ats-lang-anairiats-0.2.11/0000700000175000017500000000000012223166165013764 5ustar hwxihwxiats-lang-anairiats-0.2.11/INSTALL0000664000175000017500000001013312223166157015030 0ustar hwxihwxi// // // Installation Guide for ATS/Anairiats // // ------------------------------------------------------------------------ ###### # # Installation from a precompiled package # ###### In order to use this approach, which is the simplest, you are required to have root access. After downloading an approriate precompiled ATS package for your platform, please untar it in the root directory "/". Then set the environment variable ATSHOME to "/usr/share/atshome". ------------------------------------------------------------------------ ###### # # Installation through source code compilation # ###### The current implementation of ATS is given the name ATS/Anairiats, or simply Anairiats. It is nearly all written in ATS itself. In order to install Anairiats, the following requirements need to be met: * Operating System requirement: * Linux * Windows with Cygwin * MacOS X (currently no GC support for multithreading) * SunOS (currently no GC support for multithreading) We plan to port it to other platforms in the future. * Programming Language requirement: GNU C Compiler (GCC). Also, the GMP library (libgmp.a), which is often included in a GNU/Linux distribution, is currently optional, and it may be required to install a future release of ATS. Once these requirements are met, you can readily install Anairiats in 3 steps as describled below: Step 1: After downloading the tarball ATS.tgz, please untar it in a directory, say "FOO", of your choice. This, for instance, can be done by executing the following command: tar -zvxf ATS.tar.gz All the files and directories extracted from the tarball are now in the directory "FOO/ATS". Step 2: Please execute the following command ./configure --prefix=DESTDIR where DESTDIR is the name of the directory where ATS is to be installed. If the argument [--prefix=DESTDIR] is missing, then the default directory for installing ATS is "/usr/local". You can now go into the directory "FOO/ATS" and execute make all This generates executables "atscc" and "atsopt" in the directory "FOO/ATS/bin", which is the command you need for compiling ATS programs, and a library file "libats.a" in the directory "FOO/ATS/CCOMP/lib", which you need for linking. Step 3: Please make sure that ATSHOME is set to "FOO/ATS", and ATSHOMERELOC is set to "ATS-x.x.x", where x.x.x is the verison number of ATS package. This should probably be done by a shell script. Step 4: Optionally, you can install ATS by executing make install If you do so, please set ATSHOME to $DESTDIR/share/ats-anairiats-x.x.x, which is the name of the directory where ATS is installed. The environment variable ATSHOMERELOC is still set to "ATS-x.x.x". Note that the values of ATSHOME and ATSHOMERELOC can also be found in the files "FOO/ATS/.ATSHOME" and "FOO/ATS/.ATSHOMERELOC", respectively. ------------------------------------------------------------------------ ###### # # Installation through bootstrapping # ###### This approach is most suitable for keeping up with the active development of ATS. In order to bootstrap ATS/Anairiats, one needs to first check out the following svn directory and name it as some local directory, say, "FOO": svn co https://ats-lang.svn.sourceforge.net/svnroot/ats-lang/trunk FOO Then one needs to check out another svn directory and name it as the local directory "FOO/bootstrap0": svn co \ https://ats-lang.svn.sourceforge.net/svnroot/ats-lang/bootstrap/anairiats \ FOO/bootstrap0 After this is done, please go into the directory "FOO" and execute the command 'autoconf' and then do 'make all'. It is also possible to use the ATS/Geizella compiler (written in Objective Caml) for bootstrapping ATS/Anairiats. This can be done by checking out the following svn directory and name it as the local directory "FOO/bootstrap0": svn co \ https://ats-lang.svn.sourceforge.net/svnroot/ats-lang/bootstrap/geizella \ FOO/bootstrap0 After this is done, please go into the directory "FOO" and execute the command 'aclocal' and then 'autoconf' and then do 'make all'. ###### ------------------------------------------------------------------------ ###### end of [INSTALL] ###### ats-lang-anairiats-0.2.11/utils/0000700000175000017500000000000012223166166015125 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/scripts/0000700000175000017500000000000012223166166016614 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/scripts/atscc_main.dats0000664000175000017500000004416612223166165021620 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // Time: Summer 2007 // // This is one of the first programs written in ATS/Geizella. The coding // style is clearly awkward. // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" #include "libc/CATS/stdlib.cats" #include "libc/sys/CATS/types.cats" // for [pid_t] #include "libc/CATS/unistd.cats" typedef ats_ptr_type ats_intref_type ; %} // end of [%{^] (* ****** ****** *) staload "top.sats" (* ****** ****** *) fn do_usage ( cmd: string ) : void = () where { val () = printf ("The usage of %s is:\n", @(cmd)) val () = printf (" %s [flag-or-file]*\n", @(cmd)) } // end of [do_usage] (* ****** ****** *) #define nil STRLSTnil; #define :: STRLSTcons fn string_is_flag (s: string): bool = let val s = string1_of_string s in if string_is_empty s then false else (s[0] = '-') end // end of [string_is_flag] (* ****** ****** *) // extern fun DATS_wait_set (): void = "DATS_wait_set" extern fun DATS_wait_is_set (): bool = "DATS_wait_is_set" extern fun DATS_wait_clear (): void = "DATS_wait_clear" extern fun DATS_extract (s: string): Stropt = "DATS_extract" extern fun flag_is_DATSdef (s: string): bool = "flag_is_DATSdef" // extern fun IATS_wait_set (): void = "IATS_wait_set" extern fun IATS_wait_is_set (): bool = "IATS_wait_is_set" extern fun IATS_wait_clear (): void = "IATS_wait_clear" extern fun IATS_extract (s: string): Stropt = "IATS_extract" extern fun flag_is_IATSdir (s: string): bool = "flag_is_IATSdir" // (* ****** ****** *) fn flag_is_m32 (flag: string): bool = case+ flag of | "-m32" => true | _ => false fn flag_is_m64 (flag: string): bool = case+ flag of | "-m64" => true | _ => false (* ****** ****** *) fn flag_is_compile_only (flag: string): Bool = case+ flag of "-cc" => true | "--compile" => true | _ => false val is_compile_only: intref = intref_make 0 extern val "is_compile_only" = is_compile_only (* ****** ****** *) fn flag_is_typecheck_only (flag: string): Bool = case+ flag of "-tc" => true | "--typecheck" => true | _ => false val is_typecheck_only: intref = intref_make 0 extern val "is_typecheck_only" = is_typecheck_only (* ****** ****** *) fn flag_is_objcode_only (flag: string): Bool = case+ flag of "-c" => true | _ => false val is_objcode_only: intref = intref_make 0 extern val "is_objcode_only" = is_objcode_only (* ****** ****** *) fn flag_is_debug (flag: string): Bool = case+ flag of "-g" => true | _ => false fn flag_is_version (flag: string): Bool = case+ flag of "-v" => true | "--version" => true | _ => false // end of [flag_is_version] (* ****** ****** *) fn flag_is_ATS_GCATS (flag: string): Bool = begin case+ flag of "-D_ATS_GCATS" => true | _ => false end // end of [flag_is_ATS_GCATS] val is_ATS_GCATS: intref = intref_make 0 fn flag_is_ATS_GCATS2 (flag: string): Bool = begin case+ flag of "-D_ATS_GCATS2" => true | _ => false end // end of [flag_is_ATS_GCATS2] val is_ATS_GCATS2: intref = intref_make 0 fn flag_is_ATS_GCBDW (flag: string): Bool = begin case+ flag of "-D_ATS_GCBDW" => true | _ => false end // end of [flag_is_ATS_GCBDW] val is_ATS_GCBDW: intref = intref_make 0 (* ****** ****** *) fn flag_is_ATS_MULTITHREAD (flag: string): Bool = case+ flag of "-D_ATS_MULTITHREAD" => true | _ => false val is_ATS_MULTITHREAD = intref_make 0 extern val "is_ATS_MULTITHREAD" = is_ATS_MULTITHREAD (* ****** ****** *) fn flag_is_ATS_DEBUG (flag: string): Bool = begin case+ flag of "-D_ATS_DEBUG" => true | _ => false end // end of [flag_is_ATS_DEBUG] val is_ATS_DEBUG: intref = intref_make 0 (* ****** ****** *) fn flag_is_lats (flag: string): Bool = case+ flag of "-lats" => true | _ => false val is_lats: intref = intref_make 0 fn flag_is_lats_mt (flag: string): Bool = case+ flag of "-lats_mt" => true | _ => false val is_lats_mt: intref = intref_make 0 (* ****** ****** *) extern fun atscc_outfile_name_make (basename: string): String = "atscc_outfile_name_make" // end of [atscc_outfile_name_make] (* ****** ****** *) #define sbp2str string1_of_strbuf fn atscc_argv_process {n:pos} {l:addr} ( pf: !array_v (String, n, l) | n: int n, p: ptr l ) : Strlst(*param_c*) = let // fn* aux {i:nat | i <= n} ( // .. pf: !array_v (String, n, l) | param_ats: Strlst, param_c: Strlst, i: int i ) : Strlst(*param_c*) = if i < n then let val s = p[i] in case+ 0 of // | _ when DATS_wait_is_set () => begin DATS_wait_clear (); aux (pf | s :: param_ats, param_c, i+1) end // end of [_ when ...] // | _ when IATS_wait_is_set () => begin IATS_wait_clear (); aux (pf | s :: param_ats, param_c, i+1) end // end of [_ when ...] // | _ when string_is_flag s => begin aux_flag (pf | param_ats, param_c, i, s) end // end of [_ when ...] | _ => begin aux_file (pf | param_ats, param_c, i, s) end // end of [_] end else if intref_get is_objcode_only > 0 then let val param_c = strlst_reverse param_c val _IATSHOME = sbp2str ("-I" + ATSHOME_dir) val param_c = _IATSHOME :: param_c val _Iruntime_global = sbp2str ("-I" + runtime_global) val param_c = _Iruntime_global :: param_c in param_c end else let val param_c = (case+ 0 of | _ when intref_get is_ATS_GCATS > 0 => let val is_mt = intref_get is_ATS_MULTITHREAD > 0 val gcobj_local = (if is_mt then "GCATS/gc_mt.o" else "GCATS/gc.o"): string val gcobj_global = runtime_global + gcobj_local in gcobj_global :: param_c end // end of [ATS_GCATS] | _ when intref_get is_ATS_GCATS2 > 0 => let val gc_o = sbp2str (runtime_global + "GCATS2/gc.o") in gc_o :: param_c end // end of [ATS_GCATS2] | _ when intref_get is_ATS_GCBDW > 0 => let (* val () = begin prerr "is_ATS_GCBDW = 1"; prerr_newline () end // end of [val] *) // [ATS_PKGCONFIG] is declared in [prelude/params.hats] #if (ATS_PKGCONFIG == 1) #then #define :: STRLSTcons; #define nil STRLSTnil val arglst = "bdw-gc" :: "--libs" :: nil () val toks = atscc_pkgconfig (arglst, 2) where { extern fun atscc_pkgconfig {n:nat} (arglst: strlst n, narg: int n): List_vt string = "atscc_pkgconfig" } // end of [val] val param_c = loop (param_c, toks) where { fun loop (param_c: Strlst, toks: List_vt string): Strlst = case+ toks of | ~list_vt_cons (tok, toks) => loop (STRLSTcons (tok, param_c), toks) | ~list_vt_nil () => param_c // end of [loop] } // end of [val param_c] #else // ATS_PKGCONFIG <> 1 val gcobj_local_lib = "GCBDW/lib": string val gcobj_global_lib = runtime_global + gcobj_local_lib val param_c = ("-L" + gcobj_global_lib) :: param_c val param_c = "-lgc" :: param_c #endif // end of [ATS_PKGCONFIG == 1] in param_c end // end of [ATS_GCBDW] | _ => param_c ) : Strlst // end of [val] // val param_c = ( if intref_get is_ATS_MULTITHREAD > 0 then if intref_get is_lats_mt > 0 then param_c else "-lats_mt" :: param_c else param_c ) : Strlst // end of [val] // val param_c = ( if intref_get is_lats > 0 then param_c else "-lats" :: param_c ) : Strlst // end of [val] // val param_c = strlst_reverse param_c val ats_prelude_c = sbp2str (runtime_global + "ats_prelude.c") val param_c = ats_prelude_c :: param_c val _Latslib_global = sbp2str ("-L" + atslib_global ()) val param_c = _Latslib_global :: param_c val _Iruntime_global = sbp2str ("-I" + runtime_global) val param_c = _Iruntime_global :: param_c val _IATSHOME = sbp2str ("-I" + ATSHOME_dir) val param_c = _IATSHOME :: param_c in param_c (* Strlst *) end // end of [aux] // and aux_flag {i:nat | i < n} // .. (pf: !array_v (String, n, l) | param_ats: Strlst, param_c: Strlst, i: int i, flag: String) : Strlst = begin case+ flag of | _ when flag_is_typecheck_only flag => let val () = intref_set (is_typecheck_only, 1) val param_ats = "--typecheck" :: param_ats in aux (pf | param_ats, param_c, i+1) end // end of [_ when flag_is_typecheck_only] | _ when flag_is_compile_only flag => let val () = intref_set (is_compile_only, 1) in aux (pf | param_ats, param_c, i+1) end // end of [_ when flag_is_compile_only] | _ when flag_is_objcode_only flag => let val () = intref_set (is_objcode_only, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_objcode_only] // | _ when flag_is_ATS_GCATS flag => let val () = intref_set (is_ATS_GCATS, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_ATS_GCATS] | _ when flag_is_ATS_GCATS2 flag => let val () = intref_set (is_ATS_GCATS2, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_ATS_GCATS2] | _ when flag_is_ATS_GCBDW flag => let val () = intref_set (is_ATS_GCBDW, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_ATS_GCBDW] // | _ when flag_is_ATS_MULTITHREAD flag => let val () = intref_set (is_ATS_MULTITHREAD, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_ATS_MULTITHREAD] // | _ when flag_is_lats flag => let val () = intref_set (is_lats, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_lats] | _ when flag_is_lats_mt flag => let val () = intref_set (is_lats_mt, 1) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_lats_mt] // | _ when flag_is_ATS_DEBUG flag => let val param_ats = "--debug=1" :: param_ats in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_ATS_DEBUG] // | _ when flag_is_DATSdef flag => let val param_ats = flag :: param_ats val flgval = DATS_extract flag; val () = begin if stropt_is_some flgval then () else DATS_wait_set () end // end of [if] in aux (pf | param_ats, param_c, i+1) end // end of [_ when ...] // | _ when flag_is_IATSdir flag => let val param_ats = flag :: param_ats val dir = IATS_extract flag; val () = begin if stropt_is_some dir then () else IATS_wait_set () end // end of [if] in aux (pf | param_ats, param_c, i+1) end // end of [_ when ...] // | _ when flag_is_m32 flag => let val () = wordsize_target_set (4(*bytes*)) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_m32] | _ when flag_is_m64 flag => let val () = wordsize_target_set (8(*bytes*)) in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_m64] // | _ when flag_is_debug flag => let val param_c = flag :: param_c val param_ats = "--gline" :: param_ats in aux (pf | param_ats, param_c, i+1) end // end of [_ when flag_is_debug] // | _ when flag_is_version flag => let val () = atscc_version () in aux (pf | param_ats, flag :: param_c, i+1) end // end of [_ when flag_is_version] // | _ => aux (pf | param_ats, flag :: param_c, i+1) end // end of [aux_flag] // and aux_file {i:nat | i < n} // .. (pf: !array_v (String, n, l) | param_ats: Strlst, param_c: Strlst, i: int i, file: String) : Strlst = let val sfx = suffix_of_filename file val flag_stadyn = ( if stropt_is_none sfx then ~1 else begin case stropt_unsome sfx of "sats" => 0 | "dats" => 1 | _ => ~1 end ) : int val flag_debug = (if intref_get (is_ATS_DEBUG) > 0 then 1 else 0): int in if flag_stadyn >= 0 then if intref_get (is_typecheck_only) > 0 then let val () = typecheck_file (flag_stadyn, param_ats, file) in aux (pf | param_ats, param_c, i+1) end else let val basename = basename_of_filename file val outfile_c = atscc_outfile_name_make basename val () = ccomp_file_to_file (flag_stadyn, param_ats, file, outfile_c) val param_c = outfile_c :: param_c in aux (pf | param_ats, param_c, i+1) end // end of [if] else begin aux (pf | param_ats, file :: param_c, i+1) end (* end of [if] *) end // end of [aux_file] // in aux (pf | nil (*param_ats*), nil (*param_c*), 1) end // end of [atscc_argv_process] (* ****** ****** *) extern val "atscc_argv_process" = atscc_argv_process // for use in C (* ****** ****** *) dynload "basics.dats" dynload "atscc.dats" (* ****** ****** *) implement main_prelude () = () (* ****** ****** *) extern fun atscc_main {n:pos} (argc: int n, argv: &(@[string][n])): void = "atscc_main" // end of [atscc_main] implement main (argc, argv) = case+ argc of | 1 => let val cmd = argv.[0] in do_usage (basename_of_filename cmd) end | _ => atscc_main (argc, argv) // end of [main] (* ****** ****** *) %{$ static int the_DATS_wait = 0 ; ats_void_type DATS_wait_set () { the_DATS_wait = 1 ; return ; } ats_bool_type DATS_wait_is_set () { return (the_DATS_wait ? ats_true_bool : ats_false_bool) ; } ats_void_type DATS_wait_clear () { the_DATS_wait = 0 ; return ; } ats_bool_type flag_is_DATSdef (ats_ptr_type s0) { return ( strncmp((char*)s0, "-DATS", 5)==0 ? ats_true_bool : ats_false_bool ) ; } // end of [flag_is_DATSdef] ats_ptr_type DATS_extract (ats_ptr_type s0) { int n ; char* s ; n = strlen ((char*)s0) - 5 ; if (n <= 0) return (ats_ptr_type)0 ; s = ats_malloc_gc (n + 1) ; memcpy (s, (char*)s0 + 5, n) ; s[n] = '\0' ; return s ; } // end of [DATS_extract] %} // end of [%{$] (* ****** ****** *) %{$ static int the_IATS_wait = 0 ; ats_void_type IATS_wait_set () { the_IATS_wait = 1 ; return ; } ats_bool_type IATS_wait_is_set () { return (the_IATS_wait ? ats_true_bool : ats_false_bool) ; } ats_void_type IATS_wait_clear () { the_IATS_wait = 0 ; return ; } ats_bool_type flag_is_IATSdir (ats_ptr_type s0) { return ( strncmp((char*)s0, "-IATS", 5)==0 ? ats_true_bool : ats_false_bool ) ; } // end of [flag_is_IATSdir] ats_ptr_type IATS_extract (ats_ptr_type s0) { int n ; char* s ; n = strlen ((char*)s0) - 5 ; if (n <= 0) return (ats_ptr_type)0 ; s = ats_malloc_gc (n + 1) ; memcpy (s, (char*)s0 + 5, n) ; s[n] = '\0' ; return s ; } // end of [IATS_extract] %} // end of [%{$] (* ****** ****** *) %{$ typedef ats_ptr_type ats_stropt_type ; typedef ats_ptr_type ats_string_type ; // extern ats_ptr_type strlst_head_get(ats_ptr_type) ; extern ats_ptr_type strlst_tail_get(ats_ptr_type) ; // extern ats_int_type strlst_length(ats_ptr_type) ; extern ats_ptr_type strlst_reverse(ats_ptr_type) ; // extern ats_intref_type is_compile_only ; extern ats_intref_type is_typecheck_only ; extern ats_int_type inref_get(ats_intref_type) ; // ats_string_type atscc_outfile_name_make ( ats_string_type basename ) { int n ; char c, *s ; n = strlen((char*)basename) ; s = (char*)ats_malloc_gc(n+3) ; s[n+2] = '\000' ; s[n+1] = 'c' ; s[n] = '.' ; --n ; while (n >= 0) { c = ((char*)basename)[n] ; if (c == '.') { s[n] = '_' ; --n ; break ; } s[n] = c ; --n ; } while (n >= 0) { s[n] = ((char*)basename)[n] ; --n ; } return s ; } // end of [atscc_outfile_name_make] ats_void_type atscc_main ( ats_int_type argc , ats_ptr_type argv ) { int i, n ; ats_sum_ptr_type ss ; ats_ptr_type argv_new, p ; pid_t pid ; int status, ecode ; extern ats_ptr_type ATSCCOMP_gcc ; char *gcc = (char*)ATSCCOMP_gcc ; ss = ((ats_sum_ptr_type (*)(ats_int_type, ats_ptr_type))atscc_argv_process)(argc, argv) ; if (intref_get(is_compile_only) > 0) return ; if (intref_get(is_typecheck_only) > 0) return ; n = strlst_length(ss) ; argv_new = ats_malloc_ngc ((n+1)*sizeof(ats_string_type)+sizeof(ats_stropt_type)) ; p = argv_new ; // initialization for [argv_new] *((ats_string_type*)p) = gcc ; p = ((ats_string_type*)p) + 1 ; for (i = 0; i < n; ++i) { *((ats_string_type*)p) = strlst_head_get(ss) ; p = ((ats_string_type*)p) + 1 ; ss = strlst_tail_get(ss) ; } /* end of [for] */ *((ats_stropt_type *)p) = (ats_stropt_type)0 ; // printf ("argv_new = ") ; for (i = 0; i <= n; ++i) { printf ("%s ", (char*)((ats_string_type*)argv_new)[i]) ; } /* end of [for] */ printf ("\n") ; pid = fork () ; if (pid < 0) { ats_exit_errmsg (1, "Exit: [fork] failed.\n") ; } /* end of [if] */ if (pid == 0) execvp (gcc, argv_new) ; // this is the child status = 0 ; wait (&status) ; // this is the parent if (status) { if (WIFEXITED(status)) ecode = WEXITSTATUS(status) ; else ecode = EXIT_FAILURE ; // end of [if] atspre_exit_prerrf (ecode, "Exit: [%s] failed.\n", gcc) ; } /* end of [if] */ return ; } // end of [atscc_main] %} // end of [%{$] (* ****** ****** *) (* end of [atscc_main.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/top.sats0000664000175000017500000001164212223166165020331 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2007 // (* ****** ****** *) fun wordsize_target_get (): size_t fun wordsize_target_set (sz: size_t): void (* ****** ****** *) val ATSHOME_dir : String = "ATSHOME_dir" val ATSCCOMP_gcc : String = "ATSCCOMP_gcc" val atsopt_local : String = "atsopt_local" and atsopt_global : String = "atsopt_global" val precats_local : String = "precats_local" and precats_global : String = "precats_global" val runtime_local : String = "runtime_local" and runtime_global : String = "runtime_global" (* ****** ****** *) fun atslib_local (): String = "atslib_local" fun atslib_output_local (): String = "atslib_output_local" fun atslib_global (): String = "atslib_global" fun atslib_output_global (): String = "atslib_output_global" (* ****** ****** *) fun libats_local (): String = "libats_local" fun libats_global (): String = "libats_global" fun libats_mt_local (): String = "libats_mt_local" fun libats_mt_global (): String = "libats_mt_global" (* ****** ****** *) fun ATSHOME_dir_append (s: string): String fun basename_of_filename (s: string): String fun suffix_of_filename (s: string): Stropt fun filename_is_local (s: string): Bool (* ****** ****** *) fun getcwd0 () : strptr1 = "atsutil_getcwd0" fun file_is_exec (file: string) : Bool = "file_is_exec" (* ****** ****** *) abstype intref // boxed type = ats_intref_type fun intref_make (i: int): intref = "intref_make" fun intref_get (r: intref): int = "intref_get" fun intref_set (r: intref, i: int): void = "intref_set" (* ****** ****** *) datatype strlst (int) = | STRLSTnil (0) | {n:nat} STRLSTcons (n+1) of (string, strlst n) typedef Strlst = [n:nat] strlst n fun strlst_nil (): strlst 0 = "strlst_nil" fun strlst_is_nil {n:nat} (ss: strlst n): bool (n == 0) = "strlst_is_nil" fun strlst_head_get {n:pos} (ss: strlst n): string = "strlst_head_get" fun strlst_tail_get {n:pos} (ss: strlst n): strlst (n-1) = "strlst_tail_get" fun strlst_length {n:nat} (ss: strlst n): size_t n = "strlst_length" fun strlst_reverse {n:nat} (ss: strlst n): strlst n = "strlst_reverse" (* ****** ****** *) dataviewtype lstrlst (int) = // for linear string lists | LSTRLSTnil (0) | {n:nat} LSTRLSTcons (n+1) of (string, lstrlst n) viewtypedef Lstrlst = [n:nat] lstrlst n fun lstrlst_reverse {n:nat} (xs: lstrlst n):<> lstrlst n (* ****** ****** *) fun strlst_to_strarr {n:nat} {l:addr} (pf: !array_v (String?, n, l) >> array_v (String, n, l) | ss: strlst n, p: ptr l) : void = "strlst_to_strarr" fun string_trans (s: string, f: char - String): String = "string_trans" (* ****** ****** *) fun ccomp_file_to_file_err (flag_stadyn: int, param_ats: Strlst, infile: string, outfile: string): int // end of [ccomp_file_to_file_err] fun ccomp_file_to_file (flag_stadyn: int, param_ats: Strlst, infile: string, outfile: string): void // end of [ccomp_file_to_file] (* ****** ****** *) fun typecheck_file (flag_stadyn: int, param_ats: Strlst, infile: string): void // end of [typecheck_file] (* ****** ****** *) fun atscc_version (): void (* ****** ****** *) fun ar_s_exn (libfile: string): void fun gcc_libfile_err (param: Strlst, infile: string, outfile: string): int fun ccomp_gcc_ar_libfile (param: Strlst, infile: string, libfile: string): void // for building the main ATS library fun libats_make (param: Strlst): void fun libats_mt_make (param: Strlst): void // for building the sml basis library fun libats_smlbas_make (param: Strlst): void // for building the atslex library fun libats_lex_make (param: Strlst): void (* ****** ****** *) (* end of top.sats *) ats-lang-anairiats-0.2.11/utils/scripts/atspack.dats0000664000175000017500000013556212223166166021147 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2008 // (* ****** ****** *) // // HX: // The command [atspack] is called to make an ATS package for release // // // This is done in ATS (instead of in a scripting language like PERL) largely // because I want to test some functions declared in [libc/SATS/stdio.sats]. // Also, this exercise should help myself become a bit more familiar with the // Linux file system in general. // (* ****** ****** *) // staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" // staload "libc/SATS/dirent.sats" // staload STAT = "libc/sys/SATS/stat.sats" macdef chmod_exn = $STAT.chmod_exn macdef mkdir_exn = $STAT.mkdir_exn // staload TYPES = "libc/sys/SATS/types.sats" typedef mode_t = $TYPES.mode_t // (* ****** ****** *) #define ATSPACKAGE_NAME "ats-lang-anairiats" (* ****** ****** *) extern fun dirent_name_get (dir: &DIR): Stropt = "dirent_name_get" %{^ /* extern ats_ptr_type atspre_string_make_substring ( ats_ptr_type src0, ats_size_type st, ats_size_type ln ) ; // atspre_string_make_substring */ static inline ats_ptr_type dirent_name_get (ats_ptr_type dir) { struct dirent *ent ; ent = readdir((DIR*)dir) ; if (ent) { return atspre_string_make_substring (ent->d_name, 0, strlen(ent->d_name)) ; } else { return (char*)0 ; } // end of [if] } /* end of [dirent_name_get] */ %} // end of [%{^] (* ****** ****** *) fn getenv_exn (name: string): String = let val (fpf_x | x) = getenv name in if strptr_isnot_null (x) then let val x1 = strptr_dup (x) prval () = fpf_x (x) val x1 = string_of_strptr (x1) in string1_of_string (x1) end else let prval () = fpf_x (x) in prerr "The environment variable ["; prerr name; prerr "] is undefined!\n" ; exit (1) end (* end of [if] *) end // end of [getenv_exn] val ATSHOME = let val str = getenv_exn ("ATSHOME") (* val lst = string_length (str) - 1 val () = if str[lst] = dirsep then str[lst] = '\000' else () *) in str // return value end // end of [val] (* ****** ****** *) infixl ++ symintr ++ overload ++ with string0_append (* ****** ****** *) val SRCROOT = ATSHOME ++ "/" fn ATSPACKAGE_VERSION_get (): string = let val name = SRCROOT ++ "VERSION.txt" val () = begin if ~(test_file_exists name) then begin prerr "The file ["; prerr name; prerr "] is not available."; prerr_newline (); exit (1) end // end of [if] end val fil = open_file_exn (name, file_mode_r) val version = input_line (fil) val () = assert_errmsg (stropt_is_some version, #LOCATION) val version = stropt_unsome version val () = close_file_exn (fil) (* val () = begin prerr "ATSPACKAGE_VERSION_get: version = "; prerr version; prerr_newline () end // end of [val] *) in version end // end of [ATSPACKAGE_VERSION_get] val ATSPACKAGE_VERSION: string = ATSPACKAGE_VERSION_get () val DSTROOT: string = let val sp = stringlst_concat '[ATSPACKAGE_NAME, "-", ATSPACKAGE_VERSION, "/"] in string_of_strptr (sp) end // end of [DSTROOT] (* ****** ****** *) // #define BUFSZ 8192 // // there are certainly faster ways to copy files, but this code gives // an opportunity to test ATS :) fn fcopy_exn (src: string, dst: string): void = let (* val () = begin print "fopen_exn: src = "; print src; print_newline (); print "fopen_exn: dst = "; print dst; print_newline (); end // end of [val] *) val (pf_src | p_src) = fopen_exn (src, file_mode_r) val (pf_dst | p_dst) = fopen_exn (dst, file_mode_w) (* val [l_buf:addr] (pf_gc, pf_buf | p_buf) = malloc_gc (BUFSZ) *) var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) fun loop ( pf_buf: !bytes (BUFSZ) @ p_buf | p_buf: ptr p_buf, src: &FILE r, dst: &FILE w ) : void = if feof (src) <> 0 then () else let val nread = fread_byte (file_mode_lte_r_r | !p_buf, BUFSZ, src) val () = fwrite_byte_exn (file_mode_lte_w_w | !p_buf, nread, dst) in loop (pf_buf | p_buf, src, dst) end // end of [loop] val () = loop (pf_buf | p_buf, !p_src, !p_dst) (* val () = free_gc (pf_gc, pf_buf | p_buf) *) in fclose_exn (pf_src | p_src); fclose_exn (pf_dst | p_dst) end // end of [fcopy_exn] (* ****** ****** *) fn fcp_Makefile (src: string, dst: string): void = fcopy_exn (src++"Makefile", dst++"Makefile") // end of [fcp_Makefile] (* ****** ****** *) val DIRmode: mode_t = begin $STAT.S_IRWXU // lor S_IRGRP lor S_IXGRP lor S_IROTH lor S_IXOTH end // end of [DIRmode] (* ****** ****** *) fn file_isexi (path: string): bool = test_file_exists (path) fn file_isdir (path: string): bool = test_file_isdir (path) > 0 (* ****** ****** *) fn dir_copy ( srcdir: string, dstdir: string, test: string -> bool ) : void = let val srcdir = string1_of_string srcdir and dstdir = string1_of_string dstdir // macdef cp (name) = fcopy_exn (srcdir ++ ,(name), dstdir ++ ,(name)) // fun loop ( dir: &DIR ) : void = let val name = dirent_name_get (dir) in case+ 0 of | _ when stropt_is_some name => let val name = stropt_unsome (name) val () = case+ name of | _ when test (name) => cp (name) | _ => () in loop (dir) end // end of [_ when ...] | _ => () end // end of [loop] val (pf_dir | p_dir) = opendir_exn (srcdir) val () = loop (!p_dir) val () = closedir_exn (pf_dir | p_dir) in // empty end // end of [dir_copy] fn dir_copy_all ( srcdir: string, dstdir: string ) : void = dir_copy (srcdir, dstdir, test) where { fun test (path: string) = ~file_isdir (path) } // end of [dir_copy_all] (* ****** ****** *) val SRCROOTccomp = SRCROOT ++ "ccomp/" val DSTROOTccomp = DSTROOT ++ "ccomp/" val SRCROOTccomp_lib = SRCROOTccomp ++ "lib/" val DSTROOTccomp_lib = DSTROOTccomp ++ "lib/" val SRCROOTccomp_lib_output = SRCROOTccomp_lib ++ "output/" val DSTROOTccomp_lib_output = DSTROOTccomp_lib ++ "output/" val SRCROOTccomp_lib64 = SRCROOTccomp ++ "lib64/" val DSTROOTccomp_lib64 = DSTROOTccomp ++ "lib64/" val SRCROOTccomp_lib64_output = SRCROOTccomp_lib64 ++ "output/" val DSTROOTccomp_lib64_output = DSTROOTccomp_lib64 ++ "output/" val SRCROOTccomp_runtime = SRCROOTccomp ++ "runtime/" val DSTROOTccomp_runtime = DSTROOTccomp ++ "runtime/" (* val SRCROOTccomp_runtime_NGC = SRCROOTccomp_runtime ++ "NGC/" val DSTROOTccomp_runtime_NGC = DSTROOTccomp_runtime ++ "NGC/" *) val SRCROOTccomp_runtime_GCATS = SRCROOTccomp_runtime ++ "GCATS/" val DSTROOTccomp_runtime_GCATS = DSTROOTccomp_runtime ++ "GCATS/" (* val SRCROOTsrc = SRCROOT ++ "src/"; val DSTROOTsrc = DSTROOT ++ "src/" *) (* ****** ****** *) val the_wordsize = sizeof : size_t var the_wordsize_target: size_t = the_wordsize val (pfbox_the_wordsize_target | ()) = begin vbox_make_view_ptr {size_t} (view@ the_wordsize_target | &the_wordsize_target) end // end of [val] fn wordsize_target_get (): size_t = let prval vbox pf = pfbox_the_wordsize_target in the_wordsize_target end // end of [wordsize_target_get] fn wordsize_target_set (sz: size_t): void = let prval vbox pf = pfbox_the_wordsize_target in the_wordsize_target := sz end // end of [wordsize_target_get] (* ****** ****** *) datatype packnd = | PACKNDsource | PACKNDprecompiled fn packnd_is_source (knd: packnd): bool = case+ knd of PACKNDsource () => true | _ => false // end of [packnd_is_source] fn packnd_is_precompiled (knd: packnd): bool = case+ knd of PACKNDprecompiled () => true | _ => false // end of [packnd_is_precompiled] (* ****** ****** *) fn Anairiats_bin_dir_copy (knd: packnd): void = let val SRCROOTbin = SRCROOT ++ "bin/" val DSTROOTbin = DSTROOT ++ "bin/" // macdef cp (name) = fcopy_exn (SRCROOTbin ++ ,(name), DSTROOTbin ++ ,(name)) macdef cpx (name) = let val src_name = SRCROOTbin ++ ,(name) val dst_name = DSTROOTbin ++ ,(name) val () = fcopy_exn (src_name, dst_name) val () = chmod_exn (dst_name, $STAT.S_IRWXU) in // empty end // end of [cpx] // val () = mkdir_exn (DSTROOTbin, DIRmode) // for keeping the directory from being removed val () = cp (".keeper") val () = begin if (packnd_is_precompiled knd) then (cpx "atscc"; cpx "atsopt") end // end of [begin] in print "The [bin] directory is successfully copied."; print_newline () end // end of [bin_dir_copy] (* ****** ****** *) fun name_is_suffix ( name: string, sfx: string ) : bool = let val [n1:int] name = string1_of_string name val n1 = string1_length (name) val [n2:int] sfx = string1_of_string sfx val n2 = string1_length (sfx) in if n1 >= n2 then let val d = n1 - n2 var i: natLte n2 = 0 var res: bool = true val () = while (i < n2) ( if name[d+i] = sfx[i] then i := i+1 else (res := false; break) ) // end of [val] in res end else false // [sfx] cannot be the suffix of [name] // end of [if] end // end of [name_is_suffix] fn name_is_c (name: string): bool = name_is_suffix (name, ".c") fn name_is_cats (name: string): bool = name_is_suffix (name, ".cats") fn name_is_dats (name: string): bool = name_is_suffix (name, ".dats") fn name_is_hats (name: string): bool = name_is_suffix (name, ".hats") fn name_is_sats (name: string): bool = name_is_suffix (name, ".sats") fn name_is_html (name: string): bool = name_is_suffix (name, ".html") fn name_is_xats (name: string): bool = let val name = string1_of_string name val n = string_length (name) in if (n >= 5) then if (name[n-5] <> '.') then false else if name[n-3] <> 'a' then false else if name[n-2] <> 't' then false else if name[n-1] <> 's' then false else true else false end // end of [name_is_xats] (* ****** ****** *) fn Anairiats_bootstrap_dir_copy () = let val SRCROOTbootstrap = SRCROOT ++ "bootstrap1/" val DSTROOTbootstrap = DSTROOT ++ "bootstrap1/" // fn test (name: string): bool = begin case+ name of | _ when name_is_c (name) => true | _ when name_is_cats (name) => true | _ => false end // end of [test] // macdef cp (name) = fcopy_exn (SRCROOTbootstrap ++ ,(name), DSTROOTbootstrap ++ ,(name)) // val () = mkdir_exn (DSTROOTbootstrap, DIRmode) val () = dir_copy (SRCROOTbootstrap, DSTROOTbootstrap, test) val () = cp "ats_grammar_yats.h" in print "The [bootstrap] directory is successfully copied."; print_newline () end // end of [Anairiats_bootscrap_dir_copy] (* ****** ****** *) fn Anairiats_ccomp_lib_dir_copy (wsz: size_t, knd: packnd): void = let val wsz = size1_of_size (wsz) // no-op casting val () = mkdir_exn (DSTROOTccomp_lib, DIRmode) val () = mkdir_exn (DSTROOTccomp_lib64, DIRmode) macdef cp32 (name) = fcopy_exn (SRCROOTccomp_lib ++ ,(name), DSTROOTccomp_lib ++ ,(name)) macdef cp64 (name) = fcopy_exn (SRCROOTccomp_lib64 ++ ,(name), DSTROOTccomp_lib64 ++ ,(name)) val () = if (packnd_is_precompiled knd) then let val () = if (wsz = 4(*bytes*)) then let val () = cp32 ("libats.a") val () = cp32 ("libats_mt.a") val () = cp32 ("libats_smlbas.a") val () = cp32 ("libatsdoc.a") in // nothing end // end of [val] val () = if (wsz = 8(*bytes*)) then let val () = cp64 ("libats.a") val () = cp64 ("libats_mt.a") val () = cp64 ("libats_smlbas.a") val () = cp64 ("libatsdoc.a") in // nothing end // end of [val] in // nothing end // end of [val] val () = mkdir_exn (DSTROOTccomp_lib_output, DIRmode) val () = mkdir_exn (DSTROOTccomp_lib64_output, DIRmode) val () = fcopy_exn // keeping the directory from being removed (SRCROOTccomp_lib_output ++ ".keeper", DSTROOTccomp_lib_output ++ ".keeper") // end of [val] val () = fcopy_exn // keeping the directory from being removed (SRCROOTccomp_lib64_output ++ ".keeper", DSTROOTccomp_lib64_output ++ ".keeper") // end of [val] in // empty end // end of [Anairiats_ccomp_lib_dir_copy] (* ****** ****** *) (* fn Anairiats_ccomp_runtime_NGC_dir_copy (knd: packnd): void = () where { val () = mkdir_exn (DSTROOTccomp_runtime_NGC, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTccomp_runtime_NGC ++ ,(name), DSTROOTccomp_runtime_NGC ++ ,(name) ) // end of [fcopy_exn] val () = cp "gc.h" val () = print "The [ccomp/runtime/NGC] directory is successfully copied."; val () = print_newline () } // end of [Anairiats_ccomp_runtime_NGC_dir_copy] *) (* ****** ****** *) fn Anairiats_ccomp_runtime_GCATS_dir_copy (knd: packnd): void = let fn test (name: string): bool = begin case+ name of | _ when name_is_xats (name) => true | _ => false end // end of [filename_test] // macdef cp (name) = fcopy_exn ( SRCROOTccomp_runtime_GCATS ++ ,(name), DSTROOTccomp_runtime_GCATS ++ ,(name) ) // end of [fcopy_exn] // val () = mkdir_exn (DSTROOTccomp_runtime_GCATS, DIRmode) val () = dir_copy ( SRCROOTccomp_runtime_GCATS, DSTROOTccomp_runtime_GCATS, test ) // end of [dir_copy] val () = begin cp "Makefile"; cp "README"; // cp "gc.h"; // no longer used end // end of [val] val () = begin if (packnd_is_precompiled knd) then (cp "gc.o"; cp "gc_mt.o") end // end of [val] in print "The [ccomp/runtime/GCATS] directory is successfully copied."; print_newline () end // end of [Anairiats_ccomp_runtime_GCATS_dir_copy] (* ****** ****** *) fn Anairiats_ccomp_runtime_dir_copy (knd: packnd): void = let macdef cp (name) = fcopy_exn ( SRCROOTccomp_runtime ++ ,(name), DSTROOTccomp_runtime ++ ,(name) ) val () = mkdir_exn (DSTROOTccomp_runtime, DIRmode) in cp "ats_config.h"; cp "ats_basics.h"; cp "ats_types.h"; cp "ats_exception.h"; cp "ats_memory.h"; cp "ats_bootstrap.c"; cp "ats_prelude.c"; cp "ats_prelude_ngc.c"; cp "ats_prelude_gcats.c"; cp "ats_prelude_gcbdw.c"; // ccomp_runtime_NGC_dir_copy (knd); // no longer in use Anairiats_ccomp_runtime_GCATS_dir_copy (knd); print "The [ccomp/runtime] directory is successfully copied."; print_newline () end // end of [Anairiats_ccomp_runtime_dir_copy] (* ****** ****** *) fn Anairiats_ccomp_dir_copy (knd: packnd): void = let val () = mkdir_exn (DSTROOTccomp, DIRmode) val () = let val wsz = wordsize_target_get () in Anairiats_ccomp_lib_dir_copy (wsz, knd) end // end of [val] val () = Anairiats_ccomp_runtime_dir_copy (knd) in // empty end // end of [Anairiats_ccomp_dir_copy] (* ****** ****** *) fn Anairiats_doc_dir_copy () = let val SRCROOTdoc = SRCROOT ++ "doc/" val DSTROOTdoc = DSTROOT ++ "doc/" val () = mkdir_exn (DSTROOTdoc, DIRmode) val () = fcopy_exn ( SRCROOTdoc ++ "FAQ.txt", DSTROOTdoc ++ "FAQ.txt" ) // end of [fcopy_exn] // val () = () where { val SRCROOTdoc_BOOK = SRCROOTdoc ++ "BOOK/" val DSTROOTdoc_BOOK = DSTROOTdoc ++ "BOOK/" val () = mkdir_exn (DSTROOTdoc_BOOK, DIRmode) val SRCROOTdoc_BOOK_manual = SRCROOTdoc_BOOK ++ "manual/" val DSTROOTdoc_BOOK_manual = DSTROOTdoc_BOOK ++ "manual/" val () = mkdir_exn (DSTROOTdoc_BOOK_manual, DIRmode) val () = fcopy_exn ( SRCROOTdoc_BOOK_manual ++ "manual_main.pdf" , DSTROOTdoc_BOOK_manual ++ "manual_main.pdf" ) // end of [fcopy_exn] } // end of [val] // val SRCROOTdoc_EXAMPLE = SRCROOTdoc ++ "EXAMPLE/" val DSTROOTdoc_EXAMPLE = DSTROOTdoc ++ "EXAMPLE/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE, DIRmode) // val () = () where { val SRCROOTdoc_EXAMPLE_INTRO = SRCROOTdoc_EXAMPLE ++ "INTRO/" val DSTROOTdoc_EXAMPLE_INTRO = DSTROOTdoc_EXAMPLE ++ "INTRO/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_INTRO, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_INTRO ++ ,(name), DSTROOTdoc_EXAMPLE_INTRO ++ ,(name) ) val () = cp "Makefile" val () = cp "HelloWorld.dats" val () = cp "f91.dats" val () = cp "fact1.dats" val () = cp "fact2.dats" val () = cp "fact3.dats" val () = cp "fact4.dats" val () = cp "fact_in_c.dats" val () = cp "fibs.dats" val () = cp "revarr.dats" val () = cp "revstr.dats" val () = cp "tally.dats" } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_MISC = SRCROOTdoc_EXAMPLE ++ "MISC/" val DSTROOTdoc_EXAMPLE_MISC = DSTROOTdoc_EXAMPLE ++ "MISC/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_MISC, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_MISC ++ ,(name), DSTROOTdoc_EXAMPLE_MISC ++ ,(name) ) val () = cp "Makefile" val () = cp "AutoDiff.dats" val () = cp "BlackScholes.dats" val () = cp "coin_flip.dats" val () = cp "curve.dats" val () = cp "fft.dats" val () = cp "GarsiaWachs.dats" val () = cp "GaussElim.dats" val () = cp "gcd_mt.dats" val () = cp "hamming_lazy.dats" val () = cp "hanoi.dats" val () = cp "isqrt.dats" val () = cp "kmp.dats" val () = cp "longestline.dats" val () = cp "montecarlo.dats" val () = cp "mycat.dats" val () = cp "myfind.dats" val () = cp "passwdgen.dats" val () = cp "pi_lazy.dats" val () = cp "Peano.dats" val () = cp "permute.dats" val () = cp "permute_vt.dats" val () = cp "quicksort_list.dats" val () = cp "quicksort1_list.dats" val () = cp "quicksort2_list.dats" val () = cp "queens.dats" val () = cp "queens_appel.dats" val () = cp "queens_lazy_vt.dats" val () = cp "sieve.dats" val () = cp "sieve_lazy.dats" val () = cp "sieve_lazy_vt.dats" val () = cp "strmat.dats" val () = cp "sumup.dats" val () = cp "systemf_programming_examples.dats" val () = cp "tetrix.dats" val () = cp "wc.dats" } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_MISC = SRCROOTdoc_EXAMPLE ++ "MISC/Twentyfour/" val DSTROOTdoc_EXAMPLE_MISC = DSTROOTdoc_EXAMPLE ++ "MISC/Twentyfour/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_MISC, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_MISC ++ ,(name), DSTROOTdoc_EXAMPLE_MISC ++ ,(name) ) val () = cp "Makefile" val () = cp "rational.sats" val () = cp "rational.dats" val () = cp "twentyfour.dats" } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_MISC = SRCROOTdoc_EXAMPLE ++ "MISC/HttpServer/" val DSTROOTdoc_EXAMPLE_MISC = DSTROOTdoc_EXAMPLE ++ "MISC/HttpServer/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_MISC, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_MISC ++ ,(name), DSTROOTdoc_EXAMPLE_MISC ++ ,(name) ) val () = cp "Makefile" val () = cp "server.dats" val () = cp "server2.dats" } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_TEST = SRCROOTdoc_EXAMPLE ++ "TEST/" val DSTROOTdoc_EXAMPLE_TEST = DSTROOTdoc_EXAMPLE ++ "TEST/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_TEST, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_TEST ++ ,(name), DSTROOTdoc_EXAMPLE_TEST ++ ,(name) ) // val () = cp "Makefile" // val () = cp "prelude_array.dats" val () = cp "prelude_array0.dats" val () = cp "prelude_bool.dats" val () = cp "prelude_char.dats" val () = cp "prelude_float.dats" val () = cp "prelude_integer.dats" val () = cp "prelude_list.dats" val () = cp "prelude_list_vt.dats" val () = cp "prelude_dlist_vt.dats" val () = cp "prelude_matrix.dats" val () = cp "prelude_matrix0.dats" val () = cp "prelude_string.dats" // val () = cp "prelude_lazy_vt.dats" // val () = cp "libc_math.dats" val () = cp "libc_complex.dats" val () = cp "libc_dirent.dats" val () = cp "libc_dlfcn.dats" val () = cp "libc_gmp.dats" val () = cp "libc_printf.dats" val () = cp "libc_pwd.dats" val () = cp "libc_random.dats" val () = cp "libc_sched.dats" val () = cp "libc_stdio.dats" val () = cp "libc_stdlib.dats" val () = cp "libc_time.dats" val () = cp "libc_unistd.dats" // val () = cp "libc_gdbm_gdbm.dats" val () = cp "libc_gdbm_ndbm.dats" // val () = cp "libc_sys_utsname.dats" // val () = cp "libats_funarray_braun.dats" val () = cp "libats_fundeque_fingertree.dats" val () = cp "libats_funheap_braun.dats" val () = cp "libats_funheap_binomial.dats" val () = cp "libats_funmap_avltree.dats" val () = cp "libats_funmap_rbtree.dats" val () = cp "libats_funralist_nested.dats" val () = cp "libats_funset_avltree.dats" val () = cp "libats_funset_listord.dats" // val () = cp "libats_genarrays.dats" val () = cp "libats_hashtable_chain.dats" val () = cp "libats_hashtable_linprb.dats" val () = cp "libats_intinf.dats" val () = cp "libats_iterint.dats" // val () = cp "libats_linstack_arr.dats" val () = cp "libats_linqueue_arr.dats" val () = cp "libats_linqueue_lst.dats" // val () = cp "libats_linmap_avltree.dats" val () = cp "libats_linmap_rbtree.dats" val () = cp "libats_linmap_skiplist.dats" val () = cp "libats_linset_listord.dats" val () = cp "libats_linordset_randbst.dats" // val () = cp "libats_linbitvec.dats" val () = cp "libats_linheap_binomial.dats" // val () = cp "libats_rarray.dats" val () = cp "libats_refcount.dats" val () = cp "libats_regexp.dats" val () = cp "libats_parworkshop.dats" val () = cp "libats_vector.dats" // val () = cp "libats_ngc_slist.dats" val () = cp "libats_ngc_dlist.dats" // val () = cp "libats_ngc_linmap_avltree.dats" val () = cp "libats_ngc_linmap_pavltree.dats" // val () = cp "libats_smlbas_array.dats" val () = cp "libats_smlbas_array2.dats" val () = cp "libats_smlbas_char.dats" val () = cp "libats_smlbas_list.dats" val () = cp "libats_smlbas_string.dats" val () = cp "libats_smlbas_time.dats" } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_KR = SRCROOTdoc_EXAMPLE ++ "KernighanRitchie/" val DSTROOTdoc_EXAMPLE_KR = DSTROOTdoc_EXAMPLE ++ "KernighanRitchie/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_KR, DIRmode) #define NCHAPTER 8 val () = fcp_Makefile (SRCROOTdoc_EXAMPLE_KR, DSTROOTdoc_EXAMPLE_KR) var !p_arr with pf_arr = @[string]( "Chapter01/", "Chapter02/", "Chapter03/", "Chapter04/" , "Chapter05/", "Chapter06/", "Chapter07/", "Chapter08/" ) // end of [var] val () = loop (!p_arr, 0) where { fun loop ( names: &(@[string][NCHAPTER]), i: natLte NCHAPTER ) : void = if i < NCHAPTER then let val name = names.[i] val src = SRCROOTdoc_EXAMPLE_KR ++ name val dst = DSTROOTdoc_EXAMPLE_KR ++ name val () = mkdir_exn (dst, DIRmode) val () = fcopy_exn (src ++ "Makefile", dst ++ "Makefile") val () = dir_copy (src, dst, name_is_xats) in loop (names, i+1) end // end of [if] } // end of [val] } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_AUP = SRCROOTdoc_EXAMPLE ++ "AUP/" val DSTROOTdoc_EXAMPLE_AUP = DSTROOTdoc_EXAMPLE ++ "AUP/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_AUP, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_AUP ++ ,(name), DSTROOTdoc_EXAMPLE_AUP ++ ,(name) ) // end of [macdef] val () = cp "Makefile" val () = cp "README" val () = dir_copy (SRCROOTdoc_EXAMPLE_AUP, DSTROOTdoc_EXAMPLE_AUP, name_is_xats) val () = mkdir_exn (DSTROOTdoc_EXAMPLE_AUP ++ "data", DIRmode) val () = cp "data/fruits.txt" val SRCROOTdoc_EXAMPLE_AUP_utils = SRCROOTdoc_EXAMPLE_AUP ++ "utils/" val DSTROOTdoc_EXAMPLE_AUP_utils = DSTROOTdoc_EXAMPLE_AUP ++ "utils/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_AUP_utils, DIRmode) val () = dir_copy (SRCROOTdoc_EXAMPLE_AUP_utils, DSTROOTdoc_EXAMPLE_AUP_utils, name_is_c) val () = dir_copy (SRCROOTdoc_EXAMPLE_AUP_utils, DSTROOTdoc_EXAMPLE_AUP_utils, name_is_xats) } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_MULTICORE = SRCROOTdoc_EXAMPLE ++ "MULTICORE/" val DSTROOTdoc_EXAMPLE_MULTICORE = DSTROOTdoc_EXAMPLE ++ "MULTICORE/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_MULTICORE, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_MULTICORE ++ ,(name), DSTROOTdoc_EXAMPLE_MULTICORE ++ ,(name) ) // end of [macdef] val () = cp "Makefile" val () = dir_copy (SRCROOTdoc_EXAMPLE_MULTICORE, DSTROOTdoc_EXAMPLE_MULTICORE, name_is_xats) } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_cairo = SRCROOTdoc_EXAMPLE ++ "cairo/" val DSTROOTdoc_EXAMPLE_cairo = DSTROOTdoc_EXAMPLE ++ "cairo/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_cairo, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_cairo ++ ,(name), DSTROOTdoc_EXAMPLE_cairo ++ ,(name) ) // end of [macdef] val () = cp "Makefile" val () = dir_copy (SRCROOTdoc_EXAMPLE_cairo, DSTROOTdoc_EXAMPLE_cairo, name_is_xats) } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_GTK = SRCROOTdoc_EXAMPLE ++ "GTK/" val DSTROOTdoc_EXAMPLE_GTK = DSTROOTdoc_EXAMPLE ++ "GTK/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_GTK, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_GTK ++ ,(name), DSTROOTdoc_EXAMPLE_GTK ++ ,(name) ) // end of [macdef] val () = cp "Makefile" val () = dir_copy (SRCROOTdoc_EXAMPLE_GTK, DSTROOTdoc_EXAMPLE_GTK, name_is_xats) } // end of [val] // val () = () where { val SRCROOTdoc_EXAMPLE_OpenGL = SRCROOTdoc_EXAMPLE ++ "OpenGL/" val DSTROOTdoc_EXAMPLE_OpenGL = DSTROOTdoc_EXAMPLE ++ "OpenGL/" val () = mkdir_exn (DSTROOTdoc_EXAMPLE_OpenGL, DIRmode) macdef cp (name) = fcopy_exn ( SRCROOTdoc_EXAMPLE_OpenGL ++ ,(name), DSTROOTdoc_EXAMPLE_OpenGL ++ ,(name) ) // end of [macdef] val () = cp "Makefile" val () = dir_copy (SRCROOTdoc_EXAMPLE_OpenGL, DSTROOTdoc_EXAMPLE_OpenGL, name_is_xats) } // end of [val] // in print "The [doc] directory is successfully copied."; print_newline () end // end of [Anairiats_doc_dir_copy] (* ****** ****** *) fn libdir_copy ( srclibname: string, dstlibname: string ) : void = let val srclibname = string1_of_string srclibname and dstlibname = string1_of_string dstlibname // val srclibname_SATS = srclibname ++ "SATS/" val dstlibname_SATS = dstlibname ++ "SATS/" val () = mkdir_exn (dstlibname_SATS, DIRmode) val () = dir_copy (srclibname_SATS, dstlibname_SATS, name_is_sats) // // DATS is optional val srclibname_DATS = srclibname ++ "DATS/" val () = if file_isexi (srclibname_DATS) then let val dstlibname_DATS = dstlibname ++ "DATS/" val () = mkdir_exn (dstlibname_DATS, DIRmode) in dir_copy (srclibname_DATS, dstlibname_DATS, name_is_dats) end // end of [val] // // CATS is optional val srclibname_CATS = srclibname ++ "CATS/" val () = if file_isexi (srclibname_CATS) then let val dstlibname_CATS = dstlibname ++ "CATS/" val () = mkdir_exn (dstlibname_CATS, DIRmode) in dir_copy (srclibname_CATS, dstlibname_CATS, name_is_cats) end // end of [val] // // HATS is optional val srclibname_HATS = srclibname ++ "HATS/" val () = if file_isexi (srclibname_HATS) then let val dstlibname_HATS = dstlibname ++ "HATS/" val () = mkdir_exn (dstlibname_HATS, DIRmode) in dir_copy (srclibname_HATS, dstlibname_HATS, name_is_hats) end // end of [val] in // empty end // end of [libdir_copy] (* ****** ****** *) fn Anairiats_prelude_dir_copy () = let val SRCROOTprelude = SRCROOT ++ "prelude/" val DSTROOTprelude = DSTROOT ++ "prelude/" macdef cp (name) = fcopy_exn ( SRCROOTprelude ++ ,(name), DSTROOTprelude ++ ,(name) ) val () = mkdir_exn (DSTROOTprelude, DIRmode) val () = libdir_copy (SRCROOTprelude, DSTROOTprelude) val () = cp "fixity.ats" val () = cp "basics_sta.sats" val () = cp "basics_dyn.sats" val () = cp "macrodef.sats" val () = cp "params.hats" val () = cp "params_system.hats" val () = cp "sortdef.sats" val () = cp "ats_main_prelude.dats" in print "The [prelude] directory is successfully copied."; print_newline () end // end of [Anairiats_prelude_dir_copy] fn Anairiats_libc_dir_copy () = let val SRCROOTlibc = SRCROOT ++ "libc/" val DSTROOTlibc = DSTROOT ++ "libc/" val () = mkdir_exn (DSTROOTlibc, DIRmode) val () = libdir_copy (SRCROOTlibc, DSTROOTlibc) // val SRCROOTlibc_sys = SRCROOTlibc ++ "sys/" val DSTROOTlibc_sys = DSTROOTlibc ++ "sys/" val () = mkdir_exn (DSTROOTlibc_sys, DIRmode) val () = libdir_copy (SRCROOTlibc_sys, DSTROOTlibc_sys) // val SRCROOTlibc_arpa = SRCROOTlibc ++ "arpa/" val DSTROOTlibc_arpa = DSTROOTlibc ++ "arpa/" val () = mkdir_exn (DSTROOTlibc_arpa, DIRmode) val () = libdir_copy (SRCROOTlibc_arpa, DSTROOTlibc_arpa) // val SRCROOTlibc_netinet = SRCROOTlibc ++ "netinet/" val DSTROOTlibc_netinet = DSTROOTlibc ++ "netinet/" val () = mkdir_exn (DSTROOTlibc_netinet, DIRmode) val () = libdir_copy (SRCROOTlibc_netinet, DSTROOTlibc_netinet) // val SRCROOTlibc_gdbm = SRCROOTlibc ++ "gdbm/" val DSTROOTlibc_gdbm = DSTROOTlibc ++ "gdbm/" val () = mkdir_exn (DSTROOTlibc_gdbm, DIRmode) val () = libdir_copy (SRCROOTlibc_gdbm, DSTROOTlibc_gdbm) // in print "The [libc] directory is successfully copied."; print_newline () end // end of [Anairiats_libc_dir_copy] fn Anairiats_libats_dir_copy () = let // the code for libats val SRCROOTlibats = SRCROOT ++ "libats/" val DSTROOTlibats = DSTROOT ++ "libats/" val () = mkdir_exn (DSTROOTlibats, DIRmode) val () = libdir_copy (SRCROOTlibats, DSTROOTlibats) // the code for [libats/ngc] val SRCROOTlibats_ngc = SRCROOTlibats ++ "ngc/" val DSTROOTlibats_ngc = DSTROOTlibats ++ "ngc/" val () = mkdir_exn (DSTROOTlibats_ngc, DIRmode) val () = libdir_copy (SRCROOTlibats_ngc, DSTROOTlibats_ngc) // the code for sml basis library is in [libats/smlbas] val SRCROOTlibats_smlbas = SRCROOTlibats ++ "smlbas/" val DSTROOTlibats_smlbas = DSTROOTlibats ++ "smlbas/" val () = mkdir_exn (DSTROOTlibats_smlbas, DIRmode) val () = fcopy_exn ( SRCROOTlibats_smlbas++".libfiles", DSTROOTlibats_smlbas++".libfiles" ) (* end of [val] *) val () = libdir_copy (SRCROOTlibats_smlbas, DSTROOTlibats_smlbas) // the code for ATS lexer is in [libats/lex] val SRCROOTlibatslex = SRCROOTlibats ++ "lex/" val DSTROOTlibatslex = DSTROOTlibats ++ "lex/" val () = mkdir_exn (DSTROOTlibatslex, DIRmode) val () = dir_copy (SRCROOTlibatslex, DSTROOTlibatslex, name_is_xats) in print "The [libats] directory is successfully copied."; print_newline () end // end of [Anairiats_libats_dir_copy] fn Anairiats_libatsdoc_dir_copy () = let // the code for libats val SRCROOTlibatsdoc = SRCROOT ++ "libatsdoc/" val DSTROOTlibatsdoc = DSTROOT ++ "libatsdoc/" macdef cp name = fcopy_exn (SRCROOTlibatsdoc ++ ,(name), DSTROOTlibatsdoc ++ ,(name)) val () = mkdir_exn (DSTROOTlibatsdoc, DIRmode) val () = cp "Makefile" val () = cp "Makefile_inp" val () = cp "dynloadall.dats" // val () = libdir_copy (SRCROOTlibatsdoc, DSTROOTlibatsdoc) // in print "The [libatsdoc] directory is successfully copied."; print_newline () end // end of [Anairiats_libatsdoc_dir_copy] fn Anairiats_contrib_dir_copy (knd: packnd) = let val SRCROOTcontrib = SRCROOT ++ "contrib/" val DSTROOTcontrib = DSTROOT ++ "contrib/" val () = mkdir_exn (DSTROOTcontrib, DIRmode) // val () = () where { // API for parcomb: [contrib/parcomb] val SRCROOTcontrib_parcomb = SRCROOTcontrib ++ "parcomb/" val DSTROOTcontrib_parcomb = DSTROOTcontrib ++ "parcomb/" macdef cp name = fcopy_exn (SRCROOTcontrib_parcomb ++ ,(name), DSTROOTcontrib_parcomb ++ ,(name)) val () = mkdir_exn (DSTROOTcontrib_parcomb, DIRmode) val () = cp "Makefile" val () = cp "dynloadall.dats" // val () = libdir_copy (SRCROOTcontrib_parcomb, DSTROOTcontrib_parcomb) val SRCROOTcontrib_parcomb_TEST = SRCROOTcontrib_parcomb ++ "TEST/" val DSTROOTcontrib_parcomb_TEST = DSTROOTcontrib_parcomb ++ "TEST/" val () = mkdir_exn (DSTROOTcontrib_parcomb_TEST, DIRmode) val () = dir_copy_all (SRCROOTcontrib_parcomb_TEST, DSTROOTcontrib_parcomb_TEST) } // end of [where] // val () = () where { // API for cblas: [contrib/cblas] val SRCROOTcontrib_cblas = SRCROOTcontrib ++ "cblas/" val DSTROOTcontrib_cblas = DSTROOTcontrib ++ "cblas/" val () = mkdir_exn (DSTROOTcontrib_cblas, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_cblas, DSTROOTcontrib_cblas) val () = libdir_copy (SRCROOTcontrib_cblas, DSTROOTcontrib_cblas) val SRCROOTcontrib_cblas_TEST = SRCROOTcontrib_cblas ++ "TEST/" val DSTROOTcontrib_cblas_TEST = DSTROOTcontrib_cblas ++ "TEST/" val () = mkdir_exn (DSTROOTcontrib_cblas_TEST, DIRmode) val () = dir_copy_all (SRCROOTcontrib_cblas_TEST, DSTROOTcontrib_cblas_TEST) } // end of [where] // val () = () where { // API for clapack: [contrib/clapack] val SRCROOTcontrib_clapack = SRCROOTcontrib ++ "clapack/" val DSTROOTcontrib_clapack = DSTROOTcontrib ++ "clapack/" val () = mkdir_exn (DSTROOTcontrib_clapack, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_clapack, DSTROOTcontrib_clapack) val () = libdir_copy (SRCROOTcontrib_clapack, DSTROOTcontrib_clapack) val SRCROOTcontrib_clapack_TEST = SRCROOTcontrib_clapack ++ "TEST/" val DSTROOTcontrib_clapack_TEST = DSTROOTcontrib_clapack ++ "TEST/" val () = mkdir_exn (DSTROOTcontrib_clapack_TEST, DIRmode) val () = dir_copy_all (SRCROOTcontrib_clapack_TEST, DSTROOTcontrib_clapack_TEST) } // end of [where] // val () = () where { // API for glib: [contrib/glib] val SRCROOTcontrib_glib = SRCROOTcontrib ++ "glib/" val DSTROOTcontrib_glib = DSTROOTcontrib ++ "glib/" val () = mkdir_exn (DSTROOTcontrib_glib, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_glib, DSTROOTcontrib_glib) val () = libdir_copy (SRCROOTcontrib_glib, DSTROOTcontrib_glib) val DSTROOTcontrib_glib_SATS_glib = DSTROOTcontrib_glib ++ "SATS/glib/" val () = mkdir_exn (DSTROOTcontrib_glib_SATS_glib, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "glib/SATS/glib/", DSTROOTcontrib_glib_SATS_glib, name_is_sats ) // end of [val] val DSTROOTcontrib_glib_SATS_gobject = DSTROOTcontrib_glib ++ "SATS/gobject/" val () = mkdir_exn (DSTROOTcontrib_glib_SATS_gobject, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "glib/SATS/gobject/", DSTROOTcontrib_glib_SATS_gobject, name_is_sats ) // end of [val] val DSTROOTcontrib_glib_CATS_glib = DSTROOTcontrib_glib ++ "CATS/glib/" val () = mkdir_exn (DSTROOTcontrib_glib_CATS_glib, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "glib/CATS/glib/", DSTROOTcontrib_glib_CATS_glib, name_is_cats ) // end of [val] val () = fcopy_exn ( SRCROOTcontrib ++ "glib/HATS/glibconfig_hats", DSTROOTcontrib ++ "glib/HATS/glibconfig_hats" ) // end of [val] } // end of [where] // val () = () where { // API for cairo: [contrib/cairo] val SRCROOTcontrib_cairo = SRCROOTcontrib ++ "cairo/" val DSTROOTcontrib_cairo = DSTROOTcontrib ++ "cairo/" val () = mkdir_exn (DSTROOTcontrib_cairo, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_cairo, DSTROOTcontrib_cairo) val () = libdir_copy (SRCROOTcontrib_cairo, DSTROOTcontrib_cairo) } // end of [where] // val () = () where { // API for pango: [contrib/pango] val SRCROOTcontrib_pango = SRCROOTcontrib ++ "pango/" val DSTROOTcontrib_pango = DSTROOTcontrib ++ "pango/" val () = mkdir_exn (DSTROOTcontrib_pango, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_pango, DSTROOTcontrib_pango) val () = libdir_copy (SRCROOTcontrib_pango, DSTROOTcontrib_pango) val DSTROOTcontrib_pango_SATS_pango = DSTROOTcontrib_pango ++ "SATS/pango/" val () = mkdir_exn (DSTROOTcontrib_pango_SATS_pango, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "pango/SATS/pango/", DSTROOTcontrib_pango_SATS_pango, name_is_sats ) // end of [val] } // end of [where] // val () = () where { // API for X11: [contrib/X11] val SRCROOTcontrib_X11 = SRCROOTcontrib ++ "X11/" val DSTROOTcontrib_X11 = DSTROOTcontrib ++ "X11/" val () = mkdir_exn (DSTROOTcontrib_X11, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_X11, DSTROOTcontrib_X11) val () = libdir_copy (SRCROOTcontrib_X11, DSTROOTcontrib_X11) } // end of [where] // val () = () where { // API for GTK: [contrib/GTK] val SRCROOTcontrib_GTK = SRCROOTcontrib ++ "GTK/" val DSTROOTcontrib_GTK = DSTROOTcontrib ++ "GTK/" val () = mkdir_exn (DSTROOTcontrib_GTK, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_GTK, DSTROOTcontrib_GTK) val () = libdir_copy (SRCROOTcontrib_GTK, DSTROOTcontrib_GTK) val DSTROOTcontrib_GTK_SATS_gtk = DSTROOTcontrib_GTK ++ "SATS/gtk/" val () = mkdir_exn (DSTROOTcontrib_GTK_SATS_gtk, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "GTK/SATS/gtk/", DSTROOTcontrib_GTK_SATS_gtk, name_is_sats ) // end of [val] val DSTROOTcontrib_GTK_SATS_gdk = DSTROOTcontrib ++ "GTK/SATS/gdk/" val () = mkdir_exn (DSTROOTcontrib_GTK_SATS_gdk, DIRmode) val () = dir_copy ( SRCROOTcontrib ++ "GTK/SATS/gdk/", DSTROOTcontrib_GTK_SATS_gdk, name_is_sats ) // end of [val] } // end of [where] // val () = () where { // API for GL: [contrib/GL] val SRCROOTcontrib_GL = SRCROOTcontrib ++ "GL/" val DSTROOTcontrib_GL = DSTROOTcontrib ++ "GL/" val () = mkdir_exn (DSTROOTcontrib_GL, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_GL, DSTROOTcontrib_GL) val () = libdir_copy (SRCROOTcontrib_GL, DSTROOTcontrib_GL) } // end of [where] // val () = () where { // API for SDL: [contrib/SDL] val SRCROOTcontrib_SDL = SRCROOTcontrib ++ "SDL/" val DSTROOTcontrib_SDL = DSTROOTcontrib ++ "SDL/" val () = mkdir_exn (DSTROOTcontrib_SDL, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_SDL, DSTROOTcontrib_SDL) val () = libdir_copy (SRCROOTcontrib_SDL, DSTROOTcontrib_SDL) } // end of [where] // val () = () where { // API for mysql: [contrib/mysql] val SRCROOTcontrib_mysql = SRCROOTcontrib ++ "mysql/" val DSTROOTcontrib_mysql = DSTROOTcontrib ++ "mysql/" val () = mkdir_exn (DSTROOTcontrib_mysql, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_mysql, DSTROOTcontrib_mysql) val () = libdir_copy (SRCROOTcontrib_mysql, DSTROOTcontrib_mysql) val SRCROOTcontrib_mysql_TEST = SRCROOTcontrib_mysql ++ "TEST/" val DSTROOTcontrib_mysql_TEST = DSTROOTcontrib_mysql ++ "TEST/" val () = mkdir_exn (DSTROOTcontrib_mysql_TEST, DIRmode) val () = dir_copy_all (SRCROOTcontrib_mysql_TEST, DSTROOTcontrib_mysql_TEST) } // end of [where] // val () = () where { // API for jansson: [contrib/jansson] val SRCROOTcontrib_jansson = SRCROOTcontrib ++ "jansson/" val DSTROOTcontrib_jansson = DSTROOTcontrib ++ "jansson/" val () = mkdir_exn (DSTROOTcontrib_jansson, DIRmode) val () = fcp_Makefile (SRCROOTcontrib_jansson, DSTROOTcontrib_jansson) val () = libdir_copy (SRCROOTcontrib_jansson, DSTROOTcontrib_jansson) val SRCROOTcontrib_jansson_TEST = SRCROOTcontrib_jansson ++ "TEST/" val DSTROOTcontrib_jansson_TEST = DSTROOTcontrib_jansson ++ "TEST/" val () = mkdir_exn (DSTROOTcontrib_jansson_TEST, DIRmode) val () = dir_copy_all (SRCROOTcontrib_jansson_TEST, DSTROOTcontrib_jansson_TEST) } // end of [where] // val () = () where { // [contrib/testing] val SRCROOTcontrib_testing = SRCROOTcontrib ++ "testing/" val DSTROOTcontrib_testing = DSTROOTcontrib ++ "testing/" val () = mkdir_exn (DSTROOTcontrib_testing, DIRmode) (* val () = fcp_Makefile (SRCROOTcontrib_testing, DSTROOTcontrib_testing) *) val () = libdir_copy (SRCROOTcontrib_testing, DSTROOTcontrib_testing) } // end of [where] // in print "The [contrib] directory is successfully copied."; print_newline () end // end of [Anairiats_contrib_dir_copy] (* ****** ****** *) (* fn Anairiats_src_dir_copy (): void = let fn test (name: string): bool = begin case+ name of | _ when name_is_xats (name) => true | _ => false end // end of [filename_test] macdef cp (name) = fcopy_exn (SRCROOTsrc ++ ,(name), DSTROOTsrc ++ ,(name)) val () = mkdir_exn (DSTROOTsrc, DIRmode) val () = dir_copy (SRCROOTsrc, DSTROOTsrc, test) val () = cp "Makefile" val () = cp "Makefile_bootstrap" val () = cp "ats_grammar_yats.c" val () = cp "ats_grammar_yats.h" in print "The [src] directory is successfully copied."; print_newline () end // end of [Anairiats_src_dir_copy] *) (* ****** ****** *) fn Anairiats_utils_dir_copy () = let val SRCROOTutils = SRCROOT ++ "utils/" val DSTROOTutils = DSTROOT ++ "utils/" val () = mkdir_exn (DSTROOTutils, DIRmode) // val SRCROOTutils_atslex = SRCROOTutils ++ "atslex/" val DSTROOTutils_atslex = DSTROOTutils ++ "atslex/" macdef cp name = fcopy_exn (SRCROOTutils_atslex ++ ,(name), DSTROOTutils_atslex ++ ,(name)) val () = mkdir_exn (DSTROOTutils_atslex, DIRmode) val () = dir_copy (SRCROOTutils_atslex, DSTROOTutils_atslex, name_is_xats) val () = cp "README" val () = cp "Makefile" // val SRCROOTutils_atslex_EXAMPLE = SRCROOTutils_atslex ++ "EXAMPLE/" val DSTROOTutils_atslex_EXAMPLE = DSTROOTutils_atslex ++ "EXAMPLE/" val () = mkdir_exn (DSTROOTutils_atslex_EXAMPLE, DIRmode) val () = dir_copy (SRCROOTutils_atslex_EXAMPLE, DSTROOTutils_atslex_EXAMPLE, name_is_xats) val () = fcp_Makefile (SRCROOTutils_atslex_EXAMPLE, DSTROOTutils_atslex_EXAMPLE) // val SRCROOTutils_scripts = SRCROOTutils ++ "scripts/" val DSTROOTutils_scripts = DSTROOTutils ++ "scripts/" macdef cp name = fcopy_exn (SRCROOTutils_scripts ++ ,(name), DSTROOTutils_scripts ++ ,(name)) val () = mkdir_exn (DSTROOTutils_scripts, DIRmode) val () = dir_copy (SRCROOTutils_scripts, DSTROOTutils_scripts, name_is_xats) val () = cp "Makefile" // val SRCROOTutils_atsdoc = SRCROOTutils ++ "atsdoc/" val DSTROOTutils_atsdoc = DSTROOTutils ++ "atsdoc/" macdef cp name = fcopy_exn (SRCROOTutils_atsdoc ++ ,(name), DSTROOTutils_atsdoc ++ ,(name)) val () = mkdir_exn (DSTROOTutils_atsdoc, DIRmode) val () = dir_copy (SRCROOTutils_atsdoc, DSTROOTutils_atsdoc, name_is_xats) (* val () = cp "README" *) val () = cp "Makefile" val () = libdir_copy (SRCROOTutils_atsdoc, DSTROOTutils_atsdoc) // in print "The [utils] directory is successfully copied."; print_newline () end // end of [Anairiats_utils_dir_copy] (* ****** ****** *) extern fun atspack_source_code (): void implement atspack_source_code () = let val () = // run-time checking if test_file_exists (DSTROOT) then begin print "The directory ["; print DSTROOT; print "] already exists."; print_newline (); exit (1) end // end of [if] val () = mkdir_exn (DSTROOT, DIRmode) macdef cp name = fcopy_exn (SRCROOT ++ ,(name), DSTROOT ++ ,(name)) macdef cp2 name1 name2 = fcopy_exn (SRCROOT ++ ,(name1), DSTROOT ++ ,(name2)) macdef cpx (name) = let val src_name = SRCROOT ++ ,(name) val dst_name = DSTROOT ++ ,(name) val () = fcopy_exn (src_name, dst_name) val () = chmod_exn (dst_name, $STAT.S_IRWXU) in // empty end // end of [cpx] val () = cp "INSTALL" val () = cp "VERSION.txt" val () = cp2 "Makefile_dist" "Makefile" val () = cp2 "Makefile_macosx" "Makefile_macosx" val () = cp2 "Makefile_bootstrap" "Makefile_bootstrap" // val () = cp "ats_env.sh.in" // val () = cp "config.mk.in" val () = cp "config.h.in" // in case [autoheader] is not available // val () = cp "configure.ac" val () = cpx "configure" // in case [autoconf] is not available ... (* val () = cpx "install-sh"; val () = cpx "missing" *) // val () = cp "test.sh.in" // val () = cp ".libfiles" val () = cp ".libfiles_mt" // val () = Anairiats_bin_dir_copy (PACKNDsource) val () = Anairiats_bootstrap_dir_copy () val () = Anairiats_ccomp_dir_copy (PACKNDsource) val () = Anairiats_doc_dir_copy () val () = Anairiats_prelude_dir_copy () val () = Anairiats_libc_dir_copy () val () = Anairiats_libats_dir_copy () val () = Anairiats_libatsdoc_dir_copy () val () = Anairiats_contrib_dir_copy (PACKNDsource) (* val () = Anairiats_src_dir_copy () // HX: The source code is no longer distributed *) val () = Anairiats_utils_dir_copy () // in print "The package ["; print ATSPACKAGE_NAME; print "-"; print ATSPACKAGE_VERSION; print "] is successfully built."; print_newline () end // end of [atspack_source_code] (* ****** ****** *) extern fun atspack_precompiled (): void implement atspack_precompiled () = let val () = // run-time checking if test_file_exists (DSTROOT) then begin prerr "The directory ["; prerr DSTROOT; prerr "] already exists."; prerr_newline (); exit (1) end // end of [if] val () = mkdir_exn (DSTROOT, DIRmode) macdef cp (name) = fcopy_exn (SRCROOT ++ ,(name), DSTROOT ++ ,(name)) val () = cp "INSTALL" val () = cp "config.h" val () = Anairiats_bin_dir_copy (PACKNDprecompiled) val () = Anairiats_ccomp_dir_copy (PACKNDprecompiled) val () = Anairiats_doc_dir_copy () val () = Anairiats_prelude_dir_copy () val () = Anairiats_libc_dir_copy () val () = Anairiats_libats_dir_copy () val () = Anairiats_contrib_dir_copy (PACKNDprecompiled) in // empty end // end of [atspack_precompiled] (* ****** ****** *) fn do_usage (cmd: string): void = () where { val () = printf ("%s [flag] [kind]\n", @(cmd)) val () = printf (" where flag is -m32 or -m64, and [kind] is --source or --precompiled.\n", @()) } // end of [do_usage] (* ****** ****** *) implement main (argc, argv) = let // fun loop {n,i:nat | i <= n} .. ( argc: int n, argv: &(@[string][n]), i: int i, cnt: &int ) : void = if i < argc then let val x = argv.[i] val () = case+ 0 of | _ when x = "--source" => ( cnt := cnt+1; atspack_source_code () ) | _ when x = "--precompiled" => ( cnt := cnt+1; atspack_precompiled () ) | _ when x = "-m32" => wordsize_target_set (4(*bytes*)) | _ when x = "-m64" => wordsize_target_set (8(*bytes*)) | _ when x = "--help" => do_usage (argv.[0]) | _ => let val () = prerrf ("[%s]: unrecognized flag: %s\n", @(argv.[0], x)) in // nothing end // end of [_] in if cnt = 0 then loop (argc, argv, i+1, cnt) end // end of [if] (* end of [loop] *) // var cnt: int = 0 val () = loop (argc, argv, 1, cnt) val () = if cnt = 0 then do_usage (argv.[0]) // in // nothing end // end of [main] (* ****** ****** *) (* end of [atspack.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/Makefile0000664000175000017500000001213612223166166020273 0ustar hwxihwxi######################################################################### # # # Applied Type System # # # # Hongwei Xi # # # ######################################################################### # # ATS - Unleashing the Power of Types! # # Copyright (C) 2002-2007 Hongwei Xi. # # ATS is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free # Software Foundation; either version 2.1, or (at your option) any later # version. # # ATS is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with ATS; see the file COPYING. If not, write to the Free # Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # ###### ATSHOMEQ="$(ATSHOME)" ATSOPT=$(ATSHOMEQ)/bin/atsopt ATSRUNTIME=$(ATSHOMEQ)/ccomp/runtime ATSLIBC=$(ATSHOMEQ)/libc ATSCC=$(ATSHOMEQ)/bin/atscc CC=gcc INCLUDES=-I$(ATSHOMEQ) -I$(ATSRUNTIME) CCFLAGS=-O2 -g ###### all: atscc atslib echo "[atscc] and [atslib] have been generated." ###### atscc: atscc_main_dats.c \ top_sats.o basics_dats.o pkgconfig.o atscc_dats.o \ errno_sats.o fcntl_sats.o stdio_sats.o stdlib_sats.o string_sats.o unistd_sats.o \ sys_types_sats.o sys_wait_sats.o $(CC) $(INCLUDES) $(CCFLAGS) -o atscc atscc_main_dats.c $(ATSRUNTIME)/ats_prelude.c \ top_sats.o basics_dats.o pkgconfig.o atscc_dats.o \ errno_sats.o fcntl_sats.o stdio_sats.o stdlib_sats.o string_sats.o unistd_sats.o \ sys_types_sats.o sys_wait_sats.o ###### atslib: atslib_main_dats.c \ top_sats.o basics_dats.o atscc_dats.o atslib_dats.o \ fcntl_sats.o stdio_sats.o stdlib_sats.o unistd_sats.o \ sys_types_sats.o sys_wait_sats.o $(CC) $(INCLUDES) $(CCFLAGS) -o atslib atslib_main_dats.c $(ATSRUNTIME)/ats_prelude.c \ top_sats.o basics_dats.o atscc_dats.o atslib_dats.o \ fcntl_sats.o stdio_sats.o stdlib_sats.o unistd_sats.o \ sys_types_sats.o sys_wait_sats.o ###### atspack: atspack.dats $(ATSCC) -o atspack $(CCFLAGS) atspack.dats ###### deltabs: deltabs.dats $(ATSCC) -o deltabs $(CCFLAGS) deltabs.dats -D_ATS_gcats ###### top_sats.c: top.sats $(ATSOPT) --output $@ --static top.sats top_sats.o: top_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c top_sats.c basics_dats.c: top.sats basics.dats $(ATSOPT) --output $@ --dynamic basics.dats basics_dats.o: basics_dats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c basics_dats.c ###### pkgconfig_dats.c: pkgconfig.dats $(ATSOPT) --output $@ --dynamic pkgconfig.dats pkgconfig.o: pkgconfig_dats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c pkgconfig_dats.c ###### atscc_dats.c: top.sats atscc.dats $(ATSOPT) --output $@ --dynamic atscc.dats atscc_dats.o: atscc_dats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c atscc_dats.c atscc_main_dats.c: atscc_main.dats $(ATSOPT) --output $@ --dynamic atscc_main.dats ###### atslib_dats.c: top.sats atslib.dats $(ATSOPT) --output $@ --dynamic atslib.dats atslib_dats.o: atslib_dats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c atslib_dats.c atslib_main_dats.c: atslib_main.dats $(ATSOPT) --output $@ --dynamic atslib_main.dats ###### errno_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/errno.sats errno_sats.o: errno_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c errno_sats.c fcntl_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/fcntl.sats fcntl_sats.o: fcntl_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c fcntl_sats.c stdio_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/stdio.sats stdio_sats.o: stdio_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c stdio_sats.c stdlib_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/stdlib.sats stdlib_sats.o: stdlib_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c stdlib_sats.c string_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/string.sats string_sats.o: string_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c string_sats.c unistd_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/SATS/unistd.sats unistd_sats.o: unistd_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c unistd_sats.c sys_types_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/sys/SATS/types.sats sys_types_sats.o: sys_types_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c sys_types_sats.c sys_wait_sats.c: $(ATSOPT) --output $@ --static $(ATSLIBC)/sys/SATS/wait.sats sys_wait_sats.o: sys_wait_sats.c $(CC) $(INCLUDES) $(CCFLAGS) -o $@ -c sys_wait_sats.c ###### clean:: rm -f *_sats.c *_dats.c *.o *~ cleanall:: clean rm -f atscc atslib atspack ###### ats-lang-anairiats-0.2.11/utils/scripts/deltabs.dats0000664000175000017500000001446312223166166021133 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2007 // (* ****** ****** *) // replacing tabs with spaces (* ****** ****** *) staload "libc/SATS/stdio.sats" #define i2c char_of_int (* ****** ****** *) #define SPACES_PER_TAB 8 extern fun getline {m:file_mode} (pf: file_mode_lte (m, r) | out: &FILE m): string extern fun putline {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, str: string): void dataviewtype charlst (int) = | charlst_nil (0) | {n:nat} charlst_cons (n+1) of (char, charlst n) #define nil charlst_nil #define cons charlst_cons #define :: charlst_cons extern fun charlst_is_nil {n:nat} (cs: !charlst n): bool (n == 0) = "charlst_is_nil" implement charlst_is_nil (cs) = case+ cs of | nil _ => (fold@ cs; true) | cons _ => (fold@ cs; false) extern fun charlst_uncons {n:pos} (cs: &charlst n >> charlst (n-1)): char = "charlst_uncons" implement charlst_uncons (cs) = let val ~(c :: cs_r) = cs in cs := cs_r; c end extern fun string_make_charlst_int {n:nat} (cs: charlst n, n: int n): string n = "string_make_charlst_int" %{ ats_ptr_type string_make_charlst_int (ats_ptr_type cs, const ats_int_type n) { char *s0, *s; s0 = ats_malloc_gc(n+1) ; s = s0 + n ; *s = '\0' ; --s ; while (!charlst_is_nil(cs)) { *s = charlst_uncons(&cs) ; --s ; } return s0 ; } %} implement getline {m} (pf | out) = let fun loop {n:nat} (out: &FILE m, cs: charlst n, n: int n): string = let val i = fgetc_err (pf | out) in if i >= 0 then let val c = i2c i in if c <> '\n' then begin loop (out, c :: cs, n+1) end else begin string_make_charlst_int (c :: cs, n+1) end end else begin string_make_charlst_int (cs, n) end end in loop (out, nil (), 0) end (* ****** ****** *) implement putline {m} (pf | out, s) = let // fun prsp {n:nat} .. (out: &FILE m, nsp: int n): void = if nsp > 0 then (fputc_exn (pf |' ', out); prsp (out, nsp-1)) // fun loop{n,i:nat | i <= n} .. ( out: &FILE m, s: string n, n: size_t n, i: size_t i ) : void = if i < n then let val c = s[i] in if (c = '\t') then let val i = int1_of_size1 (i) val nsp = (SPACES_PER_TAB - i nmod SPACES_PER_TAB) in prsp (out, nsp) end else begin fputc_exn (pf | c, out) end; loop (out, s, n, i+1) end // end of [if] // val s = string1_of_string s // in loop (out, s, string_length s, 0) end // end of [putline] (* ****** ****** *) fn fdeltabs ( fil_s: &FILE r, fil_d: &FILE w ) : void = let fun loop (fil_s: &FILE r, fil_d: &FILE w): void = if feof (fil_s) = 0 then let val s = getline (file_mode_lte_r_r | fil_s) in putline (file_mode_lte_w_w | fil_d, s); loop (fil_s, fil_d) end // end of [if] in loop (fil_s, fil_d) end // end of [fdeltabs] (* ****** ****** *) fn deltabs_file_file (src: string, dst: string): void = let val (pf_s_opt | ptr_s) = fopen_err (src, file_mode_r) val () = assert_prerrf_bool1 (ptr_s > null, "Exit: [fopen_err(\"%s\", \"r\")] failed\n", @(src)) prval Some_v pf_s = pf_s_opt val (pf_d_opt | ptr_d) = fopen_err (dst, file_mode_w) val () = assert_prerrf_bool1 (ptr_d > null, "Exit: [fopen_err(\"%s\", \"w\")] failed\n", @(dst)) prval Some_v pf_d = pf_d_opt in fdeltabs (!ptr_s, !ptr_d); fclose_exn (pf_s | ptr_s); fclose_exn (pf_d | ptr_d); end // end of [deltabs_file_file] // // HX: [dst_dir] needs to end with "/" // fn deltabs_file_dir ( src_fil: string, dst_dir: string ) : void = let val dst_fil = dst_dir + src_fil in deltabs_file_file (src_fil, dst_fil) end // end of [deltabs_file_dir] (* ****** ****** *) implement main (argc, argv) = let // val cmd = argv.[0] // val () = if (argc < 2) then begin prerrf ("Usage of [%s]:\n", @(cmd)); prerrf (" 1. %s [-(stdin)]\n", @(cmd)); prerrf (" 2. %s [file(src)]\n", @(cmd)); prerrf (" 3. %s [-(stdin)] [file(dst)]\n", @(cmd)); prerrf (" 4. %s [file(src)] [file(dst)]\n", @(cmd)); prerrf (" 5. %s [file(src)] ... [file(src)] [dir(dst)]\n", @(cmd)); exit (1) end // end of [val] // val () = assert (argc >= 2) // in // case+ argc of | 2 when (argv.[1] = "-") => let val (pf_s | ptr_s) = stdin_get () val (pf_d | ptr_d) = stdout_get () in fdeltabs (!ptr_s, !ptr_d); stdin_view_set (pf_s | (*none*)); stdout_view_set (pf_d | (*none*)) end | 2 => let val (pf_d | ptr_d) = stdout_get () val (pf_s | ptr_s) = fopen_exn (argv.[1], file_mode_r) in fdeltabs (!ptr_s, !ptr_d); fclose_exn (pf_s | ptr_s); stdout_view_set (pf_d | (*none*)) end | 3 when (argv.[1] = "-") => let val (pf_s | ptr_s) = stdin_get () val (pf_d | ptr_d) = fopen_exn (argv.[2], file_mode_w) in fdeltabs (!ptr_s, !ptr_d); fclose_exn (pf_d | ptr_d); stdin_view_set (pf_s | (*none*)) end | 3 => deltabs_file_file (argv.[1], argv.[2]) | _ =>> begin exit_errmsg (1, "not yet supported!\n") end // end of [_] // end // end of [main] (* ****** ****** *) (* end of [deltabs.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/basics.dats0000664000175000017500000003414712223166166020762 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2007 // (* ****** ****** *) staload STDLIB = "libc/SATS/stdlib.sats" (* ****** ****** *) staload "top.sats" (* ****** ****** *) exception Fatal of string (* ****** ****** *) local #include "prelude/params_system.hats" in // in of [local] #if SYSTEM_IS_UNIX_LIKE #then // val dirsep: char = '/' val dirsep_str: string = "/" // #endif end // end of [local] (* ****** ****** *) local val the_wordsize: size_t = sizeof var the_wordsize_target: size_t = the_wordsize val (pfbox_the_wordsize_target | ()) = begin vbox_make_view_ptr {size_t} (view@ the_wordsize_target | &the_wordsize_target) end // end of [val] in // in of [local] implement wordsize_target_get () = let prval vbox pf = pfbox_the_wordsize_target in the_wordsize_target end // end of [wordsize_target_get] implement wordsize_target_set (sz) = let prval vbox pf = pfbox_the_wordsize_target in the_wordsize_target := sz end // end of [wordsize_target_get] end // end of [local] (* ****** ****** *) #define sbp2str string1_of_strbuf implement atsopt_local = "bin/atsopt" implement precats_local = "prelude/CATS/" implement runtime_local = "ccomp/runtime/" implement atslib_local () = let val wsz = wordsize_target_get () val wsz = size1_of_size (wsz) // no-op casting in case+ 0 of | _ when (wsz = 4(*bytes*)) => "ccomp/lib/" | _ when (wsz = 8(*bytes*)) => "ccomp/lib64/" | _ => "ccomp/lib/" end // end of [atslib_local] implement atslib_output_local () = sbp2str (atslib_local () + "output/") // end of [atslib_output_local] implement libats_local () = sbp2str (atslib_local () + "libats.a") // end of [libats_local] // // HX: multithreaded // implement libats_mt_local () = sbp2str (atslib_local () + "libats_mt.a") // end of [libats_mt_local] (* ****** ****** *) local #define ATSHOME_var "ATSHOME" in // in of [local] fn ATSHOME_get (): String = let val (fpf_x | x) = $STDLIB.getenv ATSHOME_var in if strptr_isnot_null (x) then let val x1 = strptr_dup (x) prval () = fpf_x (x) val x1 = string_of_strptr (x1) in string1_of_string (x1) end else let prval () = fpf_x (x) in prerr "The environment variable ["; prerr ATSHOME_var; prerr "] is undefined!"; prerr_newline (); $raise (Fatal "ATSHOME_get") end (* end of [if] *) end // end of [ATSHOME_get] end // end of [local] (* ****** ****** *) implement ATSHOME_dir = let val ATSHOME = ATSHOME_get () val n = string_length ATSHOME in if n > 0 then if ATSHOME[n-1] = dirsep then ATSHOME else sbp2str (ATSHOME + dirsep_str) else begin prerr "The variable [ATSHOME] is empty!\n" ; $raise (Fatal "ATSHOME") end (* end of [if] *) end // end of [ATSHOME] implement ATSHOME_dir_append basename = sbp2str (ATSHOME_dir + (string1_of_string basename)) // end of [ATSHOME_dir_append] (* ****** ****** *) implement strptr_dup (p) = let val str = __cast (p) where { extern castfn __cast {l:agz} (p: !strptr l):<> String } // end of [val] val n = string1_length (str) val str2 = string_make_substring (str, 0, n) in strptr_of_strbuf (str2) end // end of [strptr_dup] (* ****** ****** *) local #define ATSCCOMP_def "gcc" #define ATSCCOMP_var "ATSCCOMP" in // in of [local] implement ATSCCOMP_gcc = let val (fpf_x | x) = $STDLIB.getenv ATSCCOMP_var in if strptr_isnot_null (x) then let val x1 = strptr_dup (x) prval () = fpf_x (x) val x1 = string_of_strptr (x1) in (string1_of_string)x1 end else let prval () = fpf_x (x) in ATSCCOMP_def end (* end of [if] *) end // end of [ATSCCOMP_gcc] end // end of [local] (* ****** ****** *) implement basename_of_filename name = let val name = string1_of_string name val n = string_length name val i = string_index_of_char_from_right (name, dirsep) in if (i >= 0) then let val i = size1_of_ssize1 (i) val () = assert_prerrf_bool1 (i < n, "[basename_of(%s)] failed.\n", @(name)) val sbp = string_make_substring (name, i+1, n-i-1) in sbp2str (sbp) end else begin name (* [name] containing no [dirsep] *) end // end of [if] end // end of [basename_of_filename] implement suffix_of_filename name = let val name = string1_of_string name val i = string_index_of_char_from_right (name, '.') in if i >= 0 then let val i = size1_of_ssize1 (i) val n = string_length name val str = sbp2str (string_make_substring (name, i+1, n-i-1)) in stropt_some (str) end else begin stropt_none (* [name] containing no [dirsep] *) end // end of [if] end // end of [suffix_of_filename] implement filename_is_local name = let val name = string1_of_string name in if string1_isnot_empty (name) then let val _0 = size1_of_int1 0 in if string_get_char_at (name, _0) <> dirsep then true else false end else true end // end of [filename_is_local] (* ****** ****** *) implement atsopt_global = ATSHOME_dir_append atsopt_local implement precats_global = ATSHOME_dir_append precats_local implement runtime_global = ATSHOME_dir_append runtime_local implement atslib_global () = ATSHOME_dir_append (atslib_local ()) implement atslib_output_global () = ATSHOME_dir_append (atslib_output_local ()) implement libats_global () = ATSHOME_dir_append (libats_local ()) implement libats_mt_global () = ATSHOME_dir_append (libats_mt_local ()) (* ****** ****** *) local #define nil STRLSTnil #define :: STRLSTcons in // in of [local] implement strlst_nil () = STRLSTnil () implement strlst_is_nil (ss) = case+ ss of nil () => true | _ :: _ => false implement strlst_head_get (ss) = let val+ s :: _ = ss in s end implement strlst_tail_get (ss) = let val+ _ :: ss = ss in ss end implement strlst_length {n} (ss) = let fun aux {i,j:nat | i+j == n} .. (ss: strlst i, res: size_t j): size_t n = case+ ss of nil () => res | _ :: ss => aux (ss, res+1) // end of [aux] in aux (ss, size1_of_int1 0) end // end of [strlst_length] implement strlst_reverse {n} ss = let fun aux {i,j:nat | i+j == n} .. (ss: strlst i, res: strlst j): strlst n = case+ ss of nil () => res | s :: ss => aux (ss, s :: res) in aux (ss, nil ()) end // end of [strlst_reverse] end // end of [local] (* ****** ****** *) implement lstrlst_reverse (xs0) = let fun revapp {m,n:nat} .. (xs: lstrlst m, ys: lstrlst n):<> lstrlst (m+n) = case+ xs of | LSTRLSTcons (_, !p_xs1) => let val xs1 = !p_xs1 in !p_xs1 := ys; fold@ xs; revapp (xs1, xs) end // end of [val] | ~LSTRLSTnil () => ys // end of [revapp] in revapp (xs0, LSTRLSTnil ()) end // end of [lstrlst_reverse] (* ****** ****** *) %{^ #include #include #include #include /* ****** ****** */ #include "libc/CATS/stdlib.cats" /* ****** ****** */ ats_void_type // also defined in [prelude/DATS/basics.dats] ats_exit(const ats_int_type ecode) { exit (ecode) ; return ; } ats_void_type // also defined in [prelude/DATS/basics.dats] ats_exit_errmsg ( ats_int_type ecode, ats_ptr_type errmsg ) { fprintf(stderr, "%s", (char*)errmsg) ; exit (ecode) ; return ; } // end of [ats_exit_errmsg] /* ****** ****** */ ats_void_type // also defined in [prelude/DATS/printf.dats] atspre_exit_prerrf ( // [ecode] should be of the type uint8 ats_int_type ecode, const ats_ptr_type fmt, ... ) { va_list ap ; va_start(ap, fmt) ; vfprintf(stderr, (char *)fmt, ap) ; va_end(ap) ; /* fprintf (stderr, "atspre_exit_prerrf: ecode = %i\n", ecode) ; */ exit (ecode) ; return ; // deadcode } // end of [atspre_exit_prerrf] // ats_void_type // also defined in [prelude/DATS/printf.dats] atspre_assert_prerrf ( ats_bool_type assertion, ats_ptr_type fmt, ... ) { int err ; va_list ap ; // if (!assertion) { va_start(ap, fmt) ; err = vfprintf(stderr, (char *)fmt, ap) ; va_end(ap) ; if (err < 0) { ats_exit_errmsg (1, "exit(ATS): [atspre_assert_prerrf]: prerrf failed\n") ; } else { ats_exit_errmsg (1, "exit(ATS): [atspre_assert_prerrf]: assert failed\n") ; } /* end of [if] */ } /* end of [if] */ // return ; } // end of [atspre_assert_prerrf] // // // HX: also defined in [prelude/DATS/printf.dats] // ats_ptr_type atspre_vsprintf_size ( ats_int_type guess, const ats_ptr_type fmt, va_list ap0 ) { int n, sz ; char *res ; va_list ap ; // sz = guess ; // while (1) { va_copy (ap, ap0) ; res = ATS_MALLOC(sz) ; n = vsnprintf(res, sz, (char*)fmt, ap) ; if (n >= 0) { if (n < sz) return res ; sz = n+1 ; ATS_FREE(res) ; continue ; } else { return ((ats_ptr_type)0) ; } // end of [if] } // end of [while] // return (ats_ptr_type)0 ; // deadcode // } // end of [atspre_vsprintf_size] // // HX: also defined in [prelude/DATS/printf.dats] // ats_ptr_type atspre_tostringf_size ( ats_int_type guess, const ats_ptr_type fmt, ... ) { char *res ; va_list ap ; // va_start(ap, fmt); res = (char*)atspre_vsprintf_size (guess, fmt, ap); va_end(ap); if (!res) { ats_exit_errmsg (1, "exit(ATS): [atspre_tostringf_size] failed.\n") ; } // end of [if] // return res ; } // end of [atspre_tostringf_size] /* ****** ****** */ // // HX: also defined in [prelude/DATS/string.dats] // ats_ptr_type atspre_string_make_substring ( ats_ptr_type src0, ats_size_type start, ats_size_type len ) { char *des, *src ; des = ATS_MALLOC(len+1) ; src = ((char*)src0) + start ; memcpy(des, src, len) ; des[len] = '\000' ; return des ; } // end of [atspre_string_make_substring] /* ****** ****** */ extern ats_ptr_type atsopt_global ; ats_bool_type file_is_exec ( ats_ptr_type name ) { struct stat buf ; int ret = stat (name, &buf) ; // if (ret < 0) { atspre_exit_prerrf (1, "exit(ATS): File [%s] does not exist.\n", atsopt_global) ; } // end of [if] // return (S_IXUSR & buf.st_mode) ; } // end of [file_is_exec] /* ****** ****** */ // int reference operations typedef ats_ptr_type ats_intref_type ; ats_intref_type intref_make (ats_int_type i) { int *r ; r = ats_malloc_gc(sizeof(ats_int_type)) ; // HX: GC is not needed *r = i ; return r ; } // end of [intref_make] ats_int_type intref_get (ats_intref_type r) { return *((ats_int_type*)r) ; } // end of [intref_get] ats_void_type intref_set (ats_intref_type r, ats_int_type i) { *((ats_int_type*)r) = i ; return ; } // end of [intref_set] /* ****** ****** */ ats_int_type atslib_fork_exec_and_wait_cloptr_exn (ats_ptr_type f_child) { pid_t pid ; int status, ecode ; pid = fork () ; if (pid < 0) { ats_exit_errmsg (1, "Exit: [fork] failed.\n") ; } if (pid > 0) { wait (&status) ; ATS_FREE (f_child) ; if (status) { if (WIFEXITED(status)) ecode = WEXITSTATUS(status) ; else ecode = EXIT_FAILURE ; // end of [if] exit (ecode) ; } else return (0) ; } // end of [if] /* this is the child */ ((ats_void_type (*)(ats_clo_ptr_type))((ats_clo_ptr_type)f_child)->closure_fun)(f_child) ; _exit (0) ; /* no need to flush STDIN, STDOUT and STDERR */ return 0 ; // deadcode } // end of [atslib_fork_exec_and_wait_cloptr_exn] /* ****** ****** */ extern ats_bool_type strlst_is_nil(ats_ptr_type) ; extern ats_ptr_type strlst_head_get(ats_ptr_type) ; extern ats_ptr_type strlst_tail_get(ats_ptr_type) ; ats_void_type strlst_to_strarr ( ats_sum_ptr_type ss, ats_ptr_type p ) { while (1) { if (strlst_is_nil(ss)) break ; *((ats_ptr_type *)p) = strlst_head_get(ss) ; p = ((ats_ptr_type *)p) + 1 ; ss = strlst_tail_get(ss) ; } /* end of [while] */ return ; } // end of [strlst_to_strarr] #define BUFSZ 64 ats_ptr_type string_trans ( ats_ptr_type s0, ats_clo_ptr_type f ) { int i, sz; char *buf0, *buf1, *p, c, *s ; // sz = BUFSZ ; buf0 = ats_malloc_gc(sz) ; // i = 0 ; p = buf0 ; while (c = *((char *)s0)) { s0 = (char *)s0 + 1 ; s = ((ats_ptr_type (*)(ats_clo_ptr_type, ats_char_type))f->closure_fun)(f, c) ; while (c = *s) { ++s ; if (i == sz) { buf1 = ats_malloc_gc (sz + sz) ; memcpy (buf1, buf0, sz) ; ats_free_gc (buf0); buf0 = buf1 ; p = buf0 + sz ; sz = sz + sz ; } /* end of [if] */ *p = c ; ++i ; ++p ; } /* end of [while] */ } /* end of [while] */ // if (i == sz) { buf1 = ats_malloc_gc(sz+1) ; memcpy (buf1, buf0, sz) ; ats_free_gc (buf0) ; buf0 = buf1 ; } /* end of [if] */ // buf0[i] = '\000' ; return buf0 ; // } // end of [string_trans] // // // HX: for the purpose of bootstrapping; it is already defined in unistd.dats // ats_ptr_type atsutil_getcwd0 () { char *buf, *res ; int sz = 64 ; buf = ats_malloc_gc(sz) ; while (1) { res = getcwd (buf, sz) ; if (!res) { ats_free_gc (buf) ; sz = sz + sz ; buf = ats_malloc_gc (sz) ; continue ; } /* end of [if] */ break ; } /* end of [while] */ return buf ; } // end of [atsutil_getcwd0] %} // end of [%{^] (* ****** ****** *) (* end of [basics.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/pkgconfig.dats0000664000175000017500000002056412223166166021463 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Author: Likai Liu (liulk AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "top.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 (* ****** ****** *) %{^ extern int execvp_with_stdout (char **result, char* argv[]) ; %} (* ****** ****** *) extern fun atscc_pkgconfig {n:nat} (arglst: strlst n, narg: int n): Lstrlst = "atscc_pkgconfig" // end of [atscc_pkgconfig] extern fun shelltok_parse (inp: string): Lstrlst = "shelltok_parse" (* ****** ****** *) extern typedef "lstrlst_t" = lstrlst 0 extern typedef "strlst_t" = STRLSTcons_pstruct (string, strlst 0) %{$ extern void free (void*) ; ats_ptr_type atscc_pkgconfig ( ats_ptr_type arglst, ats_int_type narg ) { char **argv, *buf ; int i, err ; strlst_t toks ; i = 0 ; argv = alloca(1/*cmd*/ + narg + 1/*NULL*/) ; argv[i] = "pkg-config"; i += 1 ; while (arglst != 0) { argv[i] = (char*)(((strlst_t)arglst)->atslab_0); i += 1; arglst = (((strlst_t)arglst)->atslab_1); } /* end of [while] */ argv[i] = (char*)0 ; /* i == narg + 1 */ err = execvp_with_stdout(&buf, argv) ; if (err != 0) { if (buf != 0) free (buf) ; return (ats_ptr_type)0 ; } // end of [if] toks = (lstrlst_t)shelltok_parse (buf) ; free (buf) ; return toks ; } %} (* ****** ****** *) // // HX: The implementation is largely adopted from one written by Likai Liu // in C. I hereby experiment with a programming style involving [alloca] that // I have been considering for some time. // staload STRING = "libc/SATS/string.sats" implement shelltok_parse (inp) = let #define NUL '\0' #define SQUOTE '\'' #define DQUOTE '\"' #define SLASH '\\' #define BUFSZ_INIT 1024 fun loop1 {n,i:nat | i <= n} {bsz:int | bsz >= 1} .. ( inp: string n , i: size_t i, buf: &bytes bsz, bsz: size_t bsz , itms: Lstrlst ) :<> Lstrlst = let val c = string_test_char_at (inp, i) in if (c <> NUL) then begin case+ 0 of | _ when char_isspace (c) => loop1 (inp, i+1, buf, bsz, itms) | _ when (c = SQUOTE orelse c = DQUOTE) => loop2 (inp, c(*quote*), 0(*escape*), i+1, buf, bsz, 0, itms) | _ => let val () = buf.[0] := byte_of_char c in loop3 {n,i+1} (inp, NUL(*quote*), 0(*escape*), i+1, buf, bsz, 1, itms) end // end of [_] end else begin itms // loop1 exits end (* end of [if] *) end (* end of [loop1] *) and loop2 {n,i:nat | i <= n} {bsz,k:nat | k < bsz} .. ( inp: string n , quotechar: char, escape: int , i: size_t i, buf: &bytes bsz, bsz: size_t bsz, k: size_t k , itms: Lstrlst ) :<> Lstrlst = let val c = string_test_char_at (inp, i) in if (c <> NUL) then begin case+ 0 of | _ when quotechar <> NUL => begin if c <> quotechar then let val () = buf.[k] := byte_of_char c in loop3 (inp, quotechar, escape, i+1, buf, bsz, k+1, itms) end else begin // this is a closing quote loop2 (inp, NUL(*quote*), 0(*escape*), i+1, buf, bsz, k, itms) end (* end of [if] *) end // end of [_ when ...] | _ when escape > 0 => let // quotechar = NUL val () = buf.[k] := byte_of_char c in loop3 (inp, quotechar, escape, i+1, buf, bsz, k+1, itms) end // end of [_ when ...] | _ when (c = SQUOTE orelse c = DQUOTE) => loop2 (inp, c(*quote*), 0(*escape*), i+1, buf, bsz, k, itms) // end of [_ when ...] | _ when c = SLASH => loop2 (inp, NUL(*quote*), 1(*escape*), i+1, buf, bsz, k, itms) // end of [_ when ...] | _ when char_isspace (c) => let val itm = string_make_substring (__cast buf, 0, k) where { extern castfn __cast (buf: &bytes bsz):<> string (k) } // end of [val] val itm = string1_of_strbuf (itm) in loop1 (inp, i+1, buf, bsz, LSTRLSTcons (itm, itms)) end // end of [_ when ...] | _ => let val () = buf.[k] := byte_of_char c in loop3 (inp, NUL(*quote*), 0(*escape*), i+1, buf, bsz, k+1, itms) end // end of [_] end else let val itm = string_make_substring (__cast buf, 0, k) where { extern castfn __cast (buf: &bytes bsz):<> string (k) } // end of [val] val itm = string1_of_strbuf (itm) // // should an unclosed quote be reported? // in LSTRLSTcons (itm, itms) // loop2 exits end (* end of [if] *) end // end of [loop2] and loop3 {n,i:nat | i <= n} {bsz,k:nat | 1 <= bsz; k <= bsz} .. ( inp: string n , quotechar: char, escape: int , i: size_t i, buf: &bytes bsz, bsz: size_t bsz, k: size_t k , itms: Lstrlst ) :<> Lstrlst = if k < bsz then begin loop2 (inp, quotechar, escape, i, buf, bsz, k, itms) end else let // k = bsz val bsz2 = bsz + bsz var !p_buf1 with pf_buf1 = @[byte][bsz2]() prval () = pf_buf1 := bytes_v_of_b0ytes_v (pf_buf1) val _(*p_buf1*) = $STRING.memcpy (pf_buf1 | p_buf1, buf, k) in loop2 (inp, quotechar, escape, i, !p_buf1, bsz2, k, itms) end // end of [if] // end of [loop3] val inp = string1_of_string (inp) var !p_buf with pf_buf = @[byte][BUFSZ_INIT]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val itms = loop1 (inp, 0, !p_buf, BUFSZ_INIT, LSTRLSTnil ()) in lstrlst_reverse (itms) end (* end of [shelltok_parse] *) (* ****** ****** *) %{$ /* ** Author: Likai Liu (liulk AT cs DOT bu DOT edu); some modification by HX ** Time: Summer, 2009 */ #include /* EINTR */ #include /* perror() */ #include /* malloc(), realloc(), free(), abort() */ #include /* waitpid() */ #include /* pipe(), fork(), execvp() */ #define BUFSZ_INIT 1024 int execvp_with_stdout (char **result, char* argv[]) { *result = NULL; int filedes[2]; if (pipe(filedes) != 0) return -1; pid_t pid = fork(); if (pid == 0) { /* prepare execution of child process. */ dup2(filedes[1], STDOUT_FILENO); close(filedes[0]); close(filedes[1]); execvp(argv[0], argv); perror(argv[0]); abort(); } else if (pid == -1) { close(filedes[0]); close(filedes[1]); return -1; } // end of [if] close(filedes[1]); size_t buf_size = BUFSZ_INIT, buf_used = 0; char *buf = malloc(buf_size); while(1) { if (buf_used >= buf_size) { buf_size *= 2; buf = realloc(buf, buf_size); } ssize_t res = read(filedes[0], buf + buf_used, buf_size - buf_used); if (res == 0) break; else if (res == -1) { if (errno == EINTR) continue; else break; } // end of [if] buf_used += res; } // end of [while] buf[buf_used] = '\0'; close(filedes[0]); int status, ecode ; waitpid(pid, &status, 0); if (WIFEXITED(status)) ecode = WEXITSTATUS(status) ; else ecode = EXIT_FAILURE ; // end of [if] *result = buf ; return ecode ; } %} (* end of [%{^] *) (* ****** ****** *) (* end of [pkgconfig.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/atslib.dats0000664000175000017500000003047112223166166020770 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer 2007 // (* ****** ****** *) staload "libc/SATS/stdio.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "top.sats" (* ****** ****** *) extern fun ar_r_exec (libfile: string, objfile: string): void = "ar_r_exec" // end of [ar_r_exec] // archive with replacement fn ar_r_err (libfile: string, objfile: string): int = begin fork_exec_and_wait_cloptr_exn (lam () => ar_r_exec (libfile, objfile)) end // end of [ar_r_err] // this is equivalent to [ranlib] extern fun ar_s_exec (libfile: string): void = "ar_s_exec" implement ar_s_exn (libfile) = let val status = fork_exec_and_wait_cloptr_exn (lam () => ar_s_exec (libfile)) // end of [val] in if (status != 0) then exit_prerrf {void} (1, "exit(ATS): [ar_s(%s)] failed\n", @(libfile)) // end of [if] end // end of [ar_s_exn] (* ****** ****** *) extern fun gcc_libfile_exec (param_rev: Strlst, infile: string, outfile: string): void = "gcc_libfile_exec" // end of [gcc_libfile_exec] implement gcc_libfile_err (param_rev, infile, outfile) = let val cmd = lam (): void = gcc_libfile_exec (param_rev, infile, outfile) in fork_exec_and_wait_cloptr_exn (cmd) end // end of [gcc_libfile_err] (* ****** ****** *) #define sbp2str string1_of_strbuf extern fun tostringf_size {ts:types} (guess: size_t, fmt: printf_c ts, arg: ts):<> strptr1 = "atspre_tostringf_size" // end of [tostringf_size] fn char_identifize (c: char): String = if char_isalnum c then tostring c else let val i = uint_of_char c val c1 = i / 16U and c2 = i mod 16U val ptr = tostringf_size (4, "_%x%x", @(c1, c2)) val str = string_of_strptr (ptr) in string1_of_string (str) end // end of [if] // end of [char_identifize] implement ccomp_gcc_ar_libfile (param_rev, infile, libfile) = let val sfx = suffix_of_filename infile val flag_stadyn = ( if stropt_is_none sfx then begin exit_prerrf {int} ( 1, "exit(ATS): [%s]: no filename extension\n.", @(infile) ) // end of [exit_prerrf] end else begin case+ stropt_unsome sfx of | "sats" => 0 | "dats" => 1 | _ => exit_prerrf {int} ( 1, "exit(ATS): [%s]: unsupported filename extension\n.", @(infile) ) // end of [exit_prerrf] end // end of [if] ) : int // val infull = ( if filename_is_local infile then let val cwd = getcwd0 () val str = tostringf_size (64, "%s/%s", @(__cast cwd, infile)) where { extern castfn __cast {l:agz} (x: !strptr l): string } // end of [val] val () = strptr_free (cwd) in string_of_strptr (str) end else infile // end of [if] ) : string // val outbase = string_trans (infull, char_identifize) val outfile = sbp2str (atslib_output_global () + outbase) val outfile_c = sbp2str (outfile + ".c") val status = ccomp_file_to_file_err (flag_stadyn, STRLSTnil(*param_ats*), infile, outfile_c) val () = if (status != 0) then exit_prerrf {void} (1, "exit(ATS): [ccomp_gcc_ar_libfile(%s)] failed: ccomp\n", @(infile)) // end of [val] val outfile_o = sbp2str (outfile + ".o") val status = gcc_libfile_err (param_rev, outfile_c, outfile_o) val () = if (status != 0) then begin exit_prerrf {void} (1, "exit(ATS): [ccomp_gcc_ar_libfile(%s)] failed: gcc\n", @(infile)) end // end of [val] val status = ar_r_err (libfile, outfile_o) val () = if (status != 0) then exit_prerrf {void} (1, "exit(ATS): [ccomp_gcc_ar_libfile(%s)] failed: ar\n", @(infile)) // end of [val] in printf ("The file [%s] has been compiled and archived.\n", @(infile)) end // end of [ccomp_gcc_ar_libfile] (* ****** ****** *) extern fun fget_line {m:fm} (pf: file_mode_lte (m, r) | f: &FILE m): String = "atsutil_fget_line" // end of [fget_line] #define i2sz size1_of_int1 fun library_make_loop {m:fm} {l_file:addr} ( param_rev: Strlst, file: &FILE r, dir: String, libfilename: string ) : void = let // fn line_is_comment (name: String): bool = let in if string_isnot_atend (name, 0) then if name[0] = '#' then true else false else true // end of [if] end // end of [line_is_comment] // fun split {n:int} {i0,i:nat | i0 <= i; i <= n} .. ( line: string (n), n: size_t n, i0: size_t i0, i: size_t i ) : List (string) = if i < n then let val c = line[i] in if c != ' ' then split (line, n, i0, i+1) else let val x = string_make_substring (line, i0, i-i0) val x = string_of_strbuf (x) in list_cons (x, split_skip (line, n, i+1)) end end else let val x = string_make_substring (line, i0, n-i0) val x = string_of_strbuf (x) in list_cons (x, list_nil) end // end of [if] and split_skip {n:int} {i:nat | i <= n} .. ( line: string (n), n: size_t n, i: size_t i ) : List (string) = if i < n then let val c = line[i] in if c != ' ' then split (line, n, i, i+1) else split_skip (line, n, i+1) // end of [if] end else list_nil () // end of [if] // end of [split_skip] in if feof (file) <> 0 then () else let val line = fget_line (file_mode_lte_r_r | file) // end of [val] val () = if ~line_is_comment (line) then let val n = string_length (line) val xs = split (line, n, 0, 0) in case+ xs of | list_cons (x, xs) => let val x = string1_of_string x val dirx = sbp2str (dir + x) val param_rev = loop (xs, param_rev) where { fun loop {m,n:nat} (xs: list (string, m), ys: strlst n): strlst (m+n) = case+ xs of | list_cons (x, xs) => loop (xs, STRLSTcons (x, ys)) | list_nil () => ys // end of [loop] } // end of [val] in ccomp_gcc_ar_libfile (param_rev, dirx, libfilename) end // end of [list_cons] | list_nil () => () end // end of [val] in library_make_loop (param_rev, file, dir, libfilename) end (* end of [if] *) end // end of [library_make_loop] (* ****** ****** *) implement libats_make (param_rev) = let val libfiles_local = ATSHOME_dir_append ".libfiles_local" val libats_global = libats_global () val (pf_file | p_file) = fopen_exn (libfiles_local, file_mode_r) val () = library_make_loop (param_rev, !p_file, ATSHOME_dir, libats_global) val () = fclose_exn (pf_file | p_file) val () = ar_s_exn (libats_global) in // nothing end // end of [libats_make] implement libats_mt_make (param_rev) = let val libfiles_mt_local = ATSHOME_dir_append ".libfiles_mt_local" val libats_mt_global = libats_mt_global () val (pf_file | p_file) = fopen_exn (libfiles_mt_local, file_mode_r) val () = library_make_loop (param_rev, !p_file, ATSHOME_dir, libats_mt_global) val () = fclose_exn (pf_file | p_file) val () = ar_s_exn (libats_mt_global) in // nothing end // end of [libats_mt_make] (* ****** ****** *) implement libats_lex_make (param_rev) = let val dir = ATSHOME_dir_append "libats/lex/" val libats_lex_local = sbp2str (atslib_local () + "libats_lex.a") val libats_lex_global = ATSHOME_dir_append (libats_lex_local) in ccomp_gcc_ar_libfile (param_rev, sbp2str (dir + "lexing.sats"), libats_lex_global) ; ccomp_gcc_ar_libfile (param_rev, sbp2str (dir + "lexing.dats"), libats_lex_global) ; ccomp_gcc_ar_libfile (param_rev, sbp2str (dir + "tables.dats"), libats_lex_global) ; ar_s_exn (libats_lex_global) ; end // end of [libats_lex_make] (* ****** ****** *) implement libats_smlbas_make (param_rev) = () where { val smlbas_libfiles = ATSHOME_dir_append "libats/smlbas/.libfiles" val (pf_file | p_file) = fopen_exn (smlbas_libfiles, file_mode_r) val libats_smlbas_local = sbp2str (atslib_local () + "libats_smlbas.a") val libats_smlbas_global = ATSHOME_dir_append (libats_smlbas_local) val () = library_make_loop (param_rev, !p_file, ATSHOME_dir, libats_smlbas_global) val () = fclose_exn (pf_file | p_file) val () = ar_s_exn (libats_smlbas_global) } // end of [libats_smlbas_make] (* ****** ****** *) %{^ #include #include "libc/CATS/stdio.cats" typedef ats_ptr_type ats_string_type ; extern ats_string_type ATSHOME_dir ; extern ats_string_type runtime_global ; extern ats_bool_type strlst_is_nil (ats_ptr_type) ; extern ats_ptr_type strlst_head_get (ats_ptr_type) ; extern ats_ptr_type strlst_tail_get (ats_ptr_type) ; ats_void_type gcc_libfile_exec ( ats_ptr_type param_rev , ats_string_type input_c , ats_string_type output_o ) { int err ; int n, argc ; char **argv, **argv_p, **argv_p1 ; // argc = n = strlst_length (param_rev) ; argc += 1 ; // self(*first*) argc += 2 ; // -I runtime_global argc += 2 ; // -I ATSHOME_dir argc += 2 ; // -c input_c argc += 2 ; // -o output_o argc += 1 ; // nullptr(*last) argv = (char**)malloc (argc * sizeof(ats_ptr_type)) ; if (!argv) { fprintf (stderr, "exit(ATS): gcc_libfile_exec: malloc failed!\n") ; exit (1) ; } // end of [if] argv_p = argv ; *argv_p = "gcc" ; argv_p += 1 ; *argv_p = "-I" ; argv_p += 1 ; *argv_p = runtime_global ; argv_p += 1 ; *argv_p = "-I" ; argv_p += 1 ; *argv_p = ATSHOME_dir ; argv_p += 1 ; argv_p += n ; argv_p1 = argv_p ; while (1) { if (strlst_is_nil (param_rev)) break ; argv_p1 -= 1 ; *argv_p1 = (char*)strlst_head_get (param_rev) ; param_rev = strlst_tail_get (param_rev) ; } // end of [while] *argv_p = "-c" ; argv_p += 1 ; *argv_p = input_c ; argv_p += 1 ; *argv_p = "-o" ; argv_p += 1 ; *argv_p = output_o ; argv_p += 1 ; *argv_p = (char*)0 ; // /* fputs (*argv, stderr) ; argv_p = argv + 1 ; while (*argv_p) { fputc (' ', stderr) ; fputs (*argv_p, stderr) ; argv_p += 1 ; } fputc ('\n', stderr) ; // */ err = execvp("gcc", argv) ; if (err < 0) perror ("ccomp_file_to_file_exec: [execvp] failed: ") ; exit (1) ; // return ; } // end of [gcc_libfile_exec] ats_void_type ar_r_exec (ats_string_type lib, ats_string_type output_o) { // /* fprintf (stderr, "ar -r %s %s\n", (char*)lib, (char*)output_o) ; // */ execlp("ar", "ar", "-r", lib, output_o, (char*)0) ; return ; } // end of [ar_r_exec] ats_void_type ar_s_exec (ats_string_type lib) { // /* fprintf (stderr, "ar -s %s\n", (char*)lib) ; // */ execlp("ar", "ar", "-s", lib, (char*)0) ; return ; } // end of [ar_s_exec] #define INCSZ 1024 ats_string_type atsutil_fget_line (ats_ptr_type file) { int c; int i, sz; char *buf0, *buf1, *p; // if (feof((FILE *)file)) { ats_exit_errmsg (1, (ats_string_type)"exit(ATS): [fget_line] failed: EOF\n"); } // end of [if] // sz = INCSZ; buf0 = (char*)ats_malloc_gc(sz); p = buf0; // while (1) { for (i = 0; i < INCSZ; ++i) { c = fgetc ((FILE *)file) ; if (c == '\n' || c == EOF) { *p = '\000'; return buf0; } *p = c; ++p; } buf1 = (char*)ats_malloc_gc (sz + INCSZ) ; memcpy (buf1, buf0, sz) ; ats_free_gc (buf0) ; buf0 = buf1 ; p = buf0 + sz; sz = sz + INCSZ ; } // end of [while] // return (char*)0 ; // deadcode // } // end of [atsutil_fget_line] %} // end of [%{^] (* ****** ****** *) (* end of [atslib.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/atslib_main.dats0000664000175000017500000001002412223166166021764 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer 2007 // (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" #include "libc/CATS/stdlib.cats" #include "libc/sys/CATS/types.cats" #include "libc/CATS/unistd.cats" %} // end of [%{^] (* ****** ****** *) staload "top.sats" (* ****** ****** *) fn do_usage (cmd: string): void = begin printf ("The usage of %s is:\n", @(cmd)); printf (" 1. %s --libats (* generating [libats.a] *)\n", @(cmd)); printf (" 2. %s --libats_smlbas (* generating [libats_smlbas.a] *)\n", @(cmd)); printf (" 3. %s --libats_lex (* generating [libats_lex.a] *)\n", @(cmd)); printf (" 4. %s (* compiling and archiving it into [libats.a] *) \n", @(cmd)); end // end of [do_usage] (* ****** ****** *) dynload "basics.dats" dynload "atscc.dats" dynload "atslib.dats" (* ****** ****** *) implement main_prelude () = () (* ****** ****** *) implement main {n} (argc, argv) = let var param_rev: Strlst = STRLSTnil () fun loop {i:nat | i <= n} .. ( argc: int n , argv: &(@[string][n]) , i: int i , param_rev: &Strlst ) : void = if i < argc then let val arg = string1_of_string (argv.[i]) val isempty = string_is_atend (arg, 0) val () = if isempty then begin // empty // skip the empty argument end else begin case+ arg of | "--libats" => libats_make (param_rev) | "--libats_mt" => libats_mt_make (param_rev) | "--libats_smlbas" => libats_smlbas_make (param_rev) | "--libats_lex" => libats_lex_make (param_rev) | "-m32" => let val () = wordsize_target_set (4(*bytes*)) // 32-bit target machine in param_rev := STRLSTcons (arg, param_rev) end // end of [m64] | "-m64" => let val () = wordsize_target_set (8(*bytes*)) // 64-bit target machine in param_rev := STRLSTcons (arg, param_rev) end // end of [m64] | _ => if arg[0] = '-' then begin param_rev := STRLSTcons (arg, param_rev) end else let val libats_global = libats_global () val () = ccomp_gcc_ar_libfile (param_rev, arg, libats_global) val () = ar_s_exn (libats_global) // this is equivalent to [ranlib] in // empty end // end of [_] end // end of [val] in loop (argc, argv, i+1, param_rev) end // end of [if] // end of [loop] in case+ argc of | _ when argc >= 2 => loop (argc, argv, 1, param_rev) | _ (* argc = 1 *) => do_usage (argv.[0]) end // end of [main] (* ****** ****** *) (* end of [atslib_main.dats] *) ats-lang-anairiats-0.2.11/utils/scripts/atscc.dats0000664000175000017500000001610012223166166020600 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer 2007 // (* ****** ****** *) staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/wait.sats" (* ****** ****** *) staload "top.sats" (* ****** ****** *) val () = assert_prerrf_bool ( file_is_exec atsopt_global , "The file [%s] is not executable.\n" , @(atsopt_global) ) // end of [val] fn print_usage_of_ccomp_file (): void = print ("Usage: ccomp_file [infile] -output=[outfile]\n") // end of [print_usage_of_comp_file] (* ****** ****** *) extern fun typecheck_file_exec ( flag_stadyn: int, param_rev: Strlst, s: string ) : void = "typecheck_file_exec" implement typecheck_file (flag_stadyn, param_rev, infile) = () where { val cmd = lam (): void = typecheck_file_exec (flag_stadyn, param_rev, infile) val status = fork_exec_and_wait_cloptr_exn (cmd) val status = int1_of_int (status) val (pf_ifexited | ifexited) = WIFEXITED (status) val () = if ifexited then let val code = WEXITSTATUS (pf_ifexited | status) in if code != 0 then exit_prerrf {void} (code, "exit(ATS): [typecheck_file(%s)] failed.\n", @(infile)) // end of [if] end // end of [val] val () = if ~ifexited then begin prerr ("[typecheck_file] is sigtermed\n"); exit(EXIT_FAILURE) end // end of [val] } (* end of [typecheck_file] *) extern fun ccomp_file_to_file_exec (flag_stadyn: int, param_rev: Strlst, s1: string, s2: string): void = "ccomp_file_to_file_exec" implement ccomp_file_to_file_err (flag_stadyn, param_rev, infile, outfile) = let val cmd = lam(): void = ccomp_file_to_file_exec (flag_stadyn, param_rev, infile, outfile) // end of [val] in fork_exec_and_wait_cloptr_exn (cmd) end // end of [ccomp_file_to_file_err] implement ccomp_file_to_file (flag_stadyn, param_rev, infile, outfile) = () where { val status = begin ccomp_file_to_file_err (flag_stadyn, param_rev, infile, outfile) end // end of [val] val status = int1_of_int (status) val (pf_ifexited | ifexited) = WIFEXITED (status) val () = if ifexited then let val code = WEXITSTATUS (pf_ifexited | status) in if (code != 0) then exit_prerrf {void} (code, "exit(ATS): [ccomp_file_to_file(%s, %s)] failed.\n", @(infile, outfile) ) // end of [if] end // end of [val] val () = if ~ifexited then begin prerr ("[compile_file_to_file] is sigtermed\n"); exit(EXIT_FAILURE) end // end of [val] } // end of [ccomp_file_to_file] (* ****** ****** *) extern fun atscc_version_exec (): void = "atscc_version_exec" implement atscc_version () = () where { val status = fork_exec_and_wait_cloptr_exn (lam () => atscc_version_exec ()) // end of [val] val status = int1_of_int (status) val (pf_ifexited | ifexited) = WIFEXITED (status) val () = if ifexited then let val code = WEXITSTATUS (pf_ifexited | status) in if code != 0 then exit_prerrf {void} (code, "exit(ATS): [atscc_version] failed.\n", @()) // end of [if] end // end of [val] val () = if ~ifexited then begin prerr ("[atscc_version] is sigtermed\n"); exit(EXIT_FAILURE) end // end of [val] } // end of [atscc_version] (* ****** ****** *) %{^ #include #include // extern ats_ptr_type atsopt_global ; // extern ats_bool_type strlst_is_nil (ats_ptr_type) ; extern ats_ptr_type strlst_head_get (ats_ptr_type) ; extern ats_ptr_type strlst_tail_get (ats_ptr_type) ; // ats_void_type ccomp_file_to_file_exec ( ats_int_type flag_stadyn , ats_ptr_type param_rev , ats_ptr_type infile, ats_ptr_type outfile ) { int err ; char *flag_stadyn_str ; int n, argc ; char **argv, **argv_p, **argv_p1 ; // switch (flag_stadyn) { case 0: flag_stadyn_str = "--static" ; break ; case 1: flag_stadyn_str = "--dynamic" ; break ; default: ats_exit_errmsg ( 1, "[ccomp_file_to_file_exec] failed: wrong flag.\n" ) ; break ; // end of [default] } // end of [switch] // argc = n = strlst_length (param_rev) ; argc += 1 ; // self(*first*) argc += 2 ; // input */ if (outfile) argc += 2 ; // output argc += 1 ; // nullptr(*last*) // argv = (char**)malloc(argc * sizeof(ats_ptr_type)) ; if (!argv) { fprintf(stderr, "exit(ATS): ccomp_file_to_file_exec: malloc failed!\n") ; exit(EXIT_FAILURE) ; } // end of [if] argv_p = argv ; *argv_p = (char*)atsopt_global ; argv_p += 1 ; // // [param_rev] is in the reversed order!!! argv_p += n ; argv_p1 = argv_p ; while (1) { if (strlst_is_nil(param_rev)) break ; argv_p1 -= 1 ; *argv_p1 = (char*)strlst_head_get(param_rev) ; param_rev = strlst_tail_get(param_rev) ; } // end of [while] // if (outfile) { *argv_p = "--output" ; argv_p += 1 ; *argv_p = outfile ; argv_p += 1 ; } // end of [if] // *argv_p = flag_stadyn_str ; argv_p += 1 ; *argv_p = infile ; argv_p += 1 ; *argv_p = (char*)0 ; // /* fputs(*argv, stderr) ; argv_p = argv + 1 ; while (*argv_p) { fputc(' ', stderr) ; fputs(*argv_p, stderr) ; argv_p += 1 ; } // end of [while] fputc('\n', stderr) ; // */ err = execv((char*)atsopt_global, argv) ; if (err < 0) perror("ccomp_file_to_file_exec: [execv] failed: ") ; exit(EXIT_FAILURE) ; return ; // deadcode } /* end of [ccomp_file_to_file_exec] */ ats_void_type typecheck_file_exec ( ats_int_type flag_stadyn , ats_ptr_type param_rev , ats_ptr_type infile) { ccomp_file_to_file_exec (flag_stadyn, param_rev, infile, (ats_ptr_type)0/*outfile*/) ; return ; } // end of [typecheck_file_exec] ats_void_type atscc_version_exec () { int err = execl ( (char*)atsopt_global, (char*)atsopt_global, "--version", (char*)0 ) ; if (err < 0) perror("atscc_version: [execl] failed: ") ; exit(EXIT_FAILURE) ; } // end of [atscc_version] %} // end of [%{^] (* ****** ****** *) (* end of [atscc.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/0000700000175000017500000000000012223166166016402 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atsdoc/atsdoc_main.dats0000664000175000017500000003122312223166166021555 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: August, 2011 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) staload "atsdoc_translate.sats" (* ****** ****** *) // dynload "atsdoc_translate.dats" dynload "atsdoc_translate_error.dats" dynload "atsdoc_translate_item.dats" // (* ****** ****** *) // dynload "libatsdoc/dynloadall.dats" // HX: for libatsdoc.o // (* ****** ****** *) datatype comarg = COMARGkey of (int, string) viewtypedef comarglst (n: int) = list_vt (comarg, n) (* ****** ****** *) extern fun comarg_parse (s: string):<> comarg extern fun comarglst_parse {n:nat} (argc: int n, argv: &(@[string][n])):<> list_vt (comarg, n) // end of [comarglst_parse] (* ****** ****** *) implement comarg_parse (s) = let fun loop {n,i:nat | i <= n} .. (s: string n, n: int n, i: int i):<> comarg = if i < n then begin if (s[i] <> '-') then COMARGkey (i, s) else loop (s, n, i+1) end else begin COMARGkey (n, s) (* loop exists *) end // end of [if] // end of [loop] val s = string1_of_string s val n = string_length s; val n = int1_of_size1 n in loop (s, n, 0) end // end of [comarg_parse] implement comarglst_parse {n} (argc, argv) = let viewtypedef arglst (n: int) = list_vt (comarg, n) fun loop {i:nat | i <= n} {l:addr} .. (pf0: arglst 0 @ l | argv: &(@[string][n]), i: int i, p: ptr l) : (arglst (n-i) @ l | void) = if i < argc then let val+ ~list_vt_nil () = !p val arg = comarg_parse (argv.[i]) val lst0 = list_vt_cons (arg, list_vt_nil ()) val+ list_vt_cons (_, !lst) = lst0 val (pf | ()) = loop (view@ (!lst) | argv, i+1, lst) in fold@ lst0; !p := lst0; (pf0 | ()) end else (pf0 | ()) var lst0 = list_vt_nil {comarg} () val (pf | ()) = loop (view@ lst0 | argv, 0, &lst0) // tail-call prval () = view@ lst0 := pf in lst0 end // end of [comarglst_parse] (* ****** ****** *) fn comarg_warning (str: string) = { val () = prerr "waring(ATSDOC)" val () = prerr ": unrecognized command line argument [" val () = prerr str val () = prerr "] is ignored." val () = prerr_newline () } // end of [comarg_warning] (* ****** ****** *) datatype waitkind = | WTKnone of () | WTKinput of () // -i ... | WTKoutcode of () // --outcode ... // data | WTKoutdata of () // --outdata ... // code | WTKprefix of () // --prefix // end of [waitkind] typedef cmdstate = @{ comarg0= comarg // , waitkind= waitkind // , ninputfile= int // number of processed input files // } // end of [cmdstate] (* ****** ****** *) fn isWTKinput (state: cmdstate): bool = case+ state.waitkind of | WTKinput () => true | _ => false // end of [isWTKinput] fn isWTKoutcode (state: cmdstate): bool = case+ state.waitkind of | WTKoutcode () => true | _ => false // end of [isWTKoutcode] fn isWTKoutdata (state: cmdstate): bool = case+ state.waitkind of | WTKoutdata () => true | _ => false // end of [isWTKoutdata] fn isWTKprefix (state: cmdstate): bool = case+ state.waitkind of | WTKprefix () => true | _ => false // end of [isWTKprefix] (* ****** ****** *) datatype outchan = | OUTCHANptr of FILEref | OUTCHANref of FILEref // end of [OUTCHAN] fun outchan_get_fileref (x: outchan): FILEref = ( case+ x of | OUTCHANref (filr) => filr | OUTCHANptr (filp) => filp ) // end of [outchan_get_fileref] fun outchan_close (x: outchan): void = case+ x of | OUTCHANptr (filp) => fclose0_exn (filp) | OUTCHANref (filr) => () // end of [outchan_close] (* ****** ****** *) local // val stdoutchan = OUTCHANref (stdout_ref) val the_outcode = ref (stdoutchan) val the_outdata = ref (stdoutchan) // in // in of [local] fun outcode_get (): outchan = !the_outcode fun outcode_set (_new: outchan): void = let val _old = !the_outcode val () = !the_outcode := _new in outchan_close (_old) end // end of [outcode_set] fun outdata_get (): outchan = !the_outdata fun outdata_set (_new: outchan): void = let val _old = !the_outdata val () = !the_outdata := _new in outchan_close (_old) end // end of [outdata_set] end // end of [local] (* ****** ****** *) fun outcode_set_filename (path: string): void = let val (pfopt | filp) = fopen_err (path, file_mode_w) in // if filp > null then let prval Some_v (pffil) = pfopt val filp = __cast (pffil | filp) where { extern castfn __cast {m:fm} {l:addr} (pf: FILE (m) @ l | p: ptr l): FILEref } // end of [val] in outcode_set (OUTCHANptr (filp)) end else let prval None_v () = pfopt in outcode_set (OUTCHANref (stderr_ref)) end // end of [if] // end // end of [outcode_set_filename] fun outdata_set_filename (path: string): void = let val (pfopt | filp) = fopen_err (path, file_mode_w) in // if filp > null then let prval Some_v (pffil) = pfopt val filp = __cast (pffil | filp) where { extern castfn __cast {m:fm} {l:addr} (pf: FILE (m) @ l | p: ptr l): FILEref } // end of [val] in outdata_set (OUTCHANptr (filp)) end else let prval None_v () = pfopt in outdata_set (OUTCHANref (stderr_ref)) end // end of [if] // end // end of [outdata_set_filename] (* ****** ****** *) local val argv0 = ref ("") in // in of [local] fn argv0_get (): string = !argv0 fn argv0_set (cmd: string): void = !argv0 := cmd end // end of [local] fn atsdoc_usage (): void = { val cmd = argv0_get () // [argv0] is already set val () = printf ("usage: %s ... \n\n", @(cmd)) val () = printf ("where each is of one of the following forms:\n\n", @()) val () = printf (" -i filenames (for taking input from )\n", @()) val () = printf (" --input filenames (for taking input from )\n", @()) val () = printf (" -oc filename (outputing texting code to )\n", @()) val () = printf (" --outcode filename (outputing texting code to )\n", @()) val () = printf (" -od filename (outputing texting data to )\n", @()) val () = printf (" --outdata filename (outputing texting data to )\n", @()) val () = printf (" -h (for printing out the usage)\n", @()) val () = printf (" --help (for printing out the usage)\n", @()) val () = printf ("\n", @()) } // end of [atsdoc_usage] (* ****** ****** *) fn* process_cmdline {i:nat} .. ( state: &cmdstate, arglst: comarglst (i) ) : void = let (* val () = prerrf ("process_cmdline: enter\n") *) in // case+ arglst of | ~list_vt_cons (arg, arglst) => ( process_cmdline2 (state, arg, arglst) ) // endof [list_vt_cons] | ~list_vt_nil () when state.ninputfile = 0 => let // val outdata = outdata_get () val filr = outchan_get_fileref (outdata) val () = trans_top_from_stdin (filr) // val outcode = outcode_get () val filr = outchan_get_fileref (outcode) val () = fprint_the_tranitmlst (filr, "STDIN") // in // nothing end // end of [list_vt_nil when ...] | ~list_vt_nil () => () // end // end of [process_cmdline] and process_cmdline2 {i:nat} .. ( state: &cmdstate , arg: comarg, arglst: comarglst (i) ) : void = let in // case+ arg of | _ when isWTKinput (state) => let // // HX: the [WTKinput] state stays unchanged // val nif = state.ninputfile in case+ arg of | COMARGkey (1, key) when nif > 0 => process_cmdline2_COMARGkey1 (state, arglst, key) | COMARGkey (2, key) when nif > 0 => process_cmdline2_COMARGkey2 (state, arglst, key) | COMARGkey (_, basename) => let val () = state.ninputfile := state.ninputfile + 1 val outdata = outdata_get () val filr = outchan_get_fileref (outdata) val () = trans_top_from_basename (filr, basename) val outcode = outcode_get () val filr = outchan_get_fileref (outcode) val () = fprint_the_tranitmlst (filr, basename) in process_cmdline (state, arglst) end (* end of [_] *) end // end of [_ when isWTKinput] // | _ when isWTKoutcode (state) => let val () = state.waitkind := WTKnone () val COMARGkey (_, basename) = arg val () = outcode_set_filename (basename) in process_cmdline (state, arglst) end // end of [_ when isWTKoutcode] | _ when isWTKoutdata (state) => let val () = state.waitkind := WTKnone () val COMARGkey (_, basename) = arg val () = outdata_set_filename (basename) in process_cmdline (state, arglst) end // end of [_ when isWTKoutdata] // | _ when isWTKprefix (state) => let val () = state.waitkind := WTKnone () val COMARGkey (_, prfx) = arg val () = funres_set_prfx (prfx) // HX: prefix for return names in process_cmdline (state, arglst) end // end of [_ when isWTKoutdata] // | COMARGkey (1, key) => process_cmdline2_COMARGkey1 (state, arglst, key) | COMARGkey (2, key) => process_cmdline2_COMARGkey2 (state, arglst, key) | COMARGkey (_, key) => let val () = state.waitkind := WTKnone () val () = comarg_warning (key) in process_cmdline (state, arglst) end // end // end of [process_cmdline2] and process_cmdline2_COMARGkey1 {i:nat} .. ( state: &cmdstate , arglst: comarglst (i) , key: string ) : void = let val () = state.waitkind := WTKnone () val () = (case+ key of | "-i" => { val () = state.ninputfile := 0 val () = state.waitkind := WTKinput () } | "-oc" => { val () = state.ninputfile := 0 val () = state.waitkind := WTKoutcode () } | "-od" => { val () = state.ninputfile := 0 val () = state.waitkind := WTKoutdata () } | "-h" => { val () = state.waitkind := WTKnone () val () = state.ninputfile := state.ninputfile + 1 // HX: cutting a corner! val () = atsdoc_usage () // print out usage } (* | "-v" => atsdoc_version (stdout_ref) *) | _ => comarg_warning (key) ) : void // end of [val] in process_cmdline (state, arglst) end // end of [process_cmdline2_COMARGkey1] and process_cmdline2_COMARGkey2 {i:nat} .. ( state: &cmdstate , arglst: comarglst (i) , key: string ) : void = let val () = state.waitkind := WTKnone () val () = (case+ key of | "--input" => { val () = state.ninputfile := 0 val () = state.waitkind := WTKinput } | "--outcode" => { val () = state.waitkind := WTKoutcode () } | "--outdata" => { val () = state.waitkind := WTKoutdata () } | "--prefix" => { val () = state.waitkind := WTKprefix () } | "--help" => { val () = state.waitkind := WTKnone () val () = state.ninputfile := state.ninputfile + 1 // HX: cutting a corner! val () = atsdoc_usage () // print out usage } (* | "--version" => atsdoc_version (stdout_ref) *) | _ => comarg_warning (key) ) : void // end of [val] in process_cmdline (state, arglst) end // end of [process_cmdline2_COMARGkey2] (* ****** ****** *) implement main ( argc, argv ) = () where { (* *) // val () = argv0_set (argv.[0]) // val arglst = comarglst_parse (argc, argv) val ~list_vt_cons (arg0, arglst) = arglst // var state = @{ comarg0 = arg0 // , waitkind= WTKnone () // , ninputfile= 0 // } : cmdstate // val () = process_cmdline (state, arglst) // val () = outchan_close (outcode_get ()) val () = outchan_close (outdata_get ()) // } // end of [main] (* ****** ****** *) (* end of [atsdoc_main.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/SATS/0000700000175000017500000000000012223166166017154 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atsdoc/Makefile0000664000175000017500000000516612223166166020066 0ustar hwxihwxi####################################################################### # # # Applied Type System # # # # Hongwei Xi # # # ####################################################################### # # ATS/Postiats - Unleashing the Potential of Types! # Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software # All rights reserved # # ATS is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free # Software Foundation; either version 2.1, or (at your option) any later # version. # # ATS is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with ATS; see the file COPYING. If not, please write to the # Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # ###### # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Start Time: July, 2011 # ###### ATSCC=$(ATSHOME)/bin/atscc ATSOPT=$(ATSHOME)/bin/atsopt ###### ATSGCFLAG= ATSGCFLAG=-D_ATS_GCATS ATSCCFLAGS=-g ATSCCFLAGS=-g -O ATSCCFLAGS=-g -O2 ###### SOURCES := \ atsdoc_translate.sats \ atsdoc_translate.dats \ atsdoc_translate_error.dats \ atsdoc_translate_item.dats \ SOURCESsta := $(filter %.sats, $(SOURCES)) SOURCESdyn := $(filter %.dats, $(SOURCES)) OBJECTS := $(SOURCES) OBJECTS := $(patsubst %.sats, %_sats.o, $(OBJECTS)) OBJECTS := $(patsubst %.dats, %_dats.o, $(OBJECTS)) ###### all:: atsdoc clean ###### atsdoc: atsdoc_main_dats.o $(OBJECTS) $(ATSCC) $(ATSGCFLAG) $(ATSCCFLAGS) -o atsdoc atsdoc_main_dats.o $(OBJECTS) -latsdoc ###### %_sats.o: %.sats $(ATSCC) $(ATSCCFLAGS) -c $< %_dats.o: %.dats $(ATSCC) $(ATSCCFLAGS) -c $< ###### # # HX: '-o .depend' means appending instead of overwriting # # depend:: # $(RMF) .depend # $(ATSOPT) -o .depend -dep1 -s $(SOURCESsta) -d $(SOURCESdyn) # $(ATSOPT) -o .depend -dep1 -d atsdoc_main.dats #include .depend # ###### RMF=rm -f WCL=wc -l ###### srclines:: ; $(WCL) $(SOURCES) ###### clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.o clean:: ; $(RMF) *_?ats.c cleanall:: clean cleanall:: ; $(RMF) atsdoc ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/utils/atsdoc/atsdoc_translate.dats0000664000175000017500000002673512223166166022642 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: July, 2011 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" macdef fputc_err = $STDIO.fputc_err (* ****** ****** *) // staload SYM = "libatsdoc/SATS/libatsdoc_symbol.sats" // staload FIL = "libatsdoc/SATS/libatsdoc_filename.sats" // staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" // macdef posincby1 (pos) = $LOC.position_incby_count (,(pos), 1u) macdef posincbyc (pos, i) = $LOC.position_incby_char (,(pos), ,(i)) // (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_lexbuf.sats" (* ****** ****** *) staload "atsdoc_translate.sats" (* ****** ****** *) #define i2c char_of_int #define i2u uint_of_int #define u2i int_of_uint #define sz2i int1_of_size1 (* ****** ****** *) macdef neof (i) = (,(i) != EOF) (* ****** ****** *) local val the_funres_prefix = ref ("__tok") in implement funres_get_prfx () = !the_funres_prefix implement funres_set_prfx (prfx) = !the_funres_prefix := prfx end // end of [local] (* ****** ****** *) local val cntref = ref (1) fun funres_get_count (): int = let val n = !cntref; val () = !cntref := n + 1 in n end // end of [funres_count] in // in of [local] implement funcall_get_fres () = let val prfx = funres_get_prfx () val count = funres_get_count () val fres = sprintf ("%s%i", @(prfx, count)) in string_of_strptr (fres) end // end of [funcall_get_fres] end // end of [local] (* ****** ****** *) implement tranitm_make (loc, node) = '{ tranitm_loc= loc, tranitm_node= node } (* ****** ****** *) implement fprint_tranitm (out, itm) = case+ itm.tranitm_node of | EXTCODE (code) => ( fprint_string (out, code) ) // end of [EXTCODE] | FUNCALL (fnam, knd, xs, fres) => let val () = fprintf (out, "val %s = %s", @(fres, fnam)) val () = if knd > 0 then fprint_string (out, "$lst") val () = fprint_funarglst (out, xs) val () = fprint_newline (out) val () = fprintf ( out, "val () = theAtextMap_insert_str (\"%s\", %s)", @(fres, fres) ) // end of [val] val () = fprint_newline (out) in // nothing end // end of [FUNCALL] // end of [fprint_tranitm] (* ****** ****** *) fun SPACE_test (c: char): bool = char_isspace (c) (* ****** ****** *) implement DIGIT_test (c) = char_isdigit (c) implement IDENTFST_test (c) = case+ 0 of | _ when ('a' <= c andalso c <= 'z') => true | _ when ('A' <= c andalso c <= 'Z') => true | _ when c = '_' => true | _ => false // end of [IDENTFST_test] implement IDENTRST_test (c) = case+ 0 of | _ when ('a' <= c andalso c <= 'z') => true | _ when ('A' <= c andalso c <= 'Z') => true | _ when ('0' <= c andalso c <= '9') => true | _ when c = '_' => true | _ when c = '\'' => true | _ => false // end of [IDENTRST_test] (* ****** ****** *) implement ftesting_seq0 (buf, pos, f) = diff where { fun loop ( buf: &lexbuf, nchr: uint, f: char -> bool ) : uint = let val i = lexbuf_get_char (buf, nchr) in if neof(i) then if f ((i2c)i) then loop (buf, succ(nchr), f) else nchr // end of [if] else nchr // end of [if] end // end of [loop] val nchr0 = lexbufpos_diff (buf, pos) val nchr1 = loop (buf, nchr0, f) val diff = nchr1 - nchr0 val () = if diff > 0u then $LOC.position_incby_count (pos, diff) else () // end of [val] } // end of [ftesting_seq0] (* ****** ****** *) implement testing_spaces (buf, pos) = let fun loop ( buf: &lexbuf, pos: &position, k: uint ) : uint = let val i = lexbufpos_get_char (buf, pos) in if neof(i) then ( if SPACE_test ((i2c)i) then let val () = posincbyc (pos, i) in loop (buf, pos, k+1u) end else k // end of [if] ) else k // end of [if] end // end of [loop] in loop (buf, pos, 0u) end // end of [testing_spaces] (* ****** ****** *) // // HX: [lit] contains no '\n'! // implement testing_literal (buf, pos, lit) = res where { // val [n:int] lit = string1_of_string (lit) // fun loop {k:nat | k <= n} ( buf: &lexbuf, nchr: uint, lit: string n, k: size_t k ) : int = let val notatend = string_isnot_atend (lit, k) // end of [val] in if notatend then let val i = lexbuf_get_char (buf, nchr) in if neof(i) then if ((i2c)i = lit[k]) then loop (buf, succ(nchr), lit, k+1) else ~1 // end of [if] else ~1 // end of [if] end else (sz2i)k // end of [if] end // end of [loop] // val nchr0 = lexbufpos_diff (buf, pos) val res = loop (buf, nchr0, lit, 0) val () = if res >= 0 then $LOC.position_incby_count (pos, (i2u)res) else () // end of [if] // end of [val] // } // end of [testing_literal] (* ****** ****** *) implement testing_ident (buf, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then ( if IDENTFST_test ((i2c)i) then let val () = posincby1 (pos) val nchr = ftesting_seq0 (buf, pos, IDENTRST_test) in (u2i)nchr + 1 end else ~1 // end of [if] ) else ~1 // end of [if] // end // end of [testing_ident] (* ****** ****** *) local viewtypedef tranitmlst_vt = List_vt (tranitm) val theList = ref (list_vt_nil) in // in of [local] implement the_tranitmlst_add (x) = let val (vbox pf | p) = ref_get_view_ptr (theList) in !p := list_vt_cons (x, !p) end // end of [the_tranitmlst_add] implement the_tranitmlst_get () = let val (vbox pf | p) = ref_get_view_ptr (theList) val xs = !p val () = !p := list_vt_nil in list_vt_reverse (xs) end // end of [the_tranitmlst_add] end // end of [local] (* ****** ****** *) extern fun trans_top_PERCENT (out: FILEref, buf: &lexbuf, pos: &position): void // end of [trans_PERCENT] extern fun trans_top_SHARP (out: FILEref, buf: &lexbuf, pos: &position): void // end of [trans_SHARP] extern fun trans_top_SLASH (out: FILEref, buf: &lexbuf, pos: &position): void // end of [trans_SLASH] (* ****** ****** *) implement trans_top (out, buf) = let // var pos: position val () = lexbuf_get_position (buf, pos) // val i0 = lexbuf_get_char (buf, 0u) // in // if neof(i0) then let val c = (i2c)i0 // the first character val () = posincbyc (pos, i0) in case+ c of | '%' => let val () = trans_top_PERCENT (out, buf, pos) val () = lexbuf_reset_position (buf, pos) in trans_top (out, buf) end | '#' => let val () = trans_top_SHARP (out, buf, pos) val () = lexbuf_reset_position (buf, pos) in trans_top (out, buf) end | '\\' => let val () = trans_top_SLASH (out, buf, pos) val () = lexbuf_reset_position (buf, pos) in trans_top (out, buf) end | _ => let val err = fputc_err (c, out) val () = lexbuf_reset_position (buf, pos) in trans_top (out, buf) end // end of [_] // end else () // end of [if] // end // end of [trans_top] (* ****** ****** *) implement trans_top_PERCENT (out, buf, pos) = let val i = lexbufpos_get_char (buf, pos) val c = (i2c)i in case+ c of | '\{' when // '%{' at the beginning $LOC.position_get_ncol (pos) = 1 => let var pos0: position val () = lexbuf_get_position (buf, pos0) val () = posincby1 (pos) in trans_extcode (buf, pos0, pos) end // end of ['\{'] | _ => let val () = posincbyc (pos, i) val err = fputc_err ('%', out); val err = fputc_err (c, out) in // nothing end // end of [_] end // end of [trans_PERCENT] (* ****** ****** *) implement trans_top_SHARP (out, buf, pos) = let var pos0: position val () = $LOC.position_copy (pos0, pos) val opt = trans_funcall (buf, pos0, pos) in // case+ opt of | ~Some_vt (fres) => fprintf (out, "#%s$", @(fres)) // HX: '$' is a separator! | ~None_vt () => let val err = fputc_err ('#', out) in (*nothing*) end // end of [if] // end // end of [trans_top_SHARP] (* ****** ****** *) implement trans_top_SLASH (out, buf, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then let val c = (i2c)i in case+ c of | '\n' => let val () = posincbyc (pos, i) in // nothing end // end of ['\n'] | '#' => let val () = posincby1 (pos); val err = fputc_err (c, out) in // nothing end // end of ['\\'] | '\\' => let val () = posincby1 (pos); val err = fputc_err (c, out) in // nothing end // end of ['\\'] | '%' => let val () = posincby1 (pos); val err = fputc_err (c, out) in // nothing end // end of ['\\'] | _ => let val () = posincby1 (pos) val err = fputc_err ('\\', out); val err = fputc_err (c, out) in // nothing end // end of [_] end else let val err = fputc_err ('\\', out) in // nothing end // end of [if] // end // end of [trans_top_SLASH] (* ****** ****** *) implement trans_top_from_stdin (tout) = () where { var buf: lexbuf val () = lexbuf_initialize_getc (buf, lam () = $STDIO.getchar ()) val () = trans_top (tout, buf) val () = lexbuf_uninitialize (buf) // val () = fprint_the_docerrlst (stderr_ref) // } // end of [trans_top_from_stdin] implement trans_top_from_filename (tout, fil) = let prval pfmod = file_mode_lte_r_r val fullname = $FIL.filename_get_full (fil) val fullname = $SYM.symbol_get_name (fullname) val (pffil | filp) = $STDIO.fopen_exn (fullname, file_mode_r) var buf: lexbuf val () = lexbuf_initialize_filp (file_mode_lte_r_r, pffil | buf, filp) // val (pfpush | ()) = $FIL.the_filenamelst_push (fil) val () = trans_top (tout, buf) val () = $FIL.the_filenamelst_pop (pfpush | (*none*)) // val () = lexbuf_uninitialize (buf) in fprint_the_docerrlst (stderr_ref) end // end of [trans_top_from_filename] implement trans_top_from_basename (tout, basename) = let val filopt = $FIL.filenameopt_make_relative (basename) in // case+ filopt of | ~Some_vt (fil) => trans_top_from_filename (tout, fil) | ~None_vt () => let val () = prerrf ("The file [%s] cannot be opened for read.\n", @(basename)) in // nothing end // end of [if] // end of [case] // end // end of [trans_top_from_filename] (* ****** ****** *) (* end of [atsdoc_translate.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/atsdoc_translate.sats0000664000175000017500000001135612223166166022652 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: July, 2011 // (* ****** ****** *) staload FIL = "libatsdoc/SATS/libatsdoc_filename.sats" typedef filename = $FIL.filename staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" stadef location = $LOC.location stadef position = $LOC.position (* ****** ****** *) staload LBF = "libatsdoc/SATS/libatsdoc_lexbuf.sats" stadef lexbuf = $LBF.lexbuf (* ****** ****** *) datatype docerr_node = | DE_STRING_unclose of () | DE_EXTCODE_unclose of () | DE_FUNARGLST_unclose of () | DE_FUNRES_none of () | DE_FUNRES_unclose of () // end of [docerr_node] typedef docerr = '{ docerr_loc= location, docerr_node= docerr_node } // end of [docerr] fun docerr_make (loc: location, node: docerr_node): docerr fun the_docerrlst_clear (): void fun the_docerrlst_add (err: docerr): void fun the_docerrlst_length (): int fun fprint_the_docerrlst (out: FILEref): void (* ****** ****** *) fun lexbufpos2_docerr (buf: &lexbuf, pos0: &position, pos1: &position, node: docerr_node) : void // end of [lexbufpos2_docerr] (* ****** ****** *) datatype funarg = | FAint of string | FAident of string | FAstrsub of string | FAfunres of string | FAnil of () // end of [funarg] typedef funarglst = List (funarg) fun fprint_funarg (out: FILEref, x: funarg): void fun fprint_funarglst (out: FILEref, xs: funarglst): void (* ****** ****** *) // // HX: knd = 0/1 : tup/lst // datatype tranitm_node = | EXTCODE of (string(*code*)) | FUNCALL of (string(*fnam*), int(*knd*), funarglst, string(*fres*)) // end of [transitm_node] typedef tranitm = '{ tranitm_loc= location, tranitm_node= tranitm_node } // end of [funcall] fun tranitm_make (loc: location, node: tranitm_node): tranitm fun fprint_tranitm (out: FILEref, x: tranitm): void (* ****** ****** *) // fun funres_get_prfx (): string // HX: get the prefix for return names fun funres_set_prfx (prf: string): void // HX: set the prefix for return names // fun funcall_get_fres (): string // HX: using a counter to general unique return names // (* ****** ****** *) fun DIGIT_test (c: char): bool fun IDENTFST_test (c: char): bool fun IDENTRST_test (c: char): bool (* ****** ****** *) // // HX: f('\n') must be false! // fun ftesting_seq0 ( buf: &lexbuf, pos: &position, f: char -> bool ) : uint // end of [ftesting_seq0] (* ****** ****** *) fun testing_spaces (buf: &lexbuf, pos: &position): uint // end of [testing_spaces] fun testing_literal ( buf: &lexbuf, pos: &position, lit: string ) : int // end of [testing_literal] fun testing_ident (buf: &lexbuf, pos: &position): int (* ****** ****** *) fun the_tranitmlst_add (x: tranitm): void fun the_tranitmlst_get (): List_vt (tranitm) fun fprint_the_tranitmlst (out: FILEref, basename: string): void (* ****** ****** *) fun trans_top (out: FILEref, buf: &lexbuf): void fun trans_extcode (buf: &lexbuf, pos0: &position, pos: &position) : void // end of [trans_extcode] fun trans_funcall // HX: pos0 is right after the char '#' (buf: &lexbuf, pos0: &position, pos: &position) : Option_vt (string(*fres*)) // end of [trans_funcall] (* ****** ****** *) // // HX: tout: txt; dout: dats // fun trans_top_from_stdin (tout: FILEref): void fun trans_top_from_filename (tout: FILEref, fil: filename): void fun trans_top_from_basename (tout: FILEref, basename: string): void (* ****** ****** *) (* end of [atsdoc_translate.sats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/atsdoc_translate_error.dats0000664000175000017500000001316512223166166024044 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: August, 2011 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" typedef location = $LOC.location overload fprint with $LOC.fprint_location (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_lexbuf.sats" (* ****** ****** *) staload "atsdoc_translate.sats" (* ****** ****** *) implement docerr_make (loc, node) = '{ docerr_loc= loc, docerr_node= node } // end of [docerr_make] (* ****** ****** *) viewtypedef docerrlst_vt = List_vt (docerr) (* ****** ****** *) extern fun the_docerrlst_get (n: &int? >> int): docerrlst_vt (* ****** ****** *) local #define MAXLEN 100 #assert (MAXLEN > 0) val the_length = ref (0) val the_docerrlst = ref (list_vt_nil) in // in of [local] implement the_docerrlst_length () = !the_length implement the_docerrlst_clear () = () where { val () = !the_length := 0 val () = () where { val (vbox pf | p) = ref_get_view_ptr (the_docerrlst) val () = list_vt_free (!p) val () = !p := list_vt_nil () } // end of [val] } // end of [the_docerrlst_clear] implement the_docerrlst_add (err) = () where { val n = let val (vbox pf | p) = ref_get_view_ptr (the_length) val n = !p val () = !p := n + 1 in n end // end of [val] val () = if n < MAXLEN then let val (vbox pf | p) = ref_get_view_ptr (the_docerrlst) in !p := list_vt_cons (err, !p) end // end of [val] } // end of [the_docerrlst_add] implement the_docerrlst_get (n) = xs where { val () = n := !the_length val () = !the_length := 0 val (vbox pf | p) = ref_get_view_ptr (the_docerrlst) val xs = !p val xs = list_vt_reverse (xs) val () = !p := list_vt_nil () } // end of [the_docerrlst_get] end // end of [local] (* ****** ****** *) extern fun fprint_docerr (out: FILEref, err: docerr): void implement fprint_docerr (out, x) = let val loc = x.docerr_loc val () = fprint (out, loc) in // case+ x.docerr_node of // | DE_EXTCODE_unclose () => () where { val () = fprintf (out, ": error(atsdoc)", @()) val () = fprintf (out, ": the external code block is unclosed.", @()) val () = fprint_newline (out) } // | DE_STRING_unclose () => () where { val () = fprintf (out, ": error(atsdoc)", @()) val () = fprintf (out, ": the string argument is unclosed.", @()) val () = fprint_newline (out) } // | DE_FUNARGLST_unclose () => () where { val () = fprintf (out, ": error(atsdoc)", @()) val () = fprintf (out, ": the funarg list is not properly closed.", @()) val () = fprint_newline (out) } | DE_FUNRES_none () => () where { val () = fprintf (out, ": error(atsdoc)", @()) val () = fprintf (out, ": the funres identifier is ill-formed.", @()) val () = fprint_newline (out) } | DE_FUNRES_unclose () => () where { val () = fprintf (out, ": error(atsdoc)", @()) val () = fprintf (out, ": the optional funres is not properly closed.", @()) val () = fprint_newline (out) } (* | _ => () where { val () = fprintf (out, ": error(lexing): unspecified", @()) val () = fprint_newline (out) } *) // end // end of [fprint_docerr] implement fprint_the_docerrlst (out) = let var n: int? val xs = the_docerrlst_get (n) fun loop ( out: FILEref, xs: docerrlst_vt, n: int ) : int = case+ xs of | ~list_vt_cons (x, xs) => ( fprint_docerr (out, x); loop (out, xs, n-1) ) // end of [list_vt_cons] | ~list_vt_nil () => n // end of [loop] in // case+ xs of | list_vt_cons _ => let prval () = fold@ (xs) val n = loop (out, xs, n) val () = if n > 0 then { val () = fprint_string (out, "There are possibly some additional errors.") val () = fprint_newline (out) } // end of [if] in // nothing end // end of [list_vt_cons] | ~list_vt_nil () => () // end // end of [fprint_the_docerrlst] (* ****** ****** *) implement lexbufpos2_docerr ( buf, pos0, pos1, node ) = let val loc = $LOC.location_make_pos_pos (pos0, pos1) val () = the_docerrlst_add (docerr_make (loc, node)) in // nothing end // end of [lexbufpos2_docerr] (* ****** ****** *) (* end of [atsdoc_translate_error.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/DATS/0000700000175000017500000000000012223166166017135 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atsdoc/HATS/0000700000175000017500000000000012223166166017141 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atsdoc/HATS/pats2dbookatxt.hats0000664000175000017500000000604312223166166023012 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #ifndef ATSDOC_PATS2DBOOKATXT #define ATSDOC_PATS2DBOOKATXT 1 (* ****** ****** *) fn sizeof (type: string): atext = atext_strcst (type) // end of [sizeof] fn stacode (x: string): atext = atext_strcst (x) fn prfcode (x: string): atext = atext_strcst (x) fn dyncode (x: string): atext = atext_strcst (x) (* ****** ****** *) local val theCount = ref (0) in // in of [local] fn patscode_count_getinc (): int = let val n = !theCount in !theCount := n+1; n end // end of [getinc] fn patscode_count_reset (): void = !theCount := 0 end // end of [local] (* ****** ****** *) local val thePrefix = ref ("") in // in of [local] fn patscode_prefix_get (): string = !thePrefix fn patscode_prefix_set (x: string): void = !thePrefix := x end // end of [local] (* ****** ****** *) fn pats2xhtmls (code: string): atext = let val _beg = atext_strcst ("") in atext_apptxt3 (_beg, _code, _end) end // end of [pats2xhtmls] fn pats2xhtmld (code: string): atext = let val _beg = atext_strcst ("") in atext_apptxt3 (_beg, _code, _end) end // end of [pats2xhtmld] (* ****** ****** *) fn pats2xhtmls_save (code: string): atext = pats2xhtmls (code) (* ****** ****** *) fn pats2xhtmls_tryit (code: string): atext = pats2xhtmls (code) fn pats2xhtmld_tryit (code: string): atext = pats2xhtmld (code) (* ****** ****** *) #endif // end of [ATSDOC_PATS2DBOOKATXT] (* ****** ****** *) (* end of [pats2dbookatxt.hats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/HATS/pats2xhtmlatxt.hats0000664000175000017500000001657012223166166023056 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #ifndef ATSDOC_PATS2XHTMLATXT #define ATSDOC_PATS2XHTMLATXT 1 (* ****** ****** *) #include "utils/atsdoc/HATS/xhtmlatxt.hats" (* ****** ****** *) fn patsyntax_style (): atext = atext_strcst("\ \n\ ") (* ****** ****** *) fn patscode_jquery_min_js (): atext = atext_strcst("\ \n\ ") (* ****** ****** *) fn patscode_tryit_bind_all_js (): atext = atext_strcst("\ \n\ ") (* ****** ****** *) macdef para (x) = xmltagging ("p", ,(x)) (* ****** ****** *) fn HR (sz: int): atext = let val str = sprintf ("
", @(sz)) in atext_strptr (str) end // end of [HR] (* ****** ****** *) fn sizeof (type: string): atext = atext_appstr3 ("sizeof<", type, ">") // end of [tszof] fn stacode (x: string): atext = let val _beg = atext_strcst"" val _end = atext_strcst"" in atext_apptxt3 (_beg, atext_strsub(x), _end) end // end of [stacode] fn prfcode (x: string): atext = let val _beg = atext_strcst"" val _end = atext_strcst"" in atext_apptxt3 (_beg, atext_strsub(x), _end) end // end of [prfcode] fn dyncode (x: string): atext = let val _beg = atext_strcst"" val _end = atext_strcst"" in atext_apptxt3 (_beg, atext_strsub(x), _end) end // end of [dyncode] (* ****** ****** *) local val theCount = ref (0) in // in of [local] fn patscode_count_getinc (): int = let val n = !theCount in !theCount := n+1; n end // end of [getinc] fn patscode_count_reset (): void = !theCount := 0 end // end of [local] (* ****** ****** *) local val thePrefix = ref ("") in // in of [local] fn patscode_prefix_get (): string = !thePrefix fn patscode_prefix_set (x: string): void = !thePrefix := x end // end of [local] (* ****** ****** *) fn patscode_save ( stadyn: int, code: string ) : Option (string) = let // val prfx = patscode_prefix_get () // in // if prfx != "" then let val cnt = patscode_count_getinc () val path = sprintf ("%s_%i", @(prfx, cnt)) val path = string_of_strptr (path) val ext = ( if stadyn = 0 then "sats" else "dats" ) : string // end of [val] val pathext = sprintf ("%s.%s", @(path, ext)) val pathext = string_of_strptr (pathext) val out = open_file_exn (pathext, file_mode_w) val () = fprint_string (out, code) val () = close_file_exn (out) in Some (path) end else None () // end of [if] // end // end of [patscoded_save] (* ****** ****** *) fn pats2xhtmls (code: string): atext = let // val _beg = atext_strcst ("
")
val _code = atext_strptr (string_pats2xhtmlize_bground (0(*stadyn*), code))
val _end = atext_strcst ("
\n") // in atext_apptxt3 (_beg, _code, _end) end // end of [pats2xhtmls] fn pats2xhtmld (code: string): atext = let // val _beg = atext_strcst ("
")
val _code = atext_strptr (string_pats2xhtmlize_bground (1(*stadyn*), code))
val _end = atext_strcst ("
\n") in atext_apptxt3 (_beg, _code, _end) end // end of [pats2xhtmld] (* ****** ****** *) fn pats2xhtmld_save (code: string): atext = let // val _(*path*) = patscode_save (1(*stadyn*), code) // in pats2xhtmld (code) end // end of [pats2xhtmld_save] (* ****** ****** *) fn pats2xhtmld_tryit (code: string): atext = let val opt = patscode_save (1(*stadyn*), code) val name = ( case+ opt of | Some path => let val x = sprintf ("%s.dats", @(path)) in string_of_strptr (x) end // end of [Some] | None () => "TRYIT/patscode_tryit_nameless.dats" ) : string // end of [val] // val _beg = let val x = sprintf ( "
", @(name)
  ) // end of [val]
in
  atext_strptr (x)
end // end of [val]
val _code = atext_strptr (string_pats2xhtmlize_bground (1(*stadyn*), code))
val _end = atext_strcst ("
\n") // in atext_apptxt3 (_beg, _code, _end) end // end of [pats2xhtmld_tryit] (* ****** ****** *) #endif // end of [ATSDOC_PATS2XHTMLATXT] (* ****** ****** *) (* end of [pats2xhtmlatxt.hats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/HATS/xhtmlatxt.hats0000664000175000017500000000725412223166166022103 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: September, 2011 // (* ****** ****** *) (* ** HX: help functions for writing xhtml documents via [atsdoc] *) (* ****** ****** *) #ifndef ATSDOC_XHTMLATXT #define ATSDOC_XHTMLATXT 1 (* ****** ****** *) // staload UN = "prelude/SATS/unsafe.sats" // staload TIME = "libc/SATS/time.sats" staload STDIO = "libc/SATS/stdio.sats" // staload "libatsdoc/SATS/libatsdoc_atext.sats" // (* ****** ****** *) local // val LT = "<" val LTSLASH = "" // in fun xmltagging ( tag: string, x: string ) : atext = let val _opn = atext_appstr3 (LT, tag, GT) val _clo = atext_appstr3 (LTSLASH, tag, GT) in atext_apptxt3 (_opn, atext_strsub(x), _clo) end // end of [xmltagging] end // end of [local] (* ****** ****** *) macdef head (x) = xmltagging ("head", ,(x)) macdef title (x) = xmltagging ("title", ,(x)) macdef body (x) = xmltagging ("body", ,(x)) (* ****** ****** *) macdef H1 (x) = xmltagging ("h1", ,(x)) macdef H2 (x) = xmltagging ("h2", ,(x)) macdef H3 (x) = xmltagging ("h3", ,(x)) macdef H4 (x) = xmltagging ("h4", ,(x)) (* ****** ****** *) local // val COMMENTopn = atext_strcst"") // in fun comment (x: string): atext = atext_apptxt3 (COMMENTopn, atext_strsub(x), COMMENTcls) // end of [comment] end // end of [local] (* ****** ****** *) fun ignore (x: string): atext = atext_nil () fun ignoretxt (x: atext): atext = atext_nil () (* ****** ****** *) macdef emph(x) = xmltagging ("em", ,(x)) macdef emphasis(x) = xmltagging ("em", ,(x)) (* ****** ****** *) macdef strong(x) = xmltagging ("strong", ,(x)) (* ****** ****** *) macdef textpre(x) = xmltagging ("pre", ,(x)) //
 ... 
(* ****** ****** *) fn pcenter (x: string): atext = let val opn = atext_strcst"

" val cls = atext_strcst"

" in atext_apptxt3 (opn, atext_strsub(x), cls) end // end of [pcenter] (* ****** ****** *) fun timestamp (): atext = let var time = $TIME.time_get () val (fpf | x) = $TIME.ctime (time) val x1 = sprintf ("%s", @($UN.castvwtp1{string}(x))) prval () = fpf (x) val x1 = string_of_strptr (x1) in atext_strcst (x1) end // end of [timestamp] (* ****** ****** *) #endif // end of [#ifndef(ATSDOC_XHTMLATXT)] (* end of [xhtmlatxt.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/HATS/docbookatxt.hats0000664000175000017500000001015412223166166022360 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: September, 2011 // (* ****** ****** *) (* ** HX: help functions for writing docbook documents via [atsdoc] *) (* ****** ****** *) #ifndef ATSDOC_DOCBOOKATXT #define ATSDOC_DOCBOOKATXT 1 (* ****** ****** *) #include "utils/atsdoc/HATS/xhtmlatxt.hats" (* ****** ****** *) macdef bookinfo (x) = xmltagging ("bookinfo", ,(x)) macdef articleinfo (x) = xmltagging ("articleinfo", ,(x)) (* ****** ****** *) macdef title (x) = xmltagging ("title", ,(x)) macdef subtitle (x) = xmltagging ("subtitle", ,(x)) (* ****** ****** *) macdef author (x) = xmltagging ("author", ,(x)) macdef firstname (x) = xmltagging ("firstname", ,(x)) macdef surname (x) = xmltagging ("surname", ,(x)) (* ****** ****** *) macdef email (x) = xmltagging ("email", ,(x)) macdef address (x) = xmltagging ("address", ,(x)) macdef affiliation (x) = xmltagging ("affiliation", ,(x)) (* ****** ****** *) macdef copyright (x) = xmltagging ("copyright", ,(x)) (* ****** ****** *) macdef abstract (x) = xmltagging ("abstract", ,(x)) (* ****** ****** *) // macdef code (x) = xmltagging ("code", ,(x)) macdef command (x) = xmltagging ("command", ,(x)) macdef emph (x) = xmltagging ("emphasis", ,(x)) macdef filename (x) = xmltagging ("filename", ,(x)) // macdef para (x) = xmltagging ("para", ,(x)) macdef simplesect (x) = xmltagging ("simplesect", ,(x)) // (* ****** ****** *) // macdef sub (x) = xmltagging ("subscript", ,(x)) macdef sup (x) = xmltagging ("superscript", ,(x)) // (* ****** ****** *) macdef member (x) = xmltagging ("member", ,(x)) macdef simplelist (x) = xmltagging ("simplelist", ,(x)) (* ****** ****** *) macdef listitem (x) = xmltagging ("listitem", ,(x)) macdef orderedlist (x) = xmltagging ("orderedlist", ,(x)) macdef itemizedlist (x) = xmltagging ("itemizedlist", ,(x)) (* ****** ****** *) macdef programlisting (x) = xmltagging ("programlisting", ,(x)) macdef informalexample (x) = xmltagging ("informalexample", ,(x)) (* ****** ****** *) fun ulink (link: string, name: string): atext = let val res = sprintf ("%s", @(link, name)) in atext_strptr (res) end // end of [ulink] (* ****** ****** *) // local // val _opn = "\ \n" // end of [val] in // fun atscode (x: string): atext = atext_appstr3 (_opn, x, _cls) // fun atscodefil (path: string): atext = let val _opn = atext_strcst(_opn) val _code = atext_filepath (path) val _cls = atext_strcst(_cls) in atext_apptxt3 (_opn, _code, _cls) end // end of [atscodefil] // end // end of [local] // (* ****** ****** *) #endif // end of [#ifndef(ATSDOC_DOCBOOKATXT)] (* end of [docbookatxt.dats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/HATS/postiatsatxt.hats0000664000175000017500000001674712223166166022624 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #ifndef ATSDOC_POSTIATSATXT #define ATSDOC_POSTIATSATXT 1 (* ****** ****** *) // staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/unsafe.dats" // staload STDIO = "libc/SATS/stdio.sats" staload TIME = "libc/SATS/time.sats" // dynload "libatsdoc/dynloadall.dats" // staload "libatsdoc/SATS/libatsdoc_atext.sats" // (* ****** ****** *) fun comment (x: string): atext = let val _beg = "(*\n" and _end = "\n*)" in atext_appstr3 (_beg, x, _end) end // end of [comment] fun ignoretxt (x: atext): atext = atext_nil () (* ****** ****** *) fun timestamp (): atext = let var time = $TIME.time_get () val (fpf | x) = $TIME.ctime (time) val x1 = sprintf ("%s", @($UN.castvwtp1{string}(x))) prval () = fpf (x) val x1 = string_of_strptr (x1) val x1 = string1_of_string (x1) // fun loop {n,i:nat | i <= n} ( str: string n, i: size_t i ) : sizeLte (n) = if string_isnot_atend (str, i) then let val c = str[i] in if c <> '\n' then loop (str, i+1) else i end else i // end of [if] // end of [loop] // val ofs = loop (x1, 0) val p_ofs = $UN.cast2ptr(x1) + ofs val [l:addr] p_ofs = ptr1_of_ptr (p_ofs) prval () = __assert () where { extern praxi __assert (): [l > null] void } // end of [prval] val () = $UN.ptrset (p_ofs, '\0') // in atext_strcst (x1) end // end of [timestamp] (* ****** ****** *) fun atscode_banner (): atext = atext_strcst ("\ (***********************************************************************)\n\ (* *)\n\ (* Applied Type System *)\n\ (* *)\n\ (***********************************************************************)\n\ ") // end of [atscode_banner] fun atscode_banner_for_C (): atext = atext_strcst ("\ /***********************************************************************/\n\ /* */\n\ /* Applied Type System */\n\ /* */\n\ /***********************************************************************/\n\ ") // end of [atscode_banner_for_C] (* ****** ****** *) fun atscode_copyright_GPL (): atext = atext_strcst ("\ (*\n\ ** ATS/Postiats - Unleashing the Potential of Types!\n\ ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc.\n\ ** All rights reserved\n\ **\n\ ** ATS is free software; you can redistribute it and/or modify it under\n\ ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the\n\ ** Free Software Foundation; either version 3, or (at your option) any\n\ ** later version.\n\ **\n\ ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY\n\ ** WARRANTY; without even the implied warranty of MERCHANTABILITY or\n\ ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License\n\ ** for more details.\n\ **\n\ ** You should have received a copy of the GNU General Public License\n\ ** along with ATS; see the file COPYING. If not, please write to the\n\ ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA\n\ ** 02110-1301, USA.\n\ *)\ ") // end of [atscode_copyright_GPL] fun atscode_copyright_LGPL (): atext = atext_strcst ("\ (*\n\ ** ATS/Postiats - Unleashing the Potential of Types!\n\ ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc.\n\ ** All rights reserved\n\ **\n\ ** ATS is free software; you can redistribute it and/or modify it under\n\ ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the\n\ ** Free Software Foundation; either version 2.1, or (at your option) any\n\ ** later version.\n\ **\n\ ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY\n\ ** WARRANTY; without even the implied warranty of MERCHANTABILITY or\n\ ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License\n\ ** for more details.\n\ **\n\ ** You should have received a copy of the GNU General Public License\n\ ** along with ATS; see the file COPYING. If not, please write to the\n\ ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA\n\ ** 02110-1301, USA.\n\ *)\ ") // end of [atsode_copyright_LGPL) (* ****** ****** *) fun atscode_copyright_GPL_for_C (): atext = atext_apptxt3 ( atext_strcst "/* ", atscode_copyright_GPL (), atext_strcst " */" ) // end of [atscode_copyright_GPL_for_C] fun atscode_copyright_LGPL_for_C (): atext = atext_apptxt3 ( atext_strcst "/* ", atscode_copyright_LGPL (), atext_strcst " */" ) // end of [atscode_copyright_LGPL_for_C] (* ****** ****** *) fun atscode_author (x: string): atext = atext_appstr3 ("(* Author: ", x, " *)") fun atscode_authoremail (x: string): atext = atext_appstr3 ("(* Authoremail: ", x, " *)") (* ****** ****** *) fun atscode_start_time (x: string): atext = atext_appstr3 ("(* Start time: ", x, " *)") // end of [atscode_start_time] (* ****** ****** *) fun atscode_separator (): atext = atext_strcst ("(* ****** ****** *)") // end of [atscode_separator] fun atscode_separator_for_C (): atext = atext_strcst ("/* ****** ****** */") // end of [atscode_separator_for_C] (* ****** ****** *) fun atscode_decl_strcst (x: string): atext = atext_strcst (x) fun atscode_decl_strsub (x: string): atext = atext_strsub (x) (* ****** ****** *) fun atscode_eof_strsub (x: string): atext = atext_apptxt3 (atext_strcst"(* end of [", atext_strsub(x), atext_strcst"] *)") // end of [atscode_eof_strsub] fun atscode_eof_strsub_for_C (x: string): atext = atext_apptxt3 (atext_strcst"/* end of [", atext_strsub(x), atext_strcst"] */") // end of [atscode_eof_strsub_for_C] (* ****** ****** *) fun macextval (tname: string, vname: string): atext = let // val x = sprintf ( "macdef %s = $extval (%s, \"%s\")", @(vname, tname, vname) ) (* end of [val] *) // in atext_strptr (x) end // end of[macextval] (* ****** ****** *) #endif // end of [ATSDOC_POSTIATSATXT] (* ****** ****** *) (* end of [postiatsatxt_txt.hats] *) ats-lang-anairiats-0.2.11/utils/atsdoc/atsdoc_translate_item.dats0000664000175000017500000004302512223166166023647 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: August, 2011 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/pointer.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) // staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" typedef position = $LOC.position // macdef posincby1 (pos) = $LOC.position_incby_count (,(pos), 1u) macdef posincbyc (pos, i) = $LOC.position_incby_char (,(pos), ,(i)) // (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_lexbuf.sats" (* ****** ****** *) staload "atsdoc_translate.sats" (* ****** ****** *) #define i2c char_of_int (* ****** ****** *) macdef neof (i) = (,(i) != EOF) (* ****** ****** *) implement fprint_funarg (out, x) = case+ x of | FAint (int) => fprint_string (out, int) | FAident (ide) => fprint_string (out, ide) | FAstrsub (str) => let val () = fprint_char (out , '"') val () = fprint_string (out, str) val () = fprint_char (out , '"') in // nothing end // end of [FAstrsub] | FAfunres (res) => fprint_string (out, res) | FAnil () => fprint_string (out, "#error") // end of [fprint_funarg] implement fprint_funarglst (out, xs) = let fun loop (out: FILEref, xs: funarglst, i: int): void = case+ xs of | list_cons (x, xs) => let val () = if i > 0 then fprint_string (out, ", ") val () = fprint_funarg (out, x) in loop (out, xs, i+1) end // end of [list_cons] | list_nil () => () // end of [loop] val () = fprint_char (out, '\(') val () = loop (out, xs, 0) val () = fprint_char (out, ')') in // nothing end // end of [fprint_funarglst] (* ****** ****** *) absviewtype stroutptr (l:addr) extern fun stroutptr_make (): [l:agz] stroutptr (l) extern fun stroutptr_free {l:agz} (out: stroutptr l): List_vt (char) extern fun stroutptr2string {l:agz} (out: stroutptr l): string extern fun stroutptr_add_char {l:agz} (out: !stroutptr l, x: char): void extern fun stroutptr_add_string {l:agz} (out: !stroutptr l, x: string): void (* ****** ****** *) local // staload Q = "libats/SATS/linqueue_lst.sats" staload _(*anon*) = "libats/DATS/linqueue_lst.dats" // stadef T0 = $Q.QUEUE0(char) stadef T1 = $Q.QUEUE1(char) // assume stroutptr (l:addr) = (free_gc_v (T0, l), T1 @ l | ptr l) // in // in of [local] implement stroutptr_make () = let val [l:addr] (pfgc, pfat | p) = ptr_alloc () val () = $Q.queue_initialize (!p) in #[l | (pfgc, pfat | p)] end // end of [stroutptr_make] implement stroutptr_free (out) = let prval pfat = out.1; val p = out.2 val xs = $Q.queue_uninitialize (!p) val () = ptr_free {T0} (out.0, pfat | p) in xs end // end of [stroutptr_free] implement stroutptr_add_char (out, x) = let prval pf = out.1 val () = $Q.queue_insert (!(out.2), x) prval () = out.1 := pf in // nothing end // end of [stroutptr_add_char] end // end of [local] implement stroutptr2string (out) = let val cs = stroutptr_free (out) val n = list_vt_length (cs) val buf = string_make_list_int ($UN.castvwtp1 (cs), n) val () = list_vt_free (cs) in string_of_strbuf (buf) end // end of [stroutptr2string] implement stroutptr_add_string {l} (out, x) = let fun loop {n,i:nat | i <= n} (out: !stroutptr l, x: string n, i: size_t i): void = if string_isnot_atend (x, i) then let val () = stroutptr_add_char (out, x[i]) in loop (out, x, i+1) end // end of [if] val x = string1_of_string (x) in loop (out, x, 0) end // end [stroutptr_add_string] (* ****** ****** *) extern fun trans_extcode_START {l:agz} ( out: !stroutptr l, buf: &lexbuf, pos0: &position, pos: &position ) : void // end of [trans_extcode_START] (* ****** ****** *) implement trans_extcode (buf, pos0, pos) = let val out = stroutptr_make () val () = trans_extcode_START (out, buf, pos0, pos) val loc = $LOC.location_make_pos_pos (pos0, pos) val str = stroutptr2string (out) val ext = tranitm_make (loc, EXTCODE (str)) val () = the_tranitmlst_add (ext) in // nothing end // end of [trans_extcode] implement trans_extcode_START (out, buf, pos0, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then let val c = (i2c)i in case+ c of | '%' when // HX: only if '%}' initiates a newline $LOC.position_get_ncol (pos) = 0 => let val res = testing_literal (buf, pos, "%}") in if res >= 0 then ( // HX: '%}' is skipped ) else let val () = posincby1 (pos) val () = stroutptr_add_char (out, c) in trans_extcode_START (out, buf, pos0, pos) end // end of [if] end // end of ['%' when ...] | _ => let val () = posincbyc (pos, i) val () = stroutptr_add_char (out, c) in trans_extcode_START (out, buf, pos0, pos) end // end of [_] end else ( lexbufpos2_docerr (buf, pos0, pos, DE_EXTCODE_unclose) ) (* end of [if] *) // end // end of [trans_extcode_START] (* ****** ****** *) #define SQUOTE '\'' #define DQUOTE '"' #define SHARP '#' #define SLASH '\\' extern fun trans_string {l:agz} ( // single quoted SDQ: char, out: !stroutptr l, buf: &lexbuf, pos0: &position, pos: &position ) : void // end of [trans_sstring] extern fun trans_string_SHARP {l:agz} (out: !stroutptr l, buf: &lexbuf, pos: &position): void // end of [trans_sstring_SHARP] extern fun trans_string_SLASH {l:agz} (SDQ: char, out: !stroutptr l, buf: &lexbuf, pos: &position): void // end of [trans_sstring_SLASH] (* ****** ****** *) implement trans_string (SDQ, out, buf, pos0, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then let val c = (i2c)i (* val () = fprintf (stderr_ref, "trans_dstring: c = %c\n", @(c)) *) in case+ c of | _ when c = SDQ => let val () = posincby1 (pos) in () // HX: closing properly end // end of [SDQ] | DQUOTE => let val () = posincby1 (pos) val () = stroutptr_add_char (out, SLASH) val () = stroutptr_add_char (out, DQUOTE) in trans_string (SDQ, out, buf, pos0, pos) end | SHARP => let val () = posincby1 (pos) val () = trans_string_SHARP (out, buf, pos) in trans_string (SDQ, out, buf, pos0, pos) end // end of [SHARP] | SLASH => let val () = posincby1 (pos) val () = trans_string_SLASH (SDQ, out, buf, pos) in trans_string (SDQ, out, buf, pos0, pos) end // end OF [SLASH] | _ => let val () = posincbyc (pos, i) val () = stroutptr_add_char (out, c) in trans_string (SDQ, out, buf, pos0, pos) end // end of [_] end else ( lexbufpos2_docerr (buf, pos0, pos, DE_STRING_unclose) ) (* end of [if] *) // end // end of [trans_dstring] implement trans_string_SHARP (out, buf, pos) = let var pos0: position val () = $LOC.position_copy (pos0, pos) val opt = trans_funcall (buf, pos0, pos) in // case+ opt of | ~Some_vt (fres) => let val () = stroutptr_add_char (out, '#') val () = stroutptr_add_string (out, fres) val () = stroutptr_add_char (out, '$') // HX: '$' is used as a sep! in // nothing end // end of [Some_vt] | ~None_vt () => let val () = stroutptr_add_char (out, '#') in (*nothing*) end // end of [if] // end // end of [trans_dstring_SHARP] (* ****** ****** *) implement trans_string_SLASH (SDQ, out, buf, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then let val c = (i2c)i in case+ c of | _ when c = SDQ => let val () = posincby1 (pos) val () = stroutptr_add_char (out, SLASH) val () = stroutptr_add_char (out, SDQ) in // nothing end // end of [SDQ] | SHARP => let val () = posincby1 (pos) in stroutptr_add_char (out, SHARP) end // end of [SHARP] | SLASH => let val () = posincby1 (pos) in stroutptr_add_char (out, SLASH) end // end of [SLASH] | _ => let val () = posincbyc (pos, i) val () = stroutptr_add_char (out, SLASH) val () = stroutptr_add_char (out, c) in // nothing end // end of [_] end else ( stroutptr_add_char (out, SLASH) ) (* end of [if] *) // end // end of [trans_dstring_SLASH] (* ****** ****** *) extern fun trans_funres (buf: &lexbuf, pos: &position): Option (string) // end of [trans_funres] extern fun trans_funres_LBRACKET (buf: &lexbuf, pos0: &position, pos: &position): Option (string) // end of [trans_funres_LBRACKET] (* ****** ****** *) implement trans_funres (buf, pos) = let val i = lexbufpos_get_char (buf, pos) in // if neof(i) then let val c = (i2c)i in case+ c of | '\[' => let var pos0: position val () = $LOC.position_copy (pos0, pos) val () = posincby1 (pos) in trans_funres_LBRACKET (buf, pos0, pos) end // end of ['\['] | _ => None () end else None () // end of [if] // end // end of [trans_funres] implement trans_funres_LBRACKET (buf, pos0, pos) = let // val k = testing_ident (buf, pos) val () = if k < 0 then lexbufpos2_docerr (buf, pos0, pos, DE_FUNRES_none) // end of [val] val k = (if k >= 0 then k else 0): int val k = (uint_of)k // val st0 = lexbuf_get_base (buf) val st1 = $LOC.position_get_ntot (pos0) val st = st1 - st0 val st = (uint_of)st val str = lexbuf_get_substrptr1 (buf, st+1u, k) val ide = string_of_strptr (str) // val i = lexbufpos_get_char (buf, pos) in // if i = int_of(']') then let val () = posincby1 (pos) in Some (ide) end else let val () = lexbufpos2_docerr (buf, pos0, pos, DE_FUNRES_unclose) in Some (ide) end // end of [if] // end // end of [trans_funres_LBRACKET] (* ****** ****** *) extern fun trans_funarg (buf: &lexbuf, pos: &position): funarg // end of [trans_funarg] extern fun trans_funarglst ( buf: &lexbuf, pos: &position, knd: &int, err: &int ) : funarglst // end of [trans_funarglst] extern fun trans_funarglst_OPEN ( buf: &lexbuf, pos0: &position, pos: &position, cls: char, err: &int, ind: int ) : funarglst // end of [trans_funarglst_OPEN] (* ****** ****** *) implement trans_funarg (buf, pos) = let // val _(*uint*) = testing_spaces (buf, pos) // val i = lexbufpos_get_char (buf, pos) // in // if neof(i) then let val c = (i2c)i in case+ c of | SQUOTE => let var pos0: position val () = $LOC.position_copy (pos0, pos) val () = posincby1 (pos) val out = stroutptr_make () val () = trans_string (SQUOTE, out, buf, pos0, pos) val str = stroutptr2string (out) in FAstrsub (str) end // end of [SQUOTE] | DQUOTE => let var pos0: position val () = $LOC.position_copy (pos0, pos) val () = posincby1 (pos) val out = stroutptr_make () val () = trans_string (DQUOTE, out, buf, pos0, pos) val str = stroutptr2string (out) in FAstrsub (str) end // end of ['"'] | SHARP => let var pos0: position val () = posincby1 (pos) val () = $LOC.position_copy (pos0, pos) val opt = trans_funcall (buf, pos0, pos) in case+ opt of | ~Some_vt (fres) => FAfunres (fres) | ~None_vt () => FAnil () end // end of [SHARP] | _ when DIGIT_test (c) => let val st0 = lexbuf_get_base (buf) val st1 = $LOC.position_get_ntot (pos) val st = st1 - st0 val st = (uint_of)st // val () = posincby1 (pos) val ln = ftesting_seq0 (buf, pos, DIGIT_test) (* val () = fprintf (stderr_ref, "trans_funarg: st = %u\n", @(st)) val () = fprintf (stderr_ref, "trans_funarg: ln = %u\n", @(ln)) *) val str = lexbuf_get_substrptr1 (buf, st, ln+1u) val str = string_of_strptr (str) (* val () = fprintf (stderr_ref, "trans_funarg: str = %s\n", @(str)) *) in FAint (str) end // end of [_ when ...] | _ when IDENTFST_test (c) => let // val st0 = lexbuf_get_base (buf) val st1 = $LOC.position_get_ntot (pos) val st = st1 - st0 val st = (uint_of)st // val () = posincby1 (pos) val ln = ftesting_seq0 (buf, pos, IDENTRST_test) (* val () = fprintf (stderr_ref, "trans_funarg: st = %u\n", @(st)) val () = fprintf (stderr_ref, "trans_funarg: ln = %u\n", @(ln)) *) val str = lexbuf_get_substrptr1 (buf, st, ln+1u) val str = string_of_strptr (str) (* val () = fprintf (stderr_ref, "trans_funarg: str = %s\n", @(str)) *) in FAident (str) end // end of [_ when ...] | _ => FAnil () end else ( FAnil () ) (* end of [if] *) // end // end of [trans_funarg] (* ****** ****** *) fn isdelim (c: char): bool = if c = '\(' then true else if c = '\{' then true else false // end of [isdelim] fn codelim (c: char): char = case+ c of '\(' => ')' | '\{' => '}' | _ => c // end of [codelim] fn delim_get_kind (c: char): int = if c = '\(' then 0 else if c = '\{' then 1 else ~1 // end of [delim_get_kind] implement trans_funarglst (buf, pos, knd, err) = let val i = lexbufpos_get_char (buf, pos) // in // if neof(i) then let val c = (i2c)i (* val () = fprintf (stderr_ref, "trans_funarglst: c = %c\n", @(c)) *) in case+ c of | _ when isdelim(c) => let var pos0: position val () = $LOC.position_copy (pos0, pos) val () = posincby1 (pos) val () = knd := delim_get_kind (c) val cls = codelim (c) in trans_funarglst_OPEN (buf, pos0, pos, cls, err, 0) end // end of ['"'] | _ => let val () = err := err + 1 in list_nil () end // end of [_] end else ( list_nil () ) (* end of [if] *) // end // end of [trans_funarglst] implement trans_funarglst_OPEN (buf, pos0, pos, cls, err, ind) = let // val _(*uint*) = testing_spaces (buf, pos) // val i = lexbufpos_get_char (buf, pos) // in // if neof(i) then let val c = (i2c)i in case+ c of | _ when c = cls => let val () = posincby1 (pos) in list_nil () end // end of [')'] | _ => ( if ind > 0 then ( if c = ',' then let val () = posincby1 (pos) val _(*uint*) = testing_spaces (buf, pos) val arg = trans_funarg (buf, pos) val args = trans_funarglst_OPEN (buf, pos0, pos, cls, err, ind+1) in list_cons (arg, args) end else let val () = err := err + 1 val () = lexbufpos2_docerr (buf, pos0, pos, DE_FUNARGLST_unclose) in list_nil () end // end of [if] ) else let val arg = trans_funarg (buf, pos) val args = trans_funarglst_OPEN (buf, pos0, pos, cls, err, ind+1) in list_cons (arg, args) end // end of [if] ) (* end of [_] *) end else let val () = err := err + 1 val () = lexbufpos2_docerr (buf, pos0, pos, DE_FUNARGLST_unclose) in list_nil () end (* end of [if] *) // end // end of [trans_funarglst_OPEN] (* ****** ****** *) implement trans_funcall (buf, pos0, pos) = let // val k = testing_ident (buf, pos) in // if k >= 0 then let // val st0 = lexbuf_get_base (buf) val st1 = $LOC.position_get_ntot (pos0) val st = st1 - st0 val st = (uint_of)st // val k = uint_of_int (k) val fnam = lexbuf_get_substrptr1 (buf, st, k) val fnam = string_of_strptr (fnam) val fres = funcall_get_fres () // HX: incrementally stamped // // HX: [fres] may be supplied by the user // val opt = trans_funres (buf, pos) val fres = (case opt of | Some ide => ide | None () => fres ) : string // end of [val] // var knd: int = 0 var err: int = 0 val xs = trans_funarglst (buf, pos, knd, err) val loc = $LOC.location_make_pos_pos (pos0, pos) val fcal = tranitm_make (loc, FUNCALL (fnam, knd, xs, fres)) val () = the_tranitmlst_add (fcal) // in Some_vt (fres) end else None_vt () // end of [if] // end // end of [trans_funcall] (* ****** ****** *) implement fprint_the_tranitmlst (out, basename) = let (* ** HX: [basename] is no longer needed! *) fun loop ( out: FILEref, xs: List (tranitm) ) : void = case+ xs of | list_cons (x, xs) => let val () = fprint_string (out, "(*\n") val () = $LOC.fprint_location (out, x.tranitm_loc) val () = fprint_string (out, "\n*)\n") val () = fprint_tranitm (out, x) val () = fprint_newline (out) // HX: more readable in loop (out, xs) end // end of [list_cons] | list_nil () => () // end of [loop] val xs = the_tranitmlst_get () val () = loop (out, $UN.castvwtp1 (xs)) val () = list_vt_free (xs) in // nothing end // end of [fprint_the_tranitmlst] (* ****** ****** *) (* end of [atsdoc_translate_item.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/0000700000175000017500000000000012223166165016424 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atslex/charset.dats0000664000175000017500000001443712223166165020757 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* * ATS - Unleashing the Power of Types! * * Copyright (C) 2002-2008 Hongwei Xi, Boston University * * All rights reserved * * ATS is free software; you can redistribute it and/or modify it under * the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the * Free Software Foundation; either version 2.1, or (at your option) any * later version. * * ATS is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * * You should have received a copy of the GNU General Public License * along with ATS; see the file COPYING. If not, write to the Free * Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301, USA. * *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "top.sats" (* ****** ****** *) datatype chars = | chars_nil | chars_cons of (char, char, chars) assume charset_t = chars // implement fprint_charset {m:file_mode} (pf_mod | fil, cs): void = let fun loop (fil: &FILE m, cs: chars): void = begin case+ cs of | chars_cons (c1, c2, cs) => begin if c1 = c2 then begin fprintf (pf_mod | fil, " '%c'", @(c1)); loop (fil, cs) end else begin fprintf (pf_mod | fil, " '%c'-'%c'", @(c1, c2)); loop (fil, cs) end end // end of [chars_cons] | chars_nil () => () end // end of [loop] in case+ cs of | chars_cons (c1, c2, cs) => begin if c1 = c2 then begin fprintf (pf_mod | fil, "[ '%c'", @(c1)); loop (fil, cs); fprint_string (pf_mod | fil, " ]") end else begin fprintf (pf_mod | fil, "[ '%c'-'%c'", @(c1, c2)); loop (fil, cs); fprint_string (pf_mod | fil, " ]") end // end of [if] end // end of [chars_cons] | chars_nil () => begin fprint_string (pf_mod | fil, "[]") end // end of [chars_nil] end // end of [fprint_charset] implement print_charset (cs) = print_mac (fprint_charset, cs) implement prerr_charset (cs) = prerr_mac (fprint_charset, cs) (* ****** ****** *) #define CHAR_NUL '\000' #define CHAR_MAX '\177' #define CHAR_EOF '\377' implement charset_nil = chars_nil () implement charset_all = chars_cons (CHAR_NUL, CHAR_MAX, chars_nil ()) // every char satisfying c <= -1 is treated as CHAR_EOF implement charset_eof = chars_cons (CHAR_EOF, CHAR_EOF, chars_nil ()) (* ****** ****** *) implement charset_interval (c1, c2) = begin if c1 <= c2 then chars_cons (c1, c2, chars_nil ()) else chars_cons (c2, c1, chars_nil ()) // end of [if] end // end of [charset_interval] implement charset_singleton c = chars_cons (c, c, chars_nil ()) // implement charset_complement (cs) = charset_difference (charset_all, cs) // implement charset_is_member (cs, c0) = loop (cs, c0) where { fun loop (cs: chars, c0: char): bool = begin case+ cs of | chars_cons (c1, c2, cs) => begin if c1 <= c0 then (if c0 <= c2 then true else loop (cs, c0)) else loop (cs, c0) end // end of [chars_cons] | chars_nil () => false end // end of [loop] } // end of [charset_is_member] // implement charset_union (cs1, cs2) = let fun loop (cs1: chars, cs2: chars) : chars = begin case+ (cs1, cs2) of | (chars_cons (c11, c12, cs10), chars_cons (c21, c22, cs20)) => begin if c21 < c11 then begin loop (cs2, cs1) end else if 1 < c21 - c12 then begin chars_cons (c11, c12, loop (cs10, cs2)) end else if c12 <= c22 then begin loop (chars_cons (c11, c22, cs20), cs10) end else begin loop (cs1, cs20) end end // end of [chars_cons _, chars_cons _] | (chars_nil (), _) => cs2 | (_, chars_nil ()) => cs1 end // end of [loop] in loop (cs1, cs2) end // end of [charset_union] // implement charset_intersect (cs1, cs2) = let fun loop (cs1: chars, cs2: chars) : chars = begin case+ (cs1, cs2) of | (chars_cons (c11, c12, cs10), chars_cons (c21, c22, cs20)) => begin if c21 < c11 then begin loop (cs2, cs1) end else if c12 < c21 then begin loop (cs10, cs2) end else if c12 <= c22 then begin chars_cons (c21, c12, loop (cs10, cs2)) end else begin chars_cons (c21, c22, loop (cs1, cs20)) end end // end of [chars_cons] | (chars_nil (), _) => chars_nil () | (_, chars_nil ()) => chars_nil () end // end of [loop] in loop (cs1, cs2) end // end of [charset_intersect] // implement add_char_int (c, i) = char_of_int (int_of_char c + i) implement sub_char_int (c, i) = char_of_int (int_of_char c - i) // implement charset_difference (cs1, cs2) = let fun loop (cs1: chars, cs2: chars) : chars = begin case+ (cs1, cs2) of | (chars_cons (c11, c12, cs10), chars_cons (c21, c22, cs20)) => begin if c12 < c21 then begin loop (cs10, cs2) end else if c22 < c11 then begin loop (cs1, cs20) end else if c12 <= c22 then begin if c11 < c21 then begin chars_cons (c11, c21-1, loop (cs10, cs2)) end else begin loop (cs10, cs2) end // end of [if] end else begin // c22 < c12 if c11 < c21 then begin chars_cons (c11, c21-1, loop (chars_cons (c22+1, c12, cs10), cs20)) end else begin loop (chars_cons (c22+1, c12, cs10), cs20) end // end of [if] end end // end of [chars_cons _, chars_cons _] | (chars_nil (), _) => chars_nil () | (_, chars_nil ()) => cs1 end // end of [loop] in loop (cs1, cs2) end // end of [charset_difference] (* ****** ****** *) (* end of [charset.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/states.dats0000664000175000017500000001301412223166165020617 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) (* ** ** The tagged states of a DFA are stored in a binary tree constructed ** according to the randomized binary search tree algorithm. ** *) // %{^ #include "libc/CATS/random.cats" %} // staload "top.sats" // dataviewtype states (int) = | STSnil (0) | {sl,sr:nat} STScons(1+sl+sr) of (int (1+sl+sr), int, intset_t, states sl, states sr) assume states_t = [n:nat] states n (* ****** ****** *) implement states_nil () = STSnil () implement states_free (sts): void = let fun free {s:nat} .. (sts: states s): void = case+ sts of | ~STScons (_, _, _, sts_l, sts_r) => (free sts_l; free sts_r) | ~STSnil () => () // end of [free] in free sts end // end of [states_free] (* ****** ****** *) implement states_find (sts, ns0): int = let fun loop {s:nat} .. (sts: !states s, ns0: intset_t): int = case+ sts of | STScons (s, tag, ns, !sts_l, !sts_r) => let val sgn = compare (ns0, ns) in case+ sgn of | ~1 => let val ans = loop (!sts_l, ns0) in fold@ sts; ans end | 1 => let val ans = loop (!sts_r, ns0) in fold@ sts; ans end | _ (*0*) => (fold@ sts; tag) end // end of [STScons] | STSnil () => (fold@ sts; ~1) // end of [loop] in loop (sts, ns0) end // end of [states_find] (* ****** ****** *) fn states_size {s:nat} (sts: !states s): int s = begin case+ sts of | STScons (s, _, _, _, _) => (fold@ sts; s) | STSnil () => (fold@ sts; 0) end // end of [states_size] (* ****** ****** *) #define i2d double_of_int staload Rand = "libc/SATS/random.sats" fn dice {m,n:pos} (m: int m, n: int n): bool = let val r = $Rand.drand48 () in i2d (m + n) * r < i2d m end // end of [dice] (* ****** ****** *) implement states_insert (sts, tag0, ns0) = let fun insert_at_root {s:nat} .. (sts: states s, tag0: int, ns0: intset_t): states (s+1) = case+ sts of | STScons (!p_s, tag, ns, !p_sts_l, !p_sts_r) => begin if compare (ns0, ns) >= 0 then let val sts_r_new = insert_at_root (!p_sts_r, tag0, ns0) val+ STScons (!p_sr, tag_r, ns_r, !p_sts_rl, !p_sts_rr) = sts_r_new val s = !p_s; val srr = states_size !p_sts_rr in !p_sts_r := !p_sts_rl; !p_s := s - srr; fold@ sts; !p_sts_rl := sts; !p_sr := s + 1; fold@ sts_r_new; sts_r_new end else let val sts_l_new = insert_at_root (!p_sts_l, tag0, ns0) val+ STScons (!p_sl, tag_l, ns_l, !p_sts_ll, !p_sts_lr) = sts_l_new val s = !p_s; val sll = states_size !p_sts_ll in !p_sts_l := !p_sts_lr; !p_s := s - sll; fold@ sts; !p_sts_lr := sts; !p_sl := s + 1; fold@ sts_l_new; sts_l_new end (* end of [if] *) end // end of [STScons] | ~STSnil () => STScons (1, tag0, ns0, STSnil (), STSnil ()) // end of [insert_at_root] fun insert_random {s:nat} .. (sts: states s, tag0: int, ns0: intset_t): states (s+1) = case+ sts of | STScons ( !p_s as s, tag, ns, !p_sts_l, !p_sts_r ) => begin if dice (1, s) then begin fold@ sts; insert_at_root (sts, tag0, ns0) end else begin if compare (ns0, ns) >= 0 then begin !p_sts_r := insert_random (!p_sts_r, tag0, ns0); !p_s := s + 1; fold@ sts; sts end else begin !p_sts_l := insert_random (!p_sts_l, tag0, ns0); !p_s := s + 1; fold@ sts; sts end (* end of [if] *) end (* end of [if] *) end // end of [STScons] | ~STSnil () => begin STScons (1, tag0, ns0, STSnil (), STSnil ()) end // end of [STSnil] // end of [insert_random] in sts := insert_random (sts, tag0, ns0) end // end of [insert_random] (* ****** ****** *) implement states_foreach_and_free {v} (pf | f, sts) = let viewtypedef cloptr_t = (!v | int, intset_t) - void fun aux {s:nat} .. (pf: !v | f: !cloptr_t, sts: states s): void = case+ sts of | ~STScons (s, tag, ns, sts_l, sts_r) => begin f (pf | tag, ns); aux (pf | f, sts_l); aux (pf | f, sts_r) end // end of [STScons] | ~STSnil () => () // end of [aux] in aux (pf | f, sts) end // end of [states_foreach_and_free] (* ****** ****** *) (* end of [states.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/EXAMPLE/0000700000175000017500000000000012223166165017517 5ustar hwxihwxiats-lang-anairiats-0.2.11/utils/atslex/EXAMPLE/calc_r.lats0000664000175000017500000004015512223166165021650 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2007 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) // Time: December, 2011 // (* ****** ****** *) (* ** ** A simple calculator for evaluating arithmetic expressions. ** With modifications to [calc.lats], this example ** shows how to write re-entrant lexers in ATS. ** *) (* The formats of supported commands: [var] = [exp] print [exp] quit Here is a session: ./calc << x = 1 + 2 << y = x + x << print x >> 3 << print y >> 6 << quit *) %{ // preamble staload "libc/SATS/stdio.sats" staload "libats/lex/lexing.sats" (* ****** ****** *) exception UncloseCommentException fun comment_is_unclosed (lb: &lexbuf_t): void = begin exit_errmsg {void} (1, "unclosed comment\n") ; end // end of [comment_is_unclosed] dataviewtype token = | TOKid of strptr1 | TOKint of int | TOKop_add | TOKop_sub | TOKop_mul | TOKop_div | TOKparen_l | TOKparen_r | TOKeq | TOKeof // end of [token] fun free_token (tok: token): void = case+ tok of | ~TOKid id => strptr_free id | ~TOKint i => () | ~TOKop_add () => () | ~TOKop_sub () => () | ~TOKop_mul () => () | ~TOKop_div () => () | ~TOKparen_l () => () | ~TOKparen_r () => () | ~TOKeq () => () | ~TOKeof () => () // end of [free_token] extern fun fprint_token {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, tok: !token): void implement fprint_token (pf_mod | fil, tok): void = case+ tok of | TOKid !s => (fprint (pf_mod | fil, "TOKid("); fprint (pf_mod | fil, !s); fprint (pf_mod | fil, ")"); fold@ tok) | TOKint i => (fprintf (pf_mod | fil, "TOKint(%i)", @(i)); fold@ tok) | TOKop_add () => (fprint_string (pf_mod | fil, "+"); fold@ tok) | TOKop_sub () => (fprint_string (pf_mod | fil, "-"); fold@ tok) | TOKop_mul () => (fprint_string (pf_mod | fil, "*"); fold@ tok) | TOKop_div () => (fprint_string (pf_mod | fil, "/"); fold@ tok) | TOKparen_l () => (fprint_string (pf_mod | fil, "("); fold@ tok) | TOKparen_r () => (fprint_string (pf_mod | fil, ")"); fold@ tok) | TOKeq () => (fprint_string (pf_mod | fil, "="); fold@ tok) | TOKeof () => (fprint_string (pf_mod | fil, "EOF"); fold@ tok) // end of [fprint_token] extern fun print_token (tok: !token): void implement print_token (tok) = let val (pf_stdout | stdout) = stdout_get () in fprint_token (file_mode_lte_w_w | !stdout, tok); stdout_view_set (pf_stdout | (*none*)) end // end of [print_token] extern fun prerr_token (tok: !token): void implement prerr_token (tok) = let val (pf_stderr | stderr) = stderr_get () in fprint_token (file_mode_lte_w_w | !stderr, tok); stderr_view_set (pf_stderr | (*none*)) end // end of [prerr_token] (* ****** ****** *) %{^ extern long int strtol (const char *nptr, char **endptr, int base) ; ats_int_type __strtoi (ats_ptr_type str, ats_int_type base) { return strtol ((char*)str, (char**)0, base) ; } // end of [__strtoi] %} fun lexeme_int (lb: &lexbuf_t, base: int): int = let val str = lexeme_strptr_lexbuf (lb) val res = __strtoi (str, base) in strptr_free str; res end where { extern fun __strtoi (str: !strptr1, base: int): int = "__strtoi" } // end of [lexeme_int] (* ****** ****** *) extern fun TOKEN (mylexbuf: &lexbuf_t): token fn TOKEN_lexing_error {a:viewt@ype} (mylexbuf: &lexbuf_t): a = lexing_error () extern fun COMMENT (mylexbuf: &lexbuf_t, level: int): void fn COMMENT_lexing_error {a:viewt@ype} (mylexbuf: &lexbuf_t, level: int): a = lexing_error () extern fun COMMENT_LINE (mylexbuf: &lexbuf_t): void fn COMMENT_LINE_lexing_error {a:viewt@ype} (mylexbuf: &lexbuf_t): a = lexing_error () extern fun COMMENT_REST (mylexbuf: &lexbuf_t): void fn COMMENT_REST_lexing_error {a:viewt@ype} (mylexbuf: &lexbuf_t): a = lexing_error () (* ****** ****** *) %} // definition of constants of regular expressions (* 011: \t; \014: \f; \015: \r *) blank = [ '\f' '\r' '\t' ' ' ] + xdigit = [ '0'-'9' 'a'-'f' 'A'-'F' ] ident_fst = [ 'A'-'Z' 'a'-'z' '_' ] ident_rst = [ '0'-'9' 'A'-'Z' 'a'-'z' '_' '\'' ] ident = $ident_fst $ident_rst * sgn = ['+' '-']? int8 = $sgn '0' ['0'-'7']* int10 = $sgn ['1'-'9'] ['0'-'9']* int16 = $sgn '0' [ 'x' 'X'] $xdigit+ newline = '\n' %% TOKEN () = | $blank { TOKEN (mylexbuf) } | $newline { TOKEN (mylexbuf) } | "(*" { COMMENT (mylexbuf, 0); TOKEN (mylexbuf) } | "//" { COMMENT_LINE (mylexbuf); TOKEN (mylexbuf) } | "////" { COMMENT_REST (mylexbuf); TOKeof () } | $ident { TOKid (lexeme_strptr_lexbuf (mylexbuf)) } | $int8 { TOKint (lexeme_int (mylexbuf, 8)) } | $int10 { TOKint (lexeme_int (mylexbuf, 10)) } | $int16 { TOKint (lexeme_int (mylexbuf, 16)) } | '=' { TOKeq () } | '+' { TOKop_add () } | '-' { TOKop_sub () } | '*' { TOKop_mul () } | '/' { TOKop_div () } | '(' { TOKparen_l () } | ')' { TOKparen_r () } | $EOF { TOKeof () } COMMENT (level) = | "(*" { COMMENT (mylexbuf, level+1) } | "*)" { if level > 0 then COMMENT (mylexbuf, level-1) else () } | $newline { COMMENT (mylexbuf, level) } | $EOF { comment_is_unclosed (mylexbuf) } | [^] { COMMENT (mylexbuf, level) } COMMENT_LINE () = | [^ '\n']* { () } COMMENT_REST () = | [^]* { () } %% %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] // postamble in the lexer.sats dataviewtype exp = | EXPint of int | EXPadd of (exp, exp) | EXPsub of (exp, exp) | EXPmul of (exp, exp) | EXPdiv of (exp, exp) | EXPid of strptr1 | EXPerr fun free_exp (e0: exp): void = case+ e0 of | ~EXPint i => () | ~EXPadd (e1, e2) => (free_exp e1; free_exp e2) | ~EXPsub (e1, e2) => (free_exp e1; free_exp e2) | ~EXPmul (e1, e2) => (free_exp e1; free_exp e2) | ~EXPdiv (e1, e2) => (free_exp e1; free_exp e2) | ~EXPid id => strptr_free id | ~EXPerr () => () // end of [free_exp] fun print_exp (e0: !exp): void = case+ e0 of | EXPint i => begin print "EXPint("; print i; print ")"; fold@ e0 end | EXPadd (!p_e1, !p_e2) => begin print "EXPadd("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPsub (!p_e1, !p_e2) => begin print "EXPsub("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPmul (!p_e1, !p_e2) => begin print "EXPmul("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPdiv (!p_e1, !p_e2) => begin print "EXPdiv("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPid (!id) => (print "EXPid("; print (!id); print ")"; fold@ e0) | EXPerr () => (print "EXPerr("; print ")"; fold@ e0) // end of [print_exp] dataviewtype cmd = | CMDassgn of (strptr1, exp) | CMDerror | CMDprint of exp | CMDquit fun free_cmd (cmd: cmd): void = begin case+ cmd of | ~CMDassgn (id, e) => (strptr_free id; free_exp e) | ~CMDerror () => () | ~CMDprint e => free_exp e | ~CMDquit () => () end // end of [free_cmd] // exception EvalErrorException (* [var] := [identifier] [exp0] := [var] | [integer] | ( [exp2] ) [exp0_r] := * [exp0] | / [exp0] | (* empty *) [exp1] := [exp0] [exp1_r] [exp1_r] := + [exp1] | - [exp1] | (* empty *) [exp2] := [exp1] [exp1_r] *) fun parse_paren_r (lb: &lexbuf_t, tok: &token, err: &int): void = case+ tok of | ~TOKparen_r () => (tok := TOKEN (lb)) | tok_v => (tok := tok_v; err := err + 1) // end of [parse_paren_r] fun parse_exp_0 (lb: &lexbuf_t, tok: &token, err: &int): exp = case tok of | ~TOKint i => (tok := TOKEN (lb); EXPint i) | ~TOKid id => (tok := TOKEN (lb); EXPid id) | ~TOKparen_l () => let val () = tok := TOKEN (lb) val e = parse_exp_2 (lb, tok, err) in parse_paren_r (lb, tok, err); e end | tok_v => begin free_token tok_v; err := err + 1; tok := TOKEN (lb); EXPerr end // end of [parse_exp_0] and parse_exp_0_r (lb: &lexbuf_t, tok: &token, err: &int, e0: exp): exp = case tok of | ~TOKop_mul () => let val () = tok := TOKEN (lb) val e1 = parse_exp_0 (lb, tok, err) in parse_exp_0_r (lb, tok, err, EXPmul (e0, e1)) end | ~TOKop_div () => let val () = tok := TOKEN (lb) val e1 = parse_exp_0 (lb, tok, err) in parse_exp_0_r (lb, tok, err, EXPdiv (e0, e1)) end | tok_v => (tok := tok_v; e0) // end of [parse_exp_0_r] and parse_exp_1 (lb: &lexbuf_t, tok: &token, err: &int): exp = let val e0 = parse_exp_0 (lb, tok, err) in parse_exp_0_r (lb, tok, err, e0) end // end of [parse_exp_1] and parse_exp_1_r (lb: &lexbuf_t, tok: &token, err: &int, e0: exp): exp = case tok of | ~TOKop_add () => let val () = tok := TOKEN (lb) val e1 = parse_exp_1 (lb, tok, err) in parse_exp_1_r (lb, tok, err, EXPadd (e0, e1)) end | ~TOKop_sub () => let val () = tok := TOKEN (lb) val e1 = parse_exp_1 (lb, tok, err) in parse_exp_1_r (lb, tok, err, EXPsub (e0, e1)) end | tok_v => (tok := tok_v; e0) // end of [parse_exp_1_r] and parse_exp_2 (lb: &lexbuf_t, tok: &token, err: &int): exp = let val e0 = parse_exp_1 (lb, tok, err) in parse_exp_1_r (lb, tok, err, e0) end // end of [parse_exp_2] // fun parse_eq (lb: &lexbuf_t, tok: &token, err: &int): void = case+ tok of | ~TOKeq () => (tok := TOKEN (lb)) | tok_v => (tok := tok_v; err := err + 1) // end of [parse_eq] // (* [cmd] := [var] = [exp2] | print [exp2] | quit *) fun parse_cmd (lb: &lexbuf_t, tok: &token, err: &int): cmd = let extern fun eq_strptr_string (x: !strptr1, y: string) : bool = "atspre_eq_string_string" // end of [eq_strptr_string] overload = with eq_strptr_string in case+ tok of | ~TOKid id when id = "print" => let val () = strptr_free id val () = tok := TOKEN (lb) val e = parse_exp_2 (lb, tok, err) in CMDprint e end | ~TOKid id when id = "quit" => (strptr_free id; tok := TOKEN (lb); CMDquit ()) | ~TOKid id => let val () = tok := TOKEN (lb) val () = parse_eq (lb, tok, err) val e = parse_exp_2 (lb, tok, err) in CMDassgn (id, e) end | tok_v => (tok := tok_v; CMDerror ()) end // end of [parse_cmd] // dataviewtype env = ENVnil | ENVcons of (strptr1, int, env) fun free_env (env: env): void = case+ env of | ~ENVcons (id, _, env1) => (free_env env1; strptr_free id) | ~ENVnil () => () fun print_env (env: !env): void = case+ env of | ENVcons (!id, i, !env1) => (print (!id); print " = "; print i; print_newline (); print_env (!env1); fold@ env) | ENVnil () => (fold@ env) fun env_find (env: !env, id0: strptr1): int = case+ env of | ENVcons (!id, i, !env1) => let extern fun eq_strptr_strptr (x: !strptr1, y: !strptr1) :<> bool = "atspre_eq_string_string" // end of [eq_strptr_strptr] overload = with eq_strptr_strptr in if id0 = !id then begin strptr_free id0; fold@ env; i end else let val res = env_find (!env1, id0) in fold@ env; res end // end of [if] end // end of [let] | ENVnil () => (strptr_free id0; fold@ env; 0) // end of [eval_find] fun eval_exp (env: &env, e0: exp): int = let (* val () = begin print "eval_exp: e0 = "; print_exp e0; print_newline () end // end of [val] *) in case+ e0 of | ~EXPint i => i | ~EXPadd (e1, e2) => eval_exp (env, e1) + eval_exp (env, e2) | ~EXPsub (e1, e2) => eval_exp (env, e1) - eval_exp (env, e2) | ~EXPmul (e1, e2) => eval_exp (env, e1) * eval_exp (env, e2) | ~EXPdiv (e1, e2) => eval_exp (env, e1) / eval_exp (env, e2) | ~EXPid (id) => env_find (env, id) | ~EXPerr () => $raise EvalErrorException end // end of [eval_exp] fun eval_cmd (env: &env, cmd: cmd): int = case+ cmd of | ~CMDassgn (id, e) => let val i = eval_exp (env, e) in (* print "eval_cmd: before:\n"; print_env env; *) env := ENVcons (id, i, env); (* print "eval_cmd: after:\n"; print_env env; *) 0 end | ~CMDprint e => let val i = eval_exp (env, e) in print ">> "; print i; print_newline (); 0 end // end of [CMDprint] | ~CMDquit () => 1 | ~CMDerror () => begin print "The command is illegal; please try again:\n"; 0 end // end of [CMDerror] // end of [eval_cmd] extern fun getline (): strptr1 fun eval_string (env: &env, input: strptr1): int = let val (pf_infil | p_infil) = infile_make_strptr input val (pf_lexbuf | lexbuf) = lexbuf_make_infile (pf_infil | p_infil) var tok: token = TOKEN (!lexbuf) var err: int = (0: int) val cmd = parse_cmd (!lexbuf, tok, err) (* val () = begin print "eval_string: err = "; print err; print_newline () end // end of [val] *) val cmd = ( if err > 0 then (free_cmd cmd; CMDerror ()) else cmd ) : cmd (* val () = begin print "eval_string: tok = "; print_token tok; print_newline () end // end of [val] *) val cmd = (case+ tok of | ~TOKeof () => cmd | tok_v => (free_token tok_v; free_cmd cmd; CMDerror ()) ) : cmd val res = eval_cmd (env, cmd) in lexbuf_free (pf_lexbuf | lexbuf); res end // end of [eval_string] (* ****** ****** *) dynload "libats/lex/lexing.dats" (* ****** ****** *) implement main (argc, argv) = let // var env0 = ENVnil () // fun read_eval_print (env: &env >> env?): void = let val () = print "<< " val () = fflush_stdout () val input = getline () val i = eval_string (env, input) in if i = 0 then read_eval_print (env) else (free_env env) end // end of [read_eval_print] // in // read_eval_print (env0) // end // end of [main] (* ****** ****** *) dataviewtype charlst (int) = | charlst_nil (0) | {n:nat} charlst_cons (n+1) of (char, charlst n) // end of [charlst] #define nil charlst_nil #define :: charlst_cons #define cons charlst_cons extern fun charlst_is_nil {n:nat} (cs: !charlst n): bool (n == 0) = "charlst_is_nil" implement charlst_is_nil (cs) = case+ cs of | nil _ => (fold@ cs; true) | cons _ => (fold@ cs; false) // end of [charlst_is_nil] extern fun charlst_uncons {n:pos} (cs: &charlst n >> charlst (n-1)): char = "charlst_uncons" implement charlst_uncons (cs) = let val ~(c :: cs_r) = cs in cs := cs_r; c end // end of [charlst_uncons] extern fun strptr_make_charlst_int {n:nat} (cs: charlst n, n: int n): strptr1 = "strptr_make_charlst_int" %{$ ats_ptr_type strptr_make_charlst_int ( ats_ptr_type cs, const ats_int_type n ) { char *s0, *s; s0 = (char*)ATS_MALLOC(n+1) ; s = s0 + n ; *s = '\0' ; --s ; while (!charlst_is_nil(cs)) { *s = charlst_uncons(&cs) ; --s ; } return s0 ; } // end of [strptr_make_charlst_int] %} // end of [%{$] implement getline () = let fun loop {n:nat} ( cs: charlst n, n: int n ) : strptr1 = let val c = getchar () in if c >= 0 then begin case+ char_of_int c of | '\n' => strptr_make_charlst_int (cs, n) | c => loop (charlst_cons (c, cs), n+1) end else begin strptr_make_charlst_int (cs, n) end end // end of [let] // end of [loop] in loop (charlst_nil (), 0) end // end of [getline] (* ****** ****** *) (* end of [calc.lats] *) ats-lang-anairiats-0.2.11/utils/atslex/EXAMPLE/Makefile0000664000175000017500000000406612223166165021201 0ustar hwxihwxi######################################################################### # # # Applied Type System # # # # Hongwei Xi # # # ######################################################################### # # ATS - Unleashing the Power of Types! # # Copyright (C) 2002-2007 Hongwei Xi. # # ATS is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free # Software Foundation; either version 2.1, or (at your option) any later # version. # # ATS is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with ATS; see the file COPYING. If not, write to the Free # Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # ###### # # A simple example of using [atslex] # ###### ATSCC=$(ATSHOME)/bin/atscc ATSLEX=$(ATSHOME)/bin/atslex ###### calc: calc_lats_dats.c; $(ATSCC) -g -o calc $< -lats_lex calc_r: calc_r_lats_dats.c; $(ATSCC) -g -o calc_r $< -lats_lex ###### calc_lats.dats: calc.lats; $(ATSLEX) < $< > $@ calc_lats_dats.c: calc_lats.dats; $(ATSCC) -c calc_lats.dats calc_r_lats.dats: calc_r.lats; $(ATSLEX) --reentrant < $< > $@ calc_r_lats_dats.c: calc_r_lats.dats; $(ATSCC) -c calc_r_lats.dats ###### clean:: rm -f *~ rm -f calc_lats.dats calc_lats_dats.c calc_lats_dats.o rm -f calc_r_lats.dats calc_r_lats_dats.c calc_r_lats_dats.o cleanall:: clean rm -f ./calc rm -f ./calc_r ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/utils/atslex/EXAMPLE/calc.lats0000664000175000017500000003620612223166165021331 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2007 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) (* ** ** A simple calculator for evaluating arithmetic expressions. ** This example shows how lexical analysis can be done in ATS. ** Also, it shows some typical uses of dataviewtypes, a.k.a. ** linear datatypes. ** *) (* The formats of supported commands: [var] = [exp] print [exp] quit Here is a session: ./calc << x = 1 + 2 << y = x + x << print x >> 3 << print y >> 6 << quit *) %{ // preamble staload "libc/SATS/stdio.sats" staload "libats/lex/lexing.sats" (* ****** ****** *) exception UncloseCommentException fun comment_is_unclosed (): void = begin exit_errmsg {void} (1, "unclosed comment\n") ; end // end of [comment_is_unclosed] dataviewtype token = | TOKid of string | TOKint of int | TOKop_add | TOKop_sub | TOKop_mul | TOKop_div | TOKparen_l | TOKparen_r | TOKeq | TOKeof // end of [token] fun free_token (tok: token): void = case+ tok of | ~TOKid id => () | ~TOKint i => () | ~TOKop_add () => () | ~TOKop_sub () => () | ~TOKop_mul () => () | ~TOKop_div () => () | ~TOKparen_l () => () | ~TOKparen_r () => () | ~TOKeq () => () | ~TOKeof () => () // end of [free_token] extern fun fprint_token {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, tok: !token): void implement fprint_token (pf_mod | fil, tok): void = case+ tok of | TOKid s => (fprintf (pf_mod | fil, "TOKid(%s)", @(s)); fold@ tok) | TOKint i => (fprintf (pf_mod | fil, "TOKint(%i)", @(i)); fold@ tok) | TOKop_add () => (fprint_string (pf_mod | fil, "+"); fold@ tok) | TOKop_sub () => (fprint_string (pf_mod | fil, "-"); fold@ tok) | TOKop_mul () => (fprint_string (pf_mod | fil, "*"); fold@ tok) | TOKop_div () => (fprint_string (pf_mod | fil, "/"); fold@ tok) | TOKparen_l () => (fprint_string (pf_mod | fil, "("); fold@ tok) | TOKparen_r () => (fprint_string (pf_mod | fil, ")"); fold@ tok) | TOKeq () => (fprint_string (pf_mod | fil, "="); fold@ tok) | TOKeof () => (fprint_string (pf_mod | fil, "EOF"); fold@ tok) // end of [fprint_token] extern fun print_token (tok: !token): void implement print_token (tok) = let val (pf_stdout | stdout) = stdout_get () in fprint_token (file_mode_lte_w_w | !stdout, tok); stdout_view_set (pf_stdout | (*none*)) end // end of [print_token] extern fun prerr_token (tok: !token): void implement prerr_token (tok) = let val (pf_stderr | stderr) = stderr_get () in fprint_token (file_mode_lte_w_w | !stderr, tok); stderr_view_set (pf_stderr | (*none*)) end // end of [prerr_token] (* ****** ****** *) %{^ extern long int strtol (const char *nptr, char **endptr, int base) ; ats_int_type __strtoi (ats_ptr_type str, ats_int_type base) { return strtol ((char*)str, (char**)0, base) ; } // end of [__strtoi] %} fun lexeme_int (base: int): int = let val str = lexeme_string () in __strtoi (str, base) end where { extern fun __strtoi (str: string, base: int): int = "__strtoi" } // end of [lexeme_int] (* ****** ****** *) extern fun TOKEN (): token fn TOKEN_lexing_error {a:viewt@ype} (): a = lexing_error () extern fun COMMENT (level: int): void fn COMMENT_lexing_error {a:viewt@ype} (level: int): a = lexing_error () extern fun COMMENT_LINE (): void fn COMMENT_LINE_lexing_error {a:viewt@ype} (): a = lexing_error () extern fun COMMENT_REST (): void fn COMMENT_REST_lexing_error {a:viewt@ype} (): a = lexing_error () (* ****** ****** *) %} // definition of constants of regular expressions (* 011: \t; \014: \f; \015: \r *) blank = [ '\f' '\r' '\t' ' ' ] + xdigit = [ '0'-'9' 'a'-'f' 'A'-'F' ] ident_fst = [ 'A'-'Z' 'a'-'z' '_' ] ident_rst = [ '0'-'9' 'A'-'Z' 'a'-'z' '_' '\'' ] ident = $ident_fst $ident_rst * sgn = ['+' '-']? int8 = $sgn '0' ['0'-'7']* int10 = $sgn ['1'-'9'] ['0'-'9']* int16 = $sgn '0' [ 'x' 'X'] $xdigit+ newline = '\n' %% TOKEN = | $blank { TOKEN () } | $newline { TOKEN () } | "(*" { COMMENT (0); TOKEN () } | "//" { COMMENT_LINE (); TOKEN () } | "////" { COMMENT_REST (); TOKeof () } | $ident { TOKid (lexeme_string ()) } | $int8 { TOKint (lexeme_int (8)) } | $int10 { TOKint (lexeme_int (10)) } | $int16 { TOKint (lexeme_int (16)) } | '=' { TOKeq () } | '+' { TOKop_add () } | '-' { TOKop_sub () } | '*' { TOKop_mul () } | '/' { TOKop_div () } | '(' { TOKparen_l () } | ')' { TOKparen_r () } | $EOF { TOKeof () } COMMENT (level) = | "(*" { COMMENT (level+1) } | "*)" { if level > 0 then COMMENT (level-1) else () } | $newline { COMMENT (level) } | $EOF { comment_is_unclosed () } | [^] { COMMENT (level) } COMMENT_LINE = | [^ '\n']* { () } COMMENT_REST = | [^]* { () } %% %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] // postamble in the lexer.sats dataviewtype exp = | EXPint of int | EXPadd of (exp, exp) | EXPsub of (exp, exp) | EXPmul of (exp, exp) | EXPdiv of (exp, exp) | EXPid of string | EXPerr fun free_exp (e0: exp): void = case+ e0 of | ~EXPint i => () | ~EXPadd (e1, e2) => (free_exp e1; free_exp e2) | ~EXPsub (e1, e2) => (free_exp e1; free_exp e2) | ~EXPmul (e1, e2) => (free_exp e1; free_exp e2) | ~EXPdiv (e1, e2) => (free_exp e1; free_exp e2) | ~EXPid id => () | ~EXPerr () => () // end of [free_exp] fun print_exp (e0: !exp): void = case+ e0 of | EXPint i => begin print "EXPint("; print i; print ")"; fold@ e0 end | EXPadd (!p_e1, !p_e2) => begin print "EXPadd("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPsub (!p_e1, !p_e2) => begin print "EXPsub("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPmul (!p_e1, !p_e2) => begin print "EXPmul("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPdiv (!p_e1, !p_e2) => begin print "EXPdiv("; print_exp !p_e1; print ", "; print_exp !p_e2; print ")"; fold@ e0 end | EXPid id => (print "EXPid("; print id; print ")"; fold@ e0) | EXPerr () => (print "EXPerr("; print ")"; fold@ e0) // end of [print_exp] dataviewtype cmd = | CMDassgn of (string, exp) | CMDerror | CMDprint of exp | CMDquit fun free_cmd (cmd: cmd): void = begin case+ cmd of | ~CMDassgn (id, e) => free_exp e | ~CMDerror () => () | ~CMDprint e => free_exp e | ~CMDquit () => () end // end of [free_cmd] // exception EvalErrorException (* [var] := [identifier] [exp0] := [var] | [integer] | ( [exp2] ) [exp0_r] := * [exp0] | / [exp0] | (* empty *) [exp1] := [exp0] [exp1_r] [exp1_r] := + [exp1] | - [exp1] | (* empty *) [exp2] := [exp1] [exp1_r] *) fun parse_paren_r (tok: &token, err: &int): void = case+ tok of | ~TOKparen_r () => (tok := TOKEN ()) | tok_v => (tok := tok_v; err := err + 1) // end of [parse_paren_r] fun parse_exp_0 (tok: &token, err: &int): exp = case tok of | ~TOKint i => (tok := TOKEN (); EXPint i) | ~TOKid id => (tok := TOKEN (); EXPid id) | ~TOKparen_l () => let val () = tok := TOKEN () val e = parse_exp_2 (tok, err) in parse_paren_r (tok, err); e end | tok_v => begin free_token tok_v; err := err + 1; tok := TOKEN (); EXPerr end // end of [parse_exp_0] and parse_exp_0_r (tok: &token, err: &int, e0: exp): exp = case tok of | ~TOKop_mul () => let val () = tok := TOKEN () val e1 = parse_exp_0 (tok, err) in parse_exp_0_r (tok, err, EXPmul (e0, e1)) end | ~TOKop_div () => let val () = tok := TOKEN () val e1 = parse_exp_0 (tok, err) in parse_exp_0_r (tok, err, EXPdiv (e0, e1)) end | tok_v => (tok := tok_v; e0) // end of [parse_exp_0_r] and parse_exp_1 (tok: &token, err: &int): exp = let val e0 = parse_exp_0 (tok, err) in parse_exp_0_r (tok, err, e0) end // end of [parse_exp_1] and parse_exp_1_r (tok: &token, err: &int, e0: exp): exp = case tok of | ~TOKop_add () => let val () = tok := TOKEN () val e1 = parse_exp_1 (tok, err) in parse_exp_1_r (tok, err, EXPadd (e0, e1)) end | ~TOKop_sub () => let val () = tok := TOKEN () val e1 = parse_exp_1 (tok, err) in parse_exp_1_r (tok, err, EXPsub (e0, e1)) end | tok_v => (tok := tok_v; e0) // end of [parse_exp_1_r] and parse_exp_2 (tok: &token, err: &int): exp = let val e0 = parse_exp_1 (tok, err) in parse_exp_1_r (tok, err, e0) end // end of [parse_exp_2] // fun parse_eq (tok: &token, err: &int): void = case+ tok of | ~TOKeq () => (tok := TOKEN ()) | tok_v => (tok := tok_v; err := err + 1) // end of [parse_eq] // (* [cmd] := [var] = [exp2] | print [exp2] | quit *) fun parse_cmd (tok: &token, err: &int): cmd = begin case+ tok of | ~TOKid id when id = "print" => let val () = tok := TOKEN () val e = parse_exp_2 (tok, err) in CMDprint e end | ~TOKid id when id = "quit" => (tok := TOKEN (); CMDquit ()) | ~TOKid id => let val () = tok := TOKEN () val () = parse_eq (tok, err) val e = parse_exp_2 (tok, err) in CMDassgn (id, e) end (* | ~TOKid id => begin case+ id of | "print" => let val () = tok := TOKEN () val e = parse_exp_2 (tok, err) in CMDprint e end | "quit" => (tok := TOKEN (); CMDquit ()) | _ => let val () = tok := TOKEN () val () = parse_eq (tok, err) val e = parse_exp_2 (tok, err) in CMDassgn (id, e) end end *) | tok_v => (tok := tok_v; CMDerror ()) end // end of [parse_cmd] // datatype env = ENVnil | ENVcons of (string, int, env) fun print_env (env: env): void = case+ env of | ENVcons (id, i, env) => (print id; print " = "; print i; print_newline (); print_env env) | ENVnil () => () fun env_find (env: env, id0: string): int = case+ env of | ENVcons (id, i, env) => if id0 = id then i else env_find (env, id0) | ENVnil () => 0 // end of [eval_find] fun eval_exp (env: &env, e0: exp): int = let (* val () = begin print "eval_exp: e0 = "; print_exp e0; print_newline () end // end of [val] *) in case+ e0 of | ~EXPint i => i | ~EXPadd (e1, e2) => eval_exp (env, e1) + eval_exp (env, e2) | ~EXPsub (e1, e2) => eval_exp (env, e1) - eval_exp (env, e2) | ~EXPmul (e1, e2) => eval_exp (env, e1) * eval_exp (env, e2) | ~EXPdiv (e1, e2) => eval_exp (env, e1) / eval_exp (env, e2) | ~EXPid (id) => env_find (env, id) | ~EXPerr () => $raise EvalErrorException end // end of [eval_exp] fun eval_cmd (env: &env, cmd: cmd): int = case+ cmd of | ~CMDassgn (id, e) => let val i = eval_exp (env, e) in (* print "eval_cmd: before:\n"; print_env env; *) env := ENVcons (id, i, env); (* print "eval_cmd: after:\n"; print_env env; *) 0 end | ~CMDprint e => let val i = eval_exp (env, e) in print ">> "; print i; print_newline (); 0 end // end of [CMDprint] | ~CMDquit () => 1 | ~CMDerror () => begin print "The command is illegal; please try again:\n"; 0 end // end of [CMDerror] // end of [eval_cmd] extern fun getline (): string fun eval_string (env: &env, input: string): int = let val (pf_infil | p_infil) = infile_make_string input val (pf_lexbuf | lexbuf) = lexbuf_make_infile (pf_infil | p_infil) val () = lexing_lexbuf_set (pf_lexbuf | lexbuf) var tok: token = TOKEN () var err: int = (0: int) val cmd = parse_cmd (tok, err) (* val () = begin print "eval_string: err = "; print err; print_newline () end // end of [val] *) val cmd = ( if err > 0 then (free_cmd cmd; CMDerror ()) else cmd ) : cmd (* val () = begin print "eval_string: tok = "; print_token tok; print_newline () end // end of [val] *) val cmd = (case+ tok of | ~TOKeof () => cmd | tok_v => (free_token tok_v; free_cmd cmd; CMDerror ()) ) : cmd in eval_cmd (env, cmd) end // end of [eval_string] (* ****** ****** *) dynload "libats/lex/lexing.dats" (* ****** ****** *) implement main (argc, argv) = let // var env0: env = ENVnil () // fun read_eval_print (env: &env): void = let val () = print "<< " val () = fflush_stdout () val input = getline () val i = eval_string (env, input) val () = lexing_lexbuf_free () in if i = 0 then read_eval_print (env) else () end // end of [read_eval_print] // in // read_eval_print (env0) // end // end of [main] (* ****** ****** *) dataviewtype charlst (int) = | charlst_nil (0) | {n:nat} charlst_cons (n+1) of (char, charlst n) // end of [charlst] #define nil charlst_nil #define :: charlst_cons #define cons charlst_cons extern fun charlst_is_nil {n:nat} (cs: !charlst n): bool (n == 0) = "charlst_is_nil" implement charlst_is_nil (cs) = case+ cs of | nil _ => (fold@ cs; true) | cons _ => (fold@ cs; false) // end of [charlst_is_nil] extern fun charlst_uncons {n:pos} (cs: &charlst n >> charlst (n-1)): char = "charlst_uncons" implement charlst_uncons (cs) = let val ~(c :: cs_r) = cs in cs := cs_r; c end // end of [charlst_uncons] extern fun string_make_charlst_int {n:nat} (cs: charlst n, n: int n): string n = "string_make_charlst_int" %{$ ats_ptr_type string_make_charlst_int ( ats_ptr_type cs, const ats_int_type n ) { char *s0, *s; s0 = ats_malloc_gc(n+1) ; s = s0 + n ; *s = '\0' ; --s ; while (!charlst_is_nil(cs)) { *s = charlst_uncons(&cs) ; --s ; } return s0 ; } // end of [string_make_charlst_int] %} // end of [%{$] implement getline () = let fun loop {n:nat} ( cs: charlst n, n: int n ) : string = let val c = getchar () in if c >= 0 then begin case+ char_of_int c of | '\n' => string_make_charlst_int (cs, n) | c => loop (charlst_cons (c, cs), n+1) end else begin string_make_charlst_int (cs, n) end end // end of [let] // end of [loop] in loop (charlst_nil (), 0) end // end of [getline] (* ****** ****** *) (* end of [calc.lats] *) ats-lang-anairiats-0.2.11/utils/atslex/token.dats0000664000175000017500000004646212223166165020451 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. ** *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) staload "top.sats" (* ****** ****** *) extern fun errmsg {a:viewt@ype} (msg: string): a implement errmsg (msg) = (prerr msg; prerr_newline (); exit 1) (* ****** ****** *) #define BASE 8 #define c2i int_of_char #define i2c char_of_int1 (* ****** ****** *) typedef intch = intBtw (~1, UCHAR_MAX+1) extern fun char_get (): intch = "char_get" extern fun char_update (): void = "char_update" extern fun char_get_update (): intch = "char_get_update" extern fun char_update_get (): intch = "char_update_get" extern fun pos_prev_reset (): void = "pos_prev_reset" %{^ static int the_line_cnt = 1 ; static int the_line_cnt_prev = 1 ; static int the_char_cnt = 0 ; static int the_char_cnt_prev = 0 ; ats_int_type pos_get_line () { return the_line_cnt ; } ats_int_type pos_get_char () { return the_char_cnt ; } ats_int_type pos_get_line_prev () { return the_line_cnt_prev ; } ats_int_type pos_get_char_prev () { return the_char_cnt_prev ; } ATSinline() ats_void_type pos_prev_reset ( // there is no argument for this fun ) { the_line_cnt_prev = the_line_cnt ; the_char_cnt_prev = the_char_cnt ; return ; } // end of [pos_prev_reset] /* ****** ****** */ ATSinline() ats_void_type pos_advance (ats_char_type c) { switch (c) { case '\n': ++the_line_cnt ; the_char_cnt = 0 ; break ; default: ++the_char_cnt ; break ; } /* end of [switch] */ return ; } static ats_int_type the_char ; ATSinline() ats_int_type char_get() { return the_char ; } ATSinline() ats_void_type char_update() { the_char = atslex_getchar () ; pos_advance (the_char) ; return ; } // end of [char_update] ATSinline() ats_int_type char_get_update() { int c = the_char ; the_char = atslex_getchar () ; pos_advance (the_char) ; return c ; } // end of [char_get_update] ATSinline() ats_int_type char_update_get() { the_char = atslex_getchar () ; pos_advance (the_char) ; return the_char ; } // end of [char_update_get] %} // end of [%{^] (* ****** ****** *) dataviewtype chars (int) = | chars_nil (0) | {n:nat} chars_cons (n+1) of (char, chars n) // end of [chars] #define nil chars_nil #define :: chars_cons extern fun chars_is_nil {n:nat} (cs: !chars n): bool (n == 0) = "chars_is_nil" // end of [chars_is_nil] implement chars_is_nil (cs) = case+ cs of | nil () => (fold@ cs; true) | _ :: _ => (fold@ cs; false) // end of [chars_is_nil] extern fun chars_uncons {n:pos} (cs: &chars n >> chars (n-1)): char = "chars_uncons" // end of [chars_uncons] implement chars_uncons (cs) = let val+ ~(c :: cs1) = cs in cs := cs1; c end // end of [chars_uncons] fun chars_free {n:nat} (cs: chars n): void = case+ cs of ~(c :: cs) => chars_free cs | ~nil () => () // end of [chars_free] (* ****** ****** *) extern // [cs] must not contain null bytes fun string_make_charlst_rev_int {n:nat} ( cs: chars n, n: int n ) : string n = "string_make_charlst_rev_int" // end of [fun] %{$ ats_ptr_type string_make_charlst_rev_int (ats_ptr_type cs, const ats_int_type n) { char *s0, *s; s0 = ats_malloc_gc(n+1) ; s = s0 + n ; *s = '\0' ; --s ; while (!chars_is_nil(cs)) { *s = chars_uncons(&cs) ; --s ; } return s0 ; } /* string_make_charlst_rev_int */ %} // end of [%{$] (* ****** ****** *) implement tokenize_line_comment () = loop () where { fun loop (): void = let val c = char_get () in if c >= 0 then let val c = i2c c in char_update (); if c <> '\n' then loop () else () end else begin // end of [if] // loop returns end // end of [if] end // end of [let] } // end of [tokenize_line_comment] (* ****** ****** *) implement tokenize_rest_text () = loop (nil (), 0) where { fun loop {n:nat} (cs: chars n, n: int n): string = let val c = char_get () in if c >= 0 then let val c = i2c c in char_update (); loop (c :: cs, n+1) end else begin // c = EOF string_make_charlst_rev_int (cs, n) // the end of file is reached end // end of [if] end // end of [let] } // end of [tokenize_rest_text] (* ****** ****** *) fn errmsg_unclosed_logue (): string = let val pos = position_prev_get () in prerr_string ("The logue starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {string} (1) end // end of [errmsg_unclosed_logue] implement tokenize_logue () = loop (nil (), 0, 0) where { fun loop {n,level:nat} (cs: chars n, n: int n, level: int level): string = let val c = char_get () in if c >= 0 then let val c = i2c c in case+ c of | '%' => let val c1 = char_update_get () in if c1 >= 0 then let val c1 = i2c c1 in case+ c1 of | '}' => if level > 0 then begin char_update (); loop (c1 :: c :: cs, n+2, level-1) end else begin char_update (); string_make_charlst_rev_int (cs, n) end // end of ['}'] | '\{' => begin char_update (); loop (c1 :: c :: cs, n+2, level+1) end // end of ['\{'] | _ => loop (c :: cs, n+1, level) end else begin // c1 = EOF chars_free cs; errmsg_unclosed_logue () end // end of [if] end (* end of ['%'] *) | _ (* c <> '%' *) => begin char_update (); loop (c :: cs, n+1, level) end // end of [_] end else begin // c = EOF chars_free cs; errmsg_unclosed_logue () end // end of [if] end // end of [loop] } // end of [tokenize_logue] (* ****** ****** *) fn errmsg_unclosed_funarg (): string = let val pos = position_prev_get () in prerr_string ("The function argument starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {string} (1) end // end of [errmsg_unclosed_funarg] implement tokenize_funarg () = loop (nil (), 0) where { fun loop {n:nat} (cs: chars n, n: int n): string = let val c = char_get () in if c >= 0 then let val c = i2c c in case+ c of | ')' => begin char_update (); string_make_charlst_rev_int (cs, n) end // end of [')'] | _ => (char_update (); loop (c :: cs, n+1)) end else begin chars_free cs; errmsg_unclosed_funarg () end // end of [if] end // end of [loop] } // end of [tokenize_funarg] (* ****** ****** *) fn errmsg_char_esc (): char = let val pos = position_prev_get () in prerr_string ("The escaped char at ["); prerr_pos pos; prerr_string ("] is not supported."); prerr_newline (); exit {char} (1) end // end of [errmsg_char_esc] fun tokenize_char_esc_code (ci: int, i: int): int = if i < 2 then let val c = char_get () in if c >= 0 then let val c = i2c c in case+ 0 of | _ when char_isdigit c => begin char_update (); tokenize_char_esc_code (BASE * ci + (c - '0'), i+1) end // end of [_ when ...] | _ => ci // end of [_] end else ci end else begin ci // function returns: an error is to be reported later end // end of [if] // end of [tokenize_char_esc_code] fun tokenize_char_esc (): char = let val c = char_get_update () in case+ 0 of | _ when c >= 0 => let val c = i2c c in if char_isdigit c then char_of_int (tokenize_char_esc_code (c - '0', 0)) else begin case+ c of | 'a' => '\007' (* alert *) | 'b' => '\010' (* backspace *) | 'f' => '\014' (* line feed *) | 'n' => '\012' (* newline *) | 'r' => '\015' (* carriage return *) | 't' => '\011' (* horizonal tab *) | 'v' => '\013' (* vertical tab *) | _ => c (* no effect on other chars *) end // end of [if] end // end of [_ when ...] | _ (* c = EOF *) => '\000' // an error is to be reported later end // end of [tokenize_char_esc] fn errmsg_unclosed_char (): char = let val pos = position_prev_get () in prerr_string ("The char starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {char} (1) end // end of [errmsg_unclose_char] fun tokenize_char (): char = let val c0 = char_get (); val c = case+ 0 of | _ when c0 >= 0 => let val c0 = i2c c0 in case+ c0 of | '\\' => (char_update (); tokenize_char_esc ()) | '\'' => '\0' (* '' stands for '\0' *) | _ => (char_update (); c0) end // end of [_ when ...] | _ (* c0 < 0 *) => '\000' val c1 = char_get_update () in case+ 0 of | _ when c1 >= 0 => let val c1 = i2c c1 in if c1 <> '\'' then errmsg_unclosed_char () else c end // end of [_ when ...] | _ (* c1 < 0 *) => errmsg_unclosed_char () end // end of [tokenize_char] (* ****** ****** *) fn errmsg_unclosed_code (): string = let val pos = position_prev_get () in prerr_string ("The code starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {string} (1) end // end of [errmsg_unclosed_code] fun tokenize_code {n,level:nat} ( cs: chars n, n: int n, level: int level ) : string = let val c = char_get () in if c >= 0 then let val c = i2c c in case+ c of | '\{' => begin char_update (); tokenize_code (c :: cs, n+1, level+1) end // end of ['\{'] | '}' when level > 0 => begin char_update (); tokenize_code (c :: cs, n+1, level-1) end // end of ['}' when ...] | '}' (* level = 0 *) => begin char_update (); string_make_charlst_rev_int (cs, n) end // end of ['}'] | _ => begin char_update (); tokenize_code (c :: cs, n+1, level) end // end of [_] end else begin chars_free cs; errmsg_unclosed_code () end // end of [if] end // end of [tokenize_code] (* ****** ****** *) fn errmsg_unclosed_comment (): void = let val pos = position_prev_get () in prerr_string ("The comment starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {void} (1) end // end of [errmsg_unclosed_comment] fun tokenize_comment {level:nat} (level: int level): void = let val c = char_get () in if c >= 0 then let val c = i2c c in case+ c of | '\(' => let val c1 = char_update_get () in case+ 0 of | _ when c1 >= 0 => let val c1 = i2c c1 in case+ c1 of | '*' => tokenize_comment (level+1) | _ => tokenize_comment level end // end of [_ when ...] | _ (* c1 < 0 *) => tokenize_comment level end // end of ['\('] | '*' => let val c1 = char_update_get () in case+ 0 of | _ when c1 >= 0 => let val c1 = i2c c1 in case+ c1 of | ')' => begin if level > 0 then tokenize_comment (level-1) else char_update () end // end of [')'] | _ => tokenize_comment level end // end of [_ when ...] | _ (* c1 < 0 *) => tokenize_comment level end // end of ['*'] | _ => (char_update (); tokenize_comment level) end else begin errmsg_unclosed_comment () end // end of [if] end // end of [tokenize_comment] (* ****** ****** *) fun tokenize_int (i: int): int = let val c = char_get () in case+ 0 of | _ when c >= 0 => let val c = i2c c in if char_isdigit c then (char_update (); tokenize_int (BASE * i + (c - '0'))) else i end // end of [_ when ...] | _ (* c = EOF *) => i end // end of [tokenize_int] (* ****** ****** *) fun tokenize_string_char () = let val c = char_get_update () in case+ 0 of | _ when c >= 0 => let val c = i2c c in if c = '\\' then tokenize_char_esc () else c end // end of [_ when ...] | _ (* c = EOF *) => '\000' // an error is to be reported later end // end of [tokenize_string_char] fn errmsg_unclosed_string (): string = let val pos = position_prev_get () in prerr_string ("The string starting at ["); prerr_pos pos; prerr_string ("] is not closed."); prerr_newline (); exit {string} (1) end // end of [errmsg_unclosed_string] fun tokenize_string {n:nat} (cs: chars n, n: int n): string = let val c0 = char_get () in case+ 0 of | _ when (c0 >= 0) => let val c0 = i2c c0 in if c0 = '"' then begin char_update (); string_make_charlst_rev_int (cs, n) end else let val c = tokenize_string_char () in tokenize_string (c :: cs, n+1) end // end of [if] end // end of [_ when ...] | _ (* c0 < 0 *) => begin chars_free cs; errmsg_unclosed_string () end // end of [_] end // end of [tokenize_string] (* ****** ****** *) fn char_iseof (c: int): bool = if c >= 0 then false else true fn char_issymbl (c: char): bool = string_contains ("!%&#+-/:<=>@\\~`|*", c) fun tokenize_word_sym {n:nat} (cs: chars n, n: int n): string = let val c = char_get () in case+ 0 of | _ when c >= 0 => let val c = i2c c in if char_issymbl c then (char_update (); tokenize_word_sym (c :: cs, n+1)) else string_make_charlst_rev_int (cs, n) end // end of [_ when ...] | _ (* c = EOF *) => string_make_charlst_rev_int (cs, n) end // end of [tokenize_word_sym] fun tokenize_word_ide {n:nat} ( cs: chars n, n: int n ) : string = let val c = char_get () in case+ 0 of | _ when c >= 0 => let val c = i2c c in if char_islttr c then (char_update (); tokenize_word_ide (c :: cs, n+1)) else string_make_charlst_rev_int (cs, n) end // end of [_ when ...] | _ (* c = EOF *) => string_make_charlst_rev_int (cs, n) end where { fn char_islttr (c: char): bool = if char_isalnum c then true else c = '_' } // end of [tokenize_word_ide] (* ****** ****** *) extern fun fprint_token {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, tok: token): void = "fprint_token" implement fprint_token ( pf_mod | fil, tok ) = begin case+ tok of | TOKchar c => fprintf (pf_mod | fil, "char(%c)", @(c)) | TOKcode s => fprintf (pf_mod | fil, "code(%s)", @(s)) | TOKint i => fprintf (pf_mod | fil, "int(%i)", @(i)) | TOKstring s => fprintf (pf_mod | fil, "string(%s)", @(s)) | TOKword s => fprintf (pf_mod | fil, "word(%s)", @(s)) | TOKlit c => fprintf (pf_mod | fil, "lit(%c)", @(c)) | TOKmark s => fprintf (pf_mod | fil, "mark(%s)", @(s)) | TOKeof () => fprint_string (pf_mod | fil, "EOF") end // end of [fprint_token] implement print_token (tok) = () where { val (pf_stdout | ptr_stdout) = stdout_get () val () = fprint_token (file_mode_lte_w_w | !ptr_stdout, tok) val () = stdout_view_set (pf_stdout | (*none*)) } // end of [print_token] implement prerr_token (tok) = () where { val (pf_stderr | ptr_stderr) = stderr_get () val () = fprint_token (file_mode_lte_w_w | !ptr_stderr, tok) val () = stderr_view_set (pf_stderr | (*none*)) } // end of [prerr_token] (* ****** ****** *) fun pos_prev_reset_and_char_update (): void = (pos_prev_reset (); char_update ()) // end of [fun] extern fun tokenize (): token = "tokenize" implement tokenize () = let val c = char_get () in case+ 0 of | _ when c >= 0 => tokenize_main (i2c c) | _ (* c = EOF *) => TOKeof () end where { // fun tokenize_main (c: char) = case+ c of | '\'' => let val () = pos_prev_reset_and_char_update () in TOKchar (tokenize_char ()) end // end of ['\''] | '\(' => let val () = pos_prev_reset_and_char_update () val c1 = char_get (); val isstar = ( if c1 >= 0 then let val c1 = i2c c1 in case+ c1 of '*' => true | _ => false end else false ) : bool // end of [isstar] in if isstar then (tokenize_comment (0); tokenize ()) else TOKlit '\(' end // end of ['\('] | '/' => let val () = pos_prev_reset_and_char_update () val c1 = char_get (); val isslash = ( if c1 >= 0 then let val c1 = i2c c1 in case+ c1 of '/' => true | _ => false end else false ) : bool // end of [isslash] in if isslash then begin tokenize_line_comment (); tokenize () end else begin TOKword (tokenize_word_sym ('/' :: nil (), 1)) end // end of [if] end // end of ['/'] | '\{' => let val () = pos_prev_reset_and_char_update () in TOKcode (tokenize_code (nil (), 0, 0)) end // end of ['\{'] | '"' => let val () = pos_prev_reset_and_char_update () in TOKstring (tokenize_string (nil (), 0)) end // end of ['"'] | '_' => let val () = pos_prev_reset_and_char_update () in TOKword (tokenize_word_ide (c :: nil (), 1)) end // end of ['_'] | '%' => let val () = pos_prev_reset_and_char_update () val c1 = char_get (); val islbrace = ( if c1 >= 0 then let val c1 = i2c c1 in case+ c1 of '\{' => true | _ => false end else false ) : bool // end of [islbrace] in if islbrace then begin char_update (); TOKmark "%{" end else begin TOKword (tokenize_word_sym (c :: nil (), 1)) end // end of [if] end // end of ['%'] | _ when char_isdigit c => let val () = pos_prev_reset_and_char_update () in TOKint (tokenize_int (c - '0')) end // end of [digit] | _ when char_isalpha c => let val () = pos_prev_reset_and_char_update () in TOKword (tokenize_word_ide (c :: nil (), 1)) end // end of [alpha] | _ when char_issymbl c => let val () = pos_prev_reset_and_char_update () in TOKword (tokenize_word_sym (c :: nil (), 1)) end // end of [symbl] | _ when char_isspace c => let val () = char_update () in tokenize () end // end of [space] | _ => let val () = pos_prev_reset_and_char_update () in TOKlit c end // end of [_] (* end of [tokenize_main] *) // } // end of [tokenize ... where ...] (* ****** ****** *) %{$ static ats_ptr_type the_token ; ats_ptr_type token_get () { return the_token ; } ats_void_type token_update () { the_token = tokenize () ; return ; } ats_ptr_type token_get_update () { ats_ptr_type tok = the_token ; the_token = tokenize () ; return tok; } // end of [token_get_update] %} // end of [%{$] (* ****** ****** *) // // HX: initialization // implement token_initialization () = let val () = char_update () // flush out a junk value val () = token_update () // flush out a junk value in // empty end // end of [let] (* ****** ****** *) (* end of [token.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/top.sats0000664000175000017500000001431012223166165020135 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) abstype pos_t (* defined in position.dats *) abstype charset_t (* defined in [charset.dats] *) abstype intset_t (* defined in [intset.dats] *) absviewtype states_t (* defined in [states.dats] *) datatype token = // type for tokens | TOKchar of char | TOKcode of string | TOKint of int | TOKstring of string | TOKword of string | TOKlit of char | TOKmark of string | TOKeof // end of [token] datatype regex = // type for regular expressions | REGalt of (regex, regex) | REGchars of charset_t | REGid of string | REGnil | REGopt of regex | REGplus of regex | REGrep of (regex, int) | REGseq of (regex, regex) | REGstar of regex | REGstr of string // end if [regex] datatype redef = | redef_nil | redef_cons of (string (* identifier *), regex, redef) // end of [redef] datatype rules = | rules_nil | rules_cons of (regex, string (* code for action *), rules) // end of [rules] datatype lexfns = | lexfns_nil | lexfns_cons of (string (*name*), string (*arg*), rules, lexfns) // end if [lexfns] typedef lexer = '{ preamble= string, redef= redef, lexfns= lexfns, postamble= string } // end of [lexer] (* ****** ****** *) fun the_atslex_input_fin (): void fun the_atslex_input_set {l:addr} (pf: FILE r @ l | p: ptr l): void fun atslex_getchar (): int = "atslex_getchar" fun atslex_get_reentrant (): bool fun atslex_set_reentrant (b: bool): void (* ****** ****** *) // // HX: implemented in [token.dats] // fun pos_get_line (): int = "pos_get_line" fun pos_get_char (): int = "pos_get_char" fun pos_get_line_prev (): int = "pos_get_line_prev" fun pos_get_char_prev (): int = "pos_get_char_prev" fun token_get (): token = "token_get" fun token_update (): void = "token_update" fun token_get_update (): token = "token_get_update" fun tokenize_line_comment (): void fun tokenize_rest_text (): string fun tokenize_logue (): string fun tokenize_funarg (): string fun print_token (tok: token): void = "print_token" fun prerr_token (tok: token): void = "prerr_token" fun token_initialization (): void (* ****** ****** *) // // HX: implemented in [position.dats] // fun position_get (): pos_t = "position_get" fun position_prev_get (): pos_t = "position_prev_get" fun print_pos (p: pos_t): void = "print_pos" fun prerr_pos (p: pos_t): void = "prerr_pos" (* ****** ****** *) // // HX: implemented in [charset.sats] // val char_max: char fun add_char_int (c: char, i: int): char fun sub_char_int (c: char, i: int): char overload + with add_char_int overload - with sub_char_int val charset_all: charset_t // the full charset val charset_nil: charset_t // the empty charset val charset_eof: charset_t fun charset_interval (c1: char, c2: char): charset_t fun charset_singleton (c: char): charset_t fun charset_complement (cs: charset_t): charset_t fun charset_difference (cs1: charset_t, cs2: charset_t): charset_t fun charset_intersect (cs1: charset_t, cs2: charset_t): charset_t fun charset_union (cs1: charset_t, cs2: charset_t): charset_t fun charset_is_member (cs: charset_t, c: char): bool fun fprint_charset {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, cs: charset_t): void = "fprint_charset" fun print_charset (cs: charset_t): void fun prerr_charset (cs: charset_t): void (* ****** ****** *) // // HX: implemented in [parser.dats] // fun print_regex (reg: regex): void fun prerr_regex (reg: regex): void fun lexer_parse (): lexer (* ****** ****** *) // // HX: implemented in [intset.dats] // val intset_nil : intset_t fun intset_is_nil (ns: intset_t): bool fun intset_singleton (n: int): intset_t fun eq_intset_intset (ns1: intset_t, ns2: intset_t): bool overload = with eq_intset_intset fun compare_intset_intset (ns1: intset_t, ns2: intset_t): Sgn overload compare with compare_intset_intset fun union_intset_intset (ns1: intset_t, ns2: intset_t): intset_t overload + with union_intset_intset fun fprint_intset {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, ns: intset_t): void = "fprint_intset" fun print_intset (cs: intset_t): void fun prerr_intset (cs: intset_t): void fun foreach_intset {v:view} (pf: !v | f: !(!v | int) - void, ns: intset_t): void // end of [foreach_intset] (* ****** ****** *) // // HX: implemented in [states.dats] // fun states_nil (): states_t fun states_free (sts: states_t): void fun states_find (sts: !states_t, ns0: intset_t): int fun states_insert (sts: &states_t, tag0: int, ns0: intset_t): void fun states_foreach_and_free {v:view} (pf: !v | f: !(!v | int, intset_t) - void, sts: states_t): void // end of [states_foreach_and_free] (* ****** ****** *) // // HX: implemented in [lexgen.dats] // fun fprint_lexfns {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, rds: redef, lfs: lexfns): void // end of [fprint_lexfns] (* ****** ****** *) (* end of top.sats *) ats-lang-anairiats-0.2.11/utils/atslex/Makefile0000664000175000017500000000501212223166165020076 0ustar hwxihwxi######################################################################### # # # Applied Type System # # # # Hongwei Xi # # # ######################################################################### # # ATS - Unleashing the Power of Types! # # Copyright (C) 2002-2007 Hongwei Xi. # # ATS is free software; you can redistribute it and/or modify it under # the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the # Free Software Foundation; either version 2.1, or (at your option) any # later version. # # ATS is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with ATS; see the file COPYING. If not, write to the Free # Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # ###### ATSHOMEQ="$(ATSHOME)" ATSCC=$(ATSHOMEQ)/bin/atscc #ATSCCFLAGS=-D_ATS_gc #ATSCCFLAGS=-D_ATS_gcats #ATSCCFLAGS=-D_ATS_GCATS ATSCCFLAGS= ATSRUNTIME=$(ATSHOMEQ)/ccomp/runtime CCFLAGS=-g -O2 INCLUDES=-I$(ATSHOMEQ) -I$(ATSRUNTIME) ###### atslex: \ atslex.dats top_sats.o lexgen_dats.o \ charset_dats.o intset_dats.o states_dats.o \ parser_dats.o position_dats.o token_dats.o $(ATSCC) $(ATSCCFLAGS) -o atslex \ atslex.dats top_sats.o lexgen_dats.o \ charset_dats.o intset_dats.o states_dats.o \ parser_dats.o position_dats.o token_dats.o ###### charset_dats.o: charset.dats $(ATSCC) $(CCFLAGS) -c charset.dats intset_dats.o: intset.dats $(ATSCC) $(CCFLAGS) -c intset.dats lexgen_dats.o: lexgen.dats $(ATSCC) $(CCFLAGS) -c lexgen.dats parser_dats.o: parser.dats $(ATSCC) $(CCFLAGS) -c parser.dats position_dats.o: position.dats $(ATSCC) $(CCFLAGS) -c position.dats states_dats.o: states.dats $(ATSCC) $(CCFLAGS) -c states.dats token_dats.o: token.dats $(ATSCC) $(CCFLAGS) -c token.dats top_sats.o: top.sats $(ATSCC) $(CCFLAGS) -c top.sats ###### clean:: rm -f *_sats.c *_dats.c *.o *~ cleanall: clean; rm -f atslex ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/utils/atslex/README0000664000175000017500000000273612223166165017330 0ustar hwxihwxi// // A lexer implemented in ATS and for ATS // Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) Time: July 2007. ###### beg of [README] ###### This is a plain implementation of a lexer. Except for a few minor changes, the algorithm used in the implementation basically follows the one given in the following book by Aho, Sethi and Ullman: "Compilers: principles, techniques and tools" The primary purpose of this implementation (as of now) is for bootstrapping ATS/Geizella. // atslex.dats : for defining the main function charset.dats : for representing sets of characters intset.dats : for representing sets of states position.dats : for recording positions in an input file lexgen.dats : for generating code for lexical analysis states.dats : for assigning numbers to states token.dats : for tokenization top.sats : for exporting various functions // Makefile: the makefile for [atslex] // lexing.sats : for exporting functions used in the generated code lexing.dats : for definiting functions used in the generated code tables.dats : for creating and accessing transition and accept tables // Usuage: [atslex] receives its input from STDIN and emits its output to STDOUT. For instance, the following command line reads from an input file named xyz.lats and write the generated ATS code to a file named xyz_lats.dats. atslex < xyz.lats > xyz_lats.dats It is recommended that .lats be used as the name extension for input files passed to atslex. ###### end of [README] ###### ats-lang-anairiats-0.2.11/utils/atslex/parser.dats0000664000175000017500000003355212223166165020621 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "top.sats" (* ****** ****** *) fun prerr_range (): void = let val pos_prev = position_prev_get () val pos = position_get () in prerr_pos pos_prev; prerr "-"; prerr_pos pos end // end of [prerr_range] fun errmsg_illegal {a:viewt@ype} (msg: string): a = begin prerr msg; prerr (": The token at ["); prerr_range (); prerr ("] is illegal."); prerr_newline (); exit {a} (1) end // end of [errmsg_illegal] (* ****** ****** *) fun errmsg_literal (c: char): void = begin prerr ("The token at ["); prerr_range (); prerr ("] is not ["); prerr_char (c); prerr ("]."); prerr_newline (); exit {void} (1) end // end of [errmsg_literal] fun literal (c0: char): void = let val tok = token_get () in case+ tok of | TOKlit c when c0 = c => token_update () | _ => errmsg_literal (c0) end // end of [literal] (* ****** ****** *) fun errmsg_litword (s: string): void = begin prerr ("The token at ["); prerr_range (); prerr ("] is not ["); prerr (s); prerr ("]."); prerr_newline (); exit {void} (1) end // end of [errmsg_litword] fun litword (s0: string): void = let val tok = token_get () in case+ tok of | TOKword s when s0 = s => token_update () | _ => errmsg_litword (s0) // end of [case] end // end of [litword] (* ****** ****** *) fun errmsg_char (): char = begin prerr ("The token at ["); prerr_range (); prerr ("] is not a char."); prerr_newline (); exit {char} (1) end // end of [errmsg_char] fun char (): char = let val tok = token_get () in case+ tok of | TOKchar c => (token_update (); c) | _ => errmsg_char () end // end of [char ()] (* ****** ****** *) fun errmsg_string (): string = begin prerr ("The token at ["); prerr_range (); prerr ("] is not a string."); prerr_newline (); exit {string} (1) end // end of [errmsg_string] fun string (): string = let val tok = token_get () in case+ tok of | TOKstring s => (token_update (); s) | _ => errmsg_string () end // end of [string ()] (* ****** ****** *) fun errmsg_ident (): string = begin prerr ("The token at ["); prerr_range (); prerr ("] is not an identifier."); prerr_newline (); exit {string} (1) end // end of [errmsg_ident] fun ident (): string = let val tok = token_get () in case+ tok of | TOKword s => (token_update (); s) | _ => errmsg_ident () end // end of [ident] (* ****** ****** *) fun errmsg_code (): string = begin prerr ("The token at ["); prerr_range (); prerr ("] is not code."); prerr_newline (); exit {string} (1) end // end of [errmsg_code] fun code (): string = let val tok = token_get () in case+ tok of | TOKcode s => (token_update (); s) | _ => errmsg_code () end // end of [code] (* ****** ****** *) fun charset_atm_r (c0: char): charset_t = let val tok = token_get () in case+ tok of | TOKword "-" => let val () = token_update (); val c1 = char () in charset_interval (c0, c1) end // end of [TOKword] | _ => charset_singleton c0 // end of [case] end // end of [charset_atm_r] fun charset_seq_r (cs0: charset_t): charset_t = let val tok = token_get () in case+ tok of | TOKchar c => let val () = token_update (); val cs1 = charset_atm_r c in charset_seq_r (charset_union (cs0, cs1)) end //end of [TOKchar] | _ => cs0 // end of [case] end // end of [charset_seq_r] (* ****** ****** *) fun charset_r (): charset_t = let val tok = token_get () in case+ tok of | TOKlit ']' => let val () = token_update () in charset_nil end // end of [TOKlit ']'] | TOKlit '^' => let val () = token_update (); val c = charset_r () in charset_complement (c) end // end of [TOKlit '^'] | TOKchar c => let val () = token_update () val cs = charset_seq_r (charset_atm_r c) val () = literal ']' in cs end // end of [TOKchar] | _ => begin errmsg_illegal {charset_t} ("charset_r") end // end of [_] // end of [case] end // end of [charset_seq_r] (* ****** ****** *) extern fun fprint_regex {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, reg: regex): void = "fprint_regex" implement fprint_regex (pf_mod | fil, reg): void = begin case+ reg of | REGalt (reg1, reg2) => begin fprint_string (pf_mod | fil, "REGalt("); fprint_regex (pf_mod | fil, reg1); fprint_string (pf_mod | fil, ", "); fprint_regex (pf_mod | fil, reg2); fprint_string (pf_mod | fil, ")"); end // end of [REGalt] | REGchars cs => begin fprint_string (pf_mod | fil, "REGchars("); fprint_charset (pf_mod | fil, cs); fprint_string (pf_mod | fil, ")"); end // end [REGchars] | REGid id => begin fprint_string (pf_mod | fil, "REGid("); fprint_string (pf_mod | fil, id); fprint_string (pf_mod | fil, ")"); end // end of [id] | REGnil () => begin fprint_string (pf_mod | fil, "REGnil()"); end // end of [REGnil] | REGopt reg => begin fprint_string (pf_mod | fil, "REGopt("); fprint_regex (pf_mod | fil, reg); fprint_string (pf_mod | fil, ")"); end // end of [REGopt] | REGplus reg => begin fprint_string (pf_mod | fil, "REGplus("); fprint_regex (pf_mod | fil, reg); fprint_string (pf_mod | fil, ")"); end // end of [REGplus] | REGrep (reg, i) => begin fprint_string (pf_mod | fil, "REGrep("); fprint_regex (pf_mod | fil, reg); fprint_string (pf_mod | fil, ", "); fprint_int (pf_mod | fil, i); fprint_string (pf_mod | fil, ")"); end // end of [REGrep] | REGseq (reg1, reg2) => begin fprint_string (pf_mod | fil, "REGseq("); fprint_regex (pf_mod | fil, reg1); fprint_string (pf_mod | fil, ", "); fprint_regex (pf_mod | fil, reg2); fprint_string (pf_mod | fil, ")"); end // end of [REGseq] | REGstar reg => begin fprint_string (pf_mod | fil, "REGstar("); fprint_regex (pf_mod | fil, reg); fprint_string (pf_mod | fil, ")"); end // end of [REGstar] | REGstr s => begin fprint_string (pf_mod | fil, "REGstr(\""); fprint_string (pf_mod | fil, s); fprint_string (pf_mod | fil, "\")"); end // end of [REGstr] end // end of [fprint_regex] implement print_regex (reg) = let val (pf_stdout | ptr_stdout) = stdout_get () in fprint_regex (file_mode_lte_w_w | !ptr_stdout, reg); stdout_view_set (pf_stdout | (*none*)) end // end of [print_regex] implement prerr_regex (reg) = let val (pf_stderr | ptr_stderr) = stderr_get () in fprint_regex (file_mode_lte_w_w | !ptr_stderr, reg); stderr_view_set (pf_stderr | (*none*)) end // end of [prerr_regex] (* ****** ****** *) fun is_regex_0 (): bool = begin case+ token_get () of | TOKword "_" => true | TOKchar c => true | TOKlit '$' => true | TOKstring s => true | TOKlit '\[' => true | TOKlit '\(' => true | _ => false end // end of [is_regex_0] fun regex_0 (): regex = let val tok = token_get () in case+ tok of | TOKword "_" => begin token_update (); REGchars (charset_all) end // end of [TOKword] | TOKchar c => begin token_update (); REGchars (charset_singleton c) end // end of [TOKchar] | TOKlit '$' => (token_update (); REGid (ident ())) | TOKstring s => (token_update (); REGstr s) | TOKlit '\[' => let val () = token_update (); val cs = charset_r () in REGchars cs end // end of [TOKlit] | TOKlit '\(' => let val () = token_update (); val re = regex_3 (); val () = literal ')' in re end // end of [TOKlit] | _ => errmsg_illegal {regex} ("regex_0") end // end of [regex_0] and regex_1 (): regex = begin let val reg = regex_0 () in regex_1_r (reg) end end // end of [regex_1] and regex_1_r (reg0: regex): regex = let val tok = token_get () in case+ tok of | TOKword "*" => let val () = token_update () in regex_1_r (REGstar reg0) end | TOKword "+" => let val () = token_update () in regex_1_r (REGplus reg0) end | TOKlit '?' => let val () = token_update () in regex_1_r (REGopt reg0) end | _ => reg0 // end of [case] end // end of [regex_1_r] and regex_2 (): regex = regex_2_r (regex_1 ()) and regex_2_r (reg0: regex): regex = begin if is_regex_0 () then let val reg1 = regex_1 () in regex_2_r (REGseq (reg0, reg1)) end else reg0 end // end of [regex_2_r] and regex_3 (): regex = regex_3_r (regex_2 ()) and regex_3_r (reg0: regex): regex = let val tok = token_get () in case+ tok of | TOKword "|" => let val () = token_update (); val reg1 = regex_2 () in regex_3_r (REGalt (reg0, reg1)) end // end of [TOKword] | _ => reg0 // end of [case] end // end of [regex_3_r] val regex = regex_3 (* ****** ****** *) fun redef_reverse (rds: redef): redef = let fun loop (rds1: redef, rds2: redef): redef = case+ rds1 of | redef_cons (id, reg, rds1) => loop (rds1, redef_cons (id, reg, rds2)) | redef_nil () => rds2 // end of [loop] in loop (rds, redef_nil ()) end // end of [redef_reverse] fun redef (rds: redef): redef = let val tok = token_get () in case+ tok of | TOKword id when id <> "%%" => let (* val () = (prerr "redef: id = "; prerr id; prerr_newline ()) *) val () = token_update () val () = litword ("=") val reg = regex () (* val () = (prerr "redef: reg = "; prerr_regex reg; prerr_newline ()) *) in redef (redef_cons (id, reg, rds)) end // end of [TOKword] | _ => redef_reverse rds // end of [case] end // end of [redef] (* ****** ****** *) fun rules_reverse (rls: rules): rules = let fun loop (rls1: rules, rls2: rules): rules = case+ rls1 of | rules_cons (r, s, rls1) => loop (rls1, rules_cons (r, s, rls2)) | rules_nil () => rls2 // end of [loop] in loop (rls, rules_nil ()) end // end of [rules_reverse] fun barrules (rls: rules): rules = let val tok = token_get () in case+ tok of | TOKword "|" => let val () = token_update () val reg = regex () val cstr = code () (* val () = (prerr "rules: reg = "; prerr_regex reg; prerr_newline ()) val () = (prerr "rules: cstr = "; prerr cstr; prerr_newline ()) *) in barrules (rules_cons (reg, cstr, rls)) end // end of [TOKword "|"] | _ => rules_reverse rls end // end of [barrules] fun rules (): rules = let val tok = token_get () in case+ tok of | TOKword "|" => barrules (rules_nil ()) | _ => let val reg = regex () (* val () = (prerr "rules: reg = "; prerr_regex reg; prerr_newline ()) *) val cstr = code () (* val () = (prerr "rules: cstr = "; prerr cstr; prerr_newline ()) *) in barrules (rules_cons (reg, cstr, rules_nil ())) end // end of [_] // end of [case] end // end of [rules] (* ****** ****** *) fun lexfn_funarg (): string = case+ token_get () of | TOKlit '\(' => begin let val arg = tokenize_funarg () in token_update (); arg end end | _ => "" // end of [lexfn_funarg] fun lexfns (): lexfns = case+ token_get () of | TOKword id when id <> "%%" => let (* val () = (prerr "lexfns: id = "; prerr id; prerr_newline ()) *) val () = token_update () val arg = lexfn_funarg () val () = litword "=" val rls = rules () in lexfns_cons (id, arg, rls, lexfns ()) end // end of [TOKword id when ...] | _ => lexfns_nil () // end of [lexfns] (* ****** ****** *) fun preamble (): string = let (* val () = begin prerr "preamble: enter"; prerr_newline () end *) val result = case+ token_get () of | TOKmark "%{" => begin let val s = tokenize_logue () in (token_update (); s) end end | _ => "" // end of [result] (* val () = begin prerr "preamble: leave"; prerr_newline () end // end of [val] *) in result end // end of [preamble] fun postamble (): string = case+ token_get () of | TOKword "%%" => let val s = tokenize_rest_text () in (token_update (); s) end // end of [TOKword "%%"] | _ => "" // end of [postamble] (* ****** ****** *) fun done (): void = let val tok = token_get () in case+ tok of | TOKeof () => () | _ => errmsg_illegal {void} "done" end // end of [done()] (* ****** ****** *) implement lexer_parse () = let val str1 = preamble () (* val () = (prerr "preamble =\n"; prerr str1; prerr_newline ()) *) val rds = redef (redef_nil ()) val () = litword "%%" val lfs = lexfns () val str2 = postamble () (* val () = (prerr "postamble =\n"; prerr str2; prerr_newline ()) *) // val () = done () // no need for this because of [postamble] in '{ preamble= str1, redef= rds, lexfns= lfs, postamble= str2 } end // end of [lexer_parse] (* ****** ****** *) (* end of [parser.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/position.dats0000664000175000017500000000616112223166165021165 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* * ATS - Unleashing the Power of Types! * * Copyright (C) 2002-2008 Hongwei Xi, Boston University * * All rights reserved * * ATS is free software; you can redistribute it and/or modify it under * the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the * Free Software Foundation; either version 2.1, or (at your option) any * later version. * * ATS is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * * You should have received a copy of the GNU General Public License * along with ATS; see the file COPYING. If not, write to the Free * Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301, USA. * *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) (* functions for manipulating positions in files *) // staload "top.sats" // (* ****** ****** *) typedef pos = '{line= int, char= int} assume pos_t = pos (* ****** ****** *) fun fprint_pos {m:file_mode} (pf_mod: file_mode_lte (m, w) | fil: &FILE m, p: pos): void = fprintf (pf_mod | fil, "%i.%i", @(p.line, p.char)) implement print_pos (p) = print_mac (fprint_pos, p) implement prerr_pos (p) = prerr_mac (fprint_pos, p) (* ****** ****** *) fn lt_pos_pos (p1: pos, p2: pos): bool = if p1.line < p2.line then true else if p1.line <= p2.line then p1.char < p2.char else false // end of [lt_pos_pos] fn lte_pos_pos (p1: pos, p2: pos): bool = if p1.line < p2.line then true else if p1.line <= p2.line then p1.char <= p2.char else false // end of [lte_pos_pos] overload < with lt_pos_pos overload <= with lte_pos_pos (* ****** ****** *) fun min_pos_pos (p1: pos, p2: pos): pos = if p1 <= p2 then p1 else p2 fun max_pos_pos (p1: pos, p2: pos): pos = if p1 <= p2 then p2 else p1 overload min with min_pos_pos overload max with max_pos_pos (* ****** ****** *) implement position_get () = let // [pos_line_get] is implemented in [token.dats] val line = pos_get_line () // [pos_char_get] is implemented in [token.dats] val char = pos_get_char () in '{line= line, char= char } end // end of [position_get] implement position_prev_get () = let // [pos_line_prev_get] is implemented in [token.dats] val line = pos_get_line_prev () // [pos_char_prev_get] is implemented in [token.dats] val char = pos_get_char_prev () in '{line= line, char= char } end // end of [position_prev_get] (* ****** ****** *) (* end of [position.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/lexgen.dats0000664000175000017500000006131212223166165020602 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) %{^ #include "prelude/CATS/array.cats" %} (* ****** ****** *) staload "top.sats" typedef intset = intset_t // datatype for regular expressions datatype regex1_node = | REG1alt of (regex1, regex1) | REG1chars of (int, charset_t) | REG1nil | REG1end of int | REG1opt of regex1 | REG1plus of regex1 | REG1seq of (regex1, regex1) | REG1star of regex1 | REG1null where regex1: type = '{ node= regex1_node, null= bool, fstpos= intset, lstpos= intset } (* ****** ****** *) exception Fatal (* ****** ****** *) datatype CSI = CSI_cs of charset_t | CSI_i of int dataviewtype CSIlst (int) = | CSIlst_nil (0) | {n:nat} CSIlst_cons (n+1) of (CSI, CSIlst n) extern fun CSI_uncons {n:pos} (lst: &CSIlst n >> CSIlst (n-1)): CSI = "CSI_uncons" implement CSI_uncons (lst) = let val+ ~CSIlst_cons (csi, lst_r) = lst in (lst := lst_r; csi) end viewtypedef T = [n:nat] @{ lst= CSIlst n, len= int n } (* ****** ****** *) fn regex1_alt ( r1: regex1, r2: regex1 ) : regex1 = let val null: bool = if r1.null then true else r2.null val fstpos = r1.fstpos + r2.fstpos val lstpos = r1.lstpos + r2.lstpos in '{ node= REG1alt (r1, r2) , null= null , fstpos= fstpos , lstpos= lstpos } end // end of [regex1_alt] // fn regex1_chars ( x: &T, cs: charset_t ) : regex1 = let val x_len = x.len val () = x.len := x_len + 1 val x_lst = x.lst val () = x.lst := CSIlst_cons (CSI_cs cs, x_lst) in '{ node= REG1chars (x_len, cs) , null= false , fstpos = intset_singleton x_len , lstpos = intset_singleton x_len } end // end of [regex1_chars] // fn regex1_end ( x: &T, irule: int ) : regex1 = let val x_len = x.len val () = x.len := x_len + 1 val x_lst = x.lst val () = x.lst := CSIlst_cons (CSI_i irule, x_lst) in '{ node= REG1end x_len , null= false , fstpos = intset_singleton x_len , lstpos = intset_singleton x_len } end // end of [regex1_end] // fn regex1_nil (): regex1 = '{ node= REG1nil () , null= true , fstpos = intset_nil , lstpos = intset_nil } // fn regex1_null (): regex1 = '{ node= REG1nil () , null= false , fstpos = intset_nil , lstpos = intset_nil } // fn regex1_seq ( r1: regex1, r2: regex1 ) : regex1 = let val null: bool = if r1.null then r2.null else false val fstpos: intset = if r1.null then r1.fstpos + r2.fstpos else r1.fstpos val lstpos: intset = if r2.null then r1.lstpos + r2.lstpos else r2.lstpos in '{ node= REG1seq (r1, r2) , null= null , fstpos= fstpos , lstpos= lstpos } end // end of [regex1_seq] // fn regex1_opt (r: regex1): regex1 = let val fstpos = r.fstpos and lstpos = r.lstpos in '{ node= REG1opt r , null= true , fstpos= fstpos , lstpos= lstpos } end // end of [regex1_opt] fn regex1_plus (r: regex1): regex1 = let val null = r.null and fstpos = r.fstpos and lstpos = r.lstpos in '{ node= REG1plus r , null= null , fstpos= fstpos , lstpos= lstpos } end // end of [regex1_plus] fn regex1_star (r: regex1): regex1 = let val fstpos = r.fstpos and lstpos = r.lstpos in '{ node= REG1star r , null= true , fstpos= fstpos , lstpos= lstpos } end // end of [regex1_star] (* ****** ****** *) fn redef_find ( env: redef, id0: string ) : Option regex = let fun loop (env: redef, id0: string): Option regex = begin case+ env of | redef_cons (id, r, env) => if (id0 = id) then Some {regex} (r) else loop (env, id0) | redef_nil () => None {regex} () end // end of [loop] in loop (env, id0) end // end of [redef_find] (* ****** ****** *) extern fun array_of_CSIlst {n:nat} ( lst: CSIlst n, n: int n ) :<> [l:addr] ( free_gc_v (CSI?, n, l), array_v (CSI, n, l) | ptr l ) = "array_of_CSIlst" %{ typedef ats_ptr_type CSI ; ats_ptr_type array_of_CSIlst ( ats_ptr_type lst, ats_int_type n ) { CSI *p0, *p ; p0 = atspre_array_ptr_alloc_tsz(n, sizeof(CSI)) ; p = p0 + (n-1) ; while (n > 0) { *p = CSI_uncons (&lst) ; --n ; --p ; } return p0 ; } // end of [array_of_CSIlst] %} (* ****** ****** *) fun regex_mark_str {i,l:nat | i <= l} .. ( env: redef, x0: &T, i: size_t i, l: size_t l, s: string l, r1e: regex1 ) : regex1 = begin if i < l then let val cs = charset_singleton s[i] val r1e = regex1_seq (r1e, regex1_chars (x0, cs)) in regex_mark_str (env, x0, i+1, l, s, r1e) end else r1e end // end of [regex_mark_str] (* ****** ****** *) fun regex_mark ( env: redef, x0: &T, r0e: regex ) : regex1 = begin case+ r0e of | REGalt (r0e1, r0e2) => let val r1e1 = regex_mark (env, x0, r0e1) val r1e2 = regex_mark (env, x0, r0e2) in regex1_alt (r1e1, r1e2) end | REGchars (cs) => regex1_chars (x0, cs) | REGnil () => regex1_nil () | REGid id => begin case+ redef_find (env, id) of | Some r0e0 => regex_mark (env, x0, r0e0) | None () => begin prerrf ("Undefined identifier: %s\n", @(id)); $raise Fatal () end end (* end of [REGid] *) | REGopt (r0e0) => regex1_opt (regex_mark (env, x0, r0e0)) | REGplus (r0e0) => regex1_plus (regex_mark (env, x0, r0e0)) | REGrep (r0e0, i) => if i > 0 then let val r1e0 = regex_mark (env, x0, r0e0) in regex_mark_rep (env, x0, i-1, r0e0, r1e0) end else regex1_nil () // end of [REGrep] | REGseq (r0e1, r0e2) => let val r1e1 = regex_mark (env, x0, r0e1) val r1e2 = regex_mark (env, x0, r0e2) in regex1_seq (r1e1, r1e2) end // end of [REGseq] | REGstar (r0e0) => regex1_star (regex_mark (env, x0, r0e0)) | REGstr (str) => let val str = string1_of_string str in regex_mark_str (env, x0, 0, string_length str, str, regex1_nil ()) end // end of [REGstr] end // end of [regex_mark] and regex_mark_rep ( env: redef, x0: &T, i: int, r0e: regex, r1e: regex1 ) : regex1 = if i > 0 then let val r1e' = regex_mark (env, x0, r0e) in regex_mark_rep (env, x0, i-1, r0e, regex1_seq (r1e, r1e')) end else r1e // end of [if] // end of [regex_mark_rep] (* ****** ****** *) fun followpos {n:nat} ( n0: int n, r: regex1 ) : [l:addr] ( free_gc_v (intset?, n, l), array_v (intset, n, l) | ptr l ) = let fun aux {l:addr} (pf: !array_v (intset, n, l) | A: ptr l, n0: int n, r: regex1): void = aux_node (pf | A, n0, r.node) and aux_node{l:addr} (pf: !array_v (intset, n, l) | A: ptr l, n0: int n, r_node: regex1_node) : void = case+ r_node of | REG1alt (r1, r2) => begin aux (pf | A, n0, r1); aux (pf | A, n0, r2) end // end of [REG1alt] | REG1chars (n, cs) => () | REG1end n => () | REG1nil () => () | REG1null () => () | REG1opt r0 => aux (pf | A, n0, r0) | REG1plus r0 => let val r0_fstpos = r0.fstpos val f = lam ( pf: !array_v (intset, n, l) | i: int ) : void = let val i = int1_of_int i (* val () = prerrf ("followpos: i = %i and n = %i\n", @(i,n)) *) val () = assert (0 <= i) val () = assert (i < n0) in A[i] := A[i] + r0_fstpos end // end of [f] val () = foreach_intset (pf | f, r0.lstpos) val () = cloptr_free (f) in aux (pf | A, n0, r0) end // end of [REG1plus] | REG1seq (r1, r2) => let val r2_fstpos = r2.fstpos val f = lam ( pf: !array_v (intset, n, l) | i: int ) : void = let val i = int1_of i (* val () = prerrf ("followpos: i = %i and n = %i\n", @(i,n)) *) val () = assert (0 <= i) val () = assert (i < n0) in A[i] := A[i] + r2_fstpos end // end of [f] val () = foreach_intset (pf | f, r1.lstpos) val () = cloptr_free (f) in aux (pf | A, n0, r1); aux (pf | A, n0, r2); end // end of [REG1seq] | REG1star r0 => let val r0_fstpos = r0.fstpos val f = lam ( pf: !array_v (intset, n, l) | i: int ) : void = let val i = int1_of i (* val () = prerrf ("followpos: i = %i and n = %i\n", @(i,n)) *) val () = assert (0 <= i) val () = assert (i < n0) in A[i] := A[i] + r0_fstpos end // end of [f] val () = foreach_intset (pf | f, r0.lstpos) val () = cloptr_free (f) in aux (pf | A, n0, r0) end // end of [REG1star] // end of [aux] and [aux_node] val n0_sz = size1_of_int1 n0 val tsz = sizeof val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {intset} (n0_sz, tsz) val () = begin array_ptr_initialize_elt_tsz {intset} (!p_arr, n0_sz, ini, tsz) end where { var ini: intset = intset_nil } // end of [val] val () = aux (pf_arr | p_arr, n0, r) in (pf_gc, pf_arr | p_arr) end // end of [followpos] (* ****** ****** *) fn rules_mark ( env: redef, x0: &T, rls: rules ) : regex1 = let fun aux ( env: redef, x0: &T, irule: int, rls: rules ) : regex1 = case+ rls of | rules_cons (r0e, act, rls) => let val r1e1 = regex_mark (env, x0, r0e) val r1e2 = regex1_end (x0, irule) val r1e_seq = regex1_seq (r1e1, r1e2) in regex1_alt (r1e_seq, aux (env, x0, irule+1, rls)) end | rules_nil () => regex1_null () // end of [aux] in aux (env, x0, 1, rls) // irule starts from 1! end (* rules_mark *) (* ****** ****** *) dataviewtype acclst = | acclst_nil of () | acclst_cons of (int (*state*), int (*rule*), acclst) // end of [acclst] dataviewtype intlst = intlst_nil | intlst_cons of (int, intlst) // end of [dataviewtype] dataviewtype statelst = | statelst_nil of () | statelst_cons of (intset, statelst) // end of [statelst] dataviewtype translst (int) = | translst_nil (0) of () | {n:nat} translst_cons (n+1) of (int, intlst, translst n) // end of [translst] viewtypedef Translst = [n:nat] translst n (* ****** ****** *) fn transition_char {n:nat} {l_csi,l_pos:addr} ( pf1: !array_v (CSI, n, l_csi) , pf2: !array_v (intset, n, l_pos) | A_csi: ptr l_csi , A_pos: ptr l_pos , n: int n, st: intset, c: char ) : intset = let (* val () = prerrf ("transition_char: c = %i\n", @(int_of c)) *) var st_res: intset = intset_nil viewdef V = ( array_v (CSI, n, l_csi), array_v (intset, n, l_pos), intset @ st_res ) // end of [viewdef] val f = lam ( pf: !V | i: int ) : void = let prval (pf1, pf2, pf3) = pf val i = int1_of_int i (* val () = prerrf ("transition_char: i = %i and n = %i\n", @(i, n)) val () = (prerr "transition_char: st_res = "; prerr_intset st_res; prerr_newline ()) *) val () = assert (0 <= i); val () = assert (i < n) val () = (case+ A_csi[i] of | CSI_cs cs => begin if charset_is_member (cs, c) then st_res := st_res + A_pos[i] end // end of [CSI_cs] | _ => () ) : void // end of [val] (* val () = (prerr "transition_char: st_res = "; prerr_intset st_res; prerr_newline ()) *) in pf := (pf1, pf2, pf3) end // end of [f] prval pf = (pf1, pf2, view@ st_res) val () = foreach_intset {V} (pf | f, st) prval () = (pf1 := pf.0; pf2 := pf.1; view@ st_res := pf.2) val () = cloptr_free (f) in st_res end // end of [transition_char] fun transition_one {n:nat} {l_csi,l_pos:addr} (pf1: !array_v (CSI, n, l_csi), pf2: !array_v (intset, n, l_pos) | A_csi: ptr l_csi, A_pos: ptr l_pos, n: int n, nst_r: &int, sts: &states_t, stlst: &statelst, st0: intset, c: char, ns: intlst): intlst = begin if int_of_char c >= ~1 then let val st = transition_char (pf1, pf2 | A_csi, A_pos, n, st0, c) val nst = states_find (sts, st) val nst = if nst < 0 then let // not found val nst = nst_r val () = nst_r := nst+1 val () = states_insert (sts, nst, st) val () = stlst := statelst_cons (st, stlst) in nst end else begin nst (* found *) end // end of [if] val ns = intlst_cons (nst, ns) in transition_one ( pf1, pf2 | A_csi, A_pos, n, nst_r, sts, stlst, st0, c-1, ns ) // end of [transition_one] end else begin ns end // end of [if] end (* end of [transition_one] *) macdef CHAR_MAX = '\177' fun transition_all {n:nat} {l_csi,l_pos:addr} (pf1: !array_v (CSI, n, l_csi), pf2: !array_v (intset, n, l_pos) | A_csi: ptr l_csi, A_pos: ptr l_pos, n: int n, nst_r: &int, sts: &states_t, stlst: statelst, ans: Translst): Translst = begin case+ stlst of | ~statelst_cons (st, stlst) => let val nst = states_find (sts, st) var stlst = stlst val ns = transition_one ( pf1, pf2 | A_csi, A_pos, n, nst_r, sts, stlst, st, CHAR_MAX, intlst_nil () ) // transition_one in transition_all ( pf1, pf2 | A_csi, A_pos, n, nst_r, sts, stlst, translst_cons (nst, ns, ans) ) // end of [transition_all] end | ~statelst_nil () => ans end // end of [transition_all] (* ****** ****** *) fun accept_one {n:nat} {l_csi:addr} ( pf1: !array_v (CSI, n, l_csi) | A_csi: ptr l_csi, n: int n, st: intset ) : int = let var irule = (0: int) viewdef V = (array_v (CSI, n, l_csi), int @ irule) val f = lam (pf: !V | nst: int): void = let prval (pf1, pf2) = pf val nst = int1_of_int nst (* val () = prerrf ("accept_one: i = %i and n = %i\n", @(i,n)) *) val () = assert (0 <= nst) val () = assert (nst < n) val () = case+ A_csi[nst] of | CSI_i i => begin if irule > 0 then (if i < irule then irule := i) else (irule := i) end // end of [CSI_i] | _ => () // end of [val] in pf := (pf1, pf2) end // end of [f] prval pf = (pf1, view@ irule) val () = foreach_intset {V} (pf | f, st) prval () = pf1 := pf.0; prval () = view@ irule := pf.1 val () = cloptr_free (f) in irule end // end of [accept_one] fun accept_all {n:nat} {l_csi:addr} ( pf1: !array_v (CSI, n, l_csi) | A_csi: ptr l_csi, n: int n, sts: states_t ) : acclst = let var ans: acclst = acclst_nil () viewdef V = (array_v (CSI, n, l_csi), acclst @ ans) val f = lam ( pf: !V | tag: int, st: intset ) : void = let prval (pf1, pf2) = pf val irule = accept_one (pf1 | A_csi, n, st) val () = if irule > 0 then ans := acclst_cons (tag, irule, ans) in pf := (pf1, pf2) end // end of [f] prval pf = (pf1, view@ ans) val () = states_foreach_and_free {V} (pf | f, sts) prval () = pf1 := pf.0; prval () = view@ ans := pf.1 val () = cloptr_free (f) in ans end // end of [accept_all] (* ****** ****** *) extern fun acclst_length (lst: !acclst): int = "acclst_length" // end of [acclst_length] implement acclst_length (lst) = let fun loop ( lst: !acclst, j: int ) : int = case+ lst of | acclst_cons (_, _, !lst_r) => let val n = loop (!lst_r, j+1) in fold@ lst; n end | acclst_nil () => (fold@ lst; j) // end of [loop] in loop (lst, 0) end // end of [acclst_length] (* ****** ****** *) extern fun translst_length {n:nat} (lst: !translst n): int n = "translst_length" // end of [translst_length] implement translst_length (lst) = let fun loop {i,j:nat} (lst: !translst i, j: int j): int(i+j) = case+ lst of | translst_cons (_, _, !lst_r) => let val n = loop (!lst_r, j+1) in fold@ lst; n end | translst_nil () => (fold@ lst; j) // end of [loop] in loop (lst, 0) end // end of [translst_length] (* ****** ****** *) extern fun translst_uncons {n:pos} ( lst: &translst n >> translst (n-1), tag: &(int?) >> int, ns: &intlst? >> intlst ) : void = "translst_uncons" implement translst_uncons (lst, tag, ns) = let val+ ~translst_cons (tag_v, ns_v, lst_v) = lst in tag := tag_v; ns := ns_v; lst := lst_v end // end of [translst_uncons] (* ****** ****** *) extern fun fprint_irule {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, i: int ) : void = "fprint_irule" extern fun fprint_state {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, n: int ) : void = "fprint_state" %{ ats_void_type fprint_irule ( ats_ptr_type fil, ats_int_type i ) { // int x, x0, x1, x2 ; // x = i >> 8 ; x2 = '0' + (x & 07) ; x >>= 3 ; x1 = '0' + (x & 07) ; x >>= 3 ; x0 = '0' + (x & 07) ; x >>= 3 ; fputc ('\\', fil); fputc (x0, fil) ; fputc (x1, fil) ; fputc (x2, fil) ; // if (x != 0) { fprintf ( stderr, "lexgen.dats: fprint_irule: rule number is too large: %i .\n", i ) ; exit (1) ; } // end of [if] // x = i & 0xff ; x2 = '0' + (x & 07) ; x >>= 3 ; x1 = '0' + (x & 07) ; x >>= 3 ; x0 = '0' + (x & 07) ; fputc ('\\', fil); fputc (x0, fil) ; fputc (x1, fil) ; fputc (x2, fil) ; // return ; } // end of [fprint_irule] ats_void_type fprint_state ( ats_ptr_type fil, ats_int_type n ) { // int x, x0, x1, x2 ; // x = n >> 8 ; x2 = '0' + (x & 07) ; x >>= 3 ; x1 = '0' + (x & 07) ; x >>= 3 ; x0 = '0' + (x & 07) ; x >>= 3 ; fputc ('\\', fil); fputc (x0, fil) ; fputc (x1, fil) ; fputc (x2, fil) ; // if (x != 0) { fprintf ( stderr, "lexgen.dats: fprint_state: state number is too large: %i .\n", n ) ; exit (1) ; } // end of [fprint_state] // x = n & 0xff ; x2 = '0' + (x & 07) ; x >>= 3 ; x1 = '0' + (x & 07) ; x >>= 3 ; x0 = '0' + (x & 07) ; fputc ('\\', fil); fputc (x0, fil) ; fputc (x1, fil) ; fputc (x2, fil) ; // return ; } // end of [fprint_state] %} extern fun fprint_intlst {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, ns: intlst ) : void = "fprint_intlst" // // printing as well as freeing // implement fprint_intlst {m} (pf_mod | fil, ns) = let fun loop ( fil: &FILE m, ns: intlst ) : void = case+ ns of | ~intlst_cons (n, ns) => ( fprint_state (pf_mod | fil, n); loop (fil, ns) ) // end of [intlst_cons] | ~intlst_nil () => () // end of [loop] val () = loop (fil, ns) val () = fprint_char (pf_mod | fil, '\\') in // nothing end // end of [fprint_intlst] (* ****** ****** *) extern typedef "intlst" = intlst // printing as well as freeing extern fun fprint_translst {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, lst: Translst ) : void = "fprint_translst" %{ ats_void_type fprint_translst ( ats_ptr_type fil , ats_ptr_type lst ) { int i, n, tag ; intlst ns, *A; n = translst_length (lst) ; // this is really just radix sorting A = ats_malloc_ngc((n+1)*sizeof(intlst)) ; // A[0] is unused for (i = 1; i <= n; ++i) { translst_uncons (&lst, &tag, &ns) ; /* fprintf (stderr, "fprint_translst: i = %i and tag = %i\n", i, tag); */ A[tag] = ns ; } // end of [for] for (i = 1; i <= n; ++i) { fprint_intlst (fil, A[i]) ; fprintf ((FILE*)fil, "\n") ; } // end of [for] ats_free_ngc(A) ; return ; } // end of [fprint_translst] %} // // HX: freeing as well // fun fprint_acclst {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, lst: acclst ) : void = let fun loop ( fil: &FILE m, lst: acclst ) : void = case+ lst of | ~acclst_cons (n, i, lst) => begin fprint_state (pf_mod | fil, n); fprint_irule (pf_mod | fil, i); fprint_char (pf_mod | fil, '\\'); fprint_newline (pf_mod | fil); loop (fil, lst) end // end of [acclst_cons] | ~acclst_nil () => () // end of [loop] in loop (fil, lst) end // end of [fprint_acclst] (* ****** ****** *) fun fprint_header {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, id: string, arg: string ) : void = let val isreent = atslex_get_reentrant () in fprintf (pf_mod | fil, "implement %s (", @(id)); if isreent then begin fprint_string (pf_mod | fil, "mylexbuf"); if string_isnot_empty arg then fprint_string (pf_mod | fil, ", "); end; // end of [if] fprintf (pf_mod | fil, "%s) =\n", @(arg)); if ~isreent then begin fprint_string (pf_mod | fil, "case+ lexing_engine (__") end else begin fprint_string (pf_mod | fil, "case+ lexing_engine_lexbuf (mylexbuf, __"); end; // end of [if] fprint_string (pf_mod | fil, id); fprint_string (pf_mod | fil, "_transition_table, __"); fprint_string (pf_mod | fil, id); fprint_string (pf_mod | fil, "_accept_table) of"); fprint_newline (pf_mod | fil) end // end of [fprint_header] (* ****** ****** *) fun fprint_rules {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, id: string, arg: string, rls: rules ) : void = let val isreent = atslex_get_reentrant () fun loop ( fil: &FILE m, rls: rules, irule: int ) : void = case+ rls of | rules_cons (r, code, rls) => begin fprintf (pf_mod | fil, " | %i => ( %s )\n", @(irule, code)); loop (fil, rls, irule + 1) end // end of [rules_cons] | rules_nil () => () // end of [loop] in loop (fil, rls, 1); fprintf (pf_mod | fil, " | _ => %s_lexing_error (", @(id)); if isreent then begin fprint_string (pf_mod | fil, "mylexbuf"); if string_isnot_empty arg then fprint_string (pf_mod | fil, ", "); end; // end of [if] fprintf (pf_mod | fil, "%s)\n", @(arg)) end // end of [fprint_rules] (* ****** ****** *) extern fun fprint_DFA {m:file_mode} ( pf_mod: file_mode_lte (m, w) | fil: &FILE m, env: redef, id: string, arg: string, rls: rules ) : void // end of [fprint_DFA] val regex_eof = REGchars charset_eof implement fprint_DFA ( pf_mod | fil, env, id, arg, rls ) = let // var x0: T = @{ lst= CSIlst_nil (), len= 0 } // EOF is pre-defined and cannot be overwritten val env = redef_cons ("EOF", regex_eof, env) val root_regex1 = rules_mark (env, x0, rls) val root_fstpos = root_regex1.fstpos // (* val () = fprint_string (pf_mod | fil, "root_fstpos = ") val () = fprint_intset (pf_mod | fil, root_fstpos) val () = fprint_newline (pf_mod | fil) *) // val npos = x0.len // val (pf_csi_gc, pf_csi | A_csi) = array_of_CSIlst (x0.lst, npos) val (pf_pos_gc, pf_pos | A_pos) = followpos (npos, root_regex1) // var nst_r = (0: int) var sts = states_nil () // // state 0 is special: it is the error state val _ = states_insert (sts, 0, intset_nil) // state 1 is special: it is the start state val _ = states_insert (sts, 1, root_fstpos) val () = nst_r := (2: int) // var stlst = statelst_nil () val () = stlst := statelst_cons (root_fstpos, stlst) // val dfa_transtbl = transition_all ( pf_csi, pf_pos | A_csi, A_pos, npos, nst_r, sts, stlst, translst_nil () ) // end of [val] // val () = array_ptr_free {intset?} (pf_pos_gc, pf_pos | A_pos) // val dfa_acctbl = accept_all (pf_csi | A_csi, npos, sts: states_t) val dfa_nfinal = acclst_length dfa_acctbl (* number of final states *) // val () = array_ptr_free {CSI?} (pf_csi_gc, pf_csi | A_csi) // val dfa_nstate = nst_r - 1 // in // // transition table // fprintf ( pf_mod | fil, "val __%s_transition_table: transition_table_t = __transition_table_make %i \"\\\n", @(id, dfa_nstate) ); fprint_translst (pf_mod | fil, dfa_transtbl); fprint_string (pf_mod | fil, "\"\n"); // // accepting states // fprintf ( pf_mod | fil, "val __%s_accept_table: accept_table_t = __accept_table_make %i %i \"\\\n", @(id, dfa_nstate, dfa_nfinal) ); fprint_acclst (pf_mod | fil, dfa_acctbl); fprint_string (pf_mod | fil, "\"\n\n"); // // function for lexical analysis // fprint_header (pf_mod | fil, id, arg); fprint_rules (pf_mod | fil, id, arg, rls); fprint_newline (pf_mod | fil); // end // end of [fprint_DFA] (* ****** ****** *) implement fprint_lexfns {m} (pf_mod | fil, env, lfs) = let fun loop ( fil: &FILE m, env: redef, lfs: lexfns ) : void = case+ lfs of | lexfns_cons (id, arg, rls, lfs) => begin fprint_DFA (pf_mod | fil, env, id, arg, rls); loop (fil, env, lfs) end // end of [lexfns_cons] | lexfns_nil () => () // end of [loop] in loop (fil, env, lfs) end // end of [fprint_lexfns] (* ****** ****** *) (* end of [lexgen.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/intset.dats0000664000175000017500000001004512223166165020623 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* * ATS - Unleashing the Power of Types! * * Copyright (C) 2002-2008 Hongwei Xi, Boston University * * All rights reserved * * ATS is free software; you can redistribute it and/or modify it under * the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the * Free Software Foundation; either version 2.1, or (at your option) any * later version. * * ATS is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * * You should have received a copy of the GNU General Public License * along with ATS; see the file COPYING. If not, write to the Free * Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301, USA. * *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "top.sats" (* ****** ****** *) datatype ints = | ints_nil | ints_cons of (int, ints) assume intset_t = ints // #define nil ints_nil; #define cons ints_cons; #define :: ints_cons // implement fprint_intset {m:file_mode} (pf_mod | fil, ns) = let fun aux1 (fil: &FILE m, ns: ints): void = begin case+ ns of n :: ns => aux2 (fil, n, ns) | nil () => () end // end of [aux1] and aux2 (fil: &FILE m, n: int, ns: ints) : void = begin case+ ns of | cons (n1, ns1) => begin fprint_int (pf_mod | fil, n); fprint_string (pf_mod | fil, ", "); aux2 (fil, n1, ns1) end | nil () => fprint_int (pf_mod | fil, n) end // end of [aux2] in aux1 (fil, ns) end // end of [fprint_intset] // implement print_intset (ns) = print_mac (fprint_intset, ns) implement prerr_intset (ns) = prerr_mac (fprint_intset, ns) // implement intset_nil = nil () implement intset_is_nil (ns) = begin case+ ns of nil () => true | _ :: _ => false end implement intset_singleton (n) = cons (n, nil ()) implement eq_intset_intset (ns1, ns2) = let fun loop (ns1: ints, ns2: ints): bool = case+ (ns1, ns2) of | (nil (), nil ()) => true | (n1 :: ns1, n2 :: ns2) => if n1 = n2 then loop (ns1, ns2) else false | (_, _) => false in loop (ns1, ns2) end // end of [eq_intset_intset] implement compare_intset_intset (ns1, ns2) = let fun loop (ns1: ints, ns2: ints): Sgn = case+ (ns1, ns2) of | (n1 :: ns1, n2 :: ns2) => begin if n1 < n2 then ~1 else (if n1 > n2 then 1 else compare (ns1, ns2)) end | (_ :: _, nil ()) => 1 | (nil (), _ :: _) => ~1 | (nil (), nil ()) => 0 in loop (ns1, ns2) end // end of [compare_intset_intset] implement union_intset_intset (ns1, ns2) = let fun aux_union (ns1: ints, ns2: ints) : ints = begin case+ (ns1, ns2) of | (n1 :: ns1', n2 :: ns2') => let val sgn = compare (n1, n2) in if sgn < 0 then n1 :: aux_union (ns1', ns2) else if sgn > 0 then n2 :: aux_union (ns1, ns2') else n1 :: aux_union (ns1', ns2') end // end of [cons _, cons _] | (nil (), _) => ns2 | (_, nil ()) => ns1 end // end of [aux_union] in aux_union (ns1, ns2) end // end of [union_intset_intset] implement foreach_intset {v} (pf | f, ns): void = let viewtypedef cloptr_t = (!v | int) - void fun loop (pf: !v | f: !cloptr_t, ns: intset_t) : void = begin case+ ns of | n :: ns => (f (pf | n); loop (pf | f, ns)) | nil () => () end // end of [loop] in loop (pf | f, ns) end // end of [foreach_intset] (* ****** ****** *) (* end of [intset.dats] *) ats-lang-anairiats-0.2.11/utils/atslex/atslex.dats0000664000175000017500000001205312223166165020616 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // July 2007 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "top.sats" (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) dynload "intset.dats" dynload "charset.dats" dynload "states.dats" dynload "position.dats" dynload "token.dats" dynload "parser.dats" dynload "lexgen.dats" (* ****** ****** *) local dataviewtype input = | {l:addr} INPUTsome of (FILE r @ l | ptr l) | INPUTnone of () val theInputRef = ref (INPUTnone ()) in // in of [local] implement the_atslex_input_fin () = let val (vbox pf | p) = ref_get_view_ptr (theInputRef) in case+ !p of | ~INPUTsome (pf_fil | p_fil) => let val () = $STDIO.fclose1_exn (pf_fil | p_fil) in !p := INPUTnone () end // end of [INPUTsome] | INPUTnone () => fold@ !p end // end of [the_atslex_input_fin] implement the_atslex_input_set (pf_fil | p_fil) = let val (vbox pf | p) = ref_get_view_ptr (theInputRef) in case+ !p of | INPUTsome (!pf1_fil_r | !p1_fil_r) => let val () = $STDIO.fclose1_exn (!pf1_fil_r | !p1_fil_r) in !pf1_fil_r := pf_fil; !p1_fil_r := p_fil; fold@ !p end // end of [INPUTsome] | ~INPUTnone () => (!p := INPUTsome (pf_fil | p_fil)) end // end of [the_atslex_input_set] implement atslex_getchar () = let val (vbox pf | p) = ref_get_view_ptr (theInputRef) in case+ !p of | INPUTsome (!pf_fil_r | p_fil) => let prval pf_fil = !pf_fil_r val c = $STDIO.fgetc1_err (file_mode_lte_r_r | !p_fil) prval () = !pf_fil_r := pf_fil in fold@ !p; c end // end of [INPUTsome] | INPUTnone () => (fold@ !p; ~1 (*EOF*)) end // end of [atslex_getchar] end // end of [local] (* ****** ****** *) fn is_reentrant (str: string): bool = case+ str of | "--reentrant" => true | _ => false // end of [is_reentrant] local val the_reentrant = ref (false) in // in of [local] implement atslex_get_reentrant () = !the_reentrant implement atslex_set_reentrant (b) = !the_reentrant := b end // end of [local] (* ****** ****** *) fn atslex_usage (cmd: string): void = begin printf ("usage: %s [--reentrant] --input --output \n", @(cmd)); end // end of [atslex_usage] (* ****** ****** *) implement main {n} (argc, argv) = let val () = loop (argv, 0) where { fun loop {i:nat | i <= n} .. ( argv: &(@[string][n]), i: int i ) : void = if i < argc then ( if is_reentrant (argv.[i]) then atslex_set_reentrant (true) else loop (argv, i+1) // end of [if] ) // end of [if] // end of [loop] } // end of [where] // end of [val] val () = let val (pf_stdin | p_stdin) = stdin_get () in the_atslex_input_set (pf_stdin | p_stdin) end // end of [val] val () = token_initialization () // // val () = prerr ("atslex: [lexer_parse] is started.\n") // val lexer = lexer_parse () val () = the_atslex_input_fin () // close the input channel // // val () = prerr ("atslex: [lexer_parse] is finished.\n") // val (pf_stdout | ptr_stdout) = stdout_get () val () = fprint_string ( file_mode_lte_w_w | !ptr_stdout, lexer.preamble ) // end of [fprint_string] // // val () = prerr ("atslex: preamble is finished.\n") // val () = fprint_lexfns ( file_mode_lte_w_w | !ptr_stdout, lexer.redef, lexer.lexfns ) // end of [fprint_lexfns] // // val () = prerr ("atslex: [fprint_lexfns] is finished.\n") // val () = fprint_string ( file_mode_lte_w_w | !ptr_stdout, lexer.postamble ) // end of [fprint_string] // // val () = prerr ("atslex: postamble is finished.\n") // val () = stdout_view_set (pf_stdout | (*none*)) in // empty end // end of [main] (* ****** ****** *) (* end of [atslex.dats] *) ats-lang-anairiats-0.2.11/config.mk.in0000664000175000017500000000116712223166157016211 0ustar hwxihwxiINSTALL := @INSTALL@ PACKAGE_TARNAME := @PACKAGE_TARNAME@ PACKAGE_VERSION := @PACKAGE_VERSION@ abs_top_srcdir := @abs_top_srcdir@ prefix := @prefix@ exec_prefix := @exec_prefix@ bindir := @bindir@ CC := @CC@ AR := ar LN_S := @LN_S@ INSTALL := @INSTALL@ MKDIR_P := @MKDIR_P@ CFLAGS := @CFLAGS@ CPPFLAGS := @CPPFLAGS@ LDFLAGS := @LDFLAGS@ ATSHOME := $(abs_top_srcdir) ATSLIBHOME := $(prefix)/lib/$(PACKAGE_TARNAME)-$(PACKAGE_VERSION) ATSHOMERELOC := ATS-$(PACKAGE_VERSION) ATSHOMEQ := "$(ATSHOME)" HAVE_LIBGMP := @HAVE_LIBGMP@ HAVE_LIBGLIB20 := @HAVE_LIBGLIB20@ HAVE_LIBGTK20 := @HAVE_LIBGTK20@ HAVE_LIBSDL10 := @HAVE_LIBSDL10@ ats-lang-anairiats-0.2.11/Makefile_macosx0000664000175000017500000002204212223166157017013 0ustar hwxihwxi######################################################################### ## ## ## Applied Type System ## ## ## ## Hongwei Xi ## ## ## ######################################################################### ## ## ATS/Anairiats - Unleashing the Potential of Types! ## ## Copyright (C) 2002-2010 Hongwei Xi. ## ## ATS is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free ## Software Foundation; either version 2.1, or (at your option) any later ## version. ## ## ATS is distributed in the hope that it will be useful, but WITHOUT ANY ## WARRANTY; without even the implied warranty of MERCHANTABILITY or ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ## for more details. ## ## You should have received a copy of the GNU General Public License ## along with ATS; see the file COPYING. If not, write to the Free ## Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ## 02110-1301, USA. ## ###### ## ## Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ## Author: Likai Liu (liulk AT cs DOT bu DOT edu) ## Author: Yuri D'Elia (wavexx AT thregr DOT org) ## # Disable parallelism and implicit rules MAKEFLAGS += -j1 .SUFFIXES: all:: Makefile ###### # integration with autoconf. SRC_CONFIG_FILES := config.mk.in config.h.in BUILT_CONFIG_FILES := $(SRC_CONFIG_FILES:%.in=%) Makefile: config.mk config.status: configure ./configure touch $@ $(BUILT_CONFIG_FILES): %: config.status $(filter-out %,$(SRC_CONFIG_FILES)) ./config.status touch $(BUILT_CONFIG_FILES) config.h.in: configure.ac autoheader $< touch $@ configure: configure.ac $(SRC_CONFIG_FILES) aclocal automake --add-missing --foreign || true autoconf touch $(BUILT_CONFIG_FILES) -include config.mk ###### DESTDIR := export ATSHOME export ATSHOMERELOC export ATSHOMEQ ###### ATSHOMEBIN = $(ATSHOMEQ)/bin ###### # # HX-2011-06-01: # This part is by Georg Bauhaus (bauhaus AT arcor DOT de): # It addresses the issue that the [-D] option is not available # for $(INSTALL) on MacOSX. # .PHONY: install_dirs install_dirs:: config.h # # make all subdirectories needed by install. # cd $(abs_top_srcdir) [ -d $(DESTDIR)/$(bindir) ] || $(MKDIR_P) $(DESTDIR)/$(bindir) $(MKDIR_P) $(DESTDIR)$(ATSNEWHOME)/bin find ccomp contrib doc libats libc prelude -type d \ -exec $(MKDIR_P) $(DESTDIR)$(ATSNEWHOME)/\{} \; \ -print install_files:: install_dirs # # recursively install all files in the list except .svn control files. # for d in ccomp/runtime contrib doc libats libc prelude; do \ cd $(abs_top_srcdir) && \ $(INSTALL) -d $(DESTDIR)$(ATSNEWHOME)/"$$d" && \ find "$$d" -name .svn -prune -o -type f \ -exec $(INSTALL) -m 644 \{} $(DESTDIR)$(ATSNEWHOME)/\{} \; \ -print && \ find "$$d" -name .svn -prune -o -type l \ -exec cp -d \{} $(DESTDIR)$(ATSNEWHOME)/\{} \; \ -print; \ done # # install specific files in the list as regular files. # for f in \ COPYING INSTALL *.txt ccomp/lib/*.a ccomp/lib64/*.a config.h; \ do \ [ -f "$$f" ] || continue; \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 644 "$$f" $(DESTDIR)$(ATSNEWHOME)/"$$f" && \ echo "$$f"; \ done # # install specific files in the list as executables. # for f in bin/*; do \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 755 "$$f" $(DESTDIR)$(ATSNEWHOME)/"$$f" && \ echo "$$f"; \ done # # install multiple copies of wrapper script, for each binary. # for f in bin/*; do \ b=`basename "$$f"`; \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 755 ats_env.sh $(DESTDIR)$(bindir)/"$$b" && \ echo install ats_env.sh to $(bindir)/"$$b"; \ done install:: install_files ###### test:: sh test.sh ###### all:: all-anairiats # # HX: [all1] is the entry point for bootstrapping with ATS/Geizella # all-geizella:: atsopt0-geizella all-geizella::all1 # # HX: [all1] is the entry point for bootstrapping with ATS/Anairiats # all-anairiats:: atsopt0-anairiats all-anairiats:: all1 ###### all1:: bootstrapping all1:: atsopt1 all1:: bin/atscc all1:: bin/atslib all1:: libfiles libfiles_mt all1:: bin/atspack all1:: bin/atslex all1:: ccomp/runtime/GCATS/gc.o all1:: ccomp/runtime/GCATS/gc_mt.o all1:: atsopt1_gc all1:: contrib all1:: ; @echo "ATS/Anairiats has been built up successfully!" all1:: ; @echo "The value of ATSHOME for this build is \"$(ATSHOME)\"." all1:: ; @echo "The value of ATSHOMERELOC for this build is \"$(ATSHOMERELOC)\"." ###### w/o GC ###### atsopt0:: atsopt0-anairiats # # bootstrapping via ocaml # atsopt0-geizella: ; $(MAKE) -C bootstrap0 -f ./Makefile atsopt # # bootstrapping via gcc # atsopt0-anairiats: ; $(MAKE) -C bootstrap0 -f ./Makefile atsopt ###### bootstrapping ###### bootstrapping:: ; $(MAKE) -C src -f ./Makefile_srcbootstrap all ###### w/o GC ###### atsopt1:: ; $(MAKE) -C bootstrap1 -f ../Makefile_bootstrap atsopt atsopt1:: ; $(CPF) bootstrap1/atsopt $(ATSHOMEBIN)/atsopt ###### with GC ###### atsopt1_gc:: ; $(MAKE) -C bootstrap1 -f ../Makefile_bootstrap atsopt_gc atsopt1_gc:: ; $(CPF) bootstrap1/atsopt_gc $(ATSHOMEBIN)/atsopt ###### contrib libraries ###### contrib:: ifeq (1,1) $(MAKE) -C contrib/parcomb all endif ifeq ($(HAVE_LIBGLIB20),1) $(MAKE) -C contrib/glib all endif ifeq ($(HAVE_LIBGTK20),1) $(MAKE) -C contrib/cairo all $(MAKE) -C contrib/pango all $(MAKE) -C contrib/GTK all endif ifeq ($(HAVE_LIBSDL10),1) $(MAKE) -C contrib/SDL all endif ###### some toplevel commands ###### bin/atscc bin/atslib: $(MAKE) -C utils/scripts atscc $(CPF) utils/scripts/atscc $(ATSHOMEBIN) $(MAKE) -C utils/scripts atslib $(CPF) utils/scripts/atslib $(ATSHOMEBIN) $(MAKE) -C utils/scripts clean bin/atspack: $(MAKE) -C utils/scripts atspack $(CPF) utils/scripts/atspack $(ATSHOMEBIN) ###### library ###### ATS_PROOFCHECK= # ATS_PROOFCHECK=-D_ATS_PROOFCHECK # it should be turned on from time to time # # [CC -E] for preprocessing # ATSLIB=$(ATSHOMEBIN)/atslib .libfiles_local: .libfiles ; $(CC) -E -P -x c -o $@ $< libfiles: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats_smlbas lib32files: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats_smlbas lib64files: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats_smlbas .libfiles_mt_local: .libfiles_mt ; $(CC) -E -P -x c -o $@ $< libfiles_mt: .libfiles_mt_local $(ATSLIB) $(ATS_PROOFCHECK) -O2 -D_ATS_MULTITHREAD --libats_mt ###### a lexer for ATS ###### bin/atslex: $(MAKE) -C utils/atslex atslex $(CPF) utils/atslex/atslex $(ATSHOMEBIN) $(MAKE) -C utils/atslex atslex clean ###### GC runtime ###### ccomp/runtime/GCATS/gc.o: $(MAKE) -C ccomp/runtime/GCATS gc.o $(MAKE) -C ccomp/runtime/GCATS clean ccomp/runtime/GCATS/gc_mt.o: $(MAKE) -C ccomp/runtime/GCATS gc_mt.o $(MAKE) -C ccomp/runtime/GCATS clean ###### package:: bin/atspack --source precompiled:: bin/atspack --precompiled rm -fr usr/share/atshome mv ats-lang-anairiats-* usr/share/atshome tar -zvcf ats-lang-anairiats-precompiled.tar.gz \ --exclude=usr/.svn --exclude=usr/bin/.svn --exclude=usr/share/.svn usr/ ###### srclines:: $(MAKE) -C src lines liblines:: wc -l \ prelude/*/*.?ats \ prelude/*/*/*.?ats \ libc/*/*.?ats \ libc/*/*/*.?ats \ libats/*/*.?ats \ libats/*/*/*.?ats \ ###### CPF=cp -f RMF=rm -f ###### clean:: $(RMF) bootstrap0/*.o $(RMF) bootstrap1/*.c $(RMF) bootstrap1/*.h $(RMF) bootstrap1/*.cats $(RMF) bootstrap1/*.o cleanall:: clean $(RMF) $(BUILT_CONFIG_FILES) $(RMF) .libfiles_local $(RMF) .libfiles_mt_local $(RMF) bootstrap0/atsopt $(RMF) bootstrap1/atsopt $(RMF) src/ats_grammar_yats.c src/ats_grammar_yats.h $(RMF) bin/atsopt bin/atscc bin/atslib bin/atslex bin/atspack $(RMF) ccomp/lib/libats.a $(RMF) ccomp/lib/libats_mt.a $(RMF) ccomp/lib/libats_lex.a $(RMF) ccomp/lib/libats_smlbas.a $(RMF) ccomp/lib/output/* $(RMF) ccomp/lib64/libats.a $(RMF) ccomp/lib64/libats_mt.a $(RMF) ccomp/lib64/libats_lex.a $(RMF) ccomp/lib64/libats_smlbas.a $(RMF) ccomp/lib64/output/* $(RMF) contrib/glib/atsctrb_glib.o $(RMF) contrib/cairo/atsctrb_cairo.o $(RMF) contrib/pango/atsctrb_pango.o $(RMF) contrib/X11/atsctrb_X11.o $(RMF) contrib/GTK/atsctrb_GTK.o $(RMF) contrib/GL/atsctrb_GL.o $(RMF) contrib/SDL/atsctrb_SDL.o cleanall:: ; $(MAKE) -C utils/atslex -f ./Makefile cleanall cleanall:: ; $(MAKE) -C utils/scripts -f ./Makefile cleanall cleanall:: ; $(MAKE) -C ccomp/runtime/GCATS -f ./Makefile cleanall distclean:: cleanall distclean:: ; find . -name .svn -prune -o -name \*~ -exec rm \{} \; ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/0000700000175000017500000000000012223166165015424 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/SDL/0000700000175000017500000000000012223166165016046 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/SDL/CATS/0000700000175000017500000000000012223166165016600 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL.cats0000664000175000017500000000531512223166165020116 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_CATS #define ATSCTRB_SDL_CATS /* ****** ****** */ #include "SDL.h" /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_SDL_ref_null() { return ((ats_ptr_type)0) ; } ATSinline() ats_void_type atsctrb_SDL_ref_free_null (ats_ptr_type p) { return ; } /* ****** ****** */ ATSinline() ats_bool_type atsctrb_SDL_ref_is_null (ats_ref_type p) { return (p == (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_SDL_is_null] ATSinline() ats_bool_type atsctrb_SDL_ref_isnot_null (ats_ref_type p) { return (p != (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_SDL_ref_isnot_null] /* ****** ****** */ #include "contrib/SDL/CATS/SDL_stdinc.cats" /* ****** ****** */ #include "contrib/SDL/CATS/SDL_events.cats" #include "contrib/SDL/CATS/SDL_timer.cats" #include "contrib/SDL/CATS/SDL_thread.cats" #include "contrib/SDL/CATS/SDL_video.cats" /* ****** ****** */ #define atsctrb_SDL_Init SDL_Init #define atsctrb_SDL_Quit SDL_Quit /* ****** ****** */ #define atsctrb_SDL_InitSubSystem InitSubSystem #define atsctrb_SDL_QuitSubSystem QuitSubSystem #define atsctrb_SDL_WasInit SDL_WasInit /* ****** ****** */ #endif // end of [ATSCTRB_SDL_CATS] /* end of [SDL.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_keysym.cats0000664000175000017500000000355212223166165021520 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // /* ****** ****** */ #ifndef ATSCTRB_SDL_KEYSYM_CATS #define ATSCTRB_SDL_KEYSYM_CATS /* ****** ****** */ static inline ats_bool_type atsctrb_eq_SDLKey_SDLKey (SDLKey x1, SDLKey x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_SDL_EventType_SDL_EventType] /* ****** ****** */ #endif // end of [ATSCTRB_SDL_KEYSYM_CATS] /* end of [SDL_keysym.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_keyboard.cats0000664000175000017500000000420312223166165021771 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_KEYBOARD_CATS #define ATSCTRB_SDL_KEYBOARD_CATS /* ****** ****** */ #include "contrib/SDL/CATS/SDL_keysym.cats" /* ****** ****** */ #define atsctrb_SDL_GetKeyState SDL_GetKeyState static inline ats_ref_type // SDL_KeyStateArr atsctrb_SDL_GetKeyState_null () { return SDL_GetKeyState ((int*)0) ; } // end of [atsctrb_SDL_GetKeyState_null] static inline ats_int_type // SDL_KeyStateArr atsctrb_SDL_KeyStateArr_get ( ats_ref_type keyarr, SDLKey key ) { return ((Uint8*)keyarr)[key] ; } // end of [atsctrb_SDL_KeyStateArr_get] /* ****** ****** */ #endif // end of [ATSCTRB_SDL_KEYBOARD_CATS] /* end of [SDL_keyboard.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_mixer.cats0000664000175000017500000000514112223166165021317 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: March, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_MIXER_CATS #define ATSCTRB_SDL_MIXER_CATS /* ****** ****** */ #include "SDL/SDL.h" #include "SDL/SDL_mixer.h" /* ****** ****** */ #define atsctrb_Mix_OpenAudio Mix_OpenAudio #define atsctrb_Mix_AllocateChannels Mix_AllocateChannels #define atsctrb_Mix_QuerySpec Mix_QuerySpec #define atsctrb_Mix_LoadWAV Mix_LoadWAV #define atsctrb_Mix_LoadMUS Mix_LoadMUS #define atsctrb_Mix_FreeChunk Mix_FreeChunk #define atsctrb_Mix_FreeMusic Mix_FreeMusic #define atsctrb_Mix_PlayChannel Mix_PlayChannel #define atsctrb_Mix_PlayChannelTimed Mix_PlayChannelTimed #define atsctrb_Mix_PlayMusic Mix_PlayMusic #define atsctrb_Mix_HaltChannel Mix_HaltChannel #define atsctrb_Mix_HaltGroup Mix_HaltGroup #define atsctrb_Mix_HaltMusic Mix_HaltMusic #define atsctrb_Mix_PauseMusic Mix_PauseMusic #define atsctrb_Mix_ResumeMusic Mix_ResumeMusic #define atsctrb_Mix_RewindMusic Mix_RewindMusic #define atsctrb_Mix_PausedMusic Mix_PausedMusic #define atsctrb_Mix_Playing Mix_Playing #define atsctrb_Mix_PlayingMusic Mix_PlayingMusic /* ****** ****** */ #endif // end of [ATSCTRB_SDL_MIXER_CATS] /* end of [SDL_mixer.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_video.cats0000664000175000017500000001031612223166165021301 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_VIDEO_CATS #define ATSCTRB_SDL_VIDEO_CATS /* ****** ****** */ static inline ats_void_type atsctrb_SDL_Rect_init ( ats_ref_type rect , Sint16 x, Sint16 y, Uint16 w, Uint16 h ) { ((SDL_Rect*)rect)->x = x ; ((SDL_Rect*)rect)->y = y ; ((SDL_Rect*)rect)->w = w ; ((SDL_Rect*)rect)->h = h ; return ; } // end of [atsctrb_SDL_Rect_init] /* ****** ****** */ static inline ats_void_type atsctrb_SDL_Color_init ( ats_ref_type color, Uint8 r, Uint8 g, Uint8 b ) { ((SDL_Color*)color)->r = r ; ((SDL_Color*)color)->g = g ; ((SDL_Color*)color)->b = b ; return ; } // end of [atsctrb_SDL_Color_init] /* ****** ****** */ #define atsctrb_SDL_Surface_flags(sf) (((SDL_Surface*)(sf))->flags) #define atsctrb_SDL_Surface_format(sf) (((SDL_Surface*)(sf))->format) #define atsctrb_SDL_Surface_w(sf) (((SDL_Surface*)(sf))->w) #define atsctrb_SDL_Surface_h(sf) (((SDL_Surface*)(sf))->h) #define atsctrb_SDL_Surface_pitch(sf) (((SDL_Surface*)(sf))->pitch) #define atsctrb_SDL_Surface_clip_rect(sf) (((SDL_Surface*)(sf))->clip_rect) #define atsctrb_SDL_Surface_refcount(sf) (((SDL_Surface*)(sf))->refcount) /* ****** ****** */ #define atsctrb_SDL_SetVideoMode SDL_SetVideoMode static inline ats_ref_type atsctrb_SDL_ResetVideoMode ( ats_ref_type screen // not actually used , ats_int_type width , ats_int_type height , ats_int_type bpp , Uint32 flags ) { return SDL_SetVideoMode (width, height, bpp, flags) ; } // end of [atsctrb_SDL_ResetVideoMode] /* ****** ****** */ #define atsctrb_SDL_UpdateRect SDL_UpdateRect #define atsctrb_SDL_UpdateRects SDL_UpdateRects #define atsctrb_SDL_Flip SDL_Flip /* ****** ****** */ #define atsctrb_SDL_MapRGB SDL_MapRGB #define atsctrb_SDL_MapRGBA SDL_MapRGBA /* ****** ****** */ #define atsctrb_SDL_CreateRGBSurface SDL_CreateRGBSurface #define atsctrb_SDL_CreateRGBSurfaceFrom SDL_CreateRGBSurfaceFrom #define atsctrb_SDL_FreeSurface SDL_FreeSurface /* ****** ****** */ #define atsctrb_SDL_LoadBMP SDL_LoadBMP /* ****** ****** */ #define atsctrb_SDL_SetColorKey SDL_SetColorKey #define atsctrb_SDL_SetAlpha SDL_SetAlpha /* ****** ****** */ #define atsctrb_SDL_GetClipRect SDL_GetClipRect #define atsctrb_SDL_SetClipRect SDL_SetClipRect /* ****** ****** */ #define atsctrb_SDL_UpperBlit SDL_UpperBlit /* ****** ****** */ #define atsctrb_SDL_FillRect SDL_FillRect /* ****** ****** */ #define atsctrb_SDL_DisplayFormat SDL_DisplayFormat #define atsctrb_SDL_DisplayFormatAlpha SDL_DisplayFormatAlpha /* ****** ****** */ #define atsctrb_SDL_WM_GetCaption SDL_WM_GetCaption #define atsctrb_SDL_WM_SetCaption SDL_WM_SetCaption /* ****** ****** */ #define atsctrb_SDL_GL_SwapBuffers SDL_GL_SwapBuffers /* ****** ****** */ #endif // end of [ATSCTRB_SDL_VIDEO_CATS] /* end of [SDL_video.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_image.cats0000664000175000017500000000341612223166165021260 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_IMAGE_CATS #define ATSCTRB_SDL_IMAGE_CATS /* ****** ****** */ #include "SDL/SDL.h" #include "SDL/SDL_image.h" /* ****** ****** */ #define atsctrb_IMG_Load IMG_Load /* ****** ****** */ #endif // end of [ATSCTRB_SDL_IMAGE_CATS] /* end of [SDL_image.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_timer.cats0000664000175000017500000000361512223166165021317 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_TIMER_CATS #define ATSCTRB_SDL_TIMER_CATS /* ****** ****** */ #define atsctrb_SDL_GetTicks SDL_GetTicks #define atsctrb_SDL_Delay SDL_Delay /* ****** ****** */ #define atsctrb_SDL_SetTimer SDL_SetTimer #define atsctrb_SDL_CancelTimer () \ SDL_SetTimer ((Uint32)0, (SDL_TimerCallback)NULL) /* ****** ****** */ #endif // end of [ATSCTRB_SDL_TIMER_CATS] /* end of [SDL_timer.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_stdinc.cats0000664000175000017500000000600712223166165021461 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_STDINC_CATS #define ATSCTRB_SDL_STDINC_CATS /* ****** ****** */ static inline Uint8 atsctrb_land_Uint8_Uint8 (Uint8 x1, Uint8 x2) { return (x1 & x2) ; } // end of [atsctrb_land_Uint8_Uint8] static inline Uint8 atsctrb_lor_Uint8_Uint8 (Uint8 x1, Uint8 x2) { return (x1 | x2) ; } // end of [atsctrb_lor_Uint8_Uint8] /* ****** ****** */ static inline Uint16 atsctrb_add_Uint16_Uint16 (Uint16 x1, Uint16 x2) { return (x1 + x2) ; } // end of [atsctrb_add_Uint16_Uint16] static inline Uint16 atsctrb_sub_Uint16_Uint16 (Uint16 x1, Uint16 x2) { return (x1 - x2) ; } // end of [atsctrb_sub_Uint16_Uint16] static inline Uint16 atsctrb_land_Uint16_Uint16 (Uint16 x1, Uint16 x2) { return (x1 & x2) ; } // end of [atsctrb_land_Uint16_Uint16] static inline Uint16 atsctrb_lor_Uint16_Uint16 (Uint16 x1, Uint16 x2) { return (x1 | x2) ; } // end of [atsctrb_lor_Uint16_Uint16] /* ****** ****** */ static inline Uint32 atsctrb_add_Uint32_Uint32 (Uint32 x1, Uint32 x2) { return (x1 + x2) ; } // end of [atsctrb_add_Uint32_Uint32] static inline Uint32 atsctrb_sub_Uint32_Uint32 (Uint32 x1, Uint32 x2) { return (x1 - x2) ; } // end of [atsctrb_sub_Uint32_Uint32] static inline Uint32 atsctrb_land_Uint32_Uint32 (Uint32 x1, Uint32 x2) { return (x1 & x2) ; } // end of [atsctrb_land_Uint32_Uint32] static inline Uint32 atsctrb_lor_Uint32_Uint32 (Uint32 x1, Uint32 x2) { return (x1 | x2) ; } // end of [atsctrb_lor_Uint32_Uint32] /* ****** ****** */ #endif // end of [ATSCTRB_SDL_STDINC_CATS] /* end of [SDL_stdinc.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_events.cats0000664000175000017500000000516512223166165021505 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_EVENTS_CATS #define ATSCTRB_SDL_EVENTS_CATS /* ****** ****** */ #include "contrib/SDL/CATS/SDL_active.cats" #include "contrib/SDL/CATS/SDL_keyboard.cats" /* ****** ****** */ static inline ats_bool_type atsctrb_eq_SDL_EventType_SDL_EventType (SDL_EventType x1, SDL_EventType x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_SDL_EventType_SDL_EventType] /* ****** ****** */ #define atsctrb_SDL_Event_type(event) (((SDL_Event*)(event))->type) /* ****** ****** */ #define atsctrb_SDL_KeyboardEvent_type(_ref) \ ats_field_getval(SDL_KeyboardEvent, _ref, type) #define atsctrb_SDL_KeyboardEvent_which(_ref) \ ats_field_getval(SDL_KeyboardEvent, _ref, which) #define atsctrb_SDL_KeyboardEvent_state(_ref) \ ats_field_getval(SDL_KeyboardEvent, _ref, state) #define atsctrb_SDL_KeyboardEvent_keysym(_ref) \ ats_field_getval(SDL_KeyboardEvent, _ref, keysym) /* ****** ****** */ #define atsctrb_SDL_PollEvent SDL_PollEvent #define atsctrb_SDL_PollEvent_null () SDL_PollEvent((SDL_Event*)0) ; /* ****** ****** */ #endif // end of [ATSCTRB_SDL_EVENTS_CATS] /* end of [SDL_events.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_ttf.cats0000664000175000017500000000574712223166165021004 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_TTF_CATS #define ATSCTRB_SDL_TTF_CATS /* ****** ****** */ #include "SDL/SDL.h" #include "SDL/SDL_ttf.h" /* ****** ****** */ #define atsctrb_TTF_Init TTF_Init /* ****** ****** */ #define atsctrb_TTF_OpenFont TTF_OpenFont /* ****** ****** */ #define atsctrb_TTF_GetFontStyle TTF_GetFontStyle #define atsctrb_TTF_SetFontStyle TTF_SetFontStyle #define atsctrb_TTF_GetFontHeight TTF_GetFontHeight #define atsctrb_TTF_FontAscent TTF_FontAscent #define atsctrb_TTF_FontDescent TTF_FontDescent #define atsctrb_TTF_FontLineSkip TTF_FontLineSkip #define atsctrb_TTF_FontFaces TTF_FontFaces /* ****** ****** */ #define atsctrb_TTF_FontFaceIsFixedWidth TTF_FontFaceIsFixedWidth #define atsctrb_TTF_FontFaceFamilyName #define atsctrb_FontFaceStyleName /* ****** ****** */ #define atsctrb_TTF_SizeText TTF_SizeText #define atsctrb_TTF_SizeUTF8 TTF_SizeUTF8 /* ****** ****** */ #define atsctrb_TTF_GlyphMetrics TTF_GlyphMetrics /* ****** ****** */ #define atsctrb_TTF_RenderText_Solid TTF_RenderText_Solid #define atsctrb_TTF_RenderUTF8_Solid TTF_RenderUTF8_Solid #define atsctrb_TTF_RenderText_Shaded TTF_RenderText_Shaded #define atsctrb_TTF_RenderUTF8_Shaded TTF_RenderUTF8_Shaded #define atsctrb_TTF_RenderGlyph_Solid TTF_RenderGlyph_Solid /* ****** ****** */ #define atsctrb_TTF_CloseFont TTF_CloseFont /* ****** ****** */ #define atsctrb_TTF_Quit TTF_Quit #define atsctrb_TTF_WasInit TTF_WasInit /* ****** ****** */ #endif // end of [ATSCTRB_SDL_TTF_CATS] /* end of [SDL_ttf.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_thread.cats0000664000175000017500000000347012223166165021445 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_THREAD_CATS #define ATSCTRB_SDL_THREAD_CATS /* ****** ****** */ #define atsctrb_SDL_CreateThread SDL_CreateThread #define atsctrb_SDL_KillThread SDL_KillThread #define atsctrb_SDL_WaitThread SDL_WaitThread /* ****** ****** */ #endif // end of [ATSCTRB_SDL_THREAD_CATS] /* end of [SDL_thread.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/CATS/SDL_active.cats0000664000175000017500000000333212223166165021446 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_SDL_ACTIVE_CATS #define ATSCTRB_SDL_ACTIVE_CATS /* ****** ****** */ #define atsctrb_SDL_GetAppState SDL_GetAppState /* ****** ****** */ #endif // end of [ATSCTRB_SDL_ACTIVE_CATS] /* end of [SDL_active.cats] */ ats-lang-anairiats-0.2.11/contrib/SDL/SATS/0000700000175000017500000000000012223166165016620 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_keyboard.sats0000664000175000017500000000576712223166165022051 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) #include "contrib/SDL/SATS/SDL_keysym.sats" (* ****** ****** *) typedef SDL_keysym = $extype_struct "SDL_keysym" of { scancode= Uint8, sym= SDLKey, mod= SDLMod, unicode= Uint16 } // end of [SDL_keysym] (* ****** ****** *) #define SDL_ALL_HOTKEYS 0xFFFFFFFF (* ****** ****** *) fun SDL_EnableUNICODE (enable: int): int = "mac#atsctrb_SDL_EnableUNICODE" (* ****** ****** *) #define SDL_DEFAULT_REPEAT_DELAY 500 #define SDL_DEFAULT_REPEAT_INTERVAL 30 fun SDL_EnableKeyRepeat (delay: int, interval: int): int = "mac#atsctrb_SDL_EnableKeyRepeat" // end of [SDL_EnableKeyRepeat] fun SDL_GetKeyRepeat ( delay: &int? >> int, interval: &int? >> int ) : void = "mac#atsctrb_SDL_GetKeyRepeat" // end of [fun] (* ****** ****** *) abstype SDL_KeyStateArr (int) typedef SDL_KeyStateArr = [n:nat] SDL_KeyStateArr n fun SDL_GetKeyState (numkeys: &int? >> int n): #[n:nat] SDL_KeyStateArr (n) = "mac#atsctrb_SDL_GetKeyState" fun SDL_GetKeyState_null (): [n:nat] SDL_KeyStateArr (n) = "atsctrb_SDL_GetKeyState_null" // this is a function! fun SDL_KeyStateArr_get {n:nat} (keyarr: SDL_KeyStateArr n, key: SDLKey):<> int = "atsctrb_SDL_KeyStateArr_get" // this is a function! overload [] with SDL_KeyStateArr_get (* ****** ****** *) fun SDL_GetModState (): SDLMod = "mac#atsctrb_SDL_GetModState" fun SDL_SetModState (state: SDLMod): void = "mac#atsctrb_SDL_SetModState" (* ****** ****** *) fun SDL_GetKeyName (key: SDLKey): string = "mac#atsctrb_SDL_GetKeyName" (* ****** ****** *) (* end of [SDL_keyboard.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_timer.sats0000664000175000017500000000440012223166165021350 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) (* ** This is the OS scheduler timeslice, in milliseconds *) macdef SDL_TIMESLICE = 10 (* ** This is the maximum resolution of the SDL timer on all platforms *) macdef TIMER_RESOLUTION = 10 (* Experimentally determined *) fun SDL_GetTicks (): Uint32 = "mac#atsctrb_SDL_GetTicks" (* ****** ****** *) fun SDL_Delay (ms: Uint32): void = "mac#atsctrb_SDL_Delay" (* ****** ****** *) typedef SDL_TimerCallback = (Uint32(*interval*)) - Uint32 fun SDL_SetTimer ( interval: Uint32, callback: SDL_TimerCallback ) : int = "mac#atsctrb_SDL_SetTimer" // end of [fun] // // SDL_CancelTimer () = SDL_SetTimer (0, NULL) // fun SDL_CancelTimer (): int // cancel the current running timer = "mac#atsctrb_SDL_CancelTimer" (* ****** ****** *) (* end of [SDL_timer.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_events.sats0000664000175000017500000004530212223166165021542 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) #include "contrib/SDL/SATS/SDL_active.sats" #include "contrib/SDL/SATS/SDL_keyboard.sats" (* ****** ****** *) abst@ype SDL_EventType = $extype"SDL_EventType" typedef SDL_Event = $extype_struct "SDL_Event" of { type= SDL_EventType , _rest= undefined_t // this field cannot be accessed } // end of [SDL_Event] propdef SDL_Event_castdn_t (a:t@ype) = {l:addr} (SDL_Event @ l) - (a @ l, a @ l - SDL_Event @ l) // end of [SDL_Event_castdn_t] (* ****** ****** *) castfn int_of_SDL_EventType (x: SDL_EventType):<> int overload int_of with int_of_SDL_EventType // fun eq_SDL_EventType_SDL_EventType ( x1: SDL_EventType, x2: SDL_EventType ) :<> bool = "atsctrb_eq_SDL_EventType_SDL_EventType" overload = with eq_SDL_EventType_SDL_EventType // macdef SDL_ACTIVEEVENT = $extval (SDL_EventType, "SDL_ACTIVEEVENT") macdef SDL_KEYDOWN = $extval (SDL_EventType, "SDL_KEYDOWN") macdef SDL_KEYUP = $extval (SDL_EventType, "SDL_KEYUP") macdef SDL_MOUSEMOTION = $extval (SDL_EventType, "SDL_MOUSEMOTION") macdef SDL_MOUSEBUTTONDOWN = $extval (SDL_EventType, "SDL_MOUSEBUTTONDOWN") macdef SDL_MOUSEBUTTONUP = $extval (SDL_EventType, "SDL_MOUSEBUTTONUP") macdef SDL_JOYAXISMOTION = $extval (SDL_EventType, "SDL_JOYAXISMOTION") macdef SDL_JOYBALLMOTION = $extval (SDL_EventType, "SDL_JOYBALLMOTION") macdef SDL_JOYHATMOTION = $extval (SDL_EventType, "SDL_JOYHATMOTION") macdef SDL_JOYBUTTONDOWN = $extval (SDL_EventType, "SDL_JOYBUTTONDOWN") macdef SDL_JOYBUTTONUP = $extval (SDL_EventType, "SDL_JOYBUTTONUP") macdef SDL_QUIT = $extval (SDL_EventType, "SDL_QUIT") macdef SDL_SYSWMEVENT = $extval (SDL_EventType, "SDL_SYSWMEVENT") macdef SDL_VIDEORESIZE = $extval (SDL_EventType, "SDL_VIDEORESIZE") macdef SDL_VIDEOEXPOSE = $extval (SDL_EventType, "SDL_VIDEOEXPOSE") fun SDL_Event_type (x: &SDL_Event):<> SDL_EventType = "mac#atsctrb_SDL_Event_type" // end of [SDL_Event_type] (* ****** ****** *) typedef SDL_ActiveEvent = $extype_struct "SDL_ActiveEvent" of { type= Uint8, gain= Uint8, state= Uint8 } // end of [SDL_ActiveEvent] praxi SDL_Event_active_castdn : SDL_Event_castdn_t (SDL_ActiveEvent) (* ****** ****** *) typedef SDL_KeyboardEvent = $extype_struct "SDL_KeyboardEvent" of { type= Uint8, which= Uint8, state= Uint8, keysym= SDL_keysym } // end of [SDL_KeyboardEvent] praxi SDL_Event_key_castdn : SDL_Event_castdn_t (SDL_KeyboardEvent) (* ****** ****** *) typedef SDL_MouseMotionEvent = $extype_struct "SDL_MouseMotionEvent" of { type= Uint8 , which= Uint8 , state= Uint8 , x= Uint16 , y= Uint16 , xrel= Sint16 , yrel= Sint16 } // end of [SDL_MouseMotionEvent] praxi SDL_Event_motion_castdn : SDL_Event_castdn_t (SDL_MouseMotionEvent) (* ****** ****** *) typedef SDL_MouseButtonEvent = $extype_struct "SDL_MouseButtonEvent" of { type= Uint8 , which= Uint8 , button= Uint8 , state= Uint8 , x= Uint16 , y= Uint16 } // end of [SDL_MouseButtonEvent] praxi SDL_Event_button_castdn : SDL_Event_castdn_t (SDL_MouseButtonEvent) (* ****** ****** *) typedef SDL_JoyAxisEvent = $extype_struct "SDL_JoyAxisEvent" of { type= Uint8 , which= Uint8 , axis= Uint8 , value= Sint16 } // end of [SDL_JoyAxisEvent] praxi SDL_Event_jaxis_castdn : SDL_Event_castdn_t (SDL_JoyAxisEvent) (* ****** ****** *) typedef SDL_JoyBallEvent = $extype_struct "SDL_JoyBallEvent" of { type= Uint8 , which= Uint8 , ball= Uint8 , xrel= Sint16 , yrel= Sint16 } // end of [SDL_JoyBallEvent] praxi SDL_Event_jball_castdn : SDL_Event_castdn_t (SDL_JoyBallEvent) (* ****** ****** *) typedef SDL_JoyButtonEvent = $extype_struct "SDL_JoyButtonEvent" of { type= Uint8 , which= Uint8 , button= Uint8 , state= Uint8 } // end of [SDL_JoyButtonEvent] praxi SDL_Event_jbutton_castdn : SDL_Event_castdn_t (SDL_JoyButtonEvent) (* ****** ****** *) typedef SDL_ResizeEvent = $extype_struct "SDL_ResizeEvent" of { type= Uint8, w= int, h= int } // end of [SDL_ResizeEvent] praxi SDL_Event_resize_castdn : SDL_Event_castdn_t (SDL_ResizeEvent) (* ****** ****** *) typedef SDL_ExposeEvent = $extype_struct "SDL_ExposeEvent" of { type= Uint8 } // end of [SDL_ExposeEvent] praxi SDL_Event_expose_castdn : SDL_Event_castdn_t (SDL_ExposeEvent) (* ****** ****** *) typedef SDL_QuitEvent = $extype_struct "SDL_QuitEvent" of { type= Uint8 } // end of [SDL_QuitEvent] (* ****** ****** *) fun SDL_PollEvent ( event: &SDL_Event? >> opt (SDL_Event, i > 0) ) : #[i:two] int i = "mac#atsctrb_SDL_PollEvent" fun SDL_PollEvent_null (): [i:two] int i = "mac#atsctrb_SDL_PollEvent_null" // end of [SDL_PollEvent_null] (* ****** ****** *) //// /* SDL - Simple DirectMedia Layer Copyright (C) 1997-2009 Sam Lantinga This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Sam Lantinga slouken@libsdl.org */ /** * @file SDL_events.h * Include file for SDL event handling */ #ifndef _SDL_events_h #define _SDL_events_h #include "SDL_stdinc.h" #include "SDL_error.h" #include "SDL_active.h" #include "SDL_keyboard.h" #include "SDL_mouse.h" #include "SDL_joystick.h" #include "SDL_quit.h" #include "begin_code.h" /* Set up for C function definitions, even when using C++ */ #ifdef __cplusplus extern "C" { #endif /** @name General keyboard/mouse state definitions */ /*@{*/ #define SDL_RELEASED 0 #define SDL_PRESSED 1 /*@}*/ /** Event enumerations */ typedef enum { SDL_NOEVENT = 0, /**< Unused (do not remove) */ SDL_ACTIVEEVENT, /**< Application loses/gains visibility */ SDL_KEYDOWN, /**< Keys pressed */ SDL_KEYUP, /**< Keys released */ SDL_MOUSEMOTION, /**< Mouse moved */ SDL_MOUSEBUTTONDOWN, /**< Mouse button pressed */ SDL_MOUSEBUTTONUP, /**< Mouse button released */ SDL_JOYAXISMOTION, /**< Joystick axis motion */ SDL_JOYBALLMOTION, /**< Joystick trackball motion */ SDL_JOYHATMOTION, /**< Joystick hat position change */ SDL_JOYBUTTONDOWN, /**< Joystick button pressed */ SDL_JOYBUTTONUP, /**< Joystick button released */ SDL_QUIT, /**< User-requested quit */ SDL_SYSWMEVENT, /**< System specific event */ SDL_EVENT_RESERVEDA, /**< Reserved for future use.. */ SDL_EVENT_RESERVEDB, /**< Reserved for future use.. */ SDL_VIDEORESIZE, /**< User resized video mode */ SDL_VIDEOEXPOSE, /**< Screen needs to be redrawn */ SDL_EVENT_RESERVED2, /**< Reserved for future use.. */ SDL_EVENT_RESERVED3, /**< Reserved for future use.. */ SDL_EVENT_RESERVED4, /**< Reserved for future use.. */ SDL_EVENT_RESERVED5, /**< Reserved for future use.. */ SDL_EVENT_RESERVED6, /**< Reserved for future use.. */ SDL_EVENT_RESERVED7, /**< Reserved for future use.. */ /** Events SDL_USEREVENT through SDL_MAXEVENTS-1 are for your use */ SDL_USEREVENT = 24, /** This last event is only for bounding internal arrays * It is the number of bits in the event mask datatype -- Uint32 */ SDL_NUMEVENTS = 32 } SDL_EventType; /** @name Predefined event masks */ /*@{*/ #define SDL_EVENTMASK(X) (1<<(X)) typedef enum { SDL_ACTIVEEVENTMASK = SDL_EVENTMASK(SDL_ACTIVEEVENT), SDL_KEYDOWNMASK = SDL_EVENTMASK(SDL_KEYDOWN), SDL_KEYUPMASK = SDL_EVENTMASK(SDL_KEYUP), SDL_KEYEVENTMASK = SDL_EVENTMASK(SDL_KEYDOWN)| SDL_EVENTMASK(SDL_KEYUP), SDL_MOUSEMOTIONMASK = SDL_EVENTMASK(SDL_MOUSEMOTION), SDL_MOUSEBUTTONDOWNMASK = SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN), SDL_MOUSEBUTTONUPMASK = SDL_EVENTMASK(SDL_MOUSEBUTTONUP), SDL_MOUSEEVENTMASK = SDL_EVENTMASK(SDL_MOUSEMOTION)| SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN)| SDL_EVENTMASK(SDL_MOUSEBUTTONUP), SDL_JOYAXISMOTIONMASK = SDL_EVENTMASK(SDL_JOYAXISMOTION), SDL_JOYBALLMOTIONMASK = SDL_EVENTMASK(SDL_JOYBALLMOTION), SDL_JOYHATMOTIONMASK = SDL_EVENTMASK(SDL_JOYHATMOTION), SDL_JOYBUTTONDOWNMASK = SDL_EVENTMASK(SDL_JOYBUTTONDOWN), SDL_JOYBUTTONUPMASK = SDL_EVENTMASK(SDL_JOYBUTTONUP), SDL_JOYEVENTMASK = SDL_EVENTMASK(SDL_JOYAXISMOTION)| SDL_EVENTMASK(SDL_JOYBALLMOTION)| SDL_EVENTMASK(SDL_JOYHATMOTION)| SDL_EVENTMASK(SDL_JOYBUTTONDOWN)| SDL_EVENTMASK(SDL_JOYBUTTONUP), SDL_VIDEORESIZEMASK = SDL_EVENTMASK(SDL_VIDEORESIZE), SDL_VIDEOEXPOSEMASK = SDL_EVENTMASK(SDL_VIDEOEXPOSE), SDL_QUITMASK = SDL_EVENTMASK(SDL_QUIT), SDL_SYSWMEVENTMASK = SDL_EVENTMASK(SDL_SYSWMEVENT) } SDL_EventMask ; #define SDL_ALLEVENTS 0xFFFFFFFF /*@}*/ /** Application visibility event structure */ typedef struct SDL_ActiveEvent { Uint8 type; /**< SDL_ACTIVEEVENT */ Uint8 gain; /**< Whether given states were gained or lost (1/0) */ Uint8 state; /**< A mask of the focus states */ } SDL_ActiveEvent; /** Keyboard event structure */ typedef struct SDL_KeyboardEvent { Uint8 type; /**< SDL_KEYDOWN or SDL_KEYUP */ Uint8 which; /**< The keyboard device index */ Uint8 state; /**< SDL_PRESSED or SDL_RELEASED */ SDL_keysym keysym; } SDL_KeyboardEvent; /** Mouse motion event structure */ typedef struct SDL_MouseMotionEvent { Uint8 type; /**< SDL_MOUSEMOTION */ Uint8 which; /**< The mouse device index */ Uint8 state; /**< The current button state */ Uint16 x, y; /**< The X/Y coordinates of the mouse */ Sint16 xrel; /**< The relative motion in the X direction */ Sint16 yrel; /**< The relative motion in the Y direction */ } SDL_MouseMotionEvent; /** Mouse button event structure */ typedef struct SDL_MouseButtonEvent { Uint8 type; /**< SDL_MOUSEBUTTONDOWN or SDL_MOUSEBUTTONUP */ Uint8 which; /**< The mouse device index */ Uint8 button; /**< The mouse button index */ Uint8 state; /**< SDL_PRESSED or SDL_RELEASED */ Uint16 x, y; /**< The X/Y coordinates of the mouse at press time */ } SDL_MouseButtonEvent; /** Joystick axis motion event structure */ typedef struct SDL_JoyAxisEvent { Uint8 type; /**< SDL_JOYAXISMOTION */ Uint8 which; /**< The joystick device index */ Uint8 axis; /**< The joystick axis index */ Sint16 value; /**< The axis value (range: -32768 to 32767) */ } SDL_JoyAxisEvent; /** Joystick trackball motion event structure */ typedef struct SDL_JoyBallEvent { Uint8 type; /**< SDL_JOYBALLMOTION */ Uint8 which; /**< The joystick device index */ Uint8 ball; /**< The joystick trackball index */ Sint16 xrel; /**< The relative motion in the X direction */ Sint16 yrel; /**< The relative motion in the Y direction */ } SDL_JoyBallEvent; /** Joystick hat position change event structure */ typedef struct SDL_JoyHatEvent { Uint8 type; /**< SDL_JOYHATMOTION */ Uint8 which; /**< The joystick device index */ Uint8 hat; /**< The joystick hat index */ Uint8 value; /**< The hat position value: * SDL_HAT_LEFTUP SDL_HAT_UP SDL_HAT_RIGHTUP * SDL_HAT_LEFT SDL_HAT_CENTERED SDL_HAT_RIGHT * SDL_HAT_LEFTDOWN SDL_HAT_DOWN SDL_HAT_RIGHTDOWN * Note that zero means the POV is centered. */ } SDL_JoyHatEvent; /** Joystick button event structure */ typedef struct SDL_JoyButtonEvent { Uint8 type; /**< SDL_JOYBUTTONDOWN or SDL_JOYBUTTONUP */ Uint8 which; /**< The joystick device index */ Uint8 button; /**< The joystick button index */ Uint8 state; /**< SDL_PRESSED or SDL_RELEASED */ } SDL_JoyButtonEvent; /** The "window resized" event * When you get this event, you are responsible for setting a new video * mode with the new width and height. */ typedef struct SDL_ResizeEvent { Uint8 type; /**< SDL_VIDEORESIZE */ int w; /**< New width */ int h; /**< New height */ } SDL_ResizeEvent; /** The "screen redraw" event */ typedef struct SDL_ExposeEvent { Uint8 type; /**< SDL_VIDEOEXPOSE */ } SDL_ExposeEvent; /** The "quit requested" event */ typedef struct SDL_QuitEvent { Uint8 type; /**< SDL_QUIT */ } SDL_QuitEvent; /** A user-defined event type */ typedef struct SDL_UserEvent { Uint8 type; /**< SDL_USEREVENT through SDL_NUMEVENTS-1 */ int code; /**< User defined event code */ void *data1; /**< User defined data pointer */ void *data2; /**< User defined data pointer */ } SDL_UserEvent; /** If you want to use this event, you should include SDL_syswm.h */ struct SDL_SysWMmsg; typedef struct SDL_SysWMmsg SDL_SysWMmsg; typedef struct SDL_SysWMEvent { Uint8 type; SDL_SysWMmsg *msg; } SDL_SysWMEvent; /** General event structure */ typedef union SDL_Event { Uint8 type; SDL_ActiveEvent active; SDL_KeyboardEvent key; SDL_MouseMotionEvent motion; SDL_MouseButtonEvent button; SDL_JoyAxisEvent jaxis; SDL_JoyBallEvent jball; SDL_JoyHatEvent jhat; SDL_JoyButtonEvent jbutton; SDL_ResizeEvent resize; SDL_ExposeEvent expose; SDL_QuitEvent quit; SDL_UserEvent user; SDL_SysWMEvent syswm; } SDL_Event; /* Function prototypes */ /** Pumps the event loop, gathering events from the input devices. * This function updates the event queue and internal input device state. * This should only be run in the thread that sets the video mode. */ extern DECLSPEC void SDLCALL SDL_PumpEvents(void); typedef enum { SDL_ADDEVENT, SDL_PEEKEVENT, SDL_GETEVENT } SDL_eventaction; /** * Checks the event queue for messages and optionally returns them. * * If 'action' is SDL_ADDEVENT, up to 'numevents' events will be added to * the back of the event queue. * If 'action' is SDL_PEEKEVENT, up to 'numevents' events at the front * of the event queue, matching 'mask', will be returned and will not * be removed from the queue. * If 'action' is SDL_GETEVENT, up to 'numevents' events at the front * of the event queue, matching 'mask', will be returned and will be * removed from the queue. * * @return * This function returns the number of events actually stored, or -1 * if there was an error. * * This function is thread-safe. */ extern DECLSPEC int SDLCALL SDL_PeepEvents(SDL_Event *events, int numevents, SDL_eventaction action, Uint32 mask); /** Polls for currently pending events, and returns 1 if there are any pending * events, or 0 if there are none available. If 'event' is not NULL, the next * event is removed from the queue and stored in that area. */ extern DECLSPEC int SDLCALL SDL_PollEvent(SDL_Event *event); /** Waits indefinitely for the next available event, returning 1, or 0 if there * was an error while waiting for events. If 'event' is not NULL, the next * event is removed from the queue and stored in that area. */ extern DECLSPEC int SDLCALL SDL_WaitEvent(SDL_Event *event); /** Add an event to the event queue. * This function returns 0 on success, or -1 if the event queue was full * or there was some other error. */ extern DECLSPEC int SDLCALL SDL_PushEvent(SDL_Event *event); /** @name Event Filtering */ /*@{*/ typedef int (SDLCALL *SDL_EventFilter)(const SDL_Event *event); /** * This function sets up a filter to process all events before they * change internal state and are posted to the internal event queue. * * The filter is protypted as: * @code typedef int (SDLCALL *SDL_EventFilter)(const SDL_Event *event); @endcode * * If the filter returns 1, then the event will be added to the internal queue. * If it returns 0, then the event will be dropped from the queue, but the * internal state will still be updated. This allows selective filtering of * dynamically arriving events. * * @warning Be very careful of what you do in the event filter function, as * it may run in a different thread! * * There is one caveat when dealing with the SDL_QUITEVENT event type. The * event filter is only called when the window manager desires to close the * application window. If the event filter returns 1, then the window will * be closed, otherwise the window will remain open if possible. * If the quit event is generated by an interrupt signal, it will bypass the * internal queue and be delivered to the application at the next event poll. */ extern DECLSPEC void SDLCALL SDL_SetEventFilter(SDL_EventFilter filter); /** * Return the current event filter - can be used to "chain" filters. * If there is no event filter set, this function returns NULL. */ extern DECLSPEC SDL_EventFilter SDLCALL SDL_GetEventFilter(void); /*@}*/ /** @name Event State */ /*@{*/ #define SDL_QUERY -1 #define SDL_IGNORE 0 #define SDL_DISABLE 0 #define SDL_ENABLE 1 /*@}*/ /** * This function allows you to set the state of processing certain events. * If 'state' is set to SDL_IGNORE, that event will be automatically dropped * from the event queue and will not event be filtered. * If 'state' is set to SDL_ENABLE, that event will be processed normally. * If 'state' is set to SDL_QUERY, SDL_EventState() will return the * current processing state of the specified event. */ extern DECLSPEC Uint8 SDLCALL SDL_EventState(Uint8 type, int state); /* Ends C function definitions when using C++ */ #ifdef __cplusplus } #endif #include "close_code.h" #endif /* _SDL_events_h */ ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL.sats0000664000175000017500000000710712223166165020157 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) // // API for SDL in ATS // (* ****** ****** *) %{# #include "contrib/SDL/CATS/SDL.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) symintr NULL symintr Sint8 Uint8 symintr Sint16 Uint16 symintr Sint32 Uint32 symintr Sint64 Uint64 symintr ref_null // castfn symintr ref_free_null // castfn symintr ref_is_null ref_isnot_null // fun (* ****** ****** *) #include "contrib/SDL/SATS/SDL_stdinc.sats" (* ****** ****** *) #include "contrib/SDL/SATS/SDL_events.sats" #include "contrib/SDL/SATS/SDL_thread.sats" #include "contrib/SDL/SATS/SDL_timer.sats" #include "contrib/SDL/SATS/SDL_video.sats" (* ****** ****** *) (* #define SDL_INIT_TIMER 0x00000001 #define SDL_INIT_AUDIO 0x00000010 #define SDL_INIT_VIDEO 0x00000020 #define SDL_INIT_CDROM 0x00000100 #define SDL_INIT_JOYSTICK 0x00000200 #define SDL_INIT_NOPARACHUTE 0x00100000 /**< Don't catch fatal signals */ #define SDL_INIT_EVENTTHREAD 0x01000000 /**< Not supported on all OS's */ #define SDL_INIT_EVERYTHING 0x0000FFFF *) macdef SDL_INIT_TIMER = $extval (Uint32, "SDL_INIT_TIMER") macdef SDL_INIT_AUDIO = $extval (Uint32, "SDL_INIT_AUDIO") macdef SDL_INIT_VIDEO = $extval (Uint32, "SDL_INIT_VIDEO") macdef SDL_INIT_CDROM = $extval (Uint32, "SDL_INIT_CDROM") macdef SDL_INIT_JOYSTICK = $extval (Uint32, "SDL_INIT_JOYSTICK") macdef SDL_INIT_NOPARACHUTE = $extval (Uint32, "SDL_INIT_NOPARACHUTE") macdef SDL_INIT_EVENTTHREAD = $extval (Uint32, "SDL_INIT_EVENTTHREAD") macdef SDL_INIT_EVERYTHING = $extval (Uint32, "SDL_INIT_EVERYTHING") (* ****** ****** *) fun SDL_Init (flags: Uint32): int = "mac#atsctrb_SDL_Init" // end of [fun] castfn SDL_Quit_Video {l:addr} ( pf: Video_v l | sf: SDL_Surface_ref l ) : ptr // end of [castfn] fun SDL_Quit (): void = "mac#atsctrb_SDL_Quit" (* ****** ****** *) fun SDL_InitSubSystem (flags: Uint32): int = "mac#atsctrb_SDL_InitSubSystem" fun SDL_QuitSubSystem (flags: Uint32): void = "mac#atsctrb_SDL_QuitSubSystem" fun SDL_WasInit (flags: Uint32): Uint32 = "mac#atsctrb_SDL_WasInit" (* ****** ****** *) (* end of [SDL.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_stdinc.sats0000664000175000017500000001035312223166165021520 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) abst@ype Sint8 = int8_t0ype abst@ype Uint8 = uint8_t0ype castfn Sint8_of_int (x: int):<> Sint8 overload Sint8 with Sint8_of_int castfn int_of_Sint8 (x: Sint8):<> int castfn Uint8_of_int (x: int):<> Uint8 overload Uint8 with Uint8_of_int castfn int_of_Uint8 (x: Uint8):<> int castfn Uint8_of_uint (x: uint):<> Uint8 overload Uint8 with Uint8_of_uint castfn uint_of_Uint8 (x: Uint8):<> uint fun land_Uint8_Uint8 (x1: Uint8, x2: Uint8): Uint8 = "atsctrb_land_Uint8_Uint8" // function overload land with land_Uint8_Uint8 fun lor_Uint8_Uint8 (x1: Uint8, x2: Uint8): Uint8 = "atsctrb_lor_Uint8_Uint8" // function overload lor with lor_Uint8_Uint8 (* ****** ****** *) abst@ype Sint16 = int16_t0ype abst@ype Uint16 = uint16_t0ype castfn Sint16_of_int (x: int):<> Sint16 overload Sint16 with Sint16_of_int castfn int_of_Sint16 (x: Sint16):<> int castfn Uint16_of_int (x: int):<> Uint16 overload Uint16 with Uint16_of_int castfn int_of_Uint16 (x: Uint16):<> int castfn Uint16_of_uint (x: uint):<> Uint16 overload Uint16 with Uint16_of_uint castfn uint_of_Uint16 (x: Uint16):<> uint (* ****** ****** *) abst@ype Sint32 = int32_t0ype abst@ype Uint32 = uint32_t0ype castfn Sint32_of_int (x: int):<> Sint32 overload Sint32 with Sint32_of_int castfn int_of_Sint32 (x: Sint32):<> int castfn Uint32_of_int (x: int):<> Uint32 overload Uint32 with Uint32_of_int castfn int_of_Uint32 (x: Uint32):<> int castfn Uint32_of_uint (x: uint):<> Uint32 overload Uint32 with Uint32_of_uint castfn uint_of_Uint32 (x: Uint32):<> uint (* ****** ****** *) abst@ype Sint64 = int64_t0ype abst@ype Uint64 = uint64_t0ype (* ****** ****** *) fun add_Uint16_Uint16 (x1: Uint16, x2: Uint16): Uint16 = "atsctrb_add_Uint16_Uint16" // function overload + with add_Uint16_Uint16 fun sub_Uint16_Uint16 (x1: Uint16, x2: Uint16): Uint16 = "atsctrb_sub_Uint16_Uint16" // function overload - with sub_Uint16_Uint16 fun land_Uint16_Uint16 (x1: Uint16, x2: Uint16): Uint16 = "atsctrb_land_Uint16_Uint16" // function overload land with land_Uint16_Uint16 fun lor_Uint16_Uint16 (x1: Uint16, x2: Uint16): Uint16 = "atsctrb_lor_Uint16_Uint16" // function overload lor with lor_Uint16_Uint16 (* ****** ****** *) fun add_Uint32_Uint32 (x1: Uint32, x2: Uint32): Uint32 = "atsctrb_add_Uint32_Uint32" // function overload + with add_Uint32_Uint32 fun sub_Uint32_Uint32 (x1: Uint32, x2: Uint32): Uint32 = "atsctrb_sub_Uint32_Uint32" // function overload - with sub_Uint32_Uint32 fun land_Uint32_Uint32 (x1: Uint32, x2: Uint32): Uint32 = "atsctrb_land_Uint32_Uint32" // function overload land with land_Uint32_Uint32 fun lor_Uint32_Uint32 (x1: Uint32, x2: Uint32): Uint32 = "atsctrb_lor_Uint32_Uint32" // function overload lor with lor_Uint32_Uint32 (* ****** ****** *) (* end of [SDL_stdinc.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_thread.sats0000664000175000017500000000406712223166165021510 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) absviewtype SDL_Thread_ptr // SDL_Thread* (* ****** ****** *) fun SDL_ThreadID ():<> Uint32 = "mac#atsctrb_SDL_ThreadID" (* ****** ****** *) fun SDL_CreateThread {vt:viewtype} ( threadfun: (vt) - int, env: vt ) : SDL_Thread_ptr = "mac#atsctrb_SDL_CreateThread" // end of [fun] fun SDL_KillThread (thread: SDL_Thread_ptr):<> void = "mac#atsctrb_SDL_KillThread" // end of [fun] fun SDL_WaitThread ( thread: SDL_Thread_ptr, status: &int? >> int ) :<> void = "mac#atsctrb_SDL_WaitThread" // end of [fun] (* ****** ****** *) (* end of [SDL_thread.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_ttf.sats0000664000175000017500000001545112223166165021035 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) %{# #include "contrib/SDL/CATS/SDL_ttf.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for static loading at run-time (* ****** ****** *) staload "contrib/SDL/SATS/SDL.sats" (* ****** ****** *) // // HX-2010-jan: is this type refcounted? // absviewtype TTF_Font_ref (l:addr) // TTF_Font* or null viewtypedef TTF_Font_ref0 = [l:agez] TTF_Font_ref l viewtypedef TTF_Font_ref1 = [l:addr | l <> null] TTF_Font_ref l fun TTF_Font_ref_null ():<> TTF_Font_ref null = "atsctrb_SDL_ref_null" fun TTF_Font_ref_free_null (sf: TTF_Font_ref null):<> void = "atsctrb_SDL_ref_free_null" // overload ref_free_null with TTF_Font_ref_free_null fun TTF_Font_ref_is_null {l:addr} (x: !TTF_Font_ref l):<> bool (l == null) = "atsctrb_SDL_ref_is_null" overload ref_is_null with TTF_Font_ref_is_null fun TTF_Font_ref_isnot_null {l:addr} (x: !TTF_Font_ref l):<> bool (l <> null) = "atsctrb_SDL_ref_isnot_null" overload ref_isnot_null with TTF_Font_ref_isnot_null (* ****** ****** *) fun TTF_Init (): int (*err*) = "atsctrb_TTF_Init" (* ****** ****** *) (* extern DECLSPEC TTF_Font * SDLCALL TTF_OpenFont(const char *file, int ptsize); extern DECLSPEC TTF_Font * SDLCALL TTF_OpenFontIndex(const char *file, int ptsize, long index); extern DECLSPEC TTF_Font * SDLCALL TTF_OpenFontRW(SDL_RWops *src, int freesrc, int ptsize); extern DECLSPEC TTF_Font * SDLCALL TTF_OpenFontIndexRW(SDL_RWops *src, int freesrc, int ptsize, long index); *) fun TTF_OpenFont (filename: string, ptsize: int): TTF_Font_ref0 = "mac#atsctrb_TTF_OpenFont" // end of [TTF_OpenFont] (* ****** ****** *) macdef TTF_STYLE_NORMAL = $extval (int, "TTF_STYLE_NORMAL") macdef TTF_STYLE_BOLD = $extval (int, "TTF_STYLE_BOLD") macdef TTF_STYLE_ITALIC = $extval (int, "TTF_STYLE_ITALIC") macdef TTF_STYLE_UNDERLINE = $extval (int, "TTF_STYLE_UNDERLINE") fun TTF_GetFontStyle {l:agz} (font: !TTF_Font_ref l): int(*style*) = "mac#atsctrb_TTF_GetFontStyle" // end of [TTF_GetFontStyle] fun TTF_SetFontStyle {l:agz} (font: !TTF_Font_ref l, style: int): void = "mac#atsctrb_TTF_SetFontStyle" // end of [TTF_SetFontStyle] fun TTF_FontHeight {l:agz} (font: !TTF_Font_ref l): int(*height*) = "mac#atsctrb_TTF_FontHeight" // end of [TTF_FontHeight] fun TTF_FontAscent {l:agz} (font: !TTF_Font_ref l): int(*ascent*) = "mac#atsctrb_TTF_FontAscent" // end of [TTF_FontAscent] fun TTF_FontDescent {l:agz} (font: !TTF_Font_ref l): int(*descent*) = "mac#atsctrb_TTF_FontDescent" // end of [TTF_FontDescent] fun TTF_FontLineSkip {l:agz} (font: !TTF_Font_ref l): int(*lineskip*) = "mac#atsctrb_TTF_FontLineSkip" // end of [TTF_FontLineSkip] fun TTF_FontFaces {l:agz} (font: !TTF_Font_ref l): lint(*number of faces*) = "mac#atsctrb_TTF_FontFaces" // end of [TTF_FontFaces] (* ****** ****** *) fun TTF_FontFaceIsFixedWidth {l:agz} (font: !TTF_Font_ref l): int = "mac#atsctrb_TTF_FontFaceIsFixedWidth" fun TTF_FontFaceFamilyName {l:agz} (font: !TTF_Font_ref l): string = "mac#atsctrb_TTF_FontFaceFamilyName" fun TTF_FontFaceStyleName {l:agz} (font: !TTF_Font_ref l): string = "mac#atsctrb_FontFaceStyleName" (* ****** ****** *) fun TTF_SizeText {l:agz} (font: !TTF_Font_ref l, txt: string, w: &int? >> int, h: &int? >> int): int(*err*) = "mac#atsctrb_TTF_SizeText" fun TTF_SizeUTF8 {l:agz} (font: !TTF_Font_ref l, txt: string, w: &int? >> int, h: &int? >> int): int(*err*) = "mac#atsctrb_TTF_SizeUTF8" (* fun TTF_SizeUTF16 {l:agz} (font: !TTF_Font_ref l, txt: wstring, w: &int? >> int, h: &int? >> int): int = "mac#atsctrb_TTF_SizeUTF16" *) (* ****** ****** *) fun TTF_GlyphMetrics {l:agz} ( font: !TTF_Font_ref l, ch: Uint16 , minx: &int? >> int, maxx: &int? >> int , miny: &int? >> int, maxy: &int? >> int , advance: &int? >> int ) : int (*err*) = "mac#atsctrb_TTF_GlyphMetrics" // end of [TTF_GlyphMetrics] (* ****** ****** *) fun TTF_RenderText_Solid {l:agz} (font: !TTF_Font_ref l, txt: string, fg: SDL_Color): SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderText_Solid" fun TTF_RenderUTF8_Solid {l:agz} (font: !TTF_Font_ref l, txt: string, fg: SDL_Color): SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderUTF8_Solid" (* fun TTF_RenderUTF16_Solid {l:agz} (font: !TTF_Font_ref l, txt: wstring, fg: SDL_Color): SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderUTF16_Solid" *) (* ****** ****** *) fun TTF_RenderText_Shaded {l:agz} ( font: !TTF_Font_ref l, txt: string, fg: SDL_Color, bg: SDL_Color ) : SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderText_Shaded" // end of [TTF_RenderText_Shaded] fun TTF_RenderUTF8_Shaded {l:agz} ( font: !TTF_Font_ref l, txt: string, fg: SDL_Color, bg: SDL_Color ) : SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderUTF8_Shaded" // end of [TTF_RenderUTF8_Shaded] (* fun TTF_RenderUTF16_Shaded {l:agz} ( font: !TTF_Font_ref l, txt: wstring, fg: SDL_Color, bg: SDL_Color ) : SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderUTF16_Shaded" *) (* ****** ****** *) fun TTF_RenderGlyph_Solid {l:agz} ( font: !TTF_Font_ref l, ch: Uint16, fg: SDL_Color ) : SDL_Surface_ref0 = "mac#atsctrb_TTF_RenderGlyph_Solid" // end of [TTF_RenderGlyph_Solid] (* ****** ****** *) fun TTF_CloseFont {l:agz} (font: TTF_Font_ref l): void = "mac#atsctrb_TTF_CloseFont" // end of [TTF_CloseFont] (* ****** ****** *) fun TTF_Quit (): void = "mac#atsctrb_TTF_Quit" fun TTF_WasInit (): int = "mac#atsctrb_TTF_WasInit" (* ****** ****** *) (* end of [SDL_ttf.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_image.sats0000664000175000017500000000376412223166165021326 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) %{# #include "contrib/SDL/CATS/SDL_image.cats" %} // end of [%{#] (* ****** ****** *) staload "contrib/SDL/SATS/SDL.sats" (* ****** ****** *) macdef SDL_IMAGE_MAJOR_VERSION = $extval (int, "SDL_IMAGE_MAJOR_VERSION") macdef SDL_IMAGE_MINOR_VERSION = $extval (int, "SDL_IMAGE_MINOR_VERSION") macdef SDL_IMAGE_PATCHLEVEL = $extval (int, "SDL_IMAGE_PATCHLEVEL") (* ****** ****** *) fun IMG_Load (filename: string): SDL_Surface_ref0 = "mac#atsctrb_IMG_Load" (* ****** ****** *) (* end of [SDL_image.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_active.sats0000664000175000017500000000362412223166165021512 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) macdef SDL_APPMOUSEFOCUS = $extval (Uint8, "SDL_APPMOUSEFOCUS") // The app has mouse coverage macdef SDL_APPINPUTFOCUS = $extval (Uint8, "SDL_APPINPUTFOCUS") // The app has input focus macdef SDL_APPACTIVE = $extval (Uint8, "SDL_APPACTIVE") // The application is active (* ****** ****** *) fun SDL_GetAppState (): Uint8 = "mac#atsctrb_SDL_GetAppState" (* ****** ****** *) (* end of [SDL_active.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_keysym.sats0000664000175000017500000003520212223166165021555 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) abst@ype SDLKey = $extype"SDLKey" // castfn int_of_SDLKey (x: SDLKey):<> int fun eq_SDLKey_SDLKey (x1: SDLKey, x2: SDLKey):<> bool = "atsctrb_eq_SDLKey_SDLKey" overload = with eq_SDLKey_SDLKey // macdef SDLK_UNKNOWN = $extval (SDLKey, "SDLK_UNKNOWN") macdef SDLK_FIRST = $extval (SDLKey, "SDLK_FIRST") macdef SDLK_BACKSPACE = $extval (SDLKey, "SDLK_BACKSPACE") macdef SDLK_TAB = $extval (SDLKey, "SDLK_TAB") macdef SDLK_CLEAR = $extval (SDLKey, "SDLK_CLEAR") macdef SDLK_RETURN = $extval (SDLKey, "SDLK_RETURN") macdef SDLK_PAUSE = $extval (SDLKey, "SDLK_PAUSE") macdef SDLK_ESCAPE = $extval (SDLKey, "SDLK_ESCAPE") macdef SDLK_SPACE = $extval (SDLKey, "SDLK_SPACE") macdef SDLK_EXCLAIM = $extval (SDLKey, "SDLK_EXCLAIM") macdef SDLK_QUOTEDBL = $extval (SDLKey, "SDLK_QUOTEDBL") macdef SDLK_HASH = $extval (SDLKey, "SDLK_HASH") macdef SDLK_DOLLAR = $extval (SDLKey, "SDLK_DOLLAR") macdef SDLK_AMPERSAND = $extval (SDLKey, "SDLK_AMPERSAND") macdef SDLK_QUOTE = $extval (SDLKey, "SDLK_QUOTE") macdef SDLK_LEFTPAREN = $extval (SDLKey, "SDLK_LEFTPAREN") macdef SDLK_RIGHTPAREN = $extval (SDLKey, "SDLK_RIGHTPAREN") macdef SDLK_ASTERISK = $extval (SDLKey, "SDLK_ASTERISK") macdef SDLK_PLUS = $extval (SDLKey, "SDLK_PLUS") macdef SDLK_COMMA = $extval (SDLKey, "SDLK_COMMA") macdef SDLK_MINUS = $extval (SDLKey, "SDLK_MINUS") macdef SDLK_PERIOD = $extval (SDLKey, "SDLK_PERIOD") macdef SDLK_SLASH = $extval (SDLKey, "SDLK_SLASH") macdef SDLK_0 = $extval (SDLKey, "SDLK_0") macdef SDLK_1 = $extval (SDLKey, "SDLK_1") macdef SDLK_2 = $extval (SDLKey, "SDLK_2") macdef SDLK_3 = $extval (SDLKey, "SDLK_3") macdef SDLK_4 = $extval (SDLKey, "SDLK_4") macdef SDLK_5 = $extval (SDLKey, "SDLK_5") macdef SDLK_6 = $extval (SDLKey, "SDLK_6") macdef SDLK_7 = $extval (SDLKey, "SDLK_7") macdef SDLK_8 = $extval (SDLKey, "SDLK_8") macdef SDLK_9 = $extval (SDLKey, "SDLK_9") macdef SDLK_COLON = $extval (SDLKey, "SDLK_COLON") macdef SDLK_SEMICOLON = $extval (SDLKey, "SDLK_SEMICOLON") macdef SDLK_LESS = $extval (SDLKey, "SDLK_LESS") macdef SDLK_EQUALS = $extval (SDLKey, "SDLK_EQUALS") macdef SDLK_GREATER = $extval (SDLKey, "SDLK_GREATER") macdef SDLK_QUESTION = $extval (SDLKey, "SDLK_QUESTION") macdef SDLK_AT = $extval (SDLKey, "SDLK_AT") // macdef SDLK_LEFTBRACKET = $extval (SDLKey, "SDLK_LEFTBRACKET") macdef SDLK_BACKSLASH = $extval (SDLKey, "SDLK_BACKSLASH") macdef SDLK_RIGHTBRACKET = $extval (SDLKey, "SDLK_RIGHTBRACKET") macdef SDLK_CARET = $extval (SDLKey, "SDLK_CARET") macdef SDLK_UNDERSCORE = $extval (SDLKey, "SDLK_UNDERSCORE") macdef SDLK_BACKQUOTE = $extval (SDLKey, "SDLK_BACKQUOTE") macdef SDLK_a = $extval (SDLKey, "SDLK_a") macdef SDLK_b = $extval (SDLKey, "SDLK_b") macdef SDLK_c = $extval (SDLKey, "SDLK_c") macdef SDLK_d = $extval (SDLKey, "SDLK_d") macdef SDLK_e = $extval (SDLKey, "SDLK_e") macdef SDLK_f = $extval (SDLKey, "SDLK_f") macdef SDLK_g = $extval (SDLKey, "SDLK_g") macdef SDLK_h = $extval (SDLKey, "SDLK_h") macdef SDLK_i = $extval (SDLKey, "SDLK_i") macdef SDLK_j = $extval (SDLKey, "SDLK_j") macdef SDLK_k = $extval (SDLKey, "SDLK_k") macdef SDLK_l = $extval (SDLKey, "SDLK_l") macdef SDLK_m = $extval (SDLKey, "SDLK_m") macdef SDLK_n = $extval (SDLKey, "SDLK_n") macdef SDLK_o = $extval (SDLKey, "SDLK_o") macdef SDLK_p = $extval (SDLKey, "SDLK_p") macdef SDLK_q = $extval (SDLKey, "SDLK_q") macdef SDLK_r = $extval (SDLKey, "SDLK_r") macdef SDLK_s = $extval (SDLKey, "SDLK_s") macdef SDLK_t = $extval (SDLKey, "SDLK_t") macdef SDLK_u = $extval (SDLKey, "SDLK_u") macdef SDLK_v = $extval (SDLKey, "SDLK_v") macdef SDLK_w = $extval (SDLKey, "SDLK_w") macdef SDLK_x = $extval (SDLKey, "SDLK_x") macdef SDLK_y = $extval (SDLKey, "SDLK_y") macdef SDLK_z = $extval (SDLKey, "SDLK_z") macdef SDLK_DELETE = $extval (SDLKey, "SDLK_DELETE") // macdef SDLK_WORLD_0 = $extval (SDLKey, "SDLK_WORLD_0") macdef SDLK_WORLD_1 = $extval (SDLKey, "SDLK_WORLD_1") macdef SDLK_WORLD_2 = $extval (SDLKey, "SDLK_WORLD_2") macdef SDLK_WORLD_3 = $extval (SDLKey, "SDLK_WORLD_3") macdef SDLK_WORLD_4 = $extval (SDLKey, "SDLK_WORLD_4") macdef SDLK_WORLD_5 = $extval (SDLKey, "SDLK_WORLD_5") macdef SDLK_WORLD_6 = $extval (SDLKey, "SDLK_WORLD_6") macdef SDLK_WORLD_7 = $extval (SDLKey, "SDLK_WORLD_7") macdef SDLK_WORLD_8 = $extval (SDLKey, "SDLK_WORLD_8") macdef SDLK_WORLD_9 = $extval (SDLKey, "SDLK_WORLD_9") macdef SDLK_WORLD_10 = $extval (SDLKey, "SDLK_WORLD_10") macdef SDLK_WORLD_11 = $extval (SDLKey, "SDLK_WORLD_11") macdef SDLK_WORLD_12 = $extval (SDLKey, "SDLK_WORLD_12") macdef SDLK_WORLD_13 = $extval (SDLKey, "SDLK_WORLD_13") macdef SDLK_WORLD_14 = $extval (SDLKey, "SDLK_WORLD_14") macdef SDLK_WORLD_15 = $extval (SDLKey, "SDLK_WORLD_15") macdef SDLK_WORLD_16 = $extval (SDLKey, "SDLK_WORLD_16") macdef SDLK_WORLD_17 = $extval (SDLKey, "SDLK_WORLD_17") macdef SDLK_WORLD_18 = $extval (SDLKey, "SDLK_WORLD_18") macdef SDLK_WORLD_19 = $extval (SDLKey, "SDLK_WORLD_19") macdef SDLK_WORLD_20 = $extval (SDLKey, "SDLK_WORLD_20") macdef SDLK_WORLD_21 = $extval (SDLKey, "SDLK_WORLD_21") macdef SDLK_WORLD_22 = $extval (SDLKey, "SDLK_WORLD_22") macdef SDLK_WORLD_23 = $extval (SDLKey, "SDLK_WORLD_23") macdef SDLK_WORLD_24 = $extval (SDLKey, "SDLK_WORLD_24") macdef SDLK_WORLD_25 = $extval (SDLKey, "SDLK_WORLD_25") macdef SDLK_WORLD_26 = $extval (SDLKey, "SDLK_WORLD_26") macdef SDLK_WORLD_27 = $extval (SDLKey, "SDLK_WORLD_27") macdef SDLK_WORLD_28 = $extval (SDLKey, "SDLK_WORLD_28") macdef SDLK_WORLD_29 = $extval (SDLKey, "SDLK_WORLD_29") macdef SDLK_WORLD_30 = $extval (SDLKey, "SDLK_WORLD_30") macdef SDLK_WORLD_31 = $extval (SDLKey, "SDLK_WORLD_31") macdef SDLK_WORLD_32 = $extval (SDLKey, "SDLK_WORLD_32") macdef SDLK_WORLD_33 = $extval (SDLKey, "SDLK_WORLD_33") macdef SDLK_WORLD_34 = $extval (SDLKey, "SDLK_WORLD_34") macdef SDLK_WORLD_35 = $extval (SDLKey, "SDLK_WORLD_35") macdef SDLK_WORLD_36 = $extval (SDLKey, "SDLK_WORLD_36") macdef SDLK_WORLD_37 = $extval (SDLKey, "SDLK_WORLD_37") macdef SDLK_WORLD_38 = $extval (SDLKey, "SDLK_WORLD_38") macdef SDLK_WORLD_39 = $extval (SDLKey, "SDLK_WORLD_39") macdef SDLK_WORLD_40 = $extval (SDLKey, "SDLK_WORLD_40") macdef SDLK_WORLD_41 = $extval (SDLKey, "SDLK_WORLD_41") macdef SDLK_WORLD_42 = $extval (SDLKey, "SDLK_WORLD_42") macdef SDLK_WORLD_43 = $extval (SDLKey, "SDLK_WORLD_43") macdef SDLK_WORLD_44 = $extval (SDLKey, "SDLK_WORLD_44") macdef SDLK_WORLD_45 = $extval (SDLKey, "SDLK_WORLD_45") macdef SDLK_WORLD_46 = $extval (SDLKey, "SDLK_WORLD_46") macdef SDLK_WORLD_47 = $extval (SDLKey, "SDLK_WORLD_47") macdef SDLK_WORLD_48 = $extval (SDLKey, "SDLK_WORLD_48") macdef SDLK_WORLD_49 = $extval (SDLKey, "SDLK_WORLD_49") macdef SDLK_WORLD_50 = $extval (SDLKey, "SDLK_WORLD_50") macdef SDLK_WORLD_51 = $extval (SDLKey, "SDLK_WORLD_51") macdef SDLK_WORLD_52 = $extval (SDLKey, "SDLK_WORLD_52") macdef SDLK_WORLD_53 = $extval (SDLKey, "SDLK_WORLD_53") macdef SDLK_WORLD_54 = $extval (SDLKey, "SDLK_WORLD_54") macdef SDLK_WORLD_55 = $extval (SDLKey, "SDLK_WORLD_55") macdef SDLK_WORLD_56 = $extval (SDLKey, "SDLK_WORLD_56") macdef SDLK_WORLD_57 = $extval (SDLKey, "SDLK_WORLD_57") macdef SDLK_WORLD_58 = $extval (SDLKey, "SDLK_WORLD_58") macdef SDLK_WORLD_59 = $extval (SDLKey, "SDLK_WORLD_59") macdef SDLK_WORLD_60 = $extval (SDLKey, "SDLK_WORLD_60") macdef SDLK_WORLD_61 = $extval (SDLKey, "SDLK_WORLD_61") macdef SDLK_WORLD_62 = $extval (SDLKey, "SDLK_WORLD_62") macdef SDLK_WORLD_63 = $extval (SDLKey, "SDLK_WORLD_63") macdef SDLK_WORLD_64 = $extval (SDLKey, "SDLK_WORLD_64") macdef SDLK_WORLD_65 = $extval (SDLKey, "SDLK_WORLD_65") macdef SDLK_WORLD_66 = $extval (SDLKey, "SDLK_WORLD_66") macdef SDLK_WORLD_67 = $extval (SDLKey, "SDLK_WORLD_67") macdef SDLK_WORLD_68 = $extval (SDLKey, "SDLK_WORLD_68") macdef SDLK_WORLD_69 = $extval (SDLKey, "SDLK_WORLD_69") macdef SDLK_WORLD_70 = $extval (SDLKey, "SDLK_WORLD_70") macdef SDLK_WORLD_71 = $extval (SDLKey, "SDLK_WORLD_71") macdef SDLK_WORLD_72 = $extval (SDLKey, "SDLK_WORLD_72") macdef SDLK_WORLD_73 = $extval (SDLKey, "SDLK_WORLD_73") macdef SDLK_WORLD_74 = $extval (SDLKey, "SDLK_WORLD_74") macdef SDLK_WORLD_75 = $extval (SDLKey, "SDLK_WORLD_75") macdef SDLK_WORLD_76 = $extval (SDLKey, "SDLK_WORLD_76") macdef SDLK_WORLD_77 = $extval (SDLKey, "SDLK_WORLD_77") macdef SDLK_WORLD_78 = $extval (SDLKey, "SDLK_WORLD_78") macdef SDLK_WORLD_79 = $extval (SDLKey, "SDLK_WORLD_79") macdef SDLK_WORLD_80 = $extval (SDLKey, "SDLK_WORLD_80") macdef SDLK_WORLD_81 = $extval (SDLKey, "SDLK_WORLD_81") macdef SDLK_WORLD_82 = $extval (SDLKey, "SDLK_WORLD_82") macdef SDLK_WORLD_83 = $extval (SDLKey, "SDLK_WORLD_83") macdef SDLK_WORLD_84 = $extval (SDLKey, "SDLK_WORLD_84") macdef SDLK_WORLD_85 = $extval (SDLKey, "SDLK_WORLD_85") macdef SDLK_WORLD_86 = $extval (SDLKey, "SDLK_WORLD_86") macdef SDLK_WORLD_87 = $extval (SDLKey, "SDLK_WORLD_87") macdef SDLK_WORLD_88 = $extval (SDLKey, "SDLK_WORLD_88") macdef SDLK_WORLD_89 = $extval (SDLKey, "SDLK_WORLD_89") macdef SDLK_WORLD_90 = $extval (SDLKey, "SDLK_WORLD_90") macdef SDLK_WORLD_91 = $extval (SDLKey, "SDLK_WORLD_91") macdef SDLK_WORLD_92 = $extval (SDLKey, "SDLK_WORLD_92") macdef SDLK_WORLD_93 = $extval (SDLKey, "SDLK_WORLD_93") macdef SDLK_WORLD_94 = $extval (SDLKey, "SDLK_WORLD_94") macdef SDLK_WORLD_95 = $extval (SDLKey, "SDLK_WORLD_95") // macdef SDLK_KP0 = $extval (SDLKey, "SDLK_KP0") macdef SDLK_KP1 = $extval (SDLKey, "SDLK_KP1") macdef SDLK_KP2 = $extval (SDLKey, "SDLK_KP2") macdef SDLK_KP3 = $extval (SDLKey, "SDLK_KP3") macdef SDLK_KP4 = $extval (SDLKey, "SDLK_KP4") macdef SDLK_KP5 = $extval (SDLKey, "SDLK_KP5") macdef SDLK_KP6 = $extval (SDLKey, "SDLK_KP6") macdef SDLK_KP7 = $extval (SDLKey, "SDLK_KP7") macdef SDLK_KP8 = $extval (SDLKey, "SDLK_KP8") macdef SDLK_KP9 = $extval (SDLKey, "SDLK_KP9") macdef SDLK_KP_PERIOD = $extval (SDLKey, "SDLK_KP_PERIOD") macdef SDLK_KP_DIVIDE = $extval (SDLKey, "SDLK_KP_DIVIDE") macdef SDLK_KP_MULTIPLY = $extval (SDLKey, "SDLK_KP_MULTIPLY") macdef SDLK_KP_MINUS = $extval (SDLKey, "SDLK_KP_MINUS") macdef SDLK_KP_PLUS = $extval (SDLKey, "SDLK_KP_PLUS") macdef SDLK_KP_ENTER = $extval (SDLKey, "SDLK_KP_ENTER") macdef SDLK_KP_EQUALS = $extval (SDLKey, "SDLK_KP_EQUALS") // macdef SDLK_UP = $extval (SDLKey, "SDLK_UP") macdef SDLK_DOWN = $extval (SDLKey, "SDLK_DOWN") macdef SDLK_RIGHT = $extval (SDLKey, "SDLK_RIGHT") macdef SDLK_LEFT = $extval (SDLKey, "SDLK_LEFT") macdef SDLK_INSERT = $extval (SDLKey, "SDLK_INSERT") macdef SDLK_HOME = $extval (SDLKey, "SDLK_HOME") macdef SDLK_END = $extval (SDLKey, "SDLK_END") macdef SDLK_PAGEUP = $extval (SDLKey, "SDLK_PAGEUP") macdef SDLK_PAGEDOWN = $extval (SDLKey, "SDLK_PAGEDOWN") // macdef SDLK_F1 = $extval (SDLKey, "SDLK_F1") macdef SDLK_F2 = $extval (SDLKey, "SDLK_F2") macdef SDLK_F3 = $extval (SDLKey, "SDLK_F3") macdef SDLK_F4 = $extval (SDLKey, "SDLK_F4") macdef SDLK_F5 = $extval (SDLKey, "SDLK_F5") macdef SDLK_F6 = $extval (SDLKey, "SDLK_F6") macdef SDLK_F7 = $extval (SDLKey, "SDLK_F7") macdef SDLK_F8 = $extval (SDLKey, "SDLK_F8") macdef SDLK_F9 = $extval (SDLKey, "SDLK_F9") macdef SDLK_F10 = $extval (SDLKey, "SDLK_F10") macdef SDLK_F11 = $extval (SDLKey, "SDLK_F11") macdef SDLK_F12 = $extval (SDLKey, "SDLK_F12") macdef SDLK_F13 = $extval (SDLKey, "SDLK_F13") macdef SDLK_F14 = $extval (SDLKey, "SDLK_F14") macdef SDLK_F15 = $extval (SDLKey, "SDLK_F15") // macdef SDLK_NUMLOCK = $extval (SDLKey, "SDLK_NUMLOCK") macdef SDLK_CAPSLOCK = $extval (SDLKey, "SDLK_CAPSLOCK") macdef SDLK_SCROLLOCK = $extval (SDLKey, "SDLK_SCROLLOCK") macdef SDLK_RSHIFT = $extval (SDLKey, "SDLK_RSHIFT") macdef SDLK_LSHIFT = $extval (SDLKey, "SDLK_LSHIFT") macdef SDLK_RCTRL = $extval (SDLKey, "SDLK_RCTRL") macdef SDLK_LCTRL = $extval (SDLKey, "SDLK_LCTRL") macdef SDLK_RALT = $extval (SDLKey, "SDLK_RALT") macdef SDLK_LALT = $extval (SDLKey, "SDLK_LALT") macdef SDLK_RMETA = $extval (SDLKey, "SDLK_RMETA") macdef SDLK_LMETA = $extval (SDLKey, "SDLK_LMETA") macdef SDLK_LSUPER = $extval (SDLKey, "SDLK_LSUPER") macdef SDLK_RSUPER = $extval (SDLKey, "SDLK_RSUPER") macdef SDLK_MODE = $extval (SDLKey, "SDLK_MODE") macdef SDLK_COMPOSE = $extval (SDLKey, "SDLK_COMPOSE") macdef SDLK_HELP = $extval (SDLKey, "SDLK_HELP") macdef SDLK_PRINT = $extval (SDLKey, "SDLK_PRINT") macdef SDLK_SYSREQ = $extval (SDLKey, "SDLK_SYSREQ") macdef SDLK_BREAK = $extval (SDLKey, "SDLK_BREAK") macdef SDLK_MENU = $extval (SDLKey, "SDLK_MENU") macdef SDLK_POWER = $extval (SDLKey, "SDLK_POWER") macdef SDLK_EURO = $extval (SDLKey, "SDLK_EURO") macdef SDLK_UNDO = $extval (SDLKey, "SDLK_UNDO") // macdef SDLK_LAST = $extval (SDLKey, "SDLK_LAST") (* ****** ****** *) abst@ype SDLMod = $extype"SDLMod" // macdef KMOD_NONE = $extval (SDLMod, "KMOD_NONE") macdef KMOD_LSHIFT = $extval (SDLMod, "KMOD_LSHIFT") macdef KMOD_RSHIFT = $extval (SDLMod, "KMOD_RSHIFT") macdef KMOD_LCTRL = $extval (SDLMod, "KMOD_LCTRL") macdef KMOD_RCTRL = $extval (SDLMod, "KMOD_RCTRL") macdef KMOD_LALT = $extval (SDLMod, "KMOD_LALT") macdef KMOD_RALT = $extval (SDLMod, "KMOD_RALT") macdef KMOD_LMETA = $extval (SDLMod, "KMOD_LMETA") macdef KMOD_RMETA = $extval (SDLMod, "KMOD_RMETA") macdef KMOD_NUM = $extval (SDLMod, "KMOD_NUM") macdef KMOD_CAPS = $extval (SDLMod, "KMOD_CAPS") macdef KMOD_MODE = $extval (SDLMod, "KMOD_MODE") macdef KMOD_RESERVED = $extval (SDLMod, "KMOD_RESERVED") // macdef KMOD_CTRL = $extval (SDLMod, "KMOD_CTRL") macdef KMOD_SHIFT = $extval (SDLMod, "KMOD_SHIFT") macdef KMOD_ALT = $extval (SDLMod, "KMOD_ALT") macdef KMOD_META = $extval (SDLMod, "KMOD_META") (* ****** ****** *) (* end of [SDL_keysym.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_video.sats0000664000175000017500000003251212223166165021343 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) macdef SDL_ALPHA_OPAQUE = 255 macdef SDL_ALPHA_TRANSPARENT = 0 (* ****** ****** *) typedef SDL_Rect = $extype_struct "SDL_Rect" of { x= Sint16, y= Sint16, w= Uint16, h= Uint16 } // end of [SDL_Rect] fun SDL_Rect_init ( rect: &SDL_Rect? >> SDL_Rect , x: Sint16, y: Sint16, w: Uint16, h: Uint16 ) :<> void = "atsctrb_SDL_Rect_init" (* ****** ****** *) typedef SDL_Color = $extype_struct "SDL_Color" of { r= Uint8, g= Uint8, b= Uint8 (* , unused= Uint8 *) } // end of [SDL_Color] fun SDL_Color_init ( color: &SDL_Color? >> SDL_Color, r: Uint8, g: Uint8, b: Uint8 ) :<> void = "atsctrb_SDL_Color_init" (* ****** ****** *) viewtypedef SDL_PixelFormat = $extype_struct "SDL_PixelFormat" of { BitsPerPixel= Uint8 , BytesPerPixel= Uint8 , Rloss= Uint8, Gloss= Uint8, Bloss= Uint8, Aloss= Uint8 , Rshift= Uint8, Gshift= Uint8, Bshift= Uint8, Ashift= Uint8 , Rmask= Uint32, Gmask= Uint32, Bmask= Uint32, Amask= Uint32 , colorkey= Uint32 , alpha= Uint8 , rest= undefined_t // fields that are not exported } // end of [SDL_PixelFormat] (* ****** ****** *) // // HX: [SDL_Surface_ref] is reference counted // absviewtype SDL_Surface_ref (l:addr) // SDL_Surface* or null viewtypedef SDL_Surface_ref0 = [l:agez] SDL_Surface_ref l viewtypedef SDL_Surface_ref1 = [l:addr | l > null] SDL_Surface_ref l fun SDL_Surface_ref_null ():<> SDL_Surface_ref null = "atsctrb_SDL_ref_null" fun SDL_Surface_ref_free_null (sf: SDL_Surface_ref null):<> void = "atsctrb_SDL_ref_free_null" overload ref_free_null with SDL_Surface_ref_free_null fun SDL_Surface_ref_is_null {l:addr} (x: !SDL_Surface_ref l):<> bool (l == null) = "atsctrb_SDL_ref_is_null" overload ref_is_null with SDL_Surface_ref_is_null fun SDL_Surface_ref_isnot_null {l:addr} (x: !SDL_Surface_ref l):<> bool (l > null) = "atsctrb_SDL_ref_isnot_null" overload ref_isnot_null with SDL_Surface_ref_isnot_null (* ****** ****** *) fun SDL_Surface_flags {l:agz} ( sf: !SDL_Surface_ref l ) : Uint32 = "mac#atsctrb_SDL_Surface_flags" // end of [fun] fun SDL_Surface_format {l:agz} ( sf: !SDL_Surface_ref l ) : [l_format:addr] ( minus (SDL_Surface_ref l, SDL_PixelFormat @ l_format) , SDL_PixelFormat @ l_format | ptr l_format ) = "mac#atsctrb_SDL_Surface_format" fun SDL_Surface_w {l:agz} (sf: !SDL_Surface_ref l): int = "mac#atsctrb_SDL_Surface_w" // end of [fun] fun SDL_Surface_h {l:agz} (sf: !SDL_Surface_ref l): int = "mac#atsctrb_SDL_Surface_h" // end of [fun] fun SDL_Surface_pitch {l:agz} (sf: !SDL_Surface_ref l): Uint16 = "mac#atsctrb_SDL_Surface_pitch" // end of [fun] fun SDL_Surface_clip_rect {l:agz} ( sf: !SDL_Surface_ref l ) : [l_rect:addr] ( minus (SDL_Surface_ref l, SDL_Rect @ l_rect) , SDL_Rect @ l_rect | ptr l_rect ) = "mac#atsctrb_SDL_Surface_clip_rect" fun SDL_Surface_refcount {l:agz} (sf: !SDL_Surface_ref l): int = "mac#atsctrb_SDL_Surface_refcount" // end of [fun] (* ****** ****** *) (* /** Available for SDL_CreateRGBSurface() or SDL_SetVideoMode() */ #define SDL_SWSURFACE 0x00000000 /**< Surface is in system memory */ #define SDL_HWSURFACE 0x00000001 /**< Surface is in video memory */ #define SDL_ASYNCBLIT 0x00000004 /**< Use asynchronous blits if possible */ *) macdef SDL_SWSURFACE = $extval (Uint32, "SDL_SWSURFACE") macdef SDL_HWSURFACE = $extval (Uint32, "SDL_HWSURFACE") macdef SDL_ASYNCBLIT = $extval (Uint32, "SDL_ASYNCBLIT") (* ****** ****** *) (* /** Available for SDL_SetVideoMode() */ #define SDL_ANYFORMAT 0x10000000 /**< Allow any video depth/pixel-format */ #define SDL_HWPALETTE 0x20000000 /**< Surface has exclusive palette */ #define SDL_DOUBLEBUF 0x40000000 /**< Set up double-buffered video mode */ #define SDL_FULLSCREEN 0x80000000 /**< Surface is a full screen display */ #define SDL_OPENGL 0x00000002 /**< Create an OpenGL rendering context */ #define SDL_OPENGLBLIT 0x0000000A /**< Create an OpenGL rendering context and use it for blitting */ #define SDL_RESIZABLE 0x00000010 /**< This video mode may be resized */ #define SDL_NOFRAME 0x00000020 /**< No window caption or edge frame */ *) macdef SDL_ANYFORMAT = $extval (Uint32, "SDL_ANYFORMAT") macdef SDL_HWPALETTE = $extval (Uint32, "SDL_HWPALETTE") macdef SDL_DOUBLEBUF = $extval (Uint32, "SDL_DOUBLEBUF") macdef SDL_FULLSCREEN = $extval (Uint32, "SDL_FULLSCREEN") macdef SDL_OPENGL = $extval (Uint32, "SDL_OPENGL") macdef SDL_OPENGLBLIT = $extval (Uint32, "SDL_OPENGLBLIT") macdef SDL_RESIZABLE = $extval (Uint32, "SDL_RESIZABLE") macdef SDL_NOFRAME = $extval (Uint32, "SDL_NOFRAME") (* /** Used internally (read-only) */ #define SDL_HWACCEL 0x00000100 /**< Blit uses hardware acceleration */ #define SDL_SRCCOLORKEY 0x00001000 /**< Blit uses a source color key */ #define SDL_RLEACCELOK 0x00002000 /**< Private flag */ #define SDL_RLEACCEL 0x00004000 /**< Surface is RLE encoded */ #define SDL_SRCALPHA 0x00010000 /**< Blit uses source alpha blending */ #define SDL_PREALLOC 0x01000000 /**< Surface uses preallocated memory */ *) macdef SDL_HWACCEL = $extval (Uint32, "SDL_HWACCEL") macdef SDL_SRCCOLORKEY = $extval (Uint32, "SDL_SRCCOLORKEY") macdef SDL_RLEACCELOK = $extval (Uint32, "SDL_RLEACCELOK") macdef SDL_RLEACCEL = $extval (Uint32, "SDL_RLEACCEL") macdef SDL_SRCALPHA = $extval (Uint32, "SDL_SRCALPHA") macdef SDL_PREALLOC = $extval (Uint32, "SDL_PREALLOC") (* ****** ****** *) abst@ype SDL_GLattr = $extype"SDL_GLattr" macdef SDL_GL_RED_SIZE = $extval (SDL_GLattr, "SDL_GL_RED_SIZE") macdef SDL_GL_GREEN_SIZE = $extval (SDL_GLattr, "SDL_GL_GREEN_SIZE") macdef SDL_GL_BLUE_SIZE = $extval (SDL_GLattr, "SDL_GL_BLUE_SIZE") macdef SDL_GL_ALPHA_SIZE = $extval (SDL_GLattr, "SDL_GL_ALPHA_SIZE") macdef SDL_GL_BUFFER_SIZE = $extval (SDL_GLattr, "SDL_GL_BUFFER_SIZE") macdef SDL_GL_DOUBLEBUFFER = $extval (SDL_GLattr, "SDL_GL_DOUBLEBUFFER") macdef SDL_GL_DEPTH_SIZE = $extval (SDL_GLattr, "SDL_GL_DEPTH_SIZE") macdef SDL_GL_STENCIL_SIZE = $extval (SDL_GLattr, "SDL_GL_STENCIL_SIZE") macdef SDL_GL_ACCUM_RED_SIZE = $extval (SDL_GLattr, "SDL_GL_ACCUM_RED_SIZE") macdef SDL_GL_ACCUM_GREEN_SIZE = $extval (SDL_GLattr, "SDL_GL_ACCUM_GREEN_SIZE") macdef SDL_GL_ACCUM_BLUE_SIZE = $extval (SDL_GLattr, "SDL_GL_ACCUM_BLUE_SIZE") macdef SDL_GL_ACCUM_ALPHA_SIZE = $extval (SDL_GLattr, "SDL_GL_ACCUM_ALPHA_SIZE") macdef SDL_GL_STEREO = $extval (SDL_GLattr, "SDL_GL_STEREO") macdef SDL_GL_MULTISAMPLEBUFFERS = $extval (SDL_GLattr, "SDL_GL_MULTISAMPLEBUFFERS") macdef SDL_GL_MULTISAMPLESAMPLES = $extval (SDL_GLattr, "SDL_GL_MULTISAMPLESAMPLES") macdef SDL_GL_ACCELERATED_VISUAL = $extval (SDL_GLattr, "SDL_GL_ACCELERATED_VISUAL") macdef SDL_GL_SWAP_CONTROL = $extval (SDL_GLattr, "SDL_GL_SWAP_CONTROL") (* ****** ****** *) absview Video_v (l:addr) praxi Video_v_unnull (pf: Video_v null): void fun SDL_SetVideoMode ( width: int , height: int , bpp: int , flags: Uint32 ) : [l:agez] (Video_v l | SDL_Surface_ref l) = "mac#atsctrb_SDL_SetVideoMode" // end of [fun] fun SDL_SetVideoMode_exn ( width: int , height: int , bpp: int , flags: Uint32 ) : [l:agz] ( Video_v l | SDL_Surface_ref l ) // end of [fun] fun SDL_ResetVideoMode {l:addr} ( pf: Video_v l | surf: SDL_Surface_ref l , width: int , height: int , bpp: int , flags: Uint32 ) : [l:agez] (Video_v l | SDL_Surface_ref l) = "atsctrb_SDL_ResetVideoMode" // end of [fun] (* ****** ****** *) // // HX: note: x=y=w=h=0 means the whole screen! // fun SDL_UpdateRect {l:agz} ( screen: !SDL_Surface_ref l, x: Sint32, y: Sint32, w: Uint32, h: Uint32 ) : void = "mac#atsctrb_SDL_UpdateRect" // end of [fun] fun SDL_UpdateRects {l:agz} {n:nat} ( screen: !SDL_Surface_ref l, n: int n, rects: &(@[SDL_Rect][n]) ) : void = "mac#atsctrb_SDL_UpdateRects" // end of [fun] (* ****** ****** *) fun SDL_Flip {l:agz} ( screen: !SDL_Surface_ref l ) : int (*err*) = "mac#atsctrb_SDL_Flip" // end of [fun] (* ****** ****** *) fun SDL_SetGamma ( red: float, green: float, blue: float ) : int (*err*) = "atsctrb_SDL_SetGamma" // end of [fun] (* ****** ****** *) fun SDL_GetGammaRamp ( red: &(@[Uint16?][256]) >> @[Uint16?][256] , green: &(@[Uint16?][256]) >> @[Uint16?][256] , blue: &(@[Uint16?][256]) >> @[Uint16?][256] ) : int (*err*) = "atsctrb_SDL_GetGammaRamp" // end of [fun] fun SDL_SetGammaRamp ( red: &(@[Uint16][256]), green: &(@[Uint16][256]), blue: &(@[Uint16][256]) ) : int (*err*) = "atsctrb_SDL_SetGammaRamp" // end of [fun] (* ****** ****** *) fun SDL_MapRGB ( format: &SDL_PixelFormat, r: Uint8, g: Uint8, b: Uint8 ) : Uint32 = "mac#atsctrb_SDL_MapRGB" // end of [fun] fun SDL_MapRGBA ( format: &SDL_PixelFormat, r: Uint8, g: Uint8, b: Uint8, a: Uint8 ) : Uint32 = "mac#atsctrb_SDL_MapRGBA" // end of [fun] (* ****** ****** *) fun SDL_CreateRGBSurface ( flags: Uint32 , width: int, height: int, depth: int , Rmask: Uint32, Gmask: Uint32, Bmask: Uint32, Amask: Uint32 ) : SDL_Surface_ref0 = "mac#atsctrb_SDL_CreateRGBSurface" // end of [fun] fun SDL_CreateRGBSurfaceFrom ( data: ptr // this is unsafe , width: int, height: int, depth: int, pitch: int , Rmask: Uint32, Gmask: Uint32, Bmask: Uint32, Amask: Uint32 ) : SDL_Surface_ref0 = "mac#atsctrb_SDL_CreateRGBSurfaceFrom" // end of [fun] fun SDL_FreeSurface (surface: SDL_Surface_ref1): void = "mac#atsctrb_SDL_FreeSurface" // end of [SDL_FreeSurface] (* ****** ****** *) absview SDL_Surface_v (l:addr) fun SDL_LockSurface {l:agz} ( surface: !SDL_Surface_ref l ) : [i:int | i <= 0] (option_v (SDL_Surface_v l, i==0) | int i) = "atsctrb_SDL_LockSurface" // end of [fun] fun SDL_LockSurface_exn {l:agz} ( surface: !SDL_Surface_ref l ) : (SDL_Surface_v l | void) = "atsctrb_SDL_LockSurface_exn" // end of [fun] fun SDL_UnlockSurface {l:agz} ( pf: SDL_Surface_v l | surface: !SDL_Surface_ref l ) : int = "atsctrb_SDL_UnlockSurface" // end of [fun] (* ****** ****** *) fun SDL_LoadBMP (filename: string) : SDL_Surface_ref0 = "mac#atsctrb_SDL_LoadBMP" // end of [SDL_LoadBMP] fun SDL_LoadBMP_exn (filename: string): SDL_Surface_ref1 (* ****** ****** *) fun SDL_SetColorKey {l:agz} ( surface: !SDL_Surface_ref l, flag: Uint32, key: Uint32 ) : int (*err*) = "mac#atsctrb_SDL_SetColorKey" fun SDL_SetAlpha {l:agz} ( surface: !SDL_Surface_ref l, flag: Uint32, alpha: Uint8 ) : int (*err*) = "mac#atsctrb_SDL_SetAlpha" (* ****** ****** *) fun SDL_GetClipRect {l:agz} ( surface: !SDL_Surface_ref l, rect: &SDL_Rect? >> SDL_Rect ) : void = "mac#atsctrb_SDL_GetClipRect" // end of [fun] fun SDL_SetClipRect {l:agz} (surface: !SDL_Surface_ref l, rect: &SDL_Rect): int(*SDL_TRUE/SDL_FALSE*) = "mac#atsctrb_SDL_SetClipRect" // end of [fun] (* ****** ****** *) fun SDL_UpperBlit {l1,l2:agz} ( src: !SDL_Surface_ref l1, srcrect: &SDL_Rect , dst: !SDL_Surface_ref l2, dstrect: &SDL_Rect ) : int (*err*) = "mac#atsctrb_SDL_UpperBlit" // end of [fun] fun SDL_UpperBlit_ptr {l1,l2:agz} ( src: !SDL_Surface_ref l1, srcrect: ptr, dst: !SDL_Surface_ref l2, dstrect: ptr ) : int (*err*) = "mac#atsctrb_SDL_UpperBlit" // end of [fun] (* ****** ****** *) fun SDL_FillRect {l:agz} ( dst: !SDL_Surface_ref l, dstrect: &SDL_Rect, color: Uint32 ) : int (*err*) = "mac#atsctrb_SDL_FillRect" // end of [fun] fun SDL_FillRect_ptr {l:agz} ( // use only if dstrect=NULL dst: !SDL_Surface_ref l, dstrect: ptr, color: Uint32 ) : int (*err*) = "mac#atsctrb_SDL_FillRect" // end of [fun] (* ****** ****** *) fun SDL_DisplayFormat {l:agz} ( surface: !SDL_Surface_ref l ) : SDL_Surface_ref0 = "mac#atsctrb_SDL_DisplayFormat" // end of [fun] fun SDL_DisplayFormatAlpha {l:agz} ( surface: !SDL_Surface_ref l ) : SDL_Surface_ref0 = "mac#atsctrb_SDL_DisplayFormatAlpha" // end of [fun] (* ****** ****** *) fun SDL_WM_GetCaption ( title: &Stropt? >> Stropt, icon: &Stropt? >> Stropt ) : void = "mac#atsctrb_SDL_WM_GetCaption" // end of [fun] (* ** HX: the passed string can be freed after the call *) fun SDL_WM_SetCaption ( title: Stropt, icon: Stropt ) : void = "mac#atsctrb_SDL_WM_SetCaption" // end of [fun] (* ****** ****** *) fun SDL_GL_SwapBuffers (): void = "mac#atsctrb_SDL_GL_SwapBuffers" (* ****** ****** *) (* end of [SDL_video.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/SATS/SDL_mixer.sats0000664000175000017500000001563312223166165021366 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: March, 2010 // (* ****** ****** *) %{# #include "contrib/SDL/CATS/SDL_mixer.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for static loading at run-time (* ****** ****** *) staload "contrib/SDL/SATS/SDL.sats" (* ****** ****** *) macdef MIX_DEFAULT_FORMAT = $extval (Uint16, "MIX_DEFAULT_FORMAT") macdef MIX_DEFAULT_FREQUENCY = $extval (int, "MIX_DEFAULT_FREQUENCY") macdef MIX_DEFAULT_CHANNELS = $extval (int, "MIX_DEFAULT_CHANNELS") macdef MIX_MAX_VOLUME = $extval (int, "MIX_MAX_VOLUME") (* ****** ****** *) abst@ype Mix_Fading = $extype"Mix_Fading" macdef MIX_NO_FADING = $extval (Mix_Fading, "MIX_NO_FADING") macdef MIX_FADING_OUT = $extval (Mix_Fading, "MIX_FADING_OUT") macdef MIX_FADING_IN = $extval (Mix_Fading, "MIX_FADING_IN") abst@ype Mix_MusicType = $extype"Mix_MusicType" macdef MUS_NONE = $extval (Mix_MusicType, "MUS_NONE") macdef MUS_CMD = $extval (Mix_MusicType, "MUS_CMD") macdef MUS_WAV = $extval (Mix_MusicType, "MUS_WAV") macdef MUS_MOD = $extval (Mix_MusicType, "MUS_MOD") macdef MUS_MID = $extval (Mix_MusicType, "MUS_MID") macdef MUS_OGG = $extval (Mix_MusicType, "MUS_OGG") macdef MUS_MP3 = $extval (Mix_MusicType, "MUS_MP3") (* ****** ****** *) (* viewtypedef Mix_Chunk = $extype_struct "Mix_Chunk" of { allocated= int , abuf= ptr // Uint8* // this needs to be taken care of at some point , alen= Uint32 , volume= Uint8 // Per-sample volume, 0-128 } // end of [Mix_Chunk] *) // // this type is not refcounted: // absviewtype Mix_Chunk_ref (l:addr) // = Mix_Chunk* viewtypedef Mix_Chunk_ref0 = [l:agez] Mix_Chunk_ref (l) viewtypedef Mix_Chunk_ref1 = [l:addr | l > null] Mix_Chunk_ref (l) fun Mix_Chunk_ref_is_null {l:addr} (x: !Mix_Chunk_ref l):<> bool (l == null) = "atsctrb_SDL_ref_is_null" // overload ref_is_null with Mix_Chunk_ref_is_null fun Mix_Chunk_ref_isnot_null {l:addr} (x: !Mix_Chunk_ref l):<> bool (l <> null) = "atsctrb_SDL_ref_isnot_null" // overload ref_isnot_null with Mix_Chunk_ref_isnot_null (* ****** ****** *) // // HX: is this type refcounted? // absviewtype Mix_Music_ref (l:addr) // = Mix_Music* viewtypedef Mix_Music_ref0 = [l:agez] Mix_Music_ref (l) viewtypedef Mix_Music_ref1 = [l:addr | l > null] Mix_Music_ref (l) fun Mix_Music_ref_is_null {l:addr} (x: !Mix_Music_ref l):<> bool (l == null) = "atsctrb_SDL_ref_is_null" // overload ref_is_null with Mix_Music_ref_is_null fun Mix_Music_ref_isnot_null {l:addr} (x: !Mix_Music_ref l):<> bool (l <> null) = "atsctrb_SDL_ref_isnot_null" // overload ref_isnot_null with Mix_Music_ref_isnot_null (* ****** ****** *) fun Mix_OpenAudio ( frequency: int, format: Uint16, channels: int, chunksize: int ) : int(*err*) = "mac#atsctrb_Mix_OpenAudio" // end of [Mix_OpenAudio] (* ****** ****** *) fun Mix_AllocateChannels (numchans: int): int = "mac#atsctrb_Mix_AllocateChannels" // end of [Mix_AllocateChannels] (* ****** ****** *) fun Mix_QuerySpec ( frequency: &int? >> opt (int, i > 0) , format: &Uint16? >> opt (Uint16, i > 0) , channels: &int? >> opt (int, i > 0) ) : #[i:two] int i = "mac#atsctrb_Mix_QuerySpec" (* ****** ****** *) (* /* Load a wave file or a music (.mod .s3m .it .xm) file */ extern DECLSPEC Mix_Chunk * SDLCALL Mix_LoadWAV_RW(SDL_RWops *src, int freesrc); #define Mix_LoadWAV(file) Mix_LoadWAV_RW(SDL_RWFromFile(file, "rb"), 1) extern DECLSPEC Mix_Music * SDLCALL Mix_LoadMUS(const char *file); *) fun Mix_LoadWAV (file: string): Mix_Chunk_ref0 = "mac#atsctrb_Mix_LoadWAV" fun Mix_LoadMUS (file: string): Mix_Music_ref0 = "mac#atsctrb_Mix_LoadMUS" (* ****** ****** *) fun Mix_FreeChunk {l:agz} (chunk: Mix_Chunk_ref l): void = "mac#atsctrb_Mix_FreeChunk" // end of [Mix_FreeChunk] fun Mix_FreeMusic {l:agz} (music: Mix_Music_ref l): void = "mac#atsctrb_Mix_FreeMusic" // end of [Mix_FreeMusic] (* ****** ****** *) (* #define Mix_PlayChannel(channel,chunk,loops) Mix_PlayChannelTimed(channel,chunk,loops,-1) extern DECLSPEC int SDLCALL Mix_PlayChannelTimed(int channel, Mix_Chunk *chunk, int loops, int ticks); extern DECLSPEC int SDLCALL Mix_PlayMusic(Mix_Music *music, int loops); *) fun Mix_PlayChannel {l:agz} (channel: int, chunk: !Mix_Chunk_ref l, loops: int): int = "mac#atsctrb_Mix_PlayChannel" // end of [Mix_PlayChannel] fun Mix_PlayChannelTimed {l:agz} ( channel: int, chunk: !Mix_Chunk_ref l, loops: int, ticks: int ) : int = "mac#atsctrb_Mix_PlayChannelTimed" // end of [Mix_PlayChannelTimed] fun Mix_PlayMusic {l:agz} ( music: !Mix_Music_ref l, loops: int ) : int = "mac#atsctrb_Mix_PlayMusic" // end of [Mix_PlayMusic] fun Mix_HaltChannel (channel: int): int = "mac#atsctrb_Mix_HaltChannel" fun Mix_HaltGroup (tag: int): int = "mac#atsctrb_Mix_HaltGroup" fun Mix_HaltMusic (): int = "mac#atsctrb_Mix_HaltMusic" (* /* Pause/Resume the music stream */ extern DECLSPEC void SDLCALL Mix_PauseMusic(void); extern DECLSPEC void SDLCALL Mix_ResumeMusic(void); extern DECLSPEC void SDLCALL Mix_RewindMusic(void); extern DECLSPEC int SDLCALL Mix_PausedMusic(void); *) fun Mix_PauseMusic (): void = "mac#atsctrb_Mix_PauseMusic" fun Mix_ResumeMusic (): void = "mac#atsctrb_Mix_ResumeMusic" fun Mix_RewindMusic (): void = "mac#atsctrb_Mix_RewindMusic" fun Mix_PausedMusic (): int = "mac#atsctrb_Mix_PausedMusic" (* extern DECLSPEC int SDLCALL Mix_Playing(int channel); extern DECLSPEC int SDLCALL Mix_PlayingMusic(void); *) fun Mix_Playing (channel: int): int = "mac#atsctrb_Mix_Playing" // end of [Mix_Playing] fun Mix_PlayingMusic (): int = "mac#atsctrb_Mix_PlayingMusic" (* ****** ****** *) (* end of [SDL_mixer.sats] *) ats-lang-anairiats-0.2.11/contrib/SDL/Makefile0000664000175000017500000000205512223166165017524 0ustar hwxihwxi# # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: January, 2010 # ###### ATSHOMEQ="$(ATSHOME)" ATSCC=$(ATSHOMEQ)/bin/atscc -Wall SDLCFLAGS=`sdl-config --cflags` ###### all:: atsctrb_SDL.o all:: clean ###### OBJECTS := \ SDL_sats.o \ SDL_dats.o \ SDL_image_sats.o \ SDL_ttf_sats.o \ ###### atsctrb_SDL.o: $(OBJECTS) ; ld -r -o $@ $(OBJECTS) ###### SDL_sats.o: \ SATS/SDL.sats \ SATS/SDL_thread.sats \ SATS/SDL_timer.sats \ SATS/SDL_video.sats $(ATSCC) $(SDLCFLAGS) -o $@ -c SATS/SDL.sats SDL_dats.o: DATS/SDL.dats $(ATSCC) $(SDLCFLAGS) -o $@ -c DATS/SDL.dats ###### SDL_image_sats.o: SATS/SDL_image.sats $(ATSCC) $(SDLCFLAGS) -o $@ -c SATS/SDL_image.sats ###### SDL_ttf_sats.o: SATS/SDL_ttf.sats $(ATSCC) $(SDLCFLAGS) -o $@ -c SATS/SDL_ttf.sats ###### RMF=rm -f ###### clean:: ; $(RMF) SDL_sats.c SDL_sats.o clean:: ; $(RMF) SDL_dats.c SDL_dats.o clean:: ; $(RMF) SDL_image_sats.c SDL_image_sats.o clean:: ; $(RMF) SDL_ttf_sats.c SDL_ttf_sats.o cleanall: clean ; $(RMF) atsctrb_SDL.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/SDL/DATS/0000700000175000017500000000000012223166165016601 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/SDL/DATS/SDL.dats0000664000175000017500000000473612223166165020126 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 // (* ****** ****** *) // // API for SDL in ATS // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "contrib/SDL/SATS/SDL.sats" (* ****** ****** *) implement SDL_SetVideoMode_exn (width, height, bpp, flags) = let val (pf | sf) = SDL_SetVideoMode (width, height, bpp, flags) in if ref_is_null (sf) then let prval () = Video_v_unnull (pf) val _null = ref_free_null (sf) val () = prerr ("exit(ATS/SDL): [SDL_SetVideoMode] failed.\n") in exit (1) end else (pf | sf) // end of [if] end // end of [SDL_SetVideoMode_exn] (* ****** ****** *) implement SDL_LoadBMP_exn (filename) = let val sf = SDL_LoadBMP (filename) // [sfopt] may be null in if ref_is_null (sf) then let val _null = ref_free_null sf val () = prerrf ( "exit(ATS/SDL): [SDL_LoadBMP(%s)] failed.\n", @(filename) ) // end of [val] in exit (1) end else sf // end of [if] end // end of [SDL_LoadBMP_exn] (* ****** ****** *) (* end of [SDL.dats] *) ats-lang-anairiats-0.2.11/contrib/glib/0000700000175000017500000000000012223166165016341 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/CATS/0000700000175000017500000000000012223166165017073 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/0000700000175000017500000000000012223166165020010 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gqsort.cats0000664000175000017500000000375512223166165022231 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GQSORT_CATS #define ATSCTRB_GLIB_GQSORT_CATS /* ****** ****** */ /* #include "glib/gqsort.h" */ /* ****** ****** */ static inline ats_void_type atsctrb_g_qsort_with_data ( ats_ref_type pbase , gint n , ats_size_type size , ats_fun_ptr_type compare_func , ats_ptr_type env ) { g_qsort_with_data ( (gconstpointer)pbase , (gint)n , (gsize)size , (GCompareDataFunc)compare_func , (gpointer)env ) ; return ; } // end of [atsctrb_g_qsort_with_data] /* ****** ****** */ #endif /* ATSCTRB_GLIB_GQSORT_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gmem.cats0000664000175000017500000000325212223166165021627 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GMEM_CATS #define ATSCTRB_GLIB_GMEM_CATS /* ****** ****** */ /* #include "glib/gmem.h" */ /* ****** ****** */ #define atsctrb_g_free g_free /* ****** ****** */ #endif /* ATSCTRB_GLIB_GMEM_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gutils.cats0000664000175000017500000000327212223166165022213 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GUTILS_CATS #define ATSCTRB_GLIB_GUTILS_CATS /* ****** ****** */ /* #include "glib/gutils.h" */ /* ****** ****** */ #define atsctrb_g_snprintf g_snprintf /* ****** ****** */ #endif /* ATSCTRB_GLIB_GUTILS_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/ghash.cats0000664000175000017500000000400012223166165021764 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GHASH_CATS #define ATSCTRB_GLIB_GHASH_CATS /* ****** ****** */ /* #include "glib/ghash.h" */ /* ****** ****** */ typedef GHashTable *GHashTable_ref ; /* ****** ****** */ #define atsctrb_g_hash_table_new g_hash_table_new #define atsctrb_g_hash_table_destroy g_hash_table_destroy #define atsctrb_g_hash_table_size g_hash_table_size #define atsctrb_g_hash_table_insert g_hash_table_insert #define atsctrb_g_hash_table_lookup hash_table_lookup #define atsctrb_g_str_hash g_str_hash /* ****** ****** */ #endif /* ATSCTRB_GLIB_GHASH_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/garray.cats0000664000175000017500000000516612223166165022175 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GARRAY_CATS #define ATSCTRB_GLIB_GARRAY_CATS /* ****** ****** */ /* #include "glib/garray.h" */ /* ****** ****** */ typedef GArray *GArray_ref ; /* ****** ****** */ #define atsctrb_g_array_new g_array_new #define atsctrb_g_array_sized_new g_array_sized_new #define atsctrb_g_array_ref g_array_ref #define atsctrb_g_array_unref g_array_unref /* ****** ****** */ #define atsctrb_g_array_set_size g_array_set_size /* ****** ****** */ ATSinline() ats_void_type atsctrb_g_array_free_true ( ats_ptr_type array ) { g_array_free ((GArray*)array, TRUE) ; return ; } // end of [atsctrb_g_array_free_true] /* ****** ****** */ #define atsctrb_g_array_append_val(array, v) \ g_array_append_val ((GArray*)(array), *(v)) #define atsctrb_g_array_prepend_val(array, v) \ g_array_prepend_val ((GArray*)(array), *(v)) /* ****** ****** */ #define atsctrb_g_array_sort g_array_sort /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_g_array_takeout_tsz ( ats_ptr_type array, gint i, ats_size_type tsz ) { return (&g_array_index((GArray*)array, char, 0)) + i * tsz ; } // end of [atsctrb_g_array_takeout] /* ****** ****** */ #endif /* ATSCTRB_GLIB_GARRAY_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gbasics.cats0000664000175000017500000001604312223166165022317 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GBASICS_CATS #define ATSCTRB_GLIB_GBASICS_CATS /* ****** ****** */ /* #include "glib/gtypes.h" */ /* ****** ****** */ ATSinline() gint atsctrb_add_gint_gint (gint x, gint y) { return (x + y) ; } ATSinline() gint atsctrb_sub_gint_gint (gint x, gint y) { return (x - y) ; } ATSinline() gint atsctrb_mul_gint_gint (gint x, gint y) { return (x * y) ; } ATSinline() gint atsctrb_div_gint_gint (gint x, gint y) { return (x / y) ; } /* ****** ****** */ ATSinline() ats_bool_type atsctrb_lt_gint_gint (gint x, gint y) { return (x < y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lt_gint_gint] ATSinline() ats_bool_type atsctrb_lte_gint_gint (gint x, gint y) { return (x <= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lte_gint_gint] ATSinline() ats_bool_type atsctrb_gt_gint_gint (gint x, gint y) { return (x > y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gt_gint_gint] ATSinline() ats_bool_type atsctrb_gte_gint_gint (gint x, gint y) { return (x >= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gte_gint_gint] ATSinline() ats_bool_type atsctrb_eq_gint_gint (gint x, gint y) { return (x == y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_gint_gint] ATSinline() ats_bool_type atsctrb_neq_gint_gint (gint x, gint y) { return (x != y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_neq_gint_gint] /* ****** ****** */ ATSinline() guint atsctrb_add_guint_guint (guint x, guint y) { return (x + y) ; } ATSinline() guint atsctrb_sub_guint_guint (guint x, guint y) { return (x - y) ; } ATSinline() guint atsctrb_mul_guint_guint (guint x, guint y) { return (x * y) ; } ATSinline() guint atsctrb_div_guint_guint (guint x, guint y) { return (x / y) ; } /* ****** ****** */ ATSinline() ats_bool_type atsctrb_lt_guint_guint (guint x, guint y) { return (x < y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lt_guint_guint] ATSinline() ats_bool_type atsctrb_lte_guint_guint (guint x, guint y) { return (x <= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lte_guint_guint] ATSinline() ats_bool_type atsctrb_gt_guint_guint (guint x, guint y) { return (x > y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gt_guint_guint] ATSinline() ats_bool_type atsctrb_gte_guint_guint (guint x, guint y) { return (x >= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gte_guint_guint] ATSinline() ats_bool_type atsctrb_eq_guint_guint (guint x, guint y) { return (x == y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_guint_guint] ATSinline() ats_bool_type atsctrb_neq_guint_guint (guint x, guint y) { return (x != y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_neq_guint_guint] /* ****** ****** */ ATSinline() ats_bool_type atsctrb_lt_gint32_gint32 (gint32 x, gint32 y) { return (x < y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lt_gint32_gint32] ATSinline() ats_bool_type atsctrb_lte_gint32_gint32 (gint32 x, gint32 y) { return (x <= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lte_gint32_gint32] ATSinline() ats_bool_type atsctrb_gt_gint32_gint32 (gint32 x, gint32 y) { return (x > y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gt_gint32_gint32] ATSinline() ats_bool_type atsctrb_gte_gint32_gint32 (gint32 x, gint32 y) { return (x >= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gte_gint32_gint32] ATSinline() ats_bool_type atsctrb_eq_gint32_gint32 (gint32 x, gint32 y) { return (x == y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_gint32_gint32] ATSinline() ats_bool_type atsctrb_neq_gint32_gint32 (gint32 x, gint32 y) { return (x != y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_neq_gint32_gint32] /* ****** ****** */ ATSinline() ats_bool_type atsctrb_lt_guint32_guint32 (guint32 x, guint32 y) { return (x < y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lt_guint32_guint32] ATSinline() ats_bool_type atsctrb_lte_guint32_guint32 (guint32 x, guint32 y) { return (x <= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_lte_guint32_guint32] ATSinline() ats_bool_type atsctrb_gt_guint32_guint32 (guint32 x, guint32 y) { return (x > y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gt_guint32_guint32] ATSinline() ats_bool_type atsctrb_gte_guint32_guint32 (guint32 x, guint32 y) { return (x >= y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_gte_guint32_guint32] ATSinline() ats_bool_type atsctrb_eq_guint32_guint32 (guint32 x, guint32 y) { return (x == y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_guint32_guint32] ATSinline() ats_bool_type atsctrb_neq_guint32_guint32 (guint32 x, guint32 y) { return (x != y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_neq_guint32_guint32] /* ****** ****** */ #define atsctrb_GPOINTER_TO_INT GPOINTER_TO_INT #define atsctrb_GINT_TO_POINTER GINT_TO_POINTER /* ****** ****** */ // // HX-2010-05-19: // this one is implemented in $ATSHOME/prelude/CATS/string.cats // extern ats_int_type atspre_compare_string_string (ats_ptr_type x1, ats_ptr_type x2) ; // end of [atspre_compare_string_string] #define atsctrb_compare_gstring_gstring \ atspre_compare_string_string ATSinline () ats_int_type atsctrb_compare_gstring0_gstring0 (ats_ptr_type x1, ats_ptr_type x2) { if (!x1) { if (!x2) return ats_true_bool ; else return ats_false_bool ; } // end of [if] if (!x2) return ats_false_bool ; // x1 != NULL return atspre_compare_string_string (x1, x2) ; } // end of [atsctrb_compare_gstring0_gstring0] /* ****** ****** */ #endif /* ATSCTRB_GLIB_GBASICS_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/glist.cats0000664000175000017500000000705112223166165022025 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GLIST_CATS #define ATSCTRB_GLIB_GLIST_CATS /* ****** ****** */ typedef GList *GList_ptr ; /* ****** ****** */ ATSinline() ats_bool_type atsctrb_g_list_is_nil (ats_ptr_type list) { return (list == (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_g_list_is_nil] ATSinline() ats_bool_type atsctrb_g_list_isnot_nil (ats_ptr_type list) { return (list != (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_g_list_isnot_nil] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_g_list_new_nil () { return (GList_ptr)0 ; } ATSinline() ats_void_type atsctrb_g_list_free_nil (ats_ptr_type xs) { return ; } /* ****** ****** */ #define atsctrb_g_list_free g_list_free #define atsctrb_g_list_free1 g_list_free1 #define atsctrb_g_list_next g_list_next #define atsctrb_g_list_previous g_list_previous #define atsctrb_g_list_last g_list_last #define atsctrb_g_list_first g_list_first #define atsctrb_g_list_append g_list_append #define atsctrb_g_list_prepend g_list_prepend #define atsctrb_g_list_length g_list_length /* ****** ****** */ #define atsctrb_g_list_insert g_list_insert ATSinline() ats_ptr_type atsctrb_g_list_insert_sorted ( ats_ptr_type list, ats_ptr_type x, ats_fun_ptr_type cmp ) { return g_list_insert_sorted ((GList_ptr)list, (gpointer)x, (GCompareFunc)cmp) ; } // end of [atsctrb_g_list_insert_sorted] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_g_list_remove_current ( ats_ptr_type list, ats_ref_type node ) { *(GList_ptr*)node = (GList_ptr)list ; return g_list_remove_link (list, list) ; } // end of [atsctrb_g_list_remove_current] /* ****** ****** */ #define atsctrb_g_list_concat g_list_concat #define atsctrb_g_list_copy g_list_copy #define atsctrb_g_list_reverse g_list_reverse #define atsctrb_g_list_sort g_list_sort #define atsctrb_g_list_sort_with_data g_list_sort_with_data #define atsctrb_g_list_foreach g_list_foreach #define atsctrb_g_list_nth g_list_nth #define atsctrb_g_list_nth_data g_list_nth_data #define atsctrb_g_list_index g_list_index /* ****** ****** */ #endif /* ATSCTRB_GLIB_GLIST_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gstring.cats0000664000175000017500000000702612223166165022362 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GSTRING_CATS #define ATSCTRB_GLIB_GSTRING_CATS /* ****** ****** */ /* #include "glib/gstring.h" */ /* ****** ****** */ typedef GString *GString_ptr ; /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_g_string_get_str (ats_ptr_type string) { return ((GString*)string)->str ; } // end of [atsctrb_g_string_get_str] ATSinline() gsize atsctrb_g_string_get_len (ats_ptr_type string) { return ((GString*)string)->len ; } // end of [atsctrb_g_string_get_len] ATSinline() gsize atsctrb_g_string_get_allocated_len (ats_ptr_type string) { return ((GString*)string)->allocated_len ; } // end of [atsctrb_g_string_get_allocated_len] /* ****** ****** */ #define atsctrb_g_string_new_null() g_string_new ((char*)0) #define atsctrb_g_string_new_init(init) g_string_new (init) /* ****** ****** */ #define atsctrb_g_string_printf g_string_printf #define atsctrb_g_string_append_printf g_string_append_printf /* ****** ****** */ #define atsctrb_g_string_assign g_string_assign /* ****** ****** */ #define atsctrb_g_string_append g_string_append #define atsctrb_g_string_append_c g_string_append_c #define atsctrb_g_string_append_len g_string_append_len /* ****** ****** */ #define atsctrb_g_string_prepend g_string_prepend #define atsctrb_g_string_prepend_c g_string_prepend_c #define atsctrb_g_string_prepend_len g_string_prepend_len /* ****** ****** */ #define atsctrb_g_string_insert g_string_insert #define atsctrb_g_string_insert_c g_string_insert_c #define atsctrb_g_string_insert_len g_string_insert_len /* ****** ****** */ #define atsctrb_g_string_overwrite g_string_overwrite #define atsctrb_g_string_overwrite_len g_string_overwrite_len /* ****** ****** */ #define atsctrb_g_string_erase g_string_erase #define atsctrb_g_string_truncate g_string_truncate #define atsctrb_g_string_set_size g_string_set_size /* ****** ****** */ #define atsctrb_g_string_free_true(x) g_string_free(x, TRUE) /* ****** ****** */ #define atsctrb_g_string_hash g_new_string_hash #define atsctrb_g_string_equal g_new_string_equal /* ****** ****** */ #endif /* ATSCTRB_GLIB_GSTRING_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/grand.cats0000664000175000017500000000513112223166165021773 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GRAND_CATS #define ATSCTRB_GLIB_GRAND_CATS /* ****** ****** */ /* #include "glib/grand.h" */ /* ****** ****** */ typedef GRand *GRand_ptr ; /* ****** ****** */ #define atsctrb_g_rand_new_with_seed g_rand_new_with_seed #define atsctrb_g_rand_new_with_seed_array g_rand_new_with_seed_array #define atsctrb_g_rand_new g_rand_new #define atsctrb_g_rand_copy g_rand_copy #define atsctrb_g_rand_free g_rand_free #define atsctrb_g_rand_set_seed g_rand_set_seed #define atsctrb_g_rand_set_seed_array g_rand_set_seed_array #define atsctrb_g_rand_boolean g_rand_boolean #define atsctrb_g_rand_int g_rand_int #define atsctrb_g_rand_int_range g_rand_int_range #define atsctrb_g_rand_double g_rand_double #define atsctrb_g_rand_double_range g_rand_double_range /* ****** ****** */ #define atsctrb_g_random_set_seed g_random_set_seed #define atsctrb_g_random_boolean g_random_boolean #define atsctrb_g_random_int g_random_int #define atsctrb_g_random_int_range g_random_int_range #define atsctrb_g_random_double g_random_double #define atsctrb_g_random_double_range g_random_double_range /* ****** ****** */ #endif /* ATSCTRB_GLIB_GRAND_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gunicode.cats0000664000175000017500000000537712223166165022511 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GUNICODE_CATS #define ATSCTRB_GLIB_GUNICODE_CATS /* ****** ****** */ /* #include "glib/gunicode.h" */ /* ****** ****** */ #define atsctrb_g_unichar_isalnum g_unichar_isalnum #define atsctrb_g_unichar_isalpha g_unichar_isalpha #define atsctrb_g_unichar_iscntrl g_unichar_iscntrl #define atsctrb_g_unichar_isdigit g_unichar_isdigit #define atsctrb_g_unichar_isgraph g_unichar_isgraph #define atsctrb_g_unichar_islower g_unichar_islower #define atsctrb_g_unichar_isprint g_unichar_isprint #define atsctrb_g_unichar_ispunct g_unichar_ispunct #define atsctrb_g_unichar_isspace g_unichar_isspace #define atsctrb_g_unichar_isupper g_unichar_isupper #define atsctrb_g_unichar_isxdigit g_unichar_isxdigit #define atsctrb_g_unichar_istitle g_unichar_istitle #define atsctrb_g_unichar_isdefined g_unichar_isdefined #define atsctrb_g_unichar_iswide g_unichar_iswide #define atsctrb_g_unichar_iswide_cjk g_unichar_iswide_cjk #define atsctrb_g_unichar_iszerowidth g_unichar_iszerowidth #define atsctrb_g_unichar_ismark g_unichar_ismark /* ****** ****** */ ATSinline() glong atsctrb_g_utf8_strlen_cstr (ats_ptr_type str) { return g_utf8_strlen ((gchar*)str, -1) ; } // end of [atsctrb_g_utf8_strlen_cstr] #define atsctrb_g_utf8_strlen_carr g_utf8_strlen /* ****** ****** */ #endif /* ATSCTRB_GLIB_GUNICODE_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib/gslist.cats0000664000175000017500000000346412223166165022214 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_GSLIST_CATS #define ATSCTRB_GLIB_GSLIST_CATS /* ****** ****** */ typedef GSList *GSList_ptr ; /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_g_slist_new_nil () { return (GSList_ptr)0 ; } ATSinline() ats_void_type atsctrb_g_slist_free_nil (ats_ptr_type xs) { return ; } /* ****** ****** */ #endif /* ATSCTRB_GLIB_GSLIST_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib.cats0000664000175000017500000000443712223166165020710 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GLIB_CATS #define ATSCTRB_GLIB_CATS /* ****** ****** */ #include "glib.h" // #include "contrib/glib/CATS/glib/gbasics.cats" // #define atsctrb_g_strdup g_strdup #define atsctrb_g_strndup g_strndup #define atsctrb_g_strdup_printf g_strdup_printf #define atsctrb_g_strnfill g_strnfill // #include "contrib/glib/CATS/glib/garray.cats" #include "contrib/glib/CATS/glib/ghash.cats" #include "contrib/glib/CATS/glib/glist.cats" // doubly-linked #include "contrib/glib/CATS/glib/gmem.cats" #include "contrib/glib/CATS/glib/gqsort.cats" #include "contrib/glib/CATS/glib/grand.cats" #include "contrib/glib/CATS/glib/gslist.cats" // singly-linked #include "contrib/glib/CATS/glib/gstring.cats" #include "contrib/glib/CATS/glib/gutils.cats" // #include "contrib/glib/CATS/glib/gunicode.cats" /* ****** ****** */ #endif /* ATSCTRB_GLIB_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/CATS/glib-object.cats0000664000175000017500000000443112223166165022146 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSCTRB_GOBJECT_CATS #define ATSCTRB_GOBJECT_CATS /* ****** ****** */ #include "glib-object.h" /* ****** ****** */ ATSinline() ats_int_type atsctrb_g_object_ref_count (ats_ptr_type x) { return g_atomic_int_get ((int*)&((GObject*)x)->ref_count) ; } // end of [atsctrb_g_object_ref_count] /* ****** ****** */ #define atsctrb_g_object_is_floating g_object_is_floating #define atsctrb_g_object_ref g_object_ref #define atsctrb_g_object_unref g_object_unref #define atsctrb_g_signal_connect g_signal_connect #define atsctrb_g_signal_connect_after g_signal_connect_after #define atsctrb_g_signal_connect_swapped g_signal_connect_swapped #define atsctrb_g_signal_emit_by_name g_signal_emit_by_name #define atsctrb_g_signal_stop_emission_by_name g_signal_stop_emission_by_name /* ****** ****** */ #endif /* ATSCTRB_GOBJECT_CATS */ ats-lang-anairiats-0.2.11/contrib/glib/SATS/0000700000175000017500000000000012223166165017113 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/0000700000175000017500000000000012223166165020030 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gunicode.sats0000664000175000017500000002262012223166165022537 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2011 // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gunicode.cats" %} // end of [%{#] (* ****** ****** *) staload "contrib/glib/SATS/glib/gtypes.sats" (* ****** ****** *) abst@ype gunichar = guint32 abst@ype gunichar2 = guint16 (* ****** ****** *) // abst@ype GUnicodeType = int // macdef G_UNICODE_CONTROL = $extval (GUnicodeType, "G_UNICODE_CONTROL") macdef G_UNICODE_FORMAT = $extval (GUnicodeType, "G_UNICODE_FORMAT") macdef G_UNICODE_UNASSIGNED = $extval (GUnicodeType, "G_UNICODE_UNASSIGNED") macdef G_UNICODE_PRIVATE_USE = $extval (GUnicodeType, "G_UNICODE_PRIVATE_USE") macdef G_UNICODE_SURROGATE = $extval (GUnicodeType, "G_UNICODE_SURROGATE") macdef G_UNICODE_LOWERCASE_LETTER = $extval (GUnicodeType, "G_UNICODE_LOWERCASE_LETTER") macdef G_UNICODE_MODIFIER_LETTER = $extval (GUnicodeType, "G_UNICODE_MODIFIER_LETTER") macdef G_UNICODE_OTHER_LETTER = $extval (GUnicodeType, "G_UNICODE_OTHER_LETTER") macdef G_UNICODE_TITLECASE_LETTER = $extval (GUnicodeType, "G_UNICODE_TITLECASE_LETTER") macdef G_UNICODE_UPPERCASE_LETTER = $extval (GUnicodeType, "G_UNICODE_UPPERCASE_LETTER") macdef G_UNICODE_COMBINING_MARK = $extval (GUnicodeType, "G_UNICODE_COMBINING_MARK") macdef G_UNICODE_ENCLOSING_MARK = $extval (GUnicodeType, "G_UNICODE_ENCLOSING_MARK") macdef G_UNICODE_NON_SPACING_MARK = $extval (GUnicodeType, "G_UNICODE_NON_SPACING_MARK") macdef G_UNICODE_DECIMAL_NUMBER = $extval (GUnicodeType, "G_UNICODE_DECIMAL_NUMBER") macdef G_UNICODE_LETTER_NUMBER = $extval (GUnicodeType, "G_UNICODE_LETTER_NUMBER") macdef G_UNICODE_OTHER_NUMBER = $extval (GUnicodeType, "G_UNICODE_OTHER_NUMBER") macdef G_UNICODE_CONNECT_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_CONNECT_PUNCTUATION") macdef G_UNICODE_DASH_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_DASH_PUNCTUATION") macdef G_UNICODE_CLOSE_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_CLOSE_PUNCTUATION") macdef G_UNICODE_FINAL_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_FINAL_PUNCTUATION") macdef G_UNICODE_INITIAL_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_INITIAL_PUNCTUATION") macdef G_UNICODE_OTHER_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_OTHER_PUNCTUATION") macdef G_UNICODE_OPEN_PUNCTUATION = $extval (GUnicodeType, "G_UNICODE_OPEN_PUNCTUATION") macdef G_UNICODE_CURRENCY_SYMBOL = $extval (GUnicodeType, "G_UNICODE_CURRENCY_SYMBOL") macdef G_UNICODE_MODIFIER_SYMBOL = $extval (GUnicodeType, "G_UNICODE_MODIFIER_SYMBOL") macdef G_UNICODE_MATH_SYMBOL = $extval (GUnicodeType, "G_UNICODE_MATH_SYMBOL") macdef G_UNICODE_OTHER_SYMBOL = $extval (GUnicodeType, "G_UNICODE_OTHER_SYMBOL") macdef G_UNICODE_LINE_SEPARATOR = $extval (GUnicodeType, "G_UNICODE_LINE_SEPARATOR") macdef G_UNICODE_PARAGRAPH_SEPARATOR = $extval (GUnicodeType, "G_UNICODE_PARAGRAPH_SEPARATOR") macdef G_UNICODE_SPACE_SEPARATO = $extval (GUnicodeType, "G_UNICODE_SPACE_SEPARATO") // (* ****** ****** *) // abst@ype GUnicodeBreakType = int // macdef G_UNICODE_BREAK_MANDATORY = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_MANDATORY") macdef G_UNICODE_BREAK_CARRIAGE_RETURN = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_CARRIAGE_RETURN") macdef G_UNICODE_BREAK_LINE_FEED = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_LINE_FEED") macdef G_UNICODE_BREAK_COMBINING_MARK = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_COMBINING_MARK") macdef G_UNICODE_BREAK_SURROGATE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_SURROGATE") macdef G_UNICODE_BREAK_ZERO_WIDTH_SPACE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_ZERO_WIDTH_SPACE") macdef G_UNICODE_BREAK_INSEPARABLE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_INSEPARABLE") macdef G_UNICODE_BREAK_NON_BREAKING_GLUE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_NON_BREAKING_GLUE") macdef G_UNICODE_BREAK_CONTINGENT = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_CONTINGENT") macdef G_UNICODE_BREAK_SPACE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_SPACE") macdef G_UNICODE_BREAK_AFTER = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_AFTER") macdef G_UNICODE_BREAK_BEFORE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_BEFORE") macdef G_UNICODE_BREAK_BEFORE_AND_AFTER = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_BEFORE_AND_AFTER") macdef G_UNICODE_BREAK_HYPHEN = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HYPHEN") macdef G_UNICODE_BREAK_NON_STARTER = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_NON_STARTER") macdef G_UNICODE_BREAK_OPEN_PUNCTUATION = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_OPEN_PUNCTUATION") macdef G_UNICODE_BREAK_CLOSE_PUNCTUATION = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_CLOSE_PUNCTUATION") macdef G_UNICODE_BREAK_QUOTATION = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_QUOTATION") macdef G_UNICODE_BREAK_EXCLAMATION = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_EXCLAMATION") macdef G_UNICODE_BREAK_IDEOGRAPHIC = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_IDEOGRAPHIC") macdef G_UNICODE_BREAK_NUMERIC = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_NUMERIC") macdef G_UNICODE_BREAK_INFIX_SEPARATOR = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_INFIX_SEPARATOR") macdef G_UNICODE_BREAK_SYMBOL = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_SYMBOL") macdef G_UNICODE_BREAK_ALPHABETIC = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_ALPHABETIC") macdef G_UNICODE_BREAK_PREFIX = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_PREFIX") macdef G_UNICODE_BREAK_POSTFIX = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_POSTFIX") macdef G_UNICODE_BREAK_COMPLEX_CONTEXT = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_COMPLEX_CONTEXT") macdef G_UNICODE_BREAK_AMBIGUOUS = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_AMBIGUOUS") macdef G_UNICODE_BREAK_UNKNOWN = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_UNKNOWN") macdef G_UNICODE_BREAK_NEXT_LINE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_NEXT_LINE") macdef G_UNICODE_BREAK_WORD_JOINER = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_WORD_JOINER") macdef G_UNICODE_BREAK_HANGUL_L_JAMO = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HANGUL_L_JAMO") macdef G_UNICODE_BREAK_HANGUL_V_JAMO = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HANGUL_V_JAMO") macdef G_UNICODE_BREAK_HANGUL_T_JAMO = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HANGUL_T_JAMO") macdef G_UNICODE_BREAK_HANGUL_LV_SYLLABLE = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HANGUL_LV_SYLLABLE") macdef G_UNICODE_BREAK_HANGUL_LVT_SYLLABL = $extval (GUnicodeBreakType, "G_UNICODE_BREAK_HANGUL_LVT_SYLLABL") // (* ****** ****** *) fun g_unichar_isalnum (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isalnum" fun g_unichar_isalpha (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isalpha" fun g_unichar_iscntrl (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_iscntrl" fun g_unichar_isdigit (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isdigit" fun g_unichar_isgraph (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isgraph" fun g_unichar_islower (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_islower" fun g_unichar_isprint (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isprint" fun g_unichar_ispunct (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_ispunct" fun g_unichar_isspace (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isspace" fun g_unichar_isupper (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isupper" fun g_unichar_isxdigit (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isxdigit" fun g_unichar_istitle (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_istitle" fun g_unichar_isdefined (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_isdefined" fun g_unichar_iswide (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_iswide" fun g_unichar_iswide_cjk (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_iswide_cjk" fun g_unichar_iszerowidth (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_iszerowidth" fun g_unichar_ismark (c: gunichar):<> gboolean = "mac#atsctrb_g_unichar_ismark" (* ****** ****** *) fun g_utf8_strlen_cstr ( x: string ) : glong = "atsctrb_g_utf8_strlen_cstr" // end of [g_utf8_strlen_cstr] fun g_utf8_strlen_carr {n:nat} ( x: &READ(@[gchar][n]), n: gsize(n) ) : glong = "mac#atsctrb_g_utf8_strlen_carr" // end of [g_utf8_strlen_carr] (* ****** ****** *) (* end of [gunicode.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/grand.sats0000664000175000017500000001564612223166165022047 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/grand.cats" %} // end of [%{#] (* ****** ****** *) // // HX-2010-02-27: // This is only needed for individual testing // staload "contrib/glib/SATS/glib/gtypes.sats" // (* ****** ****** *) absviewtype GRand_ptr (l:addr) // = GRand* viewtypedef GRand_ptr = [l:addr] GRand_ptr l (* ****** ****** *) fun g_rand_new_with_seed (seed: guint32): GRand_ptr = "mac#atsctrb_g_rand_new_with_seed" // end of [g_rand_new_with_seed] fun g_rand_new_with_seed_array {n:nat} (seed: &(@[guint32][n]), n: gint n): GRand_ptr = "mac#atsctrb_g_rand_new_with_seed_array" // end of [g_rand_new_with_seed_array] (* ****** ****** *) fun g_rand_new (): GRand_ptr = "mac#atsctrb_g_rand_new" fun g_rand_copy {l:addr} (rand: !GRand_ptr l): GRand_ptr = "mac#atsctrb_g_rand_copy" fun g_rand_free (rand: GRand_ptr): void = "mac#atsctrb_g_rand_free" (* ****** ****** *) fun g_rand_set_seed {l:addr} ( rand: !GRand_ptr l, seed: guint32 ) : void = "mac#atsctrb_g_rand_set_seed" // end of [g_rand_set_seed] fun g_rand_set_seed_array {l:addr} {n:nat} ( rand: !GRand_ptr l, seed: &(@[guint32][n]), n: gint n ) : void = "mac#atsctrb_g_rand_set_seed_array" // end of [g_rand_set_seed_array] (* ****** ****** *) fun g_rand_boolean {l:addr} ( rand: !GRand_ptr l ) : gboolean = "mac#atsctrb_g_rand_boolean" // end of [g_rand_boolean] fun g_rand_int {l:addr} ( rand: !GRand_ptr l ) : guint32 = "mac#atsctrb_g_rand_int" // end of [g_rand_int] fun g_rand_int_range {l:addr} ( rand: !GRand_ptr l, _beg: gint32, _end: gint32 ) : gint32 = "mac#atsctrb_g_rand_int_range" // end of [g_rand_int_range] fun g_rand_double {l:addr} (rand: !GRand_ptr l): gdouble = "mac#atsctrb_g_rand_double" // end of [g_rand_double] fun g_rand_double_range {l:addr} ( rand: !GRand_ptr l, _beg: gdouble, _end: gdouble ) : gdouble = "mac#atsctrb_g_rand_double_range" // end of [g_rand_double_range] (* ****** ****** *) fun g_random_set_seed (seed: guint32): void = "mac#atsctrb_g_random_set_seed" // end of [g_random_set_seed] (* ****** ****** *) fun g_random_boolean (): gboolean = "mac#atsctrb_g_random_boolean" // end of [g_random_boolean] fun g_random_int (): guint32 = "mac#atsctrb_g_random_int" // end of [g_random_int] fun g_random_int_range (_beg: gint32, _end: gint32): gint32 = "mac#atsctrb_g_random_int_range" // end of [g_random_int_range] fun g_random_double (): gdouble = "mac#atsctrb_g_random_double" // end of [g_random_double] fun g_random_double_range (_beg: gdouble, _end: gdouble): gdouble = "mac#atsctrb_g_random_double_range" // end of [g_random_double_range] (* ****** ****** *) (* end of [grand.sats] *) //// /* GLIB - Library of useful routines for C programming * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ /* * Modified by the GLib Team and others 1997-2000. See the AUTHORS * file for a list of people on the GLib Team. See the ChangeLog * files for a list of changes. These files are distributed with * GLib at ftp://ftp.gtk.org/pub/gtk/. */ #if defined(G_DISABLE_SINGLE_INCLUDES) && !defined (__GLIB_H_INSIDE__) && !defined (GLIB_COMPILATION) #error "Only can be included directly." #endif #ifndef __G_RAND_H__ #define __G_RAND_H__ #include G_BEGIN_DECLS typedef struct _GRand GRand; /* GRand - a good and fast random number generator: Mersenne Twister * see http://www.math.keio.ac.jp/~matumoto/emt.html for more info. * The range functions return a value in the intervall [begin, end). * int -> [0..2^32-1] * int_range -> [begin..end-1] * double -> [0..1) * double_range -> [begin..end) */ GRand* g_rand_new_with_seed (guint32 seed); GRand* g_rand_new_with_seed_array (const guint32 *seed, guint seed_length); GRand* g_rand_new (void); void g_rand_free (GRand *rand_); GRand* g_rand_copy (GRand *rand_); void g_rand_set_seed (GRand *rand_, guint32 seed); void g_rand_set_seed_array (GRand *rand_, const guint32 *seed, guint seed_length); #define g_rand_boolean(rand_) ((g_rand_int (rand_) & (1 << 15)) != 0) guint32 g_rand_int (GRand *rand_); gint32 g_rand_int_range (GRand *rand_, gint32 begin, gint32 end); gdouble g_rand_double (GRand *rand_); gdouble g_rand_double_range (GRand *rand_, gdouble begin, gdouble end); void g_random_set_seed (guint32 seed); #define g_random_boolean() ((g_random_int () & (1 << 15)) != 0) guint32 g_random_int (void); gint32 g_random_int_range (gint32 begin, gint32 end); gdouble g_random_double (void); gdouble g_random_double_range (gdouble begin, gdouble end); G_END_DECLS #endif /* __G_RAND_H__ */ ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/ghash.sats0000664000175000017500000001735712223166165022047 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) // // HX-2010-02-28: // In any acconts, [ghash] is a terrible package for ATS to incorporate. // It is simply a _big_ mess, and I tried my best to make some sense out // of this mess! // // HX-2010-03-01: // I suggest that you don't use this package unless you _really_ know what // you are doing, especially, if you want to turn on GCATS! // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/ghash.cats" %} // end of [%{#] (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/gtypes.sats" // (* ****** ****** *) // // HX-2010-02-24: [GHashTable_ref] is refcounted // absviewtype GHashTable_ref (key:type, itm: type, l:addr) = $extype"GHashTable_ref" viewtypedef GHashTable_ref (key:type, itm: type) = [l:addr] GHashTable_ref (key, itm, l) // end of [GHashTable_ref] (* ****** ****** *) fun g_hash_table_new {key,itm:type} ( hash_func: GHashFunc key, key_equal_func: GEqualFunc key ) : GHashTable_ref (key,itm) = "mac#atslib_g_hash_table_new" // end of [g_hash_table_new] fun g_hash_table_destroy {key,itm:type} ( hash_table: GHashTable_ref (key,itm) ) : void = "mac#atslib_g_hash_table_destroy" // end of [g_hash_table_destroy] (* ****** ****** *) fun g_hash_table_insert {key,itm:type} {l:addr} ( hash_table: !GHashTable_ref (key, itm, l), key: key, itm: itm ) : void = "mac#atsctrb_g_hash_table_insert" // end of [g_hash_table_insert] (* ****** ****** *) fun g_hash_table_size {key,itm:type} {l:addr} ( hash_table: !GHashTable_ref (key, itm, l) ) : guint = "mac#atsctrb_g_hash_table_size" // end of [g_hash_table_size] (* ****** ****** *) fun g_hash_table_lookup {key,itm:type} {l:addr} ( hash_table: !GHashTable_ref (key, itm, l), key: key ) : [lp:addr] ( {lp <> null} (!ptr lp >> itm) - void | ptr lp ) = "mac#atslib_g_hash_table_lookup" // end of [g_hash_table_lookup] (* ****** ****** *) fun g_str_hash (str: string): guint = "mac#atsctrb_g_str_hash" (* ****** ****** *) (* end of [ghash.sats] *) //// /* GLIB - Library of useful routines for C programming * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ /* * Modified by the GLib Team and others 1997-2000. See the AUTHORS * file for a list of people on the GLib Team. See the ChangeLog * files for a list of changes. These files are distributed with * GLib at ftp://ftp.gtk.org/pub/gtk/. */ #ifndef __G_HASH_H__ #define __G_HASH_H__ #include G_BEGIN_DECLS typedef struct _GHashTable GHashTable; typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); /* Hash tables */ GHashTable* g_hash_table_new (GHashFunc hash_func, GEqualFunc key_equal_func); GHashTable* g_hash_table_new_full (GHashFunc hash_func, GEqualFunc key_equal_func, GDestroyNotify key_destroy_func, GDestroyNotify value_destroy_func); void g_hash_table_destroy (GHashTable *hash_table); void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); void g_hash_table_replace (GHashTable *hash_table, gpointer key, gpointer value); gboolean g_hash_table_remove (GHashTable *hash_table, gconstpointer key); void g_hash_table_remove_all (GHashTable *hash_table); gboolean g_hash_table_steal (GHashTable *hash_table, gconstpointer key); void g_hash_table_steal_all (GHashTable *hash_table); gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); gboolean g_hash_table_lookup_extended (GHashTable *hash_table, gconstpointer lookup_key, gpointer *orig_key, gpointer *value); void g_hash_table_foreach (GHashTable *hash_table, GHFunc func, gpointer user_data); gpointer g_hash_table_find (GHashTable *hash_table, GHRFunc predicate, gpointer user_data); guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); guint g_hash_table_foreach_steal (GHashTable *hash_table, GHRFunc func, gpointer user_data); guint g_hash_table_size (GHashTable *hash_table); /* keeping hash tables alive */ GHashTable* g_hash_table_ref (GHashTable *hash_table); void g_hash_table_unref (GHashTable *hash_table); #ifndef G_DISABLE_DEPRECATED /* The following two functions are deprecated and will be removed in * the next major release. They do no good. */ #define g_hash_table_freeze(hash_table) ((void)0) #define g_hash_table_thaw(hash_table) ((void)0) #endif /* G_DISABLE_DEPRECATED */ /* Hash Functions */ gboolean g_str_equal (gconstpointer v1, gconstpointer v2); guint g_str_hash (gconstpointer v); gboolean g_int_equal (gconstpointer v1, gconstpointer v2); guint g_int_hash (gconstpointer v); /* This "hash" function will just return the key's address as an * unsigned integer. Useful for hashing on plain addresses or * simple integer values. * Passing NULL into g_hash_table_new() as GHashFunc has the * same effect as passing g_direct_hash(). */ guint g_direct_hash (gconstpointer v) G_GNUC_CONST; gboolean g_direct_equal (gconstpointer v1, gconstpointer v2) G_GNUC_CONST; G_END_DECLS #endif /* __G_HASH_H__ */ ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gstring.sats0000664000175000017500000001611212223166165022416 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) // // HX-2010-03-03: // it is just a plain vanilla style of implementation of strings; please // do not expect it to be highly efficient because it is not implemented // as such. // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gstring.cats" %} // end of [%{#] (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/glib/gtypes.sats" // (* ****** ****** *) absviewtype GString_ptr (l:addr) // = GString* viewtypedef GString_ptr0 = [l:agez] GString_ptr (l) viewtypedef GString_ptr1 = [l:addr | l > null] GString_ptr (l) (* ****** ****** *) fun g_string_get_str {l:agz} (string: !GString_ptr l): ptr = "atsctrb_g_string_get_str" // end of [g_string_get_str] fun g_string_get_len {l:agz} (string: !GString_ptr l): gsize = "atsctrb_g_string_get_len" // end of [g_string_get_len] fun g_string_get_allocated_len {l:agz} ( string: !GString_ptr l ) : gsize = "atsctrb_g_string_get_allocated_len" // end of [g_string_get_allocated_len] (* ****** ****** *) symintr g_string_new fun g_string_new_null (): GString_ptr1 = "mac#atsctrb_g_string_new_null" overload g_string_new with g_string_new_null fun g_string_new_init {l:addr} ( init: !READ(gstring(l)) ) : GString_ptr1 = "mac#atsctrb_g_string_new_init" overload g_string_new with g_string_new_init (* ****** ****** *) absviewtype gchararrptr (l:addr, n:int) // @[gchar][n] @ l // // HX-2010-05-28: [init] can be NULL // fun g_string_new_len {l:addr} {n,n1:nat | n1 <= n} ( init: !gchararrptr (l, n), n1: gsize n1 ) : GString_ptr1 = "mac#g_string_new_len" // end of [g_string_new_len] (* ****** ****** *) fun g_string_sized_new {n:nat} (n: gsize n): GString_ptr1 = "mac#g_string_sized_new" // end of [g_string_sized_new] (* ****** ****** *) // string = _val fun g_string_assign {l,l1:addr | l > null} ( string: !GString_ptr l, _val: !gstring l1 ) : ptr l = "mac#atsctrb_g_string_assign" // end of [g_string_assign] (* ****** ****** *) // // HX: string = string ++ _val // fun g_string_append {l,l1:addr | l > null} ( string: !GString_ptr l, _val: !gstring l1 ) : ptr l = "mac#atsctrb_g_string_append" // end of [g_string_append] // // HX: string = string ++ c // fun g_string_append_c {l:agz} (string: !GString_ptr l, c: gchar): ptr l = "mac#atsctrb_g_string_append_c" // end of [g_string_append_c] // // string = string ++ _val // fun g_string_append_len {l,l1:addr | l > null} {n1,n2:nat | n2 <= n1} ( string: !GString_ptr l, _val: !gchararrptr (l1, n1), n2: gsize n2 ) : ptr l = "mac#atsctrb_g_string_append_len" // end of [g_string_append_len] (* ****** ****** *) // // the original content in [string] is overwritten // fun g_string_printf {l:agz} {ts:types} ( string: !READ(GString_ptr(l)), fmt: printf_c ts, arg: ts ) : void = "mac#atsctrb_g_string_printf" // end of [g_string_printf] fun g_string_append_printf {l:agz} {ts:types} ( string: !READ(GString_ptr(l)), fmt: printf_c ts, arg: ts ) : void = "mac#atsctrb_g_string_append_printf" // end of [g_string_append_printf] (* ****** ****** *) // // HX: string = _val ++ string // fun g_string_prepend {l:agz} (string: !GString_ptr l, _val: string): ptr l = "mac#atsctrb_g_string_prepend" // end of [g_string_prepend] // // HX: string = c ++ string // fun g_string_prepend_c {l:agz} (string: !GString_ptr l, c: gchar): ptr l = "mac#atsctrb_g_string_prepend_c" // end of [g_string_prepend_c] // // HX: string = _val ++ string // fun g_string_prepend_len {l,l1:addr | l > null} {n1,n2:nat} ( string: !GString_ptr l, _val: !gchararrptr (l1, n1), n2: gsize n2 ) : ptr l = "mac#atsctrb_g_string_prepend_len" // end of [g_string_prepend_len] (* ****** ****** *) fun g_string_insert {l:agz} (string: !GString_ptr l, pos: gssize, _val: string): ptr l = "mac#atsctrb_g_string_insert" // end of [g_string_insert] fun g_string_insert_c {l:agz} (string: !GString_ptr l, pos: gssize, c: gchar): ptr l = "mac#atsctrb_g_string_insert_c" // end of [g_string_insert_c] fun g_string_insert_len {l,l1:addr | l > null} {n1,n2:nat} ( string: !GString_ptr l, pos: gssize, _val: !gchararrptr (l1, n1), n2: gsize n2 ) : ptr l = "mac#atsctrb_g_string_insert_len" // end of [g_string_insert_len] (* ****** ****** *) // // HX: since glib-2.14 // fun g_string_overwrite {l:agz} (string: !GString_ptr l, pos: gssize, _val: string): ptr l = "mac#atsctrb_g_string_overwrite" // end of [g_string_overwrite] // // HX: since glib-2.14 // fun g_string_overwrite_len {l,l1:addr | l > null} {n1,n2:nat} ( string: !GString_ptr l, pos: gssize, _val: !gchararrptr (l1, n1), n2: gsize n2 ) : ptr l = "mac#atsctrb_g_string_overwrite_len" // end of [g_string_overwrite_len] (* ****** ****** *) // HX: erase all if [n] is negative fun g_string_erase {l:agz} (string: !GString_ptr l, pos: gssize, n: gssize): ptr l = "mac#atsctrb_g_string_erase" // end of [g_string_erase] (* ****** ****** *) fun g_string_truncate {l:agz} (string: !GString_ptr l, n: gsize): ptr l = "mac#atsctrb_g_string_truncate" // end of [g_string_truncate] (* ****** ****** *) fun g_string_set_size {l:agz} (string: !GString_ptr l, n: gsize): ptr l = "mac#atsctrb_g_string_set_size" // end of [g_string_set_size] (* ****** ****** *) fun g_string_free_true (string: GString_ptr1): void = "mac#atsctrb_g_string_free_true" // end of [g_string_free_true] (* ****** ****** *) fun g_string_hash {l:agz} (string1: !READ(GString_ptr(l))): guint = "mac#atsctrb_g_string_hash" // end of [g_string_hash] fun g_string_equal {l1,l2:agz} ( string1: !READ(GString_ptr(l1)), string2: !READ(GString_ptr(l2)) ) : gboolean = "mac#atsctrb_g_string_equal" // end of [g_string_equal] (* ****** ****** *) (* end of [gstring.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gutils.sats0000664000175000017500000000347412223166165022257 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gutils.cats" %} // end of [%{#] (* ****** ****** *) fun g_snprintf {n:pos} {l:addr} {ts:types} ( pf: b0ytes n @ l | p: ptr l, n: gulong n, fmt: printf_c ts, arg: ts ) : ( gstring_v l, gstring l - b0ytes n @ l | gint ) = "mac#atsctrb_g_snprintf" // end of [g_strdup_printf] (* ****** ****** *) (* end of [gutils.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gslist.sats0000664000175000017500000000407312223166165022251 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gslist.cats" %} (* ****** ****** *) sortdef vwtp = viewtype (* ** n = 0 if and only if l = null *) absviewtype GSList_ptr (a:viewtype+, n:int) // = GSList* viewtypedef GSList_ptr0 (a:vwtp) = [n:nat] GSList_ptr (a, n) viewtypedef GSList_ptr1 (a:vwtp) = [n:pos] GSList_ptr (a, n) (* ****** ****** *) fun g_slist_new_nil {a:vwtp} (): GSList_ptr (a, 0) = "mac#atsctrb_g_slist_new_nil" // end of [g_slist_new_nil] fun g_slist_free_nil {a:vwtp} (xs: GSList_ptr (a, 0)):<> void = "mac#atsctrb_g_slist_free_nil" // end of [g_slist_free_nil] (* ****** ****** *) (* end of [gslist.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gbasics.sats0000664000175000017500000002721112223166165022356 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/glib/gtypes.sats" // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gbasics.cats" %} // end of [%{#] (* ****** ****** *) macdef GTRUE = $extval (gboolean, "TRUE") macdef GFALSE = $extval (gboolean, "FALSE") castfn bool_of_gboolean {b:bool} (b: gboolean b):<> bool b overload bool_of with bool_of_gboolean symintr gboolean castfn gboolean_of_bool0 (b: bool):<> gboolean overload gboolean with gboolean_of_bool0 castfn gboolean_of_bool1 {b:bool} (b: bool b):<> gboolean b overload gboolean with gboolean_of_bool1 (* ****** ****** *) castfn char_of_gchar {c:char} (c: gchar c):<> char c overload char_of with char_of_gchar symintr gchar castfn gchar_of_char0 (c: char):<> gchar overload gchar with gchar_of_char0 castfn gchar_of_char1 {c:char} (c: char c):<> gchar c overload gchar with gchar_of_char1 (* ****** ****** *) castfn int_of_gint {i:int} (i: gint i):<> int i overload int_of with int_of_gint symintr gint castfn gint_of_int0 (i: int):<> gint overload gint with gint_of_int0 castfn gint_of_int1 {i:int} (i: int i):<> gint i overload gint with gint_of_int1 (* ****** ****** *) castfn uint_of_guint {i:nat} (i: guint i):<> uint i overload uint_of with uint_of_guint symintr guint // castfn guint_of_uint0 (i: uint):<> guint overload guint with guint_of_uint0 castfn guint_of_uint1 {i:nat} (i: uint i):<> guint i overload guint with guint_of_uint1 // castfn guint_of_int1 {i:nat} (i: int i):<> guint i overload guint with guint_of_int1 (* ****** ****** *) symintr guint8 castfn guint8_of_uint (i: uint):<> guint8 overload guint8 with guint8_of_uint castfn guint8_of_int {i:nat} (i: int i):<> guint8 overload guint8 with guint8_of_int symintr guint16 castfn guint16_of_uint (i: uint):<> guint16 overload guint16 with guint16_of_uint castfn guint16_of_int {i:nat} (i: int i):<> guint16 overload guint16 with guint16_of_int symintr guint32 castfn guint32_of_uint (i: uint):<> guint32 overload guint32 with guint32_of_uint castfn guint32_of_int {i:nat} (i: int i):<> guint32 overload guint32 with guint32_of_int (* ****** ****** *) symintr glong castfn glong_of_int {i:nat} (i: int i): glong i overload glong with glong_of_int castfn glong_of_lint {i:nat} (i: lint i): glong i overload glong with glong_of_lint (* ****** ****** *) symintr gulong castfn gulong_of_int {i:nat} (i: int i): gulong i overload gulong with gulong_of_int castfn gulong_of_uint {i:nat} (i: uint i): gulong i overload gulong with gulong_of_uint castfn gulong_of_ulint {i:nat} (i: ulint i): gulong i overload gulong with gulong_of_ulint (* ****** ****** *) castfn float_of_gfloat (x: gfloat):<> float overload float_of with float_of_gfloat symintr gfloat castfn gfloat_of_float (x: float):<> gfloat overload gfloat with gfloat_of_float castfn gfloat_of_double (x: double):<> gfloat overload gfloat with gfloat_of_double castfn gfloat_of_int (x: int):<> gfloat overload gfloat with gfloat_of_int (* ****** ****** *) castfn double_of_gdouble (x: gdouble):<> double overload double_of with double_of_gdouble symintr gdouble castfn gdouble_of_double (x: double):<> gdouble overload gdouble with gdouble_of_double castfn gdouble_of_int (x: int):<> gdouble overload gdouble with gdouble_of_int (* ****** ****** *) typedef add (a:t@ype) = (a, a) -<> a typedef sub (a:t@ype) = (a, a) -<> a typedef mul (a:t@ype) = (a, a) -<> a typedef div (a:t@ype) = (a, a) -<> a typedef lt (a:t@ype) = (a, a) -<> bool typedef lte (a:t@ype) = (a, a) -<> bool typedef gt (a:t@ype) = (a, a) -<> bool typedef gte (a:t@ype) = (a, a) -<> bool typedef eq (a:t@ype) = (a, a) -<> bool typedef neq (a:t@ype) = (a, a) -<> bool (* ****** ****** *) fun add_gint_gint {i,j:int} (x: gint i, y: gint j): gint (i+j) = "atsctrb_add_gint_gint" overload + with add_gint_gint fun sub_gint_gint {i,j:int} (x: gint i, y: gint j): gint (i-j) = "atsctrb_sub_gint_gint" overload - with sub_gint_gint fun mul_gint_gint : mul (gint) = "atsctrb_mul_gint_gint" overload * with mul_gint_gint fun div_gint_gint : div (gint) = "atsctrb_div_gint_gint" overload / with div_gint_gint (* ****** ****** *) fun lt_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i < j) = "atsctrb_lt_gint_gint" overload < with lt_gint_gint fun lte_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i <= j) = "atsctrb_lte_gint_gint" overload <= with lte_gint_gint fun gt_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i > j) = "atsctrb_gt_gint_gint" overload > with gt_gint_gint fun gte_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i >= j) = "atsctrb_gte_gint_gint" overload >= with gte_gint_gint fun eq_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i == j) = "atsctrb_eq_gint_gint" overload = with eq_gint_gint fun neq_gint_gint {i,j:int} (x: gint i, y: gint j): bool (i <> j) = "atsctrb_neq_gint_gint" overload <> with neq_gint_gint (* ****** ****** *) fun add_guint_guint {i,j:int} (x: guint i, y: guint j): guint (i+j) = "atsctrb_add_guint_guint" overload + with add_guint_guint fun sub_guint_guint {i,j:int | i >= j} (x: guint i, y: guint j): guint (i-j) = "atsctrb_sub_guint_guint" overload - with sub_guint_guint fun mul_guint_guint : mul (guint) = "atsctrb_mul_guint_guint" overload * with mul_guint_guint fun div_guint_guint : div (guint) = "atsctrb_div_guint_guint" overload / with div_guint_guint (* ****** ****** *) fun lt_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i < j) = "atsctrb_lt_guint_guint" overload < with lt_guint_guint fun lte_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i <= j) = "atsctrb_lte_guint_guint" overload <= with lte_guint_guint fun gt_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i > j) = "atsctrb_gt_guint_guint" overload > with gt_guint_guint fun gte_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i >= j) = "atsctrb_gte_guint_guint" overload >= with gte_guint_guint fun eq_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i == j) = "atsctrb_eq_guint_guint" overload = with eq_guint_guint fun neq_guint_guint {i,j:int} (x: guint i, y: guint j): bool (i <> j) = "atsctrb_neq_guint_guint" overload <> with neq_guint_guint (* ****** ****** *) fun lt_gint32_gint32 : lt (gint32) = "atsctrb_lt_gint32_gint32" overload < with lt_gint32_gint32 fun lte_gint32_gint32 : lte (gint32) = "atsctrb_lte_gint32_gint32" overload <= with lte_gint32_gint32 fun gt_gint32_gint32 : gt (gint32) = "atsctrb_gt_gint32_gint32" overload > with gt_gint32_gint32 fun gte_gint32_gint32 : gte (gint32) = "atsctrb_gte_gint32_gint32" overload >= with gte_gint32_gint32 fun eq_gint32_gint32 : eq (gint32) = "atsctrb_eq_gint32_gint32" overload = with eq_gint32_gint32 fun neq_gint32_gint32 : neq (gint32) = "atsctrb_neq_gint32_gint32" overload <> with neq_gint32_gint32 (* ****** ****** *) fun lt_guint32_guint32 : lt (guint32) = "atsctrb_lt_guint32_guint32" overload < with lt_guint32_guint32 fun lte_guint32_guint32 : lte (guint32) = "atsctrb_lte_guint32_guint32" overload <= with lte_guint32_guint32 fun gt_guint32_guint32 : gt (guint32) = "atsctrb_gt_guint32_guint32" overload > with gt_guint32_guint32 fun gte_guint32_guint32 : gte (guint32) = "atsctrb_gte_guint32_guint32" overload >= with gte_guint32_guint32 fun eq_guint32_guint32 : eq (guint32) = "atsctrb_eq_guint32_guint32" overload = with eq_guint32_guint32 fun neq_guint32_guint32 : neq (guint32) = "atsctrb_neq_guint32_guint32" overload <> with neq_guint32_guint32 (* ****** ****** *) symintr gsize castfn gsize_of_int1 {i:nat} (i: int i):<> gsize i overload gsize with gsize_of_int1 castfn gsize_of_uint0 (i: uint):<> gsize overload gsize with gsize_of_uint0 castfn gsize_of_uint1 {i:nat} (i: uint i):<> gsize i overload gsize with gsize_of_uint1 castfn gsize_of_size0 (i: size_t):<> gsize overload gsize with gsize_of_size0 castfn gsize_of_size1 {i:nat} (i: size_t i):<> gsize i overload gsize with gsize_of_size1 (* ****** ****** *) symintr gssize castfn gssize_of_int0 (i: int):<> gssize overload gssize with gssize_of_int0 castfn gssize_of_int1 {i:int} (i: int i):<> gssize i overload gssize with gssize_of_int1 castfn gssize_of_size0 (i: size_t):<> gssize overload gssize with gssize_of_size0 castfn gssize_of_size1 {i:nat} (i: size_t i):<> gssize i overload gssize with gssize_of_size1 castfn gssize_of_ssize0 (i: ssize_t):<> gssize overload gssize with gssize_of_ssize0 castfn gssize_of_ssize1 {i:int} (i: ssize_t i):<> gssize i overload gssize with gssize_of_ssize1 (* ****** ****** *) symintr gpointer castfn gpointer_of_type {a:type} (x: a):<> gpointer overload gpointer with gpointer_of_type symintr gpointer_vt castfn gpointer_of_viewtype {a:viewtype} (x: !a):<> gpointer overload gpointer_vt with gpointer_of_viewtype fun GPOINTER_TO_INT (x: gpointer): gint = "mac#atsctrb_GPOINTER_TO_INT" // end of [GPOINTER_TO_INT] fun GINT_TO_POINTER (x: gint): gpointer = "mac#atsctrb_GINT_TO_POINTER" // end of [GINT_TO_POINTER] (* ****** ****** *) absviewtype gstring (l:addr) viewtypedef gstring0 = [l:agez] gstring l viewtypedef gstring1 = [l:addr | l > null] gstring l castfn ptr_of_gstring {l:addr} (x: !gstring l):<> ptr l overload ptr_of with ptr_of_gstring absview gstring_v (l:addr) castfn gstring_of_viewptr {l:addr} (pf: gstring_v l | p: ptr l): gstring l castfn gstring_make_null (x: ptr null): gstring (null) castfn gstring_of_string (x: string): [l:agz] (gstring l - void | gstring l) // end of [gstring_of_string] castfn gstring_of_stropt (x: Stropt): [l:addr] (gstring l - void | gstring l) // end of [gstring_of_stropt] fun compare_gstring_gstring {l1,l2:agz} (x1: !gstring l1, x2: !gstring l2): Sgn = "atsctrb_compare_gstring_gstring" // end of [compare_gstring_gstring] fun compare_gstring0_gstring0 {l1,l2:addr} (x1: !gstring l1, x2: !gstring l2): Sgn = "atsctrb_compare_gstring0_gstring0" // end of [compare_gstring_gstring] (* ****** ****** *) fun g_strdup {l:agz} (x: !gstring l): gstring1 = "mac#atsctrb_g_strdup" fun g_strdup0 {l:addr} (x: !gstring l): gstring0 = "mac#atsctrb_g_strdup" fun g_strndup {l:agz} (x: !gstring l): gstring1 = "mac#atsctrb_g_strndup" fun g_strdup_printf {ts:types} ( fmt: printf_c ts, arg: ts ) : gstring1 = "mac#atsctrb_g_strdup_printf" // end of [g_strdup_printf] fun g_strnfill (n: gsize, c: gchar): gstring1 = "mac#atsctrb_g_strnfill" (* ****** ****** *) (* end of [gbasics.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/garray.sats0000664000175000017500000001036712223166165022234 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/garray.cats" %} (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/glib/gtypes.sats" // (* ****** ****** *) // // HX-2010-02-17: GArray_ref is reference-counted // absviewtype GArray_ref (a:viewt@ype+, l:addr) // = GArray* viewtypedef GArray_ref1 (a:viewt@ype) = [l:agz] GArray_ref (a, l) (* ****** ****** *) fun g_array_new {a:viewt@ype} (zrotrm: gboolean, clear: gboolean, sz: sizeof_t a): GArray_ref1 a = "mac#atsctrb_g_array_new" // end of [g_array_new] fun g_array_sized_new {a:viewt@ype} ( zrotrm: gboolean, clear: gboolean, sz: sizeof_t a, reserved: guint ) : GArray_ref1 a = "mac#atsctrb_g_array_sized_new" // end of [g_array_sized_new] (* ****** ****** *) fun g_array_ref {a:viewt@ype} {l:agz} (array: !GArray_ref (a, l)): GArray_ref (a, l) = "mac#atsctrb_g_array_ref" // end of [g_array_ref] fun g_array_unref {a:viewt@ype} (array: GArray_ref1 a): void = "mac#atsctrb_g_array_unref" // end of [g_array_unref] (* ****** ****** *) (* // // HX-2010-02-27: // Given the availability of g_array_unref, I have to be convinced that // this is really needed // *) fun g_array_free_true {a:t@ype} ( array: GArray_ref1 a ) : void = "atsctrb_g_array_free_true" // function! // end of [g_array_free_true] (* ****** ****** *) fun g_array_get_element_size {a:viewt@ype} {l:agz} ( array: !GArray_ref (a, l) ) : sizeof_t a = "mac#atslib_g_array_get_element_size" // end of [g_array_get_element_size] (* ****** ****** *) // // HX: unsafe functions // fun g_array_takeout_tsz {a:viewt@ype} {l:agz} {i:nat} ( array: !GArray_ref (a, l), i: gint i, tsz: sizeof_t a ) : [l_elt:addr] ( a @ l_elt, minus (GArray_ref (a, l), a @ l_elt) | ptr l_elt ) = "atsctrb_g_array_takeout_tsz" // end of [g_array_takeout_tsz] fun{a:t@ype} g_array_get_elt_at {l:agz} {i:nat} (array: !GArray_ref (a, l), i: gint i): a // end of [g_array_get_elt_at] fun{a:t@ype} g_array_set_elt_at {l:agz} {i:nat} (array: !GArray_ref (a, l), i: gint i, x: a): void // end of [g_array_set_elt_at] (* ****** ****** *) fun g_array_append_val {a:viewt@ype} {l:agz} ( array: !GArray_ref (a, l), v: &a >> a?! ) : void = "mac#atsctrb_g_array_append_val" // end of [g_array_append_val] fun g_array_prepend_val {a:viewt@ype} {l:agz} ( array: !GArray_ref (a, l), v: &a >> a?! ) : void = "mac#atsctrb_g_array_prepend_val" // end of [g_array_prepend_val] (* ****** ****** *) fun g_array_set_size {a:viewt@ype} {l:agz} ( array: !GArray_ref (a, l), size: guint ) : void = "mac#atsctrb_g_array_set_size" // end of [g_array_set_size] (* ****** ****** *) fun g_array_sort {a:viewt@ype} {l:agz} ( A: !GArray_ref (a, l), cmp: GCompareFuncRef a ) : void = "mac#atsctrb_g_array_sort" // end of [g_array_sort] (* ****** ****** *) (* end of [garray.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/glist.sats0000664000175000017500000001553612223166165022074 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) // // HX-2010-02-28: // In any acconts, [glist] is a terrible package for ATS to incorporate. // It is simply a _big_ mess, and I have tried my best to make some sense // out of this mess! // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/glist.cats" %} // end of [%{#] (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/glib/gtypes.sats" // (* ****** ****** *) sortdef vwtp = viewtype absviewtype GList_ptr (a:viewtype+, frnt:int, rear:int) = ptr // = GList* // end of [GList_ptr] viewtypedef GList_ptr0 (a:vwtp) = [f,r:nat] GList_ptr (a, f, r) viewtypedef GList_ptr1 (a:vwtp) = [f:nat;r:pos] GList_ptr (a, f, r) (* ****** ****** *) fun g_list_is_nil {a:vwtp} {l,r:nat} (list: !GList_ptr (a, l, r)): bool (r==0) = "atsctrb_g_list_is_nil" // end of [g_list_is_nil] fun g_list_isnot_nil {a:vwtp} {l,r:nat} (list: !GList_ptr (a, l, r)): bool (r > 0) = "atsctrb_g_list_isnot_nil" // end of [g_list_isnot_nil] (* ****** ****** *) fun g_list_new_nil {a:vwtp} (): GList_ptr (a, 0, 0) = "mac#atsctrb_g_list_new_nil" // end of [g_list_new_nil] fun g_list_free_nil {a:vwtp} (xs: GList_ptr (a, 0, 0)):<> void = "mac#atsctrb_g_list_free_nil" // end of [g_list_free_nil] (* ****** ****** *) fun g_list_free {a:vwtp} (list: GList_ptr0 (a?)): void = "mac#atsctrb_g_list_free" // end of [g_list] fun g_list_free1 {a:vwtp} (list: GList_ptr (a?, 0, 1)): void = "mac#atsctrb_g_list_free1" // end of [g_list_free11] (* ****** ****** *) fun g_list_next {a:vwtp} {f:nat;r:int | r >= 2} (list: GList_ptr (a, f, r)): GList_ptr (a, f+1, r-1) = "mac#atsctrb_g_list_next" // end of [g_list_next] fun g_list_previous {a:vwtp} {f:pos;r:nat} (list: GList_ptr (a, f, r)): GList_ptr (a, f-1, r+1) = "mac#atsctrb_g_list_previous" // end of [g_list_previous] fun g_list_last {a:vwtp} {f:nat;r:pos} (list: GList_ptr (a, f, r)): GList_ptr (a, f+r-1, 1) = "mac#atsctrb_g_list_last" // end of [g_list_last] fun g_list_first {a:vwtp} {f,r:nat} ( list: GList_ptr (a, f, r) ) : GList_ptr (a, 0, f+r) = "mac#atsctrb_g_list_first" // end of [g_list_first] (* ****** ****** *) // // HX: append at the far end // fun g_list_append {a:vwtp} {f,r:nat} ( // its complexity is O(n) list: GList_ptr (a, f, r), x: !a >> a?! ) : GList_ptr (a, f, r+1) = "mac#atsctrb_g_list_append" // end of [g_list_append] (* ****** ****** *) // // HX: insert at the current position // fun g_list_prepend {a:vwtp} {f,r:nat} ( // its complexity is O(1) list: GList_ptr (a, f, r), x: !a >> a?! ) : GList_ptr (a, f, r+1) = "mac#atsctrb_g_list_prepend" // end of [g_list_prepend] (* ****** ****** *) fun g_list_length {a:vwtp} {f,r:nat} (list: !GList_ptr (a, f, r)): gint r = "mac#atsctrb_g_list_length" // end of [g_list_length] (* ****** ****** *) fun g_list_insert_at {a:vwtp} {f,r:nat} {i:nat | i <= r} ( // its complexity is O(i) list: GList_ptr (a, f, r), x: !a >> a?!, i: gint i ) : GList_ptr (a, f, r+1) = "mac#atsctrb_g_list_insert" // end of [g_list_insert_at] fun g_list_insert_sorted {a:vwtp} {f,r:nat} ( // its complexity is O(n) list: GList_ptr (a, f, r), x: !a >> a?!, cmp: (!a, !a) - gint ) : GList_ptr (a, f, r+1) = "mac#atsctrb_g_list_insert_sorted" // end of [g_list_insert_sorted] (* ****** ****** *) fun g_list_remove_current {a:vwtp} {f,r:int | r > 0} ( list: GList_ptr (a, f, r), node: &ptr? >> GList_ptr (a, 0, 1) ) : GList_ptr (a, f, r-1) = "atsctrb_g_list_remove_current" (* ****** ****** *) fun g_list_concat {a:vwtp} {l1,r1:nat} {r2:nat} ( list1: GList_ptr (a, l1, r1), list2: GList_ptr (a, 0, r2) ) : GList_ptr (a, l1, r1+r2) = "mac#atsctrb_g_list_concat" // end of [g_list_concat] (* ****** ****** *) fun g_list_copy {a:type} {f,r:nat} (list: !GList_ptr (a, f, r)): GList_ptr (a, 0, r) = "mac#atsctrb_g_list_copy" // end of [g_list_copy] (* ****** ****** *) fun g_list_reverse {a:vwtp} {r:nat} (list: GList_ptr (a, 0, r)): GList_ptr (a, 0, r) = "mac#atsctrb_g_list_reverse" // end of [g_list_reverse] (* ****** ****** *) // // HX-2010-02-28: // these sorting functions are based on mergesort implementation // fun g_list_sort {a:vwtp} {r:nat} ( list: GList_ptr (a, 0, r), cmp: (!a, !a) - gint ) : GList_ptr (a, 0, r) = "mac#atsctrb_g_list_sort" // end of [g_list_sort] fun g_list_sort_with_data {a:vwtp} {vt:viewtype} {r:nat} ( list: GList_ptr (a, 0, r), cmp: (!a, !a, !vt) - gint, env: !vt ) : GList_ptr (a, 0, r) = "mac#atsctrb_g_list_sort_with_data" // end of [g_list_sort_with_data] (* ****** ****** *) fun g_list_foreach {a:vwtp} {vt:viewtype} {f,r:nat} ( list: !GList_ptr (a, f, r), f: (!a, !vt) - void, env: !vt ) : void = "mac#atsctrb_g_list_foreach" // end of [g_list_foreach] (* ****** ****** *) fun g_list_nth {a:vwtp} {f,r:nat} {i:nat | i < r} ( list: GList_ptr (a, f, r), i: int (i) ) : GList_ptr (a, f+i, r-i) = "mac#atsctrb_g_list_nth" // end of [g_list_nth] fun g_list_nth_data {a:type} {f,r:nat} ( list: !GList_ptr (a, f, r), i: natLt r ) : a = "mac#atsctrb_g_list_nth_data" // end of [g_list_nth_data] fun g_list_nth_prev {a:vwtp} {f,r:nat} {i:nat | i <= f} (list: GList_ptr (a, f, r), i: int i): GList_ptr (a, f-i, r+i) = "mac#atsctrb_g_list_nth" // end of [g_list_nth_prev] (* ****** ****** *) fun g_list_index {a:type} {f,r:nat} ( list: !GList_ptr (a, f, r), x: !a ) : [i:int | ~1 <= i; i < r] gint i = "mac#atsctrb_g_list_index" // end of [g_list_index] (* ****** ****** *) (* end of [glist.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gqsort.sats0000664000175000017500000000365512223166165022270 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gqsort.cats" %} (* ****** ****** *) // // HX-2010-02-27: only need for individual testing // staload "contrib/glib/SATS/gtypes.sats" // (* ****** ****** *) fun g_qsort_with_data {a:viewt@ype} {vt:viewtype} {n:nat} ( pbase: &(@[a][n]) , n: gint n , size: sizeof_t a , compare_func: GCompareDataFuncRef (a, vt) , env: !vt ) :<> void = "mac#atsctrb_g_qsort_with_data" // end of [g_qsort_with_data] (* ****** ****** *) (* end of [gqsort.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gmem.sats0000664000175000017500000000403412223166165021666 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "contrib/glib/CATS/glib/gmem.cats" %} // end of [%{#] (* ****** ****** *) absview gfree_v (l:addr) (* ****** ****** *) fun gptr_alloc {a:viewt@ype} (n: sizeof_t a) : [l:addr] (gfree_v l, a? @ l | ptr l) = "mac#atsctrb_gptr_alloc" // end of [gptr_alloc] fun gptr_free {a:viewt@ype} {l:addr} (pf1: gfree_v l, pf2: a? @ l | p: ptr l): void = "mac#atsctrb_g_free" // end of [gptr_free] (* ****** ****** *) castfn gstring_free_null (x: gstring null):<> ptr null fun gstring_free {l:addr} (x: gstring l): void = "mac#atsctrb_g_free" (* ****** ****** *) (* end of [gmem.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib/gtypes.sats0000664000175000017500000004741112223166165022262 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) // // HX-2010-02-27: // these are declared in glibconfig.h // abst@ype gint8 = $extype"gint8" abst@ype gint16 = $extype"gint16" abst@ype gint32 = $extype"gint32" abst@ype gint64 = $extype"gint64" abst@ype guint8 = $extype"guint8" abst@ype guint16 = $extype"guint16" abst@ype guint32 = $extype"guint32" abst@ype guint64 = $extype"guint64" (* ****** ****** *) macdef G_MININT8 = $extval (gint8, "G_MININT8") // = 0x80 macdef G_MAXINT8 = $extval (gint8, "G_MAXINT8") // = 0x7f macdef G_MAXUINT8 = $extval (guint8, "G_MAXUINT8") // = 0xff macdef G_MININT16 = $extval (gint16, "G_MININT16") // = 0x8000 macdef G_MAXINT16 = $extval (gint16, "G_MAXINT16") // = 0x7fff macdef G_MAXUINT16 = $extval (guint16, "G_MAXUINT16") // = 0xffff macdef G_MININT32 = $extval (gint32, "G_MININT32") // = 0x80000000 macdef G_MAXINT32 = $extval (gint32, "G_MAXINT32") // = 0x7fffffff macdef G_MAXUINT32 = $extval (guint32, "G_MAXUINT32") // = 0xffffffff macdef G_MININT64 = $extval (gint64, "G_MININT64") macdef G_MAXINT64 = $extval (gint64, "G_MAXINT64") macdef G_MAXUINT64 = $extval (guint64, "G_MAXUINT64") (* ****** ****** *) abst@ype gboolean (bool) = $extype"gboolean" typedef gboolean = [b:bool] gboolean (b) abst@ype gchar (c:char) = $extype"gchar" typedef gchar = [c:char] gchar (c) abst@ype guchar (c:char) = $extype"guchar" typedef guchar = [c:char] guchar (c) (* ****** ****** *) abst@ype gint (i:int) = $extype"gint" typedef gint = [i:int] gint i abst@ype guint (i:int) = $extype"guint" typedef guint = [i:nat] guint i (* ****** ****** *) abst@ype gshort = $extype"gshort" abst@ype gushort = $extype"gushort" (* ****** ****** *) abst@ype glong (i: int) = $extype"glong" typedef glong = [i:int] glong (i) abst@ype gulong (i:int) = $extype"gulong" typedef gulong = [i:nat] gulong (i) (* ****** ****** *) abst@ype gsize (i:int) = $extype"gsize" typedef gsize = [i:nat] gsize i abst@ype gssize (i:int) = $extype"gssize" typedef gssize = [i:int] gssize i (* ****** ****** *) abst@ype gfloat = $extype"gfloat" abst@ype gdouble = $extype"gdouble" (* ****** ****** *) abstype gpointer = $extype"gpointer" (* ****** ****** *) // typedef GCompareFunc (a:viewtype) = (!a, !a) - gint typedef GCompareFuncRef (a:viewt@ype) = (&a, &a) - gint // typedef GCompareDataFunc (a:viewtype, vt:viewtype) = (!a, !a, !vt) - gint typedef GCompareDataFuncRef (a:viewt@ype, vt:viewtype) = (&a, &a, !vt) - gint // typedef GEqualFunc (a:type) = (a, a) - gboolean // typedef GHashFunc (key:type) = (key) - guint typedef GHFunc (key:type, itm:type, vt:viewtype) = (key, itm, !vt) - void // (* ****** ****** *) (* #define G_E 2.7182818284590452353602874713526624977572470937000 #define G_LN2 0.69314718055994530941723212145817656807550013436026 #define G_LN10 2.3025850929940456840179914546843642076011014886288 #define G_PI 3.1415926535897932384626433832795028841971693993751 #define G_PI_2 1.5707963267948966192313216916397514420985846996876 #define G_PI_4 0.78539816339744830961566084581987572104929234984378 #define G_SQRT2 1.4142135623730950488016887242096980785696718753769 *) macdef G_E = $extval (gdouble , "G_E") macdef G_LN2 = $extval (gdouble , "G_LN2") macdef G_LN10 = $extval (gdouble , "G_LN10") macdef G_PI = $extval (gdouble , "G_PI") macdef G_PI_2 = $extval (gdouble , "G_PI_2") macdef G_PI_4 = $extval (gdouble , "G_PI_4") macdef G_SQRT2 = $extval (gdouble , "G_SQRT2") (* ****** ****** *) (* end of [gtypes.sats] *) //// /* GLIB - Library of useful routines for C programming * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ /* * Modified by the GLib Team and others 1997-2000. See the AUTHORS * file for a list of people on the GLib Team. See the ChangeLog * files for a list of changes. These files are distributed with * GLib at ftp://ftp.gtk.org/pub/gtk/. */ #ifndef __G_TYPES_H__ #define __G_TYPES_H__ #include G_BEGIN_DECLS /* Provide type definitions for commonly used types. * These are useful because a "gint8" can be adjusted * to be 1 byte (8 bits) on all platforms. Similarly and * more importantly, "gint32" can be adjusted to be * 4 bytes (32 bits) on all platforms. */ typedef char gchar; typedef short gshort; typedef long glong; typedef int gint; typedef gint gboolean; typedef unsigned char guchar; typedef unsigned short gushort; typedef unsigned long gulong; typedef unsigned int guint; typedef float gfloat; typedef double gdouble; /* Define min and max constants for the fixed size numerical types */ #define G_MININT8 ((gint8) 0x80) #define G_MAXINT8 ((gint8) 0x7f) #define G_MAXUINT8 ((guint8) 0xff) #define G_MININT16 ((gint16) 0x8000) #define G_MAXINT16 ((gint16) 0x7fff) #define G_MAXUINT16 ((guint16) 0xffff) #define G_MININT32 ((gint32) 0x80000000) #define G_MAXINT32 ((gint32) 0x7fffffff) #define G_MAXUINT32 ((guint32) 0xffffffff) #define G_MININT64 ((gint64) G_GINT64_CONSTANT(0x8000000000000000)) #define G_MAXINT64 G_GINT64_CONSTANT(0x7fffffffffffffff) #define G_MAXUINT64 G_GINT64_CONSTANT(0xffffffffffffffffU) typedef void* gpointer; typedef const void *gconstpointer; typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); typedef gint (*GCompareDataFunc) (gconstpointer a, gconstpointer b, gpointer user_data); typedef gboolean (*GEqualFunc) (gconstpointer a, gconstpointer b); typedef void (*GDestroyNotify) (gpointer data); typedef void (*GFunc) (gpointer data, gpointer user_data); typedef guint (*GHashFunc) (gconstpointer key); typedef void (*GHFunc) (gpointer key, gpointer value, gpointer user_data); typedef void (*GFreeFunc) (gpointer data); typedef const gchar * (*GTranslateFunc) (const gchar *str, gpointer data); /* Define some mathematical constants that aren't available * symbolically in some strict ISO C implementations. */ #define G_E 2.7182818284590452353602874713526624977572470937000 #define G_LN2 0.69314718055994530941723212145817656807550013436026 #define G_LN10 2.3025850929940456840179914546843642076011014886288 #define G_PI 3.1415926535897932384626433832795028841971693993751 #define G_PI_2 1.5707963267948966192313216916397514420985846996876 #define G_PI_4 0.78539816339744830961566084581987572104929234984378 #define G_SQRT2 1.4142135623730950488016887242096980785696718753769 /* Portable endian checks and conversions * * glibconfig.h defines G_BYTE_ORDER which expands to one of * the below macros. */ #define G_LITTLE_ENDIAN 1234 #define G_BIG_ENDIAN 4321 #define G_PDP_ENDIAN 3412 /* unused, need specific PDP check */ /* Basic bit swapping functions */ #define GUINT16_SWAP_LE_BE_CONSTANT(val) ((guint16) ( \ (guint16) ((guint16) (val) >> 8) | \ (guint16) ((guint16) (val) << 8))) #define GUINT32_SWAP_LE_BE_CONSTANT(val) ((guint32) ( \ (((guint32) (val) & (guint32) 0x000000ffU) << 24) | \ (((guint32) (val) & (guint32) 0x0000ff00U) << 8) | \ (((guint32) (val) & (guint32) 0x00ff0000U) >> 8) | \ (((guint32) (val) & (guint32) 0xff000000U) >> 24))) #define GUINT64_SWAP_LE_BE_CONSTANT(val) ((guint64) ( \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x00000000000000ffU)) << 56) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x000000000000ff00U)) << 40) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x0000000000ff0000U)) << 24) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x00000000ff000000U)) << 8) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x000000ff00000000U)) >> 8) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x0000ff0000000000U)) >> 24) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0x00ff000000000000U)) >> 40) | \ (((guint64) (val) & \ (guint64) G_GINT64_CONSTANT (0xff00000000000000U)) >> 56))) /* Arch specific stuff for speed */ #if defined (__GNUC__) && (__GNUC__ >= 2) && defined (__OPTIMIZE__) # if defined (__i386__) # define GUINT16_SWAP_LE_BE_IA32(val) \ (__extension__ \ ({ register guint16 __v, __x = ((guint16) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT16_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ ("rorw $8, %w0" \ : "=r" (__v) \ : "0" (__x) \ : "cc"); \ __v; })) # if !defined (__i486__) && !defined (__i586__) \ && !defined (__pentium__) && !defined (__i686__) \ && !defined (__pentiumpro__) && !defined (__pentium4__) # define GUINT32_SWAP_LE_BE_IA32(val) \ (__extension__ \ ({ register guint32 __v, __x = ((guint32) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ ("rorw $8, %w0\n\t" \ "rorl $16, %0\n\t" \ "rorw $8, %w0" \ : "=r" (__v) \ : "0" (__x) \ : "cc"); \ __v; })) # else /* 486 and higher has bswap */ # define GUINT32_SWAP_LE_BE_IA32(val) \ (__extension__ \ ({ register guint32 __v, __x = ((guint32) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ ("bswap %0" \ : "=r" (__v) \ : "0" (__x)); \ __v; })) # endif /* processor specific 32-bit stuff */ # define GUINT64_SWAP_LE_BE_IA32(val) \ (__extension__ \ ({ union { guint64 __ll; \ guint32 __l[2]; } __w, __r; \ __w.__ll = ((guint64) (val)); \ if (__builtin_constant_p (__w.__ll)) \ __r.__ll = GUINT64_SWAP_LE_BE_CONSTANT (__w.__ll); \ else \ { \ __r.__l[0] = GUINT32_SWAP_LE_BE (__w.__l[1]); \ __r.__l[1] = GUINT32_SWAP_LE_BE (__w.__l[0]); \ } \ __r.__ll; })) /* Possibly just use the constant version and let gcc figure it out? */ # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val)) # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_IA32 (val)) # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_IA32 (val)) # elif defined (__ia64__) # define GUINT16_SWAP_LE_BE_IA64(val) \ (__extension__ \ ({ register guint16 __v, __x = ((guint16) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT16_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ __volatile__ ("shl %0 = %1, 48 ;;" \ "mux1 %0 = %0, @rev ;;" \ : "=r" (__v) \ : "r" (__x)); \ __v; })) # define GUINT32_SWAP_LE_BE_IA64(val) \ (__extension__ \ ({ register guint32 __v, __x = ((guint32) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ __volatile__ ("shl %0 = %1, 32 ;;" \ "mux1 %0 = %0, @rev ;;" \ : "=r" (__v) \ : "r" (__x)); \ __v; })) # define GUINT64_SWAP_LE_BE_IA64(val) \ (__extension__ \ ({ register guint64 __v, __x = ((guint64) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT64_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ __volatile__ ("mux1 %0 = %1, @rev ;;" \ : "=r" (__v) \ : "r" (__x)); \ __v; })) # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA64 (val)) # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_IA64 (val)) # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_IA64 (val)) # elif defined (__x86_64__) # define GUINT32_SWAP_LE_BE_X86_64(val) \ (__extension__ \ ({ register guint32 __v, __x = ((guint32) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ ("bswapl %0" \ : "=r" (__v) \ : "0" (__x)); \ __v; })) # define GUINT64_SWAP_LE_BE_X86_64(val) \ (__extension__ \ ({ register guint64 __v, __x = ((guint64) (val)); \ if (__builtin_constant_p (__x)) \ __v = GUINT64_SWAP_LE_BE_CONSTANT (__x); \ else \ __asm__ ("bswapq %0" \ : "=r" (__v) \ : "0" (__x)); \ __v; })) /* gcc seems to figure out optimal code for this on its own */ # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_CONSTANT (val)) # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_X86_64 (val)) # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_X86_64 (val)) # else /* generic gcc */ # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_CONSTANT (val)) # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_CONSTANT (val)) # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_CONSTANT (val)) # endif #else /* generic */ # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_CONSTANT (val)) # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_CONSTANT (val)) # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_CONSTANT (val)) #endif /* generic */ #define GUINT16_SWAP_LE_PDP(val) ((guint16) (val)) #define GUINT16_SWAP_BE_PDP(val) (GUINT16_SWAP_LE_BE (val)) #define GUINT32_SWAP_LE_PDP(val) ((guint32) ( \ (((guint32) (val) & (guint32) 0x0000ffffU) << 16) | \ (((guint32) (val) & (guint32) 0xffff0000U) >> 16))) #define GUINT32_SWAP_BE_PDP(val) ((guint32) ( \ (((guint32) (val) & (guint32) 0x00ff00ffU) << 8) | \ (((guint32) (val) & (guint32) 0xff00ff00U) >> 8))) /* The G*_TO_?E() macros are defined in glibconfig.h. * The transformation is symmetric, so the FROM just maps to the TO. */ #define GINT16_FROM_LE(val) (GINT16_TO_LE (val)) #define GUINT16_FROM_LE(val) (GUINT16_TO_LE (val)) #define GINT16_FROM_BE(val) (GINT16_TO_BE (val)) #define GUINT16_FROM_BE(val) (GUINT16_TO_BE (val)) #define GINT32_FROM_LE(val) (GINT32_TO_LE (val)) #define GUINT32_FROM_LE(val) (GUINT32_TO_LE (val)) #define GINT32_FROM_BE(val) (GINT32_TO_BE (val)) #define GUINT32_FROM_BE(val) (GUINT32_TO_BE (val)) #define GINT64_FROM_LE(val) (GINT64_TO_LE (val)) #define GUINT64_FROM_LE(val) (GUINT64_TO_LE (val)) #define GINT64_FROM_BE(val) (GINT64_TO_BE (val)) #define GUINT64_FROM_BE(val) (GUINT64_TO_BE (val)) #define GLONG_FROM_LE(val) (GLONG_TO_LE (val)) #define GULONG_FROM_LE(val) (GULONG_TO_LE (val)) #define GLONG_FROM_BE(val) (GLONG_TO_BE (val)) #define GULONG_FROM_BE(val) (GULONG_TO_BE (val)) #define GINT_FROM_LE(val) (GINT_TO_LE (val)) #define GUINT_FROM_LE(val) (GUINT_TO_LE (val)) #define GINT_FROM_BE(val) (GINT_TO_BE (val)) #define GUINT_FROM_BE(val) (GUINT_TO_BE (val)) /* Portable versions of host-network order stuff */ #define g_ntohl(val) (GUINT32_FROM_BE (val)) #define g_ntohs(val) (GUINT16_FROM_BE (val)) #define g_htonl(val) (GUINT32_TO_BE (val)) #define g_htons(val) (GUINT16_TO_BE (val)) /* IEEE Standard 754 Single Precision Storage Format (gfloat): * * 31 30 23 22 0 * +--------+---------------+---------------+ * | s 1bit | e[30:23] 8bit | f[22:0] 23bit | * +--------+---------------+---------------+ * B0------------------->B1------->B2-->B3--> * * IEEE Standard 754 Double Precision Storage Format (gdouble): * * 63 62 52 51 32 31 0 * +--------+----------------+----------------+ +---------------+ * | s 1bit | e[62:52] 11bit | f[51:32] 20bit | | f[31:0] 32bit | * +--------+----------------+----------------+ +---------------+ * B0--------------->B1---------->B2--->B3----> B4->B5->B6->B7-> */ /* subtract from biased_exponent to form base2 exponent (normal numbers) */ typedef union _GDoubleIEEE754 GDoubleIEEE754; typedef union _GFloatIEEE754 GFloatIEEE754; #define G_IEEE754_FLOAT_BIAS (127) #define G_IEEE754_DOUBLE_BIAS (1023) /* multiply with base2 exponent to get base10 exponent (normal numbers) */ #define G_LOG_2_BASE_10 (0.30102999566398119521) #if G_BYTE_ORDER == G_LITTLE_ENDIAN union _GFloatIEEE754 { gfloat v_float; struct { guint mantissa : 23; guint biased_exponent : 8; guint sign : 1; } mpn; }; union _GDoubleIEEE754 { gdouble v_double; struct { guint mantissa_low : 32; guint mantissa_high : 20; guint biased_exponent : 11; guint sign : 1; } mpn; }; #elif G_BYTE_ORDER == G_BIG_ENDIAN union _GFloatIEEE754 { gfloat v_float; struct { guint sign : 1; guint biased_exponent : 8; guint mantissa : 23; } mpn; }; union _GDoubleIEEE754 { gdouble v_double; struct { guint sign : 1; guint biased_exponent : 11; guint mantissa_high : 20; guint mantissa_low : 32; } mpn; }; #else /* !G_LITTLE_ENDIAN && !G_BIG_ENDIAN */ #error unknown ENDIAN type #endif /* !G_LITTLE_ENDIAN && !G_BIG_ENDIAN */ typedef struct _GTimeVal GTimeVal; struct _GTimeVal { glong tv_sec; glong tv_usec; }; G_END_DECLS /* We prefix variable declarations so they can * properly get exported in windows dlls. */ #ifndef GLIB_VAR # ifdef G_PLATFORM_WIN32 # ifdef GLIB_STATIC_COMPILATION # define GLIB_VAR extern # else /* !GLIB_STATIC_COMPILATION */ # ifdef GLIB_COMPILATION # ifdef DLL_EXPORT # define GLIB_VAR __declspec(dllexport) # else /* !DLL_EXPORT */ # define GLIB_VAR extern # endif /* !DLL_EXPORT */ # else /* !GLIB_COMPILATION */ # define GLIB_VAR extern __declspec(dllimport) # endif /* !GLIB_COMPILATION */ # endif /* !GLIB_STATIC_COMPILATION */ # else /* !G_PLATFORM_WIN32 */ # define GLIB_VAR extern # endif /* !G_PLATFORM_WIN32 */ #endif /* GLIB_VAR */ #endif /* __G_TYPES_H__ */ ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib-object.sats0000664000175000017500000000665112223166165022214 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib-object.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload GLIB = "contrib/glib/SATS/glib.sats" stadef gboolean = $GLIB.gboolean stadef gint = $GLIB.gint stadef guint = $GLIB.guint stadef gpointer = $GLIB.gpointer (* ****** ****** *) // // HX: [gobjref]: reference-counted // absviewtype gobjref (c:cls, l:addr) // gobject pointer castfn ptr_of_gobjref {c:cls} {l:addr} (x: !gobjref (c, l)):<> ptr l overload ptr_of with ptr_of_gobjref (* ****** ****** *) classdec GObject // super: none classdec GInitiallyUnowned : GObject // HX: no floating reference in ATS classdec GInterface // super: none (* ****** ****** *) fun g_object_is_null {c:cls} {l:addr} (x: !gobjref (c, l)): bool (l == null) = "atspre_ptr_is_null" // end of [g_object_is_null] fun g_object_isnot_null {c:cls} {l:addr} (x: !gobjref (c, l)): bool (l > null) = "atspre_ptr_isnot_null" // end of [g_object_is_null] (* ****** ****** *) fun g_object_free_null {c:cls} (x: gobjref (c, null)):<> void = "atspre_ptr_free_null" // end of [g_object_free_null] (* ****** ****** *) // // HX-2010-04-13: this is unsafe but I cannot find a better means ... // castfn g_object_vref {c:cls} {l:addr} // vitural reference (x: !gobjref (c, l)):<> (gobjref (c, l) - void | gobjref (c, l)) // end of [g_object_vref] (* ****** ****** *) abstype GCallback // = () - void castfn G_CALLBACK {a:type} (x: a): GCallback // HX: unfortunately ... (* ****** ****** *) #include "contrib/glib/SATS/gobject/gsignal.sats" #include "contrib/glib/SATS/gobject/gobject.sats" (* ****** ****** *) (* end of [glib-object.sats] *) //// gobject: gboxed.h gobjectalias.h gtype.h gvaluecollector.h gclosure.h gparam.h gtypemodule.h gvaluetypes.h genums.h gparamspecs.h gtypeplugin.h stamp-gmarshal.h gmarshal.h gsignal.h gvalue.h gobject.h gsourceclosure.h gvaluearray.h ats-lang-anairiats-0.2.11/contrib/glib/SATS/glib.sats0000664000175000017500000000706212223166165020745 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) %{# #include "contrib/glib/CATS/glib.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) macdef GLIB_MAJOR_VERSION = $extval (int, "GLIB_MAJOR_VERSION") macdef GLIB_MINOR_VERSION = $extval (int, "GLIB_MINOR_VERSION") macdef GLIB_MICRO_VERSION = $extval (int, "GLIB_MICRO_VERSION") macdef GLIB_VERSION = 1000 * (1000 * GLIB_MAJOR_VERSION + GLIB_MINOR_VERSION) + GLIB_MICRO_VERSION // end of [GLIB_VERSION] (* ****** ****** *) #include "contrib/glib/SATS/glib/gtypes.sats" (* ****** ****** *) #include "contrib/glib/SATS/glib/gbasics.sats" (* ****** ****** *) #include "contrib/glib/SATS/glib/gmem.sats" (* ****** ****** *) #include "contrib/glib/SATS/glib/garray.sats" #include "contrib/glib/SATS/glib/ghash.sats" #include "contrib/glib/SATS/glib/glist.sats" #include "contrib/glib/SATS/glib/gqsort.sats" #include "contrib/glib/SATS/glib/grand.sats" #include "contrib/glib/SATS/glib/gslist.sats" #include "contrib/glib/SATS/glib/gstring.sats" #include "contrib/glib/SATS/glib/gutils.sats" #include "contrib/glib/SATS/glib/gunicode.sats" (* ****** ****** *) (* end of [glib.sats] *) //// glib: galloca.h gdate.h gmacros.h gqsort.h gstrfuncs.h garray.h gdir.h gmain.h gquark.h gstring.h gasyncqueue.h gerror.h gmappedfile.h gqueue.h gthread.h gatomic.h gfileutils.h gmarkup.h grand.h gthreadpool.h gbacktrace.h ghash.h gmem.h grel.h gtimer.h gbase64.h ghook.h gmessages.h gscanner.h gtree.h gbookmarkfile.h gi18n-lib.h gnode.h gshell.h gtypes.h gcache.h gi18n.h goption.h gslice.h gunicode.h gcompletion.h giochannel.h gpattern.h gslist.h gutils.h gconvert.h gkeyfile.h gprimes.h gspawn.h gwin32.h gdataset.h glist.h gprintf.h gstdio.h gobject: gboxed.h gobjectalias.h gtype.h gvaluecollector.h gclosure.h gparam.h gtypemodule.h gvaluetypes.h genums.h gparamspecs.h gtypeplugin.h stamp-gmarshal.h gmarshal.h gsignal.h gvalue.h gobject.h gsourceclosure.h gvaluearray.h ats-lang-anairiats-0.2.11/contrib/glib/SATS/gobject/0000700000175000017500000000000012223166165020530 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/SATS/gobject/gsignal.sats0000664000175000017500000000603512223166165023070 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abstype gsignal // gchar* castfn gsignal (x: string):<> gsignal macdef GSIGNAL_ACTIVATE = $extval (gsignal, "\"activate\"") macdef GSIGNAL_CLICKED = $extval (gsignal, "\"clicked\"") macdef GSIGNAL_DESTROY = $extval (gsignal, "\"destroy\"") macdef GSIGNAL_EVENT = $extval (gsignal, "\"event\"") macdef GSIGNAL_DELETE_EVENT = $extval (gsignal, "\"delete_event\"") (* ****** ****** *) fun g_signal_connect {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l) , sig: gsignal , handler: GCallback , data: gpointer ) : guint = "mac#atsctrb_g_signal_connect" // end of [g_signal_connect] (* ****** ****** *) fun g_signal_connect_after {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l) , sig: gsignal , handler: GCallback , data: gpointer ) : guint = "mac#atsctrb_g_signal_connect_after" // end of [g_signal_connect_after] (* ****** ****** *) fun g_signal_connect_swapped {c1,c2:cls | c1 <= GObject; c2 <= GObject} {l1,l2:agz} ( x: !gobjref (c1, l1) , sig: gsignal , handler: GCallback , data: !gobjref (c2, l2) ) : guint = "mac#atsctrb_g_signal_connect_swapped" // end of [g_signal_connect_swapped] (* ****** ****** *) fun g_signal_emit_by_name {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l), sig: gsignal ) : void = "mac#atsctrb_g_signal_emit_by_name" // end of [g_signal_emit_by_name] (* ****** ****** *) fun g_signal_stop_emission_by_name {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l), sig: gsignal ) : void = "mac#atsctrb_g_signal_stop_emission_by_name" // end of [g_signal_stop_emission_by_name] (* ****** ****** *) (* end of [gsignal.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/SATS/gobject/gobject.sats0000664000175000017500000000402512223166165023056 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun g_object_is_floating {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l) ) : bool = "mac#atsctrb_g_object_is_floating" (* ****** ****** *) fun g_object_ref_count {c:cls} {l:addr} ( x: !gobjref (c, l) ) : int = "mac#atsctrb_g_object_ref_count" (* ****** ****** *) fun g_object_ref {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l) ) : gobjref (c, l) = "mac#atsctrb_g_object_ref" fun g_object_unref {c:cls | c <= GObject} {l:agz} ( x: gobjref (c, l) ) : void = "mac#atsctrb_g_object_unref" (* ****** ****** *) (* end of [gobject.sats] *) ats-lang-anairiats-0.2.11/contrib/glib/Makefile0000664000175000017500000000151312223166165020015 0ustar hwxihwxi# # API for glib in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: February, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall GLIBCFLAGS = `pkg-config glib-2.0 --cflags` ###### GCC=gcc ###### all:: glibconfig all:: atsctrb_glib.o all:: clean ###### glibconfig: HATS/glibconfig_hats $(GCC) $(GLIBCFLAGS) -E -P -o HATS/glibconfig.hats -x c $< ###### atsctrb_glib.o: \ glib_sats.o glib_dats.o ld -r -o $@ \ glib_sats.o glib_dats.o ###### glib_sats.o: SATS/glib.sats $(ATSCC) $(GLIBCFLAGS) -o $@ -c SATS/glib.sats glib_dats.o: DATS/glib.dats $(ATSCC) $(GLIBCFLAGS) -o $@ -c DATS/glib.dats ###### clean:: rm -f glib_sats.c glib_sats.o rm -f glib_dats.c glib_dats.o cleanall: clean rm -f atsctrb_glib.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/glib/DATS/0000700000175000017500000000000012223166165017074 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/DATS/glib.dats0000664000175000017500000000425712223166165020712 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: February, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for static loading #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" (* ****** ****** *) implement{a} g_array_get_elt_at (array, i) = let val (pf, fpf | p) = g_array_takeout_tsz {a} (array, i, sizeof) val x = !p prval () = minus_addback (fpf, pf | array) in x end // end of [g_array_get_elt_at] implement{a} g_array_set_elt_at (array, i, x) = let val (pf, fpf | p) = g_array_takeout_tsz {a} (array, i, sizeof) val () = !p := x prval () = minus_addback (fpf, pf | array) in // nothing end // end of [g_array_set_elt_at] (* ****** ****** *) (* end of [glib.dats] *) ats-lang-anairiats-0.2.11/contrib/glib/HATS/0000700000175000017500000000000012223166165017100 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/glib/HATS/glibconfig.hats0000664000175000017500000000122112223166165022074 0ustar hwxihwxi(* typedef long int ptrdiff_t; typedef long unsigned int size_t; typedef int wchar_t; typedef signed char gint8; typedef unsigned char guint8; typedef signed short gint16; typedef unsigned short guint16; typedef signed int gint32; typedef unsigned int guint32; typedef signed long gint64; typedef unsigned long guint64; typedef signed long gssize; typedef unsigned long gsize; typedef gint64 goffset; typedef signed long gintptr; typedef unsigned long guintptr; typedef int GPid; *) #define ATSCTRB_GLIB_MAJOR_VERSION 2 #define ATSCTRB_GLIB_MINOR_VERSION 32 #define ATSCTRB_GLIB_MICRO_VERSION 3 #define ATSCTRB_GLIB_VERSION 1000 * (1000 * 2 + 32) + 3 ats-lang-anairiats-0.2.11/contrib/glib/HATS/glibconfig_hats0000664000175000017500000000373012223166165022164 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // /* ****** ****** */ #define __ATS(x) x /* ****** ****** */ (* // #define GLIB_COMPILATION 1 // #include // HX: gmacros.h may otherwise complain *) /* ****** ****** */ __ATS(#define ATSCTRB_GLIB_MAJOR_VERSION GLIB_MAJOR_VERSION) __ATS(#define ATSCTRB_GLIB_MINOR_VERSION GLIB_MINOR_VERSION) __ATS(#define ATSCTRB_GLIB_MICRO_VERSION GLIB_MICRO_VERSION) __ATS(#define ATSCTRB_GLIB_VERSION 1000 * (1000 * GLIB_MAJOR_VERSION + GLIB_MINOR_VERSION) + GLIB_MICRO_VERSION) /* ****** ****** */ /* end of [glibconfig] */ ats-lang-anairiats-0.2.11/contrib/cairo/0000700000175000017500000000000012223166165016521 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cairo/CATS/0000700000175000017500000000000012223166165017253 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cairo/CATS/cairo.cats0000664000175000017500000005373712223166165021257 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 /* ****** ****** */ #ifndef ATSCTRB_CAIRO_CAIRO_CATS #define ATSCTRB_CAIRO_CAIRO_CATS /* ****** ****** */ #include #include #include #include #include #include /* ****** ****** */ typedef ats_ref_type ats_cairo_ref ; typedef ats_ref_type ats_cairo_surface_ref ; typedef ats_ref_type ats_cairo_pattern_ref ; typedef ats_ref_type ats_cairo_font_face_ref ; typedef ats_ref_type ats_cairo_scaled_font_ref ; /* ****** ****** */ // // contexts for drawing // /* ****** ****** */ #define atsctrb_cairo_create cairo_create /* ****** ****** */ #define atsctrb_cairo_status cairo_status #define atsctrb_cairo_reference cairo_reference #define atsctrb_cairo_destroy cairo_destroy #define atsctrb_cairo_get_reference_count cairo_get_reference_count /* ****** ****** */ #define atsctrb_cairo_save cairo_save #define atsctrb_cairo_restore cairo_restore /* ****** ****** */ #define atsctrb_cairo_get_target cairo_get_target #define atsctrb_cairo_get_group_target cairo_get_group_target /* ****** ****** */ #define atsctrb_cairo_push_group cairo_push_group #define atsctrb_cairo_push_group_with_content cairo_push_group_with_content #define atsctrb_cairo_pop_group cairo_pop_group #define atsctrb_cairo_pop_group_to_source cairo_pop_group_to_source /* ****** ****** */ #define atsctrb_cairo_set_source_rgb cairo_set_source_rgb #define atsctrb_cairo_set_source_rgba cairo_set_source_rgba /* ****** ****** */ #define atsctrb_cairo_get_source cairo_get_source #define atsctrb_cairo_set_source cairo_set_source #define atsctrb_cairo_set_source_surface cairo_set_source_surface /* ****** ****** */ #define atsctrb_cairo_get_antialias cairo_get_antialias #define atsctrb_cairo_set_antialias cairo_set_antialias /* ****** ****** */ #if (CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1,4,0)) #define atsctrb_cairo_get_dash_count cairo_get_dash_count ATSinline() ats_int_type atsctrb_cairo_get_dash ( ats_cairo_ref cr , ats_ptr_type dashes, ats_int_type n , ats_ptr_type offset ) { int n1 = cairo_get_dash_count((cairo_t*)cr) ; if (n1 <= n) { cairo_get_dash((cairo_t*)cr, (double*)dashes, (double*)offset) ; } else { cairo_get_dash((cairo_t*)cr, (double*)0, (double*)offset) ; } // end of [if] return n1 ; } // end of [atsctrb_cairo_get_dash] #define atsctrb_cairo_set_dash cairo_set_dash #endif // end of [#if (CAIRO_VERSION >= 1.4.0)] /* ****** ****** */ #define atsctrb_cairo_get_fill_rule cairo_get_fill_rule #define atsctrb_cairo_set_fill_rule cairo_set_fill_rule /* ****** ****** */ #define atsctrb_cairo_get_line_cap cairo_get_line_cap #define atsctrb_cairo_set_line_cap cairo_set_line_cap /* ****** ****** */ #define atsctrb_cairo_get_line_join cairo_get_line_join #define atsctrb_cairo_set_line_join cairo_set_line_join /* ****** ****** */ #define atsctrb_cairo_get_line_width cairo_get_line_width #define atsctrb_cairo_set_line_width cairo_set_line_width /* ****** ****** */ #define atsctrb_cairo_get_miter_limit cairo_get_miter_limit #define atsctrb_cairo_set_miter_limit cairo_set_miter_limit /* ****** ****** */ #define atsctrb_cairo_get_operator cairo_get_operator #define atsctrb_cairo_set_operator cairo_set_operator /* ****** ****** */ #define atsctrb_cairo_get_tolerance cairo_get_tolerance #define atsctrb_cairo_set_tolerance cairo_set_tolerance /* ****** ****** */ #if (CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1,4,0)) #define atsctrb_cairo_rectangle_list_destroy cairo_rectangle_list_destroy #define atsctrb_cairo_copy_clip_rectangle_list cairo_copy_clip_rectangle_list #endif // end of [#if (CAIRO_VERSION >= 1.4.0)] /* ****** ****** */ #define atsctrb_cairo_clip cairo_clip #define atsctrb_cairo_clip_preserve cairo_clip_preserve #define atsctrb_cairo_clip_extents cairo_clip_extents #define atsctrb_cairo_reset_clip cairo_reset_clip /* ****** ****** */ #define atsctrb_cairo_fill cairo_fill #define atsctrb_cairo_fill_preserve cairo_fill_preserve #define atsctrb_cairo_fill_extents cairo_fill_extents #define atsctrb_cairo_in_fill cairo_in_fill /* ****** ****** */ #define atsctrb_cairo_mask cairo_mask #define atsctrb_cairo_mask_surface cairo_mask_surface /* ****** ****** */ #define atsctrb_cairo_paint cairo_paint #define atsctrb_cairo_paint_with_alpha cairo_paint_with_alpha /* ****** ****** */ #define atsctrb_cairo_stroke cairo_stroke #define atsctrb_cairo_stroke_preserve cairo_stroke_preserve #define atsctrb_cairo_stroke_extents cairo_stroke_extents #define atsctrb_cairo_in_stroke atsctrb_cairo_in_stroke /* ****** ****** */ #define atsctrb_cairo_copy_page cairo_copy_page #define atsctrb_cairo_show_page cairo_show_page /* ****** ****** */ #if (CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1,4,0)) #define atsctrb_cairo_get_user_data cairo_get_user_data #define atsctrb_cairo_set_user_data cairo_set_user_data #endif // end of [#if (CAIRO_VERSION >= 1.4.0)] /* ****** ****** */ // // drawing paths // /* ****** ****** */ #define atsctrb_cairo_copy_path cairo_copy_path #define atsctrb_cairo_copy_path_flat cairo_copy_path_flat #define atsctrb_cairo_append_path cairo_append_path #define atsctrb_cairo_path_destroy cairo_path_destroy /* ****** ****** */ #define atsctrb_cairo_has_current_point cairo_has_current_point #define atsctrb_cairo_get_current_point cairo_get_current_point /* ****** ****** */ #define atsctrb_cairo_new_path cairo_new_path #define atsctrb_cairo_new_sub_path cairo_new_sub_path #define atsctrb_cairo_close_path cairo_close_path /* ****** ****** */ #define atsctrb_cairo_arc cairo_arc #define atsctrb_cairo_arc_negative cairo_arc_negative #define atsctrb_cairo_curve_to cairo_curve_to #define atsctrb_cairo_line_to cairo_line_to #define atsctrb_cairo_move_to cairo_move_to #define atsctrb_cairo_rectangle cairo_rectangle /* ****** ****** */ #define atsctrb_cairo_rel_curve_to cairo_rel_curve_to #define atsctrb_cairo_rel_line_to cairo_rel_line_to #define atsctrb_cairo_rel_move_to cairo_rel_move_to /* ****** ****** */ #define atsctrb_cairo_path_extents cairo_path_extents /* ****** ****** */ // // patterns for drawing // #define atsctrb_cairo_pattern_create_rgb cairo_pattern_create_rgb #define atsctrb_cairo_pattern_create_rgba cairo_pattern_create_rgba #define atsctrb_cairo_pattern_get_rgba cairo_pattern_get_rgba #define atsctrb_cairo_pattern_create_for_surface cairo_pattern_create_for_surface #define atsctrb_cairo_pattern_get_surface cairo_pattern_get_surface #define atsctrb_cairo_pattern_create_linear cairo_pattern_create_linear #define atsctrb_cairo_pattern_get_linear_points cairo_pattern_get_linear_points #define atsctrb_cairo_pattern_create_radial cairo_pattern_create_radial #define atsctrb_cairo_pattern_get_radial_circles cairo_pattern_get_radial_circles #define atsctrb_cairo_pattern_status cairo_pattern_status #define atsctrb_cairo_pattern_reference cairo_pattern_reference #define atsctrb_cairo_pattern_destroy cairo_pattern_destroy #define atsctrb_cairo_pattern_get_reference_count cairo_pattern_get_reference_count #define atsctrb_cairo_pattern_get_type cairo_pattern_get_type #define atsctrb_cairo_pattern_add_color_stop_rgb cairo_pattern_add_color_stop_rgb #define atsctrb_cairo_pattern_add_color_stop_rgba cairo_pattern_add_color_stop_rgba #define atsctrb_cairo_pattern_get_color_stop_count cairo_pattern_get_color_stop_count #define atsctrb_cairo_pattern_get_color_stop_rgba cairo_pattern_get_color_stop_rgba #define atsctrb_cairo_pattern_get_extend cairo_pattern_get_extend #define atsctrb_cairo_pattern_set_extend cairo_pattern_set_extend #define atsctrb_cairo_pattern_get_filter cairo_pattern_get_filter #define atsctrb_cairo_pattern_set_filter cairo_pattern_set_filter #define atsctrb_cairo_pattern_get_matrix cairo_pattern_get_matrix #define atsctrb_cairo_pattern_set_matrix cairo_pattern_set_matrix #if (CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1,4,0)) #define atsctrb_cairo_pattern_get_user_data cairo_pattern_get_user_data #define atsctrb_cairo_pattern_set_user_data cairo_pattern_set_user_data #endif // end of [#if (CAIRO_VERSION >= 1.4.0)] /* ****** ****** */ // // drawing texts // /* ****** ****** */ #define atsctrb_cairo_select_font_face cairo_select_font_face #define atsctrb_cairo_set_font_size cairo_set_font_size /* ****** ****** */ #define atsctrb_cairo_get_font_matrix cairo_get_font_matrix #define atsctrb_cairo_set_font_matrix cairo_set_font_matrix /* ****** ****** */ #define atsctrb_cairo_get_font_options cairo_get_font_options #define atsctrb_cairo_set_font_options cairo_set_font_options /* ****** ****** */ #define atsctrb_cairo_get_font_face cairo_get_font_face #define atsctrb_cairo_set_font_face cairo_set_font_face /* ****** ****** */ #define atsctrb_cairo_font_extents cairo_font_extents #define atsctrb_cairo_text_extents cairo_text_extents #define atsctrb_cairo_glyph_extents cairo_glyph_extents /* ****** ****** */ #define atsctrb_cairo_text_path cairo_text_path #define atsctrb_cairo_glyph_path cairo_glyph_path /* ****** ****** */ #define atsctrb_cairo_show_text cairo_show_text #define atsctrb_cairo_show_glyphs cairo_show_glyphs /* ****** ****** */ #define atsctrb_cairo_toy_font_face_create cairo_toy_font_face_create #define atsctrb_cairo_toy_font_face_get_family cairo_toy_font_face_get_family #define atsctrb_cairo_toy_font_face_get_slant cairo_toy_font_face_get_slant #define atsctrb_cairo_toy_font_face_get_weight cairo_toy_font_face_get_weight /* ****** ****** */ #if (CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1,8,0)) #define atsctrb_cairo_glyph_allocate cairo_glyph_allocate #define atsctrb_cairo_glyph_free cairo_glyph_free #define atsctrb_cairo_cluster_allocate cairo_cluster_allocate #define atsctrb_cairo_cluster_free cairo_cluster_free #endif // end of [#if (CAIRO_VERSION >= 1.8.0)] /* ****** ****** */ // // transformations for drawing // /* ****** ****** */ #define atsctrb_cairo_translate cairo_translate #define atsctrb_cairo_scale cairo_scale #define atsctrb_cairo_rotate cairo_rotate #define atsctrb_cairo_transform cairo_transform /* ****** ****** */ #define atsctrb_cairo_get_matrix cairo_get_matrix #define atsctrb_cairo_set_matrix cairo_set_matrix #define atsctrb_cairo_identity_matrix cairo_identity_matrix /* ****** ****** */ #define atsctrb_cairo_user_to_device cairo_user_to_device #define atsctrb_cairo_user_to_device_distance cairo_user_to_device_distance #define atsctrb_cairo_device_to_user cairo_device_to_user #define atsctrb_cairo_device_to_user_distance cairo_device_to_user_distance /* ****** ****** */ // // fonts for drawing // #define atsctrb_cairo_font_face_status cairo_font_face_status #define atsctrb_cairo_font_face_reference cairo_font_face_reference #define atsctrb_cairo_font_face_destroy cairo_font_face_destroy #define atsctrb_cairo_font_face_get_reference_count cairo_font_face_get_reference_count typedef cairo_font_type_t ats_cairo_font_type_type ; #define atsctrb_cairo_font_face_get_type cairo_font_face_get_type /* ****** ****** */ // // scaled fonts // #define atsctrb_cairo_scaled_font_status cairo_scaled_font_status #define atsctrb_cairo_scaled_font_reference cairo_scaled_font_reference #define atsctrb_cairo_scaled_font_destroy cairo_scaled_font_destroy #define atsctrb_cairo_scaled_font_get_reference_count cairo_scaled_font_get_reference_count #define atsctrb_cairo_scaled_font_extents cairo_scaled_font_extents #define atsctrb_cairo_scaled_font_text_extents cairo_scaled_font_text_extents #define atsctrb_cairo_scaled_font_get_font_face cairo_scaled_font_get_font_face #define atsctrb_cairo_scaled_font_get_font_options cairo_scaled_font_get_font_options #define atsctrb_cairo_scaled_font_get_font_matrix cairo_scaled_font_get_font_matrix #define atsctrb_cairo_scaled_font_get_ctm cairo_scaled_font_get_ctm #define atsctrb_cairo_scaled_font_get_scale_matrix cairo_scaled_font_get_scale_matrix #define atsctrb_cairo_scaled_font_get_type cairo_scaled_font_get_type /* ****** ****** */ // // font options // #define atsctrb_cairo_font_options_create cairo_font_options_create #define atsctrb_cairo_font_options_copy cairo_font_options_copy #define atsctrb_cairo_font_options_destroy cairo_font_options_destroy #define atsctrb_cairo_font_options_status cairo_font_options_status #define atsctrb_cairo_font_options_merge cairo_font_options_merge #define atsctrb_cairo_font_options_hash cairo_font_options_hash #define atsctrb_cairo_font_options_equal cairo_font_options_equal #define atsctrb_cairo_font_options_get_antialias cairo_font_options_get_antialias #define atsctrb_cairo_font_options_set_antialias cairo_font_options_set_antialias #define atsctrb_cairo_font_options_get_subpixel_order cairo_font_options_get_subpixel_order #define atsctrb_cairo_font_options_set_subpixel_order cairo_font_options_set_subpixel_order #define atsctrb_cairo_font_options_get_hint_style cairo_font_options_get_hint_style #define atsctrb_cairo_font_options_set_hint_style cairo_font_options_set_hint_style #define atsctrb_cairo_font_options_get_hint_metrics cairo_font_options_get_hint_metrics #define atsctrb_cairo_font_options_set_hint_metrics cairo_font_options_set_hint_metrics /* ****** ****** */ // // Support for FreeType Font // #define atsctrb_cairo_ft_font_face_create_for_ft_face cairo_ft_font_face_create_for_ft_face #define atsctrb_cairo_ft_font_face_create_for_pattern cairo_ft_font_face_create_for_pattern #define atsctrb_cairo_ft_font_options_substitute cairo_ft_font_options_substitute #define atsctrb_cairo_ft_scaled_font_lock_face cairo_ft_scaled_font_lock_face #define atsctrb_cairo_ft_scaled_font_unlock_face cairo_ft_scaled_font_unlock_face /* ****** ****** */ // // surfaces for drawing // #define atsctrb_cairo_surface_create_similar cairo_surface_create_similar #define atsctrb_cairo_surface_status cairo_surface_status #define atsctrb_cairo_surface_reference cairo_surface_reference #define atsctrb_cairo_surface_destroy cairo_surface_destroy #define atsctrb_cairo_surface_get_reference_count cairo_surface_get_reference_count #define atsctrb_cairo_surface_finish cairo_surface_finish #define atsctrb_cairo_surface_flush cairo_surface_flush #define atsctrb_cairo_surface_get_font_options cairo_surface_get_font_options #define atsctrb_cairo_surface_get_content cairo_surface_get_content #define atsctrb_cairo_surface_mark_dirty cairo_surface_mark_dirty #define atsctrb_cairo_surface_mark_dirty_rectangle cairo_surface_mark_dirty_rectangle #define atsctrb_cairo_get_device_offset cairo_get_device_offset #define atsctrb_cairo_set_device_offset cairo_set_device_offset #define atsctrb_cairo_surface_get_type cairo_surface_get_type #define atsctrb_cairo_surface_copy_page cairo_surface_copy_page #define atsctrb_cairo_surface_show_page cairo_surface_show_page /* ****** ****** */ // image surface typedef cairo_format_t ats_cairo_format_type ; #define atsctrb_cairo_format_stride_for_width cairo_format_stride_for_width #define atsctrb_cairo_image_surface_create cairo_image_surface_create #define atsctrb_cairo_image_surface_create_for_data cairo_image_surface_create_for_data #define atsctrb_cairo_image_surface_get_data cairo_image_surface_get_data #define atsctrb_cairo_image_surface_get_format cairo_image_surface_get_format #define atsctrb_cairo_image_surface_get_width cairo_image_surface_get_width #define atsctrb_cairo_image_surface_get_height cairo_image_surface_get_height #define atsctrb_cairo_image_surface_get_stride cairo_image_surface_get_stride /* ****** ****** */ // PNG support #define atsctrb_cairo_image_surface_create_from_png cairo_image_surface_create_from_png #define atsctrb_cairo_image_surface_create_from_png_stream cairo_image_surface_create_from_png_stream #define atsctrb_cairo_surface_write_to_png cairo_surface_write_to_png #define atsctrb_cairo_surface_write_to_png_stream cairo_surface_write_to_png_stream /* ****** ****** */ // PDF surface #if (CAIRO_HAS_PDF_SURFACE) #define atsctrb_cairo_pdf_surface_create cairo_pdf_surface_create static inline ats_ref_type atsctrb_cairo_pdf_surface_create_null ( ats_double_type width, ats_double_type height ) { return cairo_pdf_surface_create((char*)0, width, height) ; } // end of [atsctrb_cairo_pdf_surface_create_null] #define atsctrb_cairo_pdf_surface_create_for_stream cairo_pdf_surface_create_for_stream #define atsctrb_cairo_pdf_surface_set_size cairo_pdf_surface_set_size #endif // end of [CAIRO_HAS_PDF_SURFACE] /* ****** ****** */ // PS surface #if (CAIRO_HAS_PS_SURFACE) #define atsctrb_cairo_ps_surface_create cairo_ps_surface_create static inline ats_ref_type atsctrb_cairo_ps_surface_create_null ( ats_double_type width, ats_double_type height ) { return cairo_ps_surface_create((char*)0, width, height) ; } // end of [atsctrb_cairo_ps_surface_create_null] #define atsctrb_cairo_ps_surface_create_for_stream \ cairo_ps_surface_create_for_stream /* typedef cairo_ps_level_t ats_cairo_ps_level_type ; ats_ref_type atsctrb_cairo_ps_get_levels (ats_ref_type num_levels) { cairo_ps_level_t **p_levels ; cairo_ps_get_levels (p_levels, (int*)num_levels) ; return (ats_ref_type)(*p_levels) ; } // end of [cairo_ps_get_levels] */ #define atsctrb_cairo_ps_surface_set_size \ cairo_ps_surface_set_size #define atsctrb_cairo_ps_surface_dsc_begin_setup \ cairo_ps_surface_dsc_begin_setup #define atsctrb_cairo_ps_surface_dsc_begin_page_setup \ cairo_ps_surface_dsc_begin_page_setup #define atsctrb_cairo_ps_surface_dsc_comment \ cairo_ps_surface_dsc_comment #endif // end of [CAIRO_HAS_PS_SURFACE] /* ****** ****** */ #if (CAIRO_HAS_SVG_SURFACE) #define atsctrb_cairo_svg_surface_create \ cairo_svg_surface_create #define atsctrb_cairo_svg_surface_create_for_stream \ cairo_svg_surface_create_for_stream #define atsctrb_cairo_svg_surface_restrict_to_version \ cairo_svg_surface_restrict_to_version static inline ats_ref_type // array of versions atsctrb_cairo_svg_get_versions (ats_ref_type n) { cairo_svg_version_t const **versions ; cairo_svg_get_versions(versions, (int*)n) ; return (ats_ref_type)(*versions) ; } // end of [atsctrb_cairo_svg_get_versions] #define atsctrb_cairo_svg_version_to_string cairo_svg_version_to_string #endif // end of [CAIRO_HAS_SVG_SURFACE] /* ****** ****** */ #if (CAIRO_HAS_QUARTZ_SURFACE) #define atsctrb_cairo_quartz_surface_create \ cairo_quartz_surface_create #define atsctrb_cairo_quartz_surface_create_for_cg_context \ cairo_quartz_surface_create_for_cg_context #define atsctrb_cairo_quartz_surface_get_cg_context \ cairo_quartz_surface_get_cg_context #endif // end of [CAIRO_HAS_QUARTZ_SURFACE] /* ****** ****** */ #if (CAIRO_HAS_XLIB_SURFACE) #define atsctrb_cairo_xlib_surface_create \ cairo_xlib_surface_create #define atsctrb_cairo_xlib_surface_create_for_bitmap \ cairo_xlib_surface_create_for_bitmap #define atsctrb_cairo_xlib_surface_set_size \ cairo_xlib_surface_set_size #define atsctrb_cairo_xlib_surface_get_drawable \ cairo_xlib_surface_get_drawable #define atsctrb_cairo_xlib_surface_set_drawable \ cairo_xlib_surface_set_drawable #define atsctrb_cairo_xlib_surface_get_display cairo_xlib_surface_get_display #define atsctrb_cairo_xlib_surface_get_screen cairo_xlib_surface_get_screen #define atsctrb_cairo_xlib_surface_get_visual cairo_xlib_surface_get_visual #define atsctrb_cairo_xlib_surface_get_width cairo_xlib_surface_get_width #define atsctrb_cairo_xlib_surface_get_height cairo_xlib_surface_get_height #define atsctrb_cairo_xlib_surface_get_depth cairo_xlib_surface_get_depth #endif // end of [CAIRO_HAS_XLIB_SURFACE] /* ****** ****** */ // // utilities for drawing // /* ****** ****** */ // generic matrix operations #define atsctrb_cairo_matrix_init cairo_matrix_init #define atsctrb_cairo_matrix_init_identity cairo_matrix_init_identity #define atsctrb_cairo_matrix_init_translate cairo_matrix_init_translate #define atsctrb_cairo_matrix_init_scale cairo_matrix_init_scale #define atsctrb_cairo_matrix_init_rotate cairo_matrix_init_rotate /* ****** ****** */ #define atsctrb_cairo_matrix_translate cairo_matrix_translate #define atsctrb_cairo_matrix_scale cairo_matrix_scale #define atsctrb_cairo_matrix_rotate cairo_matrix_rotate /* ****** ****** */ #define atsctrb_cairo_matrix_invert cairo_matrix_invert #define atsctrb_cairo_matrix_multiply cairo_matrix_multiply #define atsctrb_cairo_matrix_transform_distance cairo_matrix_transform_distance #define atsctrb_cairo_matrix_transform_point cairo_matrix_transform_point /* ****** ****** */ #define atsctrb_cairo_status_to_string cairo_status_to_string #define atsctrb_cairo_debug_reset_static_data cairo_debug_reset_static_data /* ****** ****** */ // // cairo version macros and functions // #define atsctrb_cairo_version cairo_version static inline ats_ptr_type // string atsctrb_cairo_version_string () { return (ats_ptr_type)cairo_version_string() ; } // end of [atsctrb_cairo_version_string] /* ****** ****** */ #endif // end of [ATSCTRB_CAIRO_CAIRO_CATS] /* end of [cairo.cats] */ ats-lang-anairiats-0.2.11/contrib/cairo/SATS/0000700000175000017500000000000012223166165017273 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cairo/SATS/cairo_extra.sats0000664000175000017500000000406712223166165022512 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: July, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) typedef rgb = @{ r= double, g= double, b= double } // end of [rgb] typedef rgba = @{ r= double, g= double, b= double, a= double } // end of [rgb] (* ****** ****** *) // // HX-2010-07-21: showing text in the middle of a given box // fun cairo_show_text_inbox {l:agz} ( cr: !cairo_ref l, width :double, height :double, utf8: string ) : void // end of [cairo_show_text_inbox] (* ****** ****** *) (* end of [cairo_extra.sats] *) ats-lang-anairiats-0.2.11/contrib/cairo/SATS/cairo.sats0000664000175000017500000020261112223166165021302 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 // (* ****** ****** *) // // API for cairo in ATS // (* ****** ****** *) %{# #include "contrib/cairo/CATS/cairo.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // [cairo_bool_t] and [bool] are the same // (* ****** ****** *) // // a reference to cairo drawing context // // [cairo_ref] is reference counted absviewtype cairo_ref (l:addr) // cairo_t* viewtypedef cairo_ref1 = [l:addr | l > null] cairo_ref l // [cairo_surface_ref] is reference counted absviewtype cairo_surface_ref (l:addr) // = cairo_surface_t* viewtypedef cairo_surface_ref1 = [l:addr | l > null] cairo_surface_ref l // [cairo_pattern_ref] is reference counted absviewtype cairo_pattern_ref (l:addr) // = cairo_pattern_t* viewtypedef cairo_pattern_ref1 = [l:addr | l > null] cairo_pattern_ref l // [cairo_font_face_ref] is reference counted absviewtype cairo_font_face_ref (l:addr) // = cairo_font_face_t* viewtypedef cairo_font_face_ref1 = [l:addr | l > null] cairo_font_face_ref l // [cairo_font_options_ptr] is not reference counted absviewtype cairo_font_options_ptr (l:addr) // = cairo_font_options_ptr viewtypedef cairo_font_options_ptr1 = [l:addr | l > null] cairo_font_options_ptr l (* ****** ****** *) abst@ype cairo_matrix_t = $extype"cairo_matrix_t" (* ****** ****** *) // // enum type // abst@ype cairo_status_t = $extype"cairo_status_t" macdef CAIRO_STATUS_SUCCESS = $extval (cairo_status_t, "CAIRO_STATUS_SUCCESS") macdef CAIRO_STATUS_NO_MEMORY = $extval (cairo_status_t, "CAIRO_STATUS_NO_MEMORY") macdef CAIRO_STATUS_INVALID_RESTORE = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_RESTORE") macdef CAIRO_STATUS_INVALID_POP_GROUP = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_POP_GROUP") macdef CAIRO_STATUS_NO_CURRENT_POINT = $extval (cairo_status_t, "CAIRO_STATUS_NO_CURRENT_POINT") macdef CAIRO_STATUS_INVALID_MATRIX = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_MATRIX") macdef CAIRO_STATUS_INVALID_STATUS = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_STATUS") macdef CAIRO_STATUS_NULL_POINTER = $extval (cairo_status_t, "CAIRO_STATUS_NULL_POINTER") macdef CAIRO_STATUS_INVALID_STRING = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_STRING") macdef CAIRO_STATUS_INVALID_PATH_DATA = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_PATH_DATA") macdef CAIRO_STATUS_READ_ERROR = $extval (cairo_status_t, "CAIRO_STATUS_READ_ERROR") macdef CAIRO_STATUS_WRITE_ERROR = $extval (cairo_status_t, "CAIRO_STATUS_WRITE_ERROR") macdef CAIRO_STATUS_SURFACE_FINISHED = $extval (cairo_status_t, "CAIRO_STATUS_SURFACE_FINISHED") macdef CAIRO_STATUS_SURFACE_TYPE_MISMATCH = $extval (cairo_status_t, "CAIRO_STATUS_SURFACE_TYPE_MISMATCH") macdef CAIRO_STATUS_PATTERN_TYPE_MISMATCH = $extval (cairo_status_t, "CAIRO_STATUS_PATTERN_TYPE_MISMATCH") macdef CAIRO_STATUS_INVALID_CONTENT = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_CONTENT") macdef CAIRO_STATUS_INVALID_FORMAT = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_FORMAT") macdef CAIRO_STATUS_INVALID_VISUAL = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_VISUAL") macdef CAIRO_STATUS_FILE_NOT_FOUND = $extval (cairo_status_t, "CAIRO_STATUS_FILE_NOT_FOUND") macdef CAIRO_STATUS_INVALID_DASH = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_DASH") macdef CAIRO_STATUS_INVALID_DSC_COMMENT = $extval (cairo_status_t, "CAIRO_STATUS_INVALID_DSC_COMMENT") castfn int_of_cairo_status (x: cairo_status_t):<> int overload int_of with int_of_cairo_status fun eq_cairo_status_cairo_status ( x1: cairo_status_t, x2: cairo_status_t ) :<> bool = "mac#atspre_eq_int_int" overload = with eq_cairo_status_cairo_status fun neq_cairo_status_cairo_status ( x1: cairo_status_t, x2: cairo_status_t ) :<> bool = "mac#atspre_neq_int_int" overload <> with neq_cairo_status_cairo_status overload != with neq_cairo_status_cairo_status (* ****** ****** *) // // enum type // abst@ype cairo_format_t = $extype"cairo_format_t" macdef CAIRO_FORMAT_ARGB32 = $extval (cairo_format_t, "CAIRO_FORMAT_ARGB32") macdef CAIRO_FORMAT_RGB24 = $extval (cairo_format_t, "CAIRO_FORMAT_RGB24") macdef CAIRO_FORMAT_A8 = $extval (cairo_format_t, "CAIRO_FORMAT_A8") macdef CAIRO_FORMAT_A1 = $extval (cairo_format_t, "CAIRO_FORMAT_A1") (* macdef CAIRO_FORMAT_RGB16_565 = // deprecated! $extval (cairo_format_t, "CAIRO_FORMAT_RGB16_565") *) castfn int_of_cairo_format (x: cairo_format_t):<> int overload int_of with int_of_cairo_format fun eq_cairo_format_cairo_format (x1: cairo_format_t, x2: cairo_format_t):<> bool = "mac#atspre_eq_int_int" overload = with eq_cairo_format_cairo_format (* ****** ****** *) // // enum type // abst@ype cairo_content_t = $extype"cairo_content_t" macdef CAIRO_CONTENT_COLOR = $extval (cairo_content_t, "CAIRO_CONTENT_COLOR") macdef CAIRO_CONTENT_ALPHA = $extval (cairo_content_t, "CAIRO_CONTENT_ALPHA") macdef CAIRO_CONTENT_COLOR_ALPHA = $extval (cairo_content_t, "CAIRO_CONTENT_COLOR_ALPHA") (* ****** ****** *) absview cairo_save_v (l:addr) // abstract view generated by cairo_save absview cairo_push_group_v (l:addr) // abstract view generated by cairo_push_group (* ****** ****** *) // // contexts for drawing // (* ****** ****** *) fun cairo_create {l:agz} ( sf: !cairo_surface_ref l ) : cairo_ref1 = "mac#atsctrb_cairo_create" // // HX: implemented in [cairo.dats] // fun cairo_create0 {l:agz} (sf: cairo_surface_ref l): cairo_ref1 // end of [cairo_create0] (* ****** ****** *) fun cairo_status {l:agz} ( cr: !cairo_ref l ) : cairo_status_t = "mac#atsctrb_cairo_status" fun cairo_reference {l:agz} ( cr: !cairo_ref l ) : cairo_ref l = "mac#atsctrb_cairo_reference" fun cairo_destroy (cr: cairo_ref1): void = "mac#atsctrb_cairo_destroy" // end of [cairo_destroy] fun cairo_get_reference_count {l:agz} ( cr: !cairo_ref l ) : uint = "mac#atsctrb_cairo_get_reference_count" (* ****** ****** *) fun cairo_save {l:agz} ( cr: !cairo_ref l ) : (cairo_save_v l | void) = "mac#atsctrb_cairo_save" fun cairo_restore {l:agz} ( pf: cairo_save_v l | cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_restore" (* ****** ****** *) fun cairo_get_target {l1:agz} ( cr: !cairo_ref l1 ) : [l2:agz] ( minus (cairo_ref l1, cairo_surface_ref l2) | cairo_surface_ref l2 ) = "mac#atsctrb_cairo_get_target" fun cairo_get_group_target {l1:agz} ( cr: !cairo_ref l1 ) : [l2:agz] ( minus (cairo_ref l1, cairo_surface_ref l2) | cairo_surface_ref l2 ) = "mac#atsctrb_cairo_get_group_target" // // HX-2010-01-23: // note that these two functions are slightly different from // the original ones in cairo in terms of reference counting // fun cairo_get1_target {l:agz} ( cr: !cairo_ref l ) : cairo_surface_ref1 = "atsctrb_cairo_get1_target" // function! fun cairo_get1_group_target {l:agz} ( cr: !cairo_ref l ) : cairo_surface_ref1 = "atsctrb_cairo_get1_group_target" // function! (* ****** ****** *) fun cairo_push_group {l:agz} ( cr: !cairo_ref l ) : (cairo_push_group_v l | void) = "mac#atsctrb_cairo_push_group" fun cairo_push_group_with_content {l:agz} ( cr: !cairo_ref l, content: cairo_content_t ) : (cairo_push_group_v l | void) = "mac#atsctrb_cairo_push_group_with_content" fun cairo_pop_group {l:agz} ( pf: cairo_push_group_v l | cr: !cairo_ref l ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pop_group" fun cairo_pop_group_to_source {l:agz} ( pf: cairo_push_group_v l | cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_pop_group_to_source" (* ****** ****** *) fun cairo_set_source_rgb {l:agz} ( cr: !cairo_ref l , red: double, green: double, blue: double ) : void = "mac#atsctrb_cairo_set_source_rgb" fun cairo_set_source_rgba {l:agz} ( cr: !cairo_ref l , red: double , green: double , blue: double , alpha: double ) : void = "mac#atsctrb_cairo_set_source_rgba" (* ****** ****** *) // // HX-2010-04-29: pattern reference count is unchanged! // fun cairo_get_source {l:agz} ( cr: !cairo_ref l ) :<> [l1:agz] ( minus (cairo_ref l, cairo_pattern_ref l1) | cairo_pattern_ref l1 ) = "mac#atsctrb_cairo_get_source" fun cairo_set_source {l1,l2:agz} ( cr: !cairo_ref l1 , pat: !cairo_pattern_ref l2 ) : void = "mac#atsctrb_cairo_set_source" fun cairo_set_source_surface {l1,l2:agz} ( cr: !cairo_ref l1 , sf: !cairo_surface_ref l2 , x: double, y: double ) : void = "mac#atsctrb_cairo_set_source_surface" (* ****** ****** *) // // enum type // abst@ype cairo_antialias_t = $extype"cairo_antialias_t" macdef CAIRO_ANTIALIAS_DEFAULT = $extval (cairo_antialias_t, "CAIRO_ANTIALIAS_DEFAULT") macdef CAIRO_ANTIALIAS_NONE = $extval (cairo_antialias_t, "CAIRO_ANTIALIAS_NONE") macdef CAIRO_ANTIALIAS_GRAY = $extval (cairo_antialias_t, "CAIRO_ANTIALIAS_GRAY") macdef CAIRO_ANTIALIAS_SUBPIXEL = $extval (cairo_antialias_t, "CAIRO_ANTIALIAS_SUBPIXEL") fun cairo_get_antialias {l:agz} ( cr: !cairo_ref l ) : cairo_antialias_t = "mac#atsctrb_cairo_get_antialias" fun cairo_set_antialias {l:agz} ( cr: !cairo_ref l , antialias: cairo_antialias_t ) : void = "mac#atsctrb_cairo_set_antialias" (* ****** ****** *) fun cairo_get_dash_count {l:agz} ( cr: !cairo_ref l ) : int = "mac#atsctrb_cairo_get_dash_count" // // HX: note that [dashes] gets updated only if [n1 <= n] // fun cairo_get_dash {l:agz} {n:nat} ( cr: !cairo_ref l , dashes: &(@[double][n]), n: int n , offset: &double? >> double ) : [n1:nat] int n1 = "atsctrb_cairo_get_dash" // this is a function! fun cairo_set_dash {l:agz} {n:nat} ( cr: !cairo_ref l , dashes: &(@[double][n]), n: int n , offset: double ) : void = "mac#atsctrb_cairo_set_dash" (* ****** ****** *) // // enum type // abst@ype cairo_fill_rule_t = $extype"cairo_fill_rule_t" macdef CAIRO_FILL_RULE_WINDING = $extval (cairo_fill_rule_t, "CAIRO_FILL_RULE_WINDING") macdef CAIRO_FILL_RULE_EVEN_ODD = $extval (cairo_fill_rule_t, "CAIRO_FILL_RULE_EVEN_ODD") fun cairo_get_fill_rule {l:agz} ( cr: !cairo_ref l ) : cairo_fill_rule_t = "mac#atsctrb_cairo_get_fill_rule" fun cairo_set_fill_rule {l:agz} ( cr: !cairo_ref l , fill_rule: cairo_fill_rule_t ) : void = "mac#atsctrb_cairo_set_fill_rule" (* ****** ****** *) // // enum type // abst@ype cairo_line_cap_t = $extype"cairo_line_cap_t" macdef CAIRO_LINE_CAP_BUTT = $extval (cairo_line_cap_t, "CAIRO_LINE_CAP_BUTT") macdef CAIRO_LINE_CAP_ROUND = $extval (cairo_line_cap_t, "CAIRO_LINE_CAP_ROUND") macdef CAIRO_LINE_CAP_SQUARE = $extval (cairo_line_cap_t, "CAIRO_LINE_CAP_SQUARE") fun cairo_get_line_cap {l:agz} ( cr: !cairo_ref l ) : cairo_line_cap_t = "mac#atsctrb_cairo_get_line_cap" fun cairo_set_line_cap {l:agz} ( cr: !cairo_ref l , line_cap: cairo_line_cap_t ) : void = "mac#atsctrb_cairo_set_line_cap" (* ****** ****** *) // // enum type // abst@ype cairo_line_join_t = $extype"cairo_line_join_t" macdef CAIRO_LINE_JOIN_MITER = $extval (cairo_line_join_t, "CAIRO_LINE_JOIN_MITER") macdef CAIRO_LINE_JOIN_ROUND = $extval (cairo_line_join_t, "CAIRO_LINE_JOIN_ROUND") macdef CAIRO_LINE_JOIN_BEVEL = $extval (cairo_line_join_t, "CAIRO_LINE_JOIN_BEVEL") fun cairo_get_line_join {l:agz} ( cr: !cairo_ref l ) : cairo_line_join_t = "mac#atsctrb_cairo_get_line_join" fun cairo_set_line_join {l:agz} ( cr: !cairo_ref l , line_join: cairo_line_join_t ) : void = "mac#atsctrb_cairo_set_line_join" (* ****** ****** *) fun cairo_get_line_width {l:agz} ( cr: !cairo_ref l ) : double = "mac#atsctrb_cairo_get_line_width" fun cairo_set_line_width {l:agz} ( cr: !cairo_ref l, width: double ) : void = "mac#atsctrb_cairo_set_line_width" (* ****** ****** *) fun cairo_get_miter_limit {l:agz} ( cr: !cairo_ref l ) : double = "mac#atsctrb_cairo_get_miter_limit" fun cairo_set_miter_limit {l:agz} ( cr: !cairo_ref l, width: double ) : void = "mac#atsctrb_cairo_set_miter_limit" (* ****** ****** *) // // enum type // abst@ype cairo_operator_t = $extype"cairo_operator_t" castfn int_of_cairo_operator (x: cairo_operator_t):<> int macdef CAIRO_OPERATOR_CLEAR = $extval (cairo_operator_t, "CAIRO_OPERATOR_CLEAR") macdef CAIRO_OPERATOR_SOURCE = $extval (cairo_operator_t, "CAIRO_OPERATOR_SOURCE") macdef CAIRO_OPERATOR_OVER = $extval (cairo_operator_t, "CAIRO_OPERATOR_OVER") macdef CAIRO_OPERATOR_IN = $extval (cairo_operator_t, "CAIRO_OPERATOR_IN") macdef CAIRO_OPERATOR_OUT = $extval (cairo_operator_t, "CAIRO_OPERATOR_OUT") macdef CAIRO_OPERATOR_ATOP = $extval (cairo_operator_t, "CAIRO_OPERATOR_ATOP") macdef CAIRO_OPERATOR_DEST = $extval (cairo_operator_t, "CAIRO_OPERATOR_DEST") macdef CAIRO_OPERATOR_DEST_OVER = $extval (cairo_operator_t, "CAIRO_OPERATOR_DEST_OVER") macdef CAIRO_OPERATOR_DEST_IN = $extval (cairo_operator_t, "CAIRO_OPERATOR_DEST_IN") macdef CAIRO_OPERATOR_DEST_OUT = $extval (cairo_operator_t, "CAIRO_OPERATOR_DEST_OUT") macdef CAIRO_OPERATOR_DEST_ATOP = $extval (cairo_operator_t, "CAIRO_OPERATOR_DEST_ATOP") macdef CAIRO_OPERATOR_XOR = $extval (cairo_operator_t, "CAIRO_OPERATOR_XOR") macdef CAIRO_OPERATOR_ADD = $extval (cairo_operator_t, "CAIRO_OPERATOR_ADD") macdef CAIRO_OPERATOR_SATURATE = $extval (cairo_operator_t, "CAIRO_OPERATOR_SATURATE") fun cairo_get_operator {l:agz} ( cr: !cairo_ref l ) : cairo_operator_t = "mac#atsctrb_cairo_get_operator" fun cairo_set_operator {l:agz} ( cr: !cairo_ref l , operator: cairo_operator_t ) : void = "mac#atsctrb_cairo_set_operator" (* ****** ****** *) fun cairo_get_tolerance {l:agz} ( cr: !cairo_ref l ) : double = "mac#atsctrb_cairo_get_tolerance" fun cairo_set_tolerance {l:agz} ( cr: !cairo_ref l , tolerance: double ) : void = "mac#atsctrb_cairo_set_tolerance" (* ****** ****** *) typedef cairo_rectangle_t = $extype_struct "cairo_rectangle_t" of { x= double, y= double, width= double, height= double } // end of [cairo_rectangel_t] (* ****** ****** *) absviewtype // [n]: list length cairo_rectangle_list_ptr (n:int) // cairo_rectangle_list_t* viewtypedef cairo_rectangle_list_ptr1 = [n:nat] cairo_rectangle_list_ptr (n) fun cairo_rectangle_list_destroy {n:nat} ( lst: cairo_rectangle_list_ptr (n) ) : void = "mac#atsctrb_cairo_rectangle_list_destroy" fun cairo_copy_clip_rectangle_list {l:agz} ( cr: !cairo_ref l ) : [n:nat] cairo_rectangle_list_ptr (n) = "mac#atsctrb_cairo_copy_clip_rectangle_list" (* ****** ****** *) fun cairo_clip {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_clip" fun cairo_clip_preserve {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_clip_preserve" fun cairo_clip_extents {l:agz} ( cr: !cairo_ref l , x1: &double? >> double , y1: &double? >> double , x2: &double? >> double , y2: &double? >> double ) : void = "mac#atsctrb_cairo_clip_extents" fun cairo_reset_clip {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_reset_clip" (* ****** ****** *) fun cairo_fill {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_fill" // end of [cairo_fill] fun cairo_fill_preserve {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_fill_preserve" // end of [fun] fun cairo_fill_extents {l:agz} ( cr: !cairo_ref l , x1: &double? >> double, y1: &double? >> double , x2: &double? >> double, y2: &double? >> double ) : void = "mac#atsctrb_cairo_fill_extents" // end of [fun] fun cairo_in_fill {l:agz} ( cr: !cairo_ref l, x: double, y: double ) : bool = "mac#atsctrb_cairo_in_fill" // end of [fun] (* ****** ****** *) fun cairo_mask {l1,l2:agz} ( cr: !cairo_ref l1, pattern: !cairo_pattern_ref l2 ) : void = "mac#atsctrb_cairo_mask" // end of [fun] fun cairo_mask_surface {l1,l2:agz} ( cr: !cairo_ref l1 , sf: !cairo_surface_ref l2 , surface_x: double , surface_y: double ) : void = "mac#atsctrb_cairo_mask_surface" // end of [fun] (* ****** ****** *) fun cairo_paint {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_paint" // end of [fun] fun cairo_paint_with_alpha {l:agz} ( cr: !cairo_ref l, alpha: double ) : void = "mac#atsctrb_cairo_paint_with_alpha" // end of [fun] (* ****** ****** *) fun cairo_stroke {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_stroke" // end of [fun] fun cairo_stroke_preserve {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_stroke_preserve" // end of [fun] fun cairo_stroke_extents {l:agz} ( cr: !cairo_ref l , x1: &double? >> double, y1: &double? >> double , x2: &double? >> double, y2: &double? >> double ) : void = "mac#atsctrb_cairo_stroke_extents" // end of [fun] fun cairo_in_stroke {l:agz} ( cr: !cairo_ref l , x: double, y: double ) : bool = "mac#atsctrb_cairo_in_stroke" // end of [fun] (* ****** ****** *) fun cairo_copy_page {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_copy_page" // end of [cairo_copy_page] fun cairo_show_page {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_show_page" // end of [cairo_show_page] (* ****** ****** *) abst@ype cairo_user_data_key_t = $extype"cairo_user_data_key_t" // // note: this interface is unsafe!!! // fun cairo_get_user_data {l:agz} ( cr: !cairo_ref l , key: &cairo_user_data_key_t ) : Ptr = "mac#atsctrb_cairo_get_user_data" // end of [cairo_get_user_data] fun cairo_set_user_data {l:agz} ( cr: !cairo_ref l , key: &cairo_user_data_key_t , user_data: ptr // the proof of its view is aborbed into [cr] , destroy_func: ptr - void ) : cairo_status_t = "mac#atsctrb_cairo_set_user_data" // end of [cairo_set_user_data] (* ****** ****** *) // // drawing paths // (* ****** ****** *) absviewtype // [n]: path length cairo_path_ptr (n:int) // cairo_path_t* viewtypedef cairo_path_ptr1 = [n:nat] cairo_path_ptr (n) fun cairo_copy_path {l:agz} ( cr: !cairo_ref l ) : [n:nat] cairo_path_ptr n = "mac#atsctrb_cairo_copy_path" // end of [cairo_copy_path] fun cairo_copy_path_flat {l:agz} ( cr: !cairo_ref l ) : [n:nat] cairo_path_ptr n = "mac#atsctrb_cairo_copy_path_flat" // end of [cairo_copy_path_flat] fun cairo_append_path {l:agz} {n:nat} ( cr: !cairo_ref l , path: !cairo_path_ptr n ) : void = "mac#atsctrb_cairo_append_path" // end of [cairo_append_path] fun cairo_path_destroy {n:nat} ( path: cairo_path_ptr n ) : void = "mac#atsctrb_cairo_path_destroy" // end of [cairo_path_destroy] (* ****** ****** *) fun cairo_has_current_point {l:agz} ( cr: !cairo_ref l ) : bool = "mac#atsctrb_cairo_has_current_point" // end of [cairo_has_current_point] fun cairo_get_current_point {l:agz} ( cr: !cairo_ref l , x: &double? >> double , y: &double? >> double ) : void = "mac#atsctrb_cairo_get_current_point" // end of [cairo_get_current_point] (* ****** ****** *) fun cairo_new_path {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_new_path" // end of [cairo_new_path] fun cairo_new_sub_path {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_new_path" // end of [cairo_new_sub_path] fun cairo_close_path {l:agz} (cr: !cairo_ref l): void = "mac#atsctrb_cairo_close_path" // end of [cairo_close_path] (* ****** ****** *) fun cairo_arc {l:agz} ( cr: !cairo_ref l , xc: double, yc: double , rad: double, angle1: double, angle2: double ) : void = "mac#atsctrb_cairo_arc" // end of [cairo_arc] fun cairo_arc_negative {l:agz} ( cr: !cairo_ref l , xc: double, yc: double , rad: double, angle1: double, angle2: double ) : void = "mac#atsctrb_cairo_arc_negative" // end of [cairo_arc_negative] fun cairo_curve_to {l:agz} ( cr: !cairo_ref l , x1: double, y1: double , x2: double, y2: double , x3: double, y3: double ) : void = "mac#atsctrb_cairo_curve_to" // end of [cairo_curve_to] fun cairo_line_to {l:agz} (cr: !cairo_ref l, x: double, y: double): void = "mac#atsctrb_cairo_line_to" // end of [cairo_line_to] fun cairo_move_to {l:agz} ( cr: !cairo_ref l , x: double, y: double ) : void = "mac#atsctrb_cairo_move_to" // end of [cairo_move_to] fun cairo_rectangle {l:agz} ( cr: !cairo_ref l , x: double , y: double , w: double // width , h: double // height ) : void = "mac#atsctrb_cairo_rectangle" // end of [cairo_rectangle] (* ****** ****** *) fun cairo_rel_curve_to {l:agz} ( cr: !cairo_ref l , dx1: double, dy1: double , dx2: double, dy2: double , dx3: double, dy3: double ) : void = "mac#atsctrb_cairo_rel_curve_to" // end of [cairo_rel_curve_to] fun cairo_rel_line_to {l:agz} ( cr: !cairo_ref l , dx: double, dy: double ) : void = "mac#atsctrb_cairo_rel_line_to" // end of [cairo_rel_line_to] fun cairo_rel_move_to {l:agz} ( cr: !cairo_ref l , dx: double, dy: double ) : void = "mac#atsctrb_cairo_rel_move_to" // end of [cairo_rel_move_to] (* ****** ****** *) fun cairo_path_extents {l:agz} ( cr: !cairo_ref l , x1: &double? >> double , y1: &double? >> double , x2: &double? >> double , y2: &double? >> double ) : void = "mac#atsctrb_cairo_path_extents" // end of [cairo_path_extents] (* ****** ****** *) // // patterns for drawing // (* ****** ****** *) // // enum type // abst@ype cairo_pattern_type_t = $extype"cairo_pattern_type_t" macdef CAIRO_PATTERN_TYPE_SOLID = $extval (cairo_pattern_type_t, "CAIRO_PATTERN_TYPE_SOLID") macdef CAIRO_PATTERN_TYPE_SURFACE = $extval (cairo_pattern_type_t, "CAIRO_PATTERN_TYPE_SURFACE") macdef CAIRO_PATTERN_TYPE_LINEAR = $extval (cairo_pattern_type_t, "CAIRO_PATTERN_TYPE_LINEAR") macdef CAIRO_PATTERN_TYPE_RADIAL = $extval (cairo_pattern_type_t, "CAIRO_PATTERN_TYPE_RADIAL") (* ****** ****** *) // HX: this is an enum type abst@ype cairo_extend_t = $extype"cairo_extend_t" macdef CAIRO_EXTEND_NONE = $extval (cairo_extend_t, "CAIRO_EXTEND_NONE") macdef CAIRO_EXTEND_REPEAT = $extval (cairo_extend_t, "CAIRO_EXTEND_REPEAT") macdef CAIRO_EXTEND_REFLECT = $extval (cairo_extend_t, "CAIRO_EXTEND_REFLECT") macdef CAIRO_EXTEND_PAD = $extval (cairo_extend_t, "CAIRO_EXTEND_PAD") (* ****** ****** *) // HX: this is an enum type abst@ype cairo_filter_t = $extype"cairo_filter_t" macdef CAIRO_FILTER_FAST = $extval (cairo_filter_t, "CAIRO_FILTER_FAST") macdef CAIRO_FILTER_GOOD = $extval (cairo_filter_t, "CAIRO_FILTER_GOOD") macdef CAIRO_FILTER_BEST = $extval (cairo_filter_t, "CAIRO_FILTER_BEST") macdef CAIRO_FILTER_NEAREST = $extval (cairo_filter_t, "CAIRO_FILTER_NEAREST") macdef CAIRO_FILTER_BILINEAR = $extval (cairo_filter_t, "CAIRO_FILTER_BILINEAR") macdef CAIRO_FILTER_GAUSSIAN = $extval (cairo_filter_t, "CAIRO_FILTER_GAUSSIAN") (* ****** ****** *) fun cairo_pattern_create_rgb ( red: double, green: double, blue: double ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pattern_create_rgb" // end of [cairo_pattern_create_rgb] (* ****** ****** *) fun cairo_pattern_create_rgba ( red: double, green: double, blue: double, alpha: double ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pattern_create_rgba" // end of [cairo_pattern_create_rgba] fun cairo_pattern_get_rgba {l:agz} ( pat: !cairo_pattern_ref l , r: &double? >> double , g: &double? >> double , b: &double? >> double , a: &double? >> double ) : cairo_status_t = "mac#atsctrb_cairo_pattern_get_rgba" // end of [cairo_pattern_get_rgba] (* ****** ****** *) fun cairo_pattern_create_for_surface {l:agz} ( sf: !cairo_surface_ref l ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pattern_create_for_surface" // end of [cairo_pattern_create_for_surface] fun cairo_pattern_get_surface {l:agz} ( pat: !cairo_pattern_ref l , surface: &cairo_surface_ref1? >> cairo_surface_ref l1 ) : #[l1:agz] ( // HX-2010-05-05: no ownership transfer minus (cairo_pattern_ref l, cairo_surface_ref l1) | cairo_status_t ) = "mac#atsctrb_cairo_pattern_get_surface" // end of [cairo_pattern_get_surface] (* ****** ****** *) fun cairo_pattern_create_linear ( x0: double, x1: double, x2: double, x3: double ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pattern_create_linear" // end of [cairo_pattern_create_linear] fun cairo_pattern_get_linear_points {l:agz} ( cr: !cairo_pattern_ref l , x0: &double? >> double , x1: &double? >> double , x2: &double? >> double , x3: &double? >> double ) : cairo_status_t = "mac#atsctrb_cairo_pattern_get_linear_points" // end of [cairo_pattern_get_linear_points] (* ****** ****** *) fun cairo_pattern_create_radial ( cx0: double, cy0: double, rad0: double, cx1: double, cy1: double, rad1: double ) : cairo_pattern_ref1 = "mac#atsctrb_cairo_pattern_create_radial" // end of [cairo_pattern_create_radial] fun cairo_pattern_get_radial_circles {l:agz} ( cr: !cairo_pattern_ref l , x0: &double? >> double , y0: &double? >> double , r0: &double? >> double , x1: &double? >> double , y1: &double? >> double , r1: &double? >> double ) : cairo_status_t = "mac#atsctrb_cairo_pattern_get_radial_circles" // end of [cairo_pattern_get_radial_circles] (* ****** ****** *) fun cairo_pattern_status {l:agz} ( pat: cairo_pattern_ref l ) : cairo_status_t = "mac#atsctrb_cairo_pattern_status" // end of [cairo_pattern_status] fun cairo_pattern_reference {l:agz} ( pat: !cairo_pattern_ref l ) : cairo_pattern_ref l = "mac#atsctrb_cairo_pattern_reference" // end of [cairo_pattern_reference] fun cairo_pattern_destroy ( pat: cairo_pattern_ref1 ) : void = "mac#atsctrb_cairo_pattern_destroy" // end of [cairo_pattern_destroy] fun cairo_pattern_get_reference_count {l:agz} ( cr: !cairo_pattern_ref l ) : uint = "mac#atsctrb_cairo_pattern_get_reference_count" // end of [cairo_pattern_get_reference_count] (* ****** ****** *) fun cairo_pattern_get_type {l:agz} ( pat: !cairo_pattern_ref l ) : cairo_pattern_type_t = "mac#atsctrb_cairo_pattern_get_type" // end of [cairo_pattern_get_type] fun cairo_pattern_add_color_stop_rgb {l:agz} ( pat: !cairo_pattern_ref l , offset: double, red: double, green: double, blue: double ) : void = "mac#atsctrb_cairo_pattern_add_color_stop_rgb" // end of [cairo_pattern_add_color_stop_rgb] fun cairo_pattern_add_color_stop_rgba {l:agz} ( pat: !cairo_pattern_ref l , offset: double , red: double, green: double, blue: double , alpha: double ) : void = "mac#atsctrb_cairo_pattern_add_color_stop_rgba" // end of [cairo_pattern_add_color_stop_rgba] fun cairo_pattern_get_color_stop_count {l:agz} ( pat: !cairo_pattern_ref l , count: &int? >> int ) : cairo_status_t = "mac#atsctrb_cairo_pattern_get_color_stop_count" // end of [cairo_pattern_get_color_stop_count] fun cairo_pattern_get_color_stop_rgba {l:agz} ( pat: !cairo_pattern_ref l , index: int , offset: &double? >> double , red: &double? >> double , green: &double? >> double , blue: &double? >> double , alpha: &double? >> double ) : cairo_status_t = "mac#atsctrb_cairo_pattern_get_color_stop_rgba" // end of [cairo_pattern_get_color_stop_rgba] (* ****** ****** *) fun cairo_pattern_get_extend {l:agz} ( pat: !cairo_pattern_ref l ) : cairo_extend_t = "mac#atsctrb_cairo_pattern_get_extend" // end of [cairo_pattern_get_extend] fun cairo_pattern_set_extend {l:agz} ( pat: !cairo_pattern_ref l , extend: cairo_extend_t ) : void = "mac#atsctrb_cairo_pattern_set_extend" // end of [cairo_pattern_set_extend] (* ****** ****** *) fun cairo_pattern_get_filter {l:agz} ( pat: !cairo_pattern_ref l ) : cairo_filter_t = "mac#atsctrb_cairo_pattern_get_filter" // end of [cairo_pattern_get_filter] fun cairo_pattern_set_filter {l:agz} ( pat: !cairo_pattern_ref l , filter: cairo_filter_t ) : void = "mac#atsctrb_cairo_pattern_set_filter" // end of [cairo_pattern_set_filter] (* ****** ****** *) fun cairo_pattern_set_matrix {l:agz} ( pat: !cairo_pattern_ref l , matrix: &cairo_matrix_t ) : void = "mac#atsctrb_cairo_pattern_set_matrix" // end of [cairo_pattern_set_matrix] fun cairo_pattern_get_matrix {l:agz} ( pat: !cairo_pattern_ref l , matrix: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_pattern_get_matrix" // end of [cairo_pattern_get_matrix] (* ****** ****** *) fun cairo_pattern_get_user_data {l:agz} ( pat: !cairo_pattern_ref l , key: &cairo_user_data_key_t ) : Ptr = "mac#atsctrb_cairo_pattern_get_user_data" // end of [cairo_pattern_get_user_data] fun cairo_pattern_set_user_data {l:agz} ( pat: !cairo_pattern_ref l , key: &cairo_user_data_key_t , user_data: ptr // the proof of its view is aborbed into [cr] , destroy_func: ptr - void ) : cairo_status_t = "mac#atsctrb_cairo_pattern_set_user_data" // end of [cairo_pattern_set_user_data] (* ****** ****** *) // // drawing texts // (* ****** ****** *) // enum type abst@ype cairo_font_slant_t = $extype"cairo_font_slant_t" macdef CAIRO_FONT_SLANT_NORMAL = $extval (cairo_font_slant_t, "CAIRO_FONT_SLANT_NORMAL") macdef CAIRO_FONT_SLANT_ITALIC = $extval (cairo_font_slant_t, "CAIRO_FONT_SLANT_ITALIC") macdef CAIRO_FONT_SLANT_OBLIQUE = $extval (cairo_font_slant_t, "CAIRO_FONT_SLANT_OBLIQUE") castfn int_of_cairo_font_slant (x: cairo_font_slant_t):<> int // enum type abst@ype cairo_font_weight_t = $extype"cairo_font_weight_t" macdef CAIRO_FONT_WEIGHT_NORMAL = $extval (cairo_font_weight_t, "CAIRO_FONT_WEIGHT_NORMAL") macdef CAIRO_FONT_WEIGHT_BOLD = $extval (cairo_font_weight_t, "CAIRO_FONT_WEIGHT_BOLD") castfn int_of_cairo_font_weight (x: cairo_font_weight_t):<> int (* ****** ****** *) fun cairo_select_font_face {l:agz} ( cr: !cairo_ref l , name: string (*family*) , slnt: cairo_font_slant_t , wght: cairo_font_weight_t ) : void = "mac#atsctrb_cairo_select_font_face" // end of [cairo_select_font_face] fun cairo_set_font_size {l:agz} ( cr: !cairo_ref l, size: double ) : void = "mac#atsctrb_cairo_set_font_size" // end of [cairo_set_font_size] (* ****** ****** *) fun cairo_get_font_matrix {l:agz} ( cr: !cairo_ref l , mat: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_get_font_matrix" // end of [cairo_get_font_matrix] fun cairo_set_font_matrix {l:agz} ( cr: !cairo_ref l , mat: &cairo_matrix_t ) : void = "mac#atsctrb_cairo_set_font_matrix" // end of [cairo_set_font_matrix] (* ****** ****** *) // // HX: options is over written // fun cairo_get_font_options {l1,l2:agz} ( cr: !cairo_ref l1 , options: !cairo_font_options_ptr l2 ) : void = "mac#atsctrb_cairo_get_font_options" // end of [cairo_get_font_options] fun cairo_set_font_options {l1,l2:agz} ( cr: !cairo_ref l1 , options: !cairo_font_options_ptr l2 ) : void = "mac#atsctrb_cairo_set_font_options" // end of [cairo_set_font_options] (* ****** ****** *) fun cairo_get_font_face {l:agz} ( cr: !cairo_ref l ) : cairo_font_face_ref1 = "mac#atsctrb_cairo_get_font_face" // end of [cairo_get_font_face] fun cairo_set_font_face {l1,l2:agz} ( cr: !cairo_ref l1 , face: !cairo_font_face_ref l2 ) : void = "mac#atsctrb_cairo_set_font_face" // end of [cairo_set_font_face] (* ****** ****** *) typedef cairo_glyph_t = $extype_struct "cairo_glyph_t" of { index= ulint , x= double , y= double } // end of [cairo_glyph_t] typedef cairo_text_cluster_t = $extype_struct "cairo_text_cluster_t" of { num_bytes= int , num_glyphs= int } // end of [cairo_text_cluster_t] (* // HX: note that these viewtypes contain views needed for freeing *) absviewtype cairo_glyph_arrptr (n:int,l:addr) // = cairo_glyph_t* absviewtype cairo_cluster_arrptr (n:int,l:addr) // = cairo_cluster_t* (* // this would be of great inconvenience abst@ype cairo_font_extents_t = $extype"cairo_font_extents_t" *) typedef cairo_font_extents_t = $extype_struct "cairo_font_extents_t" of { ascent= double , descent= double , height= double , max_x_advance= double , max_y_advance= double } // end of [cairo_font_extents_t] (* ****** ****** *) (* // HX: this would have been of great inconvenience: abst@ype cairo_text_extents_t = $extype"cairo_text_extents_t" *) typedef cairo_text_extents_t = $extype_struct "cairo_text_extents_t" of { x_bearing= double, y_bearing= double , width= double, height= double , x_advance= double, y_advance= double } // end of [cairo_text_extents_t] (* ****** ****** *) fun cairo_font_extents {l:agz} ( cr: !cairo_ref l , extents: &cairo_font_extents_t? >> cairo_font_extents_t ) : void = "mac#atsctrb_cairo_font_extents" // end of [cairo_font_extents] fun cairo_text_extents {l:agz} ( cr: !cairo_ref l, utf8: string , extents: &cairo_text_extents_t? >> cairo_text_extents_t ) : void = "mac#atsctrb_cairo_text_extents" // end of [cairo_text_extents] fun cairo_glyph_extents {l:agz} {n:nat} {la:agz} ( cr: !cairo_ref l , glyphs: !cairo_glyph_arrptr (n, la), n: int n , extents: &cairo_text_extents_t? >> cairo_text_extents_t ) : void = "mac#atsctrb_cairo_glyph_extents" // end of [cairo_glyph_extents] (* ****** ****** *) fun cairo_text_path {l:agz} ( cr: !cairo_ref l , text: string // read-only ) : void = "mac#atsctrb_cairo_text_path" // end of [cairo_text_path] fun cairo_glyph_path {l:agz} {n:nat} {la:agz} ( cr: !cairo_ref l , glyphs: !cairo_glyph_arrptr (n, la), n: int n ) : void = "mac#atsctrb_cairo_glyph_path" // end of [cairo_glyph_path] (* ****** ****** *) fun cairo_show_text {l:agz} ( cr: !cairo_ref l , utf8: string // read-only ) : void = "mac#atsctrb_cairo_show_text" // end of [cairo_show_text] fun cairo_show_glyphs {l:agz} {n:nat} {la:agz} ( cr: !cairo_ref l , glyphs: !cairo_glyph_arrptr (n, la), n: int n ) : void = "mac#atsctrb_cairo_show_glyphs" // end of [cairo_show_glyphs] (* ****** ****** *) fun cairo_toy_font_face_create ( family: string , s: cairo_font_slant_t, w: cairo_font_weight_t ) : cairo_font_face_ref1 = "mac#atsctrb_cairo_toy_font_face_create" // end of [cairo_toy_font_face_create] fun cairo_toy_font_face_get_family {l:agz} ( font_face: !cairo_font_face_ref l ) : [l:agz] ( strptr(l) - void | strptr(l) ) = "mac#atsctrb_cairo_toy_font_face_get_family" // end of [cairo_toy_font_face_get_family] fun cairo_toy_font_face_get_slant {l:agz} ( font_face: !cairo_font_face_ref l ) : cairo_font_slant_t = "mac#atsctrb_cairo_toy_font_face_get_slant" // end of [cairo_toy_font_face_get_slant] fun cairo_toy_font_face_get_weight {l:agz} ( font_face: !cairo_font_face_ref l ) : cairo_font_weight_t = "mac#atsctrb_cairo_toy_font_face_get_weight" // end of [cairo_toy_font_face_get_weight] (* ****** ****** *) fun cairo_glyph_allocate {n:nat} ( n: int n // array size ) : [l:agz] cairo_glyph_arrptr (n, l) = "mac#atsctrb_cairo_glyph_allocate" // end of [cairo_glyph_allocate] fun cairo_glyph_free {n:nat} {l:agz} ( // [l] can be null p_arr: cairo_glyph_arrptr (n, l) ) : void = "mac#atsctrb_cairo_glyph_free" // end of [cairo_glyph_free] fun cairo_cluster_allocate {n:nat} ( n: int n // array size ) : [l:agz] cairo_cluster_arrptr (n, l) = "mac#atsctrb_cairo_cluster_allocate" // end of [cairo_cluster_allocate] fun cairo_cluster_free {n:nat} {l:agz} ( // [l] can be null p_arr: cairo_cluster_arrptr (n, l) ) : void = "mac#atsctrb_cairo_cluster_free" // end of [cairo_cluster_free] (* ****** ****** *) // // HX: transformations for drawing // (* ****** ****** *) fun cairo_translate {l:agz} ( cr: !cairo_ref l, x: double, y: double ) : void = "mac#atsctrb_cairo_translate" // end of [fun] fun cairo_scale {l:agz} ( cr: !cairo_ref l, sx: double, sy: double ) : void = "mac#atsctrb_cairo_scale" // end of [fun] // // HX: radiants are used for angles // fun cairo_rotate {l:agz} ( cr: !cairo_ref l, angle: double ) : void = "mac#atsctrb_cairo_rotate" // end of [fun] fun cairo_transform {l:agz} ( cr: !cairo_ref l, mat: &cairo_matrix_t ) : void = "mac#atsctrb_cairo_transform" // end of [fun] (* ****** ****** *) fun cairo_get_matrix {l:agz} ( cr: !cairo_ref l , mat: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_get_matrix" // end of [fun] fun cairo_set_matrix {l:agz} ( cr: !cairo_ref l, mat: &cairo_matrix_t ) : void = "mac#atsctrb_cairo_set_matrix" // end of [fun] fun cairo_identity_matrix {l:agz} ( cr: !cairo_ref l ) : void = "mac#atsctrb_cairo_identity_matrix" // end of [fun] (* ****** ****** *) fun cairo_user_to_device {l:agz} ( cr: !cairo_ref l, x: &double, y: &double ) : void = "mac#atsctrb_cairo_user_to_device" // end of [fun] fun cairo_user_to_device_distance {l:agz} ( cr: !cairo_ref l, dx: &double, dy: &double ) : void = "mac#atsctrb_cairo_user_to_device_distance" // end of [fun] fun cairo_device_to_user {l:agz} ( cr: !cairo_ref l, x: &double, y: &double ) : void = "mac#atsctrb_cairo_device_to_user" // end of [fun] fun cairo_device_to_user_distance {l:agz} ( cr: !cairo_ref l, dx: &double, dy: &double ) : void = "mac#atsctrb_cairo_device_to_user_distance" // end of [fun] (* ****** ****** *) // // HX: fonts for drawing // (* ****** ****** *) fun cairo_font_face_status {l:agz} ( font_face: !cairo_font_face_ref l ) : cairo_status_t = "mac#atsctrb_cairo_font_face_status" // end of [fun] fun cairo_font_face_destroy ( font_face: cairo_font_face_ref1 ) : void = "mac#atsctrb_cairo_font_face_destroy" // end of [fun] fun cairo_font_face_reference {l:agz} ( font_face: !cairo_font_face_ref l ) : cairo_font_face_ref l = "mac#atsctrb_cairo_font_face_reference" // end of [fun] fun cairo_font_face_get_reference_count {l:agz} ( font_face: !cairo_font_face_ref l ) : uint = "mac#atsctrb_cairo_font_face_get_reference_count" // end of [fun] // // enum type // abst@ype cairo_font_type_t = $extype"cairo_font_type_t" macdef CAIRO_FONT_TYPE_TOY = $extval (cairo_font_type_t, "CAIRO_FONT_TYPE_TOY") macdef CAIRO_FONT_TYPE_FT = $extval (cairo_font_type_t, "CAIRO_FONT_TYPE_FT") macdef CAIRO_FONT_TYPE_WIN32 = $extval (cairo_font_type_t, "CAIRO_FONT_TYPE_WIN32") macdef CAIRO_FONT_TYPE_QUARTZ = $extval (cairo_font_type_t, "CAIRO_FONT_TYPE_QUARTZ") macdef CAIRO_FONT_TYPE_USER = $extval (cairo_font_type_t, "CAIRO_FONT_TYPE_USER") fun cairo_font_face_get_type {l:agz} ( font_face: !cairo_font_face_ref l ) : cairo_font_type_t = "mac#atsctrb_cairo_font_face_get_type" (* ****** ****** *) // // HX: scaled fonts // (* ****** ****** *) absviewtype cairo_scaled_font_ref (l:addr) // cairo_scaled_font_t* viewtypedef cairo_scaled_font_ref1 = [l:addr | l > null] cairo_scaled_font_ref l fun cairo_scaled_font_status {l:agz} ( font: !cairo_scaled_font_ref l ) : cairo_status_t = "mac#atsctrb_cairo_scaled_font_status" // end of [fun] fun cairo_scaled_font_destroy ( font: cairo_scaled_font_ref1 ) : void = "mac#atsctrb_cairo_scaled_font_destroy" // end of [fun] fun cairo_scaled_font_reference {l:agz} ( font: !cairo_scaled_font_ref l ) : cairo_scaled_font_ref1 = "mac#atsctrb_cairo_scaled_font_reference" // end of [fun] fun cairo_scaled_font_get_reference_count {l:agz} ( font: !cairo_scaled_font_ref l ) : uint = "mac#atsctrb_cairo_scaled_font_reference_count" // end of [fun] (* ****** ****** *) fun cairo_scaled_font_extents {l:agz} ( font: !cairo_scaled_font_ref l , extents: &cairo_font_extents_t? >> cairo_font_extents_t ) : void = "mac#atsctrb_cairo_scaled_font_extents" // end of [fun] fun cairo_scaled_font_text_extents {l:agz} ( font: !cairo_scaled_font_ref l , utf8: string , extents: &cairo_text_extents_t? >> cairo_text_extents_t ) : void = "mac#atsctrb_cairo_scaled_font_text_extents" // end of [fun] fun cairo_scaled_font_get_font_face {l:agz} ( font: !cairo_scaled_font_ref l ) : cairo_font_face_ref1 = "mac#atsctrb_cairo_scaled_font_get_font_face" // end of [fun] fun cairo_scaled_font_get_font_options {l1,l2:agz} ( font: !cairo_scaled_font_ref l1 , options: !cairo_font_options_ptr l2 ) : void = "mac#atsctrb_cairo_scaled_font_get_font_options" // end of [fun] fun cairo_scaled_font_get_font_matrix {l:agz} ( font: !cairo_scaled_font_ref l , font_matrix: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_scaled_font_get_font_matrix" // end of [fun] fun cairo_scaled_font_get_ctm {l:agz} ( font: !cairo_scaled_font_ref l , ctm: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_scaled_font_get_ctm" // end of [fun] fun cairo_scaled_font_get_scale_matrix {l:agz} ( font: !cairo_scaled_font_ref l , scale_matrix: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_scaled_font_get_scale_matrix" // end of [fun] fun cairo_scaled_font_get_type {l:agz} ( font: !cairo_scaled_font_ref l ) : cairo_font_type_t = "mac#atsctrb_cairo_scaled_font_get_type" // end of [fun] (* ****** ****** *) // // HX: font options // (* ****** ****** *) fun cairo_font_options_create ( // there is no argument for the function ) : cairo_font_options_ptr1 = "mac#atsctrb_cairo_font_options_create" // end of [fun] // // HX-2010-04-30: // true copying (instead of reference counting) // fun cairo_font_options_copy {l:agz} ( options: !cairo_font_options_ptr l ) : cairo_font_options_ptr1 = "mac#atsctrb_cairo_font_options_copy" // end of [fun] fun cairo_font_options_destroy ( options: cairo_font_options_ptr1 ) : void = "mac#atsctrb_cairo_font_options_copy" // end of [fun] fun cairo_font_options_status {l:agz} ( options: !cairo_font_options_ptr l ) : cairo_status_t = "mac#atsctrb_cairo_font_options_status" // end of [fun] fun cairo_font_options_merge {l1,l2:agz} ( options: !cairo_font_options_ptr l1 , other: !cairo_font_options_ptr l2 ) : void = "mac#atsctrb_cairo_font_options_merge" // end of [fun] fun cairo_font_options_hash {l:agz} ( options: !cairo_font_options_ptr l ) : ulint = "mac#atsctrb_cairo_font_options_hash" // end of [fun] fun cairo_font_options_equal {l1,l2:agz} ( options: !cairo_font_options_ptr l1 , other: !cairo_font_options_ptr l2 ) : bool // cairo_bool_t = "mac#atsctrb_cairo_font_options_equal" // end of [fun] (* ****** ****** *) fun cairo_font_options_get_antialias {l:agz} ( options: !cairo_font_options_ptr l ) : cairo_antialias_t = "mac#atsctrb_cairo_font_options_get_antialias" // end of [fun] fun cairo_font_options_set_antialias {l:agz} ( options: !cairo_font_options_ptr l , antialias: cairo_antialias_t ) : void = "mac#atsctrb_cairo_font_options_set_antialias" // end of [fun] (* ** enum *) abst@ype cairo_subpixel_order_t = $extype"cairo_subpixel_order_t" macdef CAIRO_SUBPIXEL_ORDER_DEFAULT = $extval (cairo_subpixel_order_t, "CAIRO_SUBPIXEL_ORDER_DEFAULT") macdef CAIRO_SUBPIXEL_ORDER_RGB = $extval (cairo_subpixel_order_t, "CAIRO_SUBPIXEL_ORDER_RGB") macdef CAIRO_SUBPIXEL_ORDER_BGR = $extval (cairo_subpixel_order_t, "CAIRO_SUBPIXEL_ORDER_BGR") macdef CAIRO_SUBPIXEL_ORDER_VRGB = $extval (cairo_subpixel_order_t, "CAIRO_SUBPIXEL_ORDER_VRGB") macdef CAIRO_SUBPIXEL_ORDER_VBGR = $extval (cairo_subpixel_order_t, "CAIRO_SUBPIXEL_ORDER_VBGR") fun cairo_font_options_get_subpixel_order {l:agz} ( options: !cairo_font_options_ptr l ) :<> cairo_subpixel_order_t = "mac#atsctrb_cairo_font_options_get_subpixel_order" fun cairo_font_options_set_subpixel_order {l:agz} ( options: !cairo_font_options_ptr l , subpixel_order: cairo_subpixel_order_t ) : void = "mac#atsctrb_cairo_font_options_set_subpixel_order" (* ** enum *) abst@ype cairo_hint_style_t = $extype"cairo_hint_style_t" macdef CAIRO_HINT_STYLE_DEFAULT = $extval (cairo_hint_style_t, "CAIRO_HINT_STYLE_DEFAULT") macdef CAIRO_HINT_STYLE_NONE = $extval (cairo_hint_style_t, "CAIRO_HINT_STYLE_NONE") macdef CAIRO_HINT_STYLE_SLIGHT = $extval (cairo_hint_style_t, "CAIRO_HINT_STYLE_SLIGHT") macdef CAIRO_HINT_STYLE_MEDIUM = $extval (cairo_hint_style_t, "CAIRO_HINT_STYLE_MEDIUM") macdef CAIRO_HINT_STYLE_FULL = $extval (cairo_hint_style_t, "CAIRO_HINT_STYLE_FULL") fun cairo_font_options_get_hint_style {l:agz} ( options: !cairo_font_options_ptr l ) :<> cairo_hint_style_t = "mac#atsctrb_cairo_font_options_get_hint_style" // end of [fun] fun cairo_font_options_set_hint_style {l:agz} ( options: !cairo_font_options_ptr l , hint_style: cairo_hint_style_t ) : void = "mac#atsctrb_cairo_font_options_set_hint_style" // end of [fun] (* ** enum *) abst@ype cairo_hint_metrics_t = $extype"cairo_hint_metrics_t" macdef CAIRO_HINT_METRICS_DEFAULT = $extval (cairo_hint_metrics_t, "CAIRO_HINT_METRICS_DEFAULT") macdef CAIRO_HINT_METRICS_OFF = $extval (cairo_hint_metrics_t, "CAIRO_HINT_METRICS_OFF") macdef CAIRO_HINT_METRICS_ON = $extval (cairo_hint_metrics_t, "CAIRO_HINT_METRICS_ON") fun cairo_font_options_get_hint_metrics {l:agz} ( options: !cairo_font_options_ptr l ) :<> cairo_hint_metrics_t = "mac#atsctrb_cairo_font_options_get_hint_metrics" // end of [fun] fun cairo_font_options_set_hint_metrics {l:agz} ( options: !cairo_font_options_ptr l , hint_metrics: cairo_hint_metrics_t ) : void = "mac#atsctrb_cairo_font_options_set_hint_metrics" // end of [fun] (* ****** ****** *) // // HX: Support for FreeType Font // (* ****** ****** *) (* #define CAIRO_HAS_FT_FONT *) absviewtype FT_Face // boxed object absviewtype FcPattern_ptr // FcPattern* fun cairo_ft_font_face_create_for_ft_face ( face: FT_Face , load_flags: int ) : cairo_font_face_ref1 = "mac#atsctrb_cairo_ft_font_face_create_for_ft_face" // end of [fun] fun cairo_ft_font_face_create_for_pattern ( pattern: FcPattern_ptr ) : cairo_font_face_ref1 = "mac#atsctrb_cairo_ft_font_face_create_for_pattern" // end of [fun] fun cairo_ft_font_options_substitute {l:agz} ( options: !cairo_font_options_ptr l , pattern: FcPattern_ptr ) :<> void = "mac#atsctrb_cairo_ft_font_options_substitute" // end of [fun] (* ****** ****** *) absview scaled_font_lock_face_v (l:addr) fun cairo_ft_scaled_font_lock_face {l:agz} ( scaled_font: !cairo_scaled_font_ref l ) :<> (scaled_font_lock_face_v l | FT_Face) = "mac#atsctrb_cairo_ft_scaled_font_lock_face" // end of [cairo_ft_scaled_font_lock_face] fun cairo_ft_scaled_font_unlock_face {l:agz} ( pf: scaled_font_lock_face_v l | scaled_font: !cairo_scaled_font_ref l ) :<> void = "mac#atsctrb_cairo_ft_scaled_font_unlock_face" // end of [cairo_ft_scaled_font_unlock_face] (* ****** ****** *) // // HX: surfaces for drawing // (* ****** ****** *) fun cairo_surface_create_similar {l:agz} ( sf: !cairo_surface_ref l , content: cairo_content_t , width: int, height: int ) : cairo_surface_ref1 = "mac#atsctrb_cairo_surface_create_similar" // end of [fun] fun cairo_surface_reference {l:agz} ( sf: !cairo_surface_ref l ) : cairo_surface_ref l = "mac#atsctrb_cairo_surface_reference" // end of [fun] fun cairo_surface_destroy (sf: cairo_surface_ref1): void = "mac#atsctrb_cairo_surface_destroy" // end of [cairo_surface_destroy] fun cairo_surface_status {l:agz} ( sf: !cairo_surface_ref l ) : cairo_status_t = "mac#atsctrb_cairo_surface_status" // end of [cairo_surface_status] fun cairo_surface_finish {l:agz} (sf: !cairo_surface_ref l): void = "mac#atsctrb_cairo_surface_finish" // end of [cairo_surface_finish] fun cairo_surface_flush {l:agz} (sf: !cairo_surface_ref l): void = "mac#atsctrb_cairo_surface_flush" // end of [cairo_surface_flush] fun cairo_surface_get_font_options {l1,l2:agz} ( sf: !cairo_surface_ref l1, options: !cairo_font_options_ptr l2 ) : void = "mac#atsctrb_cairo_surface_get_font_options" // end of [cairo_surface_get_font_options] fun cairo_surface_get_content {l:agz} ( sf: !cairo_surface_ref l ) : cairo_content_t = "mac#atsctrb_cairo_surface_get_content" // end of [cairo_surface_get_content] fun cairo_surface_mark_dirty {l:agz} ( sf: !cairo_surface_ref l ) : void = "mac#atsctrb_cairo_surface_mark_dirty" // end of [cairo_surface_mark_dirty] fun cairo_surface_mark_dirty_rectangle {l:agz} ( sf: !cairo_surface_ref l , x: int, y: int, width: int, height: int ) : void = "mac#atsctrb_cairo_surface_mark_dirty" // end of [cairo_surface_mark_dirty_rectangle] fun cairo_get_device_offset {l:agz} ( sf: !cairo_surface_ref l, x_ofs: &double? >> double, y_ofs: &double? >> double ) : void = "mac#atsctrb_cairo_get_device_offset" // end of [cairo_get_device_offset] fun cairo_set_device_offset {l:agz} ( sf: !cairo_surface_ref l , x_ofs: double, y_ofs: double ) : void = "mac#atsctrb_cairo_set_device_offset" // end of [cairo_set_device_offset] (* ****** ****** *) // // enum type // abstype cairo_surface_type_t = $extype"cairo_surface_type_t" macdef CAIRO_SURFACE_TYPE_IMAGE = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_IMAGE") macdef CAIRO_SURFACE_TYPE_PDF = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_PDF") macdef CAIRO_SURFACE_TYPE_PS = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_PS") macdef CAIRO_SURFACE_TYPE_XLIB = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_XLIB") macdef CAIRO_SURFACE_TYPE_XCB = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_XCB") macdef CAIRO_SURFACE_TYPE_GLITZ = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_GLITZ") macdef CAIRO_SURFACE_TYPE_QUARTZ = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_QUARTZ") macdef CAIRO_SURFACE_TYPE_QUARTZ_IMAGE = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_QUARTZ_IMAGE") macdef CAIRO_SURFACE_TYPE_WIN32 = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_WIN32") macdef CAIRO_SURFACE_TYPE_WIN32_PRINTING = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_WIN32_PRINTING") macdef CAIRO_SURFACE_TYPE_BEOS = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_BEOS") macdef CAIRO_SURFACE_TYPE_DIRECTFB = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_DIRECTFB") macdef CAIRO_SURFACE_TYPE_SVG = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_SVG") macdef CAIRO_SURFACE_TYPE_OS2 = $extval (cairo_surface_type_t, "CAIRO_SURFACE_TYPE_OS2") fun cairo_surface_get_type {l:agz} ( sf: !cairo_surface_ref l ) : cairo_surface_type_t = "mac#atsctrb_cairo_surface_get_type" // end of [cairo_surface_get_type] fun cairo_surface_get_reference_count {l:agz} ( sf: !cairo_surface_ref l ) : int = "mac#atsctrb_cairo_surface_get_reference_count" // end of [cairo_surface_get_reference_count] fun cairo_surface_copy_page {l:agz} ( sf: !cairo_surface_ref l ) : void = "mac#atsctrb_cairo_surface_copy_page" // end of [cairo_surface_copy_page] fun cairo_surface_show_page {l:agz} ( sf: !cairo_surface_ref l ) : void = "mac#atsctrb_cairo_surface_show_page" // end of [cairo_surface_show_page] (* ****** ****** *) // // HX: image surface // (* ****** ****** *) (* // how to handle this: #define CAIRO_HAS_IMAGE_SURFACE *) fun cairo_format_stride_for_width ( format: cairo_format_t, width: int ) : int = "mac#atsctrb_cairo_format_stride_for_width" // end of [cairo_format_stride_for_width] fun cairo_image_surface_create ( format: cairo_format_t, width: int, height: int ) : cairo_surface_ref1 = "mac#atsctrb_cairo_image_surface_create" // end of [cairo_image_surface_create] // // this one is unsafe but ... // fun cairo_image_surface_create_for_data ( data: ptr // uchar* , format: cairo_format_t , width: int, height: int, stride: int ) : cairo_surface_ref1 = "mac#atsctrb_cairo_image_surface_create_for_data" // end of [fun] fun cairo_image_surface_get_format {l:agz} ( sf: !cairo_surface_ref l ) : cairo_format_t = "mac#atsctrb_cairo_image_surface_get_format" // end of [cairo_image_surface_get_format] fun cairo_image_surface_get_width {l:agz} ( sf: !cairo_surface_ref l ) : int // HX: the C interface says int = "mac#atsctrb_cairo_image_surface_get_width" // end of [cairo_image_surface_get_width] fun cairo_image_surface_get_height {l:agz} ( sf: !cairo_surface_ref l ) : int // HX: the C interface says int = "mac#atsctrb_cairo_image_surface_get_height" // end of [cairo_image_surface_get_height] fun cairo_image_surface_get_stride {l:agz} ( sf: !cairo_surface_ref l ) : int // HX: the C interface says int = "mac#atsctrb_cairo_image_surface_get_stride" // end of [cairo_image_surface_get_stride] // // HX-2010-05-21: // the data is of the type: // GEMAT (uchar, height, alpha*width, row, stride), where // alpha = 4 for CAIRO_FORMAT_ARGB32 // alpga = 4 for CAIRO_FORMAT_RGB24 // alpha = 1 for CAIRO_FORMAT_A8 // alpha = 1/8 for CAIRO_FORMAT_A1 // fun cairo_image_surface_get_data {l:agz} ( sf: !cairo_surface_ref l ) : Ptr // uchar* = "mac#atsctrb_cairo_image_surface_get_data" // end of [cairo_image_surface_get_data] (* ****** ****** *) // // HX: PNG support // (* ****** ****** *) fun cairo_image_surface_create_from_png (filename: string): cairo_surface_ref1 = "mac#atsctrb_cairo_image_surface_create_from_png" // end of [cairo_image_surface_create_from_png] fun cairo_image_surface_create_from_png_stream {v:view} {vt:viewtype} ( pf: !v | read_func: {n:nat} (!v | !vt, &(@[byte][n]), int n) - cairo_status_t , env: !vt ) : cairo_surface_ref1 = "mac#atsctrb_cairo_image_surface_create_from_png" // end of [cairo_image_surface_create_from_png_stream] fun cairo_surface_write_to_png {l:agz} (sf: !cairo_surface_ref l, filename: string): cairo_status_t = "mac#atsctrb_cairo_surface_write_to_png" // end of [cairo_surface_write_to_png] fun cairo_surface_write_to_png_stream {v:view} {vt:viewtype} {l:agz} ( pf: !v | sf: !cairo_surface_ref l , write_func: {n:nat} (!v | !vt, &(@[byte][n]), int n) - cairo_status_t , env: !vt ) : cairo_status_t = "mac#atsctrb_cairo_surface_write_to_png_stream" // end of [cairo_surface_write_to_png_stream] (* ****** ****** *) // // HX: PDF surface // (* ****** ****** *) (* #define CAIRO_HAS_PDF_SURFACE *) fun cairo_pdf_surface_create ( filename: string // read-only string , width_in_points: double, height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_pdf_surface_create" // end of [cairo_pdf_surface_create] fun cairo_pdf_surface_create_null ( width_in_points: double, height_in_points: double ) : cairo_surface_ref1 = "atsctrb_cairo_pdf_surface_create_null" // function! // end of [cairo_pdf_surface_create_null] (* ** note that [pf] and [env] can be freed only after the ** returned surface is destroyed by a call to [cairo_surface_destroy] *) fun cairo_pdf_surface_create_for_stream {v:view} {vt:viewtype} ( pf: !v | write_func: {n:nat} (!v | !vt, &(@[byte][n]), int n) - cairo_status_t , env: !vt , width_in_points: double , height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_pdf_surface_create_for_stream" // end of [cairo_pdf_surface_create_for_stream] fun cairo_pdf_surface_set_size {l:agz} ( sf: !cairo_surface_ref l , width_in_points: double, height_in_points: double ) : void = "mac#atsctrb_cairo_pdf_surface_set_size" // end of [cairo_pdf_surface_set_size] (* ****** ****** *) // // HX: PS surface // (* ****** ****** *) (* #define CAIRO_HAS_PS_SURFACE *) fun cairo_ps_surface_create ( filename: string , width_in_points: double, height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_ps_surface_create" // end of [cairo_ps_surface_create] fun cairo_ps_surface_create_null ( width_in_points: double, height_in_points: double ) : cairo_surface_ref1 = "atsctrb_cairo_ps_surface_create_null" // fun! // end of [cairo_ps_surface_create_null] (* ** note that [pf] and [env] can be freed only after the ** returned surface is destroyed by a call to [cairo_surface_destroy] *) fun cairo_ps_surface_create_for_stream {v:view} {vt:viewtype} ( pf: !v | write_func: {n:nat} (!v | !vt, &(@[byte][n]), int n) - cairo_status_t , env: !vt , width_in_points: double , height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_ps_surface_create_for_stream" // end of [cairo_ps_surface_create_for_stream] (* // // enum // abst@ype cairo_ps_level_t = $extype"cairo_ps_level_t" macdef CAIRO_PS_LEVEL_2 = $extval (cairo_ps_level_t, "CAIRO_PS_LEVEL_2") macdef CAIRO_PS_LEVEL_3 = $extval (cairo_ps_level_t, "CAIRO_PS_LEVEL_3") (* void cairo_ps_get_levels (cairo_ps_level_t const **levels, int *num_levels); *) fun cairo_ps_get_levels ( num_levels: &int? >> int n ) : #[n:nat] array (cairo_ps_level_t, n) = "mac#atsctrb_cairo_ps_get_levels" // end of [cairo_ps_get_levels] // // HX: a NULL ptr is returned if [level] is invalid // fun cairo_ps_level_to_string ( level: cairo_ps_level_t ) : [l:addr] (strptr(l) - void | strptr(l)) = "mac#atsctrb_cairo_ps_level_to_string" // end of [cairo_ps_level_to_string] *) fun cairo_ps_surface_set_size {l:agz} ( sf: !cairo_surface_ref l , width_in_points: double, height_in_points: double ) : void = "mac#atsctrb_cairo_ps_surface_set_size" // end of [fun] fun cairo_ps_surface_dsc_begin_setup {l:agz} ( sf: !cairo_surface_ref l ) : void = "mac#atsctrb_cairo_ps_surface_dsc_begin_setup" // end of [cairo_ps_surface_dsc_begin_setup] fun cairo_ps_surface_dsc_begin_page_setup {l:agz} ( sf: !cairo_surface_ref l ) : void = "mac#atsctrb_cairo_ps_surface_dsc_begin_page_setup" // end of [cairo_ps_surface_dsc_begin_page_setup] fun cairo_ps_surface_dsc_comment {l:agz} ( sf: !cairo_surface_ref l , comment: string // read-only ) : void = "mac#atsctrb_cairo_ps_surface_dsc_comment" // end of [cairo_ps_surface_dsc_comment] (* ****** ****** *) (* #define CAIRO_HAS_SVG_SURFACE *) fun cairo_svg_surface_create ( filename: string , width_in_points: double, height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_svg_surface_create" // end of [fun] (* ** note that [pf] and [env] can be freed only after the ** returned surface is destroyed by a call to [cairo_surface_destroy] *) fun cairo_svg_surface_create_for_stream {v:view} {vt:viewtype} ( pf: !v | write_func: {n:nat} (!v | !vt, &(@[byte][n]), int n) - cairo_status_t , env: !vt , width_in_points: double , height_in_points: double ) : cairo_surface_ref1 = "mac#atsctrb_cairo_svg_surface_create_for_stream" // end of [fun] // enum type abst@ype cairo_svg_version_t = $extype"cairo_svg_version_t" fun cairo_svg_surface_restrict_to_version {l:agz} ( cr: !cairo_ref l, version: cairo_svg_version_t ) : void = "mac#atsctrb_cairo_svg_surface_restrict_to_version" // end of [fun] fun cairo_svg_get_versions ( n: &int? >> int n ) : #[n:nat] array (cairo_svg_version_t, n) = "atsctrb_cairo_svg_get_versions" // this is a function! // end of [fun] // // HX: the return string is statically allocated // fun cairo_svg_version_to_string ( version: cairo_svg_version_t ) : string = "mac#atsctrb_cairo_svg_version_to_string" // end of [fun] (* ****** ****** *) // // HX: Quartz surface // (* ****** ****** *) (* #define CAIRO_HAS_QUARTZ_SURFACE *) fun cairo_quartz_surface_create ( format: cairo_format_t, width: uint, height: uint ) : cairo_surface_ref1 = "mac#atsctrb_cairo_quartz_surface_create" // end of [fun] (* ** HX (2010-01-9): ** this type should probably be linear; however I do not really know ** how it can be properly handled as I have never used it. *) abstype CGContextRef = $extype"CGContextRef" fun cairo_quartz_surface_create_for_cg_context ( cgContext: CGContextRef, width: uint, height: uint ) : cairo_surface_ref1 = "mac#atsctrb_cairo_quartz_surface_create_for_cg_context" // end of [cairo_quartz_surface_create_for_cg_context] fun cairo_quartz_surface_get_cg_context {l:agz} ( surface: !cairo_surface_ref l ) : CGContextRef = "mac#atsctrb_cairo_quartz_surface_get_cg_context" // end of [cairo_quartz_surface_get_cg_context] (* ****** ****** *) // // Xlib surface // (* #define CAIRO_HAS_XLIB_SURFACE *) staload X = "contrib/X11/SATS/X.sats" staload Xlib = "contrib/X11/SATS/Xlib.sats" stadef Drawable = $X.Drawable stadef Pixmap = $X.Pixmap stadef Display_ptr = $Xlib.Display_ptr stadef Screen_ptr = $Xlib.Screen_ptr stadef Visual_ptr = $Xlib.Visual_ptr fun cairo_xlib_surface_create {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable , visual: !Visual_ptr l2 , width: int, height: int ) : cairo_surface_ref1 = "mac#atsctrb_cairo_xlib_surface_create" // end of [cairo_xlib_surface_create] fun cairo_xlib_surface_create_for_bitmap {l1,l2:agz} ( dpy: !Display_ptr l1 , bitmap: Pixmap , scr: !Screen_ptr l2 , width: int, height: int ) : cairo_surface_ref1 = "mac#atsctrb_cairo_xlib_surface_create_for_bitmap" // end of [cairo_xlib_surface_create_for_bitmap] fun cairo_xlib_surface_set_size {l:agz} ( surface: !cairo_surface_ref l , width: int, height: int ) : void = "mac#atsctrb_cairo_xlib_surface_set_size" // end of [cairo_xlib_surface_set_size] fun cairo_xlib_surface_set_drawable {l:agz} ( surface: !cairo_surface_ref l , drw: Drawable, width: int, height: int ) : void = "mac#atsctrb_cairo_xlib_surface_set_drawable" // end of [cairo_xlib_surface_set_drawable] fun cairo_xlib_surface_get_drawable {l:agz} ( surface: !cairo_surface_ref l ) : Drawable = "mac#atsctrb_cairo_xlib_surface_get_drawable" // end of [cairo_xlib_surface_get_drawable] fun cairo_xlib_surface_get_display {l1:agz} ( surface: !cairo_surface_ref l1 ) : [l2:agz] ( minus (cairo_surface_ref l1, Display_ptr l2) | Display_ptr l2 ) = "mac#atsctrb_cairo_xlib_surface_get_display" // end of [cairo_xlib_surface_get_display] fun cairo_xlib_surface_get_screen {l1:agz} ( surface: !cairo_surface_ref l1 ) : [l2:agz] ( minus (cairo_surface_ref l1, Screen_ptr l2) | Screen_ptr l2 ) = "mac#atsctrb_cairo_xlib_surface_get_screen" // end of [cairo_xlib_surface_get_screen] fun cairo_xlib_surface_get_visual {l1:agz} ( surface: !cairo_surface_ref l1 ) : [l2:agz] ( minus (cairo_surface_ref l1, Visual_ptr l2) | Visual_ptr l2 ) = "mac#atsctrb_cairo_xlib_surface_get_visual" // end of [cairo_xlib_surface_get_visual] fun cairo_xlib_surface_get_width {l:agz} ( surface: !cairo_surface_ref l ) : int = "mac#atsctrb_cairo_xlib_surface_get_width" // end of [cairo_xlib_surface_get_width] fun cairo_xlib_surface_get_height {l:agz} ( surface: !cairo_surface_ref l ) : int = "mac#atsctrb_cairo_xlib_surface_get_height" // end of [cairo_xlib_surface_get_height] fun cairo_xlib_surface_get_depth {l:agz} ( surface: !cairo_surface_ref l ) : int = "mac#atsctrb_cairo_xlib_surface_get_depth" // end of [cairo_xlib_surface_get_depth] (* ****** ****** *) // // HX: utilities for drawing // (* ****** ****** *) // // generic matrix operations // (* ****** ****** *) fun cairo_matrix_init ( matrix: &cairo_matrix_t? >> cairo_matrix_t , xx: double, yx: double , xy: double, yy: double , x0: double, y0: double ) : void = "mac#atsctrb_cairo_matrix_init" // end of [fun] fun cairo_matrix_init_identity ( matrix: &cairo_matrix_t? >> cairo_matrix_t ) : void = "mac#atsctrb_cairo_matrix_init_identity" // end of [fun] fun cairo_matrix_init_translate ( matrix: &cairo_matrix_t? >> cairo_matrix_t , tx: double, ty: double ) : void = "mac#atsctrb_cairo_matrix_init_translate" // end of [cairo_matrix_init_translate] fun cairo_matrix_init_scale ( matrix: &cairo_matrix_t? >> cairo_matrix_t , sx: double, sy: double ) : void = "mac#atsctrb_cairo_matrix_init_scale" // end of [cairo_matrix_init_scale] fun cairo_matrix_init_rotate ( matrix: &cairo_matrix_t? >> cairo_matrix_t , angle: double ) : void = "mac#atsctrb_cairo_matrix_init_rotate" // end of [cairo_matrix_init_rotate] (* ****** ****** *) fun cairo_matrix_translate ( matrix: &cairo_matrix_t >> cairo_matrix_t , tx: double, ty: double ) : void = "mac#atsctrb_cairo_matrix_translate" // end of [cairo_matrix_translate] fun cairo_matrix_scale ( matrix: &cairo_matrix_t >> cairo_matrix_t , sx: double, sy: double ) : void = "mac#atsctrb_cairo_matrix_scale" // end of [cairo_matrix_scale] fun cairo_matrix_rotate ( matrix: &cairo_matrix_t >> cairo_matrix_t , angle: double ) : void = "mac#atsctrb_cairo_matrix_rotate" // end of [cairo_matrix_rotate] (* ****** ****** *) fun cairo_matrix_invert ( matrix: &cairo_matrix_t >> cairo_matrix_t ) : cairo_status_t = "mac#atsctrb_cairo_matrix_invert" // end of [fun] fun cairo_matrix_multiply ( result: &cairo_matrix_t? >> cairo_matrix_t , amatrix: &cairo_matrix_t (*read*) , bmatrix: &cairo_matrix_t (*read*) ) : void = "mac#atsctrb_cairo_matrix_multiply" // end of [fun] fun cairo_matrix_transform_distance ( matrix: &cairo_matrix_t (*read*) , dx: &double , dy: &double ) : void = "mac#atsctrb_cairo_matrix_transform_distance" // end of [fun] fun cairo_matrix_transform_point ( matrix: &cairo_matrix_t (*read*) , x: &double , y: &double ) : void = "mac#atsctrb_cairo_matrix_transform_point" // end of [fun] (* ****** ****** *) // // HX: error handling // (* ****** ****** *) // // HX: all error strings are statically allocated // fun cairo_status_to_string ( status: cairo_status_t ) : string = "mac#atsctrb_cairo_status_to_string" // end of [fun] fun cairo_debug_reset_static_data ( // there is no argument for the function ) : void = "mac#atsctrb_cairo_debug_reset_static_data" // end of [fun] (* ****** ****** *) // // HX: cairo version macros and functions // macdef CAIRO_VERSION = $extval (int, "CAIRO_VERSION") macdef CAIRO_VERSION_MAJOR = $extval (int, "CAIRO_VERSION_MAJOR") macdef CAIRO_VERSION_MINOR = $extval (int, "CAIRO_VERSION_MINOR") macdef CAIRO_VERSION_MICRO = $extval (int, "CAIRO_VERSION_MICRO") macdef CAIRO_VERSION_STRING = $extval (string, "CAIRO_VERSION_STRING") fun CAIRO_VERSION_ENCODE ( major: int, minor: int, micro: int ) : int = "mac#CAIRO_VERSION_ENCODE" // end of [fun] fun CAIRO_VERSION_STRINGIZE ( major: int, minor: int, micro: int ) : string = "mac#CAIRO_VERSION_STRINGIZE" // end of [fun] fun cairo_version (): int = "mac#atsctrb_cairo_version" // end of [cairo_version] fun cairo_version_string ( // there is no argument for the function ) : string = "atsctrb_cairo_version_string" // function! // end of [fun] (* ****** ****** *) (* end of [cairo.sats] *) ats-lang-anairiats-0.2.11/contrib/cairo/Makefile0000664000175000017500000000123612223166165020177 0ustar hwxihwxi# # API for cairo in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: December, 2009 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall XRCFLAGS=`pkg-config cairo --cflags` ###### all:: atsctrb_cairo.o all:: clean ###### atsctrb_cairo.o: \ cairo_dats.o cairo_extra_dats.o ld -r -o $@ $^ ###### cairo_dats.o: DATS/cairo.dats $(ATSCC) $(XRCFLAGS) -o $@ -c DATS/cairo.dats cairo_extra_dats.o: DATS/cairo_extra.dats $(ATSCC) $(XRCFLAGS) -o $@ -c DATS/cairo_extra.dats ###### clean:: rm -f *_?ats.c *_?ats.o cleanall: clean rm -f atsctrb_cairo.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/cairo/DATS/0000700000175000017500000000000012223166165017254 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cairo/DATS/cairo.dats0000664000175000017500000000706112223166165021246 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) implement cairo_create0 (sf) = cr where { val cr = cairo_create (sf); val () = cairo_surface_destroy (sf) } // end of [cairo_create0] (* ****** ****** *) implement cairo_get1_target (cr) = sf1 where { val (fpf_sf | sf) = cairo_get_target (cr) val sf1 = cairo_surface_reference (sf) // increase refcount by 1 prval () = minus_addback (fpf_sf, sf | cr) // return borrowed resource } // end of [cairo_get_target1] implement cairo_get1_group_target (cr) = sf1 where { val (fpf_sf | sf) = cairo_get_group_target (cr) val sf1 = cairo_surface_reference (sf) // increase refcount by 1 prval () = minus_addback (fpf_sf, sf | cr) // return borrowed resource } // end of [cairo_get_group_target1] (* ****** ****** *) (* // // implementing [cairo_surface_write_to_png] in terms of // [cairo_surface_write_to_png_stream] // // fun cairo_surface_write_to_png // (sf: !cairo_surface_ref, filename: string): cairo_status_t implement cairo_surface_write_to_png (sf, filename) = let val [l:addr] (pfopt_fil | p_fil) = $STDIO.fopen_err (filename, file_mode_w) in if (p_fil <> null) then let prval Some_v pf_fil = pfopt_fil viewdef V = FILE w @ l; viewtypedef VT = ptr l fn f (pf: !V | env: !VT, data: string, n0: uint) : cairo_status_t = let extern fun fwrite (data: string, n: size_t, fil: &FILE w): size_t = "atslib_fwrite_byte" val n0 = size_of_uint (n0) val n1 = fwrite (data, n0, !env) in if n1 < n0 then CAIRO_STATUS_WRITE_ERROR else CAIRO_STATUS_SUCCESS end // end of [fn f] val status = cairo_surface_write_to_png_stream {V} {VT} (pf_fil | sf, f, p_fil) val () = $STDIO.fclose1_exn (pf_fil | p_fil) in status end else let prval None_v () = pfopt_fil in CAIRO_STATUS_WRITE_ERROR end // end of [if] end // end of [cairo_surface_write_to_png] *) (* ****** ****** *) (* end of [cairo.dats] *) ats-lang-anairiats-0.2.11/contrib/cairo/DATS/cairo_extra.dats0000664000175000017500000000464312223166165022454 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: July, 2010 // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" staload "contrib/cairo/SATS/cairo_extra.sats" (* ****** ****** *) implement cairo_show_text_inbox (cr, bxw, bxh, utf8) = () where { val (pf | ()) = cairo_save (cr) // val () = cairo_set_font_size (cr, 1.0(*FONTSIZE*)) // HX: the value should not matter // var te : cairo_text_extents_t // val () = cairo_text_extents (cr, utf8, te) val alpha = (1.0 * bxw / te.width) // this is just an estimate val () = cairo_scale (cr, alpha, alpha) // val () = cairo_text_extents (cr, utf8, te) val w = te.width and h = te.height val x_base = w / 2 + te.x_bearing and y_base = ~te.y_bearing / 2 val () = cairo_move_to (cr, ~x_base, y_base) val () = cairo_show_text (cr, utf8) // val () = cairo_restore (pf | cr) } // end of [cairo_show_text_inbox] (* ****** ****** *) (* end of [cairo_extra.dats] *) ats-lang-anairiats-0.2.11/contrib/jansson/0000700000175000017500000000000012223166165017077 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/jansson/CATS/0000700000175000017500000000000012223166165017631 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/jansson/CATS/jansson.cats0000664000175000017500000001576412223166165022211 0ustar hwxihwxi/* ** Copyright (C) 2010 Chris Double. ** ** Permission to use, copy, modify, and distribute this software for any ** purpose with or without fee is hereby granted, provided that the above ** copyright notice and this permission notice appear in all copies. ** ** THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES ** WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF ** MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ** ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ** WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ** ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ** OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ /* ****** ****** */ /* ** Time: September, 2012 ** Author Hongwei Xi (gmhwxi AT gmail DOT com) ** ** The API is simplied a bit in the hope that it can be used more easily. */ /* ****** ****** */ #ifndef ATSCTRB_JANSSON_JANSSON_CATS #define ATSCTRB_JANSSON_JANSSON_CATS /* ****** ****** */ #include /* ****** ****** */ typedef json_t *JSONptr ; typedef const json_t *JSONconstptr ; /* ****** ****** */ #define atsctrb_json_typeof json_typeof /* ****** ****** */ #define atsctrb_json_is_null(x) json_is_null((JSONptr)x) #define atsctrb_json_is_true(x) json_is_true((JSONptr)x) #define atsctrb_json_is_false(x) json_is_false((JSONptr)x) #define atsctrb_json_is_boolean(x) json_is_boolean((JSONptr)x) #define atsctrb_json_is_integer(x) json_is_integer((JSONptr)x) #define atsctrb_json_is_real(x) json_is_real((JSONptr)x) #define atsctrb_json_is_number(x) json_is_number((JSONptr)x) #define atsctrb_json_is_string(x) json_is_string((JSONptr)x) #define atsctrb_json_is_array(x) json_is_array((JSONptr)x) #define atsctrb_json_is_object(x) json_is_object((JSONptr)x) /* ****** ****** */ #define atsctrb_json_incref json_incref #define atsctrb_json_decref json_decref /* ****** ****** */ #define atsctrb_json_null json_null #define atsctrb_json_true json_true #define atsctrb_json_false json_false /* ****** ****** */ #define atsctrb_json_integer json_integer #define atsctrb_json_integer_value json_integer_value #define atsctrb_json_integer_set json_integer_set /* ****** ****** */ #define atsctrb_json_real json_real #define atsctrb_json_real_value json_real_value #define atsctrb_json_real_set json_real_set /* ****** ****** */ #define atsctrb_json_number_value json_number_value /* ****** ****** */ #define atsctrb_json_string json_string #define atsctrb_json_string_nocheck json_string_nocheck #define atsctrb_json_string_value(x) ((char*)json_string_value(x)) #define atsctrb_json_string_set json_string_set #define atsctrb_json_string_set_nocheck json_string_set_nocheck /* ****** ****** */ #define atsctrb_json_array json_array #define atsctrb_json_array_size json_array_size /* ****** ****** */ #define atsctrb_json_array_get json_array_get ATSinline() ats_ptr_type atsctrb_json_array_get_exnmsg ( ats_ptr_type json, ats_size_type ind, ats_ptr_type msg ) { JSONptr itm ; itm = atsctrb_json_array_get (json, ind) ; if (!itm) { fprintf (stderr, "exit(ATS): json_array_get: %s\n", (char*)msg) ; exit (1); } // end of [if] return itm ; } // end of [atsctrb_json_array_get_exnmsg] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_json_array_get1 ( ats_ptr_type json, ats_size_type ind ) { JSONptr itm ; itm = json_array_get((JSONptr)json, ind); if (itm) json_incref(itm) ; return (itm) ; } // end of [atsctrb_json_array_get1] ATSinline() ats_ptr_type atsctrb_json_array_get1_exnmsg ( ats_ptr_type json, ats_size_type ind, ats_ptr_type msg ) { JSONptr itm ; itm = atsctrb_json_array_get1 (json, ind) ; if (!itm) { fprintf (stderr, "exit(ATS): json_array_get1: %s\n", (char*)msg) ; exit (1); } // end of [if] return (itm) ; } // end of [atsctrb_json_array_get1_exnmsg] /* ****** ****** */ #define atsctrb_json_array_set json_array_set #define atsctrb_json_array_set_new json_array_set_new #define atsctrb_json_array_append json_array_append #define atsctrb_json_array_append_new json_array_append_new #define atsctrb_json_array_insert json_array_insert #define atsctrb_json_array_insert_new json_array_insert_new #define atsctrb_json_array_remove json_array_remove #define atsctrb_json_array_clear json_array_clear #define atsctrb_json_array_extend json_array_extend /* ****** ****** */ #define atsctrb_json_object json_object #define atsctrb_json_object_size json_object_size /* ****** ****** */ #define atsctrb_json_object_get json_object_get ATSinline() ats_ptr_type atsctrb_json_object_get_exnmsg ( ats_ptr_type json, ats_ptr_type key, ats_ptr_type msg ) { JSONptr itm ; itm = atsctrb_json_object_get (json, key) ; if (!itm) { fprintf (stderr, "exit(ATS): json_object_get: %s\n", (char*)msg) ; exit (1); } // end of [if] return itm ; } // end of [atsctrb_json_object_get_exnmsg] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_json_object_get1 ( ats_ptr_type json, ats_ptr_type key ) { JSONptr itm ; itm = atsctrb_json_object_get (json, key) ; if (itm) json_incref(itm) ; return (itm) ; } // end of [atsctrb_json_object_get1] ATSinline() ats_ptr_type atsctrb_json_object_get1_exnmsg ( ats_ptr_type json, ats_ptr_type key, ats_ptr_type msg ) { JSONptr itm ; itm = atsctrb_json_object_get1 (json, key) ; if (!itm) { fprintf (stderr, "exit(ATS): json_object_get1: %s\n", (char*)msg) ; exit (1); } // end of [if] return (itm) ; } // end of [atsctrb_json_object_get1_exnmsg] #define atsctrb_json_object_set json_object_set #define atsctrb_json_object_set_nocheck json_object_set_nocheck #define atsctrb_json_object_set_new json_object_set_new #define atsctrb_json_object_set_new_nocheck json_object_set_new_nocheck #define atsctrb_json_object_del json_object_del #define atsctrb_json_object_clear json_object_clear #define atsctrb_json_object_update json_object_update #define atsctrb_json_object_update_existing json_object_update_existing #define atsctrb_json_object_update_missing json_object_update_missing /* ****** ****** */ #define atsctrb_json_object_iter json_object_iter #define atsctrb_json_object_iter_at json_object_iter_at #define atsctrb_json_object_iter_next json_object_iter_next #define atsctrb_json_object_iter_nextret json_object_iter_nextret /* ****** ****** */ #define atsctrb_json_object_iter_key json_object_iter_key #define atsctrb_json_object_iter_value json_object_iter_value #define atsctrb_json_object_iter_set json_object_iter_set #define atsctrb_json_object_iter_set_new json_object_iter_set_new #define atsctrb_json_object_key_to_iter json_object_key_to_iter /* ****** ****** */ #define atsctrb_json_loads json_loads #define atsctrb_json_loadb json_loadb #define atsctrb_json_loadf json_loadf #define atsctrb_json_load_file json_load_file #define atsctrb_json_dumps json_dumps #define atsctrb_json_dumpf json_dumpf #define atsctrb_json_dump_file json_dump_file /* ****** ****** */ #endif // ifndef ATSHOME_CONTRIB_JANSSON_JANSSON_CATS /* ****** ****** */ /* end of [jansson.cats] */ ats-lang-anairiats-0.2.11/contrib/jansson/TEST/0000700000175000017500000000000012223166165017656 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/jansson/TEST/test01.dats0000664000175000017500000000277712223166165021704 0ustar hwxihwxi(* ** Copyright (C) 2010 Chris Double. ** ** Permission to use, copy, modify, and distribute this software for any ** purpose with or without fee is hereby granted, provided that the above ** copyright notice and this permission notice appear in all copies. ** ** THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES ** WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF ** MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ** ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ** WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ** ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ** OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. *) (* ** Some modification by Hongwei Xi (September 2012) *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "jansson/SATS/jansson.sats" (* ****** ****** *) implement main () = let // var err: json_err? // val rt = json_loads ("{\"one\":1}", 0, err) val () = assertloc (JSONptr_isnot_null (rt)) val (fpf | one) = json_object_get_exnloc (rt, "one") val ji = json_integer_value (one) val () = printf ("int = %i\n", @($UN.cast2int(ji))) prval () = minus_addback (fpf, one | rt) // val _(*err*) = json_dumpf (rt, stdout_ref, 0) // end of [val] val () = fprint_newline (stdout_ref) // val () = json_decref(rt) in // nothing end // end of [main] (* ****** ****** *) (* end of [test01.dats] *) ats-lang-anairiats-0.2.11/contrib/jansson/TEST/Makefile0000664000175000017500000000145512223166165021337 0ustar hwxihwxi# # A simple Makefile # ###### ATSCC=$(ATSHOME)/bin/atscc ###### CCFLAGS=-O2 ###### ATSCTRB=$(ATSHOME)/contrib ###### all:: all:: test01 all:: test02 all:: github_commits ###### clean:: cleanall:: ###### test01: test01_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -IATS$(ATSCTRB) -o $@ $< -ljansson cleanall:: ; $(RMF) test01 test02: test02_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -IATS$(ATSCTRB) -o $@ $< -ljansson cleanall:: ; $(RMF) test02 ###### github_commits: github_commits_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -IATS$(ATSCTRB) -o $@ $< -ljansson -lcurl cleanall:: ; $(RMF) github_commits ###### %_dats.c: %.dats ; $(ATSCC) -cc -IATS$(ATSCTRB) $< ###### RMF=rm -f ###### clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.o *_?ats.c ###### cleanall:: clean ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/jansson/TEST/test02.dats0000664000175000017500000000303012223166165021664 0ustar hwxihwxi(* ** Copyright (C) 2010 Chris Double. ** ** Permission to use, copy, modify, and distribute this software for any ** purpose with or without fee is hereby granted, provided that the above ** copyright notice and this permission notice appear in all copies. ** ** THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES ** WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF ** MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ** ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ** WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ** ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ** OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. *) (* ** Some modification by Hongwei Xi (September 2012) *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload "jansson/SATS/jansson.sats" (* ****** ****** *) #define isnz JSONptr_isnot_null (* ****** ****** *) implement main () = let // val a = json_string("this is a string") val () = assertloc(isnz(a)) val () = assertloc(json_is_string(a)) // val ( fpf | s ) = json_string_value(a) val s2 = strptr_dup(s) prval () = minus_addback (fpf, s | a) // val err = json_string_set(a, $UN.castvwtp1{string}(s2)) val () = print_string("Value is: ") val () = print_strptr(s2) val () = print_newline() val () = strptr_free(s2) val () = json_decref(a) in // nothing end // end of [main] (* ****** ****** *) (* end of [test01.dats] *) ats-lang-anairiats-0.2.11/contrib/jansson/TEST/github_commits.dats0000664000175000017500000001264012223166165023567 0ustar hwxihwxi// // For testing the ATS API for jansson // Only the ATS code here is written by Hongwei Xi // %{^ /* * Copyright (c) 2009-2012 Petri Lehtinen * * Jansson is free software; you can redistribute it and/or modify * it under the terms of the MIT license. See LICENSE for details. */ #include #include #include #include #define BUFFER_SIZE (256 * 1024) /* 256 KB */ /* Return the offset of the first newline in text or the length of text if there's no newline */ struct write_result { char *data; int pos; }; static size_t write_response ( void *ptr, size_t size, size_t nmemb, void *stream ) { struct write_result *result = (struct write_result *)stream; if(result->pos + size * nmemb >= BUFFER_SIZE - 1) { fprintf(stderr, "error: too small buffer\n"); return 0; } memcpy(result->data + result->pos, ptr, size * nmemb); result->pos += size * nmemb; return size * nmemb; } static char *request(const char *url) { CURL *curl; CURLcode status; char *data; long code; curl = curl_easy_init(); data = malloc(BUFFER_SIZE); if(!curl || !data) return NULL; struct write_result write_result = { .data = data, .pos = 0 }; curl_easy_setopt(curl, CURLOPT_URL, url); curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_response); curl_easy_setopt(curl, CURLOPT_WRITEDATA, &write_result); status = curl_easy_perform(curl); if(status != 0) { fprintf(stderr, "error: unable to request data from %s:\n", url); fprintf(stderr, "%s\n", curl_easy_strerror(status)); return NULL; } curl_easy_getinfo(curl, CURLINFO_RESPONSE_CODE, &code); if(code != 200) { fprintf(stderr, "error: server responded with code %ld\n", code); return NULL; } curl_easy_cleanup(curl); curl_global_cleanup(); /* zero-terminate the result */ data[write_result.pos] = '\0'; return data; } %} // end of [%{^] (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload "jansson/SATS/jansson.sats" (* ****** ****** *) extern fun request (url: string): strptr0 = "mac#request" (* ****** ****** *) extern fun process_root {l:addr} (root: !JSONptr l, err: &json_err): void // end of [process_root] extern fun process_root_array {l:agz} (root: !JSONptr l): void implement process_root {l} (root, err) = let prval () = addr_is_gtez {l} () val isnz = JSONptr_isnot_null (root) val () = if ~isnz then let val () = fprintf (stderr_ref, "error: on line %d: %s\n", @(err.line, $UN.cast{string}(err.text)) ) // end of [val] in exit (1) end val () = assert (isnz) val isa = json_is_array (root) val () = if ~isa then let val () = fprintf (stderr_ref, "error: root is not an array\n", @()) in exit (1) end in process_root_array {l} (root) end // end of [process_root] macdef JPNZ (x) = assertloc (JSONptr_isnot_null ,(x)) // end of [JPNZ] implement process_root_array {l} (root) = let // val n = json_array_size (root) // fun loop ( root: !JSONptr l, n: size_t, i: size_t ) : void = let in // if i < n then let // val data = json_array_get1_exnloc (root, i) // end of [val] val () = assertloc (json_is_object (data)) // val sha = json_object_get1_exnloc (data, "sha") // end of [val] val () = assertloc (json_is_string (sha)) // val commit = json_object_get1_exnloc (data, "commit") // end of [val] val () = assertloc (json_is_object (commit)) // val message = json_object_get1_exnloc (commit, "message") // end of [val] val () = assertloc (json_is_string (message)) // val (fpf1 | sha_value) = json_string_value (sha) val (fpf2 | message_value) = json_string_value (message) // val () = fprintf (stdout_ref, "%s\n", @($UN.linstr2str(sha_value))) val () = fprint_newline (stdout_ref) val () = fprintf (stdout_ref, "%s\n", @($UN.linstr2str(message_value))) val () = fprint_newline (stdout_ref) // prval () = minus_addback (fpf1, sha_value | sha) prval () = minus_addback (fpf2, message_value | message) val () = json_decref (commit) val () = json_decref (sha) val () = json_decref (message) val () = json_decref (data) // in loop (root, n, i+1) end else () // end of [if] // end // end of [loop] // in loop (root, n, 0) end // end of [process_root_array] (* ****** ****** *) #define URL_FORMAT "https://api.github.com/repos/%s/%s/commits" implement main (argc, argv) = let // val cmd = argv.[0] var arg1: string = "githwxi" var arg2: string = "ATS-Postiats" // (* val () = if (argc < 3) then let val () = fprintf(stderr_ref, "usage: %s USER REPOSITORY\n\n", @(cmd)) val () = fprintf(stderr_ref, "List commits at USER's REPOSITORY.\n\n", @()) in exit (2) end // end of [val] *) // val () = if argc >= 2 then arg1 := argv.[1] val () = if argc >= 3 then arg2 := argv.[2] // val url = sprintf (URL_FORMAT, @(arg1, arg2)) val text = request($UN.castvwtp1{string}(url)) val () = strptr_free (url) // val isnz = strptr_isnot_null (text) // in // if isnz then let var err: json_err val root = json_loads ($UN.linstr2str(text), 0, err) val () = strptr_free (text) val () = process_root (root, err) val () = json_decref(root) in exit (0) end else let prval () = strptr_free_null (text) in (*nothing*) end // end of [if] // end // end of [main] (* ****** ****** *) (* end of [github_commits.dats] *) ats-lang-anairiats-0.2.11/contrib/jansson/SATS/0000700000175000017500000000000012223166165017651 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/jansson/SATS/jansson.sats0000664000175000017500000003507612223166165022247 0ustar hwxihwxi(* ** Copyright (C) 2010 Chris Double. ** ** Permission to use, copy, modify, and distribute this software for any ** purpose with or without fee is hereby granted, provided that the above ** copyright notice and this permission notice appear in all copies. ** ** THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES ** WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF ** MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ** ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ** WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ** ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ** OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. *) (* ****** ****** *) (* ** Time: September, 2012 ** Author Hongwei Xi (gmhwxi AT gmail DOT com) ** ** The API is modified in the hope that it can be used more conveniently. *) (* ****** ****** *) %{# #include "jansson/CATS/jansson.cats" %} (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) typedef SHR(x:type) = x // for commenting purpose typedef NSH(x:type) = x // for commenting purpose (* ****** ****** *) // abst@ype json_type = $extype"json_type" // macdef JSON_OBJECT = $extval (json_type, "JSON_OBJECT") macdef JSON_ARRAY = $extval (json_type, "JSON_ARRAY") macdef JSON_STRING = $extval (json_type, "JSON_STRING") macdef JSON_INTEGER = $extval (json_type, "JSON_INTEGER") macdef JSON_REAL = $extval (json_type, "JSON_REAL") macdef JSON_TRUE = $extval (json_type, "JSON_TRUE") macdef JSON_FALSE = $extval (json_type, "JSON_FALSE") macdef JSON_NULL = $extval (json_type, "JSON_NULL") // abst@ype json_t = $extype"json_t" // json_type + refcount typedef json_error_t = $extype_struct "json_error_t" of { line= int , column= int , position= int , source= (*char*)ptr , text= (*char*)ptr } // end of [typedef] // abst@ype json_int_t = $extype"json_int_t" // largest available int type // (* ****** ****** *) absviewtype JSONptr (l:addr) // json_t* viewtypedef JSONptr0 = [l:addr] JSONptr (l) viewtypedef JSONptr1 = [l:addr | l > null] JSONptr (l) (* ****** ****** *) absviewtype JSONiter (l1:addr, l2:addr) viewtypedef JSONiter0 (l1:addr) = [l2:addr] JSONiter (l1, l2) viewtypedef JSONiter1 (l1:addr) = [l2:addr | l2 > null] JSONiter (l1, l2) (* ****** ****** *) praxi JSONptr_is_gtez {l:addr} (x: !JSONptr l): [l >= null] void praxi JSONiter_is_gtez {l1,l2:addr} (x: !JSONiter (l1, l2)): [l2 >= null] void (* ****** ****** *) castfn JSONptr2ptr {l:addr} (x: !JSONptr l):<> ptr (l) castfn JSONiter2ptr {l1,l2:addr} (x: !JSONiter (l1, l2)):<> ptr (l2) (* ****** ****** *) praxi JSONptr_free_null {l:addr | l <= null} (x: JSONptr l):<> void // end of [JSONptr_free_null] praxi JSONiter_return {l1,l2:addr} (json: !JSONptr l1, iter: JSONiter (l1, l2)):<> void // end of [JSONiter_return] (* ****** ****** *) fun JSONptr_is_null {l:addr} (x: !JSONptr l):<> bool (l==null) = "mac#atspre_ptr_is_null" // end of [JSONptr_is_null] fun JSONptr_isnot_null {l:addr} (x: !JSONptr (l)):<> bool (l > null) = "mac#atspre_ptr_isnot_null" // end of [JSONptr_isnot_null] overload ~ with JSONptr_isnot_null (* ****** ****** *) fun json_typeof {l:agz} (json: !JSONptr l): int = "mac#atsctrb_json_typeof" (* ****** ****** *) // // HX-2012-09: // these functions currently indeed return 0/1 for false/true // fun json_is_null {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_null" fun json_is_true {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_true" fun json_is_false {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_false" fun json_is_boolean {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_boolean" fun json_is_integer {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_integer" fun json_is_real {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_real" fun json_is_number {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_number" fun json_is_string {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_string" fun json_is_array {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_array" fun json_is_object {l:addr} (json: !JSONptr (l)) : bool = "mac#atsctrb_json_is_object" (* ****** ****** *) fun json_incref {l:agz} (json: !JSONptr (l)) : JSONptr (l) = "mac#atsctrb_json_incref" fun json_decref {l:addr} (json: JSONptr (l)) : void = "mac#atsctrb_json_decref" (* ****** ****** *) fun json_null () : JSONptr1 = "mac#atsctrb_json_null" fun json_true () : JSONptr1 = "mac#atsctrb_json_true" fun json_false () : JSONptr1 = "mac#atsctrb_json_false" (* ****** ****** *) fun json_string (value: NSH(string)) : JSONptr0 = "mac#atsctrb_json_string" // end of [json_string] fun json_string_nocheck (value: NSH(string)) : JSONptr0 = "mac#atsctrb_json_string_nocheck" // end of [json_string_nocheck] fun json_string_value {l1:agz} ( json: !JSONptr (l1) ) : [l2:agz] (minus (JSONptr l1, strptr l2) | strptr l2) = "mac#atsctrb_json_string_value" // end of [json_string_value] fun json_string_set {l:agz} ( json: !JSONptr (l) , value: NSH(string) ) : int = "mac#atsctrb_json_string_set" // end of [json_string_set] fun json_string_set_nocheck {l:agz} ( json: !JSONptr (l) , value: NSH(string) ) : int = "mac#atsctrb_json_string_set_nocheck" (* ****** ****** *) typedef json_int = json_int_t castfn int2json_int (x: int): json_int castfn lint2json_int (x: lint): json_int castfn llint2json_int (x: llint): json_int fun json_integer (value: json_int) : JSONptr0 = "mac#atsctrb_json_integer" // end of [json_integer] fun json_integer_value {l:agz} (json: !JSONptr l): json_int = "mac#atsctrb_json_integer_value" // end of [json_integer_value] fun json_integer_set {l:agz} ( json: !JSONptr l, value: json_int ) : int(*err*) = "mac#atsctrb_json_integer_set" (* ****** ****** *) fun json_real (value: int) : JSONptr0 = "mac#atsctrb_json_real" // end of [json_real] fun json_real_value {l:agz} (json: !JSONptr l): double = "mac#atsctrb_json_real_value" fun json_real_set {l:agz} ( json: !JSONptr l, value: double ) : int = "mac#atsctrb_json_real_set" (* ****** ****** *) fun json_number_value {l:agz} (json: !JSONptr l): double = "mac#atsctrb_json_number_value" // end of [json_number_value] (* ****** ****** *) fun json_array ((*void*)) : JSONptr0 = "mac#atsctrb_json_array" // end of [json_array] fun json_array_size {l:agz} (json: !JSONptr l) : size_t = "mac#atsctrb_json_array_size" // end of [json_array_size] (* ****** ****** *) fun json_array_get {l1:agz} ( json: !JSONptr (l1), index: size_t ) : [l2:addr] (minus (JSONptr l1, JSONptr l2) | JSONptr l2) = "mac#atsctrb_json_array_get" // end of [json_array_get] fun json_array_get_exnmsg {l1:agz} ( json: !JSONptr (l1), index: size_t, msg: NSH(string) ) : [l2:agz] (minus (JSONptr l1, JSONptr l2) | JSONptr l2) = "mac#atsctrb_json_array_get_exnmsg" // end of [json_array_get_exnmsg] macdef json_array_get_exnloc (x, i) = json_array_get_exnmsg (,(x), ,(i), #LOCATION) // end of [json_array_get_exnloc] (* ****** ****** *) fun json_array_get1 {l1:agz} (json: !JSONptr (l1), index: size_t) : JSONptr0 = "mac#atsctrb_json_array_get1" fun json_array_get1_exnmsg {l1:agz} (json: !JSONptr (l1), index: size_t, msg: NSH(string)): JSONptr1 = "mac#atsctrb_json_array_get1_exnmsg" macdef json_array_get1_exnloc (x, i) = json_array_get1_exnmsg (,(x), ,(i), #LOCATION) // end of [json_array_get1_exnloc] (* ****** ****** *) fun json_array_set {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: !JSONptr l2(*preserved*) ) : int(*err*) = "mac#atsctrb_json_array_set" fun json_array_set_new {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: JSONptr (l2) /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_array_set_new" fun json_array_append {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: !JSONptr l2(*preserved*) ) : int(*err*) = "mac#atsctrb_json_array_append" fun json_array_append_new {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: JSONptr (l2) /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_array_append_new" fun json_array_insert {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: !JSONptr l2(*preserved*) ) : int(*err*) = "mac#atsctrb_json_array_insert" fun json_array_insert_new {l1:agz}{l2:addr} ( json: !JSONptr (l1), index: size_t, value: JSONptr (l2) /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_array_insert_new" fun json_array_remove {l:agz} ( json: !JSONptr l, index: size_t ) : int(*err*) = "mac#atsctrb_json_array_remove" fun json_array_clear {l:agz} (json: !JSONptr l) : int(*0*) = "mac#atsctrb_json_array_clear" // end of [json_array_clear] fun json_array_extend {l1,l2:agz} ( json1: !JSONptr (l1), json2: !JSONptr (l2) ) : int(*err*) = "mac#atsctrb_json_array_extend" (* ****** ****** *) fun json_object ((*void*)) : JSONptr0 = "mac#atsctrb_json_object" // end of [json_object] fun json_object_size {l:agz} (json: !JSONptr l): size_t = "mac#atsctrb_json_object_size" // end of [json_object_size] fun json_object_get {l1:agz} ( json: !JSONptr l1, key: NSH(string) ) : [l2:addr] (minus (JSONptr l1, JSONptr l2) | JSONptr l2) = "mac#atsctrb_json_object_get" // end of [json_object_get] fun json_object_get_exnmsg {l1:agz} ( json: !JSONptr l1, key: NSH(string), msg: NSH(string) ) : [l2:agz] (minus (JSONptr l1, JSONptr l2) | JSONptr l2) = "atsctrb_json_object_get_exnmsg" macdef json_object_get_exnloc (x, k) = json_object_get_exnmsg (,(x), ,(k), #LOCATION) // end of [json_object_get_exnloc] (* ****** ****** *) fun json_object_get1 {l1:agz} (json: !JSONptr l1, key: NSH(string)): JSONptr0 = "mac#atsctrb_json_object_get1" fun json_object_get1_exnmsg {l1:agz} (json: !JSONptr l1, key: NSH(string), msg: NSH(string)): JSONptr1 = "mac#atsctrb_json_object_get1_exnmsg" macdef json_object_get1_exnloc (x, k) = json_object_get1_exnmsg (,(x), ,(k), #LOCATION) // end of [json_object_get1_exnloc] (* ****** ****** *) fun json_object_set {l1:agz}{l2:addr} ( json: !JSONptr (l1) , key: NSH(string) , value: !JSONptr l2(*preserved*) ) : int(*err*) = "mac#atsctrb_json_object_set" fun json_object_set_nocheck {l1:agz}{l2:addr} ( json: !JSONptr (l1) , key: NSH(string) , value: !JSONptr l2(*preserved*) ) : int(*err*) = "mac#atsctrb_json_object_set_nocheck" fun json_object_set_new {l1:agz}{l2:addr} ( json: !JSONptr (l1) , key: NSH(string) , value: JSONptr l2 /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_object_set_new" fun json_object_set_new_nocheck {l1:agz}{l2:addr} ( json: !JSONptr (l1) , key: NSH(string) , value: JSONptr l2 /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_object_set_new_nocheck" fun json_object_del {l:agz} ( json: !JSONptr l, key: NSH(string) ) : int(*err*) = "mac#atsctrb_json_object_del" fun json_object_clear {l:agz} (json: !JSONptr l): int(*err*) = "mac#atsctrb_json_object_clear" // end of [json_object_clear] fun json_object_update {l1:agz}{l2:addr} ( json1: !JSONptr l1, json2: !JSONptr l2 ) : int(*err*) = "mac#atsctrb_json_object_update" fun json_object_update_existing {l1:agz}{l2:addr} ( json1: !JSONptr l1, json2: !JSONptr l2 ) : int(*err*) = "mac#atsctrb_json_object_update_existing" fun json_object_update_missing {l1:agz}{l2:addr} ( json1: !JSONptr l1, json2: !JSONptr l2 ) : int(*err*) = "mac#atsctrb_json_object_update_missing" (* ****** ****** *) fun JSONiter_is_null {l1,l2:addr} (x: !JSONiter (l1, l2)):<> bool (l2==null) = "mac#atspre_ptr_is_null" // end of [JSONiter_is_null] fun JSONiter_isnot_null {l1,l2:addr} (x: !JSONiter (l1, l2)):<> bool (l2 > null) = "mac#atspre_ptr_isnot_null" // end of [JSONiter_isnot_null] overload ~ with JSONiter_isnot_null (* ****** ****** *) fun json_object_iter {l1:agz} ( json: !JSONptr (l1) ) : JSONiter0 (l1) = "mac#atsctrb_json_object_iter" fun json_object_iter_at {l1:agz} ( json: !JSONptr (l1), key: NSH(string) ) : JSONiter0 (l1) = "mac#atsctrb_json_object_iter_at" fun json_object_iter_next {l1,l2:agz} ( json: !JSONptr l1, iter: !JSONiter (l1, l2) ) : JSONiter0 (l1) = "mac#atsctrb_json_object_iter_next" fun json_object_iter_nextret {l1,l2:agz} ( json: !JSONptr l1, iter: JSONiter (l1, l2) ) : JSONiter0 (l1) = "mac#atsctrb_json_object_iter_nextret" (* ****** ****** *) absviewtype objkey_addr_viewtype (l:addr) = ptr stadef objkey = objkey_addr_viewtype praxi objkey_return {l:addr} (json: !JSONptr l, key: objkey l):<> void // end of [objkey_return] fun json_object_iter_key {l1,l2:agz} ( iter: !JSONiter (l1, l2) ) : objkey l1 = "mac#atsctrb_json_object_iter_key" fun json_object_iter_value {l1,l2:agz} ( iter: !JSONiter (l1, l2) ) : JSONptr1 = "mac#atsctrb_json_object_iter_value" (* ****** ****** *) fun json_object_iter_set {l1,l2,l3:agz} ( json: !JSONptr l1 , iter: !JSONiter (l1, l2) , value: !JSONptr l3(*preserved*) ) : int(*err*) = "mac#atsctrb_json_object_iter_set" fun json_object_iter_set_new {l1,l2,l3:agz} ( json: !JSONptr l1 , iter: !JSONiter (l1, l2) , value: JSONptr l3 /*consumed*/ ) : int(*err*) = "mac#atsctrb_json_object_iter_set_new" (* ****** ****** *) /* void *json_object_key_to_iter(const char *key) */ fun json_object_key_to_iter {l:addr} ( key: objkey (l) ) : JSONiter1 (l) = "mac#atsctrb_json_object_key_to_iter" (* ****** ****** *) macdef JSON_COMPACT = $extval (int, "JSON_COMPACT") macdef JSON_ENSURE_ASCII = $extval (int, "JSON_ENSURE_ASCII") macdef JSON_SORT_KEYS = $extval (int, "JSON_SORT_KEYS") macdef JSON_PRESERVE_ORDER = $extval (int, "JSON_PRESERVE_ORDER") macdef JSON_ENCODE_ANY = $extval (int, "JSON_ENCODE_ANY") (* ****** ****** *) typedef json_err = json_error_t fun json_loads ( inp: NSH(string) , flags: int , error: &json_err? >> json_err ) : JSONptr0 = "mac#atsctrb_json_loads" fun json_loadb {lb:addr} {n1,n2:int | n1 >= n2} ( pfbuf: !bytes(n1) @ lb | pbuf: ptr lb, n2: size_t n2 , flags: int , error: &json_err? >> json_err ) : JSONptr0 = "mac#atsctrb_json_loadb" fun json_loadf ( inp: FILEref , flags: int , error: &json_err? >> json_err ) : JSONptr0 = "mac#atsctrb_json_loadf" fun json_load_file ( path: NSH(string) , flags: int , error: &json_err? >> json_err ) : JSONptr0 = "mac#atsctrb_json_load_file" (* ****** ****** *) fun json_dumps {l:agz} (root: !JSONptr l, flags: int): strptr0 = "mac#atsctrb_json_dumps" // end of [json_dumps] fun json_dumpf {l:agz} ( root: !JSONptr l , out: FILEref, flags: int ) : int(*err*) = "mac#atsctrb_json_dumpf" fun json_dump_file {l:agz} ( root: !JSONptr l , path: NSH(string), flags: int ) : int(*err*) = "mac#atsctrb_json_dump_file" (* ****** ****** *) (* end of [jasson.sats] *) ats-lang-anairiats-0.2.11/contrib/jansson/Makefile0000664000175000017500000000117212223166165020554 0ustar hwxihwxi# # API for cairo in ATS # # Start Time: August, 2012 # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # ###### ATSHOMEQ="$(ATSHOME)" ###### ATSCC=$(ATSHOMEQ)/bin/atscc ATSCTRB="$(ATSHOME)"/contrib JANSSONCLFLAGS=-ljansson ###### all:: ###### all:: atsctrb_jansson.o atsctrb_jansson.o: jansson_dats.o ; ld -r -o $@ $^ ###### jansson_dats.o: DATS/jansson.dats $(ATSCC) -O2 -I$(ATSCTRB) -IATS$(ATSCTRB) -o $@ -c $< $(JANSSONCLFLAGS) ###### RMF=rm -f ###### all:: clean clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.c *_?ats.o ###### cleanall:: clean cleanall:: ; $(RMF) atsctrb_jansson.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/jansson/DATS/0000700000175000017500000000000012223166165017632 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/jansson/DATS/jansson.dats0000664000175000017500000000322112223166165022174 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** Start Time: September, 2012 ** Author: Hongwei Xi (gmhwxi AT gmail DOT com) *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "jansson/SATS/jansson.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) macdef null = the_null_ptr (* ****** ****** *) (* ****** ****** *) (* end of [mysql.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/0000700000175000017500000000000012223166163017045 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/parcomb/dynloadall.dats0000664000175000017500000000321312223166162022057 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi ( hwxi AT cs DOT bu DOT edu ) *) (* ****** ****** *) dynload "contrib/parcomb/DATS/posloc.dats" dynload "contrib/parcomb/DATS/parcomb.dats" dynload "contrib/parcomb/DATS/tokenize.dats" (* ****** ****** *) (* end of [dynloadall.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/TEST/0000700000175000017500000000000012223166163017624 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/parcomb/TEST/calc1_example.dats0000664000175000017500000000713112223166163023215 0ustar hwxihwxi(* ** ** An example of parsing based on parsing combinators ** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December 2008 (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] (* ****** ****** *) staload "contrib/parcomb/SATS/parcomb.sats" ; (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "contrib/parcomb/DATS/parcomb.dats" ; (* ****** ****** *) (* ** expr = term expr' ** expr' = (PLUS | MINUS) term expr' | /* empty */ ** term = term term' ** term' = (TIMES | DIVIDES) factor term' | /* empty */ ** factor = integer | LPAREN expr RPAREN | UMINUS factor *) infix (|| + 1) wth infixl (&& + 2) <<; infixr (&& + 1) >> postfix ^* ^+ (* ****** ****** *) typedef charpar (a:t@ype) = parser_t (a, char) typedef lcharpar (a:t@ype) = lazy (charpar (a)) val anychar = any_parser () fn litchar (c0): charpar (char) = anychar \sat (lam (c:char): bool = (c0 = c)) (* ****** ****** *) val LPAREN = litchar '\('; val RPAREN = litchar ')' val PLUS = litchar '+'; val MINUS = litchar '-' val TIMES = litchar '*'; val DIVIDES = litchar '/' val UMINUS = litchar '~' // datatype unit = unit of () val SPACE = (anychar \sat char_isspace): charpar (char) val p_spaces = discard_many_parser (SPACE): charpar (unit) val rec lp_digit: lcharpar int = $delay ( (anychar \sat char_isdigit) wth digit_val_get ) where { fn digit_val_get (c: char):<> int = (c - '0') } // end of [lp_digit] and lp_integer: lcharpar int = $delay (!lp_digit^+ wth f) where { fn f (ds: List1 int):<0> int = loop (ds, d) where { val+ list_cons (d, ds) = ds fun loop {n:nat} .. (ds: list (int, n), i: int):<0> int = begin case+ ds of | list_cons (d, ds) => loop (ds, d + 10 * i) | list_nil () => i end // end of [loop] } // end of [f] } // end of [lp_integer] typedef intc = int - int typedef intintc = @(int, intc) val rec lp_expr : lcharpar int = $delay ( seq2wth_parser_fun (lzeta lp_term, lzeta lp_expr', f) ) where { val f = lam (t: int, k: intc): int = k (t) } // end of [lp_expr] and lp_expr' : lcharpar intc = $delay ( p_spaces >> ( seq3wth_parser_fun (PLUS || MINUS, lzeta lp_term, lzeta lp_expr', f) || return (lam (t: int) = t) ) ) where { fn f (c: char, t: int, k: intc):<> intc = begin if c = '+' then lam t0 => k (t0 + t) else lam t0 => k (t0 - t) end // end of [f] } // end of [lp_expr'] and lp_term : lcharpar int = $delay ( seq2wth_parser_fun (lzeta lp_factor, lzeta lp_term', f) ) where { val f = lam (t: int, k: intc): int = k (t) } // end of [lp_term] and lp_term' : lcharpar intc = $delay ( p_spaces >> ( seq3wth_parser_fun (TIMES || DIVIDES, lzeta lp_factor, lzeta lp_term', f) || return (lam (t: int) = t) ) ) where { fn f (c: char, t: int, k: intc):<> intc = begin if c = '*' then lam t0 => k (t0 * t) else lam t0 => k (t0 / t) end // end of [f] } // end of [lp_term'] and lp_factor : lcharpar int = $delay ( p_spaces >> ( !lp_integer || (LPAREN >> !lp_expr << RPAREN) || (UMINUS >> lzeta lp_factor wth (lam (t: int): int = ~t)) ) ) // end of [lp_factor] (* ****** ****** *) dynload "contrib/parcomb/dynloadall.dats" (* ****** ****** *) implement main () = let var tks = char_stream_make_file stdin_ref var ncur: int = 0 and nmax: int = 0 val r = apply_parser (!lp_expr, tks, ncur, nmax) val i = ( case+ r of ~Some_vt i => i | ~None_vt _ => 0 ) : int in print "The value of the expression = "; print i; print_newline () end // end of [main] (* ****** ****** *) (* end of [calc1_example.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/TEST/lambda_example.dats0000664000175000017500000001531512223166163023455 0ustar hwxihwxi(* ** ** An example of parsing based on parsing combinators ** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: January 2009 (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" staload "contrib/parcomb/SATS/tokenize.sats" (* ****** ****** *) staload "contrib/parcomb/SATS/parcomb.sats" ; staload _(*anonymous*) = "contrib/parcomb/DATS/parcomb.dats" (* ****** ****** *) (* ** term_atm = var | ( term ) ** term = \ vars . term | term_atm term_rst ** term_rst = (*empty*) | term_atm term_rst *) infix (|| + 1) wth infixl (&& + 2) <<; infixr (&& + 1) >> postfix ^* ^+ (* ****** ****** *) typedef P (a: t@ype) = parser_t (a, token) typedef LP (a: t@ype) = lazy (parser_t (a, token)) val anytoken = any_parser () val anyopttoken = anyopt_parser () val LPAREN = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKsingleton ('\(') => true | _ => false ) val RPAREN = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKsingleton (')') => true | _ => false ) fn litident (name0: string): P token = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKide name => name0 = name | _ => false ) // end of [litident] val BACKSLASH = litident "\\" val DOT = litident "." (* ****** ****** *) datatype term_node = | Var of string | Lam of (string, term) | App of (term, term) where term = '{ term_loc= location_t, term_node= term_node } // end of [term] fun print_term (t: term): void = case+ t.term_node of | Var name => (print "Var("; print name; print ")") | Lam (name, t) => begin print "Lam("; print name; print "; "; print_term t; print ")" end // end of [Lam] | App (t1, t2) => begin print "App("; print_term t1; print ", "; print_term t2; print ")" end // end of [App] // end of [print_term] overload print with print_term (* ****** ****** *) fn term_var (loc: loc_t, name: string):<> term = '{ term_loc= loc, term_node= Var (name) } // end of [term_var] fn term_lam (loc: loc_t, x: string, t_body: term):<> term = '{ term_loc= loc, term_node= Lam (x, t_body) } // end of [term_lam] fn term_app (loc: loc_t, t1_fun: term, t2_arg: term):<> term = '{ term_loc= loc, term_node= App (t1_fun, t2_arg) } // end of [term_app] (* ****** ****** *) typedef termc = term - term fn isIdSymFst (c: char):<> bool = begin if char_isalpha c then true else string_contains ("_'", c) end // end of [isIdSymFst] fn isIdSymRst (c: char):<> bool = begin if isIdSymFst c then true else char_isdigit (c) end // end of [isIdSymRst] fn isKeyword (name: string):<> bool = false fn isVar (name: string):<> bool = let fun loop {n,i:nat | i <= n} .. (name: string n, i: size_t i):<> bool = if string_is_at_end (name, i) then true else let val c = $effmask_ref (name[i]) in if isIdSymRst (c) then loop (name, i+1) else false end // end of [if] // end of [loop] in if isKeyword name then false else let val [n:int] name = string1_of_string (name) in if string_is_at_end (name, 0) then false else let val c0 = $effmask_ref (name[0]) in if isIdSymFst c0 then loop (name, 1) else false end // end of [if] end // end of [isKeyword] end // end of [isVar] (* ****** ****** *) val p_var = (anytoken \sat pred) : P token where { fn pred (tok: token):<> bool = case+ tok.token_node of TOKide name => isVar name | _ => false } // end of [p_int] val p_vars = (p_var)^* : P (List token) val rec lp_term : LP term = $delay ( seq2wth_parser_fun (BACKSLASH >> p_vars, DOT >> lzeta lp_term, f_lams) || seq2wth_parser_fun (lzeta lp_term_atm, lzeta lp_term_rst, f_app) ) where { fn f_lams (toks: List token, t_body: term):<> term = aux (toks, t_body) where { fun aux {n:nat} .. (toks: list (token, n), t_body: term):<> term = case+ toks of | list_cons (tok, toks) => let val- TOKide name = tok.token_node val t_body = aux (toks, t_body) val loc = location_combine (tok.token_loc, t_body.term_loc) in term_lam (loc, name, t_body) end // end of [list_cons] | list_nil () => t_body } // end of [f_lams] fn f_app (t: term, tc: termc):<> term = tc (t) } // end of [lp_term] and lp_term_atm : LP term = $delay ( p_var wth f_var || LPAREN >> !lp_term << RPAREN ) where { fn f_var (tok: token):<> term = let val- TOKide name = tok.token_node in term_var (tok.token_loc, name) end // end of [f_var] } // end of [lp_term_atm] and lp_term_rst : LP termc = $delay ( seq2wth_parser_fun (!lp_term_atm, lzeta lp_term_rst, f) || return (lam (t: term): term = t) ) where { fn f (t: term, tc: termc):<> termc = lam (t0) => let val loc = location_combine (t0.term_loc, t.term_loc) in tc (term_app (loc, t0, t)) end // end of [lam] // end of [f] } // end of [lp_term_rst] (* ****** ****** *) dynload "contrib/parcomb/dynloadall.dats" (* ****** ****** *) extern fun parse_failure (tks: stream token, ncur: int, nmax: int): void implement parse_failure (tks, ncur, nmax) = let fun loop (tks: stream token, n: int): Option_vt (token) = case+ !tks of | stream_cons (tk, tks) => if n > 0 then loop (tks, n-1) else Some_vt (tk) | stream_nil () => None_vt () // end of [loop] val otk = loop (tks, nmax - ncur) in case+ otk of | ~Some_vt tk => begin prerr_location tk.token_loc; prerr ": exit"; prerr ": parsing failure"; prerr_newline () end // end of [Some_vt] | ~None_vt () => begin prerr ": exit"; prerr ": parsing failure at the end of the token stream."; prerr_newline () end // end of [None_vt] end // end of [parse_failure] (* ****** ****** *) implement main () = let val cs = char_stream_make_file stdin_ref val tks0 = tokenstream_make_charstream (cs) var tks: stream token = tks0 var ncur: int = 0 and nmax: int = 0 val otrm = apply_parser (!lp_term, tks, ncur, nmax) val trm = case+ otrm of | ~Some_vt trm => trm | ~None_vt () => let val () = parse_failure (tks, ncur, nmax) in exit {term} (1) end // end of [None_vt] // end of [val] val otk = stream_get_item (tks) val () = (case+ otk of | ~Some_vt tk => begin prerr_location tk.token_loc; prerr ": exit"; prerr ": parsing failure: unconsumed token"; prerr_newline (); exit {void} (1) end // end of [Some] // there are no unconsumed tokens | ~None_vt () => () ) : void // end of [token] val () = begin print "trm = "; print trm; print_newline () end // end of [val] in // empty end // end of [main] (* ****** ****** *) (* end of [lambda_example.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/TEST/calc2_example.dats0000664000175000017500000001352012223166163023215 0ustar hwxihwxi(* ** ** An example of parsing based on parsing combinators ** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December 2008 (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" staload "contrib/parcomb/SATS/tokenize.sats" (* ****** ****** *) staload "contrib/parcomb/SATS/parcomb.sats" ; staload _(*anonymous*) = "contrib/parcomb/DATS/parcomb.dats" ; (* ****** ****** *) (* ** expr = term expr' ** expr' = (PLUS | MINUS) term expr' | /* empty */ ** term = term term' ** term' = (TIMES | DIVIDES) factor term' | /* empty */ ** factor = integer | LPAREN expr RPAREN | UMINUS factor *) infix (|| + 1) wth infixl (&& + 2) <<; infixr (&& + 1) >> postfix ^* ^+ (* ****** ****** *) typedef P (a: t@ype) = parser_t (a, token) typedef LP (a: t@ype) = lazy (parser_t (a, token)) val anytoken = any_parser () val anyopttoken = anyopt_parser () val LPAREN = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKsingleton ('\(') => true | _ => false ) val RPAREN = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKsingleton (')') => true | _ => false ) fn litident (name0: string): P token = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKide name => name0 = name | _ => false ) // end of [litident] val UMINUS = litident "~" val PLUS = litident "+" val MINUS = litident "-" val TIMES = litident "*" val DIVIDES = litident "/" (* ****** ****** *) datatype exp_node = | EXPint of int | EXPuminus of exp | EXPadd of (exp, exp) | EXPsub of (exp, exp) | EXPmul of (exp, exp) | EXPdiv of (exp, exp) where exp = '{ exp_loc= loc_t, exp_node= exp_node } // end of [exp] (* ****** ****** *) fn exp_int (loc: loc_t, int: int):<> exp = '{ exp_loc= loc, exp_node= EXPint int } fn exp_uminus (loc: loc_t, e: exp):<> exp = '{ exp_loc= loc, exp_node= EXPuminus e } fn exp_add (loc: loc_t, e1: exp, e2: exp):<> exp = '{ exp_loc= loc, exp_node= EXPadd (e1, e2) } fn exp_sub (loc: loc_t, e1: exp, e2: exp):<> exp = '{ exp_loc= loc, exp_node= EXPsub (e1, e2) } fn exp_mul (loc: loc_t, e1: exp, e2: exp):<> exp = '{ exp_loc= loc, exp_node= EXPmul (e1, e2) } fn exp_div (loc: loc_t, e1: exp, e2: exp):<> exp = '{ exp_loc= loc, exp_node= EXPdiv (e1, e2) } (* ****** ****** *) fun exp_eval (e: exp): int = case+ e.exp_node of | EXPint int => int | EXPuminus e => ~(exp_eval e) | EXPadd (e1, e2) => exp_eval e1 + exp_eval e2 | EXPsub (e1, e2) => exp_eval e1 - exp_eval e2 | EXPmul (e1, e2) => exp_eval e1 * exp_eval e2 | EXPdiv (e1, e2) => exp_eval e1 / exp_eval e2 // end of [exp_eval] (* ****** ****** *) typedef expc = exp - exp val p_int = (anytoken \sat pred) : P token where { fn pred (tok: token):<> bool = case+ tok.token_node of TOKint _ => true | _ => false } // end of [p_int] val rec lp_expr : LP exp = $delay ( seq2wth_parser_fun (lzeta lp_term, lzeta lp_expr', f) ) where { fn f (e: exp, k: expc):<> exp = k (e) } // end of [lp_expr] and lp_expr' : LP expc = $delay ( seq3wth_parser_fun (PLUS || MINUS, lzeta lp_term, lzeta lp_expr', f) || return (lam (e: exp) = e) ) where { fn f (opr: token, e: exp, k: expc):<> expc = case+ opr.token_node of | TOKide "+" => lam e0 => let val loc = location_combine (e0.exp_loc, e.exp_loc) in k (exp_add (loc, e0, e)) end | _ => lam e0 => let val loc = location_combine (e0.exp_loc, e.exp_loc) in k (exp_sub (loc, e0, e)) end // end of [_] // end of [f] } // end of [p_expr'] and lp_term : LP exp = $delay ( seq2wth_parser_fun (lzeta lp_factor, lzeta lp_term', f) ) where { fn f (e: exp, k: expc):<> exp = k (e) } // end of [lp_term] and lp_term' : LP expc = $delay ( seq3wth_parser_fun ( TIMES || DIVIDES, lzeta lp_factor, lzeta lp_term', f ) || return (lam (e: exp) = e) ) where { fn f (opr: token, e: exp, k: expc):<> expc = case+ opr.token_node of | TOKide "*" => lam e0 => let val loc = location_combine (e0.exp_loc, e.exp_loc) in k (exp_mul (loc, e0, e)) end | _ => lam e0 => let val loc = location_combine (e0.exp_loc, e.exp_loc) in k (exp_div (loc, e0, e)) end // end of [_] // end of [f] } // end of [p_term'] and lp_factor : LP exp = $delay ( p_int wth f1 || seq2wth_parser_fun (UMINUS, lzeta lp_factor, f2) || (LPAREN >> !lp_expr << RPAREN) ) where { fn f1 (tok: token):<> exp = let val- TOKint int = tok.token_node in exp_int (tok.token_loc, int) end // end of [f1] fn f2 (opr: token, e: exp):<> exp = let val loc = location_combine (opr.token_loc, e.exp_loc) in exp_uminus (loc, e) end // end of [f2] } // end of [p_fac] (* ****** ****** *) dynload "contrib/parcomb/dynloadall.dats" (* ****** ****** *) implement main () = let fun errck (tks: &stream token): void = case+ stream_get_item (tks) of | ~Some_vt tk => begin prerr tk.token_loc; prerr ": error(0)"; prerr ": there are tokens left unconsumed."; prerr_newline (); exit {void} (1) end // end of [Some] | ~None_vt () => () // end of [errck] val cs = char_stream_make_file stdin_ref val tks0 = tokenstream_make_charstream (cs) var tks = tks0 var ncur: int = 0 and nmax: int = 0 val r = apply_parser (!lp_expr, tks, ncur, nmax) val i = (case+ r of | ~Some_vt e => begin let val () = errck (tks) in exp_eval e end end // end of [Some_vt] | ~None_vt _ => let val () = (tks := tks0; ncur := 0; errck tks) in 0 end // end of [None_vt] ) : int // end of [val] in print "the value of the expression = "; print i; print_newline () end // end of [main] (* ****** ****** *) (* end of [calc2_example.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/TEST/Makefile0000664000175000017500000000164412223166163021305 0ustar hwxihwxi###### # # Makefile for parcomb testing # ###### ATSUSRQ="$(ATSHOME)" ATSLIBQ="$(ATSHOME)" ifeq ("$(ATSHOME)","") ATSUSRQ="/usr" ATSLIBQ="/usr/lib/ats-anairiats-0.2.3" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSCTRB=$(ATSLIBQ)/contrib/parcomb/atsctrb_parcomb.o ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: calc1 calc1: calc1_example.dats $(ATSCC) -D_ATS_GCATS -o $@ $< $(ATSCTRB) cleanall:: ; $(RMF) calc1 checkall:: calc2 calc2: calc2_example.dats $(ATSCC) -D_ATS_GCATS -o $@ $< $(ATSCTRB) cleanall:: ; $(RMF) calc2 checkall:: calc3 calc3: calc3_example.dats $(ATSCC) -D_ATS_GCATS -o $@ $< $(ATSCTRB) cleanall:: ; $(RMF) calc3 ###### checkall:: lambda lambda: lambda_example.dats $(ATSCC) -D_ATS_GCATS -o $@ $< $(ATSCTRB) cleanall:: ; $(RMF) lambda ###### RMF = rm -f ###### clean:: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/parcomb/TEST/calc3_example.dats0000664000175000017500000003277512223166163023233 0ustar hwxihwxi(* ** ** An example of parsing based on parsing combinators ** The grammar used in this example is adopted from the ** straightline calculator example in Appel's compiler ** book (ML version): pages 10, 11, 12 ** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: January 2009 (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" staload "contrib/parcomb/SATS/tokenize.sats" (* ****** ****** *) staload "contrib/parcomb/SATS/parcomb.sats" ; staload _(*anonymous*) = "contrib/parcomb/DATS/parcomb.dats" (* ****** ****** *) (* ** Stm := id := Exp ** Stm := print (ExpLst) ** Stm := Stm ; Stm ** Exp := id | num | Exp Binop Exp | (Stm, Exp) ** ExpLst := Exp, ExpLst ** ExpLst := Exp ** Binop := + | - | * | / *) infix (|| + 1) wth infixl (&& + 2) <<; infixr (&& + 1) >> postfix ^* ^+ (* ****** ****** *) typedef P (a: t@ype) = parser_t (a, token) typedef LP (a: t@ype) = lazy (parser_t (a, token)) val anytoken = any_parser () val anyopttoken = anyopt_parser () // fn litchar (c0: char): P token = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKsingleton c => c0 = c | _ => false ) // end of [litchar] val LPAREN = litchar '\(' val RPAREN = litchar ')' val COMMA = litchar ',' val SEMICOLON = litchar ';' // fn litident (name0: string): P token = anytoken \sat (lam (tok: token): bool = case+ tok.token_node of TOKide name => name0 = name | _ => false ) // end of [litident] val PLUS = litident "+" val MINUS = litident "-" val TIMES = litident "*" val DIV = litident "/" val ASSGN = litident ":=" val PRINT = litident "print" (* ****** ****** *) abstype ident_t extern fun ident_make (name: string):<> ident_t extern fun fprint_ident (out: FILEref, id: ident_t): void extern fun eq_ident_ident (_: ident_t, _: ident_t): bool overload = with eq_ident_ident local assume ident_t = string in implement ident_make (name) = name implement fprint_ident (out, id) = fprint_string (out, id) implement eq_ident_ident (id1, id2) = eq_string_string (id1, id2) end // end of [local] (* ****** ****** *) datatype binop = Plus | Minus | Times | Div datatype stm_node = | CompoundStm of (stm, stm) | AssignStm of (ident_t, exp) | PrintStm of explst and exp_node = | IdExp of ident_t | NumExp of int | OpExp of (exp, binop, exp) | EseqExp of (stm, exp) where stm = '{ stm_loc= location_t, stm_node= stm_node } and exp = '{ exp_loc= location_t, exp_node= exp_node } and explst = List exp (* ****** ****** *) extern fun fprint_binop (out: FILEref, opr: binop): void implement fprint_binop (out, opr) = case+ opr of | Plus () => fprint_string (out, "+") | Minus () => fprint_string (out, "-") | Times () => fprint_string (out, "*") | Div () => fprint_string (out, "/") // end of [fprint_binop] extern fun fprint_stm (out: FILEref, stm: stm): void extern fun fprint_exp (out: FILEref, exp: exp): void extern fun fprint_explst (out: FILEref, exps: explst): void implement fprint_stm (out, stm) = ( case+ stm.stm_node of | CompoundStm (stm1, stm2) => begin fprint_string (out, "("); fprint_stm (out, stm1); fprint_string (out, "; "); fprint_stm (out, stm2); fprint_string (out, ")"); end | AssignStm (id1, exp2) => begin fprint_ident (out, id1); fprint_string (out, " := "); fprint_exp (out, exp2) end | PrintStm (exps) => begin fprint_string (out, "print ("); fprint_explst (out, exps); fprint_string (out, ")") end ) // end of [fprint_stm] implement fprint_exp (out, exp) = ( case+ exp.exp_node of | IdExp (id) => fprint_ident (out, id) | NumExp (int) => fprint_int (out, int) | OpExp (exp1, opr, exp2) => begin fprint_string (out, "("); fprint_exp (out, exp1); fprint_string (out, " "); fprint_binop (out, opr); fprint_string (out, " "); fprint_exp (out, exp2); fprint_string (out, ")") end | EseqExp (stm1, exp2) => begin fprint_string (out, "("); fprint_stm (out, stm1); fprint_string (out, "; "); fprint_exp (out, exp2); fprint_string (out, ")") end ) // end of [fprint_exp] implement fprint_explst (out, exps) = let fun loop ( out: FILEref, exps: explst, i: int ) : void = ( case+ exps of | list_cons (exp, exps) => begin if i > 0 then fprint_string (out, ", "); fprint_exp (out, exp); loop (out, exps, i+1) end // end of [list_cons] | list_nil () => () ) // end of [loop] in loop (out, exps, 0) end // end of [fprint_explst] (* ****** ****** *) fn fCompoundStm ( stm1: stm, stm2: stm ) :<> stm = let val loc = location_combine (stm1.stm_loc, stm2.stm_loc) // end of [val] in '{ stm_loc= loc, stm_node= CompoundStm (stm1, stm2) } end // end of [fCompoundStm] fn fAssignStm ( tok1: token, exp2: exp ) :<> stm = let val- TOKide name = tok1.token_node val loc1 = tok1.token_loc; val id1 = ident_make name val loc = location_combine (loc1, exp2.exp_loc) in '{ stm_loc= loc, stm_node= AssignStm (id1, exp2) } end // end of [fAssignStm] fn fPrintStm ( tok1: token, exps2: explst, tok3: token ) :<> stm = let val loc = location_combine (tok1.token_loc, tok3.token_loc) // end of [val] in '{ stm_loc= loc, stm_node= PrintStm (exps2) } end // end of [fPrintStm] (* ****** ****** *) fn fIdExp ( tok: token ) :<> exp = let val loc = tok.token_loc val- TOKide (name) = tok.token_node val id = ident_make (name) in '{ exp_loc= loc, exp_node= IdExp (id) } end // end of [fIdExp] fn fNumExp ( tok: token ) :<> exp = let val- TOKint int = tok.token_node in '{ exp_loc= tok.token_loc, exp_node= NumExp (int) } end // end of [fNumExp] fn fOpExp ( exp1: exp, opr: binop, exp2: exp ) :<> exp = let val loc = location_combine (exp1.exp_loc, exp2.exp_loc) in '{ exp_loc= loc, exp_node= OpExp (exp1, opr, exp2) } end // end of [fOpExp] fn fEseqExp ( tok1: token, stm2: stm, exp3: exp, tok4: token ) :<> exp = let val loc = location_combine (tok1.token_loc, tok4.token_loc) in '{ exp_loc= loc, exp_node= EseqExp (stm2, exp3) } end // end of [fEseqExp] (* ****** ****** *) typedef stmc = stm - stm typedef expc = exp - exp val p_ide = (anytoken \sat pred) : P token where { fn pred (tok: token):<> bool = case+ tok.token_node of TOKide _ => true | _ => false } // end of [p_ide] val p_num = (anytoken \sat pred) : P token where { fn pred (tok: token):<> bool = case+ tok.token_node of TOKint _ => true | _ => false } // end of [p_num] // val rec lp_stm0 : LP stm = $delay ( seq2wth_parser_fun (p_ide, ASSGN >> lzeta lp_exp, fAssignStm) || seq3wth_parser_fun (PRINT, LPAREN >> lzeta lp_explst, RPAREN, fPrintStm) ) // end of [lp_stm0] and lp_stm0_c : LP stmc = $delay ( seq2wth_parser_fun (SEMICOLON >> !lp_stm0, lzeta lp_stm0_c, f) || return (lam (stm: stm) = stm) ) where { fn f (stm1: stm, stmc: stmc):<> stmc = lam (stm0: stm) => stmc (fCompoundStm (stm0, stm1)) } // end of [lp_stm_cont] and lp_stm : LP stm = $delay ( seq2wth_parser_fun (!lp_stm0, !lp_stm0_c, lam (stm, stmc) => stmc (stm)) ) // end of [lp_stm1] and lp_exp0 : LP exp = $delay ( p_ide wth fIdExp || p_num wth fNumExp || seq4wth_parser_fun (LPAREN, !lp_stm, COMMA >> lzeta lp_exp, RPAREN, fEseqExp) ) // end of [lp_exp0] and lp_exp0_c : LP expc = $delay ( seq3wth_parser_fun (TIMES || DIV, !lp_exp0, lzeta lp_exp0_c, f) || return (lam (exp: exp) = exp) ) where { fn f (tok: token, exp1: exp, expc: expc):<> expc = let val opr = let val- TOKide name = tok.token_node in case+ name of "*" => Times () | _ => Div () end : binop in lam exp0 => expc (fOpExp (exp0, opr, exp1)) end // end of [f] } // end of [lp_exp0_c] and lp_exp1 : LP exp = $delay ( seq2wth_parser_fun (!lp_exp0, !lp_exp0_c, lam (exp, expc) => expc (exp)) ) // end of [lp_exp1] and lp_exp1_c : LP expc = $delay ( seq3wth_parser_fun (PLUS || MINUS, !lp_exp1, lzeta lp_exp1_c, f) || return (lam (exp: exp) = exp) ) where { fn f (tok: token, exp1: exp, expc: expc):<> expc = let val opr = let val- TOKide name = tok.token_node in case+ name of "+" => Plus () | _ => Minus () end : binop in lam exp0 => expc (fOpExp (exp0, opr, exp1)) end // end of [f] } // end of [lp_exp0_c] and lp_exp : LP exp = $delay ( seq2wth_parser_fun (!lp_exp1, !lp_exp1_c, lam (exp, expc) => expc (exp)) ) // end of [lp_exp] (* and lp_explst_c : LP explst = $delay ( seq2wth_parser_fun (COMMA >> !lp_exp, lzeta lp_explst_c, lam (e, es) => list_cons (e, es)) || return (list_nil ()) ) and lp_explst : LP (explst) = $delay ( seq2wth_parser_fun (!lp_exp, !lp_explst_c, lam (e, es) => list_cons (e, es)) ) // end of [lp_explst] *) and lp_explst : LP (explst) = $delay (repeat0_sep_parser (!lp_exp, COMMA)) (* ****** ****** *) extern fun parse_failure (tks: stream token, ncur: int, nmax: int): void implement parse_failure (tks, ncur, nmax) = let fun loop (tks: stream token, n: int): Option_vt (token) = case+ !tks of | stream_cons (tk, tks) => if n > 0 then loop (tks, n-1) else Some_vt (tk) | stream_nil () => None_vt () // end of [loop] val otk = loop (tks, nmax - ncur) in case+ otk of | ~Some_vt tk => begin prerr_location tk.token_loc; prerr ": exit"; prerr ": parsing failure"; prerr_newline () end // end of [Some_vt] | ~None_vt () => begin prerr ": exit"; prerr ": parsing failure at the end of the token stream."; prerr_newline () end // end of [None_vt] end // end of [parse_failure] (* ****** ****** *) extern fun parse_from_stdin (): stm implement parse_from_stdin () = let val cs = char_stream_make_file stdin_ref val tks0 = tokenstream_make_charstream (cs) var tks: stream token = tks0 var ncur: int = 0 and nmax: int = 0 val r = apply_parser (!lp_stm, tks, ncur, nmax) val stm = (case+ r of | ~Some_vt stm => stm | ~None_vt _ => let val () = parse_failure (tks, ncur, nmax) in exit {stm} (1) end // end of [Fail_vt] ) : stm // end of [val] val otk = stream_get_item (tks) val () = (case+ otk of | ~Some_vt tk => begin prerr_location tk.token_loc; prerr ": exit"; prerr ": parsing failure: unconsumed token"; prerr_newline (); exit {void} (1) end // end of [Some] // there are no unconsumed tokens | ~None_vt () => () ) : void // end of [token] in stm end // end of [parse_from_stdin] (* ****** ****** *) abstype table_t extern fun table_make (): table_t extern fun lookup (tbl: table_t, x: ident_t): int extern fun update (tbl: table_t, x: ident_t, v: int): table_t local assume table_t = List @(ident_t, int) in implement table_make () = list_nil () implement lookup (tbl, x0) = case+ tbl of | list_cons (xv, tbl) => if (x0 = xv.0) then xv.1 else lookup (tbl, x0) | list_nil () => begin 0 // if a variable is not defined; this is convenient but not such a good style end // end of [list_nil] // end of [lookup] implement update (tbl, x0, v_new) = case+ tbl of | list_cons (xv, tbl) => begin if x0 = xv.0 then list_cons (@(x0, v_new), tbl) else list_cons (xv, update (tbl, x0, v_new)) // end of [if] end // end of [list_cons] | list_nil () => list_cons (@(x0, v_new), list_nil ()) // end of [update] end // end of [local] (* ****** ****** *) extern fun interpExp (tbl: &table_t, _: exp): int extern fun interpStm (tbl: &table_t, _: stm): void (* ****** ****** *) implement interpExp (tbl, exp) = ( case+ exp.exp_node of | IdExp id => let val v = lookup (tbl, id) in v end | NumExp v => v | OpExp (exp1, binop, exp2) => let val v1 = interpExp (tbl, exp1) val v2 = interpExp (tbl, exp2) in case+ binop of | Plus () => v1 + v2 | Minus () => v1 - v2 | Times () => v1 * v2 | Div () => v1 / v2 end // end of [OpExp] | EseqExp (stm, exp) => let val () = interpStm (tbl, stm) in interpExp (tbl, exp) end // end of [EseqExp] ) // end of [interpExp] implement interpStm (tbl, stm) = ( case+ stm.stm_node of | CompoundStm (stm1, stm2) => let val () = interpStm (tbl, stm1) in interpStm (tbl, stm2) end // end of [CompoundStm] | AssignStm (id, exp) => let val v = interpExp (tbl, exp) val tbl_new = update (tbl, id, v) in tbl := tbl_new end // end of [AssignStm] | PrintStm (exps) => loop (tbl, exps, 0) where { fun loop (tbl: &table_t, exps: explst, i: int): void = case+ exps of | list_cons (exp, exps) => let val v = interpExp (tbl, exp) in if i > 0 then print ' '; print v; loop (tbl, exps, i+1) end // end of [list_cons] | list_nil () => print_newline () } // end of [PrintStm] ) // end of [interpStm] (* ****** ****** *) extern fun interp (_: stm): void implement interp (stm) = let var tbl0 = table_make (); val () = interpStm (tbl0, stm) in // empty end // end of [interp] (* ****** ****** *) dynload "contrib/parcomb/dynloadall.dats" (* ****** ****** *) (* // HX; heere is an example: a := 5 + 3; b := (print (a, a-1), 10 * a); print (b) *) (* ****** ****** *) implement main () = let val () = begin print "Please input a statement on the next line:\n" end // end of [val] val stm = parse_from_stdin () in interp (stm) end // end of [main] (* ****** ****** *) (* end of [calc3_example.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/SATS/0000700000175000017500000000000012223166163017617 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/parcomb/SATS/parcomb.sats0000664000175000017500000002047712223166163022164 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** An implementation of parsing combinators ** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2008 // (* ****** ****** *) sortdef t0p = t@ype (* ****** ****** *) fun{t:t0p} stream_get_item (tks: &stream t):<> Option_vt (t) (* ****** ****** *) abstype parser_t (a:t0p, t:t0p) stadef parser = parser_t (* ****** ****** *) fun lzeta {a:t0p}{t:t0p} (p: lazy (parser (a, t))):<> parser (a, t) (* ****** ****** *) fun{a:t0p} any_parser (): parser (a, a) fun{a:t0p} anyopt_parser (): parser (Option a, a) (* ****** ****** *) fun{} fail_parser {a:t0p}{t:t0p} (): parser (a, t) (* ****** ****** *) // // HX: this one does not consume any tokens // fun{a:t0p}{t:t0p} neg_parser (p: parser (a, t)): parser (unit, t) overload ~ with neg_parser (* ****** ****** *) symintr return fun{a:t0p}{t:t0p} return_parser (x: a):<> parser (a, t) overload return with return_parser (* ****** ****** *) // symintr alt // infix fun{a:t0p}{t:t0p} alt_parser_parser (p1: parser (a, t), p2: parser (a, t)):<> parser (a, t) overload || with alt_parser_parser (* ****** ****** *) // symintr seq // infix fun{a1,a2:t0p}{t:t0p} seq_parser_parser ( p1: parser (a1, t), p2: parser (a2, t) ) :<> parser (@(a1,a2), t) overload && with seq_parser_parser (* ****** ****** *) symintr wth // infix fun{a:t0p;b:t0p}{t:t0p} seq1wth_parser_fun ( p1: parser (a, t), f: (a) - b ) :<> parser (b, t) overload wth with seq1wth_parser_fun fun{a:t0p;b:t0p}{t:t0p} seq1wth_parser_cloref ( p1: parser (a, t), f: (a) - b ) :<> parser (b, t) overload wth with seq1wth_parser_cloref (* ****** ****** *) fun{ a1,a2,b:t0p}{t:t0p } seq2wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , f: (a1, a2) - b ) :<> parser (b, t) // end of [seq2wth_parser_fun] fun{ a1,a2,b:t0p}{t:t0p } seq2wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , f: (a1, a2) - b ) :<> parser (b, t) // end of [seq2wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,b:t0p}{t:t0p } seq3wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , f: (a1, a2, a3) - b ) :<> parser (b, t) // end of [seq3wth_parser_fun] fun{ a1,a2,a3,b:t0p}{t:t0p } seq3wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , f: (a1, a2, a3) - b ) :<> parser (b, t) // end of [seq3wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,a4,b:t0p}{t:t0p } seq4wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , f: (a1, a2, a3, a4) - b ) :<> parser (b, t) // end of [seq4wth_parser_fun] fun{ a1,a2,a3,a4,b:t0p}{t:t0p } seq4wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , f: (a1, a2, a3, a4) - b ) :<> parser (b, t) // end of [seq4wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,a4,a5,b:t0p}{t:t0p } seq5wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , f: (a1, a2, a3, a4, a5) - b ) :<> parser (b, t) // end of [seq5wth_parser_fun] fun{ a1,a2,a3,a4,a5,b:t0p}{t:t0p } seq5wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , f: (a1, a2, a3, a4, a5) - b ) :<> parser (b, t) // end of [seq5wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,a4,a5,a6,b:t0p}{t:t0p } seq6wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , f: (a1, a2, a3, a4, a5, a6) - b ) :<> parser (b, t) // end of [seq6wth_parser_fun] fun{ a1,a2,a3,a4,a5,a6,b:t0p}{t:t0p } seq6wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , f: (a1, a2, a3, a4, a5, a6) - b ) :<> parser (b, t) // end of [seq6wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,a4,a5,a6,a7,b:t0p}{t:t0p } seq7wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , p7: parser (a7, t) , f: (a1, a2, a3, a4, a5, a6, a7) - b ) :<> parser (b, t) // end of [seq7wth_parser_fun] fun{ a1,a2,a3,a4,a5,a6,a7,b:t0p}{t:t0p } seq7wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , p7: parser (a7, t) , f: (a1, a2, a3, a4, a5, a6, a7) - b ) :<> parser (b, t) // end of [seq7wth_parser_cloref] (* ****** ****** *) fun{ a1,a2,a3,a4,a5,a6,a7,a8,b:t0p}{t:t0p } seq8wth_parser_fun ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , p7: parser (a7, t) , p8: parser (a8, t) , f: (a1, a2, a3, a4, a5, a6, a7, a8) - b ) :<> parser (b, t) // end of [seq8wth_parser_fun] fun{ a1,a2,a3,a4,a5,a6,a7,a8,b:t0p}{t:t0p } seq8wth_parser_cloref ( p1: parser (a1, t) , p2: parser (a2, t) , p3: parser (a3, t) , p4: parser (a4, t) , p5: parser (a5, t) , p6: parser (a6, t) , p7: parser (a7, t) , p8: parser (a8, t) , f: (a1, a2, a3, a4, a5, a6, a7, a8) - b ) :<> parser (b, t) // end of [seq8wth_parser_cloref] (* ****** ****** *) // << (fst) and >> (snd) fun{ a1,a2:t0p}{t:t0p } proj1_parser_parser (p1: parser (a1, t), p2: parser (a2, t)):<> parser (a1, t) overload << with proj1_parser_parser fun{ a1,a2:t0p}{t:t0p } proj2_parser_parser (p1: parser (a1, t), p2: parser (a2, t)):<> parser (a2, t) overload >> with proj2_parser_parser (* ****** ****** *) symintr sat // infix fun{a:t0p}{t:t0p} sat_parser_fun (p: parser (a, t), f: a - bool):<> parser (a, t) overload sat with sat_parser_fun fun{a:t0p}{t:t0p} sat_parser_cloref (p: parser (a, t), f: a - bool):<> parser (a, t) overload sat with sat_parser_cloref (* ****** ****** *) fun{a:t0p}{t:t0p} discard_one_parser (p: parser (a, t)):<> parser (unit, t) fun{a:t0p}{t:t0p} discard_many_parser (p: parser (a, t)):<> parser (unit, t) (* ****** ****** *) symintr ^? ^* ^+ // postfix fun{a:t0p}{t:t0p} optional_parser (p: parser (a, t)):<> parser (Option a, t) overload ^? with optional_parser fun{a:t0p}{t:t0p} repeat0_parser (p: parser (a, t)):<> parser (List a, t) overload ^* with repeat0_parser viewtypedef List1 (a: t0p) = [n:int | n > 0] list (a, n) fun{a:t0p}{t:t0p} repeat1_parser (p: parser (a, t)):<> parser (List1 a, t) overload ^+ with repeat1_parser (* ****** ****** *) fun{ a,b:t0p}{t:t0p } repeat0_sep_parser (p: parser (a, t), sep: parser (b, t)):<> parser (List a, t) // end of [repeat0_sep_parser] fun{ a,b:t0p}{t:t0p } repeat1_sep_parser (p: parser (a, t), sep: parser (b, t)):<> parser (List1 a, t) // end of [repeat1_sep_parser] (* ****** ****** *) fun{ a:t0p}{t:t0p } apply_parser ( p: parser (a, t), tks: &stream t, ncur: &int, nmax: &int ) : Option_vt a // end of [apply_parser] (* ****** ****** *) (* end of [parcomb.sats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/SATS/posloc.sats0000664000175000017500000000725012223166163022032 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** For recording location information for concrete syntax *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: December 2008 (* ****** ****** *) abstype filename_t // boxed type fun filename_make_string (name: string): filename_t fun fprint_filename (out: FILEref, fil: filename_t): void overload fprint with fprint_filename fun print_filename (loc: filename_t): void overload print with print_filename fun prerr_filename (loc: filename_t): void overload prerr with prerr_filename (* ****** ****** *) val filename_none: filename_t val filename_stdin: filename_t fun filename_pop (): void fun filename_push (x: filename_t): void fun filename_get_current ():<> filename_t (* ****** ****** *) abstype position_t // boxed type typedef lint = int_long_t0ype fun position_line (p: position_t):<> int fun position_loff (p: position_t):<> int fun position_toff (p: position_t):<> lint (* ****** ****** *) fun fprint_position (fil: FILEref, pos: position_t): void overload fprint with fprint_position fun print_position (pos: position_t): void = "lexing_print_position" overload print with print_position fun prerr_position (pos: position_t): void = "lexing_prerr_position" overload prerr with prerr_position (* ****** ****** *) val position_origin: position_t fun position_next (p: position_t, c: char):<> position_t fun lt_position_position (p1: position_t, p2: position_t):<> bool overload < with lt_position_position fun lte_position_position (p1: position_t, p2: position_t):<> bool overload <= with lte_position_position fun eq_position_position (p1: position_t, p2: position_t):<> bool overload = with eq_position_position fun neq_position_position (p1: position_t, p2: position_t):<> bool overload <> with neq_position_position (* ****** ****** *) abstype location_t // boxed type val location_none: location_t fun location_make (_1: position_t, _2: position_t):<> location_t fun location_combine (_1: location_t, _2: location_t):<> location_t fun fprint_location (out: FILEref, loc: location_t): void overload fprint with fprint_location fun print_location (loc: location_t): void overload print with print_location fun prerr_location (loc: location_t): void overload prerr with prerr_location fun tostrptr_location (loc: location_t): strptr0 (* ****** ****** *) (* end of [posloc.sats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/SATS/tokenize.sats0000664000175000017500000000454112223166163022363 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** Tokenization: using PCs to turn a character stream into a token stream *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: December 2008 (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" (* ****** ****** *) typedef loc_t = location_t datatype token_node = | TOKchr of char | TOKide of string | TOKint of int | TOKsingleton of char | TOKstr of string // end of [token_node] where token = '{ token_loc= loc_t, token_node= token_node } // end of [token] and tokenlst = List token and tokenopt = Option token (* ****** ****** *) fun fprint_token (out: FILEref, tok: token): void overload fprint with fprint_token fun print_token (tok: token): void fun prerr_token (tok: token): void overload print with print_token overload prerr with prerr_token (* ****** ****** *) fun tokenstream_make_charstream (cps: stream char): stream token // end of [tokenstream_make_charstream] (* ****** ****** *) (* end of [tokenize.sats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/Makefile0000664000175000017500000000222112223166162020515 0ustar hwxihwxi###### # # Makefile for the [parcomb] package # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif # end of [ifeq] ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall ###### SOURCES := \ dynloadall.dats \ parcomb.sats parcomb.dats \ posloc.sats posloc.dats \ tokenize.sats tokenize.dats \ OBJECTS := $(SOURCES) OBJECTS := $(patsubst %.dats, %_dats.o, $(OBJECTS)) OBJECTS := $(patsubst %.sats, %_sats.o, $(OBJECTS)) ###### all:: atsctrb_parcomb.o all:: clean ###### atsctrb_parcomb.o: $(OBJECTS); ld -r -o $@ $(OBJECTS) ###### dynloadall_dats.o: dynloadall.dats; $(ATSCC) -O2 -c -o $@ $< ###### parcomb_sats.o: SATS/parcomb.sats $(ATSCC) -O2 -c -o $@ $< parcomb_dats.o: DATS/parcomb.dats $(ATSCC) -O2 -c -o $@ $< ###### posloc_sats.o: SATS/posloc.sats $(ATSCC) -O2 -c -o $@ $< posloc_dats.o: DATS/posloc.dats $(ATSCC) -O2 -c -o $@ $< tokenize_sats.o: SATS/tokenize.sats $(ATSCC) -O2 -c -o $@ $< tokenize_dats.o: DATS/tokenize.dats $(ATSCC) -O2 -c -o $@ $< ###### RMF=rm -f ###### clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.c clean:: ; $(RMF) *_?ats.o cleanall: clean $(RMF) atsctrb_parcomb.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/parcomb/DATS/0000700000175000017500000000000012223166163017600 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/parcomb/DATS/posloc.dats0000664000175000017500000001763112223166163022000 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" (* ****** ****** *) typedef filename = @{ filename= string } assume filename_t = filename implement filename_make_string (name) = @{ filename = name } // end of [filename_make_string] implement fprint_filename (out, fil) = fprint_string (out, fil.filename) implement print_filename (fil) = fprint_filename (stdout_ref, fil) implement prerr_filename (fil) = fprint_filename (stderr_ref, fil) (* ****** ****** *) implement filename_none = @{ filename= "" } implement filename_stdin = @{ filename= "stdin" } (* ****** ****** *) local viewtypedef filenamelst_vt = List_vt (filename) val the_filenamelst = ref_make_elt (list_vt_nil) in // in of [local] implement filename_push (x) = let val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) in !p := list_vt_cons (x, !p) end // end of [filename_push] implement filename_pop () = let val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) in case+ !p of | ~list_vt_cons (x, xs) => (!p := xs) | list_vt_nil () => let (* // // HX: there is no check!!! // val () = $effmask_ref begin prerr "exit(ATS/PARCOMB)"; prerr ": ERROR: filename_pop: empty stack"; prerr_newline (); end // end of [val] val () = $effmask_exn (exit 1) *) in fold@ !p end // end of [list_vt_nil] end (* end of [filename_get] *) implement filename_get_current () = $effmask_all let val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) in case+ !p of | list_vt_cons (x, _) => (fold@ !p; x) | list_vt_nil () => (fold@ !p; filename_none) end // end of [filename_get] end // end of [local] (* ****** ****** *) typedef position = '{ line= int, loff= int, toff= lint } assume position_t = position implement position_origin = '{ line = 0, loff= 0, toff= 0L } implement position_next (pos, c) = if (c = '\n') then '{ line= pos.line + 1, loff= 0, toff= pos.toff + 1L } else '{ line= pos.line, loff= pos.loff + 1, toff= pos.toff + 1L } // end of [if] // end of [position_next] implement position_line (p) = p.line implement position_loff (p) = p.loff implement position_toff (p) = p.toff implement fprint_position (fil, pos) = fprintf (fil, "%li(line=%i, offs=%i)", @(pos.toff+1L, pos.line+1, pos.loff+1)) implement print_position (pos) = fprint_position (stdout_ref, pos) implement prerr_position (pos) = fprint_position (stderr_ref, pos) implement lt_position_position (p1, p2) = p1.toff < p2.toff implement lte_position_position (p1, p2) = p1.toff <= p2.toff implement eq_position_position (p1, p2) = p1.toff = p2.toff implement neq_position_position (p1, p2) = p1.toff <> p2.toff (* ****** ****** *) typedef location = '{ filename= filename_t // file name , begpos_line= int , begpos_loff= int // beginning char position in a line , begpos_toff= lint // beginning char position , endpos_line= int , endpos_loff= int // finishing char position in a line , endpos_toff= lint // finishing char position } /* end of [location] */ assume location_t = location (* ****** ****** *) implement location_none = '{ filename= filename_none , begpos_line= ~1 , begpos_loff= ~1 , begpos_toff= ~1L , endpos_line= ~1 , endpos_loff= ~1 , endpos_toff= ~1L } // end of [location_none] fn location_is_none (loc: location):<> bool = (loc.begpos_toff < 0L) (* ****** ****** *) implement location_make (begpos, endpos) = '{ filename= filename_get_current () , begpos_line= position_line begpos , begpos_loff= position_loff begpos , begpos_toff= position_toff begpos , endpos_line= position_line endpos , endpos_loff= position_loff endpos , endpos_toff= position_toff endpos } // end of [location_make] (* ****** ****** *) fn location_combine_main (loc1: location, loc2: location):<> location = let var begpos_line: int and begpos_loff: int var begpos_toff: lint var endpos_line: int and endpos_loff: int var endpos_toff: lint val () = if loc1.begpos_toff <= loc2.begpos_toff then begin begpos_line := loc1.begpos_line; begpos_loff := loc1.begpos_loff; begpos_toff := loc1.begpos_toff; end else begin begpos_line := loc2.begpos_line; begpos_loff := loc2.begpos_loff; begpos_toff := loc2.begpos_toff; end // end of [if] val () = if loc1.endpos_toff >= loc2.endpos_toff then begin endpos_line := loc1.endpos_line; endpos_loff := loc1.endpos_loff; endpos_toff := loc1.endpos_toff; end else begin endpos_line := loc2.endpos_line; endpos_loff := loc2.endpos_loff; endpos_toff := loc2.endpos_toff; end // end of [if] in '{ filename = loc1.filename , begpos_line= begpos_line , begpos_loff= begpos_loff , begpos_toff= begpos_toff , endpos_line= endpos_line , endpos_loff= endpos_loff , endpos_toff= endpos_toff } end // end of [location_combine_main] implement location_combine (loc1, loc2) = begin case+ 0 of | _ when location_is_none loc1 => loc2 | _ when location_is_none loc2 => loc1 | _ => location_combine_main (loc1, loc2) end // end of [location_combine] (* ****** ****** *) implement fprint_location (out, loc) = begin fprint_filename (out, loc.filename); fprint_string (out, ": "); fprint_lint (out, loc.begpos_toff+1L); fprint_string (out, "(line="); fprint_int (out, loc.begpos_line+1); fprint_string (out, ", offs="); fprint_int (out, loc.begpos_loff+1); fprint_string (out, ") -- "); fprint_lint (out, loc.endpos_toff+1L); fprint_string (out, "(line="); fprint_int (out, loc.endpos_line+1); fprint_string (out, ", offs="); fprint_int (out, loc.endpos_loff+1); fprint_string (out, ")"); end // end of [fprint_location] implement print_location (loc) = fprint_location (stdout_ref, loc) implement prerr_location (loc) = fprint_location (stderr_ref, loc) (* ****** ****** *) local staload "libc/SATS/stdio.sats" in // in of [local] implement tostrptr_location (loc) = let val (pfopt | filp) = tmpfile_err () in if filp > null then let prval Some_v (pffil) = pfopt prval pfmod = file_mode_lte_rw_w () extern castfn __cast (p: ptr): FILEref val () = fprint_location (__cast (filp), loc) (* val _(*int*) = fflush_err (pfmod | !filp) *) val _(*int*) = fseek_err (!filp, 0l, SEEK_SET) val res = input_line_vt (__cast (filp)) val () = fclose_exn (pffil | filp) in res end else let prval None_v () = pfopt in strptr_null () end (* end of [if] *) end // end of [tostrptr_location] end // end of [local] (* ****** ****** *) (* end of [posloc.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/DATS/tokenize.dats0000664000175000017500000004320312223166163022323 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Tokenization: using PCs to turn a character stream into a token stream ** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December 2008 (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" %} // end of [%{^] (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "contrib/parcomb/SATS/posloc.sats" staload "contrib/parcomb/SATS/parcomb.sats" staload _(*anon*) = "contrib/parcomb/DATS/parcomb.dats" (* ****** ****** *) staload "contrib/parcomb/SATS/tokenize.sats" (* ****** ****** *) // // HX: please make changes here if needed // #define LINE_COMMENT_BEG "//" // C++ style (* #define LINE_COMMENT_BEG "--" // Haskell style *) #if defined (LINE_COMMENT_BEG) #then #assert (LINE_COMMENT_BEG <> "") #endif // end of [...] (* ****** ****** *) // // a block comment can be embedded inside another one // // C-style #define BLOCK_COMMENT_BEG "/*" #define BLOCK_COMMENT_END "*/" (* // ML-style #define BLOCK_COMMENT_BEG "(*" #define BLOCK_COMMENT_END "*)" *) (* ****** ****** *) #if defined (BLOCK_COMMENT_BEG) && defined (BLOCK_COMMENT_END) #then #assert (BLOCK_COMMENT_BEG <> "") #assert (BLOCK_COMMENT_END <> "") #assert (BLOCK_COMMENT_BEG <> BLOCK_COMMENT_END) #endif (* ****** ****** *) typedef pos_t = position_t typedef charpos = @(char, pos_t) extern fun charposstream_make_charstream (cs: stream char, pos: pos_t): stream charpos implement charposstream_make_charstream (cs, pos) = let fun charposstream_make_charstream_con (cs: stream char, pos: pos_t): stream_con charpos = case+ !cs of | stream_cons (c, cs1) => let val pos1 = position_next (pos, c) in stream_cons (@(c, pos), charposstream_make_charstream (cs1, pos1)) end // end of [stream_cons] | stream_nil () => stream_nil () // end of [charposstream_make_charstream_con] in $delay (charposstream_make_charstream_con (cs, pos)) end // end of [charposstream_make_charstream] (* ****** ****** *) fn token_chr_make (loc: loc_t, chr: char):<> token = '{ token_loc= loc, token_node= TOKchr chr } // end of [token_chr_make] fn token_ide_make (loc: loc_t, ide: string):<> token = '{ token_loc= loc, token_node= TOKide ide } // end of [token_ide_make] fn token_int_make (loc: loc_t, int: int):<> token = '{ token_loc= loc, token_node= TOKint int } // end of [token_int_make] fn token_str_make (loc: loc_t, str: string):<> token = '{ token_loc= loc, token_node= TOKstr str } // end of [token_str_make] extern fun token_singleton_make (loc: loc_t, c: char):<> token implement token_singleton_make (loc, c) = '{ token_loc= loc, token_node= TOKsingleton c } // end of [token_singleton_make] (* ****** ****** *) implement fprint_token (out, tok) = begin case+ tok.token_node of | TOKchr c => begin fprint (out, "TOKchr("); fprint (out, c); fprint (out, ")") end // end of [TOKchr] | TOKide name => begin fprint (out, "TOKide("); fprint (out, name); fprint (out, ")") end // end of [TOKide] | TOKint i => begin fprint (out, "TOKint("); fprint (out, i); fprint (out, ")") end // end of [TOKint] | TOKstr s => begin fprint (out, "TOKstr("); fprint (out, s); fprint (out, ")") end // end of [TOKstr] | TOKsingleton c => begin fprint (out, "TOKsingleton("); fprint (out, c); fprint (out, ")") end // end of [TOKsingleton] end // end of [fprint_token] implement print_token (tok) = fprint_token (stdout_ref, tok) implement prerr_token (tok) = fprint_token (stderr_ref, tok) (* ****** ****** *) infixl (&& + 1) << infixr (&& + 2) >> infixl (&& + 5) wth postfix (&& + 10) ^* ^+ typedef charpar (a:t@ype) = parser_t (a, charpos) typedef lcharpar (a:t@ype) = lazy (parser_t (a, charpos)) val anycharpos = any_parser () and anyoptcharpos = anyopt_parser () fn litchar (c: char):<> charpar (charpos) = begin anycharpos \sat (lam (cp: charpos): bool = cp.0 = c) end // end of [litchar] fn litcharneg (c: char):<> charpar (charpos) = begin anycharpos \sat (lam (cp: charpos): bool = cp.0 <> c) end // end of [litcharneg] val p_UMINUS = (litchar '~'): charpar charpos (* ****** ****** *) val p_space = begin anycharpos \sat (lam (cp: charpos): bool = char_isspace cp.0) end : charpar (charpos) val p_spaces: charpar (unit) = discard_many_parser (p_space) // end of [p_spaces] fn p_singleton (c: char) : charpar (token) = (litchar c wth f) where { fn f (cp: charpos):<> token = let val pos = cp.1; val loc = location_make (pos, pos) in token_singleton_make (loc, cp.0) end // end of [f] } // end of [p_singleton] val p_comma = p_singleton ',' val p_semicolon = p_singleton ';' val p_lparen = p_singleton '\(' val p_rparen = p_singleton ')' val p_lbracket = p_singleton '\[' val p_rbracket = p_singleton ']' val p_lbrace = p_singleton '\{' val p_rbrace = p_singleton '}' (* ****** ****** *) fn litword {n:int | n >= 2} (s: string n):<> charpar (loc_t) = let fun aux {n,i:nat | i < n} .. (s: string n, i: size_t i):<> charpar (charpos) = let val c = $effmask_ref (s[i]) in if string_is_atend (s, i+1) then litchar c else litchar c >> aux (s, i+1) end // end of [aux] fn f (cp0: charpos, cp1: charpos):<> loc_t = location_make (cp0.1, cp1.1) val c0 = $effmask_ref (s[0]) in seq2wth_parser_fun (litchar c0, aux (s, 1), f) end // end of [litword] (* ****** ****** *) #if defined (LINE_COMMENT_BEG) #then val p_line_comment: charpar (unit) = litword LINE_COMMENT_BEG >> discard_many_parser (anycharpos \sat pred) where { fn pred (cp: charpos):<> bool = case+ cp.0 of | c when (c = '\n') => false | _ => true // end of [pred] } // end of [p_line_comment] #else val p_line_comment: charpar (unit) = fail_parser () #endif // #if defined (LINE_COMMENT_BEG) (* ****** ****** *) #if defined (BLOCK_COMMENT_BEG) && defined (BLOCK_COMMENT_END) #then local val p_comment_beg = litword BLOCK_COMMENT_BEG val p_comment_end = litword BLOCK_COMMENT_END val p_comment_inside = (anycharpos \sat pred) where { fn pred (cp: charpos):<> bool = let val c = cp.0 in if c = string_get_char_at (BLOCK_COMMENT_BEG, 0) then false else if c = string_get_char_at (BLOCK_COMMENT_END, 0) then false else true // end of [if] // end of [if] end // end of [pred] } // end of [p_comment_inside] val rec lp_comment0 : lcharpar (unit) = $delay ( seq2wth_parser_fun (p_comment_beg, !lp_comment1, f) ) where { fn f (loc: loc_t, err: int):<> unit = $effmask_all ( if (err = 0) then unit () else begin prerr loc; prerr ": error(0)"; prerr ": this comment is unclosed."; prerr_newline (); exit {unit} (1) end // end of [if] ) // end of [$effmask_all] } // end of [lp_comment0] and lp_comment1 : lcharpar (int) = $delay ( discard_many_parser (p_comment_inside) >> !lp_comment2 ) // end of [lp_comment1] and lp_comment2 : lcharpar (int) = $delay ( p_comment_end >> return 0 || (* success *) lzeta lp_comment0 >> lzeta lp_comment1 || anycharpos >> lzeta lp_comment1 || return (~1) (* failure: unclosed comment *) ) // end of [lp_comment2] in // in of [local] val p_comment = !lp_comment0 end // end of [local] #else val p_comment: charpar (unit) = fail_parser () #endif // #if defined (BLOCK_COMMENT_BEG) && defined (BLOCK_COMMENT_END) (* ****** ****** *) // parser for letters val p_print = begin anycharpos \sat (lam (cp: charpos): bool = char_isprint cp.0) end : charpar (charpos) // parser for digits val p_digit = begin anycharpos \sat (lam (cp: charpos): bool = char_isdigit cp.0) end : charpar (charpos) (* ****** ****** *) val SQUOTE = litchar '\'' // single quote val BACKSLASH = litchar '\\' val BACKSLASHneg = litcharneg '\\' val p_escape_chr = ( seq2wth_parser_fun (BACKSLASH, p_print, f1) || seq2wth_parser_fun (BACKSLASH, p_digit^+, f2) ) : charpar (char) where { fn f1 (bs: charpos, cp: charpos):<> char = let val chr = case+ cp.0 of | 'a' => '\007' (* alert *) | 'b' => '\010' (* backspace *) | 'f' => '\014' (* line feed *) | 't' => '\011' (* horizontal tab *) | 'n' => '\012' (* newline *) | 'r' => '\015' (* carriage return *) | 'v' => '\013' (* vertical tab *) | chr => chr in chr end // end of [f1] fn f2 (bs: charpos, res: List1 charpos):<> char = let val+ list_cons (cp, cps) = res var err: int = 1 val int = loop (cps, cp.0 - '0', err) where { fun loop {n:nat} .. (cps: list (charpos, n), int: int, err: &int):<> int = case+ cps of | list_cons (cp, cps) => let val () = err := err + 1 in loop (cps, (cp.0 - '0') + 8 * int, err) end // end of [list_cons] | list_nil () => int // end of [loop] } val () = $effmask_all ( if err <= 3 then () else begin prerr bs.1; prerr ": error(0)"; prerr ": the number of digits following the backslash (\) should be no more than 3."; prerr_newline (); exit {void} (1) end // end of [if] ) // end of [val] in char_of_int int end // end of [f2] } // end of [p_escape_char] val p_chr_inside = ( BACKSLASHneg wth f || p_escape_chr ) : charpar (char) where { fn f (cp: charpos):<> char = cp.0 } // end of [p_chr_inside] val p_token_chr = (seq3wth_parser_fun (SQUOTE, p_chr_inside, anyoptcharpos, f) ) : charpar (token) where { fn f (cp0: charpos, chr: char, ocp1: Option charpos) :<> token = case+ ocp1 of | Some cp1 => let var err: int = 0; val c1 = cp1.0 val () = if c1 <> '\'' then err := err + 1 val () = $effmask_all (if (err > 0) then begin prerr cp1.1; prerr ": error(0)"; prerr ": the character ["; prerr c1; prerr "] should be a closing quote but it is not."; prerr_newline (); exit {void} (1) end) // end of [val] val loc = location_make (cp0.1, cp1.1) in token_chr_make (loc, chr) end // end of [Some] | None () => $effmask_all begin prerr cp0.1; prerr ": error(0)"; prerr ": the quote is left open until the end."; prerr_newline (); exit {token} (1) end // end of [None] // end of [f] } // end of [p_token_chr] (* ****** ****** *) val DQUOTE = litchar '"' // double quote val p_str_inside = ( (BACKSLASHneg \sat pred) wth f || p_escape_chr ) : charpar (char) where { fn pred (cp: charpos):<> bool = case+ cp.0 of c when c = '"' => false | _ => true // end of [pred] fn f (cp: charpos):<> char = cp.0 } // end of [p_str_inside] val p_token_str = (seq3wth_parser_fun (DQUOTE, p_str_inside^*, anyoptcharpos, f) ) : charpar (token) where { fn f (cp0: charpos, cs: List char, ocp1: Option charpos) :<> token = case+ ocp1 of | Some cp1 => let val () = // check if the string is closed if cp1.0 <> '"' then $effmask_all begin prerr cp0.1; prerr ": error(0)"; prerr ": the double quote is unclosed."; prerr_newline (); exit {void} (1) end : void // end of [val] val loc = location_make (cp0.1, cp1.1) val ncs = list_length (cs) val str = string1_of_strbuf (string_make_list_int (cs, ncs)) in token_str_make (loc, str) end // end of [Some] | None () => $effmask_all begin prerr cp0.1; prerr ": error(0)"; prerr ": the double quote is left open until the end."; prerr_newline (); exit {token} (1) end // end of [None] // end of [f] } // end of [p_token_str] (* ****** ****** *) local fun loop {n:nat} .. (cps: list (charpos, n), int: int, pos: pos_t):<0> @(int, pos_t) = case+ cps of | list_cons (cp, cps) => loop (cps, (cp.0 - '0') + 10 * int, cp.1) | list_nil () => @(int, pos) // end of [loop] in // in of [local] // // parsing unsigned integers // val p_token_uint = (p_digit^+ wth f): charpar token where { fn f (cps: List1 charpos):<> token = let val+ list_cons (cp, cps) = cps val pos_beg = cp.1 val ip = loop (cps, cp.0 - '0', pos_beg) val loc = location_make (pos_beg, ip.1) in token_int_make (loc, ip.0) end // end of [f] } // end of [p_token_uint] val p_token_int = ( p_token_uint || (p_UMINUS && p_digit^+) wth f ) : charpar token where { fn f (res: @(charpos, List1 charpos)):<> token = let val cp = res.0 and cps = res.1 val p_beg = cp.1; val ip = loop (cps, 0, p_beg) val loc = location_make (p_beg, ip.1) in token_int_make (loc, ~ip.0) end // end of [f] } // end of [p_token_int] end // end of [local] (* ****** ****** *) val p_letter = (anycharpos \sat pred): charpar (charpos) where { fn pred (cp: charpos): bool = let val c = cp.0 in if char_isalpha c then true else (c = '_') end // end of [pred] } // end of [p_letter] val p_letdig = (anycharpos \sat pred): charpar (charpos) where { fn pred (cp: charpos): bool = let val c = cp.0 in if char_isalpha c then true else (if char_isdigit c then true else cp.0 = '_') end // end of [pred] } // end of [p_letdig] val p_symbolic = anycharpos \sat ( lam (cp: charpos): bool = string_contains ("!%&$#+-./:<=>?@\\~`|*", cp.0) ) // end of [p_symbolic] val p_token_ide = let fn f1 (cp: charpos, cps: List charpos):<> token = let val n = list_length (cps) val (pf_gc, pf | p0) = malloc_gc (size1_of_int1 (n+2)) prval pf = chars_v_of_b0ytes_v (pf) prval (pf1, pf2) = array_v_uncons {char} (pf) val () = !p0 := cp.0 val pos_beg = cp.1; val pos_end = loop (pf2 | p0 + sizeof, cps, pos_beg) where { fun loop {n:nat} {l:addr} .. ( pf: !chars (n+1) @ l | p: ptr l, cps: list (charpos, n), pos: pos_t ) :<> pos_t = begin case+ cps of | list_cons (cp, cps) => let prval (pf1, pf2) = array_v_uncons {char} (pf) val () = !p := cp.0 val pos_end = loop (pf2 | p + sizeof, cps, cp.1) prval () = pf := array_v_cons {char} (pf1, pf2) in pos_end end // end of [list_cons] | list_nil () => pos end // end of [loop] } // end of [val] val loc = location_make (pos_beg, pos_end) prval pf = array_v_cons {char} (pf1, pf2) prval pf = bytes_v_of_chars_v (pf) val () = bytes_strbuf_trans (pf | p0, size1_of_int1 (n+1)) val str = string1_of_strbuf @(pf_gc, pf | p0) in token_ide_make (loc, str) end // end of [f1] fn f2 (res: List1 charpos):<> token = let val+ list_cons (cp, cps) = res in f1 (cp, cps) end // end of [f2] in seq2wth_parser_fun (p_letter, p_letdig^*, f1) || (p_symbolic^+ wth f2) end // end of [p_token_ide] (* ****** ****** *) val p_ignores = discard_many_parser (p_space >> p_spaces || p_line_comment || p_comment) val p_token = p_ignores >> ( p_comma || p_semicolon || p_lparen || p_rparen || p_lbracket || p_rbracket || p_lbrace || p_rbrace || p_token_int || p_token_ide || p_token_chr || p_token_str ) : charpar token (* ****** ****** *) // // declared in [parcomb.sats] // implement tokenstream_make_charstream (cs) = let fun make (cps: stream charpos) : stream token = $delay (make_con cps) and make_con (cps: stream charpos) : stream_con token = let var cps = cps var ncur: int = 0 and nmax: int = 0 val r = apply_parser (p_token, cps, ncur, nmax) in case+ r of | ~Some_vt tk => stream_cons (tk, make cps) | ~None_vt () => stream_nil () end // end of [make_con] val cps = begin charposstream_make_charstream (cs, position_origin) end // end of [val] in make cps end // end of [tokenstream_make_charstream] (* ****** ****** *) (* // some code for testing: staload _(*anon*) = "prelude/DATS/list.dats" ; dynload "posloc.dats" ; (* ****** ****** *) implement main () = let val cs = char_stream_make_file stdin_ref var tks = tokenstream_make_charstream (cs) val () = loop (tks) where { fun loop (tks: &stream token): void = let val r = stream_item_get (tks) in case+ r of | ~Some_vt tok => let val () = begin print tok.token_loc; print ": "; print tok; print_newline () end // end of [val] in loop (tks) end // end of [Some_vt] | ~None_vt () => () end // end of [loop] } // end of [val] in // empty end // end of [main] *) (* ****** ****** *) (* end of [tokenize.dats] *) ats-lang-anairiats-0.2.11/contrib/parcomb/DATS/parcomb.dats0000664000175000017500000005136012223166163022121 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "contrib/parcomb/SATS/parcomb.sats" (* ****** ****** *) #define Okay Some_vt #define Fail None_vt (* ****** ****** *) implement{t} stream_get_item (tks) = case+ !tks of | stream_cons (tk1, tks1) => (tks := tks1; Some_vt tk1) | stream_nil () => None_vt () // end of [stream_get_item] (* ****** ****** *) assume parser_t = // no [ref] effect! lam (a:t@ype, t:t@ype) => (&stream t, &int, &int) - Option_vt a // end of [parser_t] (* ****** ****** *) implement{a}{t} apply_parser (p, tks, ncur, nmax) = p (tks, ncur, nmax) (* ****** ****** *) implement lzeta (p) = lam (tks, ncur, nmax) => !p (tks, ncur, nmax) (* ****** ****** *) implement{a}{t} return_parser (x) = lam (tks, ncur, nmax) => Okay (x) (* ****** ****** *) implement{a}{t} alt_parser_parser (p1, p2) = lam (tks, ncur, nmax) => let val tks0 = tks val ncur0 = ncur val r1 = p1 (tks, ncur, nmax) in case+ r1 of | Okay _ => (fold@ r1; r1) | ~Fail _ => let val () = tks := tks0 and () = ncur := ncur0 in p2 (tks, ncur, nmax) end (* end of [Fail] *) end // end of [alt_parser_parser] (* ****** ****** *) implement{a1,a2}{t} seq_parser_parser (p1, p2) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => Okay @(v1, v2) | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq_parser_parser] (* ****** ****** *) implement{a,b}{t} seq1wth_parser_fun (p, f) = lam (tks, ncur, nmax) => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => Okay (f v) | Fail _ => (fold@ r; r) end // end of [seq1wth_parser_fun] implement{a,b}{t} seq1wth_parser_cloref (p, f) = lam (tks, ncur, nmax) => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => Okay (f v) | Fail _ => (fold@ r; r) end // end of [seq1wth_parser_cloref] (* ****** ****** *) implement{a1,a2,b}{t} seq2wth_parser_fun (p1, p2, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => Okay (f (v1, v2)) | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq2wth_parser_fun] implement{a1,a2,b}{t} seq2wth_parser_cloref (p1, p2, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => Okay (f (v1, v2)) | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq2wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,b}{t} seq3wth_parser_fun (p1, p2, p3, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => Okay (f (v1, v2, v3)) | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq3wth_parser_fun] implement{a1,a2,a3,b}{t} seq3wth_parser_cloref (p1, p2, p3, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => Okay (f (v1, v2, v3)) | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq3wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,a4,b}{t} seq4wth_parser_fun (p1, p2, p3, p4, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => Okay (f (v1, v2, v3, v4)) | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq4wth_parser_fun] implement{a1,a2,a3,a4,b}{t} seq4wth_parser_cloref (p1, p2, p3, p4, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => Okay (f (v1, v2, v3, v4)) | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq4wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,a4,a5,b}{t} seq5wth_parser_fun (p1, p2, p3, p4, p5, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => Okay (f (v1, v2, v3, v4, v5)) | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq5wth_parser_fun] implement{a1,a2,a3,a4,a5,b}{t} seq5wth_parser_cloref (p1, p2, p3, p4, p5, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => Okay (f (v1, v2, v3, v4, v5)) | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq5wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,a4,a5,a6,b}{t} seq6wth_parser_fun (p1, p2, p3, p4, p5, p6, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => Okay (f (v1, v2, v3, v4, v5, v6)) | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq6wth_parser_fun] implement{a1,a2,a3,a4,a5,a6,b}{t} seq6wth_parser_cloref (p1, p2, p3, p4, p5, p6, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => Okay (f (v1, v2, v3, v4, v5, v6)) | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq6wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,a4,a5,a6,a7,b}{t} seq7wth_parser_fun (p1, p2, p3, p4, p5, p6, p7, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => let val r7 = p7 (tks, ncur, nmax) in case+ r7 of | ~Okay v7 => Okay (f (v1, v2, v3, v4, v5, v6, v7)) | Fail _ => (fold@ r7; r7) end // end of [Okay] | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq7wth_parser_fun] implement{a1,a2,a3,a4,a5,a6,a7,b}{t} seq7wth_parser_cloref (p1, p2, p3, p4, p5, p6, p7, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => let val r7 = p7 (tks, ncur, nmax) in case+ r7 of | ~Okay v7 => Okay (f (v1, v2, v3, v4, v5, v6, v7)) | Fail _ => (fold@ r7; r7) end // end of [Okay] | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq7wth_parser_cloref] (* ****** ****** *) implement{a1,a2,a3,a4,a5,a6,a7,a8,b}{t} seq8wth_parser_fun (p1, p2, p3, p4, p5, p6, p7, p8, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => let val r7 = p7 (tks, ncur, nmax) in case+ r7 of | ~Okay v7 => let val r8 = p8 (tks, ncur, nmax) in case+ r8 of | ~Okay v8 => Okay (f (v1, v2, v3, v4, v5, v6, v7, v8)) | Fail _ => (fold@ r8; r8) end // end of [Okay] | Fail _ => (fold@ r7; r7) end // end of [Okay] | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq8wth_parser_fun] implement{a1,a2,a3,a4,a5,a6,a7,a8,b}{t} seq8wth_parser_cloref (p1, p2, p3, p4, p5, p6, p7, p8, f) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay v1 => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay v2 => let val r3 = p3 (tks, ncur, nmax) in case+ r3 of | ~Okay v3 => let val r4 = p4 (tks, ncur, nmax) in case+ r4 of | ~Okay v4 => let val r5 = p5 (tks, ncur, nmax) in case+ r5 of | ~Okay v5 => let val r6 = p6 (tks, ncur, nmax) in case+ r6 of | ~Okay v6 => let val r7 = p7 (tks, ncur, nmax) in case+ r7 of | ~Okay v7 => let val r8 = p8 (tks, ncur, nmax) in case+ r8 of | ~Okay v8 => Okay (f (v1, v2, v3, v4, v5, v6, v7, v8)) | Fail _ => (fold@ r8; r8) end // end of [Okay] | Fail _ => (fold@ r7; r7) end // end of [Okay] | Fail _ => (fold@ r6; r6) end // end of [Okay] | Fail _ => (fold@ r5; r5) end // end of [Okay] | Fail _ => (fold@ r4; r4) end // end of [Okay] | Fail _ => (fold@ r3; r3) end // end of [Okay] | Fail _ => (fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [seq8wth_parser_cloref] (* ****** ****** *) implement{a1,a2}{t} proj1_parser_parser (p1, p2) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | Okay _(*v1*) => let val r2 = p2 (tks, ncur, nmax) in case+ r2 of | ~Okay _(*v2*) => (fold@ r1; r1) | Fail _ => (free@ {a1} r1; fold@ r2; r2) end // end of [Okay] | Fail _ => (fold@ r1; r1) end // end of [proj1_parser_parser] implement{a1,a2}{t} proj2_parser_parser (p1, p2) = lam (tks, ncur, nmax) => let val r1 = p1 (tks, ncur, nmax) in case+ r1 of | ~Okay _(*v1*) => p2 (tks, ncur, nmax) | Fail _ => (fold@ r1; r1) end // end of [proj2_parser_parser] (* ****** ****** *) implement{a}{t} sat_parser_fun (p, f) = lam (tks, ncur, nmax) => let val tks0 = tks and ncur0 = ncur val r = p (tks, ncur, nmax) in case+ r of | Okay v => begin if f v then (fold@ r; r) else begin tks := tks0; ncur := ncur0; free@ {a} (r); Fail () end // end of [if] end (* end of [Okay] *) | Fail _ => (fold@ r; r) end // end of [sat_parser_fun] implement{a}{t} sat_parser_cloref (p, f) = lam (tks, ncur, nmax) => let val tks0 = tks and ncur0 = ncur val r = p (tks, ncur, nmax) in case+ r of | Okay v => begin if f v then (fold@ r; r) else begin tks := tks0; ncur := ncur0; free@ {a} (r); Fail () end // end of [if] end (* end of [Okay] *) | Fail _ => (fold@ r; r) end // end of [sat_parser_cloref] (* ****** ****** *) implement{a} any_parser () = lam (tks, ncur, nmax) => let val ans = stream_get_item tks in case+ ans of | ~Some_vt v => Okay v where { val () = ncur := ncur + 1 val () = if ncur > nmax then nmax := ncur } // end of [Some_vt] | ~None_vt () => Fail () end // end of [any_parser] implement{a} anyopt_parser () = lam (tks, ncur, nmax) => let val ans = stream_get_item tks in case+ ans of | ~Some_vt v => Okay (Some v) where { val () = ncur := ncur + 1 val () = if ncur > nmax then nmax := ncur } // end of [Some] | ~None_vt () => Okay (None ()) end // end of [anyopt_parser] (* ****** ****** *) implement{} fail_parser () = lam (tks, ncur, nmax) => Fail () (* ****** ****** *) // // HX: it is difficult to know where the failure occurs! // implement{a}{t} neg_parser (p) = lam (tks, ncur, nmax) => let val tks0 = tks and ncur0 = ncur val r = p (tks, ncur, nmax) val () = tks := tks0 and () = ncur := ncur0 in case+ r of ~Okay _ => Fail () | ~Fail _ => Okay (unit) end // end of [neg_parser] (* ****** ****** *) implement{a}{t} optional_parser (p) = lam (tks, ncur, nmax) => let val tks0 = tks and ncur0 = ncur; val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => Okay (Some v) | ~Fail _ => begin tks := tks0; ncur := ncur0; Okay (None ()) // no token is consumed end // end of [Fail] end // end of [optional_parser] (* ****** ****** *) implement{a}{t} repeat0_parser (p) = lam (tks, ncur, nmax) => let typedef T = List a fun loop ( tks: &stream t, ncur: &int, nmax: &int, p: parser_t (a, t), res: &T? >> T ) : void = let val tks0 = tks and ncur0 = ncur; val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => let val () = res := list_cons {a} {0} (v, ?) val list_cons (_, !p_res_nxt) = res val () = loop (tks, ncur, nmax, p, !p_res_nxt) in fold@ res end // end of [Okay] | ~Fail _ => begin tks := tks0; ncur := ncur0; res:= list_nil () end // end of [Fail] end // end of [loop] var res: T // uninitialized val () = loop (tks, ncur, nmax, p, res) in Okay (res) // this parser never fails end // end of [repeat0_parser] (* ****** ****** *) implement{a}{t} repeat1_parser (p) = lam (tks, ncur, nmax) => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => let val- ~Okay (vs) = repeat0_parser (p) (tks, ncur, nmax) in Okay (list_cons (v, vs)) end // end of [Okay] | Fail _ => (fold@ r; r) end // end of [repeat1_parser] (* ****** ****** *) implement{a,b}{t} repeat0_sep_parser (p, sep) = lam (tks, ncur, nmax) => let val tks0 = tks and ncur0 = ncur val r = repeat1_sep_parser (p, sep) (tks, ncur, nmax) in case+ r of | Okay _ => (fold@ r; r) | ~Fail _ => let val () = tks := tks0 and () = ncur := ncur0 in Okay (list_nil) end // end of [Fail] end // end of [repeat0_sep_parser] implement{a,b}{t} repeat1_sep_parser (p, sep) = lam (tks, ncur, nmax) => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v0 => let var res: List a // uninitialized val () = loop (tks, ncur, nmax, res) where { fun loop ( tks: &stream t, ncur: &int, nmax: &int , res: &(List a?) >> List a ) : void = let val tks0 = tks and ncur0 = ncur in case+ sep (tks, ncur, nmax) of | ~Okay v_sep => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => let val () = res := list_cons {a} {0} (v, ?) val list_cons (_, !p_res_next) = res val () = loop (tks, ncur, nmax, !p_res_next) in fold@ res end // end of [Okay] | ~Fail _ => begin tks := tks0; ncur := ncur0; res := list_nil () end // end of [Fail] end // end of [Okay] | ~Fail _ => begin tks := tks0; ncur := ncur0; res := list_nil () end // end of [Fail] end // end of [loop] } // end of [val] in Okay (list_cons (v0, res)) end // end of [Okay] | Fail _ => (fold@ r; r) end // end of [repeat1_sep_parser] (* ****** ****** *) implement{a}{t} discard_one_parser (p) = lam (tks, ncur, nmax) => let val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => Okay unit | Fail _ => (fold@ r; r) end // end of [discard_parser] implement{a}{t} discard_many_parser (p) = lam (tks, ncur, nmax) => let fun loop ( tks: &stream t, ncur: &int, nmax: &int, p: parser_t (a, t) ) : void = let val tks0 = tks and ncur0 = ncur val r = p (tks, ncur, nmax) in case+ r of | ~Okay v => loop (tks, ncur, nmax, p) | ~Fail _ => (tks := tks0; ncur := ncur0) end // end of [loop] val () = loop (tks, ncur, nmax, p) in Okay (unit) end // end of [discard_many_parser] (* ****** ****** *) (* end of [parcomb.dats] *) ats-lang-anairiats-0.2.11/contrib/GTK/0000700000175000017500000000000012223166165016051 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/CATS/0000700000175000017500000000000012223166165016603 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/CATS/gdk.cats0000664000175000017500000001036412223166165020244 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: April, 2010 // /* ****** ****** */ #ifndef ATSCTRB_GTK_GDK_CATS #define ATSCTRB_GTK_GDK_CATS /* ****** ****** */ #include /* ****** ****** */ // // source: gdkcairo.h // #define atsctrb_gdk_cairo_create gdk_cairo_create #define atsctrb_gdk_cairo_set_source_color gdk_cairo_set_source_color #define atsctrb_gdk_cairo_set_source_pixbuf gdk_cairo_set_source_pixbuf #define atsctrb_gdk_cairo_set_source_pixmap gdk_cairo_set_source_pixmap #define atsctrb_gdk_cairo_rectangle gdk_cairo_rectangle #define atsctrb_gdk_cairo_region gdk_cairo_region #define atsctrb_gdk_cairo_reset_clip gdk_cairo_reset_clip /* ****** ****** */ // // source: gdkcolor.h // ATSinline() ats_void_type atsctrb_gdk_color3_set ( ats_ptr_type p_color , ats_uint_type r, ats_uint_type b, ats_uint_type g ) { ((GdkColor*)p_color)->red = (guint16)r ; ((GdkColor*)p_color)->blue = (guint16)b ; ((GdkColor*)p_color)->green = (guint16)g ; return ; } // end of [atsctrb_gdk_color3_set] ATSinline() ats_void_type atsctrb_gdk_color4_set ( ats_ptr_type p_color , ats_uint_type pix , ats_uint_type r, ats_uint_type b, ats_uint_type g ) { ((GdkColor*)p_color)->pixel = (guint32)pix ; ((GdkColor*)p_color)->red = (guint16)r ; ((GdkColor*)p_color)->blue = (guint16)b ; ((GdkColor*)p_color)->green = (guint16)g ; return ; } // end of [atsctrb_gdk_color4_set] #define atsctrb_gdk_color_copy gdk_color_copy #define atsctrb_gdk_color_free gdk_color_free #define atsctrb_gdk_color_parse gdk_color_parse /* ****** ****** */ // // source: gdkevent.h // ATSinline() ats_bool_type atsctrb_eq_GdkEventType_GdkEventType (GdkEventType x1, GdkEventType x2) { return (x1 == x2) ; } // end of [atsctrb_eq_GdkEventType_GdkEventType] ATSinline() GdkEventMask atsctrb_lor_GdkEventMask_GdkEventMask (GdkEventMask x1, GdkEventMask x2) { return (x1 | x2) ; } // end of [atsctrb_lor_GdkEventMask_GdkEventMask] ATSinline() ats_bool_type atsctrb_eq_GdkVisibilityState_GdkVisibilityState (GdkVisibilityState x1, GdkVisibilityState x2) { return (x1 == x2) ; } // end of [atsctrb_eq_GdkVisibilityState_GdkVisibilityState] /* ****** ****** */ // // source: gdkpixbuf.h // #define atsctrb_gdk_pixbuf_render_threshold_alpha \ gdk_pixbuf_render_threshold_alpha /* ****** ****** */ // // source: gdkpixmap.h // #define atsctrb_gdk_pixmap_new gdk_pixmap_new /* ****** ****** */ // // source: gdkrgb.h // #define atsctrb_gdk_rgb_find_color gdk_rgb_find_color /* ****** ****** */ // // source: gdkwindow.h // #define atsctrb_gdk_window_set_background gdk_window_set_background #define atsctrb_gdk_window_invalidate_rect gdk_window_invalidate_rect #define atsctrb_gdk_window_process_updates gdk_window_process_updates #define atsctrb_gdk_window_process_all_updates gdk_window_process_all_updates /* ****** ****** */ #endif // end of [ATSCTRB_GTK_GDK_CATS] ats-lang-anairiats-0.2.11/contrib/GTK/CATS/gtk.cats0000664000175000017500000014070612223166165020270 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: April, 2010 // /* ****** ****** */ #ifndef ATSCTRB_GTK_GTK_CATS #define ATSCTRB_GTK_GTK_CATS /* ****** ****** */ #include /* ****** ****** */ ATSinline() GtkAttachOptions atsctrb_lor_GtkAttachOptions_GtkAttachOptions (GtkAttachOptions x1, GtkAttachOptions x2) { return (x1 | x2) ; } // end of [atsctrb_lor_GtkAttachOptions_GtkAttachOptions] ATSinline() GtkAccelFlags atsctrb_lor_GtkAccelFlags_GtkAccelFlags (GtkAccelFlags x1, GtkAccelFlags x2) { return (x1 | x2) ; } // end of [atsctrb_lor_GtkAccelFlags_GtkAccelFlags] /* ****** ****** */ // // source: gtk/gtkaccelgroup.h // // // HX-2010-05-02: // it is a direct subclass of GObject, so there is no floating reference // #define atsctrb_gtk_accel_group_new gtk_accel_group_new /* ****** ****** */ // // source: gtk/gtkadjustment.h // ATSinline() ats_ptr_type atsctrb_gtk_adjustment_new ( gdouble value , gdouble lower , gdouble upper , gdouble step_inc , gdouble page_inc , gdouble page_size ) { GtkObject *adj = gtk_adjustment_new (value, lower, upper, step_inc, page_inc, page_size) ; g_object_ref_sink(G_OBJECT(adj)) ; // removing floating reference! return adj ; } // end of [atsctrb_gtk_adjustment_new] #define atsctrb_gtk_adjustment_get_value gtk_adjustment_get_value #define atsctrb_gtk_adjustment_set_value gtk_adjustment_set_value /* ****** ****** */ // // source: gtk/gtkalignment.h // ATSinline() ats_ptr_type atsctrb_gtk_alignment_new ( gfloat xalign , gfloat yalign , gfloat xscale , gfloat yscale ) { GtkWidget *widget = gtk_alignment_new (xalign, yalign, xscale, yscale) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_alignment_new] #define atsctrb_gtk_alignment_set gtk_alignment_set #define atsctrb_gtk_alignment_get_padding gtk_alignment_get_padding #define atsctrb_gtk_alignment_set_padding gtk_alignment_set_padding /* ****** ****** */ // // source: gtk/gtkarrow.h // ATSinline() ats_ptr_type atsctrb_gtk_arrow_new ( GtkArrowType arrow_type , GtkShadowType shadow_type ) { GtkWidget *widget = gtk_arrow_new(arrow_type, shadow_type); g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_arrow_new] #define atsctrb_gtk_arrow_set gtk_arrow_set /* ****** ****** */ // // source: gtk/gtkbox.h // #define atsctrb_gtk_box_pack_start gtk_box_pack_start #define atsctrb_gtk_box_pack_end gtk_box_pack_end /* ****** ****** */ // // source: gtk/gtkbutton.h // ATSinline() ats_ptr_type atsctrb_gtk_button_new () { GtkWidget *widget = gtk_button_new() ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_button_new] ATSinline() ats_ptr_type atsctrb_gtk_button_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_button_new_with_label((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_button_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_button_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_button_new_with_mnemonic((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_button_new_with_mnemonic] ATSinline() ats_ptr_type atsctrb_gtk_button_new_from_stock (ats_ptr_type stock_id) { GtkWidget *widget = gtk_button_new_from_stock((gchar*)stock_id) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_button_new_from_stock] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_gtk_button_get_label (ats_ptr_type button) { // HX: a string constant is returned: return (void*)gtk_button_get_label((GtkButton*)button) ; } // end of [atsctrb_gtk_button_get_label] #define atsctrb_gtk_button_set_label gtk_button_set_label /* ****** ****** */ // // source: gtk/gtkcheckbutton.h // ATSinline() ats_ptr_type atsctrb_gtk_check_button_new () { GtkWidget *widget = gtk_check_button_new() ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_button_new] ATSinline() ats_ptr_type atsctrb_gtk_check_button_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_check_button_new_with_label((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_button_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_check_button_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_check_button_new_with_mnemonic((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_button_new_with_mnemonic] /* ****** ****** */ // // source: gtk/gtkcheckmenuitem.h // ATSinline() ats_ptr_type atsctrb_gtk_check_menu_item_new () { GtkWidget *widget = gtk_check_menu_item_new() ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_menu_item_new] ATSinline() ats_ptr_type atsctrb_gtk_check_menu_item_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_check_menu_item_new_with_label((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_menu_item_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_check_menu_item_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_check_menu_item_new_with_mnemonic((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_check_menu_item_new_with_mnemonic] #define atsctrb_gtk_check_menu_item_get_active gtk_check_menu_item_get_active #define atsctrb_gtk_check_menu_item_set_active gtk_check_menu_item_set_active #define atsctrb_gtk_check_menu_item_get_inconsistent gtk_check_menu_item_get_inconsistent #define atsctrb_gtk_check_menu_item_set_inconsistent gtk_check_menu_item_set_inconsistent #define atsctrb_gtk_check_menu_item_get_draw_as_radio gtk_check_menu_item_get_draw_as_radio #define atsctrb_gtk_check_menu_item_set_draw_as_radio gtk_check_menu_item_set_draw_as_radio /* ****** ****** */ // // source: gtk/gtkclipboard.h // #define atsctrb_gtk_clipboard_get gtk_clipboard_get #define atsctrb_gtk_clipboard_wait_is_text_available gtk_clipboard_wait_is_text_available /* ****** ****** */ // // source: gtk/gtkcontainer.h // #define atsctrb_gtk_container_add gtk_container_add #define atsctrb_gtk_container_remove gtk_container_remove #define atsctrb_gtk_container_set_border_width gtk_container_set_border_width /* ****** ****** */ // // source: gtk/gtkcolorsel.h // ATSinline() ats_ptr_type atsctrb_gtk_color_selection_new () { GtkWidget *widget = gtk_color_selection_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_color_selection_new] #define atsctrb_gtk_color_selection_get_previous_color \ gtk_color_selection_get_previous_color #define atsctrb_gtk_color_selection_set_previous_color \ gtk_color_selection_set_previous_color #define atsctrb_gtk_color_selection_get_current_color \ gtk_color_selection_get_current_color #define atsctrb_gtk_color_selection_set_current_color \ gtk_color_selection_set_current_color #define atsctrb_gtk_color_selection_set_has_palette \ gtk_color_selection_set_has_palette #define atsctrb_gtk_color_selection_set_has_opacitiy_control \ gtk_color_selection_set_has_opacitiy_control /* ****** ****** */ // // source: gtk/gtkcolorseldialog.h // ATSinline() ats_ptr_type atsctrb_gtk_color_selection_dialog_new (ats_ptr_type title) { GtkWidget *widget = gtk_color_selection_dialog_new ((gchar*)title) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_color_selection_dialog_new] ATSinline() ats_ptr_type atsctrb_gtk_color_selection_dialog_get_colorsel (ats_ptr_type colorseldlg) { return ((GtkColorSelectionDialog*)colorseldlg)->colorsel ; } // end of [...] /* ****** ****** */ // // source: gtk/gtkdialog.h // ATSinline() GtkDialogFlags atsctrb_lor_GtkDialogFlags_GtkDialogFlags (GtkDialogFlags x1, GtkDialogFlags x2) { return (x1 | x2) ; } // end of [atsctrb_lor_GtkDialogFlags_GtkDialogFlags] ATSinline() ats_ptr_type atsctrb_gtk_dialog_new () { GtkWidget *widget = gtk_dialog_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_dialog_new] ATSinline() ats_ptr_type atsctrb_gtk_dialog_get_window (ats_ptr_type dialog) { return &((GtkDialog*)dialog)->window ; } // end of [gtk_dialog_get_window] ATSinline() ats_ptr_type atsctrb_gtk_dialog_get_vbox (ats_ptr_type dialog) { return ((GtkDialog*)dialog)->vbox ; } // end of [...] ATSinline() ats_ptr_type atsctrb_gtk_dialog_get_action_area (ats_ptr_type dialog) { return ((GtkDialog*)dialog)->action_area ; } // end of [...] #define atsctrb_gtk_dialog_add_button gtk_dialog_add_button #define atsctrb_gtk_dialog_run gtk_dialog_run /* ****** ****** */ // // source: gtk/gtkdrawingarea.h // ATSinline() ats_ptr_type atsctrb_gtk_drawing_area_new () { GtkWidget *widget = gtk_drawing_area_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_drawing_area_new] /* ****** ****** */ // // source: gtk/gtkentry.h // ATSinline() ats_ptr_type atsctrb_gtk_entry_new () { GtkWidget *widget = gtk_entry_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_entry_new] #define atsctrb_gtk_entry_get_editable gtk_entry_get_editable #define atsctrb_gtk_entry_set_editable gtk_entry_set_editable #define atsctrb_gtk_entry_get_visibility gtk_entry_get_visibility #define atsctrb_gtk_entry_set_visibility gtk_entry_set_visibility #define atsctrb_gtk_entry_get_max_length gtk_entry_get_max_length #define atsctrb_gtk_entry_set_max_length gtk_entry_set_max_length ATSinline() ats_ptr_type atsctrb_gtk_entry_get_text (ats_ptr_type entry) { // it returns a const pointer return (void*)gtk_entry_get_text((GtkEntry*)entry) ; } #define atsctrb_gtk_entry_set_text gtk_entry_set_text /* ****** ****** */ // // source: gtk/gtkfilechooser.h // #define atsctrb_GTK_FILE_CHOOSER GTK_FILE_CHOOSER #define atsctrb_gtk_file_chooser_get_action gtk_file_chooser_get_action #define atsctrb_gtk_file_chooser_set_action gtk_file_chooser_set_action ATSinline() ats_ptr_type atsctrb_gtk_file_chooser_get_filename (ats_ptr_type filesel) { return (void*)gtk_file_chooser_get_filename ((GtkFileChooser*)filesel) ; } // end of [atsctrb_gtk_file_chooser_get_filename] #define atsctrb_gtk_file_chooser_set_filename gtk_file_chooser_set_filename #define atsctrb_gtk_file_chooser_set_current_name gtk_file_chooser_set_current_name #define atsctrb_gtk_file_chooser_get_do_overwrite_confirmation \ gtk_file_chooser_get_do_overwrite_confirmation #define atsctrb_gtk_file_chooser_set_do_overwrite_confirmation \ gtk_file_chooser_set_do_overwrite_confirmation /* ****** ****** */ // // source: gtk/gtkfilechooserdialog.h // ATSinline() ats_ptr_type atsctrb_gtk_file_chooser_dialog_new ( ats_ptr_type title, GtkFileChooserAction action ) { GtkWidget *widget = gtk_file_chooser_dialog_new ( (gchar*)title , NULL // parent window , action , NULL //, 0 // response_id // HX-2010-05-25: this is unnecessary , NULL // button/reponse_id pairs ) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_file_chooser_dialog_new] /* ****** ****** */ // // source: gtk/gtkfilesel.h // // HX-2010-04-19: // this is all DEPRECATED; please use gtk/gtkfilechooserdialog.h // ATSinline() ats_ptr_type atsctrb_gtk_file_selection_new (ats_ptr_type title) { GtkWidget *widget = gtk_file_selection_new ((gchar*)title) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_file_selection_new] ATSinline() ats_ptr_type atsctrb_gtk_file_selection_get_ok_button (ats_ptr_type filesel) { return ((GtkFileSelection*)filesel)->ok_button ; } // end of [...] ATSinline() ats_ptr_type atsctrb_gtk_file_selection_get_cancel_button (ats_ptr_type filesel) { return ((GtkFileSelection*)filesel)->cancel_button ; } // end of [...] ATSinline() ats_ptr_type atsctrb_gtk_file_selection_get_filename (ats_ptr_type filesel) { return (void*)gtk_file_selection_get_filename ((GtkFileSelection*)filesel) ; } // end of [atsctrb_gtk_file_selection_get_filename] #define atsctrb_gtk_file_selection_set_filename gtk_file_selection_set_filename /* ****** ****** */ // // source: gtk/gtkfontsel.h // ATSinline() ats_ptr_type atsctrb_gtk_font_selection_new () { GtkWidget *widget = gtk_font_selection_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_font_selection_new] ATSinline() ats_ptr_type atsctrb_gtk_font_selection_dialog_new (ats_ptr_type title) { GtkWidget *widget = gtk_font_selection_dialog_new ((gchar*)title) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_font_selection_dialog_new] #define atsctrb_gtk_font_selection_dialog_get_ok_button \ gtk_font_selection_dialog_get_ok_button #define atsctrb_gtk_font_selection_dialog_get_cancel_button \ gtk_font_selection_dialog_get_cancel_button #define atsctrb_gtk_font_selection_dialog_get_font_name \ gtk_font_selection_dialog_get_font_name #define atsctrb_gtk_font_selection_dialog_set_font_name \ gtk_font_selection_dialog_set_font_name #define atsctrb_gtk_font_selection_dialog_get_preview_text \ gtk_font_selection_dialog_get_preview_text #define atsctrb_gtk_font_selection_dialog_set_preview_text \ gtk_font_selection_dialog_set_preview_text /* ****** ****** */ // // source: gtk/gtkframe.h // ATSinline() ats_ptr_type atsctrb_gtk_frame_new (ats_ptr_type name) { GtkWidget *widget = gtk_frame_new ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_frame_new] #define atsctrb_gtk_frame_new_null() atsctrb_gtk_frame_new(NULL) #define atsctrb_gtk_frame_set_label gtk_frame_set_label #define atsctrb_gtk_frame_set_label_widget gtk_frame_set_label_widget #define atsctrb_gtk_frame_set_label_align gtk_frame_set_label_align #define atsctrb_gtk_frame_set_shadow_type gtk_frame_set_shadow_type /* ****** ****** */ // // source: gtk/gtkhbox.h // ATSinline() ats_ptr_type atsctrb_gtk_hbox_new ( gboolean homo, gint spacing ) { GtkWidget *widget = gtk_hbox_new (homo, spacing) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hbox_new] /* ****** ****** */ // // source: gtk/gtkhruler.h // ATSinline() ats_ptr_type atsctrb_gtk_hruler_new () { GtkWidget *widget = gtk_hruler_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hruler_new] /* ****** ****** */ // // source: gtk/gtkhpaned.h // ATSinline() ats_ptr_type atsctrb_gtk_hpaned_new () { GtkWidget *widget = gtk_hpaned_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hpaned_new] /* ****** ****** */ // // source: gtk/gtkhscale.h // ATSinline() ats_ptr_type atsctrb_gtk_hscale_new (ats_ptr_type adj) { GtkWidget *widget = gtk_hscale_new ((GtkAdjustment*)adj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hscale_new] ATSinline() ats_ptr_type atsctrb_gtk_hscale_new_with_range (gdouble min, gdouble max, gdouble step) { GtkWidget *widget = gtk_hscale_new_with_range (min, max, step) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hscale_new_with_range] /* ****** ****** */ // // source: gtk/gtkhsrollbar.h // ATSinline() ats_ptr_type atsctrb_gtk_hscrollbar_new (ats_ptr_type adj) { GtkWidget *widget = gtk_hscrollbar_new ((GtkAdjustment*)adj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hscrollbar_new] /* ****** ****** */ // // source: gtk/gtkhseparator.h // ATSinline() ats_ptr_type atsctrb_gtk_hseparator_new () { GtkWidget *widget = gtk_hseparator_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_hseparator_new] /* ****** ****** */ // // source: gtk/gtkimagemenuitem.h // ATSinline() ats_ptr_type atsctrb_gtk_image_menu_item_new () { GtkWidget *widget = gtk_image_menu_item_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_image_menu_item_new] ATSinline() ats_ptr_type atsctrb_gtk_image_menu_item_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_image_menu_item_new_with_label ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_image_menu_item_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_image_menu_item_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_image_menu_item_new_with_mnemonic ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_image_menu_item_new_with_mnemonic] ATSinline() ats_ptr_type atsctrb_gtk_image_menu_item_new_from_stock (ats_ptr_type name, ats_ptr_type aclgrp) { GtkWidget *widget = gtk_image_menu_item_new_from_stock ((gchar*)name, (GtkAccelGroup*)aclgrp) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_image_menu_item_new_from_stock] #define atsctrb_gtk_image_menu_item_new_from_stock_null(name) \ atsctrb_gtk_image_menu_item_new_from_stock(name, NULL) /* ****** ****** */ // // source: gtk/gtklabel.h // ATSinline() ats_ptr_type atsctrb_gtk_label_new (ats_ptr_type name) { GtkWidget *widget = gtk_label_new ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_label_new] #define atsctrb_gtk_label_get_text gtk_label_get_text #define atsctrb_gtk_label_set_text gtk_label_set_text #define atsctrb_gtk_label_get_justify gtk_label_get_justify #define atsctrb_gtk_label_set_justify gtk_label_set_justify #define atsctrb_gtk_label_get_line_wrap gtk_label_get_line_wrap #define atsctrb_gtk_label_set_line_wrap gtk_label_set_line_wrap /* ****** ****** */ // // source: gtk/gtkmenu.h // ATSinline() ats_ptr_type atsctrb_gtk_menu_new () { GtkWidget *widget = gtk_menu_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_menu_new] #define atsctrb_gtk_menu_popup_null(menu, button, time) \ gtk_menu_popup(menu, NULL, NULL, NULL, NULL, button, time) /* ****** ****** */ // // source: gtk/gtkmenubar.h // ATSinline() ats_ptr_type atsctrb_gtk_menu_bar_new () { GtkWidget *widget = gtk_menu_bar_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_menu_bar_new] /* ****** ****** */ // // source: gtk/gtkmenuitem.h // ATSinline() ats_ptr_type atsctrb_gtk_menu_item_new () { GtkWidget *widget = gtk_menu_item_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_menu_item_new] ATSinline() ats_ptr_type atsctrb_gtk_menu_item_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_menu_item_new_with_label ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_menu_item_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_menu_item_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_menu_item_new_with_mnemonic ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_menu_item_new_with_mnemonic] #if GTK_CHECK_VERSION(2, 16, 0) // >= GTK-2.16 #define atsctrb_gtk_menu_item_get_label gtk_menu_item_get_label // >= GTK-2.16 #define atsctrb_gtk_menu_item_set_label gtk_menu_item_set_label #else // // HX-2010-05-06: a kludge that can be scratched at any moment // ATSinline() ats_ptr_type atsctrb_gtk_menu_item_get_label ( ats_ptr_type menu_item, ats_ptr_type label ) { if (GTK_IS_LABEL (GTK_BIN (menu_item)->child)) return (void*)gtk_label_get_label (GTK_LABEL (GTK_BIN (menu_item)->child)) ; return NULL ; } // end of [atsctrb_gtk_menu_item_let_label] // ATSinline() ats_void_type atsctrb_gtk_menu_item_set_label ( ats_ptr_type menu_item, ats_ptr_type label ) { if (GTK_IS_LABEL (GTK_BIN (menu_item)->child)) { gtk_label_set_label (GTK_LABEL (GTK_BIN (menu_item)->child), label ? (gchar*)label : (gchar*)"") ; // g_object_notify (G_OBJECT (menu_item), "label"); // not really available } ; return ; } // end of [atsctrb_gtk_menu_item_set_label] // #endif // GTK_CHECK_VERSION(2, 16, 0) #define atsctrb_gtk_menu_item_set_submenu gtk_menu_item_set_submenu /* ****** ****** */ // // source: gtk/gtkmenushell.h // #define atsctrb_gtk_menu_shell_append gtk_menu_shell_append #define atsctrb_gtk_menu_shell_prepend gtk_menu_shell_prepend #define atsctrb_gtk_menu_shell_select_item gtk_menu_shell_select_item #define atsctrb_gtk_menu_shell_select_first gtk_menu_shell_select_first #define atsctrb_gtk_menu_shell_deselect gtk_menu_shell_deselect /* ****** ****** */ // // source: gtk/gtkmessagedialog.h // ATSinline() ats_ptr_type atsctrb_gtk_message_dialog_new0 ( GtkDialogFlags flags , GtkMessageType _type, GtkButtonsType buttons, ats_ptr_type msg ) { GtkWidget *widget = gtk_message_dialog_new (NULL, flags, _type, buttons, NULL) ; gtk_label_set_text ( GTK_LABEL (GTK_MESSAGE_DIALOG (widget)->label), (gchar*)msg ) ; // end of [gtk_label_set_text] g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_message_dialog_new0] ATSinline() ats_ptr_type atsctrb_gtk_message_dialog_new0_with_markup ( GtkDialogFlags flags , GtkMessageType _type, GtkButtonsType buttons, ats_ptr_type msg ) { GtkWidget *widget = gtk_message_dialog_new_with_markup (NULL, flags, _type, buttons, NULL) ; gtk_message_dialog_set_markup (GTK_MESSAGE_DIALOG (widget), (gchar*)msg) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_message_dialog_new0_with_markup] #define atsctrb_gtk_message_dialog_set_markup gtk_message_dialog_set_markup #define atsctrb_gtk_messgage_dialog_get_image gtk_messgage_dialog_get_image #define atsctrb_gtk_messgage_dialog_set_image gtk_messgage_dialog_set_image /* ****** ****** */ // // Source: gtk/gtkmisc.h // #define atsctrb_gtk_misc_get_alignment gtk_misc_get_alignment #define atsctrb_gtk_misc_set_alignment gtk_misc_set_alignment /* ****** ****** */ // // source: gtk/gtkoptionmenu.h // ATSinline() ats_ptr_type atsctrb_gtk_option_menu_new () { GtkWidget *widget = gtk_option_menu_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_option_menu_new] #define atsctrb_gtk_option_menu_set_menu gtk_option_menu_set_menu /* ****** ****** */ // // source: gtk/gtkpaned.h // #define atsctrb_gtk_paned_add1 gtk_paned_add1 #define atsctrb_gtk_paned_add2 gtk_paned_add2 #define atsctrb_gtk_paned_pack1 gtk_paned_pack1 #define atsctrb_gtk_paned_pack2 gtk_paned_pack2 #define atsctrb_gtk_paned_get_child1 gtk_paned_get_child1 #define atsctrb_gtk_paned_get_child2 gtk_paned_get_child2 #define atsctrb_gtk_paned_get_position gtk_paned_get_position #define atsctrb_gtk_paned_set_position gtk_paned_set_position #define atsctrb_gtk_paned_get_handle_window gtk_paned_get_handle_window /* ****** ****** */ // // source: gtk/gtkhprogress.h // #define atsctrb_gtk_progress_get_value gtk_progress_get_value #define atsctrb_gtk_progress_set_value gtk_progress_set_value /* ****** ****** */ // // source: gtk/gtkhprogressbar.h // ATSinline() ats_ptr_type atsctrb_gtk_progress_bar_new () { GtkWidget *widget = gtk_progress_bar_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_progress_bar_new] // // HX-2010-06-03: this one is deprecated! // ATSinline() ats_ptr_type atsctrb_gtk_progress_bar_new_with_adjustment (ats_ptr_type adj) { GtkWidget *widget = gtk_progress_bar_new_with_adjustment ((GtkAdjustment*)adj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_progress_bar_new_with_adjustment] #define atsctrb_gtk_progress_bar_pulse gtk_progress_bar_pulse #define atsctrb_gtk_progress_bar_get_text gtk_progress_bar_get_text #define atsctrb_gtk_progress_bar_set_text gtk_progress_bar_set_text #define atsctrb_gtk_progress_bar_get_fraction gtk_progress_bar_get_fraction #define atsctrb_gtk_progress_bar_set_fraction gtk_progress_bar_set_fraction #define atsctrb_gtk_progress_bar_get_pulse_step gtk_progress_bar_get_pulse_step #define atsctrb_gtk_progress_bar_set_pulse_step gtk_progress_bar_set_pulse_step #define atsctrb_gtk_progress_bar_get_orientation gtk_progress_bar_get_orientation #define atsctrb_gtk_progress_bar_set_orientation gtk_progress_bar_set_orientation #define atsctrb_gtk_progress_bar_get_ellipsize gtk_progress_bar_get_ellipsize #define atsctrb_gtk_progress_bar_set_ellipsize gtk_progress_bar_set_ellipsize /* ****** ****** */ // // source: gtk/gtkradiobutton.h // ATSinline() ats_ptr_type atsctrb_gtk_radio_button_new (ats_ptr_type group) { GtkWidget *widget = gtk_radio_button_new ((GSList*)group) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_radio_button_new] ATSinline() ats_ptr_type atsctrb_gtk_radio_button_new_with_label (ats_ptr_type group, ats_ptr_type name) { GtkWidget *widget = gtk_radio_button_new_with_label ((GSList*)group, (gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_radio_button_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_radio_button_new_with_mnemonic (ats_ptr_type group, ats_ptr_type name) { GtkWidget *widget = gtk_radio_button_new_with_mnemonic ((GSList*)group, (gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_radio_button_new_with_mnemonic] ATSinline() ats_ptr_type atsctrb_gtk_radio_button_new_from_widget (ats_ptr_type member) { GtkWidget *widget = gtk_radio_button_new_from_widget ((GtkRadioButton*)member) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_radio_button_new_from_widget] ATSinline() ats_ptr_type atsctrb_gtk_radio_button_new_with_label_from_widget (ats_ptr_type member, ats_ptr_type name) { GtkWidget *widget = gtk_radio_button_new_with_label_from_widget ((GtkRadioButton*)member, (gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_radio_button_new_with_label_from_widget] #define atsctrb_gtk_radio_button_get_group gtk_radio_button_get_group #define atsctrb_gtk_radio_button_set_group gtk_radio_button_set_group /* ****** ****** */ // // source: gtk/gtkrange.h // #define atsctrb_gtk_range_get_adjustment gtk_range_get_adjustment #define atsctrb_gtk_range_set_adjustment gtk_range_set_adjustment #define atsctrb_gtk_range_set_update_policy gtk_range_set_update_policy /* ****** ****** */ // // source: gtk/gtkruler.h // #define atsctrb_gtk_ruler_set_metric gtk_ruler_set_metric #define atsctrb_gtk_ruler_set_range gtk_ruler_set_range /* ****** ****** */ // // source: gtk/gtkscale.h // #define atsctrb_gtk_scale_set_digits gtk_scale_set_digits #define atsctrb_gtk_scale_set_value_pos gtk_scale_set_value_pos #define atsctrb_gtk_scale_set_draw_value gtk_scale_set_draw_value /* ****** ****** */ // // source: gtk/gtkscrolledwindow.h // ATSinline() ats_ptr_type atsctrb_gtk_scrolled_window_new ( ats_ptr_type hadj, ats_ptr_type vadj ) { GtkWidget *widget = gtk_scrolled_window_new ((GtkAdjustment*)hadj, (GtkAdjustment*)vadj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_scrolled_window_new] ATSinline() ats_ptr_type atsctrb_gtk_scrolled_window_new_null () { return atsctrb_gtk_scrolled_window_new (NULL, NULL) ; } // end of [atsctrb_gtk_scrolled_window_new_null] #define atsctrb_gtk_scrolled_window_get_policy gtk_scrolled_window_get_policy #define atsctrb_gtk_scrolled_window_set_policy gtk_scrolled_window_set_policy #define atsctrb_gtk_scrolled_window_get_placement gtk_scrolled_window_get_placement #define atsctrb_gtk_scrolled_window_set_placement gtk_scrolled_window_set_placement /* ****** ****** */ // // source: gtk/gtkseparatormenuitem.h // ATSinline() ats_ptr_type atsctrb_gtk_separator_menu_item_new () { GtkWidget *widget = gtk_separator_menu_item_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_separator_menu_item_new] /* ****** ****** */ // // source: gtk/gtkseparatortoolitem.h // ATSinline() ats_ptr_type atsctrb_gtk_separator_tool_item_new () { GtkToolItem *item = gtk_separator_tool_item_new () ; g_object_ref_sink(G_OBJECT(item)) ; // removing floating reference! return item ; } // end of [atsctrb_gtk_separator_tool_item_new] /* ****** ****** */ // // source: gtk/gtkspinbutton.h // ATSinline() ats_ptr_type atsctrb_gtk_spin_button_new ( ats_ptr_type adj, gdouble rate, guint digits ) { GtkWidget *widget ; widget = gtk_spin_button_new ((GtkAdjustment*)adj, rate, digits) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_spin_button_new] #define atsctrb_gtk_spin_button_configure gtk_spin_button_configure #define atsctrb_gtk_spin_button_get_range gtk_spin_button_get_range #define atsctrb_gtk_spin_button_set_range gtk_spin_button_set_range #define atsctrb_gtk_spin_button_get_value gtk_spin_button_get_value #define atsctrb_gtk_spin_button_get_value_as_int gtk_spin_button_get_value_as_int #define atsctrb_gtk_spin_button_set_value gtk_spin_button_set_value #define atsctrb_gtk_spin_button_get_digits gtk_spin_button_get_digits #define atsctrb_gtk_spin_button_set_digits gtk_spin_button_set_digits #define atsctrb_gtk_spin_button_get_numeric gtk_spin_button_get_numeric #define atsctrb_gtk_spin_button_set_numeric gtk_spin_button_set_numeric #define atsctrb_gtk_spin_button_get_wrap gtk_spin_button_get_wrap #define atsctrb_gtk_spin_button_set_wrap gtk_spin_button_set_wrap #define atsctrb_gtk_spin_button_get_snap_to_ticks gtk_spin_button_get_snap_to_ticks #define atsctrb_gtk_spin_button_set_snap_to_ticks gtk_spin_button_set_snap_to_ticks #define atsctrb_gtk_spin_button_spin gtk_spin_button_spin #define atsctrb_gtk_spin_button_update gtk_spin_button_update /* ****** ****** */ // // source: gtk/gtkstatusbar.h // ATSinline() ats_ptr_type atsctrb_gtk_statusbar_new () { GtkWidget *widget = gtk_statusbar_new(); g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_statusbar_new] #define atsctrb_gtk_statusbar_push gtk_statusbar_push #define atsctrb_gtk_statusbar_pop gtk_statusbar_pop #define atsctrb_gtk_statusbar_remove gtk_statusbar_remove #define atsctrb_gtk_statusbar_get_context_id gtk_statusbar_get_context_id #define atsctrb_gtk_statusbar_get_has_resize_grip gtk_statusbar_get_has_resize_grip #define atsctrb_gtk_statusbar_set_has_resize_grip gtk_statusbar_set_has_resize_grip /* ****** ****** */ // // source: gtk/gtkstyle.h // ATSinline() ats_ptr_type atsctrb_gtk_style_get_text_aa (ats_ptr_type x) { return &((GtkStyle*)x)->text_aa ; } // end of [atsctrb_gtk_style_get_text_aa] ATSinline() ats_ptr_type atsctrb_gtk_style_get_font_desc (ats_ptr_type x) { return ((GtkStyle*)x)->font_desc ; } // end of [atsctrb_gtk_style_get_font_desc] #define atsctrb_gtk_style_new gtk_style_new #define atsctrb_gtk_style_copy gtk_style_copy #define atsctrb_gtk_style_attach gtk_style_attach #define atsctrb_gtk_style_detach gtk_style_detach /* ****** ****** */ // // source: gtk/gtktable.h // ATSinline() ats_ptr_type atsctrb_gtk_table_new ( guint rows, guint cols, gboolean homo ) { GtkWidget *widget = gtk_table_new (rows, cols, homo) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_table_new] #define atsctrb_gtk_table_attach gtk_table_attach #define atsctrb_gtk_table_attach_defaults gtk_table_attach_defaults #define atsctrb_gtk_table_resize gtk_table_resize #define atsctrb_gtk_table_set_row_spacing gtk_table_set_row_spacing #define atsctrb_gtk_table_set_col_spacing gtk_table_set_col_spacing #define atsctrb_gtk_table_set_row_spacings gtk_table_set_row_spacings #define atsctrb_gtk_table_set_col_spacings gtk_table_set_col_spacings /* ****** ****** */ // // source: gtk/gtktextbuffer.h // // // HX-2010-05-03: there is no floating reference involved // #define atsctrb_gtk_text_buffer_new_null() gtk_text_buffer_new(NULL) #define atsctrb_gtk_text_buffer_insert gtk_text_buffer_insert ATSinline() ats_void_type atsctrb_gtk_text_buffer_insertall ( ats_ptr_type tb, ats_ref_type iter, ats_ptr_type text ) { gtk_text_buffer_insert ( (GtkTextBuffer*)tb, (GtkTextIter*)iter, (gchar*)text, -1 ) ; return ; } // end of [atsctrb_gtk_text_buffer_insertall] // #define atsctrb_gtk_text_buffer_place_cursor gtk_text_buffer_place_cursor #define atsctrb_gtk_text_buffer_insert_at_cursor gtk_text_buffer_insert_at_cursor ATSinline() ats_void_type atsctrb_gtk_text_buffer_insertall_at_cursor ( ats_ptr_type tb, ats_ptr_type text ) { gtk_text_buffer_insert_at_cursor ((GtkTextBuffer*)tb, (gchar*)text, -1) ; return ; } // end of [atsctrb_gtk_text_buffer_insertall_at_cursor] // #define atsctrb_gtk_text_buffer_get_text gtk_text_buffer_get_text #define atsctrb_gtk_text_buffer_set_text gtk_text_buffer_set_text ATSinline() ats_void_type atsctrb_gtk_text_buffer_setall_text (ats_ptr_type tb, ats_ptr_type text) { gtk_text_buffer_set_text ((GtkTextBuffer*)tb, (gchar*)text, -1) ; return ; } // end of [atsctrb_gtk_text_buffer_setall_text] // #define atsctrb_gtk_text_buffer_get_iter_at_mark \ gtk_text_buffer_get_iter_at_mark #define atsctrb_gtk_text_buffer_get_iter_at_offset \ gtk_text_buffer_get_iter_at_offset #define atsctrb_gtk_text_buffer_delete gtk_text_buffer_delete #define atsctrb_gtk_text_buffer_get_start_iter gtk_text_buffer_get_start_iter #define atsctrb_gtk_text_buffer_get_end_iter gtk_text_buffer_get_end_iter #define atsctrb_gtk_text_buffer_get_bounds gtk_text_buffer_get_bounds #define atsctrb_gtk_text_buffer_get_insert gtk_text_buffer_get_insert #define atsctrb_gtk_text_buffer_get_modified gtk_text_buffer_get_modified #define atsctrb_gtk_text_buffer_set_modified gtk_text_buffer_set_modified #define atsctrb_gtk_text_buffer_cut_clipboard gtk_text_buffer_cut_clipboard #define atsctrb_gtk_text_buffer_copy_clipboard gtk_text_buffer_copy_clipboard #define atsctrb_gtk_text_buffer_paste_clipboard_at_cursor(tb, cb, editable) \ gtk_text_buffer_paste_clipboard(tb, cb, NULL, editable) #define atsctrb_gtk_text_buffer_get_selection_bounds \ gtk_text_buffer_get_selection_bounds #define atsctrb_gtk_text_buffer_get_selection_bounds_null(tb) \ gtk_text_buffer_get_selection_bounds (tb, NULL, NULL) /* ****** ****** */ // // source: gtk/gtktextiter.h // #define atsctrb_gtk_text_iter_is_start gtk_text_iter_is_start #define atsctrb_gtk_text_iter_is_end gtk_text_iter_is_end // #define atsctrb_gtk_text_iter_get_line gtk_text_iter_get_line #define atsctrb_gtk_text_iter_get_line_offset gtk_text_iter_get_line_offset // #define atsctrb_gtk_text_iter_forward_char gtk_text_iter_forward_char #define atsctrb_gtk_text_iter_backward_char gtk_text_iter_backward_char #define atsctrb_gtk_text_iter_forward_chars gtk_text_iter_forward_chars #define atsctrb_gtk_text_iter_backward_chars gtk_text_iter_backward_chars // #define atsctrb_gtk_text_iter_forward_line gtk_text_iter_forward_line #define atsctrb_gtk_text_iter_backward_line gtk_text_iter_backward_line #define atsctrb_gtk_text_iter_forward_lines gtk_text_iter_forward_lines #define atsctrb_gtk_text_iter_backward_lines gtk_text_iter_backward_lines /* ****** ****** */ // // source: gtk/gtktextview.h // ATSinline() ats_ptr_type atsctrb_gtk_text_view_new () { GtkWidget *widget = gtk_text_view_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_text_view_new] ATSinline() ats_ptr_type atsctrb_gtk_text_view_new_with_buffer (ats_ptr_type tb) { GtkWidget *widget = gtk_text_view_new_with_buffer ((GtkTextBuffer*)tb) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_text_view_new_with_buffer] #define atsctrb_gtk_text_view_get_buffer gtk_text_view_get_buffer #define atsctrb_gtk_text_view_set_buffer gtk_text_view_set_buffer #define atsctrb_gtk_text_view_get_wrap_mode gtk_text_view_get_wrap_mode #define atsctrb_gtk_text_view_set_wrap_mode gtk_text_view_set_wrap_mode #define atsctrb_gtk_text_view_get_editable gtk_text_view_get_editable #define atsctrb_gtk_text_view_set_editable gtk_text_view_set_editable #define atsctrb_gtk_text_view_get_cursor_visible gtk_text_view_get_cursor_visible #define atsctrb_gtk_text_view_set_cursor_visible gtk_text_view_set_cursor_visible #define atsctrb_gtk_text_view_get_overwrite gtk_text_view_get_overwrite #define atsctrb_gtk_text_view_set_overwrite gtk_text_view_set_overwrite #define atsctrb_gtk_text_view_get_justification gtk_text_view_get_justification #define atsctrb_gtk_text_view_set_justification gtk_text_view_set_justification #define atsctrb_gtk_text_view_get_left_margin gtk_text_view_get_left_margin #define atsctrb_gtk_text_view_set_left_margin gtk_text_view_set_left_margin #define atsctrb_gtk_text_view_get_right_margin gtk_text_view_get_right_margin #define atsctrb_gtk_text_view_set_right_margin gtk_text_view_set_right_margin #define atsctrb_gtk_text_view_get_window gtk_text_view_get_window #define atsctrb_gtk_text_view_get_border_window_size \ gtk_text_view_get_border_window_size #define atsctrb_gtk_text_view_set_border_window_size \ gtk_text_view_set_border_window_size #define atsctrb_gtk_text_view_get_line_at_y gtk_text_view_get_line_at_y #define atsctrb_gtk_text_view_get_line_yrange gtk_text_view_get_line_yrange #define atsctrb_gtk_text_view_window_to_buffer_coords \ gtk_text_view_window_to_buffer_coords #define atsctrb_gtk_text_view_buffer_to_window_coords \ gtk_text_view_buffer_to_window_coords /* ****** ****** */ // // source: gtk/gtktogglebutton.h // ATSinline() ats_ptr_type atsctrb_gtk_toggle_button_new () { GtkWidget *widget = gtk_toggle_button_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_toggle_button_new] ATSinline() ats_ptr_type atsctrb_gtk_toggle_button_new_with_label (ats_ptr_type name) { GtkWidget *widget = gtk_toggle_button_new_with_label ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_toggle_button_new_with_label] ATSinline() ats_ptr_type atsctrb_gtk_toggle_button_new_with_mnemonic (ats_ptr_type name) { GtkWidget *widget = gtk_toggle_button_new_with_mnemonic ((gchar*)name) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [gtk_toggle_button_new_with_mnemonic] #define atsctrb_gtk_toggle_button_get_active gtk_toggle_button_get_active #define atsctrb_gtk_toggle_button_set_active gtk_toggle_button_set_active /* ****** ****** */ // // source: gtk/gtktoolbar.h // ATSinline() ats_ptr_type atsctrb_gtk_toolbar_new () { GtkWidget *widget = gtk_toolbar_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_toolbar_new] #define atsctrb_gtk_toolbar_get_style gtk_toolbar_get_style #define atsctrb_gtk_toolbar_set_style gtk_toolbar_set_style #define atsctrb_gtk_toolbar_insert gtk_toolbar_insert /* ****** ****** */ // // source: gtk/gtktoolbutton.h // ATSinline() ats_ptr_type atsctrb_gtk_tool_button_new_from_stock (ats_ptr_type stock_id) { GtkToolItem *item = gtk_tool_button_new_from_stock (stock_id) ; g_object_ref_sink(G_OBJECT(item)) ; // removing floating reference! return item ; } // end of [atsctrb_gtk_tool_button_new_from_stock] /* ****** ****** */ // // source: gtk/gtkvbox.h // ATSinline() ats_ptr_type atsctrb_gtk_vbox_new ( gboolean homo, gint spacing ) { GtkWidget *widget = gtk_vbox_new (homo, spacing) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vbox_new] /* ****** ****** */ // // source: gtk/gtkvpaned.h // ATSinline() ats_ptr_type atsctrb_gtk_vpaned_new () { GtkWidget *widget = gtk_vpaned_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vpaned_new] /* ****** ****** */ // // source: gtk/gtkvruler.h // ATSinline() ats_ptr_type atsctrb_gtk_vruler_new () { GtkWidget *widget = gtk_vruler_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vruler_new] /* ****** ****** */ // // source: gtk/gtkvscale.h // ATSinline() ats_ptr_type atsctrb_gtk_vscale_new (ats_ptr_type adj) { GtkWidget *widget = gtk_vscale_new ((GtkAdjustment*)adj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vscale_new] ATSinline() ats_ptr_type atsctrb_gtk_vscale_new_with_range (gdouble min, gdouble max, gdouble step) { GtkWidget *widget = gtk_vscale_new_with_range (min, max, step) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vscale_new_with_range] /* ****** ****** */ // // source: gtk/gtkvsrollbar.h // ATSinline() ats_ptr_type atsctrb_gtk_vscrollbar_new (ats_ptr_type adj) { GtkWidget *widget = gtk_vscrollbar_new ((GtkAdjustment*)adj) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vscrollbar_new] /* ****** ****** */ // // source: gtk/gtkvseparator.h // ATSinline() ats_ptr_type atsctrb_gtk_vseparator_new () { GtkWidget *widget = gtk_vseparator_new () ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! return widget ; } // end of [atsctrb_gtk_vseparator_new] /* ****** ****** */ // // source: gtk/gtkwidget.h // #define atsctrb_GTK_WIDGET_SET_FLAGS GTK_WIDGET_SET_FLAGS // #define atsctrb_GTK_WIDGET_STATE GTK_WIDGET_STATE #define atsctrb_GTK_WIDGET_SAVED_STATE GTK_WIDGET_SAVED_STATE // #define atsctrb_gtk_widget_destroy gtk_widget_destroy // #define atsctrb_gtk_widget_map gtk_widget_map #define atsctrb_gtk_widget_unmap gtk_widget_unmap // #define atsctrb_gtk_widget_realize gtk_widget_realize #define atsctrb_gtk_widget_unrealize gtk_widget_unrealize // #define atsctrb_gtk_widget_show gtk_widget_show #define atsctrb_gtk_widget_show_now gtk_widget_show_now #define atsctrb_gtk_widget_show_all gtk_widget_show_all // #define atsctrb_gtk_widget_hide gtk_widget_hide // #define atsctrb_gtk_widget_get_sensitive gtk_widget_get_sensitive #define atsctrb_gtk_widget_set_sensitive gtk_widget_set_sensitive // // HX: get out of a GDK window // ATSinline() ats_ptr_type atsctrb_gtk_widget_get_window (ats_ptr_type widget) { return (GTK_WIDGET(widget))->window ; } // end of [atsctrb_gtk_widget_get_window] ATSinline() ats_ptr_type atsctrb_gtk_widget_getref_allocation (ats_ptr_type widget) { return &(GTK_WIDGET(widget))->allocation ; } // end of [atsctrb_gtk_widget_get_allocation] #define atsctrb_gtk_widget_get_allocation gtk_widget_get_allocation #define atsctrb_gtk_widget_set_allocation gtk_widget_set_allocation // #define atsctrb_gtk_widget_set_size_request gtk_widget_set_size_request // #define atsctrb_gtk_widget_grab_focus gtk_widget_grab_focus #define atsctrb_gtk_widget_grab_default gtk_widget_grab_default // #define atsctrb_gtk_widget_set_events gtk_widget_set_events // #define atsctrb_gtk_widget_add_accelerator gtk_widget_add_accelerator #define atsctrb_gtk_widget_remove_accelerator gtk_widget_remove_accelerator // #define atsctrb_gtk_widget_modify_fg gtk_widget_modify_fg #define atsctrb_gtk_widget_modify_bg gtk_widget_modify_bg // #define atsctrb_gtk_widget_get_toplevel gtk_widget_get_toplevel // #define atsctrb_gtk_widget_get_colormap gtk_widget_get_colormap #define atsctrb_gtk_widget_modify_font gtk_widget_modify_font // #define atsctrb_gtk_widget_queue_draw_area gtk_widget_queue_draw_area // #define atsctrb_gtk_widget_create_pango_context gtk_widget_create_pango_context #define atsctrb_gtk_widget_get_pango_context gtk_widget_get_pango_context // #define atsctrb_gtk_widget_create_pango_layout gtk_widget_create_pango_layout // #define atsctrb_gtk_widget_get_style gtk_widget_get_style #define atsctrb_gtk_widget_set_style gtk_widget_set_style /* ****** ****** */ // // source: gtk/gtkwindow.h // #define atsctrb_GTK_IS_WINDOW GTK_IS_WINDOW ATSinline() ats_ptr_type atsctrb_gtk_window_new (GtkWindowType window_type) { GtkWidget *widget = gtk_window_new (window_type) ; g_object_ref_sink(G_OBJECT(widget)) ; // removing floating reference! /* ** the ref-count of the created window is 2! */ return widget ; } // end of [atsctrb_gtk_window_new] #define atsctrb_gtk_window_get_title gtk_window_get_title #define atsctrb_gtk_window_set_title gtk_window_set_title #define atsctrb_gtk_window_set_position gtk_window_set_position #define atsctrb_gtk_window_get_transient_for gtk_window_get_transient_for #define atsctrb_gtk_window_set_transient_for gtk_window_set_transient_for #define atsctrb_gtk_window_get_size gtk_window_get_size #define atsctrb_gtk_window_set_default_size gtk_window_set_default_size #define atsctrb_gtk_window_get_resizable gtk_window_get_resizable #define atsctrb_gtk_window_set_resizable gtk_window_set_resizable #define atsctrb_gtk_window_add_accel_group gtk_window_add_accel_group #define atsctrb_gtk_window_remove_accel_group gtk_window_remove_accel_group #define atsctrb_gtk_window_get_window_type gtk_window_get_window_type #define atsctrb_gtk_window_get_type_hint gtk_window_get_type_hint #define atsctrb_gtk_window_move gtk_window_move #define atsctrb_gtk_window_reshow_with_initial_size \ gtk_window_reshow_with_initial_size #define atsctrb_gtk_window_resize gtk_window_resize #define atsctrb_gtk_window_get_opacity gtk_window_get_opacity #define atsctrb_gtk_window_set_opacity gtk_window_set_opacity #define atsctrb_gtk_window_get_mnemonics_visible gtk_window_get_mnemonics_visible #define atsctrb_gtk_window_set_mnemonics_visible gtk_window_set_mnemonics_visible /* ****** ****** */ // // source: gtk/gtkmain.h // #define atsctrb_gtk_main gtk_main #define atsctrb_gtk_main_level gtk_main_level #define atsctrb_gtk_main_quit gtk_main_quit #define atsctrb_gtk_timeout_add gtk_timeout_add /* ****** ****** */ #endif // end of [ATSCTRB_GTK_GTK_CATS] /* end of [gtk.cats] */ ats-lang-anairiats-0.2.11/contrib/GTK/SATS/0000700000175000017500000000000012223166165016623 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/0000700000175000017500000000000012223166165017410 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhruler.sats0000664000175000017500000000316012223166165022327 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hruler_new (): GtkHRuler_ref1 = "mac#atsctrb_gtk_hruler_new" // end of [gtk_hruler_new] (* ****** ****** *) (* end of [gtkhruler.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvpaned.sats0000664000175000017500000000316012223166165022303 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vpaned_new (): GtkVPaned_ref1 = "mac#atsctrb_gtk_vpaned_new" // end of [gtk_vpaned_new] (* ****** ****** *) (* end of [gtkvpaned.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktable.sats0000664000175000017500000001052012223166165022113 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_table_new ( nrow: guint , ncol: guint , homo: gboolean ) : GtkTable_ref1 = "mac#atsctrb_gtk_table_new" // end of [gtk_table_new] (* ****** ****** *) fun lor_GtkAttachOptions_GtkAttachOptions (x1: GtkAttachOptions, x2: GtkAttachOptions):<> GtkAttachOptions = "atsctrb_lor_GtkAttachOptions_GtkAttachOptions" overload lor with lor_GtkAttachOptions_GtkAttachOptions (* ****** ****** *) symintr gtk_table_attach typedef gtk_table_attach_type (a:t@ype) = {c1,c2:cls | c1 <= GtkTable; c2 <= GtkWidget} {l1,l2:agz} ( !gobjref (c1, l1) // table , !gobjref (c2, l2) // widget , a // left , a // right , a // top , a // bot , GtkAttachOptions // xopt , GtkAttachOptions // yopt , a // xpadding , a // ypadding ) - void // end of [gtk_table_attach_type] fun gtk_table_attach__type : gtk_table_attach_type (uint) = "mac#atsctrb_gtk_table_attach" overload gtk_table_attach with gtk_table_attach__type fun gtk_table_attach__gtype : gtk_table_attach_type (guint) = "mac#atsctrb_gtk_table_attach" overload gtk_table_attach with gtk_table_attach__gtype (* ****** ****** *) symintr gtk_table_attach_defaults typedef gtk_table_attach_defaults_type (a:t@ype) = {c1,c2:cls | c1 <= GtkTable; c2 <= GtkWidget} {l1,l2:agz} ( !gobjref (c1, l1) // table , !gobjref (c2, l2) // widget , a // left , a // right , a // top , a // bot ) - void // end of [gtk_table_attach_defaults_type] fun gtk_table_attach_defaults__type : gtk_table_attach_defaults_type (uint) = "mac#atsctrb_gtk_table_attach_defaults" overload gtk_table_attach_defaults with gtk_table_attach_defaults__type fun gtk_table_attach_defaults__gtype : gtk_table_attach_defaults_type (guint) = "mac#atsctrb_gtk_table_attach_defaults" overload gtk_table_attach_defaults with gtk_table_attach_defaults__gtype (* ****** ****** *) fun gtk_table_resize {c:cls | c <= GtkTable} {l:addr} ( table: !gobjref (c, l), nrow: guint, ncol: guint ) : void = "mac#atsctrb_gtk_table_resize" // end of [gtk_table_resize] (* ****** ****** *) fun gtk_table_set_row_spacing {c:cls | c <= GtkTable} {l:addr} (table: !gobjref (c, l), row: guint, spacing: guint): void = "mac#atsctrb_gtk_table_set_row_spacing" // end of [gtk_table_set_row_spacing] fun gtk_table_set_col_spacing {c:cls | c <= GtkTable} {l:addr} (table: !gobjref (c, l), col: guint, spacing: guint): void = "mac#atsctrb_gtk_table_set_col_spacing" // end of [gtk_table_set_col_spacing] (* ****** ****** *) fun gtk_table_set_row_spacings {c:cls | c <= GtkTable} {l:addr} ( table: !gobjref (c, l), spacing: guint ) : void = "mac#atsctrb_gtk_table_set_row_spacings" // end of [gtk_table_set_row_spacings] fun gtk_table_set_col_spacings {c:cls | c <= GtkTable} {l:addr} ( table: !gobjref (c, l), spacing: guint ) : void = "mac#atsctrb_gtk_table_set_col_spacings" // end of [gtk_table_set_col_spacings] (* ****** ****** *) (* end of [gtktable.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkarrow.sats0000664000175000017500000000356012223166165022164 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_arrow_new ( arrow_type: GtkArrowType, shadow_type: GtkShadowType ) : GtkArrow_ref1 = "mac#atsctrb_gtk_arrow_new" // end of [gtk_arrow_new] fun gtk_arrow_set {c:cls | c <= GtkArrow} {l:agz} ( arrow: !gobjref (c, l) , arrow_type: GtkArrowType, shadow_type: GtkShadowType ) : void = "mac#atsctrb_gtk_arrow_set" // end of [gtk_arrow_set] (* ****** ****** *) (* end of [gtkarrow.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmenu.sats0000664000175000017500000000351112223166165021772 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_menu_new (): GtkMenu_ref1 = "mac#atsctrb_gtk_menu_new" // end of [gtk_menu_new] (* ****** ****** *) fun gtk_menu_popup_null {c:cls | c <= GtkMenu} {l:agz} ( menu: !gobjref (c, l) , button: guint , activate_time: guint32 ) : void = "mac#atsctrb_gtk_menu_popup_null" // end of [gtk_menu_popup_null] (* ****** ****** *) (* end of [gtkmenu.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktoolbar.sats0000664000175000017500000000503212223166165022470 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abst@ype GtkToolbarSpaceStyle = $extype"GtkToolbarSpaceStyle" macdef GTK_TOOLBAR_SPACE_EMPTY = $extval (GtkToolbarSpaceStyle, "GTK_TOOLBAR_SPACE_EMPTY") macdef GTK_TOOLBAR_SPACE_LINE = $extval (GtkToolbarSpaceStyle, "GTK_TOOLBAR_SPACE_LINE") (* ****** ****** *) fun gtk_toolbar_new (): GtkToolbar_ref1 = "mac#atsctrb_gtk_toolbar_new" // end of [gtk_toolbar_new] (* ****** ****** *) fun gtk_toolbar_get_style {c:cls | c <= GtkToolbar} {l:agz} ( toolbar: !gobjref (c, l) ) : GtkToolbarStyle = "mac#atsctrb_gtk_toolbar_get_style" // end of [gtk_toolbar_get_style] fun gtk_toolbar_set_style {c:cls | c <= GtkToolbar} {l:agz} ( toolbar: !gobjref (c, l), style: GtkToolbarStyle ) : void = "mac#atsctrb_gtk_toolbar_set_style" // end of [gtk_toolbar_set_style] (* ****** ****** *) fun gtk_toolbar_insert {c1,c2:cls | c1 <= GtkToolbar; c2 <= GtkToolItem} {l1,l2:agz} ( bar: !gobjref (c1, l1) , itm: !gobjref (c2, l2) , position: gint ) : void = "mac#atsctrb_gtk_toolbar_insert" // end of [gtk_toolbar_insert] (* ****** ****** *) (* end of [gtktoolbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkalignment.sats0000664000175000017500000000715412223166165023013 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) symintr gtk_alignment_new typedef gtk_alignment_new_type (a:t@ype) = ( a // xalign , a // yalign , a // xscale , a // yscale ) - GtkAlignment_ref1 fun gtk_alignment_new__type : gtk_alignment_new_type float = "mac#atsctrb_gtk_alignment_new" overload gtk_alignment_new with gtk_alignment_new__type fun gtk_alignment_new__gtype : gtk_alignment_new_type gfloat = "mac#atsctrb_gtk_alignment_new" overload gtk_alignment_new with gtk_alignment_new__gtype (* ****** ****** *) symintr gtk_alignment_set typedef gtk_alignment_set_type (a:t@ype) = ( a // xalign , a // yalign , a // xscale , a // yscale ) - void fun gtk_alignment_set__type : gtk_alignment_set_type float = "mac#atsctrb_gtk_alignment_set" overload gtk_alignment_set with gtk_alignment_set__type fun gtk_alignment_set__gtype : gtk_alignment_set_type gfloat = "mac#atsctrb_gtk_alignment_set" overload gtk_alignment_set with gtk_alignment_set__gtype (* ****** ****** *) symintr gtk_alignment_get_padding typedef gtk_alignment_get_padding_type (a:t@ype) = ( &a? >> a // xalign , &a? >> a // yalign , &a? >> a // xscale , &a? >> a // yscale ) - void fun gtk_alignment_get_padding__type : gtk_alignment_get_padding_type uint = "mac#atsctrb_gtk_alignment_get_padding" overload gtk_alignment_get_padding with gtk_alignment_get_padding__type fun gtk_alignment_get_padding__gtype : gtk_alignment_get_padding_type guint = "mac#atsctrb_gtk_alignment_get_padding" overload gtk_alignment_get_padding with gtk_alignment_get_padding__gtype (* ****** ****** *) symintr gtk_alignment_set_padding typedef gtk_alignment_set_padding_type (a:t@ype) = ( &a // xalign , &a // yalign , &a // xscale , &a // yscale ) - void // end of [typedef] fun gtk_alignment_set_padding__type : gtk_alignment_set_padding_type uint = "mac#atsctrb_gtk_alignment_set_padding" overload gtk_alignment_set_padding with gtk_alignment_set_padding__type fun gtk_alignment_set_padding__gtype : gtk_alignment_set_padding_type guint = "mac#atsctrb_gtk_alignment_set_padding" overload gtk_alignment_set_padding with gtk_alignment_set_padding__gtype (* ****** ****** *) (* end of [gtkalignment.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhseparator.sats0000664000175000017500000000320412223166165023175 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hseparator_new (): GtkHSeparator_ref1 = "mac#atsctrb_gtk_hseparator_new" // end of [gtk_hseparator_new] (* ****** ****** *) (* end of [gtkhseparator.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvscale.sats0000664000175000017500000000361612223166165022311 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vscale_new {c:cls | c <= GtkAdjustment} {l:agz} ( adj: !gobjref (c, l) ) : GtkVScale_ref1 = "mac#atsctrb_gtk_vscale_new" // end of [gtk_vscale_new] fun gtk_vscale_new_with_range {c:cls | c <= GtkAdjustment} {l:agz} ( min: gdouble, max: gdouble, step: gdouble ) : GtkVScale_ref1 = "mac#atsctrb_gtk_vscale_new_with_range" // end of [gtk_vscale_new_with_rangle] (* ****** ****** *) (* end of [gtkvscale.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkframe.sats0000664000175000017500000000740512223166165022126 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_frame_new {l:addr} (name: !gstring l): GtkFrame_ref1 = "mac#atsctrb_gtk_frame_new" // end of [gtk_frame_new] // // HX-2010-04-15: this is just gtk_frame_new (NULL) // fun gtk_frame_new_null (): GtkFrame_ref1 = "mac#atsctrb_gtk_frame_new_null" // end of [gtk_frame_new_null] (* ****** ****** *) // // HX-2010-05-08: checked: gstring is shared; it is not copied out // fun gtk_frame_get_label {c:cls | c <= GtkFrame} {l1:agz} ( frame: !gobjref (c, l1) ) : [l2:addr] ( minus (gobjref (c, l1), gstring l2) | gstring l2 ) = "mac#atsctrb_gtk_frame_get_label" // end of [gtk_frame_get_label] fun gtk_frame_set_label {c:cls | c <= GtkFrame} {l1,l2:agz} ( frame: !gobjref (c, l1), name: !gstring l2 ) : void = "mac#atsctrb_gtk_frame_set_label" // end of [gtk_frame_set_label] (* ****** ****** *) fun gtk_frame_get_label_align {c:cls | c <= GtkFrame} {l:agz} ( frame: !gobjref (c, l), x: &gfloat? >> gfloat, y: &gfloat >> gfloat ) : void = "mac#atsctrb_gtk_frame_get_label_align" // end of [gtk_frame_get_label_align] fun gtk_frame_set_label_align {c:cls | c <= GtkFrame} {l1,l2:agz} (frame: !gobjref (c, l1), name: !gstring l2, x: gfloat, y: gfloat): void = "mac#atsctrb_gtk_frame_set_label_align" // end of [gtk_frame_set_label_align] (* ****** ****** *) // // HX-2010-05-08: checked: reference count is unchanged // fun gtk_frame_get_label_widget {c:cls | c <= GtkFrame} {l1:agz} ( frame: !gobjref (c, l1) ) : [l2:addr] ( minus (gobjref (c, l1), gobjref (GtkLabel, l2)) | gobjref (GtkLabel, l2) ) = "mac#atsctrb_gtk_frame_get_label_widget" // end of [gtk_frame_get_label_widget] fun gtk_frame_set_label_widget {c1,c2:cls | c1 <= GtkFrame; c2 <= GtkWidget} {l1,l2:agz} ( frame: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_frame_set_label_widget" // end of [gtk_frame_set_label_widget] (* ****** ****** *) fun gtk_frame_get_shadow_type {c:cls | c <= GtkFrame} {l:agz} ( frame: !gobjref (c, l) ) : GtkShadowType = "mac#atsctrb_gtk_frame_set_shadow_type" // end of [gtk_frame_get_shadow_type] fun gtk_frame_set_shadow_type {c:cls | c <= GtkFrame} {l:agz} ( frame: !gobjref (c, l), _type: GtkShadowType ) : void = "mac#atsctrb_gtk_frame_set_shadow_type" // end of [gtk_frame_set_shadow_type] (* ****** ****** *) (* end of [gtkframe.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtklabel.sats0000664000175000017500000000545612223166165022117 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_label_new {l:agz} ( name: !gstring l ) : GtkLabel_ref1 = "mac#atsctrb_gtk_label_new" // end of [gtk_label_new] (* ****** ****** *) fun gtk_label_get_text {c:cls | c <= GtkLabel} {l1:agz} ( label: !gobjref (c, l1) ) : [l2:addr] ( minus (gobjref (c, l1), gstring l2) | gstring l2 ) = "mac#atsctrb_gtk_label_get_text" fun gtk_label_set_text {c:cls | c <= GtkLabel} {l1,l2:agz} ( label: !gobjref (c, l1), name: !gstring l2 ) : void = "mac#atsctrb_gtk_label_set_text" // end of [fun] (* ****** ****** *) fun gtk_label_get_justify {c:cls | c <= GtkLabel} {l:agz} ( label: !gobjref (c, l) ) : GtkJustification = "mac#atsctrb_gtk_label_get_justify" // end of [gtk_label_get_justify] fun gtk_label_set_justify {c:cls | c <= GtkLabel} {l:agz} ( label: !gobjref (c, l), jtype: GtkJustification ) : void = "mac#atsctrb_gtk_label_set_justify" // end of [gtk_label_set_justify] (* ****** ****** *) fun gtk_label_get_line_wrap {c:cls | c <= GtkLabel} {l:agz} ( label: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_label_get_line_wrap" // end of [gtk_label_get_line_wrap] fun gtk_label_set_line_wrap {c:cls | c <= GtkLabel} {l:agz} ( label: !gobjref (c, l), wrap: gboolean ) : void = "mac#atsctrb_gtk_label_set_line_wrap" // end of [gtk_label_set_line_wrap] (* ****** ****** *) (* end of [gtklabel.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkscale.sats0000664000175000017500000000403712223166165022121 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_scale_set_draw_value {c:cls | c <= GtkScale} {l:agz} ( scale: !gobjref (c, l), draw_value: gboolean ) : void = "mac#atsctrb_gtk_scale_set_draw_value" // end of [fun] fun gtk_scale_set_digits {c:cls | c <= GtkScale} {l:agz} ( scale: !gobjref (c, l), digits: gint ) : void = "mac#atsctrb_gtk_scale_set_digits" // end of [fun] fun gtk_scale_set_value_pos {c:cls | c <= GtkScale} {l:agz} ( scale: !gobjref (c, l), pos: GtkPositionType ) : void = "mac#atsctrb_gtk_scale_set_value_pos" // end of [fun] (* ****** ****** *) (* end of [gtkscale.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkseparator.sats0000664000175000017500000000304612223166165023031 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) // it is still empty (* ****** ****** *) (* end of [gtkseparator.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktogglebutton.sats0000664000175000017500000000472712223166165023555 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_toggle_button_new (): GtkToggleButton_ref1 = "mac#atsctrb_gtk_toggle_button_new" // end of [gtk_toggle_button_new] fun gtk_toggle_button_new_with_label {l:agz} ( name: !gstring l ) : GtkToggleButton_ref1 = "mac#atsctrb_gtk_toggle_button_new_with_label" // end of [gtk_toggle_button_new_with_label] fun gtk_toggle_button_new_with_mnemonic {l:agz} ( name: !gstring l ) : GtkToggleButton_ref1 = "mac#atsctrb_gtk_toggle_button_new_with_mnemonic" // end of [gtk_toggle_button_new_with_mnemonic] (* ****** ****** *) fun gtk_toggle_button_get_active {c:cls | c <= GtkToggleButton} {l:agz} ( button: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_toggle_button_get_active" // end of [gtk_toggle_button_get_active] fun gtk_toggle_button_set_active {c:cls | c <= GtkToggleButton} {l:agz} ( button: !gobjref (c, l), isactive: gboolean ) : void = "mac#atsctrb_gtk_toggle_button_set_active" // end of [gtk_toggle_button_set_active] (* ****** ****** *) (* end of [gtktogglebutton.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkcheckmenuitem.sats0000664000175000017500000000721412223166165023653 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gtk_check_menu_item_new (): GtkCheckMenuItem_ref1 = "mac#atsctrb_gtk_check_menu_item_new" // end of [gtk_check_menu_item_new] fun gtk_check_menu_item_new_with_label {l:agz} (name: !gstring l): GtkCheckMenuItem_ref1 = "mac#atsctrb_gtk_check_menu_item_new_with_label" // end of [gtk_check_menu_item_new_with_label] fun gtk_check_menu_item_new_with_mnemonic {l:agz} (name: !gstring l): GtkCheckMenuItem_ref1 = "mac#atsctrb_gtk_check_menu_item_new_with_mnemonic" // end of [gtk_check_menu_item_new_with_mnemonic] (* ****** ****** *) fun gtk_check_menu_item_get_active {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_check_menu_item_get_active" // end of [gtk_check_menu_item_get_active] fun gtk_check_menu_item_set_active {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l), active: gboolean): void = "mac#atsctrb_gtk_check_menu_item_set_active" // end of [gtk_check_menu_item_set_active] (* ****** ****** *) fun gtk_check_menu_item_toggled {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l)): void = "mac#atsctrb_gtk_check_menu_item_toggled" // end of [gtk_check_menu_item_toggled] (* ****** ****** *) fun gtk_check_menu_item_get_inconsistent {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_check_menu_item_get_inconsistent" // end of [gtk_check_menu_item_get_inconsistent] fun gtk_check_menu_item_set_inconsistent {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l), inconsistent: gboolean): void = "mac#atsctrb_gtk_check_menu_item_set_inconsistent" // end of [gtk_check_menu_item_set_inconsistent] (* ****** ****** *) fun gtk_check_menu_item_get_draw_as_radio {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_check_menu_item_get_draw_as_radio" // end of [gtk_check_menu_item_get_draw_as_radio] fun gtk_check_menu_item_set_draw_as_radio {c:cls | c <= GtkCheckMenuItem} {l:agz} (item: !gobjref (c, l), draw_as_radio: gboolean): void = "mac#atsctrb_gtk_check_menu_item_set_draw_as_radio" // end of [gtk_check_menu_item_set_draw_as_radio] (* ****** ****** *) (* end of [gtkcheckmenuitem.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmenuitem.sats0000664000175000017500000000537412223166165022662 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_menu_item_new (): GtkMenuItem_ref1 = "mac#atsctrb_gtk_menu_item_new" // end of [gtk_menu_item_new] fun gtk_menu_item_new_with_label {l:agz} (name: !gstring l): GtkMenuItem_ref1 = "mac#atsctrb_gtk_menu_item_new_with_label" // end of [gtk_menu_item_new_with_label] fun gtk_menu_item_new_with_mnemonic {l:agz} (name: !gstring l): GtkMenuItem_ref1 = "mac#atsctrb_gtk_menu_item_new_with_mnemonic" // end of [gtk_menu_item_new_with_mnemonic] (* ****** ****** *) // // HX-2010-05-06: the returned gstring can be NULL! // fun gtk_menu_item_get_label {c:cls | c <= GtkMenuItem} {l:agz} ( item: !gobjref (c, l) ) : [l1:addr] ( minus (gobjref (c, l), gstring l1) | gstring l1 ) = "mac#atsctrb_gtk_menu_item_get_label" // end of [gtk_menu_item_get_label] fun gtk_menu_item_set_label {c:cls | c <= GtkMenuItem} {l1,l2:agz} ( item: !gobjref (c, l1), name: !gstring l2 ) : void = "mac#atsctrb_gtk_menu_item_set_label" // end of [gtk_menu_item_set_label] (* ****** ****** *) fun gtk_menu_item_set_submenu {c1,c2:cls | c1 <= GtkMenuItem; c2 <= GtkWidget} {l1,l2:addr | l2 > null} ( menuitem: !gobjref (c1, l1) , submenu: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_menu_item_set_submenu" // end of [gtk_menu_item_set_submenu] (* ****** ****** *) (* end of [gtkmenuitem.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvseparator.sats0000664000175000017500000000320412223166165023213 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vseparator_new (): GtkVSeparator_ref1 = "mac#atsctrb_gtk_vseparator_new" // end of [gtk_vseparator_new] (* ****** ****** *) (* end of [gtkvseparator.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkscrollbar.sats0000664000175000017500000000304612223166165023014 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) // it is still empty (* ****** ****** *) (* end of [gtkscrollbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkcolorsel.sats0000664000175000017500000001036212223166165022652 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) fun gtk_color_selection_new (): GtkColorSelection_ref1 = "mac#atsctrb_gtk_color_selection_new" // end of [gtk_color_selection_new] (* ****** ****** *) fun gtk_color_selection_set_has_palette {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), has_palette: gboolean): void = "mac#atsctrb_gtk_color_selection_set_has_palette" // end of [gtk_color_selection_set_has_palette] (* ****** ****** *) fun gtk_color_selection_set_has_opacitiy_control {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), has_opacity: gboolean): void = "mac#atsctrb_gtk_color_selection_set_has_opacitiy_control" // end of [gtk_color_selection_set_has_opacitiy_control] (* ****** ****** *) fun gtk_color_selection_get_previous_color {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), color: &GdkColor? >> GdkColor): void = "mac#atsctrb_gtk_color_selection_get_previous_color" // end of [gtk_color_selection_get_previous_color] fun gtk_color_selection_set_previous_color {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), color: &GdkColor): void = "mac#atsctrb_gtk_color_selection_set_previous_color" // end of [gtk_color_selection_set_previous_color] (* ****** ****** *) fun gtk_color_selection_get_current_color {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), color: &GdkColor? >> GdkColor): void = "mac#atsctrb_gtk_color_selection_get_current_color" // end of [gtk_color_selection_get_current_color] fun gtk_color_selection_set_current_color {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), color: &GdkColor): void = "mac#atsctrb_gtk_color_selection_set_current_color" // end of [gtk_color_selection_set_current_color] (* ****** ****** *) fun gtk_color_selection_get_previous_alpha {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), alpha: &guint16? >> guint16): void = "mac#atsctrb_gtk_color_selection_get_previous_alpha" // end of [gtk_color_selection_get_previous_alpha] fun gtk_color_selection_set_previous_alpha {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), alpha: guint16): void = "mac#atsctrb_gtk_color_selection_set_previous_alpha" // end of [gtk_color_selection_set_previous_alpha] (* ****** ****** *) fun gtk_color_selection_get_current_alpha {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), alpha: &guint16? >> guint16): void = "mac#atsctrb_gtk_color_selection_get_current_alpha" // end of [gtk_color_selection_get_current_alpha] fun gtk_color_selection_set_current_alpha {c:cls | c <= GtkColorSelection} {l:agz} (dialog: !gobjref (c, l), alpha: guint16): void = "mac#atsctrb_gtk_color_selection_set_current_alpha" // end of [gtk_color_selection_set_current_alpha] (* ****** ****** *) (* end of [gtkcolorsel.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkruler.sats0000664000175000017500000000444612223166165022167 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_ruler_set_metric {c:cls | c <= GtkRuler} {l:agz} ( ruler: !gobjref (c, l), metric: GtkMetricType ) : void = "mac#atsctrb_gtk_ruler_set_metric" // end of [gtk_ruler_set_metric] (* ****** ****** *) typedef gtk_ruler_set_range_type (a:t@ype) = {c:cls | c <= GtkRuler} {l:agz} ( !gobjref (c, l) , a // lower , a // upper , a // position , a // max_size ) - void // end of [gtk_ruler_set_range_type] symintr gtk_ruler_set_range fun gtk_ruler_set_range__type : gtk_ruler_set_range_type (double) = "mac#atsctrb_gtk_ruler_set_range" overload gtk_ruler_set_range with gtk_ruler_set_range__type fun gtk_ruler_set_range__gtype : gtk_ruler_set_range_type (gdouble) = "mac#atsctrb_gtk_ruler_set_range" overload gtk_ruler_set_range with gtk_ruler_set_range__gtype (* ****** ****** *) (* end of [gtkruler.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkcolorseldialog.sats0000664000175000017500000000403312223166165024030 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) fun gtk_color_selection_dialog_new {l:agz} ( title: !gstring l ) : GtkColorSelectionDialog_ref1 = "mac#atsctrb_gtk_color_selection_dialog_new" // end of [gtk_color_selection_dialog_new] (* ****** ****** *) fun gtk_color_selection_dialog_get_colorsel {c:cls | c <= GtkColorSelectionDialog} {l:agz} ( dialog: !gobjref (c, l) ) : [l_sel:agz] ( minus (gobjref (c, l), gobjref (GtkColorSelection, l_sel)) | gobjref (GtkColorSelection, l_sel) ) = "mac#atsctrb_gtk_color_selection_dialog_get_colorsel" (* ****** ****** *) (* end of [gtkcolorseldialog.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhpaned.sats0000664000175000017500000000316012223166165022265 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hpaned_new (): GtkHPaned_ref1 = "mac#atsctrb_gtk_hpaned_new" // end of [gtk_hpaned_new] (* ****** ****** *) (* end of [gtkhpaned.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkfilesel.sats0000664000175000017500000000561312223166165022456 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) // // HX-2010-04-19: this is all deprecated!!! // (* ****** ****** *) fun gtk_file_selection_new {l:agz} (title: !gstring l): GtkFileSelection_ref1 = "mac#atsctrb_gtk_file_selection_new" // end of [gtk_file_selection_new] (* ****** ****** *) fun gtk_file_selection_get_ok_button {c:cls | c <= GtkFileSelection} {l:agz} (filesel: !gobjref (c, l)):<> [l_btn:agz] ( minus (gobjref (c, l), gobjref (GtkButton, l_btn)) | gobjref (GtkButton, l_btn) ) = "atsctrb_gtk_file_selection_get_ok_button" // end of [gtk_file_selection_get_ok_button] fun gtk_file_selection_get_cancel_button {c:cls | c <= GtkFileSelection} {l:agz} (filesel: !gobjref (c, l)):<> [l_btn:agz] ( minus (gobjref (c, l), gobjref (GtkButton, l_btn)) | gobjref (GtkButton, l_btn) ) = "atsctrb_gtk_file_selection_get_cancel_button" // end of [gtk_file_selection_get_cancel_button] (* ****** ****** *) fun gtk_file_selection_get_filename {c:cls | c <= GtkFileSelection} {l1:agz} (filesel: !gobjref (c, l1)) : [l2:addr] (minus (gobjref (c, l1), gstring l2) | gstring l2) = "mac#atsctrb_gtk_file_selection_get_filename" // end of [gtk_file_selection_get_filename] fun gtk_file_selection_set_filename {c:cls | c <= GtkFileSelection} {l1,l2:agz} ( filesel: !gobjref (c, l1), filename: !gstring l2 ) : void = "mac#atsctrb_gtk_file_selection_set_filename" // end of [gtk_file_selection_set_filename] (* ****** ****** *) (* end of [gtkfilesel.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkseparatormenuitem.sats0000664000175000017500000000325512223166165024577 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_separator_menu_item_new (): GtkSeparatorMenuItem_ref1 = "mac#atsctrb_gtk_separator_menu_item_new" // end of [gtk_separator_menu_item_new] (* ****** ****** *) (* end of [gtkseparatormenuitem.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkseparatortoolitem.sats0000664000175000017500000000420612223166165024605 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gtk_separator_tool_item_new (): GtkSeparatorToolItem_ref1 = "mac#atsctrb_gtk_separator_tool_item_new" // end of [gtk_separator_tool_item_new] (* ****** ****** *) fun gtk_separator_tool_item_get_draw {c:cls | c <= GtkSeparatorToolItem} {l:agz} ( itm: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_separator_tool_item_get_draw" // end of [gtk_separator_tool_item_get_draw] fun gtk_separator_tool_item_set_draw {c:cls | c <= GtkSeparatorToolItem} {l:agz} ( itm: !gobjref (c, l), draw: gboolean ) : void = "mac#atsctrb_gtk_separator_tool_item_set_draw" // end of [gtk_separator_tool_item_set_draw] (* ****** ****** *) (* end of [gtkseparatortoolitem.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktexttag.sats0000664000175000017500000000317012223166165022507 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_text_tag_new (): GtkTextTag_ref1 = "mac#atsctrb_gtk_text_tag_new" // end of [gtk_text_tag_new] (* ****** ****** *) (* end of [gtktexttag.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvbox.sats0000664000175000017500000000320612223166165022005 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vbox_new ( homo: gboolean, spacing: gint ) : GtkVBox_ref1 = "mac#atsctrb_gtk_vbox_new" // end of [gtk_vbox_new] (* ****** ****** *) (* end of [gtkvbox.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvruler.sats0000664000175000017500000000316012223166165022345 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vruler_new (): GtkVRuler_ref1 = "mac#atsctrb_gtk_vruler_new" // end of [gtk_vruler_new] (* ****** ****** *) (* end of [gtkvruler.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkdialog.sats0000664000175000017500000001356312223166165022275 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) abst@ype GtkDialogFlags = $extype"GtkDialogFlags" macdef GTK_DIALOG_MODAL = $extval (GtkDialogFlags, "GTK_DIALOG_MODAL") macdef GTK_DIALOG_DESTROY_WITH_PARENT = $extval (GtkDialogFlags, "GTK_DIALOG_DESTROY_WITH_PARENT") macdef GTK_DIALOG_NO_SEPARATOR = $extval (GtkDialogFlags, "GTK_DIALOG_NO_SEPARATOR") fun lor_GtkDialogFlags_GtkDialogFlags ( x1: GtkDialogFlags, x2: GtkDialogFlags ) :<> GtkDialogFlags = "mac#atsctrb_lor_GtkDialogFlags_GtkDialogFlags" overload lor with lor_GtkDialogFlags_GtkDialogFlags (* ****** ****** *) abst@ype GtkResponseType = $extype"GtkResponseType" symintr GtkResponseType castfn GtkResponseType_of_int (x: int):<>GtkResponseType overload GtkResponseType with GtkResponseType_of_int castfn gint_of_GtkResponseType (x: GtkResponseType):<> gint (* ** GTK returns this if a response widget has no response_id, ** or if the dialog gets programmatically hidden or destroyed. *) // GTK_RESPONSE_NONE = -1 macdef GTK_RESPONSE_NONE = $extval (GtkResponseType, "GTK_RESPONSE_NONE") (* ** GTK won't return these unless you pass them in ** as the response for an action widget. They are ** for your convenience. *) // GTK_RESPONSE_REJECT = -2 macdef GTK_RESPONSE_REJECT = $extval (GtkResponseType, "GTK_RESPONSE_REJECT") // GTK_RESPONSE_ACCEPT = -3 macdef GTK_RESPONSE_ACCEPT = $extval (GtkResponseType, "GTK_RESPONSE_ACCEPT") (* If the dialog is deleted *) // GTK_RESPONSE_DELETE_EVENT = -4 macdef GTK_RESPONSE_DELETE_EVENT = $extval (GtkResponseType, "GTK_RESPONSE_DELETE_EVENT") (* ** These are returned from GTK dialogs, and you can also use them ** yourself if you like. *) // GTK_RESPONSE_OK = -5 macdef GTK_RESPONSE_OK = $extval (GtkResponseType, "GTK_RESPONSE_OK") // GTK_RESPONSE_CANCEL = -6 macdef GTK_RESPONSE_CANCEL = $extval (GtkResponseType, "GTK_RESPONSE_CANCEL") // GTK_RESPONSE_CLOSE = -7 macdef GTK_RESPONSE_CLOSE = $extval (GtkResponseType, "GTK_RESPONSE_CLOSE") // GTK_RESPONSE_YES = -8 macdef GTK_RESPONSE_YES = $extval (GtkResponseType, "GTK_RESPONSE_YES") // GTK_RESPONSE_NO = -9 macdef GTK_RESPONSE_NO = $extval (GtkResponseType, "GTK_RESPONSE_NO") // GTK_RESPONSE_APPLY = -10 macdef GTK_RESPONSE_APPLY = $extval (GtkResponseType, "GTK_RESPONSE_APPLY") // GTK_RESPONSE_HELP = -11 macdef GTK_RESPONSE_HELP = $extval (GtkResponseType, "GTK_RESPONSE_HELP") (* ****** ****** *) fun gtk_dialog_new () : GtkDialog_ref1 = "mac#atsctrb_gtk_dialog_new" // end of [gtk_dialog_new] (* // HX: this one is not supported directly in ATS GtkWidget* gtk_dialog_new_with_buttons ( const gchar *title , GtkWindow *parent , GtkDialogFlags flags , const gchar *first_button_text , ... ) ; *) (* ****** ****** *) // // HX-2010-04: needed? // HX-2010-05-02: // Yes. E.g, it may be needed for setting transient-window property // for the parent window. // fun gtk_dialog_get_window {c:cls | c <= GtkDialog} {l:agz} (dialog: !gobjref (c, l)) :<> [l_win:agz] ( // this one is actually 'getref' minus (gobjref (c, l), gobjref (GtkWindow, l_win)) | gobjref (GtkWindow, l_win) ) = "mac#atsctrb_gtk_dialog_get_window" // end of [gtk_dialog_get_window] fun gtk_dialog_get_vbox {c:cls | c <= GtkDialog} {l:agz} (dialog: !gobjref (c, l)):<> [l_box:agz] ( minus (gobjref (c, l), gobjref (GtkVBox, l_box)) | gobjref (GtkVBox, l_box) ) = "mac#atsctrb_gtk_dialog_get_vbox" // end of [gtk_dialog_get_vbox] fun gtk_dialog_get_action_area {c:cls | c <= GtkDialog} {l:agz} (dialog: !gobjref (c, l)):<> [l_box:agz] ( minus (gobjref (c, l), gobjref (GtkHBox, l_box)) | gobjref (GtkHBox, l_box) ) = "mac#atsctrb_gtk_dialog_get_action_area" // end of [gtk_dialog_get_action_area] (* ****** ****** *) fun gtk_dialog_add_button {c:cls | c <= GtkDialog} {l1,l2:agz} (dialog: !gobjref (c, l1), name: !gstring l2, response_id: GtkResponseType) : [l3:agz] ( minus (gobjref (c, l1), gobjref (GtkButton, l3)) | gobjref (GtkButton, l3) ) = "mac#atsctrb_gtk_dialog_add_button" // end of [gtk_dialog_add_button] (* ****** ****** *) // // HX-2010-04-10: // If the diaglog widget is destroyed in the middle, all bets are off!!! // fun gtk_dialog_run {c:cls | c <= GtkDialog} {l:agz} (dialog: !gobjref (c, l)): gint = "mac#atsctrb_gtk_dialog_run" // end of [gtk_dialog_run] (* ****** ****** *) fun gtk_dialog_response {c:cls | c <= GtkDialog} {l:agz} ( dialog: !gobjref (c, l), response_id: gint ) : void = "mac#atsctrb_gtk_dialog_response" // end of [gtk_dialog_response] (* ****** ****** *) (* end of [gtkdialog.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkcontainer.sats0000664000175000017500000000431412223166165023012 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_container_add {c1,c2:cls | c1 <= GtkContainer; c2 <= GtkWidget} {l1,l2:agz} ( container: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_container_add" // end of [gtk_container_add] fun gtk_container_remove {c1,c2:cls | c1 <= GtkContainer; c2 <= GtkWidget} {l1,l2:agz} ( container: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_container_remove" // end of [gtk_container_remove] (* ****** ****** *) fun gtk_container_set_border_width {c:cls | c <= GtkContainer} {l:agz} ( container: !gobjref (c, l), width: guint ) : void = "mac#atsctrb_gtk_container_set_border_width" // end of [gtk_container_set_border_width] (* ****** ****** *) (* end of [gtkcontainer.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkrange.sats0000664000175000017500000000456612223166165022135 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_range_set_update_policy {c:cls | c <= GtkRange} {l:agz} ( range: !gobjref (c, l), policy: GtkUpdateType ) : void = "mac#atsctrb_gtk_range_set_update_policy" // end of [gtk_range_set_update_policy] (* ****** ****** *) // // HX-2010-04: this one is 'get0' in ATS: // fun gtk_range_get_adjustment {c:cls | c <= GtkRange} {l:agz} ( range: !gobjref (c, l) ) : [l1:addr] ( minus (gobjref (c, l), gobjref (GtkAdjustment, l1)) | gobjref (GtkAdjustment, l1) ) = "mac#atsctrb_gtk_range_get_adjustment" // end of [gtk_range_get_adjustment] // // HX-2010-04-13: // this one is 'set1': [g_object_ref] is called on [adj] if it is added! // fun gtk_range_set_adjustment {c:cls | c <= GtkRange} {l1,l2:agz} ( range: !gobjref (c, l1), adj: !gobjref (GtkAdjustment, l2) ) : void = "mac#atsctrb_gtk_range_set_adjustment" // end of [gtk_range_set_adjustment] (* ****** ****** *) (* end of [gtkrange.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkstock.sats0000664000175000017500000003375112223166165022162 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) (* #define GTK_STOCK_DIALOG_AUTHENTICATION "gtk-dialog-authentication" #define GTK_STOCK_DIALOG_INFO "gtk-dialog-info" #define GTK_STOCK_DIALOG_WARNING "gtk-dialog-warning" #define GTK_STOCK_DIALOG_ERROR "gtk-dialog-error" #define GTK_STOCK_DIALOG_QUESTION "gtk-dialog-question" *) macdef GTK_STOCK_DIALOG_AUTHENTICATION = $extval (string, "GTK_STOCK_DIALOG_AUTHENTICATION") macdef GTK_STOCK_DIALOG_INFO = $extval (string, "GTK_STOCK_DIALOG_INFO") macdef GTK_STOCK_DIALOG_WARNING = $extval (string, "GTK_STOCK_DIALOG_WARNING") macdef GTK_STOCK_DIALOG_ERROR = $extval (string, "GTK_STOCK_DIALOG_ERROR") macdef GTK_STOCK_DIALOG_QUESTION = $extval (string, "GTK_STOCK_DIALOG_QUESTION") (* ****** ****** *) (* #define GTK_STOCK_DND "gtk-dnd" #define GTK_STOCK_DND_MULTIPLE "gtk-dnd-multiple" *) macdef GTK_STOCK_DND = $extval (string, "GTK_STOCK_DND") macdef GTK_STOCK_DND_MULTIPLE = $extval (string, "GTK_STOCK_DND_MULTIPLE") (* ****** ****** *) (* #define GTK_STOCK_ABOUT "gtk-about" #define GTK_STOCK_ADD "gtk-add" #define GTK_STOCK_APPLY "gtk-apply" #define GTK_STOCK_BOLD "gtk-bold" #define GTK_STOCK_CANCEL "gtk-cancel" #define GTK_STOCK_CAPS_LOCK_WARNING "gtk-caps-lock-warning" #define GTK_STOCK_CDROM "gtk-cdrom" #define GTK_STOCK_CLEAR "gtk-clear" #define GTK_STOCK_CLOSE "gtk-close" #define GTK_STOCK_COLOR_PICKER "gtk-color-picker" #define GTK_STOCK_CONVERT "gtk-convert" #define GTK_STOCK_CONNECT "gtk-connect" #define GTK_STOCK_COPY "gtk-copy" #define GTK_STOCK_CUT "gtk-cut" #define GTK_STOCK_DELETE "gtk-delete" #define GTK_STOCK_DIRECTORY "gtk-directory" #define GTK_STOCK_DISCARD "gtk-discard" #define GTK_STOCK_DISCONNECT "gtk-disconnect" #define GTK_STOCK_EDIT "gtk-edit" #define GTK_STOCK_EXECUTE "gtk-execute" #define GTK_STOCK_FILE "gtk-file" #define GTK_STOCK_FIND "gtk-find" #define GTK_STOCK_FIND_AND_REPLACE "gtk-find-and-replace" #define GTK_STOCK_FLOPPY "gtk-floppy" #define GTK_STOCK_FULLSCREEN "gtk-fullscreen" #define GTK_STOCK_GOTO_BOTTOM "gtk-goto-bottom" #define GTK_STOCK_GOTO_FIRST "gtk-goto-first" #define GTK_STOCK_GOTO_LAST "gtk-goto-last" #define GTK_STOCK_GOTO_TOP "gtk-goto-top" #define GTK_STOCK_GO_BACK "gtk-go-back" #define GTK_STOCK_GO_DOWN "gtk-go-down" #define GTK_STOCK_GO_FORWARD "gtk-go-forward" #define GTK_STOCK_GO_UP "gtk-go-up" #define GTK_STOCK_HARDDISK "gtk-harddisk" #define GTK_STOCK_HELP "gtk-help" #define GTK_STOCK_HOME "gtk-home" #define GTK_STOCK_INDEX "gtk-index" #define GTK_STOCK_INDENT "gtk-indent" #define GTK_STOCK_INFO "gtk-info" #define GTK_STOCK_UNINDENT "gtk-unindent" #define GTK_STOCK_ITALIC "gtk-italic" #define GTK_STOCK_JUMP_TO "gtk-jump-to" #define GTK_STOCK_JUSTIFY_CENTER "gtk-justify-center" #define GTK_STOCK_JUSTIFY_FILL "gtk-justify-fill" #define GTK_STOCK_JUSTIFY_LEFT "gtk-justify-left" #define GTK_STOCK_JUSTIFY_RIGHT "gtk-justify-right" #define GTK_STOCK_LEAVE_FULLSCREEN "gtk-leave-fullscreen" #define GTK_STOCK_MISSING_IMAGE "gtk-missing-image" #define GTK_STOCK_MEDIA_FORWARD "gtk-media-forward" #define GTK_STOCK_MEDIA_NEXT "gtk-media-next" #define GTK_STOCK_MEDIA_PAUSE "gtk-media-pause" #define GTK_STOCK_MEDIA_PLAY "gtk-media-play" #define GTK_STOCK_MEDIA_PREVIOUS "gtk-media-previous" #define GTK_STOCK_MEDIA_RECORD "gtk-media-record" #define GTK_STOCK_MEDIA_REWIND "gtk-media-rewind" #define GTK_STOCK_MEDIA_STOP "gtk-media-stop" #define GTK_STOCK_NETWORK "gtk-network" #define GTK_STOCK_NEW "gtk-new" #define GTK_STOCK_NO "gtk-no" #define GTK_STOCK_OK "gtk-ok" #define GTK_STOCK_OPEN "gtk-open" #define GTK_STOCK_ORIENTATION_PORTRAIT "gtk-orientation-portrait" #define GTK_STOCK_ORIENTATION_LANDSCAPE "gtk-orientation-landscape" #define GTK_STOCK_ORIENTATION_REVERSE_LANDSCAPE "gtk-orientation-reverse-landscape" #define GTK_STOCK_ORIENTATION_REVERSE_PORTRAIT "gtk-orientation-reverse-portrait" #define GTK_STOCK_PAGE_SETUP "gtk-page-setup" #define GTK_STOCK_PASTE "gtk-paste" #define GTK_STOCK_PREFERENCES "gtk-preferences" #define GTK_STOCK_PRINT "gtk-print" #define GTK_STOCK_PRINT_ERROR "gtk-print-error" #define GTK_STOCK_PRINT_PAUSED "gtk-print-paused" #define GTK_STOCK_PRINT_PREVIEW "gtk-print-preview" #define GTK_STOCK_PRINT_REPORT "gtk-print-report" #define GTK_STOCK_PRINT_WARNING "gtk-print-warning" #define GTK_STOCK_PROPERTIES "gtk-properties" #define GTK_STOCK_QUIT "gtk-quit" #define GTK_STOCK_REDO "gtk-redo" #define GTK_STOCK_REFRESH "gtk-refresh" #define GTK_STOCK_REMOVE "gtk-remove" #define GTK_STOCK_REVERT_TO_SAVED "gtk-revert-to-saved" #define GTK_STOCK_SAVE "gtk-save" #define GTK_STOCK_SAVE_AS "gtk-save-as" #define GTK_STOCK_SELECT_ALL "gtk-select-all" #define GTK_STOCK_SELECT_COLOR "gtk-select-color" #define GTK_STOCK_SELECT_FONT "gtk-select-font" #define GTK_STOCK_SORT_ASCENDING "gtk-sort-ascending" #define GTK_STOCK_SORT_DESCENDING "gtk-sort-descending" #define GTK_STOCK_SPELL_CHECK "gtk-spell-check" #define GTK_STOCK_STOP "gtk-stop" #define GTK_STOCK_STRIKETHROUGH "gtk-strikethrough" #define GTK_STOCK_UNDELETE "gtk-undelete" #define GTK_STOCK_UNDERLINE "gtk-underline" #define GTK_STOCK_UNDO "gtk-undo" #define GTK_STOCK_YES "gtk-yes" #define GTK_STOCK_ZOOM_100 "gtk-zoom-100" #define GTK_STOCK_ZOOM_FIT "gtk-zoom-fit" #define GTK_STOCK_ZOOM_IN "gtk-zoom-in" #define GTK_STOCK_ZOOM_OUT "gtk-zoom-out" *) macdef GTK_STOCK_ABOUT = $extval (string, "GTK_STOCK_ABOUT") macdef GTK_STOCK_ADD = $extval (string, "GTK_STOCK_ADD") macdef GTK_STOCK_APPLY = $extval (string, "GTK_STOCK_APPLY") macdef GTK_STOCK_BOLD = $extval (string, "GTK_STOCK_BOLD") macdef GTK_STOCK_CANCEL = $extval (string, "GTK_STOCK_CANCEL") macdef GTK_STOCK_CAPS_LOCK_WARNING = $extval (string, "GTK_STOCK_CAPS_LOCK_WARNING") macdef GTK_STOCK_CDROM = $extval (string, "GTK_STOCK_CDROM") macdef GTK_STOCK_CLEAR = $extval (string, "GTK_STOCK_CLEAR") macdef GTK_STOCK_CLOSE = $extval (string, "GTK_STOCK_CLOSE") macdef GTK_STOCK_COLOR_PICKER = $extval (string, "GTK_STOCK_COLOR_PICKER") macdef GTK_STOCK_CONVERT = $extval (string, "GTK_STOCK_CONVERT") macdef GTK_STOCK_CONNECT = $extval (string, "GTK_STOCK_CONNECT") macdef GTK_STOCK_COPY = $extval (string, "GTK_STOCK_COPY") macdef GTK_STOCK_CUT = $extval (string, "GTK_STOCK_CUT") macdef GTK_STOCK_DELETE = $extval (string, "GTK_STOCK_DELETE") macdef GTK_STOCK_DIRECTORY = $extval (string, "GTK_STOCK_DIRECTORY") macdef GTK_STOCK_DISCARD = $extval (string, "GTK_STOCK_DISCARD") macdef GTK_STOCK_DISCONNECT = $extval (string, "GTK_STOCK_DISCONNECT") macdef GTK_STOCK_EDIT = $extval (string, "GTK_STOCK_EDIT") macdef GTK_STOCK_EXECUTE = $extval (string, "GTK_STOCK_EXECUTE") macdef GTK_STOCK_FILE = $extval (string, "GTK_STOCK_FILE") macdef GTK_STOCK_FIND = $extval (string, "GTK_STOCK_FIND") macdef GTK_STOCK_FIND_AND_REPLACE = $extval (string, "GTK_STOCK_FIND_AND_REPLACE") macdef GTK_STOCK_FLOPPY = $extval (string, "GTK_STOCK_FLOPPY") macdef GTK_STOCK_FULLSCREEN = $extval (string, "GTK_STOCK_FULLSCREEN") macdef GTK_STOCK_GOTO_BOTTOM = $extval (string, "GTK_STOCK_GOTO_BOTTOM") macdef GTK_STOCK_GOTO_FIRST = $extval (string, "GTK_STOCK_GOTO_FIRST") macdef GTK_STOCK_GOTO_LAST = $extval (string, "GTK_STOCK_GOTO_LAST") macdef GTK_STOCK_GOTO_TOP = $extval (string, "GTK_STOCK_GOTO_TOP") macdef GTK_STOCK_GO_BACK = $extval (string, "GTK_STOCK_GO_BACK") macdef GTK_STOCK_GO_DOWN = $extval (string, "GTK_STOCK_GO_DOWN") macdef GTK_STOCK_GO_FORWARD = $extval (string, "GTK_STOCK_GO_FORWARD") macdef GTK_STOCK_GO_UP = $extval (string, "GTK_STOCK_GO_UP") macdef GTK_STOCK_HARDDISK = $extval (string, "GTK_STOCK_HARDDISK") macdef GTK_STOCK_HELP = $extval (string, "GTK_STOCK_HELP") macdef GTK_STOCK_HOME = $extval (string, "GTK_STOCK_HOME") macdef GTK_STOCK_INDEX = $extval (string, "GTK_STOCK_INDEX") macdef GTK_STOCK_INDENT = $extval (string, "GTK_STOCK_INDENT") macdef GTK_STOCK_INFO = $extval (string, "GTK_STOCK_INFO") macdef GTK_STOCK_UNINDENT = $extval (string, "GTK_STOCK_UNINDENT") macdef GTK_STOCK_ITALIC = $extval (string, "GTK_STOCK_ITALIC") macdef GTK_STOCK_JUMP_TO = $extval (string, "GTK_STOCK_JUMP_TO") macdef GTK_STOCK_JUSTIFY_CENTER = $extval (string, "GTK_STOCK_JUSTIFY_CENTER") macdef GTK_STOCK_JUSTIFY_FILL = $extval (string, "GTK_STOCK_JUSTIFY_FILL") macdef GTK_STOCK_JUSTIFY_LEFT = $extval (string, "GTK_STOCK_JUSTIFY_LEFT") macdef GTK_STOCK_JUSTIFY_RIGHT = $extval (string, "GTK_STOCK_JUSTIFY_RIGHT") macdef GTK_STOCK_LEAVE_FULLSCREEN = $extval (string, "GTK_STOCK_LEAVE_FULLSCREEN") macdef GTK_STOCK_MISSING_IMAGE = $extval (string, "GTK_STOCK_MISSING_IMAGE") macdef GTK_STOCK_MEDIA_FORWARD = $extval (string, "GTK_STOCK_MEDIA_FORWARD") macdef GTK_STOCK_MEDIA_NEXT = $extval (string, "GTK_STOCK_MEDIA_NEXT") macdef GTK_STOCK_MEDIA_PAUSE = $extval (string, "GTK_STOCK_MEDIA_PAUSE") macdef GTK_STOCK_MEDIA_PLAY = $extval (string, "GTK_STOCK_MEDIA_PLAY") macdef GTK_STOCK_MEDIA_PREVIOUS = $extval (string, "GTK_STOCK_MEDIA_PREVIOUS") macdef GTK_STOCK_MEDIA_RECORD = $extval (string, "GTK_STOCK_MEDIA_RECORD") macdef GTK_STOCK_MEDIA_REWIND = $extval (string, "GTK_STOCK_MEDIA_REWIND") macdef GTK_STOCK_MEDIA_STOP = $extval (string, "GTK_STOCK_MEDIA_STOP") macdef GTK_STOCK_NETWORK = $extval (string, "GTK_STOCK_NETWORK") macdef GTK_STOCK_NEW = $extval (string, "GTK_STOCK_NEW") macdef GTK_STOCK_NO = $extval (string, "GTK_STOCK_NO") macdef GTK_STOCK_OK = $extval (string, "GTK_STOCK_OK") macdef GTK_STOCK_OPEN = $extval (string, "GTK_STOCK_OPEN") macdef GTK_STOCK_ORIENTATION_PORTRAIT = $extval (string, "GTK_STOCK_ORIENTATION_PORTRAIT") macdef GTK_STOCK_ORIENTATION_LANDSCAPE = $extval (string, "GTK_STOCK_ORIENTATION_LANDSCAPE") macdef GTK_STOCK_ORIENTATION_REVERSE_LANDSCAPE = $extval (string, "GTK_STOCK_ORIENTATION_REVERSE_LANDSCAPE") macdef GTK_STOCK_ORIENTATION_REVERSE_PORTRAIT = $extval (string, "GTK_STOCK_ORIENTATION_REVERSE_PORTRAIT") macdef GTK_STOCK_PAGE_SETUP = $extval (string, "GTK_STOCK_PAGE_SETUP") macdef GTK_STOCK_PASTE = $extval (string, "GTK_STOCK_PASTE") macdef GTK_STOCK_PREFERENCES = $extval (string, "GTK_STOCK_PREFERENCES") macdef GTK_STOCK_PRINT = $extval (string, "GTK_STOCK_PRINT") macdef GTK_STOCK_PRINT_ERROR = $extval (string, "GTK_STOCK_PRINT_ERROR") macdef GTK_STOCK_PRINT_PAUSED = $extval (string, "GTK_STOCK_PRINT_PAUSED") macdef GTK_STOCK_PRINT_PREVIEW = $extval (string, "GTK_STOCK_PRINT_PREVIEW") macdef GTK_STOCK_PRINT_REPORT = $extval (string, "GTK_STOCK_PRINT_REPORT") macdef GTK_STOCK_PRINT_WARNING = $extval (string, "GTK_STOCK_PRINT_WARNING") macdef GTK_STOCK_PROPERTIES = $extval (string, "GTK_STOCK_PROPERTIES") macdef GTK_STOCK_QUIT = $extval (string, "GTK_STOCK_QUIT") macdef GTK_STOCK_REDO = $extval (string, "GTK_STOCK_REDO") macdef GTK_STOCK_REFRESH = $extval (string, "GTK_STOCK_REFRESH") macdef GTK_STOCK_REMOVE = $extval (string, "GTK_STOCK_REMOVE") macdef GTK_STOCK_REVERT_TO_SAVED = $extval (string, "GTK_STOCK_REVERT_TO_SAVED") macdef GTK_STOCK_SAVE = $extval (string, "GTK_STOCK_SAVE") macdef GTK_STOCK_SAVE_AS = $extval (string, "GTK_STOCK_SAVE_AS") macdef GTK_STOCK_SELECT_ALL = $extval (string, "GTK_STOCK_SELECT_ALL") macdef GTK_STOCK_SELECT_COLOR = $extval (string, "GTK_STOCK_SELECT_COLOR") macdef GTK_STOCK_SELECT_FONT = $extval (string, "GTK_STOCK_SELECT_FONT") macdef GTK_STOCK_SORT_ASCENDING = $extval (string, "GTK_STOCK_SORT_ASCENDING") macdef GTK_STOCK_SORT_DESCENDING = $extval (string, "GTK_STOCK_SORT_DESCENDING") macdef GTK_STOCK_SPELL_CHECK = $extval (string, "GTK_STOCK_SPELL_CHECK") macdef GTK_STOCK_STOP = $extval (string, "GTK_STOCK_STOP") macdef GTK_STOCK_STRIKETHROUGH = $extval (string, "GTK_STOCK_STRIKETHROUGH") macdef GTK_STOCK_UNDELETE = $extval (string, "GTK_STOCK_UNDELETE") macdef GTK_STOCK_UNDERLINE = $extval (string, "GTK_STOCK_UNDERLINE") macdef GTK_STOCK_UNDO = $extval (string, "GTK_STOCK_UNDO") macdef GTK_STOCK_YES = $extval (string, "GTK_STOCK_YES") macdef GTK_STOCK_ZOOM_100 = $extval (string, "GTK_STOCK_ZOOM_100") macdef GTK_STOCK_ZOOM_FIT = $extval (string, "GTK_STOCK_ZOOM_FIT") macdef GTK_STOCK_ZOOM_IN = $extval (string, "GTK_STOCK_ZOOM_IN") macdef GTK_STOCK_ZOOM_OUT = $extval (string, "GTK_STOCK_ZOOM_OUT") (* ****** ****** *) (* end of [gtkstock.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhscale.sats0000664000175000017500000000360712223166165022273 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hscale_new {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l)): GtkHScale_ref1 = "mac#atsctrb_gtk_hscale_new" // end of [gtk_hscale_new] fun gtk_hscale_new_with_range {c:cls | c <= GtkAdjustment} {l:agz} ( min: gdouble, max: gdouble, step: gdouble ) : GtkHScale_ref1 = "mac#atsctrb_gtk_hscale_new_with_range" // end of [gtk_hscale_new_with_rangle] (* ****** ****** *) (* end of [gtkhscale.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkoptionmenu.sats0000664000175000017500000000356212223166165023231 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_option_menu_new (): GtkOptionMenu_ref1 = "mac#atsctrb_gtk_option_menu_new" // end of [gtk_option_menu_new] fun gtk_option_menu_set_menu {c1,c2:cls | c1 <= GtkOptionMenu;c2 <= GtkMenu} {l1,l2:agz} ( opt: !gobjref (c1, l1), menu: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_option_menu_set_menu" // end of [gtk_option_menu_set_menu] (* ****** ****** *) (* end of [gtkoptionmenu.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkentry.sats0000664000175000017500000000650212223166165022172 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_entry_new (): GtkEntry_ref1 = "mac#atsctrb_gtk_entry_new" // end of [gtk_entry_new] (* ****** ****** *) fun gtk_entry_get_visibility {c:cls | c <= GtkEntry} {l:agz} ( entry: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_entry_get_visibility" // end of [gtk_entry_get_visibility] fun gtk_entry_set_visibility {c:cls | c <= GtkEntry} {l:agz} ( entry: !gobjref (c, l), visibility: gboolean ) : void = "mac#atsctrb_gtk_entry_set_visibility" // end of [gtk_entry_set_visibility] (* ****** ****** *) fun gtk_entry_get_editable {c:cls | c <= GtkEntry} {l:agz} ( entry: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_entry_get_editable" // end of [gtk_entry_get_editable] fun gtk_entry_set_editable {c:cls | c <= GtkEntry} {l:agz} ( entry: !gobjref (c, l), editable: gboolean ) : void = "mac#atsctrb_gtk_entry_set_editable" // end of [gtk_entry_set_editable] (* ****** ****** *) fun gtk_entry_get_max_length {c:cls | c <= GtkEntry} {l:agz} (entry: !gobjref (c, l)): gint = "mac#atsctrb_gtk_entry_get_max_length" // end of [gtk_entry_get_max_length] fun gtk_entry_set_max_length {c:cls | c <= GtkEntry} {l:agz} ( entry: !gobjref (c, l), max: gint ) : void = "mac#atsctrb_gtk_entry_set_max_length" // end of [gtk_entry_set_max_length] (* ****** ****** *) // // HX-2010-05-07: assumed: the return cannot be NULL! // fun gtk_entry_get_text {c:cls | c <= GtkEntry} {l1:agz} (entry: !gobjref (c, l1)) : [l2:agz] ( minus (gobjref (c, l1), gstring l2) | gstring l2 ) = "mac#atsctrb_gtk_entry_get_text" // end of [gtk_entry_get_text] // // HX-2010-05-07: checked: the input [text] cannot be NULL! // fun gtk_entry_set_text {c:cls | c <= GtkEntry} {l1,l2:agz} ( entry: !gobjref (c, l1), text: !gstring l2 ) : void = "mac#atsctrb_gtk_entry_set_text" // end of [gtk_entry_set_text] (* ****** ****** *) (* end of [gtkentry.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkcheckbutton.sats0000664000175000017500000000377712223166165023355 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_check_button_new (): GtkCheckButton_ref1 = "mac#atsctrb_gtk_check_button_new" // end of [gtk_check_button_new] fun gtk_check_button_new_with_label {l:agz} (name: !gstring l): GtkCheckButton_ref1 = "mac#atsctrb_gtk_check_button_new_with_label" // end of [gtk_check_button_new_with_label] fun gtk_check_button_new_with_mnemonic {l:agz} (name: !gstring l): GtkCheckButton_ref1 = "mac#atsctrb_gtk_check_button_new_with_mnemonic" // end of [gtk_check_button_new_with_mnemonic] (* ****** ****** *) (* end of [gtkcheckbutton.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkfilechooser.sats0000664000175000017500000001041512223166165023331 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: May, 2010 // (* ****** ****** *) abst@ype GtkFileChooserAction = $extype"GtkFileChooserAction" macdef GTK_FILE_CHOOSER_ACTION_OPEN = $extval (GtkFileChooserAction, "GTK_FILE_CHOOSER_ACTION_OPEN") macdef GTK_FILE_CHOOSER_ACTION_SAVE = $extval (GtkFileChooserAction, "GTK_FILE_CHOOSER_ACTION_SAVE") macdef GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER = $extval (GtkFileChooserAction, "GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER") macdef GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER = $extval (GtkFileChooserAction, "GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER") (* ****** ****** *) abst@ype GtkFileChooserConfirmation = $extype"GtkFileChooserConfirmation" macdef GTK_FILE_CHOOSER_CONFIRMATION_CONFIRM = $extval (GtkFileChooserConfirmation, "GTK_FILE_CHOOSER_CONFIRMATION_CONFIRM") macdef GTK_FILE_CHOOSER_CONFIRMATION_ACCEPT_FILENAME = $extval (GtkFileChooserConfirmation, "GTK_FILE_CHOOSER_CONFIRMATION_ACCEPT_FILENAME") macdef GTK_FILE_CHOOSER_CONFIRMATION_SELECT_AGAIN = $extval (GtkFileChooserConfirmation, "GTK_FILE_CHOOSER_CONFIRMATION_SELECT_AGAIN") (* ****** ****** *) fun gtk_file_chooser_get_action {c:cls | c <= GtkFileChooser} {l:agz} (chooser: !gobjref (c, l)): GtkFileChooserAction = "mac#atsctrb_gtk_file_chooser_get_action" // end of [gtk_file_chooser_get_action] fun gtk_file_chooser_set_action {c:cls | c <= GtkFileChooser} {l:agz} (chooser: !gobjref (c, l), action: GtkFileChooserAction): void = "mac#atsctrb_gtk_file_chooser_set_action" // end of [gtk_file_chooser_set_action] (* ****** ****** *) // // HX-2010-05-05: // the return may be a NULL gstring // fun gtk_file_chooser_get_filename {c:cls | c <= GtkFileChooser} {l:agz} (chooser: !gobjref (c, l)): gstring0 // it is copied out = "mac#atsctrb_gtk_file_chooser_get_filename" // end of [gtk_file_chooser_get_filename] fun gtk_file_chooser_set_filename {c:cls | c <= GtkFileChooser} {l1,l2:agz} (chooser: !gobjref (c, l1), filename: !gstring l2): gboolean = "mac#atsctrb_gtk_file_chooser_set_filename" // end of [gtk_file_chooser_set_filename] (* ****** ****** *) fun gtk_file_chooser_set_current_name {c:cls | c <= GtkFileChooser} {l1,l2:agz} (chooser: !gobjref (c, l1), name: !gstring l2): void = "mac#atsctrb_gtk_file_chooser_set_current_name" // end of [gtk_file_chooser_set_current_name] (* ****** ****** *) fun gtk_file_chooser_get_do_overwrite_confirmation {c:cls | c <= GtkFileChooser} {l:agz} (chooser: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_file_chooser_get_do_overwrite_confirmation" // end of [gtk_file_chooser_get_do_overwrite_confirmation] fun gtk_file_chooser_set_do_overwrite_confirmation {c:cls | c <= GtkFileChooser} {l:agz} (chooser: !gobjref (c, l), yesno: gboolean): void = "mac#atsctrb_gtk_file_chooser_set_do_overwrite_confirmation" // end of [gtk_file_chooser_set_do_overwrite_confirmation] (* ****** ****** *) (* end of [gtkfilechooser.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktexttagtable.sats0000664000175000017500000000425412223166165023523 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_text_tag_table_new ( // there is no argument for this function ) : GtkTextTagTable_ref1 = "mac#atsctrb_gtk_text_tag_table_new" // end of [gtk_text_tag_table_new] (* ****** ****** *) fun gtk_text_tag_table_add {c1,c2:cls | c1 <= GtkTextTagTable; c2 <= GtkTextTag} {l1,l2:agz} ( tbl: !gobjref (c1, l1), tag: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_text_tag_table_add" // end of [gtk_text_tag_table_add] fun gtk_text_tag_table_remove {c1,c2:cls | c1 <= GtkTextTagTable; c2 <= GtkTextTag} {l1,l2:agz} ( tbl: !gobjref (c1, l1), tag: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_text_tag_table_add" // end of [gtk_text_tag_table_add] (* ****** ****** *) (* end of [gtktexttagtable.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmisc.sats0000664000175000017500000000370112223166165021762 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_misc_set_alignment {c:cls | c <= GtkMisc} {l:agz} ( misc: !gobjref (c, l) , xalign: gfloat, yalign: gfloat ) : void = "mac#atsctrb_gtk_misc_set_alignment" // end of [gtk_misc_set_alignment] fun gtk_misc_get_alignment {c:cls | c <= GtkMisc} {l:agz} ( misc: !gobjref (c, l) , xalign: &gfloat? >> gfloat, yalign: &gfloat? >> gfloat ) : void = "mac#atsctrb_gtk_misc_get_alignment" // end of [gtk_misc_get_alignment] (* ****** ****** *) (* end of [gtkmisc.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkfilechooserdialog.sats0000664000175000017500000000511412223166165024511 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: May, 2010 // (* ****** ****** *) // // HX-2010-05-28: if [l1] is null, then no button is inserted // fun gtk_file_chooser_dialog_new {l1:addr} ( title: Stropt , action: GtkFileChooserAction /* // HX: can be added by gtk_dialog_add_button , first_button_text: !gstring l1, response_id: gint */ ) : GtkFileChooserDialog_ref1 = "atsctrb_gtk_file_chooser_dialog_new" // a function! // end of [gtk_file_chooser_dialog_new] (* // // HX: this one is not directly supported in ATS: // GtkWidget* gtk_file_chooser_dialog_new ( const gchar *title , GtkWindow *parent , GtkFileChooserAction action , const gchar *first_button_text , ... ) // end of [gtk_file_chooser_dialog_new] *) (* ****** ****** *) // // HX-2010-05-02: // note that this is really just a cast (intead of a field selection) // fun gtk_file_chooser_dialog_get_chooser {c:cls | c <= GtkFileChooserDialog} {l:agz} (chooserdlg: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), gobjref (GtkFileChooser, l1)) | gobjref (GtkFileChooser, l1) ) = "mac#atsctrb_GTK_FILE_CHOOSER" // end of [gtk_file_chooser_dialog_get_chooser] (* ****** ****** *) (* end of [gtkfilechooserdialog.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktextview.sats0000664000175000017500000002065612223166165022716 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abst@ype GtkTextWindowType = $extype"GtkTextWindowType" macdef GTK_TEXT_WINDOW_PRIVATE = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_PRIVATE") macdef GTK_TEXT_WINDOW_WIDGET = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_WIDGET") macdef GTK_TEXT_WINDOW_TEXT = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_TEXT") macdef GTK_TEXT_WINDOW_LEFT = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_LEFT") macdef GTK_TEXT_WINDOW_RIGHT = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_RIGHT") macdef GTK_TEXT_WINDOW_TOP = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_TOP") macdef GTK_TEXT_WINDOW_BOTTOM = $extval (GtkTextWindowType, "GTK_TEXT_WINDOW_BOTTOM") (* ****** ****** *) fun gtk_text_view_new (): GtkTextView_ref1 = "mac#atsctrb_gtk_text_view_new" // end of [gtk_text_view_new] // // HX-2010-05-03: if [NULL] is passed, a new one is created automatically // fun gtk_text_view_new_with_buffer {c:cls | c <= GtkTextBuffer} {l:addr} ( tb: !gobjref (c, l) ) : GtkTextView_ref1 = "mac#atsctrb_gtk_text_view_new_with_buffer" // end of [gtk_text_view_new_with_buffer] (* ****** ****** *) fun gtk_text_view_set_buffer {c1,c2:cls | c1 <= GtkTextView; c2 <= GtkTextBuffer} {l1,l2:agz} ( tv: !gobjref (c1, l1), tb: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_text_view_set_buffer" // end of [gtk_text_view_set_buffer] // // HX-2010-05-06: this one is 'get0' // fun gtk_text_view_get_buffer {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) :<> [l_buf:agz] ( minus (gobjref (c, l), gobjref (GtkTextBuffer, l_buf)) | gobjref (GtkTextBuffer, l_buf) ) = "mac#atsctrb_gtk_text_view_get_buffer" // end of [gtk_text_view_get_buffer] (* ****** ****** *) fun gtk_text_view_get_wrap_mode {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l)): GtkWrapMode = "mac#atsctrb_gtk_text_view_get_wrap_mode" // end of [gtk_text_view_get_wrap_mode] fun gtk_text_view_set_wrap_mode {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l), mode: GtkWrapMode): void = "mac#atsctrb_gtk_text_view_set_wrap_mode" // end of [gtk_text_view_set_wrap_mode] (* ****** ****** *) fun gtk_text_view_get_editable {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_text_view_get_editable" // end of [gtk_text_view_get_editable] fun gtk_text_view_set_editable {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l), editable: gboolean): void = "mac#atsctrb_gtk_text_view_set_editable" // end of [gtk_text_view_set_editable] (* ****** ****** *) fun gtk_text_view_get_cursor_visible {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_text_view_get_cursor_visible" // end of [gtk_text_view_get_cursor_visible] fun gtk_text_view_set_cursor_visible {c:cls | c <= GtkTextView} {l:agz} (tv: !gobjref (c, l), visible: gboolean): void = "mac#atsctrb_gtk_text_view_set_cursor_visible" // end of [gtk_text_view_set_cursor_visible] (* ****** ****** *) fun gtk_text_view_get_overwrite {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_text_view_get_overwrite" // end of [gtk_text_view_get_overwrite] fun gtk_text_view_set_overwrite {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , overwrite: gboolean ) : void = "mac#atsctrb_gtk_text_view_set_overwrite" // end of [gtk_text_view_set_overwrite] (* ****** ****** *) fun gtk_text_view_get_justification {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) : GtkJustification = "mac#atsctrb_gtk_text_view_get_justification" // end of [gtk_text_view_get_justification] fun gtk_text_view_set_justification {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , justification: GtkJustification ) : void = "mac#atsctrb_gtk_text_view_set_justification" // end of [gtk_text_view_set_justification] (* ****** ****** *) fun gtk_text_view_get_left_margin {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_text_view_get_left_margin" // end of [gtk_text_view_get_left_margin] fun gtk_text_view_set_left_margin {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), margin: gint ) : void = "mac#atsctrb_gtk_text_view_set_left_margin" // end of [gtk_text_view_set_left_margin] fun gtk_text_view_get_right_margin {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_text_view_get_right_margin" // end of [gtk_text_view_get_right_margin] fun gtk_text_view_set_right_margin {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), margin: gint ) : void = "mac#atsctrb_gtk_text_view_set_right_margin" // end of [gtk_text_view_set_right_margin] (* ****** ****** *) fun gtk_text_view_get_indent {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_text_view_get_indent" // end of [gtk_text_view_get_indent] fun gtk_text_view_set_indent {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), indent: gint ) : void = "mac#atsctrb_gtk_text_view_set_indent" // end of [gtk_text_view_set_indent] (* ****** ****** *) fun gtk_text_view_get_window {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), type: GtkTextWindowType ) :<> [l1:addr] ( minus (gobjref (c, l), GdkWindow_ref l1) | GdkWindow_ref l1 ) = "mac#atsctrb_gtk_text_view_get_window" // end of [gtk_text_view_get_window] (* ****** ****** *) fun gtk_text_view_get_border_window_size {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), type: GtkTextWindowType ) : gint = "mac#atsctrb_gtk_text_view_get_border_window_size" // end of [gtk_text_view_get_border_window_size] fun gtk_text_view_set_border_window_size {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l), type: GtkTextWindowType, size: gint ) : void = "mac#atsctrb_gtk_text_view_set_border_window_size" // end of [gtk_text_view_set_border_window_size] (* ****** ****** *) fun gtk_text_view_get_line_at_y {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , iter: &GtkTextIter? >> GtkTextIter , y: gint , linetop: &gint? >> gint ) : void = "mac#atsctrb_gtk_text_view_get_line_at_y" // end of [gtk_text_view_get_line_at_y] fun gtk_text_view_get_line_yrange {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , iter: &GtkTextIter , y: &gint? >> gint , height: &gint? >> gint ) : void = "mac#atsctrb_gtk_text_view_get_line_yrange" // end of [gtk_text_view_get_line_yrange] (* ****** ****** *) fun gtk_text_view_buffer_to_window_coords {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , _type: GtkTextWindowType , buf_x: gint, buf_y: gint , win_x: &gint? >> gint, win_y: &gint? >> gint ) : void = "mac#atsctrb_gtk_text_view_buffer_to_window_coords" // end of [gtk_text_view_buffer_to_window_coords] fun gtk_text_view_window_to_buffer_coords {c:cls | c <= GtkTextView} {l:agz} ( tv: !gobjref (c, l) , _type: GtkTextWindowType , win_x: gint, win_y: gint , buf_x: &gint? >> gint, buf_y: &gint? >> gint ) : void = "mac#atsctrb_gtk_text_view_window_to_buffer_coords" // end of [gtk_text_view_window_to_buffer_coords] (* ****** ****** *) (* end of [gtktextview.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkprogress.sats0000664000175000017500000000372112223166165022675 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June, 2010 // (* ****** ****** *) // // HX-2010-06-02: this is all deprecated!!! // (* ****** ****** *) fun gtk_progress_get_value {c:cls | c <= GtkProgress} {l:agz} ( progress: !gobjref (c, l) ) : gdouble = "mac#atsctrb_gtk_progress_get_value" // end of [gtk_progress_get_value] fun gtk_progress_set_value {c:cls | c <= GtkProgress} {l:agz} ( progress: !gobjref (c, l), value: gdouble ) : void = "mac#atsctrb_gtk_progress_set_value" // end of [gtk_progress_set_value] (* ****** ****** *) (* end of [gtkprogress.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhbox.sats0000664000175000017500000000321012223166165021762 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hbox_new ( homo: gboolean, spacing: gint ) : GtkHBox_ref1 = "mac#atsctrb_gtk_hbox_new" // end of [gtk_hbox_new] (* ****** ****** *) (* end of [gtkhbox.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkclipboard.sats0000664000175000017500000000363212223166165022771 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gtk_clipboard_get (selection: GdkAtom) : [l:agz] (GtkClipBoard_ref l - void | GtkClipBoard_ref l) = "mac#atsctrb_gtk_clipboard_get" // end of [gtk_clipboard_get] fun gtk_clipboard_wait_is_text_available {c:cls | c <= GtkClipBoard} {l:agz} (cb: !gobjref (c, l)): gboolean = "mac#atsctrb_gtk_clipboard_wait_is_text_available" // end of [gtk_clipboard_wait_is_text_available] (* ****** ****** *) (* end of [gtkclipboard.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkspinbutton.sats0000664000175000017500000001510312223166165023233 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abst@ype GtkSpinButtonUpdatePolicy = $extype"GtkSpinButtonUpdatePolicy" macdef GTK_UPDATE_ALWAYS = $extval (GtkSpinButtonUpdatePolicy, "GTK_UPDATE_ALWAYS") macdef GTK_UPDATE_IF_VALID = $extval (GtkSpinButtonUpdatePolicy, "GTK_UPDATE_IF_VALID") (* ****** ****** *) abst@ype GtkSpinType = $extype"GtkSpinType" macdef GTK_SPIN_STEP_FORWARD = $extval (GtkSpinType, "GTK_SPIN_STEP_FORWARD") macdef GTK_SPIN_STEP_BACKWARD = $extval (GtkSpinType, "GTK_SPIN_STEP_BACKWARD") macdef GTK_SPIN_PAGE_FORWARD = $extval (GtkSpinType, "GTK_SPIN_PAGE_FORWARD") macdef GTK_SPIN_PAGE_BACKWARD = $extval (GtkSpinType, "GTK_SPIN_PAGE_BACKWARD") macdef GTK_SPIN_HOME = $extval (GtkSpinType, "GTK_SPIN_HOME") macdef GTK_SPIN_END = $extval (GtkSpinType, "GTK_SPIN_END") macdef GTK_SPIN_USER_DEFINED = $extval (GtkSpinType, "GTK_SPIN_USER_DEFINED") (* ****** ****** *) fun gtk_spin_button_new {c:cls | c <= GtkAdjustment} {l:agz} ( adj: !gobjref (c, l) , rate: gdouble, digits: guint ) : GtkSpinButton_ref1 = "mac#atsctrb_gtk_spin_button_new" // end of [gtk_spin_button_new] (* ****** ****** *) fun gtk_spin_button_configure {c1,c2:cls | c1 <= GtkSpinButton; c2 <= GtkAdjustment} {l1,l2:agz} ( button: !gobjref (c1, l1) , adj: !gobjref (c2, l2) , rate: gdouble, digits: guint ) : void = "mac#atsctrb_gtk_spin_button_configure" // end of [gtk_spin_button_configure] (* ****** ****** *) fun gtk_spin_button_get_range {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) , min: &gdouble? >> gdouble , max: &gdouble? >> gdouble ) : void = "mac#atsctrb_gtk_spin_button_get_range" // end of [gtk_spin_button_get_range] fun gtk_spin_button_set_range {c:cls | c <= GtkSpinButton} {l:agz} (button: !gobjref (c, l), min: gdouble, max: gdouble): void = "mac#atsctrb_gtk_spin_button_set_range" // end of [gtk_spin_button_set_range] (* ****** ****** *) fun gtk_spin_button_get_value {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : gdouble = "mac#atsctrb_gtk_spin_button_get_value" // end of [gtk_spin_button_get_value] fun gtk_spin_button_get_value_as_int {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_spin_button_get_value_as_int" // end of [gtk_spin_button_get_value_as_int] fun gtk_spin_button_set_value {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l), value: gdouble ) : void = "mac#atsctrb_gtk_spin_button_set_value" // end of [gtk_spin_button_set_value] (* ****** ****** *) fun gtk_spin_button_get_digits {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : guint = "mac#atsctrb_gtk_spin_button_get_digits" // end of [gtk_spin_button_get_digits] fun gtk_spin_button_set_digits {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l), digits: guint ) : void = "mac#atsctrb_gtk_spin_button_set_digits" // end of [gtk_spin_button_set_digits] (* ****** ****** *) fun gtk_spin_button_get_numeric {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_spin_button_get_numeric" // end of [gtk_spin_button_get_numeric] fun gtk_spin_button_set_numeric {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l), numeric: gboolean ) : void = "mac#atsctrb_gtk_spin_button_set_numeric" // end of [gtk_spin_button_set_numeric] (* ****** ****** *) fun gtk_spin_button_get_wrap {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_spin_button_get_wrap" // end of [gtk_spin_button_get_wrap] fun gtk_spin_button_set_wrap {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l), wrap: gboolean ) : void = "mac#atsctrb_gtk_spin_button_set_wrap" // end of [gtk_spin_button_set_wrap] (* ****** ****** *) fun gtk_spin_button_get_snap_to_ticks {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_spin_button_get_snap_to_ticks" // end of [gtk_spin_button_get_snap_to_ticks] fun gtk_spin_button_set_snap_to_ticks {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l), s2t: gboolean ) : void = "mac#atsctrb_gtk_spin_button_set_snap_to_ticks" // end of [gtk_spin_button_set_snap_to_ticks] (* ****** ****** *) fun gtk_spin_button_get_update_policy {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) ) : GtkSpinButtonUpdatePolicy = "mac#atsctrb_gtk_spin_button_get_update_policy" // end of [gtk_spin_button_get_update_policy] fun gtk_spin_button_set_update_policy {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) , policy: GtkSpinButtonUpdatePolicy ) : void = "mac#atsctrb_gtk_spin_button_set_update_policy" // end of [gtk_spin_button_set_update_policy] (* ****** ****** *) fun gtk_spin_button_spin {c:cls | c <= GtkSpinButton} {l:agz} ( button: !gobjref (c, l) , dir: GtkSpinType, inc: gdouble ) : void = "mac#atsctrb_gtk_spin_button_spin" // end of [gtk_spin_button_spin] (* ****** ****** *) fun gtk_spin_button_update {c:cls | c <= GtkSpinButton} {l:agz} (button: !gobjref (c, l)) : void = "mac#atsctrb_gtk_spin_button_update" // end of [gtk_spin_button_update] (* ****** ****** *) (* end of [gtk_spin_button.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkaccelgroup.sats0000664000175000017500000000414112223166165023152 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abst@ype GtkAccelFlags = $extype"GtkAccelFlags" macdef GTK_ACCEL_LOCKED = $extval (GtkAccelFlags, "GTK_ACCEL_LOCKED") macdef GTK_ACCEL_MASK = $extval (GtkAccelFlags, "GTK_ACCEL_MASK") macdef GTK_ACCEL_VISIBLE = $extval (GtkAccelFlags, "GTK_ACCEL_VISIBLE") fun lor_GtkAccelFlags_GtkAccelFlags ( x1: GtkAccelFlags, x2: GtkAccelFlags ) :<> GtkAccelFlags = "atsctrb_lor_GtkAccelFlags_GtkAccelFlags" overload lor with lor_GtkAccelFlags_GtkAccelFlags (* ****** ****** *) fun gtk_accel_group_new (): GtkAccelGroup_ref1 = "mac#atsctrb_gtk_accel_group_new" // end of [gtk_accel_group_new] (* ****** ****** *) (* end of [gtkaccelgroup.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmenushell.sats0000664000175000017500000000525112223166165023025 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_menu_shell_append {c1,c2:cls | c1 <= GtkMenuShell; c2 <= GtkWidget} {l1,l2:agz} ( container: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_menu_shell_append" // end of [gtk_menu_shell_append] fun gtk_menu_shell_prepend {c1,c2:cls | c1 <= GtkMenuShell; c2 <= GtkWidget} {l1,l2:agz} ( container: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_menu_shell_prepend" // end of [gtk_menu_shell_prepend] (* ****** ****** *) fun gtk_menu_shell_select_item {c1,c2:cls | c1 <= GtkMenuShell; c2 <= GtkWidget} {l1,l2:agz} ( container: !gobjref (c1, l1), widget: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_menu_shell_select_item" // end of [gtk_menu_shell_select_item] fun gtk_menu_shell_select_first {c:cls | c <= GtkMenuShell} {l:agz} (container: !gobjref (c, l), search_sensitive: gboolean): void = "mac#atsctrb_gtk_menu_shell_select_first" // end of [gtk_menu_shell_select_first] (* ****** ****** *) fun gtk_menu_shell_deselect {c:cls | c <= GtkMenuShell} {l:agz} ( container: !gobjref (c, l) ) : void = "mac#atsctrb_gtk_menu_shell_deselect" // end of [gtk_menu_shell_deselect] (* ****** ****** *) (* end of [gtkmenushell.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktypeutils.sats0000664000175000017500000000313712223166165023074 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) typedef GtkFunction = (gpointer) - gboolean (* ****** ****** *) (* end of [gtktypeutils.sats] *) (* ****** ****** *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktextmark.sats0000664000175000017500000000304512223166165022667 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) // it is still empty (* ****** ****** *) (* end of [gtktextmark.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkstatusbar.sats0000664000175000017500000000565712223166165023053 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_statusbar_new (): GtkStatusbar_ref1 = "mac#atsctrb_gtk_statusbar_new" // end of [gtk_statusbar_new] fun gtk_statusbar_get_context_id {c:cls | c <= GtkStatusbar} {l1,l2:agz} ( bar: !gobjref (c, l1) , context: !gstring l2 ) : guint = "mac#atsctrb_gtk_statusbar_get_context_id" // end of [gtk_statusbar_get_context_id] (* ****** ****** *) fun gtk_statusbar_push {c:cls | c <= GtkStatusbar} {l1,l2:agz} ( bar: !gobjref (c, l1) , context_id: guint , text: !gstring l2 ) : guint(*msgid*) = "mac#atsctrb_gtk_statusbar_push" // end of [gtk_statusbar_push] fun gtk_statusbar_pop {c:cls | c <= GtkStatusbar} {l:agz} ( bar: !gobjref (c, l), context_id: guint ) : void = "mac#atsctrb_gtk_statusbar_pop" // end of [gtk_statusbar_pop] fun gtk_statusbar_remove {c:cls | c <= GtkStatusbar} {l:agz} ( bar: !gobjref (c, l) , context_id: guint , message_id: guint ) : void = "mac#atsctrb_gtk_statusbar_remove" // end of [gtk_statusbar_remvoe] (* ****** ****** *) fun gtk_statusbar_get_has_resize_grip {c:cls | c <= GtkStatusbar} {l:agz} ( bar: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_statusbar_get_has_resize_grip" // end of [gtk_statusbar_get_has_resize_grip] fun gtk_statusbar_set_has_resize_grip {c:cls | c <= GtkStatusbar} {l:agz} ( bar: !gobjref (c, l), setting: gboolean ) : void = "mac#atsctrb_gtk_statusbar_set_has_resize_grip" // end of [gtk_statusbar_set_has_resize_grip] (* ****** ****** *) (* end of [gtkstatusbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkstyle.sats0000664000175000017500000000735512223166165022200 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) (* struct _GtkStyle { GObject parent_instance; /*< public >*/ GdkColor fg[5]; GdkColor bg[5]; GdkColor light[5]; GdkColor dark[5]; GdkColor mid[5]; GdkColor text[5]; GdkColor base[5]; GdkColor text_aa[5]; /* Halfway between text/base */ GdkColor black; GdkColor white; PangoFontDescription *font_desc; gint xthickness; gint ythickness; GdkGC *fg_gc[5]; GdkGC *bg_gc[5]; GdkGC *light_gc[5]; GdkGC *dark_gc[5]; GdkGC *mid_gc[5]; GdkGC *text_gc[5]; GdkGC *base_gc[5]; GdkGC *text_aa_gc[5]; GdkGC *black_gc; GdkGC *white_gc; GdkPixmap *bg_pixmap[5]; /*< private >*/ gint attach_count; gint depth; GdkColormap *colormap; GdkFont *private_font; PangoFontDescription *private_font_desc; /* Font description for style->private_font or %NULL */ /* the RcStyle from which this style was created */ GtkRcStyle *rc_style; GSList *styles; /* of type GtkStyle* */ GArray *property_cache; GSList *icon_factories; /* of type GtkIconFactory* */ }; *) (* ****** ****** *) fun gtk_style_get_text_aa {c:cls | c <= GtkStyle} {l:agz} (x: !gobjref (c, l)): [l1:addr] ( minus (gobjref (c, l), array_v (GdkColor, 5, l1)), array_v (GdkColor, 5, l1) | ptr l1 ) = "atsctrb_gtk_style_get_text_aa" // a function // end of [gtk_style_get_text_aa] fun gtk_style_get_font_desc {c:cls | c <= GtkStyle} {l:agz} (x: !gobjref (c, l)): [l1:addr] ( minus (gobjref (c, l), PangoFontDescription_ptr l1) | PangoFontDescription_ptr l1 ) = "atsctrb_gtk_style_get_font_desc" // a function // end of [gtk_style_get_font_desc] (* ****** ****** *) fun gtk_style_new (): GtkStyle_ref1 = "mac#atsctrb_gtk_style_new" // end of [gtk_style_new] fun gtk_style_copy {c:cls | c <= GtkStyle} {l:agz} ( x: !gobjref (c, l) ) : GtkStyle_ref1 = "mac#atsctrb_gtk_style_copy" // end of [gtk_style_copy] (* ****** ****** *) fun gtk_style_attach {c1,c2:cls | c1 <= GtkStyle; c2 <= GdkWindow} {l1,l2:agz} ( x: gobjref (c1, l1), win: !gobjref (GdkWindow, l2) ) : GtkStyle_ref1 = "mac#atsctrb_gtk_style_attach" // end of [gtk_style_attach] fun gtk_style_detach {c:cls | c <= GtkStyle} {l:agz} ( x: !gobjref (c, l) ) : void = "mac#atsctrb_gtk_style_detach" // end of [gtk_style_detach] (* ****** ****** *) (* end of [gtkstyle.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkscrolledwindow.sats0000664000175000017500000000607012223166165024070 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: May, 2010 // (* ****** ****** *) // // HX-2010-05-03: [hadj] and [vadj] can be NULL // if NULL is used, an adjustment is to be created by the [new] function // fun gtk_scrolled_window_new {c1,c2:cls | c1 <= GtkAdjustment; c2 <= GtkAdjustment} {l1,l2:addr} ( hadj: !gobjref (c1, l1) , vadj: !gobjref (c2, l2) ) : GtkScrolledWindow_ref1 = "atsctrb_gtk_scrolled_window_new" // end of [gtk_scrolled_window_new] fun gtk_scrolled_window_new_null (): GtkScrolledWindow_ref1 = "atsctrb_gtk_scrolled_window_new_null" // end of [gtk_scrolled_window_new_null] (* ****** ****** *) fun gtk_scrolled_window_get_policy {c:cls | c <= GtkScrolledWindow} {l:agz} ( win: !gobjref (c, l) , hp: &GtkPolicyType? >> GtkPolicyType , vp: &GtkPolicyType? >> GtkPolicyType ) : void = "mac#atsctrb_gtk_scrolled_window_get_policy" // end of [gtk_scrolled_window_get_policy] fun gtk_scrolled_window_set_policy {c:cls | c <= GtkScrolledWindow} {l:agz} ( win: !gobjref (c, l) , hp: GtkPolicyType , vp: GtkPolicyType ) : void = "mac#atsctrb_gtk_scrolled_window_set_policy" // end of [gtk_scrolled_window_set_policy] (* ****** ****** *) fun gtk_scrolled_window_get_placement {c:cls | c <= GtkScrolledWindow} {l:agz} ( win: !gobjref (c, l) ) : GtkCornerType = "mac#atsctrb_gtk_scrolled_window_get_placement" // end of [gtk_scrolled_window_get_placement] fun gtk_scrolled_window_set_placement {c:cls | c <= GtkScrolledWindow} {l:agz} ( win: !gobjref (c, l), placement: GtkCornerType ) : void = "mac#atsctrb_gtk_scrolled_window_set_placement" // end of [gtk_scrolled_window_set_placement] (* ****** ****** *) (* end of [gtkscrolledwindow.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkbox.sats0000664000175000017500000000403012223166165021613 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_box_pack_start {c1,c2:cls | c1 <= GtkBox; c2 <= GtkWidget} {l1,l2:agz} ( box: !gobjref (c1, l1) , child: !gobjref (c2, l2) , expand: gboolean, fill: gboolean, padding: guint ) : void = "mac#atsctrb_gtk_box_pack_start" // end of [gtk_box_pack_start] fun gtk_box_pack_end {c1,c2:cls | c1 <= GtkBox; c2 <= GtkWidget} {l1,l2:agz} ( box: !gobjref (c1, l1) , child: !gobjref (c2, l2) , expand: gboolean, fill: gboolean, padding: guint ) : void = "mac#atsctrb_gtk_box_pack_end" // end of [gtk_box_pack_end] (* ****** ****** *) (* end of [gtkbox.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkimagemenuitem.sats0000664000175000017500000000501112223166165023651 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_image_menu_item_new (): GtkImageMenuItem_ref1 = "mac#atsctrb_gtk_image_menu_item_new" // end of [gtk_image_menu_item_new] fun gtk_image_menu_item_new_with_label {l:agz} (name: !gstring l): GtkImageMenuItem_ref1 = "mac#atsctrb_gtk_image_menu_item_new_with_label" // end of [gtk_image_menu_item_new_with_label] fun gtk_image_menu_item_new_with_mnemonic {l:agz} (name: !gstring l): GtkImageMenuItem_ref1 = "mac#atsctrb_gtk_image_menu_item_new_with_mnemonic" // end of [gtk_image_menu_item_new_with_mnemonic] (* ****** ****** *) fun gtk_image_menu_item_new_from_stock {c:cls | c <= GtkAccelGroup} {l1:agz;l2:addr} (name: !gstring l1, aclgrp: !gobjref (c, l2)): GtkImageMenuItem_ref1 = "mac#atsctrb_gtk_image_menu_item_new_from_stock" // end of [gtk_image_menu_item_new_from_stock] fun gtk_image_menu_item_new_from_stock_null {l:agz} (name: !gstring l): GtkImageMenuItem_ref1 = "mac#atsctrb_gtk_image_menu_item_new_from_stock_null" // end of [gtk_image_menu_item_new_from_stock_null] (* ****** ****** *) (* end of [gtkimagemenuitem.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkprogressbar.sats0000664000175000017500000001223712223166165023364 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June, 2010 // (* ****** ****** *) abst@ype GtkProgressBarStyle = $extype"GtkProgressBarStyle" macdef GTK_PROGRESS_CONTINUOUS = $extval (GtkProgressBarStyle, "GTK_PROGRESS_CONTINUOUS") macdef GTK_PROGRESS_DISCRETE = $extval (GtkProgressBarStyle, "GTK_PROGRESS_DISCRETE") abst@ype GtkProgressBarOrientation = $extype"GtkProgressBarOrientation" macdef GTK_PROGRESS_LEFT_TO_RIGHT = $extval (GtkProgressBarOrientation, "GTK_PROGRESS_LEFT_TO_RIGHT") macdef GTK_PROGRESS_RIGHT_TO_LEFT = $extval (GtkProgressBarOrientation, "GTK_PROGRESS_RIGHT_TO_LEFT") macdef GTK_PROGRESS_BOTTOM_TO_TOP = $extval (GtkProgressBarOrientation, "GTK_PROGRESS_BOTTOM_TO_TOP") macdef GTK_PROGRESS_TOP_TO_BOTTOM = $extval (GtkProgressBarOrientation, "GTK_PROGRESS_TOP_TO_BOTTOM") (* ****** ****** *) fun gtk_progress_bar_new (): GtkProgressBar_ref1 = "mac#atsctrb_gtk_progress_bar_new" // end of [gtk_progress_bar_new] // // HX-2010-06-03: this one is deprecated! // HX-2010-06-03: checked: [adj] can be NULL // fun gtk_progress_bar_new_with_adjustment {c:cls | c <= GtkAdjustment} {l:addr} ( adj: !gobjref (c, l) ) : GtkProgressBar_ref1 = "mac#atsctrb_gtk_progress_bar_new_with_adjustment" // end of [gtk_progress_bar_new_with_adjustment] (* ****** ****** *) fun gtk_progress_bar_pulse {c:cls | c <= GtkProgressBar} {l:agz} ( pbar: !gobjref (c, l) ) : void = "mac#atsctrb_gtk_progress_bar_pulse" // end of [gtk_progress_bar_pulse] (* ****** ****** *) fun gtk_progress_bar_get_text {c:cls | c <= GtkProgressBar} {l:agz} ( pbar: !gobjref (c, l) ) : [l1:addr] ( minus (gobjref (c, l), gstring l1) | gstring l1 ) = "mac#atsctrb_gtk_progress_bar_get_text" // end of [gtk_progress_bar_get_text] fun gtk_progress_bar_set_text {c:cls | c <= GtkProgressBar} {l,l1:addr | l > null} (pbar: !gobjref (c, l), text: !gstring l1): void = "mac#atsctrb_gtk_progress_bar_set_text" // end of [gtk_progress_bar_set_text] (* ****** ****** *) fun gtk_progress_bar_get_fraction {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l)): gdouble = "mac#atsctrb_gtk_progress_bar_get_fraction" // end of [gtk_progress_bar_get_fraction] fun gtk_progress_bar_set_fraction {c:cls | c <= GtkProgressBar} {l:agz} ( pbar: !gobjref (c, l), frac: gdouble ) : void = "mac#atsctrb_gtk_progress_bar_set_fraction" // end of [gtk_progress_bar_set_fraction] (* ****** ****** *) fun gtk_progress_bar_get_pulse_step {c:cls | c <= GtkProgressBar} {l:agz} ( pbar: !gobjref (c, l) ) : gdouble = "mac#atsctrb_gtk_progress_bar_get_pulse_step" // end of [gtk_progress_bar_get_pulse_step] fun gtk_progress_bar_set_pulse_step {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l), frac: gdouble): void = "mac#atsctrb_gtk_progress_bar_set_pulse_step" // end of [gtk_progress_bar_set_pulse_step] (* ****** ****** *) fun gtk_progress_bar_get_orientation {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l)): GtkProgressBarOrientation = "mac#atsctrb_gtk_progress_bar_get_orientation" // end of [gtk_progress_bar_get_orientation] fun gtk_progress_bar_set_orientation {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l), orient: GtkProgressBarOrientation): void = "mac#atsctrb_gtk_progress_bar_set_orientation" // end of [gtk_progress_bar_set_orientation] (* ****** ****** *) fun gtk_progress_bar_get_ellipsize {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l)): PangoEllipsizeMode = "mac#atsctrb_gtk_progress_bar_get_ellipsize" // end of [gtk_progress_bar_get_ellipsize] fun gtk_progress_bar_set_ellipsize {c:cls | c <= GtkProgressBar} {l:agz} (pbar: !gobjref (c, l), mode: PangoEllipsizeMode): void = "mac#atsctrb_gtk_progress_bar_set_ellipsize" // end of [gtk_progress_bar_set_ellipsize] (* ****** ****** *) (* end of [gtkprogressbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkbutton.sats0000664000175000017500000000531312223166165022343 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_button_new (): GtkButton_ref1 = "mac#atsctrb_gtk_button_new" // end of [gtk_button_new] fun gtk_button_new_with_label {l:agz} (label: !gstring l): GtkButton_ref1 = "mac#atsctrb_gtk_button_new_with_label" // end of [gtk_button_new_with_label] fun gtk_button_new_with_mnemonic {l:agz} (label: !gstring l): GtkButton_ref1 = "mac#atsctrb_gtk_button_new_with_mnemonic" // end of [gtk_button_new_with_mnemonic] fun gtk_button_new_from_stock {l:agz} (stock_id: !gstring l): GtkButton_ref1 = "mac#atsctrb_gtk_button_new_from_stock" // end of [gtk_button_new_from_stock] (* ****** ****** *) // // HX-2010-04-26: the label string belongs to the widget! // HX-2010-05-07: the label string can be NULL (if it is not set) // fun gtk_button_get_label {c:cls | c <= GtkButton} {l1:agz} ( widget: !gobjref (c, l1) ) : [l2:addr] ( minus (gobjref (c, l1), gstring l2) | gstring l2 ) = "mac#atsctrb_gtk_button_get_label" (* ****** ****** *) // // HX-2010-05-07: checked: label = NULL -> label = "" // fun gtk_button_set_label {c:cls | c <= GtkButton} {l1,l2:agz} ( widget: !gobjref (c, l1) , label: gstring l2 ) : void = "mac#atsctrb_gtk_button_set_label" // end of [gtk_button_set_label] (* ****** ****** *) (* end of [gtkbutton.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkwidget.sats0000664000175000017500000002415612223166165022321 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) typedef GtkAllocation = $extype_struct "GtkAllocation" of { x= gint , y= gint , width= gint , height= gint } // end of [GtkAllocation] (* ****** ****** *) // // HX: GtkAllocation and GdkRectangle are the same! // praxi GtkAllocation2GdkRectangle {l:addr} (pf: GtkAllocation @ l): GdkRectangle @ l praxi GdkRectangle2GtkAllocation {l:addr} (pf: GdkRectangle @ l): GtkAllocation @ l (* ****** ****** *) abst@ype GTK_WIDGET_FLAG = guint macdef GTK_CAN_DEFAULT = $extval (GTK_WIDGET_FLAG, "GTK_CAN_DEFAULT") fun GTK_WIDGET_SET_FLAGS {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), flag: GTK_WIDGET_FLAG): void = "mac#atsctrb_GTK_WIDGET_SET_FLAGS" // end of [GTK_WIDGET_SET_FLAGS] (* ****** ****** *) fun GTK_WIDGET_STATE {c:cls | c <= GtkWidget} {l:agz} (wid: !gobjref (c, l)): GtkStateType = "mac#atsctrb_GTK_WIDGET_STATE" // end of [GTK_WIDGET_STATE] fun GTK_WIDGET_SAVED_STATE {c:cls | c <= GtkWidget} {l:agz} (wid: !gobjref (c, l)): GtkStateType = "mac#atsctrb_GTK_WIDGET_SAVED_STATE" // end of [GTK_WIDGET_SAVED_STATE] (* ****** ****** *) // // HX: ref-count is unaffected! // fun gtk_widget_destroy {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l) ) : void = "mac#atsctrb_gtk_widget_destroy" // end of [gtk_widget_destroy] // // HX: [gtk_widget_destroy0] consumes the gobject! // fun gtk_widget_destroy0 {c:cls | c <= GtkWidget} {l:agz} ( widget: gobjref (c, l) ) : void = "mac#atsctrb_gtk_widget_destroy" // end of [gtk_widget_destroy0] (* ****** ****** *) fun gtk_widget_map {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_map" fun gtk_widget_unmap {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_unmap" (* ****** ****** *) fun gtk_widget_realize {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_realize" fun gtk_widget_unrealize {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_unrealize" (* ****** ****** *) fun gtk_widget_show {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_show" // // HX-2010-05-08: // this one is implemented in [gtk.dats] // it seems to be a commonly used combination // fun gtk_widget_show_unref {c:cls | c <= GtkWidget} {l:agz} (widget: gobjref (c, l)): void // end of [gtk_widget_show_unref] (* ****** ****** *) fun gtk_widget_show_now {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_show_now" fun gtk_widget_show_all {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_show_all" (* ****** ****** *) fun gtk_widget_hide {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_hide" (* ****** ****** *) fun gtk_widget_get_sensitive {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_widget_get_sensitive" // end of [gtk_widget_get_sensitive] fun gtk_widget_set_sensitive {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), sensitive: gboolean): void = "mac#atsctrb_gtk_widget_set_sensitive" // end of [gtk_widget_set_sensitive] (* ****** ****** *) // // HX: negative width/height can have special meaning // fun gtk_widget_set_size_request {c:cls | c <= GtkWidget} {l:agz} ( widegt: !gobjref (c, l), width: gint, height: gint ) : void = "mac#atsctrb_gtk_widget_set_size_request" // end of [gtk_widget_set_size_request] (* ****** ****** *) fun gtk_widget_grab_focus {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_grab_focus" // end of [gtk_widget_grab_focus] fun gtk_widget_grab_default {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): void = "mac#atsctrb_gtk_widget_grab_default" // end of [gtk_widget_grab_default] (* ****** ****** *) fun gtk_widget_set_events {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l), events: gint ) : void = "mac#atsctrb_gtk_widget_set_events" // end of [gtk_widget_set_events] (* ****** ****** *) fun gtk_widget_add_accelerator {c1,c2:cls | c1 <= GtkWidget; c2 <= GtkAccelGroup} {l1,l2:agz} ( widget: !gobjref (c1, l1) , signal: gsignal , aclgrp: !gobjref (c2, l2) , aclkey: guint , aclmod: GdkModifierType , aclflg: GtkAccelFlags ) : void = "mac#atsctrb_gtk_widget_add_accelerator" // end of [gtk_widget_add_accelerator] fun gtk_widget_remove_accelerator {c1,c2:cls | c1 <= GtkWidget; c2 <= GtkAccelGroup} {l1,l2:agz} ( widget: !gobjref (c1, l1) , aclgrp: !gobjref (c2, l2) , aclkey: guint , aclmod: GdkModifierType ) : void = "mac#atsctrb_gtk_widget_remove_accelerator" // end of [gtk_widget_remove_accelerator] (* ****** ****** *) // // HX-2010-04-18: // it gets GDK window! // this is probably safe enough :) // fun gtk_widget_get_window {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l) ) : [l_win:addr] ( minus (gobjref (c, l), gobjref (GdkWindow, l_win)) | gobjref (GdkWindow, l_win) ) = "atsctrb_gtk_widget_get_window" // function! // end of [gtk_widget_get_window] (* ****** ****** *) // HX: since GTK-2.18 fun gtk_widget_get_allocation {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l) , alloc: &GtkAllocation? >> GtkAllocation ) : void = "mac#atsctrb_gtk_widget_get_allocation" // end of [gtk_widget_get_allocation] // HX: since GTK-2.18 fun gtk_widget_set_allocation {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l), alloc: &GtkAllocation ) : void = "mac#atsctrb_gtk_widget_set_allocation" // end of [gtk_widget_set_allocation] fun gtk_widget_getref_allocation {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)) : [l_alloc:addr] ( GtkAllocation @ l_alloc , minus (gobjref (c, l), GtkAllocation @ l_alloc) | ptr l_alloc ) = "atsctrb_gtk_widget_getref_allocation" // function! // end of [gtk_widget_getref_allocation] (* ****** ****** *) fun gtk_widget_modify_fg {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), state: GtkStateType, color: &GdkColor): void = "mac#atsctrb_gtk_widget_modify_fg" // end of [gtk_widget_modify_fg] fun gtk_widget_modify_bg {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), state: GtkStateType, color: &GdkColor): void = "mac#atsctrb_gtk_widget_modify_bg" // end of [gtk_widget_modify_bg] (* ****** ****** *) fun gtk_widget_get_toplevel {c:cls | c <= GtkWidget} {l:agz} ( widget: !gobjref (c, l) ) : [c1:cls;l1:agz | c1 <= GtkWidget] ( gobjref (c1, l1) - void | gobjref (c1, l1) ) = "mac#atsctrb_gtk_widget_get_toplevel" // end of [gtk_widget_get_toplevel] (* ****** ****** *) // // HX-2010-05-13: checked: this is a 'get0' function // fun gtk_widget_get_colormap {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), GdkColormap_ref l1) | GdkColormap_ref l1 ) = "mac#atsctrb_gtk_widget_get_colormap" // end of [gtk_widget_get_colormap] (* ****** ****** *) fun gtk_widget_modify_font {c:cls | c <= GtkWidget} {l1,l2:agz} (widget: !gobjref (c, l1), fd: !PangoFontDescription_ptr l2): void = "mac#atsctrb_gtk_widget_modify_font" // end of [gtk_widget_modify_font] (* ****** ****** *) fun gtk_widget_queue_draw_area {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), x: gint, y: gint, width: gint, height: gint): void = "mac#atsctrb_gtk_widget_queue_draw_area" // end of [gtk_widget_queue_draw_area] (* ****** ****** *) fun gtk_widget_create_pango_context {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): PangoContext_ref1 = "mac#atsctrb_gtk_widget_create_pango_context" // end of [gtk_widget_create_pango_context] fun gtk_widget_get_pango_context {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), PangoContext_ref l1) | PangoContext_ref l1 ) = "mac#atsctrb_gtk_widget_get_pango_context" // end of [gtk_widget_get_pango_context] (* ****** ****** *) fun gtk_widget_create_pango_layout {c:cls | c <= GtkWidget} {l1,l2:agz} (widget: !gobjref (c, l1), text: !gstring l2): PangoLayout_ref1 = "mac#atsctrb_gtk_widget_create_pango_layout" // end of [gtk_widget_create_pango_layout] (* ****** ****** *) // // HX-2010-05-24: style may not be set // fun gtk_widget_get_style {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l)): [l1:addr] ( minus (gobjref (c, l), gobjref (GtkStyle, l1)) | gobjref (GtkStyle, l1) ) = "mac#atsctrb_gtk_widget_get_style" // end of [gtk_widget_get_style] fun gtk_widget_set_style {c1,c2:cls | c1 <= GtkWidget; c2 <= GtkStyle} {l1,l2:agz} (widget: !gobjref (c1, l1), style: gobjref (c2, l2)): void = "mac#atsctrb_gtk_widget_set_style" // end of [gtk_widget_set_style] (* ****** ****** *) (* end of [gtkwidget.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmessagedialog.sats0000664000175000017500000000774612223166165023650 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: May, 2010 // (* ****** ****** *) abst@ype GtkMessageType = $extype"GtkMessageType" macdef GTK_MESSAGE_INFO = $extval (GtkMessageType, "GTK_MESSAGE_INFO") macdef GTK_MESSAGE_WARNING = $extval (GtkMessageType, "GTK_MESSAGE_WARNING") macdef GTK_MESSAGE_QUESTION = $extval (GtkMessageType, "GTK_MESSAGE_QUESTION") macdef GTK_MESSAGE_ERROR = $extval (GtkMessageType, "GTK_MESSAGE_ERROR") macdef GTK_MESSAGE_OTHER = $extval (GtkMessageType, "GTK_MESSAGE_OTHER") (* ****** ****** *) abst@ype GtkButtonsType = $extype"GtkButtonsType" macdef GTK_BUTTONS_NONE = $extval (GtkButtonsType, "GTK_BUTTONS_NONE") macdef GTK_BUTTONS_OK = $extval (GtkButtonsType, "GTK_BUTTONS_OK") macdef GTK_BUTTONS_CLOSE = $extval (GtkButtonsType, "GTK_BUTTONS_CLOSE") macdef GTK_BUTTONS_CANCEL = $extval (GtkButtonsType, "GTK_BUTTONS_CANCEL") macdef GTK_BUTTONS_YES_NO = $extval (GtkButtonsType, "GTK_BUTTONS_YES_NO") macdef GTK_BUTTONS_OK_CANCEL = $extval (GtkButtonsType, "GTK_BUTTONS_OK_CANCEL") (* ****** ****** *) // // HX-2010-05: these are just slightly simplified versions // fun gtk_message_dialog_new0 {l:addr} ( flags: GtkDialogFlags , _type: GtkMessageType , buttons: GtkButtonsType , message: !gstring l ) : GtkMessageDialog_ref1 = "atsctrb_gtk_message_dialog_new0" // function! // end of [gtk_message_dialog_new] fun gtk_message_dialog_new0_with_markup {l:addr} ( flags: GtkDialogFlags , _type: GtkMessageType , buttons: GtkButtonsType , message: !gstring l ) : GtkMessageDialog_ref1 = "atsctrb_gtk_message_dialog_new0_with_markup" // function! // end of [gtk_message_dialog_new0_with_markup] (* ****** ****** *) fun gtk_message_dialog_set_markup {c:cls | c <= GtkMessageDialog} {l1,l2:agz} ( dialog: !gobjref (c, l1), markup: !gstring l2 ) : void = "mac#atsctrb_gtk_message_dialog_set_markup" // macro // end of [gtk_message_dialog_set_markup] (* ****** ****** *) // // HX-2010-05-26: checked: this is a 'get0' function // fun gtk_messgage_dialog_get_image {c:cls | c <= GtkMessageDialog} {l:agz} (dialog: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), gobjref (GtkImage, l1)) | gobjref (GtkImage, l1) ) = "mac#atsctrb_gtk_messgage_dialog_get_image" // end of [gtk_messgage_dialog_get_image] // // HX-2010-05-26: checked: [image] can be NULL! // fun gtk_messgage_dialog_set_image {c1,c2:cls | c1 <= GtkMessageDialog; c2 <= GtkImage} {l1,l2:addr | l1 > null} ( dialog: !gobjref (c1, l1), image: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_messgage_dialog_set_image" // end of [gtk_messgage_dialog_set_image] (* ****** ****** *) (* end of [gtkmessagedialog.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmenubar.sats0000664000175000017500000000317012223166165022460 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_menu_bar_new (): GtkMenuBar_ref1 = "mac#atsctrb_gtk_menu_bar_new" // end of [gtk_menu_bar_new] (* ****** ****** *) (* end of [gtkmenubar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkfontsel.sats0000664000175000017500000001054712223166165022507 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: May, 2010 // (* ****** ****** *) fun gtk_font_selection_new () : GtkFontSelection_ref1 = "atsctrb_gtk_font_selection_new" // function! // end of [gtk_font_selection_new] (* ****** ****** *) // // HX-2010-05-25: // this is a 'get0' functionl; the return value cannot be NULL // fun gtk_font_selection_get_preview_text {c:cls | c <= GtkFontSelection} {l:agz} (fsd: !gobjref (c, l)) : [l1:agz] ( minus (gobjref (c, l), gstring l1) | gstring l1 ) = "mac#atsctrb_gtk_font_selection_get_preview_text" fun gtk_font_selection_set_preview_text {c:cls | c <= GtkFontSelection} {l,l1:agz} ( fsd: !gobjref (c, l), text: !gstring l1 ) : void = "mac#atsctrb_gtk_font_selection_set_preview_text" // end of [fun] (* ****** ****** *) // // HX-2010-05-25: [title] can be NULL // fun gtk_font_selection_dialog_new {l:addr} (title: !gstring l): GtkFontSelectionDialog_ref1 = "atsctrb_gtk_font_selection_dialog_new" // function! // end of [gtk_font_selection_dialog_new] (* ****** ****** *) // HX: this is a 'get0' function fun gtk_font_selection_dialog_get_ok_button {c:cls | c <= GtkFontSelectionDialog} {l:agz} (fsd: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), GtkButton_ref l1) | GtkButton_ref l1 ) = "mac#atsctrb_gtk_font_selection_dialog_get_ok_button" // end of [gtk_font_selection_dialog_get_ok_button] // HX: this is a 'get0' function fun gtk_font_selection_dialog_get_cancel_button {c:cls | c <= GtkFontSelectionDialog} {l:agz} (fsd: !gobjref (c, l)): [l1:agz] ( minus (gobjref (c, l), GtkButton_ref l1) | GtkButton_ref l1 ) = "mac#atsctrb_gtk_font_selection_dialog_get_cancel_button" // end of [gtk_font_selection_dialog_get_cancel_button] (* ****** ****** *) // HX-2010-05-25: the return value can be NULL fun gtk_font_selection_dialog_get_font_name {c:cls | c <= GtkFontSelectionDialog} {l:agz} (fsd: !gobjref (c, l)): gstring0 = "mac#atsctrb_gtk_font_selection_dialog_get_font_name" // end of [gtk_font_selection_dialog_get_font_name] fun gtk_font_selection_dialog_set_font_name {c:cls | c <= GtkFontSelectionDialog} {l,l1:agz} ( fsd: !gobjref (c, l), fontname: !gstring l1 ) : gboolean = "mac#atsctrb_gtk_font_selection_dialog_set_font_name" // end of [gtk_font_selection_dialog_set_font_name] (* ****** ****** *) // HX-2010-05-25: // this is a 'get0' functionl; the return value cannot be NULL fun gtk_font_selection_dialog_get_preview_text {c:cls | c <= GtkFontSelectionDialog} {l:agz} ( fsd: !gobjref (c, l) ) : [l1:agz] ( minus (gobjref (c, l), gstring l1) | gstring l1 ) = "mac#atsctrb_gtk_font_selection_dialog_get_preview_text" // end of [gtk_font_selection_dialog_get_preview_text] fun gtk_font_selection_dialog_set_preview_text {c:cls | c <= GtkFontSelectionDialog} {l,l1:agz} ( fsd: !gobjref (c, l), text: !gstring l1 ) : void = "mac#atsctrb_gtk_font_selection_dialog_set_preview_text" // end of [gtk_font_selection_dialog_set_preview_text] (* ****** ****** *) (* end of [gtkfontsel.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkwindow.sats0000664000175000017500000001464712223166165022351 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) fun GTK_IS_WINDOW {c:cls | c <= GObject} {l:agz} ( x: !gobjref (c, l) ) : bool (c <= GtkWindow) = "mac#atsctrb_GTK_IS_WINDOW" // end of [GTK_IS_WINDOW] (* ****** ****** *) // // HX-2011-10: // the ref-count of the created window is 2! // fun gtk_window_new (tp: GtkWindowType) : GtkWindow_ref1 = "mac#atsctrb_gtk_window_new" // end of [gtk_window_new] (* ****** ****** *) // // HX-2010-05-14: checked: this is a 'get0' function // fun gtk_window_get_title {c:cls | c <= GtkWindow} {l1:agz} ( window: !gobjref (c, l1) ) : [l2:addr] ( minus (gobjref (c, l1), gstring l2) | gstring l2 ) = "mac#atsctrb_gtk_window_get_title" fun gtk_window_set_title {c:cls | c <= GtkWindow} {l1,l2:agz} ( window: !gobjref (c, l1), title: !gstring l2 ) : void = "mac#atsctrb_gtk_window_set_title" (* ****** ****** *) fun gtk_window_set_position {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) , pos: GtkWindowPosition ) : void = "mac#atsctrb_gtk_window_set_position" // end of [gtk_window_set_position] (* ****** ****** *) fun gtk_window_get_transient_for {c1:cls | c1 <= GtkWindow} {l1:agz} ( window: !gobjref (c1, l1) ) : [c2:cls;l2:addr | c2 <= GtkWindow] ( minus (gobjref (c1, l1), gobjref (c2, l2)) | gobjref (c2, l2) ) = "mac#atsctrb_gtk_window_get_transient_for" // end of [gtk_window_get_transient_for] fun gtk_window_set_transient_for {c1,c2:cls | c1 <= GtkWindow; c2 <= GtkWindow} {l1,l2:agz} ( window: !gobjref (c1, l1), parent: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_window_set_transient_for" // end of [gtk_window_set_transient_for] (* ****** ****** *) fun gtk_window_get_size {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) , width: &gint? >> gint, height: &gint? >> gint ) : void = "mac#atsctrb_gtk_window_get_size" // end of [gtk_window_get_size] (* ****** ****** *) // // HX: // [width = -1] means unset // [height = -1] means unset // fun gtk_window_set_default_size {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), width: gint, height: gint ) : void = "mac#atsctrb_gtk_window_set_default_size" // end of [gtk_window_set_default_size] (* ****** ****** *) fun gtk_window_get_resizable {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_window_get_resizeable" // end of [gtk_window_get_resizeable] fun gtk_window_set_resizable {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), resizable: gboolean ) : void = "mac#atsctrb_gtk_window_set_resizable" // end of [gtk_window_set_resizable] (* ****** ****** *) fun gtk_window_add_accel_group {c1,c2:cls | c1 <= GtkWindow; c2 <= GtkAccelGroup} {l1,l2:agz} ( window: !gobjref (c1, l1), aclgrp: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_window_add_accel_group" // end of [gtk_window_add_accel_group] fun gtk_window_remove_accel_group {c1,c2:cls | c1 <= GtkWindow; c2 <= GtkAccelGroup} {l1,l2:agz} ( window: !gobjref (c1, l1), aclgrp: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_window_remove_accel_group" // end of [gtk_window_remove_accel_group] (* ****** ****** *) fun gtk_window_get_window_type {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : GtkWindowType = "mac#atsctrb_gtk_window_get_window_type" // end of [gtk_window_get_window_type] (* ****** ****** *) fun gtk_window_get_type_hint {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : GdkWindowTypeHint = "mac#atsctrb_gtk_window_get_type_hint" // end of [gtk_window_get_type_hint] (* ****** ****** *) fun gtk_window_move {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), x: gint, y: gint ) : void = "mac#atsctrb_gtk_window_move" // end of [gtk_window_move] (* ****** ****** *) fun gtk_window_reshow_with_initial_size {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : void = "mac#atsctrb_gtk_window_reshow_with_initial_size" // end of [gtk_window_reshow_with_initial_size] fun gtk_window_resize {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), width: gint, height: gint ) : void = "mac#atsctrb_gtk_window_resize" // end of [gtk_window_resize] (* ****** ****** *) fun gtk_window_get_opacity {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : gdouble = "mac#atsctrb_gtk_window_get_opacity" // end of [gtk_window_get_opacity] fun gtk_window_set_opacity {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), opacity: gdouble ) : void = "mac#atsctrb_gtk_window_set_opacity" // end of [gtk_window_set_opacity] (* ****** ****** *) fun gtk_window_get_mnemonics_visible {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_window_get_mnemonics_visible" // end of [gtk_window_get_mnemonics_visible] fun gtk_window_set_mnemonics_visible {c:cls | c <= GtkWindow} {l:agz} ( window: !gobjref (c, l), visible: gboolean ) : void = "mac#atsctrb_gtk_window_set_mnemonics_visible" // end of [gtk_window_set_mnemonics_visible] (* ****** ****** *) (* end of [gtkwindow.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktextiter.sats0000664000175000017500000000654112223166165022704 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_text_iter_is_start ( iter: &GtkTextIter ) : gboolean = "mac#atsctrb_gtk_text_iter_is_start" // end of [gtk_text_iter_is_start] fun gtk_text_iter_is_end ( iter: &GtkTextIter ) : gboolean = "mac#atsctrb_gtk_text_iter_is_end" // end of [gtk_text_iter_is_end] (* ****** ****** *) fun gtk_text_iter_get_line ( iter: &GtkTextIter ) : gint = "mac#atsctrb_gtk_text_iter_get_line" // end of [gtk_text_iter_get_line] fun gtk_text_iter_get_line_offset ( iter: &GtkTextIter ) : gint = "mac#atsctrb_gtk_text_iter_get_line_offset" // end of [gtk_text_iter_get_line_offset] (* ****** ****** *) fun gtk_text_iter_forward_char ( iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_iter_forward_char" // end of [gtk_text_iter_forward_char] fun gtk_text_iter_backward_char ( iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_iter_backward_char" // end of [gtk_text_iter_backward_char] fun gtk_text_iter_forward_chars (iter: &GtkTextIter, cnt: gint): void = "mac#atsctrb_gtk_text_iter_forward_chars" // end of [gtk_text_iter_forward_chars] fun gtk_text_iter_backward_chars (iter: &GtkTextIter, cnt: gint): void = "mac#atsctrb_gtk_text_iter_backward_chars" // end of [gtk_text_iter_backward_chars] (* ****** ****** *) fun gtk_text_iter_forward_line ( iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_iter_forward_line" // end of [gtk_text_iter_forward_line] fun gtk_text_iter_backward_line ( iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_iter_backward_line" // end of [gtk_text_iter_backward_line] fun gtk_text_iter_forward_lines ( iter: &GtkTextIter, cnt: gint ) : void = "mac#atsctrb_gtk_text_iter_forward_lines" // end of [gtk_text_iter_forward_lines] fun gtk_text_iter_backward_lines (iter: &GtkTextIter, cnt: gint): void = "mac#yatsctrb_gtk_text_iter_backward_lines" // end of [gtk_text_iter_backward_lines] (* ****** ****** *) (* end of [gtktextiter.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkhscrollbar.sats0000664000175000017500000000330612223166165023163 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_hscrollbar_new {c:cls | c <= GtkAdjustment} {l:agz} ( adj: !gobjref (c, l) ) : GtkHScrollbar_ref1 = "mac#atsctrb_gtk_hscrollbar_new" // end of [gtk_hscrollbar_new] (* ****** ****** *) (* end of [gtkhscrollbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktoolbutton.sats0000664000175000017500000000331312223166165023237 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_tool_button_new_from_stock {l:agz} ( stock_id: !gstring l ) : GtkToolButton_ref1 = "mac#atsctrb_gtk_tool_button_new_from_stock" // end of [gtk_tool_button_new_from_stock] (* ****** ****** *) (* end of [gtktoolbutton.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkmain.sats0000664000175000017500000000524512223166165021760 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_main (): void = "mac#atsctrb_gtk_main" // end of [gtk_main] fun gtk_main_level (): guint = "mac#atsctrb_gtk_main_level" // end of [gtk_main_level] (* // gtk_main_iteration(): gtk_main_iteration_do(TRUE) *) fun gtk_main_iteration (): gboolean = "mac#gtk_main_iteration" fun gtk_main_iteration_do (blocking: gboolean): gboolean = "mac#gtk_main_iteration_do" // end of [gtk_main_iteration_do] fun gtk_main_quit (): void = "mac#atsctrb_gtk_main_quit" (* ****** ****** *) fun gtk_init_add ( f: GtkFunction, data: gpointer ) : void = "mac#gtk_init_add" // end of [gtk_init_add] fun gtk_quit_add ( level: guint, f: GtkFunction, data: gpointer ) : guint = "mac#gtk_quit_add" // end of [gtk_quit_add] (* ****** ****** *) fun gtk_events_pending ((*none*)): gboolean = "mac#gtk_events_pending" // end of [gtk_events_pending] (* ****** ****** *) #ifndef GTK_DISABLE_DEPRECATED #then fun gtk_timeout_add ( interval: guint32 , f: GtkFunction, data: gpointer ) : guint = "mac#atsctrb_gtk_timeout_add" // end of [gtk_timeout_add] fun gtk_timeout_remove (id: guint): void = "mac#gtk_timeout_remove" // end of [gtk_timeout_remove] #endif // end of [...] (* ****** ****** *) (* end of [gtkmain.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkvscrollbar.sats0000664000175000017500000000330412223166165023177 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_vscrollbar_new {c:cls | c <= GtkAdjustment} {l:agz} ( adj: !gobjref (c, l) ) : GtkVScrollbar_ref1 = "mac#atsctrb_gtk_vscrollbar_new" // end of [gtk_vscrollbar_new] (* ****** ****** *) (* end of [gtkvscrollbar.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkradiobutton.sats0000664000175000017500000000565612223166165023374 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) fun gtk_radio_button_new {n:nat} ( group: !GSList_ptr (gpointer, n) ) : GtkRadioButton_ref1 = "mac#atsctrb_gtk_radio_button_new" // end of [gtk_radio_button_new] fun gtk_radio_button_new_with_label {n:nat} {l:agz} ( group: !GSList_ptr (gpointer, n), name: !gstring l ) : GtkRadioButton_ref1 = "mac#atsctrb_gtk_radio_button_new_with_label" // end of [gtk_radio_button_new_with_label] fun gtk_radio_button_new_with_mnemonic {n:nat} {l:agz} ( group: !GSList_ptr (gpointer, n), name: !gstring l ) : GtkRadioButton_ref1 = "mac#atsctrb_gtk_radio_button_new_with_mnemonic" // end of [gtk_radio_button_new_with_mnemonic] fun gtk_radio_button_new_from_widget {c:cls | c <= GtkRadioButton} {l:agz} ( group: !gobjref (c, l) ) : GtkRadioButton_ref1 = "mac#atsctrb_gtk_radio_button_new_from_widget" // end of [gtk_radio_button_new_from_widget] fun gtk_radio_button_new_with_label_from_widget {c:cls | c <= GtkRadioButton} {l1,l2:agz} ( group: !gobjref (c, l1), name: !gstring l2 ) : GtkRadioButton_ref1 = "mac#atsctrb_gtk_radio_button_new_with_label_from_widget" // end of [gtk_radio_button_new_with_label_from_widget] (* ****** ****** *) fun gtk_radio_button_get_group {c:cls | c <= GtkRadioButton} {l:agz} ( button: !gobjref (c, l) ) : ( minus (gobjref (c, l), GSList_ptr0 (gpointer)) | GSList_ptr0 (gpointer) ) = "mac#atsctrb_gtk_radio_button_get_group" // end of [gtk_radio_button_get_group] (* ****** ****** *) (* end of [gtkradiobutton.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkadjustment.sats0000664000175000017500000000601612223166165023207 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) symintr gtk_adjustment_new typedef gtk_adjustment_new_type (a:t@ype) = ( a // value , a // lower , a // upper , a // step_increment , a // page_increment , a // page_size ) - GtkAdjustment_ref1 fun gtk_adjustment_new__type : gtk_adjustment_new_type (double) = "mac#atsctrb_gtk_adjustment_new" overload gtk_adjustment_new with gtk_adjustment_new__type fun gtk_adjustment_new__gtype : gtk_adjustment_new_type (gdouble) = "mac#atsctrb_gtk_adjustment_new" overload gtk_adjustment_new with gtk_adjustment_new__gtype (* ****** ****** *) fun gtk_adjustment_changed {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l)): void = "mac#atsctrb_gtk_adjustment_changed" // end of [gtk_adjustment_changed] fun gtk_adjustment_value_changed {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l)): void = "mac#atsctrb_gtk_adjustment_value_changed" // end of [gtk_adjustment_value_changed] fun gtk_adjustment_clamp_page {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l), lower: gdouble, upper: gdouble): void = "mac#atsctrb_gtk_adjustment_clamp_page" // end of [gtk_adjustment_clamp_page] (* ****** ****** *) fun gtk_adjustment_get_value {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l)): gdouble = "mac#atsctrb_gtk_adjustment_get_value" // end of [gtk_adjustment_get_value] fun gtk_adjustment_set_value {c:cls | c <= GtkAdjustment} {l:agz} (adj: !gobjref (c, l), value: gdouble): void = "mac#atsctrb_gtk_adjustment_set_value" // end of [gtk_adjustment_set_value] (* ****** ****** *) (* end of [gtkadjustment.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkpaned.sats0000664000175000017500000000734412223166165022125 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_paned_add1 {c1,c2:cls | c1 <= GtkPaned; c2 <= GtkWidget} {l1,l2:agz} ( paned: !gobjref (c1, l1) , child: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_paned_add1" // end of [gtk_paned_add1] fun gtk_paned_add2 {c1,c2:cls | c1 <= GtkPaned; c2 <= GtkWidget} {l1,l2:agz} ( paned: !gobjref (c1, l1) , child: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_paned_add2" // end of [gtk_paned_add2] (* ****** ****** *) fun gtk_paned_pack1 {c1,c2:cls | c1 <= GtkPaned; c2 <= GtkWidget} {l1,l2:agz} ( paned: !gobjref (c1, l1) , child: !gobjref (c2, l2) , expand: gboolean , shrink: gboolean ) : void = "mac#atsctrb_gtk_paned_pack1" // end of [gtk_paned_pack1] fun gtk_paned_pack2 {c1,c2:cls | c1 <= GtkPaned; c2 <= GtkWidget} {l1,l2:agz} ( paned: !gobjref (c1, l1) , child: !gobjref (c2, l2) , expand: gboolean , shrink: gboolean ) : void = "mac#atsctrb_gtk_paned_pack2" // end of [gtk_paned_pack2] (* ****** ****** *) // // HX-2010-05-12: // checked: the reference count of the widget taken out is unchanged // fun gtk_paned_get_child1 {c1:cls | c1 <= GtkPaned} {l1:agz} ( paned: !gobjref (c1, l1) ) : [c2:cls;l2:addr | c2 <= GtkWidget] ( minus (gobjref (c1, l1), gobjref (c2, l2)) | gobjref (c2, l2) ) = "mac#atsctrb_gtk_paned_get_child1" // end of [gtk_paned_get_child1] fun gtk_paned_get_child2 {c1:cls | c1 <= GtkPaned} {l1:agz} ( paned: !gobjref (c1, l1) ) : [c2:cls;l2:addr | c2 <= GtkWidget] ( minus (gobjref (c1, l1), gobjref (c2, l2)) | gobjref (c2, l2) ) = "mac#atsctrb_gtk_paned_get_child2" // end of [gtk_paned_get_child2] (* ****** ****** *) fun gtk_paned_get_position {c:cls | c <= GtkPaned} {l:agz} ( paned: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_paned_get_position" // end of [gtk_paned_get_position] fun gtk_paned_set_position {c:cls | c <= GtkPaned} {l:agz} ( paned: !gobjref (c, l), position: gint ) : void = "mac#atsctrb_gtk_paned_set_position" // end of [gtk_paned_set_position] (* ****** ****** *) fun gtk_paned_get_handle_window {c1:cls | c1 <= GtkPaned} {l1:agz} ( paned: !gobjref (c1, l1) ) : [l2:addr] ( minus (gobjref (c1, l1), gobjref (GtkWindow, l2)) | gobjref (GtkWindow, l2) ) = "mac#atsctrb_gtk_paned_get_handle_window" // end of [gtk_paned_get_handle_window] (* ****** ****** *) (* end of [gtkpaned.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtktextbuffer.sats0000664000175000017500000002056612223166165023215 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_text_buffer_new_null () : GtkTextBuffer_ref1 = "mac#atsctrb_gtk_text_buffer_new_null" // end of [gtk_text_buffer_new_null] (* ****** ****** *) // // HX-2010-05-06: this one is 'get0' // fun gtk_text_buffer_get_tag_table {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) :<> [l_tbl:agz] ( minus (gobjref (c, l), gobjref (GtkTextTagTable, l_tbl)) | gobjref (GtkTextTagTable, l_tbl) ) = "mac#atsctrb_gtk_text_buffer_get_tag_table" // end of [gtk_text_buffer_get_tag_table] (* ****** ****** *) fun gtk_text_buffer_get_line_count {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_text_buffer_get_line_count" // end of [gtk_text_buffer_get_line_count] fun gtk_text_buffer_get_char_count {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) : gint = "mac#atsctrb_gtk_text_buffer_get_char_count" // end of [gtk_text_buffer_get_char_count] (* ****** ****** *) fun gtk_text_buffer_get_iter_at_mark {c1,c2:cls | c1 <= GtkTextBuffer; c2 <= GtkTextMark} {l1,l2:agz} ( tb: !gobjref (c1, l1) , iter: &GtkTextIter? >> GtkTextIter , mark: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_text_buffer_get_iter_at_mark" // end of [gtk_text_buffer_get_iter_at_mark] fun gtk_text_buffer_get_iter_at_offset {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) , iter: &GtkTextIter? >> GtkTextIter , charofs: gint ) : void = "mac#atsctrb_gtk_text_buffer_get_iter_at_offset" // end of [gtk_text_buffer_get_iter_at_offset] (* ****** ****** *) fun gtk_text_buffer_delete {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) , _beg: &GtkTextIter, _end: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_buffer_delete" // end of [gtk_text_buffer_get_delete] (* ****** ****** *) fun gtk_text_buffer_insert {c:cls | c <= GtkTextBuffer} {l:agz} {n0,n1:nat | n0 >= n1} ( tb: !gobjref (c, l) , iter: &GtkTextIter , text: &(@[gchar][n0]) , len: gint n1 ) : void = "mac#atsctrb_gtk_text_buffer_insert" // end of [gtk_text_buffer_insert] fun gtk_text_buffer_insertall {c:cls | c <= GtkTextBuffer} {l1,l2:agz} ( tb: !gobjref (c, l1) , iter: &GtkTextIter , text: !gstring l2 ) : void = "atsctrb_gtk_text_buffer_insertall" // function! // end of [gtk_text_buffer_insert_all] (* ****** ****** *) fun gtk_text_buffer_place_cursor {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l), iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_buffer_place_cursor" // end of [gtk_text_buffer_place_cursor] fun gtk_text_buffer_insert_at_cursor {c:cls | c <= GtkTextBuffer} {l:agz} {n0,n1:nat | n0 >= n1} ( tb: !gobjref (c, l) , text: &(@[gchar][n0]) , len: gint n1 ) : void = "mac#atsctrb_gtk_text_buffer_insert_at_cursor" // end of [gtk_text_buffer_insert_at_cursor] fun gtk_text_buffer_insertall_at_cursor {c:cls | c <= GtkTextBuffer} {l1,l2:agz} ( tb: !gobjref (c, l1), text: !gstring l2 ) : void = "atsctrb_gtk_text_buffer_insertall_at_cursor" // function! // end of [gtk_text_buffer_insertall_at_cursor] (* ****** ****** *) fun gtk_text_buffer_get_start_iter {c:cls | c <= GtkTextBuffer} {l:agz} (tb: !gobjref (c, l), iter: &GtkTextIter? >> GtkTextIter): void = "mac#atsctrb_gtk_text_buffer_get_start_iter" // end of [gtk_text_buffer_get_start_iter] fun gtk_text_buffer_get_end_iter {c:cls | c <= GtkTextBuffer} {l:agz} (tb: !gobjref (c, l), iter: &GtkTextIter? >> GtkTextIter): void = "mac#atsctrb_gtk_text_buffer_get_end_iter" // end of [gtk_text_buffer_get_end_iter] (* ****** ****** *) fun gtk_text_buffer_get_bounds {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) , _beg: &GtkTextIter? >> GtkTextIter , _end: &GtkTextIter? >> GtkTextIter ) : void = "mac#atsctrb_gtk_text_buffer_get_bounds" // end of [gtk_text_buffer_get_bounds] (* ****** ****** *) // // HX-2010-05-04: yes, the return type is [gstring1]! // fun gtk_text_buffer_get_text {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) , _beg: &GtkTextIter, _end: &GtkTextIter , include_hidden_chars: gboolean ) : gstring1 = "mac#atsctrb_gtk_text_buffer_get_text" // end of [gtk_text_buffer_get_get_text] (* ****** ****** *) fun gtk_text_buffer_set_text {c:cls | c <= GtkTextBuffer} {l:agz} {n0,n1:nat | n0 >= n1} ( tb: !gobjref (c, l), text: &(@[gchar][n0]), len: gint n1 ) : void = "mac#atsctrb_gtk_text_buffer_set_text" // end of [gtk_text_buffer_set_text] fun gtk_text_buffer_setall_text {c:cls | c <= GtkTextBuffer} {l1,l2:agz} (tb: !gobjref (c, l1), text: !gstring l2): void = "atsctrb_gtk_text_buffer_setall_text" // function! // end of [gtk_text_buffer_setall_text] (* ****** ****** *) fun gtk_text_buffer_place_cursor {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l), iter: &GtkTextIter ) : void = "mac#atsctrb_gtk_text_buffer_place_cursor" // end of [gtk_text_buffer_place_cursor] (* ****** ****** *) fun gtk_text_buffer_get_insert {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) : [l1:agz] ( minus (gobjref (c, l), gobjref (GtkTextMark, l1)) | gobjref (GtkTextMark, l1) ) = "mac#atsctrb_gtk_text_buffer_get_insert" // end of [gtk_text_buffer_get_insert] (* ****** ****** *) fun gtk_text_buffer_get_modified {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_text_buffer_get_modified" // end of [gtk_text_buffer_get_modified] fun gtk_text_buffer_set_modified {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l), modified: gboolean ) : void = "mac#atsctrb_gtk_text_buffer_set_modified" // end of [gtk_text_buffer_set_modified] (* ****** ****** *) fun gtk_text_buffer_cut_clipboard {c1,c2:cls | c1 <= GtkTextBuffer; c2 <= GtkClipBoard} {l1,l2:agz} ( tb: !gobjref (c1, l1), cb: !gobjref (c2, l2), editable: gboolean ) : void = "mac#atsctrb_gtk_text_buffer_cut_clipboard" // end of [gtk_text_buffer_cut_clipboard] fun gtk_text_buffer_copy_clipboard {c1,c2:cls | c1 <= GtkTextBuffer; c2 <= GtkClipBoard} {l1,l2:agz} ( tb: !gobjref (c1, l1), cb: !gobjref (c2, l2) ) : void = "mac#atsctrb_gtk_text_buffer_copy_clipboard" // end of [gtk_text_buffer_copy_clipboard] fun gtk_text_buffer_paste_clipboard_at_cursor {c1,c2:cls | c1 <= GtkTextBuffer; c2 <= GtkClipBoard} {l1,l2:agz} ( tb: !gobjref (c1, l1), cb: !gobjref (c2, l2), editable: gboolean ) : void = "mac#atsctrb_gtk_text_buffer_paste_clipboard_at_cursor" // end of [gtk_text_buffer_paste_clipboard_at_cursor] (* ****** ****** *) fun gtk_text_buffer_get_selection_bounds {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) , _beg: &GtkTextIter? >> GtkTextIter , _end: &GtkTextIter? >> GtkTextIter ) : gboolean = "mac#atsctrb_gtk_text_buffer_get_selection_bounds" // end of [gtk_text_buffer_get_selection_bounds] fun gtk_text_buffer_get_selection_bounds_null {c:cls | c <= GtkTextBuffer} {l:agz} ( tb: !gobjref (c, l) ) : gboolean = "mac#atsctrb_gtk_text_buffer_get_selection_bounds_null" // end of [gtk_text_buffer_get_selection_bounds_null] (* ****** ****** *) (* end of [gtktextbuffer.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkenums.sats0000664000175000017500000002130312223166165022154 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) abst@ype GtkAnchorType = $extype"GtkAnchorType" macdef GTK_ANCHOR_CENTER = $extval (GtkAnchorType, "GTK_ANCHOR_CENTER") macdef GTK_ANCHOR_NORTH = $extval (GtkAnchorType, "GTK_ANCHOR_NORTH") macdef GTK_ANCHOR_NORTH_WEST = $extval (GtkAnchorType, "GTK_ANCHOR_NORTH_WEST") macdef GTK_ANCHOR_NORTH_EAST = $extval (GtkAnchorType, "GTK_ANCHOR_NORTH_EAST") macdef GTK_ANCHOR_SOUTH = $extval (GtkAnchorType, "GTK_ANCHOR_SOUTH") macdef GTK_ANCHOR_SOUTH_WEST = $extval (GtkAnchorType, "GTK_ANCHOR_SOUTH_WEST") macdef GTK_ANCHOR_SOUTH_EAST = $extval (GtkAnchorType, "GTK_ANCHOR_SOUTH_EAST") macdef GTK_ANCHOR_WEST = $extval (GtkAnchorType, "GTK_ANCHOR_WEST") macdef GTK_ANCHOR_EAST = $extval (GtkAnchorType, "GTK_ANCHOR_EAST") macdef GTK_ANCHOR_N = $extval (GtkAnchorType, "GTK_ANCHOR_N") macdef GTK_ANCHOR_NW = $extval (GtkAnchorType, "GTK_ANCHOR_NW") macdef GTK_ANCHOR_NE = $extval (GtkAnchorType, "GTK_ANCHOR_NE") macdef GTK_ANCHOR_S = $extval (GtkAnchorType, "GTK_ANCHOR_S") macdef GTK_ANCHOR_SW = $extval (GtkAnchorType, "GTK_ANCHOR_SW") macdef GTK_ANCHOR_SE = $extval (GtkAnchorType, "GTK_ANCHOR_SE") macdef GTK_ANCHOR_W = $extval (GtkAnchorType, "GTK_ANCHOR_W") macdef GTK_ANCHOR_E = $extval (GtkAnchorType, "GTK_ANCHOR_E") (* ****** ****** *) abst@ype GtkArrowPlacement = $extype"GtkArrowPlacement" macdef GTK_ARROWS_BOTH = $extval (GtkArrowPlacement, "GTK_ARROWS_BOTH") macdef GTK_ARROWS_START = $extval (GtkArrowPlacement, "GTK_ARROWS_START") macdef GTK_ARROWS_END = $extval (GtkArrowPlacement, "GTK_ARROWS_END") (* ****** ****** *) abst@ype GtkArrowType = $extype"GtkArrowType" macdef GTK_ARROW_UP = $extval (GtkArrowType, "GTK_ARROW_UP") macdef GTK_ARROW_DOWN = $extval (GtkArrowType, "GTK_ARROW_DOWN") macdef GTK_ARROW_LEFT = $extval (GtkArrowType, "GTK_ARROW_LEFT") macdef GTK_ARROW_RIGHT = $extval (GtkArrowType, "GTK_ARROW_RIGHT") macdef GTK_ARROW_NONE = $extval (GtkArrowType, "GTK_ARROW_NONE") (* ****** ****** *) abst@ype GtkAttachOptions = $extype"GtkAttachOptions" macdef GTK_EXPAND = $extval (GtkAttachOptions, "GTK_EXPAND") macdef GTK_SHRINK = $extval (GtkAttachOptions, "GTK_SHRINK") macdef GTK_FILL = $extval (GtkAttachOptions, "GTK_FILL") (* ****** ****** *) abst@ype GtkButtonBoxStyle = $extype"GtkButtonBoxStyle" macdef GTK_BUTTONBOX_DEFAULT_STYLE = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_DEFAULT_STYLE") macdef GTK_BUTTONBOX_SPREAD = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_SPREAD") macdef GTK_BUTTONBOX_EDGE = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_EDGE") macdef GTK_BUTTONBOX_START = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_START") macdef GTK_BUTTONBOX_END = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_END") macdef GTK_BUTTONBOX_CENTER = $extval (GtkButtonBoxStyle, "GTK_BUTTONBOX_CENTER") (* ****** ****** *) abst@ype GtkJustification = $extype"GtkJustification" macdef GTK_JUSTIFY_LEFT = $extval (GtkJustification, "GTK_JUSTIFY_LEFT") macdef GTK_JUSTIFY_RIGHT = $extval (GtkJustification, "GTK_JUSTIFY_RIGHT") macdef GTK_JUSTIFY_CENTER = $extval (GtkJustification, "GTK_JUSTIFY_CENTER") macdef GTK_JUSTIFY_FILL = $extval (GtkJustification, "GTK_JUSTIFY_FILL") (* ****** ****** *) (* ** Placement type for scrolled window *) abst@ype GtkCornerType = $extype"GtkCornerType" macdef GTK_CORNER_TOP_LEFT = $extval (GtkCornerType, "GTK_CORNER_TOP_LEFT") macdef GTK_CORNER_BOTTOM_LEFT = $extval (GtkCornerType, "GTK_CORNER_BOTTOM_LEFT") macdef GTK_CORNER_TOP_RIGHT = $extval (GtkCornerType, "GTK_CORNER_TOP_RIGHT") macdef GTK_CORNER_BOTTOM_RIGHT = $extval (GtkCornerType, "GTK_CORNER_BOTTOM_RIGHT") (* ****** ****** *) abst@ype GtkPathType = $extype"GtkPathType" macdef GTK_PATH_WIDGET = $extval (GtkPathType, "GTK_PATH_WIDGET") macdef GTK_PATH_WIDGET_CLASS = $extval (GtkPathType, "GTK_PATH_WIDGET_CLASS") macdef GTK_PATH_CLASS = $extval (GtkPathType, "GTK_PATH_CLASS") (* ****** ****** *) (* ** Policy type for scrolled window *) abst@ype GtkPolicyType = $extype"GtkPolicyType" macdef GTK_POLICY_ALWAYS = $extval (GtkPolicyType, "GTK_POLICY_ALWAYS") macdef GTK_POLICY_AUTOMATIC = $extval (GtkPolicyType, "GTK_POLICY_AUTOMATIC") macdef GTK_POLICY_NEVER = $extval (GtkPolicyType, "GTK_POLICY_NEVER") (* ****** ****** *) abst@ype GtkPositionType = $extype"GtkPositionType" macdef GTK_POS_LEFT = $extval (GtkPositionType, "GTK_POS_LEFT") macdef GTK_POS_RIGHT = $extval (GtkPositionType, "GTK_POS_RIGHT") macdef GTK_POS_TOP = $extval (GtkPositionType, "GTK_POS_TOP") macdef GTK_POS_BOTTOM = $extval (GtkPositionType, "GTK_POS_BOTTOM") (* ****** ****** *) abst@ype GtkShadowType = $extype"GtkShadowType" macdef GTK_SHADOW_IN = $extval (GtkShadowType, "GTK_SHADOW_IN") macdef GTK_SHADOW_OUT = $extval (GtkShadowType, "GTK_SHADOW_OUT") // default macdef GTK_SHADOW_ETCHED_IN = $extval (GtkShadowType, "GTK_SHADOW_ETCHED_IN") macdef GTK_SHADOW_ETCHED_OUT = $extval (GtkShadowType, "GTK_SHADOW_ETCHED_OUT") macdef GTK_SHADOW_NONE = $extval (GtkShadowType, "GTK_SHADOW_NONE") (* ****** ****** *) abst@ype GtkStateType = $extype"GtkStateType" macdef GTK_STATE_NORMAL = $extval (GtkStateType, "GTK_STATE_NORMAL") macdef GTK_STATE_ACTIVE = $extval (GtkStateType, "GTK_STATE_ACTIVE") macdef GTK_STATE_PRELIGHT = $extval (GtkStateType, "GTK_STATE_PRELIGHT") macdef GTK_STATE_SELECTED = $extval (GtkStateType, "GTK_STATE_SELECTED") macdef GTK_STATE_INSENSITIVE = $extval (GtkStateType, "GTK_STATE_INSENSITIVE") (* ****** ****** *) abst@ype GtkMetricType = $extype"GtkMetricType" macdef GTK_PIXELS = $extval (GtkMetricType, "GTK_PIXELS") macdef GTK_INCHES = $extval (GtkMetricType, "GTK_INCHES") macdef GTK_CENTIMETERS = $extval (GtkMetricType, "GTK_CENTIMETERS") (* ****** ****** *) abst@ype GtkToolbarStyle = $extype"GtkToolbarStyle" macdef GTK_TOOLBAR_ICONS = $extval (GtkToolbarStyle, "GTK_TOOLBAR_ICONS") macdef GTK_TOOLBAR_TEXT = $extval (GtkToolbarStyle, "GTK_TOOLBAR_TEXT") macdef GTK_TOOLBAR_BOTH = $extval (GtkToolbarStyle, "GTK_TOOLBAR_BOTH") macdef GTK_TOOLBAR_BOTH_HORIZ = $extval (GtkToolbarStyle, "GTK_TOOLBAR_BOTH_HORIZ") (* ****** ****** *) abst@ype GtkUpdateType = $extype"GtkUpdateType" macdef GTK_UPDATE_CONTINUOUS = $extval (GtkUpdateType, "GTK_UPDATE_CONTINUOUS") macdef GTK_UPDATE_DISCONTINUOUS = $extval (GtkUpdateType, "GTK_UPDATE_DISCONTINUOUS") macdef GTK_UPDATE_DELAYED = $extval (GtkUpdateType, "GTK_UPDATE_DELAYED") (* ****** ****** *) abst@ype GtkWindowPosition = $extype"GtkWindowPosition" macdef GTK_WIN_POS_NONE = $extval (GtkWindowPosition, "GTK_WIN_POS_NONE") macdef GTK_WIN_POS_CENTER = $extval (GtkWindowPosition, "GTK_WIN_POS_CENTER") macdef GTK_WIN_POS_MOUSE = $extval (GtkWindowPosition, "GTK_WIN_POS_MOUSE") macdef GTK_WIN_POS_CENTER_ALWAYS = $extval (GtkWindowPosition, "GTK_WIN_POS_CENTER_ALWAYS") macdef GTK_WIN_POS_CENTER_ON_PARENT = $extval (GtkWindowPosition, "GTK_WIN_POS_CENTER_ON_PARENT") (* ****** ****** *) abst@ype GtkWindowType = $extype"GtkWindowType" macdef GTK_WINDOW_TOPLEVEL = $extval (GtkWindowType, "GTK_WINDOW_TOPLEVEL") macdef GTK_WINDOW_POPUP = $extval (GtkWindowType, "GTK_WINDOW_POPUP") (* ****** ****** *) abst@ype GtkWrapMode = $extype"GtkWrapMode" macdef GTK_WRAP_NONE = $extval (GtkWrapMode, "GTK_WRAP_NONE") macdef GTK_WRAP_CHAR = $extval (GtkWrapMode, "GTK_WRAP_CHAR") macdef GTK_WRAP_WORD = $extval (GtkWrapMode, "GTK_WRAP_WORD") macdef GTK_WRAP_WORD_CHAR = $extval (GtkWrapMode, "GTK_WRAP_WORD_CHAR") (* ****** ****** *) (* end of [gtkenums.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk/gtkdrawingarea.sats0000664000175000017500000000321412223166165023312 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gtk_drawing_area_new (): GtkDrawingArea_ref1 = "mac#atsctrb_gtk_drawing_area_new" // end of [gtk_drawing_area_new] (* ****** ****** *) (* end of [gtkdrawingarea.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk-pixbuf.sats0000664000175000017500000000517112223166165021577 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) %{# #include "contrib/GTK/CATS/gdk-pixbuf.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staload at run-time (* ****** ****** *) staload GLIB = "contrib/glib/SATS/glib.sats" stadef gint = $GLIB.gint stadef guint = $GLIB.guint stadef gint8 = $GLIB.gint8 stadef guint8 = $GLIB.guint8 stadef guint16 = $GLIB.guint16 stadef guint32 = $GLIB.guint32 stadef gfloat = $GLIB.gfloat stadef gdouble = $GLIB.gdouble stadef gpointer = $GLIB.gpointer (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef gboolean = $GOBJ.gboolean stadef gobjref = $GOBJ.gobjref (* ****** ****** *) staload "gdkclassdec.sats" (* ****** ****** *) #include "gdk-pixbuf/gdk-pixbuf-core.sats" (* ****** ****** *) (* end of [gdk-pixbuf.sats] *) //// #include #include #include #include #include #include #include #include #include #include ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtk.sats0000664000175000017500000004417512223166165020333 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) // // HX: // // Some naming conventions used in this API for GTK // // get0 : get out a value that must be returned // get1 : get out a value by increasing its reference count // getref : get out a reference that must be returned // // set0 : consume-set; the original value is freed if necessary // set1 : preserve-set; the original value is freed if necessary // // takeout : this is the same as get0 // (* ****** ****** *) %{# #include "contrib/GTK/CATS/gtk.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) staload GLIB = "contrib/glib/SATS/glib.sats" // stadef gboolean = $GLIB.gboolean // stadef gchar = $GLIB.gchar // stadef gint (i:int) = $GLIB.gint (i) stadef gint = $GLIB.gint // stadef guint (i:int) = $GLIB.guint (i) stadef guint = $GLIB.guint // stadef gfloat = $GLIB.gfloat stadef gdouble = $GLIB.gdouble // stadef gpointer = $GLIB.gpointer // stadef gstring = $GLIB.gstring stadef gstring0 = $GLIB.gstring0 stadef gstring1 = $GLIB.gstring1 // stadef GSList_ptr = $GLIB.GSList_ptr stadef GSList_ptr0 = $GLIB.GSList_ptr0 stadef GSList_ptr1 = $GLIB.GSList_ptr1 // (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" // stadef gobjref = $GOBJ.gobjref stadef gsignal = $GOBJ.gsignal // (* ****** ****** *) staload "contrib/pango/SATS/pango.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdkclassdec.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" (* ****** ****** *) viewtypedef GtkAdjustment_ref (l:addr) = gobjref (GtkAdjustment, l) viewtypedef GtkAdjustment_ref0 = [l:agez] GtkAdjustment_ref l viewtypedef GtkAdjustment_ref1 = [l:addr | l > null] GtkAdjustment_ref l viewtypedef GtkAlignment_ref (l:addr) = gobjref (GtkAlignment, l) viewtypedef GtkAlignment_ref0 = [l:agez] GtkAlignment_ref l viewtypedef GtkAlignment_ref1 = [l:addr | l > null] GtkAlignment_ref l viewtypedef GtkArrow_ref (l:addr) = gobjref (GtkArrow, l) viewtypedef GtkArrow_ref0 = [l:agez] GtkArrow_ref l viewtypedef GtkArrow_ref1 = [l:addr | l > null] GtkArrow_ref l viewtypedef GtkButton_ref (l:addr) = gobjref (GtkButton, l) viewtypedef GtkButton_ref0 = [l:agez] GtkButton_ref l viewtypedef GtkButton_ref1 = [l:addr | l > null] GtkButton_ref l viewtypedef GtkCheckButton_ref (l:addr) = gobjref (GtkCheckButton, l) viewtypedef GtkCheckButton_ref0 = [l:agez] GtkCheckButton_ref l viewtypedef GtkCheckButton_ref1 = [l:addr | l > null] GtkCheckButton_ref l viewtypedef GtkCheckMenuItem_ref (l:addr) = gobjref (GtkCheckMenuItem, l) viewtypedef GtkCheckMenuItem_ref0 = [l:agez] GtkCheckMenuItem_ref l viewtypedef GtkCheckMenuItem_ref1 = [l:addr | l > null] GtkCheckMenuItem_ref l viewtypedef GtkClipBoard_ref (l:addr) = gobjref (GtkClipBoard, l) viewtypedef GtkClipBoard_ref0 = [l:agez] GtkClipBoard_ref l viewtypedef GtkClipBoard_ref1 = [l:addr | l > null] GtkClipBoard_ref l viewtypedef GtkColorSelection_ref (l:addr) = gobjref (GtkColorSelection, l) viewtypedef GtkColorSelection_ref0 = [l:agez] GtkColorSelection_ref l viewtypedef GtkColorSelection_ref1 = [l:addr | l > null] GtkColorSelection_ref l viewtypedef GtkColorSelectionDialog_ref (l:addr) = gobjref (GtkColorSelectionDialog, l) viewtypedef GtkColorSelectionDialog_ref0 = [l:agez] GtkColorSelectionDialog_ref l viewtypedef GtkColorSelectionDialog_ref1 = [l:addr | l > null] GtkColorSelectionDialog_ref l viewtypedef GtkDialog_ref (l:addr) = gobjref (GtkDialog, l) viewtypedef GtkDialog_ref0 = [l:agez] GtkDialog_ref l viewtypedef GtkDialog_ref1 = [l:addr | l > null] GtkDialog_ref l viewtypedef GtkDrawingArea_ref (l:addr) = gobjref (GtkDrawingArea, l) viewtypedef GtkDrawingArea_ref0 = [l:agez] GtkDrawingArea_ref l viewtypedef GtkDrawingArea_ref1 = [l:addr | l > null] GtkDrawingArea_ref l viewtypedef GtkEntry_ref (l:addr) = gobjref (GtkEntry, l) viewtypedef GtkEntry_ref0 = [l:agez] GtkEntry_ref l viewtypedef GtkEntry_ref1 = [l:addr | l > null] GtkEntry_ref l viewtypedef GtkFileSelection_ref (l:addr) = gobjref (GtkFileSelection, l) viewtypedef GtkFileSelection_ref0 = [l:agez] GtkFileSelection_ref l viewtypedef GtkFileSelection_ref1 = [l:addr | l > null] GtkFileSelection_ref l viewtypedef GtkFileChooserDialog_ref (l:addr) = gobjref (GtkFileChooserDialog, l) viewtypedef GtkFileChooserDialog_ref0 = [l:agez] GtkFileChooserDialog_ref l viewtypedef GtkFileChooserDialog_ref1 = [l:addr | l > null] GtkFileChooserDialog_ref l viewtypedef GtkFontSelection_ref (l:addr) = gobjref (GtkFontSelection, l) viewtypedef GtkFontSelection_ref0 = [l:agez] GtkFontSelection_ref l viewtypedef GtkFontSelection_ref1 = [l:addr | l > null] GtkFontSelection_ref l viewtypedef GtkFontSelectionDialog_ref (l:addr) = gobjref (GtkFontSelectionDialog, l) viewtypedef GtkFontSelectionDialog_ref0 = [l:agez] GtkFontSelectionDialog_ref l viewtypedef GtkFontSelectionDialog_ref1 = [l:addr | l > null] GtkFontSelectionDialog_ref l viewtypedef GtkFrame_ref (l:addr) = gobjref (GtkFrame, l) viewtypedef GtkFrame_ref0 = [l:agez] GtkFrame_ref l viewtypedef GtkFrame_ref1 = [l:addr | l > null] GtkFrame_ref l viewtypedef GtkHBox_ref (l:addr) = gobjref (GtkHBox, l) viewtypedef GtkHBox_ref0 = [l:agez] GtkHBox_ref l viewtypedef GtkHBox_ref1 = [l:addr | l > null] GtkHBox_ref l viewtypedef GtkHPaned_ref (l:addr) = gobjref (GtkHPaned, l) viewtypedef GtkHPaned_ref0 = [l:agez] GtkHPaned_ref l viewtypedef GtkHPaned_ref1 = [l:addr | l > null] GtkHPaned_ref l viewtypedef GtkHRuler_ref (l:addr) = gobjref (GtkHRuler, l) viewtypedef GtkHRuler_ref0 = [l:agez] GtkHRuler_ref l viewtypedef GtkHRuler_ref1 = [l:addr | l > null] GtkHRuler_ref l viewtypedef GtkHScale_ref (l:addr) = gobjref (GtkHScale, l) viewtypedef GtkHScale_ref0 = [l:agez] GtkHScale_ref l viewtypedef GtkHScale_ref1 = [l:addr | l > null] GtkHScale_ref l viewtypedef GtkHScrollbar_ref (l:addr) = gobjref (GtkHScrollbar, l) viewtypedef GtkHScrollbar_ref0 = [l:agez] GtkHScrollbar_ref l viewtypedef GtkHScrollbar_ref1 = [l:addr | l > null] GtkHScrollbar_ref l viewtypedef GtkHSeparator_ref (l:addr) = gobjref (GtkHSeparator, l) viewtypedef GtkHSeparator_ref0 = [l:agez] GtkHSeparator_ref l viewtypedef GtkHSeparator_ref1 = [l:addr | l > null] GtkHSeparator_ref l viewtypedef GtkImageMenuItem_ref (l:addr) = gobjref (GtkImageMenuItem, l) viewtypedef GtkImageMenuItem_ref0 = [l:agez] GtkImageMenuItem_ref l viewtypedef GtkImageMenuItem_ref1 = [l:addr | l > null] GtkImageMenuItem_ref l viewtypedef GtkLabel_ref (l:addr) = gobjref (GtkLabel, l) viewtypedef GtkLabel_ref0 = [l:agez] GtkLabel_ref l viewtypedef GtkLabel_ref1 = [l:addr | l > null] GtkLabel_ref l viewtypedef GtkMenu_ref (l:addr) = gobjref (GtkMenu, l) viewtypedef GtkMenu_ref0 = [l:agez] GtkMenu_ref l viewtypedef GtkMenu_ref1 = [l:addr | l > null] GtkMenu_ref l viewtypedef GtkMenuBar_ref (l:addr) = gobjref (GtkMenuBar, l) viewtypedef GtkMenuBar_ref0 = [l:agez] GtkMenuBar_ref l viewtypedef GtkMenuBar_ref1 = [l:addr | l > null] GtkMenuBar_ref l viewtypedef GtkMenuItem_ref (l:addr) = gobjref (GtkMenuItem, l) viewtypedef GtkMenuItem_ref0 = [l:agez] GtkMenuItem_ref l viewtypedef GtkMenuItem_ref1 = [l:addr | l > null] GtkMenuItem_ref l viewtypedef GtkMenuShell_ref (l:addr) = gobjref (GtkMenuShell, l) viewtypedef GtkMenuShell_ref0 = [l:agez] GtkMenuShell_ref l viewtypedef GtkMenuShell_ref1 = [l:addr | l > null] GtkMenuShell_ref l viewtypedef GtkMessageDialog_ref (l:addr) = gobjref (GtkMessageDialog, l) viewtypedef GtkMessageDialog_ref0 = [l:agez] GtkMessageDialog_ref l viewtypedef GtkMessageDialog_ref1 = [l:addr | l > null] GtkMessageDialog_ref l viewtypedef GtkOptionMenu_ref (l:addr) = gobjref (GtkOptionMenu, l) viewtypedef GtkOptionMenu_ref0 = [l:agez] GtkOptionMenu_ref l viewtypedef GtkOptionMenu_ref1 = [l:addr | l > null] GtkOptionMenu_ref l viewtypedef GtkProgressBar_ref (l:addr) = gobjref (GtkProgressBar, l) viewtypedef GtkProgressBar_ref0 = [l:agez] GtkProgressBar_ref l viewtypedef GtkProgressBar_ref1 = [l:addr | l > null] GtkProgressBar_ref l viewtypedef GtkRadioButton_ref (l:addr) = gobjref (GtkRadioButton, l) viewtypedef GtkRadioButton_ref0 = [l:agez] GtkRadioButton_ref l viewtypedef GtkRadioButton_ref1 = [l:addr | l > null] GtkRadioButton_ref l viewtypedef GtkScrolledWindow_ref (l:addr) = gobjref (GtkScrolledWindow, l) viewtypedef GtkScrolledWindow_ref0 = [l:agez] GtkScrolledWindow_ref l viewtypedef GtkScrolledWindow_ref1 = [l:addr | l > null] GtkScrolledWindow_ref l viewtypedef GtkSeparatorMenuItem_ref (l:addr) = gobjref (GtkSeparatorMenuItem, l) viewtypedef GtkSeparatorMenuItem_ref0 = [l:agez] GtkSeparatorMenuItem_ref l viewtypedef GtkSeparatorMenuItem_ref1 = [l:addr | l > null] GtkSeparatorMenuItem_ref l viewtypedef GtkSeparatorToolItem_ref (l:addr) = gobjref (GtkSeparatorToolItem, l) viewtypedef GtkSeparatorToolItem_ref0 = [l:agez] GtkSeparatorToolItem_ref l viewtypedef GtkSeparatorToolItem_ref1 = [l:addr | l > null] GtkSeparatorToolItem_ref l viewtypedef GtkSpinButton_ref (l:addr) = gobjref (GtkSpinButton, l) viewtypedef GtkSpinButton_ref0 = [l:agez] GtkSpinButton_ref l viewtypedef GtkSpinButton_ref1 = [l:addr | l > null] GtkSpinButton_ref l viewtypedef GtkStatusbar_ref (l:addr) = gobjref (GtkStatusbar, l) viewtypedef GtkStatusbar_ref0 = [l:agez] GtkStatusbar_ref l viewtypedef GtkStatusbar_ref1 = [l:addr | l > null] GtkStatusbar_ref l viewtypedef GtkTable_ref (l:addr) = gobjref (GtkTable, l) viewtypedef GtkTable_ref0 = [l:agez] GtkTable_ref l viewtypedef GtkTable_ref1 = [l:addr | l > null] GtkTable_ref l viewtypedef GtkTextView_ref (l:addr) = gobjref (GtkTextView, l) viewtypedef GtkTextView_ref0 = [l:agez] GtkTextView_ref l viewtypedef GtkTextView_ref1 = [l:addr | l > null] GtkTextView_ref l viewtypedef GtkToggleButton_ref (l:addr) = gobjref (GtkToggleButton, l) viewtypedef GtkToggleButton_ref0 = [l:agez] GtkToggleButton_ref l viewtypedef GtkToggleButton_ref1 = [l:addr | l > null] GtkToggleButton_ref l viewtypedef GtkToolbar_ref (l:addr) = gobjref (GtkToolbar, l) viewtypedef GtkToolbar_ref0 = [l:agez] GtkToolbar_ref l viewtypedef GtkToolbar_ref1 = [l:addr | l > null] GtkToolbar_ref l viewtypedef GtkToolButton_ref (l:addr) = gobjref (GtkToolButton, l) viewtypedef GtkToolButton_ref0 = [l:agez] GtkToolButton_ref l viewtypedef GtkToolButton_ref1 = [l:addr | l > null] GtkToolButton_ref l viewtypedef GtkVBox_ref (l:addr) = gobjref (GtkVBox, l) viewtypedef GtkVBox_ref0 = [l:agez] GtkVBox_ref l viewtypedef GtkVBox_ref1 = [l:addr | l > null] GtkVBox_ref l viewtypedef GtkVPaned_ref (l:addr) = gobjref (GtkVPaned, l) viewtypedef GtkVPaned_ref0 = [l:agez] GtkVPaned_ref l viewtypedef GtkVPaned_ref1 = [l:addr | l > null] GtkVPaned_ref l viewtypedef GtkVRuler_ref (l:addr) = gobjref (GtkVRuler, l) viewtypedef GtkVRuler_ref0 = [l:agez] GtkVRuler_ref l viewtypedef GtkVRuler_ref1 = [l:addr | l > null] GtkVRuler_ref l viewtypedef GtkVScale_ref (l:addr) = gobjref (GtkVScale, l) viewtypedef GtkVScale_ref0 = [l:agez] GtkVScale_ref l viewtypedef GtkVScale_ref1 = [l:addr | l > null] GtkVScale_ref l viewtypedef GtkVScrollbar_ref (l:addr) = gobjref (GtkVScrollbar, l) viewtypedef GtkVScrollbar_ref0 = [l:agez] GtkVScrollbar_ref l viewtypedef GtkVScrollbar_ref1 = [l:addr | l > null] GtkVScrollbar_ref l viewtypedef GtkVSeparator_ref (l:addr) = gobjref (GtkVSeparator, l) viewtypedef GtkVSeparator_ref0 = [l:agez] GtkVSeparator_ref l viewtypedef GtkVSeparator_ref1 = [l:addr | l > null] GtkVSeparator_ref l // // viewtypedef GtkWidget_ref (l:addr) = gobjref (GtkWidget, l) // viewtypedef GtkWindow_ref (l:addr) = gobjref (GtkWindow, l) viewtypedef GtkWindow_ref0 = [l:agez] GtkWindow_ref l viewtypedef GtkWindow_ref1 = [l:addr | l > null] GtkWindow_ref l (* ****** ****** *) viewtypedef GtkAccelGroup_ref (l:addr) = gobjref (GtkAccelGroup, l) viewtypedef GtkAccelGroup_ref0 = [l:agez] GtkAccelGroup_ref l viewtypedef GtkAccelGroup_ref1 = [l:addr | l > null] GtkAccelGroup_ref l (* ****** ****** *) viewtypedef GtkFileChooser_ref (l:addr) = gobjref (GtkFileChooser, l) viewtypedef GtkFileChooser_ref0 = [l:agez] GtkFileChooser_ref l viewtypedef GtkFileChooser_ref1 = [l:addr | l > null] GtkFileChooser_ref l (* ****** ****** *) viewtypedef GtkStyle_ref (l:addr) = gobjref (GtkStyle, l) viewtypedef GtkStyle_ref0 = [l:agez] GtkStyle_ref l viewtypedef GtkStyle_ref1 = [l:addr | l > null] GtkStyle_ref l (* ****** ****** *) viewtypedef GtkTextBuffer_ref (l:addr) = gobjref (GtkTextBuffer, l) viewtypedef GtkTextBuffer_ref0 = [l:agez] GtkTextBuffer_ref l viewtypedef GtkTextBuffer_ref1 = [l:addr | l > null] GtkTextBuffer_ref l viewtypedef GtkTextTag_ref (l:addr) = gobjref (GtkTextTag, l) viewtypedef GtkTextTag_ref0 = [l:agez] GtkTextTag_ref l viewtypedef GtkTextTag_ref1 = [l:addr | l > null] GtkTextTag_ref l viewtypedef GtkTextTagTable_ref (l:addr) = gobjref (GtkTextTagTable, l) viewtypedef GtkTextTagTable_ref0 = [l:agez] GtkTextTagTable_ref l viewtypedef GtkTextTagTable_ref1 = [l:addr | l > null] GtkTextTagTable_ref l abst@ype GtkTextIter = $extype"GtkTextIter" // opaque viewtypedef GtkTextMark_ref (l:addr) = gobjref (GtkTextMark, l) viewtypedef GtkTextMark_ref0 = [l:agez] GtkTextMark_ref l viewtypedef GtkTextMark_ref1 = [l:addr | l > null] GtkTextMark_ref l (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkenums.sats" #include "contrib/GTK/SATS/gtk/gtkstock.sats" #include "contrib/GTK/SATS/gtk/gtktypeutils.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkaccelgroup.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkstyle.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtktextbuffer.sats" #include "contrib/GTK/SATS/gtk/gtktextiter.sats" #include "contrib/GTK/SATS/gtk/gtktextmark.sats" #include "contrib/GTK/SATS/gtk/gtktexttag.sats" #include "contrib/GTK/SATS/gtk/gtktexttagtable.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkfilechooser.sats" // GInterface (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkadjustment.sats" #include "contrib/GTK/SATS/gtk/gtkalignment.sats" #include "contrib/GTK/SATS/gtk/gtkarrow.sats" #include "contrib/GTK/SATS/gtk/gtkbox.sats" #include "contrib/GTK/SATS/gtk/gtkbutton.sats" #include "contrib/GTK/SATS/gtk/gtkcheckbutton.sats" #include "contrib/GTK/SATS/gtk/gtkcheckmenuitem.sats" #include "contrib/GTK/SATS/gtk/gtkclipboard.sats" #include "contrib/GTK/SATS/gtk/gtkcontainer.sats" #include "contrib/GTK/SATS/gtk/gtkcolorsel.sats" #include "contrib/GTK/SATS/gtk/gtkcolorseldialog.sats" #include "contrib/GTK/SATS/gtk/gtkdialog.sats" #include "contrib/GTK/SATS/gtk/gtkdrawingarea.sats" #include "contrib/GTK/SATS/gtk/gtkentry.sats" #include "contrib/GTK/SATS/gtk/gtkfilesel.sats" // DEPRECATED!!! #include "contrib/GTK/SATS/gtk/gtkfilechooserdialog.sats" #include "contrib/GTK/SATS/gtk/gtkfontsel.sats" #include "contrib/GTK/SATS/gtk/gtkframe.sats" #include "contrib/GTK/SATS/gtk/gtkhbox.sats" #include "contrib/GTK/SATS/gtk/gtkhpaned.sats" #include "contrib/GTK/SATS/gtk/gtkhruler.sats" #include "contrib/GTK/SATS/gtk/gtkhscale.sats" #include "contrib/GTK/SATS/gtk/gtkhscrollbar.sats" #include "contrib/GTK/SATS/gtk/gtkhseparator.sats" #include "contrib/GTK/SATS/gtk/gtkimagemenuitem.sats" #include "contrib/GTK/SATS/gtk/gtklabel.sats" #include "contrib/GTK/SATS/gtk/gtkmenu.sats" #include "contrib/GTK/SATS/gtk/gtkmenubar.sats" #include "contrib/GTK/SATS/gtk/gtkmenuitem.sats" #include "contrib/GTK/SATS/gtk/gtkmenushell.sats" #include "contrib/GTK/SATS/gtk/gtkmessagedialog.sats" #include "contrib/GTK/SATS/gtk/gtkmisc.sats" #include "contrib/GTK/SATS/gtk/gtkoptionmenu.sats" #include "contrib/GTK/SATS/gtk/gtkpaned.sats" #include "contrib/GTK/SATS/gtk/gtkprogress.sats" // DEPRECATED!!! #include "contrib/GTK/SATS/gtk/gtkprogressbar.sats" #include "contrib/GTK/SATS/gtk/gtkradiobutton.sats" #include "contrib/GTK/SATS/gtk/gtkrange.sats" #include "contrib/GTK/SATS/gtk/gtkruler.sats" #include "contrib/GTK/SATS/gtk/gtkscale.sats" #include "contrib/GTK/SATS/gtk/gtkscrollbar.sats" #include "contrib/GTK/SATS/gtk/gtkscrolledwindow.sats" #include "contrib/GTK/SATS/gtk/gtkseparator.sats" #include "contrib/GTK/SATS/gtk/gtkseparatormenuitem.sats" // <= menuitem #include "contrib/GTK/SATS/gtk/gtkseparatortoolitem.sats" #include "contrib/GTK/SATS/gtk/gtkspinbutton.sats" // <= entry #include "contrib/GTK/SATS/gtk/gtkstatusbar.sats" #include "contrib/GTK/SATS/gtk/gtktable.sats" // <= container #include "contrib/GTK/SATS/gtk/gtktextview.sats" // <= container #include "contrib/GTK/SATS/gtk/gtktogglebutton.sats" #include "contrib/GTK/SATS/gtk/gtktoolbar.sats" #include "contrib/GTK/SATS/gtk/gtktoolbutton.sats" #include "contrib/GTK/SATS/gtk/gtkvbox.sats" #include "contrib/GTK/SATS/gtk/gtkvpaned.sats" #include "contrib/GTK/SATS/gtk/gtkvruler.sats" #include "contrib/GTK/SATS/gtk/gtkvscale.sats" #include "contrib/GTK/SATS/gtk/gtkvscrollbar.sats" #include "contrib/GTK/SATS/gtk/gtkvseparator.sats" #include "contrib/GTK/SATS/gtk/gtkwidget.sats" #include "contrib/GTK/SATS/gtk/gtkwindow.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gtk/gtkmain.sats" (* ****** ****** *) (* end of [gtk.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gtkclassdec.sats0000664000175000017500000001620412223166165022025 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef GObject = $GOBJ.GObject stadef GInitiallyUnowned = $GOBJ.GInitiallyUnowned stadef GInterface = $GOBJ.GInterface (* ****** ****** *) classdec GtkAccelGroup : GObject classdec GtkClipBoard : GObject classdec GtkFileChooser : GInterface (* ****** ****** *) // // class hierarchy for GTK // classdec GtkObject : GInitiallyUnowned classdec GtkWidget : GtkObject classdec GtkMisc : GtkWidget classdec GtkLabel : GtkMisc classdec GtkArrow : GtkMisc classdec GtkImage : GtkMisc classdec GtkPixmap : GtkMisc // end of [GtkMisc] classdec GtkContainer : GtkWidget classdec GtkBin : GtkContainer classdec GtkAlignment : GtkBin classdec GtkFrame : GtkBin classdec GtkAspectFrame : GtkFrame // end of [GtkGrame] classdec GtkButton : GtkBin classdec GtkToggleButton : GtkButton classdec GtkCheckButton : GtkToggleButton classdec GtkRadioButton : GtkCheckButton // end of [GtkCheckButton] // end of [GtkToggleButton] classdec GtkOptionMenu : GtkButton // end of [GtkButton] classdec GtkItem : GtkBin classdec GtkMenuItem : GtkItem classdec GtkCheckMenuItem : GtkMenuItem classdec GtkRadioMenuItem : GtkCheckMenuItem // end of [GtkCheckMenuItem] classdec GtkImageMenuItem : GtkMenuItem classdec GtkSeparatorMenuItem : GtkMenuItem classdec GtkTearoffMenuItem : GtkMenuItem // end of [GtkMenuItem] // classdec GtkListItem : GtkItem // deprecated since GTK+-2.0 // classdec GtkTreeItem : GtkItem // deprecated since GTK+-2.0 // end of [GtkItem] classdec GtkToolItem : GtkBin classdec GtkToolButton : GtkToolItem classdec GtkSeparatorToolItem : GtkToolItem // end of [GtkToolItem] classdec GtkWindow : GtkBin classdec GtkDialog : GtkWindow classdec GtkColorSelectionDialog : GtkDialog classdec GtkFileSelection : GtkDialog // DEPRECATED! classdec GtkFileChooserDialog : GtkDialog classdec GtkFontSelectionDialog : GtkDialog classdec GtkInputDialog : GtkDialog classdec GtkMessageDialog : GtkDialog // end of [GtkDialog] classdec GtkPlug : GtkWindow // end of [GtkWindow] classdec GtkEventBox : GtkBin classdec GtkHandleBox : GtkBin classdec GtkScrolledWindow : GtkBin classdec GtkViewport : GtkBin // end of [GtkBin] classdec GtkBox : GtkContainer classdec GtkBottonBox : GtkBox classdec GtkBottonHBox : GtkBottonBox classdec GtkBottonVBox : GtkBottonBox // end of [GtkBottonBox] classdec GtkVBox : GtkBox classdec GtkColorSelection : GtkVBox classdec GtkFontSelection : GtkVBox classdec GtkGammarCurve : GtkVBox // end of [GtkVBox] classdec GtkHBox : GtkBox classdec GtkCombo : GtkHBox classdec GtkStatusbar : GtkHBox // end of [GtkHBox] // end of [GtkBox] classdec GtkFixed : GtkContainer classdec GtkPaned : GtkContainer classdec GtkHPaned : GtkPaned classdec GtkVPaned : GtkPaned // end of [GtkPaned] classdec GtkLayout : GtkContainer classdec GtkMenuShell : GtkContainer classdec GtkMenuBar : GtkMenuShell classdec GtkMenu : GtkMenuShell // end of [GtkMenuShell] classdec GtkNotebook : GtkContainer classdec GtkSocket : GtkContainer classdec GtkTable : GtkContainer classdec GtkTextView : GtkContainer classdec GtkToolbar : GtkContainer classdec GtkTreeView : GtkContainer // end of [GtkContainer] classdec GtkCalendar : GtkWidget classdec GtkDrawingArea : GtkWidget classdec GtkCurve : GtkDrawingArea // end of [GtkDrawingArea] classdec GtkEditable : GtkWidget classdec GtkEntry : GtkEditable classdec GtkSpinButton : GtkEntry // end of [GtkEntry] // end of [GtkEditable] classdec GtkRuler : GtkWidget classdec GtkHRuler : GtkRuler classdec GtkVRuler : GtkRuler // end of [GtkScale] classdec GtkRange : GtkWidget classdec GtkScale : GtkRange classdec GtkHScale : GtkScale classdec GtkVScale : GtkScale // end of [GtkScale] classdec GtkScrollbar : GtkRange classdec GtkHScrollbar : GtkScrollbar classdec GtkVScrollbar : GtkScrollbar // end of [GtkScrollbar] // end of [GtkRange] classdec GtkSeparator : GtkWidget classdec GtkHSeparator : GtkSeparator classdec GtkVSeparator : GtkSeparator // end of [GtkSeparator] classdec GtkInvisible : GtkWidget classdec GtkPreview : GtkWidget classdec GtkProgress : GtkWidget // DEPRECATED!!! classdec GtkProgressBar : GtkProgress // end of [GtkProgress] // end of [GtkWidget] classdec GtkAdjustment : GtkObject classdec GtkCellRenderer : GtkObject classdec GtkCellRendererPixbuf : GtkCellRenderer classdec GtkCellRendererText : GtkCellRenderer classdec GtkCellRendererToggle : GtkCellRenderer // end of [GtkCellRenderer] classdec GtkItemFactory : GtkObject classdec GtkTooltips : GtkObject classdec GtkTreeViewColumn : GtkObject // end of [GtkObject] (* ****** ****** *) classdec GtkStyle : GObject (* ****** ****** *) classdec GtkTextBuffer : GObject classdec GtkTextTag : GObject classdec GtkTextTagTable : GObject classdec GtkTextMark : GObject (* ****** ****** *) (* end of [gtkclassdec.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk.sats0000664000175000017500000000733712223166165020312 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) %{# #include "contrib/GTK/CATS/gdk.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staload at run-time (* ****** ****** *) staload GLIB = "contrib/glib/SATS/glib.sats" // stadef gboolean (b:bool) = $GLIB.gboolean b stadef gboolean = $GLIB.gboolean // stadef gchar = $GLIB.gchar // stadef gint = $GLIB.gint stadef gint8 = $GLIB.gint8 stadef gint16 = $GLIB.gint16 stadef gint32 = $GLIB.gint32 // stadef guint = $GLIB.guint stadef guint8 = $GLIB.guint8 stadef guint16 = $GLIB.guint16 stadef guint32 = $GLIB.guint32 // stadef gfloat = $GLIB.gfloat stadef gdouble = $GLIB.gdouble // stadef gpointer = $GLIB.gpointer // stadef gstring = $GLIB.gstring stadef gstring0 = $GLIB.gstring0 stadef gstring1 = $GLIB.gstring1 // (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef gobjref = $GOBJ.gobjref (* ****** ****** *) absview GdkFree_v (l:addr) // for free GDK resources (* ****** ****** *) staload "contrib/GTK/SATS/gdkclassdec.sats" (* ****** ****** *) viewtypedef GdkColormap_ref (l:addr) = gobjref (GdkColormap, l) viewtypedef GdkColormap_ref0 = [l:agez] GdkColormap_ref l viewtypedef GdkColormap_ref1 = [l:addr | l > null] GdkColormap_ref l viewtypedef GdkPixbuf_ref (l:addr) = gobjref (GdkPixbuf, l) viewtypedef GdkPixbuf_ref0 = [l:agez] GdkPixbuf_ref l viewtypedef GdkPixbuf_ref1 = [l:addr | l > null] GdkPixbuf_ref l viewtypedef GdkPixmap_ref (l:addr) = gobjref (GdkPixmap, l) viewtypedef GdkPixmap_ref0 = [l:agez] GdkPixmap_ref l viewtypedef GdkPixmap_ref1 = [l:addr | l > null] GdkPixmap_ref l viewtypedef GdkWindow_ref (l:addr) = gobjref (GdkWindow, l) viewtypedef GdkWindow_ref0 = [l:agez] GdkWindow_ref l viewtypedef GdkWindow_ref1 = [l:addr | l > null] GdkWindow_ref l (* ****** ****** *) #include "contrib/GTK/SATS/gdk/gdktypes.sats" (* ****** ****** *) #include "contrib/GTK/SATS/gdk/gdkcairo.sats" #include "contrib/GTK/SATS/gdk/gdkcolor.sats" #include "contrib/GTK/SATS/gdk/gdkevents.sats" #include "contrib/GTK/SATS/gdk/gdkkeys.sats" #include "contrib/GTK/SATS/gdk/gdkpixbuf.sats" #include "contrib/GTK/SATS/gdk/gdkpixmap.sats" #include "contrib/GTK/SATS/gdk/gdkrgb.sats" #include "contrib/GTK/SATS/gdk/gdkselection.sats" #include "contrib/GTK/SATS/gdk/gdkwindow.sats" (* ****** ****** *) (* end of [gdk.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/0000700000175000017500000000000012223166165017370 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkevents.sats0000664000175000017500000002353112223166165022276 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) macdef GDK_NOTHING = $extval (GdkEventType, "GDK_NOTHING") macdef GDK_DELETE = $extval (GdkEventType, "GDK_DELETE") macdef GDK_DESTROY = $extval (GdkEventType, "GDK_DESTROY") macdef GDK_EXPOSE = $extval (GdkEventType, "GDK_EXPOSE") macdef GDK_MOTION_NOTIFY = $extval (GdkEventType, "GDK_MOTION_NOTIFY") macdef GDK_BUTTON_PRESS = $extval (GdkEventType, "GDK_BUTTON_PRESS") macdef GDK_2BUTTON_PRESS = $extval (GdkEventType, "GDK_2BUTTON_PRESS") macdef GDK_3BUTTON_PRESS = $extval (GdkEventType, "GDK_3BUTTON_PRESS") macdef GDK_BUTTON_RELEASE = $extval (GdkEventType, "GDK_BUTTON_RELEASE") macdef GDK_KEY_PRESS = $extval (GdkEventType, "GDK_KEY_PRESS") macdef GDK_KEY_RELEASE = $extval (GdkEventType, "GDK_KEY_RELEASE") macdef GDK_ENTER_NOTIFY = $extval (GdkEventType, "GDK_ENTER_NOTIFY") macdef GDK_LEAVE_NOTIFY = $extval (GdkEventType, "GDK_LEAVE_NOTIFY") macdef GDK_FOCUS_CHANGE = $extval (GdkEventType, "GDK_FOCUS_CHANGE") macdef GDK_CONFIGURE = $extval (GdkEventType, "GDK_CONFIGURE") macdef GDK_MAP = $extval (GdkEventType, "GDK_MAP") macdef GDK_UNMAP = $extval (GdkEventType, "GDK_UNMAP") macdef GDK_PROPERTY_NOTIFY = $extval (GdkEventType, "GDK_PROPERTY_NOTIFY") macdef GDK_SELECTION_CLEAR = $extval (GdkEventType, "GDK_SELECTION_CLEAR") macdef GDK_SELECTION_REQUEST = $extval (GdkEventType, "GDK_SELECTION_REQUEST") macdef GDK_SELECTION_NOTIFY = $extval (GdkEventType, "GDK_SELECTION_NOTIFY") macdef GDK_PROXIMITY_IN = $extval (GdkEventType, "GDK_PROXIMITY_IN") macdef GDK_PROXIMITY_OUT = $extval (GdkEventType, "GDK_PROXIMITY_OUT") macdef GDK_DRAG_ENTER = $extval (GdkEventType, "GDK_DRAG_ENTER") macdef GDK_DRAG_LEAVE = $extval (GdkEventType, "GDK_DRAG_LEAVE") macdef GDK_DRAG_MOTION = $extval (GdkEventType, "GDK_DRAG_MOTION") macdef GDK_DRAG_STATUS = $extval (GdkEventType, "GDK_DRAG_STATUS") macdef GDK_DROP_START = $extval (GdkEventType, "GDK_DROP_START") macdef GDK_DROP_FINISHED = $extval (GdkEventType, "GDK_DROP_FINISHED") macdef GDK_CLIENT_EVENT = $extval (GdkEventType, "GDK_CLIENT_EVENT") macdef GDK_VISIBILITY_NOTIFY = $extval (GdkEventType, "GDK_VISIBILITY_NOTIFY") macdef GDK_NO_EXPOSE = $extval (GdkEventType, "GDK_NO_EXPOSE") macdef GDK_SCROLL = $extval (GdkEventType, "GDK_SCROLL") macdef GDK_WINDOW_STATE = $extval (GdkEventType, "GDK_WINDOW_STATE") macdef GDK_SETTING = $extval (GdkEventType, "GDK_SETTING") macdef GDK_OWNER_CHANGE = $extval (GdkEventType, "GDK_OWNER_CHANGE") macdef GDK_GRAB_BROKEN = $extval (GdkEventType, "GDK_GRAB_BROKEN") macdef GDK_DAMAGE = $extval (GdkEventType, "GDK_DAMAGE") fun eq_GdkEventType_GdkEventType ( x1: GdkEventType, x2: GdkEventType ) : bool = "mac#atsctrb_eq_GdkEventType_GdkEventType" overload = with eq_GdkEventType_GdkEventType (* ****** ****** *) macdef GDK_EXPOSURE_MASK = $extval (GdkEventMask, "GDK_EXPOSURE_MASK") macdef GDK_POINTER_MOTION_MASK = $extval (GdkEventMask, "GDK_POINTER_MOTION_MASK") macdef GDK_POINTER_MOTION_HINT_MASK = $extval (GdkEventMask, "GDK_POINTER_MOTION_HINT_MASK") macdef GDK_BUTTON_MOTION_MASK = $extval (GdkEventMask, "GDK_BUTTON_MOTION_MASK") macdef GDK_BUTTON1_MOTION_MASK = $extval (GdkEventMask, "GDK_BUTTON1_MOTION_MASK") macdef GDK_BUTTON2_MOTION_MASK = $extval (GdkEventMask, "GDK_BUTTON2_MOTION_MASK") macdef GDK_BUTTON3_MOTION_MASK = $extval (GdkEventMask, "GDK_BUTTON3_MOTION_MASK") macdef GDK_BUTTON_PRESS_MASK = $extval (GdkEventMask, "GDK_BUTTON_PRESS_MASK") macdef GDK_BUTTON_RELEASE_MASK = $extval (GdkEventMask, "GDK_BUTTON_RELEASE_MASK") macdef GDK_KEY_PRESS_MASK = $extval (GdkEventMask, "GDK_KEY_PRESS_MASK") macdef GDK_KEY_RELEASE_MASK = $extval (GdkEventMask, "GDK_KEY_RELEASE_MASK") macdef GDK_ENTER_NOTIFY_MASK = $extval (GdkEventMask, "GDK_ENTER_NOTIFY_MASK") macdef GDK_LEAVE_NOTIFY_MASK = $extval (GdkEventMask, "GDK_LEAVE_NOTIFY_MASK") macdef GDK_FOCUS_CHANGE_MASK = $extval (GdkEventMask, "GDK_FOCUS_CHANGE_MASK") macdef GDK_STRUCTURE_MASK = $extval (GdkEventMask, "GDK_STRUCTURE_MASK") macdef GDK_PROPERTY_CHANGE_MASK = $extval (GdkEventMask, "GDK_PROPERTY_CHANGE_MASK") macdef GDK_VISIBILITY_NOTIFY_MASK = $extval (GdkEventMask, "GDK_VISIBILITY_NOTIFY_MASK") macdef GDK_PROXIMITY_IN_MASK = $extval (GdkEventMask, "GDK_PROXIMITY_IN_MASK") macdef GDK_PROXIMITY_OUT_MASK = $extval (GdkEventMask, "GDK_PROXIMITY_OUT_MASK") macdef GDK_SUBSTRUCTURE_MASK = $extval (GdkEventMask, "GDK_SUBSTRUCTURE_MASK") macdef GDK_SCROLL_MASK = $extval (GdkEventMask, "GDK_SCROLL_MASK") macdef GDK_ALL_EVENTS_MASK = $extval (GdkEventMask, "GDK_ALL_EVENTS_MASK") castfn gint_of_GdkEventMask (x: GdkEventMask):<> gint fun lor_GdkEventMask_GdkEventMask (x1: GdkEventMask, x2: GdkEventMask): GdkEventMask = "atsctrb_lor_GdkEventMask_GdkEventMask" overload lor with lor_GdkEventMask_GdkEventMask (* ****** ****** *) macdef GDK_VISIBILITY_UNOBSCURED = $extval (GdkVisibilityState, "GDK_VISIBILITY_UNOBSCURED") macdef GDK_VISIBILITY_PARTIAL = $extval (GdkVisibilityState, "GDK_VISIBILITY_PARTIAL") macdef GDK_VISIBILITY_FULLY_OBSCURED = $extval (GdkVisibilityState, "GDK_VISIBILITY_FULLY_OBSCURED") fun eq_GdkVisibilityState_GdkVisibilityState (x1: GdkVisibilityState, x2: GdkVisibilityState): bool = "atsctrb_eq_GdkVisibilityState_GdkVisibilityState" overload = with eq_GdkVisibilityState_GdkVisibilityState (* ****** ****** *) macdef GDK_WINDOW_STATE_WITHDRAWN = $extval (GdkWindowState, "GDK_WINDOW_STATE_WITHDRAWN") macdef GDK_WINDOW_STATE_ICONIFIED = $extval (GdkWindowState, "GDK_WINDOW_STATE_ICONIFIED") macdef GDK_WINDOW_STATE_MAXIMIZED = $extval (GdkWindowState, "GDK_WINDOW_STATE_MAXIMIZED") macdef GDK_WINDOW_STATE_STICKY = $extval (GdkWindowState, "GDK_WINDOW_STATE_STICKY") macdef GDK_WINDOW_STATE_FULLSCREEN = $extval (GdkWindowState, "GDK_WINDOW_STATE_FULLSCREEN") macdef GDK_WINDOW_STATE_ABOVE = $extval (GdkWindowState, "GDK_WINDOW_STATE_ABOVE") macdef GDK_WINDOW_STATE_BELOW = $extval (GdkWindowState, "GDK_WINDOW_STATE_BELOW") (* ****** ****** *) typedef GdkEvent = $extype_struct "GdkEvent" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , _rest= undefined_t // this field cannot be accessed } // end of [GdkEvent] propdef GdkEvent_castdn_t (a:t@ype) = {l:addr} (GdkEvent @ l) - (a @ l, a @ l - GdkEvent @ l) // end of [GdkEvent_castdn_t] (* ****** ****** *) typedef GdkEventAny = $extype_struct "GdkEventAny" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 } // end of [GdkEventAny] praxi GdkEventAny_castdn : GdkEvent_castdn_t (GdkEventAny) (* ****** ****** *) typedef GdkEventButton = $extype_struct "GdkEventButton" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , time= guint32 , x= gdouble, y= gdouble // gdouble *axes; , state= guint , button= guint , device= ptr // GdkDevice *device; , x_root= gdouble, y_root= gdouble , _res= undefined_t // this field cannot be accessed } // end of [GdkEventButton] praxi GdkEventButton_castdn : GdkEvent_castdn_t (GdkEventButton) (* ****** ****** *) typedef GdkEventExpose = $extype_struct "GdkEventExpose" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , area= GdkRectangle , region= ptr // GdkRegion *region; , count = gint // the number of events that follow } // end of [GdkEventExpose] praxi GdkEventExpose_castdn : GdkEvent_castdn_t (GdkEventExpose) (* ****** ****** *) typedef GdkEventNoExpose = $extype_struct "GdkNoEventExpose" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 } // end of [GdkEventNoExpose] (* ****** ****** *) typedef GdkEventVisibility = $extype_struct "GdkEventVisibility" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , state= GdkVisibilityState } // end of [GdkEventVisibility] (* ****** ****** *) typedef GdkEventMotion = $extype_struct "GdkEventMotion" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , time= guint32 , x= gdouble , y= gdouble , axes= ptr // gdouble *axes; , state= guint , is_hint= gint16 , device= ptr // GdkDevice *device; , x_root= gdouble , y_root= gdouble } // end of [GdkEventMotion] (* ****** ****** *) typedef GdkEventKey = $extype_struct "GdkEventKey" of { type= GdkEventType , window= ptr // GdkWindow *window; , send_event= gint8 , time= guint32 , state= guint , keyval= guint , length= gint , string= ptr // gchar* , hardware_keycode= guint16 , group= guint8 (* , is_modifier= guint : 1 *) } // end of [GdkEventKey] (* ****** ****** *) (* end of [gdkevents.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdktypes.sats0000664000175000017500000001044712223166165022140 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) typedef GdkColor = $extype_struct "GdkColor" of { pixel= guint32, red= guint16, green= guint16, blue= guint16 } // end of [GdkColor] (* ****** ****** *) typedef GdkPoint = $extype_struct "GdkPoint" of { x= gint, y= gint } // end of [GdkPoint] (* ****** ****** *) typedef GdkRectangle = $extype_struct "GdkRectangle" of { x= gint , y= gint , width= gint , height= gint } // end of [GdkRectangle] (* ****** ****** *) // // HX-2010-05-16: it is defined in gdkregion-generic.h // typedef GdkRegion = $extype_struct "GdkRegion" of { size= lint // a long integer , numRects= lint // a long integer // , GdkRegionBox *rects // , extents= GdkRegionBox } // end of [GdkRegion] (* ****** ****** *) typedef GdkSegment = $extype_struct "GdkSegment" of { x1= gint , y1= gint , x2= gint , y2= gint } // end of [GdkSegment] (* ****** ****** *) typedef GdkSpan = $extype_struct "GdkSpan" of { x= gint, y= gint, width= gint(*number of pixels in a span*) } // end of [GdkSpan] (* ****** ****** *) abst@ype GdkWChar = $extype"GdKWChar" (* ****** ****** *) abstype GdkAtom // typedef struct _GdkAtom *GdkAtom castfn GDK_ATOM_TO_POINTER (x: GdkAtom):<> gpointer castfn GDK_POINTER_TO_ATOM (x: gpointer):<> GdkAtom macdef GDK_NONE = $extval (GdkAtom, "GDK_NONE") (* ****** ****** *) abst@ype GdkEventType = $extype"GdkEventType" abst@ype GdkEventMask = $extype"GdkEventMask" (* ****** ****** *) abst@ype GdkModifierType = $extype"GdkModifierType" macdef GDK_SHIFT_MASK = $extval (GdkModifierType, "GDK_SHIFT_MASK") macdef GDK_LOCK_MASK = $extval (GdkModifierType, "GDK_LOCK_MASK") macdef GDK_CONTROL_MASK = $extval (GdkModifierType, "GDK_CONTROL_MASK") macdef GDK_MOD1_MASK = $extval (GdkModifierType, "GDK_MOD1_MASK") macdef GDK_MOD2_MASK = $extval (GdkModifierType, "GDK_MOD2_MASK") macdef GDK_MOD3_MASK = $extval (GdkModifierType, "GDK_MOD3_MASK") macdef GDK_MOD4_MASK = $extval (GdkModifierType, "GDK_MOD4_MASK") macdef GDK_MOD5_MASK = $extval (GdkModifierType, "GDK_MOD5_MASK") macdef GDK_BUTTON1_MASK = $extval (GdkModifierType, "GDK_BUTTON1_MASK") macdef GDK_BUTTON2_MASK = $extval (GdkModifierType, "GDK_BUTTON2_MASK") macdef GDK_BUTTON3_MASK = $extval (GdkModifierType, "GDK_BUTTON3_MASK") macdef GDK_BUTTON4_MASK = $extval (GdkModifierType, "GDK_BUTTON4_MASK") macdef GDK_BUTTON5_MASK = $extval (GdkModifierType, "GDK_BUTTON5_MASK") macdef GDK_SUPER_MASK = $extval (GdkModifierType, "GDK_SUPER_MASK") macdef GDK_HYPER_MASK = $extval (GdkModifierType, "GDK_HYPER_MASK") macdef GDK_META_MASK = $extval (GdkModifierType, "GDK_META_MASK") macdef GDK_RELEASE_MASK = $extval (GdkModifierType, "GDK_RELEASE_MASK") macdef GDK_MODIFIER_MASK = $extval (GdkModifierType, "GDK_MODIFIER_MASK") (* ****** ****** *) abst@ype GdkVisibilityState = $extype"GdkVisibilityState" abst@ype GdkWindowState = $extype"GdkWindowState" (* ****** ****** *) (* end of [gdktypes.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkrgb.sats0000664000175000017500000000327612223166165021550 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gdk_rgb_find_color {c:cls | c <= GdkColormap} {l:agz} ( cm: !gobjref (c, l), color: &GdkColor ) : void = "mac#atsctrb_gdk_rgb_find_color" // end of [gdk_rgb_find_color] (* ****** ****** *) (* end of [gdkrgb.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkwindow.sats0000664000175000017500000002145112223166165022300 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) abst@ype GdkWindowType = $extype"GdkWindowType" macdef GDK_WINDOW_ROOT = $extval (GdkWindowType, "GDK_WINDOW_ROOT") macdef GDK_WINDOW_TOPLEVEL = $extval (GdkWindowType, "GDK_WINDOW_TOPLEVEL") macdef GDK_WINDOW_CHILD = $extval (GdkWindowType, "GDK_WINDOW_CHILD") macdef GDK_WINDOW_DIALOG = $extval (GdkWindowType, "GDK_WINDOW_DIALOG") macdef GDK_WINDOW_TEMP = $extval (GdkWindowType, "GDK_WINDOW_TEMP") macdef GDK_WINDOW_FOREIGN = $extval (GdkWindowType, "GDK_WINDOW_FOREIGN") (* ****** ****** *) abst@ype GdkWindowAttributesType = $extype"GdkWindowAttributesType" macdef GDK_WA_TITLE = $extval (GdkWindowAttributesType, "GDK_WA_TITLE") macdef GDK_WA_X = $extval (GdkWindowAttributesType, "GDK_WA_X") macdef GDK_WA_Y = $extval (GdkWindowAttributesType, "GDK_WA_Y") macdef GDK_WA_CURSOR = $extval (GdkWindowAttributesType, "GDK_WA_CURSOR") macdef GDK_WA_COLORMAP = $extval (GdkWindowAttributesType, "GDK_WA_COLORMAP") macdef GDK_WA_VISUAL = $extval (GdkWindowAttributesType, "GDK_WA_VISUAL") macdef GDK_WA_WMCLASS = $extval (GdkWindowAttributesType, "GDK_WA_WMCLASS") macdef GDK_WA_NOREDIR = $extval (GdkWindowAttributesType, "GDK_WA_NOREDIR") macdef GDK_WA_TYPE_HINT = $extval (GdkWindowAttributesType, "GDK_WA_TYPE_HINT") (* ****** ****** *) abst@ype GdkWindowHints = $extype"GdkWindowHints" macdef GDK_HINT_POS = $extval (GdkWindowHints, "GDK_HINT_POS") macdef GDK_HINT_MIN_SIZE = $extval (GdkWindowHints, "GDK_HINT_MIN_SIZE") macdef GDK_HINT_MAX_SIZE = $extval (GdkWindowHints, "GDK_HINT_MAX_SIZE") macdef GDK_HINT_BASE_SIZE = $extval (GdkWindowHints, "GDK_HINT_BASE_SIZE") macdef GDK_HINT_ASPECT = $extval (GdkWindowHints, "GDK_HINT_ASPECT") macdef GDK_HINT_RESIZE_INC = $extval (GdkWindowHints, "GDK_HINT_RESIZE_INC") macdef GDK_HINT_WIN_GRAVITY = $extval (GdkWindowHints, "GDK_HINT_WIN_GRAVITY") macdef GDK_HINT_USER_POS = $extval (GdkWindowHints, "GDK_HINT_USER_POS") macdef GDK_HINT_USER_SIZE = $extval (GdkWindowHints, "GDK_HINT_USER_SIZE") (* ****** ****** *) abst@ype GdkWindowTypeHint = $extype"GdkWindowTypeHint" macdef GDK_WINDOW_TYPE_HINT_NORMAL = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_NORMAL") macdef GDK_WINDOW_TYPE_HINT_DIALOG = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_DIALOG") macdef GDK_WINDOW_TYPE_HINT_MENU = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_MENU") macdef GDK_WINDOW_TYPE_HINT_TOOLBAR = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_TOOLBAR") macdef GDK_WINDOW_TYPE_HINT_SPLASHSCREEN = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_SPLASHSCREEN") macdef GDK_WINDOW_TYPE_HINT_UTILITY = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_UTILITY") macdef GDK_WINDOW_TYPE_HINT_DOCK = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_DOCK") macdef GDK_WINDOW_TYPE_HINT_DESKTOP = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_DESKTOP") macdef GDK_WINDOW_TYPE_HINT_DROPDOWN_MENU = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_DROPDOWN_MENU") macdef GDK_WINDOW_TYPE_HINT_POPUP_MENU = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_POPUP_MENU") macdef GDK_WINDOW_TYPE_HINT_TOOLTIP = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_TOOLTIP") macdef GDK_WINDOW_TYPE_HINT_NOTIFICATION = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_NOTIFICATION") macdef GDK_WINDOW_TYPE_HINT_COMBO = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_COMBO") macdef GDK_WINDOW_TYPE_HINT_DND = $extval (GdkWindowTypeHint, "GDK_WINDOW_TYPE_HINT_DND") (* ****** ****** *) (* ** The next two enumeration values current match the ** Motif constants. If this is changed, the implementation ** of gdk_window_set_decorations/gdk_window_set_functions ** will need to change as well. *) abst@ype GdkWMDecoration = $extype"GdkWMDecoration" macdef GDK_DECOR_ALL = $extval (GdkWMDecoration, "GDK_DECOR_ALL") macdef GDK_DECOR_BORDER = $extval (GdkWMDecoration, "GDK_DECOR_BORDER") macdef GDK_DECOR_RESIZEH = $extval (GdkWMDecoration, "GDK_DECOR_RESIZEH") macdef GDK_DECOR_TITLE = $extval (GdkWMDecoration, "GDK_DECOR_TITLE") macdef GDK_DECOR_MENU = $extval (GdkWMDecoration, "GDK_DECOR_MENU") macdef GDK_DECOR_MINIMIZE = $extval (GdkWMDecoration, "GDK_DECOR_MINIMIZE") macdef GDK_DECOR_MAXIMIZE = $extval (GdkWMDecoration, "GDK_DECOR_MAXIMIZE") abst@ype GdkWMFunction = $extype"GdkWMFunction" macdef GDK_FUNC_ALL = $extval (GdkWMFunction, "GDK_FUNC_ALL") macdef GDK_FUNC_RESIZE = $extval (GdkWMFunction, "GDK_FUNC_RESIZE") macdef GDK_FUNC_MOVE = $extval (GdkWMFunction, "GDK_FUNC_MOVE") macdef GDK_FUNC_MINIMIZE = $extval (GdkWMFunction, "GDK_FUNC_MINIMIZE") macdef GDK_FUNC_MAXIMIZE = $extval (GdkWMFunction, "GDK_FUNC_MAXIMIZE") macdef GDK_FUNC_CLOSE = $extval (GdkWMFunction, "GDK_FUNC_CLOSE") (* ****** ****** *) abst@ype GdkGravity = $extype"GdkGravity" macdef GDK_GRAVITY_NORTH_WEST = $extval (GdkGravity, "GDK_GRAVITY_NORTH_WEST") macdef GDK_GRAVITY_NORTH = $extval (GdkGravity, "GDK_GRAVITY_NORTH") macdef GDK_GRAVITY_NORTH_EAST = $extval (GdkGravity, "GDK_GRAVITY_NORTH_EAST") macdef GDK_GRAVITY_WEST = $extval (GdkGravity, "GDK_GRAVITY_WEST") macdef GDK_GRAVITY_CENTER = $extval (GdkGravity, "GDK_GRAVITY_CENTER") macdef GDK_GRAVITY_EAST = $extval (GdkGravity, "GDK_GRAVITY_EAST") macdef GDK_GRAVITY_SOUTH_WEST = $extval (GdkGravity, "GDK_GRAVITY_SOUTH_WEST") macdef GDK_GRAVITY_SOUTH = $extval (GdkGravity, "GDK_GRAVITY_SOUTH") macdef GDK_GRAVITY_SOUTH_EAST = $extval (GdkGravity, "GDK_GRAVITY_SOUTH_EAST") macdef GDK_GRAVITY_STATIC = $extval (GdkGravity, "GDK_GRAVITY_STATIC") abst@ype GdkWindowEdge = $extype"GdkWindowEdge" macdef GDK_WINDOW_EDGE_NORTH_WEST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_NORTH_WEST") macdef GDK_WINDOW_EDGE_NORTH = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_NORTH") macdef GDK_WINDOW_EDGE_NORTH_EAST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_NORTH_EAST") macdef GDK_WINDOW_EDGE_WEST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_WEST") macdef GDK_WINDOW_EDGE_EAST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_EAST") macdef GDK_WINDOW_EDGE_SOUTH_WEST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_SOUTH_WEST") macdef GDK_WINDOW_EDGE_SOUTH = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_SOUTH") macdef GDK_WINDOW_EDGE_SOUTH_EAST = $extval (GdkWindowEdge, "GDK_WINDOW_EDGE_SOUTH_EAST") (* ****** ****** *) fun gdk_window_set_background {c:cls | c <= GdkWindow} {l:addr} ( window: !gobjref (c, l), color: &GdkColor ) : void = "mac#atsctrb_gdk_window_set_background" // end of [gdk_window_set_background] (* ****** ****** *) (* void gdk_window_invalidate_rect ( GdkWindow *window, const GdkRectangle *rect, gboolean invalidate_children ) ; // end of [gdk_window_invalidate_rect] *) fun gdk_window_invalidate_rect {c:cls | c <= GdkWindow} {l:addr} ( window: !gobjref (c, l) , rect: &GdkRectangle, invalidate_children: gboolean ) : void = "mac#atsctrb_gdk_window_invalidate_rect" // end of [gdk_window_invalidate_rect] (* ****** ****** *) (* void gdk_window_process_updates ( GdkWindow *window, gboolean update_children ) ; // end of [gdk_window_process_updates] *) fun gdk_window_process_updates {c:cls | c <= GdkWindow} {l:addr} ( window: !gobjref (c, l), update_children: gboolean ) : void = "mac#atsctrb_gdk_window_process_updates" // end of [gdk_window_process_updates] (* void gdk_window_process_all_updates (void); *) fun gdk_window_process_all_updates (): void = "mac#atsctrb_gdk_window_process_all_updates" // end of [gdk_window_process_all_updates] (* ****** ****** *) (* end of [gdkwindow.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkpixmap.sats0000664000175000017500000000333612223166165022271 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gdk_pixmap_new {c:cls | c <= GdkDrawable} {l:agz} ( drawable: !gobjref (c, l) , height: gint , width: gint , depth: gint ) : GdkPixmap_ref1 = "mac#atsctrb_gdk_pixmap_new" // end of [gdk_pixmap_new] (* ****** ****** *) (* end of [gdkpixmap.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkcairo.sats0000664000175000017500000000605412223166165022070 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload CAIRO = "contrib/cairo/SATS/cairo.sats" stadef cairo_ref = $CAIRO.cairo_ref stadef cairo_ref1 = $CAIRO.cairo_ref1 (* ****** ****** *) fun gdk_cairo_create {c:cls | c <= GdkDrawable} {l:agz} ( widget: !gobjref (c, l) ) : cairo_ref1 = "mac#atsctrb_gdk_cairo_create" // end of [gdk_cairo_create] (* ****** ****** *) fun gdk_cairo_set_source_color {l:agz} ( cr: !cairo_ref l, color: &GdkColor ) : void = "mac#atsctrb_gdk_cairo_set_source_color" // end of [gdk_cairo_set_source_color] (* ****** ****** *) fun gdk_cairo_set_source_pixbuf {c:cls | c <= GdkPixbuf} {l1,l2:agz} ( cr: !cairo_ref l1 , pixbuf: !gobjref (c, l2) , x: double, y: double ) : void = "mac#atsctrb_gdk_cairo_set_source_pixbuf" // end of [gdk_cairo_set_source_pixbuf] fun gdk_cairo_set_source_pixmap {c:cls | c <= GdkPixmap} {l1,l2:agz} ( cr: !cairo_ref l1 , pixmap: !gobjref (c, l2) , x: double, y: double ) : void = "mac#atsctrb_gdk_cairo_set_source_pixmap" // end of [gdk_cairo_set_source_pixmap] (* ****** ****** *) fun gdk_cairo_rectangle {l:agz} ( cr: !cairo_ref l , rect: &GdkRectangle ) : void = "mac#atsctrb_gdk_cairo_rectangle" // end of [gdk_cairo_rectangle] (* ****** ****** *) fun gdk_cairo_region {l:agz} ( cr: !cairo_ref l , reg: &GdkRegion ) : void = "mac#atsctrb_gdk_cairo_region" // end of [gdk_cairo_region] (* ****** ****** *) fun gdk_cairo_reset_clip {c:cls | c <= GdkDrawable} {l1,l2:agz} ( cr: !cairo_ref l1 , drw: !gobjref (c, l2) ) : void = "mac#atsctrb_gdk_cairo_reset_clip" // end of [gdk_cairo_reset_clip] (* ****** ****** *) (* end of [gdkcairo.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkpixbuf.sats0000664000175000017500000000357512223166165022275 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) fun gdk_pixbuf_render_threshold_alpha {c1,c2:cls | c1 <= GdkPixbuf; c2 <= GdkBitmap} {l1,l2:agz} ( pixbuf: !gobjref (c1, l1) , bitmap: !gobjref (c2, l2) , src_x: int , src_y: int , dst_x: int , dst_y: int , width: int , height: int , alpha_threshold: int ) : void = "mac#atsctrb_gdk_pixbuf_render_threshold_alpha" // end of [gdk_pixbuf_render_threshold_alpha] (* ****** ****** *) (* end of [gdkpixbuf.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkselection.sats0000664000175000017500000000533512223166165022761 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) macdef GDK_SELECTION_PRIMARY = $extval (GdkAtom, "GDK_SELECTION_PRIMARY") macdef GDK_SELECTION_SECONDARY = $extval (GdkAtom, "GDK_SELECTION_SECONDARY") macdef GDK_SELECTION_CLIPBOARD = $extval (GdkAtom, "GDK_SELECTION_CLIPBOARD") macdef GDK_TARGET_BITMAP = $extval (GdkAtom, "GDK_TARGET_BITMAP") macdef GDK_TARGET_COLORMAP = $extval (GdkAtom, "GDK_TARGET_COLORMAP") macdef GDK_TARGET_DRAWABLE = $extval (GdkAtom, "GDK_TARGET_DRAWABLE") macdef GDK_TARGET_PIXMAP = $extval (GdkAtom, "GDK_TARGET_PIXMAP") macdef GDK_TARGET_STRING = $extval (GdkAtom, "GDK_TARGET_STRING") macdef GDK_SELECTION_TYPE_ATOM = $extval (GdkAtom, "GDK_SELECTION_TYPE_ATOM") macdef GDK_SELECTION_TYPE_BITMAP = $extval (GdkAtom, "GDK_SELECTION_TYPE_BITMAP") macdef GDK_SELECTION_TYPE_COLORMAP = $extval (GdkAtom, "GDK_SELECTION_TYPE_COLORMAP") macdef GDK_SELECTION_TYPE_DRAWABLE = $extval (GdkAtom, "GDK_SELECTION_TYPE_DRAWABLE") macdef GDK_SELECTION_TYPE_INTEGER = $extval (GdkAtom, "GDK_SELECTION_TYPE_INTEGER") macdef GDK_SELECTION_TYPE_PIXMAP = $extval (GdkAtom, "GDK_SELECTION_TYPE_PIXMAP") macdef GDK_SELECTION_TYPE_WINDOW = $extval (GdkAtom, "GDK_SELECTION_TYPE_WINDOW") macdef GDK_SELECTION_TYPE_STRING = $extval (GdkAtom, "GDK_SELECTION_TYPE_STRING") (* ****** ****** *) (* end of [gdkselection.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkkeys.sats0000664000175000017500000017172612223166165021757 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) #define GDK_VoidSymbol 0xffffff #define GDK_BackSpace 0xff08 #define GDK_Tab 0xff09 #define GDK_Linefeed 0xff0a #define GDK_Clear 0xff0b #define GDK_Return 0xff0d #define GDK_Pause 0xff13 #define GDK_Scroll_Lock 0xff14 #define GDK_Sys_Req 0xff15 #define GDK_Escape 0xff1b #define GDK_Delete 0xffff #define GDK_Multi_key 0xff20 #define GDK_Codeinput 0xff37 #define GDK_SingleCandidate 0xff3c #define GDK_MultipleCandidate 0xff3d #define GDK_PreviousCandidate 0xff3e #define GDK_Kanji 0xff21 #define GDK_Muhenkan 0xff22 #define GDK_Henkan_Mode 0xff23 #define GDK_Henkan 0xff23 #define GDK_Romaji 0xff24 #define GDK_Hiragana 0xff25 #define GDK_Katakana 0xff26 #define GDK_Hiragana_Katakana 0xff27 #define GDK_Zenkaku 0xff28 #define GDK_Hankaku 0xff29 #define GDK_Zenkaku_Hankaku 0xff2a #define GDK_Touroku 0xff2b #define GDK_Massyo 0xff2c #define GDK_Kana_Lock 0xff2d #define GDK_Kana_Shift 0xff2e #define GDK_Eisu_Shift 0xff2f #define GDK_Eisu_toggle 0xff30 #define GDK_Kanji_Bangou 0xff37 #define GDK_Zen_Koho 0xff3d #define GDK_Mae_Koho 0xff3e #define GDK_Home 0xff50 #define GDK_Left 0xff51 #define GDK_Up 0xff52 #define GDK_Right 0xff53 #define GDK_Down 0xff54 #define GDK_Prior 0xff55 #define GDK_Page_Up 0xff55 #define GDK_Next 0xff56 #define GDK_Page_Down 0xff56 #define GDK_End 0xff57 #define GDK_Begin 0xff58 #define GDK_Select 0xff60 #define GDK_Print 0xff61 #define GDK_Execute 0xff62 #define GDK_Insert 0xff63 #define GDK_Undo 0xff65 #define GDK_Redo 0xff66 #define GDK_Menu 0xff67 #define GDK_Find 0xff68 #define GDK_Cancel 0xff69 #define GDK_Help 0xff6a #define GDK_Break 0xff6b #define GDK_Mode_switch 0xff7e #define GDK_script_switch 0xff7e #define GDK_Num_Lock 0xff7f #define GDK_KP_Space 0xff80 #define GDK_KP_Tab 0xff89 #define GDK_KP_Enter 0xff8d #define GDK_KP_F1 0xff91 #define GDK_KP_F2 0xff92 #define GDK_KP_F3 0xff93 #define GDK_KP_F4 0xff94 #define GDK_KP_Home 0xff95 #define GDK_KP_Left 0xff96 #define GDK_KP_Up 0xff97 #define GDK_KP_Right 0xff98 #define GDK_KP_Down 0xff99 #define GDK_KP_Prior 0xff9a #define GDK_KP_Page_Up 0xff9a #define GDK_KP_Next 0xff9b #define GDK_KP_Page_Down 0xff9b #define GDK_KP_End 0xff9c #define GDK_KP_Begin 0xff9d #define GDK_KP_Insert 0xff9e #define GDK_KP_Delete 0xff9f #define GDK_KP_Multiply 0xffaa #define GDK_KP_Add 0xffab #define GDK_KP_Separator 0xffac #define GDK_KP_Subtract 0xffad #define GDK_KP_Decimal 0xffae #define GDK_KP_Divide 0xffaf #define GDK_KP_0 0xffb0 #define GDK_KP_1 0xffb1 #define GDK_KP_2 0xffb2 #define GDK_KP_3 0xffb3 #define GDK_KP_4 0xffb4 #define GDK_KP_5 0xffb5 #define GDK_KP_6 0xffb6 #define GDK_KP_7 0xffb7 #define GDK_KP_8 0xffb8 #define GDK_KP_9 0xffb9 #define GDK_KP_Equal 0xffbd #define GDK_F1 0xffbe #define GDK_F2 0xffbf #define GDK_F3 0xffc0 #define GDK_F4 0xffc1 #define GDK_F5 0xffc2 #define GDK_F6 0xffc3 #define GDK_F7 0xffc4 #define GDK_F8 0xffc5 #define GDK_F9 0xffc6 #define GDK_F10 0xffc7 #define GDK_F11 0xffc8 #define GDK_L1 0xffc8 #define GDK_F12 0xffc9 #define GDK_L2 0xffc9 #define GDK_F13 0xffca #define GDK_L3 0xffca #define GDK_F14 0xffcb #define GDK_L4 0xffcb #define GDK_F15 0xffcc #define GDK_L5 0xffcc #define GDK_F16 0xffcd #define GDK_L6 0xffcd #define GDK_F17 0xffce #define GDK_L7 0xffce #define GDK_F18 0xffcf #define GDK_L8 0xffcf #define GDK_F19 0xffd0 #define GDK_L9 0xffd0 #define GDK_F20 0xffd1 #define GDK_L10 0xffd1 #define GDK_F21 0xffd2 #define GDK_R1 0xffd2 #define GDK_F22 0xffd3 #define GDK_R2 0xffd3 #define GDK_F23 0xffd4 #define GDK_R3 0xffd4 #define GDK_F24 0xffd5 #define GDK_R4 0xffd5 #define GDK_F25 0xffd6 #define GDK_R5 0xffd6 #define GDK_F26 0xffd7 #define GDK_R6 0xffd7 #define GDK_F27 0xffd8 #define GDK_R7 0xffd8 #define GDK_F28 0xffd9 #define GDK_R8 0xffd9 #define GDK_F29 0xffda #define GDK_R9 0xffda #define GDK_F30 0xffdb #define GDK_R10 0xffdb #define GDK_F31 0xffdc #define GDK_R11 0xffdc #define GDK_F32 0xffdd #define GDK_R12 0xffdd #define GDK_F33 0xffde #define GDK_R13 0xffde #define GDK_F34 0xffdf #define GDK_R14 0xffdf #define GDK_F35 0xffe0 #define GDK_R15 0xffe0 #define GDK_Shift_L 0xffe1 #define GDK_Shift_R 0xffe2 #define GDK_Control_L 0xffe3 #define GDK_Control_R 0xffe4 #define GDK_Caps_Lock 0xffe5 #define GDK_Shift_Lock 0xffe6 #define GDK_Meta_L 0xffe7 #define GDK_Meta_R 0xffe8 #define GDK_Alt_L 0xffe9 #define GDK_Alt_R 0xffea #define GDK_Super_L 0xffeb #define GDK_Super_R 0xffec #define GDK_Hyper_L 0xffed #define GDK_Hyper_R 0xffee #define GDK_ISO_Lock 0xfe01 #define GDK_ISO_Level2_Latch 0xfe02 #define GDK_ISO_Level3_Shift 0xfe03 #define GDK_ISO_Level3_Latch 0xfe04 #define GDK_ISO_Level3_Lock 0xfe05 #define GDK_ISO_Level5_Shift 0xfe11 #define GDK_ISO_Level5_Latch 0xfe12 #define GDK_ISO_Level5_Lock 0xfe13 #define GDK_ISO_Group_Shift 0xff7e #define GDK_ISO_Group_Latch 0xfe06 #define GDK_ISO_Group_Lock 0xfe07 #define GDK_ISO_Next_Group 0xfe08 #define GDK_ISO_Next_Group_Lock 0xfe09 #define GDK_ISO_Prev_Group 0xfe0a #define GDK_ISO_Prev_Group_Lock 0xfe0b #define GDK_ISO_First_Group 0xfe0c #define GDK_ISO_First_Group_Lock 0xfe0d #define GDK_ISO_Last_Group 0xfe0e #define GDK_ISO_Last_Group_Lock 0xfe0f #define GDK_ISO_Left_Tab 0xfe20 #define GDK_ISO_Move_Line_Up 0xfe21 #define GDK_ISO_Move_Line_Down 0xfe22 #define GDK_ISO_Partial_Line_Up 0xfe23 #define GDK_ISO_Partial_Line_Down 0xfe24 #define GDK_ISO_Partial_Space_Left 0xfe25 #define GDK_ISO_Partial_Space_Right 0xfe26 #define GDK_ISO_Set_Margin_Left 0xfe27 #define GDK_ISO_Set_Margin_Right 0xfe28 #define GDK_ISO_Release_Margin_Left 0xfe29 #define GDK_ISO_Release_Margin_Right 0xfe2a #define GDK_ISO_Release_Both_Margins 0xfe2b #define GDK_ISO_Fast_Cursor_Left 0xfe2c #define GDK_ISO_Fast_Cursor_Right 0xfe2d #define GDK_ISO_Fast_Cursor_Up 0xfe2e #define GDK_ISO_Fast_Cursor_Down 0xfe2f #define GDK_ISO_Continuous_Underline 0xfe30 #define GDK_ISO_Discontinuous_Underline 0xfe31 #define GDK_ISO_Emphasize 0xfe32 #define GDK_ISO_Center_Object 0xfe33 #define GDK_ISO_Enter 0xfe34 #define GDK_dead_grave 0xfe50 #define GDK_dead_acute 0xfe51 #define GDK_dead_circumflex 0xfe52 #define GDK_dead_tilde 0xfe53 #define GDK_dead_perispomeni 0xfe53 #define GDK_dead_macron 0xfe54 #define GDK_dead_breve 0xfe55 #define GDK_dead_abovedot 0xfe56 #define GDK_dead_diaeresis 0xfe57 #define GDK_dead_abovering 0xfe58 #define GDK_dead_doubleacute 0xfe59 #define GDK_dead_caron 0xfe5a #define GDK_dead_cedilla 0xfe5b #define GDK_dead_ogonek 0xfe5c #define GDK_dead_iota 0xfe5d #define GDK_dead_voiced_sound 0xfe5e #define GDK_dead_semivoiced_sound 0xfe5f #define GDK_dead_belowdot 0xfe60 #define GDK_dead_hook 0xfe61 #define GDK_dead_horn 0xfe62 #define GDK_dead_stroke 0xfe63 #define GDK_dead_abovecomma 0xfe64 #define GDK_dead_psili 0xfe64 #define GDK_dead_abovereversedcomma 0xfe65 #define GDK_dead_dasia 0xfe65 #define GDK_First_Virtual_Screen 0xfed0 #define GDK_Prev_Virtual_Screen 0xfed1 #define GDK_Next_Virtual_Screen 0xfed2 #define GDK_Last_Virtual_Screen 0xfed4 #define GDK_Terminate_Server 0xfed5 #define GDK_AccessX_Enable 0xfe70 #define GDK_AccessX_Feedback_Enable 0xfe71 #define GDK_RepeatKeys_Enable 0xfe72 #define GDK_SlowKeys_Enable 0xfe73 #define GDK_BounceKeys_Enable 0xfe74 #define GDK_StickyKeys_Enable 0xfe75 #define GDK_MouseKeys_Enable 0xfe76 #define GDK_MouseKeys_Accel_Enable 0xfe77 #define GDK_Overlay1_Enable 0xfe78 #define GDK_Overlay2_Enable 0xfe79 #define GDK_AudibleBell_Enable 0xfe7a #define GDK_Pointer_Left 0xfee0 #define GDK_Pointer_Right 0xfee1 #define GDK_Pointer_Up 0xfee2 #define GDK_Pointer_Down 0xfee3 #define GDK_Pointer_UpLeft 0xfee4 #define GDK_Pointer_UpRight 0xfee5 #define GDK_Pointer_DownLeft 0xfee6 #define GDK_Pointer_DownRight 0xfee7 #define GDK_Pointer_Button_Dflt 0xfee8 #define GDK_Pointer_Button1 0xfee9 #define GDK_Pointer_Button2 0xfeea #define GDK_Pointer_Button3 0xfeeb #define GDK_Pointer_Button4 0xfeec #define GDK_Pointer_Button5 0xfeed #define GDK_Pointer_DblClick_Dflt 0xfeee #define GDK_Pointer_DblClick1 0xfeef #define GDK_Pointer_DblClick2 0xfef0 #define GDK_Pointer_DblClick3 0xfef1 #define GDK_Pointer_DblClick4 0xfef2 #define GDK_Pointer_DblClick5 0xfef3 #define GDK_Pointer_Drag_Dflt 0xfef4 #define GDK_Pointer_Drag1 0xfef5 #define GDK_Pointer_Drag2 0xfef6 #define GDK_Pointer_Drag3 0xfef7 #define GDK_Pointer_Drag4 0xfef8 #define GDK_Pointer_Drag5 0xfefd #define GDK_Pointer_EnableKeys 0xfef9 #define GDK_Pointer_Accelerate 0xfefa #define GDK_Pointer_DfltBtnNext 0xfefb #define GDK_Pointer_DfltBtnPrev 0xfefc #define GDK_3270_Duplicate 0xfd01 #define GDK_3270_FieldMark 0xfd02 #define GDK_3270_Right2 0xfd03 #define GDK_3270_Left2 0xfd04 #define GDK_3270_BackTab 0xfd05 #define GDK_3270_EraseEOF 0xfd06 #define GDK_3270_EraseInput 0xfd07 #define GDK_3270_Reset 0xfd08 #define GDK_3270_Quit 0xfd09 #define GDK_3270_PA1 0xfd0a #define GDK_3270_PA2 0xfd0b #define GDK_3270_PA3 0xfd0c #define GDK_3270_Test 0xfd0d #define GDK_3270_Attn 0xfd0e #define GDK_3270_CursorBlink 0xfd0f #define GDK_3270_AltCursor 0xfd10 #define GDK_3270_KeyClick 0xfd11 #define GDK_3270_Jump 0xfd12 #define GDK_3270_Ident 0xfd13 #define GDK_3270_Rule 0xfd14 #define GDK_3270_Copy 0xfd15 #define GDK_3270_Play 0xfd16 #define GDK_3270_Setup 0xfd17 #define GDK_3270_Record 0xfd18 #define GDK_3270_ChangeScreen 0xfd19 #define GDK_3270_DeleteWord 0xfd1a #define GDK_3270_ExSelect 0xfd1b #define GDK_3270_CursorSelect 0xfd1c #define GDK_3270_PrintScreen 0xfd1d #define GDK_3270_Enter 0xfd1e #define GDK_space 0x020 #define GDK_exclam 0x021 #define GDK_quotedbl 0x022 #define GDK_numbersign 0x023 #define GDK_dollar 0x024 #define GDK_percent 0x025 #define GDK_ampersand 0x026 #define GDK_apostrophe 0x027 #define GDK_quoteright 0x027 #define GDK_parenleft 0x028 #define GDK_parenright 0x029 #define GDK_asterisk 0x02a #define GDK_plus 0x02b #define GDK_comma 0x02c #define GDK_minus 0x02d #define GDK_period 0x02e #define GDK_slash 0x02f #define GDK_0 0x030 #define GDK_1 0x031 #define GDK_2 0x032 #define GDK_3 0x033 #define GDK_4 0x034 #define GDK_5 0x035 #define GDK_6 0x036 #define GDK_7 0x037 #define GDK_8 0x038 #define GDK_9 0x039 #define GDK_colon 0x03a #define GDK_semicolon 0x03b #define GDK_less 0x03c #define GDK_equal 0x03d #define GDK_greater 0x03e #define GDK_question 0x03f #define GDK_at 0x040 #define GDK_A 0x041 #define GDK_B 0x042 #define GDK_C 0x043 #define GDK_D 0x044 #define GDK_E 0x045 #define GDK_F 0x046 #define GDK_G 0x047 #define GDK_H 0x048 #define GDK_I 0x049 #define GDK_J 0x04a #define GDK_K 0x04b #define GDK_L 0x04c #define GDK_M 0x04d #define GDK_N 0x04e #define GDK_O 0x04f #define GDK_P 0x050 #define GDK_Q 0x051 #define GDK_R 0x052 #define GDK_S 0x053 #define GDK_T 0x054 #define GDK_U 0x055 #define GDK_V 0x056 #define GDK_W 0x057 #define GDK_X 0x058 #define GDK_Y 0x059 #define GDK_Z 0x05a #define GDK_bracketleft 0x05b #define GDK_backslash 0x05c #define GDK_bracketright 0x05d #define GDK_asciicircum 0x05e #define GDK_underscore 0x05f #define GDK_grave 0x060 #define GDK_quoteleft 0x060 #define GDK_a 0x061 #define GDK_b 0x062 #define GDK_c 0x063 #define GDK_d 0x064 #define GDK_e 0x065 #define GDK_f 0x066 #define GDK_g 0x067 #define GDK_h 0x068 #define GDK_i 0x069 #define GDK_j 0x06a #define GDK_k 0x06b #define GDK_l 0x06c #define GDK_m 0x06d #define GDK_n 0x06e #define GDK_o 0x06f #define GDK_p 0x070 #define GDK_q 0x071 #define GDK_r 0x072 #define GDK_s 0x073 #define GDK_t 0x074 #define GDK_u 0x075 #define GDK_v 0x076 #define GDK_w 0x077 #define GDK_x 0x078 #define GDK_y 0x079 #define GDK_z 0x07a #define GDK_braceleft 0x07b #define GDK_bar 0x07c #define GDK_braceright 0x07d #define GDK_asciitilde 0x07e #define GDK_nobreakspace 0x0a0 #define GDK_exclamdown 0x0a1 #define GDK_cent 0x0a2 #define GDK_sterling 0x0a3 #define GDK_currency 0x0a4 #define GDK_yen 0x0a5 #define GDK_brokenbar 0x0a6 #define GDK_section 0x0a7 #define GDK_diaeresis 0x0a8 #define GDK_copyright 0x0a9 #define GDK_ordfeminine 0x0aa #define GDK_guillemotleft 0x0ab #define GDK_notsign 0x0ac #define GDK_hyphen 0x0ad #define GDK_registered 0x0ae #define GDK_macron 0x0af #define GDK_degree 0x0b0 #define GDK_plusminus 0x0b1 #define GDK_twosuperior 0x0b2 #define GDK_threesuperior 0x0b3 #define GDK_acute 0x0b4 #define GDK_mu 0x0b5 #define GDK_paragraph 0x0b6 #define GDK_periodcentered 0x0b7 #define GDK_cedilla 0x0b8 #define GDK_onesuperior 0x0b9 #define GDK_masculine 0x0ba #define GDK_guillemotright 0x0bb #define GDK_onequarter 0x0bc #define GDK_onehalf 0x0bd #define GDK_threequarters 0x0be #define GDK_questiondown 0x0bf #define GDK_Agrave 0x0c0 #define GDK_Aacute 0x0c1 #define GDK_Acircumflex 0x0c2 #define GDK_Atilde 0x0c3 #define GDK_Adiaeresis 0x0c4 #define GDK_Aring 0x0c5 #define GDK_AE 0x0c6 #define GDK_Ccedilla 0x0c7 #define GDK_Egrave 0x0c8 #define GDK_Eacute 0x0c9 #define GDK_Ecircumflex 0x0ca #define GDK_Ediaeresis 0x0cb #define GDK_Igrave 0x0cc #define GDK_Iacute 0x0cd #define GDK_Icircumflex 0x0ce #define GDK_Idiaeresis 0x0cf #define GDK_ETH 0x0d0 #define GDK_Eth 0x0d0 #define GDK_Ntilde 0x0d1 #define GDK_Ograve 0x0d2 #define GDK_Oacute 0x0d3 #define GDK_Ocircumflex 0x0d4 #define GDK_Otilde 0x0d5 #define GDK_Odiaeresis 0x0d6 #define GDK_multiply 0x0d7 #define GDK_Oslash 0x0d8 #define GDK_Ooblique 0x0d8 #define GDK_Ugrave 0x0d9 #define GDK_Uacute 0x0da #define GDK_Ucircumflex 0x0db #define GDK_Udiaeresis 0x0dc #define GDK_Yacute 0x0dd #define GDK_THORN 0x0de #define GDK_Thorn 0x0de #define GDK_ssharp 0x0df #define GDK_agrave 0x0e0 #define GDK_aacute 0x0e1 #define GDK_acircumflex 0x0e2 #define GDK_atilde 0x0e3 #define GDK_adiaeresis 0x0e4 #define GDK_aring 0x0e5 #define GDK_ae 0x0e6 #define GDK_ccedilla 0x0e7 #define GDK_egrave 0x0e8 #define GDK_eacute 0x0e9 #define GDK_ecircumflex 0x0ea #define GDK_ediaeresis 0x0eb #define GDK_igrave 0x0ec #define GDK_iacute 0x0ed #define GDK_icircumflex 0x0ee #define GDK_idiaeresis 0x0ef #define GDK_eth 0x0f0 #define GDK_ntilde 0x0f1 #define GDK_ograve 0x0f2 #define GDK_oacute 0x0f3 #define GDK_ocircumflex 0x0f4 #define GDK_otilde 0x0f5 #define GDK_odiaeresis 0x0f6 #define GDK_division 0x0f7 #define GDK_oslash 0x0f8 #define GDK_ooblique 0x0f8 #define GDK_ugrave 0x0f9 #define GDK_uacute 0x0fa #define GDK_ucircumflex 0x0fb #define GDK_udiaeresis 0x0fc #define GDK_yacute 0x0fd #define GDK_thorn 0x0fe #define GDK_ydiaeresis 0x0ff #define GDK_Aogonek 0x1a1 #define GDK_breve 0x1a2 #define GDK_Lstroke 0x1a3 #define GDK_Lcaron 0x1a5 #define GDK_Sacute 0x1a6 #define GDK_Scaron 0x1a9 #define GDK_Scedilla 0x1aa #define GDK_Tcaron 0x1ab #define GDK_Zacute 0x1ac #define GDK_Zcaron 0x1ae #define GDK_Zabovedot 0x1af #define GDK_aogonek 0x1b1 #define GDK_ogonek 0x1b2 #define GDK_lstroke 0x1b3 #define GDK_lcaron 0x1b5 #define GDK_sacute 0x1b6 #define GDK_caron 0x1b7 #define GDK_scaron 0x1b9 #define GDK_scedilla 0x1ba #define GDK_tcaron 0x1bb #define GDK_zacute 0x1bc #define GDK_doubleacute 0x1bd #define GDK_zcaron 0x1be #define GDK_zabovedot 0x1bf #define GDK_Racute 0x1c0 #define GDK_Abreve 0x1c3 #define GDK_Lacute 0x1c5 #define GDK_Cacute 0x1c6 #define GDK_Ccaron 0x1c8 #define GDK_Eogonek 0x1ca #define GDK_Ecaron 0x1cc #define GDK_Dcaron 0x1cf #define GDK_Dstroke 0x1d0 #define GDK_Nacute 0x1d1 #define GDK_Ncaron 0x1d2 #define GDK_Odoubleacute 0x1d5 #define GDK_Rcaron 0x1d8 #define GDK_Uring 0x1d9 #define GDK_Udoubleacute 0x1db #define GDK_Tcedilla 0x1de #define GDK_racute 0x1e0 #define GDK_abreve 0x1e3 #define GDK_lacute 0x1e5 #define GDK_cacute 0x1e6 #define GDK_ccaron 0x1e8 #define GDK_eogonek 0x1ea #define GDK_ecaron 0x1ec #define GDK_dcaron 0x1ef #define GDK_dstroke 0x1f0 #define GDK_nacute 0x1f1 #define GDK_ncaron 0x1f2 #define GDK_odoubleacute 0x1f5 #define GDK_udoubleacute 0x1fb #define GDK_rcaron 0x1f8 #define GDK_uring 0x1f9 #define GDK_tcedilla 0x1fe #define GDK_abovedot 0x1ff #define GDK_Hstroke 0x2a1 #define GDK_Hcircumflex 0x2a6 #define GDK_Iabovedot 0x2a9 #define GDK_Gbreve 0x2ab #define GDK_Jcircumflex 0x2ac #define GDK_hstroke 0x2b1 #define GDK_hcircumflex 0x2b6 #define GDK_idotless 0x2b9 #define GDK_gbreve 0x2bb #define GDK_jcircumflex 0x2bc #define GDK_Cabovedot 0x2c5 #define GDK_Ccircumflex 0x2c6 #define GDK_Gabovedot 0x2d5 #define GDK_Gcircumflex 0x2d8 #define GDK_Ubreve 0x2dd #define GDK_Scircumflex 0x2de #define GDK_cabovedot 0x2e5 #define GDK_ccircumflex 0x2e6 #define GDK_gabovedot 0x2f5 #define GDK_gcircumflex 0x2f8 #define GDK_ubreve 0x2fd #define GDK_scircumflex 0x2fe #define GDK_kra 0x3a2 #define GDK_kappa 0x3a2 #define GDK_Rcedilla 0x3a3 #define GDK_Itilde 0x3a5 #define GDK_Lcedilla 0x3a6 #define GDK_Emacron 0x3aa #define GDK_Gcedilla 0x3ab #define GDK_Tslash 0x3ac #define GDK_rcedilla 0x3b3 #define GDK_itilde 0x3b5 #define GDK_lcedilla 0x3b6 #define GDK_emacron 0x3ba #define GDK_gcedilla 0x3bb #define GDK_tslash 0x3bc #define GDK_ENG 0x3bd #define GDK_eng 0x3bf #define GDK_Amacron 0x3c0 #define GDK_Iogonek 0x3c7 #define GDK_Eabovedot 0x3cc #define GDK_Imacron 0x3cf #define GDK_Ncedilla 0x3d1 #define GDK_Omacron 0x3d2 #define GDK_Kcedilla 0x3d3 #define GDK_Uogonek 0x3d9 #define GDK_Utilde 0x3dd #define GDK_Umacron 0x3de #define GDK_amacron 0x3e0 #define GDK_iogonek 0x3e7 #define GDK_eabovedot 0x3ec #define GDK_imacron 0x3ef #define GDK_ncedilla 0x3f1 #define GDK_omacron 0x3f2 #define GDK_kcedilla 0x3f3 #define GDK_uogonek 0x3f9 #define GDK_utilde 0x3fd #define GDK_umacron 0x3fe #define GDK_Babovedot 0x1e02 #define GDK_babovedot 0x1e03 #define GDK_Dabovedot 0x1e0a #define GDK_Wgrave 0x1e80 #define GDK_Wacute 0x1e82 #define GDK_dabovedot 0x1e0b #define GDK_Ygrave 0x1ef2 #define GDK_Fabovedot 0x1e1e #define GDK_fabovedot 0x1e1f #define GDK_Mabovedot 0x1e40 #define GDK_mabovedot 0x1e41 #define GDK_Pabovedot 0x1e56 #define GDK_wgrave 0x1e81 #define GDK_pabovedot 0x1e57 #define GDK_wacute 0x1e83 #define GDK_Sabovedot 0x1e60 #define GDK_ygrave 0x1ef3 #define GDK_Wdiaeresis 0x1e84 #define GDK_wdiaeresis 0x1e85 #define GDK_sabovedot 0x1e61 #define GDK_Wcircumflex 0x174 #define GDK_Tabovedot 0x1e6a #define GDK_Ycircumflex 0x176 #define GDK_wcircumflex 0x175 #define GDK_tabovedot 0x1e6b #define GDK_ycircumflex 0x177 #define GDK_OE 0x13bc #define GDK_oe 0x13bd #define GDK_Ydiaeresis 0x13be #define GDK_overline 0x47e #define GDK_kana_fullstop 0x4a1 #define GDK_kana_openingbracket 0x4a2 #define GDK_kana_closingbracket 0x4a3 #define GDK_kana_comma 0x4a4 #define GDK_kana_conjunctive 0x4a5 #define GDK_kana_middledot 0x4a5 #define GDK_kana_WO 0x4a6 #define GDK_kana_a 0x4a7 #define GDK_kana_i 0x4a8 #define GDK_kana_u 0x4a9 #define GDK_kana_e 0x4aa #define GDK_kana_o 0x4ab #define GDK_kana_ya 0x4ac #define GDK_kana_yu 0x4ad #define GDK_kana_yo 0x4ae #define GDK_kana_tsu 0x4af #define GDK_kana_tu 0x4af #define GDK_prolongedsound 0x4b0 #define GDK_kana_A 0x4b1 #define GDK_kana_I 0x4b2 #define GDK_kana_U 0x4b3 #define GDK_kana_E 0x4b4 #define GDK_kana_O 0x4b5 #define GDK_kana_KA 0x4b6 #define GDK_kana_KI 0x4b7 #define GDK_kana_KU 0x4b8 #define GDK_kana_KE 0x4b9 #define GDK_kana_KO 0x4ba #define GDK_kana_SA 0x4bb #define GDK_kana_SHI 0x4bc #define GDK_kana_SU 0x4bd #define GDK_kana_SE 0x4be #define GDK_kana_SO 0x4bf #define GDK_kana_TA 0x4c0 #define GDK_kana_CHI 0x4c1 #define GDK_kana_TI 0x4c1 #define GDK_kana_TSU 0x4c2 #define GDK_kana_TU 0x4c2 #define GDK_kana_TE 0x4c3 #define GDK_kana_TO 0x4c4 #define GDK_kana_NA 0x4c5 #define GDK_kana_NI 0x4c6 #define GDK_kana_NU 0x4c7 #define GDK_kana_NE 0x4c8 #define GDK_kana_NO 0x4c9 #define GDK_kana_HA 0x4ca #define GDK_kana_HI 0x4cb #define GDK_kana_FU 0x4cc #define GDK_kana_HU 0x4cc #define GDK_kana_HE 0x4cd #define GDK_kana_HO 0x4ce #define GDK_kana_MA 0x4cf #define GDK_kana_MI 0x4d0 #define GDK_kana_MU 0x4d1 #define GDK_kana_ME 0x4d2 #define GDK_kana_MO 0x4d3 #define GDK_kana_YA 0x4d4 #define GDK_kana_YU 0x4d5 #define GDK_kana_YO 0x4d6 #define GDK_kana_RA 0x4d7 #define GDK_kana_RI 0x4d8 #define GDK_kana_RU 0x4d9 #define GDK_kana_RE 0x4da #define GDK_kana_RO 0x4db #define GDK_kana_WA 0x4dc #define GDK_kana_N 0x4dd #define GDK_voicedsound 0x4de #define GDK_semivoicedsound 0x4df #define GDK_kana_switch 0xff7e #define GDK_Farsi_0 0x6f0 #define GDK_Farsi_1 0x6f1 #define GDK_Farsi_2 0x6f2 #define GDK_Farsi_3 0x6f3 #define GDK_Farsi_4 0x6f4 #define GDK_Farsi_5 0x6f5 #define GDK_Farsi_6 0x6f6 #define GDK_Farsi_7 0x6f7 #define GDK_Farsi_8 0x6f8 #define GDK_Farsi_9 0x6f9 #define GDK_Arabic_percent 0x66a #define GDK_Arabic_superscript_alef 0x670 #define GDK_Arabic_tteh 0x679 #define GDK_Arabic_peh 0x67e #define GDK_Arabic_tcheh 0x686 #define GDK_Arabic_ddal 0x688 #define GDK_Arabic_rreh 0x691 #define GDK_Arabic_comma 0x5ac #define GDK_Arabic_fullstop 0x6d4 #define GDK_Arabic_0 0x660 #define GDK_Arabic_1 0x661 #define GDK_Arabic_2 0x662 #define GDK_Arabic_3 0x663 #define GDK_Arabic_4 0x664 #define GDK_Arabic_5 0x665 #define GDK_Arabic_6 0x666 #define GDK_Arabic_7 0x667 #define GDK_Arabic_8 0x668 #define GDK_Arabic_9 0x669 #define GDK_Arabic_semicolon 0x5bb #define GDK_Arabic_question_mark 0x5bf #define GDK_Arabic_hamza 0x5c1 #define GDK_Arabic_maddaonalef 0x5c2 #define GDK_Arabic_hamzaonalef 0x5c3 #define GDK_Arabic_hamzaonwaw 0x5c4 #define GDK_Arabic_hamzaunderalef 0x5c5 #define GDK_Arabic_hamzaonyeh 0x5c6 #define GDK_Arabic_alef 0x5c7 #define GDK_Arabic_beh 0x5c8 #define GDK_Arabic_tehmarbuta 0x5c9 #define GDK_Arabic_teh 0x5ca #define GDK_Arabic_theh 0x5cb #define GDK_Arabic_jeem 0x5cc #define GDK_Arabic_hah 0x5cd #define GDK_Arabic_khah 0x5ce #define GDK_Arabic_dal 0x5cf #define GDK_Arabic_thal 0x5d0 #define GDK_Arabic_ra 0x5d1 #define GDK_Arabic_zain 0x5d2 #define GDK_Arabic_seen 0x5d3 #define GDK_Arabic_sheen 0x5d4 #define GDK_Arabic_sad 0x5d5 #define GDK_Arabic_dad 0x5d6 #define GDK_Arabic_tah 0x5d7 #define GDK_Arabic_zah 0x5d8 #define GDK_Arabic_ain 0x5d9 #define GDK_Arabic_ghain 0x5da #define GDK_Arabic_tatweel 0x5e0 #define GDK_Arabic_feh 0x5e1 #define GDK_Arabic_qaf 0x5e2 #define GDK_Arabic_kaf 0x5e3 #define GDK_Arabic_lam 0x5e4 #define GDK_Arabic_meem 0x5e5 #define GDK_Arabic_noon 0x5e6 #define GDK_Arabic_ha 0x5e7 #define GDK_Arabic_heh 0x5e7 #define GDK_Arabic_waw 0x5e8 #define GDK_Arabic_alefmaksura 0x5e9 #define GDK_Arabic_yeh 0x5ea #define GDK_Arabic_fathatan 0x5eb #define GDK_Arabic_dammatan 0x5ec #define GDK_Arabic_kasratan 0x5ed #define GDK_Arabic_fatha 0x5ee #define GDK_Arabic_damma 0x5ef #define GDK_Arabic_kasra 0x5f0 #define GDK_Arabic_shadda 0x5f1 #define GDK_Arabic_sukun 0x5f2 #define GDK_Arabic_madda_above 0x653 #define GDK_Arabic_hamza_above 0x654 #define GDK_Arabic_hamza_below 0x655 #define GDK_Arabic_jeh 0x698 #define GDK_Arabic_veh 0x6a4 #define GDK_Arabic_keheh 0x6a9 #define GDK_Arabic_gaf 0x6af #define GDK_Arabic_noon_ghunna 0x6ba #define GDK_Arabic_heh_doachashmee 0x6be #define GDK_Farsi_yeh 0x6cc #define GDK_Arabic_farsi_yeh 0x6cc #define GDK_Arabic_yeh_baree 0x6d2 #define GDK_Arabic_heh_goal 0x6c1 #define GDK_Arabic_switch 0xff7e #define GDK_Cyrillic_GHE_bar 0x492 #define GDK_Cyrillic_ghe_bar 0x493 #define GDK_Cyrillic_ZHE_descender 0x496 #define GDK_Cyrillic_zhe_descender 0x497 #define GDK_Cyrillic_KA_descender 0x49a #define GDK_Cyrillic_ka_descender 0x49b #define GDK_Cyrillic_KA_vertstroke 0x49c #define GDK_Cyrillic_ka_vertstroke 0x49d #define GDK_Cyrillic_EN_descender 0x4a2 #define GDK_Cyrillic_en_descender 0x4a3 #define GDK_Cyrillic_U_straight 0x4ae #define GDK_Cyrillic_u_straight 0x4af #define GDK_Cyrillic_U_straight_bar 0x4b0 #define GDK_Cyrillic_u_straight_bar 0x4b1 #define GDK_Cyrillic_HA_descender 0x4b2 #define GDK_Cyrillic_ha_descender 0x4b3 #define GDK_Cyrillic_CHE_descender 0x4b6 #define GDK_Cyrillic_che_descender 0x4b7 #define GDK_Cyrillic_CHE_vertstroke 0x4b8 #define GDK_Cyrillic_che_vertstroke 0x4b9 #define GDK_Cyrillic_SHHA 0x4ba #define GDK_Cyrillic_shha 0x4bb #define GDK_Cyrillic_SCHWA 0x4d8 #define GDK_Cyrillic_schwa 0x4d9 #define GDK_Cyrillic_I_macron 0x4e2 #define GDK_Cyrillic_i_macron 0x4e3 #define GDK_Cyrillic_O_bar 0x4e8 #define GDK_Cyrillic_o_bar 0x4e9 #define GDK_Cyrillic_U_macron 0x4ee #define GDK_Cyrillic_u_macron 0x4ef #define GDK_Serbian_dje 0x6a1 #define GDK_Macedonia_gje 0x6a2 #define GDK_Cyrillic_io 0x6a3 #define GDK_Ukrainian_ie 0x6a4 #define GDK_Ukranian_je 0x6a4 #define GDK_Macedonia_dse 0x6a5 #define GDK_Ukrainian_i 0x6a6 #define GDK_Ukranian_i 0x6a6 #define GDK_Ukrainian_yi 0x6a7 #define GDK_Ukranian_yi 0x6a7 #define GDK_Cyrillic_je 0x6a8 #define GDK_Serbian_je 0x6a8 #define GDK_Cyrillic_lje 0x6a9 #define GDK_Serbian_lje 0x6a9 #define GDK_Cyrillic_nje 0x6aa #define GDK_Serbian_nje 0x6aa #define GDK_Serbian_tshe 0x6ab #define GDK_Macedonia_kje 0x6ac #define GDK_Ukrainian_ghe_with_upturn 0x6ad #define GDK_Byelorussian_shortu 0x6ae #define GDK_Cyrillic_dzhe 0x6af #define GDK_Serbian_dze 0x6af #define GDK_numerosign 0x6b0 #define GDK_Serbian_DJE 0x6b1 #define GDK_Macedonia_GJE 0x6b2 #define GDK_Cyrillic_IO 0x6b3 #define GDK_Ukrainian_IE 0x6b4 #define GDK_Ukranian_JE 0x6b4 #define GDK_Macedonia_DSE 0x6b5 #define GDK_Ukrainian_I 0x6b6 #define GDK_Ukranian_I 0x6b6 #define GDK_Ukrainian_YI 0x6b7 #define GDK_Ukranian_YI 0x6b7 #define GDK_Cyrillic_JE 0x6b8 #define GDK_Serbian_JE 0x6b8 #define GDK_Cyrillic_LJE 0x6b9 #define GDK_Serbian_LJE 0x6b9 #define GDK_Cyrillic_NJE 0x6ba #define GDK_Serbian_NJE 0x6ba #define GDK_Serbian_TSHE 0x6bb #define GDK_Macedonia_KJE 0x6bc #define GDK_Ukrainian_GHE_WITH_UPTURN 0x6bd #define GDK_Byelorussian_SHORTU 0x6be #define GDK_Cyrillic_DZHE 0x6bf #define GDK_Serbian_DZE 0x6bf #define GDK_Cyrillic_yu 0x6c0 #define GDK_Cyrillic_a 0x6c1 #define GDK_Cyrillic_be 0x6c2 #define GDK_Cyrillic_tse 0x6c3 #define GDK_Cyrillic_de 0x6c4 #define GDK_Cyrillic_ie 0x6c5 #define GDK_Cyrillic_ef 0x6c6 #define GDK_Cyrillic_ghe 0x6c7 #define GDK_Cyrillic_ha 0x6c8 #define GDK_Cyrillic_i 0x6c9 #define GDK_Cyrillic_shorti 0x6ca #define GDK_Cyrillic_ka 0x6cb #define GDK_Cyrillic_el 0x6cc #define GDK_Cyrillic_em 0x6cd #define GDK_Cyrillic_en 0x6ce #define GDK_Cyrillic_o 0x6cf #define GDK_Cyrillic_pe 0x6d0 #define GDK_Cyrillic_ya 0x6d1 #define GDK_Cyrillic_er 0x6d2 #define GDK_Cyrillic_es 0x6d3 #define GDK_Cyrillic_te 0x6d4 #define GDK_Cyrillic_u 0x6d5 #define GDK_Cyrillic_zhe 0x6d6 #define GDK_Cyrillic_ve 0x6d7 #define GDK_Cyrillic_softsign 0x6d8 #define GDK_Cyrillic_yeru 0x6d9 #define GDK_Cyrillic_ze 0x6da #define GDK_Cyrillic_sha 0x6db #define GDK_Cyrillic_e 0x6dc #define GDK_Cyrillic_shcha 0x6dd #define GDK_Cyrillic_che 0x6de #define GDK_Cyrillic_hardsign 0x6df #define GDK_Cyrillic_YU 0x6e0 #define GDK_Cyrillic_A 0x6e1 #define GDK_Cyrillic_BE 0x6e2 #define GDK_Cyrillic_TSE 0x6e3 #define GDK_Cyrillic_DE 0x6e4 #define GDK_Cyrillic_IE 0x6e5 #define GDK_Cyrillic_EF 0x6e6 #define GDK_Cyrillic_GHE 0x6e7 #define GDK_Cyrillic_HA 0x6e8 #define GDK_Cyrillic_I 0x6e9 #define GDK_Cyrillic_SHORTI 0x6ea #define GDK_Cyrillic_KA 0x6eb #define GDK_Cyrillic_EL 0x6ec #define GDK_Cyrillic_EM 0x6ed #define GDK_Cyrillic_EN 0x6ee #define GDK_Cyrillic_O 0x6ef #define GDK_Cyrillic_PE 0x6f0 #define GDK_Cyrillic_YA 0x6f1 #define GDK_Cyrillic_ER 0x6f2 #define GDK_Cyrillic_ES 0x6f3 #define GDK_Cyrillic_TE 0x6f4 #define GDK_Cyrillic_U 0x6f5 #define GDK_Cyrillic_ZHE 0x6f6 #define GDK_Cyrillic_VE 0x6f7 #define GDK_Cyrillic_SOFTSIGN 0x6f8 #define GDK_Cyrillic_YERU 0x6f9 #define GDK_Cyrillic_ZE 0x6fa #define GDK_Cyrillic_SHA 0x6fb #define GDK_Cyrillic_E 0x6fc #define GDK_Cyrillic_SHCHA 0x6fd #define GDK_Cyrillic_CHE 0x6fe #define GDK_Cyrillic_HARDSIGN 0x6ff #define GDK_Greek_ALPHAaccent 0x7a1 #define GDK_Greek_EPSILONaccent 0x7a2 #define GDK_Greek_ETAaccent 0x7a3 #define GDK_Greek_IOTAaccent 0x7a4 #define GDK_Greek_IOTAdieresis 0x7a5 #define GDK_Greek_IOTAdiaeresis 0x7a5 #define GDK_Greek_OMICRONaccent 0x7a7 #define GDK_Greek_UPSILONaccent 0x7a8 #define GDK_Greek_UPSILONdieresis 0x7a9 #define GDK_Greek_OMEGAaccent 0x7ab #define GDK_Greek_accentdieresis 0x7ae #define GDK_Greek_horizbar 0x7af #define GDK_Greek_alphaaccent 0x7b1 #define GDK_Greek_epsilonaccent 0x7b2 #define GDK_Greek_etaaccent 0x7b3 #define GDK_Greek_iotaaccent 0x7b4 #define GDK_Greek_iotadieresis 0x7b5 #define GDK_Greek_iotaaccentdieresis 0x7b6 #define GDK_Greek_omicronaccent 0x7b7 #define GDK_Greek_upsilonaccent 0x7b8 #define GDK_Greek_upsilondieresis 0x7b9 #define GDK_Greek_upsilonaccentdieresis 0x7ba #define GDK_Greek_omegaaccent 0x7bb #define GDK_Greek_ALPHA 0x7c1 #define GDK_Greek_BETA 0x7c2 #define GDK_Greek_GAMMA 0x7c3 #define GDK_Greek_DELTA 0x7c4 #define GDK_Greek_EPSILON 0x7c5 #define GDK_Greek_ZETA 0x7c6 #define GDK_Greek_ETA 0x7c7 #define GDK_Greek_THETA 0x7c8 #define GDK_Greek_IOTA 0x7c9 #define GDK_Greek_KAPPA 0x7ca #define GDK_Greek_LAMDA 0x7cb #define GDK_Greek_LAMBDA 0x7cb #define GDK_Greek_MU 0x7cc #define GDK_Greek_NU 0x7cd #define GDK_Greek_XI 0x7ce #define GDK_Greek_OMICRON 0x7cf #define GDK_Greek_PI 0x7d0 #define GDK_Greek_RHO 0x7d1 #define GDK_Greek_SIGMA 0x7d2 #define GDK_Greek_TAU 0x7d4 #define GDK_Greek_UPSILON 0x7d5 #define GDK_Greek_PHI 0x7d6 #define GDK_Greek_CHI 0x7d7 #define GDK_Greek_PSI 0x7d8 #define GDK_Greek_OMEGA 0x7d9 #define GDK_Greek_alpha 0x7e1 #define GDK_Greek_beta 0x7e2 #define GDK_Greek_gamma 0x7e3 #define GDK_Greek_delta 0x7e4 #define GDK_Greek_epsilon 0x7e5 #define GDK_Greek_zeta 0x7e6 #define GDK_Greek_eta 0x7e7 #define GDK_Greek_theta 0x7e8 #define GDK_Greek_iota 0x7e9 #define GDK_Greek_kappa 0x7ea #define GDK_Greek_lamda 0x7eb #define GDK_Greek_lambda 0x7eb #define GDK_Greek_mu 0x7ec #define GDK_Greek_nu 0x7ed #define GDK_Greek_xi 0x7ee #define GDK_Greek_omicron 0x7ef #define GDK_Greek_pi 0x7f0 #define GDK_Greek_rho 0x7f1 #define GDK_Greek_sigma 0x7f2 #define GDK_Greek_finalsmallsigma 0x7f3 #define GDK_Greek_tau 0x7f4 #define GDK_Greek_upsilon 0x7f5 #define GDK_Greek_phi 0x7f6 #define GDK_Greek_chi 0x7f7 #define GDK_Greek_psi 0x7f8 #define GDK_Greek_omega 0x7f9 #define GDK_Greek_switch 0xff7e #define GDK_leftradical 0x8a1 #define GDK_topleftradical 0x8a2 #define GDK_horizconnector 0x8a3 #define GDK_topintegral 0x8a4 #define GDK_botintegral 0x8a5 #define GDK_vertconnector 0x8a6 #define GDK_topleftsqbracket 0x8a7 #define GDK_botleftsqbracket 0x8a8 #define GDK_toprightsqbracket 0x8a9 #define GDK_botrightsqbracket 0x8aa #define GDK_topleftparens 0x8ab #define GDK_botleftparens 0x8ac #define GDK_toprightparens 0x8ad #define GDK_botrightparens 0x8ae #define GDK_leftmiddlecurlybrace 0x8af #define GDK_rightmiddlecurlybrace 0x8b0 #define GDK_topleftsummation 0x8b1 #define GDK_botleftsummation 0x8b2 #define GDK_topvertsummationconnector 0x8b3 #define GDK_botvertsummationconnector 0x8b4 #define GDK_toprightsummation 0x8b5 #define GDK_botrightsummation 0x8b6 #define GDK_rightmiddlesummation 0x8b7 #define GDK_lessthanequal 0x8bc #define GDK_notequal 0x8bd #define GDK_greaterthanequal 0x8be #define GDK_integral 0x8bf #define GDK_therefore 0x8c0 #define GDK_variation 0x8c1 #define GDK_infinity 0x8c2 #define GDK_nabla 0x8c5 #define GDK_approximate 0x8c8 #define GDK_similarequal 0x8c9 #define GDK_ifonlyif 0x8cd #define GDK_implies 0x8ce #define GDK_identical 0x8cf #define GDK_radical 0x8d6 #define GDK_includedin 0x8da #define GDK_includes 0x8db #define GDK_intersection 0x8dc #define GDK_union 0x8dd #define GDK_logicaland 0x8de #define GDK_logicalor 0x8df #define GDK_partialderivative 0x8ef #define GDK_function 0x8f6 #define GDK_leftarrow 0x8fb #define GDK_uparrow 0x8fc #define GDK_rightarrow 0x8fd #define GDK_downarrow 0x8fe #define GDK_blank 0x9df #define GDK_soliddiamond 0x9e0 #define GDK_checkerboard 0x9e1 #define GDK_ht 0x9e2 #define GDK_ff 0x9e3 #define GDK_cr 0x9e4 #define GDK_lf 0x9e5 #define GDK_nl 0x9e8 #define GDK_vt 0x9e9 #define GDK_lowrightcorner 0x9ea #define GDK_uprightcorner 0x9eb #define GDK_upleftcorner 0x9ec #define GDK_lowleftcorner 0x9ed #define GDK_crossinglines 0x9ee #define GDK_horizlinescan1 0x9ef #define GDK_horizlinescan3 0x9f0 #define GDK_horizlinescan5 0x9f1 #define GDK_horizlinescan7 0x9f2 #define GDK_horizlinescan9 0x9f3 #define GDK_leftt 0x9f4 #define GDK_rightt 0x9f5 #define GDK_bott 0x9f6 #define GDK_topt 0x9f7 #define GDK_vertbar 0x9f8 #define GDK_emspace 0xaa1 #define GDK_enspace 0xaa2 #define GDK_em3space 0xaa3 #define GDK_em4space 0xaa4 #define GDK_digitspace 0xaa5 #define GDK_punctspace 0xaa6 #define GDK_thinspace 0xaa7 #define GDK_hairspace 0xaa8 #define GDK_emdash 0xaa9 #define GDK_endash 0xaaa #define GDK_signifblank 0xaac #define GDK_ellipsis 0xaae #define GDK_doubbaselinedot 0xaaf #define GDK_onethird 0xab0 #define GDK_twothirds 0xab1 #define GDK_onefifth 0xab2 #define GDK_twofifths 0xab3 #define GDK_threefifths 0xab4 #define GDK_fourfifths 0xab5 #define GDK_onesixth 0xab6 #define GDK_fivesixths 0xab7 #define GDK_careof 0xab8 #define GDK_figdash 0xabb #define GDK_leftanglebracket 0xabc #define GDK_decimalpoint 0xabd #define GDK_rightanglebracket 0xabe #define GDK_marker 0xabf #define GDK_oneeighth 0xac3 #define GDK_threeeighths 0xac4 #define GDK_fiveeighths 0xac5 #define GDK_seveneighths 0xac6 #define GDK_trademark 0xac9 #define GDK_signaturemark 0xaca #define GDK_trademarkincircle 0xacb #define GDK_leftopentriangle 0xacc #define GDK_rightopentriangle 0xacd #define GDK_emopencircle 0xace #define GDK_emopenrectangle 0xacf #define GDK_leftsinglequotemark 0xad0 #define GDK_rightsinglequotemark 0xad1 #define GDK_leftdoublequotemark 0xad2 #define GDK_rightdoublequotemark 0xad3 #define GDK_prescription 0xad4 #define GDK_minutes 0xad6 #define GDK_seconds 0xad7 #define GDK_latincross 0xad9 #define GDK_hexagram 0xada #define GDK_filledrectbullet 0xadb #define GDK_filledlefttribullet 0xadc #define GDK_filledrighttribullet 0xadd #define GDK_emfilledcircle 0xade #define GDK_emfilledrect 0xadf #define GDK_enopencircbullet 0xae0 #define GDK_enopensquarebullet 0xae1 #define GDK_openrectbullet 0xae2 #define GDK_opentribulletup 0xae3 #define GDK_opentribulletdown 0xae4 #define GDK_openstar 0xae5 #define GDK_enfilledcircbullet 0xae6 #define GDK_enfilledsqbullet 0xae7 #define GDK_filledtribulletup 0xae8 #define GDK_filledtribulletdown 0xae9 #define GDK_leftpointer 0xaea #define GDK_rightpointer 0xaeb #define GDK_club 0xaec #define GDK_diamond 0xaed #define GDK_heart 0xaee #define GDK_maltesecross 0xaf0 #define GDK_dagger 0xaf1 #define GDK_doubledagger 0xaf2 #define GDK_checkmark 0xaf3 #define GDK_ballotcross 0xaf4 #define GDK_musicalsharp 0xaf5 #define GDK_musicalflat 0xaf6 #define GDK_malesymbol 0xaf7 #define GDK_femalesymbol 0xaf8 #define GDK_telephone 0xaf9 #define GDK_telephonerecorder 0xafa #define GDK_phonographcopyright 0xafb #define GDK_caret 0xafc #define GDK_singlelowquotemark 0xafd #define GDK_doublelowquotemark 0xafe #define GDK_cursor 0xaff #define GDK_leftcaret 0xba3 #define GDK_rightcaret 0xba6 #define GDK_downcaret 0xba8 #define GDK_upcaret 0xba9 #define GDK_overbar 0xbc0 #define GDK_downtack 0xbc2 #define GDK_upshoe 0xbc3 #define GDK_downstile 0xbc4 #define GDK_underbar 0xbc6 #define GDK_jot 0xbca #define GDK_quad 0xbcc #define GDK_uptack 0xbce #define GDK_circle 0xbcf #define GDK_upstile 0xbd3 #define GDK_downshoe 0xbd6 #define GDK_rightshoe 0xbd8 #define GDK_leftshoe 0xbda #define GDK_lefttack 0xbdc #define GDK_righttack 0xbfc #define GDK_hebrew_doublelowline 0xcdf #define GDK_hebrew_aleph 0xce0 #define GDK_hebrew_bet 0xce1 #define GDK_hebrew_beth 0xce1 #define GDK_hebrew_gimel 0xce2 #define GDK_hebrew_gimmel 0xce2 #define GDK_hebrew_dalet 0xce3 #define GDK_hebrew_daleth 0xce3 #define GDK_hebrew_he 0xce4 #define GDK_hebrew_waw 0xce5 #define GDK_hebrew_zain 0xce6 #define GDK_hebrew_zayin 0xce6 #define GDK_hebrew_chet 0xce7 #define GDK_hebrew_het 0xce7 #define GDK_hebrew_tet 0xce8 #define GDK_hebrew_teth 0xce8 #define GDK_hebrew_yod 0xce9 #define GDK_hebrew_finalkaph 0xcea #define GDK_hebrew_kaph 0xceb #define GDK_hebrew_lamed 0xcec #define GDK_hebrew_finalmem 0xced #define GDK_hebrew_mem 0xcee #define GDK_hebrew_finalnun 0xcef #define GDK_hebrew_nun 0xcf0 #define GDK_hebrew_samech 0xcf1 #define GDK_hebrew_samekh 0xcf1 #define GDK_hebrew_ayin 0xcf2 #define GDK_hebrew_finalpe 0xcf3 #define GDK_hebrew_pe 0xcf4 #define GDK_hebrew_finalzade 0xcf5 #define GDK_hebrew_finalzadi 0xcf5 #define GDK_hebrew_zade 0xcf6 #define GDK_hebrew_zadi 0xcf6 #define GDK_hebrew_qoph 0xcf7 #define GDK_hebrew_kuf 0xcf7 #define GDK_hebrew_resh 0xcf8 #define GDK_hebrew_shin 0xcf9 #define GDK_hebrew_taw 0xcfa #define GDK_hebrew_taf 0xcfa #define GDK_Hebrew_switch 0xff7e #define GDK_Thai_kokai 0xda1 #define GDK_Thai_khokhai 0xda2 #define GDK_Thai_khokhuat 0xda3 #define GDK_Thai_khokhwai 0xda4 #define GDK_Thai_khokhon 0xda5 #define GDK_Thai_khorakhang 0xda6 #define GDK_Thai_ngongu 0xda7 #define GDK_Thai_chochan 0xda8 #define GDK_Thai_choching 0xda9 #define GDK_Thai_chochang 0xdaa #define GDK_Thai_soso 0xdab #define GDK_Thai_chochoe 0xdac #define GDK_Thai_yoying 0xdad #define GDK_Thai_dochada 0xdae #define GDK_Thai_topatak 0xdaf #define GDK_Thai_thothan 0xdb0 #define GDK_Thai_thonangmontho 0xdb1 #define GDK_Thai_thophuthao 0xdb2 #define GDK_Thai_nonen 0xdb3 #define GDK_Thai_dodek 0xdb4 #define GDK_Thai_totao 0xdb5 #define GDK_Thai_thothung 0xdb6 #define GDK_Thai_thothahan 0xdb7 #define GDK_Thai_thothong 0xdb8 #define GDK_Thai_nonu 0xdb9 #define GDK_Thai_bobaimai 0xdba #define GDK_Thai_popla 0xdbb #define GDK_Thai_phophung 0xdbc #define GDK_Thai_fofa 0xdbd #define GDK_Thai_phophan 0xdbe #define GDK_Thai_fofan 0xdbf #define GDK_Thai_phosamphao 0xdc0 #define GDK_Thai_moma 0xdc1 #define GDK_Thai_yoyak 0xdc2 #define GDK_Thai_rorua 0xdc3 #define GDK_Thai_ru 0xdc4 #define GDK_Thai_loling 0xdc5 #define GDK_Thai_lu 0xdc6 #define GDK_Thai_wowaen 0xdc7 #define GDK_Thai_sosala 0xdc8 #define GDK_Thai_sorusi 0xdc9 #define GDK_Thai_sosua 0xdca #define GDK_Thai_hohip 0xdcb #define GDK_Thai_lochula 0xdcc #define GDK_Thai_oang 0xdcd #define GDK_Thai_honokhuk 0xdce #define GDK_Thai_paiyannoi 0xdcf #define GDK_Thai_saraa 0xdd0 #define GDK_Thai_maihanakat 0xdd1 #define GDK_Thai_saraaa 0xdd2 #define GDK_Thai_saraam 0xdd3 #define GDK_Thai_sarai 0xdd4 #define GDK_Thai_saraii 0xdd5 #define GDK_Thai_saraue 0xdd6 #define GDK_Thai_sarauee 0xdd7 #define GDK_Thai_sarau 0xdd8 #define GDK_Thai_sarauu 0xdd9 #define GDK_Thai_phinthu 0xdda #define GDK_Thai_maihanakat_maitho 0xdde #define GDK_Thai_baht 0xddf #define GDK_Thai_sarae 0xde0 #define GDK_Thai_saraae 0xde1 #define GDK_Thai_sarao 0xde2 #define GDK_Thai_saraaimaimuan 0xde3 #define GDK_Thai_saraaimaimalai 0xde4 #define GDK_Thai_lakkhangyao 0xde5 #define GDK_Thai_maiyamok 0xde6 #define GDK_Thai_maitaikhu 0xde7 #define GDK_Thai_maiek 0xde8 #define GDK_Thai_maitho 0xde9 #define GDK_Thai_maitri 0xdea #define GDK_Thai_maichattawa 0xdeb #define GDK_Thai_thanthakhat 0xdec #define GDK_Thai_nikhahit 0xded #define GDK_Thai_leksun 0xdf0 #define GDK_Thai_leknung 0xdf1 #define GDK_Thai_leksong 0xdf2 #define GDK_Thai_leksam 0xdf3 #define GDK_Thai_leksi 0xdf4 #define GDK_Thai_lekha 0xdf5 #define GDK_Thai_lekhok 0xdf6 #define GDK_Thai_lekchet 0xdf7 #define GDK_Thai_lekpaet 0xdf8 #define GDK_Thai_lekkao 0xdf9 #define GDK_Hangul 0xff31 #define GDK_Hangul_Start 0xff32 #define GDK_Hangul_End 0xff33 #define GDK_Hangul_Hanja 0xff34 #define GDK_Hangul_Jamo 0xff35 #define GDK_Hangul_Romaja 0xff36 #define GDK_Hangul_Codeinput 0xff37 #define GDK_Hangul_Jeonja 0xff38 #define GDK_Hangul_Banja 0xff39 #define GDK_Hangul_PreHanja 0xff3a #define GDK_Hangul_PostHanja 0xff3b #define GDK_Hangul_SingleCandidate 0xff3c #define GDK_Hangul_MultipleCandidate 0xff3d #define GDK_Hangul_PreviousCandidate 0xff3e #define GDK_Hangul_Special 0xff3f #define GDK_Hangul_switch 0xff7e #define GDK_Hangul_Kiyeog 0xea1 #define GDK_Hangul_SsangKiyeog 0xea2 #define GDK_Hangul_KiyeogSios 0xea3 #define GDK_Hangul_Nieun 0xea4 #define GDK_Hangul_NieunJieuj 0xea5 #define GDK_Hangul_NieunHieuh 0xea6 #define GDK_Hangul_Dikeud 0xea7 #define GDK_Hangul_SsangDikeud 0xea8 #define GDK_Hangul_Rieul 0xea9 #define GDK_Hangul_RieulKiyeog 0xeaa #define GDK_Hangul_RieulMieum 0xeab #define GDK_Hangul_RieulPieub 0xeac #define GDK_Hangul_RieulSios 0xead #define GDK_Hangul_RieulTieut 0xeae #define GDK_Hangul_RieulPhieuf 0xeaf #define GDK_Hangul_RieulHieuh 0xeb0 #define GDK_Hangul_Mieum 0xeb1 #define GDK_Hangul_Pieub 0xeb2 #define GDK_Hangul_SsangPieub 0xeb3 #define GDK_Hangul_PieubSios 0xeb4 #define GDK_Hangul_Sios 0xeb5 #define GDK_Hangul_SsangSios 0xeb6 #define GDK_Hangul_Ieung 0xeb7 #define GDK_Hangul_Jieuj 0xeb8 #define GDK_Hangul_SsangJieuj 0xeb9 #define GDK_Hangul_Cieuc 0xeba #define GDK_Hangul_Khieuq 0xebb #define GDK_Hangul_Tieut 0xebc #define GDK_Hangul_Phieuf 0xebd #define GDK_Hangul_Hieuh 0xebe #define GDK_Hangul_A 0xebf #define GDK_Hangul_AE 0xec0 #define GDK_Hangul_YA 0xec1 #define GDK_Hangul_YAE 0xec2 #define GDK_Hangul_EO 0xec3 #define GDK_Hangul_E 0xec4 #define GDK_Hangul_YEO 0xec5 #define GDK_Hangul_YE 0xec6 #define GDK_Hangul_O 0xec7 #define GDK_Hangul_WA 0xec8 #define GDK_Hangul_WAE 0xec9 #define GDK_Hangul_OE 0xeca #define GDK_Hangul_YO 0xecb #define GDK_Hangul_U 0xecc #define GDK_Hangul_WEO 0xecd #define GDK_Hangul_WE 0xece #define GDK_Hangul_WI 0xecf #define GDK_Hangul_YU 0xed0 #define GDK_Hangul_EU 0xed1 #define GDK_Hangul_YI 0xed2 #define GDK_Hangul_I 0xed3 #define GDK_Hangul_J_Kiyeog 0xed4 #define GDK_Hangul_J_SsangKiyeog 0xed5 #define GDK_Hangul_J_KiyeogSios 0xed6 #define GDK_Hangul_J_Nieun 0xed7 #define GDK_Hangul_J_NieunJieuj 0xed8 #define GDK_Hangul_J_NieunHieuh 0xed9 #define GDK_Hangul_J_Dikeud 0xeda #define GDK_Hangul_J_Rieul 0xedb #define GDK_Hangul_J_RieulKiyeog 0xedc #define GDK_Hangul_J_RieulMieum 0xedd #define GDK_Hangul_J_RieulPieub 0xede #define GDK_Hangul_J_RieulSios 0xedf #define GDK_Hangul_J_RieulTieut 0xee0 #define GDK_Hangul_J_RieulPhieuf 0xee1 #define GDK_Hangul_J_RieulHieuh 0xee2 #define GDK_Hangul_J_Mieum 0xee3 #define GDK_Hangul_J_Pieub 0xee4 #define GDK_Hangul_J_PieubSios 0xee5 #define GDK_Hangul_J_Sios 0xee6 #define GDK_Hangul_J_SsangSios 0xee7 #define GDK_Hangul_J_Ieung 0xee8 #define GDK_Hangul_J_Jieuj 0xee9 #define GDK_Hangul_J_Cieuc 0xeea #define GDK_Hangul_J_Khieuq 0xeeb #define GDK_Hangul_J_Tieut 0xeec #define GDK_Hangul_J_Phieuf 0xeed #define GDK_Hangul_J_Hieuh 0xeee #define GDK_Hangul_RieulYeorinHieuh 0xeef #define GDK_Hangul_SunkyeongeumMieum 0xef0 #define GDK_Hangul_SunkyeongeumPieub 0xef1 #define GDK_Hangul_PanSios 0xef2 #define GDK_Hangul_KkogjiDalrinIeung 0xef3 #define GDK_Hangul_SunkyeongeumPhieuf 0xef4 #define GDK_Hangul_YeorinHieuh 0xef5 #define GDK_Hangul_AraeA 0xef6 #define GDK_Hangul_AraeAE 0xef7 #define GDK_Hangul_J_PanSios 0xef8 #define GDK_Hangul_J_KkogjiDalrinIeung 0xef9 #define GDK_Hangul_J_YeorinHieuh 0xefa #define GDK_Korean_Won 0xeff #define GDK_Armenian_ligature_ew 0x587 #define GDK_Armenian_full_stop 0x589 #define GDK_Armenian_verjaket 0x589 #define GDK_Armenian_separation_mark 0x55d #define GDK_Armenian_but 0x55d #define GDK_Armenian_hyphen 0x58a #define GDK_Armenian_yentamna 0x58a #define GDK_Armenian_exclam 0x55c #define GDK_Armenian_amanak 0x55c #define GDK_Armenian_accent 0x55b #define GDK_Armenian_shesht 0x55b #define GDK_Armenian_question 0x55e #define GDK_Armenian_paruyk 0x55e #define GDK_Armenian_AYB 0x531 #define GDK_Armenian_ayb 0x561 #define GDK_Armenian_BEN 0x532 #define GDK_Armenian_ben 0x562 #define GDK_Armenian_GIM 0x533 #define GDK_Armenian_gim 0x563 #define GDK_Armenian_DA 0x534 #define GDK_Armenian_da 0x564 #define GDK_Armenian_YECH 0x535 #define GDK_Armenian_yech 0x565 #define GDK_Armenian_ZA 0x536 #define GDK_Armenian_za 0x566 #define GDK_Armenian_E 0x537 #define GDK_Armenian_e 0x567 #define GDK_Armenian_AT 0x538 #define GDK_Armenian_at 0x568 #define GDK_Armenian_TO 0x539 #define GDK_Armenian_to 0x569 #define GDK_Armenian_ZHE 0x53a #define GDK_Armenian_zhe 0x56a #define GDK_Armenian_INI 0x53b #define GDK_Armenian_ini 0x56b #define GDK_Armenian_LYUN 0x53c #define GDK_Armenian_lyun 0x56c #define GDK_Armenian_KHE 0x53d #define GDK_Armenian_khe 0x56d #define GDK_Armenian_TSA 0x53e #define GDK_Armenian_tsa 0x56e #define GDK_Armenian_KEN 0x53f #define GDK_Armenian_ken 0x56f #define GDK_Armenian_HO 0x540 #define GDK_Armenian_ho 0x570 #define GDK_Armenian_DZA 0x541 #define GDK_Armenian_dza 0x571 #define GDK_Armenian_GHAT 0x542 #define GDK_Armenian_ghat 0x572 #define GDK_Armenian_TCHE 0x543 #define GDK_Armenian_tche 0x573 #define GDK_Armenian_MEN 0x544 #define GDK_Armenian_men 0x574 #define GDK_Armenian_HI 0x545 #define GDK_Armenian_hi 0x575 #define GDK_Armenian_NU 0x546 #define GDK_Armenian_nu 0x576 #define GDK_Armenian_SHA 0x547 #define GDK_Armenian_sha 0x577 #define GDK_Armenian_VO 0x548 #define GDK_Armenian_vo 0x578 #define GDK_Armenian_CHA 0x549 #define GDK_Armenian_cha 0x579 #define GDK_Armenian_PE 0x54a #define GDK_Armenian_pe 0x57a #define GDK_Armenian_JE 0x54b #define GDK_Armenian_je 0x57b #define GDK_Armenian_RA 0x54c #define GDK_Armenian_ra 0x57c #define GDK_Armenian_SE 0x54d #define GDK_Armenian_se 0x57d #define GDK_Armenian_VEV 0x54e #define GDK_Armenian_vev 0x57e #define GDK_Armenian_TYUN 0x54f #define GDK_Armenian_tyun 0x57f #define GDK_Armenian_RE 0x550 #define GDK_Armenian_re 0x580 #define GDK_Armenian_TSO 0x551 #define GDK_Armenian_tso 0x581 #define GDK_Armenian_VYUN 0x552 #define GDK_Armenian_vyun 0x582 #define GDK_Armenian_PYUR 0x553 #define GDK_Armenian_pyur 0x583 #define GDK_Armenian_KE 0x554 #define GDK_Armenian_ke 0x584 #define GDK_Armenian_O 0x555 #define GDK_Armenian_o 0x585 #define GDK_Armenian_FE 0x556 #define GDK_Armenian_fe 0x586 #define GDK_Armenian_apostrophe 0x55a #define GDK_Georgian_an 0x10d0 #define GDK_Georgian_ban 0x10d1 #define GDK_Georgian_gan 0x10d2 #define GDK_Georgian_don 0x10d3 #define GDK_Georgian_en 0x10d4 #define GDK_Georgian_vin 0x10d5 #define GDK_Georgian_zen 0x10d6 #define GDK_Georgian_tan 0x10d7 #define GDK_Georgian_in 0x10d8 #define GDK_Georgian_kan 0x10d9 #define GDK_Georgian_las 0x10da #define GDK_Georgian_man 0x10db #define GDK_Georgian_nar 0x10dc #define GDK_Georgian_on 0x10dd #define GDK_Georgian_par 0x10de #define GDK_Georgian_zhar 0x10df #define GDK_Georgian_rae 0x10e0 #define GDK_Georgian_san 0x10e1 #define GDK_Georgian_tar 0x10e2 #define GDK_Georgian_un 0x10e3 #define GDK_Georgian_phar 0x10e4 #define GDK_Georgian_khar 0x10e5 #define GDK_Georgian_ghan 0x10e6 #define GDK_Georgian_qar 0x10e7 #define GDK_Georgian_shin 0x10e8 #define GDK_Georgian_chin 0x10e9 #define GDK_Georgian_can 0x10ea #define GDK_Georgian_jil 0x10eb #define GDK_Georgian_cil 0x10ec #define GDK_Georgian_char 0x10ed #define GDK_Georgian_xan 0x10ee #define GDK_Georgian_jhan 0x10ef #define GDK_Georgian_hae 0x10f0 #define GDK_Georgian_he 0x10f1 #define GDK_Georgian_hie 0x10f2 #define GDK_Georgian_we 0x10f3 #define GDK_Georgian_har 0x10f4 #define GDK_Georgian_hoe 0x10f5 #define GDK_Georgian_fi 0x10f6 #define GDK_Xabovedot 0x1e8a #define GDK_Ibreve 0x12c #define GDK_Zstroke 0x1b5 #define GDK_Gcaron 0x1e6 #define GDK_Ocaron 0x1d1 #define GDK_Obarred 0x19f #define GDK_xabovedot 0x1e8b #define GDK_ibreve 0x12d #define GDK_zstroke 0x1b6 #define GDK_gcaron 0x1e7 #define GDK_ocaron 0x1d2 #define GDK_obarred 0x275 #define GDK_SCHWA 0x18f #define GDK_schwa 0x259 #define GDK_Lbelowdot 0x1e36 #define GDK_lbelowdot 0x1e37 #define GDK_Abelowdot 0x1ea0 #define GDK_abelowdot 0x1ea1 #define GDK_Ahook 0x1ea2 #define GDK_ahook 0x1ea3 #define GDK_Acircumflexacute 0x1ea4 #define GDK_acircumflexacute 0x1ea5 #define GDK_Acircumflexgrave 0x1ea6 #define GDK_acircumflexgrave 0x1ea7 #define GDK_Acircumflexhook 0x1ea8 #define GDK_acircumflexhook 0x1ea9 #define GDK_Acircumflextilde 0x1eaa #define GDK_acircumflextilde 0x1eab #define GDK_Acircumflexbelowdot 0x1eac #define GDK_acircumflexbelowdot 0x1ead #define GDK_Abreveacute 0x1eae #define GDK_abreveacute 0x1eaf #define GDK_Abrevegrave 0x1eb0 #define GDK_abrevegrave 0x1eb1 #define GDK_Abrevehook 0x1eb2 #define GDK_abrevehook 0x1eb3 #define GDK_Abrevetilde 0x1eb4 #define GDK_abrevetilde 0x1eb5 #define GDK_Abrevebelowdot 0x1eb6 #define GDK_abrevebelowdot 0x1eb7 #define GDK_Ebelowdot 0x1eb8 #define GDK_ebelowdot 0x1eb9 #define GDK_Ehook 0x1eba #define GDK_ehook 0x1ebb #define GDK_Etilde 0x1ebc #define GDK_etilde 0x1ebd #define GDK_Ecircumflexacute 0x1ebe #define GDK_ecircumflexacute 0x1ebf #define GDK_Ecircumflexgrave 0x1ec0 #define GDK_ecircumflexgrave 0x1ec1 #define GDK_Ecircumflexhook 0x1ec2 #define GDK_ecircumflexhook 0x1ec3 #define GDK_Ecircumflextilde 0x1ec4 #define GDK_ecircumflextilde 0x1ec5 #define GDK_Ecircumflexbelowdot 0x1ec6 #define GDK_ecircumflexbelowdot 0x1ec7 #define GDK_Ihook 0x1ec8 #define GDK_ihook 0x1ec9 #define GDK_Ibelowdot 0x1eca #define GDK_ibelowdot 0x1ecb #define GDK_Obelowdot 0x1ecc #define GDK_obelowdot 0x1ecd #define GDK_Ohook 0x1ece #define GDK_ohook 0x1ecf #define GDK_Ocircumflexacute 0x1ed0 #define GDK_ocircumflexacute 0x1ed1 #define GDK_Ocircumflexgrave 0x1ed2 #define GDK_ocircumflexgrave 0x1ed3 #define GDK_Ocircumflexhook 0x1ed4 #define GDK_ocircumflexhook 0x1ed5 #define GDK_Ocircumflextilde 0x1ed6 #define GDK_ocircumflextilde 0x1ed7 #define GDK_Ocircumflexbelowdot 0x1ed8 #define GDK_ocircumflexbelowdot 0x1ed9 #define GDK_Ohornacute 0x1eda #define GDK_ohornacute 0x1edb #define GDK_Ohorngrave 0x1edc #define GDK_ohorngrave 0x1edd #define GDK_Ohornhook 0x1ede #define GDK_ohornhook 0x1edf #define GDK_Ohorntilde 0x1ee0 #define GDK_ohorntilde 0x1ee1 #define GDK_Ohornbelowdot 0x1ee2 #define GDK_ohornbelowdot 0x1ee3 #define GDK_Ubelowdot 0x1ee4 #define GDK_ubelowdot 0x1ee5 #define GDK_Uhook 0x1ee6 #define GDK_uhook 0x1ee7 #define GDK_Uhornacute 0x1ee8 #define GDK_uhornacute 0x1ee9 #define GDK_Uhorngrave 0x1eea #define GDK_uhorngrave 0x1eeb #define GDK_Uhornhook 0x1eec #define GDK_uhornhook 0x1eed #define GDK_Uhorntilde 0x1eee #define GDK_uhorntilde 0x1eef #define GDK_Uhornbelowdot 0x1ef0 #define GDK_uhornbelowdot 0x1ef1 #define GDK_Ybelowdot 0x1ef4 #define GDK_ybelowdot 0x1ef5 #define GDK_Yhook 0x1ef6 #define GDK_yhook 0x1ef7 #define GDK_Ytilde 0x1ef8 #define GDK_ytilde 0x1ef9 #define GDK_Ohorn 0x1a0 #define GDK_ohorn 0x1a1 #define GDK_Uhorn 0x1af #define GDK_uhorn 0x1b0 #define GDK_EcuSign 0x20a0 #define GDK_ColonSign 0x20a1 #define GDK_CruzeiroSign 0x20a2 #define GDK_FFrancSign 0x20a3 #define GDK_LiraSign 0x20a4 #define GDK_MillSign 0x20a5 #define GDK_NairaSign 0x20a6 #define GDK_PesetaSign 0x20a7 #define GDK_RupeeSign 0x20a8 #define GDK_WonSign 0x20a9 #define GDK_NewSheqelSign 0x20aa #define GDK_DongSign 0x20ab #define GDK_EuroSign 0x20ac #define GDK_zerosuperior 0x2070 #define GDK_foursuperior 0x2074 #define GDK_fivesuperior 0x2075 #define GDK_sixsuperior 0x2076 #define GDK_sevensuperior 0x2077 #define GDK_eightsuperior 0x2078 #define GDK_ninesuperior 0x2079 #define GDK_zerosubscript 0x2080 #define GDK_onesubscript 0x2081 #define GDK_twosubscript 0x2082 #define GDK_threesubscript 0x2083 #define GDK_foursubscript 0x2084 #define GDK_fivesubscript 0x2085 #define GDK_sixsubscript 0x2086 #define GDK_sevensubscript 0x2087 #define GDK_eightsubscript 0x2088 #define GDK_ninesubscript 0x2089 #define GDK_partdifferential 0x2202 #define GDK_emptyset 0x2205 #define GDK_elementof 0x2208 #define GDK_notelementof 0x2209 #define GDK_containsas 0x220b #define GDK_squareroot 0x221a #define GDK_cuberoot 0x221b #define GDK_fourthroot 0x221c #define GDK_dintegral 0x222c #define GDK_tintegral 0x222d #define GDK_because 0x2235 #define GDK_approxeq 0x2248 #define GDK_notapproxeq 0x2247 #define GDK_notidentical 0x2262 #define GDK_stricteq 0x2263 #define GDK_braille_dot_1 0xfff1 #define GDK_braille_dot_2 0xfff2 #define GDK_braille_dot_3 0xfff3 #define GDK_braille_dot_4 0xfff4 #define GDK_braille_dot_5 0xfff5 #define GDK_braille_dot_6 0xfff6 #define GDK_braille_dot_7 0xfff7 #define GDK_braille_dot_8 0xfff8 #define GDK_braille_dot_9 0xfff9 #define GDK_braille_dot_10 0xfffa #define GDK_braille_blank 0x2800 #define GDK_braille_dots_1 0x2801 #define GDK_braille_dots_2 0x2802 #define GDK_braille_dots_12 0x2803 #define GDK_braille_dots_3 0x2804 #define GDK_braille_dots_13 0x2805 #define GDK_braille_dots_23 0x2806 #define GDK_braille_dots_123 0x2807 #define GDK_braille_dots_4 0x2808 #define GDK_braille_dots_14 0x2809 #define GDK_braille_dots_24 0x280a #define GDK_braille_dots_124 0x280b #define GDK_braille_dots_34 0x280c #define GDK_braille_dots_134 0x280d #define GDK_braille_dots_234 0x280e #define GDK_braille_dots_1234 0x280f #define GDK_braille_dots_5 0x2810 #define GDK_braille_dots_15 0x2811 #define GDK_braille_dots_25 0x2812 #define GDK_braille_dots_125 0x2813 #define GDK_braille_dots_35 0x2814 #define GDK_braille_dots_135 0x2815 #define GDK_braille_dots_235 0x2816 #define GDK_braille_dots_1235 0x2817 #define GDK_braille_dots_45 0x2818 #define GDK_braille_dots_145 0x2819 #define GDK_braille_dots_245 0x281a #define GDK_braille_dots_1245 0x281b #define GDK_braille_dots_345 0x281c #define GDK_braille_dots_1345 0x281d #define GDK_braille_dots_2345 0x281e #define GDK_braille_dots_12345 0x281f #define GDK_braille_dots_6 0x2820 #define GDK_braille_dots_16 0x2821 #define GDK_braille_dots_26 0x2822 #define GDK_braille_dots_126 0x2823 #define GDK_braille_dots_36 0x2824 #define GDK_braille_dots_136 0x2825 #define GDK_braille_dots_236 0x2826 #define GDK_braille_dots_1236 0x2827 #define GDK_braille_dots_46 0x2828 #define GDK_braille_dots_146 0x2829 #define GDK_braille_dots_246 0x282a #define GDK_braille_dots_1246 0x282b #define GDK_braille_dots_346 0x282c #define GDK_braille_dots_1346 0x282d #define GDK_braille_dots_2346 0x282e #define GDK_braille_dots_12346 0x282f #define GDK_braille_dots_56 0x2830 #define GDK_braille_dots_156 0x2831 #define GDK_braille_dots_256 0x2832 #define GDK_braille_dots_1256 0x2833 #define GDK_braille_dots_356 0x2834 #define GDK_braille_dots_1356 0x2835 #define GDK_braille_dots_2356 0x2836 #define GDK_braille_dots_12356 0x2837 #define GDK_braille_dots_456 0x2838 #define GDK_braille_dots_1456 0x2839 #define GDK_braille_dots_2456 0x283a #define GDK_braille_dots_12456 0x283b #define GDK_braille_dots_3456 0x283c #define GDK_braille_dots_13456 0x283d #define GDK_braille_dots_23456 0x283e #define GDK_braille_dots_123456 0x283f #define GDK_braille_dots_7 0x2840 #define GDK_braille_dots_17 0x2841 #define GDK_braille_dots_27 0x2842 #define GDK_braille_dots_127 0x2843 #define GDK_braille_dots_37 0x2844 #define GDK_braille_dots_137 0x2845 #define GDK_braille_dots_237 0x2846 #define GDK_braille_dots_1237 0x2847 #define GDK_braille_dots_47 0x2848 #define GDK_braille_dots_147 0x2849 #define GDK_braille_dots_247 0x284a #define GDK_braille_dots_1247 0x284b #define GDK_braille_dots_347 0x284c #define GDK_braille_dots_1347 0x284d #define GDK_braille_dots_2347 0x284e #define GDK_braille_dots_12347 0x284f #define GDK_braille_dots_57 0x2850 #define GDK_braille_dots_157 0x2851 #define GDK_braille_dots_257 0x2852 #define GDK_braille_dots_1257 0x2853 #define GDK_braille_dots_357 0x2854 #define GDK_braille_dots_1357 0x2855 #define GDK_braille_dots_2357 0x2856 #define GDK_braille_dots_12357 0x2857 #define GDK_braille_dots_457 0x2858 #define GDK_braille_dots_1457 0x2859 #define GDK_braille_dots_2457 0x285a #define GDK_braille_dots_12457 0x285b #define GDK_braille_dots_3457 0x285c #define GDK_braille_dots_13457 0x285d #define GDK_braille_dots_23457 0x285e #define GDK_braille_dots_123457 0x285f #define GDK_braille_dots_67 0x2860 #define GDK_braille_dots_167 0x2861 #define GDK_braille_dots_267 0x2862 #define GDK_braille_dots_1267 0x2863 #define GDK_braille_dots_367 0x2864 #define GDK_braille_dots_1367 0x2865 #define GDK_braille_dots_2367 0x2866 #define GDK_braille_dots_12367 0x2867 #define GDK_braille_dots_467 0x2868 #define GDK_braille_dots_1467 0x2869 #define GDK_braille_dots_2467 0x286a #define GDK_braille_dots_12467 0x286b #define GDK_braille_dots_3467 0x286c #define GDK_braille_dots_13467 0x286d #define GDK_braille_dots_23467 0x286e #define GDK_braille_dots_123467 0x286f #define GDK_braille_dots_567 0x2870 #define GDK_braille_dots_1567 0x2871 #define GDK_braille_dots_2567 0x2872 #define GDK_braille_dots_12567 0x2873 #define GDK_braille_dots_3567 0x2874 #define GDK_braille_dots_13567 0x2875 #define GDK_braille_dots_23567 0x2876 #define GDK_braille_dots_123567 0x2877 #define GDK_braille_dots_4567 0x2878 #define GDK_braille_dots_14567 0x2879 #define GDK_braille_dots_24567 0x287a #define GDK_braille_dots_124567 0x287b #define GDK_braille_dots_34567 0x287c #define GDK_braille_dots_134567 0x287d #define GDK_braille_dots_234567 0x287e #define GDK_braille_dots_1234567 0x287f #define GDK_braille_dots_8 0x2880 #define GDK_braille_dots_18 0x2881 #define GDK_braille_dots_28 0x2882 #define GDK_braille_dots_128 0x2883 #define GDK_braille_dots_38 0x2884 #define GDK_braille_dots_138 0x2885 #define GDK_braille_dots_238 0x2886 #define GDK_braille_dots_1238 0x2887 #define GDK_braille_dots_48 0x2888 #define GDK_braille_dots_148 0x2889 #define GDK_braille_dots_248 0x288a #define GDK_braille_dots_1248 0x288b #define GDK_braille_dots_348 0x288c #define GDK_braille_dots_1348 0x288d #define GDK_braille_dots_2348 0x288e #define GDK_braille_dots_12348 0x288f #define GDK_braille_dots_58 0x2890 #define GDK_braille_dots_158 0x2891 #define GDK_braille_dots_258 0x2892 #define GDK_braille_dots_1258 0x2893 #define GDK_braille_dots_358 0x2894 #define GDK_braille_dots_1358 0x2895 #define GDK_braille_dots_2358 0x2896 #define GDK_braille_dots_12358 0x2897 #define GDK_braille_dots_458 0x2898 #define GDK_braille_dots_1458 0x2899 #define GDK_braille_dots_2458 0x289a #define GDK_braille_dots_12458 0x289b #define GDK_braille_dots_3458 0x289c #define GDK_braille_dots_13458 0x289d #define GDK_braille_dots_23458 0x289e #define GDK_braille_dots_123458 0x289f #define GDK_braille_dots_68 0x28a0 #define GDK_braille_dots_168 0x28a1 #define GDK_braille_dots_268 0x28a2 #define GDK_braille_dots_1268 0x28a3 #define GDK_braille_dots_368 0x28a4 #define GDK_braille_dots_1368 0x28a5 #define GDK_braille_dots_2368 0x28a6 #define GDK_braille_dots_12368 0x28a7 #define GDK_braille_dots_468 0x28a8 #define GDK_braille_dots_1468 0x28a9 #define GDK_braille_dots_2468 0x28aa #define GDK_braille_dots_12468 0x28ab #define GDK_braille_dots_3468 0x28ac #define GDK_braille_dots_13468 0x28ad #define GDK_braille_dots_23468 0x28ae #define GDK_braille_dots_123468 0x28af #define GDK_braille_dots_568 0x28b0 #define GDK_braille_dots_1568 0x28b1 #define GDK_braille_dots_2568 0x28b2 #define GDK_braille_dots_12568 0x28b3 #define GDK_braille_dots_3568 0x28b4 #define GDK_braille_dots_13568 0x28b5 #define GDK_braille_dots_23568 0x28b6 #define GDK_braille_dots_123568 0x28b7 #define GDK_braille_dots_4568 0x28b8 #define GDK_braille_dots_14568 0x28b9 #define GDK_braille_dots_24568 0x28ba #define GDK_braille_dots_124568 0x28bb #define GDK_braille_dots_34568 0x28bc #define GDK_braille_dots_134568 0x28bd #define GDK_braille_dots_234568 0x28be #define GDK_braille_dots_1234568 0x28bf #define GDK_braille_dots_78 0x28c0 #define GDK_braille_dots_178 0x28c1 #define GDK_braille_dots_278 0x28c2 #define GDK_braille_dots_1278 0x28c3 #define GDK_braille_dots_378 0x28c4 #define GDK_braille_dots_1378 0x28c5 #define GDK_braille_dots_2378 0x28c6 #define GDK_braille_dots_12378 0x28c7 #define GDK_braille_dots_478 0x28c8 #define GDK_braille_dots_1478 0x28c9 #define GDK_braille_dots_2478 0x28ca #define GDK_braille_dots_12478 0x28cb #define GDK_braille_dots_3478 0x28cc #define GDK_braille_dots_13478 0x28cd #define GDK_braille_dots_23478 0x28ce #define GDK_braille_dots_123478 0x28cf #define GDK_braille_dots_578 0x28d0 #define GDK_braille_dots_1578 0x28d1 #define GDK_braille_dots_2578 0x28d2 #define GDK_braille_dots_12578 0x28d3 #define GDK_braille_dots_3578 0x28d4 #define GDK_braille_dots_13578 0x28d5 #define GDK_braille_dots_23578 0x28d6 #define GDK_braille_dots_123578 0x28d7 #define GDK_braille_dots_4578 0x28d8 #define GDK_braille_dots_14578 0x28d9 #define GDK_braille_dots_24578 0x28da #define GDK_braille_dots_124578 0x28db #define GDK_braille_dots_34578 0x28dc #define GDK_braille_dots_134578 0x28dd #define GDK_braille_dots_234578 0x28de #define GDK_braille_dots_1234578 0x28df #define GDK_braille_dots_678 0x28e0 #define GDK_braille_dots_1678 0x28e1 #define GDK_braille_dots_2678 0x28e2 #define GDK_braille_dots_12678 0x28e3 #define GDK_braille_dots_3678 0x28e4 #define GDK_braille_dots_13678 0x28e5 #define GDK_braille_dots_23678 0x28e6 #define GDK_braille_dots_123678 0x28e7 #define GDK_braille_dots_4678 0x28e8 #define GDK_braille_dots_14678 0x28e9 #define GDK_braille_dots_24678 0x28ea #define GDK_braille_dots_124678 0x28eb #define GDK_braille_dots_34678 0x28ec #define GDK_braille_dots_134678 0x28ed #define GDK_braille_dots_234678 0x28ee #define GDK_braille_dots_1234678 0x28ef #define GDK_braille_dots_5678 0x28f0 #define GDK_braille_dots_15678 0x28f1 #define GDK_braille_dots_25678 0x28f2 #define GDK_braille_dots_125678 0x28f3 #define GDK_braille_dots_35678 0x28f4 #define GDK_braille_dots_135678 0x28f5 #define GDK_braille_dots_235678 0x28f6 #define GDK_braille_dots_1235678 0x28f7 #define GDK_braille_dots_45678 0x28f8 #define GDK_braille_dots_145678 0x28f9 #define GDK_braille_dots_245678 0x28fa #define GDK_braille_dots_1245678 0x28fb #define GDK_braille_dots_345678 0x28fc #define GDK_braille_dots_1345678 0x28fd #define GDK_braille_dots_2345678 0x28fe #define GDK_braille_dots_12345678 0x28ff (* ****** ****** *) (* end of [gdkkeys.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdk/gdkcolor.sats0000664000175000017500000000465012223166165022111 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) fun gdk_color3_set ( color: &GdkColor, r: uint, b: uint, g: uint ) :<> void = "mac#atsctrb_gdk_color3_set" // end of [gdk_color3_set] fun gdk_color4_set ( color: &GdkColor, pix: uint, r: uint, b: uint, g: uint ) :<> void = "mac#atsctrb_gdk_color4_set" // end of [gdk_color4_set] (* ****** ****** *) (* GdkColor *gdk_color_copy (const GdkColor *color); void gdk_color_free (GdkColor *color); *) fun gdk_color_copy ( color: &GdkColor ) : [l:addr] (GdkFree_v l, GdkColor @ l | ptr l) = "mac#atsctrb_gdk_color_copy" // end of [gdk_color_copy] fun gdk_color_free {l:addr} ( pf1: GdkFree_v l, pf2: GdkColor @ l | p: ptr l ) : void = "mac#atsctrb_gdk_color_free" // end of [gdk_color_free] (* ****** ****** *) fun gdk_color_parse {l:agz} ( spec: !gstring l, color: &GdkColor? >> opt (GdkColor, b) ) : #[b:bool] gboolean b = "mac#atsctrb_gdk_color_parse" // end of [gdk_color_parse] (* ****** ****** *) (* end of [gdkcolor.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/SATS/gdkclassdec.sats0000664000175000017500000000404512223166165022005 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef GObject = $GOBJ.GObject (* ****** ****** *) // // class hierarchy for GDK // classdec GdkColormap : GObject classdec GdkObject : GObject classdec GdkDrawable : GdkObject classdec GdkBitmap : GdkDrawable // offscreen of depth 1 classdec GdkPixmap : GdkDrawable classdec GdkWindow : GdkDrawable // end of [GdkDrawable] // end of [GdkObject] classdec GdkPixbuf : GObject (* ****** ****** *) (* end of [gdkclassdec.sats] *) ats-lang-anairiats-0.2.11/contrib/GTK/Makefile0000664000175000017500000000114412223166165017525 0ustar hwxihwxi# # API for GTK in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: May, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif # end of [ifeq] ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSCTRB=$(ATSUSRQ)/contrib GTKCFLAGS = `pkg-config gtk+-2.0 --cflags` ###### all:: atsctrb_GTK.o all:: clean ###### atsctrb_GTK.o: GTK_dats.o ld -r -o $@ GTK_dats.o ###### GTK_dats.o: DATS/gtk.dats $(ATSCC) -Wall $(GTKCFLAGS) -o $@ -c $< ###### RMF=rm -f ###### clean:: ; $(RMF) *_?ats.c *_?ats.o cleanall:: clean cleanall:: ; $(RMF) atsctrb_GTK.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/GTK/DATS/0000700000175000017500000000000012223166165016604 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GTK/DATS/gtk.dats0000664000175000017500000000414712223166165020270 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynloading at run-time (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdkclassdec.sats" staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) // // source: gtkwidget.sats // implement gtk_widget_show_unref {c} (widget) = let prval () = clstrans {c,GtkWidget,GObject} () val () = gtk_widget_show (widget) in g_object_unref (widget) end // end of [gtk_widget_show_unref] (* ****** ****** *) (* end of [gtk.dats] *) ats-lang-anairiats-0.2.11/contrib/clapack/0000700000175000017500000000000012223166165017022 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/CATS/0000700000175000017500000000000012223166165017554 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/CATS/f2c.cats0000664000175000017500000003120312223166165021115 0ustar hwxihwxi/* ** ** An interface for ATS to interact with LAPACK ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** */ // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // /* ****** ****** */ #ifndef ATS_CONTRIB_F2C_CATS #define ATS_CONTRIB_F2C_CATS /* ****** ****** */ #include "libc/CATS/complex.cats" /* ****** ****** */ /* ** #include "f2c.h" */ typedef long int F2Cinteger; typedef unsigned long int F2Cuinteger; typedef char *F2Caddress; typedef short int F2Cshortint; typedef float F2Creal; typedef double F2Cdoublereal; /* typedef struct { F2Creal r, i; } F2Ccomplex; */ typedef ats_fcomplex_type F2Ccomplex; /* typedef struct { F2Cdoublereal r, i; } F2Cdoublecomplex; */ typedef ats_dcomplex_type F2Cdoublecomplex; typedef long int F2Clogical; typedef short int F2Cshortlogical; typedef char F2Clogical1; typedef char F2Cinteger1; /* ****** ****** */ // real // // arithmetic operations // extern float absf (float x) ; static inline F2Creal atsctrb_f2c_abs_real (F2Creal x) { return (absf(x)) ; } // end of [atsctrb_f2c_abs_real] static inline F2Creal atsctrb_f2c_neg_real (F2Creal x) { return (-x) ; } // end of [atsctrb_f2c_neg_real] static inline F2Creal atsctrb_f2c_add_real_real (F2Creal x1, F2Creal x2) { return (x1 + x2) ; } // end of [atsctrb_f2c_add_real_real] static inline F2Creal atsctrb_f2c_sub_real_real (F2Creal x1, F2Creal x2) { return (x1 - x2) ; } // end of [atsctrb_f2c_sub_real_real] static inline F2Creal atsctrb_f2c_mul_real_real (F2Creal x1, F2Creal x2) { return (x1 * x2) ; } // end of [atsctrb_f2c_mul_real_real] static inline F2Creal atsctrb_f2c_div_real_real (F2Creal x1, F2Creal x2) { return (x1 / x2) ; } // end of [atsctrb_f2c_div_real_real] // // comparison operations // static inline ats_bool_type atsctrb_f2c_lt_real_real (F2Creal x1, F2Creal x2) { return (x1 < x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_lt_real_real] static inline ats_bool_type atsctrb_f2c_lte_real_real (F2Creal x1, F2Creal x2) { return (x1 <= x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_lte_real_real] static inline ats_bool_type atsctrb_f2c_gt_real_real (F2Creal x1, F2Creal x2) { return (x1 > x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_gt_real_real] static inline ats_bool_type atsctrb_f2c_gte_real_real (F2Creal x1, F2Creal x2) { return (x1 >= x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_gte_real_real] static inline ats_bool_type atsctrb_f2c_eq_real_real (F2Creal x1, F2Creal x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_eq_real_real] static inline ats_bool_type atsctrb_f2c_neq_real_real (F2Creal x1, F2Creal x2) { return (x1 != x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_neq_real_real] /* ****** ****** */ // doublereal // // arithmetic operations // static inline F2Cdoublereal atsctrb_f2c_abs_doublereal (F2Cdoublereal x) { return (absf(x)) ; } // end of [atsctrb_f2c_abs_doublereal] static inline F2Cdoublereal atsctrb_f2c_neg_doublereal (F2Cdoublereal x) { return (-x) ; } // end of [atsctrb_f2c_neg_doublereal] static inline F2Cdoublereal atsctrb_f2c_add_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 + x2) ; } // end of [atsctrb_f2c_add_doublereal_doublereal] static inline F2Cdoublereal atsctrb_f2c_sub_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 - x2) ; } // end of [atsctrb_f2c_sub_doublereal_doublereal] static inline F2Cdoublereal atsctrb_f2c_mul_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 * x2) ; } // end of [atsctrb_f2c_mul_doublereal_doublereal] static inline F2Cdoublereal atsctrb_f2c_div_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 / x2) ; } // end of [atsctrb_f2c_div_doublereal_doublereal] // // comparison operations // static inline ats_bool_type atsctrb_f2c_lt_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 < x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_lt_doublereal_doublereal] static inline ats_bool_type atsctrb_f2c_lte_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 <= x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_lte_doublereal_doublereal] static inline ats_bool_type atsctrb_f2c_gt_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 > x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_gt_doublereal_doublereal] static inline ats_bool_type atsctrb_f2c_gte_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 >= x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_gte_doublereal_doublereal] static inline ats_bool_type atsctrb_f2c_eq_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_eq_doublereal_doublereal] static inline ats_bool_type atsctrb_f2c_neq_doublereal_doublereal (F2Cdoublereal x1, F2Cdoublereal x2) { return (x1 != x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_f2c_neq_doublereal_doublereal] /* ****** ****** */ #if (0) static inline F2Ccomplex atsctrb_f2c_complex_of_ccmplx (ats_fcomplex_type x) { F2Ccomplex y ; y.r = crealf(x) ; y.i = cimagf(x) ; return y ; } /* end of [atsctrb_complex_of_ccmplx] */ static inline ats_fcomplex_type atsctrb_f2c_ccmplx_of_complex (F2Ccomplex x) { return (x.r + x.i * I) ; } /* end of [atsctrb_ccmplx_of_complex] */ #endif // [#if (0)] #if (1) static inline F2Ccomplex atsctrb_f2c_complex_of_ccmplx (ats_fcomplex_type x) { return *(F2Ccomplex*)&x ; } /* end of [atsctrb_complex_of_ccmplx] */ static inline ats_fcomplex_type atsctrb_f2c_ccmplx_of_complex (F2Ccomplex x) { return *(ats_fcomplex_type*)&x ; } /* end of [atsctrb_ccmplx_of_complex] */ #endif // [#if (1)] /* ****** ****** */ // complex // // arithmetic operations // static inline F2Ccomplex atsctrb_f2c_add_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return atsctrb_f2c_complex_of_ccmplx ( atsctrb_f2c_ccmplx_of_complex (x1) + atsctrb_f2c_ccmplx_of_complex (x2) ) ; } /* end of [atsctrb_f2c_add_complex_complex] */ static inline F2Ccomplex atsctrb_f2c_sub_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return atsctrb_f2c_complex_of_ccmplx ( atsctrb_f2c_ccmplx_of_complex (x1) - atsctrb_f2c_ccmplx_of_complex (x2) ) ; } /* end of [atsctrb_f2c_sub_complex_complex] */ static inline F2Ccomplex atsctrb_f2c_mul_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return atsctrb_f2c_complex_of_ccmplx ( atsctrb_f2c_ccmplx_of_complex (x1) * atsctrb_f2c_ccmplx_of_complex (x2) ) ; } /* end of [atsctrb_f2c_mul_complex_complex] */ static inline F2Ccomplex atsctrb_f2c_div_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return atsctrb_f2c_complex_of_ccmplx ( atsctrb_f2c_ccmplx_of_complex (x1) / atsctrb_f2c_ccmplx_of_complex (x2) ) ; } /* end of [atsctrb_f2c_div_complex_complex] */ static inline ats_bool_type atsctrb_f2c_eq_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return ( atsctrb_f2c_ccmplx_of_complex (x1) == atsctrb_f2c_ccmplx_of_complex (x2) ? ats_true_bool : ats_false_bool ) ; } /* end of [atsctrb_f2c_eq_complex_complex] */ static inline ats_bool_type atsctrb_f2c_neq_complex_complex (F2Ccomplex x1, F2Ccomplex x2) { return ( atsctrb_f2c_ccmplx_of_complex (x1) != atsctrb_f2c_ccmplx_of_complex (x2) ? ats_true_bool : ats_false_bool ) ; } /* end of [atsctrb_f2c_neq_complex_complex] */ /* ****** ****** */ #if (0) static inline F2Cdoublecomplex atsctrb_f2c_doublecomplex_of_zcmplx (ats_dcomplex_type x) { F2Cdoublecomplex y ; y.r = creal(x) ; y.i = cimag(x) ; return y ; } /* end of [atsctrb_f2c_doublecomplex_of_zcmplx] */ static inline ats_dcomplex_type atsctrb_f2c_zcmplx_of_doublecomplex (F2Cdoublecomplex x) { return (x.r + x.i * I) ; } /* end of [atsctrb_zcmplx_of_doublecomplex] */ #endif // [#if (0)] #if (1) static inline F2Cdoublecomplex atsctrb_f2c_doublecomplex_of_zcmplx (ats_dcomplex_type x) { return *(F2Cdoublecomplex*)&x ; } /* end of [atsctrb_doublecomplex_of_zcmplx] */ static inline ats_dcomplex_type atsctrb_f2c_zcmplx_of_doublecomplex (F2Cdoublecomplex x) { return *(ats_dcomplex_type*)&x ; } /* end of [atsctrb_zcmplx_of_doublecomplex] */ #endif // [#if (1)] /* ****** ****** */ // doublecomplex // // arithmetic operations // static inline F2Cdoublecomplex atsctrb_f2c_add_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return atsctrb_f2c_doublecomplex_of_zcmplx ( atsctrb_f2c_zcmplx_of_doublecomplex (x1) + atsctrb_f2c_zcmplx_of_doublecomplex (x2) ) ; } /* end of [atsctrb_f2c_add_doublecomplex_doublecomplex] */ static inline F2Cdoublecomplex atsctrb_f2c_sub_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return atsctrb_f2c_doublecomplex_of_zcmplx ( atsctrb_f2c_zcmplx_of_doublecomplex (x1) - atsctrb_f2c_zcmplx_of_doublecomplex (x2) ) ; } /* end of [atsctrb_f2c_sub_doublecomplex_doublecomplex] */ static inline F2Cdoublecomplex atsctrb_f2c_mul_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return atsctrb_f2c_doublecomplex_of_zcmplx ( atsctrb_f2c_zcmplx_of_doublecomplex (x1) * atsctrb_f2c_zcmplx_of_doublecomplex (x2) ) ; } /* end of [atsctrb_f2c_mul_doublecomplex_doublecomplex] */ static inline F2Cdoublecomplex atsctrb_f2c_div_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return atsctrb_f2c_doublecomplex_of_zcmplx ( atsctrb_f2c_zcmplx_of_doublecomplex (x1) / atsctrb_f2c_zcmplx_of_doublecomplex (x2) ) ; } /* end of [atsctrb_f2c_div_doublecomplex_doublecomplex] */ static inline ats_bool_type atsctrb_f2c_eq_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return ( atsctrb_f2c_ccmplx_of_doublecomplex (x1) == atsctrb_f2c_ccmplx_of_doublecomplex (x2) ? ats_true_bool : ats_false_bool ) ; } /* end of [atsctrb_f2c_eq_doublecomplex_doublecomplex] */ static inline ats_bool_type atsctrb_f2c_neq_doublecomplex_doublecomplex (F2Cdoublecomplex x1, F2Cdoublecomplex x2) { return ( atsctrb_f2c_ccmplx_of_doublecomplex (x1) != atsctrb_f2c_ccmplx_of_doublecomplex (x2) ? ats_true_bool : ats_false_bool ) ; } /* end of [atsctrb_f2c_neq_doublecomplex_doublecomplex] */ /* ****** ****** */ static inline F2Cinteger atsctrb_f2c_add_integer_integer (F2Cinteger i, F2Cinteger j) { return (i + j); } // end of [atsctrb_f2c_add_integer_integer] static inline F2Cinteger atsctrb_f2c_add_int1_integer (ats_int_type i, F2Cinteger j) { return (i + j); } // end of [atsctrb_f2c_add_int1_integer] static inline F2Cinteger atsctrb_f2c_add_integer_int1 (F2Cinteger i, ats_int_type j) { return (i + j); } // end of [atsctrb_f2c_add_integer_int1] static inline F2Cinteger atsctrb_f2c_sub_integer_integer (F2Cinteger i, F2Cinteger j) { return (i - j); } // end of [atsctrb_f2c_sub_integer_integer] static inline F2Cinteger atsctrb_f2c_mul_integer_integer (F2Cinteger i, F2Cinteger j) { return (i * j); } // end of [atsctrb_f2c_mul_integer_integer] /* ****** ****** */ static inline ats_bool_type atsctrb_f2c_lt_integer_integer (F2Cinteger i, F2Cinteger j) { return (i < j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_lt_integer_integer] static inline ats_bool_type atsctrb_f2c_lte_integer_integer (F2Cinteger i, F2Cinteger j) { return (i <= j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_lte_integer_integer] static inline ats_bool_type atsctrb_f2c_gt_integer_integer (F2Cinteger i, F2Cinteger j) { return (i > j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_gt_integer_integer] static inline ats_bool_type atsctrb_f2c_gte_integer_integer (F2Cinteger i, F2Cinteger j) { return (i >= j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_gte_integer_integer] static inline ats_bool_type atsctrb_f2c_eq_integer_integer (F2Cinteger i, F2Cinteger j) { return (i == j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_eq_integer_integer] static inline ats_bool_type atsctrb_f2c_neq_integer_integer (F2Cinteger i, F2Cinteger j) { return (i != j ? ats_true_bool : ats_false_bool); } // end of [atsctrb_f2c_neq_integer_integer] /* ****** ****** */ static inline F2Cinteger atsctrb_f2c_max_integer_integer (F2Cinteger i, F2Cinteger j) { return (i >= j ? i : j); } // end of [atsctrb_f2c_max_integer_integer] static inline F2Cinteger atsctrb_f2c_min_integer_integer (F2Cinteger i, F2Cinteger j) { return (i <= j ? i : j); } // end of [atsctrb_f2c_min_integer_integer] /* ****** ****** */ #endif /* end of [ATS_CONTRIB_F2C_CATS] */ /* end of [f2c.cats] */ ats-lang-anairiats-0.2.11/contrib/clapack/CATS/clapack.cats0000664000175000017500000010731712223166165022053 0ustar hwxihwxi/* ** ** An interface for ATS to interact with LAPACK ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** */ // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // /* ****** ****** */ #ifndef ATS_CONTRIB_CLAPACK_CATS #define ATS_CONTRIB_CLAPACK_CATS /* ****** ****** */ #include "f2c.cats" /* ****** ****** */ /* ** lamch: S, D */ #if (0) doublereal dlamch_(char *cmach) ; #endif extern // F2Creal slamch_ (char *cmach) ; F2Cdoublereal slamch_t (char *cmach) ; // CLAPACK says it! ATSinline() F2Creal atsctrb_clapack_slamch (ats_char_type cmach) { return slamch_(&cmach) ; } // end of [atsctrb_clapack_slamch] extern F2Cdoublereal dlamch_ (char *cmach) ; ATSinline() F2Cdoublereal atsctrb_clapack_dlamch (ats_char_type cmach) { return dlamch_(&cmach) ; } // end of [atsctrb_clapack_dlamch] /* ****** ****** */ /* ** lange: S, D, C, Z */ #if (0) /* Subroutine */ doublereal dlange_( char *norm , integer *m, integer *n , doublereal *a, integer *lda , doublereal *work ) ; #endif extern F2Creal slange_( char *norm , F2Cinteger *m , F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *work ) ; ATSinline() F2Creal atsctrb_clapack_slange ( ats_char_type norm , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ptr_type work ) { F2Creal res ; res = slange_(&norm, &m, &n, a, &lda, work) ; return res ; } /* end of [atsctrb_clapack_slange] */ // extern F2Cdoublereal dlange_( char *norm , F2Cinteger *m , F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *work ) ; ATSinline() F2Cdoublereal atsctrb_clapack_dlange ( ats_char_type norm , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ptr_type work ) { F2Cdoublereal res ; res = dlange_(&norm, &m, &n, a, &lda, work) ; return res ; } /* end of [atsctrb_clapack_dlange] */ // extern F2Creal clange_( char *norm , F2Cinteger *m , F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *work ) ; ATSinline() F2Creal atsctrb_clapack_clange ( ats_char_type norm , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ptr_type work ) { F2Creal res ; res = clange_(&norm, &m, &n, a, &lda, work) ; return res ; } /* end of [atsctrb_clapack_clange] */ // extern F2Cdoublereal zlange_( char *norm , F2Cinteger *m , F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *work ) ; ATSinline() F2Cdoublereal atsctrb_clapack_zlange ( ats_char_type norm , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ptr_type work ) { F2Cdoublereal res ; res = zlange_(&norm, &m, &n, a, &lda, work) ; return res ; } /* end of [atsctrb_clapack_zlange] */ /* ****** ****** */ /* ** lacpy: S, D, C, Z */ extern int slacpy_( char *uplo , F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *b, F2Cinteger *ldb ) ; ATSinline() ats_void_type atsctrb_clapack_slacpy ( ats_char_type uln , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { slacpy_(&uln, &m, &n, a, &lda, b, &ldb) ; return ; } /* end of [atsctrb_clapack_slacpy] */ // extern int dlacpy_( char *uplo , F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *b, F2Cinteger *ldb ) ; ATSinline() ats_void_type atsctrb_clapack_dlacpy ( ats_char_type uln , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { dlacpy_(&uln, &m, &n, a, &lda, b, &ldb) ; return ; } /* end of [atsctrb_clapack_dlacpy] */ // extern int clacpy_( char *uplo , F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *b, F2Cinteger *ldb ) ; ATSinline() ats_void_type atsctrb_clapack_clacpy ( ats_char_type uln , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { clacpy_(&uln, &m, &n, a, &lda, b, &ldb) ; return ; } /* end of [atsctrb_clapack_clacpy] */ // extern int zlacpy_( char *uplo , F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *b, F2Cinteger *ldb ) ; ATSinline() ats_void_type atsctrb_clapack_zlacpy ( ats_char_type uln , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { zlacpy_(&uln, &m, &n, a, &lda, b, &ldb) ; return ; } /* end of [atsctrb_clapack_zlacpy] */ /* ****** ****** */ /* ** gelqf: S, D, C, Z */ extern int sgelqf_( F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *tau, F2Creal *work , F2Cinteger *lwork, F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgelqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sgelqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgelqf] */ // extern int dgelqf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgelqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgelqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgelqf] */ // int cgelqf_( F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgelqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cgelqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgelqf] */ // extern int zgelqf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgelqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zgelqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgelqf] */ /* ****** ****** */ /* ** ormlq: S, D & unmlq: C, Z */ /* Subroutine */ extern int sormlq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *c, F2Cinteger *ldc , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sormlq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sormlq_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_sormlq] */ // extern int dormlq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *c, F2Cinteger *ldc , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dormlq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dormlq_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_dormlq] */ // /* Subroutine */ extern int cunmlq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *c__, F2Cinteger *ldc , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cunmlq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cunmlq_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_cunmlq] */ // extern int zunmlq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *c__, F2Cinteger *ldc , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zunmlq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zunmlq_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_zunmlq] */ /* ****** ****** */ /* ** geqlf: S, D, C, Z */ extern int sgeqlf_( F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgeqlf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sgeqlf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgeqlf] */ // extern int dgeqlf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgeqlf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgeqlf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgeqlf] */ // extern int cgeqlf_( F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgeqlf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cgeqlf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgeqlf] */ // extern int zgeqlf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgeqlf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zgeqlf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgeqlf] */ /* ****** ****** */ /* ** ormql: S, D and unmql: C, Z */ /* Subroutine */ extern int sormql_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *c, F2Cinteger *ldc , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sormql ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sormql_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_sormql] */ // extern int dormql_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *c, F2Cinteger *ldc , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dormql ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dormql_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_dormql] */ /* Subroutine */ extern int cunmql_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *c__, F2Cinteger *ldc , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cunmql ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cunmql_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_cunmql] */ // extern int zunmql_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *c__, F2Cinteger *ldc , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zunmql ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zunmql_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_zunmql] */ /* ****** ****** */ /* ** geqrf: S, D, C, Z */ extern int sgeqrf_( F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgeqrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sgeqrf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgeqrf] */ // extern int dgeqrf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgeqrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgeqrf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgeqrf] */ // extern int cgeqrf_( F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgeqrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cgeqrf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgeqrf] */ // extern int zgeqrf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgeqrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zgeqrf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgeqrf] */ /* ****** ****** */ /* ** ormqr: S, D and unmqr: C, Z */ /* Subroutine */ extern int sormqr_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *c, F2Cinteger *ldc , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sormqr ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; char transp = trans; if (transp == 'C' || transp == 'c') transp = 'T'; sormqr_( &side, &transp, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_sormqr] */ // extern int dormqr_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *c, F2Cinteger *ldc , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dormqr ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; char transp = trans; if (transp == 'C' || transp == 'c') transp = 'T'; dormqr_( &side, &transp, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_dormqr] */ // /* Subroutine */ extern int cunmqr_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *c__, F2Cinteger *ldc , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cunmqr ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cunmqr_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_cunmqr] */ // extern int zunmqr_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *c__, F2Cinteger *ldc , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zunmqr ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zunmqr_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_zunmqr] */ /* ****** ****** */ /* ** gerqf: S, D, C, Z */ extern int sgerqf_( F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *tau, F2Creal *work , F2Cinteger *lwork, F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgerqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sgerqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgerqf] */ // extern int dgerqf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgerqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgerqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgerqf] */ // int cgerqf_( F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgerqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cgerqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgerqf] */ // extern int zgerqf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgerqf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zgerqf_(&m, &n, a, &lda, tau, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgerqf] */ /* ****** ****** */ /* ** unmrq: C, Z */ /* Subroutine */ extern int cunmrq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *tau , F2Ccomplex *c__, F2Cinteger *ldc , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cunmrq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cunmrq_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_cunmrq] */ // extern int zunmrq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *tau , F2Cdoublecomplex *c__, F2Cinteger *ldc , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zunmrq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c__, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zunmrq_( &side, &trans, &m, &n, &k, a, &lda, tau, c__, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_zunmrq] */ /* Subroutine */ extern int sormrq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Creal *a, F2Cinteger *lda , F2Creal *tau , F2Creal *c, F2Cinteger *ldc , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sormrq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sormrq_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_sormrq] */ // extern int dormrq_( char *side, char *trans , F2Cinteger *m, F2Cinteger *n, F2Cinteger *k , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *tau , F2Cdoublereal *c, F2Cinteger *ldc , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dormrq ( ats_char_type side , ats_char_type trans , F2Cinteger m, F2Cinteger n, F2Cinteger k , ats_ref_type a, F2Cinteger lda , ats_ref_type tau , ats_ref_type c, F2Cinteger ldc , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dormrq_( &side, &trans, &m, &n, &k, a, &lda, tau, c, &ldc, work, &lwork, &info ) ; return info ; } /* end of [atsctrb_clapack_dormrq] */ /* ****** ****** */ // gels: S, D, C, Z extern int sgels_( char *trans , F2Cinteger *m, F2Cinteger *n , F2Cinteger *nrhs , F2Creal *a, F2Cinteger *lda , F2Creal *b, F2Cinteger *ldb , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgels ( ats_char_type trans , F2Cinteger m, F2Cinteger n , F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; sgels_(&trans, &m, &n, &nrhs, a, &lda, b, &ldb, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgels] */ // /* Subroutine */ extern int dgels_( char *trans , F2Cinteger *m, F2Cinteger *n , F2Cinteger *nrhs , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *b, F2Cinteger *ldb , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgels ( ats_char_type trans , F2Cinteger m, F2Cinteger n , F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgels_(&trans, &m, &n, &nrhs, a, &lda, b, &ldb, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgels] */ // extern int cgels_( char *trans , F2Cinteger *m, F2Cinteger *n , F2Cinteger *nrhs , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *b, F2Cinteger *ldb , F2Ccomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgels ( ats_char_type trans , F2Cinteger m, F2Cinteger n , F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; cgels_(&trans, &m, &n, &nrhs, a, &lda, b, &ldb, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgels] */ // extern int zgels_( char *trans , F2Cinteger *m, F2Cinteger *n , F2Cinteger *nrhs , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *b, F2Cinteger *ldb , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgels ( ats_char_type trans , F2Cinteger m, F2Cinteger n , F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; zgels_(&trans, &m, &n, &nrhs, a, &lda, b, &ldb, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgels] */ /* ****** ****** */ // trtrs: S, D, C, Z extern int strtrs_( char *uplo , char *trans , char *diag , F2Cinteger *n , F2Cinteger *nrhs , F2Creal *a, F2Cinteger *lda , F2Creal *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_strtrs ( ats_char_type uplo , ats_char_type trans , ats_char_type diag , F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; strtrs_(&uplo, &trans, &diag, &n, &nrhs, a, &lda, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_strtrs] */ // extern int dtrtrs_( char *uplo , char *trans , char *diag , F2Cinteger *n , F2Cinteger *nrhs , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dtrtrs ( ats_char_type uplo , ats_char_type trans , ats_char_type diag , F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; dtrtrs_(&uplo, &trans, &diag, &n, &nrhs, a, &lda, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_dtrtrs] */ // extern int ctrtrs_( char *uplo , char *trans , char *diag , F2Cinteger *n , F2Cinteger *nrhs , F2Ccomplex *a, F2Cinteger *lda , F2Ccomplex *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_ctrtrs ( ats_char_type uplo , ats_char_type trans , ats_char_type diag , F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; ctrtrs_(&uplo, &trans, &diag, &n, &nrhs, a, &lda, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_ctrtrs] */ // extern int ztrtrs_( char *uplo , char *trans , char *diag , F2Cinteger *n , F2Cinteger *nrhs , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublecomplex *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_ztrtrs ( ats_char_type uplo , ats_char_type trans , ats_char_type diag , F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; ztrtrs_(&uplo, &trans, &diag, &n, &nrhs, a, &lda, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_ztrtrs] */ /* ****** ****** */ // getrf: S, D, C, Z extern int sgetrf_( F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgetrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv ) { F2Cinteger info ; sgetrf_(&m, &n, a, &lda, ipiv, &info) ; return info ; } /* end of [atsctrb_clapack_sgetrf] */ // extern int dgetrf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgetrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv ) { F2Cinteger info ; dgetrf_(&m, &n, a, &lda, ipiv, &info) ; return info ; } /* end of [atsctrb_clapack_dgetrf] */ // extern int cgetrf_( F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgetrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv ) { F2Cinteger info ; cgetrf_(&m, &n, a, &lda, ipiv, &info) ; return info ; } /* end of [atsctrb_clapack_cgetrf] */ // extern int zgetrf_( F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgetrf ( F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv ) { F2Cinteger info ; zgetrf_(&m, &n, a, &lda, ipiv, &info) ; return info ; } /* end of [atsctrb_clapack_zgetrf] */ /* ****** ****** */ // gesv: S, D, C, Z /* Subroutine */ extern int dgesv_ ( F2Cinteger *n, F2Cinteger *nrhs , F2Cdoublereal *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cdoublereal *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgesv ( F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; dgesv_ (&n, &nrhs, a, &lda, ipiv, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_dgesv] */ /* Subroutine */ extern int sgesv_ ( F2Cinteger *n, F2Cinteger *nrhs , F2Creal *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Creal *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgesv ( F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; sgesv_ (&n, &nrhs, a, &lda, ipiv, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_sgesv] */ /* Subroutine */ extern int cgesv_ ( F2Cinteger *n, F2Cinteger *nrhs , F2Ccomplex *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Ccomplex *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgesv ( F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; cgesv_ (&n, &nrhs, a, &lda, ipiv, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_cgesv] */ /* Subroutine */ extern int zgesv_ ( F2Cinteger *n, F2Cinteger *nrhs , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cinteger *ipiv , F2Cdoublecomplex *b, F2Cinteger *ldb , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgesv ( F2Cinteger n, F2Cinteger nrhs , ats_ref_type a, F2Cinteger lda , ats_ref_type ipiv , ats_ref_type b, F2Cinteger ldb ) { F2Cinteger info ; zgesv_ (&n, &nrhs, a, &lda, ipiv, b, &ldb, &info) ; return info ; } /* end of [atsctrb_clapack_zgesv] */ /* ****** ****** */ // gesvd: S, D, C, Z /* Subroutine */ extern int sgesvd_( char *jobu, char *jobvt , F2Cinteger *m, F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Creal *s , F2Creal *u, F2Cinteger *ldu , F2Creal *vt, F2Cinteger *ldvt , F2Creal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_sgesvd ( char jobu, char jobvt , F2Cinteger m, F2Cinteger n , ats_ptr_type a, F2Cinteger lda , ats_ptr_type s , ats_ptr_type u, F2Cinteger ldu , ats_ptr_type vt, F2Cinteger ldvt , ats_ptr_type work, F2Cinteger lwork ) { F2Cinteger info ; sgesvd_ (&jobu, &jobvt, &m, &n, a, &lda, s, u, &ldu, vt, &ldvt, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_sgesvd] */ /* Subroutine */ extern int dgesvd_( char *jobu, char *jobvt , F2Cinteger *m, F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cdoublereal *s , F2Cdoublereal *u, F2Cinteger *ldu , F2Cdoublereal *vt, F2Cinteger *ldvt , F2Cdoublereal *work, F2Cinteger *lwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_dgesvd ( char jobu, char jobvt , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type s , ats_ref_type u, F2Cinteger ldu , ats_ref_type vt, F2Cinteger ldvt , ats_ref_type work, F2Cinteger lwork ) { F2Cinteger info ; dgesvd_ (&jobu, &jobvt, &m, &n, a, &lda, s, u, &ldu, vt, &ldvt, work, &lwork, &info) ; return info ; } /* end of [atsctrb_clapack_dgesvd] */ /* Subroutine */ extern int cgesvd_( char *jobu, char *jobvt , F2Cinteger *m, F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Creal *s , F2Ccomplex *u, F2Cinteger *ldu , F2Ccomplex *vt, F2Cinteger *ldvt , F2Ccomplex *work, F2Cinteger *lwork , F2Creal *rwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_cgesvd ( char jobu, char jobvt , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type s , ats_ref_type u, F2Cinteger ldu , ats_ref_type vt, F2Cinteger ldvt , ats_ref_type work, F2Cinteger lwork , ats_ref_type rwork ) { F2Cinteger info ; cgesvd_ (&jobu, &jobvt, &m, &n, a, &lda, s, u, &ldu, vt, &ldvt, work, &lwork, rwork, &info) ; return info ; } /* end of [atsctrb_clapack_cgesvd] */ /* Subroutine */ extern int zgesvd_( char *jobu, char *jobvt , F2Cinteger *m, F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cdoublereal *s , F2Cdoublecomplex *u, F2Cinteger *ldu , F2Cdoublecomplex *vt, F2Cinteger *ldvt , F2Cdoublecomplex *work, F2Cinteger *lwork , F2Cdoublereal *rwork , F2Cinteger *info ) ; ATSinline() ats_int_type atsctrb_clapack_zgesvd ( char jobu, char jobvt , F2Cinteger m, F2Cinteger n , ats_ref_type a, F2Cinteger lda , ats_ref_type s , ats_ref_type u, F2Cinteger ldu , ats_ref_type vt, F2Cinteger ldvt , ats_ref_type work, F2Cinteger lwork , ats_ref_type rwork ) { F2Cinteger info ; zgesvd_ (&jobu, &jobvt, &m, &n, a, &lda, s, u, &ldu, vt, &ldvt, work, &lwork, rwork, &info) ; return info ; } /* end of [atsctrb_clapack_zgesvd] */ /* ****** ****** */ /* Subroutine */ extern int slaswp_ ( F2Cinteger *n , F2Creal *a, F2Cinteger *lda , F2Cinteger *k1, F2Cinteger *k2 , F2Cinteger *ipiv , F2Cinteger *incx ) ; ATSinline() ats_void_type atsctrb_clapack_slaswp ( F2Cinteger n , ats_ref_type a, F2Cinteger lda , F2Cinteger k1, F2Cinteger k2 , ats_ref_type ipiv , F2Cinteger incx ) { slaswp_ (&n, a, &lda, &k1, &k2, ipiv, &incx) ; return ; } /* Subroutine */ extern int dlaswp_ ( F2Cinteger *n , F2Cdoublereal *a, F2Cinteger *lda , F2Cinteger *k1, F2Cinteger *k2 , F2Cinteger *ipiv , F2Cinteger *incx ) ; ATSinline() ats_void_type atsctrb_clapack_dlaswp ( F2Cinteger n , ats_ref_type a, F2Cinteger lda , F2Cinteger k1, F2Cinteger k2 , ats_ref_type ipiv , F2Cinteger incx ) { dlaswp_ (&n, a, &lda, &k1, &k2, ipiv, &incx) ; return ; } /* Subroutine */ extern int claswp_ ( F2Cinteger *n , F2Ccomplex *a, F2Cinteger *lda , F2Cinteger *k1, F2Cinteger *k2 , F2Cinteger *ipiv , F2Cinteger *incx ) ; ATSinline() ats_void_type atsctrb_clapack_claswp ( F2Cinteger n , ats_ref_type a, F2Cinteger lda , F2Cinteger k1, F2Cinteger k2 , ats_ref_type ipiv , F2Cinteger incx ) { claswp_ (&n, a, &lda, &k1, &k2, ipiv, &incx) ; return ; } /* Subroutine */ extern int zlaswp_ ( F2Cinteger *n , F2Cdoublecomplex *a, F2Cinteger *lda , F2Cinteger *k1, F2Cinteger *k2 , F2Cinteger *ipiv , F2Cinteger *incx ) ; ATSinline() ats_void_type atsctrb_clapack_zlaswp ( F2Cinteger n , ats_ref_type a, F2Cinteger lda , F2Cinteger k1, F2Cinteger k2 , ats_ref_type ipiv , F2Cinteger incx ) { zlaswp_ (&n, a, &lda, &k1, &k2, ipiv, &incx) ; return ; } /* ****** ****** */ #endif /* [ATS_CONTRIB_CLAPACK_CATS] */ /* end of [clapack.cats] */ ats-lang-anairiats-0.2.11/contrib/clapack/TEST/0000700000175000017500000000000012223166165017601 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/TEST/Makefile0000664000175000017500000000163012223166165021255 0ustar hwxihwxi# # # Makefile for some BLAS testing code # # ###### ATSUSRQ="$(ATSHOME)" ATSLIBQ="$(ATSHOME)" ifeq ("$(ATSHOME)","") ATSUSRQ="/usr" ATSLIBQ="/usr/lib/ats-anairiats-0.2.3" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt LIBFLAGS=-L/usr/lib/atlas -L/usr/lib64/atlas ATSCTRB=\ $(ATSLIBQ)/contrib/cblas/atsctrb_cblas.o \ $(ATSLIBQ)/contrib/clapack/atsctrb_clapack.o \ ###### .PHONY: all # ###### all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: test_clapack test_clapack: test_clapack.dats $(ATSCC) $(LIBFLAGS) -O3 -o $@ $< $(ATSCTRB) -llapack -lblas \ && ./test_clapack cleanall:: ; $(RMF) test_clapack ###### html:: ; $(ATSOPT) --posmark_html -d test_clapack.dats > test_clapack_dats.html cleanall:: ; $(RMF) test_clapack_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/clapack/TEST/test_clapack.dats0000664000175000017500000017345612223166165023147 0ustar hwxihwxi(* ** ** An interface for ATS to interact with LAPACK ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) local #include "prelude/HATS/number.hats" in (*empty*) end local #include "contrib/clapack/HATS/f2c.hats" in (*empty*) end local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end local #include "contrib/clapack/HATS/clapack.hats" in (*empty*) end (* ****** ****** *) staload NUM = "prelude/SATS/number.sats" fn{a:t@ype} of_int (i:int):<> a = $NUM.of_int (i) (* ****** ****** *) staload F2C = "contrib/clapack/SATS/f2c.sats" typedef integer = $F2C.integer macdef lint_of_integer = $F2C.lint_of_integer macdef integer_of_int1 = $F2C.integer_of_int1 macdef size1_of_integer = $F2C.size1_of_integer fn{a:t@ype} print_typ (): void = $F2C.print_typ () fn{a:t@ype} print_elt (x: a): void = $F2C.print_elt (x) (* ****** ****** *) staload M = "libc/SATS/math.sats" staload C = "libc/SATS/complex.sats" (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) typedef real = $F2C.real typedef doublereal = $F2C.doublereal typedef complex = $F2C.complex typedef doublecomplex = $F2C.doublecomplex (* ****** ****** *) #define i2sz size1_of_int1 #define sz2i int1_of_size1 (* ****** ****** *) fn srandgen_elt (): real = let val x = drand48 () in $F2C.real_of_float (float_of_double x) end // end of [srandgen_elt] fn drandgen_elt (): doublereal = $F2C.doublereal_of_double (drand48 ()) fn crandgen_elt (): complex = let val x = drand48 () and y = drand48 () val x = float_of_double x and y = float_of_double y in $F2C.complex_of_ccmplx ($C.ccmplx_make_cart (x, y)) end // end of [crandgen_elt] fn zrandgen_elt (): doublecomplex = let val x = drand48 () and y = drand48 () in $F2C.doublecomplex_of_zcmplx ($C.zcmplx_make_cart (x, y)) end // end of [zrandgen_elt] (* ****** ****** *) extern fun{t:t@ype} randgen_elt (): t implement randgen_elt () = srandgen_elt () implement randgen_elt () = drandgen_elt () implement randgen_elt () = crandgen_elt () implement randgen_elt () = zrandgen_elt () (* ****** ****** *) staload "libats/SATS/fmatrix.sats" staload _(*anonymous*) = "libats/DATS/fmatrix.dats" staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" staload "contrib/cblas/SATS/cblas_extra.sats" staload _(*anonymous*) = "contrib/cblas/DATS/cblas_extra.dats" (* ****** ****** *) fun{t:t@ype} randgen_arr {n:nat} .<>. (n: int n) : [l:addr] ( free_gc_v (t?, n, l), array_v (t, n, l) | ptr l ) = let val tsz = sizeof val n_sz = size1_of_int1 (n) val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {t} (n_sz, tsz) // end of [val] // val () = array_ptr_initialize_fun (!p_arr, n_sz, f) where { val f = lam ( _: sizeLt n, x: &(t?) >> t ) : void = x := randgen_elt () // end of [val] } // end of [val] // in (pf_gc, pf_arr | p_arr) end // end of [rangen_arr] (* ****** ****** *) fun{t:t@ype} randgen_fmat {m,n:nat} (m: int m, n: int n) : [mn:int] [l:addr] ( free_gc_v (t?, mn, l) , MUL (m, n, mn) , fmatrix_v (t, m, n, l) | ptr l ) = let val (pf_mn | mn) = m imul2 n prval () = mul_nat_nat_nat (pf_mn) val (pf_gc, pf_arr | p_arr) = randgen_arr (mn) prval pf_fmat = fmatrix_v_of_array_v (pf_mn, pf_arr) in (pf_gc, pf_mn, pf_fmat | p_arr) end // end of [randgen_fmat] fn{a:t@ype} print_fmat {m,n:nat} ( M: &fmatrix (a, m, n), m: size_t m, n: size_t n ) : void = fmatrix_ptr_iforeach_fun (M, pr, ORDERrow, m, n) where { val pr = lam ( i: size_t, j: size_t, x: &a ) : void = $effmask_all let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // nothing end // end of [let] } // end of [fmatrix_ptr_iforeach_fun] // end of [print_fmat] (* ****** ****** *) fun{t:t@ype} randgen_gemat {m,n:nat} (m: int m, n: int n) : [mn:int] [l:addr] ( free_gc_v (t?, mn, l) , MUL (m, n, mn) , GEMAT_v (t, m, n, col, m, l) | ptr l ) = let val (pf_gc, pf_mn, pf_fmat | p_arr) = randgen_fmat (m, n) prval (pf_gmat, _) = GEMAT_v_of_fmatrix_v (pf_fmat) in (pf_gc, pf_mn, pf_gmat | p_arr) end // end of [randgen_gemat] fn{a:t@ype} print_gemat {ord:order} {m,n:nat} {lda:pos} ( ord: ORDER ord, M: &GEMAT (a, m, n, ord, lda) , m: size_t m, n: size_t n, lda: size_t lda ) : void = let val () = GEMAT_ptr_iforeach_fun (ord, M, pr, ORDERrow, m, n, lda) where { val pr = lam ( i: size_t, j: size_t, x: &a ) : void = $effmask_all let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // empty end // end of [val] } // end of [val] in // nothing end // end of [print_gemat] (* ****** ****** *) // // SC: Fill matrix with random FP numbers // fn{t:t@ype} GEMAT_rand {ord:order} {m,n:nat} {lda:pos} ( ord: ORDER ord, m: size_t m, n: size_t n , A: &GEMAT(t?, m, n, ord, lda) >> GEMAT (t, m, n, ord, lda) , lda: size_t lda ) : void = let // val f = lam ( i: sizeLt m, j: sizeLt n, x: &t? >> t ) : void =<> x := $effmask_ref (randgen_elt ()) // end of [val] // val () = GEMAT_ptr_initialize_fun (ord, A, m, n, lda, f) // in // nothing end // end of [GEMAT_rand] (* ****** ****** *) extern fun{a:t@ype} trcpy {ord:order} {ul:uplo} {dg:diag} {m:nat} {lda,ldb:inc} ( ord: ORDER ord , ul: UPLO ul, dg: DIAG dg, m: size_t m , A: &TRMAT (a, m, ord, ul, dg, lda), lda: size_t lda , B: &GEMAT (a, m, m, ord, ldb), ldb: size_t ldb ) :<> void // end of [trcpy] implement{a} trcpy {ord} {ul} {dg} {m} {lda,ldb} (ord, ul, dg, m, A, lda, B, ldb) = let prval (pfb_trm, fpfb) = TRMAT_v_of_GEMAT_v (view@ B, ul, dg) val () = TRMAT_ptr_copy (ord, ul, dg, A, B, m, lda, ldb) prval () = view@ B := fpfb (pfb_trm) fun loop {i:nat | i <= m} .. (B: &GEMAT (a, m, m, ord, ldb), i: size_t i, _1: a): void = if i < m then begin GEMAT_ptr_set_elt_at (ord, B, ldb, i, i, _1); loop (B, i+1, _1) end // end of [if] // end of [loop] val () = case+ dg of | DIAGunit () => loop (B, 0, of_int 1) | DIAGnonunit () => () // end of [val] in // nothing end // end of [trcpy] (* ****** ****** *) staload "contrib/clapack/SATS/clapack.sats" staload _(*anonymous*) = "contrib/clapack/DATS/clapack.dats" (* ****** ****** *) // // Part I // (* ****** ****** *) extern fun{t,tr:t@ype} lange_lacpy_test (): void implement{t,tr} lange_lacpy_test () = () where { #define M 20 #define M2 %(M/2) #define N 13 // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {t} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf11_gem, pf12_gem, fpf1_gem | p11, p12) = GEMAT_ptr_split2x1 (pf1_gem | ORDERcol, p1_arr, M, M2) (* end of [val] *) // val m = integer_of_int1 (M) val n = integer_of_int1 (N) val m2 = integer_of_int1 (M2) var !p_work with pf_work = @[tr?][M2]() // val NMinf11 = lange_inf (m2, n, !p11, m, !p_work) // val () = (print "NMinf11 = "; print_elt NMinf11; print_newline ()) val NMfro11 = lange_frob (m2, n, !p11, m) // val () = (print "NMfro11 = "; print_elt NMfro11; print_newline ()) // val () = lacpy {M2,N} (ClapackULN_U, m2, n, !p11, m, !p12, m) val () = lacpy {M2,N} (ClapackULN_L, m2, n, !p11, m, !p12, m) // val NMinf12 = lange_inf (m2, n, !p12, m, !p_work) // val () = (print "NMinf12 = "; print_elt NMinf12; print_newline ()) val NMfro12 = lange_frob (m2, n, !p12, m) // val () = (print "NMfro12 = "; print_elt NMfro12; print_newline ()) // val sfmin = lamch ('S') val () = assert_errmsg_bool ((NMinf11 \$F2C.sub NMinf12) \$F2C.lte sfmin, #LOCATION) val () = assert_errmsg_bool ((NMfro11 \$F2C.sub NMfro12) \$F2C.lte sfmin, #LOCATION) // prval () = pf1_gem := fpf1_gem (pf11_gem, pf12_gem) prval () = pf1_fmat := fpf1_fmat (pf1_gem) // (* val () = print "M =\n" val () = print_fmat (!p1_arr, M, N) val () = print_newline () *) // prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // } // end of [lange_lacpy_test] (* ****** ****** *) fn{a:t@ype} macheps_get ():<> a = let val _1 = $NUM.of_double 1.0 val _2 = $NUM.of_double 2.0 fun guess (x: a): a = if $F2C.eq (_1, x \$F2C.add _1) then x else guess (x \$F2C.div _2) (* end of [guess] *) in $effmask_ntm (guess _1) end // end of [machine_eps] val macheps_float = macheps_get () val macheps_double = macheps_get () (* ****** ****** *) // gels & gels_work_query test extern fun{t,tr:t@ype} gels_test (): void implement{t,tr} gels_test () = () where { #define M 30 #define N 10 #define NRHS 2 val () = assert_prerrf_bool1 ( M >= N, "%s: test works only for LS problems\n", @(#LOCATION) ) // end of [val] // Make A val (pf_MN | MN) = M imul2 N prval () = mul_nat_nat_nat (pf_MN) val (pf_gc_A, pf_arr_A | p_A) = randgen_arr (MN) prval pf_fmat_A = fmatrix_v_of_array_v (pf_MN, pf_arr_A) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make X val (pf_NNRHS | NNRHS) = N imul2 NRHS prval () = mul_nat_nat_nat (pf_NNRHS) val (pf_gc_X, pf_arr_X | p_X) = randgen_arr (NNRHS) prval pf_fmat_X = fmatrix_v_of_array_v (pf_NNRHS, pf_arr_X) prval (pf_gmat_X, fpf_fmat_X) = GEMAT_v_of_fmatrix_v (pf_fmat_X) // Make B val (pf_MNRHS | MNRHS) = M imul2 NRHS prval () = mul_nat_nat_nat (pf_MNRHS) val MNRHS_sz = size1_of_int1 MNRHS val (pf_gc_B, pf_arr_B | p_B) = array_ptr_alloc (MNRHS_sz) val () = array_ptr_initialize_elt (!p_B, MNRHS_sz, of_int 1) prval pf_fmat_B = fmatrix_v_of_array_v (pf_MNRHS, pf_arr_B) prval (pf_gmat_B, fpf_fmat_B) = GEMAT_v_of_fmatrix_v (pf_fmat_B) // B <- A * X val () = cblas_gemm {col} {TPN, TPN} ( TRANDIM_N (), TRANDIM_N () // match dimensions after transposition | CblasColMajor , CblasNoTrans // For A , CblasNoTrans // For X , M, NRHS, N , of_int 1 , !p_A, M , !p_X, N , of_int 0 , !p_B, M ) // [cblas_gemm] val M_ = integer_of_int1 (M) val N_ = integer_of_int1 (N) val NRHS_ = integer_of_int1 NRHS // Setup gels val (pf_lwork | lwork) = gels_work_query (ClapackNoTrans, M_, N_, NRHS_) (* val lwork1 = lint_of_integer lwork val lwork1 = ulint_of_lint (lwork1) val () = begin printf ("lwork = %lu\n", @(lwork1)); printf ("lwork = 0x%lx\n", @(lwork1)); end // end of [val] *) val (pf_gc_work, pf_arr_work | p_work) = array_ptr_alloc (size1_of_integer lwork) // Solve for X (inside B after gels) val info = gels ( pf_lwork | ClapackNoTrans , M_, N_, NRHS_, !p_A, M_, !p_B, M_ , !p_work, lwork ) val () = assert_prerrf_bool (info = 0, "%s: gels failed: info = %i\n", @(#LOCATION, info)) // Free work val () = array_ptr_free (pf_gc_work, pf_arr_work | p_work) // Split B = [B1; B2] = [X; res] val (pf_gmat_B1, pf_gmat_B2, fpf_gmat_B | p_B1, p_B2) = GEMAT_ptr_split2x1 (pf_gmat_B | ORDERcol, p_B, M, N) // X <- X - B val () = GEMAT_axpy (ORDERcol, N, NRHS, of_int (~1), !p_B1, M, !p_X, N) // norm (X - B) val err = lange_one (N_, NRHS_, !p_X, N_) // check val mach_eps = lamch_eps () val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (mach_eps, of_int (M * (N + NRHS)))) val () = assert_prerrf_bool (isbig, "%s: gels LS solve failed", @(#LOCATION)) // Unsplit B prval pf_gmat_B = fpf_gmat_B (pf_gmat_B1, pf_gmat_B2) // Free B prval pf_fmat_B = fpf_fmat_B (pf_gmat_B) prval (pf2_MNRHS, pf_arr_B) = array_v_of_fmatrix_v (pf_fmat_B) prval () = mul_isfun (pf_MNRHS, pf2_MNRHS) val () = array_ptr_free (pf_gc_B, pf_arr_B | p_B) // Free X prval pf_fmat_X = fpf_fmat_X (pf_gmat_X) prval (pf2_NNRHS, pf_arr_X) = array_v_of_fmatrix_v (pf_fmat_X) prval () = mul_isfun (pf_NNRHS, pf2_NNRHS) val () = array_ptr_free (pf_gc_X, pf_arr_X | p_X) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) prval (pf2_MN, pf_arr_A) = array_v_of_fmatrix_v (pf_fmat_A) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf_gc_A, pf_arr_A | p_A) } // end of [gels_test] // // Separate test for fat systems // extern fun{t,tr:t@ype} gels_test_minnorm (): void implement{t,tr} gels_test_minnorm () = () where { #define M 10 #define N 30 #define NRHS 2 val () = assert_prerrf_bool1 ( M <= N, "%s: test works only for MN problems\n", @(#LOCATION) ) // end of [val] // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Z val (pf_gc_Z, pf_MNRHS, pf_fmat_Z | p_Z) = randgen_fmat (M, NRHS) prval () = mul_nat_nat_nat (pf_MNRHS) prval (pf_gmat_Z, fpf_fmat_Z) = GEMAT_v_of_fmatrix_v (pf_fmat_Z) // Make X = A^T * Z val (pf_gc_X, pf_NNRHS, pf_fmat_X | p_X) = fmatrix_ptr_alloc (N, NRHS) val () = fmatrix_ptr_initialize_elt (!p_X, N, NRHS, of_int 0) // cannot be skipped: 0 * NAN = NAN; 0 * INF = NAN prval (pf_gmat_X, fpf_fmat_X) = GEMAT_v_of_fmatrix_v (pf_fmat_X) val () = cblas_gemm ( TRANDIM_C () , TRANDIM_N () | CblasColMajor , CblasConjTrans , CblasNoTrans , N, NRHS, M , of_int 1 , !p_A, M , !p_Z, M , of_int 0 , !p_X, N ) // Free Z prval pf_fmat_Z = fpf_fmat_Z (pf_gmat_Z) val () = fmatrix_ptr_free (pf_gc_Z, pf_MNRHS, pf_fmat_Z | p_Z) // Make B = [B1; B2] (larger than needed to hold X; B1 = B) val (pf_gc_B, pf2_NNRHS, pf_fmat_B | p_B) = fmatrix_ptr_alloc (N, NRHS) val () = fmatrix_ptr_initialize_elt (!p_B, N, NRHS, of_int 0) prval (pf_gmat_B, fpf_fmat_B) = GEMAT_v_of_fmatrix_v (pf_fmat_B) val (pf_gmat_B1, pf_gmat_B2, fpf_gmat_B | p_B1, p_B2) = GEMAT_ptr_split2x1 (pf_gmat_B | ORDERcol, p_B, N, M) // B1 <- A * X val () = cblas_gemm {col} {TPN, TPN} ( TRANDIM_N (), TRANDIM_N () // match dimensions after transposition | CblasColMajor , CblasNoTrans // For A , CblasNoTrans // For X , M, NRHS, N , of_int 1 , !p_A, M , !p_X, N , of_int 0 , !p_B1, N ) // [cblas_gemm] // Unsplit B to pass to gels prval pf_gmat_B = fpf_gmat_B (pf_gmat_B1, pf_gmat_B2) // Setup gels val M_ = integer_of_int1 (M) val N_ = integer_of_int1 (N) val NRHS_ = integer_of_int1 NRHS val (pf_lwork | lwork) = gels_work_query (ClapackNoTrans, M_, N_, NRHS_) (* val lwork1 = lint_of_integer lwork val lwork1 = ulint_of_lint (lwork1) val () = begin printf ("lwork = %lu\n", @(lwork1)); printf ("lwork = 0x%lx\n", @(lwork1)); end // end of [val] *) val (pf_gc_work, pf_arr_work | p_work) = array_ptr_alloc (size1_of_integer lwork) // Solve for X (inside B after gels) val info = gels ( pf_lwork | ClapackNoTrans , M_, N_, NRHS_, !p_A, M_, !p_B, N_ , !p_work, lwork ) // end of [val] val () = assert_prerrf_bool (info = 0, "%s: gels failed: info = %i\n", @(#LOCATION, info)) // Free work val () = array_ptr_free (pf_gc_work, pf_arr_work | p_work) // X <- X - B val () = GEMAT_axpy (ORDERcol, N, NRHS, of_int (~1), !p_B, N, !p_X, N) // norm (X - B) val err = lange_one (N_, NRHS_, !p_X, N_) // check val mach_eps = macheps_get () // lamch_eps () (* val () = begin print "mach_eps = "; print_elt mach_eps; print " gels_MN err = "; print_elt ($F2C.div (err, mach_eps)); print_newline () end // end of [val] *) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (mach_eps, of_int (20 * M * (N + NRHS)))) val () = assert_prerrf_bool (isbig, "%s: gels MN solve failed", @(#LOCATION)) // Free B prval pf_fmat_B = fpf_fmat_B (pf_gmat_B) val () = fmatrix_ptr_free (pf_gc_B, pf2_NNRHS, pf_fmat_B | p_B) // Free X prval pf_fmat_X = fpf_fmat_X (pf_gmat_X) val () = fmatrix_ptr_free (pf_gc_X, pf_NNRHS, pf_fmat_X | p_X) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gels_test_minnorm] (* ****** ****** *) // gesv: S, D, C, Z extern fun{t,tr:t@ype} gesv_test (): void implement{t,tr} gesv_test () = () where { #define M 300 #define NRHS 2 (* val () = begin print "gesv_test<"; print_typ (); print ">: "; print_newline () end // end of [val] *) // Make A val (pf_MM | MM) = M imul2 M prval () = mul_nat_nat_nat (pf_MM) val (pf_gc_A, pf_arr_A | p_A) = randgen_arr (MM) prval pf_fmat_A = fmatrix_v_of_array_v (pf_MM, pf_arr_A) // Add M to diagonal to improve condition number // val () = fmatrix_ptr_iforeach_fun (!p_A, f, ORDERcol, M, M) where { val f = lam ( i: size_t, j: size_t, x: &t ) : void = if i = j then x := $F2C.add (x, of_int M) } // end of [val] // prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make X val (pf_MNRHS | MNRHS) = M imul2 NRHS prval () = mul_nat_nat_nat (pf_MNRHS) val (pf_gc_X, pf_arr_X | p_X) = randgen_arr (MNRHS) prval pf_fmat_X = fmatrix_v_of_array_v (pf_MNRHS, pf_arr_X) prval (pf_gmat_X, fpf_fmat_X) = GEMAT_v_of_fmatrix_v (pf_fmat_X) // Make B val MNRHS_sz = size1_of_int1 MNRHS val (pf_gc_B, pf_arr_B | p_B) = array_ptr_alloc (MNRHS_sz) val () = array_ptr_initialize_elt (!p_B, MNRHS_sz, of_int 1) prval pf_fmat_B = fmatrix_v_of_array_v (pf_MNRHS, pf_arr_B) prval (pf_gmat_B, fpf_fmat_B) = GEMAT_v_of_fmatrix_v (pf_fmat_B) // B <- A * X val () = cblas_gemm {col} {TPN, TPN} ( TRANDIM_N (), TRANDIM_N () // match dimensions after transposition | CblasColMajor , CblasNoTrans // For A , CblasNoTrans // For X , M, NRHS, M , of_int 1 , !p_A, M , !p_X, M , of_int 0 , !p_B, M ) // [cblas_gemm] // Set-up for gesv val (pf_gc_ipiv, pf_arr_ipiv | p_ipiv) = array_ptr_alloc (size1_of_int1 M) // Solve for X (inside B after gesv) val M_ = integer_of_int1 (M) val NRHS_ = integer_of_int1 NRHS val (pferr | info) = gesv (pf_gmat_A | M_, NRHS_, p_A, M_, !p_ipiv, !p_B, M_) val () = assert_prerrf_bool (info = 0, "%s: gesv failed: info = %i", @(#LOCATION, info)) val () = pf_gmat_A := LUMAT_err_v_elim (pferr) // Free ipiv val () = array_ptr_free (pf_gc_ipiv, pf_arr_ipiv | p_ipiv) // X <- X - B val () = GEMAT_axpy (ORDERcol, M, NRHS, of_int (~1), !p_B, M, !p_X, M) // norm (X - B) val err = lange_one (M_, NRHS_, !p_X, M_) // val () = (print ("error = "); print_elt (err); print_newline ()) // check val mach_eps = macheps_get () // lamch_eps () val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (mach_eps, of_int (2*NRHS*M*M))) val () = assert_prerrf_bool (isbig, "%s: [gesv] solve failed", @(#LOCATION)) // Free B prval pf_fmat_B = fpf_fmat_B (pf_gmat_B) prval (pf2_MNRHS, pf_arr_B) = array_v_of_fmatrix_v (pf_fmat_B) prval () = mul_isfun (pf_MNRHS, pf2_MNRHS) val () = array_ptr_free (pf_gc_B, pf_arr_B | p_B) // Free X prval pf_fmat_X = fpf_fmat_X (pf_gmat_X) prval (pf2_NNRHS, pf_arr_X) = array_v_of_fmatrix_v (pf_fmat_X) prval () = mul_isfun (pf_MNRHS, pf2_NNRHS) val () = array_ptr_free (pf_gc_X, pf_arr_X | p_X) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) prval (pf2_MM, pf_arr_A) = array_v_of_fmatrix_v (pf_fmat_A) prval () = mul_isfun (pf_MM, pf2_MM) val () = array_ptr_free (pf_gc_A, pf_arr_A | p_A) } // end of [gesv_test] (* ****** ****** *) // gesvd tests: S, D, C, Z with many variants extern fun{t,tr:t@ype} gesvd_test (): void implement{t,tr} gesvd_test () = () where { #define M 55 #define N 30 // (* val () = begin print "gesvd_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate U val (pf_gc_U, pf_MM, pf_fmat_U | p_U) = fmatrix_ptr_alloc (M, M) prval () = mul_nat_nat_nat (pf_MM) prval (pf_gmat_U, fpf_fmat_U) = GEMAT_v_of_fmatrix_v (pf_fmat_U) // Allocate S stavar mn : int val MN = min_size1_size1 (M, N) : size_t mn var !p_S = @[tr][MN]() // Allocate VT val (pf_gc_VT, pf_NN, pf_fmat_VT | p_VT) = fmatrix_ptr_alloc (N, N) prval () = mul_nat_nat_nat (pf_NN) prval (pf_gmat_VT, fpf_fmat_VT) = GEMAT_v_of_fmatrix_v (pf_fmat_VT) // Set-up workspace for SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Full SVD of A val info = gesvd ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_U, M_, !p_VT, N_, !p_work, lwork ) // end of [val] val () = (print "info = "; print info; print_newline ()) val () = assert_prerrf_bool (info = 0, "%s: gesvd failed: info = %i\n", @(#LOCATION, info)) // A <- U * S * VT val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_A, M, N, M, of_int 0) val () = if M <= N then let // U <- U * diag (S) val () = GEMAT_scal_col {col} {mn,mn} (ORDERcol, M, M, !p_U, M, !p_S) val (pf_gmat_VT1, pf_gmat_VT2, fpf_gmat_VT | p_VT1, p_VT2) = GEMAT_ptr_split1x2 (pf_gmat_VT | ORDERcol, p_VT, N, M(*min(M,N)*)) val () = cblas_gemm ( TRANDIM_N {M,M} (), TRANDIM_N () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, min(M,N) , of_int 1 , !p_U, M , !p_VT1, N , of_int 0 , !p_A, M ) // end of [val] prval () = pf_gmat_VT := fpf_gmat_VT (pf_gmat_VT1, pf_gmat_VT2) in // nothing end else let // VT <- diag(S) * VT val () = GEMAT_scal_row {col} {mn,mn} (ORDERcol, N, N, !p_S, !p_VT, N) val (pf_gmat_U1, pf_gmat_U2, fpf_gmat_U | p_U1, p_U2) = GEMAT_ptr_split1x2 (pf_gmat_U | ORDERcol, p_U, M, N(*min(M,N)*)) val () = cblas_gemm ( TRANDIM_N {M,mn} (), TRANDIM_N () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, min(M,N) , of_int 1 , !p_U1, M , !p_VT, N , of_int 0 , !p_A, M ) // end of [val] prval () = pf_gmat_U := fpf_gmat_U (pf_gmat_U1, pf_gmat_U2) in // nothing end (* end of [if] *) // Check ||Ac - A|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_A, M, !p_Ac, M) val err = lange_one (M_, N_, !p_Ac, M_) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M*N*min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_test failed\n", @(#LOCATION)) // Free VT prval pf_fmat_VT = fpf_fmat_VT (pf_gmat_VT) val () = fmatrix_ptr_free (pf_gc_VT, pf_NN, pf_fmat_VT | p_VT) // Free U prval pf_fmat_U = fpf_fmat_U (pf_gmat_U) val () = fmatrix_ptr_free (pf_gc_U, pf_MM, pf_fmat_U | p_U) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_test] (* ****** ****** *) // gesvd_econ test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_econ_test (): void implement{t,tr} gesvd_econ_test () = () where { #define M 55 #define N 30 // (* val () = begin print "gesvd_econ_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) val MN = min (M, N) val MN_sz = i2sz MN // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate U val (pf_gc_U, pf_MMN, pf_fmat_U | p_U) = fmatrix_ptr_alloc (M, MN_sz) prval () = mul_nat_nat_nat (pf_MMN) prval (pf_gmat_U, fpf_fmat_U) = GEMAT_v_of_fmatrix_v (pf_fmat_U) // Allocate S var !p_S = @[tr][MN]() // Allocate VT val (pf_gc_VT, pf_MNN, pf_fmat_VT | p_VT) = fmatrix_ptr_alloc (MN_sz, N) prval () = mul_nat_nat_nat (pf_MNN) prval (pf_gmat_VT, fpf_fmat_VT) = GEMAT_v_of_fmatrix_v (pf_fmat_VT) // Set-up workspace for SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_econ_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Economy SVD of A val info = gesvd_econ ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_U, M_, !p_VT, N_, !p_work, lwork ) // end of [val] val () = (print "info = "; print info; print_newline ()) val () = assert_prerrf_bool (info = 0, "%s: gesvd_econ failed: info = %i\n", @(#LOCATION, info)) // Prepare A val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_A, M, N, M, of_int 0) // U <- U * diag (S) val () = GEMAT_scal_col (ORDERcol, M, MN_sz, !p_U, M, !p_S) // A <- (U * S) * VT val () = cblas_gemm ( TRANDIM_N (), TRANDIM_N () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, MN , of_int 1 , !p_U, M , !p_VT, N , of_int 0 , !p_A, M ) // end of [val] // Check ||Ac - A|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_A, M, !p_Ac, M) val err = lange_one (M_, N_, !p_Ac, M_) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M*N*min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_econ_test failed\n", @(#LOCATION)) // Free VT prval pf_fmat_VT = fpf_fmat_VT (pf_gmat_VT) val () = fmatrix_ptr_free (pf_gc_VT, pf_MNN, pf_fmat_VT | p_VT) // Free U prval pf_fmat_U = fpf_fmat_U (pf_gmat_U) val () = fmatrix_ptr_free (pf_gc_U, pf_MMN, pf_fmat_U | p_U) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_econ_test] (* ****** ****** *) // gesvd_sing test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_sing_test (): void implement{t,tr} gesvd_sing_test () = () where { #define M 55 #define N 30 // (* val () = begin print "gesvd_sing_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) val MN = min (M, N) val MN_sz = i2sz (MN) // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate U val (pf_gc_U, pf_MMN, pf_fmat_U | p_U) = fmatrix_ptr_alloc (M, MN_sz) prval () = mul_nat_nat_nat (pf_MMN) prval (pf_gmat_U, fpf_fmat_U) = GEMAT_v_of_fmatrix_v (pf_fmat_U) // Allocate S and Sc var !p_S with pfS_arr = @[tr][MN_sz]() var !p_Sc with pfSc_arr = @[tr][MN_sz]() // Allocate VT val (pf_gc_VT, pf_MNN, pf_fmat_VT | p_VT) = fmatrix_ptr_alloc (MN_sz, N) prval () = mul_nat_nat_nat (pf_MNN) prval (pf_gmat_VT, fpf_fmat_VT) = GEMAT_v_of_fmatrix_v (pf_fmat_VT) // Set-up workspace for singular values SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_sing_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Singular values of A val info = gesvd_sing ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_work, lwork ) // end of [val] val () = begin print "info = "; print info; print_newline (); end // end of [va] val () = assert_prerrf_bool (info = 0, "%s: gesvd_sing failed: info = %i\n", @(#LOCATION, info)) // Set-up workspace for economy SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_econ_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Economy SVD of Ac val info = gesvd_econ ( pf_lwork | M_, N_, !p_Ac, M_, !p_Sc, !p_U, M_, !p_VT, N_, !p_work, lwork ) // end of [val] val () = (print "info = "; print info; print_newline ()) val () = assert_prerrf_bool (info = 0, "%s: gesvd_econ failed: info = %i\n", @(#LOCATION, info)) // Check ||Sc - S|| prval pfS_gvec = GEVEC_v_of_array_v (pfS_arr) prval pfSc_gvec = GEVEC_v_of_array_v (pfSc_arr) val () = cblas_axpy (MN, of_int (~1), !p_S, 1, !p_Sc, 1) val err = cblas_asum (MN, !p_Sc, 1) prval () = pfS_arr := array_v_of_GEVEC_v (pfS_gvec) prval () = pfSc_arr := array_v_of_GEVEC_v (pfSc_gvec) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_sing_test failed\n", @(#LOCATION)) // Free VT prval pf_fmat_VT = fpf_fmat_VT (pf_gmat_VT) val () = fmatrix_ptr_free (pf_gc_VT, pf_MNN, pf_fmat_VT | p_VT) // Free U prval pf_fmat_U = fpf_fmat_U (pf_gmat_U) val () = fmatrix_ptr_free (pf_gc_U, pf_MMN, pf_fmat_U | p_U) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_sing_test] (* ****** ****** *) // gesvd_left test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_left_test (): void implement{t,tr} gesvd_left_test () = () where { #define M 55 #define N 30 val () = assert_prerrf_bool (M >= N , "%s: gesvd_left only for skinny matrices", @(#LOCATION) ) // end of [val] // (* val () = begin print "gesvd_left_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate S and Sc stavar n : int val Nz = min_size1_size1 (M, N) : size_t n // cannot remove var !p_S with pfS_arr = @[tr][Nz]() var !p_Sc with pfSc_arr = @[tr][Nz]() // Set-up workspace for left SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_left_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Left SVD of A val info = gesvd_left {M,n} ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_work, lwork ) val () = begin print "info = "; print info; print_newline (); end val () = assert_prerrf_bool (info = 0, "%s: gesvd_left failed: info = %i\n", @(#LOCATION, info)) // Set-up workspace for singular values SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_sing_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Singular values of Ac val info = gesvd_sing ( pf_lwork | M_, N_, !p_Ac, M_, !p_Sc, !p_work, lwork ) val () = begin print "info = "; print info; print_newline (); end val () = assert_prerrf_bool (info = 0, "%s: gesvd_sing failed: info = %i\n", @(#LOCATION, info)) // Check ||Sc - S|| prval pfS_gvec = GEVEC_v_of_array_v (pfS_arr) prval pfSc_gvec = GEVEC_v_of_array_v (pfSc_arr) val () = cblas_axpy (N, of_int (~1), !p_S, 1, !p_Sc, 1) val err = cblas_asum (N, !p_Sc, 1) prval () = pfS_arr := array_v_of_GEVEC_v (pfS_gvec) prval () = pfSc_arr := array_v_of_GEVEC_v (pfSc_gvec) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_left_test failed\n", @(#LOCATION)) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_left_test] (* ****** ****** *) // gesvd_right test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_right_test (): void implement{t,tr} gesvd_right_test () = () where { #define M 30 #define N 65 val () = assert_prerrf_bool (M <= N, "%s: gesvd_right only for fat matrices", @(#LOCATION)) // (* val () = begin print "gesvd_right_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate S and Sc stavar m : int val Mz = min_size1_size1 (M, N) : size_t m // cannot remove var !p_S with pfS_arr = @[tr][Mz]() var !p_Sc with pfSc_arr = @[tr][Mz]() // Set-up workspace for right SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_right_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Right SVD of A val info = gesvd_right {m,N} ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_work, lwork ) val () = begin print "info = "; print info; print_newline (); end val () = assert_prerrf_bool ( info = 0, "%s: gesvd_right failed: info = %i\n", @(#LOCATION, info) ) // Set-up workspace for singular values SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_sing_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Singular values of Ac val info = gesvd_sing ( pf_lwork | M_, N_, !p_Ac, M_, !p_Sc, !p_work, lwork ) val () = begin print "info = "; print info; print_newline (); end val () = assert_prerrf_bool (info = 0, "%s: gesvd_sing failed: info = %i", @(#LOCATION, info)) // Check ||Sc - S|| prval pfS_gvec = GEVEC_v_of_array_v (pfS_arr) prval pfSc_gvec = GEVEC_v_of_array_v (pfSc_arr) val () = cblas_axpy (M, of_int (~1), !p_S, 1, !p_Sc, 1) val err = cblas_asum (M, !p_Sc, 1) prval () = pfS_arr := array_v_of_GEVEC_v (pfS_gvec) prval () = pfSc_arr := array_v_of_GEVEC_v (pfSc_gvec) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_right_test failed\n", @(#LOCATION)) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_right_test] (* ****** ****** *) // gesvd_skinny test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_skinny_test (): void implement{t,tr} gesvd_skinny_test () = () where { #define M 55 #define N 30 val () = assert_prerrf_bool1 ( M >= N, "%s: gesvd_skinny only works for skinny", @(#LOCATION) ) // (* val () = begin print "gesvd_skinny_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) stavar n : int val Nsz = min_size1_size1 (M,N) : size_t n // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate S var !p_S = @[tr][Nsz]() // Allocate VT val (pf_gc_VT, pf_NN, pf_fmat_VT | p_VT) = fmatrix_ptr_alloc (N, N) prval () = mul_nat_nat_nat (pf_NN) prval (pf_gmat_VT, fpf_fmat_VT) = GEMAT_v_of_fmatrix_v (pf_fmat_VT) // Set-up workspace for SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_skinny_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Skinny SVD of A val info = gesvd_skinny {M,n} ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_VT, N_, !p_work, lwork ) val () = begin print "info = "; print info; print_newline (); end val () = assert_prerrf_bool (info = 0, "%s: gesvd_skinny failed: info = %i\n", @(#LOCATION, info)) // A = U <- U * diag (S) val () = GEMAT_scal_col {col} {M,n} (ORDERcol, M, N, !p_A, M, !p_S) // Ac <- (U * S) * VT - Ac val () = cblas_gemm ( TRANDIM_N (), TRANDIM_N () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, N , of_int 1 , !p_A, M , !p_VT, N , of_int (~1) , !p_Ac, M ) // Check ||Ac - A|| val err = lange_one (M_, N_, !p_Ac, M_) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * min(M,N)), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_skinny_test failed\n", @(#LOCATION)) // Free VT prval pf_fmat_VT = fpf_fmat_VT (pf_gmat_VT) val () = fmatrix_ptr_free (pf_gc_VT, pf_NN, pf_fmat_VT | p_VT) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_skinny_test] (* ****** ****** *) // gesvd_fat test: S, D, C, Z extern fun{t,tr:t@ype} gesvd_fat_test (): void implement{t,tr} gesvd_fat_test () = () where { #define M 30 #define N 56 val () = assert_prerrf_bool ( M <= N, "%s: gesvd_fat only for fat", @(#LOCATION) ) // (* val () = begin print "gesvd_fat_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) stavar m : int val Msz = min_size1_size1 (M,N) : size_t m // Make A val (pf_gc_A, pf_MN, pf_fmat_A | p_A) = randgen_fmat (M, N) prval () = mul_nat_nat_nat (pf_MN) prval (pf_gmat_A, fpf_fmat_A) = GEMAT_v_of_fmatrix_v (pf_fmat_A) // Make Ac = copy of A val (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) = fmatrix_ptr_alloc (M, N) prval () = mul_nat_nat_nat (pfc_MN) val () = fmatrix_ptr_initialize_elt (!p_Ac, M, N, of_int 0) prval (pf_gmat_Ac, fpf_fmat_Ac) = GEMAT_v_of_fmatrix_v (pf_fmat_Ac) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate U val (pf_gc_U, pf_MM, pf_fmat_U | p_U) = fmatrix_ptr_alloc (M, M) prval () = mul_nat_nat_nat (pf_MM) prval (pf_gmat_U, fpf_fmat_U) = GEMAT_v_of_fmatrix_v (pf_fmat_U) // Allocate S var !p_S = @[tr][Msz]() // Set-up workspace for SVD val M_ = integer_of_int1 M val N_ = integer_of_int1 N val [lwork:int] (pf_lwork | lwork) = gesvd_fat_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // Economy fat SVD of A val info = gesvd_fat {m,N} ( pf_lwork | M_, N_, !p_A, M_, !p_S, !p_U, M_, !p_work, lwork ) val () = assert_prerrf_bool (info = 0, "%s: gesvd_fat failed: info = %i\n", @(#FILENAME, info)) // U <- U * diag (S) val () = GEMAT_scal_col {col} {m,m} (ORDERcol, M, M, !p_U, M, !p_S) // Ac <- (U * S) * VT - Ac (VT = A) val () = cblas_gemm ( TRANDIM_N (), TRANDIM_N () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, M , of_int 1 , !p_U, M , !p_A, M , of_int (~1) , !p_Ac, M ) // Check ||Ac - A|| // val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_A, M, !p_Ac, M) val err = lange_one (M_, N_, !p_Ac, M_) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * M), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gesvd_fat_test failed\n", @(#LOCATION)) // Free U prval pf_fmat_U = fpf_fmat_U (pf_gmat_U) val () = fmatrix_ptr_free (pf_gc_U, pf_MM, pf_fmat_U | p_U) // Free Ac prval pf_fmat_Ac = fpf_fmat_Ac (pf_gmat_Ac) val () = fmatrix_ptr_free (pf_gc_Ac, pfc_MN, pf_fmat_Ac | p_Ac) // Free A prval pf_fmat_A = fpf_fmat_A (pf_gmat_A) val () = fmatrix_ptr_free (pf_gc_A, pf_MN, pf_fmat_A | p_A) } // end of [gesvd_fat_test] (* ****** ****** *) extern fun{t,tr:t@ype} gelqf_unmlq_test (): void implement{t,tr} gelqf_unmlq_test () = () where { #define M 2 #define N 3 val () = assert_prerrf_bool (M <= N, "%s: only fat matrices\n", @(#LOCATION)) // (* val () = begin print "gelqf_unmlq_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gmat_A | p_A, free_A) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_rand (ORDERcol, M, N, !p_A, M) // Copy A val (pf_gmat_Ac | p_Ac, free_Ac) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac, M, N, M, of_int 0) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate tau of Q val MN = min (M, N) var !p_tau with pf_arr_tau = @[t][MN]() // Query for optimal work size and allocate work val lwork = gelqf_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // A <- LQ = A val (pf_lqmat_A | info) = gelqf ( pf_gmat_A, pf_arr_tau | M_, N_, p_A, M_, p_tau, !p_work, lwork) val () = assert_prerrf_bool1 (info = 0, "%s: gelqf failed: info = %i\n", @(#LOCATION, info)) // Allocate Ac2 <- (L 0) val (pf_gmat_Ac2 | p_Ac2, free_Ac2) = GEMAT_col_ptr_allocfree (M, N) val (pf1_gmat_Ac2, pf2_gmat_Ac2, fpf_gmat_Ac2 | p1_Ac2, p2_Ac2) = GEMAT_ptr_split1x2 (pf_gmat_Ac2 | ORDERcol, p_Ac2, M, M) val () = GEMAT_ptr_initialize_eye (ORDERcol, M, !p1_Ac2, M) prval (pf_trmat_A, fpf_lqmat_A) = TRMAT_v_of_LQMAT_v (pf_lqmat_A) val () = cblas_trmm ( SIDEDIM_L () | CblasColMajor , CblasLeft, CblasLower, CblasNoTrans, CblasNonUnit , M, M, of_int 1, !p_A, M, !p1_Ac2, M) prval pf_lqmat_A = fpf_lqmat_A (pf_trmat_A) val NM_sz = i2sz (N-M) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p2_Ac2, M, NM_sz, M, of_int 0) prval pf_gmat_Ac2 = fpf_gmat_Ac2 (pf1_gmat_Ac2, pf2_gmat_Ac2) // Ac2 <- (L 0) * Q val lwork = unmlq_work_query (SIDEDIM_R () | ClapackRight, ClapackNoTrans, M_, N_, M_) var !p_work with pf_arr_work = @[t][size1_of_integer lwork]() val info = unmlq ( SIDEDIM_R (), pf_lqmat_A | ClapackRight, ClapackNoTrans , M_, N_, M_, p_A, M_, p_tau, !p_Ac2, M_, !p_work, lwork ) // Check ||Ac - Ac2|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_Ac, M, !p_Ac2, M) val err = lange_one (M_, N_, !p_Ac2, M_) val isbig = // error cannot be ignored $F2C.lte (err, $F2C.mul (of_int (M * N * M), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gelqf_unmlq_test failed\n", @(#LOCATION)) // Free Ac2 val () = free_Ac2 (pf_gmat_Ac2 | p_Ac2) // Free LQMAT prval (pf_gmat_A, pf_arr_tau1) = LQMAT_err_v_elim (pf_lqmat_A) prval () = pf_arr_tau := pf_arr_tau1 // Free Ac val () = free_Ac (pf_gmat_Ac | p_Ac) // Free A val () = free_A (pf_gmat_A | p_A) } // end of [gelqf_unmlq_test] (* ****** ****** *) extern fun{t,tr:t@ype} geqlf_unmql_test (): void implement{t,tr} geqlf_unmql_test () = () where { #define M 30 #define N 20 val () = assert_prerrf_bool (N <= M, "%s: only skinny matrices\n", @(#LOCATION)) // (* val () = begin print "geqlf_unmql_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gmat_A | p_A, free_A) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_rand (ORDERcol, M, N, !p_A, M) // Copy A val (pf_gmat_Ac | p_Ac, free_Ac) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac, M, N, M, of_int 0) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate tau of Q stavar n : int val Nsz = min_size1_size1 (M, N) : size_t n var !p_tau with pf_arr_tau = @[t][Nsz]() // Query lwork and allocate work val lwork = geqlf_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // A <- LQ = A val (pf_qlmat_A | info) = geqlf ( pf_gmat_A, pf_arr_tau | M_, N_, p_A, M_, p_tau, !p_work, lwork) val () = assert_prerrf_bool1 (info = 0, "%s: geqlf failed: info = %i\n", @(#LOCATION, info)) // Allocate Ac2 <- (0 L')' val (pf_gmat_Ac2 | p_Ac2, free_Ac2) = GEMAT_col_ptr_allocfree (M, N) val (pf1_gmat_Ac2, pf2_gmat_Ac2, fpf_gmat_Ac2 | p1_Ac2, p2_Ac2) = GEMAT_ptr_split2x1 (pf_gmat_Ac2 | ORDERcol, p_Ac2, M, i2sz (M-N)) val () = GEMAT_ptr_initialize_eye (ORDERcol, N, !p2_Ac2, M) val (pf_trmat_A, fpf_qlmat_A | p_L) = TRMAT_of_QLMAT (pf_qlmat_A | M_, N_, p_A) val () = cblas_trmm ( SIDEDIM_L () | CblasColMajor , CblasLeft, CblasLower, CblasNoTrans, CblasNonUnit , N, N, of_int 1, !p_L, M, !p2_Ac2, M) prval pf_qlmat_A = fpf_qlmat_A (pf_trmat_A) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p1_Ac2, i2sz (M-N), N, M, of_int 0) prval pf_gmat_Ac2 = fpf_gmat_Ac2 (pf1_gmat_Ac2, pf2_gmat_Ac2) // Ac2 <- Q * (0 L')' val lwork = unmql_work_query (SIDEDIM_L () | ClapackLeft, ClapackNoTrans, M_, N_, N_) var !p_work with pf_arr_work = @[t][size1_of_integer lwork]() val info = unmql ( SIDEDIM_L (), pf_qlmat_A | ClapackLeft, ClapackNoTrans , M_, N_, N_, p_A, M_, p_tau, !p_Ac2, M_, !p_work, lwork ) // Check ||Ac - Ac2|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_Ac, M, !p_Ac2, M) val err = lange_one (M_, N_, !p_Ac2, M_) val isbig = // error cannot be ignored $F2C.lte (err, $F2C.mul (of_int (M * N * N), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: geqlf_unmql_test failed\n", @(#LOCATION)) // Free Ac2 val () = free_Ac2 (pf_gmat_Ac2 | p_Ac2) // Free LQMAT prval (pf_gmat_A, pf_arr_tau1) = QLMAT_err_v_elim (pf_qlmat_A) prval () = pf_arr_tau := pf_arr_tau1 // Free Ac val () = free_Ac (pf_gmat_Ac | p_Ac) // Free A val () = free_A (pf_gmat_A | p_A) } // end of [geqlf_unmql_test] (* ****** ****** *) extern fun{t,tr:t@ype} geqrf_unmqr_test (): void implement{t,tr} geqrf_unmqr_test () = () where { #define M 30 #define N 20 val () = assert_prerrf_bool1 (N <= M, "%s: Only skinny matrices.", @(#LOCATION)) // (* val () = begin print "geqrf_unmqr_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gmat_A | p_A, free_A) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_rand (ORDERcol, M, N, !p_A, M) // Copy A val (pf_gmat_Ac | p_Ac, free_Ac) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac, M, N, M, of_int 0) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate tau of Q stavar n : int val Nsz = min_size1_size1 (M, N) : size_t n var !p_tau with pf_arr_tau = @[t][Nsz]() // Work query and allocate val lwork = geqrf_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // A <- QR = A val (pf_qrmat_A | info) = geqrf ( pf_gmat_A, pf_arr_tau | M_, N_, p_A, M_, p_tau, !p_work, lwork) val () = assert_prerrf_bool1 (info = 0, "%s: geqrf failed!", @(#LOCATION)) // Allocate Ac2 <- (R' 0)' val (pf_gmat_Ac2 | p_Ac2, free_Ac2) = GEMAT_col_ptr_allocfree (M, N) val (pf1_gmat_Ac2, pf2_gmat_Ac2, fpf_gmat_Ac2 | p1_Ac2, p2_Ac2) = GEMAT_ptr_split2x1 (pf_gmat_Ac2 | ORDERcol, p_Ac2, M, N) val () = GEMAT_ptr_initialize_eye (ORDERcol, N, !p1_Ac2, M) prval (pf_trmat_A, fpf_qrmat_A) = TRMAT_v_of_QRMAT_v (pf_qrmat_A) val () = cblas_trmm ( SIDEDIM_L () | CblasColMajor , CblasLeft, CblasUpper, CblasNoTrans, CblasNonUnit , N, N, of_int 1, !p_A, M, !p1_Ac2, M) prval pf_qrmat_A = fpf_qrmat_A (pf_trmat_A) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p2_Ac2, i2sz (M-N), N, M, of_int 0) prval pf_gmat_Ac2 = fpf_gmat_Ac2 (pf1_gmat_Ac2, pf2_gmat_Ac2) // Ac2 <- Q * (R' 0)' val lwork = unmqr_work_query (SIDEDIM_L () | ClapackLeft, ClapackNoTrans, M_, N_, N_) var !p_work with pf_arr_work = @[t][size1_of_integer lwork]() val info = unmqr ( SIDEDIM_L (), pf_qrmat_A | ClapackLeft, ClapackNoTrans , M_, N_, N_, p_A, M_, p_tau, !p_Ac2, M_, !p_work, lwork ) // Check ||Ac - Ac2|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_Ac, M, !p_Ac2, M) val err = lange_one (M_, N_, !p_Ac2, M_) val isbig = // error cannot be ignored $F2C.lte (err, $F2C.mul (of_int (M * N * N), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: geqrf_unmql_test failed\n", @(#LOCATION)) // Free Ac2 val () = free_Ac2 (pf_gmat_Ac2 | p_Ac2) // Free QRMAT prval (pf_gmat_A, pf_arr_tau1) = QRMAT_err_v_elim (pf_qrmat_A) prval () = pf_arr_tau := pf_arr_tau1 // Free Ac val () = free_Ac (pf_gmat_Ac | p_Ac) // Free A val () = free_A (pf_gmat_A | p_A) } // end of [geqrf_unmqr_test] (* ****** ****** *) extern fun{t,tr:t@ype} gerqf_unmrq_test (): void implement{t,tr} gerqf_unmrq_test () = () where { #define M 20 #define N 30 val () = assert_prerrf_bool (N >= M, "%s: only fat matrices\n", @(#LOCATION)) // (* val () = begin print "gerqf_unmrq_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gmat_A | p_A, free_A) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_rand (ORDERcol, M, N, !p_A, M) // Copy A val (pf_gmat_Ac | p_Ac, free_Ac) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac, M, N, M, of_int 0) val M_ = integer_of_int1 M val N_ = integer_of_int1 N val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate tau of Q val MN = min (M, N) var !p_tau with pf_arr_tau = @[t][MN]() // Work query and allocate val lwork = gerqf_work_query (M_, N_) var !p_work = @[t][size1_of_integer lwork]() // A <- RQ = A val (pf_rqmat_A | info) = gerqf ( pf_gmat_A, pf_arr_tau | M_, N_, p_A, M_, p_tau, !p_work, lwork) val () = assert_prerrf_bool1 (info = 0, "%s: gerqf failed: info = %i\n", @(#LOCATION, info)) // Allocate Ac2 <- (0 R) val (pf_gmat_Ac2 | p_Ac2, free_Ac2) = GEMAT_col_ptr_allocfree (M, N) val (pf1_gmat_Ac2, pf2_gmat_Ac2, fpf_gmat_Ac2 | p1_Ac2, p2_Ac2) = GEMAT_ptr_split1x2 (pf_gmat_Ac2 | ORDERcol, p_Ac2, M, i2sz (N-M)) val () = GEMAT_ptr_initialize_eye (ORDERcol, M, !p2_Ac2, M) val (pf_trmat_A, fpf_rqmat_A | p_R) = TRMAT_of_RQMAT (pf_rqmat_A | M_, N_, M_, p_A) val () = cblas_trmm ( SIDEDIM_L () | CblasColMajor , CblasLeft, CblasUpper, CblasNoTrans, CblasNonUnit , M, M, of_int 1, !p_R, M, !p2_Ac2, M) prval pf_rqmat_A = fpf_rqmat_A (pf_trmat_A) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p1_Ac2, M, i2sz (N-M), M, of_int 0) prval pf_gmat_Ac2 = fpf_gmat_Ac2 (pf1_gmat_Ac2, pf2_gmat_Ac2) // Ac2 <- (0 R) * Q val lwork = unmrq_work_query (SIDEDIM_R () | ClapackRight, ClapackNoTrans, M_, N_, M_) var !p_work with pf_arr_work = @[t][size1_of_integer lwork]() val info = unmrq ( SIDEDIM_R (), pf_rqmat_A | ClapackRight, ClapackNoTrans , M_, N_, M_, p_A, M_, p_tau, !p_Ac2, M_, !p_work, lwork ) // Check ||Ac - Ac2|| val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_Ac, M, !p_Ac2, M) val err = lange_one (M_, N_, !p_Ac2, M_) val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N * M), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: gerqf_unmrq_test failed\n", @(#LOCATION)) // Free Ac2 val () = free_Ac2 (pf_gmat_Ac2 | p_Ac2) // Free RQMAT prval (pf_gmat_A, pf_arr_tau1) = RQMAT_err_v_elim (pf_rqmat_A) prval () = pf_arr_tau := pf_arr_tau1 // Free Ac val () = free_Ac (pf_gmat_Ac | p_Ac) // Free A val () = free_A (pf_gmat_A | p_A) } // end of [gerqf_unmrq_test] (* ****** ****** *) extern prfun anonymitize_at {a:viewt@ype} {l:addr} (pf: !a @ l >> v): #[v:view] (v - a @ l) // end of [vhide] implement anonymitize_at {a} {l} (pf) = let viewdef V = a @ l; prval id = lam (pf: V): V = pf in #[V | id] end // end of [anonymitize] extern fun{t,tr:t@ype} getrf_laswp_test (): void implement{t,tr} getrf_laswp_test () = () where { #define M 30 #define N 20 val () = assert_prerrf_bool (M >= N, "%s: only skinny matrices\n", @(#LOCATION)) val M_ = integer_of_int1 M val N_ = integer_of_int1 N // (* val () = begin print "getrf_laswp_test<"; print_typ (); print ">: "; print_newline () end // end of [val] // *) // Make A val (pf_gmat_A | p_A, free_A) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_rand (ORDERcol, M, N, !p_A, M) // Copy A val (pf_gmat_Ac | p_Ac, free_Ac) = GEMAT_col_ptr_allocfree (M, N) val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac, M, N, M, of_int 0) val () = lacpy (ClapackULN_N, M_, N_, !p_A, M_, !p_Ac, M_) // Allocate ipiv var !p_ipiv = @[integer][min_size1_size1(M,N)]() // A -> PLU val (pf_lumat | info) = getrf (pf_gmat_A | M_, N_, p_A, M_, !p_ipiv) val () = assert_prerrf_bool1 (info >= 0, "%s: getrf failed with info = %i\n", @(#LOCATION, info)) // Get factors val (pf_L, pf_U, pf_mat, fpf_lumat | p_mat) = LUMAT_ptr_split_skinny (pf_lumat | p_A, M, N, M) // Multiply factors // Allocate space val (pf_gmat_Ac2 | p_Ac2, free_Ac2) = GEMAT_col_ptr_allocfree (M, N) // Split into top & bottom val (pf_gmat_Ac2_1, pf_gmat_Ac2_2, fpf_gmat_Ac2 | p_Ac2_1, p_Ac2_2) = GEMAT_ptr_split2x1 (pf_gmat_Ac2 | ORDERcol, p_Ac2, M, N) // Ac2 <- [L1 L2] * U val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac2_1, N, N, M, of_int 0) // prval fpf_U = anonymitize_at (pf_U) val () = trcpy (ORDERcol, UPLOlower, DIAGunit, N, !p_A, M, !p_Ac2_1, M) prval () = pf_U := fpf_U (pf_U) // val () = GEMAT_ptr_initialize_elt (ORDERcol, !p_Ac2_2, i2sz (M-N), N, M, of_int 0) val () = lacpy (ClapackULN_N, M_-N_, N_, !p_mat, M_, !p_Ac2_2, M_) prval pf_gmat_Ac2 = fpf_gmat_Ac2 (pf_gmat_Ac2_1, pf_gmat_Ac2_2) // prval fpf_L = anonymitize_at (pf_L) val () = cblas_trmm ( SIDEDIM_R () | CblasColMajor, CblasRight, CblasUpper, CblasNoTrans, CblasNonUnit , M, N, of_int 1, !p_A, M, !p_Ac2, M ) // end of [val] prval () = pf_L := fpf_L (pf_L) // Ac2 <- ipiv * Ac2 val () = laswp (N_, !p_Ac2, M_, integer_of_int1 1, N_ , !p_ipiv, integer_of_int1 (~1)) // norm (Ac - Ac2) val () = GEMAT_axpy (ORDERcol, M, N, of_int (~1), !p_Ac, M, !p_Ac2, M) val err = lange_one (M_, N_, !p_Ac2, M_) // Error check val isbig = $F2C.lte // error cannot be ignored (err, $F2C.mul (of_int (M * N), macheps_get ())) val () = assert_prerrf_bool (isbig, "%s: getrf_laswp_test failed \n", @(#LOCATION)) // Free A prval pf_lumat = fpf_lumat (pf_L, pf_U, pf_mat) prval pf_gmat_A = LUMAT_err_v_elim (pf_lumat) val () = free_A (pf_gmat_A | p_A) // Free Ac val () = free_Ac (pf_gmat_Ac | p_Ac) // Free Ac2 val () = free_Ac2 (pf_gmat_Ac2 | p_Ac2) } // end of [getrf_laswp_test] (* ****** ****** *) fn part1_test () = () where { val () = print "lange_lacpy_test: begins ... " val () = lange_lacpy_test () val () = lange_lacpy_test () val () = lange_lacpy_test () val () = lange_lacpy_test () val () = (print "finishes"; print_newline ()) // val () = print "gels_test: begins ... " val () = gels_test () val () = gels_test () val () = gels_test () val () = gels_test () val () = (print "finishes"; print_newline ()) // val () = print "gels_test_minnorm: begins ... " val () = gels_test_minnorm () val () = gels_test_minnorm () val () = gels_test_minnorm () val () = gels_test_minnorm () val () = (print "finishes"; print_newline ()) // val () = print "gesv_test: begins ... " val () = gesv_test () val () = gesv_test () val () = gesv_test () val () = gesv_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_test: begins ...\n" val () = gesvd_test () val () = gesvd_test () val () = gesvd_test () val () = gesvd_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_econ_test: begins ...\n" val () = gesvd_econ_test () val () = gesvd_econ_test () val () = gesvd_econ_test () val () = gesvd_econ_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_sing_test: begins ...\n" val () = gesvd_sing_test () val () = gesvd_sing_test () val () = gesvd_sing_test () val () = gesvd_sing_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_left_test: begins ...\n" val () = gesvd_left_test () val () = gesvd_left_test () val () = gesvd_left_test () val () = gesvd_left_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_right_test: begins ...\n" val () = gesvd_right_test () val () = gesvd_right_test () val () = gesvd_right_test () val () = gesvd_right_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_skinny_test: begins ...\n" val () = gesvd_skinny_test () val () = gesvd_skinny_test () val () = gesvd_skinny_test () val () = gesvd_skinny_test () val () = (print "finishes"; print_newline ()) // val () = print "gesvd_fat_test: begins ...\n" val () = gesvd_fat_test () val () = gesvd_fat_test () val () = gesvd_fat_test () val () = gesvd_fat_test () val () = (print "finishes"; print_newline ()) // val () = print "gelqf_unmlq_test: begins ...\n" val () = gelqf_unmlq_test () val () = gelqf_unmlq_test () val () = gelqf_unmlq_test () val () = gelqf_unmlq_test () val () = (print "finishes"; print_newline ()) // val () = print "geqlf_unmql_test: begins ...\n" val () = geqlf_unmql_test () val () = geqlf_unmql_test () val () = geqlf_unmql_test () val () = geqlf_unmql_test () val () = (print "finishes"; print_newline ()) // val () = print "geqrf_unmqr_test: begins ...\n" val () = geqrf_unmqr_test () val () = geqrf_unmqr_test () val () = geqrf_unmqr_test () val () = geqrf_unmqr_test () val () = (print "finishes"; print_newline ()) // val () = print "gerqf_unmrq_test: begins ...\n" val () = gerqf_unmrq_test () val () = gerqf_unmrq_test () val () = gerqf_unmrq_test () val () = gerqf_unmrq_test () val () = (print "finishes"; print_newline ()) // val () = print "getrf_laswp_test: begins ...\n" val () = getrf_laswp_test () val () = getrf_laswp_test () val () = getrf_laswp_test () val () = getrf_laswp_test () val () = (print "finishes"; print_newline ()) } // end of [part1_test] (* ****** ****** *) dynload "contrib/cblas/DATS/cblas.dats" dynload "contrib/cblas/DATS/cblas_extra.dats" dynload "contrib/clapack/DATS/clapack.dats" (* ****** ****** *) implement main () = () where { // (* val () = srand48_with_time () // this makes it really hard for debugging // *) val () = begin print "clapack_test: starts"; print_newline () end // end of [val] val () = part1_test () val () = begin print "clapack_test: finishes"; print_newline () end // end of [val] } // end of [main] (* ****** ****** *) (* end of [clapack_test.dats] *) ats-lang-anairiats-0.2.11/contrib/clapack/SATS/0000700000175000017500000000000012223166165017574 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/SATS/clapack.sats0000664000175000017500000012023112223166165022101 0ustar hwxihwxi(* ** ** An interface for ATS to interact with LAPACK ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "contrib/clapack/CATS/clapack.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "contrib/clapack/SATS/f2c.sats" (* ****** ****** *) staload "libc/SATS/complex.sats" staload GA = "libats/SATS/genarrays.sats" // sortdef inc = $GA.inc // sort for leading dimensions // sortdef order = $GA.order stadef row = $GA.row stadef col = $GA.col // sortdef uplo = $GA.uplo stadef upper = $GA.upper stadef lower = $GA.lower // sortdef side = $GA.side stadef left = $GA.left stadef right = $GA.right stadef sidedim_p = $GA.sidedim_p // sortdef transpose = $GA.transpose stadef TPN = $GA.TPN stadef TPT = $GA.TPT stadef TPC = $GA.TPC stadef trandim_p = $GA.trandim_p // sortdef diag = $GA.diag stadef unit = $GA.unit() stadef nonunit = $GA.nonunit() (* ****** ****** *) (* ** for column-major generic matrices: *) viewtypedef GEMAT (a:viewt@ype, m:int, n:int, lda:int) = $GA.GEMAT (a, m, n, col, lda) // end of [GEMAT] viewtypedef TRMAT (a:viewt@ype, n:int, ul: uplo, dg: diag, lda: int) = $GA.TRMAT (a, n, col, ul, dg, lda) // end of [TRMAT] (* ****** ****** *) abst@ype CLAPACK_UPLO_t (uplo) = char macdef ClapackUpper = $extval (CLAPACK_UPLO_t upper, "'U'") macdef ClapackLower = $extval (CLAPACK_UPLO_t lower, "'L'") abst@ype CLAPACK_UPLO_OPT_t = char (* upper, lower, none *) macdef ClapackULN_U = $extval (CLAPACK_UPLO_OPT_t, "'U'") macdef ClapackULN_L = $extval (CLAPACK_UPLO_OPT_t, "'L'") macdef ClapackULN_N = $extval (CLAPACK_UPLO_OPT_t, "'N'") (* ****** ****** *) abst@ype CLAPACK_SIDE_t (side) = char macdef ClapackLeft = $extval (CLAPACK_SIDE_t left, "'L'") macdef ClapackRight = $extval (CLAPACK_SIDE_t right, "'R'") (* ****** ****** *) abst@ype CLAPACK_TRANSPOSE_t (transpose) = char macdef ClapackNoTrans = $extval (CLAPACK_TRANSPOSE_t TPN, "'N'") macdef ClapackTrans = $extval (CLAPACK_TRANSPOSE_t TPT, "'T'") macdef ClapackConjTrans = $extval (CLAPACK_TRANSPOSE_t TPC, "'C'") (* ****** ****** *) abst@ype CLAPACK_DIAG_t (diag) = char macdef ClapackUnit = $extval (CLAPACK_DIAG_t(unit), "'U'") macdef ClapackNonUnit = $extval (CLAPACK_DIAG_t(nonunit), "'N'") (* ****** ****** *) abst@ype CLAPACK_NORM_t (char) = char typedef CLAPACK_NORM_t = [c:char] CLAPACK_NORM_t (c) macdef ClapackNormMax = $extval (CLAPACK_NORM_t 'M', "'M'") // max of elt macdef ClapackNormInf = $extval (CLAPACK_NORM_t 'I', "'I'") // max of row sums macdef ClapackNormOne = $extval (CLAPACK_NORM_t 'O', "'O'") // max of col sums // Frobenius: sqrt (sum of all elements squared) macdef ClapackNormFrob = $extval (CLAPACK_NORM_t 'F', "'F'") (* ****** ****** *) (* /* CMACH (input) CHARACTER*1 */ /* Specifies the value to be returned by SLAMCH: */ /* = 'E' or 'e', SLAMCH := eps */ /* = 'S' or 's , SLAMCH := sfmin */ /* = 'B' or 'b', SLAMCH := base */ /* = 'P' or 'p', SLAMCH := eps*base */ /* = 'N' or 'n', SLAMCH := t */ /* = 'R' or 'r', SLAMCH := rnd */ /* = 'M' or 'm', SLAMCH := emin */ /* = 'U' or 'u', SLAMCH := rmin */ /* = 'L' or 'l', SLAMCH := emax */ /* = 'O' or 'o', SLAMCH := rmax */ /* where */ /* eps = relative machine precision */ /* sfmin = safe minimum, such that 1/sfmin does not overflow */ /* base = base of the machine */ /* prec = eps*base */ /* t = number of (base) digits in the mantissa */ /* rnd = 1.0 when rounding occurs in addition, 0.0 otherwise */ /* emin = minimum exponent before (gradual) underflow */ /* rmin = underflow threshold - base**(emin-1) */ /* emax = largest exponent before overflow */ /* rmax = overflow threshold - (base**emax)*(1-eps) */ *) // lamach: S, D fun{t:t@ype} lamch (cmach: char): t fun slamch (c: char):<> real = "atsctrb_clapack_slamch" fun dlamch (c: char):<> doublereal = "atsctrb_clapack_dlamch" (* // // This is fine, too, but it is likely to be unnecessary ... (HX) // sortdef char_lamch = { c : char | c == 'E' || c == 'e' || c == 'S' || c == 's' || c == 'B' || c == 'b' || c == 'P' || c == 'p' || c == 'N' || c == 'n' || c == 'R' || c == 'r' || c == 'M' || c == 'm' || c == 'U' || c == 'u' || c == 'L' || c == 'l' || c == 'O' || c == 'o' } // lamach: S, D // always returns a double! fun{t:t@ype} lamch {c:char_lamch} (cmach: char c): t // slamch returns a double! fun slamch {c:char_lamch} (c: char c): doublereal = "atsctrb_clapack_slamch" fun dlamch {c:char_lamch} (c: char c): doublereal = "atsctrb_clapack_dlamch" *) fun{t:t@ype} lamch_eps ():<> t fun{t:t@ype} lamch_sfmin ():<> t fun{t:t@ype} lamch_base ():<> t fun{t:t@ype} lamch_prec ():<> t fun{t:t@ype} lamch_t ():<> t fun{t:t@ype} lamch_rnd ():<> t fun{t:t@ype} lamch_emin ():<> t fun{t:t@ype} lamch_rmin ():<> t fun{t:t@ype} lamch_emax ():<> t fun{t:t@ype} lamch_rmax ():<> t (* ****** ****** *) // lange: S, D, C, Z (* // taken from [clapack.h] doublereal dlange_( char *norm , integer *m, integer *n , doublereal *a, integer *lda , doublereal *work ) ; *) dataview langework_v (t:t@ype+, c:char, m:int, l:addr) = | {c == 'I'} langework_v_some (t, c, m, l) of array_v (t?, m, l) | {c <> 'I'} langework_v_none (t, c, m, l) of () // end of [langework_v] // |t1| = t2 typedef lange_type (t1:t@ype, t2:t@ype) = {c:char} {m,n:nat} {lda:inc} {m1:pos | m <= m1} {l_work:addr} ( (*pf: *) !langework_v (t2, c, m1, l_work) | (*norm: *) CLAPACK_NORM_t c , (*m:*) integer m, (*n:*) integer n , (*a:*) &GEMAT (t1, m, n, lda), (*lda:*) integer lda , (*p_work:*) ptr l_work ) - t2 // end of [lange_type] fun{t1,t2:t@ype} lange: lange_type (t1, t2) fun slange: lange_type (real, real) = "atsctrb_clapack_slange" fun dlange: lange_type (doublereal, doublereal) = "atsctrb_clapack_dlange" fun clange: lange_type (complex, real) = "atsctrb_clapack_clange" fun zlange: lange_type (doublecomplex, doublereal) = "atsctrb_clapack_zlange" (* ****** ****** *) // |t1| = t2 fun{t1,t2:t@ype} lange_inf {m,n:nat} {lda:inc} {m1:pos | m <= m1} ( m: integer m, n: integer n , a: &GEMAT (t1, m, n, lda), lda: integer lda , work: &(@[t2?][m1]) ) :<> t2 // end of [lange_inf] // |t1| = t2 fun{t1,t2:t@ype} lange_one {m,n:nat} {lda:inc} ( m: integer m, n: integer n, a: &GEMAT (t1, m, n, lda), lda: integer lda ) :<> t2 // [end of [lange_one] // |t1| = t2 fun{t1,t2:t@ype} lange_max {m,n:nat} {lda:inc} ( m: integer m, n: integer n, a: &GEMAT (t1, m, n, lda), lda: integer lda ) :<> t2 // [end of [lange_max] // |t1| = t2 fun{t1,t2:t@ype} lange_frob {m,n:nat} {lda:inc} ( m: integer m, n: integer n, a: &GEMAT (t1, m, n, lda), lda: integer lda ) :<> t2 // [end of [lange_frob] (* ****** ****** *) // // lacpy: S, D, C, Z // (* // taken from [clapack.h] /* Subroutine */ int dlacpy_( char *uplo , integer *m, integer *n , doublereal *a, integer *lda , doublereal *b, integer *ldb ) ; *) typedef lacpy_type (t:t@ype) = {m,n:nat} {lda,ldb:inc} ( (*uln:*) CLAPACK_UPLO_OPT_t , (*m:*) integer m, (*n:*) integer n , (*a:*) &GEMAT (t, m, n, lda), (*lda:*) integer lda , (*b:*) &GEMAT (t, m, n, ldb), (*ldb:*) integer ldb ) - void // end of [typedef] fun{t:t@ype} lacpy: lacpy_type (t) fun slacpy: lacpy_type (real) = "atsctrb_clapack_slacpy" fun dlacpy: lacpy_type (doublereal) = "atsctrb_clapack_dlacpy" fun clacpy: lacpy_type (complex) = "atsctrb_clapack_clacpy" fun zlacpy: lacpy_type (doublecomplex) = "atsctrb_clapack_zlacpy" (* ****** ****** *) absview LQMAT_err_v ( a:t@ype+, m:int, n:int, k:int, lda: int, la:addr, ltau:addr , err:int ) // end of [absview] prfun LQMAT_err_v_elim {a:t@ype} {m,n,k:int} {lda:int} {la,ltau:addr} {err:int} ( pflq: LQMAT_err_v (a, m, n, k, lda, la, ltau, err) ) : ( GEMAT (a?, m, n, lda) @ la, array_v (a, k, ltau) ) // end of [LQMAT_err_v_elim] viewdef LQMAT_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr ) = LQMAT_err_v (a, m, n, k, lda, la, ltau, 0(*succ*)) prfun TRMAT_v_of_LQMAT_v {a:t@ype} {m,n,k:nat | m <= n} {lda:inc} {la,ltau:addr} ( pf_lqmat: LQMAT_v (a, m, n, k, lda, la, ltau) ) : ( TRMAT (a, m, lower, nonunit, lda) @ la , TRMAT (a, m, lower, nonunit, lda) @ la - LQMAT_v (a, m, n, k, lda, la, ltau) ) // end of [TRMAT_v_of_LQMAT_v] (* ****** ****** *) // // gelqf: S, D, C, Z // (* // taken from [clapack.h] /* Subroutine */ int dgelqf_( integer *m, integer *n , doublereal *a, integer *lda , doublereal *tau , doublereal *work, integer *lwork , integer *info ) ; *) typedef gelqf_type (t:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= m} ( GEMAT (t, m, n, lda) @ la // a , array_v (t?, mn, ltau) // tau | integer m , integer n , ptr la, integer lda // a, lda , ptr ltau // tau , &(@[t?][lwork]), integer lwork ) - [err:int] ( LQMAT_err_v (t, m, n, mn, lda, la, ltau, err) | int err ) // end of [gelqf_type] fun{t:t@ype} gelqf: gelqf_type (t) fun sgelqf: gelqf_type (real) = "atsctrb_clapack_sgelqf" fun dgelqf: gelqf_type (doublereal) = "atsctrb_clapack_dgelqf" fun cgelqf: gelqf_type (complex) = "atsctrb_clapack_cgelqf" fun zgelqf: gelqf_type (doublecomplex) = "atsctrb_clapack_zgelqf" fun{t:t@ype} gelqf_exn {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= m} ( pfa: GEMAT (t, m, n, lda) @ la // a , pftau: array_v (t?, mn, ltau) // tau | m: integer m , n: integer n , la: ptr la, lda: integer lda // a, lda , ltau: ptr ltau // tau , work: &(@[t?][lwork]), lwork: integer lwork ) :<> [err:int] ( LQMAT_v (t, m, n, mn, lda, la, ltau) | void ) // end of [gelqf_exn] fun{t:t@ype} gelqf_work_query {m,n:nat} (m: integer m, n: integer n) :<> [lwork:int | lwork >= m] integer (lwork) (* ****** ****** *) // // ormlq: S, D and unmlq: C, Z // (* /* Subroutine */ int sormlq_( char *side , char *trans , integer *m, integer *n, integer *k , real *a, integer *lda , real *tau , real *c, integer *ldc , real *work, integer *lwork , integer *info ) ; // taken from [clapack.h] /* Subroutine */ int cunmlq_( char *side , char *trans , integer *m, integer *n, integer *k , complex *a, integer *lda , complex *tau , complex *c__, integer *ldc , complex *work, integer *lwork , integer *info ) ; *) typedef unmlq_type (t:t@ype) = {m,n,k:nat} {ma,na:int} // k <= min(ma,na) {lda,ldc:inc} {lr:side} {tr:transpose} {lwork:pos | lwork >= m+n-na} {la,ltau:addr} ( (*side:*) sidedim_p (lr, m, n, na) , (*lqmat:*) !LQMAT_v (t, ma, na, k, lda, la, ltau) | (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer m, (*n:*) integer n, (*k:*) integer k , (*a:*) ptr la, (*lda:*) integer lda, (*tau:*) ptr ltau , (*c__:*) &GEMAT (t, m, n, ldc), (*ldc:*) integer ldc , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - int // end of [unmlq_type] fun{t:t@ype} unmlq: unmlq_type (t) fun cunmlq: unmlq_type (complex) = "atsctrb_clapack_cunmlq" fun zunmlq: unmlq_type (doublecomplex) = "atsctrb_clapack_zunmlq" fun{t:t@ype} unmlq_work_query {m,n,k:pos} {na:nat | k <= na} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, na) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-na] integer (lwork) // end of [unmlq_work_query] (* ****** ****** *) stadef ormlq_type = unmlq_type fun{t:t@ype} ormlq: ormlq_type (t) fun sormlq: ormlq_type (real) = "atsctrb_clapack_sormlq" fun dormlq: ormlq_type (doublereal) = "atsctrb_clapack_dormlq" fun{t:t@ype} ormlq_work_query {m,n,k:pos} {na:nat | k <= na} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, na) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-na] integer (lwork) // end of [ormlq_work_query] (* ****** ****** *) absview QLMAT_err_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr , err:int ) // end of [absview] prfun QLMAT_err_v_elim {a:t@ype} {m,n,k:int} {lda:int} {la,ltau:addr} {err:int} ( pflq: QLMAT_err_v (a, m, n, k, lda, la, ltau, err) ) : ( GEMAT (a?, m, n, lda) @ la, array_v (a, k, ltau) ) // end of [QLMAT_err_v_elim] viewdef QLMAT_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr ) = QLMAT_err_v (a, m, n, k, lda, la, ltau, 0(*succ*)) prfun TRMAT_v_of_QLMAT_v {a:t@ype} {m,n,k:nat | m >= n} {lda:inc} {la,ltau:addr} {ofs:int} ( pf_mul: MUL (m-n, sizeof a, ofs) , pf_qlmat: QLMAT_v (a, m, n, k, lda, la, ltau) ) : ( TRMAT (a, n, lower, nonunit, lda) @ la+ofs , TRMAT (a, n, lower, nonunit, lda) @ la+ofs - QLMAT_v (a, m, n, k, lda, la, ltau) ) // end of [TRMAT_v_of_QLMAT_v] fun{a:t@ype} TRMAT_of_QLMAT {m,n,k:nat | m >= n} {lda:inc} {la,ltau:addr} ( pf_qlmat: QLMAT_v (a, m, n, k, lda, la, ltau) | m: integer m, n: integer n, pa: ptr la ) :<> [la_ofs:addr] ( // la_ofs: la + ofs TRMAT (a, n, lower, nonunit, lda) @ la_ofs , TRMAT (a, n, lower, nonunit, lda) @ la_ofs - QLMAT_v (a, m, n, k, lda, la, ltau) | ptr la_ofs ) // end of [TRMAT_of_QLMAT] (* ****** ****** *) // geqlf: S, D, C, Z (* // taken from [clapack.h] /* Subroutine */ int dgeqlf_( integer *m, integer *n , doublereal *a, integer *lda , doublereal *tau , doublereal *work, integer *lwork , integer *info ) ; *) typedef geqlf_type (t:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= n} ( (*a:*) GEMAT (t, m, n, lda) @ la , (*tau*) array_v (t?, mn, ltau) | (*m:*) integer m, (*n:*) integer n , (*a:*) ptr la, (*lda:*) integer lda, (*tau:*) ptr ltau , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - [err:int] ( QLMAT_err_v (t, m, n, mn, lda, la, ltau, err) | int err ) // end of [geqlf_type] fun{t:t@ype} geqlf: geqlf_type (t) fun sgeqlf: geqlf_type (real) = "atsctrb_clapack_sgeqlf" fun dgeqlf: geqlf_type (doublereal) = "atsctrb_clapack_dgeqlf" fun cgeqlf: geqlf_type (complex) = "atsctrb_clapack_cgeqlf" fun zgeqlf: geqlf_type (doublecomplex) = "atsctrb_clapack_zgeqlf" fun{t:t@ype} geqlf_exn {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= n} ( pfa: GEMAT (t, m, n, lda) @ la , pftau: array_v (t, mn, ltau) | m: integer m, n: integer n , a: ptr la, lda: integer lda, tau: ptr ltau , work: &(@[t?][lwork]), lwork: integer lwork ) : ( QLMAT_v (t, m, n, mn, lda, la, ltau) | void ) // end of [geqlf_exn] fun{t:t@ype} geqlf_work_query {m,n:nat} ( m: integer m, n: integer n ) :<> [lwork:int | lwork >= n] integer (lwork) (* ****** ****** *) // // ormql: S, D and unmql: C, Z // (* // taken from [clapack.h] /* Subroutine */ int cunmql_( char *side , char *trans , integer *m, integer *n, integer *k , complex *a, integer *lda , complex *tau , complex *c__, integer *ldc , complex *work, integer *lwork , integer *info ) ; *) typedef unmql_type (t:t@ype) = {m,n,k:nat} {ma,na:int} // k <= min (ma,na) {lda,ldc:inc} {lr:side} {tr:transpose} {lwork:pos | lwork >= m+n-ma} {la,ltau:addr} ( (*pf:*) sidedim_p (lr, m, n, ma) , (*qlmat*) !QLMAT_v (t, ma, na, k, lda, la, ltau) | (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer m, (*n:*) integer n, (*k:*) integer k , (*a:*) ptr la, (*lda:*) integer lda, (*tau:*) ptr ltau , (*c__:*) &GEMAT (t, m, n, ldc), (*ldc:*) integer ldc , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - int // end of [unmql_type] stadef ormql_type = unmql_type fun{t:t@ype} ormql: ormql_type (t) fun sormql: ormql_type (real) = "atsctrb_clapack_sormql" fun dormql: ormql_type (doublereal) = "atsctrb_clapack_dormql" fun{t:t@ype} unmql: unmql_type (t) fun cunmql: unmql_type (complex) = "atsctrb_clapack_cunmql" fun zunmql: unmql_type (doublecomplex) = "atsctrb_clapack_zunmql" fun{t:t@ype} ormql_work_query {m,n,k:pos} {ma:nat | k <= ma} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, ma) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-ma] integer (lwork) // end of [ormql_work_query] fun{t:t@ype} unmql_work_query {m,n,k:pos} {ma:nat | k <= ma} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, ma) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-ma] integer (lwork) // end of [unmql_work_query] (* ****** ****** *) absview QRMAT_err_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr , err:int ) // end of [absview] prfun QRMAT_err_v_elim {a:t@ype} {m,n,k:int} {lda:int} {la,ltau:addr} {err:int} ( pfqr: QRMAT_err_v (a, m, n, k, lda, la, ltau, err) ) : ( GEMAT (a?, m, n, lda) @ la, array_v (a, k, ltau) ) // end of [QRMAT_err_v_elim] viewdef QRMAT_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr ) = QRMAT_err_v (a, m, n, k, lda, la, ltau, 0(*succ*)) prfun TRMAT_v_of_QRMAT_v {a:t@ype} {m,n,k:nat | m >= n} {lda:inc} {la,ltau:addr} ( pf_qrmat: QRMAT_v (a, m, n, k, lda, la, ltau) ) : ( $GA.TRMAT_v (a, n, col, upper, nonunit, lda, la) , $GA.TRMAT_v (a, n, col, upper, nonunit, lda, la) - QRMAT_v (a, m, n, k, lda, la, ltau) ) // end of [TRMAT_v_of_QRMAT_v] (* ****** ****** *) // geqrf: S, D, C, Z (* /* Subroutine */ int dgeqrf_( integer *m, integer *n , doublereal *a, integer *lda , doublereal *tau , doublereal *work, integer *lwork , integer *info ) ; *) typedef geqrf_type (t:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= n} ( GEMAT (t, m, n, lda) @ la // a , array_v (t?, mn, ltau) // tau | integer m , integer n , ptr la, integer lda // a, lda , ptr ltau // tau , &(@[t?][lwork]), integer lwork ) - [err:int] ( QRMAT_err_v (t, m, n, mn, lda, la, ltau, err) | int err ) // end of [geqrf_type] fun{t:t@ype} geqrf: geqrf_type (t) fun sgeqrf: geqrf_type (real) = "atsctrb_clapack_sgeqrf" fun dgeqrf: geqrf_type (doublereal) = "atsctrb_clapack_dgeqrf" fun cgeqrf: geqrf_type (complex) = "atsctrb_clapack_cgeqrf" fun zgeqrf: geqrf_type (doublecomplex) = "atsctrb_clapack_zgeqrf" fun{t:t@ype} geqrf_exn {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= n} ( pfa: GEMAT (t, m, n, lda) @ la , pftau: array_v (t, mn, ltau) | m: integer m, n: integer n , a: ptr la, lda: integer lda, tau: ptr ltau , work: &(@[t?][lwork]), lwork: integer lwork ) : ( QRMAT_v (t, m, n, mn, lda, la, ltau) | void ) // end of [geqrf_exn] fun{t:t@ype} geqrf_work_query {m,n:nat} (m: integer m, n: integer n) :<> [lwork:int | lwork >= n] integer lwork (* ****** ****** *) typedef unmqr_type (t:t@ype) = {m,n,k:nat} {ma,na:int} // k <= min (ma, na) {lda,ldc:inc} {lr:side} {tr:transpose} {lwork:pos | lwork >= m+n-ma} {la,ltau:addr} ( (*pf:*) sidedim_p (lr, m, n, ma) , (*qrmat*) !QRMAT_v (t, ma, na, k, lda, la, ltau) | (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer m, (*n:*) integer n, (*k:*) integer k , (*a:*) ptr la, (*lda:*) integer lda, (*tau:*) ptr ltau , (*c:*) &GEMAT (t, m, n, ldc), (*ldc:*) integer ldc , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - int // end of [unmqr_type] stadef ormqr_type = unmqr_type fun{t:t@ype} ormqr: ormqr_type (t) fun sormqr: ormqr_type (real) = "atsctrb_clapack_sormqr" fun dormqr: ormqr_type (doublereal) = "atsctrb_clapack_dormqr" fun{t:t@ype} unmqr: unmqr_type (t) fun cunmqr: unmqr_type (complex) = "atsctrb_clapack_cunmqr" fun zunmqr: unmqr_type (doublecomplex) = "atsctrb_clapack_zunmqr" fun{t:t@ype} ormqr_work_query {m,n,k:pos} {ma:nat | k <= ma} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, ma) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-ma] integer (lwork) // end of [ormqr_work_query] fun{t:t@ype} unmqr_work_query {m,n,k:pos} {ma:nat | k <= ma} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, ma) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-ma] integer (lwork) // end of [unmqr_work_query] (* ****** ****** *) absview RQMAT_err_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr , err:int ) // end of [absview] prfun RQMAT_err_v_elim {a:t@ype} {m,n,k:int} {lda:int} {la,ltau:addr} {err:int} ( pfrq: RQMAT_err_v (a, m, n, k, lda, la, ltau, err) ) : ( GEMAT (a?, m, n, lda) @ la, array_v (a, k, ltau) ) // end of [RQMAT_err_v_elim] viewdef RQMAT_v ( a: t@ype, m: int, n: int, k:int, lda: int, la:addr, ltau:addr ) = RQMAT_err_v (a, m, n, k, lda, la, ltau, 0(*succ*)) prfun TRMAT_v_of_RQMAT_v {a:t@ype} {m,n,k:nat | m <= n} {lda:inc} {la,ltau:addr} {ofs1,ofs:int} ( pf_mul1: MUL (n-m, lda, ofs1) , pf_mul: MUL (ofs1, sizeof a, ofs) , pf_rqmat: RQMAT_v (a, m, n, k, lda, la, ltau) ) : ( $GA.TRMAT_v (a, m, col, upper, nonunit, lda, la+ofs) , $GA.TRMAT_v (a, m, col, upper, nonunit, lda, la+ofs) - RQMAT_v (a, m, n, k, lda, la, ltau) ) // end of [TRMAT_v_of_RQMAT_v] fun{a:t@ype} TRMAT_of_RQMAT {m,n,k:nat | m <= n} {lda:inc} {la,ltau:addr} {ofs:int} ( pf_rqmat: RQMAT_v (a, m, n, k, lda, la, ltau) | m: integer m, n: integer n, lda: integer lda, pa: ptr la ) :<> [l:addr] ( $GA.TRMAT_v (a, m, col, upper, nonunit, lda, l) , $GA.TRMAT_v (a, m, col, upper, nonunit, lda, l) - RQMAT_v (a, m, n, k, lda, la, ltau) | ptr l ) // end of [TRMAT_of_RQMAT] (* ****** ****** *) // // gerqf: S, D, C, Z // (* /* Subroutine */ int dgerqf_( integer *m, integer *n , doublereal *a, integer *lda , doublereal *tau , doublereal *work, integer *lwork , integer *info ) ; *) typedef gerqf_type (t:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= m} ( (*a*) GEMAT (t, m, n, lda) @ la , (*tau*) array_v (t?, mn, ltau) | (*m:*) integer m, (*n:*) integer n , (*a:*) ptr la, (*lda:*) integer lda, (*tau :*) ptr ltau , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - [err:int] ( RQMAT_err_v (t, m, n, mn, lda, la, ltau, err) | int err ) // end of [gerqf_type] fun{t:t@ype} gerqf: gerqf_type (t) fun sgerqf: gerqf_type (real) = "atsctrb_clapack_sgerqf" fun dgerqf: gerqf_type (doublereal) = "atsctrb_clapack_dgerqf" fun cgerqf: gerqf_type (complex) = "atsctrb_clapack_cgerqf" fun zgerqf: gerqf_type (doublecomplex) = "atsctrb_clapack_zgerqf" fun{t:t@ype} gerqf_exn {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la,ltau:addr} {lwork:pos | lwork >= m} ( pfa: GEMAT (t, m, n, lda) @ la , pftau: array_v (t, mn, ltau) | m: integer m, n: integer n , a: ptr la, lda: integer lda, tau: ptr ltau , work: &(@[t?][lwork]), lwork: integer lwork ) : ( RQMAT_v (t, m, n, mn, lda, la, ltau) | void ) // end of [gerqf_exn] fun{t:t@ype} gerqf_work_query {m,n:nat} (m: integer m, n: integer n) :<> [lwork:int | lwork >= m] integer lwork // end of [fun] (* ****** ****** *) // // unmrq: C, Z // (* /* Subroutine */ int cunmrq_( char *side , char *trans , integer *m, integer *n, integer *k , complex *a, integer *lda , complex *tau , complex *c__, integer *ldc , complex *work, integer *lwork , integer *info ) ; *) typedef unmrq_type (t:t@ype) = {m,n,k:nat} {ma,na:int} // na >= k {lda,ldc:inc} {lr:side} {tr:transpose} {lwork:pos | lwork >= m+n-na} {la,ltau:addr} ( (*pf:*) sidedim_p (lr, m, n, na) , (*rqmat*) !RQMAT_v (t, ma, na, k, lda, la, ltau) | (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer m, (*n:*) integer n, (*k:*) integer k , (*a:*) ptr la, (*lda:*) integer lda, (*tau:*) ptr ltau , (*c__:*) &GEMAT (t, m, n, ldc), (*ldc:*) integer ldc , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - int // end of [unmrq_type] stadef ormrq_type = unmrq_type fun{t:t@ype} unmrq: unmrq_type (t) fun cunmrq: unmrq_type (complex) = "atsctrb_clapack_cunmrq" fun zunmrq: unmrq_type (doublecomplex) = "atsctrb_clapack_zunmrq" fun{t:t@ype} ormrq: ormrq_type (t) fun sormrq: ormrq_type (real) = "atsctrb_clapack_sormrq" fun dormrq: ormrq_type (doublereal) = "atsctrb_clapack_dormrq" fun{t:t@ype} ormrq_work_query {m,n,k:pos} {na:nat | k <= na} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, na) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-na] integer (lwork) // end of [ormrq_work_query] fun{t:t@ype} unmrq_work_query {m,n,k:pos} {na:nat | k <= na} {lr:side} {tr:transpose} ( pf: sidedim_p (lr, m, n, na) | side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k ) :<> [lwork:pos | lwork >= m+n-na] integer (lwork) // end of [unmrq_work_query] (* ****** ****** *) // gels: S, D, C, Z (* /* Subroutine */ int dgels_( char *trans , integer *m, integer *n , integer *nrhs , doublereal *a, integer *lda , doublereal *b, integer *ldb , doublereal *work, integer *lwork , integer *info ) ; *) (* ** lwork >= 1 ** lwork >= 2*min (m,n) ** lwork >= min (m,n) + nrhs *) absprop gels_lwork_p (tr: transpose, m: int, n: int, nrhs: int, lwork: int) // making the relation abstract // end of [absprop] prfun lemma_gels_lwork {tr:transpose} // implemented in [clapack.dats] {m,n,nrhs,lwork:nat | lwork >= 1; lwork >= 2*min(m,n); lwork >= min(m,n) + nrhs} () : gels_lwork_p (tr, m, n, nrhs, lwork) // end of [lemma_gels_lwork] typedef gels_type (t:t@ype) = {tr:transpose} {m,n:nat} {nrhs:nat} {lda,ldb:inc} {lwork:pos} ( (*pf_lwork:*) gels_lwork_p (tr, m, n, nrhs, lwork) | (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer m, (*n:*) integer n, (*nrhs:*) integer nrhs , (*a:*) &GEMAT (t, m, n, lda) >> GEMAT (t?, m, n, lda) , (*lda:*) integer lda , (*b:*) &GEMAT (t, max(m,n), nrhs, ldb) , (*ldb:*) integer ldb , (*work:*) &(@[t?][lwork]), (*lwork:*) integer lwork ) - int // end of [gels_type] fun{t:t@ype} gels: gels_type (t) = "atsctrb_clapack_gels" fun sgels : gels_type (real) = "atsctrb_clapack_sgels" fun dgels : gels_type (doublereal) = "atsctrb_clapack_dgels" fun cgels : gels_type (complex) = "atsctrb_clapack_cgels" fun zgels : gels_type (doublecomplex) = "atsctrb_clapack_zgels" fun{t:t@ype} gels_work_query {tr:transpose} {m,n:pos} {nrhs:nat} ( trans: CLAPACK_TRANSPOSE_t tr, m: integer m, n: integer n, nrhs: integer nrhs ) :<> [lwork:pos] ( gels_lwork_p (tr, m, n, nrhs, lwork) | integer lwork ) // end of [gels_work_query] (* ****** ****** *) // trtrs: S, D, C, Z (* /* Subroutine */ int dtrtrs_( char *uplo , char *trans , char *diag , integer *n , integer *nrhs , doublereal *a, integer *lda , doublereal *b, integer *ldb , integer *info ) ; *) typedef trtrs_type (t:t@ype) = {ul:uplo} {tr:transpose} {dg:diag} {n:nat} {nrhs:nat} {lda,ldb:inc} ( (*uplo:*) CLAPACK_UPLO_t ul , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*diag:*) CLAPACK_DIAG_t dg , (*n:*) integer n, (*nrhs:*) integer nrhs , (*a:*) &TRMAT (t, n, ul, dg, lda), (*lda:*) integer lda , (*b:*) &GEMAT (t, n, nrhs, ldb), (*ldb:*) integer ldb ) - int // end of [trtrs_type] fun{t:t@ype} trtrs: trtrs_type (t) fun strtrs: trtrs_type (real) = "atsctrb_clapack_strtrs" fun dtrtrs: trtrs_type (doublereal) = "atsctrb_clapack_dtrtrs" fun ctrtrs: trtrs_type (complex) = "atsctrb_clapack_ctrtrs" fun ztrtrs: trtrs_type (doublecomplex) = "atsctrb_clapack_ztrtrs" (* ****** ****** *) absview LUMAT_err_v ( a: t@ype, m: int, n: int, lda: int, la:addr, err:int ) // end of [absview] prfun LUMAT_err_v_elim {a:t@ype} {m,n:int} {lda:int} {la:addr} {err:int} (pflu: LUMAT_err_v (a, m, n, lda, la, err)): GEMAT (a?, m, n, lda) @ la // end of [LUMAT_err_v_elim] prfun TRMAT_LU_v_of_LUMAT_v {a:t@ype} {m,n:nat | m <= n} {lda:inc} {la:addr} {err:nat} {ofs:int} ( pf_ofs: MUL (n, sizeof a, ofs) , pf_lumat: LUMAT_err_v (a, m, n, lda, la, err) ) : ( TRMAT (a, n, lower, unit, lda) @ la , TRMAT (a, m, lower, unit, lda) @ la - LUMAT_err_v (a, m, n, lda, la, err) ) // end of [TRMAT_LU_v_of_LUMAT_v] prfun TRMAT_UN_v_of_LUMAT_v {a:t@ype} {m,n:nat | m >= n} {lda:inc} {la:addr} {err:nat} ( pf_lumat: LUMAT_err_v (a, m, n, lda, la, err) ) : ( TRMAT (a, n, upper, nonunit, lda) @ la , TRMAT (a, n, upper, nonunit, lda) @ la - LUMAT_err_v (a, m, n, lda, la, err) ) // end of [TRMAT_UN_v_of_LUMAT_v] fun{a:t@ype} LUMAT_ptr_split_skinny {m,n:nat | m >= n} {lda:inc} {la:addr} {err:nat} ( pf_lumat: LUMAT_err_v (a, m, n, lda, la, err) | la: ptr la, m: size_t m, n: size_t n, lda: size_t lda ) :<> [la_ofs:addr] ( TRMAT (a, n, lower, unit, lda) @ la , TRMAT (a, n, upper, nonunit, lda) @ la , GEMAT (a, m-n, n, lda) @ la_ofs , ( TRMAT (a, n, lower, unit, lda) @ la , TRMAT (a, n, upper, nonunit, lda) @ la , GEMAT (a, m-n, n, lda) @ la_ofs ) - LUMAT_err_v (a, m, n, lda, la, err) | ptr la_ofs ) // end of [LUMAT_ptr_split_skinny] (* ****** ****** *) // getrf: S, D, C, Z (* /* Subroutine */ int dgetrf_( integer *m, integer *n , doublereal *a, integer *lda , integer *ipiv , integer *info ) ; *) // // SC-2010-11-16: // getrf computes LU factorization with row pivoting: A = P*L*U // The LU factors are overwritten on the input matrix A. // The view at A is changed to LUMAT_err_v to reflect this. // The original view at A can be recovered using LUMAT_err_v_elim. // The permutation is stored in ipiv. Note that this uses Fortran indices, // so 1 <= IPIV(i) <= m. // If the returned error code is < 0, then IPIV is still uninitialized and // so has no meaning. If the error code > 0, then the LU factorization did // finish, but the U has a zero diagonal in position indicated by the error // code (in Fortran index notation). // typedef getrf_type (t:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la:addr} ( (*a*) GEMAT (t, m, n, lda) @ la | (*m:*) integer m, (*n:*) integer n , (*a:*) ptr la, (*lda:*) integer lda , (*ipiv:*) &(@[integer?][mn]) >> @[integerBtwe(1,m)][mn] ) - [err:int] ( LUMAT_err_v (t, m, n, lda, la, err) | int err ) // end of [getrf_type] // fun{t:t@ype} getrf: getrf_type (t) fun sgetrf: getrf_type (real) = "atsctrb_clapack_sgetrf" fun dgetrf: getrf_type (doublereal) = "atsctrb_clapack_dgetrf" fun cgetrf: getrf_type (complex) = "atsctrb_clapack_cgetrf" fun zgetrf: getrf_type (doublecomplex) = "atsctrb_clapack_zgetrf" // // SC-2010-11-16: // getrf_exn is the same as getrf, except that it raises an exception // of error < 0. // fun{t:t@ype} getrf_exn {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {la:addr} ( pf: GEMAT (t, m, n, lda) @ la | m: integer m, n: integer n , a: ptr la, lda: integer lda , ipiv: &(@[integer?][mn]) >> @[integerBtwe(1,m)][mn] ) : [info:int | info >= 0] ( LUMAT_err_v (t, m, n, lda, la, info) | int info ) // end of [getrf_exn] (* ****** ****** *) // laswp: S, D, C, Z (* /* Subroutine */ int dlaswp_( integer *n , doublereal *a, integer *lda , integer *k1, integer *k2 , integer *ipiv , integer *incx ) ; *) typedef laswp_type (t:t@ype) = {m,n:nat} {lda:inc} {k1,k2:nat | k1 <= k2 && k2 <= m} {k:nat | k2 <= k} {incx:int | incx == 1 || incx == ~1} ( (*n:*) integer n , (*a:*) &GEMAT (t, m, n, lda), (*lda:*) integer lda , (*k1*) integer k1, (*k2*) integer k2 , (*ipiv:*) &(@[integer][k]) , (*incx*) integer incx ) -<> void // end of [laswp_type] // fun{t:t@ype} laswp: laswp_type (t) fun slaswp: laswp_type (real) = "atsctrb_clapack_slaswp" fun dlaswp: laswp_type (doublereal) = "atsctrb_clapack_dlaswp" fun claswp: laswp_type (complex) = "atsctrb_clapack_claswp" fun zlaswp: laswp_type (doublecomplex) = "atsctrb_clapack_zlaswp" (* ****** ****** *) // gesv: S, D, C, Z (* /* Subroutine */ int dgesv_ ( integer *n, integer *nrhs , doublereal *a, integer *lda , integer *ipiv , doublereal *b, integer *ldb , integer *info ) ; *) // // SC-2010-11-15: // A := P*L*U; So the view at A is changed to LUMAT_err_v. To get back the // original view (with uninitialized A) use LUMAT_err_v_elim. ipiv is // assigned P. The solution to A * x = b, is returned in b. A must be a // square matrix. // typedef gesv_type (t:t@ype) = {n,nrhs:nat} {lda,ldb:inc} {la:addr} ( (*a*) GEMAT (t, n, n, lda) @ la | (*n:*) integer n, (*nrhs:*) integer nrhs , (*a:*) ptr la, (*lda:*) integer lda , (*ipiv:*) &(@[integer?][n]) >> @[integerBtwe(1,n)][n] , (*b:*) &GEMAT (t, n, nrhs, ldb), (*ldb:*) integer ldb ) - [err:int] ( LUMAT_err_v (t, n, n, lda, la, err) | int err ) // end of [gesv_type] fun{t:t@ype} gesv: gesv_type (t) fun sgesv: gesv_type (real) = "atsctrb_clapack_sgesv" fun dgesv: gesv_type (doublereal) = "atsctrb_clapack_dgesv" fun cgesv: gesv_type (complex) = "atsctrb_clapack_cgesv" fun zgesv: gesv_type (doublecomplex) = "atsctrb_clapack_zgesv" (* ****** ****** *) (* /* Subroutine */ int dgesvd_( char *jobu, char *jobvt , integer *m, integer *n , doublereal *a, integer *lda , doublereal *s , doublereal *u, integer *ldu , doublereal *vt, integer *ldvt , doublereal *work, integer *lwork , integer *info ) ; *) (* ****** ****** *) // gesvd: full SVD // JOBU = 'A' and JOBVT = 'A') (* ** lwork >= 1 ** lwork >= 3*min(m,n) + m ** lwork >= 3*min(m,n) + n ** lwork >= 5*min(m,n) *) absprop gesvd_lwork_p (m:int, n:int, lwork:int) prfun lemma_gesvd_lwork // implemented in [clapack.dats] { m, n, lwork : nat | lwork >= 1 ; lwork >= 3*min(m,n) + max(m,n) ; lwork >= 5*min(m,n) } () : gesvd_lwork_p (m,n,lwork) // end of [lemma_gesvd_lwork] (* ** Full SVD *) typedef gesvd_type (t1:t@ype, t2:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda,ldu,ldvt:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , (*lda:*) integer lda , (*s:*) &(@[t2?][mn]) >> @[t2][mn] , (*u:*) &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , (*ldu:*) integer ldu , (*vt:*) &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , (*ldvt:*) integer ldvt , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_type] fun{t1,t2:t@ype} gesvd: gesvd_type (t1, t2) fun{t1,t2:t@ype} gesvd_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_work_query] (* ****** ****** *) (* ** Econonmy SVD *) typedef gesvd_econ_type (t1:t@ype, t2:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda,ldu,ldvt:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , (*lda:*) integer lda , (*s:*) &(@[t2?][mn]) >> @[t2][mn] , (*u:*) &(GEMAT (t1?, m, mn, ldu)) >> GEMAT (t1, m, mn, ldu) , (*ldu:*) integer ldu , (*vt:*) &(GEMAT (t1?, mn, n, ldvt)) >> GEMAT (t1, mn, n, ldvt) , (*ldvt:*) integer ldvt , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_econ_type] fun{t1,t2:t@ype} gesvd_econ: gesvd_econ_type (t1, t2) fun{t1,t2:t@ype} gesvd_econ_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_econ_work_query] (* ****** ****** *) (* ** Singular values only *) typedef gesvd_sing_type (t1:t@ype, t2:t@ype) = {m,n:nat} {mn:int | mn==min(m,n)} {lda:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , (*lda:*) integer lda , (*s:*) &(@[t2?][mn]) >> @[t2][mn] , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_sing_type] fun{t1,t2:t@ype} gesvd_sing: gesvd_sing_type (t1, t2) fun{t1,t2:t@ype} gesvd_sing_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_sing_work_query] (* ****** ****** *) (* ** Singular values and left singular vectors only: A -> U *) typedef gesvd_left_type (t1:t@ype, t2:t@ype) = {m,n:nat | m >= n} {lda:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) , (*lda:*) integer lda , (*s:*) &(@[t2?][n]) >> @[t2][n] , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_left_type] fun{t1,t2:t@ype} gesvd_left: gesvd_left_type (t1, t2) fun{t1,t2:t@ype} gesvd_left_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_left_work_query] (* ****** ****** *) (* ** Singular values and right singular vectors only: A -> VT *) typedef gesvd_right_type (t1:t@ype, t2:t@ype) = {m,n:nat | m <= n} {lda:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) , (*lda:*) integer lda , (*s:*) &(@[t2?][m]) >> @[t2][m] , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_right_type] fun{t1,t2:t@ype} gesvd_right: gesvd_right_type (t1, t2) fun{t1,t2:t@ype} gesvd_right_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_right_work_query] (* ****** ****** *) (* ** Economy SVD of skinny matrices: A -> U *) typedef gesvd_skinny_type (t1:t@ype, t2:t@ype) = {m,n:nat | m >= n} {lda,ldvt:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) , (*lda:*) integer lda , (*s:*) &(@[t2?][n]) >> @[t2][n] , (*vt:*) &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , (*ldvt:*) integer ldvt , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_skinny_type] fun{t1,t2:t@ype} gesvd_skinny: gesvd_skinny_type (t1, t2) fun{t1,t2:t@ype} gesvd_skinny_work_query {m,n:pos | m >= n} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_skinny_work_query] (* ****** ****** *) (* ** Only S and VT of skinny matrix *) fun{t1,t2:t@ype} gesvd_skinny_right {m,n:nat | m >= n} {lda,ldvt:inc} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | m: integer m , n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT (t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][n]) >> @[t2][n] , vt: &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , ldvt: integer ldvt , work: &(@[t1?][lwork]) , lwork: integer lwork ) :<> int // end of [gesvd_skinny_right] fun{t1,t2:t@ype} gesvd_skinny_right_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_skinny_right_work_query] (* ****** ****** *) (* ** Economy SVD of fat matrices: A -> VT *) typedef gesvd_fat_type (t1:t@ype, t2:t@ype) = {m,n:nat | m <= n} {lda,ldu:inc} {lwork:pos} ( (*pf_lwork:*) gesvd_lwork_p (m, n, lwork) | (*m:*) integer m , (*n:*) integer n , (*a:*) &(GEMAT (t1, m, n, lda)) , (*lda:*) integer lda , (*s:*) &(@[t2?][m]) >> @[t2][m] , (*u:*) &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , (*ldu:*) integer ldu , (*work:*) &(@[t1?][lwork]) , (*lwork:*) integer lwork ) - int // end of [gesvd_fat_type] fun{t1,t2:t@ype} gesvd_fat: gesvd_fat_type (t1, t2) fun{t1,t2:t@ype} gesvd_fat_work_query {m,n:pos} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_fat_work_query] (* ****** ****** *) (* ** Only U and S of fat matrix *) fun{t1,t2:t@ype} gesvd_fat_left {m,n:nat | m <= n} {lda,ldu:inc} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | m: integer m , n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT (t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][m]) >> @[t2][m] , u: &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , ldu: integer ldu , work: &(@[t1?][lwork]) , lwork: integer lwork ) :<> int // end of [gesvd_fat_left] fun{t1,t2:t@ype} gesvd_fat_left_work_query {m,n:pos | m <= n} (m: integer m, n: integer n) :<> [lwork:pos] (gesvd_lwork_p (m, n, lwork) | integer lwork) // end of [gesvd_fat_left_work_query] (* ****** ****** *) (* end of [clapack.sats] *) ats-lang-anairiats-0.2.11/contrib/clapack/SATS/f2c.sats0000664000175000017500000002616512223166165021170 0ustar hwxihwxi(* ** ** A f2c (fortran-to-c) interface for ATS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "contrib/clapack/CATS/f2c.cats" %} // end of [%{#} (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) fun{t:t@ype} print_typ (): void fun{t:t@ype} print_elt (x: t): void (* ****** ****** *) fun{t:t@ype} of_int (x: int):<> t fun{t:t@ype} of_double (x: double):<> t (* ****** ****** *) fun{t1,t2:t@ype} abs (x: t1):<> t2 fun{t:t@ype} neg (x: t):<> t fun{t:t@ype} add (x1: t, x2: t):<> t fun{t:t@ype} sub (x1: t, x2: t):<> t fun{t:t@ype} mul (x1: t, x2: t):<> t fun{t:t@ype} div (x1: t, x2: t):<> t fun{t:t@ype} lt (x1: t, x2: t):<> bool fun{t:t@ype} lte (x1: t, x2: t):<> bool fun{t:t@ype} gt (x1: t, x2: t):<> bool fun{t:t@ype} gte (x1: t, x2: t):<> bool fun{t:t@ype} eq (x1: t, x2: t):<> bool fun{t:t@ype} neq (x1: t, x2: t):<> bool (* ****** ****** *) // // F2Creal = float // f2c.cats // abst@ype real = $extype"ats_float_type" castfn real_of_float (x: float):<> real castfn float_of_real (x: real):<> float fun abs_real (x: real):<> real fun neg_real (x: real):<> real overload ~ with neg_real fun add_real_real (x1: real, x2: real):<> real = "atsctrb_f2c_add_real_real" overload + with add_real_real fun sub_real_real (x1: real, x2: real):<> real = "atsctrb_f2c_sub_real_real" overload - with sub_real_real fun mul_real_real (x1: real, x2: real):<> real = "atsctrb_f2c_mul_real_real" overload * with mul_real_real fun div_real_real (x1: real, x2: real):<> real = "atsctrb_f2c_div_real_real" overload / with div_real_real fun lt_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_lt_real_real" overload < with lt_real_real fun lte_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_lte_real_real" overload <= with lte_real_real fun gt_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_gt_real_real" overload > with gt_real_real fun gte_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_gte_real_real" overload >= with gte_real_real fun eq_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_eq_real_real" overload = with eq_real_real fun neq_real_real (x1: real, x2: real):<> bool = "atsctrb_f2c_neq_real_real" overload <> with neq_real_real (* ****** ****** *) // F2Cdoublereal = double // f2c.cats abst@ype doublereal = $extype"ats_double_type" castfn doublereal_of_double (x: double):<> doublereal castfn double_of_doublereal (x: doublereal):<> double fun abs_doublereal (x: doublereal):<> doublereal fun neg_doublereal (x: doublereal):<> doublereal overload ~ with neg_doublereal fun add_doublereal_doublereal (x1: doublereal, x2: doublereal):<> doublereal = "atsctrb_f2c_add_doublereal_doublereal" overload + with add_doublereal_doublereal fun sub_doublereal_doublereal (x1: doublereal, x2: doublereal):<> doublereal = "atsctrb_f2c_sub_doublereal_doublereal" overload - with sub_doublereal_doublereal fun mul_doublereal_doublereal (x1: doublereal, x2: doublereal):<> doublereal = "atsctrb_f2c_mul_doublereal_doublereal" overload * with mul_doublereal_doublereal fun div_doublereal_doublereal (x1: doublereal, x2: doublereal):<> doublereal = "atsctrb_f2c_div_doublereal_doublereal" overload / with div_doublereal_doublereal fun lt_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_lt_doublereal_doublereal" overload < with lt_doublereal_doublereal fun lte_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_lte_doublereal_doublereal" overload <= with lte_doublereal_doublereal fun gt_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_gt_doublereal_doublereal" overload > with gt_doublereal_doublereal fun gte_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_gte_doublereal_doublereal" overload >= with gte_doublereal_doublereal fun eq_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_eq_doublereal_doublereal" overload = with eq_doublereal_doublereal fun neq_doublereal_doublereal (x1: doublereal, x2: doublereal):<> bool = "atsctrb_f2c_neq_doublereal_doublereal" overload <> with neq_doublereal_doublereal (* ****** ****** *) // // F2Ccomplex = ccmplx // f2c.cats // abst@ype complex = $extype"ats_fcomplex_type" castfn complex_of_ccmplx (x: ccmplx):<> complex = "atsctrb_f2c_complex_of_ccmplx" castfn ccmplx_of_complex (x: complex):<> ccmplx = "atsctrb_f2c_ccmplx_of_complex" fun abs_complex (x: complex):<> real fun neg_complex (x: complex):<> complex overload ~ with neg_complex fun add_complex_complex (x1: complex, x2: complex):<> complex = "atsctrb_f2c_add_complex_complex" overload + with add_complex_complex fun sub_complex_complex (x1: complex, x2: complex):<> complex = "atsctrb_f2c_sub_complex_complex" overload - with sub_complex_complex fun mul_complex_complex (x1: complex, x2: complex):<> complex = "atsctrb_f2c_mul_complex_complex" overload * with mul_complex_complex fun div_complex_complex (x1: complex, x2: complex):<> complex = "atsctrb_f2c_div_complex_complex" overload / with div_complex_complex fun eq_complex_complex (x1: complex, x2: complex):<> bool = "atsctrb_f2c_eq_complex_complex" overload = with eq_complex_complex fun neq_complex_complex (x1: complex, x2: complex):<> bool = "atsctrb_f2c_neq_complex_complex" overload <> with neq_complex_complex (* ****** ****** *) // // F2Cdoublecomplex = zcmplx // f2c.cats // abst@ype doublecomplex = $extype"ats_dcomplex_type" castfn doublecomplex_of_zcmplx (x: zcmplx):<> doublecomplex = "atsctrb_f2c_doublecomplex_of_zcmplx" castfn zcmplx_of_doublecomplex (x: doublecomplex):<> zcmplx = "atsctrb_f2c_zcmplx_of_doublecomplex" fun abs_doublecomplex (x: doublecomplex):<> doublereal fun neg_doublecomplex (x: doublecomplex):<> doublecomplex overload ~ with neg_doublecomplex fun add_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> doublecomplex = "atsctrb_f2c_add_doublecomplex_doublecomplex" overload + with add_doublecomplex_doublecomplex fun sub_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> doublecomplex = "atsctrb_f2c_sub_doublecomplex_doublecomplex" overload - with sub_doublecomplex_doublecomplex fun mul_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> doublecomplex = "atsctrb_f2c_mul_doublecomplex_doublecomplex" overload * with mul_doublecomplex_doublecomplex fun div_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> doublecomplex = "atsctrb_f2c_div_doublecomplex_doublecomplex" overload / with div_doublecomplex_doublecomplex fun eq_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> bool = "atsctrb_f2c_eq_doublecomplex_doublecomplex" overload = with eq_doublecomplex_doublecomplex fun neq_doublecomplex_doublecomplex (x1: doublecomplex, x2: doublecomplex):<> bool = "atsctrb_f2c_neq_doublecomplex_doublecomplex" overload <> with neq_doublecomplex_doublecomplex (* ****** ****** *) abst@ype integer (i: int) = $extype"F2Cinteger" // defined to be long int typedef integer = [i:int] integer (i) typedef integerGt (n:int) = [i:int | i > n] integer (i) typedef integerGte (n:int) = [i:int | i >= n] integer (i) typedef integerBtw (l:int, u:int) = [i:int | l <= i; i < u] integer (i) typedef integerBtwe (l:int, u:int) = [i:int | l <= i; i <= u] integer (i) castfn integer_of_lint (x: lint):<> integer castfn lint_of_integer (x: integer):<> lint castfn size1_of_integer {i:nat} (i: integer i):<> size_t (i) castfn integer_of_size1 {i:nat} (i: size_t i):<> integer (i) castfn ssize1_of_integer {i:int} (i: integer i):<> ssize_t (i) castfn integer_of_ssize1 {i:int} (i: ssize_t i):<> integer (i) fun integer_of_int1 {i:int} (i: int i):<> integer (i) = "atspre_lint_of_int" // end of [integer_of_int1] (* ****** ****** *) fun add_integer_integer {i,j:int} (i: integer i, j: integer j):<> integer (i+j) = "atsctrb_f2c_add_integer_integer" overload + with add_integer_integer fun add_int1_integer {i,j:int} (i: int i, j: integer j):<> integer (i+j) = "atsctrb_f2c_add_int1_integer" overload + with add_int1_integer fun add_integer_int1 {i,j:int} (i: integer i, j: int j):<> integer (i+j) = "atsctrb_f2c_add_integer_int1" overload + with add_integer_int1 fun sub_integer_integer {i,j:int} (i: integer i, j: integer j):<> integer (i-j) = "atsctrb_f2c_sub_integer_integer" overload - with sub_integer_integer fun mul_integer_integer {i,j:int} (i: integer i, j: integer j):<> [ij:int] integer ij = "atsctrb_f2c_mul_integer_integer" overload * with mul_integer_integer (* ****** ****** *) fun lt_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i < j) = "atsctrb_f2c_lt_integer_integer" overload < with lt_integer_integer fun lte_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i <= j) = "atsctrb_f2c_lte_integer_integer" overload <= with lte_integer_integer fun gt_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i < j) = "atsctrb_f2c_gt_integer_integer" overload > with gt_integer_integer fun gte_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i <= j) = "atsctrb_f2c_gte_integer_integer" overload >= with gte_integer_integer fun eq_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i == j) = "atsctrb_f2c_eq_integer_integer" overload = with eq_integer_integer fun neq_integer_integer {i,j:int} (i: integer i, j: integer j):<> bool (i <> j) = "atsctrb_f2c_eq_integer_integer" overload <> with neq_integer_integer (* ****** ****** *) fun max_integer_integer {i,j:int} (i: integer i, j: integer j):<> integer (max(i,j)) = "atsctrb_f2c_max_integer_integer" overload max with max_integer_integer fun min_integer_integer {i,j:int} (i: integer i, j: integer j):<> integer (min(i,j)) = "atsctrb_f2c_min_integer_integer" overload min with min_integer_integer (* ****** ****** *) fun fprint_integer (out: FILEref, i: integer): void fun print_integer (i: integer): void overload print with print_integer fun prerr_integer (i: integer): void overload prerr with prerr_integer (* ****** ****** *) fun{t:t@ype} to_integer (x: t):<> integer (* ****** ****** *) abst@ype uinteger (i:int) = $extype"F2Cuinteger" // defined to be unsigned long int typedef uinteger = [i:nat] uinteger (i) castfn uinteger_of_ulint (x: ulint):<> uinteger castfn ulint_of_uinteger (x: uinteger):<> ulint castfn size1_of_uinteger {i:nat} (i: uinteger i):<> size_t (i) castfn uinteger_of_size1 {i:nat} (i: size_t i):<> uinteger (i) fun uinteger_of_int1 {i:nat} (i: int i):<> integer (i) = "atspre_ulint_of_int" // end of [uinteger_of_int1] fun uinteger_of_uint1 {i:nat} (u: uint i):<> uinteger (i) = "atspre_ulint_of_uint" // end of [uinteger_of_uint1] (* ****** ****** *) fun fprint_uinteger (out: FILEref, u: uinteger): void fun print_uinteger (u: uinteger): void overload print with print_uinteger fun prerr_uinteger (u: uinteger): void overload prerr with prerr_uinteger (* ****** ****** *) (* end of [f2c.sats] *) ats-lang-anairiats-0.2.11/contrib/clapack/Makefile0000664000175000017500000000115712223166165020502 0ustar hwxihwxi# # API for clapack in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Author: Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) # Time: July, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall LIBFLAGS=-L/usr/lib/atlas ###### all: atsctrb_clapack.o clean ###### atsctrb_clapack.o: clapack_dats.o ld -r -o $@ clapack_dats.o ###### clapack_dats.o: DATS/clapack.dats $(ATSCC) $(LIBFLAGS) -o $@ -c DATS/clapack.dats ###### clean:: rm -f *_?ats.c *_?ats.o cleanall: clean rm -f atsctrb_clapack.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/clapack/DATS/0000700000175000017500000000000012223166165017555 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/DATS/clapack.dats0000664000175000017500000007660012223166165022055 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) staload "libats/SATS/genarrays.sats" (* ****** ****** *) staload "contrib/clapack/SATS/f2c.sats" staload "contrib/clapack/SATS/clapack.sats" (* ****** ****** *) (* // // implemented in [clapack.hats] // implement{t1,t2} lange_inf {m,n} (m, n, a, lda) = ans where { var norm: CLAPACK_NORM_t = ClapackNormInf val m_sz = size1_of_integer m val [l_arr:addr] (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {t2} (m_sz+1, sizeof) prval pf_work = langework_v_some {t2,'I',m+1,l_arr} (pf_arr) val ans = lange (pf_work | norm, m, n, a, lda, p_arr) prval langework_v_some pf_arr = pf_work val () = array_ptr_free {t2} (pf_gc, pf_arr | p_arr) } (* end of [lange_inf] *) *) (* ****** ****** *) local assume gels_lwork_p (tr:transpose, m:int, n:int, nrhs:int, lwork:int) = [lwork >= 1; lwork >= 2*min(m,n); lwork >= min(m,n) + nrhs] void // end of [assume] in // in of [local] implement lemma_gels_lwork () = () end // end of [local] // implement{t} gels (...) = ... // in [clapack.hats] implement{t} gels_work_query {tr} {m,n} {nrhs} (trans, m, n, nrhs) = let // extern fun{t:t@ype} __gels {tr: transpose} {m,n:pos} {nrhs:nat} ( trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, nrhs: integer nrhs , p_a: ptr null, lda: integer // >= m , p_b: ptr null, ldb: integer // >= max (m,n) , work: &t? >> t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gels" // val lda = m val ldb = max_integer_integer (m,n) // a bit arbitrary var work: t // uninitialized var lwork = integer_of_int1 (~1) // val info = __gels (trans, m, n, nrhs, null(*a*), lda, null(*b*), ldb, work, lwork) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gels_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // if [clapack_gels] is correct extern prfun lemma (): [lwork>0] gels_lwork_p (tr, m, n, nrhs, lwork) } // end of [prval] in (pf_lwork | lwork) end (* end of [gels_work_query] *) (* ****** ****** *) local assume gesvd_lwork_p (m:int, n:int, lwork:int) = [lwork >= 1; lwork >= 3*min(m,n)+max(m,n); lwork >= 5*min(m,n)] void // end of [assume] in // in of [local] implement lemma_gesvd_lwork () = () end // end of [local] (* ****** ****** *) implement{t1,t2} gesvd (pf_lwork | m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {mn:int | mn==min(m,n)} {lda,ldu,ldvt:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'A' , jobvt: char 'A' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][mn]) >> @[t2][mn] , u: &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , ldu: integer ldu , vt: &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , ldvt: integer ldvt , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd (pf_lwork | 'A', 'A', m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) end // end of [gesvd] // implement{t1,t2} // |t1| = t2 gesvd_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'A', jobvt: char 'A' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= n , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = m and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'A', 'A', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_work_query] (* ****** ****** *) implement{t1,t2} gesvd_econ (pf_lwork | m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {mn:int | mn==min(m,n)} {lda,ldu,ldvt:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'S' , jobvt: char 'S' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][mn]) >> @[t2][mn] , u: &(GEMAT (t1?, m, mn, ldu)) >> GEMAT (t1, m, mn, ldu) , ldu: integer ldu , vt: &(GEMAT (t1?, mn, n, ldvt)) >> GEMAT (t1, mn, n, ldvt) , ldvt: integer ldvt , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd (pf_lwork | 'S', 'S', m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) end // end of [gesvd_econ] // implement{t1,t2} // |t1| = t2 gesvd_econ_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'S', jobvt: char 'S' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= n , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = m and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'S', 'S', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_econ_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_econ_work_query] (* ****** ****** *) implement{t1,t2} gesvd_sing (pf_lwork | m, n, a, lda, s, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {mn:int | mn==min(m,n)} {lda:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'N' , jobvt: char 'N' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT(t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][mn]) >> @[t2][mn] , u: ptr null , ldu: integer , vt: ptr null , ldvt: integer , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'N', 'N', m, n, a, lda, s , null(*u*), integer_of_int1 1(*ldu*) , null(*vt*), integer_of_int1 1(*ldvt*) , work, lwork) end // end of [gesvd_sing] // implement{t1,t2} // |t1| = t2 gesvd_sing_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'N', jobvt: char 'N' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= 1 , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = integer_of_int1 1 and ldvt = integer_of_int1 1 var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'N', 'N', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_sing_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_sing_work_query] (* ****** ****** *) implement{t1,t2} gesvd_left (pf_lwork | m, n, a, lda, s, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'O' , jobvt: char 'N' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) , lda: integer lda , s: &(@[t2?][n]) >> @[t2][n] , u: ptr null , ldu: integer , vt: ptr null , ldvt: integer , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'O', 'N', m, n, a, lda, s , null(*u*), m(*ldu*) , null(*vt*), integer_of_int1 1(*ldvt*) , work, lwork) end // end of [gesvd_left] // implement{t1,t2} // |t1| = t2 gesvd_left_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'O', jobvt: char 'N' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = m and ldvt = integer_of_int1 1 var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'O', 'N', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_left_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_left_work_query] (* ****** ****** *) implement{t1,t2} gesvd_right (pf_lwork | m, n, a, lda, s, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'N' , jobvt: char 'O' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) , lda: integer lda , s: &(@[t2?][m]) >> @[t2][m] , u: ptr null , ldu: integer , vt: ptr null , ldvt: integer , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'N', 'O', m, n, a, lda, s , null(*u*), integer_of_int1 1(*ldu*) , null(*vt*), integer_of_int1 1(*ldvt*) , work, lwork) end // end of [gesvd_right] // implement{t1,t2} // |t1| = t2 gesvd_right_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'N', jobvt: char 'O' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= 1 , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = integer_of_int1 1 and ldvt = integer_of_int1 1 var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'N', 'O', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_right_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_right_work_query] (* ****** ****** *) implement{t1,t2} gesvd_skinny (pf_lwork | m, n, a, lda, s, vt, ldvt, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda,ldvt:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'O' , jobvt: char 'S' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) , lda: integer lda , s: &(@[t2?][n]) >> @[t2][n] , u: ptr null , ldu: integer , vt: &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , ldvt: integer ldvt , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'O', 'S', m, n, a, lda, s , null(*u*), integer_of_int1 1(*ldu*) , vt, ldvt , work, lwork) end // end of [gesvd_skinny] // implement{t1,t2} // |t1| = t2 gesvd_skinny_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'O', jobvt: char 'S' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = integer_of_int1 1 and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'O', 'S', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_skinny_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_skinny_work_query] (* ****** ****** *) implement{t1,t2} gesvd_skinny_right (pf_lwork | m, n, a, lda, s, vt, ldvt, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda,ldvt:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'N' , jobvt: char 'A' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT (t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][n]) >> @[t2][n] , u: ptr null , ldu: integer , vt: &(GEMAT (t1?, n, n, ldvt)) >> GEMAT (t1, n, n, ldvt) , ldvt: integer ldvt , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'N', 'A', m, n, a, lda, s , null(*u*), integer_of_int1 1(*ldu*) , vt, ldvt , work, lwork) end // end of [gesvd_skinny_right] // implement{t1,t2} // |t1| = t2 gesvd_skinny_right_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'N', jobvt: char 'A' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = integer_of_int1 1 and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'N', 'A', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_skinny_right_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_skinny_right_work_query] (* ****** ****** *) implement{t1,t2} gesvd_fat (pf_lwork | m, n, a, lda, s, u, ldu, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda,ldu:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'S' , jobvt: char 'O' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) , lda: integer lda , s: &(@[t2?][m]) >> @[t2][m] , u: &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , ldu: integer ldu , vt: ptr null , ldvt: integer , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'S', 'O', m, n, a, lda, s , u, ldu , null(*vt*), integer_of_int1 1(*ldvt*) , work, lwork) end // end of [gesvd_fat] // implement{t1,t2} // |t1| = t2 gesvd_fat_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'S', jobvt: char 'O' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = m and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'S', 'O', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_fat_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_fat_work_query] (* ****** ****** *) implement{t1,t2} gesvd_fat_left (pf_lwork | m, n, a, lda, s, u, ldu, work, lwork) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:nat} {lda,ldu:pos} {lwork:pos} ( pf_lwork: gesvd_lwork_p (m, n, lwork) | jobu: char 'A' , jobvt: char 'N' , m: integer m, n: integer n , a: &(GEMAT (t1, m, n, lda)) >> GEMAT (t1?, m, n, lda) , lda: integer lda , s: &(@[t2?][m]) >> @[t2][m] , u: &(GEMAT (t1?, m, m, ldu)) >> GEMAT (t1, m, m, ldu) , ldu: integer ldu , vt: ptr null , ldvt: integer , work: &(@[t1?][lwork]), lwork: integer lwork ) :<> int = "atsctrb_clapack_gesvd" // in __gesvd ( pf_lwork | 'A', 'N', m, n, a, lda, s , u, ldu , null(*vt*), integer_of_int1 1(*ldvt*) , work, lwork) end // end of [gesvd_fat_left] // implement{t1,t2} // |t1| = t2 gesvd_fat_left_work_query {m,n} (m, n) = let // extern fun{t1,t2:t@ype} __gesvd {m,n:pos} ( jobu: char 'A', jobvt: char 'N' , m: integer m, n: integer n , a: ptr null, lda: integer // >= m , s: ptr null , u: ptr null, ldu: integer // >= m , vt: ptr null, ldvt: integer // >= 1 , work: &t1? >> t1, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gesvd" // val lda = m and ldu = m and ldvt = n var work: t1 // uninitialized val lwork = integer_of_int1 (~1) val info = __gesvd ( 'A', 'N', m, n , null(*a*), lda, null(*s*), null(*u*), ldu, null(*vt*), ldvt , work, lwork ) // end of [val] val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [gesvd_fat_left_work_query]: failed\n"; exit (1) ) // end of [val] // val [lwork:int] lwork = to_integer (work) prval pf_lwork = lemma () where { // assume that [clapack_gesvd] is extern prfun lemma (): [lwork>0] gesvd_lwork_p (m, n, lwork) // correct } // end of [prval] in (pf_lwork | lwork) end // end of [gesvd_fat_left_work_query] (* ****** ****** *) implement{t} gelqf_work_query {m,n} (m, n) = let // extern fun{t:t@ype} __gelqf ( m: integer m, n: integer n , a: ptr null, lda: integer , ltau: ptr null, work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gelqf" // var work = of_double 0.0 val info = __gelqf (m, n, null, m, null, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK); [gelqf_work_query]: failed\n"; exit (1) ) val [lwork:int] lwork = to_integer (work) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m] () } in lwork end // of [gelqf_work_query] (* ****** ****** *) implement{t} ormlq_work_query {m,n,k} {na} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __ormlq ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_ormlq" // var work = of_double 0.0 val info = __ormlq (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [ormlq_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - na] () } in lwork end // end of [ormlq_work_query] implement{t} unmlq_work_query {m,n,k} {na} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __unmlq ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_unmlq" // var work = of_double 0.0 val info = __unmlq (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [unmlq_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - na] () } in lwork end // end of [unmlq_work_query] (* ****** ****** *) implement{a} TRMAT_of_QLMAT (pf_qlmat | m, n, pa) = let val mn = sub_integer_integer (m, n) val mn = size1_of_integer (mn) val [ofs:int] (pf_mul | ofs) = mul2_size1_size1 (mn, sizeof) prval (pf_trmat, fpf_qlmat) = TRMAT_v_of_QLMAT_v {a} (pf_mul, pf_qlmat) in (pf_trmat, fpf_qlmat | pa + ofs) end // end of [TRMAT_of_QLMAT] implement{t} geqlf_work_query {m,n} (m, n) = let // extern fun{t:t@ype} __geqlf ( m: integer m, n: integer n , a: ptr null, lda: integer , ltau: ptr null, work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_geqlf" // var work = of_double 0.0 val info = __geqlf (m, n, null, m, null, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK); [geqlf_work_query]: failed\n"; exit (1) ) val [lwork:int] lwork = to_integer (work) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= n] () } in lwork end // of [geqlf_work_query] implement{t} ormql_work_query {m,n,k} {ma} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __ormql ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_ormql" // var work = of_double 0.0 val info = __ormql (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [ormql_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - ma] () } in lwork end // end of [ormql_work_query] implement{t} unmql_work_query {m,n,k} {ma} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __unmql ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_unmql" // var work = of_double 0.0 val info = __unmql (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [unmql_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - ma] () } in lwork end // end of [unmql_work_query] (* ****** ****** *) implement{t} geqrf_work_query {m,n} (m, n) = let // extern fun{t:t@ype} __geqrf ( m: integer m, n: integer n , a: ptr null, lda: integer , ltau: ptr null, work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_geqrf" // var work = of_double 0.0 val info = __geqrf (m, n, null, m, null, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK); [geqrf_work_query]: failed\n"; exit (1) ) val [lwork:int] lwork = to_integer (work) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= n] () } in lwork end // of [geqrf_work_query] implement{t} ormqr_work_query {m,n,k} {ma} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __ormqr ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_ormqr" // var work = of_double 0.0 val info = __ormqr (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [ormqr_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - ma] () } in lwork end // end of [ormqr_work_query] implement{t} unmqr_work_query {m,n,k} {ma} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __unmqr ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_unmqr" // var work = of_double 0.0 val info = __unmqr (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [unmqr_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - ma] () } in lwork end // end of [unmqr_work_query] (* ****** ****** *) implement{a} TRMAT_of_RQMAT (pf_rqmat | m, n, lda, pa) = let val nm = sub_integer_integer (n, m) val nm = size1_of_integer (nm) val lda_ = size1_of_integer (lda) val [ofs1:int] (pf_mul1 | ofs1) = mul2_size1_size1 (nm, lda_) prval () = mul_nat_nat_nat (pf_mul1) val [ofs:int] (pf_mul | ofs) = mul2_size1_size1 (ofs1, sizeof) prval (pf_trmat, fpf_rqmat) = TRMAT_v_of_RQMAT_v {a} ( pf_mul1, pf_mul, pf_rqmat ) in (pf_trmat, fpf_rqmat | pa + ofs) end // end of [TRMAT_of_RQMAT] implement{t} gerqf_work_query {m,n} (m, n) = let // extern fun{t:t@ype} __gerqf ( m: integer m, n: integer n , a: ptr null, lda: integer , ltau: ptr null, work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_gerqf" // var work = of_double 0.0 val info = __gerqf (m, n, null, m, null, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK); [gerqf_work_query]: failed\n"; exit (1) ) val [lwork:int] lwork = to_integer (work) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m] () } in lwork end // of [gerqf_work_query] implement{t} ormrq_work_query {m,n,k} {na} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __ormrq ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_ormrq" // var work = of_double 0.0 val info = __ormrq (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [ormrq_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - na] () } in lwork end // end of [ormrq_work_query] implement{t} unmrq_work_query {m,n,k} {na} {lr} {tr} (pf | side, trans, m, n, k) = let // extern fun{t:t@ype} __unmrq ( side: CLAPACK_SIDE_t lr, trans: CLAPACK_TRANSPOSE_t tr , m: integer m, n: integer n, k: integer k , a: ptr null, lda: integer, tau: ptr null , c: ptr null, ldc: integer , work: &t, lwork: integer (~1) ) :<> int = "atsctrb_clapack_unmrq" // var work = of_double 0.0 val info = __unmrq (side, trans, m, n, k, null, m, null, null, m, work, integer_of_int1 (~1)) val () = if info < 0 then $effmask_all ( prerr "exit(ATS/CLAPACK): [unmrq_work_query]: failed\n"; exit (1) ) // end of [val] val [lwork:int] lwork = to_integer (work) (* val () = $effmask_exn (assert (lwork >= m+n-k && lwork > integer_of_int1 0)) *) prval pf = lemma_lwork () where { extern prfun lemma_lwork () : [lwork > 0 && lwork >= m + n - na] () } in lwork end // end of [unmrq_work_query] (* ****** ****** *) implement{a} LUMAT_ptr_split_skinny {m,n} {lda} {la} {err} (pf_lumat | la, m, n, lda) = let val ofs = (n * sizeof): size_t val [ofs:int] ofs = size1_of_size ofs viewdef L = TRMAT (a, n, lower, unit, lda) @ la viewdef U = TRMAT (a, n, upper, nonunit, lda) @ la viewdef MAT = GEMAT (a, m-n, n, lda) @ la + ofs viewdef LUMAT = LUMAT_err_v (a, m, n, lda, la, err) prval (pf_l, pf_u, pf_mat, fpf_lumat) = __lemma (pf_lumat) where { extern prfun __lemma (pf: LUMAT): (L, U, MAT, (L, U, MAT) - LUMAT) } // end of [prval] in (pf_l, pf_u, pf_mat, fpf_lumat | la + ofs) end // of [LUMAT_ptr_split_skinny] (* ****** ****** *) (* end of [clapack.dats] *) ats-lang-anairiats-0.2.11/contrib/clapack/DATS/f2c.dats0000664000175000017500000000206212223166165021120 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) staload "contrib/clapack/SATS/f2c.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynloading at run-time (* ****** ****** *) implement fprint_integer (out, i) = let val i = lint_of_integer i // no-op casting in fprint_lint (out, i) end // end of [fprint_integer] implement print_integer (i) = fprint_integer (stdout_ref, i) implement prerr_integer (i) = fprint_integer (stderr_ref, i) (* ****** ****** *) implement fprint_uinteger (out, u) = let val u = ulint_of_uinteger u // no-op casting in fprint_ulint (out, u) end // end of [fprint_uinteger] implement print_uinteger (u) = fprint_uinteger (stdout_ref, u) implement prerr_uinteger (u) = fprint_uinteger (stderr_ref, u) (* ****** ****** *) (* end of [f2c.dats] *) ats-lang-anairiats-0.2.11/contrib/clapack/HATS/0000700000175000017500000000000012223166165017561 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/clapack/HATS/f2c.hats0000664000175000017500000001167512223166165021142 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) staload C = "libc/SATS/complex.sats" staload "contrib/clapack/SATS/f2c.sats" (* ****** ****** *) implement print_typ () = print "real" implement print_typ () = print "doublereal" implement print_typ () = print "complex" implement print_typ () = print "doublecomplex" implement print_elt (x) = print_float (float_of_real x) implement print_elt (x) = print_double (double_of_doublereal x) implement print_elt (x) = $C.print_ccmplx (ccmplx_of_complex x) implement print_elt (x) = $C.print_zcmplx (zcmplx_of_doublecomplex x) (* ****** ****** *) implement of_int (x) = (real_of_float (float_of_int x)) implement of_int (x) = doublereal_of_double (double_of_int x) implement of_int (x) = complex_of_ccmplx ($C.ccmplx_of_int x) implement of_int (x) = doublecomplex_of_zcmplx ($C.zcmplx_of_int x) implement of_double (x) = real_of_float (float_of_double x) implement of_double (x) = doublereal_of_double (x) implement of_double (x) = complex_of_ccmplx ($C.ccmplx_of_float (float_of_double x)) implement of_double (x) = doublecomplex_of_zcmplx ($C.zcmplx_of_double x) (* ****** ****** *) implement abs (x) = abs_real (x) implement abs (x) = abs_doublereal (x) implement abs (x) = abs_complex (x) implement abs (x) = abs_doublecomplex (x) (* ****** ****** *) implement neg (x) = neg_real (x) implement neg (x) = neg_doublereal (x) implement neg (x) = neg_complex (x) implement neg (x) = neg_doublecomplex (x) (* ****** ****** *) implement add (x1, x2) = add_real_real (x1, x2) implement add (x1, x2) = add_doublereal_doublereal (x1, x2) implement add (x1, x2) = add_complex_complex (x1, x2) implement add (x1, x2) = add_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement sub (x1, x2) = sub_real_real (x1, x2) implement sub (x1, x2) = sub_doublereal_doublereal (x1, x2) implement sub (x1, x2) = sub_complex_complex (x1, x2) implement sub (x1, x2) = sub_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement mul (x1, x2) = mul_real_real (x1, x2) implement mul (x1, x2) = mul_doublereal_doublereal (x1, x2) implement mul (x1, x2) = mul_complex_complex (x1, x2) implement mul (x1, x2) = mul_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement div (x1, x2) = div_real_real (x1, x2) implement div (x1, x2) = div_doublereal_doublereal (x1, x2) implement div (x1, x2) = div_complex_complex (x1, x2) implement div (x1, x2) = div_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement lt (x1, x2) = lt_real_real (x1, x2) implement lt (x1, x2) = lt_doublereal_doublereal (x1, x2) (* ****** ****** *) implement lte (x1, x2) = lte_real_real (x1, x2) implement lte (x1, x2) = lte_doublereal_doublereal (x1, x2) (* ****** ****** *) implement gt (x1, x2) = gt_real_real (x1, x2) implement gt (x1, x2) = gt_doublereal_doublereal (x1, x2) (* ****** ****** *) implement gte (x1, x2) = gte_real_real (x1, x2) implement gte (x1, x2) = gte_doublereal_doublereal (x1, x2) (* ****** ****** *) implement eq (x1, x2) = eq_real_real (x1, x2) implement eq (x1, x2) = eq_doublereal_doublereal (x1, x2) implement eq (x1, x2) = eq_complex_complex (x1, x2) implement eq (x1, x2) = eq_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement neq (x1, x2) = neq_real_real (x1, x2) implement neq (x1, x2) = neq_doublereal_doublereal (x1, x2) implement neq (x1, x2) = neq_complex_complex (x1, x2) implement neq (x1, x2) = neq_doublecomplex_doublecomplex (x1, x2) (* ****** ****** *) implement to_integer (x) = integer_of_lint (lint_of_int x) // end of [to_integer] implement to_integer (x) = integer_of_lint (lint_of_float (float_of_real x)) // end of [to_integer] implement to_integer (x) = integer_of_lint (lint_of_double (double_of_doublereal x)) // end of [to_integer] implement to_integer (x) = integer_of_lint (lint_of_float ($C.crealf (ccmplx_of_complex x))) // end of [to_integer] implement to_integer (x) = integer_of_lint (lint_of_double ($C.creal (zcmplx_of_doublecomplex x))) // end of [to_integer] (* ****** ****** *) (* end of [f2c.hats] *) ats-lang-anairiats-0.2.11/contrib/clapack/HATS/clapack.hats0000664000175000017500000010526412223166165022064 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_CLAPACK_DEBUG 1 // for controlling some debugging code (* ****** ****** *) staload F2C = "contrib/clapack/SATS/f2c.sats" typedef integer (i:int) = $F2C.integer (i) typedef integer = $F2C.integer typedef real = $F2C.real typedef doublereal = $F2C.doublereal typedef complex = $F2C.complex typedef doublecomplex = $F2C.doublecomplex staload "contrib/clapack/SATS/clapack.sats" (* ****** ****** *) local typedef float = real typedef double = doublereal typedef ccmplx = complex typedef zcmplx = doublecomplex in // in of [local] (* ****** ****** *) // lamch: S, D implement lamch (cmach) = slamch (cmach) implement lamch (cmach) = dlamch (cmach) implement lamch_eps () = slamch ('E') implement lamch_sfmin () = slamch ('S') implement lamch_base () = slamch ('B') implement lamch_prec () = slamch ('P') implement lamch_t () = slamch ('N') implement lamch_rnd () = slamch ('R') implement lamch_emin () = slamch ('M') implement lamch_rmin () = slamch ('U') implement lamch_emax () = slamch ('L') implement lamch_rmax () = slamch ('O') implement lamch_eps () = dlamch ('E') implement lamch_sfmin () = dlamch ('S') implement lamch_base () = dlamch ('B') implement lamch_prec () = dlamch ('P') implement lamch_t () = dlamch ('N') implement lamch_rnd () = dlamch ('R') implement lamch_emin () = dlamch ('M') implement lamch_rmin () = dlamch ('U') implement lamch_emax () = dlamch ('L') implement lamch_rmax () = dlamch ('O') (* ****** ****** *) // lange: S, D, C, Z implement lange (pf | norm, m, n, a, lda, work) = slange (pf | norm, m, n, a, lda, work) // end of [lange] implement lange (pf | norm, m, n, a, lda, work) = dlange (pf | norm, m, n, a, lda, work) // end of [lange] implement lange (pf | norm, m, n, a, lda, work) = clange (pf | norm, m, n, a, lda, work) // end of [lange] implement lange (pf | norm, m, n, a, lda, work) = zlange (pf | norm, m, n, a, lda, work) // end of [lange] (* ****** ****** *) // lange_inf: S, D, C, Z implement{t1,t2} lange_inf {m,n} {lda} {m1} (m, n, a, lda, work) = let stavar l_work: addr val p_work: ptr l_work = &work prval pf_work = view@ work prval pf_lange = langework_v_some {t2,'I',m1,l_work} (pf_work) val res = lange (pf_lange | ClapackNormInf, m, n, a, lda, p_work) prval langework_v_some (pf_work) = pf_lange prval () = view@ work := pf_work in res end // end of [lange_inf] implement{t1,t2} lange_one {m,n} {lda} (m, n, a, lda) = let prval pf_lange = langework_v_none {t2, 'O', m+1, null} () val res = lange (pf_lange | ClapackNormOne, m, n, a, lda, null) prval langework_v_none () = pf_lange in res end // end of [lange_one] implement{t1,t2} lange_max {m,n} {lda} (m, n, a, lda) = let prval pf_lange = langework_v_none {t2, 'M', m+1, null} () val res = lange (pf_lange | ClapackNormMax, m, n, a, lda, null) prval langework_v_none () = pf_lange in res end // end of [lange_max] implement{t1,t2} lange_frob {m,n} {lda} (m, n, a, lda) = let prval pf_lange = langework_v_none {t2, 'F', m+1, null} () val res = lange (pf_lange | ClapackNormFrob, m, n, a, lda, null) prval langework_v_none () = pf_lange in res end // end of [lange_frob] (* ****** ****** *) // // lacpy: S, D, C, Z // implement lacpy (uln, m, n, a, lda, b, ldb) = slacpy (uln, m, n, a, lda, b, ldb) // end of [lacpy] implement lacpy (uln, m, n, a, lda, b, ldb) = dlacpy (uln, m, n, a, lda, b, ldb) // end of [lacpy] implement lacpy (uln, m, n, a, lda, b, ldb) = clacpy (uln, m, n, a, lda, b, ldb) // end of [lacpy] implement lacpy (uln, m, n, a, lda, b, ldb) = zlacpy (uln, m, n, a, lda, b, ldb) // end of [lacpy] (* ****** ****** *) implement gelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = sgelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gelqf] implement gelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = dgelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gelqf] implement gelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = cgelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gelqf] implement gelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = zgelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gelqf] implement{t} gelqf_exn (pfa, pftau | m, n, a, lda, tau, work, lwork) = let val [err:int] (pflq | info) = gelqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [val] // val () = $effmask_all (if (info <> 0) then begin prerr "exit(ATS/CLAPACK): [gelqf] failed."; prerr_newline (); exit (1) end) : [err==0] void // in (pflq | ()) end // end of [gelqf_exn] (* ****** ****** *) typedef gelqf_dummy_type (t:t@ype) = ( (*m:*) integer, (*n:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*work:*) ptr, (*lwork:*) integer ) - int extern fun{t:t@ype} gelqf_dummy: gelqf_dummy_type (t) = "atsctrb_clapack_gelqf" extern fun sgelqf_dummy: gelqf_dummy_type (float) = "atsctrb_clapack_sgelqf" extern fun dgelqf_dummy: gelqf_dummy_type (double) = "atsctrb_clapack_dgelqf" extern fun cgelqf_dummy: gelqf_dummy_type (ccmplx) = "atsctrb_clapack_cgelqf" extern fun zgelqf_dummy: gelqf_dummy_type (zcmplx) = "atsctrb_clapack_zgelqf" implement gelqf_dummy (m, n, a, lda, tau, work, lwork) = sgelqf_dummy (m, n, a, lda, tau, work, lwork) implement gelqf_dummy (m, n, a, lda, tau, work, lwork) = dgelqf_dummy (m, n, a, lda, tau, work, lwork) implement gelqf_dummy (m, n, a, lda, tau, work, lwork) = cgelqf_dummy (m, n, a, lda, tau, work, lwork) implement gelqf_dummy (m, n, a, lda, tau, work, lwork) = zgelqf_dummy (m, n, a, lda, tau, work, lwork) (* ****** ****** *) // ormlq: S, D (and unmlq: C, Z) implement ormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormlq] implement ormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormlq] implement ormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormlq] implement ormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormlq] // (ormlq: S, D) and unmlq: C, Z implement unmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmlq] implement unmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmlq] implement unmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmlq] implement unmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmlq (pfsd, pflq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmlq] (* ****** ****** *) typedef unmlq_dummy_type (t:t@ype) = {lr:side} {tr:transpose} ( (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer, (*n:*) integer, (*k:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*c:*) ptr, (*ldc:*) integer , (*work:*) ptr, (*lwork:*) integer ) - int stadef ormlq_dummy_type = unmlq_dummy_type extern fun{t:t@ype} ormlq_dummy: ormlq_dummy_type (t) = "atsctrb_clapack_ormlq" extern fun{t:t@ype} unmlq_dummy: unmlq_dummy_type (t) = "atsctrb_clapack_unmlq" extern fun sormlq_dummy: ormlq_dummy_type (float) = "atsctrb_clapack_sormlq" extern fun dormlq_dummy: ormlq_dummy_type (double) = "atsctrb_clapack_dormlq" extern fun cunmlq_dummy: unmlq_dummy_type (ccmplx) = "atsctrb_clapack_cunmlq" extern fun zunmlq_dummy: unmlq_dummy_type (zcmplx) = "atsctrb_clapack_zunmlq" // ormlq_dummy implement ormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // unmlq_dummy implement unmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormlq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) (* ****** ****** *) implement geqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) = sgeqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqlf] implement geqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) = dgeqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqlf] implement geqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) = cgeqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqlf] implement geqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) = zgeqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqlf] implement{t} geqlf_exn (pfa, pftau | m, n, a, lda, tau, work, lwork) = let val [err:int] (pfql | info) = geqlf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [val] // val () = $effmask_all (if (info <> 0) then begin prerr "exit(ATS/CLAPACK): [geqlf] failed."; prerr_newline (); exit (1) end) : [err==0] void // in (pfql | ()) end // end of [geqlf_exn] (* ****** ****** *) typedef geqlf_dummy_type (t:t@ype) = ( (*m:*) integer, (*n:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*work:*) ptr, (*lwork:*) integer ) - int extern fun{t:t@ype} geqlf_dummy: geqlf_dummy_type (t) = "atsctrb_clapack_geqlf" extern fun sgeqlf_dummy: geqlf_dummy_type (float) = "atsctrb_clapack_sgeqlf" extern fun dgeqlf_dummy: geqlf_dummy_type (double) = "atsctrb_clapack_dgeqlf" extern fun cgeqlf_dummy: geqlf_dummy_type (ccmplx) = "atsctrb_clapack_cgeqlf" extern fun zgeqlf_dummy: geqlf_dummy_type (zcmplx) = "atsctrb_clapack_zgeqlf" implement geqlf_dummy (m, n, a, lda, tau, work, lwork) = sgeqlf_dummy (m, n, a, lda, tau, work, lwork) implement geqlf_dummy (m, n, a, lda, tau, work, lwork) = dgeqlf_dummy (m, n, a, lda, tau, work, lwork) implement geqlf_dummy (m, n, a, lda, tau, work, lwork) = cgeqlf_dummy (m, n, a, lda, tau, work, lwork) implement geqlf_dummy (m, n, a, lda, tau, work, lwork) = zgeqlf_dummy (m, n, a, lda, tau, work, lwork) (* ****** ****** *) // ormql: S, D (and unmql: C, Z) implement ormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormql] implement ormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormql] implement ormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormql] implement ormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormql] // (ormql: S, D) and unmql: C, Z implement unmql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmql] implement unmql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormql (pfsd, pfql | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmql] implement unmql (pf, pfql | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = cunmql (pf, pfql | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmql] implement unmql (pf, pfql | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = zunmql (pf, pfql | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmql] (* ****** ****** *) (* ****** ****** *) typedef unmql_dummy_type (t:t@ype) = {lr:side} {tr:transpose} ( (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer, (*n:*) integer, (*k:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*c:*) ptr, (*ldc:*) integer , (*work:*) ptr, (*lwork:*) integer ) - int stadef ormql_dummy_type = unmql_dummy_type extern fun{t:t@ype} ormql_dummy: ormql_dummy_type (t) = "atsctrb_clapack_ormql" extern fun{t:t@ype} unmql_dummy: unmql_dummy_type (t) = "atsctrb_clapack_unmql" extern fun sormql_dummy: ormql_dummy_type (float) = "atsctrb_clapack_sormql" extern fun dormql_dummy: ormql_dummy_type (double) = "atsctrb_clapack_dormql" extern fun cunmql_dummy: unmql_dummy_type (ccmplx) = "atsctrb_clapack_cunmql" extern fun zunmql_dummy: unmql_dummy_type (zcmplx) = "atsctrb_clapack_zunmql" // ormql_dummy implement ormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // unmql_dummy implement unmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormql_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) (* ****** ****** *) implement geqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) = sgeqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqrf] implement geqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) = dgeqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqrf] implement geqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) = cgeqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqrf] implement geqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) = zgeqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [geqrf] implement{t} geqrf_exn (pfa, pftau | m, n, a, lda, tau, work, lwork) = let val [err:int] (pfqr | info) = geqrf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [val] // val () = $effmask_all (if (info <> 0) then begin prerr "exit(ATS/CLAPACK): [geqrf] failed."; prerr_newline (); exit (1) end) : [err==0] void // in (pfqr | ()) end // end of [geqrf_exn] (* ****** ****** *) typedef geqrf_dummy_type (t:t@ype) = ( (*m:*) integer, (*n:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*work:*) ptr, (*lwork:*) integer ) - int extern fun{t:t@ype} geqrf_dummy: geqrf_dummy_type (t) = "atsctrb_clapack_geqrf" extern fun sgeqrf_dummy: geqrf_dummy_type (float) = "atsctrb_clapack_sgeqrf" extern fun dgeqrf_dummy: geqrf_dummy_type (double) = "atsctrb_clapack_dgeqrf" extern fun cgeqrf_dummy: geqrf_dummy_type (ccmplx) = "atsctrb_clapack_cgeqrf" extern fun zgeqrf_dummy: geqrf_dummy_type (zcmplx) = "atsctrb_clapack_zgeqrf" implement geqrf_dummy (m, n, a, lda, tau, work, lwork) = sgeqrf_dummy (m, n, a, lda, tau, work, lwork) implement geqrf_dummy (m, n, a, lda, tau, work, lwork) = dgeqrf_dummy (m, n, a, lda, tau, work, lwork) implement geqrf_dummy (m, n, a, lda, tau, work, lwork) = cgeqrf_dummy (m, n, a, lda, tau, work, lwork) implement geqrf_dummy (m, n, a, lda, tau, work, lwork) = zgeqrf_dummy (m, n, a, lda, tau, work, lwork) (* ****** ****** *) // ormqr: S, D (and unmqr: C, Z) implement ormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormqr] implement ormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormqr] implement ormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormqr] implement ormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormqr] // unmqr: C, Z and (ormqr: S, D) implement unmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmqr] implement unmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmqr] implement unmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = cunmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmqr] implement unmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = zunmqr (pfsd, pfqr | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmqr] (* ****** ****** *) typedef unmqr_dummy_type (t:t@ype) = {lr:side} {tr:transpose} ( (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer, (*n:*) integer, (*k:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*c:*) ptr, (*ldc:*) integer , (*work:*) ptr, (*lwork:*) integer ) - int stadef ormqr_dummy_type = unmqr_dummy_type extern fun{t:t@ype} ormqr_dummy: ormqr_dummy_type (t) = "atsctrb_clapack_ormqr" extern fun{t:t@ype} unmqr_dummy: unmqr_dummy_type (t) = "atsctrb_clapack_unmqr" extern fun sormqr_dummy: ormqr_dummy_type (float) = "atsctrb_clapack_sormqr" extern fun dormqr_dummy: ormqr_dummy_type (double) = "atsctrb_clapack_dormqr" extern fun cunmqr_dummy: unmqr_dummy_type (ccmplx) = "atsctrb_clapack_cunmqr" extern fun zunmqr_dummy: unmqr_dummy_type (zcmplx) = "atsctrb_clapack_zunmqr" // ormqr_dummy implement ormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // unmqr_dummy implement unmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormqr_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) (* ****** ****** *) implement gerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = sgerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gerqf] implement gerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = dgerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gerqf] implement gerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = cgerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gerqf] implement gerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) = zgerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [gerqf] implement{t} gerqf_exn (pfa, pftau | m, n, a, lda, tau, work, lwork) = let val [err:int] (pfrq | info) = gerqf (pfa, pftau | m, n, a, lda, tau, work, lwork) // end of [val] // val () = $effmask_all (if (info <> 0) then begin prerr "exit(ATS/CLAPACK): [gerqf] failed."; prerr_newline (); exit (1) end) : [err==0] void // in (pfrq | ()) end // end of [gerqf_exn] (* ****** ****** *) typedef gerqf_dummy_type (t:t@ype) = ( (*m:*) integer, (*n:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*work:*) ptr, (*lwork:*) integer ) - int extern fun{t:t@ype} gerqf_dummy: gerqf_dummy_type (t) = "atsctrb_clapack_gerqf" extern fun sgerqf_dummy: gerqf_dummy_type (float) = "atsctrb_clapack_sgerqf" extern fun dgerqf_dummy: gerqf_dummy_type (double) = "atsctrb_clapack_dgerqf" extern fun cgerqf_dummy: gerqf_dummy_type (ccmplx) = "atsctrb_clapack_cgerqf" extern fun zgerqf_dummy: gerqf_dummy_type (zcmplx) = "atsctrb_clapack_zgerqf" implement gerqf_dummy (m, n, a, lda, tau, work, lwork) = sgerqf_dummy (m, n, a, lda, tau, work, lwork) implement gerqf_dummy (m, n, a, lda, tau, work, lwork) = dgerqf_dummy (m, n, a, lda, tau, work, lwork) implement gerqf_dummy (m, n, a, lda, tau, work, lwork) = cgerqf_dummy (m, n, a, lda, tau, work, lwork) implement gerqf_dummy (m, n, a, lda, tau, work, lwork) = zgerqf_dummy (m, n, a, lda, tau, work, lwork) (* ****** ****** *) implement ormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormrq] implement ormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormrq] implement ormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormrq] implement ormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [ormrq] implement unmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmrq] implement unmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // end of [unmrq] implement unmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = cunmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmrq] implement unmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) = zunmrq (pfsd, pfrq | side, trans, m, n, k, a, lda, tau, c__, ldc, work, lwork) // end of [unmrq] (* ****** ****** *) (* ****** ****** *) typedef unmrq_dummy_type (t:t@ype) = {lr:side} {tr:transpose} ( (*side:*) CLAPACK_SIDE_t lr , (*trans:*) CLAPACK_TRANSPOSE_t tr , (*m:*) integer, (*n:*) integer, (*k:*) integer , (*a:*) ptr, (*lda:*) integer, (*tau:*) ptr , (*c:*) ptr, (*ldc:*) integer , (*work:*) ptr, (*lwork:*) integer ) - int stadef ormrq_dummy_type = unmrq_dummy_type extern fun{t:t@ype} ormrq_dummy: ormrq_dummy_type (t) = "atsctrb_clapack_ormrq" extern fun{t:t@ype} unmrq_dummy: unmrq_dummy_type (t) = "atsctrb_clapack_unmrq" extern fun sormrq_dummy: ormrq_dummy_type (float) = "atsctrb_clapack_sormrq" extern fun dormrq_dummy: ormrq_dummy_type (double) = "atsctrb_clapack_dormrq" extern fun cunmrq_dummy: unmrq_dummy_type (ccmplx) = "atsctrb_clapack_cunmrq" extern fun zunmrq_dummy: unmrq_dummy_type (zcmplx) = "atsctrb_clapack_zunmrq" // ormrq_dummy implement ormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement ormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) // unmrq_dummy implement unmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = cunmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = zunmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = sormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) implement unmrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) = dormrq_dummy (side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork) (* ****** ****** *) (* /* Subroutine */ int dgels_( char *trans , integer *m, integer *n , integer *nrhs , doublereal *a, integer *lda , doublereal *b, integer *ldb , doublereal *work, integer *lwork , integer *info ) ; *) // gels: S, D, C, Z implement gels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) = sgels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) // end of [gels] implement gels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) = dgels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) // end of [gels] implement gels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) = cgels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) // end of [gels] implement gels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) = zgels ( pf_lwork | trans, m, n, nrhs, a, lda, b, ldb, work, lwork ) // end of [gels] (* ****** ****** *) (* /* Subroutine */ int dtrtrs_( char *uplo , char *trans , char *diag , integer *n , integer *nrhs , doublereal *a, integer *lda , doublereal *b, integer *ldb , integer *info ) ; *) implement trtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) = strtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) // end of [trtrs] implement trtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) = dtrtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) // end of [trtrs] implement trtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) = ctrtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) // end of [trtrs] implement trtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) = ztrtrs (uplo, trans, diag, n, nhrs, a, lda, b, ldb) // end of [trtrs] (* ****** ****** *) // getrf: S, D, C, Z (* /* Subroutine */ int dgetrf_( integer *m, integer *n , doublereal *a, integer *lda , integer *ipiv , integer *info ) ; *) implement getrf (pfa | m, n, a, lda, ipiv) = sgetrf (pfa | m, n, a, lda, ipiv) // end of [getrf] implement getrf (pfa | m, n, a, lda, ipiv) = dgetrf (pfa | m, n, a, lda, ipiv) // end of [getrf] implement getrf (pfa | m, n, a, lda, ipiv) = cgetrf (pfa | m, n, a, lda, ipiv) // end of [getrf] implement getrf (pfa | m, n, a, lda, ipiv) = zgetrf (pfa | m, n, a, lda, ipiv) // end of [getrf] implement{t} getrf_exn (pfa | m, n, a, lda, ipiv) = let val [info:int] (pflu | info) = getrf (pfa | m, n, a, lda, ipiv) val () = $effmask_all (if (info < 0) then begin prerr "exit(ATS/CLAPACK): [getrf] failed."; prerr_newline (); exit (1) end) (* end of [val] *) val () = assert (info >= 0) in (pflu | info) end // end of [getrf_exn] (* ****** ****** *) // laswp: S, D, C, Z (* /* Subroutine */ int dlaswp_( integer *n , doublereal *a, integer *lda , integer *k1, integer *k2 , integer *ipiv , integer *incx ) ; *) implement laswp (n, a, lda, k1, k2, ipiv, incx) = slaswp (n, a, lda, k1, k2, ipiv, incx) implement laswp (n, a, lda, k1, k2, ipiv, incx) = dlaswp (n, a, lda, k1, k2, ipiv, incx) implement laswp (n, a, lda, k1, k2, ipiv, incx) = claswp (n, a, lda, k1, k2, ipiv, incx) implement laswp (n, a, lda, k1, k2, ipiv, incx) = zlaswp (n, a, lda, k1, k2, ipiv, incx) (* ****** ****** *) // gesv: S, D, C, Z (* /* Subroutine */ int dgesv_ ( integer *n, integer *nrhs , doublereal *a, integer *lda , integer *ipiv , doublereal *b, integer *ldb , integer *info ) ; *) implement gesv (pf | n, nrhs, a, lda, ipiv, b, ldb) = sgesv (pf | n, nrhs, a, lda, ipiv, b, ldb) // end of [gesv] implement gesv (pf | n, nrhs, a, lda, ipiv, b, ldb) = dgesv (pf | n, nrhs, a, lda, ipiv, b, ldb) // end of [gesv] implement gesv (pf | n, nrhs, a, lda, ipiv, b, ldb) = cgesv (pf | n, nrhs, a, lda, ipiv, b, ldb) // end of [gesv] implement gesv (pf | n, nrhs, a, lda, ipiv, b, ldb) = zgesv (pf | n, nrhs, a, lda, ipiv, b, ldb) // end of [gesv] (* ****** ****** *) typedef gesvd_dummy_type (t1:t@ype,t2:t@ype) = {m,n:nat} ( (*jobu:*) char, (*jobvt:*) char , (*m:*) integer m, (*n:*) integer n , (*a:*) ptr, (*lda:*) integer, (*s:*) ptr , (*u:*) ptr, (*ldu:*) integer, (*vt:*) ptr, (*ldvt:*) integer , (*work:*) ptr, (*lwork:*) integer ) - int extern fun{t1,t2:t@ype} gesvd_dummy: gesvd_dummy_type (t1, t2) = "atsctrb_clapack_gesvd" typedef gesvd_c_dummy_type (t1:t@ype,t2:t@ype) = {m,n:nat} ( (*jobu:*) char, (*jobvt:*) char , (*m:*) integer m, (*n:*) integer n , (*a:*) ptr, (*lda:*) integer, (*s:*) ptr , (*u:*) ptr, (*ldu:*) integer, (*vt:*) ptr, (*ldvt:*) integer , (*work:*) ptr, (*lwork:*) integer, (*rwork*) ptr ) - int extern fun{t1,t2:t@ype} gesvd_c_dummy: gesvd_c_dummy_type (t1, t2) = "atsctrb_clapack_gesvd_c" extern fun sgesvd_dummy: gesvd_dummy_type (real, real) = "atsctrb_clapack_sgesvd" extern fun dgesvd_dummy: gesvd_dummy_type (double, double) = "atsctrb_clapack_dgesvd" extern fun cgesvd_dummy: gesvd_c_dummy_type (ccmplx, float) = "atsctrb_clapack_cgesvd" extern fun zgesvd_dummy: gesvd_c_dummy_type (zcmplx, double) = "atsctrb_clapack_zgesvd" implement gesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = sgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) // end of [gesvd_dummy] implement gesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = dgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) // end of [gesvd_dummy] implement gesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = let val mn = $F2C.min_integer_integer (m, n) val mn = $F2C.size1_of_integer mn // no-op casting var !p_rwork = @[float][5*mn]() // could this be dangerous? in cgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, p_rwork) end // end of [gesvd_dummy] implement gesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork) = let val mn = $F2C.min_integer_integer (m, n) val mn = $F2C.size1_of_integer mn // no-op casting var !p_rwork = @[double][5*mn]() // could this be dangerous? in zgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, p_rwork) end // end of [gesvd_dummy] implement gesvd_c_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, rwork) = cgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, rwork) // end of [gesvd_c_dummy] implement gesvd_c_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, rwork) = zgesvd_dummy (jobu, jobvt, m, n, a, lda, s, u, ldu, vt, ldvt, work, lwork, rwork) // end of [gesvd_c_dummy] (* ****** ****** *) end // end of [local] (* end of [clapack.hats] *) ats-lang-anairiats-0.2.11/contrib/cblas/0000700000175000017500000000000012223166163016506 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/CATS/0000700000175000017500000000000012223166163017240 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/CATS/cblas.cats0000664000175000017500000002276112223166163021224 0ustar hwxihwxi/* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** */ /* ****** ****** */ // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // /* ****** ****** */ #ifndef ATS_CONTRIB_CBLAS_CATS #define ATS_CONTRIB_CBLAS_CATS /* ****** ****** */ #include "ats_types.h" #include "ats_memory.h" /* ****** ****** */ #include "cblas.h" /* ****** ****** */ // #include // typedef float complex ats_fcomplex_type ; // typedef double complex ats_dcomplex_type ; // typedef long double complex ats_lcomplex_type ; /* ****** ****** */ #if (0) ATSinline() ats_bool_type atsctrb_eq_CBLAS_ORDER_ORDER ( ats_int_type x1, ats_int_type x2 ) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsctrb_eq_CBLAS_ORDER_ORDER] */ ATSinline() ats_bool_type atsctrb_eq_CBLAS_UPLO_UPLO ( ats_int_type x1, ats_int_type x2 ) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsctrb_eq_CBLAS_UPLO_UPLO] */ ATSinline() ats_bool_type atsctrb_eq_CBLAS_DIAG_DIAG ( ats_int_type x1, ats_int_type x2 ) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsctrb_eq_CBLAS_DIAG_DIAG] */ /* ****** ****** */ ATSinline() ats_bool_type atsctrb_eq_CBLAS_TRANSPOSE_TRANSPOSE ( ats_int_type x1, ats_int_type x2 ) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsctrb_eq_CBLAS_TRANSPOSE_TRANSPOSE] */ ATSinline() ats_bool_type atsctrb_eq_CBLAS_SIDE_SIDE ( ats_int_type x1, ats_int_type x2 ) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsctrb_eq_CBLAS_SIDE_SIDE] */ #endif // end of [#if(0)] /* ****** ****** */ // // BLAS level 1 // /* ****** ****** */ #define atsctrb_cblas_srotg cblas_srotg #define atsctrb_cblas_drotg cblas_drotg #if (0) #define atsctrb_cblas_crotg cblas_crotg #define atsctrb_cblas_zrotg cblas_zrotg #endif // end of [0] /* ****** ****** */ #define atsctrb_cblas_srotmg cblas_srotmg #define atsctrb_cblas_drotmg cblas_drotmg /* ****** ****** */ #define atsctrb_cblas_srot cblas_srot #define atsctrb_cblas_drot cblas_drot #if (0) // not in CBLAS proper #define atsctrb_cblas_csrot cblas_csrot #define atsctrb_cblas_zdrot cblas_zdrot #endif // end of [0] /* ****** ****** */ #define atsctrb_cblas_srotm cblas_srotm #define atsctrb_cblas_drotm cblas_drotm /* ****** ****** */ #define atsctrb_cblas_sdsdot cblas_sdsdot #define atsctrb_cblas_dsdot cblas_dsdot #define atsctrb_cblas_sdot cblas_sdot #define atsctrb_cblas_ddot cblas_ddot /* ****** ****** */ #define atsctrb_cblas_cdotu_sub cblas_cdotu_sub #define atsctrb_cblas_cdotc_sub cblas_cdotc_sub #define atsctrb_cblas_zdotu_sub cblas_zdotu_sub #define atsctrb_cblas_zdotc_sub cblas_zdotc_sub /* ****** ****** */ #define atsctrb_cblas_snrm2 cblas_snrm2 #define atsctrb_cblas_dnrm2 cblas_dnrm2 #define atsctrb_cblas_scnrm2 cblas_scnrm2 #define atsctrb_cblas_dznrm2 cblas_dznrm2 /* ****** ****** */ #define atsctrb_cblas_sasum cblas_sasum #define atsctrb_cblas_dasum cblas_dasum #define atsctrb_cblas_scasum cblas_scasum #define atsctrb_cblas_dzasum cblas_dzasum /* ****** ****** */ #define atsctrb_cblas_isamax cblas_isamax #define atsctrb_cblas_idamax cblas_idamax #define atsctrb_cblas_icamax cblas_icamax #define atsctrb_cblas_izamax cblas_izamax /* ****** ****** */ #define atsctrb_cblas_sswap cblas_sswap #define atsctrb_cblas_dswap cblas_dswap #define atsctrb_cblas_cswap cblas_cswap #define atsctrb_cblas_zswap cblas_zswap /* ****** ****** */ #define atsctrb_cblas_scopy cblas_scopy #define atsctrb_cblas_dcopy cblas_dcopy #define atsctrb_cblas_ccopy cblas_ccopy #define atsctrb_cblas_zcopy cblas_zcopy /* ****** ****** */ #define atsctrb_cblas_saxpy cblas_saxpy #define atsctrb_cblas_daxpy cblas_daxpy #define atsctrb_cblas_caxpy cblas_caxpy #define atsctrb_cblas_zaxpy cblas_zaxpy /* ****** ****** */ #define atsctrb_cblas_sscal cblas_sscal #define atsctrb_cblas_dscal cblas_dscal #define atsctrb_cblas_cscal cblas_cscal #define atsctrb_cblas_zscal cblas_zscal #define atsctrb_cblas_csscal cblas_csscal #define atsctrb_cblas_zdscal cblas_zdscal /* ****** ****** */ // // BLAS level 2 // /* ****** ****** */ /* ** GEMV: S, D, C, Z */ #define atsctrb_cblas_sgemv cblas_sgemv #define atsctrb_cblas_dgemv cblas_dgemv #define atsctrb_cblas_cgemv cblas_cgemv #define atsctrb_cblas_zgemv cblas_zgemv /* ****** ****** */ /* ** GBMV: S, D, C, Z */ #define atsctrb_cblas_sgbmv cblas_sgbmv #define atsctrb_cblas_dgbmv cblas_dgbmv #define atsctrb_cblas_cgbmv cblas_cgbmv #define atsctrb_cblas_zgbmv cblas_zgbmv /* ****** ****** */ /* ** TRMV: S, D, C, Z */ #define atsctrb_cblas_strmv cblas_strmv #define atsctrb_cblas_dtrmv cblas_dtrmv #define atsctrb_cblas_ctrmv cblas_ctrmv #define atsctrb_cblas_ztrmv cblas_ztrmv /* ****** ****** */ /* ** TBMV: S, D, C, Z */ #define atsctrb_cblas_stbmv cblas_stbmv #define atsctrb_cblas_dtbmv cblas_dtbmv #define atsctrb_cblas_ctbmv cblas_ctbmv #define atsctrb_cblas_ztbmv cblas_ztbmv /* ****** ****** */ /* ** TPMV: S, D, C, Z */ #define atsctrb_cblas_stpmv cblas_stpmv #define atsctrb_cblas_dtpmv cblas_dtpmv #define atsctrb_cblas_ctpmv cblas_ctpmv #define atsctrb_cblas_ztpmv cblas_ztpmv /* ****** ****** */ /* ** TRSV: S, D, C, Z */ #define atsctrb_cblas_strsv cblas_strsv #define atsctrb_cblas_dtrsv cblas_dtrsv #define atsctrb_cblas_ctrsv cblas_ctrsv #define atsctrb_cblas_ztrsv cblas_ztrsv /* ****** ****** */ /* ** TBSV: S, D, C, Z */ #define atsctrb_cblas_stbsv cblas_stbsv #define atsctrb_cblas_dtbsv cblas_dtbsv #define atsctrb_cblas_ctbsv cblas_ctbsv #define atsctrb_cblas_ztbsv cblas_ztbsv /* ****** ****** */ /* ** TPSV: S, D, C, Z */ #define atsctrb_cblas_stpsv cblas_stpsv #define atsctrb_cblas_dtpsv cblas_dtpsv #define atsctrb_cblas_ctpsv cblas_ctpsv #define atsctrb_cblas_ztpsv cblas_ztpsv /* ****** ****** */ /* ** SYMV: S, D */ #define atsctrb_cblas_ssymv cblas_ssymv #define atsctrb_cblas_dsymv cblas_dsymv /* ****** ****** */ /* ** SBMV: S, D */ #define atsctrb_cblas_ssbmv cblas_ssbmv #define atsctrb_cblas_dsbmv cblas_dsbmv /* ****** ****** */ /* ** SPMV: S, D */ #define atsctrb_cblas_sspmv cblas_sspmv #define atsctrb_cblas_dspmv cblas_dspmv /* ****** ****** */ /* ** GER: S, D */ #define atsctrb_cblas_sger cblas_sger #define atsctrb_cblas_dger cblas_dger /* ****** ****** */ /* ** SYR: S, D */ #define atsctrb_cblas_ssyr cblas_ssyr #define atsctrb_cblas_dsyr cblas_dsyr /* ****** ****** */ /* ** SPR: S, D */ #define atsctrb_cblas_sspr cblas_sspr #define atsctrb_cblas_dspr cblas_dspr /* ****** ****** */ /* ** SYR2: S, D */ #define atsctrb_cblas_ssyr2 cblas_ssyr2 #define atsctrb_cblas_dsyr2 cblas_dsyr2 /* ****** ****** */ /* ** SPR2: S, D */ #define atsctrb_cblas_sspr2 cblas_sspr2 #define atsctrb_cblas_dspr2 cblas_dspr2 /* ****** ****** */ /* ** HEMV: C, Z // extended with S, D */ #define atsctrb_cblas_chemv cblas_chemv #define atsctrb_cblas_zhemv cblas_zhemv /* ****** ****** */ /* ** HBMV; C, Z // extended with S, D */ #define atsctrb_cblas_chbmv cblas_chbmv #define atsctrb_cblas_zhbmv cblas_zhbmv /* ****** ****** */ /* ** HPMV; C, Z // extended with S, D */ #define atsctrb_cblas_chpmv cblas_chpmv #define atsctrb_cblas_zhpmv cblas_zhpmv /* ****** ****** */ /* ** GERU: C, Z // extended with S, D */ #define atsctrb_cblas_cgeru cblas_cgeru #define atsctrb_cblas_zgeru cblas_zgeru /* ****** ****** */ /* ** GERC: C, Z // extended with S, D */ #define atsctrb_cblas_cgerc cblas_cgerc #define atsctrb_cblas_zgerc cblas_zgerc /* ****** ****** */ /* ** HER: C, D // extended with S, D */ #define atsctrb_cblas_cher cblas_cher #define atsctrb_cblas_zher cblas_zher /* ****** ****** */ /* ** HPR: C, Z // extended with S, D */ #define atsctrb_cblas_chpr cblas_chpr #define atsctrb_cblas_zhpr cblas_zhpr /* ****** ****** */ /* ** HER2: C, Z // extended with S, D */ #define atsctrb_cblas_cher2 cblas_cher2 #define atsctrb_cblas_zher2 cblas_zher2 /* ****** ****** */ #define atsctrb_cblas_chpr2 cblas_chpr2 #define atsctrb_cblas_zhpr2 cblas_zhpr2 /* ****** ****** */ // // BLAS level 3 // /* ****** ****** */ #define atsctrb_cblas_sgemm cblas_sgemm #define atsctrb_cblas_dgemm cblas_dgemm #define atsctrb_cblas_cgemm cblas_cgemm #define atsctrb_cblas_zgemm cblas_zgemm /* ****** ****** */ #define atsctrb_cblas_ssyrk cblas_ssyrk #define atsctrb_cblas_dsyrk cblas_dsyrk #define atsctrb_cblas_csyrk cblas_csyrk #define atsctrb_cblas_zsyrk cblas_zsyrk /* ****** ****** */ #define atsctrb_cblas_ssyr2k cblas_ssyr2k #define atsctrb_cblas_dsyr2k cblas_dsyr2k #define atsctrb_cblas_csyr2k cblas_csyr2k #define atsctrb_cblas_zsyr2k cblas_zsyr2k /* ****** ****** */ #define atsctrb_cblas_ssymm cblas_ssymm #define atsctrb_cblas_dsymm cblas_dsymm #define atsctrb_cblas_csymm cblas_csymm #define atsctrb_cblas_zsymm cblas_zsymm /* ****** ****** */ #define atsctrb_cblas_strmm cblas_strmm #define atsctrb_cblas_dtrmm cblas_dtrmm #define atsctrb_cblas_ctrmm cblas_ctrmm #define atsctrb_cblas_ztrmm cblas_ztrmm /* ****** ****** */ #define atsctrb_cblas_strsm cblas_strsm #define atsctrb_cblas_dtrsm cblas_dtrsm #define atsctrb_cblas_ctrsm cblas_ctrsm #define atsctrb_cblas_ztrsm cblas_ztrsm /* ****** ****** */ #define atsctrb_cblas_chemm cblas_chemm #define atsctrb_cblas_zhemm cblas_zhemm /* ****** ****** */ #define atsctrb_cblas_cherk cblas_cherk #define atsctrb_cblas_zherk cblas_zherk /* ****** ****** */ #define atsctrb_cblas_cher2k cblas_cher2k #define atsctrb_cblas_zher2k cblas_zher2k /* ****** ****** */ #endif /* [ATS_CONTRIB_CBLAS_CATS] */ /* end of [cblas.cats] */ ats-lang-anairiats-0.2.11/contrib/cblas/TEST/0000700000175000017500000000000012223166164017266 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_lu_dats.c0000664000175000017500000123676212223166163022160 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-7-16: 6h:48m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/matrix.cats" #include "prelude/CATS/option.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "libc/CATS/complex.cats" #include "libats/CATS/genarrays.cats" #include "libc/CATS/complex.cats" // it needs to be loaded before [cblas.cats] #include "contrib/cblas/CATS/cblas.cats" #include "libc/CATS/complex.cats" #include "libats/CATS/genarrays.cats" #include "libc/CATS/complex.cats" #include "libats/CATS/genarrays.cats" #include "libats/CATS/fmatrix.cats" #include "libats/CATS/genarrays.cats" #include "libats/CATS/genarrays.cats" #include "libc/CATS/complex.cats" // it needs to be loaded before [cblas.cats] #include "contrib/cblas/CATS/cblas.cats" #include "libc/CATS/complex.cats" #include "libats/CATS/genarrays.cats" /* external codes at top */ ats_void_type __matrix_free (ats_ptr_type A) { ATS_FREE (A); return ; } /* type definitions */ typedef struct { ats_ptr_type atslab_2 ; ats_size_type atslab_3 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_5 ; ats_ptr_type atslab_6 ; ats_ptr_type atslab_7 ; ats_ptr_type atslab_8 ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; ats_ptr_type atslab_6 ; } anairiats_rec_3 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_float_type, atspre_float_of_double) (ats_double_type) ; ATSextern_fun(ats_float_type, atspre_abs_float) (ats_float_type) ; ATSextern_fun(ats_float_type, atspre_add_float_float) (ats_float_type, ats_float_type) ; ATSextern_fun(ats_float_type, atspre_sub_float_float) (ats_float_type, ats_float_type) ; ATSextern_fun(ats_float_type, atspre_mul_float_float) (ats_float_type, ats_float_type) ; ATSextern_fun(ats_float_type, atspre_div_float_float) (ats_float_type, ats_float_type) ; ATSextern_fun(ats_void_type, atspre_print_float) (ats_float_type) ; ATSextern_fun(ats_double_type, atspre_double_of_int) (ats_int_type) ; ATSextern_fun(ats_double_type, atspre_abs_double) (ats_double_type) ; ATSextern_fun(ats_double_type, atspre_add_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_sub_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_mul_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_div_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_void_type, atspre_print_double) (ats_double_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_min_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int_of_size) (ats_size_type) ; ATSextern_fun(ats_size_type, atspre_add_size_size) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_mul_size_size) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_gt_size_int) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_size_int) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_print_size) (ats_size_type) ; ATSextern_fun(ats_int_type, atspre_int1_of_size1) (ats_size_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_sub_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_sub_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_mul_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_mul2_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_mod1_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_lt_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_lte_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_gt_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_alloc_tsz) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_void_type, atspre_array_ptr_initialize_cloenv_tsz) (ats_ref_type, ats_size_type, ats_ref_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_array_ptr_copy_tsz) (ats_ref_type, ats_ref_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_matrix_ptr_takeout_row_tsz) (ats_ptr_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_matrix_ptr_takeout_elt_tsz) (ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_matrix_make_arrpsz__main) (ats_size_type, ats_size_type, anairiats_rec_0) ; ATSextern_fun(ats_ptr_type, atspre_matrix_make_funenv_tsz) (ats_size_type, ats_size_type, ats_ptr_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_ccmplx) (ats_fcomplex_type) ; ATSextern_fun(ats_fcomplex_type, atslib_ccmplx_of_float) (ats_float_type) ; ATSextern_fun(ats_fcomplex_type, atslib_add_ccmplx_ccmplx) (ats_fcomplex_type, ats_fcomplex_type) ; ATSextern_fun(ats_fcomplex_type, atslib_sub_ccmplx_ccmplx) (ats_fcomplex_type, ats_fcomplex_type) ; ATSextern_fun(ats_fcomplex_type, atslib_mul_ccmplx_ccmplx) (ats_fcomplex_type, ats_fcomplex_type) ; ATSextern_fun(ats_fcomplex_type, atslib_div_ccmplx_ccmplx) (ats_fcomplex_type, ats_fcomplex_type) ; ATSextern_fun(ats_float_type, atslib_cabsf) (ats_fcomplex_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_zcmplx) (ats_dcomplex_type) ; ATSextern_fun(ats_dcomplex_type, atslib_zcmplx_of_double) (ats_double_type) ; ATSextern_fun(ats_dcomplex_type, atslib_add_zcmplx_zcmplx) (ats_dcomplex_type, ats_dcomplex_type) ; ATSextern_fun(ats_dcomplex_type, atslib_sub_zcmplx_zcmplx) (ats_dcomplex_type, ats_dcomplex_type) ; ATSextern_fun(ats_dcomplex_type, atslib_mul_zcmplx_zcmplx) (ats_dcomplex_type, ats_dcomplex_type) ; ATSextern_fun(ats_dcomplex_type, atslib_div_zcmplx_zcmplx) (ats_dcomplex_type, ats_dcomplex_type) ; ATSextern_fun(ats_double_type, atslib_cabs) (ats_dcomplex_type) ; ATSextern_fun(ats_void_type, atslib_GEVEC_ptr_foreach_funenv_tsz) (ats_ref_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_GEVEC_ptr_iforeach_funenv_tsz) (ats_ref_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_GEVEC_ptr_iforeach_cloenv_tsz) (ats_ref_type, ats_ref_type, ats_size_type, ats_size_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_size_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get) (ats_ptr_type, ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_copy_tsz) (ats_ptr_type, ats_ref_type, ats_ref_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_foreach_funenv_tsz) (ats_ptr_type, ats_ref_type, ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_iforeach_funenv_tsz) (ats_ptr_type, ats_ref_type, ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDER) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e10_2libats_2SATS_2fmatrix_2esats__fmatrix_ptr_free) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tsz) (ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x1_tsz) (ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(anairiats_rec_2, ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tsz) (ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(anairiats_rec_3, ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__TRMAT_U_ptr_split2x2_tsz) (ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(anairiats_rec_3, ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__TRMAT_L_ptr_split2x2_tsz) (ats_ptr_type, ats_ptr_type, ats_size_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_void_type, __matrix_free) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e10_2prelude_2SATS_2arith_2esats__mul_istot_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2prelude_2SATS_2arith_2esats__mul_nat_nat_nat_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__array_v_of_matrix_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__matrix_v_of_array_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_nil_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_unnil_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_cons_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_uncons_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__array_v_of_GEVEC_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_array_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_trans_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_nil_row_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_unnil_row_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_GEMAT_v_row_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_GEMAT_v_col_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRMAT_v_trans_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRMAT_v_of_GEMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HEMAT_v_of_SYMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SYMAT_v_of_HEMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HBMAT_v_of_SBMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SBMAT_v_of_HBMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HPMAT_v_of_SPMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SPMAT_v_of_HPMAT_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2fmatrix_2esats__GEMAT_v_of_fmatrix_v_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__coerce_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__coerce_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____assert_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____assert_prfck () ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type cblas_rotg_01912_ats_float_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type cblas_rotg_01912_ats_double_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type cblas_rot_01920_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_float_type arg5, ats_float_type arg6) ; static ats_void_type cblas_rot_01920_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_double_type arg5, ats_double_type arg6) ; static ats_void_type cblas_rotmg_01917_ats_float_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_float_type arg3, ats_ref_type arg4) ; static ats_void_type cblas_rotmg_01917_ats_double_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_double_type arg3, ats_ref_type arg4) ; static ats_void_type cblas_rotm_01923_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_void_type cblas_rotm_01923_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_float_type cblas_dot_01926_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_double_type cblas_dot_01926_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_dotu_sub_01931_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_void_type cblas_dotu_sub_01931_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_void_type cblas_dotc_sub_01934_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_void_type cblas_dotc_sub_01934_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) ; static ats_float_type cblas_dotu_01937_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_double_type cblas_dotu_01937_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_fcomplex_type cblas_dotu_01937_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_dcomplex_type cblas_dotu_01937_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_float_type cblas_dotc_01938_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_double_type cblas_dotc_01938_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_fcomplex_type cblas_dotc_01938_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_dcomplex_type cblas_dotc_01938_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_float_type cblas_nrm2_01939_ats_float_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_double_type cblas_nrm2_01939_ats_double_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_float_type cblas_nrm2_01939_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_double_type cblas_nrm2_01939_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_float_type cblas_asum_01944_ats_float_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_double_type cblas_asum_01944_ats_double_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_float_type cblas_asum_01944_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_double_type cblas_asum_01944_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_int_type cblas_iamax_01949_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_int_type cblas_iamax_01949_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_int_type cblas_iamax_01949_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_int_type cblas_iamax_01949_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_void_type cblas_swap_01954_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_swap_01954_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_swap_01954_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_swap_01954_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_axpy_01964_ats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) ; static ats_void_type cblas_axpy_01964_ats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) ; static ats_void_type cblas_axpy_01964_ats_fcomplex_type (ats_int_type arg0, ats_fcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) ; static ats_void_type cblas_axpy_01964_ats_dcomplex_type (ats_int_type arg0, ats_dcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) ; static ats_void_type cblas_copy_01959_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_copy_01959_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_copy_01959_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_copy_01959_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) ; static ats_void_type cblas_scal_01969_ats_float_type_2cats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_scal_01969_ats_double_type_2cats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_scal_01969_ats_fcomplex_type_2cats_fcomplex_type (ats_int_type arg0, ats_fcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_scal_01969_ats_dcomplex_type_2cats_dcomplex_type (ats_int_type arg0, ats_dcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_scal_01969_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_scal_01969_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_void_type cblas_gemv_01976_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_gemv_01976_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_gemv_01976_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_fcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_gemv_01976_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_dcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_gbmv_01981_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_float_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_float_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type cblas_gbmv_01981_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_double_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_double_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type cblas_gbmv_01981_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_fcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_fcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type cblas_gbmv_01981_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_dcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_dcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type cblas_trmv_01986_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trmv_01986_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trmv_01986_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trmv_01986_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_tbmv_01991_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbmv_01991_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbmv_01991_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbmv_01991_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tpmv_01996_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpmv_01996_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpmv_01996_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpmv_01996_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_trsv_02001_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trsv_02001_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trsv_02001_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_trsv_02001_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) ; static ats_void_type cblas_tbsv_02006_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbsv_02006_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbsv_02006_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tbsv_02006_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_tpsv_02011_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpsv_02011_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpsv_02011_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_tpsv_02011_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_symv_02016_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_symv_02016_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_sbmv_02019_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_sbmv_02019_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_spmv_02022_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_spmv_02022_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_ger_02025_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_ger_02025_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_syr_02028_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_syr_02028_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_syr2_02031_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_syr2_02031_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_spr_02034_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_spr_02034_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_spr2_02037_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_spr2_02037_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_hemv_02040_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_hemv_02040_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_hemv_02040_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_fcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_hemv_02040_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_dcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_hbmv_02043_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_hbmv_02043_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_hbmv_02043_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_fcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_hbmv_02043_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_dcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_hpmv_02046_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_hpmv_02046_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_hpmv_02046_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_hpmv_02046_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_geru_02049_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_geru_02049_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_geru_02049_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_geru_02049_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_gerc_02052_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_gerc_02052_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_gerc_02052_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_gerc_02052_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_her_02055_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_her_02055_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_her_02055_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_her_02055_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) ; static ats_void_type cblas_her2_02058_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_her2_02058_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_her2_02058_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_her2_02058_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) ; static ats_void_type cblas_hpr_02061_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_hpr_02061_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_hpr_02061_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_hpr_02061_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) ; static ats_void_type cblas_hpr2_02064_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_hpr2_02064_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_hpr2_02064_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_hpr2_02064_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) ; static ats_void_type cblas_gemm_overlap_check_136 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type atsctrb_cblas_gemm_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_float_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_float_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type atsctrb_cblas_gemm_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_double_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_double_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type atsctrb_cblas_gemm_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_fcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_fcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type atsctrb_cblas_gemm_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_dcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_dcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) ; static ats_void_type cblas_syrk_02073_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_syrk_02073_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_syrk_02073_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_fcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_syrk_02073_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_dcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_syr2k_02078_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_syr2k_02078_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_syr2k_02078_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_syr2k_02078_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_symm_02083_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_symm_02083_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_symm_02083_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_symm_02083_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_trmm_02088_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trmm_02088_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trmm_02088_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trmm_02088_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trsm_02093_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trsm_02093_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trsm_02093_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_trsm_02093_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) ; static ats_void_type cblas_hemm_02098_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_hemm_02098_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_hemm_02098_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_hemm_02098_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_herk_02101_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_herk_02101_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_herk_02101_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_herk_02101_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) ; static ats_void_type cblas_her2k_02104_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_her2k_02104_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_her2k_02104_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_void_type cblas_her2k_02104_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) ; static ats_float_type of_double_02161_ats_float_type (ats_double_type arg0) ; static ats_double_type of_double_02161_ats_double_type (ats_double_type arg0) ; static ats_fcomplex_type of_double_02161_ats_fcomplex_type (ats_double_type arg0) ; static ats_dcomplex_type of_double_02161_ats_dcomplex_type (ats_double_type arg0) ; static ats_void_type print_elt_02162_ats_float_type (ats_float_type arg0) ; static ats_void_type print_elt_02162_ats_double_type (ats_double_type arg0) ; static ats_void_type print_elt_02162_ats_fcomplex_type (ats_fcomplex_type arg0) ; static ats_void_type print_elt_02162_ats_dcomplex_type (ats_dcomplex_type arg0) ; static ats_float_type abs_02163_ats_float_type_2cats_float_type (ats_float_type arg0) ; static ats_double_type abs_02163_ats_double_type_2cats_double_type (ats_double_type arg0) ; static ats_float_type abs_02163_ats_float_type_2cats_fcomplex_type (ats_fcomplex_type arg0) ; static ats_double_type abs_02163_ats_double_type_2cats_dcomplex_type (ats_dcomplex_type arg0) ; static ats_float_type add_02164_ats_float_type (ats_float_type arg0, ats_float_type arg1) ; static ats_double_type add_02164_ats_double_type (ats_double_type arg0, ats_double_type arg1) ; static ats_fcomplex_type add_02164_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) ; static ats_dcomplex_type add_02164_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) ; static ats_float_type sub_02165_ats_float_type (ats_float_type arg0, ats_float_type arg1) ; static ats_double_type sub_02165_ats_double_type (ats_double_type arg0, ats_double_type arg1) ; static ats_fcomplex_type sub_02165_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) ; static ats_dcomplex_type sub_02165_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) ; static ats_float_type mul_02166_ats_float_type (ats_float_type arg0, ats_float_type arg1) ; static ats_double_type mul_02166_ats_double_type (ats_double_type arg0, ats_double_type arg1) ; static ats_fcomplex_type mul_02166_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) ; static ats_dcomplex_type mul_02166_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) ; static ats_float_type div_02167_ats_float_type (ats_float_type arg0, ats_float_type arg1) ; static ats_double_type div_02167_ats_double_type (ats_double_type arg0, ats_double_type arg1) ; static ats_fcomplex_type div_02167_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) ; static ats_dcomplex_type div_02167_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) ; static ats_void_type __ats_fun_203 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_203_closure_make () ; static ats_void_type __ats_fun_203_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_205 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type matrix_make_vclo_01660_ats_float_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type __ats_fun_207 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_207_closure_make () ; static ats_void_type __ats_fun_207_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_209 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) ; static ats_void_type loop1_211 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) ; static ats_void_type loop2_212 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) ; static ats_void_type loop1_211_0loop2_212 (ats_int_type arg0, ...) ; static ats_void_type matrix_iforeach_funenv_01669_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) ; static ats_void_type matrix_iforeach_cloref_01672_ats_float_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type print_matrix_02646_ats_float_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_ptr_type GEMAT_ptr_takeout_01857_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_float_type GEMAT_ptr_get_elt_at_01858_ats_float_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_void_type loop_215 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type loop_215_closure_make (ats_ptr_type env0, ats_size_type env1) ; static ats_void_type loop_215_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type lu_02160_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) ; static ats_void_type __ats_fun_219 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_219_closure_make () ; static ats_void_type __ats_fun_219_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type f_220 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type matrix_iforeach_fun_01670_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type loop_223 (ats_ptr_type env0, ats_ptr_type env1, ats_float_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_clo_ptr_type loop_223_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_float_type env2, ats_size_type env3, ats_size_type env4) ; static ats_void_type loop_223_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type gemaxpy_02168_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) ; static ats_float_type loop_226 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) ; static ats_clo_ptr_type loop_226_closure_make (ats_size_type env0) ; static ats_float_type loop_226_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) ; static ats_float_type gemnrm2_02169_ats_float_type_2cats_float_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) ; static ats_void_type test_02654_ats_float_type_2cats_float_type (ats_int_type arg0) ; static ats_void_type __ats_fun_228 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_228_closure_make () ; static ats_void_type __ats_fun_228_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_230 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type matrix_make_vclo_01660_ats_double_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type __ats_fun_232 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_232_closure_make () ; static ats_void_type __ats_fun_232_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_234 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) ; static ats_void_type loop1_236 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) ; static ats_void_type loop2_237 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) ; static ats_void_type loop1_236_0loop2_237 (ats_int_type arg0, ...) ; static ats_void_type matrix_iforeach_funenv_01669_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) ; static ats_void_type matrix_iforeach_cloref_01672_ats_double_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type print_matrix_02646_ats_double_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_ptr_type GEMAT_ptr_takeout_01857_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_double_type GEMAT_ptr_get_elt_at_01858_ats_double_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_void_type loop_240 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type loop_240_closure_make (ats_ptr_type env0, ats_size_type env1) ; static ats_void_type loop_240_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type lu_02160_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) ; static ats_void_type __ats_fun_244 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_244_closure_make () ; static ats_void_type __ats_fun_244_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type f_245 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type matrix_iforeach_fun_01670_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type loop_248 (ats_ptr_type env0, ats_ptr_type env1, ats_double_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_clo_ptr_type loop_248_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_double_type env2, ats_size_type env3, ats_size_type env4) ; static ats_void_type loop_248_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type gemaxpy_02168_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) ; static ats_double_type loop_251 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) ; static ats_clo_ptr_type loop_251_closure_make (ats_size_type env0) ; static ats_double_type loop_251_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) ; static ats_double_type gemnrm2_02169_ats_double_type_2cats_double_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) ; static ats_void_type test_02654_ats_double_type_2cats_double_type (ats_int_type arg0) ; static ats_void_type __ats_fun_253 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_253_closure_make () ; static ats_void_type __ats_fun_253_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_255 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type matrix_make_vclo_01660_ats_fcomplex_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type __ats_fun_257 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_257_closure_make () ; static ats_void_type __ats_fun_257_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_259 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) ; static ats_void_type loop1_261 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) ; static ats_void_type loop2_262 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) ; static ats_void_type loop1_261_0loop2_262 (ats_int_type arg0, ...) ; static ats_void_type matrix_iforeach_funenv_01669_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) ; static ats_void_type matrix_iforeach_cloref_01672_ats_fcomplex_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type print_matrix_02646_ats_fcomplex_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_ptr_type GEMAT_ptr_takeout_01857_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_fcomplex_type GEMAT_ptr_get_elt_at_01858_ats_fcomplex_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_void_type loop_265 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type loop_265_closure_make (ats_ptr_type env0, ats_size_type env1) ; static ats_void_type loop_265_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type lu_02160_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) ; static ats_void_type __ats_fun_269 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_269_closure_make () ; static ats_void_type __ats_fun_269_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type f_270 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type matrix_iforeach_fun_01670_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type loop_273 (ats_ptr_type env0, ats_ptr_type env1, ats_fcomplex_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_clo_ptr_type loop_273_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_fcomplex_type env2, ats_size_type env3, ats_size_type env4) ; static ats_void_type loop_273_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type gemaxpy_02168_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) ; static ats_float_type loop_276 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) ; static ats_clo_ptr_type loop_276_closure_make (ats_size_type env0) ; static ats_float_type loop_276_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) ; static ats_float_type gemnrm2_02169_ats_float_type_2cats_fcomplex_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) ; static ats_void_type test_02654_ats_float_type_2cats_fcomplex_type (ats_int_type arg0) ; static ats_void_type __ats_fun_278 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_278_closure_make () ; static ats_void_type __ats_fun_278_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_280 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type matrix_make_vclo_01660_ats_dcomplex_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type __ats_fun_282 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_282_closure_make () ; static ats_void_type __ats_fun_282_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type app_284 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) ; static ats_void_type loop1_286 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) ; static ats_void_type loop2_287 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) ; static ats_void_type loop1_286_0loop2_287 (ats_int_type arg0, ...) ; static ats_void_type matrix_iforeach_funenv_01669_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) ; static ats_void_type matrix_iforeach_cloref_01672_ats_dcomplex_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type print_matrix_02646_ats_dcomplex_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_ptr_type GEMAT_ptr_takeout_01857_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_dcomplex_type GEMAT_ptr_get_elt_at_01858_ats_dcomplex_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) ; static ats_void_type loop_290 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type loop_290_closure_make (ats_ptr_type env0, ats_size_type env1) ; static ats_void_type loop_290_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type lu_02160_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) ; static ats_void_type __ats_fun_294 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type __ats_fun_294_closure_make () ; static ats_void_type __ats_fun_294_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type f_295 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) ; static ats_void_type matrix_iforeach_fun_01670_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type loop_298 (ats_ptr_type env0, ats_ptr_type env1, ats_dcomplex_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_clo_ptr_type loop_298_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_dcomplex_type env2, ats_size_type env3, ats_size_type env4) ; static ats_void_type loop_298_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type gemaxpy_02168_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) ; static ats_double_type loop_301 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) ; static ats_clo_ptr_type loop_301_closure_make (ats_size_type env0) ; static ats_double_type loop_301_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) ; static ats_double_type gemnrm2_02169_ats_double_type_2cats_dcomplex_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) ; static ats_void_type test_02654_ats_double_type_2cats_dcomplex_type (ats_int_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 745(line=44, offs=3) -- 784(line=44, offs=42) */ ATSstaticdec() ats_void_type cblas_rotg_01912_ats_float_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_cblas_rotg_01912_ats_float_type: /* tmp0 = */ atsctrb_cblas_srotg (arg0, arg1, arg2, arg3) ; return /* (tmp0) */ ; } /* end of [cblas_rotg_01912_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 847(line=48, offs=3) -- 886(line=48, offs=42) */ ATSstaticdec() ats_void_type cblas_rotg_01912_ats_double_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp1) ; __ats_lab_cblas_rotg_01912_ats_double_type: /* tmp1 = */ atsctrb_cblas_drotg (arg0, arg1, arg2, arg3) ; return /* (tmp1) */ ; } /* end of [cblas_rotg_01912_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 1314(line=74, offs=3) -- 1382(line=74, offs=71) */ ATSstaticdec() ats_void_type cblas_rot_01920_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_float_type arg5, ats_float_type arg6) { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_cblas_rot_01920_ats_float_type: /* tmp2 = */ atsctrb_cblas_srot (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp2) */ ; } /* end of [cblas_rot_01920_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 1443(line=78, offs=3) -- 1511(line=78, offs=71) */ ATSstaticdec() ats_void_type cblas_rot_01920_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_double_type arg5, ats_double_type arg6) { /* local vardec */ // ATSlocal_void (tmp3) ; __ats_lab_cblas_rot_01920_ats_double_type: /* tmp3 = */ atsctrb_cblas_drot (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp3) */ ; } /* end of [cblas_rot_01920_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 1623(line=88, offs=3) -- 1677(line=88, offs=57) */ ATSstaticdec() ats_void_type cblas_rotmg_01917_ats_float_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_float_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp4) ; __ats_lab_cblas_rotmg_01917_ats_float_type: /* tmp4 = */ atsctrb_cblas_srotmg (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp4) */ ; } /* end of [cblas_rotmg_01917_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 1742(line=92, offs=3) -- 1796(line=92, offs=57) */ ATSstaticdec() ats_void_type cblas_rotmg_01917_ats_double_type (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_double_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp5) ; __ats_lab_cblas_rotmg_01917_ats_double_type: /* tmp5 = */ atsctrb_cblas_drotmg (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp5) */ ; } /* end of [cblas_rotmg_01917_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 1908(line=102, offs=3) -- 1971(line=102, offs=66) */ ATSstaticdec() ats_void_type cblas_rotm_01923_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp6) ; __ats_lab_cblas_rotm_01923_ats_float_type: /* tmp6 = */ atsctrb_cblas_srotm (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp6) */ ; } /* end of [cblas_rotm_01923_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2034(line=106, offs=3) -- 2097(line=106, offs=66) */ ATSstaticdec() ats_void_type cblas_rotm_01923_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp7) ; __ats_lab_cblas_rotm_01923_ats_double_type: /* tmp7 = */ atsctrb_cblas_drotm (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp7) */ ; } /* end of [cblas_rotm_01923_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2207(line=116, offs=4) -- 2263(line=116, offs=60) */ ATSstaticdec() ats_float_type cblas_dot_01926_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp8) ; __ats_lab_cblas_dot_01926_ats_float_type: tmp8 = atsctrb_cblas_sdot (arg0, arg1, arg2, arg3, arg4) ; return (tmp8) ; } /* end of [cblas_dot_01926_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2325(line=120, offs=4) -- 2381(line=120, offs=60) */ ATSstaticdec() ats_double_type cblas_dot_01926_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp9) ; __ats_lab_cblas_dot_01926_ats_double_type: tmp9 = atsctrb_cblas_ddot (arg0, arg1, arg2, arg3, arg4) ; return (tmp9) ; } /* end of [cblas_dot_01926_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2569(line=131, offs=4) -- 2642(line=131, offs=77) */ ATSstaticdec() ats_void_type cblas_dotu_sub_01931_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp10) ; __ats_lab_cblas_dotu_sub_01931_ats_fcomplex_type: /* tmp10 = */ atsctrb_cblas_cdotu_sub (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp10) */ ; } /* end of [cblas_dotu_sub_01931_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2715(line=135, offs=4) -- 2788(line=135, offs=77) */ ATSstaticdec() ats_void_type cblas_dotu_sub_01931_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp11) ; __ats_lab_cblas_dotu_sub_01931_ats_dcomplex_type: /* tmp11 = */ atsctrb_cblas_zdotu_sub (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp11) */ ; } /* end of [cblas_dotu_sub_01931_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 2979(line=146, offs=4) -- 3052(line=146, offs=77) */ ATSstaticdec() ats_void_type cblas_dotc_sub_01934_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp12) ; __ats_lab_cblas_dotc_sub_01934_ats_fcomplex_type: /* tmp12 = */ atsctrb_cblas_cdotc_sub (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp12) */ ; } /* end of [cblas_dotc_sub_01934_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 3125(line=150, offs=4) -- 3198(line=150, offs=77) */ ATSstaticdec() ats_void_type cblas_dotc_sub_01934_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp13) ; __ats_lab_cblas_dotc_sub_01934_ats_dcomplex_type: /* tmp13 = */ atsctrb_cblas_zdotc_sub (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp13) */ ; } /* end of [cblas_dotc_sub_01934_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 3320(line=160, offs=4) -- 3376(line=160, offs=60) */ ATSstaticdec() ats_float_type cblas_dotu_01937_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp14) ; __ats_lab_cblas_dotu_01937_ats_float_type: tmp14 = atsctrb_cblas_sdot (arg0, arg1, arg2, arg3, arg4) ; return (tmp14) ; } /* end of [cblas_dotu_01937_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 3439(line=164, offs=4) -- 3495(line=164, offs=60) */ ATSstaticdec() ats_double_type cblas_dotu_01937_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp15) ; __ats_lab_cblas_dotu_01937_ats_double_type: tmp15 = atsctrb_cblas_ddot (arg0, arg1, arg2, arg3, arg4) ; return (tmp15) ; } /* end of [cblas_dotu_01937_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 3559(line=168, offs=4) -- 3692(line=173, offs=4) */ ATSstaticdec() ats_fcomplex_type cblas_dotu_01937_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp16) ; ATSlocal (ats_fcomplex_type, tmp17) ; // ATSlocal_void (tmp18) ; __ats_lab_cblas_dotu_01937_ats_fcomplex_type: /* ats_fcomplex_type tmp17 ; */ /* tmp18 = */ atsctrb_cblas_cdotu_sub (arg0, arg1, arg2, arg3, arg4, (&tmp17)) ; tmp16 = tmp17 ; return (tmp16) ; } /* end of [cblas_dotu_01937_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 3753(line=176, offs=4) -- 3886(line=181, offs=4) */ ATSstaticdec() ats_dcomplex_type cblas_dotu_01937_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp19) ; ATSlocal (ats_dcomplex_type, tmp20) ; // ATSlocal_void (tmp21) ; __ats_lab_cblas_dotu_01937_ats_dcomplex_type: /* ats_dcomplex_type tmp20 ; */ /* tmp21 = */ atsctrb_cblas_zdotu_sub (arg0, arg1, arg2, arg3, arg4, (&tmp20)) ; tmp19 = tmp20 ; return (tmp19) ; } /* end of [cblas_dotu_01937_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4000(line=190, offs=4) -- 4056(line=190, offs=60) */ ATSstaticdec() ats_float_type cblas_dotc_01938_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp22) ; __ats_lab_cblas_dotc_01938_ats_float_type: tmp22 = atsctrb_cblas_sdot (arg0, arg1, arg2, arg3, arg4) ; return (tmp22) ; } /* end of [cblas_dotc_01938_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4120(line=194, offs=4) -- 4176(line=194, offs=60) */ ATSstaticdec() ats_double_type cblas_dotc_01938_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp23) ; __ats_lab_cblas_dotc_01938_ats_double_type: tmp23 = atsctrb_cblas_ddot (arg0, arg1, arg2, arg3, arg4) ; return (tmp23) ; } /* end of [cblas_dotc_01938_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4241(line=198, offs=4) -- 4374(line=203, offs=4) */ ATSstaticdec() ats_fcomplex_type cblas_dotc_01938_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp24) ; ATSlocal (ats_fcomplex_type, tmp25) ; // ATSlocal_void (tmp26) ; __ats_lab_cblas_dotc_01938_ats_fcomplex_type: /* ats_fcomplex_type tmp25 ; */ /* tmp26 = */ atsctrb_cblas_cdotc_sub (arg0, arg1, arg2, arg3, arg4, (&tmp25)) ; tmp24 = tmp25 ; return (tmp24) ; } /* end of [cblas_dotc_01938_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4435(line=206, offs=4) -- 4568(line=211, offs=4) */ ATSstaticdec() ats_dcomplex_type cblas_dotc_01938_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp27) ; ATSlocal (ats_dcomplex_type, tmp28) ; // ATSlocal_void (tmp29) ; __ats_lab_cblas_dotc_01938_ats_dcomplex_type: /* ats_dcomplex_type tmp28 ; */ /* tmp29 = */ atsctrb_cblas_zdotc_sub (arg0, arg1, arg2, arg3, arg4, (&tmp28)) ; tmp27 = tmp28 ; return (tmp27) ; } /* end of [cblas_dotc_01938_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4687(line=219, offs=35) -- 4726(line=219, offs=74) */ ATSstaticdec() ats_float_type cblas_nrm2_01939_ats_float_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_float_type, tmp30) ; __ats_lab_cblas_nrm2_01939_ats_float_type_2cats_float_type: tmp30 = atsctrb_cblas_snrm2 (arg0, arg1, arg2) ; return (tmp30) ; } /* end of [cblas_nrm2_01939_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4763(line=220, offs=37) -- 4802(line=220, offs=76) */ ATSstaticdec() ats_double_type cblas_nrm2_01939_ats_double_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_double_type, tmp31) ; __ats_lab_cblas_nrm2_01939_ats_double_type_2cats_double_type: tmp31 = atsctrb_cblas_dnrm2 (arg0, arg1, arg2) ; return (tmp31) ; } /* end of [cblas_nrm2_01939_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4838(line=221, offs=36) -- 4878(line=221, offs=76) */ ATSstaticdec() ats_float_type cblas_nrm2_01939_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_float_type, tmp32) ; __ats_lab_cblas_nrm2_01939_ats_float_type_2cats_fcomplex_type: tmp32 = atsctrb_cblas_scnrm2 (arg0, arg1, arg2) ; return (tmp32) ; } /* end of [cblas_nrm2_01939_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 4915(line=222, offs=37) -- 4955(line=222, offs=77) */ ATSstaticdec() ats_double_type cblas_nrm2_01939_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_double_type, tmp33) ; __ats_lab_cblas_nrm2_01939_ats_double_type_2cats_dcomplex_type: tmp33 = atsctrb_cblas_dznrm2 (arg0, arg1, arg2) ; return (tmp33) ; } /* end of [cblas_nrm2_01939_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5049(line=230, offs=37) -- 5089(line=230, offs=77) */ ATSstaticdec() ats_float_type cblas_asum_01944_ats_float_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_float_type, tmp34) ; __ats_lab_cblas_asum_01944_ats_float_type_2cats_float_type: tmp34 = atsctrb_cblas_sasum (arg0, arg1, arg2) ; return (tmp34) ; } /* end of [cblas_asum_01944_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5126(line=231, offs=37) -- 5166(line=231, offs=77) */ ATSstaticdec() ats_double_type cblas_asum_01944_ats_double_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_double_type, tmp35) ; __ats_lab_cblas_asum_01944_ats_double_type_2cats_double_type: tmp35 = atsctrb_cblas_dasum (arg0, arg1, arg2) ; return (tmp35) ; } /* end of [cblas_asum_01944_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5203(line=232, offs=37) -- 5243(line=232, offs=77) */ ATSstaticdec() ats_float_type cblas_asum_01944_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_float_type, tmp36) ; __ats_lab_cblas_asum_01944_ats_fcomplex_type_2cats_float_type: tmp36 = atsctrb_cblas_scasum (arg0, arg1, arg2) ; return (tmp36) ; } /* end of [cblas_asum_01944_ats_fcomplex_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5280(line=233, offs=37) -- 5320(line=233, offs=77) */ ATSstaticdec() ats_double_type cblas_asum_01944_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_double_type, tmp37) ; __ats_lab_cblas_asum_01944_ats_dcomplex_type_2cats_double_type: tmp37 = atsctrb_cblas_dzasum (arg0, arg1, arg2) ; return (tmp37) ; } /* end of [cblas_asum_01944_ats_dcomplex_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5407(line=241, offs=31) -- 5447(line=241, offs=71) */ ATSstaticdec() ats_int_type cblas_iamax_01949_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp38) ; __ats_lab_cblas_iamax_01949_ats_float_type: tmp38 = atsctrb_cblas_isamax (arg0, arg1, arg2) ; return (tmp38) ; } /* end of [cblas_iamax_01949_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5478(line=242, offs=31) -- 5518(line=242, offs=71) */ ATSstaticdec() ats_int_type cblas_iamax_01949_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp39) ; __ats_lab_cblas_iamax_01949_ats_double_type: tmp39 = atsctrb_cblas_idamax (arg0, arg1, arg2) ; return (tmp39) ; } /* end of [cblas_iamax_01949_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5549(line=243, offs=31) -- 5589(line=243, offs=71) */ ATSstaticdec() ats_int_type cblas_iamax_01949_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp40) ; __ats_lab_cblas_iamax_01949_ats_fcomplex_type: tmp40 = atsctrb_cblas_icamax (arg0, arg1, arg2) ; return (tmp40) ; } /* end of [cblas_iamax_01949_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5620(line=244, offs=31) -- 5660(line=244, offs=71) */ ATSstaticdec() ats_int_type cblas_iamax_01949_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp41) ; __ats_lab_cblas_iamax_01949_ats_dcomplex_type: tmp41 = atsctrb_cblas_izamax (arg0, arg1, arg2) ; return (tmp41) ; } /* end of [cblas_iamax_01949_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5746(line=253, offs=3) -- 5803(line=253, offs=60) */ ATSstaticdec() ats_void_type cblas_swap_01954_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp42) ; __ats_lab_cblas_swap_01954_ats_float_type: /* tmp42 = */ atsctrb_cblas_sswap (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp42) */ ; } /* end of [cblas_swap_01954_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5866(line=257, offs=3) -- 5923(line=257, offs=60) */ ATSstaticdec() ats_void_type cblas_swap_01954_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp43) ; __ats_lab_cblas_swap_01954_ats_double_type: /* tmp43 = */ atsctrb_cblas_dswap (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp43) */ ; } /* end of [cblas_swap_01954_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 5987(line=261, offs=3) -- 6044(line=261, offs=60) */ ATSstaticdec() ats_void_type cblas_swap_01954_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp44) ; __ats_lab_cblas_swap_01954_ats_fcomplex_type: /* tmp44 = */ atsctrb_cblas_cswap (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp44) */ ; } /* end of [cblas_swap_01954_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6108(line=265, offs=3) -- 6165(line=265, offs=60) */ ATSstaticdec() ats_void_type cblas_swap_01954_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp45) ; __ats_lab_cblas_swap_01954_ats_dcomplex_type: /* tmp45 = */ atsctrb_cblas_zswap (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp45) */ ; } /* end of [cblas_swap_01954_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6282(line=275, offs=3) -- 6353(line=275, offs=74) */ ATSstaticdec() ats_void_type cblas_axpy_01964_ats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp46) ; __ats_lab_cblas_axpy_01964_ats_float_type: /* tmp46 = */ atsctrb_cblas_saxpy (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp46) */ ; } /* end of [cblas_axpy_01964_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6416(line=279, offs=3) -- 6487(line=279, offs=74) */ ATSstaticdec() ats_void_type cblas_axpy_01964_ats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp47) ; __ats_lab_cblas_axpy_01964_ats_double_type: /* tmp47 = */ atsctrb_cblas_daxpy (arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp47) */ ; } /* end of [cblas_axpy_01964_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6551(line=283, offs=3) -- 6661(line=285, offs=4) */ ATSstaticdec() ats_void_type cblas_axpy_01964_ats_fcomplex_type (ats_int_type arg0, ats_fcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_fcomplex_type, tmp49) ; __ats_lab_cblas_axpy_01964_ats_fcomplex_type: /* ats_fcomplex_type tmp49 ; */ tmp49 = arg1 ; /* tmp48 = */ atsctrb_cblas_caxpy (arg0, (&tmp49), arg2, arg3, arg4, arg5) ; return /* (tmp48) */ ; } /* end of [cblas_axpy_01964_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6725(line=288, offs=3) -- 6835(line=290, offs=4) */ ATSstaticdec() ats_void_type cblas_axpy_01964_ats_dcomplex_type (ats_int_type arg0, ats_dcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_dcomplex_type, tmp51) ; __ats_lab_cblas_axpy_01964_ats_dcomplex_type: /* ats_dcomplex_type tmp51 ; */ tmp51 = arg1 ; /* tmp50 = */ atsctrb_cblas_zaxpy (arg0, (&tmp51), arg2, arg3, arg4, arg5) ; return /* (tmp50) */ ; } /* end of [cblas_axpy_01964_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 6952(line=299, offs=3) -- 7009(line=299, offs=60) */ ATSstaticdec() ats_void_type cblas_copy_01959_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp52) ; __ats_lab_cblas_copy_01959_ats_float_type: /* tmp52 = */ atsctrb_cblas_scopy (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp52) */ ; } /* end of [cblas_copy_01959_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7072(line=303, offs=3) -- 7129(line=303, offs=60) */ ATSstaticdec() ats_void_type cblas_copy_01959_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp53) ; __ats_lab_cblas_copy_01959_ats_double_type: /* tmp53 = */ atsctrb_cblas_dcopy (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp53) */ ; } /* end of [cblas_copy_01959_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7193(line=307, offs=3) -- 7250(line=307, offs=60) */ ATSstaticdec() ats_void_type cblas_copy_01959_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp54) ; __ats_lab_cblas_copy_01959_ats_fcomplex_type: /* tmp54 = */ atsctrb_cblas_ccopy (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp54) */ ; } /* end of [cblas_copy_01959_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7314(line=311, offs=3) -- 7371(line=311, offs=60) */ ATSstaticdec() ats_void_type cblas_copy_01959_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ref_type arg3, ats_int_type arg4) { /* local vardec */ // ATSlocal_void (tmp55) ; __ats_lab_cblas_copy_01959_ats_dcomplex_type: /* tmp55 = */ atsctrb_cblas_zcopy (arg0, arg1, arg2, arg3, arg4) ; return /* (tmp55) */ ; } /* end of [cblas_copy_01959_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7502(line=321, offs=3) -- 7555(line=321, offs=56) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_float_type_2cats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp56) ; __ats_lab_cblas_scal_01969_ats_float_type_2cats_float_type: /* tmp56 = */ atsctrb_cblas_sscal (arg0, arg1, arg2, arg3) ; return /* (tmp56) */ ; } /* end of [cblas_scal_01969_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7631(line=325, offs=3) -- 7684(line=325, offs=56) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_double_type_2cats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp57) ; __ats_lab_cblas_scal_01969_ats_double_type_2cats_double_type: /* tmp57 = */ atsctrb_cblas_dscal (arg0, arg1, arg2, arg3) ; return /* (tmp57) */ ; } /* end of [cblas_scal_01969_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7760(line=328, offs=37) -- 7852(line=330, offs=4) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_fcomplex_type_2cats_fcomplex_type (ats_int_type arg0, ats_fcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp58) ; ATSlocal (ats_fcomplex_type, tmp59) ; __ats_lab_cblas_scal_01969_ats_fcomplex_type_2cats_fcomplex_type: /* ats_fcomplex_type tmp59 ; */ tmp59 = arg1 ; /* tmp58 = */ atsctrb_cblas_cscal (arg0, (&tmp59), arg2, arg3) ; return /* (tmp58) */ ; } /* end of [cblas_scal_01969_ats_fcomplex_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 7928(line=332, offs=37) -- 8020(line=334, offs=4) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_dcomplex_type_2cats_dcomplex_type (ats_int_type arg0, ats_dcomplex_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_dcomplex_type, tmp61) ; __ats_lab_cblas_scal_01969_ats_dcomplex_type_2cats_dcomplex_type: /* ats_dcomplex_type tmp61 ; */ tmp61 = arg1 ; /* tmp60 = */ atsctrb_cblas_zscal (arg0, (&tmp61), arg2, arg3) ; return /* (tmp60) */ ; } /* end of [cblas_scal_01969_ats_dcomplex_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 8097(line=337, offs=3) -- 8151(line=337, offs=57) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_float_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp62) ; __ats_lab_cblas_scal_01969_ats_fcomplex_type_2cats_float_type: /* tmp62 = */ atsctrb_cblas_csscal (arg0, arg1, arg2, arg3) ; return /* (tmp62) */ ; } /* end of [cblas_scal_01969_ats_fcomplex_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 8228(line=341, offs=3) -- 8282(line=341, offs=57) */ ATSstaticdec() ats_void_type cblas_scal_01969_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_double_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp63) ; __ats_lab_cblas_scal_01969_ats_dcomplex_type_2cats_double_type: /* tmp63 = */ atsctrb_cblas_zdscal (arg0, arg1, arg2, arg3) ; return /* (tmp63) */ ; } /* end of [cblas_scal_01969_ats_dcomplex_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 8450(line=357, offs=3) -- 8607(line=360, offs=4) */ ATSstaticdec() ats_void_type cblas_gemv_01976_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp64) ; __ats_lab_cblas_gemv_01976_ats_float_type: /* tmp64 = */ atsctrb_cblas_sgemv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp64) */ ; } /* end of [cblas_gemv_01976_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 8694(line=364, offs=3) -- 8851(line=367, offs=4) */ ATSstaticdec() ats_void_type cblas_gemv_01976_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp65) ; __ats_lab_cblas_gemv_01976_ats_double_type: /* tmp65 = */ atsctrb_cblas_dgemv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp65) */ ; } /* end of [cblas_gemv_01976_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 8937(line=370, offs=30) -- 9194(line=380, offs=4) */ ATSstaticdec() ats_void_type cblas_gemv_01976_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_fcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_fcomplex_type, tmp67) ; ATSlocal (ats_fcomplex_type, tmp68) ; __ats_lab_cblas_gemv_01976_ats_fcomplex_type: /* ats_fcomplex_type tmp67 ; */ tmp67 = arg4 ; /* ats_fcomplex_type tmp68 ; */ tmp68 = arg9 ; /* tmp66 = */ atsctrb_cblas_cgemv (arg0, arg1, arg2, arg3, (&tmp67), arg5, arg6, arg7, arg8, (&tmp68), arg10, arg11) ; return /* (tmp66) */ ; } /* end of [cblas_gemv_01976_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 9256(line=382, offs=30) -- 9513(line=392, offs=4) */ ATSstaticdec() ats_void_type cblas_gemv_01976_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_dcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp69) ; ATSlocal (ats_dcomplex_type, tmp70) ; ATSlocal (ats_dcomplex_type, tmp71) ; __ats_lab_cblas_gemv_01976_ats_dcomplex_type: /* ats_dcomplex_type tmp70 ; */ tmp70 = arg4 ; /* ats_dcomplex_type tmp71 ; */ tmp71 = arg9 ; /* tmp69 = */ atsctrb_cblas_zgemv (arg0, arg1, arg2, arg3, (&tmp70), arg5, arg6, arg7, arg8, (&tmp71), arg10, arg11) ; return /* (tmp69) */ ; } /* end of [cblas_gemv_01976_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 9595(line=396, offs=29) -- 9823(line=417, offs=4) */ ATSstaticdec() ats_void_type cblas_gbmv_01981_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_float_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_float_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp72) ; __ats_lab_cblas_gbmv_01981_ats_float_type: /* tmp72 = */ atsctrb_cblas_sgbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) ; return /* (tmp72) */ ; } /* end of [cblas_gbmv_01981_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 9908(line=420, offs=30) -- 10136(line=441, offs=4) */ ATSstaticdec() ats_void_type cblas_gbmv_01981_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_double_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_double_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp73) ; __ats_lab_cblas_gbmv_01981_ats_double_type: /* tmp73 = */ atsctrb_cblas_dgbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) ; return /* (tmp73) */ ; } /* end of [cblas_gbmv_01981_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 10222(line=444, offs=30) -- 10539(line=469, offs=4) */ ATSstaticdec() ats_void_type cblas_gbmv_01981_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_fcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_fcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp74) ; ATSlocal (ats_fcomplex_type, tmp75) ; ATSlocal (ats_fcomplex_type, tmp76) ; __ats_lab_cblas_gbmv_01981_ats_fcomplex_type: /* ats_fcomplex_type tmp75 ; */ tmp75 = arg6 ; /* ats_fcomplex_type tmp76 ; */ tmp76 = arg11 ; /* tmp74 = */ atsctrb_cblas_cgbmv (arg0, arg1, arg2, arg3, arg4, arg5, (&tmp75), arg7, arg8, arg9, arg10, (&tmp76), arg12, arg13) ; return /* (tmp74) */ ; } /* end of [cblas_gbmv_01981_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 10601(line=471, offs=30) -- 10918(line=496, offs=4) */ ATSstaticdec() ats_void_type cblas_gbmv_01981_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_dcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_dcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_dcomplex_type, tmp78) ; ATSlocal (ats_dcomplex_type, tmp79) ; __ats_lab_cblas_gbmv_01981_ats_dcomplex_type: /* ats_dcomplex_type tmp78 ; */ tmp78 = arg6 ; /* ats_dcomplex_type tmp79 ; */ tmp79 = arg11 ; /* tmp77 = */ atsctrb_cblas_zgbmv (arg0, arg1, arg2, arg3, arg4, arg5, (&tmp78), arg7, arg8, arg9, arg10, (&tmp79), arg12, arg13) ; return /* (tmp77) */ ; } /* end of [cblas_gbmv_01981_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11035(line=505, offs=3) -- 11146(line=506, offs=62) */ ATSstaticdec() ats_void_type cblas_trmv_01986_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp80) ; __ats_lab_cblas_trmv_01986_ats_float_type: /* tmp80 = */ atsctrb_cblas_strmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp80) */ ; } /* end of [cblas_trmv_01986_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11209(line=510, offs=3) -- 11320(line=511, offs=62) */ ATSstaticdec() ats_void_type cblas_trmv_01986_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp81) ; __ats_lab_cblas_trmv_01986_ats_double_type: /* tmp81 = */ atsctrb_cblas_dtrmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp81) */ ; } /* end of [cblas_trmv_01986_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11384(line=515, offs=3) -- 11495(line=516, offs=62) */ ATSstaticdec() ats_void_type cblas_trmv_01986_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp82) ; __ats_lab_cblas_trmv_01986_ats_fcomplex_type: /* tmp82 = */ atsctrb_cblas_ctrmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp82) */ ; } /* end of [cblas_trmv_01986_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11559(line=520, offs=3) -- 11670(line=521, offs=62) */ ATSstaticdec() ats_void_type cblas_trmv_01986_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp83) ; __ats_lab_cblas_trmv_01986_ats_dcomplex_type: /* tmp83 = */ atsctrb_cblas_ztrmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp83) */ ; } /* end of [cblas_trmv_01986_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11787(line=531, offs=3) -- 11904(line=532, offs=65) */ ATSstaticdec() ats_void_type cblas_tbmv_01991_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp84) ; __ats_lab_cblas_tbmv_01991_ats_float_type: /* tmp84 = */ atsctrb_cblas_stbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp84) */ ; } /* end of [cblas_tbmv_01991_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 11967(line=536, offs=3) -- 12084(line=537, offs=65) */ ATSstaticdec() ats_void_type cblas_tbmv_01991_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp85) ; __ats_lab_cblas_tbmv_01991_ats_double_type: /* tmp85 = */ atsctrb_cblas_dtbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp85) */ ; } /* end of [cblas_tbmv_01991_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 12148(line=541, offs=3) -- 12265(line=542, offs=65) */ ATSstaticdec() ats_void_type cblas_tbmv_01991_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp86) ; __ats_lab_cblas_tbmv_01991_ats_fcomplex_type: /* tmp86 = */ atsctrb_cblas_ctbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp86) */ ; } /* end of [cblas_tbmv_01991_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 12329(line=546, offs=3) -- 12446(line=547, offs=65) */ ATSstaticdec() ats_void_type cblas_tbmv_01991_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp87) ; __ats_lab_cblas_tbmv_01991_ats_dcomplex_type: /* tmp87 = */ atsctrb_cblas_ztbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp87) */ ; } /* end of [cblas_tbmv_01991_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 12563(line=557, offs=3) -- 12666(line=558, offs=58) */ ATSstaticdec() ats_void_type cblas_tpmv_01996_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp88) ; __ats_lab_cblas_tpmv_01996_ats_float_type: /* tmp88 = */ atsctrb_cblas_stpmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp88) */ ; } /* end of [cblas_tpmv_01996_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 12729(line=562, offs=3) -- 12832(line=563, offs=58) */ ATSstaticdec() ats_void_type cblas_tpmv_01996_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp89) ; __ats_lab_cblas_tpmv_01996_ats_double_type: /* tmp89 = */ atsctrb_cblas_dtpmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp89) */ ; } /* end of [cblas_tpmv_01996_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 12896(line=567, offs=3) -- 12999(line=568, offs=58) */ ATSstaticdec() ats_void_type cblas_tpmv_01996_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp90) ; __ats_lab_cblas_tpmv_01996_ats_fcomplex_type: /* tmp90 = */ atsctrb_cblas_ctpmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp90) */ ; } /* end of [cblas_tpmv_01996_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 13063(line=572, offs=3) -- 13166(line=573, offs=58) */ ATSstaticdec() ats_void_type cblas_tpmv_01996_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp91) ; __ats_lab_cblas_tpmv_01996_ats_dcomplex_type: /* tmp91 = */ atsctrb_cblas_ztpmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp91) */ ; } /* end of [cblas_tpmv_01996_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 13283(line=583, offs=3) -- 13394(line=584, offs=62) */ ATSstaticdec() ats_void_type cblas_trsv_02001_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp92) ; __ats_lab_cblas_trsv_02001_ats_float_type: /* tmp92 = */ atsctrb_cblas_strsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp92) */ ; } /* end of [cblas_trsv_02001_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 13457(line=588, offs=3) -- 13568(line=589, offs=62) */ ATSstaticdec() ats_void_type cblas_trsv_02001_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp93) ; __ats_lab_cblas_trsv_02001_ats_double_type: /* tmp93 = */ atsctrb_cblas_dtrsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp93) */ ; } /* end of [cblas_trsv_02001_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 13632(line=593, offs=3) -- 13743(line=594, offs=62) */ ATSstaticdec() ats_void_type cblas_trsv_02001_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp94) ; __ats_lab_cblas_trsv_02001_ats_fcomplex_type: /* tmp94 = */ atsctrb_cblas_ctrsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp94) */ ; } /* end of [cblas_trsv_02001_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 13807(line=598, offs=3) -- 13918(line=599, offs=62) */ ATSstaticdec() ats_void_type cblas_trsv_02001_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8) { /* local vardec */ // ATSlocal_void (tmp95) ; __ats_lab_cblas_trsv_02001_ats_dcomplex_type: /* tmp95 = */ atsctrb_cblas_ztrsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp95) */ ; } /* end of [cblas_trsv_02001_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14035(line=609, offs=3) -- 14152(line=610, offs=65) */ ATSstaticdec() ats_void_type cblas_tbsv_02006_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp96) ; __ats_lab_cblas_tbsv_02006_ats_float_type: /* tmp96 = */ atsctrb_cblas_stbsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp96) */ ; } /* end of [cblas_tbsv_02006_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14215(line=614, offs=3) -- 14332(line=615, offs=65) */ ATSstaticdec() ats_void_type cblas_tbsv_02006_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp97) ; __ats_lab_cblas_tbsv_02006_ats_double_type: /* tmp97 = */ atsctrb_cblas_dtbsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp97) */ ; } /* end of [cblas_tbsv_02006_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14396(line=619, offs=3) -- 14513(line=620, offs=65) */ ATSstaticdec() ats_void_type cblas_tbsv_02006_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp98) ; __ats_lab_cblas_tbsv_02006_ats_fcomplex_type: /* tmp98 = */ atsctrb_cblas_ctbsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp98) */ ; } /* end of [cblas_tbsv_02006_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14577(line=624, offs=3) -- 14694(line=625, offs=65) */ ATSstaticdec() ats_void_type cblas_tbsv_02006_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp99) ; __ats_lab_cblas_tbsv_02006_ats_dcomplex_type: /* tmp99 = */ atsctrb_cblas_ztbsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp99) */ ; } /* end of [cblas_tbsv_02006_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14811(line=635, offs=3) -- 14914(line=636, offs=58) */ ATSstaticdec() ats_void_type cblas_tpsv_02011_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp100) ; __ats_lab_cblas_tpsv_02011_ats_float_type: /* tmp100 = */ atsctrb_cblas_stpsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp100) */ ; } /* end of [cblas_tpsv_02011_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 14977(line=640, offs=3) -- 15080(line=641, offs=58) */ ATSstaticdec() ats_void_type cblas_tpsv_02011_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp101) ; __ats_lab_cblas_tpsv_02011_ats_double_type: /* tmp101 = */ atsctrb_cblas_dtpsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp101) */ ; } /* end of [cblas_tpsv_02011_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 15144(line=645, offs=3) -- 15247(line=646, offs=58) */ ATSstaticdec() ats_void_type cblas_tpsv_02011_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp102) ; __ats_lab_cblas_tpsv_02011_ats_fcomplex_type: /* tmp102 = */ atsctrb_cblas_ctpsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp102) */ ; } /* end of [cblas_tpsv_02011_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 15311(line=650, offs=3) -- 15414(line=651, offs=58) */ ATSstaticdec() ats_void_type cblas_tpsv_02011_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp103) ; __ats_lab_cblas_tpsv_02011_ats_dcomplex_type: /* tmp103 = */ atsctrb_cblas_ztpsv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp103) */ ; } /* end of [cblas_tpsv_02011_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 15525(line=661, offs=3) -- 15652(line=662, offs=70) */ ATSstaticdec() ats_void_type cblas_symv_02016_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp104) ; __ats_lab_cblas_symv_02016_ats_float_type: /* tmp104 = */ atsctrb_cblas_ssymv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp104) */ ; } /* end of [cblas_symv_02016_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 15715(line=666, offs=3) -- 15842(line=667, offs=70) */ ATSstaticdec() ats_void_type cblas_symv_02016_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp105) ; __ats_lab_cblas_symv_02016_ats_double_type: /* tmp105 = */ atsctrb_cblas_dsymv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp105) */ ; } /* end of [cblas_symv_02016_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 15953(line=677, offs=3) -- 16086(line=678, offs=73) */ ATSstaticdec() ats_void_type cblas_sbmv_02019_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp106) ; __ats_lab_cblas_sbmv_02019_ats_float_type: /* tmp106 = */ atsctrb_cblas_ssbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp106) */ ; } /* end of [cblas_sbmv_02019_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 16149(line=682, offs=3) -- 16282(line=683, offs=73) */ ATSstaticdec() ats_void_type cblas_sbmv_02019_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp107) ; __ats_lab_cblas_sbmv_02019_ats_double_type: /* tmp107 = */ atsctrb_cblas_dsbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp107) */ ; } /* end of [cblas_sbmv_02019_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 16393(line=693, offs=3) -- 16511(line=694, offs=65) */ ATSstaticdec() ats_void_type cblas_spmv_02022_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp108) ; __ats_lab_cblas_spmv_02022_ats_float_type: /* tmp108 = */ atsctrb_cblas_sspmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp108) */ ; } /* end of [cblas_spmv_02022_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 16574(line=698, offs=3) -- 16692(line=699, offs=65) */ ATSstaticdec() ats_void_type cblas_spmv_02022_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp109) ; __ats_lab_cblas_spmv_02022_ats_double_type: /* tmp109 = */ atsctrb_cblas_dspmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp109) */ ; } /* end of [cblas_spmv_02022_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 16802(line=710, offs=3) -- 16910(line=711, offs=60) */ ATSstaticdec() ats_void_type cblas_ger_02025_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp110) ; __ats_lab_cblas_ger_02025_ats_float_type: /* tmp110 = */ atsctrb_cblas_sger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp110) */ ; } /* end of [cblas_ger_02025_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 16971(line=715, offs=3) -- 17079(line=716, offs=60) */ ATSstaticdec() ats_void_type cblas_ger_02025_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp111) ; __ats_lab_cblas_ger_02025_ats_double_type: /* tmp111 = */ atsctrb_cblas_dger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp111) */ ; } /* end of [cblas_ger_02025_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 17187(line=726, offs=3) -- 17283(line=727, offs=54) */ ATSstaticdec() ats_void_type cblas_syr_02028_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp112) ; __ats_lab_cblas_syr_02028_ats_float_type: /* tmp112 = */ atsctrb_cblas_ssyr (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp112) */ ; } /* end of [cblas_syr_02028_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 17344(line=731, offs=3) -- 17440(line=732, offs=54) */ ATSstaticdec() ats_void_type cblas_syr_02028_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp113) ; __ats_lab_cblas_syr_02028_ats_double_type: /* tmp113 = */ atsctrb_cblas_dsyr (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp113) */ ; } /* end of [cblas_syr_02028_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 17550(line=742, offs=3) -- 17665(line=743, offs=64) */ ATSstaticdec() ats_void_type cblas_syr2_02031_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp114) ; __ats_lab_cblas_syr2_02031_ats_float_type: /* tmp114 = */ atsctrb_cblas_ssyr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp114) */ ; } /* end of [cblas_syr2_02031_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 17728(line=747, offs=3) -- 17843(line=748, offs=64) */ ATSstaticdec() ats_void_type cblas_syr2_02031_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp115) ; __ats_lab_cblas_syr2_02031_ats_double_type: /* tmp115 = */ atsctrb_cblas_dsyr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp115) */ ; } /* end of [cblas_syr2_02031_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 17952(line=758, offs=3) -- 18040(line=759, offs=50) */ ATSstaticdec() ats_void_type cblas_spr_02034_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp116) ; __ats_lab_cblas_spr_02034_ats_float_type: /* tmp116 = */ atsctrb_cblas_sspr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp116) */ ; } /* end of [cblas_spr_02034_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 18101(line=763, offs=3) -- 18189(line=764, offs=50) */ ATSstaticdec() ats_void_type cblas_spr_02034_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp117) ; __ats_lab_cblas_spr_02034_ats_double_type: /* tmp117 = */ atsctrb_cblas_dspr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp117) */ ; } /* end of [cblas_spr_02034_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 18299(line=774, offs=3) -- 18404(line=775, offs=59) */ ATSstaticdec() ats_void_type cblas_spr2_02037_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp118) ; __ats_lab_cblas_spr2_02037_ats_float_type: /* tmp118 = */ atsctrb_cblas_sspr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp118) */ ; } /* end of [cblas_spr2_02037_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 18467(line=779, offs=3) -- 18572(line=780, offs=59) */ ATSstaticdec() ats_void_type cblas_spr2_02037_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp119) ; __ats_lab_cblas_spr2_02037_ats_double_type: /* tmp119 = */ atsctrb_cblas_dspr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp119) */ ; } /* end of [cblas_spr2_02037_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 18705(line=790, offs=3) -- 18995(line=797, offs=4) */ ATSstaticdec() ats_void_type cblas_hemv_02040_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp120) ; __ats_lab_cblas_hemv_02040_ats_float_type: /* tmp120 = */ atsctrb_cblas_ssymv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp120) */ ; } /* end of [cblas_hemv_02040_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 19058(line=800, offs=3) -- 19350(line=807, offs=4) */ ATSstaticdec() ats_void_type cblas_hemv_02040_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp121) ; __ats_lab_cblas_hemv_02040_ats_double_type: /* tmp121 = */ atsctrb_cblas_dsymv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp121) */ ; } /* end of [cblas_hemv_02040_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 19414(line=810, offs=3) -- 19588(line=814, offs=4) */ ATSstaticdec() ats_void_type cblas_hemv_02040_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_fcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp122) ; ATSlocal (ats_fcomplex_type, tmp123) ; ATSlocal (ats_fcomplex_type, tmp124) ; __ats_lab_cblas_hemv_02040_ats_fcomplex_type: /* ats_fcomplex_type tmp123 ; */ tmp123 = arg3 ; /* ats_fcomplex_type tmp124 ; */ tmp124 = arg8 ; /* tmp122 = */ atsctrb_cblas_chemv (arg0, arg1, arg2, (&tmp123), arg4, arg5, arg6, arg7, (&tmp124), arg9, arg10) ; return /* (tmp122) */ ; } /* end of [cblas_hemv_02040_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 19652(line=817, offs=3) -- 19826(line=821, offs=4) */ ATSstaticdec() ats_void_type cblas_hemv_02040_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_dcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp125) ; ATSlocal (ats_dcomplex_type, tmp126) ; ATSlocal (ats_dcomplex_type, tmp127) ; __ats_lab_cblas_hemv_02040_ats_dcomplex_type: /* ats_dcomplex_type tmp126 ; */ tmp126 = arg3 ; /* ats_dcomplex_type tmp127 ; */ tmp127 = arg8 ; /* tmp125 = */ atsctrb_cblas_zhemv (arg0, arg1, arg2, (&tmp126), arg4, arg5, arg6, arg7, (&tmp127), arg9, arg10) ; return /* (tmp125) */ ; } /* end of [cblas_hemv_02040_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 19959(line=830, offs=3) -- 20251(line=836, offs=4) */ ATSstaticdec() ats_void_type cblas_hbmv_02043_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_float_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp128) ; __ats_lab_cblas_hbmv_02043_ats_float_type: /* tmp128 = */ atsctrb_cblas_ssbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp128) */ ; } /* end of [cblas_hbmv_02043_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 20314(line=839, offs=3) -- 20608(line=845, offs=4) */ ATSstaticdec() ats_void_type cblas_hbmv_02043_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_double_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp129) ; __ats_lab_cblas_hbmv_02043_ats_double_type: /* tmp129 = */ atsctrb_cblas_dsbmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp129) */ ; } /* end of [cblas_hbmv_02043_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 20672(line=848, offs=3) -- 20858(line=853, offs=4) */ ATSstaticdec() ats_void_type cblas_hbmv_02043_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_fcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp130) ; ATSlocal (ats_fcomplex_type, tmp131) ; ATSlocal (ats_fcomplex_type, tmp132) ; __ats_lab_cblas_hbmv_02043_ats_fcomplex_type: /* ats_fcomplex_type tmp131 ; */ tmp131 = arg4 ; /* ats_fcomplex_type tmp132 ; */ tmp132 = arg9 ; /* tmp130 = */ atsctrb_cblas_chbmv (arg0, arg1, arg2, arg3, (&tmp131), arg5, arg6, arg7, arg8, (&tmp132), arg10, arg11) ; return /* (tmp130) */ ; } /* end of [cblas_hbmv_02043_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 20922(line=856, offs=3) -- 21108(line=861, offs=4) */ ATSstaticdec() ats_void_type cblas_hbmv_02043_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_dcomplex_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp133) ; ATSlocal (ats_dcomplex_type, tmp134) ; ATSlocal (ats_dcomplex_type, tmp135) ; __ats_lab_cblas_hbmv_02043_ats_dcomplex_type: /* ats_dcomplex_type tmp134 ; */ tmp134 = arg4 ; /* ats_dcomplex_type tmp135 ; */ tmp135 = arg9 ; /* tmp133 = */ atsctrb_cblas_zhbmv (arg0, arg1, arg2, arg3, (&tmp134), arg5, arg6, arg7, arg8, (&tmp135), arg10, arg11) ; return /* (tmp133) */ ; } /* end of [cblas_hbmv_02043_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 21274(line=874, offs=3) -- 21553(line=880, offs=4) */ ATSstaticdec() ats_void_type cblas_hpmv_02046_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp136) ; __ats_lab_cblas_hpmv_02046_ats_float_type: /* tmp136 = */ atsctrb_cblas_sspmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp136) */ ; } /* end of [cblas_hpmv_02046_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 21616(line=883, offs=3) -- 21897(line=889, offs=4) */ ATSstaticdec() ats_void_type cblas_hpmv_02046_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp137) ; __ats_lab_cblas_hpmv_02046_ats_double_type: /* tmp137 = */ atsctrb_cblas_dspmv (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp137) */ ; } /* end of [cblas_hpmv_02046_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 21961(line=892, offs=3) -- 22126(line=896, offs=4) */ ATSstaticdec() ats_void_type cblas_hpmv_02046_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp138) ; ATSlocal (ats_fcomplex_type, tmp139) ; ATSlocal (ats_fcomplex_type, tmp140) ; __ats_lab_cblas_hpmv_02046_ats_fcomplex_type: /* ats_fcomplex_type tmp139 ; */ tmp139 = arg3 ; /* ats_fcomplex_type tmp140 ; */ tmp140 = arg7 ; /* tmp138 = */ atsctrb_cblas_chpmv (arg0, arg1, arg2, (&tmp139), arg4, arg5, arg6, (&tmp140), arg8, arg9) ; return /* (tmp138) */ ; } /* end of [cblas_hpmv_02046_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 22190(line=899, offs=3) -- 22355(line=903, offs=4) */ ATSstaticdec() ats_void_type cblas_hpmv_02046_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp141) ; ATSlocal (ats_dcomplex_type, tmp142) ; ATSlocal (ats_dcomplex_type, tmp143) ; __ats_lab_cblas_hpmv_02046_ats_dcomplex_type: /* ats_dcomplex_type tmp142 ; */ tmp142 = arg3 ; /* ats_dcomplex_type tmp143 ; */ tmp143 = arg7 ; /* tmp141 = */ atsctrb_cblas_zhpmv (arg0, arg1, arg2, (&tmp142), arg4, arg5, arg6, (&tmp143), arg8, arg9) ; return /* (tmp141) */ ; } /* end of [cblas_hpmv_02046_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 22488(line=912, offs=3) -- 22596(line=913, offs=60) */ ATSstaticdec() ats_void_type cblas_geru_02049_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp144) ; __ats_lab_cblas_geru_02049_ats_float_type: /* tmp144 = */ atsctrb_cblas_sger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp144) */ ; } /* end of [cblas_geru_02049_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 22659(line=917, offs=3) -- 22767(line=918, offs=60) */ ATSstaticdec() ats_void_type cblas_geru_02049_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp145) ; __ats_lab_cblas_geru_02049_ats_double_type: /* tmp145 = */ atsctrb_cblas_dger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp145) */ ; } /* end of [cblas_geru_02049_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 22831(line=922, offs=3) -- 22971(line=926, offs=4) */ ATSstaticdec() ats_void_type cblas_geru_02049_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp146) ; ATSlocal (ats_fcomplex_type, tmp147) ; __ats_lab_cblas_geru_02049_ats_fcomplex_type: /* ats_fcomplex_type tmp147 ; */ tmp147 = arg3 ; /* tmp146 = */ atsctrb_cblas_cgeru (arg0, arg1, arg2, (&tmp147), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp146) */ ; } /* end of [cblas_geru_02049_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 23035(line=929, offs=3) -- 23183(line=933, offs=4) */ ATSstaticdec() ats_void_type cblas_geru_02049_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp148) ; ATSlocal (ats_dcomplex_type, tmp149) ; __ats_lab_cblas_geru_02049_ats_dcomplex_type: /* ats_dcomplex_type tmp149 ; */ tmp149 = arg3 ; /* tmp148 = */ atsctrb_cblas_zgeru (arg0, arg1, arg2, (&tmp149), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp148) */ ; } /* end of [cblas_geru_02049_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 23316(line=942, offs=3) -- 23424(line=943, offs=60) */ ATSstaticdec() ats_void_type cblas_gerc_02052_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp150) ; __ats_lab_cblas_gerc_02052_ats_float_type: /* tmp150 = */ atsctrb_cblas_sger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp150) */ ; } /* end of [cblas_gerc_02052_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 23487(line=947, offs=3) -- 23595(line=948, offs=60) */ ATSstaticdec() ats_void_type cblas_gerc_02052_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp151) ; __ats_lab_cblas_gerc_02052_ats_double_type: /* tmp151 = */ atsctrb_cblas_dger (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp151) */ ; } /* end of [cblas_gerc_02052_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 23659(line=952, offs=3) -- 23799(line=956, offs=4) */ ATSstaticdec() ats_void_type cblas_gerc_02052_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp152) ; ATSlocal (ats_fcomplex_type, tmp153) ; __ats_lab_cblas_gerc_02052_ats_fcomplex_type: /* ats_fcomplex_type tmp153 ; */ tmp153 = arg3 ; /* tmp152 = */ atsctrb_cblas_cgerc (arg0, arg1, arg2, (&tmp153), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp152) */ ; } /* end of [cblas_gerc_02052_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 23863(line=959, offs=3) -- 24011(line=963, offs=4) */ ATSstaticdec() ats_void_type cblas_gerc_02052_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (ats_dcomplex_type, tmp155) ; __ats_lab_cblas_gerc_02052_ats_dcomplex_type: /* ats_dcomplex_type tmp155 ; */ tmp155 = arg3 ; /* tmp154 = */ atsctrb_cblas_zgerc (arg0, arg1, arg2, (&tmp155), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp154) */ ; } /* end of [cblas_gerc_02052_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 24148(line=972, offs=3) -- 24403(line=978, offs=4) */ ATSstaticdec() ats_void_type cblas_her_02055_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp156) ; __ats_lab_cblas_her_02055_ats_float_type_2cats_float_type: /* tmp156 = */ atsctrb_cblas_ssyr (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp156) */ ; } /* end of [cblas_her_02055_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 24477(line=981, offs=3) -- 24734(line=987, offs=4) */ ATSstaticdec() ats_void_type cblas_her_02055_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp157) ; __ats_lab_cblas_her_02055_ats_double_type_2cats_double_type: /* tmp157 = */ atsctrb_cblas_dsyr (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp157) */ ; } /* end of [cblas_her_02055_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 24809(line=990, offs=3) -- 24905(line=991, offs=54) */ ATSstaticdec() ats_void_type cblas_her_02055_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp158) ; __ats_lab_cblas_her_02055_ats_float_type_2cats_fcomplex_type: /* tmp158 = */ atsctrb_cblas_cher (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp158) */ ; } /* end of [cblas_her_02055_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 24980(line=995, offs=3) -- 25076(line=996, offs=54) */ ATSstaticdec() ats_void_type cblas_her_02055_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7) { /* local vardec */ // ATSlocal_void (tmp159) ; __ats_lab_cblas_her_02055_ats_double_type_2cats_dcomplex_type: /* tmp159 = */ atsctrb_cblas_zher (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) ; return /* (tmp159) */ ; } /* end of [cblas_her_02055_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 25215(line=1006, offs=3) -- 25493(line=1013, offs=4) */ ATSstaticdec() ats_void_type cblas_her2_02058_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp160) ; __ats_lab_cblas_her2_02058_ats_float_type: /* tmp160 = */ atsctrb_cblas_ssyr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp160) */ ; } /* end of [cblas_her2_02058_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 25556(line=1016, offs=3) -- 25836(line=1023, offs=4) */ ATSstaticdec() ats_void_type cblas_her2_02058_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp161) ; __ats_lab_cblas_her2_02058_ats_double_type: /* tmp161 = */ atsctrb_cblas_dsyr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp161) */ ; } /* end of [cblas_her2_02058_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 25900(line=1026, offs=3) -- 26046(line=1030, offs=4) */ ATSstaticdec() ats_void_type cblas_her2_02058_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp162) ; ATSlocal (ats_fcomplex_type, tmp163) ; __ats_lab_cblas_her2_02058_ats_fcomplex_type: /* ats_fcomplex_type tmp163 ; */ tmp163 = arg3 ; /* tmp162 = */ atsctrb_cblas_cher2 (arg0, arg1, arg2, (&tmp163), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp162) */ ; } /* end of [cblas_her2_02058_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 26110(line=1033, offs=3) -- 26256(line=1037, offs=4) */ ATSstaticdec() ats_void_type cblas_her2_02058_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9) { /* local vardec */ // ATSlocal_void (tmp164) ; ATSlocal (ats_dcomplex_type, tmp165) ; __ats_lab_cblas_her2_02058_ats_dcomplex_type: /* ats_dcomplex_type tmp165 ; */ tmp165 = arg3 ; /* tmp164 = */ atsctrb_cblas_zher2 (arg0, arg1, arg2, (&tmp165), arg4, arg5, arg6, arg7, arg8, arg9) ; return /* (tmp164) */ ; } /* end of [cblas_her2_02058_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 26393(line=1046, offs=3) -- 26638(line=1052, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr_02061_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp166) ; __ats_lab_cblas_hpr_02061_ats_float_type_2cats_float_type: /* tmp166 = */ atsctrb_cblas_sspr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp166) */ ; } /* end of [cblas_hpr_02061_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 26712(line=1055, offs=3) -- 26959(line=1061, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr_02061_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp167) ; __ats_lab_cblas_hpr_02061_ats_double_type_2cats_double_type: /* tmp167 = */ atsctrb_cblas_dspr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp167) */ ; } /* end of [cblas_hpr_02061_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 27034(line=1064, offs=3) -- 27122(line=1065, offs=50) */ ATSstaticdec() ats_void_type cblas_hpr_02061_ats_float_type_2cats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp168) ; __ats_lab_cblas_hpr_02061_ats_float_type_2cats_fcomplex_type: /* tmp168 = */ atsctrb_cblas_chpr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp168) */ ; } /* end of [cblas_hpr_02061_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 27197(line=1069, offs=3) -- 27285(line=1070, offs=50) */ ATSstaticdec() ats_void_type cblas_hpr_02061_ats_double_type_2cats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp169) ; __ats_lab_cblas_hpr_02061_ats_double_type_2cats_dcomplex_type: /* tmp169 = */ atsctrb_cblas_zhpr (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp169) */ ; } /* end of [cblas_hpr_02061_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 27424(line=1080, offs=3) -- 27692(line=1086, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr2_02064_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_float_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp170) ; __ats_lab_cblas_hpr2_02064_ats_float_type: /* tmp170 = */ atsctrb_cblas_sspr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp170) */ ; } /* end of [cblas_hpr2_02064_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 27755(line=1089, offs=3) -- 28025(line=1095, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr2_02064_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_double_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp171) ; __ats_lab_cblas_hpr2_02064_ats_double_type: /* tmp171 = */ atsctrb_cblas_dspr2 (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) ; return /* (tmp171) */ ; } /* end of [cblas_hpr2_02064_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 28089(line=1098, offs=3) -- 28225(line=1102, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr2_02064_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_fcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp172) ; ATSlocal (ats_fcomplex_type, tmp173) ; __ats_lab_cblas_hpr2_02064_ats_fcomplex_type: /* ats_fcomplex_type tmp173 ; */ tmp173 = arg3 ; /* tmp172 = */ atsctrb_cblas_chpr2 (arg0, arg1, arg2, (&tmp173), arg4, arg5, arg6, arg7, arg8) ; return /* (tmp172) */ ; } /* end of [cblas_hpr2_02064_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 28289(line=1105, offs=3) -- 28425(line=1109, offs=4) */ ATSstaticdec() ats_void_type cblas_hpr2_02064_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_dcomplex_type arg3, ats_ref_type arg4, ats_int_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8) { /* local vardec */ // ATSlocal_void (tmp174) ; ATSlocal (ats_dcomplex_type, tmp175) ; __ats_lab_cblas_hpr2_02064_ats_dcomplex_type: /* ats_dcomplex_type tmp175 ; */ tmp175 = arg3 ; /* tmp174 = */ atsctrb_cblas_zhpr2 (arg0, arg1, arg2, (&tmp175), arg4, arg5, arg6, arg7, arg8) ; return /* (tmp174) */ ; } /* end of [cblas_hpr2_02064_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 28559(line=1123, offs=4) -- 28828(line=1130, offs=6) */ ATSstaticdec() ats_void_type cblas_gemm_overlap_check_136 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp176) ; ATSlocal (ats_bool_type, tmp177) ; ATSlocal (ats_bool_type, tmp178) ; // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; __ats_lab_cblas_gemm_overlap_check_136: tmp178 = atspre_peq (arg0, arg2) ; if (tmp178) { tmp177 = ats_true_bool ; } else { tmp177 = atspre_peq (arg1, arg2) ; } /* end of [if] */ if (tmp177) { /* tmp179 = */ atspre_prerr_string (ATSstrcst("error(ATS/CBLAS): cblas_gemm")) ; /* tmp180 = */ atspre_prerr_string (ATSstrcst(": overlapping between input and output is not allowed!")) ; /* tmp181 = */ atspre_prerr_newline () ; /* tmp176 = */ ats_exit (1) ; } else { /* empty */ } /* end of [if] */ return /* (tmp176) */ ; } /* end of [cblas_gemm_overlap_check_136] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 28910(line=1133, offs=29) -- 29224(line=1145, offs=4) */ ATSstaticdec() ats_void_type atsctrb_cblas_gemm_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_float_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_float_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; __ats_lab_atsctrb_cblas_gemm_ats_float_type: /* tmp183 = */ cblas_gemm_overlap_check_136 (arg7, arg9, arg12) ; /* tmp182 = */ atsctrb_cblas_sgemm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) ; return /* (tmp182) */ ; } /* end of [atsctrb_cblas_gemm_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 29285(line=1147, offs=30) -- 29599(line=1159, offs=4) */ ATSstaticdec() ats_void_type atsctrb_cblas_gemm_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_double_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_double_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; __ats_lab_atsctrb_cblas_gemm_ats_double_type: /* tmp185 = */ cblas_gemm_overlap_check_136 (arg7, arg9, arg12) ; /* tmp184 = */ atsctrb_cblas_dgemm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) ; return /* (tmp184) */ ; } /* end of [atsctrb_cblas_gemm_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 29661(line=1161, offs=30) -- 30027(line=1174, offs=4) */ ATSstaticdec() ats_void_type atsctrb_cblas_gemm_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_fcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_fcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; ATSlocal (ats_fcomplex_type, tmp188) ; ATSlocal (ats_fcomplex_type, tmp189) ; __ats_lab_atsctrb_cblas_gemm_ats_fcomplex_type: /* tmp187 = */ cblas_gemm_overlap_check_136 (arg7, arg9, arg12) ; /* ats_fcomplex_type tmp188 ; */ tmp188 = arg6 ; /* ats_fcomplex_type tmp189 ; */ tmp189 = arg11 ; /* tmp186 = */ atsctrb_cblas_cgemm (arg0, arg1, arg2, arg3, arg4, arg5, (&tmp188), arg7, arg8, arg9, arg10, (&tmp189), arg12, arg13) ; return /* (tmp186) */ ; } /* end of [atsctrb_cblas_gemm_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 30089(line=1176, offs=30) -- 30455(line=1189, offs=4) */ ATSstaticdec() ats_void_type atsctrb_cblas_gemm_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_dcomplex_type arg6, ats_ref_type arg7, ats_int_type arg8, ats_ref_type arg9, ats_int_type arg10, ats_dcomplex_type arg11, ats_ref_type arg12, ats_int_type arg13) { /* local vardec */ // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; ATSlocal (ats_dcomplex_type, tmp192) ; ATSlocal (ats_dcomplex_type, tmp193) ; __ats_lab_atsctrb_cblas_gemm_ats_dcomplex_type: /* tmp191 = */ cblas_gemm_overlap_check_136 (arg7, arg9, arg12) ; /* ats_dcomplex_type tmp192 ; */ tmp192 = arg6 ; /* ats_dcomplex_type tmp193 ; */ tmp193 = arg11 ; /* tmp190 = */ atsctrb_cblas_zgemm (arg0, arg1, arg2, arg3, arg4, arg5, (&tmp192), arg7, arg8, arg9, arg10, (&tmp193), arg12, arg13) ; return /* (tmp190) */ ; } /* end of [atsctrb_cblas_gemm_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 30572(line=1198, offs=3) -- 30711(line=1199, offs=76) */ ATSstaticdec() ats_void_type cblas_syrk_02073_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp194) ; __ats_lab_cblas_syrk_02073_ats_float_type: /* tmp194 = */ atsctrb_cblas_ssyrk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp194) */ ; } /* end of [cblas_syrk_02073_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 30774(line=1203, offs=3) -- 30913(line=1204, offs=76) */ ATSstaticdec() ats_void_type cblas_syrk_02073_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp195) ; __ats_lab_cblas_syrk_02073_ats_double_type: /* tmp195 = */ atsctrb_cblas_dsyrk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp195) */ ; } /* end of [cblas_syrk_02073_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 30977(line=1208, offs=3) -- 31179(line=1212, offs=4) */ ATSstaticdec() ats_void_type cblas_syrk_02073_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_fcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp196) ; ATSlocal (ats_fcomplex_type, tmp197) ; ATSlocal (ats_fcomplex_type, tmp198) ; __ats_lab_cblas_syrk_02073_ats_fcomplex_type: /* ats_fcomplex_type tmp197 ; */ tmp197 = arg5 ; /* ats_fcomplex_type tmp198 ; */ tmp198 = arg8 ; /* tmp196 = */ atsctrb_cblas_csyrk (arg0, arg1, arg2, arg3, arg4, (&tmp197), arg6, arg7, (&tmp198), arg9, arg10) ; return /* (tmp196) */ ; } /* end of [cblas_syrk_02073_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 31243(line=1215, offs=3) -- 31445(line=1219, offs=4) */ ATSstaticdec() ats_void_type cblas_syrk_02073_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_dcomplex_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp199) ; ATSlocal (ats_dcomplex_type, tmp200) ; ATSlocal (ats_dcomplex_type, tmp201) ; __ats_lab_cblas_syrk_02073_ats_dcomplex_type: /* ats_dcomplex_type tmp200 ; */ tmp200 = arg5 ; /* ats_dcomplex_type tmp201 ; */ tmp201 = arg8 ; /* tmp199 = */ atsctrb_cblas_zsyrk (arg0, arg1, arg2, arg3, arg4, (&tmp200), arg6, arg7, (&tmp201), arg9, arg10) ; return /* (tmp199) */ ; } /* end of [cblas_syrk_02073_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 31564(line=1228, offs=3) -- 31728(line=1231, offs=4) */ ATSstaticdec() ats_void_type cblas_syr2k_02078_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp202) ; __ats_lab_cblas_syr2k_02078_ats_float_type: /* tmp202 = */ atsctrb_cblas_ssyr2k (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp202) */ ; } /* end of [cblas_syr2k_02078_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 31793(line=1235, offs=3) -- 31957(line=1238, offs=4) */ ATSstaticdec() ats_void_type cblas_syr2k_02078_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp203) ; __ats_lab_cblas_syr2k_02078_ats_double_type: /* tmp203 = */ atsctrb_cblas_dsyr2k (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp203) */ ; } /* end of [cblas_syr2k_02078_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 32023(line=1242, offs=3) -- 32250(line=1248, offs=4) */ ATSstaticdec() ats_void_type cblas_syr2k_02078_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp204) ; ATSlocal (ats_fcomplex_type, tmp205) ; ATSlocal (ats_fcomplex_type, tmp206) ; __ats_lab_cblas_syr2k_02078_ats_fcomplex_type: /* ats_fcomplex_type tmp205 ; */ tmp205 = arg5 ; /* ats_fcomplex_type tmp206 ; */ tmp206 = arg10 ; /* tmp204 = */ atsctrb_cblas_csyr2k (arg0, arg1, arg2, arg3, arg4, (&tmp205), arg6, arg7, arg8, arg9, (&tmp206), arg11, arg12) ; return /* (tmp204) */ ; } /* end of [cblas_syr2k_02078_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 32316(line=1251, offs=3) -- 32543(line=1257, offs=4) */ ATSstaticdec() ats_void_type cblas_syr2k_02078_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp207) ; ATSlocal (ats_dcomplex_type, tmp208) ; ATSlocal (ats_dcomplex_type, tmp209) ; __ats_lab_cblas_syr2k_02078_ats_dcomplex_type: /* ats_dcomplex_type tmp208 ; */ tmp208 = arg5 ; /* ats_dcomplex_type tmp209 ; */ tmp209 = arg10 ; /* tmp207 = */ atsctrb_cblas_zsyr2k (arg0, arg1, arg2, arg3, arg4, (&tmp208), arg6, arg7, arg8, arg9, (&tmp209), arg11, arg12) ; return /* (tmp207) */ ; } /* end of [cblas_syr2k_02078_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 32661(line=1266, offs=3) -- 32814(line=1267, offs=83) */ ATSstaticdec() ats_void_type cblas_symm_02083_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp210) ; __ats_lab_cblas_symm_02083_ats_float_type: /* tmp210 = */ atsctrb_cblas_ssymm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp210) */ ; } /* end of [cblas_symm_02083_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 32877(line=1271, offs=3) -- 33030(line=1272, offs=83) */ ATSstaticdec() ats_void_type cblas_symm_02083_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp211) ; __ats_lab_cblas_symm_02083_ats_double_type: /* tmp211 = */ atsctrb_cblas_dsymm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp211) */ ; } /* end of [cblas_symm_02083_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 33094(line=1276, offs=3) -- 33310(line=1280, offs=4) */ ATSstaticdec() ats_void_type cblas_symm_02083_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp212) ; ATSlocal (ats_fcomplex_type, tmp213) ; ATSlocal (ats_fcomplex_type, tmp214) ; __ats_lab_cblas_symm_02083_ats_fcomplex_type: /* ats_fcomplex_type tmp213 ; */ tmp213 = arg5 ; /* ats_fcomplex_type tmp214 ; */ tmp214 = arg10 ; /* tmp212 = */ atsctrb_cblas_csymm (arg0, arg1, arg2, arg3, arg4, (&tmp213), arg6, arg7, arg8, arg9, (&tmp214), arg11, arg12) ; return /* (tmp212) */ ; } /* end of [cblas_symm_02083_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 33374(line=1283, offs=3) -- 33590(line=1287, offs=4) */ ATSstaticdec() ats_void_type cblas_symm_02083_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp215) ; ATSlocal (ats_dcomplex_type, tmp216) ; ATSlocal (ats_dcomplex_type, tmp217) ; __ats_lab_cblas_symm_02083_ats_dcomplex_type: /* ats_dcomplex_type tmp216 ; */ tmp216 = arg5 ; /* ats_dcomplex_type tmp217 ; */ tmp217 = arg10 ; /* tmp215 = */ atsctrb_cblas_zsymm (arg0, arg1, arg2, arg3, arg4, (&tmp216), arg6, arg7, arg8, arg9, (&tmp217), arg11, arg12) ; return /* (tmp215) */ ; } /* end of [cblas_symm_02083_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 33707(line=1296, offs=3) -- 33868(line=1299, offs=4) */ ATSstaticdec() ats_void_type cblas_trmm_02088_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp218) ; __ats_lab_cblas_trmm_02088_ats_float_type: /* tmp218 = */ atsctrb_cblas_strmm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp218) */ ; } /* end of [cblas_trmm_02088_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 33955(line=1303, offs=3) -- 34116(line=1306, offs=4) */ ATSstaticdec() ats_void_type cblas_trmm_02088_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp219) ; __ats_lab_cblas_trmm_02088_ats_double_type: /* tmp219 = */ atsctrb_cblas_dtrmm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp219) */ ; } /* end of [cblas_trmm_02088_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 34202(line=1309, offs=30) -- 34436(line=1318, offs=4) */ ATSstaticdec() ats_void_type cblas_trmm_02088_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp220) ; ATSlocal (ats_fcomplex_type, tmp221) ; __ats_lab_cblas_trmm_02088_ats_fcomplex_type: /* ats_fcomplex_type tmp221 ; */ tmp221 = arg7 ; /* tmp220 = */ atsctrb_cblas_ctrmm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, (&tmp221), arg8, arg9, arg10, arg11) ; return /* (tmp220) */ ; } /* end of [cblas_trmm_02088_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 34498(line=1320, offs=30) -- 34732(line=1329, offs=4) */ ATSstaticdec() ats_void_type cblas_trmm_02088_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp222) ; ATSlocal (ats_dcomplex_type, tmp223) ; __ats_lab_cblas_trmm_02088_ats_dcomplex_type: /* ats_dcomplex_type tmp223 ; */ tmp223 = arg7 ; /* tmp222 = */ atsctrb_cblas_ztrmm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, (&tmp223), arg8, arg9, arg10, arg11) ; return /* (tmp222) */ ; } /* end of [cblas_trmm_02088_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 34849(line=1338, offs=3) -- 35010(line=1341, offs=4) */ ATSstaticdec() ats_void_type cblas_trsm_02093_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_float_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp224) ; __ats_lab_cblas_trsm_02093_ats_float_type: /* tmp224 = */ atsctrb_cblas_strsm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp224) */ ; } /* end of [cblas_trsm_02093_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 35097(line=1345, offs=3) -- 35258(line=1348, offs=4) */ ATSstaticdec() ats_void_type cblas_trsm_02093_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_double_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp225) ; __ats_lab_cblas_trsm_02093_ats_double_type: /* tmp225 = */ atsctrb_cblas_dtrsm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) ; return /* (tmp225) */ ; } /* end of [cblas_trsm_02093_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 35344(line=1351, offs=30) -- 35578(line=1360, offs=4) */ ATSstaticdec() ats_void_type cblas_trsm_02093_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_fcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp226) ; ATSlocal (ats_fcomplex_type, tmp227) ; __ats_lab_cblas_trsm_02093_ats_fcomplex_type: /* ats_fcomplex_type tmp227 ; */ tmp227 = arg7 ; /* tmp226 = */ atsctrb_cblas_ctrsm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, (&tmp227), arg8, arg9, arg10, arg11) ; return /* (tmp226) */ ; } /* end of [cblas_trsm_02093_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 35640(line=1362, offs=30) -- 35874(line=1371, offs=4) */ ATSstaticdec() ats_void_type cblas_trsm_02093_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_int_type arg5, ats_int_type arg6, ats_dcomplex_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_ref_type arg10, ats_int_type arg11) { /* local vardec */ // ATSlocal_void (tmp228) ; ATSlocal (ats_dcomplex_type, tmp229) ; __ats_lab_cblas_trsm_02093_ats_dcomplex_type: /* ats_dcomplex_type tmp229 ; */ tmp229 = arg7 ; /* tmp228 = */ atsctrb_cblas_ztrsm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, (&tmp229), arg8, arg9, arg10, arg11) ; return /* (tmp228) */ ; } /* end of [cblas_trsm_02093_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 36007(line=1380, offs=3) -- 36323(line=1387, offs=4) */ ATSstaticdec() ats_void_type cblas_hemm_02098_ats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp230) ; __ats_lab_cblas_hemm_02098_ats_float_type: /* tmp230 = */ atsctrb_cblas_ssymm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp230) */ ; } /* end of [cblas_hemm_02098_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 36386(line=1390, offs=3) -- 36704(line=1397, offs=4) */ ATSstaticdec() ats_void_type cblas_hemm_02098_ats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp231) ; __ats_lab_cblas_hemm_02098_ats_double_type: /* tmp231 = */ atsctrb_cblas_dsymm (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp231) */ ; } /* end of [cblas_hemm_02098_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 36768(line=1400, offs=3) -- 36984(line=1404, offs=4) */ ATSstaticdec() ats_void_type cblas_hemm_02098_ats_fcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_fcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp232) ; ATSlocal (ats_fcomplex_type, tmp233) ; ATSlocal (ats_fcomplex_type, tmp234) ; __ats_lab_cblas_hemm_02098_ats_fcomplex_type: /* ats_fcomplex_type tmp233 ; */ tmp233 = arg5 ; /* ats_fcomplex_type tmp234 ; */ tmp234 = arg10 ; /* tmp232 = */ atsctrb_cblas_chemm (arg0, arg1, arg2, arg3, arg4, (&tmp233), arg6, arg7, arg8, arg9, (&tmp234), arg11, arg12) ; return /* (tmp232) */ ; } /* end of [cblas_hemm_02098_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 37048(line=1407, offs=3) -- 37264(line=1411, offs=4) */ ATSstaticdec() ats_void_type cblas_hemm_02098_ats_dcomplex_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_dcomplex_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp235) ; ATSlocal (ats_dcomplex_type, tmp236) ; ATSlocal (ats_dcomplex_type, tmp237) ; __ats_lab_cblas_hemm_02098_ats_dcomplex_type: /* ats_dcomplex_type tmp236 ; */ tmp236 = arg5 ; /* ats_dcomplex_type tmp237 ; */ tmp237 = arg10 ; /* tmp235 = */ atsctrb_cblas_zhemm (arg0, arg1, arg2, arg3, arg4, (&tmp236), arg6, arg7, arg8, arg9, (&tmp237), arg11, arg12) ; return /* (tmp235) */ ; } /* end of [cblas_hemm_02098_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 37403(line=1420, offs=3) -- 37705(line=1427, offs=4) */ ATSstaticdec() ats_void_type cblas_herk_02101_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp238) ; __ats_lab_cblas_herk_02101_ats_float_type_2cats_float_type: /* tmp238 = */ atsctrb_cblas_ssyrk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp238) */ ; } /* end of [cblas_herk_02101_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 37775(line=1430, offs=3) -- 38079(line=1437, offs=4) */ ATSstaticdec() ats_void_type cblas_herk_02101_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp239) ; __ats_lab_cblas_herk_02101_ats_double_type_2cats_double_type: /* tmp239 = */ atsctrb_cblas_dsyrk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp239) */ ; } /* end of [cblas_herk_02101_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 38149(line=1440, offs=3) -- 38298(line=1442, offs=4) */ ATSstaticdec() ats_void_type cblas_herk_02101_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_float_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp240) ; __ats_lab_cblas_herk_02101_ats_fcomplex_type_2cats_float_type: /* tmp240 = */ atsctrb_cblas_cherk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp240) */ ; } /* end of [cblas_herk_02101_ats_fcomplex_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 38369(line=1445, offs=3) -- 38518(line=1447, offs=4) */ ATSstaticdec() ats_void_type cblas_herk_02101_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_double_type arg8, ats_ref_type arg9, ats_int_type arg10) { /* local vardec */ // ATSlocal_void (tmp241) ; __ats_lab_cblas_herk_02101_ats_dcomplex_type_2cats_double_type: /* tmp241 = */ atsctrb_cblas_zherk (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) ; return /* (tmp241) */ ; } /* end of [cblas_herk_02101_ats_dcomplex_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 38657(line=1455, offs=36) -- 39006(line=1466, offs=4) */ ATSstaticdec() ats_void_type cblas_her2k_02104_ats_float_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_float_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp242) ; __ats_lab_cblas_her2k_02104_ats_float_type_2cats_float_type: /* tmp242 = */ atsctrb_cblas_ssyr2k (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp242) */ ; } /* end of [cblas_her2k_02104_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 39077(line=1468, offs=38) -- 39428(line=1479, offs=4) */ ATSstaticdec() ats_void_type cblas_her2k_02104_ats_double_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_double_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp243) ; __ats_lab_cblas_her2k_02104_ats_double_type_2cats_double_type: /* tmp243 = */ atsctrb_cblas_dsyr2k (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp243) */ ; } /* end of [cblas_her2k_02104_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 39498(line=1481, offs=37) -- 39711(line=1489, offs=4) */ ATSstaticdec() ats_void_type cblas_her2k_02104_ats_fcomplex_type_2cats_float_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_fcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_float_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp244) ; ATSlocal (ats_fcomplex_type, tmp245) ; __ats_lab_cblas_her2k_02104_ats_fcomplex_type_2cats_float_type: /* ats_fcomplex_type tmp245 ; */ tmp245 = arg5 ; /* tmp244 = */ atsctrb_cblas_cher2k (arg0, arg1, arg2, arg3, arg4, (&tmp245), arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp244) */ ; } /* end of [cblas_her2k_02104_ats_fcomplex_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/HATS/cblas.hats: 39782(line=1491, offs=38) -- 39995(line=1499, offs=4) */ ATSstaticdec() ats_void_type cblas_her2k_02104_ats_dcomplex_type_2cats_double_type (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_int_type arg4, ats_dcomplex_type arg5, ats_ref_type arg6, ats_int_type arg7, ats_ref_type arg8, ats_int_type arg9, ats_double_type arg10, ats_ref_type arg11, ats_int_type arg12) { /* local vardec */ // ATSlocal_void (tmp246) ; ATSlocal (ats_dcomplex_type, tmp247) ; __ats_lab_cblas_her2k_02104_ats_dcomplex_type_2cats_double_type: /* ats_dcomplex_type tmp247 ; */ tmp247 = arg5 ; /* tmp246 = */ atsctrb_cblas_zher2k (arg0, arg1, arg2, arg3, arg4, (&tmp247), arg6, arg7, arg8, arg9, arg10, arg11, arg12) ; return /* (tmp246) */ ; } /* end of [cblas_her2k_02104_ats_dcomplex_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 929(line=44, offs=28) -- 953(line=44, offs=52) */ ATSstaticdec() ats_float_type of_double_02161_ats_float_type (ats_double_type arg0) { /* local vardec */ ATSlocal (ats_float_type, tmp248) ; __ats_lab_of_double_02161_ats_float_type: tmp248 = atspre_float_of_double (arg0) ; return (tmp248) ; } /* end of [of_double_02161_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 983(line=45, offs=29) -- 990(line=45, offs=36) */ ATSstaticdec() ats_double_type of_double_02161_ats_double_type (ats_double_type arg0) { /* local vardec */ ATSlocal (ats_double_type, tmp249) ; __ats_lab_of_double_02161_ats_double_type: tmp249 = arg0 ; return (tmp249) ; } /* end of [of_double_02161_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1019(line=46, offs=29) -- 1059(line=46, offs=69) */ ATSstaticdec() ats_fcomplex_type of_double_02161_ats_fcomplex_type (ats_double_type arg0) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp250) ; ATSlocal (ats_float_type, tmp251) ; __ats_lab_of_double_02161_ats_fcomplex_type: tmp251 = atspre_float_of_double (arg0) ; tmp250 = atslib_ccmplx_of_float (tmp251) ; return (tmp250) ; } /* end of [of_double_02161_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1089(line=47, offs=29) -- 1114(line=47, offs=54) */ ATSstaticdec() ats_dcomplex_type of_double_02161_ats_dcomplex_type (ats_double_type arg0) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp252) ; __ats_lab_of_double_02161_ats_dcomplex_type: tmp252 = atslib_zcmplx_of_double (arg0) ; return (tmp252) ; } /* end of [of_double_02161_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1208(line=52, offs=28) -- 1221(line=52, offs=41) */ ATSstaticdec() ats_void_type print_elt_02162_ats_float_type (ats_float_type arg0) { /* local vardec */ // ATSlocal_void (tmp253) ; __ats_lab_print_elt_02162_ats_float_type: /* tmp253 = */ atspre_print_float (arg0) ; return /* (tmp253) */ ; } /* end of [print_elt_02162_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1250(line=53, offs=29) -- 1263(line=53, offs=42) */ ATSstaticdec() ats_void_type print_elt_02162_ats_double_type (ats_double_type arg0) { /* local vardec */ // ATSlocal_void (tmp254) ; __ats_lab_print_elt_02162_ats_double_type: /* tmp254 = */ atspre_print_double (arg0) ; return /* (tmp254) */ ; } /* end of [print_elt_02162_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1292(line=54, offs=29) -- 1305(line=54, offs=42) */ ATSstaticdec() ats_void_type print_elt_02162_ats_fcomplex_type (ats_fcomplex_type arg0) { /* local vardec */ // ATSlocal_void (tmp255) ; __ats_lab_print_elt_02162_ats_fcomplex_type: /* tmp255 = */ ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_ccmplx (arg0) ; return /* (tmp255) */ ; } /* end of [print_elt_02162_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1334(line=55, offs=29) -- 1347(line=55, offs=42) */ ATSstaticdec() ats_void_type print_elt_02162_ats_dcomplex_type (ats_dcomplex_type arg0) { /* local vardec */ // ATSlocal_void (tmp256) ; __ats_lab_print_elt_02162_ats_dcomplex_type: /* tmp256 = */ ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_zcmplx (arg0) ; return /* (tmp256) */ ; } /* end of [print_elt_02162_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1439(line=60, offs=28) -- 1457(line=60, offs=46) */ ATSstaticdec() ats_float_type abs_02163_ats_float_type_2cats_float_type (ats_float_type arg0) { /* local vardec */ ATSlocal (ats_float_type, tmp257) ; __ats_lab_abs_02163_ats_float_type_2cats_float_type: tmp257 = atspre_abs_float (arg0) ; return (tmp257) ; } /* end of [abs_02163_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1488(line=61, offs=30) -- 1507(line=61, offs=49) */ ATSstaticdec() ats_double_type abs_02163_ats_double_type_2cats_double_type (ats_double_type arg0) { /* local vardec */ ATSlocal (ats_double_type, tmp258) ; __ats_lab_abs_02163_ats_double_type_2cats_double_type: tmp258 = atspre_abs_double (arg0) ; return (tmp258) ; } /* end of [abs_02163_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1537(line=62, offs=29) -- 1556(line=62, offs=48) */ ATSstaticdec() ats_float_type abs_02163_ats_float_type_2cats_fcomplex_type (ats_fcomplex_type arg0) { /* local vardec */ ATSlocal (ats_float_type, tmp259) ; __ats_lab_abs_02163_ats_float_type_2cats_fcomplex_type: tmp259 = atslib_cabsf (arg0) ; return (tmp259) ; } /* end of [abs_02163_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1587(line=63, offs=30) -- 1606(line=63, offs=49) */ ATSstaticdec() ats_double_type abs_02163_ats_double_type_2cats_dcomplex_type (ats_dcomplex_type arg0) { /* local vardec */ ATSlocal (ats_double_type, tmp260) ; __ats_lab_abs_02163_ats_double_type_2cats_dcomplex_type: tmp260 = atslib_cabs (arg0) ; return (tmp260) ; } /* end of [abs_02163_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1695(line=68, offs=22) -- 1713(line=68, offs=40) */ ATSstaticdec() ats_float_type add_02164_ats_float_type (ats_float_type arg0, ats_float_type arg1) { /* local vardec */ ATSlocal (ats_float_type, tmp261) ; __ats_lab_add_02164_ats_float_type: tmp261 = atspre_add_float_float (arg0, arg1) ; return (tmp261) ; } /* end of [add_02164_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1736(line=69, offs=23) -- 1754(line=69, offs=41) */ ATSstaticdec() ats_double_type add_02164_ats_double_type (ats_double_type arg0, ats_double_type arg1) { /* local vardec */ ATSlocal (ats_double_type, tmp262) ; __ats_lab_add_02164_ats_double_type: tmp262 = atspre_add_double_double (arg0, arg1) ; return (tmp262) ; } /* end of [add_02164_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1777(line=70, offs=23) -- 1795(line=70, offs=41) */ ATSstaticdec() ats_fcomplex_type add_02164_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp263) ; __ats_lab_add_02164_ats_fcomplex_type: tmp263 = atslib_add_ccmplx_ccmplx (arg0, arg1) ; return (tmp263) ; } /* end of [add_02164_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1818(line=71, offs=23) -- 1836(line=71, offs=41) */ ATSstaticdec() ats_dcomplex_type add_02164_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp264) ; __ats_lab_add_02164_ats_dcomplex_type: tmp264 = atslib_add_zcmplx_zcmplx (arg0, arg1) ; return (tmp264) ; } /* end of [add_02164_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1903(line=74, offs=22) -- 1921(line=74, offs=40) */ ATSstaticdec() ats_float_type sub_02165_ats_float_type (ats_float_type arg0, ats_float_type arg1) { /* local vardec */ ATSlocal (ats_float_type, tmp265) ; __ats_lab_sub_02165_ats_float_type: tmp265 = atspre_sub_float_float (arg0, arg1) ; return (tmp265) ; } /* end of [sub_02165_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1944(line=75, offs=23) -- 1962(line=75, offs=41) */ ATSstaticdec() ats_double_type sub_02165_ats_double_type (ats_double_type arg0, ats_double_type arg1) { /* local vardec */ ATSlocal (ats_double_type, tmp266) ; __ats_lab_sub_02165_ats_double_type: tmp266 = atspre_sub_double_double (arg0, arg1) ; return (tmp266) ; } /* end of [sub_02165_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 1985(line=76, offs=23) -- 2003(line=76, offs=41) */ ATSstaticdec() ats_fcomplex_type sub_02165_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp267) ; __ats_lab_sub_02165_ats_fcomplex_type: tmp267 = atslib_sub_ccmplx_ccmplx (arg0, arg1) ; return (tmp267) ; } /* end of [sub_02165_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2026(line=77, offs=23) -- 2044(line=77, offs=41) */ ATSstaticdec() ats_dcomplex_type sub_02165_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp268) ; __ats_lab_sub_02165_ats_dcomplex_type: tmp268 = atslib_sub_zcmplx_zcmplx (arg0, arg1) ; return (tmp268) ; } /* end of [sub_02165_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2111(line=80, offs=22) -- 2129(line=80, offs=40) */ ATSstaticdec() ats_float_type mul_02166_ats_float_type (ats_float_type arg0, ats_float_type arg1) { /* local vardec */ ATSlocal (ats_float_type, tmp269) ; __ats_lab_mul_02166_ats_float_type: tmp269 = atspre_mul_float_float (arg0, arg1) ; return (tmp269) ; } /* end of [mul_02166_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2152(line=81, offs=23) -- 2170(line=81, offs=41) */ ATSstaticdec() ats_double_type mul_02166_ats_double_type (ats_double_type arg0, ats_double_type arg1) { /* local vardec */ ATSlocal (ats_double_type, tmp270) ; __ats_lab_mul_02166_ats_double_type: tmp270 = atspre_mul_double_double (arg0, arg1) ; return (tmp270) ; } /* end of [mul_02166_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2193(line=82, offs=23) -- 2211(line=82, offs=41) */ ATSstaticdec() ats_fcomplex_type mul_02166_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp271) ; __ats_lab_mul_02166_ats_fcomplex_type: tmp271 = atslib_mul_ccmplx_ccmplx (arg0, arg1) ; return (tmp271) ; } /* end of [mul_02166_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2234(line=83, offs=23) -- 2252(line=83, offs=41) */ ATSstaticdec() ats_dcomplex_type mul_02166_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp272) ; __ats_lab_mul_02166_ats_dcomplex_type: tmp272 = atslib_mul_zcmplx_zcmplx (arg0, arg1) ; return (tmp272) ; } /* end of [mul_02166_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2319(line=86, offs=22) -- 2337(line=86, offs=40) */ ATSstaticdec() ats_float_type div_02167_ats_float_type (ats_float_type arg0, ats_float_type arg1) { /* local vardec */ ATSlocal (ats_float_type, tmp273) ; __ats_lab_div_02167_ats_float_type: tmp273 = atspre_div_float_float (arg0, arg1) ; return (tmp273) ; } /* end of [div_02167_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2360(line=87, offs=23) -- 2378(line=87, offs=41) */ ATSstaticdec() ats_double_type div_02167_ats_double_type (ats_double_type arg0, ats_double_type arg1) { /* local vardec */ ATSlocal (ats_double_type, tmp274) ; __ats_lab_div_02167_ats_double_type: tmp274 = atspre_div_double_double (arg0, arg1) ; return (tmp274) ; } /* end of [div_02167_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2401(line=88, offs=23) -- 2419(line=88, offs=41) */ ATSstaticdec() ats_fcomplex_type div_02167_ats_fcomplex_type (ats_fcomplex_type arg0, ats_fcomplex_type arg1) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp275) ; __ats_lab_div_02167_ats_fcomplex_type: tmp275 = atslib_div_ccmplx_ccmplx (arg0, arg1) ; return (tmp275) ; } /* end of [div_02167_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2442(line=89, offs=23) -- 2460(line=89, offs=41) */ ATSstaticdec() ats_dcomplex_type div_02167_ats_dcomplex_type (ats_dcomplex_type arg0, ats_dcomplex_type arg1) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp276) ; __ats_lab_div_02167_ats_dcomplex_type: tmp276 = atslib_div_zcmplx_zcmplx (arg0, arg1) ; return (tmp276) ; } /* end of [div_02167_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7577(line=270, offs=18) -- 7790(line=276, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_203 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp284) ; ATSlocal (ats_int_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_float_type, tmp287) ; ATSlocal (ats_double_type, tmp288) ; ATSlocal (ats_int_type, tmp289) ; ATSlocal (ats_int_type, tmp290) ; __ats_lab___ats_fun_203: tmp285 = atspre_int_of_size (arg0) ; tmp286 = atspre_int_of_size (arg1) ; tmp290 = atspre_min_int_int (tmp285, tmp286) ; tmp289 = atspre_add_int_int (tmp290, 2) ; tmp288 = atspre_double_of_int (tmp289) ; tmp287 = of_double_02161_ats_float_type (tmp288) ; ats_ptrget_mac(ats_float_type, arg2) = tmp287 ; return /* (tmp284) */ ; } /* end of [__ats_fun_203] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_203_closure_type ; ats_void_type __ats_fun_203_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_203 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_203_closure_init (__ats_fun_203_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_203_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6291(line=234, offs=6) -- 6538(line=243, offs=6) */ ATSstaticdec() ats_void_type app_205 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp294) ; __ats_lab_app_205: /* tmp294 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp294) */ ; } /* end of [app_205] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6079(line=224, offs=3) -- 6719(line=248, offs=2) */ ATSstaticdec() ats_ptr_type matrix_make_vclo_01660_ats_float_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp293) ; __ats_lab_matrix_make_vclo_01660_ats_float_type: tmp293 = atspre_matrix_make_funenv_tsz (arg0, arg1, &app_205, sizeof(ats_float_type), arg2) ; return (tmp293) ; } /* end of [matrix_make_vclo_01660_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6878(line=240, offs=12) -- 7083(line=247, offs=6) */ ATSstaticdec() ats_void_type __ats_fun_207 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp301) ; // ATSlocal_void (tmp302) ; ATSlocal (ats_bool_type, tmp303) ; // ATSlocal_void (tmp304) ; ATSlocal (ats_bool_type, tmp305) ; ATSlocal (ats_bool_type, tmp306) ; __ats_lab___ats_fun_207: tmp303 = atspre_gt_size_int (arg1, 0) ; if (tmp303) { /* tmp302 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp306 = atspre_gt_size_int (arg0, 0) ; if (tmp306) { tmp305 = atspre_eq_size_int (arg1, 0) ; } else { tmp305 = ats_false_bool ; } /* end of [if] */ if (tmp305) { /* tmp304 = */ atspre_print_string (ATSstrcst("\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp301 = */ print_elt_02162_ats_float_type (ats_ptrget_mac(ats_float_type, arg2)) ; return /* (tmp301) */ ; } /* end of [__ats_fun_207] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_207_closure_type ; ats_void_type __ats_fun_207_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_207 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_207_closure_init (__ats_fun_207_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_207_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_207_closure_make () { __ats_fun_207_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_207_closure_type)) ; __ats_fun_207_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 13041(line=505, offs=6) -- 13158(line=509, offs=31) */ ATSstaticdec() ats_void_type app_209 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp309) ; __ats_lab_app_209: /* tmp309 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp309) */ ; } /* end of [app_209] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11049(line=425, offs=6) */ ATSstaticdec() ats_void_type loop1_211 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp335) ; /* tmp335 = */ loop1_211_0loop2_212 (0, arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp335) */ ; } /* end of [loop1_211] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11077(line=427, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop2_212 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp336) ; /* tmp336 = */ loop1_211_0loop2_212 (1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp336) */ ; } /* end of [loop2_212] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop1_211_0loop2_212 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_size_type, tmp313) ; ATSlocal (ats_size_type, tmp314) ; ATSlocal (ats_size_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_size_type, tmp319) ; ATSlocal (ats_size_type, tmp320) ; ATSlocal (ats_size_type, tmp321) ; ATSlocal (ats_size_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; ATSlocal (ats_bool_type, tmp325) ; // ATSlocal_void (tmp326) ; ATSlocal (ats_bool_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_size_type, tmp332) ; ATSlocal (ats_size_type, tmp333) ; // ATSlocal_void (tmp334) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp311 = va_arg(funarg, ats_ptr_type) ; tmp312 = va_arg(funarg, ats_ptr_type) ; tmp313 = va_arg(funarg, ats_size_type) ; tmp314 = va_arg(funarg, ats_size_type) ; tmp315 = va_arg(funarg, ats_size_type) ; tmp316 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop1_211 ; case 1: va_start(funarg, arg0) ; tmp317 = va_arg(funarg, ats_ptr_type) ; tmp318 = va_arg(funarg, ats_ptr_type) ; tmp319 = va_arg(funarg, ats_size_type) ; tmp320 = va_arg(funarg, ats_size_type) ; tmp321 = va_arg(funarg, ats_size_type) ; tmp322 = va_arg(funarg, ats_size_type) ; tmp323 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop2_212 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_loop1_211: tmp325 = atspre_lt_size1_size1 (tmp315, tmp313) ; if (tmp325) { tmp317 = tmp311 ; tmp318 = tmp312 ; tmp319 = tmp313 ; tmp320 = tmp314 ; tmp321 = tmp315 ; tmp322 = 0 ; tmp323 = tmp316 ; goto __ats_lab_loop2_212 ; // tail call } else { /* empty */ } /* end of [if] */ return /* tmp324 */ ; __ats_lab_loop2_212: tmp327 = atspre_lt_size1_size1 (tmp322, tmp320) ; if (tmp327) { tmp329 = ats_selsin_mac(tmp317, atslab_data) ; tmp328 = atspre_matrix_ptr_takeout_elt_tsz (tmp329, tmp321, tmp320, tmp322, sizeof(ats_float_type)) ; tmp330 = ats_selsin_mac(tmp328, atslab_2) ; /* tmp331 = */ ((ats_void_type(*)(ats_size_type, ats_size_type, ats_ref_type, ats_ptr_type))tmp318) (tmp321, tmp322, tmp330, tmp323) ; tmp332 = atspre_add_size1_int1 (tmp322, 1) ; tmp317 = tmp317 ; tmp318 = tmp318 ; tmp319 = tmp319 ; tmp320 = tmp320 ; tmp321 = tmp321 ; tmp322 = tmp332 ; tmp323 = tmp323 ; goto __ats_lab_loop2_212 ; // tail call } else { tmp333 = atspre_add_size1_int1 (tmp321, 1) ; tmp311 = tmp317 ; tmp312 = tmp318 ; tmp313 = tmp319 ; tmp314 = tmp320 ; tmp315 = tmp333 ; tmp316 = tmp323 ; goto __ats_lab_loop1_211 ; // tail call } /* end of [if] */ return /* tmp326 */ ; return /* (tmp334) */ ; } /* end of [loop1_211_0loop2_212] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10699(line=416, offs=3) -- 11747(line=448, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_funenv_01669_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp310) ; __ats_lab_matrix_iforeach_funenv_01669_ats_float_type: /* tmp310 = */ loop1_211 (arg0, arg1, arg2, arg3, 0, arg4) ; return /* (tmp310) */ ; } /* end of [matrix_iforeach_funenv_01669_ats_float_type] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 12922(line=500, offs=9) -- 13300(line=516, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_cloref_01672_ats_float_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp308) ; __ats_lab_matrix_iforeach_cloref_01672_ats_float_type: /* tmp308 = */ matrix_iforeach_funenv_01669_ats_float_type (arg0, &app_209, arg2, arg3, arg1) ; return /* (tmp308) */ ; } /* end of [matrix_iforeach_cloref_01672_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6804(line=237, offs=24) -- 7199(line=251, offs=4) */ ATSstaticdec() ats_void_type print_matrix_02646_ats_float_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp300) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_size_type, tmp337) ; ATSlocal (ats_size_type, tmp338) ; __ats_lab_print_matrix_02646_ats_float_type: tmp307 = __ats_fun_207_closure_make () ; tmp337 = atspre_size1_of_int1 (arg1) ; tmp338 = atspre_size1_of_int1 (arg2) ; /* tmp300 = */ matrix_iforeach_cloref_01672_ats_float_type (arg0, tmp307, tmp337, tmp338) ; return /* (tmp300) */ ; } /* end of [print_matrix_02646_ats_float_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 16114(line=539, offs=3) -- 16221(line=540, offs=74) */ ATSstaticdec() anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp344) ; __ats_lab_GEMAT_ptr_split2x2_01864_ats_float_type: tmp344 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tsz (arg0, arg1, arg2, arg3, arg4, sizeof(ats_float_type)) ; return (tmp344) ; } /* end of [GEMAT_ptr_split2x2_01864_ats_float_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10372(line=356, offs=3) -- 10834(line=369, offs=4) */ ATSstaticdec() ats_ptr_type GEMAT_ptr_takeout_01857_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_size_type, tmp354) ; ATSlocal (ats_size_type, tmp355) ; ATSlocal (ats_size_type, tmp356) ; ATSlocal (ats_size_type, tmp357) ; ATSlocal (ats_size_type, tmp358) ; __ats_lab_GEMAT_ptr_takeout_01857_ats_float_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp356 = atspre_mul_size_size (arg3, arg2) ; tmp355 = atspre_add_size_size (tmp356, arg4) ; tmp354 = atspre_mul_size_size (tmp355, sizeof(ats_float_type)) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp358 = atspre_mul_size_size (arg4, arg2) ; tmp357 = atspre_add_size_size (arg3, tmp358) ; tmp354 = atspre_mul_size_size (tmp357, sizeof(ats_float_type)) ; break ; } while (0) ; tmp353 = atspre_padd_size (arg1, ats_castfn_mac(ats_size_type, tmp354)) ; return (tmp353) ; } /* end of [GEMAT_ptr_takeout_01857_ats_float_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10921(line=374, offs=22) -- 11095(line=380, offs=4) */ ATSstaticdec() ats_float_type GEMAT_ptr_get_elt_at_01858_ats_float_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp359) ; __ats_lab_GEMAT_ptr_get_elt_at_01858_ats_float_type: tmp352 = GEMAT_ptr_takeout_01857_ats_float_type (arg0, arg1, arg2, arg3, arg4) ; tmp359 = ats_selsin_mac(tmp352, atslab_2) ; tmp351 = ats_ptrget_mac(ats_float_type, tmp359) ; return (tmp351) ; } /* end of [GEMAT_ptr_get_elt_at_01858_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5361(line=184, offs=7) -- 6693(line=230, offs=8) */ ATSstaticdec() ats_void_type loop_215 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp341) ; ATSlocal (ats_bool_type, tmp342) ; ATSlocal (anairiats_rec_2, tmp343) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_size_type, tmp349) ; ATSlocal (ats_float_type, tmp350) ; ATSlocal (ats_int_type, tmp360) ; ATSlocal (ats_size_type, tmp361) ; ATSlocal (ats_bool_type, tmp362) ; ATSlocal (ats_size_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_float_type, tmp366) ; ATSlocal (ats_float_type, tmp367) ; ATSlocal (ats_int_type, tmp368) ; ATSlocal (ats_int_type, tmp369) ; ATSlocal (ats_float_type, tmp370) ; ATSlocal (ats_float_type, tmp371) ; // ATSlocal_void (tmp372) ; __ats_lab_loop_215: tmp342 = atspre_igte (arg0, 2) ; if (tmp342) { tmp343 = GEMAT_ptr_split2x2_01864_ats_float_type (env0, arg1, env1, 1, 1) ; tmp345 = ats_select_mac(tmp343, atslab_5) ; tmp346 = ats_select_mac(tmp343, atslab_6) ; tmp347 = ats_select_mac(tmp343, atslab_7) ; tmp348 = ats_select_mac(tmp343, atslab_8) ; tmp349 = atspre_size1_of_int1 (0) ; tmp350 = GEMAT_ptr_get_elt_at_01858_ats_float_type (env0, tmp345, env1, tmp349, tmp349) ; tmp360 = atspre_isub (arg0, 1) ; /* ats_size_type tmp361 ; */ /* loop initialization */ tmp361 = tmp349 ; ats_loop_beg_mac(__ats_lab_2) tmp362 = atspre_lt_size1_int1 (tmp361, tmp360) ; if (!tmp362) break ; tmp364 = GEMAT_ptr_takeout_01857_ats_float_type (env0, tmp347, env1, tmp361, tmp349) ; tmp365 = ats_selsin_mac(tmp364, atslab_2) ; tmp367 = ats_ptrget_mac(ats_float_type, tmp365) ; tmp366 = div_02167_ats_float_type (tmp367, tmp350) ; ats_ptrget_mac(ats_float_type, tmp365) = tmp366 ; /* post update before continue */ __ats_lab_4: tmp363 = atspre_add_size1_int1 (tmp361, 1) ; tmp361 = tmp363 ; ats_loop_end_mac(__ats_lab_2, __ats_lab_3) tmp368 = atspre_int1_of_size1 (env1) ; tmp369 = ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDER (env0) ; tmp370 = of_double_02161_ats_float_type (-1.0) ; tmp371 = of_double_02161_ats_float_type (1.0) ; /* tmp372 = */ atsctrb_cblas_gemm_ats_float_type (tmp369, CblasNoTrans, CblasNoTrans, tmp360, tmp360, 1, tmp370, tmp347, tmp368, tmp346, tmp368, tmp371, tmp348, tmp368) ; arg0 = tmp360 ; arg1 = tmp348 ; goto __ats_lab_loop_215 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp341) */ ; } /* end of [loop_215] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_size_type closure_env_1 ; } loop_215_closure_type ; ats_void_type loop_215_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { loop_215 (((loop_215_closure_type*)cloptr)->closure_env_0, ((loop_215_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type loop_215_closure_init (loop_215_closure_type *p_clo, ats_ptr_type env0, ats_size_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_215_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop_215_closure_make (ats_ptr_type env0, ats_size_type env1) { loop_215_closure_type *p_clo = ATS_MALLOC(sizeof(loop_215_closure_type)) ; loop_215_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5305(line=183, offs=3) -- 6731(line=232, offs=2) */ ATSstaticdec() ats_void_type lu_02160_ats_float_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp340) ; __ats_lab_lu_02160_ats_float_type: /* tmp340 = */ loop_215 (arg2, arg3, arg0, arg1) ; return /* (tmp340) */ ; } /* end of [lu_02160_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 10009(line=355, offs=18) -- 10243(line=361, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_219 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp381) ; ATSlocal (ats_int_type, tmp382) ; ATSlocal (ats_int_type, tmp383) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_float_type, tmp385) ; ATSlocal (ats_float_type, tmp386) ; __ats_lab___ats_fun_219: tmp382 = atspre_int_of_size (arg0) ; tmp383 = atspre_int_of_size (arg1) ; tmp384 = atspre_eq_int_int (tmp382, tmp383) ; if (tmp384) { tmp385 = of_double_02161_ats_float_type (1.0) ; ats_ptrget_mac(ats_float_type, arg2) = tmp385 ; } else { tmp386 = of_double_02161_ats_float_type (0.0) ; ats_ptrget_mac(ats_float_type, arg2) = tmp386 ; } /* end of [if] */ return /* (tmp381) */ ; } /* end of [__ats_fun_219] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_219_closure_type ; ats_void_type __ats_fun_219_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_219 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_219_closure_init (__ats_fun_219_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_219_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 11436(line=409, offs=8) -- 11617(line=415, offs=8) */ ATSstaticdec() ats_void_type f_220 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp403) ; ATSlocal (ats_int_type, tmp404) ; ATSlocal (ats_int_type, tmp405) ; ATSlocal (ats_float_type, tmp406) ; ATSlocal (ats_double_type, tmp407) ; ATSlocal (ats_int_type, tmp408) ; ATSlocal (ats_int_type, tmp409) ; __ats_lab_f_220: tmp404 = atspre_int_of_size (arg0) ; tmp405 = atspre_int_of_size (arg1) ; tmp409 = atspre_min_int_int (tmp404, tmp405) ; tmp408 = atspre_add_int_int (tmp409, 2) ; tmp407 = atspre_double_of_int (tmp408) ; tmp406 = of_double_02161_ats_float_type (tmp407) ; ats_ptrget_mac(ats_float_type, arg2) = tmp406 ; return /* (tmp403) */ ; } /* end of [f_220] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11825(line=452, offs=9) -- 12178(line=466, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_fun_01670_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp411) ; __ats_lab_matrix_iforeach_fun_01670_ats_float_type: /* tmp411 = */ matrix_iforeach_funenv_01669_ats_float_type (arg0, ats_castfn_mac(ats_ptr_type, arg1), arg2, arg3, atspre_null_ptr) ; return /* (tmp411) */ ; } /* end of [matrix_iforeach_fun_01670_ats_float_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 13485(line=460, offs=3) -- 13586(line=461, offs=71) */ ATSstaticdec() anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp418) ; __ats_lab_GEMAT_ptr_split1x2_01862_ats_float_type: tmp418 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tsz (arg0, arg1, arg2, arg3, sizeof(ats_float_type)) ; return (tmp418) ; } /* end of [GEMAT_ptr_split1x2_01862_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2933(line=111, offs=7) -- 3936(line=135, offs=6) */ ATSstaticdec() ats_void_type loop_223 (ats_ptr_type env0, ats_ptr_type env1, ats_float_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp415) ; ATSlocal (ats_bool_type, tmp416) ; ATSlocal (anairiats_rec_1, tmp417) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (anairiats_rec_1, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_size_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_int_type, tmp426) ; ATSlocal (ats_size_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_int_type, tmp429) ; ATSlocal (ats_int_type, tmp430) ; // ATSlocal_void (tmp431) ; ATSlocal (ats_size_type, tmp432) ; __ats_lab_loop_223: tmp416 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp416) { tmp417 = GEMAT_ptr_split1x2_01862_ats_float_type (env0, arg2, env3, 1) ; tmp419 = ats_select_mac(tmp417, atslab_3) ; tmp420 = ats_select_mac(tmp417, atslab_4) ; tmp421 = GEMAT_ptr_split1x2_01862_ats_float_type (env1, arg3, env4, 1) ; tmp422 = ats_select_mac(tmp421, atslab_3) ; tmp423 = ats_select_mac(tmp421, atslab_4) ; tmp425 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp424 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp425, env0, env3) ; tmp426 = atspre_int1_of_size1 (tmp424) ; tmp428 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp427 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp428, env1, env4) ; tmp429 = atspre_int1_of_size1 (tmp427) ; tmp430 = atspre_int1_of_size1 (arg0) ; /* tmp431 = */ cblas_axpy_01964_ats_float_type (tmp430, env2, tmp419, tmp426, tmp422, tmp429) ; tmp432 = atspre_sub_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp432 ; arg2 = tmp420 ; arg3 = tmp423 ; goto __ats_lab_loop_223 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp415) */ ; } /* end of [loop_223] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_float_type closure_env_2 ; ats_size_type closure_env_3 ; ats_size_type closure_env_4 ; } loop_223_closure_type ; ats_void_type loop_223_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { loop_223 (((loop_223_closure_type*)cloptr)->closure_env_0, ((loop_223_closure_type*)cloptr)->closure_env_1, ((loop_223_closure_type*)cloptr)->closure_env_2, ((loop_223_closure_type*)cloptr)->closure_env_3, ((loop_223_closure_type*)cloptr)->closure_env_4, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type loop_223_closure_init (loop_223_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_float_type env2, ats_size_type env3, ats_size_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_223_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type loop_223_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_float_type env2, ats_size_type env3, ats_size_type env4) { loop_223_closure_type *p_clo = ATS_MALLOC(sizeof(loop_223_closure_type)) ; loop_223_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2875(line=110, offs=5) -- 3978(line=138, offs=4) */ ATSstaticdec() ats_void_type gemaxpy_02168_ats_float_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_float_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) { /* local vardec */ // ATSlocal_void (tmp414) ; __ats_lab_gemaxpy_02168_ats_float_type: /* tmp414 = */ loop_223 (arg0, arg1, arg4, arg6, arg8, arg2, arg3, arg5, arg7) ; return /* (tmp414) */ ; } /* end of [gemaxpy_02168_ats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4283(line=152, offs=7) -- 4904(line=168, offs=6) */ ATSstaticdec() ats_float_type loop_226 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) { /* local vardec */ ATSlocal (ats_float_type, tmp438) ; ATSlocal (ats_bool_type, tmp439) ; ATSlocal (anairiats_rec_1, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_int_type, tmp444) ; ATSlocal (ats_float_type, tmp445) ; ATSlocal (ats_size_type, tmp446) ; ATSlocal (ats_float_type, tmp447) ; __ats_lab_loop_226: tmp439 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp439) { tmp441 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp440 = GEMAT_ptr_split1x2_01862_ats_float_type (tmp441, arg2, env0, 1) ; tmp442 = ats_select_mac(tmp440, atslab_3) ; tmp443 = ats_select_mac(tmp440, atslab_4) ; tmp444 = atspre_int1_of_size1 (arg0) ; tmp445 = cblas_nrm2_01939_ats_float_type_2cats_float_type (tmp444, tmp442, 1) ; tmp446 = atspre_sub_size1_int1 (arg1, 1) ; tmp447 = add_02164_ats_float_type (arg3, tmp445) ; arg0 = arg0 ; arg1 = tmp446 ; arg2 = tmp443 ; arg3 = tmp447 ; goto __ats_lab_loop_226 ; // tail call } else { tmp438 = arg3 ; } /* end of [if] */ return (tmp438) ; } /* end of [loop_226] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_size_type closure_env_0 ; } loop_226_closure_type ; ats_float_type loop_226_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) { return loop_226 (((loop_226_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type loop_226_closure_init (loop_226_closure_type *p_clo, ats_size_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_226_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type loop_226_closure_make (ats_size_type env0) { loop_226_closure_type *p_clo = ATS_MALLOC(sizeof(loop_226_closure_type)) ; loop_226_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4248(line=151, offs=5) -- 5228(line=177, offs=4) */ ATSstaticdec() ats_float_type gemnrm2_02169_ats_float_type_2cats_float_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp437) ; ATSlocal (ats_float_type, tmp448) ; ATSlocal (ats_float_type, tmp449) ; __ats_lab_gemnrm2_02169_ats_float_type_2cats_float_type: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp448 = of_double_02161_ats_float_type (0.0) ; tmp437 = loop_226 (arg4, arg2, arg1, arg3, tmp448) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp449 = of_double_02161_ats_float_type (0.0) ; tmp437 = loop_226 (arg4, arg1, arg2, arg3, tmp449) ; break ; } while (0) ; return (tmp437) ; } /* end of [gemnrm2_02169_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7405(line=263, offs=20) -- 12456(line=443, offs=2) */ ATSstaticdec() ats_void_type test_02654_ats_float_type_2cats_float_type (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp281) ; ATSlocal (ats_size_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (__ats_fun_203_closure_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp295) ; // ATSlocal_void (tmp296) ; ATSlocal (ats_bool_type, tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp339) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_size_type, tmp374) ; // ATSlocal_void (tmp375) ; ATSlocal (ats_bool_type, tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; ATSlocal (ats_size_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (__ats_fun_219_closure_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; // ATSlocal_void (tmp390) ; ATSlocal (ats_float_type, tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_bool_type, tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_float_type, tmp397) ; // ATSlocal_void (tmp398) ; ATSlocal (ats_bool_type, tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; ATSlocal (ats_size_type, tmp402) ; // ATSlocal_void (tmp410) ; ATSlocal (ats_size_type, tmp412) ; // ATSlocal_void (tmp413) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_float_type, tmp435) ; ATSlocal (ats_float_type, tmp436) ; ATSlocal (ats_ptr_type, tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; // ATSlocal_void (tmp456) ; __ats_lab_test_02654_ats_float_type_2cats_float_type: tmp282 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp283 ; */ tmp283 = &(tmp291) ; __ats_fun_203_closure_init (tmp283) ; // closure initialization tmp292 = matrix_make_vclo_01660_ats_float_type (tmp282, tmp282, tmp283) ; tmp295 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp292), atslab_1) ; tmp297 = atspre_ilte (arg0, 10) ; if (tmp297) { /* tmp298 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp299 = */ print_matrix_02646_ats_float_type (tmp292, arg0, arg0) ; /* tmp296 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp373 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp374 = atspre_size1_of_int1 (arg0) ; /* tmp339 = */ lu_02160_ats_float_type (arg0, tmp295, tmp373, tmp374) ; tmp376 = atspre_ilte (arg0, 10) ; if (tmp376) { /* tmp377 = */ atspre_print_string (ATSstrcst("L\\U =\n")) ; /* tmp378 = */ print_matrix_02646_ats_float_type (tmp292, arg0, arg0) ; /* tmp375 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp379 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp380 ; */ tmp380 = &(tmp387) ; __ats_fun_219_closure_init (tmp380) ; // closure initialization tmp388 = matrix_make_vclo_01660_ats_float_type (tmp379, tmp379, tmp380) ; tmp389 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp388), atslab_1) ; tmp391 = of_double_02161_ats_float_type (1.0) ; /* tmp390 = */ cblas_trmm_02088_ats_float_type (CblasRowMajor, CblasRight, CblasUpper, CblasNoTrans, CblasNonUnit, arg0, arg0, tmp391, tmp295, arg0, tmp389, arg0) ; tmp393 = atspre_ilte (arg0, 10) ; if (tmp393) { /* tmp394 = */ atspre_print_string (ATSstrcst("U =\n")) ; /* tmp395 = */ print_matrix_02646_ats_float_type (tmp388, arg0, arg0) ; /* tmp392 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp397 = of_double_02161_ats_float_type (1.0) ; /* tmp396 = */ cblas_trmm_02088_ats_float_type (CblasRowMajor, CblasLeft, CblasLower, CblasNoTrans, CblasUnit, arg0, arg0, tmp397, tmp295, arg0, tmp389, arg0) ; tmp399 = atspre_ilte (arg0, 10) ; if (tmp399) { /* tmp400 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp401 = */ print_matrix_02646_ats_float_type (tmp388, arg0, arg0) ; /* tmp398 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp402 = atspre_size1_of_int1 (arg0) ; /* tmp410 = */ matrix_iforeach_fun_01670_ats_float_type (tmp292, &f_220, tmp402, tmp402) ; tmp412 = atspre_size1_of_int1 (arg0) ; tmp433 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp434 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp435 = of_double_02161_ats_float_type (-1.0) ; /* tmp413 = */ gemaxpy_02168_ats_float_type (tmp433, tmp434, tmp412, tmp412, tmp435, tmp295, tmp412, tmp389, tmp412) ; tmp450 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp436 = gemnrm2_02169_ats_float_type_2cats_float_type (tmp450, tmp412, tmp412, tmp389, tmp412) ; /* tmp451 = */ __matrix_free (tmp292) ; /* tmp452 = */ __matrix_free (tmp388) ; /* tmp453 = */ atspre_print_string (ATSstrcst("size = ")) ; /* tmp454 = */ atspre_print_size (tmp412) ; /* tmp455 = */ atspre_print_string (ATSstrcst(" and error = ")) ; /* tmp456 = */ print_elt_02162_ats_float_type (tmp436) ; /* tmp281 = */ atspre_print_newline () ; return /* (tmp281) */ ; } /* end of [test_02654_ats_float_type_2cats_float_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7577(line=270, offs=18) -- 7790(line=276, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_228 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp465) ; ATSlocal (ats_int_type, tmp466) ; ATSlocal (ats_int_type, tmp467) ; ATSlocal (ats_double_type, tmp468) ; ATSlocal (ats_double_type, tmp469) ; ATSlocal (ats_int_type, tmp470) ; ATSlocal (ats_int_type, tmp471) ; __ats_lab___ats_fun_228: tmp466 = atspre_int_of_size (arg0) ; tmp467 = atspre_int_of_size (arg1) ; tmp471 = atspre_min_int_int (tmp466, tmp467) ; tmp470 = atspre_add_int_int (tmp471, 2) ; tmp469 = atspre_double_of_int (tmp470) ; tmp468 = of_double_02161_ats_double_type (tmp469) ; ats_ptrget_mac(ats_double_type, arg2) = tmp468 ; return /* (tmp465) */ ; } /* end of [__ats_fun_228] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_228_closure_type ; ats_void_type __ats_fun_228_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_228 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_228_closure_init (__ats_fun_228_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_228_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6291(line=234, offs=6) -- 6538(line=243, offs=6) */ ATSstaticdec() ats_void_type app_230 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp475) ; __ats_lab_app_230: /* tmp475 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp475) */ ; } /* end of [app_230] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6079(line=224, offs=3) -- 6719(line=248, offs=2) */ ATSstaticdec() ats_ptr_type matrix_make_vclo_01660_ats_double_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp474) ; __ats_lab_matrix_make_vclo_01660_ats_double_type: tmp474 = atspre_matrix_make_funenv_tsz (arg0, arg1, &app_230, sizeof(ats_double_type), arg2) ; return (tmp474) ; } /* end of [matrix_make_vclo_01660_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6878(line=240, offs=12) -- 7083(line=247, offs=6) */ ATSstaticdec() ats_void_type __ats_fun_232 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp482) ; // ATSlocal_void (tmp483) ; ATSlocal (ats_bool_type, tmp484) ; // ATSlocal_void (tmp485) ; ATSlocal (ats_bool_type, tmp486) ; ATSlocal (ats_bool_type, tmp487) ; __ats_lab___ats_fun_232: tmp484 = atspre_gt_size_int (arg1, 0) ; if (tmp484) { /* tmp483 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp487 = atspre_gt_size_int (arg0, 0) ; if (tmp487) { tmp486 = atspre_eq_size_int (arg1, 0) ; } else { tmp486 = ats_false_bool ; } /* end of [if] */ if (tmp486) { /* tmp485 = */ atspre_print_string (ATSstrcst("\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp482 = */ print_elt_02162_ats_double_type (ats_ptrget_mac(ats_double_type, arg2)) ; return /* (tmp482) */ ; } /* end of [__ats_fun_232] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_232_closure_type ; ats_void_type __ats_fun_232_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_232 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_232_closure_init (__ats_fun_232_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_232_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_232_closure_make () { __ats_fun_232_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_232_closure_type)) ; __ats_fun_232_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 13041(line=505, offs=6) -- 13158(line=509, offs=31) */ ATSstaticdec() ats_void_type app_234 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp490) ; __ats_lab_app_234: /* tmp490 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp490) */ ; } /* end of [app_234] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11049(line=425, offs=6) */ ATSstaticdec() ats_void_type loop1_236 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp516) ; /* tmp516 = */ loop1_236_0loop2_237 (0, arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp516) */ ; } /* end of [loop1_236] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11077(line=427, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop2_237 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp517) ; /* tmp517 = */ loop1_236_0loop2_237 (1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp517) */ ; } /* end of [loop2_237] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop1_236_0loop2_237 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_size_type, tmp494) ; ATSlocal (ats_size_type, tmp495) ; ATSlocal (ats_size_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_size_type, tmp500) ; ATSlocal (ats_size_type, tmp501) ; ATSlocal (ats_size_type, tmp502) ; ATSlocal (ats_size_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; // ATSlocal_void (tmp505) ; ATSlocal (ats_bool_type, tmp506) ; // ATSlocal_void (tmp507) ; ATSlocal (ats_bool_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; // ATSlocal_void (tmp512) ; ATSlocal (ats_size_type, tmp513) ; ATSlocal (ats_size_type, tmp514) ; // ATSlocal_void (tmp515) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp492 = va_arg(funarg, ats_ptr_type) ; tmp493 = va_arg(funarg, ats_ptr_type) ; tmp494 = va_arg(funarg, ats_size_type) ; tmp495 = va_arg(funarg, ats_size_type) ; tmp496 = va_arg(funarg, ats_size_type) ; tmp497 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop1_236 ; case 1: va_start(funarg, arg0) ; tmp498 = va_arg(funarg, ats_ptr_type) ; tmp499 = va_arg(funarg, ats_ptr_type) ; tmp500 = va_arg(funarg, ats_size_type) ; tmp501 = va_arg(funarg, ats_size_type) ; tmp502 = va_arg(funarg, ats_size_type) ; tmp503 = va_arg(funarg, ats_size_type) ; tmp504 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop2_237 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_loop1_236: tmp506 = atspre_lt_size1_size1 (tmp496, tmp494) ; if (tmp506) { tmp498 = tmp492 ; tmp499 = tmp493 ; tmp500 = tmp494 ; tmp501 = tmp495 ; tmp502 = tmp496 ; tmp503 = 0 ; tmp504 = tmp497 ; goto __ats_lab_loop2_237 ; // tail call } else { /* empty */ } /* end of [if] */ return /* tmp505 */ ; __ats_lab_loop2_237: tmp508 = atspre_lt_size1_size1 (tmp503, tmp501) ; if (tmp508) { tmp510 = ats_selsin_mac(tmp498, atslab_data) ; tmp509 = atspre_matrix_ptr_takeout_elt_tsz (tmp510, tmp502, tmp501, tmp503, sizeof(ats_double_type)) ; tmp511 = ats_selsin_mac(tmp509, atslab_2) ; /* tmp512 = */ ((ats_void_type(*)(ats_size_type, ats_size_type, ats_ref_type, ats_ptr_type))tmp499) (tmp502, tmp503, tmp511, tmp504) ; tmp513 = atspre_add_size1_int1 (tmp503, 1) ; tmp498 = tmp498 ; tmp499 = tmp499 ; tmp500 = tmp500 ; tmp501 = tmp501 ; tmp502 = tmp502 ; tmp503 = tmp513 ; tmp504 = tmp504 ; goto __ats_lab_loop2_237 ; // tail call } else { tmp514 = atspre_add_size1_int1 (tmp502, 1) ; tmp492 = tmp498 ; tmp493 = tmp499 ; tmp494 = tmp500 ; tmp495 = tmp501 ; tmp496 = tmp514 ; tmp497 = tmp504 ; goto __ats_lab_loop1_236 ; // tail call } /* end of [if] */ return /* tmp507 */ ; return /* (tmp515) */ ; } /* end of [loop1_236_0loop2_237] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10699(line=416, offs=3) -- 11747(line=448, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_funenv_01669_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp491) ; __ats_lab_matrix_iforeach_funenv_01669_ats_double_type: /* tmp491 = */ loop1_236 (arg0, arg1, arg2, arg3, 0, arg4) ; return /* (tmp491) */ ; } /* end of [matrix_iforeach_funenv_01669_ats_double_type] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 12922(line=500, offs=9) -- 13300(line=516, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_cloref_01672_ats_double_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp489) ; __ats_lab_matrix_iforeach_cloref_01672_ats_double_type: /* tmp489 = */ matrix_iforeach_funenv_01669_ats_double_type (arg0, &app_234, arg2, arg3, arg1) ; return /* (tmp489) */ ; } /* end of [matrix_iforeach_cloref_01672_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6804(line=237, offs=24) -- 7199(line=251, offs=4) */ ATSstaticdec() ats_void_type print_matrix_02646_ats_double_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp481) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_size_type, tmp518) ; ATSlocal (ats_size_type, tmp519) ; __ats_lab_print_matrix_02646_ats_double_type: tmp488 = __ats_fun_232_closure_make () ; tmp518 = atspre_size1_of_int1 (arg1) ; tmp519 = atspre_size1_of_int1 (arg2) ; /* tmp481 = */ matrix_iforeach_cloref_01672_ats_double_type (arg0, tmp488, tmp518, tmp519) ; return /* (tmp481) */ ; } /* end of [print_matrix_02646_ats_double_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 16114(line=539, offs=3) -- 16221(line=540, offs=74) */ ATSstaticdec() anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp525) ; __ats_lab_GEMAT_ptr_split2x2_01864_ats_double_type: tmp525 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tsz (arg0, arg1, arg2, arg3, arg4, sizeof(ats_double_type)) ; return (tmp525) ; } /* end of [GEMAT_ptr_split2x2_01864_ats_double_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10372(line=356, offs=3) -- 10834(line=369, offs=4) */ ATSstaticdec() ats_ptr_type GEMAT_ptr_takeout_01857_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_size_type, tmp535) ; ATSlocal (ats_size_type, tmp536) ; ATSlocal (ats_size_type, tmp537) ; ATSlocal (ats_size_type, tmp538) ; ATSlocal (ats_size_type, tmp539) ; __ats_lab_GEMAT_ptr_takeout_01857_ats_double_type: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp537 = atspre_mul_size_size (arg3, arg2) ; tmp536 = atspre_add_size_size (tmp537, arg4) ; tmp535 = atspre_mul_size_size (tmp536, sizeof(ats_double_type)) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp539 = atspre_mul_size_size (arg4, arg2) ; tmp538 = atspre_add_size_size (arg3, tmp539) ; tmp535 = atspre_mul_size_size (tmp538, sizeof(ats_double_type)) ; break ; } while (0) ; tmp534 = atspre_padd_size (arg1, ats_castfn_mac(ats_size_type, tmp535)) ; return (tmp534) ; } /* end of [GEMAT_ptr_takeout_01857_ats_double_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10921(line=374, offs=22) -- 11095(line=380, offs=4) */ ATSstaticdec() ats_double_type GEMAT_ptr_get_elt_at_01858_ats_double_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp540) ; __ats_lab_GEMAT_ptr_get_elt_at_01858_ats_double_type: tmp533 = GEMAT_ptr_takeout_01857_ats_double_type (arg0, arg1, arg2, arg3, arg4) ; tmp540 = ats_selsin_mac(tmp533, atslab_2) ; tmp532 = ats_ptrget_mac(ats_double_type, tmp540) ; return (tmp532) ; } /* end of [GEMAT_ptr_get_elt_at_01858_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5361(line=184, offs=7) -- 6693(line=230, offs=8) */ ATSstaticdec() ats_void_type loop_240 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp522) ; ATSlocal (ats_bool_type, tmp523) ; ATSlocal (anairiats_rec_2, tmp524) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_size_type, tmp530) ; ATSlocal (ats_double_type, tmp531) ; ATSlocal (ats_int_type, tmp541) ; ATSlocal (ats_size_type, tmp542) ; ATSlocal (ats_bool_type, tmp543) ; ATSlocal (ats_size_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_double_type, tmp547) ; ATSlocal (ats_double_type, tmp548) ; ATSlocal (ats_int_type, tmp549) ; ATSlocal (ats_int_type, tmp550) ; ATSlocal (ats_double_type, tmp551) ; ATSlocal (ats_double_type, tmp552) ; // ATSlocal_void (tmp553) ; __ats_lab_loop_240: tmp523 = atspre_igte (arg0, 2) ; if (tmp523) { tmp524 = GEMAT_ptr_split2x2_01864_ats_double_type (env0, arg1, env1, 1, 1) ; tmp526 = ats_select_mac(tmp524, atslab_5) ; tmp527 = ats_select_mac(tmp524, atslab_6) ; tmp528 = ats_select_mac(tmp524, atslab_7) ; tmp529 = ats_select_mac(tmp524, atslab_8) ; tmp530 = atspre_size1_of_int1 (0) ; tmp531 = GEMAT_ptr_get_elt_at_01858_ats_double_type (env0, tmp526, env1, tmp530, tmp530) ; tmp541 = atspre_isub (arg0, 1) ; /* ats_size_type tmp542 ; */ /* loop initialization */ tmp542 = tmp530 ; ats_loop_beg_mac(__ats_lab_9) tmp543 = atspre_lt_size1_int1 (tmp542, tmp541) ; if (!tmp543) break ; tmp545 = GEMAT_ptr_takeout_01857_ats_double_type (env0, tmp528, env1, tmp542, tmp530) ; tmp546 = ats_selsin_mac(tmp545, atslab_2) ; tmp548 = ats_ptrget_mac(ats_double_type, tmp546) ; tmp547 = div_02167_ats_double_type (tmp548, tmp531) ; ats_ptrget_mac(ats_double_type, tmp546) = tmp547 ; /* post update before continue */ __ats_lab_11: tmp544 = atspre_add_size1_int1 (tmp542, 1) ; tmp542 = tmp544 ; ats_loop_end_mac(__ats_lab_9, __ats_lab_10) tmp549 = atspre_int1_of_size1 (env1) ; tmp550 = ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDER (env0) ; tmp551 = of_double_02161_ats_double_type (-1.0) ; tmp552 = of_double_02161_ats_double_type (1.0) ; /* tmp553 = */ atsctrb_cblas_gemm_ats_double_type (tmp550, CblasNoTrans, CblasNoTrans, tmp541, tmp541, 1, tmp551, tmp528, tmp549, tmp527, tmp549, tmp552, tmp529, tmp549) ; arg0 = tmp541 ; arg1 = tmp529 ; goto __ats_lab_loop_240 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp522) */ ; } /* end of [loop_240] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_size_type closure_env_1 ; } loop_240_closure_type ; ats_void_type loop_240_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { loop_240 (((loop_240_closure_type*)cloptr)->closure_env_0, ((loop_240_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type loop_240_closure_init (loop_240_closure_type *p_clo, ats_ptr_type env0, ats_size_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_240_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop_240_closure_make (ats_ptr_type env0, ats_size_type env1) { loop_240_closure_type *p_clo = ATS_MALLOC(sizeof(loop_240_closure_type)) ; loop_240_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5305(line=183, offs=3) -- 6731(line=232, offs=2) */ ATSstaticdec() ats_void_type lu_02160_ats_double_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp521) ; __ats_lab_lu_02160_ats_double_type: /* tmp521 = */ loop_240 (arg2, arg3, arg0, arg1) ; return /* (tmp521) */ ; } /* end of [lu_02160_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 10009(line=355, offs=18) -- 10243(line=361, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_244 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp562) ; ATSlocal (ats_int_type, tmp563) ; ATSlocal (ats_int_type, tmp564) ; ATSlocal (ats_bool_type, tmp565) ; ATSlocal (ats_double_type, tmp566) ; ATSlocal (ats_double_type, tmp567) ; __ats_lab___ats_fun_244: tmp563 = atspre_int_of_size (arg0) ; tmp564 = atspre_int_of_size (arg1) ; tmp565 = atspre_eq_int_int (tmp563, tmp564) ; if (tmp565) { tmp566 = of_double_02161_ats_double_type (1.0) ; ats_ptrget_mac(ats_double_type, arg2) = tmp566 ; } else { tmp567 = of_double_02161_ats_double_type (0.0) ; ats_ptrget_mac(ats_double_type, arg2) = tmp567 ; } /* end of [if] */ return /* (tmp562) */ ; } /* end of [__ats_fun_244] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_244_closure_type ; ats_void_type __ats_fun_244_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_244 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_244_closure_init (__ats_fun_244_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_244_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 11436(line=409, offs=8) -- 11617(line=415, offs=8) */ ATSstaticdec() ats_void_type f_245 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp584) ; ATSlocal (ats_int_type, tmp585) ; ATSlocal (ats_int_type, tmp586) ; ATSlocal (ats_double_type, tmp587) ; ATSlocal (ats_double_type, tmp588) ; ATSlocal (ats_int_type, tmp589) ; ATSlocal (ats_int_type, tmp590) ; __ats_lab_f_245: tmp585 = atspre_int_of_size (arg0) ; tmp586 = atspre_int_of_size (arg1) ; tmp590 = atspre_min_int_int (tmp585, tmp586) ; tmp589 = atspre_add_int_int (tmp590, 2) ; tmp588 = atspre_double_of_int (tmp589) ; tmp587 = of_double_02161_ats_double_type (tmp588) ; ats_ptrget_mac(ats_double_type, arg2) = tmp587 ; return /* (tmp584) */ ; } /* end of [f_245] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11825(line=452, offs=9) -- 12178(line=466, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_fun_01670_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp592) ; __ats_lab_matrix_iforeach_fun_01670_ats_double_type: /* tmp592 = */ matrix_iforeach_funenv_01669_ats_double_type (arg0, ats_castfn_mac(ats_ptr_type, arg1), arg2, arg3, atspre_null_ptr) ; return /* (tmp592) */ ; } /* end of [matrix_iforeach_fun_01670_ats_double_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 13485(line=460, offs=3) -- 13586(line=461, offs=71) */ ATSstaticdec() anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp599) ; __ats_lab_GEMAT_ptr_split1x2_01862_ats_double_type: tmp599 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tsz (arg0, arg1, arg2, arg3, sizeof(ats_double_type)) ; return (tmp599) ; } /* end of [GEMAT_ptr_split1x2_01862_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2933(line=111, offs=7) -- 3936(line=135, offs=6) */ ATSstaticdec() ats_void_type loop_248 (ats_ptr_type env0, ats_ptr_type env1, ats_double_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp596) ; ATSlocal (ats_bool_type, tmp597) ; ATSlocal (anairiats_rec_1, tmp598) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (anairiats_rec_1, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_size_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_int_type, tmp607) ; ATSlocal (ats_size_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_int_type, tmp610) ; ATSlocal (ats_int_type, tmp611) ; // ATSlocal_void (tmp612) ; ATSlocal (ats_size_type, tmp613) ; __ats_lab_loop_248: tmp597 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp597) { tmp598 = GEMAT_ptr_split1x2_01862_ats_double_type (env0, arg2, env3, 1) ; tmp600 = ats_select_mac(tmp598, atslab_3) ; tmp601 = ats_select_mac(tmp598, atslab_4) ; tmp602 = GEMAT_ptr_split1x2_01862_ats_double_type (env1, arg3, env4, 1) ; tmp603 = ats_select_mac(tmp602, atslab_3) ; tmp604 = ats_select_mac(tmp602, atslab_4) ; tmp606 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp605 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp606, env0, env3) ; tmp607 = atspre_int1_of_size1 (tmp605) ; tmp609 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp608 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp609, env1, env4) ; tmp610 = atspre_int1_of_size1 (tmp608) ; tmp611 = atspre_int1_of_size1 (arg0) ; /* tmp612 = */ cblas_axpy_01964_ats_double_type (tmp611, env2, tmp600, tmp607, tmp603, tmp610) ; tmp613 = atspre_sub_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp613 ; arg2 = tmp601 ; arg3 = tmp604 ; goto __ats_lab_loop_248 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp596) */ ; } /* end of [loop_248] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_double_type closure_env_2 ; ats_size_type closure_env_3 ; ats_size_type closure_env_4 ; } loop_248_closure_type ; ats_void_type loop_248_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { loop_248 (((loop_248_closure_type*)cloptr)->closure_env_0, ((loop_248_closure_type*)cloptr)->closure_env_1, ((loop_248_closure_type*)cloptr)->closure_env_2, ((loop_248_closure_type*)cloptr)->closure_env_3, ((loop_248_closure_type*)cloptr)->closure_env_4, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type loop_248_closure_init (loop_248_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_double_type env2, ats_size_type env3, ats_size_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_248_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type loop_248_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_double_type env2, ats_size_type env3, ats_size_type env4) { loop_248_closure_type *p_clo = ATS_MALLOC(sizeof(loop_248_closure_type)) ; loop_248_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2875(line=110, offs=5) -- 3978(line=138, offs=4) */ ATSstaticdec() ats_void_type gemaxpy_02168_ats_double_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_double_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) { /* local vardec */ // ATSlocal_void (tmp595) ; __ats_lab_gemaxpy_02168_ats_double_type: /* tmp595 = */ loop_248 (arg0, arg1, arg4, arg6, arg8, arg2, arg3, arg5, arg7) ; return /* (tmp595) */ ; } /* end of [gemaxpy_02168_ats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4283(line=152, offs=7) -- 4904(line=168, offs=6) */ ATSstaticdec() ats_double_type loop_251 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) { /* local vardec */ ATSlocal (ats_double_type, tmp619) ; ATSlocal (ats_bool_type, tmp620) ; ATSlocal (anairiats_rec_1, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_int_type, tmp625) ; ATSlocal (ats_double_type, tmp626) ; ATSlocal (ats_size_type, tmp627) ; ATSlocal (ats_double_type, tmp628) ; __ats_lab_loop_251: tmp620 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp620) { tmp622 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp621 = GEMAT_ptr_split1x2_01862_ats_double_type (tmp622, arg2, env0, 1) ; tmp623 = ats_select_mac(tmp621, atslab_3) ; tmp624 = ats_select_mac(tmp621, atslab_4) ; tmp625 = atspre_int1_of_size1 (arg0) ; tmp626 = cblas_nrm2_01939_ats_double_type_2cats_double_type (tmp625, tmp623, 1) ; tmp627 = atspre_sub_size1_int1 (arg1, 1) ; tmp628 = add_02164_ats_double_type (arg3, tmp626) ; arg0 = arg0 ; arg1 = tmp627 ; arg2 = tmp624 ; arg3 = tmp628 ; goto __ats_lab_loop_251 ; // tail call } else { tmp619 = arg3 ; } /* end of [if] */ return (tmp619) ; } /* end of [loop_251] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_size_type closure_env_0 ; } loop_251_closure_type ; ats_double_type loop_251_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) { return loop_251 (((loop_251_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type loop_251_closure_init (loop_251_closure_type *p_clo, ats_size_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_251_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type loop_251_closure_make (ats_size_type env0) { loop_251_closure_type *p_clo = ATS_MALLOC(sizeof(loop_251_closure_type)) ; loop_251_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4248(line=151, offs=5) -- 5228(line=177, offs=4) */ ATSstaticdec() ats_double_type gemnrm2_02169_ats_double_type_2cats_double_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp618) ; ATSlocal (ats_double_type, tmp629) ; ATSlocal (ats_double_type, tmp630) ; __ats_lab_gemnrm2_02169_ats_double_type_2cats_double_type: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp629 = of_double_02161_ats_double_type (0.0) ; tmp618 = loop_251 (arg4, arg2, arg1, arg3, tmp629) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp630 = of_double_02161_ats_double_type (0.0) ; tmp618 = loop_251 (arg4, arg1, arg2, arg3, tmp630) ; break ; } while (0) ; return (tmp618) ; } /* end of [gemnrm2_02169_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7405(line=263, offs=20) -- 12456(line=443, offs=2) */ ATSstaticdec() ats_void_type test_02654_ats_double_type_2cats_double_type (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp462) ; ATSlocal (ats_size_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (__ats_fun_228_closure_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp476) ; // ATSlocal_void (tmp477) ; ATSlocal (ats_bool_type, tmp478) ; // ATSlocal_void (tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp520) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_size_type, tmp555) ; // ATSlocal_void (tmp556) ; ATSlocal (ats_bool_type, tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; ATSlocal (ats_size_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (__ats_fun_244_closure_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; // ATSlocal_void (tmp571) ; ATSlocal (ats_double_type, tmp572) ; // ATSlocal_void (tmp573) ; ATSlocal (ats_bool_type, tmp574) ; // ATSlocal_void (tmp575) ; // ATSlocal_void (tmp576) ; // ATSlocal_void (tmp577) ; ATSlocal (ats_double_type, tmp578) ; // ATSlocal_void (tmp579) ; ATSlocal (ats_bool_type, tmp580) ; // ATSlocal_void (tmp581) ; // ATSlocal_void (tmp582) ; ATSlocal (ats_size_type, tmp583) ; // ATSlocal_void (tmp591) ; ATSlocal (ats_size_type, tmp593) ; // ATSlocal_void (tmp594) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_double_type, tmp616) ; ATSlocal (ats_double_type, tmp617) ; ATSlocal (ats_ptr_type, tmp631) ; // ATSlocal_void (tmp632) ; // ATSlocal_void (tmp633) ; // ATSlocal_void (tmp634) ; // ATSlocal_void (tmp635) ; // ATSlocal_void (tmp636) ; // ATSlocal_void (tmp637) ; __ats_lab_test_02654_ats_double_type_2cats_double_type: tmp463 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp464 ; */ tmp464 = &(tmp472) ; __ats_fun_228_closure_init (tmp464) ; // closure initialization tmp473 = matrix_make_vclo_01660_ats_double_type (tmp463, tmp463, tmp464) ; tmp476 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp473), atslab_1) ; tmp478 = atspre_ilte (arg0, 10) ; if (tmp478) { /* tmp479 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp480 = */ print_matrix_02646_ats_double_type (tmp473, arg0, arg0) ; /* tmp477 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp554 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp555 = atspre_size1_of_int1 (arg0) ; /* tmp520 = */ lu_02160_ats_double_type (arg0, tmp476, tmp554, tmp555) ; tmp557 = atspre_ilte (arg0, 10) ; if (tmp557) { /* tmp558 = */ atspre_print_string (ATSstrcst("L\\U =\n")) ; /* tmp559 = */ print_matrix_02646_ats_double_type (tmp473, arg0, arg0) ; /* tmp556 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp560 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp561 ; */ tmp561 = &(tmp568) ; __ats_fun_244_closure_init (tmp561) ; // closure initialization tmp569 = matrix_make_vclo_01660_ats_double_type (tmp560, tmp560, tmp561) ; tmp570 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp569), atslab_1) ; tmp572 = of_double_02161_ats_double_type (1.0) ; /* tmp571 = */ cblas_trmm_02088_ats_double_type (CblasRowMajor, CblasRight, CblasUpper, CblasNoTrans, CblasNonUnit, arg0, arg0, tmp572, tmp476, arg0, tmp570, arg0) ; tmp574 = atspre_ilte (arg0, 10) ; if (tmp574) { /* tmp575 = */ atspre_print_string (ATSstrcst("U =\n")) ; /* tmp576 = */ print_matrix_02646_ats_double_type (tmp569, arg0, arg0) ; /* tmp573 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp578 = of_double_02161_ats_double_type (1.0) ; /* tmp577 = */ cblas_trmm_02088_ats_double_type (CblasRowMajor, CblasLeft, CblasLower, CblasNoTrans, CblasUnit, arg0, arg0, tmp578, tmp476, arg0, tmp570, arg0) ; tmp580 = atspre_ilte (arg0, 10) ; if (tmp580) { /* tmp581 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp582 = */ print_matrix_02646_ats_double_type (tmp569, arg0, arg0) ; /* tmp579 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp583 = atspre_size1_of_int1 (arg0) ; /* tmp591 = */ matrix_iforeach_fun_01670_ats_double_type (tmp473, &f_245, tmp583, tmp583) ; tmp593 = atspre_size1_of_int1 (arg0) ; tmp614 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp615 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp616 = of_double_02161_ats_double_type (-1.0) ; /* tmp594 = */ gemaxpy_02168_ats_double_type (tmp614, tmp615, tmp593, tmp593, tmp616, tmp476, tmp593, tmp570, tmp593) ; tmp631 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp617 = gemnrm2_02169_ats_double_type_2cats_double_type (tmp631, tmp593, tmp593, tmp570, tmp593) ; /* tmp632 = */ __matrix_free (tmp473) ; /* tmp633 = */ __matrix_free (tmp569) ; /* tmp634 = */ atspre_print_string (ATSstrcst("size = ")) ; /* tmp635 = */ atspre_print_size (tmp593) ; /* tmp636 = */ atspre_print_string (ATSstrcst(" and error = ")) ; /* tmp637 = */ print_elt_02162_ats_double_type (tmp617) ; /* tmp462 = */ atspre_print_newline () ; return /* (tmp462) */ ; } /* end of [test_02654_ats_double_type_2cats_double_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7577(line=270, offs=18) -- 7790(line=276, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_253 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp646) ; ATSlocal (ats_int_type, tmp647) ; ATSlocal (ats_int_type, tmp648) ; ATSlocal (ats_fcomplex_type, tmp649) ; ATSlocal (ats_double_type, tmp650) ; ATSlocal (ats_int_type, tmp651) ; ATSlocal (ats_int_type, tmp652) ; __ats_lab___ats_fun_253: tmp647 = atspre_int_of_size (arg0) ; tmp648 = atspre_int_of_size (arg1) ; tmp652 = atspre_min_int_int (tmp647, tmp648) ; tmp651 = atspre_add_int_int (tmp652, 2) ; tmp650 = atspre_double_of_int (tmp651) ; tmp649 = of_double_02161_ats_fcomplex_type (tmp650) ; ats_ptrget_mac(ats_fcomplex_type, arg2) = tmp649 ; return /* (tmp646) */ ; } /* end of [__ats_fun_253] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_253_closure_type ; ats_void_type __ats_fun_253_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_253 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_253_closure_init (__ats_fun_253_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_253_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6291(line=234, offs=6) -- 6538(line=243, offs=6) */ ATSstaticdec() ats_void_type app_255 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp656) ; __ats_lab_app_255: /* tmp656 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp656) */ ; } /* end of [app_255] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6079(line=224, offs=3) -- 6719(line=248, offs=2) */ ATSstaticdec() ats_ptr_type matrix_make_vclo_01660_ats_fcomplex_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp655) ; __ats_lab_matrix_make_vclo_01660_ats_fcomplex_type: tmp655 = atspre_matrix_make_funenv_tsz (arg0, arg1, &app_255, sizeof(ats_fcomplex_type), arg2) ; return (tmp655) ; } /* end of [matrix_make_vclo_01660_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6878(line=240, offs=12) -- 7083(line=247, offs=6) */ ATSstaticdec() ats_void_type __ats_fun_257 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp663) ; // ATSlocal_void (tmp664) ; ATSlocal (ats_bool_type, tmp665) ; // ATSlocal_void (tmp666) ; ATSlocal (ats_bool_type, tmp667) ; ATSlocal (ats_bool_type, tmp668) ; __ats_lab___ats_fun_257: tmp665 = atspre_gt_size_int (arg1, 0) ; if (tmp665) { /* tmp664 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp668 = atspre_gt_size_int (arg0, 0) ; if (tmp668) { tmp667 = atspre_eq_size_int (arg1, 0) ; } else { tmp667 = ats_false_bool ; } /* end of [if] */ if (tmp667) { /* tmp666 = */ atspre_print_string (ATSstrcst("\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp663 = */ print_elt_02162_ats_fcomplex_type (ats_ptrget_mac(ats_fcomplex_type, arg2)) ; return /* (tmp663) */ ; } /* end of [__ats_fun_257] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_257_closure_type ; ats_void_type __ats_fun_257_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_257 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_257_closure_init (__ats_fun_257_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_257_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_257_closure_make () { __ats_fun_257_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_257_closure_type)) ; __ats_fun_257_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 13041(line=505, offs=6) -- 13158(line=509, offs=31) */ ATSstaticdec() ats_void_type app_259 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp671) ; __ats_lab_app_259: /* tmp671 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp671) */ ; } /* end of [app_259] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11049(line=425, offs=6) */ ATSstaticdec() ats_void_type loop1_261 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp697) ; /* tmp697 = */ loop1_261_0loop2_262 (0, arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp697) */ ; } /* end of [loop1_261] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11077(line=427, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop2_262 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp698) ; /* tmp698 = */ loop1_261_0loop2_262 (1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp698) */ ; } /* end of [loop2_262] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop1_261_0loop2_262 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_size_type, tmp675) ; ATSlocal (ats_size_type, tmp676) ; ATSlocal (ats_size_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_size_type, tmp681) ; ATSlocal (ats_size_type, tmp682) ; ATSlocal (ats_size_type, tmp683) ; ATSlocal (ats_size_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; // ATSlocal_void (tmp686) ; ATSlocal (ats_bool_type, tmp687) ; // ATSlocal_void (tmp688) ; ATSlocal (ats_bool_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; // ATSlocal_void (tmp693) ; ATSlocal (ats_size_type, tmp694) ; ATSlocal (ats_size_type, tmp695) ; // ATSlocal_void (tmp696) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp673 = va_arg(funarg, ats_ptr_type) ; tmp674 = va_arg(funarg, ats_ptr_type) ; tmp675 = va_arg(funarg, ats_size_type) ; tmp676 = va_arg(funarg, ats_size_type) ; tmp677 = va_arg(funarg, ats_size_type) ; tmp678 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop1_261 ; case 1: va_start(funarg, arg0) ; tmp679 = va_arg(funarg, ats_ptr_type) ; tmp680 = va_arg(funarg, ats_ptr_type) ; tmp681 = va_arg(funarg, ats_size_type) ; tmp682 = va_arg(funarg, ats_size_type) ; tmp683 = va_arg(funarg, ats_size_type) ; tmp684 = va_arg(funarg, ats_size_type) ; tmp685 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop2_262 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_loop1_261: tmp687 = atspre_lt_size1_size1 (tmp677, tmp675) ; if (tmp687) { tmp679 = tmp673 ; tmp680 = tmp674 ; tmp681 = tmp675 ; tmp682 = tmp676 ; tmp683 = tmp677 ; tmp684 = 0 ; tmp685 = tmp678 ; goto __ats_lab_loop2_262 ; // tail call } else { /* empty */ } /* end of [if] */ return /* tmp686 */ ; __ats_lab_loop2_262: tmp689 = atspre_lt_size1_size1 (tmp684, tmp682) ; if (tmp689) { tmp691 = ats_selsin_mac(tmp679, atslab_data) ; tmp690 = atspre_matrix_ptr_takeout_elt_tsz (tmp691, tmp683, tmp682, tmp684, sizeof(ats_fcomplex_type)) ; tmp692 = ats_selsin_mac(tmp690, atslab_2) ; /* tmp693 = */ ((ats_void_type(*)(ats_size_type, ats_size_type, ats_ref_type, ats_ptr_type))tmp680) (tmp683, tmp684, tmp692, tmp685) ; tmp694 = atspre_add_size1_int1 (tmp684, 1) ; tmp679 = tmp679 ; tmp680 = tmp680 ; tmp681 = tmp681 ; tmp682 = tmp682 ; tmp683 = tmp683 ; tmp684 = tmp694 ; tmp685 = tmp685 ; goto __ats_lab_loop2_262 ; // tail call } else { tmp695 = atspre_add_size1_int1 (tmp683, 1) ; tmp673 = tmp679 ; tmp674 = tmp680 ; tmp675 = tmp681 ; tmp676 = tmp682 ; tmp677 = tmp695 ; tmp678 = tmp685 ; goto __ats_lab_loop1_261 ; // tail call } /* end of [if] */ return /* tmp688 */ ; return /* (tmp696) */ ; } /* end of [loop1_261_0loop2_262] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10699(line=416, offs=3) -- 11747(line=448, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_funenv_01669_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp672) ; __ats_lab_matrix_iforeach_funenv_01669_ats_fcomplex_type: /* tmp672 = */ loop1_261 (arg0, arg1, arg2, arg3, 0, arg4) ; return /* (tmp672) */ ; } /* end of [matrix_iforeach_funenv_01669_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 12922(line=500, offs=9) -- 13300(line=516, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_cloref_01672_ats_fcomplex_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp670) ; __ats_lab_matrix_iforeach_cloref_01672_ats_fcomplex_type: /* tmp670 = */ matrix_iforeach_funenv_01669_ats_fcomplex_type (arg0, &app_259, arg2, arg3, arg1) ; return /* (tmp670) */ ; } /* end of [matrix_iforeach_cloref_01672_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6804(line=237, offs=24) -- 7199(line=251, offs=4) */ ATSstaticdec() ats_void_type print_matrix_02646_ats_fcomplex_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp662) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_size_type, tmp699) ; ATSlocal (ats_size_type, tmp700) ; __ats_lab_print_matrix_02646_ats_fcomplex_type: tmp669 = __ats_fun_257_closure_make () ; tmp699 = atspre_size1_of_int1 (arg1) ; tmp700 = atspre_size1_of_int1 (arg2) ; /* tmp662 = */ matrix_iforeach_cloref_01672_ats_fcomplex_type (arg0, tmp669, tmp699, tmp700) ; return /* (tmp662) */ ; } /* end of [print_matrix_02646_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 16114(line=539, offs=3) -- 16221(line=540, offs=74) */ ATSstaticdec() anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp706) ; __ats_lab_GEMAT_ptr_split2x2_01864_ats_fcomplex_type: tmp706 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tsz (arg0, arg1, arg2, arg3, arg4, sizeof(ats_fcomplex_type)) ; return (tmp706) ; } /* end of [GEMAT_ptr_split2x2_01864_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10372(line=356, offs=3) -- 10834(line=369, offs=4) */ ATSstaticdec() ats_ptr_type GEMAT_ptr_takeout_01857_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp715) ; ATSlocal (ats_size_type, tmp716) ; ATSlocal (ats_size_type, tmp717) ; ATSlocal (ats_size_type, tmp718) ; ATSlocal (ats_size_type, tmp719) ; ATSlocal (ats_size_type, tmp720) ; __ats_lab_GEMAT_ptr_takeout_01857_ats_fcomplex_type: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp718 = atspre_mul_size_size (arg3, arg2) ; tmp717 = atspre_add_size_size (tmp718, arg4) ; tmp716 = atspre_mul_size_size (tmp717, sizeof(ats_fcomplex_type)) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp720 = atspre_mul_size_size (arg4, arg2) ; tmp719 = atspre_add_size_size (arg3, tmp720) ; tmp716 = atspre_mul_size_size (tmp719, sizeof(ats_fcomplex_type)) ; break ; } while (0) ; tmp715 = atspre_padd_size (arg1, ats_castfn_mac(ats_size_type, tmp716)) ; return (tmp715) ; } /* end of [GEMAT_ptr_takeout_01857_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10921(line=374, offs=22) -- 11095(line=380, offs=4) */ ATSstaticdec() ats_fcomplex_type GEMAT_ptr_get_elt_at_01858_ats_fcomplex_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_fcomplex_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp721) ; __ats_lab_GEMAT_ptr_get_elt_at_01858_ats_fcomplex_type: tmp714 = GEMAT_ptr_takeout_01857_ats_fcomplex_type (arg0, arg1, arg2, arg3, arg4) ; tmp721 = ats_selsin_mac(tmp714, atslab_2) ; tmp713 = ats_ptrget_mac(ats_fcomplex_type, tmp721) ; return (tmp713) ; } /* end of [GEMAT_ptr_get_elt_at_01858_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5361(line=184, offs=7) -- 6693(line=230, offs=8) */ ATSstaticdec() ats_void_type loop_265 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp703) ; ATSlocal (ats_bool_type, tmp704) ; ATSlocal (anairiats_rec_2, tmp705) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; ATSlocal (ats_size_type, tmp711) ; ATSlocal (ats_fcomplex_type, tmp712) ; ATSlocal (ats_int_type, tmp722) ; ATSlocal (ats_size_type, tmp723) ; ATSlocal (ats_bool_type, tmp724) ; ATSlocal (ats_size_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_fcomplex_type, tmp728) ; ATSlocal (ats_fcomplex_type, tmp729) ; ATSlocal (ats_int_type, tmp730) ; ATSlocal (ats_int_type, tmp731) ; ATSlocal (ats_fcomplex_type, tmp732) ; ATSlocal (ats_fcomplex_type, tmp733) ; // ATSlocal_void (tmp734) ; __ats_lab_loop_265: tmp704 = atspre_igte (arg0, 2) ; if (tmp704) { tmp705 = GEMAT_ptr_split2x2_01864_ats_fcomplex_type (env0, arg1, env1, 1, 1) ; tmp707 = ats_select_mac(tmp705, atslab_5) ; tmp708 = ats_select_mac(tmp705, atslab_6) ; tmp709 = ats_select_mac(tmp705, atslab_7) ; tmp710 = ats_select_mac(tmp705, atslab_8) ; tmp711 = atspre_size1_of_int1 (0) ; tmp712 = GEMAT_ptr_get_elt_at_01858_ats_fcomplex_type (env0, tmp707, env1, tmp711, tmp711) ; tmp722 = atspre_isub (arg0, 1) ; /* ats_size_type tmp723 ; */ /* loop initialization */ tmp723 = tmp711 ; ats_loop_beg_mac(__ats_lab_16) tmp724 = atspre_lt_size1_int1 (tmp723, tmp722) ; if (!tmp724) break ; tmp726 = GEMAT_ptr_takeout_01857_ats_fcomplex_type (env0, tmp709, env1, tmp723, tmp711) ; tmp727 = ats_selsin_mac(tmp726, atslab_2) ; tmp729 = ats_ptrget_mac(ats_fcomplex_type, tmp727) ; tmp728 = div_02167_ats_fcomplex_type (tmp729, tmp712) ; ats_ptrget_mac(ats_fcomplex_type, tmp727) = tmp728 ; /* post update before continue */ __ats_lab_18: tmp725 = atspre_add_size1_int1 (tmp723, 1) ; tmp723 = tmp725 ; ats_loop_end_mac(__ats_lab_16, __ats_lab_17) tmp730 = atspre_int1_of_size1 (env1) ; tmp731 = ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDER (env0) ; tmp732 = of_double_02161_ats_fcomplex_type (-1.0) ; tmp733 = of_double_02161_ats_fcomplex_type (1.0) ; /* tmp734 = */ atsctrb_cblas_gemm_ats_fcomplex_type (tmp731, CblasNoTrans, CblasNoTrans, tmp722, tmp722, 1, tmp732, tmp709, tmp730, tmp708, tmp730, tmp733, tmp710, tmp730) ; arg0 = tmp722 ; arg1 = tmp710 ; goto __ats_lab_loop_265 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp703) */ ; } /* end of [loop_265] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_size_type closure_env_1 ; } loop_265_closure_type ; ats_void_type loop_265_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { loop_265 (((loop_265_closure_type*)cloptr)->closure_env_0, ((loop_265_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type loop_265_closure_init (loop_265_closure_type *p_clo, ats_ptr_type env0, ats_size_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_265_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop_265_closure_make (ats_ptr_type env0, ats_size_type env1) { loop_265_closure_type *p_clo = ATS_MALLOC(sizeof(loop_265_closure_type)) ; loop_265_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5305(line=183, offs=3) -- 6731(line=232, offs=2) */ ATSstaticdec() ats_void_type lu_02160_ats_fcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp702) ; __ats_lab_lu_02160_ats_fcomplex_type: /* tmp702 = */ loop_265 (arg2, arg3, arg0, arg1) ; return /* (tmp702) */ ; } /* end of [lu_02160_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 10009(line=355, offs=18) -- 10243(line=361, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_269 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp743) ; ATSlocal (ats_int_type, tmp744) ; ATSlocal (ats_int_type, tmp745) ; ATSlocal (ats_bool_type, tmp746) ; ATSlocal (ats_fcomplex_type, tmp747) ; ATSlocal (ats_fcomplex_type, tmp748) ; __ats_lab___ats_fun_269: tmp744 = atspre_int_of_size (arg0) ; tmp745 = atspre_int_of_size (arg1) ; tmp746 = atspre_eq_int_int (tmp744, tmp745) ; if (tmp746) { tmp747 = of_double_02161_ats_fcomplex_type (1.0) ; ats_ptrget_mac(ats_fcomplex_type, arg2) = tmp747 ; } else { tmp748 = of_double_02161_ats_fcomplex_type (0.0) ; ats_ptrget_mac(ats_fcomplex_type, arg2) = tmp748 ; } /* end of [if] */ return /* (tmp743) */ ; } /* end of [__ats_fun_269] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_269_closure_type ; ats_void_type __ats_fun_269_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_269 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_269_closure_init (__ats_fun_269_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_269_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 11436(line=409, offs=8) -- 11617(line=415, offs=8) */ ATSstaticdec() ats_void_type f_270 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp765) ; ATSlocal (ats_int_type, tmp766) ; ATSlocal (ats_int_type, tmp767) ; ATSlocal (ats_fcomplex_type, tmp768) ; ATSlocal (ats_double_type, tmp769) ; ATSlocal (ats_int_type, tmp770) ; ATSlocal (ats_int_type, tmp771) ; __ats_lab_f_270: tmp766 = atspre_int_of_size (arg0) ; tmp767 = atspre_int_of_size (arg1) ; tmp771 = atspre_min_int_int (tmp766, tmp767) ; tmp770 = atspre_add_int_int (tmp771, 2) ; tmp769 = atspre_double_of_int (tmp770) ; tmp768 = of_double_02161_ats_fcomplex_type (tmp769) ; ats_ptrget_mac(ats_fcomplex_type, arg2) = tmp768 ; return /* (tmp765) */ ; } /* end of [f_270] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11825(line=452, offs=9) -- 12178(line=466, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_fun_01670_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp773) ; __ats_lab_matrix_iforeach_fun_01670_ats_fcomplex_type: /* tmp773 = */ matrix_iforeach_funenv_01669_ats_fcomplex_type (arg0, ats_castfn_mac(ats_ptr_type, arg1), arg2, arg3, atspre_null_ptr) ; return /* (tmp773) */ ; } /* end of [matrix_iforeach_fun_01670_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 13485(line=460, offs=3) -- 13586(line=461, offs=71) */ ATSstaticdec() anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp780) ; __ats_lab_GEMAT_ptr_split1x2_01862_ats_fcomplex_type: tmp780 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tsz (arg0, arg1, arg2, arg3, sizeof(ats_fcomplex_type)) ; return (tmp780) ; } /* end of [GEMAT_ptr_split1x2_01862_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2933(line=111, offs=7) -- 3936(line=135, offs=6) */ ATSstaticdec() ats_void_type loop_273 (ats_ptr_type env0, ats_ptr_type env1, ats_fcomplex_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp777) ; ATSlocal (ats_bool_type, tmp778) ; ATSlocal (anairiats_rec_1, tmp779) ; ATSlocal (ats_ptr_type, tmp781) ; ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (anairiats_rec_1, tmp783) ; ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_size_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_int_type, tmp788) ; ATSlocal (ats_size_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_int_type, tmp791) ; ATSlocal (ats_int_type, tmp792) ; // ATSlocal_void (tmp793) ; ATSlocal (ats_size_type, tmp794) ; __ats_lab_loop_273: tmp778 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp778) { tmp779 = GEMAT_ptr_split1x2_01862_ats_fcomplex_type (env0, arg2, env3, 1) ; tmp781 = ats_select_mac(tmp779, atslab_3) ; tmp782 = ats_select_mac(tmp779, atslab_4) ; tmp783 = GEMAT_ptr_split1x2_01862_ats_fcomplex_type (env1, arg3, env4, 1) ; tmp784 = ats_select_mac(tmp783, atslab_3) ; tmp785 = ats_select_mac(tmp783, atslab_4) ; tmp787 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp786 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp787, env0, env3) ; tmp788 = atspre_int1_of_size1 (tmp786) ; tmp790 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp789 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp790, env1, env4) ; tmp791 = atspre_int1_of_size1 (tmp789) ; tmp792 = atspre_int1_of_size1 (arg0) ; /* tmp793 = */ cblas_axpy_01964_ats_fcomplex_type (tmp792, env2, tmp781, tmp788, tmp784, tmp791) ; tmp794 = atspre_sub_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp794 ; arg2 = tmp782 ; arg3 = tmp785 ; goto __ats_lab_loop_273 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp777) */ ; } /* end of [loop_273] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_fcomplex_type closure_env_2 ; ats_size_type closure_env_3 ; ats_size_type closure_env_4 ; } loop_273_closure_type ; ats_void_type loop_273_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { loop_273 (((loop_273_closure_type*)cloptr)->closure_env_0, ((loop_273_closure_type*)cloptr)->closure_env_1, ((loop_273_closure_type*)cloptr)->closure_env_2, ((loop_273_closure_type*)cloptr)->closure_env_3, ((loop_273_closure_type*)cloptr)->closure_env_4, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type loop_273_closure_init (loop_273_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_fcomplex_type env2, ats_size_type env3, ats_size_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_273_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type loop_273_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_fcomplex_type env2, ats_size_type env3, ats_size_type env4) { loop_273_closure_type *p_clo = ATS_MALLOC(sizeof(loop_273_closure_type)) ; loop_273_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2875(line=110, offs=5) -- 3978(line=138, offs=4) */ ATSstaticdec() ats_void_type gemaxpy_02168_ats_fcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_fcomplex_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) { /* local vardec */ // ATSlocal_void (tmp776) ; __ats_lab_gemaxpy_02168_ats_fcomplex_type: /* tmp776 = */ loop_273 (arg0, arg1, arg4, arg6, arg8, arg2, arg3, arg5, arg7) ; return /* (tmp776) */ ; } /* end of [gemaxpy_02168_ats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4283(line=152, offs=7) -- 4904(line=168, offs=6) */ ATSstaticdec() ats_float_type loop_276 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) { /* local vardec */ ATSlocal (ats_float_type, tmp800) ; ATSlocal (ats_bool_type, tmp801) ; ATSlocal (anairiats_rec_1, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_int_type, tmp806) ; ATSlocal (ats_float_type, tmp807) ; ATSlocal (ats_size_type, tmp808) ; ATSlocal (ats_float_type, tmp809) ; __ats_lab_loop_276: tmp801 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp801) { tmp803 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp802 = GEMAT_ptr_split1x2_01862_ats_fcomplex_type (tmp803, arg2, env0, 1) ; tmp804 = ats_select_mac(tmp802, atslab_3) ; tmp805 = ats_select_mac(tmp802, atslab_4) ; tmp806 = atspre_int1_of_size1 (arg0) ; tmp807 = cblas_nrm2_01939_ats_float_type_2cats_fcomplex_type (tmp806, tmp804, 1) ; tmp808 = atspre_sub_size1_int1 (arg1, 1) ; tmp809 = add_02164_ats_float_type (arg3, tmp807) ; arg0 = arg0 ; arg1 = tmp808 ; arg2 = tmp805 ; arg3 = tmp809 ; goto __ats_lab_loop_276 ; // tail call } else { tmp800 = arg3 ; } /* end of [if] */ return (tmp800) ; } /* end of [loop_276] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_size_type closure_env_0 ; } loop_276_closure_type ; ats_float_type loop_276_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_float_type arg3) { return loop_276 (((loop_276_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type loop_276_closure_init (loop_276_closure_type *p_clo, ats_size_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_276_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type loop_276_closure_make (ats_size_type env0) { loop_276_closure_type *p_clo = ATS_MALLOC(sizeof(loop_276_closure_type)) ; loop_276_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4248(line=151, offs=5) -- 5228(line=177, offs=4) */ ATSstaticdec() ats_float_type gemnrm2_02169_ats_float_type_2cats_fcomplex_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_float_type, tmp799) ; ATSlocal (ats_float_type, tmp810) ; ATSlocal (ats_float_type, tmp811) ; __ats_lab_gemnrm2_02169_ats_float_type_2cats_fcomplex_type: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp810 = of_double_02161_ats_float_type (0.0) ; tmp799 = loop_276 (arg4, arg2, arg1, arg3, tmp810) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp811 = of_double_02161_ats_float_type (0.0) ; tmp799 = loop_276 (arg4, arg1, arg2, arg3, tmp811) ; break ; } while (0) ; return (tmp799) ; } /* end of [gemnrm2_02169_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7405(line=263, offs=20) -- 12456(line=443, offs=2) */ ATSstaticdec() ats_void_type test_02654_ats_float_type_2cats_fcomplex_type (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp643) ; ATSlocal (ats_size_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (__ats_fun_253_closure_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp657) ; // ATSlocal_void (tmp658) ; ATSlocal (ats_bool_type, tmp659) ; // ATSlocal_void (tmp660) ; // ATSlocal_void (tmp661) ; // ATSlocal_void (tmp701) ; ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_size_type, tmp736) ; // ATSlocal_void (tmp737) ; ATSlocal (ats_bool_type, tmp738) ; // ATSlocal_void (tmp739) ; // ATSlocal_void (tmp740) ; ATSlocal (ats_size_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (__ats_fun_269_closure_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; // ATSlocal_void (tmp752) ; ATSlocal (ats_fcomplex_type, tmp753) ; // ATSlocal_void (tmp754) ; ATSlocal (ats_bool_type, tmp755) ; // ATSlocal_void (tmp756) ; // ATSlocal_void (tmp757) ; // ATSlocal_void (tmp758) ; ATSlocal (ats_fcomplex_type, tmp759) ; // ATSlocal_void (tmp760) ; ATSlocal (ats_bool_type, tmp761) ; // ATSlocal_void (tmp762) ; // ATSlocal_void (tmp763) ; ATSlocal (ats_size_type, tmp764) ; // ATSlocal_void (tmp772) ; ATSlocal (ats_size_type, tmp774) ; // ATSlocal_void (tmp775) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_fcomplex_type, tmp797) ; ATSlocal (ats_float_type, tmp798) ; ATSlocal (ats_ptr_type, tmp812) ; // ATSlocal_void (tmp813) ; // ATSlocal_void (tmp814) ; // ATSlocal_void (tmp815) ; // ATSlocal_void (tmp816) ; // ATSlocal_void (tmp817) ; // ATSlocal_void (tmp818) ; __ats_lab_test_02654_ats_float_type_2cats_fcomplex_type: tmp644 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp645 ; */ tmp645 = &(tmp653) ; __ats_fun_253_closure_init (tmp645) ; // closure initialization tmp654 = matrix_make_vclo_01660_ats_fcomplex_type (tmp644, tmp644, tmp645) ; tmp657 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp654), atslab_1) ; tmp659 = atspre_ilte (arg0, 10) ; if (tmp659) { /* tmp660 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp661 = */ print_matrix_02646_ats_fcomplex_type (tmp654, arg0, arg0) ; /* tmp658 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp735 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp736 = atspre_size1_of_int1 (arg0) ; /* tmp701 = */ lu_02160_ats_fcomplex_type (arg0, tmp657, tmp735, tmp736) ; tmp738 = atspre_ilte (arg0, 10) ; if (tmp738) { /* tmp739 = */ atspre_print_string (ATSstrcst("L\\U =\n")) ; /* tmp740 = */ print_matrix_02646_ats_fcomplex_type (tmp654, arg0, arg0) ; /* tmp737 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp741 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp742 ; */ tmp742 = &(tmp749) ; __ats_fun_269_closure_init (tmp742) ; // closure initialization tmp750 = matrix_make_vclo_01660_ats_fcomplex_type (tmp741, tmp741, tmp742) ; tmp751 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp750), atslab_1) ; tmp753 = of_double_02161_ats_fcomplex_type (1.0) ; /* tmp752 = */ cblas_trmm_02088_ats_fcomplex_type (CblasRowMajor, CblasRight, CblasUpper, CblasNoTrans, CblasNonUnit, arg0, arg0, tmp753, tmp657, arg0, tmp751, arg0) ; tmp755 = atspre_ilte (arg0, 10) ; if (tmp755) { /* tmp756 = */ atspre_print_string (ATSstrcst("U =\n")) ; /* tmp757 = */ print_matrix_02646_ats_fcomplex_type (tmp750, arg0, arg0) ; /* tmp754 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp759 = of_double_02161_ats_fcomplex_type (1.0) ; /* tmp758 = */ cblas_trmm_02088_ats_fcomplex_type (CblasRowMajor, CblasLeft, CblasLower, CblasNoTrans, CblasUnit, arg0, arg0, tmp759, tmp657, arg0, tmp751, arg0) ; tmp761 = atspre_ilte (arg0, 10) ; if (tmp761) { /* tmp762 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp763 = */ print_matrix_02646_ats_fcomplex_type (tmp750, arg0, arg0) ; /* tmp760 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp764 = atspre_size1_of_int1 (arg0) ; /* tmp772 = */ matrix_iforeach_fun_01670_ats_fcomplex_type (tmp654, &f_270, tmp764, tmp764) ; tmp774 = atspre_size1_of_int1 (arg0) ; tmp795 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp796 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp797 = of_double_02161_ats_fcomplex_type (-1.0) ; /* tmp775 = */ gemaxpy_02168_ats_fcomplex_type (tmp795, tmp796, tmp774, tmp774, tmp797, tmp657, tmp774, tmp751, tmp774) ; tmp812 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp798 = gemnrm2_02169_ats_float_type_2cats_fcomplex_type (tmp812, tmp774, tmp774, tmp751, tmp774) ; /* tmp813 = */ __matrix_free (tmp654) ; /* tmp814 = */ __matrix_free (tmp750) ; /* tmp815 = */ atspre_print_string (ATSstrcst("size = ")) ; /* tmp816 = */ atspre_print_size (tmp774) ; /* tmp817 = */ atspre_print_string (ATSstrcst(" and error = ")) ; /* tmp818 = */ print_elt_02162_ats_float_type (tmp798) ; /* tmp643 = */ atspre_print_newline () ; return /* (tmp643) */ ; } /* end of [test_02654_ats_float_type_2cats_fcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7577(line=270, offs=18) -- 7790(line=276, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_278 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp827) ; ATSlocal (ats_int_type, tmp828) ; ATSlocal (ats_int_type, tmp829) ; ATSlocal (ats_dcomplex_type, tmp830) ; ATSlocal (ats_double_type, tmp831) ; ATSlocal (ats_int_type, tmp832) ; ATSlocal (ats_int_type, tmp833) ; __ats_lab___ats_fun_278: tmp828 = atspre_int_of_size (arg0) ; tmp829 = atspre_int_of_size (arg1) ; tmp833 = atspre_min_int_int (tmp828, tmp829) ; tmp832 = atspre_add_int_int (tmp833, 2) ; tmp831 = atspre_double_of_int (tmp832) ; tmp830 = of_double_02161_ats_dcomplex_type (tmp831) ; ats_ptrget_mac(ats_dcomplex_type, arg2) = tmp830 ; return /* (tmp827) */ ; } /* end of [__ats_fun_278] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_278_closure_type ; ats_void_type __ats_fun_278_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_278 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_278_closure_init (__ats_fun_278_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_278_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6291(line=234, offs=6) -- 6538(line=243, offs=6) */ ATSstaticdec() ats_void_type app_280 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp837) ; __ats_lab_app_280: /* tmp837 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp837) */ ; } /* end of [app_280] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 6079(line=224, offs=3) -- 6719(line=248, offs=2) */ ATSstaticdec() ats_ptr_type matrix_make_vclo_01660_ats_dcomplex_type (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp836) ; __ats_lab_matrix_make_vclo_01660_ats_dcomplex_type: tmp836 = atspre_matrix_make_funenv_tsz (arg0, arg1, &app_280, sizeof(ats_dcomplex_type), arg2) ; return (tmp836) ; } /* end of [matrix_make_vclo_01660_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6878(line=240, offs=12) -- 7083(line=247, offs=6) */ ATSstaticdec() ats_void_type __ats_fun_282 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp844) ; // ATSlocal_void (tmp845) ; ATSlocal (ats_bool_type, tmp846) ; // ATSlocal_void (tmp847) ; ATSlocal (ats_bool_type, tmp848) ; ATSlocal (ats_bool_type, tmp849) ; __ats_lab___ats_fun_282: tmp846 = atspre_gt_size_int (arg1, 0) ; if (tmp846) { /* tmp845 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp849 = atspre_gt_size_int (arg0, 0) ; if (tmp849) { tmp848 = atspre_eq_size_int (arg1, 0) ; } else { tmp848 = ats_false_bool ; } /* end of [if] */ if (tmp848) { /* tmp847 = */ atspre_print_string (ATSstrcst("\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp844 = */ print_elt_02162_ats_dcomplex_type (ats_ptrget_mac(ats_dcomplex_type, arg2)) ; return /* (tmp844) */ ; } /* end of [__ats_fun_282] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_282_closure_type ; ats_void_type __ats_fun_282_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_282 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_282_closure_init (__ats_fun_282_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_282_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_282_closure_make () { __ats_fun_282_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_282_closure_type)) ; __ats_fun_282_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 13041(line=505, offs=6) -- 13158(line=509, offs=31) */ ATSstaticdec() ats_void_type app_284 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_clo_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp852) ; __ats_lab_app_284: /* tmp852 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_size_type, ats_size_type, ats_ref_type))(ats_closure_fun(arg3))) (arg3, arg0, arg1, arg2) ; return /* (tmp852) */ ; } /* end of [app_284] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11049(line=425, offs=6) */ ATSstaticdec() ats_void_type loop1_286 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp878) ; /* tmp878 = */ loop1_286_0loop2_287 (0, arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp878) */ ; } /* end of [loop1_286] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11077(line=427, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop2_287 (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_size_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp879) ; /* tmp879 = */ loop1_286_0loop2_287 (1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp879) */ ; } /* end of [loop2_287] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10840(line=421, offs=7) -- 11685(line=444, offs=6) */ ATSstaticdec() ats_void_type loop1_286_0loop2_287 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_size_type, tmp856) ; ATSlocal (ats_size_type, tmp857) ; ATSlocal (ats_size_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_size_type, tmp862) ; ATSlocal (ats_size_type, tmp863) ; ATSlocal (ats_size_type, tmp864) ; ATSlocal (ats_size_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; // ATSlocal_void (tmp867) ; ATSlocal (ats_bool_type, tmp868) ; // ATSlocal_void (tmp869) ; ATSlocal (ats_bool_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; // ATSlocal_void (tmp874) ; ATSlocal (ats_size_type, tmp875) ; ATSlocal (ats_size_type, tmp876) ; // ATSlocal_void (tmp877) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp854 = va_arg(funarg, ats_ptr_type) ; tmp855 = va_arg(funarg, ats_ptr_type) ; tmp856 = va_arg(funarg, ats_size_type) ; tmp857 = va_arg(funarg, ats_size_type) ; tmp858 = va_arg(funarg, ats_size_type) ; tmp859 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop1_286 ; case 1: va_start(funarg, arg0) ; tmp860 = va_arg(funarg, ats_ptr_type) ; tmp861 = va_arg(funarg, ats_ptr_type) ; tmp862 = va_arg(funarg, ats_size_type) ; tmp863 = va_arg(funarg, ats_size_type) ; tmp864 = va_arg(funarg, ats_size_type) ; tmp865 = va_arg(funarg, ats_size_type) ; tmp866 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop2_287 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_loop1_286: tmp868 = atspre_lt_size1_size1 (tmp858, tmp856) ; if (tmp868) { tmp860 = tmp854 ; tmp861 = tmp855 ; tmp862 = tmp856 ; tmp863 = tmp857 ; tmp864 = tmp858 ; tmp865 = 0 ; tmp866 = tmp859 ; goto __ats_lab_loop2_287 ; // tail call } else { /* empty */ } /* end of [if] */ return /* tmp867 */ ; __ats_lab_loop2_287: tmp870 = atspre_lt_size1_size1 (tmp865, tmp863) ; if (tmp870) { tmp872 = ats_selsin_mac(tmp860, atslab_data) ; tmp871 = atspre_matrix_ptr_takeout_elt_tsz (tmp872, tmp864, tmp863, tmp865, sizeof(ats_dcomplex_type)) ; tmp873 = ats_selsin_mac(tmp871, atslab_2) ; /* tmp874 = */ ((ats_void_type(*)(ats_size_type, ats_size_type, ats_ref_type, ats_ptr_type))tmp861) (tmp864, tmp865, tmp873, tmp866) ; tmp875 = atspre_add_size1_int1 (tmp865, 1) ; tmp860 = tmp860 ; tmp861 = tmp861 ; tmp862 = tmp862 ; tmp863 = tmp863 ; tmp864 = tmp864 ; tmp865 = tmp875 ; tmp866 = tmp866 ; goto __ats_lab_loop2_287 ; // tail call } else { tmp876 = atspre_add_size1_int1 (tmp864, 1) ; tmp854 = tmp860 ; tmp855 = tmp861 ; tmp856 = tmp862 ; tmp857 = tmp863 ; tmp858 = tmp876 ; tmp859 = tmp866 ; goto __ats_lab_loop1_286 ; // tail call } /* end of [if] */ return /* tmp869 */ ; return /* (tmp877) */ ; } /* end of [loop1_286_0loop2_287] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 10699(line=416, offs=3) -- 11747(line=448, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_funenv_01669_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp853) ; __ats_lab_matrix_iforeach_funenv_01669_ats_dcomplex_type: /* tmp853 = */ loop1_286 (arg0, arg1, arg2, arg3, 0, arg4) ; return /* (tmp853) */ ; } /* end of [matrix_iforeach_funenv_01669_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 12922(line=500, offs=9) -- 13300(line=516, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_cloref_01672_ats_dcomplex_type (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp851) ; __ats_lab_matrix_iforeach_cloref_01672_ats_dcomplex_type: /* tmp851 = */ matrix_iforeach_funenv_01669_ats_dcomplex_type (arg0, &app_284, arg2, arg3, arg1) ; return /* (tmp851) */ ; } /* end of [matrix_iforeach_cloref_01672_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 6804(line=237, offs=24) -- 7199(line=251, offs=4) */ ATSstaticdec() ats_void_type print_matrix_02646_ats_dcomplex_type (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp843) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_size_type, tmp880) ; ATSlocal (ats_size_type, tmp881) ; __ats_lab_print_matrix_02646_ats_dcomplex_type: tmp850 = __ats_fun_282_closure_make () ; tmp880 = atspre_size1_of_int1 (arg1) ; tmp881 = atspre_size1_of_int1 (arg2) ; /* tmp843 = */ matrix_iforeach_cloref_01672_ats_dcomplex_type (arg0, tmp850, tmp880, tmp881) ; return /* (tmp843) */ ; } /* end of [print_matrix_02646_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 16114(line=539, offs=3) -- 16221(line=540, offs=74) */ ATSstaticdec() anairiats_rec_2 GEMAT_ptr_split2x2_01864_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp887) ; __ats_lab_GEMAT_ptr_split2x2_01864_ats_dcomplex_type: tmp887 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tsz (arg0, arg1, arg2, arg3, arg4, sizeof(ats_dcomplex_type)) ; return (tmp887) ; } /* end of [GEMAT_ptr_split2x2_01864_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10372(line=356, offs=3) -- 10834(line=369, offs=4) */ ATSstaticdec() ats_ptr_type GEMAT_ptr_takeout_01857_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_size_type, tmp897) ; ATSlocal (ats_size_type, tmp898) ; ATSlocal (ats_size_type, tmp899) ; ATSlocal (ats_size_type, tmp900) ; ATSlocal (ats_size_type, tmp901) ; __ats_lab_GEMAT_ptr_takeout_01857_ats_dcomplex_type: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp899 = atspre_mul_size_size (arg3, arg2) ; tmp898 = atspre_add_size_size (tmp899, arg4) ; tmp897 = atspre_mul_size_size (tmp898, sizeof(ats_dcomplex_type)) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp901 = atspre_mul_size_size (arg4, arg2) ; tmp900 = atspre_add_size_size (arg3, tmp901) ; tmp897 = atspre_mul_size_size (tmp900, sizeof(ats_dcomplex_type)) ; break ; } while (0) ; tmp896 = atspre_padd_size (arg1, ats_castfn_mac(ats_size_type, tmp897)) ; return (tmp896) ; } /* end of [GEMAT_ptr_takeout_01857_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 10921(line=374, offs=22) -- 11095(line=380, offs=4) */ ATSstaticdec() ats_dcomplex_type GEMAT_ptr_get_elt_at_01858_ats_dcomplex_type (ats_ptr_type arg0, ats_ref_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_dcomplex_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp902) ; __ats_lab_GEMAT_ptr_get_elt_at_01858_ats_dcomplex_type: tmp895 = GEMAT_ptr_takeout_01857_ats_dcomplex_type (arg0, arg1, arg2, arg3, arg4) ; tmp902 = ats_selsin_mac(tmp895, atslab_2) ; tmp894 = ats_ptrget_mac(ats_dcomplex_type, tmp902) ; return (tmp894) ; } /* end of [GEMAT_ptr_get_elt_at_01858_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5361(line=184, offs=7) -- 6693(line=230, offs=8) */ ATSstaticdec() ats_void_type loop_290 (ats_ptr_type env0, ats_size_type env1, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp884) ; ATSlocal (ats_bool_type, tmp885) ; ATSlocal (anairiats_rec_2, tmp886) ; ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_size_type, tmp892) ; ATSlocal (ats_dcomplex_type, tmp893) ; ATSlocal (ats_int_type, tmp903) ; ATSlocal (ats_size_type, tmp904) ; ATSlocal (ats_bool_type, tmp905) ; ATSlocal (ats_size_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_dcomplex_type, tmp909) ; ATSlocal (ats_dcomplex_type, tmp910) ; ATSlocal (ats_int_type, tmp911) ; ATSlocal (ats_int_type, tmp912) ; ATSlocal (ats_dcomplex_type, tmp913) ; ATSlocal (ats_dcomplex_type, tmp914) ; // ATSlocal_void (tmp915) ; __ats_lab_loop_290: tmp885 = atspre_igte (arg0, 2) ; if (tmp885) { tmp886 = GEMAT_ptr_split2x2_01864_ats_dcomplex_type (env0, arg1, env1, 1, 1) ; tmp888 = ats_select_mac(tmp886, atslab_5) ; tmp889 = ats_select_mac(tmp886, atslab_6) ; tmp890 = ats_select_mac(tmp886, atslab_7) ; tmp891 = ats_select_mac(tmp886, atslab_8) ; tmp892 = atspre_size1_of_int1 (0) ; tmp893 = GEMAT_ptr_get_elt_at_01858_ats_dcomplex_type (env0, tmp888, env1, tmp892, tmp892) ; tmp903 = atspre_isub (arg0, 1) ; /* ats_size_type tmp904 ; */ /* loop initialization */ tmp904 = tmp892 ; ats_loop_beg_mac(__ats_lab_23) tmp905 = atspre_lt_size1_int1 (tmp904, tmp903) ; if (!tmp905) break ; tmp907 = GEMAT_ptr_takeout_01857_ats_dcomplex_type (env0, tmp890, env1, tmp904, tmp892) ; tmp908 = ats_selsin_mac(tmp907, atslab_2) ; tmp910 = ats_ptrget_mac(ats_dcomplex_type, tmp908) ; tmp909 = div_02167_ats_dcomplex_type (tmp910, tmp893) ; ats_ptrget_mac(ats_dcomplex_type, tmp908) = tmp909 ; /* post update before continue */ __ats_lab_25: tmp906 = atspre_add_size1_int1 (tmp904, 1) ; tmp904 = tmp906 ; ats_loop_end_mac(__ats_lab_23, __ats_lab_24) tmp911 = atspre_int1_of_size1 (env1) ; tmp912 = ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDER (env0) ; tmp913 = of_double_02161_ats_dcomplex_type (-1.0) ; tmp914 = of_double_02161_ats_dcomplex_type (1.0) ; /* tmp915 = */ atsctrb_cblas_gemm_ats_dcomplex_type (tmp912, CblasNoTrans, CblasNoTrans, tmp903, tmp903, 1, tmp913, tmp890, tmp911, tmp889, tmp911, tmp914, tmp891, tmp911) ; arg0 = tmp903 ; arg1 = tmp891 ; goto __ats_lab_loop_290 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp884) */ ; } /* end of [loop_290] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_size_type closure_env_1 ; } loop_290_closure_type ; ats_void_type loop_290_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { loop_290 (((loop_290_closure_type*)cloptr)->closure_env_0, ((loop_290_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type loop_290_closure_init (loop_290_closure_type *p_clo, ats_ptr_type env0, ats_size_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_290_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop_290_closure_make (ats_ptr_type env0, ats_size_type env1) { loop_290_closure_type *p_clo = ATS_MALLOC(sizeof(loop_290_closure_type)) ; loop_290_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 5305(line=183, offs=3) -- 6731(line=232, offs=2) */ ATSstaticdec() ats_void_type lu_02160_ats_dcomplex_type (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp883) ; __ats_lab_lu_02160_ats_dcomplex_type: /* tmp883 = */ loop_290 (arg2, arg3, arg0, arg1) ; return /* (tmp883) */ ; } /* end of [lu_02160_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 10009(line=355, offs=18) -- 10243(line=361, offs=8) */ ATSstaticdec() ats_void_type __ats_fun_294 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp924) ; ATSlocal (ats_int_type, tmp925) ; ATSlocal (ats_int_type, tmp926) ; ATSlocal (ats_bool_type, tmp927) ; ATSlocal (ats_dcomplex_type, tmp928) ; ATSlocal (ats_dcomplex_type, tmp929) ; __ats_lab___ats_fun_294: tmp925 = atspre_int_of_size (arg0) ; tmp926 = atspre_int_of_size (arg1) ; tmp927 = atspre_eq_int_int (tmp925, tmp926) ; if (tmp927) { tmp928 = of_double_02161_ats_dcomplex_type (1.0) ; ats_ptrget_mac(ats_dcomplex_type, arg2) = tmp928 ; } else { tmp929 = of_double_02161_ats_dcomplex_type (0.0) ; ats_ptrget_mac(ats_dcomplex_type, arg2) = tmp929 ; } /* end of [if] */ return /* (tmp924) */ ; } /* end of [__ats_fun_294] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_294_closure_type ; ats_void_type __ats_fun_294_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { __ats_fun_294 (arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_294_closure_init (__ats_fun_294_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_294_clofun ; return ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 11436(line=409, offs=8) -- 11617(line=415, offs=8) */ ATSstaticdec() ats_void_type f_295 (ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp946) ; ATSlocal (ats_int_type, tmp947) ; ATSlocal (ats_int_type, tmp948) ; ATSlocal (ats_dcomplex_type, tmp949) ; ATSlocal (ats_double_type, tmp950) ; ATSlocal (ats_int_type, tmp951) ; ATSlocal (ats_int_type, tmp952) ; __ats_lab_f_295: tmp947 = atspre_int_of_size (arg0) ; tmp948 = atspre_int_of_size (arg1) ; tmp952 = atspre_min_int_int (tmp947, tmp948) ; tmp951 = atspre_add_int_int (tmp952, 2) ; tmp950 = atspre_double_of_int (tmp951) ; tmp949 = of_double_02161_ats_dcomplex_type (tmp950) ; ats_ptrget_mac(ats_dcomplex_type, arg2) = tmp949 ; return /* (tmp946) */ ; } /* end of [f_295] */ /* // /home/hwxi/research/Anairiats/prelude/DATS/matrix.dats: 11825(line=452, offs=9) -- 12178(line=466, offs=4) */ ATSstaticdec() ats_void_type matrix_iforeach_fun_01670_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp954) ; __ats_lab_matrix_iforeach_fun_01670_ats_dcomplex_type: /* tmp954 = */ matrix_iforeach_funenv_01669_ats_dcomplex_type (arg0, ats_castfn_mac(ats_ptr_type, arg1), arg2, arg3, atspre_null_ptr) ; return /* (tmp954) */ ; } /* end of [matrix_iforeach_fun_01670_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 13485(line=460, offs=3) -- 13586(line=461, offs=71) */ ATSstaticdec() anairiats_rec_1 GEMAT_ptr_split1x2_01862_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp961) ; __ats_lab_GEMAT_ptr_split1x2_01862_ats_dcomplex_type: tmp961 = ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tsz (arg0, arg1, arg2, arg3, sizeof(ats_dcomplex_type)) ; return (tmp961) ; } /* end of [GEMAT_ptr_split1x2_01862_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2933(line=111, offs=7) -- 3936(line=135, offs=6) */ ATSstaticdec() ats_void_type loop_298 (ats_ptr_type env0, ats_ptr_type env1, ats_dcomplex_type env2, ats_size_type env3, ats_size_type env4, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp958) ; ATSlocal (ats_bool_type, tmp959) ; ATSlocal (anairiats_rec_1, tmp960) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; ATSlocal (anairiats_rec_1, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_size_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_int_type, tmp969) ; ATSlocal (ats_size_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_int_type, tmp972) ; ATSlocal (ats_int_type, tmp973) ; // ATSlocal_void (tmp974) ; ATSlocal (ats_size_type, tmp975) ; __ats_lab_loop_298: tmp959 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp959) { tmp960 = GEMAT_ptr_split1x2_01862_ats_dcomplex_type (env0, arg2, env3, 1) ; tmp962 = ats_select_mac(tmp960, atslab_3) ; tmp963 = ats_select_mac(tmp960, atslab_4) ; tmp964 = GEMAT_ptr_split1x2_01862_ats_dcomplex_type (env1, arg3, env4, 1) ; tmp965 = ats_select_mac(tmp964, atslab_3) ; tmp966 = ats_select_mac(tmp964, atslab_4) ; tmp968 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp967 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp968, env0, env3) ; tmp969 = atspre_int1_of_size1 (tmp967) ; tmp971 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp970 = ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_get (tmp971, env1, env4) ; tmp972 = atspre_int1_of_size1 (tmp970) ; tmp973 = atspre_int1_of_size1 (arg0) ; /* tmp974 = */ cblas_axpy_01964_ats_dcomplex_type (tmp973, env2, tmp962, tmp969, tmp965, tmp972) ; tmp975 = atspre_sub_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp975 ; arg2 = tmp963 ; arg3 = tmp966 ; goto __ats_lab_loop_298 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp958) */ ; } /* end of [loop_298] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_dcomplex_type closure_env_2 ; ats_size_type closure_env_3 ; ats_size_type closure_env_4 ; } loop_298_closure_type ; ats_void_type loop_298_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_ref_type arg3) { loop_298 (((loop_298_closure_type*)cloptr)->closure_env_0, ((loop_298_closure_type*)cloptr)->closure_env_1, ((loop_298_closure_type*)cloptr)->closure_env_2, ((loop_298_closure_type*)cloptr)->closure_env_3, ((loop_298_closure_type*)cloptr)->closure_env_4, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type loop_298_closure_init (loop_298_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_dcomplex_type env2, ats_size_type env3, ats_size_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_298_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type loop_298_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_dcomplex_type env2, ats_size_type env3, ats_size_type env4) { loop_298_closure_type *p_clo = ATS_MALLOC(sizeof(loop_298_closure_type)) ; loop_298_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 2875(line=110, offs=5) -- 3978(line=138, offs=4) */ ATSstaticdec() ats_void_type gemaxpy_02168_ats_dcomplex_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_dcomplex_type arg4, ats_ref_type arg5, ats_size_type arg6, ats_ref_type arg7, ats_size_type arg8) { /* local vardec */ // ATSlocal_void (tmp957) ; __ats_lab_gemaxpy_02168_ats_dcomplex_type: /* tmp957 = */ loop_298 (arg0, arg1, arg4, arg6, arg8, arg2, arg3, arg5, arg7) ; return /* (tmp957) */ ; } /* end of [gemaxpy_02168_ats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4283(line=152, offs=7) -- 4904(line=168, offs=6) */ ATSstaticdec() ats_double_type loop_301 (ats_size_type env0, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) { /* local vardec */ ATSlocal (ats_double_type, tmp981) ; ATSlocal (ats_bool_type, tmp982) ; ATSlocal (anairiats_rec_1, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_int_type, tmp987) ; ATSlocal (ats_double_type, tmp988) ; ATSlocal (ats_size_type, tmp989) ; ATSlocal (ats_double_type, tmp990) ; __ats_lab_loop_301: tmp982 = atspre_gt_size1_int1 (arg1, 0) ; if (tmp982) { tmp984 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1) ; tmp983 = GEMAT_ptr_split1x2_01862_ats_dcomplex_type (tmp984, arg2, env0, 1) ; tmp985 = ats_select_mac(tmp983, atslab_3) ; tmp986 = ats_select_mac(tmp983, atslab_4) ; tmp987 = atspre_int1_of_size1 (arg0) ; tmp988 = cblas_nrm2_01939_ats_double_type_2cats_dcomplex_type (tmp987, tmp985, 1) ; tmp989 = atspre_sub_size1_int1 (arg1, 1) ; tmp990 = add_02164_ats_double_type (arg3, tmp988) ; arg0 = arg0 ; arg1 = tmp989 ; arg2 = tmp986 ; arg3 = tmp990 ; goto __ats_lab_loop_301 ; // tail call } else { tmp981 = arg3 ; } /* end of [if] */ return (tmp981) ; } /* end of [loop_301] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_size_type closure_env_0 ; } loop_301_closure_type ; ats_double_type loop_301_clofun (ats_clo_ptr_type cloptr, ats_size_type arg0, ats_size_type arg1, ats_ref_type arg2, ats_double_type arg3) { return loop_301 (((loop_301_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type loop_301_closure_init (loop_301_closure_type *p_clo, ats_size_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_301_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type loop_301_closure_make (ats_size_type env0) { loop_301_closure_type *p_clo = ATS_MALLOC(sizeof(loop_301_closure_type)) ; loop_301_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 4248(line=151, offs=5) -- 5228(line=177, offs=4) */ ATSstaticdec() ats_double_type gemnrm2_02169_ats_double_type_2cats_dcomplex_type (ats_ptr_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ref_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_double_type, tmp980) ; ATSlocal (ats_double_type, tmp991) ; ATSlocal (ats_double_type, tmp992) ; __ats_lab_gemnrm2_02169_ats_double_type_2cats_dcomplex_type: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp991 = of_double_02161_ats_double_type (0.0) ; tmp980 = loop_301 (arg4, arg2, arg1, arg3, tmp991) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp992 = of_double_02161_ats_double_type (0.0) ; tmp980 = loop_301 (arg4, arg1, arg2, arg3, tmp992) ; break ; } while (0) ; return (tmp980) ; } /* end of [gemnrm2_02169_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 7405(line=263, offs=20) -- 12456(line=443, offs=2) */ ATSstaticdec() ats_void_type test_02654_ats_double_type_2cats_dcomplex_type (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp824) ; ATSlocal (ats_size_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (__ats_fun_278_closure_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_ptr_type, tmp838) ; // ATSlocal_void (tmp839) ; ATSlocal (ats_bool_type, tmp840) ; // ATSlocal_void (tmp841) ; // ATSlocal_void (tmp842) ; // ATSlocal_void (tmp882) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (ats_size_type, tmp917) ; // ATSlocal_void (tmp918) ; ATSlocal (ats_bool_type, tmp919) ; // ATSlocal_void (tmp920) ; // ATSlocal_void (tmp921) ; ATSlocal (ats_size_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (__ats_fun_294_closure_type, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; // ATSlocal_void (tmp933) ; ATSlocal (ats_dcomplex_type, tmp934) ; // ATSlocal_void (tmp935) ; ATSlocal (ats_bool_type, tmp936) ; // ATSlocal_void (tmp937) ; // ATSlocal_void (tmp938) ; // ATSlocal_void (tmp939) ; ATSlocal (ats_dcomplex_type, tmp940) ; // ATSlocal_void (tmp941) ; ATSlocal (ats_bool_type, tmp942) ; // ATSlocal_void (tmp943) ; // ATSlocal_void (tmp944) ; ATSlocal (ats_size_type, tmp945) ; // ATSlocal_void (tmp953) ; ATSlocal (ats_size_type, tmp955) ; // ATSlocal_void (tmp956) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_dcomplex_type, tmp978) ; ATSlocal (ats_double_type, tmp979) ; ATSlocal (ats_ptr_type, tmp993) ; // ATSlocal_void (tmp994) ; // ATSlocal_void (tmp995) ; // ATSlocal_void (tmp996) ; // ATSlocal_void (tmp997) ; // ATSlocal_void (tmp998) ; // ATSlocal_void (tmp999) ; __ats_lab_test_02654_ats_double_type_2cats_dcomplex_type: tmp825 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp826 ; */ tmp826 = &(tmp834) ; __ats_fun_278_closure_init (tmp826) ; // closure initialization tmp835 = matrix_make_vclo_01660_ats_dcomplex_type (tmp825, tmp825, tmp826) ; tmp838 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp835), atslab_1) ; tmp840 = atspre_ilte (arg0, 10) ; if (tmp840) { /* tmp841 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp842 = */ print_matrix_02646_ats_dcomplex_type (tmp835, arg0, arg0) ; /* tmp839 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp916 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp917 = atspre_size1_of_int1 (arg0) ; /* tmp882 = */ lu_02160_ats_dcomplex_type (arg0, tmp838, tmp916, tmp917) ; tmp919 = atspre_ilte (arg0, 10) ; if (tmp919) { /* tmp920 = */ atspre_print_string (ATSstrcst("L\\U =\n")) ; /* tmp921 = */ print_matrix_02646_ats_dcomplex_type (tmp835, arg0, arg0) ; /* tmp918 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp922 = atspre_size1_of_int1 (arg0) ; /* ats_ptr_type tmp923 ; */ tmp923 = &(tmp930) ; __ats_fun_294_closure_init (tmp923) ; // closure initialization tmp931 = matrix_make_vclo_01660_ats_dcomplex_type (tmp922, tmp922, tmp923) ; tmp932 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, tmp931), atslab_1) ; tmp934 = of_double_02161_ats_dcomplex_type (1.0) ; /* tmp933 = */ cblas_trmm_02088_ats_dcomplex_type (CblasRowMajor, CblasRight, CblasUpper, CblasNoTrans, CblasNonUnit, arg0, arg0, tmp934, tmp838, arg0, tmp932, arg0) ; tmp936 = atspre_ilte (arg0, 10) ; if (tmp936) { /* tmp937 = */ atspre_print_string (ATSstrcst("U =\n")) ; /* tmp938 = */ print_matrix_02646_ats_dcomplex_type (tmp931, arg0, arg0) ; /* tmp935 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp940 = of_double_02161_ats_dcomplex_type (1.0) ; /* tmp939 = */ cblas_trmm_02088_ats_dcomplex_type (CblasRowMajor, CblasLeft, CblasLower, CblasNoTrans, CblasUnit, arg0, arg0, tmp940, tmp838, arg0, tmp932, arg0) ; tmp942 = atspre_ilte (arg0, 10) ; if (tmp942) { /* tmp943 = */ atspre_print_string (ATSstrcst("A =\n")) ; /* tmp944 = */ print_matrix_02646_ats_dcomplex_type (tmp931, arg0, arg0) ; /* tmp941 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp945 = atspre_size1_of_int1 (arg0) ; /* tmp953 = */ matrix_iforeach_fun_01670_ats_dcomplex_type (tmp835, &f_295, tmp945, tmp945) ; tmp955 = atspre_size1_of_int1 (arg0) ; tmp976 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp977 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp978 = of_double_02161_ats_dcomplex_type (-1.0) ; /* tmp956 = */ gemaxpy_02168_ats_dcomplex_type (tmp976, tmp977, tmp955, tmp955, tmp978, tmp838, tmp955, tmp932, tmp955) ; tmp993 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0) ; tmp979 = gemnrm2_02169_ats_double_type_2cats_dcomplex_type (tmp993, tmp955, tmp955, tmp932, tmp955) ; /* tmp994 = */ __matrix_free (tmp835) ; /* tmp995 = */ __matrix_free (tmp931) ; /* tmp996 = */ atspre_print_string (ATSstrcst("size = ")) ; /* tmp997 = */ atspre_print_size (tmp955) ; /* tmp998 = */ atspre_print_string (ATSstrcst(" and error = ")) ; /* tmp999 = */ print_elt_02162_ats_double_type (tmp979) ; /* tmp824 = */ atspre_print_newline () ; return /* (tmp824) */ ; } /* end of [test_02654_ats_double_type_2cats_dcomplex_type] */ /* // /home/hwxi/research/Anairiats/contrib/cblas/TEST/test_lu.dats: 12633(line=455, offs=16) -- 13419(line=476, offs=4) */ ATSglobaldec() ats_void_type mainats () { /* local vardec */ // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; // ATSlocal_void (tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp461) ; // ATSlocal_void (tmp638) ; // ATSlocal_void (tmp639) ; // ATSlocal_void (tmp640) ; // ATSlocal_void (tmp641) ; // ATSlocal_void (tmp642) ; // ATSlocal_void (tmp819) ; // ATSlocal_void (tmp820) ; // ATSlocal_void (tmp821) ; // ATSlocal_void (tmp822) ; // ATSlocal_void (tmp823) ; // ATSlocal_void (tmp1000) ; __ats_lab_mainats: /* tmp278 = */ atspre_print_string (ATSstrcst("test:")) ; /* tmp279 = */ atspre_print_newline () ; /* tmp280 = */ test_02654_ats_float_type_2cats_float_type (10) ; /* tmp457 = */ atspre_print_string (ATSstrcst("================================================")) ; /* tmp458 = */ atspre_print_newline () ; /* tmp459 = */ atspre_print_string (ATSstrcst("test:")) ; /* tmp460 = */ atspre_print_newline () ; /* tmp461 = */ test_02654_ats_double_type_2cats_double_type (10) ; /* tmp638 = */ atspre_print_string (ATSstrcst("================================================")) ; /* tmp639 = */ atspre_print_newline () ; /* tmp640 = */ atspre_print_string (ATSstrcst("test:")) ; /* tmp641 = */ atspre_print_newline () ; /* tmp642 = */ test_02654_ats_float_type_2cats_fcomplex_type (10) ; /* tmp819 = */ atspre_print_string (ATSstrcst("================================================")) ; /* tmp820 = */ atspre_print_newline () ; /* tmp821 = */ atspre_print_string (ATSstrcst("test:")) ; /* tmp822 = */ atspre_print_newline () ; /* tmp823 = */ test_02654_ats_double_type_2cats_dcomplex_type (10) ; /* tmp1000 = */ atspre_print_string (ATSstrcst("================================================")) ; /* tmp277 = */ atspre_print_newline () ; return /* (tmp277) */ ; } /* end of [mainats] */ /* static load function */ // extern ats_void_type ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staload (void) ; // extern ats_void_type ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e10_2prelude_2DATS_2matrix_2edats__staload (void) ; // extern ats_void_type ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__staload (void) ; // extern ats_void_type ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload () { static int ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload_flag) return ; ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload_flag = 1 ; // ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__staload () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staload () ; // ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__staload () ; ATS_2d0_2e2_2e10_2prelude_2DATS_2matrix_2edats__staload () ; // ATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__staload () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staload () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__staload () ; // ATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__dynload () { // ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e10_2prelude_2SATS_2arith_2esats__mul_istot_prfck () ; ATS_2d0_2e2_2e10_2prelude_2SATS_2arith_2esats__mul_nat_nat_nat_prfck () ; ATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__array_v_of_matrix_v_prfck () ; ATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__matrix_v_of_array_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_nil_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_unnil_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_cons_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_uncons_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__array_v_of_GEVEC_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_array_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_trans_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_nil_row_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_v_unnil_row_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_GEMAT_v_row_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEVEC_v_of_GEMAT_v_col_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRMAT_v_trans_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRMAT_v_of_GEMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HEMAT_v_of_SYMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SYMAT_v_of_HEMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HBMAT_v_of_SBMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SBMAT_v_of_HBMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__HPMAT_v_of_SPMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SPMAT_v_of_HPMAT_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2SATS_2fmatrix_2esats__GEMAT_v_of_fmatrix_v_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__coerce_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__coerce_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____assert_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____assert_prfck () ; ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats____cast_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ int main (int argc, char *argv[]) { ATS_GC_INIT() ; mainats_prelude() ; ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__dynload() ; mainats((ats_int_type)argc, (ats_ptr_type)argv) ; return (0) ; } /* end of main */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [test_lu_dats.c] */ ats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_gemm1.dats0000664000175000017500000001340112223166163022222 0ustar hwxihwxi// // some testing code for the ATS interface to BLAS // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end (* ****** ****** *) staload "libc/SATS/complex.sats" staload "libats/SATS/genarrays.sats" (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) staload "libats/SATS/fmatrix.sats" staload _(*anonymous*) = "libats/DATS/fmatrix.dats" (* ****** ****** *) (* fun cblas_dgemm_instance2 {ma,na:nat} {lda,ldc:nat} ( M: int ma, N: int na , A: &GEMAT (double, ma, na, lda), lda: int lda , C: &GEMAT (double, na, na, ldc), ldc: int ldc ) : void = cblas_dgemm ( TRANDIM_T , TRANDIM_N | CblasColMajor , CblasTrans, CblasNoTrans , N, N, M , 1.0 (* alpha *) , A, lda, A, lda , 0.0 (* beta *) , C, ldc ) // end of [cblas_dgemm] // end of [cblas_gemm_instance2] *) (* ****** ****** *) extern fun{a:t@ype} of_double (x: double):<> a implement of_double (x: double) = float_of_double (x) implement of_double (x: double) = x implement of_double (x) = ccmplx_of_float (float_of_double x) implement of_double (x) = zcmplx_of_double (x) extern fun{a:t@ype} print_elt (x: a): void implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x (* ****** ****** *) extern fun{a:t@ype} mul_fmat_fmat {m,n,k:pos} ( m: int m, n: int n, k: int k , A: &fmatrix (a, m, k), B: &fmatrix (a, k, n), C: &fmatrix (a, m, n) ) : void // end of [mul_fmat_fmat] (* ****** ****** *) implement{a} mul_fmat_fmat (m, n, k, A, B, C) = let stavar v1: view and v2: view prval (pfA, fpfA) = GEMAT_v_of_fmatrix_v {a} (view@ A) prval (pfB, fpfB) = GEMAT_v_of_fmatrix_v {a} (view@ B) prval pfAB = (pfA, pfB) prval (pfC, fpfC) = GEMAT_v_of_fmatrix_v {a} (view@ C) val alpha: a = of_double (1.0) and beta: a = of_double (0.0) // viewdef v = (v1, v2) val () = cblas_gemm__main {v} ( pfAB , TRANDIM_N , vsubr_tup_2_0 () , TRANDIM_N , vsubr_tup_2_1 () | CblasColMajor , CblasNoTrans, CblasNoTrans , m, n, k , alpha , &A, m, &B, k , beta , C, m ) // end of [cblas_gemm__main] // prval (pfA: v1, pfB: v2) = pfAB prval () = view@ A := fpfA (pfA) prval () = view@ B := fpfB (pfB) prval () = view@ C := fpfC (pfC) in // nothing end // end of [mul_fmat_fmat] (* ****** ****** *) fn{a:t@ype} print_fmatrix {m,n:nat} (M: &fmatrix (a, m, n), m: size_t m, n: size_t n) : void = let (* val pr = lam (i: int, j: int, x: a): void = let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // empty end // end of [val] var i: int? and j: int? // uninitialized val () = for* (i:natLte m) => (i := 0; i < m; i := i+1) begin for* (i: natLt m, j: natLte n) => (j := 0; j < n; j := j+1) pr (i, j, M[i,m,j]) // end of [for*] end // end of [val] *) // val () = fmatrix_ptr_iforeach_fun (M, pr, ORDERrow, m, n) where { val pr = lam ( i: size_t, j: size_t, x: &a ) : void = $effmask_all let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // empty end // end of [val] } // end of [val] // in // empty end // end of [print_fmatrix] (* ****** ****** *) typedef elt = double (* ****** ****** *) #define N 10 val (pf_NN | NN) = op imul2 (N, N) prval () = mul_nat_nat_nat (pf_NN) val NN_sz = size1_of_int1 (NN) (* ****** ****** *) val ( pf1_gc, pf1_arr | p1_arr ) = array_ptr_alloc_tsz {elt} (NN_sz, sizeof) // end of [val] prval pf1_mat = fmatrix_v_of_array_v {elt?} (pf_NN, pf1_arr) // prval pf = unit_v () val () = fmatrix_ptr_initialize_vclo (pf | !p1_arr, N, N, !p_clo) where { var !p_clo = @lam ( pf: !unit_v | x: &(elt?) >> elt, i: size_t, j: size_t ) : void = let val ij = (if i <= j then i else j): size_t in x := of_double (double_of_size (ij + 1)) // x := zcmplx_make_cart (double_of i, double_of j) end (* end of [var] *) } prval unit_v () = pf // val () = print "M1=\n" val () = print_fmatrix (!p1_arr, N, N) val () = print_newline () (* ****** ****** *) val ( pf2_gc, pf2_arr | p2_arr ) = array_ptr_alloc_tsz {elt} (NN_sz, sizeof) // end of [val] prval pf2_mat = fmatrix_v_of_array_v {elt?} (pf_NN, pf2_arr) // prval pf = unit_v () val () = fmatrix_ptr_initialize_vclo (pf | !p2_arr, N, N, !p_clo) where { var !p_clo = @lam ( pf: !unit_v | x: &(elt?) >> elt, i: size_t, j: size_t ) : void = begin x := of_double (0.0) end (* end of [var] *) } prval unit_v () = pf // val () = print "M2=\n" val () = print_fmatrix (!p2_arr, N, N) val () = print_newline () (* ****** ****** *) val (pf1'_arr | p1'_arr) = __cast (!p1_arr) where { extern castfn __cast (A: &fmatrix (elt, N, N)): [l:addr] (fmatrix_v (elt, N, N, l) | ptr l) } // end of [val] val () = mul_fmat_fmat (N, N, N, !p1_arr, !p1'_arr, !p2_arr) val () = print "M2=\n" val () = print_fmatrix (!p2_arr, N, N) val () = print_newline () (* ****** ****** *) prval (pf1_NN, pf1_arr) = array_v_of_fmatrix_v {elt} (pf1_mat) prval () = mul_isfun (pf_NN, pf1_NN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) prval (pf2_NN, pf2_arr) = array_v_of_fmatrix_v {elt} (pf2_mat) prval () = mul_isfun (pf_NN, pf2_NN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) (* ****** ****** *) (* // HX: no longer needed dynload "libc/DATS/complex.dats" dynload "libats/DATS/genarrays.dats" dynload "libats/DATS/fmatrix.dats" *) (* ****** ****** *) implement main () = () (* ****** ****** *) (* end of [gemm_test1.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/TEST/Makefile0000664000175000017500000000306312223166163020743 0ustar hwxihwxi# # # Makefile for some BLAS testing code # # ###### ATSUSRQ="$(ATSHOME)" ATSLIBQ="$(ATSHOME)" ifeq ("$(ATSHOME)","") ATSUSRQ="/usr" ATSLIBQ="/usr/lib/ats-anairiats-0.2.5" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt LIBFLAGS=-L/usr/lib/atlas -L/usr/lib64/atlas ATSCTRB=$(ATSLIBQ)/contrib/cblas/atsctrb_cblas.o ###### LBLAS=-lblas LCBLAS=$(LBLAS) ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: test_cblas test_cblas: test_cblas.dats $(ATSCC) $(LIBFLAGS) -O2 -o $@ test_cblas.dats $(ATSCTRB) $(LCBLAS) -lm \ && ./test_cblas cleanall:: ; $(RMF) test_cblas ###### checkall:: test_gemm1 test_gemm1: test_gemm1.dats $(ATSCC) $(LIBFLAGS) -O2 -o $@ test_gemm1.dats $(ATSCTRB) $(LCBLAS) -lm \ && ./test_gemm1 cleanall:: ; $(RMF) test_gemm1 checkall:: test_gemm2 test_gemm2: test_gemm2.dats $(ATSCC) $(LIBFLAGS) -O2 -o $@ test_gemm2.dats $(ATSCTRB) $(LCBLAS) -lm \ && ./test_gemm2 cleanall:: ; $(RMF) test_gemm2 ###### checkall:: test_symm test_symm: test_symm.dats $(ATSCC) $(LIBFLAGS) -O2 -o $@ test_symm.dats $(ATSCTRB) $(LCBLAS) -lm \ && ./test_symm cleanall:: ; $(RMF) test_symm ###### checkall:: test_lu test_lu: test_lu.dats $(ATSCC) $(LIBFLAGS) -O2 -o $@ test_lu.dats $(ATSCTRB) $(LCBLAS) -lm \ && ./test_lu cleanall:: ; $(RMF) test_lu ###### html:: ; $(ATSOPT) --posmark_html -d test_cblas.dats > test_cblas_dats.html cleanall:: ; $(RMF) *_?ats.html ###### RMF=rm -f ###### clean:: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_lu0000664000175000017500000023705312223166163020715 0ustar hwxihwxiELF>è@@PÃ@8 @@@@@@øø88@8@@@ܵܵ ¾¾`¾`@ @¾@¾`@¾`  TT@T@DDPåtd0Œ0Œ@0Œ@||QåtdRåtd¾¾`¾`èè/lib64/ld-linux-x86-64.so.2GNUGNU Dú)‘žE†Y(máéíö너,ˆÁ P ,/2(ŒBEÕì»ã’|ØqX¸ñ9ò‹ëÓﵦŸr‡<õ«eC/?_åÝ5Ño k3“Ýé‘ ‰y¾'{c ÷KŸJWÉX0Â`ñÿ(Â`ñÿXÃ` ñÿ(Â`Ë À@˜8Â`¸èƒ@libblas.so.3gf__gmon_start___Jv_RegisterClassescblas_ctrmmcblas_dgemmcblas_caxpycblas_sgemmcblas_dnrm2cblas_snrm2cblas_dtrmmcblas_daxpycblas_strmmcblas_saxpycblas_scnrm2_finicblas_dznrm2_initcblas_zgemmcblas_ztrmmcblas_zaxpycblas_cgemmlibc.so.6fflushexitperror__lxstatreallocfgetccallocstrlenmemset__fprintf_chkstdoutfputcfputsmemcpyfclose__vsnprintf_chkvprintfmallocstderrfwrite__vfprintf_chk__ctype_toupper_loc__ctype_tolower_loc__xstat__libc_start_mainvfprintffree_edata__bss_start_endGLIBC_2.14GLIBC_2.3.4GLIBC_2.2.5GLIBC_2.3”‘–ti (ui 4ii @à¿`0Â`,8Â`1À`À`À`À` À`(À`0À`8À`@À` HÀ` PÀ` XÀ` `À` hÀ`pÀ`xÀ`€À`ˆÀ`À`˜À` À`¨À`°À`¸À`ÀÀ`ÈÀ`ÐÀ`ØÀ`àÀ`èÀ`ðÀ` øÀ`!Á`"Á`#Á`%Á`& Á`'(Á`(0Á`)8Á`*@Á`+HƒìèKèÒèÝtHƒÄÃÿ5 ± ÿ% ± @ÿ% ± héàÿÿÿÿ%± héÐÿÿÿÿ%ú° héÀÿÿÿÿ%ò° hé°ÿÿÿÿ%ê° hé ÿÿÿÿ%â° héÿÿÿÿ%Ú° hé€ÿÿÿÿ%Ò° hépÿÿÿÿ%ʰ hé`ÿÿÿÿ%° h éPÿÿÿÿ%º° h é@ÿÿÿÿ%²° h é0ÿÿÿÿ%ª° h é ÿÿÿÿ%¢° h éÿÿÿÿ%š° héÿÿÿÿ%’° héðþÿÿÿ%а héàþÿÿÿ%‚° héÐþÿÿÿ%z° héÀþÿÿÿ%r° hé°þÿÿÿ%j° hé þÿÿÿ%b° héþÿÿÿ%Z° hé€þÿÿÿ%R° hépþÿÿÿ%J° hé`þÿÿÿ%B° héPþÿÿÿ%:° hé@þÿÿÿ%2° hé0þÿÿÿ%*° hé þÿÿÿ%"° héþÿÿÿ%° héþÿÿÿ%° héðýÿÿÿ% ° h éàýÿÿÿ%° h!éÐýÿÿÿ%ú¯ h"éÀýÿÿÿ%ò¯ h#é°ýÿÿÿ%ê¯ h$é ýÿÿÿ%⯠h%éýÿÿÿ%Ú¯ h&é€ýÿÿÿ%Ò¯ h'épýÿÿÿ%ʯ h(é`ýÿÿH‰ùPH‹=­° ºH†@¾1Àè´ÿÿÿ¿èŠÿÿÿU1ÀH‰õS‰ûHƒìèþ1Àè‡<1ÀèP4H‰î‰ß1Àè”HƒÄ1À[]Ã1íI‰Ñ^H‰âHƒäðPTIÇÀ ƒ@HÇÁƒ@HÇǰ@èÏýÿÿôHƒìH‹Á­ H…ÀtÿÐHƒÄÃUH‰åSHƒì€=° uK»0¾`H‹ú¯ Hë(¾`HÁûHƒëH9Øs$fDHƒÀH‰Õ¯ ÿÅ(¾`H‹ǯ H9ØrâÆ³¯ HƒÄ[]Ãfff.„Hƒ=« UH‰åt¸H…Àt]¿8¾`ÿà]ÃH‹©® ÄH‹™® ‹9”À¶ÀÃfffff.„H‹a® ÄH‹Q® ‹9”À¶ÀÃfffff.„HƒìH‹OD‹H‹=ö® º„@¾1Àèýýÿÿ¿èÓýÿÿHƒìH‰ùH‹=Ê® º0„@¾1ÀèÑýÿÿ¿è§ýÿÿ€HƒìH‰ùH‹=š® ºP„@¾1Àè¡ýÿÿ¿èwýÿÿ€óÃfffff.„óÃfffff.„1ÀÃffff.„óÃfffff.„1ÀÃffff.„óÃfffff.„HƒìèWüÿÿH…Àt HƒÄÃD¾x„@¿H‰D$è;H‹D$HƒÄÃf.„Hƒìè—ûÿÿH…Àt HƒÄÃD¾ „@¿H‰D$èÔ:H‹D$HƒÄÃf.„é[úÿÿff.„HƒìèüÿÿH…Àt HƒÄÃD¾È„@¿H‰D$è„:H‹D$HƒÄÃf.„é‹ûÿÿff.„éûúÿÿff.„éëùÿÿff.„é«ûÿÿI‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„I‰øH‹H‰ÏH‰ÑH‰òL‰Æÿàfff.„ÀHƒìH‹=ò« º?Š@¾¸ZÀèûúÿÿ…ÀxHƒÄÃf¾ø…@‰ÇHƒÄéð8HƒìH‹=µ« º?Š@¾¸èÁúÿÿ…Àx HƒÄľ †@‰ÇHƒÄé°8H‰\$ÐH‰l$ØL‰d$àL‰l$èL‰t$ðL‰|$øH옅ÿH‰t$8H‰T$@H‰L$HL‰D$PL‰L$X…HT$0H„$ H‹L$8L‹´$ H‰T$(º HT$(H‰D$ ¸L‹|0°ÇD$ H‹D0ÇD$(L‹"º(HT$(ÇD$0L‹*H”$¨H‰T$ L9èvWH‰D$H‰ $1ÛI9Üv5L‰èH‹$I¯ÄHØH,‚€H‰ÞHƒÃH‰êL‰ñL‰ïHƒÅAÿ×I9ÜwäH‹D$IƒÅH‹ $L9èw©H‹\$hH‹l$pL‹d$xL‹¬$€L‹´$ˆL‹¼$HĘÃÿt¿è)ùÿÿf„H„$ HT$0H‹œ$ L‹´$¨H‰D$ H‹D$8H‰T$(H‰$¸L‹|0°ÇD$ H‹D0H‰D$¸ L‹d0°(ÇD$0L‹l0H„$°H‰D$ éñþÿÿ€H‰\$ÐH‰l$ØL‰d$àL‰l$èL‰t$ðL‰|$øH옅ÿH‰t$8H‰T$@H‰L$HL‰D$PL‰L$X…HT$0H„$ H‹L$8L‹´$ H‰T$(º HT$(H‰D$ ¸L‹|0°ÇD$ H‹D0ÇD$(L‹"º(HT$(ÇD$0L‹*H”$¨H‰T$ L9èvWH‰D$H‰ $1ÛI9Üv5L‰èH‹$I¯ÄHØH,€H‰ÞHƒÃH‰êL‰ñL‰ïHƒÅAÿ×I9ÜwäH‹D$IƒÅH‹ $L9èw©H‹\$hH‹l$pL‹d$xL‹¬$€L‹´$ˆL‹¼$HĘÃÿt¿èI÷ÿÿf„H„$ HT$0H‹œ$ L‹´$¨H‰D$ H‹D$8H‰T$(H‰$¸L‹|0°ÇD$ H‹D0H‰D$¸ L‹d0°(ÇD$0L‹l0H„$°H‰D$ éñþÿÿ€H‰\$ÐH‰l$ØL‰d$àL‰l$èL‰t$ðL‰|$øH옅ÿH‰t$8H‰T$@H‰L$HL‰D$PL‰L$X…HT$0H„$ H‹L$8L‹´$ H‰T$(º HT$(H‰D$ ¸L‹|0°ÇD$ H‹D0ÇD$(L‹"º(HT$(ÇD$0L‹*H”$¨H‰T$ L9èvWH‰D$H‰ $1ÛI9Üv5L‰èH‹$I¯ÄHØH,€H‰ÞHƒÃH‰êL‰ñL‰ïHƒÅAÿ×I9ÜwäH‹D$IƒÅH‹ $L9èw©H‹\$hH‹l$pL‹d$xL‹¬$€L‹´$ˆL‹¼$HĘÃÿt¿èiõÿÿf„H„$ HT$0H‹œ$ L‹´$¨H‰D$ H‹D$8H‰T$(H‰$¸L‹|0°ÇD$ H‹D0H‰D$¸ L‹d0°(ÇD$0L‹l0H„$°H‰D$ éñþÿÿ€H‰\$ÐH‰l$ØL‰d$àL‰l$èL‰t$ðL‰|$øH옅ÿH‰t$8H‰T$@H‰L$HL‰D$PL‰L$X…H„$ ÇD$º H‹L$8L‹´$ H‰D$ HD$0H‰D$(¸HD$(HT$(L‹8¸HD$(ÇD$ H‹ÇD$(L‹"º(HT$(ÇD$0L‹*H”$¨H‰T$ L9èvVH‰D$H‰ $1ÛI9Üv4L‰íI¯ìHÝHÁåH,$fDH‰ÞHƒÃH‰êL‰ñL‰ïHƒÅAÿ×I9ÜwäH‹D$IƒÅH‹ $L9èwªH‹\$hH‹l$pL‹d$xL‹¬$€L‹´$ˆL‹¼$HĘÃÿt¿èyóÿÿf„H„$ ÇD$H‹œ$ L‹´$¨H‰D$ HD$0H‰D$(H‹D$8H‰$¸HD$(L‹8¸HD$(ÇD$ H‹ÇD$(H‰D$¸ HD$(L‹ ¸(HD$(ÇD$0L‹(H„$°H‰D$ éÐþÿÿDSH‰û¿Hƒìè®õÿÿH‰ÞHǰ)@E1ÉH‰$A¸ ¹ º@1ÿ1Àè´ýÿÿHƒÄ[Ãfffff.„SH‰û¿Hƒìè^õÿÿH‰ÞHÇ€'@E1ÉH‰$A¸ ¹ ºP@1ÿ1ÀèÄ÷ÿÿHƒÄ[Ãfffff.„SH‰û¿HƒìèõÿÿH‰ÞHÇ0(@E1ÉH‰$A¸ ¹ º@1ÿ1ÀèTùÿÿHƒÄ[Ãfffff.„SH‰û¿Hƒìè¾ôÿÿH‰ÞHÇà(@E1ÉH‰$A¸ ¹ ºÐ@1ÿ1ÀèäúÿÿHƒÄ[Ãfffff.„AUATI‰ôH‰ÎUH‰ýSH‰ÓHƒì8H…Ò„¶H‰úA¸¹¿<Ã`èéUIüÿÿÿH‰D$H‰T$H‰D$ H‰T$(H‰ÆI‰Õ‡ƒfWÀòD$ë;fDH‰êL‰îA¸¹¿<Ã`è•UH‰D$H‰T$H‰ÆH‰D$ H‰T$(I‰ÕºD‰çèžðÿÿòXD$HƒëòD$u¬òD$HƒÄ8[]A\A]ÃfWÀòD$ëãL‰çè÷ðÿÿ€H‹=¡¡ S1À¹Y…@ºv…@¾è¢ðÿÿ…ÀxNH‹=¡ 1À¹˜†@ºv…@¾èðÿÿ…Àx=H‹^¡ ¿ H‰ÞèéîÿÿH‰ßè¡ïÿÿ[¿éV.fD¾p†@‰ÇèT.ë¤f¾p†@‰ÇèD.ëµfHƒìHþÿÿÿw&Húÿÿÿw%9ÖMòƒÆò*ÆfÀfZÀóHƒÄÃH‰÷è%ðÿÿH‰×èðÿÿffff.„HƒìHþÿÿÿw&Húÿÿÿw%9ÖtÇHƒÄÃÇ€?HƒÄÃH‰÷èÕïÿÿH‰×èÍïÿÿffff.„HƒìHÿÿÿÿw)Hþÿÿÿw9÷MþƒÇò*ÇfÀfZÀóHƒÄÃH‰÷è…ïÿÿDHƒìHþÿÿÿwHúÿÿÿw9ÖMòƒÆò*ÆòHƒÄÃH‰÷èMïÿÿH‰×èEïÿÿDHƒìHþÿÿÿw5Húÿÿÿw49ÖtHÇHƒÄÃf.„Hºð?H‰HƒÄÃH‰÷èöîÿÿH‰×èîîÿÿfffff.„HƒìHÿÿÿÿw!Hþÿÿÿw9÷MþƒÇò*ÇòHƒÄÃH‰÷è­îÿÿffff.„HƒìHþÿÿÿw%Húÿÿÿw$9ÖÇAMòƒÆó*ÆóHƒÄÃH‰÷èfîÿÿH‰×è^îÿÿfffff.„HƒìHþÿÿÿw9Húÿÿÿw89Öt‹¸c‰‹´c‰AHƒÄ˪c‰‹¦c‰AHƒÄÃH‰÷èîÿÿH‰×èúíÿÿf.„HƒìHÿÿÿÿw(Hþÿÿÿw9÷ÇBMþƒÇó*ÇóHƒÄÃH‰÷è¶íÿÿfDHƒìHþÿÿÿw&Húÿÿÿw%9ÖHÇAMòƒÆò*ÆòHƒÄÃH‰÷èuíÿÿH‰×èmíÿÿffff.„HƒìHþÿÿÿwEHúÿÿÿwD9ÖtH‹×bH‰H‹ÕbH‰AHƒÄÃ@H‹ÉbH‰H‹ÇbH‰AHƒÄÃH‰÷èíÿÿH‰×èþìÿÿfffff.„HƒìHÿÿÿÿw)Hþÿÿÿw9÷HÇBMþƒÇò*ÇòHƒÄÃH‰÷èµìÿÿDAUATI‰ôH‰ÎUH‰ýSH‰ÓHƒì8H…Ò„¶H‰úA¸¹¿<Ã`è¹PIüÿÿÿH‰D$H‰T$H‰D$ H‰T$(H‰ÆI‰Õ‡ƒfWÀòD$ë;fDH‰êL‰îA¸¹¿<Ã`èePH‰D$H‰T$H‰ÆH‰D$ H‰T$(I‰ÕºD‰çè>ëÿÿòXD$HƒëòD$u¬òD$HƒÄ8[]A\A]ÃfWÀòD$ëãL‰çèÇëÿÿ€AUATI‰ôH‰ÎUH‰ýSH‰ÓHƒì8H…Ò„®H‰úA¸¹¿<Ã`èÉOIüÿÿÿH‰D$H‰T$H‰D$ H‰T$(H‰ÆI‰Õw~WÀóD$ ë8H‰êL‰îA¸¹¿<Ã`è}OH‰D$H‰T$H‰ÆH‰D$ H‰T$(I‰ÕºD‰çè¶éÿÿóXD$ HƒëóD$ u¬óD$ HƒÄ8[]A\A]ÃWÀóD$ ëäL‰çèàêÿÿAUATI‰ôH‰ÎUH‰ýSH‰ÓHƒì8H…Ò„®H‰úA¸¹¿<Ã`èéNIüÿÿÿH‰D$H‰T$H‰D$ H‰T$(H‰ÆI‰Õw~WÀóD$ ë8H‰êL‰îA¸¹¿<Ã`èNH‰D$H‰T$H‰ÆH‰D$ H‰T$(I‰ÕºD‰çè6èÿÿóXD$ HƒëóD$ u¬óD$ HƒÄ8[]A\A]ÃWÀóD$ ëäL‰çèêÿÿH‰\$èH‰l$ðH‰ÓL‰d$øHƒìH…ÒI‰ôH‰ÍuOM…ät&H…Ûu!H‹=~š 1À¹Žˆ@ºv…@¾èˆéÿÿ…ÀxTóEH‹$H‹l$L‹d$HƒÄéHîÿÿ„H‹=9š 1À¹y…@ºv…@¾èCéÿÿ…Ày¾p†@‰ÇèC'낾p†@‰Çè4'ëžfH‰\$èH‰l$ðH‰ÓL‰d$øHƒìH…ÒI‰ôH‰ÍuOM…ät&H…Ûu!H‹=Ι 1À¹Žˆ@ºv…@¾èØèÿÿ…ÀxTòEH‹$H‹l$L‹d$HƒÄéØíÿÿ„H‹=‰™ 1À¹y…@ºv…@¾è“èÿÿ…Ày¾p†@‰Çè“&낾p†@‰Çè„&ëžfH‰\$èH‰l$ðH‰ËL‰d$øHƒì(H…ÒI‰ôH‰Õu_M…ät&H…íu!H‹=™ 1À¹Žˆ@ºv…@¾è(èÿÿ…Àxl‹‹CH‹l$H‹\$L‹d$ ‰T$‰D$ ó~D$HƒÄ(é©Hf„H‹=ɘ 1À¹y…@ºv…@¾èÓçÿÿ…Ày€¾p†@‰ÇèÓ%éoÿÿÿfD¾p†@‰Çè¼%ë†f.„H‰\$èH‰l$ðH‰ËL‰d$øHƒìH…ÒI‰ôH‰ÕuOM…ät&H…íu!H‹=N˜ 1À¹Žˆ@ºv…@¾èXçÿÿ…ÀxTòH‹l$òKL‹d$H‹$HƒÄéDH@H‹= ˜ 1À¹y…@ºv…@¾èçÿÿ…Ày¾p†@‰Çè%낾p†@‰Çè%ëžfé;êÿÿff.„AW1À¹|…@ºv…@¾AVAUATUSHìxH‹=—— è²æÿÿ…Àˆ<H‹ƒ— ¿ H‰ÞèåÿÿH‰ßèÎåÿÿL„$๺0@¾ ¿ HÇ„$à !@èACH‹=:— H‰D$X¹…@1Àºv…@¾è?æÿÿ…ÀˆêH‹|$XèóÿÿH‹— ¿ H‰Þè™äÿÿH‰ß» èLåÿÿH‹l$X€H¼$H‰êA¹A¸¹ ¾DÃ`HÇ$A‰ÜèßKH‹„$H…ÛL‹´$˜L‹¬$ H‹¬$¨ót8‹5”— 1Ò1À@H ……öHDÊHƒÀHƒÂ(LéH9Øóó^ÁórÖ¿DÃ`èÄI9í„“I9ó J[A¹ó@[E‰àD‰áºo¾o‰ÇÇD$( H‰l$ ÇD$ L‰t$ÇD$ L‰,$èåÿÿHƒë…õþÿÿH‹=Ε 1À¹”…@ºv…@¾èØäÿÿ…ÀˆrH‹|$Xè&òÿÿH‹Ÿ• ¿ H‰Þè2ãÿÿH‰ßèêãÿÿL„$ð¹º0@¾ ¿ HÇ„$ðp!@è]AH‰D$`H‰D$A¹ H‹D$Xó`ZA¸ƒ¹oºy¾Ž¿eÇD$ H‰D$ÇD$ Ç$ è%ãÿÿH‹=þ” 1À¹–…@ºv…@¾èäÿÿ…Àˆ‘H‹|$`èVñÿÿH‹Ï” ¿ H‰ÞèbâÿÿH‰ßèãÿÿH‹D$`óÍYA¹ A¸„¹oºz¾¿eH‰D$H‹D$XÇD$ ÇD$ Ç$ H‰D$è‚âÿÿH‹=[” 1À¹…@ºv…@¾èeãÿÿ…ÀˆÝH‹|$`A¿ è­ðÿÿH‹&” ¿ H‰Þè¹áÿÿH‰ßèqâÿÿH‹t$XE1ÉA¸ ¹ ºÀ!@1ÿ1ÀHÇ$èhèÿÿL‹d$`L‹l$XfDº L‰îA¸¹¿DÃ`èKGL‰æH‰”$ˆH‰”$¸A¸¹¿DÃ`I‰Õº H‰ÃH‰„$€H‰„$°èG¾DÃ`H‰”$ˆH‰”$¸I‰Ô¿<Ã`º I‰ÆH‰„$€H‰„$°èŽFH=ÿÿÿH‰Å‡º ¾DÃ`¿<Ã`èkFH=ÿÿÿ‡éA‰ÀL‰ñ‰êH‰Þó X¿ èâßÿÿIƒï…ÿÿÿH‹L$`º ¾ ¿ è_öÿÿH‹|$XóD$hè/åÿÿH‹|$`è%åÿÿH‹=®’ 1À¹›…@ºv…@¾è¸áÿÿ…ÀˆH‹=‰’ ¹ º£…@¾1Àè“áÿÿH‹=l’ 1À¹§…@ºv…@¾èváÿÿ…ÀˆÌóD$hèCæÿÿH‹<’ ¿ H‰ÞèÏßÿÿH‰ßè‡àÿÿH‹= ’ 1À¹Ð†@ºv…@¾è*áÿÿ…ÀˆoH‹û‘ ¿ H‰ÞèŽßÿÿH‰ßèFàÿÿH‹=ß‘ 1À¹µ…@ºv…@¾èéàÿÿ…ÀˆH‹º‘ ¿ H‰ÞèMßÿÿH‰ßèàÿÿL„$¹ºp@¾ ¿ HÇ„$"@èx=H‹=q‘ H‰D$X¹…@1Àºv…@¾èvàÿÿ…Àˆ™H‹|$XèîÿÿH‹=‘ ¿ H‰ÞèÐÞÿÿH‰ß» èƒßÿÿH‹l$XfDH¼$H‰êA¹A¸¹ ¾DÃ`HÇ$A‰ÜèFH‹„$H…ÛL‹´$˜L‹¬$ H‹¬$¨òt8‹5Ì‘ 1Ò1À@H Å…öHDÊHƒÀHƒÂPLéH9Øòò^ÁòrÖ¿DÃ`èüI9í„ãI9î„Úò ŠUA¹ò„UE‰àD‰áºo¾o‰ÇÇD$( H‰l$ ÇD$ L‰t$ÇD$ L‰,$è§ÝÿÿHƒë…õþÿÿH‹= 1À¹”…@ºv…@¾èßÿÿ…Àˆ"H‹|$Xè®ìÿÿH‹× ¿ H‰ÞèjÝÿÿH‰ßè"ÞÿÿL„$¹ºp@¾ ¿ HÇ„$@"@è•;H‰D$`H‰D$A¹ H‹D$Xò TA¸ƒ¹oºy¾Ž¿eÇD$ H‰D$ÇD$ Ç$ èíÝÿÿH‹=6 1À¹–…@ºv…@¾è@Þÿÿ…ÀˆAH‹|$`èÞëÿÿH‹ ¿ H‰ÞèšÜÿÿH‰ßèRÝÿÿH‹D$`ò TA¹ A¸„¹oºz¾¿eH‰D$H‹D$XÇD$ ÇD$ Ç$ H‰D$èJÝÿÿH‹=“Ž 1À¹…@ºv…@¾èÝÿÿ…ÀˆH‹|$`A¿ è5ëÿÿH‹^Ž ¿ H‰ÞèñÛÿÿH‰ßè©ÜÿÿH‹t$XE1ÉA¸ ¹ º "@1ÿ1ÀHÇ$è€äÿÿL‹d$`L‹l$XfDº L‰îA¸¹¿DÃ`èƒAL‰æH‰”$ˆH‰”$¸A¸¹¿DÃ`I‰Õº H‰ÃH‰„$€H‰„$°è@A¾DÃ`H‰”$ˆH‰”$¸I‰Ô¿<Ã`º I‰ÆH‰„$€H‰„$°èÆ@H=ÿÿÿH‰Å‡Iº ¾DÃ`¿<Ã`è£@H=ÿÿÿ‡!òoRA‰ÀL‰ñ‰êH‰Þ¿ è:ÚÿÿIƒï…ÿÿÿH‹L$`º ¾ ¿ èwêÿÿH‹|$XòD$hègßÿÿH‹|$`è]ßÿÿH‹=æŒ 1À¹›…@ºv…@¾èðÛÿÿ…ÀˆÏH‹=ÁŒ ¹ º£…@¾1ÀèËÛÿÿH‹=¤Œ 1À¹§…@ºv…@¾è®Ûÿÿ…Àˆ|òD$hè»àÿÿH‹tŒ ¿ H‰ÞèÚÿÿH‰ßè¿ÚÿÿH‹=XŒ 1À¹Ð†@ºv…@¾èbÛÿÿ…ÀˆH‹3Œ ¿ H‰ÞèÆÙÿÿH‰ßè~ÚÿÿH‹=Œ 1À¹Ê…@ºv…@¾è!Ûÿÿ…ÀˆÍ H‹ò‹ ¿ H‰Þè…ÙÿÿH‰ßè=ÚÿÿL„$ ¹º°@¾ ¿ HÇ„$ à"@è°7H‹=©‹ H‰D$p¹…@1Àºv…@¾è®Úÿÿ…ÀˆI H‹|$pL¤$`è”èÿÿH‹m‹ ¿ H‰ÞèÙÿÿH‰ß» è³ÙÿÿH‹l$pfDH¼$H‰êA¹A¸¹ ¾DÃ`HÇ$A‰ÝèG@H‹„$H…ÛL‹¼$˜L‹´$ H‹¬$¨óóD$Xó@óD$`„~‹ç‹ 1É1Ò‰D$h‹|$hHÕó\$`óT$X…ÿHDÁLðóóHH‰D$@H‰T$HH‰L$PèšEH‹T$HH‹L$PfÖD$xH‹D$@‹t$|‹|$xHƒÂHƒÁPH9Ó‰p‰8w“¿DÃ`èÑI9î„Ð I9ï„Ç ‹AOA¹E‰èD‰é¾o‰ÇÇD$8 H‰l$0‰”$`‹OÇD$ L‰|$ÇD$ L‰t$‰”$d‹ÅNL‰$$‰”$h‹¸N‰”$lH”$hH‰T$(ºoèæÖÿÿHƒë…dþÿÿH‹=¥‰ 1À¹”…@ºv…@¾è¯Øÿÿ…Àˆk H‹|$pèæÿÿH‹v‰ ¿ H‰Þè ×ÿÿH‰ßèÁ×ÿÿL„$0¹º°@¾ ¿ HÇ„$00#@è45H‰D$X‹ NA¹ A¸ƒ¹oºy¾Ž¿eÇD$( ‰„$`‹ØMÇD$ L‰d$Ç$ ‰„$dH‹D$XH‰D$ H‹D$pH‰D$èÐÖÿÿH‹=¹ˆ 1À¹–…@ºv…@¾èÃ×ÿÿ…Àˆ: H‹|$Xè±åÿÿH‹Šˆ ¿ H‰ÞèÖÿÿH‰ßèÕÖÿÿ‹OMA¹ A¸„¹oºz¾¿eÇD$( ÇD$ ‰„$`‹ML‰d$Ç$ ‰„$dH‹D$XH‰D$ H‹D$pH‰D$èÖÿÿH‹=ÿ‡ 1À¹…@ºv…@¾è ×ÿÿ…Àˆ‘ H‹|$XA¿ èñäÿÿH‹ʇ ¿ H‰Þè]ÕÿÿH‰ßèÖÿÿH‹t$pE1ÉA¸ ¹ º#@1ÿ1ÀHÇ$èÌßÿÿH‹l$XL‹l$pfº L‰îA¸¹¿DÃ`èó:H‰îH‰”$ˆH‰”$¸A¸¹¿DÃ`I‰Õº H‰ÃH‰„$€H‰„$°è°:¾DÃ`H‰”$ˆH‰”$¸H‰Õ¿<Ã`º I‰ÆH‰„$€H‰„$°è6:H=ÿÿÿI‰Ä‡© º ¾DÃ`¿<Ã`è:H=ÿÿÿ‡‘ ‹¹KH´$hA‰ÁM‰ðD‰á¿ ‰”$h‹šK‰”$lH‰ÚèoÕÿÿIƒï…õþÿÿH‹L$Xº ¾ ¿ èÌêÿÿH‹|$póD$`è¼ØÿÿH‹|$Xè²ØÿÿH‹=;† 1À¹›…@ºv…@¾èEÕÿÿ…ÀˆÞ H‹=† ¹ º£…@¾1Àè ÕÿÿH‹=ù… 1À¹§…@ºv…@¾èÕÿÿ…ÀˆÐóD$`èÐÙÿÿH‹É… ¿ H‰Þè\ÓÿÿH‰ßèÔÿÿH‹=­… 1À¹Ð†@ºv…@¾è·Ôÿÿ…Àˆ•H‹ˆ… ¿ H‰ÞèÓÿÿH‰ßèÓÓÿÿH‹=l… 1À¹ß…@ºv…@¾èvÔÿÿ…ÀˆeH‹G… ¿ H‰ÞèÚÒÿÿH‰ßè’ÓÿÿL„$@¹ºð@¾ ¿ HÇ„$@Ð#@è1H‹=þ„ H‰D$p¹…@1Àºv…@¾èÔÿÿ…ÀˆH‹|$pL¤$ÀèùàÿÿH‹„ ¿ H‰ÞèUÒÿÿH‰ß» èÓÿÿH‹l$pH¼$H‰êA¹A¸¹ ¾DÃ`HÇ$A‰ÝèŸ9H‹„$H…ÛL‹¼$˜L‹´$ H‹¬$¨òòD$Xò@òD$`tz‹C… 1É1Ò‰D$h€‹t$hH‰ÐHÁàò\$`òT$X…öHDÁLðòòHH‰D$@H‰T$HH‰L$PèÃAH‹T$HH‹L$PH‹D$@HƒÂHÁ H9ÓòòHw›¿DÃ`è1 I9î„HI9ï„?H‹¨HA¹E‰èD‰é¾o‰ÇÇD$8 H‰l$0H‰”$ÀH‹HÇD$ L‰|$ÇD$ L‰t$H‰”$ÈH‹8HL‰$$H‰”$ÐH‹-HH‰”$ØH”$ÐH‰T$(ºoèîÐÿÿHƒë…dþÿÿH‹=ý‚ 1À¹”…@ºv…@¾èÒÿÿ…ÀˆH‹|$pèßÿÿH‹΂ ¿ H‰ÞèaÐÿÿH‰ßèÑÿÿL„$P¹ºð@¾ ¿ HÇ„$P $@èŒ.H‰D$XH‹xGA¹ A¸ƒ¹oºy¾Ž¿eÇD$( H‰„$ÀH‹IGÇD$ L‰d$Ç$ H‰„$ÈH‹D$XH‰D$ H‹D$pH‰D$èÔÏÿÿH‹= ‚ 1À¹–…@ºv…@¾èÑÿÿ…Àˆ9H‹|$XèÞÿÿH‹Þ ¿ H‰ÞèqÏÿÿH‰ßè)ÐÿÿH‹ºFA¹ A¸„¹oºz¾¿eÇD$( ÇD$ H‰„$ÀH‹ƒFL‰d$Ç$ H‰„$ÈH‹D$XH‰D$ H‹D$pH‰D$èÏÿÿH‹=O 1À¹…@ºv…@¾èYÐÿÿ…ÀˆŒH‹|$XA¿ èQÝÿÿH‹ ¿ H‰Þè­ÎÿÿH‰ßèeÏÿÿH‹t$pE1ÉA¸ ¹ º$@1ÿ1ÀHÇ$èüÚÿÿH‹l$XL‹l$pfº L‰îA¸¹¿DÃ`èC4H‰îH‰”$ˆH‰”$¸A¸¹¿DÃ`I‰Õº H‰ÃH‰„$€H‰„$°è4¾DÃ`H‰”$ˆH‰”$¸H‰Õ¿<Ã`º I‰ÆH‰„$€H‰„$°è†3H=ÿÿÿI‰Ä‡ùº ¾DÃ`¿<Ã`èc3H=ÿÿÿ‡áH‹EH´$ÐA‰ÁM‰ðD‰á¿ H‰”$ÐH‹óDH‰”$ØH‰Úè ÎÿÿIƒï…ñþÿÿH‹L$Xº ¾ ¿ èHâÿÿH‹|$pòD$`èÒÿÿH‹|$XèþÑÿÿH‹=‡ 1À¹›…@ºv…@¾è‘Îÿÿ…ÀˆÕH‹=b ¹ º£…@¾1ÀèlÎÿÿH‹=E 1À¹§…@ºv…@¾èOÎÿÿ…Àˆ¤òD$`è\ÓÿÿH‹ ¿ H‰Þè¨ÌÿÿH‰ßè`ÍÿÿH‹=ù~ 1À¹Ð†@ºv…@¾èÎÿÿ…ÀˆiH‹Ô~ ¿ H‰ÞègÌÿÿH‰ßèÍÿÿHÄx[]A\A]A^A_ÃD‰D$@èÿÜÿÿ‹D$@édèÿÿfD‰D$@èçÜÿÿ‹D$@éîÿÿfD‰D$@èÏÜÿÿ‹D$@é'ôÿÿfD‰D$@è·Üÿÿ‹D$@é¯úÿÿ¾p†@‰Çèr 鳿ÿÿ¾p†@‰Çèa é¦òÿÿ¾p†@‰ÇèP é"òÿÿ¾p†@‰Çè? éÐñÿÿ¾p†@‰Çè. ésñÿÿ¾p†@‰Çè é ñÿÿ¾p†@‰Çè ébïÿÿ¾p†@‰Çèû é®îÿÿ¾p†@‰Çèê éÍíÿÿ¾p†@‰ÇèÙ éVìÿÿ¾p†@‰ÇèÈ éÒëÿÿ¾p†@‰Çè· é€ëÿÿ¾p†@‰Çè¦ é#ëÿÿ¾p†@‰Çè• éÐêÿÿ¾p†@‰Çè„ ééÿÿ¾p†@‰Çès é^èÿÿ¾p†@‰Çèb é}çÿÿ¾p†@‰ÇèQ éæÿÿ¾p†@‰Çè@ é„óÿÿ¾p†@‰Çè/ é÷ÿÿ¾p†@‰Çè éZ÷ÿÿ¾p†@‰Çè éŠ÷ÿÿ¾p†@‰Çèü éì÷ÿÿ¾p†@‰Çèë é×ùÿÿ¾p†@‰ÇèÚ é¶úÿÿ¾p†@‰ÇèÉ écûÿÿ¾p†@‰Çè¸ éýÿÿ¾p†@‰Çè§ éKýÿÿ¾p†@‰Çè– é†ýÿÿ¾p†@‰Çè… éµóÿÿ¾p†@‰Çèt é^ôÿÿ¾p†@‰Çèc éöÿÿL‰çèvËÿÿH‰ÇènËÿÿH‰ïèfËÿÿfDHƒìD‹-| E…ÀtHƒÄÃÇ| è-èt(è-HƒÄé†6fD1Àé¹ÿÿÿUH‰å]ÃUH‰å]ÃUH‰å]ÃUH‰å]ÃUH‰åHìàH‰½(ÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰µ ÿÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹ ÿÿÿH•0ÿÿÿH‹…(ÿÿÿH‰ÎH‰ÇèêÉÿÿ‰…Lÿÿÿ‹…LÿÿÿÉÃUH‰åHìàH‰½(ÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰µ ÿÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹ ÿÿÿH•0ÿÿÿH‹…(ÿÿÿH‰ÎH‰Çè6Éÿÿ‰…Lÿÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾h‡@‰ÇèeÉÃUH‰åHìàH‰µXÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰½(ÿÿÿ¸èþÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹…(ÿÿÿH•0ÿÿÿH‰ÖH‰ÇèúÇÿÿ‰…Lÿÿÿ¸è¸ýÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾…‡@‰ÇèÉÃUH‰åHìàH‰µXÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰½(ÿÿÿ¸è>ýÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹(ÿÿÿH‹Çx H•0ÿÿÿH‰ÎH‰ÇèÇÿÿ‰…Lÿÿÿ¸èçüÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾¡‡@‰Çè²ÉÃUH‰åH‰}èH‹Eè‹…Àu ÇEüeë ÇEüf‹Eü]ÃUH‰åH‰}èH‹Eè‹…Àu ÇEüyë ÇEüz‹Eü]ÃUH‰åH‰}èH‹Eè‹…Àu ÇEü„ë ÇEüƒ‹Eü]ÃUH‰åH‰}èH‹Eè‹…Àu ÇEüoëH‹E苃øu ÇEüpë ÇEüq‹Eü]ÃUH‰åH‰}èH‹Eè‹…Àu ÇEüë ÇEüŽ‹Eü]ÃUH‰å‹Ôw …ÀuÇÆw è±(ë]ÃUH‰å¸èÏÿÿÿ]ÃUH‰å]ÃUH‰å]ÃUH‰å]ÃUH‰å]ÃUH‰åHìàH‰½(ÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰µ ÿÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹ ÿÿÿH•0ÿÿÿH‹…(ÿÿÿH‰ÎH‰ÇèŠÅÿÿ‰…Lÿÿÿ‹…LÿÿÿÉÃUH‰åHìàH‰½(ÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰µ ÿÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹ ÿÿÿH•0ÿÿÿH‹…(ÿÿÿH‰ÎH‰ÇèÖÄÿÿ‰…Lÿÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾½‡@‰ÇèÉÃUH‰åHìàH‰µXÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰½(ÿÿÿ¸èþÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹…(ÿÿÿH•0ÿÿÿH‰ÖH‰ÇèšÃÿÿ‰…Lÿÿÿ¸è¸ýÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾Ú‡@‰Çè/ÉÃUH‰åHìàH‰µXÿÿÿH‰•`ÿÿÿH‰hÿÿÿL‰…pÿÿÿL‰xÿÿÿ„Àt )E€)M)U )]°)eÀ)mÐ)uà)}ðH‰½(ÿÿÿ¸è>ýÿÿÇ…0ÿÿÿÇ…4ÿÿÿ0HEH‰…8ÿÿÿH…PÿÿÿH‰…@ÿÿÿH‹(ÿÿÿH‹gt H•0ÿÿÿH‰ÎH‰Çè-Ãÿÿ‰…Lÿÿÿ¸èçüÿÿƒ½Lÿÿÿy‹…Lÿÿÿ¾ö‡@‰ÇèRÉÃUH‰å‹nt …ÀuÇ`t èó!è%è)%ë]ÃUH‰å¸èÅÿÿÿ]ÃHƒì1Àè1Àè>1Àè‡ 1ÀèÐ 1Àè 1Àè1Àè[1ÀèD1Àè1Àèö1Àèß1Àè(1ÀèÁ1Àè*1Àè“1ÀèÜ1Àè1Àè 1Àè7!1Àè !1ÀèÙ!1ÀHƒÄé."fffff.„‹†s …Àu Çxs óÃf.„‹fs …Òu ÇXs óË%ÄHƒìè×Áÿÿ€S‰ûH‰÷H‹5Ër èÀÿÿ‰ßè·Áÿÿ€Hƒì…ÿtHƒÄÃH‹ ¤r ¿ˆ@º¾è˜Áÿÿ¿è~Áÿÿfffff.„Hƒì…ÿtHƒÄÃH‹=dr H‰ñºHˆ@¾1ÀèhÁÿÿ¿è>Áÿÿfffff.„Hƒì‹<%è ÁÿÿHƒìH‹ r º¾¿.ˆ@èÁÿÿ1ÀèÊÿÿÿf.„‹Jr …Àu ÇH¾gfffffffDH‰ØHƒéH÷îH‰ØHÁø?HÁúH)ÂH’HÀH)ÃÃ0H…ÒˆH‰ÓuÑHƒý|+H‰ÈuHƒèÆAÿ0[]A\Ãf„ƒÆ~LcæHcÿë‚fÆAÿ-HAÿ[]A\ÃUH‰ýSHƒìH…ÿtrH‰ú1ÛH¹ÍÌÌÌÌÌÌÌH‰ÐƒÃH÷áHÁêH…Òuî{HcÛHcÿèP·ÿÿHÃH¹ÍÌÌÌÌÌÌÌÆH‰èHƒëH÷áHÁêH’HÀH)ŃÅ0H…Ò@ˆ+H‰ÕuÚHƒÄH‰Ø[]ÿè·ÿÿH‰ÃÆ@Æ0ëà‹ne …Àu Ç`e óÃf.„‹Ne …Òu Ç@e óË2e …Àu Ç$e óÃf.„‹e …Òu Çe óÃóÃfffff.„‹æd …ÀtóÃ@ÇÒd éá1ÀéÙÿÿÿf„S‰ûHìЄÀH‰T$0H‰L$8L‰D$@L‰L$Ht7)D$P)L$`)T$p)œ$€)¤$)¬$ )´$°)¼$ÀH„$àH‹=àc HL$H‰ò¾ÇD$H‰D$HD$ ÇD$ 0H‰D$臰ÿÿ‰ßè ²ÿÿHìØ„ÀH‰T$0H‰L$8L‰D$@L‰L$Ht7)D$P)L$`)T$p)œ$€)¤$)¬$ )´$°)¼$À…ÿtHÄØÃfDH„$àH‹=1c HL$H‰ò¾ÇD$H‰D$HD$ ÇD$ 0H‰D$èØ¯ÿÿ…Àx¾P‰@¿èðÿÿHÄØÃD¾(‰@‰Çèüïÿÿë„f.„H‰\$ØL‰l$ðH‰ÓL‰t$øH‰l$àI‰öL‰d$èA‰ýHƒìHH‹McåL‰çH‰D$H‹CH‰D$H‹CH‰D$èe´ÿÿLL$M‰ðHÇÁÿÿÿÿºL‰æH‰ÇH‰ÅèÓ°ÿÿ…ÀxGA9Å~*H‰èH‹\$ H‹l$(L‹d$0L‹l$8L‹t$@HƒÄHÃf„H‰ïDhè„´ÿÿéuÿÿÿ€1íëº@HìØ„ÀH‰T$0H‰L$8L‰D$@L‰L$Ht7)D$P)L$`)T$p)œ$€)¤$)¬$ )´$°)¼$ÀH„$àHT$ÇD$ÇD$ 0H‰D$HD$ H‰D$è¹þÿÿHÄØÃHƒìH‰òH‰þ¿èœþÿÿH…ÀtHƒÄÃf¾x‰@¿H‰D$èlîÿÿH‹D$HƒÄÃfHìØ„ÀH‰t$(H‰T$0H‰L$8L‰D$@L‰L$Ht7)D$P)L$`)T$p)œ$€)¤$)¬$ )´$°)¼$ÀH„$àHt$ÇD$ÇD$ 0H‰D$HD$ H‰D$è4ÿÿÿHÄØÃÿæfffff.„‹ú` …Àu Çì` óÃf.„‹Ú` …Òu ÇÌ` óÃH‰ÑH‰ø1ÒH÷öH¯ðH)÷H‰9Ãf.„‹ž` …Àu Ç` óÃf.„‹~` …Òu Çp` óÃS@¾ßƒ€=w艬ÿÿH‹HcÛHš‹‰Ø[Ãf„S@¾ßƒ€=wèÙ®ÿÿH‹HcÛH™‹‰Ø[Ãf„AVI‰öAUATUSH‰ûè¬ÿÿHxI‰ÅèQ±ÿÿM…íI‰ÄH‰Åt1í@¾<+AÿÖAˆ,HƒÅL9íuìLåÆEL‰à[]A\A]A^Ãf„HìØ„ÀH‰t$(H‰T$0H‰L$8L‰D$@L‰L$Ht7)D$P)L$`)T$p)œ$€)¤$)¬$ )´$°)¼$ÀH„$àH‰úH‹=»^ HL$¾ÇD$H‰D$HD$ ÇD$ 0H‰D$èe«ÿÿ…ÀxHÄØÃf„¾ž‰@‰Çè”ëÿÿHÄØÃfff.„HƒìH‰ùH‹=B^ 1Àºv…@¾èQ­ÿÿ…Àx HƒÄľp†@‰ÇHƒÄé@ëÿÿHƒìH‰ùH‹= ^ 1Àºv…@¾è­ÿÿ…Àx HƒÄľp†@‰ÇHƒÄéëÿÿAVA‰öAUATUHcîSH‰ûH}覯ÿÿÆ(1íE…öI‰ÅëEfDEˆd-HƒÅA9î~1D¶#H‹[E„äuå1À¿À‰@èYþÿÿ¿èêÿÿEˆd-HƒÅA9îÏ[]A\L‰èA]A^ÃDAWAVA‰öAUATUHcîSH‰ûH}Hƒìè ¯ÿÿAƒîI‰ÇÆ(xPE‰õMcö1íI÷ÕIÆëEˆ$.HƒíL9ít0D¶#H‹[E„äuæ1À¿À‰@èÊýÿÿ¿èêÿÿEˆ$.HƒíL9íuÐHƒÄL‰ø[]A\A]A^A_ÃATH…ÿUH‰ýStuI‰ü1Û€I‹<$M‹d$躩ÿÿHÃM…äuêH{èy®ÿÿ1ÿÆH‹uH‹m¶„Ét(H)þH9ßH‰úr ë@H9Úsˆ HƒÂ¶ „ÉuìH‰×H…íuÄ[]A\ÿè%®ÿÿÆ[]A\Ãffff.„AUI‰ýATU1íSHƒìè,©ÿÿH‰Ã1ÀH…Ûuë#H‰ÅHƒë¿E¶dèÙ­ÿÿH…ÛH‰hDˆ uÝHƒÄ[]A\A]Ãf1öH…ÿtH‰øfDH‹@ƒÆH…Àuôéßýÿÿffffff.„ATI‰ÔUS¶H‰ó„ÀtH‰ý@HƒÅ¾øL‰æÿÓ¶E„Àuì[]A\Ãffffff.„¾€b@éÖûÿÿfD¾Pb@éÆûÿÿfDHƒìH‰ùH‹=2[ 1Àºv…@¾èAªÿÿ…Àx HƒÄľp†@‰ÇHƒÄé0èÿÿHƒìH‰ùH‹=úZ 1Àºv…@¾èªÿÿ…Àx HƒÄľp†@‰ÇHƒÄéðçÿÿ‹5B[ …öu Ç4[ óÃf.„‹="[ …ÿu Ç[ óÃf.„¶¸Ùï/…Òt@H‰ÁHcÒHƒÇHÁáHÊHж…ÒuåóÃH‰\$èL‰d$øH‰ûH‰l$ðHƒì@„öA‰ôt:Hè¬ÿÿA¾ôH‰ÅH‰ÚH‰ï臧ÿÿÆDH‰èH‹$H‹l$L‹d$HƒÄÃ@¾Š@¿èçÿÿH{èЫÿÿ1öH‰Åë·f„L‰d$ðI‰üHzH‰\$àH‰l$èH‰ÕL‰l$øHƒì(I‰õè–«ÿÿK4,H‰ÃH‰êH‰Çè”§ÿÿÆ+H‰ØH‹l$H‹\$L‹d$L‹l$ HƒÄ(Ã@SH‰û臦ÿÿH‰ßH‰Â1ö[é‰ÿÿÿf„USHƒì¾/…ít,H‰û…€=wèn¨ÿÿH‹Hcí‹,¨@ˆ+HƒÃ¾+…íu×HƒÄ[]ÃUSHƒì¾/…ít,H‰û…€=w讥ÿÿH‹Hcí‹,¨@ˆ+HƒÃ¾+…íu×HƒÄ[]ËVY …Àu ÇHY óÃf.„‹6Y …Òu Ç(Y óÃH‰\$ÐH‰l$ØH‰ûL‰d$àL‰l$èH‰õL‰|$øL‰t$ðHƒì8H…öI‰ÔI‰ÍM‰Çt"E1ö€L‰÷IƒÆH‰ÞL‰úLëAÿÔI9îuèH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8ÃDH‰\$ÐH‰l$ØH‰ûL‰d$àL‰l$èI‰ôL‰t$ðL‰|$øE1öHƒì8H…öH‰ÕI‰ÍM‰Çt"€L‰öIƒÆH‰ÚL‰ùH‰ïLëÿUM9æuåH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8ÃfH¯ñH¯ÑH7HúÃH‰øÃfff.„H‰\$ØH‰l$àH‰ûL‰d$èL‰l$ðH‰õL‰t$øHƒì(H…ÒI‰ÔI‰ÍM‰Æt€H‰ßL‰öLëÿÕIƒìuïH‹$H‹l$L‹d$L‹l$L‹t$ HƒÄ(Ãf.„H‰\$ÐH‰l$ØH‰ûL‰d$àL‰l$èI‰ôL‰|$øL‰t$ðHƒì8H…ÒH‰ÕI‰ÍM‰Çt"E1ö€L‰÷IƒÆH‰ÞL‰úLëAÿÔI9îuèH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8ÃD‹W …Àu ÇW óÃf.„‹îV …Òu ÇàV óÃf.„H‰l$àH‰õH‰\$ØL‰t$øL‰d$èH‰ûL‰l$ðHƒì(H…íH‰ÖI‰Îu"H‹$H‹l$L‹d$L‹l$L‹t$ HƒÄ(ÃDH‰Êèè£ÿÿEÿ…À~ÏIcÖƒøE‰õH<A¼t'@H‰ÞEäè½£ÿÿ‰èD)à…À~¢EíA9ÄIcÕH<|ÝHcÐH‰ÞH‹l$I¯ÖH‹$L‹d$L‹l$L‹t$ HƒÄ(éz£ÿÿ‹V …Àu ÇôU óÃf.„‹âU …Òu ÇÔU óÃHƒì(H‰<$H‰|$¿H‰t$H‰t$èÿ¦ÿÿH‹T$H‰H‹T$H‰PHƒÄ(Ãf„H‹GÃff.„‹zU …ÀtóÃ@ÇfU éAôÿÿ1ÀéÙÿÿÿ‹NU …ÀuÇ@U ÇŠU óË.U …ÒuÇ U ÇjU óËU …ÀtóÃ@ÇþT é1ÀéÙÿÿÿI‰ÑH‰ð1ÒH÷wL‹GH‰ÖH‰ÇL‰ÊAÿà@H‰ÐÃfff.„H‰ÐÃfff.„H‰l$àH‰õH‰\$ØH¯ïH‰ÏL‰d$èL‰l$ðL‰t$øHƒìXI‰ôI‰ÕI‰ÎL‰D$H¯ýè²¥ÿÿL‹D$HT$H‰ÃL‰ñH‰îH‰ÇL‰d$L‰l$ HÇD$ðm@è„ûÿÿH‰ØH‹l$8H‹\$0L‹d$@L‹l$HL‹t$PHƒÄXËT …Àu ÇT óÃf.„‹þS …Òu ÇðS óÃHƒì(¿H‹D$0H‰$H‹D$8H‰D$H‹D$@H‰D$èõ¤ÿÿH‹$H‰H‹T$H‰PH‹T$H‰PHƒÄ(ÀHƒìXH‰T$ H‰L$(H‰T$0H‰|$8H‰t$@H‰$H‰|$H‰t$è€ÿÿÿHƒÄXÃff.„HƒìXH‰T$ H‰L$(H‰T$0H‰|$8H‰t$@H‰$H‰|$H‰t$è@ÿÿÿHƒÄXÃff.„H‹GÃff.„H‹GÃff.„‹öR …ÀtóÃ@ÇâR é¡ñÿÿ1ÀéÙÿÿÿ‹ÊR …Àu ǼR óÃ1ÀH…ÿ”ÀÀ1ÀH…ÿ•ÀÀ‹ŽR …Àu Ç€R óÃf.„‹nR …Òu Ç`R óËRR …Àu ÇDR óÃf.„‹2R …Òu Ç$R óÃ1ÀHƒ?t„HƒÀHƒ<ÇuõóËöQ …Àu ÇèQ óÃf.„‹ÖQ …Òu ÇÈQ óÃfÖD$ðóL$ô. ùóD$ðs5óíÀºBŠ@¾¸WÊZÀÉZÉéÊŸÿÿf.„Àº:Š@ɾ¸ZÀZÉé Ÿÿÿf. ¸s&òžºBŠ@¾¸fWÊévŸÿÿfDº:Š@¾¸é\Ÿÿÿfff.„fÖD$ð‹D$ðH‹=P ‰D$è‹D$ô‰D$ìó~D$èéÿÿÿ„fÖD$ð‹D$ðH‹=÷O ‰D$è‹D$ô‰D$ìó~D$èéèþÿÿ„H‹=ÉO éDÿÿÿ@H‹=ÁO é4ÿÿÿ@‹zP …Àu ÇlP óÃf.„‹ZP …Òu ÇLP óË>P …Àu Ç0P óË"P …ÀtóÃ@ÇP é! ‹P …ÀtóÃ@ÇòO é‹êO …Àu ÇÜO óËÎO …ÀtóÃ@ǺO 鋲O …ÀuxǤO ÇÆO Ç´O ÇžO Ç´O Ç®O ÇO ÇŽO ÇhO ÇjO Ç\O ÇjO óÃH‰øH‹H‹@ÿàI‰ðH‹GH‹wL‰ÇÿàL‰t$øM‰ÆH‰\$ØH‰l$àL‰d$èH‰ûL‰l$ðHƒì(H‰õL¯ñH…ÒI‰ÔM‰ÍtH‰ßL‰îLóÿÕIƒìuïH‹$H‹l$L‹d$L‹l$L‹t$ HƒÄ(Ãf.„L‰|$øM‰ÇH‰\$ÐH‰l$ØL‰d$àH‰ûL‰l$èL‰t$ðHƒì8L¯ùH…ÒI‰ôH‰ÕM‰ÍtE1öL‰÷IƒÆH‰ÞL‰êLûAÿÔL9õuèH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8ÃDL‰|$øM‰ÇH‰\$ÐH‰l$ØL‰d$àH‰ûL‰l$èL‰t$ðHƒì8L¯ùE1öH…ÒH‰õI‰ÔM‰ÍtL‰öIƒÆH‰ÚL‰éH‰ïLûÿUM9ôuåH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8Ãf‹¸…Ét ƒùtóÃfD‹6…öHEÂÀ‹…ÉHDÂÃffffff.„HƒìHH‰ð‹7…ötKƒþt0¿xŠ@H‰D$H‰T$H‰L$L‰$èqÿÿL‹$H‹L$H‹T$H‹D$H¯ÑHƒÄHI¯ÐHÂÃfDL‰ÂHƒÄHH¯ÑHÂÃf„HƒìHH‰ð‹7…ötCƒþt(¿èŠ@H‰D$H‰L$L‰D$èÿÿL‹D$H‹L$H‹D$L‰ÂHƒÄHH¯ÑHÂÀH¯ÑHƒÄHI¯ÐHÂÃAWAVI‰ÖAUM‰ÅATM‰ÌUSHƒìHM…ÉH‰t$H‰<$H‰Î„ŒL‹¼$€L¯úë fDH‰îH‹$M‰ð¹¿DÃ`èGÿÿÿH‰T$H‰T$(H‰ÕH‹T$H‰ÃL‰îM‰ð¹¿DÃ`H‰D$H‰D$ èÿÿÿH‰ÞH‰T$H‰T$8I‰ÕH‰ÇL‰úH‰D$H‰D$0èî˜ÿÿIƒìuˆHƒÄH[]A\A]A^A_Ãf„D‹H‰øH‹|$E…Òt0I¯ÉH‰L¯ÇH¯ÏHÑJ4NH‰HL‰@H‰pÃf„L¯ÁH‰L¯ÏL¯ÇJ H‰HIÐK4L‰@H‰pÃf„‹?I‰òI‰ÓL‰ÈH‹t$H‹T$…ÿtH‰L$M‰ÁL‰ÑM‰ØH‰Çé‘þÿÿL‰D$I‰ÉM‰ØL‰ÑH‰Çézþÿÿf.„AWAVAUI‰ýATUH‰õSH‰ÓHƒìXD‹L‰D$ L‰L$(L‹¼$L‹´$˜E…ÒL‹¤$ …»M…É„M…À„”f„L‰ú¹H‰îM‰ðL‰ïèšýÿÿL‰îH‰T$8H‰T$HH‰Õ¿DÃ`L‰úH‰D$0H‰D$@H‰D$è¾üÿÿI¯ÆH‹L$H‰D$H‹D$(H‰D$fDH‰ÏH‰L$L‰æÿÓH‹L$HL$Hƒl$uáHƒl$ …uÿÿÿHƒÄX[]A\A]A^A_ÃfDHƒ|$ tãHƒ|$(tÛL‰ú¹H‰îM‰ðL‰ïèzüÿÿL‰îH‰T$8H‰T$HH‰Õ¿<Ã`L‰úH‰D$0H‰D$@H‰D$èüÿÿI¯ÆH‹L$H‰D$H‹D$ H‰D$fDH‰ÏH‰L$L‰æÿÓH‹L$HL$Hƒl$uáHƒl$(…uÿÿÿHƒÄX[]A\A]A^A_ÃfDAWAVAUATM‰ÌUSL‰ÃHìˆD‹H‰<$H‰t$H‰T$H‹¬$ÐE…Û…ïM…É„ÏM…À„Æ1ÀL‰D$H‰ÃH‹”$ÀL‹„$ȹH‹t$H‹<$E1öèâûÿÿH‹4$H‰T$(¿DÃ`H‰T$xH‰T$I‰ÅH‹”$ÀH‰D$ H‰D$pèûÿÿI‰ÇH‹D$HÇD$0ðs@H‰\$@A¸ðs@L¯¼$ÈH‰D$8ë @L‹D$0L‰öIƒÆL‰êH‰éH|$0MýAÿÐM9ôuÞHƒÃH9\$…GÿÿÿHĈ[]A\A]A^A_ÃDM…ÀtäM…Étß1ÀL‰L$I‰Ä@H‹”$ÀL‹„$ȹH‹t$H‹<$E1öèŠúÿÿH‹4$H‰T$(¿<Ã`H‰T$xH‰T$I‰ÅH‹”$ÀH‰D$ H‰D$pèúÿÿI‰ÇH‹D$HÇD$Pt@L‰d$`A¸t@L¯¼$ÈH‰D$Xë @L‹D$PL‰öIƒÆL‰êH‰éH|$PMýAÿÐL9óuÞIƒÄL9d$…Gÿÿÿéÿÿÿf‹6H‰ø…öt'I¯ÈH‰M¯ÁI¯ÉHÑIÈH‰HL‰@Ãf„L‰ÎH‰I¯ðL¯ÁH 2M¯ÁH‰HIÐIðL‰@Ãff.„Hƒì8‹6H‰ø…ötsƒþt<¿X‹@H‰D$(H‰T$ H‰L$L‰D$L‰L$èû–ÿÿL‹L$L‹D$H‹L$H‹T$ H‹D$(I¯ÈL‰ÎH‰I¯ðI¯ÉHÑL1H 2L‰@H‰HHƒÄ8ÄI¯ÈH‰M¯ÁI¯ÉHÑIÈH‰HL‰@HƒÄ8Ãfffff.„Hƒì‹=2F …ÿt HƒÄÃDÇF è9öÿÿHƒÄéPöÿÿ1ÀéÉÿÿÿ‹úE …ÀtóÃ@ÇæE éáõÿÿó5˜(â(ëTæTî.ìvG(ê(ú(àó^ëóYýóYåóYéóXûóXáó\èó^çó^ï.äzMód$øól$üó~D$øÃf(ë(û(áó^êD(ÁóYýóYåóYèóXúóXàóD\Åó^çA(èó^ïë®.í{®Wÿ.×z7u5.ßz0@u*.ÀŠ×TN (éVä (âóYêóYàéoÿÿÿD(ÈóD\ÈE.ÉšÂ.À›À Ð…åD(ÁóD\ÁE.ÀŠÉD(ÂóD\ÂE.ÀšÂ.Ò›À ÐuD(ÃóD\ÃE.À‹ÿÿÿ.ÛŠÿÿÿE.ÉŠþþÿÿD(ÁóD\ÁE.ÀŠëþÿÿ„À(ïtó-¡D(Âó%• TîDTÄAVè(Õ(ëó\ë.íŠã(ïTãTîVì(à(ÝóYâ(éóYÃóYëóXå(êóYéóYçó\èóYïéuþÿÿ.ÉŠ.ÿÿÿD(ÂóD\ÂE.ÀŠ$ÿÿÿD(ÓóD\ÓE.ÒŠÿÿÿ„À(ïtó-üD(Àó%ð TîDTÄAVè(Å(éó\é.ízxTáTþVü(àóYÃ(ÏóYâó=7 (éóYëóXå(éóYêóYçó\èóYïéÏýÿÿ.Ûó-‰Š ÿÿÿé ÿÿÿ.É‹ þÿÿD(ÈD(ÂóD\ÈóD\Âédþÿÿ.Ézƒó=Qévÿÿÿò5ø f(àf(éf(Âf(ËfTÆfTÎf.Èv:f(Êf(úf(Äò^ËòYùòYÁòYÍòXûòXÅò\Ìò^Çò^Ïf.ÀzAóÃff(Ëf(ûf(Åò^ÊfD(ÅòYùòYÁòYÌòXúòXÄòD\Áò^ÇfA(Èò^Ïë¹f.É{¹fWÿf.×z5u3f.ßz-u+f.äŠúf(ÊfT ƒ fV ; f(ÁòYÍòYÄÃfD(ÌòD\ÌfE.ÉšÂf.ä›À Ð…õfD(ÅòD\ÅfE.ÀŠÖfD(ÂòD\ÂfE.ÀšÂf.Ò›À ÐufD(ÃòD\ÃfE.À‹ÿÿÿf.ÛŠÿÿÿfE.ÉŠýþÿÿfD(ÅòD\ÅfE.ÀŠèþÿÿ„Àf(Ïtò ÄfD(Âf(Óò»fTÎò\ÓfDTÀfAVÈf.ÒŠóf(×fTÃfTÖfVÐf(Äf(ÚòYÁf(ÕòYÍòYÓòYÜòXÂò\ËòYÇòYÏÃf.íŠ ÿÿÿfD(ÂòD\ÂfE.ÀŠÿÿÿfD(ÓòD\ÓfE.ÒŠÿÿÿ„Àf(Ïtò fD(ÄòfTÎfDTÀfAVÈf(áf(Íò\Íf.Ézf(ÏfTÅfTÎò=} fVÈf(Äf(éòYÂòYÊf(ÔòYëòYÓòXÅò\ÊòYÇòYÏÃf.Ûò˜Šûþÿÿéúþÿÿf.í‹üýÿÿfD(ÌfD(ÂòD\ÌòD\ÂéDþÿÿf.íò ^ŠoÿÿÿénÿÿÿH‰l$ØL‰d$àH-ó: L%ì: L‰l$èL‰t$ðL‰|$øH‰\$ÐHƒì8L)åA‰ýI‰öHÁýI‰×èk‹ÿÿH…ít1Û@L‰úL‰öD‰ïAÿÜHƒÃH9ëuêH‹\$H‹l$L‹d$L‹l$ L‹t$(L‹|$0HƒÄ8ÀóÃUH‰åSHƒìH‹X: Hƒøÿt»¾`DHƒëÿÐH‹HƒøÿuñHƒÄ[]ÃHƒìè?ŽÿÿHƒÄÃexit(ATS): uncaught exception: %s(%d) exit(ATS): %s: match failure. exit(ATS): %s: funarg match failure. exit(ATS): [ats_malloc_gc] failed. exit(ATS): [ats_calloc_gc] failed. exit(ATS): [ats_realloc_gc] failed. ArraySubscriptExceptionListSubscriptExceptionDivisionByZeroExceptionOverflowExceptionAssertionExceptionerror(ATS/CBLAS): cblas_gemm%s, test:A = L\U = size = %lu and error = test:test:test:exit(ATS): [fprint_float] failed. exit(ATS): [fprint_double] failed. [atspre_int_of_size(%lu)] failed exit(ATS): [fprint_string] failed. : overlapping between input and output is not allowed!================================================€?ð?€¿ð¿€?€¿ð?ð¿exit(ATS): [fprintf] failed exit(ATS): [printf] failed exit(ATS): [prerrf] failed exit(ATS): [fprintf] failed exit(ATS): [printf] failed exit(ATS): [prerrf] failed exit(ATS): [assert] failed [assertfalse] executed exit(ATS): [assert] failed: %s truefalseExit: [fprint_bool] failed. fputsfputcfflushexit(ATS): [fflush] failed fcloseexit(ATS): [fclose] failed exit(ATS): [fputs(%s)] failed exit(ATS): [fputc(%c)] failed [atspre_assert_prerrf]: prerrf failed [atspre_assert_prerrf]: assert failed exit(ATS): [atspre_vsprintf] failed. exit(ATS): [prerrf] failed exit(ATS): a string cannot contain null characters in the middle. exit(ATS): [string_make_char] failed: null char. %f+i*%f%f-i*%f€€/home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 13020(line=445, offs=14) -- 13100(line=446, offs=69)/home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 14083(line=478, offs=14) -- 14163(line=479, offs=69)/home/hwxi/research/Anairiats/libats/DATS/genarrays.dats: 33418(line=1101, offs=14) -- 33910(line=1113, offs=12)€ÿÿÿ€ðÿÿÿÿÿÿÿð;|°‚ÿÿ˜P…ÿÿ €…ÿÿ †ÿÿÀ°†ÿÿØІÿÿðà†ÿÿ ‡ÿÿ 0‡ÿÿ8 `‡ÿÿP ‡ÿÿh  ‡ÿÿ€ °‡ÿÿ˜ À‡ÿÿ° ЇÿÿÈ à‡ÿÿà ð‡ÿÿø 0ˆÿÿ pˆÿÿ8 €ˆÿÿP Àˆÿÿp Јÿÿˆ àˆÿÿ  ðˆÿÿ¸ ‰ÿÿÐ ‰ÿÿè @‰ÿÿ `‰ÿÿ €‰ÿÿ0  ‰ÿÿH À‰ÿÿ` à‰ÿÿx Šÿÿ @Šÿÿ° €ŠÿÿÐ `Œÿÿ @Žÿÿ0 ÿÿ` 0’ÿÿ¨ €’ÿÿÈ Ð’ÿÿè “ÿÿ p“ÿÿ( `”ÿÿh ð”ÿÿˆ @•ÿÿ¨ •ÿÿÈ Ð•ÿÿè –ÿÿp–ÿÿ(°–ÿÿH—ÿÿh`—ÿÿˆ —ÿÿ¨ð—ÿÿÈ`˜ÿÿè ˜ÿÿ™ÿÿHpšÿÿˆP›ÿÿÈœÿÿð°œÿÿ€ÿÿ@0žÿÿh@žÿÿ€ð¹ÿÿÐ0ºÿÿð8ºÿÿ0>ºÿÿPDºÿÿpJºÿÿPºÿÿ°»ÿÿÐÍ»ÿÿð£¼ÿÿ€½ÿÿ0©½ÿÿPÒ½ÿÿpû½ÿÿ9¾ÿÿ°b¾ÿÿÐ…¾ÿÿð˜¾ÿÿž¾ÿÿ0¤¾ÿÿPª¾ÿÿp°¾ÿÿd¿ÿÿ°-ÀÿÿÐÁÿÿðàÁÿÿ Âÿÿ0 ÂÿÿPÐÂÿÿhðÂÿÿ€Ãÿÿ˜ Ãÿÿ°0ÃÿÿÈPÃÿÿàÃÿÿÐÃÿÿ àÃÿÿ8ÄÿÿP0ÄÿÿhPÄÿÿ€pÄÿÿ˜Äÿÿ°àÄÿÿÐÅÿÿè Åÿÿ@Åÿÿ`Åÿÿ0€ÅÿÿHÅÿÿ`ðÅÿÿ˜ðÆÿÿèÇÿÿ°Çÿÿ8àÇÿÿP Èÿÿp0Èÿÿˆ@Èÿÿ PÈÿÿ¸`ÈÿÿÐpÈÿÿè°ÈÿÿðÈÿÿÉÿÿ00ÉÿÿH€ÉÿÿhÊÿÿ`Êÿÿ°ðÊÿÿØËÿÿø°Ëÿÿ ÐËÿÿ@Íÿÿ¸ÀÍÿÿØÐÍÿÿð0ÎÿÿÎÿÿ ðÎÿÿ8ÏÿÿP0ÏÿÿhPÏÿÿ€pÏÿÿ˜`ÐÿÿÐÑÿÿ Ñÿÿ@Ñÿÿ0`ÑÿÿH€Ñÿÿ`Ñÿÿx°ÑÿÿÀÑÿÿ¨`ÒÿÿÈ@ÓÿÿðÔÿÿÔÿÿ8ÐÔÿÿXpÕÿÿx€Õÿÿ Õÿÿ¨ÀÕÿÿÀàÕÿÿØÖÿÿð ÖÿÿPÖÿÿ(€ÖÿÿHàÖÿÿˆ°×ÿÿ¨ð×ÿÿÈ0Øÿÿè°Øÿÿ(@ÙÿÿpàÙÿÿ¨0Úÿÿà`Úÿÿø Úÿÿ(°Úÿÿ@ÀÚÿÿXÛÿÿx@Ûÿÿ˜`Ûÿÿ°€ÛÿÿȰÛÿÿà0Üÿÿ Üÿÿ0 °ÜÿÿP ðÜÿÿx 0Ýÿÿ  PÝÿÿ¸ pÝÿÿÐ ðÝÿÿø pÞÿÿ !€Þÿÿ8!ÞÿÿP!ßÿÿx!€ßÿÿ ! ßÿÿ¸!ÀßÿÿÐ!àÿÿ"°àÿÿ"Ðàÿÿ0"áÿÿH" áÿÿ`"@áÿÿx"Páÿÿ"páÿÿ¨"áÿÿÀ"°áÿÿØ"Àáÿÿð"àáÿÿ#ðáÿÿ #âÿÿ8#âÿÿ`#°âÿÿx#Ðâÿÿ# ãÿÿ¨#`ãÿÿÀ# ãÿÿØ#°ãÿÿð#Àãÿÿ$àãÿÿ $ðãÿÿ8$äÿÿP$ äÿÿh$0äÿÿ€$Päÿÿ˜$päÿÿ°$äÿÿÈ$°äÿÿà$Ðäÿÿø$ðäÿÿ%åÿÿ(%€åÿÿ@%ÐåÿÿX%æÿÿp%0æÿÿˆ%@æÿÿ %Pæÿÿ¸%pæÿÿÐ%æÿÿè%°æÿÿ&Ðæÿÿ&ðæÿÿ0&çÿÿH&0çÿÿ`&Àçÿÿx&Ðçÿÿ&àçÿÿ¨&PèÿÿÐ&Ðèÿÿø&Péÿÿ 'éÿÿ8'êÿÿX'`êÿÿx'0ëÿÿÈ' ëÿÿà'ðëÿÿø' íÿÿ`( ïÿÿ°(ðÿÿÈ(°ðÿÿè(àðÿÿ)ððÿÿ )ñÿÿ8)àóÿÿP)àöÿÿh)p÷ÿÿ)zRx $zÿÿ FJ w€?;*3$"DØ}ÿÿ\Ð}ÿÿtØ}ÿÿŒÐ}ÿÿ¤Ø}ÿÿ-D¼ð}ÿÿ)DÔ~ÿÿ)Dì ~ÿÿ~ÿÿ~ÿÿ4~ÿÿL~ÿÿdø}ÿÿ|ð}ÿÿ6D N F ]œ~ÿÿ6D N F ]¼0~ÿÿÔ(~ÿÿ6D N F ]ôH~ÿÿ @~ÿÿ$8~ÿÿ<0~ÿÿT(~ÿÿl0~ÿÿ„8~ÿÿœ@~ÿÿ´H~ÿÿÌP~ÿÿäX~ÿÿü`~ÿÿh~ÿÿ@Gf C K4ˆ~ÿÿ@Dc I K,T¨~ÿÿÙe ŽŒ†ƒ D ,„X€ÿÿÙe ŽŒ†ƒ D ,´‚ÿÿÙe ŽŒ†ƒ D ,七ÿÿ e ŽŒ†ƒ/ D ¸xÿÿ&D,€…ÿÿBAƒL sAL°…ÿÿBAƒL sAlà…ÿÿBAƒL sAŒ†ÿÿBAƒL sA<¬@†ÿÿéBBŒG †D(ƒG`¸ (A ABBA ìð†ÿÿŽHƒX P  `‡ÿÿCDn A ,‡ÿÿCD` D J A LÀ‡ÿÿ;Dn A là‡ÿÿ;Df A ŒˆÿÿRDa K Q A ¬@ˆÿÿ3Df A Ì`ˆÿÿBDm A ìˆÿÿVDk A U A  Јÿÿ:Dm A ,ðˆÿÿCDn A L ‰ÿÿbDo E Y A lp‰ÿÿ;Dn A <Œ‰ÿÿéBBŒG †D(ƒG`¸ (A ABBA <Ì@ŠÿÿàBBŒG †D(ƒG`° (A ABBA < àŠÿÿàBBŒG †D(ƒG`° (A ABBA $L€‹ÿÿ®M†ƒI ŒM M $tŒÿÿ®M†ƒI ŒM M $œŒÿÿÆM†ƒI0Œ\ N $Ä8ÿÿ®M†ƒI ŒQ I ìÀÿÿL¸ÿÿªBSŽB B(ŒA0†A8ƒG°æ 8A0A(B BBBF T©ÿÿ:DP D ]t8©ÿÿ$Œptÿÿ5A†FƒF cCA´©ÿÿA†C A Ôæ¨ÿÿA†C A ǫ̂ÿÿA†C A  ²¨ÿÿA†C A 4 ˜¨ÿÿ´A†C ¯ T ,©ÿÿÉA†C Ä t Õ©ÿÿÖA†C Ñ ” ‹ªÿÿÝA†C Ø ´ H«ÿÿ)A†C d Ô Q«ÿÿ)A†C d ô Z«ÿÿ)A†C d  c«ÿÿ>A†C y 4 «ÿÿ)A†C d T Š«ÿÿ#A†C ^ t «ÿÿA†C K ” €«ÿÿA†C A ´ f«ÿÿA†C A Ô L«ÿÿA†C A ô 2«ÿÿA†C A  «ÿÿ´A†C ¯ 4 ¬«ÿÿÉA†C Ä T U¬ÿÿÖA†C Ñ t ­ÿÿÝA†C Ø ” È­ÿÿ-A†C h ´ Õ­ÿÿA†C K Ô È­ÿÿ¢D™ì `®ÿÿ h®ÿÿ p®ÿÿ4 h®ÿÿ DL `®ÿÿAƒd h®ÿÿ2DH A „ ˆ®ÿÿ2DH A ¤ ¨®ÿÿD¼  ®ÿÿ&DÔ ¸®ÿÿì À®ÿÿ È®ÿÿ Юÿÿ4 Ø®ÿÿMD] G `T ¯ÿÿl ¯ÿÿ„ ¯ÿÿœ ¯ÿÿ´ (¯ÿÿÌ 0¯ÿÿ4ä (¯ÿÿ]BBŒD †D(ƒG0C(A ABBLP¯ÿÿüBEŒD †A(ƒF0ˆ (D ABBE J(D ABBl°ÿÿ4„ø¯ÿÿ¢A†GƒJ j AAB N KAF ¼p°ÿÿ'G \Ôˆ°ÿÿ<AƒR eCô¨°ÿÿ   °ÿÿ $˜°ÿÿ <°ÿÿ Tˆ°ÿÿ l€°ÿÿ5G m„¨°ÿÿ=G uœаÿÿD Z´ذÿÿD VÌà°ÿÿPN †ƒA$ì±ÿÿ†S Œ†ƒG F x±ÿÿPN †ƒA$4¨±ÿÿ†S Œ†ƒH E \²ÿÿAƒY$|²ÿÿ•S Œƒ†K B ¤ˆ²ÿÿAƒYtĈ²ÿÿ¿BŽDB ŒA(†A0ƒW (A EBBE Ç (A EBBG Z (A EBBD f (A EBBA <гÿÿ0DN F S\à³ÿÿtسÿÿRŒ ´ÿÿU¤h´ÿÿZ¼°´ÿÿÔ¸´ÿÿìÀ´ÿÿÈ´ÿÿ4дÿÿíBŒJ†D ƒ³ ABJ YAB,Tˆµÿÿ–A†DƒD q DAA „øµÿÿœ¶ÿÿ´¶ÿÿ̶ÿÿä¶ÿÿü¶ÿÿ¶ÿÿ,¶ÿÿ AƒIà$L¶ÿÿÖGàZ G Z F $tH·ÿÿ¼MƒM†ŽLPŒp J œà·ÿÿGà‡¼P¸ÿÿ>D Y C ]Üp¸ÿÿ”GàŒüð¸ÿÿè¸ÿÿ,ð¸ÿÿDø¸ÿÿ\¹ÿÿt¹ÿÿŒ¹ÿÿ'Aƒe¬ ¹ÿÿ'Aƒe<Ì0¹ÿÿWBŽEB ŒA(†A0ƒD(A BBB P¹ÿÿÄGàŸ J S,ºÿÿ@Dc I KL ºÿÿ@Dc I K<l@ºÿÿ{BŽEB ŒA(†D0ƒb(A BEBD¬€ºÿÿBBŽE B(ŒA0†D8ƒK@f8D0A(B BBB4ôȺÿÿ“BŒD†D ƒs ABA NAB4,0»ÿÿNBEŒA †C(ƒD0x(A ABBdH»ÿÿ!,|`»ÿÿ1BŒD†A ƒfAB¬p»ÿÿ Äh»ÿÿ Ü`»ÿÿ@Dc I Kü€»ÿÿ@Dc I K »ÿÿ4¨»ÿÿL°»ÿÿ-$dÈ»ÿÿwMŒƒI †} E $Œ ¼ÿÿ\HŒQ†ƒI0y´X¼ÿÿAƒQ$ÔX¼ÿÿ@A†AƒD wAA$üp¼ÿÿ@A†AƒD wAA$ˆ¼ÿÿ<¼ÿÿ$T˜¼ÿÿ{M†ƒ[@ŽŒR$|ð¼ÿÿ~M†ƒMŒMŽD@R¤H½ÿÿ¼@½ÿÿ$Ô8½ÿÿfM†ƒV0ŽŒB$ü€½ÿÿ{M†ƒMŒN@ŽR$ؽÿÿ<à½ÿÿ,Tè½ÿÿÆH†RŒŽƒI0g F q„ˆ¾ÿÿœ¾ÿÿ´˜¾ÿÿ7D0rÌÀ¾ÿÿ举ÿÿüÀ¾ÿÿ¸¾ÿÿ ,À¾ÿÿ DȾÿÿ\оÿÿtȾÿÿŒоÿÿ¤Ⱦÿÿ$¼À¾ÿÿH†_`ŽŒƒeä(¿ÿÿü0¿ÿÿ8¿ÿÿID0D,p¿ÿÿ5D`pD˜¿ÿÿ5D`p\À¿ÿÿt¸¿ÿÿŒ°¿ÿÿ¤¸¿ÿÿ¼°¿ÿÿÔ¸¿ÿÿ ì°¿ÿÿ ¨¿ÿÿ°¿ÿÿ4¸¿ÿÿLÀ¿ÿÿdÈ¿ÿÿ|пÿÿ”Ø¿ÿÿ¬à¿ÿÿpÄ8ÀÿÿDÜpÀÿÿ(ôˆÀÿÿ(  Àÿÿ $˜Àÿÿ <ÀÿÿT˜Àÿÿl Àÿÿ„¨Àÿÿœ°Àÿÿ´¸ÀÿÿÌÀÀÿÿäÈÀÿÿ„ü@Áÿÿ 8Áÿÿ$,0ÁÿÿfHŽRŒ†ƒI0B$TxÁÿÿ{HRŒ†ƒN@ŽR$|ÐÁÿÿ~HRŒ†ƒN@ŽU¤(Âÿÿ1¼PÂÿÿgDPF N GÜ Âÿÿ`DP} O HLüàÂÿÿÇBBŽE E(ŒD0†A8ƒD€¥8A0A(B BBBL`Ãÿÿgd¸ÃÿÿFd|ðÃÿÿªBBŽB E(ŒA0†D8ƒGØ 8A0A(B BBBG Ÿ8A0A(B BBBLä8ÅÿÿþBBŽB B(ŒD0†A8ƒJÀ 8A0A(B BBBF 4 èÆÿÿUL 0Çÿÿ¢D@s I al ÀÇÿÿ0DN F SŒ ÐÇÿÿ¤ ÈÇÿÿ¼ ÐÇÿÿÄÔ ˆÊÿÿõ$ì pÍÿÿ‰QŒ†_@ƒŽX!ØÍÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ À@ èƒ@õþÿo˜@ @Ø@ J è¿`Øè @  @H þÿÿoP @ÿÿÿoðÿÿoê @@¾`ö@@@&@6@F@V@f@v@†@–@¦@¶@Æ@Ö@æ@ö@@@&@6@F@V@f@v@†@–@¦@¶@Æ@Ö@æ@ö@@@&@6@F@V@f@v@pÁ`2í„@Á`(…@°Á`…@ÐÁ`4…@ðÁ` F…@ð?€?GCC: (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3.symtab.strtab.shstrtab.interp.note.ABI-tag.note.gnu.build-id.gnu.hash.dynsym.dynstr.gnu.version.gnu.version_r.rela.dyn.rela.plt.init.text.fini.rodata.eh_frame_hdr.eh_frame.ctors.dtors.jcr.dynamic.got.got.plt.data.bss.comment8@8#T@T 1t@t$Döÿÿo˜@˜@N Ø@ØÈV @ J^ÿÿÿoê @ê fkþÿÿoP @P Pz  @  H„è @è Ø ŽÀ@À‰à@à ”€@€hršèƒ@胠„@„0¨0Œ@0Œ|¶°”@°”,!À¾`¾Ç(¾`(¾Î8¾`8¾Ó@¾`@¾ Üà¿`à¿áè¿`è¿`êPÁ`PÁØð0Â`(Â(õ0(Â*RÂþÐÊH-Ç øF8@T@t@˜@Ø@ @ê @P @   @ è @ À@ à@ €@èƒ@„@0Œ@°”@¾`(¾`8¾`@¾`à¿`è¿`PÁ`0Â` @ñÿ¾`*(¾`88¾`E 0@[@Â`jHÂ`x  @ñÿ„ ¾`‘ص@Ÿ8¾`« °ƒ@ÁñÿÐ 0@Ø P@à p@è @ð °@ø Ð@ ð@ @ 0@@/ p@@O °@Ùd @Ùy p@ÙŽ P@ £ €@&¿ `@Bð °)@® °@B3 €'@®H @Bx 0(@® P@B¿ à(@ÆÔ  @éê @Ž !@C# p!@C8 À!@;> "@;S @"@Rh  "@3n à"@Bƒ 0#@V˜ #@:ž Ð#@C³ $@bÈ $@;Î Ð$@éã À%@àù  &@àXÂ`Zñÿhñÿu hF@Œ nF@£ tF@º zF@Ñ`Â`á €F@´ô 4G@É ýG@Ö ÓH@Ý+hÂ`>pÂ`†ñÿu ÈJ@Œ ÎJ@£ ÔJ@º ÚJ@ÑxÂ`á àJ@´ô ”K@É ]L@Ö 3M@Ý+€Â`™ˆÂ`çñÿ7ŒÂ`}ñÿÆÂ`ñÿO”Â`ñÿÙ Q@å 0Q@ñ PQ@þ pQ@  Q@ °Q@, ÀQ@]4 °U@†H V@†\ @W@•p X@¿„˜Â`Çñÿ œÂ`P ñÿš  Â`Ý ñÿ$ ¤Â`d ñÿ® ¨Â`ñ ñÿ:  °]@H ¬Â`Š ñÿÖ °Â` ñÿf ´Â`ª ñÿó  Pb@'  €b@'  °b@W c@Ä. ¸Â`p ñÿ¸ ¼Â`ù ñÿAÄÂ`‚ñÿÐÈÂ`ñÿ^ÐÂ` ñÿçÔÂ`'ñÿsØÂ`¶ñÿÿ ðm@äÂ`Tñÿž o@I¸ìÂ`ûñÿDðÂ`†ñÿÏôÂ`ñÿ[øÂ`žñÿçüÂ`)ñÿpÃ`°ñÿöÃ`5ñÿ{Ã`ºñÿ Ã`Fñÿ‘Ã`ÔñÿÃ`_ñÿªÃ`îñÿ9 ðs@ M t@a v@ÇmÃ`±ñÿö Ã`4¾`E@¾`N¾`aè¿`w @)—  ƒ@§Æ Ðy@þ ’J@#T €O@2b @ƒ 0]@¹Ë Àu@g °a@Ok pg@£ `r@ Þ g@0Â`* @s@b Àm@› PÁ`¦ Àl@á,Ã`! ð@0 \@–G €p@ }@³ €[@ì Àh@' ð@D €u@1„ €r@º Ð{@U ðk@Æ5 q@m  a@¬ `U@Pó r@(.  @q@pC  `h@\` èÂ`«  Àp@ä  0g@@!! @6/!ñÿ(Â`6!$Ã`l! `*@z! Ða@µ! O@ñ! Ðo@."B" Po@5‡" àd@§" P@&º"PÂ`Ò" pr@ ## À@%#èƒ@+#?#Á`Y# àr@Ž#š# }@Ô# S@$ @V@PW$m$ ðY@¦$ Àn@Þ$ 0|@¢)%ÀÁ`;% d@@x% ðf@@µ%Â% p]@û%Â`& Ðf@ R&  @^& €P@”& À]@Ì& @}@ÄÕ& àn@ 'ÀÂ`Z' àT@=›' ^@Ö°' ð]@ Ã' N@-( Àr@<( ào@y(Œ(  j@ª( f@NÀ( Á`Ø(ì( q@$) o@5o)0Ã`­)ðÁ`Ã) °I@)*!* p_@¼6* ÀZ@Zv*‚*0¾`*¢*Â`·* `d@{Ó* °q@Dè* 0b@"+A+ €m@ w+ƒ+€Á`š+®+PÁ`»+4Ã`ø+ Pm@0, `[@i, Pp@ ¨, U@ð,ü, T@ - j@~:-F- pm@~- Àj@f¢- ±- n@Ñ-  r@. PO@ . @P@H. Ð@d.XÁ`q. à@Š. s@Â. @Ü.ï.8Ã`// `s@„i/`Á`/„@Ž/ 0n@¬/<Ã`é/ b@#0 ða@h0 P]@ž0 @®0  p@ç0 p@ 1 €i@W1 0k@{|1ˆ1 €@õ‘1 s@Ê1 `@)ä1 Ðw@F)252J2  m@ €2Œ2 T@<Ì2 i@@â2 ƒ@‰ò23 pT@ 3 PT@ 43H3ÌÂ`’3 @³3 Â`Ë3 Ðk@4 àp@4 @$4ñÿXÃ`)4>4 F@:~4 è@…4Â`š4 PN@¢ª4 x@ªù4 @p@ 85 µJ@v5  T@5·5$Ã`Ç5 0S@¢6 t@f(6E6 ÀO@2Z6 0@-x6…6š6ñÿ(Â`¦6²6ÐÁ`Ç6 P@Ñ6 °@5Ö6 `F@7 f@1[7 à]@“7@Ã`Ó7 a@”ä7  [@íú78 °g@-8DÃ`Y8 ]@’8 m@7Õ8(Ã` 9HÃ`J9 àl@…9 `O@•9 `T@ ¬9hÁ`Ä9 ðo@ý9 @: @m@V:j: àg@w‚: €T@ š: ®:  P@ä:ú: ÀY@03; °k@j; 0v@`³; n@ö;Â` < 0`@I<LÃ`‡< @U@Ó< @à< €t@{= `P@== àm@v= R@üµ= 0r@(ð= ÙI@)9>E>PÃ`ƒ>pÁ`ž> àc@@Û> iJ@)$? O@`?r? `w@g»? `f@!Ñ? Z@R@ W@Y@m@ˆ@ àh@@ž@ +J@>ñ@àÂ`CAàÁ`VA `@6dAÜÂ` A pe@“¸A À`@>ÈA ÀP@MÛA p@B °j@TB =N@˜B°Á`³B à|@0íB u@~C àf@ QCTÃ`ŽC @O@œC `Z@UÛC `p@D à@0D @[@gD À@mD °@6|D Ð@ŒD  i@{³D¿D àS@'×D `i@E-E [@dE J@)­E8Â`ÁE àW@ F p*@ªcall_gmon_startcrtstuff.c__CTOR_LIST____DTOR_LIST____JCR_LIST____do_global_dtors_auxcompleted.6531dtor_idx.6533frame_dummy__CTOR_END____FRAME_END____JCR_END____do_global_ctors_auxtest_lu_dats.capp_205app_209app_230app_234app_255app_259app_280app_284print_elt_02162_ats_float_typeprint_elt_02162_ats_double_typeloop1_211_0loop2_212loop1_236_0loop2_237loop1_261_0loop2_262loop1_286_0loop2_287atspre_int1_of_size1.part.0print_matrix_02646_ats_dcomplex_type.constprop.5__ats_fun_282_clofunprint_matrix_02646_ats_float_type.constprop.7__ats_fun_207_clofunprint_matrix_02646_ats_double_type.constprop.12__ats_fun_232_clofunprint_matrix_02646_ats_fcomplex_type.constprop.20__ats_fun_257_clofunloop_251.constprop.21cblas_gemm_overlap_check_136.part.1__ats_fun_203_clofun__ats_fun_219_clofunf_220__ats_fun_228_clofun__ats_fun_244_clofunf_245__ats_fun_253_clofun__ats_fun_269_clofunf_270__ats_fun_278_clofun__ats_fun_294_clofunf_295loop_301.constprop.6loop_226.constprop.10loop_276.constprop.16ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload_flag.16754ats_prelude.ccblas_dats.catspre_stdout_view_getatspre_stdout_view_setatspre_stderr_view_getatspre_stderr_view_setatspre_null_ptratspre_fprintf_erratspre_fprintf_exnatspre_printf_exnatspre_prerrf_exnatspre_stropt_noneATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_2edats__staload_flag.9064cblas_extra_dats.cATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_extra_2edats__staload_flag.9035_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fats_5fmain_5fprelude_2edats.cATS_2d0_2e2_2e10_2prelude_2ats_main_prelude_2edats__staload_flag.7933_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fbasics_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2basics_2edats__staload_flag.7911_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fbool_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2bool_2edats__staload_flag.7886_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2ffilebas_2edats.c__ats_fun_7__ats_fun_9__ats_fun_11__ats_fun_13__ats_fun_15__ats_fun_29_clofunloop_18__ats_fun_22_clofun__ats_fun_24_clofun__ats_fun_26_clofun__ats_fun_30_clofunATS_2d0_2e2_2e10_2prelude_2DATS_2filebas_2edats__staload_flag.9022_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2ffloat_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2float_2edats__staload_flag.8014_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2finteger_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2integer_2edats__staload_flag.7901_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2flazy_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2lazy_2edats__staload_flag.7901_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fpointer_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2pointer_2edats__staload_flag.7894_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fprintf_2edats.catslib_va_endATS_2d0_2e2_2e10_2prelude_2DATS_2printf_2edats__staload_flag.7932_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2freference_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2reference_2edats__staload_flag.7898_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fsizetype_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2sizetype_2edats__staload_flag.7913_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fstring_2edats.catspre_char_toupperatspre_char_tolowerstring_make_fun_19ATS_2d0_2e2_2e10_2prelude_2DATS_2string_2edats__staload_flag.8308_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2farith_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2arith_2edats__staload_flag.7886_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2farray_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2array_2edats__staload_flag.8129_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2farray_5fprf_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2array_prf_2edats__staload_flag.7886_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2farray0_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2array0_2edats__staload_flag.7965_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2flist_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2list_2edats__staload_flag.7912_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2flist_5fvt_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2list_vt_2edats__staload_flag.8892_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fmatrix_2edats.c__ats_fun_5_clofunATS_2d0_2e2_2e10_2prelude_2DATS_2matrix_2edats__staload_flag.8033_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fmatrix0_2edats.cref_01033_anairiats_rec_1ATS_2d0_2e2_2e10_2prelude_2DATS_2matrix0_2edats__staload_flag.7998_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fSATS_2fnumber_2esats.cATS_2d0_2e2_2e10_2prelude_2SATS_2number_2esats__staload_flag.2675_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2foption_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2option_2edats__staload_flag.7908_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2foption0_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2option0_2edats__staload_flag.7886_2fhome_2fhwxi_2fresearch_2fAnairiats_2fprelude_2fDATS_2fptrarr_2edats.cATS_2d0_2e2_2e10_2prelude_2DATS_2ptrarr_2edats__staload_flag.7894_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fDATS_2fcomplex_2edats.cATS_2d0_2e2_2e10_2libc_2DATS_2complex_2edats__staload_flag.8431_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fSATS_2fstdarg_2esats.cATS_2d0_2e2_2e10_2libc_2SATS_2stdarg_2esats__staload_flag.2696_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fSATS_2fstdlib_2esats.cATS_2d0_2e2_2e10_2libc_2SATS_2stdlib_2esats__staload_flag.4219_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fsys_2fSATS_2fstat_2esats.cATS_2d0_2e2_2e10_2libc_2sys_2SATS_2stat_2esats__staload_flag.3163_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fsys_2fSATS_2ftypes_2esats.cATS_2d0_2e2_2e10_2libc_2sys_2SATS_2types_2esats__staload_flag.2999_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibats_2fSATS_2ffmatrix_2esats.cATS_2d0_2e2_2e10_2libats_2SATS_2fmatrix_2esats__staload_flag.2684_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibats_2fSATS_2fgenarrays_2esats.cATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staload_flag.2686_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibats_2fDATS_2fgenarrays_2edats.c__ats_fun_17_clofun__ats_fun_19_clofunloop_row_11ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__staload_flag.8882_2fhome_2fhwxi_2fresearch_2fAnairiats_2flibc_2fSATS_2ffcntl_2esats.cATS_2d0_2e2_2e10_2libc_2SATS_2fcntl_2esats__staload_flag.3756__init_array_end_DYNAMIC__init_array_start_GLOBAL_OFFSET_TABLE_ats_funarg_match_failure_handle__libc_csu_fini__ctype_toupper_loc@@GLIBC_2.3ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_iforeach_funenv_tszATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_2edats__staloadatspre_assertats_gc_chunk_count_limit_max_getATS_2d0_2e2_2e10_2prelude_2DATS_2lazy_2edats__staloadfree@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split1x2_tszATS_2d0_2e2_2e10_2prelude_2DATS_2reference_2edats__staload__vfprintf_chk@@GLIBC_2.3.4ATS_2d0_2e2_2e10_2prelude_2DATS_2string_2edats__staloadATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_zcmplxATS_2d0_2e2_2e10_2prelude_2DATS_2string_2edats__dynloadstdout@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2libats_2SATS_2fmatrix_2esats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2list_vt_2edats__staloaddata_startATS_2d0_2e2_2e10_2prelude_2DATS_2array_prf_2edats__staloadATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRANSPOSE_T_1ats_malloc_ngcatspre_tostrptr_ullintATS_2d0_2e2_2e10_2prelude_2DATS_2option_2edats__dynloadATS_2d0_2e2_2e10_2libc_2SATS_2fcntl_2esats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2integer_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__strptr_dupats_gc_chunk_count_limit_setATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__MATVECINC_getATS_2d0_2e2_2e10_2libc_2DATS_2complex_2edats__staloadATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__TRMAT_U_ptr_split2x2_tszcblas_saxpyatspre_array_ptr_initialize_elt_tszATS_2d0_2e2_2e10_2prelude_2DATS_2ptrarr_2edats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2reference_2esats__ref_app_funATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__char_stream_make_fileATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__print_ccmplxatslib_fprint_ccmplxatspre_string_make_substringATS_2d0_2e2_2e10_2prelude_2basics_sta_2esats__sasp__matrix0_viewt0ype_typeATS_2d0_2e2_2e10_2prelude_2DATS_2option0_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__prerr_strptrats_malloc_gc_edataATS_2d0_2e2_2e10_2prelude_2DATS_2list_2edats__lcons_0__matrix_freeATS_2d0_2e2_2e10_2prelude_2DATS_2reference_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2ats_main_prelude_2edats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2matrix0_2esats__matrix0_rowfclose@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2SATS_2matrix0_2esats__matrix0_make_arrpszatspre_string_make_list_rev_intatspre_assertfalsethe_ats_exception_stackATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__prerr_zcmplxcblas_daxpyats_gc_init_finistrlen@@GLIBC_2.2.5ListSubscriptExceptionConATS_2d0_2e2_2e10_2libc_2SATS_2stdlib_2esats__staloadcblas_cgemmATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__input_lineATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__line_stream_make_file__lxstat@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2DATS_2filebas_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2DATS_2matrix_2edats__staloadATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__TRMAT_L_ptr_split2x2_tszOverflowExceptionATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__prerr_strbufATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__print_strptrcblas_scnrm2ATS_2d0_2e2_2e10_2prelude_2DATS_2pointer_2edats__staloadatslib_zcmplx_imag_unitATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__string_tolowerats_free_gcATS_2d0_2e2_2e10_2prelude_2DATS_2bool_2edats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2printf_2edats__staload__divsc3ATS_2d0_2e2_2e10_2prelude_2DATS_2matrix_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2basics_sta_2esats__sasp__array_viewt0ype_int_typeATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__test_file_islnkatspre_assert_prerrfatspre_exit_prerrfATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_extra_2edats__staloadATS_2d0_2e2_2e10_2libc_2SATS_2stdarg_2esats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2matrix0_2esats__matrix0_colfputs@@GLIBC_2.2.5atspre_array_ptr_takeout2_tszatspre_string_explodeDivisionByZeroExceptionmemset@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2DATS_2ptrarr_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2matrix0_2esats__matrix0_make_arrpsz__mainATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__UPLOupper_0AssertionExceptionConATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_ORDER_of_ORDERfgetc@@GLIBC_2.2.5atspre_vsprintf_sizeATS_2d0_2e2_2e10_2prelude_2SATS_2float_2esats__pow_ldouble_int1cblas_dgemm__DTOR_END__fputc@@GLIBC_2.2.5ats_stderr_view_lockatspre_string_make_list_intatslib_fprint_zcmplxATS_2d0_2e2_2e10_2prelude_2DATS_2sizetype_2edats__dynload__libc_start_main@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2DATS_2list_2edats__staloadcblas_ztrmmListSubscriptExceptioncalloc@@GLIBC_2.2.5__data_startATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SIDEleft_0ATS_2d0_2e2_2e10_2prelude_2DATS_2array0_2edats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2integer_2edats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2option_2esats__option_is_someATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__char_list_vt_make_filecblas_zgemmatspre_test_file_isregatspre_array_ptr_initialize_cloenv_tszcblas_snrm2ATS_2d0_2e2_2e10_2prelude_2DATS_2array0_2edats__dynloadatspre_array_ptr_foreach_funenv_tsz__gmon_start__atspre_matrix_make_arrpsz__mainATS_2d0_2e2_2e10_2libc_2DATS_2complex_2edats__dynloadats_exitATS_2d0_2e2_2e10_2prelude_2DATS_2basics_2edats__staloadListSubscriptException_make__dso_handleisListSubscriptExceptionATS_2d0_2e2_2e10_2libc_2sys_2SATS_2stat_2esats__staloadisArraySubscriptExceptionmemcpy@@GLIBC_2.14ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRANSPOSE_C_2ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__staloadats_exception_con_tag_IO_stdin_usedatspre_matrix_make_funenv_tszATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERcol_1ATS_2d0_2e2_2e10_2prelude_2DATS_2sizetype_2edats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2sizetype_2esats__divmod_size1_size1ATS_2d0_2e2_2e10_2prelude_2DATS_2lazy_2edats__dynloadats_realloc_ngcATS_2d0_2e2_2e10_2prelude_2DATS_2option0_2edats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2matrix0_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2DATS_2arith_2edats__dynloadatspre_array_ptr_iforeach_funenv_tszcblas_ctrmm__divdc3ATS_2d0_2e2_2e10_2libc_2sys_2SATS_2types_2esats__staloadats_caseof_failure_handleATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_copy_tszcblas_strmm__xstat@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2DATS_2list_2edats__dynloadcblas_zaxpyATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__test_file_modeatspre_strbuf_toupper__libc_csu_initmalloc@@GLIBC_2.2.5atspre_test_file_isdiratspre_test_file_isblkfflush@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2basics_sta_2esats__sasp__array0_viewt0ype_typeats_gc_chunk_count_limit_max_setatslib_ccmplx_imag_unitATS_2d0_2e2_2e10_2prelude_2DATS_2array_2edats__dynloadatspre_ptrarr_sizeats_calloc_ngc_endvprintf@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__staload_startats_stdout_view_lockmainats_preludeATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__GEMAT_ptr_foreach_funenv_tszATS_2d0_2e2_2e10_2prelude_2SATS_2option_2esats__option_is_noneATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__test_file_isempats_empty_valueATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__output_lineatslib_GEVEC_ptr_foreach_funenv_tsz__vsnprintf_chk@@GLIBC_2.3.4atspre_assert_errmsgats_uncaught_exception_handlecblas_dznrm2realloc@@GLIBC_2.2.5__bss_startcblas_dtrmmOverflowExceptionConats_crashmainATS_2d0_2e2_2e10_2contrib_2cblas_2TEST_2test_lu_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__string_foreach__mainATS_2d0_2e2_2e10_2prelude_2DATS_2printf_2edats__dynloadATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__DIAGnonunit_1atspre_tostringfatspre_tostrptr_llintcblas_dnrm2atspre_string_hash_33ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__ORDERrow_0ATS_2d0_2e2_2e10_2prelude_2DATS_2pointer_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2array0_2esats__array0_make_arrpszATS_2d0_2e2_2e10_2prelude_2DATS_2list_2edats__lnil_1ATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__TRANSPOSE_N_0ATS_2d0_2e2_2e10_2prelude_2DATS_2array_prf_2edats__dynloadats_exit_errmsgatspre_test_file_ischrArraySubscriptExceptionATS_2d0_2e2_2e10_2prelude_2DATS_2matrix0_2edats__staloadArraySubscriptException_makeATS_2d0_2e2_2e10_2prelude_2SATS_2array0_2esats__array0_sizeperror@@GLIBC_2.2.5atspre_string_make_charatspre_test_file_isfifo_Jv_RegisterClassesATS_2d0_2e2_2e10_2prelude_2DATS_2bool_2edats__dynloadvfprintf@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2DATS_2filebas_2edats__staloadATS_2d0_2e2_2e10_2prelude_2DATS_2array_2edats__staloadATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x1_tszATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__matrix_make_arrpszats_stdin_view_lockATS_2d0_2e2_2e10_2prelude_2SATS_2printf_2esats__tostringf_sizeATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__SIDEright_1ATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__char_list_vt_make_file_lenats_free_ngcatslib_GEVEC_ptr_iforeach_funenv_tszATS_2d0_2e2_2e10_2prelude_2DATS_2basics_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2DATS_2list_vt_2edats__dynloadATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__input_line_vtATS_2d0_2e2_2e10_2libc_2SATS_2complex_2esats__prerr_ccmplxATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_UPLO_of_UPLOcblas_caxpyATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__UPLOlower_1ArraySubscriptExceptionConATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__print_strbufATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_SIDE_of_SIDEATS_2d0_2e2_2e10_2prelude_2ats_main_prelude_2edats__dynloadexit@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__GEMAT_ptr_split2x2_tszatspre_string_implodeATS_2d0_2e2_2e10_2prelude_2SATS_2float_2esats__pow_float_int1ATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__char_stream_vt_make_filefwrite@@GLIBC_2.2.5__fprintf_chk@@GLIBC_2.3.4atspre_strbuf_tolowerATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_TRANSPOSE_of_TRANSPOSEATS_2d0_2e2_2e10_2prelude_2basics_sta_2esats__sasp__matrix_viewt0ype_int_int_typeAssertionExceptionats_calloc_gcATS_2d0_2e2_2e10_2prelude_2SATS_2matrix_2esats__sasp__mtrxtatspre_stringlst_concatatspre_vsprintfatspre_fprint_boolATS_2d0_2e2_2e10_2prelude_2SATS_2number_2esats__staloadATS_2d0_2e2_2e10_2prelude_2SATS_2array_2esats__array_make_arrpszATS_2d0_2e2_2e10_2contrib_2cblas_2DATS_2cblas_extra_2edats__dynloadDivisionByZeroExceptionConATS_2d0_2e2_2e10_2libats_2DATS_2genarrays_2edats__staloadatslib_GEVEC_ptr_iforeach_cloenv_tszATS_2d0_2e2_2e10_2prelude_2SATS_2string_2esats__string_toupperATS_2d0_2e2_2e10_2libats_2SATS_2genarrays_2esats__DIAGunit_0ats_crash_intATS_2d0_2e2_2e10_2prelude_2SATS_2float_2esats__pow_double_int1ATS_2d0_2e2_2e10_2prelude_2DATS_2option_2edats__staloadats_gc_chunk_count_limit_getATS_2d0_2e2_2e10_2prelude_2DATS_2float_2edats__dynload_initats_realloc_gcats_gc_markrootatspre_array_ptr_initialize_funenv_tszcblas_sgemmatspre_test_file_existsATS_2d0_2e2_2e10_2prelude_2DATS_2arith_2edats__staload__ctype_tolower_loc@@GLIBC_2.3ATS_2d0_2e2_2e10_2prelude_2DATS_2float_2edats__staloadATS_2d0_2e2_2e10_2contrib_2cblas_2SATS_2cblas_2esats__CBLAS_DIAG_of_DIAGstderr@@GLIBC_2.2.5ATS_2d0_2e2_2e10_2prelude_2SATS_2filebas_2esats__line_stream_vt_make_filemainatsats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_lu.dats0000664000175000017500000004701512223166164021645 0ustar hwxihwxi// // some testing code for the ATS interface to BLAS // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ** The code is translated from the C version written by ** Shivkumar Chandrasekaran that is attached at the end ** of the file. *) (* ****** ****** *) local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/matrix.dats" (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) extern fun{a:t@ype} lu {n:nat} {ord:order} {lda:pos} (n: int n, A: &GEMAT (a, n, n, ord, lda), ord: ORDER ord, lda: size_t lda):<> void // end of [lu] (* ****** ****** *) extern fun{a:t@ype} of_double (x: double):<> a implement of_double (x) = float_of_double (x) implement of_double (x) = x implement of_double (x) = ccmplx_of_float (float_of_double x) implement of_double (x) = zcmplx_of_double (x) (* ****** ****** *) extern fun{a:t@ype} print_elt (x: a): void implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x (* ****** ****** *) extern fun{a1,a2:t@ype} abs (x: a2):<> a1 implement abs (x) = abs_float (x) implement abs (x) = abs_double (x) implement abs (x) = abs_ccmplx (x) implement abs (x) = abs_zcmplx (x) (* ****** ****** *) extern fun{a:t@ype} add (x1: a, x2: a):<> a implement add (x1, x2) = x1 + x2 implement add (x1, x2) = x1 + x2 implement add (x1, x2) = x1 + x2 implement add (x1, x2) = x1 + x2 extern fun{a:t@ype} sub (x1: a, x2: a):<> a implement sub (x1, x2) = x1 - x2 implement sub (x1, x2) = x1 - x2 implement sub (x1, x2) = x1 - x2 implement sub (x1, x2) = x1 - x2 extern fun{a:t@ype} mul (x1: a, x2: a):<> a implement mul (x1, x2) = x1 * x2 implement mul (x1, x2) = x1 * x2 implement mul (x1, x2) = x1 * x2 implement mul (x1, x2) = x1 * x2 extern fun{a:t@ype} div (x1: a, x2: a):<> a implement div (x1, x2) = x1 / x2 implement div (x1, x2) = x1 / x2 implement div (x1, x2) = x1 / x2 implement div (x1, x2) = x1 / x2 (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) extern fun{a:t@ype} gemaxpy {ordA,ordB:order} {m,n:nat} {lda,ldb:pos} ( OrderA: ORDER (ordA) , OrderB: ORDER (ordB) , M: size_t m, N: size_t n , alpha: a , A: &GEMAT (a, m, n, ordA, lda), lda: size_t lda , B: &GEMAT (a, m, n, ordB, ldb), ldb: size_t ldb ) :<> void // end of [gemaxpy] implement{a} gemaxpy {ordA,ordB} {m,n} {lda,ldb} (OrderA, OrderB, M, N, alpha, A, lda, B, ldb) = let fun loop {m,n:nat} .. ( M: size_t m, N: size_t n , A: &GEMAT (a, m, n, ordA, lda) , B: &GEMAT (a, m, n, ordB, ldb) ) : void = if N > 0 then let val (pfA1, pfA2, fpfA | pA1, pA2) = GEMAT_ptr_split1x2 (view@ A | OrderA, &A, lda, 1) val (pfB1, pfB2, fpfB | pB1, pB2) = GEMAT_ptr_split1x2 (view@ B | OrderB, &B, ldb, 1) prval (pfA1_inc, pfA1_V, fpfA1) = GEVEC_v_of_GEMAT_v_col {a} (pfA1) val dA = MATVECINC_get (pfA1_inc | ORDERcol, OrderA, lda) val dA = int1_of_size1 dA prval (pfB1_inc, pfB1_V, fpfB1) = GEVEC_v_of_GEMAT_v_col {a} (pfB1) val dB = MATVECINC_get (pfB1_inc | ORDERcol, OrderB, ldb) val dB = int1_of_size1 dB val M_i = int1_of_size1 M val () = cblas_axpy (M_i, alpha, !pA1, dA, !pB1, dB) prval () = pfA1 := fpfA1 (pfA1_V) prval () = pfB1 := fpfB1 (pfB1_V) val () = loop (M, N-1, !pA2, !pB2) prval () = view@ A := fpfA (pfA1, pfA2) prval () = view@ B := fpfB (pfB1, pfB2) in // empty end // end of [if] in loop (M, N, A, B) end // end of [gemaxpy] (* ****** ****** *) extern fun{a1,a2:t@ype} gemnrm2 {ordA:order} {m,n:nat} {lda:pos} ( OrderA: ORDER (ordA) , M: size_t m, N: size_t n , A: &GEMAT (a2, m, n, ordA, lda), lda: size_t lda ) :<> a1 implement{a1,a2} gemnrm2 {ordA} {m,n} {lda} (OrderA, M, N, A, lda) = let fun loop {m,n:nat} .. ( M: size_t m, N: size_t n, A: &GEMAT (a2, m, n, col, lda), res: a1 ) : a1 = if N > 0 then let val (pfA1, pfA2, fpfA | pA1, pA2) = GEMAT_ptr_split1x2 (view@ A | ORDERcol, &A, lda, 1) prval (pfA1_inc, pfA1_V, fpfA1) = GEVEC_v_of_GEMAT_v_col (pfA1) prval MATVECINCcolcol () = pfA1_inc val M_i = int1_of_size1 M val res1 = cblas_nrm2 (M_i, !pA1, 1) prval () = pfA1 := fpfA1 (pfA1_V) val res = loop (M, N-1, !pA2, res \add res1) prval () = view@ A := fpfA (pfA1, pfA2) in res // loop exits end else begin res // loop exits end (* end of [if] *) in case+ OrderA of | ORDERrow () => res where { prval TRANORDrowcol () = GEMAT_v_trans (view@ A) val res = loop (N, M, A, of_double (0.0)) prval TRANORDcolrow () = GEMAT_v_trans (view@ A) } // end of [ORDERrow] | ORDERcol () => loop (M, N, A, of_double (0.0)) end // end of [gemnrm2] (* ****** ****** *) implement{a} lu {n} {ord} {lda} (n, A, ord, lda) = loop (view@ A | n, &A) where { fun loop {n:nat} {l:addr} .. (pf_mat: !GEMAT_v (a, n, n, ord, lda, l) | n: int n, p_mat: ptr l) : void = if n >= 2 then let val (pf11, pf12, pf21, pf22, fpf | p11, p12, p21, p22) = GEMAT_ptr_split2x2 (pf_mat | ord, p_mat, lda, 1, 1) // end of [val] // val _0 = size1_of_int1 0 val A_0_0 = GEMAT_ptr_get_elt_at (ord, !p11, lda, _0, _0) val n1 = n - 1 // var i: size_t // uninitialized val () = for* {i:nat | i < n} .. (i: size_t i) => (i := _0; i < n1; i := i+1) let val (pf, fpf | p) = GEMAT_ptr_takeout (pf21 | ord, p21, lda, i, _0) // end of [val] val () = !p := (!p \div A_0_0) prval () = pf21 := fpf (pf) in // nothing end // end of [val] // val lda_i = int1_of_size1 lda // val cbord = CBLAS_ORDER_of_ORDER (ord) val alpha: a = of_double (~1.0) and beta: a = of_double (1.0) val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | cbord , CblasNoTrans , CblasNoTrans , n1, n1, 1 , alpha , !p21, lda_i , !p12, lda_i , beta , !p22, lda_i ) // end of [val] // val () = loop (pf22 | n1, p22) prval () = pf_mat := fpf (pf11, pf12, pf21, pf22) in // nothing end // end of [if] // end of [loop] } // end of [lu] (* ****** ****** *) fn{a:t@ype} print_matrix {m,n:nat} ( M: matrix (a, m, n), m: int m, n: int n ) : void = let val pr = lam (i: size_t, j: size_t, x: &a): void = let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // empty end // end of [val] val () = matrix_iforeach_cloref (M, pr, size1_of_int1 m, size1_of_int1 n) in // empty end // end of [print_matrix] (* ****** ****** *) %{^ ats_void_type __matrix_free (ats_ptr_type A) { ATS_FREE (A); return ; } %} // end of [%{^] (* ****** ****** *) fun{a1,a2:t@ype} test {N:nat | N >= 1} (N: int N): void = () where { // prval pf = unit_v () val A = matrix_make_vclo (pf | N, N, !p_clo) where { val N = size1_of_int1 (N) var !p_clo = @lam ( pf: !unit_v | i: size_t, j: size_t, x: &(a2?) >> a2 ) : void = let val i = int_of_size i and j = int_of_size j in x := of_double (double_of (min (i, j) + 2)) end (* end of [var] *) } prval unit_v () = pf val (pf_A | p_A) = __cast (A) where { extern castfn __cast {nr,nc:nat} (_: matrix (a2, nr, nc)): [l:addr] (GEMAT (a2, nr, nc, row, nc) @ l | ptr l) } // end of [val] // val () = if (N <= 10) then begin print "A =\n"; print_matrix (A, N, N); print_newline () end // end of [val] val () = lu (N, !p_A, ORDERrow, i2sz N) // LU factorization val () = if (N <= 10) then begin print "L\U =\n"; print_matrix (A, N, N); print_newline () end // end of [val] // (* var res: a1 = of_double (0.0) var i: int? and j: int? and k: int? // // upper part // val () = for* (i: natLte N) => (i := 0; i < N; i := i + 1) let val () = for* (i: natLt N, j: natLte N) => (j := i; j < N; j := j + 1) let var tmp: a2 = of_double (0.0) val () = for* (i: natLt N, j: natLt N, k: natLte N) => (k := 0; k < i; k := k + 1) let val () = tmp := add (tmp, mul (A[i,N,k], A[k,N,j])) in // nothing end // end of [val] val () = tmp := add (tmp, A[i,N,j]) val x = of_double (double_of (min(i,j) + 2)) val () = res := add (res, abs (tmp \sub x)) in // nothing end // end of [val] in // nothing end // end of [val] // // lower part // val () = for* (j: natLte N) => (j := 0; j < N-1; j := j+1) let val () = for* (i: natLte N, j: natLt (N-1)) => (i := j+1; i < N; i := i + 1) let var tmp: a2 = of_double (0.0) val () = for* (i: natLt N, j: natLt (N-1), k: natLte N) => (k := 0; k <= j; k := k + 1) let val () = tmp := add (tmp, A[i,N,k] \mul A[k,N,j]) in // nothing end // end of [val] val x = of_double (double_of (min(i,j) + 2)) val () = res := add (res, abs (tmp \sub x)) in // nothing end // end of [val] in // nothing end // end of [val] val () = (print_matrix (A, N, N); print_newline ()) *) // prval pf = unit_v () // [A1] is a *unit* matrix val A1 = matrix_make_vclo (pf | N, N, !p_clo) where { val N = size1_of_int1 (N) var !p_clo = @lam ( pf: !unit_v | i: size_t, j: size_t, x: &(a2?) >> a2 ) : void = let val i = int_of_size i and j = int_of_size j in if i = j then x := of_double (1.0) else x := of_double (0.0) end (* end of [var] *) } prval unit_v () = pf val (pf_A1 | p_A1) = __cast (A1) where { extern castfn __cast {nr,nc:nat} (_: matrix (a2, nr, nc)): [l:addr] (GEMAT (a2, nr, nc, row, nc) @ l | ptr l) } // end of [val] // prval (pf_A_up_u, fpf_A) = TRMAT_v_of_GEMAT_v (pf_A, UPLOupper, DIAGnonunit) val () = cblas_trmm ( SIDEDIM_R | CblasRowMajor , CblasRight , CblasUpper , CblasNoTrans , CblasNonUnit , N, N , of_double (1.0) , !p_A, N , !p_A1, N ) prval () = (pf_A := fpf_A (pf_A_up_u)) val () = if (N <= 10) then begin print "U =\n"; print_matrix (A1, N, N); print_newline () end // end of [val] // prval (pf_A_lo_nu, fpf_A) = TRMAT_v_of_GEMAT_v (pf_A, UPLOlower, DIAGunit) val () = cblas_trmm ( SIDEDIM_L | CblasRowMajor , CblasLeft , CblasLower , CblasNoTrans , CblasUnit , N, N , of_double (1.0) , !p_A, N , !p_A1, N ) prval () = (pf_A := fpf_A (pf_A_lo_nu)) val () = if (N <= 10) then begin print "A =\n"; print_matrix (A1, N, N); print_newline () end // end of [val] // val () = matrix_iforeach_fun (A, f, N, N) where { val N = size1_of_int1 (N) fn f ( i: sizeLt N, j: sizeLt N, x: &a2 ) :<> void = let val i = int_of_size i and j = int_of_size j in x := of_double (double_of (min (i, j) + 2)) end // end of [f] } // end of [val] // local // in val N = size1_of_int1 N val () = gemaxpy (ORDERrow, ORDERrow, N, N, of_double (~1.0), !p_A, N, !p_A1, N) // end of [val] val res = gemnrm2 (ORDERrow, N, N, !p_A1, N) end // end of [local] val () = () where { extern castfn __cast {nr,nc:nat} {l:addr} (_: GEMAT (a2, nr, nc, row, nc) @ l | _: ptr l): ptr l val _ = __cast (pf_A | p_A) and _ = __cast (pf_A1 | p_A1) } // end of [val] // val () = () where { extern fun __matrix_free // a hack!!! (A: matrix (a2, N, N)): void = "__matrix_free" // end of [extern fun] val () = __matrix_free (A) and () = __matrix_free (A1) } val () = begin print "size = "; print N; print " and error = "; print_elt res; print_newline () end // end of [val] } // end of [test] (* ****** ****** *) (* // HX: no longer needed dynload "libc/DATS/complex.dats" dynload "libats/DATS/genarrays.dats" *) (* ****** ****** *) implement main () = let #define N 10 // val () = (print "test:"; print_newline ()) val () = test (N) val () = (print "================================================"; print_newline ()) // val () = (print "test:"; print_newline ()) val () = test (N) val () = (print "================================================"; print_newline ()) // val () = (print "test:"; print_newline ()) val () = test (N) val () = (print "================================================"; print_newline ()) // val () = (print "test:"; print_newline ()) val () = test (N) val () = (print "================================================"; print_newline ()) // in // nothing end // end of [main] (* ****** ****** *) (* end of [test_lu.dats] *) //// /* File: my_lu.c Author: Shivkumar Chandrasekaran Purpose: Mimic in ATS for testing CBLAS interface Compile: gcc -O3 my_lu.c -L/usr/local/atlas/lib -lcblas -latlas or: gcc -O3 my_lu.c -L/usr/local/atlas/lib -lpthread -lptcblas -latlas Output: If "./a.out 100" works correctly output should be double: size = 100, error = 0.000000, time = 0 seconds float: ... $Id: my_lu.c,v 1.3 2009/06/20 23:31:25 shiv Exp shiv $ */ #include #include #include #include #include "/usr/local/atlas/include/cblas.h" /* real lu */ #define lu(type, stype) \ void lu_ ## stype (int n, int lda, type a[]) { \ \ if (n <= 1) return; \ \ /* a[1:n-1;0] = a[1:n-1;0] / a[0,0] */ \ { \ int i; \ for (i = 1; i < n; i++) a[i*lda] /= a[0]; \ }; \ \ /* a[1:n-1, 1:n-1] -= a[1:n-1,0] * a[0,1:n-1] / a[0,0] */ \ cblas_ ## stype ## gemm ( \ CblasRowMajor, CblasNoTrans, CblasNoTrans, \ n-1, n-1, 1, -1, a+lda, lda, a+1, lda, \ 1, a+lda+1, lda); \ \ lu_ ## stype (n-1, lda, a+lda+1); \ return; \ } /* complex lu */ #define luc(type, stype) \ void lu_ ## stype (int n, int lda, type a[]) { \ \ static type one = 1+0I; \ static type minus_one = -1+0I; \ \ if (n <= 1) return; \ \ /* a[1:n-1;0] = a[1:n-1;0] / a[0,0] */ \ { \ int i; \ for (i = 1; i < n; i++) a[i*lda] /= a[0]; \ }; \ \ /* a[1:n-1, 1:n-1] -= a[1:n-1,0] * a[0,1:n-1] / a[0,0] */ \ cblas_ ## stype ## gemm ( \ CblasRowMajor, CblasNoTrans, CblasNoTrans, \ n-1, n-1, 1, &minus_one, a+lda, lda, \ a+1, lda, &one, a+lda+1, lda); \ \ lu_ ## stype (n-1, lda, a+lda+1); \ return; \ } lu(double, d) lu(float, s) luc(double complex, z) luc(float complex, c) inline int min (int i, int j) { if (i < j) return i; else return j; } #define test(type, stype) \ void test_ ## stype (int n) { \ \ type a[n][n]; \ clock_t cl; \ \ /* a[i][j] = min(i,j) + 1 */ \ { \ int i, j; \ for (i = 0; i < n; i++) \ for (j = i; j < n; j++) \ a[i][j] = a[j][i] = i+1; \ }; \ \ cl = clock (); \ lu_ ## stype (n, n, (type *) a); \ cl = clock () - cl; \ \ /* a = l * u */ \ { \ int i, j, k; \ type tmp; \ double res = 0; \ \ /* upper part */ \ for (i = 0; i < n; i++) \ for (j = i; j < n; j++) { \ tmp = 0; \ for (k = 0; k < i; k++) tmp += a[i][k] * a[k][j]; \ tmp += a[i][j]; \ res += abs (tmp - min(i,j) - 1); \ }; \ /* lower part */ \ for (j = 0; j < n-1; j++) \ for (i = j+1; i < n; i++) { \ tmp = 0; \ for (k = 0; k <= j; k++) tmp += a[i][k] * a[k][j]; \ res += abs (tmp - min(i,j) - 1); \ }; \ \ printf (#type ": size = %i, error = %f, time = %i seconds\n", \ n, res, cl / CLOCKS_PER_SEC); \ }; \ \ return; \ } test(double, d) test(float, s) test(double complex, z) test(float complex, c) int main (int argc, char *argv[]) { int n = atoi (argv[1]); if (argc > 1) { test_d (n); test_s (n); test_z (n); test_c (n); } else printf ("Please specify matrix dimension; for example: %s 1000\n", argv[0]); return 0; } ats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_symm.dats0000664000175000017500000000723212223166164022207 0ustar hwxihwxi// // some testing code for the ATS interface to BLAS // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/matrix.dats" (* ****** ****** *) staload "libc/SATS/complex.sats" staload "libats/SATS/genarrays.sats" (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) extern fun{a:t@ype} mul_gemat_symat {m,n:pos} ( m: int m, n: int n , A: matrix (a, m, n), B: matrix (a, n, n), C: matrix (a, m, n) ) : void // end of [mul_gemat_symat] (* ****** ****** *) extern fun{a:t@ype} of_double (x: double):<> a implement of_double (x: double) = float_of_double (x) implement of_double (x: double) = x implement of_double (x) = ccmplx_of_float (float_of_double x) implement of_double (x) = zcmplx_of_double (x) (* ****** ****** *) extern fun{a:t@ype} print_elt (x: a): void implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x (* ****** ****** *) implement{a} mul_gemat_symat (m, n, A, B, C) = let extern castfn __cast {nr,nc:nat} (_: matrix (a, nr, nc)): [l:addr] (GEMAT (a, nr, nc, row, nc) @ l | ptr l) val (pf_A | p_A) = __cast (A) val (pf_B | p_B) = __cast (B) val (pf_C | p_C) = __cast (C) extern castfn __cast {nr,nc:nat} {l:addr} (_: GEMAT (a, nr, nc, row, nc) @ l | _: ptr l): ptr l val alpha: a = of_double (1.0) and beta: a = of_double (0.0) prval (pf_B_up, fpf_B) = SYMAT_v_of_GEMAT_v (pf_B, UPLOupper) val () = cblas_symm ( SIDEDIM_R | CblasRowMajor , CblasRight // side , CblasUpper // uplo , m, n , alpha , !p_B, n , !p_A, n , beta , !p_C, n ) prval () = pf_B := fpf_B (pf_B_up) val _ = __cast (pf_A | p_A) val _ = __cast (pf_B | p_B) val _ = __cast (pf_C | p_C) in // nothing end // end of [mul_gemat_symat] (* ****** ****** *) fn{a:t@ype} print_matrix {m,n:nat} ( M: matrix (a, m, n), m: int m, n: int n ) : void = let val pr = lam (i: size_t, j: size_t, x: &a): void = let val _0 = size_of_int1 0 val () = if j > _0 then print ", " val () = if (i > _0 andalso j = _0) then print "\n" val () = print_elt (x) in // empty end // end of [val] val () = matrix_iforeach_cloref (M, pr, size1_of_int1 m, size1_of_int1 n) in // empty end // end of [print_matrix] (* ****** ****** *) typedef elt = double (* ****** ****** *) prval pf = unit_v () val M1 = matrix_make_vclo (pf | 10, 10, !p_clo) where { var !p_clo = @lam ( pf: !unit_v | i: size_t, j: size_t, x: &(elt?) >> elt ) : void = let val i = int_of_size i and j = int_of_size j in x := of_double (double_of_int (1 + min (i, j))) // x := zcmplx_make_cart (double_of i, double_of j) end (* end of [var] *) } prval unit_v () = pf val () = print "M1=\n" val () = print_matrix (M1, 10, 10) val () = print_newline () (* ****** ****** *) prval pf = unit_v () val M2 = matrix_make_vclo (pf | 10, 10, !p_clo) where { var !p_clo = @lam ( pf: !unit_v | i: size_t, j: size_t, x: &(elt?) >> elt ) : void = let in x := of_double (0.0) end (* end of [var] *) } prval unit_v () = pf val () = print "M2=\n" val () = print_matrix (M2, 10, 10) val () = print_newline () val () = mul_gemat_symat (10, 10, M1, M1, M2) val () = print "M2=\n" val () = print_matrix (M2, 10, 10) val () = print_newline () (* ****** ****** *) implement main () = () (* ****** ****** *) (* end of [symm_test.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_cblas.dats0000664000175000017500000032344712223166164022317 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) local #include "prelude/HATS/number.hats" in (*empty*) end local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end (* ****** ****** *) staload M = "libc/SATS/math.sats" macdef M_PI = $M.M_PI staload C = "libc/SATS/complex.sats" typedef ccmplx = $C.ccmplx typedef zcmplx = $C.zcmplx (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) staload NUM = "prelude/SATS/number.sats" macdef sin = $NUM.sin macdef cos = $NUM.cos (* ****** ****** *) fn{a:t@ype} of_int (x):<> a = $NUM.of_int (x) fn{a:t@ype} of_double (x):<> a = $NUM.of_double (x) fn{a:t@ype} print_typ (): void = $NUM.print_typ () fn{a:t@ype} print_elt (x: a): void = $NUM.print_elt (x) (* ****** ****** *) #define sz2i int1_of_size1 #define i2sz size1_of_int1 (* ****** ****** *) local fn{a:t@ype} macheps_get ():<> a = let val one = of_double 1.0 val two = of_double 2.0 fun guess (x: a): a = if $NUM.eq (one, one \$NUM.add x) then x else guess (x \$NUM.div two) // end of [if] (* end of [guess] *) in $effmask_ntm (guess one) end // end of [machine_eps] in // in of [local] val macheps_float = macheps_get () val macheps_double = macheps_get () end // end of [local] (* ****** ****** *) extern fun{a:t@ype} isEpsilon (x: a): bool val epsilon_double = 0.001 val epsilon_float = float_of (0.001) implement isEpsilon (x) = abs x <= epsilon_float implement isEpsilon (x) = abs x <= epsilon_double implement isEpsilon (x) = $C.abs_ccmplx x <= epsilon_float implement isEpsilon (x) = $C.abs_zcmplx x <= epsilon_double (* // // this is too strict for some of the tests to pass // implement isEpsilon (x) = abs x <= macheps_float implement isEpsilon (x) = abs x <= macheps_double implement isEpsilon (x) = abs_ccmplx x <= macheps_float implement isEpsilon (x) = abs_zcmplx x <= macheps_double *) (* ****** ****** *) fn srandgen_elt (): float = let val x = drand48 () in float_of_double (x) end // end of [srandgen_elt] fn drandgen_elt (): double = drand48 () fn crandgen_elt (): ccmplx = $C.ccmplx_make_cart (x, y) where { val x = drand48 () and y = drand48 () val x = float_of_double x and y = float_of_double y } // end of [crandgen_elt] fn zrandgen_elt (): zcmplx = let val x = drand48 () and y = drand48 () in $C.zcmplx_make_cart (x, y) end // end of [zrandgen_elt] extern fun{a:t@ype} randgen_elt (): a implement randgen_elt () = srandgen_elt () implement randgen_elt () = drandgen_elt () implement randgen_elt () = crandgen_elt () implement randgen_elt () = zrandgen_elt () (* ****** ****** *) fun{a:t@ype} randgen_arr {n:nat} .<>. (n: int n) : [l:addr] ( free_gc_v (a?, n, l), array_v (a, n, l) | ptr l ) = let val tsz = sizeof val n_sz = size1_of_int1 (n) val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (n_sz, tsz) // end of [val] val () = array_ptr_initialize_fun (!p_arr, n_sz, f) where { val f = lam ( _: sizeLt n , x: &(a?) >> a ) : void = x := randgen_elt () // end of [val] } // end of [val] in (pf_gc, pf_arr | p_arr) end // end of [rangen_arr] (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" (* ****** ****** *) staload "libats/SATS/fmatrix.sats" staload _(*anonymous*) = "libats/DATS/fmatrix.dats" fun{a:t@ype} randgen_fmat {m,n:nat} (m: int m, n: int n) : [mn:int] [l:addr] ( free_gc_v (a?, mn, l) , MUL (m, n, mn) , fmatrix_v (a, m, n, l) | ptr l ) = let val (pf_mn | mn) = m imul2 n prval () = mul_nat_nat_nat (pf_mn) val (pf_gc, pf_arr | p_arr) = randgen_arr (mn) prval pf_fmat = fmatrix_v_of_array_v (pf_mn, pf_arr) in (pf_gc, pf_mn, pf_fmat | p_arr) end // end of [randgen_fmat] (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) // BLAS level 1 (* ****** ****** *) extern fun{a:t@ype} rotg_test () : void implement{t} rotg_test (): void = () where { var a = of_double 1.0 var b = of_double 1.0 var c : t var s : t val () = cblas_rotg (a, b, c, s) val () = begin print "rotg_test<"; print_typ (); print ">"; print ": a = "; print_elt a; print ", b = "; print_elt b; print ", c = "; print_elt c; print ", s = "; print_elt s; print_newline () end // end of [val] } // end of [rotg_test] (* ****** ****** *) extern fun{a:t@ype} rot_test () : void implement{a} rot_test () : void = () where { #define M 17 #define N 19 val (pf_MN | MN) = M imul2 N prval () = mul_nat_nat_nat (pf_MN) // val tsz = sizeof // val (pfA_gc, pfA_arr | pA_arr) = randgen_arr (MN) prval pfA_fmat = fmatrix_v_of_array_v {a} (pf_MN, pfA_arr) prval (pfA_gem, fpfA_fmat) = GEMAT_v_of_fmatrix_v {a} (pfA_fmat) val (pfA11_gem, pfA21_gem, fpfA_gem| pA11_arr, pA21_arr) = GEMAT_ptr_split2x1 (pfA_gem | ORDERcol, pA_arr, M, 1) // end of [val] prval (pfX_incX, pfX_gev, fpfA11_gem) = GEVEC_v_of_GEMAT_v_row (pfA11_gem) // end of [val] val incX = MATVECINC_get (pfX_incX | ORDERrow, ORDERcol, M) val incX = sz2i incX prval (pfY_incY, pfY_gev, fpfA21_gem) = GEMAT_v_uncons_row {a} (pfA21_gem) val incY = MATVECINC_get (pfY_incY | ORDERrow, ORDERcol, M) val incY = sz2i incY val N_sz = size1_of_int1 (N) val (pfX2_gc, pfX2_arr | pX2_arr) = array_ptr_alloc_tsz {a} (N_sz, tsz) var zero: a = of_double (0.0) val () = array_ptr_initialize_elt_tsz {a} (!pX2_arr, N_sz, zero, tsz) prval pfX2_gev = GEVEC_v_of_array_v {a} (pfX2_arr) val () = cblas_copy (N, !pA11_arr, incX, !pX2_arr, 1) val (pfY2_gc, pfY2_arr | pY2_arr) = array_ptr_alloc_tsz {a} (N_sz, tsz) val () = array_ptr_initialize_elt_tsz {a} (!pY2_arr, N_sz, zero, tsz) prval pfY2_gev = GEVEC_v_of_array_v {a} (pfY2_arr) val () = cblas_copy (N, !pA21_arr, incY, !pY2_arr, 1) // val theta: double = cos (M_PI / 6.0) val c = of_double (cos theta) val s = of_double (sin theta) val () = cblas_rot (N, !pA11_arr, incX, !pA21_arr, incY, c, s) val ci = of_double (cos (~theta)) val si = of_double (sin (~theta)) val () = cblas_rot (N, !pA11_arr, incX, !pA21_arr, incY, ci, si) val neg1 = of_double (~1.0) val () = cblas_axpy (N, neg1, !pA11_arr, incX, !pX2_arr, 1) val () = cblas_axpy (N, neg1, !pA21_arr, incY, !pY2_arr, 1) val Xnrm2 = cblas_nrm2 (N, !pX2_arr, 1) val Ynrm2 = cblas_nrm2 (N, !pY2_arr, 1) // val () = begin print "rot_test<"; print_typ (); print ">"; print ": starts ... " end // end of [val] (* val () = begin print_newline (); print ": Xnrm2 = "; print_elt Xnrm2; print ", Ynrm2 = "; print_elt Ynrm2; print_newline () end // end of [val] *) val () = assert (isEpsilon (Xnrm2 \$NUM.div (of_int N))) val () = assert (isEpsilon (Ynrm2 \$NUM.div (of_int N))) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pfY2_arr := array_v_of_GEVEC_v (pfY2_gev) val () = array_ptr_free (pfY2_gc, pfY2_arr | pY2_arr) prval () = pfX2_arr := array_v_of_GEVEC_v (pfX2_gev) val () = array_ptr_free (pfX2_gc, pfX2_arr | pX2_arr) prval () = pfA21_gem := fpfA21_gem (pfY_gev) prval () = pfA11_gem := fpfA11_gem (pfX_gev) prval () = pfA_gem := fpfA_gem (pfA11_gem, pfA21_gem) prval () = pfA_fmat := fpfA_fmat (pfA_gem) prval (pfA_MN, pfA_arr) = array_v_of_fmatrix_v (pfA_fmat) prval () = mul_isfun (pf_MN, pfA_MN) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [rot_test] (* ****** ****** *) extern fun{a:t@ype} rotm_test (): void implement{a} rotm_test (): void = () where { #define M 7 #define N 100 val (pf_MN | MN) = M imul2 N prval () = mul_nat_nat_nat (pf_MN) // val tsz = sizeof // val (pfA_gc, pfA_arr | pA_arr) = randgen_arr (MN) prval pfA_fmat = fmatrix_v_of_array_v {a} (pf_MN, pfA_arr) prval (pfA_gem, fpfA_fmat) = GEMAT_v_of_fmatrix_v (pfA_fmat) prval (pfX_inc, pfX_gev, fpfA_gem) = GEMAT_v_uncons_row (pfA_gem) val incX = MATVECINC_get (pfX_inc | ORDERrow, ORDERcol, M) // val (pfB_gc, pfB_arr | pB_arr) = randgen_arr (MN) prval pfB_fmat = fmatrix_v_of_array_v {a} (pf_MN, pfB_arr) prval (pfB_gem, fpfB_fmat) = GEMAT_v_of_fmatrix_v (pfB_fmat) prval (pfY_inc, pfY_gev, fpfB_gem) = GEMAT_v_uncons_row (pfB_gem) val incY = MATVECINC_get (pfY_inc | ORDERrow, ORDERcol, M) // var neg1: a = of_double (~1.0) val (pfP_gc, pfP_arr | pP_arr) = array_ptr_alloc_tsz {a} (5, tsz) val () = array_ptr_initialize_elt_tsz {a} (!pP_arr, 5, neg1, tsz) prval pfP_gev = GEVEC_v_of_array_v {a} (pfP_arr) // val _0 = size1_of_int1 0 var d1 = of_double (1.0) var d2 = of_double (1.0) var b1 = GEVEC_ptr_get_elt_at (!pA_arr, incX, _0) var b2 = GEVEC_ptr_get_elt_at (!pB_arr, incY, _0) val () = cblas_rotmg (d1, d2, b1, b2, !pP_arr) val () = cblas_rotm (N, !pA_arr, sz2i incX, !pB_arr, sz2i incY, !pP_arr) // val () = assert ( isEpsilon (GEVEC_ptr_get_elt_at (!pB_arr, incY, _0) \$NUM.div (of_int N)) ) // end of [val] val () = begin print "rotm_test<"; print_typ (); print ">"; print ": Y[0] = "; print_elt (GEVEC_ptr_get_elt_at (!pB_arr, incY, _0)); print_newline () end // end of [val] // prval () = pfP_arr := array_v_of_GEVEC_v (pfP_gev) val () = array_ptr_free (pfP_gc, pfP_arr | pP_arr) // prval () = pfB_gem := fpfB_gem (pfY_gev) prval () = pfB_fmat := fpfB_fmat (pfB_gem) prval (pfB_MN, pfB_arr) = array_v_of_fmatrix_v (pfB_fmat) prval () = mul_isfun (pf_MN, pfB_MN) val () = array_ptr_free (pfB_gc, pfB_arr | pB_arr) // prval () = pfA_gem := fpfA_gem (pfX_gev) prval () = pfA_fmat := fpfA_fmat (pfA_gem) prval (pfA_MN, pfA_arr) = array_v_of_fmatrix_v (pfA_fmat) prval () = mul_isfun (pf_MN, pfA_MN) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [rotm_test] (* ****** ****** *) extern fun{a1,a2:t@ype} asum_test (): void implement{a,ar} // ar = |a| asum_test (): void = () where { #define M 7 #define N 100 val (pf_MN | MN) = M imul2 N prval () = mul_nat_nat_nat (pf_MN) // val tsz = sizeof // val MN_sz = size1_of_int1 MN val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (MN_sz, tsz) var one: a = of_int (1) val () = array_ptr_initialize_elt_tsz {a} (!p_arr, MN_sz, one, tsz) prval (pf_fmat) = fmatrix_v_of_array_v {a} (pf_MN, pf_arr) prval (pf_gmat, fpf_fmat) = GEMAT_v_of_fmatrix_v {a} (pf_fmat) prval (pf_inc, pf_gev, fpf_gmat) = GEMAT_v_uncons_col {a} (pf_gmat) val inc = MATVECINC_get (pf_inc | ORDERcol, ORDERcol, M) // val nrm1 = cblas_asum (M, !p_arr, sz2i inc) val () = begin print "asum_test<"; print_typ (); print ">"; print ": starts ... "; end // end of [val] (* val () = begin print ": nrm1 = "; print_elt nrm1; print_newline () end // end of [val] *) val () = assert (isEpsilon (nrm1 \$NUM.sub (of_int M))) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pf_gmat := fpf_gmat (pf_gev) prval () = pf_fmat := fpf_fmat (pf_gmat) prval (pf1_MN, pf_arr) = array_v_of_fmatrix_v (pf_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf_gc, pf_arr | p_arr) } // end of [asum_test] (* ****** ****** *) extern fun{a:t@ype} iamax_test (): void implement{a} iamax_test (): void = () where { #define M 7 #define N 10 val (pf_MN | MN) = M imul2 N prval () = mul_nat_nat_nat (pf_MN) // val tsz = sizeof // val MN_sz = size1_of_int1 (MN) val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (MN_sz, tsz) prval pf_fmat = fmatrix_v_of_array_v {a?} (pf_MN, pf_arr) prval pf = unit_v val () = fmatrix_ptr_initialize_vclo {unit_v} (pf | !p_arr, M, N, !p_f) where { var !p_f = @lam ( pf_v : !unit_v | x : &(a?) >> a, i : sizeLt M, j : sizeLt N ) : void = x := of_int (sz2i j - sz2i i) // end of [var !p_f] } // end of [val] prval unit_v () = pf prval (pf_gem, fpf_fmat) = GEMAT_v_of_fmatrix_v (pf_fmat) #define M1 2 val (pf_gem1, pf_gem2, fpf_gem | p_arr1, p_arr2) = GEMAT_ptr_split2x1 (pf_gem | ORDERcol, p_arr, M, M1) prval (pf_inc1, pf_gev1, fpf_gem2) = GEMAT_v_uncons_row {a} (pf_gem2) val inc1 = MATVECINC_get (pf_inc1 | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val indx = cblas_iamax (N, !p_arr2, inc1) val () = begin print "iamax_test<"; print_typ (); print">"; print ": starts ... "; end // end of [val] (* val () = begin print_newline (); print ": max_index = "; print indx; print_newline () end // end of [val] *) val () = assert (indx = (if M1 < N/2 then N-1 else 0)) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pf_gem2 := fpf_gem2 (pf_gev1) prval () = pf_gem := fpf_gem (pf_gem1, pf_gem2) prval () = pf_fmat := fpf_fmat (pf_gem) prval (pf1_MN, pf_arr) = array_v_of_fmatrix_v (pf_fmat) prval () = mul_isfun (pf1_MN, pf_MN) val () = array_ptr_free (pf_gc, pf_arr | p_arr) } // end of [iamax_test] (* ****** ****** *) extern fun{a:t@ype} dot_test (): void implement{a} dot_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val res_X_Y = cblas_dot (N, !p1_arr, inc1, !p2_arr, inc2) val () = begin print "dot_test<"; print_typ (); print ">"; print (": starts ... ") end // end of [val] val res_Y_X = cblas_dot (N, !p1_arr, inc1, !p2_arr, inc2) val () = assert (isEpsilon ((res_X_Y \$NUM.sub res_Y_X) \$NUM.div (of_int N))) (* end pf [val] *) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [dot_test] (* ****** ****** *) extern fun{a:t@ype} dotu_test (): void implement{a} dotu_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val () = begin print "dotu_test<"; print_typ (); print ">"; print (": starts ... ") end // end of [val] val res_X_Y = cblas_dotu (N, !p1_arr, inc1, !p2_arr, inc2) val res_Y_X = cblas_dotu (N, !p1_arr, inc1, !p2_arr, inc2) val () = assert (isEpsilon ((res_X_Y \$NUM.sub res_Y_X) \$NUM.div (of_int N))) (* end pf [val] *) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [dotu_test] (* ****** ****** *) extern fun{a:t@ype} dotc_test (): void implement{a} dotc_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val () = begin print "dotc_test<"; print_typ (); print ">"; print (": starts ... ") end // end of [val] val res_X_Y = cblas_dotc (N, !p1_arr, inc1, !p2_arr, inc2) val res_Y_X = cblas_dotc (N, !p1_arr, inc1, !p2_arr, inc2) val () = assert (isEpsilon ((res_X_Y \$NUM.sub res_Y_X) \$NUM.div (of_int N))) (* end pf [val] *) val () = begin print ("finishes"); print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [dotc_test] (* ****** ****** *) extern fun{a,ar:t@ype} swap_test (): void implement{a,ar} // ar = |a| swap_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) prval (pf3_inc, pf3_gev, fpf3_gem) = GEMAT_v_uncons_row (pf3_gem) // inc3 = M val inc3 = MATVECINC_get (pf3_inc | ORDERrow, ORDERcol, M) val inc3 = sz2i inc3 // val () = begin print "swap_test<"; print_typ (); print ">"; print ": starts ... " end // end of [val] val neg1 = of_double (~1.0) val () = cblas_copy (N, !p1_arr, inc1, !p2_arr, inc2) val () = cblas_swap (N, !p1_arr, inc1, !p3_arr, inc3) val () = cblas_axpy (N, neg1, !p2_arr, inc2, !p3_arr, inc3) val diff = cblas_nrm2 (N, !p3_arr, inc3) val () = assert (isEpsilon (diff \$NUM.div (of_int N))) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_gem := fpf3_gem (pf3_gev) prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [swap_test] (* ****** ****** *) extern fun{a,ar:t@ype} copy_test (): void implement{a,ar} // ar = |a| copy_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val () = begin print "copy_test<"; print_typ (); print ">"; print (": starts ... ") end // end of [val] val X_nrm2 = cblas_nrm2 (N, !p1_arr, inc1) val () = cblas_copy (N, !p1_arr, inc1, !p2_arr, inc2) val Y_nrm2 = cblas_nrm2 (N, !p2_arr, inc2) val () = assert (isEpsilon ((X_nrm2 \$NUM.sub Y_nrm2) \$NUM.div (of_int N))) (* end of [val] *) // val () = begin print ("finishes"); print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [copy_test] (* ****** ****** *) extern fun{a,ar:t@ype} axpy_test (): void implement{a,ar} // ar = |a| axpy_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val () = begin print "axpy_test<"; print_typ (); print ">"; print (": starts ... ") end // end of [val] val X1_nrm2 = cblas_nrm2 (N, !p1_arr, inc1) val Y1_nrm2 = cblas_nrm2 (N, !p2_arr, inc2) val zero = of_double ( 0.0) val pos1 = of_double ( 1.0) val neg1 = of_double (~1.0) val () = cblas_axpy (N, neg1, !p1_arr, inc1, !p2_arr, inc2) // Y <- Y - X // Y = Y0 - X0 val () = cblas_axpy (N, pos1, !p2_arr, inc2, !p1_arr, inc1) // X <- X + Y // X = Y0 val () = cblas_axpy (N, neg1, !p1_arr, inc1, !p2_arr, inc2) // Y <- Y - X // Y = -X0 val X2_nrm2 = cblas_nrm2 (N, !p1_arr, inc1) val Y2_nrm2 = cblas_nrm2 (N, !p2_arr, inc2) val () = assert (isEpsilon ((X1_nrm2 \$NUM.sub Y2_nrm2) \$NUM.div (of_int N))) val () = assert (isEpsilon ((Y1_nrm2 \$NUM.sub X2_nrm2) \$NUM.div (of_int N))) val () = begin print ("finishes"); print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [axpy_test] (* ****** ****** *) extern fun{a,a2,ar:t@ype} scal_test (): void implement{a,a2,ar} // ar = |a| scal_test (): void = () where { #define M 7 // needs to be a positive number #define N 100 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) // val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_inc, pf1_gev, fpf1_gem) = GEMAT_v_uncons_row (pf1_gem) // inc1 = M val inc1 = MATVECINC_get (pf1_inc | ORDERrow, ORDERcol, M) val inc1 = sz2i inc1 // val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (MN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_row (pf2_gem) // inc2 = M val inc2 = MATVECINC_get (pf2_inc | ORDERrow, ORDERcol, M) val inc2 = sz2i inc2 // val () = begin print "scal_test<"; print_typ (); print ","; print_typ (); print ">"; print (": starts ... ") end // end of [val] val X1_nrm2 = cblas_nrm2 (N, !p1_arr, inc1) (* val () = begin print "X_nrm2 = "; print_elt (X1_nrm2); print_newline () end // end of [val] *) val neg1 = of_double (~1.0) val () = cblas_scal (N, neg1, !p1_arr, inc1) // X <- ~X val X2_nrm2 = cblas_nrm2 (N, !p1_arr, inc1) (* val () = begin print "X_nrm2 = "; print_elt (X2_nrm2); print_newline () end // end of [val] *) val () = assert (isEpsilon ((X1_nrm2 \$NUM.sub X2_nrm2) \$NUM.div (of_int N))) // end of [val] val () = begin print ("finishes"); print_newline () end // end of [val] // prval () = pf1_gem := fpf1_gem (pf1_gev) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_MN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_MN, pf2_MN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [scal_test] (* ****** ****** *) // BLAS level 2 (* ****** ****** *) extern fun{a,ar:t@ype} gemv_test (): void // // relate gemv to gemm // implement{a,ar} // ar = |a| gemv_test (): void = () where { #define M 19 // needs to be a positive number #define K 100 // needs to be a positive number #define N 1 // needs to be a positive number // val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, K , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] // prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_col (pf2_gem) // inc2 = 1 val inc2 = MATVECINC_get (pf2_inc | ORDERcol, ORDERcol, K) val inc2 = sz2i inc2 prval (pf3_inc, pf3_gev, fpf3_gem) = GEMAT_v_uncons_col (pf3_gem) // inc3 = 1 val inc3 = MATVECINC_get (pf3_inc | ORDERcol, ORDERcol, M) val inc3 = sz2i inc3 // val () = cblas_gemv ( TRANDIM_N | CblasColMajor , CblasNoTrans , M, K , pos1 (* alpha *) , !p1_arr, M , !p2_arr, inc2 , neg1 (* beta *) , !p3_arr, inc3 ) // end of [val] // val diff = cblas_nrm2 (M, !p3_arr, inc3) val () = begin print "gemv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_gem := fpf3_gem (pf3_gev) prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [gemv_test] (* ****** ****** *) extern fun{a,ar:t@ype} gbmv_test (): void implement{a,ar} // ar = |a| gbmv_test (): void = () where { #define M 100 #define K 70 #define KU 5 #define KL 7 #define R (1+KL+KU) val K_sz = i2sz K val R_sz = i2sz R val (pf_RK | RK_sz) = mul2_size1_size1 (R_sz, K_sz) prval () = mul_nat_nat_nat (pf_RK) val (pfB_gc, pfB_arr | pB_arr) = array_ptr_alloc_tsz {a} (RK_sz, sizeof) // end of [val] prval pfB_fmat = fmatrix_v_of_array_v {a?} {R,K} (pf_RK, pfB_arr) // end of [prval] prval pf_unit = unit_v val () = fmatrix_ptr_initialize_vclo {unit_v} (pf_unit | !pB_arr, R_sz, K_sz, !p_f) where { val klpku = of_int (KL + KU) var !p_f = @lam ( pf : !unit_v | x : &(a?) >> a, k : sizeLt R, j : sizeLt K ) : void = x := // k = diagonal (ku = main), j = column (if k <> KU then of_int (~1) else klpku) } // end of [val] prval unit_v () = pf_unit prval (pfB_gbmat, fpfB_fmat) = GBMAT_v_of_fmatrix_v {a} (pfB_fmat, M, KL, KU) // end of [prval] val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc_tsz {a} (K, sizeof) // end of [val] val () = array_ptr_initialize_elt (!pX_arr, K, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc_tsz {a} (M, sizeof) // end of [val] // val () = array_ptr_initialize_fun (!pY_arr, M, f) where { fun f .<>. ( i : sizeLt M, x : &(a?) >> a ) :<> void = let val i = sz2i i val x0 = ( if i < KL then KL - i else if i < K-KU then 0 else if i < K then KU - (K - i - 1) else if i < K + KL then i - K - KL else 0 // end of [if] ) : int in x := of_int x0 end // end of [f] } // end of [val] // prval pfY_gev = GEVEC_v_of_array_v {a} (pfY_arr) val incY = 1 // val () = cblas_gbmv ( TRANDIM_N | CblasColMajor , CblasNoTrans , M, K , KL, KU , of_int 1 (* alpha *) , !pB_arr, R , !pX_arr, incX , of_int (~1) (* beta *) , !pY_arr, incY ) val diff = cblas_asum (M, !pY_arr, incY) (* val () = begin print "gbmv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] *) val () = begin print "gbmv_test<"; print_typ (); print ">: starts ... "; end val () = assert (isEpsilon (diff \$NUM.div (of_int (M*(KL+KU))))) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pfX_arr := array_v_of_GEVEC_v (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfY_arr := array_v_of_GEVEC_v (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfB_fmat := fpfB_fmat (pfB_gbmat) prval (pf2_RK, pfB_arr) = array_v_of_fmatrix_v (pfB_fmat) prval () = mul_isfun (pf_RK, pf2_RK) val () = array_ptr_free (pfB_gc, pfB_arr | pB_arr) } // end of [gbmv_test] (* ****** ****** *) extern fun{a,ar:t@ype} trmv_trsv_test (): void implement{a,ar} // ar = |a| trmv_trsv_test (): void = () where { #define M 100 // val (pf_MM | MM) = M imul2 M prval () = mul_nat_nat_nat (pf_MM) val (pfA_gc, pfA_arr | pA_arr) = array_ptr_alloc (size1_of_int1 MM) prval pfA_fmat = fmatrix_v_of_array_v (pf_MM, pfA_arr) prval pf_unit = unit_v val () = fmatrix_ptr_initialize_vclo {unit_v} (pf_unit | !pA_arr, M, M, !p_f) where { var !p_f = @lam (pf : !unit_v | A : &(a?) >> a, i : sizeLt M, j : sizeLt M) : void = A := of_int (sz2i j - sz2i i) } prval unit_v () = pf_unit prval (pfA_gmat, fpfA_fmat) = GEMAT_v_of_fmatrix_v (pfA_fmat) prval (pfA_trmat, fpfA_gmat) = TRMAT_v_of_GEMAT_v (pfA_gmat, UPLOupper, DIAGunit) // val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pX_arr, M, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pY_arr, M, of_int 1) prval pfY_gev = GEVEC_v_of_array_v (pfY_arr) val incY = 1 // val () = cblas_trmv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , M , !pA_arr, M , !pX_arr, incX ) // val () = cblas_trsv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , M , !pA_arr, M , !pX_arr, incX ) // val () = cblas_axpy ( M , of_int (~1) , !pX_arr, incX , !pY_arr, incY ) val diff = cblas_asum (M, !pY_arr, incY) val () = begin print "trmv_trsv_test<"; print_typ (); print ">: starts ... " end val () = assert (isEpsilon (diff \$NUM.div (of_int (M * M)))) val () = begin print "finishes"; print_newline () end (* val () = begin print "trmv_trsv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end *) // prval () = pfY_arr := array_v_of_GEVEC_v {a} (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfX_arr := array_v_of_GEVEC_v {a} (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfA_gmat := fpfA_gmat (pfA_trmat) prval () = pfA_fmat := fpfA_fmat (pfA_gmat) prval (pf2_MM, pfA_arr) = array_v_of_fmatrix_v (pfA_fmat) prval () = mul_isfun (pf_MM, pf2_MM) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [trmv_trsv_test] (* ****** ****** *) extern fun{a,ar:t@ype} tbmv_tbsv_test (): void implement{a,ar} // ar = |a| tbmv_tbsv_test (): void = () where { #define N 100 #define K 7 // val (pf_KN | KN) = (1+K) imul2 N prval () = mul_nat_nat_nat (pf_KN) val KN_sz = size1_of_int1 KN val (pfA_gc, pfA_arr | pA_arr) = array_ptr_alloc (KN_sz) prval pfA_fmat = fmatrix_v_of_array_v (pf_KN, pfA_arr) prval pf_unit = unit_v val () = fmatrix_ptr_initialize_vclo {unit_v} (pf_unit | !pA_arr, i2sz (K+1), N, !p_f) where { var !p_f = @lam ( pf: !unit_v | A: &(a?) >> a, i: sizeLt (K+1), j: sizeLt N ) : void = A := of_double ( if i < K then 1.0 / double_of_int K else 1.0 ) // end of [of_double] } // end of [val] prval unit_v () = pf_unit prval (pfA_gmat, fpfA_fmat) = GEMAT_v_of_fmatrix_v (pfA_fmat) prval (pfA_tpmat, fpfA_gmat) = TBMAT_v_of_GEMAT_v {a} {N,K} (pfA_gmat, UPLOupper, DIAGunit, K) (* end of [prval] *) // val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc (N) val () = array_ptr_initialize_elt (!pX_arr, N, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc (N) val () = array_ptr_initialize_elt (!pY_arr, N, of_int 1) prval pfY_gev = GEVEC_v_of_array_v (pfY_arr) val incY = 1 // val () = cblas_tbmv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , N, K , !pA_arr, (1+K) , !pX_arr, incX ) // val () = cblas_tbsv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , N, K , !pA_arr, (1+K) , !pX_arr, incX ) // val () = cblas_axpy ( N , of_int (~1) , !pX_arr, incX , !pY_arr, incY ) val diff = cblas_asum (N, !pY_arr, incY) (* val () = begin print "tbmv_tbsv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end *) val () = begin print "tbmv_tbsv_test<"; print_typ (); print ">: starts ... " end val () = assert (isEpsilon (diff \$NUM.div (of_int (N * K)))) val () = begin print "finishes"; print_newline () end // end of [val] // prval () = pfY_arr := array_v_of_GEVEC_v {a} (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfX_arr := array_v_of_GEVEC_v {a} (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfA_gmat := fpfA_gmat (pfA_tpmat) prval () = pfA_fmat := fpfA_fmat (pfA_gmat) prval (pf2_KN, pfA_arr) = array_v_of_fmatrix_v (pfA_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [tbmv_tbsv_test] (* ****** ****** *) extern fun{a,ar:t@ype} tpmv_tpsv_test (): void implement{a,ar} // ar = |a| tpmv_tpsv_test (): void = () where { #define M 100 #define L ((M * (M+1))/2) // prval pf_mml2 = mul_make {M,M+1} () prval () = mul_elim {M,M+1} {2*L} (pf_mml2) val L_sz = size1_of_int1 L val (pfA_gc, pfA_arr | pA_arr) = array_ptr_alloc (L_sz) val () = array_ptr_initialize_elt (!pA_arr, L_sz, of_double (1.0 / double_of_int M)) prval pfA_gvec = GEVEC_v_of_array_v {a} (pfA_arr) prval (pfA_tpmat, fpfA_gvec) = TPMAT_v_of_GEVEC_v {a} (pf_mml2, pfA_gvec, ORDERcol, UPLOupper, DIAGunit) // val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pX_arr, M, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pY_arr, M, of_int 1) prval pfY_gev = GEVEC_v_of_array_v (pfY_arr) val incY = 1 // val () = cblas_tpmv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , M , !pA_arr , !pX_arr, incX ) // val () = cblas_tpsv ( CblasColMajor , CblasUpper , CblasNoTrans , CblasUnit , M , !pA_arr , !pX_arr, incX ) // val () = cblas_axpy ( M , of_int (~1) , !pX_arr, incX , !pY_arr, incY ) val diff = cblas_asum (M, !pY_arr, incY) (* val () = begin print "tpmv_tpsv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end *) val () = begin print "tpmv_tpsv_test<"; print_typ (); print ">: starts ... " end val () = assert (isEpsilon (diff \$NUM.div (of_int (M * M)))) val () = begin print "finishes"; print_newline () end // prval () = pfY_arr := array_v_of_GEVEC_v {a} (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfX_arr := array_v_of_GEVEC_v {a} (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfA_gvec := fpfA_gvec (pfA_tpmat) prval () = pfA_arr := array_v_of_GEVEC_v (pfA_gvec) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [tpmv_tpsv_test] (* ****** ****** *) extern fun{a,ar:t@ype} symv_test (): void // // relate symv to symm // implement{a,ar} // ar = |a| symv_test (): void = () where { #define M 100 // needs to be a positive number #define K 100 // needs to be a positive number #define N 1 // needs to be a positive number val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_sym, fpf1_gem) = SYMAT_v_of_GEMAT_v (pf1_gem, UPLOupper) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_symm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] // prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_col (pf2_gem) // inc2 = 1 val inc2 = MATVECINC_get (pf2_inc | ORDERcol, ORDERcol, K) val inc2 = sz2i inc2 prval (pf3_inc, pf3_gev, fpf3_gem) = GEMAT_v_uncons_col (pf3_gem) // inc3 = 1 val inc3 = MATVECINC_get (pf3_inc | ORDERcol, ORDERcol, M) val inc3 = sz2i inc3 // val () = cblas_symv ( CblasColMajor , CblasUpper , M , pos1 (* alpha *) , !p1_arr, M , !p2_arr, inc2 , neg1 (* beta *) , !p3_arr, inc3 ) // end of [val] // val diff = cblas_nrm2 (M, !p3_arr, inc3) val () = begin print "symv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) // prval () = pf1_gem := fpf1_gem (pf1_sym) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_gem := fpf3_gem (pf3_gev) prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [symv_test] (* ****** ****** *) extern fun{a,ar:t@ype} ger_test (): void // // relate ger to gemm // implement{a,ar} // ar = |a| ger_test (): void = () where { #define M 19 // needs to be a positive number #define N 57 // needs to be a positive number #define K 01 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pfx_gc, pfx_arr | px_arr) = randgen_arr (MK) prval pfx_fmat = fmatrix_v_of_array_v {a} (pf_MK, pfx_arr) prval (pfx_gem, fpfx_fmat) = GEMAT_v_of_fmatrix_v (pfx_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pfy_gc, pfy_arr | py_arr) = randgen_arr (KN) prval pfy_fmat = fmatrix_v_of_array_v {a} (pf_KN, pfy_arr) prval (pfy_gem, fpfy_fmat) = GEMAT_v_of_fmatrix_v (pfy_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, K , pos1 (* alpha *) , !px_arr, M , !py_arr, K , zero (* beta *) , !p1_arr, M ) // end of [val] // prval (pfx_inc, pfx_gev, fpfx_gem) = GEMAT_v_uncons_col (pfx_gem) // incx = 1 val incx = MATVECINC_get (pfx_inc | ORDERcol, ORDERcol, M) val incx = sz2i incx prval (pfy_inc, pfy_gev, fpfy_gem) = GEMAT_v_uncons_row (pfy_gem) // incy = 1 val incy = MATVECINC_get (pfy_inc | ORDERrow, ORDERcol, K) val incy = sz2i incy // val () = cblas_ger ( CblasColMajor, M, N, neg1, !px_arr, incx, !py_arr, incy, !p1_arr, M ) // prval () = pfx_gem := fpfx_gem (pfx_gev) prval () = pfy_gem := fpfy_gem (pfy_gev) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) prval pf1_vec = GEVEC_v_of_array_v {a} (pf1_arr) val diff = cblas_nrm2 (MN, !p1_arr, 1) prval pf1_arr = array_v_of_GEVEC_v {a} (pf1_vec) val () = begin print "ger_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pfx_fmat := fpfx_fmat (pfx_gem) prval (pfx_MK, pfx_arr) = array_v_of_fmatrix_v (pfx_fmat) prval () = mul_isfun (pf_MK, pfx_MK) val () = array_ptr_free (pfx_gc, pfx_arr | px_arr) // prval () = pfy_fmat := fpfy_fmat (pfy_gem) prval (pfy_KN, pfy_arr) = array_v_of_fmatrix_v (pfy_fmat) prval () = mul_isfun (pf_KN, pfy_KN) val () = array_ptr_free (pfy_gc, pfy_arr | py_arr) } // end of [ger_test] (* ****** ****** *) extern fun{a,ar:t@ype} geru_test (): void // // relate geru to gemm // implement{a,ar} // ar = |a| geru_test (): void = () where { #define M 19 // needs to be a positive number #define N 57 // needs to be a positive number #define K 01 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pfx_gc, pfx_arr | px_arr) = randgen_arr (MK) prval pfx_fmat = fmatrix_v_of_array_v {a} (pf_MK, pfx_arr) prval (pfx_gem, fpfx_fmat) = GEMAT_v_of_fmatrix_v (pfx_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pfy_gc, pfy_arr | py_arr) = randgen_arr (KN) prval pfy_fmat = fmatrix_v_of_array_v {a} (pf_KN, pfy_arr) prval (pfy_gem, fpfy_fmat) = GEMAT_v_of_fmatrix_v (pfy_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, K , pos1 (* alpha *) , !px_arr, M , !py_arr, K , zero (* beta *) , !p1_arr, M ) // end of [val] // prval (pfx_inc, pfx_gev, fpfx_gem) = GEMAT_v_uncons_col (pfx_gem) // incx = 1 val incx = MATVECINC_get (pfx_inc | ORDERcol, ORDERcol, M) val incx = sz2i incx prval (pfy_inc, pfy_gev, fpfy_gem) = GEMAT_v_uncons_row (pfy_gem) // incy = 1 val incy = MATVECINC_get (pfy_inc | ORDERrow, ORDERcol, K) val incy = sz2i incy // val () = cblas_geru ( CblasColMajor, M, N, neg1, !px_arr, incx, !py_arr, incy, !p1_arr, M ) // prval () = pfx_gem := fpfx_gem (pfx_gev) prval () = pfy_gem := fpfy_gem (pfy_gev) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) prval pf1_vec = GEVEC_v_of_array_v {a} (pf1_arr) val diff = cblas_nrm2 (MN, !p1_arr, 1) prval pf1_arr = array_v_of_GEVEC_v {a} (pf1_vec) val () = begin print "geru_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pfx_fmat := fpfx_fmat (pfx_gem) prval (pfx_MK, pfx_arr) = array_v_of_fmatrix_v (pfx_fmat) prval () = mul_isfun (pf_MK, pfx_MK) val () = array_ptr_free (pfx_gc, pfx_arr | px_arr) // prval () = pfy_fmat := fpfy_fmat (pfy_gem) prval (pfy_KN, pfy_arr) = array_v_of_fmatrix_v (pfy_fmat) prval () = mul_isfun (pf_KN, pfy_KN) val () = array_ptr_free (pfy_gc, pfy_arr | py_arr) } // end of [geru_test] (* ****** ****** *) extern fun{a:t@ype} conj (x: a):<> a implement conj (x) = x implement conj (x) = x implement conj (x) = $C.conj_ccmplx (x) implement conj (x) = $C.conj_zcmplx (x) extern fun{a,ar:t@ype} gerc_test (): void // // relate gerc to gemm // implement{a,ar} // ar = |a| gerc_test (): void = () where { #define M 19 // needs to be a positive number #define N 57 // needs to be a positive number #define K 01 // needs to be a positive number val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MN) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pfx_gc, pfx_arr | px_arr) = randgen_arr (MK) prval pfx_fmat = fmatrix_v_of_array_v {a} (pf_MK, pfx_arr) prval (pfx_gem, fpfx_fmat) = GEMAT_v_of_fmatrix_v (pfx_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pfy_gc, pfy_arr | py_arr) = randgen_arr (KN) prval pfy_fmat = fmatrix_v_of_array_v {a} (pf_KN, pfy_arr) prval (pfy_gem, fpfy_fmat) = GEMAT_v_of_fmatrix_v (pfy_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, K , pos1 (* alpha *) , !px_arr, M , !py_arr, K , zero (* beta *) , !p1_arr, M ) // end of [val] // prval (pfx_inc, pfx_gev, fpfx_gem) = GEMAT_v_uncons_col (pfx_gem) // incx = 1 val incx = MATVECINC_get (pfx_inc | ORDERcol, ORDERcol, M) val incx = sz2i incx prval (pfy_inc, pfy_gev, fpfy_gem) = GEMAT_v_uncons_row (pfy_gem) // incy = 1 val incy = MATVECINC_get (pfy_inc | ORDERrow, ORDERcol, K) val incy_i = sz2i incy // val () = loop (pfy_gev | N, py_arr, incy) where { fun loop {n:nat} {d:inc} {l:addr} .. ( pf: !GEVEC_v (a, n, d, l) | n: size_t n, p: ptr l, inc: size_t d ) : void = if n > 0 then let prval pf_mul = mul_istot {d, sizeof a} () prval (pf_at, pf1) = GEVEC_v_uncons {a} (pf_mul, pf) val () = !p := conj (!p) prval () = pf := GEVEC_v_cons {a} (pf_mul, pf_at, pf1) val (pf1, pf2, fpf | p1) = GEVEC_ptr_split (pf | p, inc, 1) val () = loop (pf2 | n-1, p1, inc) prval () = pf := fpf (pf1, pf2) in // nothing end (* end of [if] *) // end of [loop] } // end of [val] // // HX-2010-07-15: if removed, a gcc optimization bug occurs!!! // val incy_i = sz2i incy val () = cblas_gerc ( CblasColMajor, M, N, neg1, !px_arr, incx, !py_arr, incy_i, !p1_arr, M ) // end of [cblas_gerc] // prval () = pfx_gem := fpfx_gem (pfx_gev) prval () = pfy_gem := fpfy_gem (pfy_gev) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MN, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MN, pf1_MN) prval pf1_vec = GEVEC_v_of_array_v {a} (pf1_arr) val diff = cblas_nrm2 (MN, !p1_arr, 1) prval pf1_arr = array_v_of_GEVEC_v {a} (pf1_vec) val () = begin print "gerc_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pfx_fmat := fpfx_fmat (pfx_gem) prval (pfx_MK, pfx_arr) = array_v_of_fmatrix_v (pfx_fmat) prval () = mul_isfun (pf_MK, pfx_MK) val () = array_ptr_free (pfx_gc, pfx_arr | px_arr) // prval () = pfy_fmat := fpfy_fmat (pfy_gem) prval (pfy_KN, pfy_arr) = array_v_of_fmatrix_v (pfy_fmat) prval () = mul_isfun (pf_KN, pfy_KN) val () = array_ptr_free (pfy_gc, pfy_arr | py_arr) } // end of [gerc_test] (* ****** ****** *) extern fun{a,ar:t@ype} hemv_test (): void // // relate hemv to hemm // implement{a,ar} // ar = |a| hemv_test (): void = () where { #define M 100 // needs to be a positive number #define K 100 // needs to be a positive number #define N 1 // needs to be a positive number val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) prval (pf1_hem, fpf1_gem) = HEMAT_v_of_GEMAT_v (pf1_gem, UPLOupper) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_hemm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] // prval (pf2_inc, pf2_gev, fpf2_gem) = GEMAT_v_uncons_col (pf2_gem) // inc2 = 1 val inc2 = MATVECINC_get (pf2_inc | ORDERcol, ORDERcol, K) val inc2 = sz2i inc2 prval (pf3_inc, pf3_gev, fpf3_gem) = GEMAT_v_uncons_col (pf3_gem) // inc3 = 1 val inc3 = MATVECINC_get (pf3_inc | ORDERcol, ORDERcol, M) val inc3 = sz2i inc3 // val () = cblas_hemv ( CblasColMajor , CblasUpper , M , pos1 (* alpha *) , !p1_arr, M , !p2_arr, inc2 , neg1 (* beta *) , !p3_arr, inc3 ) // end of [val] // val diff = cblas_nrm2 (M, !p3_arr, inc3) val () = begin print "hemv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = assert (isEpsilon diff) // prval () = pf1_gem := fpf1_gem (pf1_hem) prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_gem := fpf2_gem (pf2_gev) prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_gem := fpf3_gem (pf3_gev) prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [hemv_test] (* ****** ****** *) extern fun{a,ar:t@ype} hbmv_test (): void extern prfun HBMAT_v_of_fmatrix_v {a:viewt@ype} {k,m:nat} {l:addr} {ul : uplo} ( pf : fmatrix_v (a, k, m, l), ul: UPLO (ul) ) : ( HBMAT_v (a, m, col, ul, k-1, k, l) , HBMAT_v (a, m, col, ul, k-1, k, l) - fmatrix_v (a, k, m, l) ) // end of [HBMAT_v_of_fmatrix_v] implement{a,ar} // ar = |a| hbmv_test (): void = () where { #define M 100 #define K 5 #define R (1+K) // val R_sz = i2sz R val M_sz = i2sz M val (pf_RM | RM_sz) = mul2_size1_size1 (R_sz, M_sz) prval () = mul_nat_nat_nat (pf_RM) val (pfB_gc, pfB_arr | pB_arr) = array_ptr_alloc (RM_sz) prval (pfB_fmat) = fmatrix_v_of_array_v {a?} {R,M} (pf_RM, pfB_arr) prval pf_unit = unit_v val () = fmatrix_ptr_initialize_vclo {unit_v} (pf_unit | !pB_arr, R_sz, M_sz, !p_f) where { val kpk1 = of_int (2*K) var !p_f = @lam ( pf : !unit_v | x : &(a?) >> a, k : sizeLt R, j : sizeLt M ) : void = x := // k = diagonal (K = main/upper), j = column (if k < K then of_int (~1) else kpk1) } prval unit_v () = pf_unit prval (pfB_hbmat, fpfB_fmat) = HBMAT_v_of_fmatrix_v {a} (pfB_fmat, UPLOupper) // val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pX_arr, M, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc (M) // val () = array_ptr_initialize_fun (!pY_arr, M, f) where { fn f ( i : sizeLt M , y : &(a?) >> a ) :<> void = let val i = sz2i i val y0 = ( if i < K then K - i else if i < M-K then 0 else // i < M K - (M - i - 1) // end of [if] ) : int in y := of_int y0 end // end of [f] } // end of [val] // prval pfY_gev = GEVEC_v_of_array_v {a} (pfY_arr) val incY = 1 // val () = cblas_hbmv ( CblasColMajor , CblasUpper , M, K , of_int 1 (* alpha *) , !pB_arr, R , !pX_arr, incX , of_int (~1) (* beta *) , !pY_arr, incY ) val diff = cblas_asum (M, !pY_arr, incY) (* val () = begin print "hbmv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end *) val () = begin print "hbmv_test<"; print_typ (); print ">: starts ... "; end val () = assert (isEpsilon (diff \$NUM.div (of_int (M*K)))) val () = begin print "finishes"; print_newline () end // prval () = pfX_arr := array_v_of_GEVEC_v (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfY_arr := array_v_of_GEVEC_v (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfB_fmat := fpfB_fmat (pfB_hbmat) prval (pf2_RM, pfB_arr) = array_v_of_fmatrix_v (pfB_fmat) prval () = mul_isfun (pf_RM, pf2_RM) val () = array_ptr_free (pfB_gc, pfB_arr | pB_arr) } // end of [hbmv_test] (* ****** ****** *) extern fun{a,ar:t@ype} hpmv_test (): void // // [HPMAT_v_of_array_v] can be proven by using [HPMAT_v_of_GEVEC_v] // extern prfun HPMAT_v_of_array_v {a:viewt@ype} {n,m:nat} {l:addr} {ord:order} {ul:uplo} ( pf_mmn: MUL (m, m+1, 2*n) , pf: array_v (a, n, l), m: int m, ord: ORDER ord, ul: UPLO ul ) : ( HPMAT_v (a, m, ord, ul, l) , HPMAT_v (a, m, ord, ul, l) - array_v (a, n, l) ) // end of [HPMAT_v_of_array_v] implement{a,ar} // ar = |a| hpmv_test (): void = () where { #define M 100 #define L ((M * (M+1)) / 2) // prval pf_mml2 = mul_make {M,M+1} () prval () = mul_elim {M,M+1} {2*L} (pf_mml2) val L_sz = size1_of_int1 L val (pfA_gc, pfA_arr | pA_arr) = array_ptr_alloc (L_sz) // val () = array_ptr_initialize_fun (!pA_arr, L_sz, f) where { fn f (i : sizeLt L, A : &(a?) >> a) :<> void = let val i = sz2i i val c = int_of_double (($M.sqrt (1.0 + 8.0 * (double_of_int i)) - 1.0) / 2.0) val r = i - (c * (c + 1)) / 2 in A := of_int (c - r) end // end of [f] } // end of [val] // prval (pfA_hpmat, fpfA_arr) = HPMAT_v_of_array_v (pf_mml2, pfA_arr, M, ORDERcol, UPLOupper) // val (pfX_gc, pfX_arr | pX_arr) = array_ptr_alloc (M) val () = array_ptr_initialize_elt (!pX_arr, M, of_int 1) prval pfX_gev = GEVEC_v_of_array_v {a} (pfX_arr) val incX = 1 val (pfY_gc, pfY_arr | pY_arr) = array_ptr_alloc (M) // val () = array_ptr_initialize_fun (!pY_arr, M, f) where { fn f ( i : sizeLt M, y : &(a?) >> a ) :<> void = y := of_int let val i = sz2i i in (i * (i + 1) + (M - i - 1) * (M - i)) / 2 end // end of [let] } // end of [val] // prval pfY_gev = GEVEC_v_of_array_v {a} (pfY_arr) val incY = 1 // val () = cblas_hpmv ( CblasColMajor , CblasUpper , M , of_int 1 (* alpha *) , !pA_arr , !pX_arr, incX , of_int (~1) (* beta *) , !pY_arr, incY ) val diff = cblas_asum (M, !pY_arr, incY) val () = begin print "hpmv_test<"; print_typ (); print ">: starts ... " end val () = assert (isEpsilon (diff \$NUM.div (of_int M))) val () = begin print "finishes"; print_newline () end (* val () = begin print "hpmv_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end *) // prval () = pfX_arr := array_v_of_GEVEC_v (pfX_gev) val () = array_ptr_free (pfX_gc, pfX_arr | pX_arr) prval () = pfY_arr := array_v_of_GEVEC_v (pfY_gev) val () = array_ptr_free (pfY_gc, pfY_arr | pY_arr) prval () = pfA_arr := fpfA_arr (pfA_hpmat) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [hpmv_test] (* ****** ****** *) // Sum of 2-norms of columns fun{a,ar:t@ype} GEMAT_nrmF {m,n:nat} {ld:pos} {ord:order} ( Order: ORDER ord , A: &GEMAT (a, m, n, ord, ld), m: size_t m, n: size_t n, ld: size_t ld ): ar = let val m_i = sz2i m fun loop {k:nat} {l0:addr} ( pf_gmat: !GEMAT_v (a, m, k, ord, ld, l0) | pA: ptr l0, acc: ar, k: size_t k): ar = if k = 0 then acc else let prval (pf_inc, pf_gev, fpf_gmat) = GEMAT_v_uncons_col {a} {ord} {m,k} (pf_gmat) val inc = MATVECINC_get (pf_inc | ORDERcol, Order, ld) val inc = sz2i inc val cnrm = cblas_nrm2 (m_i, !pA, inc) prval () = pf_gmat := fpf_gmat (pf_gev) val (pf1_gmat, pf2_gmat, fpf_gmat | pA1, pA2) = GEMAT_ptr_split1x2 (pf_gmat | Order, pA, ld, 1) val acc = loop (pf2_gmat | pA2, $NUM.add (acc, cnrm), k-1) prval () = pf_gmat := fpf_gmat (pf1_gmat, pf2_gmat) in acc end // end of [loop] in loop (view@ A | &A, of_int 0, n) end // end of [GEMAT_nrmF] // Y <- alpha X + Y fun{a:t@ype} GEMAT_axpy {m,n:nat} {ldx,ldy:pos} {ord:order} ( Order: ORDER ord , m: size_t m, n: size_t n , alpha: a , X: &GEMAT (a, m, n, ord, ldx), ldx: size_t ldx , Y: &GEMAT (a, m, n, ord, ldy), ldy: size_t ldy ): void = let val m_i = sz2i m fun loop {lx,ly:addr} {k:nat} ( pfX_gmat: !GEMAT_v (a, m, k, ord, ldx, lx) , pfY_gmat: !GEMAT_v (a, m, k, ord, ldy, ly) | pX: ptr lx, pY: ptr ly, k: size_t k): void = if k > 0 then let prval (pfX_inc, pfX_gvec, fpfX_gmat) = GEMAT_v_uncons_col (pfX_gmat) val incX = MATVECINC_get (pfX_inc | ORDERcol, Order, ldx) val incX = sz2i incX prval (pfY_inc, pfY_gvec, fpfY_gmat) = GEMAT_v_uncons_col (pfY_gmat) val incY = MATVECINC_get (pfY_inc | ORDERcol, Order, ldy) val incY = sz2i incY val () = cblas_axpy (m_i, alpha, !pX, incX, !pY, incY) prval () = pfX_gmat := fpfX_gmat (pfX_gvec) prval () = pfY_gmat := fpfY_gmat (pfY_gvec) val (pfX1_gmat, pfX2_gmat, fpfX_gmat | pX1, pX2) = GEMAT_ptr_split1x2 (pfX_gmat | Order, pX, ldx, 1) val (pfY1_gmat, pfY2_gmat, fpfY_gmat | pY1, pY2) = GEMAT_ptr_split1x2 (pfY_gmat | Order, pY, ldy, 1) val () = loop (pfX2_gmat, pfY2_gmat | pX2, pY2, k-1) prval () = pfX_gmat := fpfX_gmat (pfX1_gmat, pfX2_gmat) prval () = pfY_gmat := fpfY_gmat (pfY1_gmat, pfY2_gmat) in // nothing end // end of [if] in loop (view@ X, view@ Y | &X, &Y, n) end // end of [GEMAT_axpy] (* ****** ****** *) extern fun{a,ar:t@ype} her_her2_test (): void (* [ c s] [-c^2 ] [ c s]^T = 1/2 [-2c2 s2] = ([-c2][1 0] + [1][-c2 s2]) 1/2 [-s c] [ s^2] [-s c] [ s2 ] ([ s2] [0] ) where c = cos theta s = sin theta c2 = cos 2theta s2 = sin 2theta *) implement{a,ar} // ar = |a| her_her2_test (): void = () where { #define M 100 val (pfA_gc, pf_MM, pfA_fmat | pA_arr) = randgen_fmat (M, M) val () = loop_diag (!pA_arr, 0) where { // real diag for HEMAT fun loop_diag {i:nat | i <= M} .. (A: &fmatrix(a, M, M), i: size_t i) : void = if i < M then let val x = fmatrix_ptr_get_elt_at (A, M, i, i) val x_re = x \$NUM.add (conj x) val () = fmatrix_ptr_set_elt_at (A, M, i, i, x_re) in loop_diag (A, i+1) end // end of [if] // end of [loop_diag] } // end of [val] val (pfC_gc, pfC_MM, pfC_fmat | pC_arr) = fmatrix_ptr_alloc (M, M) prval () = mul_isfun (pf_MM, pfC_MM) val () = fmatrix_ptr_copy (!pA_arr, !pC_arr, M, M) prval (pfC_gmat, fpfC_fmat) = GEMAT_v_of_fmatrix_v (pfC_fmat) prval (pfA_gmat, fpfA_fmat) = GEMAT_v_of_fmatrix_v (pfA_fmat) prval (pfA_hmat, fpfA_gmat) = HEMAT_v_of_GEMAT_v (pfA_gmat, UPLOupper) // val [_:int] [lb:addr] (pfB_gc, pfB_M2, pfB_fmat | pB_arr) = randgen_fmat (M, 2) // end of [val] prval (pfB_gmat, fpfB_fmat) = GEMAT_v_of_fmatrix_v (pfB_fmat) prval () = mul_nat_nat_nat (pfB_M2) // val (pfBV_gc, pfBV_M2, pfBV_fmat | pBV_arr) = randgen_fmat (M, 2) prval (pfBV_gmat, fpfBV_fmat) = GEMAT_v_of_fmatrix_v (pfBV_fmat) prval () = mul_isfun (pfB_M2, pfBV_M2) // #define theta (M_PI / 8.0) val cr = cos theta val sr = sin theta var c = of_double cr val s = of_double sr val s_m = $NUM.neg s val l1 = of_double (~(cr * cr)) val l2 = of_double (sr * sr) val [_:int] [lv:addr] (pfV_gc, pfV_22, pfV_fmat | pV_arr) = fmatrix_ptr_alloc (2, 2) // end of [val] val () = fmatrix_ptr_initialize_elt (!pV_arr, 2, 2, c) // macdef fmset (A, i, j, c) = fmatrix_ptr_set_elt_at {2,2} (,(A), 2, ,(i), ,(j), ,(c)) (* end of [macdef] *) // val () = fmset (!pV_arr, 0, 0, c) val () = fmset (!pV_arr, 1, 0, s_m) val () = fmset (!pV_arr, 0, 1, s) val () = fmset (!pV_arr, 1, 1, c) prval (pfV_gmat, fpfV_fmat) = GEMAT_v_of_fmatrix_v (pfV_fmat) // viewdef vB = GEMAT_v (a, M, 2, col, M, lb) viewdef vV = GEMAT_v (a, 2, 2, col, 2, lv) viewdef vBV = @(vB, vV) prval pf_BV_gmat = @(pfB_gmat, pfV_gmat) val () = cblas_gemm__main {vBV} ( // BV <- B * V pf_BV_gmat , TRANDIM_N , vsubr_tup_2_0 {vB,vV} () , TRANDIM_N , vsubr_tup_2_1 {vB,vV} () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, 2, 2 , of_int 1 , pB_arr, M , pV_arr, 2 , of_int 0 , !pBV_arr, M ) prval (pfB_gmat, pfV_gmat) = pf_BV_gmat // val (pfBV1_gmat, pfBV2_gmat, fpfBV_gmat | pBV1_arr, pBV2_arr) = GEMAT_ptr_split1x2 (pfBV_gmat | ORDERcol, pBV_arr, M, 1) // end of [val] prval (pfBV1_inc, pfBV1_gev, fpfBV1_gmat) = GEVEC_v_of_GEMAT_v_col (pfBV1_gmat) // end of [prval] val incBV1 = MATVECINC_get (pfBV1_inc | ORDERcol, ORDERcol, M) val incBV1 = sz2i incBV1 prval (pfBV2_inc, pfBV2_gev, fpfBV2_gmat) = GEVEC_v_of_GEMAT_v_col (pfBV2_gmat) // end of [prval] val incBV2 = MATVECINC_get (pfBV2_inc | ORDERcol, ORDERcol, M) val incBV2 = sz2i incBV2 // A <- A + l1 BV1 * BV1' + l2 BV2 * BV2 ' val () = cblas_her ( CblasColMajor , CblasUpper , M , l1 , !pBV1_arr, incBV1 , !pA_arr, M ) val () = cblas_her ( CblasColMajor , CblasUpper , M , l2 , !pBV2_arr, incBV2 , !pA_arr, M ) // val (pfB1_gmat, pfB2_gmat, fpfB_gmat | pB1_arr, pB2_arr) = GEMAT_ptr_split1x2 (pfB_gmat | ORDERcol, pB_arr, M, 1) prval (pfB1_inc, pfB1_gev, fpfB1_gmat) = GEVEC_v_of_GEMAT_v_col (pfB1_gmat) val incB1 = MATVECINC_get (pfB1_inc | ORDERcol, ORDERcol, M) val incB1 = sz2i incB1 prval (pfB2_inc, pfB2_gev, fpfB2_gmat) = GEVEC_v_of_GEMAT_v_col (pfB2_gmat) val incB2 = MATVECINC_get (pfB2_inc | ORDERcol, ORDERcol, M) val incB2 = sz2i incB2 val c2r = cos (2.0 * theta) val s2r = sin (2.0 * theta) // val () = cblas_scal ( // B2 <- sin(2 theta) B2 M, of_double s2r, !pB2_arr, incB2 ) val () = cblas_axpy ( // B2 <- - cos(2 theta) B1 + [sin(2 theta) B2] M , of_double (~c2r) , !pB1_arr, incB1 , !pB2_arr, incB2 ) // val () = cblas_her2 ( // A <- A + 0.5 (B2 B1' + B1 * B2') CblasColMajor , CblasUpper , M , of_double (~0.5) , !pB2_arr, incB2 , !pB1_arr, incB1 , !pA_arr, M ) // prval pfA_gmat = fpfA_gmat (pfA_hmat) val () = GEMAT_axpy ( ORDERcol, M, M, of_int (~1), !pA_arr, M, !pC_arr, M) val diff = GEMAT_nrmF (ORDERcol, !pC_arr, M, M, M) (* val () = begin print "her_her2_test<"; print_typ (); print ","; print_typ (); print ">: diff = "; print_elt diff; print_newline () end // end of [val] *) val () = begin print "her_her2_test<"; print_typ (); print ","; print_typ (); print ">: starts ... "; end // end of [val] val () = assert (isEpsilon (diff \$NUM.div (of_int (M * M)))) val () = begin print "finishes"; print_newline () end // end of [val] // prval pfBV1_gmat = fpfBV1_gmat (pfBV1_gev) prval pfBV2_gmat = fpfBV2_gmat (pfBV2_gev) prval pfBV_gmat = fpfBV_gmat (pfBV1_gmat, pfBV2_gmat) prval pfBV_fmat = fpfBV_fmat (pfBV_gmat) val () = fmatrix_ptr_free (pfBV_gc, pfBV_M2, pfBV_fmat| pBV_arr) // prval pfV_fmat = fpfV_fmat (pfV_gmat) val () = fmatrix_ptr_free (pfV_gc, pfV_22, pfV_fmat | pV_arr) // prval pfC_fmat = fpfC_fmat (pfC_gmat) val () = fmatrix_ptr_free (pfC_gc, pfC_MM, pfC_fmat| pC_arr) // prval pfB1_gmat = fpfB1_gmat (pfB1_gev) prval pfB2_gmat = fpfB2_gmat (pfB2_gev) prval pfB_gmat = fpfB_gmat (pfB1_gmat, pfB2_gmat) prval pfB_fmat = fpfB_fmat (pfB_gmat) val () = fmatrix_ptr_free (pfB_gc, pfB_M2, pfB_fmat | pB_arr) // prval pfA_fmat = fpfA_fmat (pfA_gmat) val () = fmatrix_ptr_free (pfA_gc, pf_MM, pfA_fmat | pA_arr) } // end of [her_her2_test] (* ****** ****** *) extern fun{a,ar:t@ype} hpr_hpr2_test (): void implement{a,ar} // ar = |a| hpr_hpr2_test (): void = () where { #define M 100 #define L ((M * (M+1))/2) val (pfA_gc, pfA_arr | pA_arr) = randgen_arr (L) val () = loop_diag (!pA_arr, 0, 2) where { // real diag for HPMAT fun loop_diag {i,k:nat | i < L && k <= M+1} (A: &(@[a][L]), i: int i, k: int k): void = let val () = A[i] := $NUM.add (A[i], conj A[i]) in if i < L-M && k <= M then loop_diag (A, i+k, k+1) end // end of [loop_diag] } val L_sz = size1_of_int1 L val (pfC_gc, pfC_arr | pC_arr) = array_ptr_alloc (L_sz) val () = array_ptr_copy_tsz (!pA_arr, !pC_arr, L_sz, sizeof) prval pf_mml2 = mul_make {M,M+1} () prval () = mul_elim {M,M+1} {2*L} (pf_mml2) prval pfC_gev = GEVEC_v_of_array_v (pfC_arr) prval pfA_gev = GEVEC_v_of_array_v (pfA_arr) prval (pfA_hpmat, fpfA_gev) = HPMAT_v_of_GEVEC_v (pf_mml2, pfA_gev, ORDERcol, UPLOupper) (* end of [prval] *) // val [_:int] [lb:addr] (pfB_gc, pfB_M2, pfB_fmat | pB_arr) = randgen_fmat (M, 2) // end of [val] prval (pfB_gmat, fpfB_fmat) = GEMAT_v_of_fmatrix_v (pfB_fmat) prval () = mul_nat_nat_nat (pfB_M2) // val (pfBV_gc, pfBV_M2, pfBV_fmat | pBV_arr) = randgen_fmat (M, 2) // end of [val] prval (pfBV_gmat, fpfBV_fmat) = GEMAT_v_of_fmatrix_v (pfBV_fmat) prval () = mul_isfun (pfB_M2, pfBV_M2) // #define theta (M_PI / 8.0) val cr = cos theta val sr = sin theta var c = of_double cr val s = of_double sr val s_m = $NUM.neg s val l1 = of_double (~(cr * cr)) val l2 = of_double (sr * sr) val [_:int] [lv:addr] (pfV_gc, pfV_22, pfV_fmat | pV_arr) = fmatrix_ptr_alloc (2, 2) val () = fmatrix_ptr_initialize_elt (!pV_arr, 2, 2, c) // macdef fmset (A, i, j, c) = fmatrix_ptr_set_elt_at {2,2} (,(A), 2, ,(i), ,(j), ,(c)) // val () = fmset (!pV_arr, 0, 0, c) val () = fmset (!pV_arr, 1, 0, s_m) val () = fmset (!pV_arr, 0, 1, s) val () = fmset (!pV_arr, 1, 1, c) prval (pfV_gmat, fpfV_fmat) = GEMAT_v_of_fmatrix_v (pfV_fmat) // viewdef vB = GEMAT_v (a, M, 2, col, M, lb) viewdef vV = GEMAT_v (a, 2, 2, col, 2, lv) viewdef vBV = @(vB, vV) prval pf_BV_gmat = @(pfB_gmat, pfV_gmat) val () = cblas_gemm__main {vBV} ( // BV <- B * V pf_BV_gmat , TRANDIM_N , vsubr_tup_2_0 {vB,vV} () , TRANDIM_N , vsubr_tup_2_1 {vB,vV} () | CblasColMajor , CblasNoTrans , CblasNoTrans , M, 2, 2 , of_int 1 , pB_arr, M , pV_arr, 2 , of_int 0 , !pBV_arr, M ) prval (pfB_gmat, pfV_gmat) = pf_BV_gmat // val (pfBV1_gmat, pfBV2_gmat, fpfBV_gmat | pBV1_arr, pBV2_arr) = GEMAT_ptr_split1x2 (pfBV_gmat | ORDERcol, pBV_arr, M, 1) prval (pfBV1_inc, pfBV1_gev, fpfBV1_gmat) = GEVEC_v_of_GEMAT_v_col (pfBV1_gmat) val incBV1 = MATVECINC_get (pfBV1_inc | ORDERcol, ORDERcol, M) val incBV1 = sz2i incBV1 prval (pfBV2_inc, pfBV2_gev, fpfBV2_gmat) = GEVEC_v_of_GEMAT_v_col (pfBV2_gmat) val incBV2 = MATVECINC_get (pfBV2_inc | ORDERcol, ORDERcol, M) val incBV2 = sz2i incBV2 // A <- A + l1 BV1 * BV1' + l2 BV2 * BV2 ' val () = cblas_hpr ( CblasColMajor , CblasUpper , M , l1 , !pBV1_arr, incBV1 , !pA_arr ) val () = cblas_hpr ( CblasColMajor , CblasUpper , M , l2 , !pBV2_arr, incBV2 , !pA_arr ) // val (pfB1_gmat, pfB2_gmat, fpfB_gmat | pB1_arr, pB2_arr) = GEMAT_ptr_split1x2 (pfB_gmat | ORDERcol, pB_arr, M, 1) prval (pfB1_inc, pfB1_gev, fpfB1_gmat) = GEVEC_v_of_GEMAT_v_col (pfB1_gmat) val incB1 = MATVECINC_get (pfB1_inc | ORDERcol, ORDERcol, M) val incB1 = sz2i incB1 prval (pfB2_inc, pfB2_gev, fpfB2_gmat) = GEVEC_v_of_GEMAT_v_col (pfB2_gmat) val incB2 = MATVECINC_get (pfB2_inc | ORDERcol, ORDERcol, M) val incB2 = sz2i incB2 val c2r = cos (2.0 * theta) val s2r = sin (2.0 * theta) // val () = cblas_scal ( // B2 <- sin(2 theta) B2 M, of_double s2r, !pB2_arr, incB2 ) val () = cblas_axpy ( // B2 <- - cos(2 theta) B1 + [sin(2 theta) B2] M , of_double (~c2r) , !pB1_arr, incB1 , !pB2_arr, incB2 ) // val () = cblas_hpr2 ( // A <- A + 0.5 (B2 B1' + B1 * B2') CblasColMajor , CblasUpper , M , of_double (~0.5) , !pB2_arr, incB2 , !pB1_arr, incB1 , !pA_arr ) // prval pfA_gev = fpfA_gev (pfA_hpmat) val () = cblas_axpy ( L, of_int (~1), !pA_arr, 1, !pC_arr, 1) val diff = cblas_asum (L, !pC_arr, 1) (* val () = begin print "hpr_hpr2_test<"; print_typ (); print ","; print_typ (); print ">: diff = "; print_elt diff; print_newline () end // end of [val] *) val () = begin print "hpr_hpr2_test<"; print_typ (); print ","; print_typ (); print ">: starts ... "; end // end of [val] val () = assert (isEpsilon (diff \$NUM.div (of_int (M * M)))) val () = begin print "finishes"; print_newline () end // end of [val] // prval pfBV1_gmat = fpfBV1_gmat (pfBV1_gev) prval pfBV2_gmat = fpfBV2_gmat (pfBV2_gev) prval pfBV_gmat = fpfBV_gmat (pfBV1_gmat, pfBV2_gmat) prval pfBV_fmat = fpfBV_fmat (pfBV_gmat) val () = fmatrix_ptr_free (pfBV_gc, pfBV_M2, pfBV_fmat| pBV_arr) // prval pfV_fmat = fpfV_fmat (pfV_gmat) val () = fmatrix_ptr_free (pfV_gc, pfV_22, pfV_fmat | pV_arr) // prval pfC_arr = array_v_of_GEVEC_v (pfC_gev) val () = array_ptr_free (pfC_gc, pfC_arr| pC_arr) // prval pfB1_gmat = fpfB1_gmat (pfB1_gev) prval pfB2_gmat = fpfB2_gmat (pfB2_gev) prval pfB_gmat = fpfB_gmat (pfB1_gmat, pfB2_gmat) prval pfB_fmat = fpfB_fmat (pfB_gmat) val () = fmatrix_ptr_free (pfB_gc, pfB_M2, pfB_fmat | pB_arr) // prval pfA_arr = array_v_of_GEVEC_v (pfA_gev) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) } // end of [hpr_hpr2_test] (* ****** ****** *) // BLAS level 3 (* ****** ****** *) extern fun{a,ar:t@ype} gemm_test (): void // // checking the identity A * B = (B^T * A^T)^T // implement{a,ar} // ar = |a| gemm_test (): void = () where { #define M 13 // needs to be a positive number #define K 29 // needs to be a positive number #define N 17 // needs to be a positive number // val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasColMajor , CblasNoTrans , CblasNoTrans , M, N, K , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] // prval TRANORDcolrow () = GEMAT_v_trans (pf1_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf3_gem) val () = cblas_gemm ( TRANDIM_N , TRANDIM_N | CblasRowMajor , CblasNoTrans , CblasNoTrans , N, M, K , pos1 (* alpha *) , !p2_arr, K , !p1_arr, M , neg1 (* beta *) , !p3_arr, M ) // end of [val] prval TRANORDrowcol () = GEMAT_v_trans (pf1_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf3_gem) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) prval pf3_vec = GEVEC_v_of_array_v {a} (pf3_arr) val diff = cblas_nrm2 (MN, !p3_arr, 1) val () = begin print "gemm_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf3_arr = array_v_of_GEVEC_v {a} (pf3_vec) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [gemm_test] (* ****** ****** *) extern fun{a,ar:t@ype} syrk_test (): void // // checking the identity A * A' = (A')' * A' // implement{a,ar} // ar = |a| syrk_test (): void = () where { #define N 17 // needs to be a positive number #define K 29 // needs to be a positive number // val (pf_NK | NK) = op imul2 (N, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (NK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // var zero: a = of_double (0.0) val (pf_NN | NN) = op imul2 (N, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NN) val NN_sz = size1_of_int1 NN val (pf2_gc, pf2_arr | p2_arr) = array_ptr_alloc_tsz {a} (NN_sz, sizeof) // end of [val] val () = array_ptr_initialize_elt_tsz {a} (!p2_arr, NN_sz, zero, sizeof) // end of [val] prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_NN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // prval (pf2_sym, fpf2_gem) = SYMAT_v_of_GEMAT_v (pf2_gem, UPLOupper) val () = cblas_syrk ( TRANDIM_N | CblasColMajor , CblasUpper , CblasNoTrans , N, K , pos1 (* alpha *) , !p1_arr, N , zero (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval (pf2_sym, fpf2_gem) = SYMAT_v_of_GEMAT_v (pf2_gem, UPLOlower) val () = cblas_syrk ( TRANDIM_T | CblasRowMajor , CblasLower , CblasTrans , N, K , pos1 (* alpha *) , !p1_arr, N , neg1 (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) prval TRANORDrowcol () = GEMAT_v_trans (pf1_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_NK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_NK, pf1_NK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_NN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_NN, pf2_NN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val diff = cblas_nrm2 (NN, !p2_arr, 1) val () = begin print "syrk_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [syrk_test] (* ****** ****** *) extern fun{a,ar:t@ype} syr2k_test (): void // // checking the identity A * B' + B * A' = A' * B'' + B' * A'' // implement{a,ar} // ar = |a| syr2k_test (): void = () where { #define N 17 // needs to be a positive number #define K 29 // needs to be a positive number // val (pf_NK | NK) = op imul2 (N, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NK) val (pf1A_gc, pf1A_arr | p1A_arr) = randgen_arr (NK) prval pf1A_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1A_arr) prval (pf1A_gem, fpf1A_fmat) = GEMAT_v_of_fmatrix_v (pf1A_fmat) val (pf1B_gc, pf1B_arr | p1B_arr) = randgen_arr (NK) prval pf1B_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1B_arr) prval (pf1B_gem, fpf1B_fmat) = GEMAT_v_of_fmatrix_v (pf1B_fmat) // var zero: a = of_double (0.0) val (pf_NN | NN) = op imul2 (N, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NN) val NN_sz = size1_of_int1 NN val (pf2_gc, pf2_arr | p2_arr) = array_ptr_alloc_tsz {a} (NN_sz, sizeof) // end of [val] val () = array_ptr_initialize_elt_tsz {a} (!p2_arr, NN_sz, zero, sizeof) // end of [val] prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_NN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // prval (pf2_sym, fpf2_gem) = SYMAT_v_of_GEMAT_v (pf2_gem, UPLOupper) val () = cblas_syr2k ( TRANDIM_N | CblasColMajor , CblasUpper , CblasNoTrans , N, K , pos1 (* alpha *) , !p1A_arr, N , !p1B_arr, N , zero (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1A_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf1B_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval (pf2_sym, fpf2_gem) = SYMAT_v_of_GEMAT_v (pf2_gem, UPLOlower) val () = cblas_syr2k ( TRANDIM_T | CblasRowMajor , CblasLower , CblasTrans , N, K , pos1 (* alpha *) , !p1A_arr, N , !p1B_arr, N , neg1 (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) prval TRANORDrowcol () = GEMAT_v_trans (pf1A_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf1B_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) // prval () = pf1A_fmat := fpf1A_fmat (pf1A_gem) prval (pf1A_NK, pf1A_arr) = array_v_of_fmatrix_v (pf1A_fmat) prval () = mul_isfun (pf_NK, pf1A_NK) val () = array_ptr_free (pf1A_gc, pf1A_arr | p1A_arr) prval () = pf1B_fmat := fpf1B_fmat (pf1B_gem) prval (pf1B_NK, pf1B_arr) = array_v_of_fmatrix_v (pf1B_fmat) prval () = mul_isfun (pf_NK, pf1B_NK) val () = array_ptr_free (pf1B_gc, pf1B_arr | p1B_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_NN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_NN, pf2_NN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val diff = cblas_nrm2 (NN, !p2_arr, 1) val () = begin print "syr2k_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [syr2k_test] (* ****** ****** *) extern fun{a,ar:t@ype} symm_test (): void // // checking the identity A * B = (B^T * A^T)^T // implement{a,ar} // ar = |a| symm_test (): void = () where { #define M 13 // needs to be a positive number #define K 13 // needs to be a positive number #define N 17 // needs to be a positive number val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // prval (pf1_sym, fpf1_gem) = SYMAT_v_of_GEMAT_v (pf1_gem, UPLOupper) val () = cblas_symm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] prval pf1_gem = fpf1_gem (pf1_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf3_gem) // prval (pf1_sym, fpf1_gem) = SYMAT_v_of_GEMAT_v (pf1_gem, UPLOlower) val () = cblas_symm ( SIDEDIM_R | CblasRowMajor , CblasRight , CblasLower , N, M , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , neg1 (* beta *) , !p3_arr, M ) // end of [val] prval pf1_gem = fpf1_gem (pf1_sym) // prval TRANORDrowcol () = GEMAT_v_trans (pf1_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf3_gem) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) prval pf3_vec = GEVEC_v_of_array_v {a} (pf3_arr) // val diff = cblas_nrm2 (MN, !p3_arr, 1) val () = begin print "symm_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf3_arr = array_v_of_GEVEC_v {a} (pf3_vec) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [symm_test] (* ****** ****** *) extern fun{a,ar:t@ype} trmm_trsm_test (): void // // checking the identity: B = A^{-1} A B // implement{a,ar} // ar = |a| trmm_trsm_test (): void = () where { #define M 13 // needs to be a positive number #define K 13 // needs to be a positive number #define N 17 // needs to be a positive number val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val nrm1 = cblas_nrm2 (KN, !p2_arr, 1) prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val pos1 = of_double (1.0) prval (pf1_trm, fpf1_gem) = TRMAT_v_of_GEMAT_v (pf1_gem, UPLOupper, DIAGunit) val () = cblas_trmm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , CblasNoTrans , CblasUnit , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K ) // end of [val] val () = cblas_trsm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , CblasNoTrans , CblasUnit , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K ) // end of [val] prval pf1_gem = fpf1_gem (pf1_trm) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val nrm2 = cblas_nrm2 (KN, !p2_arr, 1) val diff = $NUM.sub (nrm1, nrm2) prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) val () = begin print "trmm_trsm_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // } // end of [trmm_trsm_test] (* ****** ****** *) extern fun{a,ar:t@ype} hemm_test (): void // // checking the identity A * B = (B^T * A^T)^T // implement{a,ar} // ar = |a| hemm_test (): void = () where { #define M 13 // needs to be a positive number #define K 13 // needs to be a positive number #define N 17 // needs to be a positive number val (pf_MK | MK) = op imul2 (M, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (MK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_MK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // val (pf_KN | KN) = op imul2 (K, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_KN) val (pf2_gc, pf2_arr | p2_arr) = randgen_arr (KN) prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_KN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val (pf_MN | MN) = op imul2 (M, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_MN) val (pf3_gc, pf3_arr | p3_arr) = randgen_arr (MN) prval pf3_fmat = fmatrix_v_of_array_v {a} (pf_MN, pf3_arr) prval (pf3_gem, fpf3_fmat) = GEMAT_v_of_fmatrix_v (pf3_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // prval (pf1_sym, fpf1_gem) = HEMAT_v_of_GEMAT_v (pf1_gem, UPLOupper) val () = cblas_hemm ( SIDEDIM_L | CblasColMajor , CblasLeft , CblasUpper , M, N , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , zero (* beta *) , !p3_arr, M ) // end of [val] prval pf1_gem = fpf1_gem (pf1_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf3_gem) // prval (pf1_sym, fpf1_gem) = HEMAT_v_of_GEMAT_v (pf1_gem, UPLOlower) val () = cblas_hemm ( SIDEDIM_R | CblasRowMajor , CblasRight , CblasLower , N, M , pos1 (* alpha *) , !p1_arr, M , !p2_arr, K , neg1 (* beta *) , !p3_arr, M ) // end of [val] prval pf1_gem = fpf1_gem (pf1_sym) // prval TRANORDrowcol () = GEMAT_v_trans (pf1_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf3_gem) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_MK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_MK, pf1_MK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_KN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_KN, pf2_KN) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) // prval () = pf3_fmat := fpf3_fmat (pf3_gem) prval (pf3_MN, pf3_arr) = array_v_of_fmatrix_v (pf3_fmat) prval () = mul_isfun (pf_MN, pf3_MN) prval pf3_vec = GEVEC_v_of_array_v {a} (pf3_arr) // val diff = cblas_nrm2 (MN, !p3_arr, 1) val () = begin print "hemm_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf3_arr = array_v_of_GEVEC_v {a} (pf3_vec) val () = array_ptr_free (pf3_gc, pf3_arr | p3_arr) } // end of [hemm_test] (* ****** ****** *) extern fun{a,ar:t@ype} herk_test (): void // // checking the identity A * A' = (A')' * A' // implement{a,ar} // ar = |a| herk_test (): void = () where { #define N 17 // needs to be a positive number #define K 29 // needs to be a positive number // val (pf_NK | NK) = op imul2 (N, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NK) val (pf1_gc, pf1_arr | p1_arr) = randgen_arr (NK) prval pf1_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1_arr) prval (pf1_gem, fpf1_fmat) = GEMAT_v_of_fmatrix_v (pf1_fmat) // var zero: a = of_double (0.0) val (pf_NN | NN) = op imul2 (N, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NN) val NN_sz = size1_of_int1 NN val (pf2_gc, pf2_arr | p2_arr) = array_ptr_alloc_tsz {a} (NN_sz, sizeof) // end of [val] val () = array_ptr_initialize_elt_tsz {a} (!p2_arr, NN_sz, zero, sizeof) // end of [val] prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_NN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val zero = of_double (0.0) val pos1 = of_double (1.0) val neg1 = of_double (~1.0) // prval (pf2_sym, fpf2_gem) = HEMAT_v_of_GEMAT_v (pf2_gem, UPLOupper) val () = cblas_herk ( TRANDIM_N | CblasColMajor , CblasUpper , CblasNoTrans , N, K , pos1 (* alpha *) , !p1_arr, N , zero (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval (pf2_sym, fpf2_gem) = HEMAT_v_of_GEMAT_v (pf2_gem, UPLOlower) val () = cblas_herk ( TRANDIM_C | CblasRowMajor , CblasLower , CblasConjTrans , N, K , pos1 (* alpha *) , !p1_arr, N , neg1 (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) prval TRANORDrowcol () = GEMAT_v_trans (pf1_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) // prval () = pf1_fmat := fpf1_fmat (pf1_gem) prval (pf1_NK, pf1_arr) = array_v_of_fmatrix_v (pf1_fmat) prval () = mul_isfun (pf_NK, pf1_NK) val () = array_ptr_free (pf1_gc, pf1_arr | p1_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_NN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_NN, pf2_NN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val diff = cblas_nrm2 (NN, !p2_arr, 1) val () = begin print "herk_test<"; print_typ (); print ","; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [herk_test] (* ****** ****** *) extern fun{a,ar:t@ype} her2k_test (): void // // checking the identity A * B' + B * A' = A' * B'' + B' * A'' // implement{a,ar} // ar = |a| her2k_test (): void = () where { #define N 17 // needs to be a positive number #define K 29 // needs to be a positive number // val (pf_NK | NK) = op imul2 (N, K) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NK) val (pf1A_gc, pf1A_arr | p1A_arr) = randgen_arr (NK) prval pf1A_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1A_arr) prval (pf1A_gem, fpf1A_fmat) = GEMAT_v_of_fmatrix_v (pf1A_fmat) val (pf1B_gc, pf1B_arr | p1B_arr) = randgen_arr (NK) prval pf1B_fmat = fmatrix_v_of_array_v {a} (pf_NK, pf1B_arr) prval (pf1B_gem, fpf1B_fmat) = GEMAT_v_of_fmatrix_v (pf1B_fmat) // var zero: a = of_double (0.0) val (pf_NN | NN) = op imul2 (N, N) // this should not be moved out! prval () = mul_nat_nat_nat (pf_NN) val NN_sz = size1_of_int1 NN val (pf2_gc, pf2_arr | p2_arr) = array_ptr_alloc_tsz {a} (NN_sz, sizeof) // end of [val] val () = array_ptr_initialize_elt_tsz {a} (!p2_arr, NN_sz, zero, sizeof) // end of [val] prval pf2_fmat = fmatrix_v_of_array_v {a} (pf_NN, pf2_arr) prval (pf2_gem, fpf2_fmat) = GEMAT_v_of_fmatrix_v (pf2_fmat) // val pos1 = of_double (1.0) val zero = of_double (0.0) val neg1 = of_double (~1.0) // prval (pf2_sym, fpf2_gem) = HEMAT_v_of_GEMAT_v (pf2_gem, UPLOupper) val () = cblas_her2k ( TRANDIM_N | CblasColMajor , CblasUpper , CblasNoTrans , N, K , pos1 (* alpha *) , !p1A_arr, N , !p1B_arr, N , zero (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) // prval TRANORDcolrow () = GEMAT_v_trans (pf1A_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf1B_gem) prval TRANORDcolrow () = GEMAT_v_trans (pf2_gem) prval (pf2_sym, fpf2_gem) = HEMAT_v_of_GEMAT_v (pf2_gem, UPLOlower) val () = cblas_her2k ( TRANDIM_C | CblasRowMajor , CblasLower , CblasConjTrans , N, K , pos1 (* alpha *) , !p1A_arr, N , !p1B_arr, N , neg1 (* beta *) , !p2_arr, N ) // end of [val] prval () = pf2_gem := fpf2_gem (pf2_sym) prval TRANORDrowcol () = GEMAT_v_trans (pf1A_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf1B_gem) prval TRANORDrowcol () = GEMAT_v_trans (pf2_gem) // prval () = pf1A_fmat := fpf1A_fmat (pf1A_gem) prval (pf1A_NK, pf1A_arr) = array_v_of_fmatrix_v (pf1A_fmat) prval () = mul_isfun (pf_NK, pf1A_NK) val () = array_ptr_free (pf1A_gc, pf1A_arr | p1A_arr) prval () = pf1B_fmat := fpf1B_fmat (pf1B_gem) prval (pf1B_NK, pf1B_arr) = array_v_of_fmatrix_v (pf1B_fmat) prval () = mul_isfun (pf_NK, pf1B_NK) val () = array_ptr_free (pf1B_gc, pf1B_arr | p1B_arr) // prval () = pf2_fmat := fpf2_fmat (pf2_gem) prval (pf2_NN, pf2_arr) = array_v_of_fmatrix_v (pf2_fmat) prval () = mul_isfun (pf_NN, pf2_NN) prval pf2_vec = GEVEC_v_of_array_v {a} (pf2_arr) val diff = cblas_nrm2 (NN, !p2_arr, 1) val () = begin print "her2k_test<"; print_typ (); print ">"; print ": diff = "; print_elt diff; print_newline () end // end of [val] prval pf2_arr = array_v_of_GEVEC_v {a} (pf2_vec) val () = array_ptr_free (pf2_gc, pf2_arr | p2_arr) } // end of [her2k_test] (* ****** ****** *) (* // no longer needed dynload "libats/DATS/genarrays.dats" dynload "libats/DATS/fmatrix.dats" *) (* ****** ****** *) fn level1_test (): void = () where { // val () = rotg_test () val () = rotg_test () (* val () = rotg_test () // ATLAS extension val () = rotg_test () // ATLAS extension *) // val () = rot_test () val () = rot_test () // val () = rotm_test () val () = rotm_test () // val () = asum_test () val () = asum_test () val () = asum_test () val () = asum_test () // val () = iamax_test () val () = iamax_test () val () = iamax_test () val () = iamax_test () // val () = dot_test () val () = dot_test () // val () = dotu_test () val () = dotu_test () val () = dotu_test () val () = dotu_test () // val () = dotc_test () val () = dotc_test () val () = dotc_test () val () = dotc_test () // val () = swap_test () val () = swap_test () val () = swap_test () val () = swap_test () // val () = copy_test () val () = copy_test () val () = copy_test () val () = copy_test () // val () = axpy_test () val () = axpy_test () val () = axpy_test () val () = axpy_test () // val () = scal_test () val () = scal_test () val () = scal_test () val () = scal_test () val () = scal_test () val () = scal_test () // val () = begin print "Testing for BLAS level 1 functions is done."; print_newline () end // end of [val] } // end of [level1] (* ****** ****** *) fn level2_test (): void = () where { val () = gemv_test () val () = gemv_test () val () = gemv_test () val () = gemv_test () // val () = gbmv_test () val () = gbmv_test () val () = gbmv_test () val () = gbmv_test () // val () = trmv_trsv_test () val () = trmv_trsv_test () val () = trmv_trsv_test () val () = trmv_trsv_test () // val () = tbmv_tbsv_test () val () = tbmv_tbsv_test () val () = tbmv_tbsv_test () val () = tbmv_tbsv_test () // val () = tpmv_tpsv_test () val () = tpmv_tpsv_test () val () = tpmv_tpsv_test () val () = tpmv_tpsv_test () // val () = symv_test () val () = symv_test () // val () = ger_test () val () = ger_test () // val () = geru_test () val () = geru_test () val () = geru_test () val () = geru_test () // val () = gerc_test () val () = gerc_test () val () = gerc_test () val () = gerc_test () // val () = hemv_test () val () = hemv_test () val () = hemv_test () val () = hemv_test () // val () = hbmv_test () val () = hbmv_test () val () = hbmv_test () val () = hbmv_test () // val () = hpmv_test () val () = hpmv_test () val () = hpmv_test () val () = hpmv_test () // val () = her_her2_test () val () = her_her2_test () val () = her_her2_test () val () = her_her2_test () // val () = hpr_hpr2_test () val () = hpr_hpr2_test () val () = hpr_hpr2_test () val () = hpr_hpr2_test () // val () = begin print "Testing for BLAS level 2 functions is done."; print_newline () end // end of [val] } // end of [level2] (* ****** ****** *) fn level3_test (): void = () where { // val () = gemm_test () val () = gemm_test () val () = gemm_test () val () = gemm_test () // val () = syrk_test () val () = syrk_test () val () = syrk_test () val () = syrk_test () // val () = syr2k_test () val () = syr2k_test () val () = syr2k_test () val () = syr2k_test () // val () = symm_test () val () = symm_test () val () = symm_test () val () = symm_test () // val () = trmm_trsm_test () val () = trmm_trsm_test () val () = trmm_trsm_test () val () = trmm_trsm_test () // val () = hemm_test () val () = hemm_test () val () = hemm_test () val () = hemm_test () // val () = herk_test () val () = herk_test () val () = herk_test () val () = herk_test () // val () = her2k_test () val () = her2k_test () val () = her2k_test () val () = her2k_test () // val () = begin print "Testing for BLAS level 3 functions is done."; print_newline () end // end of [val] } // end of [level3] (* ****** ****** *) implement main () = () where { // (* val () = srand48_with_time () // this makes it really hard for debugging // *) val () = level1_test () val () = level2_test () val () = level3_test () } // end of [main] (* ****** ****** *) (* end of [cblas_test.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/TEST/test_gemm2.dats0000664000175000017500000000742012223166164022230 0ustar hwxihwxi// // some testing code for the ATS interface to BLAS // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // This example demonstrates how to compute A * A^T (* ****** ****** *) local #include "contrib/cblas/HATS/cblas.hats" in (*empty*) end (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" staload "libats/SATS/fmatrix.sats" staload _(*anonymous*) = "libats/DATS/fmatrix.dats" (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" staload _(*anonymous*) = "contrib/cblas/DATS/cblas.dats" (* ****** ****** *) extern fun{a:t@ype} of_double (x: double):<> a implement of_double (x: double) = float_of_double (x) implement of_double (x: double) = x implement of_double (x) = ccmplx_of_float (float_of_double x) implement of_double (x) = zcmplx_of_double (x) (* ****** ****** *) extern fun{a:t@ype} print_elt (x: a): void implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x implement print_elt (x) = print x (* ****** ****** *) // // C <- A * A^T // fun{t:t@ype} test {v:view} {ord:order} {ma,na:nat} {lda,ldc:pos} {la:addr} ( pf: !v , pfa : GEMAT_v (t, ma, na, ord, lda, la) <= v | Order: CBLAS_ORDER_t ord , M: int ma, N: int na , pA: ptr la, lda: int lda , C: &GEMAT (t, ma, ma, ord, ldc), ldc: int ldc ) : void = cblas_gemm__main ( pf , TRANDIM_N , pfa , TRANDIM_T , pfa | Order , CblasNoTrans, CblasTrans , M, M, N , of_double 1.0 (* alpha *) , pA, lda, pA, lda , of_double 0.0 (* beta *) , C, ldc ) // end of [test] (* ****** ****** *) fn{a:t@ype} print_fmatrix {m,n:nat} ( M: &fmatrix (a, m, n), m: size_t m, n: size_t n ) : void = fmatrix_ptr_iforeach_fun (M, pr, ORDERrow, m, n) where { val pr = lam ( i: size_t, j: size_t, x: &a ) : void = $effmask_all let val () = if j > 0 then print ", " val () = if (i > 0 andalso j = 0) then print "\n" val () = print_elt (x) in // empty end // end of [val] } // end of [fmartrix_ptr_iforeach_fun] // end of [print_fmatrix] (* ****** ****** *) typedef elt = float (* ****** ****** *) val () = () where { val [l:addr] (pfA_gc, pfA_arr | pA_arr) = array_ptr_alloc_tsz {elt} (6, sizeof) // end of [val] var fone = of_double (1.0) val () = array_ptr_initialize_elt_tsz {elt} (!pA_arr, 6, fone, sizeof) // end of [val] prval pf_3x2 = mul_make {3,2} () prval pfA_fmat = fmatrix_v_of_array_v (pf_3x2, pfA_arr) // val () = print "A =\n" val () = print_fmatrix (!pA_arr, 3, 2) val () = print_newline () // prval (pfA_gmat, fpfA_fmat) = GEMAT_v_of_fmatrix_v (pfA_fmat) var !pC with pfC_arr = @[elt][9](of_double 0.0) prval pf_3x3 = mul_make {3,3} () prval pfC_fmat = fmatrix_v_of_array_v (pf_3x3, pfC_arr) prval (pfC_gmat, fpfC_fmat) = GEMAT_v_of_fmatrix_v (pfC_fmat) // viewdef V = GEMAT_v (elt, 3, 2, col, 3, l) val () = test {V} (pfA_gmat, vsubr_refl {V} () | CblasColMajor, 3, 2, pA_arr, 3, !pC, 3) (* end of [val] *) // prval pfA_fmat = fpfA_fmat (pfA_gmat) prval (pf2_3x2, pfA_arr) = array_v_of_fmatrix_v (pfA_fmat) prval () = mul_isfun (pf_3x2, pf2_3x2) val () = array_ptr_free (pfA_gc, pfA_arr | pA_arr) // prval () = pfC_fmat := fpfC_fmat (pfC_gmat) // val () = print "C =\n" val () = print_fmatrix (!pC, 3, 3) val () = print_newline () // prval (pf2_3x3, pfC2_arr) = array_v_of_fmatrix_v (pfC_fmat) prval () = mul_isfun (pf2_3x3, pf_3x3) prval () = pfC_arr := pfC2_arr } // end of [main] (* ****** ****** *) implement main () = () (* ****** ****** *) (* end of [gemm2_test.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/SATS/0000700000175000017500000000000012223166163017260 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/SATS/cblas_extra.sats0000664000175000017500000000315112223166163022457 0ustar hwxihwxi(* ** ** Some functions provided for convenience ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libats/SATS/genarrays.sats" (* ****** ****** *) // // SC: Fill square matrix with identity diagnal // fun{a:t@ype} GEMAT_ptr_initialize_eye {ord:order} {m:nat} {lda:inc} ( ord: ORDER ord, m: size_t m , A: &GEMAT (a?, m, m, ord, lda) >> GEMAT (a, m, m, ord, lda) , lda: size_t lda ) :<> void // end of [GEMAT_ptr_initialize_eye] (* ****** ****** *) // // Y <- alpha * X + Y // fun{a:t@ype} GEMAT_axpy {ord:order} {m,n:nat} {ldx,ldy:inc} ( ord: ORDER ord , m: size_t m, n: size_t n , alpha: a , X: &GEMAT (a, m, n, ord, ldx), ldx: size_t ldx , Y: &GEMAT (a, m, n, ord, ldy), ldy: size_t ldy ) :<> void // end of [GEMAT_axpy] (* ****** ****** *) // // A <- diag(D) * A // fun{a1,a2:t@ype} // |a1| = a2 GEMAT_scal_row {ord:order} {m,n:nat} {lda:inc} ( ord: ORDER ord, m: size_t m, n: size_t n , D: &(@[a2][m]), A: &GEMAT (a1, m, n, ord, lda), lda: size_t lda ) :<> void // end of [[GEMAT_scal_row] (* ****** ****** *) // // A <- A * diag(D) // fun{a1,a2:t@ype} // |a1| = a2 GEMAT_scal_col {ord:order} {m,n:nat} {lda:inc} ( ord: ORDER ord, m: size_t m, n: size_t n , A: &GEMAT (a1, m, n, ord, lda), lda: size_t lda, D: &(@[a2][n]) ) :<> void // end of [[GEMAT_scal_col] (* ****** ****** *) (* end of [cblas_extra.sats] *) ats-lang-anairiats-0.2.11/contrib/cblas/SATS/cblas.sats0000664000175000017500000024330312223166163021261 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libc/CATS/complex.cats" // it needs to be loaded before [cblas.cats] #include "contrib/cblas/CATS/cblas.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) staload GA = "libats/SATS/genarrays.sats" // sortdef inc = $GA.inc // sortdef order = $GA.order // stadef row = $GA.row stadef col = $GA.col stadef ORDER = $GA.ORDER // sortdef uplo = $GA.uplo stadef upper = $GA.upper stadef lower = $GA.lower stadef UPLO = $GA.UPLO // sortdef diag = $GA.diag stadef unit = $GA.unit () stadef nonunit = $GA.nonunit () stadef DIAG = $GA.DIAG // sortdef transpose = $GA.transpose stadef TPN = $GA.TPN stadef TPT = $GA.TPT stadef TPC = $GA.TPC stadef TRANSPOSE = $GA.TRANSPOSE // sortdef side = $GA.side stadef left = $GA.left stadef right = $GA.right stadef SIDE = $GA.SIDE // stadef GEVEC = $GA.GEVEC stadef GEMAT = $GA.GEMAT stadef GEMAT_v = $GA.GEMAT_v stadef GBMAT = $GA.GBMAT stadef TRMAT = $GA.TRMAT stadef TBMAT = $GA.TBMAT stadef TPMAT = $GA.TPMAT stadef SYMAT = $GA.SYMAT stadef SBMAT = $GA.SBMAT stadef SPMAT = $GA.SPMAT stadef HEMAT = $GA.HEMAT stadef HBMAT = $GA.HBMAT stadef HPMAT = $GA.HPMAT // stadef trandim_p = $GA.trandim_p stadef sidedim_p = $GA.sidedim_p // (* ****** ****** *) abst@ype CBLAS_ORDER_t (order) = int (* val CblasRowMajor : CBLAS_ORDER_t (row) val CblasColMajor : CBLAS_ORDER_t (col) *) macdef CblasRowMajor = $extval (CBLAS_ORDER_t row, "CblasRowMajor") macdef CblasColMajor = $extval (CBLAS_ORDER_t col, "CblasColMajor") (* // HX: it not implemented because it is not needed yet fun eq_CBLAS_ORDER_ORDER {ord1,ord2:order} (x1: CBLAS_ORDER_t ord1, x2: CBLAS_ORDER_t ord2):<> bool (ord1==ord2) = "atsctrb_eq_CBLAS_ORDER_ORDER" overload = with eq_CBLAS_ORDER_ORDER *) // implemented in [clbas.dats] fun CBLAS_ORDER_of_ORDER {ord:order} (x: ORDER ord):<> CBLAS_ORDER_t ord (* // implemented in [clbas.dats] fun OrderOfCblasOrder {ord:order} (x: CBLAS_ORDER_t ord):<> ORDER ord = "atsctrb_OrderOfCblasOrder" // end of [OrderOfCblasOrder] *) (* ****** ****** *) abst@ype CBLAS_UPLO_t (uplo) = int (* val CblasUpper : CBLAS_UPLO_t (upper) val CblasLower : CBLAS_UPLO_t (lower) *) macdef CblasUpper = $extval (CBLAS_UPLO_t upper, "CblasUpper") macdef CblasLower = $extval (CBLAS_UPLO_t lower, "CblasLower") (* fun eq_CBLAS_UPLO_UPLO {ul1,ul2:uplo} (x1: CBLAS_UPLO_t ul1, x2: CBLAS_UPLO_t ul2):<> bool (ul1==ul2) = "atsctrb_eq_CBLAS_UPLO_UPLO" overload = with eq_CBLAS_UPLO_UPLO *) // implemented in [clbas.dats] fun CBLAS_UPLO_of_UPLO {ul:uplo} (x: UPLO ul):<> CBLAS_UPLO_t ul (* ****** ****** *) abst@ype CBLAS_DIAG_t (diag) = int (* val CblasUnit : CBLAS_DIAG_t (unit) val CblasNonUnit : CBLAS_DIAG_t (nonunit) *) macdef CblasUnit = $extval (CBLAS_DIAG_t(unit), "CblasUnit") macdef CblasNonUnit = $extval (CBLAS_DIAG_t(nonunit), "CblasNonUnit") (* fun eq_CBLAS_DIAG_DIAG {dg1,dg2:diag} (x1: CBLAS_DIAG_t dg1, x2: CBLAS_DIAG_t dg2):<> bool (dg1==dg2) = "atsctrb_eq_CBLAS_DIAG_DIAG" overload = with eq_CBLAS_DIAG_DIAG *) // // HX: implemented in [clbas.dats] // fun CBLAS_DIAG_of_DIAG {dg:diag} (x: DIAG dg):<> CBLAS_DIAG_t dg (* ****** ****** *) abst@ype CBLAS_TRANSPOSE_t (transpose) = int (* val CblasNoTrans : CBLAS_TRANSPOSE_t (N) val CblasTrans : CBLAS_TRANSPOSE_t (T) val CblasConjTrans : CBLAS_TRANSPOSE_t (CT) val AtlasConj : CBLAS_TRANSPOSE_t (AC) // not used *) macdef CblasNoTrans = $extval (CBLAS_TRANSPOSE_t (TPN), "CblasNoTrans") // end of [macdef] macdef CblasTrans = $extval (CBLAS_TRANSPOSE_t (TPT), "CblasTrans") // end of [macdef] macdef CblasConjTrans = $extval (CBLAS_TRANSPOSE_t (TPC), "CblasConjTrans") // end of [macdef] (* macdef AtlasConj = $extval (CBLAS_TRANSPOSE_t (AC), "AtlasConj") // end of [macdef] *) (* fun eq_CBLAS_TRANSPOSE_TRANSPOSE {tr1,tr2:transpose} (x1: CBLAS_TRANSPOSE_t tr1, x2: CBLAS_TRANSPOSE_t tr2):<> bool (tr1==tr2) = "atsctrb_eq_CBLAS_TRANSPOSE_TRANSPOSE" overload = with eq_CBLAS_TRANSPOSE_TRANSPOSE *) fun // implemented in [clbas.dats] CBLAS_TRANSPOSE_of_TRANSPOSE {tr:transpose} (x: TRANSPOSE tr):<> CBLAS_TRANSPOSE_t tr // end of [fun] (* ****** ****** *) abst@ype CBLAS_SIDE_t (side) = int (* val CblasLeft : CBLAS_SIDE_t (left) val CblasRight : CBLAS_SIDE_t (right) *) macdef CblasLeft = $extval (CBLAS_SIDE_t left, "CblasLeft") macdef CblasRight = $extval (CBLAS_SIDE_t right, "CblasRight") (* fun eq_CBLAS_SIDE_SIDE {lr1,lr2:side} (x1: CBLAS_SIDE_t lr1, x2: CBLAS_SIDE_t lr2):<> bool (lr1==lr2) = "atsctrb_eq_CBLAS_SIDE_SIDE" overload = with eq_CBLAS_SIDE_SIDE *) fun // implemented in [clbas.dats] CBLAS_SIDE_of_SIDE {lr:side} (x: SIDE lr):<> CBLAS_SIDE_t lr // end of [CBLAS_SIDE_of_SIDE] (* ****** ****** *) // // BLAS level 1 // (* ****** ****** *) // // ROTG: S, D, C, Z // (* void cblas_drotg (double *a, double *b, double *c, double *s); // end of [cblas-drotg] *) // // givens(c, s) [a b]' -> [a 0] // fun{t:t@ype} cblas_rotg (a: &t, b: &t, c: &t? >> t, s: &t? >> t) :<> void // end of [cblas_rotg] fun cblas_srotg ( // givens(c, s) [a b]' -> [a 0] a: &float, b: &float , c: &float? >> float, s: &float? >> float ) :<> void = "mac#atsctrb_cblas_srotg" // end of [cblas_srotg] fun cblas_drotg ( // givens(c, s) [a b]' -> [a 0] a: &double, b: &double , c: &double? >> double, s: &double? >> double ) :<> void = "mac#atsctrb_cblas_drotg" // end of [cblas_drotg] fun cblas_crotg ( // givens(c, s) [a b]' -> [a 0] a: &ccmplx, b: &ccmplx , c: &ccmplx? >> ccmplx, s: &ccmplx? >> ccmplx ) :<> void = "mac#atsctrb_cblas_crotg" // end of [cblas_crotg] fun cblas_zrotg ( // givens(c, s) [a b]' -> [a 0] a: &zcmplx, b: &zcmplx , c: &zcmplx? >> zcmplx, s: &zcmplx? >> zcmplx ) :<> void = "mac#atsctrb_cblas_zrotg" // end of [cblas_zrotg] (* ****** ****** *) // // ROTMG: S, D // (* void cblas_drotmg ( double *d1, double *d2 , double *b1, const double b2 , double *P ) ; *) // // mod_givens(P) [sqrt(d1)*b1 sqrt(d2)*b2]' -> [a 0] // fun{a:t@ype} cblas_rotmg ( d1: &a, d2: &a, b1: &a, b2: a, P: &GEVEC (a, 5, 1) ) :<> void // end of [cblas_rotmg] fun cblas_srotmg ( d1: &float, d2: &float , b1: &float, b2: float , P: &GEVEC (float, 5, 1) ) :<> void = "mac#atsctrb_cblas_srotmg" // end of [cblas_srotmg] fun cblas_drotmg ( d1: &double, d2: &double , b1: &double, b2: double , P: &GEVEC (double, 5, 1) ) :<> void = "mac#atsctrb_cblas_drotmg" // end of [cblas_srotmg] (* ****** ****** *) // // ROT: S, D, CS, ZD // (* void cblas_drot ( const int N , double *X, const int incX , double *Y, const int incY , const double c, const double s ) ; void cblas_zdrot ( const int N , void *X, const int incX , void *Y, const int incY , const double c, const double s ) ; *) fun{a:t@ype} cblas_rot // givens(c, s) [x y]' {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) , c: a, s: a ) :<> void // end of [cblas_rot] fun cblas_srot {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx), incX: int (dx) , Y: &GEVEC (float, n, dy), incY: int (dy) , c: float, s: float ) :<> void = "mac#atsctrb_cblas_srot" // end of [cblas_srot] fun cblas_drot {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (double, n, dx), incX: int (dx) , Y: &GEVEC (double, n, dy), incY: int (dy) , c: double, s: double ) :<> void = "mac#atsctrb_cblas_drot" // end of [cblas_drot] (* // not in CBLAS proper fun cblas_csrot {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (ccmplx, n, dx), incX: int (dx) , Y: &GEVEC (ccmplx, n, dy), incY: int (dy) , c: float, s: float ) :<> void = "mac#atsctrb_cblas_csrot" // end of [cblas_csrot] fun cblas_zdrot {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (zcmplx, n, dx), incX: int (dx) , Y: &GEVEC (zcmplx, n, dy), incY: int (dy) , c: double, s: double ) :<> void = "mac#atsctrb_cblas_zdrot" // end of [cblas_zdrot] *) (* ****** ****** *) // // ROTM: S, D // (* void cblas_drotm ( const int N , double *X, const int incX , double *Y, const int incY , const double *P ) ; *) fun{a:t@ype} cblas_rotm // mod_givens(P) [x y]' {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) , P: &GEVEC (a, 5, 1) ) :<> void // end of [cblas_rotm] fun cblas_srotm {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx), incX: int (dx) , Y: &GEVEC (float, n, dy), incY: int (dy) , P: &GEVEC (float, 5, 1) ) :<> void = "mac#atsctrb_cblas_srotm" // end of [cblas_srotm] fun cblas_drotm {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (double, n, dx), incX: int (dx) , Y: &GEVEC (double, n, dy), incY: int (dy) , P: &GEVEC (double, 5, 1) ) :<> void = "mac#atsctrb_cblas_drotm" // end of [cblas_drotm] (* ****** ****** *) // // DOT: S, D // (* // taken from [cblas.h] double cblas_ddot( const int N , const double *X, const int incX , const double *Y, const int incY ) ; *) fun{a:t@ype} cblas_dot // dot product {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) ) :<> a // end of [cblas_dot] fun cblas_sdot // dot product for single precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx), incX: int (dx) , Y: &GEVEC (float, n, dy), incY: int (dy) ) :<> float = "mac#atsctrb_cblas_sdot" fun cblas_ddot // dot product for double precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (double, n, dx), incX: int (dx) , Y: &GEVEC (double, n, dy), incY: int (dy) ) :<> double = "mac#atsctrb_cblas_ddot" // end of [fun] (* ****** ****** *) (* float cblas_sdsdot( const int N, const float alpha , const float *X, const int incX , const float *Y, const int incY ) ; double cblas_dsdot( const int N , const float *X, const int incX , const float *Y, const int incY ) ; *) // dot product for fun cblas_sdsdot // single precision computed in double precision {n:nat} {dx,dy:inc} ( N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int (dx) , Y: &GEVEC (float, n, dy), incY: int (dy) ) :<> float = "mac#atsctrb_cblas_sdsdot" // end of [cblas_sdsdot] // dot product for fun cblas_dsdot // single precision computed in double precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx), incX: int (dx) , Y: &GEVEC (float, n, dy), incY: int (dy) ) :<> double = "mac#atsctrb_cblas_dsdot" // end of [cblas_dsdot] (* ****** ****** *) // // DOTU_SUB: C, Z // (* void cblas_cdotu_sub( const int N , const void *X, const int incX , const void *Y, const int incY , void *dotu ) ; *) fun{a:t@ype} cblas_dotu_sub // dot product for complex {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) , dotu: &a? >> a ) :<> void // end of [cblas_dotu_sub] fun cblas_cdotu_sub // dot product for complex single precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (ccmplx, n, dx), incX: int (dx) , Y: &GEVEC (ccmplx, n, dy), incY: int (dy) , dotu: &ccmplx? >> ccmplx ) :<> void = "mac#atsctrb_cblas_cdotu_sub" // end of [cblas_cdotu_sub] fun cblas_zdotu_sub // dot product for complex double precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (zcmplx, n, dx), incX: int (dx) , Y: &GEVEC (zcmplx, n, dy), incY: int (dy) , dotu: &zcmplx? >> zcmplx ) :<> void = "mac#atsctrb_cblas_zdotu_sub" // end of [cblas_zdotu_sub] (* ****** ****** *) // // DOTU_SUB: C, Z // (* void cblas_cdotc_sub ( const int N , const void *X, const int incX , const void *Y, const int incY , void *dotc ) ; *) fun{a:t@ype} cblas_dotc_sub // conjugate dot product for complex {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) , dotc: &a? >> a ) :<> void // end of [cblas_dotc_sub] fun cblas_cdotc_sub // conjugate dot product for complex single precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (ccmplx, n, dx), incX: int (dx) , Y: &GEVEC (ccmplx, n, dy), incY: int (dy) , dotc: &ccmplx? >> ccmplx ) :<> void = "mac#atsctrb_cblas_cdotc_sub" // end of [cblas_cdotc_sub] fun cblas_zdotc_sub // conjugate dot product for complex double precision {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (zcmplx, n, dx), incX: int (dx) , Y: &GEVEC (zcmplx, n, dy), incY: int (dy) , dotc: &zcmplx? >> zcmplx ) :<> void = "mac#atsctrb_cblas_zdotc_sub" // end of [cblas_zdotc_sub] (* ****** ****** *) // // DOTU: C, Z // extended with S, D // fun{a:t@ype} cblas_dotu // dot product unconjugated {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) ) :<> a // end of [cblas_dotu] // // DOTC: C, Z // extended with S, D // fun{a:t@ype} cblas_dotc // dot product conjugated {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int (dx) , Y: &GEVEC (a, n, dy), incY: int (dy) ) :<> a // end of [cblas_dotc] (* ****** ****** *) // // SNRM2: S, D, SC, DZ // (* float cblas_snrm2(const int N, const float *X, const int incX); double cblas_dnrm2(const int N, const double *X, const int incX); float cblas_scnrm2(const int N, const void *X, const int incX); double cblas_dznrm2(const int N, const void *X, const int incX); *) fun{a1,a2:t@ype} cblas_nrm2 {n:nat} {dx:inc} ( N: int n, X: &GEVEC (a2, n, dx), incX: int dx ) :<> a1 // end of [atsctrb_cblas_nrm2] fun cblas_snrm2 {n:nat} {dx:inc} ( N: int n, X: &GEVEC (float, n, dx), incX: int dx ) :<> float = "mac#atsctrb_cblas_snrm2" // end of [cblas_snrm2] fun cblas_dnrm2 {n:nat} {dx:inc} ( N: int n, X: &GEVEC (double, n, dx), incX: int dx ) :<> double = "mac#atsctrb_cblas_dnrm2" // end of [cblas_dnrm2] fun cblas_scnrm2 {n:nat} {dx:inc} ( N: int n, X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> float = "mac#atsctrb_cblas_scnrm2" // end of [cblas_scnrm2] fun cblas_dznrm2 {n:nat} {dx:inc} ( N: int n, X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> double = "mac#atsctrb_cblas_dznrm2" // end of [cblas_dznrm2] (* ****** ****** *) // // ASUM: S, D, SC, DZ // (* float cblas_sasum(const int N, const float *X, const int incX); double cblas_dasum(const int N, const double *X, const int incX); float cblas_scasum(const int N, const void *X, const int incX); double cblas_dzasum(const int N, const void *X, const int incX); *) fun{a1,a2:t@ype} cblas_asum // 1-norm of a vector {n:nat} {dx:inc} ( N: int n, X: &GEVEC (a1, n, dx), incX: int dx ) :<> a2 // end of [atsctrb_cblas_asum] fun cblas_sasum // 1-norm of a vector in single precision {n:nat} {dx:inc} ( N: int n, X: &GEVEC (float, n, dx), incX: int dx ) :<> float = "mac#atsctrb_cblas_sasum" // end of [cblas_sasum] fun cblas_dasum // 1-norm of a vector in double precision {n:nat} {dx:inc} ( N: int n, X: &GEVEC (double, n, dx), incX: int dx ) :<> double = "mac#atsctrb_cblas_dasum" // end of [cblas_dasum] fun cblas_scasum // 1-norm of a vector in single precision complex {n:nat} {dx:inc} ( N: int n, X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> float = "mac#atsctrb_cblas_scasum" // end of [cblas_scasum] fun cblas_dzasum // 1-norm of a vector in double precision complex {n:nat} {dx:inc} ( N: int n, X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> double = "mac#atsctrb_cblas_dzasum" // end of [cblas_dzasum] (* ****** ****** *) // // IAMAX: S, D, C, Z // (* #define CBLAS_INDEX int CBLAS_INDEX cblas_isamax(const int N, const float *X, const int incX); CBLAS_INDEX cblas_idamax(const int N, const double *X, const int incX); CBLAS_INDEX cblas_icamax(const int N, const void *X, const int incX); CBLAS_INDEX cblas_izamax(const int N, const void *X, const int incX); *) typedef CBLAS_INDEX = int // should it be made abstract? fun{a:t@ype} cblas_iamax // arg infty-norm of a vector {n:nat} {dx:inc} ( N: int n, X: &GEVEC (a, n, dx), incX: int dx ) :<> CBLAS_INDEX // end of [atsctrb_cblas_iamax] fun cblas_isamax // arg infty-norm of a vector in single precision {n:nat} {dx:inc} ( N: int n, X: &GEVEC (float, n, dx), incX: int dx ) :<> CBLAS_INDEX = "mac#atsctrb_cblas_isamax" // end of [fun] fun cblas_idamax // arg infty-norm of a vector in double precision {n:nat} {dx:inc} ( N: int n, X: &GEVEC (double, n, dx), incX: int dx ) :<> CBLAS_INDEX = "mac#atsctrb_cblas_idamax" // end of [fun] fun cblas_icamax // arg infty-norm of a vector in single precision complex {n:nat} {dx:inc} ( N: int n, X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> CBLAS_INDEX = "mac#atsctrb_cblas_icamax" // end of [fun] fun cblas_izamax // arg infty-norm of a vector in double precision complex {n:nat} {dx:inc} ( N: int n, X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> CBLAS_INDEX = "mac#atsctrb_cblas_izamax" // end of [fun] (* ****** ****** *) // // SWAP: S, D, C, Z // (* void cblas_dswap ( const int N , double *X, const int incX , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_swap // X <-> Y {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_swap] fun cblas_sswap {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx), incX: int dx , Y: &GEVEC (float, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_sswap" // end of [fun] fun cblas_dswap {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (double, n, dx), incX: int dx , Y: &GEVEC (double, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dswap" // end of [fun] fun cblas_cswap {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (ccmplx, n, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_cswap" // end of [fun] fun cblas_zswap {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (zcmplx, n, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zswap" // end of [fun] (* ****** ****** *) // // COPY: S, D, C, Z // (* void cblas_dcopy ( const int N , const double *X , const int incX , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_copy // copy vector X to Y (Y <- X) {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (a, n, dx) , incX: int dx , Y: &GEVEC (a?, n, dy) >> GEVEC (a, n, dy) , incY: int dy ) :<> void // end of [cblas_copy] fun cblas_scopy {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (float, n, dx) , incX: int dx , Y: &GEVEC (float?, n, dy) >> GEVEC (float, n, dy) , incY: int dy ) :<> void = "mac#atsctrb_cblas_scopy" // end of [fun] fun cblas_dcopy {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (double, n, dx) , incX: int dx , Y: &GEVEC (double?, n, dy) >> GEVEC (double, n, dy) , incY: int dy ) :<> void = "mac#atsctrb_cblas_dcopy" // end of [fun] fun cblas_ccopy {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (ccmplx, n, dx) , incX: int dx , Y: &GEVEC (ccmplx?, n, dy) >> GEVEC (ccmplx, n, dy) , incY: int dy ) :<> void = "mac#atsctrb_cblas_ccopy" // end of [fun] fun cblas_zcopy {n:nat} {dx,dy:inc} ( N: int n , X: &GEVEC (zcmplx, n, dx) , incX: int dx , Y: &GEVEC (zcmplx?, n, dy) >> GEVEC (zcmplx, n, dy) , incY: int dy ) :<> void = "mac#atsctrb_cblas_zcopy" // end of [fun] (* ****** ****** *) // // AXPY: S, D, C, Z // (* void cblas_daxpy ( const int N , const double alpha , const double *X, const int incX , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_axpy // Y <- alpha * X + Y {n:nat} {dx,dy:inc} ( N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_axpy] fun cblas_saxpy {n:nat} {dx,dy:inc} ( N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int dx , Y: &GEVEC (float, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_saxpy" // end of [fun] fun cblas_daxpy {n:nat} {dx,dy:inc} ( N: int n , alpha: double , X: &GEVEC (double, n, dx), incX: int dx , Y: &GEVEC (double, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_daxpy" // end of [fun] fun cblas_caxpy {n:nat} {dx,dy:inc} ( N: int n , alpha: &ccmplx , X: &GEVEC (ccmplx, n, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_caxpy" // end of [fun] fun cblas_zaxpy {n:nat} {dx,dy:inc} ( N: int n , alpha: &zcmplx , X: &GEVEC (zcmplx, n, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zaxpy" // end of [fun] (* ****** ****** *) // // SCAL: S, D, C, Z, CS, ZD // (* void cblas_sscal(const int N, const float alpha, float *X, const int incX); void cblas_dscal(const int N, const double alpha, double *X, const int incX); void cblas_cscal(const int N, const void *alpha, void *X, const int incX); void cblas_zscal(const int N, const void *alpha, void *X, const int incX); void cblas_csscal(const int N, const float alpha, void *X, const int incX); void cblas_zdscal(const int N, const double alpha, void *X, const int incX); *) fun{a1,a2:t@ype} cblas_scal // X <- alpha * X {n:nat} {dx:inc} ( N: int n, alpha: a2 , X: &GEVEC (a1, n, dx), incX: int (dx) ) :<> void // end of [cblas_scal] fun cblas_sscal {n:nat} {dx:inc} ( N: int n, alpha: float , X: &GEVEC (float, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_sscal" // end of [fun] fun cblas_dscal {n:nat} {dx:inc} ( N: int n, alpha: double , X: &GEVEC (double, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_dscal" // end of [fun] fun cblas_cscal {n:nat} {dx:inc} ( N: int n, alpha: &ccmplx , X: &GEVEC (ccmplx, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_cscal" // end of [fun] fun cblas_zscal {n:nat} {dx:inc} ( N: int n, alpha: &zcmplx , X: &GEVEC (zcmplx, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_zscal" // end of [fun] fun cblas_csscal {n:nat} {dx:inc} ( N: int n, alpha: float , X: &GEVEC (ccmplx, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_csscal" // end of [fun] fun cblas_zdscal {n:nat} {dx:inc} ( N: int n, alpha: double , X: &GEVEC (zcmplx, n, dx), incX: int (dx) ) :<> void = "mac#atsctrb_cblas_zdscal" // end of [fun] (* ****** ****** *) // // BLAS level 2 // (* ****** ****** *) // // GEMV: S, D, C, Z // (* void cblas_dgemv ( const enum CBLAS_ORDER Order , const enum CBLAS_TRANSPOSE TransA , const int M, const int N , const double alpha , const double *A, const int lda , const double *X, const int incX , const double beta , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_gemv {ord:order} {trA:transpose} {ma,na:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , alpha: a , A: &GEMAT (a, ma, na, ord, lda), lda: int lda , X: &GEVEC (a, nx, dx), incX: int dx , beta: a , Y: &GEVEC (a, ny, dy), incY: int dy ) :<> void // end of [cblas_gemv] fun cblas_sgemv {ord:order} {trA:transpose} {ma,na:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , alpha: float , A: &GEMAT (float, ma, na, ord, lda), lda: int lda , X: &GEVEC (float, nx, dx), incX: int dx , beta: float , Y: &GEVEC (float, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_sgemv" // end of [fun] fun cblas_dgemv {ord:order} {trA:transpose} {ma,na:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , alpha: double , A: &GEMAT (double, ma, na, ord, lda), lda: int lda , X: &GEVEC (double, nx, dx), incX: int dx , beta: double , Y: &GEVEC (double, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dgemv" // end of [fun] fun cblas_cgemv {ord:order} {trA:transpose} {ma,na:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , alpha: &ccmplx , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , X: &GEVEC (ccmplx, nx, dx), incX: int dx , beta: &ccmplx , Y: &GEVEC (ccmplx, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_cgemv" // end of [fun] fun cblas_zgemv {ord:order} {trA:transpose} {ma,na:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , alpha: &zcmplx , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , X: &GEVEC (zcmplx, nx, dx), incX: int dx , beta: &zcmplx , Y: &GEVEC (zcmplx, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zgemv" // end of [fun] (* ****** ****** *) // // GBMV: S, D, C, Z // (* void cblas_dgbmv ( const enum CBLAS_ORDER Order , const enum CBLAS_TRANSPOSE TransA , const int M, const int N , const int KL, const int KU , const double alpha , const double *A, const int lda , const double *X, const int incX , const double beta , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_gbmv {ord:order} {trA:transpose} {ma,na:nat} {kl,ku:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , KL: int kl, KU: int ku , alpha: a , A: &GBMAT (a, ma, na, ord, kl, ku, lda), lda: int lda , X: &GEVEC (a, nx, dx), incX: int dx , beta: a , Y: &GEVEC (a, ny, dy), incY: int dy ) :<> void // end of [cblas_gbmv] fun cblas_sgbmv {ord:order} {trA:transpose} {ma,na:nat} {kl,ku:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , KL: int kl, KU: int ku , alpha: float , A: &GBMAT (float, ma, na, ord, kl, ku, lda), lda: int lda , X: &GEVEC (float, nx, dx), incX: int dx , beta: float , Y: &GEVEC (float, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_sgbmv" // end of [fun] fun cblas_dgbmv {ord:order} {trA:transpose} {ma,na:nat} {kl,ku:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , KL: int kl, KU: int ku , alpha: double , A: &GBMAT (double, ma, na, ord, kl, ku, lda), lda: int lda , X: &GEVEC (double, nx, dx), incX: int dx , beta: double , Y: &GEVEC (double, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dgbmv" // end of [fun] fun cblas_cgbmv {ord:order} {trA:transpose} {ma,na:nat} {kl,ku:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , KL: int kl, KU: int ku , alpha: &ccmplx , A: &GBMAT (ccmplx, ma, na, ord, kl, ku, lda), lda: int lda , X: &GEVEC (ccmplx, nx, dx), incX: int dx , beta: &ccmplx , Y: &GEVEC (ccmplx, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_cgbmv" // end of [fun] fun cblas_zgbmv {ord:order} {trA:transpose} {ma,na:nat} {kl,ku:nat} {lda:pos} {nx,ny:nat} {dx,dy:inc} ( pfa: trandim_p (trA, ma, na, ny, nx) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , M: int ma, N: int na , KL: int kl, KU: int ku , alpha: &zcmplx , A: &GBMAT (zcmplx, ma, na, ord, kl, ku, lda), lda: int lda , X: &GEVEC (zcmplx, nx, dx), incX: int dx , beta: &zcmplx , Y: &GEVEC (zcmplx, ny, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zgbmv" // end of [fun] (* ****** ****** *) // // TRMV: S, D, C, Z // (* void cblas_dtrmv( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag, , const int N , const double *A, const int lda , double *X, const int incX ) ; *) fun{a:t@ype} cblas_trmv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (a, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_trmv] fun cblas_strmv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (float, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_strmv" // end of [fun] fun cblas_dtrmv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (double, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtrmv" // end of [fun] fun cblas_ctrmv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (ccmplx, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctrmv" // end of [fun] fun cblas_ztrmv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (zcmplx, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztrmv" // end of [fun] (* ****** ****** *) // // TBMV: S, D, C, Z // (* void cblas_dtbmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int N, const int K , const double *A, const int lda , double *X, const int incX ) ; *) fun{a:t@ype} cblas_tbmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (a, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_tbmv] fun cblas_stbmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (float, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_stbmv" // end of [fun] fun cblas_dtbmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (double, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtbmv" // end of [fun] fun cblas_ctbmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (ccmplx, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctbmv" // end of [fun] fun cblas_ztbmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (zcmplx, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztbmv" // end of [fun] (* ****** ****** *) // // TPMV: S, D, C, Z // (* void cblas_dtpmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int N , const double *Ap , double *X, const int incX ) ; *) fun{a:t@ype} cblas_tpmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (a, n, ord, ul, dg) , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_tpmv] fun cblas_stpmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (float, n, ord, ul, dg) , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_stpmv" // end of [fun] fun cblas_dtpmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (double, n, ord, ul, dg) , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtpmv" // end of [fun] fun cblas_ctpmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n , Ap: &TPMAT (ccmplx, n, ord, ul, dg) , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctpmv" // end of [fun] fun cblas_ztpmv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n , Ap: &TPMAT (zcmplx, n, ord, ul, dg) , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztpmv" // end of [fun] (* ****** ****** *) // // TRSV: S, D, C, Z // (* void cblas_dtrsv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int N , const double *A, const int lda , double *X, const int incX ) ; *) fun{a:t@ype} cblas_trsv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (a, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_trsv] fun cblas_strsv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (float, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_strsv" // end of [fun] fun cblas_dtrsv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (double, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtrsv" // end of [fun] fun cblas_ctrsv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (ccmplx, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctrsv" // end of [fun] fun cblas_ztrsv {ord:order} {ul:uplo} {trA:transpose} {dg:diag} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , A: &TRMAT (zcmplx, n, ord, ul, dg, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztrsv" // end of [fun] (* ****** ****** *) // // TBSV: S, D, C, Z // (* void cblas_dtbsv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int N, const int K , const double *A, const int lda , double *X, const int incX ) ; *) fun{a:t@ype} cblas_tbsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (a, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_tbsv] fun cblas_stbsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (float, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_stbsv" // end of [fun] fun cblas_dtbsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (double, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtbsv" // end of [fun] fun cblas_ctbsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (ccmplx, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctbsv" // end of [fun] fun cblas_ztbsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {k:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n, K: int k , A: &TBMAT (zcmplx, n, ord, ul, dg, k, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztbsv" // end of [fun] (* ****** ****** *) // // TPSV: S, D, C, Z // (* void cblas_dtpsv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int N , const double *Ap , double *X, const int incX ) ; *) fun{a:t@ype} cblas_tpsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (a, n, ord, ul, dg) , X: &GEVEC (a, n, dx), incX: int dx ) :<> void // end of [cblas_tpsv] fun cblas_stpsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (float, n, ord, ul, dg) , X: &GEVEC (float, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_stpsv" // end of [fun] fun cblas_dtpsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , TransA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , N: int n , Ap: &TPMAT (double, n, ord, ul, dg) , X: &GEVEC (double, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_dtpsv" // end of [fun] fun cblas_ctpsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n , Ap: &TPMAT (ccmplx, n, ord, ul, dg) , X: &GEVEC (ccmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ctpsv" // end of [fun] fun cblas_ztpsv {ord:order} {ul:uplo} {dg:diag} {trA:transpose} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , TransA: CBLAS_TRANSPOSE_t trA , Diag: CBLAS_DIAG_t dg , N: int n , Ap: &TPMAT (zcmplx, n, ord, ul, dg) , X: &GEVEC (zcmplx, n, dx), incX: int dx ) :<> void = "mac#atsctrb_cblas_ztpsv" // end of [fun] (* ****** ****** *) // // SYMV: S, D // (* void cblas_dsymv( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const double alpha , const double *A, const int lda , const double *X, const int incX, , const double beta , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_symv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , A: &SYMAT (a, n, ord, ul, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_symv] fun cblas_ssymv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , A: &SYMAT (float, n, ord, ul, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx , beta: float , Y: &GEVEC (float, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_ssymv" // end of [fun] fun cblas_dsymv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , A: &SYMAT (double, n, ord, ul, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx , beta: double , Y: &GEVEC (double, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dsymv" // end of [fun] (* ****** ****** *) // // SBMV: S, D // (* void cblas_dsbmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N, const int K , const double alpha , const double *A, const int lda , const double *X, const int incX , const double beta , float *Y, const int incY ) ; *) fun{a:t@ype} cblas_sbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: a , A: &SBMAT (a, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_sbmv] fun cblas_ssbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: float , A: &SBMAT (float, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (float, n, dx), incX: int dx , beta: float , Y: &GEVEC (float, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_ssbmv" // end of [cblas_ssbmv] fun cblas_dsbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: double , A: &SBMAT (double, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (double, n, dx), incX: int dx , beta: double , Y: &GEVEC (double, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dsbmv" // end of [cblas_dsbmv] (* ****** ****** *) // // SPMV: S, D // HPMV: C, Z // (* void cblas_dspmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const double alpha , const double *Ap , const double *X, const int incX , const double beta , double *Y, const int incY ) ; *) fun{a:t@ype} cblas_spmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: a , Ap: &SPMAT (a, n, ord, ul) , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_spmv] fun cblas_sspmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: float , Ap: &SPMAT (float, n, ord, ul) , X: &GEVEC (float, n, dx), incX: int dx , beta: float , Y: &GEVEC (float, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_sspmv" // end of [fun] fun cblas_dspmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: double , Ap: &SPMAT (double, n, ord, ul) , X: &GEVEC (double, n, dx), incX: int dx , beta: double , Y: &GEVEC (double, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_dspmv" // end of [fun] (* ****** ****** *) // // GER: S, D // (* void cblas_dger( const enum CBLAS_ORDER Order , const int M, const int N , const double alpha , const double *X, const int incX , const double *Y, const int incY , double *A, const int lda ) ; *) fun{a:t@ype} cblas_ger {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: a , X: &GEVEC (a, m, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &GEMAT (a, m, n, ord, lda), lda: int lda ) :<> void // end of [cblas_ger] fun cblas_sger {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: float , X: &GEVEC (float, m, dx), incX: int dx , Y: &GEVEC (float, n, dy), incY: int dy , A: &GEMAT (float, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_sger" // end of [cblas_sger] fun cblas_dger {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: double , X: &GEVEC (double, m, dx), incX: int dx , Y: &GEVEC (double, n, dy), incY: int dy , A: &GEMAT (double, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_dger" // end of [cblas_dger] (* ****** ****** *) // // SYR: S, D // (* void cblas_dsyr ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const double alpha , const double *X, const int incX , double *A, const int lda ) ; *) fun{a:t@ype} cblas_syr {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , A: &SYMAT (a, n, ord, ul, lda), lda: int lda ) :<> void // end of [cblas_syr] fun cblas_ssyr {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int dx , A: &SYMAT (float, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_ssyr" // end of [cblas_ssyr] fun cblas_dsyr {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (double, n, dx), incX: int dx , A: &SYMAT (double, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_dsyr" // end of [cblas_dsyr] (* ****** ****** *) // // SYR2: S, D // fun{a:t@ype} cblas_syr2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &SYMAT (a, n, ord, ul, lda), lda: int lda ) :<> void // end of [cblas_syr2] fun cblas_ssyr2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int dx , Y: &GEVEC (float, n, dy), incY: int dy , A: &SYMAT (float, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_ssyr2" // end of [cblas_ssyr2] fun cblas_dsyr2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (double, n, dx), incX: int dx , Y: &GEVEC (double, n, dy), incY: int dy , A: &SYMAT (double, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_dsyr2" // end of [cblas_dsyr2] (* ****** ****** *) // // SPR: S, D // (* void cblas_dspr ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const double alpha , const double *X, const int incX , double *Ap ) ; *) fun{a:t@ype} cblas_spr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Ap: &SPMAT (a, n, ord, ul) ) :<> void // end of [cblas_spr] fun cblas_sspr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int dx , Ap: &SPMAT (float, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_sspr" // end of [cblas_sspr] fun cblas_dspr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (double, n, dx), incX: int dx , Ap: &SPMAT (double, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_dspr" // end of [cblas_dspr] (* ****** ****** *) // // SPR2: S, D // (* void cblas_dspr2 ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const double alpha , const double *X, const int incX , const double *Y, const int incY , double *A ) ; *) fun{a:t@ype} cblas_spr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &SPMAT (a, n, ord, ul) ) :<> void // end of [cblas_spr2] fun cblas_sspr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (float, n, dx), incX: int dx , Y: &GEVEC (float, n, dy), incY: int dy , A: &SPMAT (float, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_sspr2" // end of [cblas_sspr2] fun cblas_dspr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (double, n, dx), incX: int dx , Y: &GEVEC (double, n, dy), incY: int dy , A: &SPMAT (double, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_dspr2" // end of [cblas_dspr2] (* ****** ****** *) // // HEMV: C, Z // extended with S, D // (* void cblas_chemv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const void *alpha , const void *A, const int lda , const void *X, const int incX , const void *beta , void *Y, const int incY ) ; *) fun{a:t@ype} cblas_hemv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , A: &HEMAT (a, n, ord, ul, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_hemv] fun cblas_chemv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &ccmplx , A: &HEMAT (ccmplx, n, ord, ul, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx , beta: &ccmplx , Y: &GEVEC (ccmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_chemv" // end of [fun] fun cblas_zhemv {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &zcmplx , A: &HEMAT (zcmplx, n, ord, ul, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx , beta: &zcmplx , Y: &GEVEC (zcmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zhemv" // end of [fun] (* ****** ****** *) // // HBMV: C, Z // extended with S, D // (* void cblas_chbmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N, const int K , const void *alpha , const void *A, const int lda , const void *X, const int incX , const void *beta , void *Y, const int incY ) ; *) fun{a:t@ype} cblas_hbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: a , A: &HBMAT (a, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_hbmv] fun cblas_chbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: &ccmplx , A: &HBMAT (ccmplx, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (ccmplx, n, dx), incX: int dx , beta: &ccmplx , Y: &GEVEC (ccmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_chbmv" // end of [cblas_chbmv] fun cblas_zhbmv {ord:order} {ul:uplo} {n,k:nat | k < n} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n, K: int k , alpha: &zcmplx , A: &HBMAT (zcmplx, n, ord, ul, k, lda), lda: int lda , X: &GEVEC (zcmplx, n, dx), incX: int dx , beta: &zcmplx , Y: &GEVEC (zcmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zhbmv" // end of [cblas_zhbmv] (* ****** ****** *) // // HPMV: C, Z // extended with S, D // (* void cblas_chpmv ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const void *alpha , const void *Ap , const void *X, const int incX , const void *beta, void *Y, const int incY ) ; *) fun{a:t@ype} cblas_hpmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: a , Ap: &HPMAT (a, n, ord, ul) , X: &GEVEC (a, n, dx), incX: int dx , beta: a , Y: &GEVEC (a, n, dy), incY: int dy ) :<> void // end of [cblas_hpmv] fun cblas_chpmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: &ccmplx , Ap: &HPMAT (ccmplx, n, ord, ul) , X: &GEVEC (ccmplx, n, dx), incX: int dx , beta: &ccmplx , Y: &GEVEC (ccmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_chpmv" // end of [fun] fun cblas_zhpmv {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t ord , Uplo: CBLAS_UPLO_t ul , N: int n , alpha: &zcmplx , Ap: &HPMAT (zcmplx, n, ord, ul) , X: &GEVEC (zcmplx, n, dx), incX: int dx , beta: &zcmplx , Y: &GEVEC (zcmplx, n, dy), incY: int dy ) :<> void = "mac#atsctrb_cblas_zhpmv" // end of [fun] (* ****** ****** *) // // GERU: C, Z // extended with S, D // (* void cblas_cgeru( const enum CBLAS_ORDER Order , const int M, const int N , const void *alpha , const void *X, const int incX , const void *Y, const int incY , void *A, const int lda ) ; *) fun{a:t@ype} cblas_geru {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: a , X: &GEVEC (a, m, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &GEMAT (a, m, n, ord, lda), lda: int lda ) :<> void // end of [cblas_geru] fun cblas_cgeru {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: &ccmplx , X: &GEVEC (ccmplx, m, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy , A: &GEMAT (ccmplx, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_cgeru" // end of [fun] fun cblas_zgeru {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: &zcmplx , X: &GEVEC (zcmplx, m, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy , A: &GEMAT (zcmplx, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_zgeru" // end of [fun] (* ****** ****** *) // // GERU: C, Z // extended with S, D // (* void cblas_cgerc( const enum CBLAS_ORDER Order , const int M, const int N , const void *alpha , const void *X, const int incX , const void *Y, const int incY , void *A, const int lda ) ; *) fun{a:t@ype} cblas_gerc {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: a , X: &GEVEC (a, m, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &GEMAT (a, m, n, ord, lda), lda: int lda ) :<> void // end of [cblas_gerc] fun cblas_cgerc {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: &ccmplx , X: &GEVEC (ccmplx, m, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy , A: &GEMAT (ccmplx, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_cgerc" // end of [fun] fun cblas_zgerc {ord:order} {m,n:nat} {dx,dy:inc} {lda:pos} ( Order: CBLAS_ORDER_t (ord) , M: int m, N: int n , alpha: &zcmplx , X: &GEVEC (zcmplx, m, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy , A: &GEMAT (zcmplx, m, n, ord, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_zgerc" // end of [fun] (* ****** ****** *) // // HER: C, Z // extended with S, D // (* void cblas_cher( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const float alpha , const void *X, const int incX , void *A, const int lda ) ; *) fun{a1,a2:t@ype} cblas_her {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a1 , X: &GEVEC (a2, n, dx), incX: int dx , A: &HEMAT (a2, n, ord, ul, lda), lda: int lda ) :<> void // end of [cblas_her] fun cblas_cher {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (ccmplx, n, dx), incX: int dx , A: &HEMAT (ccmplx, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_cher" // end of [cblas_cher] fun cblas_zher {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (zcmplx, n, dx), incX: int dx , A: &HEMAT (zcmplx, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_zher" // end of [cblas_zher] (* ****** ****** *) // // HER2: C, Z // extended with S, D // (* void cblas_cher2 ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const void *alpha , const void *X, const int incX , const void *Y, const int incY , void *A, const int lda ) ; *) fun{a:t@ype} cblas_her2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , A: &HEMAT (a, n, ord, ul, lda), lda: int lda ) :<> void // end of [cblas_her2] fun cblas_cher2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &ccmplx , X: &GEVEC (ccmplx, n, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy , A: &HEMAT (ccmplx, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_cher2" // end of [cblas_cher2] fun cblas_zher2 {ord:order} {ul:uplo} {n:nat} {lda:pos} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &zcmplx , X: &GEVEC (zcmplx, n, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy , A: &HEMAT (zcmplx, n, ord, ul, lda), lda: int lda ) :<> void = "mac#atsctrb_cblas_zher2" // end of [cblas_zher2] (* ****** ****** *) // // HPR: C, Z // extended with S, D // (* void cblas_chpr ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const float alpha , const void *X, const int incX , void *A ) ; *) fun{a1,a2:t@ype} cblas_hpr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a1 , X: &GEVEC (a2, n, dx), incX: int dx , A: &HPMAT (a2, n, ord, ul) ) :<> void // end of [cblas_hpr] fun cblas_chpr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: float , X: &GEVEC (ccmplx, n, dx), incX: int dx , A: &HPMAT (ccmplx, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_chpr" // end of [cblas_chpr] fun cblas_zhpr {ord:order} {ul:uplo} {n:nat} {dx:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: double , X: &GEVEC (zcmplx, n, dx), incX: int dx , A: &HPMAT (zcmplx, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_zhpr" // end of [cblas_zhpr] (* ****** ****** *) // // HPR2: C, Z // extended with S, D // (* void cblas_chpr2 ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const int N , const void *alpha , const void *X, const int incX , const void *Y, const int incY , void *Ap ) ; *) fun{a:t@ype} cblas_hpr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: a , X: &GEVEC (a, n, dx), incX: int dx , Y: &GEVEC (a, n, dy), incY: int dy , Ap: &HPMAT (a, n, ord, ul) ) :<> void // end of [cblas_hpr2] fun cblas_chpr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &ccmplx , X: &GEVEC (ccmplx, n, dx), incX: int dx , Y: &GEVEC (ccmplx, n, dy), incY: int dy , Ap: &HPMAT (ccmplx, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_chpr2" // end of [cblas_chpr2] fun cblas_zhpr2 {ord:order} {ul:uplo} {n:nat} {dx,dy:inc} ( Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , N: int n , alpha: &zcmplx , X: &GEVEC (zcmplx, n, dx), incX: int dx , Y: &GEVEC (zcmplx, n, dy), incY: int dy , Ap: &HPMAT (zcmplx, n, ord, ul) ) :<> void = "mac#atsctrb_cblas_zhpr2" // end of [cblas_zhpr2] (* ****** ****** *) // // BLAS level 3 // (* ****** ****** *) // // GEMM: S, D, C, Z // (* // taken from [cblas.h] void cblas_dgemm ( const enum CBLAS_ORDER Order , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_TRANSPOSE TransB , const int M, const int N, const int K , const double alpha , const double *A, const int lda , const double *B, const int ldb , const double beta , double *C, const int ldc ) ; *) fun{t:t@ype} cblas_gemm {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, m, k) , pfb: trandim_p (trB, mb, nb, k, n) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , TransB: CBLAS_TRANSPOSE_t (trB) , M: int m, N: int n, K: int k , alpha: t , A: &GEMAT (t, ma, na, ord, lda), lda: int lda , B: &GEMAT (t, mb, nb, ord, ldb), ldb: int ldb , beta: t , C: &GEMAT (t, m, n, ord, ldc), ldc: int ldc ) :<> void = "atsctrb_cblas_gemm" fun cblas_sgemm {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, m, k) , pfb: trandim_p (trB, mb, nb, k, n) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t trA , TransB: CBLAS_TRANSPOSE_t trB , M: int m, N: int n, K: int k , alpha: float , A: &GEMAT (float, ma, na, ord, lda), lda: int lda , B: &GEMAT (float, mb, nb, ord, ldb), ldb: int ldb , beta: float , C: &GEMAT (float, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_sgemm" // end of [fun] fun cblas_dgemm {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, m, k) , pfb: trandim_p (trB, mb, nb, k, n) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t trA , TransB: CBLAS_TRANSPOSE_t trB , M: int m, N: int n, K: int k , alpha: double , A: &GEMAT (double, ma, na, ord, lda), lda: int lda , B: &GEMAT (double, mb, nb, ord, ldb), ldb: int ldb , beta: double , C: &GEMAT (double, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_dgemm" // end of [fun] fun cblas_cgemm {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, m, k) , pfb: trandim_p (trB, mb, nb, k, n) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t trA , TransB: CBLAS_TRANSPOSE_t trB , M: int m, N: int n, K: int k , alpha: &ccmplx , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (ccmplx, mb, nb, ord, ldb), ldb: int ldb , beta: &ccmplx , C: &GEMAT (ccmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_cgemm" // end of [fun] fun cblas_zgemm {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, m, k) , pfb: trandim_p (trB, mb, nb, k, n) | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t trA , TransB: CBLAS_TRANSPOSE_t trB , M: int m, N: int n, K: int k , alpha: &zcmplx , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (zcmplx, mb, nb, ord, ldb), ldb: int ldb , beta: &zcmplx , C: &GEMAT (zcmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zgemm" // end of [fun] // // HX: this one is correct but too cumbersome to use! // fun{t:t@ype} cblas_gemm__main {v:view} {ord:order} {trA,trB:transpose} {m,n,k:nat} {ma,na:nat} {mb,nb:nat} {lda,ldb,ldc:pos} {la,lb:addr} ( pf: !v , pfa1: trandim_p (trA, ma, na, m, k) , pfa2: GEMAT_v (t, ma, na, ord, lda, la) <= v // containment , pfb1: trandim_p (trB, mb, nb, k, n) , pfb2: GEMAT_v (t, mb, nb, ord, ldb, lb) <= v // containment | Order: CBLAS_ORDER_t ord , TransA: CBLAS_TRANSPOSE_t (trA) , TransB: CBLAS_TRANSPOSE_t (trB) , M: int m, N: int n, K: int k , alpha: t , pA: ptr la, lda: int lda , pB: ptr lb, ldb: int ldb , beta: t , C: &GEMAT (t, m, n, ord, ldc), ldc: int ldc ) :<> void = "atsctrb_cblas_gemm" (* ****** ****** *) // // SYRK: S, D, C, Z // (* void cblas_dsyrk ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE Trans , const int N, const int K , const double alpha , const double *A, const int lda , const double beta , double *C, const int ldc ) ; *) fun{a:t@ype} cblas_syrk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: a , A: &GEMAT (a, ma, na, ord, lda), lda: int lda , beta: a , C: &SYMAT (a, n, ord, ul, ldc), ldc: int ldc ) :<> void // end of [cblas_syrk] fun cblas_ssyrk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: float , A: &GEMAT (float, ma, na, ord, lda), lda: int lda , beta: float , C: &SYMAT (float, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_ssyrk" // end of [fun] fun cblas_dsyrk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: double , A: &GEMAT (double, ma, na, ord, lda), lda: int lda , beta: double , C: &SYMAT (double, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_dsyrk" // end of [fun] fun cblas_csyrk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &ccmplx , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , beta: &ccmplx , C: &SYMAT (ccmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_csyrk" // end of [fun] fun cblas_zsyrk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &zcmplx , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , beta: &zcmplx , C: &SYMAT (zcmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zsyrk" // end of [fun] (* ****** ****** *) // // SYRK2: S, D, C, Z // (* void cblas_dsyr2k ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE Trans , const int N, const int K , const double alpha , const double *A, const int lda , const double *B, const int ldb , const double beta , double *C, const int ldc ) ; *) fun{a:t@ype} cblas_syr2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: a , A: &GEMAT (a, ma, na, ord, lda), lda: int lda , B: &GEMAT (a, ma, na, ord, ldb), ldb: int ldb , beta: a , C: &SYMAT (a, n, ord, ul, ldc), ldc: int ldc ) :<> void // end of [cblas_syr2k] fun cblas_ssyr2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: float , A: &GEMAT (float, ma, na, ord, lda), lda: int lda , B: &GEMAT (float, ma, na, ord, ldb), ldb: int ldb , beta: float , C: &SYMAT (float, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_ssyr2k" // end of [fun] fun cblas_dsyr2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: double , A: &GEMAT (double, ma, na, ord, lda), lda: int lda , B: &GEMAT (double, ma, na, ord, ldb), ldb: int ldb , beta: double , C: &SYMAT (double, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_dsyr2k" // end of [fun] fun cblas_csyr2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &ccmplx , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (ccmplx, ma, na, ord, ldb), ldb: int ldb , beta: &ccmplx , C: &SYMAT (ccmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_csyr2k" // end of [fun] fun cblas_zsyr2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &zcmplx , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (zcmplx, ma, na, ord, ldb), ldb: int ldb , beta: &zcmplx , C: &SYMAT (zcmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zsyr2k" // end of [fun] (* ****** ****** *) // // SYMM: S, D, C, Z // (* void cblas_dsymm ( const enum CBLAS_ORDER Order , const enum CBLAS_SIDE Side , const enum CBLAS_UPLO Uplo , const int M, const int N , const double alpha , const double *A, const int lda , const double *B, const int ldb , const double beta , double *C, const int ldc ) ; *) fun{a:t@ype} cblas_symm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: a , A: &SYMAT (a, na, ord, ul, lda), lda: int lda , B: &GEMAT (a, m, n, ord, ldb), ldb: int ldb , beta: a , C: &GEMAT (a, m, n, ord, ldc), ldc: int ldc ) :<> void // end of [cblas_symm] fun cblas_ssymm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: float , A: &SYMAT (float, na, ord, ul, lda), lda: int lda , B: &GEMAT (float, m, n, ord, ldb), ldb: int ldb , beta: float , C: &GEMAT (float, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_ssymm" // end of [fun] fun cblas_dsymm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: double , A: &SYMAT (double, na, ord, ul, lda), lda: int lda , B: &GEMAT (double, m, n, ord, ldb), ldb: int ldb , beta: double , C: &GEMAT (double, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_dsymm" // end of [fun] fun cblas_csymm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: &ccmplx , A: &SYMAT (ccmplx, na, ord, ul, lda), lda: int lda , B: &GEMAT (ccmplx, m, n, ord, ldb), ldb: int ldb , beta: &ccmplx , C: &GEMAT (ccmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_csymm" // end of [fun] fun cblas_zsymm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: &zcmplx , A: &SYMAT (zcmplx, na, ord, ul, lda), lda: int lda , B: &GEMAT (zcmplx, m, n, ord, ldb), ldb: int ldb , beta: &zcmplx , C: &GEMAT (zcmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zsymm" // end of [fun] (* ****** ****** *) // // TRMM: S, D, C, Z // (* // B <- alpha A B or B <- alpha B A void cblas_dtrmm ( const enum CBLAS_ORDER Order , const enum CBLAS_SIDE Side , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int M, const int N , const double alpha , const double *A, const int lda , double *B, const int ldb ) ; *) fun{a:t@ype} cblas_trmm {ord:order} {lr:side} {ul:uplo} {trA:transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: a , A: &TRMAT (a, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (a, m, n, ord, ldb), ldb: int ldb ) :<> void // end of [cblas_trmm] fun cblas_strmm {ord:order} {lr:side} {ul:uplo} {trA:transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: float , A: &TRMAT (float, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (float, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_strmm" fun cblas_dtrmm {ord:order} {lr:side} {ul:uplo} {trA:transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: double , A: &TRMAT (double, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (double, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_dtrmm" // end of [fun] fun cblas_ctrmm {ord:order} {lr:side} {ul:uplo} {trA:transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: &ccmplx , A: &TRMAT (ccmplx, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (ccmplx, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_ctrmm" // end of [fun] fun cblas_ztrmm {ord:order} {lr:side} {ul:uplo} {trA:transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: &zcmplx , A: &TRMAT (zcmplx, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (zcmplx, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_ztrmm" // end of [fun] (* ****** ****** *) // // TRSM: S, D, C, Z // (* // B <- alpha A^{-1} B or B <- alpha B A^{-1} void cblas_dtrsm ( const enum CBLAS_ORDER Order , const enum CBLAS_SIDE Side , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE TransA , const enum CBLAS_DIAG Diag , const int M, const int N , const double alpha , const double *A, const int lda , double *B, const int ldb ) ; *) fun{a:t@ype} cblas_trsm {ord:order} {lr:side} {ul:uplo} {trA: transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: a , A: &TRMAT (a, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (a, m, n, ord, ldb), ldb: int ldb ) :<> void // end of [cblas_trmm] fun cblas_strsm {ord:order} {lr:side} {ul:uplo} {trA: transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: float , A: &TRMAT (float, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (float, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_strsm" // end of [fun] fun cblas_dtrsm {ord:order} {lr:side} {ul:uplo} {trA: transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: double , A: &TRMAT (double, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (double, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_dtrsm" // end of [fun] fun cblas_ctrsm {ord:order} {lr:side} {ul:uplo} {trA: transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: &ccmplx , A: &TRMAT (ccmplx, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (ccmplx, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_ctrsm" // end of [fun] fun cblas_ztrsm {ord:order} {lr:side} {ul:uplo} {trA: transpose} {dg:diag} {m,n:nat} {na:nat} {lda,ldb:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t (ord) , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , transA: CBLAS_TRANSPOSE_t (trA) , Diag: CBLAS_DIAG_t (dg) , M: int m, N: int n , alpha: &zcmplx , A: &TRMAT (zcmplx, na, ord, ul, dg, lda), lda: int lda , B: &GEMAT (zcmplx, m, n, ord, ldb), ldb: int ldb ) :<> void = "mac#atsctrb_cblas_ztrsm" // end of [fun] (* ****** ****** *) // // HEMM: C, Z // extended with S, D, // (* void cblas_chemm( const enum CBLAS_ORDER Order , const enum CBLAS_SIDE Side , const enum CBLAS_UPLO Uplo , const int M, const int N , const void *alpha , const void *A, const int lda , const void *B, const int ldb , const void *beta , void *C, const int ldc ) ; *) fun{a:t@ype} cblas_hemm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: a , A: &HEMAT (a, na, ord, ul, lda), lda: int lda , B: &GEMAT (a, m, n, ord, ldb), ldb: int ldb , beta: a , C: &GEMAT (a, m, n, ord, ldc), ldc: int ldc ) :<> void // end of [cblas_hemm] fun cblas_chemm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: &ccmplx , A: &HEMAT (ccmplx, na, ord, ul, lda), lda: int lda , B: &GEMAT (ccmplx, m, n, ord, ldb), ldb: int ldb , beta: &ccmplx , C: &GEMAT (ccmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_chemm" // end of [fun] fun cblas_zhemm {ord:order} {lr:side} {ul:uplo} {m,n:nat} {na:nat} {lda,ldb,ldc:pos} ( pfa: sidedim_p (lr, m, n, na) | Order: CBLAS_ORDER_t ord , Side: CBLAS_SIDE_t (lr) , Uplo: CBLAS_UPLO_t (ul) , M: int m, N: int n , alpha: &zcmplx , A: &HEMAT (zcmplx, na, ord, ul, lda), lda: int lda , B: &GEMAT (zcmplx, m, n, ord, ldb), ldb: int ldb , beta: &zcmplx , C: &GEMAT (zcmplx, m, n, ord, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zhemm" // end of [fun] (* ****** ****** *) // // HERK: C, Z // extended with S, D // (* void cblas_cherk ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE Trans , const int N, const int K , const float alpha , const void *A, const int lda , const float beta , void *C, const int ldc ) ; *) fun{a1,a2:t@ype} cblas_herk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: a2 , A: &GEMAT (a1, ma, na, ord, lda), lda: int lda , beta: a2 , C: &HEMAT (a1, n, ord, ul, ldc), ldc: int ldc ) :<> void // end of [cblas_herk] fun cblas_cherk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: float , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , beta: float , C: &HEMAT (ccmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_cherk" // end of [fun] fun cblas_zherk {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: double , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , beta: double , C: &HEMAT (zcmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zherk" // end of [fun] (* ****** ****** *) // // HER2K: C, Z // extended with S, D // (* void cblas_cher2k ( const enum CBLAS_ORDER Order , const enum CBLAS_UPLO Uplo , const enum CBLAS_TRANSPOSE Trans , const int N, const int K , const void *alpha , const void *A, const int lda , const void *B, const int ldb , const void *beta , void *C, const int ldc ) ; *) fun{a1,a2:t@ype} cblas_her2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: a1 , A: &GEMAT (a1, ma, na, ord, lda), lda: int lda , B: &GEMAT (a1, ma, na, ord, ldb), ldb: int ldb , beta: a2 , C: &HEMAT (a1, n, ord, ul, ldc), ldc: int ldc ) :<> void // end of [cblas_her2k] fun cblas_cher2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &ccmplx , A: &GEMAT (ccmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (ccmplx, ma, na, ord, ldb), ldb: int ldb , beta: float , C: &HEMAT (ccmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_cher2k" // end of [fun] fun cblas_zher2k {ord:order} {ul:uplo} {trA:transpose} {n,k:nat} {ma,na:nat} {lda,ldb,ldc:pos} ( pfa: trandim_p (trA, ma, na, n, k) | Order: CBLAS_ORDER_t (ord) , Uplo: CBLAS_UPLO_t (ul) , Trans: CBLAS_TRANSPOSE_t (trA) , N: int n, K: int k , alpha: &zcmplx , A: &GEMAT (zcmplx, ma, na, ord, lda), lda: int lda , B: &GEMAT (zcmplx, ma, na, ord, ldb), ldb: int ldb , beta: double , C: &HEMAT (zcmplx, n, ord, ul, ldc), ldc: int ldc ) :<> void = "mac#atsctrb_cblas_zher2k" // end of [fun] (* ****** ****** *) (* end of [cblas.sats] *) ats-lang-anairiats-0.2.11/contrib/cblas/Makefile0000664000175000017500000000133412223166163020163 0ustar hwxihwxi# # API for cblas in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Author: Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) # Time: July, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall LD=ld LIBFLAGS=-L/usr/lib/atlas ###### all: atsctrb_cblas.o clean ###### atsctrb_cblas.o: \ cblas_dats.o cblas_extra_dats.o ; $(LD) -r -o $@ $^ ###### cblas_dats.o: \ DATS/cblas.dats; $(ATSCC) $(LIBFLAGS) -o $@ -c DATS/cblas.dats cblas_extra_dats.o: \ DATS/cblas_extra.dats; $(ATSCC) $(LIBFLAGS) -o $@ -c DATS/cblas_extra.dats ###### clean:: rm -f *_?ats.c *_?ats.o cleanall: clean rm -f atsctrb_cblas.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/cblas/DATS/0000700000175000017500000000000012223166163017241 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/DATS/cblas_extra.dats0000664000175000017500000001620712223166163022427 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "prelude/SATS/number.sats" (* ****** ****** *) staload "libats/SATS/fmatrix.sats" staload GA = "libats/SATS/genarrays.sats" sortdef inc = $GA.inc sortdef order = $GA.order stadef row = $GA.row stadef col = $GA.col sortdef uplo = $GA.uplo stadef upper = $GA.upper stadef lower = $GA.lower sortdef diag = $GA.diag stadef unit = $GA.unit stadef nonunit = $GA.nonunit stadef GEMAT = $GA.GEMAT stadef GEMAT_v = $GA.GEMAT_v (* ****** ****** *) staload "contrib/cblas/SATS/cblas.sats" staload "contrib/cblas/SATS/cblas_extra.sats" (* ****** ****** *) #define sz2i int1_of_size1 (* ****** ****** *) // // filling a square matrix with identity diagnal // implement{a} GEMAT_ptr_initialize_eye {ord} {m} {lda} (ord, m, A, lda) = let val _0 = of_int (0) val () = $GA.GEMAT_ptr_initialize_elt (ord, A, m, m, lda, _0) // end of [val] fun loop {i:nat | i <= m} .. (A: &GEMAT (a, m, m, ord, lda), i: size_t i, _1: a): void = if i < m then begin $GA.GEMAT_ptr_set_elt_at (ord, A, lda, i, i, _1); loop (A, i+1, _1) end // end of [if] // end of [loop] val _1 = of_int (1) in loop (A, 0, _1) end // end of [GEMAT_ptr_initialize_eye] (* ****** ****** *) (* ** Y <- alpha * X + Y *) implement{a} GEMAT_axpy // generalizing [cblas_axpy] {ord} {m,n} {ldx,ldy} (ord, m, n, alpha, X, ldx, Y, ldy) = let fun loop_row {lx,ly:addr} {m,n:nat} .. ( pfX_gmat: !GEMAT_v (a, m, n, row, ldx, lx) , pfY_gmat: !GEMAT_v (a, m, n, row, ldy, ly) | pX: ptr lx, pY: ptr ly, m: size_t m, n: size_t n ) : void = if m > 0 then let prval (pfX_inc, pfX_gvec, fpfX_gmat) = $GA.GEMAT_v_uncons_row (pfX_gmat) prval $GA.MATVECINCrowrow () = pfX_inc prval (pfY_inc, pfY_gvec, fpfY_gmat) = $GA.GEMAT_v_uncons_row (pfY_gmat) prval $GA.MATVECINCrowrow () = pfY_inc val () = cblas_axpy (sz2i n, alpha, !pX, 1(*incX*), !pY, 1(*incY*)) prval () = pfX_gmat := fpfX_gmat (pfX_gvec) prval () = pfY_gmat := fpfY_gmat (pfY_gvec) val (pfX1_gmat, pfX2_gmat, fpfX_gmat | pX1, pX2) = $GA.GEMAT_ptr_split2x1 (pfX_gmat | $GA.ORDERrow, pX, ldx, 1) val (pfY1_gmat, pfY2_gmat, fpfY_gmat | pY1, pY2) = $GA.GEMAT_ptr_split2x1 (pfY_gmat | $GA.ORDERrow, pY, ldy, 1) val () = loop_row (pfX2_gmat, pfY2_gmat | pX2, pY2, m-1, n) prval () = pfX_gmat := fpfX_gmat (pfX1_gmat, pfX2_gmat) prval () = pfY_gmat := fpfY_gmat (pfY1_gmat, pfY2_gmat) in // nothing end // no else // end of [if] in case+ ord of | $GA.ORDERrow () => loop_row (view@ X, view@ Y | &X, &Y, m, n) | $GA.ORDERcol () => let prval $GA.TRANORDcolrow () = $GA.GEMAT_v_trans {a} {col} (view@ X) prval $GA.TRANORDcolrow () = $GA.GEMAT_v_trans {a} {col} (view@ Y) val () = loop_row (view@ X, view@ Y | &X, &Y, n, m) prval $GA.TRANORDrowcol () = $GA.GEMAT_v_trans {a} {row} (view@ X) prval $GA.TRANORDrowcol () = $GA.GEMAT_v_trans {a} {row} (view@ Y) in // nothing end // end of [ORDERcol] end // end of [GEMAT_axpy] (* ****** ****** *) (* ** A <- diag(D) * A *) implement{a1,a2} GEMAT_scal_row {ord} {m,n} {lda} (ord, m, n, D, A, lda) = let fun scal_arr_arr {m,i:nat | i <= m} .. ( D: &(@[a2][m]), A: &(@[a1][m]), m: size_t m, i: size_t i ) :<> void = if i < m then begin A[i] := scal (D[i], A[i]); scal_arr_arr (D, A, m, i+1) end // end of [scal_arr_arr] fun loop_col {m,n:nat} {la:addr} .. ( pf_gmat: !GEMAT_v (a1, m, n, col, lda, la) | D: &(@[a2][m]), pA: ptr la, lda: size_t lda, m: size_t m, n: size_t n ) :<> void = if n > 0 then let val (pfA1_gmat, pfA2_gmat, fpf_gmat | pA1, pA2) = $GA.GEMAT_ptr_split1x2 (pf_gmat | $GA.ORDERcol, pA, lda, 1) prval (pf2_inc, pfA1_gvec, fpfA1_gmat) = $GA.GEVEC_v_of_GEMAT_v_col (pfA1_gmat) prval $GA.MATVECINCcolcol () = pf2_inc prval pfA1_arr = $GA.array_v_of_GEVEC_v (pfA1_gvec) val () = scal_arr_arr (D, !pA1, m, 0) prval () = pfA1_gvec := $GA.GEVEC_v_of_array_v (pfA1_arr) prval () = pfA1_gmat := fpfA1_gmat (pfA1_gvec) val () = loop_col (pfA2_gmat | D, pA2, lda, m, n-1) prval () = pf_gmat := fpf_gmat {a1} (pfA1_gmat, pfA2_gmat) in // nothing end // end of [if] // end of [loop_col] in case+ ord of | $GA.ORDERrow () => let prval $GA.TRANORDrowcol () = $GA.GEMAT_v_trans {a1} {row} (view@ A) val () = GEMAT_scal_col ($GA.ORDERcol, n, m, A, lda, D) prval $GA.TRANORDcolrow () = $GA.GEMAT_v_trans {a1} {col} (view@ A) in // nothing end // end of [ORDERrow] | $GA.ORDERcol () => loop_col (view@ A | D, &A, lda, m, n) end // end of [GEMAT_scal_row] (* ****** ****** *) (* ** A <- A * diag(D) *) implement{a1,a2} GEMAT_scal_col {ord} {m,n} {lda} (ord, m, n, A, lda, D) = let (* ** scal_arr_num (A, alpha, m) = cblas_scal (alpha, A, m, 1(*inc*)) *) fun scal_arr_num {m:nat} {la:addr} .. ( pfA: !array_v (a1, m, la) | pA: ptr la, alpha: a2, m: size_t m ) :<> void = if m > 0 then let prval (pfA1, pfA2) = array_v_uncons {a1} (pfA) val () = !pA := scal (alpha, !pA) val () = scal_arr_num (pfA2 | pA+sizeof, alpha, m-1) prval () = pfA := array_v_cons {a1} (pfA1, pfA2) in // nothing end // end of [if] // end of [scal_arr_num] fun loop_col {m,n:nat} {la,ld:addr} .. ( pf_gmat: !GEMAT_v (a1, m, n, col, lda, la), pfD: !array_v (a2, n, ld) | pA: ptr la, pD: ptr ld, m: size_t m, n: size_t n ) : void = if n > 0 then let val (pfA1_gmat, pfA2_gmat, fpf_gmat | pA1, pA2) = $GA.GEMAT_ptr_split1x2 (pf_gmat | $GA.ORDERcol, pA, lda, 1) prval (pf2_inc, pfA1_gvec, fpfA1_gmat) = $GA.GEVEC_v_of_GEMAT_v_col (pfA1_gmat) prval $GA.MATVECINCcolcol () = pf2_inc prval pfA1_arr = $GA.array_v_of_GEVEC_v {a1} (pfA1_gvec) prval (pfD1, pfD2) = array_v_uncons {a2} (pfD) val () = scal_arr_num (pfA1_arr | pA1, !pD, m) prval () = pfA1_gvec := $GA.GEVEC_v_of_array_v (pfA1_arr) prval () = pfA1_gmat := fpfA1_gmat (pfA1_gvec) val () = loop_col (pfA2_gmat, pfD2 | pA2, pD+sizeof, m, n-1) prval () = pf_gmat := fpf_gmat {a1} (pfA1_gmat, pfA2_gmat) prval () = pfD := array_v_cons {a2} (pfD1, pfD2) in // nothing end // end of [if] // end of [loop_col] in case+ ord of | $GA.ORDERrow () => let prval $GA.TRANORDrowcol () = $GA.GEMAT_v_trans {a1} {row} (view@ A) val () = GEMAT_scal_row ($GA.ORDERcol, n, m, D, A, lda) prval $GA.TRANORDcolrow () = $GA.GEMAT_v_trans {a1} {col} (view@ A) in // nothing end // end of [ORDERrow] | $GA.ORDERcol () => loop_col (view@ A, view@ D | &A, &D, m, n) end // end of [GEMAT_scal_col] (* ****** ****** *) (* end of [cblas_extra.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/DATS/cblas.dats0000664000175000017500000000406212223166163021220 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) implement CBLAS_ORDER_of_ORDER (x) = case+ x of | ORDERrow () => CblasRowMajor | ORDERcol () => CblasColMajor // end of [CBLAS_ORDER_of_ORDER] (* // HX: as of now, [ORDER_of_CBLAS_ORDER] is not needed prfun ORDER_istot {ord:order} .<>. (): ORDER (ord) = scase ord of | row () => ORDERrow () | col () => ORDERcol () // end of [ORDER_istot] implement ORDER_of_CBLAS_ORDER {ord} (cbord) = let prval ord = ORDER_istot {ord} () in if cbord = CblasRowMajor then let prval ORDERrow () = ord in ORDERrow end else if cbord = CblasColMajor then let prval ORDERcol () = ord in ORDERcol () end else let val () = prerr "exit(ATS/CBLAS): ORDER_of_CBLAS_ORDER: out-of-range" val () = prerr_newline () in exit (1) end // end of [if] end (* end of [ORDER_of_CBLAS_ORDER] *) *) (* ****** ****** *) implement CBLAS_UPLO_of_UPLO (x) = case+ x of | UPLOupper () => CblasUpper | UPLOlower () => CblasLower // end of [CBLAS_UPLO_of_UPLO] (* ****** ****** *) implement CBLAS_DIAG_of_DIAG (x) = case+ x of | DIAGunit () => CblasUnit | DIAGnonunit () => CblasNonUnit // end of [CBLAS_DIAG_of_DIAG] (* ****** ****** *) implement CBLAS_TRANSPOSE_of_TRANSPOSE (x) = case+ x of | TRANSPOSE_N () => CblasNoTrans | TRANSPOSE_T () => CblasTrans | TRANSPOSE_C () => CblasConjTrans // end of [CBLAS_TRANSPOSE_of_TRANSPOSE] (* ****** ****** *) implement CBLAS_SIDE_of_SIDE (x) = case+ x of | SIDEleft () => CblasLeft | SIDEright () => CblasRight // end of [CBLAS_SIDE_of_SIDE] (* ****** ****** *) (* end of [cblas.dats] *) ats-lang-anairiats-0.2.11/contrib/cblas/HATS/0000700000175000017500000000000012223166163017245 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/cblas/HATS/cblas.hats0000664000175000017500000011621312223166163021232 0ustar hwxihwxi(* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_CBLAS_DEBUG 1 // for controlling some debugging code (* ****** ****** *) staload C = "libc/SATS/complex.sats" typedef ccmplx = $C.ccmplx typedef zcmplx = $C.zcmplx (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload "contrib/cblas/SATS/cblas.sats" (* ****** ****** *) // // BLAS level 1 // (* ****** ****** *) // // cblas_rotg: S, D, C, Z // implement cblas_rotg (a, b, c, s) = cblas_srotg (a, b, c, s) // end of [cblas_rotg] implement cblas_rotg (a, b, c, s) = cblas_drotg (a, b, c, s) // end of [cblas_rotg] // must test first #if (0) // if it is to be uncommented // ATLAS extension implement cblas_rotg (a, b, c, s) = cblas_crotg (a, b, c, s) // end of [cblas_rotg] implement cblas_rotg (a, b, c, s) = cblas_zrotg (a, b, c, s) // end of [cblas_rotg] #endif // end of [#if 0] (* ****** ****** *) // // cblas_rot: S, D, CS, ZD // implement cblas_rot (N, X, incX, Y, incY, c, s) = cblas_srot (N, X, incX, Y, incY, c, s) // end of [cblas_rot] implement cblas_rot (N, X, incX, Y, incY, c, s) = cblas_drot (N, X, incX, Y, incY, c, s) // end of [cblas_rot] (* ****** ****** *) // // cblas_rotmg: S, D // implement cblas_rotmg (d1, d2, b1, b2, P) = cblas_srotmg (d1, d2, b1, b2, P) // end of [cblas_rotmg] implement cblas_rotmg (d1, d2, b1, b2, P) = cblas_drotmg (d1, d2, b1, b2, P) // end of [cblas_rotmg] (* ****** ****** *) // // cblas_rotm: S, D // implement cblas_rotm (N, X, incX, Y, incY, P) = cblas_srotm (N, X, incX, Y, incY, P) // end of [cblas_rotm] implement cblas_rotm (N, X, incX, Y, incY, P) = cblas_drotm (N, X, incX, Y, incY, P) // end of [cblas_rotm] (* ****** ****** *) // // cblas_dot: S, D // implement cblas_dot (N, X, incX, Y, incY) = cblas_sdot (N, X, incX, Y, incY) // end of [cblas_dot] implement cblas_dot (N, X, incX, Y, incY) = cblas_ddot (N, X, incX, Y, incY) // end of [cblas_dot] (* ****** ****** *) // // cblas_dotu_sub: C, Z // unconjugated dot product (call-by-reference on the return value) // implement cblas_dotu_sub (N, X, incX, Y, incY, dotu) = cblas_cdotu_sub (N, X, incX, Y, incY, dotu) // end of [cblas_dotu_sub] implement cblas_dotu_sub (N, X, incX, Y, incY, dotu) = cblas_zdotu_sub (N, X, incX, Y, incY, dotu) // end of [cblas_dotu_sub] (* ****** ****** *) // // cblas_dotc_sub: C, Z // conjugated dot product (call-by-reference on the return value) // implement cblas_dotc_sub (N, X, incX, Y, incY, dotu) = cblas_cdotc_sub (N, X, incX, Y, incY, dotu) // end of [cblas_dotc_sub] implement cblas_dotc_sub (N, X, incX, Y, incY, dotu) = cblas_zdotc_sub (N, X, incX, Y, incY, dotu) // end of [cblas_dotc_sub] (* ****** ****** *) // // cblas_dotu: S, D, C, Z // implement cblas_dotu (N, X, incX, Y, incY) = cblas_sdot (N, X, incX, Y, incY) // end of [cblas_dot] implement cblas_dotu (N, X, incX, Y, incY) = cblas_ddot (N, X, incX, Y, incY) // end of [cblas_dot] implement cblas_dotu (N, X, incX, Y, incY) = let var dotu : ccmplx // uninitialized val () = cblas_cdotu_sub (N, X, incX, Y, incY, dotu) in dotu end // of [cblas_dotu] implement cblas_dotu (N, X, incX, Y, incY) = let var dotu : zcmplx // uninitialized val () = cblas_zdotu_sub (N, X, incX, Y, incY, dotu) in dotu end // of [cblas_dotu] (* ****** ****** *) // // cblas_dotc: S, D, C, Z // implement cblas_dotc (N, X, incX, Y, incY) = cblas_sdot (N, X, incX, Y, incY) // end of [cblas_dotc] implement cblas_dotc (N, X, incX, Y, incY) = cblas_ddot (N, X, incX, Y, incY) // end of [cblas_dotc] implement cblas_dotc (N, X, incX, Y, incY) = let var dotc : ccmplx // uninitialized val () = cblas_cdotc_sub (N, X, incX, Y, incY, dotc) in dotc end // of [cblas_dotc] implement cblas_dotc (N, X, incX, Y, incY) = let var dotc : zcmplx // uninitialized val () = cblas_zdotc_sub (N, X, incX, Y, incY, dotc) in dotc end // of [cblas_dotc] (* ****** ****** *) // // cblas_nrm2: S, D, SC, DZ // implement cblas_nrm2 (N, X, incX) = cblas_snrm2 (N, X, incX) implement cblas_nrm2 (N, X, incX) = cblas_dnrm2 (N, X, incX) implement cblas_nrm2 (N, X, incX) = cblas_scnrm2 (N, X, incX) implement cblas_nrm2 (N, X, incX) = cblas_dznrm2 (N, X, incX) (* ****** ****** *) // // cblas_asum: S, D, SC, DZ // implement cblas_asum (N, X, incX) = cblas_sasum (N, X, incX) implement cblas_asum (N, X, incX) = cblas_dasum (N, X, incX) implement cblas_asum (N, X, incX) = cblas_scasum (N, X, incX) implement cblas_asum (N, X, incX) = cblas_dzasum (N, X, incX) (* ****** ****** *) // // cblas_iamax: S, D, C, Z // implement cblas_iamax (N, X, incX) = cblas_isamax (N, X, incX) implement cblas_iamax (N, X, incX) = cblas_idamax (N, X, incX) implement cblas_iamax (N, X, incX) = cblas_icamax (N, X, incX) implement cblas_iamax (N, X, incX) = cblas_izamax (N, X, incX) (* ****** ****** *) // // cblas_swap: S, D, C, Z // implement cblas_swap (N, X, incX, Y, incY) = cblas_sswap (N, X, incX, Y, incY) // end of [cblas_swap] implement cblas_swap (N, X, incX, Y, incY) = cblas_dswap (N, X, incX, Y, incY) // end of [cblas_swap] implement cblas_swap (N, X, incX, Y, incY) = cblas_cswap (N, X, incX, Y, incY) // end of [cblas_swap] implement cblas_swap (N, X, incX, Y, incY) = cblas_zswap (N, X, incX, Y, incY) // end of [cblas_swap] (* ****** ****** *) // // cblas_axpy: S, D, C, Z // implement cblas_axpy (N, alpha, X, incX, Y, incY) = cblas_saxpy (N, alpha, X, incX, Y, incY) // end of [cblas_axpy] implement cblas_axpy (N, alpha, X, incX, Y, incY) = cblas_daxpy (N, alpha, X, incX, Y, incY) // end of [cblas_axpy] implement cblas_axpy (N, alpha, X, incX, Y, incY) = let var alpha: ccmplx = alpha in cblas_caxpy (N, alpha, X, incX, Y, incY) end // end of [cblas_axpy] implement cblas_axpy (N, alpha, X, incX, Y, incY) = let var alpha: zcmplx = alpha in cblas_zaxpy (N, alpha, X, incX, Y, incY) end // end of [cblas_axpy] (* ****** ****** *) // // cblas_copy: S, D, C, Z // implement cblas_copy (N, X, incX, Y, incY) = cblas_scopy (N, X, incX, Y, incY) // end of [cblas_copy] implement cblas_copy (N, X, incX, Y, incY) = cblas_dcopy (N, X, incX, Y, incY) // end of [cblas_copy] implement cblas_copy (N, X, incX, Y, incY) = cblas_ccopy (N, X, incX, Y, incY) // end of [cblas_copy] implement cblas_copy (N, X, incX, Y, incY) = cblas_zcopy (N, X, incX, Y, incY) // end of [cblas_copy] (* ****** ****** *) // // cblas_scal: S, D, C, D, CS, ZD // implement cblas_scal (N, alpha, X, incX) = cblas_sscal (N, alpha, X, incX) // end of [cblas_scal] implement cblas_scal (N, alpha, X, incX) = cblas_dscal (N, alpha, X, incX) // end of [cblas_scal] implement cblas_scal (N, alpha, X, incX) = let var alpha: ccmplx = alpha in cblas_cscal (N, alpha, X, incX) end // end of [cblas_scal] implement cblas_scal (N, alpha, X, incX) = let var alpha: zcmplx = alpha in cblas_zscal (N, alpha, X, incX) end // end of [cblas_scal] implement cblas_scal (N, alpha, X, incX) = cblas_csscal (N, alpha, X, incX) // end of [cblas_scal] implement cblas_scal (N, alpha, X, incX) = cblas_zdscal (N, alpha, X, incX) // end of [cblas_scal] (* ****** ****** *) // // BLAS level 2 // (* ****** ****** *) // // cblas_gemv: S, D, C, Z // implement cblas_gemv (pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY) = cblas_sgemv ( pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY ) // end of [cblas_sgemv] // end of [cblas_gemv] implement cblas_gemv (pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY) = cblas_dgemv ( pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY ) // end of [cblas_dgemv] // end of [cblas_gemv] implement cblas_gemv ( pfa | Order, TransA, M, N , alpha, A, lda, X, incX, beta, Y, incY ) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_cgemv ( pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY ) // end of [cblas_cgemv] end // end of [cblas_gemv] implement cblas_gemv ( pfa | Order, TransA, M, N , alpha, A, lda, X, incX, beta, Y, incY ) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zgemv ( pfa | Order, TransA, M, N, alpha, A, lda, X, incX, beta, Y, incY ) // end of [cblas_zgemv] end // end of [cblas_gemv] (* ****** ****** *) implement cblas_gbmv ( pfa | Order , TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) = cblas_sgbmv ( pfa | Order, TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) // end of [cblas_sgbmv] // end of [cblas_gbmv] implement cblas_gbmv ( pfa | Order , TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) = cblas_dgbmv ( pfa | Order, TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) // end of [cblas_dgbmv] // end of [cblas_gbmv] implement cblas_gbmv ( pfa | Order , TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_cgbmv ( pfa | Order, TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) // end of [cblas_cgbmv] end // end of [cblas_gbmv] implement cblas_gbmv ( pfa | Order , TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zgbmv ( pfa | Order, TransA , M, N , KL, KU , alpha , A, lda , X, incX , beta , Y, incY ) // end of [cblas_zgbmv] end // end of [cblas_gbmv] (* ****** ****** *) // // cblas_trmv: S, D, C, Z // implement cblas_trmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_strmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trmv] implement cblas_trmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_dtrmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trmv] implement cblas_trmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_ctrmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trmv] implement cblas_trmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_ztrmv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trmv] (* ****** ****** *) // // cblas_tbmv: S, D, C, Z // implement cblas_tbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_stbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbmv] implement cblas_tbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_dtbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbmv] implement cblas_tbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_ctbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbmv] implement cblas_tbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_ztbmv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbmv] (* ****** ****** *) // // cblas_tpmv: S, D, C, Z // implement cblas_tpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_stpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpmv] implement cblas_tpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_dtpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpmv] implement cblas_tpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_ctpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpmv] implement cblas_tpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_ztpmv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpmv] (* ****** ****** *) // // cblas_trsv: S, D, C, Z // implement cblas_trsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_strsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trsv] implement cblas_trsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_dtrsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trsv] implement cblas_trsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_ctrsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trsv] implement cblas_trsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) = cblas_ztrsv (Order, Uplo, TransA, Diag, N, A, lda, X, incX) // end of [cblas_trsv] (* ****** ****** *) // // cblas_tbsv: S, D, C, Z // implement cblas_tbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_stbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbsv] implement cblas_tbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_dtbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbsv] implement cblas_tbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_ctbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbsv] implement cblas_tbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) = cblas_ztbsv (Order, Uplo, TransA, Diag, N, K, A, lda, X, incX) // end of [cblas_tbsv] (* ****** ****** *) // // cblas_tpsv: S, D, C, Z // implement cblas_tpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_stpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpsv] implement cblas_tpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_dtpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpsv] implement cblas_tpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_ctpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpsv] implement cblas_tpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) = cblas_ztpsv (Order, Uplo, TransA, Diag, N, Ap, X, incX) // end of [cblas_tpsv] (* ****** ****** *) // // cblas_symv: S, D // implement cblas_symv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = cblas_ssymv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) // end of [cblas_symv] implement cblas_symv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = cblas_dsymv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) // end of [cblas_symv] (* ****** ****** *) // // cblas_sbmv: S, D // implement cblas_sbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = cblas_ssbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) // end of [cblas_sbmv] implement cblas_sbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = cblas_dsbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) // end of [cblas_sbmv] (* ****** ****** *) // // cblas_spmv: S, D // implement cblas_spmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = cblas_sspmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) // end of [cblas_spmv] implement cblas_spmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = cblas_dspmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) // end of [cblas_spmv] (* ****** ****** *) // // cblas_ger: S, D // implement cblas_ger (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_sger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_ger] implement cblas_ger (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_dger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_ger] (* ****** ****** *) // // cblas_syr: S, D // implement cblas_syr (Order, Uplo, N, alpha, X, incX, A, lda) = cblas_ssyr (Order, Uplo, N, alpha, X, incX, A, lda) // end of [cblas_syr] implement cblas_syr (Order, Uplo, N, alpha, X, incX, A, lda) = cblas_dsyr (Order, Uplo, N, alpha, X, incX, A, lda) // end of [cblas_syr] (* ****** ****** *) // // cblas_syr2: S, D // implement cblas_syr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = cblas_ssyr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_syr2] implement cblas_syr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = cblas_dsyr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_syr2] (* ****** ****** *) // // cblas_spr: S, D // implement cblas_spr (Order, Uplo, N, alpha, X, incX, Ap) = cblas_sspr (Order, Uplo, N, alpha, X, incX, Ap) // end of [cblas_spr] implement cblas_spr (Order, Uplo, N, alpha, X, incX, Ap) = cblas_dspr (Order, Uplo, N, alpha, X, incX, Ap) // end of [cblas_spr] (* ****** ****** *) // // cblas_spr2: S, D // implement cblas_spr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) = cblas_sspr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) // end of [cblas_spr2] implement cblas_spr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) = cblas_dspr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) // end of [cblas_spr2] (* ****** ****** *) // // cblas_hemv: C, Z // extended with S, D // implement cblas_hemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ A) val () = cblas_ssymv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hemv] implement cblas_hemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ A) val () = cblas_dsymv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hemv] implement cblas_hemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = let var alpha = alpha and beta = beta in cblas_chemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) end // end of [cblas_symv] implement cblas_hemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) = let var alpha = alpha and beta = beta in cblas_zhemv (Order, Uplo, N, alpha, A, lda, X, incX, beta, Y, incY) end // end of [cblas_symv] (* ****** ****** *) // // cblas_hbmv: C, Z // extended with S, D // implement cblas_hbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = let prval pf_mat = SBMAT_v_of_HBMAT_v (REALTYPfloat, view@ A) val () = cblas_ssbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) prval () = view@ A := HBMAT_v_of_SBMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hbmv] implement cblas_hbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = let prval pf_mat = SBMAT_v_of_HBMAT_v (REALTYPdouble, view@ A) val () = cblas_dsbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) prval () = view@ A := HBMAT_v_of_SBMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hbmv] implement cblas_hbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = let var alpha0 = alpha var beta0 = beta in cblas_chbmv (Order, Uplo, N, K, alpha0, A, lda, X, incX, beta0, Y, incY) end // end of [cblas_hbmv] implement cblas_hbmv (Order, Uplo, N, K, alpha, A, lda, X, incX, beta, Y, incY) = let var alpha0 = alpha var beta0 = beta in cblas_zhbmv (Order, Uplo, N, K, alpha0, A, lda, X, incX, beta0, Y, incY) end // end of [cblas_hbmv] (* ****** ****** *) // // cblas_hbmv: C, Z // extended with S, D // // // cblas_hpmv: S, D, C, Z // implement cblas_hpmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPfloat, view@ Ap) val () = cblas_sspmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) prval () = view@ Ap := HPMAT_v_of_SPMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hpmv] implement cblas_hpmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPdouble, view@ Ap) val () = cblas_dspmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) prval () = view@ Ap := HPMAT_v_of_SPMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hpmv] implement cblas_hpmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = let var alpha = alpha and beta = beta in cblas_chpmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) end // end of [cblas_hpmv] implement cblas_hpmv (Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) = let var alpha = alpha and beta = beta in cblas_zhpmv(Order, Uplo, N, alpha, Ap, X, incX, beta, Y, incY) end // end of [cblas_hpmv] (* ****** ****** *) // // cblas_geru: C, Z // extended with S, D // implement cblas_geru (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_sger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_geru] implement cblas_geru (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_dger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_geru] implement cblas_geru (Order, M, N, alpha, X, incX, Y, incY, A, lda) = let var alpha = alpha in cblas_cgeru (Order, M, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_geru] implement cblas_geru (Order, M, N, alpha, X, incX, Y, incY, A, lda) = let var alpha: zcmplx = alpha in cblas_zgeru (Order, M, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_geru] (* ****** ****** *) // // cblas_gerc: C, Z // extended with S, D // implement cblas_gerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_sger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_gerc] implement cblas_gerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) = cblas_dger (Order, M, N, alpha, X, incX, Y, incY, A, lda) // end of [cblas_gerc] implement cblas_gerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) = let var alpha = alpha in cblas_cgerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_gerc] implement cblas_gerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) = let var alpha: zcmplx = alpha in cblas_zgerc (Order, M, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_gerc] (* ****** ****** *) // // cblas_her: C, Z // extended with S, D // implement cblas_her (Order, Uplo, N, alpha, X, incX, A, lda) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ A) val () = cblas_ssyr (Order, Uplo, N, alpha, X, incX, A, lda) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_her] implement cblas_her (Order, Uplo, N, alpha, X, incX, A, lda) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ A) val () = cblas_dsyr (Order, Uplo, N, alpha, X, incX, A, lda) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_her] implement cblas_her (Order, Uplo, N, alpha, X, incX, A, lda) = cblas_cher (Order, Uplo, N, alpha, X, incX, A, lda) // end of [cblas_her] implement cblas_her (Order, Uplo, N, alpha, X, incX, A, lda) = cblas_zher (Order, Uplo, N, alpha, X, incX, A, lda) // end of [cblas_her] (* ****** ****** *) // // cblas_her2: C, Z // extended with S, D // implement cblas_her2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ A) val () = cblas_ssyr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_her2] implement cblas_her2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ A) val () = cblas_dsyr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_her2] implement cblas_her2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = let var alpha = alpha in cblas_cher2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_her2] implement cblas_her2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) = let var alpha = alpha in cblas_zher2 (Order, Uplo, N, alpha, X, incX, Y, incY, A, lda) end // end of [cblas_her2] (* ****** ****** *) // // cblas_hpr: C, Z // extended with S, D // implement cblas_hpr (Order, Uplo, N, alpha, X, incX, A) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPfloat, view@ A) val () = cblas_sspr (Order, Uplo, N, alpha, X, incX, A) prval () = view@ A := HPMAT_v_of_SPMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hpr] implement cblas_hpr (Order, Uplo, N, alpha, X, incX, A) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPdouble, view@ A) val () = cblas_dspr (Order, Uplo, N, alpha, X, incX, A) prval () = view@ A := HPMAT_v_of_SPMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hpr] implement cblas_hpr (Order, Uplo, N, alpha, X, incX, Ap) = cblas_chpr (Order, Uplo, N, alpha, X, incX, Ap) // end of [cblas_hpr] implement cblas_hpr (Order, Uplo, N, alpha, X, incX, Ap) = cblas_zhpr (Order, Uplo, N, alpha, X, incX, Ap) // end of [cblas_hpr] (* ****** ****** *) // // cblas_hpr2: C, Z // extended with S, D // implement cblas_hpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, Ap) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPfloat, view@ Ap) val () = cblas_sspr2 (Order, Uplo, N, alpha, X, incX, Y, incY, Ap) prval () = view@ Ap := HPMAT_v_of_SPMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hpr2] implement cblas_hpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, Ap) = let prval pf_mat = SPMAT_v_of_HPMAT_v (REALTYPdouble, view@ Ap) val () = cblas_dspr2 (Order, Uplo, N, alpha, X, incX, Y, incY, Ap) prval () = view@ Ap := HPMAT_v_of_SPMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hpr2] implement cblas_hpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) = let var alpha = alpha in cblas_chpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) end // end of [cblas_hpr2] implement cblas_hpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) = let var alpha = alpha in cblas_zhpr2 (Order, Uplo, N, alpha, X, incX, Y, incY, A) end // end of [cblas_hpr2] (* ****** ****** *) // // BLAS level 3 // (* ****** ****** *) // // cblas_gemm: S, D, C, Z // fn cblas_gemm_overlap_check (pA: ptr, pB: ptr, pC: ptr):<> void = if (pA = pC orelse pB = pC) then $effmask_all begin prerr "error(ATS/CBLAS): cblas_gemm"; prerr ": overlapping between input and output is not allowed!"; prerr_newline (); exit (1) end // end of [if] // end of [cblas_gemm_overlap_check] implement cblas_gemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let #if ATS_CBLAS_DEBUG #then val () = cblas_gemm_overlap_check (&A, &B, &C) #endif in cblas_sgemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_sgemm] end // end of [cblas_gemm] implement cblas_gemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let #if ATS_CBLAS_DEBUG #then val () = cblas_gemm_overlap_check (&A, &B, &C) #endif in cblas_dgemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_dgemm] end // end of [cblas_gemm] implement cblas_gemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let #if ATS_CBLAS_DEBUG #then val () = cblas_gemm_overlap_check (&A, &B, &C) #endif var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_cgemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_cgemm] end // end of [cblas_gemm] implement cblas_gemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let #if ATS_CBLAS_DEBUG #then val () = cblas_gemm_overlap_check (&A, &B, &C) #endif var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zgemm ( pfa, pfb | Order, TransA, TransB, M, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_zgemm] end // end of [cblas_gemm] (* ****** ****** *) // // cblas_syrk: S, D, C, Z // implement cblas_syrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = cblas_ssyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) // end of [cblas_syrk] implement cblas_syrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = cblas_dsyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) // end of [cblas_syrk] implement cblas_syrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_csyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) end // end of [cblas_syrk] implement cblas_syrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zsyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) end // end of [cblas_syrk] (* ****** ****** *) // // cblsa_syr2K: S, D, C, Z // implement cblas_syr2k (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc) = cblas_ssyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_syr2k] implement cblas_syr2k (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc) = cblas_dsyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [cblas_syr2k] implement cblas_syr2k (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_csyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) end // end of [cblas_syr2k] implement cblas_syr2k (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zsyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) end // end of [cblas_syr2k] (* ****** ****** *) // // cblas_symm: S, D, C, Z // implement cblas_symm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = cblas_ssymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) // end of [cblas_symm] implement cblas_symm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = cblas_dsymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) // end of [cblas_symm] implement cblas_symm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_csymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) end // end of [cblas_symm] implement cblas_symm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zsymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) end // end of [cblas_symm] (* ****** ****** *) // // cblas_trmm: S, D, C, Z // implement cblas_trmm (pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb) = cblas_strmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_strmm] // end of [cblas_trmm] implement cblas_trmm (pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb) = cblas_dtrmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_dtrmm] // end of [cblas_trmm] implement cblas_trmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) = let var alpha: ccmplx = alpha in cblas_ctrmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_ctrmm] end // end of [cblas_trmm] implement cblas_trmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) = let var alpha: zcmplx = alpha in cblas_ztrmm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_ztrmm] end // end of [cblas_trmm] (* ****** ****** *) // // cblas_trsm: S, D, C, Z // implement cblas_trsm (pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb) = cblas_strsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_strsm] // end of [cblas_trsm] implement cblas_trsm (pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb) = cblas_dtrsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_dtrsm] // end of [cblas_trsm] implement cblas_trsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) = let var alpha: ccmplx = alpha in cblas_ctrsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_ctrsm] end // end of [cblas_trsm] implement cblas_trsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) = let var alpha: zcmplx = alpha in cblas_ztrsm ( pfa | Order, Side, Uplo, TransA, Diag, M, N, alpha, A, lda, B, ldb ) // end of [cblas_ztrsm] end // end of [cblas_trsm] (* ****** ****** *) // // cblas_hemm: C, Z // extended with S, D // implement cblas_hemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ A) val () = cblas_ssymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_hemm] implement cblas_hemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ A) val () = cblas_dsymm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) prval () = view@ A := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_hemm] implement cblas_hemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: ccmplx = alpha and beta: ccmplx = beta in cblas_chemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) end // end of [cblas_hemm] implement cblas_hemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) = let var alpha: zcmplx = alpha and beta: zcmplx = beta in cblas_zhemm (pfa | Order, Side, Uplo, M, N, alpha, A, lda, B, ldb, beta, C, ldc) end // end of [cblas_hemm] (* ****** ****** *) // // cblas_herk: C, Z // extended with S, D // implement cblas_herk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ C) val () = cblas_ssyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) prval () = view@ C := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_herk] implement cblas_herk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ C) val () = cblas_dsyrk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) prval () = view@ C := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_herk] implement cblas_herk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = begin cblas_cherk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) end // end of [cblas_herk] implement cblas_herk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) = begin cblas_zherk (pfa | Order, Uplo, Trans, N, K, alpha, A, lda, beta, C, ldc) end // end of [cblas_herk] (* ****** ****** *) // // cblas_her2k: C, Z // extended with S, D // implement cblas_her2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPfloat, view@ C) val () = cblas_ssyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [val] prval () = view@ C := HEMAT_v_of_SYMAT_v (REALTYPfloat, pf_mat) in // nothing end // end of [cblas_her2k] implement cblas_her2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let prval pf_mat = SYMAT_v_of_HEMAT_v (REALTYPdouble, view@ C) val () = cblas_dsyr2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) // end of [val] prval () = view@ C := HEMAT_v_of_SYMAT_v (REALTYPdouble, pf_mat) in // nothing end // end of [cblas_her2k] implement cblas_her2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let var alpha: ccmplx = alpha in cblas_cher2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) end // end of [cblas_her2k] implement cblas_her2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) = let var alpha: zcmplx = alpha in cblas_zher2k ( pfa | Order, Uplo, Trans, N, K, alpha, A, lda, B, ldb, beta, C, ldc ) end // end of [cblas_her2k] (* ****** ****** *) (* end of [cblas.hats] *) ats-lang-anairiats-0.2.11/contrib/pango/0000700000175000017500000000000012223166165016530 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/pango/CATS/0000700000175000017500000000000012223166165017262 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/pango/CATS/pango.cats0000664000175000017500000001233712223166165021264 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 /* ****** ****** */ #ifndef ATSCTRB_PANGO_PANGO_CATS #define ATSCTRB_PANGO_PANGO_CATS /* ****** ****** */ #include /* ****** ****** */ /* ****** ****** */ // // pango-attributes.h // #define atsctrb_pango_color_copy pango_color_copy #define atsctrb_pango_color_free pango_color_free #define atsctrb_pango_color_parser pango_color_parse #define atsctrb_pango_attribute_copy pango_attribute_copy #define atsctrb_pango_attribute_destroy pango_attribute_destroy #define atsctrb_pango_attribute_equal pango_attribute_equal #define atsctrb_pango_attr_foreground_new pango_attr_foreground_new #define atsctrb_pango_attr_background_new pango_attr_background_new #define atsctrb_pango_attr_list_new pango_attr_list_new #define atsctrb_pango_attr_list_ref pango_attr_list_ref #define atsctrb_pango_attr_list_unref pango_attr_list_unref #define atsctrb_pango_attr_list_copy pango_attr_list_copy #define atsctrb_pango_attr_list_insert pango_attr_list_insert #define atsctrb_pango_attr_list_insert_before pango_attr_list_insert_before #define atsctrb_pango_attr_list_change pango_attr_list_change /* ****** ****** */ // // pango-context.h // /* ****** ****** */ // // pango-font.h // #define atsctrb_pango_font_description_from_string \ pango_font_description_from_string #define atsctrb_pango_font_description_to_string \ pango_font_description_to_string #define atsctrb_pango_font_description_to_filename \ pango_font_description_to_filename #define atsctrb_pango_font_description_free pango_font_description_free /* ****** ****** */ // // pango-layout.h // #define atsctrb_pango_layout_new pango_layout_new #define atsctrb_pango_layout_copy pango_layout_copy // #define atsctrb_pango_layout_get_attributes pango_layout_get_attributes #define atsctrb_pango_layout_set_attributes pango_layout_set_attributes // #define atsctrb_pango_layout_get_text \ atsctrb_pango_layout_get_text #define atsctrb_pango_layout_set_text \ atsctrb_pango_layout_set_text #define atsctrb_pango_layout_setall_text(layout,text) \ pango_layout_set_text(layout, text, -1) // #define atsctrb_pango_layout_get_size pango_layout_get_size #define atsctrb_pango_layout_get_pixel_size pango_layout_get_pixel_size // #define atsctrb_pango_layout_get_width pango_layout_get_width #define atsctrb_pango_layout_set_width pango_layout_set_width #define atsctrb_pango_layout_get_height pango_layout_get_height #define atsctrb_pango_layout_set_height pango_layout_set_height // #define atsctrb_pango_layout_get_alignment pango_layout_get_alignment #define atsctrb_pango_layout_set_alignment pango_layout_set_alignment // #define atsctrb_pango_layout_get_wrap pango_layout_get_wrap #define atsctrb_pango_layout_set_wrap pango_layout_set_wrap #define atsctrb_pango_layout_is_wrapped pango_layout_is_wrapped // #define atsctrb_pango_layout_get_ellipsize pango_layout_get_ellipsize #define atsctrb_pango_layout_set_ellipsize pango_layout_set_ellipsize #define atsctrb_pango_layout_is_ellipsized pango_layout_is_ellipsized // #define atsctrb_pango_layout_get_indent pango_layout_get_indent #define atsctrb_pango_layout_set_indent pango_layout_set_indent #define atsctrb_pango_layout_get_spacing pango_layout_get_spacing #define atsctrb_pango_layout_set_spacing pango_layout_set_spacing // #define atsctrb_pango_layout_get_justify pango_layout_get_justify #define atsctrb_pango_layout_set_justify pango_layout_set_justify #define atsctrb_pango_layout_get_auto_dir pango_layout_get_auto_dir #define atsctrb_pango_layout_set_auto_dir pango_layout_set_auto_dir #define atsctrb_pango_layout_get_single_paragraph_mode \ pango_layout_get_single_paragraph_mode #define atsctrb_pango_layout_set_single_paragraph_mode \ pango_layout_set_single_paragraph_mode /* ****** ****** */ #endif // end of [ATSCTRB_PANGO_PANGO_CATS] /* end of [pango.cats] */ ats-lang-anairiats-0.2.11/contrib/pango/SATS/0000700000175000017500000000000012223166165017302 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/pango/SATS/pango.sats0000664000175000017500000000736612223166165021332 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 // (* ****** ****** *) // // API for pango in ATS // (* ****** ****** *) %{# #include "contrib/pango/CATS/pango.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // staload GLIB = "contrib/glib/SATS/glib.sats" // stadef gboolean (b:bool) = $GLIB.gboolean b stadef gboolean = $GLIB.gboolean // stadef gchar = $GLIB.gchar // stadef gint (n:int) = $GLIB.gint (n) stadef gint = $GLIB.gint stadef gint8 = $GLIB.gint8 stadef gint16 = $GLIB.gint16 stadef gint32 = $GLIB.gint32 // stadef guint (n:int) = $GLIB.guint (n) stadef guint = $GLIB.guint stadef guint8 = $GLIB.guint8 stadef guint16 = $GLIB.guint16 stadef guint32 = $GLIB.guint32 // stadef gdouble = $GLIB.gdouble stadef gfloat = $GLIB.gfloat // stadef gpointer = $GLIB.gpointer // stadef gstring = $GLIB.gstring stadef gstring0 = $GLIB.gstring0 stadef gstring1 = $GLIB.gstring1 // (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef gobjref = $GOBJ.gobjref (* ****** ****** *) absview PangoFree_v (l:addr) // for free Pango resources (* ****** ****** *) staload "contrib/pango/SATS/pangoclassdec.sats" viewtypedef PangoContext_ref (l:addr) = gobjref (PangoContext, l) viewtypedef PangoContext_ref0 = [l:agez] PangoContext_ref l viewtypedef PangoContext_ref1 = [l:addr | l > null] PangoContext_ref l viewtypedef PangoLayout_ref (l:addr) = gobjref (PangoLayout, l) viewtypedef PangoLayout_ref0 = [l:agez] PangoLayout_ref l viewtypedef PangoLayout_ref1 = [l:addr | l > null] PangoLayout_ref l (* ****** ****** *) (* #include #include #include #include #include #include #include #include #include #include #include #include #include #include *) (* ****** ****** *) #include "contrib/pango/SATS/pango/pango-attributes.sats" #include "contrib/pango/SATS/pango/pango-context.sats" #include "contrib/pango/SATS/pango/pango-font.sats" #include "contrib/pango/SATS/pango/pango-layout.sats" (* ****** ****** *) (* end of [pango.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/SATS/pango/0000700000175000017500000000000012223166165020406 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/pango/SATS/pango/pango-layout.sats0000664000175000017500000002131312223166165023735 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 (* ****** ****** *) abst@ype PangoAlignment = $extype"PangoAlignment" macdef PANGO_ALIGN_LEFT = $extval (PangoAlignment, "PANGO_ALIGN_LEFT") macdef PANGO_ALIGN_CENTER = $extval (PangoAlignment, "PANGO_ALIGN_CENTER") macdef PANGO_ALIGN_RIGHT = $extval (PangoAlignment, "PANGO_ALIGN_RIGHT") abst@ype PangoWrapMode = $extype"PangoWrapMode" macdef PANGO_WRAP_WORD = $extval (PangoWrapMode, "PANGO_WRAP_WORD") macdef PANGO_WRAP_CHAR = $extval (PangoWrapMode, "PANGO_WRAP_CHAR") macdef PANGO_WRAP_WORD_CHAR = $extval (PangoWrapMode, "PANGO_WRAP_WORD_CHAR") abst@ype PangoEllipsizeMode = $extype"PangoEllipsizeMode" macdef PANGO_ELLIPSIZE_NONE = $extval (PangoEllipsizeMode, "PANGO_ELLIPSIZE_NONE") macdef PANGO_ELLIPSIZE_START = $extval (PangoEllipsizeMode, "PANGO_ELLIPSIZE_START") macdef PANGO_ELLIPSIZE_MIDDLE = $extval (PangoEllipsizeMode, "PANGO_ELLIPSIZE_MIDDLE") macdef PANGO_ELLIPSIZE_END = $extval (PangoEllipsizeMode, "PANGO_ELLIPSIZE_END") (* ****** ****** *) fun pango_layout_new (): PangoLayout_ref1 = "mac#atsctrb_pango_layout_new" fun pango_layout_copy {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): PangoLayout_ref1 = "mac#atsctrb_pango_layout_copy" // end of [pango_layout_copy] (* ****** ****** *) // // HX-2010-05-24: this is a 'get0' function // fun pango_layout_get_attributes {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): [l1:addr] ( minus (gobjref (c, l), PangoAttrList_ref l1) | PangoAttrList_ref l1 ) = "mac#atsctrb_pango_layout_get_attributes" // end of [pango_layout_get_attributes] fun pango_layout_set_attributes {c:cls | c <= PangoLayout} {l,l1:addr | l > null} (layout: !gobjref (c, l), alist: !PangoAttrList_ref l1): void = "mac#atsctrb_pango_layout_set_attributes" // end of [pango_layout_set_attributes] (* ****** ****** *) fun pango_layout_get_text {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): [l1:addr] (gobjref (c, l), gstring l1 | gstring l1) = "mac#atsctrb_pango_layout_get_text" // end of [pango_layout_get_text] fun pango_layout_set_text {c:cls | c <= PangoLayout} {l:agz} {n0,n1:nat | n1 <= n0} (layout: !gobjref (c, l), text: &(@[gchar][n0]), n1: int n1): void = "mac#atsctrb_pango_layout_set_text" // end of [pango_layout_set_text] fun pango_layout_setall_text {c:cls | c <= PangoLayout} {l,l1:agz} (layout: !gobjref (c, l), text: !gstring l1): void = "mac#atsctrb_pango_layout_setall_text" // end of [pango_layout_setall_text] (* ****** ****** *) fun pango_layout_get_size {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), width: &int? >> int, height: &int? >> int): void = "mac#atsctrb_pango_layout_get_size" // end of [pango_layout_get_size] fun pango_layout_get_pixel_size {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), width: &int? >> int, height: &int? >> int): void = "mac#atsctrb_pango_layout_get_pixel_size" // end of [pango_layout_get_pixel_size] (* ****** ****** *) fun pango_layout_get_width {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): int = "mac#atsctrb_pango_layout_get_width" // end of [pango_layout_get_width] fun pango_layout_set_width {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), width: int): void = "mac#atsctrb_pango_layout_set_width" // end of [pango_layout_set_width] fun pango_layout_get_height {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): int = "mac#atsctrb_pango_layout_get_height" // end of [pango_layout_get_height] fun pango_layout_set_height {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), height: int): void = "mac#atsctrb_pango_layout_set_height" // end of [pango_layout_set_height] (* ****** ****** *) fun pango_layout_get_alignment {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): PangoAlignment = "mac#atsctrb_pango_layout_get_alignment" // end of [pango_layout_get_alignment] fun pango_layout_set_alignment {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), knd: PangoAlignment): void = "mac#atsctrb_pango_layout_set_alignment" // end of [pango_layout_set_alignment] (* ****** ****** *) fun pango_layout_get_wrap {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): PangoWrapMode = "mac#atsctrb_pango_layout_get_wrap" // end of [pango_layout_get_wrap] fun pango_layout_set_wrap {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), knd: PangoWrapMode): void = "mac#atsctrb_pango_layout_set_wrap" // end of [pango_layout_set_wrap] fun pango_layout_is_wrapped {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): gboolean = "mac#atsctrb_pango_layout_is_wrapped" // end of [pango_layout_is_wrapped] (* ****** ****** *) fun pango_layout_get_ellipsize {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): PangoEllipsizeMode = "mac#atsctrb_pango_layout_get_ellipsize" // end of [pango_layout_get_ellipsize] fun pango_layout_set_ellipsize {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), knd: PangoEllipsizeMode): void = "mac#atsctrb_pango_layout_set_ellipsize" // end of [pango_layout_set_ellipsize] fun pango_layout_is_ellipsized {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): gboolean = "mac#atsctrb_pango_layout_is_ellipsized" // end of [pango_layout_is_ellipsized] (* ****** ****** *) fun pango_layout_get_indent {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): int = "mac#atsctrb_pango_layout_get_indent" // end of [pango_layout_get_indent] fun pango_layout_set_indent {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), indent: int): void = "mac#atsctrb_pango_layout_set_indent" // end of [pango_layout_set_indent] fun pango_layout_get_spacing {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): int = "mac#atsctrb_pango_layout_get_spacing" // end of [pango_layout_get_spacing] fun pango_layout_set_spacing {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), spacing: int): void = "mac#atsctrb_pango_layout_set_spacing" // end of [pango_layout_set_spacing] (* ****** ****** *) fun pango_layout_get_justify {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): gboolean = "mac#atsctrb_pango_layout_get_justify" // end of [pango_layout_get_justify] fun pango_layout_set_justify {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), justify: gboolean): void = "mac#atsctrb_pango_layout_set_justify" // end of [pango_layout_set_justify] fun pango_layout_get_auto_dir {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): gboolean = "mac#atsctrb_pango_layout_get_auto_dir" // end of [pango_layout_get_auto_dir] fun pango_layout_set_auto_dir {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), auto_dir: gboolean): void = "mac#atsctrb_pango_layout_set_auto_dir" // end of [pango_layout_set_auto_dir] (* ****** ****** *) fun pango_layout_get_single_paragraph_mode {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l)): gboolean = "mac#atsctrb_pango_layout_get_single_paragraph_mode" // end of [pango_layout_get_single_paragraph_mode] fun pango_layout_set_single_paragraph_mode {c:cls | c <= PangoLayout} {l:agz} (layout: !gobjref (c, l), setting: gboolean): void = "mac#atsctrb_pango_layout_set_single_paragraph_mode" // end of [pango_layout_set_single_paragraph_mode] (* ****** ****** *) (* end of [pango-layout.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/SATS/pango/pango-attributes.sats0000664000175000017500000001552112223166165024612 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 // (* ****** ****** *) typedef PangoColor = $extype_struct "PangoColor" of { red= guint16 , green= guint16 , blue= guint16 } // end of [PangoColor] (* ****** ****** *) fun pango_color_copy ( src: &PangoColor ) : [l:addr] (PangoColor @ l | ptr l) = "mac#atsctrb_pango_color_copy" // end of [pango_color_copy] fun pango_color_free {l:addr} ( pf1: PangoFree_v l, pf2: PangoColor @ l | p: ptr l ) : void = "mac#atsctrb_pango_color_free" // end of [pango_color_free] fun pango_color_parse {l:agz} ( clr: &PangoColor? >> opt (PangoColor, b), spec: !gstring l ) : #[b: bool] gboolean b = "mac#atsctrb_pango_color_parse" // end of [pango_color_parse] (* ****** ****** *) abst@ype PangoAttrType = $extype"PangoAttrType" macdef PANGO_ATTR_INVALID = $extval (PangoAttrType, "PANGO_ATTR_INVALID") macdef PANGO_ATTR_LANGUAGE = $extval (PangoAttrType, "PANGO_ATTR_LANGUAGE") macdef PANGO_ATTR_FAMILY = $extval (PangoAttrType, "PANGO_ATTR_FAMILY") macdef PANGO_ATTR_STYLE = $extval (PangoAttrType, "PANGO_ATTR_STYLE") macdef PANGO_ATTR_WEIGHT = $extval (PangoAttrType, "PANGO_ATTR_WEIGHT") macdef PANGO_ATTR_VARIANT = $extval (PangoAttrType, "PANGO_ATTR_VARIANT") macdef PANGO_ATTR_STRETCH = $extval (PangoAttrType, "PANGO_ATTR_STRETCH") macdef PANGO_ATTR_SIZE = $extval (PangoAttrType, "PANGO_ATTR_SIZE") macdef PANGO_ATTR_FONT_DESC = $extval (PangoAttrType, "PANGO_ATTR_FONT_DESC") macdef PANGO_ATTR_FOREGROUND = $extval (PangoAttrType, "PANGO_ATTR_FOREGROUND") macdef PANGO_ATTR_BACKGROUND = $extval (PangoAttrType, "PANGO_ATTR_BACKGROUND") macdef PANGO_ATTR_UNDERLINE = $extval (PangoAttrType, "PANGO_ATTR_UNDERLINE") macdef PANGO_ATTR_STRIKETHROUGH = $extval (PangoAttrType, "PANGO_ATTR_STRIKETHROUGH") macdef PANGO_ATTR_RISE = $extval (PangoAttrType, "PANGO_ATTR_RISE") macdef PANGO_ATTR_SHAPE = $extval (PangoAttrType, "PANGO_ATTR_SHAPE") macdef PANGO_ATTR_SCALE = $extval (PangoAttrType, "PANGO_ATTR_SCALE") macdef PANGO_ATTR_FALLBACK = $extval (PangoAttrType, "PANGO_ATTR_FALLBACK") macdef PANGO_ATTR_LETTER_SPACING = $extval (PangoAttrType, "PANGO_ATTR_LETTER_SPACING") macdef PANGO_ATTR_UNDERLINE_COLOR = $extval (PangoAttrType, "PANGO_ATTR_UNDERLINE_COLOR") macdef PANGO_ATTR_STRIKETHROUGH_COLOR = $extval (PangoAttrType, "PANGO_ATTR_STRIKETHROUGH_COLOR") macdef PANGO_ATTR_ABSOLUTE_SIZE = $extval (PangoAttrType, "PANGO_ATTR_ABSOLUTE_SIZE") (* ****** ****** *) abst@ype PangoUnderline = $extype"PangoUnderline" macdef PANGO_UNDERLINE_NONE = $extval (PangoUnderline, "PANGO_UNDERLINE_NONE") macdef PANGO_UNDERLINE_SINGLE = $extval (PangoUnderline, "PANGO_UNDERLINE_SINGLE") macdef PANGO_UNDERLINE_DOUBLE = $extval (PangoUnderline, "PANGO_UNDERLINE_DOUBLE") macdef PANGO_UNDERLINE_LOW = $extval (PangoUnderline, "PANGO_UNDERLINE_LOW") macdef PANGO_UNDERLINE_ERROR = $extval (PangoUnderline, "PANGO_UNDERLINE_ERROR") (* ****** ****** *) typedef PangoAttribute = $extype_struct "PangoAttribute" of { start_index= guint, end_index= guint , _rest = undefined_t // this field cannot be accessed } // end of [PangoAttribute] absviewtype PangoAttribute_ptr (l:addr) // HX: _not_ refcounted viewtypedef PangoAttribute_ptr1 = [l:addr | l > null] PangoAttribute_ptr l (* ****** ****** *) fun pango_attribute_copy {l:agz} ( attr: !PangoAttribute_ptr l ) : [l_new:addr] PangoAttribute_ptr l_new = "mac#atsctrb_pango_attribute_copy" // end of [pango_attribute_copy] fun pango_attribute_destroy {l:agz} ( attr: PangoAttribute_ptr l ) : void = "mac#atsctrb_pango_attribute_destroy" // end of [pango_attribute_destroy] fun pango_attribute_equal {l1,l2:agz} ( attr1: PangoAttribute_ptr l1, attr2: PangoAttribute_ptr l2 ) : gboolean = "mac#atsctrb_pango_attribute_equal" // end of [pango_attribute_equal] (* ****** ****** *) fun pango_attr_foreground_new (r: guint16, g: guint16, b: guint16): PangoAttribute_ptr1 = "mac#atsctrb_pango_attr_foreground_new" // end of [pango_attr_foreground_new] fun pango_attr_background_new (r: guint16, g: guint16, b: guint16): PangoAttribute_ptr1 = "mac#atsctrb_pango_attr_background_new" // end of [pango_attr_background_new] (* ****** ****** *) absviewtype PangoAttrList_ref (l:addr) viewtypedef PangoAttrList_ref1 = [l:addr | l > null] PangoAttrList_ref (l) (* ****** ****** *) fun pango_attr_list_new (): PangoAttrList_ref1 = "mac#atsctrb_pango_attr_list_new" fun pango_attr_list_ref {l:agz} (alist: !PangoAttrList_ref l): PangoAttrList_ref l = "mac#atsctrb_pango_attr_list_ref" fun pango_attr_list_unref {l:agz} (alist: PangoAttrList_ref l): void = "mac#atsctrb_pango_attr_list_unref" fun pango_attr_list_copy {l:agz} (alist: !PangoAttrList_ref l): PangoAttrList_ref1 = "mac#atsctrb_pango_attr_list_copy" // HX: [attr] is owned by [alist] after the call fun pango_attr_list_insert {l1,l2:agz} ( alist: !PangoAttrList_ref l1, attr: PangoAttribute_ptr l2 ) : void = "mac#atsctrb_pango_attr_list_insert" // end of [pango_attr_list_insert] // HX: [attr] is owned by [alist] after the call fun pango_attr_list_insert_before {l1,l2:agz} (alist: !PangoAttrList_ref l1, attr: PangoAttribute_ptr l2): void = "mac#atsctrb_pango_attr_list_insert_before" // end of [pango_attr_list_insert_before] // HX: [attr] is owned by [alist] after the call fun pango_attr_list_change {l1,l2:agz} ( alist: !PangoAttrList_ref l1, attr: PangoAttribute_ptr l2 ) : void = "mac#atsctrb_pango_attr_list_change" // end of [pango_attr_list_change] (* ****** ****** *) (* end of [pango-attributes.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/SATS/pango/pango-context.sats0000664000175000017500000000314012223166165024102 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 (* ****** ****** *) // // API for pango in ATS // (* ****** ****** *) (* ****** ****** *) (* end of [pango-context.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/SATS/pango/pango-font.sats0000664000175000017500000002322712223166165023374 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 (* ****** ****** *) // // API for pango in ATS // (* ****** ****** *) abst@ype PangoStyle = $extype"PangoStyle" macdef PANGO_STYLE_NORMAL = $extval (PangoStyle, "PANGO_STYLE_NORMAL") macdef PANGO_STYLE_OBLIQUE = $extval (PangoStyle, "PANGO_STYLE_OBLIQUE") macdef PANGO_STYLE_ITALIC = $extval (PangoStyle, "PANGO_STYLE_ITALIC") (* ****** ****** *) abst@ype PangoVariant = $extype"PangoVariant" macdef PANGO_VARIANT_NORMAL = $extval (PangoVariant, "PANGO_VARIANT_NORMAL") macdef PANGO_VARIANT_SMALL_CAPS = $extval (PangoVariant, "PANGO_VARIANT_SMALL_CAPS") (* ****** ****** *) abst@ype PangoWeight = $extype"PangoWeight" macdef PANGO_WEIGHT_ULTRALIGHT = $extval (PangoWeight, "PANGO_WEIGHT_ULTRALIGHT") macdef PANGO_WEIGHT_LIGHT = $extval (PangoWeight, "PANGO_WEIGHT_LIGHT") macdef PANGO_WEIGHT_NORMAL = $extval (PangoWeight, "PANGO_WEIGHT_NORMAL") macdef PANGO_WEIGHT_SEMIBOLD = $extval (PangoWeight, "PANGO_WEIGHT_SEMIBOLD") macdef PANGO_WEIGHT_BOLD = $extval (PangoWeight, "PANGO_WEIGHT_BOLD") macdef PANGO_WEIGHT_ULTRABOLD = $extval (PangoWeight, "PANGO_WEIGHT_ULTRABOLD") macdef PANGO_WEIGHT_HEAVY = $extval (PangoWeight, "PANGO_WEIGHT_HEAVY") (* ****** ****** *) abst@ype PangoStretch = $extype"PangoStretch" macdef PANGO_STRETCH_ULTRA_CONDENSED = $extval (PangoStretch, "PANGO_STRETCH_ULTRA_CONDENSED") macdef PANGO_STRETCH_EXTRA_CONDENSED = $extval (PangoStretch, "PANGO_STRETCH_EXTRA_CONDENSED") macdef PANGO_STRETCH_CONDENSED = $extval (PangoStretch, "PANGO_STRETCH_CONDENSED") macdef PANGO_STRETCH_SEMI_CONDENSED = $extval (PangoStretch, "PANGO_STRETCH_SEMI_CONDENSED") macdef PANGO_STRETCH_NORMAL = $extval (PangoStretch, "PANGO_STRETCH_NORMAL") macdef PANGO_STRETCH_SEMI_EXPANDED = $extval (PangoStretch, "PANGO_STRETCH_SEMI_EXPANDED") macdef PANGO_STRETCH_EXPANDED = $extval (PangoStretch, "PANGO_STRETCH_EXPANDED") macdef PANGO_STRETCH_EXTRA_EXPANDED = $extval (PangoStretch, "PANGO_STRETCH_EXTRA_EXPANDED") macdef PANGO_STRETCH_ULTRA_EXPANDED = $extval (PangoStretch, "PANGO_STRETCH_ULTRA_EXPANDED") (* ****** ****** *) abst@ype PangoFontMask = $extype"PangoFontMask" macdef PANGO_FONT_MASK_FAMILY = $extval (PangoFontMask, "PANGO_FONT_MASK_FAMILY") macdef PANGO_FONT_MASK_STYLE = $extval (PangoFontMask, "PANGO_FONT_MASK_STYLE") macdef PANGO_FONT_MASK_VARIANT = $extval (PangoFontMask, "PANGO_FONT_MASK_VARIANT") macdef PANGO_FONT_MASK_WEIGHT = $extval (PangoFontMask, "PANGO_FONT_MASK_WEIGHT") macdef PANGO_FONT_MASK_STRETCH = $extval (PangoFontMask, "PANGO_FONT_MASK_STRETCH") macdef PANGO_FONT_MASK_SIZE = $extval (PangoFontMask, "PANGO_FONT_MASK_SIZE") (* ****** ****** *) macdef PANGO_SCALE_XX_SMALL = $extval (double, "PANGO_SCALE_XX_SMALL") macdef PANGO_SCALE_X_SMALL = $extval (double, "PANGO_SCALE_X_SMALL") macdef PANGO_SCALE_SMALL = $extval (double, "PANGO_SCALE_SMALL") macdef PANGO_SCALE_MEDIUM = $extval (double, "PANGO_SCALE_MEDIUM") macdef PANGO_SCALE_LARGE = $extval (double, "PANGO_SCALE_LARGE") macdef PANGO_SCALE_X_LARGE = $extval (double, "PANGO_SCALE_X_LARGE") macdef PANGO_SCALE_XX_LARGE = $extval (double, "PANGO_SCALE_XX_LARGE") (* ****** ****** *) absviewtype PangoFontDescription_ptr (l:addr) viewtypedef PangoFontDescription_ptr0 = [l:addr] PangoFontDescription_ptr l viewtypedef PangoFontDescription_ptr1 = [l:addr | l > null] PangoFontDescription_ptr l castfn ptr_of_PangoFontDescription_ptr {l:addr} (x: !PangoFontDescription_ptr l): ptr l overload ptr_of with ptr_of_PangoFontDescription_ptr (* ****** ****** *) fun pango_font_description_new (): PangoFontDescription_ptr1 = "mac#atsctrb_pango_font_description_new" // end of [pango_font_description_new] fun pango_font_description_copy {l:agz} ( fd: !PangoFontDescription_ptr l ) : PangoFontDescription_ptr l = "mac#atsctrb_pango_font_description_copy" // end of [pango_font_description_copy] fun pango_font_description_copy_static // shallow copy {l:agz} ( fd: !PangoFontDescription_ptr l ) : PangoFontDescription_ptr l = "mac#atsctrb_pango_font_description_copy_static" // end of [pango_font_description_copy] fun pango_font_description_hash {l:agz} ( fd: !PangoFontDescription_ptr l ) : guint = "mac#atsctrb_pango_font_description_hash" // end of [pango_font_description_hash] fun pango_font_description_equal {l1,l2:agz} ( fd1: !PangoFontDescription_ptr l1, fd2: !PangoFontDescription_ptr l2 ) : gboolean = "mac#atsctrb_pango_font_description_hash" // end of [pango_font_description_hash] fun pango_font_description_free {l:agz} (fd: PangoFontDescription_ptr l): void = "mac#atsctrb_pango_font_description_free" // end of [pango_font_description_free] (* ****** ****** *) fun pango_font_description_get_family {l:agz} ( fd: !PangoFontDescription_ptr l ) : [l1:addr] ( minus (PangoFontDescription_ptr l, gstring l1) | gstring l1 ) = "mac#atsctrb_pango_font_description_get_family" fun pango_font_description_set_family {l1,l2:agz} ( fd: !PangoFontDescription_ptr l1, family: !gstring l2 ) : void = "mac#atsctrb_pango_font_description_set_family" fun pango_font_description_get_stretch {l:agz} ( fd: !PangoFontDescription_ptr l ) : PangoStretch = "mac#atsctrb_pango_font_description_get_stretch" fun pango_font_description_set_stretch {l:agz} ( fd: !PangoFontDescription_ptr l, stretch: PangoStretch ) : void = "mac#atsctrb_pango_font_description_set_stretch" fun pango_font_description_get_style {l:agz} (fd: !PangoFontDescription_ptr l): PangoStyle = "mac#atsctrb_pango_font_description_get_style" fun pango_font_description_set_style {l:agz} (fd: !PangoFontDescription_ptr l, style: PangoStyle): void = "mac#atsctrb_pango_font_description_set_style" fun pango_font_description_get_variant {l:agz} (fd: !PangoFontDescription_ptr l): PangoVariant = "mac#atsctrb_pango_font_description_get_variant" fun pango_font_description_set_variant {l:agz} ( fd: !PangoFontDescription_ptr l, variant: PangoVariant ) : void = "mac#atsctrb_pango_font_description_set_variant" fun pango_font_description_get_weight {l:agz} ( fd: !PangoFontDescription_ptr l ) : PangoWeight = "mac#atsctrb_pango_font_description_get_weight" fun pango_font_description_set_weight {l:agz} ( fd: !PangoFontDescription_ptr l, weight: PangoWeight ) : void = "mac#atsctrb_pango_font_description_set_weight" (* ****** ****** *) fun pango_font_description_get_size {l:agz} ( fd: !PangoFontDescription_ptr l ) : gint = "mac#atsctrb_pango_font_description_get_size" fun pango_font_description_set_size {l:agz} ( fd: !PangoFontDescription_ptr l, size: gint ) : void = "mac#atsctrb_pango_font_description_set_size" fun pango_font_description_set_absolute_size {l:agz} ( fd: !PangoFontDescription_ptr l, size: gdouble ) : void = "mac#atsctrb_pango_font_description_set_absolute_size" fun pango_font_description_get_size_is_absolute {l:agz} ( fd: !PangoFontDescription_ptr l ) : gboolean = "mac#atsctrb_pango_font_description_get_size_is_absolute" (* ****** ****** *) (* fun pango_font_description_get_gravity {l:agz} (fd: !PangoFontDescription_ptr l): PangoGravity = "mac#atsctrb_pango_font_description_get_gravity" fun pango_font_description_set_gravity {l:agz} (fd: !PangoFontDescription_ptr l, gravity: PangoGravity): void = "mac#atsctrb_pango_font_description_set_gravity" *) (* ****** ****** *) fun pango_font_description_get_set_fields {l:agz} ( fd: !PangoFontDescription_ptr l ) : PangoFontMask = "mac#atsctrb_pango_font_description_get_set_fields" fun pango_font_description_unset_fields {l:agz} ( fd: !PangoFontDescription_ptr l, mask: PangoFontMask ) : void = "mac#atsctrb_pango_font_description_unset_fields" (* ****** ****** *) fun pango_font_description_from_string {l:agz} ( name: !gstring l ) : PangoFontDescription_ptr1 = "mac#atsctrb_pango_font_description_from_string" // end of [pango_font_description_from_string] fun pango_font_description_to_string {l:agz} ( fd: !PangoFontDescription_ptr l ) : gstring1 = "mac#atsctrb_pango_font_description_to_string" // end of [pango_font_description_to_string] fun pango_font_description_to_filename {l:agz} ( fd: !PangoFontDescription_ptr l ) : gstring1 = "mac#atsctrb_pango_font_description_to_filename" // end of [pango_font_description_to_filename] (* ****** ****** *) (* end of [pango-font.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/SATS/pangoclassdec.sats0000664000175000017500000000347112223166165023025 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2009-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) staload GOBJ = "contrib/glib/SATS/glib-object.sats" stadef GObject = $GOBJ.GObject (* ****** ****** *) // // class hierarchy for Pango // classdec PangoContext : GObject classdec PangoLayout : GObject (* ****** ****** *) (* end of [pangoclassdec.sats] *) ats-lang-anairiats-0.2.11/contrib/pango/Makefile0000664000175000017500000000105412223166165020204 0ustar hwxihwxi# # API for pango in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: May, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc PANGOCFLAGS=`pkg-config pango --cflags` ###### all:: atsctrb_pango.o all:: clean ###### atsctrb_pango.o: pango_dats.o ld -r -o $@ pango_dats.o ###### pango_dats.o: DATS/pango.dats $(ATSCC) $(PANGOCFLAGS) -o $@ -c DATS/pango.dats ###### clean:: rm -f *_?ats.c *_?ats.o cleanall: clean rm -f atsctrb_pango.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/pango/DATS/0000700000175000017500000000000012223166165017263 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/pango/DATS/pango.dats0000664000175000017500000000326012223166165021261 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: May, 2010 // (* ****** ****** *) // // API for pango in ATS // (* ****** ****** *) staload "contrib/pango/SATS/pango.sats" (* ****** ****** *) // it is still empty (* ****** ****** *) (* end of [pango.sats] *) ats-lang-anairiats-0.2.11/contrib/X11/0000700000175000017500000000000012223166165015775 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/X11/CATS/0000700000175000017500000000000012223166165016527 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/X11/CATS/Xlib.cats0000664000175000017500000002635412223166165020327 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_XLIB_XLIB_CATS #define ATSCTRB_XLIB_XLIB_CATS /* ****** ****** */ #include "X11/Xlib.h" #include "X11/Xutil.h" /* ****** ****** */ // // Chapter 2: Display Functions // /* ****** ****** */ #define atsctrb_XOpenDisplay XOpenDisplay /* ****** ****** */ #define atsctrb_XAllPlanes XAllPlanes #define atsctrb_XBlackPixel XBlackPixel #define atsctrb_XWhitePixel XWhitePixel #define atsctrb_XConnectionNumber XConnectionNumber #define atsctrb_XDefaultColormap XDefaultColormap #define atsctrb_XDefaultDepth XDefaultDepth #define atsctrb_XListDepths XListDepths // this is a function #define atsctrb_XDefaultGC XDefaultGC #define atsctrb_XDefaultRootWindow XDefaultRootWindow #define atsctrb_XDefaultScreenOfDisplay XDefaultScreenOfDisplay #define atsctrb_XScreenOfDisplay XScreenOfDisplay #define atsctrb_XDefaultScreen XDefaultScreen #define atsctrb_XDefaultVisual XDefaultVisual #define atsctrb_XDisplayCells XDisplayCells #define atsctrb_XDisplayPlanes XDisplayPlanes #define atsctrb_XDisplayString XDisplayString #define atsctrb_XMaxRequestSize XMaxRequestSize #define atsctrb_XLastKnownRequestProcessed XLastKnownRequestProcessed #define atsctrb_XNextRequest XNextRequest #define atsctrb_XProtocolVersion XProtocolVersion #define atsctrb_XProtocolRevision XProtocolRevision #define atsctrb_XQLength XQLength #define atsctrb_XRootWindow XRootWindow #define atsctrb_XScreenCount XScreenCount #define atsctrb_XServerVendor XServerVendor #define atsctrb_XVendorRelease XVendorRelease /* ****** ****** */ #define atsctrb_XListPixmapFormats XListPixmapFormats #define atsctrb_XImageByteOrder XImageByteOrder #define atsctrb_XBitmapUnit XBitmapUnit #define atsctrb_XBitmapOrder XBitmapOrder #define atsctrb_XBitmapPad XBitmapPad #define atsctrb_XDisplayHeight DisplayHeight #define atsctrb_XDisplayHeightMM DisplayHeightMM #define atsctrb_XDisplayWidth DisplayWidth #define atsctrb_XDisplayWidthMM DisplayWidthMM /* ****** ****** */ #define atsctrb_XNoOp XNoOp /* ****** ****** */ #define atsctrb_XFree XFree /* ****** ****** */ #define atsctrb_XCloseDisplay XCloseDisplay /* ****** ****** */ // // Chapter 3: Window Functions // /* ****** ****** */ #define atsctrb_XVisualIDFromVisual XVisualIDFromVisual #define atsctrb_XCreateWindow XCreateWindow #define atsctrb_XCreateSimpleWindow XCreateSimpleWindow #define atsctrb_XDestroyWindow XDestroyWindow #define atsctrb_XDestroyWindow XDestroyWindow #define atsctrb_XMapWindow XMapWindow #define atsctrb_XMapRaised XMapRaised #define atsctrb_XMapSubwindows XMapSubwindows #define atsctrb_XUnmapWindow XUnmapWindow #define atsctrb_XUnmapSubwindows XUnmapSubwindows #define atsctrb_XConfigureWindow XConfigureWindow #define atsctrb_XMoveWindow XMoveWindow #define atsctrb_XResizeWindow XResizeWindow #define atsctrb_XMoveResizeWindow XMoveResizeWindow #define atsctrb_XSetWindowBorderWidth XSetWindowBorderWidth #define atsctrb_XRaiseWindow XRaiseWindow #define atsctrb_XLowerWindow XLowerWindow #define atsctrb_XCirculateSubwindows XCirculateSubwindows #define atsctrb_XCirculateSubwindowsUp XCirculateSubwindowsUp #define atsctrb_XCirculateSubwindowsDown XCirculateSubwindowsDown #define atsctrb_XRestackWindows XRestackWindows #define atsctrb_XChangeWindowAttributes XChangeWindowAttributes #define atsctrb_XSetWindowBackground XSetWindowBackground #define atsctrb_XSetWindowBackgroundPixmap XSetWindowBackgroundPixmap #define atsctrb_XSetWindowBorder XSetWindowBorder #define atsctrb_XSetWindowBorderPixmap XSetWindowBorderPixmap #define atsctrb_XSetWindowColormap XSetWindowColormap #define atsctrb_XDefineCursor XDefineCursor #define atsctrb_XUndefineCursor XUndefineCursor /* ****** ****** */ // // Chapter 4: Window Information Functions // /* ****** ****** */ #define atsctrb_XQueryTree XQueryTree #define atsctrb_XGetWindowAttributes XGetWindowAttributes #define atsctrb_XGetWindowAttributes XGetWindowAttributes /* ****** ****** */ // // Chapter 5: Creating and Freeing Pixmaps // /* ****** ****** */ #define atsctrb_XCreatePixmap XCreatePixmap #define atsctrb_XFreePixmap XFreePixmap #define atsctrb_XCreateFontCursor XCreateFontCursor #define atsctrb_XFreeCursor XFreeCursor /* ****** ****** */ // // Chapter 6: Color Management Functions // /* ****** ****** */ #define atsctrb_XCreateColormap XCreateColormap #define atsctrb_XCopyColormapAndFree XCopyColormapAndFree #define atsctrb_XFreeColormap XFreeColormap #define atsctrb_XLookupColor XLookupColor #define atsctrb_XParseColor XParseColor #define atsctrb_XAllocColor XAllocColor #define atsctrb_XAllocNamedColor XAllocNamedColor #define atsctrb_XStoreColor XStoreColor #define atsctrb_XStoreColors XStoreColors #define atsctrb_XStoreNamedColor XStoreNamedColor #define atsctrb_XQueryColor XQueryColor #define atsctrb_XQueryColors XQueryColors /* ****** ****** */ // // Chapter 7: Graphics Context Functions // /* ****** ****** */ #define atsctrb_XCreateGC XCreateGC #define atsctrb_XCopyGC XCopyGC #define atsctrb_XChangeGC XChangeGC #define atsctrb_XGetGCValues XGetGCValues #define atsctrb_XFreeGC XFreeGC #define atsctrb_XFlushGC XFlushGC #define atsctrb_XSetForeground XSetForeground #define atsctrb_XSetBackground XSetBackground #define atsctrb_XSetFunction XSetFunction #define atsctrb_XSetPlaneMask XSetPlaneMask #define atsctrb_XSetFont XSetFont #define atsctrb_XSetLineAttributes XSetLineAttributes #define atsctrb_XSetDashes XSetDashes /* ****** ****** */ // // Chapter 8: Graphics Functions // /* ****** ****** */ #define atsctrb_XClearArea XClearArea #define atsctrb_XClearWindow XClearWindow #define atsctrb_XCopyArea XCopyArea #define atsctrb_XCopyPlane XCopyPlane #define atsctrb_XDrawPoint XDrawPoint #define atsctrb_XDrawPoints XDrawPoints #define atsctrb_XDrawLine XDrawLine #define atsctrb_XDrawLines XDrawLines #define atsctrb_XDrawSegments XDrawSegments #define atsctrb_XDrawRectangle XDrawRectangle #define atsctrb_XDrawRectangles XDrawRectangles #define atsctrb_XDrawArc XDrawArc #define atsctrb_XDrawArcs XDrawArcs #define atsctrb_XFillRectangle XFillRectangle #define atsctrb_XFillRectangles XFillRectangles #define atsctrb_XFillPolygon XFillPolygon #define atsctrb_XFillArc XFillArc #define atsctrb_XFillArcs XFillArcs #define atsctrb_XLoadFont XLoadFont #define atsctrb_XQueryFont XQueryFont #define atsctrb_XLoadQueryFont XLoadQueryFont #define atsctrb_XFreeFont XFreeFont #define atsctrb_XTextWidth XTextWidth #define atsctrb_XTextWidth16 XTextWidth16 #define atsctrb_XDrawString XDrawString #define atsctrb_XDrawString16 XDrawString16 #define atsctrb_XDrawImageString XDrawImageString #define atsctrb_XDrawImageString16 XDrawImageString16 /* ****** ****** */ // // Chapter 9: Window and Session Manager Functions // /* ****** ****** */ #define atsctrb_XReparentWindow XReparentWindow #define atsctrb_XChangeSaveSet XChangeSaveSet #define atsctrb_XAddSaveSet XAddSaveSet #define atsctrb_XRemoveFromSaveSet XRemoveFromSaveSet #define atsctrb_XInstallColormap XInstallColormap #define atsctrb_XUninstallColormap XUninstallColormap #define atsctrb_XListInstalledColormaps XListInstalledColormaps #define atsctrb_XGrabServer XGrabServer #define atsctrb_XUngrabServer XUngrabServer #define atsctrb_XKillClient XKillClient #define atsctrb_XSetScreenSaver XSetScreenSaver #define atsctrb_XForceScreenSaver XForceScreenSaver #define atsctrb_XActivateScreenSaver XActivateScreenSaver #define atsctrb_XResetScreenSaver XResetScreenSaver #define atsctrb_XGetScreenSaver XGetScreenSaver #define atsctrb_XAddHost XAddHost #define atsctrb_XAddHosts XAddHosts #define atsctrb_XListHosts XListHosts #define atsctrb_XRemoveHost XRemoveHost #define atsctrb_XRemoveHosts XRemoveHosts #define atsctrb_XSetAccessControl XSetAccessControl #define atsctrb_XEnableAccessControl XEnableAccessControl #define atsctrb_XDisableAccessControl XDisableAccessControl /* ****** ****** */ // // Chapter 11: Event Handling Functions // /* ****** ****** */ #define atsctrb_XSelectInput XSelectInput #define atsctrb_XFlush XFlush #define atsctrb_XSync XSync /* ****** ****** */ // // Chapter 14: Inter-client communication functions // /* ****** ****** */ #define atsctrb_XIconifyWindow XIconifyWindow #define atsctrb_XDestroyWindow XDestroyWindow #define atsctrb_XReconfigureWMWindow XReconfigureWMWindow #define atsctrb_XDefaultString XDefaultString // static inline Status atsctrb_XStringToTextProperty ( ats_ptr_type str, ats_ref_type text ) { return XStringListToTextProperty((char**)&str, 1, (XTextProperty*)text) ; } // end of [XStringToTextProperty] #define atsctrb_XStringListToTextProperty XStringListToTextProperty // #define atsctrb_XTextPropertyToStringList XTextPropertyToStringList #define atsctrb_XFreeStringList XFreeStringList // #define atsctrb_XSetTextProperty XSetTextProperty #define atsctrb_XGetTextProperty XGetTextProperty #define atsctrb_XSetWMName XSetWMName #define atsctrb_XGetWMName XGetWMName #define atsctrb_XStoreName XStoreName #define atsctrb_XFetchName XFetchName #define atsctrb_XSetWMIconName XSetWMIconName #define atsctrb_XGetWMIconName XGetWMIconName #define atsctrb_XSetIconName XSetIconName #define atsctrb_XGetIconName XGetIconName #define atsctrb_XSetTransientForHint XSetTransientForHint #define atsctrb_XGetTransientForHint XGetTransientForHint // #define atsctrb_XAllocWMHints XAllocWMHints #define atsctrb_XAllocSizeHints XAllocSizeHints #define atsctrb_XAllocClassHint XAllocClassHint #define atsctrb_XEventsQueued XEventsQueued #define atsctrb_XPending XPending #define atsctrb_XNextEvent XNextEvent #define atsctrb_XPeekEvent XPeekEvent // #define atsctrb_XSetWMProperties XSetWMProperties /* ****** ****** */ // // Chapter 16: Application Unitility Functions // /* ****** ****** */ #define atsctrb_XCreatePixmapFromBitmapData XCreatePixmapFromBitmapData #define atsctrb_XCreateBitmapFromData XCreateBitmapFromData /* ****** ****** */ #endif // end of [ATSCTRB_XLIB_XLIB_CATS] /* end of [Xlib.cats] */ ats-lang-anairiats-0.2.11/contrib/X11/CATS/X.cats0000664000175000017500000000424112223166165017627 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 /* ****** ****** */ #ifndef ATSCTRB_XLIB_X_CATS #define ATSCTRB_XLIB_X_CATS /* ****** ****** */ #include "X11/X.h" /* ****** ****** */ typedef ats_lint_type InputEventMask_t; static inline InputEventMask_t atsctrb_lor_InputEventMask_InputEventMask (InputEventMask_t x, InputEventMask_t y) { return (x | y) ; } // end of [atsctrb_lor_InputEventMask_InputEventMask] /* ****** ****** */ typedef ats_int_type EventType_t; static inline ats_bool_type atsctrb_eq_EventType_EventType (EventType_t x, EventType_t y) { return (x==y ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_EventType_EventType] /* ****** ****** */ #endif // end of [ATSCTRB_XLIB_X_CATS] /* end of [X.cats] */ ats-lang-anairiats-0.2.11/contrib/X11/SATS/0000700000175000017500000000000012223166165016547 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/X11/SATS/Xlib.sats0000664000175000017500000016412312223166165020364 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: January, 2010 // (* ****** ****** *) %{# #include "contrib/X11/CATS/Xlib.cats" %} // end of [{%#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "contrib/X11/SATS/X.sats" (* ****** ****** *) // these are for resources allocated by absviewtype XPtr (a:viewt@ype, l:addr) viewtypedef XPtr0 (a:viewt@ype) = [l:addr] XPtr (a, l) viewtypedef XPtr1 (a:viewt@ype) = [l:addr | l > null] XPtr (a, l) // prfun XPtr_viewget {a:viewt@ype} {l:agz} (x: !XPtr (a, l)): (a @ l, minus (XPtr (a, l), a @ l)) // castfn ptr_of_XPtr {a:viewt@ype} {l:addr} (x: !XPtr (a, l)): ptr l overload ptr_of with ptr_of_XPtr // absviewtype XArray (a:viewt@ype, n:int, l:addr) viewtypedef XArray1 (a:viewt@ype, n:int) = [l:agz] XArray (a, n, l) // prfun XArray_viewget {a:viewt@ype} {n:nat} {l:agz} (x: !XArray (a, n, l)) : (array_v (a, n, l), minus (XArray (a, n, l), array_v (a, n, l))) // castfn ptr_of_XArray {a:viewt@ype} {n:nat} {l:addr} (x: !XArray (a, n, l)): ptr l overload ptr_of with ptr_of_XArray // absviewtype XString (l:addr) viewtypedef XString0 = [l:agez] XString (l) viewtypedef XString1 = [l:addr | l > null] XString (l) // castfn ptr_of_XString {l:addr} (x: !XString (l)): ptr l overload ptr_of with ptr_of_XString // // HX: for a array of linear strings: // absviewtype XStrarr (n:int, l:addr) // array + strings are allocated by XAlloc viewtypedef XStrarr1 (n:int) = [l:addr | l > null] XStrarr (n, l) (* ****** ****** *) fun XPtrFree {a:viewt@ype} {l:addr} ( x: XPtr (a, l) ) : void = "mac#atsctrb_XFree" // end of [XPtrFree] fun XArrayFree {a:viewt@ype} {n:nat} {l:addr} ( x: XArray (a, n, l) ) : void = "mac#atsctrb_XFree" // end of [XArrayFree] fun XStringFree {a:viewt@ype} {l:addr} ( x: XString l ) : void = "mac#atsctrb_XFree" // end of [XStringFree] (* ****** ****** *) // // HX-2010-01-22: // it is just a pointer; it is not reference counted // absviewtype Display_ptr (l:addr) // Display* viewtypedef Display_ptr0 = [l:agez] Display_ptr l viewtypedef Display_ptr1 = [l:addr | l > null] Display_ptr l // // HX-2010-01-22: // it is just a pointer; it is not reference counted // absviewtype Screen_ptr (l:addr) // Screen* viewtypedef Screen_ptr0 = [l:agez] Screen_ptr l viewtypedef Screen_ptr1 = [l:addr | l > null] Screen_ptr l // // HX: it is just a pointer; it is not reference counted // absviewtype Visual_ptr (l:addr) // Visual* viewtypedef Visual_ptr0 = [l:agez] Visual_ptr l viewtypedef Visual_ptr1 = [l:addr | l > null] Visual_ptr l (* ****** ****** *) // // HX: it is just a pointer; it is not reference counted // absviewtype GCptr (l:addr) = ptr // $extype"GC" // *GC = _XGC viewtypedef GCptr0 = [l:agez] GCptr l viewtypedef GCptr1 = [l:addr | l > null] GCptr l abstype GCref = $extype"GC" // this one should never be freed! (* ****** ****** *) // // // Chapter 2: Display Functions // // (* ****** ****** *) // // 2.1: opening the display // (* ****** ****** *) fun XOpenDisplay (name: Stropt): Display_ptr0 = "mac#atsctrb_XOpenDisplay" fun Display_ptr_is_null {l:addr} (p_dpy: !Display_ptr l): bool (l == null) = "atspre_ptr_is_null" // defined in $ATSHOME/prelude/CATS/pointer.cats fun Display_ptr_isnot_null {l:addr} (p_dpy: !Display_ptr l): bool (l > null) = "atspre_ptr_isnot_null" // defined in $ATSHOME/prelude/CATS/pointer.cats (* ****** ****** *) // // 2.2: obtaining information about display, image formats or screens // (* ****** ****** *) // // 2.2.1: display macros // (* ****** ****** *) fun XAllPlanes (): ulint = "mac#atsctrb_XAllPlanes" fun XBlackPixel {l:agz} (dpy: !Display_ptr l, nscr: int):<> ulint = "mac#atsctrb_XBlackPixel" fun XWhitePixel {l:agz} (dpy: !Display_ptr l, nscr: int):<> ulint = "mac#atsctrb_XWhitePixel" fun XConnectionNumber {l:agz} (dpy: !Display_ptr l):<> int = "mac#atsctrb_XConnectionNumber" fun XDefaultColormap {l:agz} (dpy: !Display_ptr l, nscr: int):<> Colormap = "mac#atsctrb_XDefaultColormap" (* ****** ****** *) fun XDefaultDepth {l:agz} (dpy: !Display_ptr l, nscr: int):<> int = "mac#atsctrb_XDefaultDepth" fun XListDepths {l:agz} ( dpy: !Display_ptr l , nscr: int, cnt: &int? >> opt (int n, la > null) ) : #[n:nat;la:addr] XArray (int, n, la) = "mac#atsctrb_XListDepths" // end of [XListDepths] (* ****** ****** *) fun XDefaultGC {l:agz} ( dpy: !Display_ptr l, nscr: int ) : GCref = "mac#atsctrb_XDefaultGC" // end of [XDefaultGC] (* ****** ****** *) fun XDefaultRootWindow {l:agz} ( dpy: !Display_ptr l ) : Window = "mac#atsctrb_XDefaultRootWindow" // end of [XDefaultRootWindow] fun XDefaultScreenOfDisplay {l1:agz} ( dpy: !Display_ptr l1 ) : [l2:agz] ( minus (Display_ptr l1, Screen_ptr l2) | Screen_ptr l2 ) = "mac#atsctrb_XDefaultScreenOfDisplay" // end of [XDefaultScreenOfDisplay] fun XScreenOfDisplay {l1:agz} ( dpy: !Display_ptr l1, nsrc: int ) : [l2:agz] ( minus (Display_ptr l1, Screen_ptr l2) | Screen_ptr l2 ) = "mac#atsctrb_XDefaultScreenOfDisplay" // end of [XDefaultScreenOfDisplay] fun XDefaultScreen {l:agz} (dpy: !Display_ptr l): int(*nscr*) = "mac#atsctrb_XDefaultScreen" fun XDefaultVisual {l1:agz} ( dpy: !Display_ptr l1, nsrc: int ) : [l2:agz] ( minus (Display_ptr l1, Visual_ptr l2) | Visual_ptr l2 ) = "mac#atsctrb_XDefaultVisual" // end of [XDefaultVisual] // number of entries in the default colormap fun XDisplayCells {l:agz} (dpy: !Display_ptr l, nscr: int): int(*ncell*) = "mac#atsctrb_XDisplayCells" // the depth of the root window fun XDisplayPlanes {l:agz} (dpy: !Display_ptr l, nscr: int): int(*depth*) = "mac#atsctrb_XDisplayPlanes" // the name passed to XOpenDisplay fun XDisplayString {l:agz} (dpy: !Display_ptr l): string = "mac#atsctrb_XDisplayString" (* ****** ****** *) fun XMaxRequestSize {l:agz} (dpy: !Display_ptr l): lint // in 4-byte units = "mac#atsctrb_XMaxRequestSize" // the full serial number for the last processed request fun XLastKnownRequestProcessed {l:agz} (dpy: !Display_ptr l): ulint = "mac#atsctrb_XLastKnownRequestProcessed" // the full serial number to be used for the next request fun XNextRequest {l:agz} (dpy: !Display_ptr l): ulint = "mac#atsctrb_XNextRequest" (* ****** ****** *) fun XProtocolVersion {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XProtocolVersion" fun XProtocolRevision {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XProtocolRevision" (* ****** ****** *) // the length of the event queue for [dpy] fun XQLength {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XQLength" (* ****** ****** *) fun XRootWindow {l:agz} ( dpy: !Display_ptr l, nscr: int ) : Window = "mac#atsctrb_XRootWindow" // end of [fun] fun XScreenCount {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XScreenCount" fun XServerVendor {l:agz} (dpy: !Display_ptr l): string = "mac#atsctrb_XServerVendor" fun XVendorRelease {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XVendorRelease" (* ****** ****** *) // // 2.2.2: image format functions and macros // (* ****** ****** *) typedef XPixmapFormatValues = $extype_struct "XPixmapFormatValues" of { depth= int, bits_per_pixel= int, scanline_pad= int } // end of [XPixmapFormatValues] fun XListPixmapFormats {l:agz} ( dpy: !Display_ptr l, n: &int? >> opt (int n, la > null) ) : #[n:nat;la:addr] XArray (XPixmapFormatValues, n, la) = "mac#atsctrb_XListPixmapFormats" macdef LSBFirst = $extval (int, "LSBFirst") macdef MSBFirst = $extval (int, "MSBFirst") fun XImageByteOrder {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XImageByteOrder" fun XBitmapUnit {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XBitmapUnit" fun XBitmapOrder {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XBitmapOrder" fun XBitmapPad {l:agz} (dpy: !Display_ptr l): int = "mac#atsctrb_XBitmapPad" fun XDisplayHeight {l:agz} (dpy: !Display_ptr l, nscr: int): int = "mac#atsctrb_XDisplayHeight" fun XDisplayHeightMM {l:agz} (dpy: !Display_ptr l, nscr: int): int = "mac#atsctrb_XDisplayHeightMM" fun XDisplayWidth {l:agz} (dpy: !Display_ptr l, nscr: int): int = "mac#atsctrb_XDisplayWidth" fun XDisplayWidthMM {l:agz} (dpy: !Display_ptr l, nscr: int): int = "mac#atsctrb_XDisplayWidthMM" (* ****** ****** *) // // 2.2.3: screen information macros // (* ****** ****** *) fun XBlackPixelOfScreen {l:agz} (scr: !Screen_ptr l): ulint = "mac#atsctrb_XBlackPixelOfScreen" fun XWhitePixelOfScreen {l:agz} (scr: !Screen_ptr l): ulint = "mac#atsctrb_XWhitePixelOfScreen" fun XCellsOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XCellsOfScreen" fun XDefaultColormapOfScreen {l:agz} (scr: !Screen_ptr l): Colormap = "mac#atsctrb_XDefaultColormapOfScreen" fun XDefaultDepthOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XDefaultDepthOfScreen" fun XDefaultGCOfScreen {l:agz} (scr: !Screen_ptr l): GCref = "mac#atsctrb_XDefaultGCOfScreen" // // HX: the function returns WhenMapped, NotUseful or Always // fun XDoesBackingStore {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XDoesBackingStore" fun XDoesSaveUnders {l:agz} (scr: !Screen_ptr l): bool = "mac#atsctrb_XDoesSaveUnders" fun XScreenNumberOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XScreenNumberofScreen" fun XEventMaskOfScreen {l:agz} (scr: !Screen_ptr l): lint = "mac#atsctrb_XEventMaskOfScreen" fun XWidthOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XWidthOfScreen" fun XWidthMMOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XWidthMMOfScreen" fun XHeightOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XHeightOfScreen" fun XHeightMMOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XHeightMMOfScreen" fun XMaxCmapsOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XMaxCmapsOfScreen" fun XMinCmapsOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XMinCmapsOfScreen" fun XPlanesOfScreen {l:agz} (scr: !Screen_ptr l): int = "mac#atsctrb_XPlanesOfScreen" fun XRootWindowOfScreen {l:agz} (scr: !Screen_ptr l): Window = "mac#atsctrb_XRootWindowOfScreen" (* ****** ****** *) // // 2.3: generating a NoOperation protocol request // (* ****** ****** *) fun XNoOp {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XNoOp" (* ****** ****** *) // // 2.4: freeing client-created data // (* ****** ****** *) absview XFree_v (l:addr) fun XFree0 {l:addr} (pf: XFree_v l | p: ptr l): void = "mac#atsctrb_XFree" // end of [XFree0] symintr XFree overload XFree with XFree0 overload XFree with XPtrFree overload XFree with XArrayFree overload XFree with XStringFree (* ****** ****** *) // // 2.5: closing the display // (* ****** ****** *) fun XCloseDisplay (dpy: Display_ptr1): void = "mac#atsctrb_XCloseDisplay" abst@ype close_mode_t = int macdef DestroyAll = $extval (close_mode_t, "DestroyAll") macdef RetainPermanent = $extval (close_mode_t, "RetainPermanent") macdef RetainTemporary = $extval (close_mode_t, "RetainTemporary") // // [XSetCloseDownMode] may generate a BadValue error // fun XSetCloseDownMode {l:agz} (dpy: Display_ptr l, mode: close_mode_t): void // end of [XSetCloseDownMode] (* ****** ****** *) // // // Chapter 3: Window Functions // // (* ****** ****** *) // // 3.1: visual types // (* ****** ****** *) fun XVisualIDFromVisual {l:agz} (visual: !Visual_ptr l): VisualID = "mac#atsctrb_XVisualIDFromVisual" (* ****** ****** *) // // 3.2: window attributes // (* ****** ****** *) typedef XSetWindowAttributes = $extype_struct "XSetWindowAttributes" of { background_pixmap= Pixmap , background_pixel= ulint , border_pixmap= Pixmap , border_pixel= ulint , bit_gravity= int , win_gravity= int , backing_store= int , backing_planes= ulint , backing_pixel= ulint , save_under= bool , event_mask= lint , do_not_propagate_mask= lint , override_redirect= bool , colormap= Colormap , cursor= Cursor } // end of [XSetWindowAttributes] (* ****** ****** *) // // 3.3: creating windows // (* ****** ****** *) fun XCreateWindow {ld,lv:agz} ( dpy: !Display_ptr ld , parent: Window , x: int, y: int , width: uint, height: uint , border_width: uint , depth: uint // can [depth] be negative? , _class: uint , visual: !Visual_ptr lv , valuemask: ulint , attr: &XSetWindowAttributes ) : Window = "mac#atsctrb_XCreateWindow" // end of [XCreateWindow] fun XCreateSimpleWindow {ld:agz} ( dpy: !Display_ptr ld , parent: Window , x: int, y: int , width: uint, height: uint , border_width: uint // in pixels , border: ulint // border pixel value , background: ulint // background pixel value ) : Window = "mac#atsctrb_XCreateSimpleWindow" // end of [XCreateSimpleWindow] (* ****** ****** *) // // 3.4: destroying windows // (* ****** ****** *) fun XDestroyWindow {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XDestroyWindow" fun XDestroySubwindows {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XDestroyWindow" (* ****** ****** *) // // 3.5: mapping windows // (* ****** ****** *) fun XMapWindow {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XMapWindow" fun XMapRaised {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XMapRaised" fun XMapSubwindows {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XMapSubwindows" (* ****** ****** *) // // 3.6: unmapping windows // (* ****** ****** *) fun XUnmapWindow {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XUnmapWindow" fun XUnmapSubwindows {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XUnmapSubwindows" (* ****** ****** *) // // 3.7: configuring windows // (* ****** ****** *) typedef XWindowChanges = $extype_struct "XWindowChanges" of { x= int, y= int , width= int, height= int , border_width= int , sibling= Window , stack_mode= int } // end of [XWindowChanges] fun XConfigureWindow {l:agz} ( dpy: !Display_ptr l , win: Window , valmask: uint , values: &XWindowChanges ) : void = "mac#atsctrb_XConfigureWindow" fun XMoveWindow {l:agz} (dpy: !Display_ptr l, win: Window, x: int, y: int): void = "mac#atsctrb_XMoveWindow" fun XResizeWindow {l:agz} (dpy: !Display_ptr l, win: Window, width: uint, height: uint): void = "mac#atsctrb_XResizeWindow" fun XMoveResizeWindow {l:agz} ( dpy: !Display_ptr l, win: Window, x: int, y: int, width: uint, height: uint ) : void = "mac#atsctrb_XMoveResizeWindow" fun XSetWindowBorderWidth {l:agz} (dpy: !Display_ptr l, win: Window, border_width: uint): void = "mac#atsctrb_XSetWindowBorderWidth" (* ****** ****** *) // // 3.8: changing windows stacking order // (* ****** ****** *) fun XRaiseWindow {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XRaiseWindow" fun XLowerWindow {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XLowerWindow" fun XCirculateSubwindows {l:agz} (dpy: !Display_ptr l, win: Window, dir: int): void = "mac#atsctrb_XCirculateSubwindows" fun XCirculateSubwindowsUp {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XCirculateSubwindowsUp" fun XCirculateSubwindowsDown {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XCirculateSubwindowsDown" fun XRestackWindows {l:agz} {n:nat} (dpy: !Display_ptr l, wins: &(@[Window][n]), nwin: int n): void = "mac#atsctrb_XRestackWindows" (* ****** ****** *) // // 3.9: changing windows attributes // (* ****** ****** *) fun XChangeWindowAttributes {l:agz} ( dpy: !Display_ptr l , win: Window , valmask: ulint , attr: &XSetWindowAttributes ) : void = "mac#atsctrb_XChangeWindowAttributes" fun XSetWindowBackground {l:agz} (dpy: !Display_ptr l, win: Window, bg_pixel: ulint): void = "mac#atsctrb_XSetWindowBackground" fun XSetWindowBackgroundPixmap {l:agz} (dpy: !Display_ptr l, win: Window, bg_pixmap: Pixmap): void = "mac#atsctrb_XSetWindowBackgroundPixmap" fun XSetWindowBorder {l:agz} (dpy: !Display_ptr l, win: Window, bd_pixel: ulint): void = "mac#atsctrb_XSetWindowBorder" fun XSetWindowBorderPixmap {l:agz} (dpy: !Display_ptr l, win: Window, bd_pixmap: Pixmap): void = "mac#atsctrb_XSetWindowBorderPixmap" fun XSetWindowColormap {l:agz} (dpy: !Display_ptr l, win: Window, colormap: Colormap): void = "mac#atsctrb_XSetWindowColormap" fun XDefineCursor {l:agz} (dpy: !Display_ptr l, win: Window, cursor: Cursor): void = "mac#atsctrb_XDefineCursor" fun XUndefineCursor {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XUndefineCursor" (* ****** ****** *) // // // Chapter 4: Window Information Functions // // (* ****** ****** *) abst@ype Status (i:int) = $extype"Status" // = int typedef Status = [i:int] Status i castfn int_of_Status {i:int} (x: Status i):<> int i overload int_of with int_of_Status fun XQueryTree {l:agz} ( dpy: !Display_ptr l , win: Window , root: &Window? >> Window , parent: &Window? >> Window , children: &ptr? >> opt (XArray1 (Window, n), i <> 0) , nchilren: &int? >> opt (int n, i <> 0) ) : #[i:int;n:nat] Status i = "mac#atsctrb_XQueryTree" // end of [XQueryTree] typedef XWindowAttributes = $extype_struct "XWindowAttributes" of { x= int, y= int , width= uint, height= uint , border_width= uint , depth= int // , visual= Visual_ptr1 , root= Window , _class= int , bit_gravity= int , win_gravity= int , backing_store= int , backing_planes= ulint , backing_pixel= ulint , save_under= bool , colormap= Colormap , map_installed= bool , map_state= int , all_event_mask= lint , your_event_mask= lint , do_not_propagate_mask= lint , override_redirect= bool // , screen= Screen_ptr1 } // end of [XWindowAttributes] fun XGetWindowAttributes {l:agz} ( dpy: !Display_ptr l, win: Window , attr: &XWindowAttributes? >> opt (XWindowAttributes, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetWindowAttributes" fun XGetGeometry {l:agz} ( dpy: !Display_ptr l, drw: Drawable , root: &Window? >> Window , x: &int? >> int, y: &int? >> int , width: &uint? >> uint, height: &uint? >> uint , border_width: &uint? >> uint , depth: &uint? >> uint ) : Status // ... = "mac#atsctrb_XGetWindowAttributes" // end of [fun] (* ****** ****** *) // // 4.2: translating screen coordinates // (* ****** ****** *) fun XTranslateCoordinates {l:agz} ( dpy: !Display_ptr l , win_src: Window, win_dst: Window , x_src: int, y_src: int , x_dst: &int? >> int, y_dst: &int? >> int , child: &Window? >> Window ) : bool = "mac#atsctrb_XTranslateCoordinates" // end of [fun] fun XQueryPointer {l:agz} ( dpy: !Display_ptr l , win: Window , root: &Window? >> Window, child: &Window? >> Window , x_root: &int? >> int, y_root: &int? >> int , x_win: &int? >> int, y_win: &int? >> int , mask: &uint? >> uint ) : bool = "mac#atsctrb_XQueryPointer" // end of [fun] (* ****** ****** *) // // 4.3: properties and atoms // (* ****** ****** *) fun XInternAtom {l:agz} ( dpy: !Display_ptr l, atom_name: string, only_if_exists: bool ) : Atom = "mac#atsctrb_XInternAtom" // end of [XInternAtom] fun XGetAtomName {l:agz} ( dpy: !Display_ptr l, atom: Atom ) : XString0 = "mac#atsctrb_XGetAtomName" // end of [XGetAtomName] (* ****** ****** *) // // 4.4: obtaining and changing window properties // (* ****** ****** *) // // // Chapter 5: Pixmap and Cursor Functions // // (* ****** ****** *) // // 5.1: creating and freeing pixmaps // (* ****** ****** *) fun XCreatePixmap {l:agz} ( dpy: !Display_ptr l , drw: Drawable, width: uint, height: uint, depth: uint ) : Pixmap = "mac#atsctrb_XCreatePixmap" // end of [fun] fun XFreePixmap {l:agz} (dpy: !Display_ptr l, pixmap: Pixmap): void = "mac#atsctrb_XFreePixmap" // end of [XFreePixmap] (* ****** ****** *) // // // 5.2: creating, recoloring and freeing cursors // // (* ****** ****** *) fun XCreateFontCursor {l:agz} ( dpy: !Display_ptr l, shape: uint ) : Cursor = "mac#atsctrb_XCreateFontCursor" // end of [fun] fun XFreeCursor {l:agz} ( dpy: !Display_ptr l, cursor: Cursor ) : void = "mac#atsctrb_XFreeCursor" // end of [fun] (* ****** ****** *) // // // Chapter 6: Color Management Functions // // (* ****** ****** *) // // 6.1: color structures // (* ****** ****** *) typedef XColor = $extype_struct "XColor" of { pixel= ulint , red= usint, green= usint, blue= usint , flags= char, pad= char } // end of [XColor] (* ****** ****** *) // // 6.4: creating, copying and destroying // (* ****** ****** *) fun XCreateColormap {l1,l2:agz} ( dsp: !Display_ptr l1 , win: Window, visual: !Visual_ptr l2, alloc: int ) : Colormap = "mac#atsctrb_XCreateColormap" // end of [fun] fun XCopyColormapAndFree {l:agz} ( dpy: !Display_ptr l, colormap: Colormap ) : void = "mac#atsctrb_XCopyColormapAndFree" // end of [fun] fun XFreeColormap {l:agz} ( dpy: !Display_ptr l, colormap: Colormap ) : void = "mac#atsctrb_XFreeColormap" // end of [fun] (* ****** ****** *) // // 6.5: Mapping Color Names to Values // (* ****** ****** *) fun XLookupColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap, color_name: string , exact_def: &XColor? >> opt (XColor, i <> 0) , screen_def: &XColor? >> opt (XColor, i <> 0) ) : #[i:int] Status i // nonzero if the name is resolved = "mac#atsctrb_XLookupColor" // end of [XLookupColor] fun XParseColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap , spec: string , exact_def: &XColor? >> opt (XColor, i <> 0) ) : #[i:int] Status i // nonzero if the name is resolved = "mac#atsctrb_XParseColor" // end of [XParseColor] (* fun XcmsLookupColor (...) *) (* ****** ****** *) // // 6.6: Allocating and Freeing Color Cells // (* ****** ****** *) fun XAllocColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap, screen_in_out: &XColor >> opt (XColor, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XAllocColor" // end of [XAllocColor] (* fun XcmsAllocColor (...) *) fun XAllocNamedColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap , color_name: string , screen_def: &XColor? >> opt (XColor, i <> 0) , exact_def: &XColor? >> opt (XColor, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XAllocNamedColor" // end of [XAllocNamedColor] (* fun XcmsAllocNamedColor (...) *) (* fun XAllocColorCells (...) fun XAllocColorPlanes (...) *) (* fun XFreeColors (...) *) (* ****** ****** *) // // 6.7: Modifying and Querying Colormap Cells // (* ****** ****** *) fun XStoreColor {l:agz} ( dpy: !Display_ptr l, colormap: Colormap, color: &XColor ) : void = "mac#atsctrb_XStoreColor" // end of [XStoreColor] fun XStoreColors {l:agz} {n:nat} ( dpy: !Display_ptr l , colormap: Colormap, colors: &(@[XColor][n]), ncolor: int n ) : void = "mac#atsctrb_XStoreColors" // end of [XStoreColors] (* XcmsStoreColor (...) XcmsStoreColors (...) *) fun XStoreNamedColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap, color_name: string, pixel: ulint, flags: int ) : void = "mac#atsctrb_XStoreNamedColor" // end of [XStoreNamedColor] fun XQueryColor {l:agz} ( dpy: !Display_ptr l , colormap: Colormap, def_in_out: &XColor >> XColor ) : void = "mac#atsctrb_XQueryColor" // end of [XQueryColor] fun XQueryColors {l:agz} {n:nat} ( dpy: !Display_ptr l , colormap: Colormap, defs_in_out: &(@[XColor][n]), ncolor: int n ) : void = "mac#atsctrb_XQueryColors" // end of [XQueryColors] (* fun XcmsQueryColor (...) fun XcmsQueryColors (...) *) (* ****** ****** *) // // 6.8: Color Conversion Context Functions // (* ****** ****** *) // // 6.9: Converting Between Color Spaces // (* ****** ****** *) // // 6.10: Callback functions // (* ****** ****** *) // // 6.11: Gamut querying functions // (* ****** ****** *) // // 6.12: Color management extensions // (* ****** ****** *) // // // Chapter 7: Graphics Context Functions // // (* ****** ****** *) // // 7.1: Manipulating Graphics Context/State // (* ****** ****** *) macdef GCFunction = $extval (lint, "GCFunction") macdef GCPlaneMask = $extval (lint, "GCPlaneMask") macdef GCForeground = $extval (lint, "GCForeground") macdef GCBackground = $extval (lint, "GCBackground") macdef GCLineWidth = $extval (lint, "GCLineWidth") macdef GCLineStyle = $extval (lint, "GCLineStyle") macdef GCCapStyle = $extval (lint, "GCCapStyle") macdef GCJoinStyle = $extval (lint, "GCJoinStyle") macdef GCFillStyle = $extval (lint, "GCFillStyle") macdef GCFillRule = $extval (lint, "GCFillRule") macdef GCTile = $extval (lint, "GCTile") macdef GCStipple = $extval (lint, "GCStipple") macdef GCTileStipXOrigin = $extval (lint, "GCTileStipXOrigin") macdef GCTileStipYOrigin = $extval (lint, "GCTileStipYOrigin") macdef GCFont = $extval (lint, "GCFont") macdef GCSubWindowMode = $extval (lint, "GCSubWindowMode") macdef GCGraphicsExposures = $extval (lint, "GCGraphicsExposures") macdef GCClipXOrigin = $extval (lint, "GCClipXOrigin") macdef GCClipYOrigin = $extval (lint, "GCClipYOrigin") macdef GCClipMask = $extval (lint, "GCClipMask") macdef GCDashOffset = $extval (lint, "GCDashOffset") macdef GCDashList = $extval (lint, "GCDashList") macdef GCArcMode = $extval (lint, "GCArcMode") typedef XGCValues = $extype_struct "XGCValues" of { function= int , plane_mask= ulint , foreground= ulint , background= ulint , line_width= int , line_style= int , cap_style= int , join_style= int , fill_style= int , arc_mode= int , tile= Pixmap , stipple= Pixmap , ts_x_origin = int , ts_y_origin = int , font= Font , subwindow_mode= int , graphics_exposures= XBool , clip_x_origin= int , clip_y_origin= int , clip_mask= Pixmap , dash_offset= int , dashes= char } // end of [XGCValues] fun GCptr_is_null {l:addr} (p_dpy: !GCptr l): bool (l == null) = "atspre_ptr_is_null" // defined in $ATSHOME/prelude/CATS/pointer.cats fun GCptr_isnot_null {l:addr} (p_dpy: !GCptr l): bool (l > null) = "atspre_ptr_isnot_null" // defined in $ATSHOME/prelude/CATS/pointer.cats fun XCreateGC {l:agz} ( // [values] can be uninitialized ... dpy: !Display_ptr l, drw: Drawable, mask: ulint, values: &XGCValues? ) : GCptr1 // HX-2010-04-18: should it be GCptr0? = "mac#atsctrb_XCreateGC" // end of [XCreateGC] fun XCopyGC {l1,l2,l3:agz} (dpy: !Display_ptr l1, src: !GCptr l2, dst: !GCptr l3, mask: ulint): void = "mac#atsctrb_XCopyGC" // end of [XCopyGC] fun XChangeGC {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, mask: ulint, values: &XGCValues): void = "mac#atsctrb_XChangeGC" // end of [XChangeGC] fun XGetGCValues {l1,l2:agz} ( dpy: !Display_ptr l1, gc: !GCptr l2, mask: ulint, values: &XGCValues? >> XGCValues ) : void = "mac#atsctrb_XGetGCValues" // end of [XGetGCValues] fun XFreeGC {l1,l2:agz} (dpy: !Display_ptr l1, gc: GCptr l2): void = "mac#atsctrb_XFreeGC" // end of [XFreeGC] fun XFlushGC {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2): void = "mac#atsctrb_XFlushGC" // end of [XFlushGC] (* ****** ****** *) // // 7.2: Using GC convenience routines // (* ****** ****** *) fun XSetForeground {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, foreground: ulint): void = "mac#atsctrb_XSetForeground" // end of [XSetForeground] fun XSetBackground {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, background: ulint): void = "mac#atsctrb_XSetBackground" // end of [XSetBackground] fun XSetFunction {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, _function: int): void = "mac#atsctrb_XSetFunction" // end of [XSetFunction] fun XSetPlaneMask {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, plane_mask: ulint): void = "mac#atsctrb_XSetPlaneMask" // end of [XSetPlaneMask] fun XSetFont {l1,l2:agz} (dpy: !Display_ptr l1, gc: !GCptr l2, font: Font): void = "mac#atsctrb_XSetFont" // end of [XSetFont] fun XSetLineAttributes {l1,l2:agz} ( dpy: !Display_ptr l1, gc: !GCptr l2 , line_width: uint, line_style: int, cap_style: int, join_style: int ) : void = "mac#atsctrb_XSetLineAttributes" // end of [XSetLineAttributes] fun XSetDashes {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1, gc: !GCptr l2 , dash_offset: int, dash_list: &(@[char][n]), n: int n ) : void = "mac#atsctrb_XSetDashes" // end of [XSetDashes] (* ****** ****** *) // // // Chapter 8: Graphics Functions // // (* ****** ****** *) // // 8.1: Clearing Areas // (* ****** ****** *) fun XClearArea {l:agz} ( dsp: !Display_ptr l , win: Window , x: int, y: int , width: uint, height: uint , exposures: XBool ) : void = "mac#atsctrb_XClearArea" // end of [fun] fun XClearWindow {l:agz} (dsp: !Display_ptr l, win: Window) : void = "mac#atsctrb_XClearWindow" // end of [XClearWindow] (* ****** ****** *) // // 8.2: Copying Areas // (* ****** ****** *) fun XCopyArea {l1,l2:agz} ( dpy: !Display_ptr l1 , src: Drawable, dst: Drawable , gc: !GCptr l2 , x_src: int, y_src: int , width: uint, height: uint , x_dst: int, y_dst: int ) : void = "mac#atsctrb_XCopyArea" // end of [fun] fun XCopyPlane {l1,l2:agz} ( dpy: !Display_ptr l1 , src: Drawable, dst: Drawable , gc: !GCptr l2 , x_src: int, y_src: int , width: uint, height: uint , x_dst: int, y_dst: int , plane: ulint // set exactly one-bit to 1 ) : void = "mac#atsctrb_XCopyPlane" // end of [fun] (* ****** ****** *) // // 8.3: Drawing Points, Lines, Rectangles and Arcs // (* ****** ****** *) typedef XSegment = $extype_struct "XSegment" of { x1= sint, y1= sint, x2= sint, y2= sint } // end of [XSegment] typedef XPoint = $extype_struct "XPoint" of { x= sint, y= sint } // end of [XPoint] typedef XRectangle = $extype_struct "XRectangle" of { x= sint, y= sint, width= usint, height= usint } // end of [XRectangle] typedef XArc = $extype_struct "XArc" of { x= sint, y= sint , width= usint, height= usint , angle1= sint, angle2= sint // uint: 1/64 degree } // end of [XArc] (* ****** ****** *) // // 8.3.1: Drawing Single and Multiple Points // (* ****** ****** *) fun XDrawPoint {l1,l2:agz} ( dpy: !Display_ptr l1, drw: Drawable, gc: !GCptr l2, x: int, y: int ) : void = "mac#atsctrb_XDrawPoint" // end of [XDrawPoint] fun XDrawPoints {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, points: &(@[XPoint][n]), n: int n, mode: int ) : void = "mac#atsctrb_XDrawPoints" // end of [XDrawPoints] (* ****** ****** *) // // 8.3.2: Drawing Single and Multiple Lines // (* ****** ****** *) fun XDrawLine {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, x1: int, y1: int, x2: int, y2: int ) : void = "mac#atsctrb_XDrawLine" // end of [XDrawLine] fun XDrawLines {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, points: &(@[XPoint][n]), n: int n, mode: int ) : void = "mac#atsctrb_XDrawLines" // end of [XDrawLines] fun XDrawSegments {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, segments: &(@[XSegment][n]), n: int n ) : void = "mac#atsctrb_XDrawSegments" // end of [XDrawSegments] (* ****** ****** *) // // 8.3.3: Drawing Single and Multiple Rectangles // (* ****** ****** *) fun XDrawRectangle {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, x: int, y: int, width: uint, height: uint ) : void = "mac#atsctrb_XDrawRectangle" // end of [XDrawRectangle] fun XDrawRectangles {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, rectangles: &(@[XRectangle][n]), n: int n ) : void = "mac#atsctrb_XDrawRectangles" // end of [XDrawRectangles] (* ****** ****** *) // // 8.3.4: Drawing Single and Multiple Arcs // (* ****** ****** *) fun XDrawArc {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2 , x: int, y: int, width: uint, height: uint, angle1: int, angle2: int ) : void = "mac#atsctrb_XDrawArc" // end of [XDrawArc] fun XDrawArcs {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, arcs: &(@[XArc][n]), n: int n ) : void = "mac#atsctrb_XDrawArcs" // end of [XDrawArcs] (* ****** ****** *) // // 8.4: Filling Areas // (* ****** ****** *) // // 8.4.1: Filling Single and Multiple Rectangles // (* ****** ****** *) fun XFillRectangle {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, x: int, y: int, width: uint, height: uint ) : void = "mac#atsctrb_XFillRectangle" // end of [XFillRectangle] fun XFillRectangles {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, rectangles: &(@[XRectangle][n]), n: int n ) : void = "mac#atsctrb_XFillRectangles" // end of [XFillRectangles] (* ****** ****** *) // // 8.4.2: Filling a Single Polygon // (* ****** ****** *) fun XFillPolygon {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, points: &(@[XPoint][n]), n: int n , shape: int, mode: int ) : void = "mac#atsctrb_XFillPolygon" // end of [XFillPolygon] (* ****** ****** *) // // 8.4.3: Filling Single and Multiple Arcs // (* ****** ****** *) fun XFillArc {l1,l2:agz} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2 , x: int, y: int, width: uint, height: uint, angle1: int, angle2: int ) : void = "mac#atsctrb_XFillArc" // end of [XFillArc] fun XFillArcs {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable, gc: !GCptr l2, arcs: &(@[XArc][n]), n: int n ) : void = "mac#atsctrb_XFillArcs" // end of [XFillArcs] (* ****** ****** *) // // 8.5: Font Metrics // (* ****** ****** *) typedef XCharStruct = $extype_struct "XCharStruct" of { lbearing= sint, rbearing= sint , width= sint, ascent= sint, descent= sint , attributes= usint } // end of [XCharStruct] typedef XFontProp = $extype_struct "XFontProp" of { name= Atom, card32= ulint } // end of [XFontProp] typedef XChar2b = $extype_struct "XChar2b" of { byte1= uchar, byte2= uchar } // end of [XChar2b] typedef XFontStruct = $extype_struct "XFontStruct" of { XExtData= ptr , fid= Font , direction= uint , min_char_or_byte2= uint , max_char_or_byte2= uint , min_byte1= uint , max_byte1= uint , all_chars_exist= XBool , default_char= uint // , n_properties= int n // , properties= ptr l_properties // @[XFontProp][n] @ l_properties , min_bounds= XCharStruct , max_bounds= XCharStruct // , per_char= ptr // XCharStruct* , ascent= int , descent= int } // end of [XFontStruct] (* ****** ****** *) // // 8.5.1: Loading and Freeing Fonts // (* ****** ****** *) absview XFreeFont_v (l:addr) prfun XFreeFont_v_unnull (pf: XFreeFont_v null): void fun XLoadFont {l:agz} (dpy: !Display_ptr l, name: string): Font = "mac#atsctrb_XLoadFont" // end of [XLoadFont] fun XQueryFont {l:agz} (dpy: !Display_ptr l, font_id: XID) : [l:agez] ( XFreeFont_v l, optvar_v (XFontStruct, l) | ptr l ) = "mac#atsctrb_XQueryFont" // end of [XQueryFont] fun XLoadQueryFont {l:agz} (dpy: !Display_ptr l, name: string) : [l:agez] ( XFreeFont_v l, optvar_v (XFontStruct, l) | ptr l ) = "mac#atsctrb_XLoadQueryFont" // end of [XLoadQueryFont] fun XFreeFont {l1,l2:addr} ( pf1: XFreeFont_v l2, pf2: XFontStruct @ l2 | dpy: !Display_ptr l1, p_font_struct: ptr l2 ) : void = "mac#atsctrb_XFreeFont" // end of [XFreeFont] (* ****** ****** *) // // 8.5.3: Computing Character String Sizes // (* ****** ****** *) fun XTextWidth {n:nat} (ftinfo: &XFontStruct, str: string n, nstr: int n): int = "mac#atsctrb_XTextWidth" // end of [XTextWidth] fun XTextWidth16 {n:nat} (ftinfo: &XFontStruct, str: array (XChar2b, n), nstr: int n): int = "mac#atsctrb_XTextWidth16" // end of [XTextWidth] (* ****** ****** *) // // 8.6: Drawing Text // (* ****** ****** *) // // 8.6.2: Drawing Text Characters // (* ****** ****** *) fun XDrawString {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable , gc: !GCptr l2 , x: int, y: int , str: string n , len: int n ) : void = "mac#atsctrb_XDrawString" // end of [XDrawString] fun XDrawString16 {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable , gc: !GCptr l2 , x: int, y: int , str: array (XChar2b, n) , len: int n ) : void = "mac#atsctrb_XDrawString16" // end of [XDrawString16] (* ****** ****** *) // // 8.6.3: Drawing Image Characters // (* ****** ****** *) fun XDrawImageString {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable , gc: !GCptr l2 , x: int, y: int , str: string n , len: int n ) : void = "mac#atsctrb_XDrawImageString" // end of [XDrawImageString] fun XDrawImageString16 {l1,l2:agz} {n:nat} ( dpy: !Display_ptr l1 , drw: Drawable , gc: !GCptr l2 , x: int, y: int , str: array (XChar2b, n) , len: int n ) : void = "mac#atsctrb_XDrawImageString16" // end of [XDrawImageString16] (* ****** ****** *) // // // Chapter 9: Window and Session Manager Functions // // (* ****** ****** *) // // 9.1: Changing the parent of a window // (* ****** ****** *) fun XReparentWindow {l:agz} ( dpy: !Display_ptr l , win: Window , parent: Window , x: int , y: int ) : void = "mac#atsctrb_XReparentWindow" // end of [XReparentWindow] (* ****** ****** *) // // 9.2: Controlling the Lifetime of a Window // (* ****** ****** *) fun XChangeSaveSet {l:agz} (dpy: !Display_ptr l, win: Window, mode: int): void = "mac#atsctrb_XChangeSaveSet" // end of [atsctrb_XChangeSaveSet] fun XAddSaveSet {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XAddSaveSet" // end of [XAddSaveSet] fun XRemoveFromSaveSet {l:agz} (dpy: !Display_ptr l, win: Window): void = "mac#atsctrb_XRemoveFromSaveSet" // end of [XRemoveFromSaveSet] (* ****** ****** *) // // 9.3: Managing installed colormaps // (* ****** ****** *) fun XInstallColormap {l:agz} (dpy: !Display_ptr l, colormap: Colormap): void = "mac#atsctrb_XInstallColormap" // end of [XInstallColormap] fun XUninstallColormap {l:agz} (dpy: !Display_ptr l, colormap: Colormap): void = "mac#atsctrb_XUninstallColormap" // end of [XUninstallColormap] fun XListInstalledColormaps {l:agz} ( dpy: !Display_ptr l, win: Window, nmap: &int? >> opt (int n, la > null) ) : #[n:nat;la:addr] XArray (Colormap, n, la) = "mac#atsctrb_XListInstalledColormaps" // end of [XListInstalledColormaps] (* ****** ****** *) // // 9.4: Setting and Retrieving the Fond Search Path // (* ****** ****** *) // // 9.5: Server Grabbing // (* ****** ****** *) fun XGrabServer {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XGrabServer" // end of [XGrabServer] fun XUngrabServer {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XUngrabServer" // end of [XUngrabServer] (* ****** ****** *) // // 9.6: Killing Clients // (* ****** ****** *) fun XKillClient {l:agz} (dpy: !Display_ptr l, resource: XID): void = "mac#atsctrb_XKillClient" // end of [XKillClient] (* ****** ****** *) // // 9.7: Screen Saver Control // (* ****** ****** *) fun XSetScreenSaver {l:agz} ( dpy: !Display_ptr l , timeout: int, interval: int, prefer_blanking: int, allow_exposures: int ) : void = "mac#atsctrb_XSetScreenSaver" // end of [XSetScreenSaver] fun XForceScreenSaver {l:agz} ( dpy: !Display_ptr l, mode: int ) : void = "mac#atsctrb_XForceScreenSaver" // end of [XForceScreenSaver] fun XActivateScreenSaver {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XActivateScreenSaver" // end of [XActivateScreenSaver] fun XResetScreenSaver {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XResetScreenSaver" // end of [XResetScreenSaver] fun XGetScreenSaver {l:agz} ( dpy: !Display_ptr l , timeout: &int? >> int , interval: &int? >> int , prefer_blanking: &int? >> int , allow_exposures: &int? >> int ) : void = "mac#atsctrb_XGetScreenSaver" // end of [XGetScreenSaver] (* ****** ****** *) // // 9.8: Controlling Host Access // (* ****** ****** *) // // 9.8.1: Adding, Getting or Removing Hosts // (* ****** ****** *) typedef XHostAddress = $extype_struct "XHostAddress" of { family= int , length= int , address= string } // end of [XHostAddress] fun XAddHost {l:agz} (dpy: !Display_ptr l, host: &XHostAddress): void = "mac#atsctrb_XAddHost" // end of [XAddHost] fun XAddHosts {l:agz} {n:nat} ( dpy: !Display_ptr l, hosts: &(@[XHostAddress][n]), n: int n ) : void = "mac#atsctrb_XAddHosts" // end of [XAddHosts] fun XListHosts {l:agz} ( dpy: !Display_ptr l , nhost: &int? >> opt (int n, la > null) , state: &XBool? >> opt (XBool, la > null) ) : #[n:nat;la:addr] XArray (XHostAddress, n, la) = "mac#atsctrb_XListHosts" // end of [XListHosts] fun XRemoveHost {l:agz} (dpy: !Display_ptr l, host: &XHostAddress): void = "mac#atsctrb_XRemoveHost" // end of [XRemoveHost] fun XRemoveHosts {l:agz} {n:nat} (dpy: !Display_ptr l, hosts: &(@[XHostAddress][n]), n: int n): void = "mac#atsctrb_XRemoveHosts" // end of [XRemoveHosts] (* ****** ****** *) // // 9.8.2: Changing, Enabling or Disabling Access Control // (* ****** ****** *) fun XSetAccessControl {l:agz} (dpy: !Display_ptr l, mode: int): void = "mac#atsctrb_XSetAccessControl" // end of [XSetAccessControl] fun XEnableAccessControl {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XEnableAccessControl" // end of [XEnableAccessControl] fun XDisableAccessControl {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XDisableAccessControl" // end of [XDisableAccessControl] (* ****** ****** *) // // // Chapter 10: Events // // (* ****** ****** *) typedef XEvent = $extype_struct "XEvent" of { type= EventType_t // the type of the event , _rest= undefined_t // this abstract field cannot be accessed } // end of [XEvent] propdef XEvent_castdn_t (a:t@ype) = {l:addr} (XEvent @ l) - (a @ l, a @ l - XEvent @ l) // end of [XEvent_castdn_t] (* ****** ****** *) // // 10.2: Event Structures // (* ****** ****** *) typedef XAnyEvent = $extype_struct "XAnyEvent" of { type= EventType_t , serial = ulint // # of last request processed by server , send_event= XBool // true if this comes from a SendEvent request /* , display= Display_ptr0 // Display the event was read freom */ , window= Window , _rest= undefined_t } // end of [XAnyEvent] praxi XEvent_xany_castdn : XEvent_castdn_t (XAnyEvent) (* ****** ****** *) // // 10.5: Keyboard and Pointer Events // (* ****** ****** *) typedef XKeyEvent = $extype_struct "XKeyEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // display from which the event was read */ , window= Window // individual section , root= Window , subwindow= Window /* , time= Time */ , x= int, y= int , x_root= int, y_root= int , state= uint , keycode= uint , same_screen= XBool , _rest= undefined_t } // end of [XKeyEvent] praxi XEvent_xkey_castdn : XEvent_castdn_t (XKeyEvent) // typedef XKeyPressedEvent = XKeyEvent typedef XKeyReleasedEvent = XKeyEvent // typedef XButtonEvent = $extype_struct "XButtonEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ , window= Window // individual section , root= Window , subwindow= Window /* , time= Time */ , x= int, y= int , x_root= int, y_root= int , state= uint , button= uint , same_screen= XBool , _rest= undefined_t } // end of [XButtonEvent] praxi XEvent_xbutton_castdn : XEvent_castdn_t (XButtonEvent) // typedef XMotionEvent = $extype_struct "XMotionEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ , window= Window // individual section , root= Window , subwindow= Window /* , time= Time */ , x= int, y= int , x_root= int, y_root= int , state= uint , in_hint= char , same_screen= XBool , _rest= undefined_t } // end of [XMotionEvent] praxi XEvent_xmotion_castdn : XEvent_castdn_t (XMotionEvent) (* ****** ****** *) // // 10.6: Window Entry/Exit Events // (* ****** ****** *) // // 10.7: Input Focus Events // (* ****** ****** *) // // 10.8: Key Map State Notification Events // (* ****** ****** *) // // 10.9: Exposure Events // (* ****** ****** *) typedef XExposeEvent = $extype_struct "XExposeEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ , window= Window // individual section , x= int, y= int , width= int, height= int , count= int } // end of [XExposeEvent] praxi XEvent_xexpose_castdn : XEvent_castdn_t (XExposeEvent) (* ****** ****** *) // // 10.10: Window State Change Events // (* ****** ****** *) // // 10.10.1: CirculateNotify Events // (* ****** ****** *) typedef XCirculateEvent = $extype_struct "XCirculateEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ // individual section , event= Window , window= Window , place= int , _rest= undefined_t } // end of [XCirculateEvent] praxi XEvent_xcirculate_castdn : XEvent_castdn_t (XCirculateEvent) (* ****** ****** *) // // 10.10.2: ConfigureNotify Events // (* ****** ****** *) typedef XConfigureEvent = $extype_struct "XConfigureEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ // individual section , event= Window , window= Window , x= int, y= int , width= int, height= int , border_width= int , above= Window , override_redirect= XBool , _rest= undefined_t } // end of [XConfigureEvent] praxi XEvent_xconfigure_castdn : XEvent_castdn_t (XConfigureEvent) (* ****** ****** *) // // 10.10.2: CreateNotify Events // (* ****** ****** *) typedef XCreateWindowEvent = $extype_struct "XCreateWindowEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ // individual section , parent= Window , window= Window , x= int, y= int , width= int, height= int , border_width= int , override_redirect= XBool , _rest= undefined_t } // end of [XCreateWindowEvent] praxi XEvent_xcreatewindow_castdn : XEvent_castdn_t (XCreateWindowEvent) (* ****** ****** *) // // 10.10.2: DestroyNotify Events // (* ****** ****** *) typedef XDestroyWindowEvent = $extype_struct "XDestroyWindowEvent" of { type= EventType_t , serial= ulint , send_event= XBool /* , display= Display_ptr0 // Display the event was read freom */ // individual section , event= Window , window= Window , x= int, y= int , _rest= undefined_t } // end of [XDestroyWindowEvent] praxi XEvent_xdestroywindow_castdn : XEvent_castdn_t (XDestroyWindowEvent) (* ****** ****** *) // // // Chapter 11: Event Handling Functions // // (* ****** ****** *) // // 11.1: selecting events // (* ****** ****** *) fun XSelectInput {l:agz} (dpy: !Display_ptr l, win: Window, eventmask: InputEventMask_t): void = "mac#atsctrb_XSelectInput" // end of [XSelectInput] (* ****** ****** *) // // 11.2: handling the output buffer // (* ****** ****** *) fun XFlush {l:agz} (dpy: !Display_ptr l): void = "mac#atsctrb_XFlush" // end of [XFlush] fun XSync {l:agz} (dpy: !Display_ptr l, discard: bool): void = "mac#atsctrb_XSync" // end of [XSync] (* ****** ****** *) // // 11.3: Event Queue Management // macdef QueuedAlready = $extval (int, "QueuedAlready") macdef QueuedAfterReading = $extval (int, "QueuedAfterReading") macdef QueuedAfterFlush = $extval (int, "QueuedAfterFlush") fun XEventsQueued {l:agz} (dpy: Display_ptr l, mode: int): int = "mac#atsctrb_XEventsQueued" // end of [XEventsQueued] // this one is equivalent to XEventsQueued (QueuedAfterFlush) fun XPending {l:agz} (dpy: Display_ptr l): int = "mac#atsctrb_XPending" (* ****** ****** *) // // 11.4: manipulating the event queue // (* ****** ****** *) // // 11.4.1: returning the next event // (* ****** ****** *) fun XNextEvent {l:agz} (dpy: !Display_ptr l, event: &XEvent? >> XEvent): void = "mac#atsctrb_XNextEvent" // end of [XNextEvent] fun XPeekEvent {l:agz} (dpy: !Display_ptr l, event: &XEvent? >> XEvent): void = "mac#atsctrb_XPeekEvent" // end of [XPeekEvent] (* ****** ****** *) // // // Chapter 14: Inter-client communication functions // // source: "X11/Xutil.h" // (* ****** ****** *) // // 14.1: Client to Window Manage Communication // (* ****** ****** *) typedef XTextProperty (l:addr) = $extype_struct "XTextProperty" of { value= ptr l // property data , encoding= Atom // type of property , format= int // 8, 16, or 32 , nitems= ulint // number of items in value } // end of [XTextProperty] typedef XTextProperty = [l:addr] XTextProperty l (* ****** ****** *) // // HX: this is an enum type // abst@ype XICCEncodingStyle = $extype"XICCEncodingStyle" macdef XStringStyle = $extval (XICCEncodingStyle, "XStringStyle") macdef XCompoundTextStyle = $extval (XICCEncodingStyle, "XCompoundTextStyle") macdef XTextStyle = $extval (XICCEncodingStyle, "XTextStyle") macdef XStdICCTextStyle = $extval (XICCEncodingStyle, "XStdICCTextStyle") (* ****** ****** *) // // 14.1.1: Manipulating Top-Level Windows // (* ****** ****** *) fun XIconifyWindow {l:agz} ( dpy: !Display_ptr l, win: Window, nscr: int ) : Status = "mac#atsctrb_XIconifyWindow" // end of [XIconifyWindow] fun XWithdrawWindow {l:agz} ( dpy: !Display_ptr l, win: Window, nscr: int ) : Status = "mac#atsctrb_XWithdrawWindow" // end of [XWithdrawWindow] fun XReconfigureWMWindow {l:agz} ( dpy: !Display_ptr l , win: Window, nscr: int, mask: uint, values: &XWindowChanges? ) : Status = "mac#atsctrb_XReconfigureWMWindow" // end of [XReconfigureWMWindow] (* ****** ****** *) // // 14.1.2: Converting String Lists // (* ****** ****** *) fun XDefaultString (): string = "mac#atsctrb_XDefaultString" // fun XStringToTextProperty ( str: string , text: &XTextProperty? >> opt (XTextProperty l, i <> 0) ) : #[i:int;l:addr] (XFree_v l | Status i) = "atsctrb_XStringToTextProperty" // end of [XStringToTextProperty] fun XStringListToTextProperty {n:nat} ( list: &(@[string][n]), n: int n , text: &XTextProperty? >> opt (XTextProperty l, i <> 0) ) : #[i:int;l:addr] (XFree_v l | Status i) = "mac#atsctrb_XStringListToTextProperty" // end of [XStringListToTextProperty] // fun XTextPropertyToStringList {l:addr} ( text: &XTextProperty l , list: &XStrarr? >> opt (XStrarr1 n, i <> 0) , n: &int? >> opt (int n, i <> 0) ) : #[i:int;n:nat] Status i = "mac#atsctrb_XTextPropertyToStringList" // end of [XTextPropertyToStringList] fun XFreeStringList {n:nat} {l:addr} (list: XStrarr (n, l)): void = "mac#atsctrb_XFreeStringList" // end of [XFreeStringList] (* ****** ****** *) // // 14.1.3: Setting and Reading Text Properties // (* ****** ****** *) fun XSetTextProperty {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty , property: Atom ) : void = "mac#atsctrb_XSetTextProperty" // end of [XSetTextProperty] fun XGetTextProperty {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty? >> opt (XTextProperty, i <> 0) , property: Atom ) : #[i:int] Status i = "mac#atsctrb_XGetTextProperty" // end of [XGetTextProperty] (* ****** ****** *) // // 14.1.4: Setting and Reading the WM_NAME Property // (* ****** ****** *) fun XSetWMName {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty ) : void = "mac#atsctrb_XSetWMName" // end of [XSetWMName] fun XGetWMName {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty >> opt (XTextProperty, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetWMName" // end of [XGetWMName] fun XStoreName {l:agz} ( dpy: !Display_ptr l , win: Window , window_name: string // the name is copied into ... ) : void = "mac#atsctrb_XStoreName" // end of [XStoreName] absviewtype XString fun XFetchName {l:agz} ( dpy: !Display_ptr l , win: Window , window_name: &XString? >> opt (XString0, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XFetchName" // end of [XFetchName] (* ****** ****** *) // // 14.1.5: Setting and Reading the WM_ICON_NAME Property // (* ****** ****** *) fun XSetWMIconName {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty ) : void = "mac#atsctrb_XSetWMIconName" // end of [XSetWMIconName] fun XGetWMIconName {l:agz} ( dpy: !Display_ptr l , win: Window , text: &XTextProperty >> opt (XTextProperty, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetWMIconName" // end of [XGetWMIconName] fun XSetIconName {l:agz} ( dpy: !Display_ptr l , win: Window , icon_name: string // copied into ... ) : void = "mac#atsctrb_XSetIconName" // end of [XSetIconName] fun XGetIconName {l:agz} ( dpy: !Display_ptr l , win: Window , icon_name: &XString? >> opt (XString0, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetIconName" // end of [XGetIconName] (* ****** ****** *) // // 14.1.6: Setting and Reading the WM_HINTS Property // macdef InputHint = $extval (lint, "InputHint") macdef StateHint = $extval (lint, "StateHint") macdef IconPixmapHint = $extval (lint, "IconPixmapHint") macdef IconWindowHint = $extval (lint, "IconWindowHint") macdef IconPositionHint = $extval (lint, "IconPositionHint") macdef IconMaskHint = $extval (lint, "IconMaskHint") macdef WindowGroupHint = $extval (lint, "WindowGroupHint") macdef AllHints = $extval (lint, "AllHints") macdef XUrgencyHint = $extval (lint, "XUrgencyHint") // macdef WithdrawnState = $extval (int, "WithdrawnState") macdef NormalState = $extval (int, "NormalState") macdef IconicState = $extval (int, "IconicState") // typedef XWMHints = $extype_struct "XWMHints" of { flags= lint // marks which fields in this structure are defined , input= XBool // does this application rely on the window manager to get keyword input? , initial_state= int // see below , icon_pixmap= Pixmap // pixmap to be used as icon , icon_window= Window // window to be used as icon , icon_x= int, icon_y= int // initial position of icon , icon_mask= Pixmap // pixmap to be used as mask for icon_pixmap , window_group= XID // id of related window group // may be extended in the future } // end of [XWMHints] fun XAllocWMHints (): XPtr0 (XWMHints) = "mac#atsctrb_XAllocWMHints" // end of [XAllocWMHints] fun XSetWNHints {l:agz} (dpy: !Display_ptr l, win: Window, wmhints: &XWMHints): void = "mac#atsctrb_XSetWNHints" // end of [XSetWNHints] fun XGetWNHints {l:agz} (dpy: !Display_ptr l, win: Window): XPtr0 (XWMHints) = "mac#atsctrb_XGetWNHints" // end of [XGetWNHints] (* ****** ****** *) // // 14.1.7: Setting and Reading the WM_NORMAL Property // (* ****** ****** *) typedef XSizeHints_aspect = $extype_struct "XSizeHints_aspect" of { x= int, y= int } // end of [XSizeHints_aspect] macdef USPosition = $extval (lint, "USPosition") macdef USSize = $extval (lint, "USSize") macdef PPosition = $extval (lint, "PPosition") macdef PSize = $extval (lint, "PSize") macdef PMinSize = $extval (lint, "PMinSize") macdef PMaxSize = $extval (lint, "PMaxSize") macdef PResizeInc = $extval (lint, "PResizeInc") macdef PAspect = $extval (lint, "PAspect") macdef PBaseSize = $extval (lint, "PBaseSize") macdef PWinGravity = $extval (lint, "PWinGravity") typedef XSizeHints = $extype_struct "XSizeHints" of { flags= lint , x= int, y= int , width= int, height= int , min_width= int, min_height= int , max_width= int, max_height= int , width_inc= int, height_inc= int , min_aspect= XSizeHints_aspect, max_aspect= XSizeHints_aspect , base_width= int, base_height= int , win_gravity= int } // end of [XSizeHints] fun XAllocSizeHints () : XPtr0 (XSizeHints) = "mac#atsctrb_XAllocSizeHints" // end of [XAllocSizeHints] // fun XSetWMNormalHints {l:agz} (dpy: !Display_ptr l, win: Window, hints: &XSizeHints): void = "mac#atsctrb_XSetWMNormalHints" // end of [XSetWMNormalHints] fun XGetWMNormalHints {l:agz} ( dpy: !Display_ptr l, win: Window , hints: &XSizeHints? >> opt (XSizeHints, i <> 0) , supplied: &lint? >> lint ) : #[i:int] Status i = "mac#atsctrb_XGetWMNormalHints" // end of [XGetWMNormalHints] // fun XSetWMSizeHints {l:agz} ( dpy: !Display_ptr l , win: Window , hints: &XSizeHints , property: Atom ) : void = "mac#atsctrb_XSetWMSizeHints" // end of [XSetWMSizeHints] fun XGetWMSizeHints {l:agz} ( dpy: !Display_ptr l, win: Window , hints: &XSizeHints? >> opt (XSizeHints, i <> 0) , supplied: &lint? >> lint, property: Atom ) : #[i:int] Status i = "mac#atsctrb_XGetWMSizeHints" // end of [XGetWMSizeHints] (* ****** ****** *) // // 14.1.8: Setting and Reading the WM_CLASS Property // (* ****** ****** *) typedef XClassHint = $extype_struct "XClassHint" of { res_name= string , res_class= string } // end of [XClassHint] fun XAllocClassHint () : XPtr0 (XClassHint) = "mac#atsctrb_XAllocClassHint" // end of [XAllocClassHint] fun XSetClassHint {l:agz} (dpy: !Display_ptr l, win: Window, class_hint: XClassHint): void = "mac#atsctrb_XSetClassHint" fun XGetClassHint {l:agz} ( dpy: !Display_ptr l , win: Window , class_hint: &XClassHint? >> opt (XClassHint, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetClassHint" (* ****** ****** *) // // 14.1.9: Setting and Reading the WM_TRANSIENT_FOR Property // (* ****** ****** *) fun XSetTransientForHint {l:agz} ( dpy: !Display_ptr l, win: Window, prop_window: Window ) : void = "mac#atsctrb_XSetTransientForHint" // end of [XSetTransientForHint] fun XGetTransientForHint {l:agz} ( dpy: !Display_ptr l , win: Window, prop_window: &Window? >> opt (Window, i <> 0) ) : #[i:int] Status i = "mac#atsctrb_XGetTransientForHint" // end of [XGetTransientForHint] (* ****** ****** *) // // 14.1.13: Using Window Manager Convenience Functions // (* ****** ****** *) fun XSetWMProperties {l:agz} {l1,l2:addr} {n:nat} ( dpy: !Display_ptr l , win: Window , win_name: &XTextProperty l1, icon_name: &XTextProperty l2 , argv: &(@[string][n]) , argc: int n , normal_hints: &XSizeHints // partially init , wm_hints: &XWMHints // partially init , class_hint: &XClassHint // partially init ) : void = "mac#atsctrb_XSetWMProperties" // end of [XSetWMProperties] (* ****** ****** *) // // // Chapter 16: Application Unitility Functions // // (* ****** ****** *) // // 16.9: Manipulating Bitmaps // (* ****** ****** *) fun XCreatePixmapFromBitmapData {l:agz} ( dpy: !Display_ptr l , drw: Drawable, data: ptr(*chars*) , width: uint, height: uint, fg: ulint, bg: ulint, depth: uint ) : Pixmap = "mac#atsctrb_XCreatePixmapFromBitmapData" // end of [XCreatePixmapFromBitmapData] fun XCreateBitmapFromData {l:agz} ( dpy: !Display_ptr l , drw: Drawable, data: ptr(*chars*), width: uint, height: uint ) : Pixmap = "mac#atsctrb_XCreateBitmapFromData" // end of [XCreateBitmapFromData] (* ****** ****** *) // // 16.10: Using the Context Manager // (* ****** ****** *) (* end of [Xlib.sats] *) ats-lang-anairiats-0.2.11/contrib/X11/SATS/X.sats0000664000175000017500000002616012223166165017673 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) %{# #include "contrib/X11/CATS/X.cats" %} // end of [{%#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // HX-2010-02-17: This is ugly: // Flags in X should have been declared of the type ulint! // fun lor_lint_lint (x: lint, y: lint):<> lint = "mac#atspre_lor_ulint_ulint" // end of [lor_lint_lint] overload lor with lor_lint_lint (* ****** ****** *) // Bool is already used in ATS typedef XBool = bool // unindexed // abst@ype Atom = $extype"Atom" // unsigned long int abst@ype Mask = $extype"Mask" // unsigned long int abst@ype VisualID = $extype"VisualID" // unsigned long int abst@ype Time = $extype"Time" // unsigned long int (* ****** ****** *) // [XID] is unsigned long int abst@ype XID = $extype"XID" abst@ype Window = $extype"Window" // = XID abst@ype Font = $extype"Font" // = XID abst@ype Pixmap = $extype"Pixmap" // = XID abst@ype Cursor = $extype"Cursor" // = XID abst@ype Colormap = $extype"Colormap" // = XID abst@ype GContext = $extype"GContext" // = XID abst@ype KeySym = $extype"KeySym" // = XID // abst@ype Drawable = $extype"Drawable" // = XID symintr Drawable castfn Drawable_of_Window (x: Window): Drawable overload Drawable with Drawable_of_Window castfn Drawable_of_Pixmap (x: Pixmap): Drawable overload Drawable with Drawable_of_Pixmap (* ****** ****** *) // EVENT DEFINITIONS (* ** Input Event Masks. ** Used as event-mask window attribute and as arguments to Grab requests. *) abst@ype InputEventMask_t = lint fun lor_InputEventMask_InputEventMask (x: InputEventMask_t, y: InputEventMask_t): InputEventMask_t = "atsctrb_lor_InputEventMask_InputEventMask" // end of [lor_InputEventMask_InputEventMask] overload lor with lor_InputEventMask_InputEventMask macdef NoEventMask = $extval (InputEventMask_t, "NoEventMask") macdef KeyPressMask = $extval (InputEventMask_t, "KeyPressMask") macdef KeyReleaseMask = $extval (InputEventMask_t, "KeyReleaseMask") macdef ButtonPressMask = $extval (InputEventMask_t, "ButtonPressMask") macdef ButtonReleaseMask = $extval (InputEventMask_t, "ButtonReleaseMask") macdef EnterWindowMask = $extval (InputEventMask_t, "EnterWindowMask") macdef LeaveWindowMask = $extval (InputEventMask_t, "LeaveWindowMask") macdef PointerMotionMask = $extval (InputEventMask_t, "PointerMotionMask") macdef PointerMotionHintMask = $extval (InputEventMask_t, "PointerMotionHintMask") macdef Button1MotionMask = $extval (InputEventMask_t, "Button1MotionMask") macdef Button2MotionMask = $extval (InputEventMask_t, "Button2MotionMask") macdef Button3MotionMask = $extval (InputEventMask_t, "Button3MotionMask") macdef Button4MotionMask = $extval (InputEventMask_t, "Button4MotionMask") macdef Button5MotionMask = $extval (InputEventMask_t, "Button5MotionMask") macdef ButtonMotionMask = $extval (InputEventMask_t, "ButtonMotionMask") macdef KeymapStateMask = $extval (InputEventMask_t, "KeymapStateMask") macdef ExposureMask = $extval (InputEventMask_t, "ExposureMask") macdef VisibilityChangeMask = $extval (InputEventMask_t, "VisibilityChangeMask") macdef StructureNotifyMask = $extval (InputEventMask_t, "StructureNotifyMask") macdef ResizeRedirectMask = $extval (InputEventMask_t, "ResizeRedirectMask") macdef SubstructureNotifyMask = $extval (InputEventMask_t, "SubstructureNotifyMask") macdef SubstructureRedirectMask = $extval (InputEventMask_t, "SubstructureRedirectMask") macdef FocusChangeMask = $extval (InputEventMask_t, "FocusChangeMask") macdef PropertyChangeMask = $extval (InputEventMask_t, "PropertyChangeMask") macdef ColormapChangeMask = $extval (InputEventMask_t, "ColormapChangeMask") macdef OwnerGrabButtonMask = $extval (InputEventMask_t, "OwnerGrabButtonMask") (* ****** ****** *) (* ** Event names. ** Used in "type" field in XEvent structures *) abst@ype EventType_t = int fun eq_EventType_EventType (x: EventType_t, y: EventType_t): bool = "atsctrb_eq_EventType_EventType" overload = with eq_EventType_EventType macdef KeyPress = $extval (EventType_t, "KeyPress") macdef KeyRelease = $extval (EventType_t, "KeyRelease") macdef ButtonPress = $extval (EventType_t, "ButtonPress") macdef ButtonRelease = $extval (EventType_t, "ButtonRelease") macdef MotionNotify = $extval (EventType_t, "MotionNotify") macdef EnterNotify = $extval (EventType_t, "EnterNotify") macdef LeaveNotify = $extval (EventType_t, "LeaveNotify") macdef FocusIn = $extval (EventType_t, "FocusIn") macdef FocusOut = $extval (EventType_t, "FocusOut") macdef KeymapNotify = $extval (EventType_t, "KeymapNotify") macdef Expose = $extval (EventType_t, "Expose") macdef GraphicsExpose = $extval (EventType_t, "GraphicsExpose") macdef NoExpose = $extval (EventType_t, "NoExpose") macdef VisibilityNotify = $extval (EventType_t, "VisibilityNotify") macdef CreateNotify = $extval (EventType_t, "CreateNotify") macdef DestroyNotify = $extval (EventType_t, "DestroyNotify") macdef UnmapNotify = $extval (EventType_t, "UnmapNotify") macdef MapNotify = $extval (EventType_t, "MapNotify") macdef MapRequest = $extval (EventType_t, "MapRequest") macdef ReparentNotify = $extval (EventType_t, "ReparentNotify") macdef ConfigureNotify = $extval (EventType_t, "ConfigureNotify") macdef ConfigureRequest = $extval (EventType_t, "ConfigureRequest") macdef GravityNotify = $extval (EventType_t, "GravityNotify") macdef ResizeRequest = $extval (EventType_t, "ResizeRequest") macdef CirculateNotify = $extval (EventType_t, "CirculateNotify") macdef CirculateRequest = $extval (EventType_t, "CirculateRequest") macdef PropertyNotify = $extval (EventType_t, "PropertyNotify") macdef SelectionClear = $extval (EventType_t, "SelectionClear") macdef SelectionRequest = $extval (EventType_t, "SelectionRequest") macdef SelectionNotify = $extval (EventType_t, "SelectionNotify") macdef ColormapNotify = $extval (EventType_t, "ColormapNotify") macdef ClientMessage = $extval (EventType_t, "ClientMessage") macdef MappingNotify = $extval (EventType_t, "MappingNotify") macdef LASTEvent = $extval (EventType_t, "LASTEvent") (* ****** ****** *) (* ** GRAPHICS DEFINITIONS *) (* graphics functions, as in GC.alu *) macdef GXclear = $extval (int, "GXclear") macdef GXand = $extval (int, "GXand") macdef GXandReverse = $extval (int, "GXandReverse") macdef GXcopy = $extval (int, "GXcopy") macdef GXandInverted = $extval (int, "GXandInverted") macdef GXnoop = $extval (int, "GXnoop") macdef GXxor = $extval (int, "GXxor") macdef GXor = $extval (int, "GXor") macdef GXnor = $extval (int, "GXnor") macdef GXequiv = $extval (int, "GXequiv") macdef GXinvert = $extval (int, "GXinvert") macdef GXorReverse = $extval (int, "GXorReverse") macdef GXcopyInverted = $extval (int, "GXcopyInverted") macdef GXorInverted = $extval (int, "GXorInverted") macdef GXnand = $extval (int, "GXnand") macdef GXset = $extval (int, "GXset") (* LineStyle *) macdef LineSolid = $extval (int, "LineSolid") macdef LineOnOffDash = $extval (int, "LineOnOffDash") macdef LineDoubleDash = $extval (int, "LineDoubleDash") (* capStyle *) macdef CapNotLast = $extval (int, "CapNotLast") macdef CapButt = $extval (int, "CapButt") macdef CapRound = $extval (int, "CapRound") macdef CapProjecting = $extval (int, "CapProjecting") (* joinStyle *) macdef JoinMiter = $extval (int, "JoinMiter") macdef JoinRound = $extval (int, "JoinRound") macdef JoinBevel = $extval (int, "JoinBevel") (* fillStyle *) macdef FillSolid = $extval (int, "FillSolid") macdef FillTiled = $extval (int, "FillTiled") macdef FillStippled = $extval (int, "FillStippled") macdef FillOpaqueStippled = $extval (int, "FillOpaqueStippled") (* fillRule *) macdef EvenOddRule = $extval (int, "EvenOddRule") macdef WindingRule = $extval (int, "WindingRule") (* subwindow mode *) macdef ClipByChildren = $extval (int, "ClipByChildren") macdef IncludeInferiors = $extval (int, "IncludeInferiors") (** SetClipRectangles ordering *) macdef Unsorted = $extval (int, "Unsorted") macdef YSorted = $extval (int, "YSorted") macdef YXSorted = $extval (int, "YXSorted") macdef YXBanded = $extval (int, "YXBanded") (* CoordinateMode for drawing routines *) macdef CoordModeOrigin = $extval (int, "CoordModeOrigin") macdef CoordModePrevious = $extval (int, "CoordModePrevious") (* Polygon shapes *) macdef Complex = $extval (int, "Complex") macdef Nonconvex = $extval (int, "Nonconvex") macdef Convex = $extval (int, "Convex") (* Arc modes for PolyFillArc *) macdef ArcChord = $extval (int, "ArcChord") macdef ArcPieSlice = $extval (int, "ArcPieSlice") (* ** ** GC components: ** masks used in CreateGC, CopyGC, ChangeGC, OR'ed into GC.stateChanges ** *) macdef GCFunction = $extval (int, "GCFunction") macdef GCPlaneMask = $extval (int, "GCPlaneMask") macdef GCForeground = $extval (int, "GCForeground") macdef GCBackground = $extval (int, "GCBackground") macdef GCLineWidth = $extval (int, "GCLineWidth") macdef GCLineStyle = $extval (int, "GCLineStyle") macdef GCCapStyle = $extval (int, "GCCapStyle") macdef GCJoinStyle = $extval (int, "GCJoinStyle") macdef GCFillStyle = $extval (int, "GCFillStyle") macdef GCFillRule = $extval (int, "GCFillRule") macdef GCTile = $extval (int, "GCTile") macdef GCStipple = $extval (int, "GCStipple") macdef GCTileStipXOrigin = $extval (int, "GCTileStipXOrigin") macdef GCTileStipYOrigin = $extval (int, "GCTileStipYOrigin") macdef GCFont = $extval (int, "GCFont") macdef GCSubwindowMode = $extval (int, "GCSubwindowMode") macdef GCGraphicsExposures = $extval (int, "GCGraphicsExposures") macdef GCClipXOrigin = $extval (int, "GCClipXOrigin") macdef GCClipYOrigin = $extval (int, "GCClipYOrigin") macdef GCClipMask = $extval (int, "GCClipMask") macdef GCDashOffset = $extval (int, "GCDashOffset") macdef GCDashList = $extval (int, "GCDashList") macdef GCArcMode = $extval (int, "GCArcMode") macdef GCLastBit = $extval (int, "GCLastBit") (* ****** ****** *) (* end of [X.sats] *) ats-lang-anairiats-0.2.11/contrib/X11/Makefile0000664000175000017500000000136412223166165017455 0ustar hwxihwxi# # API for Xlib in ATS # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: January, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSHOME),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc -Wall ###### all: atsctrb_X11.o clean ###### atsctrb_X11.o: \ X_sats.o \ Xlib_sats.o Xlib_dats.o ld -r -o $@ \ X_sats.o \ Xlib_sats.o Xlib_dats.o ###### X_sats.o: SATS/X.sats $(ATSCC) -IX11 -o $@ -c SATS/X.sats ###### Xlib_sats.o: SATS/Xlib.sats $(ATSCC) -IX11 -o $@ -c SATS/Xlib.sats Xlib_dats.o: DATS/Xlib.dats $(ATSCC) -IX11 -o $@ -c DATS/Xlib.dats ###### clean:: rm -f X_sats.c X_sats.o rm -f Xlib_sats.c Xlib_sats.o rm -f Xlib_dats.c Xlib_dats.o cleanall: clean rm -f atsctrb_Xlib.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/X11/DATS/0000700000175000017500000000000012223166165016530 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/X11/DATS/Xlib.dats0000664000175000017500000000334712223166165020326 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "contrib/X11/SATS/X.sats" staload "contrib/X11/SATS/Xlib.sats" (* ****** ****** *) // it is yet empty (* ****** ****** *) (* end of [Xlib.dats] *) ats-lang-anairiats-0.2.11/contrib/testing/0000700000175000017500000000000012223166165017101 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/testing/SATS/0000700000175000017500000000000012223166165017653 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/testing/SATS/fprint.sats0000664000175000017500000001135712223166165022074 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no staloading at run-time (* ****** ****** *) fun{a:t@ype} fprint_elt (out: FILEref, x: a): void // HX: cannot implemented generically (* ****** ****** *) fun{a:t@ype} array0_fprint_elt ( out: FILEref, A: array0 a, sep: string ) : void // end of [array0_fprint_elt] fun{a:t@ype} array0_fprint_fun ( out: FILEref, A: array0 a, sep: string , pr: (FILEref, a) -> void ) : void // end of [array0_fprint_fun] (* ****** ****** *) fun{a:t@ype} array_fprint_elt {n:nat} ( out: FILEref , A: array (a, n), n: size_t n, sep: string ) : void // end of [array_fprint_elt] fun{a:t@ype} array_fprint_fun {n:nat} ( out: FILEref , A: array (a, n), n: size_t n, sep: string , pr: (FILEref, a) -> void ) : void // end of [array_fprint_fun] (* ****** ****** *) fun{a:t@ype} array_ptr_fprint_elt {n:nat} ( out: FILEref , A: &(@[a][n]), n: size_t n, sep: string ) : void // end of [array_ptr_fprint_elt] fun{a:t@ype} array_ptr_fprint_fun {n:nat} ( out: FILEref , A: &(@[a][n]), n: size_t n, sep: string , pr: (FILEref, a) -> void ) : void // end of [array_ptr_fprint_fun] (* ****** ****** *) fun{a:t@ype} list0_fprint_elt ( out: FILEref, xs: list0 (a), sep: string ) : void // end of [list0_fprint_elt] fun{a:t@ype} list0_fprint_fun ( out: FILEref, xs: list0 (a), sep: string , pr: (FILEref, a) -> void ) : void // end of [list0_fprint_fun] (* ****** ****** *) fun{a:t@ype} list_fprint_elt ( out: FILEref, xs: List (a), sep: string ) : void // end of [list_fprint_elt] fun{a:t@ype} list_fprint_fun ( out: FILEref, xs: List (a), sep: string , pr: (FILEref, a) -> void ) : void // end of [list_fprint_fun] (* ****** ****** *) fun{a:t@ype} list_vt_fprint_elt {n:nat} ( out: FILEref, xs: !list_vt (a, n), sep: string ) : void // end of [list_vt_fprint_elt] fun{a:t@ype} list_vt_fprint_fun {n:nat} ( out: FILEref, xs: !list_vt (a, n), sep: string , pr: (FILEref, a) -> void ) : void // end of [list_vt_fprint] (* ****** ****** *) fun{a:t@ype} matrix0_fprint_elt ( out: FILEref , M: matrix0 (a) , sep1: string, sep2: string ) : void // end of [matrix0_fprint_elt] fun{a:t@ype} matrix0_fprint_fun ( out: FILEref , M: matrix0 (a) , sep1: string, sep2: string , pr: (FILEref, a) -> void ) : void // end of [matrix0_fprint_fun] (* ****** ****** *) fun{a:t@ype} matrix_fprint_elt {m,n:nat} {l:addr} ( out: FILEref , M: matrix (a, m, n), m: size_t m, n: size_t n , sep1: string, sep2: string ) : void // end of [matrix_fprint_elt] fun{a:t@ype} matrix_fprint_fun {m,n:nat} {l:addr} ( out: FILEref , M: matrix (a, m, n), m: size_t m, n: size_t n , sep1: string, sep2: string , pr: (FILEref, a) -> void ) : void // end of [matrix_fprint_fun] (* ****** ****** *) fun{a:t@ype} matrix_ptr_fprint_elt {m,n:nat} {l:addr} ( pf: !matrix_v (a, m, n, l) | out: FILEref , p: ptr l, m: size_t m, n: size_t n , sep1: string, sep2: string ) : void // end of [matrix_ptr_fprint_elt] fun{a:t@ype} matrix_ptr_fprint_fun {m,n:nat} {l:addr} ( pf: !matrix_v (a, m, n, l) | out: FILEref , p: ptr l, m: size_t m, n: size_t n , sep1: string, sep2: string , pr: (FILEref, a) -> void ) : void // end of [matrix_ptr_fprint_fun] (* ****** ****** *) (* end of [fprint.sats] *) ats-lang-anairiats-0.2.11/contrib/testing/SATS/randgen.sats0000664000175000017500000000560112223166165022203 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no staloading at run-time (* ****** ****** *) fun{a:t@ype} randgen (): a // HX: cannot implemented generically (* ****** ****** *) fun{a:t@ype} array0_randgen {n:nat} (n: size_t n): array0 (a) fun{a:t@ype} array_randgen {n:nat} (n: size_t n): array (a, n) (* ****** ****** *) fun{a:t@ype} array_ptr_randgen {n:nat} (n: size_t n) : [l:agz] (free_gc_v (a?, n, l), array_v (a, n, l) | ptr l) // end of [array_ptr_randgen] fun{a:t@ype} array_ptr_randinit {n:nat} {l:addr} ( pf: !array_v (a?, n, l) >> array_v (a, n, l) | p: ptr l, n: size_t n ) : void // end of [array_ptr_randinit] (* ****** ****** *) fun{a:t@ype} list0_randgen {n:nat} (n: int n): list0 (a) fun{a:t@ype} list_randgen {n:nat} (n: int n): list (a, n) fun{a:t@ype} list_vt_randgen {n:nat} (n: int n): list_vt (a, n) (* ****** ****** *) fun{a:t@ype} matrix0_randgen {m,n:nat} (m: size_t m, n: size_t n): matrix0 (a) // end of [matrix0_randgen] fun{a:t@ype} matrix_randgen {m,n:nat} (m: size_t m, n: size_t n): matrix (a, m, n) // end of [matrix_randgen] (* ****** ****** *) fun{a:t@ype} matrix_ptr_randinit {m,n:nat} {l:addr} ( pf: !matrix_v (a?, m, n, l) >> matrix_v (a, m, n, l) | p: ptr l, m: size_t m, n: size_t n ) : void // end of [matrix_ptr_randinit] (* ****** ****** *) (* end of [randgen.sats] *) ats-lang-anairiats-0.2.11/contrib/testing/DATS/0000700000175000017500000000000012223166165017634 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/testing/DATS/randgen.dats0000664000175000017500000001130312223166165022141 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no staloading at run-time #define ATS_DYNLOADFLAG 0 // no dynloading at run-time (* ****** ****** *) staload "contrib/testing/SATS/randgen.sats" (* ****** ****** *) implement{a} array0_randgen (n) = let val (pfgc, pfarr | p) = array_ptr_randgen (n) in array0_make_arrpsz {a} @(pfgc, pfarr | p, n) // HX: a unary fun end // end of [array0_randgen] (* ****** ****** *) implement{a} array_randgen (n) = let val (pfgc, pfarr | p) = array_ptr_randgen (n) prval () = free_gc_elim {a?} (pfgc) // HX: return the certificate in array_make_view_ptr (pfarr | p) end // end of [array_randgen] (* ****** ****** *) implement{a} array_ptr_randgen (n) = (pfgc, pfarr | p) where { val (pfgc, pfarr | p) = array_ptr_alloc_tsz {a} (n, sizeof) val () = array_ptr_randinit (pfarr | p, n) } // end of [array_ptr_randgen] (* ****** ****** *) implement{a} array_ptr_randinit (pf | p, n) = let fun loop {n:nat} {l:addr} .. ( pf: !array_v (a?, n, l) >> array_v (a, n, l) | p: ptr l, n: size_t n ) : void = if n > 0 then let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := randgen () val () = loop (pf2 | p+sizeof, n-1) in pf := array_v_cons {a} (pf1, pf2) end else let prval () = array_v_unnil (pf) prval () = pf := array_v_nil () in // nothing end // end of [if] in loop (pf | p, n) end // end of [array_ptr_randinit] (* ****** ****** *) implement{a} list0_randgen (n) = let val xs = list_randgen (n) in list0_of_list (xs) end // end of [list0_randgen] (* ****** ****** *) implement{a} list_randgen (n) = let val xs = list_vt_randgen (n) in list_of_list_vt (xs) end // end of [list_randgen] (* ****** ****** *) implement{a} list_vt_randgen (n) = let fun loop {i,j:nat} ( i: int i, xs: list_vt (a, j) ) : list_vt (a, i+j) = if i > 0 then let val x = randgen () in loop (i-1, list_vt_cons (x, xs)) end else xs // end of [if] // end of [loop] in loop (n, list_vt_nil ()) end // end of [list_vt_randgen] (* ****** ****** *) implement{a} matrix0_randgen (m, n) = let val (pfmul | mn) = mul2_size1_size1 (m, n) val (pfgc, pfarr | p) = array_ptr_randgen (mn) in matrix0_make_arrpsz__main {a} (pfmul | m, n, (pfgc, pfarr | p, mn)) end // end of [matrix0_randgen] (* ****** ****** *) implement{a} matrix_randgen (m, n) = let val (pfmul | mn) = mul2_size1_size1 (m, n) val (pfgc, pfarr | p) = array_ptr_randgen (mn) in matrix_make_arrpsz__main {a} (pfmul | m, n, (pfgc, pfarr | p, mn)) end // end of [matrix_randgen] (* ****** ****** *) (* prfun array_v_of_matrix_v {a:viewt@ype} {m,n:int} {l:addr} (pf_mat: matrix_v (a, m, n, l)):<> [mn:nat] (MUL (m, n, mn), array_v (a, mn, l)) *) implement{a} matrix_ptr_randinit (pfmat | p, m, n) = let prval (pfmul, pfarr) = array_v_of_matrix_v {a?} (pfmat) val (pfmul_alt | mn) = mul2_size1_size1 (m, n) prval () = mul_isfun (pfmul, pfmul_alt) // HX: there is only one [mn] val () = array_ptr_randinit (pfarr | p, mn) prval () = pfmat := matrix_v_of_array_v {a} (pfmul, pfarr) in // nothing end // end of [matrix_ptr_randinit] (* ****** ****** *) (* end of [randgen.dats] *) ats-lang-anairiats-0.2.11/contrib/testing/DATS/fprint.dats0000664000175000017500000001417212223166165022034 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no staloading at run-time #define ATS_DYNLOADFLAG 0 // no dynloading at run-time (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "contrib/testing/SATS/fprint.sats" (* ****** ****** *) implement{a} array0_fprint_elt (out, A, sep) = array0_fprint_fun (out, A, sep, fprint_elt) // end of [array0_fprint_elt] implement{a} array0_fprint_fun (out, A, sep, pr) = () where { val r = array0_get_arrszref {a} (A) (* castfn ref_get_view_ptr {a:viewt@ype} (r: ref a):<> [l:addr] (vbox (a @ l) | ptr l) *) val (vbox pf | p) = ref_get_view_ptr (r) prval pfarr = p->1; val parr = p->2; val n = p->3 val () = $effmask_ref (array_ptr_fprint_fun (out, !parr, n, sep, pr)) prval () = p->1 := pfarr } // end of [array0_fprint_fun] (* ****** ****** *) implement{a} array_fprint_elt (out, A, n, sep) = array_fprint_fun (out, A, n, sep, fprint_elt) // end of [array_fprint_elt] implement{a} array_fprint_fun (out, A, n, sep, pr) = let (* castfn array_get_view_ptr {a:viewt@ype} {n:nat} (A: array (a, n)):<> [l:addr] (vbox (array_v (a, n, l)) | ptr l) *) val (vbox pf | p) = array_get_view_ptr (A) in $effmask_ref (array_ptr_fprint_fun (out, !p, n, sep, pr)) end // end of [array_fprint_fun] (* ****** ****** *) implement{a} array_ptr_fprint_elt (out, A, n, sep) = array_ptr_fprint_fun (out, A, n, sep, fprint_elt) // end of [array_ptr_fprint_elt] implement{a} array_ptr_fprint_fun {n} (out, A, n, sep, pr) = let var i: sizeLte (n); val _0 = size1_of_int1 (0) in for (i := _0; i < n; i := i+1) ( if i > 0 then fprint_string (out, sep); pr (out, A.[i]) ) // end of [for] end // end of [array_ptr_fprint_fun] (* ****** ****** *) implement{a} list0_fprint_elt (out, xs, sep) = list_fprint_elt (out, list_of_list0 (xs), sep) // end of [list0_fprint_elt] implement{a} list0_fprint_fun (out, xs, sep, pr) = list_fprint_fun (out, list_of_list0 (xs), sep, pr) // end of [list0_fprint_fun] (* ****** ****** *) implement{a} list_fprint_elt (out, xs, sep) = list_fprint_fun (out, xs, sep, fprint_elt) // end of [list_fprint_elt] implement{a} list_fprint_fun (out, xs, sep, pr) = let fun loop ( xs: List a, i: int ) : void = case+ xs of | list_cons (x, xs) => let val () = if i > 0 then fprint_string (out, sep) // end of [val] val () = pr (out, x) in loop (xs, i+1) end // end of [list_cons] | list_nil () => () // end of [loop] in loop (xs, 0) end // end of [list_fprint_fun] (* ****** ****** *) implement{a} list_vt_fprint_elt (out, xs, sep) = ( list_fprint_elt (out, $UN.castvwtp1 {List a} (xs), sep) ) // end of [list_vt_fprint_elt] implement{a} list_vt_fprint_fun (out, xs, sep, pr) = ( list_fprint_fun (out, $UN.castvwtp1 {List a} (xs), sep, pr) ) // end of [list_vt_fprint_fun] (* ****** ****** *) implement{a} matrix0_fprint_elt (out, M, sep1, sep2) = ( matrix0_fprint_fun (out, M, sep1, sep2, fprint_elt) ) // end of [matrix0_fprint_elt] implement{a} matrix0_fprint_fun (out, M, sep1, sep2, pr) = let val m = matrix0_row (M) and n = matrix0_col (M) var !p_clo = @lam ( i: size_t, j: size_t, x: &a ) : void = $effmask_all { val () = if j > 0 then fprint_string (out, sep1) val () = pr (out, x) val () = if j = n-1 then fprint_string (out, sep2) } // end of [var] val () = matrix0_iforeach (M, $UN.cast (p_clo)) in // nothing end // end of [matrix0_fprint_fun] (* ****** ****** *) implement{a} matrix_fprint_elt {m,n} (out, M, m, n, sep1, sep2) = ( matrix_fprint_fun (out, M, m, n, sep1, sep2, fprint_elt) ) // end of [matrix_fprint_elt] implement{a} matrix_fprint_fun {m,n} (out, M, m, n, sep1, sep2, pr) = let var !p_clo = @lam ( pf: !unit_v | i: sizeLt m, j: sizeLt n, x: &a ) : void = $effmask_all { val () = if j > 0 then fprint_string (out, sep1) val () = pr (out, x) val () = if j = n-1 then fprint_string (out, sep2) } // end of [var] prval pfu = unit_v () val () = matrix_iforeach_vclo (pfu | M, !p_clo, m, n) prval unit_v () = pfu in // nothing end // end of [matrix_ptr_fprint_fun] (* ****** ****** *) implement{a} matrix_ptr_fprint_elt {m,n} (pf | out, p, m, n, sep1, sep2) = matrix_fprint_elt (out, $UN.cast (p), m, n, sep1, sep2) // end of [matrix_ptr_fprint_elt] implement{a} matrix_ptr_fprint_fun {m,n} (pf | out, p, m, n, sep1, sep2, pr) = matrix_fprint_fun (out, $UN.cast (p), m, n, sep1, sep2, pr) // end of [matrix_ptr_fprint_fun] (* ****** ****** *) (* end of [fprint.dats] *) ats-lang-anairiats-0.2.11/contrib/GL/0000700000175000017500000000000012223166165015726 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GL/CATS/0000700000175000017500000000000012223166165016460 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GL/CATS/glut.cats0000664000175000017500000001303012223166165020320 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 /* ****** ****** */ #ifndef ATSTRIB_GL_GLUT_CATS #define ATSTRIB_GL_GLUT_CATS /* ****** ****** */ #include /* ****** ****** */ /* ** Initialization functions, see fglut_init.c */ #define atsctrb_glutInit glutInit #define atsctrb_glutInitWindowPosition glutInitWindowPosition #define atsctrb_glutInitWindowSize glutInitWindowSize #define atsctrb_glutInitDisplayMode glutInitDisplayMode #define atsctrb_glutInitDisplayString glutInitDisplayString /* ****** ****** */ /* ** Process loop function, see freeglut_main.c */ #define atsctrb_glutMainLoop glutMainLoop /* ****** ****** */ /* ** Window management functions, see freeglut_window.c */ #define atsctrb_glutCreateWindow glutCreateWindow #define atsctrb_glutCreateSubWindow glutCreateSubWindow #define atsctrb_glutDestroyWindow atsctrb_glutDestroyWindow #define atsctrb_glutGetWindow glutGetWindow #define atsctrb_glutSetWindow glutSetWindow #define atsctrb_glutSetWindowTitle glutSetWindowTitle #define atsctrb_glutSetIconTitle glutSetIconTitle #define atsctrb_glutReshapeWindow glutReshapeWindow #define atsctrb_glutPositionWindow glutPositionWindow #define atsctrb_glutShowWindow glutShowWindow #define atsctrb_glutHideWindow glutHideWindow #define atsctrb_glutIconifyWindow glutIconifyWindow #define atsctrb_glutPushWindow glutPushWindow #define atsctrb_glutPopWindow glutPopWindow #define atsctrb_glutFullScreen glutFullScreen /* ****** ****** */ /* ** Display-connected functions, see freeglut_display.c */ #define atsctrb_glutPostWindowRedisplay glutPostWindowRedisplay #define atsctrb_glutPostRedisplay glutPostRedisplay #define atsctrb_glutSwapBuffers glutSwapBuffers /* ****** ****** */ // Global callback functions, see freeglut_callbacks.c #define atsctrb_glutTimerFunc glutTimerFunc /* ****** ****** */ #define atsctrb_glutIdleFunc glutIdleFunc static inline ats_void_type atsctrb_glutIdleFunc_null () { glutIdleFunc ((void (*)(void))0) ; return ; } // end of [atsctrb_glutIdleFunc_null] /* ****** ****** */ /* ** Window-specific callback functions, see freeglut_callbacks.c */ #define atsctrb_glutKeyboardFunc glutKeyboardFunc #define atsctrb_glutMouseFunc glutMouseFunc #define atsctrb_glutSpecialFunc glutSpecialFunc #define atsctrb_glutReshapeFunc glutReshapeFunc #define atsctrb_glutVisibilityFunc glutVisibilityFunc #define atsctrb_glutDisplayFunc glutDisplayFunc #define atsctrb_glutMotionFunc glutMotionFunc #define atsctrb_glutPassiveMotionFunc glutPassiveMotionFunc #define atsctrb_glutEntryFunc glutEntryFunc /* ****** ****** */ #define atsctrb_glutGet glutGet #define atsctrb_glutDeviceGet glutDeviceGet #define atsctrb_glutGetModifiers glutGetModifiers #define atsctrb_glutLayerGet glutLayerGet /* ****** ****** */ #define atsctrb_glutBitmapCharacter glutBitmapCharacter #define atsctrb_glutBitmapWidth glutBitmapWidth #define atsctrb_glutBitmapLength glutBitmapLength #define atsctrb_glutStrokeCharacter glutStrokeCharacter #define atsctrb_glutStrokeWidth glutStrokeWidth #define atsctrb_glutStrokeLength glutStrokeLength /* ****** ****** */ #define atsctrb_glutWireCube glutWireCube #define atsctrb_glutSolidCube glutSolidCube #define atsctrb_glutWireSphere glutWireSphere #define atsctrb_glutSolidSphere glutSolidSphere /* ****** ****** */ #define atsctrb_glutWireCone glutWireCone #define atsctrb_glutSolidCone glutSolidCone /* ****** ****** */ #define atsctrb_glutWireTorus glutWireTorus #define atsctrb_glutSolidTorus glutSolidTorus /* ****** ****** */ #define atsctrb_glutWireTeapot glutWireTeapot #define atsctrb_glutSolidTeapot glutSolidTeapot /* ****** ****** */ #define atsctrb_glutWireDodecahedron glutWireDodecahedron #define atsctrb_glutSolidDodecahedron glutSolidDodecahedron #define atsctrb_glutWireOctahedron glutWireOctahedron #define atsctrb_glutSolidOctahedron glutSolidOctahedron #define atsctrb_glutWireTetrahedron glutWireTetrahedron #define atsctrb_glutSolidTetrahedron glutSolidTetrahedron #define atsctrb_glutWireIcosahedron glutWireIcosahedron () #define atsctrb_glutSolidIcosahedron glutSolidIcosahedron () /* ****** ****** */ #endif /* ATSTRIB_GL_GLUT_CATS */ /* end of [glut.cats] */ ats-lang-anairiats-0.2.11/contrib/GL/CATS/glu.cats0000664000175000017500000000564512223166165020151 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 /* ****** ****** */ #ifndef ATSCTRB_GL_GLU_CATS #define ATSCTRB_GL_GLU_CATS /* ****** ****** */ #include /* ****** ****** */ #include /* ****** ****** */ typedef GLUquadricObj ats_GLUquadricObj_type ; /* ****** ****** */ #define atsctrb_gluCylinder gluCylinder /* ****** ****** */ #define atsctrb_gluDeleteQuadric gluDeleteQuadric /* ****** ****** */ #define atsctrb_gluDisk gluDisk /* ****** ****** */ #define atsctrb_gluLookAt gluLookAt /* ****** ****** */ #define atsctrb_gluNewQuadric gluNewQuadric static inline ats_ptr_type atsctrb_gluNewQuadric_exn () { GLUquadricObj* p_obj ; p_obj = gluNewQuadric() ; if (!p_obj) { fprintf (stderr, "exit(ATSCTRB/glu): [gluNewQuadric] failed.\n") ; exit (1) ; } // end of [if] return p_obj ; } // end of [atsctrb_gluNewQuadric_exn] /* ****** ****** */ #define atsctrb_gluOrtho2D gluOrtho2D /* ****** ****** */ #define atsctrb_gluPartialDisk gluPartialDisk /* ****** ****** */ #define atsctrb_gluPerspective gluPerspective /* ****** ****** */ #define atsctrb_gluQuadricDrawStyle gluQuadricDrawStyle #define atsctrb_gluQuadricNormals gluQuadricNormals #define atsctrb_gluQuadricOrientation gluQuadricOrientation #define atsctrb_gluQuadricTexture gluQuadricTexture /* ****** ****** */ #define atsctrb_gluSphere gluSphere /* ****** ****** */ #define atsctrb_gluUnProject gluUnProject /* ****** ****** */ #endif /* ATSCTRB_GL_GLU_CATS */ /* end of [glu.cats] */ ats-lang-anairiats-0.2.11/contrib/GL/CATS/gl.cats0000664000175000017500000003424112223166165017756 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 // /* ****** ****** */ #ifndef ATSCTRB_GL_GL_CATS #define ATSCTRB_GL_GL_CATS /* ****** ****** */ #include // for stderr, fprintf, etc. /* ****** ****** */ #include /* ****** ****** */ extern void exit (int status) ; // see [stdlib.h] /* ****** ****** */ typedef GLboolean ats_GLboolean_type ; typedef GLenum ats_GLenum_type ; typedef GLbitfield ats_GLbitfield_type ; typedef GLdouble ats_GLdouble_type ; typedef GLfloat ats_GLfloat_type ; typedef GLint ats_GLint_type ; typedef GLshort ats_GLshort_type ; typedef GLbyte ats_GLbyte_type ; typedef GLubyte ats_GLubyte_type ; typedef GLuint ats_GLuint_type ; typedef GLushort ats_GLushort_type ; typedef GLsizei ats_GLsizei_type ; typedef GLclampd ats_GLclampd_type ; typedef GLclampf ats_GLclampf_type ; /* ****** ****** */ ATSinline() ats_int_type atsctrb_int_of_GLenum (GLenum x) { return x ; } // ATSinline() ats_bool_type atsctrb_eq_GLenum_GLenum (GLenum x1, GLenum x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_eq_GLenum_GLenum] ATSinline() ats_bool_type atsctrb_neq_GLenum_GLenum (GLenum x1, GLenum x2) { return (x1 != x2 ? ats_true_bool : ats_false_bool) ; } // end of [atsctrb_neq_GLenum_GLenum] // ATSinline() ats_GLbyte_type atsctrb_GLbyte_of_int (int x) { return x ; } // ATSinline() ats_GLubyte_type atsctrb_GLubyte_of_int (int x) { return x ; } ATSinline() ats_GLubyte_type atsctrb_GLubyte_of_uint (unsigned int x) { return x ; } // ATSinline() ats_GLshort_type atsctrb_GLshort_of_int (int x) { return x ; } // ATSinline() ats_GLushort_type atsctrb_GLushort_of_int (int x) { return x ; } ATSinline() ats_GLushort_type atsctrb_GLushort_of_uint (unsigned int x) { return x ; } // ATSinline() ats_GLsizei_type atsctrb_GLsizei_of_int (int x) { return x ; } // ATSinline() ats_GLdouble_type atsctrb_GLdouble_of_int (int x) { return x ; } // ATSinline() ats_GLfloat_type atsctrb_GLfloat_of_int (int x) { return x ; } ATSinline() ats_GLfloat_type atsctrb_GLfloat_of_double (double x) { return x ; } ATSinline() ats_GLclampf_type atsctrb_GLclampf_of_double (double x) { return x ; } // ATSinline() ats_GLbitfield_type atsctrb_lor_GLbitfield_GLbitfield (GLbitfield b1, GLbitfield b2) { return (b1 | b2) ; } // end of [atsctrb_lor_GLbitfield_GLbitfield] /* ****** ****** */ // // Miscellaneous functions // /* ****** ****** */ #define atsctrb_glClearIndex glClearIndex #define atsctrb_glClearColor glClearColor /* ****** ****** */ #define atsctrb_glClear glClear #define atsctrb_glIndexMask glIndexMask #define atsctrb_glColorMask glColorMask /* ****** ****** */ #define atsctrb_glAlphaFunc glAlphaFunc #define atsctrb_glBlendFunc glBlendFunc #define atsctrb_glLogicOp glLogicOp /* ****** ****** */ #define atsctrb_glCullFace glCullFace #define atsctrb_glFrontFace glFrontFace /* ****** ****** */ #define atsctrb_glPointSize glPointSize /* ****** ****** */ #define atsctrb_glLineWidth glLineWidth /* ****** ****** */ #define atsctrb_glLineStipple glLineStipple /* ****** ****** */ #define atsctrb_glPolygonMode glPolygonMode #define atsctrb_glPolygonOffset glPolygonOffset #define atsctrb_glPolygonStipple glPolygonStipple #define atsctrb_glGetPolygonStipple glGetPolygonStipple #define atsctrb_glEdgeFlag glEdgeFlag #define atsctrb_glEdgeFlagv glEdgeFlagv #define atsctrb_glScissor glScissor /* ****** ****** */ #define atsctrb_glClipPlane glClipPlane #define atsctrb_glGetClipPlane glGetClipPlane /* ****** ****** */ #define atsctrb_glDrawBuffer glDrawBuffer #define atsctrb_glReadBuffer glReadBuffer /* ****** ****** */ #define atsctrb_glEnable glEnable #define atsctrb_glDisable glDisable #define atsctrb_glIsEnabled glIsEnabled /* // OpenGL 1.1 #define atsctrb_glEnableClientState glEnableClientState #define atsctrb_glDisableClientState glDisableClientState */ /* ****** ****** */ #define atsctrb_glGetBooleanv glGetBooleanv #define atsctrb_glGetDoublev glGetDoublev #define atsctrb_glGetFloatv glGetFloatv #define atsctrb_glGetIntegerv glGetIntegerv /* ****** ****** */ #define atsctrb_glPushAttrib glPushAttrib #define atsctrb_glPopAttrib glPopAttrib /* ****** ****** */ #define atsctrb_glRenderMode glRenderMode #define atsctrb_glGetError glGetError #define atsctrb_glGetString glGetString #define atsctrb_glFinish glFinish #define atsctrb_glFlush glFlush #define atsctrb_glHint glHint /* ****** ****** */ // Depth Buffer #define atsctrb_glClearDepth glClearDepth #define atsctrb_glDepthFunc glDepthFunc #define atsctrb_glDepthMask glDepthMask #define atsctrb_glDepthRange glDepthRange /* ****** ****** */ // Accumulation Buffer #define atsctrb_glClearAccum glClearAccum #define atsctrb_glAccum glAccum /* ****** ****** */ // // Transformation // /* ****** ****** */ #define atsctrb_glMatrixMode glMatrixMode /* ****** ****** */ #define atsctrb_glOrtho glOrtho /* ****** ****** */ #define atsctrb_glFrustum glFrustum /* ****** ****** */ #define atsctrb_glViewport glViewport /* ****** ****** */ #define atsctrb_glPopMatrix glPopMatrix #define atsctrb_glPushMatrix glPushMatrix /* ****** ****** */ #define atsctrb_glLoadIdentity glLoadIdentity #define atsctrb_glLoadMatrixd glLoadMatrixd #define atsctrb_glLoadMatrixf glLoadMatrixf /* ****** ****** */ #define atsctrb_glMultMatrixd glMultMatrixd #define atsctrb_glMultMatrixf glMultMatrixf /* ****** ****** */ #define atsctrb_glRotated glRotated #define atsctrb_glRotatef glRotatef #define atsctrb_glScaled glScaled #define atsctrb_glScalef glScalef #define atsctrb_glTranslated glTranslated #define atsctrb_glTranslatef glTranslatef /* ****** ****** */ // // Display Lists // #define atsctrb_glIsList glIsList ATSinline() GLuint atsctrb_glGenList () { return glGenLists (1) ; } ATSinline() GLuint atsctrb_glGenList_exn () { GLuint lst = glGenLists (1) ; if (lst == 0) { fprintf (stderr, "exit(ATS/GL): [glGenLists] failed.\n") ; exit (1) ; } // end of [if] return lst ; } // end of [atsctrb_glGenList_exn] #define atsctrb_glGenLists glGenLists ATSinline() GLuint atsctrb_glNewList_new (GLuint lst, GLenum mode) { glNewList (lst, mode) ; return lst ; } // end of [atsctrb_glNewList_new] ATSinline() ats_void_type atsctrb_glNewList_clear (GLuint lst, GLenum mode) { glNewList (lst, mode) ; return ; } // end of [atsctrb_glNewList_clear] ATSinline() ats_void_type atsctrb_glDeleteList (GLuint lst) { glDeleteLists (lst, 1) ; return ; } // end of [atsctrb_glDeleteList] #define atsctrb_glEndList glEndList #define atsctrb_glCallList glCallList #define atsctrb_glListBase glListBase /* ****** ****** */ #define atsctrb_glBegin glBegin #define atsctrb_glEnd glEnd /* ****** ****** */ // // Drawing functions // #define atsctrb_glVertex2d glVertex2d #define atsctrb_glVertex2f glVertex2f #define atsctrb_glVertex2i glVertex2i #define atsctrb_glVertex2s glVertex2s #define atsctrb_glVertex2dv glVertex2dv #define atsctrb_glVertex2fv glVertex2fv #define atsctrb_glVertex2iv glVertex2iv #define atsctrb_glVertex2sv glVertex2sv /* ****** ****** */ #define atsctrb_glVertex3d glVertex3d #define atsctrb_glVertex3f glVertex3f #define atsctrb_glVertex3i glVertex3i #define atsctrb_glVertex3s glVertex3s #define atsctrb_glVertex3dv glVertex3dv #define atsctrb_glVertex3fv glVertex3fv #define atsctrb_glVertex3iv glVertex3iv #define atsctrb_glVertex3sv glVertex3sv /* ****** ****** */ #define atsctrb_glVertex4d glVertex4d #define atsctrb_glVertex4f glVertex4f #define atsctrb_glVertex4i glVertex4i #define atsctrb_glVertex4s glVertex4s #define atsctrb_glVertex4dv glVertex4dv #define atsctrb_glVertex4fv glVertex4fv #define atsctrb_glVertex4iv glVertex4iv #define atsctrb_glVertex4sv glVertex4sv /* ****** ****** */ #define atsctrb_glNormal3b glNormal3b #define atsctrb_glNormal3d glNormal3d #define atsctrb_glNormal3f glNormal3f #define atsctrb_glNormal3i glNormal3i #define atsctrb_glNormal3s glNormal3s #define atsctrb_glNormal3bv glNormal3bv #define atsctrb_glNormal3dv glNormal3dv #define atsctrb_glNormal3fv glNormal3fv #define atsctrb_glNormal3iv glNormal3iv #define atsctrb_glNormal3sv glNormal3sv /* ****** ****** */ #define atsctrb_glIndexd glIndexd #define atsctrb_glIndexf glIndexf #define atsctrb_glIndexi glIndexi #define atsctrb_glIndexs glIndexs #define atsctrb_glIndexub glIndexub /* ****** ****** */ #define atsctrb_glColor3b glColor3b #define atsctrb_glColor3d glColor3d #define atsctrb_glColor3f glColor3f #define atsctrb_glColor3i glColor3i #define atsctrb_glColor3s glColor3s #define atsctrb_glColor3ub glColor3ub #define atsctrb_glColor3ui glColor3ui #define atsctrb_glColor3us glColor3us #define atsctrb_glColor3bv glColor3bv #define atsctrb_glColor3dv glColor3dv #define atsctrb_glColor3fv glColor3fv #define atsctrb_glColor3iv glColor3iv #define atsctrb_glColor3sv glColor3sv #define atsctrb_glColor3ubv glColor3ubv #define atsctrb_glColor3uiv glColor3uiv #define atsctrb_glColor3usv glColor3usv /* ****** ****** */ #define atsctrb_glColor4b glColor4b #define atsctrb_glColor4d glColor4d #define atsctrb_glColor4f glColor4f #define atsctrb_glColor4i glColor4i #define atsctrb_glColor4s glColor4s #define atsctrb_glColor4ub glColor4ub #define atsctrb_glColor4ui glColor4ui #define atsctrb_glColor4us glColor4us #define atsctrb_glColor4bv glColor4bv #define atsctrb_glColor4dv glColor4dv #define atsctrb_glColor4fv glColor4fv #define atsctrb_glColor4iv glColor4iv #define atsctrb_glColor4sv glColor4sv #define atsctrb_glColor4ubv glColor4ubv #define atsctrb_glColor4uiv glColor4uiv #define atsctrb_glColor4usv glColor4usv /* ****** ****** */ #define atsctrb_glTexCoord1d glTexCoord1d #define atsctrb_glTexCoord1f glTexCoord1f #define atsctrb_glTexCoord1i glTexCoord1i #define atsctrb_glTexCoord1s glTexCoord1s #define atsctrb_glTexCoord2d glTexCoord2d #define atsctrb_glTexCoord2f glTexCoord2f #define atsctrb_glTexCoord2i glTexCoord2i #define atsctrb_glTexCoord2s glTexCoord2s #define atsctrb_glTexCoord3d glTexCoord3d #define atsctrb_glTexCoord3f glTexCoord3f #define atsctrb_glTexCoord3i glTexCoord3i #define atsctrb_glTexCoord3s glTexCoord3s /* ****** ****** */ #define atsctrb_glRasterPos2d glRasterPos2d #define atsctrb_glRasterPos2f glRasterPos2f #define atsctrb_glRasterPos2i glRasterPos2i #define atsctrb_glRasterPos2s glRasterPos2s #define atsctrb_glRasterPos3d glRasterPos3d #define atsctrb_glRasterPos3f glRasterPos3f #define atsctrb_glRasterPos3i glRasterPos3i #define atsctrb_glRasterPos3s glRasterPos3s #define atsctrb_glRasterPos4d glRasterPos4d #define atsctrb_glRasterPos4f glRasterPos4f #define atsctrb_glRasterPos4i glRasterPos4i #define atsctrb_glRasterPos4s glRasterPos4s /* ****** ****** */ #define atsctrb_glRectd glRectd #define atsctrb_glRectf glRectf /* ****** ****** */ // // Lighting // /* ****** ****** */ #define atsctrb_glShadeModel glShadeModel #define atsctrb_glLightf glLightf #define atsctrb_glLighti glLighti #define atsctrb_glLightfv glLightfv #define atsctrb_glLightiv glLightiv #define atsctrb_glGetLightfv glGetLightfv #define atsctrb_glGetLightiv glGetLightiv /* ****** ****** */ #define atsctrb_glLightModelf glLightModelf #define atsctrb_glLightModeli glLightModeli #define atsctrb_glLightModelfv glLightModelfv #define atsctrb_glLightModeliv glLightModeliv /* ****** ****** */ #define atsctrb_glMaterialf glMaterialf #define atsctrb_glMateriali glMateriali #define atsctrb_glMaterialfv glMaterialfv #define atsctrb_glMaterialiv glMaterialiv #define atsctrb_glGetMaterialfv glGetMaterialfv #define atsctrb_glGetMaterialiv glGetMaterialiv #define atsctrb_glColorMaterial glColorMaterial /* ****** ****** */ // // Raster functions // #define atsctrb_glPixelZoom glPixelZoom #define atsctrb_glPixelStoref glPixelStoref #define atsctrb_glPixelStorei glPixelStorei #define atsctrb_glBitmap glBitmap #define atsctrb_glReadPixels glReadPixels #define atsctrb_glDrawPixels glDrawPixels #define atsctrb_glCopyPixels glCopyPixels /* ****** ****** */ // // Texture mapping // #define atsctrb_glTexParameterf glTexParameterf #define atsctrb_glTexParameteri glTexParameteri #define atsctrb_glTexEnvf glTexEnvf #define atsctrb_glTexEnvi glTexEnvi /* ****** ****** */ #define atsctrb_glTexImage1D glTexImage1D #define atsctrb_glTexImage2D glTexImage2D /* ****** ****** */ // // OpenGL 1.1 // ATSinline() ats_void_type atsctrb_glGenTexture (ats_ref_type texture) { glGenTextures(1, (GLuint*)texture) ; return ; } // end of [atsctrb_glGenTexture] #define atsctrb_glGenTextures glGenTextures ATSinline() ats_void_type atsctrb_glDeleteTexture (ats_GLuint_type texture) { glDeleteTextures(1, (GLuint*)&texture) ; return ; } // end of [atsctrb_glDeleteTexture] #define atsctrb_glDeleteTextures glDeleteTextures #define atsctrb_glBindTexture glBindTexture /* ****** ****** */ #define atsctrb_glFogf glFogf #define atsctrb_glFogi glFogi #define atsctrb_glFogfv glFogfv #define atsctrb_glFogiv glFogiv /* ****** ****** */ #endif /* ATSCTRB_GL_GL_CATS */ /* end of [gl.cats] */ ats-lang-anairiats-0.2.11/contrib/GL/SATS/0000700000175000017500000000000012223166165016500 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GL/SATS/glut.sats0000664000175000017500000005240412223166165020370 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: Summer, 2008 // (* ****** ****** *) %{# #include "contrib/GL/CATS/glut.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" (* ****** ****** *) (* ** GLUT API macro definitions -- the special key codes: *) macdef GLUT_KEY_F1 = $extval (GLenum, "GLUT_KEY_F1") macdef GLUT_KEY_F2 = $extval (GLenum, "GLUT_KEY_F2") macdef GLUT_KEY_F3 = $extval (GLenum, "GLUT_KEY_F3") macdef GLUT_KEY_F4 = $extval (GLenum, "GLUT_KEY_F4") macdef GLUT_KEY_F5 = $extval (GLenum, "GLUT_KEY_F5") macdef GLUT_KEY_F6 = $extval (GLenum, "GLUT_KEY_F6") macdef GLUT_KEY_F7 = $extval (GLenum, "GLUT_KEY_F7") macdef GLUT_KEY_F8 = $extval (GLenum, "GLUT_KEY_F8") macdef GLUT_KEY_F9 = $extval (GLenum, "GLUT_KEY_F9") macdef GLUT_KEY_F10 = $extval (GLenum, "GLUT_KEY_F10") macdef GLUT_KEY_F11 = $extval (GLenum, "GLUT_KEY_F11") macdef GLUT_KEY_F12 = $extval (GLenum, "GLUT_KEY_F12") macdef GLUT_KEY_LEFT = $extval (GLenum, "GLUT_KEY_LEFT") macdef GLUT_KEY_RIGHT = $extval (GLenum, "GLUT_KEY_RIGHT") macdef GLUT_KEY_UP = $extval (GLenum, "GLUT_KEY_UP") macdef GLUT_KEY_DOWN = $extval (GLenum, "GLUT_KEY_DOWN") macdef GLUT_KEY_PAGE_UP = $extval (GLenum, "GLUT_KEY_PAGE_UP") macdef GLUT_KEY_PAGE_DOWN = $extval (GLenum, "GLUT_KEY_PAGE_DOWN") macdef GLUT_KEY_HOME = $extval (GLenum, "GLUT_KEY_HOME") macdef GLUT_KEY_END = $extval (GLenum, "GLUT_KEY_END") macdef GLUT_KEY_INSERT = $extval (GLenum, "GLUT_KEY_INSERT") (* ****** ****** *) (* ** GLUT API macro definitions -- mouse state definitions *) macdef GLUT_LEFT_BUTTON = $extval (GLenum, "GLUT_LEFT_BUTTON") macdef GLUT_MIDDLE_BUTTON = $extval (GLenum, "GLUT_MIDDLE_BUTTON") macdef GLUT_RIGHT_BUTTON = $extval (GLenum, "GLUT_RIGHT_BUTTON") macdef GLUT_UP = $extval (GLenum, "GLUT_UP") macdef GLUT_DOWN = $extval (GLenum, "GLUT_DOWN") macdef GLUT_LEFT = $extval (GLenum, "GLUT_LEFT") macdef GLUT_ENTERED = $extval (GLenum, "GLUT_ENTERED") (* ****** ****** *) (* ** GLUT API macro definitions -- the display mode definitions *) macdef GLUT_RGB = $extval (GLenum, "GLUT_RGB") macdef GLUT_RGBA = $extval (GLenum, "GLUT_RGBA") macdef GLUT_INDEX = $extval (GLenum, "GLUT_INDEX") macdef GLUT_SINGLE = $extval (GLenum, "GLUT_SINGLE") macdef GLUT_DOUBLE = $extval (GLenum, "GLUT_DOUBLE") macdef GLUT_ACCUM = $extval (GLenum, "GLUT_ACCUM") macdef GLUT_ALPHA = $extval (GLenum, "GLUT_ALPHA") macdef GLUT_DEPTH = $extval (GLenum, "GLUT_DEPTH") macdef GLUT_STENCIL = $extval (GLenum, "GLUT_STENCIL") macdef GLUT_MULTISAMPLE = $extval (GLenum, "GLUT_MULTISAMPLE") macdef GLUT_STEREO = $extval (GLenum, "GLUT_STEREO") macdef GLUT_LUMINANCE = $extval (GLenum, "GLUT_LUMINANCE") (* ****** ****** *) (* ** GLUT API macro definitions -- windows and menu related definitions *) macdef GLUT_MENU_IN_USE = $extval (GLenum, "GLUT_MENU_IN_USE") macdef GLUT_MENU_NOT_IN_USE = $extval (GLenum, "GLUT_MENU_NOT_IN_USE") macdef GLUT_VISIBLE = $extval (GLenum, "GLUT_VISIBLE") macdef GLUT_NOT_VISIBLE = $extval (GLenum, "GLUT_NOT_VISIBLE") macdef GLUT_HIDDEN = $extval (GLenum, "GLUT_HIDDEN") macdef GLUT_FULLY_RETAINED = $extval (GLenum, "GLUT_FULLY_RETAINED") macdef GLUT_PARTIALLY_RETAINED = $extval (GLenum, "GLUT_PARTIALLY_RETAINED") macdef GLUT_FULLY_COVERED = $extval (GLenum, "GLUT_FULLY_COVERED") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutGet parameters *) macdef GLUT_WINDOW_X = $extval (GLenum, "GLUT_WINDOW_X") macdef GLUT_WINDOW_Y = $extval (GLenum, "GLUT_WINDOW_Y") macdef GLUT_WINDOW_WIDTH = $extval (GLenum, "GLUT_WINDOW_WIDTH") macdef GLUT_WINDOW_HEIGHT = $extval (GLenum, "GLUT_WINDOW_HEIGHT") macdef GLUT_WINDOW_BUFFER_SIZE = $extval (GLenum, "GLUT_WINDOW_BUFFER_SIZE") macdef GLUT_WINDOW_STENCIL_SIZE = $extval (GLenum, "GLUT_WINDOW_STENCIL_SIZE") macdef GLUT_WINDOW_DEPTH_SIZE = $extval (GLenum, "GLUT_WINDOW_DEPTH_SIZE") macdef GLUT_WINDOW_RED_SIZE = $extval (GLenum, "GLUT_WINDOW_RED_SIZE") macdef GLUT_WINDOW_GREEN_SIZE = $extval (GLenum, "GLUT_WINDOW_GREEN_SIZE") macdef GLUT_WINDOW_BLUE_SIZE = $extval (GLenum, "GLUT_WINDOW_BLUE_SIZE") macdef GLUT_WINDOW_ALPHA_SIZE = $extval (GLenum, "GLUT_WINDOW_ALPHA_SIZE") macdef GLUT_WINDOW_ACCUM_RED_SIZE = $extval (GLenum, "GLUT_WINDOW_ACCUM_RED_SIZE") macdef GLUT_WINDOW_ACCUM_GREEN_SIZE = $extval (GLenum, "GLUT_WINDOW_ACCUM_GREEN_SIZE") macdef GLUT_WINDOW_ACCUM_BLUE_SIZE = $extval (GLenum, "GLUT_WINDOW_ACCUM_BLUE_SIZE") macdef GLUT_WINDOW_ACCUM_ALPHA_SIZE = $extval (GLenum, "GLUT_WINDOW_ACCUM_ALPHA_SIZE") macdef GLUT_WINDOW_DOUBLEBUFFER = $extval (GLenum, "GLUT_WINDOW_DOUBLEBUFFER") macdef GLUT_WINDOW_RGBA = $extval (GLenum, "GLUT_WINDOW_RGBA") macdef GLUT_WINDOW_PARENT = $extval (GLenum, "GLUT_WINDOW_PARENT") macdef GLUT_WINDOW_NUM_CHILDREN = $extval (GLenum, "GLUT_WINDOW_NUM_CHILDREN") macdef GLUT_WINDOW_COLORMAP_SIZE = $extval (GLenum, "GLUT_WINDOW_COLORMAP_SIZE") macdef GLUT_WINDOW_NUM_SAMPLES = $extval (GLenum, "GLUT_WINDOW_NUM_SAMPLES") macdef GLUT_WINDOW_STEREO = $extval (GLenum, "GLUT_WINDOW_STEREO") macdef GLUT_WINDOW_CURSOR = $extval (GLenum, "GLUT_WINDOW_CURSOR") macdef GLUT_SCREEN_WIDTH = $extval (GLenum, "GLUT_SCREEN_WIDTH") macdef GLUT_SCREEN_HEIGHT = $extval (GLenum, "GLUT_SCREEN_HEIGHT") macdef GLUT_SCREEN_WIDTH_MM = $extval (GLenum, "GLUT_SCREEN_WIDTH_MM") macdef GLUT_SCREEN_HEIGHT_MM = $extval (GLenum, "GLUT_SCREEN_HEIGHT_MM") macdef GLUT_MENU_NUM_ITEMS = $extval (GLenum, "GLUT_MENU_NUM_ITEMS") macdef GLUT_DISPLAY_MODE_POSSIBLE = $extval (GLenum, "GLUT_DISPLAY_MODE_POSSIBLE") macdef GLUT_INIT_WINDOW_X = $extval (GLenum, "GLUT_INIT_WINDOW_X") macdef GLUT_INIT_WINDOW_Y = $extval (GLenum, "GLUT_INIT_WINDOW_Y") macdef GLUT_INIT_WINDOW_WIDTH = $extval (GLenum, "GLUT_INIT_WINDOW_WIDTH") macdef GLUT_INIT_WINDOW_HEIGHT = $extval (GLenum, "GLUT_INIT_WINDOW_HEIGHT") macdef GLUT_INIT_DISPLAY_MODE = $extval (GLenum, "GLUT_INIT_DISPLAY_MODE") macdef GLUT_ELAPSED_TIME = $extval (GLenum, "GLUT_ELAPSED_TIME") macdef GLUT_WINDOW_FORMAT_ID = $extval (GLenum, "GLUT_WINDOW_FORMAT_ID") macdef GLUT_INIT_STATE = $extval (GLenum, "GLUT_INIT_STATE") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutDeviceGet parameters *) macdef GLUT_HAS_KEYBOARD = $extval (GLenum, "GLUT_HAS_KEYBOARD") macdef GLUT_HAS_MOUSE = $extval (GLenum, "GLUT_HAS_MOUSE") macdef GLUT_HAS_SPACEBALL = $extval (GLenum, "GLUT_HAS_SPACEBALL") macdef GLUT_HAS_DIAL_AND_BUTTON_BOX = $extval (GLenum, "GLUT_HAS_DIAL_AND_BUTTON_BOX") macdef GLUT_HAS_TABLET = $extval (GLenum, "GLUT_HAS_TABLET") macdef GLUT_NUM_MOUSE_BUTTONS = $extval (GLenum, "GLUT_NUM_MOUSE_BUTTONS") macdef GLUT_NUM_SPACEBALL_BUTTONS = $extval (GLenum, "GLUT_NUM_SPACEBALL_BUTTONS") macdef GLUT_NUM_BUTTON_BOX_BUTTONS = $extval (GLenum, "GLUT_NUM_BUTTON_BOX_BUTTONS") macdef GLUT_NUM_DIALS = $extval (GLenum, "GLUT_NUM_DIALS") macdef GLUT_NUM_TABLET_BUTTONS = $extval (GLenum, "GLUT_NUM_TABLET_BUTTONS") macdef GLUT_DEVICE_IGNORE_KEY_REPEAT = $extval (GLenum, "GLUT_DEVICE_IGNORE_KEY_REPEAT") macdef GLUT_DEVICE_KEY_REPEAT = $extval (GLenum, "GLUT_DEVICE_KEY_REPEAT") macdef GLUT_HAS_JOYSTICK = $extval (GLenum, "GLUT_HAS_JOYSTICK") macdef GLUT_OWNS_JOYSTICK = $extval (GLenum, "GLUT_OWNS_JOYSTICK") macdef GLUT_JOYSTICK_BUTTONS = $extval (GLenum, "GLUT_JOYSTICK_BUTTONS") macdef GLUT_JOYSTICK_AXES = $extval (GLenum, "GLUT_JOYSTICK_AXES") macdef GLUT_JOYSTICK_POLL_RATE = $extval (GLenum, "GLUT_JOYSTICK_POLL_RATE") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutLayerGet parameters *) macdef GLUT_OVERLAY_POSSIBLE = $extval (GLenum, "GLUT_OVERLAY_POSSIBLE") macdef GLUT_LAYER_IN_USE = $extval (GLenum, "GLUT_LAYER_IN") macdef GLUT_HAS_OVERLAY = $extval (GLenum, "GLUT_HAS_OVERLAY") macdef GLUT_TRANSPARENT_INDEX = $extval (GLenum, "GLUT_TRANSPARENT_INDEX") macdef GLUT_NORMAL_DAMAGED = $extval (GLenum, "GLUT_NORMAL_DAMAGED") macdef GLUT_OVERLAY_DAMAGED = $extval (GLenum, "GLUT_OVERLAY_DAMAGED") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutVideoResizeGet parameters *) macdef GLUT_VIDEO_RESIZE_POSSIBLE = $extval (GLenum, "GLUT_VIDEO_RESIZE_POSSIBLE") macdef GLUT_VIDEO_RESIZE_IN_USE = $extval (GLenum, "GLUT_VIDEO_RESIZE_IN_USE") macdef GLUT_VIDEO_RESIZE_X_DELTA = $extval (GLenum, "GLUT_VIDEO_RESIZE_X_DELTA") macdef GLUT_VIDEO_RESIZE_Y_DELTA = $extval (GLenum, "GLUT_VIDEO_RESIZE_Y_DELTA") macdef GLUT_VIDEO_RESIZE_WIDTH_DELTA = $extval (GLenum, "GLUT_VIDEO_RESIZE_WIDTH_DELTA") macdef GLUT_VIDEO_RESIZE_HEIGHT_DELTA = $extval (GLenum, "GLUT_VIDEO_RESIZE_HEIGHT_DELTA") macdef GLUT_VIDEO_RESIZE_X = $extval (GLenum, "GLUT_VIDEO_RESIZE_X") macdef GLUT_VIDEO_RESIZE_Y = $extval (GLenum, "GLUT_VIDEO_RESIZE_Y") macdef GLUT_VIDEO_RESIZE_WIDTH = $extval (GLenum, "GLUT_VIDEO_RESIZE_WIDTH") macdef GLUT_VIDEO_RESIZE_HEIGHT = $extval (GLenum, "GLUT_VIDEO_RESIZE_HEIGHT") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutUseLayer parameters *) macdef GLUT_NORMAL = $extval (GLenum, "GLUT_NORMAL") macdef GLUT_OVERLAY = $extval (GLenum, "GLUT_OVERLAY") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutGetModifiers parameters *) macdef GLUT_ACTIVE_SHIFT = $extval (GLenum, "GLUT_ACTIVE_SHIFT") macdef GLUT_ACTIVE_CTRL = $extval (GLenum, "GLUT_ACTIVE_CTRL") macdef GLUT_ACTIVE_ALT = $extval (GLenum, "GLUT_ACTIVE_ALT") (* ****** ****** *) (* ** GLUT API macro definitions -- the glutSetCursor parameters *) macdef GLUT_CURSOR_RIGHT_ARROW = $extval (GLenum, "GLUT_CURSOR_RIGHT_ARROW") macdef GLUT_CURSOR_LEFT_ARROW = $extval (GLenum, "GLUT_CURSOR_LEFT_ARROW") macdef GLUT_CURSOR_INFO = $extval (GLenum, "GLUT_CURSOR_INFO") macdef GLUT_CURSOR_DESTROY = $extval (GLenum, "GLUT_CURSOR_DESTROY") macdef GLUT_CURSOR_HELP = $extval (GLenum, "GLUT_CURSOR_HELP") macdef GLUT_CURSOR_CYCLE = $extval (GLenum, "GLUT_CURSOR_CYCLE") macdef GLUT_CURSOR_SPRAY = $extval (GLenum, "GLUT_CURSOR_SPRAY") macdef GLUT_CURSOR_WAIT = $extval (GLenum, "GLUT_CURSOR_WAIT") macdef GLUT_CURSOR_TEXT = $extval (GLenum, "GLUT_CURSOR_TEXT") macdef GLUT_CURSOR_CROSSHAIR = $extval (GLenum, "GLUT_CURSOR_CROSSHAIR") macdef GLUT_CURSOR_UP_DOWN = $extval (GLenum, "GLUT_CURSOR_UP_DOWN") macdef GLUT_CURSOR_LEFT_RIGHT = $extval (GLenum, "GLUT_CURSOR_LEFT_RIGHT") macdef GLUT_CURSOR_TOP_SIDE = $extval (GLenum, "GLUT_CURSOR_TOP_SIDE") macdef GLUT_CURSOR_BOTTOM_SIDE = $extval (GLenum, "GLUT_CURSOR_BOTTOM_SIDE") macdef GLUT_CURSOR_LEFT_SIDE = $extval (GLenum, "GLUT_CURSOR_LEFT_SIDE") macdef GLUT_CURSOR_RIGHT_SIDE = $extval (GLenum, "GLUT_CURSOR_RIGHT_SIDE") macdef GLUT_CURSOR_TOP_LEFT_CORNER = $extval (GLenum, "GLUT_CURSOR_TOP_LEFT_CORNER") macdef GLUT_CURSOR_TOP_RIGHT_CORNER = $extval (GLenum, "GLUT_CURSOR_TOP_RIGHT_CORNER") macdef GLUT_CURSOR_BOTTOM_LEFT_CORNER = $extval (GLenum, "GLUT_CURSOR_BOTTOM_LEFT_CORNER") macdef GLUT_CURSOR_BOTTOM_RIGHT_CORNER = $extval (GLenum, "GLUT_CURSOR_BOTTOM_RIGHT_CORNER") macdef GLUT_CURSOR_INHERIT = $extval (GLenum, "GLUT_CURSOR_INHERIT") macdef GLUT_CURSOR_NONE = $extval (GLenum, "GLUT_CURSOR_NONE") macdef GLUT_CURSOR_FULL_CROSSHAIR = $extval (GLenum, "GLUT_CURSOR_FULL_CROSSHAIR") (* ****** ****** *) (* ** GLUT API macro definitions -- RGB color component specification definitions *) macdef GLUT_RED = $extval (GLenum, "GLUT_RED") macdef GLUT_GREEN = $extval (GLenum, "GLUT_GREEN") macdef GLUT_BLUE = $extval (GLenum, "GLUT_BLUE") (* ****** ****** *) (* ** GLUT API macro definitions -- additional keyboard and joystick definitions *) macdef GLUT_KEY_REPEAT_OFF = $extval (GLenum, "GLUT_KEY_REPEAT_OFF") macdef GLUT_KEY_REPEAT_ON = $extval (GLenum, "GLUT_KEY_REPEAT_ON") macdef GLUT_KEY_REPEAT_DEFAULT = $extval (GLenum, "GLUT_KEY_REPEAT_DEFAULT") macdef GLUT_JOYSTICK_BUTTON_A = $extval (GLenum, "GLUT_JOYSTICK_BUTTON_A") macdef GLUT_JOYSTICK_BUTTON_B = $extval (GLenum, "GLUT_JOYSTICK_BUTTON_B") macdef GLUT_JOYSTICK_BUTTON_C = $extval (GLenum, "GLUT_JOYSTICK_BUTTON_C") macdef GLUT_JOYSTICK_BUTTON_D = $extval (GLenum, "GLUT_JOYSTICK_BUTTON_D") (* ****** ****** *) (* ** GLUT API macro definitions -- game mode definitions *) macdef GLUT_GAME_MODE_ACTIVE = $extval (GLenum, "GLUT_GAME_MODE_ACTIVE") macdef GLUT_GAME_MODE_POSSIBLE = $extval (GLenum, "GLUT_GAME_MODE_POSSIBLE") macdef GLUT_GAME_MODE_WIDTH = $extval (GLenum, "GLUT_GAME_MODE_WIDTH") macdef GLUT_GAME_MODE_HEIGHT = $extval (GLenum, "GLUT_GAME_MODE_HEIGHT") macdef GLUT_GAME_MODE_PIXEL_DEPTH = $extval (GLenum, "GLUT_GAME_MODE_PIXEL_DEPTH") macdef GLUT_GAME_MODE_REFRESH_RATE = $extval (GLenum, "GLUT_GAME_MODE_REFRESH_RATE") macdef GLUT_GAME_MODE_DISPLAY_CHANGED = $extval (GLenum, "GLUT_GAME_MODE_DISPLAY_CHANGED") (* ****** ****** *) (* ** Initialization functions, see fglut_init.c *) (* extern void glutInit( int* pargc, char** argv ); *) fun glutInitWindowPosition ( x: int, y: int ) : void = "mac#atsctrb_glutInitWindowPosition" // end of [fun] fun glutInitWindowSize (width: int, height: int): void = "mac#atsctrb_glutInitWindowSize" // end of [fun] fun glutInitDisplayMode (display: uint): void = "mac#atsctrb_glutInitDisplayMode" // end of [fun] fun glutInitDisplayString (display: string): void = "mac#atsctrb_glutInitDisplayString" // end of [fun] (* ****** ****** *) // // HX: Process loop function, see freeglut_main.c // fun glutMainLoop (): void = "mac#atsctrb_glutMainLoop" (* ****** ****** *) (* ** Window management functions, see freeglut_window.c *) fun glutCreateWindow (title: string): int = "mac#atsctrb_glutCreateWindow" fun glutCreateSubWindow ( window: int, x: int, y: int, width: int, height: int ) : int = "mac#atsctrb_glutCreateSubWindow" // end of [fun] fun glutDestroyWindow (window: int): void = "mac#atsctrb_glutDestroyWindow" fun glutGetWindow (): int = "mac#atsctrb_glutGetWindow" fun glutSetWindow (window: int): void = "mac#atsctrb_glutSetWindow" fun glutSetWindowTitle (title: string): void = "mac#atsctrb_glutSetWindowTitle" fun glutSetIconTitle (title: string): void = "mac#atsctrb_glutSetIconTitle" fun glutReshapeWindow ( width: int, height: int ) : void = "mac#atsctrb_glutReshapeWindow" // end of [fun] fun glutPositionWindow ( x: int, y: int ) : void = "mac#atsctrb_glutPositionWindow" // end of [fun] fun glutShowWindow (): void = "mac#atsctrb_glutShowWindow" fun glutHideWindow (): void = "mac#atsctrb_glutHideWindow" fun glutIconifyWindow (): void = "mac#atsctrb_glutIconifyWindow" fun glutPushWindow (): void = "mac#atsctrb_glutPushWindow" fun glutPopWindow (): void = "mac#atsctrb_glutPopWindow" fun glutFullScreen (): void = "mac#atsctrb_glutFullScreen" (* ****** ****** *) (* ** Display-connected functions, see freeglut_display.c *) fun glutPostWindowRedisplay ( window: int ) : void = "mac#atsctrb_glutPostWindowRedisplay" // end of [fun] fun glutPostRedisplay (): void = "mac#atsctrb_glutPostRedisplay" // end of [fun] fun glutSwapBuffers (): void = "mac#atsctrb_glutSwapBuffers" // end of [fun] (* ****** ****** *) (* ** Global callback functions, see freeglut_callbacks.c *) fun glutTimerFunc ( time: uint, callback: (int) -> void, value: int ) : void = "mac#atsctrb_glutTimerFunc" fun glutIdleFunc ( callback: () -> void ) : void = "mac#atsctrb_glutIdleFunc" fun glutIdleFunc_null (): void = "atsctrb_glutIdleFunc_null" // this is a function! // end of [glutIdleFunc_null] (* ****** ****** *) (* ** Window-specific callback functions, see freeglut_callbacks.c *) fun glutKeyboardFunc ( callback: (uchar, int, int) -> void ) : void = "mac#atsctrb_glutKeyboardFunc" fun glutMouseFunc ( callback: (int, int, int, int) -> void ) : void = "mac#atsctrb_glutMouseFunc" fun glutSpecialFunc ( callback: (int, int, int) -> void ) : void = "mac#atsctrb_glutSpecialFunc" fun glutReshapeFunc ( callback: (int, int) -> void ) : void = "mac#atsctrb_glutReshapeFunc" fun glutVisibilityFunc ( callback: (int) -> void ) : void = "mac#atsctrb_glutVisibilityFunc" fun glutDisplayFunc ( callback: () -> void ) : void = "mac#atsctrb_glutDisplayFunc" fun glutMotionFunc ( callback: (int, int) -> void ) : void = "mac#atsctrb_glutMotionFunc" fun glutPassiveMotionFunc ( callback: (int, int) -> void ) : void = "mac#atsctrb_glutPassiveMotionFunc" fun glutEntryFunc ( callback: (int) -> void ) : void = "mac#atsctrb_glutEntryFunc" (* ****** ****** *) (* ** State setting and retrieval functions, see freeglut_state.c *) fun glutGet (query: GLenum): int = "mac#atsctrb_glutGet" fun glutDeviceGet (query: GLenum): int = "mac#atsctrb_glutDeviceGet" fun glutGetModifiers (): int = "mac#atsctrb_glutGetModifiers" fun glutLayerGet (query: GLenum): int = "mac#atsctrb_glutLayerGet" (* ****** ****** *) abstype GLUTfontref_stroke // void* macdef GLUT_STROKE_ROMAN = $extval (GLUTfontref_stroke, "GLUT_STROKE_ROMAN") macdef GLUT_STROKE_MONO_ROMAN = $extval (GLUTfontref_stroke, "GLUT_STROKE_MONO_ROMAN") fun glutStrokeCharacter ( font: GLUTfontref_stroke, c: char ) : void = "mac#atsctrb_glutStrokeCharacter" fun glutStrokeWidth ( font: GLUTfontref_stroke, c: char ) : int = "mac#atsctrb_glutStrokeWidth" fun glutStrokeLength ( font: GLUTfontref_stroke, txt: string ) : int = "mac#atsctrb_glutStrokeLength" // // HX: implemented in [glut.dats] // fun glutStrokeString (font: GLUTfontref_stroke, s: string): void // end of [glutStrokeString] (* ****** ****** *) abstype GLUTfontref_bitmap // void* macdef GLUT_BITMAP_8_BY_13 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_8_BY_13") macdef GLUT_BITMAP_9_BY_15 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_9_BY_15") macdef GLUT_BITMAP_TIMES_ROMAN_10 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_TIMES_ROMAN_10") macdef GLUT_BITMAP_TIMES_ROMAN_24 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_TIMES_ROMAN_24") macdef GLUT_BITMAP_HELVETICA_10 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_HELVETICA_10") macdef GLUT_BITMAP_HELVETICA_12 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_HELVETICA_12") macdef GLUT_BITMAP_HELVETICA_18 = $extval (GLUTfontref_bitmap, "GLUT_BITMAP_HELVETICA_18") fun glutBitmapCharacter (font: GLUTfontref_bitmap, c: char): void = "mac#atsctrb_glutBitmapCharacter" fun glutBitmapWidth (font: GLUTfontref_bitmap, c: char): int = "mac#atsctrb_glutBitmapWidth" fun glutBitmapLength (font: GLUTfontref_bitmap, txt: string): int = "mac#atsctrb_glutBitmapLength" // // HX: implemented in [glut.dats] // fun glutBitmapString (font: GLUTfontref_bitmap, s: string): void (* ****** ****** *) fun glutWireCube (size: GLdouble): void = "mac#atsctrb_glutWireCube" fun glutSolidCube (size: GLdouble): void = "mac#atsctrb_glutSolidCube" fun glutWireSphere (radius: GLdouble, slices: GLint, stacks: GLint): void = "mac#atsctrb_glutWireSphere" fun glutSolidSphere (radius: GLdouble, slices: GLint, stacks: GLint): void = "mac#atsctrb_glutSolidSphere" (* ****** ****** *) fun glutWireCone ( base: GLdouble, height: GLdouble, slices: GLint, stacks: GLint ) : void = "mac#atsctrb_glutWireCone" // end of [fun] fun glutSolidCone ( base: GLdouble, height: GLdouble, slices: GLint, stacks: GLint ) : void = "mac#atsctrb_glutSolidCone" // end of [fun] (* ****** ****** *) fun glutWireTorus ( innerRadius: GLdouble , outerRadius: GLdouble , sides: GLint , rings: GLint ) : void = "mac#atsctrb_glutWireTorus" // end of [fun] fun glutSolidTorus ( innerRadius: GLdouble , outerRadius: GLdouble , sides: GLint , rings: GLint ) : void = "mac#atsctrb_glutSolidTorus" // end of [fun] (* ****** ****** *) fun glutWireTeapot (size: GLdouble): void = "mac#atsctrb_glutWireTeapot" // end of [glutWireTeapot] fun glutSolidTeapot (size: GLdouble): void = "mac#atsctrb_glutSolidTeapot" // end of [glutSolidTeapot] (* ****** ****** *) fun glutWireDodecahedron (): void = "mac#atsctrb_glutWireDodecahedron" fun glutSolidDodecahedron (): void = "mac#atsctrb_glutSolidDodecahedron" fun glutWireOctahedron (): void = "mac#atsctrb_glutWireOctahedron" fun glutSolidOctahedron (): void = "mac#atsctrb_glutSolidOctahedron" fun glutWireTetrahedron (): void = "mac#atsctrb_glutWireTetrahedron" fun glutSolidTetrahedron (): void = "mac#atsctrb_glutSolidTetrahedron" fun glutWireIcosahedron (): void = "mac#atsctrb_glutWireIcosahedron" fun glutSolidIcosahedron (): void = "mac#atsctrb_glutSolidIcosahedron" (* ****** ****** *) (* end of [glut.sats] *) ats-lang-anairiats-0.2.11/contrib/GL/SATS/glu.sats0000664000175000017500000001535512223166165020210 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: December, 2009 // (* ****** ****** *) %{# #include "contrib/GL/CATS/glu.cats" %} (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" (* ****** ****** *) abst@ype GLUquadricObj = $extype"ats_GLUquadricObj_type" (* ****** ****** *) (* GLAPI void GLAPIENTRY gluCylinder ( GLUquadric* quad, GLdouble base, GLdouble top, GLdouble height , GLint slices, GLint stacks ); *) fun gluCylinder {n,sk:nat} ( qobj: &GLUquadricObj , base: GLdouble, top: GLdouble, height: GLdouble , slices: int n, stacks: int sk ) : void = "mac#atsctrb_gluCylinder" // end of [gluCylinder] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluDeleteQuadric (GLUquadric* quad); *) fun gluDeleteQuadric {l:addr} ( pf: GLUquadricObj @ l | p: ptr l ) : void = "mac#atsctrb_gluDeleteQuadric" // end of [gluDeleteQuadric] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluDisk ( GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops ) ; *) fun gluDisk {n,lp:nat} ( qobj: &GLUquadricObj , inner: GLdouble, outer: GLdouble, slices: int n, loops: int lp ) : void = "mac#atsctrb_gluDisk" // end of [gluDisk] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluLookAt ( GLdouble eyeX, GLdouble eyeY, GLdouble eyeZ , GLdouble centerX, GLdouble centerY, GLdouble centerZ , GLdouble upX, GLdouble upY, GLdouble upZ ) ; *) typedef gluLookAt_type (a:t@ype) = ( a(*eyeX*), a(*eyeY*), a(*eyeZ*) , a(*centerX*), a(*centerY*), a(*centerZ*) , a(*upX*), a(*upY*), a(*upZ*) ) - void // end of [gluLookAt_type] symintr gluLookAt fun gluLookAt_double : gluLookAt_type (double) = "mac#atsctrb_gluLookAt" overload gluLookAt with gluLookAt_double fun gluLookAt_GLdouble : gluLookAt_type (GLdouble) = "mac#atsctrb_gluLookAt" overload gluLookAt with gluLookAt_GLdouble (* ****** ****** *) fun gluNewQuadric ( // there is no argument ) : [l:addr] ( option_v (GLUquadricObj @ l, l <> null) | ptr l ) = "mac#atsctrb_gluNewQuadric" // end of [gluNewQuadric] fun gluNewQuadric_exn ( // there is no argument ) : [l:addr] (GLUquadricObj @ l | ptr l) = "atsctrb_gluNewQuadric_exn" // this is a function! // end of [gluNewQuadric_exn] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluOrtho2D ( GLdouble left, GLdouble right, GLdouble bottom, GLdouble top ) ; *) typedef gluOrtho2D_type (a:t@ype) = (a(*lft*), a(*rgh*), a(*bot*), a(*top*)) - void symintr gluOrtho2D fun gluOrtho2D_double : gluOrtho2D_type (double) = "mac#atsctrb_gluOrtho2D" overload gluOrtho2D with gluOrtho2D_double fun gluOrtho2D_GLdouble : gluOrtho2D_type (GLdouble) = "mac#atsctrb_gluOrtho2D" overload gluOrtho2D with gluOrtho2D_GLdouble (* ****** ****** *) (* GLAPI void GLAPIENTRY gluPartialDisk ( GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops , GLdouble start, GLdouble sweep ) ; *) fun gluPartialDisk {n,lp:nat} ( qobj: &GLUquadricObj, inner: GLdouble, outer: GLdouble, slices: int n, loops: int lp , start: GLdouble, sweep: GLdouble ) : void = "mac#atsctrb_gluPartialDisk" // end of [fun] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluPerspective (GLdouble fovy, GLdouble aspect, GLdouble zNear, GLdouble zFar); *) typedef gluPerspective_type (a:t@ype) = (a(*fovy*), a(*aspect*), a(*zNear*), a(*zFar*)) - void // end of [gluPerspective_type] symintr gluPerspective fun gluPerspective_double : gluPerspective_type (double) = "mac#atsctrb_gluPerspective" overload gluPerspective with gluPerspective_double fun gluPerspective_GLdouble : gluPerspective_type (GLdouble) = "mac#atsctrb_gluPerspective" overload gluPerspective with gluPerspective_GLdouble (* ****** ****** *) (* GLAPI void GLAPIENTRY gluQuadricDrawStyle (GLUquadric* quad, GLenum draw); *) fun gluQuadricDrawStyle ( qobj: &GLUquadricObj, draw: GLenum ) : void = "mac#atsctrb_gluQuadricDrawStyle" // end of [fun] (* GLAPI void GLAPIENTRY gluQuadricNormals (GLUquadric* quad, GLenum normal); *) fun gluQuadricNormals ( qobj: &GLUquadricObj, normal: GLenum ) : void = "mac#atsctrb_gluQuadricNormals" // end of [fun] (* GLAPI void GLAPIENTRY gluQuadricOrientation (GLUquadric* quad, GLenum orientation); *) fun gluQuadricTexture ( qobj: &GLUquadricObj, orientation: GLenum ) : void = "mac#atsctrb_gluQuadricOrientation" // end of [fun] (* GLAPI void GLAPIENTRY gluQuadricTexture (GLUquadric* quad, GLboolean texture); *) fun gluQuadricTexture ( qobj: &GLUquadricObj, texture: GLboolean ) : void = "mac#atsctrb_gluQuadricTexture" // end of [fun] (* ****** ****** *) (* GLAPI void GLAPIENTRY gluSphere (GLUquadric* quad, GLdouble radius, GLint slices, GLint stacks); *) fun gluSphere {n,lp:nat} ( qobj: &GLUquadricObj , radius: GLdouble, slices: int n, loops: int lp ) : void = "mac#atsctrb_gluSphere" (* ****** ****** *) (* GLAPI GLint GLAPIENTRY gluUnProject ( GLdouble winX, GLdouble winY, GLdouble winZ , const GLdouble *model, const GLdouble *proj , const GLint *view , GLdouble* objX, GLdouble* objY, GLdouble* objZ ) ; *) fun gluUnProject ( winX: GLdouble , winY: GLdouble , winZ: GLdouble , model: &(@[GLdouble][16]) , project: &(@[GLdouble][16]) , viewport: &(@[GLint][4]) , objX: &GLdouble? >> GLdouble , objY: &GLdouble? >> GLdouble , objZ: &GLdouble? >> GLdouble ) : GLint = "mac#atsctrb_gluUnProject" // end of [fun] (* ****** ****** *) (* end of [glu.sats] *) ats-lang-anairiats-0.2.11/contrib/GL/SATS/glx.sats0000664000175000017500000000352312223166165020205 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: January, 2010 (* ****** ****** *) staload "contrib/X11/SATS/Xlib.sats" (* ****** ****** *) abst@ype GLXFBConfig = $extype"GLXFBConfig" fun glXGetFBConfigs {l:agz} ( dpy: !Display_ptr l, screen: int, nelements: &int 0 >> int n ) : #[n:nat] [l:addr] ( XFree_v (l), @[GLXFBConfig][n] @ l | ptr l ) = "mac#atsctrb_glXGetFBConfigs" (* ****** ****** *) (* end of [glx.sats] *) ats-lang-anairiats-0.2.11/contrib/GL/SATS/gl.sats0000664000175000017500000026744412223166165020033 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: Summer, 2008 // Restarting time: December, 2009 // (* ****** ****** *) %{# #include "contrib/GL/CATS/gl.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) typedef GLvoid = void // typedef GLenum = uint abst@ype GLenum = $extype"ats_GLenum_type" fun int_of_GLenum (x: GLenum): int = "atsctrb_int_of_GLenum" overload int_of with int_of_GLenum fun eq_GLenum_GLenum (x1: GLenum, x2: GLenum):<> bool = "atsctrb_eq_GLenum_GLenum" overload = with eq_GLenum_GLenum fun neq_GLenum_GLenum (x1: GLenum, x2: GLenum):<> bool = "atsctrb_neq_GLenum_GLenum" overload <> with neq_GLenum_GLenum abst@ype GLenum_type (a:t@ype) = GLenum abst@ype GLenum_format (n:int) = GLenum (* ****** ****** *) // typedef GLbitfield = int abst@ype GLbitfield = $extype"ats_GLbitfield_type" (* ****** ****** *) // typedef GLboolean = uchar abst@ype GLboolean = $extype"ats_GLboolean_type" (* ****** ****** *) // typedef GLbyte = char // 1-byte signed abst@ype GLbyte = $extype"ats_GLbyte_type" castfn GLbyte_of_byte (x: byte):<> GLbyte // typedef GLubyte = uchar // 1-byte unsigned abst@ype GLubyte = $extype"ats_GLubyte_type" castfn GLubyte_of_byte (x: byte):<> GLubyte (* ****** ****** *) // // typedef GLshort = short // 2-byte signed // abst@ype GLshort = $extype"ats_GLshort_type" // // typedef GLushort = usint // 2-byte unsigned // abst@ype GLushort = $extype"ats_GLushort_type" (* ****** ****** *) abst@ype GLint (n:int) = $extype"ats_GLint_type" // 4-byte signed typedef GLint = [n:int] GLint (n) castfn GLint_of_int (x: int):<> GLint castfn int_of_GLint (x: GLint):<> int castfn GLint_of_int1 {n:int} (x: int n):<> GLint n castfn int1_of_GLint {n:int} (x: GLint n):<> int n castfn GLint_of_GLenum (x: GLenum):<> GLint abst@ype GLuint (n:int) = $extype"ats_GLuint_type" // 4-byte unsigned typedef GLuint = [n:nat] GLuint (n) castfn GLuint_of_uint (x: uint):<> GLuint castfn uint_of_GLuint (x: GLuint):<> uint castfn GLuint_of_uint1 {n:int} (x: uint n):<> GLuint n castfn uint1_of_GLuint {n:int} (x: GLuint n):<> uint n (* ****** ****** *) // // typedef GLsizei = int // 4-byte signed // abst@ype GLsizei (i: int) = $extype"ats_GLsizei_type" typedef GLsizei = [i:int] GLsizei (i) (* ****** ****** *) abst@ype GLdouble = $extype"ats_GLdouble_type" // double precision castfn GLdouble_of_double (x: double):<> GLdouble castfn double_of_GLdouble (x: GLdouble):<> double overload double_of with double_of_GLdouble // // typedef GLclampd = double // double precision float in [0,1] // abst@ype GLclampd = $extype"ats_GLclampd_type" castfn GLclampd_of_double (x: double):<> GLclampd (* ****** ****** *) abst@ype GLfloat = $extype"ats_GLfloat_type" // single precision castfn GLfloat_of_float (x: float):<> GLfloat castfn float_of_GLfloat (x: GLfloat):<> float overload float_of with float_of_GLfloat // // typedef GLclampf = float // single precision float in [0,1] // abst@ype GLclampf = $extype"ats_GLclampf_type" castfn GLclampf_of_float (x: float):<> GLclampf (* ****** ****** *) fun GLbyte_of_int (x: int):<> GLbyte = "atsctrb_GLbyte_of_int" fun GLubyte_of_int (x: int):<> GLubyte = "atsctrb_GLubyte_of_int" fun GLubyte_of_uint (x: uint):<> GLubyte = "atsctrb_GLubyte_of_uint" fun GLshort_of_int (x: int):<> GLshort = "atsctrb_GLshort_of_int" fun GLushort_of_int (x: int):<> GLushort = "atsctrb_GLushort_of_int" fun GLushort_of_uint (x: uint):<> GLushort = "atsctrb_GLushort_of_uint" fun GLsizei_of_int1 {i:int} (x: int i): GLsizei i = "atsctrb_GLsizei_of_int" fun GLdouble_of_int (x: int):<> GLdouble = "atsctrb_GLdouble_of_int" fun GLfloat_of_int (x: int):<> GLfloat = "atsctrb_GLfloat_of_int" fun GLfloat_of_double (x: double):<> GLfloat = "atsctrb_GLfloat_of_double" fun GLclampf_of_double (x: double):<> GLclampf = "atsctrb_GLclampf_of_double" (* ****** ****** *) symintr GLbyte GLubyte overload GLbyte with GLbyte_of_int overload GLubyte with GLubyte_of_int overload GLubyte with GLubyte_of_uint symintr GLshort GLushort overload GLshort with GLshort_of_int overload GLushort with GLushort_of_int overload GLushort with GLushort_of_uint symintr GLint GLuint overload GLint with GLint_of_int // castfn overload GLint with GLint_of_int1 // castfn overload GLint with GLint_of_GLenum // castfn overload GLuint with GLuint_of_uint // castfn overload GLuint with GLuint_of_uint1 // castfn symintr GLsizei overload GLsizei with GLsizei_of_int1 symintr GLdouble GLclampd overload GLdouble with GLdouble_of_int overload GLdouble with GLdouble_of_double // castfn overload GLclampd with GLclampd_of_double // castfn symintr GLfloat GLclampf overload GLfloat with GLfloat_of_int overload GLfloat with GLfloat_of_float overload GLfloat with GLfloat_of_double overload GLclampf with GLclampf_of_double (* ****** ****** *) fun lor_GLbitfield_GLbitfield (b1: GLbitfield, b2: GLbitfield): GLbitfield = "atsctrb_lor_GLbitfield_GLbitfield" overload lor with lor_GLbitfield_GLbitfield (* ****** ****** *) abst@ype GLarray2 (a:t@ype, w:int, n:int) // for 2-dimension arrays abst@ype GLarray3 (a:t@ype, w:int, h:int, n:int) // for 3-dimension arrays (* ****** ****** *) // Datatypes macdef GL_BYTE = $extval (GLenum_type GLbyte, "GL_BYTE") macdef GL_UNSIGNED_BYTE = $extval (GLenum_type GLubyte, "GL_UNSIGNED_BYTE") macdef GL_SHORT = $extval (GLenum_type GLshort, "GL_SHORT") macdef GL_UNSIGNED_SHORT = $extval (GLenum_type GLushort, "GL_UNSIGNED_SHORT") macdef GL_INT = $extval (GLenum_type GLint, "GL_INT") macdef GL_UNSIGNED_INT = $extval (GLenum_type GLuint, "GL_UNSIGNED_INT") macdef GL_FLOAT = $extval (GLenum_type GLfloat, "GL_FLOAT") macdef GL_DOUBLE = $extval (GLenum_type GLdouble, "GL_DOUBLE") macdef GL_2_BYTES = $extval (GLenum, "GL_2_BYTES") macdef GL_3_BYTES = $extval (GLenum, "GL_3_BYTES") macdef GL_4_BYTES = $extval (GLenum, "GL_4_BYTES") // Boolean values macdef GL_TRUE = $extval (GLboolean, "GL_TRUE") macdef GL_FALSE = $extval (GLboolean, "GL_FALSE") (* ****** ****** *) // Primitives macdef GL_POINTS = $extval (GLenum, "GL_POINTS") macdef GL_LINES = $extval (GLenum, "GL_LINES") macdef GL_LINE_LOOP = $extval (GLenum, "GL_LINE_LOOP") macdef GL_LINE_STRIP = $extval (GLenum, "GL_LINE_STRIP") macdef GL_TRIANGLES = $extval (GLenum, "GL_TRIANGLES") macdef GL_TRIANGLE_STRIP = $extval (GLenum, "GL_TRIANGLE_STRIP") macdef GL_TRIANGLE_FAN = $extval (GLenum, "GL_TRIANGLE_FAN") macdef GL_QUADS = $extval (GLenum, "GL_QUADS") macdef GL_QUAD_STRIP = $extval (GLenum, "GL_QUAD_STRIP") macdef GL_POLYGON = $extval (GLenum, "GL_POLYGON") // Vertex Arrays macdef GL_VERTEX_ARRAY = $extval (GLenum, "GL_VERTEX_ARRAY") macdef GL_NORMAL_ARRAY = $extval (GLenum, "GL_NORMAL_ARRAY") macdef GL_COLOR_ARRAY = $extval (GLenum, "GL_COLOR_ARRAY") macdef GL_INDEX_ARRAY = $extval (GLenum, "GL_INDEX_ARRAY") macdef GL_TEXTURE_COORD_ARRAY = $extval (GLenum, "GL_TEXTURE_COORD_ARRAY") macdef GL_EDGE_FLAG_ARRAY = $extval (GLenum, "GL_EDGE_FLAG_ARRAY") macdef GL_VERTEX_ARRAY_SIZE = $extval (GLenum, "GL_VERTEX_ARRAY_SIZE") macdef GL_VERTEX_ARRAY_TYPE = $extval (GLenum, "GL_VERTEX_ARRAY_TYPE") macdef GL_VERTEX_ARRAY_STRIDE = $extval (GLenum, "GL_VERTEX_ARRAY_STRIDE") macdef GL_NORMAL_ARRAY_TYPE = $extval (GLenum, "GL_NORMAL_ARRAY_TYPE") macdef GL_NORMAL_ARRAY_STRIDE = $extval (GLenum, "GL_NORMAL_ARRAY_STRIDE") macdef GL_COLOR_ARRAY_SIZE = $extval (GLenum, "GL_COLOR_ARRAY_SIZE") macdef GL_COLOR_ARRAY_TYPE = $extval (GLenum, "GL_COLOR_ARRAY_TYPE") macdef GL_COLOR_ARRAY_STRIDE = $extval (GLenum, "GL_COLOR_ARRAY_STRIDE") macdef GL_INDEX_ARRAY_TYPE = $extval (GLenum, "GL_INDEX_ARRAY_TYPE") macdef GL_INDEX_ARRAY_STRIDE = $extval (GLenum, "GL_INDEX_ARRAY_STRIDE") macdef GL_TEXTURE_COORD_ARRAY_SIZE = $extval (GLenum, "GL_TEXTURE_COORD_ARRAY_SIZE") macdef GL_TEXTURE_COORD_ARRAY_TYPE = $extval (GLenum, "GL_TEXTURE_COORD_ARRAY_TYPE") macdef GL_TEXTURE_COORD_ARRAY_STRIDE = $extval (GLenum, "GL_TEXTURE_COORD_ARRAY_STRIDE") macdef GL_EDGE_FLAG_ARRAY_STRIDE = $extval (GLenum, "GL_EDGE_FLAG_ARRAY_STRIDE") macdef GL_VERTEX_ARRAY_POINTER = $extval (GLenum, "GL_VERTEX_ARRAY_POINTER") macdef GL_NORMAL_ARRAY_POINTER = $extval (GLenum, "GL_NORMAL_ARRAY_POINTER") macdef GL_COLOR_ARRAY_POINTER = $extval (GLenum, "GL_COLOR_ARRAY_POINTER") macdef GL_INDEX_ARRAY_POINTER = $extval (GLenum, "GL_INDEX_ARRAY_POINTER") macdef GL_TEXTURE_COORD_ARRAY_POINTER = $extval (GLenum, "GL_TEXTURE_COORD_ARRAY_POINTER") macdef GL_EDGE_FLAG_ARRAY_POINTER = $extval (GLenum, "GL_EDGE_FLAG_ARRAY_POINTER") macdef GL_V2F = $extval (GLenum, "GL_V2F") macdef GL_V3F = $extval (GLenum, "GL_V3F") macdef GL_C4UB_V2F = $extval (GLenum, "GL_C4UB_V2F") macdef GL_C4UB_V3F = $extval (GLenum, "GL_C4UB_V3F") macdef GL_C3F_V3F = $extval (GLenum, "GL_C3F_V3F") macdef GL_N3F_V3F = $extval (GLenum, "GL_N3F_V3F") macdef GL_C4F_N3F_V3F = $extval (GLenum, "GL_C4F_N3F_V3F") macdef GL_T2F_V3F = $extval (GLenum, "GL_T2F_V3F") macdef GL_T4F_V4F = $extval (GLenum, "GL_T4F_V4F") macdef GL_T2F_C4UB_V3F = $extval (GLenum, "GL_T2F_C4UB_V3F") macdef GL_T2F_C3F_V3F = $extval (GLenum, "GL_T2F_C3F_V3F") macdef GL_T2F_N3F_V3F = $extval (GLenum, "GL_T2F_N3F_V3F") macdef GL_T2F_C4F_N3F_V3F = $extval (GLenum, "GL_T2F_C4F_N3F_V3F") macdef GL_T4F_C4F_N3F_V4F = $extval (GLenum, "GL_T4F_C4F_N3F_V4F") // Matrix Mode macdef GL_MATRIX_MODE = $extval (GLenum, "GL_MATRIX_MODE") macdef GL_MODELVIEW = $extval (GLenum, "GL_MODELVIEW") macdef GL_PROJECTION = $extval (GLenum, "GL_PROJECTION") macdef GL_TEXTURE = $extval (GLenum, "GL_TEXTURE") // Points macdef GL_POINT_SMOOTH = $extval (GLenum, "GL_POINT_SMOOTH") macdef GL_POINT_SIZE = $extval (GLenum, "GL_POINT_SIZE") macdef GL_POINT_SIZE_GRANULARITY = $extval (GLenum, "GL_POINT_SIZE_GRANULARITY") macdef GL_POINT_SIZE_RANGE = $extval (GLenum, "GL_POINT_SIZE_RANGE") // Lines macdef GL_LINE_SMOOTH = $extval (GLenum, "GL_LINE_SMOOTH") macdef GL_LINE_STIPPLE = $extval (GLenum, "GL_LINE_STIPPLE") macdef GL_LINE_STIPPLE_PATTERN = $extval (GLenum, "GL_LINE_STIPPLE_PATTERN") macdef GL_LINE_STIPPLE_REPEAT = $extval (GLenum, "GL_LINE_STIPPLE_REPEAT") macdef GL_LINE_WIDTH = $extval (GLenum, "GL_LINE_WIDTH") macdef GL_LINE_WIDTH_GRANULARITY = $extval (GLenum, "GL_LINE_WIDTH_GRANULARITY") macdef GL_LINE_WIDTH_RANGE = $extval (GLenum, "GL_LINE_WIDTH_RANGE") // Polygons macdef GL_POINT = $extval (GLenum, "GL_POINT") macdef GL_LINE = $extval (GLenum, "GL_LINE") macdef GL_FILL = $extval (GLenum, "GL_FILL") macdef GL_CW = $extval (GLenum, "GL_CW") macdef GL_CCW = $extval (GLenum, "GL_CCW") macdef GL_FRONT = $extval (GLenum, "GL_FRONT") macdef GL_BACK = $extval (GLenum, "GL_BACK") macdef GL_POLYGON_MODE = $extval (GLenum, "GL_POLYGON_MODE") macdef GL_POLYGON_SMOOTH = $extval (GLenum, "GL_POLYGON_SMOOTH") macdef GL_POLYGON_STIPPLE = $extval (GLenum, "GL_POLYGON_STIPPLE") macdef GL_EDGE_FLAG = $extval (GLenum, "GL_EDGE_FLAG") macdef GL_CULL_FACE = $extval (GLenum, "GL_CULL_FACE") macdef GL_CULL_FACE_MODE = $extval (GLenum, "GL_CULL_FACE_MODE") macdef GL_FRONT_FACE = $extval (GLenum, "GL_FRONT_FACE") macdef GL_POLYGON_OFFSET_FACTOR = $extval (GLenum, "GL_POLYGON_OFFSET_FACTOR") macdef GL_POLYGON_OFFSET_UNITS = $extval (GLenum, "GL_POLYGON_OFFSET_UNITS") macdef GL_POLYGON_OFFSET_POINT = $extval (GLenum, "GL_POLYGON_OFFSET_POINT") macdef GL_POLYGON_OFFSET_LINE = $extval (GLenum, "GL_POLYGON_OFFSET_LINE") macdef GL_POLYGON_OFFSET_FILL = $extval (GLenum, "GL_POLYGON_OFFSET_FILL") // Display Lists macdef GL_COMPILE = $extval (GLenum, "GL_COMPILE") macdef GL_COMPILE_AND_EXECUTE = $extval (GLenum, "GL_COMPILE_AND_EXECUTE") macdef GL_LIST_BASE = $extval (GLenum, "GL_LIST_BASE") macdef GL_LIST_INDEX = $extval (GLenum, "GL_LIST_INDEX") macdef GL_LIST_MODE = $extval (GLenum, "GL_LIST_MODE") // Depth buffer macdef GL_NEVER = $extval (GLenum, "GL_NEVER") macdef GL_LESS = $extval (GLenum, "GL_LESS") macdef GL_EQUAL = $extval (GLenum, "GL_EQUAL") macdef GL_LEQUAL = $extval (GLenum, "GL_LEQUAL") macdef GL_GREATER = $extval (GLenum, "GL_GREATER") macdef GL_NOTEQUAL = $extval (GLenum, "GL_NOTEQUAL") macdef GL_GEQUAL = $extval (GLenum, "GL_GEQUAL") macdef GL_ALWAYS = $extval (GLenum, "GL_ALWAYS") macdef GL_DEPTH_TEST = $extval (GLenum, "GL_DEPTH_TEST") macdef GL_DEPTH_BITS = $extval (GLenum, "GL_DEPTH_BITS") macdef GL_DEPTH_CLEAR_VALUE = $extval (GLenum, "GL_DEPTH_CLEAR_VALUE") macdef GL_DEPTH_FUNC = $extval (GLenum, "GL_DEPTH_FUNC") macdef GL_DEPTH_RANGE = $extval (GLenum, "GL_DEPTH_RANGE") macdef GL_DEPTH_WRITEMASK = $extval (GLenum, "GL_DEPTH_WRITEMASK") macdef GL_DEPTH_COMPONENT = $extval (GLenum, "GL_DEPTH_COMPONENT") // Lighting macdef GL_LIGHTING = $extval (GLenum, "GL_LIGHTING") macdef GL_LIGHT0 = $extval (GLenum, "GL_LIGHT0") macdef GL_LIGHT1 = $extval (GLenum, "GL_LIGHT1") macdef GL_LIGHT2 = $extval (GLenum, "GL_LIGHT2") macdef GL_LIGHT3 = $extval (GLenum, "GL_LIGHT3") macdef GL_LIGHT4 = $extval (GLenum, "GL_LIGHT4") macdef GL_LIGHT5 = $extval (GLenum, "GL_LIGHT5") macdef GL_LIGHT6 = $extval (GLenum, "GL_LIGHT6") macdef GL_LIGHT7 = $extval (GLenum, "GL_LIGHT7") macdef GL_SPOT_EXPONENT = $extval (GLenum, "GL_SPOT_EXPONENT") macdef GL_SPOT_CUTOFF = $extval (GLenum, "GL_SPOT_CUTOFF") macdef GL_CONSTANT_ATTENUATION = $extval (GLenum, "GL_CONSTANT_ATTENUATION") macdef GL_LINEAR_ATTENUATION = $extval (GLenum, "GL_LINEAR_ATTENUATION") macdef GL_QUADRATIC_ATTENUATION = $extval (GLenum, "GL_QUADRATIC_ATTENUATION") macdef GL_AMBIENT = $extval (GLenum, "GL_AMBIENT") macdef GL_DIFFUSE = $extval (GLenum, "GL_DIFFUSE") macdef GL_SPECULAR = $extval (GLenum, "GL_SPECULAR") macdef GL_SHININESS = $extval (GLenum, "GL_SHININESS") macdef GL_EMISSION = $extval (GLenum, "GL_EMISSION") macdef GL_POSITION = $extval (GLenum, "GL_POSITION") macdef GL_SPOT_DIRECTION = $extval (GLenum, "GL_SPOT_DIRECTION") macdef GL_AMBIENT_AND_DIFFUSE = $extval (GLenum, "GL_AMBIENT_AND_DIFFUSE") macdef GL_COLOR_INDEXES = $extval (GLenum, "GL_COLOR_INDEXES") macdef GL_LIGHT_MODEL_TWO_SIDE = $extval (GLenum, "GL_LIGHT_MODEL_TWO_SIDE") macdef GL_LIGHT_MODEL_LOCAL_VIEWER = $extval (GLenum, "GL_LIGHT_MODEL_LOCAL_VIEWER") macdef GL_LIGHT_MODEL_AMBIENT = $extval (GLenum, "GL_LIGHT_MODEL_AMBIENT") macdef GL_FRONT_AND_BACK = $extval (GLenum, "GL_FRONT_AND_BACK") macdef GL_SHADE_MODEL = $extval (GLenum, "GL_SHADE_MODEL") macdef GL_FLAT = $extval (GLenum, "GL_FLAT") macdef GL_SMOOTH = $extval (GLenum, "GL_SMOOTH") macdef GL_COLOR_MATERIAL = $extval (GLenum, "GL_COLOR_MATERIAL") macdef GL_COLOR_MATERIAL_FACE = $extval (GLenum, "GL_COLOR_MATERIAL_FACE") macdef GL_COLOR_MATERIAL_PARAMETER = $extval (GLenum, "GL_COLOR_MATERIAL_PARAMETER") macdef GL_NORMALIZE = $extval (GLenum, "GL_NORMALIZE") // User clipping planes macdef GL_CLIP_PLANE0 = $extval (GLenum, "GL_CLIP_PLANE0") macdef GL_CLIP_PLANE1 = $extval (GLenum, "GL_CLIP_PLANE1") macdef GL_CLIP_PLANE2 = $extval (GLenum, "GL_CLIP_PLANE2") macdef GL_CLIP_PLANE3 = $extval (GLenum, "GL_CLIP_PLANE3") macdef GL_CLIP_PLANE4 = $extval (GLenum, "GL_CLIP_PLANE4") macdef GL_CLIP_PLANE5 = $extval (GLenum, "GL_CLIP_PLANE5") // Accumulation buffer macdef GL_ACCUM_RED_BITS = $extval (GLenum, "GL_ACCUM_RED_BITS") macdef GL_ACCUM_GREEN_BITS = $extval (GLenum, "GL_ACCUM_GREEN_BITS") macdef GL_ACCUM_BLUE_BITS = $extval (GLenum, "GL_ACCUM_BLUE_BITS") macdef GL_ACCUM_ALPHA_BITS = $extval (GLenum, "GL_ACCUM_ALPHA_BITS") macdef GL_ACCUM_CLEAR_VALUE = $extval (GLenum, "GL_ACCUM_CLEAR_VALUE") macdef GL_ACCUM = $extval (GLenum, "GL_ACCUM") macdef GL_ADD = $extval (GLenum, "GL_ADD") macdef GL_LOAD = $extval (GLenum, "GL_LOAD") macdef GL_MULT = $extval (GLenum, "GL_MULT") macdef GL_RETURN = $extval (GLenum, "GL_RETURN") // Alpha testing macdef GL_ALPHA_TEST = $extval (GLenum, "GL_ALPHA_TEST") macdef GL_ALPHA_TEST_REF = $extval (GLenum, "GL_ALPHA_TEST_REF") macdef GL_ALPHA_TEST_FUNC = $extval (GLenum, "GL_ALPHA_TEST_FUNC") // Blending macdef GL_BLEND = $extval (GLenum, "GL_BLEND") macdef GL_BLEND_SRC = $extval (GLenum, "GL_BLEND_SRC") macdef GL_BLEND_DST = $extval (GLenum, "GL_BLEND_DST") macdef GL_ZERO = $extval (GLenum, "GL_ZERO") macdef GL_ONE = $extval (GLenum, "GL_ONE") macdef GL_SRC_COLOR = $extval (GLenum, "GL_SRC_COLOR") macdef GL_ONE_MINUS_SRC_COLOR = $extval (GLenum, "GL_ONE_MINUS_SRC_COLOR") macdef GL_SRC_ALPHA = $extval (GLenum, "GL_SRC_ALPHA") macdef GL_ONE_MINUS_SRC_ALPHA = $extval (GLenum, "GL_ONE_MINUS_SRC_ALPHA") macdef GL_DST_ALPHA = $extval (GLenum, "GL_DST_ALPHA") macdef GL_ONE_MINUS_DST_ALPHA = $extval (GLenum, "GL_ONE_MINUS_DST_ALPHA") macdef GL_DST_COLOR = $extval (GLenum, "GL_DST_COLOR") macdef GL_ONE_MINUS_DST_COLOR = $extval (GLenum, "GL_ONE_MINUS_DST_COLOR") macdef GL_SRC_ALPHA_SATURATE = $extval (GLenum, "GL_SRC_ALPHA_SATURATE") // Render mode macdef GL_FEEDBACK = $extval (GLenum, "GL_FEEDBACK") macdef GL_RENDER = $extval (GLenum, "GL_RENDER") macdef GL_SELECT = $extval (GLenum, "GL_SELECT") // Feedback macdef GL_2D = $extval (GLenum, "GL_2D") macdef GL_3D = $extval (GLenum, "GL_3D") macdef GL_3D_COLOR = $extval (GLenum, "GL_3D_COLOR") macdef GL_3D_COLOR_TEXTURE = $extval (GLenum, "GL_3D_COLOR_TEXTURE") macdef GL_4D_COLOR_TEXTURE = $extval (GLenum, "GL_4D_COLOR_TEXTURE") macdef GL_POINT_TOKEN = $extval (GLenum, "GL_POINT_TOKEN") macdef GL_LINE_TOKEN = $extval (GLenum, "GL_LINE_TOKEN") macdef GL_LINE_RESET_TOKEN = $extval (GLenum, "GL_LINE_RESET_TOKEN") macdef GL_POLYGON_TOKEN = $extval (GLenum, "GL_POLYGON_TOKEN") macdef GL_BITMAP_TOKEN = $extval (GLenum, "GL_BITMAP_TOKEN") macdef GL_DRAW_PIXEL_TOKEN = $extval (GLenum, "GL_DRAW_PIXEL_TOKEN") macdef GL_COPY_PIXEL_TOKEN = $extval (GLenum, "GL_COPY_PIXEL_TOKEN") macdef GL_PASS_THROUGH_TOKEN = $extval (GLenum, "GL_PASS_THROUGH_TOKEN") macdef GL_FEEDBACK_BUFFER_POINTER = $extval (GLenum, "GL_FEEDBACK_BUFFER_POINTER") macdef GL_FEEDBACK_BUFFER_SIZE = $extval (GLenum, "GL_FEEDBACK_BUFFER_SIZE") macdef GL_FEEDBACK_BUFFER_TYPE = $extval (GLenum, "GL_FEEDBACK_BUFFER_TYPE") // Selection macdef GL_SELECTION_BUFFER_POINTER = $extval (GLenum, "GL_SELECTION_BUFFER_POINTER") macdef GL_SELECTION_BUFFER_SIZE = $extval (GLenum, "GL_SELECTION_BUFFER_SIZE") // Fog macdef GL_FOG = $extval (GLenum, "GL_FOG") macdef GL_FOG_MODE = $extval (GLenum, "GL_FOG_MODE") macdef GL_FOG_DENSITY = $extval (GLenum, "GL_FOG_DENSITY") macdef GL_FOG_COLOR = $extval (GLenum, "GL_FOG_COLOR") macdef GL_FOG_INDEX = $extval (GLenum, "GL_FOG_INDEX") macdef GL_FOG_START = $extval (GLenum, "GL_FOG_START") macdef GL_FOG_END = $extval (GLenum, "GL_FOG_END") macdef GL_LINEAR = $extval (GLenum, "GL_LINEAR") macdef GL_EXP = $extval (GLenum, "GL_EXP") macdef GL_EXP2 = $extval (GLenum, "GL_EXP2") // Logic Ops macdef GL_LOGIC_OP = $extval (GLenum, "GL_LOGIC_OP") macdef GL_INDEX_LOGIC_OP = $extval (GLenum, "GL_INDEX_LOGIC_OP") macdef GL_COLOR_LOGIC_OP = $extval (GLenum, "GL_COLOR_LOGIC_OP") macdef GL_LOGIC_OP_MODE = $extval (GLenum, "GL_LOGIC_OP_MODE") macdef GL_CLEAR = $extval (GLenum, "GL_CLEAR") macdef GL_SET = $extval (GLenum, "GL_SET") macdef GL_COPY = $extval (GLenum, "GL_COPY") macdef GL_COPY_INVERTED = $extval (GLenum, "GL_COPY_INVERTED") macdef GL_NOOP = $extval (GLenum, "GL_NOOP") macdef GL_INVERT = $extval (GLenum, "GL_INVERT") macdef GL_AND = $extval (GLenum, "GL_AND") macdef GL_NAND = $extval (GLenum, "GL_NAND") macdef GL_OR = $extval (GLenum, "GL_OR") macdef GL_NOR = $extval (GLenum, "GL_NOR") macdef GL_XOR = $extval (GLenum, "GL_XOR") macdef GL_EQUIV = $extval (GLenum, "GL_EQUIV") macdef GL_AND_REVERSE = $extval (GLenum, "GL_AND_REVERSE") macdef GL_AND_INVERTED = $extval (GLenum, "GL_AND_INVERTED") macdef GL_OR_REVERSE = $extval (GLenum, "GL_OR_REVERSE") macdef GL_OR_INVERTED = $extval (GLenum, "GL_OR_INVERTED") // Stencil macdef GL_STENCIL_BITS = $extval (GLenum, "GL_STENCIL_BITS") macdef GL_STENCIL_TEST = $extval (GLenum, "GL_STENCIL_TEST") macdef GL_STENCIL_CLEAR_VALUE = $extval (GLenum, "GL_STENCIL_CLEAR_VALUE") macdef GL_STENCIL_FUNC = $extval (GLenum, "GL_STENCIL_FUNC") macdef GL_STENCIL_VALUE_MASK = $extval (GLenum, "GL_STENCIL_VALUE_MASK") macdef GL_STENCIL_FAIL = $extval (GLenum, "GL_STENCIL_FAIL") macdef GL_STENCIL_PASS_DEPTH_FAIL = $extval (GLenum, "GL_STENCIL_PASS_DEPTH_FAIL") macdef GL_STENCIL_PASS_DEPTH_PASS = $extval (GLenum, "GL_STENCIL_PASS_DEPTH_PASS") macdef GL_STENCIL_REF = $extval (GLenum, "GL_STENCIL_REF") macdef GL_STENCIL_WRITEMASK = $extval (GLenum, "GL_STENCIL_WRITEMASK") macdef GL_STENCIL_INDEX = $extval (GLenum, "GL_STENCIL_INDEX") macdef GL_KEEP = $extval (GLenum, "GL_KEEP") macdef GL_REPLACE = $extval (GLenum, "GL_REPLACE") macdef GL_INCR = $extval (GLenum, "GL_INCR") macdef GL_DECR = $extval (GLenum, "GL_DECR") // Buffers, Pixel Drawing/Reading macdef GL_NONE = $extval (GLenum, "GL_NONE") macdef GL_LEFT = $extval (GLenum, "GL_LEFT") macdef GL_RIGHT = $extval (GLenum, "GL_RIGHT") macdef GL_FRONT_LEFT = $extval (GLenum, "GL_FRONT_LEFT") macdef GL_FRONT_RIGHT = $extval (GLenum, "GL_FRONT_RIGHT") macdef GL_BACK_LEFT = $extval (GLenum, "GL_BACK_LEFT") macdef GL_BACK_RIGHT = $extval (GLenum, "GL_BACK_RIGHT") macdef GL_AUX0 = $extval (GLenum, "GL_AUX0") macdef GL_AUX1 = $extval (GLenum, "GL_AUX1") macdef GL_AUX2 = $extval (GLenum, "GL_AUX2") macdef GL_AUX3 = $extval (GLenum, "GL_AUX3") // macdef GL_COLOR_INDEX = $extval (GLenum, "GL_COLOR_INDEX") macdef GL_COLOR_INDEX_format = $extval (GLenum_format 1, "GL_COLOR_INDEX") macdef GL_RED = $extval (GLenum, "GL_RED") macdef GL_RED_format = $extval (GLenum_format 1, "GL_RED") macdef GL_GREEN = $extval (GLenum, "GL_GREEN") macdef GL_GREEN_format = $extval (GLenum_format 1, "GL_GREEN") macdef GL_BLUE = $extval (GLenum, "GL_BLUE") macdef GL_BLUE_format = $extval (GLenum_format 1, "GL_BLUE") macdef GL_ALPHA = $extval (GLenum, "GL_ALPHA") macdef GL_ALPHA_format = $extval (GLenum_format 1, "GL_ALPHA") macdef GL_LUMINANCE = $extval (GLenum, "GL_LUMINANCE") macdef GL_LUMINANCE_format = $extval (GLenum_format 1, "GL_LUMINANCE") macdef GL_LUMINANCE_ALPHA = $extval (GLenum, "GL_LUMINANCE_ALPHA") macdef GL_LUMINANCE_ALPHA_format = $extval (GLenum_format 2, "GL_LUMINANCE_ALPHA") // macdef GL_ALPHA_BITS = $extval (GLenum, "GL_ALPHA_BITS") macdef GL_RED_BITS = $extval (GLenum, "GL_RED_BITS") macdef GL_GREEN_BITS = $extval (GLenum, "GL_GREEN_BITS") macdef GL_BLUE_BITS = $extval (GLenum, "GL_BLUE_BITS") macdef GL_INDEX_BITS = $extval (GLenum, "GL_INDEX_BITS") macdef GL_SUBPIXEL_BITS = $extval (GLenum, "GL_SUBPIXEL_BITS") macdef GL_AUX_BUFFERS = $extval (GLenum, "GL_AUX_BUFFERS") macdef GL_READ_BUFFER = $extval (GLenum, "GL_READ_BUFFER") macdef GL_DRAW_BUFFER = $extval (GLenum, "GL_DRAW_BUFFER") macdef GL_DOUBLEBUFFER = $extval (GLenum, "GL_DOUBLEBUFFER") macdef GL_STEREO = $extval (GLenum, "GL_STEREO") macdef GL_BITMAP = $extval (GLenum, "GL_BITMAP") macdef GL_COLOR = $extval (GLenum, "GL_COLOR") macdef GL_DEPTH = $extval (GLenum, "GL_DEPTH") macdef GL_STENCIL = $extval (GLenum, "GL_STENCIL") macdef GL_DITHER = $extval (GLenum, "GL_DITHER") // macdef GL_RGB = $extval (GLenum, "GL_RGB") macdef GL_RGB_format = $extval (GLenum_format 3, "GL_RGB") macdef GL_RGBA = $extval (GLenum, "GL_RGBA") macdef GL_RGBA_format = $extval (GLenum_format 4, "GL_RGBA") // // // Implementation Limits // macdef GL_MAX_LIST_NESTING = $extval (GLenum, "GL_MAX_LIST_NESTING") macdef GL_MAX_EVAL_ORDER = $extval (GLenum, "GL_MAX_EVAL_ORDER") macdef GL_MAX_LIGHTS = $extval (GLenum, "GL_MAX_LIGHTS") macdef GL_MAX_CLIP_PLANES = $extval (GLenum, "GL_MAX_CLIP_PLANES") macdef GL_MAX_TEXTURE_SIZE = $extval (GLenum, "GL_MAX_TEXTURE_SIZE") macdef GL_MAX_PIXEL_MAP_TABLE = $extval (GLenum, "GL_MAX_PIXEL_MAP_TABLE") macdef GL_MAX_ATTRIB_STACK_DEPTH = $extval (GLenum, "GL_MAX_ATTRIB_STACK_DEPTH") macdef GL_MAX_MODELVIEW_STACK_DEPTH = $extval (GLenum, "GL_MAX_MODELVIEW_STACK_DEPTH") macdef GL_MAX_NAME_STACK_DEPTH = $extval (GLenum, "GL_MAX_NAME_STACK_DEPTH") macdef GL_MAX_PROJECTION_STACK_DEPTH = $extval (GLenum, "GL_MAX_PROJECTION_STACK_DEPTH") macdef GL_MAX_TEXTURE_STACK_DEPTH = $extval (GLenum, "GL_MAX_TEXTURE_STACK_DEPTH") macdef GL_MAX_VIEWPORT_DIMS = $extval (GLenum, "GL_MAX_VIEWPORT_DIMS") macdef GL_MAX_CLIENT_ATTRIB_STACK_DEPTH = $extval (GLenum, "GL_MAX_CLIENT_ATTRIB_STACK_DEPTH") // Gets macdef GL_ATTRIB_STACK_DEPTH = $extval (GLenum, "GL_ATTRIB_STACK_DEPTH") macdef GL_CLIENT_ATTRIB_STACK_DEPTH = $extval (GLenum, "GL_CLIENT_ATTRIB_STACK_DEPTH") macdef GL_COLOR_CLEAR_VALUE = $extval (GLenum, "GL_COLOR_CLEAR_VALUE") macdef GL_COLOR_WRITEMASK = $extval (GLenum, "GL_COLOR_WRITEMASK") macdef GL_CURRENT_INDEX = $extval (GLenum, "GL_CURRENT_INDEX") macdef GL_CURRENT_COLOR = $extval (GLenum, "GL_CURRENT_COLOR") macdef GL_CURRENT_NORMAL = $extval (GLenum, "GL_CURRENT_NORMAL") macdef GL_CURRENT_RASTER_COLOR = $extval (GLenum, "GL_CURRENT_RASTER_COLOR") macdef GL_CURRENT_RASTER_DISTANCE = $extval (GLenum, "GL_CURRENT_RASTER_DISTANCE") macdef GL_CURRENT_RASTER_INDEX = $extval (GLenum, "GL_CURRENT_RASTER_INDEX") macdef GL_CURRENT_RASTER_POSITION = $extval (GLenum, "GL_CURRENT_RASTER_POSITION") macdef GL_CURRENT_RASTER_TEXTURE_COORDS = $extval (GLenum, "GL_CURRENT_RASTER_TEXTURE_COORDS") macdef GL_CURRENT_RASTER_POSITION_VALID = $extval (GLenum, "GL_CURRENT_RASTER_POSITION_VALID") macdef GL_CURRENT_TEXTURE_COORDS = $extval (GLenum, "GL_CURRENT_TEXTURE_COORDS") macdef GL_INDEX_CLEAR_VALUE = $extval (GLenum, "GL_INDEX_CLEAR_VALUE") macdef GL_INDEX_MODE = $extval (GLenum, "GL_INDEX_MODE") macdef GL_INDEX_WRITEMASK = $extval (GLenum, "GL_INDEX_WRITEMASK") macdef GL_MODELVIEW_MATRIX = $extval (GLenum, "GL_MODELVIEW_MATRIX") macdef GL_MODELVIEW_STACK_DEPTH = $extval (GLenum, "GL_MODELVIEW_STACK_DEPTH") macdef GL_NAME_STACK_DEPTH = $extval (GLenum, "GL_NAME_STACK_DEPTH") macdef GL_PROJECTION_MATRIX = $extval (GLenum, "GL_PROJECTION_MATRIX") macdef GL_PROJECTION_STACK_DEPTH = $extval (GLenum, "GL_PROJECTION_STACK_DEPTH") macdef GL_RENDER_MODE = $extval (GLenum, "GL_RENDER_MODE") macdef GL_RGBA_MODE = $extval (GLenum, "GL_RGBA_MODE") macdef GL_TEXTURE_MATRIX = $extval (GLenum, "GL_TEXTURE_MATRIX") macdef GL_TEXTURE_STACK_DEPTH = $extval (GLenum, "GL_TEXTURE_STACK_DEPTH") macdef GL_VIEWPORT = $extval (GLenum, "GL_VIEWPORT") // Evaluators macdef GL_AUTO_NORMAL = $extval (GLenum, "GL_AUTO_NORMAL") macdef GL_MAP1_COLOR_4 = $extval (GLenum, "GL_MAP1_COLOR_4") macdef GL_MAP1_INDEX = $extval (GLenum, "GL_MAP1_INDEX") macdef GL_MAP1_NORMAL = $extval (GLenum, "GL_MAP1_NORMAL") macdef GL_MAP1_TEXTURE_COORD_1 = $extval (GLenum, "GL_MAP1_TEXTURE_COORD_1") macdef GL_MAP1_TEXTURE_COORD_2 = $extval (GLenum, "GL_MAP1_TEXTURE_COORD_2") macdef GL_MAP1_TEXTURE_COORD_3 = $extval (GLenum, "GL_MAP1_TEXTURE_COORD_3") macdef GL_MAP1_TEXTURE_COORD_4 = $extval (GLenum, "GL_MAP1_TEXTURE_COORD_4") macdef GL_MAP1_VERTEX_3 = $extval (GLenum, "GL_MAP1_VERTEX_3") macdef GL_MAP1_VERTEX_4 = $extval (GLenum, "GL_MAP1_VERTEX_4") macdef GL_MAP2_COLOR_4 = $extval (GLenum, "GL_MAP2_COLOR_4") macdef GL_MAP2_INDEX = $extval (GLenum, "GL_MAP2_INDEX") macdef GL_MAP2_NORMAL = $extval (GLenum, "GL_MAP2_NORMAL") macdef GL_MAP2_TEXTURE_COORD_1 = $extval (GLenum, "GL_MAP2_TEXTURE_COORD_1") macdef GL_MAP2_TEXTURE_COORD_2 = $extval (GLenum, "GL_MAP2_TEXTURE_COORD_2") macdef GL_MAP2_TEXTURE_COORD_3 = $extval (GLenum, "GL_MAP2_TEXTURE_COORD_3") macdef GL_MAP2_TEXTURE_COORD_4 = $extval (GLenum, "GL_MAP2_TEXTURE_COORD_4") macdef GL_MAP2_VERTEX_3 = $extval (GLenum, "GL_MAP2_VERTEX_3") macdef GL_MAP2_VERTEX_4 = $extval (GLenum, "GL_MAP2_VERTEX_4") macdef GL_MAP1_GRID_DOMAIN = $extval (GLenum, "GL_MAP1_GRID_DOMAIN") macdef GL_MAP1_GRID_SEGMENTS = $extval (GLenum, "GL_MAP1_GRID_SEGMENTS") macdef GL_MAP2_GRID_DOMAIN = $extval (GLenum, "GL_MAP2_GRID_DOMAIN") macdef GL_MAP2_GRID_SEGMENTS = $extval (GLenum, "GL_MAP2_GRID_SEGMENTS") macdef GL_COEFF = $extval (GLenum, "GL_COEFF") macdef GL_ORDER = $extval (GLenum, "GL_ORDER") macdef GL_DOMAIN = $extval (GLenum, "GL_DOMAIN") // Hints macdef GL_PERSPECTIVE_CORRECTION_HINT = $extval (GLenum, "GL_PERSPECTIVE_CORRECTION_HINT") macdef GL_POINT_SMOOTH_HINT = $extval (GLenum, "GL_POINT_SMOOTH_HINT") macdef GL_LINE_SMOOTH_HINT = $extval (GLenum, "GL_LINE_SMOOTH_HINT") macdef GL_POLYGON_SMOOTH_HINT = $extval (GLenum, "GL_POLYGON_SMOOTH_HINT") macdef GL_FOG_HINT = $extval (GLenum, "GL_FOG_HINT") macdef GL_DONT_CARE = $extval (GLenum, "GL_DONT_CARE") macdef GL_FASTEST = $extval (GLenum, "GL_FASTEST") macdef GL_NICEST = $extval (GLenum, "GL_NICEST") // Scissor box macdef GL_SCISSOR_BOX = $extval (GLenum, "GL_SCISSOR_BOX") macdef GL_SCISSOR_TEST = $extval (GLenum, "GL_SCISSOR_TEST") // Pixel Mode / Transfer macdef GL_MAP_COLOR = $extval (GLenum, "GL_MAP_COLOR") macdef GL_MAP_STENCIL = $extval (GLenum, "GL_MAP_STENCIL") macdef GL_INDEX_SHIFT = $extval (GLenum, "GL_INDEX_SHIFT") macdef GL_INDEX_OFFSET = $extval (GLenum, "GL_INDEX_OFFSET") macdef GL_RED_SCALE = $extval (GLenum, "GL_RED_SCALE") macdef GL_RED_BIAS = $extval (GLenum, "GL_RED_BIAS") macdef GL_GREEN_SCALE = $extval (GLenum, "GL_GREEN_SCALE") macdef GL_GREEN_BIAS = $extval (GLenum, "GL_GREEN_BIAS") macdef GL_BLUE_SCALE = $extval (GLenum, "GL_BLUE_SCALE") macdef GL_BLUE_BIAS = $extval (GLenum, "GL_BLUE_BIAS") macdef GL_ALPHA_SCALE = $extval (GLenum, "GL_ALPHA_SCALE") macdef GL_ALPHA_BIAS = $extval (GLenum, "GL_ALPHA_BIAS") macdef GL_DEPTH_SCALE = $extval (GLenum, "GL_DEPTH_SCALE") macdef GL_DEPTH_BIAS = $extval (GLenum, "GL_DEPTH_BIAS") macdef GL_PIXEL_MAP_S_TO_S_SIZE = $extval (GLenum, "GL_PIXEL_MAP_S_TO_S_SIZE") macdef GL_PIXEL_MAP_I_TO_I_SIZE = $extval (GLenum, "GL_PIXEL_MAP_I_TO_I_SIZE") macdef GL_PIXEL_MAP_I_TO_R_SIZE = $extval (GLenum, "GL_PIXEL_MAP_I_TO_R_SIZE") macdef GL_PIXEL_MAP_I_TO_G_SIZE = $extval (GLenum, "GL_PIXEL_MAP_I_TO_G_SIZE") macdef GL_PIXEL_MAP_I_TO_B_SIZE = $extval (GLenum, "GL_PIXEL_MAP_I_TO_B_SIZE") macdef GL_PIXEL_MAP_I_TO_A_SIZE = $extval (GLenum, "GL_PIXEL_MAP_I_TO_A_SIZE") macdef GL_PIXEL_MAP_R_TO_R_SIZE = $extval (GLenum, "GL_PIXEL_MAP_R_TO_R_SIZE") macdef GL_PIXEL_MAP_G_TO_G_SIZE = $extval (GLenum, "GL_PIXEL_MAP_G_TO_G_SIZE") macdef GL_PIXEL_MAP_B_TO_B_SIZE = $extval (GLenum, "GL_PIXEL_MAP_B_TO_B_SIZE") macdef GL_PIXEL_MAP_A_TO_A_SIZE = $extval (GLenum, "GL_PIXEL_MAP_A_TO_A_SIZE") macdef GL_PIXEL_MAP_S_TO_S = $extval (GLenum, "GL_PIXEL_MAP_S_TO_S") macdef GL_PIXEL_MAP_I_TO_I = $extval (GLenum, "GL_PIXEL_MAP_I_TO_I") macdef GL_PIXEL_MAP_I_TO_R = $extval (GLenum, "GL_PIXEL_MAP_I_TO_R") macdef GL_PIXEL_MAP_I_TO_G = $extval (GLenum, "GL_PIXEL_MAP_I_TO_G") macdef GL_PIXEL_MAP_I_TO_B = $extval (GLenum, "GL_PIXEL_MAP_I_TO_B") macdef GL_PIXEL_MAP_I_TO_A = $extval (GLenum, "GL_PIXEL_MAP_I_TO_A") macdef GL_PIXEL_MAP_R_TO_R = $extval (GLenum, "GL_PIXEL_MAP_R_TO_R") macdef GL_PIXEL_MAP_G_TO_G = $extval (GLenum, "GL_PIXEL_MAP_G_TO_G") macdef GL_PIXEL_MAP_B_TO_B = $extval (GLenum, "GL_PIXEL_MAP_B_TO_B") macdef GL_PIXEL_MAP_A_TO_A = $extval (GLenum, "GL_PIXEL_MAP_A_TO_A") macdef GL_PACK_ALIGNMENT = $extval (GLenum, "GL_PACK_ALIGNMENT") macdef GL_PACK_LSB_FIRST = $extval (GLenum, "GL_PACK_LSB_FIRST") macdef GL_PACK_ROW_LENGTH = $extval (GLenum, "GL_PACK_ROW_LENGTH") macdef GL_PACK_SKIP_PIXELS = $extval (GLenum, "GL_PACK_SKIP_PIXELS") macdef GL_PACK_SKIP_ROWS = $extval (GLenum, "GL_PACK_SKIP_ROWS") macdef GL_PACK_SWAP_BYTES = $extval (GLenum, "GL_PACK_SWAP_BYTES") macdef GL_UNPACK_ALIGNMENT = $extval (GLenum, "GL_UNPACK_ALIGNMENT") macdef GL_UNPACK_LSB_FIRST = $extval (GLenum, "GL_UNPACK_LSB_FIRST") macdef GL_UNPACK_ROW_LENGTH = $extval (GLenum, "GL_UNPACK_ROW_LENGTH") macdef GL_UNPACK_SKIP_PIXELS = $extval (GLenum, "GL_UNPACK_SKIP_PIXELS") macdef GL_UNPACK_SKIP_ROWS = $extval (GLenum, "GL_UNPACK_SKIP_ROWS") macdef GL_UNPACK_SWAP_BYTES = $extval (GLenum, "GL_UNPACK_SWAP_BYTES") macdef GL_ZOOM_X = $extval (GLenum, "GL_ZOOM_X") macdef GL_ZOOM_Y = $extval (GLenum, "GL_ZOOM_Y") // Texture mapping macdef GL_TEXTURE_ENV = $extval (GLenum, "GL_TEXTURE_ENV") macdef GL_TEXTURE_ENV_MODE = $extval (GLenum, "GL_TEXTURE_ENV_MODE") macdef GL_TEXTURE_1D = $extval (GLenum, "GL_TEXTURE_1D") macdef GL_TEXTURE_2D = $extval (GLenum, "GL_TEXTURE_2D") macdef GL_TEXTURE_WRAP_S = $extval (GLenum, "GL_TEXTURE_WRAP_S") macdef GL_TEXTURE_WRAP_T = $extval (GLenum, "GL_TEXTURE_WRAP_T") macdef GL_TEXTURE_MAG_FILTER = $extval (GLenum, "GL_TEXTURE_MAG_FILTER") macdef GL_TEXTURE_MIN_FILTER = $extval (GLenum, "GL_TEXTURE_MIN_FILTER") macdef GL_TEXTURE_ENV_COLOR = $extval (GLenum, "GL_TEXTURE_ENV_COLOR") macdef GL_TEXTURE_GEN_S = $extval (GLenum, "GL_TEXTURE_GEN_S") macdef GL_TEXTURE_GEN_T = $extval (GLenum, "GL_TEXTURE_GEN_T") macdef GL_TEXTURE_GEN_MODE = $extval (GLenum, "GL_TEXTURE_GEN_MODE") macdef GL_TEXTURE_BORDER_COLOR = $extval (GLenum, "GL_TEXTURE_BORDER_COLOR") macdef GL_TEXTURE_WIDTH = $extval (GLenum, "GL_TEXTURE_WIDTH") macdef GL_TEXTURE_HEIGHT = $extval (GLenum, "GL_TEXTURE_HEIGHT") macdef GL_TEXTURE_BORDER = $extval (GLenum, "GL_TEXTURE_BORDER") macdef GL_TEXTURE_COMPONENTS = $extval (GLenum, "GL_TEXTURE_COMPONENTS") macdef GL_TEXTURE_RED_SIZE = $extval (GLenum, "GL_TEXTURE_RED_SIZE") macdef GL_TEXTURE_GREEN_SIZE = $extval (GLenum, "GL_TEXTURE_GREEN_SIZE") macdef GL_TEXTURE_BLUE_SIZE = $extval (GLenum, "GL_TEXTURE_BLUE_SIZE") macdef GL_TEXTURE_ALPHA_SIZE = $extval (GLenum, "GL_TEXTURE_ALPHA_SIZE") macdef GL_TEXTURE_LUMINANCE_SIZE = $extval (GLenum, "GL_TEXTURE_LUMINANCE_SIZE") macdef GL_TEXTURE_INTENSITY_SIZE = $extval (GLenum, "GL_TEXTURE_INTENSITY_SIZE") macdef GL_NEAREST_MIPMAP_NEAREST = $extval (GLenum, "GL_NEAREST_MIPMAP_NEAREST") macdef GL_NEAREST_MIPMAP_LINEAR = $extval (GLenum, "GL_NEAREST_MIPMAP_LINEAR") macdef GL_LINEAR_MIPMAP_NEAREST = $extval (GLenum, "GL_LINEAR_MIPMAP_NEAREST") macdef GL_LINEAR_MIPMAP_LINEAR = $extval (GLenum, "GL_LINEAR_MIPMAP_LINEAR") macdef GL_OBJECT_LINEAR = $extval (GLenum, "GL_OBJECT_LINEAR") macdef GL_OBJECT_PLANE = $extval (GLenum, "GL_OBJECT_PLANE") macdef GL_EYE_LINEAR = $extval (GLenum, "GL_EYE_LINEAR") macdef GL_EYE_PLANE = $extval (GLenum, "GL_EYE_PLANE") macdef GL_SPHERE_MAP = $extval (GLenum, "GL_SPHERE_MAP") macdef GL_DECAL = $extval (GLenum, "GL_DECAL") macdef GL_MODULATE = $extval (GLenum, "GL_MODULATE") macdef GL_NEAREST = $extval (GLenum, "GL_NEAREST") macdef GL_REPEAT = $extval (GLenum, "GL_REPEAT") macdef GL_CLAMP = $extval (GLenum, "GL_CLAMP") macdef GL_S = $extval (GLenum, "GL_S") macdef GL_T = $extval (GLenum, "GL_T") macdef GL_R = $extval (GLenum, "GL_R") macdef GL_Q = $extval (GLenum, "GL_Q") macdef GL_TEXTURE_GEN_R = $extval (GLenum, "GL_TEXTURE_GEN_R") macdef GL_TEXTURE_GEN_Q = $extval (GLenum, "GL_TEXTURE_GEN_Q") // Utility macdef GL_VENDOR = $extval (GLenum, "GL_VENDOR") macdef GL_RENDERER = $extval (GLenum, "GL_RENDERER") macdef GL_VERSION = $extval (GLenum, "GL_VERSION") macdef GL_EXTENSIONS = $extval (GLenum, "GL_EXTENSIONS") // Errors macdef GL_NO_ERROR = $extval (GLenum, "GL_NO_ERROR") macdef GL_INVALID_ENUM = $extval (GLenum, "GL_INVALID_ENUM") macdef GL_INVALID_VALUE = $extval (GLenum, "GL_INVALID_VALUE") macdef GL_INVALID_OPERATION = $extval (GLenum, "GL_INVALID_OPERATION") macdef GL_STACK_OVERFLOW = $extval (GLenum, "GL_STACK_OVERFLOW") macdef GL_STACK_UNDERFLOW = $extval (GLenum, "GL_STACK_UNDERFLOW") macdef GL_OUT_OF_MEMORY = $extval (GLenum, "GL_OUT_OF_MEMORY") // glPush/PopAttrib bits macdef GL_CURRENT_BIT = $extval (GLbitfield, "GL_CURRENT_BIT") macdef GL_POINT_BIT = $extval (GLbitfield, "GL_POINT_BIT") macdef GL_LINE_BIT = $extval (GLbitfield, "GL_LINE_BIT") macdef GL_POLYGON_BIT = $extval (GLbitfield, "GL_POLYGON_BIT") macdef GL_POLYGON_STIPPLE_BIT = $extval (GLbitfield, "GL_POLYGON_STIPPLE_BIT") macdef GL_PIXEL_MODE_BIT = $extval (GLbitfield, "GL_PIXEL_MODE_BIT") macdef GL_LIGHTING_BIT = $extval (GLbitfield, "GL_LIGHTING_BIT") macdef GL_FOG_BIT = $extval (GLbitfield, "GL_FOG_BIT") macdef GL_DEPTH_BUFFER_BIT = $extval (GLbitfield, "GL_DEPTH_BUFFER_BIT") macdef GL_ACCUM_BUFFER_BIT = $extval (GLbitfield, "GL_ACCUM_BUFFER_BIT") macdef GL_STENCIL_BUFFER_BIT = $extval (GLbitfield, "GL_STENCIL_BUFFER_BIT") macdef GL_VIEWPORT_BIT = $extval (GLbitfield, "GL_VIEWPORT_BIT") macdef GL_TRANSFORM_BIT = $extval (GLbitfield, "GL_TRANSFORM_BIT") macdef GL_ENABLE_BIT = $extval (GLbitfield, "GL_ENABLE_BIT") macdef GL_COLOR_BUFFER_BIT = $extval (GLbitfield, "GL_COLOR_BUFFER_BIT") macdef GL_HINT_BIT = $extval (GLbitfield, "GL_HINT_BIT") macdef GL_EVAL_BIT = $extval (GLbitfield, "GL_EVAL_BIT") macdef GL_LIST_BIT = $extval (GLbitfield, "GL_LIST_BIT") macdef GL_TEXTURE_BIT = $extval (GLbitfield, "GL_TEXTURE_BIT") macdef GL_SCISSOR_BIT = $extval (GLbitfield, "GL_SCISSOR_BIT") macdef GL_ALL_ATTRIB_BITS = $extval (GLbitfield, "GL_ALL_ATTRIB_BITS") // OpenGL 1.1 macdef GL_PROXY_TEXTURE_1D = $extval (GLenum, "GL_PROXY_TEXTURE_1D") macdef GL_PROXY_TEXTURE_2D = $extval (GLenum, "GL_PROXY_TEXTURE_2D") macdef GL_TEXTURE_PRIORITY = $extval (GLenum, "GL_TEXTURE_PRIORITY") macdef GL_TEXTURE_RESIDENT = $extval (GLenum, "GL_TEXTURE_RESIDENT") macdef GL_TEXTURE_BINDING_1D = $extval (GLenum, "GL_TEXTURE_BINDING_1D") macdef GL_TEXTURE_BINDING_2D = $extval (GLenum, "GL_TEXTURE_BINDING_2D") macdef GL_TEXTURE_INTERNAL_FORMAT = $extval (GLenum, "GL_TEXTURE_INTERNAL_FORMAT") macdef GL_ALPHA4 = $extval (GLenum, "GL_ALPHA4") macdef GL_ALPHA8 = $extval (GLenum, "GL_ALPHA8") macdef GL_ALPHA12 = $extval (GLenum, "GL_ALPHA12") macdef GL_ALPHA16 = $extval (GLenum, "GL_ALPHA16") macdef GL_LUMINANCE4 = $extval (GLenum, "GL_LUMINANCE4") macdef GL_LUMINANCE8 = $extval (GLenum, "GL_LUMINANCE8") macdef GL_LUMINANCE12 = $extval (GLenum, "GL_LUMINANCE12") macdef GL_LUMINANCE16 = $extval (GLenum, "GL_LUMINANCE16") macdef GL_LUMINANCE4_ALPHA4 = $extval (GLenum, "GL_LUMINANCE4_ALPHA4") macdef GL_LUMINANCE6_ALPHA2 = $extval (GLenum, "GL_LUMINANCE6_ALPHA2") macdef GL_LUMINANCE8_ALPHA8 = $extval (GLenum, "GL_LUMINANCE8_ALPHA8") macdef GL_LUMINANCE12_ALPHA4 = $extval (GLenum, "GL_LUMINANCE12_ALPHA4") macdef GL_LUMINANCE12_ALPHA12 = $extval (GLenum, "GL_LUMINANCE12_ALPHA12") macdef GL_LUMINANCE16_ALPHA16 = $extval (GLenum, "GL_LUMINANCE16_ALPHA16") macdef GL_INTENSITY = $extval (GLenum, "GL_INTENSITY") macdef GL_INTENSITY4 = $extval (GLenum, "GL_INTENSITY4") macdef GL_INTENSITY8 = $extval (GLenum, "GL_INTENSITY8") macdef GL_INTENSITY12 = $extval (GLenum, "GL_INTENSITY12") macdef GL_INTENSITY16 = $extval (GLenum, "GL_INTENSITY16") macdef GL_R3_G3_B2 = $extval (GLenum, "GL_R3_G3_B2") macdef GL_RGB4 = $extval (GLenum, "GL_RGB4") macdef GL_RGB5 = $extval (GLenum, "GL_RGB5") macdef GL_RGB8 = $extval (GLenum, "GL_RGB8") macdef GL_RGB10 = $extval (GLenum, "GL_RGB10") macdef GL_RGB12 = $extval (GLenum, "GL_RGB12") macdef GL_RGB16 = $extval (GLenum, "GL_RGB16") macdef GL_RGBA2 = $extval (GLenum, "GL_RGBA2") macdef GL_RGBA4 = $extval (GLenum, "GL_RGBA4") macdef GL_RGB5_A1 = $extval (GLenum, "GL_RGB5_A1") macdef GL_RGBA8 = $extval (GLenum, "GL_RGBA8") macdef GL_RGB10_A2 = $extval (GLenum, "GL_RGB10_A2") macdef GL_RGBA12 = $extval (GLenum, "GL_RGBA12") macdef GL_RGBA16 = $extval (GLenum, "GL_RGBA16") macdef GL_CLIENT_PIXEL_STORE_BIT = $extval (GLenum, "GL_CLIENT_PIXEL_STORE_BIT") macdef GL_CLIENT_VERTEX_ARRAY_BIT = $extval (GLenum, "GL_CLIENT_VERTEX_ARRAY_BIT") macdef GL_ALL_CLIENT_ATTRIB_BITS = $extval (GLenum, "GL_ALL_CLIENT_ATTRIB_BITS") macdef GL_CLIENT_ALL_ATTRIB_BITS = $extval (GLenum, "GL_CLIENT_ALL_ATTRIB_BITS") (* ****** ****** *) // // Miscellaneous // (* ****** ****** *) fun glClearIndex (c: GLfloat): void = "mac#atsctrb_glClearIndex" // end of [glClearIndex] // typedef glClearColor_type (a:t@ype) = (a(*red*), a(*green*), a(*blue*), a(*alpha*)) - void // end of [glClearColor_type] symintr glClearColor fun glClearColor_double : glClearColor_type (double) = "mac#atsctrb_glClearColor" overload glClearColor with glClearColor_double fun glClearColor_GLclampf : glClearColor_type (GLclampf) = "mac#atsctrb_glClearColor" overload glClearColor with glClearColor_GLclampf // fun glClear (mask: GLbitfield): void = "mac#atsctrb_glClear" fun glIndexMask (mask: GLuint): void = "mac#atsctrb_glIndexMask" fun glColorMask ( red: GLboolean, green: GLboolean, blue: GLboolean, alpha: GLboolean ) : void = "mac#atsctrb_glColorMask" fun glAlphaFunc (func: GLenum, ref: GLclampf): void = "mac#atsctrb_glAlphaFunc" fun glBlendFunc (sfactor: GLenum, dfactor: GLenum): void = "mac#atsctrb_glBlendFunc" fun glLogicOp (opcode: GLenum): void = "mac#atsctrb_glLogicOp" (* ****** ****** *) fun glCullFace (mode: GLenum): void = "mac#atsctrb_glCullFace" fun glFrontFace (mode: GLenum): void = "mac#atsctrb_glFrontFace" (* ****** ****** *) symintr glPointSize fun glPointSize_double (size: double): void = "mac#atsctrb_glPointSize" overload glPointSize with glPointSize_double fun glPointSize_GLfloat (size: GLfloat): void = "mac#atsctrb_glPointSize" overload glPointSize with glPointSize_GLfloat (* ****** ****** *) symintr glLineWidth fun glLineWidth_double (width: double): void = "mac#atsctrb_glLineWidth" overload glLineWidth with glLineWidth_double fun glLineWidth_GLfloat (width: GLfloat): void = "mac#atsctrb_glLineWidth" overload glLineWidth with glLineWidth_GLfloat (* ****** ****** *) typedef glLineStipple_type (a:t@ype) = {n:int | 1 <= n; n <= 256} (int n(*factor*), a(*pattern*)) - void fun glLineStipple : glLineStipple_type (GLushort) = "mac#atsctrb_glLineStipple" // end of [glLineStipple] (* ****** ****** *) fun glPolygonMode (face: GLenum, mode: GLenum): void = "mac#atsctrb_glPolygonMode" fun glPolygonOffset (factor: GLfloat, units: GLfloat): void = "mac#atsctrb_glPolygonOffset" fun glPolygonStipple (mask: &GLarray2 (GLubyte, 32, 32)): void = "mac#atsctrb_glPolygonStipple" fun glGetPolygonStipple (mask: &GLarray2 (GLubyte, 32, 32)): void = "mac#atsctrb_glGetPolygonStipple" fun glEdgeFlag (flag: GLboolean): void = "mac#atsctrb_glEdgeFlag" fun glEdgeFlagv (flag: &GLboolean): void = "mac#atsctrb_glEdgeFlagv" fun glScissor (x: GLint, y: GLint, width: GLsizei, height: GLsizei): void = "mac#atsctrb_glScissor" (* ****** ****** *) fun glClipPlane (plane: GLenum, eqn: &(@[GLdouble][4])): void = "mac#atsctrb_glClipPlane" fun glGetClipPlane (plane: GLenum, eqn: &(@[GLdouble][4]) >> @[GLdouble][4]): void = "mac#atsctrb_glGetClipPlane" (* ****** ****** *) fun glDrawBuffer (mode: GLenum): void = "mac#atsctrb_glDrawBuffer" fun glReadBuffer (mode: GLenum): void = "mac#atsctrb_glReadBuffer" (* ****** ****** *) fun glEnable (cap: GLenum): void = "mac#atsctrb_glEnable" fun glDisable (cap: GLenum): void = "mac#atsctrb_glDisable" fun glIsEnabled (cap: GLenum): GLboolean = "mac#atsctrb_glIsEnabled" // (* // OpenGL 1.1 fun glEnableClientState (cap: GLenum): void = "mac#atsctrb_glEnableClientState" // end of [glEnableClientState] // version 1.1 fun glDisableClientState (cap: GLenum): void = "mac#atsctrb_glDisableClientState" // end of [glDisableClientState] *) (* ****** ****** *) // // these are really unsafe functions!!! // typedef glGetParams_type (a:t@ype, n:int) = (GLenum, &(@[a?][n]) >> @[a][n]) - void // end of [glGetParams] fun glGetBooleanv : {n:nat} glGetParams_type (GLboolean, n) = "mac#atsctrb_glGetBooleanv" fun glGetDoublev : {n:nat} glGetParams_type (GLdouble, n) = "mac#atsctrb_glGetDoublev" fun glGetFloatv : {n:nat} glGetParams_type (GLfloat, n) = "mac#atsctrb_glGetFloatv" fun glGetIntegerv : {n:nat} glGetParams_type (GLint, n) = "mac#atsctrb_glGetIntegerv" (* ****** ****** *) absview glPushAttrib_v fun glPushAttrib (mask: GLbitfield): (glPushAttrib_v | void) = "mac#atsctrb_glPushAttrib" // end of [glPushAttrib] fun glPopAttrib (pf: glPushAttrib_v | (*none*)): void = "mac#atsctrb_glPopAttrib" (* // OpenGL 1.1 fun glPushClientAttrib (mask: GLbitfield): void = "mac#atsctrb_glPushClientAttrib" fun glPopClientAttrib (): void = "mac#atsctrb_glPopClientAttrib" *) (* ****** ****** *) fun glRenderMode (mode: GLenum): GLint = "mac#atsctrb_glRenderMode" fun glGetError (): GLenum = "mac#atsctrb_glGetError" fun glGetString (name: GLenum): string = "mac#atsctrb_glGetString" fun glFinish (): void = "mac#atsctrb_glFinish" fun glFlush (): void = "mac#atsctrb_glFlush" fun glHint (target: GLenum, mode: GLenum): void = "mac#atsctrb_glHint" (* ****** ****** *) // Depth Buffer fun glClearDepth (depth: GLclampd): void = "mac#atsctrb_glClearDepth" // end of [glClearDepth] fun glDepthFunc (func: GLenum): void = "mac#atsctrb_glDepthFunc" fun glDepthMask (flag: GLboolean): void = "mac#atsctrb_glDepthMask" fun glDepthRange ( near_val: GLclampd, far_val: GLclampd ) : void = "mac#atsctrb_glDepthRange" // end of [glDepthRange] (* ****** ****** *) // Accumulation Buffer fun glClearAccum ( red: GLfloat, green: GLfloat, blue: GLfloat, alpha: GLfloat ) : void = "mac#atsctrb_glClearAccum" fun glAccum (opr: GLenum, value: GLfloat): void = "mac#atsctrb_glAccum" // end of [glAccum] (* ****** ****** *) // // Transformation // fun glMatrixMode (mode: GLenum): void = "mac#atsctrb_glMatrixMode" (* ****** ****** *) typedef glOrtho_type (a:t@ype) = ( a (*lft*), a (*rgt*), a (*bot*), a (*top*), a (*near_val*), a (*far_val*) ) - void // end of [glOrtho_type] symintr glOrtho fun glOrtho_double : glOrtho_type (double) = "mac#atsctrb_glOrtho" overload glOrtho with glOrtho_double fun glOrtho_GLdouble : glOrtho_type (GLdouble) = "mac#atsctrb_glOrtho" overload glOrtho with glOrtho_GLdouble (* ****** ****** *) typedef glFrustum_type (a:t@ype) = ( a (*lft*), a (*rgh*), a (*bot*), a (*top*), a (*near_val*), a (*far_val*) ) - void // end of [glFrustum_type] symintr glFrustum fun glFrustum_double : glFrustum_type (double) = "mac#atsctrb_glFrustum" overload glFrustum with glFrustum_double fun glFrustum_GLdouble : glFrustum_type (GLdouble) = "mac#atsctrb_glFrustum" overload glFrustum with glFrustum_GLdouble (* ****** ****** *) symintr glViewport fun glViewport_type (x: int, y: int, width: int, height: int): void = "mac#atsctrb_glViewport" overload glViewport with glViewport_type fun glViewport_GLtype (x: GLint, y: GLint, width: GLsizei, height: GLsizei): void = "mac#atsctrb_glViewport" overload glViewport with glViewport_GLtype (* ****** ****** *) absview glPushMatrix_v fun glPushMatrix (): (glPushMatrix_v | void) = "mac#atsctrb_glPushMatrix" fun glPopMatrix (pf: glPushMatrix_v | (*none*)): void = "mac#atsctrb_glPopMatrix" (* ****** ****** *) fun glLoadIdentity (): void = "mac#atsctrb_glLoadIdentity" (* ****** ****** *) typedef glLoadMatrix_type (a:t@ype) = (&(@[a][16])) - void fun glLoadMatrixd : glLoadMatrix_type (GLdouble) = "mac#atsctrb_glLoadMatrixd" fun glLoadMatrixf : glLoadMatrix_type (GLfloat) = "mac#atsctrb_glLoadMatrixf" (* ****** ****** *) typedef glMultMatrix_type (a:t@ype) = (&(@[a][16])) - void fun glMultMatrixd : glMultMatrix_type (GLdouble) = "mac#atsctrb_glMultMatrixd" fun glMultMatrixf : glMultMatrix_type (GLfloat) = "mac#atsctrb_glMultMatrixf" (* ****** ****** *) typedef glRotate_type (a:t@ype) = (a(*angle*), a(*x*), a(*y*), a(*z*)) - void symintr glRotated fun glRotated_double : glRotate_type (double) = "mac#atsctrb_glRotated" overload glRotated with glRotated_double fun glRotated_GLdouble : glRotate_type (GLdouble) = "mac#atsctrb_glRotated" overload glRotated with glRotated_GLdouble fun glRotatef : glRotate_type (GLfloat) = "mac#atsctrb_glRotatef" (* ****** ****** *) typedef glScale_type (a:t@ype) = (a(*x*), a(*y*), a(*z*)) - void symintr glScaled fun glScaled_double : glScale_type (double) = "mac#atsctrb_glScaled" overload glScaled with glScaled_double fun glScaled_GLdouble : glScale_type (GLdouble) = "mac#atsctrb_glScaled" overload glScaled with glScaled_GLdouble fun glScalef : glScale_type (GLfloat) = "mac#atsctrb_glScalef" (* ****** ****** *) typedef glTranslate_type (a:t@ype) = (a(*x*), a(*y*), a(*z*)) - void symintr glTranslated fun glTranslated_double : glTranslate_type (double) = "mac#atsctrb_glTranslated" overload glTranslated with glTranslated_double fun glTranslated_GLdouble : glTranslate_type (GLdouble) = "mac#atsctrb_glTranslated" overload glTranslated with glTranslated_GLdouble fun glTranslatef : glTranslate_type (GLfloat) = "mac#atsctrb_glTranslatef" // end of [glTranslatef] (* ****** ****** *) // // Display Lists // // // GLnewlist_v(n) indicates that [n] is a unique name // absview GLnewlist_v (n:int) prfun GLnewlst_v_elim_null (pf: GLnewlist_v 0): void absview GLlist_v (n:int) // a display list of the name [n] exists absviewt@ype GLlist (n:int) = GLuint castfn GLlist_encode {n:int} (pf: GLlist_v n | n: GLuint n):<> GLlist n castfn GLlist_decode {n:int} (lst: GLlist n):<> @(GLlist_v n | GLuint n) // // HX-2010-06-15: // if glIsList(lst) returns true, then we can expect a split as follows: // (GLlist_v (n) - void, GLlist_v (n)) // fun glIsList {n:nat} (lst: GLuint n): GLboolean = "mac#atsctrb_glIsList" fun glDeleteList {n:int} (lst: GLlist n): void = "atsctrb_glDeleteList" // function! (* // HX: this one is difficult to handle fun glDeleteLists (lst: GLuint, range: GLsizei): void = "atsctrb_glDeleteLists" *) fun glGenList () : [n:nat] @(GLnewlist_v n | GLuint n) = "atsctrb_glGenList" // function! // end of [glGenList] fun glGenList_exn () : [n:pos] @(GLnewlist_v n | GLuint n) = "atsctrb_glGenList_exn" // function! // end of [glGenList_exn] (* // HX: this one is difficult to handle fun glGenLists (range: GLsizei): GLuint = "atsctrb_glGenLists" *) absview glNewList_v symintr glNewList fun glNewList_new {n:pos} ( pf: GLnewlist_v n | lst: GLuint n, mode: GLenum ) : @(glNewList_v | GLlist n) = "atsctrb_glNewList_new" overload glNewList with glNewList_new fun glNewList_clear {n:int} (lst: !GLlist n, mode: GLenum): @(glNewList_v | void) = "atsctrb_glNewList_clear" overload glNewList with glNewList_clear fun glEndList (pf: glNewList_v | (*none*)): void = "mac#atsctrb_glEndList" fun glCallList {n:int} (lst: !GLlist n): void = "mac#atsctrb_glCallList" fun glListBase (base: GLuint): void = "mac#atsctrb_glListBase" (* // HX: this one is difficult to handle fun glCallLists (n: GLsizei, typ: GLenum, lst: GLvoid* ): void *) (* ****** ****** *) /* ** Drawing Functions */ absview glBegin_v fun glBegin (mode: GLenum): @(glBegin_v | void) = "mac#atsctrb_glBegin" fun glEnd (pf: glBegin_v | (*none*)): void = "mac#atsctrb_glEnd" (* ****** ****** *) typedef glVertex2_type (a:t@ype) = (a(*x*), a(*y*)) - void // end of [glVertex2_type] // symintr glVertex2d fun glVertex2d_double : glVertex2_type (double) = "mac#atsctrb_glVertex2d" overload glVertex2d with glVertex2d_double fun glVertex2d_GLdouble : glVertex2_type (GLdouble) = "mac#atsctrb_glVertex2d" overload glVertex2d with glVertex2d_GLdouble fun glVertex2f : glVertex2_type (GLfloat) = "mac#atsctrb_glVertex2f" fun glVertex2i : glVertex2_type (GLint) = "mac#atsctrb_glVertex2i" fun glVertex2s : glVertex2_type (GLshort) = "mac#atsctrb_glVertex2s" typedef glVertex2v (a:t@ype) = (&(@[a][2])) - void fun glVertex2dv : glVertex2v (GLdouble) = "mac#atsctrb_glVertex2dv" fun glVertex2fv : glVertex2v (GLfloat) = "mac#atsctrb_glVertex2fv" fun glVertex2iv : glVertex2v (GLint) = "mac#atsctrb_glVertex2iv" fun glVertex2sv : glVertex2v (GLshort) = "mac#atsctrb_glVertex2sv" (* ****** ****** *) typedef glVertex3_type (a:t@ype) = (a(*x*), a(*y*), a(*z*)) - void // end of [glVertex3_type] symintr glVertex3d fun glVertex3d_double : glVertex3_type (double) = "mac#atsctrb_glVertex3d" overload glVertex3d with glVertex3d_double fun glVertex3d_GLdouble : glVertex3_type (GLdouble) = "mac#atsctrb_glVertex3d" overload glVertex3d with glVertex3d_GLdouble fun glVertex3f : glVertex3_type (GLfloat) = "mac#atsctrb_glVertex3f" fun glVertex3i : glVertex3_type (GLint) = "mac#atsctrb_glVertex3i" fun glVertex3s : glVertex3_type (GLshort) = "mac#atsctrb_glVertex3s" typedef glVertex3v (a:t@ype) = (&(@[a][3])) - void fun glVertex3dv : glVertex3v (GLdouble) = "mac#atsctrb_glVertex3dv" fun glVertex3fv : glVertex3v (GLfloat) = "mac#atsctrb_glVertex3fv" fun glVertex3iv : glVertex3v (GLint) = "mac#atsctrb_glVertex3iv" fun glVertex3sv : glVertex3v (GLshort) = "mac#atsctrb_glVertex3sv" (* ****** ****** *) typedef glVertex4_type (a:t@ype) = (a(*x*), a(*y*), a(*z*), a(*w*)) - void symintr glVertex4d fun glVertex4d_double : glVertex4_type (double) = "mac#atsctrb_glVertex4d" overload glVertex4d with glVertex4d_double fun glVertex4d_GLdouble : glVertex4_type (GLdouble) = "mac#atsctrb_glVertex4d" overload glVertex4d with glVertex4d_GLdouble fun glVertex4f : glVertex4_type (GLfloat) = "mac#atsctrb_glVertex4f" fun glVertex4i : glVertex4_type (GLint) = "mac#atsctrb_glVertex4i" fun glVertex4s : glVertex4_type (GLshort) = "mac#atsctrb_glVertex4s" typedef glVertex4v (a:t@ype) = (&(@[a][4])) - void fun glVertex4dv : glVertex4v (GLdouble) = "mac#atsctrb_glVertex4dv" fun glVertex4fv : glVertex4v (GLfloat) = "mac#atsctrb_glVertex4fv" fun glVertex4iv : glVertex4v (GLint) = "mac#atsctrb_glVertex4iv" fun glVertex4sv : glVertex4v (GLshort) = "mac#atsctrb_glVertex4sv" (* ****** ****** *) typedef glNormal3_type (a:t@ype) = (a(*nx*), a(*ny*), a(*nz*)) - void fun glNormal3b : glNormal3_type (GLbyte) = "mac#atsctrb_glNormal3b" fun glNormal3d : glNormal3_type (GLdouble) = "mac#atsctrb_glNormal3d" fun glNormal3f : glNormal3_type (GLfloat) = "mac#atsctrb_glNormal3f" fun glNormal3i : glNormal3_type (GLint) = "mac#atsctrb_glNormal3i" fun glNormal3s : glNormal3_type (GLshort) = "mac#atsctrb_glNormal3s" typedef glNormal3v_type (a:t@ype) = (&(@[a][3])) - void fun glNormal3bv : glNormal3v_type (GLbyte) = "mac#atsctrb_glNormal3bv" fun glNormal3dv : glNormal3v_type (GLdouble) = "mac#atsctrb_glNormal3dv" fun glNormal3fv : glNormal3v_type (GLfloat) = "mac#atsctrb_glNormal3fv" fun glNormal3iv : glNormal3v_type (GLint) = "mac#atsctrb_glNormal3iv" fun glNormal3sv : glNormal3v_type (GLshort) = "mac#atsctrb_glNormal3sv" (* ****** ****** *) fun glIndexd (c: GLdouble): void = "mac#atsctrb_glIndexd" fun glIndexf (c: GLfloat): void = "mac#atsctrb_glIndexf" fun glIndexi (c: GLint): void = "mac#atsctrb_glIndexi" fun glIndexs (c: GLshort): void = "mac#atsctrb_glIndexs" fun glIndexub (c: GLubyte): void = "mac#atsctrb_glIndexub" // OpenGL 1.1 (* GLAPI void GLAPIENTRY glIndexdv( const GLdouble *c ); GLAPI void GLAPIENTRY glIndexfv( const GLfloat *c ); GLAPI void GLAPIENTRY glIndexiv( const GLint *c ); GLAPI void GLAPIENTRY glIndexsv( const GLshort *c ); GLAPI void GLAPIENTRY glIndexubv( const GLubyte *c ); /* 1.1 */ *) (* ****** ****** *) typedef glColor3_type (a:t@ype) = (a(*red*), a(*green*), a(*blue*)) - void // end of [glColor3_type] fun glColor3b : glColor3_type (GLbyte) = "mac#atsctrb_glColor3b" // symintr glColor3d fun glColor3d_double : glColor3_type (double) = "mac#atsctrb_glColor3d" overload glColor3d with glColor3d_double fun glColor3d_GLdouble : glColor3_type (GLdouble) = "mac#atsctrb_glColor3d" overload glColor3d with glColor3d_GLdouble // fun glColor3f : glColor3_type (GLfloat) = "mac#atsctrb_glColor3f" fun glColor3i : glColor3_type (GLint) = "mac#atsctrb_glColor3i" fun glColor3s : glColor3_type (GLshort) = "mac#atsctrb_glColor3s" fun glColor3ub : glColor3_type (GLubyte) = "mac#atsctrb_glColor3ub" fun glColor3ui : glColor3_type (GLuint) = "mac#atsctrb_glColor3ui" fun glColor3us : glColor3_type (GLushort) = "mac#atsctrb_glColor3us" typedef glColor3v_type (a:t@ype) = (&(@[a][3])) - void fun glColor3bv : glColor3v_type (GLbyte) = "mac#atsctrb_glColor3bv" fun glColor3dv : glColor3v_type (GLdouble) = "mac#atsctrb_glColor3dv" fun glColor3fv : glColor3v_type (GLfloat) = "mac#atsctrb_glColor3fv" fun glColor3iv : glColor3v_type (GLint) = "mac#atsctrb_glColor3iv" fun glColor3iv : glColor3v_type (GLshort) = "mac#atsctrb_glColor3sv" fun glColor3ubv : glColor3v_type (GLubyte) = "mac#atsctrb_glColor3ubv" fun glColor3uiv : glColor3v_type (GLuint) = "mac#atsctrb_glColor3uiv" fun glColor3uiv : glColor3v_type (GLushort) = "mac#atsctrb_glColor3usv" (* ****** ****** *) typedef glColor4_type (a:t@ype) = (a(*red*), a(*green*), a(*blue*), a(*alpha*)) - void // end of [glColor4_type] // fun glColor4b : glColor4_type (GLbyte) = "mac#atsctrb_glColor4b" // symintr glColor4d fun glColor4d_double : glColor4_type (double) = "mac#atsctrb_glColor4d" overload glColor4d with glColor4d_double fun glColor4d_GLdouble : glColor4_type (GLdouble) = "mac#atsctrb_glColor4d" overload glColor4d with glColor4d_GLdouble // fun glColor4f : glColor4_type (GLfloat) = "mac#atsctrb_glColor4f" fun glColor4i : glColor4_type (GLint) = "mac#atsctrb_glColor4i" fun glColor4s : glColor4_type (GLshort) = "mac#atsctrb_glColor4s" fun glColor4ub : glColor4_type (GLubyte) = "mac#atsctrb_glColor4ub" fun glColor4ui : glColor4_type (GLuint) = "mac#atsctrb_glColor4ui" fun glColor4us : glColor4_type (GLushort) = "mac#atsctrb_glColor4us" (* ****** ****** *) typedef glColor4v_type (a:t@ype) = (&(@[a][4])) - void fun glColor4bv : glColor4v_type (GLbyte) = "mac#atsctrb_glColor4bv" fun glColor4dv : glColor4v_type (GLdouble) = "mac#atsctrb_glColor4dv" fun glColor4fv : glColor4v_type (GLfloat) = "mac#atsctrb_glColor4fv" fun glColor4iv : glColor4v_type (GLint) = "mac#atsctrb_glColor4iv" fun glColor4iv : glColor4v_type (GLshort) = "mac#atsctrb_glColor4sv" fun glColor4ubv : glColor4v_type (GLubyte) = "mac#atsctrb_glColor4ubv" fun glColor4uiv : glColor4v_type (GLuint) = "mac#atsctrb_glColor4uiv" fun glColor4uiv : glColor4v_type (GLushort) = "mac#atsctrb_glColor4usv" (* ****** ****** *) typedef glTexCoord1_type (a:t@ype) = (a(*s*)) - void // symintr glTexCoord1d fun glTexCoord1d_double : glTexCoord1_type (double) = "mac#atsctrb_glTexCoord1d" overload glTexCoord1d with glTexCoord1d_double fun glTexCoord1d_GLdouble : glTexCoord1_type (GLdouble) = "mac#atsctrb_glTexCoord1d" overload glTexCoord1d with glTexCoord1d_GLdouble // fun glTexCoord1f : glTexCoord1_type (GLfloat) = "mac#atsctrb_glTexCoord1f" fun glTexCoord1i : glTexCoord1_type (GLint) = "mac#atsctrb_glTexCoord1i" fun glTexCoord1s : glTexCoord1_type (GLshort) = "mac#atsctrb_glTexCoord1s" (* ****** ****** *) typedef glTexCoord2_type (a:t@ype) = (a(*s*), a(*t*)) - void // end of [glTexCoord2_type] // symintr glTexCoord2d fun glTexCoord2d_double : glTexCoord2_type (double) = "mac#atsctrb_glTexCoord2d" overload glTexCoord2d with glTexCoord2d_double fun glTexCoord2d_GLdouble : glTexCoord2_type (GLdouble) = "mac#atsctrb_glTexCoord2d" overload glTexCoord2d with glTexCoord2d_GLdouble // fun glTexCoord2f : glTexCoord2_type (GLfloat) = "mac#atsctrb_glTexCoord2f" fun glTexCoord2i : glTexCoord2_type (GLint) = "mac#atsctrb_glTexCoord2i" fun glTexCoord2s : glTexCoord2_type (GLshort) = "mac#atsctrb_glTexCoord2s" (* ****** ****** *) typedef glTexCoord3_type (a:t@ype) = (a(*s*), a(*t*), a(*r*)) - void // end of [glTexCoord3_type] // symintr glTexCoord3d fun glTexCoord3d_double : glTexCoord3_type (double) = "mac#atsctrb_glTexCoord3d" overload glTexCoord3d with glTexCoord3d_double fun glTexCoord3d_GLdouble : glTexCoord3_type (GLdouble) = "mac#atsctrb_glTexCoord3d" overload glTexCoord3d with glTexCoord3d_GLdouble // fun glTexCoord3f : glTexCoord3_type (GLfloat) = "mac#atsctrb_glTexCoord3f" fun glTexCoord3i : glTexCoord3_type (GLint) = "mac#atsctrb_glTexCoord3i" fun glTexCoord3s : glTexCoord3_type (GLshort) = "mac#atsctrb_glTexCoord3s" (* ****** ****** *) typedef glTexCoord4_type (a:t@ype) = (a(*s*), a(*t*), a(*r*), a(*q*)) - void // end of [glTexCoord4_type] fun glTexCoord4d : glTexCoord4_type (GLdouble) = "mac#atsctrb_glTexCoord4d" fun glTexCoord4f : glTexCoord4_type (GLfloat) = "mac#atsctrb_glTexCoord4f" fun glTexCoord4i : glTexCoord4_type (GLint) = "mac#atsctrb_glTexCoord4i" fun glTexCoord4s : glTexCoord4_type (GLshort) = "mac#atsctrb_glTexCoord4s" (* ****** ****** *) typedef glTexCoord1v_type (a:t@ype) = (&(@[a][1])) - void fun glTexCoord1dv : glTexCoord1v_type (GLdouble) = "mac#atsctrb_glTexCoord1dv" fun glTexCoord1fv : glTexCoord1v_type (GLfloat) = "mac#atsctrb_glTexCoord1fv" fun glTexCoord1iv : glTexCoord1v_type (GLint) = "mac#atsctrb_glTexCoord1iv" fun glTexCoord1sv : glTexCoord1v_type (GLshort) = "mac#atsctrb_glTexCoord1sv" typedef glTexCoord2v_type (a:t@ype) = (&(@[a][2])) - void fun glTexCoord2dv : glTexCoord2v_type (GLdouble) = "mac#atsctrb_glTexCoord2dv" fun glTexCoord2fv : glTexCoord2v_type (GLfloat) = "mac#atsctrb_glTexCoord2fv" fun glTexCoord2iv : glTexCoord2v_type (GLint) = "mac#atsctrb_glTexCoord2iv" fun glTexCoord2sv : glTexCoord2v_type (GLshort) = "mac#atsctrb_glTexCoord2sv" typedef glTexCoord3v_type (a:t@ype) = (&(@[a][3])) - void fun glTexCoord3dv : glTexCoord3v_type (GLdouble) = "mac#atsctrb_glTexCoord3dv" fun glTexCoord3fv : glTexCoord3v_type (GLfloat) = "mac#atsctrb_glTexCoord3fv" fun glTexCoord3iv : glTexCoord3v_type (GLint) = "mac#atsctrb_glTexCoord3iv" fun glTexCoord3sv : glTexCoord3v_type (GLshort) = "mac#atsctrb_glTexCoord3sv" typedef glTexCoord4v_type (a:t@ype) = (&(@[a][4])) - void fun glTexCoord4dv : glTexCoord4v_type (GLdouble) = "mac#atsctrb_glTexCoord4dv" fun glTexCoord4fv : glTexCoord4v_type (GLfloat) = "mac#atsctrb_glTexCoord4fv" fun glTexCoord4iv : glTexCoord4v_type (GLint) = "mac#atsctrb_glTexCoord4iv" fun glTexCoord4sv : glTexCoord4v_type (GLshort) = "mac#atsctrb_glTexCoord4sv" (* ****** ****** *) typedef glRasterPos2_type (a:t@ype) = (a(*x*), a(*y*)) - void // end of [glRasterPos2_type] symintr glRasterPos2d fun glRasterPos2d_double : glRasterPos2_type (double) = "mac#atsctrb_glRasterPos2d" overload glRasterPos2d with glRasterPos2d_double fun glRasterPos2d_GLdouble : glRasterPos2_type (GLdouble) = "mac#atsctrb_glRasterPos2d" overload glRasterPos2d with glRasterPos2d_GLdouble fun glRasterPos2f : glRasterPos2_type (GLfloat) = "mac#atsctrb_glRasterPos2f" fun glRasterPos2i : glRasterPos2_type (GLint) = "mac#atsctrb_glRasterPos2i" fun glRasterPos2s : glRasterPos2_type (GLshort) = "mac#atsctrb_glRasterPos2s" (* ****** ****** *) typedef glRasterPos3_type (a:t@ype) = (a(*x*), a(*y*), a(*z*)) - void // end of [glRasterPos3_type] fun glRasterPos3d : glRasterPos3_type (GLdouble) = "mac#atsctrb_glRasterPos3d" fun glRasterPos3f : glRasterPos3_type (GLfloat) = "mac#atsctrb_glRasterPos3f" fun glRasterPos3i : glRasterPos3_type (GLint) = "mac#atsctrb_glRasterPos3i" fun glRasterPos3s : glRasterPos3_type (GLshort) = "mac#atsctrb_glRasterPos3s" (* ****** ****** *) typedef glRasterPos4_type (a:t@ype) = (a(*x*), a(*y*), a(*z*), a(*w*)) - void // end of [glRasterPos4_type] fun glRasterPos4d : glRasterPos4_type (GLdouble) = "mac#atsctrb_glRasterPos4d" fun glRasterPos4f : glRasterPos4_type (GLfloat) = "mac#atsctrb_glRasterPos4f" fun glRasterPos4i : glRasterPos4_type (GLint) = "mac#atsctrb_glRasterPos4i" fun glRasterPos4s : glRasterPos4_type (GLshort) = "mac#atsctrb_glRasterPos4s" (* ****** ****** *) typedef glRasterPos2v_type (a:t@ype) = (&(@[a][2])) - void fun glRasterPos2dv : glRasterPos2v_type (GLdouble) = "mac#atsctrb_glRasterPos2dv" fun glRasterPos2fv : glRasterPos2v_type (GLfloat) = "mac#atsctrb_glRasterPos2fv" fun glRasterPos2iv : glRasterPos2v_type (GLint) = "mac#atsctrb_glRasterPos2iv" fun glRasterPos2sv : glRasterPos2v_type (GLshort) = "mac#atsctrb_glRasterPos2sv" typedef glRasterPos3v_type (a:t@ype) = (&(@[a][3])) - void fun glRasterPos3dv : glRasterPos3v_type (GLdouble) = "mac#atsctrb_glRasterPos3dv" fun glRasterPos3fv : glRasterPos3v_type (GLfloat) = "mac#atsctrb_glRasterPos3fv" fun glRasterPos3iv : glRasterPos3v_type (GLint) = "mac#atsctrb_glRasterPos3iv" fun glRasterPos3sv : glRasterPos3v_type (GLshort) = "mac#atsctrb_glRasterPos3sv" typedef glRasterPos4v_type (a:t@ype) = (&(@[a][4])) - void fun glRasterPos4dv : glRasterPos4v_type (GLdouble) = "mac#atsctrb_glRasterPos4dv" fun glRasterPos4fv : glRasterPos4v_type (GLfloat) = "mac#atsctrb_glRasterPos4fv" fun glRasterPos4iv : glRasterPos4v_type (GLint) = "mac#atsctrb_glRasterPos4iv" fun glRasterPos4sv : glRasterPos4v_type (GLshort) = "mac#atsctrb_glRasterPos4sv" (* ****** ****** *) typedef glRect_type (a:t@ype) = (a(*x1*), a(*y1*), a(*x2*), a(*y2*)) - void // symintr glRectd fun glRectd_double : glRect_type (double) = "mac#atsctrb_glRectd" overload glRectd with glRectd_double fun glRectd_GLdouble : glRect_type (GLdouble) = "mac#atsctrb_glRectd" overload glRectd with glRectd_GLdouble // fun glRectf : glRect_type (GLfloat) = "mac#atsctrb_glRectf" fun glRecti : glRect_type (GLint) = "mac#atsctrb_glRecti" fun glRects : glRect_type (GLshort) = "mac#atsctrb_glRects" (* ****** ****** *) typedef glRectv_type (a:t@ype) = (&(@[a][2]), &(@[a][2])) - void // end of [glRectv_type] fun glRectdv : glRectv_type (GLdouble) = "mac#atsctrb_glRectdv" fun glRectfv : glRectv_type (GLfloat) = "mac#atsctrb_glRectdf" fun glRectiv : glRectv_type (GLint) = "mac#atsctrb_glRectdi" fun glRectsv : glRectv_type (GLshort) = "mac#atsctrb_glRectds" (* ****** ****** *) // // Lighting // (* ****** ****** *) fun glShadeModel (mode: GLenum): void = "mac#atsctrb_glShadeModel" // end of [glShadeModel] (* ****** ****** *) typedef glLight_type (a:t@ype) = (GLenum(*light*), GLenum(*pname*), a(*param*)) - void fun glLightf : glLight_type (GLfloat) = "mac#atsctrb_glLightf" fun glLighti : glLight_type (GLint) = "mac#atsctrb_glLighti" (* ****** ****** *) // // these are really unsafe functions!!! // typedef glLightv_type (a:t@ype, n:int) = ( GLenum(*light*), GLenum(*pname*), &(@[a][n])(*param*) ) - void // end of [glLightv_type] fun glLightfv : {n:nat} glLightv_type (GLfloat, n) = "mac#atsctrb_glLightfv" fun glLightiv : {n:nat} glLightv_type (GLint, n) = "mac#atsctrb_glLightiv" typedef glGetLightv_type (a:t@ype, n:int) = ( GLenum(*light*), GLenum(*pname*), &(@[a?][n]) >> @[a][n](*param*) ) - void // end of [glGetLightv_type] fun glGetLightfv : {n:nat} glGetLightv_type (GLfloat, n) = "mac#atsctrb_glGetLightfv" fun glGetLightiv : {n:nat} glGetLightv_type (GLint, n) = "mac#atsctrb_glGetLightiv" (* ****** ****** *) typedef glLightModel_type (a:t@ype) = (GLenum(*pname*), a(*param*)) - void // end of [glLightModel_type] fun glLightModelf : glLightModel_type (GLfloat) = "mac#atsctrb_glLightModelf" fun glLightModeli : glLightModel_type (GLint) = "mac#atsctrb_glLightModeli" (* ****** ****** *) typedef glLightModelv_type (a:t@ype, n:int) = (GLenum(*pname*), &(@[a][n])(*params*)) - void // end of [glLightModelv_type] fun glLightModelfv : {n:nat} glLightModelv_type (GLfloat, n) = "mac#atsctrb_glLightModelfv" fun glLightModeliv : {n:nat} glLightModelv_type (GLint, n) = "mac#atsctrb_glLightModeliv" (* ****** ****** *) typedef glMaterial_type (a:t@ype) = (GLenum(*face*), GLenum(*pname*), a(*param*)) - void // end of [glMaterial_type] fun glMaterialf : glMaterial_type (GLfloat)= "mac#atsctrb_glMaterialf" fun glMateriali : glMaterial_type (GLint) = "mac#atsctrb_glMateriali" (* ****** ****** *) typedef glMaterialv_type (a:t@ype, n:int) = (GLenum(*face*), GLenum(*pname*), &(@[a][n])) - void // end of [glMaterialv_type] fun glMaterialfv : {n:nat} glMaterialv_type (GLfloat, n) = "mac#atsctrb_glMaterialfv" fun glMaterialiv : {n:nat} glMaterialv_type (GLint, n) = "mac#atsctrb_glMaterialiv" (* ****** ****** *) typedef glGetMaterialv_type (a:t@ype, n:int) = ( GLenum(*face*), GLenum(*pname*), &(@[a?][n]) >> @[a][n] ) - void // end of [glGetMaterialv_type] fun glGetMaterialfv : {n:nat} glGetMaterialv_type (GLfloat, n) = "mac#atsctrb_glGetMaterialfv" fun glGetMaterialiv : {n:nat} glGetMaterialv_type (GLint, n) = "mac#atsctrb_glGetMaterialiv" (* ****** ****** *) fun glColorMaterial (face: GLenum, mode: GLenum): void = "mac#atsctrb_glColorMaterial" // end of [glColorMaterial] (* ****** ****** *) // // Raster functions // (* ****** ****** *) fun glPixelZoom (xfactor: GLfloat, yfactor: GLfloat): void = "mac#atsctrb_glPixelZoom" // end of [glPixelZoom] (* ****** ****** *) typedef glPixelStore_type (a:t@ype) = (GLenum(*pname*), a(*param*)) - void // end of [glPixelStore_type] fun glPixelStoref : glPixelStore_type (GLfloat) = "mac#atsctrb_glPixelStoref" fun glPixelStorei : glPixelStore_type (GLint) = "mac#atsctrb_glPixelStorei" (* ****** ****** *) fun glBitmap {w8:nat} {w,h:nat | w <= 8*w8} {n:nat} {p:int | p <= n} ( pf: MUL (w8, h, p) | width: GLsizei w, height: GLsizei h , xorig: GLfloat, yorig: GLfloat, xmove: GLfloat, ymove: GLfloat , bitmap: &(@[GLubyte][n]) ) : void = "mac#atsctrb_glBitmap" // end of [glBitmap] (* ****** ****** *) fun glReadPixels {a:t@ype} {w,h:nat} {n:nat} ( x: GLint, y: GLint , w: GLsizei w, h: GLsizei h , fmt: GLenum_format n , type: GLenum_type a , pixels: &GLarray3 (a, w, h, n) ) : void = "mac#atsctrb_glReadPixels" // end of [glReadPixels] fun glDrawPixels {a:t@ype} {w,h:nat} {n:nat} ( w: GLsizei w, h: GLsizei h , fmt: GLenum_format n , type: GLenum_type a , pixels: &GLarray3 (a, w, h, n) ) : void = "mac#atsctrb_glDrawPixels" // end of [glDrawPixels] fun glCopyPixels {w,h:nat} ( x: GLint, y: GLint, w: GLsizei w, h: GLsizei h, type: GLenum ) : void = "mac#atsctrb_glCopyPixels" // end of [glCopyPixels] (* ****** ****** *) // // Texture mapping // typedef glTexParameter_type (a:t@ype) = (GLenum(*target*), GLenum(*pname*), a(*param*)) - void // end of [glTexParameter_type] fun glTexParameterf : glTexParameter_type (GLfloat) = "mac#atsctrb_glTexParameterf" fun glTexParameteri : glTexParameter_type (GLint) = "mac#atsctrb_glTexParameteri" typedef glTexEnv_type (a:t@ype) = (GLenum(*target*), GLenum(*pname*), a(*param*)) - void // end of [glTexEnv] fun glTexEnvf : glTexEnv_type (GLfloat) = "mac#atsctrb_glTexEnvf" fun glTexEnvi : glTexEnv_type (GLint) = "mac#atsctrb_glTexEnvi" (* ****** ****** *) fun glTexImage1D {a:t@ype} {w:nat} {n:int} ( target: GLenum , level: GLint , interalFormat: GLint , width: GLsizei w // height = 1 , border: natLt(2) , format: GLenum_format n , type: GLenum_type (a) , texels: &GLarray2 (a, w, n) ) : void = "mac#atsctrb_glTexImage1D" // end of [fun] fun glTexImage2D {a:t@ype} {w,h:int} {n:int} ( target: GLenum , level: GLint , interalFormat: GLint , width: GLsizei w , height: GLsizei h , border: natLt(2) , format: GLenum_format n , type: GLenum_type (a) , texels: &GLarray3 (a, w, h, n) ) : void = "mac#atsctrb_glTexImage2D" // end of [fun] (* ****** ****** *) // // OpenGL 1.1 // absviewt@ype GLtexture (int) = GLuint viewtypedef GLtexture = [n:int] GLtexture (n) fun glGenTexture (texture: &GLtexture? >> GLtexture): void = "atsctrb_glGenTexture" // this is a function! // end of [glGenTexture] fun glGenTextures {n:pos} ( n: GLsizei n , textures: &(@[GLtexture?][n]) >> @[GLtexture][n] ) : void = "mac#atsctrb_glGenTextures" // end of [glGenTextures] fun glDeleteTexture (texture: GLtexture): void = "atsctrb_glDeleteTexture" // this is a function! // end of [glDeleteTexture] fun glDeleteTextures {n:pos} ( n: GLsizei n, textures: &(@[GLtexture][n]) ) : void = "mac#atsctrb_glDeleteTextures" // end of [glDeleteTextures] fun glBindTexture {i:int} ( target: GLenum, texture: !GLtexture i ) : void = "mac#atsctrb_glBindTexture" // end of [glBindTexture] (* ****** ****** *) typedef glFog_type (a:t@ype) = (GLenum(*pname*), a(*param*)) - void typedef glFogv_type (a:t@ype) = {n:nat} (GLenum(*pname*), &(@[a][n])(*params*)) - void // end of [glFogv_type] fun glFogf : glFog_type (GLfloat) = "mac#atsctrb_glFogf" fun glFogi : glFog_type (GLint) = "mac#atsctrb_glFogi" fun glFogfv : glFogv_type (GLfloat) = "mac#atsctrb_glFogfv" fun glFogiv : glFogv_type (GLint) = "mac#atsctrb_glFogiv" (* ****** ****** *) // // OpenGL 1.2 // (* ****** ****** *) macdef GL_RESCALE_NORMAL = $extval (GLenum, "GL_RESCALE_NORMAL") macdef GL_CLAMP_TO_EDGE = $extval (GLenum, "GL_CLAMP_TO_EDGE") macdef GL_MAX_ELEMENTS_VERTICES = $extval (GLenum, "GL_MAX_ELEMENTS_VERTICES") macdef GL_MAX_ELEMENTS_INDICES = $extval (GLenum, "GL_MAX_ELEMENTS_INDICES") // macdef GL_BGR = $extval (GLenum, "GL_BGR") macdef GL_BGR_format = $extval (GLenum_format 3, "GL_BGR") macdef GL_BGRA = $extval (GLenum, "GL_BGRA") macdef GL_BGRA_format = $extval (GLenum_format 4, "GL_BGRA") // macdef GL_UNSIGNED_BYTE_3_3_2 = $extval (GLenum, "GL_UNSIGNED_BYTE_3_3_2") macdef GL_UNSIGNED_BYTE_2_3_3_REV = $extval (GLenum, "GL_UNSIGNED_BYTE_2_3_3_REV") macdef GL_UNSIGNED_SHORT_5_6_5 = $extval (GLenum, "GL_UNSIGNED_SHORT_5_6_5") macdef GL_UNSIGNED_SHORT_5_6_5_REV = $extval (GLenum, "GL_UNSIGNED_SHORT_5_6_5_REV") macdef GL_UNSIGNED_SHORT_4_4_4_4 = $extval (GLenum, "GL_UNSIGNED_SHORT_4_4_4_4") macdef GL_UNSIGNED_SHORT_4_4_4_4_REV = $extval (GLenum, "GL_UNSIGNED_SHORT_4_4_4_4_REV") macdef GL_UNSIGNED_SHORT_5_5_5_1 = $extval (GLenum, "GL_UNSIGNED_SHORT_5_5_5_1") macdef GL_UNSIGNED_SHORT_1_5_5_5_REV = $extval (GLenum, "GL_UNSIGNED_SHORT_1_5_5_5_REV") macdef GL_UNSIGNED_INT_8_8_8_8 = $extval (GLenum, "GL_UNSIGNED_INT_8_8_8_8") macdef GL_UNSIGNED_INT_8_8_8_8_REV = $extval (GLenum, "GL_UNSIGNED_INT_8_8_8_8_REV") macdef GL_UNSIGNED_INT_10_10_10_2 = $extval (GLenum, "GL_UNSIGNED_INT_10_10_10_2") macdef GL_UNSIGNED_INT_2_10_10_10_REV = $extval (GLenum, "GL_UNSIGNED_INT_2_10_10_10_REV") macdef GL_LIGHT_MODEL_COLOR_CONTROL = $extval (GLenum, "GL_LIGHT_MODEL_COLOR_CONTROL") macdef GL_SINGLE_COLOR = $extval (GLenum, "GL_SINGLE_COLOR") macdef GL_SEPARATE_SPECULAR_COLOR = $extval (GLenum, "GL_SEPARATE_SPECULAR_COLOR") macdef GL_TEXTURE_MIN_LOD = $extval (GLenum, "GL_TEXTURE_MIN_LOD") macdef GL_TEXTURE_MAX_LOD = $extval (GLenum, "GL_TEXTURE_MAX_LOD") macdef GL_TEXTURE_BASE_LEVEL = $extval (GLenum, "GL_TEXTURE_BASE_LEVEL") macdef GL_TEXTURE_MAX_LEVEL = $extval (GLenum, "GL_TEXTURE_MAX_LEVEL") macdef GL_SMOOTH_POINT_SIZE_RANGE = $extval (GLenum, "GL_SMOOTH_POINT_SIZE_RANGE") macdef GL_SMOOTH_POINT_SIZE_GRANULARITY = $extval (GLenum, "GL_SMOOTH_POINT_SIZE_GRANULARITY") macdef GL_SMOOTH_LINE_WIDTH_RANGE = $extval (GLenum, "GL_SMOOTH_LINE_WIDTH_RANGE") macdef GL_SMOOTH_LINE_WIDTH_GRANULARITY = $extval (GLenum, "GL_SMOOTH_LINE_WIDTH_GRANULARITY") macdef GL_ALIASED_POINT_SIZE_RANGE = $extval (GLenum, "GL_ALIASED_POINT_SIZE_RANGE") macdef GL_ALIASED_LINE_WIDTH_RANGE = $extval (GLenum, "GL_ALIASED_LINE_WIDTH_RANGE") macdef GL_PACK_SKIP_IMAGES = $extval (GLenum, "GL_PACK_SKIP_IMAGES") macdef GL_PACK_IMAGE_HEIGHT = $extval (GLenum, "GL_PACK_IMAGE_HEIGHT") macdef GL_UNPACK_SKIP_IMAGES = $extval (GLenum, "GL_UNPACK_SKIP_IMAGES") macdef GL_UNPACK_IMAGE_HEIGHT = $extval (GLenum, "GL_UNPACK_IMAGE_HEIGHT") macdef GL_TEXTURE_3D = $extval (GLenum, "GL_TEXTURE_3D") macdef GL_PROXY_TEXTURE_3D = $extval (GLenum, "GL_PROXY_TEXTURE_3D") macdef GL_TEXTURE_DEPTH = $extval (GLenum, "GL_TEXTURE_DEPTH") macdef GL_TEXTURE_WRAP_R = $extval (GLenum, "GL_TEXTURE_WRAP_R") macdef GL_MAX_3D_TEXTURE_SIZE = $extval (GLenum, "GL_MAX_3D_TEXTURE_SIZE") macdef GL_TEXTURE_BINDING_3D = $extval (GLenum, "GL_TEXTURE_BINDING_3D") (* ****** ****** *) // GL_ARB_imaging (* ****** ****** *) macdef GL_CONSTANT_COLOR = $extval (GLenum, "GL_CONSTANT_COLOR") macdef GL_ONE_MINUS_CONSTANT_COLOR = $extval (GLenum, "GL_ONE_MINUS_CONSTANT_COLOR") macdef GL_CONSTANT_ALPHA = $extval (GLenum, "GL_CONSTANT_ALPHA") macdef GL_ONE_MINUS_CONSTANT_ALPHA = $extval (GLenum, "GL_ONE_MINUS_CONSTANT_ALPHA") macdef GL_COLOR_TABLE = $extval (GLenum, "GL_COLOR_TABLE") macdef GL_POST_CONVOLUTION_COLOR_TABLE = $extval (GLenum, "GL_POST_CONVOLUTION_COLOR_TABLE") macdef GL_POST_COLOR_MATRIX_COLOR_TABLE = $extval (GLenum, "GL_POST_COLOR_MATRIX_COLOR_TABLE") macdef GL_PROXY_COLOR_TABLE = $extval (GLenum, "GL_PROXY_COLOR_TABLE") macdef GL_PROXY_POST_CONVOLUTION_COLOR_TABLE = $extval (GLenum, "GL_PROXY_POST_CONVOLUTION_COLOR_TABLE") macdef GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE = $extval (GLenum, "GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE") macdef GL_COLOR_TABLE_SCALE = $extval (GLenum, "GL_COLOR_TABLE_SCALE") macdef GL_COLOR_TABLE_BIAS = $extval (GLenum, "GL_COLOR_TABLE_BIAS") macdef GL_COLOR_TABLE_FORMAT = $extval (GLenum, "GL_COLOR_TABLE_FORMAT") macdef GL_COLOR_TABLE_WIDTH = $extval (GLenum, "GL_COLOR_TABLE_WIDTH") macdef GL_COLOR_TABLE_RED_SIZE = $extval (GLenum, "GL_COLOR_TABLE_RED_SIZE") macdef GL_COLOR_TABLE_GREEN_SIZE = $extval (GLenum, "GL_COLOR_TABLE_GREEN_SIZE") macdef GL_COLOR_TABLE_BLUE_SIZE = $extval (GLenum, "GL_COLOR_TABLE_BLUE_SIZE") macdef GL_COLOR_TABLE_ALPHA_SIZE = $extval (GLenum, "GL_COLOR_TABLE_ALPHA_SIZE") macdef GL_COLOR_TABLE_LUMINANCE_SIZE = $extval (GLenum, "GL_COLOR_TABLE_LUMINANCE_SIZE") macdef GL_COLOR_TABLE_INTENSITY_SIZE = $extval (GLenum, "GL_COLOR_TABLE_INTENSITY_SIZE") macdef GL_CONVOLUTION_1D = $extval (GLenum, "GL_CONVOLUTION_1D") macdef GL_CONVOLUTION_2D = $extval (GLenum, "GL_CONVOLUTION_2D") macdef GL_SEPARABLE_2D = $extval (GLenum, "GL_SEPARABLE_2D") macdef GL_CONVOLUTION_BORDER_MODE = $extval (GLenum, "GL_CONVOLUTION_BORDER_MODE") macdef GL_CONVOLUTION_FILTER_SCALE = $extval (GLenum, "GL_CONVOLUTION_FILTER_SCALE") macdef GL_CONVOLUTION_FILTER_BIAS = $extval (GLenum, "GL_CONVOLUTION_FILTER_BIAS") macdef GL_REDUCE = $extval (GLenum, "GL_REDUCE") macdef GL_CONVOLUTION_FORMAT = $extval (GLenum, "GL_CONVOLUTION_FORMAT") macdef GL_CONVOLUTION_WIDTH = $extval (GLenum, "GL_CONVOLUTION_WIDTH") macdef GL_CONVOLUTION_HEIGHT = $extval (GLenum, "GL_CONVOLUTION_HEIGHT") macdef GL_MAX_CONVOLUTION_WIDTH = $extval (GLenum, "GL_MAX_CONVOLUTION_WIDTH") macdef GL_MAX_CONVOLUTION_HEIGHT = $extval (GLenum, "GL_MAX_CONVOLUTION_HEIGHT") macdef GL_POST_CONVOLUTION_RED_SCALE = $extval (GLenum, "GL_POST_CONVOLUTION_RED_SCALE") macdef GL_POST_CONVOLUTION_GREEN_SCALE = $extval (GLenum, "GL_POST_CONVOLUTION_GREEN_SCALE") macdef GL_POST_CONVOLUTION_BLUE_SCALE = $extval (GLenum, "GL_POST_CONVOLUTION_BLUE_SCALE") macdef GL_POST_CONVOLUTION_ALPHA_SCALE = $extval (GLenum, "GL_POST_CONVOLUTION_ALPHA_SCALE") macdef GL_POST_CONVOLUTION_RED_BIAS = $extval (GLenum, "GL_POST_CONVOLUTION_RED_BIAS") macdef GL_POST_CONVOLUTION_GREEN_BIAS = $extval (GLenum, "GL_POST_CONVOLUTION_GREEN_BIAS") macdef GL_POST_CONVOLUTION_BLUE_BIAS = $extval (GLenum, "GL_POST_CONVOLUTION_BLUE_BIAS") macdef GL_POST_CONVOLUTION_ALPHA_BIAS = $extval (GLenum, "GL_POST_CONVOLUTION_ALPHA_BIAS") macdef GL_CONSTANT_BORDER = $extval (GLenum, "GL_CONSTANT_BORDER") macdef GL_REPLICATE_BORDER = $extval (GLenum, "GL_REPLICATE_BORDER") macdef GL_CONVOLUTION_BORDER_COLOR = $extval (GLenum, "GL_CONVOLUTION_BORDER_COLOR") macdef GL_COLOR_MATRIX = $extval (GLenum, "GL_COLOR_MATRIX") macdef GL_COLOR_MATRIX_STACK_DEPTH = $extval (GLenum, "GL_COLOR_MATRIX_STACK_DEPTH") macdef GL_MAX_COLOR_MATRIX_STACK_DEPTH = $extval (GLenum, "GL_MAX_COLOR_MATRIX_STACK_DEPTH") macdef GL_POST_COLOR_MATRIX_RED_SCALE = $extval (GLenum, "GL_POST_COLOR_MATRIX_RED_SCALE") macdef GL_POST_COLOR_MATRIX_GREEN_SCALE = $extval (GLenum, "GL_POST_COLOR_MATRIX_GREEN_SCALE") macdef GL_POST_COLOR_MATRIX_BLUE_SCALE = $extval (GLenum, "GL_POST_COLOR_MATRIX_BLUE_SCALE") macdef GL_POST_COLOR_MATRIX_ALPHA_SCALE = $extval (GLenum, "GL_POST_COLOR_MATRIX_ALPHA_SCALE") macdef GL_POST_COLOR_MATRIX_RED_BIAS = $extval (GLenum, "GL_POST_COLOR_MATRIX_RED_BIAS") macdef GL_POST_COLOR_MATRIX_GREEN_BIAS = $extval (GLenum, "GL_POST_COLOR_MATRIX_GREEN_BIAS") macdef GL_POST_COLOR_MATRIX_BLUE_BIAS = $extval (GLenum, "GL_POST_COLOR_MATRIX_BLUE_BIAS") macdef GL_POST_COLOR_MATRIX_ALPHA_BIAS = $extval (GLenum, "GL_POST_COLOR_MATRIX_ALPHA_BIAS") macdef GL_HISTOGRAM = $extval (GLenum, "GL_HISTOGRAM") macdef GL_PROXY_HISTOGRAM = $extval (GLenum, "GL_PROXY_HISTOGRAM") macdef GL_HISTOGRAM_WIDTH = $extval (GLenum, "GL_HISTOGRAM_WIDTH") macdef GL_HISTOGRAM_FORMAT = $extval (GLenum, "GL_HISTOGRAM_FORMAT") macdef GL_HISTOGRAM_RED_SIZE = $extval (GLenum, "GL_HISTOGRAM_RED_SIZE") macdef GL_HISTOGRAM_GREEN_SIZE = $extval (GLenum, "GL_HISTOGRAM_GREEN_SIZE") macdef GL_HISTOGRAM_BLUE_SIZE = $extval (GLenum, "GL_HISTOGRAM_BLUE_SIZE") macdef GL_HISTOGRAM_ALPHA_SIZE = $extval (GLenum, "GL_HISTOGRAM_ALPHA_SIZE") macdef GL_HISTOGRAM_LUMINANCE_SIZE = $extval (GLenum, "GL_HISTOGRAM_LUMINANCE_SIZE") macdef GL_HISTOGRAM_SINK = $extval (GLenum, "GL_HISTOGRAM_SINK") macdef GL_MINMAX = $extval (GLenum, "GL_MINMAX") macdef GL_MINMAX_FORMAT = $extval (GLenum, "GL_MINMAX_FORMAT") macdef GL_MINMAX_SINK = $extval (GLenum, "GL_MINMAX_SINK") macdef GL_TABLE_TOO_LARGE = $extval (GLenum, "GL_TABLE_TOO_LARGE") macdef GL_BLEND_EQUATION = $extval (GLenum, "GL_BLEND_EQUATION") macdef GL_MIN = $extval (GLenum, "GL_MIN") macdef GL_MAX = $extval (GLenum, "GL_MAX") macdef GL_FUNC_ADD = $extval (GLenum, "GL_FUNC_ADD") macdef GL_FUNC_SUBTRACT = $extval (GLenum, "GL_FUNC_SUBTRACT") macdef GL_FUNC_REVERSE_SUBTRACT = $extval (GLenum, "GL_FUNC_REVERSE_SUBTRACT") macdef GL_BLEND_COLOR = $extval (GLenum, "GL_BLEND_COLOR") (* ****** ****** *) // OpenGL 1.3 (* ****** ****** *) // multitexture macdef GL_TEXTURE0 = $extval (GLenum, "GL_TEXTURE0") macdef GL_TEXTURE1 = $extval (GLenum, "GL_TEXTURE1") macdef GL_TEXTURE2 = $extval (GLenum, "GL_TEXTURE2") macdef GL_TEXTURE3 = $extval (GLenum, "GL_TEXTURE3") macdef GL_TEXTURE4 = $extval (GLenum, "GL_TEXTURE4") macdef GL_TEXTURE5 = $extval (GLenum, "GL_TEXTURE5") macdef GL_TEXTURE6 = $extval (GLenum, "GL_TEXTURE6") macdef GL_TEXTURE7 = $extval (GLenum, "GL_TEXTURE7") macdef GL_TEXTURE8 = $extval (GLenum, "GL_TEXTURE8") macdef GL_TEXTURE9 = $extval (GLenum, "GL_TEXTURE9") macdef GL_TEXTURE10 = $extval (GLenum, "GL_TEXTURE10") macdef GL_TEXTURE11 = $extval (GLenum, "GL_TEXTURE11") macdef GL_TEXTURE12 = $extval (GLenum, "GL_TEXTURE12") macdef GL_TEXTURE13 = $extval (GLenum, "GL_TEXTURE13") macdef GL_TEXTURE14 = $extval (GLenum, "GL_TEXTURE14") macdef GL_TEXTURE15 = $extval (GLenum, "GL_TEXTURE15") macdef GL_TEXTURE16 = $extval (GLenum, "GL_TEXTURE16") macdef GL_TEXTURE17 = $extval (GLenum, "GL_TEXTURE17") macdef GL_TEXTURE18 = $extval (GLenum, "GL_TEXTURE18") macdef GL_TEXTURE19 = $extval (GLenum, "GL_TEXTURE19") macdef GL_TEXTURE20 = $extval (GLenum, "GL_TEXTURE20") macdef GL_TEXTURE21 = $extval (GLenum, "GL_TEXTURE21") macdef GL_TEXTURE22 = $extval (GLenum, "GL_TEXTURE22") macdef GL_TEXTURE23 = $extval (GLenum, "GL_TEXTURE23") macdef GL_TEXTURE24 = $extval (GLenum, "GL_TEXTURE24") macdef GL_TEXTURE25 = $extval (GLenum, "GL_TEXTURE25") macdef GL_TEXTURE26 = $extval (GLenum, "GL_TEXTURE26") macdef GL_TEXTURE27 = $extval (GLenum, "GL_TEXTURE27") macdef GL_TEXTURE28 = $extval (GLenum, "GL_TEXTURE28") macdef GL_TEXTURE29 = $extval (GLenum, "GL_TEXTURE29") macdef GL_TEXTURE30 = $extval (GLenum, "GL_TEXTURE30") macdef GL_TEXTURE31 = $extval (GLenum, "GL_TEXTURE31") macdef GL_ACTIVE_TEXTURE = $extval (GLenum, "GL_ACTIVE_TEXTURE") macdef GL_CLIENT_ACTIVE_TEXTURE = $extval (GLenum, "GL_CLIENT_ACTIVE_TEXTURE") macdef GL_MAX_TEXTURE_UNITS = $extval (GLenum, "GL_MAX_TEXTURE_UNITS") // texture_cube_map macdef GL_NORMAL_MAP = $extval (GLenum, "GL_NORMAL_MAP") macdef GL_REFLECTION_MAP = $extval (GLenum, "GL_REFLECTION_MAP") macdef GL_TEXTURE_CUBE_MAP = $extval (GLenum, "GL_TEXTURE_CUBE_MAP") macdef GL_TEXTURE_BINDING_CUBE_MAP = $extval (GLenum, "GL_TEXTURE_BINDING_CUBE_MAP") macdef GL_TEXTURE_CUBE_MAP_POSITIVE_X = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_POSITIVE_X") macdef GL_TEXTURE_CUBE_MAP_NEGATIVE_X = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_NEGATIVE_X") macdef GL_TEXTURE_CUBE_MAP_POSITIVE_Y = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_POSITIVE_Y") macdef GL_TEXTURE_CUBE_MAP_NEGATIVE_Y = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_NEGATIVE_Y") macdef GL_TEXTURE_CUBE_MAP_POSITIVE_Z = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_POSITIVE_Z") macdef GL_TEXTURE_CUBE_MAP_NEGATIVE_Z = $extval (GLenum, "GL_TEXTURE_CUBE_MAP_NEGATIVE_Z") macdef GL_PROXY_TEXTURE_CUBE_MAP = $extval (GLenum, "GL_PROXY_TEXTURE_CUBE_MAP") macdef GL_MAX_CUBE_MAP_TEXTURE_SIZE = $extval (GLenum, "GL_MAX_CUBE_MAP_TEXTURE_SIZE") // texture_compression macdef GL_COMPRESSED_ALPHA = $extval (GLenum, "GL_COMPRESSED_ALPHA") macdef GL_COMPRESSED_LUMINANCE = $extval (GLenum, "GL_COMPRESSED_LUMINANCE") macdef GL_COMPRESSED_LUMINANCE_ALPHA = $extval (GLenum, "GL_COMPRESSED_LUMINANCE_ALPHA") macdef GL_COMPRESSED_INTENSITY = $extval (GLenum, "GL_COMPRESSED_INTENSITY") macdef GL_COMPRESSED_RGB = $extval (GLenum, "GL_COMPRESSED_RGB") macdef GL_COMPRESSED_RGBA = $extval (GLenum, "GL_COMPRESSED_RGBA") macdef GL_TEXTURE_COMPRESSION_HINT = $extval (GLenum, "GL_TEXTURE_COMPRESSION_HINT") macdef GL_TEXTURE_COMPRESSED_IMAGE_SIZE = $extval (GLenum, "GL_TEXTURE_COMPRESSED_IMAGE_SIZE") macdef GL_TEXTURE_COMPRESSED = $extval (GLenum, "GL_TEXTURE_COMPRESSED") macdef GL_NUM_COMPRESSED_TEXTURE_FORMATS = $extval (GLenum, "GL_NUM_COMPRESSED_TEXTURE_FORMATS") macdef GL_COMPRESSED_TEXTURE_FORMATS = $extval (GLenum, "GL_COMPRESSED_TEXTURE_FORMATS") // multisample macdef GL_MULTISAMPLE = $extval (GLenum, "GL_MULTISAMPLE") macdef GL_SAMPLE_ALPHA_TO_COVERAGE = $extval (GLenum, "GL_SAMPLE_ALPHA_TO_COVERAGE") macdef GL_SAMPLE_ALPHA_TO_ONE = $extval (GLenum, "GL_SAMPLE_ALPHA_TO_ONE") macdef GL_SAMPLE_COVERAGE = $extval (GLenum, "GL_SAMPLE_COVERAGE") macdef GL_SAMPLE_BUFFERS = $extval (GLenum, "GL_SAMPLE_BUFFERS") macdef GL_SAMPLES = $extval (GLenum, "GL_SAMPLES") macdef GL_SAMPLE_COVERAGE_VALUE = $extval (GLenum, "GL_SAMPLE_COVERAGE_VALUE") macdef GL_SAMPLE_COVERAGE_INVERT = $extval (GLenum, "GL_SAMPLE_COVERAGE_INVERT") macdef GL_MULTISAMPLE_BIT = $extval (GLenum, "GL_MULTISAMPLE_BIT") // transpose_matrix macdef GL_TRANSPOSE_MODELVIEW_MATRIX = $extval (GLenum, "GL_TRANSPOSE_MODELVIEW_MATRIX") macdef GL_TRANSPOSE_PROJECTION_MATRIX = $extval (GLenum, "GL_TRANSPOSE_PROJECTION_MATRIX") macdef GL_TRANSPOSE_TEXTURE_MATRIX = $extval (GLenum, "GL_TRANSPOSE_TEXTURE_MATRIX") macdef GL_TRANSPOSE_COLOR_MATRIX = $extval (GLenum, "GL_TRANSPOSE_COLOR_MATRIX") // texture_env_combine macdef GL_COMBINE = $extval (GLenum, "GL_COMBINE") macdef GL_COMBINE_RGB = $extval (GLenum, "GL_COMBINE_RGB") macdef GL_COMBINE_ALPHA = $extval (GLenum, "GL_COMBINE_ALPHA") macdef GL_SOURCE0_RGB = $extval (GLenum, "GL_SOURCE0_RGB") macdef GL_SOURCE1_RGB = $extval (GLenum, "GL_SOURCE1_RGB") macdef GL_SOURCE2_RGB = $extval (GLenum, "GL_SOURCE2_RGB") macdef GL_SOURCE0_ALPHA = $extval (GLenum, "GL_SOURCE0_ALPHA") macdef GL_SOURCE1_ALPHA = $extval (GLenum, "GL_SOURCE1_ALPHA") macdef GL_SOURCE2_ALPHA = $extval (GLenum, "GL_SOURCE2_ALPHA") macdef GL_OPERAND0_RGB = $extval (GLenum, "GL_OPERAND0_RGB") macdef GL_OPERAND1_RGB = $extval (GLenum, "GL_OPERAND1_RGB") macdef GL_OPERAND2_RGB = $extval (GLenum, "GL_OPERAND2_RGB") macdef GL_OPERAND0_ALPHA = $extval (GLenum, "GL_OPERAND0_ALPHA") macdef GL_OPERAND1_ALPHA = $extval (GLenum, "GL_OPERAND1_ALPHA") macdef GL_OPERAND2_ALPHA = $extval (GLenum, "GL_OPERAND2_ALPHA") macdef GL_RGB_SCALE = $extval (GLenum, "GL_RGB_SCALE") macdef GL_ADD_SIGNED = $extval (GLenum, "GL_ADD_SIGNED") macdef GL_INTERPOLATE = $extval (GLenum, "GL_INTERPOLATE") macdef GL_SUBTRACT = $extval (GLenum, "GL_SUBTRACT") macdef GL_CONSTANT = $extval (GLenum, "GL_CONSTANT") macdef GL_PRIMARY_COLOR = $extval (GLenum, "GL_PRIMARY_COLOR") macdef GL_PREVIOUS = $extval (GLenum, "GL_PREVIOUS") // texture_env_dot3 macdef GL_DOT3_RGB = $extval (GLenum, "GL_DOT3_RGB") macdef GL_DOT3_RGBA = $extval (GLenum, "GL_DOT3_RGBA") // texture_border_clamp macdef GL_CLAMP_TO_BORDER = $extval (GLenum, "GL_CLAMP_TO_BORDER") (* ****** ****** *) macdef GL_ARB_multitexture = $extval (GLenum, "GL_ARB_multitexture") macdef GL_TEXTURE0_ARB = $extval (GLenum, "GL_TEXTURE0_ARB") macdef GL_TEXTURE1_ARB = $extval (GLenum, "GL_TEXTURE1_ARB") macdef GL_TEXTURE2_ARB = $extval (GLenum, "GL_TEXTURE2_ARB") macdef GL_TEXTURE3_ARB = $extval (GLenum, "GL_TEXTURE3_ARB") macdef GL_TEXTURE4_ARB = $extval (GLenum, "GL_TEXTURE4_ARB") macdef GL_TEXTURE5_ARB = $extval (GLenum, "GL_TEXTURE5_ARB") macdef GL_TEXTURE6_ARB = $extval (GLenum, "GL_TEXTURE6_ARB") macdef GL_TEXTURE7_ARB = $extval (GLenum, "GL_TEXTURE7_ARB") macdef GL_TEXTURE8_ARB = $extval (GLenum, "GL_TEXTURE8_ARB") macdef GL_TEXTURE9_ARB = $extval (GLenum, "GL_TEXTURE9_ARB") macdef GL_TEXTURE10_ARB = $extval (GLenum, "GL_TEXTURE10_ARB") macdef GL_TEXTURE11_ARB = $extval (GLenum, "GL_TEXTURE11_ARB") macdef GL_TEXTURE12_ARB = $extval (GLenum, "GL_TEXTURE12_ARB") macdef GL_TEXTURE13_ARB = $extval (GLenum, "GL_TEXTURE13_ARB") macdef GL_TEXTURE14_ARB = $extval (GLenum, "GL_TEXTURE14_ARB") macdef GL_TEXTURE15_ARB = $extval (GLenum, "GL_TEXTURE15_ARB") macdef GL_TEXTURE16_ARB = $extval (GLenum, "GL_TEXTURE16_ARB") macdef GL_TEXTURE17_ARB = $extval (GLenum, "GL_TEXTURE17_ARB") macdef GL_TEXTURE18_ARB = $extval (GLenum, "GL_TEXTURE18_ARB") macdef GL_TEXTURE19_ARB = $extval (GLenum, "GL_TEXTURE19_ARB") macdef GL_TEXTURE20_ARB = $extval (GLenum, "GL_TEXTURE20_ARB") macdef GL_TEXTURE21_ARB = $extval (GLenum, "GL_TEXTURE21_ARB") macdef GL_TEXTURE22_ARB = $extval (GLenum, "GL_TEXTURE22_ARB") macdef GL_TEXTURE23_ARB = $extval (GLenum, "GL_TEXTURE23_ARB") macdef GL_TEXTURE24_ARB = $extval (GLenum, "GL_TEXTURE24_ARB") macdef GL_TEXTURE25_ARB = $extval (GLenum, "GL_TEXTURE25_ARB") macdef GL_TEXTURE26_ARB = $extval (GLenum, "GL_TEXTURE26_ARB") macdef GL_TEXTURE27_ARB = $extval (GLenum, "GL_TEXTURE27_ARB") macdef GL_TEXTURE28_ARB = $extval (GLenum, "GL_TEXTURE28_ARB") macdef GL_TEXTURE29_ARB = $extval (GLenum, "GL_TEXTURE29_ARB") macdef GL_TEXTURE30_ARB = $extval (GLenum, "GL_TEXTURE30_ARB") macdef GL_TEXTURE31_ARB = $extval (GLenum, "GL_TEXTURE31_ARB") macdef GL_ACTIVE_TEXTURE_ARB = $extval (GLenum, "GL_ACTIVE_TEXTURE_ARB") macdef GL_CLIENT_ACTIVE_TEXTURE_ARB = $extval (GLenum, "GL_CLIENT_ACTIVE_TEXTURE_ARB") macdef GL_MAX_TEXTURE_UNITS_ARB = $extval (GLenum, "GL_MAX_TEXTURE_UNITS_ARB") macdef GL_MESA_shader_debug = $extval (GLenum, "GL_MESA_shader_debug") macdef GL_DEBUG_OBJECT_MESA = $extval (GLenum, "GL_DEBUG_OBJECT_MESA") macdef GL_DEBUG_PRINT_MESA = $extval (GLenum, "GL_DEBUG_PRINT_MESA") macdef GL_DEBUG_ASSERT_MESA = $extval (GLenum, "GL_DEBUG_ASSERT_MESA") macdef GL_MESA_trace = $extval (GLenum, "GL_MESA_trace") macdef GL_TRACE_ALL_BITS_MESA = $extval (GLenum, "GL_TRACE_ALL_BITS_MESA") macdef GL_TRACE_OPERATIONS_BIT_MESA = $extval (GLenum, "GL_TRACE_OPERATIONS_BIT_MESA") macdef GL_TRACE_PRIMITIVES_BIT_MESA = $extval (GLenum, "GL_TRACE_PRIMITIVES_BIT_MESA") macdef GL_TRACE_ARRAYS_BIT_MESA = $extval (GLenum, "GL_TRACE_ARRAYS_BIT_MESA") macdef GL_TRACE_TEXTURES_BIT_MESA = $extval (GLenum, "GL_TRACE_TEXTURES_BIT_MESA") macdef GL_TRACE_PIXELS_BIT_MESA = $extval (GLenum, "GL_TRACE_PIXELS_BIT_MESA") macdef GL_TRACE_ERRORS_BIT_MESA = $extval (GLenum, "GL_TRACE_ERRORS_BIT_MESA") macdef GL_TRACE_MASK_MESA = $extval (GLenum, "GL_TRACE_MASK_MESA") macdef GL_TRACE_NAME_MESA = $extval (GLenum, "GL_TRACE_NAME_MESA") macdef GL_MESA_packed_depth_stencil = $extval (GLenum, "GL_MESA_packed_depth_stencil") macdef GL_DEPTH_STENCIL_MESA = $extval (GLenum, "GL_DEPTH_STENCIL_MESA") macdef GL_UNSIGNED_INT_24_8_MESA = $extval (GLenum, "GL_UNSIGNED_INT_24_8_MESA") macdef GL_UNSIGNED_INT_8_24_REV_MESA = $extval (GLenum, "GL_UNSIGNED_INT_8_24_REV_MESA") macdef GL_UNSIGNED_SHORT_15_1_MESA = $extval (GLenum, "GL_UNSIGNED_SHORT_15_1_MESA") macdef GL_UNSIGNED_SHORT_1_15_REV_MESA = $extval (GLenum, "GL_UNSIGNED_SHORT_1_15_REV_MESA") macdef GL_MESA_program_debug = $extval (GLenum, "GL_MESA_program_debug") macdef GL_FRAGMENT_PROGRAM_POSITION_MESA = $extval (GLenum, "GL_FRAGMENT_PROGRAM_POSITION_MESA") macdef GL_FRAGMENT_PROGRAM_CALLBACK_MESA = $extval (GLenum, "GL_FRAGMENT_PROGRAM_CALLBACK_MESA") macdef GL_FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA = $extval (GLenum, "GL_FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA") macdef GL_FRAGMENT_PROGRAM_CALLBACK_DATA_MESA = $extval (GLenum, "GL_FRAGMENT_PROGRAM_CALLBACK_DATA_MESA") macdef GL_VERTEX_PROGRAM_POSITION_MESA = $extval (GLenum, "GL_VERTEX_PROGRAM_POSITION_MESA") macdef GL_VERTEX_PROGRAM_CALLBACK_MESA = $extval (GLenum, "GL_VERTEX_PROGRAM_CALLBACK_MESA") macdef GL_VERTEX_PROGRAM_CALLBACK_FUNC_MESA = $extval (GLenum, "GL_VERTEX_PROGRAM_CALLBACK_FUNC_MESA") macdef GL_VERTEX_PROGRAM_CALLBACK_DATA_MESA = $extval (GLenum, "GL_VERTEX_PROGRAM_CALLBACK_DATA_MESA") macdef GL_ATI_blend_equation_separate = $extval (GLenum, "GL_ATI_blend_equation_separate") macdef GL_ALPHA_BLEND_EQUATION_ATI = $extval (GLenum, "GL_ALPHA_BLEND_EQUATION_ATI") (* ****** ****** *) (* end of [gl.sats] *) ats-lang-anairiats-0.2.11/contrib/GL/Makefile0000664000175000017500000000140712223166165017404 0ustar hwxihwxi# # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Time: December, 2009 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ATSCC=$(ATSUSRQ)/bin/atscc ###### all:: atsctrb_GL.o all:: atsctrb_glut.o all:: clean ###### atsctrb_GL.o: gl_sats.o glu_sats.o ; ld -r -o $@ $^ atsctrb_glut.o: glut_sats.o glut_dats.o ; ld -r -o $@ $^ ###### gl_sats.o: SATS/gl.sats $(ATSCC) -o $@ -c SATS/gl.sats glu_sats.o: SATS/glu.sats $(ATSCC) -o $@ -c SATS/glu.sats ###### glut_sats.o: SATS/glut.sats $(ATSCC) -o $@ -c SATS/glut.sats glut_dats.o: DATS/glut.dats $(ATSCC) -o $@ -c DATS/glut.dats ###### RMF=rm -f ###### clean:: ; $(RMF) *_?ats.c *_?ats.o cleanall:: clean cleanall:: ; $(RMF) atsctrb_GL.o atsctrb_glut.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/GL/DATS/0000700000175000017500000000000012223166165016461 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/GL/DATS/glut.dats0000664000175000017500000000436012223166165020330 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Starting time: Summer, 2008 // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) implement glutStrokeString (font, s) = let val [n:int] s = string1_of_string s var i: sizeLte n = size1_of_int1 (0) in while (string_isnot_atend (s, i)) let val () = glutStrokeCharacter (font, s[i]) in i := i+1 end // end of [while] end // end of [glutStrokeString] (* ****** ****** *) implement glutBitmapString (font, s) = let val [n:int] s = string1_of_string s var i: sizeLte n = size1_of_int1 (0) in while (string_isnot_atend (s, i)) let val () = glutBitmapCharacter (font, s[i]) in i := i+1 end // end of [while] end // end of [glutBitmapString] (* ****** ****** *) (* end of [glut.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/0000700000175000017500000000000012223166165016571 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/mysql/CATS/0000700000175000017500000000000012223166165017323 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/mysql/CATS/mysql.cats0000664000175000017500000001171712223166165021367 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /***********************************************************************/ /* (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) */ /* ****** ****** */ /* ** Source: ** $PATSHOME/prelude/CATS/CODEGEN/mysql.atxt ** Time of generation: Sat Sep 1 15:33:21 2012 */ /* ****** ****** */ /* (* Author: Hongwei Xi *) (* Authoremail: hwxi AT cs DOT bu DOT edu *) (* Start time: May, 2012 *) */ /* ****** ****** */ #ifndef ATSHOME_CONTRIB_MYSQL_MYSQL_CATS #define ATSHOME_CONTRIB_MYSQL_MYSQL_CATS /* ****** ****** */ #include /* ****** ****** */ typedef MYSQL MYSQL_struct ; typedef MYSQL_RES MYSQLRES_struct ; typedef MYSQL_ROW MYSQLROW_struct ; typedef MYSQL_FIELD MYSQLFIELD_struct ; /* ****** ****** */ #define atsctrb_mysql_init_0() mysql_init(NULL) #define atsctrb_mysql_init_1(conn) mysql_init(conn) /* ****** ****** */ #define atsctrb_mysql_close mysql_close #define atsctrb_mysql_real_connect mysql_real_connect #define atsctrb_mysql_change_user mysql_change_user /* ****** ****** */ #define atsctrb_mysql_ping mysql_ping #define atsctrb_mysql_commit mysql_commit /* ****** ****** */ #define atsctrb_mysql_query mysql_query #define atsctrb_mysql_list_dbs mysql_list_dbs #define atsctrb_mysql_list_fields mysql_list_fields /* ****** ****** */ #define atsctrb_mysql_field_count mysql_field_count /* ****** ****** */ #define atsctrb_mysql_num_rows mysql_num_rows #define atsctrb_mysql_num_fields mysql_num_fields /* ****** ****** */ #define atsctrb_mysql_field_tell mysql_field_tell #define atsctrb_mysql_field_seek mysql_field_seek /* ****** ****** */ #define atsctrb_mysql_affected_rows mysql_affected_rows /* ****** ****** */ #define atsctrb_mysql_use_result mysql_use_result #define atsctrb_mysql_store_result mysql_store_result /* ****** ****** */ #define atsctrb_mysql_free_result mysql_free_result /* ****** ****** */ #define atsctrb_mysql_data_seek mysql_data_seek /* ****** ****** */ #define atsctrb_mysql_fetch_row mysql_fetch_row #define atsctrb_mysql_fetch_lengths mysql_fetch_lengths /* ****** ****** */ #define atsctrb_mysql_fetch_field mysql_fetch_field #define atsctrb_mysql_fetch_field_direct mysql_fetch_field_direct #define atsctrb_mysql_fetch_fields mysql_fetch_fields /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_mysqlrow_get_at (ats_ptr_type row, ats_int_type i) { return ((ats_ptr_type*)row)[i] ; } // end of [atsctrb_mysqlrow_get_at] ATSinline() ats_ulint_type atsctrb_mysqlrowlen_get_at (ats_ptr_type rowlen, ats_int_type i) { return ((ats_ulint_type*)rowlen)[i] ; } // end of [atsctrb_mysqlrowlen_get_at] /* ****** ****** */ ATSinline() ats_ptr_type atsctrb_mysqlfield_get_name (ats_ptr_type fld) { return ((MYSQLFIELD_struct*)fld)->name ; } // end of [atsctrb_mysqlfield_get_name] /* ****** ****** */ #define atsctrb_mysql_info(conn) ((char*)(mysql_info(conn))) #define atsctrb_mysql_stat(conn) ((char*)(mysql_stat(conn))) #define atsctrb_mysql_sqlstate(conn) ((char*)(mysql_sqlstate(conn))) /* ****** ****** */ #define atsctrb_mysql_get_host_info(conn) ((char*)(mysql_get_host_info(conn))) #define atsctrb_mysql_get_proto_info mysql_get_proto_info #define atsctrb_mysql_get_client_info() ((char*)(mysql_get_client_info())) #define atsctrb_mysql_get_client_version mysql_get_client_version #define atsctrb_mysql_get_server_info(conn) ((char*)(mysql_get_server_info(conn))) #define atsctrb_mysql_get_server_version mysql_get_server_version /* ****** ****** */ #define atsctrb_mysql_errno mysql_errno #define atsctrb_mysql_error(x) ((char*)(mysql_error(x))) /* ****** ****** */ #define atsctrb_mysql_hex_string mysql_hex_string #define atsctrb_mysql_escape_string mysql_escape_string #define atsctrb_mysql_real_escape_string mysql_real_escape_string /* ****** ****** */ #define atsctrb_mysql_warning_count mysql_warning_count /* ****** ****** */ #endif // ifndef ATSHOME_CONTRIB_MYSQL_MYSQL_CATS /* ****** ****** */ /* end of [mysql.cats] */ ats-lang-anairiats-0.2.11/contrib/mysql/TEST/0000700000175000017500000000000012223166165017350 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/mysql/TEST/test04.dats0000664000175000017500000000216712223166165021372 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) #define some stropt_some #define none stropt_none (* ****** ****** *) implement main () = let val [l:addr] conn = mysql_init () val perr = MYSQLptr2ptr (conn) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // // mysql -h... -P... -umysqlats mysqlats -p mysqlats16712 // val host = some"instance25474.db.xeround.com" val user = some"mysqlats" val passwd = some"mysqlats16712" val dbname = some"testdb" val port = 16712U val socket = none val perr = mysql_real_connect (conn, host, user, passwd, dbname, port, socket, 0UL) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (perr > null) // val qry = "CREATE DATABASE testdb" val ierr = mysql_query (conn, $UN.cast{query}(qry)) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (ierr = 0) // val () = mysql_close (conn) in // nothing end // end of [main] (* ****** ****** *) (* end of [test04.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/TEST/test06.dats0000664000175000017500000000363312223166165021373 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) #define some stropt_some #define none stropt_none (* ****** ****** *) implement main () = let val [l:addr] conn = mysql_init () val perr = MYSQLptr2ptr (conn) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // // mysql -h... -P... -umysqlats mysqlats -p mysqlats16712 // val host = some"instance25474.db.xeround.com" val user = some"mysqlats" val passwd = some"mysqlats16712" val dbname = some"testdb" val port = 16712U val perr = mysql_real_connect (conn, host, user, passwd, dbname, port, none, 0UL) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (perr > null) // val qry = "SELECT * FROM writers" val ierr = mysql_query (conn, $UN.cast{query}(qry)) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (ierr = 0) // val nfld1 = mysql_field_count (conn) val () = println! ("nfld1 = ", nfld1) // val res = mysql_store_result (conn) val () = fprint_mysql_error (stderr_ref, conn) val perr = MYSQLRESptr2ptr (res) val () = assertloc (perr > null) // val ( _pf | nrow2 ) = mysql_num_rows (res) val nrow2 = $UN.cast{ullint} (nrow2) val () = println! ("nrow2 = ", nrow2) val (_pf | nfld2) = mysql_num_fields (res) val () = println! ("nfld2 = ", nfld2) // val () = fprint_mysqlres_sep (stdout_ref, res, "\n", ", ") val () = fprint_newline (stdout_ref) // val ( _pf | nrow2 ) = mysql_num_rows (res) val nrow2 = $UN.cast{ullint} (nrow2) val () = println! ("nrow2 = ", nrow2) val (_pf | nfld2) = mysql_num_fields (res) val () = println! ("nfld2 = ", nfld2) // val () = mysql_free_result (res) // val () = mysql_close (conn) in // nothing end // end of [main] (* ****** ****** *) (* end of [test06.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/TEST/test01.dats0000664000175000017500000000047012223166165021362 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) implement main () = let val version = mysql_get_client_info () val () = printf("MySQL client version: %s\n", @(version)) in end // end of [main] (* ****** ****** *) (* end of [test01.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/TEST/Makefile0000664000175000017500000000255712223166165021035 0ustar hwxihwxi# # A simple Makefile # ###### ATSHOMEQ="$(ATSHOME)" ###### ATSCC=$(ATSHOME)/bin/atscc ATSCTRB=$(ATSHOMEQ)/contrib ###### CCFLAGS=-O2 MYSQLCFLAGS=`mysql_config --cflags --libs` ###### all:: all:: test01 all:: test02 all:: test03 all:: test04 all:: test05 all:: test06 ###### clean:: cleanall:: ###### test01: test01_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test01 $< $(MYSQLCFLAGS) cleanall:: ; $(RMF) test01 ###### test02: test02_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test02 $< $(MYSQLCFLAGS) $(ATSCTRB)/mysql/atsctrb_mysql.o cleanall:: ; $(RMF) test02 ###### test03: test03_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test03 $< $(MYSQLCFLAGS) $(ATSCTRB)/mysql/atsctrb_mysql.o cleanall:: ; $(RMF) test03 ###### test04: test04_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test04 $< $(MYSQLCFLAGS) $(ATSCTRB)/mysql/atsctrb_mysql.o cleanall:: ; $(RMF) test04 ###### test05: test05_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test05 $< $(MYSQLCFLAGS) $(ATSCTRB)/mysql/atsctrb_mysql.o cleanall:: ; $(RMF) test05 ###### test06: test06_dats.c $(ATSCC) $(CCFLAGS) -I$(ATSCTRB) -o test06 $< $(MYSQLCFLAGS) $(ATSCTRB)/mysql/atsctrb_mysql.o cleanall:: ; $(RMF) test06 ###### %_dats.c: %.dats ; $(ATSCC) -cc -IATS$(ATSCTRB) $< ###### RMF=rm -f ###### clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.o *_?ats.c ###### cleanall:: clean ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/mysql/TEST/test05.dats0000664000175000017500000000415412223166165021371 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) #define some stropt_some #define none stropt_none (* ****** ****** *) implement main () = let val [l:addr] conn = mysql_init () val perr = MYSQLptr2ptr (conn) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // // mysql -h... -P... -umysqlats mysqlats -p mysqlats16712 // val host = some"instance25474.db.xeround.com" val user = some"mysqlats" val passwd = some"mysqlats16712" val dbname = some"testdb" val port = 16712U val perr = mysql_real_connect (conn, host, user, passwd, dbname, port, none, 0UL) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (perr > null) // macdef query (x) = $UN.cast{query}{string}(,(x)) // val ierr = mysql_query(conn, query"DROP TABLE writers") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"CREATE TABLE writers(id INT UNSIGNED AUTO_INCREMENT, name VARCHAR(25), PRIMARY KEY(id))") val () = fprint_mysql_error (stderr_ref, conn) // val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'William Shakespeare')") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'Leo Tolstoy')") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'Jack London')") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'Honore de Balzac')") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'Lion Feuchtwanger')") val () = fprint_mysql_error (stderr_ref, conn) val ierr = mysql_query(conn, query"INSERT INTO writers VALUES(NULL, 'Emile Zola')") val () = fprint_mysql_error (stderr_ref, conn) // val () = mysql_close (conn) in // nothing end // end of [main] (* ****** ****** *) (* end of [test05.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/TEST/test02.dats0000664000175000017500000000353212223166165021365 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) #define some stropt_some #define none stropt_none (* ****** ****** *) implement main () = let val [l:addr] conn = mysql_init () val perr = MYSQLptr2ptr (conn) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // // mysql -h... -P... -umysqlats mysqlats -p mysqlats16712 // val host = some"instance25474.db.xeround.com" val user = some"mysqlats" val pass = some"mysqlats16712" val port = 16712U val perr = mysql_real_connect (conn, host, user, pass, none, port, none, 0UL) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // val stat = mysql_stat (conn) val () = fprintf (stdout_ref, "stat: %s\n", @(stat)) val sqlstate = mysql_sqlstate (conn) val () = fprintf (stdout_ref, "sqlstate: %s\n", @(sqlstate)) // val info = mysql_get_host_info (conn) val () = fprintf (stdout_ref, "host info: %s\n", @(info)) val proto = mysql_get_proto_info (conn) val () = fprintf (stdout_ref, "proto info: %u\n", @(proto)) // val info = mysql_get_server_info (conn) val () = fprintf (stdout_ref, "server info: %s\n", @(info)) val version = mysql_get_server_version (conn) val () = fprintf (stdout_ref, "server info: %lu\n", @(version)) // val qry = "create database testdb" val ierr = mysql_query (conn, $UN.cast{query}(qry)) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (ierr = 0) // val qry = "drop database testdb" val ierr = mysql_query (conn, $UN.cast{query}(qry)) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (ierr = 0) // val () = mysql_close (conn) in // nothing end // end of [main] (* ****** ****** *) (* end of [test02.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/TEST/test03.dats0000664000175000017500000000425212223166165021366 0ustar hwxihwxi// // Testing ATS API for mysql // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) // staload "mysql/SATS/mysql.sats" // (* ****** ****** *) #define some stropt_some #define none stropt_none (* ****** ****** *) implement main () = let val [l:addr] conn = mysql_init () val perr = MYSQLptr2ptr (conn) val () = fprint_mysql_error (stderr_ref, conn) // val () = assertloc (perr > null) // // mysql -h... -P... -umysqlats mysqlats -p mysqlats16712 // val host = some"instance25474.db.xeround.com" val user = some"mysqlats" val pass = some"mysqlats16712" val port = 16712U val perr = mysql_real_connect (conn, host, user, pass, none, port, none, 0UL) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (perr > null) // val res = mysql_list_dbs (conn, none) val () = fprint_mysql_error (stderr_ref, conn) val perr = MYSQLRESptr2ptr (res) val () = assertloc (perr > null) // val () = fprint_mysqlres_sep (stdout_ref, res, "\n", ", ") val () = fprint_newline (stdout_ref) // val ( _pf | nrow2 ) = mysql_num_rows (res) val nrow2 = $UN.cast{ullint} (nrow2) val () = println! ("nrow2 = ", nrow2) val (_pf | nfld2) = mysql_num_fields (res) val () = println! ("nfld2 = ", nfld2) // val () = mysql_free_result (res) // val qry = "SHOW DATABASES" val ierr = mysql_query (conn, $UN.cast{query}(qry)) val () = fprint_mysql_error (stderr_ref, conn) val () = assertloc (ierr = 0) // val nfld1 = mysql_field_count (conn) val () = println! ("nfld1 = ", nfld1) // val res = mysql_use_result (conn) val () = fprint_mysql_error (stderr_ref, conn) val perr = MYSQLRESptr2ptr (res) val () = assertloc (perr > null) // val () = fprint_mysqlres_sep (stdout_ref, res, "\n", ", ") val () = fprint_newline (stdout_ref) // val ( _pf | nrow2 ) = mysql_num_rows (res) val nrow2 = $UN.cast{ullint} (nrow2) val () = println! ("nrow2 = ", nrow2) val (_pf | nfld2) = mysql_num_fields (res) val () = println! ("nfld2 = ", nfld2) // val () = mysql_free_result (res) // val () = mysql_close (conn) // in // nothing end // end of [main] (* ****** ****** *) (* end of [test03.dats] *) ats-lang-anairiats-0.2.11/contrib/mysql/SATS/0000700000175000017500000000000012223166165017343 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/mysql/SATS/mysql.sats0000664000175000017500000003615612223166165021433 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** Start Time: August, 2012 ** Author: Hongwei Xi (gmhwxi AT gmail DOT com) *) (* ****** ****** *) %{# #include "mysql/CATS/mysql.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) typedef SHR(x:type) = x // for commenting purpose typedef NSH(x:type) = x // for commenting purpose (* ****** ****** *) absviewt@ype MYSQL = $extype "MYSQL_struct" absviewt@ype MYSQLRES = $extype "MYSQLRES_struct" absviewt@ype MYSQLFIELD = $extype "MYSQLFIELD_struct" (* ****** ****** *) absviewtype MYSQLptr (l:addr) viewtypedef MYSQLptr0 = [l:addr] MYSQLptr (l) viewtypedef MYSQLptr1 = [l:addr| l > null] MYSQLptr (l) (* ****** ****** *) absviewtype MYSQLRESptr (l:addr) viewtypedef MYSQLRESptr0 = [l:addr] MYSQLRESptr (l) viewtypedef MYSQLRESptr1 = [l:addr| l > null] MYSQLRESptr (l) (* ****** ****** *) absviewtype MYSQLFIELDptr (l1:addr, l2:addr) viewtypedef MYSQLFIELDptr0 (l1:addr) = [l2:addr] MYSQLFIELDptr (l1, l2) viewtypedef MYSQLFIELDptr1 (l1:addr) = [l2:addr| l2 > null] MYSQLFIELDptr (l1, l2) (* ****** ****** *) /* typedef char **MYSQLROW; */ absviewtype MYSQLROW (l1:addr, l2:addr) viewtypedef MYSQLROW0 (l1:addr) = [l2:addr] MYSQLROW (l1, l2) viewtypedef MYSQLROW1 (l1:addr) = [l2:addr| l2 > null] MYSQLROW (l1, l2) (* ****** ****** *) absviewtype MYSQLROWLEN (l1:addr, l2:addr) viewtypedef MYSQLROWLEN0 (l1:addr) = [l2:addr] MYSQLROWLEN (l1, l2) viewtypedef MYSQLROWLEN1 (l1:addr) = [l2:addr| l2 > null] MYSQLROWLEN (l1, l2) (* ****** ****** *) castfn MYSQLptr2ptr {l:addr} (x: !MYSQLptr l):<> ptr (l) castfn MYSQLRESptr2ptr {l:addr} (x: !MYSQLRESptr (l)):<> ptr (l) castfn MYSQLFIELDptr2ptr {l1,l2:addr} (x: !MYSQLFIELDptr (l1, l2)):<> ptr (l2) (* ****** ****** *) castfn MYSQLROW2ptr {l1,l2:addr} (x: !MYSQLROW (l1, l2)):<> ptr (l2) (* ****** ****** *) abstype query = string (* ****** ****** *) symintr free_null prfun mysql_free_null {l:addr | l <= null} (x: MYSQLptr (l)):<> void overload free_null with mysql_free_null prfun mysqlres_free_null {l:addr | l <= null} (x: MYSQLRESptr (l)):<> void overload free_null with mysqlres_free_null prfun mysqlrow_free_null {l1,l2:addr | l2 <= null} (x: MYSQLROW (l1, l2)):<> void overload free_null with mysqlrow_free_null prfun mysqlfield_free_null {l1,l2:addr | l2 <= null} (x: MYSQLFIELDptr (l1, l2)):<> void overload free_null with mysqlfield_free_null (* ****** ****** *) symintr mysql_init fun mysql_init_0 ((*null*)): MYSQLptr0 = "mac#atsctrb_mysql_init_0" overload mysql_init with mysql_init_0 fun mysql_init_1 {l:agz} (x: !MYSQLptr l): ptr = "mac#atsctrb_mysql_init_1" overload mysql_init with mysql_init_1 fun mysql_init_exn ((*null*)): MYSQLptr1 (* ****** ****** *) fun mysql_close (x: MYSQLptr0): void = "mac#atsctrb_mysql_close" (* ****** ****** *) /* MYSQL * STDCALL mysql_real_connect(MYSQL *mysql, const char *host, const char *user, const char *passwd, const char *db, unsigned int port, const char *unix_socket, unsigned long clientflag); */ fun mysql_real_connect {l:agz} ( mysql: !MYSQLptr (l) , host: NSH(stropt) , user: NSH(stropt) , passwd: NSH(stropt) , dbname: NSH(stropt) , port: uint , socket: NSH(stropt) , clientflag: ulint ) : Ptrnull (l) = "mac#atsctrb_mysql_real_connect" // end of [mysql_real_connect] (* ****** ****** *) /* my_bool mysql_change_user (MYSQL *mysql, const char *user, const char *passwd, const char *db); */ fun mysql_change_user {l:agz} ( mysql: !MYSQLptr l , user: NSH(string) , passwd: NSH(stropt) , dbname: NSH(stropt) ) : int = "mac#atsctrb_mysql_change_user" (* ****** ****** *) /* int mysql_ping(MYSQL *mysql); */ fun mysql_ping {l:agz} (mysql: !MYSQLptr l): int = "mac#atsctrb_mysql_ping" // end of [mysql_ping] (* ****** ****** *) /* my_bool mysql_commit (MYSQL *mysql); */ fun mysql_commit {l:agz} (mysql: !MYSQLptr l): int = "mac#atsctrb_mysql_commit" // end of [mysql_commit] (* ****** ****** *) /* int mysql_query(MYSQL *mysql, const char *q); */ fun mysql_query {l:agz} (mysql: !MYSQLptr l, q: query): int(*err*) = "mac#atsctrb_mysql_query" // end of [mysql_query] (* ****** ****** *) /* int mysql_create_db (MYSQL *mysql, const char *db); */ (* // HX-2012-08: it is deprecated; use mysql_query instead *) /* int mysql_drop_db (MYSQL *mysql, const char *db) */ (* // HX-2012-08: it is deprecated; use mysql_query instead *) (* ****** ****** *) /* MYSQL_RES* mysql_list_dbs(MYSQL *mysql, const char *wild) */ fun mysql_list_dbs {l:agz} ( mysql: !MYSQLptr l, wild: NSH(stropt) ) : MYSQLRESptr0 = "mac#atsctrb_mysql_list_dbs" /* MYSQL_RES* mysql_list_fields (MYSQL *mysql, const char *table, const char *wild) */ fun mysql_list_fields {l:agz} ( mysql: !MYSQLptr l , table: NSH(string), wild: NSH(stropt) ) : MYSQLRESptr0 = "mac#atsctrb_mysql_list_fields" (* ****** ****** *) fun mysql_field_count {l:agz} ( mysql: !MYSQLptr l ) : uint = "mac#atsctrb_mysql_field_count" (* ****** ****** *) absprop MYSQLRESnrow (addr, int) praxi lemma_MYSQLRESnrow_param {l:addr}{n:int} (pf: MYSQLRESnrow (l, n)): [l>null;n>=0] void // end of [lemma_MYSQLRESnrow_param] (* ****** ****** *) absprop MYSQLRESnfield (addr, int) praxi lemma_MYSQLRESnfield_param {l:addr}{n:int} (pf: MYSQLRESnfield (l, n)): [l>null;n>=0] void // end of [lemma_MYSQLRESnfield_param] praxi MYSQLRESnfield_istot {l:addr} (): [n:nat] MYSQLRESnfield (l, n) // end of [MYSQLRESnfield_istot] praxi MYSQLRESnfield_isfun {l:addr}{n1,n2:int} ( pf1: MYSQLRESnfield (l, n1) , pf2: MYSQLRESnfield (l, n2) ) : [n1==n2] void // end of [MYSQLRESnfield_isfun] (* ****** ****** *) fun mysql_num_rows {l:agz} ( res: !MYSQLRESptr l ) : [n:nat] (MYSQLRESnrow (l, n) | ullint n) = "mac#atsctrb_mysql_num_rows" macdef mysqlres_get_nrow = mysql_num_rows fun mysql_num_fields {l:agz} ( res: !MYSQLRESptr l ) : [n:nat] (MYSQLRESnfield (l, n) | int n) = "mac#atsctrb_mysql_num_fields" macdef mysqlres_get_nfield = mysql_num_fields (* ****** ****** *) /* typedef unsigned int MYSQL_FIELD_OFFSET ; */ /* MYSQL_FIELD_OFFSET mysql_field_tell (MYSQL_RES *result); */ fun mysql_field_tell {l:agz}{n:int} ( pf: MYSQLRESnfield (l, n) | res: !MYSQLRESptr l ) : natLte (n) = "mac#atsctrb_mysql_field_tell" /* MYSQL_FIELD_OFFSET mysql_field_seek (MYSQL_RES *result, MYSQL_FIELD_OFFSET offset); */ fun mysql_field_seek {l:agz}{n:int} ( pf: MYSQLRESnfield (l, n) | res: !MYSQLRESptr l, i: natLte (n) ) : natLte (n) = "mac#atsctrb_mysql_field_seek" (* ****** ****** *) /* my_ulonglong mysql_affected_rows(MYSQL *mysql) */ fun mysql_affected_rows {l:agz} (mysql: !MYSQLptr l): ullint = "mac#atsctrb_mysql_affected_rows" // end of [mysql_affected_rows] (* ****** ****** *) /* MYSQL_RES *mysql_use_result(MYSQL *mysql); */ fun mysql_use_result {l:agz} ( mysql: !MYSQLptr l ) : MYSQLRESptr0 = "mac#atsctrb_mysql_use_result" /* MYSQL_RES *mysql_store_result(MYSQL *mysql); */ fun mysql_store_result {l:agz} ( mysql: !MYSQLptr l ) : MYSQLRESptr0 = "mac#atsctrb_mysql_store_result" (* ****** ****** *) /* void mysql_free_result(MYSQL_RES *result); */ fun mysql_free_result (result: MYSQLRESptr0): void = "mac#atsctrb_mysql_free_result" // end of [mysql_free_result] (* ****** ****** *) /* void mysql_data_seek (MYSQL_RES *result, my_ulonglong offset) */ fun mysql_data_seek {l:agz} ( result: !MYSQLRESptr l, ofs: ullint ) : void = "mac#atsctrb_mysql_data_seek" (* ****** ****** *) /* MYSQL_ROW mysql_fetch_row(MYSQL_RES *result); */ fun mysql_fetch_row {l:agz} ( res: !MYSQLRESptr l ) : MYSQLROW0 (l) = "mac#atsctrb_mysql_fetch_row" macdef mysqlres_fetch_row = mysql_fetch_row prfun mysql_unfetch_row {l1,l2:addr} ( res: !MYSQLRESptr (l1), row: MYSQLROW (l1, l2) ) :<> void // end of [mysql_unfetch_row] macdef mysqlres_unfetch_row = mysql_unfetch_row (* ****** ****** *) /* MYSQL_ROWLEN mysql_fetch_lengths(MYSQL_RES *result); */ fun mysql_fetch_lengths {l:agz} ( res: !MYSQLRESptr l ) : MYSQLROWLEN0 (l) = "mac#atsctrb_mysql_fetch_lengths" macdef mysqlres_fetch_lengths = mysql_fetch_lengths prfun mysql_unfetch_lengths {l1,l2:addr} ( res: !MYSQLRESptr l1, rowlen: MYSQLROWLEN (l1, l2) ) :<> void // end of [mysql_unfetch_rowlen] macdef mysqlres_unfetch_lengths = mysql_unfetch_lengths (* ****** ****** *) fun mysqlrow_get_at {l1,l2:addr | l2 > null}{n:int} ( pfrow: MYSQLRESnfield (l1, n) | row: !MYSQLROW (l1, l2), i: natLt n ) : ptr = "mac#atsctrb_mysqlrow_get_at" // endfun (* ****** ****** *) fun mysqlrowlen_get_at {l1,l2:addr | l2 > null}{n:int} ( pfrow: MYSQLRESnfield (l1, n) | rowlen: !MYSQLROWLEN (l1, l2), i: natLt n ) : ulint = "mac#atsctrb_mysqlrowlen_get_at" // endfun (* ****** ****** *) /* MYSQL_FIELD mysql_fetch_field(MYSQL_RES *result); */ fun mysql_fetch_field {l:agz} ( res: !MYSQLRESptr l ) : MYSQLFIELDptr0 (l) = "mac#atsctrb_mysql_fetch_field" macdef mysqlres_fetch_field = mysql_fetch_field prfun mysql_unfetch_field {l1,l2:addr} ( res: !MYSQLRESptr (l1), field: MYSQLFIELDptr (l1, l2) ) :<> void // end of [mysql_unfetch_field] macdef mysqlres_unfetch_field = mysql_unfetch_field (* ****** ****** *) /* MYSQL_FIELD* mysql_fetch_field_direct (MYSQL_RES *result, unsigned int fieldnr); */ fun mysql_fetch_field_direct {l:agz}{n:int} ( pf: MYSQLRESnfield (l, n) | res: !MYSQLRESptr l, i: natLt n ) : MYSQLFIELDptr1 (l) = "mac#atsctrb_mysql_fetch_field_direct" macdef mysqlres_fetch_field_at = mysql_fetch_field_direct (* ****** ****** *) /* MYSQL_FIELD *mysql_fetch_fields (MYSQL_RES *result) */ fun mysql_fetch_fields {l:agz}{n:int} ( pf: MYSQLRESnfield (l, n) | res: !MYSQLRESptr l ) : [la:addr] ( array_v (MYSQLROW1 (l), n, la) , minus (MYSQLRESptr l, array_v (MYSQLROW1 (l), n, la)) | ptr la ) = "mac#atsctrb_mysql_fetch_fields" (* ****** ****** *) fun mysqlfield_get_name {l1,l2:addr | l2 > null} (fld: !MYSQLFIELDptr (l1, l2)) : ptr(*char*) = "mac#atsctrb_mysqlfield_get_name" // endfun fun mysqlfield_get_length {l1,l2:addr | l2 > null} (fld: !MYSQLFIELDptr (l1, l2)) : ulint = "mac#atsctrb_mysqlfield_get_length" // endfun fun mysqlfield_get_max_length {l1,l2:addr | l2 > null} (fld: !MYSQLFIELDptr (l1, l2)) : ulint = "mac#atsctrb_mysqlfield_get_max_length" // endfun (* ****** ****** *) /* const char *mysql_info (MYSQL *mysql); */ fun mysql_info {l:agz} (mysql: !MYSQLptr l): string = "mac#atsctrb_mysql_info" // end of [mysql_info] (* ****** ****** *) /* const char *mysql_stat (MYSQL *mysql); */ fun mysql_stat {l:agz} (mysql: !MYSQLptr l): string = "mac#atsctrb_mysql_stat" // end of [mysql_stat] (* ****** ****** *) /* const char *mysql_sqlstate (MYSQL *mysql); */ fun mysql_sqlstate {l:agz} (mysql: !MYSQLptr l): string = "mac#atsctrb_mysql_sqlstate" // end of [mysql_sqlstate] (* ****** ****** *) /* const char *mysql_get_host_info (MYSQL *mysql); */ fun mysql_get_host_info {l:agz} ( mysql: !MYSQLptr l ) : string = "mac#atsctrb_mysql_get_host_info" // end of [mysql_get_host_info] /* unsigned int mysql_get_proto_info(MYSQL *mysql) */ fun mysql_get_proto_info {l:agz} ( mysql: !MYSQLptr l ) : uint = "mac#atsctrb_mysql_get_proto_info" // end of [mysql_get_proto_info] (* ****** ****** *) /* const char* mysql_get_client_info(void); */ fun mysql_get_client_info (): string = "mac#atsctrb_mysql_get_client_info" // end of [mysql_get_client_info] /* unsigned long mysql_get_client_version(void); */ fun mysql_get_client_version (): ulint = "mac#atsctrb_mysql_get_client_version" // end of [mysql_get_client_version] (* ****** ****** *) /* const char *mysql_get_server_info (MYSQL *mysql); */ fun mysql_get_server_info {l:agz} ( mysql: !MYSQLptr l ) : string = "mac#atsctrb_mysql_get_server_info" // end of [mysql_get_server_info] /* unsigned long int mysql_get_server_version(MYSQL *mysql) */ fun mysql_get_server_version {l:agz} ( mysql: !MYSQLptr l ) : ulint = "mac#atsctrb_mysql_get_server_version" // end of [mysql_get_server_version] (* ****** ****** *) /* my_bool mysql_eof(MYSQL_RES *result); */ (* // HX-2012-08: this one is deprecated *) /* unsigned int mysql_errno(MYSQL *mysql); */ fun mysql_errno {l:addr} (mysql: !MYSQLptr l): uint = "mac#atsctrb_mysql_errno" // end of [mysql_errno] /* const char* mysql_error(MYSQL *mysql); */ fun mysql_error {l:addr} (mysql: !MYSQLptr l): string = "mac#atsctrb_mysql_error" // end of [mysql_errno] (* ****** ****** *) /* unsigned long mysql_hex_string (char *to, const char *from, unsigned long from_length) ; */ fun mysql_hex_string {lb:addr} {m,n:int | m >= 2*n+1} ( pf: b0ytes(m) @ lb | pbuf: ptr lb, src: NSH(string(n)), n: size_t n ) : sizeLt (m) = "mac#atsctrb_mysql_hex_string" /* unsigned long mysql_escape_string (char *to, const char *from, unsigned long from_length) ; */ fun mysql_escape_string {lb:addr} {m,n:int | m >= 2*n+1} ( pf: b0ytes(m) @ lb | pbuf: ptr lb, src: NSH(string(n)), n: size_t n ) : sizeLt (m) = "mac#atsctrb_mysql_escape_string" /* unsigned long mysql_real_escape_string (MYSQL *mysql, char *to,const char *from, unsigned long length); */ fun mysql_real_escape_string {l,lb:addr | l > null} {m,n:int | m >= 2*n+1} ( pf: b0ytes(m) @ lb | mysql: !MYSQLptr l, pbuf: ptr lb, src: NSH(string(n)), n: size_t n ) : sizeLt (m) = "mac#atsctrb_mysql_real_escape_string" (* ****** ****** *) /* unsigned int mysql_warning_count(MYSQL *mysql); */ fun mysql_warning_count {l:agz} (mysql: !MYSQLptr l): uint = "mac#atsctrb_mysql_warning_count" // end of [mysql_warning_count] (* ****** ****** *) // // Some convenience functions // (* ****** ****** *) fun fprint_mysql_error {l:addr} (out: FILEref, mysql: !MYSQLptr l): void // end of [fprint_mysql_error] (* ****** ****** *) fun fprint_mysqlres_sep {l:agz} ( out: FILEref , res: !MYSQLRESptr (l), sep1: NSH(string), sep2: NSH(string) ) : void // end of [fprint_mysqlres_sep] fun fprint_mysqlrow_sep {l1,l2:addr | l2 > null}{n:int} ( pfrow: MYSQLRESnfield (l1, n) | out: FILEref, row: !MYSQLROW (l1, l2), n: int n, sep: NSH(string) ) : void // end of [fprint_mysqlrow_sep] (* ****** ****** *) (* end of [mysql.sats] *) ats-lang-anairiats-0.2.11/contrib/mysql/Makefile0000664000175000017500000000117412223166165020250 0ustar hwxihwxi# # API for mysql in ATS # # Start Time: August, 2012 # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # ###### ATSHOMEQ="$(ATSHOME)" ###### ATSCC=$(ATSHOMEQ)/bin/atscc ATSCTRB=$(ATSHOMEQ)/contrib MYSQLCFLAGS=`mysql_config --cflags --libs` ###### all:: ###### all:: atsctrb_mysql.o atsctrb_mysql.o: mysql_dats.o ; ld -r -o $@ $^ ###### mysql_dats.o: DATS/mysql.dats $(ATSCC) -O2 -I$(ATSCTRB) -IATS$(ATSCTRB) -o $@ -c $< $(MYSQLCFLAGS) ###### RMF=rm -f ###### all:: clean clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.c *_?ats.o ###### cleanall:: clean cleanall:: ; $(RMF) atsctrb_mysql.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/contrib/mysql/DATS/0000700000175000017500000000000012223166165017324 5ustar hwxihwxiats-lang-anairiats-0.2.11/contrib/mysql/DATS/mysql.dats0000664000175000017500000001042712223166165021366 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** Start Time: August, 2012 ** Author: Hongwei Xi (gmhwxi AT gmail DOT com) *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "mysql/SATS/mysql.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) macdef nullp = the_null_ptr (* ****** ****** *) implement mysql_init_exn ((*null*)) = let val conn = mysql_init_0 () val p = MYSQLptr2ptr (conn) in // if p > nullp then conn else let // val () = fprint_mysql_error (stderr_ref, conn) prval () = mysql_free_null (conn) // HX: no-op val () = fprint_string (stderr_ref, "exit(ATS): [mysql_init0] failed.") val () = fprint_newline (stderr_ref) // in exit (1) end // end of [if] // end // end of [mysql_init0_exn] (* ****** ****** *) implement fprint_mysql_error (out, conn) = { val errno = mysql_errno (conn) val error = mysql_error (conn) val () = fprintf (out, "error(mysql): %u: %s", @(errno, error)) val () = fprint_newline (out) } // end of [fprint_mysql_error] (* ****** ****** *) implement fprint_mysqlres_sep {l} (out, res, sep1, sep2) = let // val [n:int] (pfrow | n) = mysql_num_fields (res) // fun loop1 ( out: FILEref , res: !MYSQLRESptr l, i: int ) : void = let val fld = mysqlres_fetch_field (res) val p = MYSQLFIELDptr2ptr (fld) in // if p > nullp then let val name = mysqlfield_get_name (fld) prval () = mysqlres_unfetch_field (res, fld) val () = if i > 0 then fprint_string (out, sep2) val () = fprint_string (out, $UN.cast{string}(name)) in loop1 (out, res, i+1) end else let prval () = mysqlres_unfetch_field (res, fld) in // finished end // end of [if] // end // end of [loop1] // fun loop2 ( out: FILEref , res: !MYSQLRESptr l, i: int ) : void = let val row = mysqlres_fetch_row (res) val prow = MYSQLROW2ptr (row) in // if prow > nullp then let val () = if i > 0 then fprint_string (out, sep1) val () = fprint_mysqlrow_sep (pfrow | out, row, n, sep2) prval () = mysqlres_unfetch_row (res, row) in loop2 (out, res, i+1) end else let prval () = mysqlres_unfetch_row (res, row) in // nothing end // end of [if] // end // end of [loop2] // val () = loop1 (out, res, 0) val () = loop2 (out, res, 1) // in // nothing end // end of [fprint_mysqlres_sep] (* ****** ****** *) implement fprint_mysqlrow_sep {l1,l2}{n} (pfrow | out, row, n, sep) = let // prval () = lemma_MYSQLRESnfield_param (pfrow) // fun loop {i:nat | i <= n} .. ( out: FILEref, row: !MYSQLROW (l1, l2), n: int n, sep: string, i: int i ) : void = if i < n then let val () = if i > 0 then fprint_string (out, sep) val p = mysqlrow_get_at (pfrow | row, i) val () = ( if (p > nullp) then fprint_string (out, $UN.cast{string}(p)) else fprint_string (out, "NULL") // end of [if] ) : void // end of [val] in loop (out, row, n, sep, i+1) end else () // end of [if] // in loop (out, row, n, sep, 0) end // end of [fprint_mysqlrow_sep] (* ****** ****** *) (* end of [mysql.dats] *) ats-lang-anairiats-0.2.11/prelude/0000700000175000017500000000000012223166162015421 5ustar hwxihwxiats-lang-anairiats-0.2.11/prelude/macrodef.sats0000664000175000017500000000571112223166162020115 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) (* some commonly used macro definitions *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [macrodef.ats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* macros in short form *) // [orelse] and [andalso] are not defined in the curried // form as they are infix operators macdef orelse (x, y) = if ,(x) then true else ,(y) macdef andalso (x, y) = if ,(x) then ,(y) else false (* ****** ****** *) macdef exitloc (x) = exit_errmsg (,(x), #LOCATION) macdef assertloc (x) = assert_errmsg (,(x), #LOCATION) (* ****** ****** *) (* only a macro in long form can be defined recursively *) macrodef rec power_mac x(*base:code*) n(*exponent:int*) = if n > 1 then `(,(x) * ,(power_mac x (n-1))) else (if n > 0 then x else `(1)) // end of [power_mac] macdef square_mac (x) = ,(power_mac x 2) and cube_mac (x) = ,(power_mac x 3) (* ****** ****** *) macdef print_mac (fprint, x) = let val (pf_stdout | ptr_stdout) = stdout_get () in ,(fprint) (file_mode_lte_w_w | !ptr_stdout, ,(x)); stdout_view_set (pf_stdout | (*none*)) end // end of [print_mac] macdef prerr_mac (fprint, x) = let val (pf_stderr | ptr_stderr) = stderr_get () in ,(fprint) (file_mode_lte_w_w | !ptr_stderr, ,(x)); stderr_view_set (pf_stderr | (*none*)) end // end of [prerr_mac] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [macrodef.ats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* end of [macrodef.sats] *) ats-lang-anairiats-0.2.11/prelude/CATS/0000700000175000017500000000000012223166162016153 5ustar hwxihwxiats-lang-anairiats-0.2.11/prelude/CATS/integer.cats0000664000175000017500000006637312223166162020517 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_INTEGER_CATS #define ATS_PRELUDE_INTEGER_CATS /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ /* ** these functions are declared in stdlib.h */ extern int atoi (const char* cs) ; extern long int atol (const char* cs) ; extern long long int atoll (const char* cs) ; /* ****** ****** */ #include "ats_types.h" #include "ats_memory.h" #include "ats_exception.h" /* ****** ****** */ // HX: implemented in $ATSHOME/prelude/DATS/integer.dats extern ats_ptr_type atspre_tostrptr_llint (ats_llint_type i) ; extern ats_ptr_type atspre_tostrptr_ullint (ats_ullint_type u) ; /* ****** ****** */ /* signed integers */ /* ****** ****** */ ATSinline() ats_int_type atspre_int_of_char (ats_char_type c) { return c ; } ATSinline() ats_int_type atspre_int_of_schar (ats_schar_type c) { return c ; } ATSinline() ats_int_type atspre_int_of_uchar (ats_uchar_type c) { return c ; } // ATSinline() ats_int_type atspre_int_of_string (ats_ptr_type s) { return atoi((char*)s) ; } /* end of [atspre_int_of_string] */ // ATSinline() ats_int_type atspre_abs_int (ats_int_type i) { return (i >= 0 ? i : -i) ; } // end of [atspre_abs_int] ATSinline() ats_int_type atspre_neg_int (ats_int_type i) { return (-i) ; } ATSinline() ats_int_type atspre_succ_int (ats_int_type i) { return (i + 1) ; } ATSinline() ats_int_type atspre_pred_int (ats_int_type i) { return (i - 1) ; } ATSinline() ats_int_type atspre_add_int_int (ats_int_type i1, ats_int_type i2) { return (i1 + i2) ; } ATSinline() ats_int_type atspre_sub_int_int (ats_int_type i1, ats_int_type i2) { return (i1 - i2) ; } ATSinline() ats_int_type atspre_mul_int_int (ats_int_type i1, ats_int_type i2) { return (i1 * i2) ; } ATSinline() ats_int_type atspre_div_int_int (ats_int_type i1, ats_int_type i2) { return (i1 / i2) ; } ATSinline() ats_int_type atspre_mod_int_int (ats_int_type i1, ats_int_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_int_int (ats_int_type i1, ats_int_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_int_int (ats_int_type i1, ats_int_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_int_int (ats_int_type i1, ats_int_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_int_int (ats_int_type i1, ats_int_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_int_int (ats_int_type i1, ats_int_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_int_int (ats_int_type i1, ats_int_type i2) { return (i1 != i2) ; } // compare, max and min ATSinline() ats_int_type atspre_compare_int_int (ats_int_type i1, ats_int_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_int_type atspre_max_int_int (ats_int_type i1, ats_int_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_int_type atspre_min_int_int (ats_int_type i1, ats_int_type i2) { return (i1 <= i2) ? i1 : i2 ; } // // square, cube and pow functions // ATSinline() ats_int_type atspre_square_int (ats_int_type i) { return (i * i) ; } ATSinline() ats_int_type atspre_cube_int (ats_int_type i) { return (i * i * i) ; } ATSinline() ats_int_type atspre_pow_int_int1 (ats_int_type x, ats_int_type n) { ats_int_type res = 1; while (n > 0) { if (n % 2 > 0) { res *= x ; x = x * x ; } else { x = x * x ; } n = n >> 1 ; } return res ; } // greatest common division ATSinline() ats_int_type atspre_gcd_int_int (ats_int_type m0, ats_int_type n0) { int m, n, t ; if (m0 >= 0) m = m0; else m = -m0 ; if (n0 >= 0) n = n0; else n = -n0 ; while (m) { t = n % m ; n = m ; m = t ; } return n ; } // bitwise operations ATSinline() ats_int_type atspre_asl_int_int1 (ats_int_type i, ats_int_type n) { return i << n ; } ATSinline() ats_int_type atspre_asr_int_int1 (ats_int_type i, ats_int_type n) { return i >> n ; } // print functions ATSinline() ats_void_type atspre_fprint_int (ats_ptr_type out, ats_int_type i) { int n ; n = fprintf ((FILE*)out, "%d", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_int] failed.\n") ; } /* end of [if] */ return ; } ATSinline() ats_void_type atspre_print_int (ats_int_type i) { // atspre_stdout_view_get () ; atspre_fprint_int ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_int (ats_int_type i) { // atspre_stderr_view_get () ; atspre_fprint_int ((ats_ptr_type)stderr, i) ; // atspre_stderr_view_set () ; return ; } // ATSinline() ats_void_type atspre_fscan_int_exn ( ats_ptr_type inp, ats_ref_type r ) { int n ; n = fscanf ((FILE*)inp, "%d", (int*)r) ; if (n <= 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fscan_int_exn] failed.\n") ; } // end of [if] return ; } /* end of [atspre_fscan_int_exn] */ // ATSinline() ats_ptr_type atspre_tostrptr_int (ats_int_type i) { return atspre_tostrptr_llint (i) ; } // end of [atspre_tostrptr_int] /* ****** ****** */ /* unsigned integers */ /* ****** ****** */ ATSinline() ats_uint_type atspre_uint_of_char (ats_char_type c) { return ((unsigned char)c) ; } // end of [atspre_uint_of_char] ATSinline() ats_uint_type atspre_uint_of_uchar (ats_uchar_type c) { return ((unsigned char)c) ; } // end of [atspre_uint_of_uchar] ATSinline() ats_uint_type atspre_uint_of_double (ats_double_type d) { return (ats_uint_type)d ; } // end of [atspre_uint_of_double] ATSinline() ats_uint_type atspre_succ_uint (ats_uint_type i) { return (i + 1) ; } ATSinline() ats_uint_type atspre_pred_uint (ats_uint_type i) { return (i - 1) ; } ATSinline() ats_uint_type atspre_add_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 + i2) ; } // end of [atspre_add_uint_uint] ATSinline() ats_uint_type atspre_sub_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 - i2) ; } // end of [atspre_sub_uint_uint] ATSinline() ats_uint_type atspre_mul_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 * i2) ; } // end of [atspre_mul_uint_uint] ATSinline() ats_uint_type atspre_div_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 / i2) ; } // end of [atspre_div_uint_uint] ATSinline() ats_uint_type atspre_mod_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 % i2) ; } // end of [atspre_mod_uint_uint] ATSinline() ats_bool_type atspre_lt_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 < i2) ; } // end of [atspre_lt_uint_uint] ATSinline() ats_bool_type atspre_lte_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 <= i2) ; } // end of [atspre_lte_uint_uint] ATSinline() ats_bool_type atspre_gt_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 > i2) ; } // end of [atspre_gt_uint_uint] ATSinline() ats_bool_type atspre_gte_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 >= i2) ; } // end of [atspre_gte_uint_uint] ATSinline() ats_bool_type atspre_eq_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 == i2) ; } // end of [atspre_eq_uint_uint] ATSinline() ats_bool_type atspre_neq_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 != i2) ; } // end of [atspre_neq_uint_uint] // // compare, max and min // ATSinline() ats_int_type atspre_compare_uint_uint (ats_uint_type i1, ats_uint_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_uint_type atspre_max_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 >= i2 ? i1 : i2) ; } ATSinline() ats_uint_type atspre_min_uint_uint (ats_uint_type i1, ats_uint_type i2) { return (i1 <= i2 ? i1 : i2) ; } ATSinline() ats_uint_type atspre_square_uint (ats_uint_type u) { return (u * u) ; } ATSinline() ats_uint_type atspre_cube_uint (ats_uint_type u) { return (u * u * u) ; } /* ** bitwise operations */ ATSinline() ats_uint_type atspre_lnot_uint (ats_uint_type x) { return (~x) ; } ATSinline() ats_uint_type atspre_land_uint_uint (ats_uint_type x, ats_uint_type y) { return (x & y) ; } ATSinline() ats_uint_type atspre_lor_uint_uint (ats_uint_type x, ats_uint_type y) { return (x | y) ; } ATSinline() ats_uint_type atspre_lxor_uint_uint (ats_uint_type x, ats_uint_type y) { return (x ^ y) ; } /* ** logical shifting operations */ ATSinline() ats_uint_type atspre_lsl_uint_int1 ( ats_uint_type u, ats_int_type n ) { return (u << n) ; } // end of [atspre_lsl_uint_int1] ATSinline() ats_uint_type atspre_lsr_uint_int1 ( ats_uint_type u, ats_int_type n ) { return (u >> n) ; } // end of [atspre_lsr_uint_int1] #define atspre_lsl_uint_uint atspre_lsl_uint_int1 #define atspre_lsr_uint_uint atspre_lsr_uint_int1 /* ****** ****** */ /* ** print functions */ ATSinline() ats_void_type atspre_fprint_uint (ats_ptr_type out, ats_uint_type u) { int n = fprintf ((FILE*)out, "%u", u) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uint] failed.\n") ; } return ; } /* end of [atspre_fprint_uint] */ ATSinline() ats_void_type atspre_print_uint ( ats_uint_type u ) { // atspre_stdout_view_get () ; atspre_fprint_uint((ats_ptr_type)stdout, u) ; // atspre_stdout_view_set () ; return ; } /* end of [atspre_print_uint] */ ATSinline() ats_void_type atspre_prerr_uint ( ats_uint_type u ) { // atspre_stderr_view_get () ; atspre_fprint_uint((ats_ptr_type)stderr, u) ; // atspre_stderr_view_set () ; return ; } /* end of [atspre_prerr_uint] */ /* ** stringization */ ATSinline() ats_ptr_type atspre_tostrptr_uint (ats_uint_type u) { return atspre_tostrptr_ullint (u) ; } // end of [atspre_tostrptr_uint] /* ****** ****** */ #define atspre_int1_of_string atspre_int_of_string #define atspre_iabs atspre_abs_int #define atspre_ineg atspre_neg_int #define atspre_isucc atspre_succ_int #define atspre_ipred atspre_pred_int #define atspre_iadd atspre_add_int_int #define atspre_isub atspre_sub_int_int #define atspre_imul atspre_mul_int_int #define atspre_imul1 atspre_mul_int_int #define atspre_imul2 atspre_mul_int_int #define atspre_idiv atspre_div_int_int #define atspre_idiv1 atspre_div_int_int #define atspre_nmul atspre_mul_int_int #define atspre_ndiv atspre_div_int_int // HX: there is no [ndiv1] #define atspre_ndiv2 atspre_div_int_int #define atspre_nmod atspre_mod_int_int #define atspre_nmod1 atspre_mod_int_int #define atspre_nmod2 atspre_mod_int_int #define atspre_ilt atspre_lt_int_int #define atspre_ilte atspre_lte_int_int #define atspre_igt atspre_gt_int_int #define atspre_igte atspre_gte_int_int #define atspre_ieq atspre_eq_int_int #define atspre_ineq atspre_neq_int_int #define atspre_icompare atspre_compare_int_int #define atspre_imax atspre_max_int_int #define atspre_imin atspre_min_int_int #define atspre_ipow atspre_pow_int_int1 #define atspre_npow atspre_pow_int_int1 ATSinline() ats_int_type atspre_ihalf (ats_int_type n) { return (n / 2) ; } ATSinline() ats_int_type atspre_nhalf (ats_int_type n) { return (n >> 1) ; } /* ****** ****** */ #define atspre_uadd atspre_add_uint_uint #define atspre_usub atspre_sub_uint_uint #define atspre_umul atspre_mul_uint_uint #define atspre_udiv atspre_div_uint_uint #define atspre_umod atspre_mod_uint_uint // HX: there is no [nmod1] #define atspre_umod2 atspre_mod_uint_uint // ATSinline() ats_int_type atspre_uimod ( ats_uint_type u1, ats_int_type i2 ) { return (u1 % ((ats_uint_type)i2)) ; } /* end of [atspre_uimod] */ #define atspre_uimod2 ats_uimod #define atspre_ult atspre_lt_uint_uint #define atspre_ulte atspre_lte_uint_uint #define atspre_ugt atspre_gt_uint_uint #define atspre_ugte atspre_gte_uint_uint #define atspre_ueq atspre_eq_uint_uint #define atspre_uneq atspre_neq_uint_uint #define atspre_ucompare atspre_compare_uint_uint #define atspre_umax atspre_max_uint_uint #define atspre_umin atspre_min_uint_uint /* ****** ****** */ /* signed long integers */ /* ****** ****** */ ATSinline() ats_lint_type atspre_lint_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_lint (ats_lint_type li) { return li ; } /* ****** ****** */ ATSinline() ats_lint_type atspre_lint_of_uint (ats_uint_type u) { return u ; } ATSinline() ats_uint_type atspre_uint_of_lint (ats_lint_type li) { return li ; } /* ****** ****** */ ATSinline() ats_lint_type atspre_lint_of_string (ats_ptr_type s) { return atol((char*)s) ; } // end of [atspre_lint_of_string] // arithmetic functions and comparison functions ATSinline() ats_lint_type atspre_abs_lint (ats_lint_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_lint_type atspre_neg_lint (ats_lint_type i) { return (-i) ; } ATSinline() ats_lint_type atspre_succ_lint (ats_lint_type i) { return (i + 1) ; } ATSinline() ats_lint_type atspre_pred_lint (ats_lint_type i) { return (i - 1) ; } ATSinline() ats_lint_type atspre_add_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 + i2) ; } ATSinline() ats_lint_type atspre_sub_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 - i2) ; } ATSinline() ats_lint_type atspre_mul_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 * i2) ; } ATSinline() ats_lint_type atspre_div_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 / i2) ; } ATSinline() ats_lint_type atspre_mod_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 != i2) ; } // compare, max and min ATSinline() ats_int_type atspre_compare_lint_lint (ats_lint_type i1, ats_lint_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_lint_type atspre_max_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 >= i2 ? i1 : i2) ; } ATSinline() ats_lint_type atspre_min_lint_lint (ats_lint_type i1, ats_lint_type i2) { return (i1 <= i2 ? i1 : i2) ; } // print functions ATSinline() ats_void_type atspre_fprint_lint (ats_ptr_type out, ats_lint_type i) { int n ; n = fprintf ((FILE*)out, "%li", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_lint] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_lint (ats_lint_type i) { // atspre_stdout_view_get () ; atspre_fprint_lint ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_lint (ats_lint_type i) { // atspre_stderr_view_get () ; atspre_fprint_lint ((ats_ptr_type)stderr, i) ; // atspre_stderr_view_set () ; return ; } // ATSinline() ats_ptr_type atspre_tostrptr_lint (ats_lint_type i) { return atspre_tostrptr_llint (i) ; } // end of [atspre_tostrptr_lint] /* ****** ****** */ /* unsigned long integers */ /* ****** ****** */ ATSinline() ats_ulint_type atspre_ulint_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_ulint (ats_ulint_type ul) { return ul ; } // ATSinline() ats_ulint_type atspre_ulint_of_uint (ats_uint_type u) { return u ; } ATSinline() ats_uint_type atspre_uint_of_ulint (ats_ulint_type ul) { return ul ; } /* ****** ****** */ ATSinline() ats_ulint_type atspre_succ_ulint (ats_ulint_type i) { return (i + 1) ; } ATSinline() ats_ulint_type atspre_pred_ulint (ats_ulint_type i) { return (i - 1) ; } ATSinline() ats_ulint_type atspre_add_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 + i2) ; } ATSinline() ats_ulint_type atspre_sub_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 - i2) ; } ATSinline() ats_ulint_type atspre_mul_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 * i2) ; } ATSinline() ats_ulint_type atspre_div_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 / i2) ; } ATSinline() ats_ulint_type atspre_mod_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 != i2) ; } // // compare, max and min // ATSinline() ats_int_type atspre_compare_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_ulint_type atspre_max_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 >= i2 ? i1 : i2) ; } ATSinline() ats_ulint_type atspre_min_ulint_ulint (ats_ulint_type i1, ats_ulint_type i2) { return (i1 <= i2 ? i1 : i2) ; } // // bitwise operations // ATSinline() ats_ulint_type atspre_lnot_ulint (ats_ulint_type x) { return (~x) ; } ATSinline() ats_ulint_type atspre_land_ulint_ulint (ats_ulint_type x, ats_ulint_type y) { return (x & y) ; } ATSinline() ats_ulint_type atspre_lor_ulint_ulint (ats_ulint_type x, ats_ulint_type y) { return (x | y) ; } ATSinline() ats_ulint_type atspre_lxor_ulint_ulint (ats_ulint_type x, ats_ulint_type y) { return (x ^ y) ; } ATSinline() ats_ulint_type atspre_lsl_ulint_int1 (ats_ulint_type i, ats_int_type n) { return i << n ; } ATSinline() ats_ulint_type atspre_lsr_ulint_int1 (ats_ulint_type i, ats_int_type n) { return i >> n ; } // // print functions // ATSinline() ats_void_type atspre_fprint_ulint (ats_ptr_type out, ats_ulint_type i) { int n = fprintf ((FILE*)out, "%lu", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_ulint] failed.\n") ; } return ; } // end of [atspre_fprint_ulint] ATSinline() ats_void_type atspre_print_ulint (ats_ulint_type i) { // atspre_stdout_view_get () ; atspre_fprint_ulint ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_ulint] ATSinline() ats_void_type atspre_prerr_ulint (ats_ulint_type i) { // atspre_stderr_view_get () ; atspre_fprint_ulint ((ats_ptr_type)stderr, i) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_ulint] // ATSinline() ats_ptr_type atspre_tostrptr_ulint (ats_ulint_type i) { return atspre_tostrptr_ullint (i) ; } // end of [atspre_tostrptr_ulint] /* ****** ****** */ // // long long integers // /* ****** ****** */ ATSinline() ats_llint_type atspre_llint_of_int (ats_int_type i) { return ((ats_llint_type)i) ; } // end of [atspre_llint_of_int] ATSinline() ats_int_type atspre_int_of_llint (ats_llint_type lli) { return ((ats_int_type)lli) ; } // end of [atspre_int_of_llint] #if (0) // // HX: defined in $ATSHOME/prelude/CATS/float.cats // ATSinline() ats_llint_type atspre_llint_of_double (ats_double_type d) { return ((ats_llint_type)d) ; } // end of [atspre_llint_of_double] #endif // end of [#if 0] ATSinline() ats_llint_type atspre_llint_of_string (ats_ptr_type s) { return atoll((char*)s) ; } // end of [atspre_llint_of_string] // // arithmetic functions and comparison functions // ATSinline() ats_llint_type atspre_abs_llint (ats_llint_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_llint_type atspre_neg_llint (ats_llint_type i) { return (-i) ; } ATSinline() ats_llint_type atspre_succ_llint (ats_llint_type i) { return (i + 1) ; } ATSinline() ats_llint_type atspre_pred_llint (ats_llint_type i) { return (i - 1) ; } ATSinline() ats_llint_type atspre_add_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 + i2) ; } ATSinline() ats_llint_type atspre_sub_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 - i2) ; } ATSinline() ats_llint_type atspre_mul_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 * i2) ; } ATSinline() ats_llint_type atspre_div_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 / i2) ; } ATSinline() ats_llint_type atspre_mod_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_llint_llint (ats_llint_type i1, ats_llint_type i2) { return (i1 != i2) ; } // compare, max and min ATSinline() ats_int_type atspre_compare_llint_llint (ats_llint_type i1, ats_llint_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_llint_type atspre_max_llint_llint ( ats_llint_type i1, ats_llint_type i2 ) { return (i1 >= i2 ? i1 : i2) ; } // end of [atspre_max_llint_llint] ATSinline() ats_llint_type atspre_min_llint_llint ( ats_llint_type i1, ats_llint_type i2 ) { return (i1 <= i2 ? i1 : i2) ; } // end of [atspre_min_llint_llint] // // print functions // ATSinline() ats_void_type atspre_fprint_llint ( ats_ptr_type out, ats_llint_type i ) { int n = fprintf ((FILE*)out, "%lli", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_llint] failed.\n") ; } return ; } // end of [atspre_fprint_llint] ATSinline() ats_void_type atspre_print_llint (ats_llint_type lli) { // atspre_stdout_view_get () ; atspre_fprint_llint ((ats_ptr_type)stdout, lli) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_llint] ATSinline() ats_void_type atspre_prerr_llint (ats_llint_type lli) { // atspre_stderr_view_get () ; atspre_fprint_llint ((ats_ptr_type)stderr, lli) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_llint] /* ****** ****** */ // /* unsigned long long integers */ // /* ****** ****** */ ATSinline() ats_ullint_type atspre_ullint_of_int (ats_int_type i) { return ((ats_ullint_type)i) ; } // end of [atspre_ullint_of_int] ATSinline() ats_ullint_type atspre_ullint_of_uint (ats_uint_type u) { return ((ats_ullint_type)u) ; } // end of [atspre_ullint_of_uint] #if (0) // // HX: defined in $ATSHOME/prelude/CATS/float.cats // ATSinline() ats_ullint_type atspre_ullint_of_double (ats_double_type d) { return ((ats_ullint_type)d) ; } // end of [atspre_ullint_of_double] #endif // end of [#if 0] /* ****** ****** */ ATSinline() ats_ullint_type atspre_succ_ullint (ats_ullint_type i) { return (i + 1) ; } ATSinline() ats_ullint_type atspre_pred_ullint (ats_ullint_type i) { return (i - 1) ; } ATSinline() ats_ullint_type atspre_add_ullint_ullint ( ats_ullint_type i1, ats_ullint_type i2 ) { return (i1 + i2) ; } // end of [atspre_add_ullint_ullint] ATSinline() ats_ullint_type atspre_sub_ullint_ullint ( ats_ullint_type i1, ats_ullint_type i2 ) { return (i1 - i2) ; } // end of [atspre_sub_ullint_ullint] ATSinline() ats_ullint_type atspre_mul_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 * i2) ; } ATSinline() ats_ullint_type atspre_div_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 / i2) ; } ATSinline() ats_ullint_type atspre_mod_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 != i2) ; } // // compare, max and min // ATSinline() ats_int_type atspre_compare_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } // end of [atspre_compare_ullint_ullint] ATSinline() ats_ullint_type atspre_max_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 >= i2 ? i1 : i2) ; } ATSinline() ats_ullint_type atspre_min_ullint_ullint (ats_ullint_type i1, ats_ullint_type i2) { return (i1 <= i2 ? i1 : i2) ; } // // print functions // ATSinline() ats_void_type atspre_fprint_ullint ( ats_ptr_type out, ats_ullint_type i ) { int n = fprintf ((FILE*)out, "%llu", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_ullint] failed.\n") ; } return ; } // end of [atspre_fprint_ullint] ATSinline() ats_void_type atspre_print_ullint (ats_ullint_type i) { // atspre_stdout_view_get () ; atspre_fprint_ullint ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_ullint] ATSinline() ats_void_type atspre_prerr_ullint (ats_ullint_type i) { // atspre_stderr_view_get () ; atspre_fprint_ullint ((ats_ptr_type)stderr, i) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_ullint] /* ****** ****** */ #endif /* ATS_PRELUDE_INTEGER_CATS */ /* end of [integer.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/sizetype.cats0000664000175000017500000003436612223166162020733 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_SIZETYPE_CATS #define ATS_PRELUDE_SIZETYPE_CATS /* ****** ****** */ #include /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ // // unsigned size type // /* ****** ****** */ extern void exit (int) ; // HX: see [stdlib.h] /* ****** ****** */ ATSinline() ats_size_type atspre_size_of_int (ats_int_type i) { if (i < 0) { fprintf (stderr, "[atspre_size_of_int(%i)] failed\n", i) ; exit (1) ; } /* end of [if] */ return ((ats_size_type)i) ; } // end of [atspre_size_of_int] #define atspre_int_of_size atspre_int1_of_size1 #define atspre_size_of_int1 atspre_size1_of_int1 #define atspre_uint_of_size atspre_uint1_of_size1 #define atspre_size_of_uint atspre_size1_of_uint1 /* ****** ****** */ #define atspre_add_size_int atspre_add_size1_int1 #define atspre_add_size_size atspre_add_size1_size1 #define atspre_sub_size_int atspre_sub_size1_int1 #define atspre_sub_size_size atspre_sub_size1_size1 #define atspre_mul_int_size atspre_mul_int1_size1 #define atspre_mul_size_int atspre_mul_size1_int1 #define atspre_mul_size_size atspre_mul_size1_size1 #define atspre_div_size_int atspre_div_size1_int1 #define atspre_div_size_size atspre_div_size1_size1 #define atspre_mod_size_int atspre_mod_size1_int1 #define atspre_mod_size_size atspre_mod_size1_size1 #define atspre_lt_size_size atspre_lt_size1_size1 #define atspre_lte_size_size atspre_lte_size1_size1 #define atspre_gt_size_int atspre_gt_size1_int1 #define atspre_gt_size_size atspre_gt_size1_size1 #define atspre_gte_size_int atspre_gte_size1_int1 #define atspre_gte_size_size atspre_gte_size1_size1 #define atspre_eq_size_int atspre_eq_size1_int1 #define atspre_eq_size_size atspre_eq_size1_size1 #define atspre_neq_size_int atspre_neq_size1_int1 #define atspre_neq_size_size atspre_neq_size1_size1 #define atspre_max_size_size atspre_max_size1_size1 #define atspre_min_size_size atspre_min_size1_size1 /* ****** ****** */ ATSinline() ats_size_type atspre_land_size_size (ats_size_type x, ats_size_type y) { return (x & y) ; } ATSinline() ats_size_type atspre_lor_size_size (ats_size_type x, ats_size_type y) { return (x | y) ; } ATSinline() ats_size_type atspre_lxor_size_size (ats_size_type x, ats_size_type y) { return (x ^ y) ; } /* ****** ****** */ ATSinline() ats_size_type atspre_lsl_size_int1 (ats_size_type sz, ats_int_type n) { return (sz << n) ; } ATSinline() ats_size_type atspre_lsr_size_int1 (ats_size_type sz, ats_int_type n) { return (sz >> n) ; } /* ****** ****** */ // print functions ATSinline() ats_void_type atspre_fprint_size ( ats_ptr_type out, ats_size_type sz ) { fprintf ((FILE*)out, "%lu", (ats_ulint_type)sz) ; return ; } // end of [atspre_fprint_size] ATSinline() ats_void_type atspre_print_size (ats_size_type sz) { // atspre_stdout_view_get () ; atspre_fprint_size ((ats_ptr_type)stdout, sz) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_size (ats_size_type sz) { // atspre_stderr_view_get () ; atspre_fprint_size ((ats_ptr_type)stderr, sz) ; // atspre_stderr_view_set () ; return ; } /* ****** ****** */ // // unsigned size type (indexed) // /* ****** ****** */ ATSinline() ats_int_type atspre_int1_of_size1 (ats_size_type sz) { if (INT_MAX < sz) { fprintf (stderr, "[atspre_int_of_size(%lu)] failed\n", (ats_ulint_type)sz) ; exit (1) ; } /* end of [if] */ return ((ats_int_type)sz) ; } // end of [atspre_int1_of_size1] ATSinline() ats_uint_type atspre_uint1_of_size1 (ats_size_type sz) { if (UINT_MAX < sz) { fprintf (stderr, "[atspre_uint_of_size(%lu)] failed\n", (ats_ulint_type)sz) ; exit (1) ; } /* end of [if] */ return ((ats_uint_type)sz) ; } // end of [atspre_uint1_of_size1] /* ****** ****** */ ATSinline() ats_size_type atspre_size1_of_int1 (ats_int_type i) { return (ats_size_type)i ; } ATSinline() ats_size_type atspre_size1_of_uint1 (ats_uint_type u) { return (ats_size_type)u ; } ATSinline() ats_size_type atspre_size1_of_ptrdiff1 (ats_ptrdiff_type x) { return (ats_size_type)x ; } /* ****** ****** */ ATSinline() ats_size_type atspre_succ_size1 (ats_size_type sz) { return (sz + 1) ; } ATSinline() ats_size_type atspre_pred_size1 (ats_size_type sz) { return (sz - 1) ; } /* ****** ****** */ ATSinline() ats_size_type atspre_add_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 + i2) ; } ATSinline() ats_size_type atspre_add_size1_size1 ( ats_size_type sz1, ats_size_type sz2 ) { return (sz1 + sz2) ; } // end of [atspre_add_size1_size1] /* ****** ****** */ ATSinline() ats_size_type atspre_sub_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 - i2) ; } ATSinline() ats_size_type atspre_sub_size1_size1 ( ats_size_type sz1, ats_size_type sz2 ) { return (sz1 - sz2) ; } // end of [atspre_sub_size1_size1] /* ****** ****** */ ATSinline() ats_size_type atspre_mul_int1_size1 ( ats_int_type i1, ats_size_type sz2 ) { return (i1 * sz2) ; } // end of [atspre_mul_int1_size1] ATSinline() ats_size_type atspre_mul_size1_int1 ( ats_size_type sz1, ats_int_type i2 ) { return (sz1 * i2) ; } // end of [atspre_mul_size1_int1] ATSinline() ats_size_type atspre_mul_size1_size1 ( ats_size_type sz1, ats_size_type sz2 ) { return (sz1 * sz2) ; } // end of [atspre_mul_size1_size1] #define atspre_mul1_size1_size1 atspre_mul_size1_size1 #define atspre_mul2_size1_size1 atspre_mul_size1_size1 /* ****** ****** */ ATSinline() ats_size_type atspre_div_size1_int1 ( ats_size_type sz1, ats_int_type i2 ) { return (sz1 / i2) ; } // end of [atspre_div_size1_int1] #define atspre_div2_size1_int1 atspre_div_size1_int1 ATSinline() ats_size_type atspre_div_size1_size1 ( ats_size_type sz1, ats_size_type sz2 ) { return (sz1 / sz2) ; } // end of [atspre_div_size1_size1] #define atspre_div2_size1_size1 atspre_div_size1_size1 /* ****** ****** */ ATSinline() ats_int_type atspre_mod_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 % i2) ; } // end of [atspre_mod_size1_int1] #define atspre_mod1_size1_int1 atspre_mod_size1_int1 #define atspre_mod2_size1_int1 atspre_mod_size1_int1 ATSinline() ats_size_type atspre_mod_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 % sz2) ; } // end of [atspre_mod_size1_size1] #define atspre_mod1_size1_size1 atspre_mod_size1_size1 #define atspre_mod2_size1_size1 atspre_mod_size1_size1 /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 < sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_size1_size1] ATSinline() ats_bool_type atspre_lt_int1_size1 (ats_int_type i1, ats_size_type sz2) { return ((ats_size_type)i1 < sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_int1_size1] ATSinline() ats_bool_type atspre_lt_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 < (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_size1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_lte_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 <= sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_size1_size1] ATSinline() ats_bool_type atspre_lte_int1_size1 (ats_int_type i1, ats_size_type sz2) { return ((ats_size_type)i1 <= sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_int1_size1] ATSinline() ats_bool_type atspre_lte_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 <= (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_size1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_gt_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 > sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_size1_size1] ATSinline() ats_bool_type atspre_gt_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 > (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_size1_int1] ATSinline() ats_bool_type atspre_gte_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 >= sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_size1_size1] ATSinline() ats_bool_type atspre_gte_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 >= (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_size1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_eq_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 == sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_size1_size1] ATSinline() ats_bool_type atspre_eq_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 == (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_size1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_neq_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 != sz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_neq_size1_size1] ATSinline() ats_bool_type atspre_neq_size1_int1 (ats_size_type sz1, ats_int_type i2) { return (sz1 != (ats_size_type)i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_neq_size1_int1] /* ****** ****** */ ATSinline() ats_size_type atspre_max_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 >= sz2 ? sz1 : sz2) ; } // end of [atspre_max_size1_size1] ATSinline() ats_size_type atspre_min_size1_size1 (ats_size_type sz1, ats_size_type sz2) { return (sz1 <= sz2 ? sz1 : sz2) ; } // end of [atspre_min_size1_size1] /* ****** ****** */ // // signed size type // /* ****** ****** */ #define atspre_int_of_ssize atspre_int1_of_ssize1 #define atspre_ssize_of_int atspre_ssize1_of_int1 #define atspre_add_ssize_ssize atspre_add_ssize1_ssize1 #define atspre_sub_ssize_ssize atspre_sub_ssize1_ssize1 #define atspre_mul_ssize_ssize atspre_mul_ssize1_ssize1 #define atspre_div_ssize_ssize atspre_div_ssize1_ssize1 /* ****** ****** */ // // signed size type (indexed) // /* ****** ****** */ ATSinline() ats_int_type atspre_int1_of_ssize1 (ats_ssize_type ssz) { if (INT_MAX < ssz || ssz < INT_MIN) { fprintf (stderr, "exit(ATS): [atspre_int1_of_ssize1(%li)] failed\n", (ats_lint_type)ssz ) ; exit (1) ; } /* end of [if] */ return (ats_int_type)ssz ; } // end of [atspre_int1_of_ssize1] ATSinline() ats_ssize_type atspre_ssize1_of_int1 (ats_int_type i) { return (ats_ssize_type)i ; } // end of [atspre_ssize1_of_int1] /* ****** ****** */ ATSinline() ats_ssize_type atspre_add_ssize1_ssize1 ( ats_ssize_type i, ats_ssize_type j ) { return (i + j) ; } // end of [atspre_add_ssize1_ssize1] ATSinline() ats_ssize_type atspre_sub_ssize1_ssize1 ( ats_ssize_type i, ats_ssize_type j ) { return (i - j) ; } // end of [atspre_sub_ssize1_ssize1] ATSinline() ats_ssize_type atspre_mul_ssize1_ssize1 ( ats_ssize_type i, ats_ssize_type j ) { return (i * j) ; } // end of [atspre_mul_ssize1_ssize1] ATSinline() ats_ssize_type atspre_div_ssize1_ssize1 ( ats_ssize_type i, ats_ssize_type j ) { return (i / j) ; } // end of [atspre_div_ssize1_ssize1] /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_ssize1_int1 (ats_ssize_type ssz1, ats_int_type i2) { return (ssz1 < i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_ssize1_int1] ATSinline() ats_bool_type atspre_lte_ssize1_int1 (ats_ssize_type ssz1, ats_int_type i2) { return (ssz1 <= i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_ssize1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_gt_ssize1_int1 (ats_ssize_type ssz1, ats_int_type i2) { return (ssz1 > i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_ssize1_int1] ATSinline() ats_bool_type atspre_gte_ssize1_int1 (ats_ssize_type ssz1, ats_int_type i2) { return (ssz1 >= i2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_ssize1_int1] /* ****** ****** */ ATSinline() ats_bool_type atspre_eq_ssize1_ssize1 (ats_ssize_type ssz1, ats_ssize_type ssz2) { return (ssz1 == ssz2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_ssize1_ssize1] ATSinline() ats_bool_type atspre_neq_ssize1_ssize1 (ats_ssize_type ssz1, ats_ssize_type ssz2) { return (ssz1 != ssz2 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_eq_ssize1_ssize1] */ /* ****** ****** */ // print functions ATSinline() ats_void_type atspre_fprint_ssize ( ats_ptr_type out, ats_ssize_type ssz ) { fprintf ((FILE*)out, "%li", (ats_lint_type)ssz) ; return ; } // end of [atspre_fprint_ssize] ATSinline() ats_void_type atspre_print_ssize (ats_ssize_type ssz) { // atspre_stdout_view_get () ; atspre_fprint_ssize ((ats_ptr_type)stdout, ssz) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_ssize] ATSinline() ats_void_type atspre_prerr_ssize (ats_size_type ssz) { // atspre_stderr_view_get () ; atspre_fprint_ssize ((ats_ptr_type)stderr, ssz) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_ssize] /* ****** ****** */ #endif /* ATS_PRELUDE_SIZETYPE_CATS */ /* end of [sizetype.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/byte.cats0000664000175000017500000001322712223166162020013 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_BYTE_CATS #define ATS_PRELUDE_BYTE_CATS /* ****** ****** */ #include /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ extern ats_void_type ats_exit_errmsg (ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ /* // // HX: these are now casting functions: // ATSinline() ats_byte_type atspre_byte_of_char (ats_char_type c) { return c ; } ATSinline() ats_char_type atspre_char_of_byte (ats_byte_type b) { return b ; } */ /* ****** ****** */ ATSinline() ats_byte_type atspre_byte_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_byte (ats_byte_type b) { return b ; } /* ****** ****** */ ATSinline() ats_byte_type atspre_byte_of_uint (ats_uint_type u) { return u ; } ATSinline() ats_uint_type atspre_uint_of_byte (ats_byte_type b) { return b ; } /* ****** ****** */ // arithmetic operations ATSinline() ats_byte_type atspre_succ_byte(ats_byte_type i) { return (i + 1) ; } ATSinline() ats_byte_type atspre_pred_byte(ats_byte_type i) { return (i - 1) ; } ATSinline() ats_byte_type atspre_add_byte_byte(ats_byte_type i1, ats_byte_type i2) { return (i1 + i2) ; } ATSinline() ats_byte_type atspre_sub_byte_byte(ats_byte_type i1, ats_byte_type i2) { return (i1 - i2) ; } ATSinline() ats_byte_type atspre_mul_byte_byte(ats_byte_type i1, ats_byte_type i2) { return (i1 * i2) ; } ATSinline() ats_byte_type atspre_div_byte_byte(ats_byte_type i1, ats_byte_type i2) { return (i1 / i2) ; } /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_byte_byte(ats_byte_type b1, ats_byte_type b2) { return (b1 < b2) ; } ATSinline() ats_bool_type atspre_lte_byte_byte(ats_byte_type b1, ats_byte_type b2) { return (b1 <= b2) ; } ATSinline() ats_bool_type atspre_gt_byte_byte(ats_byte_type b1, ats_byte_type b2) { return (b1 > b2) ; } ATSinline() ats_bool_type atspre_gte_byte_byte(ats_byte_type b1, ats_byte_type b2) { return (b1 >= b2) ; } /* ****** ****** */ ATSinline() ats_bool_type atspre_eq_byte_byte (ats_byte_type b1, ats_byte_type b2) { return (b1 == b2) ; } // end of [atspre_eq_byte_byte] ATSinline() ats_bool_type atspre_neq_byte_byte (ats_byte_type b1, ats_byte_type b2) { return (b1 != b2) ; } // end of [atspre_neq_byte_byte] // // bitwise operations // ATSinline() ats_byte_type atspre_lnot_byte(ats_byte_type b) { return (~b) ; } ATSinline() ats_byte_type atspre_land_byte_byte (ats_byte_type b1, ats_byte_type b2) { return (b1 & b2) ; } // end of [atspre_land_byte_byte] ATSinline() ats_byte_type atspre_lor_byte_byte (ats_byte_type b1, ats_byte_type b2) { return (b1 | b2) ; } // end of [atspre_lor_byte_byte] ATSinline() ats_byte_type atspre_lxor_byte_byte (ats_byte_type b1, ats_byte_type b2) { return (b1 ^ b2) ; } // end of [atspre_lxor_byte_byte] ATSinline() ats_byte_type atspre_lsl_byte_int1 (ats_byte_type b, ats_int_type n) { return (b << n) ; } // end of [atspre_lsl_byte_int1] ATSinline() ats_byte_type atspre_lsr_byte_int1 (ats_byte_type b, ats_int_type n) { return (b >> n) ; } // end of [atspre_lsr_byte_int1] // // print functions // ATSinline() ats_void_type atspre_fprint_byte ( const ats_ptr_type out, const ats_byte_type b ) { /* int n = fputc (b, (FILE *)out) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"Exit: [fprint_byte] failed.\n") ; } // end of [if] */ (void)fputc (b, (FILE *)out) ; return ; } // end of [atspre_fprint_byte] ATSinline() ats_void_type atspre_print_byte (const ats_byte_type c) { // atspre_stdout_view_get () ; atspre_fprint_byte((ats_ptr_type)stdout, c) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_byte] ATSinline() ats_void_type atspre_prerr_byte (const ats_byte_type c) { // atspre_stderr_view_get () ; atspre_fprint_byte((ats_ptr_type)stderr, c) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_byte] /* ****** ****** */ #define atspre_lt_byte1_byte1 atspre_lt_byte_byte #define atspre_lte_byte1_byte1 atspre_lte_byte_byte #define atspre_gt_byte1_byte1 atspre_gt_byte_byte #define atspre_gte_byte1_byte1 atspre_gte_byte_byte #define atspre_eq_byte1_byte1 atspre_eq_byte_byte #define atspre_neq_byte1_byte1 atspre_neq_byte_byte /* ****** ****** */ #endif /* ATS_PRELUDE_BYTE_CATS */ /* end of [byte.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/integer_fixed.cats0000664000175000017500000006322512223166162021667 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_INTEGER_FIXED_CATS #define ATS_PRELUDE_INTEGER_FIXED_CATS /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ extern ats_void_type ats_exit_errmsg (ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ /* signed and unsigned integers of fixed sizes */ /* ****** ****** */ // signed integer of size 8bit ATSinline() ats_int8_type atspre_int8_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_int8 (ats_int8_type i) { return i ; } // ------ ------ ATSinline() ats_int8_type atspre_abs_int8 (ats_int8_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_int8_type atspre_neg_int8 (ats_int8_type i) { return (-i) ; } ATSinline() ats_int8_type atspre_succ_int8 (ats_int8_type i) { return (i + 1) ; } ATSinline() ats_int8_type atspre_pred_int8 (ats_int8_type i) { return (i - 1) ; } ATSinline() ats_int8_type atspre_add_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 + i2) ; } ATSinline() ats_int8_type atspre_sub_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 - i2) ; } ATSinline() ats_int8_type atspre_mul_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 * i2) ; } ATSinline() ats_int8_type atspre_div_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 / i2) ; } ATSinline() ats_int8_type atspre_mod_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_int8_int8 (ats_int8_type i1, ats_int8_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_int8_type atspre_max_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_int8_type atspre_min_int8_int8 (ats_int8_type i1, ats_int8_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_int8 (ats_ptr_type out, ats_int8_type i) { int n = fprintf ((FILE*)out, "%hhd", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_int8] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_int8 (ats_int8_type i) { // atspre_stdout_view_get () ; atspre_fprint_int8 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_int8 (ats_int8_type i) { atspre_stderr_view_get () ; atspre_fprint_int8 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ // unsigned integer of size 8bit ATSinline() ats_uint8_type atspre_uint8_of_uint (ats_uint_type i) { return i ; } ATSinline() ats_uint_type atspre_uint_of_uint8 (ats_uint8_type i) { return i ; } // ------ ------ ATSinline() ats_uint8_type atspre_succ_uint8 (ats_uint8_type i) { return (i + 1) ; } ATSinline() ats_uint8_type atspre_pred_uint8 (ats_uint8_type i) { return (i - 1) ; } ATSinline() ats_uint8_type atspre_add_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 + i2) ; } ATSinline() ats_uint8_type atspre_sub_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 - i2) ; } ATSinline() ats_uint8_type atspre_mul_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 * i2) ; } ATSinline() ats_uint8_type atspre_div_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 / i2) ; } ATSinline() ats_uint8_type atspre_mod_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 % i2) ; } // ------ ------ // comparison operations ATSinline() ats_bool_type atspre_lt_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_uint8_type atspre_max_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_uint8_type atspre_min_uint8_uint8 (ats_uint8_type i1, ats_uint8_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_uint8 (ats_ptr_type out, ats_uint8_type i) { int n = fprintf ((FILE*)out, "%hhu", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uint8] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_uint8 (ats_uint8_type i) { // atspre_stdout_view_get () ; atspre_fprint_uint8 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_uint8 (ats_uint8_type i) { atspre_stderr_view_get () ; atspre_fprint_uint8 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ // signed integer of size 16bit ATSinline() ats_int16_type atspre_int16_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_int16 (ats_int16_type i) { return i ; } // ------ ------ ATSinline() ats_int16_type atspre_abs_int16 (ats_int16_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_int16_type atspre_neg_int16 (ats_int16_type i) { return (-i) ; } ATSinline() ats_int16_type atspre_succ_int16 (ats_int16_type i) { return (i + 1) ; } ATSinline() ats_int16_type atspre_pred_int16 (ats_int16_type i) { return (i - 1) ; } ATSinline() ats_int16_type atspre_add_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 + i2) ; } ATSinline() ats_int16_type atspre_sub_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 - i2) ; } ATSinline() ats_int16_type atspre_mul_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 * i2) ; } ATSinline() ats_int16_type atspre_div_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 / i2) ; } ATSinline() ats_int16_type atspre_mod_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_int16_int16 (ats_int16_type i1, ats_int16_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_int16_type atspre_max_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_int16_type atspre_min_int16_int16 (ats_int16_type i1, ats_int16_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_int16 (ats_ptr_type out, ats_int16_type i) { int n = fprintf ((FILE*)out, "%d", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_int16] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_int16 (ats_int16_type i) { // atspre_stdout_view_get () ; atspre_fprint_int16 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_int16 (ats_int16_type i) { atspre_stderr_view_get () ; atspre_fprint_int16 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ // // unsigned integer of size 16bit // ATSinline() ats_uint16_type atspre_uint16_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_uint16 (ats_uint16_type i) { return i ; } ATSinline() ats_uint16_type atspre_uint16_of_uint (ats_uint_type i) { return i ; } ATSinline() ats_uint_type atspre_uint_of_uint16 (ats_uint16_type i) { return i ; } // ------ ------ ATSinline() ats_uint16_type atspre_succ_uint16 (ats_uint16_type i) { return (i + 1) ; } ATSinline() ats_uint16_type atspre_pred_uint16 (ats_uint16_type i) { return (i - 1) ; } ATSinline() ats_uint16_type atspre_add_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 + i2) ; } ATSinline() ats_uint16_type atspre_sub_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 - i2) ; } ATSinline() ats_uint16_type atspre_mul_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 * i2) ; } ATSinline() ats_uint16_type atspre_div_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 / i2) ; } ATSinline() ats_uint16_type atspre_mod_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 % i2) ; } // ------ ------ // comparison operations ATSinline() ats_bool_type atspre_lt_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_uint16_type atspre_max_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_uint16_type atspre_min_uint16_uint16 (ats_uint16_type i1, ats_uint16_type i2) { return (i1 <= i2) ? i1 : i2 ; } // // print functions // ATSinline() ats_void_type atspre_fprint_uint16 (ats_ptr_type out, ats_uint16_type i) { int n = fprintf ((FILE*)out, "%hu", i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uint16] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_uint16 (ats_uint16_type i) { // atspre_stdout_view_get () ; atspre_fprint_uint16 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_uint16 (ats_uint16_type i) { atspre_stderr_view_get () ; atspre_fprint_uint16 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ // signed integer of size 32bit ATSinline() ats_int32_type atspre_int32_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_int32 (ats_int32_type i) { return i ; } // ------ ------ ATSinline() ats_int32_type atspre_abs_int32 (ats_int32_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_int32_type atspre_neg_int32 (ats_int32_type i) { return (-i) ; } ATSinline() ats_int32_type atspre_succ_int32 (ats_int32_type i) { return (i + 1) ; } ATSinline() ats_int32_type atspre_pred_int32 (ats_int32_type i) { return (i - 1) ; } ATSinline() ats_int32_type atspre_add_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 + i2) ; } ATSinline() ats_int32_type atspre_sub_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 - i2) ; } ATSinline() ats_int32_type atspre_mul_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 * i2) ; } ATSinline() ats_int32_type atspre_div_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 / i2) ; } ATSinline() ats_int32_type atspre_mod_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 != i2) ; } // compare, max, int ATSinline() ats_int_type atspre_compare_int32_int32 (ats_int32_type i1, ats_int32_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_int32_type atspre_max_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_int32_type atspre_min_int32_int32 (ats_int32_type i1, ats_int32_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_int32 (ats_ptr_type out, ats_int32_type i) { int n ; n = fprintf ((FILE*)out, "%li", (ats_lint_type)i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_int32] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_int32 (ats_int32_type i) { // atspre_stdout_view_get () ; atspre_fprint_int32 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_int32 (ats_int32_type i) { atspre_stderr_view_get () ; atspre_fprint_int32 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } ATSinline() ats_ptr_type atspre_tostrptr_int32 (ats_int32_type i) { return atspre_tostrptr_llint (i) ; } // end of [atspre_tostrptr_int32] /* ****** ****** */ // // unsigned integer of size 32bit // ATSinline() ats_uint32_type atspre_uint32_of_int (ats_int_type i) { return i ; } ATSinline() ats_int_type atspre_int_of_uint32 (ats_uint32_type i) { return i ; } ATSinline() ats_uint32_type atspre_uint32_of_uint (ats_uint_type i) { return i ; } ATSinline() ats_uint_type atspre_uint_of_uint32 (ats_uint32_type i) { return i ; } // ------ ------ ATSinline() ats_uint32_type atspre_succ_uint32 (ats_uint32_type i) { return (i + 1) ; } ATSinline() ats_uint32_type atspre_pred_uint32 (ats_uint32_type i) { return (i - 1) ; } ATSinline() ats_uint32_type atspre_add_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 + i2) ; } ATSinline() ats_uint32_type atspre_sub_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 - i2) ; } ATSinline() ats_uint32_type atspre_mul_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 * i2) ; } ATSinline() ats_uint32_type atspre_div_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 / i2) ; } ATSinline() ats_uint32_type atspre_mod_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 % i2) ; } // ------ ------ // comparison operations ATSinline() ats_bool_type atspre_lt_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_uint32_type atspre_max_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_uint32_type atspre_min_uint32_uint32 (ats_uint32_type i1, ats_uint32_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_uint32 (ats_ptr_type out, ats_uint32_type i) { int n = fprintf ((FILE*)out, "%lu", (ats_ulint_type)i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uint32] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_uint32 (ats_uint32_type i) { // atspre_stdout_view_get () ; atspre_fprint_uint32 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_uint32 (ats_uint32_type i) { atspre_stderr_view_get () ; atspre_fprint_uint32 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ // signed integer of size 64bit ATSinline() ats_int64_type atspre_int64_of_int (ats_int_type i) { return (i) ; } ATSinline() ats_int64_type atspre_int64_of_lint (ats_lint_type i) { return (i) ; } ATSinline() ats_int64_type atspre_int64_of_llint (ats_llint_type i) { return (i) ; } ATSinline() ats_int_type atspre_int_of_int64 (ats_int64_type i) { return i ; } // ------ ------ ATSinline() ats_int64_type atspre_abs_int64 (ats_int64_type i) { return (i >= 0 ? i : -i) ; } ATSinline() ats_int64_type atspre_neg_int64 (ats_int64_type i) { return (-i) ; } ATSinline() ats_int64_type atspre_succ_int64 (ats_int64_type i) { return (i + 1) ; } ATSinline() ats_int64_type atspre_pred_int64 (ats_int64_type i) { return (i - 1) ; } ATSinline() ats_int64_type atspre_add_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 + i2) ; } ATSinline() ats_int64_type atspre_sub_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 - i2) ; } ATSinline() ats_int64_type atspre_mul_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 * i2) ; } ATSinline() ats_int64_type atspre_div_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 / i2) ; } ATSinline() ats_int64_type atspre_mod_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 % i2) ; } ATSinline() ats_bool_type atspre_lt_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_int64_int64 (ats_int64_type i1, ats_int64_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_int64_type atspre_max_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_int64_type atspre_min_int64_int64 (ats_int64_type i1, ats_int64_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_int64 (ats_ptr_type out, ats_int64_type i) { int n ; n = fprintf ((FILE*)out, "%lli", (ats_llint_type)i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_int64] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_int64 (ats_int64_type i) { // atspre_stdout_view_get () ; atspre_fprint_int64 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_int64 (ats_int64_type i) { atspre_stderr_view_get () ; atspre_fprint_int64 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } ATSinline() ats_ptr_type atspre_tostrptr_int64 (ats_int64_type i) { return atspre_tostrptr_llint (i) ; } // end of [atspre_tostrptr_int64] /* ****** ****** */ // unsigned integer of size 64bit ATSinline() ats_uint64_type atspre_uint64_of_int1 (ats_int_type i) { return i ; } ATSinline() ats_uint64_type atspre_uint64_of_uint (ats_uint_type i) { return i ; } ATSinline() ats_uint64_type atspre_uint64_of_ulint (ats_ulint_type i) { return i ; } ATSinline() ats_uint64_type atspre_uint64_of_ullint (ats_ullint_type i) { return i ; } ATSinline() ats_uint_type atspre_uint_of_uint64 (ats_uint64_type i) { return i ; } /* ****** ****** */ ATSinline() ats_uint64_type atspre_succ_uint64 (ats_uint64_type i) { return (i + 1) ; } ATSinline() ats_uint64_type atspre_pred_uint64 (ats_uint64_type i) { return (i - 1) ; } /* ****** ****** */ ATSinline() ats_uint64_type atspre_add_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 + i2) ; } ATSinline() ats_uint64_type atspre_sub_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 - i2) ; } ATSinline() ats_uint64_type atspre_mul_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 * i2) ; } ATSinline() ats_uint64_type atspre_div_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 / i2) ; } ATSinline() ats_uint64_type atspre_mod_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 % i2) ; } /* ****** ****** */ // comparison operations ATSinline() ats_bool_type atspre_lt_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 < i2) ; } ATSinline() ats_bool_type atspre_lte_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 <= i2) ; } ATSinline() ats_bool_type atspre_gt_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 > i2) ; } ATSinline() ats_bool_type atspre_gte_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 >= i2) ; } ATSinline() ats_bool_type atspre_eq_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 == i2) ; } ATSinline() ats_bool_type atspre_neq_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 != i2) ; } // compare, max, min ATSinline() ats_int_type atspre_compare_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } ATSinline() ats_uint64_type atspre_max_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 >= i2) ? i1 : i2 ; } ATSinline() ats_uint64_type atspre_min_uint64_uint64 (ats_uint64_type i1, ats_uint64_type i2) { return (i1 <= i2) ? i1 : i2 ; } // print functions ATSinline() ats_void_type atspre_fprint_uint64 (ats_ptr_type out, ats_uint64_type u) { int n = fprintf ((FILE*)out, "%llu", (ats_ullint_type)u) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uint64] failed.\n") ; } return ; } ATSinline() ats_void_type atspre_print_uint64 (ats_uint64_type i) { // atspre_stdout_view_get () ; atspre_fprint_uint64 ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_uint64 (ats_uint64_type i) { atspre_stderr_view_get () ; atspre_fprint_uint64 ((ats_ptr_type)stderr, i) ; atspre_stderr_view_set () ; return ; } /* ****** ****** */ #endif /* ATS_PRELUDE_INTEGER_FIXED_CATS */ /* end of [integer_fixed.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/bool.cats0000664000175000017500000001161612223166162020003 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_BOOL_CATS #define ATS_PRELUDE_BOOL_CATS /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ ATSinline() ats_bool_type atspre_neg_bool (ats_bool_type b) { return (b ? ats_false_bool : ats_true_bool) ; } // end of [atspre_neg_bool] /* ****** ****** */ #if(0) ATSinline() ats_bool_type atspre_add_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { if (b1) { return ats_true_bool ; } else { return b2 ; } } // end of [atspre_add_bool_bool] ATSinline() ats_bool_type atspre_mul_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { if (b1) { return b2 ; } else { return ats_false_bool ; } } // end of [atspre_mul_bool_bool] #endif #define atspre_add_bool_bool(b1, b2) ((b1) || (b2)) #define atspre_mul_bool_bool(b1, b2) ((b1) && (b2)) /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { return (!b1 && b2) ; } // end of [atspre_lt_bool_bool] ATSinline() ats_bool_type atspre_lte_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { return (!b1 || b2) ; } // end of [atspre_lte_bool_bool] ATSinline() ats_bool_type atspre_gt_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { return (b1 && !b2) ; } // end of [atspre_gt_bool_bool] ATSinline() ats_bool_type atspre_gte_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { return (b1 || !b2) ; } // end of [atspre_gte_bool_bool] ATSinline() ats_bool_type atspre_eq_bool_bool ( ats_bool_type b1, ats_bool_type b2 ) { if (b1) { return b2 ; } else { return !b2 ; } } // end of [atspre_eq_bool_bool] ATSinline() ats_bool_type atspre_neq_bool_bool (ats_bool_type b1, ats_bool_type b2) { if (b1) { return !b2 ; } else { return b2 ; } } // end of [atspre_neq_bool_bool] /* ****** ****** */ // // HX: print functions // ATSinline() ats_void_type atspre_fprint_bool ( ats_ptr_type out, ats_bool_type b ) { int n ; if (b) { n = fprintf ((FILE *)out, "true") ; } else { n = fprintf ((FILE *)out, "false") ; } // end of [if] if (n < 0) { ats_exit_errmsg(n, (ats_ptr_type)"Exit: [fprint_bool] failed.\n") ; } // end of [if] return ; } // end of [atspre_fprint_bool] ATSinline() ats_void_type atspre_print_bool (ats_bool_type b) { // atspre_stdout_view_get() ; atspre_fprint_bool ((ats_ptr_type)stdout, b) ; // atspre_stdout_view_set() ; return ; } // end of [atspre_print_bool] ATSinline() ats_void_type atspre_prerr_bool (ats_bool_type b) { // atspre_stderr_view_get() ; atspre_fprint_bool ((ats_ptr_type)stderr, b) ; // atspre_stderr_view_set() ; return ; } // end of [atspre_prerr_bool] // // HX: stringization // ATSinline() ats_ptr_type atspre_tostring_bool (ats_bool_type b) { return (b ? (ats_ptr_type)"true" : (ats_ptr_type)"false") ; } // end of [atspre_tostring_bool] /* ****** ****** */ #define atspre_neg_bool1 atspre_neg_bool #define atspre_add_bool1_bool1 atspre_add_bool_bool #define atspre_mul_bool1_bool1 atspre_mul_bool_bool #define atspre_lt_bool1_bool1 atspre_lt_bool_bool #define atspre_lte_bool1_bool1 atspre_lte_bool_bool #define atspre_gt_bool1_bool1 atspre_gt_bool_bool #define atspre_gte_bool1_bool1 atspre_gte_bool_bool #define atspre_eq_bool1_bool1 atspre_eq_bool_bool #define atspre_neq_bool1_bool1 atspre_neq_bool_bool #define atspre_compare_bool1_bool1 atspre_compare_bool_bool /* ****** ****** */ #endif /* ATS_PRELUDE_BOOL_CATS */ /* end of [bool.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/float.cats0000664000175000017500000005002712223166162020154 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_FLOAT_CATS #define ATS_PRELUDE_FLOAT_CATS /* ****** ****** */ #include /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ // // HX: these functions are in [stdlib.h] // extern double atof (const char *str) ; extern long int atol (const char *str) ; extern long long int atoll (const char *str) ; /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ extern ats_ptr_type atspre_tostringf (ats_ptr_type fmt, ...) ; extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ /* floating point numbers of single precision */ /* ****** ****** */ ATSinline() ats_int_type atspre_int_of_float (ats_float_type f) { return f ; } ATSinline() ats_lint_type atspre_lint_of_float (ats_float_type f) { return f ; } ATSinline() ats_llint_type atspre_llint_of_float (ats_float_type f) { return f ; } // ATSinline() ats_float_type atspre_float_of_int (ats_int_type i) { return (ats_float_type)i ; } ATSinline() ats_float_type atspre_float_of_uint (ats_uint_type u) { return (ats_float_type)u ; } // ATSinline() ats_float_type atspre_float_of_lint (ats_lint_type i) { return (ats_float_type)i ; } ATSinline() ats_float_type atspre_float_of_ulint (ats_ulint_type u) { return (ats_float_type)u ; } // ATSinline() ats_float_type atspre_float_of_llint (ats_llint_type i) { return (ats_float_type)i ; } ATSinline() ats_float_type atspre_float_of_ullint (ats_ullint_type u) { return (ats_float_type)u ; } // ATSinline() ats_float_type atspre_float_of_size (ats_size_type sz) { return (ats_float_type)sz ; } // ATSinline() ats_float_type atspre_float_of_double (ats_double_type d) { return (ats_float_type)d ; } // end of [atspre_float_of_double] ATSinline() ats_float_type atspre_float_of_string (const ats_ptr_type s) { return (ats_float_type)(atof ((char *)s)) ; } // end of [atspre_float_of_string] /* ****** ****** */ ATSinline() ats_float_type atspre_abs_float (ats_float_type f) { return (f >= 0.0 ? f : -f) ; } // end of [atspre_abs_float] ATSinline() ats_float_type atspre_neg_float (ats_float_type f) { return (-f) ; } ATSinline() ats_float_type atspre_succ_float (ats_float_type f) { return (f + 1.0) ; } ATSinline() ats_float_type atspre_pred_float (ats_float_type f) { return (f - 1.0) ; } // ATSinline() ats_float_type atspre_add_float_float (ats_float_type f1, ats_float_type f2) { return (f1 + f2) ; } // end of [atspre_add_float_float] ATSinline() ats_float_type atspre_sub_float_float (ats_float_type f1, ats_float_type f2) { return (f1 - f2) ; } // end of [atspre_sub_float_float] // ATSinline() ats_float_type atspre_mul_float_float (ats_float_type f1, ats_float_type f2) { return (f1 * f2) ; } // end of [atspre_mul_float_float] ATSinline() ats_float_type atspre_mul_int_float (ats_int_type i1, ats_float_type f2) { return ((float)i1 * f2) ; } // end of [atspre_mul_int_float] ATSinline() ats_float_type atspre_mul_float_int (ats_float_type f1, ats_int_type i2) { return (f1 * (float)i2) ; } // end of [atspre_mul_float_int] // ATSinline() ats_float_type atspre_div_float_float (ats_float_type f1, ats_float_type f2) { return (f1 / f2) ; } // end of [atspre_div_float_float] ATSinline() ats_float_type atspre_div_float_int (ats_float_type f1, ats_int_type i2) { return (f1 / (float)i2) ; } // end of [atspre_div_float_int] ATSinline() ats_float_type atspre_div_int_float (ats_float_type i1, ats_int_type f2) { return ((float)i1 / f2) ; } // end of [atspre_div_int_float] // ATSinline() ats_bool_type atspre_lt_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 < f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_float_float] ATSinline() ats_bool_type atspre_lte_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 <= f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_float_float] ATSinline() ats_bool_type atspre_gt_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 > f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_float_float] ATSinline() ats_bool_type atspre_gte_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 >= f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_float_float] ATSinline() ats_bool_type atspre_eq_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 == f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_float_float] ATSinline() ats_bool_type atspre_neq_float_float ( ats_float_type f1, ats_float_type f2 ) { return (f1 != f2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_neq_float_float] // compare, max and min ATSinline() ats_int_type atspre_compare_float_float (ats_float_type f1, ats_float_type f2) { if (f1 < f2) return (-1) ; if (f1 > f2) return ( 1) ; return 0 ; } ATSinline() ats_float_type atspre_max_float_float (ats_float_type f1, ats_float_type f2) { return (f1 >= f2) ? f1 : f2 ; } ATSinline() ats_float_type atspre_min_float_float (ats_float_type f1, ats_float_type f2) { return (f1 <= f2) ? f1 : f2 ; } // square function ATSinline() ats_float_type atspre_square_float (ats_float_type f) { return (f * f) ; } // cube function ATSinline() ats_float_type atspre_cube_float (ats_float_type f) { return (f * f * f) ; } // print function ATSinline() ats_void_type atspre_fprint_float ( ats_ptr_type out, ats_float_type f ) { int n = fprintf ((FILE*)out, "%f", f) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_float] failed.\n") ; } // end of [if] return ; } /* end of [atspre_fprint_float] */ ATSinline() ats_void_type atspre_print_float (ats_float_type f) { // atspre_stdout_view_get () ; atspre_fprint_float ((ats_ptr_type)stdout, f) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_float (ats_float_type f) { // atspre_stderr_view_get () ; atspre_fprint_float ((ats_ptr_type)stderr, f) ; // atspre_stderr_view_set () ; return ; } // stringization ATSinline() ats_ptr_type atspre_tostrptr_float (ats_float_type f) { return atspre_tostringf ((ats_ptr_type)"%f", f) ; } // end of [atspre_tostrptr_float] /* ****** ****** */ /* floating point numbers of double precision */ /* ****** ****** */ ATSinline() ats_int_type atspre_int_of_double (ats_double_type d) { return (ats_int_type)d ; } ATSinline() ats_lint_type atspre_lint_of_double (ats_double_type d) { return (ats_lint_type)d ; } ATSinline() ats_llint_type atspre_llint_of_double (ats_double_type d) { return (ats_llint_type)d ; } // end of [atspre_llint_of_double] ATSinline() ats_ullint_type atspre_ullint_of_double (ats_double_type d) { return ((ats_ullint_type)d) ; } // end of [atspre_ullint_of_double] /* ****** ****** */ ATSinline() ats_double_type atspre_double_of_int (ats_int_type i) { return (ats_double_type)i ; } // end of [atspre_double_of_int] ATSinline() ats_double_type atspre_double_of_uint (ats_uint_type u) { return (ats_double_type)u ; } // end of [atspre_double_of_uint] ATSinline() ats_double_type atspre_double_of_lint (ats_lint_type i) { return (ats_double_type)i ; } // end of [atspre_double_of_lint] ATSinline() ats_double_type atspre_double_of_ulint (ats_ulint_type u) { return (ats_double_type)u ; } // end of [atspre_double_of_ulint] ATSinline() ats_double_type atspre_double_of_llint (ats_llint_type i) { return (ats_double_type)i ; } // end of [atspre_double_of_llint] ATSinline() ats_double_type atspre_double_of_ullint (ats_ullint_type u) { return (ats_double_type)u ; } // end of [atspre_double_of_ullint] ATSinline() ats_double_type atspre_double_of_size (ats_size_type sz) { return (ats_double_type)sz ; } // end of [atspre_double_of_size] ATSinline() ats_double_type atspre_double_of_float (ats_float_type f) { return (ats_double_type)f ; } // end of [atspre_double_of_float] ATSinline() ats_double_type atspre_double_of_string (const ats_ptr_type s) { return (ats_double_type)(atof ((char*)s)) ; } // end of [atspre_double_of_string] /* ****** ****** */ ATSinline() ats_double_type atspre_abs_double (ats_double_type f) { return (f >= 0.0 ? f : -f) ; } // end of [atspre_abs_double] ATSinline() ats_double_type atspre_neg_double (ats_double_type f) { return (-f) ; } ATSinline() ats_double_type atspre_succ_double (ats_double_type f) { return (f + 1.0) ; } ATSinline() ats_double_type atspre_pred_double (ats_double_type f) { return (f - 1.0) ; } /* ****** ****** */ ATSinline() ats_double_type atspre_add_double_double (ats_double_type f1, ats_double_type f2) { return (f1 + f2) ; } // end of [atspre_add_double_double] ATSinline() ats_double_type atspre_add_double_int (ats_double_type f1, ats_int_type i2) { return (f1 + i2) ; } // end of [atspre_add_double_int] ATSinline() ats_double_type atspre_add_int_double (ats_int_type i1, ats_double_type f2) { return (i1 + f2) ; } // end of [atspre_add_int_double] ATSinline() ats_double_type atspre_sub_double_double (ats_double_type f1, ats_double_type f2) { return (f1 - f2) ; } // end of [atspre_sub_double_double] ATSinline() ats_double_type atspre_sub_double_int (ats_double_type f1, ats_int_type i2) { return (f1 - i2) ; } ATSinline() ats_double_type atspre_sub_int_double (ats_int_type i1, ats_double_type f2) { return (i1 - f2) ; } // end of [atspre_sub_int_double] ATSinline() ats_double_type atspre_mul_double_double (ats_double_type d1, ats_double_type d2) { return (d1 * d2) ; } // end of [atspre_mul_double_double] ATSinline() ats_double_type atspre_mul_double_int (ats_double_type d1, ats_int_type i2) { return (d1 * (double)i2) ; } // end of [atspre_mul_double_int] ATSinline() ats_double_type atspre_mul_int_double (ats_int_type i1, ats_double_type d2) { return ((double)i1 * d2) ; } // end of [atspre_mul_int_double] ATSinline() ats_double_type atspre_div_double_double (ats_double_type d1, ats_double_type d2) { return (d1 / d2) ; } // end of [atspre_div_double_double] ATSinline() ats_double_type atspre_div_double_int (ats_double_type d1, ats_int_type i2) { return (d1 / (double)i2) ; } // end of [atspre_div_double_int] ATSinline() ats_double_type atspre_div_int_double (ats_int_type i1, ats_double_type d2) { return ((double)i1 / d2) ; } // end of [atspre_div_int_double] ATSinline() ats_bool_type atspre_lt_double_double ( ats_double_type d1, ats_double_type d2 ) { return (d1 < d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_double_double] ATSinline() ats_bool_type atspre_lte_double_double ( ats_double_type d1, ats_double_type d2 ) { return (d1 <= d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_double_double] ATSinline() ats_bool_type atspre_gt_double_double (ats_double_type d1, ats_double_type d2) { return (d1 > d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_double_double] ATSinline() ats_bool_type atspre_gte_double_double (ats_double_type d1, ats_double_type d2) { return (d1 >= d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_double_double] ATSinline() ats_bool_type atspre_eq_double_double (ats_double_type d1, ats_double_type d2) { return (d1 == d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_double_double] ATSinline() ats_bool_type atspre_neq_double_double (ats_double_type d1, ats_double_type d2) { return (d1 != d2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_neq_double_double] // // compare, max and min // ATSinline() ats_int_type atspre_compare_double_double (ats_double_type d1, ats_double_type d2) { if (d1 < d2) return (-1) ; else if (d1 > d2) return ( 1) ; else return 0 ; } // end of [atspre_compare_double_double] ATSinline() ats_double_type atspre_max_double_double (ats_double_type d1, ats_double_type d2) { return (d1 >= d2) ? d1 : d2 ; } // end of [atspre_max_double_double] ATSinline() ats_double_type atspre_min_double_double (ats_double_type d1, ats_double_type d2) { return (d1 <= d2) ? d1 : d2 ; } // end of [atspre_min_double_double] // square function ATSinline() ats_double_type atspre_square_double (ats_double_type d) { return (d * d) ; } // cube function ATSinline() ats_double_type atspre_cube_double (ats_double_type d) { return (d * d * d) ; } // print functions ATSinline() ats_void_type atspre_fprint_double (ats_ptr_type out, ats_double_type f) { int n = fprintf ((FILE *)out, "%f", f) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_double] failed.\n") ; } // end of [if] return ; } /* end of [atspre_fprint_double] */ ATSinline() ats_void_type atspre_print_double (ats_double_type f) { // atspre_stdout_view_get () ; atspre_fprint_double ((ats_ptr_type)stdout, f) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_double] ATSinline() ats_void_type atspre_prerr_double (ats_double_type f) { // atspre_stderr_view_get () ; atspre_fprint_double ((ats_ptr_type)stderr, f) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_double] // stringization ATSinline() ats_ptr_type atspre_tostrptr_double (ats_double_type f) { return atspre_tostringf ((ats_ptr_type)"%f", f) ; } // end of [atspre_tostrptr_double] /* ****** ****** */ /* floating point numbers of long double precision */ /* ****** ****** */ ATSinline() ats_int_type atspre_int_of_ldouble (ats_ldouble_type ld) { return ld ; } ATSinline() ats_lint_type atspre_lint_of_ldouble (ats_ldouble_type ld) { return ld ; } ATSinline() ats_llint_type atspre_llint_of_ldouble (ats_ldouble_type ld) { return ld ; } // ATSinline() ats_ldouble_type atspre_ldouble_of_int (ats_int_type i) { return ((ats_ldouble_type)i) ; } // end of [atspre_ldouble_of_int] ATSinline() ats_ldouble_type atspre_ldouble_of_lint (ats_lint_type li) { return (ats_ldouble_type)li ; } // end of [atspre_ldouble_of_lint] ATSinline() ats_ldouble_type atspre_ldouble_of_llint (ats_llint_type lli) { return (ats_ldouble_type)lli ; } // end of [atspre_ldouble_of_llint] // ATSinline() ats_ldouble_type atspre_ldouble_of_float (ats_float_type f) { return ((ats_ldouble_type)f) ; } // end of [atspre_ldouble_of_float] ATSinline() ats_ldouble_type atspre_ldouble_of_double (ats_double_type d) { return ((ats_ldouble_type)d) ; } // end of [atspre_ldouble_of_double] // ATSinline() ats_ldouble_type atspre_abs_ldouble (ats_ldouble_type f) { return (f >= 0.0 ? f : -f) ; } ATSinline() ats_ldouble_type atspre_neg_ldouble (ats_ldouble_type f) { return (-f) ; } ATSinline() ats_ldouble_type atspre_succ_ldouble (ats_ldouble_type f) { return (f + 1.0) ; } ATSinline() ats_ldouble_type atspre_pred_ldouble (ats_ldouble_type f) { return (f - 1.0) ; } ATSinline() ats_ldouble_type atspre_add_ldouble_ldouble (ats_ldouble_type f1, ats_ldouble_type f2) { return (f1 + f2) ; } // end of [atspre_add_ldouble_ldouble] ATSinline() ats_ldouble_type atspre_sub_ldouble_ldouble (ats_ldouble_type f1, ats_ldouble_type f2) { return (f1 - f2) ; } // end of [atspre_sub_ldouble_ldouble] // ATSinline() ats_ldouble_type atspre_mul_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 * ld2) ; } // end of [atspre_mul_ldouble_ldouble] ATSinline() ats_ldouble_type atspre_mul_int_ldouble (ats_int_type i1, ats_ldouble_type ld2) { return ((long double)i1 * ld2) ; } // end of [atspre_mul_int_ldouble] ATSinline() ats_ldouble_type atspre_mul_ldouble_int (ats_ldouble_type ld1, ats_int_type i2) { return (ld1 * (long double)i2) ; } // end of [atspre_mul_ldouble_int] // ATSinline() ats_ldouble_type atspre_div_ldouble_ldouble ( ats_ldouble_type ld1, ats_ldouble_type ld2 ) { return (ld1 / ld2) ; } // end of [atspre_div_ldouble_ldouble] ATSinline() ats_ldouble_type atspre_div_ldouble_int (ats_ldouble_type ld1, ats_int_type i2) { return (ld1 / (long double)i2) ; } // end of [atspre_div_ldouble_int] // ATSinline() ats_bool_type atspre_lt_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 == ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lt_ldouble_ldouble] ATSinline() ats_bool_type atspre_lte_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 <= ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_lte_ldouble_ldouble] ATSinline() ats_bool_type atspre_gt_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 > ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gt_ldouble_ldouble] ATSinline() ats_bool_type atspre_gte_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 >= ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_gte_ldouble_ldouble] ATSinline() ats_bool_type atspre_eq_ldouble_ldouble ( ats_ldouble_type ld1, ats_ldouble_type ld2 ) { return (ld1 == ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_eq_ldouble_ldouble] ATSinline() ats_bool_type atspre_neq_ldouble_ldouble ( ats_ldouble_type ld1, ats_ldouble_type ld2 ) { return (ld1 != ld2 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_neq_ldouble_ldouble] // compare, max and min ATSinline() ats_int_type atspre_compare_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { if (ld1 < ld2) return (-1) ; else if (ld1 > ld2) return ( 1) ; else return 0 ; } // end of [atspre_compare_ldouble_ldouble] ATSinline() ats_ldouble_type atspre_max_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 >= ld2) ? ld1 : ld2 ; } // end of [atspre_max_ldouble_ldouble] ATSinline() ats_ldouble_type atspre_min_ldouble_ldouble (ats_ldouble_type ld1, ats_ldouble_type ld2) { return (ld1 <= ld2) ? ld1 : ld2 ; } // end of [atspre_min_ldouble_ldouble] // square function ATSinline() ats_ldouble_type atspre_square_ldouble (ats_ldouble_type ld) { return (ld * ld) ; } // cube function ATSinline() ats_ldouble_type atspre_cube_ldouble (ats_ldouble_type ld) { return (ld * ld * ld) ; } // print functions ATSinline() ats_void_type atspre_fprint_ldouble ( ats_ptr_type out, ats_ldouble_type f ) { int n = fprintf ((FILE *)out, "%Lf", f) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_ldouble] failed.\n") ; } // end of [if] return ; } /* end of [atspre_fprint_ldouble] */ ATSinline() ats_void_type atspre_print_ldouble (ats_ldouble_type f) { // atspre_stdout_view_get () ; atspre_fprint_ldouble ((ats_ptr_type)stdout, f) ; // atspre_stdout_view_set () ; return ; } // end of [atspre_print_ldouble] ATSinline() ats_void_type atspre_prerr_ldouble (ats_ldouble_type f) { // atspre_stderr_view_get () ; atspre_fprint_ldouble ((ats_ptr_type)stderr, f) ; // atspre_stderr_view_set () ; return ; } // end of [atspre_prerr_ldouble] // stringization ATSinline() ats_ptr_type atspre_tostrptr_ldouble (ats_ldouble_type f) { return atspre_tostringf ((ats_ptr_type)"%Lf", f) ; } // end of [atspre_tostrptr_ldouble] /* ****** ****** */ #endif /* ATS_PRELUDE_FLOAT_CATS */ /* end of [float.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/list_vt.cats0000664000175000017500000000317212223166162020532 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* * ATS - Unleashing the Potential of Types! * * Copyright (C) 2002-2008 Hongwei Xi. * * ATS is free software; you can redistribute it and/or modify it under * the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the * Free Software Foundation; either version 2.1, or (at your option) any * later version. * * ATS is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * * You should have received a copy of the GNU General Public License * along with ATS; see the file COPYING. If not, please write to the * Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301, USA. * */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_LIST_VT_CATS #define ATS_PRELUDE_LIST_VT_CATS /* ****** ****** */ // it is still empty now! /* ****** ****** */ #endif /* ATS_PRELUDE_LIST_VT_CATS */ /* end of [list_vt.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/reference.cats0000664000175000017500000000447712223166162021015 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_REFERENCE_CATS #define ATS_PRELUDE_REFERENCE_CATS /* ****** ****** */ #ifdef memcpy // // HX: [memcpy] is a macro on MACOS // #else extern void *memcpy(void *dest, const void *src, size_t n) ; #endif // memcpy /* ****** ****** */ ATSinline() ats_ptr_type atspre_ref_make_elt_tsz ( ats_ptr_type p0, ats_size_type sz ) { ats_ptr_type p ; p = ATS_MALLOC(sz) ; memcpy (p, p0, sz) ; return p ; } // end of [atspre_ref_make_elt_tsz] ATSinline() ats_ptr_type atspre_ref_void_make () { return (ats_ptr_type)0 ; } ATSinline() ats_ptr_type atspre_ref_make_view_ptr (ats_ptr_type p) { return p ; } /* ****** ****** */ // // HX-2011-01-12: it is now a casting function; this is // kept for backward compatibility // ATSinline() ats_ptr_type atspre_ref_get_view_ptr (ats_ptr_type r) { return r ; } /* ****** ****** */ #endif /* ATS_PRELUDE_REFERENCE_CATS */ /* end of [reference.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/array.cats0000664000175000017500000000724412223166162020170 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_ARRAY_CATS #define ATS_PRELUDE_ARRAY_CATS /* ****** ****** */ #ifdef memcpy // // HX: [memcpy] is a macro on MACOS // #else // // in [string.h] // extern void *memcpy(void *dest, const void *src, size_t n) ; // #endif // memcpy /* ****** ****** */ ATSinline() ats_ptr_type atspre_array0_of_array1 (ats_ptr_type A) { return A ; } ATSinline() ats_ptr_type atspre_array1_of_array0 (ats_ptr_type A) { return A ; } /* ****** ****** */ ATSinline() ats_ptr_type atspre_array_ptr_alloc_tsz ( ats_size_type n, ats_size_type tsz ) { return ATS_MALLOC(n * tsz) ; } /* end of [atspre_array_ptr_alloc_tsz] */ ATSinline() ats_void_type atspre_array_ptr_free (ats_ptr_type base) { ATS_FREE(base); return ; } /* end of [atspre_array_ptr_free] */ /* ****** ****** */ // // HX: implemented in // $ATSHOME/prelude/DATS/array.dats // extern ats_void_type atspre_array_ptr_initialize_elt_tsz ( ats_ptr_type A , ats_size_type asz , ats_ptr_type ini , ats_size_type tsz ) ; /* ****** ****** */ ATSinline() ats_ptr_type atspre_array_ptr_split_tsz ( ats_ptr_type base , ats_size_type offset , ats_size_type tsz ) { return (ats_ptr_type)((char*)base + offset * tsz) ; } /* end of [atspre_array_ptr_split_tsz] */ /* ****** ****** */ ATSinline() ats_ptr_type atspre_array_ptr_takeout_tsz ( ats_ptr_type base , ats_size_type offset , ats_size_type tsz ) { return (ats_ptr_type)((char*)base + offset * tsz) ; } /* end of [atspre_array_ptr_takeout_tsz] */ /* ****** ****** */ ATSinline() ats_void_type atspre_array_ptr_copy_tsz ( ats_ptr_type p1 , ats_ptr_type p2 , ats_size_type asz , ats_size_type tsz ) { memcpy (p2, p1, asz * tsz) ; return ; } /* end of [atspre_array_ptr_copy_tsz] */ ATSinline() ats_void_type atspre_array_ptr_move_tsz ( ats_ptr_type p1 , ats_ptr_type p2 , ats_size_type asz , ats_size_type tsz ) { memcpy (p2, p1, asz * tsz) ; return ; } /* end of [atspre_array_ptr_move_tsz] */ /* ****** ****** */ ATSinline() ats_ptr_type atspre_array2_ptr_takeout_tsz ( ats_ptr_type base , ats_size_type iofs , ats_size_type ncol , ats_size_type tsz ) { return (ats_ptr_type)((char*)base + (iofs * ncol) * tsz) ; } /* end of [atspre_array2_ptr_takeout_tsz] */ /* ****** ****** */ #endif /* ATS_PRELUDE_ARRAY_CATS */ /* end of [array.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/list.cats0000664000175000017500000000350112223166162020015 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_LIST_CATS #define ATS_PRELUDE_LIST_CATS /* ****** ****** */ ATSinline() ats_ptr_type atspre_list0_of_list1 (ats_ptr_type x) { return x ; } ATSinline() ats_ptr_type atspre_list0_of_list_vt (ats_ptr_type x) { return x ; } ATSinline() ats_ptr_type atspre_list1_of_list0 (ats_ptr_type x) { return x ; } /* ****** ****** */ #endif /* ATS_PRELUDE_LIST_CATS */ /* end of [list.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/lazy_vt.cats0000664000175000017500000000460112223166162020534 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. ** */ /* ****** ****** */ // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) /* ****** ****** */ #ifndef ATS_PRELUDE_LAZY_VT_CATS #define ATS_PRELUDE_LAZY_VT_CATS /* ****** ****** */ extern void free (void*) ; // see [stdlib.h] /* ****** ****** */ #define ats_instr_move_lazy_ldelay_mac(tmp, hit, vp_clo) \ do { tmp = (vp_clo) ; } while (0) /* end of [do ... while ...] */ #define ats_instr_move_lazy_lforce_mac(tmp, hit, vp_lazy) do { \ tmp = \ ((hit (*)(ats_ptr_type, ats_bool_type))ats_closure_fun(vp_lazy))(vp_lazy, ats_true_bool) ; \ ATS_FREE (vp_lazy) ; \ } while (0) /* end of [do ... while ...] */ /* ****** ****** */ /* ** HX: [lazy_vt_free] is declared in $ATSHOME/prelude/basics_dyn.sats */ ATSinline() ats_void_type ats_lazy_vt_free (ats_ptr_type vp_lazy) { ((void (*)(ats_ptr_type, ats_bool_type))ats_closure_fun(vp_lazy))(vp_lazy, ats_false_bool) ; ATS_FREE (vp_lazy) ; return ; } /* ats_lazy_vt_free */ /* ****** ****** */ #endif /* ATS_PRELUDE_LAZY_VT_CATS */ /* end of [lazy_vt.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/string.cats0000664000175000017500000002475012223166162020361 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_STRING_CATS #define ATS_PRELUDE_STRING_CATS /* ****** ****** */ #include /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ ATSinline() ats_void_type atspre_strbuf_bytes_trans (ats_ptr_type p) { return ; } /* end of [atspre_strbuf_bytes_trans] */ ATSinline() ats_void_type atspre_bytes_strbuf_trans (ats_ptr_type p, ats_size_type n) { ((char*)p)[n] = '\000' ; return ; } /* end of [atspre_bytes_strbuf_trans] */ /* ****** ****** */ ATSinline() ats_void_type atspre_strbufptr_free (ats_ptr_type base) { ATS_FREE(base); return ; } // end of [atspre_strbufptr_free] /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; return (i < 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_lt_string_string] */ ATSinline() ats_bool_type atspre_lte_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; return (i <= 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_lte_string_string] */ ATSinline() ats_bool_type atspre_gt_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; return (i > 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_gt_string_string] */ ATSinline() ats_bool_type atspre_gte_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; return (i >= 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_gte_string_string] */ ATSinline() ats_bool_type atspre_eq_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; /* fprintf (stdout, "ats_eq_string_string: s1 = %s and s2 = %s\n", s1, s2) ; fprintf (stdout, "ats_eq_string_string: i = %i\n", i) ; */ return (i == 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_eq_string_string] */ ATSinline() ats_bool_type atspre_neq_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; return (i != 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atspre_neq_string_string] */ ATSinline() ats_int_type atspre_compare_string_string (const ats_ptr_type s1, const ats_ptr_type s2) { int i = strcmp((char*)s1, (char*)s2) ; if (i < 0) return -1 ; if (i > 0) return 1 ; return 0 ; } /* end of [atspre_compare_string_string] */ // print functions ATSinline() ats_void_type atspre_fprint_string (const ats_ptr_type out, const ats_ptr_type s) { int n = fprintf ((FILE *)out, "%s", (char*)s) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_string] failed.\n") ; } // end of [if] return ; } /* end of [atspre_fprint_string] */ ATSinline() ats_void_type atspre_print_string (const ats_ptr_type s) { // atspre_stdout_view_get() ; atspre_fprint_string((ats_ptr_type)stdout, s) ; // atspre_stdout_view_set() ; return ; } /* end of [atspre_print_string] */ ATSinline() ats_void_type atspre_prerr_string (const ats_ptr_type s) { // atspre_stderr_view_get() ; atspre_fprint_string((ats_ptr_type)stderr, s) ; // atspre_stderr_view_set() ; return ; } /* end of [atspre_prerr_string] */ /* ****** ****** */ ATSinline() ats_char_type atspre_string_get_char_at (const ats_ptr_type s, ats_size_type offset) { return *((char*)s + offset) ; } /* end of [atspre_string_get_char_at] */ ATSinline() ats_char_type atspre_string_get_char_at__intsz ( const ats_ptr_type s, ats_int_type offset ) { return *((char*)s + offset) ; } /* end of [atspre_string_get_char_at__intsz] */ ATSinline() ats_void_type atspre_strbuf_set_char_at ( ats_ptr_type s, ats_size_type offset, ats_char_type c ) { /* fprintf (stdout, "atspre_strbuf_set_char_at: s = %s\n", s); fprintf (stdout, "atspre_strbuf_set_char_at: offset = %li\n", (unsigned long)offset); fprintf (stdout, "atspre_strbuf_set_char_at: c = %c\n", c); */ *((char*)s + offset) = c ; return ; } /* end of [atspre_strbuf_set_char_at] */ ATSinline() ats_void_type atspre_strbuf_set_char_at__intsz ( ats_ptr_type s, ats_int_type offset, ats_char_type c ) { *((char*)s + offset) = c ; return ; } /* end of [atspre_strbuf_set_char_at__intsz] */ ATSinline() ats_char_type atspre_string_test_char_at ( const ats_ptr_type s, ats_size_type offset ) { return *((char*)s + offset) ; } /* end of [atspre_string_test_char_at] */ ATSinline() ats_char_type atspre_string_test_char_at__intsz ( const ats_ptr_type s, ats_int_type offset ) { return *((char*)s + offset) ; } /* end of [atspre_string_test_char_at__intsz] */ /* ****** ****** */ ATSinline() ats_void_type atspre_strbuf_initialize_substring ( ats_ptr_type p_buf , ats_ptr_type s, ats_size_type st, ats_size_type ln ) { memcpy (p_buf, ((char*)s)+st, ln) ; ((char*)p_buf)[ln] = '\000' ; return ; } // end of [atspre_strbuf_initialize_substring] /* ****** ****** */ ATSinline() ats_ptr_type atspre_string_copy (ats_ptr_type str) { int n ; char *des ; n = strlen((char*)str) ; des = (char*)ATS_MALLOC(n+1) ; des[n] = '\000' ; memcpy(des, str, n) ; return (des) ; } // end of [atspre_string_copy] /* ****** ****** */ ATSinline() ats_ptr_type atspre_string_append (ats_ptr_type s1, ats_ptr_type s2) { int n1, n2 ; char *des ; n1 = strlen((char*)s1) ; n2 = strlen((char*)s2) ; des = (char*)ATS_MALLOC(n1+n2+1) ; des[n1+n2] = '\000' ; memcpy(des, s1, n1) ; memcpy (des+n1, s2, n2) ; return (des) ; } // end of [atspre_string_append] /* ****** ****** */ ATSinline() ats_bool_type atspre_string_contains (ats_ptr_type s0, ats_char_type c) { char *s = strchr((char*)s0, (char)c) ; return (s != (char*)0 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_string_contains] /* ****** ****** */ ATSinline() ats_size_type atspre_string_length (ats_ptr_type s) { return (strlen((char*)s)) ; } // end of [atspre_string_length] /* ****** ****** */ ATSinline() ats_bool_type atspre_string_is_empty (ats_ptr_type s) { return (*((char*)s) == '\000') ; } // end of [atspre_string_is_empty] ATSinline() ats_bool_type atspre_string_isnot_empty (ats_ptr_type s) { return (*((char*)s) != '\000') ; } // end of [atspre_string_isnot_empty] /* ****** ****** */ ATSinline() ats_bool_type atspre_string_is_atend ( ats_ptr_type s, ats_size_type i ) { return (*((char*)s + i) == '\000' ? ats_true_bool : ats_false_bool) ; } // end of [atspre_string_is_atend] ATSinline() ats_bool_type atspre_string_isnot_atend ( ats_ptr_type s, ats_size_type i ) { return (*((char*)s + i) != '\000' ? ats_true_bool : ats_false_bool) ; } // end of [atspre_string_isnot_atend] /* ****** ****** */ ATSinline() ats_ssize_type atspre_string_index_of_char_from_left (const ats_ptr_type s, const ats_char_type c) { char *res ; res = strchr ((char*)s, c) ; if (res != (char*)0) return (res - (char*)s) ; return (-1) ; } // end of [atspre_string_index_of_char_from_left] ATSinline() ats_ssize_type atspre_string_index_of_char_from_right (const ats_ptr_type s, const ats_char_type c) { char *res ; res = strrchr ((char*)s, c) ; if (res != (char*)0) return (res - (char*)s) ; return (-1) ; } // end of [atspre_string_index_of_char_from_right] /* ****** ****** */ ATSinline() ats_ssize_type atspre_string_index_of_string (const ats_ptr_type s1, const ats_ptr_type s2) { char *res ; res = strstr ((char*)s1, (char*)s2) ; if (res != (char*)0) return (res - (char*)s1) ; return (-1) ; } // end of [atspre_string_index_of_string] /* ****** ****** */ extern ats_ptr_type atspre_string_make_char ( ats_size_type n, const ats_char_type c ) ; // implemented in [prelude/DATS/string.dats] extern ats_ptr_type atspre_string_make_substring ( ats_ptr_type src0, ats_size_type start, ats_size_type len ) ; // implemented in [prelude/DATS/string.dats] /* ****** ****** */ ATSinline() ats_ptr_type atspre_string_singleton (ats_char_type c) { return atspre_string_make_char (1, c) ; } // end of [atspre_string_singleton] /* ****** ****** */ // functions for optional strings static ats_ptr_type atspre_stropt_none = (ats_ptr_type)0 ; ATSinline() ats_bool_type atspre_stropt_is_none (ats_ptr_type opt) { return (opt == (ats_ptr_type)0) ; } // end of [atspre_stropt_is_none] ATSinline() ats_bool_type atspre_stropt_is_some (ats_ptr_type opt) { return (opt != (ats_ptr_type)0) ; } // end of [atspre_stropt_is_some] ATSinline() ats_void_type atspre_fprint_stropt ( ats_ref_type out, ats_ptr_type opt ) { if (!opt) { fprintf ((FILE*)out, "None()") ; return ; } // end of [if] fprintf ((FILE*)out, "Some(%s)", (char*)opt) ; return ; } // end of [atspre_fprint_stropt] /* ****** ****** */ #define atspre_stropt_gc_none() ((ats_ptr_type)0) ATSinline() ats_void_type atspre_stropt_gc_unnone (ats_ptr_type x) { return ; } /* ****** ****** */ #define atspre_strptr_null() ((ats_ptr_type)0) ATSinline() ats_void_type atspre_strptr_free (ats_ptr_type base) { if (base) ATS_FREE (base) ; return ; } // end of [atspre_strptr_free] #define atspre_fprint_strptr atspre_fprint_string /* ****** ****** */ #endif /* ATS_PRELUDE_STRING_CATS */ /* end of [string.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/matrix.cats0000664000175000017500000000422012223166162020345 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_MATRIX_CATS #define ATS_PRELUDE_MATRIX_CATS /* ****** ****** */ ATSinline() ats_ptr_type atspre_matrix_ptr_takeout_row_tsz ( ats_ptr_type base , ats_size_type iofs , ats_size_type ncol , ats_size_type tsz ) { return (ats_ptr_type)((char*)base + (iofs * ncol) * tsz) ; } /* end of [atspre_matrix_ptr_takeout_row_tsz] */ /* ****** ****** */ ATSinline() ats_ptr_type atspre_matrix_ptr_takeout_elt_tsz ( ats_ptr_type base , ats_size_type iofs , ats_size_type ncol , ats_size_type jofs , ats_size_type tsz ) { return (ats_ptr_type)((char*)base + (iofs * ncol + jofs) * tsz) ; } /* end of [atspre_matrix_ptr_takeout_tsz_tsz] */ /* ****** ****** */ #endif /* ATS_PRELUDE_MATRIX_CATS */ /* end of [matrix.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/option.cats0000664000175000017500000000352012223166162020353 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* * ATS - Unleashing the Potential of Types! * * Copyright (C) 2002-2008 Hongwei Xi. * * ATS is free software; you can redistribute it and/or modify it under * the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the * Free Software Foundation; either version 2.1, or (at your option) any * later version. * * ATS is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. * * You should have received a copy of the GNU General Public License * along with ATS; see the file COPYING. If not, please write to the * Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301, USA. * */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_OPTION_CATS #define ATS_PRELUDE_OPTION_CATS /* ****** ****** */ #if (0) // // HX-2010-03-24: no longer needed // static inline ats_ptr_type atspre_option0_of_option1 (ats_ptr_type x) { return x ; } static inline ats_ptr_type atspre_option1_of_option0 (ats_ptr_type x) { return x ; } #endif // end of if(0) /* ****** ****** */ #endif /* ATS_PRELUDE_OPTION_CATS */ /* end of [option.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/lazy.cats0000664000175000017500000000503312223166162020023 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) /* ****** ****** */ #ifndef ATS_PRELUDE_LAZY_CATS #define ATS_PRELUDE_LAZY_CATS /* ****** ****** */ /* typedef struct { ats_ptr_type tag ; ats_clo_ptr_type data ; } thunkvalue_struct ; */ typedef ats_ptr_type *thunkvalue ; /* ****** ****** */ #define ats_instr_move_lazy_delay_mac(tmp, hit, vp_clo) do { \ tmp = ATS_MALLOC ( \ sizeof(ats_ptr_type) + (sizeof(hit) <= sizeof(ats_ptr_type) ? sizeof(ats_ptr_type) : sizeof(hit)) \ ) ; /* end of [ATS_MALLOC] */ \ ((thunkvalue)tmp)[0] = (ats_ptr_type)0 ; ((thunkvalue)tmp)[1] = (vp_clo) ; \ } while (0) /* end of [do ... while ...] */ #define ats_instr_move_lazy_force_mac(tmp, hit, vp_lazy) do { \ if (((thunkvalue)vp_lazy)[0] == 0) { \ tmp = ((hit (*)(ats_clo_ptr_type))ats_closure_fun(((thunkvalue)vp_lazy)[1]))(((thunkvalue)vp_lazy)[1]) ; \ ((thunkvalue)vp_lazy)[0] += 1 ; \ *(hit*)(((thunkvalue)vp_lazy)+1) = tmp ; \ } else { \ tmp = *(hit*)(((thunkvalue)vp_lazy)+1) ; \ } /* end of [if] */ \ } while (0) /* end of [do ... while ...] */ /* ****** ****** */ #endif /* ATS_PRELUDE_LAZY_CATS */ /* end of [lazy.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/integer_ptr.cats0000664000175000017500000003367012223166162021376 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_INTEGER_PTR_CATS #define ATS_PRELUDE_INTEGER_PTR_CATS /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ // intptr and uintptr typedef ats_ptr_type ats_intptr_type ; typedef ats_ptr_type ats_uintptr_type ; /* ****** ****** */ extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ // // intptr_t: integers of one word size // ATSinline() ats_int_type atspre_int_of_intptr (ats_intptr_type i) { return (ats_int_type)(intptr_t)i ; } // end of [atspre_int_of_intptr] ATSinline() ats_lint_type atspre_lint_of_intptr (ats_intptr_type i) { return (ats_lint_type)(intptr_t)i ; } // end of [atspre_lint_of_intptr] ATSinline() ats_intptr_type atspre_intptr_of_int (ats_int_type i) { return (ats_intptr_type)(intptr_t)i ; } // end of [atspre_intptr_of_int] ATSinline() ats_intptr_type atspre_intptr_of_lint (ats_lint_type i) { return (ats_intptr_type)(intptr_t)i ; } // end of [atspre_intptr_of_lint] /* ****** ****** */ ATSinline() ats_intptr_type atspre_abs_intptr (ats_intptr_type i) { return ((intptr_t)i >= 0 ? i : (ats_intptr_type)(-(intptr_t)i)) ; } // end of [atspre_abs_intptr] ATSinline() ats_intptr_type atspre_neg_intptr (ats_intptr_type i) { return (ats_intptr_type)(-(intptr_t)i) ; } // end of [atspre_neg_intptr] ATSinline() ats_intptr_type atspre_succ_intptr (ats_intptr_type i) { return (ats_intptr_type)((intptr_t)i + 1) ; } // end of [atspre_succ_intptr] ATSinline() ats_intptr_type atspre_pred_intptr (ats_intptr_type i) { return (ats_intptr_type)((intptr_t)i - 1) ; } // end of [atspre_pred_intptr] // ATSinline() ats_intptr_type atspre_add_intptr_int ( ats_intptr_type i1, ats_int_type i2 ) { return (ats_intptr_type)((intptr_t)i1 + (int)i2) ; } // end of [atspre_add_intptr_int] ATSinline() ats_intptr_type atspre_add_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return (ats_intptr_type)((intptr_t)i1 + (intptr_t)i2) ; } // end of [atspre_add_intptr_intptr] // ATSinline() ats_intptr_type atspre_sub_intptr_int ( ats_intptr_type i1, ats_int_type i2 ) { return (ats_intptr_type)((intptr_t)i1 - (int)i2) ; } // end of [atspre_sub_intptr_int] ATSinline() ats_intptr_type atspre_sub_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return (ats_intptr_type)((intptr_t)i1 - (intptr_t)i2) ; } // end of [atspre_sub_intptr_intptr] // ATSinline() ats_intptr_type atspre_mul_intptr_int ( ats_intptr_type i1, ats_int_type i2 ) { return (ats_intptr_type)((intptr_t)i1 * (int)i2) ; } // end of [atspre_mul_intptr_int] ATSinline() ats_intptr_type atspre_mul_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return (ats_intptr_type)((intptr_t)i1 * (intptr_t)i2) ; } // end of [atspre_mul_intptr_intptr] // ATSinline() ats_intptr_type atspre_div_intptr_int ( ats_intptr_type i1, ats_int_type i2 ) { return (ats_intptr_type)((intptr_t)i1 / (int)i2) ; } // end of [atspre_div_intptr_int] ATSinline() ats_intptr_type atspre_div_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return (ats_intptr_type)((intptr_t)i1 / (intptr_t)i2) ; } // end of [atspre_div_intptr_intptr] // ATSinline() ats_intptr_type atspre_mod_intptr_int ( ats_intptr_type i1, ats_int_type i2) { return (ats_intptr_type)((intptr_t)i1 % (int)i2) ; } // end of [atspre_mod_intptr_int] ATSinline() ats_intptr_type atspre_mod_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return (ats_intptr_type)((intptr_t)i1 % (intptr_t)i2) ; } // end of [atspre_mod_intptr_intptr] /* ****** ****** */ // comparison operations ATSinline() ats_bool_type atspre_lt_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 < (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_lt_intptr_intptr] ATSinline() ats_bool_type atspre_lte_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 <= (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_lte_intptr_intptr] ATSinline() ats_bool_type atspre_gt_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 > (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_gt_intptr_intptr] ATSinline() ats_bool_type atspre_gte_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 >= (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_gte_intptr_intptr] ATSinline() ats_bool_type atspre_eq_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 == (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_eq_intptr_intptr] ATSinline() ats_bool_type atspre_neq_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ( (intptr_t)i1 != (intptr_t)i2 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atspre_neq_intptr_intptr] // // compare, max and min // ATSinline() ats_int_type atspre_compare_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } // end of [atspre_compare_intptr_intptr] ATSinline() ats_intptr_type atspre_max_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ((i1 >= i2) ? i1 : i2) ; } // end of [atspre_max_intptr_intptr] ATSinline() ats_intptr_type atspre_min_intptr_intptr ( ats_intptr_type i1, ats_intptr_type i2 ) { return ((i1 <= i2) ? i1 : i2) ; } // end of [atspre_min_intptr_intptr] // // print functions // ATSinline() ats_void_type atspre_fprint_intptr ( ats_ptr_type out, ats_intptr_type i ) { int n ; n = fprintf ((FILE*)out, "%lli", (ats_llint_type)(intptr_t)i) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_intptr] failed.\n") ; } return ; } // end of [atspre_fprint_intptr] ATSinline() ats_void_type atspre_print_intptr (ats_intptr_type i) { // atspre_stdout_view_get () ; atspre_fprint_intptr ((ats_ptr_type)stdout, i) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_intptr (ats_intptr_type i) { // atspre_stderr_view_get () ; atspre_fprint_intptr ((ats_ptr_type)stderr, i) ; // atspre_stderr_view_set () ; return ; } /* ****** ****** */ // // uintptr_t: unsigned integers of one word size // /* ****** ****** */ ATSinline() ats_uint_type atspre_uint_of_uintptr (ats_uintptr_type u) { return (ats_uint_type)(uintptr_t)u ; } // end of [atspre_uint_of_uintptr] ATSinline() ats_uintptr_type atspre_uintptr_of_int1 (ats_int_type i) { return (ats_uintptr_type)(uintptr_t)i ; } // end of [atspre_uintptr_of_int1] ATSinline() ats_uintptr_type atspre_uintptr_of_uint (ats_uint_type u) { return (ats_uintptr_type)(uintptr_t)u ; } // end of [atspre_uintptr_of_uint] ATSinline() ats_uintptr_type atspre_uintptr_of_ptr (ats_ptr_type p) { return (ats_uintptr_type)(uintptr_t)p ; } // end of [atspre_uintptr_of_ptr] // ------ ------ ATSinline() ats_ulint_type atspre_ulint_of_uintptr (ats_uintptr_type u) { return (ats_ulint_type)(uintptr_t)u ; } // end of [atspre_ulint_of_uintptr] ATSinline() ats_uintptr_type atspre_uintptr_of_ulint (ats_ulint_type u) { return (ats_uintptr_type)(uintptr_t)u ; } // end of [atspre_uintptr_of_ulint] // ------ ------ ATSinline() ats_uintptr_type atspre_succ_uintptr (ats_uintptr_type i) { return (ats_uintptr_type)((uintptr_t)i + 1) ; } ATSinline() ats_uintptr_type atspre_pred_uintptr (ats_uintptr_type i) { return (ats_uintptr_type)((uintptr_t)i - 1) ; } // ATSinline() ats_uintptr_type atspre_add_uintptr_uint (ats_uintptr_type i1, ats_uint_type i2) { return (ats_uintptr_type)((uintptr_t)i1 + i2) ; } ATSinline() ats_uintptr_type atspre_add_uintptr_uintptr (ats_uintptr_type i1, ats_uintptr_type i2) { return (ats_uintptr_type)((uintptr_t)i1 + (uintptr_t)i2) ; } // ATSinline() ats_uintptr_type atspre_sub_uintptr_uint (ats_uintptr_type i1, ats_uint_type i2) { return (ats_uintptr_type)((uintptr_t)i1 - i2) ; } ATSinline() ats_uintptr_type atspre_sub_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 - (uintptr_t)i2) ; } // ATSinline() ats_uintptr_type atspre_mul_uintptr_uint ( ats_uintptr_type i1, ats_uint_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 * i2) ; } ATSinline() ats_uintptr_type atspre_mul_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 * (uintptr_t)i2) ; } // ATSinline() ats_uintptr_type atspre_div_uintptr_uint ( ats_uintptr_type i1, ats_uint_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 / i2) ; } ATSinline() ats_uintptr_type atspre_div_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 / (uintptr_t)i2) ; } // ATSinline() ats_uintptr_type atspre_mod_uintptr_uint ( ats_uintptr_type i1, ats_uint_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 % i2) ; } ATSinline() ats_uintptr_type atspre_mod_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (ats_uintptr_type)((uintptr_t)i1 % (uintptr_t)i2) ; } // // comparison operations on uintpr // ATSinline() ats_bool_type atspre_lt_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return ((uintptr_t)i1 < (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } ATSinline() ats_bool_type atspre_lte_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return ((uintptr_t)i1 <= (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } ATSinline() ats_bool_type atspre_gt_uintptr_uintptr (ats_uintptr_type i1, ats_uintptr_type i2) { return ((uintptr_t)i1 > (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } ATSinline() ats_bool_type atspre_gte_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return ((uintptr_t)i1 >= (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } ATSinline() ats_bool_type atspre_eq_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return ((uintptr_t)i1 == (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } ATSinline() ats_bool_type atspre_neq_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return ((uintptr_t)i1 != (uintptr_t)i2 ? ats_true_bool : ats_false_bool) ; } // // compare, max and min // ATSinline() ats_int_type atspre_compare_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { if (i1 < i2) return (-1) ; else if (i1 > i2) return ( 1) ; else return (0) ; } // end of [atspre_compare_uintptr_uintptr] ATSinline() ats_uintptr_type atspre_max_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (i1 >= i2 ? i1 : i2) ; } ATSinline() ats_uintptr_type atspre_min_uintptr_uintptr ( ats_uintptr_type i1, ats_uintptr_type i2 ) { return (i1 <= i2 ? i1 : i2) ; } // // bitwise operations // ATSinline() ats_uintptr_type atspre_lnot_uintptr (ats_uintptr_type x) { return (ats_uintptr_type)(~(uintptr_t)x) ; } ATSinline() ats_uintptr_type atspre_land_uintptr_uintptr (ats_uintptr_type x, ats_uintptr_type y) { return (ats_uintptr_type)((uintptr_t)x & (uintptr_t)y) ; } ATSinline() ats_uintptr_type atspre_lor_uintptr_uintptr (ats_uintptr_type x, ats_uintptr_type y) { return (ats_uintptr_type)((uintptr_t)x | (uintptr_t)y) ; } ATSinline() ats_uintptr_type atspre_lxor_uintptr_uintptr (ats_uintptr_type x, ats_uintptr_type y) { return (ats_uintptr_type)((uintptr_t)x ^ (uintptr_t)y) ; } ATSinline() ats_uintptr_type atspre_lsl_uintptr_int1 (ats_uintptr_type x, ats_int_type n) { return (ats_uintptr_type)((uintptr_t)x << n) ; } ATSinline() ats_uintptr_type atspre_lsr_uintptr_int1 (ats_uintptr_type x, ats_int_type n) { return (ats_uintptr_type)((uintptr_t)x >> n) ; } // print functions ATSinline() ats_void_type atspre_fprint_uintptr ( ats_ptr_type out, ats_uintptr_type u ) { int n ; n = fprintf ((FILE*)out, "%llu", (ats_ullint_type)(uintptr_t)u) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_uintptr] failed.\n") ; } // end of [if] return ; } // end of [atspre_fprint_uintptr] ATSinline() ats_void_type atspre_print_uintptr (ats_uintptr_type u) { // atspre_stdout_view_get () ; atspre_fprint_uintptr ((ats_ptr_type)stdout, u) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_uintptr (ats_uintptr_type u) { // atspre_stderr_view_get () ; atspre_fprint_uintptr ((ats_ptr_type)stderr, u) ; // atspre_stderr_view_set () ; return ; } /* ****** ****** */ #endif /* ATS_PRELUDE_INTEGER_PTR_CATS */ /* end of [integer_ptr.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/char.cats0000664000175000017500000001621512223166162017765 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_CHAR_CATS #define ATS_PRELUDE_CHAR_CATS /* ****** ****** */ #include #ifndef isascii extern int isascii (int c) ; // _XOPEN_SOURCE #endif // end of [isascii] #ifndef isblank extern int isblank (int c) ; // _XOPEN_SOURCE >= 600 #endif // end of [isblank] #ifndef toascii extern int toascii (int c) ; // _XOPEN_SOURCE #endif // end of [toascii] /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ /* // // HX: these are now casting functions: // ATSinline() ats_char_type atspre_char_of_schar (ats_schar_type c) { return c ; } ATSinline() ats_schar_type atspre_schar_of_char (ats_char_type c) { return c ; } ATSinline() ats_char_type atspre_char_of_uchar (ats_uchar_type c) { return c ; } ATSinline() ats_uchar_type atspre_uchar_of_char (ats_char_type c) { return c ; } */ /* ****** ****** */ ATSinline() ats_char_type atspre_char_of_int (ats_int_type i) { return i ; } ATSinline() ats_schar_type atspre_schar_of_int (ats_int_type i) { return i ; } ATSinline() ats_uchar_type atspre_uchar_of_int (ats_int_type i) { return i ; } /* ****** ****** */ ATSinline() ats_char_type atspre_char_of_uint (ats_uint_type u) { return u ; } ATSinline() ats_schar_type atspre_schar_of_uint (ats_uint_type u) { return u ; } ATSinline() ats_uchar_type atspre_uchar_of_uint (ats_uint_type u) { return u ; } /* ****** ****** */ #define atspre_char1_of_char atspre_char_of_char #define atspre_char1_of_int atspre_char_of_int #define atspre_char1_of_uint atspre_char_of_uint /* ****** ****** */ ATSinline() ats_int_type atspre_sub_char_char ( ats_char_type c1 , ats_char_type c2 ) { return (c1 - c2) ; } /* end of [atspre_sub_char_char] */ /* ****** ****** */ ATSinline() ats_bool_type atspre_lt_char_char (ats_char_type c1, ats_char_type c2) { return (c1 < c2) ; } // end of [atspre_lt_char_char] ATSinline() ats_bool_type atspre_lte_char_char (ats_char_type c1, ats_char_type c2) { return (c1 <= c2) ; } // end of [atspre_lte_char_char] ATSinline() ats_bool_type atspre_gt_char_char (ats_char_type c1, ats_char_type c2) { return (c1 > c2) ; } // end of [atspre_gt_char_char] ATSinline() ats_bool_type atspre_gte_char_char (ats_char_type c1, ats_char_type c2) { return (c1 >= c2) ; } // end of [atspre_gte_char_char] ATSinline() ats_bool_type atspre_eq_char_char (ats_char_type c1, ats_char_type c2) { return (c1 == c2) ; } // end of [atspre_eq_char_char] ATSinline() ats_bool_type atspre_neq_char_char (ats_char_type c1, ats_char_type c2) { return (c1 != c2) ; } // end of [atspre_neq_char_char] ATSinline() ats_int_type atspre_compare_char_char (ats_char_type c1, ats_char_type c2) { int i = c1 - c2 ; if (i > 0) return 1 ; if (i < 0) return -1 ; return 0 ; } /* end of [atspre_compare_char_char] */ /* ****** ****** */ // // HX: print functions // ATSinline() ats_void_type atspre_fprint_char ( ats_ptr_type out, ats_char_type c ) { int n = fputc ((unsigned char)c, (FILE*)out) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"Exit: [fprint_char] failed.\n") ; } // end of [if] return ; } // end of [atspre_fprint_char] ATSinline() ats_void_type atspre_print_char (ats_char_type c) { // atspre_stdout_view_get () ; atspre_fprint_char((ats_ptr_type)stdout, c) ; // atspre_stdout_view_set () ; return ; } ATSinline() ats_void_type atspre_prerr_char (ats_char_type c) { // atspre_stderr_view_get () ; atspre_fprint_char((ats_ptr_type)stderr, c) ; // atspre_stderr_view_set () ; return ; } // stringization ATSinline() ats_ptr_type atspre_tostrptr_char (ats_char_type c) { char *p ; p = (char *)ATS_MALLOC(2) ; *p = (char)c ; *(p+1) = '\000' ; return (ats_ptr_type)p ; } // end of [atspre_tostrptr_char] /* ****** ****** */ ATSinline() ats_bool_type atspre_char_isalnum (ats_char_type c) { return isalnum((int)c) ; } ATSinline() ats_bool_type atspre_char_isalpha (ats_char_type c) { return isalpha((int)c) ; } /* ****** ****** */ #ifndef isascii extern int isascii(int c) ; // declared in ctype.h #endif ATSinline() ats_bool_type atspre_char_isascii (ats_char_type c) { return isascii((int)c) ; } /* ****** ****** */ #ifndef isblank extern int isblank(int c) ; // declared in ctype.h #endif ATSinline() ats_bool_type atspre_char_isblank (ats_char_type c) { return isblank((int)c) ; } /* ****** ****** */ ATSinline() ats_bool_type atspre_char_iscntrl (ats_char_type c) { return iscntrl((int)c) ; } ATSinline() ats_bool_type atspre_char_isdigit (ats_char_type c) { return isdigit((int)c) ; } ATSinline() ats_bool_type atspre_char_isgraph (ats_char_type c) { return isgraph((int)c) ; } ATSinline() ats_bool_type atspre_char_islower (ats_char_type c) { return islower((int)c) ; } ATSinline() ats_bool_type atspre_char_isnull (ats_char_type c) { return (c == '\000' ? ats_true_bool : ats_false_bool) ; } // end of [atspre_char_isnull] ATSinline() ats_bool_type atspre_char_isprint (ats_char_type c) { return isprint((int)c) ; } ATSinline() ats_bool_type atspre_char_ispunct (ats_char_type c) { return ispunct((int)c) ; } ATSinline() ats_bool_type atspre_char_isspace (ats_char_type c) { return isspace((int)c) ; } ATSinline() ats_bool_type atspre_char_isupper (ats_char_type c) { return isupper((int)c) ; } ATSinline() ats_bool_type atspre_char_isxdigit (ats_char_type c) { return isxdigit((int)c) ; } /* ****** ****** */ ATSinline() ats_char_type atspre_char_tolower (ats_char_type c) { return (int)tolower((int)c) ; } ATSinline() ats_char_type atspre_char_toupper (ats_char_type c) { return (int)toupper((int)c) ; } /* ****** ****** */ #endif /* ATS_PRELUDE_CHAR_CATS */ /* end of [char.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/printf.cats0000664000175000017500000000625212223166162020352 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_PRINTF_CATS #define ATS_PRELUDE_PRINTF_CATS /* ****** ****** */ #include #include /* ****** ****** */ extern ats_void_type ats_exit_errmsg (ats_int_type n, ats_ptr_type msg) ; extern ats_void_type atspre_stdout_view_get() ; extern ats_void_type atspre_stdout_view_set() ; /* ****** ****** */ static ats_int_type atspre_fprintf_err (ats_ptr_type file, ats_ptr_type fmt, ...) { int n ; va_list ap ; va_start(ap, fmt) ; n = vfprintf((FILE *)file, (char *)fmt, ap) ; va_end(ap) ; return n ; } // end of [atspre_fprintf_err] static ats_void_type atspre_fprintf_exn ( ats_ptr_type file, ats_ptr_type fmt, ... ) { int n ; va_list ap ; va_start(ap, fmt) ; n = vfprintf((FILE *)file, (char *)fmt, ap) ; va_end(ap) ; if (n < 0) { ats_exit_errmsg(n, (ats_ptr_type)"exit(ATS): [fprintf] failed\n") ; } // end of [if] return ; } // end of [atspre_fprintf_exn] /* ****** ****** */ static ats_void_type atspre_printf_exn ( ats_ptr_type fmt, ... ) { int n ; va_list ap ; atspre_stdout_view_get() ; va_start(ap, fmt) ; n = vprintf((char*)fmt, ap) ; va_end(ap) ; atspre_stdout_view_set() ; if (n < 0) { ats_exit_errmsg(n, (ats_ptr_type)"exit(ATS): [printf] failed\n") ; } // end of [if] return ; } // end of [atspre_printf_exn] static ats_void_type atspre_prerrf_exn ( ats_ptr_type fmt, ... ) { int n ; va_list ap ; atspre_stderr_view_get() ; va_start(ap, fmt) ; n = vfprintf(stderr, (char *)fmt, ap) ; va_end(ap) ; atspre_stderr_view_set() ; if (n < 0) { ats_exit_errmsg(n, (ats_ptr_type)"exit(ATS): [prerrf] failed\n") ; } // end of [if] return ; } // end of [atspre_prerrf_exn] /* ****** ****** */ #endif /* ATS_PRELUDE_PRINTF_CATS */ /* end of [printf.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/pointer.cats0000664000175000017500000001336312223166162020531 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_POINTER_CATS #define ATS_PRELUDE_POINTER_CATS /* ****** ****** */ extern int fprintf (FILE *stream, const char *format, ...) ; // in [stdio.h] /* ****** ****** */ // // HX: [string.h] // #ifdef memset // // HX: [memset] is a macro on MACOS // #else extern void *memset(void *s, int c, size_t n); #endif #ifdef memcpy // // HX: [memcpy] is a macro on MACOS // #else extern void *memcpy(void *dest, const void *src, size_t n) ; #endif /* ****** ****** */ static ats_ptr_type atspre_null_ptr = (ats_ptr_type)0 ; ATSinline() ats_bool_type atspre_ptr_is_null (ats_ptr_type p) { return (p == (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_ptr_is_null] ATSinline() ats_bool_type atspre_ptr_isnot_null (ats_ptr_type p) { return (p != (ats_ptr_type)0 ? ats_true_bool : ats_false_bool) ; } // end of [atspre_ptr_isnot_null] /* ****** ****** */ // // HX-2010-04-19: // this one is to be used by various "free_null" functions // ATSinline() ats_void_type atspre_ptr_free_null (ats_ptr_type p) { return ; } // end of [atspre_ptr_free_null] /* ****** ****** */ ATSinline() ats_ptr_type atspre_psucc (ats_ptr_type p) { return (ats_ptr_type)((ats_byte_type*)p + 1) ; } ATSinline() ats_ptr_type atspre_ppred (ats_ptr_type p) { return (ats_ptr_type)((ats_byte_type*)p - 1) ; } /* ****** ****** */ ATSinline() ats_ptr_type atspre_padd_int ( ats_ptr_type p, ats_int_type n ) { return (ats_ptr_type)((ats_byte_type*)p + n) ; } // end of [atspre_padd_int] ATSinline() ats_ptr_type atspre_padd_size ( ats_ptr_type p, ats_size_type n ) { return (ats_ptr_type)((ats_byte_type*)p + n) ; } // end of [atspre_padd_size] ATSinline() ats_ptr_type atspre_psub_int ( ats_ptr_type p, ats_int_type n ) { return (ats_ptr_type)((ats_byte_type*)p - n) ; } // end of [atspre_psub_int] ATSinline() ats_ptr_type atspre_psub_size ( ats_ptr_type p, ats_size_type n ) { return (ats_ptr_type)((ats_byte_type*)p - n) ; } // end of [atspre_psub_size] ATSinline() ats_ptrdiff_type atspre_pdiff ( ats_ptr_type p1, ats_ptr_type p2 ) { return ((ats_byte_type*)p1 - (ats_byte_type*)p2) ; } /* ****** ****** */ ATSinline() ats_bool_type atspre_plt (ats_ptr_type p1, ats_ptr_type p2) { return (p1 < p2) ; } ATSinline() ats_bool_type atspre_plte (ats_ptr_type p1, ats_ptr_type p2) { return (p1 <= p2) ; } ATSinline() ats_bool_type atspre_pgt (ats_ptr_type p1, ats_ptr_type p2) { return (p1 > p2) ; } ATSinline() ats_bool_type atspre_pgte (ats_ptr_type p1, ats_ptr_type p2) { return (p1 >= p2) ; } ATSinline() ats_bool_type atspre_peq (ats_ptr_type p1, ats_ptr_type p2) { return (p1 == p2) ; } ATSinline() ats_bool_type atspre_pneq (ats_ptr_type p1, ats_ptr_type p2) { return (p1 != p2) ; } ATSinline() ats_int_type atspre_compare_ptr_ptr ( ats_ptr_type p1, ats_ptr_type p2 ) { if (p1 < p2) return (-1) ; else if (p1 > p2) return ( 1) ; else return (0) ; } /* end of [atspre_compare_ptr_ptr] */ /* ****** ****** */ // print functions ATSinline() ats_void_type atspre_fprint_ptr ( ats_ptr_type out, ats_ptr_type p ) { int n = fprintf ((FILE *)out, "%p", p) ; if (n < 0) { ats_exit_errmsg (n, (ats_ptr_type)"exit(ATS): [fprint_pointer] failed.\n") ; } /* end of [if] */ return ; } ATSinline() ats_void_type atspre_print_ptr(ats_ptr_type p) { // atspre_stdout_view_get() ; atspre_fprint_ptr ((ats_ptr_type)stdout, p) ; // atspre_stdout_view_set() ; return ; } ATSinline() ats_void_type atspre_prerr_ptr(ats_ptr_type p) { // atspre_stderr_view_get() ; atspre_fprint_ptr ((ats_ptr_type)stderr, p) ; // atspre_stderr_view_set() ; return ; } /* ****** ****** */ ATSinline() ats_ptr_type atspre_ptr_alloc_tsz (ats_size_type tsz) { ats_ptr_type p ; p = ATS_MALLOC(tsz) ; return (ats_ptr_type)p ; } // end of [atspre_ptr_alloc_tsz] ATSinline() ats_void_type atspre_ptr_free(ats_ptr_type ptr) { ATS_FREE(ptr) ; return ; } /* ****** ****** */ ATSinline() ats_void_type atspre_ptr_zero_tsz (ats_ref_type p, ats_size_type tsz) { memset (p, 0, tsz) ; return ; } // end of [atspre_ptr_zero] /* ****** ****** */ // HX: for both [ptr_move_t_tsz] and [ptr_move_vt_tsz] ATSinline() ats_void_type atspre_ptr_move_tsz ( ats_ptr_type p1 , ats_ptr_type p2 , ats_size_type tsz ) { memcpy ((void*)p2, (void*)p1, tsz) ; return ; } // end of ... /* ****** ****** */ #endif /* ATS_PRELUDE_POINTER_CATS */ /* end of [pointer.cats] */ ats-lang-anairiats-0.2.11/prelude/CATS/basics.cats0000664000175000017500000001653112223166162020315 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_BASICS_CATS #define ATS_PRELUDE_BASICS_CATS /* ****** ****** */ #include #include /* ****** ****** */ #define _ATS_RUNTIME_CHECK #undef _ATS_RUNTIME_CHECK // uncomment it for debugging /* ****** ****** */ /* ** HX-2011-05-06: */ extern ats_empty_type ats_empty_value ; /* ****** ****** */ /* ** HX-2010-02-07: this one is used in many places */ ATSinline() ats_ptr_type atspre_castfn_ptr (ats_ptr_type p) { return p ; } /* ****** ****** */ /* ** HX-2011-02-26: ** this one is used to prevent tail-recursion optimization */ ATSinline() ats_void_type atspre_donothing () { return ; } /* ****** ****** */ ATSinline() ats_void_type atspre_free_null () { return ; } /* ****** ****** */ /* ** HX: cutting the corners? yes. worth it? probably. */ ATSinline() ats_ptr_type atspre_fun_coerce (ats_ptr_type p) { return p ; } ATSinline() ats_ptr_type atspre_clo_coerce (ats_ptr_type p) { return p ; } /* ****** ****** */ ATSinline() ats_ptr_type atspre_cloptr_get_view_ptr (ats_ptr_type p) { return p ; } /* ****** ****** */ ATSinline() ats_void_type atspre_cloptr_free ( ats_ptr_type p ) { ATS_FREE (p) ; return ; } // end of [atspre_cloptr_free] /* ****** ****** */ ATSinline() ats_void_type atspre_vbox_make_view_ptr (ats_ptr_type p) { return ; } ATSinline() ats_void_type atspre_vbox_make_view_ptr_gc (ats_ptr_type p) { return ; } /* ****** ****** */ /* ** HX: various functions for exits */ // implemented in [prelude/DATS/basics.dats] extern ats_void_type ats_exit (const ats_int_type n) ; // end of [ats_exit] // implemented in [prelude/DATS/basics.dats] extern ats_void_type ats_exit_errmsg (const ats_int_type n, const ats_ptr_type msg) ; // end of [ats_exit_errmsg] // implemented in [prelude/DATS/printf.dats] extern ats_void_type atspre_exit_prerrf (ats_int_type code, ats_ptr_type fmt, ...) ; // end of [atspre_exit_prerrf] /* ****** ****** */ // // HX: these will probably be removed in ATS/Postiats // extern int ats_stdin_view_lock ; extern int ats_stdout_view_lock ; extern int ats_stderr_view_lock ; /* ****** ****** */ ATSinline() ats_ptr_type atspre_stdin_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stdin_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdin_get] failed\n") ; } // end of [if] ats_stdin_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return (ats_ptr_type)stdin; } // end of [atspre_stdin_get] ATSinline() ats_void_type atspre_stdin_view_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stdin_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdin_view_get] failed\n") ; } // end of [if] ats_stdin_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stdin_view_get] ATSinline() ats_void_type atspre_stdin_view_set () { #ifdef _ATS_RUNTIME_CHECK if (ats_stdin_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdin_view_set] failed\n") ; } // end of [if] ats_stdin_view_lock = 1 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stdin_view_set] /* ****** ****** */ ATSinline() ats_ptr_type atspre_stdout_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stdout_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdout_get] failed\n") ; } // end of [if] ats_stdout_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return (ats_ptr_type)stdout ; } // end of [atspre_stdout_get] ATSinline() ats_void_type atspre_stdout_view_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stdout_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdout_view_get] failed\n") ; } // end of [if] ats_stdout_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stdout_view_get] ATSinline() ats_void_type atspre_stdout_view_set () { #ifdef _ATS_RUNTIME_CHECK if (ats_stdout_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stdout_view_set] failed\n") ; } // end of [if] ats_stdout_view_lock = 1 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stdout_view_set] /* ****** ****** */ ATSinline() ats_ptr_type atspre_stderr_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stderr_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stderr_get] failed\n") ; } // end of [if] ats_stderr_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return (ats_ptr_type)stderr ; } // end of [atspre_stderr_get] ATSinline() ats_void_type atspre_stderr_view_get () { #ifdef _ATS_RUNTIME_CHECK if (!ats_stderr_view_lock) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [stderr_view_get] failed\n") ; } // end of [if] ats_stderr_view_lock = 0 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stderr_view_get] ATSinline() ats_void_type atspre_stderr_view_set () { #ifdef _ATS_RUNTIME_CHECK if (ats_stderr_view_lock) { ats_exit_errmsg (EXIT_FAILURE, (ats_ptr_type)"exit(ATS): [stderr_view_set] failed\n") ; } // end of [if] ats_stderr_view_lock = 1 ; #endif // end of [_ATS_RUNTIME_CHECK] return ; } // end of [atspre_stderr_view_set] /* ****** ****** */ // // HX: // printing a newline on a given stream also fflushes the buffer // associated with the stream. // ATSinline() ats_void_type atspre_fprint_newline ( const ats_ptr_type out ) { int n1, n2 ; n1 = fprintf((FILE*)out, "\n") ; n2 = fflush((FILE*)out) ; #if(0) // HX: this is too much ... if (n1 + n2 < 0) { ats_exit_errmsg (EXIT_FAILURE, (ats_ptr_type)"exit(ATS): [fprint_newline] failed.\n") ; } // end of [if] #endif // end of [#if(0)] return ; } // end of [atspre_fprint_newline] ATSinline() ats_void_type atspre_print_newline () { atspre_stdout_view_get() ; atspre_fprint_newline((ats_ptr_type)stdout) ; atspre_stdout_view_set() ; return ; } // end of [atspre_print_newline] ATSinline() ats_void_type atspre_prerr_newline () { atspre_stderr_view_get() ; atspre_fprint_newline((ats_ptr_type)stderr) ; atspre_stderr_view_set() ; return ; } // end of [atspre_prerr_newline] /* ****** ****** */ #endif /* ATS_PRELUDE_BASICS_CATS */ ats-lang-anairiats-0.2.11/prelude/sortdef.sats0000664000175000017500000000543512223166162020006 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [sortdef.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // some sort definitions sortdef igz = {a: int | a > 0} and ilz = {a: int | a < 0} and inz = {a: int | a <> 0} sortdef nat = {a: int | a >= 0} and pos = {a: int | a > 0} and neg = {a: int | a < 0} sortdef one = {a: int | 0 <= a; a < 1} and two = {a: int | 0 <= a; a < 2} and three = {a: int | 0 <= a; a < 3} and four = {a: int | 0 <= a; a < 4} and five = {a: int | 0 <= a; a < 5} and six = {a: int | 0 <= a; a < 6} and seven = {a: int | 0 <= a; a < 7} and eight = {a: int | 0 <= a; a < 8} and nine = {a: int | 0 <= a; a < 9} and ten = {a: int | 0 <= a; a < 10} sortdef sgn = {a: int | ~1 <= a; a <= 1} sortdef int8 = {i:int | ~power_2_7 <= i; i < power_2_7} sortdef int16 = {i:int | ~power_2_15 <= i; i < power_2_15} sortdef agz = {a:addr | a > null} and agez = {a:addr | a >= null} (* ****** ****** *) // // HX-2009: // should parameterized subset sorts be suported? // sortdef intbtw (l: int, u: int) = {a: int | l <= a; a < u} // (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [sortdef.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* end of [sortdef.sats] *) ats-lang-anairiats-0.2.11/prelude/params_system.hats0000664000175000017500000000341012223166162021203 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some system parameters // #define NBIT_PER_BYTE 8 (* 8 bits in each byte *) // // The following one is machine-dependent! // #define NBYTE_PER_WORD // 4 or 8 bytes in each word // // // The following one is OS-dependent! // #define SYSTEM_IS_UNIX_LIKE 1 (* ****** ****** *) (* end of [params_system.hats] *) ats-lang-anairiats-0.2.11/prelude/SATS/0000700000175000017500000000000012223166161016172 5ustar hwxihwxiats-lang-anairiats-0.2.11/prelude/SATS/multiset.sats0000664000175000017500000000751612223166161020761 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [multiset.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) datasort elt = // abstract // positive integer sta lt_elt_elt_bool : (elt, elt) -> bool sta lte_elt_elt_bool : (elt, elt) -> bool sta gt_elt_elt_bool : (elt, elt) -> bool sta gte_elt_elt_bool : (elt, elt) -> bool stadef < = lt_elt_elt_bool stadef <= = lte_elt_elt_bool stadef > = gt_elt_elt_bool stadef >= = gte_elt_elt_bool (* sta elt_first : elt // elt_first = 1 praxi elt_first_lemma {x: elt} (): [elt_first <= x] void *) (* ****** ****** *) datasort eltlst = eltlst_nil of () | eltlst_cons of (elt, eltlst) // end of [eltlst] (* ****** ****** *) datasort eltmset = // abstract // natural number sta eltmset_nil : eltmset // the empty set sta add_elt_eltmset_eltmset : (elt, eltmset) -> eltmset stadef + = add_elt_eltmset_eltmset sta add_eltmset_elt_eltmset : (eltmset, elt) -> eltmset stadef + = add_eltmset_elt_eltmset sta add_eltmset_eltmset_eltmset : (eltmset, eltmset) -> eltmset stadef + = add_eltmset_eltmset_eltmset (* ****** ****** *) dataprop ELTLSTMSET (eltlst, eltmset) = | {x:elt} {xs:eltlst} {mst:eltmset} ELTLSTMSETcons (eltlst_cons (x, xs), x+mst) of ELTLSTMSET (xs, mst) | ELTLSTMSETnil (eltlst_nil, eltmset_nil) // end of [ELTLSTMSET] prfun ELTLSTMSET_istot {xs:eltlst} (): [xs1:eltmset] ELTLSTMSET (xs, xs1) prfun ELTLSTMSET_isfun {xs:eltlst} {xs1,xs2:eltmset} (pf1: ELTLSTMSET (xs, xs1), pf2: ELTLSTMSET (xs, xs2)): [xs1==xs2] void (* ****** ****** *) dataprop ELTMSETSZ (eltmset, int) = | {x:elt} {xs:eltmset} {n:nat} ELTMSETSZcons (x+xs, n+1) of ELTMSETSZ (xs, n) | ELTMSETSZnil (eltmset_nil, 0) prfun ELTMSETSZ_istot {xs:eltmset} (): [n:nat] ELTMSETSZ (xs, n) prfun ELTMSETSZ_isfun {xs:eltmset} {n1,n2:nat} (pf1: ELTMSETSZ (xs, n1), pf2: ELTMSETSZ (xs, n2)): [n1==n2] void (* ****** ****** *) absprop ELTMSETLB (elt, eltmset) absprop ELTMSETUB (eltmset, elt) prfun ELTMSETLB_monotone {l1,l2:elt | l1 <= l2} {xs:eltmset} (pf: ELTMSETLB (l2, xs)): ELTMSETLB (l1, xs) // end of [ELTMSETLB_monotone] prfun ELTMSETUB_monotone {u1,u2:elt | u1 <= u2} {xs:eltmset} (pf: ELTMSETUB (xs, u1)): ELTMSETUB (xs, u2) // end of [ELTMSETUB_monotone] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [multiset.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [multiset.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/matrix.sats0000664000175000017500000002012612223166161020407 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [matrix.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // HX: [mtrxt] is row-major // absviewt@ype mtrxt // flat matrix type (a:viewt@ype+, row:int, col:int) = @[@[a][col]][row] // end of [mtrxt] viewdef matrix_v (a:viewt@ype, m:int, n:int, l:addr) = mtrxt (a, m, n) @ l // end of [matrix_v] (* ****** ****** *) prfun array_v_of_matrix_v {a:viewt@ype}{m,n:nat}{l:addr} ( pf_mat: matrix_v (a, m, n, l) ) :<> [mn:nat] (MUL (m, n, mn), array_v (a, mn, l)) prfun matrix_v_of_array_v {a:viewt@ype}{m,n:nat}{mn:int}{l:addr} ( pf_mul: MUL (m, n, mn), pf_arr: array_v (a, mn, l) ) :<> matrix_v (a, m, n, l) (* ****** ****** *) fun{a:viewt@ype} matrix_ptr_takeout_row {m,n:int} {i:int | i < m} {l0:addr} ( pf_mat: matrix_v (a, m, n, l0) | base: ptr l0, i: size_t i, n: size_t n ) :<> [l:addr] ( array_v (a, n, l) , array_v (a, n, l) - matrix_v (a, m, n, l0) | ptr l ) // end of [matrix_ptr_takeout_row] fun matrix_ptr_takeout_row_tsz {a:viewt@ype} {m,n:int} {i:int | i < m} {l0:addr} ( pf_mat: matrix_v (a, m, n, l0) | base: ptr l0, i: size_t i, n: size_t n, tsz: sizeof_t a ) :<> [l:addr] ( array_v (a, n, l) , array_v (a, n, l) - matrix_v (a, m, n, l0) | ptr l ) = "atspre_matrix_ptr_takeout_row_tsz" (* // // HX: this is not a completely safe version, but ... // fun{a:viewt@ype} matrix_ptr_vtakeout_row {m,n:int} {i:nat | i < m} {l0:addr} ( pf_mat: matrix_v (a, m, n, l0) | base: ptr l0 , i: size_t i , n: size_t n ) : [l:addr] ( array_v (a, n, l) , array_v (a, n, l) -<> void | ptr l // l = l0 + i*n*sizeof ) // end of [matrix_ptr_vtakeout_row] *) (* ****** ****** *) fun{a:viewt@ype} matrix_ptr_takeout_elt {m,n:int} {i,j:nat | i < m; j < n} {l0:addr} ( pf_mat: matrix_v (a, m, n, l0) | base: ptr l0, i: size_t i, n: size_t n, j: size_t j ) :<> [l:addr] ( a @ l , a @ l - matrix_v (a, m, n, l0) | ptr l ) // end of [matrix_ptr_takeout_elt] fun matrix_ptr_takeout_elt_tsz {a:viewt@ype} {m,n:int} {i,j:nat | i < m; j < n} {l0:addr} ( pf_mat: matrix_v (a, m, n, l0) | base: ptr l0, i: size_t i, n: size_t n, j: size_t j, tsz: sizeof_t a ) :<> [l:addr] ( a @ l , a @ l - matrix_v (a, m, n, l0) | ptr l ) = "atspre_matrix_ptr_takeout_elt_tsz" (* ****** ****** *) (* ** ** persistent matrices ** *) (* ****** ****** *) exception MatrixSubscriptException of () (* ****** ****** *) fun matrix_make_arrpsz {a:viewt@ype} {m,n:nat} ( m: size_t m, n: size_t n, psz: arrpsz (a, m*n) ) :<> matrix (a, m, n) // end of [matrix_make_arrpsz] (* ****** ****** *) // // HX: implemented in [prelude/DATS/matrix.dats] // fun matrix_make_arrpsz__main {a:viewt@ype}{m,n:nat}{mn:int} ( pf: MUL (m, n, mn) | m: size_t m, n: size_t n, psz: arrpsz (a, mn) ) :<> matrix (a, m, n) = "atspre_matrix_make_arrpsz__main" // end of [matrix_make_arrpsz__main] (* ****** ****** *) fun{a:t@ype} matrix_make_elt {m,n:pos} (row: size_t m, col: size_t n, elt: a):<> matrix (a, m, n) // end of [matrix_make_elt] (* ****** ****** *) // // HX: implemented in [prelude/DATS/matrix.dats] // fun matrix_make_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {m,n:pos} {f:eff} ( pf: !v | row: size_t m, col: size_t n , f: (!v | sizeLt m, sizeLt n, &(a?) >> a, !vt) - void , tsz: sizeof_t a , env: !vt ) : matrix (a, m, n) = "atspre_matrix_make_funenv_tsz" // end of [fun] fun{a:viewt@ype} matrix_make_fun {m,n:pos} {f:eff} ( row: size_t m, col: size_t n , f: (sizeLt m, sizeLt n, &(a?) >> a) - void ) : matrix (a, m, n) // end of [matrix_make_fun_tsz] fun{a:viewt@ype} matrix_make_vclo {v:view} {m,n:pos} {f:eff} ( pfv: !v | row: size_t m, col: size_t n , f: &(!v | sizeLt m, sizeLt n, &(a?) >> a) - void ) : matrix (a, m, n) // end of [matrix_make_vclo] (* ****** ****** *) fun{a:t@ype} matrix_get_elt_at {m,n:int} {i,j:nat | i < m; j < n} (A: matrix (a, m, n), i: size_t i, n: size_t n, j: size_t j): a overload [] with matrix_get_elt_at fun{a:t@ype} matrix_set_elt_at {m,n:int} {i,j:nat | i < m; j < n} (A: matrix (a, m, n), i: size_t i, n: size_t n, j: size_t j, x: a): void overload [] with matrix_set_elt_at (* ****** ****** *) fun{a:t@ype} matrix_get_elt_at__intsz {m,n:int} {i,j:nat | i < m; j < n} (A: matrix (a, m, n), i: int i, n: int n, j: int j): a overload [] with matrix_get_elt_at__intsz fun{a:t@ype} matrix_set_elt_at__intsz {m,n:int} {i,j:nat | i < m; j < n} (A: matrix (a, m, n), i: int i, n: int n, j: int j, x: a): void overload [] with matrix_set_elt_at__intsz (* ****** ****** *) // // HX: // these foreach-functions are just as easy to be // implemented on the spot // (* ****** ****** *) (* ** HX: implemented in ATS (prelude/DATS/matrix.dats) *) fun{a:viewt@ype} matrix_foreach_funenv {v:view} {vt:viewtype} {m,n:nat} ( pf: !v | M: matrix (a, m, n) , f: (!v | &a, !vt) - void, m: size_t m, n: size_t n , env: !vt ) : void // end of [matrix_foreach_funenv] fun{a:viewt@ype} matrix_foreach_fun {m,n:nat} ( M: matrix (a, m, n) , f: (&a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_foreach_fun] fun{a:viewt@ype} matrix_foreach_vclo {v:view} {m,n:nat} ( pf: !v | M: matrix (a, m, n) , f: &(!v | &a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_foreach_vclo] fun{a:viewt@ype} matrix_foreach_cloref {m,n:nat} ( M: matrix (a, m, n), f: (&a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_foreach_cloref] (* ****** ****** *) // // HX: // these iforeach-functions are just as easy to be // implemented on the spot // (* ****** ****** *) (* ** HX: implemented in ATS (prelude/DATS/matrix.dats) *) fun{a:viewt@ype} matrix_iforeach_funenv {v:view} {vt:viewtype} {m,n:nat} ( pf: !v | M: matrix (a, m, n) , f: (!v | sizeLt m, sizeLt n, &a, !vt) - void, m: size_t m, n: size_t n , env: !vt ) : void // end of [matrix_iforeach_funenv] fun{a:viewt@ype} matrix_iforeach_fun {m,n:nat} ( M: matrix (a, m, n) , f: (sizeLt m, sizeLt n, &a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_iforeach_fun] fun{a:viewt@ype} matrix_iforeach_vclo {v:view} {m,n:nat} ( pf: !v | M: matrix (a, m, n) , f: &(!v | sizeLt m, sizeLt n, &a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_iforeach_vclo] fun{a:viewt@ype} matrix_iforeach_cloref {m,n:nat} ( M: matrix (a, m, n) , f: (sizeLt m, sizeLt n, &a) - void, m: size_t m, n: size_t n ) : void // end of [matrix_iforeach_cloref] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [matrix.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [matrix.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/filebas.sats0000664000175000017500000001326112223166161020512 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* Time: 2008 *) (* ****** ****** *) // // HX: Attention! // // The functions declared here are mostly done for the sake of convenience. // Please turn on GC if functions like [input_line] and [output_line] are // called repeatedly. // // For full-fledged IO support, please see [$ATSHOME/libc/SATS/stdio.sats]. // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) // // some basic IO operations // #if VERBOSE_PRELUDE #then #print "Loading [filebas.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) typedef file_mode = [m:file_mode] file_mode (m) (* ****** ****** *) macdef file_mode_r = $extval (file_mode r, "\"r\"") macdef file_mode_rr = $extval (file_mode rw, "\"r+\"") macdef file_mode_w = $extval (file_mode w, "\"w\"") macdef file_mode_ww = $extval (file_mode rw, "\"w+\"") macdef file_mode_a = $extval (file_mode w, "\"a\"") macdef file_mode_aa = $extval (file_mode rw, "\"a+\"") (* ****** ****** *) macdef EOF = $extval (int, "EOF") macdef stdin_ref = $extval (FILEref, "stdin") macdef stdout_ref = $extval (FILEref, "stdout") macdef stderr_ref = $extval (FILEref, "stderr") (* ****** ****** *) fun open_file_exn // exit on failure (path: string, mode: file_mode): FILEref = "atslib_fopen_exn" // end of [open_file_exn] fun close_file_exn (fil: FILEref): void = "atslib_fclose_exn" fun reopen_file_exn // exit on failure (path: string, mode: file_mode, fil: FILEref): void = "atslib_freopen_exn" // end of [reopen_file_exp] (* ****** ****** *) fun fflush_exn (fil: FILEref): void = "atslib_fflush_exn" (* ****** ****** *) fun test_file_eof (fil: FILEref): bool = "atslib_feof" (* ****** ****** *) fun test_file_exists // [stat] is called (path: string): bool = "atspre_test_file_exists" // end of [test_file_exists] (* ****** ****** *) // // HX-2011-02-16: // [stat] is called to obtain the mode of a given file // for [f] to be applied to it. // fun test_file_mode (path: string, f: uint -> bool): Int // // HX: [stat] is called // ~1/0/1: error/false/true // fun test_file_isblk (path: string): int = "atspre_test_file_isblk" fun test_file_ischr (path: string): int = "atspre_test_file_ischr" fun test_file_isdir (path: string): int = "atspre_test_file_isdir" fun test_file_isfifo (path: string): int = "atspre_test_file_isfifo" fun test_file_isreg (path: string): int = "atspre_test_file_isreg" // // HX: [lstat] is called // fun test_file_isemp (path: string): int // ~1/0/1: error/false/true fun test_file_islnk (path: string): int // ~1/0/1: error/false/true // (* ****** ****** *) (* ** [input_line] reads a sequence of characters ending with a newline ** character or EOF; the string returned by [input_line] does not include ** the newline character it reads; if [input_line] encounters EOF when it ** starts, then stropt_none (a null pointer) is returned. *) fun input_line (fil: FILEref): Stropt fun input_line_vt (fil: FILEref): strptr0 (* ** [output_line] writes to a given file handle a string plus a newline ** character at the end. *) fun output_line (fil: FILEref, line: string): void (* ****** ****** *) fun char_list_vt_make_file (fil: FILEref): List_vt (char) fun char_list_vt_make_file_len (fil: FILEref, n: size_t): List_vt (char) (* ****** ****** *) // // HX: making a lazy char stream out of a file handle // fun char_stream_make_file (fil: FILEref): stream (char) // making a lazy line stream out of a file handle // note that the newline character at the end of each line is dropped fun line_stream_make_file (fil: FILEref): stream (string) (* ****** ****** *) // // HX: making a _linear_ lazy char stream out of a file handle // fun char_stream_vt_make_file {m:file_mode} {l:addr} ( pf_mod: file_mode_lte (m, r), pf_fil: FILE m @ l | p_fil: ptr l ) : stream_vt (char) // end of [char_stream_vt_make_file] (* ****** ****** *) // // HX: // making a _linear_ lazy line stream out of a file handle // note that the newline character at the end of each line is dropped // fun line_stream_vt_make_file {m:file_mode} {l:addr} ( pf_mod: file_mode_lte (m, r), pf_fil: FILE m @ l | p_fil: ptr l ) : stream_vt (strptr1) // end of [line_stream_vt_make_file] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [filebas.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [filebas.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/vsubrw.sats0000664000175000017500000000624512223166161020441 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: some proof functions involving view containment. // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [vsubrw.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) prfun vsubr_intr {v1,v2:view} (fpf: v2 - [v:view] (v1, v)): vsubr_p (v1, v2) // implemented in [vsubrw.dats] prfun vsubr_elim {v1,v2:view} (pf: vsubr_p (v1, v2)):<> v2 - [v:view] (v1, v) // implemented in [vsubrw.dats] prfun vsubr_refl {v:view} (): vsubr_p (v, v) prfun vsubr_trans {v1,v2,v3:view} (pf12: vsubr_p (v1, v2), pf23: vsubr_p (v2, v3)): vsubr_p (v1, v3) // end of [vcontain_trans] prfun vsubr_of_vsubw {v1,v2:view} (pf: vsubw_p (v1, v2)): vsubr_p (v1, v2) prfun vsubr_tup_2_0 {v0,v1:view} (): vsubr_p (v0, @(v0, v1)) prfun vsubr_tup_2_1 {v0,v1:view} (): vsubr_p (v1, @(v0, v1)) (* ****** ****** *) prfun vsubw_intr {v1,v2:view} (fpf: v2 - (v1, v1 - v2)): vsubw_p (v1, v2) // implemented in [vsubrw.dats] prfun vsubw_elim {v1,v2:view} (pf: vsubw_p (v1, v2)):<> v2 - (v1, v1 - v2) // implemented in [vsubrw.dats] prfun vsubw_tup_2_0 {v0,v1:view} (): vsubw_p (v0, @(v0, v1)) prfun vsubw_tup_2_1 {v0,v1:view} (): vsubw_p (v1, @(v0, v1)) (* ****** ****** *) prval vsubw_array_elt : {a:viewtype} {n,i:nat | i < n} {l:addr} {ofs:int} MUL (i, sizeof a, ofs) -<> vsubw_p (a @ l + ofs, @[a][n] @ l) prval vsubw_array_subarray : {a:viewtype} {n0,i,n:nat | i+n <= n0} {l:addr} {ofs:int} MUL (i, sizeof a, ofs) -<> vsubw_p (@[a][n] @ l + ofs, @[a][n0] @ l) (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [vsubrw.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* end of [vsubrw.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/option0.sats0000664000175000017500000000400412223166161020470 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: 2010 *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option0.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) castfn option0_of_option1 {a:t@ype} (xs: Option a):<> option0 a castfn option1_of_option0 {a:t@ype} (xs: option0 a):<> Option a (* ****** ****** *) castfn option0_of_option_vt {a:t@ype} (xs: Option_vt a):<> option0 a (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option0.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [option0.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/lazy_vt.sats0000664000175000017500000000655112223166161020601 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [lazy_vt.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) fun{ a:viewt@ype } list_vt_of_stream_vt (xs: stream_vt a): [n:nat] (int n, list_vt (a, n)) // end of [list_vt_of_stream_vt] (* ****** ****** *) fun{a:t@ype} stream_vt_free (xs: stream_vt a): void (* ****** ****** *) fun{a:t@ype} stream_vt_filter_fun (xs: stream_vt a, pred: (&a) - bool): stream_vt a // end of [stream_vt_filter_fun] fun{a:t@ype} stream_vt_filter_cloptr (xs: stream_vt a, pred: (&a) - bool): stream_vt a // end of [stream_vt_filter_cloptr] (* ****** ****** *) fun{a:viewt@ype}{b:viewt@ype} stream_vt_map_fun (xs: stream_vt a, f: (&a >> a?) - b): stream_vt b // end of [stream_vt_map_fun] fun{a:viewt@ype}{b:viewt@ype} stream_vt_map_cloptr (xs: stream_vt a, f: (&a >> a?) - b): stream_vt b // end of [stream_vt_map_cloptr] (* ****** ****** *) // // HX: it is intended that no call-by-reference for [f] // fun{a1,a2:t@ype}{b:viewt@ype} stream_vt_map2_fun (xs1: stream_vt a1, xs2: stream_vt a2, f: (a1, a2) - b) : stream_vt b // end of [stream_vt_map2_fun] fun{a1,a2:t@ype}{b:viewt@ype} stream_vt_map2_cloptr (xs1: stream_vt a1, xs2: stream_vt a2, f: (a1, a2) - b) : stream_vt b // end of [stream_vt_map2_cloptr] (* ****** ****** *) fun{a1,a2:t@ype} stream_vt_of_lstlstprod {n1,n2:nat} (xs1: list_vt (a1, n1), xs2: list_vt (a2, n2)): stream_vt @(a1, a2) // end of [stream_vt_of_lstlstprod] (* ****** ****** *) fun{a1,a2:t@ype} stream_vt_of_strmlstprod {n:nat} (xs1: stream_vt (a1), xs2: list_vt (a2, n)): stream_vt @(a1, a2) // end of [stream_vt_of_strmlstprod] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [lazy_vt.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [lazy_vt.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/byte.sats0000664000175000017500000001161112223166161020045 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // note that a byte is just an unsigned char (uchar) (* ****** ****** *) #define BYTE_MAX 255 // 2^8 - 1 (* ****** ****** *) castfn byte_of_char (c: char):<> byte (* = "atspre_byte_of_char" *) castfn char_of_byte (b: byte):<> char (* = "atspre_char_of_byte" *) castfn byte_of_uchar (c: uchar):<> byte castfn uchar_of_byte (b: byte):<> uchar (* ****** ****** *) fun byte_of_int (i: int):<> byte = "atspre_byte_of_int" and int_of_byte (b: byte):<> int = "atspre_int_of_byte" fun byte_of_int1 {i:nat | i <= BYTE_MAX} (i: int i):<> byte = "atspre_byte_of_int" and int1_of_byte (b: byte):<> [i:nat | i <= BYTE_MAX] int i = "atspre_int_of_byte" fun byte_of_uint (u: uint):<> byte = "atspre_byte_of_uint" and uint_of_byte (b: byte):<> uint = "atspre_uint_of_byte" fun byte_of_uint1 {i:nat | i <= BYTE_MAX} (i: uint i):<> byte = "atspre_byte_of_int" and uint1_of_byte (b: byte):<> [i:nat | i <= BYTE_MAX] uint i = "atspre_int_of_byte" // // arithmetic functions and comparison functions // fun succ_byte (b: byte):<> byte = "atspre_succ_byte" overload succ with succ_byte fun pred_byte (b: byte):<> byte = "atspre_pred_byte" overload pred with pred_byte fun add_byte_byte (b1: byte, b2: byte):<> byte = "atspre_add_byte_byte" overload + with add_byte_byte fun sub_byte_byte (b1: byte, b2: byte):<> byte = "atspre_suc_byte_byte" overload - with sub_byte_byte fun mul_byte_byte (b1: byte, b2: byte):<> byte = "atspre_mul_byte_byte" overload * with mul_byte_byte fun div_byte_byte (b1: byte, b2: byte):<> byte = "atspre_div_byte_byte" overload / with div_byte_byte // // some operations on bytes // fun lt_byte_byte (b1: byte, b2: byte):<> bool = "atspre_lt_byte_byte" overload < with lt_byte_byte fun lte_byte_byte (b1: byte, b2: byte):<> bool = "atspre_lte_byte_byte" overload <= with lte_byte_byte fun gt_byte_byte (b1: byte, b2: byte):<> bool = "atspre_gt_byte_byte" overload > with gt_byte_byte fun gte_byte_byte (b1: byte, b2: byte):<> bool = "atspre_gte_byte_byte" overload >= with gte_byte_byte fun eq_byte_byte (b1: byte, b2: byte):<> bool = "atspre_eq_byte_byte" overload = with eq_byte_byte fun neq_byte_byte (b1: byte, b2: byte):<> bool = "atspre_neq_byte_byte" overload <> with neq_byte_byte // // bit operations // fun lnot_byte (b: byte):<> byte (*bitwise*) = "atspre_lnot_byte" overload ~ with lnot_byte fun land_byte_byte (b1: byte, b2: byte):<> byte = "atspre_land_byte_byte" overload land with land_byte_byte fun lor_byte_byte (b1: byte, b2: byte):<> byte = "atspre_lor_byte_byte" overload lor with lor_byte_byte fun lxor_byte_byte (b1: byte, b2: byte):<> byte = "atspre_lxor_byte_byte" overload lxor with lxor_byte_byte fun lsl_byte_int1 (b: byte, n: Nat):<> byte = "atspre_lsl_byte_int1" overload << with lsl_byte_int1 fun lsr_byte_int1 (b: byte, n: Nat):<> byte = "atspre_lsr_byte_int1" overload >> with lsr_byte_int1 (* ****** ****** *) // // print functions for characters // symintr fprint_byte fun fprint0_byte (out: FILEref, x: byte): void = "atspre_fprint_byte" overload fprint_byte with fprint0_byte fun fprint1_byte {m:file_mode} (pf: file_mode_lte (m, w) | out: !FILE m, x: byte): void = "atspre_fprint_byte" overload fprint_byte with fprint1_byte overload fprint with fprint_byte fun print_byte (b: byte): void = "atspre_print_byte" and prerr_byte (b: byte): void = "atspre_prerr_byte" overload print with print_byte overload prerr with prerr_byte (* ****** ****** *) (* end of [bytes.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/syndef.sats0000664000175000017500000000447012223166161020377 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) typedef atsyndef__List (a:t@ype) = [n:nat] list_t0ype_int_type (a, n) (* ****** ****** *) fun{a:t@ype} atsyndef__of_int (i: int): a (* ****** ****** *) fun{} atsyndef__list_is_nil {a:t@ype} {n:nat} (xs: list (a, n)):<> bool (n == 0) fun{} atsyndef__list_is_cons {a:t@ype} {n:nat} (xs: list (a, n)):<> bool ( n > 0 ) (* ****** ****** *) fun{a:t@ype} atsyndef__list_uncons {n:pos} (xs: list (a, n), x: &a? >> a):<> list (a, n-1) // end of [list_uncons] (* ****** ****** *) (* fun{a:t@ype} atsyndef__forlist_in_do (xs: List a, f: !(a) - void): void // end of [forlist_in_do] fun{a:t@ype} atsyndef__iforlist_in_do {n:nat} (xs: list (a, n), f: !(natLt n, a) - void): void // end of [iforlist_in_do] *) (* ****** ****** *) (* end of [syndef.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/memory.sats0000664000175000017500000001254212223166161020416 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [memory.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) typedef bytes (n:int) = @[byte][n] typedef b0ytes (n:int) = @[byte?][n] (* ****** ****** *) prfun bytes_v_split {n:int} {i:nat | i <= n} {l:addr} (pf: bytes(n) @ l): (bytes (i) @ l, bytes (n-i) @ l+i) // end of [bytes_v_split] prfun bytes_v_unsplit {n1,n2:nat} {l:addr} (pf1: bytes(n1) @ l, pf2: bytes(n2) @ l+n1): bytes(n1+n2) @ l // end of [bytes_v_unsplit] (* ****** ****** *) // praxi ptr_to_b0ytes_v : {a:viewt@ype} {l:addr} a? @ l - b0ytes (sizeof a) @ l // end of [ptr_to_b0ytes_v] (* ****** ****** *) // // the following declared functions are implemented in [ats_prelude_gcats.c] // (* ****** ****** *) fun gc_init (): void = "ats_gc_init" (* ****** ****** *) fun gc_memlim_get_word (): size_t = "ats_gc_memlim_get_word" fun gc_memlim_get_word_set (wsz: size_t): void = "ats_gc_memlim_set_word" fun gc_memlim_get_page (): size_t = "ats_gc_memlim_get_page" fun gc_memlim_get_page_set (wsz: size_t): void = "ats_gc_memlim_set_page" (* ****** ****** *) fun gc_max_memlim_get_word (): size_t = "ats_gc_max_memlim_get_word" fun gc_max_memlim_get_word_set (wsz: size_t): void = "ats_gc_max_memlim_set_word" fun gc_max_memlim_get_page (): size_t = "ats_gc_max_memlim_get_page" fun gc_max_memlim_get_page_set (wsz: size_t): void = "ats_gc_max_memlim_set_page" (* ****** ****** *) // // HX-2009-10-21: deprecated // fun gc_chunk_count_limit_get (): int = "ats_gc_chunk_count_limit_get" fun gc_chunk_count_limit_set (n: int): void = "ats_gc_chunk_count_limit_set" // (* ****** ****** *) // // HX-2009-10-21: deprecated fun gc_chunk_count_limit_max_get (): int = "ats_gc_chunk_count_limit_max_get" fun gc_chunk_count_limit_max_set (n: int): void = "ats_gc_chunk_count_limit_max_set" // (* ****** ****** *) fun malloc_gc {n:nat} (n: size_t n) :<> [l:agz] (freebyte_gc_v (n, l), b0ytes n @ l | ptr l) = "ats_malloc_gc" // end of [malloc_gc] fun calloc_gc {a:viewt@ype} {n:nat} ( n: size_t n, tsz: sizeof_t a ) :<> [l:agz] (free_gc_v (a?, n, l), @[a?][n] @ l | ptr l) = "ats_calloc_gc" // end of [calloc_gc] fun free_gc {n:nat} {l:addr} (pfgc: freebyte_gc_v (n, l), pfat: b0ytes n @ l | p: ptr l):<> void = "ats_free_gc" // end of [free_gc] fun realloc_gc {n0,n:nat} {l0:addr} ( pfgc: freebyte_gc_v (n0, l0), pfarr: b0ytes n0 @ l0 | _: ptr l0, _: size_t n ) :<> [l:agz] (freebyte_gc_v (n, l), b0ytes n @ l | ptr l) = "ats_realloc_gc" // end of [realloc_gc] (* ****** ****** *) dataview malloc_v (n:int, addr) = | {l:agz} malloc_v_succ (n, l) of (freebyte_ngc_v (n, l), b0ytes n @ l) | malloc_v_fail (n, null) of () // end of [malloc_v] fun malloc_ngc {n:nat} (n: size_t n):<> [l:addr] (malloc_v (n, l) | ptr l) = "ats_malloc_ngc" // end of [malloc_ngc] dataview calloc_v (a:viewt@ype, n:int, addr) = | {l:agz} calloc_v_succ (a, n, l) of (freebyte_ngc_v (n, l), @[a?][n] @ l) | calloc_v_fail (a, n, null) of () fun calloc_ngc {a:viewt@ype} {n:nat} (n: size_t n, tsz: sizeof_t a) :<> [l:addr] (calloc_v (a, n, l) | ptr l) = "ats_calloc_ngc" // end of [calloc_ngc] fun free_ngc {n:nat} {l:addr} ( _: freebyte_ngc_v (n, l), _: b0ytes n @ l | p: ptr l ) :<> void= "ats_free_ngc" // end of [free_ngc] dataview realloc_v ( n0:int, n:int(*new*), addr, addr ) = | {l0,l:agz} realloc_v_succ (n0, n, l0, l) of (freebyte_ngc_v (n, l), b0ytes n @ l) | {l0:agz} realloc_v_fail (n0, n, l0, null) of (freebyte_ngc_v (n0, l0), b0ytes n0 @ l0) fun realloc_ngc {n0,n:nat} {l0:addr} ( pfgc: freebyte_ngc_v (n0, l0), pfarr: b0ytes n0 @ l0 | _: ptr l0, _: size_t n ) :<> [l:addr] (realloc_v (n0, n, l0, l) | ptr l) = "ats_realloc_ngc" // end of [realloc_ngc] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [memory.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [memory.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/list.sats0000664000175000017500000007324612223166161020071 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) %{# #include "prelude/CATS/list.cats" %} // end of [%{#] (* ****** ****** *) (* ** Notes (HX-2009-11-8): ** ** if a function f returns a list, then usually the returned list is ** a linear list; if needed, please call the function [list_of_list_vt] ** to turn the linear list into a nonlnear one; as [list_of_list_vt] is ** a cast function (castfn), there is no run-time cost associated with ** calling it. ** *) (* ****** ****** *) (* // this is defined in [basic_sta.sats] datatype // t@ype+: covariant list_t0ype_int_type (a:t@ype+, int) = | {n:int | n >= 0} list_cons (a, n+1) of (a, list_t0ype_int_type (a, n)) | list_nil (a, 0) // end of [datatype] stadef list = list_t0ype_int_type typedef List (a:t@ype) = [n:int | n >= 0] list (a, n) *) (* ****** ****** *) sortdef t0p = t@ype (* ****** ****** *) typedef listLt (a:t0p, n:int) = [n1:nat | n1 < n] list (a, n1) typedef listLte (a:t0p, n:int) = [n1:nat | n1 <= n] list (a, n1) (* ****** ****** *) prfun list_length_is_nonnegative {a:t@ype} {n:int} (xs: list (a, n)): [n>=0] void // end of [list_length_is_nonnegative] (* ****** ****** *) macdef list_sing (x) = list_cons (,(x), list_nil ()) macdef list_pair (x1, x2) = list_cons (,(x1), list_cons (,(x2), list_nil)) (* ****** ****** *) (* exception ListSubscriptException of () *) fun ListSubscriptException ():<> exn = "ext#ListSubscriptException_make" fun isListSubscriptException (x: !exn):<> bool = "ext#isListSubscriptException" (* ****** ****** *) // // HX: a casting function // implemented in [prelude/DATS/list.dats] // castfn list_of_list_vt {a:t@ype} {n:int} (xs: list_vt (a, n)):<> list (a, n) // end of [list_of_list_vt] (* ****** ****** *) // // HX: always inlining // fun{} list_is_nil {a:t@ype} {n:int} (xs: list (a, n)):<> bool (n==0) fun{} list_is_cons {a:t@ype} {n:int} (xs: list (a, n)):<> bool (n > 0) fun{} list_is_empty {a:t@ype} {n:int} (xs: list (a, n)):<> bool (n==0) fun{} list_isnot_empty {a:t@ype} {n:int} (xs: list (a, n)):<> bool (n > 0) overload ~ with list_isnot_empty fun{a:t@ype} list_is_sing {n:int} (xs: list (a, n)):<> bool (n==1) // end of [list_is_sing] fun{a:t@ype} list_is_pair {n:int} (xs: list (a, n)):<> bool (n==2) // end of [list_is_pair] (* ****** ****** *) fun{a:t@ype} list_app_funenv {v:view} {vt:viewtype} {f:eff} ( pf: !v | xs: List a, f: (!v | a, !vt) - void, env: !vt ) : void // end of [list_app_funenv] fun{a:t@ype} list_app_fun {f:eff} (xs: List a, f: a - void): void fun{a:t@ype} list_app_vclo {v:view} {f:eff} ( pf: !v | xs: List a, f: &(!v | a) - void ) : void // end of [list_app_vclo] fun{a:t@ype} list_app_cloptr {f:eff} ( xs: List a, f: !(a) - void ) : void // end of [list_app_cloptr] fun{a:t@ype} list_app_vcloptr {v:view} {f:eff} ( pf: !v | xs: List a, f: !(!v | a) - void ) : void // end of [list_app_vcloptr] fun{a:t@ype} list_app_cloref {f:eff} (xs: List a, f: (a - void)): void (* symintr list_app overload list_app with list_app_fun overload list_app with list_app_vclo overload list_app with list_app_cloptr overload list_app with list_app_vcloptr overload list_app with list_app_cloref *) (* ****** ****** *) fun{a1,a2:t@ype} list_app2_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: list (a1, n) , ys: list (a2, n) , f: (!v | a1, a2, !vt) - void , env: !vt ) : void // end of [list_app2_funenv] fun{a1,a2:t@ype} list_app2_fun {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - void ) : void // end of [list_app2_fun] fun{a1,a2:t@ype} list_app2_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: &(!v | a1, a2) - void ) : void // end of [list_app2_vclo] fun{a1,a2:t@ype} list_app2_cloptr {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: !(a1, a2) - void ) : void // end of [list_app2_cloptr] fun{a1,a2:t@ype} list_app2_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: !(!v | a1, a2) - void ) : void // end of [list_app2_vcloptr] fun{a1,a2:t@ype} list_app2_cloref {n:int} {f:eff} (xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - void): void // end of [list_app2_cloref] (* symintr list_app2 overload list_app2 with list_app2_fun overload list_app2 with list_app2_vclo overload list_app2 with list_app2_cloptr overload list_app2 with list_app2_vcloptr overload list_app2 with list_app2_cloref *) (* ****** ****** *) fun{a:t@ype} list_append {i,j:int} (xs: list (a, i), ys: list (a, j)):<> list (a, i+j) overload + with list_append fun{a:t@ype} list_append1_vt {i,j:int} (xs: list_vt (a, i), ys: list (a, j)):<> list (a, i+j) // end of [list_append1_vt] fun{a:t@ype} list_append2_vt {i,j:int} (xs: list (a, i), ys: list_vt (a, j)):<> list_vt (a, i+j) // end of [list_append2_vt] (* ****** ****** *) fun{a1,a2:t@ype} list_assoc_funenv {v:view} {vt:viewtype} {eq:eff} ( pf: !v | xs: List @(a1, a2), eq: (!v | a1, a1, !vt) - bool, x: a1, env: !vt ) : Option_vt a2 // end of [list_assoc_funenv] fun{a1,a2:t@ype} list_assoc_fun {eq:eff} ( xs: List @(a1, a2), eq: (a1, a1) - bool, x: a1 ) : Option_vt a2 // end of [list_assoc_fun] fun{a1,a2:t@ype} list_assoc_vclo {v:view} {eq:eff} ( pf: !v | xs: List @(a1, a2), eq: &(!v | a1, a1) - bool, x: a1 ) : Option_vt a2 // end of [list_assoc_vclo] fun{a1,a2:t@ype} list_assoc_cloptr {eq:eff} ( xs: List @(a1, a2), eq: !(a1, a1) - bool, x: a1 ) : Option_vt a2 // end of [list_assoc_cloptr] fun{a1,a2:t@ype} list_assoc_vcloptr {v:view} {eq:eff} ( pf: !v | xs: List @(a1, a2), eq: !(!v | a1, a1) - bool, x: a1 ) : Option_vt a2 // end of [list_assoc_vcloptr] fun{a1,a2:t@ype} list_assoc_cloref {eq:eff} ( xs: List @(a1, a2), eq: (a1, a1) - bool, x: a1 ) : Option_vt a2 // end of [list_assoc_cloref] (* ****** ****** *) fun{a:t@ype} list_concat (xs: List (List a)):<> List_vt a (* ****** ****** *) fun{a:t@ype} list_copy {n:int} (xs: list (a, n)):<> list_vt (a, n) (* ****** ****** *) fun{a:t@ype} list_drop {n:int}{i:nat | i <= n} (xs: list (a, n), i: int i):<> list (a, n-i) // end of [list_drop] fun{a:t@ype} list_drop_exn {n:int}{i:nat} (xs: list (a, n), i: int i): [i <= n] list (a, n-i) // end of [list_drop_exn] (* ****** ****** *) fun{a:t@ype} list_exists_funenv {v:view} {vt:viewtype} {p:eff} ( pf: !v | xs: List a, p: (!v | a, !vt) - bool, env: !vt ) :

bool // end of [list_exists_funenv] fun{a:t@ype} list_exists_fun {p:eff} (xs: List a, p: a -

bool):

bool fun{a:t@ype} list_exists_vclo {v:view} {p:eff} (pf: !v | xs: List a, p: &(!v | a) - bool):

bool fun{a:t@ype} list_exists_cloptr {p:eff} (xs: List a, p: !(a) - bool):

bool fun{a:t@ype} list_exists_vcloptr {v:view} {p:eff} (pf: !v | xs: List a, p: !(!v | a) - bool):

bool fun{a:t@ype} list_exists_cloref {p:eff} (xs: List a, p: a - bool):

bool (* symintr list_exists overload list_exists with list_exists_fun overload list_exists with list_exists_vclo overload list_exists with list_exists_cloptr overload list_exists with list_exists_vcloptr overload list_exists with list_exists_cloref *) (* ****** ****** *) fun{a1,a2:t@ype} list_exists2_funenv {v:view} {vt:viewtype} {n:int} {p:eff} ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , p: (!v | a1, a2, !vt) - bool , env: !vt ) :

bool // end of [list_exists2_funenv] fun{a1,a2:t@ype} list_exists2_fun {n:int} {p:eff} (xs: list (a1, n), ys: list (a2, n), p: (a1, a2) -

bool):

bool fun{a1,a2:t@ype} list_exists2_vclo {v:view} {n:int} {p:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), p: &(!v | a1, a2) - bool ) :

bool // end of [list_exists2_vclo] fun{a1,a2:t@ype} list_exists2_cloptr {n:int} {p:eff} ( xs: list (a1, n), ys: list (a2, n), p: !(a1, a2) - bool ) :

bool // end of [list_exists2_cloptr] fun{a1,a2:t@ype} list_exists2_vcloptr {v:view} {n:int} {p:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), p: !(!v | a1, a2) - bool ) :

bool // end of [list_exists2_vcloptr] fun{a1,a2:t@ype} list_exists2_cloref {n:int} {p:eff} (xs: list (a1, n), ys: list (a2, n), p: (a1, a2) - bool):

bool // end of [list_exists2_cloref] (* symintr list_exists2 overload list_exists2 with list_exists2_fun overload list_exists2 with list_exists2_vclo overload list_exists2 with list_exists2_cloptr overload list_exists2 with list_exists2_vcloptr overload list_exists2 with list_exists2_cloref *) (* ****** ****** *) fun{a:t@ype} // HX: this function is O(n)-time list_extend {n:int} (xs: list (a, n), y: a):<> list_vt (a, n+1) (* ****** ****** *) fun{a:t@ype} list_filter_funenv {v:view}{vt:viewtype}{n:int}{p:eff} ( pf: !v | xs: list (a, n) , p: (!v | a, !vt) - bool, env: !vt ) :

listLte_vt (a, n) // endfun fun{a:t@ype} list_filter_fun{n:int}{p:eff} (xs: list (a, n), p: a - bool):

listLte_vt (a, n) // end of [list_filter_fun] fun{a:t@ype} list_filter_vclo {v:view}{n:int}{p:eff} ( pf: !v | xs: list (a, n), p: &(!v | a) - bool ) :

listLte_vt (a, n) // endfun fun{a:t@ype} list_filter_cloptr {n:int}{p:eff} ( xs: list (a, n), p: !(a) - bool ) :

listLte_vt (a, n) // end of [list_filter_cloptr] fun{a:t@ype} list_filter_vcloptr {v:view}{n:int}{p:eff} ( pf: !v | xs: list (a, n), p: !(!v | a) - bool ) :

listLte_vt (a, n) // endfun fun{a:t@ype} list_filter_cloref {n:int}{p:eff} (xs: list (a, n), p: a - bool):

listLte_vt (a, n) // end of [list_filter_cloref] (* ****** ****** *) fun{a:t@ype} list_find_funenv {v:view} {vt:viewtype} {p:eff} ( pf: !v | xs: List a, p: (!v | a, !vt) - bool, env: !vt ) :

Option_vt a // end of [list_find_funenv] fun{a:t@ype} list_find_fun {p:eff} (xs: List a, p: a - bool):

Option_vt a fun{a:t@ype} list_find_vclo {v:view} {p:eff} (pf: !v | xs: List a, p: &(!v | a) - bool):

Option_vt a // end of [list_find_vclo] fun{a:t@ype} list_find_cloptr {p:eff} (xs: List a, p: !(a) - bool):

Option_vt a fun{a:t@ype} list_find_vcloptr {v:view} {p:eff} (pf: !v | xs: List a, p: !(!v | a) - bool):

Option_vt a fun{a:t@ype} list_find_cloref {p:eff} (xs: List a, p: a - bool):

Option_vt a (* ****** ****** *) fun{init:viewt@ype}{a:t@ype} list_fold_left_funenv {v:view} {vt:viewtype} {f:eff} ( pf: !v | f: (!v | init, a, !vt) - init, ini: init, xs: List a, env: !vt ) : init // end of [list_fold_left_funenv] fun{init:viewt@ype}{a:t@ype} list_fold_left_fun {f:eff} (f: (init, a) - init, ini: init, xs: List a): init // end of [list_fold_left_fun] fun{init:viewt@ype}{a:t@ype} list_fold_left_vclo {v:view} {f:eff} ( pf: !v | f: &(!v | init, a) - init, ini: init, xs: List a ) : init // end of [list_fold_left_vclo] fun{init:viewt@ype}{a:t@ype} list_fold_left_cloptr {f:eff} ( f: !(init, a) - init, ini: init, xs: List a ) : init // end of [list_fold_left_cloptr] fun{init:viewt@ype}{a:t@ype} list_fold_left_vcloptr {v:view} {f:eff} ( pf: !v | f: !(!v | init, a) - init, ini: init, xs: List a ) : init // end of [list_fold_left_vcloptr] fun{init:viewt@ype}{a:t@ype} list_fold_left_cloref {f:eff} (f: (init, a) - init, ini: init, xs: List a): init // end of [list_fold_left_cloref] (* ****** ****** *) fun{init:viewt@ype}{a1,a2:t@ype} list_fold2_left_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | f: (!v | init, a1, a2, !vt) - init , ini: init , xs1: list (a1, n) , xs2: list (a2, n) , env: !vt ) : init // end of [list_fold2_left_funenv] fun{init:viewt@ype}{a1,a2:t@ype} list_fold2_left_cloptr {v:view} {n:int} {f:eff} ( pf: !v | f: !(!v | init, a1, a2) - init , ini: init, xs1: list (a1, n), xs2: list (a2, n) ): init // end of [list_fold2_left_cloptr] fun{init:viewt@ype}{a1,a2:t@ype} list_fold2_left_cloref {n:int} {f:eff} ( f: (init, a1, a2) - init, ini: init, xs1: list (a1, n), xs2: list (a2, n) ) : init // end of [list_fold2_left_cloref] (* ****** ****** *) fun{a:t@ype}{sink:viewt@ype} list_fold_right_funenv {v:view} {vt:viewtype} {f:eff} ( pf: !v | f: (!v | a, sink, !vt) - sink, xs: List a, snk: sink, env: !vt ) : sink // end of [list_fold_right_funenv] fun{a:t@ype}{sink:viewt@ype} list_fold_right_fun {f:eff} (f: (a, sink) - sink, xs: List a, snk: sink): sink // end of [list_fold_right_fun] fun{a:t@ype}{sink:viewt@ype} list_fold_right_vclo {v:view} {f:eff} (pf: !v | f: &(!v | a, sink) - sink, xs: List a, snk: sink): sink // end of [list_fold_right_vclo] fun{a:t@ype}{sink:viewt@ype} list_fold_right_cloptr {f:eff} (f: !(a, sink) - sink, xs: List a, snk: sink): sink // end of [list_fold_right_cloptr] fun{a:t@ype}{sink:viewt@ype} list_fold_right_vcloptr {v:view} {f:eff} (pf: !v | f: !(!v | a, sink) - sink, xs: List a, snk: sink): sink // end of [list_fold_right_vcloptr] fun{a:t@ype}{sink:viewt@ype} list_fold_right_cloref {f:eff} (f: (a, sink) - sink, xs: List a, snk: sink): sink // end of [list_fold_right_cloref] (* ****** ****** *) fun{a1,a2:t@ype}{sink:viewt@ype} list_fold2_right_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | f: (!v | a1, a2, sink, !vt) - sink , xs1: list (a1, n) , xs2: list (a2, n) , snk: sink , env: !vt ) : sink // end of [list_fold2_right_funenv] (* ****** ****** *) fun{a:t@ype} list_forall_funenv {v:view} {vt:viewtype} {p:eff} (pf: !v | xs: List a, p: (!v | a, !vt) - bool, env: !vt):

bool // end of [list_forall_funenv] fun{a:t@ype} list_forall_fun {p:eff} (xs: List a, p: a -

bool):

bool fun{a:t@ype} list_forall_vclo {v:view} {p:eff} (pf: !v | xs: List a, p: &(!v | a) - bool):

bool fun{a:t@ype} list_forall_cloptr {p:eff} (xs: List a, p: !(a) - bool):

bool fun{a:t@ype} list_forall_vcloptr {v:view} {p:eff} (pf: !v | xs: List a, p: !(!v | a) - bool):

bool fun{a:t@ype} list_forall_cloref {p:eff} (xs: List a, p: a - bool):

bool (* symintr list_forall overload list_forall with list_forall_fun overload list_forall with list_forall_vclo overload list_forall with list_forall_cloptr overload list_forall with list_forall_vcloptr overload list_forall with list_forall_cloref *) (* ****** ****** *) fun{a1,a2:t@ype} list_forall2_funenv {v:view} {vt:viewtype} {n:int} {p:eff} ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , p: (!v | a1, a2, !vt) - bool , env: !vt ) :

bool // end of [list_forall2_funenv] fun{a1,a2:t@ype} list_forall2_fun {n:int} {p:eff} (xs: list (a1, n), ys: list (a2, n), p: (a1, a2) -

bool):

bool fun{a1,a2:t@ype} list_forall2_vclo {v:view} {n:int} {p:eff} ( pf: !v| xs: list (a1, n), ys: list (a2, n), p: &(!v | a1, a2) - bool ) :

bool // end of [list_forall2_vclo] fun{a1,a2:t@ype} list_forall2_cloptr {n:int} {p:eff} ( xs: list (a1, n), ys: list (a2, n), p: !(a1, a2) - bool ) :

bool // end of [list_forall2_cloptr] fun{a1,a2:t@ype} list_forall2_vcloptr {v:view} {n:int} {p:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), p: !(!v | a1, a2) - bool ) :

bool // end of [list_forall2_vcloptr] fun{a1,a2:t@ype} list_forall2_cloref {n:int} {p:eff} ( xs: list (a1, n), ys: list (a2, n), p: (a1, a2) - bool ) :

bool // end of [list_forall2_cloref] (* symintr list_forall2 overload list_forall2 with list_forall2_fun overload list_forall2 with list_forall2_vclo overload list_forall2 with list_forall2_cloptr overload list_forall2 with list_forall2_vcloptr overload list_forall2 with list_forall2_cloref *) (* ****** ****** *) fun{a:t@ype} list_foreach_funenv {v:view} {vt:viewtype} {f:eff} ( pf: !v | xs: List a, f: (!v | a, !vt) - void, env: !vt ) : void // end of [list_foreach_funenv] fun{a:t@ype} list_foreach_fun {f:eff} (xs: List a, f: a - void): void fun{a:t@ype} list_foreach_vclo {v:view} {f:eff} (pf: !v | xs: List a, f: &(!v | a) - void): void // end of [list_foreach_vclo] fun{a:t@ype} list_foreach_cloptr {f:eff} (xs: List a, f: !(a) - void): void // end of [list_foreach_cloptr] fun{a:t@ype} list_foreach_vcloptr {v:view} {f:eff} (pf: !v | xs: List a, f: !(!v | a) - void): void // end of [list_foreach_vcloptr] fun{a:t@ype} list_foreach_cloref {f:eff} (xs: List a, f: (a) - void): void (* ****** ****** *) fun{a1,a2:t@ype} list_foreach2_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: list (a1, n) , ys: list (a2, n) , f: (!v | a1, a2, !vt) - void , env: !vt ) : void // end of [list_foreach2_funenv] fun{a1,a2:t@ype} list_foreach2_fun {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - void ) : void // end of [list_foreach2_fun] fun{a1,a2:t@ype} list_foreach2_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: &(!v | a1, a2) - void ) : void // end of [list_foreach2_vclo] fun{a1,a2:t@ype} list_foreach2_cloptr {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: !(a1, a2) - void ) : void // end of [list_foreach2_cloptr] fun{a1,a2:t@ype} list_foreach2_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: !(!v | a1, a2) - void ) : void // end of [list_foreach2_vcloptr] fun{a1,a2:t@ype} list_foreach2_cloref {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - void ) : void // end of [list_foreach2_cloref] (* ****** ****** *) fun{a:t@ype} list_iforeach_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: list (a, n), f: (!v | natLt n, a, !vt) - void, env: !vt ) : void // end of [list_iforeach_funenv] fun{a:t@ype} list_iforeach_fun {n:int} {f:eff} (xs: list (a, n), f: (natLt n, a) - void): void // end of [list_iforeach_fun] fun{a:t@ype} list_iforeach_vclo {v:view} {n:int} {f:eff} (pf: !v | xs: list (a, n), f: &(!v | natLt n, a) - void): void // end of [list_iforeach_vclo] fun{a:t@ype} list_iforeach_cloptr {n:int} {f:eff} (xs: list (a, n), f: !(natLt n, a) - void): void // end of [list_iforeach_cloptr] fun{a:t@ype} list_iforeach_vcloptr {v:view} {n:int} {f:eff} (pf: !v | xs: list (a, n), f: !(!v | natLt n, a) - void): void // end of [list_iforeach_vcloptr] fun{a:t@ype} list_iforeach_cloref {n:int} {f:eff} (xs: list (a, n), f: (natLt n, a) - void): void // end of [list_iforeach_cloref] (* ****** ****** *) fun{a1,a2:t@ype} list_iforeach2_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: list (a1, n) , ys: list (a2, n) , f: (!v | natLt n, a1, a2, !vt) - void , env: !vt ) : void // end of [list_iforeach2_funenv] fun{a1,a2:t@ype} list_iforeach2_fun {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (natLt n, a1, a2) - void ) : void // end of [list_iforeach2_fun] fun{a1,a2:t@ype} list_iforeach2_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: &(!v | natLt n, a1, a2) - void ) : void // end of [list_iforeach2_vclo] fun{a1,a2:t@ype} list_iforeach2_cloptr {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: !(natLt n, a1, a2) - void ) : void // end of [list_iforeach2_cloptr] fun{a1,a2:t@ype} list_iforeach2_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: !(!v | natLt n, a1, a2) - void ) : void // end of [list_iforeach2_vcloptr] fun{a1,a2:t@ype} list_iforeach2_cloref {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (natLt n, a1, a2) - void ) : void // end of [list_iforeach2_cloref] (* ****** ****** *) fun{a:t@ype} list_get_elt_at {n:int} (xs: list (a, n), i: natLt n):<> a overload [] with list_get_elt_at fun{a:t@ype} list_get_elt_at_exn {n:int} (xs: list (a, n), i: Nat): [n>0] a fun{a:t@ype} list_get_elt_at_opt (xs: List a, i: Nat):<> Option_vt a (* ****** ****** *) fun{a:t@ype} list_head {n:pos} (xs: list (a, n)):<> a fun{a:t@ype} list_head_exn {n:int} (xs: list (a, n)): [n>0] a (* ****** ****** *) fun{a:t@ype} list_last {n:pos} (xs: list (a, n)):<> a fun{a:t@ype} list_last_exn {n:int} (xs: list (a, n)): [n>0] a fun{a:t@ype} list_last_opt {n:int} (xs: list (a, n)):<> Option_vt (a) (* ****** ****** *) fun{a:t@ype} list_length {n:int} (xs: list (a, n)):<> int n overload length with list_length (* ****** ****** *) fun{a,b:t@ype} list_length_compare {m,n:int} (xs: list (a, m), ys: list (b, n)):<> [k:int | sgn_r (m-n, k)] int k // end of [list_length_compare] (* ****** ****** *) // // HX: please try [list_vt_make_elt] // fun{a:t@ype} list_make_elt {n:nat} (x: a, n: int n):<> list (a, n) // (* ****** ****** *) fun{a:t@ype}{b:viewt@ype} list_map_funenv {v:view} {vt:viewtype} {n:int} {f:eff} (pf: !v | xs: list (a, n), f: (!v | a, !vt) - b, env: !vt) : list_vt (b, n) // end of [list_map_funenv] fun{a:t@ype}{b:viewt@ype} list_map_fun {n:int} {f:eff} (xs: list (a, n), f: a - b): list_vt (b, n) fun{a:t@ype}{b:viewt@ype} list_map_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a, n), f: &(!v | a) - b ) : list_vt (b, n) // end of [list_map_vclo] fun{a:t@ype}{b:viewt@ype} list_map_cloptr {n:int} {f:eff} (xs: list (a, n), f: !(a) - b): list_vt (b, n) fun{a:t@ype}{b:viewt@ype} list_map_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a, n), f: !(!v | a) - b ) : list_vt (b, n) // end of [list_map_vcloptr] fun{a:t@ype}{b:viewt@ype} list_map_cloref {n:int} {f:eff} (xs: list (a, n), f: (a - b)): list_vt (b, n) // end of [list_map_cloref] (* symintr list_map overload list_map with list_map_fun overload list_map with list_map_vclo overload list_map with list_map_cloptr overload list_map with list_map_vcloptr overload list_map with list_map_cloref *) (* ****** ****** *) fun{a:t@ype}{b:viewt@ype} list_mapopt_funenv {v:view} {vt:viewtype} {n:int} {fe:eff} ( pf: !v | xs: list (a, n) , f: (!v | a, !vt) - Option_vt (b), env: !vt ) : listLte_vt (b, n) // end of [list_mapopt_funenv] fun{a:t@ype}{b:viewt@ype} list_mapopt_fun {n:int} {fe:eff} ( xs: list (a, n), f: a - Option_vt (b) ) : listLte_vt (b, n) fun{a:t@ype}{b:viewt@ype} list_mapopt_vclo {v:view} {n:int} {fe:eff} ( pf: !v | xs: list (a, n), f: &(!v | a) - Option_vt (b) ) : listLte_vt (b, n) // end of [list_mapopt_vclo] fun{a:t@ype}{b:viewt@ype} list_mapopt_cloptr {n:int} {fe:eff} ( xs: list (a, n), f: !(a) - Option_vt (b) ) : listLte_vt (b, n) fun{a:t@ype}{b:viewt@ype} list_mapopt_vcloptr {v:view} {n:int} {fe:eff} ( pf: !v | xs: list (a, n), f: !(!v | a) - Option_vt (b) ) : listLte_vt (b, n) // end of [list_mapopt_vcloptr] fun{a:t@ype}{b:viewt@ype} list_mapopt_cloref {n:int} {fe:eff} ( xs: list (a, n), f: (a - Option_vt (b)) ) : listLte_vt (b, n) // end of [list_mapopt_cloref] (* symintr list_mapopt overload list_mapopt with list_mapopt_fun overload list_mapopt with list_mapopt_vclo overload list_mapopt with list_mapopt_cloptr overload list_mapopt with list_mapopt_vcloptr overload list_mapopt with list_map_cloref *) (* ****** ****** *) fun{a1,a2:t@ype}{b:viewt@ype} list_map2_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: list (a1, n) , ys: list (a2, n) , f: (!v | a1, a2, !vt) - b , env: !vt ) : list_vt (b, n) // end of [list_map2_funenv] fun{a1,a2:t@ype}{b:viewt@ype} list_map2_fun {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - b ) : list_vt (b, n) // end of [list_map2_fun] fun{a1,a2:t@ype}{b:viewt@ype} list_map2_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: &(!v | a1, a2) - b ) : list_vt (b, n) // end of [list_map2_vclo] fun{a1,a2:t@ype}{b:viewt@ype} list_map2_cloptr {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: !(a1, a2) - b ) : list_vt (b, n) // end of [list_map2_cloptr] fun{a1,a2:t@ype}{b:viewt@ype} list_map2_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: !(!v | a1, a2) - b ) : list_vt (b, n) // end of [list_map2_vcloptr] fun{a1,a2:t@ype}{b:viewt@ype} list_map2_cloref {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - b ) : list_vt (b, n) // end of [list_map2_cloref] (* symintr list_map2 overload list_map2 with list_map2_fun overload list_map2 with list_map2_vclo overload list_map2 with list_map2_cloptr overload list_map2 with list_map2_vcloptr overload list_map2 with list_map2_cloref *) (* ****** ****** *) fun{a:t@ype} list_nth {n:int} (xs: list (a, n), i: natLt n):<> a fun{a:t@ype} list_nth_exn {n:int} (xs: list (a, n), i: Nat): [n>0] a fun{a:t@ype} list_nth_opt (xs: List a, i: Nat):<> Option_vt a (* ****** ****** *) fun{a:t@ype} list_reverse_append {i,j:int} (xs: list (a, i), ys: list (a, j)):<> list (a, i+j) // end of [list_reverse_append] (* ****** ****** *) fun{a:t@ype} list_reverse_append1_vt {i,j:int} (xs: list_vt (a, i), ys: list (a, j)):<> list (a, i+j) fun{a:t@ype} list_reverse_append2_vt {i,j:int} (xs: list (a, i), ys: list_vt (a, j)):<> list_vt (a, i+j) (* ****** ****** *) fun{a:t@ype} list_reverse {n:int} (xs: list (a, n)):<> list_vt (a, n) (* ****** ****** *) fun{a:t@ype} list_set_elt_at {n:int} (xs: list (a, n), i: natLt n, x: a):<> list (a, n) fun{a:t@ype} list_set_elt_at_exn {n:int} (xs: list (a, n), i: Nat, x: a): [n>0] list (a, n) fun{a:t@ype} list_set_elt_at_opt {n:int} (x: list (a, n), i: Nat, x: a):<> Option_vt (list (a, n)) (* ****** ****** *) fun{a:t@ype} list_split_at {n:int} {i:nat | i <= n} (xs: list (a, n), i: int i):<> (list_vt (a, i), list (a, n-i)) // end of [list_split_at] (* ****** ****** *) fun{a:t@ype} list_take {n:int}{i:nat | i <= n} (xs: list (a, n), i: int i):<> list_vt (a, i) // end of [list_take] fun{a:t@ype} list_take_exn {n:int}{i:nat} (xs: list (a, n), i: int i): [i <= n] list_vt (a, i) // end of [list_take_exn] (* ****** ****** *) // // list_tabulate: please try [list_vt_tabulate] // (* ****** ****** *) fun{a:t@ype} list_tail {n:pos} (xs: list (a, n)):<> list (a, n-1) fun{a:t@ype} list_tail_exn {n:int} (xs: list (a, n)): [n>0] list (a, n-1) (* ****** ****** *) fun{a,b:t@ype} list_zip {n:int} (xs: list (a, n), ys: list (b, n)):<> list_vt (@(a, b), n) // end of [list_zip] (* ****** ****** *) fun{a,a2:t@ype}{b:viewt@ype} list_zipwth_fun {n:int} {f:eff} (xs: list (a, n), ys: list (a2, n), f: (a, a2) - b): list_vt (b, n) // end of [list_zipwth_fun] fun{a1,a2:t@ype}{b:viewt@ype} list_zipwth_vclo {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: &(!v | a1, a2) - b ) : list_vt (b, n) // end of [list_zipwth_vclo] fun{a1,a2:t@ype}{b:viewt@ype} list_zipwth_cloptr {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: !(a1, a2) - b ) : list_vt (b, n) // end of [list_zipwth_cloptr] fun{a1,a2:t@ype}{b:viewt@ype} list_zipwth_vcloptr {v:view} {n:int} {f:eff} ( pf: !v | xs: list (a1, n), ys: list (a2, n), f: !(!v | a1, a2) - b ) : list_vt (b, n) // end of [list_zipwth_vcloptr] fun{a1,a2:t@ype}{b:viewt@ype} list_zipwth_cloref {n:int} {f:eff} ( xs: list (a1, n), ys: list (a2, n), f: (a1, a2) - b ) : list_vt (b, n) // end of [list_zipwth_cloref] (* ****** ****** *) fun{a1,a2:t@ype} list_unzip {n:int} (xys: list (@(a1, a2), n)):<> (list_vt (a1, n), list_vt (a2, n)) // end of [list_unzip] (* ****** ****** *) (* ** HX: ** [list_mergesort] one sorts in a bottom-up fashion. ** If the list to be sorted is long (say, containing 10K+ elements), ** please try to use [list_vt_mergesort] instead *) fun{a:t@ype} list_mergesort {env:viewtype} {n:int} ( xs: list (a, n), cmp: (a, a, !env) - int, env: !env ) :<> list_vt (a, n) // end of [list_mergesort] (* ** HX: ** this is not a realistic implementation. please try to use ** [list_vt_quicksort] instead *) fun{a:t@ype} list_quicksort {env:viewtype} {n:int} (xs: list (a, n), cmp: (a, a, !env) - int, env: !env):<> list_vt (a, n) // end of [list_quicksort] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [list.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/integer_ptr.sats0000664000175000017500000003162112223166161021427 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer_ptr.sats] starts!\n" #endif (* ****** ****** *) // // intptr: // signed integers of the pointer size // (* ****** ****** *) abstype intptr_int_type (i:int) = intptr_type stadef intptr = intptr_int_type typedef intptr = intptr_type (* ****** ****** *) fun int_of_intptr (i: intptr):<> int = "atspre_int_of_intptr" overload int_of with int_of_intptr fun lint_of_intptr (i: intptr):<> lint = "atspre_lint_of_intptr" overload lint_of with lint_of_intptr (* ****** ****** *) symintr intptr_of fun intptr_of_int (i: int):<> intptr = "atspre_intptr_of_int" overload intptr_of with intptr_of_int fun intptr_of_lint (i: lint):<> intptr = "atspre_intptr_of_lint" overload intptr_of with intptr_of_lint (* ****** ****** *) castfn ptr_of_intptr (i: intptr):<> ptr // "atspre_ptr_of_intptr"(removed) overload ptr_of with ptr_of_intptr castfn intptr_of_ptr (p: ptr):<> intptr // = "atspre_intptr_of_ptr"(removed) overload intptr_of with intptr_of_ptr (* ****** ****** *) fun abs_intptr (i: intptr):<> intptr = "atspre_abs_intptr" overload abs with abs_intptr fun neg_intptr (i: intptr):<> intptr = "atspre_neg_intptr" overload ~ with neg_intptr fun succ_intptr (i: intptr):<> intptr = "atspre_succ_intptr" and pred_intptr (i: intptr):<> intptr = "atspre_pred_intptr" overload succ with succ_intptr overload pred with pred_intptr // fun add_intptr_int (i: intptr, j: int):<> intptr = "atspre_add_intptr_int" overload + with add_intptr_int fun add_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_add_intptr_intptr" overload + with add_intptr_intptr // fun sub_intptr_int (i: intptr, j: int):<> intptr = "atspre_sub_intptr_int" overload - with sub_intptr_int fun sub_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_sub_intptr_intptr" overload - with sub_intptr_intptr // fun mul_intptr_int (i: intptr, j: int):<> intptr = "atspre_mul_intptr_int" overload * with mul_intptr_int fun mul_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_mul_intptr_intptr" overload * with mul_intptr_intptr // fun div_intptr_int (i: intptr, j: int):<> intptr = "atspre_div_intptr_int" overload / with div_intptr_int fun div_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_div_intptr_intptr" overload / with div_intptr_intptr // fun mod_intptr_int (i: intptr, j: int):<> intptr = "atspre_mod_intptr_int" overload mod with mod_intptr_int fun mod_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_mod_intptr_intptr" overload mod with mod_intptr_intptr // fun lt_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_lt_intptr_intptr" overload < with lt_intptr_intptr fun lte_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_lte_intptr_intptr" overload <= with lte_intptr_intptr // fun gt_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_gt_intptr_intptr" overload > with gt_intptr_intptr fun gte_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_gte_intptr_intptr" overload >= with gte_intptr_intptr // fun eq_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_eq_intptr_intptr" overload = with eq_intptr_intptr fun neq_intptr_intptr (i: intptr, j: intptr):<> bool = "atspre_neq_intptr_intptr" overload <> with neq_intptr_intptr // fun max_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_max_intptr_intptr" overload max with max_intptr_intptr fun min_intptr_intptr (i: intptr, j: intptr):<> intptr = "atspre_min_intptr_intptr" overload min with min_intptr_intptr (* ****** ****** *) symintr fprint_intptr fun fprint0_intptr (out: FILEref, x: intptr): void = "atspre_fprint_intptr" fun fprint1_intptr {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: intptr): void = "atspre_fprint_intptr" overload fprint_intptr with fprint0_intptr overload fprint_intptr with fprint1_intptr overload fprint with fprint_intptr (* ****** ****** *) fun print_intptr (i: intptr): void = "atspre_print_intptr" and prerr_intptr (i: intptr): void = "atspre_prerr_intptr" overload print with print_intptr overload prerr with prerr_intptr (* ****** ****** *) fun intptr1_of_int1 {i:nat} (i: int i): intptr i = "atspre_intptr_of_int" fun int1_of_intptr1 {i:nat} (i: intptr i): int i = "atspre_int_of_intptr" (* ****** ****** *) fun lt_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 < i2) = "atspre_lt_intptr_intptr" overload < with lt_intptr1_intptr1 fun lte_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 <= i2) = "atspre_lte_intptr_intptr" overload <= with lte_intptr1_intptr1 fun gt_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 > i2) = "atspre_gt_intptr_intptr" overload > with gt_intptr1_intptr1 fun gte_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 >= i2) = "atspre_gte_intptr_intptr" overload >= with gte_intptr1_intptr1 fun eq_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 == i2) = "atspre_eq_intptr_intptr" overload = with eq_intptr1_intptr1 fun neq_intptr1_intptr1 {i1,i2:nat} (i1: intptr i1, i2: intptr i2):<> bool (i1 <> i2) = "atspre_neq_intptr_intptr" overload <> with neq_intptr1_intptr1 (* ****** ****** *) // // uintptr: // unsigned integers of the pointer size // abstype uintptr_int_type (i:int) = uintptr_type stadef uintptr = uintptr_int_type typedef uintptr = uintptr_type (* ****** ****** *) symintr uintptr_of fun uint_of_uintptr (u: uintptr):<> uint = "atspre_uint_of_uintptr" overload uint_of with uint_of_uintptr fun uintptr_of_int1 {i:nat} (i: int i):<> uintptr = "atspre_uintptr_of_int1" overload uintptr_of with uintptr_of_int1 fun uintptr_of_uint (u: uint):<> uintptr = "atspre_uintptr_of_uint" overload uintptr_of with uintptr_of_uint (* ****** ****** *) fun ulint_of_uintptr (u: uintptr):<> ulint = "atspre_ulint_of_uintptr" fun uintptr_of_ulint (u: ulint):<> uintptr = "atspre_uintptr_of_ulint" overload uintptr_of with uintptr_of_ulint (* ****** ****** *) castfn ptr_of_uintptr (u: uintptr):<> ptr // = "atspre_ptr_of_uintptr"(removed) overload ptr_of with ptr_of_uintptr castfn uintptr_of_ptr (p: ptr):<> uintptr // = "atspre_uintptr_of_ptr"(removed) overload uintptr_of with uintptr_of_ptr (* ****** ****** *) // arithmetic functions and comparison functions fun succ_uintptr (u: uintptr):<> uintptr = "atspre_succ_uintptr" and pred_uintptr (u: uintptr):<> uintptr = "atspre_pred_uintptr" overload succ with succ_uintptr overload pred with pred_uintptr // fun add_uintptr_uint (i: uintptr, j: uint):<> uintptr = "atspre_add_uintptr_uint" overload + with add_uintptr_uint fun add_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_add_uintptr_uintptr" overload + with add_uintptr_uintptr // fun sub_uintptr_uint (i: uintptr, j: uint):<> uintptr = "atspre_sub_uintptr_uint" overload - with sub_uintptr_uint fun sub_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_sub_uintptr_uintptr" overload - with sub_uintptr_uintptr // fun mul_uintptr_uint (i: uintptr, j: uint):<> uintptr = "atspre_mul_uintptr_uint" overload * with mul_uintptr_uint fun mul_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_mul_uintptr_uintptr" overload * with mul_uintptr_uintptr // fun div_uintptr_uint (i: uintptr, j: uint):<> uintptr = "atspre_div_uintptr_uint" overload / with div_uintptr_uint fun div_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_div_uintptr_uintptr" overload / with div_uintptr_uintptr // fun mod_uintptr_uint (i: uintptr, j: uint):<> uintptr = "atspre_mod_uintptr_uint" overload mod with mod_uintptr_uint fun mod_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_mod_uintptr_uintptr" overload mod with mod_uintptr_uintptr // comparision operations on uintptr fun lt_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_lt_uintptr_uintptr" and lte_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_lte_uintptr_uintptr" fun gt_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_gt_uintptr_uintptr" and gte_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_gte_uintptr_uintptr" fun eq_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_eq_uintptr_uintptr" and neq_uintptr_uintptr (i: uintptr, j: uintptr):<> bool = "atspre_neq_uintptr_uintptr" overload < with lt_uintptr_uintptr overload <= with lte_uintptr_uintptr overload > with gt_uintptr_uintptr overload >= with gte_uintptr_uintptr overload = with eq_uintptr_uintptr overload <> with neq_uintptr_uintptr fun max_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_max_uintptr_uintptr" and min_uintptr_uintptr (i: uintptr, j: uintptr):<> uintptr = "atspre_min_uintptr_uintptr" overload max with max_uintptr_uintptr overload min with min_uintptr_uintptr (* ****** ****** *) // bit operations fun lnot_uintptr (u: uintptr):<> uintptr = "atspre_lnot_uintptr" (* bitwise *) overload ~ with lnot_uintptr fun land_uintptr_uintptr (u1: uintptr, u2: uintptr):<> uintptr = "atspre_land_uintptr_uintptr" fun lor_uintptr_uintptr (u1: uintptr, u2: uintptr):<> uintptr = "atspre_lor_uintptr_uintptr" fun lxor_uintptr_uintptr (u1: uintptr, u2: uintptr):<> uintptr = "atspre_lxor_uintptr_uintptr" overload land with land_uintptr_uintptr overload lor with lor_uintptr_uintptr overload lxor with lxor_uintptr_uintptr fun lsl_uintptr_int1 (u: uintptr, n: Nat):<> uintptr = "atspre_lsl_uintptr_int1" and lsr_uintptr_int1 (u: uintptr, n: Nat):<> uintptr = "atspre_lsr_uintptr_int1" overload << with lsl_uintptr_int1 overload >> with lsr_uintptr_int1 (* ****** ****** *) symintr fprint_uintptr fun fprint0_uintptr (out: FILEref, x: uintptr): void = "atspre_fprint_uintptr" fun fprint1_uintptr {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uintptr): void = "atspre_fprint_uintptr" overload fprint_uintptr with fprint0_uintptr overload fprint_uintptr with fprint1_uintptr overload fprint with fprint_uintptr (* ****** ****** *) fun print_uintptr (u: uintptr): void = "atspre_print_uintptr" and prerr_uintptr (u: uintptr): void = "atspre_prerr_uintptr" overload print with print_uintptr overload prerr with prerr_uintptr (* ****** ****** *) fun uintptr1_of_uint1 {i:nat} (u: uint i): uintptr i = "atspre_uintptr_of_uint" fun uint1_of_uintptr1 {i:nat} (u: uintptr i): uint i = "atspre_uint_of_uintptr" (* ****** ****** *) fun lt_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 < i2) = "atspre_lt_uintptr_uintptr" overload < with lt_uintptr1_uintptr1 fun lte_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 <= i2) = "atspre_lte_uintptr_uintptr" overload <= with lte_uintptr1_uintptr1 fun gt_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 > i2) = "atspre_gt_uintptr_uintptr" overload > with gt_uintptr1_uintptr1 fun gte_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 >= i2) = "atspre_gte_uintptr_uintptr" overload >= with gte_uintptr1_uintptr1 fun eq_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 == i2) = "atspre_eq_uintptr_uintptr" overload = with eq_uintptr1_uintptr1 fun neq_uintptr1_uintptr1 {i1,i2:nat} (u1: uintptr i1, u2: uintptr i2):<> bool (i1 <> i2) = "atspre_neq_uintptr_uintptr" overload <> with neq_uintptr1_uintptr1 (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer_ptr.sats] finishes!\n" #endif (* end of [integer_ptr.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/sizetype.sats0000664000175000017500000003761612223166161020773 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [sizetype.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) %{# #include "prelude/CATS/sizetype.cats" ; %} // end of {%{#] (* ****** ****** *) // // HX: size type // unindexed // (* ****** ****** *) fun size_of_int (i: int):<> size_t = "atspre_size_of_int" // end of [size_of_int] (* ****** ****** *) castfn size_of_lint (i: lint):<> size_t castfn lint_of_size (sz: size_t):<> lint castfn size_of_ulint (u: ulint):<> size_t castfn ulint_of_size (sz: size_t):<> ulint (* ****** ****** *) fun int_of_size (sz: size_t):<> int = "atspre_int_of_size" fun uint_of_size (sz: size_t):<> uint = "atspre_uint_of_size" fun size_of_uint (u: uint):<> size_t = "atspre_size_of_uint" fun size_of_int1 {i:nat} (i: int i):<> size_t = "atspre_size_of_int1" (* ****** ****** *) fun add_size_int (sz1: size_t, i2: int):<> size_t = "atspre_add_size_int" overload + with add_size_int fun add_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_add_size_size" overload + with add_size_size // fun sub_size_int (sz1: size_t, i2: int):<> size_t = "atspre_sub_size_int" overload - with sub_size_int fun sub_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_sub_size_size" overload - with sub_size_size // fun mul_size_int (sz1: size_t, i2: int):<> size_t = "atspre_mul_size_int" overload * with mul_size_int fun mul_int_size (i1: int, sz2: size_t):<> size_t = "atspre_mul_int_size" overload * with mul_int_size fun mul_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_mul_size_size" overload * with mul_size_size // fun div_size_int (sz1: size_t, i2: int):<> size_t = "atspre_div_size_int" overload / with div_size_int fun div_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_div_size_size" overload / with div_size_size // fun mod_size_int (sz1: size_t, i2: int):<> int = "atspre_mod_size_int" overload mod with mod_size_int fun mod_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_mod_size_size" overload mod with mod_size_size (* ****** ****** *) fun lt_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_lt_size_size" overload < with lt_size_size fun lte_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_lte_size_size" overload <= with lte_size_size // fun gt_size_int (sz1: size_t, i2: int):<> bool = "atspre_gt_size_int" overload > with gt_size_int fun gt_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_gt_size_size" overload > with gt_size_size // fun gte_size_int (sz1: size_t, i2: int):<> bool = "atspre_gte_size_int" overload >= with gte_size_int fun gte_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_gte_size_size" overload >= with gte_size_size // fun eq_size_int (sz1: size_t, i2: int):<> bool = "atspre_eq_size_int" overload = with eq_size_int fun eq_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_eq_size_size" overload = with eq_size_size // fun neq_size_int (sz1: size_t, i2: int):<> bool = "atspre_neq_size_int" overload <> with neq_size_int overload != with neq_size_int fun neq_size_size (sz1: size_t, sz2: size_t):<> bool = "atspre_neq_size_size" overload <> with neq_size_size overload != with neq_size_size (* ****** ****** *) fun max_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_max_size_size" // end of [max_size_size] fun min_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_min_size_size" // end of [min_size_size] (* ****** ****** *) // bit operations fun land_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_land_size_size" fun lor_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_lor_size_size" fun lxor_size_size (sz1: size_t, sz2: size_t):<> size_t = "atspre_lxor_size_size" overload land with land_size_size overload lor with lor_size_size overload lxor with lxor_size_size fun lsl_size_int1 (sz: size_t, n: Nat):<> size_t = "atspre_lsl_size_int1" and lsr_size_int1 (sz: size_t, n: Nat):<> size_t = "atspre_lsr_size_int1" overload << with lsl_size_int1 overload >> with lsr_size_int1 (* ****** ****** *) symintr fprint_size fun fprint0_size (out: FILEref, x: size_t): void = "atspre_fprint_size" overload fprint_size with fprint0_size fun fprint1_size {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: size_t): void = "atspre_fprint_size" overload fprint_size with fprint1_size overload fprint with fprint_size fun print_size (sz: size_t): void = "atspre_print_size" overload print with print_size fun prerr_size (sz: size_t): void = "atspre_prerr_size" overload prerr with prerr_size (* ****** ****** *) // // HX: indexed size type // (* ****** ****** *) praxi size_param_lemma {i:int} (x: size_t i): [i >= 0] void // end of [size_param_lemma] (* ****** ****** *) castfn size1_of_lint1 {i:nat} (x: lint i): size_t i castfn size1_of_ulint1 {i:nat} (x: ulint i): size_t i castfn size1_of_size (sz: size_t):<> [i:nat] size_t i (* ****** ****** *) fun int1_of_size1 {i:nat} (sz: size_t i):<> int i = "atspre_int1_of_size1" // end of [int1_of_size1] fun uint1_of_size1 {i:nat} (sz: size_t i):<> uint i = "atspre_uint1_of_size1" // end of [uint1_of_size1] // ------ ------ fun size1_of_int1 {i:nat} (i: int i):<> size_t i = "atspre_size1_of_int1" // end of [size1_of_int1] fun size1_of_uint1 {i:int} (u: uint i):<> size_t i = "atspre_size1_of_uint1" // end of [size1_of_uint1] fun size1_of_ptrdiff1 {i:nat} (_: ptrdiff_t i):<> size_t i = "atspre_size1_of_ptrdiff1" // end of [size1_of_ptrdiff1] (* ****** ****** *) fun succ_size1 {i:int} (i: size_t i):<> size_t (i+1) = "atspre_succ_size1" and pred_size1 {i:pos} (i: size_t i):<> size_t (i-1) = "atspre_pred_size1" overload succ with succ_size1 overload pred with pred_size1 // ------ ------ fun add_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> size_t (i+j) = "atspre_add_size1_int1" overload + with add_size1_int1 fun add_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> size_t (i+j) = "atspre_add_size1_size1" overload + with add_size1_size1 // ------ ------ fun sub_size1_int1 {i:int;j:nat | j <= i} (i: size_t i, j: int j):<> size_t (i-j) = "atspre_sub_size1_int1" overload - with sub_size1_int1 fun sub_size1_size1 {i,j:int | j <= i} (i: size_t i, j: size_t j):<> size_t (i-j) = "atspre_sub_size1_size1" overload - with sub_size1_size1 // ------ ------ fun mul_int1_size1 {i:nat;j:int} (i: int i, j: size_t j):<> size_t (i*j) = "atspre_mul_int1_size1" overload * with mul_int1_size1 fun mul_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> size_t (i*j) = "atspre_mul_size1_int1" overload * with mul_size1_int1 fun mul_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> size_t (i*j) = "atspre_mul_size1_size1" overload * with mul_size1_size1 symintr szmul1 szmul2 infixl ( * ) szmul1 szmul2 fun mul1_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> [p:nat] size_t p = "atspre_mul1_size1_size1" overload szmul1 with mul1_size1_size1 fun mul2_size1_size1 {i,j:int} (i: size_t i, j: size_t j) :<> [p:nat] (MUL (i, j, p) | size_t p) = "atspre_mul2_size1_size1" overload szmul2 with mul2_size1_size1 (* ****** ****** *) symintr szdiv2 infixl ( / ) szdiv2 fun div_size1_int1 {i:int;j:pos} (i: size_t i, j: int j):<> size_t (i/j) = "atspre_div_size1_int1" overload / with div_size1_int1 fun div2_size1_int1 {i:int;j:pos} (i: size_t i, j: int j):<> [q:nat] (DIV (i, j, q) | size_t q) = "atspre_div2_size1_int1" overload szdiv2 with div2_size1_int1 fun div_size1_size1 {i:int;j:pos} (i: size_t i, j: size_t j):<> size_t (i/j) = "atspre_div_size1_size1" overload / with div_size1_size1 fun div2_size1_size1 {i:int;j:pos} (i: size_t i, j: size_t j):<> [q:nat] (DIV (i, j, q) | size_t q) = "atspre_div2_size1_size1" overload szdiv2 with div2_size1_size1 (* ****** ****** *) symintr szmod1 szmod2 infixl (mod) szmod1 szmod2 fun mod1_size1_int1 {i:int;j:pos} (i: size_t i, j: int j):<> natLt (j) = "atspre_mod1_size1_int1" overload szmod1 with mod1_size1_int1 fun mod2_size1_int1 {i:int;j:pos} ( i: size_t i, j: int j ) :<> [r:int] (MOD (i, j, r) | int r) = "atspre_mod2_size1_int1" overload szmod2 with mod2_size1_int1 fun mod1_size1_size1 {i:int;j:pos} (i: size_t i, j: size_t j):<> sizeLt (j) = "atspre_mod1_size1_size1" overload szmod1 with mod1_size1_size1 fun mod2_size1_size1 {i:int;j:pos} ( i: size_t i, j: size_t j ) :<> [r:int] (MOD (i, j, r) | size_t r) = "atspre_mod2_size1_size1" overload szmod2 with mod2_size1_size1 (* ****** ****** *) fun divmod_size1_size1 {m:int; n:pos} ( m: size_t m, n: size_t n , r: &size_t? >> size_t r ) :<> #[q,r:nat | r < n] (DIVMOD (m, n, q, r) | size_t q) (* ****** ****** *) fun lt_int1_size1 {i:nat;j:int} (i: int i, j: size_t j):<> bool (i < j) = "atspre_lt_int1_size1" overload < with lt_int1_size1 fun lt_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i < j) = "atspre_lt_size1_int1" overload < with lt_size1_int1 fun lt_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i < j) = "atspre_lt_size1_size1" overload < with lt_size1_size1 // ------ ------ fun lte_int1_size1 {i:nat;j:int} (i: int i, j: size_t j):<> bool (i < j) = "atspre_lte_int1_size1" overload <= with lte_int1_size1 fun lte_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i <= j) = "atspre_lte_size1_int1" overload <= with lte_size1_int1 fun lte_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i <= j) = "atspre_lte_size1_size1" overload <= with lte_size1_size1 // ------ ------ fun gt_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i > j) = "atspre_gt_size1_int1" overload > with gt_size1_int1 fun gt_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i > j) = "atspre_gt_size1_size1" overload > with gt_size1_size1 // ------ ------ fun gte_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i >= j) = "atspre_gte_size1_int1" overload >= with gte_size1_int1 fun gte_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i >= j) = "atspre_gte_size1_size1" overload >= with gte_size1_size1 // ------ ------ fun eq_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i == j) = "atspre_eq_size1_int1" overload = with eq_size1_int1 fun eq_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i == j) = "atspre_eq_size1_size1" overload = with eq_size1_size1 // ------ ------ fun neq_size1_int1 {i:int;j:nat} (i: size_t i, j: int j):<> bool (i <> j) = "atspre_neq_size1_int1" overload <> with neq_size1_int1 overload != with neq_size1_int1 fun neq_size1_size1 {i,j:int} (i: size_t i, j: size_t j):<> bool (i <> j) = "atspre_neq_size1_size1" overload <> with neq_size1_size1 overload != with neq_size1_size1 // ------ ------ fun max_size1_size1 {i,j:int} ( i: size_t i, j: size_t j ) :<> size_t (max (i, j)) = "atspre_max_size1_size1" and min_size1_size1 {i,j:int} ( i: size_t i, j: size_t j ) :<> size_t (min (i, j)) = "atspre_min_size1_size1" overload max with max_size1_size1 overload min with min_size1_size1 (* ****** ****** *) // // HX: signed size type // unindexed // (* ****** ****** *) castfn ssize_of_lint (i: lint):<> ssize_t castfn lint_of_ssize (sz: ssize_t):<> lint castfn ssize_of_size (sz: size_t):<> ssize_t castfn size_of_ssize (sz: ssize_t):<> size_t (* ****** ****** *) fun int_of_ssize (sz: ssize_t):<> int = "atspre_int_of_ssize" fun ssize_of_int (i: int):<> ssize_t = "atspre_ssize_of_int" (* ****** ****** *) fun add_ssize_ssize (i: ssize_t, j: ssize_t): ssize_t = "atspre_add_ssize_ssize" overload + with add_ssize_ssize fun sub_ssize_ssize (i: ssize_t, j: ssize_t): ssize_t = "atspre_sub_ssize_ssize" overload - with sub_ssize_ssize fun mul_ssize_ssize (i: ssize_t, j: ssize_t): ssize_t = "atspre_mul_ssize_ssize" overload * with sub_ssize_ssize fun div_ssize_ssize (i: ssize_t, j: ssize_t): ssize_t = "atspre_div_ssize_ssize" overload / with sub_ssize_ssize (* ****** ****** *) symintr fprint_ssize fun fprint0_ssize (out: FILEref, x: ssize_t): void = "atspre_fprint_ssize" overload fprint_ssize with fprint0_ssize fun fprint1_ssize {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: ssize_t): void = "atspre_fprint_ssize" overload fprint_ssize with fprint1_ssize overload fprint with fprint_ssize fun print_ssize (sz: ssize_t): void = "atspre_print_ssize" overload print with print_ssize fun prerr_ssize (sz: ssize_t): void = "atspre_prerr_ssize" overload prerr with prerr_ssize (* ****** ****** *) // // HX: signed indexed size type // (* ****** ****** *) castfn ssize1_of_ssize (sz: ssize_t): [i:int] ssize_t i castfn ssize1_of_size1 {i:nat} (sz: size_t i):<> ssize_t i castfn size1_of_ssize1 {i:nat} (sz: ssize_t i):<> size_t i (* ****** ****** *) fun int1_of_ssize1 {i:int} (sz: ssize_t i):<> int i = "atspre_int1_of_ssize1" // end of [int1_of_ssize1] fun ssize1_of_int1 {i:int} (i: int i):<> ssize_t i = "atspre_ssize1_of_int1" // end of [ssize1_of_int1] (* ****** ****** *) fun add_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j): ssize_t (i+j) = "atspre_add_ssize1_ssize1" overload + with add_ssize1_ssize1 fun sub_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j): ssize_t (i-j) = "atspre_sub_ssize1_ssize1" overload - with sub_ssize1_ssize1 fun mul_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j): ssize_t (i*j) = "atspre_mul_ssize1_ssize1" overload * with mul_ssize1_ssize1 fun div_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j): ssize_t (i/j) = "atspre_div_ssize1_ssize1" overload / with div_ssize1_ssize1 (* ****** ****** *) fun lt_ssize1_int1 {i,j:int} (i: ssize_t i, j: int j):<> bool (i < j) = "atspre_lt_ssize1_int1" overload < with lt_ssize1_int1 // ------ ------ fun lte_ssize1_int1 {i,j:int} (i: ssize_t i, j: int j):<> bool (i <= j) = "atspre_lt_ssize1_int1" overload <= with lte_ssize1_int1 // ------ ------ fun gt_ssize1_int1 {i,j:int} (i: ssize_t i, j: int j):<> bool (i > j) = "atspre_gt_ssize1_int1" overload > with gt_ssize1_int1 // ------ ------ fun gte_ssize1_int1 {i,j:int} (i: ssize_t i, j: int j):<> bool (i >= j) = "atspre_gte_ssize1_int1" overload >= with gte_ssize1_int1 (* ****** ****** *) fun eq_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j):<> bool (i == j) = "atspre_eq_ssize1_ssize1" overload = with eq_ssize1_ssize1 fun neq_ssize1_ssize1 {i,j:int} (i: ssize_t i, j: ssize_t j):<> bool (i <> j) = "atspre_neq_ssize1_ssize1" overload <> with neq_ssize1_ssize1 overload != with neq_ssize1_ssize1 (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [sizetype.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [sizetype.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/unsafe.sats0000664000175000017500000000722712223166161020373 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // HX: // For safety, [unsafe.sats] should not be loaded automatically. // The unsafe functions declared here must be used with caution!!! // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) // // HX: [castvwtp1] : it is mostly used in a situation // where a linear value is passed as a read-only value; // for instance, casting [strptr] to [string] // castfn cast {to:t@ype} {from:t@ype} (x: from):<> to castfn castvwtp0 {to:viewt@ype}{from:viewt@ype} (x: from):<> to castfn castvwtp_trans {to:viewt@ype}{from:viewt@ype} (x: from):<> to castfn castvwtp1 {to:viewt@ype}{from:viewt@ype} (x: !from):<> to (* ****** ****** *) // castfn cast2ptr {a:type} (x: a):<> ptr castfn cast2Ptr {a:type} (x: a):<> Ptr castfn cast2Ptr1 {a:type} (x: a):<> Ptr1 // castfn cast2int {a:t@ype} (x: a):<> int castfn cast2uint {a:t@ype} (x: a):<> uint castfn cast2lint {a:t@ype} (x: a):<> lint castfn cast2ulint {a:t@ype} (x: a):<> ulint castfn cast2size {a:t@ype} (x: a):<> size_t castfn cast2ssize {a:t@ype} (x: a):<> ssize_t // (* ****** ****** *) castfn linstr2str {l:agz} (str: !strptr l):<> string (* ****** ****** *) castfn linlst2lst {a:t@ype}{n:int} (xs: !list_vt (a, n)):<> list (a, n) // end of [linlst2lst] (* ****** ****** *) // // HX: only if you know what you are doing ... // fun{a:viewt@ype} ptr0_get (p: ptr):<> a fun{a:viewt@ype} ptr0_set (p: ptr, x: a):<> void // fun{a:viewt@ype} ptr1_get (p: Ptr1):<> a fun{a:viewt@ype} ptr1_set (p: Ptr1, x: a):<> void // fun{a:viewt@ype} ptrget (p: Ptr1):<> a // backward compatibility fun{a:viewt@ype} ptrset (p: Ptr1, x: a):<> void // backward compatibility // (* ****** ****** *) // // HX-2011-02-26: virtual takeout // absview viewout (v:view) // invariant! // prfun vtakeout {v:view} (pf: !v): viewout (v) prfun viewout_decode {v:view} (pf: viewout (v)): (v, v - void) // end of [viewout_decode] (* ****** ****** *) // // HX: only if you know what you are doing ... // castfn ptr0_vtake {a:viewt@ype} (p: ptr):<> [l:addr] (a@l, a@l - void | ptr l) castfn ptr1_vtake {a:viewt@ype}{l:addr} (p: ptr l):<> (a@l, a@l - void | ptr l) // (* ****** ****** *) (* end of [unsafe.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/reference.sats0000664000175000017500000001053012223166161021037 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // some common functions on references (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [reference.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // HX: implemented in [prelude/CATS/reference.cats] // fun ref_make_elt_tsz {a:viewt@ype} (x: &a >> a?, tsz: sizeof_t a):<> ref a = "atspre_ref_make_elt_tsz" // end of [ref_make_elt_tsz] // // HX: // [ref] and [ref_make_elt] are the same // implemented in [prelude/DATS/reference.dats] // fun{a:viewt@ype} ref (x: a):<> ref a fun{a:viewt@ype} ref_make_elt (x: a):<> ref a // // HX: // this is really an identity function; it is // implemented in [prelude/CATS/reference.cats] fun ref_make_view_ptr {a:viewt@ype} {l:addr} (pf: a @ l | p: ptr l):<> ref a = "atspre_ref_make_view_ptr" // end of [ref_make_view_ptr] // // HX: implemented in [prelude/CATS/reference.cats] // fun ref_void_make ():<> ref void = "atspre_ref_void_make" (* ****** ****** *) // // HX: Operationally, it is the same as [ref_make_view_ptr] // fun refconst_make_view_ptr {a:t@ype} {l:addr} (pf: a @ l | p: ptr l):<> refconst a = "atspre_ref_make_view_ptr" // end of [refconst_make_view_ptr] (* ****** ****** *) // // HX: implemented in [prelude/DATS/reference.dats] // fun{a:t@ype} ref_get_elt (r: ref a): a = "atspre_ref_get_elt" // // HX: implemented in [prelude/DATS/reference.dats] // fun{a:t@ype} ref_set_elt (r: ref a, x: a): void = "atspre_ref_set_elt" (* ****** ****** *) // // Operationally, it is the same as [ref_get_elt] // fun{a:t@ype} refconst_get_elt (r: refconst a):<> a (* ****** ****** *) // // HX: implemented in [prelude/CATS/reference.cats] // castfn ref_get_ptr {a:viewt@ype} (r: ref a):<> [l:agz] ptr (l) castfn ref_get_view_ptr {a:viewt@ype} (r: ref a):<> [l:agz] (vbox (a @ l) | ptr l) = "atspre_ref_get_view_ptr" // end of [ref_get_view_ptr] (* ****** ****** *) // // HX: implemented in [prelude/DATS/reference.dats] // fun{a:viewt@ype} ref_swap (r: ref a, x: &a): void // // HX: implemented in [prelude/DATS/reference.dats] // fun ref_app_fun {a:viewt@ype} (r: ref a, f: (&a) -<0> void): void // end of [ref_app_fun] (* macdef ++r = let val x = !r + 1 in r := x; x end macdef r++ = let val x = !r in r := x + 1; x end macdef --r = let val x = !r - 1 in r := x; x end macdef r-- = let val x = !r in r := x - 1; x end *) (* ****** ****** *) (* // // HX: should this be added? // // extval (ats_ptr_type, "0") val refopt_none: {a:viewt@ype} refopt (a, false) = "atspre_refopt_none" fun refopt_some {a:viewt@ype} (r: ref a): refopt (a, true) fun refopt_is_some {a:viewt@ype} {b:bool} (r: refopt (a, b)): bool (b) fun refopt_is_none {a:viewt@ype} {b:bool} (r: refopt (a, b)): bool (~b) *) (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [reference.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [reference.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/array.sats0000664000175000017500000004750012223166161020226 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [array.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) sortdef vt0p = viewt@ype (* ****** ****** *) praxi array_v_of_bytes_v {a:vt0p} {n:int} {l:addr} {bsz:int} ( pf1: MUL (n, sizeof a, bsz) , pf2: b0ytes (bsz) @ l ) : @[a?][n] @ l // end of [array_v_of_bytes_v] praxi bytes_v_of_array_v {a:vt0p} {n:int} {l:addr} (pf: @[a?][n] @ l) : [bsz:int] ( MUL (n, sizeof(a), bsz), bytes (bsz) @ l ) // end of [bytes_v_of_array_v] (* ****** ****** *) praxi free_gc_trans {a:t@ype} {n:int} {l:addr} ( pfgc: free_gc_v (a, n, l) ) : [bsz:int] ( MUL (n, sizeof(a), bsz), freebyte_gc_v (bsz, l) ) // end of [free_gc_trans] (* ****** ****** *) fun{a:t@ype} array_ptr_get_elt_at {n:int} {i:nat | i < n} (A: &(@[a][n]), i: size_t i):<> a overload [] with array_ptr_get_elt_at fun{a:t@ype} array_ptr_set_elt_at {n:int} {i:nat | i < n} (A: &(@[a][n]), i: size_t i, x: a):<> void overload [] with array_ptr_set_elt_at fun{a:vt0p} array_ptr_xch_elt_at {n:int} {i:nat | i < n} {l:addr} (A: &(@[a][n]), i: size_t i, x: &a):<> void // end of [array_ptr_xch_elt_at] (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun{a:vt0p} array_ptr_exch {n:int} {i1,i2:nat | i1 < n; i2 < n} (A: &(@[a][n]), i1: size_t i1, i2: size_t i2):<> void // end of [array_ptr_exch] (* ****** ****** *) // // HX: these functions are present mostly for convenience as a // programmer ofter uses values of the type int as array indices: // fun{a:t@ype} array_ptr_get_elt_at__intsz {n:int} {i:nat | i < n} (A: &(@[a][n]), i: int i):<> a overload [] with array_ptr_get_elt_at__intsz fun{a:t@ype} array_ptr_set_elt_at__intsz {n:int} {i:nat | i < n} (A: &(@[a][n]), i: int i, x:a):<> void overload [] with array_ptr_set_elt_at__intsz fun{a:vt0p} array_ptr_xch_elt_at__intsz {n:int} {i:nat | i < n} {l:addr} (A: &(@[a][n]), i: int i, x: &a):<> void // end of [array_ptr_xch_elt_at__intsz] fun{a:vt0p} array_ptr_exch__intsz {n:int} {i1,i2:nat | i1 < n; i2 < n} (A: &(@[a][n]), i1: int i1, i2: int i2):<> void // end of [array_ptr_exch__intsz] (* ****** ****** *) (* // // HX: [array_v] can also be defined as follows: // dataview array_v ( a:viewt@ype+, int, addr ) = | {n:int | n >= 0} {l:addr} array_v_cons (a, n+1, l) of (a @ l, array_v (a, n, l+sizeof a)) | {l:addr} array_v_nil (a, 0, l) // end of [array_v] *) viewdef array_v (a:vt0p, n:int, l: addr) = @[a][n] @ l (* ****** ****** *) praxi lemma_array_v_params {a:vt0p}{n:int}{l:addr} (pf: !array_v (a, n, l)): [n >= 0] void // end of [lemma_array_v_params] (* ****** ****** *) dataview arrayopt_v ( a:viewt@ype+, int, addr, bool ) = | {n:nat} {l:addr} arrayopt_v_some (a, n, l, true) of array_v (a, n, l) | {n:nat} {l:addr} arrayopt_v_none (a, n, l, false) of array_v (a?, n, l) // end of [arrayopt_v] (* ****** ****** *) praxi array_v_nil : {a:vt0p} {l:addr} () - array_v (a, 0, l) praxi array_v_unnil : {a:vt0p} {l:addr} array_v (a, 0, l) - void praxi array_v_cons : {a:vt0p} {n:nat} {l:addr} (a @ l, array_v (a, n, l+sizeof a)) - array_v (a, n+1, l) praxi array_v_uncons : {a:vt0p} {n:int | n > 0} {l:addr} array_v (a, n, l) - (a @ l, array_v (a, n-1, l+sizeof a)) (* ****** ****** *) prfun array_v_sing {a:vt0p} {l:addr} (pf: a @ l): array_v (a, 1, l) prfun array_v_unsing {a:vt0p} {l:addr} (pf: array_v (a, 1, l)): a @ l (* ****** ****** *) fun{a:vt0p} array_ptr_alloc {n:nat} ( asz: size_t n ) :<> [l:agz] (free_gc_v (a?, n, l), array_v (a?, n, l) | ptr l) // end of [array_ptr_alloc] (* ** HX: implemented in C *) fun array_ptr_alloc_tsz {a:vt0p} {n:nat} ( asz: size_t n, tsz: sizeof_t a ) :<> [l:agz] (free_gc_v (a?, n, l), array_v (a?, n, l) | ptr l) = "atspre_array_ptr_alloc_tsz" // end of [fun] (* ****** ****** *) (* ** HX-2009: ** [array_ptr_allocfree] does not really save much. ** However, if one does not want to deal with the view ** [free_gc_v] directly, then please use it. *) fun{a:vt0p} array_ptr_allocfree {n:nat} (asz: size_t n) :<> [l:agz] ( array_v (a?, n, l) | ptr l, (array_v (a?, n, l) | ptr l) - void ) // end of [array_ptr_allocfree] (* ****** ****** *) (* ** HX: implemented in C *) fun array_ptr_free {a:t@ype} {n:int} {l:addr} ( pfgc: free_gc_v (a, n, l), pfarr: array_v (a, n, l) | p: ptr l ) :<> void = "atspre_array_ptr_free" fun{a:vt0p} array_ptr_free_fun {n:int} {l:addr} ( pfgc: free_gc_v (a?, n, l) , pfarr: array_v (a, n, l) | p: ptr l, asz: size_t n , f: (&a >> a?) - void ) :<> void // end of [array_ptr_free_fun] (* ****** ****** *) fun{a:t@ype} array_ptr_initialize_elt {n:int} ( base: &(@[a?][n]) >> @[a][n], asz: size_t n, ini: a ) :<> void // end of [array_ptr_initialize_elt] (* ** HX: implemented in C *) fun array_ptr_initialize_elt_tsz {a:t@ype} {n:int} ( base: &(@[a?][n]) >> @[a][n], asz: size_t n, ini: &a, tsz: sizeof_t a ) :<> void = "atspre_array_ptr_initialize_elt_tsz" // end of [fun] (* ****** ****** *) fun{a:t@ype} array_ptr_initialize_lst {n:int} ( base: &(@[a?][n]) >> @[a][n], xs: list (a, n) ) :<> void // end of [array_ptr_initialize_lst] // the linear list is freed along the way fun{a:vt0p} array_ptr_initialize_lst_vt {n:int} ( base: &(@[a?][n]) >> @[a][n], xs: list_vt (a, n) ) :<> void // end of [array_ptr_initialize_lst_vt] (* ****** ****** *) (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun array_ptr_initialize_funenv_tsz {a:vt0p} {v:view} {vt:viewtype} {n:nat} {f:eff} ( pfv: !v | base: &(@[a?][n]) >> @[a][n] , asz: size_t n , f: (!v | sizeLt n, &(a?) >> a, !vt) - void , tsz: sizeof_t a , env: !vt ) : void = "atspre_array_ptr_initialize_funenv_tsz" // end of [fun] fun{a:vt0p} array_ptr_initialize_fun {n:nat} {f:eff} ( base: &(@[a?][n]) >> @[a][n] , asz: size_t n , f: (sizeLt n, &(a?) >> a) - void ) : void // end of [array_ptr_initialize_fun] (* ****** ****** *) (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun array_ptr_initialize_cloenv_tsz {a:vt0p} {v:view} {vt:viewtype} {n:nat} {f:eff} ( pfv: !v | base: &(@[a?][n]) >> @[a][n] , asz: size_t n , f: &(!v | sizeLt n, &(a?) >> a, !vt) - void , tsz: sizeof_t a , env: !vt ) : void = "atspre_array_ptr_initialize_cloenv_tsz" // end of [fun] fun{a:vt0p} array_ptr_initialize_vclo {v:view} {n:nat} {f:eff}( pfv: !v | base: &(@[a?][n]) >> @[a][n] , asz: size_t n , f: &(!v | sizeLt n, &(a?) >> a) - void ) : void // end of [array_ptr_initialize_vclo] (* ****** ****** *) (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun{a:vt0p} array_ptr_clear_fun {n:int} {f:eff} ( base: &(@[a][n]) >> @[a?][n] , asz: size_t n , f: (&a >> a?) - void ) : void // end of [array_ptr_clear_fun] (* ****** ****** *) prfun array_v_split {a:vt0p} {n:int} {i:nat | i <= n} {l:addr} {ofs:int} ( pfmul: MUL (i, sizeof a, ofs), pfarr: array_v (a, n, l) ) : @( array_v (a, i, l), array_v (a, n-i, l+ofs) ) // end of [array_v_split] prfun array_v_unsplit {a:vt0p} {n1,n2:int} {l:addr} {ofs:int} ( pfmul: MUL (n1, sizeof a, ofs) , pf1arr: array_v (a, n1, l), pf2arr: array_v (a, n2, l+ofs) ) : array_v (a, n1+n2, l) // end of [array_v_unsplit] (* ***** ***** *) prfun array_v_extend : {a:vt0p} {n:nat} {l:addr} {ofs:int} ( MUL (n, sizeof a, ofs), array_v (a, n, l), a @ l+ofs ) - array_v (a, n+1, l) // end of [array_v_extend] prfun array_v_unextend : {a:vt0p} {n:int | n > 0} {l:addr} {ofs:int} ( MUL (n, sizeof a, ofs), array_v (a, n, l) ) - ( array_v (a, n-1, l), a @ l+ofs-sizeof a ) // end of [array_v_unextend] (* ***** ***** *) prfun array_v_takeout : {a:vt0p} {n:int} {i:nat | i < n} {l:addr} {ofs:int} ( MUL (i, sizeof a, ofs), array_v (a, n, l) ) - ( a @ l+ofs, a @ l+ofs - array_v (a, n, l) ) // end of [array_v_takeout] prfun array_v_takeout2 : {a:vt0p} {n:int} {i1,i2:nat | i1 < n; i2 < n; i1 <> i2} {l:addr} {ofs1,ofs2:int} ( MUL (i1, sizeof a, ofs1) , MUL (i2, sizeof a, ofs2) , array_v (a, n, l) ) - ( a @ l+ofs1 , a @ l+ofs2 , (a @ l+ofs1, a @ l+ofs2) - array_v (a, n, l) ) // end of [array_v_takeout2] (* ***** ***** *) // // HX: this is not really needed as [array_v] is covariant // prfun array_v_clear : {a:t@ype} {n:nat} {l:addr} array_v (a, n, l) - array_v (a?, n, l) // end of [array_v_clear] (* ***** ***** *) fun{a:vt0p} array_ptr_split {n:int} {i:nat | i <= n} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0, offset: size_t i ) :<> [ofs:nat] ( MUL (i, sizeof(a), ofs) , array_v (a, i, l0), array_v (a, n-i, l0+ofs) | ptr (l0+ofs) ) // end of [array_ptr_split] (* ** HX: implemented in C (prelude/CATS/array.cats) *) fun array_ptr_split_tsz {a:vt0p} {n:int} {i:nat | i <= n} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0, offset: size_t i, tsz: sizeof_t a ) :<> [ofs:nat] ( MUL (i, sizeof(a), ofs) , array_v (a, i, l0), array_v (a, n-i, l0+ofs) | ptr (l0+ofs) ) = "atspre_array_ptr_split_tsz" // end of [fun] (* ****** ****** *) fun{a:vt0p} array_ptr_takeout {n:int} {i:nat | i < n} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0, offset: size_t i ) :<> [l:addr] ( a @ l , a @ l - array_v (a, n, l0) | ptr l ) // end of [array_ptr_takeout] (* ** HX: implemented in C (prelude/CATS/array.cats) *) fun array_ptr_takeout_tsz {a:vt0p} {n:int} {i:nat | i < n} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0, offset: size_t i, tsz: sizeof_t a ) :<> [l:addr] ( a @ l , a @ l - array_v (a, n, l0) | ptr l ) = "atspre_array_ptr_takeout_tsz" // end of [fun] (* ****** ****** *) fun{a:vt0p} array_ptr_takeout2 {n:int} {i1,i2:nat | i1 < n; i2 < n; i1 <> i2} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0 , off1: size_t i1, off2: size_t i2 ) :<> [l1,l2:addr] ( a @ l1 , a @ l2, (a @ l1, a @ l2) - array_v (a, n, l0) | ptr l1 , ptr l2 ) // end of [array_ptr_takeout2] (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun array_ptr_takeout2_tsz {a:vt0p} {n:int} {i1,i2:nat | i1 < n; i2 < n; i1 <> i2} {l0:addr} ( pf: array_v (a, n, l0) | base: ptr l0 , off1: size_t i1, off2: size_t i2 , tsz: sizeof_t a ) :<> [l1,l2:addr] ( a @ l1 , a @ l2, (a @ l1, a @ l2) - array_v (a, n, l0) | ptr l1 , ptr l2 ) = "atspre_array_ptr_takeout2_tsz" // end of [fun] (* ****** ****** *) (* ** HX: if you want to take out more pointers, please try the ** proof function [vtakeout] declared in prelude/SATS/unsafe.sats *) (* ****** ****** *) (* ** HX: implemented in C (prelude/CATS/array.cats) *) fun array_ptr_copy_tsz {a:t@ype} {n:nat} ( A: &(@[a][n]), B: &(@[a?][n]) >> @[a][n], n: size_t n , tsz: sizeof_t a ) :<> void = "atspre_array_ptr_copy_tsz" // end of [array_ptr_copy_tsz] (* ** HX: implemented in C (prelude/CATS/array.cats) *) fun array_ptr_move_tsz {a:vt0p} {n:nat} ( A: &(@[a][n]) >> @[a?!][n], B: &(@[a?][n]) >> @[a][n], n: size_t n , tsz: sizeof_t a ) :<> void = "atspre_array_ptr_move_tsz" // end of [array_ptr_move_tsz] (* ****** ****** *) // // HX: // these foreach-functions are just as easy to be // implemented on the spot // (* ****** ****** *) // // HX: implemented in ATS (prelude/DATS/array.dats) // fun array_ptr_foreach_funenv_tsz {a:vt0p} {v:view} {vt:viewtype} {n:nat} {f:eff} ( pfv: !v | base: &(@[a][n]) , f: (!v | &a, !vt) - void , asz: size_t n , tsz: sizeof_t a , env: !vt ) : void = "atspre_array_ptr_foreach_funenv_tsz" // end of [fun] fun{a:vt0p} array_ptr_foreach_fun {n:nat} {f:eff} ( base: &(@[a][n]), f: (&a) - void, asz: size_t n ) : void // end of [array_ptr_foreach_fun] fun{a:vt0p} array_ptr_foreach_vclo {v:view} {n:nat} {f:eff} ( pfv: !v | base: &(@[a][n]), f: &(!v | &a) - void, asz: size_t n ) : void // end of [array_ptr_foreach_vclo] (* ****** ****** *) // // HX: // these iforeach-functions are just as easy to be // implemented on the spot // (* ****** ****** *) // // HX: implemented in ATS (prelude/DATS/array.dats) // fun array_ptr_iforeach_funenv_tsz {a:vt0p} {v:view} {vt:viewtype} {n:nat} {f:eff} ( pfv: !v | base: &(@[a][n]) , f: (!v | sizeLt n, &a, !vt) - void , asz: size_t n , tsz: sizeof_t a , env: !vt ) : void = "atspre_array_ptr_iforeach_funenv_tsz" // end of [fun] fun{a:vt0p} array_ptr_iforeach_fun {n:nat} {f:eff} ( base: &(@[a][n]) , f: (sizeLt n, &a) - void , asz: size_t n ) : void // end of [array_ptr_iforeach_fun] fun{a:vt0p} array_ptr_iforeach_clo {n:nat} {f:eff} ( base: &(@[a][n]) , f: &(sizeLt n, &a) - void , asz: size_t n ) : void // end of [array_ptr_iforeach_clo] fun{a:vt0p} array_ptr_iforeach_vclo {v:view} {n:nat} {f:eff} ( pfv: !v | base: &(@[a][n]) , f: &(!v | sizeLt n, &a) - void , asz: size_t n ) : void // end of [array_ptr_iforeach_vclo] (* ****** ****** *) (* // HX: moving an array of (linear) elements to form a list *) fun{a:t@ype} array_ptr_to_list {n:nat} (base: &(@[a][n]) >> @[a?][n], asz: size_t n):<> list_vt (a, n) // end of [array_ptr_to_list] (* ****** ****** *) // // HX: array of arrays: this may just be a curiosity // prfun array_v_group : {a:vt0p} {m,n:nat} {l:addr} {mn:int} (MUL (m, n, mn), array_v (a, mn, l)) - array_v (@[a][n], m, l) // end of [array_v_group] prfun array_v_ungroup : {a:vt0p} {m,n:nat} {l:addr} {mn:int} (MUL (m, n, mn), array_v (@[a][n], m, l)) - array_v (a, mn, l) // end of [array_v_ungroup] (* ****** ****** *) fun{a:vt0p} array2_ptr_takeout {m,n:int} {i:nat | i < m} {l0:addr} ( pf: array_v (@[a][n], m, l0) | pbase: ptr l0, i: size_t i, n: size_t n ) : [l:addr] ( array_v (a, n, l) , array_v (a, n, l) -<> array_v (@[a][n], m, l0) | ptr l // l = l0 + i*(n*sizeof) ) // end of [array2_ptr_takeout] (* ** HX: implemented in C (prelude/CATS/array.cats) *) fun array2_ptr_takeout_tsz {a:vt0p} {m,n:int} {i:nat | i < m} {l0:addr} ( pf: array_v (@[a][n], m, l0) | pbase: ptr l0, i: size_t i, n: size_t n, tsz: sizeof_t a ) : [l:addr] ( array_v (a, n, l) , array_v (a, n, l) -<> array_v (@[a][n], m, l0) | ptr l // l = l0 + i*(n*sizeof) ) = "atspre_array2_ptr_takeout_tsz" // end of [array2_ptr_takeout_tsz] (* ****** ****** *) (* ** ** persistent arrays ** *) (* ****** ****** *) (* exception ArraySubscriptException of () *) fun ArraySubscriptException ():<> exn = "ext#ArraySubscriptException_make" fun isArraySubscriptException (x: !exn):<> bool = "ext#isArraySubscriptException" (* ****** ****** *) castfn array_make_view_ptr {a:vt0p}{n:nat}{l:addr} (pf: array_v (a, n, l) | p: ptr l):<> array (a, n) // end of [array_make_view_ptr] castfn array_get_view_ptr {a:vt0p}{n:nat} (A: array (a, n)):<> [l:addr] (vbox (array_v (a, n, l)) | ptr l) // end of [array_get_view_ptr] (* ****** ****** *) fun array_make_arrpsz {a:vt0p} {n:nat} (psz: arrpsz (a, n)):<> array (a, n) // end of [array_make_arrpsz] macdef array (x) = array_make_arrpsz ,(x) (* ****** ****** *) fun{a:t@ype} array_make_elt {n:nat} (asz: size_t n, elt: a):<> array (a, n) // end of [array_make_elt] fun{a:t@ype} array_make_lst {n:nat} (asz: size_t n, xs: list (a, n)):<> array (a, n) // end of [array_make_lst] fun{a:vt0p} array_make_lst_vt {n:nat} (asz: size_t n, xs: list_vt (a, n)):<> array (a, n) // end of [array_make_lst_vt] (* ****** ****** *) fun{a:vt0p} array_make_vclo {v:view} {n:nat} {f:eff} ( pfv: !v | asz: size_t n , f: &(!v | sizeLt n, &(a?) >> a) - void ) : array (a, n) // end of [array_make_vclo] (* ****** ****** *) fun{a:vt0p} array_make_cloref {n:nat} {f:eff} ( asz: size_t n , f: (sizeLt n, &(a?) >> a) - void ) : array (a, n) // end of [array_make_cloref] (* ****** ****** *) fun{a:t@ype} array_get_elt_at {n:int} {i:nat | i < n} (A: array (a, n), i: size_t i): a overload [] with array_get_elt_at fun{a:t@ype} array_set_elt_at {n:int} {i:nat | i < n} (A: array (a, n), i: size_t i, x: a): void overload [] with array_set_elt_at fun{a:vt0p} array_xch_elt_at {n:int} {i:nat | i < n} (A: array (a, n), i: size_t i, x: &a): void // end of [array_xch_elt_at] (* ****** ****** *) fun{a:t@ype} array_get_elt_at__intsz {n:int} {i:nat | i < n} (A: array (a, n), i: int i): a overload [] with array_get_elt_at__intsz fun{a:t@ype} array_set_elt_at__intsz {n:nat} {i:nat | i < n} (A: array (a, n), i: int i, x: a): void overload [] with array_set_elt_at__intsz fun{a:vt0p} array_xch_elt_at__intsz {n:nat} {i:nat | i < n} (A: array (a, n), i: int i, x: &a): void // end of [array_xch_elt_at__intsz] (* ****** ****** *) fun{a:vt0p} array_exch {n:nat} (A: array (a, n), i: sizeLt n, j: sizeLt n): void // end of [array_exch] fun{a:vt0p} array_exch__intsz {n:nat} (A: array (a, n), i: natLt n, j: natLt n): void // end of [array_exch__intsz] (* ****** ****** *) // // HX: these functions are just as easy to be implemented on the spot // (* ** implemented in ATS (prelude/DATS/array.dats) *) fun{a:vt0p} array_foreach_funenv {v:view} {vt:viewtype} {n:nat} ( pfv: !v | A: array (a, n) , f: (!v | &a, !vt) -<> void , asz: size_t n , env: !vt ) : void // end of [array_foreach_funenv] fun{a:vt0p} array_foreach_fun {n:nat} ( A: array (a, n), f: (&a) - void, asz: size_t n ) : void // end of [array_foreach_fun] fun{a:vt0p} array_foreach_vclo {v:view} {n:nat} ( pfv: !v | A: array (a, n), f: &(!v | &a) - void, asz: size_t n ) : void // end of [array_foreach_vclo] fun{a:vt0p} array_foreach_cloref {n:nat} ( A: array (a, n), f: (&a) - void, asz: size_t n ) : void // end of [array_foreach_cloref] (* ****** ****** *) // // HX: these functions are just as easy to be implemented on the spot // (* ** HX: implemented in ATS (prelude/DATS/array.dats) *) fun{a:vt0p} array_iforeach_funenv {v:view} {vt:viewtype} {n:nat} ( pfv: !v | A: array (a, n) , f: (!v | sizeLt n, &a, !vt) -<> void , asz: size_t n , env: !vt ) : void // end of [array_iforeach_funenv] fun{a:vt0p} array_iforeach_fun {n:nat} ( A: array (a, n), f: (sizeLt n, &a) - void, asz: size_t n ) : void // end of [array_iforeach_fun] fun{a:vt0p} array_iforeach_vclo {v:view} {n:nat} ( pfv: !v | A: array (a, n), f: &(!v | sizeLt n, &a) - void, asz: size_t n ) : void // end of [array_iforeach_vclo] fun{a:vt0p} array_iforeach_cloref {n:nat} ( A: array (a, n), f: (sizeLt n, &a) - void, asz: size_t n ) : void // end of [array_iforeach_cloref] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [array.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [array.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/char.sats0000664000175000017500000002106512223166161020023 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [char.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) #define CHAR_MAX 127 // 2^7 - 1 #define CHAR_MIN ~128 // -2^7 #define UCHAR_MAX 255 // 2^8 - 1 (* ****** ****** *) // some common functions on characters (* ****** ****** *) castfn char_of_schar (c: schar):<> char castfn schar_of_char (c: char):<> schar castfn char_of_uchar (c: uchar):<> char castfn uchar_of_char (c: char):<> uchar (* ****** ****** *) fun char_of_int (i: int):<> char = "atspre_char_of_int" // end of [char_of_int] fun char_of_int1 {i: nat | i <= UCHAR_MAX} (i: int i):<> char = "atspre_char_of_int" // end of [char_of_int1] fun char_of_uint (u: uint):<> char = "atspre_char_of_uint" // end of [char_of_uint] fun char_of_uint1 {i: nat | i <= UCHAR_MAX} (u: uint i):<> char = "atspre_char_of_uint" // end of [char_of_uint1] (* ****** ****** *) fun schar_of_int (i: int):<> schar = "atspre_schar_of_int" // end of [schar_of_int] fun schar_of_int1 {i: nat | i <= UCHAR_MAX} (i: int i):<> schar = "atspre_schar_of_int" // end of [schar_of_int1] fun schar_of_uint (u: uint):<> schar = "atspre_schar_of_uint" // end of [schar_of_uint] fun schar_of_uint1 {i: nat | i <= UCHAR_MAX} (u: uint i):<> schar = "atspre_schar_of_uint" // end of [schar_of_uint1] (* ****** ****** *) fun uchar_of_int (i: int):<> uchar = "atspre_uchar_of_int" // end of [uchar_of_int] fun uchar_of_int1 {i: nat | i <= UCHAR_MAX} (i: int i):<> uchar = "atspre_uchar_of_int" // end of [uchar_of_int1] fun uchar_of_uint (u: uint):<> uchar = "atspre_uchar_of_uint" // end of [uchar_of_uint] fun uchar_of_uint1 {i: nat | i <= UCHAR_MAX} (u: uint i):<> uchar = "atspre_uchar_of_uint" // end of [uchar_of_uint1] (* ****** ****** *) // HX: also declared in [integer.sats] fun int_of_char (c: char):<> int = "atspre_int_of_char" // end of [int_of_char] // HX: also declared in [integer.sats] fun int1_of_char (c: char) :<> [i:int | CHAR_MIN <= i; i <= CHAR_MAX] int i = "atspre_int_of_char" // end of [int1_of_char] // HX: also declared in [integer.sats] fun int_of_uchar (c: uchar):<> int = "atspre_int_of_uchar" // HX: also declared in [integer.sats] fun int1_of_uchar (c: uchar) :<> [i:nat | i <= UCHAR_MAX] int i = "atspre_int_of_uchar" // end of [int1_of_uchar] (* ****** ****** *) // implemented in [integer.cats] fun uint_of_char (c: char):<> uint = "atspre_uint_of_char" // implemented in [integer.cats] fun uint1_of_char (c: char) :<> [i:nat | i <= UCHAR_MAX] uint i = "atspre_uint_of_char" // end of [uint1_of_char] // implemented in [integer.cats] fun uint_of_uchar (c: uchar):<> uint = "atspre_uint_of_uchar" // implemented in [integer.cats] fun uint1_of_uchar (c: uchar) :<> [i:nat | i <= UCHAR_MAX] uint i = "atspre_uint_of_uchar" // end of [uint1_of_uchar] (* ****** ****** *) fun sub_char_char (c1: char, c2: char):<> int = "atspre_sub_char_char" overload - with sub_char_char (* ****** ****** *) fun lt_char_char (c1: char, c2: char):<> bool = "atspre_lt_char_char" and lte_char_char (c1: char, c2: char):<> bool = "atspre_lte_char_char" overload < with lt_char_char overload <= with lte_char_char fun gt_char_char (c1: char, c2: char):<> bool = "atspre_gt_char_char" and gte_char_char (c1: char, c2: char):<> bool = "atspre_gte_char_char" overload > with gt_char_char overload >= with gte_char_char fun eq_char_char (c1: char, c2: char):<> bool = "atspre_eq_char_char" and neq_char_char (c1: char, c2: char):<> bool = "atspre_neq_char_char" overload = with eq_char_char overload <> with neq_char_char overload != with neq_char_char fun compare_char_char (c1: char, c2: char):<> Sgn = "atspre_compare_char_char" overload compare with compare_char_char (* ****** ****** *) // // HX: print functions for characters // symintr fprint_char fun fprint0_char (out: FILEref, x: char): void = "atspre_fprint_char" fun fprint1_char {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: char): void = "atspre_fprint_char" overload fprint_char with fprint0_char overload fprint_char with fprint1_char overload fprint with fprint_char (* ****** ****** *) fun print_char (c: char): void = "atspre_print_char" and prerr_char (c: char): void = "atspre_prerr_char" overload print with print_char overload prerr with prerr_char // // stringization // fun tostrptr_char (c: char):<> strptr1 = "atspre_tostrptr_char" overload tostrptr with tostrptr_char fun tostring_char (c: char):<> string (1) = "atspre_tostrptr_char" overload tostring with tostring_char (* ****** ****** *) fun char_isalpha (c: char):<> bool // whether the char is in the alphabet = "atspre_char_isalpha" and char_isalnum (c: char):<> bool // whether the char is in the alphanumeric = "atspre_char_isalnum" and char_isascii (c: char):<> bool = "atspre_char_isascii" and char_iscntrl (c: char):<> bool = "atspre_char_iscntrl" and char_isdigit (c: char):<> bool // whether the char is a digit = "atspre_char_isdigit" and char_isgraph (c: char):<> bool = "atspre_char_isgraph" and char_islower (c: char):<> bool = "atspre_char_islower" and char_isnull (c: char):<> bool = "atspre_char_isnull" and char_isprint (c: char):<> bool = "atspre_char_isprint" and char_ispunct (c: char):<> bool = "atspre_char_ispunct" and char_isspace (c: char):<> bool = "atspre_char_isspace" and char_isupper (c: char):<> bool = "atspre_char_isupper" and char_isxdigit (c: char):<> bool // whether the char is a hex digit = "atspre_char_isxdigit" (* ****** ****** *) fun char_tolower (c: char):<> char = "atspre_char_tolower" and char_toupper (c: char):<> char = "atspre_char_toupper" (* ****** ****** *) // // HX: indexed char type // (* ****** ****** *) castfn char1_of_char (c: char):<> [c:char] char c (* ****** ****** *) fun char1_of_int (i: int):<> [c:char] char c = "atspre_char1_of_int" // end of [char1_of_int] fun char1_of_uint (u: uint):<> [c:char] char c = "atspre_char1_of_uint" // end of [char1_of_uint] (* ****** ****** *) fun sub_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> int (c1-c2) = "atspre_sub_char_char" overload - with sub_char1_char1 (* ****** ****** *) fun lt_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 < c2) = "atspre_lt_char_char" and lte_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 <= c2) = "atspre_lte_char_char" overload < with lt_char1_char1 overload <= with lte_char1_char1 fun gt_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 > c2) = "atspre_gt_char_char" and gte_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 >= c2) = "atspre_gte_char_char" overload > with gt_char1_char1 overload >= with gte_char1_char1 fun eq_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 == c2) = "atspre_eq_char_char" and neq_char1_char1 {c1,c2:char} (c1: char c1, c2: char c2):<> bool (c1 <> c2) = "atspre_neq_char_char" overload = with eq_char1_char1 overload <> with neq_char1_char1 (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [char.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* end of [char.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/float.sats0000664000175000017500000004267412223166161020224 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [float.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // some common functions on floating point numbers // (* ****** ****** *) typedef lint = int_long_t0ype typedef ulint = uint_long_t0ype typedef llint = int_long_long_t0ype typedef ullint = uint_long_long_t0ype (* ****** ****** *) abst@ype float_t0ype = $extype"ats_float_type" stadef float = float_t0ype abst@ype double_long_t0ype = $extype"ats_ldouble_type" stadef ldouble = double_long_t0ype (* ****** ****** *) // // floating point numbers of single precision // (* ****** ****** *) fun int_of_float (f: float):<> int = "atspre_int_of_float" overload int_of with int_of_float fun lint_of_float (f: float):<> lint = "atspre_lint_of_float" overload lint_of with lint_of_float fun llint_of_float (f: float):<> llint = "atspre_llint_of_float" overload llint_of with llint_of_float (* ****** ****** *) fun float_of_int (i: int):<> float = "atspre_float_of_int" overload float_of with float_of_int fun float_of_uint (u: uint):<> float = "atspre_float_of_uint" overload float_of with float_of_uint // fun float_of_lint (i: lint):<> float = "atspre_float_of_lint" overload float_of with float_of_lint fun float_of_ulint (u: ulint):<> float = "atspre_float_of_ulint" overload float_of with float_of_ulint // fun float_of_llint (i: llint):<> float = "atspre_float_of_llint" overload float_of with float_of_llint fun float_of_ullint (u: ullint):<> float = "atspre_float_of_ullint" overload float_of with float_of_ullint // fun float_of_size (sz: size_t):<> float = "atspre_float_of_size" overload float_of with float_of_size (* ****** ****** *) fun float_of_double (d: double):<> float = "atspre_float_of_double" overload float_of with float_of_double fun float_of_string (s: string):<> float = "atspre_float_of_string" overload float_of with float_of_string (* ****** ****** *) fun abs_float (f: float):<> float = "atspre_abs_float" overload abs with abs_float fun neg_float (f: float):<> float = "atspre_neg_float" overload ~ with neg_float (* ****** ****** *) fun succ_float (f: float):<> float = "atspre_succ_float" and pred_float (f: float):<> float = "atspre_pred_float" overload succ with succ_float overload pred with pred_float (* ****** ****** *) fun add_float_float (f1: float, f2: float):<> float = "atspre_add_float_float" overload + with add_float_float fun sub_float_float (f1: float, f2: float):<> float = "atspre_sub_float_float" overload - with sub_float_float (* ****** ****** *) fun mul_float_float (f1: float, f2: float):<> float = "atspre_mul_float_float" and mul_int_float (i1: int, f2: float):<> float = "atspre_mul_int_float" and mul_float_int (f1: float, i2: int):<> float = "atspre_mul_float_int" overload * with mul_float_float overload * with mul_int_float overload * with mul_float_int fun div_float_float (f1: float, f2: float):<> float = "atspre_div_float_float" and div_float_int (f1: float, i2: int):<> float = "atspre_div_float_int" and div_int_float (i1: int, f2: float):<> float = "atspre_div_int_float" overload / with div_float_float overload / with div_float_int overload / with div_int_float (* ****** ****** *) fun lt_float_float (f1: float, f2: float):<> bool = "atspre_lt_float_float" and lte_float_float (f1: float, f2: float):<> bool = "atspre_lte_float_float" overload < with lt_float_float overload <= with lte_float_float fun gt_float_float (f1: float, f2: float):<> bool = "atspre_gt_float_float" and gte_float_float (f1: float, f2: float):<> bool = "atspre_gte_float_float" overload > with gt_float_float overload >= with gte_float_float fun eq_float_float (f1: float, f2: float):<> bool = "atspre_eq_float_float" and neq_float_float (f1: float, f2: float):<> bool = "atspre_neq_float_float" overload = with eq_float_float overload <> with neq_float_float overload != with neq_float_float fun compare_float_float (f1: float, f2: float):<> Sgn = "atspre_compare_float_float" overload compare with compare_float_float fun max_float_float (f1: float, f2: float):<> float = "atspre_max_float_float" and min_float_float (f1: float, f2: float):<> float = "atspre_min_float_float" overload max with max_float_float overload min with min_float_float (* ****** ****** *) fun square_float (f: float):<> float = "atspre_square_float" overload square with square_float fun cube_float (f: float):<> float = "atspre_cube_float" overload cube with cube_float fun pow_float_int1 (f: float, n: Nat):<> float overload pow with pow_float_int1 (* ****** ****** *) // // print functions for floats of single precision // (* ****** ****** *) symintr fprint_float fun fprint0_float (out: FILEref, x: float): void = "atspre_fprint_float" overload fprint_float with fprint0_float fun fprint1_float {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: float): void = "atspre_fprint_float" overload fprint_float with fprint1_float overload fprint with fprint_float fun print_float (f: float): void = "atspre_print_float" and prerr_float (f: float): void = "atspre_prerr_float" overload print with print_float overload prerr with prerr_float (* ****** ****** *) // // stringization // fun tostrptr_float (f: float):<> strptr1 = "atspre_tostrptr_float" overload tostrptr with tostrptr_float fun tostring_float (f: float):<> string = "atspre_tostrptr_float" overload tostring with tostring_float (* ****** ****** *) // // floating point numbers of double precision // (* ****** ****** *) fun int_of_double (d: double):<> int = "atspre_int_of_double" overload int_of with int_of_double fun lint_of_double (d: double):<> lint = "atspre_lint_of_double" overload lint_of with lint_of_double fun llint_of_double (d: double):<> llint = "atspre_llint_of_double" overload llint_of with llint_of_double (* ****** ****** *) fun double_of_int (i: int):<> double = "atspre_double_of_int" overload double_of with double_of_int fun double_of_uint (u: uint):<> double = "atspre_double_of_uint" overload double_of with double_of_uint fun double_of_lint (i: lint):<> double = "atspre_double_of_lint" overload double_of with double_of_lint fun double_of_ulint (u: ulint):<> double = "atspre_double_of_ulint" overload double_of with double_of_ulint fun double_of_llint (i: llint):<> double = "atspre_double_of_llint" overload double_of with double_of_llint fun double_of_ullint (u: ullint):<> double = "atspre_double_of_ullint" overload double_of with double_of_ullint fun double_of_size (sz: size_t):<> double = "atspre_double_of_size" overload double_of with double_of_size (* ****** ****** *) fun double_of_float (f: float):<> double = "atspre_double_of_float" overload double_of with double_of_float // // HX: this function is based on [atof] in [stdlib.h] // fun double_of_string (s: string):<> double = "atspre_double_of_string" overload double_of with double_of_string (* ****** ****** *) fun abs_double (d: double):<> double = "atspre_abs_double" overload abs with abs_double fun neg_double (d: double):<> double = "atspre_neg_double" overload ~ with neg_double fun succ_double (d: double):<> double = "atspre_succ_double" and pred_double (d: double):<> double = "atspre_pred_double" overload succ with succ_double overload pred with pred_double (* ****** ****** *) fun add_double_double (d1: double, d2: double):<> double = "atspre_add_double_double" and add_double_int (d1: double, i2: int):<> double = "atspre_add_double_int" and add_int_double (i1: int, d2: double):<> double = "atspre_add_int_double" overload + with add_double_double overload + with add_double_int overload + with add_int_double fun sub_double_double (d1: double, d2: double):<> double = "atspre_sub_double_double" and sub_double_int (d1: double, i2: int):<> double = "atspre_sub_double_int" and sub_int_double (i1: int, d2: double):<> double = "atspre_sub_int_double" overload - with sub_double_double overload - with sub_double_int overload - with sub_int_double (* ****** ****** *) fun mul_double_double (d1: double, d2: double):<> double = "atspre_mul_double_double" and mul_double_int (d1: double, i2: int):<> double = "atspre_mul_double_int" and mul_int_double (i1: int, d2: double):<> double = "atspre_mul_int_double" overload * with mul_double_double overload * with mul_double_int overload * with mul_int_double fun div_double_double (d1: double, d2: double):<> double = "atspre_div_double_double" and div_double_int (d1: double, i2: int):<> double = "atspre_div_double_int" and div_int_double (i1: int, d2: double):<> double = "atspre_div_int_double" overload / with div_double_double overload / with div_double_int overload / with div_int_double (* ****** ****** *) fun lt_double_double (d1: double, d2: double):<> bool = "atspre_lt_double_double" and lte_double_double (d1: double, d2: double):<> bool = "atspre_lte_double_double" overload < with lt_double_double overload <= with lte_double_double fun gt_double_double (d1: double, d2: double):<> bool = "atspre_gt_double_double" and gte_double_double (d1: double, d2: double):<> bool = "atspre_gte_double_double" overload > with gt_double_double overload >= with gte_double_double fun eq_double_double (d1: double, d2: double):<> bool = "atspre_eq_double_double" and neq_double_double (d1: double, d2: double):<> bool = "atspre_neq_double_double" overload = with eq_double_double overload <> with neq_double_double overload != with neq_double_double fun compare_double_double (d1: double, d2: double):<> Sgn = "atspre_compare_double_double" overload compare with compare_double_double (* ****** ****** *) fun max_double_double (d1: double, d2: double):<> double = "atspre_max_double_double" and min_double_double (d1: double, d2: double):<> double = "atspre_min_double_double" overload max with max_double_double overload min with min_double_double (* ****** ****** *) fun square_double (d: double):<> double = "atspre_square_double" overload square with square_double fun cube_double (d: double):<> double = "atspre_cube_double" overload cube with cube_double fun pow_double_int1 (d: double, n: Nat):<> double overload pow with pow_double_int1 (* ****** ****** *) // // print functions for floats of double precision // (* ****** ****** *) symintr fprint_double fun fprint0_double (out: FILEref, x: double): void = "atspre_fprint_double" overload fprint_double with fprint0_double fun fprint1_double {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: double): void = "atspre_fprint_double" overload fprint_double with fprint1_double overload fprint with fprint_double fun print_double (f: double): void = "atspre_print_double" and prerr_double (f: double): void = "atspre_prerr_double" overload print with print_double overload prerr with prerr_double (* ****** ****** *) // // stringization // fun tostrptr_double (d: double):<> strptr1 = "atspre_tostrptr_double" overload tostrptr with tostrptr_double fun tostring_double (d: double):<> string = "atspre_tostrptr_double" overload tostring with tostring_double (* ****** ****** *) // // floating point numbers of long double precision // (* ****** ****** *) fun int_of_ldouble (ld: ldouble):<> int = "atspre_int_of_ldouble" overload int_of with int_of_ldouble fun lint_of_ldouble (ld: ldouble):<> lint = "atspre_lint_of_ldouble" overload lint_of with lint_of_ldouble fun llint_of_ldouble (ld: ldouble):<> llint = "atspre_llint_of_ldouble" overload llint_of with llint_of_ldouble (* ****** ****** *) fun ldouble_of_int (i: int):<> ldouble = "atspre_ldouble_of_int" overload ldouble_of with ldouble_of_int fun ldouble_of_lint (li: lint):<> ldouble = "atspre_ldouble_of_lint" overload ldouble_of with ldouble_of_lint fun ldouble_of_llint (lli: llint):<> ldouble = "atspre_ldouble_of_llint" overload ldouble_of with ldouble_of_llint (* ****** ****** *) fun ldouble_of_float (f: float):<> ldouble = "atspre_ldouble_of_float" overload ldouble_of with ldouble_of_float fun ldouble_of_double (d: double):<> ldouble = "atspre_ldouble_of_double" overload ldouble_of with ldouble_of_double (* ****** ****** *) fun abs_ldouble (ld: ldouble):<> ldouble = "atspre_abs_ldouble" overload abs with abs_ldouble fun neg_ldouble (ld: ldouble):<> ldouble = "atspre_neg_ldouble" overload ~ with neg_ldouble (* ****** ****** *) fun succ_ldouble (ld: ldouble):<> ldouble = "atspre_succ_ldouble" and pred_ldouble (ld: ldouble):<> ldouble = "atspre_pred_ldouble" overload succ with succ_ldouble overload pred with pred_ldouble (* ****** ****** *) fun add_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_add_ldouble_ldouble" and sub_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_sub_ldouble_ldouble" overload + with add_ldouble_ldouble overload - with sub_ldouble_ldouble (* ****** ****** *) fun mul_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_mul_ldouble_ldouble" and mul_int_ldouble (i1: int, ld2: ldouble):<> ldouble = "atspre_mul_int_ldouble" and mul_ldouble_int (ld1: ldouble, i2: int):<> ldouble = "atspre_mul_ldouble_int" overload * with mul_ldouble_ldouble overload * with mul_int_ldouble overload * with mul_ldouble_int fun div_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_div_ldouble_ldouble" and div_ldouble_int (ld1: ldouble, i2: int):<> ldouble = "atspre_div_ldouble_int" overload / with div_ldouble_ldouble overload / with div_ldouble_int (* ****** ****** *) fun lt_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_lt_ldouble_ldouble" and lte_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_lte_ldouble_ldouble" overload < with lt_ldouble_ldouble overload <= with lte_ldouble_ldouble fun gt_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_gt_ldouble_ldouble" and gte_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_gte_ldouble_ldouble" overload > with gt_ldouble_ldouble overload >= with gte_ldouble_ldouble fun eq_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_eq_ldouble_ldouble" and neq_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> bool = "atspre_neq_ldouble_ldouble" overload = with eq_ldouble_ldouble overload <> with neq_ldouble_ldouble overload != with neq_ldouble_ldouble fun compare_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> Sgn = "atspre_compare_ldouble_ldouble" overload compare with compare_ldouble_ldouble (* ****** ****** *) fun max_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_max_ldouble_ldouble" and min_ldouble_ldouble (ld1: ldouble, ld2: ldouble):<> ldouble = "atspre_min_ldouble_ldouble" overload max with max_ldouble_ldouble overload min with min_ldouble_ldouble (* ****** ****** *) fun square_ldouble (ld: ldouble):<> ldouble = "atspre_square_ldouble" overload square with square_ldouble fun cube_ldouble (ld: ldouble):<> ldouble = "atspre_cube_ldouble" overload cube with cube_ldouble fun pow_ldouble_int1 (ld: ldouble, n: Nat):<> ldouble overload pow with pow_ldouble_int1 (* ****** ****** *) // // print functions for floats of long double precision // (* ****** ****** *) symintr fprint_ldouble fun fprint0_ldouble (out: FILEref, x: ldouble): void = "atspre_fprint_ldouble" overload fprint_ldouble with fprint0_ldouble fun fprint1_ldouble {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: ldouble): void = "atspre_fprint_ldouble" overload fprint_ldouble with fprint1_ldouble overload fprint with fprint_ldouble fun print_ldouble (ld: ldouble): void = "atspre_print_ldouble" and prerr_ldouble (ld: ldouble): void = "atspre_prerr_ldouble" overload print with print_ldouble overload prerr with prerr_ldouble (* ****** ****** *) // // stringization // fun tostrptr_ldouble (ld: ldouble):<> strptr1 = "atspre_tostrptr_ldouble" overload tostrptr with tostrptr_ldouble fun tostring_ldouble (ld: ldouble):<> string = "atspre_tostrptr_ldouble" overload tostring with tostring_ldouble (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [float.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* end of [float.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/bool.sats0000664000175000017500000001277012223166161020044 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [bool.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // some basic operations on boolean values // (* ****** ****** *) castfn bool1_of_bool (x: bool):<> Bool (* ****** ****** *) fun bool_of_int (i: int):<> bool fun int_of_bool (b: bool):<> natLt(2) // Two fun bool1_of_int1 {i:int} (i: int i):<> bool (i <> 0) fun int1_of_bool1 {b:bool} (b: bool b):<> int (int_of_bool b) (* ****** ****** *) fun neg_bool (b: bool):<> bool = "atspre_neg_bool" overload ~ with neg_bool overload not with neg_bool fun add_bool_bool (b1: bool, b2: bool):<> bool = "mac#atspre_add_bool_bool" overload || with add_bool_bool fun mul_bool_bool (b1: bool, b2: bool):<> bool = "mac#atspre_mul_bool_bool" overload && with mul_bool_bool (* ****** ****** *) fun lt_bool_bool (b1: bool, b2: bool):<> bool = "atspre_lt_bool_bool" and lte_bool_bool (b1: bool, b2: bool):<> bool = "atspre_lte_bool_bool" overload < with lt_bool_bool overload <= with lte_bool_bool fun gt_bool_bool (b1: bool, b2: bool):<> bool = "atspre_gt_bool_bool" and gte_bool_bool (b1: bool, b2: bool):<> bool = "atspre_gte_bool_bool" overload > with gt_bool_bool overload >= with gte_bool_bool fun eq_bool_bool (b1: bool, b2: bool):<> bool = "atspre_eq_bool_bool" and neq_bool_bool (b1: bool, b2: bool):<> bool = "atspre_neq_bool_bool" overload = with eq_bool_bool overload <> with neq_bool_bool overload != with neq_bool_bool fun compare_bool_bool (b1: bool, b2: bool):<> Sgn = "atspre_compare_bool_bool" overload compare with compare_bool_bool (* ****** ****** *) // // print functions for booleans // (* ****** ****** *) symintr fprint_bool fun fprint0_bool (out: FILEref, x: bool): void = "atspre_fprint_bool" overload fprint_bool with fprint0_bool fun fprint1_bool {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: bool): void = "atspre_fprint_bool" overload fprint_bool with fprint1_bool overload fprint with fprint_bool fun print_bool (b: bool): void = "atspre_print_bool" overload print with print_bool fun prerr_bool (b: bool): void = "atspre_prerr_bool" overload prerr with prerr_bool (* ****** ****** *) // // HX: stringization // fun tostring_bool (b: bool):<> string = "atspre_tostring_bool" overload tostring with tostring_bool (* ****** ****** *) fun neg_bool1 {b:bool} (b: bool b):<> bool (~b) = "atspre_neg_bool1" overload ~ with neg_bool1 overload not with neg_bool1 (* ****** ****** *) fun add_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 || b2) = "mac#atspre_add_bool1_bool1" overload || with add_bool1_bool1 fun mul_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 && b2) = "mac#atspre_mul_bool1_bool1" overload && with mul_bool1_bool1 (* ****** ****** *) fun lt_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (~b1 && b2) = "atspre_lt_bool1_bool1" and lte_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (~b1 || b2) = "atspre_lte_bool1_bool1" overload < with lt_bool1_bool1 overload <= with lte_bool1_bool1 fun gt_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 && ~b2) = "atspre_gt_bool1_bool1" and gte_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 || ~b2) = "atspre_gte_bool1_bool1" overload > with gt_bool1_bool1 overload >= with gte_bool1_bool1 fun eq_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 == b2) = "atspre_eq_bool1_bool1" and neq_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> bool (b1 <> b2) = "atspre_neq_bool1_bool1" overload = with eq_bool1_bool1 overload <> with neq_bool1_bool1 (* ****** ****** *) local stadef b2i = int_of_bool in // in of [in] fun compare_bool1_bool1 {b1,b2:bool} (b1: bool b1, b2: bool b2):<> int (b2i b1 - b2i b2) = "atspre_compare_bool1_bool1" overload compare with compare_bool1_bool1 end // end of [local] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [bool.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [bool.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/arith.sats0000664000175000017500000001501212223166161020210 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [arith.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) dataprop MUL (int, int, int) = | {n:int} MULbas (0, n, 0) | {m,n,p:int | m >= 0} MULind (m+1, n, p+n) of MUL (m, n, p) | {m,n,p:int | m > 0} MULneg (~m, n, ~p) of MUL (m, n, p) // end of [MUL] (* ****** ****** *) (* ** HX: [mul_make] can be proven based on [mul_istot] and [mul_elim] *) praxi mul_make : {m,n:int} () - MUL (m, n, m*n) praxi mul_elim : {m,n:int} {p:int} MUL (m, n, p) - [p == m*n] void // // HX: (m+i)*n = m*n+i*n // praxi mul_add_const {i:int} {m,n:int} {p:int} (pf: MUL (m, n, p)): MUL (m+i, n, p+i*n) // end of [mul_add_const] // // HX: (ax+b)*(cy+d) = ac*xy + ad*x + bc*y + bd // praxi mul_expand_linear {a,b:int} {c,d:int} // a,b,c,d: constants! {x,y:int} {xy:int} (pf: MUL (x, y, xy)): MUL (a*x+b, c*y+d, a*c*xy+a*d*x+b*c*y+b*d) // end of [mul_expand_linear] // // HX: (a1x1+a2x2+b)*(c1y1+c2y2+d) = ... // praxi mul_expand2_linear // a1,b1,c1,a2,b2,c2: constants! {a1,a2,b:int} {c1,c2,d:int} {x1,x2:int} {y1,y2:int} {x1y1,x1y2,x2y1,x2y2:int} ( pf11: MUL (x1, y1, x1y1), pf12: MUL (x1, y2, x1y2) , pf21: MUL (x2, y1, x2y1), pf22: MUL (x2, y2, x2y2) ) : MUL ( a1*x1+a2*x2+b , c1*y1+c2*y2+d , a1*c1*x1y1 + a1*c2*x1y2 + a2*c1*x2y1 + a2*c2*x2y2 + a1*d*x1 + a2*d*x2 + b*c1*y1 + b*c2*y2 + b*d ) // end of [mul_expand2_linear] (* ****** ****** *) prfun mul_istot {m,n:int} (): [p:int] MUL (m, n, p) prfun mul_isfun {m,n:int} {p1,p2:int} (pf1: MUL (m, n, p1), pf2: MUL (m, n, p2)): [p1==p2] void (* ****** ****** *) prfun mul_nat_nat_nat : {m,n:nat} {p:int} MUL (m, n, p) - [p >= 0] void prfun mul_pos_pos_pos : {m,n:pos} {p:int} MUL (m, n, p) - [p >= m+n-1] void (* ****** ****** *) prfun mul_negate {m,n:int} {p:int} (pf: MUL (m, n, p)): MUL (~m, n, ~p) prfun mul_negate2 {m,n:int} {p:int} (pf: MUL (m, n, p)): MUL (m, ~n, ~p) (* ****** ****** *) prfun mul_commute {m,n:int} {p:int} (pf: MUL (m, n, p)): MUL (n, m, p) (* ****** ****** *) // // HX: m*(n1+n2) = m*n1+m*n2 // prfun mul_distribute {m:int} {n1,n2:int} {p1,p2:int} (pf1: MUL (m, n1, p1), pf2: MUL (m, n2, p2)): MUL (m, n1+n2, p1+p2) // // HX: (m1+m2)*n = m1*n + m2*n // prfun mul_distribute2 {m1,m2:int} {n:int} {p1,p2:int} (pf1: MUL (m1, n, p1), pf2: MUL (m2, n, p2)): MUL (m1+m2, n, p1+p2) (* ****** ****** *) prfun mul_is_associative {x,y,z:int} {xy,yz,xy_z,x_yz:int} ( pf1: MUL (x, y, xy) , pf2: MUL (y, z, yz) , pf3: MUL (xy, z, xy_z) , pf4: MUL (x, yz, x_yz) ) : [xy_z==x_yz] void (* ****** ****** *) // // HX-2010-12-30: // absprop DIVMOD ( x:int, y: int, q: int, r: int // x = q * y + r ) // end of [DIVMOD] propdef DIV (x:int, y:int, q:int) = [r:int] DIVMOD (x, y, q, r) propdef MOD (x:int, y:int, r:int) = [q:int] DIVMOD (x, y, q, r) praxi div_istot {x,y:int | x >= 0; y > 0} (): DIV (x, y, x/y) praxi divmod_istot {x,y:int | x >= 0; y > 0} (): [q,r:nat | r < y] DIVMOD (x, y, q, r) praxi divmod_isfun {x,y:int | x >= 0; y > 0} {q1,q2:int} {r1,r2:int} ( pf1: DIVMOD (x, y, q1, r1) , pf2: DIVMOD (x, y, q2, r2) ) : [q1==q2;r1==r2] void // end of [divmod_isfun] praxi divmod_elim {x,y:int | x >= 0; y > 0} {q,r:int} (pf: DIVMOD (x, y, q, r)): [qy:int | 0 <= r; r < y; x==qy+r] MUL (q, y, qy) // end of [divmod_elim] (* ****** ****** *) (* dataprop GCD (int, int, int) = | {m:nat} GCDbas1 (m, 0, m) | {n:pos} GCDbas2 (0, n, n) | {m:pos;n:int | m <= n} {r:int} GCDind1 (m, n, r) of GCD (m, n-m, r) | {m:int;n:pos | m > n } {r:int} GCDind2 (m, n, r) of GCD (m-n, n, r) | {m:nat;n:int | n < 0} {r:int} GCDneg1 (m, n, r) of GCD (m, ~n, r) | {m:int;n:int | m < 0} {r:int} GCDneg2 (m, n, r) of GCD (~m, n, r) // end of [GCD] *) // // HX-2010-12-31: GCD (0, 0, 0): gcd (0, 0) = 0 // absprop GCD (int, int, int) prfun gcd_istot {m,n:int} (): [r:nat] GCD (m,n,r) prfun gcd_isfun {m,n:int} {r1,r2:int} (pf1: GCD (m, n, r1), pf2: GCD (m, n, r2)): [r1==r2] void prfun gcd_commute {m,n:int} {r:int} (pf: GCD (m, n, r)): GCD (n, m, r) (* ****** ****** *) dataprop EXP2 (int, int) = | {n:nat} {p:nat} EXP2ind (n+1, 2*p) of EXP2 (n, p) | EXP2bas (0, 1) // end of [EXP2] // // HX: proven in [arith.dats] // prfun lemma_exp2_params : {n:int}{p:int} EXP2 (n, p) - [n>=0;p>=1] void // end of [lemma_exp2_params] // prfun exp2_istot {n:nat} (): [p:nat] EXP2 (n, p) prfun exp2_isfun {n:nat} {p1,p2:int} (pf1: EXP2 (n, p1), pf2: EXP2 (n, p2)): [p1==p2] void // end of [exp2_isfun] // prfun exp2_ispos {n:nat} {p:int} (pf: EXP2 (n, p)): [p >= 1] void // end of [exp2_ispos] // prfun exp2_ismono {n1,n2:nat | n1 <= n2} {p1,p2:int} (pf1: EXP2 (n1, p1), pf2: EXP2 (n2, p2)): [p1 <= p2] void // end of [exp2_ismono] // prfun exp2_mul {n1,n2:nat | n1 <= n2} {p1,p2:nat} {p:int} ( pf1: EXP2 (n1, p1), pf2: EXP2 (n2, p2), pf3: MUL (p1, p2, p) ) : EXP2 (n1+n2, p) // end of [exp2_mul] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [arith.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [arith.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/integer_fixed.sats0000664000175000017500000005607512223166161021733 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer_fixed.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // signed and unsigned integers with fixed size (* ****** ****** *) typedef int8 = int8_t0ype fun int8_of_int (i: int):<> int8 = "atspre_int8_of_int" fun int_of_int8 (i: int8):<> int = "atspre_int_of_int8" // ------ ------ fun abs_int8 (i: int8):<> int8 = "atspre_abs_int8" overload abs with abs_int8 fun neg_int8 (i: int8):<> int8 = "atspre_neg_int8" overload ~ with neg_int8 fun succ_int8 (i: int8):<> int8 = "atspre_succ_int8" and pred_int8 (i: int8):<> int8 = "atspre_pred_int8" overload succ with succ_int8 overload pred with pred_int8 fun add_int8_int8 (i: int8, j: int8):<> int8 = "atspre_add_int8_int8" and sub_int8_int8 (i: int8, j: int8):<> int8 = "atspre_sub_int8_int8" and mul_int8_int8 (i: int8, j: int8):<> int8 = "atspre_mul_int8_int8" and div_int8_int8 (i: int8, j: int8):<> int8 = "atspre_div_int8_int8" and mod_int8_int8 (i: int8, j: int8):<> int8 = "atspre_mod_int8_int8" overload + with add_int8_int8 overload - with sub_int8_int8 overload * with mul_int8_int8 overload / with div_int8_int8 overload mod with mod_int8_int8 fun lt_int8_int8 (i: int8, j: int8):<> bool = "atspre_lt_int8_int8" and lte_int8_int8 (i: int8, j: int8):<> bool = "atspre_lte_int8_int8" fun gt_int8_int8 (i: int8, j: int8):<> bool = "atspre_gt_int8_int8" and gte_int8_int8 (i: int8, j: int8):<> bool = "atspre_gte_int8_int8" fun eq_int8_int8 (i: int8, j: int8):<> bool = "atspre_eq_int8_int8" and neq_int8_int8 (i: int8, j: int8):<> bool = "atspre_neq_int8_int8" overload < with lt_int8_int8 overload <= with lte_int8_int8 overload > with gt_int8_int8 overload >= with gte_int8_int8 overload = with eq_int8_int8 overload <> with neq_int8_int8 fun max_int8_int8 (i: int8, j: int8):<> int8 = "atspre_max_int8_int8" and min_int8_int8 (i: int8, j: int8):<> int8 = "atspre_min_int8_int8" overload max with max_int8_int8 overload min with min_int8_int8 (* ****** ****** *) symintr fprint_int8 fun fprint0_int8 (out: FILEref, x: int8): void = "atspre_fprint_int8" overload fprint_int8 with fprint0_int8 fun fprint1_int8 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: int8): void = "atspre_fprint_int8" overload fprint_int8 with fprint1_int8 overload fprint with fprint_int8 fun print_int8 (i: int8): void = "atspre_print_int8" and prerr_int8 (i: int8): void = "atspre_prerr_int8" overload print with print_int8 overload prerr with prerr_int8 (* ****** ****** *) typedef uint8 = uint8_t0ype fun uint8_of_uint (i: uint):<> uint8 = "atspre_uint8_of_uint" fun uint_of_uint8 (i: uint8):<> uint = "atspre_uint_of_uint8" // ------ ------ fun succ_uint8 (i: uint8):<> uint8 = "atspre_succ_uint8" and pred_uint8 (i: uint8):<> uint8 = "atspre_pred_uint8" overload succ with succ_uint8 overload pred with pred_uint8 fun add_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_add_uint8_uint8" and sub_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_sub_uint8_uint8" and mul_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_mul_uint8_uint8" and div_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_div_uint8_uint8" and mod_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_mod_uint8_uint8" overload + with add_uint8_uint8 overload - with sub_uint8_uint8 overload * with mul_uint8_uint8 overload / with div_uint8_uint8 overload mod with mod_uint8_uint8 fun lt_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_lt_uint8_uint8" and lte_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_lte_uint8_uint8" fun gt_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_gt_uint8_uint8" and gte_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_gte_uint8_uint8" fun eq_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_eq_uint8_uint8" and neq_uint8_uint8 (i: uint8, j: uint8):<> bool = "atspre_neq_uint8_uint8" overload < with lt_uint8_uint8 overload <= with lte_uint8_uint8 overload > with gt_uint8_uint8 overload >= with gte_uint8_uint8 overload = with eq_uint8_uint8 overload <> with neq_uint8_uint8 fun max_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_max_uint8_uint8" and min_uint8_uint8 (i: uint8, j: uint8):<> uint8 = "atspre_min_uint8_uint8" overload max with max_uint8_uint8 overload min with min_uint8_uint8 (* ****** ****** *) symintr fprint_uint8 fun fprint0_uint8 (out: FILEref, x: uint8): void = "atspre_fprint_uint8" overload fprint_uint8 with fprint0_uint8 fun fprint1_uint8 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uint8): void = "atspre_fprint_uint8" overload fprint_uint8 with fprint1_uint8 overload fprint with fprint_uint8 fun print_uint8 (i: uint8): void = "atspre_print_uint8" and prerr_uint8 (i: uint8): void = "atspre_prerr_uint8" overload print with print_uint8 overload prerr with prerr_uint8 (* ****** ****** *) // signed integer of size 16bit typedef int16 = int16_t0ype fun int16_of_int (i: int):<> int16 = "atspre_int16_of_int" fun int_of_int16 (i: int16):<> int = "atspre_int_of_int16" // ------ ------ fun abs_int16 (i: int16):<> int16 = "atspre_abs_int16" overload abs with abs_int16 fun neg_int16 (i: int16):<> int16 = "atspre_neg_int16" overload ~ with neg_int16 fun succ_int16 (i: int16):<> int16 = "atspre_succ_int16" and pred_int16 (i: int16):<> int16 = "atspre_pred_int16" overload succ with succ_int16 overload pred with pred_int16 fun add_int16_int16 (i: int16, j: int16):<> int16 = "atspre_add_int16_int16" and sub_int16_int16 (i: int16, j: int16):<> int16 = "atspre_sub_int16_int16" and mul_int16_int16 (i: int16, j: int16):<> int16 = "atspre_mul_int16_int16" and div_int16_int16 (i: int16, j: int16):<> int16 = "atspre_div_int16_int16" and mod_int16_int16 (i: int16, j: int16):<> int16 = "atspre_mod_int16_int16" overload + with add_int16_int16 overload - with sub_int16_int16 overload * with mul_int16_int16 overload / with div_int16_int16 overload mod with mod_int16_int16 fun lt_int16_int16 (i: int16, j: int16):<> bool = "atspre_lt_int16_int16" and lte_int16_int16 (i: int16, j: int16):<> bool = "atspre_lte_int16_int16" fun gt_int16_int16 (i: int16, j: int16):<> bool = "atspre_gt_int16_int16" and gte_int16_int16 (i: int16, j: int16):<> bool = "atspre_gte_int16_int16" fun eq_int16_int16 (i: int16, j: int16):<> bool = "atspre_eq_int16_int16" and neq_int16_int16 (i: int16, j: int16):<> bool = "atspre_neq_int16_int16" overload < with lt_int16_int16 overload <= with lte_int16_int16 overload > with gt_int16_int16 overload >= with gte_int16_int16 overload = with eq_int16_int16 overload <> with neq_int16_int16 fun max_int16_int16 (i: int16, j: int16):<> int16 = "atspre_max_int16_int16" and min_int16_int16 (i: int16, j: int16):<> int16 = "atspre_min_int16_int16" overload max with max_int16_int16 overload min with min_int16_int16 (* ****** ****** *) symintr fprint_int16 fun fprint0_int16 (out: FILEref, x: int16): void = "atspre_fprint_int16" overload fprint_int16 with fprint0_int16 fun fprint1_int16 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: int16): void = "atspre_fprint_int16" overload fprint_int16 with fprint1_int16 overload fprint with fprint_int16 fun print_int16 (i: int16): void = "atspre_print_int16" and prerr_int16 (i: int16): void = "atspre_prerr_int16" overload print with print_int16 overload prerr with prerr_int16 (* ****** ****** *) // unsigned integer of size 16bit typedef uint16 = uint16_t0ype fun uint16_of_int (i: int):<> uint16 = "atspre_uint16_of_int" fun int_of_uint16 (u: uint16):<> int = "atspre_int_of_uint16" fun uint16_of_uint (i: uint):<> uint16 = "atspre_uint16_of_uint" fun uint_of_uint16 (i: uint16):<> uint = "atspre_uint_of_uint16" // ------ ------ fun succ_uint16 (i: uint16):<> uint16 = "atspre_succ_uint16" and pred_uint16 (i: uint16):<> uint16 = "atspre_pred_uint16" overload succ with succ_uint16 overload pred with pred_uint16 fun add_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_add_uint16_uint16" and sub_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_sub_uint16_uint16" and mul_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_mul_uint16_uint16" and div_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_div_uint16_uint16" and mod_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_mod_uint16_uint16" overload + with add_uint16_uint16 overload - with sub_uint16_uint16 overload * with mul_uint16_uint16 overload / with div_uint16_uint16 overload mod with mod_uint16_uint16 fun lt_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_lt_uint16_uint16" and lte_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_lte_uint16_uint16" fun gt_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_gt_uint16_uint16" and gte_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_gte_uint16_uint16" fun eq_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_eq_uint16_uint16" and neq_uint16_uint16 (i: uint16, j: uint16):<> bool = "atspre_neq_uint16_uint16" overload < with lt_uint16_uint16 overload <= with lte_uint16_uint16 overload > with gt_uint16_uint16 overload >= with gte_uint16_uint16 overload = with eq_uint16_uint16 overload <> with neq_uint16_uint16 fun max_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_max_uint16_uint16" and min_uint16_uint16 (i: uint16, j: uint16):<> uint16 = "atspre_min_uint16_uint16" overload max with max_uint16_uint16 overload min with min_uint16_uint16 (* ****** ****** *) symintr fprint_uint16 fun fprint0_uint16 (out: FILEref, x: uint16): void = "atspre_fprint_uint16" overload fprint_uint16 with fprint0_uint16 fun fprint1_uint16 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uint16): void = "atspre_fprint_uint16" overload fprint_uint16 with fprint1_uint16 overload fprint with fprint_uint16 fun print_uint16 (i: uint16): void = "atspre_print_uint16" and prerr_uint16 (i: uint16): void = "atspre_prerr_uint16" overload print with print_uint16 overload prerr with prerr_uint16 (* ****** ****** *) // signed integer of size 32bit typedef int32 = int32_t0ype fun int32_of_int (i: int):<> int32 = "atspre_int32_of_int" fun int_of_int32 (i: int32):<> int = "atspre_int_of_int32" // ------ ------ fun abs_int32 (i: int32):<> int32 = "atspre_abs_int32" overload abs with abs_int32 fun neg_int32 (i: int32):<> int32 = "atspre_neg_int32" overload ~ with neg_int32 fun succ_int32 (i: int32):<> int32 = "atspre_succ_int32" and pred_int32 (i: int32):<> int32 = "atspre_pred_int32" overload succ with succ_int32 overload pred with pred_int32 fun add_int32_int32 (i: int32, j: int32):<> int32 = "atspre_add_int32_int32" and sub_int32_int32 (i: int32, j: int32):<> int32 = "atspre_sub_int32_int32" and mul_int32_int32 (i: int32, j: int32):<> int32 = "atspre_mul_int32_int32" and div_int32_int32 (i: int32, j: int32):<> int32 = "atspre_div_int32_int32" and mod_int32_int32 (i: int32, j: int32):<> int32 = "atspre_mod_int32_int32" overload + with add_int32_int32 overload - with sub_int32_int32 overload * with mul_int32_int32 overload / with div_int32_int32 overload mod with mod_int32_int32 fun lt_int32_int32 (i: int32, j: int32):<> bool = "atspre_lt_int32_int32" and lte_int32_int32 (i: int32, j: int32):<> bool = "atspre_lte_int32_int32" fun gt_int32_int32 (i: int32, j: int32):<> bool = "atspre_gt_int32_int32" and gte_int32_int32 (i: int32, j: int32):<> bool = "atspre_gte_int32_int32" fun eq_int32_int32 (i: int32, j: int32):<> bool = "atspre_eq_int32_int32" and neq_int32_int32 (i: int32, j: int32):<> bool = "atspre_neq_int32_int32" overload < with lt_int32_int32 overload <= with lte_int32_int32 overload > with gt_int32_int32 overload >= with gte_int32_int32 overload = with eq_int32_int32 overload <> with neq_int32_int32 fun compare_int32_int32 (i1: int32, i2: int32):<> Sgn = "atspre_compare_int32_int32" overload compare with compare_int32_int32 fun max_int32_int32 (i: int32, j: int32):<> int32 = "atspre_max_int32_int32" and min_int32_int32 (i: int32, j: int32):<> int32 = "atspre_min_int32_int32" overload max with max_int32_int32 overload min with min_int32_int32 (* ****** ****** *) symintr fprint_int32 fun fprint0_int32 (out: FILEref, x: int32): void = "atspre_fprint_int32" overload fprint_int32 with fprint0_int32 fun fprint1_int32 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: int32): void = "atspre_fprint_int32" overload fprint_int32 with fprint1_int32 overload fprint with fprint_int32 fun print_int32 (i: int32): void = "atspre_print_int32" and prerr_int32 (i: int32): void = "atspre_prerr_int32" overload print with print_int32 overload prerr with prerr_int32 (* ****** ****** *) // // stringization // fun tostrptr_int32 (i: int32):<> strptr1 = "atspre_tostrptr_int32" overload tostrptr with tostrptr_int32 fun tostring_int32 (i: int32):<> string = "atspre_tostrptr_int32" overload tostring with tostring_int32 (* ****** ****** *) // unsigned integer of size 32bit typedef uint32 = uint32_t0ype fun uint32_of_uint (i: uint):<> uint32 = "atspre_uint32_of_uint" fun uint_of_uint32 (i: uint32):<> uint = "atspre_uint_of_uint32" // ------ ------ fun succ_uint32 (i: uint32):<> uint32 = "atspre_succ_uint32" and pred_uint32 (i: uint32):<> uint32 = "atspre_pred_uint32" overload succ with succ_uint32 overload pred with pred_uint32 fun add_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_add_uint32_uint32" and sub_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_sub_uint32_uint32" and mul_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_mul_uint32_uint32" and div_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_div_uint32_uint32" and mod_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_mod_uint32_uint32" overload + with add_uint32_uint32 overload - with sub_uint32_uint32 overload * with mul_uint32_uint32 overload / with div_uint32_uint32 overload mod with mod_uint32_uint32 fun lt_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_lt_uint32_uint32" and lte_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_lte_uint32_uint32" fun gt_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_gt_uint32_uint32" and gte_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_gte_uint32_uint32" fun eq_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_eq_uint32_uint32" and neq_uint32_uint32 (i: uint32, j: uint32):<> bool = "atspre_neq_uint32_uint32" overload < with lt_uint32_uint32 overload <= with lte_uint32_uint32 overload > with gt_uint32_uint32 overload >= with gte_uint32_uint32 overload = with eq_uint32_uint32 overload <> with neq_uint32_uint32 fun max_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_max_uint32_uint32" and min_uint32_uint32 (i: uint32, j: uint32):<> uint32 = "atspre_min_uint32_uint32" overload max with max_uint32_uint32 overload min with min_uint32_uint32 (* ****** ****** *) symintr fprint_uint32 fun fprint0_uint32 (out: FILEref, x: uint32): void = "atspre_fprint_uint32" overload fprint_uint32 with fprint0_uint32 fun fprint1_uint32 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uint32): void = "atspre_fprint_uint32" overload fprint_uint32 with fprint1_uint32 overload fprint with fprint_uint32 fun print_uint32 (i: uint32): void = "atspre_print_uint32" and prerr_uint32 (i: uint32): void = "atspre_prerr_uint32" overload print with print_uint32 overload prerr with prerr_uint32 (* ****** ****** *) // signed integer of size 64bit typedef int64 = int64_t0ype symintr int64_of fun int64_of_int (i: int):<> int64 = "atspre_int64_of_int" overload int64_of with int64_of_int fun int64_of_lint (i: lint):<> int64 = "atspre_int64_of_lint" overload int64_of with int64_of_lint fun int64_of_llint (i: llint):<> int64 = "atspre_int64_of_llint" overload int64_of with int64_of_llint fun int_of_int64 (i: int64):<> int = "atspre_int_of_int64" // ------ ------ fun abs_int64 (i: int64):<> int64 = "atspre_abs_int64" overload abs with abs_int64 fun neg_int64 (i: int64):<> int64 = "atspre_neg_int64" overload ~ with neg_int64 fun succ_int64 (i: int64):<> int64 = "atspre_succ_int64" and pred_int64 (i: int64):<> int64 = "atspre_pred_int64" overload succ with succ_int64 overload pred with pred_int64 fun add_int64_int64 (i: int64, j: int64):<> int64 = "atspre_add_int64_int64" and sub_int64_int64 (i: int64, j: int64):<> int64 = "atspre_sub_int64_int64" and mul_int64_int64 (i: int64, j: int64):<> int64 = "atspre_mul_int64_int64" and div_int64_int64 (i: int64, j: int64):<> int64 = "atspre_div_int64_int64" and mod_int64_int64 (i: int64, j: int64):<> int64 = "atspre_mod_int64_int64" overload + with add_int64_int64 overload - with sub_int64_int64 overload * with mul_int64_int64 overload / with div_int64_int64 overload mod with mod_int64_int64 fun lt_int64_int64 (i: int64, j: int64):<> bool = "atspre_lt_int64_int64" and lte_int64_int64 (i: int64, j: int64):<> bool = "atspre_lte_int64_int64" fun gt_int64_int64 (i: int64, j: int64):<> bool = "atspre_gt_int64_int64" and gte_int64_int64 (i: int64, j: int64):<> bool = "atspre_gte_int64_int64" fun eq_int64_int64 (i: int64, j: int64):<> bool = "atspre_eq_int64_int64" and neq_int64_int64 (i: int64, j: int64):<> bool = "atspre_neq_int64_int64" overload < with lt_int64_int64 overload <= with lte_int64_int64 overload > with gt_int64_int64 overload >= with gte_int64_int64 overload = with eq_int64_int64 overload <> with neq_int64_int64 fun compare_int64_int64 (i1: int64, i2: int64):<> Sgn = "atspre_compare_int64_int64" overload compare with compare_int64_int64 fun max_int64_int64 (i: int64, j: int64):<> int64 = "atspre_max_int64_int64" and min_int64_int64 (i: int64, j: int64):<> int64 = "atspre_min_int64_int64" overload max with max_int64_int64 overload min with min_int64_int64 (* ****** ****** *) symintr fprint_int64 fun fprint0_int64 (out: FILEref, x: int64): void = "atspre_fprint_int64" overload fprint_int64 with fprint0_int64 fun fprint1_int64 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: int64): void = "atspre_fprint_int64" overload fprint_int64 with fprint1_int64 overload fprint with fprint_int64 fun print_int64 (i: int64): void = "atspre_print_int64" and prerr_int64 (i: int64): void = "atspre_prerr_int64" overload print with print_int64 overload prerr with prerr_int64 (* ****** ****** *) // // stringization // fun tostrptr_int64 (i: int64):<> strptr1 = "atspre_tostrptr_int64" overload tostrptr with tostrptr_int64 fun tostring_int64 (i: int64):<> string = "atspre_tostrptr_int64" overload tostring with tostring_int64 (* ****** ****** *) // unsigned integer of size 64bit typedef uint64 = uint64_t0ype symintr uint64_of fun uint64_of_int1 {i:nat} (i: int i):<> uint64 = "atspre_uint64_of_int1" overload uint64_of with uint64_of_int1 fun uint64_of_uint (i: uint):<> uint64 = "atspre_uint64_of_uint" overload uint64_of with uint64_of_uint fun uint64_of_ulint (i: ulint):<> uint64 = "atspre_uint64_of_ulint" overload uint64_of with uint64_of_ulint fun uint64_of_ullint (i: ullint):<> uint64 = "atspre_uint64_of_ullint" overload uint64_of with uint64_of_ullint fun uint_of_uint64 (i: uint64):<> uint = "atspre_uint_of_uint64" // ------ ------ fun succ_uint64 (i: uint64):<> uint64 = "atspre_succ_uint64" and pred_uint64 (i: uint64):<> uint64 = "atspre_pred_uint64" overload succ with succ_uint64 overload pred with pred_uint64 fun add_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_add_uint64_uint64" and sub_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_sub_uint64_uint64" and mul_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_mul_uint64_uint64" and div_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_div_uint64_uint64" and mod_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_mod_uint64_uint64" overload + with add_uint64_uint64 overload - with sub_uint64_uint64 overload * with mul_uint64_uint64 overload / with div_uint64_uint64 overload mod with mod_uint64_uint64 fun lt_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_lt_uint64_uint64" and lte_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_lte_uint64_uint64" fun gt_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_gt_uint64_uint64" and gte_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_gte_uint64_uint64" fun eq_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_eq_uint64_uint64" and neq_uint64_uint64 (i: uint64, j: uint64):<> bool = "atspre_neq_uint64_uint64" overload < with lt_uint64_uint64 overload <= with lte_uint64_uint64 overload > with gt_uint64_uint64 overload >= with gte_uint64_uint64 overload = with eq_uint64_uint64 overload <> with neq_uint64_uint64 fun max_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_max_uint64_uint64" and min_uint64_uint64 (i: uint64, j: uint64):<> uint64 = "atspre_min_uint64_uint64" overload max with max_uint64_uint64 overload min with min_uint64_uint64 (* ****** ****** *) symintr fprint_uint64 fun fprint0_uint64 (out: FILEref, x: uint64): void = "atspre_fprint_uint64" overload fprint_uint64 with fprint0_uint64 fun fprint1_uint64 {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uint64): void = "atspre_fprint_uint64" overload fprint_uint64 with fprint1_uint64 overload fprint with fprint_uint64 fun print_uint64 (i: uint64): void = "atspre_print_uint64" and prerr_uint64 (i: uint64): void = "atspre_prerr_uint64" overload print with print_uint64 overload prerr with prerr_uint64 (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer_fixed.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [integer_fixed.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/extern.sats0000664000175000017500000000621612223166161020414 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: January 29, 2010 // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) // // HX: this file is mostly used for building API's for external packages. // The "tricks" presented here should be used sparringly in cases that do // require special attention. // (* ****** ****** *) viewdef vptrout // virtual ownership (a:viewt@ype, l:addr) = (a @ l, a @ l - void) // end of [vptrout] viewdef vptroutopt // optional virtual ownership (a:viewt@ype, l:addr) = option_v (vptrout (a, l), l > null) // end of [vptroutopt] (* ****** ****** *) // // HX: note that (vt1 \minus v2) roughly means that a ticket of // [v2] is taken from [vt1]; the ticket must be returned before // [vt1] is consumed. // absview minus_viewt0ype_view (vt1: viewt@ype, v2: view) = vt1 stadef minus = minus_viewt0ype_view prfun minus_addback {vt1:viewt@ype} {v2:view} (pf1: minus (vt1, v2), pf2: v2 | x: !vt1): void // end of [minus_addback] (* ****** ****** *) // // HX-2010-04-18: // the type [stamped] should only be used in a situation // where the value cannot be uniquely identified by its type // absviewtype stamped (a:viewtype, l:addr) = a prfun stamped_encode {a:viewtype} (x: !a >> stamped (a, l)):<> #[l:addr] void // end of [stamped_encode] prfun stamped_decode {a:viewtype} {l:addr} (x: !stamped (a, l) >> a):<> void // end of [stamped_decode] (* ****** ****** *) // // HX-2010-11-26: mrsw: multiple-read-single-write // absviewt@ype mrsw_viewt0ype_int_viewt0ype (a:viewt@ype, n:int) = a stadef mrsw = mrsw_viewt0ype_int_viewt0ype // praxi mrsw_encode {a:viewt@ype} (x: !a >> mrsw (a, 0)): void praxi mrsw_decode {a:viewt@ype} (x: !mrsw (a, 0) >> a): void // (* ****** ****** *) (* end of [extern.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/ptrarr.sats0000664000175000017500000000520712223166161020420 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) (* // // HX-2010-10-14: this accurately describes [ptrarr]: // typedef Ptr1 = [l:agz] ptr (l) dataview ptrarr_v (n:int, l:addr) = | {l:addr} ptrarr_v_nil (0, l) of ptr(null) @ l | {l:addr} ptrarr_v_cons (n+1, l) of (Ptr1 @ l, ptrarr_v (n, l+sizeof(ptr))) // end of [ptrarr_v] *) abst@ype ptrarr (n:int) = array (ptr, n+1) (* ****** ****** *) praxi ptrarr_nil {l:addr} (pf: ptr null @ l): ptrarr (0) @ l praxi ptrarr_unnil {l:addr} (pf: ptrarr (0) @ l): ptr null @ l (* ****** ****** *) praxi ptrarr_cons {n:pos}{l:addr} ( pf1: Ptr1 @ l, pf2: ptrarr (n-1) @ l+sizeof(ptr) ) : ptrarr (n) @ l // end of [ptrarr_cons] praxi ptrarr_uncons {n:pos}{l:addr} (pf: ptrarr (n) @ l): (Ptr1 @ l, ptrarr (n-1) @ l+sizeof(ptr)) // end of [ptrarr_uncons] (* ****** ****** *) praxi ptrarr_takeout {vt:viewtype} {n:nat} {l:addr} (pf: ptrarr(n) @ l): ( array_v (vt, n, l), array_v (vt, n, l) - ptrarr(n) @ l ) // end of [ptrarr_takeout] (* ****** ****** *) fun ptrarr_size {n:nat} (x: &ptrarr(n)): size_t(n) = "atspre_ptrarr_size" // end of [ptrarr_size] (* ****** ****** *) (* end of [ptrarr.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/dlist_vt.sats0000664000175000017500000001162712223166161020741 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2012 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) sortdef tp = type sortdef vtp = viewtype sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) (* ** ** HX-2012-02-29: ** dlist_vt (a, f, r) means that there are f elements in ** front of the current one while r-1 elements after it. So the ** total number of elements is f+r. If f=r=0, then the list is ** empty. ** *) absviewtype // f: front; r: rear dlist_viewt0ype_int_int_viewtype (a: viewt@ype+, f: int, r: int) stadef dlist_vt = dlist_viewt0ype_int_int_viewtype (* ****** ****** *) praxi lemma1_dlist_vt_params {a:vt0p} {f,r:int} (xs: !dlist_vt (a, f, r)): [f >= 0;r >= 0] void // end of [lemma_dlist_vt_params] praxi lemma2_dlist_vt_params {a:vt0p} {f:int} (xs: !dlist_vt (a, f, 0)): [f == 0] void // end of [lemma2_dlist_vt_params] (* ****** ****** *) fun{a:vt0p} dlist_vt_nil ():<> dlist_vt (a, 0, 0) fun{a:vt0p} dlist_vt_sing (x: a):<> dlist_vt (a, 0, 1) fun{a:vt0p} dlist_vt_cons {r:int} (x: a, xs: dlist_vt (a, 0, r)):<> dlist_vt (a, 0, r+1) fun{a:vt0p} dlist_vt_snoc {f:int} (xs: dlist_vt (a, f, 1), x: a):<> dlist_vt (a, f+1, 1) (* ****** ****** *) fun{a:vt0p} dlist_vt_is_beg {f,r:int | r > 0} (xs: !dlist_vt (a, f, r)):<> bool (f==0) // end of [dlist_vt_is_beg] fun{a:vt0p} dlist_vt_is_end {f,r:int | r > 0} (xs: !dlist_vt (a, f, r)):<> bool (r==1) // end of [dlist_vt_is_end] fun{a:vt0p} rdlist_vt_is_beg {f,r:int | r > 0} (xs: !dlist_vt (a, f, r)):<> bool (r==1) // end of [rdlist_vt_is_end] fun{a:vt0p} rdlist_vt_is_end {f,r:int | r > 0} (xs: !dlist_vt (a, f, r)):<> bool (f==0) // end of [rdlist_vt_is_end] (* ****** ****** *) fun{a:t0p} dlist_vt_get {f,r:int | r > 0} (xs: !dlist_vt (a, f, r)): a // end of [dlist_vt_get] fun{a:t0p} dlist_vt_set {f,r:int | r > 0} (xs: !dlist_vt (a, f, r), x: a): void // end of [dlist_vt_set] (* ****** ****** *) fun{a:vt0p} dlist_vt_length {f,r:int} (xs: !dlist_vt (a, f, r)):<> int (r) fun{a:vt0p} rdlist_vt_length {f,r:int} (xs: !dlist_vt (a, f, r)):<> int (f) (* ****** ****** *) fun{a:vt0p} dlist_vt_move {f,r:int | r > 1} (xs: dlist_vt (a, f, r)):<> dlist_vt (a, f+1, r-1) fun{a:vt0p} rdlist_vt_move {f,r:int | f > 0} (xs: dlist_vt (a, f, r)):<> dlist_vt (a, f-1, r+1) (* ****** ****** *) fun{a:vt0p} dlist_vt_move_end {f,r:int | r > 0} (xs: dlist_vt (a, f, r)):<> dlist_vt (a, f+r-1, 1) // end of [dlist_vt_move_end] fun{a:vt0p} rdlist_vt_move_end {f,r:int | r > 0} (xs: dlist_vt (a, f, r)):<> dlist_vt (a, 0, f+r) // end of [rdlist_vt_move_end] (* ****** ****** *) fun{a:vt0p} dlist_vt_insert {f,r:int | r > 0} (xs: dlist_vt (a, f, r), x: a):<> dlist_vt (a, f, r+1) // end of [dlist_vt_insert] (* ****** ****** *) fun{a:t@ype} dlist_vt_free {r:int} (xs: dlist_vt (a, 0, r)):<> void (* ****** ****** *) fun{a:vt0p} dlist_vt_foreach_funenv {v:view}{vt:vtp}{f,r:int}{fe:eff} ( pf: !v | xs: !dlist_vt (a, f, r) , f: !(!v | &a, !vt) - void, env: !vt ) : void // end of [dlist_vt_foreach_funenv] fun{a:vt0p} dlist_vt_foreach_fun {f,r:int} {fe:eff} (xs: !dlist_vt (a, f, r), f: (&a) - void): void // end of [dlist_vt_foreach_fun] (* ****** ****** *) fun{a:vt0p} rdlist_vt_foreach_funenv {v:view}{vt:vtp}{f,r:int}{fe:eff} ( pf: !v | xs: !dlist_vt (a, f, r) , f: !(!v | &a, !vt) - void , env: !vt ) : void // end of [rdlist_vt_foreach_funenv] fun{a:vt0p} rdlist_vt_foreach_fun {f,r:int} {fe:eff} (xs: !dlist_vt (a, f, r), f: (&a) - void): void // end of [rdlist_vt_foreach_fun] (* ****** ****** *) (* end of [dlist_vt.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/array0.sats0000664000175000017500000000754112223166161020307 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: // Note that [array0] is a persistent array with size information attached. // This package is mostly for a beginner who is unfamiliar with ATS. After // some exposure to dependent types and linear types, the programmer is // recommended to use functions declared in [array.sats] instead. // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [array0.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // HX: array0 (a) = ref (Arraysize a) // (* ****** ****** *) (* ** HX-2011-01-12: ** it is changed from a fun to a castfn *) castfn array0_get_arrszref {a:viewt@ype} (A: array0 a):<> ref (Arrpsz (a)) // end of [array0_get_arrszref] (* ****** ****** *) fun array0_make_arrpsz {a:viewt@ype}{n:nat} (psz: arrpsz (a, n)):<> array0 (a) // end of [array0_make_arrpsz] (* ****** ****** *) fun{a:t@ype} array0_make_elt (asz: size_t, x: a):<> array0 a // end of [array0_make_elt] fun{a:t@ype} array0_make_lst (xs: list0 a):<> array0 a (* ****** ****** *) // // HX: this is a polymorphic function // fun array0_size {a:t@ype} (A: array0 a): size_t (* ****** ****** *) fun{a:t@ype} array0_get_elt_at ( A: array0 a, i: size_t ) : a // endfun overload [] with array0_get_elt_at fun{a:t@ype} array0_get_elt_at__intsz (A: array0 a, i: int): a overload [] with array0_get_elt_at__intsz fun{a:t@ype} array0_set_elt_at ( A: array0 a, i: size_t, x: a ) : void // endfun overload [] with array0_set_elt_at fun{a:t@ype} array0_set_elt_at__intsz (A: array0 a, i: int, x: a): void overload [] with array0_set_elt_at__intsz (* ****** ****** *) fun{ a:viewt@ype } array0_exch ( A: array0 a, i: size_t, j: size_t ) : void // endfun fun{ a:viewt@ype } array0_exch__intsz (A: array0 a, i: int, j: int): void // end of [array0_exch__intsz] (* ****** ****** *) fun{a:t@ype} array0_foreach (A: array0 a, f: (&a) - void): void // end of [array0_foreach] (* ****** ****** *) fun{a:t@ype} array0_iforeach (A: array0 a, f: (size_t, &a) - void): void // end of [array0_iforeach] (* ****** ****** *) fun{a:t@ype} array0_tabulate (asz: size_t, f: size_t - a):<> array0 a // end of [array0_tabulate] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [array0.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [array0.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/integer.sats0000664000175000017500000007731712223166161020556 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // signed integers (of unindexed type) (* ****** ****** *) castfn int_of_uint (u: uint):<> int overload int_of with int_of_uint (* ****** ****** *) fun int_of_char (c: char):<> int = "atspre_int_of_char" overload int_of with int_of_char fun int_of_schar (c: schar):<> int = "atspre_int_of_schar" overload int_of with int_of_schar fun int_of_uchar (c: uchar):<> int = "atspre_int_of_uchar" overload int_of with int_of_uchar // This function is based on [atoi] in [stdlib.h] fun int_of_string (s: string):<> int = "atspre_int_of_string" overload int_of with int_of_string (* ****** ****** *) // arithmetic functions and comparison functions fun abs_int (i: int):<> int = "atspre_abs_int" overload abs with abs_int fun neg_int (i: int):<> int = "atspre_neg_int" overload ~ with neg_int fun succ_int (i: int):<> int = "atspre_succ_int" and pred_int (i: int):<> int = "atspre_pred_int" overload succ with succ_int overload pred with pred_int fun add_int_int (i1: int, i2: int):<> int = "atspre_add_int_int" and sub_int_int (i1: int, i2: int):<> int = "atspre_sub_int_int" overload + with add_int_int overload - with sub_int_int fun mul_int_int (i1: int, i2: int):<> int = "atspre_mul_int_int" and div_int_int (i1: int, i2: int):<> int = "atspre_div_int_int" overload * with mul_int_int overload / with div_int_int fun mod_int_int (i1: int, i2: int):<> int = "atspre_mod_int_int" overload mod with mod_int_int fun gcd_int_int (i1: int, i2: int):<> int = "atspre_gcd_int_int" overload gcd with gcd_int_int fun lt_int_int (i1: int, i2: int):<> bool = "atspre_lt_int_int" and lte_int_int (i1: int, i2: int):<> bool = "atspre_lte_int_int" overload < with lt_int_int overload <= with lte_int_int fun gt_int_int (i1: int, i2: int):<> bool = "atspre_gt_int_int" and gte_int_int (i1: int, i2: int):<> bool = "atspre_gte_int_int" overload > with gt_int_int overload >= with gte_int_int fun eq_int_int (i1: int, i2: int):<> bool = "atspre_eq_int_int" fun neq_int_int (i1: int, i2: int):<> bool = "atspre_neq_int_int" overload = with eq_int_int overload <> with neq_int_int overload != with neq_int_int fun compare_int_int (i1: int, i2: int):<> Sgn = "atspre_compare_int_int" overload compare with compare_int_int fun max_int_int (i1: int, i2: int):<> int = "atspre_max_int_int" and min_int_int (i1: int, i2: int):<> int = "atspre_min_int_int" overload max with max_int_int overload min with min_int_int fun square_int (i: int):<> int = "atspre_square_int" overload square with square_int fun cube_int (i: int):<> int = "atspre_cube_int" overload cube with cube_int fun pow_int_int1 (base: int, exponent: Nat):<> int = "atspre_pow_int_int1" overload pow with pow_int_int1 (* ****** ****** *) // // bit operations // fun asl_int_int1 (i: int, n: Nat):<> int = "atspre_asl_int_int1" overload << with asl_int_int1 fun asr_int_int1 (i: int, n: Nat):<> int = "atspre_asr_int_int1" overload >> with asr_int_int1 (* ****** ****** *) symintr fprint_int fun fprint0_int (out: FILEref, x: int): void = "atspre_fprint_int" overload fprint_int with fprint0_int fun fprint1_int {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: int): void = "atspre_fprint_int" overload fprint_int with fprint1_int overload fprint with fprint_int fun print_int (i: int): void = "atspre_print_int" overload print with print_int fun prerr_int (i: int): void = "atspre_prerr_int" overload prerr with prerr_int (* ****** ****** *) symintr fscan_int_exn fun fscan0_int_exn (inp: FILEref, x: &int? >> int): void = "atspre_fscan_int_exn" overload fscan_int_exn with fscan0_int_exn fun fscan1_int_exn {m:file_mode} (pf: file_mode_lte (m, r) | inp: &FILE m, x: &int? >> int): void = "atspre_fscan_int_exn" overload fscan_int_exn with fscan1_int_exn (* ****** ****** *) // // stringization // fun tostrptr_int (i: int):<> strptr1 = "atspre_tostrptr_int" overload tostrptr with tostrptr_int fun tostring_int (i: int):<> string = "atspre_tostrptr_int" overload tostring with tostring_int (* ****** ****** *) // unsigned integers (of unindexed type) (* ****** ****** *) castfn uint_of_int (i: int):<> uint overload uint_of with uint_of_int (* ****** ****** *) fun uint_of_char (c: char):<> uint = "atspre_uint_of_char" overload uint_of with uint_of_char fun uint_of_double (d: double):<> uint = "atspre_uint_of_double" overload uint_of with uint_of_double (* ****** ****** *) // arithmetic functions and comparison functions fun succ_uint (u: uint):<> uint = "atspre_succ_uint" and pred_uint (u: uint):<> uint = "atspre_pred_uint" overload succ with succ_uint overload pred with pred_uint // fun add_uint_uint (u1: uint, u2: uint):<> uint = "atspre_add_uint_uint" and sub_uint_uint (u1: uint, u2: uint):<> uint = "atspre_sub_uint_uint" overload + with add_uint_uint overload - with sub_uint_uint fun mul_uint_uint (u1: uint, u2: uint):<> uint = "atspre_mul_uint_uint" and div_uint_uint (u1: uint, u2: uint):<> uint = "atspre_div_uint_uint" and mod_uint_uint (u1: uint, u2: uint):<> uint = "atspre_mod_uint_uint" overload * with mul_uint_uint overload / with div_uint_uint overload mod with mod_uint_uint fun gcd_uint_uint (u1: uint, u2: uint):<> uint = "atspre_gcd_uint_uint" overload gcd with gcd_uint_uint (* ****** ****** *) fun square_uint (u: uint):<> uint = "atspre_square_uint" overload square with square_uint fun cube_uint (u: uint):<> uint = "atspre_cube_uint" overload cube with cube_uint (* ****** ****** *) fun lt_uint_uint (u1: uint, u2: uint):<> bool = "atspre_lt_uint_uint" and lte_uint_uint (u1: uint, u2: uint):<> bool = "atspre_lte_uint_uint" overload < with lt_uint_uint overload <= with lte_uint_uint fun gt_uint_uint (u1: uint, u2: uint):<> bool = "atspre_gt_uint_uint" and gte_uint_uint (u1: uint, u2: uint):<> bool = "atspre_gte_uint_uint" overload > with gt_uint_uint overload >= with gte_uint_uint fun eq_uint_uint (u1: uint, u2: uint):<> bool = "atspre_eq_uint_uint" and neq_uint_uint (u1: uint, u2: uint):<> bool = "atspre_neq_uint_uint" overload = with eq_uint_uint overload <> with neq_uint_uint overload != with neq_uint_uint (* ****** ****** *) fun compare_uint_uint ( u1: uint, u2: uint ) :<> Sgn = "atspre_compare_uint_uint" overload compare with compare_uint_uint fun max_uint_uint (u1: uint, u2: uint):<> uint = "atspre_max_uint_uint" and min_uint_uint (u1: uint, u2: uint):<> uint = "atspre_min_uint_uint" overload max with max_uint_uint overload min with min_uint_uint (* ****** ****** *) // bit operations fun lnot_uint (u: uint):<> uint = "atspre_lnot_uint" (* bitwise *) overload ~ with lnot_uint fun land_uint_uint (u1: uint, u2: uint):<> uint = "atspre_land_uint_uint" overload land with land_uint_uint fun lor_uint_uint (u1: uint, u2: uint):<> uint = "atspre_lor_uint_uint" overload lor with lor_uint_uint fun lxor_uint_uint (u1: uint, u2: uint):<> uint = "atspre_lxor_uint_uint" overload lxor with lxor_uint_uint (* ****** ****** *) fun lsl_uint_int1 (u: uint, n: Nat):<> uint = "atspre_lsl_uint_int1" overload << with lsl_uint_int1 fun lsl_uint_uint (u: uint, n: uint):<> uint = "mac#atspre_lsl_uint_uint" overload << with lsl_uint_uint fun lsr_uint_int1 (u: uint, n: Nat):<> uint = "atspre_lsr_uint_int1" overload >> with lsr_uint_int1 fun lsr_uint_uint (u: uint, n: uint):<> uint = "mac#atspre_lsr_uint_uint" overload >> with lsr_uint_uint (* ****** ****** *) symintr fprint_uint fun fprint0_uint (out: FILEref, x: uint): void = "atspre_fprint_uint" fun fprint1_uint {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: uint): void = "atspre_fprint_uint" overload fprint_uint with fprint0_uint overload fprint_uint with fprint1_uint overload fprint with fprint_uint (* ****** ****** *) fun print_uint (u: uint): void = "atspre_print_uint" and prerr_uint (u: uint): void = "atspre_prerr_uint" overload print with print_uint overload prerr with prerr_uint (* ****** ****** *) // // stringization // fun tostrptr_uint (u: uint):<> strptr1 = "atspre_tostrptr_uint" overload tostrptr with tostrptr_uint fun tostring_uint (u: uint):<> string = "atspre_tostrptr_uint" overload tostring with tostring_uint (* ****** ****** *) // signed integers (of indexed type) (* ****** ****** *) castfn int1_of_int (i: int):<> [i:int] int i castfn int1_of_uint1 {i:nat} (i: uint i):<> int i overload int1_of with int1_of_int overload int1_of with int1_of_uint1 // fun int1_of_string (s: string):<> [i:int] int i = "atspre_int1_of_string" overload int1_of with int1_of_string // // arithmetic functions and comparison functions // fun iabs {i:int} (i: int i):<> [j:int | abs_r (i, j)] int j = "atspre_iabs" overload abs with iabs fun ineg {i:int} (i: int i):<> int (~i) = "atspre_ineg" overload ~ with ineg // fun isucc {i:int} (i: int i):<> int (i + 1) = "atspre_isucc" and ipred {i:int} (i: int i):<> int (i - 1) = "atspre_ipred" overload succ with isucc overload pred with ipred // fun iadd {i,j:int} (i: int i, j: int j):<> int (i+j) = "atspre_iadd" and isub {i,j:int} (i: int i, j: int j):<> int (i-j) = "atspre_isub" overload + with iadd overload - with isub // fun imul {i,j:int} (i: int i, j: int j):<> int (i*j) // [j] must be a constant! = "atspre_imul" and idiv {i,j:int | j <> 0} (i: int i, j: int j):<> int (i/j) // [j] must be a constant! = "atspre_idiv" overload * with imul overload / with idiv // fun igcd {i,j:int} (i: int i, j: int j):<> [r:int | r >= 0] int r = "atspre_igcd" overload gcd with igcd fun imul1 (i: Int, j: Int):<> Int = "atspre_imul1" and idiv1 {j:int | j <> 0} (i: Int, j: int j):<> Int = "atspre_idiv1" fun igcd1 {i,j:int} (i: int i, j: int j):<> [r:int | r >= 0] int r = "atspre_igcd1" // end of [igcd1] fun imul2 {i,j:int} (i: int i, j: int j) :<> [p:int] (MUL (i, j, p) | int p) = "atspre_imul2" fun igcd2 {i,j:int} (i: int i, j: int j) :<> [r:int] (GCD (i, j, r) | int r) = "atspre_igcd2" // fun nmul (i: Nat, j: Nat):<> Nat = "atspre_nmul" fun ndiv (i: Nat, j: Pos):<> Nat = "atspre_ndiv" // // HX: there is no [ndiv1] // fun ndiv2 {i,j:int | i >= 0; j > 0} (i: int i, j: int j):<> [q:int] (DIV (i, j, q) | int q) = "atspre_ndiv2" // end of [ndiv2] // fun nmod {i,j:int | i >= 0; j > 0} // [j] is a constant! (i: int i, j: int j) :<> [q,r:nat | r < j; i == q*j + r] int r = "atspre_nmod" fun nmod1 {i,j:int | i >= 0; j > 0} (i: int i, j: int j):<> natLt j = "atspre_nmod1" // // HX: MOD is defined in prelude/SATS/arith.sats // fun nmod2 {i,j:int | i >= 0; j > 0} (i: int i, j: int j):<> [r:int] (MOD (i, j, r) | int r) = "atspre_nmod2" (* ****** ****** *) // // HX: it is always inlined // HX: it is not supported by ATS/Geizella // HX: DIVMOD is declard in prelude/SATS/arith.sats // fun{} divmod_int1_int1 {m:nat; n:int | n > 0} ( m: int m, n: int n , r: &int? >> int r ) :<> #[q,r:nat | r < n] (DIVMOD (m, n, q, r) | int q) (* ****** ****** *) fun ilt {i,j:int} (i: int i, j: int j):<> bool (i < j) = "atspre_ilt" and ilte {i,j:int} (i: int i, j: int j):<> bool (i <= j) = "atspre_ilte" overload < with ilt overload <= with ilte fun igt {i,j:int} (i: int i, j: int j):<> bool (i > j) = "atspre_igt" and igte {i,j:int} (i: int i, j: int j):<> bool (i >= j) = "atspre_igte" overload > with igt overload >= with igte fun ieq {i,j:int} (i: int i, j: int j):<> bool (i == j) = "atspre_ieq" and ineq {i,j:int} (i: int i, j: int j):<> bool (i <> j) = "atspre_ineq" overload = with ieq overload <> with ineq overload != with ineq fun icompare {i,j:int} (i: int i, j: int j):<> [k:int | sgn_r (i-j, k)] int k = "atspre_icompare" overload compare with icompare fun imax {i,j:int} (i: int i, j: int j):<> int (max (i,j)) = "atspre_imax" and imin {i,j:int} (i: int i, j: int j):<> int (min (i,j)) = "atspre_imin" overload max with imax overload min with imin fun ipow (base: Int, exponent: Nat):<> Int = "atspre_ipow" overload pow with ipow fun npow (base: Int, exponent: Nat):<> Nat = "atspre_npow" fun ihalf {i:int} (i: int i):<> [q:int | div_r (i, 2, q)] int q = "atspre_ihalf" // end of [ihalf] fun nhalf {n:nat} (n: int n):<> [q:nat | ndiv_r (n, 2, q)] int q = "atspre_nhalf" // end of [nhalf] (* ****** ****** *) // // unsigned integers (of indexed type) // (* ****** ****** *) praxi uint_param_lemma {i:int} (u: uint i): [i >= 0] void (* ****** ****** *) castfn uint1_of_uint (i: uint):<> [i:nat] uint i overload uint1_of with uint1_of_uint castfn uint1_of_int (i: int):<> [i:nat] uint i castfn uint1_of_int1 {i:nat} (i: int i):<> uint i overload uint1_of with uint1_of_int overload uint1_of with uint1_of_int1 (* ****** ****** *) // arithmetic functions and comparison functions fun usucc {i:int} (i: uint i):<> uint (i + 1) = "atspre_usucc" and upred {i:pos} (i: uint i):<> uint (i - 1) = "atspre_upred" overload succ with usucc overload pred with upred fun uadd {i,j:int} (i: uint i, j: uint j):<> uint (i+j) = "atspre_uadd" and usub {i,j:int | i >= j} (i: uint i, j: uint j):<> uint (i-j) = "atspre_usub" overload + with uadd overload - with usub fun umul {i,j:int} (i: uint i, j: uint j):<> uint (i*j) = "atspre_umul" and udiv {i,j:int | j > 0} (i: uint i, j: uint j):<> uint (i/j) = "atspre_udiv" overload * with umul overload / with udiv fun umod {i,j:int | j > 0} // [j] is a constant! (i: uint i, j: uint j) :<> [q,r:nat | r < j; i == q*j + r] uint r = "atspre_umod" // // HX: there is no [umod1] // fun umod2 {i,j:int | j > 0} (i: uint i, j: uint j):<> [r:int] (MOD (i, j, r) | uint r) = "atspre_umod2" overload mod with umod fun uimod {i,j:int | j > 0} (i: uint i, j: int j):<> [q,r:nat | r < j; i == q*j + r] int r = "atspre_uimod" // // HX: there is no [uimod1] // fun uimod2 {i,j:int | j > 0} (i: uint i, j: int j):<> [r:int] (MOD (i, j, r) | int r) = "atspre_uimod2" overload mod with uimod fun ult {i,j:int} (i: uint i, j: uint j):<> bool (i < j) = "atspre_ult" and ulte {i,j:int} (i: uint i, j: uint j):<> bool (i <= j) = "atspre_ulte" overload < with ult overload <= with ulte fun ugt {i,j:int} (i: uint i, j: uint j):<> bool (i > j) = "atspre_ugt" and ugte {i,j:int} (i: uint i, j: uint j):<> bool (i >= j) = "atspre_ugte" overload > with ugt overload >= with ugte fun ueq {i,j:int} (i: uint i, j: uint j):<> bool (i == j) = "atspre_ueq" and uneq {i,j:int} (i: uint i, j: uint j):<> bool (i <> j) = "atspre_uneq" overload = with ueq overload <> with uneq overload != with uneq fun umax {i,j:int} (i: uint i, j: uint j):<> [k:int | max_r (i, j, k)] uint k = "atspre_umax" and umin {i,j:int} (i: uint i, j: uint j):<> [k:int | min_r (i, j, k)] uint k = "atspre_umin" overload max with umax overload min with umin fun uhalf {i:int} (i: uint i):<> uint (i/2) = "atspre_uhalf" (* ****** ****** *) // // signed long integers (unindexed) // (* ****** ****** *) stadef lint = lint_int_t0ype // indexed typedef lint = int_long_t0ype // unindexed castfn lint1_of_lint (i: lint):<> [i:int] lint i fun lint_of_int (i: int):<> lint = "atspre_lint_of_int" overload lint_of with lint_of_int fun int_of_lint (li: lint):<> int = "atspre_int_of_lint" overload int_of with int_of_lint fun lint_of_uint (u: uint):<> lint = "atspre_lint_of_uint" overload lint_of with lint_of_uint fun uint_of_lint (li: lint):<> uint = "atspre_uint_of_lint" overload uint_of with uint_of_lint // // HX: this function is based on [atol] in [stdlib.h] // fun lint_of_string (s: string):<> lint = "atspre_lint_of_string" overload lint_of with lint_of_string (* ****** ****** *) // arithmetic functions and comparison functions fun abs_lint (li: lint):<> lint = "atspre_abs_lint" overload abs with abs_lint fun neg_lint (li: lint):<> lint = "atspre_neg_lint" overload ~ with neg_lint fun succ_lint (li: lint):<> lint = "atspre_succ_lint" and pred_lint (li: lint):<> lint = "atspre_pred_lint" overload succ with succ_lint overload pred with pred_lint fun add_lint_lint (i: lint, j: lint):<> lint = "atspre_add_lint_lint" and sub_lint_lint (i: lint, j: lint):<> lint = "atspre_sub_lint_lint" overload + with add_lint_lint overload - with sub_lint_lint fun mul_lint_lint (i: lint, j: lint):<> lint = "atspre_mul_lint_lint" and div_lint_lint (i: lint, j: lint):<> lint = "atspre_div_lint_lint" overload * with mul_lint_lint overload / with div_lint_lint fun mod_lint_lint (i: lint, j: lint):<> lint = "atspre_mod_lint_lint" overload mod with mod_lint_lint fun lt_lint_lint (i: lint, j: lint):<> bool = "atspre_lt_lint_lint" and lte_lint_lint (i: lint, j: lint):<> bool = "atspre_lte_lint_lint" overload < with lt_lint_lint overload <= with lte_lint_lint fun gt_lint_lint (i: lint, j: lint):<> bool = "atspre_gt_lint_lint" and gte_lint_lint (i: lint, j: lint):<> bool = "atspre_gte_lint_lint" overload > with gt_lint_lint overload >= with gte_lint_lint fun eq_lint_lint (i: lint, j: lint):<> bool = "atspre_eq_lint_lint" and neq_lint_lint (i: lint, j: lint):<> bool = "atspre_neq_lint_lint" overload = with eq_lint_lint overload <> with neq_lint_lint overload != with neq_lint_lint fun compare_lint_lint (i1: lint, i2: lint):<> Sgn = "atspre_compare_lint_lint" overload compare with compare_lint_lint fun max_lint_lint (i: lint, j: lint):<> lint = "atspre_max_lint_lint" and min_lint_lint (i: lint, j: lint):<> lint = "atspre_min_lint_lint" overload max with max_lint_lint overload min with min_lint_lint (* ****** ****** *) symintr fprint_lint fun fprint0_lint (out: FILEref, x: lint): void = "atspre_fprint_lint" overload fprint_lint with fprint0_lint fun fprint1_lint {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: lint): void = "atspre_fprint_lint" overload fprint_lint with fprint1_lint overload fprint with fprint_lint fun print_lint (li: lint): void = "atspre_print_lint" overload print with print_lint fun prerr_lint (li: lint): void = "atspre_prerr_lint" overload prerr with prerr_lint (* ****** ****** *) // // stringization // fun tostrptr_lint (i: lint):<> strptr1 = "atspre_tostrptr_lint" overload tostrptr with tostrptr_lint fun tostring_lint (i: lint):<> string = "atspre_tostrptr_lint" overload tostring with tostring_lint (* ****** ****** *) // // signed long integers (indexed) // (* ****** ****** *) fun lt_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i < j) = "atspre_lt_lint_lint" and lte_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i <= j) = "atspre_lte_lint_lint" overload < with lt_lint1_lint1 overload <= with lte_lint1_lint1 fun gt_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i > j) = "atspre_gt_lint_lint" and gte_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i >= j) = "atspre_gte_lint_lint" overload > with gt_lint1_lint1 overload >= with gte_lint1_lint1 fun eq_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i == j) = "atspre_lt_lint_lint" and neq_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> bool (i <> j) = "atspre_lte_lint_lint" overload = with eq_lint1_lint1 overload <> with neq_lint1_lint1 overload != with neq_lint1_lint1 fun compare_lint1_lint1 {i,j:int} (i: lint i, j: lint j):<> [k:int | sgn_r (i-j, k)] int k = "atspre_compare_lint_lint" overload compare with compare_lint1_lint1 (* ****** ****** *) // // unsigned long integers (unindexed) // (* ****** ****** *) // stadef ulint = ulint_int_t0ype // indexed typedef ulint = uint_long_t0ype // unindexed // castfn ulint1_of_ulint (x: ulint):<> [i:nat] ulint i castfn ulint1_of_lint1 {i:nat} (x: lint i):<> ulint i // castfn lint_of_ulint (x: ulint):<> lint overload lint_of with lint_of_ulint // castfn ulint_of_lint (x: lint):<> ulint overload ulint_of with ulint_of_lint // fun ulint_of_int (i: int):<> ulint = "atspre_ulint_of_int" overload ulint_of with ulint_of_int // fun ulint_of_uint (u: uint):<> ulint = "atspre_ulint_of_uint" overload ulint_of with ulint_of_uint // fun uint_of_ulint (ul: ulint):<> uint = "atspre_uint_of_ulint" overload uint_of with uint_of_ulint // (* ****** ****** *) // arithmetic functions and comparison functions fun succ_ulint (lu: ulint):<> ulint = "atspre_succ_ulint" and pred_ulint (lu: ulint):<> ulint = "atspre_pred_ulint" overload succ with succ_ulint overload pred with pred_ulint fun add_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_add_ulint_ulint" and sub_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_sub_ulint_ulint" overload + with add_ulint_ulint overload - with sub_ulint_ulint fun mul_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_mul_ulint_ulint" and div_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_div_ulint_ulint" and mod_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_mod_ulint_ulint" overload * with mul_ulint_ulint overload / with div_ulint_ulint overload mod with mod_ulint_ulint fun lt_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_lt_ulint_ulint" and lte_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_lte_ulint_ulint" overload < with lt_ulint_ulint overload <= with lte_ulint_ulint fun gt_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_gt_ulint_ulint" and gte_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_gte_ulint_ulint" overload > with gt_ulint_ulint overload >= with gte_ulint_ulint fun eq_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_eq_ulint_ulint" and neq_ulint_ulint (i: ulint, j: ulint):<> bool = "atspre_neq_ulint_ulint" overload = with eq_ulint_ulint overload <> with neq_ulint_ulint overload != with neq_ulint_ulint fun compare_ulint_ulint (i1: ulint, i2: ulint):<> Sgn = "atspre_compare_ulint_ulint" overload compare with compare_ulint_ulint fun max_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_max_ulint_ulint" and min_ulint_ulint (i: ulint, j: ulint):<> ulint = "atspre_min_ulint_ulint" overload max with max_ulint_ulint overload min with min_ulint_ulint (* ****** ****** *) // bit operations fun lnot_ulint (u: ulint):<> ulint = "atspre_lnot_ulint" (* bitwise *) overload ~ with lnot_ulint fun land_ulint_ulint (u1: ulint, u2: ulint):<> ulint = "atspre_land_ulint_ulint" fun lor_ulint_ulint (u1: ulint, u2: ulint):<> ulint = "atspre_lor_ulint_ulint" fun lxor_ulint_ulint (u1: ulint, u2: ulint):<> ulint = "atspre_lxor_ulint_ulint" overload land with land_ulint_ulint overload lor with lor_ulint_ulint overload lxor with lxor_ulint_ulint fun lsl_ulint_int1 (u: ulint, n: Nat):<> ulint = "atspre_lsl_ulint_int1" and lsr_ulint_int1 (u: ulint, n: Nat):<> ulint = "atspre_lsr_ulint_int1" overload << with lsl_ulint_int1 overload >> with lsr_ulint_int1 (* ****** ****** *) symintr fprint_ulint fun fprint0_ulint (out: FILEref, x: ulint): void = "atspre_fprint_ulint" fun fprint1_ulint {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: ulint): void = "atspre_fprint_ulint" overload fprint_ulint with fprint0_ulint overload fprint_ulint with fprint1_ulint overload fprint with fprint_ulint (* ****** ****** *) fun print_ulint (lu: ulint): void = "atspre_print_ulint" overload print with print_ulint fun prerr_ulint (lu: ulint): void = "atspre_prerr_ulint" overload prerr with prerr_ulint (* ****** ****** *) // // stringization // fun tostrptr_ulint (i: ulint):<> strptr1 = "atspre_tostrptr_ulint" overload tostrptr with tostrptr_ulint fun tostring_ulint (i: ulint):<> string = "atspre_tostrptr_ulint" overload tostring with tostring_ulint (* ****** ****** *) // signed long long integers (* ****** ****** *) stadef llint = llint_int_t0ype // indexed typedef llint = int_long_long_t0ype // unindexed castfn llint1_of_llint (i: llint):<> [i:int] llint i fun llint_of_int (i: int):<> llint = "atspre_llint_of_int" overload llint_of with llint_of_int fun int_of_llint (lli: llint):<> int = "atspre_int_of_llint" overload int_of with int_of_llint fun llint_of_double (d: double):<> llint = "atspre_llint_of_double" overload llint_of with llint_of_double // // HX: This function is based on [atoll] in [stdlib.h] // fun llint_of_string (s: string):<> llint = "atspre_llint_of_string" overload llint_of with llint_of_string // arithmetic functions and comparison functions fun abs_llint (lli: llint):<> llint = "atspre_abs_llint" overload abs with abs_llint fun neg_llint (lli: llint):<> llint = "atspre_neg_llint" overload ~ with neg_llint fun succ_llint (lli: llint):<> llint = "atspre_succ_llint" and pred_llint (lli: llint):<> llint = "atspre_pred_llint" overload succ with succ_llint overload pred with pred_llint fun add_llint_llint (i: llint, j: llint):<> llint = "atspre_add_llint_llint" and sub_llint_llint (i: llint, j: llint):<> llint = "atspre_sub_llint_llint" overload + with add_llint_llint overload - with sub_llint_llint fun mul_llint_llint (i: llint, j: llint):<> llint = "atspre_mul_llint_llint" and div_llint_llint (i: llint, j: llint):<> llint = "atspre_div_llint_llint" and mod_llint_llint (i: llint, j: llint):<> llint = "atspre_mod_llint_llint" overload * with mul_llint_llint overload / with div_llint_llint overload mod with mod_llint_llint fun lt_llint_llint (i: llint, j: llint):<> bool = "atspre_lt_llint_llint" and lte_llint_llint (i: llint, j: llint):<> bool = "atspre_lte_llint_llint" overload < with lt_llint_llint overload <= with lte_llint_llint fun gt_llint_llint (i: llint, j: llint):<> bool = "atspre_gt_llint_llint" and gte_llint_llint (i: llint, j: llint):<> bool = "atspre_gte_llint_llint" overload > with gt_llint_llint overload >= with gte_llint_llint fun eq_llint_llint (i: llint, j: llint):<> bool = "atspre_eq_llint_llint" and neq_llint_llint (i: llint, j: llint):<> bool = "atspre_neq_llint_llint" overload = with eq_llint_llint overload <> with neq_llint_llint overload != with neq_llint_llint fun compare_llint_llint (i1: llint, i2: llint):<> Sgn = "atspre_compare_llint_llint" overload compare with compare_llint_llint fun max_llint_llint (i: llint, j: llint):<> llint = "atspre_max_llint_llint" and min_llint_llint (i: llint, j: llint):<> llint = "atspre_min_llint_llint" overload max with max_llint_llint overload min with min_llint_llint (* ****** ****** *) symintr fprint_llint fun fprint0_llint (out: FILEref, x: llint): void = "atspre_fprint_llint" fun fprint1_llint {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: llint): void = "atspre_fprint_llint" overload fprint_llint with fprint0_llint overload fprint_llint with fprint1_llint overload fprint with fprint_llint (* ****** ****** *) fun print_llint (lli: llint): void = "atspre_print_llint" overload print with print_llint fun prerr_llint (lli: llint): void = "atspre_prerr_llint" overload prerr with prerr_llint (* ****** ****** *) // // stringization // fun tostrptr_llint (i: llint):<> strptr1 = "atspre_tostrptr_llint" overload tostrptr with tostrptr_llint fun tostring_llint (i: llint):<> string = "atspre_tostrptr_llint" overload tostring with tostring_llint (* ****** ****** *) // unsigned long long integers (* ****** ****** *) stadef ullint = ullint_int_t0ype // indexed typedef ullint = uint_long_long_t0ype // unindexed // castfn ullint_of_llint (i: llint):<> ullint castfn llint_of_ullint (u: ullint):<> llint // fun ullint_of_int (i: int):<> ullint = "atspre_ullint_of_int" overload ullint_of with ullint_of_int fun ullint_of_uint (u: uint):<> ullint = "atspre_ullint_of_uint" overload ullint_of with ullint_of_uint fun ullint_of_double (d: double):<> ullint = "atspre_ullint_of_double" overload ullint_of with ullint_of_double (* ****** ****** *) // arithmetic functions and comparison functions fun succ_ullint (llu: ullint):<> ullint = "atspre_succ_ullint" and pred_ullint (llu: ullint):<> ullint = "atspre_pred_ullint" overload succ with succ_ullint overload pred with pred_ullint fun add_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_add_ullint_ullint" and sub_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_sub_ullint_ullint" overload + with add_ullint_ullint overload - with sub_ullint_ullint fun mul_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_mul_ullint_ullint" and div_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_div_ullint_ullint" and mod_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_mod_ullint_ullint" overload * with mul_ullint_ullint overload / with div_ullint_ullint overload mod with mod_ullint_ullint fun lt_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_lt_ullint_ullint" and lte_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_lte_ullint_ullint" overload < with lt_ullint_ullint overload <= with lte_ullint_ullint fun gt_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_gt_ullint_ullint" and gte_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_gte_ullint_ullint" overload > with gt_ullint_ullint overload >= with gte_ullint_ullint fun eq_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_eq_ullint_ullint" and neq_ullint_ullint (i: ullint, j: ullint):<> bool = "atspre_neq_ullint_ullint" overload = with eq_ullint_ullint overload <> with neq_ullint_ullint overload != with neq_ullint_ullint // // compare, max and min // fun compare_ullint_ullint (i1: ullint, i2: ullint):<> Sgn = "atspre_compare_ullint_ullint" overload compare with compare_ullint_ullint fun max_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_max_ullint_ullint" and min_ullint_ullint (i: ullint, j: ullint):<> ullint = "atspre_min_ullint_ullint" overload max with max_ullint_ullint overload min with min_ullint_ullint (* ****** ****** *) symintr fprint_ullint fun fprint0_ullint (out: FILEref, x: ullint): void = "atspre_fprint_ullint" fun fprint1_ullint {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: ullint): void = "atspre_fprint_ullint" overload fprint_ullint with fprint0_ullint overload fprint_ullint with fprint1_ullint overload fprint with fprint_ullint (* ****** ****** *) fun print_ullint (llu: ullint): void = "atspre_print_ullint" overload print with print_ullint fun prerr_ullint (llu: ullint): void = "atspre_prerr_ullint" overload prerr with prerr_ullint (* ****** ****** *) // // stringization // fun tostrptr_ullint (i: ullint):<> strptr1 = "atspre_tostrptr_ullint" overload tostrptr with tostrptr_ullint fun tostring_ullint (i: ullint):<> string = "atspre_tostrptr_ullint" overload tostring with tostring_ullint (* ****** ****** *) typedef sint = int_short_t0ype typedef usint = uint_short_t0ype (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [integer.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [integer.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/memalign.sats0000664000175000017500000001053712223166161020701 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [memalign.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) #define ATS_STALOADFLAG 0 // HX: there no need for staloading (* ****** ****** *) (* // // HX-2011-09-20: do we need this? // stadef align_int_int_bool (sz:int, n:int) = n >= 0 stacst alignof_viewt0ype_int : viewt@ype -> int stadef alignof = alignof_viewt0ype_int praxi lemma_alignof_sizeof {a:viewt@ype} (): [n:pos] MUL (n, alignof(a), sizeof(a)) // end of [lemma_alignof_sizeof] *) (* ****** ****** *) // // HX: [a] is aligned at [l] // this needs support from the underlying C compiler // absprop ISALIGNED (a:t@ype+, l:addr) // (* ****** ****** *) praxi atview_isaligned {a:viewt@ype} {l:addr} (pf: !a @ l): ISALIGNED (a?, l) // end of [atview_isaligned] (* ****** ****** *) praxi isaligned_sizeof {a:t@ype} {i:int} // HX: [i] is a constant {l:addr} (pf: ISALIGNED (a, l)): ISALIGNED (a, l+i*sizeof(a)) // end of [isaligned_sizeof] (* ****** ****** *) (* ** MB: C99 (section 7.20.3.3) *) praxi freebyte_gc_isaligned {a:viewt@ype} {n:int} {l:addr} ( pf: !freebyte_gc_v (n, l) ) : ISALIGNED (a?, l) // end of [freebyte_gc_isaligned] praxi freebyte_ngc_isaligned {a:viewt@ype} {n:int} {l:addr} ( pf: !freebyte_ngc_v (n, l) ) : ISALIGNED (a?, l) // end of [freebyte_ngc_isaligned] (* ****** ****** *) (* ** MB: C99 (section 6.2.5-6) *) praxi memalign_signed_unsigned_int {l:addr} (pf: ISALIGNED (int?, l)): ISALIGNED (uint, l) praxi memalign_signed_unsigned_int8 {l:addr} (pf: ISALIGNED (int8?, l)): ISALIGNED (uint8, l) praxi memalign_signed_unsigned_int16 {l:addr} (pf: ISALIGNED (int16?, l)): ISALIGNED (uint16, l) praxi memalign_signed_unsigned_int32 {l:addr} (pf: ISALIGNED (int32?, l)): ISALIGNED (uint32, l) praxi memalign_signed_unsigned_int64 {l:addr} (pf: ISALIGNED (int64?, l)): ISALIGNED (uint64, l) (* ****** ****** *) praxi memalign_signed_unsigned_uint {l:addr} (pf: ISALIGNED (uint?, l)): ISALIGNED (int, l) praxi memalign_signed_unsigned_uint8 {l:addr} (pf: ISALIGNED (uint8?, l)): ISALIGNED (int8, l) praxi memalign_signed_unsigned_uint16 {l:addr} (pf: ISALIGNED (uint16?, l)): ISALIGNED (int16, l) praxi memalign_signed_unsigned_uint32 {l:addr} (pf: ISALIGNED (uint32?, l)): ISALIGNED (int32, l) praxi memalign_signed_unsigned_uint64 {l:addr} (pf: ISALIGNED (uint64?, l)): ISALIGNED (int64, l) (* ****** ****** *) praxi ptr_of_b0ytes_v {a:viewt@ype} {l:addr} (pf1: ISALIGNED (a?, l), pf2: b0ytes (sizeof a) @ l): a? @ l // end of [ptr_of_b0ytes_v] (* ****** ****** *) prfun ptr_view_conversion {a1,a2:viewt@ype | sizeof a1 == sizeof a2} {l:addr} (pf1: ISALIGNED (a2?, l), pf2: !a1? @ l >> a2? @ l): void // end of [ptr_view_conversion] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [memalign.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [memalign.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/lazy.sats0000664000175000017500000000641212223166161020064 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [lazy.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) exception StreamSubscriptException of () (* ****** ****** *) // // HX-2010-07-31: please note that !laz is defined to be (1,~ref) // (* ****** ****** *) fun{a:t@ype} stream_filter_fun (xs: stream a, p: a - bool): stream a // end of [stream_filter_fun] fun{a:t@ype} stream_filter_cloref (xs: stream a, p: a - bool): stream a // end of [stream_filter_cloref] (* ****** ****** *) fun{a:t@ype}{b:t@ype} stream_map_fun (xs: stream a, f: a - b): stream b // end of [stream_map_fun] fun{a:t@ype}{b:t@ype} stream_map_cloref (xs: stream a, f: a - b): stream b // end of [stream_map_cloref] (* ****** ****** *) fun{a1,a2:t@ype}{b:t@ype} stream_map2_fun (xs1: stream a1, xs2: stream a2, f: (a1, a2) - b) : stream b // end of [stream_map2_fun] fun{a1,a2:t@ype}{b:t@ype} stream_map2_cloref (xs1: stream a1, xs2: stream a2, f: (a1, a2) - b) : stream b // end of [stream_map2_cloref] (* ****** ****** *) fun{a:t@ype} stream_ordmerge_fun (xs1: stream a, xs2: stream a, lte: (a, a) - bool) : stream a // end of [stream_ordmerge_fun] fun{a:t@ype} stream_ordmerge_cloref (xs1: stream a, xs2: stream a, lte: (a, a) - bool) : stream a // end of [stream_ordmerge_cloref] (* ****** ****** *) fun{a:t@ype} stream_nth (xs: stream a, i: Nat): a (* ****** ****** *) fun{a:t@ype} stream_take {n:nat} (xs: stream a, n: int n): [k:nat | k <= n] list_vt (a, k) // end of [stream_take] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [lazy.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [lazy.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/string.sats0000664000175000017500000005632712223166161020425 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: some string operations // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [string.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) stadef NUL = '\000' (* ****** ****** *) typedef bytes (n:int) = @[byte][n] typedef b0ytes (n:int) = @[byte?][n] typedef chars (n:int) = @[char][n] typedef c0hars (n:int) = @[char?][n] typedef c1har = [c:char | c <> NUL] char c typedef c1hars (n:int) = @[c1har][n] (* ****** ****** *) viewdef strbuf_v (m: int, n: int, l:addr) = strbuf (m, n) @ l viewdef strbuf_v (l:addr) = [m,n:nat] strbuf (m, n) @ l (* ****** ****** *) prfun strbuf_vsubr_lemma0 // implemneted in [string.dats] {m,n:nat} {l:addr} (): vsubr_p (strbuf_v l, strbuf_v (m, n, l)) // end of [strbuf_vsubr_lemma0] (* ****** ****** *) viewtypedef strbufptr_gc ( m:int, n:int, l:addr ) = @( freebyte_gc_v (m, l), strbuf_v (m, n, l) | ptr l ) // end of [strbufptr_gc] viewdef strbufptr_gc (n:int) = [m:nat;l:addr] strbufptr_gc (m, n, l) viewdef Strbufptr_gc = [m,n:nat;l:addr] strbufptr_gc (m, n, l) (* ****** ****** *) praxi bytes_v_of_b0ytes_v {bsz:int} {l:addr} (pf: b0ytes (bsz) @ l): bytes (bsz) @ l praxi char_v_of_b0yte_v {l:addr} (pf: byte? @ l): char @ l praxi chars_v_of_b0ytes_v {bsz:int} {l:addr} (pf: b0ytes (bsz) @ l): chars (bsz) @ l (* ****** ****** *) praxi bytes_v_of_chars_v {bsz:int} {l:addr} (pf: chars (bsz) @ l): bytes (bsz) @ l praxi bytes_v_of_strbuf_v {bsz:int} {l:addr} (pf: strbuf (bsz) @ l): bytes (bsz) @ l (* ****** ****** *) praxi strbuf_v_null {n:int} {l:addr} // [n] must be a nat (pf1: char NUL @ l, pf2: b0ytes (n) @ l + sizeof(char)) : strbuf_v (n+1, 0, l) // end of [strbuf_v] praxi strbuf_v_cons {m,n:int} {l:addr} // [m] and [n] must be nats (pf1: c1har @ l, pf2: strbuf_v (m, n, l + sizeof(char))) : strbuf_v (m+1, n+1, l) // end of [strbuf_v_cons] dataview strbufopt_v (int, int, addr, char) = | {m:nat} {l:addr} strbufopt_v_none (m, ~1, l, NUL) of b0ytes m @ l | {m,n:nat} {l:addr} {c:char | c <> NUL} strbufopt_v_some (m, n, l, c) of strbuf_v (m, n, l) // end of [strbufopt_v] praxi strbuf_v_uncons {m,n:int} {l:addr} (pf: strbuf_v (m, n, l)) : [c:char] @( char c @ l, strbufopt_v (m-1, n-1, l + sizeof(char), c) ) // end of [strbuf_v_uncons] (* ****** ****** *) prfun strbuf_v_split {m,n:int} {i:nat | i <= n} {l:addr} {ofs:int} ( pf_mul: MUL (i, sizeof char, ofs), pf_str: strbuf_v (m, n, l) ) : (c1hars i @ l, strbuf_v (m-i, n-i, l+ofs)) // end of [strbuf_v_split] prfun strbuf_v_unsplit {n1:nat} {m2,n2:nat} {l:addr} {ofs:int} ( pf_mul: MUL (n1, sizeof char, ofs) , pf_buf: c1hars n1 @ l, pf_str: strbuf_v (m2, n2, l+ofs) ) : strbuf_v (n1+m2, n1+n2, l) // end of [strbuf_v_unsplit] (* ****** ****** *) fun bytes_strbuf_trans {m,n:nat | n < m} {l:addr} ( pf: !b0ytes m @ l >> strbuf (m, n1) @ l | p: ptr l, n: size_t n ) :<> #[n1: nat | n1 <= n] void = "atspre_bytes_strbuf_trans" // end of [bytes_strbuf_trans] (* ****** ****** *) symintr fprint_strbuf fun fprint0_strbuf {m,n:int} (out: FILEref, buf: &strbuf (m, n)): void = "atspre_fprint_string" overload fprint_strbuf with fprint0_strbuf fun print_strbuf {m,n:int} (buf: &strbuf (m, n)): void // overload print with print_strbuf fun prerr_strbuf {m,n:int} (buf: &strbuf (m, n)): void // overload print with prerr_strbuf (* ****** ****** *) // // val string_empty : string 0 // this is not really necessary // (* ****** ****** *) // // HX: casting functions // castfn string1_of_string (str: string):<> [n:nat] string n // end of [string1_of_string] castfn string1_of_strbuf {n:nat} (bufptr: strbufptr_gc n):<> string n // end of [string1_of_strbuf] castfn strbuf_of_string1 {n:nat} (str: string n) :<> [m:int;l:addr | m > n] (vbox (strbuf (m, n) @ l) | ptr l) // end of [strbuf_of_string1] (* ****** ****** *) fun strbufptr_free (p_buf: Strbufptr_gc):<> void = "atspre_strbufptr_free" // end of [strbufptr_free] (* ****** ****** *) fun lt_string_string (s1: string, s2: string):<> bool = "atspre_lt_string_string" overload < with lt_string_string fun lt_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_lt_string_string" // end of [lt_string_string__main] (* ****** ****** *) fun lte_string_string (s1: string, s2: string):<> bool = "atspre_lte_string_string" overload <= with lte_string_string fun lte_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_lte_string_string" (* ****** ****** *) fun gt_string_string (s1: string, s2: string):<> bool = "atspre_gt_string_string" overload > with gt_string_string fun gt_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_gt_string_string" (* ****** ****** *) fun gte_string_string (s1: string, s2: string):<> bool = "atspre_gte_string_string" overload >= with gte_string_string fun gte_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_gte_string_string" (* ****** ****** *) fun eq_string_string (s1: string, s2: string):<> bool = "atspre_eq_string_string" overload = with eq_string_string fun eq_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_eq_string_string" (* ****** ****** *) fun neq_string_string (s1: string, s2: string):<> bool = "atspre_neq_string_string" overload <> with neq_string_string overload != with neq_string_string fun neq_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> bool = "atspre_neq_string_string" (* ****** ****** *) fun compare_string_string (s1: string, s2: string):<> Sgn = "atspre_compare_string_string" overload compare with compare_string_string fun compare_string_string__main {v:view} {l1,l2:addr} ( pf: !v, pf1: vsubr_p (strbuf_v l1, v), pf2: vsubr_p (strbuf_v l2, v) | p1: ptr l1, p2: ptr l2 ) :<> Sgn = "atspre_compare_string_string" (* ****** ****** *) symintr fprint_string fun fprint0_string ( out: FILEref, x: string ) : void = "atspre_fprint_string" overload fprint_string with fprint0_string fun fprint1_string {m:file_mode} ( pf: file_mode_lte (m, w) | out: &FILE m, x: string ) : void = "atspre_fprint_string" overload fprint_string with fprint1_string overload fprint with fprint_string fun fprint1_string__main {v:view} {l:addr} ( pf: !v, fpf: vsubr_p (strbuf_v l, v) | out: FILEref, p: ptr l ) : void = "atspre_fprint_string" // end of [fprint1_string__main] fun print_string (b: string): void = "atspre_print_string" and prerr_string (b: string): void = "atspre_prerr_string" overload print with print_string overload prerr with prerr_string (* ****** ****** *) fun strbuf_get_char_at {m,n:int} {i:nat | i < n} ( sbf: &strbuf (m, n), i: size_t i ) :<> c1har = "atspre_string_get_char_at" overload [] with strbuf_get_char_at fun string_get_char_at {n:int} {i:nat | i < n} ( str: string n, i: size_t i ) :<> c1har = "atspre_string_get_char_at" overload [] with string_get_char_at // // HX: // these functions are present mostly for convenience as a programmer // ofter uses values of the type int as array indices: // fun strbuf_get_char_at__intsz {m,n:int} {i:nat | i < n} (sbf: &strbuf (m, n), i: int i):<> c1har = "atspre_string_get_char_at__intsz" overload [] with strbuf_get_char_at__intsz fun string_get_char_at__intsz {n:int} {i:nat | i < n} (str: string n, i: int i):<> c1har // without effect = "atspre_string_get_char_at__intsz" overload [] with string_get_char_at__intsz (* ****** ****** *) fun strbuf_set_char_at {m,n:int} {i:nat | i < n} ( sbf: &strbuf (m, n), i: size_t i, c: c1har ) :<> void = "atspre_strbuf_set_char_at" overload [] with strbuf_set_char_at fun string_set_char_at {n:int} {i:nat | i < n} ( str: string n, i: size_t i, c: c1har ) : void // with effect! = "atspre_strbuf_set_char_at" overload [] with string_set_char_at (* ****** ****** *) // // HX: these functions are present mostly for convenience as a // programmer ofter uses values of the type int as array indices: // fun strbuf_set_char_at__intsz {m,n:int} {i:nat | i < n} ( sbf: &strbuf (m, n), i: int i, c: c1har ) :<> void = "atspre_strbuf_set_char_at__intsz" overload [] with strbuf_set_char_at__intsz fun string_set_char_at__intsz {n:int} {i:nat | i < n} ( str: string n, i: int i, c: c1har ) : void // with effect! = "atspre_strbuf_set_char_at__intsz" overload [] with string_set_char_at__intsz (* ****** ****** *) fun strbuf_test_char_at {m,n:int} {i:nat | i <= n} ( sbf: &strbuf (m, n), i: size_t i ) :<> [ c:char | (c <> NUL && i < n) || (c == NUL && i >= n) ] char c = "atspre_string_test_char_at" // end of [strbuf_test_char_at] fun string_test_char_at {n:int} {i:nat | i <= n} ( str: string n, i: size_t i ) :<> [ c:char | (c <> NUL && i < n) || (c == NUL && i >= n) ] char c = "atspre_string_test_char_at" // end of [string_test_char_at] (* ****** ****** *) // // HX: these functions are present mostly for convenience // values of the type [int] are often used as array indices: // fun strbuf_test_char_at__intsz {m,n:int} {i:nat | i <= n} ( sbf: &strbuf (m, n), i: size_t i ) :<> [ c:char | (c <> NUL && i < n) || (c == NUL && i >= n) ] char c = "atspre_string_test_char_at__intsz" // end of [strbuf_test_char_at__intsz] fun string_test_char_at__intsz {n:int} {i:nat | i <= n} ( str: string n, i: size_t i ) :<> [ c:char | (c <> NUL && i < n) || (c == NUL && i >= n) ] char c = "atspre_string_test_char_at__intsz" // end of [string_test_char_at__intsz] (* ****** ****** *) fun strbuf_initialize_substring {bsz:int} {n:int} {st,ln:nat | st+ln <= n; ln < bsz} {l:addr} ( pf: !b0ytes bsz @ l >> strbuf (bsz, ln) @ l | p: ptr l, str: string n, st: size_t st, ln: size_t ln ) : void = "atspre_strbuf_initialize_substring" (* ****** ****** *) fun string_make_char {n:nat} ( n: size_t n, c: char ) :<> strbufptr_gc n = "atspre_string_make_char" // end of [fun] (* ****** ****** *) fun string_make_list_int {n:nat} ( cs: list (char, n), n: int n ) :<> strbufptr_gc n = "atspre_string_make_list_int" // end of [fun] (* ****** ****** *) fun string_make_list_rev_int {n:nat} ( cs: list (char, n), n: int n ) :<> strbufptr_gc n = "atspre_string_make_list_rev_int" // end of [fun] (* ****** ****** *) fun string_make_array0 (A: array0 (char)): Strptr1 (* ****** ****** *) // // HX: unsafe but convenient ... // fun string_takeout_bufptr {n:int} {st:nat} {ln:nat | st+ln <= n} (x: string n, st: size_t st) : [l:addr] ( bytes(ln) @ l, bytes(ln) @ l - void | ptr l ) = "mac#atspre_padd_size" // end of [fun] fun string_make_substring {n:int} {st,ln:nat | st + ln <= n} ( str: string n, st: size_t st, ln: size_t ln ) :<> strbufptr_gc ln = "atspre_string_make_substring" // end of [fun] fun string_make_substring__main {v:view} {m,n:int} {st,ln:nat | st+ln <= n} {l:addr} ( pf: !v , pf_con: vsubr_p (strbuf_v (m, n, l), v) | p: ptr l, st: size_t st, ln: size_t ln ) :<> strbufptr_gc ln = "atspre_string_make_substring" // end of [fun] (* ****** ****** *) fun string0_copy (str: string): string = "atspre_string_copy" fun string1_copy {n:nat} (str: string (n)): strbufptr_gc (n) = "atspre_string_copy" (* ****** ****** *) fun string0_append (s1: string, s2: string):<> string // persistent = "atspre_string_append" overload + with string0_append fun string1_append {i,j:nat} (s1: string i, s2: string j):<> strbufptr_gc (i+j) // linear = "atspre_string_append" overload + with string1_append fun string1_append__main {v:view} {m1,i:nat} {m2,j:nat} {l1,l2:addr} ( pf: !v , pf1: vsubr_p (strbuf_v (m1, i, l1), v), pf2: vsubr_p (strbuf_v (m2, j, l2), v) | p1: ptr l1, p2: ptr l2 ) :<> strbufptr_gc (i+j) = "atspre_string_append" (* ****** ****** *) fun string_compare ( s1: string, s2: string ) :<> Sgn = "atspre_compare_string_string" // end of [fun] (* ****** ****** *) fun stringlst_concat (xs: List string):<> strptr1 = "atspre_stringlst_concat" // end of [stringlst_concat] (* ****** ****** *) fun string_contains (str: string, c: char):<> bool = "atspre_string_contains" // end of [string_contains] fun strptr_contains {l:agz} (str: !strptr l, c: char):<> bool = "atspre_string_contains" // end of [strptr_contains] (* ****** ****** *) fun string_equal (s1: string, s2: string):<> bool = "atspre_eq_string_string" (* ****** ****** *) fun strbuf_length {m,n:nat} (sbf: &strbuf (m, n)):<> size_t n = "atspre_string_length" // end of [strbuf_length] symintr string_length fun string0_length (str: string):<> size_t = "atspre_string_length" fun string1_length {n:nat} (str: string n):<> size_t n = "atspre_string_length" overload string_length with string0_length overload string_length with string1_length fun strptr_length {l:agz} (str: !strptr l):<> size_t = "atspre_string_length" // end of [strptr_length] (* ****** ****** *) fun strbuf_is_empty {m,n:int} (sbf: &strbuf (m, n)):<> bool (n==0) = "atspre_string_is_empty" // end of [strbuf_is_empty] symintr string_is_empty fun string0_is_empty (str: string):<> bool = "atspre_string_is_empty" overload string_is_empty with string0_is_empty fun string1_is_empty {n:nat} (str: string n):<> bool (n==0) = "atspre_string_is_empty" overload string_is_empty with string1_is_empty (* ****** ****** *) fun strbuf_isnot_empty {m,n:int} (sbf: &strbuf (m, n)):<> bool (n > 0) = "atspre_string_isnot_empty" symintr string_isnot_empty fun string0_isnot_empty (str: string):<> bool = "atspre_string_isnot_empty" overload string_isnot_empty with string0_isnot_empty fun string1_isnot_empty {n:nat} (str: string n):<> bool (n > 0) = "atspre_string_isnot_empty" overload string_isnot_empty with string1_isnot_empty (* ****** ****** *) fun strbuf_is_atend {m,n:int} {i:nat | i <= n} (sbf: &strbuf (m, n), i: size_t i):<> bool (i == n) = "atspre_string_is_atend" (* macdef strbuf_is_at_end = strbuf_is_atend // backward compatibility *) fun string_is_atend {n:int} {i:nat | i <= n} (str: string n, i: size_t i):<> bool (i == n) = "atspre_string_is_atend" (* macdef string_is_at_end = string_is_atend // backward compatibility *) (* ****** ****** *) fun strbuf_isnot_atend {m,n:int} {i:nat | i <= n} (sbf: &strbuf (m, n), i: size_t i):<> bool (i < n) = "atspre_string_isnot_atend" (* macdef strbuf_isnot_at_end = strbuf_isnot_atend // backward compatibility *) fun string_isnot_atend {n:int} {i:nat | i <= n} (str: string n, i: size_t i):<> bool (i < n) = "atspre_string_isnot_atend" (* macdef string_isnot_at_end = string_isnot_atend // backward compatibility *) (* ****** ****** *) fun string_explode {n:nat} (str: string n):<> list_vt (char, n) = "atspre_string_explode" // end of [string_explode] (* ****** ****** *) // // HX: this is an alias of [string_make_list] // fun string_implode {n:nat} (cs: list (char, n)):<> strbufptr_gc n = "atspre_string_implode" // end of [string_implode] (* ****** ****** *) // // This function is based on [strchr] in [string.h] // the NULL character at the end of a string is considered in the string // So we do not allow to search for the NULL character!!! // // locate a character from left fun string_index_of_char_from_left {n:nat} (str: string n, c: c1har):<> ssizeBtw (~1, n) = "atspre_string_index_of_char_from_left" // end of [string_index_of_char_from_left] // // This function is based on [strrchr] in [string.h] // the NULL character at the end of a string is considered in the string // So we do not allow to search for the NULL character!!! // // locate a character from right fun string_index_of_char_from_right {n:nat} (str: string n, c: c1har):<> ssizeBtw (~1, n) = "atspre_string_index_of_char_from_right" // end of [string_index_of_char_from_right] (* ****** ****** *) // // This function is based on [strstr] in [string.h] // Note that the NULL character is not compared // fun string_index_of_string // locate a substring from left {n1,n2:nat} (haystack: string n1, needle: string n2):<> ssizeBtw (~1, n1) = "atspre_string_index_of_string" (* ****** ****** *) // // HX: implemented in [prelude/CATS/string.cats] // fun string_singleton (c: char):<> strbufptr_gc 1 = "atspre_string_singleton" (* ****** ****** *) // // HX: implemented in [prelude/DATS/string.dats] // fun string_foreach__main {v:view} {vt:viewtype} {n:nat} {f:eff} (pf: !v | str: string n, f: (!v | c1har, !vt) - void, env: !vt) : void // end of [string_foreach__main] (* ****** ****** *) // // HX: implemented in [prelude/DATS/string.dats] // fun strbuf_tolower {m,n:nat} (buf: &strbuf (m, n)): void = "atspre_strbuf_tolower" fun string_tolower {n:nat} (str: string n):<> strbufptr_gc n (* ****** ****** *) // // HX: implemented in [prelude/DATS/string.dats] // fun strbuf_toupper {m,n:nat} (buf: &strbuf (m, n)): void = "atspre_strbuf_toupper" fun string_toupper {n:nat} (str: string n):<> strbufptr_gc n (* ****** ****** *) // // HX: h = (h << 5) + h + c // fun string_hash_33 (str: string):<> ulint = "atspre_string_hash_33" (* ****** ****** *) // // HX: functions for optional strings // (* ****** ****** *) // // HX: stropt_none = $extval (ats_ptr_type, "0") // val stropt_none : stropt (~1) = "atspre_stropt_none" // symintr stropt_some // castfn stropt0_some (str: string):<> [n:nat] stropt (n) = "atspre_stropt_some" overload stropt_some with stropt0_some castfn stropt1_some {n:nat} (str: string n):<> stropt (n) = "atspre_stropt_some" overload stropt_some with stropt1_some castfn stropt_unsome {n:nat} (stropt: stropt n):<> string n = "atspre_stropt_unsome" // end of [stropt_unsome] fun stropt_is_none{i:int} (stropt: stropt i):<> bool (i < 0) = "atspre_stropt_is_none" fun stropt_is_some{i:int} (stropt: stropt i):<> bool (i >= 0) = "atspre_stropt_is_some" fun fprint_stropt (out: FILEref, stropt: Stropt): void = "atspre_fprint_stropt" overload fprint with fprint_stropt (* ****** ****** *) // // HX: functions for linear optional strings // HX-2010-10-04: Given the availability of strptr, the demand for // linear optional strings has drastically reduced // absviewtype stropt_gc (m:int, n:int) (* castfn stropt_gc_none (_: ptr null): stropt_gc (0, 0) castfn stropt_gc_unnone {n:int} (x: stropt_gc (0, n)):<> ptr (null) *) fun stropt_gc_none ( // there is no argument ) :<> stropt_gc (0, 0) = "mac#atspre_stropt_gc_none" fun stropt_gc_unnone {n:int} ( x: stropt_gc (0, n) ) :<> void = "mac#atspre_stropt_gc_unnone" // end of [stropt_gc_unnone] castfn stropt_gc_some {m,n:nat} {l:addr} (x: strbufptr_gc (m,n,l)) :<> stropt_gc (m, n) = "atspre_stropt_some" castfn stropt_gc_unsome {m,n:nat | m > 0} // [m > n] (x: stropt_gc (m, n)):<> [l:addr] strbufptr_gc (m, n, l) = "atspre_stropt_unsome" fun stropt_gc_is_none {m,n:nat} (s: !stropt_gc (m,n)):<> bool (m == 0) = "atspre_stropt_is_none" fun stropt_gc_is_some {m,n:nat} (s: !stropt_gc (m,n)):<> bool (m >= 1) = "atspre_stropt_is_some" viewtypedef Stropt_gc = [m,n:nat] stropt_gc (m, n) (* ****** ****** *) // // HX-2010-08-10: linear strings // fun strptr_null ( // there is no argument ) :<> strptr (null) = "mac#atspre_strptr_null" // fun strptr_is_null {l:addr} ( x: !strptr l ) :<> bool (l==null) = "mac#atspre_ptr_is_null" fun strptr_isnot_null {l:addr} ( x: !strptr l ) :<> bool (l > null) = "mac#atspre_ptr_isnot_null" // castfn ptr_of_strptr {l:addr} (x: !strptr l):<> ptr l overload ptr_of with ptr_of_strptr // castfn stropt_of_strptr (x: strptr0):<> Stropt // castfn string_of_strptr (x: strptr1):<> string castfn string1_of_strptr (x: strptr1):<> String castfn string1_of_strptrlen {l:addr} {n:nat} (x: strptrlen (l, n)):<> string n // castfn string_takeout_ptr // non-reentrant! (x: string) : [l:agz] (strptr l - void | strptr l) // castfn strbuf_of_strptr {l:agz} (x: strptr l):<> [m,n:int | 0 <= n; n < m] strbufptr_gc (m, n, l) castfn strbuf_of_strptrlen {l:addr} {n:nat} (x: strptrlen (l, n)):<> [m:int | n < m] strbufptr_gc (m, n, l) // castfn strbuf_takeout_ptr {m,n:int} {l:addr} (pf: !strbuf_v (m, n, l) | x: ptr l):<> (strptr l - void | strptr l) // castfn string_of_strbuf {m,n:int} {l:addr} (x: strbufptr_gc (m, n, l)):<> string n // praxi strptr_free_null {l:addr | l <= null} (x: strptr l):<> void fun strptr_free {l:addr} (x: strptr l):<> void = "atspre_strptr_free" // symintr fprint_strptr fun fprint0_strptr {l:addr} (out: FILEref, x: !strptr l): void = "atspre_fprint_strptr" overload fprint_strptr with fprint0_strptr fun fprint1_strptr {l:addr} {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: !strptr l): void = "atspre_fprint_strptr" overload fprint_strptr with fprint1_strptr overload fprint with fprint_strptr // fun print_strptr {l:addr} (x: !strptr l): void overload print with print_strptr fun prerr_strptr {l:addr} (x: !strptr l): void overload prerr with prerr_strptr // symintr strptr_of castfn strptr_of_strbuf {m,n:int} {l:addr} (x: strbufptr_gc (m, n, l)):<> [l > null] strptr l overload strptr_of with strptr_of_strbuf castfn strptr_of_strptrlen {l:addr} {n:int} (x: strptrlen (l, n)):<> [l > null] strptr l overload strptr_of with strptr_of_strptrlen // (* ****** ****** *) fun strptr_dup {l:agz} (x: !strptr l):<> strptr1 fun string_tail {n:int} {i:nat | i <= n} ( x: string n, i: size_t i ) :<> [l:addr] (strptr l - void | strptrlen (l, n-i)) = "atspre_padd_size" // end pf [string_tail] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [string.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [string.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/option.sats0000664000175000017500000000546212223166161020421 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option.sats] starts!\n" #endif (* ****** ****** *) %{# #include "prelude/CATS/option.cats" %} (* ****** ****** *) (* // this is defined in [basics_sta.sats" datatype // t@ype+: covariant option_t0ype_bool_type (a:t@ype+, bool) = | None (a, false) | Some (a, true) of a // end of [datatype] stadef option = option_t0ype_bool_type typedef Option (a:t@ype) = [b:bool] option (a, b) *) (* ****** ****** *) fun option_is_none {a:t@ype} {b:bool} (opt: option (a, b)):<> bool (~b) fun option_is_some {a:t@ype} {b:bool} (opt: option (a, b)):<> bool ( b) (* ****** ****** *) fun{a:type} option_some (x: a):<> option (a, true) fun{a:type} option_unsome (opt: option (a, true)):<> a fun{a:type} option_none ((*void*)):<> option (a, false) (* ****** ****** *) fun{a:t@ype} option_app {f:eff} (opt: Option a, f: a - void): void fun{a1,a2:t@ype} option_map {b:bool} {f:eff} (opt: option (a1, b), f: a1 - a2): option (a2, b) (* ****** ****** *) // // HX: a casting function implemented in [prelude/DATS/option.dats] // castfn option_of_option_vt {a:t@ype} {b:bool} (x: option_vt (a, b)):<> option (a, b) // end of [option_of_option_vt] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option.sats] finishes!\n" #endif (* end of [option.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/option_vt.sats0000664000175000017500000000467512223166161021137 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option_vt.sats] starts!\n" #endif (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) fun{a:vt0p} option_vt_some (x: a): option_vt (a, true) fun{a:vt0p} option_vt_none ((*void*)): option_vt (a, false) (* ****** ****** *) fun{a:vt0p} option_vt_make_opt {b:bool} ( b: bool b, x: &opt (a, b) >> a? ) : option_vt (a, b) // end of [option_vt_make_opt] (* ****** ****** *) fun option_vt_is_none {a:vt0p} {b:bool} (x: !option_vt (a, b)): bool (~b) fun option_vt_is_some {a:vt0p} {b:bool} (x: !option_vt (a, b)): bool ( b) (* ****** ****** *) fun{a:vt0p} option_vt_unsome (opt: option_vt (a, true)):<> a fun{a:vt0p} option_vt_unnone (opt: option_vt (a, false)):<> void (* ****** ****** *) fun{a:t0p} option_vt_free (opt: Option_vt (a)): void (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [option_vt.sats] finishes!\n" #endif (* end of [option_vt.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/list_vt.sats0000664000175000017500000001735412223166161020600 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list_vt.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) %{# #include "prelude/CATS/list_vt.cats" %} // end of [%{#] (* ****** ****** *) sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) (* // this is defined in [basic_sta.sats] dataviewtype // viewt@ype+: covariant list_viewt0ype_int_viewtype (a:viewt@ype+, int) = | {n:int | n >= 0} list_vt_cons (a, n+1) of (a, list_viewt0ype_int_viewtype (a, n)) | list_vt_nil (a, 0) // end of [list_viewt0ype_int_viewtype] stadef list_vt = list_viewt0ype_int_viewtype viewtypedef List_vt (a:viewt@ype) = [n:int | n >=0] list_vt (a, n) *) (* ****** ****** *) macdef list_vt_sing (x) = list_vt_cons (,(x), list_vt_nil ()) macdef list_vt_pair (x1, x2) = list_vt_cons (,(x1), list_vt_cons (,(x2), list_vt_nil)) (* ****** ****** *) prfun list_vt_length_is_nonnegative {a:vt0p} {n:int} (xs: !list_vt (a, n)): [n>=0] void // end of [list_vt_length_is_nonnegative] (* ****** ****** *) fun{} list_vt_is_nil {a:vt0p} {n:int} (xs: !list_vt (a, n)):<> bool (n==0) fun{} list_vt_is_cons {a:vt0p} {n:int} (xs: !list_vt (a, n)):<> bool (n > 0) (* ****** ****** *) fun{a:vt0p} list_vt_make_array {n:int} (A: &(@[a][n]) >> @[a?!][n], n: size_t n):<> list_vt (a, n) // end of [list_vt_make_array] (* ****** ****** *) fun{a:vt0p} list_vt_of_arrpsz {n:int} (psz: arrpsz (a, n)):<> list_vt (a, n) // end of [list_vt_of_arrpsz] (* ****** ****** *) fun{a:t0p} list_vt_copy {n:int} (xs: !list_vt (a, n)):<> list_vt (a, n) (* ****** ****** *) fun{a:t0p} list_vt_free (xs: List_vt a):<> void fun{a:vt0p} list_vt_free_fun ( xs: List_vt a, f: (&a >> a?) - void ) :<> void // end of [list_vt_free_fun] (* ****** ****** *) // // HX: this one is more general than [list_length] as [a] can be linear // fun{a:vt0p} list_vt_length {n:int} (xs: !list_vt (a, n)):<> int n (* ****** ****** *) fun{a:t0p} list_vt_make_elt {n:nat} (x: a, n: int n):<> list_vt (a, n) (* ****** ****** *) fun{a:vt0p} list_vt_extend {n:int} (xs: list_vt (a, n), x: a):<> list_vt (a, n+1) // end of [list_vt_extend] (* ****** ****** *) fun{a:vt0p} list_vt_append {m,n:int} (xs: list_vt (a, m), ys: list_vt (a, n)):<> list_vt (a, m+n) // end of [list_vt_append] (* ****** ****** *) fun{a:vt0p} list_vt_split_at {n:int} {i:nat | i <= n} (xs: &list_vt (a, n) >> list_vt (a, n-i), i: int i):<> list_vt (a, i) // end of [list_vt_split_at] (* ****** ****** *) fun{a:vt0p} list_vt_reverse {n:int} (xs: list_vt (a, n)):<> list_vt (a, n) // end of [list_vt_reverse] fun{a:vt0p} list_vt_reverse_append {m,n:int} (xs: list_vt (a, m), ys: list_vt (a, n)):<> list_vt (a, m+n) // end of [list_vt_reverse_append] (* ****** ****** *) fun{a:vt0p} list_vt_concat (xss: List_vt (List_vt (a))):<> List_vt (a) (* ****** ****** *) fun{a:vt0p} list_vt_tabulate_funenv {v:view} {vt:viewtype} {n:nat} {f:eff} (pf: !v | f: (!v | natLt n, !vt) - a, n: int n, env: !vt) : list_vt (a, n) // end of [list_vt_tabulate_funenv] fun{a:vt0p} list_vt_tabulate_fun {n:nat} {f:eff} (f: natLt n - a, n: int n): list_vt (a, n) // end of [list_vt_tabulate_fun] fun{a:vt0p} list_vt_tabulate_vclo {v:view} {n:nat} {f:eff} (pf: !v | f: &(!v | natLt n) - a, n: int n): list_vt (a, n) // end of [list_vt_tabulate_vclo] fun{a:vt0p} list_vt_tabulate_cloptr {n:nat} {f:eff} (f: !(natLt n) - a, n: int n): list_vt (a, n) // end of [list_vt_tabulate_cloptr] fun{a:vt0p} list_vt_tabulate_vcloptr {v:view} {n:nat} {f:eff} (pf: !v | f: !(!v | natLt n) - a, n: int n): list_vt (a, n) // end of [list_vt_tabulate_vcloptr] (* ****** ****** *) fun{a:vt0p} list_vt_foreach_funenv {v:view} {vt:viewtype} {n:int} {f:eff} (pf: !v | xs: !list_vt (a, n), f: !(!v | &a, !vt) - void, env: !vt) : void // end of [list_vt_foreach_funenv] fun{a:vt0p} list_vt_foreach_fun {n:int} {f:eff} (xs: !list_vt (a, n), f: (&a) - void): void // end of [list_vt_foreach_fun] fun{a:vt0p} list_vt_foreach_vclo {v:view} {n:int} {f:eff} (pf: !v | xs: !list_vt (a, n), f: &(!v | &a) - void): void // end of [list_vt_foreach_vclo] fun{a:t0p} list_vt_foreach_cloptr {n:int} {f:eff} (xs: !list_vt (a, n), f: !(&a) - void): void // end of [list_vt_foreach_cloptr] fun{a:t0p} list_vt_foreach_vcloptr {v:view} {n:int} {f:eff} (pf: !v | xs: !list_vt (a, n), f: !(!v | &a) - void): void // end of [list_vt_foreach_vcloptr] (* ****** ****** *) fun{a:vt0p} list_vt_iforeach_funenv {v:view} {vt:viewtype} {n:int} {f:eff} ( pf: !v | xs: !list_vt (a, n), f: (!v | natLt n, &a, !vt) - void, env: !vt ) : void // end of [list_vt_iforeach_funenv] fun{a:vt0p} list_vt_iforeach_fun {n:int} {f:eff} (xs: !list_vt (a, n), f: (natLt n, &a) - void): void // end of [list_vt_iforeach_fun] fun{a:vt0p} list_vt_iforeach_vclo {v:view} {n:int} {f:eff} (pf: !v | xs: !list_vt (a, n), f: &(!v | natLt n, &a) - void): void // end of [list_vt_iforeach_vclo] fun{a:t0p} list_vt_iforeach_cloptr {n:int} {f:eff} (xs: !list_vt (a, n), f: !(natLt n, &a) - void): void // end of [list_vt_iforeach_cloptr] fun{a:t0p} list_vt_iforeach_vcloptr {v:view} {n:int} {f:eff} (pf: !v | xs: !list_vt (a, n), f: !(!v | natLt n, &a) - void): void // end of [list_vt_iforeach_vcloptr] (* ****** ****** *) fun{a:vt0p} list_vt_mergesort {n:int} (xs: list_vt (a, n), cmp: &(&a, &a) - int):<> list_vt (a, n) // end of [list_vt_mergesort] (* // HX: if needed, this one is more general: fun{a:vt0p} list_vt_mergesort {v:view} {n:int} (pf: !v | xs: list_vt (a, n), cmp: &(!v | &a, &a) - int):<> list_vt (a, n) // end of [list_vt_mergesort] *) (* ****** ****** *) // // HX: // // This one essentially copies a given list into an array; then it sorts // the array and copies it back into the list; then it frees up the array. // // Note that [libc/CATS/stdlib.cats] is needed. It is required that [cmp] be a // function here as the qsort in stdlib is the underlying implementation. // fun{a:vt0p} list_vt_quicksort {n:int} (xs: !list_vt (a, n), cmp: (&a, &a) - int):<> void // end of [list_vt_quicksort] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list_vt.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [list_vt.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/printf.sats0000664000175000017500000001024012223166161020401 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Rick Lavoie (coldfury AT cs DOT bu DOT edu) *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX-2010-10-1: // Note that there are also several // printf-functions and vprintf-functions declared in // $ATSHOME/libc/SATS/stdarg.sats // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [printf.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) fun fprintf_err {m:file_mode} {ts:types} ( pf: file_mode_lte (m, w) | out: &FILE m , fmt: printf_c ts , arg: ts ) : int = "atspre_fprintf_err" // end of [fprintf_err] (* ****** ****** *) symintr fprintf fun fprintf0_exn {ts:types} ( out: FILEref, fmt: printf_c ts, arg: ts ) : void = "atspre_fprintf_exn" // end of [fun] fun fprintf1_exn {m:file_mode} {ts:types} ( pf: file_mode_lte (m, w) | out: &FILE m , fmt: printf_c ts , arg: ts ) : void = "atspre_fprintf_exn" // end of [fun] overload fprintf with fprintf0_exn overload fprintf with fprintf1_exn (* ****** ****** *) fun printf {ts:types} (fmt: printf_c ts, arg: ts): void = "atspre_printf_exn" fun prerrf {ts:types} (fmt: printf_c ts, arg: ts): void = "atspre_prerrf_exn" (* ****** ****** *) symintr assert_prerrf fun assert_prerrf_bool {ts:types} ( assertion: bool, fmt: printf_c ts, arg: ts ) : void = "atspre_assert_prerrf" overload assert_prerrf with assert_prerrf_bool fun assert_prerrf_bool1 {b:bool} {ts:types} ( assertion: bool b, fmt: printf_c ts, arg: ts ) : [b] void = "atspre_assert_prerrf" overload assert_prerrf with assert_prerrf_bool1 (* ****** ****** *) // // HX-2010-08-11: // Note that linear strings are returned by these functions, which // are implemented in $ATSHOME/prelude/DATS/printf.dats // fun tostringf_size {ts:types} (guess: size_t, fmt: printf_c ts, arg: ts):<> strptr0 fun tostringf {ts:types} (fmt: printf_c ts, arg: ts):<> strptr1 = "atspre_tostringf" fun sprintf {ts:types} // HX: the same as [tostringf] (fmt: printf_c ts, arg: ts):<> strptr1 = "atspre_tostringf" (* ****** ****** *) // // HX-2010-08-26: // Note that it is by design that [vsprintf_size] returns a strptr0 // while [vsprintf] returns a strptr1 // fun vsprintf_size {ts:types} ( guess: size_t , fmt: printf_c ts, arg: &va_list (ts) >> va_list ) :<> strptr0 = "atspre_vsprintf_size" // end of [vsprintf] fun vsprintf {ts:types} ( fmt: printf_c ts, arg: &va_list (ts) >> va_list ) :<> strptr1 = "atspre_vsprintf" // end of [vsprintf] (* ****** ****** *) (* ** HX: [fprintf_ats] is to be implemented as a macro if there is a need. *) (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [printf.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [printf.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/list0.sats0000664000175000017500000001350112223166161020135 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) (* ** HX: ** Note that the functions declared in this file are for supporting list ** processing in an ML-like manner. Many more functions are available in ** the following file: ** ** $ATSHOME/libats/smlbas/SATS/list.sats ** ** that are implemented for the same purpose. *) (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list0.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // for forming singleton lists // macdef list0_sing (x) = list0_cons (,(x), list0_nil ()) // (* ****** ****** *) // // HX: a casting function implemented in [prelude/CATS/list.cats] // castfn list0_of_list {a:t@ype} (xs: List a):<> list0 a // // HX: a casting function implemented in [prelude/CATS/list.cats] // castfn list0_of_list_vt {a:t@ype} (xs: List_vt a):<> list0 a (* ****** ****** *) // castfn list_of_list0 {a:t@ype} (xs: list0 a):<> List a // (* ****** ****** *) fun{a:t@ype} list0_of_arrpsz {n:nat} (psz: arrpsz (a, n)):<> list0 a // end of [list0_of_arrpsz] (* ****** ****** *) fun{} list0_is_nil {a:t@ype} (xs: list0 a):<> bool fun{} list0_is_cons {a:t@ype} (xs: list0 a):<> bool (* ****** ****** *) fun{a:t@ype} list0_append (xs: list0 a, ys: list0 a):<> list0 a overload + with list0_append (* ****** ****** *) fun{a,b:t@ype} list0_assoc_fun (xs: list0 @(a, b), eq: (a, a) - bool, x: a): option0 (b) // end of [list0_assoc_fun] fun{a,b:t@ype} list0_assoc_cloref (xs: list0 @(a, b), eq: (a, a) - bool, x: a): option0 (b) // end of [list0_assoc_cloref] (* ****** ****** *) fun{a:t@ype} list0_concat (xs: list0 (list0 a)):<> list0 a (* ****** ****** *) fun{a:t@ype} list0_exists_fun (xs: list0 a, f: a - bool): bool fun{a:t@ype} list0_exists_cloref (xs: list0 a, f: a - bool): bool (* ****** ****** *) fun{a:t@ype} list0_filter_fun (xs: list0 a, pred: a - bool): list0 a fun{a:t@ype} list0_filter_cloref (xs: list0 a, pred: a - bool): list0 a (* ****** ****** *) fun{a:t@ype} list0_find_fun (xs: list0 a, pred: a - bool): option0 a fun{a:t@ype} list0_find_cloref (xs: list0 a, pred: a - bool): option0 a (* ****** ****** *) fun{init:t@ype}{a:t@ype} list0_fold_left (f: (init, a) - init, ini: init, xs: list0 a): init // end of [list0_fold_left] fun{a:t@ype}{sink:t@ype} list0_fold_right (f: (a, sink) - sink, xs: list0 a, snk: sink): sink // end of [list0_fold_right] (* ****** ****** *) fun{a:t@ype} list0_forall_fun (xs: list0 a, f: a - bool): bool fun{a:t@ype} list0_forall_cloref (xs: list0 a, f: a - bool): bool (* ****** ****** *) fun{a:t@ype} list0_foreach_fun (xs: list0 a, f: a - void): void fun{a:t@ype} list0_foreach_cloref (xs: list0 a, f: a - void): void (* ****** ****** *) fun{a:t@ype} list0_iforeach_fun (xs: list0 a, f: (int, a) - void): void fun{a:t@ype} list0_iforeach_cloref (xs: list0 a, f: (int, a) - void): void (* ****** ****** *) fun{a:t@ype} list0_head_exn (xs: list0 a): a (* ****** ****** *) fun{a:t@ype} list0_length (xs: list0 a):<> int (* ****** ****** *) fun{a:t@ype}{b:t@ype} list0_map_fun (xs: list0 a, f: a - b): list0 b fun{a:t@ype}{b:t@ype} list0_map_cloref (xs: list0 a, f: a - b): list0 b (* ****** ****** *) fun{a1,a2:t@ype}{b:t@ype} list0_map2_fun (xs1: list0 a1, xs2: list0 a2, f: (a1, a2) - b): list0 b // end of [list0_map2_fun] fun{a1,a2:t@ype}{b:t@ype} list0_map2_cloref (xs1: list0 a1, xs2: list0 a2, f: (a1, a2) - b): list0 b // end of [list0_map2_cloref] (* ****** ****** *) fun{a:t@ype} list0_nth_exn (xs: list0 a, i: int): a fun{a:t@ype} list0_nth_opt (xs: list0 a, i: int): option0 a (* ****** ****** *) fun{a:t@ype} list0_reverse (xs: list0 a): list0 a fun{a:t@ype} list0_reverse_append (xs: list0 a, ys: list0 a): list0 a // // HX: this one is the same as [list0_reverse_append] // fun{a:t@ype} list0_revapp (xs: list0 a, ys: list0 a): list0 a (* ****** ****** *) fun{a:t@ype} list0_tail_exn (xs: list0 a): list0 a (* ****** ****** *) fun{a:t@ype} list0_take_exn (xs: list0 a, n: int): list0 a fun{a:t@ype} list0_drop_exn (xs: list0 a, n: int): list0 a (* ****** ****** *) fun{a:t@ype} list0_mergesort (xs: list0 a, cmp: (a, a) - int): list0 (a) (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [list0.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [list0.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/number.sats0000664000175000017500000001010312223166161020365 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** An interface for various common funtion on numbers ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // this is originally done for the ATS/CBLAS package (* ****** ****** *) // // legend: // S: single precision float (float) // D: double precision float (double) // C: single precision complex (ccmplx) // Z: double precision complex (zcmplx) // (* ****** ****** *) // S, D, C, Z fun{a:t@ype} print_typ (): void fun{a:t@ype} print_elt (x: a): void (* ****** ****** *) // S, D, C, Z fun{a:t@ype} of_int (x: int):<> a (* ****** ****** *) // S, D fun{a:t@ype} of_size (x: size_t):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} of_double (x: double):<> a (* ****** ****** *) // S, D fun{a:t@ype} to_int (x:a):<> int fun{a:t@ype} to_float (x: a):<> float fun{a:t@ype} to_double (x: a):<> double (* ****** ****** *) // S, D, C, Z fun{a1,a2:t@ype} abs (x: a1):<> a2 (* ****** ****** *) // S, D, C, Z fun{a:t@ype} neg (x: a):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} add (x1: a, x2: a):<> a fun{a:t@ype} sub (x1: a, x2: a):<> a fun{a:t@ype} mul (x1: a, x2: a):<> a fun{a:t@ype} div (x1: a, x2: a):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} pow (base: a, exp: a):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} sqrt (x: a):<> a (* ****** ****** *) // S, D fun{a:t@ype} ceil (x:a) :<> a fun{a:t@ype} floor (x:a) :<> a (* ****** ****** *) // (S, S), (D, D) // (S, C), (C, C), (D, Z), (Z, Z) fun{a1,a2:t@ype} scal (x1: a1, x2: a2):<> a2 (* ****** ****** *) // S, D fun{a:t@ype} lt (x1: a, x2: a):<> bool fun{a:t@ype} lte (x1: a, x2: a):<> bool fun{a:t@ype} gt (x1: a, x2: a):<> bool fun{a:t@ype} gte (x1: a, x2: a):<> bool (* ****** ****** *) // S, D, C, Z fun{a:t@ype} eq (x1: a, x2: a):<> bool fun{a:t@ype} neq (x1: a, x2: a):<> bool (* ****** ****** *) // S, D fun{a:t@ype} signof (x: a):<> Sgn fun{a:t@ype} compare (x1: a, x2: a):<> Sgn (* ****** ****** *) // S, D fun{a:t@ype} min (x:a, y:a):<> a fun{a:t@ype} max (x:a, y:a):<> a (* ****** ****** *) // (S, C), (D, Z) // a1 = |a2| fun{a1,a2:t@ype} cmplx_make_cart (real: a1, imag: a1):<> a2 (* ****** ****** *) // (S, C), (D, Z) fun {a1,a2:t@ype} creal (x: a2):<> a1 fun {a1,a2:t@ype} cimag (x: a2):<> a1 (* ****** ****** *) // C, Z fun{a:t@ype} conj (x: a):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} sin (x: a):<> a fun{a:t@ype} cos (x: a):<> a fun{a:t@ype} tan (x: a):<> a (* ****** ****** *) // S, D, C, Z fun{a:t@ype} asin (x: a):<> a fun{a:t@ype} acos (x: a):<> a fun{a:t@ype} atan (x: a):<> a fun{a:t@ype} atan2 (x1: a, x2: a):<> a (* ****** ****** *) (* end of [number.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/matrix0.sats0000664000175000017500000000757112223166161020500 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: // // Note that [matrix0] is a persistent array with row/column information // attached. // // This package is mostly for a beginner who is unfamiliar with ATS. After // some exposure to dependent types and linear types, the programmer is // strongly recommended to use functions declared in [matrix.sats] instead. // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [matrix0.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // HX: matrix0 (a) = ref (... | ptr, row, col) // (* ****** ****** *) fun matrix0_make_arrpsz {a:viewt@ype} {m,n:nat} ( m: size_t m, n: size_t n, psz: arrpsz (a, m*n) ) :<> matrix0 (a) // end of [matrix0_make_arrpsz] fun matrix0_make_arrpsz__main {a:viewt@ype} {m,n:nat} {mn:int} ( pf_mul: MUL (m, n, mn) | m: size_t m, n: size_t n, psz: arrpsz (a, mn) ) :<> matrix0 (a) // end of [matrix0_make_arrpsz] (* ****** ****** *) fun{a:t@ype} matrix0_make_elt ( row: size_t, col: size_t, x: a ) :<> matrix0 (a) // end of [matrix0_make_elt] (* ****** ****** *) fun matrix0_row {a:t@ype} (M: matrix0 a): size_t fun matrix0_col {a:t@ype} (M: matrix0 a): size_t (* ****** ****** *) fun{a:t@ype} matrix0_get_elt_at (M: matrix0 a, i: size_t, j: size_t): a overload [] with matrix0_get_elt_at fun{a:t@ype} matrix0_set_elt_at (M: matrix0 a, i: size_t, j: size_t, x: a): void overload [] with matrix0_set_elt_at (* ****** ****** *) fun{a:t@ype} matrix0_get_elt_at__intsz (M: matrix0 a, i: int, j: int): a overload [] with matrix0_get_elt_at__intsz fun{a:t@ype} matrix0_set_elt_at__intsz (M: matrix0 a, i: int, j: int, x: a): void overload [] with matrix0_set_elt_at__intsz (* ****** ****** *) // HX: it is done row-by-row fun{a:t@ype} matrix0_foreach (M: matrix0 a, f: (&a) - void): void // end of [matrix0_foreach] // HX: it is done row-by-row fun{a:t@ype} matrix0_iforeach (M: matrix0 a, f: (size_t, size_t, &a) - void): void // end of [matrix0_iforeach] (* ****** ****** *) // // HX: [row] and [col] are assumed to be nonzero // fun{a:t@ype} matrix0_tabulate // M[i,j] := f(i, j) (row: size_t, col: size_t, f: (size_t, size_t) - a):<> matrix0 a // end of [matrix0_tabulate] (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [matrix0.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [matrix0.sats] *) ats-lang-anairiats-0.2.11/prelude/SATS/pointer.sats0000664000175000017500000002203212223166161020561 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some common functions on pointers // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [pointer.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) praxi ptr_is_gtez {l:addr} (p: ptr l):<> [l >= null] void // end of [ptr_is_gtez] (* ****** ****** *) fun ptr_is_null (p: ptr):<> bool = "mac#atspre_ptr_is_null" fun ptr_isnot_null (p: ptr):<> bool = "mac#atspre_ptr_isnot_null" (* ****** ****** *) fun add_ptr_int (p: ptr, i: int):<> ptr = "mac#atspre_padd_int" overload + with add_ptr_int fun add_ptr_size (p: ptr, sz: size_t):<> ptr = "mac#atspre_padd_size" overload + with add_ptr_size fun sub_ptr_int (p: ptr, i: int):<> ptr = "mac#atspre_psub_int" overload - with sub_ptr_int fun sub_ptr_size (p: ptr, sz: size_t):<> ptr = "mac#atspre_psub_size" overload - with sub_ptr_size (* ****** ****** *) fun lt_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_plt" and lte_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_plte" overload < with lt_ptr_ptr overload <= with lte_ptr_ptr fun gt_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_pgt" and gte_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_pgte" overload > with gt_ptr_ptr overload >= with gte_ptr_ptr fun eq_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_peq" and neq_ptr_ptr (p1: ptr, p2: ptr):<> bool = "mac#atspre_pneq" overload = with eq_ptr_ptr overload <> with neq_ptr_ptr overload != with neq_ptr_ptr (* ****** ****** *) (* // HX: declared in [integer_ptr.sats] castfn ptr_of_uintptr (u: uintptr): ptr // = "mac#atspre_ptr_of_uintptr" castfn uintptr_of_ptr (p: ptr): uintptr // = "mac#atspre_uintptr_of_ptr" *) (* ****** ****** *) castfn ptr1_of_ptr (p: ptr):<> [l:addr] ptr l (* ****** ****** *) val the_null_ptr : ptr null = "mac#atspre_null_ptr" macdef null = the_null_ptr // endmac fun ptr1_is_null {l:addr} (p: ptr l):<> bool (l==null) = "mac#atspre_ptr_is_null" fun ptr1_isnot_null {l:addr} (p: ptr l):<> bool (l > null) = "mac#atspre_ptr_isnot_null" overload ~ with ptr1_isnot_null (* ****** ****** *) fun psucc {l:addr} (p: ptr l):<> ptr (l + 1) = "mac#atspre_psucc" fun ppred {l:addr} (p: ptr l):<> ptr (l - 1) = "mac#atspre_ppred" overload succ with psucc overload pred with ppred (* ****** ****** *) symintr padd fun padd_int {l:addr} {i:int} ( p: ptr l, i: int i ) :<> ptr (l + i) = "mac#atspre_padd_int" overload + with padd_int overload padd with padd_int fun padd_size {l:addr} {i:int} ( p: ptr l, i: size_t i ) :<> ptr (l + i) = "mac#atspre_padd_size" overload + with padd_size overload padd with padd_size (* ****** ****** *) symintr psub fun psub_int {l:addr} {i:int} ( p: ptr l, i: int i ) :<> ptr (l - i) = "mac#atspre_psub_int" overload - with psub_int overload psub with psub_int fun psub_size {l:addr} {i:int} ( p: ptr l, i: size_t i ) :<> ptr (l - i) = "mac#atspre_psub_size" overload - with psub_size overload psub with psub_size (* ****** ****** *) fun pdiff {l1,l2:addr} ( p1: ptr l1, p2: ptr l2 ) :<> ptrdiff_t (l1 - l2) = "mac#atspre_pdiff" overload - with pdiff (* ****** ****** *) fun plt {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 < l2) = "mac#atspre_plt" and plte {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 <= l2) = "mac#atspre_plte" overload < with plt overload <= with plte fun pgt {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 > l2) = "mac#atspre_pgt" and pgte {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 >= l2) = "mac#atspre_pgte" overload > with pgt overload >= with pgte fun peq {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 == l2) = "mac#atspre_peq" and pneq {l1,l2:addr} (p1: ptr l1, p2: ptr l2):<> bool (l1 <> l2) = "mac#atspre_pneq" overload = with peq overload <> with pneq overload != with pneq (* ****** ****** *) fun compare_ptr_ptr (p1: ptr, p2: ptr):<> Sgn = "mac#atspre_compare_ptr_ptr" overload compare with compare_ptr_ptr (* ****** ****** *) // print functions for pointers fun fprint_ptr {m:file_mode} (pf: file_mode_lte (m, w) | out: !FILE m, x: ptr): void = "atspre_fprint_ptr" overload fprint with fprint_ptr fun print_ptr (p: ptr): void = "atspre_print_ptr" and prerr_ptr (p: ptr): void = "atspre_prerr_ptr" overload print with print_ptr overload prerr with prerr_ptr // stringization fun tostring_ptr (p: ptr):<> strptr1 = "atspre_tostring_ptr" overload tostring with tostring_ptr (* ****** ****** *) praxi free_gc_t0ype_addr_trans {a1,a2:t@ype | sizeof a1 == sizeof a2} {l:addr} (pf_gc: !free_gc_v (a1, l) >> free_gc_v (a2, l)): void // end of [free_gc_t0ype_addr_trans] (* ****** ****** *) fun{a:viewt@ype} ptr_alloc () :<> [l:addr | l > null] (free_gc_v (a?, l), a? @ l | ptr l) // end of [ptr_alloc] fun ptr_alloc_tsz {a:viewt@ype} (tsz: sizeof_t a) :<> [l:addr | l > null] (free_gc_v (a?, l), a? @ l | ptr l) = "atspre_ptr_alloc_tsz" fun ptr_free {a:t@ype} {l:addr} ( pfgc: free_gc_v (a, l), pfat: a @ l | p: ptr l ) :<> void = "atspre_ptr_free" // end of [ptr_free] (* ****** ****** *) absprop NULLABLE (a: viewt@ype+) // covariant (* ** HX: is [ptr_zeroing] a more informative name? *) fun{a:viewt@ype} ptr_zero (pf: NULLABLE (a) | x: &a? >> a):<> void fun ptr_zero_tsz {a:viewt@ype} ( pf: NULLABLE (a) | x: &a? >> a, tsz: sizeof_t a ) :<> void = "atspre_ptr_zero_tsz" // end of [ptr_zero_tsz] (* ****** ****** *) // template fun{a:t@ype} ptr_get_t_main {v:view} {l:addr} (pf1: !v, pf2: vsubr_p (a @ l, v) | p: ptr l):<> a // end of [ptr_get_t_main] // implemented in [prelude/DATS/pointer.dats] fun{a:t@ype} ptr_get_t {l:addr} (pf: !a @ l | p: ptr l):<> a // implemented in [prelude/DATS/pointer.dats] fun{a:t@ype} ptr_set_t {l:addr} (pf: !(a?) @ l >> a @ l | p: ptr l, x: a):<> void // end of [ptr_set_t] (* ****** ****** *) // template fun{a:t@ype} ptr_move_t_main {v:view} {l1,l2:addr} ( pf1: !v, pf2: vsubr_p (a @ l1, v), pf3: !(a?) @ l2 >> a @ l2 | p1: ptr l1, p2: ptr l2 ) :<> void // implemented in [prelude/DATS/pointer.dats] fun{a:t@ype} ptr_move_t {l1,l2:addr} (pf1: !a @ l1, pf2: !(a?) @ l2 >> a @ l2 | p1: ptr l1, p2: ptr l2):<> void // end of ... // implemented in [prelude/CATS/pointer.cats] fun ptr_move_t_tsz {a:t@ype} {l1,l2:addr} ( pf1: !a @ l1, pf2: !(a?) @ l2 >> a @ l2 | p1: ptr l1, p2: ptr l2, tsz: sizeof_t a ) :<> void = "atspre_ptr_move_tsz" (* ****** ****** *) // implemented in [prelude/DATS/pointer.dats] fun{a:viewt@ype} ptr_get_vt {l:addr} (pf: !a @ l >> (a?!) @ l | p: ptr l):<> a // implemented in [prelude/DATS/pointer.dats] fun{a:viewt@ype} ptr_set_vt {l:addr} (pf: !(a?) @ l >> a @ l | p: ptr l, x: a):<> void (* ****** ****** *) // implemented in [prelude/DATS/pointer.dats] fun{a:viewt@ype} ptr_move_vt {l1,l2:addr} ( pf1: !a @ l1 >> (a?) @ l1, pf2: !(a?) @ l2 >> a @ l2 | p1: ptr l1, p2: ptr l2 ) :<> void // implemented in [prelude/CATS/pointer.cats] fun ptr_move_vt_tsz {a:viewt@ype} {l1,l2:addr} ( pf1: !a @ l1 >> (a?) @ l1, pf2: !(a?) @ l2 >> a @ l2 | p: ptr l1, p2: ptr l2, tsz: sizeof_t a ) :<> void = "atspre_ptr_move_tsz" (* ****** ****** *) // implemented in [prelude/DATS/pointer.dats] fun{a:t@ype} ptr_get_inv {l:addr} (pf: !a @ l | p: ptr l):<> a // implemented in [prelude/DATS/pointer.dats] fun{a:t@ype} ptr_set_inv {l:addr} (pf: !a @ l | p: ptr l, x: a):<> void (* ****** ****** *) (* // This should be moved to another place as it is not supported by // ATS/Geizella fun{a:t@ype} ptr_get_read {v:view} {l:addr} (pf1: !v, pf2: r@ead (v, a @ l) | p: ptr l):<> a *) (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [pointer.sats] finishes!\n" #endif // end of [#if VERBOSE_PRELUDE] (* end of [pointer.sats] *) ats-lang-anairiats-0.2.11/prelude/basics_dyn.sats0000664000175000017500000003506112223166162020454 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: 2007 // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [basics_dyn.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) // // HX: some overloaded symbols // symintr ~ not symintr && || << >> land lor lxor symintr + - * / mod gcd symintr < <= > >= = <> != symintr succ pred symintr abs square sqrt cube cbrt symintr compare max min pow symintr foreach // foreach without index symintr iforeach (* foreach with index *) symintr fprint print prerr symintr length (* array_length, list_length, string_length, etc. *) symintr ofstring ofstrptr symintr tostring tostrptr symintr liftmac evalmac symintr assert assert_errmsg symintr bool_of // booleans symintr char_of uchar_of // signed/unsigned chars symintr int_of uint_of // signed/unsigned integers symintr int1_of uint1_of // signed/unsigned indexed integers symintr lint_of ulint_of // signed/unsigned long integers symintr llint_of ullint_of // signed/unsigned long long integers symintr sint_of usint_of // signed/unsigned short integers symintr ssint_of ussint_of // signed/unsigned short short integers symintr float_of double_of ldouble_of // single/double/long double symintr ptr_of ptrnul_of // many, many, many, ... symintr encode decode // many, many, many (* ****** ****** *) praxi cleanup_top {a:viewt@ype} (x: a?): void (* ****** ****** *) // // HX: should this be assumed? // HX-2010-10-12: of course, it should // praxi eqsize_byte_one (): [sizeof(byte)==1] void // praxi eqsize_byte_char (): [sizeof(byte)==sizeof(char)] void praxi eqsize_int_uint (): [sizeof(int)==sizeof(uint)] void praxi eqsize_char_schar (): [sizeof(char)==sizeof(schar)] void praxi eqsize_char_uchar (): [sizeof(char)==sizeof uchar] void // // HX-2010-04-18: there are no negative addresses // praxi addr_is_gtez {l:addr} (): [l >= null] void (* ****** ****** *) prfun false_elim {X:prop | false} (): X // [false] implies all (* ****** ****** *) (* ** ** The proof function [verify_constraint] is mostly used for ** debugging proofs, and it is equivalent to the follow line: ** ** prval _ = (): [p] void ** ** Note that the followine line puts [p] into the assumption ** store after verification is done: ** ** prval () = (): [p] void ** *) prfun verify_constraint {p:bool | p} (): void (* ****** ****** *) (* val AssertionException : exn = "AssertionException" val DivisionByZeroException : exn = "DivisionByZeroException" val OverflowException : exn = "OverflowException" val SubscriptException : exn = "SubscriptException" *) (* ****** ****** *) val{elt:viewt@ype} sizeof : size_t (sizeof elt) (* ****** ****** *) // // HX: note that sizeof(empty) = 0 and sizeof(void) = 1 // val empval : empty = "mac#ats_empty_value" // the empty value in ATS // end of [empval] (* ****** ****** *) // // HX: In $ATSHOME/ccomp/runtime: // ats_true_bool/ats_true_false are mapped to 1/0, respectively // val true : bool (true) = "mac#ats_true_bool" // macro and false : bool (false) = "mac#ats_false_bool" // macro (* ****** ****** *) // // HX: this function results in a FATAL irrecoverable error // fun crash // crash() = (void)*(int*)0 (): void = "ats_crash" // implemented in [prelude/DATS/basics.dats] // end of [crash] (* ****** ****** *) fun exit {a:viewt@ype} ( status: int ) : a = "mac#ats_exit" // end of [fun] fun exit_main {a:viewt@ype} {v_in:view} {v_out:view} ( pf: !v_in >> v_out | status: int ) : a = "mac#ats_exit" // end of [fun] fun exit_errmsg {a:viewt@ype} ( status: int, msg: string ) : a = "mac#ats_exit_errmsg" // end of [fun] fun exit_prerrf {a:viewt@ype} {ts:types} ( status: int, fmt: printf_c ts, args: ts ) : a = "mac#atspre_exit_prerrf" // end of [fun] (* ****** ****** *) // // HX-2010-10-02: // the function should be used in a position // where it is deadcode! // fun assertfalse (): [false] void = "atspre_assertfalse" // end of [assertfalse] (* ****** ****** *) fun assert_bool (assertion: bool): void = "atspre_assert" overload assert with assert_bool fun assert_bool1 {b:bool} ( assertion: bool b ) : [b] void = "atspre_assert" overload assert with assert_bool1 (* ****** ****** *) fun assert_errmsg_bool ( assertion: bool, msg: string ) : void = "atspre_assert_errmsg" overload assert_errmsg with assert_errmsg_bool fun assert_errmsg_bool1 {b:bool} ( assertion: bool b, msg: string ) : [b] void = "atspre_assert_errmsg" overload assert_errmsg with assert_errmsg_bool1 (* fun assert_errmsg_bool1_string1 {b:bool} ( assertion: bool b, msg: String ) : [b] void = "atspre_assert_errmsg" overload assert_errmsg with assert_errmsg_bool1_string1 *) (* ****** ****** *) // // HX: // If [main_dummy] is implemented, then it indicates that [mainats] // is implemented in C // prfun main_dummy (): void (* ****** ****** *) // // HX: for internal use: // [main_prelude] is called before [main] // it is implemented in "$ATSHOME/ats_main_prelude.dats" // // HX: please note that the difference in names // fun main_prelude (): void = "mainats_prelude" (* ****** ****** *) (* fun main {n:int | n >= 1} (argc: int n, argv: &(@[string][n])): void = "mainats" // end of [main] *) symintr main fun main_void (): void = "mainats" overload main with main_void fun main_argc_argv {n:int | n >= 1} (argc: int n, argv: &(@[string][n])): void = "mainats" overload main with main_argc_argv (* ****** ****** *) // // HX: for returning free_gc_v to GC // symintr free_gc_elim // praxi free_gc_elim_addr // return the certificate to the GC {l:addr} (pf: free_gc_v l): void overload free_gc_elim with free_gc_elim_addr praxi free_gc_elim_t0ype_addr // return the certificate to the GC {a:t@ype} {l:addr} (pf: free_gc_v (a, l)): void overload free_gc_elim with free_gc_elim_t0ype_addr praxi free_gc_elim_t0ype_int_addr // return the certificate to the GC {a:t@ype} {n:int} {l:addr} (pf: free_gc_v (a, n, l)): void overload free_gc_elim with free_gc_elim_t0ype_int_addr // (* ****** ****** *) // // HX: implemented in [basics.cats] // castfn cloptr_get_view_ptr {a:viewt@ype} (x: cloptr a):<> [l:addr] (free_gc_v l, clo a @ l | ptr l) = "atspre_cloptr_get_view_ptr" // end of [cloptr_get_view_ptr] castfn cloptr_make_view_ptr {a:viewt@ype} {l:addr} (pf_gc: free_gc_v l, pf_at: clo a @ l | p: ptr l):<> cloptr a = "atspre_cloptr_make_view_ptr" // end of [cloptr_make_view_ptr] castfn cloref_get_view_ptr {a:t@ype} (x: cloref a):<> [l:addr] (vbox (clo a @ l) | ptr l) = "atspre_cloref_get_view_ptr" // end of [cloref_get_view_ptr] castfn cloref_make_view_ptr {a:t@ype} {l:addr} (pf: vbox (clo a @ l) | p: ptr l):<> cloref a = "atspre_cloref_make_view_ptr" // end of [cloref_make_view_ptr] fun cloptr_free {a:t@ype} (x: cloptr a):<> void = "atspre_cloptr_free" (* ****** ****** *) praxi clstrans {c1,c2,c3:cls | c1 <= c2; c2 <= c3} (): [c1 <= c3] void // end of [clstrans] dataprop SUBCLS (c1:cls, c2:cls, bool) = | {c1 <= c2} SUBCLS (c1, c2, true) of () | SUBCLSfalse (c1, c2, false) of () // end of [SUBCLS] (* ****** ****** *) // // fun void ():<> void = "ats_void" // // [vbox_make_view_ptr] implemented in [basics.cats] fun vbox_make_view_ptr {a:viewt@ype} {l:addr} // for statically allocated (_: a @ l | _: ptr l):<> (vbox (a @ l) | void) = "atspre_vbox_make_view_ptr" // end of [vbox_make_view_ptr] (* ****** ****** *) // // HX: optional initialization // praxi opt_some {a:viewt@ype} (x: !(a) >> opt (a, true)): void praxi opt_unsome {a:viewt@ype} (x: !opt (a, true) >> a): void // praxi opt_none {a:viewt@ype} (x: !(a?) >> opt (a, false)): void praxi opt_unnone {a:viewt@ype} (x: !opt (a, false) >> a?): void // praxi opt_clear {a:t@ype} {b:bool} (x: !opt (a, b) >> a?): void // (* ****** ****** *) (* // fractional views are yet to be supported sta zero : rat and one : rat prval vfrac_make : {v:view} v -<> [s:stamp] vfrac (s, v, one) and vfrac_free : {v:view} {s:stamp} vfrac (s, v, one) -<> v and vfrac_split : {v:view} {r:rat} {s:stamp} vfrac (s, v, r) -<> (vfrac (s, v, r/2), vfrac (s, v, r/2)) and vfrac_unsplit : {v:view} {r1,r2: rat} {s:stamp} (vfrac (s, v, r1), vfrac (s, v, r2)) -<> vfrac (s, v, r1+r2) fun vtfrac_make {vt:viewtype} (_: vt):<> [s:stamp] vtfrac (s, vt, one) and vtfrac_free {vt:viewtype} {s:stamp} (_: vtfrac (s, vt, one)):<> vt and vtfrac_split {vt:viewtype} {r:rat} {s:stamp} (_: vtfrac (s, vt, r)):<> (vtfrac (s, vt, r/2), vtfrac (s, vt, r/2)) and vtfrac_unsplit {vt:viewtype} {r1,r2:rat} {s:stamp} (_: vtfrac (s, vt, r1), vtfrac (s, vt, r2)):<> vtfrac (s, vt, r1+r2) *) (* ****** ****** *) abstype file_mode (file_mode) // string type dataprop file_mode_lte (file_mode, file_mode) = | {m:file_mode} file_mode_lte_refl (m, m) | {m1,m2,m3:file_mode} file_mode_lte_tran (m1, m3) of (file_mode_lte (m1, m2), file_mode_lte (m2, m3)) | {m:file_mode} file_mode_lte_rw_r (rw, r) of () | {m:file_mode} file_mode_lte_rw_w (rw, w) of () // end of [file_mode_lte] prval file_mode_lte_r_r: file_mode_lte (r, r) // implemented in [basic.dats] prval file_mode_lte_w_w: file_mode_lte (w, w) // implemented in [basic.dats] prval file_mode_lte_rw_rw: file_mode_lte (rw, rw) // implemented in [basic.dats] (* ****** ****** *) (* standard I/O channels *) // standard input/output/error sta stdin_addr : addr macdef stdin = $extval (ptr stdin_addr, "stdin") fun stdin_get (): (FILE r @ stdin_addr | ptr stdin_addr) = "atspre_stdin_get" // end of [stdin_get] fun stdin_view_get () : (FILE r @ stdin_addr | void) = "atspre_stdin_view_get" // end of [stdin_view_get] and stdin_view_set (pf: FILE r @ stdin_addr | (*none*)): void = "atspre_stdin_view_set" // end of [stdin_view_set] sta stdout_addr : addr macdef stdout = $extval (ptr stdout_addr, "stdout") fun stdout_get () : (FILE w @ stdout_addr | ptr stdout_addr) = "atspre_stdout_get" // end of [stdout_get] fun stdout_view_get () : (FILE w @ stdout_addr | void) = "atspre_stdout_view_get" // end of [stdout_view_get] and stdout_view_set (pf: FILE w @ stdout_addr | (*none*)): void = "atspre_stdout_view_set" // end of [stdout_view_set] sta stderr_addr : addr macdef stderr = $extval (ptr stderr_addr, "stderr") fun stderr_get () : (FILE w @ stderr_addr | ptr stderr_addr) = "atspre_stderr_get" // end of [stderr_get] fun stderr_view_get () : (FILE w @ stderr_addr | void) = "atspre_stderr_view_get" // end of [stderr_view_get] and stderr_view_set (pf: FILE w @ stderr_addr | (*none*)): void = "atspre_stderr_view_set" // end of [stderr_view_set] (* ****** ****** *) // // print functions for various type of data // typedef fprint_t0ype_type (a:t@ype) = {m:file_mode} (file_mode_lte (m, w) | &FILE m, a) - void typedef fprint_viewt0ype_type (a:viewt@ype) = {m:file_mode} (file_mode_lte (m, w) | &FILE m, !a) - void (* ****** ****** *) // // HX: print functions for newlines // symintr fprint_newline fun fprint0_newline (out: FILEref): void = "atspre_fprint_newline" fun fprint1_newline {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m): void = "atspre_fprint_newline" overload fprint_newline with fprint0_newline overload fprint_newline with fprint1_newline fun print_newline (): void = "atspre_print_newline" and prerr_newline (): void = "atspre_prerr_newline" (* ****** ****** *) // // HX-2010-08-10: // the mode information is simply asserted and can be incorrect! // castfn FILEref_get_ref {m:file_mode} (x: FILEref):<> ref (FILE m) castfn FILEref_get_view_ptr {m:file_mode} // non-reentrant! (x: FILEref):<> [l:addr] (FILE m @ l, FILE m @ l - void | ptr l) // end of [FILEref_get_view_ptr] (* ****** ****** *) // // HX: implemented in prelude/DATS/basics.dats // prval option_v_unsome : {v:view} option_v (v, true) - v prval option_v_unnone : {v:view} option_v (v, false) - void (* ****** ****** *) // // HX: implemented in prelude/DATS/basics.dats // prfun unit_v_elim (pf: unit_v): void (* ****** ****** *) (* // // HX: DEPRECATED!!! // it is now supported internally; see [lazy.cats] and [lazy_vt.cats] // // // for lazy (i.e., call-by-need) evaluation // // nonlinear version dataviewtype thunkvalue (a:t@ype+) = | thunkvalue_thunk (a) of (() - a) | thunkvalue_value (a) of a // end of [thunkvalue] // // implemented in [prelude/DATS/lazy.dats] // fun{a:t@ype} lazy_force_crypt (x: crypt (lazy a)): a macdef lazy_force (x) = lazy_force_crypt ($encrypt ,(x)) // linear version dataviewtype thunkvalue_vt (a:viewt@ype+) = | thunkvalue_vt_thunk (a) of (() - a) | thunkvalue_vt_value (a) of a // end of [thunkvalue_vt] // implemented in [prelude/DATS/lazy.dats] fun{a:viewt@ype} lazy_vt_force_crypt (x: crypt (lazy_vt a)): a macdef lazy_vt_force (x) = lazy_vt_force_crypt ($encrypt ,(x)) *) fun{a:t@ype} lazy_force (x: lazy a): a fun{a:viewt@ype} lazy_vt_force (x: lazy_vt a): a (* ****** ****** *) fun lazy_vt_free {a:viewt@ype} (x: lazy_vt a): void = "ats_lazy_vt_free" overload ~ with lazy_vt_free (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [basics_dyn.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [basics_dyn.sats] *) ats-lang-anairiats-0.2.11/prelude/params.hats0000664000175000017500000000423112223166162017601 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) #define VERBOSE_FIXITY 0 (* used in [prelude/fixity.ats] *) #define VERBOSE_PRELUDE 0 (* mainly for the purpose of debugging *) (* ****** ****** *) #define ATS_MAJOR_VERSION 0 #define ATS_MINOR_VERSION 2 #define ATS_MICRO_VERSION 11 (* ****** ****** *) #define ATS_VERBOSE_LEVEL 0 #define ATS_CC_VERBOSE_LEVEL 1 // this one is used in the following files // $ATSHOME/src/ats_ccomp_emit.dats #define ATS_GC_VERBOSE_LEVEL 0 // this one is used in the following files // $ATSHOME/ccomp/runtime/GCATS/gc_top.dats (* ****** ****** *) // // HX: this one is used in the #define ATS_PKGCONFIG 1 // following file: // ${ATSHOME}/utils/scripts/atscc_main.dats (* ****** ****** *) (* end of [params.hats] *) ats-lang-anairiats-0.2.11/prelude/DATS/0000700000175000017500000000000012223166162016154 5ustar hwxihwxiats-lang-anairiats-0.2.11/prelude/DATS/array.dats0000664000175000017500000006101312223166162020164 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{^ #include "prelude/CATS/array.cats" %} // end of [%{^] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no dynamic staloading #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/array.sats" (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) (* array pointers *) (* ****** ****** *) extern praxi lemma_array_param {a:viewt@ype} {n:int} {l:addr} (pf: !array_v (a, n, l)): [n>=0;l>null] void // end of [lemma_array_param] (* ****** ****** *) implement{a} array_ptr_get_elt_at (A, i) = A.[i] implement{a} array_ptr_set_elt_at (A, i, x) = (A.[i] := x) implement{a} array_ptr_xch_elt_at (A, i, x) = let var tmp: a // uninitialized val (pf, fpf | p) = array_ptr_takeout_tsz (view@ A | &A, i, sizeof) val () = (tmp := !p; !p := x); prval () = view@ A := fpf pf in x := tmp end // end of [array_ptr_xch_elt_at] implement{a} array_ptr_exch (A, i, j) = if i != j then let var tmp: a // uninitialized extern prfun __copy {l:addr} (pf: !a @ l): a @ l val (pf, fpf | pi) = array_ptr_takeout_tsz (view@ A | &A, i, sizeof) prval pfi = __copy (pf) prval () = view@ A := fpf (pf) val (pf, fpf | pj) = array_ptr_takeout_tsz (view@ A | &A, j, sizeof) prval pfj = __copy (pf) prval () = view@ A := fpf (pf) val () = (tmp := !pi; !pi := !pj; !pj := tmp) extern prfun __free {l:addr} (pf: a @ l): void prval () = __free (pfi) prval () = __free (pfj) in // nothing end // end of [array_ptr_exch] (* ****** ****** *) // // These functions are present solely for notational convenience: // implement{a} array_ptr_get_elt_at__intsz (A, i) = let val i = i2sz i in A.[i] end implement{a} array_ptr_set_elt_at__intsz (A, i, x) = let val i = i2sz i in A.[i] := x end implement{a} array_ptr_xch_elt_at__intsz (A, i, x) = let val i = i2sz i in array_ptr_xch_elt_at (A, i, x) end // end of [array_ptr_xch_elt_at__intsz] implement{a} array_ptr_exch__intsz (A, i, j) = let val i = i2sz i and j = i2sz j in array_ptr_exch (A, i, j) end // end of [array_ptr_exch__intsz] (* ****** ****** *) implement{a} array_ptr_alloc (asz) = array_ptr_alloc_tsz {a} (asz, sizeof) (* ****** ****** *) implement{a} array_ptr_allocfree (asz) = let val [l:addr] (pfgc, pfarr | p_arr) = array_ptr_alloc (asz) in #[l | ( pfarr | p_arr, lam (pfarr | p_arr) = array_ptr_free {a?} (pfgc, pfarr | p_arr) ) ] end // end of [array_ptr_allocfree] (* ****** ****** *) implement{a} array_ptr_free_fun (pfgc, pfarr | p, asz, f) = let val () = array_ptr_clear_fun (!p, asz, f) in array_ptr_free {a?} (pfgc, pfarr | p) end // end of [array_ptr_free_fun] (* ****** ****** *) implement{a} array_ptr_initialize_elt (A0, n0, x0) = let // prval () = lemma_array_param {a?} (view@ (A0)) // fun loop {n:nat} {l:addr} .. (pf: array_v (a?, n, l) | p: ptr l, n: size_t n, x0: a) :<> (array_v (a, n, l) | void) = if n > 0 then let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := x0 val (pf2 | ans) = loop (pf2 | p+sizeof, n-1, x0) in (array_v_cons {a} (pf1, pf2) | ans) end else let prval () = array_v_unnil {a?} (pf) in (array_v_nil {a} () | ()) end // end of [if] // end of [loop] val (pf | ()) = loop (view@ A0 | &A0, n0, x0) in view@ A0 := pf end // end of [array_ptr_initialize_elt] (* ****** ****** *) implement{a} array_ptr_initialize_lst (A0, xs0) = let // prval () = lemma_array_param {a?} (view@ (A0)) // fun loop {n:nat} {l:addr} .. ( pf: array_v (a?, n, l) | p: ptr l, xs: list (a, n) ) :<> ( array_v (a, n, l) | void ) = case+ xs of | list_cons (x, xs) => let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := x val (pf2 | ans) = loop (pf2 | p+sizeof, xs) in (array_v_cons {a} (pf1, pf2) | ans) end // end of [list_cons] | list_nil () => let prval () = array_v_unnil {a?} (pf) in (array_v_nil {a} () | ()) end // end of [list_nil] // end of [loop] val (pf | ()) = loop (view@ A0 | &A0, xs0) in view@ A0 := pf end // end of [array_ptr_initialize_lst] (* ****** ****** *) implement{a} array_ptr_initialize_lst_vt (A0, xs0) = let // prval () = lemma_array_param {a?} (view@ (A0)) // fun loop {n:nat} {l:addr} .. ( pf: array_v (a?, n, l) | p: ptr l, xs: list_vt (a, n) ) :<> ( array_v (a, n, l) | void ) = case+ xs of | ~list_vt_cons (x, xs) => let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := x val (pf2 | ans) = loop (pf2 | p+sizeof, xs) in (array_v_cons {a} (pf1, pf2) | ans) end (* end of [lsit_vt_cons] *) | ~list_vt_nil () => let prval () = array_v_unnil {a?} (pf) in (array_v_nil {a} () | ()) end (* end of [list_vt_nil] *) // end of [loop] val (pf | ()) = loop (view@ A0 | &A0, xs0) in view@ A0 := pf end // end of [array_ptr_initialize_lst_vt] (* ****** ****** *) implement array_ptr_initialize_funenv_tsz {a} {v} {vt} {n} {f:eff} (pf | base, asz, f, tsz, env) = let fun loop {i:nat | i <= n} {l:addr} .. ( pfv: !v, pfarr: !array_v (a?, n-i, l) >> array_v (a, n-i, l) | p: ptr l, n: size_t n, i: size_t i , f: (!v | sizeLt n, &(a?) >> a, !vt) - void, tsz: sizeof_t a, env: !vt ) : void = if i < n then let prval (pf1_at, pf2_arr) = array_v_uncons {a?} (pfarr) val () = f (pfv | i, !p, env) val () = loop (pfv, pf2_arr | p + tsz, n, i+1, f, tsz, env) prval () = pfarr := array_v_cons {a} (pf1_at, pf2_arr) in // nothing end else let prval () = array_v_unnil (pfarr) prval () = pfarr := array_v_nil {a} () in // nothing end // end of [if] // end of [loop] in loop (pf, view@ base | &base, asz, 0, f, tsz, env) end // end of [array_ptr_initialize_funenv_tsz] implement{a} array_ptr_initialize_fun {n} {f:eff} (base, asz, f) = let // typedef fun_t = (sizeLt n, &(a?) >> a) - void typedef fun1_t = (!unit_v | sizeLt n, &(a?) >> a, !ptr) - void val f1 = coerce (f) where { extern castfn coerce (f: fun_t):<> fun1_t } // end of [val] // prval pfu = unit_v () val () = array_ptr_initialize_funenv_tsz {a} {unit_v} {ptr} (pfu | base, asz, f1, sizeof, null) prval unit_v () = pfu // in // empty end // end of [array_ptr_initialize_fun_tsz] (* ****** ****** *) implement array_ptr_initialize_cloenv_tsz {a} {v} {vt} {n} {f:eff} (pf | base, asz, f, tsz, env) = let fun loop {i:nat | i <= n} {l:addr} .. ( pfv: !v, pfarr: !array_v (a?, n-i, l) >> array_v (a, n-i, l) | p: ptr l, n: size_t n, i: size_t i , f: &(!v | sizeLt n, &(a?) >> a, !vt) - void, tsz: sizeof_t a, env: !vt ) : void = if i < n then let prval (pf1_at, pf2_arr) = array_v_uncons {a?} (pfarr) val () = f (pfv | i, !p, env) val () = loop (pfv, pf2_arr | p + tsz, n, i+1, f, tsz, env) prval () = pfarr := array_v_cons {a} (pf1_at, pf2_arr) in // nothing end else let prval () = array_v_unnil (pfarr) prval () = pfarr := array_v_nil {a} () in // nothing end // end of [if] // end of [loop] in loop (pf, view@ base | &base, asz, 0, f, tsz, env) end // end of [array_ptr_initialize_cloenv_tsz] implement{a} array_ptr_initialize_vclo {v} {n} {f:eff} (pf | base, asz, f) = let val p_f = &f; prval pf_f = view@ f viewtypedef clo_t = (!v | sizeLt n, &(a?) >> a) - void viewtypedef clo1_t = (!v | sizeLt n, &(a?) >> a, !ptr) - void prval pf1_f = coerce (pf_f) where { extern praxi coerce {l:addr} (pf: clo_t @ l): clo1_t @ l } // end of [prval] val () = array_ptr_initialize_cloenv_tsz {a} {v} {ptr} (pf | base, asz, !p_f, sizeof, null) prval pf_f = coerce (pf1_f) where { extern praxi coerce {l:addr} (pf: clo1_t @ l): clo_t @ l } // end of [prval] prval () = view@ f := pf_f in // empty end // end of [array_ptr_initialize_vclo] (* ****** ****** *) implement{a} array_ptr_clear_fun {n} {f:eff} (base, asz, f) = let // prval () = lemma_array_param {a} (view@ (base)) // fun clear {n:nat} {l:addr} .. ( pf_arr: !array_v (a, n, l) >> array_v (a?, n, l) | p_arr: ptr l, n: size_t n , f: (&a >> a?) - void, tsz: sizeof_t a ) : void = if n > 0 then let prval (pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) val () = f (!p_arr) val () = clear (pf2_arr | p_arr + tsz, n-1, f, tsz) in pf_arr := array_v_cons {a?} (pf1_at, pf2_arr) end else let prval () = array_v_unnil {a} (pf_arr) in pf_arr := array_v_nil {a?} () end // end of [if] // end of [clear] in clear (view@ base | &base, asz, f, sizeof) end // end of [array_ptr_clear_fun] (* ****** ****** *) implement{a} array_ptr_split (pf | A, i) = array_ptr_split_tsz {a} (pf | A, i, sizeof) // end of [array_ptr_split] (* ****** ****** *) implement{a} array_ptr_takeout (pf | A, i) = array_ptr_takeout_tsz {a} (pf | A, i, sizeof) // end of [array_ptr_takeout] (* ****** ****** *) infixl ( * ) szmul2 implement{a} array_ptr_takeout2 (pf | A, i1, i2) = array_ptr_takeout2_tsz {a} (pf | A, i1, i2, sizeof ) // end of [array_ptr_takeout2] implement array_ptr_takeout2_tsz {a} {n} {i1,i2} {l0} (pf | A, i1, i2, tsz) = let val [off1:int] (pf1_mul | off1) = i1 szmul2 tsz val [off2:int] (pf2_mul | off2) = i2 szmul2 tsz prval (pf1, pf2, fpf) = array_v_takeout2 {a} (pf1_mul, pf2_mul, pf) in #[ l0+off1, l0+off2 | (pf1, pf2, fpf | A+off1, A+off2) ] end // end of [array_ptr_takeout2_tsz] (* ****** ****** *) // // HX: array of arrays: this may just be a curiosity // implement{a} array2_ptr_takeout (pf | A, i, n) = array2_ptr_takeout_tsz {a} (pf | A, i, n, sizeof) // end of [array2_ptr_takeout] (* ****** ****** *) // // HX: persistent arrays that can only be reclaimed by GC // (* ****** ****** *) assume array_viewt0ype_int_type (a:viewt@ype, n:int) = [l:addr] @{ data= ptr l, view= vbox (array_v (a, n, l)) } // end of [array_viewt0ype_int_type] (* viewtypedef arrayptrsize_viewt0ype_int_viewt0ype (a: viewt@ype, n:int) = [l:addr] (free_gc_v l, @[a][n] @ l | ptr l, int n) // end of [arrayptrsize_viewt0ype_int_viewt0ype] *) implement array_make_arrpsz {a}{n} (psz) = let prval () = free_gc_elim {a?} (psz.0) // return the certificate val (pfbox | ()) = vbox_make_view_ptr (psz.1 | psz.2) in @{ data= psz.2, view= pfbox } end // end of [array_make_arrpsz] (* ****** ****** *) implement{a} array_make_elt (asz, x) = let val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC val () = array_ptr_initialize_elt (!p_arr, asz, x) val (pfbox | ()) = vbox_make_view_ptr (pfarr | p_arr) in @{ data= p_arr, view= pfbox } end // end of [array_make_elt] implement{a} array_make_lst (asz, xs) = let val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC val () = array_ptr_initialize_lst (!p_arr, xs) val (pfbox | ()) = vbox_make_view_ptr (pfarr | p_arr) in @{ data= p_arr, view= pfbox } end // end of [array_make_lst] implement{a} array_make_lst_vt (asz, xs) = let val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC val () = array_ptr_initialize_lst_vt (!p_arr, xs) val (pfbox | ()) = vbox_make_view_ptr (pfarr | p_arr) in @{ data= p_arr, view= pfbox } end // end of [array_make_lst_vt] (* ****** ****** *) implement{a} array_make_vclo (pf | asz, f) = let val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC val () = array_ptr_initialize_vclo (pf | !p_arr, asz, f) val (pfbox | ()) = vbox_make_view_ptr (pfarr | p_arr) in @{ data= p_arr, view= pfbox } end // end of [array_make_vclo] (* ****** ****** *) implement{a} array_make_cloref {n} {f:eff} (asz, f) = let // typedef cloref_t = (sizeLt n, &(a?) >> a) - void // val (pfgc, pfarr | p_arr) = array_ptr_alloc (asz) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC // prval pfu = unit_v () val () = let val app = lam ( pf: !unit_v | i: sizeLt n, x: &(a?) >> a, f: !cloref_t ) : void = f (i, x) // end of [val] in array_ptr_initialize_funenv_tsz {a} {unit_v} {cloref_t} (pfu | !p_arr, asz, app, sizeof, f) // end of ... end // end of [val] prval unit_v () = pfu // val (pfbox | ()) = vbox_make_view_ptr (pfarr | p_arr) in @{ data= p_arr, view= pfbox } end // end of [array_make_cloref] (* ****** ****** *) (* // // HX: these are now casting funtions: // implement array_make_view_ptr (pf | p) = @(pf | p) implement array_get_view_ptr (A) = @(A.view | A.data) *) (* ****** ****** *) implement{a} array_get_elt_at (A, i) = let val A_data = A.data; prval vbox pf = A.view in !A_data.[i] end // end of [array_get_elt] implement{a} array_set_elt_at (A, i, x) = let val A_data = A.data; prval vbox pf = A.view in !A_data.[i] := x end // end of [array_set_elt_at] implement{a} array_xch_elt_at (A, i, x) = let val A_data = A.data; prval vbox pf = A.view in array_ptr_xch_elt_at (!A_data, i, x) end // end of [array_xch_elt_at] (* ****** ****** *) implement{a} array_get_elt_at__intsz (A, i) = let val i = i2sz i; val A_data = A.data; prval vbox pf = A.view in !A_data.[i] end // end of [array_get_elt] implement{a} array_set_elt_at__intsz (A, i, x) = let val i = i2sz i; val A_data = A.data; prval vbox pf = A.view in !A_data.[i] := x end // end of [array_set_elt_at] implement{a} array_xch_elt_at__intsz (A, i, x) = let val i = i2sz i; val A_data = A.data; prval vbox pf = A.view in array_ptr_xch_elt_at (!A_data, i, x) end // end of [array_xch_elt_at] (* ****** ****** *) implement{a} array_exch (A, i1, i2) = if i1 <> i2 then let val A_data = A.data; prval vbox pf = A.view in array_ptr_exch (!A_data, i1, i2) end // end of [if] // end of [array_exch] implement{a} array_exch__intsz (A, i1, i2) = let val i1 = i2sz (i1) and i2 = i2sz (i2) in if i1 <> i2 then let val A_data = A.data; prval vbox pf = A.view in array_ptr_exch (!A_data, i1, i2) end // end of [if] end // end of [array_exch__intsz] (* ****** ****** *) // various [foreach] functions on linear arrays (* ****** ****** *) implement array_ptr_foreach_funenv_tsz {a} {v} {vt} {n} {f:eff} (pf | base, f, asz, tsz, env) = let fun loop {i:nat | i <= n} {l:addr} .. ( pfv: !v, pf_arr: !array_v (a, i, l) >> array_v (a, i, l) | p: ptr l , f: (!v | &a, !vt) - void, i: size_t i, tsz: sizeof_t a , env: !vt ) : void = if i > 0 then let prval (pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) val () = f (pfv | !p, env) val () = loop (pfv, pf2_arr | p + tsz, f, i-1, tsz, env) prval () = pf_arr := array_v_cons {a} (pf1_at, pf2_arr) in // nothing end else let prval () = array_v_unnil (pf_arr) prval () = pf_arr := array_v_nil {a} () in // nothing end // end of [if] in loop (pf, view@ base | &base, f, asz, tsz, env) end // end of [array_ptr_foreach_funenv_tsz] (* ****** ****** *) implement{a} array_ptr_foreach_fun {n} {f:eff} (A, f, asz) = let // viewtypedef fun0_t = (&a) - void viewtypedef fun1_t = (!unit_v | &a, !ptr) - void // val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } // prval pfu = unit_v () val () = array_ptr_foreach_funenv_tsz {a} {unit_v} {ptr} (pfu | A, f, asz, sizeof, null) prval unit_v () = pfu // in // nothing end // end of [array_ptr_foreach_fun] (* ****** ****** *) implement{a} array_ptr_foreach_vclo {v} {n} {f:eff} (pfv | A, f, asz) = let // viewtypedef clo_t = (!v | &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) // fn app (pf: !V | x: &a, p_f: !ptr l_f): void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | x) in pf := (pf1, pf2) end // end of [app] // prval pf = (pfv, view@ f) val () = array_ptr_foreach_funenv_tsz {a} {V} {ptr l_f} (pf | A, app, asz, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) in // empty end // end of [array_ptr_foreach_vclo] (* ****** ****** *) implement array_ptr_iforeach_funenv_tsz {a} {v} {vt} {n} {f:eff} (pf | base, f, asz, tsz, env) = let fun loop {i:nat | i <= n} {l:addr} .. ( pfv: !v, pf_arr: !array_v (a, n-i, l) >> array_v (a, n-i, l) | p: ptr l , f: (!v | sizeLt n, &a, !vt) - void, n: size_t n, i: size_t i , tsz: sizeof_t a, env: !vt ) : void = if i < n then let prval (pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) val () = f (pfv | i, !p, env) val () = loop (pfv, pf2_arr | p + tsz, f, n, i+1, tsz, env) prval () = pf_arr := array_v_cons {a} (pf1_at, pf2_arr) in // nothing end else let prval () = array_v_unnil (pf_arr) prval () = pf_arr := array_v_nil {a} () in // nothing end // end of [if] in loop (pf, view@ base | &base, f, asz, 0, tsz, env) end // end of [array_ptr_iforeach_funenv_tsz] (* ****** ****** *) implement{a} array_ptr_iforeach_fun {n} {f:eff} (A, f, asz) = let // viewtypedef fun0_t = (sizeLt n, &a) - void viewtypedef fun1_t = (!unit_v | sizeLt n, &a, !ptr) - void val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } // prval pfu = unit_v () val () = array_ptr_iforeach_funenv_tsz {a} {unit_v} {ptr} (pfu | A, f, asz, sizeof, null) prval unit_v () = pfu // in // nothing end // end of [array_ptr_foreach_fun] (* ****** ****** *) implement{a} array_ptr_iforeach_clo {n} {f:eff} (A, f, asz) = let typedef clo0_t = (sizeLt n, &a) - void typedef clo1_t = (!unit_v | sizeLt n, &a) - void prval () = __assert(f) where { extern prfun __assert (f: !clo0_t >> clo1_t): void } // end of [val] prval pfu = unit_v () val () = array_ptr_iforeach_vclo {unit_v} (pfu | A, f, asz) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !clo1_t >> clo0_t): void } // end of [val] in // nothing end // end of [array_ptr_iforeach_clo] implement{a} array_ptr_iforeach_vclo {v} {n} {f:eff} (pfv | A, f, asz) = let // viewtypedef clo_t = (!v | sizeLt n, &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) // fn app ( pf: !V | i: sizeLt n, x: &a, p_f: !ptr l_f ) : void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | i, x) in pf := (pf1, pf2) end // end of [app] // prval pf = (pfv, view@ f) val () = array_ptr_iforeach_funenv_tsz {a} {V} {ptr l_f} (pf | A, app, asz, sizeof, p_f) prval (pf1, pf2) = pf // prval () = (pfv := pf1; view@ f := pf2) in // empty end // end of [array_ptr_iforeach_vclo] (* ****** ****** *) // // HX: various [foreach] functions on persistent arrays // (* ****** ****** *) implement{a} array_foreach_funenv {v} {vt} {n} (pfv | A, f, asz, env) = let val (vbox pfarr | p) = array_get_view_ptr (A) in array_ptr_foreach_funenv_tsz (pfv | !p, f, asz, sizeof, env) end // end of [array_foreach_funenv] implement{a} array_foreach_fun {n} (A, f, asz) = let val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void):<> (!unit_v | &a, !ptr) -<> void } // end of [where] // prval pfu = unit_v () val () = array_foreach_funenv {unit_v} {ptr} (pfu | A, f, asz, null) prval unit_v () = pfu in // nothing end // end of [array_foreach_fun] implement{a} array_foreach_vclo {v} {n} (pfv | A, f, asz) = let stavar l_f: addr typedef clo_t = (!v | &a) - void val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf in !p_f (pf1 | x); pf := (pf1, pf2) end // end of [app] prval pf = (pfv, view@ f) val () = array_foreach_funenv {V} {ptr l_f} (pf | A, app, asz, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) in // empty end // end of [array_foreach_vclo] implement{a} array_foreach_cloref {n} (A, f, asz) = let viewtypedef cloref_t = (&a) - void fn app (pf: !unit_v | x: &a, f: !cloref_t):<> void = $effmask_all (f x) prval pf = unit_v () val () = array_foreach_funenv {unit_v} {cloref_t} (pf | A, app, asz, f) prval unit_v () = pf in // empty end // end of [array_foreach_cloref] (* ****** ****** *) implement{a} array_iforeach_funenv {v} {vt} {n} (pfv | A, f, asz, env) = let val (vbox pfarr | p) = array_get_view_ptr (A) in array_ptr_iforeach_funenv_tsz (pfv | !p, f, asz, sizeof, env) end // end of [array_iforeach_funenv] implement{a} array_iforeach_fun {n} (A, f, asz) = let val f = coerce (f) where { extern castfn coerce (f: (sizeLt n, &a) -<> void):<> (!unit_v | sizeLt n, &a, !ptr) -<> void } // end of [val] // prval pfu = unit_v () val () = array_iforeach_funenv {unit_v} {ptr} (pfu | A, f, asz, null) prval unit_v () = pfu // in // nothing end // end of [array_foreach_fun] implement{a} array_iforeach_vclo {v} {n} (pfv | A, f, asz) = let stavar l_f: addr typedef clo_t = (!v | sizeLt n, &a) - void val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) fn app (pf: !V | i: sizeLt n, x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf in !p_f (pf1 | i, x); pf := (pf1, pf2) end // end of [app] // prval pf = (pfv, view@ f) val () = array_iforeach_funenv {V} {ptr l_f} (pf | A, app, asz, p_f) prval (pf1, pf2) = pf // prval () = (pfv := pf1; view@ f := pf2) in // empty end // end of [array_iforeach_vclo] implement{a} array_iforeach_cloref {n} (A, f, asz) = let viewtypedef cloref_t = (sizeLt n, &a) - void fn app (pf: !unit_v | i: sizeLt n, x: &a, f: !cloref_t):<> void = f (i, x) prval pf = unit_v () val () = array_iforeach_funenv {unit_v} {cloref_t} (pf | A, app, asz, f) prval unit_v () = pf in // empty end // end of [array_iforeach_cloref] (* ****** ****** *) implement{a} array_ptr_alloc (n) = array_ptr_alloc_tsz {a} (n, sizeof) // end of [array_ptr_alloc] (* ****** ****** *) %{$ typedef unsigned char byte ; // // HX-2010-05-24 // In case 'memcpy' is already defined as a macro ... // #ifndef memcpy extern void *memcpy (void *dst, const void* src, size_t n) ; #endif // end of [memcpy] ats_void_type atspre_array_ptr_initialize_elt_tsz ( ats_ptr_type A , ats_size_type asz , ats_ptr_type ini , ats_size_type tsz ) { int i, itsz ; int left ; ats_ptr_type p ; if (asz == 0) return ; memcpy (A, ini, tsz) ; i = 1 ; itsz = tsz ; left = asz - i ; while (left > 0) { p = (ats_ptr_type)(((byte*)A) + itsz) ; if (left <= i) { memcpy (p, A, left * tsz) ; return ; } memcpy (p, A, itsz); i = i + i ; itsz = itsz + itsz ; left = asz - i ; } /* end of [while] */ return ; } /* end of [atspre_array_ptr_initialize_elt_tsz] */ %} // end of [%{$] (* ****** ****** *) // [array.sats] is already loaded by a call to [pervasive_load] staload _(*anonymous*) = "prelude/SATS/array.sats" // this forces that the static // loading function for [array.sats] is to be called at run-time // this is really needed only if some datatypes are declared in [array.sats] (* ****** ****** *) (* end of [array.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/matrix.dats0000664000175000017500000003211012223166162020346 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{^ #include "prelude/CATS/array.cats" %} // end of [%{^] (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/matrix.sats" (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) local (* assume matrix_v (a:viewt@ype, m:int, n:int, l:addr) = [mn:int | m >= 0; n >= 0] (MUL (m, n, mn), array_v (a, mn, l)) // end of [assume] *) assume mtrxt (a:viewt@ype, m:int, n:int) = @[@[a][n]][m] in // in of [local] implement array_v_of_matrix_v {a} {m,n} (pfmat) = let prval pfmn = mul_istot {m,n} () prval () = mul_nat_nat_nat (pfmn) prval pfarr = array_v_ungroup (pfmn, pfmat) in (pfmn, pfarr) end // end of [array_v_of_matrix_v] implement matrix_v_of_array_v (pf_mul, pfarr) = array_v_group (pf_mul, pfarr) // end of [matrix_v_of_array_v] end // end of [local] (* ****** ****** *) implement{a} matrix_ptr_takeout_row (pf | p, i, n) = matrix_ptr_takeout_row_tsz (pf | p, i, n, sizeof) // end of [matrix_ptr_takeout_row] implement{a} matrix_ptr_takeout_elt (pf | p, i, n, j) = matrix_ptr_takeout_elt_tsz (pf | p, i, n, j, sizeof) // end of [matrix_ptr_takeout_elt] (* ****** ****** *) (* ** ** persistent matrices ** *) (* ****** ****** *) assume matrix_viewt0ype_int_int_type (a:viewt@ype, m:int, n:int) = [l:addr] @{ data= ptr l, view= vbox (matrix_v (a, m, n, l)) } // end of [matrix_viewt0ype_int_int_type] (* ****** ****** *) extern fun vbox_make_view_ptr_matrix {a:viewt@ype} {m,n:int} {l:addr} ( pf: matrix_v (a, m, n, l) | p: ptr l ) :<> (vbox (matrix_v (a, m, n, l)) | void)= "atspre_vbox_make_view_ptr" // end of [vbox_make_view_ptr_matrix] (* ****** ****** *) implement matrix_make_arrpsz {a} {m,n} (m, n, psz) = let prval pfmul = mul_istot {m,n} () prval () = mul_elim (pfmul) in matrix_make_arrpsz__main {a} (pfmul | m, n, psz) end // end of [matrix_make_arrpsz] implement matrix_make_arrpsz__main {a} (pfmul | m, n, psz) = let prval () = free_gc_elim {a?} (psz.0) // return the certificate prval pfmat = matrix_v_of_array_v (pfmul, psz.1) val (pfmat_box | ()) = vbox_make_view_ptr_matrix (pfmat | psz.2) in @{ data= psz.2, view= pfmat_box } end // end of [matrix_make_arrsize__main] (* ****** ****** *) implement{a} matrix_make_elt (m, n, x) = let val (pf_mul | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat pf_mul val (pfgc, pfarr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) // end of [val] prval () = free_gc_elim {a?} (pfgc) // return the certificate val () = array_ptr_initialize_elt (!p_arr, mn, x) prval pfmat = matrix_v_of_array_v (pf_mul, pfarr) val (pfmat_box | ()) = vbox_make_view_ptr_matrix (pfmat | p_arr) in @{ data= p_arr, view= pfmat_box } end // end of [matrix_make_elt] (* ****** ****** *) %{^ #define atspre_matrix_szdiv(i, n) (i / n) %} extern fun szdiv {m,n:pos; mn,i:nat | i < mn} ( pf: MUL (m, n, mn) | i: size_t i, n: size_t n ) :<> [d:nat | d < m] size_t d = "mac#atspre_matrix_szdiv" // macro! // end of [szdiv] (* ****** ****** *) infixl ( * ) szmul2; infixl ( mod ) szmod1 implement matrix_make_funenv_tsz {a} {v} {vt} {m,n} {f:eff} (pf | m, n, f, tsz, env) = let val [mn:int] (pf_mul | mn) = m szmul2 n prval () = mul_nat_nat_nat pf_mul val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (mn, tsz) prval () = free_gc_elim {a?} (pfgc) // return the certificate to GC viewtypedef fun_t = (!v | &(a?) >> a, sizeLt m, natLt n, !vt) -<> void var !p_f1 = @lam (pf: !v | i: sizeLt mn, x: &(a?) >> a, env: !vt): void = let val d = szdiv (pf_mul | i, n) and r = i szmod1 n in f (pf | d, r, x, env) end // end of [f1] val () = begin array_ptr_initialize_cloenv_tsz {a} {v} {vt} (pf | !p_arr, mn, !p_f1, tsz, env) end // end of [val] prval pfmat = matrix_v_of_array_v (pf_mul, pfarr) val (pfmat_box | ()) = vbox_make_view_ptr_matrix (pfmat | p_arr) in @{ data= p_arr, view= pfmat_box } end // end of [matrix_make_funenv_tsz] implement{a} matrix_make_fun {m,n} {f:eff} (m, n, f) = let typedef fun0_t = (sizeLt m, sizeLt n, &(a?) >> a) - void typedef fun1_t = (!unit_v | sizeLt m, sizeLt n, &(a?) >> a, !ptr) - void val f = coerce (f) where { extern castfn coerce (f: fun0_t):<> fun1_t } // end of [val] // prval pfu = unit_v () val M = matrix_make_funenv_tsz {a} {unit_v} {ptr} (pfu | m, n, f, sizeof, null) prval unit_v () = pfu // in M // : matrix (a, m, n) end // end of [matrix_make_fun_tsz] implement{a} matrix_make_vclo {v} {m,n} {f:eff} (pfv | m, n, f) = M where { // stavar l_f: addr val p_f: ptr l_f = &f // typedef clo_t = (!v | sizeLt m, sizeLt n, &(a?) >> a) - void // end of [typedef] viewdef V = (v, clo_t @ l_f) // fn app ( pf: !V | i: sizeLt m, j: sizeLt n, x: &(a?) >> a, p_f: !ptr l_f ) : void = let prval pfclo = pf.1 // HX: taking it out to support [!p_f] val () = !p_f (pf.0 | i, j, x) prval () = pf.1 := pfclo in // nothing end // end of [app] // prval pfV = (pfv, view@ f) val M = matrix_make_funenv_tsz {a} {V} {ptr l_f} (pfV | m, n, app, sizeof, p_f) prval () = (pfv := pfV.0; view@ f := pfV.1) } // end of [matrix_make_vclo] (* ****** ****** *) local (* // // HX-2011-02-26: commented out // prfun lemma_for_matrix_subscripting {m,n:nat} {i:nat | i < m} {mn,p:int} .. (pf1: MUL (m, n, mn), pf2: MUL (i, n, p)): [p+n <= mn] void = let prval MULind pf11 = pf1 in sif i < m-1 then begin lemma_for_matrix_subscripting (pf11, pf2) end else let // i = m-1 prval () = mul_isfun (pf11, pf2) in // empty end // end of [sif] end // end of [lemma_for_matrix_subscripting] *) in // in of [local] implement{a} matrix_get_elt_at (M, i, n, j) = let prval vbox pfmat = M.view val (pfat, fpfmat | p) = matrix_ptr_takeout_elt (pfmat | M.data, i, n, j) val x = !p prval () = pfmat := fpfmat (pfat) in x // return value end // end of [matrix_get_elt_at] implement{a} matrix_set_elt_at (M, i, n, j, x) = let prval vbox pfmat = M.view val (pfat, fpfmat | p) = matrix_ptr_takeout_elt (pfmat | M.data, i, n, j) val () = !p := x prval () = pfmat := fpfmat (pfat) in // empty end // end of [matrix_set_elt_at] end // end of [local] (* ****** ****** *) implement{a} matrix_get_elt_at__intsz (M, i, n, j) = let val i = i2sz i; val n = i2sz n; val j = i2sz j in matrix_get_elt_at (M, i, n, j) end // end of [matrix_get_elt_at__intsz] implement{a} matrix_set_elt_at__intsz (M, i, n, j, x) = let val i = i2sz i; val n = i2sz n; val j = i2sz j in matrix_set_elt_at (M, i, n, j, x) end // end of [matrix_set_elt_at__intsz] (* ****** ****** *) implement{a} matrix_foreach_funenv {v} {vt} {m,n} (pf | M, f, m, n, env) = let typedef fun_t = (!v | &a, !vt) - void typedef mat_t = matrix (a, m, n) // fn* loop1 {i:nat | i <= m} .. ( pf: !v | M: mat_t , f: fun_t, m: size_t m, n: size_t n, i: size_t i , env: !vt ) : void = begin if i < m then loop2 (pf | M, f, m, n, i, 0, env) else () end // end of [loop1] // and loop2 {i,j:nat | i < m; j <= n} .. ( pf: !v | M: mat_t , f: fun_t, m: size_t m, n: size_t n, i: size_t i, j: size_t j , env: !vt ) : void = begin if j < n then let val () = () where { prval vbox pfmat = M.view val (pf1, fpf2 | p_ij) = matrix_ptr_takeout_elt_tsz (pfmat | M.data, i, n, j, sizeof) val () = f (pf | !p_ij, env) val () = pfmat := fpf2 (pf1) } // end of [val] in loop2 (pf | M, f, m, n, i, j+1, env) end else begin loop1 (pf | M, f, m, n, i+1, env) end end // end of [loop2] // in loop1 (pf | M, f, m, n, 0, env) end // end of [matrix_foreach_funenv] implement{a} matrix_foreach_fun {m,n} (M, f, m, n) = let // val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void):<> (!unit_v | &a, !ptr) -<> void } // end of [where] // prval pfu = unit_v () val () = matrix_foreach_funenv {unit_v} {ptr} (pfu | M, f, m, n, null) prval unit_v () = pfu // in // nothing end // end of [matrix_foreach_fun] implement{a} matrix_foreach_vclo {v} {m,n} (pfv | M, f, m, n) = let // stavar l_f: addr val p_f: ptr l_f = &f // typedef clo_t = (!v | &a) - void viewdef V = @(v, clo_t @ l_f) fn app ( pf: !V | x: &a, p_f: !ptr l_f ) :<> void = let prval pfclo = pf.1 in !p_f (pf.0 | x); pf.1 := pfclo end // end of [app] // prval pf = (pfv, view@ f) val () = matrix_foreach_funenv {V} {ptr l_f} (pf | M, app, m, n, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) // in // empty end // end of [matrix_foreach_vclo] implement{a} matrix_foreach_cloref {m,n} (M, f, m, n) = let viewtypedef cloref_t = (&a) - void fn app (pf: !unit_v | x: &a, f: !cloref_t):<> void = f (x) prval pf = unit_v () val () = matrix_foreach_funenv {unit_v} {cloref_t} (pf | M, app, m, n, f) prval unit_v () = pf in // empty end // end of [matrix_foreach_cloref] (* ****** ****** *) implement{a} matrix_iforeach_funenv {v} {vt} {m,n} (pf | M, f, m, n, env) = let // typedef fun_t = (!v | sizeLt m, sizeLt n, &a, !vt) - void typedef mat_t = matrix (a, m, n) // fn* loop1 {i:nat | i <= m} .. (pf: !v | M: mat_t, f: fun_t, m: size_t m, n: size_t n, i: size_t i, env: !vt) : void = begin if i < m then loop2 (pf | M, f, m, n, i, 0, env) else () end // end of [loop1] // and loop2 {i,j:nat | i < m; j <= n} .. ( pf: !v | M: mat_t, f: fun_t, m: size_t m, n: size_t n, i: size_t i, j: size_t j, env: !vt ) : void = begin if j < n then let val () = () where { prval vbox pfmat = M.view val (pf1, fpf2 | p_ij) = matrix_ptr_takeout_elt_tsz (pfmat | M.data, i, n, j, sizeof) val () = f (pf | i, j, !p_ij, env) val () = pfmat := fpf2 (pf1) } // end of [val] in loop2 (pf | M, f, m, n, i, j+1, env) end else begin loop1 (pf | M, f, m, n, i+1, env) end (* end of [if] *) end // end of [loop2] // in loop1 (pf | M, f, m, n, 0, env) end // end of [matrix_iforeach_funenv] implement{a} matrix_iforeach_fun {m,n} (M, f, m, n) = let // val f = coerce (f) where { extern castfn coerce ( f: (sizeLt m, sizeLt n, &a) -<> void ) :<> (!unit_v | sizeLt m, sizeLt n, &a, !ptr) -<> void } // end of [where] // prval pfu = unit_v () val () = matrix_iforeach_funenv {unit_v} {ptr} (pfu | M, f, m, n, null) prval unit_v () = pfu // in // nothing end // end of [matrix_iforeach_fun] implement{a} matrix_iforeach_vclo {v} {m,n} (pfv | M, f, m, n) = let // stavar l_f: addr val p_f: ptr l_f = &f // typedef clo_t = (!v | sizeLt m, sizeLt n, &a) - void viewdef V = @(v, clo_t @ l_f) // fn app ( pf: !V | i: sizeLt m, j: sizeLt n, x: &a, p_f: !ptr l_f ) :<> void = let prval pfclo = pf.1 val () = !p_f (pf.0 | i, j, x) prval () = pf.1 := pfclo in // nothing end // end of [app] // prval pf = (pfv, view@ f) val () = matrix_iforeach_funenv {V} {ptr l_f} (pf | M, app, m, n, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) // in // empty end // end of [matrix_iforeach_vclo] implement{a} matrix_iforeach_cloref {m,n} (M, f, m, n) = let // viewtypedef cloref_t = (sizeLt m, sizeLt n, &a) - void // prval pf = unit_v () fn app ( pf: !unit_v | i: sizeLt m, j: sizeLt n, x: &a, f: !cloref_t ) :<> void = $effmask_all (f (i, j, x)) // end of [app] val () = matrix_iforeach_funenv {unit_v} {cloref_t} (pf | M, app, m, n, f) prval unit_v () = pf // in // empty end // end of [matrix_iforeach_cloref] (* ****** ****** *) (* end of [matrix.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/array_prf.dats0000664000175000017500000001562212223166162021040 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/array.sats" (* ****** ****** *) // // HX: code implementing prfun functions manipulating array views // (* ****** ****** *) implement array_v_sing {a} (pf) = array_v_cons {a} (pf, array_v_nil ()) // end of [array_v_sing] implement array_v_unsing {a} (pf) = pf1 where { prval (pf1, pf2) = array_v_uncons {a} (pf) prval () = array_v_unnil (pf2) } // end of [array_v_unsing] (* ****** ****** *) implement array_v_split {a} (pf_mul, pf_arr) = split (pf_mul, pf_arr) where { prfun split {n,i:nat | i <= n} {l:addr} {ofs:int} .. (pf_mul: MUL (i, sizeof a, ofs), pf_arr: array_v (a, n, l)) : @(array_v (a, i, l), array_v (a, n-i, l+ofs)) = sif i > 0 then let prval @(pf1_elt, pf2_arr) = array_v_uncons {a} (pf_arr) // pf1_mul : MUL (i-1, sizeof a, ofs - sizeof a) prval pf1_mul = mul_add_const {~1} {i, sizeof a} (pf_mul) prval @(pf1_arr_res, pf2_arr_res) = split {n-1,i-1} (pf1_mul, pf2_arr) in @(array_v_cons {a} (pf1_elt, pf1_arr_res), pf2_arr_res) end else let prval MULbas () = pf_mul in (array_v_nil {a} {l} (), pf_arr) end // end of [sif] } // end of [array_v_split] (* ****** ****** *) implement array_v_unsplit {a} (pf_mul, pf1_arr, pf2_arr) = unsplit (pf_mul, pf1_arr, pf2_arr) where { // extern praxi lemma {n:int} {l:addr} (pf: !array_v (a, n, l)): [n>=0] void prval () = lemma (pf1_arr) and () = lemma (pf2_arr) // prfun unsplit {n1,n2:nat} {l:addr} {ofs:int} .. (pf_mul: MUL (n1, sizeof a, ofs), pf1_arr: array_v (a, n1, l), pf2_arr: array_v (a, n2, l+ofs)) : array_v (a, n1+n2, l) = sif n1 > 0 then let prval @(pf11_elt, pf12_arr) = array_v_uncons {a} (pf1_arr) // pf1_mul : MUL (n1-1, sizeof a, ofs - sizeof a) prval pf1_mul = mul_add_const {~1} {n1, sizeof a} (pf_mul) prval pf_arr_res = unsplit (pf1_mul, pf12_arr, pf2_arr) in array_v_cons {a} (pf11_elt, pf_arr_res) end else let prval () = array_v_unnil (pf1_arr); prval MULbas () = pf_mul in pf2_arr end // end of [sif] } // end of [array_v_unsplit] (* ****** ****** *) implement array_v_extend {a} (pf_mul, pf1_arr, pf2_at) = let prval pf2_arr = array_v_cons {a} (pf2_at, array_v_nil {a} ()) in array_v_unsplit {a} (pf_mul, pf1_arr, pf2_arr) end // end of [array_v_extend] implement array_v_unextend {a} (pf_mul, pf_arr) = unextend (pf_mul, pf_arr) where { prfun unextend {n:int | n > 0} {l:addr} {ofs:int} .. (pf_mul: MUL (n, sizeof a, ofs), pf_arr: array_v (a, n, l)) : (array_v (a, n-1, l), a @ l+ofs-sizeof a) = let prval @(pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) in sif n > 1 then let prval pf1_mul = mul_add_const {~1} {n, sizeof a} (pf_mul) prval @(pf21_arr, pf22_at) = unextend (pf1_mul, pf2_arr) in @(array_v_cons {a} (pf1_at, pf21_arr), pf22_at) end else let prval () = array_v_unnil (pf2_arr) prval () = mul_elim {1,sizeof a} (pf_mul) in (array_v_nil (), pf1_at) end // end of [sif] end // end of [unextend] } // end of [array_v_unextend] (* ****** ****** *) implement array_v_takeout {a} (pf_mul, pf_arr) = takeout (pf_mul, pf_arr) where { prfun takeout {n,i:nat | i < n} {l:addr} {ofs:int} .. (pf_mul: MUL (i, sizeof a, ofs), pf_arr: array_v (a, n, l)) : (a @ l+ofs, a @ l+ofs - array_v (a, n, l)) = let prval @(pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) in sif i > 0 then let prval pf1_mul = mul_add_const {~1} {i, sizeof a} (pf_mul) prval (pf_at_res, fpf_res) = takeout {n-1,i-1} (pf1_mul, pf2_arr) in (pf_at_res, lam pf_at = array_v_cons {a} (pf1_at, fpf_res pf_at)) end else let prval () = mul_elim {0,sizeof a} (pf_mul) in (pf1_at, lam pf_at = array_v_cons {a} (pf_at, pf2_arr)) end // end of [sif] end // end of takeout] } // end of [array_v_takeout] implement array_v_takeout2 {a} (pf1_mul, pf2_mul, pf_arr) = takeout2 (pf1_mul, pf2_mul, pf_arr) where { prfun takeout2 {n,i1,i2:nat | i1 < n; i2 < n; i1 <> i2} {l:addr} {ofs1,ofs2:int} .. (pf1_mul: MUL (i1, sizeof a, ofs1), pf2_mul: MUL (i2, sizeof a, ofs2), pf_arr: array_v (a, n, l)) : (a @ l+ofs1, a @ l+ofs2, (a @ l+ofs1, a @ l+ofs2) - array_v (a, n, l)) = let prval @(pf1_at, pf2_arr) = array_v_uncons {a} (pf_arr) in sif (i1 == 0) then let prval () = mul_elim {0,sizeof a} (pf1_mul) prval pf21_mul = mul_add_const {~1} {i2, sizeof a} (pf2_mul) prval (pf_at_res, fpf_res) = array_v_takeout {a} (pf21_mul, pf2_arr) in (pf1_at, pf_at_res, llam (_1, _2) = (array_v_cons {a} (_1, fpf_res (_2)))) end else sif (i2 == 0) then let prval pf11_mul = mul_add_const {~1} {i1, sizeof a} (pf1_mul) prval () = mul_elim {0,sizeof a} (pf2_mul) prval (pf_at_res, fpf_res) = array_v_takeout {a} (pf11_mul, pf2_arr) in (pf_at_res, pf1_at, lam (_1, _2) = (array_v_cons {a} (_2, fpf_res (_1)))) end else let prval pf11_mul = mul_add_const {~1} {i1, sizeof a} (pf1_mul) prval pf21_mul = mul_add_const {~1} {i2, sizeof a} (pf2_mul) prval (pf1_at_res, pf2_at_res, fpf_res) = takeout2 (pf11_mul, pf21_mul, pf2_arr) in (pf1_at_res, pf2_at_res, llam (_1, _2) = (array_v_cons {a} (pf1_at, fpf_res (_1, _2)))) end // end of [sif] end // end of [takeout2] } // end of [array_v_takeout2] (* ****** ****** *) (* end of [array_prf.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/list0.dats0000664000175000017500000002476112223166162020112 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) // // list0 implementation // (* ****** ****** *) staload "prelude/SATS/list0.sats" (* ****** ****** *) #define nil list0_nil #define cons list0_cons #define :: list0_cons (* ****** ****** *) implement{a} list0_of_arrpsz (psz) = let val xs = list_vt_of_arrpsz (psz) in list0_of_list_vt (xs) end // end of [list0_of_arrpsz] (* ****** ****** *) implement{} list0_is_nil (xs) = ( case+ xs of list0_nil () => true | _ => false ) // end of [list0_is_nil] implement{} list0_is_cons (xs) = ( case+ xs of list0_cons _ => true | _ => false ) // end of [list0_is_cons] (* ****** ****** *) implement{a} list0_append (xs, ys) = let val xs = list_of_list0 (xs) and ys = list_of_list0 (ys) in list0_of_list (list_append (xs, ys)) end // end of [list0_append] (* ****** ****** *) implement{a,b} list0_assoc_fun (xs, f, x) = let val xs = list_of_list0 (xs) val ans = list_assoc_fun (xs, f, x) in option0_of_option_vt (ans) end // end of [list0_assoc_fun] implement{a,b} list0_assoc_cloref (xs, f, x) = let val xs = list_of_list0 (xs) val ans = list_assoc_cloref (xs, f, x) in option0_of_option_vt (ans) end // end of [list0_assoc_cloref] (* ****** ****** *) implement{a} list0_concat (xss) = let castfn __cast {n:nat} .. (xss: list (list0 a, n)):<> List (List a) = case+ xss of | list_cons (xs, xss) => let val xs = list_of_list0 (xs) in list_cons (xs, __cast xss) end // end of [list0_cons] | list_nil () => list_nil () // end of [castfn] val xss = list_of_list0 {list0 a} (xss) in list0_of_list_vt (list_concat (__cast xss)) end // end of [list0_concat] (* ****** ****** *) implement{a} list0_exists_fun (xs, f) = list_exists_fun (list_of_list0 xs, f) // end of [list0_exists_fun] implement{a} list0_exists_cloref (xs, f) = list_exists_cloref (list_of_list0 xs, f) // end of [list0_exists_cloref] (* ****** ****** *) // // HX: this implementation implement{a} // of [list0_filter] is tail-recursive list0_filter_fun (xs, pred) = let val xs = list_of_list0 (xs) val xs = list_filter_fun (xs, pred) val xs = list_of_list_vt (xs) in list0_of_list (xs) end // end of [list0_filter] // HX: this implementation implement{a} // of [list0_filter] is tail-recursive list0_filter_cloref (xs, pred) = let val xs = list_of_list0 (xs) val xs = list_filter_cloref (xs, pred) val xs = list_of_list_vt (xs) in list0_of_list (xs) end // end of [list0_filter] (* ****** ****** *) implement{a} list0_find_fun (xs, pred) = let val ans = list_find_fun (list_of_list0 (xs), pred) in option0_of_option_vt (ans) end // end of [list0_find_fun] implement{a} list0_find_cloref (xs, pred) = let val ans = list_find_cloref (list_of_list0 (xs), pred) in option0_of_option_vt (ans) end // end of [list0_find_cloref] (* ****** ****** *) implement{init}{a} list0_fold_left (f, init, xs) = list_fold_left_cloref (f, init, list_of_list0 xs) // end of [list0_fold_left] implement{a}{sink} list0_fold_right (f, xs, sink) = list_fold_right_cloref (f, list_of_list0 xs, sink) // end of [list0_fold_right] (* ****** ****** *) implement{a} list0_forall_fun (xs, f) = list_forall_fun (list_of_list0 xs, f) implement{a} list0_forall_cloref (xs, f) = list_forall_cloref (list_of_list0 xs, f) (* ****** ****** *) implement{a} list0_foreach_fun (xs, f) = list_foreach_fun (list_of_list0 xs, f) // end of [list0_foreach_fun] implement{a} list0_foreach_cloref (xs, f) = let val () = list_foreach_cloref (list_of_list0 xs, f) in // empty end // end of [list0_foreach_cloref] (* ****** ****** *) implement{a} list0_iforeach_fun (xs, f) = list_iforeach_fun (list_of_list0 xs, f) // end of [list0_iforeach_fun] implement{a} list0_iforeach_cloref (xs, f) = let val () = list_iforeach_cloref (list_of_list0 xs, f) in // empty end // end of [list0_iforeach_cloref] (* ****** ****** *) implement{a} list0_head_exn (xs) = begin case+ xs of | list0_cons (x, xs) => x | list0_nil () => $raise ListSubscriptException() end // end of [list0_head_exn] (* ****** ****** *) implement{a} list0_length (xs) = list_length (list_of_list0 xs) (* ****** ****** *) implement{a}{b} list0_map_fun (xs, f) = list0_of_list_vt (list_map_fun (list_of_list0 xs, f)) // end of [list0_map_fun] implement{a}{b} list0_map_cloref (xs, f) = list0_of_list_vt (list_map_cloref (list_of_list0 xs, f)) // end of [list0_map_cloref] (* ****** ****** *) implement{a1,a2}{b} list0_map2_fun (xs1, xs2, f) = let fun loop {n1,n2:nat} .. (xs1: list (a1, n1), xs2: list (a2, n2), res: &list0 b? >> list0 b) : void = case+ (xs1, xs2) of | (list_cons (x1, xs1), list_cons (x2, xs2)) => let val y = f (x1, x2) val () = res := cons (y, ?) val+ cons (_, !p_ys) = res val () = loop (xs1, xs2, !p_ys) in fold@ (res) end // end of [list_cons _, list_cons _] | (_, _) => let val () = res := nil () in () end // end of [_, _] // end of [loop] var res: list0 b // uninitialized val () = loop (xs1, xs2, res) where { val xs1 = list_of_list0 (xs1) and xs2 = list_of_list0 (xs2) } // end of [val] in res end // end of [list0_map2_fun] implement{a1,a2}{b} list0_map2_cloref (xs1, xs2, f) = let fun loop {n1,n2:nat} .. (xs1: list (a1, n1), xs2: list (a2, n2), res: &list0 b? >> list0 b) : void = case+ (xs1, xs2) of | (list_cons (x1, xs1), list_cons (x2, xs2)) => let val y = f (x1, x2) val () = res := cons (y, ?) val+ cons (_, !p_ys) = res val () = loop (xs1, xs2, !p_ys) in fold@ (res) end // end of [list_cons _, list_cons _] | (_, _) => let val () = res := nil () in () end // end of [_, _] // end of [loop] var res: list0 b // uninitialized val () = loop (xs1, xs2, res) where { val xs1 = list_of_list0 (xs1) and xs2 = list_of_list0 (xs2) } // end of [val] in res end // end of [list0_map2_cloref] (* ****** ****** *) implement{a} list0_nth_exn (xs, i) = let fun loop {i:nat} .. (xs: list0 a, i: int i): a = case+ xs of | cons (x, xs) => if i > 0 then loop (xs, i-1) else x | nil () => $raise ListSubscriptException() // end of [loop] val i = int1_of_int i in if i >= 0 then loop (xs, i) else $raise ListSubscriptException() end // end of [list0_nth_exn] implement{a} list0_nth_opt (xs, i) = let fun loop {i:nat} .. ( xs: list0 a, i: int i ) :<> option0 (a) = case+ xs of | cons (x, xs) => if i > 0 then loop (xs, i-1) else option0_some (x) | nil () => option0_none () // end of [loop] val i = int1_of_int i in if i >= 0 then loop (xs, i) else option0_none () end // end of [list0_nth_opt] (* ****** ****** *) implement{a} list0_reverse (xs) = list0_reverse_append (xs, list0_nil ()) // end of [list0_reverse] implement{a} list0_reverse_append (xs, ys) = let val xs = list_of_list0 (xs) and ys = list_of_list0 (ys) in list0_of_list (list_reverse_append (xs, ys)) end // end of [list0_reverse_append] implement{a} list0_revapp (xs, ys) = list0_reverse_append (xs, ys) (* ****** ****** *) implement{a} list0_tail_exn (xs) = begin case+ xs of | list0_cons (x, xs) => xs | list0_nil () => $raise ListSubscriptException() end // end of [list0_tail_exn] (* ****** ****** *) implement{a} list0_take_exn (xs, n) = res where { // fun loop {i:nat} .. ( xs: list0 a, i: int i, res: &list0 a? >> list0 a ) : int = let in // if i > 0 then ( case+ xs of | list0_cons (x, xs) => let val () = res := list0_cons (x, ?) val+ list0_cons (_, !p_res1) = res val err = loop (xs, i-1, !p_res1) val () = fold@ (res) in err end // end of [list0_cons] | list0_nil () => (res := list0_nil (); 1) ) else (res := list0_nil (); 0) // end // end of [loop] // val n = int1_of_int n var res: list0 a // uninitialized val err = if :(res: list0 a) => (n >= 0) then loop (xs, n, res) else (res := list0_nil (); 1) // end of [if] val () = if err > 0 then let val () = list_vt_free (__cast res) where { extern castfn __cast (_: list0 a): List_vt a } // end of [val] in $raise ListSubscriptException() end // end of [val] // } // end of [list0_take_exn] (* ****** ****** *) implement{a} list0_drop_exn (xs, n) = res where { fun loop {i:nat} .. (xs: list0 a, i: int i, err: &int): list0 a = if i > 0 then begin case+ xs of | list0_cons (_, xs) => loop (xs, i - 1, err) | list0_nil () => (err := 1; list0_nil ()) end else xs // end of [loop] var err: int = 0 val n = int1_of_int n val res = ( if n >= 0 then loop (xs, n, err) else (err := 1; list0_nil ()) ) : list0 a val () = if err > 0 then $raise ListSubscriptException() } // end of [list0_drop_exn] (* ****** ****** *) implement{a} list0_mergesort (xs, cmp) = let val xs = list_of_list0 (xs) typedef env = (a, a) - int val ys = list_mergesort {env} (xs, lam (x, y, cmp) => $effmask_all (cmp (x, y)), cmp) in list0_of_list_vt (ys) end // end of [list0_mergesort] (* ****** ****** *) (* end of [list0.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/lazy_vt.dats0000664000175000017500000002172712223166162020546 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/lazy_vt.sats" (* ****** ****** *) (* local // for call-by-need lazy evaluation assume lazy_viewt0ype_viewtype (a:viewt@ype) = thunkvalue_vt a in implement{a} lazy_vt_force_crypt (v_lazy) = begin case+ $decrypt (v_lazy) of | ~thunkvalue_vt_thunk (xf) => let stavar T: t@ype val x = $effmask_ref((xf: () - a) ()) val (pf_gc, pf_at | p) = cloptr_get_view_ptr {T} (xf) in ptr_free (pf_gc, pf_at | p); x end // end of [thunkvalue_vt_thunk] | ~thunkvalue_vt_value (x) => x end // end of [lazy_vt_force_crypt] end // end of [local] *) implement{a} lazy_vt_force (r) = !r (* ****** ****** *) extern castfn list_vt_cons_of_stream_vt_cons {l1,l2:addr} (x: stream_vt_cons_unfold (l1, l2)):<> list_vt_cons_unfold (l1, l2) // casting one data constructor to another implement{a} list_vt_of_stream_vt (xs) = let fun loop {n0:nat} ( xs: stream_vt a, n: &int n0 >> int (n + n0) ) : #[n:nat] list_vt (a, n) = let val xs_con = !xs in case+ xs_con of | stream_vt_cons (!p_x, !p_xs1) => let val () = n := n + 1 val xs1 = !p_xs1 prval pf_xs1 = list_vt_of_lazy_vt (view@ !p_xs1) where { extern prfun list_vt_of_lazy_vt {l:addr} (pf: stream_vt a? @ l): List_vt a? @ l } // end of [prval] val () = !p_xs1 := loop (xs1, n) val xs_cons = list_vt_cons_of_stream_vt_cons (xs_con) in fold@ xs_cons; xs_cons end // end of [stream_cons] | ~stream_vt_nil () => list_vt_nil () end (* end of [loop] *) var n = 0; val res = loop (xs, n) in (n, res) end // end of [list_vt_of_stream_vt] (* ****** ****** *) implement{a} stream_vt_free (xs) = ~xs (* ****** ****** *) local fun{a:t@ype} stream_vt_filter_cloptr_con (xs: stream_vt a, pred: (&a) - bool) : stream_vt_con a = let val xs_con = !xs in case+ xs_con of | stream_vt_cons (!p_x, !p_xs1) => begin if pred (!p_x) then let val xs1 = !p_xs1 val () = !p_xs1 := stream_vt_filter_cloptr (xs1, pred) in fold@ {a} (xs_con); xs_con end else let val xs1 = !p_xs1 val () = free@ {a} (xs_con) in stream_vt_filter_cloptr_con (xs1, pred) end // end of [if] end (* end of [stream_vt_cons] *) | stream_vt_nil () => begin fold@ xs_con; cloptr_free pred; xs_con end // end of [stream_vt_nil] end // end of [stream_vt_filter_con] in // in of [local] implement{a} stream_vt_filter_fun (xs, pred) = $ldelay ( stream_vt_filter_cloptr_con (xs, lam x => pred x), ~xs ) // end of [stream_vt_filter_fun] implement{a} stream_vt_filter_cloptr (xs, pred) = $ldelay ( stream_vt_filter_cloptr_con (xs, pred), (cloptr_free pred; ~xs) ) // end of [stream_vt_filter_cloptr] end // end of [local] (* ****** ****** *) local fun {a:viewt@ype} {b:viewt@ype} stream_vt_map_cloptr_con ( xs: stream_vt a, f: (&a >> a?) - b ) : stream_vt_con (b) = let val xs_con = !xs in case+ xs_con of | stream_vt_cons (!p_x, xs1) => let val y = f (!p_x) val () = free@ {a} (xs_con) val ys = $ldelay ( stream_vt_map_cloptr_con (xs1, f) , (~xs1; cloptr_free (f)) ) // end of [$ldelay in stream_vt_cons (y, ys) end // end of [stream_vt_cons] | ~stream_vt_nil () => (cloptr_free (f); stream_vt_nil) end // end of [stream_vt_map_cloptr_con] in // in of [local] implement{a}{b} stream_vt_map_fun (xs, f) = $ldelay ( stream_vt_map_cloptr_con (xs, lam (x) => f (x)), ~xs ) // end of [stream_vt_map_fun] implement{a}{b} stream_vt_map_cloptr (xs, f) = $ldelay ( stream_vt_map_cloptr_con (xs, f), (~xs; cloptr_free (f)) ) // end of [stream_vt_map_cloptr] end // end of [local] (* ****** ****** *) local #define nil stream_vt_nil #define :: stream_vt_cons fun {a1,a2:t@ype} {b:viewt@ype} stream_vt_map2_cloptr_con ( xs1: stream_vt a1 , xs2: stream_vt a2 , f: (a1, a2) - b ) : stream_vt_con b = begin case !xs1 of | ~(x1 :: xs1) => begin case+ !xs2 of | ~(x2 :: xs2) => y :: ys where { val y = f (x1, x2) val ys = $ldelay ( stream_vt_map2_cloptr_con (xs1, xs2, f) , (~xs1; ~xs2; cloptr_free f) ) // end of [$ldelay] } (* end of [::] *) | ~nil () => (~xs1; cloptr_free f; nil ()) end // end of [::] | ~nil () => (~xs2; cloptr_free f; nil ()) end // end of [stream_map2_con] in // in of [local] implement{a1,a2}{b} stream_vt_map2_fun (xs1, xs2, f) = $ldelay ( stream_vt_map2_cloptr_con (xs1, xs2, lam (x1, x2) => f (x1, x2)) , (~xs1; ~xs2) ) // end of [stream_map2_fun] implement{a1,a2}{b} stream_vt_map2_cloptr (xs1, xs2, f) = $ldelay ( stream_vt_map2_cloptr_con (xs1, xs2, f), (~xs1; ~xs2; cloptr_free f) ) // end of [stream_vt_map2_cloptr] end // end of [local] (* ****** ****** *) local #define free list_vt_free staload UN = "prelude/SATS/unsafe.sats" fun{a1,a2:t@ype} stream_vt_of_lstlstprod_con {n1,n2:nat} ( xs1: list_vt (a1, n1), xs2: list_vt (a2, n2) ) : stream_vt_con @(a1, a2) = let typedef lst2_t = list (a2, n2) viewtypedef res_vt = stream_vt_con @(a1, a2) // fun aux1 {n1:nat} ( xs1: list_vt (a1, n1), xs2: list_vt (a2, n2) ) : res_vt = case+ xs1 of | ~list_vt_cons (x1, xs1) => aux2 (x1, $UN.castvwtp1 {lst2_t} (xs2), xs1, xs2) | ~list_vt_nil () => (free (xs2); stream_vt_nil) // end of [aux1] // and aux2 {n1:nat} {k:nat | k <= n2} ( y1: a1, ys2: list (a2, k) , xs1: list_vt (a1, n1), xs2: list_vt (a2, n2) ) : res_vt = case+ ys2 of | list_cons (y2, ys2) => let val res = $ldelay ( aux2 (y1, ys2, xs1, xs2), (free (xs1); free (xs2)) ) // end of [val] in stream_vt_cons ((y1, y2), res) end // end of [list_cons] | list_nil () => aux1 (xs1, xs2) // end of [aux2] // in aux1 (xs1, xs2) end // end of [stream_vt_of_lstlstprod_con] in // in of [local] implement{a1,a2} stream_vt_of_lstlstprod (xs1, xs2) = $ldelay ( stream_vt_of_lstlstprod_con (xs1, xs2), (free (xs1); free (xs2)) ) // end of [stream_vt_of_lstlstprod] end // end of [local] (* ****** ****** *) local #define free list_vt_free staload UN = "prelude/SATS/unsafe.sats" fun{a1,a2:t@ype} stream_vt_of_strmlstprod_con {n:nat} ( xs1: stream_vt (a1), xs2: list_vt (a2, n) ) : stream_vt_con @(a1, a2) = let typedef lst2_t = list (a2, n) viewtypedef res_vt = stream_vt_con @(a1, a2) // fun aux1 ( xs1: stream_vt (a1), xs2: list_vt (a2, n) ) : res_vt = case+ !xs1 of | ~stream_vt_cons (x1, xs1) => aux2 (x1, $UN.castvwtp1 {lst2_t} (xs2), xs1, xs2) | ~stream_vt_nil () => (free (xs2); stream_vt_nil) // end of [aux1] // and aux2 {k:nat | k <= n} ( y1: a1, ys2: list (a2, k) , xs1: stream_vt (a1), xs2: list_vt (a2, n) ) : res_vt = case+ ys2 of | list_cons (y2, ys2) => let val res = $ldelay ( aux2 (y1, ys2, xs1, xs2), (~xs1; free (xs2)) ) // end of [val] in stream_vt_cons ((y1, y2), res) end // end of [list_cons] | list_nil () => aux1 (xs1, xs2) // end of [aux2] // in aux1 (xs1, xs2) end // end of [stream_vt_of_strmlstprod_con] in // in of [local] implement{a1,a2} stream_vt_of_strmlstprod (xs1, xs2) = $ldelay ( stream_vt_of_strmlstprod_con (xs1, xs2), (~xs1; free (xs2)) ) // end of [stream_vt_of_strmlstprod] end // end of [local] (* ****** ****** *) (* end of [lazy_vt.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/option.dats0000664000175000017500000000465212223166162020364 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/option.sats" (* ****** ****** *) // this is a casting function implement option_of_option_vt (ov) = case+ ov of | ~Some_vt (v) => Some (v) | ~None_vt () => None () // end of [option_of_option_vt] (* ****** ****** *) implement option_is_none (ov) = case+ ov of None () => true | Some _ => false // end of [option_is_none] implement option_is_some (ov) = case+ ov of Some _ => true | None () => false // end of [option_is_some] (* ****** ****** *) implement{a} option_some (x) = Some (x) implement{a} option_unsome (opt) = let val Some x = opt in x end implement{a} option_none ( ) = None ( ) (* ****** ****** *) implement{a} option_app (ov, f) = case+ ov of Some v => f v | None () => () // end of [option_app] implement{a,b} option_map (ov, f) = case+ ov of Some v => Some (f v) | None () => None // end of [option_map] (* ****** ****** *) (* end of [option.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/list_vt.dats0000664000175000017500000004663312223166162020545 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // some built-in static constants for linear list operations (* ****** ****** *) (* #define ATS_STALOADFLAG 0 // ... *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/list_vt.sats" (* ****** ****** *) implement list_vt_length_is_nonnegative (xs) = begin case+ xs of list_vt_cons _ => fold@ xs | list_vt_nil () => fold@ xs end // end of [list_vt_length_is_nonnegative] (* ****** ****** *) implement{} list_vt_is_nil (xs) = case+ xs of list_vt_nil () => (fold@ xs; true) | list_vt_cons _ => (fold@ xs; false) // end of [list_vt_is_nil] implement{} list_vt_is_cons (xs) = case+ xs of list_vt_cons _ => (fold@ xs; true) | list_vt_nil () => (fold@ xs; false) // end of [list_vt_is_cons] (* ****** ****** *) implement{a} list_vt_make_array (A, n) = let // viewtypedef list_vt = [a:viewt@ype;n:nat] list_vt (a, n) // prval () = lemma_array_v_params (view@(A)) // fun loop {n:nat} {l1,l2:addr} .. ( pf1: !array_v (a, n, l1) >> array_v (a?!, n, l1) , pf2: !list_vt? @ l2 >> list_vt (a, n) @ l2 | p_arr: ptr l1, res: ptr l2, n: size_t n ) :<> void = ( if n > 0 then let prval (pf11, pf12) = array_v_uncons {a} (pf1) val () = !res := list_vt_cons {a} {0} (!p_arr, ?) val list_vt_cons (_, !res_next) = !res val () = loop (pf12, view@ (!res_next) | p_arr+sizeof, res_next, n-1) // end of [val] prval () = pf1 := array_v_cons {a?!} (pf11, pf12) in fold@ (!res) end else let prval () = array_v_unnil {a} (pf1) prval () = pf1 := array_v_nil {a?!} () in !res := list_vt_nil {a} () end // end of [if] ) // end of [loop] // var res: list_vt? val () = loop (view@ A, view@ res | &A, &res, n) // in res end // end of [list_vt_make_array] (* ****** ****** *) (* // // HX: this is a different style: looping backward // implement{a} list_vt_make_array (A, n) = let // the loop goes from the end of an array to its beginning fun loop {i,j:nat} {l:addr} {ofs:int} .. (pf_mul: MUL (i, sizeof a, ofs), pf_arr: array_v (a, i, l) | i: size_t i, p: ptr (l+ofs), res: list_vt (a, j)) :<> (array_v (a?!, i, l) | list_vt (a, i+j)) = if i > 0 then let prval pf1_mul = mul_add_const {~1} (pf_mul) prval (pf1_arr, pf_lst) = array_v_unextend {a} (pf_mul, pf_arr) val p1 = p - sizeof val x = ptr_get_vt (pf_lst | p1) val (pf1_arr | res) = loop (pf1_mul, pf1_arr | i-1, p1, list_vt_cons (x, res)) prval pf_arr = array_v_extend {a?!} (pf1_mul, pf1_arr, pf_lst) in (pf_arr | res) end else let prval () = array_v_unnil {a} (pf_arr) in (array_v_nil {a?!} () | res) end // end of [if] // end of [loop] val (pf_mul | ofs) = mul2_size1_size1 (n, sizeof) val (pf_arr | res) = loop (pf_mul, view@ A | n, &A+ofs, list_vt_nil ()) // prval () = view@ A := pf_arr // in res end // end of [list_vt_make_array] *) (* ****** ****** *) implement{a} list_vt_of_arrpsz (psz) = let val (pf_gc, pf_arr | p_arr, asz) = psz val res = list_vt_make_array (!p_arr, asz) val () = array_ptr_free {a?} (pf_gc, pf_arr | p_arr) in res end // end of [list_vt_of_arrpsz] (* ****** ****** *) local staload UN = "prelude/SATS/unsafe.sats" in // in of [local] implement{a} list_vt_copy {n} (xs0) = list_copy ($UN.castvwtp1 {list(a,n)} (xs0)) // end of [list_vt_copy] end // end of [local] (* ****** ****** *) implement{a} list_vt_free (xs0) = let fun loop {n:nat} .. (xs: list_vt (a, n)):<> void = case+ xs of ~list_vt_cons (_, xs) => loop xs | ~list_vt_nil () => () // end of [loop] in loop (xs0) end // end of [list_vt_free] implement{a} list_vt_free_fun (xs0, f) = let fun loop {n:nat} .. (xs: list_vt (a, n)): void = case+ xs of | list_vt_cons (!p_x, xs1) => (f (!p_x); free@ {a} {0} (xs); loop (xs1)) | ~list_vt_nil () => () // end of [loop] in loop (xs0) end // end of [list_vt_free_fun] (* ****** ****** *) implement{a} list_vt_length (xs0) = let prval () = list_vt_length_is_nonnegative (xs0) fun loop {i,j:nat} .. (xs: !list_vt (a, i), j: int j):<> int (i+j) = begin case+ xs of | list_vt_cons (_, !p_xs1) => let val n = loop (!p_xs1, j+1) in fold@ xs; n end | list_vt_nil () => (fold@ xs; j) end // end of [loop] in loop (xs0, 0) end // end of [list_vt_length] (* ****** ****** *) implement{a} list_vt_make_elt (x0, n) = let fun loop {i,j:nat} .. (x0: a, i: int i, res: list_vt (a, j)):<> list_vt (a, i+j) = if i > 0 then loop (x0, i-1, list_vt_cons (x0, res)) else res in loop (x0, n, list_vt_nil) end // end of [list_make_elt] (* ****** ****** *) implement{a} list_vt_extend (xs0, y) = let // prval () = list_vt_length_is_nonnegative (xs0) // fun loop {n:nat} .. ( xs0: &list_vt (a, n) >> list_vt (a, n+1), y: a ) :<> void = begin case+ xs0 of | list_vt_cons (_, !p_xs) => (loop (!p_xs, y); fold@ xs0) | ~list_vt_nil () => (xs0 := list_vt_sing (y)) end // end of [loop] // var xs0 = xs0 // in loop (xs0, y); xs0 end // end of [list_vt_append] (* ****** ****** *) implement{a} list_vt_append (xs0, ys0) = let // prval () = list_vt_length_is_nonnegative (xs0) prval () = list_vt_length_is_nonnegative (ys0) // var xs0 = xs0 fun loop {m,n:nat} .. ( xs0: &list_vt (a, m) >> list_vt (a, m+n) , ys0: list_vt (a, n) ) :<> void = begin case+ xs0 of | list_vt_cons (_, !p_xs) => (loop (!p_xs, ys0); fold@ xs0) | ~list_vt_nil () => (xs0 := ys0) end // end of [loop] in loop (xs0, ys0); xs0 end // end of [list_vt_append] (* ****** ****** *) (* ** HX: tail-recursive implementation *) implement{a} list_vt_split_at (xs, i) = let // fun loop {n:int}{i:nat | i <= n} .. ( xs: &list_vt (a, n) >> list_vt (a, n-i) , i: int i , res: &(List_vt a)? >> list_vt (a, i) ) :<> void = ( if i > 0 then let val () = res := xs val+list_vt_cons (_, !xs_nxt) = res; val () = xs := !xs_nxt in loop (xs, i-1, !xs_nxt); fold@ {a} (res) end else begin res := list_vt_nil {a} () end ) // end of [loop] // var res: List_vt a val () = loop (xs, i, res) // in res(*list_vt (a, i)*) end // end of [list_vt_split_at] (* ****** ****** *) implement{a} list_vt_reverse (xs) = list_vt_reverse_append (xs, list_vt_nil) // end of [list_vt_reverse] implement{a} list_vt_reverse_append (xs, ys) = let // prval () = list_vt_length_is_nonnegative (xs) prval () = list_vt_length_is_nonnegative (ys) // fun revapp {m,n:nat} .. ( xs: list_vt (a, m), ys: list_vt (a, n) ) :<> list_vt (a, m+n) = case+ xs of | list_vt_cons (_, !p_xs1) => let val xs1 = !p_xs1 in !p_xs1 := ys; fold@ xs; revapp (xs1, xs) end // end of [val] | ~list_vt_nil () => ys // end of [revapp] in revapp (xs, ys) end // end of [list_vt_reverse_append] (* ****** ****** *) implement{a} list_vt_concat (xss) = let fun aux {n:nat} .. ( xs0: List_vt a, xss: list_vt (List_vt a, n) ) :<> List_vt a = case+ xss of | ~list_vt_cons (xs, xss) => list_vt_append (xs0, aux (xs, xss)) | ~list_vt_nil () => xs0 // end of [aux] in case+ xss of | ~list_vt_cons (xs0, xss) => aux (xs0, xss) | ~list_vt_nil () => list_vt_nil () end // end of [list_vt_concat] (* ****** ****** *) implement{a} list_vt_tabulate_funenv {v} {vt} {n} {f} (pf | f, n, env) = let var res: List_vt a // uninitialized fun loop {i:nat | i <= n} .. ( pf: !v | n: int n, i: int i, f: (!v | natLt n, !vt) - a, env: !vt , res: &(List_vt a)? >> list_vt (a, n-i) ) : void = if i < n then let val () = (res := list_vt_cons {a} {0} (f (pf | i, env), ?)) val+list_vt_cons (_, !p) = res in loop (pf | n, i+1, f, env, !p); fold@ res end else begin res := list_vt_nil () end // end of [if] // end of [loop] in loop (pf | n, 0, f, env, res); res end // end of [list_vt_tabulate_funenv] implement{a} list_vt_tabulate_fun {n} {f:eff} (f, n) = let val f = coerce (f) where { extern castfn coerce (f: natLt n - a):<> (!unit_v | natLt n, !ptr) - a } // end of [where] prval pf = unit_v () val ans = list_vt_tabulate_funenv {..} {ptr} (pf | f, n, null) prval unit_v () = pf in ans end // end of [list_vt_tabulate_fun] implement{a} list_vt_tabulate_vclo {v} {n} {f:eff} (pf1 | f, n) = ans where { typedef clo_t = (!v | natLt n) - a stavar l_f: addr; val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) fn app ( pf: !V | i: natLt n, p_f: !ptr l_f ) : a = let prval pfclo = pf.1 val x = !p_f (pf.0 | i) prval () = pf.1 := pfclo in x end // end of [app] prval pf = (pf1, view@ f) val ans = list_vt_tabulate_funenv {V} {ptr l_f} (pf | app, n, p_f) prval () = pf1 := pf.0 prval () = view@ f := pf.1 } // end of [list_vt_tabulate_vclo] implement{a} list_vt_tabulate_cloptr {n} {f:eff} (f, n) = res where { // viewtypedef cloptr0_t = (natLt n) - a viewtypedef cloptr1_t = (!unit_v | natLt n) - a // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val res = list_vt_tabulate_vcloptr {unit_v} (pfu | f, n) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } (* end of [list_app_cloptr] *) implement{a} list_vt_tabulate_vcloptr {v} {n} {f:eff} (pf | f, n) = let viewtypedef cloptr_t = (!v | natLt n) - a fn app (pf: !v | i: natLt n, f: !cloptr_t): a = f (pf | i) in list_vt_tabulate_funenv {v} {cloptr_t} (pf | app, n, f) end // end of [list_app_vcloptr] (* ****** ****** *) implement{a} list_vt_foreach_funenv {v} {vt} {n} {f} (pf | xs0, f, env) = let // viewtypedef fun_t = (!v | &a, !vt) - void // prval () = list_vt_length_is_nonnegative (xs0) // fun loop {i:nat} .. (pf: !v | xs0: !list_vt (a, i), f: !fun_t, env: !vt): void = case+ xs0 of | list_vt_cons (!p_x, !p_xs) => begin f (pf | !p_x, env); loop (pf | !p_xs, f, env); fold@ xs0 end // end of [val] | list_vt_nil () => (fold@ xs0) // end of [loop] in loop (pf | xs0, f, env) end // end of [list_vt_foreach_funenv] implement{a} list_vt_foreach_fun {n} {f:eff} (xs, f) = let // typedef fun0_t = (&a) - void typedef fun1_t = (!unit_v | &a, !ptr) - void // val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } prval pf = unit_v () val () = list_vt_foreach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf in // nothing end // end of [list_vt_foreach_fun] implement{a} list_vt_foreach_vclo {v} {n} {f:eff} (pf1 | xs, f) = () where { typedef clo_t = (!v | &a) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f): void = () where { prval (pf1, pf2) = pf val () = !p_f (pf1 | x) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val () = list_vt_foreach_funenv {V} {ptr l_f} (pf | xs, app, p_f) prval () = pf1 := pf.0 and () = view@ f := pf.1 } // end of [list_vt_foreach_vclo] implement{a} list_vt_foreach_cloptr {n} {f:eff} (xs, f) = let // viewtypedef cloptr0_t = (&a) - void viewtypedef cloptr1_t = (!unit_v | &a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_vt_foreach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_vt_foreach_cloptr] implement{a} list_vt_foreach_vcloptr {v} {n} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | &a) - void fn app (pf: !v | x: &a, f: !cloptr_t): void = f (pf | x) val () = list_vt_foreach_funenv {v} {cloptr_t} (pf | xs, app, f) in // empty end // end of [list_vt_foreach_vcloptr] (* ****** ****** *) implement{a} list_vt_iforeach_funenv {v} {vt} {n} {f} (pf | xs0, f, env) = let // viewtypedef fun_t = (!v | natLt n, &a, !vt) - void // prval () = list_vt_length_is_nonnegative (xs0) // fun loop {i:nat | i <= n} .. (pf: !v | i: int i, xs0: !list_vt (a, n-i), f: !fun_t, env: !vt): void = case+ xs0 of | list_vt_cons (!p_x, !p_xs) => begin f (pf | i, !p_x, env); loop (pf | i+1, !p_xs, f, env); fold@ xs0 end // end of [val] | list_vt_nil () => (fold@ xs0) // end of [loop] in loop (pf | 0, xs0, f, env) end // end of [list_vt_iforeach_funenv] implement{a} list_vt_iforeach_fun {n} {f:eff} (xs, f) = let // typedef fun0_t = (natLt n, &a) - void typedef fun1_t = (!unit_v | natLt n, &a, !ptr) - void // val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } prval pf = unit_v () val () = list_vt_iforeach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf in // nothing end // end of [list_vt_iforeach_fun] implement{a} list_vt_iforeach_vclo {v} {n} {f:eff} (pf1 | xs, f) = let typedef clo_t = (!v | natLt n, &a) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) fn app (pf: !V | i: natLt n, x: &a, p_f: !ptr l_f): void = () where { prval (pf1, pf2) = pf val () = !p_f (pf1 | i, x) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val () = list_vt_iforeach_funenv {V} {ptr l_f} (pf | xs, app, p_f) prval () = pf1 := pf.0 and () = view@ f := pf.1 in // empty end // end of [list_vt_iforeach_vclo] implement{a} list_vt_iforeach_cloptr {n} {f:eff} (xs, f) = let // viewtypedef cloptr0_t = (natLt n, &a) - void viewtypedef cloptr1_t = (!unit_v | natLt n, &a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_vt_iforeach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_vt_iforeach_cloptr] implement{a} list_vt_iforeach_vcloptr {v} {n} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | natLt n, &a) - void fn app (pf: !v | i: natLt n, x: &a, f: !cloptr_t): void = f (pf | i, x) val () = list_vt_iforeach_funenv {v} {cloptr_t} (pf | xs, app, f) in // empty end // end of [list_vt_iforeach_vcloptr] (* ****** ****** *) local staload STDLIB = "libc/SATS/stdlib.sats" typedef cmp (a:viewt@ype) = (&a, &a) - int in // in of [local] implement{a} list_vt_mergesort {n} (xs, cmp) = let // fun split {n,n1:nat | n >= n1} .. ( xs: &list_vt (a, n) >> list_vt (a, n1) , n1: int n1, res: &List_vt a? >> list_vt (a, n-n1) ) :<> void = if n1 > 0 then let val+list_vt_cons (_, !p_xs1) = xs val () = split (!p_xs1, n1-1, res) in fold@ (xs) end else let val () = res := xs val () = xs := list_vt_nil () in // nothing end // end of [if] // end of [split] fun merge {n1,n2:nat} .. ( xs1: list_vt (a, n1) , xs2: list_vt (a, n2) , cmp: &cmp a , res: &List_vt a? >> list_vt (a, n1+n2) ) :<> void = case+ xs1 of | list_vt_cons (!p_x1, !p_xs11) => ( case+ xs2 of | list_vt_cons (!p_x2, !p_xs21) => let val sgn = cmp (!p_x1, !p_x2) in if sgn <= 0 then let prval () = fold@ xs2 val () = merge (!p_xs11, xs2, cmp, !p_xs11) in fold@ (xs1); res := xs1 end else let prval () = fold@ xs1 val () = merge (xs1, !p_xs21, cmp, !p_xs21) in fold@ (xs2); res := xs2 end // end of [if] end // end of [list_vt_cons] | ~list_vt_nil () => (fold@ (xs1); res := xs1) ) // end of [list_vt_cons] | ~list_vt_nil () => (res := xs2) // end of [merge] // val n = list_vt_length (xs) // in // if n >= 2 then let val+list_vt_cons (_, !p_xs1) = xs var res: List_vt a? // uninitialized val () = split (!p_xs1, (n-1)/2, res) prval () = fold@ (xs) val xs1 = list_vt_mergesort (xs, cmp) val xs2 = list_vt_mergesort (res, cmp) val () = merge (xs1, xs2, cmp, res) in res end else xs // end of [if] // end // end of [list_vt_mergesort] implement{a} list_vt_quicksort {n} (xs, cmp) = let // // HX-2010: // I use an array to do quicksorting and then copy the sorted // array back in to the list. Note that this style of hacking // should probably not be imitated :) // prval () = list_vt_length_is_nonnegative (xs) // abst@ype a1 = a? val _ = __cast (xs) where { extern castfn __cast (xs: !list_vt (a, n) >> list_vt (a1, n)):<> ptr } // end of [val] val cmp = __cast (cmp) where { extern castfn __cast (cmp: (&a, &a) - int):<> (&a1, &a1) - int } // end of [val] val asz = size1_of_int1 (list_vt_length xs) val ( pf_gc, pf_arr | p_arr ) = array_ptr_alloc_tsz {a1} (asz, sizeof) val () = array_ptr_initialize_lst (!p_arr, __cast xs) where { extern castfn __cast (xs: !list_vt (a1, n) >> list_vt (a1?, n)):<> list (a1, n) // good hacking :) } // end of [val] val () = $effmask_all ($STDLIB.qsort (!p_arr, asz, sizeof, cmp)) val () = loop (pf_arr | p_arr, xs) where { fun loop {n:nat} {l:addr} .. ( pf_arr: !array_v (a1, n, l) >> array_v (a1?, n, l) | p_arr: ptr l, xs: !list_vt (a1?, n) >> list_vt (a1, n) ) :<> void = case+ xs of | list_vt_cons (!p_x1, !p_xs1) => let prval (pf1_elt, pf2_arr) = array_v_uncons {a1} (pf_arr) val () = !p_x1 := !p_arr val () = loop (pf2_arr | p_arr + sizeof, !p_xs1) prval () = pf_arr := array_v_cons {a1?} (pf1_elt, pf2_arr) in fold@ (xs) end // end of [list_vt_cons] | list_vt_nil () => let prval () = array_v_unnil {a1} (pf_arr) prval () = pf_arr := array_v_nil {a1?} () in fold@ (xs) end // end of [list_vt_nil] // end of [loop] } // end of [val] val () = array_ptr_free {a1?} (pf_gc, pf_arr | p_arr) val _ = __cast (xs) where { extern castfn __cast (xs: !list_vt (a1, n) >> list_vt (a, n)):<> ptr } // end of val] // in // empty end // end of [list_vt_quicksort] end // end of [local] (* ****** ****** *) (* end of [list_vt.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/list.dats0000664000175000017500000021766012223166162020034 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) (* #define ATS_STALOADFLAG 0 // ... *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/list.sats" (* ****** ****** *) // list implementation #define nil list_nil #define cons list_cons #define :: list_cons (* ****** ****** *) // // this is a proof function // implement list_length_is_nonnegative (xs) = case+ xs of list_cons _ => () | list_nil () => () // end of [list_length_is_nonnegative] (* ****** ****** *) // this is a casting function implement list_of_list_vt {a} (xs) = let // castfn aux {n:nat} .. (xs: list_vt (a, n)):<> list (a, n) = case+ xs of | ~list_vt_cons (x, xs) => list_cons (x, aux xs) | ~list_vt_nil () => list_nil () // end of [aux] // prval () = list_vt_length_is_nonnegative (xs) // in aux (xs) end // end of [list_of_list_vt] (* ****** ****** *) implement{a} list_app_funenv {v} {vt} {f:eff} (pf | xs, f, env) = let typedef fun_t = (!v | a, !vt) - void fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , f: fun_t , env: !vt ) : void = begin case+ xs of | x :: xs => let val () = f (pf | x, env) in loop (pf | xs, f, env) end // end of [::] | nil () => () end // end of [loop] in loop (pf | xs, f, env) end // end of [list_app_funenv] implement{a} list_app_fun {f:eff} (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: a - void):<> (!unit_v | a, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_app_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf in () end // end of [list_app_fun] implement{a} list_app_vclo {v} {f:eff} (pf1 | xs, f) = let viewtypedef clo_t = (!v | a) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) prval pf = (pf1, view@ f) fn app (pf: !V | x: a, lf: !ptr lf): void = let prval (pf1, pf2) = pf val () = !lf (pf1 | x) prval () = pf := (pf1, pf2) in // nothing end // end of [app] val () = list_app_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in // nothing end // end of [list_app_vclo] implement{a} list_app_cloptr {f:eff} (xs, f) = let viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_app_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_app_cloptr] implement{a} list_app_vcloptr {v:view} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | a) - void fn app (pf: !v | x: a, f: !cloptr_t): void = f (pf | x) in list_app_funenv {v} {cloptr_t} (pf | xs, app, f) end // end of [list_app_vcloptr] implement{a} list_app_cloref {f:eff} (xs, f) = let typedef cloref_t = a - void fn app (pf: !unit_v | x: a, f: !cloref_t): void = f (x) prval pf = unit_v () val () = list_app_funenv {unit_v} {cloref_t} (pf | xs, app, f) prval unit_v () = pf in // nothing end // end of [list_app_cloref] (* ****** ****** *) implement{a1,a2} list_app2_funenv {v}{vt}{n}{f:eff} (pf | xs1, xs2, f, env) = let fun loop {n:nat} .. ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , f: (!v | a1, a2, !vt) - void , env: !vt ) : void = case+ (xs1, xs2) of | (x1 :: xs1, x2 :: xs2) => begin f (pf | x1, x2, env); loop (pf | xs1, xs2, f, env) end // end of [::, ::] | (nil (), nil ()) => () // end of [loop] prval () = list_length_is_nonnegative (xs1) in loop (pf | xs1, xs2, f, env) end // end of [list_app2_funenv] implement{a1,a2} list_app2_fun {n} {f:eff} (xs1, xs2, f) = let val f = coerce (f) where { extern castfn coerce (f: (a1, a2) - void):<> (!unit_v | a1, a2, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_app2_funenv {..} {ptr} (pf | xs1, xs2, f, null) prval unit_v () = pf in // empty end // end of [list_app2_fun] implement{a1,a2} list_app2_vclo {v} {n} {f:eff} (pf1 | xs1, xs2, f) = let typedef clo_t = (!v | a1, a2) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x1: a1, x2: a2, lf: !ptr lf): void = let prval (pf1, pf2) = pf val () = !lf (pf1 | x1, x2) prval () = pf := (pf1, pf2) in // nothing end // end of [app] prval pf = (pf1, view@ f) val () = list_app2_funenv {V} {ptr lf} (pf | xs1, xs2, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in // empty end // end of [list_app2_vclo] implement{a1,a2} list_app2_cloptr {n} {f:eff} (xs1, xs2, f) = let viewtypedef cloptr0_t = (a1, a2) - void viewtypedef cloptr1_t = (!unit_v | a1, a2) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_app2_vcloptr {unit_v} (pfu | xs1, xs2, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_app2_cloptr] implement{a1,a2} list_app2_vcloptr {v} {n} {f:eff} (pf | xs1, xs2, f) = let viewtypedef cloptr_t = (!v | a1, a2) - void fn app (pf: !v | x1: a1, x2: a2, f: !cloptr_t): void = f (pf | x1, x2) in list_app2_funenv {v} {cloptr_t} (pf | xs1, xs2, app, f) end // end of [list_app2_vcloptr] implement{a1,a2} list_app2_cloref {n} {f:eff} (xs1, xs2, f) = let typedef cloref_t = (a1, a2) - void fn app (pf: !unit_v | x1: a1, x2: a2, f: !cloref_t): void = f (x1, x2) prval pf = unit_v () val () = begin list_app2_funenv {unit_v} {cloref_t} (pf | xs1, xs2, app, f) end // end of [val] prval unit_v () = pf in // empty end // end of [list_app2_cloref] (* ****** ****** *) // // HX: a tail-recursive implementation of list-append // implement{a} list_append (xs, ys) = let // var res: List a // uninitialized fun loop {n1,n2:nat} .. ( xs: list (a, n1) , ys: list (a, n2) , res: &(List a)? >> list (a, n1+n2) ) :<> void = begin case+ xs of | x :: xs => let val () = res := list_cons{a}{0} (x, ?) // end of [val] val+list_cons (_, !p) = res in loop (xs, ys, !p); fold@ res end | nil () => (res := ys) end // end of [loop] // prval () = list_length_is_nonnegative (xs) prval () = list_length_is_nonnegative (ys) // in loop (xs, ys, res); res end // end of [list_append] (* // // HX: this is a standard non-tail-recursive implementation // of list_append: // implement{a} list_append {i,j} (xs, ys) = let fun aux {n1,n2:nat} .. (xs: list (a, n1), ys: list (a, n2)):<> list (a, n1+n2) = case+ xs of x :: xs => x :: aux (xs, ys) | nil () => ys in aux (xs, ys) end // end of [list_append] *) (* ****** ****** *) implement{a} list_append1_vt (xs, ys) = let extern castfn __cast {j:int} (ys: list (a, j)):<> list_vt (a, j) // end of [extern] in list_of_list_vt (list_vt_append (xs, __cast (ys))) end // end of [list_append1_vt] implement{a} list_append2_vt (xs, ys) = let // fun loop {n1,n2:nat} .. ( xs: list (a, n1) , ys: list_vt (a, n2) , res: &(List_vt a)? >> list_vt (a, n1+n2) ) :<> void = begin case+ xs of | x :: xs => let val () = res := list_vt_cons{a}{0} (x, ?) // end of [val] val+list_vt_cons (_, !p) = res in loop (xs, ys, !p); fold@ res end (* end of [::] *) | nil () => (res := ys) end // end of [loop] // var res: List_vt a // uninitialized // prval () = list_length_is_nonnegative (xs) prval () = list_vt_length_is_nonnegative (ys) // in loop (xs, ys, res); res end // end of [list_append_vt] (* ****** ****** *) implement{a1,a2} list_assoc_funenv {v} {vt} {eq:eff} (pf | xys, eq, x0, env) = let fun loop {n:nat} .. ( pf: !v | xys: list (@(a1, a2), n) , eq: (!v | a1, a1, !vt) - bool , x0: a1 , env: !vt ) : Option_vt a2 = case+ xys of | xy :: xys => ( if eq (pf | x0, xy.0, env) then Some_vt (xy.1) else loop (pf | xys, eq, x0, env) // end of [if] ) // end of [::] | nil () => None_vt () in loop (pf | xys, eq, x0, env) end // end of [list_assoc_funenv] implement{a1,a2} list_assoc_fun {eq:eff} (xys, eq, x0) = res where { val eq = coerce (eq) where { extern castfn coerce (eq: (a1, a1) - bool):<> (!unit_v | a1, a1, !ptr) - bool } // end of [where] prval pf = unit_v () val res = list_assoc_funenv {..} {ptr} (pf | xys, eq, x0, null) prval unit_v () = pf } // end of [list_assoc_fun] implement{a1,a2} list_assoc_vclo {v} {eq:eff} (pf1 | xys, eq, x0) = res where { typedef clo_t = (!v | a1, a1) - bool stavar l_eq: addr; val p_eq: ptr l_eq = &eq viewdef V = (v, clo_t @ l_eq) fn app (pf: !V | x: a1, y: a1, p_eq: !ptr l_eq): bool = let prval (pf1, pf2) = pf val res = !p_eq (pf1 | x, y) prval () = pf := (pf1, pf2) in res end // end of [app] prval pf = (pf1, view@ eq) val res = list_assoc_funenv {V} {ptr l_eq} (pf | xys, app, x0, p_eq) prval () = pf1 := pf.0 prval () = view@ eq := pf.1 } // end of [list_assoc_vclo] implement{a1,a2} list_assoc_cloptr {eq:eff} (xys, eq, x0) = res where { viewtypedef cloptr0_t = (a1, a1) - bool viewtypedef cloptr1_t = (!unit_v | a1, a1) - bool prval () = __assert(eq) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val res = list_assoc_vcloptr {unit_v} (pfu | xys, eq, x0) prval unit_v () = pfu prval () = __assert(eq) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_assoc_cloptr] implement{a1,a2} list_assoc_vcloptr {v} {eq:eff} (pf | xys, eq, x0) = let viewtypedef cloptr_t = (!v | a1, a1) - bool fn app (pf: !v | x: a1, y: a1, eq: !cloptr_t): bool = eq (pf | x, y) in list_assoc_funenv {v} {cloptr_t} (pf | xys, app, x0, eq) end // end of [list_assoc_vcloptr] implement{a1,a2} list_assoc_cloref {eq:eff} (xys, eq, x0) = let typedef cloref_t = (a1, a1) - bool fn app ( pf: !unit_v | x: a1, y: a1, eq: !cloref_t ) : bool = eq (x, y) prval pf = unit_v () val res = list_assoc_funenv {unit_v} {cloref_t} (pf | xys, app, x0, eq) prval unit_v () = pf in res end // end of [list_assoc_cloref] (* ****** ****** *) implement{a} list_concat (xss) = let fun aux {n:nat} .. ( xs0: List a, xss: list (List a, n) ) :<> List_vt a = case+ xss of | xs :: xss => list_append2_vt (xs0, aux (xs, xss)) | nil () => list_append2_vt (xs0, list_vt_nil) // end of [aux] in case+ xss of xs :: xss => aux (xs, xss) | nil () => list_vt_nil () end // end of [list_concat] (* ****** ****** *) implement{a} list_copy (xs0) = res where { // fun loop {n:nat} .. ( xs: list (a, n), res: &List_vt a? >> list_vt (a, n) ) :<> void = case+ xs of | list_cons (x, xs) => let val () = res := list_vt_cons{a}{0} (x, ?) val+list_vt_cons (_, !p_res1) = res val () = loop (xs, !p_res1) in fold@ res end // end of [cons] | list_nil () => res := list_vt_nil () var res: List_vt a // uninitialized // prval () = list_length_is_nonnegative (xs0) // val () = loop (xs0, res) } // end of [list_copy] (* ****** ****** *) implement{a} list_drop (xs, i) = loop (xs, i) where { fun loop {n,i:nat | i <= n} .. (xs: list (a, n), i: int i):<> list (a, n-i) = if i > 0 then let val+ _ :: xs = xs in loop (xs, i-1) end else xs } // end of [list_drop] implement{a} list_drop_exn (xs, i) = loop (xs, i) where { fun loop {n,i:nat} .. (xs: list (a, n), i: int i): [i <= n] list (a, n-i) = if i > 0 then begin case+ xs of | list_cons (_, xs) => loop (xs, i-1) | list_nil () => $raise ListSubscriptException() end else xs // end of [if] // prval () = list_length_is_nonnegative (xs) // } // end of [list_drop_exn] (* ****** ****** *) implement{a} list_exists_funenv {v} {vt} {p:eff} (pf | xs, p, env) = let fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , p: (!v | a, !vt) - bool , env: !vt ) :

bool = case+ xs of | x :: xs => if p (pf | x, env) then true else loop (pf | xs, p, env) | nil () => false // end of [loop] in loop (pf | xs, p, env) end // end of [list_exists_funenv] implement{a} list_exists_fun {p:eff} (xs, p) = let val p = coerce (p) where { extern castfn coerce (p: a -

bool):<> (!unit_v | a, !ptr) -

bool } // end of [where] prval pf = unit_v () val ans = list_exists_funenv {..} {ptr} (pf | xs, p, null) prval unit_v () = pf in ans end // end of [list_exists_fun] implement{a} list_exists_vclo {v} {p:eff} (pf1 | xs, p) = let typedef clo_t = (!v | a) - bool stavar lp: addr; val lp: ptr lp = &p viewdef V = (v, clo_t @ lp) fn app (pf: !V | x: a, lp: !ptr lp):

bool = let prval (pf1, pf2) = pf val ans = !lp (pf1 | x) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ p) val ans = list_exists_funenv {V} {ptr lp} (pf | xs, app, lp) prval () = pf1 := pf.0 prval () = view@ p := pf.1 in ans end // end of [list_exists_vclo] implement{a} list_exists_cloptr {p:eff} (xs, p) = ans where { viewtypedef cloptr0_t = (a) - bool viewtypedef cloptr1_t = (!unit_v | a) - bool prval () = __assert(p) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ans = list_exists_vcloptr {unit_v} (pfu | xs, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_exists_cloptr] implement{a} list_exists_vcloptr {v} {p:eff} (pf | xs, p) = let viewtypedef cloptr_t = (!v | a) - bool fn app (pf: !v | x: a, p: !cloptr_t):

bool = p (pf | x) in list_exists_funenv {v} {cloptr_t} (pf | xs, app, p) end // end of [list_exists_vcloptr] implement{a} list_exists_cloref {p:eff} (xs, p) = ans where { typedef cloref_t = a - bool fn app (pf: !unit_v | x: a, p: !cloref_t):

bool = p (x) prval pf = unit_v () val ans = list_exists_funenv {unit_v} {cloref_t} (pf | xs, app, p) prval unit_v () = pf } // end of [list_exists_cloref] (* ****** ****** *) implement{a1,a2} list_exists2_funenv {v}{vt}{n}{p:eff} (pf | xs1, xs2, p, env) = let prval () = list_length_is_nonnegative (xs1) fun loop {n:nat} .. ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , p: (!v | a1, a2, !vt) - bool , env: !vt ) :

bool = begin case+ xs1 of | x1 :: xs1 => let val+ x2 :: xs2 = xs2 in if p (pf | x1, x2, env) then true else loop (pf | xs1, xs2, p, env) end (* end of [::] *) | nil () => false end // end of [loop] in loop (pf | xs1, xs2, p, env) end // end of [list_exists2_funenv] implement{a1,a2} list_exists2_fun {n} {p:eff} (xs1, xs2, p) = ans where { val p = coerce (p) where { extern castfn coerce (p: (a1, a2) -

bool):<> (!unit_v | a1, a2, !ptr) -

bool } // end of [where] prval pf = unit_v () val ans = list_exists2_funenv {..} {ptr} (pf | xs1, xs2, p, null) prval unit_v () = pf } // end of [list_exists2_fun] implement{a1,a2} list_exists2_vclo {v} {n} {p:eff} (pf1 | xs1, xs2, p) = let typedef clo_t = (!v | a1, a2) - bool stavar lp: addr; val lp: ptr lp = &p viewdef V = (v, clo_t @ lp) fn app (pf: !V | x1: a1, x2: a2, lp: !ptr lp):

bool = let prval (pf1, pf2) = pf val ans = !lp (pf1 | x1, x2) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ p) val ans = list_exists2_funenv {V} {ptr lp} (pf | xs1, xs2, app, lp) prval () = pf1 := pf.0 prval () = view@ p := pf.1 in ans end // end of [list_exists2_vclo] implement{a1,a2} list_exists2_cloptr {n} {p:eff} (xs1, xs2, p) = ans where { viewtypedef cloptr0_t = (a1, a2) - bool viewtypedef cloptr1_t = (!unit_v | a1, a2) - bool prval () = __assert(p) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ans = list_exists2_vcloptr {unit_v} (pfu | xs1, xs2, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_exists_cloptr] implement{a1,a2} list_exists2_vcloptr {v} {n} {p:eff} (pf | xs1, xs2, p) = let viewtypedef cloptr_t = (!v | a1, a2) - bool fn app (pf: !v | x1: a1, x2: a2, p: !cloptr_t):

bool = p (pf | x1, x2) in list_exists2_funenv {v} {cloptr_t} (pf | xs1, xs2, app, p) end // end of [list_exists2_vcloptr] implement{a1,a2} list_exists2_cloref {n} {p:eff} (xs1, xs2, p) = ans where { viewtypedef cloref_t = (a1, a2) - bool fn app (pf: !unit_v | x1: a1, x2: a2, p: !cloref_t):

bool = p (x1, x2) prval pf = unit_v () val ans = list_exists2_funenv {unit_v} {cloref_t} (pf | xs1, xs2, app, p) prval unit_v () = pf } // end of [list_exists2_cloref] (* ****** ****** *) implement{a} list_extend (xs, y) = let var res: List_vt a // uninitialized fun loop {n:nat} .. ( xs: list (a, n), y: a , res: &(List_vt a)? >> list_vt (a, n+1) ) :<> void = begin case+ xs of | x :: xs => let val () = res := list_vt_cons{a}{0} (x, ?) // end of [val] val list_vt_cons (_, !p) = res in loop (xs, y, !p); fold@ res end // end of [::] | nil () => (res := list_vt_cons (y, list_vt_nil ())) end // end of [loop] prval () = list_length_is_nonnegative (xs) in loop (xs, y, res); res end // end of [list_extend] (* ****** ****** *) implement{a} list_filter_funenv {v} {vt} {n} {p:eff} (pf | xs, p, env) = let // fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , p: (!v | a, !vt) - bool , res: &(List_vt a)? >> list_vt (a, n1) , env: !vt ) :

#[n1:nat | n1 <= n] void = case+ xs of | x :: xs => begin if p (pf | x, env) then let val () = res := list_vt_cons{a}{0} (x, ?) val+list_vt_cons (_, !p_res) = res in loop (pf | xs, p, !p_res, env); fold@ res end else begin loop (pf | xs, p, res, env) end // end of [if] end (* end of [::] *) | nil () => (res := list_vt_nil ()) (* end of [loop] *) // var res: List_vt a // uninitialized // prval () = list_length_is_nonnegative (xs) // val () = loop (pf | xs, p, res, env) // in res end // end of [list_filter_funenv] implement{a} list_filter_fun {n} {p:eff} (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: a -

bool):<> (!unit_v | a, !ptr) -

bool } // end of [where] prval pf = unit_v () val ys = list_filter_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf in ys end // end of [list_filter_fun] implement{a} list_filter_vclo {v} {n} {p:eff} (pf1 | xs, f) = let typedef clo_t = (!v | a) - bool stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x: a, lf: !ptr lf):

bool = let prval (pf1, pf2) = pf; val ans = !lf (pf1 | x); prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val ys = list_filter_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in ys end // end of [list_filter_vclo] implement{a} list_filter_cloptr {n} {p:eff} (xs, p) = let viewtypedef cloptr0_t = (a) - bool viewtypedef cloptr1_t = (!unit_v | a) - bool prval () = __assert(p) where { extern prfun __assert (p: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ys = list_filter_vcloptr {unit_v} (pfu | xs, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (p: !cloptr1_t >> cloptr0_t): void } // end of [val] in ys end // end of [list_filter_cloptr] implement{a} list_filter_vcloptr {v} {n} {p:eff} (pf | xs, p) = let viewtypedef cloptr_t = (!v | a) - bool fn app (pf: !v | x: a, p: !cloptr_t):

bool = p (pf | x) in list_filter_funenv {v} {cloptr_t} (pf | xs, app, p) end // end of [list_filter_vcloptr] implement{a} list_filter_cloref {n} {p:eff} (xs, p) = ys where { typedef cloref_t = a - bool fn app (pf: !unit_v | x: a, p: !cloref_t):

bool = p (x) prval pf = unit_v () val ys = list_filter_funenv {unit_v} {cloref_t} (pf | xs, app, p) prval unit_v () = pf } // end of [list_filter_cloref] (* ****** ****** *) implement{a} list_find_funenv {v} {vt} {p:eff} (pf | xs, p, env) = let fun loop {n:nat} .. ( pf: !v | xs: list (a, n), p: !(!v | a, !vt) - bool, env: !vt ) :

Option_vt a = case+ xs of | x :: xs => if p (pf | x, env) then Some_vt (x) else loop (pf | xs, p, env) | nil () => None_vt () // end of [loop] in loop (pf | xs, p, env) end // end of [list_find_funenv] implement{a} list_find_fun {p:eff} (xs, p) = let val p = coerce (p) where { extern castfn coerce (p: a -

bool):<> (!unit_v | a, !ptr) -

bool } // end of [where] prval pfu = unit_v () val res = list_find_funenv {..} {ptr} (pfu | xs, p, null) prval unit_v () = pfu in res end // end of [list_find_fun] implement{a} list_find_vclo {v} {p:eff} (pf1 | xs, p) = let typedef clo_t = (!v | a) - bool stavar lp: addr; val lp: ptr lp = &p viewdef V = (v, clo_t @ lp) fn app (pf: !V | x: a, lf: !ptr lp):

bool = let prval (pf1, pf2) = pf; val ans = !lf (pf1 | x); prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ p) val res = list_find_funenv {V} {ptr lp} (pf | xs, app, lp) prval () = pf1 := pf.0 prval () = view@ p := pf.1 in res end // end of [list_find_vclo] implement{a} list_find_cloptr {p:eff} (xs, p) = let viewtypedef cloptr0_t = (a) - bool viewtypedef cloptr1_t = (!unit_v | a) - bool prval () = __assert(p) where { extern prfun __assert (p: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ys = list_find_vcloptr {unit_v} (pfu | xs, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (p: !cloptr1_t >> cloptr0_t): void } // end of [val] in ys end // end of [list_find_cloptr] implement{a} list_find_vcloptr {v} {p:eff} (pf | xs, p) = let viewtypedef cloptr_t = (!v | a) - bool fn app (pf: !v | x: a, p: !cloptr_t):

bool = p (pf | x) in list_find_funenv {v} {cloptr_t} (pf | xs, app, p) end // end of [list_find_vcloptr] implement{a} list_find_cloref {p:eff} (xs, p) = res where { typedef cloref_t = a - bool fn app (pf: !unit_v | x: a, p: !cloref_t):

bool = p (x) prval pf = unit_v () val res = list_find_funenv {unit_v} {cloref_t} (pf | xs, app, p) prval unit_v () = pf } // end of [list_find_cloref] (* ****** ****** *) (* // // HX: this one does not work out // macrodef list_fold_left_mac (list_fold_left, f, res, xs) = `( case+ ,(xs) of | x :: xs => ,(list_fold_left) (,(f), ,(f) (,(res), x), xs) | nil () => ,(res) ) *) implement{init}{a} list_fold_left_funenv {v} {vt} {f:eff} (pf | f, res, xs, env) = let fun loop {n:nat} .. ( pf: !v | f: (!v | init, a, !vt) - init , res: init , xs: list (a, n) , env: !vt ) : init = case+ xs of | x :: xs => let val res = f (pf | res, x, env) in loop (pf | f, res, xs, env) end // end of [::] | nil () => res // end of [loop] in loop (pf | f, res, xs, env) end // end of [list_fold_left_funenv] implement{init}{a} list_fold_left_fun {f:eff} (f, res, xs) = let val f = coerce (f) where { extern castfn coerce (f: (init, a) - init):<> (!unit_v | init, a, !ptr) - init } // end of [where] prval pf = unit_v () val ans = list_fold_left_funenv {..} {ptr} (pf | f, res, xs, null) prval unit_v () = pf in ans end // end of [list_fold_left_fun] implement{init}{a} list_fold_left_vclo {v:view} {f:eff} (pf1 | f, res, xs) = let viewtypedef clo_t = (!v | init, a) - init stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | res: init, x: a, lf: !ptr lf): init = let prval (pf1, pf2) = pf; val ans = !lf (pf1 | res, x); prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val res = list_fold_left_funenv {V} {ptr lf} (pf | app, res, xs, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in res end // end of [list_fold_left_vclo] implement{init}{a} list_fold_left_cloptr {f:eff} (f, res, xs) = res where { viewtypedef cloptr0_t = (init, a) - init viewtypedef cloptr1_t = (!unit_v | init, a) - init prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val res = list_fold_left_vcloptr {unit_v} (pfu | f, res, xs) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_fold_left_cloptr] implement{init}{a} list_fold_left_vcloptr {v:view} {f:eff} (pf | f, res, xs) = let viewtypedef cloptr_t = (!v | init, a) - init fn app (pf: !v | res: init, x: a, f: !cloptr_t): init = f (pf | res, x) in list_fold_left_funenv {v} {cloptr_t} (pf | app, res, xs, f) end // end of [list_fold_left_vcloptr] implement{init}{a} list_fold_left_cloref {f:eff} (f, res, xs) = res where { typedef cloref_t = (init, a) - init fn app (pf: !unit_v | res: init, x: a, f: !cloref_t): init = f (res, x) prval pf = unit_v () val res = list_fold_left_funenv {unit_v} {cloref_t} (pf | app, res, xs, f) prval unit_v () = pf } // end of [list_fold_left_cloref] (* ****** ****** *) implement{init}{a1,a2} list_fold2_left_funenv {v}{vt}{n}{f:eff} (pf | f, res, xs1, xs2, env) = let fun loop {n:nat} .. ( pf: !v | f: !(!v | init, a1, a2, !vt) - init , res: init , xs1: list (a1, n) , xs2: list (a2, n) , env: !vt ) : init = case+ xs1 of | x1 :: xs1 => let val+ x2 :: xs2 = xs2; val res = f (pf | res, x1, x2, env) in loop (pf | f, res, xs1, xs2, env) end // end of [::] | nil () => res // end of [loop] // prval () = list_length_is_nonnegative (xs1) // in loop (pf | f, res, xs1, xs2, env) end // end of [list_fold2_left_funenv] implement{init}{a1,a2} list_fold2_left_cloptr {v} {n} {f:eff} (pf | f, res, xs1, xs2) = let viewtypedef cloptr_t = (!v | init, a1, a2) - init fn app ( pf: !v | res: init, x1: a1, x2: a2, f: !cloptr_t ) : init = f (pf | res, x1, x2) val ans = list_fold2_left_funenv {v} {cloptr_t} (pf | app, res, xs1, xs2, f) in ans end // end of [list_fold2_left_cloptr] implement{init}{a1,a2} list_fold2_left_cloref {n} {f:eff} (f, res, xs1, xs2) = let typedef cloref_t = (init, a1, a2) - init fn app (pf: !unit_v | res: init, x1: a1, x2: a2, f: !cloref_t): init = f (res, x1, x2) prval pf = unit_v () val ans = list_fold2_left_funenv {unit_v} {cloref_t} (pf | app, res, xs1, xs2, f) prval unit_v () = pf in ans end // end of [list_fold2_left_cloref] (* ****** ****** *) implement{a}{sink} list_fold_right_funenv {v} {vt} {f:eff} (pf | f, xs, res, env) = let fun loop {n:nat} .. ( pf: !v | f: (!v | a, sink, !vt) - sink , xs: list (a, n) , res: sink , env: !vt ) : sink = case+ xs of | x :: xs => let val res = loop (pf | f, xs, res, env) in f (pf | x, res, env) end // end of [::] | nil () => res // end of [loop] in loop (pf | f, xs, res, env) end // end of [list_fold_right_funenv] implement{a}{sink} list_fold_right_fun {f:eff} (f, xs, res) = let val f = coerce (f) where { extern castfn coerce (f: (a, sink) - sink):<> (!unit_v | a, sink, !ptr) - sink } // end of [where] prval pf = unit_v () val ans = list_fold_right_funenv {..} {ptr} (pf | f, xs, res, null) prval unit_v () = pf in ans end // end of [list_fold_right_fun] implement{a}{sink} list_fold_right_vclo {v:view} {f:eff} (pf1 | f, xs, res) = let viewtypedef clo_t = (!v | a, sink) - sink stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x: a, res: sink, lf: !ptr lf): sink = let prval (pf1, pf2) = pf; val ans = !lf (pf1 | x, res); prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val ans = list_fold_right_funenv {V} {ptr lf} (pf | app, xs, res, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in ans end // end of [list_fold_right_vclo] implement{a}{sink} list_fold_right_cloptr {f:eff} (f, res, xs) = let viewtypedef cloptr0_t = (a, sink) - sink viewtypedef cloptr1_t = (!unit_v | a, sink) - sink prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val res = list_fold_right_vcloptr {unit_v} (pfu | f, res, xs) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in res end // end of [list_fold_right_cloptr] implement{a}{sink} list_fold_right_vcloptr {v:view} {f:eff} (pf | f, xs, res) = let viewtypedef cloptr_t = (!v | a, sink) - sink fn app (pf: !v | x: a, res: sink, f: !cloptr_t): sink = f (pf | x, res) in list_fold_right_funenv {v} {cloptr_t} (pf | app, xs, res, f) end // end of [list_fold_right_vcloptr] implement{a}{sink} list_fold_right_cloref {f:eff} (f, xs, res) = let typedef cloref_t = (a,sink) - sink fn app (pf: !unit_v | x: a, res: sink, f: !cloref_t): sink = f (x, res) prval pf = unit_v () val ans = list_fold_right_funenv {unit_v} {cloref_t} (pf | app, xs, res, f) prval unit_v () = pf in ans end // end of [list_fold_right_cloref] (* ****** ****** *) implement{a1,a2}{sink} list_fold2_right_funenv {v}{vt}{n}{f:eff} (pf | f, xs1, xs2, res, env) = let fun loop {n:nat} .. ( pf: !v | f: (!v | a1, a2, sink, !vt) - sink , xs1: list (a1, n) , xs2: list (a2, n) , res: sink , env: !vt ) : sink = case+ xs1 of | x1 :: xs1 => let val+ x2 :: xs2 = xs2; val res = loop (pf | f, xs1, xs2, res, env) in f (pf | x1, x2, res, env) end // end of [::] | nil () => res // end of [loop] // prval () = list_length_is_nonnegative (xs1) // in loop (pf | f, xs1, xs2, res, env) end // end of [list_fold2_right_funenv] (* ****** ****** *) implement{a} list_forall_funenv {v} {vt} {p:eff} (pf | xs, p, env) = let fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , p: (!v | a, !vt) - bool , env: !vt ) :

bool = case+ xs of | x :: xs => begin if p (pf | x, env) then loop (pf | xs, p, env) else false end // end of [::] | nil () => true // end of [loop] in loop (pf | xs, p, env) end // end of [list_forall_funenv] implement{a} list_forall_fun {p:eff} (xs, p) = let val p = coerce (p) where { extern castfn coerce (p: a -

bool):<> (!unit_v | a, !ptr) -

bool } // end of [where] prval pf = unit_v () val ans = list_forall_funenv {..} {ptr} (pf | xs, p, null) prval unit_v () = pf in ans end // end of [list_forall_fun] implement{a} list_forall_vclo {v} {p:eff} (pf1 | xs, p) = let typedef clo_t = (!v | a) - bool stavar lp: addr; val lp: ptr lp = &p viewdef V = (v, clo_t @ lp) fn app (pf: !V | x: a, lp: !ptr lp):

bool = let prval (pf1, pf2) = pf val ans = !lp (pf1 | x) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ p) val ans = list_forall_funenv {V} {ptr lp} (pf | xs, app, lp) prval () = pf1 := pf.0 prval () = view@ p := pf.1 in ans end // end of [list_forall_vclo] implement{a} list_forall_cloptr {p:eff} (xs, p) = let viewtypedef cloptr0_t = (a) - bool viewtypedef cloptr1_t = (!unit_v | a) - bool prval () = __assert(p) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ans = list_forall_vcloptr {unit_v} (pfu | xs, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in ans end // end of [list_forall_cloptr] implement{a} list_forall_vcloptr {v} {p:eff} (pf | xs, p) = let viewtypedef cloptr_t = (!v | a) - bool fn app (pf: !v | x: a, p: !cloptr_t):

bool = p (pf | x) in list_forall_funenv {v} {cloptr_t} (pf | xs, app, p) end // end of [list_forall_vcloptr] implement{a} list_forall_cloref {p:eff} (xs, p) = let typedef cloref_t = a - bool fn app (pf: !unit_v | x: a, p: !cloref_t):

bool = p (x) prval pf = unit_v () val ans = list_forall_funenv {unit_v} {cloref_t} (pf | xs, app, p) prval unit_v () = pf in ans end // end of [list_forall_cloref] (* ****** ****** *) implement{a1,a2} list_forall2_funenv {v} {vt} {n} {p:eff} (pf | xs1, xs2, p, env) = let // fun loop {n:nat} .. ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , p: (!v | a1, a2, !vt) - bool , env: !vt ) :

bool = begin case+ xs1 of | x1 :: xs1 => let val+ x2 :: xs2 = xs2 in if p (pf | x1, x2, env) then loop (pf | xs1, xs2, p, env) else false end // end of [::] | nil () => true end // end of [loop] // prval () = list_length_is_nonnegative (xs1) // in loop (pf | xs1, xs2, p, env) end // end of [list_forall2_funenv] implement{a1,a2} list_forall2_fun {n} {p:eff} (xs1, xs2, p) = let val p = coerce (p) where { extern castfn coerce (p: (a1, a2) -

bool):<> (!unit_v | a1, a2, !ptr) -

bool } // end of [where] prval pf = unit_v () val ans = list_forall2_funenv {..} {ptr} (pf | xs1, xs2, p, null) prval unit_v () = pf in ans end // end of [list_forall2_fun] implement{a1,a2} list_forall2_vclo {v} {n} {p:eff} (pf1 | xs1, xs2, p) = let typedef clo_t = (!v | a1, a2) - bool stavar lp: addr; val lp: ptr lp = &p viewdef V = (v, clo_t @ lp) fn app (pf: !V | x1: a1, x2: a2, lp: !ptr lp):

bool = let prval (pf1, pf2) = pf; val ans = !lp (pf1 | x1, x2); prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ p) val ans = list_forall2_funenv {V} {ptr lp} (pf | xs1, xs2, app, lp) prval () = pf1 := pf.0 prval () = view@ p := pf.1 in ans end // end of [list_forall2_vclo] implement{a1,a2} list_forall2_cloptr {n} {p:eff} (xs1, xs2, p) = let viewtypedef cloptr0_t = (a1, a2) - bool viewtypedef cloptr1_t = (!unit_v | a1, a2) - bool prval () = __assert(p) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ans = list_forall2_vcloptr {unit_v} (pfu | xs1, xs2, p) prval unit_v () = pfu prval () = __assert(p) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in ans end // end of [list_forall_cloptr] implement{a1,a2} list_forall2_vcloptr {v} {n} {p:eff} (pf | xs1, xs2, p) = let viewtypedef clo_t = (!v | a1, a2) - bool fn app (pf: !v | x1: a1, x2: a2, p: !clo_t):

bool = p (pf | x1, x2) in list_forall2_funenv {v} {clo_t} (pf | xs1, xs2, app, p) end // end of [list_forall2_vcloptr] implement{a1,a2} list_forall2_cloref {n} {p:eff} (xs1, xs2, p) = let viewtypedef clo_t = (a1, a2) - bool fn app (pf: !unit_v | x1: a1, x2: a2, p: !clo_t):

bool = p (x1, x2) prval pf = unit_v () val ans = list_forall2_funenv {unit_v} {clo_t} (pf | xs1, xs2, app, p) prval unit_v () = pf in ans end // end of [list_forall2_cloref] (* ****** ****** *) implement{a} list_foreach_funenv {v} {vt} {f:eff} (pf | xs, f, env) = let fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , f: (!v | a, !vt) - void , env: !vt ) : void = case+ xs of | x :: xs => (f (pf | x, env); loop (pf | xs, f, env)) | nil () => () // end of [loop] in loop (pf | xs, f, env) end // end of [list_foreach] implement{a} list_foreach_fun {f:eff} (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: (a) - void):<> (!unit_v | a, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_foreach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf in // empty end // end of [list_foreach_fun] implement{a} list_foreach_vclo {v} {f:eff} (pf1 | xs, f) = let typedef clo_t = (!v | a) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x: a, lf: !ptr lf): void = () where { prval (pf1, pf2) = pf val () = !lf (pf1 | x) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val ans = list_foreach_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 and () = view@ f := pf.1 in ans end // end of [list_foreach_vclo] implement{a} list_foreach_cloptr {f:eff} (xs, f) = let viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_foreach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_foreach_cloptr] implement{a} list_foreach_vcloptr {v} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | a) - void fn app (pf: !v | x: a, f: !cloptr_t): void = f (pf | x) in list_foreach_funenv {v} {cloptr_t} (pf | xs, app, f) end // end of [list_foreach_vcloptr] implement{a} list_foreach_cloref {f:eff} (xs, f) = let typedef cloref_t = (a) - void fn app (pf: !unit_v | x: a, f: !cloref_t): void = f (x) prval pf = unit_v () val () = list_foreach_funenv {unit_v} {cloref_t} (pf | xs, app, f) prval unit_v () = pf in // empty end // end of [list_foreach_cloref] (* ****** ****** *) implement{a1,a2} list_foreach2_funenv {v}{vt}{n}{f:eff} (pf | xs1, xs2, f, env) = let // fun loop {n:nat} .. ( pf: !v | xs1: list (a1, n) , xs2: list (a2, n) , f: (!v | a1, a2, !vt) - void , env: !vt ) : void = case+ xs1 of | x1 :: xs1 => let val x2 :: xs2 = xs2 in f (pf | x1, x2, env); loop (pf | xs1, xs2, f, env) end | nil () => () // end of [loop] // prval () = list_length_is_nonnegative (xs1) // in loop (pf | xs1, xs2, f, env) end // end of [list_foreach2_funenv] implement{a1,a2} list_foreach2_fun {n} {f} (xs, ys, f) = let val f = coerce (f) where { extern castfn coerce (f: (a1, a2) - void):<> (!unit_v | a1, a2, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_foreach2_funenv {..} {ptr} (pf | xs, ys, f, null) prval unit_v () = pf in // empty end // end of [list_foreach2_fun] implement{a1,a2} list_foreach2_vclo {v} {n} {f:eff} (pf1 | xs1, xs2, f) = let typedef clo_t = (!v | a1, a2) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x1: a1, x2: a2, lf: !ptr lf): void = () where { prval (pf1, pf2) = pf val () = !lf (pf1 | x1, x2) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val () = list_foreach2_funenv {V} {ptr lf} (pf | xs1, xs2, app, lf) prval () = pf1 := pf.0 and () = view@ f := pf.1 in // empty end // end of [list_foreach2_vclo] implement{a1,a2} list_foreach2_cloptr {n} {f:eff} (xs1, xs2, f) = let viewtypedef cloptr0_t = (a1, a2) - void viewtypedef cloptr1_t = (!unit_v | a1, a2) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_foreach2_vcloptr {unit_v} (pfu | xs1, xs2, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_foreach2_cloptr] implement{a1,a2} list_foreach2_vcloptr {v} {n} {f:eff} (pf | xs1, xs2, f) = let viewtypedef cloptr_t = (!v | a1, a2) - void fn app (pf: !v | x1: a1, x2: a2, f: !cloptr_t): void = f (pf | x1, x2) in list_foreach2_funenv {v} {cloptr_t} (pf | xs1, xs2, app, f) end // end of [list_foreach2_vcloptr] implement{a1,a2} list_foreach2_cloref {n} {f:eff} (xs1, xs2, f) = let typedef cloref_t = (a1, a2) - void fn app (pf: !unit_v | x1: a1, x2: a2, f: !cloref_t): void = f (x1, x2) prval pf = unit_v () val () = begin list_foreach2_funenv {unit_v} {cloref_t} (pf | xs1, xs2, app, f) end // end of [val] prval unit_v () = pf in // empty end // end of [list_foreach2_cloref] (* ****** ****** *) implement{a} list_iforeach_funenv {v}{vt}{n}{f:eff} (pf | xs, f, env) = let // viewtypedef cloptr_t = (!v | natLt n, a, !vt) - void // fun loop {i,j:nat | i+j==n} .. ( pf: !v | i: int i , xs: list (a, j) , f: !cloptr_t , env: !vt ) : void = begin case+ xs of | x :: xs => begin f (pf | i, x, env); loop (pf | i+1, xs, f, env) end // end of [::] | nil () => () end // end of [loop] // prval () = list_length_is_nonnegative (xs) // in loop (pf | 0, xs, f, env) end // end of [list_iforeach_funenv] implement{a} list_iforeach_fun {n} {f:eff} (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: (natLt n, a) - void):<> (!unit_v | natLt n, a, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_iforeach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf in // empty end // end of [list_iforeach_fun] implement{a} list_iforeach_vclo {v} {n} {f:eff} (pf1 | xs, f) = let typedef clo_t = (!v | natLt n, a) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | i: natLt n, x: a, lf: !ptr lf): void = () where { prval (pf1, pf2) = pf val () = !lf (pf1 | i, x) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val () = list_iforeach_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 and () = view@ f := pf.1 in // empty end // end of [list_iforeach_vclo] implement{a} list_iforeach_cloptr {n} {f:eff} (xs, f) = let viewtypedef cloptr0_t = (natLt n, a) - void viewtypedef cloptr1_t = (!unit_v | natLt n, a) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_iforeach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_iforeach_cloptr] implement{a} list_iforeach_vcloptr {v} {n} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | natLt n, a) - void fn app (pf: !v | i: natLt n, x: a, f: !cloptr_t): void = f (pf | i, x) in list_iforeach_funenv {v} {cloptr_t} (pf | xs, app, f) end // end of [list_iforeach_vcloptr] implement{a} list_iforeach_cloref {n} {f:eff} (xs, f) = let typedef cloref_t = (natLt n, a) - void fn app (pf: !unit_v | i: natLt n, x: a, f: !cloref_t): void = f (i, x) prval pf = unit_v () val () = list_iforeach_funenv {unit_v} {cloref_t} (pf | xs, app, f) prval unit_v () = pf in // empty end // end of [list_iforeach_cloref] (* ****** ****** *) implement{a1,a2} list_iforeach2_funenv {v} {vt} {n} {f:eff} (pf | xs1, xs2, f, env) = let // viewtypedef cloptr_t = (!v | natLt n, a1, a2, !vt) - void // fun loop {i,j:nat | i+j==n} .. ( pf: !v | i: int i , xs1: list (a1, j), xs2: list (a2, j) , f: !cloptr_t, env: !vt ) : void = ( case+ (xs1, xs2) of | (x1 :: xs1, x2 :: xs2) => begin f (pf | i, x1, x2, env); loop (pf | i+1, xs1, xs2, f, env) end // end of [::, ::] | (nil (), nil ()) => () ) // end of [loop] // prval () = list_length_is_nonnegative (xs1) // in loop (pf | 0, xs1, xs2, f, env) end // end of [list_iforeach2_funenv] implement{a1,a2} list_iforeach2_fun {n} {f} (xs, ys, f) = let val f = coerce (f) where { extern castfn coerce (f: (natLt n, a1, a2) - void) :<> (!unit_v | natLt n, a1, a2, !ptr) - void } // end of [where] prval pf = unit_v () val () = list_iforeach2_funenv {unit_v} {ptr} (pf | xs, ys, f, null) prval unit_v () = pf in // empty end // end of [list_foreach2_fun] implement{a1,a2} list_iforeach2_vclo {v} {n} {f:eff} (pf1 | xs1, xs2, f) = let typedef clo_t = (!v | natLt n, a1, a2) - void stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | i: natLt n, x1: a1, x2: a2, lf: !ptr lf): void = () where { prval (pf1, pf2) = pf val () = !lf (pf1 | i, x1, x2) prval () = pf := (pf1, pf2) } // end of [val] prval pf = (pf1, view@ f) val ans = list_iforeach2_funenv {V} {ptr lf} (pf | xs1, xs2, app, lf) prval () = pf1 := pf.0 and () = view@ f := pf.1 in ans end // end of [list_iforeach2_vclo] implement{a1,a2} list_iforeach2_cloptr {n} {f:eff} (xs1, xs2, f) = let viewtypedef cloptr0_t = (natLt n, a1, a2) - void viewtypedef cloptr1_t = (!unit_v | natLt n, a1, a2) - void prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = list_iforeach2_vcloptr {unit_v} (pfu | xs1, xs2, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] in // nothing end // end of [list_iforeach2_cloptr] implement{a1,a2} list_iforeach2_vcloptr {v} {n} {f:eff} (pf | xs1, xs2, f) = let viewtypedef cloptr_t = (!v | natLt n, a1, a2) - void fn app (pf: !v | i: natLt n, x1: a1, x2: a2, f: !cloptr_t): void = f (pf | i, x1, x2) in list_iforeach2_funenv {v} {cloptr_t} (pf | xs1, xs2, app, f) end // end of [list_iforeach2_vcloptr] implement{a1,a2} list_iforeach2_cloref {n} {f:eff} (xs1, xs2, f) = let viewtypedef cloref_t = (natLt n, a1, a2) - void fn app (pf: !unit_v | i: natLt n, x1: a1, x2: a2, f: !cloref_t): void = f (i, x1, x2) prval pf = unit_v () val () = begin list_iforeach2_funenv {unit_v} {cloref_t} (pf | xs1, xs2, app, f) end // end of [val] prval unit_v () = pf in // empty end // end of [list_iforeach2_cloref] (* ****** ****** *) implement{a} list_get_elt_at (xs, i) = let fun loop {n,i:nat | i < n} .. (xs: list (a, n), i: int i):<> a = let val x :: xs = xs in if i > 0 then loop (xs, i - 1) else x end // end of [loop] in loop (xs, i) end // end of [list_get_elt_at] implement{a} list_nth (xs, i) = list_get_elt_at (xs, i) implement{a} list_get_elt_at_exn (xs, i) = let fun loop {n,i:nat} .. (xs: list (a, n), i: int i): [n>0] a = case+ xs of | x :: xs => if i > 0 then loop (xs, i - 1) else x | nil () => $raise ListSubscriptException() // end of [loop] prval () = list_length_is_nonnegative (xs) in loop (xs, i) end // end of [list_get_elt_at_exn] implement{a} list_nth_exn (xs, i) = list_get_elt_at_exn (xs, i) implement{a} list_get_elt_at_opt (xs, i) = let fun loop {n,i:nat} .. (xs: list (a, n), i: int i):<> Option_vt a = case+ xs of | x :: xs => if i > 0 then loop (xs, i - 1) else Some_vt x | nil () => None_vt () // end of [loop] in loop (xs, i) end // end of [list_get_elt_at_opt] implement{a} list_nth_opt (xs, n) = list_get_elt_at_opt (xs, n) (* ****** ****** *) implement{a} list_head (xs) = let val x :: _ = xs in x end implement{a} list_head_exn (xs) = case xs of | x :: _ => x | nil () => $raise ListSubscriptException() // end of [list_hean_exn] (* ****** ****** *) implement{} list_is_nil {a} (xs) = begin case+ xs of cons _ => false | nil _ => true end // end of [list_is_nil] implement{} list_is_cons {a} (xs) = begin case+ xs of _ :: _ => true | nil () => false end // end of [list_is_cons] implement{} list_is_empty {a} (xs) = begin case+ xs of cons _ => false | nil _ => true end // end of [list_is_empty] implement{} list_isnot_empty {a} (xs) = begin case+ xs of _ :: _ => true | nil () => false end // end of [list_is_not_empty] implement{a} list_is_sing (xs) = begin case+ xs of cons (_, nil ()) => true | _ =>> false end // end of [list_is_sing] implement{a} list_is_pair (xs) = begin case+ xs of cons (_, cons (_, nil ())) => true | _ =>> false end // end of [list_is_pair] (* ****** ****** *) implement{a} list_last (xs0) = loop (x, xs) where { // fun loop {n:nat} .. (x0: a, xs: list (a, n)):<> a = case+ xs of | list_cons (x, xs) => loop (x, xs) | list_nil () => x0 // val+list_cons (x, xs) = xs0 // } // end of [list_last] implement{a} list_last_exn (xs) = case+ xs of | list_cons _ => list_last (xs) | list_nil () => $raise ListSubscriptException() // end of [list_last_exn] implement{a} list_last_opt (xs) = case+ xs of | list_cons _ => Some_vt (list_last (xs)) | list_nil () => None_vt // end of [list_last_opt] (* ****** ****** *) implement{a} list_length (xs) = let fun loop {i,j:nat} .. (xs: list (a, i), j: int j):<> int (i+j) = begin case+ xs of _ :: xs => loop (xs, isucc j) | nil () => j end // end of [loop] prval () = list_length_is_nonnegative (xs) in loop (xs, 0) end // end of [list_length] (* ****** ****** *) implement{a,b} list_length_compare (xs, ys) = case+ xs of | list_cons (x, xs) => (case+ ys of | list_cons (y, ys) => list_length_compare (xs, ys) | list_nil () => 1 ) | list_nil () => ( case+ ys of list_cons _ => ~1 | list_nil () => 0 ) // end of [list_nil] // end of [list_length_compare] (* ****** ****** *) implement{a}{b} list_map_funenv {v}{vt}{n}{f:eff} (pf | xs, f, env) = let // typedef fun_t = (!v | a, !vt) - b // fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , f: fun_t , res: &(List_vt b)? >> list_vt (b, n) , env: !vt ) : void = begin case+ xs of | x :: xs => let val y = f (pf | x, env) val+ () = res := list_vt_cons{b}{0} (y, ?) // end of [val] val+list_vt_cons (_, !p) = res in loop (pf | xs, f, !p, env); fold@ res end // end of [::] | nil () => (res := list_vt_nil ()) end // end of [loop] // var res: List_vt b // uninitialized // prval () = list_length_is_nonnegative (xs) // in loop (pf | xs, f, res, env); res end // end of [list_map_funenv] implement{a}{b} list_map_fun {n}{f:eff} (xs, f) = ys where { val f = coerce (f) where { extern castfn coerce (f: a - b):<> (!unit_v | a, !ptr) - b } // end of [where] prval pf = unit_v () val ys = list_map_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf } // end of [list_map_fun] implement{a}{b} list_map_vclo {v} {n:int} {f:eff} (pf1 | xs, f) = let viewtypedef clo_t = (!v | a) - b stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x: a, lf: !ptr lf): b = let prval (pf1, pf2) = pf val ans = !lf (pf1 | x) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val ys = list_map_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in ys end // end of [list_map_vclo] implement{a}{b} list_map_cloptr {n:int} {f:eff} (xs, f) = ys where { viewtypedef cloptr0_t = (a) - b viewtypedef cloptr1_t = (!unit_v | a) - b prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ys = list_map_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_map_cloptr] implement{a}{b} list_map_vcloptr {v} {n:int} {f:eff} (pf | xs, f) = let viewtypedef cloptr_t = (!v | a) - b fn app (pf: !v | x: a, f: !cloptr_t): b = f (pf | x) in list_map_funenv {v} {cloptr_t} (pf | xs, app, f) end // end of [list_map_vcloptr] implement{a}{b} list_map_cloref {n}{f:eff} (xs, f) = ys where { typedef cloref_t = a - b fn app (pf: !unit_v | x: a, f: !cloref_t): b = f (x) prval pf = unit_v () val ys = list_map_funenv {unit_v} {cloref_t} (pf | xs, app, f) prval unit_v () = pf } // end of [list_map_cloref] (* ****** ****** *) implement{a}{b} list_mapopt_funenv {v}{vt}{n}{f:eff} (pf | xs, f, env) = let // typedef fun_t = (!v | a, !vt) - Option_vt (b) // fun loop {n:nat} .. ( pf: !v | xs: list (a, n) , f: fun_t , res: &(List_vt b)? >> listLte_vt (b, n) , env: !vt ) : void = let in // case+ xs of | x :: xs => let val opt = f (pf | x, env) in case+ opt of | ~Some_vt (y) => let val+ () = res := list_vt_cons {b}{0} (y, ?) // end of [val] val+list_vt_cons (_, !p) = res val () = loop (pf | xs, f, !p, env) in fold@ res end // end of [Some_vt] | ~None_vt () => loop (pf | xs, f, res, env) end // end of [::] | nil () => (res := list_vt_nil ()) // end // end of [loop] // var res: List_vt b // uninitialized // prval () = list_length_is_nonnegative (xs) // in loop (pf | xs, f, res, env); res end // end of [list_mapopt_funenv] implement{a}{b} list_mapopt_fun {n}{f:eff} (xs, f) = ys where { viewtypedef bopt = Option_vt (b) val f = coerce (f) where { extern castfn coerce (f: a - bopt):<> (!unit_v | a, !ptr) - bopt } // end of [where] prval pf = unit_v () val ys = list_mapopt_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf } // end of [list_mapopt_fun] implement{a}{b} list_mapopt_vclo {v} {n:int} {f:eff} (pf1 | xs, f) = let viewtypedef bopt = Option_vt (b) viewtypedef clo_t = (!v | a) - bopt stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x: a, lf: !ptr lf): bopt = let prval (pf1, pf2) = pf val ans = !lf (pf1 | x) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val ys = list_mapopt_funenv {V} {ptr lf} (pf | xs, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in ys end // end of [list_mapopt_vclo] implement{a}{b} list_mapopt_cloptr {n:int} {f:eff} (xs, f) = ys where { viewtypedef bopt = Option_vt (b) viewtypedef cloptr0_t = (a) - bopt viewtypedef cloptr1_t = (!unit_v | a) - bopt prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ys = list_mapopt_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_mapopt_cloptr] implement{a}{b} list_mapopt_vcloptr {v} {n:int} {f:eff} (pf | xs, f) = let viewtypedef bopt = Option_vt (b) viewtypedef cloptr_t = (!v | a) - bopt fn app (pf: !v | x: a, f: !cloptr_t): bopt = f (pf | x) in list_mapopt_funenv {v} {cloptr_t} (pf | xs, app, f) end // end of [list_mapopt_vcloptr] implement{a}{b} list_mapopt_cloref {n}{f:eff} (xs, f) = ys where { viewtypedef bopt = Option_vt (b) typedef cloref_t = a - bopt fn app (pf: !unit_v | x: a, f: !cloref_t): bopt = f (x) prval pf = unit_v () val ys = list_mapopt_funenv {unit_v} {cloref_t} (pf | xs, app, f) prval unit_v () = pf } // end of [list_mapopt_cloref] (* ****** ****** *) implement{a1,a2}{b} list_map2_funenv {v}{vt}{n}{f:eff} (pf | xs, ys, f, env) = let // fun loop {n:nat} .. ( pf: !v | xs: list (a1, n) , ys: list (a2, n) , f: (!v | a1, a2, !vt) - b , res: &(List_vt b)? >> list_vt (b, n) , env: !vt ) : void = begin case+ (xs, ys) of | (x :: xs, y :: ys) => let val z = f (pf | x, y, env) val+ () = res := list_vt_cons{b}{0} (z, ?) // end of [val] val+list_vt_cons (_, !p_res1) = res in loop (pf | xs, ys, f, !p_res1, env); fold@ res end | (nil (), nil ()) => (res := list_vt_nil ()) end // end of [loop] // var res: List_vt b? // uninitialized // prval () = list_length_is_nonnegative (xs) prval () = list_length_is_nonnegative (ys) // in loop (pf | xs, ys, f, res, env); res end // end of [list_map2_funenv] implement{a1,a2}{b} list_map2_fun {n} {f:eff} (xs, ys, f) = let val f = coerce (f) where { extern castfn coerce (f: (a1, a2) - b):<> (!unit_v | a1, a2, !ptr) - b } // end of [where] prval pf = unit_v () val zs = list_map2_funenv {..} {ptr} (pf | xs, ys, f, null) prval unit_v () = pf in zs end // end of [list_map2_fun] implement{a1,a2}{b} list_map2_vclo {v} {n} {f:eff} (pf1 | xs1, xs2, f) = let typedef clo_t = (!v | a1, a2) - b stavar lf: addr; val lf: ptr lf = &f viewdef V = (v, clo_t @ lf) fn app (pf: !V | x1: a1, x2: a2, lf: !ptr lf): b = let prval (pf1, pf2) = pf val ans = !lf (pf1 | x1, x2) prval () = pf := (pf1, pf2) in ans end // end of [app] prval pf = (pf1, view@ f) val ans = list_map2_funenv {V} {ptr lf} (pf | xs1, xs2, app, lf) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in ans end // end of [list_map2_vclo] implement{a1,a2}{b} list_map2_cloptr {n} {f:eff} (xs1, xs2, f) = ys where { viewtypedef cloptr0_t = (a1, a2) - b viewtypedef cloptr1_t = (!unit_v | a1, a2) - b prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val ys = list_map2_vcloptr {unit_v} (pfu | xs1, xs2, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [list_map2_cloptr] implement{a1,a2}{b} list_map2_vcloptr {v} {n} {f:eff} (pf | xs, ys, f) = let viewtypedef cloptr_t = (!v | a1, a2) - b fn app (pf: !v | x: a1, y: a2, f: !cloptr_t): b = f (pf | x, y) in list_map2_funenv {v} {cloptr_t} (pf | xs, ys, app, f) end // end of [list_map2_vcloptr] implement{a1,a2}{b} list_map2_cloref {n} {f:eff} (xs, ys, f) = zs where { typedef cloref_t = (a1, a2) - b fn app (pf: !unit_v | x: a1, y: a2, f: !cloref_t): b = f (x, y) prval pf = unit_v () val zs = begin list_map2_funenv {unit_v} {cloref_t} (pf | xs, ys, app, f) end // end of [val] prval unit_v () = pf } // end of [list_map2_cloref] (* ****** ****** *) implement{a} list_reverse_append (xs, ys) = let fun loop {n1,n2:nat} .. (xs: list (a, n1), ys: list (a, n2)):<> list (a, n1+n2) = case+ xs of x :: xs => loop (xs, x :: ys) | nil () => ys // end of [loop] prval () = list_length_is_nonnegative (xs) prval () = list_length_is_nonnegative (ys) in loop (xs, ys) end // end of [list_reverse_append] (* ****** ****** *) implement{a} list_reverse_append1_vt (xs, ys) = let extern castfn __cast {j:int} (ys: list (a, j)):<> list_vt (a, j) // end of [__cast] in list_of_list_vt (list_vt_reverse_append (xs, __cast (ys))) end // end of [list_reverse_append1_vt] implement{a} list_reverse_append2_vt (xs, ys) = let fun loop {n1,n2:nat} .. (xs: list (a, n1), ys: list_vt (a, n2)):<> list_vt (a, n1+n2) = case+ xs of x :: xs => loop (xs, list_vt_cons (x, ys)) | nil () => ys // end of [loop] prval () = list_length_is_nonnegative (xs) prval () = list_vt_length_is_nonnegative (ys) in loop (xs, ys) end // end of [list_reverse_append2_vt] (* ****** ****** *) implement{a} list_reverse (xs) = list_reverse_append2_vt (xs, list_vt_nil ()) // end of [list_reverse] (* ****** ****** *) implement{a} list_set_elt_at (xs, i, x0) = let var res: List a // uninitialized fun loop {n,i:nat | i < n} .. (xs: list (a, n), i: int i, x0: a, res: &(List a)? >> list (a, n)) :<> void = let val x :: xs = xs in if i > 0 then let val () = res := list_cons {a} {0} (x, ?) // end of [val] val+ cons (_, !p) = res in loop (xs, i-1, x0, !p); fold@ res end else begin res := cons (x0, xs) end end // end of [loop] in loop (xs, i, x0, res); res end // end of [list_set_elt_at] local fun{a:t@ype} aux_test {n,i:nat} .. (xs: list (a, n), i: int i):<> bool (i < n) = begin case+ xs of | x :: xs => if i > 0 then aux_test (xs, i-1) else true | nil () => false end // end of [aux_test] in implement{a} list_set_elt_at_exn (xs, i, x0) = let prval () = list_length_is_nonnegative (xs) in if aux_test (xs, i) then list_set_elt_at (xs, i, x0) else $raise ListSubscriptException() end // end of [list_set_elt_at_exn] implement{a} list_set_elt_at_opt (xs, i, x0) = let prval () = list_length_is_nonnegative (xs) in if aux_test (xs, i) then Some_vt (list_set_elt_at (xs, i, x0)) else None_vt () end // end of [list_set_elt_at_opt] end // end of [local] (* ****** ****** *) implement{a} list_split_at {n} {i} (xs, i) = let var fsts: List_vt a? // uninitialized fun loop {j:nat | j <= i} .. ( xs: list (a, n-j), ij: int (i-j), fsts: &(List_vt a)? >> list_vt (a, i-j) ) :<> list (a, n-i) = if ij > 0 then let val+ x :: xs = xs val () = fsts := list_vt_cons{a}{0} (x, ?) // end of [val] val+list_vt_cons (_, !p) = fsts val snds = loop {j+1} (xs, ij - 1, !p) in fold@ fsts; snds end else begin fsts := list_vt_nil (); xs end // end of [loop] val snds = loop {0} (xs, i, fsts) in (fsts, snds) end // end of [list_split_at] (* ****** ****** *) implement{a} list_tail (xs) = let val _ :: xs = xs in xs end implement{a} list_tail_exn (xs) = case+ xs of | _ :: xs => xs | nil () => $raise ListSubscriptException() (* ****** ****** *) implement{a} list_take (xs, i) = let var res: List_vt a // uninitialized fun loop {n:int} {i:nat | i <= n} .. ( xs: list (a, n), i: int i , res: &(List_vt a)? >> list_vt (a, i) ) :<> void = if i > 0 then let val x :: xs = xs val () = res := list_vt_cons{a}{0} (x, ?) // end of [val] val+list_vt_cons (_, !p) = res in loop (xs, i-1, !p); fold@ res end else begin res := list_vt_nil () end (* end of [loop] *) // end of [loop] in loop (xs, i, res); res end // end of [list_take] implement{a} list_take_exn {n}{i} (xs, i) = let // fun loop {n,i:nat} .. (xs: list (a, n), i: int i, res: &List_vt a? >> list_vt (a, j)) :<> #[j:nat | (i <= n && i == j) || (n < i && n == j)] bool (n < i) = if i > 0 then begin case+ xs of | list_cons (x, xs) => (fold@ res; ans) where { val () = res := list_vt_cons{a}{0} (x, ?) // end of [val] val+list_vt_cons (_, !p_res1) = res val ans = loop (xs, i-1, !p_res1) } // end of [list_cons] | list_nil () => (res := list_vt_nil (); true(*err*)) end else begin res := list_vt_nil (); false(*err*) end (* end of [if] *) // end of [loop] var res: List_vt a? // uninitialized // prval () = list_length_is_nonnegative (xs) // val err = loop {n,i} (xs, i, res) // in if err then let val () = list_vt_free res in $raise ListSubscriptException() end else begin res // i <= n && length (res) == i end (* end of [if] *) end (* end of [list_take_exn] *) (* ****** ****** *) implement{a,b} list_zip (xs, ys) = let // typedef ab = @(a, b) // var res: List_vt ab // uninitialized fun loop {i:nat} .. ( xs: list (a, i), ys: list (b, i) , res: &(List_vt ab)? >> list_vt (ab, i) ) :<> void = case+ (xs, ys) of | (x :: xs, y :: ys) => let val () = res := list_vt_cons{ab}{0} (@(x, y), ?) // end of [val] val+list_vt_cons (_, !p) = res in loop (xs, ys, !p); fold@ res end // end of [::, ::] | (nil (), nil ()) => (res := list_vt_nil ()) // end of [loop] // prval () = list_length_is_nonnegative (xs) prval () = list_length_is_nonnegative (ys) // in loop (xs, ys, res); res end // end of [list_zip] (* ****** ****** *) implement{a1,a2}{b} list_zipwth_fun (xs, ys, f) = list_map2_fun (xs, ys, f) // end of [list_zipwth_fun] implement{a1,a2}{b} list_zipwth_vclo (pf | xs, ys, f) = list_map2_vclo (pf | xs, ys, f) // end of [list_zipwth_vclo] implement{a1,a2}{b} list_zipwth_cloptr (xs, ys, f) = list_map2_cloptr (xs, ys, f) // end of [list_zipwth_cloptr] implement{a1,a2}{b} list_zipwth_vcloptr (pf | xs, ys, f) = list_map2_vcloptr (pf | xs, ys, f) // end of [list_zipwth_vcloptr] implement{a1,a2}{b} list_zipwth_cloref (xs, ys, f) = list_map2_cloref (xs, ys, f) // end of [list_zipwth_cloref] (* ****** ****** *) implement{a1,a2} list_unzip xys = let // var res1: List_vt a1 and res2: List_vt a2 // uninitialized // fun loop {n:nat} .. ( xys: list (@(a1, a2), n) , res1: &(List_vt a1)? >> list_vt (a1, n) , res2: &(List_vt a2)? >> list_vt (a2, n) ) :<> void = begin case+ xys of | xy :: xys => let val () = res1 := list_vt_cons{a1}{0} (xy.0, ?) val+list_vt_cons (_, !p1) = res1 val () = res2 := list_vt_cons{a2}{0} (xy.1, ?) val+list_vt_cons (_, !p2) = res2 in loop (xys, !p1, !p2); fold@ res1; fold@ res2 end // end of [::] | list_nil () => ( res1 := list_vt_nil (); res2 := list_vt_nil () ) // end of [list_nil] end // end of [loop] // prval () = list_length_is_nonnegative (xys) // in loop (xys, res1, res2); (res1, res2) end // end of [list_unzip] (* ****** ****** *) // // HX: implementing merge sort // (* ** ** llist(a, i, n): a list of lists such that ** 1. the sum of the lengths of lists in the list of lists is i, and ** 2. the length of the list is n. ** *) local // // HX: this is not an efficient implementation but it is guaranteed to be O(n*log(n)) // dataviewtype llist (a:t@ype+, int, int) = | {i,j,n:nat} lcons (a, i+j, n+1) of (list_vt (a, i), llist (a, j, n)) | lnil (a, 0, 0) (* end of [llist] *) // typedef cmp (a:t@ype, env: viewtype, f:eff) = (a, a, !env) - int // macdef list2 (x, y) = list_vt_cons (,(x), list_vt_cons (,(y), list_vt_nil)) // fun{a:t@ype} aux1 {env:viewtype} {i:nat} {f:eff} .. ( xs: list_vt (a, i), cmp: cmp (a, env, f), env: !env ) : [n:nat] llist (a, i, n) = case+ xs of | list_vt_cons (x1, !p_xs1) => ( case+ !p_xs1 of | ~list_vt_cons (x2, xs2) => let val () = free@ {a} {0} (xs) val x12 = ( if cmp (x1, x2, env) <= 0 then list2 (x1, x2) else list2 (x2, x1) ) : list_vt (a, 2) // end of [val] in lcons (x12, aux1 (xs2, cmp, env)) end // end of [list_vt_cons] | list_vt_nil () => let prval () = fold@ (!p_xs1); prval () = fold@ (xs) in lcons (xs, lnil ()) end // end of [list_vt_nil] ) // end of [list_vt_cons] | ~list_vt_nil () => lnil () (* end of [aux1] *) // fun{a:t@ype} aux2 {env:viewtype} {i,j:nat} {f:eff} .. ( xs: list_vt (a, i), ys: list_vt (a, j), cmp: cmp (a, env, f), env: !env ) : list_vt (a, i+j) = case+ xs of | list_vt_cons (x, !p_xs1) => ( case+ ys of | list_vt_cons (y, !p_ys1) => ( if cmp (x, y, env) <= 0 then let val xs1 = !p_xs1 val () = free@ {a} {0} (xs) prval () = fold@ (ys) in list_vt_cons (x, aux2 (xs1, ys, cmp, env)) end else let prval () = fold@ (xs) val ys1 = !p_ys1 val () = free@ {a} {0} (ys) in list_vt_cons (y, aux2 (xs, ys1, cmp, env)) end // end of [if] ) // end of [list_vt_cons] | ~list_vt_nil () => (fold@ (xs); xs) ) // end of [list_vt_cons] | ~list_vt_nil () => ys (* end of [aux2] *) // fun{a:t@ype} aux3 {env:viewtype} {i,n:nat} {f:eff} .. ( xss: llist (a, i, n), cmp: cmp (a, env, f), env: !env ) : [n1:nat | (n < 2 && n1 == n) || n1 < n] llist (a, i, n1) = case+ xss of | ~lcons (xs1, ~lcons (xs2, xss)) => begin lcons (aux2 (xs1, xs2, cmp, env), aux3 (xss, cmp, env)) end // end of [lcons] | _ =>> xss (* end of [aux3] *) // fun{a:t@ype} aux4 {env:viewtype} {i,n:nat} {f:eff} .. ( xss: llist (a, i, n), cmp: cmp (a, env, f), env: !env ) : list_vt (a, i) = case+ xss of | lcons ( !p_xs, !p_xss1 ) => ( case+ !p_xss1 of | lcons _ => let prval () = fold@ (!p_xss1) // end of [prval] prval () = fold@ (xss) in aux4 (aux3 (xss, cmp, env), cmp, env) end // end of [lcons] | ~lnil () => let val xs = !p_xs; val () = free@ {a}{0,0,0} (xss) in xs end // end of [lnil] ) // end of [~lcons] | ~lnil () => list_vt_nil () (* end of [aux4] *) // in // in of [local] // implement{a} list_mergesort (xs, cmp, env) = let // prval () = list_length_is_nonnegative (xs) // end of [prval] // val xs = list_copy (xs) in aux4 (aux1 (xs, cmp, env), cmp, env) end // end of [list_mergesort] // end // end of [local] (* ****** ****** *) // // HX: implementing quick sort // local // // this may not be a practical implementation as it can easily be O(n*n) // typedef cmp (a:t@ype, env: viewtype, f:eff) = (a, a, !env) - int // #define :: list_vt_cons // fun{a:t@ype} qsrt {env:viewtype} {n:nat} {f:eff} .. ( xs: list_vt (a, n), cmp: cmp (a, env, f), env: !env ) : list_vt (a, n) = case+ xs of // [case+]: exhaustive pattern matching | ~list_vt_cons (x', xs') => part {env} {n-1,0,0} (x', xs', list_vt_nil, list_vt_nil, cmp, env) // end of [::] | ~list_vt_nil () => list_vt_nil () (* end of [qsrt] *) // and part {env:viewtype} {p,l,r:nat} {f:eff} .. ( x: a , xs: list_vt (a, p) , l: list_vt (a, l), r: list_vt (a, r) , cmp: cmp (a, env, f) , env: !env ) : list_vt (a, p+l+r+1) = case+ xs of // case+ mandates exhaustive pattern matching | ~list_vt_cons (x', xs') => ( if cmp (x', x, env) <= 0 then part {env} {p-1,l+1,r} (x, xs', x' :: l, r, cmp, env) else part {env} {p-1,l,r+1} (x, xs', l, x' :: r, cmp, env) // end of [if] ) // end of [list_vt_cons] | ~list_vt_nil () => ( list_vt_append (qsrt (l, cmp, env), x :: qsrt (r, cmp, env)) ) // end of [nil] (* end of [part] *) // in (* in of [local] *) // implement{a} list_quicksort (xs, cmp, env) = let prval () = list_length_is_nonnegative (xs) // end of [val] val xs = list_copy (xs) in qsrt (xs, cmp, env) end // end of [list_quicksort] // end // end of [local] (* ****** ****** *) (* end of [list.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/string.dats0000664000175000017500000003033012223166162020352 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [main_prelude] (* ****** ****** *) staload "prelude/SATS/string.sats" (* ****** ****** *) // // HX: declared in [prelude/SATS/string.sats] // implement strbuf_vsubr_lemma0 () = vsubr_refl () (* ****** ****** *) implement strbuf_v_split (pf_mul, pf_str) = split (pf_mul, pf_str) where { prfun split {m,n:int} {i:nat | i <= n} {l:addr} {ofs:int} .. ( pf_mul: MUL (i, sizeof char, ofs), pf_str: strbuf_v (m, n, l) ) : (c1hars i @ l, strbuf_v (m-i, n-i, l+ofs)) = sif i == 0 then let prval () = mul_elim {0, sizeof char} (pf_mul) in @(array_v_nil {c1har} (), pf_str) end else let prval (pf1_at, pf2_stropt) = strbuf_v_uncons (pf_str) prval strbufopt_v_some pf2_str = pf2_stropt prval pf2_mul = mul_add_const {~1} (pf_mul) prval (pf1_res, pf2_res) = split {m-1,n-1} (pf2_mul, pf2_str) in (array_v_cons {c1har} (pf1_at, pf1_res), pf2_res) end // end of [sif] // end of [split] } // end of [strbuf_v_split] implement strbuf_v_unsplit (pf_mul, pf_buf, pf_str) = unsplit (pf_mul, pf_buf, pf_str) where { prfun unsplit {n1:nat} {m2,n2:nat} {l:addr} {ofs:int} .. ( pf_mul: MUL (n1, sizeof char, ofs) , pf_buf: c1hars n1 @ l , pf_str: strbuf_v (m2, n2, l+ofs) ) : strbuf_v (n1+m2, n1+n2, l) = sif n1 == 0 then let prval () = mul_elim {0, sizeof char} (pf_mul) prval () = array_v_unnil {c1har} (pf_buf) in pf_str end else let prval pf2_mul = mul_add_const {~1} (pf_mul) prval (pf1_at, pf2_buf) = array_v_uncons {c1har} (pf_buf) prval pf2_res = unsplit {n1-1} (pf2_mul, pf2_buf, pf_str) in strbuf_v_cons (pf1_at, pf2_res) end // end of [sif] // end of [unsplit] } // end of [strbuf_v_unsplit] (* ****** ****** *) implement print_strbuf (buf) = fprint0_strbuf (stdout_ref, buf) implement prerr_strbuf (buf) = fprint0_strbuf (stderr_ref, buf) (* ****** ****** *) %{^ ATSinline() ats_ptr_type atspre_string_string_alloc (ats_size_type n) { char *p ; p = ATS_MALLOC(n+1); p[n] = '\000'; return p ; } // end of [atspre_string_string_alloc] %} // end of [%{^] (* ****** ****** *) // // implement string_empty = "" // this requires dynamic loading // (* ****** ****** *) #define NUL '\000' #define i2sz size1_of_int1 (* ****** ****** *) implement string_make_list_int (cs, n) = let val (pf_gc, pf_sb | p_sb) = string_alloc (i2sz n) where { extern fun string_alloc {n:nat} (n: size_t n) :<> [l:addr] (freebyte_gc_v (n+1, l), strbuf (n+1, n) @ l | ptr l) = "atspre_string_string_alloc" } // end of [val] val () = loop (!p_sb, n, 0, cs) where { fun loop {m,n:nat} {i,j:nat | i + j == n} .. (buf: &strbuf (m, n), n: int n, i: int i, cs: list (char, j)):<> void = if i < n then let val+ list_cons (c, cs) = cs val [c:char] c = char1_of_char c // val () = $effmask_all ( if (c <> NUL) then () else let val () = prerrf ( "exit(ATS): a string cannot contain null characters in the middle.\n", @() ) // end of [val] in exit(1) end (* end of [if] *) ) : [c <> NUL] void // end of [val] // val () = strbuf_set_char_at (buf, i2sz i, c) in loop (buf, n, i+1, cs) end else begin // loop exists end // end of [if] } // end of [val] in #[.. | (pf_gc, pf_sb | p_sb)] end // end of [string_make_list_int] implement string_make_list_rev_int (cs, n) = let val (pf_gc, pf_sb | p_sb) = string_alloc (i2sz n) where { extern fun string_alloc {n:nat} (n: size_t n) :<> [l:addr] (freebyte_gc_v (n+1, l), strbuf (n+1, n) @ l | ptr l) = "atspre_string_string_alloc" } // end of [val] val () = loop (!p_sb, n-1, 0, cs) where { fun loop {m,n:nat} {i,j:nat | i + j == n} .. (buf: &strbuf (m, n), n1: int (n-1), i: int i, cs: list (char, j)):<> void = if i <= n1 then let val+ list_cons (c, cs) = cs val [c:char] c = char1_of_char c // val () = $effmask_all ( if (c <> NUL) then () else let val () = prerrf ( "exit(ATS): a string cannot contain null characters in the middle.\n", @() ) // end of [val] in exit(1) end (* end of [if] *) ) : [c <> NUL] void // end of [val] // val () = strbuf_set_char_at (buf, i2sz (n1-i), c) in loop (buf, n1, i+1, cs) end else begin // loop exists end // end of [if] } // end of [val] in #[.. | (pf_gc, pf_sb | p_sb)] end // end of [string_make_list_int] (* ****** ****** *) implement stringlst_concat (ss) = let val n0 = aux (ss, i2sz 0) where { fun aux {k:nat} .. (ss: list (string, k), n: size_t):<> size_t = case+ ss of | list_cons (s, ss) => aux (ss, n + string0_length s) | list_nil () => n // end of [aux] } // end of [val n0] val [n0:int] n0 = size1_of_size (n0) fun loop1 {m0,n0,i0,n,i:nat | i0 <= n0; i <= n} .. ( s0: &strbuf (m0, n0), n0: size_t n0, i0: size_t i0, s: string n, i: size_t i ) :<> sizeLte n0 = let val c = string_test_char_at (s, i) in if c <> NUL then begin if i0 < n0 then (s0[i0] := c; loop1 (s0, n0, i0+1, s, i+1)) else i0 end else i0 // end of [if] end (* end of [loop1] *) fun loop2 {m0,n0,i0,k:nat | i0 <= n0} .. ( s0: &strbuf (m0, n0), n0: size_t n0, i0: size_t i0, ss: list (string, k) ) :<> void = begin case+ ss of | list_cons (s, ss) => let val s = string1_of_string s; val i0 = loop1 (s0, n0, i0, s, 0) in loop2 (s0, n0, i0, ss) end // end of [list_cons] | list_nil () => () // loop exists end (* end of [loop2] *) val [l:addr] ( pf_gc, pf_sb | p_sb ) = string_alloc (n0) where { extern fun string_alloc {n:nat} (n: size_t n) :<> [l:addr] (freebyte_gc_v (n+1, l), strbuf (n+1, n) @ l | ptr l) = "atspre_string_string_alloc" } // end of [val] val () = loop2 (!p_sb, n0, 0, ss) in strptr_of_strbuf @(pf_gc, pf_sb | p_sb) end // end of [stringlst_concat] (* ****** ****** *) implement string_explode (s) = let fun loop {n,i:int | 0 <= i; i <= n} .. ( s: string n, i: size_t i, cs: list_vt (char, n-i) ) :<> list_vt (char, n) = if i >= 1 then let val i1 = i - 1 val c = string_get_char_at (s, i1) in loop (s, i1, list_vt_cons (c, cs)) end else begin cs // loop exists end // end of [loop] val n = string_length s in loop (s, n, list_vt_nil ()) end // end of [string1_explode] implement string_implode (cs) = string_make_list_int (cs, loop (cs, 0)) where { fun loop {i,j:nat} .. (cs: list (char, i), j: int j):<> int (i+j) = case+ cs of | list_cons (_, cs) => loop (cs, j+1) | list_nil () => j // end of [f] } // end of [string_implode] (* ****** ****** *) implement string_foreach__main {v} {vt} {n} {f:eff} (pf | buf, f, env) = loop (pf | buf, f, env, 0) where { fun loop {i:nat | i <= n} .. ( pf: !v | str: string n, f: (!v | c1har, !vt) - void, env: !vt, i: size_t i ) : void = if string_isnot_atend (str, i) then (f (pf | str[i], env); loop (pf | str, f, env, i+1)) // end of [loop] } // end of [strbuf_foreach__main] (* ****** ****** *) local fn string_make_fun {n:nat} ( s: string n, f: c1har -<> c1har ) :<> [l:addr] strbufptr_gc (n+1, n, l) = let val n = string1_length (s) val [l:addr] (pf_gc, pf_buf | p_buf) = malloc_gc (n+1) val () = loop (pf_buf | p_buf, 0) where { fun loop {i:nat | i <= n} {l:addr} .. (pf: !b0ytes (n-i+1) @ l >> strbuf (n-i+1, n-i) @ l | p: ptr l, i: size_t i) : void = let prval () = eqsize_byte_char () prval (pf1, pf2) = array_v_uncons {byte?} (pf) prval pf1 = char_v_of_b0yte_v (pf1) in if i < n then let val c = $effmask_ref (s[i]) val () = !p := f (c) val () = loop (pf2 | p + sizeof, i + 1) prval () = pf := strbuf_v_cons (pf1, pf2) in // empty end else let val () = !p := NUL prval () = pf := strbuf_v_null (pf1, pf2) in // empty end // end of [if] end (* end of [loop] *) } // end of [val] in #[l | (pf_gc, pf_buf | p_buf)] end // end of [string_make_fun] in // in of [local] implement string_tolower (s) = let extern fun tolower (c: c1har):<> c1har = "atspre_char_tolower" in string_make_fun (s, tolower) end // end of [string_tolower__bufptr] implement string_toupper (s) = let extern fun toupper (c: c1har):<> c1har = "atspre_char_toupper" in string_make_fun (s, toupper) end // end of [string_toupper__bufptr] end // end of [local] (* ****** ****** *) implement print_strptr (p) = fprint_strptr (stdout_ref, p) implement prerr_strptr (p) = fprint_strptr (stderr_ref, p) implement strptr_dup (p) = let val str = __cast (p) where { extern castfn __cast {l:agz} (p: !strptr l):<> String } // end of [val] val n = string1_length (str) val str2 = string_make_substring (str, 0, n) in strptr_of_strbuf (str2) end // end of [strptr_dup] (* ****** ****** *) %{$ #ifndef EXIT_SUCCESS #define EXIT_SUCCESS 0 #endif #ifndef EXIT_FAILURE #define EXIT_FAILURE 1 #endif %} /* ****** ****** */ %{$ // // HX: a commonly used simple hash function // ats_ulint_type atspre_string_hash_33 (ats_ptr_type s0) { unsigned long int hash_val ; unsigned char *s; int c; hash_val = 3141593UL ; // s = (unsigned char*)s0 ; while (1) { c = *s ; if (!c) break ; // the end of string is reached hash_val = ((hash_val << 5) + hash_val) + c ; // hash_val = 33 * hash_val + c s += 1 ; } // end of [while] // return hash_val ; // } // end of [atspre_string_hash_33] %} // end of [%{$] (* ****** ****** *) %{$ ats_ptr_type atspre_string_make_char ( ats_size_type n, ats_char_type c ) { char *p ; if (!c) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [string_make_char] failed: null char.\n") ; } ; // end of [if] p = ATS_MALLOC(n+1) ; memset (p, c, n) ; p[n] = '\000' ; return p ; } // end of [atspre_string_make_char] /* ****** ****** */ ats_ptr_type atspre_string_make_substring ( ats_ptr_type src0, ats_size_type start, ats_size_type len ) { char *des, *src ; des = ATS_MALLOC(len+1) ; src = ((char*)src0) + start ; memcpy(des, src, len) ; des[len] = '\000' ; return des ; } // end of [atspre_string_make_substring] /* ****** ****** */ ats_void_type atspre_strbuf_tolower (ats_ptr_type p0) { int c ; char *p = (char*)p0 ; while ((c = *p)) { *p = tolower (c) ; p += 1 ; } return ; } // end of [atspre_strbuf_tolower] ats_void_type atspre_strbuf_toupper (ats_ptr_type p0) { int c ; char *p = (char*)p0 ; while ((c = *p)) { *p = toupper (c) ; p += 1 ; } return ; } // end of [atspre_strbuf_toupper] /* ****** ****** */ %} // end of [%{$] (* ****** ****** *) (* end of [string.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/option_vt.dats0000664000175000017500000000520212223166162021065 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/option_vt.sats" (* ****** ****** *) implement{a} option_vt_some (x) = Some_vt (x) implement{a} option_vt_none ( ) = None_vt ( ) (* ****** ****** *) implement{a} option_vt_make_opt (b, x) = ( if b then let prval () = opt_unsome {a} (x) in Some_vt (x) end else let prval () = opt_unnone {a} (x) in None_vt ( ) end // end of [if] ) (* end of [option_vt_make_opt] *) (* ****** ****** *) implement option_vt_is_none (x) = case+ x of | Some_vt _ => (fold@ (x); false) | None_vt _ => (fold@ (x); true) // end of [option_vt_is_none] implement option_vt_is_some (x) = case+ x of | Some_vt _ => (fold@ (x); true) | None_vt _ => (fold@ (x); false) // end of [option_vt_is_some] (* ****** ****** *) implement{a} option_vt_unsome (opt) = x where { val+ ~Some_vt (x) = opt } // end of [option_unsome] implement{a} option_vt_unnone (opt) = () where { val+ ~None_vt () = opt } // end of [option_unnone] (* ****** ****** *) implement{a} option_vt_free (x) = case+ x of ~Some_vt _ => () | ~None_vt _ => () // end of [option_vt_free] (* ****** ****** *) (* end of [option_vt.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/bool.dats0000664000175000017500000000324212223166162020001 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "prelude/SATS/bool.sats" (* ****** ****** *) // // HX-2013-08: it is yet empty // (* ****** ****** *) (* end of [bool.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/arith.dats0000664000175000017500000002106212223166162020155 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/arith.sats" (* ****** ****** *) implement mul_isfun (pf1, pf2) = let prfun isfun {m:nat;n:int} {p1,p2:int} .. (pf1: MUL (m, n, p1), pf2: MUL (m, n, p2)): [p1==p2] void = case+ (pf1, pf2) of | (MULbas (), MULbas ()) => () | (MULind pf1, MULind pf2) => isfun (pf1, pf2) // end of [isfun] in case+ (pf1, pf2) of | (MULneg pf1, MULneg pf2) => isfun (pf1, pf2) | (_, _) =>> isfun (pf1, pf2) end // end of [mul_isfun] implement mul_istot {m,n} () = let prfun istot {m:nat;n:int} .. (): [p:int] MUL (m, n, p) = sif m > 0 then begin MULind (istot {m-1,n} ()) end else begin MULbas () end // end of [sif] in sif m >= 0 then istot {m,n} () else MULneg (istot {~m,n} ()) end // end of [mul_istot] (* ****** ****** *) implement mul_nat_nat_nat (pf) = let prfun aux {m,n:nat} {p:int} .. (pf: MUL (m, n, p)): [p>=0] void = begin case+ pf of MULbas () => () | MULind pf => aux pf end // end of [aux] in aux pf end // end of [mul_nat_nat_nat] implement mul_pos_pos_pos (pf) = let prfun aux {m,n:pos} {p:int} .. (pf: MUL (m, n, p)): [p>=m+n-1] void = let prval MULind pf1 = pf prval pf2 = mul_commute (pf1) prval MULind pf3 = pf2 prval () = mul_nat_nat_nat (pf3) in // nothing end // end of [aux] prval () = aux (pf) in // nothing end // end of [mul_pos_pos_pos] (* ****** ****** *) prfun mul_m_n1_mnm {m,n:int} {p:int} .. (pf: MUL (m, n, p)): MUL (m, n+1, p+m) = begin case+ pf of | MULbas () => MULbas () | MULind pf => MULind (mul_m_n1_mnm pf) | MULneg pf => MULneg (mul_m_n1_mnm pf) end // end of [mul_m_n1_mnm] prfun mul_m_neg_n_neg_mn {m,n:int} {p:int} .. (pf: MUL (m, n, p)): MUL (m, ~n, ~p) = begin case+ pf of | MULbas () => MULbas () | MULind pf => MULind (mul_m_neg_n_neg_mn pf) | MULneg pf => MULneg (mul_m_neg_n_neg_mn pf) end // end of [mul_m_neg_n_neg_mn] (* ****** ****** *) implement mul_negate (pf) = let prfn aux {m,n,p:int} (pf: MUL (m, n, p)): MUL (~m, n, ~p) = sif m > 0 then MULneg pf else sif m < 0 then begin let prval MULneg pf = pf in pf end end else begin let prval MULbas () = pf in pf end end // end of [sif] // end of [aux] in aux (pf) end // end of [mul_negate] implement mul_negate2 (pf) = mul_m_neg_n_neg_mn (pf) (* ****** ****** *) implement mul_commute {m,n} (pf) = let prfun aux {m:nat;n:int} {p:int} .. (pf: MUL (m, n, p)): MUL (n, m, p) = case+ pf of | MULbas () => pf where { prval pf = mul_istot {n,0} (); prval () = mul_elim pf } // end of [MULbas] | MULind pf => mul_m_n1_mnm (aux pf) // end of [aux] in sif m >= 0 then aux pf else begin let prval MULneg pf = pf in mul_m_neg_n_neg_mn (aux pf) end end // end of [sif] end // end of [mul_commute] (* ****** ****** *) implement mul_distribute (pf1, pf2) = let prfun aux {m:int} {n1,n2:int} {p1,p2:int} .. (pf1: MUL (m, n1, p1), pf2: MUL (m, n2, p2)): MUL (m, n1+n2, p1+p2) = case+ (pf1, pf2) of | (MULbas (), MULbas ()) => MULbas () | (MULind pf1, MULind pf2) => MULind (aux (pf1, pf2)) | (MULneg pf1, MULneg pf2) => MULneg (aux (pf1, pf2)) // end of [aux] in aux (pf1, pf2) end // end of [mul_distribute] implement mul_distribute2 (pf1, pf2) = mul_commute (mul_distribute (mul_commute pf1, mul_commute pf2)) // end of [mul_distribute2] (* ****** ****** *) implement mul_is_associative {x,y,z} (pf_xy, pf_yz, pf_xy_z, pf_x_yz) = let // prfn dist {x1,x2:int;y:int} {x1y,x2y:int} (pf1: MUL (x1, y, x1y), pf2: MUL (x2, y, x2y)) : MUL (x1+x2, y, x1y+x2y) = let prval pf1_ = mul_commute pf1 prval pf2_ = mul_commute pf2 prval pf3_ = mul_distribute (pf1_, pf2_) in mul_commute (pf3_) end // end of [dist] // prfun assoc {x:nat;y,z:int} {xy,yz,xy_z,x_yz:int} .. ( pf_xy: MUL (x, y, xy) , pf_yz: MUL (y, z, yz) , pf_xy_z: MUL (xy, z, xy_z) , pf_x_yz: MUL (x, yz, x_yz) ) : [xy_z==x_yz] void = begin case+ pf_xy of | MULbas () => let prval () = mul_elim (pf_xy) // xy = 0 prval () = mul_elim (pf_xy_z) // xy_y = 0 prval () = mul_elim (pf_x_yz) // x_yz = 0 in // empty end // end of [MULbas] | MULind {x1,y,x1y} (pf_x1y) => let // x = x1 + 1; xy = x1y + 1 prval pf_x1y_z = mul_istot {x1y,z} () prval MULind (pf_x1_yz) = pf_x_yz // x_yz = x + x1_yz prval () = assoc (pf_x1y, pf_yz, pf_x1y_z, pf_x1_yz) // x1y_z = x1_yz prval pf1_xy_z = dist (pf_x1y_z, pf_yz) // xy_z = x1y_z + yz prval () = mul_isfun (pf_xy_z, pf1_xy_z) in // empty end end // end of [assoc] // in // sif x >= 0 then begin assoc (pf_xy, pf_yz, pf_xy_z, pf_x_yz) end else let prval MULneg (pf_xy) = pf_xy prval pf_xy_z = mul_negate (pf_xy_z) prval MULneg (pf_x_yz) = pf_x_yz in assoc (pf_xy, pf_yz, pf_xy_z, pf_x_yz) end // end of [sif] // end // end of [mul_associate] (* ****** ****** *) (* ** the power-of-2 function *) implement lemma_exp2_params (pf) = let prfun aux {n:int} {p:int} .. ( pf: EXP2 (n, p) ) : [n>=0;p>=1] void = case+ pf of | EXP2ind (pf1) => aux (pf1) | EXP2bas () => () // end of [aux] in aux (pf) end // end of [lemma_exp2_params] implement exp2_istot {n} () = istot {n} () where { prfun istot {n:nat} .. (): [p:nat] EXP2 (n, p) = sif n > 0 then EXP2ind (istot {n-1} ()) else EXP2bas () } // end of [exp2_istot] implement exp2_isfun (pf1, pf2) = isfun (pf1, pf2) where { prfun isfun {n:nat} {p1,p2:int} .. (pf1: EXP2 (n, p1), pf2: EXP2 (n, p2)): [p1==p2] void = case+ pf1 of | EXP2ind pf1 => let prval EXP2ind pf2 = pf2 in isfun (pf1, pf2) end // end of [EXP2ind] | EXP2bas () => let prval EXP2bas () = pf2 in (* nothing *) end // end of [EXP2bas] // end of [isfun] } // end of [exp2_isfun] implement exp2_ispos (pf) = lemma_exp2_params (pf) implement exp2_ismono (pf1, pf2) = lemma (pf1, pf2) where { prfun lemma {n1,n2:nat | n1 <= n2} {p1,p2:int} .. (pf1: EXP2 (n1, p1), pf2: EXP2 (n2, p2)): [p1 <= p2] void = case+ pf2 of | EXP2ind (pf2) => begin case+ pf1 of | EXP2ind (pf1) => lemma (pf1, pf2) | EXP2bas () => lemma (pf1, pf2) end // end of [EXP2ind] | EXP2bas () => let prval EXP2bas () = pf1 in () end // end of [lemma] } // end of [exp2_ismono] implement exp2_mul (pf1, pf2, pf3) = let prfun lemma {n1,n2:nat} {p1,p2:nat} {p:int} .. ( pf1: EXP2 (n1, p1), pf2: EXP2 (n2, p2), pf3: MUL (p1, p2, p) ) : [p>=0] EXP2 (n1+n2, p) = case+ pf2 of | EXP2ind {n21} {p21} (pf21) => let // n2 = n21+1; p2 = p21 + p21 prval pf31 = mul_istot {p1,p21} () prval pf32 = mul_distribute (pf31, pf31) prval () = mul_isfun (pf3, pf32) prval pf1_res = lemma (pf1, pf21, pf31) in EXP2ind pf1_res end // end of [EXP2ind] | EXP2bas () => let prval () = mul_elim (pf3) in pf1 end // end of [lemma] in lemma (pf1, pf2, pf3) end // end of [exp2_mul] (* ****** ****** *) (* end of [arith.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/option0.dats0000664000175000017500000000316212223166162020437 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) // // HX-2010-10-27: it is yet empty // (* ****** ****** *) (* end of [option0.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/integer.dats0000664000175000017500000000600112223166162020477 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no initialization is needed (* ****** ****** *) staload "prelude/SATS/integer.sats" (* ****** ****** *) implement{} divmod_int1_int1 {m,n} (m, n, r) = let // val (pfdiv_mn | q) = ndiv2 (m, n) val (pfmul_qn | qn) = op imul2 (q, n) // prval pfdivmod_mn = divmod_istot {m,n} () prval () = divmod_isfun (pfdiv_mn, pfdivmod_mn) prval pfmul_qn_alt = divmod_elim (pfdivmod_mn) // prval () = mul_isfun (pfmul_qn, pfmul_qn_alt) // val () = r := m - qn in (pfdivmod_mn | q) end // end of [quotrem_int1_int1] (* ****** ****** *) %{$ // stringization ats_ptr_type atspre_tostrptr_llint (ats_llint_type i0) { ats_llint_type i, i1 ; int n ; char *res ; // i1 = (i0 >= 0 ? i0 : -i0) ; for (i = i1, n = 0; i > 0; i = i / 10) n += 1 ; if (i0 < 0) n += 1 ; if (i0 == 0) n = 1; res = ATS_MALLOC(n+1) ; res = res + n ; *res = '\000' ; for (i = i1, n = 0; i > 0; i = i / 10) { *--res = ('0' + i % 10) ; } // end of [for] if (i0 < 0) *--res = '-' ; if (i0 == 0) *--res = '0' ; // return res ; } // end of [atspre_tostrptr_llint] /* ****** ****** */ ats_ptr_type atspre_tostrptr_ullint (ats_ullint_type i0) { ats_ullint_type i; int n ; char *res ; // for (i = i0, n = 0; i > 0; i = i / 10) n += 1 ; if (i0 == 0) n = 1 ; res = ATS_MALLOC(n+1) ; res = res + n; *res = '\000' ; for (i = i0, n = 0; i > 0; i = i / 10) { *--res = ('0' + i % 10) ; } // end of [for] if (i0 == 0) *--res = '0' ; // return res ; } // end of [atspre_tostrptr_ullint] %} // end of [%{$] (* ****** ****** *) (* end of [integer.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/basics.dats0000664000175000017500000001002712223166162020311 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement false_elim () = case+ 0 of _ =/=> () (* ****** ****** *) (* // HX: this is declared in $ATSHOME/prelude/basic_dyn.sats: // prfun verify_constraint {p:bool | p} (): [p] void // verify and add *) implement verify_constraint () = () (* ****** ****** *) // // HX: // file_mode_lte_r_r and file_mode_lte_w_w // are declared in $ATSHOME/prelude/basic_dyn.ats // implement file_mode_lte_r_r = file_mode_lte_refl {r} () implement file_mode_lte_w_w = file_mode_lte_refl {w} () implement file_mode_lte_rw_rw = file_mode_lte_refl {rw} () // (* ****** ****** *) implement option_v_unnone (pfopt) = let prval None_v () = pfopt in (*nothing *) end implement option_v_unsome (pfopt) = let prval Some_v (pf) = pfopt in pf end (* ****** ****** *) implement unit_v_elim (pf) = let prval unit_v () = pf in (*nothing*) end (* ****** ****** *) %{^ // // HX: for the purpose of debugging // ats_int_type ats_crash_int () { volatile int *p = 0 ; return *(p) ; } // end of [ats_crash_int] // %} // end of [%{^] implement crash ((*void*)) = { val status = crash_int () where { extern fun crash_int (): int = "ats_crash_int" } // end of [val] val ((*void*)) = exit (status) } (* end of [crash] *) (* ****** ****** *) %{^ /* ** HX: various functions for exits */ ats_void_type // external ats_exit (ats_int_type status) { exit(status) ; return ; } // end of [ats_exit] ats_void_type // external ats_exit_errmsg ( ats_int_type status , ats_ptr_type errmsg ) { fprintf(stderr, "%s", (char*)errmsg) ; exit(status) ; return ; // deadcode } /* end of [ats_exit_errmsg] */ %} // end of [%{^] (* ****** ****** *) %{^ /* ** HX: various functions for asserts */ #ifndef EXIT_SUCCESS #define EXIT_SUCCESS 0 #endif #ifndef EXIT_FAILURE #define EXIT_FAILURE 1 #endif ats_void_type atspre_assertfalse () { // extern void ats_crash() ; // fprintf(stderr, "[assertfalse] executed\n") ; ats_crash() ; // HX: this is likely to cause a core dump! return ; } // end of [atspre_asertfasle] ats_void_type atspre_assert ( ats_bool_type assertion ) { if (!assertion) { fprintf (stderr, "exit(ATS): [assert] failed\n") ; exit(EXIT_FAILURE) ; } // end of [if] return ; } /* end of [atspre_assert] */ ats_void_type atspre_assert_errmsg ( ats_bool_type assertion, ats_ptr_type errmsg ) { if (!assertion) { fprintf (stderr, "exit(ATS): [assert] failed: %s\n", (char*)errmsg) ; exit(EXIT_FAILURE) ; } // end of [if] return ; } /* end of [atspre_assert_errmsg] */ %} // end of [%{^] (* ****** ****** *) (* end of [basics.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/filebas.dats0000664000175000017500000002461412223166162020461 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX-2010-03-14: Here are some basic IO operations which // are mostly for prototype implementation. If something more // efficient is needed, please use the functions in declared // in the following file: libc/SATS/stdio.sats // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no initialization is needed (* ****** ****** *) %{^ #include #include %} // end of [%{#] (* ****** ****** *) staload "prelude/SATS/filebas.sats" (* ****** ****** *) (* // // HX: implemented in [prelude/DATS/basics.dats] // implement file_mode_lte_r_r = file_mode_lte_refl {r} () implement file_mode_lte_w_w = file_mode_lte_refl {w} () implement file_mode_lte_rw_rw = file_mode_lte_refl {rw} () *) (* ****** ****** *) %{^ typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } *charlst ; // end of [typedef] ATSinline() ats_ptr_type string_make_charlst_rev (ats_int_type sz, ats_ptr_type cs) { char *s0, *s ; charlst cs_next ; s0 = (char*)ATS_MALLOC (sz + 1) ; s = s0 + sz ; *s-- = '\0' ; while (cs != (charlst)0) { *s-- = ((charlst)cs)->atslab_0 ; cs_next = ((charlst)cs)->atslab_1 ; ATS_FREE (cs) ; cs = cs_next ; } // end of [while] return s0 ; } /* string_make_charlst_rev */ %} // end of [%{^] (* ****** ****** *) #define i2c char_of_int macdef EOF = $extval (int, "EOF") (* ****** ****** *) extern fun feof0 (f: FILEref):<> int = "mac#atslib_feof" extern fun fgetc0_err (fil: FILEref):<> int = "mac#atslib_fgetc_err" // end of [fgetc0_err] extern fun fgetc1_err {m:file_mode} {l:addr} ( pf_mod: file_mode_lte (m, r) | fil: &FILE m ) :<> int = "mac#atslib_fgetc_err" extern fun fclose0_exn (fil: FILEref): void = "atslib_fclose_exn" // end of [fclose0_exn] extern fun fclose1_exn {m:file_mode} {l:addr} (pf_fil: FILE m @ l | p_fil: ptr l): void = "atslib_fclose_exn" // end of [fclose1_exn] (* ****** ****** *) extern fun string_make_charlst_rev {n:nat} (sz: int n, cs: list_vt (char, n)):<> strptr1 = "string_make_charlst_rev" // end of [string_make_charlst_rev] (* ****** ****** *) // // HX: if the last character is '\n', it is dropped // implement input_line_vt (fil) = let fun loop {n:nat} ( fil: FILEref, n: int n, cs: list_vt (char, n) ) : strptr0 = let val c = fgetc0_err (fil) in if c <> EOF then let val c = i2c c in if (c <> '\n') then loop (fil, n+1, list_vt_cons (c, cs)) else string_make_charlst_rev (n, cs) // linear string // end of [if] end else begin if n = 0 then let val+ ~list_vt_nil () = cs in strptr_null () end else string_make_charlst_rev (n, cs) // linear string // end of [if] end // end of [if] end // end of [loop] in loop (fil, 0, list_vt_nil ()) end // end of [input_line_vt] implement input_line (fil) = let val str = input_line_vt (fil) in stropt_of_strptr (str) end // end of [input_line] (* ****** ****** *) extern fun fputc0_exn (c: char, fil: FILEref): void = "atslib_fputc_exn" // end of [fputc0_exn] extern fun fputs0_exn (str: string, fil: FILEref): void = "atslib_fputs_exn" // end of [fputs0_exn] extern fun fflush0_exn (fil: FILEref): void = "atslib_fflush_exn" // end of [fflush0_exn] (* ****** ****** *) // // HX: the character '\n' is added at the end // implement output_line (fil, line) = ( fputs0_exn (line, fil); fputc0_exn ('\n', fil); fflush0_exn (fil) ) // end of [output_line] (* ****** ****** *) local // staload "libc/sys/SATS/stat.sats" staload T = "libc/sys/SATS/types.sats" // macdef u2m = $T.mode_of_uint macdef m2u = $T.uint_of_mode // in // in of [local] implement test_file_exists (path) = let var st: stat? val ret = stat_err (path, st) in if ret = 0 then let prval () = opt_unsome {stat} (st) in true end else let prval () = opt_unnone {stat} (st) in false end (* end of [if] *) end // end of [test_file_fun] (* ****** ****** *) implement test_file_mode (path, f) = let var st: stat? ; val ret = stat_err (path, st) in if ret = 0 then let prval () = opt_unsome {stat} (st) in if f (m2u(st.st_mode)) then 1 else 0 end else let prval () = opt_unnone {stat} (st) in ~1 (*error*) end (* end of [if] *) end // end of [test_file_mode] (* ****** ****** *) implement test_file_isblk (path) = test_file_mode (path, lam x => S_ISBLK (u2m(x))) // end of [test_file_isblk] implement test_file_ischr (path) = test_file_mode (path, lam x => S_ISCHR (u2m(x))) // end of [test_file_ischr] implement test_file_isdir (path) = test_file_mode (path, lam x => S_ISDIR (u2m(x))) // end of [test_file_isdir] implement test_file_isfifo (path) = test_file_mode (path, lam x => S_ISFIFO (u2m(x))) // end of [test_file_isfifo] implement test_file_isreg (path) = test_file_mode (path, lam x => S_ISREG (u2m(x))) // end of [test_file_isreg] (* ****** ****** *) implement test_file_isemp (path) = let var st: stat? ; val ret = lstat_err (path, st) in if ret = 0 then let prval () = opt_unsome {stat} (st) in if $T.lint_of_off (st.st_size) = 0L then 1 else 0 end else let prval () = opt_unnone {stat} (st) in ~1 (*error*) end (* end of [if] *) end // end of [test_file_isemp] implement test_file_islnk (path) = let var st: stat? ; val ret = lstat_err (path, st) in if ret = 0 then let prval () = opt_unsome {stat} (st) in if S_ISLNK (st.st_mode) then 1 else 0 end else let prval () = opt_unnone {stat} (st) in ~1 (*error*) end (* end of [if] *) end // end of [test_file_islnk] end // end of [local] (* ****** ****** *) local #define i2ssz ssize1_of_int1 #define sz2ssz ssize1_of_size1 viewtypedef res = List_vt (char) fun loop {n:int} ( fil: FILEref, res: &res? >> res, n: ssize_t n ) : void = let in // if n != (i2ssz)0 then let val i = fgetc0_err (fil) in if (i >= 0) then let val c = char_of_int (i) val () = res := list_vt_cons {char}{0} (c, ?) val+ list_vt_cons (_, !p_res) = res val () = loop (fil, !p_res, n-(i2ssz)1) prval () = fold@ (res) in // nothing end else res := list_vt_nil () // end of [if] end else ( res := list_vt_nil () ) // end of [if] // end // end of [loop] in // in of [local] implement char_list_vt_make_file (fil) = let // var res: res val () = loop (fil, res, i2ssz(~1)) // in res end // end of [char_list_vt_make_file] implement char_list_vt_make_file_len (fil, n) = let // var res: res val n = size1_of_size (n) val () = loop (fil, res, (sz2ssz)n) // in res end // end of [char_list_vt_make_file_len] end // end of [local] (* ****** ****** *) implement char_stream_make_file (fil) = $delay (let val c = fgetc0_err (fil) in if c <> EOF then let val c = i2c c in stream_cons (c, char_stream_make_file fil) end else begin let val () = fclose0_exn (fil) in stream_nil () end end // end of [if] end : stream_con char ) (* end of [char_stream_make_file] *) (* ****** ****** *) implement line_stream_make_file (fil) = $delay (let val line = $effmask_ref (input_line fil) in if stropt_is_some line then let val line = stropt_unsome line in stream_cons (line, line_stream_make_file fil) end else let val () = fclose0_exn fil in stream_nil () end // end of [if] end : stream_con string // end of [let] ) (* end of [line_stream_make_file] *) (* ****** ****** *) implement char_stream_vt_make_file {m} {l} ( pf_mod, pf_fil | p_fil ) = $ldelay ( let val c = fgetc1_err (pf_mod | !p_fil) in if c >= 0 then let // c <> EOF val c = char_of_int (c) in stream_vt_cons ( c, char_stream_vt_make_file (pf_mod, pf_fil | p_fil) ) // end of [stream_vt_cons] end else let val () = fclose1_exn (pf_fil | p_fil) in stream_vt_nil () end (* end of [if] *) end : stream_vt_con char , fclose1_exn (pf_fil | p_fil) // HX: for cleanup ) // end of [char_stream_vt_make_file] (* ****** ****** *) implement line_stream_vt_make_file {m} {l} (pf_mod, pf_fil | p_fil) = let // fun loop {n:nat} ( pf_fil: FILE m @ l | p_fil: ptr l, n: int n, cs: list_vt (char, n) ) : stream_vt_con (strptr1) = let val c = fgetc1_err (pf_mod | !p_fil) in if c >= 0 then let val c = char_of_int (c) // c <> EOF in if c <> '\n' then loop (pf_fil | p_fil, n+1, list_vt_cons (c, cs)) else let val line = string_make_charlst_rev (n, cs) in stream_vt_cons ( line, line_stream_vt_make_file (pf_mod, pf_fil | p_fil) ) // end of [stream_vt_cons] end // end of [if] end else let val () = fclose1_exn (pf_fil | p_fil) in if n > 0 then let val line = string_make_charlst_rev (n, cs) in stream_vt_cons (line, $ldelay stream_vt_nil) end else let val+ ~list_vt_nil () = cs in stream_vt_nil () end // end of [if] end (* end of [if] *) end (* end of [loop] *) // in // $ldelay ( loop ( pf_fil | p_fil, 0, list_vt_nil () ) // end of [loop] , // HX: separator fclose1_exn (pf_fil | p_fil) // HX: for cleanup ) // end of [$ldelay] // end // end of [char_stream_vt_make_file] (* ****** ****** *) (* end of [filebas.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/syndef.dats0000664000175000017500000000614112223166162020337 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "prelude/SATS/syndef.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" (* ****** ****** *) implement{} atsyndef__list_is_cons (xs) = case+ xs of | list_cons _ => true | list_nil () => false // end of [list_is_cons] implement{a} atsyndef__list_uncons (rxs, rx) = let val+ list_cons (x, xs) = rxs in rx := x; xs end // end of [list_uncons_ref] (* ****** ****** *) (* implement{a} atsyndef__forlist_in_do (xs, f) = let // viewtypedef cloptr0_t = a - void viewtypedef cloptr1_t = (!unit_v | a) - void // val _ptr = __cast (f) where { extern castfn __cast (f: !cloptr0_t >> cloptr1_t):<> ptr } // end of [val] // prval pf = unit_v () val () = list_foreach_cloptr {unit_v} (pf | xs, f) prval unit_v () = pf // val _ptr = __cast (f) where { extern castfn __cast (f: !cloptr1_t >> cloptr0_t):<> ptr } // end of [val] // in // empty end // end of [forlist_in_do] *) (* ****** ****** *) (* implement{a} atsyndef__iforlist_in_do {n} (xs, f) = let // viewtypedef cloptr0_t = (natLt n, a) - void viewtypedef cloptr1_t = (!unit_v | natLt n, a) - void // val _ptr = __cast (f) where { extern castfn __cast (f: !cloptr0_t >> cloptr1_t):<> ptr } // end of [val] // prval pf = unit_v () val () = list_iforeach_cloptr {unit_v} (pf | xs, f) prval unit_v () = pf // val _ptr = __cast (f) where { extern castfn __cast (f: !cloptr1_t >> cloptr0_t):<> ptr } // end of [val] // in // empty end // end of [iforlist_in_do] *) (* ****** ****** *) (* end of [syndef.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/unsafe.dats0000664000175000017500000000476412223166162020341 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // HX: these unsafe features must be used with caution! // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "prelude/SATS/unsafe.sats" (* ****** ****** *) implement{a} ptr0_get (p) = x where { val [l:addr] p = (ptr1_of_ptr)p prval (pf, fpf) = __assert () where { extern praxi __assert (): (a @ l, a? @ l - void) } // end of [prval] val x = !p prval () = fpf (pf) } // end of [ptr0_get] implement{a} ptr0_set (p, x) = () where { val [l:addr] p = (ptr1_of_ptr)p prval (pf, fpf) = __assert () where { extern praxi __assert (): (a? @ l, a @ l - void) } // end of [prval] val () = !p := x prval () = fpf (pf) } // end of [ptr0_set] (* ****** ****** *) implement{a} ptr1_get (p) = ptr0_get (p) implement{a} ptr1_set (p, x) = ptr0_set (p, x) (* ****** ****** *) implement{a} ptrget (p) = ptr0_get (p) implement{a} ptrset (p, x) = ptr0_set (p, x) (* ****** ****** *) (* end of [unsafe.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/lazy.dats0000664000175000017500000001442112223166162020026 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/lazy.sats" (* ****** ****** *) (* local // for call-by-need lazy evaluation assume lazy_t0ype_type (a:t@ype) = ref (thunkvalue a) in implement{a} lazy_force_crypt (r) = $effmask_ref let val (vbox pf | p) = begin ref_get_view_ptr ($decrypt r) // this effect is ignored! end // end of [val] in case+ !p of | ~thunkvalue_thunk (xf) => let val x = $effmask_ref ((xf: () - a) ()) in !p := thunkvalue_value x; x end // end of [thunkvalue_thunk] | thunkvalue_value (x) => let val () = fold@ (!p) in x end // end of [thunkvalue_value] end // end of [lazy_force_crypt] *) implement{a} lazy_force (r) = !r (* ****** ****** *) #define nil stream_nil #define cons stream_cons #define :: stream_cons (* ****** ****** *) fun{a:t@ype} stream_filter_fun_con (xs: stream a, p: a - bool) : stream_con a = begin case+ !xs of | stream_cons (x, xs) => begin if p x then stream_cons (x, stream_filter_fun (xs, p)) else stream_filter_fun_con (xs, p) end // end of [stream_cons] | stream_nil () => stream_nil () end // end of [stream_filter_fun_con] implement{a} stream_filter_fun (xs, p) = $delay (stream_filter_fun_con (xs, p)) // end of [stream_filter_fun] fun{a:t@ype} stream_filter_cloref_con (xs: stream a, p: a - bool) : stream_con a = begin case+ !xs of | stream_cons (x, xs) => begin if p x then stream_cons (x, stream_filter_cloref (xs, p)) else stream_filter_cloref_con (xs, p) end // end of [stream_cons] | stream_nil () => stream_nil () end // end of [stream_filter_cloref_con] implement{a} stream_filter_cloref (xs, p) = $delay (stream_filter_cloref_con (xs, p)) // end of [stream_filter_cloref] (* ****** ****** *) implement{a}{b} stream_map_fun (xs, f) = $delay (begin case+ !xs of | x :: xs => cons (f x, stream_map_fun (xs, f)) | nil () => nil () end : stream_con b) // end of [stream_map_fun] implement{a}{b} stream_map_cloref (xs, f) = $delay (begin case+ !xs of | x :: xs => cons (f x, stream_map_cloref (xs, f)) | nil () => nil () end : stream_con b) // end of [stream_map_cloref] (* ****** ****** *) implement{a1,a2}{b} stream_map2_fun (xs1, xs2, f) = $delay (begin case+ !xs1 of | x1 :: xs1 => begin case+ !xs2 of | x2 :: xs2 => f (x1, x2) :: stream_map2_fun (xs1, xs2, f) | nil () => nil () end // end of [::] | nil () => nil () end : stream_con b) // end of [stream_map2_fun] implement{a1,a2}{b} stream_map2_cloref (xs1, xs2, f) = $delay (begin case+ !xs1 of | x1 :: xs1 => begin case+ !xs2 of | x2 :: xs2 => f (x1, x2) :: stream_map2_cloref (xs1, xs2, f) | nil () => nil () end // end of [::] | nil () => nil () end : stream_con b) // end of [stream_map2_cloref] (* ****** ****** *) implement{a} stream_ordmerge_fun (xs10, xs20, lte) = $delay (begin case+ !xs10 of | x1 :: xs1 => begin case+ !xs20 of | x2 :: xs2 => begin if lte (x1, x2) then begin x1 :: stream_ordmerge_fun (xs1, xs20, lte) end else begin x2 :: stream_ordmerge_fun (xs10, xs2, lte) end // end of [if] end (* end of [::] *) | nil () => x1 :: xs1 end (* end of [::] *) | nil () => !xs20 end : stream_con a) // end of [stream_ordmerge_fun] implement{a} stream_ordmerge_cloref (xs10, xs20, lte) = $delay (begin case+ !xs10 of | x1 :: xs1 => begin case+ !xs20 of | x2 :: xs2 => begin if lte (x1, x2) then begin x1 :: stream_ordmerge_cloref (xs1, xs20, lte) end else begin x2 :: stream_ordmerge_cloref (xs10, xs2, lte) end // end of [if] end (* end of [::] *) | nil () => x1 :: xs1 end (* end of [::] *) | nil () => !xs20 end : stream_con a) // end of [stream_ordmerge_cloref] (* ****** ****** *) implement{a} stream_nth (xs, n) = begin case+ !xs of | x :: xs => if n = 0 then x else stream_nth (xs, n-1) | nil () => $raise StreamSubscriptException () end // end of [stream_nth] (* ****** ****** *) implement{a} stream_take (xs, n) = let fun loop {n:nat} .. ( xs: stream a , n: int n , res: &List_vt a? >> list_vt (a, k) ) :<> #[k:nat | k <= n] void = if n > 0 then (case+ !xs of | stream_cons (x, xs) => let val () = res := list_vt_cons {a} {0} (x, ?) // end of [val] val list_vt_cons (_, !p_res_nxt) = res val () = loop (xs, n-1, !p_res_nxt) in fold@ (res) end // end of [stream_cons] | stream_nil () => (res := list_vt_nil ()) ) else ( res := list_vt_nil () ) // end of [if] var res: List_vt a // uninitialized val () = loop (xs, n, res) in res end // end of [stream_take] (* ****** ****** *) (* end of [lazy.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/float.dats0000664000175000017500000000570012223166162020154 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "prelude/SATS/float.sats" (* ****** ****** *) // // The following kind of code duplication should really be avoided! // implement pow_float_int1 (x, n) = let typedef T = float fun loop {n:nat} .. (x: T, n: int n, res: T):<> T = begin case+ 0 of | _ when n >= 2 => let val n2 = n / 2; val xx = x * x in if n > n2 + n2 then loop (xx, n2, x * res) else loop (xx, n2, res) end | _ when n >= 1 => x * res | _ => res end // end of [loop] in loop (x, n, 1.0: T) end // end of [pow_float_int1] implement pow_double_int1 (x, n) = let typedef T = double fun loop {n:nat} .. (x: T, n: int n, res: T):<> T = begin case+ 0 of | _ when n >= 2 => let val n2 = n / 2; val xx = x * x in if n > n2 + n2 then loop (xx, n2, x * res) else loop (xx, n2, res) end | _ when n >= 1 => x * res | _ => res end // end of [loop] in loop (x, n, 1.0: T) end // end of [pow_double_int1] implement pow_ldouble_int1 (x, n) = let typedef T = ldouble fun loop {n:nat} .. (x: T, n: int n, res: T):<> T = begin case+ 0 of | _ when n >= 2 => let val n2 = n / 2; val xx = x * x in if n > n2 + n2 then loop (xx, n2, x * res) else loop (xx, n2, res) end | _ when n >= 1 => x * res | _ => res end // end of [loop] in loop (x, n, 1.0: T) end // end of [pow_ldouble_int1] (* ****** ****** *) (* end of [float.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/ptrarr.dats0000664000175000017500000000346212223166162020364 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) %{^ ats_size_type atspre_ptrarr_size (ats_ptr_type p0) { char **p = (char**)p0 ; size_t i = 0 ; for (i = 0; *p != (char*)0; i += 1) p += 1 ; return i ; } // end of [atspre_ptrarr_size] %} // end of [%{^] (* ****** ****** *) (* end of [ptrarr.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/memalign.dats0000664000175000017500000000354412223166162020644 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some common memalign operations // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/memalign.sats" (* ****** ****** *) implement ptr_view_conversion {a1,a2} (pf1, pf2) = begin pf2 := ptr_of_b0ytes_v {a2} (pf1, ptr_to_b0ytes_v {a1} (pf2)) end // end of [ptr_view_conversion] (* ****** ****** *) (* end of [memalign.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/pointer.dats0000664000175000017500000000460412223166162020531 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some common pointer operations // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/pointer.sats" (* ****** ****** *) // // HX: this is a proof function // implement ptr_is_gtez {l} (p) = addr_is_gtez {l} () (* ****** ****** *) implement{a} ptr_alloc () = ptr_alloc_tsz {a} (sizeof) (* ****** ****** *) implement{a} ptr_zero (pf | x) = ptr_zero_tsz {a} (pf | x, sizeof) (* ****** ****** *) implement{a} ptr_get_t (pf | p) = !p implement{a} ptr_set_t (pf | p, x) = (!p := x) implement{a} ptr_move_t (pf1, pf2 | p1, p2) = (!p2 := !p1) (* ****** ****** *) implement{a} ptr_get_vt (pf | p) = !p implement{a} ptr_set_vt (pf | p, x) = (!p := x) implement{a} ptr_move_vt (pf1, pf2 | p1, p2) = (!p2 := !p1) (* ****** ****** *) implement{a} ptr_get_inv (pf | p) = !p implement{a} ptr_set_inv (pf | p, x) = (!p := x) (* ****** ****** *) (* end of [pointer.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/sizetype.dats0000664000175000017500000000417712223166162020732 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no initialization is needed (* ****** ****** *) staload "prelude/SATS/sizetype.sats" (* ****** ****** *) implement divmod_size1_size1 {m,n} (m, n, r) = let // prval () = size_param_lemma (m) prval () = size_param_lemma (n) // val (pfdiv_mn | q) = div2_size1_size1 (m, n) val (pfmul_qn | qn) = mul2_size1_size1 (q, n) // prval pfdivmod_mn = divmod_istot {m,n} () prval () = divmod_isfun (pfdiv_mn, pfdivmod_mn) prval pfmul_qn_alt = divmod_elim (pfdivmod_mn) // prval () = mul_isfun (pfmul_qn, pfmul_qn_alt) // val () = r := m - qn in (pfdivmod_mn | q) end // end of [quotrem_size1_size1] (* ****** ****** *) (* end of [sizetype.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/char.dats0000664000175000017500000000324212223166162017763 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "prelude/SATS/char.sats" (* ****** ****** *) // // HX-2013-08: it is yet empty // (* ****** ****** *) (* end of [char.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/printf.dats0000664000175000017500000000766712223166162020367 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "libc/SATS/stdarg.sats" (* ****** ****** *) staload "prelude/SATS/printf.sats" (* ****** ****** *) %{^ #define ATSPRE_SPRINTF_GUESS 16 %} // end of [%{] (* ****** ****** *) %{ ats_void_type atspre_exit_prerrf ( const ats_int_type status, const ats_ptr_type fmt, ... ) { va_list ap ; va_start(ap, fmt) ; vfprintf(stderr, (char*)fmt, ap) ; va_end(ap) ; /* fprintf (stderr, "atspre_exit_prerrf: status = %i\n", status) ; */ exit(status) ; return ; // deadcode } /* end of [atspre_exit_prerrf] */ ats_void_type atspre_assert_prerrf ( ats_bool_type assertion, ats_ptr_type fmt, ... ) { int err ; va_list ap ; if (!assertion) { /* assertion is false */ va_start(ap, fmt) ; err = vfprintf(stderr, (char*)fmt, ap) ; va_end(ap) ; if (err < 0) { ats_exit_errmsg ( err, "[atspre_assert_prerrf]: prerrf failed\n" ) ; } else { ats_exit_errmsg (1, "[atspre_assert_prerrf]: assert failed\n") ; } } /* end of [if] */ return ; } /* end of [atspre_assert_prerrf] */ %} // end of [%{] (* ****** ****** *) %{ ats_ptr_type atspre_vsprintf_size ( const ats_size_type guess , const ats_ptr_type fmt, ats_ref_type ap0 ) { int n, sz ; char *res ; va_list ap ; // sz = guess ; // while (1) { va_copy (ap, *(va_list*)ap0) ; res = ATS_MALLOC(sz) ; n = vsnprintf(res, sz, (char*)fmt, ap) ; if (n >= 0) { if (n < sz) return res ; sz = n+1 ; ATS_FREE(res) ; continue ; } else { return ((ats_ptr_type)0) ; } // end of [if] } // end of [while] // return (ats_ptr_type)0 ; // deadcode // } /* end of [atspre_vsprintf_size] */ ats_ptr_type atspre_vsprintf ( const ats_ptr_type fmt, ats_ref_type ap0 ) { char *res = (char*)atspre_vsprintf_size (ATSPRE_SPRINTF_GUESS, fmt, ap0) ; if (!res) { ats_exit_errmsg (1, "exit(ATS): [atspre_vsprintf] failed.\n") ; } // end of [if] return res ; } // end of [atspre_vsprintf] %} // end of [%{] (* ****** ****** *) implement tostringf_size (guess, fmt, arg) = let // [va_start (arg, fmt)] is emitted by atsopt val str = vsprintf_size (guess, fmt, arg) // [str] may be null val () = va_end (arg) in str end // end of [tostringf_size] implement tostringf (fmt, arg) = let // [va_start (arg, fmt)] is emitted by atsopt val str = vsprintf (fmt, arg) // [str] cannot be null val () = va_end (arg) in str end // end of [tostringf] (* ****** ****** *) (* end of [printf.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/array0.dats0000664000175000017500000001624212223166162020250 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) // // HX: array0 implementation // (* ****** ****** *) staload "prelude/SATS/array0.sats" staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) assume array0_viewt0ype_type (a:viewt@ype) = ref (Arrpsz (a)) (* ****** ****** *) (* // // HX-2011-01-12: // it is a casting function now! // implement array0_get_arrszref (A) = A *) implement array0_make_arrpsz (psz) = ref_make_elt (psz) (* ****** ****** *) implement{a} array0_make_elt (asz, x0) = let val [n:int] asz = size1_of_size asz val tsz = sizeof val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (asz, tsz) var ini: a = x0 val () = array_ptr_initialize_elt_tsz {a} (!p_arr, asz, ini, tsz) in array0_make_arrpsz {a} {n} @(pf_gc, pf_arr | p_arr, asz) end // end of [array0_make_elt] (* ****** ****** *) implement{a} array0_make_lst (xs) = let val [n:int] xs = list_of_list0 (xs) val n = list_length (xs) val asz = size1_of_int1 (n) val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (asz, sizeof) val () = array_ptr_initialize_lst (!p_arr, xs) in array0_make_arrpsz {a} {n} @(pf_gc, pf_arr | p_arr, asz) end // end of [array_make_lst] (* ****** ****** *) implement array0_size (A) = let val (vbox pf_arrpsz | p_psz) = ref_get_view_ptr (A) in p_psz->3 end // end of [array0_size] (* ****** ****** *) implement{a} array0_get_elt_at (A, i) = let val ( vbox pf_psz | p_psz ) = ref_get_view_ptr (A) val i = size1_of_size i val p_data = p_psz->2; val asz = p_psz->3 in if i < asz then let prval pf_data = p_psz->1 val x = p_data->[i] prval () = p_psz->1 := pf_data in x // return value end else begin $raise ArraySubscriptException() end // end of [if] end (* end of [array0_get_elt_at] *) implement{a} array0_get_elt_at__intsz (A, i) = let val i = int1_of_int i in if i >= 0 then begin array0_get_elt_at (A, i2sz i) end else begin $raise ArraySubscriptException() end // end of [if] end (* end of [array0_get_elt_at__intsz] *) (* ****** ****** *) implement{a} array0_set_elt_at (A, i, x) = let val (vbox pf_psz | p_psz) = ref_get_view_ptr (A) val i = size1_of_size i val p_data = p_psz->2; val asz = p_psz->3 in if i < asz then let prval pf_data = p_psz->1 val () = p_data->[i] := x prval () = p_psz->1 := pf_data in () // return no value end else begin $raise ArraySubscriptException() end // end of [if] end (* end of [array0_set_elt_at] *) implement{a} array0_set_elt_at__intsz (A, i, x) = let val i = int1_of_int i in if i >= 0 then begin array0_set_elt_at (A, i2sz i, x) end else begin $raise ArraySubscriptException() end // end of [if] end (* end of [array0_set_elt_at__intsz] *) (* ****** ****** *) implement{a} array0_exch (A, i, j) = let // val ( vbox pf_psz | p_psz ) = ref_get_view_ptr (A) val i = size1_of_size (i) val j = size1_of_size (j) val p_data = p_psz->2; val asz = p_psz->3 // in // if i < asz then let in // if j < asz then let prval pf_data = p_psz->1 val () = array_ptr_exch (!p_data, i, j) prval () = p_psz->1 := pf_data in // nothing end else ( $raise ArraySubscriptException() ) // end of [if] // end else ( $raise ArraySubscriptException() ) // end of [if] // end // end of [array0_exch] implement{a} array0_exch__intsz (A, i, j) = let val i = int1_of_int (i) val j = int1_of_int (j) in // if i >= 0 then let in // if j >= 0 then ( array0_exch (A, (i2sz)i, (i2sz)j) ) else $raise ArraySubscriptException() // end else ( $raise ArraySubscriptException() ) // end of [if] // end (* end of [array0_exch__intsz] *) (* ****** ****** *) implement{a} array0_foreach (A, f) = let fun loop {n:nat} {l:addr} .. ( pf: !array_v (a, n, l) | p: ptr l, n: size_t n, f: (&a) - void ) :<> void = let in // if n > 0 then let prval ( pf1, pf2 ) = array_v_uncons {a} (pf) val () = f (!p) val () = loop (pf2 | p+sizeof, n-1, f) in pf := array_v_cons {a} (pf1, pf2) end // end of [if] // end // end of [loop] // val ( vbox pf_psz | p_psz ) = ref_get_view_ptr (A) // in loop (p_psz->1 | p_psz->2, p_psz->3, f) end // end of [array0_foreach] implement{a} array0_iforeach (A, f) = let // val ( vbox pf_psz | p_psz ) = ref_get_view_ptr (A) stavar n0: int val n0: size_t n0 = p_psz->3 fun loop {n,i:nat | n0==n+i} {l:addr} .. ( pf: !array_v (a, n, l) | p: ptr l, n: size_t n, i: size_t i, f: (size_t, &a) - void ) :<> void = let in // if n > 0 then let prval ( pf1, pf2 ) = array_v_uncons {a} (pf) val () = f (i, !p) val () = loop {n-1,i+1} (pf2 | p+sizeof, n-1, i+1, f) prval () = pf := array_v_cons {a} (pf1, pf2) // in // nothing end // end of [if] // end // end of [loop] // in loop (p_psz->1 | p_psz->2, n0, 0, f) end // end of [array0_iforeach] (* ****** ****** *) implement{a} array0_tabulate (asz, f) = let // val [n0:int] asz = size1_of_size asz val ( pf_gc, pf_arr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) // fun loop {n,i:nat | n0 == n+i} {l:addr} .. ( pf: !array_v (a?, n, l) >> array_v (a, n, l) | p: ptr l, n: size_t n, i: size_t i, f: size_t - a ) :<> void = let in // if n > 0 then let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := f (i) val () = loop (pf2 | p+sizeof, n-1, i+1, f) prval () = pf := array_v_cons {a} (pf1, pf2) in // nothing end else let prval () = array_v_unnil {a?} (pf) prval () = pf := array_v_nil {a} () in // nothing end // end of [if] // end // end of [loop] // val () = loop (pf_arr | p_arr, asz, 0, f) // in array0_make_arrpsz {a}{n0} @(pf_gc, pf_arr | p_arr, asz) end // end of [array0_tabulate] (* ****** ****** *) (* end of [array0.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/dlist_vt.dats0000664000175000017500000002471212223166162020703 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2012 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // HX: no need for dynloading at run-time (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload "prelude/SATS/dlist_vt.sats" (* ****** ****** *) sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) dataviewtype DLIST (a:viewt@ype+, int) = | {r:nat} DLISTcons (a, r+1) of (a, ptr(*prev*), DLIST (a, r)) | DLISTnil (a, 0) of () // end of [DLIST] extern castfn dlist2ptr {a:vt0p}{r:int} (xs: !DLIST(a, r)):<> ptr (* ****** ****** *) assume dlist_viewt0ype_int_int_viewtype (a: vt0p, f:int, r:int) = DLIST (a, r) // end of [assume] (* ****** ****** *) implement{a} dlist_vt_nil () = DLISTnil () (* ****** ****** *) implement{a} dlist_vt_cons (x, xs) = case+ xs of | DLISTcons (_, !p_prev, _) => let prval () = fold@ (xs) val res = DLISTcons (x, null, xs) prval () = __assert (p_prev) where { extern praxi __assert {l:addr} (p: ptr l): [l > null] void } // end of [prval] val () = $UN.ptrset (p_prev, dlist2ptr(res)) in res end // end of [DLISTcons] | ~DLISTnil () => DLISTcons (x, null, DLISTnil ()) // end of [dlist_vt_cons] (* ****** ****** *) implement{a} dlist_vt_snoc (xs, x) = let val node = DLISTcons (x, dlist2ptr(xs), DLISTnil ()) val node1 = __copy (node) where { extern castfn __copy (xs: !DLIST(a, 1)):<> DLIST(a, 1) } val+ DLISTcons (_, prev, !p_xs) = xs val+ DLISTnil () = !p_xs; val () = !p_xs := node1 prval () = fold@ {a} (xs) prval () = __hide (xs) where { extern praxi __hide (xs: DLIST(a, 2)):<> void } // end of [prval] in node end // end of [dlist_vt_snoc] (* ****** ****** *) implement{a} dlist_vt_get {f,r} (xs) = let val+ DLISTcons (x, _, _) = xs in fold@ (xs); x end // end of [dlist_vt_get] implement{a} dlist_vt_set {f,r} (xs, x) = let val+ DLISTcons (!p_x, _, _) = xs in !p_x := x; fold@ (xs) end // end of [dlist_vt_set] (* ****** ****** *) implement{a} dlist_vt_is_beg {f,r} (xs) = let val+ DLISTcons (_, prev, _) = xs prval () = fold@ (xs) val [b:bool] ans = ( if prev > null then false else true ) : Bool // end of [val] prval () = __assert () where { extern praxi __assert (): [b==(f==0)] void } // end of [prval] in ans end // end of [dlist_vt_is_beg] implement{a} dlist_vt_is_end {f,r} (xs) = let val+ DLISTcons (_, _, !p_xs1) = xs val next = dlist2ptr (!p_xs1) prval () = fold@ (xs) val [b:bool] ans = ( if next > null then false else true ) : Bool // end of [val] prval () = __assert () where { extern praxi __assert (): [b==(r==1)] void } // end of [prval] in ans end // end of [dlist_vt_is_end] implement{a} rdlist_vt_is_beg {f,r} (xs) = dlist_vt_is_end {f,r} (xs) // end of [rdlist_vt_is_beg] implement{a} rdlist_vt_is_end {f,r} (xs) = dlist_vt_is_beg {f,r} (xs) // end of [rdlist_vt_is_end] (* ****** ****** *) implement{a} dlist_vt_length {f,r} (xs) = let fun loop {r:nat}{r0:int} .. (xs: !DLIST (a, r), res: int (r0)):<> int (r0+r) = case+ xs of | DLISTcons (_, _, !p_xs) => let val res = loop (!p_xs, res + 1); prval () = fold@ (xs) in res end // end of [DLISTcons] | DLISTnil () => (fold@ (xs); res) // end of [loop] prval () = lemma1_dlist_vt_params {a}{f,r} (xs) in loop (xs, 0) end // end of [dlist_vt_length] implement{a} rdlist_vt_length {f,r} (xs) = let // fun loop {f:nat} .. (prev: ptr, res: int):<> int = let val xs = __cast (prev) where { extern castfn __cast (p: ptr):<> [r:nat] DLIST (a, r) } // end of [val] in case+ xs of | DLISTcons (_, prev, _) => let prval () = fold@ {a} (xs) prval () = __assert () where { extern praxi __assert (): [f > 0] void } // end of [prval] prval () = __free (xs) where { extern praxi __free {r:int} (xs: DLIST (a, r)): void } // end of [prval] in loop {f-1} (prev, res + 1) end // end of [DLISTcons] | ~DLISTnil () => res end // end of [loop] // prval () = lemma1_dlist_vt_params {a}{f,r} (xs) // val res = ( case+ xs of | DLISTcons (_, prev, _) => let prval () = fold@ (xs) in loop {f} (prev, 0) end // end of [DLISTcons] | DLISTnil () => (fold@ (xs); 0) ) : int // end of [val] in __cast (res) where { extern castfn __cast (res: int):<> int (f) } // end of [__cast] end // end of [rdlist_vt_length] (* ****** ****** *) implement{a} dlist_vt_move {f,r} (xs) = let val+ DLISTcons (_, _, !p_xs1) = xs val xs1 = __copy (!p_xs1) where { extern castfn __copy (xs: !DLIST(a, r-1)):<> DLIST(a, r-1) } // end of [val] prval () = fold@ (xs) prval () = __free (xs) where { extern praxi __free (xs: DLIST (a, r)): void } // end of [prval] in xs1 // : dlist_vt (a, f+1, r-1) end // end of [dlist_vt_move] implement{a} rdlist_vt_move {f,r} (xs) = let // prval () = lemma1_dlist_vt_params {a}{f,r} (xs) prval () = ( sif r == 0 then lemma2_dlist_vt_params {a}{f} (xs) else () ) : [r > 0] void // val+ DLISTcons (_, prev, _) = xs prval () = fold@ (xs) prval () = __free (xs) where { extern praxi __free (xs: DLIST (a, r)): void } // end of [prval] in __cast (prev) where { extern castfn __cast (p: ptr):<> DLIST(a, r+1) } // end of [__cast] end // end of [rdlist_vt_move] (* ****** ****** *) implement{a} dlist_vt_move_end {f,r} (xs) = let val isend = dlist_vt_is_end {f,r} (xs) prval () = lemma1_dlist_vt_params {a}{f,r} (xs) in if isend then xs else dlist_vt_move_end {f+1,r-1} (dlist_vt_move {f,r} (xs)) // end of [if] end // end of [dlist_vt_move_end] implement{a} rdlist_vt_move_end {f,r} (xs) = let val isend = rdlist_vt_is_end {f,r} (xs) prval () = lemma1_dlist_vt_params {a}{f,r} (xs) in if isend then xs else rdlist_vt_move_end {f-1,r+1} (rdlist_vt_move {f,r} (xs)) // end of [if] end // end of [rdlist_vt_move_end] (* ****** ****** *) implement{a} dlist_vt_insert {f,r} (xs, x) = let val _xs = dlist2ptr (xs) val+ DLISTcons (_, _, !p_xs1) = xs val xs2 = dlist_vt_cons (x, !p_xs1) val+ DLISTcons (_, !p_prev, _) = xs2 val () = !p_prev := _xs prval () = fold@ {a} (xs2) val () = !p_xs1 := xs2 prval () = fold@ {a} (xs) in xs end // end of [dlist_vt_insert] (* ****** ****** *) implement{a} dlist_vt_free {r} (xs) = let fun loop {r:nat} .. (xs: DLIST (a, r)):<> void = case+ xs of | ~DLISTcons (_, _, xs) => loop (xs) | ~DLISTnil () => () // end of [loop] prval () = lemma1_dlist_vt_params {a}{0,r} (xs) in loop (xs) end // end of [dlist_vt_free] (* ****** ****** *) implement{a} dlist_vt_foreach_funenv {v}{vt}{f,r}{fe} (pfv | xs, f, env) = let // fun loop {f,r:int | r >= 0} .. ( pfv: !v | xs: !dlist_vt (a, f, r) , f: !(!v | &a, !vt) - void, env: !vt ) : void = case+ xs of | DLISTcons (!p_x, _, !p_xs1) => let val () = f (pfv | !p_x, env) val () = loop (pfv | !p_xs1, f, env) prval () = fold@ (xs) in // nothing end // end of [DLISTcons] | DLISTnil () => fold@ (xs) // end of [loop] // prval () = lemma1_dlist_vt_params {a}{f,r} (xs) // in loop (pfv | xs, f, env) end // end of [dlist_vt_foreach_funenv] implement{a} dlist_vt_foreach_fun {f,r} {fe:eff} (xs, f) = let // typedef fun0_t = (&a) - void typedef fun1_t = (!unit_v | &a, !ptr) - void // val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } prval pf = unit_v () val () = dlist_vt_foreach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf // in // nothing end // end of [dlist_vt_foreach_fun] (* ****** ****** *) implement{a} rdlist_vt_foreach_funenv {v}{vt}{f,r}{fe} (pfv | xs, f, env) = let // fun loop {f:nat} .. ( pfv: !v | prev: ptr, f: !(!v | &a, !vt) - void, env: !vt ) : void = let val xs = __cast (prev) where { extern castfn __cast (p: ptr):<> [r:nat] DLIST (a, r) } // end of [val] in case+ xs of | DLISTcons (!p_x, prev, _) => let val () = f (pfv | !p_x, env) prval () = fold@ {a} (xs) prval () = __assert () where { extern praxi __assert (): [f > 0] void } // end of [prval] prval () = __free (xs) where { extern praxi __free {r:int} (xs: DLIST (a, r)): void } // end of [prval] in loop {f-1} (pfv | prev, f, env) end // end of [DLISTcons] | ~DLISTnil () => () end // end of [loop] // prval () = lemma1_dlist_vt_params {a}{f,r} (xs) // in // case+ xs of | DLISTcons (_, prev, _) => let prval () = fold@ (xs) in loop {f} (pfv | prev, f, env) end // end of [DLISTcons] | DLISTnil () => fold@ (xs) // end // end of [rdlist_vt_foreach_funenv] implement{a} rdlist_vt_foreach_fun {f,r} {fe:eff} (xs, f) = let // typedef fun0_t = (&a) - void typedef fun1_t = (!unit_v | &a, !ptr) - void // val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } prval pf = unit_v () val () = rdlist_vt_foreach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf // in // nothing end // end of [rdlist_vt_foreach_fun] (* ****** ****** *) (* end of [dlist_vt.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/matrix0.dats0000664000175000017500000002122212223166162020430 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // matrix0 implementation // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/matrix0.sats" staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) assume matrix0_viewt0ype_type (a:viewt@ype) = ref [l:addr] [m,n:nat] [mn:int] ( MUL (m, n, mn), free_gc_v (a?, mn, l), @[a][mn] @ l | ptr l, size_t m, size_t n ) // end of [matrix0_viewt0ype_type] (* ****** ****** *) implement matrix0_make_arrpsz {a} {m,n} (m, n, psz) = let prval pfmul = mul_istot {m,n} () prval () = mul_elim (pfmul) in ref @(pfmul, psz.0, psz.1 | psz.2, m, n) end // end of [matrix0_make_arrpsz] implement matrix0_make_arrpsz__main {a} {m,n} {mn} (pfmul | m, n, psz) = let in ref @(pfmul, psz.0, psz.1 | psz.2, m, n) end (* end of [matrix0_make_arrpsz] *) (* ****** ****** *) implement{a} matrix0_make_elt (row, col, x0) = let val [m:int] row = size1_of_size (row) val [n:int] col = size1_of_size (col) val [mn:int] (pfmul | asz) = mul2_size1_size1 (row, col) prval () = mul_nat_nat_nat (pfmul) val tsz = sizeof val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (asz, tsz) var ini: a = x0 val () = array_ptr_initialize_elt_tsz {a} (!p_arr, asz, ini, tsz) in matrix0_make_arrpsz__main {a} (pfmul | row, col, @(pf_gc, pf_arr | p_arr, asz)) end // end of [matrix0_make_elt] (* ****** ****** *) implement matrix0_row (M) = let val (vbox pf | p) = ref_get_view_ptr (M) in p->4 end // end of [matrix0_row] implement matrix0_col (M) = let val (vbox pf | p) = ref_get_view_ptr (M) in p->5 end // end of [matrix0_col] (* ****** ****** *) // this one is proven in [matrix.dats] extern prfun lemma_for_matrix_subscripting {m,n:nat} {i:nat | i < m} {mn,p:int} (pf1: MUL (m, n, mn), pf2: MUL (i, n, p)): [p+n <= mn] void // end of [lemma_for_matrix_subscripting] implement{a} matrix0_get_elt_at (M, i, j) = let val (vbox pf | p) = ref_get_view_ptr (M) val i = size1_of_size i val j = size1_of_size j val p_data = p->3; val row = p->4 and col = p->5 in if i < row then ( if j < col then let prval pf_data = p->2 val (pfmul | icol) = mul2_size1_size1 (i, col) prval () = lemma_for_matrix_subscripting (p->0, pfmul) prval () = mul_nat_nat_nat (pfmul) val x = p_data->[icol + j] prval () = p->2 := pf_data in x // return value end else // out-of-col $raise MatrixSubscriptException () // end of [if] ) else ( $raise MatrixSubscriptException () // out-of-row ) // end of [if] end (* end of [matrix0_get_elt_at] *) implement{a} matrix0_set_elt_at (M, i, j, x) = let val (vbox pf | p) = ref_get_view_ptr (M) val i = size1_of_size i val j = size1_of_size j val p_data = p->3; val row = p->4 and col = p->5 in if i < row then ( if j < col then let prval pf_data = p->2 val (pfmul | icol) = mul2_size1_size1 (i, col) prval () = lemma_for_matrix_subscripting (p->0, pfmul) prval () = mul_nat_nat_nat (pfmul) val () = p_data->[icol + j] := x prval () = p->2 := pf_data in // nothing end else // out-of-col $raise MatrixSubscriptException () // end of [if] ) else ( $raise MatrixSubscriptException () // out-of-row ) // end of [if] end (* end of [matrix0_set_elt_at] *) (* ****** ****** *) implement{a} matrix0_get_elt_at__intsz (A, i, j) = let val i = int1_of_int i and j = int1_of_int j in if i >= 0 then ( if j >= 0 then ( matrix0_get_elt_at (A, i2sz i, i2sz j) ) else ( $raise MatrixSubscriptException () ) // end of [if] ) else ( $raise MatrixSubscriptException () // out-of-row ) // end of [if] end (* end of [matrix0_get_elt_at__intsz] *) implement{a} matrix0_set_elt_at__intsz (A, i, j, x) = let val i = int1_of_int i and j = int1_of_int j in if i >= 0 then ( if j >= 0 then ( matrix0_set_elt_at (A, i2sz i, i2sz j, x) ) else ( $raise MatrixSubscriptException () ) // end of [if] ) else ( $raise MatrixSubscriptException () // out-of-row ) // end of [if] end (* end of [matrix0_set_elt_at__intsz] *) (* ****** ****** *) implement{a} matrix0_foreach (M, f) = let fun loop {k:nat} {l:addr} .. ( pf: !array_v (a, k, l) | p: ptr l, k: size_t k, f: (&a) - void ) :<> void = if k > 0 then let prval (pf1, pf2) = array_v_uncons {a} (pf) val () = f (!p) val () = loop (pf2 | p+sizeof, k-1, f) in pf := array_v_cons {a} (pf1, pf2) end // end of [if] // end of [loop] val (vbox pf | p) = ref_get_view_ptr (M) val m = p->4 and n = p->5 val (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) prval () = mul_isfun (pf_mn, p->0) in loop (p->2 | p->3, mn, f) end // end of [matrix0_foreach] (* ****** ****** *) implement{a} matrix0_iforeach (M, f) = let fun loop {k:nat} {l:addr} .. ( pf: !array_v (a, k, l) | p: ptr l, k: size_t k , i: size_t, n: size_t, j: size_t , f: (size_t, size_t, &a) - void ) :<> void = if k > 0 then let prval (pf1, pf2) = array_v_uncons {a} (pf) val () = f (i, j, !p) val j1 = j+1 val () = (if j1 < n then loop (pf2 | p+sizeof, k-1, i, n, j1, f) else loop (pf2 | p+sizeof, k-1, i+1, n, 0, f) ) : void in pf := array_v_cons {a} (pf1, pf2) end // end of [if] // end of [loop] val (vbox pf | p) = ref_get_view_ptr (M) val m = p->4 and n = p->5 val (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) prval () = mul_isfun (pf_mn, p->0) in loop (p->2 | p->3, mn, 0, n, 0, f) end // end of [matrix0_iforeach] (* ****** ****** *) implement{a} matrix0_tabulate (row, col, f) = let val [m:int] m = size1_of_size row val [n:int] n = size1_of_size col val [mn:int] (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) val (pf_gc, pf_arr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) fun loop {k:nat} {l:addr} .. ( pf: !array_v (a?, k, l) >> array_v (a, k, l) | p: ptr l, k: size_t k , i: size_t, n: size_t n, j: size_t, f: (size_t, size_t) - a ) :<> void = if k > 0 then let prval (pf1, pf2) = array_v_uncons {a?} (pf) val () = !p := f (i, j) val j1 = j+1 in if j1 < n then let val () = loop (pf2 | p+sizeof, k-1, i, n, j1, f) in pf := array_v_cons {a} (pf1, pf2) end else let val () = loop (pf2 | p+sizeof, k-1, i+1, n, 0, f) in pf := array_v_cons {a} (pf1, pf2) end // end of [if] end else let prval () = array_v_unnil {a?} (pf) in pf := array_v_nil {a} () end // end of [if] // end of [loop] val () = loop (pf_arr | p_arr, mn, 0, n, 0, f) in matrix0_make_arrpsz__main {a} (pf_mn | m, n, @(pf_gc, pf_arr | p_arr, mn)) end // end of [array0_tabulate] (* ****** ****** *) // [matrix0.sats] is already loaded by a call to [pervasive_load] staload _(*anonymous*) = "prelude/SATS/matrix0.sats" // this forces that the static // loading function for [matrix0.sats] is to be called at run-time // this is really needed only if some datatypes are declared in [matrix0.sats] (* ****** ****** *) (* end of [matrix0.dats] *) ats-lang-anairiats-0.2.11/prelude/DATS/reference.dats0000664000175000017500000000475212223166162021013 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // some built-in static constants for reference operations (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "prelude/SATS/reference.sats" (* ****** ****** *) (* assume ref_viewt0ype_type (a:viewt@ype) = [l:addr] @(vbox (a @ l) | ptr l) *) (* ****** ****** *) implement{a} ref (x) = begin let var x = x in ref_make_elt_tsz {a} (x, sizeof) end end // end of [ref_make_elt] // [ref_make_elt] is the same as [ref] implement{a} ref_make_elt (x) = ref (x) (* ****** ****** *) implement{a} ref_get_elt (r) = !r implement{a} ref_set_elt (r, x) = (!r := x) (* ****** ****** *) // implement{a} refconst_get_elt (r) = !r (* ****** ****** *) implement{a} ref_swap (r, x) = let val (vbox pf | p) = ref_get_view_ptr r; val tmp = !p in !p := x; x := tmp end // end of [ref_swap] (* ****** ****** *) implement ref_app_fun {a} (r, f) = begin let val (vbox pf | p) = ref_get_view_ptr r in f (!p) end end // end of [ref_app_fun] (* ****** ****** *) (* end of [reference.dats] *) ats-lang-anairiats-0.2.11/prelude/basics_sta.sats0000664000175000017500000006434612223166162020461 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: 2007 // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [basic_sta.sats] starts!\n" #endif // end of [VERBOSE_PRELUDE] (* ****** ****** *) (* some integer constants *) #define power_2_4 0x10 #define power_2_5 0x20 #define power_2_6 0x40 #define power_2_7 0x80 #define power_2_8 0x100 #define power_2_10 0x400 #define power_2_15 0x8000 #define power_2_16 0x10000 #define power_2_20 0x100000 #define power_2_31 0x80000000 #define power_2_32 0x100000000 #define power_2_63 0x8000000000000000 #define power_2_64 0x10000000000000000 (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) // some unindexed types (* ****** ****** *) abst@ype bool_t0ype = $extype"ats_bool_type" abst@ype byte_t0ype = $extype"ats_byte_type" // sizeof (byte) = 1 (* ****** ****** *) abst@ype char_t0ype = $extype"ats_char_type" abst@ype schar_t0ype = $extype"ats_schar_type" abst@ype uchar_t0ype = $extype"ats_uchar_type" (* ****** ****** *) abstype clo_t0ype // ats_clo_type // unnamed (* ****** ****** *) abst@ype double_t0ype = $extype"ats_double_type" (* ****** ****** *) absviewtype exception_viewtype // boxed type // unamed (* ****** ****** *) // abst@ype int_t0ype = $extype"ats_int_type" abst@ype uint_t0ype = $extype"ats_uint_type" // abst@ype int_short_t0ype = $extype"ats_sint_type" abst@ype uint_short_t0ype = $extype"ats_usint_type" // abst@ype int_short_short_t0ype = $extype"ats_sint_type" abst@ype uint_short_short_t0ype = $extype"ats_ussint_type" // abst@ype int_long_t0ype = $extype"ats_lint_type" abst@ype uint_long_t0ype = $extype"ats_ulint_type" // abst@ype int_long_long_t0ype = $extype"ats_llint_type" abst@ype uint_long_long_t0ype = $extype"ats_ullint_type" // abst@ype intmax_t0ype = $extype"ats_intmax_type" abst@ype uintmax_t0ype = $extype"ats_uintmax_type" // // HX: integer types guaranteed to be of one word size // abstype intptr_type = $extype"ats_intptr_type" // named abstype uintptr_type = $extype"ats_uintptr_type" // named // // HX: integer types with fixed size // abst@ype int8_t0ype = $extype"ats_int8_type" abst@ype uint8_t0ype = $extype"ats_uint8_type" // abst@ype int16_t0ype = $extype"ats_int16_type" abst@ype uint16_t0ype = $extype"ats_uint16_type" // abst@ype int32_t0ype = $extype"ats_int32_type" abst@ype uint32_t0ype = $extype"ats_uint32_type" // abst@ype int64_t0ype = $extype"ats_int64_type" abst@ype uint64_t0ype = $extype"ats_uint64_type" // // HX: integer types for sizes // abst@ype size_t0ype = $extype"ats_size_type" abst@ype ssize_t0ype = $extype"ats_ssize_type" abst@ype ptrdiff_t0ype = $extype"ats_ptrdiff_type" // (* ****** ****** *) // // HX: unindexed type for pointers // abstype ptr_type = $extype"ats_ptr_type" // unnamed abstype ptrself_type = $extype"ats_ptrself_type" // named // (* ****** ****** *) abstype string_type // boxed type // unnamed abst@ype strbuf_t0ype // a type of variable size (* ****** ****** *) // // HX-2010-10-23: // sizeof (void) is undefined in the standard but GCC sets it to 1 // For instance, try to compile with the flags: '-ansi' and '-pedantic' // abst@ype void_t0ype = $extype"ats_void_type" // // HX-2010-10-23: [ats_empty_type] is a struct of no fields // abst@ype empty_t0ype = $extype"ats_empty_type" // sizeof(empty) = 0 // // HX-2011-02-11: [ats_undefined_type] is undefined // abst@ype undefined_t0ype = $extype"ats_undefined_type" absviewt@ype undefined_viewt0ype = $extype"ats_undefined_type" // (* ****** ****** *) // // HX: some built-in static constants for integer operations // stacst neg_int_int : int -> int (* integer negation *) stadef ~ = neg_int_int // stacst add_int_int_int : (int, int) -> int (* addition *) stadef + = add_int_int_int // stacst sub_int_int_int: (int, int) -> int (* subtraction *) stadef - = sub_int_int_int // stacst mul_int_int_int : (int, int) -> int (* multiplication *) stadef * = mul_int_int_int // stacst div_int_int_int : (int, int) -> int (* division *) stadef / = div_int_int_int // (* stacst mod_int_int_int : (int, int) -> int (* modulo operation *) stadef mod = mod_int_int_int *) // [y] is required to be a constant stadef mod (x:int, y:int) = x - y * (x / y) // stacst abs_int_int : int -> int stadef abs = abs_int_int // stacst max_int_int_int : (int, int) -> int stadef max = max_int_int_int // stacst min_int_int_int : (int, int) -> int stadef min = min_int_int_int // stadef nsub_int_int_int (x:int, y:int) = max (x-y, 0) stadef nsub = nsub_int_int_int // stacst int_of_bool : bool -> int and bool_of_int : int -> bool stacst int_of_char : char -> int and char_of_int : int -> char // (* ****** ****** *) // // HX: some built-in boolean constants // stacst true_bool : bool and false_bool : bool stadef true = true_bool and false = false_bool // // HX: some built-in static constants for boolean operations // stacst neg_bool_bool : bool -> bool (* boolean negation *) stadef ~ = neg_bool_bool // stacst mul_bool_bool_bool : (bool, bool) -> bool (* conjunction *) stadef && = mul_bool_bool_bool // stacst add_bool_bool_bool : (bool, bool) -> bool (* disjunction *) stadef || = add_bool_bool_bool // stacst gt_bool_bool_bool : (bool, bool) -> bool stadef > = gt_bool_bool_bool // stacst gte_bool_bool_bool : (bool, bool) -> bool stadef >= = gte_bool_bool_bool // stacst lt_bool_bool_bool : (bool, bool) -> bool stadef < = lt_bool_bool_bool // stacst lte_bool_bool_bool : (bool, bool) -> bool stadef <= = lte_bool_bool_bool // stacst eq_bool_bool_bool : (bool, bool) -> bool stadef == = eq_bool_bool_bool // stacst neq_bool_bool_bool : (bool, bool) -> bool stadef <> = neq_bool_bool_bool stadef != = neq_bool_bool_bool // (* ****** ****** *) // // HX: some built-in static constants for char comparisons // stacst sub_char_char_int : (char, char) -> int stadef - = sub_char_char_int // stacst gt_char_char_bool : (char, char) -> bool stadef > = gt_char_char_bool // stacst gte_char_char_bool : (char, char) -> bool stadef >= = gte_char_char_bool // stacst lt_char_char_bool : (char, char) -> bool stadef < = lt_char_char_bool // stacst lte_char_char_bool : (char, char) -> bool stadef <= = lte_char_char_bool // stacst eq_char_char_bool : (char, char) -> bool stadef == = eq_char_char_bool // stacst neq_char_char_bool : (char, char) -> bool stadef <> = neq_char_char_bool stadef != = neq_char_char_bool // (* ****** ****** *) // // HX: some built-in static constants for integer comparisons // stacst gt_int_int_bool : (int, int) -> bool stadef > = gt_int_int_bool // stacst gte_int_int_bool : (int, int) -> bool stadef >= = gte_int_int_bool // stacst lt_int_int_bool : (int, int) -> bool stadef < = lt_int_int_bool // stacst lte_int_int_bool : (int, int) -> bool stadef <= = lte_int_int_bool // stacst eq_int_int_bool : (int, int) -> bool stadef == = eq_int_int_bool // stacst neq_int_int_bool : (int, int) -> bool stadef <> = neq_int_int_bool stadef != = neq_int_int_bool // // HX: some built-in static constants for pointer arithmetic // stacst null_addr : addr stadef null = null_addr // stacst add_addr_int_addr : (addr, int) -> addr stadef + = add_addr_int_addr // stacst sub_addr_int_addr : (addr, int) -> addr stadef - = sub_addr_int_addr // stacst sub_addr_addr_int : (addr, addr) -> int stadef - = sub_addr_addr_int // stacst gt_addr_addr_bool : (addr, addr) -> bool stadef > = gt_addr_addr_bool // stacst gte_addr_addr_bool : (addr, addr) -> bool stadef >= = gte_addr_addr_bool // stacst lt_addr_addr_bool : (addr, addr) -> bool stadef < = lt_addr_addr_bool // stacst lte_addr_addr_bool : (addr, addr) -> bool stadef <= = lte_addr_addr_bool // stacst eq_addr_addr_bool : (addr, addr) -> bool stadef == = eq_addr_addr_bool // stacst neq_addr_addr_bool : (addr, addr) -> bool stadef <> = neq_addr_addr_bool stadef != = neq_addr_addr_bool // (* ****** ****** *) (* ** subclass relation *) stacst lte_cls_cls_bool : (cls, cls) -> bool stadef <= = lte_cls_cls_bool (* ****** ****** *) (* // // HX: // some built-in static constants for rationals // not yet supported and may never be supported // sta ~ : rat -> rat (* rational negation *) sta + : (rat, rat) -> rat (* addition *) and - : (rat, rat) -> rat (* subtraction *) and * : (rat, rat) -> rat (* multiplication *) and / : (rat, int) -> rat (* division *) and / : (rat, rat) -> rat (* division *) // sta > : (rat, rat) -> bool sta > : (rat, int) -> bool and >= : (rat, rat) -> bool and < : (rat, rat) -> bool and <= : (rat, rat) -> bool and <> : (rat, rat) -> bool and == : (rat, rat) -> bool // *) (* ****** ****** *) // viewtypedef bottom_t0ype_uni = {a:t0p} a viewtypedef bottom_t0ype_exi = [a:t0p | false] a // viewtypedef bottom_viewt0ype_uni = {a:vt0p} a viewtypedef bottom_viewt0ype_exi = [a:vt0p | false] a // (* ****** ****** *) // // HX: some built-in type/viewtype/prop/view constructors // absview at_viewt0ype_addr_view (viewt@ype+, addr) stadef @ = at_viewt0ype_addr_view // HX: @ is infix (* ****** ****** *) abstype ref_viewt0ype_type (viewt@ype) // boxed type // unnamed stadef ref = ref_viewt0ype_type abstype refconst_t0ype_type (t@ype) // boxed type // unnamed stadef refconst = refconst_t0ype_type (* // // HX-2009: should this be added? // abstype refopt_viewt0ype_bool_type (viewt@ype, bool) // unnamed stadef refopt = refopt_viewt0ype_bool_type // typedef Refopt (a: vt0p) = [b:bool] refopt (a, b) // *) (* ****** ****** *) // // HX: for boxing a view // absprop vbox_view_prop (view) stadef vbox = vbox_view_prop // // HX: for taking out a field // abst@ype without_viewt0ype_t0ype (viewt@ype) stadef without = without_viewt0ype_t0ype // (* ****** ****** *) viewdef vtakeout (v1: view, v2: view) = (v2, v2 - v1) viewtypedef vttakeout (vt1: viewt@ype, vt2: viewt@ype) = (vt2 - vt1 | vt2) // end of [vttakeout] (* ****** ****** *) (* // // HX: support for union type may be removed // absviewt@ype opt_viewt0ype_int_viewt0ype (a:viewt@ype+, i:int) = union (i) { value= a } stadef opt = value_viewt0ype_int_viewt0ype *) absviewt@ype opt_viewt0ype_bool_viewt0ype (a:viewt@ype+, opt:bool) = a stadef opt = opt_viewt0ype_bool_viewt0ype // // HX-2010-03-23: resulting in incorrect erasure // stadef Opt (a:vt0p) = [b:bool] opt (a, b) // (* ****** ****** *) (* // HX-2008: // this is not yet supported and may never be datasort stamp = (* abstract *) // be supported // sta vfrac : (stamp, view, rat) -> view absview vfrac (stamp, view, rat) // sta vtfrac : (stamp, viewtype, rat) -> viewtype absviewtype vtfrac (stamp, viewtype, rat) *) (* ****** ****** *) // // HX: built-in dependent type constructors // abstype array0_viewt0ype_type (elt:viewt@ype) // unnamed abstype array_viewt0ype_int_type (elt:viewt@ype, sz:int) // unnamed // abstype matrix0_viewt0ype_type (elt:viewt@ype) // unnamed abstype matrix_viewt0ype_int_int_type (elt:viewt@ype, nrow:int, ncol:int) // (* ****** ****** *) abst@ype bool_bool_t0ype (bool) = bool_t0ype abst@ype char_char_t0ype (char) = char_t0ype abst@ype int_int_t0ype (int) = int_t0ype abst@ype uint_int_t0ype (int) = uint_t0ype abst@ype lint_int_t0ype (int) = int_long_t0ype abst@ype ulint_int_t0ype (int) = uint_long_t0ype abst@ype llint_int_t0ype (int) = int_long_long_t0ype abst@ype ullint_int_t0ype (int) = uint_long_long_t0ype abst@ype size_int_t0ype (i:int) = size_t0ype abst@ype ssize_int_t0ype (i:int) = ssize_t0ype abst@ype ptrdiff_int_t0ype (i:int) = ptrdiff_t0ype (* ****** ****** *) abstype ptr_addr_type (addr) = ptr_type // named (* ****** ****** *) abstype string_int_type (int) // unnamed abstype stropt_int_type (int) // unnamed abst@ype strbuf_int_int_t0ype (bsz: int, len: int) // of variable size absviewtype strptr_addr_int_viewtype (addr, int) // for linear strings absviewtype strptr_addr_viewtype (addr) // for linear strings (* ****** ****** *) // // HX: The following definitions are needed in the ATS constraint solver // // absolute value function relation // stadef abs_int_int_bool (x: int, v: int): bool = (x >= 0 && x == v) || (x <= 0 && ~x == v) stadef abs_r = abs_int_int_bool // // HX: in-between relation // stadef btw_int_int_int_bool (x: int, y: int, z:int): bool = (x <= y && y < z) // // HX: int_of_bool conversion // stadef int_of_bool_bool (b: bool, v: int): bool = (b && v == 1) || (~b && v == 0) // // HX: maximum function relation // stadef max_int_int_int_bool (x: int, y: int, v: int): bool = (x >= y && x == v) || (x <= y && y == v) stadef max_r = max_int_int_int_bool // // HX: minimum function relation // stadef min_int_int_int_bool (x: int, y: int, v: int): bool = (x >= y && y == v) || (x <= y && x == v) stadef min_r = min_int_int_int_bool // // HX: sign function relation // stadef sgn_int_int_bool (x: int, v: int): bool = (x > 0 && v == 1) || (x == 0 && v == 0) || (x < 0 && v == ~1) stadef sgn_r = sgn_int_int_bool // // HX: division relation (nat) // stadef ndiv_int_int_int_bool (x: int, y: int, q: int): bool = (q * y <= x && x < q * y + y) stadef ndiv_r = ndiv_int_int_int_bool // // HX: division relation (int) // stadef div_int_int_int_bool (x: int, y: int, q: int) = (x >= 0 && y > 0 && ndiv_int_int_int_bool (x, y, q)) || (x >= 0 && y < 0 && ndiv_int_int_int_bool (x, ~y, ~q)) || (x <= 0 && y > 0 && ndiv_int_int_int_bool (~x, y, ~q)) || (x <= 0 && y < 0 && ndiv_int_int_int_bool (~x, ~y, q)) stadef div_r = div_int_int_int_bool // // HX: modulo relation // not handled yet // (* ****** ****** *) stadef size_int_int_bool (sz:int, n:int) = n >= 0 stacst sizeof_viewt0ype_int : viewt@ype -> int stadef sizeof = sizeof_viewt0ype_int (* ****** ****** *) // // HX: introduce some short names // stadef array0 = array0_viewt0ype_type // with dynamic size stadef array = array_viewt0ype_int_type // without dynamic size stadef matrix0 = matrix0_viewt0ype_type // with dynamic size stadef matrix = matrix_viewt0ype_int_int_type // without dynamic size stadef bool = bool_t0ype stadef bool = bool_bool_t0ype stadef byte = byte_t0ype (* ****** ****** *) stadef char = char_t0ype stadef char = char_char_t0ype stadef uchar = uchar_t0ype stadef schar = schar_t0ype (* ****** ****** *) stadef double = double_t0ype (* ****** ****** *) stadef exn = exception_viewtype // a boxed type (* ****** ****** *) stadef int = int_t0ype stadef int = int_int_t0ype stadef uint = uint_t0ype stadef uint = uint_int_t0ype stadef size_t = size_t0ype stadef size_t = size_int_t0ype stadef ssize_t = ssize_t0ype stadef ssize_t = ssize_int_t0ype stadef ptrdiff_t = ptrdiff_t0ype stadef ptrdiff_t = ptrdiff_int_t0ype (* ****** ****** *) stadef ptr = ptr_type stadef ptr = ptr_addr_type (* ****** ****** *) stadef strbuf = strbuf_int_int_t0ype stadef strbuf (bsz:int) = [len:int | 0 <= len] strbuf (bsz, len) stadef string = string_int_type stadef string = string_type stadef stropt = stropt_int_type stadef strptr = strptr_addr_viewtype // for linear strings stadef strptr0 = [l:addr] strptr (l) stadef Strptr0 = strptr0 stadef strptr1 = [l:addr | l > null] strptr (l) stadef Strptr1 = strptr1 stadef strptrlen = strptr_addr_int_viewtype // for linear strings with length (* ****** ****** *) stadef void = void_t0ype // sizeof(void) = 1 stadef empty = empty_t0ype // sizeof(empty) = 0 stadef undefined_t= undefined_t0ype // sizeof(undefined) = ? stadef undefined_vt= undefined_viewt0ype // sizeof(undefined_vt) = ? (* ****** ****** *) datatype unit = unit of () typedef Bool = [b:bool] bool b typedef Char = [c:char] char c typedef Int = [i:int] int i typedef intLt (n:int) = [i:int | i < n] int i typedef intLte (n:int) = [i:int | i <= n] int i typedef intGt (n:int) = [i:int | i > n] int i typedef intGte (n:int) = [i:int | i >= n] int i typedef intBtw (lb:int, ub:int) = [i: int | lb <= i; i < ub] int i typedef intBtwe (lb:int, ub:int) = [i: int | lb <= i; i <= ub] int i typedef Nat = [n:int | n >= 0] int n typedef natLt (n:int) = [i:int | 0 <=i; i < n] int i typedef natLte (n:int) = [i:int | 0 <= i; i <= n] int i typedef Pos = intGt 0 typedef Neg = intLt 0 typedef Sgn = [i:int | ~1 <= i; i <= 1] int i typedef Ptr = [l:addr] ptr (l) typedef Ptr1 = [l:addr | l > null] ptr (l) typedef Ptrnull (l:addr) = [l1:addr | l1 == null || l1 == l] ptr (l1) // end of [Ptrnull] typedef String = [n:int | n >= 0] string (n) typedef Stropt = [n:int] stropt (n) typedef stropt = Stropt typedef uInt = [n:int | n >=0] uint n (* ****** ****** *) typedef sizeof_t (a:vt0p) = size_int_t0ype (sizeof_viewt0ype_int a) // end of [sizeof_t] typedef Size = [i:int | i >= 0] size_t i typedef sizeLt (n: int) = [i:int | 0 <= i; i < n] size_t (i) typedef sizeLte (n: int) = [i:int | 0 <= i; i <= n] size_t (i) typedef sizeGt (n: int) = [i:int | i > n] size_t (i) typedef sizeGte (n: int) = [i:int | i >= n] size_t (i) typedef sizeBtw (lb:int, ub:int) = [i: int | lb <= i; i < ub] size_t i typedef sizeBtwe (lb:int, ub:int) = [i: int | lb <= i; i <= ub] size_t i typedef SSize = [i:int] ssize_t i typedef ssizeBtw (lb:int, ub:int) = [i: int | lb <= i; i < ub] ssize_t i typedef ssizeBtwe (lb:int, ub:int) = [i: int | lb <= i; i <= ub] ssize_t i (* ****** ****** *) // // HX: for memory deallocation (with/without GC) // absview free_gc_addr_view (l:addr) stadef free_gc_v = free_gc_addr_view absview free_ngc_addr_view (l:addr) stadef free_ngc_v = free_ngc_addr_view absview free_gc_t0ype_addr_view (a:t@ype+, l:addr) stadef free_gc_v = free_gc_t0ype_addr_view absview free_ngc_t0ype_addr_view (a:t@ype+, l:addr) stadef free_ngc_v = free_ngc_t0ype_addr_view absview free_gc_t0ype_int_addr_view (a:t@ype+, n:int, l:addr) stadef free_gc_v = free_gc_t0ype_int_addr_view absview free_ngc_t0ype_int_addr_view (a:t@ype+, n:int, l: addr) stadef free_ngc_v = free_ngc_t0ype_int_addr_view absview freebyte_gc_int_addr_view (n:int, l:addr) stadef freebyte_gc_v = freebyte_gc_int_addr_view absview freebyte_ngc_int_addr_view (n:int, l:addr) stadef freebyte_ngc_v = freebyte_ngc_int_addr_view (* ****** ****** *) // // HX: // values of viewtype [junkptr] need to be freed by calling [free]; // note that the viewtype [junkptr] may be just defined as follows: // [a:t@ype; l:addr] (free_gc_v (a, 1, l), a @ l | ptr l) // absviewtype junkptr_viewtype // unnamed stadef junkptr = junkptr_viewtype // shorthand (* ****** ****** *) // // HX: This definition should not be changed! // viewtypedef arrayptrsize_viewt0ype_int_viewt0ype (a:vt0p, n:int) = [l:addr] (free_gc_v (a?, n, l), @[a][n] @ l | ptr l, size_t n) // end of [viewtypedef] stadef arrpsz = arrayptrsize_viewt0ype_int_viewt0ype viewtypedef Arrpsz (a:vt0p) = [n:int | n >= 0] arrpsz (a, n) (* ****** ****** *) // // HX: closure, closure pointer and closure reference // absviewt@ype clo_viewt0ype_viewt0ype (_fun: viewt@ype+) // unnamed stadef clo = clo_viewt0ype_viewt0ype absviewtype cloptr_viewt0ype_viewtype (_fun: viewt@ype+) // unnamed stadef cloptr = cloptr_viewt0ype_viewtype abstype cloref_t0ype_type (_fun: t@ype) // unnamed stadef cloref = cloref_t0ype_type (* ****** ****** *) viewtypedef // HX: for commenting only SHARED_viewt0ype_viewt0ype (a: vt0p) = a stadef SHARED = SHARED_viewt0ype_viewt0ype viewtypedef // HX: for commenting only NSHARED_viewt0ype_viewt0ype (a: vt0p) = a stadef NSHARED = NSHARED_viewt0ype_viewt0ype (* ****** ****** *) // // HX: for handling read-only data // (* viewtypedef READ_viewt0ype_int_viewt0ype (a: viewt@ype, stamp: int) = a stadef READ = READ_viewt0ype_int_viewt0ype *) viewtypedef READ_viewt0ype_viewt0ype (a: vt0p) = a stadef READ = READ_viewt0ype_viewt0ype (* ****** ****** *) // // HX: for print-format strings // abstype printf_c_types_type (types) // boxed type: string stadef printf_c = printf_c_types_type (* ****** ****** *) // // HX: for handling variadic functions // absviewt@ype va_list_viewt0ype = $extype"ats_va_list_viewtype" absviewt@ype va_list_types_viewt0ype (types) = va_list_viewt0ype stadef va_list = va_list_viewt0ype stadef va_list = va_list_types_viewt0ype (* ****** ****** *) datasort file_mode = | file_mode_r (* read *) | file_mode_w (* write *) | file_mode_rw (* read and write *) // end of [file_mode] // stadef r = file_mode_r () stadef w = file_mode_w () stadef rw = file_mode_rw () // // [ats_FILE_viewtype] is defined in [libc/CATS/stdio.cats] // absviewt@ype FILE_viewt0ype (file_mode) = $extype"ats_FILE_viewtype" stadef FILE = FILE_viewt0ype // // HX-2010-05-02: // this is easy to use but unsafe and should probably be DEPRECATED? // // [FILEref_type] is [ref (FILE m)] for some [m] // abstype FILEref_type // unnamed stadef FILEref = FILEref_type // shorthand // (* ****** ****** *) // // HX: some common datatypes // datatype box_t0ype_type (a:t@ype+) = box (a) of a stadef box = box_t0ype_type // dataviewtype box_viewt0ype_viewtype (a:viewt@ype+) = box_vt (a) of a stadef box_vt = box_viewt0ype_viewtype // // HX: [list0_t0ype_type] is co-variant // datatype list0_t0ype_type (a: t@ype+) = | list0_cons (a) of (a, list0_t0ype_type a) | list0_nil (a) of () // end of [list0_t0ype_type] stadef list0 = list0_t0ype_type // datatype // t@ype+: covariant list_t0ype_int_type (a:t@ype+, int) = | {n:int | n >= 0} list_cons (a, n+1) of (a, list_t0ype_int_type (a, n)) | list_nil (a, 0) // end of [datatype] stadef list = list_t0ype_int_type typedef List (a:t0p) = [n:int | n >= 0] list (a, n) typedef List0 (a:t0p) = [n:int | n >= 0] list (a, n) typedef List1 (a:t0p) = [n:int | n >= 1] list (a, n) typedef listLt (a:t0p, n:int) = [k:int | 0 <= k; k < n] list (a, k) typedef listLte (a:t0p, n:int) = [k:int | 0 <= k; k <= n] list (a, k) typedef listBtw (a:t0p, m:int, n:int) = [k:int | m <= k; k < n] list (a, k) typedef listBtwe (a:t0p, m:int, n:int) = [k:int | m <= k; k <= n] list (a, k) // // HX: [option0_t0ype_type] is co-variant // datatype option0_t0ype_type (a: t@ype+) = | option0_some (a) of (a) | option0_none (a) of () // end of [datatype] stadef option0 = option0_t0ype_type // datatype // t@ype+: covariant option_t0ype_bool_type (a:t@ype+, bool) = | None (a, false) | Some (a, true) of a // end of [datatype] stadef option = option_t0ype_bool_type typedef Option (a:t0p) = [b:bool] option (a, b) // (* ****** ****** *) // // HX: some common dataviewtypes // dataviewtype // viewt@ype+: covariant list_viewt0ype_int_viewtype (a:viewt@ype+, int) = | {n:int | n >= 0} list_vt_cons (a, n+1) of (a, list_viewt0ype_int_viewtype (a, n)) | list_vt_nil (a, 0) // end of [list_viewt0ype_int_viewtype] stadef list_vt = list_viewt0ype_int_viewtype viewtypedef List_vt (a:vt0p) = [n:int | n >= 0] list_vt (a, n) viewtypedef List0_vt (a:vt0p) = [n:int | n >= 0] list_vt (a, n) viewtypedef List1_vt (a:vt0p) = [n:int | n >= 1] list_vt (a, n) viewtypedef listLt_vt (a:vt0p, n:int) = [k:int | 0 <= k; k < n] list_vt (a, k) viewtypedef listLte_vt (a:vt0p, n:int) = [k:int | 0 <= k; k <= n] list_vt (a, k) viewtypedef listBtw_vt (a:vt0p, m:int, n:int) = [k:int | m <= k; k < n] list_vt (a, k) viewtypedef listBtwe_vt (a:vt0p, m:int, n:int) = [k:int | m <= k; k <= n] list_vt (a, k) // dataviewtype // viewt@ype+: covariant option_viewt0ype_bool_viewtype (a:viewt@ype+, bool) = | None_vt (a, false) | Some_vt (a, true) of a // end of [option_viewt0ype_bool_viewtype] stadef option_vt = option_viewt0ype_bool_viewtype viewtypedef Option_vt (a:vt0p) = [b:bool] option_vt (a, b) // (* ****** ****** *) // // HX: some useful props and views // dataprop unit_p = unit_p of () dataview unit_v = unit_v of () // dataprop option_prop_bool_prop (P:prop+, bool) = Some_p (P, true) of P | None_p (P, false) of () stadef option_p = option_prop_bool_prop // dataview option_view_bool_view (a:view+, bool) = Some_v (a, true) of a | None_v (a, false) // end of [option_view_bool_view] stadef option_v = option_view_bool_view viewdef optvar_v (a:vt0p, l:addr) = option_v (a @ l, l > null) // dataview disj_view_view_int_view (v0: view, v1: view, int) = | InsLeft_v (v0, v1, 0) of v0 | InsRight_v (v0, v1, 1) of v1 // end of [dataview or_view_view_int_view] stadef disj_v = disj_view_view_int_view // // HX: subview relation that only allows *reading* // absprop vsubr_p (v1:view+, v2: view-) // v2 - [v:iew] @(v1, v) stadef <= (v1:view, v2:view) = vsubr_p (v1, v2) // // HX: subview relation that allows *reading* and *writing* // absprop vsubw_p (v1:view, v2: view) // v2 - @(v1, v1 - v2) // (* ****** ****** *) // absviewt@ype crypt_viewt0ype_viewt0ype (a:viewt@ype) = a stadef crypt = crypt_viewt0ype_viewt0ype // (* ****** ****** *) // // HX: // [lazy(T)] : suspended computation of a value of type T // abstype lazy_t0ype_type (t@ype+) // boxed type // unnamed stadef lazy = lazy_t0ype_type // // HX: [lazy_vt(VT)] : // suspended computation of a linear value of viewtype VT // absviewtype lazy_viewt0ype_viewtype (viewt@ype+) // boxed linear type // unnamed stadef lazy_vt = lazy_viewt0ype_viewtype // (* ****** ****** *) // // HX: lazy streams // datatype stream_con (a:t@ype+) = | stream_nil (a) | stream_cons (a) of (a, stream a) where stream (a:t@ype) = lazy (stream_con a) // // HX: lazy linear streams // dataviewtype stream_vt_con (a:viewt@ype+) = | stream_vt_nil (a) | stream_vt_cons (a) of (a, stream_vt a) where stream_vt (a:vt0p) = lazy_vt (stream_vt_con a) // (* ****** ****** *) #if VERBOSE_PRELUDE #then #print "Loading [basic_sta.sats] finishes!\n" #endif // end of [VERBOSE_PRELUDE] (* end of [basics_sta.sats] *) ats-lang-anairiats-0.2.11/prelude/fixity.ats0000664000175000017500000000516212223166162017466 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) // some fixity declarations #include "prelude/params.hats" #if VERBOSE_FIXITY #then #print "Loading [fixity.ats] starts!\n" #endif // end of [VERBOSE_FIXITY] (* ****** ****** *) // prefix 00 ! (* static *) prefix 99 ! (* dynamic *) // postfix 80 .lab // dynamic // postfix 80 ->lab // dynamic // prefix 79 & // dynamic // infixl 70 app // postfix 69 ? prefix 61 ~ infixl 60 * / infixl ( * ) imul imul1 imul2 nmul umul infixl ( / ) idiv idiv1 idiv2 idiv3 ndiv udiv infix 60 mod infix (mod) nmod nmod1 nmod2 umod umod2 uimod infixl 50 + - infixl ( + ) iadd fadd padd uadd infixl ( - ) isub nsub fsub psub usub infixl 41 asl asr lsl lsr infix 40 < <= > >= << >> infixl ( < ) ilt flt plt ult infixl ( <= ) ilte flte plte ulte infixl ( > ) igt fgt pgt ugt infixl ( >= ) igte fgte pgte ugte infixr 40 :: @ <: infix 30 = := == <> != infix ( = ) ieq feq peq ueq infix ( <> ) ineq fneq pneq uneq infixr 20 -> infixl 20 && infixl ( && ) andalso land infixl 10 || infixl ( || ) orelse lor lxor (* infix 0 >> << *) (* ****** ****** *) #if VERBOSE_FIXITY #then #print "Loading [fixity.ats] finishes!\n" #endif // end of [VERBOSE_FIXITY] (* end of [fixity.ats] *) ats-lang-anairiats-0.2.11/prelude/ats_main_prelude.dats0000664000175000017500000000621312223166162021627 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi ( hwxi AT cs DOT bu DOT edu ) *) (* ****** ****** *) // [main_prelude] is called before [main] (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement main_prelude () = let (* primary *) val () = $dynload "prelude/DATS/basics.dats" // val () = $dynload "prelude/DATS/bool.dats" // val () = $dynload "prelude/DATS/char.dats" // val () = $dynload "prelude/DATS/float.dats" // val () = $dynload "prelude/DATS/integer.dats" val () = $dynload "prelude/DATS/sizetype.dats" // val () = $dynload "prelude/DATS/pointer.dats" // val () = $dynload "prelude/DATS/reference.dats" // val () = $dynload "prelude/DATS/string.dats" // val () = $dynload "prelude/DATS/lazy.dats" val () = $dynload "prelude/DATS/lazy_vt.dats" // val () = $dynload "prelude/DATS/printf.dats" val () = $dynload "prelude/DATS/filebas.dats" // (* secondary *) (* // // HX: only proof functions // val () = $dynload "prelude/DATS/arith.dats" *) // val () = $dynload "prelude/DATS/list.dats" val () = $dynload "prelude/DATS/list_vt.dats" val () = $dynload "prelude/DATS/list0.dats" // val () = $dynload "prelude/DATS/option.dats" val () = $dynload "prelude/DATS/option_vt.dats" val () = $dynload "prelude/DATS/option0.dats" // val () = $dynload "prelude/DATS/array.dats" val () = $dynload "prelude/DATS/array0.dats" (* // // HX: only proof functions // val () = $dynload "prelude/DATS/array_prf.dats" *) // val () = $dynload "prelude/DATS/matrix.dats" val () = $dynload "prelude/DATS/matrix0.dats" // val () = $dynload "prelude/DATS/ptrarr.dats" (* val () = begin print ("The prelude library is loaded."); print_newline () end // end of [val] *) in // empty end // end of [main_prelude] (* ****** ****** *) (* end of [ats_main_prelude.dats] *) ats-lang-anairiats-0.2.11/prelude/HATS/0000700000175000017500000000000012223166162016160 5ustar hwxihwxiats-lang-anairiats-0.2.11/prelude/HATS/number.hats0000664000175000017500000002217712223166162020356 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** An interface for various common funtion on numbers ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // HX: this is originally done for the ATS/CBLAS package (* ****** ****** *) staload MATH = "libc/SATS/math.sats" (* ****** ****** *) staload CMPLX = "libc/SATS/complex.sats" typedef ccmplx = $CMPLX.ccmplx typedef zcmplx = $CMPLX.zcmplx (* ****** ****** *) staload "prelude/SATS/number.sats" (* ****** ****** *) implement print_typ () = print "float" implement print_typ () = print "double" implement print_typ () = print "ccmplx" implement print_typ () = print "zcmplx" (* ****** ****** *) implement print_elt (x) = print_float x implement print_elt (x) = print_double x implement print_elt (x) = $CMPLX.print_ccmplx x implement print_elt (x) = $CMPLX.print_zcmplx x (* ****** ****** *) implement of_int (x) = float_of_int (x) implement of_int (x) = double_of_int (x) implement of_int (x) = $CMPLX.ccmplx_of_int (x) implement of_int (x) = $CMPLX.zcmplx_of_int (x) (* ****** ****** *) implement of_size (x) = float_of_size (x) implement of_size (x) = double_of_size (x) (* ****** ****** *) implement of_double (x) = float_of_double (x) implement of_double (x) = x implement of_double (x) = let val x = float_of_double x in $CMPLX.ccmplx_of_float (x) end // end of [of_double] implement of_double (x) = $CMPLX.zcmplx_of_double (x) (* ****** ****** *) implement to_int (x) = int_of_float (x) implement to_int (x) = int_of_double (x) implement to_float (x) = x implement to_float (x) = float_of_double (x) implement to_double (x) = double_of_float (x) implement to_double (x) = x (* ****** ****** *) implement abs (x) = abs_float (x) implement abs (x) = abs_double (x) implement abs (x) = $CMPLX.abs_ccmplx (x) implement abs (x) = $CMPLX.abs_zcmplx (x) (* ****** ****** *) implement neg (x) = neg_float (x) implement neg (x) = neg_double (x) implement neg (x) = $CMPLX.neg_ccmplx (x) implement neg (x) = $CMPLX.neg_zcmplx (x) (* ****** ****** *) implement add (x1, x2) = add_float_float (x1, x2) implement add (x1, x2) = add_double_double (x1, x2) implement add (x1, x2) = $CMPLX.add_ccmplx_ccmplx (x1, x2) implement add (x1, x2) = $CMPLX.add_zcmplx_zcmplx (x1, x2) implement sub (x1, x2) = sub_float_float (x1, x2) implement sub (x1, x2) = sub_double_double (x1, x2) implement sub (x1, x2) = $CMPLX.sub_ccmplx_ccmplx (x1, x2) implement sub (x1, x2) = $CMPLX.sub_zcmplx_zcmplx (x1, x2) implement mul (x1, x2) = mul_float_float (x1, x2) implement mul (x1, x2) = mul_double_double (x1, x2) implement mul (x1, x2) = $CMPLX.mul_ccmplx_ccmplx (x1, x2) implement mul (x1, x2) = $CMPLX.mul_zcmplx_zcmplx (x1, x2) implement div (x1, x2) = div_float_float (x1, x2) implement div (x1, x2) = div_double_double (x1, x2) implement div (x1, x2) = $CMPLX.div_ccmplx_ccmplx (x1, x2) implement div (x1, x2) = $CMPLX.div_zcmplx_zcmplx (x1, x2) (* ****** ****** *) implement pow (x, y) = $MATH.powf (x, y) implement pow (x, y) = $MATH.pow (x, y) implement pow (x, y) = $CMPLX.cpowf (x, y) implement pow (x, y) = $CMPLX.cpow (x, y) (* ****** ****** *) implement ceil (x) = $MATH.ceilf (x) implement ceil (x) = $MATH.ceil (x) implement floor (x) = $MATH.floorf (x) implement floor (x) = $MATH.floor (x) (* ****** ****** *) implement sqrt (a) = $MATH.sqrtf (a) implement sqrt (a) = $MATH.sqrt (a) implement sqrt (a) = $CMPLX.sqrt_ccmplx (a) implement sqrt (a) = $CMPLX.sqrt_zcmplx (a) (* ****** ****** *) implement scal (x1, x2) = mul_float_float (x1, x2) implement scal (x1, x2) = let val x2_r = $CMPLX.ccmplx_real (x2) and x2_i = $CMPLX.ccmplx_imag (x2) in $CMPLX.ccmplx_make_cart (mul_float_float (x1, x2_r), mul_float_float (x1, x2_i)) end // end of ... implement scal (x1, x2) = $CMPLX.mul_ccmplx_ccmplx (x1, x2) implement scal (x1, x2) = mul_double_double (x1, x2) implement scal (x1, x2) = let val x2_r = $CMPLX.zcmplx_real (x2) and x2_i = $CMPLX.zcmplx_imag (x2) in $CMPLX.zcmplx_make_cart (mul_double_double (x1, x2_r), mul_double_double (x1, x2_i)) end // end of ... implement scal (x1, x2) = $CMPLX.mul_zcmplx_zcmplx (x1, x2) (* ****** ****** *) implement lt (x1, x2) = x1 < x2 implement lt (x1, x2) = x1 < x2 implement lte (x1, x2) = x1 <= x2 implement lte (x1, x2) = x1 <= x2 implement gt (x1, x2) = x1 > x2 implement gt (x1, x2) = x1 > x2 implement gte (x1, x2) = x1 >= x2 implement gte (x1, x2) = x1 >= x2 (* ****** ****** *) implement signof (x) = compare_float_float (x, (float_of)0.0) implement signof (x) = compare_double_double (x, 0.0) implement compare (x1, x2) = compare_float_float (x1, x2) implement compare (x1, x2) = compare_double_double (x1, x2) (* ****** ****** *) implement{a} min (x, y) = if lte (x,y) then x else y implement{a} max (x, y) = if gte (x,y) then x else y (* ****** ****** *) implement eq (x1, x2) = eq_float_float (x1, x2) implement eq (x1, x2) = eq_double_double (x1, x2) implement eq (x1, x2) = $CMPLX.eq_ccmplx_ccmplx (x1, x2) implement eq (x1, x2) = $CMPLX.eq_zcmplx_zcmplx (x1, x2) implement neq (x1, x2) = neq_float_float (x1, x2) implement neq (x1, x2) = neq_double_double (x1, x2) implement neq (x1, x2) = $CMPLX.neq_ccmplx_ccmplx (x1, x2) implement neq (x1, x2) = $CMPLX.neq_zcmplx_zcmplx (x1, x2) (* ****** ****** *) implement cmplx_make_cart (x1, x2) = $CMPLX.ccmplx_make_cart (x1, x2) implement cmplx_make_cart (x1, x2) = $CMPLX.zcmplx_make_cart (x1, x2) (* ****** ****** *) implement creal (x) = $CMPLX.crealf (x) implement creal (x) = $CMPLX.creal (x) implement cimag (x) = $CMPLX.cimagf (x) implement cimag (x) = $CMPLX.cimag (x) (* ****** ****** *) implement conj (x) = $CMPLX.conj_ccmplx (x) implement conj (x) = $CMPLX.conj_zcmplx (x) (* ****** ****** *) implement sin (x) = $MATH.sinf (x) implement sin (x) = $MATH.sin (x) implement sin (x) = $CMPLX.sin_ccmplx (x) implement sin (x) = $CMPLX.sin_zcmplx (x) implement cos (x) = $MATH.cosf (x) implement cos (x) = $MATH.cos (x) implement cos (x) = $CMPLX.cos_ccmplx (x) implement cos (x) = $CMPLX.cos_zcmplx (x) implement tan (x) = $MATH.tanf (x) implement tan (x) = $MATH.tan (x) implement tan (x) = $CMPLX.tan_ccmplx (x) implement tan (x) = $CMPLX.tan_zcmplx (x) (* ****** ****** *) implement asin (x) = $MATH.asinf (x) implement asin (x) = $MATH.asin (x) implement asin (x) = $CMPLX.casinf (x) implement asin (x) = $CMPLX.casin (x) implement acos (x) = $MATH.acosf (x) implement acos (x) = $MATH.acos (x) implement acos (x) = $CMPLX.cacosf (x) implement acos (x) = $CMPLX.cacos (x) implement atan (x) = $MATH.atanf (x) implement atan (x) = $MATH.atan (x) implement atan (x) = $CMPLX.catanf (x) implement atan (x) = $CMPLX.catan (x) implement atan2 (x, y) = $MATH.atan2f (x, y) implement atan2 (x, y) = $MATH.atan2 (x, y) (* ****** ****** *) (* end of [number.hats] *) ats-lang-anairiats-0.2.11/prelude/HATS/lmacrodef.hats0000664000175000017500000000526012223166162021014 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author of the file: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) (* some commonly used _local_ macro definitions *) (* ****** ****** *) // symintr is_nil symintr is_cons // symintr tup_head symintr tup_tail // (* ****** ****** *) macdef min (x, y) = if ,(x) <= ,(y) then ,(x) else ,(y) macdef max (x, y) = if ,(x) <= ,(y) then ,(y) else ,(x) (* ****** ****** *) macdef println (x) = (print ,(x); print_newline ()) macdef prerrln (x) = (prerr ,(x); prerr_newline ()) (* ****** ****** *) local macrodef rec printstar_rec args = if is_nil args then `() else `( print ,(tup_head args) ; ,(printstar_rec (tup_tail args)) ) // end of [if] // end of [printstar_rec] macrodef rec prerrstar_rec args = if is_nil args then `() else `( prerr ,(tup_head args) ; ,(prerrstar_rec (tup_tail args)) ) // end of [if] // end of [prerrstar_rec] in // in of [local] // // HX: for instance, we can write something like: // printstarln @("x+y = ", x+y, " and x*y = ", x*y) // macdef printstar args = ,(printstar_rec args) macdef printstarln args = begin ,(printstar_rec args); print_newline () end macdef prerrstar args = ,(prerrstar_rec args) macdef prerrstarln args = begin ,(prerrstar_rec args); prerr_newline () end end // end of [local] (* ****** ****** *) (* end of [lmacrodef.hats] *) ats-lang-anairiats-0.2.11/prelude/HATS/syndef.hats0000664000175000017500000000322712223166162020351 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) implement atsyndef__of_int (x) = x implement atsyndef__of_int (x) = uint_of_int (x) implement atsyndef__of_int (x) = size_of_uint (uint_of_int(x)) implement atsyndef__of_int (x) = ssize_of_int (x) (* ****** ****** *) (* end of [syndef.hats] *) ats-lang-anairiats-0.2.11/ccomp/0000700000175000017500000000000012223166160015060 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/lib/0000700000175000017500000000000012223166160015626 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/lib/output/0000700000175000017500000000000012223166160017166 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/lib/output/.keeper0000664000175000017500000000006112223166160020453 0ustar hwxihwxi// for keeping the directory from being removed. ats-lang-anairiats-0.2.11/ccomp/lib64/0000700000175000017500000000000012223166160016000 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/lib64/output/0000700000175000017500000000000012223166160017340 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/lib64/output/.keeper0000664000175000017500000000000112223166160020617 0ustar hwxihwxi ats-lang-anairiats-0.2.11/ccomp/runtime/0000700000175000017500000000000012223166160016543 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/runtime/ats_basics.h0000664000175000017500000001463312223166160021052 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_BASICS_H #define ATS_BASICS_H /* ****** ****** */ /* #define ATSstringize(id) # id */ /* ****** ****** */ // // HX-2011-02-17: // if the following definition is not supporten, please change it to: // #define ATSunused // #define ATSunused __attribute__ ((unused)) /* ****** ****** */ // #define ATSextern(ty, name) extern ty name #define ATSextern_fun(ty, name) extern ty name #define ATSextern_prf(name) // proof constant #define ATSextern_val(ty, name) extern ty name // #define ATSstatic(ty, name) static ty name #define ATSstatic_fun(ty, name) static ty name #define ATSstatic_val(ty, name) static ty name #define ATSstatic_void(name) // void name // retired // #define ATSglobal(ty, name) ty name // #define ATSlocal(ty, name) ty ATSunused name #define ATSlocal_void(name) // void name // retired // #define ATScastfn(castfn, name) name /* ****** ****** */ // // HX-2011-02-17: // if the following definition is problematic, please change it to: // #define ATSstrcst(x) x // #define ATSstrcst(x) ((ats_ptr_type)x) // HX-2011-02-17 /* ****** ****** */ #define ATSglobaldec() #define ATSstaticdec() static #define ATSextfun() extern #define ATSinline() static inline /* ****** ****** */ // // HX-2010-05-24: // if TLS is not supported, then please compile with the flag -D_ATSTLS_NONE // #define ATSthreadlocalstorage() __thread #ifdef _ATSTLS_NONE #undef ATSthreadlocalstorage #define ATSthreadlocalstorage() #endif // end of [_ATSTLS_NONE] /* ****** ****** */ #define ATSdeadcode() \ do { \ fprintf ( \ stderr, \ "abort(ATS): file = %s and line = %d: the deadcode is executed!\n", \ __FILE__, __LINE__ \ ) ; \ abort (); \ } while (0); /* ****** ****** */ // // HX: boolean values // #define ats_true_bool 1 #define ats_false_bool 0 /* ****** ****** */ // // HX: needed for handling [PATCKstring] // #define __strcmpats(s1, s2) strcmp((char*)(s1), (char*)(s2)) /* ****** ****** */ // // HX: closure function selection // #define ats_closure_fun(f) ((ats_clo_ptr_type)f)->closure_fun /* ****** ****** */ // // HX: handling cast functions // #define ats_castfn_mac(hit, vp) ((hit)vp) /* ****** ****** */ #define ats_field_getval(tyrec, ref, lab) (((tyrec*)(ref))->lab) #define ats_field_getptr(tyrec, ref, lab) (&((tyrec*)(ref))->lab) /* ****** ****** */ #define ats_cast_mac(ty, x) ((ty)(x)) #define ats_castptr_mac(ty, x) ((ty*)(x)) #define ats_selind_mac(x, ind) ((x)ind) #define ats_selbox_mac(x, lab) ((x)->lab) #define ats_select_mac(x, lab) ((x).lab) #define ats_selptr_mac(x, lab) ((x)->lab) #define ats_selsin_mac(x, lab) (x) #define ats_selptrset_mac(ty, x, lab, v) (((ty*)x)->lab = (v)) #define ats_caselind_mac(ty, x, ind) (((ty*)(&(x)))ind) #define ats_caselptrind_mac(ty, x, ind) (((ty*)(x))ind) #define ats_caselptrlab_mac(ty, x, lab) (((ty*)(x))->lab) #define ats_varget_mac(ty, x) (x) #define ats_ptrget_mac(ty, x) (*(ty*)(x)) /* ****** ****** */ // // HX: handling for/while loops // #define ats_loop_beg_mac(init) while(ats_true_bool) { init: #define ats_loop_end_mac(init, fini) goto init ; fini: break ; } // // HX: handling while loop: deprecated!!! // #define ats_while_beg_mac(clab) while(ats_true_bool) { clab: #define ats_while_end_mac(blab, clab) goto clab ; blab: break ; } /* ****** ****** */ // // HX: for initializing a reference // #define ats_instr_move_ref_mac(tmp, hit, val) \ do { tmp = ATS_MALLOC (sizeof(hit)) ; *(hit*)tmp = val ; } while (0) /* ****** ****** */ // // HX: for proof checking at run-time // #define \ ats_proofcheck_beg_mac(dyncst) \ static int dyncst ## _flag = 0 ; \ do { \ if (dyncst ## _flag > 0) return ; \ if (dyncst ## _flag < 0) { \ fprintf (stderr, \ "exit(ATS): proof checking failure: [%s] is cyclically defined!\n", \ # dyncst \ ) ; \ exit (1) ; \ } \ dyncst ## _flag = -1 ; \ } while (0) ; /* end of [ats_proofcheck_beg_mac] */ #define \ ats_proofcheck_end_mac(dyncst) { dyncst ## _flag = 1 ; } /* ****** ****** */ /* ** HX: ** [mainats_prelude] is called in the function [main] ** it is implemented in [$ATSHOME/prelude/ats_main_prelude.dats] ** where it is given the name [main_prelude]. */ extern void mainats_prelude () ; /* ****** ****** */ /* ** HX: ** functions for handling match failures ** the implementation is given in [ats_prelude.c] */ extern void ats_caseof_failure_handle (const char *loc) ; extern void ats_funarg_match_failure_handle (const char *loc) ; /* ****** ****** */ #endif /* ATS_BASICS_H */ /* end of [ats_basics.h] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_prelude_ngc.c0000664000175000017500000001142612223166160022065 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May 2009 // /* ****** ****** */ // // HX-2010-03-17: should it be named ATS_PRELUDE_NGC_C? // #ifndef ATSRUNTIME_NGC_C #define ATSRUNTIME_NGC_C /* ****** ****** */ // declared in [stdlib.h] extern void *malloc (size_t bsz) ; extern void *calloc (size_t n, size_t bsz) ; extern void free (void *p) ; extern void *realloc (void* p, size_t bsz) ; /* ****** ****** */ ats_void_type ats_gc_init () { return ; } // end of [ats_gc_init] ats_void_type ats_gc_markroot ( const ats_ptr_type p, ats_size_type bsz ) { return ; } // end of [ats_gc_markroot] ats_int_type ats_gc_chunk_count_limit_get () { return 0 ; } // end of [ats_gc_chunk_count_limit_get] ats_void_type ats_gc_chunk_count_limit_set (ats_int_type nchunk) { return ; } // end of [ats_gc_chunk_count_limit_set] ats_int_type ats_gc_chunk_count_limit_max_get () { return 0 ; } // end of [ats_gc_chunk_count_limit_max_get] ats_void_type ats_gc_chunk_count_limit_max_set (ats_int_type nchunk) { return ; } // end of [ats_gc_chunk_count_limit_max_set] /* ****** ****** */ ats_ptr_type ats_malloc_gc ( ats_size_type n ) { ats_ptr_type *p ; /* fprintf (stderr, "ats_malloc_gc: n = %i\n", n) ; */ p = malloc(n) ; /* fprintf (stderr, "ats_malloc_gc: p = %p(%li)\n", p, p) ; */ if (!p) ats_exit_errmsg(1, "exit(ATS): [ats_malloc_gc] failed.\n") ; return p ; } // end of [ats_malloc_gc] ats_ptr_type ats_calloc_gc ( ats_size_type n, ats_size_type bsz ) { ats_ptr_type *p ; /* fprintf (stderr, "ats_calloc_gc: n = %i and bsz = %i\n", n, bsz) ; */ p = calloc(n, bsz) ; /* fprintf (stderr, "ats_calloc_gc: p = %p(%li)\n", p, p) ; */ if (!p) ats_exit_errmsg(1, "exit(ATS): [ats_calloc_gc] failed.\n") ; return p ; } // end of [ats_calloc_gc] ats_void_type ats_free_gc ( const ats_ptr_type p ) { /* fprintf (stderr, "ats_free_gc: p = %p(%li)\n", p, p) ; */ free(p) ; return ; } // end of [ats_free_gc] ats_ptr_type ats_realloc_gc ( const ats_ptr_type p, ats_size_type bsz ) { ats_ptr_type p_new ; /* fprintf (stderr, "ats_realloc_gc: p = %p and bsz = %i\n", p, bsz) ; */ p_new = realloc(p, bsz) ; /* fprintf (stderr, "ats_realloc_gc: p_new = %p(%li)\n", p_new, p_new) ; */ if (!p_new) ats_exit_errmsg(1, "exit(ATS): [ats_realloc_gc] failed.\n") ; return p_new ; } // end of [ats_realloc_gc] /* ****** ****** */ ats_ptr_type ats_malloc_ngc ( ats_size_type n ) { ats_ptr_type *p ; /* fprintf (stderr, "ats_malloc_ngc: _ATS_NGC: n = %i\n", n) ; */ p = malloc(n) ; /* fprintf (stderr, "ats_malloc_ngc: _ATS_NGC: p = %p(%li)\n", p, p) ; */ return p ; } // end of [ats_malloc_ngc] ats_ptr_type ats_calloc_ngc ( ats_size_type n, ats_size_type bsz ) { ats_ptr_type *p ; p = calloc(n, bsz) ; return p ; } // end of [ats_calloc_ngc] ats_void_type ats_free_ngc ( const ats_ptr_type p ) { /* fprintf (stderr, "ats_free_ngc: _ATS_NGC: p = %p\n", p) ; */ free(p) ; return ; } // end of [ats_free_ngc] ats_ptr_type ats_realloc_ngc ( const ats_ptr_type p, ats_size_type bsz ) { ats_ptr_type *p_new ; /* fprintf (stderr, "ats_realloc_ngc: _ATS_NGC: p = %p\n", p) ; fprintf (stderr, "ats_realloc_ngc: _ATS_NGC: bsz = %i\n", bsz) ; */ p_new = realloc(p, bsz) ; /* fprintf (stderr, "ats_realloc_ngc: _ATS_NGC: p_new = %p\n", p_new) ; */ return p_new ; } // end of [ats_realloc_ngc] /* ****** ****** */ #endif /* ATSRUNTIME_NGC_C */ /* end of [ats_prelude_ngc.c] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_types.h0000664000175000017500000001045012223166160020743 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_TYPES_H #define ATS_TYPES_H /* ****** ****** */ #include #include // for both [size_t] and [ptrdiff_t] #include // for [ssize_t] /* ****** ****** */ struct ats_struct_type ; /* of indefinite size */ /* ****** ****** */ typedef struct ats_struct_type ats_abs_type ; typedef void *ats_ptr_type ; typedef void *ats_ref_type ; /* typedef struct ats_struct_type *ats_ptr_type ; typedef struct ats_struct_type *ats_ref_type ; */ #ifdef _ATS_GEIZELLA typedef void ats_var_type ; // for ATS/Geizella #else typedef struct ats_struct_type ats_var_type ; #endif // end of [_ATS_GEIZELLA] typedef void ats_varet_type ; typedef void ats_void_type ; typedef struct{} ats_empty_type ; /* ****** ****** */ typedef int ats_bool_type ; typedef unsigned char ats_byte_type ; typedef char ats_char_type ; typedef signed char ats_schar_type ; typedef unsigned char ats_uchar_type ; typedef double ats_double_type ; typedef long double ats_ldouble_type ; typedef float ats_float_type ; /* ****** ****** */ typedef int ats_int_type ; typedef unsigned int ats_uint_type ; typedef long int ats_lint_type ; typedef unsigned long int ats_ulint_type ; typedef long long int ats_llint_type ; typedef unsigned long long int ats_ullint_type ; typedef short int ats_sint_type ; typedef unsigned short int ats_usint_type ; typedef size_t ats_size_type ; typedef ssize_t ats_ssize_type ; typedef ptrdiff_t ats_ptrdiff_type ; /* ****** ****** */ typedef int8_t ats_int8_type ; typedef uint8_t ats_uint8_type ; typedef int16_t ats_int16_type ; typedef uint16_t ats_uint16_type ; typedef int32_t ats_int32_type ; typedef uint32_t ats_uint32_type ; typedef int64_t ats_int64_type ; typedef uint64_t ats_uint64_type ; /* ****** ****** */ // // HX-2010-12-06: // the erasure name of [ptr] is [ats_ptrself_type] // typedef void *ats_ptrself_type ; /* ****** ****** */ /* typedef ats_ptr_type ats_string_type ; */ /* ****** ****** */ /* // // HX: this is intended: no definition for [ats_atarray_type]. // */ typedef struct { ats_ptr_type data ; ats_int_type size ; } ats_a1rray_type ; typedef ats_a1rray_type *ats_a1rray_ptr_type ; typedef ats_a1rray_ptr_type ats_array_type ; typedef struct { ats_ptr_type data ; ats_int_type size_row ; ats_int_type size_col ; } ats_a2rray_type ; typedef ats_a2rray_type *ats_a2rray_ptr_type ; typedef ats_a2rray_ptr_type ats_matrix_type ; /* ****** ****** */ typedef struct { int tag ; } ats_sum_type ; typedef ats_sum_type *ats_sum_ptr_type ; /* ****** ****** */ typedef struct { int tag ; char *name ; } ats_exn_type ; typedef ats_exn_type *ats_exn_ptr_type ; /* ****** ****** */ typedef void *ats_fun_ptr_type ; /* ****** ****** */ typedef struct { void *closure_fun ; } ats_clo_type ; typedef ats_clo_type *ats_clo_ptr_type ; typedef ats_clo_type *ats_clo_ref_type ; /* ****** ****** */ #endif /* ATS_TYPES_H */ /* end of [ats_types.h] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_memory.h0000664000175000017500000000544312223166160021115 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_MEMORY_H #define ATS_MEMORY_H /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ // // HX: the function [alloca] is declared in extern void *alloca (size_t nsz) ; // [alloca.h] or [stdlib.h] #define ATS_ALLOCA(sz) alloca(sz) #define ATS_ALLOCA2(n, sz) alloca((n)*(sz)) /* ****** ****** */ #define ATS_GC_INIT ats_gc_init #define ATS_GC_MARKROOT ats_gc_markroot /* ****** ****** */ #define ATS_FREE ats_free_gc #define ATS_MALLOC ats_malloc_gc #define ATS_MALLOC2(n, sz) ATS_MALLOC((n)*(sz)) #define ATS_CALLOC ats_calloc_gc #define ATS_REALLOC ats_realloc_gc /* ****** ****** */ extern ats_void_type ats_gc_init () ; extern ats_void_type ats_gc_markroot (ats_ptr_type p, ats_size_type bsz) ; /* ****** ****** */ extern ats_ptr_type ats_malloc_ngc (ats_size_type n) ; extern ats_ptr_type ats_calloc_ngc (ats_size_type nmemb, ats_size_type bsz) ; extern ats_void_type ats_free_ngc (const ats_ptr_type p) ; extern ats_ptr_type ats_realloc_ngc (const ats_ptr_type p, ats_size_type n) ; /* ****** ****** */ extern ats_ptr_type ats_malloc_gc (ats_size_type bsz) ; extern ats_ptr_type ats_calloc_gc (ats_size_type nmemb, ats_size_type bsz) ; extern ats_void_type ats_free_gc (const ats_ptr_type p) ; extern ats_ptr_type ats_realloc_gc (const ats_ptr_type p, ats_size_type bsz) ; /* ****** ****** */ #endif /* ATS_MEMORY_H */ /* end of [ats_memory.h] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_prelude_gcats.c0000664000175000017500000001341512223166160022417 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 /* ****** ****** */ #ifndef ATSRUNTIME_GCATS_C #define ATSRUNTIME_GCATS_C /* ****** ****** */ extern ats_int_type gc_chunk_count_limit_get () ; extern ats_void_type gc_chunk_count_limit_set (ats_int_type n) ; extern ats_int_type gc_chunk_count_limit_max_get () ; extern ats_void_type gc_chunk_count_limit_max_set (ats_int_type n) ; /* ****** ****** */ extern ats_void_type gc_markroot_bsz (ats_ptr_type ptr, ats_int_type bsz) ; /* ****** ****** */ extern ats_ptr_type gc_aut_malloc_bsz (ats_int_type bsz) ; extern ats_ptr_type gc_aut_calloc_bsz (ats_int_type n, ats_int_type bsz) ; extern ats_void_type gc_aut_free (ats_ptr_type ptr) ; extern ats_ptr_type gc_aut_realloc_bsz (ats_ptr_type ptr, ats_int_type bsz) ; /* ****** ****** */ extern ats_ptr_type gc_man_malloc_bsz (ats_int_type bsz) ; extern ats_ptr_type gc_man_calloc_bsz (ats_int_type n, ats_int_type bsz) ; extern ats_void_type gc_man_free (ats_ptr_type ptr) ; extern ats_ptr_type gc_man_realloc_bsz (ats_ptr_type ptr, ats_int_type bsz) ; /* ****** ****** */ extern void gc_init () ; ats_void_type ats_gc_init () { gc_init () ; return ; } // end of [ats_gc_init] /* ****** ****** */ ats_void_type ats_gc_markroot (const ats_ptr_type p, ats_size_type bsz) { /* fprintf (stderr, "ats_gc_markroot: p = %p and bsz = %i\n", p, bsz) ; */ gc_markroot_bsz (p, bsz) ; return ; } // end of [ats_gc_markroot] ats_int_type ats_gc_chunk_count_limit_get () { return gc_chunk_count_limit_get () ; } // end of [ats_gc_chunk_count_limit_get] ats_void_type ats_gc_chunk_count_limit_set (ats_int_type nchunk) { gc_chunk_count_limit_set (nchunk) ; return ; } // end of [ats_gc_chunk_count_limit_set] ats_int_type ats_gc_chunk_count_limit_max_get () { return gc_chunk_count_limit_max_get () ; } // end of [ats_gc_chunk_count_limit_max_get] ats_void_type ats_gc_chunk_count_limit_max_set (ats_int_type nchunk) { gc_chunk_count_limit_max_set (nchunk) ; return ; } // end of [ats_gc_chunk_count_limit_max_set] /* ****** ****** */ ats_ptr_type ats_malloc_gc (ats_size_type n) { ats_ptr_type *p ; /* fprintf (stderr, "ats_malloc_gc: n = %i\n", n) ; */ p = gc_aut_malloc_bsz(n) ; /* fprintf (stderr, "ats_malloc_gc: p = %p(%li)\n", p, p) ; */ if (!p) ats_exit_errmsg(1, "exit(ATS): [ats_malloc_gc] failed.\n") ; return p ; } // end of [ats_malloc_gc] ats_ptr_type ats_calloc_gc (ats_size_type n, ats_size_type bsz) { ats_ptr_type *p ; /* fprintf (stderr, "ats_calloc_gc: n = %i and bsz = %i\n", n, bsz) ; */ p = gc_aut_calloc_bsz(n, bsz) ; /* fprintf (stderr, "ats_calloc_gc: p = %p(%li)\n", p, p) ; */ if (!p) ats_exit_errmsg(1, "exit(ATS): [ats_calloc_gc] failed.\n") ; return p ; } // end of [ats_calloc_gc] ats_void_type ats_free_gc (const ats_ptr_type p) { /* fprintf (stderr, "ats_free_gc: p = %p(%li)\n", p, p) ; */ gc_aut_free(p) ; return ; } // end of [ats_free_gc] ats_ptr_type ats_realloc_gc (const ats_ptr_type p, ats_size_type bsz) { ats_ptr_type p_new ; /* fprintf (stderr, "ats_realloc_gc: p = %p and bsz = %i\n", p, bsz) ; */ p_new = gc_aut_realloc_bsz(p, bsz) ; /* fprintf (stderr, "ats_realloc_gc: p_new = %p(%li)\n", p_new, p_new) ; */ if (!p_new) ats_exit_errmsg(1, "exit(ATS): [ats_realloc_gc] failed.\n") ; return p_new ; } // end of [ats_realloc_gc] /* ****** ****** */ ats_ptr_type ats_malloc_ngc (ats_size_type n) { ats_ptr_type *p ; /* fprintf (stderr, "ats_malloc_ngc: _ATS_GCATS: n = %i\n", n) ; */ p = gc_man_malloc_bsz(n) ; /* fprintf (stderr, "ats_malloc_ngc: _ATS_GCATS: p = %p(%li)\n", p, p) ; */ return p ; } // end of [ats_malloc_ngc] ats_ptr_type ats_calloc_ngc (ats_size_type n, ats_size_type bsz) { ats_ptr_type *p ; p = gc_man_calloc_bsz(n, bsz) ; return p ; } // end of [ats_calloc_ngc] ats_void_type ats_free_ngc (const ats_ptr_type p) { /* fprintf (stderr, "ats_free_ngc: _ATS_GCATS: p = %p\n", p) ; */ gc_man_free(p) ; return ; } // end of [ats_free_ngc] ats_ptr_type ats_realloc_ngc (const ats_ptr_type p, ats_size_type bsz) { ats_ptr_type *p_new ; /* fprintf (stderr, "ats_realloc_ngc: _ATS_GCATS: p = %p\n", p) ; fprintf (stderr, "ats_realloc_ngc: _ATS_GCATS: bsz = %i\n", bsz) ; */ p_new = gc_man_realloc_bsz(p, bsz) ; /* fprintf (stderr, "ats_realloc_ngc: _ATS_GCATS: p_new = %p\n", p_new) ; */ return p_new ; } // end of [ats_realloc_ngc] /* ****** ****** */ #endif /* ATSRUNTIME_GCATS_C */ /* end of [ats_prelude_gcats.c] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_prelude_gcbdw.c0000664000175000017500000000732512223166160022407 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Power of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Likai Liu (liulk AT cs DOT bu DOT edu) */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATSRUNTIME_GCBDW_C #define ATSRUNTIME_GCBDW_C /* ****** ****** */ #ifdef HAVE_GCBDW // from config.h #include // interface file for [Boehm-Demers-Weiser GC] #else #error "Boehm-Demers-Weiser GC version 7.1 or later must be installed first." #endif // end of [HAVE_GCBDW] /* ****** ****** */ ats_void_type ats_gc_init () { GC_INIT() ; return ; } // end of [ats_gc_init] ats_void_type ats_gc_markroot ( const ats_ptr_type p, ats_size_type bsz ) { return ; } // end of [ats_gc_markroot] ats_int_type ats_gc_chunk_count_limit_get () { return 0 ; } // end of [ats_gc_chunk_count_limit_get] ats_void_type ats_gc_chunk_count_limit_set (ats_int_type nchunk) { return ; } // end of [ats_gc_chunk_count_limit_set] ats_int_type ats_gc_chunk_count_limit_max_get () { return 0 ; } // end of [ats_gc_chunk_count_limit_max_get] ats_void_type ats_gc_chunk_count_limit_max_set (ats_int_type nchunk) { return ; } // end of [ats_gc_chunk_count_limit_max_set] /* ****** ****** */ ats_ptr_type ats_malloc_gc ( ats_size_type nbytes ) { return GC_MALLOC(nbytes) ; // allocated memory is cleared } // end of [ats_malloc_gc] ats_ptr_type ats_calloc_gc ( ats_size_type nitm , ats_size_type bsz ) { return GC_MALLOC(nitm * bsz) ; // allocated memory is cleared } // end of [ats_calloc_gc] ats_void_type ats_free_gc (ats_ptr_type p) { GC_FREE(p) ; return ; } // end of [ats_free_gc] ats_ptr_type ats_realloc_gc ( ats_ptr_type p_old , ats_size_type nbytes_new ) { return GC_REALLOC(p_old, nbytes_new) ; } // end of [ats_realloc_gc] /* ****** ****** */ ats_ptr_type ats_malloc_ngc ( ats_size_type nbytes ) { return GC_MALLOC_UNCOLLECTABLE(nbytes) ; // allocated memory is cleared } // end of [ats_malloc_ngc] ats_ptr_type ats_calloc_ngc ( ats_size_type nitm , ats_size_type bsz ) { return GC_MALLOC_UNCOLLECTABLE(nitm * bsz) ; // allocated memory is cleared } // end of [ats_calloc_ngc] ats_void_type ats_free_ngc (ats_ptr_type p) { GC_FREE (p) ; return ; } // end of [ats_free_ngc] ats_ptr_type ats_realloc_ngc ( ats_ptr_type p_old , ats_size_type nbytes_new ) { return GC_REALLOC (p_old, nbytes_new) ; } // end of [ats_realloc_ngc] /* ****** ****** */ #endif /* ATSRUNTIME_GCBDW_C */ /* end of [ats_prelude_gcbdw.c] */ ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/0000700000175000017500000000000012223166160017404 5ustar hwxihwxiats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_top.dats0000664000175000017500000001757112223166160022354 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) #include "prelude/params.hats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_top_" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) %{^ int the_chunk_count = 0 ; // a soft threshold that can be extended int the_chunk_count_limit = 1 ; // int the_chunk_count_limit = 1024 ; // a hard threshold that cannot be extended int the_chunk_count_limit_max = 8192 ; // a list of freed chunk data freeitmlst the_freeitmlst_chunk_data = (freeitmlst)0 ; #ifdef _ATS_MULTITHREAD // this is the lock that protects the previous variables pthread_mutex_t the_gc_main_lock = PTHREAD_MUTEX_INITIALIZER ; #endif // [_ATS_MULTITHREAD] /* ****** ****** */ chunklst the_sweeplst_array[FREEITMLST_ARRAYSIZE] = { (chunklst)0 } ; #ifdef _ATS_MULTITHREAD pthread_mutex_t the_sweeplst_lock_array[FREEITMLST_ARRAYSIZE] ; ats_void_type gc_sweeplst_lock_array_init () { int i ; pthread_mutex_t *p_lock ; i = 0 ; p_lock = the_sweeplst_lock_array ; while (i < FREEITMLST_ARRAYSIZE) { pthread_mutex_init (p_lock, NULL); i += 1; p_lock += 1 ; } /* fprintf (stderr, "the_sweeplst_lock_array has been initialized.\n") ; */ return ; } #endif /* ****** ****** */ #ifdef _ATS_MULTITHREAD // __thread // freeitmlst the_freeitmlst_array[FREEITMLST_ARRAYSIZE] = // { (freeitmlst)0 } ; __thread freeitmlst *the_freeitmlst_array = (freeitmlst*)0 ; #else /* single thread */ freeitmlst the_freeitmlst_array[FREEITMLST_ARRAYSIZE] = { (freeitmlst)0 } ; #endif /* ****** ****** */ // protecting [the_globalentrylst] in [gc_globalentrylst.dats] #ifdef _ATS_MULTITHREAD pthread_mutex_t the_globalentrylst_lock = PTHREAD_MUTEX_INITIALIZER ; #endif /* ****** ****** */ // manually managed list of allocated memories manmemlst the_manmemlst = (manmemlst)0 ; #ifdef _ATS_MULTITHREAD pthread_mutex_t the_manmemlst_lock = PTHREAD_MUTEX_INITIALIZER ; #endif /* ****** ****** */ #ifdef _ATS_MULTITHREAD pthread_mutex_t the_threadinfolst_lock = PTHREAD_MUTEX_INITIALIZER ; #endif /* ****** ****** */ #if (__WORDSIZE == 32) botsegtbllst the_topsegtbl[TOPSEG_TABLESIZE] = { (botsegtbllst)0 } ; #endif // end of [__WORDSIZE == 32] #if (__WORDSIZE == 64) botsegtbllst the_topsegtbl[TOPSEG_HASHTABLESIZE] = { (botsegtbllst)0 } ; #endif // end of [__WORDSIZE == 64] /* ****** ****** */ ats_int_type the_markstatck_overflow = 0 ; // for debugging purpose // ats_void_type segfault (void) { return *(int*)0 ; } %} (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) %{$ ats_int_type gc_chunk_count_limit_get () { return the_chunk_count_limit ; } ats_void_type gc_chunk_count_limit_set (ats_int_type n) { if (n >= 0) { the_chunk_count_limit = n ; } else { fprintf (stderr, "GC Fatal Error: [gc_chunk_count_limit_set]: negative argument.\n") ; exit (1) ; } return ; } ats_int_type gc_chunk_count_limit_max_get () { return the_chunk_count_limit_max ; } ats_void_type gc_chunk_count_limit_max_set (ats_int_type n) { the_chunk_count_limit_max = n ; return ; } %} (* ****** ****** *) extern fun freeitmlst_chunk_data_get (): freeitmlst0 = "freeitmlst_chunk_data_get" %{$ extern ats_ptr_type the_freeitmlst_chunk_data ; ats_ptr_type freeitmlst_chunk_data_get () { return the_freeitmlst_chunk_data ; } %} implement gc_fprint_stats {m} (pf | out) = let val () = let val nchunk = the_chunk_count_get () in fprintf (pf | out, "the_chunk_count:\t%i\n", @(nchunk)) end val () = let val ndata = freeitmlst_length (freeitmlst_chunk_data_get ()) in fprintf (pf | out, "the_free_chunk_data_count:\t%i\n", @(ndata)) end #define N FREEITMLST_ARRAYSIZE fun loop {i:nat | i <= N} .. (out: &FILE m, i: int i): void = begin if i < N then let val itms = the_freeitmlst_array_get (i) val nitm = freeitmlst_length (itms); val () = begin fprintf (pf | out, "freeitmlst(%i):\t%i\n", @(i, nitm)) end in loop (out, i+1) end end // end of [loop] val () = loop (out, 0) in // empty end // end of [gc_fprint_stats] implement gc_print_stats () = let val (pf_stdout | ptr_stdout) = stdout_get () val () = begin gc_fprint_stats (file_mode_lte_w_w | !ptr_stdout) end in stdout_view_set (pf_stdout | (*none*)) end // end of [gc_print_stats] implement gc_prerr_stats () = let val (pf_stderr | ptr_stderr) = stderr_get () val () = begin gc_fprint_stats (file_mode_lte_w_w | !ptr_stderr) end in stderr_view_set (pf_stderr | (*none*)) end // end of [gc_prerr_stats] (* ****** ****** *) dynload "gcats1_misc.dats" dynload "gcats1_freeitmlst.dats" dynload "gcats1_chunk.dats" dynload "gcats1_globalentry.dats" #ifdef _ATS_MULTITHREAD dynload "gcats1_multithread.dats" #endif dynload "gcats1_marking.dats" dynload "gcats1_collecting.dats" dynload "gcats1_autops.dats" dynload "gcats1_manops.dats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // disabling implicit dynamic loading and // using explicit dynamic loading instead #define ATS_DYNLOADFUN_NAME "gc_init" // name for the dynload function val () = let // initialization val dir = gc_stack_dir_get () val () = gc_stack_beg_set (dir) #ifdef _ATS_MULTITHREAD val () = gc_sweeplst_lock_array_init () where { extern fun gc_sweeplst_lock_array_init (): void = "gc_sweeplst_lock_array_init" } val () = gc_sem_init () where { extern fun gc_sem_init (): void = "gc_sem_init" } val () = gc_signal_init () where { extern fun gc_signal_init (): void = "gc_signal_init" } val () = gc_threadinfo_init () where { extern fun gc_threadinfo_init (): void = "gc_threadinfo_init" } #endif // [_ATS_MULTITHREAD] val () = the_markstack_extend (1) #if (ATS_GC_VERBOSE_LEVEL >= 1) val () = (prerr "GC initialization is done."; prerr_newline ()) #endif // [ATS_GC_VERBOSE_LEVEL] in (* empty *) end // end of [gc_init] (* ****** ****** *) %{$ ats_ptr_type the_globalentrylst = (ats_ptr_type)0 ; // GLOBALENTRYLSTnil // end of ... extern void globalentrylst_insert (ats_ref_type ents, ats_ptr_type ptr, ats_int_type wsz) ; ats_void_type gc_markroot_bsz (ats_ptr_type ptr, ats_int_type bsz/*bytesize*/) { int wsz = (bsz >> NBYTE_PER_WORD_LOG) ; /* fprintf (stderr, "gc_markroot_bsz: ptr = %p\n", ptr) ; fprintf (stderr, "gc_markroot_bsz: bsz = %i\n", bsz) ; fprintf (stderr, "gc_markroot_bsz: wsz = %i\n", wsz) ; */ globalentrylst_insert (&the_globalentrylst, ptr, wsz) ; return ; } /* end of [gc_markroot_bsz] */ %} (* ****** ****** *) (* end of [gcats1_top.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_all.cats0000664000175000017500000000500412223166160022305 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // June 2008 // /* ****** ****** */ /* include some .h files */ #include "ats_config.h" #include "ats_basics.h" #include "ats_exception.h" #include "ats_memory.h" #include "ats_types.h" /* ****** ****** */ /* include some .cats files */ #include "prelude/CATS/array.cats" #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" /* ****** ****** */ #include "gcats1.cats" #include "gcats1_top_dats.c" #include "gcats1_misc_dats.c" #include "gcats1_freeitmlst_dats.c" #include "gcats1_chunk_dats.c" #include "gcats1_globalentry_dats.c" #ifdef _ATS_MULTITHREAD #include "gcats1_multithread_dats.c" #endif #include "gcats1_marking_dats.c" #include "gcats1_collecting_dats.c" #include "gcats1_autops_dats.c" #include "gcats1_manops_dats.c" /* ****** ****** */ /* end of [gcats1_all.cats] */ ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1.sats0000664000175000017500000003715012223166160021504 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) %{# #include "gcats1.cats" %} // end of [%{#] (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) abst@ype freeitm (wsz:int) (* size unit: word *) viewtypedef freeitmptrsz (wsz:int, l:addr) = @{ ptr= ptr l, size= int wsz, view= freeitm wsz @ l } viewtypedef freeitmptrsz () = [wsz:int] [l:addr] freeitmptrsz (wsz, l) (* ****** ****** *) abstype freeitmlst (n:int) typedef freeitmlst0 = [n:nat] freeitmlst (n) typedef freeitmlst1 = [n:pos] freeitmlst (n) fun freeitmlst2ptr (x: freeitmlst0): ptr = "freeitmlst2ptr" (* ****** ****** *) // // implemented in [gcats1_misc.dats] // fun gc_stack_dir_get (): int = "gc_stack_dir_get" fun gc_stack_beg_get (): ptr = "gc_stack_beg_get" fun gc_stack_beg_set (dir: int): void = "gc_stack_beg_set" (* ****** ****** *) // // A variety of locks // absview gc_main_lock_v fun gc_main_lock_acquire (): (gc_main_lock_v | void) = "gc_main_lock_acquire" fun gc_main_lock_release (pf: gc_main_lock_v | (*none*)): void = "gc_main_lock_release" // absview globalentrylst_lock_v fun the_globalentrylst_lock_acquire (): (globalentrylst_lock_v | void) = "the_globalentrylst_lock_acquire" fun the_globalentrylst_lock_release (pf: globalentrylst_lock_v | (*none*)): void = "the_globalentrylst_lock_release" // absview manmemlst_lock_v fun the_manmemlst_lock_acquire (): (manmemlst_lock_v | void) = "the_manmemlst_lock_acquire" fun the_manmemlst_lock_release (pf: manmemlst_lock_v | (*none*)): void = "the_manmemlst_lock_release" // absview threadinfolst_lock_v fun the_threadinfolst_lock_acquire (): (threadinfolst_lock_v | void) = "the_threadinfolst_lock_acquire" fun the_threadinfolst_lock_release (pf: threadinfolst_lock_v | (*none*)): void = "the_threadinfolst_lock_release" // absview sweeplst_lock_v (int) absview sweeplst_lock_all_v absview sweeplst_lock_rest_v (int) prval sweeplst_lock_all_takeout {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: sweeplst_lock_all_v | i: int i): (sweeplst_lock_v i, sweeplst_lock_rest_v i) prval sweeplst_lock_all_complete {i:nat | i < FREEITMLST_ARRAYSIZE} (pf1: sweeplst_lock_v i, pf2: sweeplst_lock_rest_v i): sweeplst_lock_all_v // fun the_sweeplst_lock_acquire_one {i:nat | i < FREEITMLST_ARRAYSIZE} (i: int i): (sweeplst_lock_v i | void) = "the_sweeplst_lock_acquire_one" fun the_sweeplst_lock_release_one {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: sweeplst_lock_v i | i: int i): void = "the_sweeplst_lock_release_one" // fun the_sweeplst_lock_acquire_all (): (sweeplst_lock_all_v | void) = "the_sweeplst_lock_acquire_all" fun the_sweeplst_lock_release_all (pf: sweeplst_lock_all_v | (*none*)): void = "the_sweeplst_lock_release_all" // fun the_sweeplst_lock_acquire_rest {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: sweeplst_lock_v i | i: int i): (sweeplst_lock_all_v | void) = "the_sweeplst_lock_acquire_rest" fun the_sweeplst_lock_release_rest {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: sweeplst_lock_all_v | i: int i): (sweeplst_lock_v i | void) = "the_sweeplst_lock_release_rest" (* ****** ****** *) // // some operations on freeitmlst // fun freeitmlst_is_nil {n:nat} (itms: freeitmlst n): bool (n==0) = "freeitmlst_is_nil" fun freeitmlst_is_cons {n:nat} (itms: freeitmlst n): bool (n>0) = "freeitmlst_is_cons" fun freeitmlst_cons {n:nat} (itm: ptr, itms: freeitmlst n): freeitmlst (n+1) = "freeitmlst_cons" fun freeitmlst_tail_get {n:pos} (itms: freeitmlst n): freeitmlst (n-1) = "freeitmlst_tail_get" fun freeitmlst_length {n:nat} (itms: freeitmlst n): int n = "freeitmlst_length" // // // no lock for the following operations as // [the_freeitmlst_array] is thread-local // fun the_freeitmlst_array_get (i: natLt FREEITMLST_ARRAYSIZE): freeitmlst0 = "the_freeitmlst_array_get" fun the_freeitmlst_array_set (i: natLt FREEITMLST_ARRAYSIZE, itms: freeitmlst0): void = "the_freeitmlst_array_set" fun the_freeitmlst_array_clear_one (i: natLt FREEITMLST_ARRAYSIZE): void = "the_freeitmlst_array_clear_one" fun the_freeitmlst_array_insert_at (itm: ptr, i: natLt FREEITMLST_ARRAYSIZE): void = "the_freeitmlst_array_insert_at" // fun the_freeitmlst_array_clear_all (): void = "the_freeitmlst_array_clear_all" fun the_freeitmlst_array_mark_unset (): void = "the_freeitmlst_array_mark_unset" (* ****** ****** *) // some operation on chunks abstype markbits abstype chunklst (n:int) typedef chunklst0 = [n:nat] chunklst (n) typedef chunklst1 = [n:pos] chunklst (n) fun chunklst2ptr (x: chunklst0): ptr = "chunklst2ptr" fun chunklst_is_nil {n:nat} (chks: chunklst n): bool (n==0) = "chunklst_is_nil" fun chunklst_is_cons {n:nat} (chks: chunklst n): bool (n>0) = "chunklst_is_cons" fun chunklst_itembsz_get (chks: chunklst1): int = "chunklst_itembsz_get" fun chunklst_itemwsz_get (chks: chunklst1): int = "chunklst_itemwsz_get" fun chunklst_itemwsz_log_get (chks: chunklst1): intLt (FREEITMLST_ARRAYSIZE) = "chunklst_itemwsz_log_get" fun chunklst_itemtot_get (chks: chunklst1): int = "chunklst_itemtot_get" fun chunklst_markcnt_get (chks: chunklst1): int = "chunklst_markcnt_get" #ifdef _ATS_MULTITHREAD fun chunklst_freecnt_get (chks: chunklst1): int = "chunklst_freecnt_get" fun chunklst_freecnt_inc (chks: chunklst1): void = "chunklst_freecnt_inc" #endif // fun chunklst_data_get (chks: chunklst1): freeitmlst1 = "chunklst_data_get" fun chunklst_data_nonalign_get (chks: chunklst1): freeitmlst1 = "chunklst_data_nonalign_get" // fun chunklst_markbits_get (chks: chunklst1): markbits = "chunklst_markbits_get" // fun chunklst_sweep_next_get {n:pos} (chks: chunklst n): chunklst (n-1) = "chunklst_sweep_next_get" fun chunklst_sweep_length {n:nat} (chks: chunklst n): int n // fun chunklst_markcnt_dec (chks: chunklst1): void = "chunklst_markcnt_dec" fun chunklst_markcnt_inc (chks: chunklst1): void = "chunklst_markcnt_inc" // fun chunklst_create (pf: !gc_main_lock_v | itemwsz_log: int, itemwsz: int): chunklst1 = "chunklst_create" fun chunklst_create_release (pf: gc_main_lock_v | itemwsz_log: int, itemwsz: int): chunklst1 = "chunklst_create_release" fun chunklst_destroy (pf: !gc_main_lock_v | chks: chunklst1): void = "chunklst_destroy" (* ****** ****** *) fun the_chunk_count_get (): int = "the_chunk_count_get" fun the_chunk_count_dec_by (pf: !gc_main_lock_v | n: int): void = "the_chunk_count_dec_by" fun the_chunk_count_inc_by (pf: !gc_main_lock_v | n: int): void = "the_chunk_count_inc_by" fun the_chunk_count_limit_is_reached (pf: !gc_main_lock_v | (*none*)): bool = "the_chunk_count_limit_is_reached" fun the_chunk_count_limit_is_not_reached (pf: !gc_main_lock_v | (*none*)): bool = "the_chunk_count_limit_is_not_reached" fun the_chunk_count_limit_is_reached_within (pf: !gc_main_lock_v | n: int): bool = "the_chunk_count_limit_is_reached_within" (* ****** ****** *) fun gc_markbits_clear_the_topsegtbl (): void = "gc_markbits_clear_the_topsegtbl" (* ****** ****** *) absprop PTR_TOPSEG_GET_p (int) abst@ype uintptr (i:int) = $extype "ats_uintptr1_type" fun PTR_TOPSEG_GET (p: ptr): [i:nat] (PTR_TOPSEG_GET_p i | uintptr i) = "PTR_TOPSEG_GET" fun PTR_BOTSEG_GET (p: ptr): natLt (BOTSEG_TABLESIZE) = "PTR_BOTSEG_GET" fun PTR_CHKSEG_GET (p: ptr): natLt (CHKSEG_TABLESIZE) = "PTR_CHKSEG_GET" // abstype botsegtbllst (n:int) typedef botsegtbllst0 = [n:nat] botsegtbllst (n) typedef botsegtbllst1 = [n:pos] botsegtbllst (n) // fun botsegtbllst_is_nil {n:nat} (tbls: botsegtbllst n): bool (n==0) = "botsegtbllst_is_nil" fun botsegtbllst_is_cons {n:nat} (tbls: botsegtbllst n): bool (n>0) = "botsegtbllst_is_cons" // #if (__WORDSIZE == 32) fun botsegtbl_make_32 (): botsegtbllst (1) = "botsegtbl_make_32" #endif // end of [__WORDSIZE == 32] #if (__WORDSIZE == 64) fun botsegtbl_make_64 {i,n:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i, tbls: botsegtbllst n) : botsegtbllst (n+1) = "botsegtbl_make_64" #endif // end of [__WORDSIZE == 64] // fun botsegtbllst_get ( tbls: botsegtbllst1 , i: natLt (BOTSEG_TABLESIZE) ) : chunklst0 = "botsegtbllst_get" fun botsegtbllst_set ( tbls: botsegtbllst1 , i: natLt (BOTSEG_TABLESIZE) , chks: chunklst1 ) : void = "botsegtbllst_set" fun botsegtbllst_clear ( tbls: botsegtbllst1 , i: natLt (BOTSEG_TABLESIZE) ) : void = "botsegtbllst_clear" (* ****** ****** *) fun the_topsegtbl_get {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i): botsegtbllst0 fun the_topsegtbl_get_some {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i): botsegtbllst1 (* ****** ****** *) fun gc_ptr_is_valid (p: ptr, ofs: &int): chunklst0 = "gc_ptr_is_valid" (* ****** ****** *) // // manmemlst // abstype manmemlst (n:int) typedef manmemlst0 = [n:nat] manmemlst (n) typedef manmemlst1 = [n:pos] manmemlst (n) // fun the_manmemlst_get (): manmemlst0 = "the_manmemlst_get" // fun manmemlst_is_nil {n:nat} (mms: manmemlst n): bool (n==0) = "manmemlst_is_nil" fun manmemlst_is_cons {n:nat} (mms: manmemlst n): bool (n>0) = "manmemlst_is_cons" // fun manmemlst_length {n:nat} (mms: manmemlst n): int n = "manmemlst_length" // fun manmemlst_itemwsz_get (mms: manmemlst1): int = "manmemlst_itemwsz_get" fun manmemlst_prev_get {n:pos} (mms: manmemlst1): [i:int | i == 0 || i == n+1] manmemlst i = "manmemlst_prev_get" fun manmemlst_next_get {n:pos} (mms: manmemlst n): manmemlst (n-1) = "manmemlst_next_get" fun manmemlst_data_get (mms: manmemlst1): freeitmlst0 = "manmemlst_data_get" (* ****** ****** *) // [marking] abstype markstackpagelst (n: int) // boxed type typedef markstackpagelst0 = [n:nat] markstackpagelst (n) typedef markstackpagelst1 = [n:pos] markstackpagelst (n) // fun markstackpagelst_nil (): markstackpagelst 0 = "markstackpagelst_nil" fun markstackpagelst_is_nil {n:nat} (msps: markstackpagelst n): bool (n==0) = "markstackpagelst_is_nil" fun markstackpagelst_is_cons {n:nat} (msps: markstackpagelst n): bool (n>0) = "markstackpagelst_is_cons" fun markstackpagelst_next_get {n:pos} (msps: markstackpagelst n): markstackpagelst (n-1) = "markstackpagelst_next_get" fun markstackpagelst_prev_get {n:pos} (msps: markstackpagelst n): [i:nat | i == 0 || i == n+1] markstackpagelst i = "markstackpagelst_prev_get" fun markstackpagelst_length {n:nat} (msps: markstackpagelst n): int n = "markstackpagelst_length" // fun MARK_GET (x: markbits, i: int): int = "MARK_GET" fun MARK_SET (x: markbits, i: int): void = "MARK_SET" fun MARK_CLEAR (x: markbits, i: int): void = "MARK_CLEAR" // fun markstackpagelst_entry_get {n:pos} {i:nat | i < MARKSTACK_PAGESIZE} (msps: markstackpagelst n, i: int i, p: &ptr? >> ptr, wsz: &int? >> int): void = "markstackpagelst_entry_get" fun markstackpagelst_entry_set {n:pos} {i:nat | i < MARKSTACK_PAGESIZE} (msps: markstackpagelst n, i: int i, p: ptr, wsz: int): void = "markstackpagelst_entry_set" // fun the_markstack_extend {n:nat} (n: int n): void = "the_markstack_extend" // fun markstack_pop ( msps: &markstackpagelst1 , pos: &natLte(MARKSTACK_PAGESIZE) , p: &ptr? >> ptr, wsz: &int? >> int ) : int (* underflow status *) = "markstack_pop" fun markstack_push ( msps: &markstackpagelst1 , pos: &natLte(MARKSTACK_PAGESIZE) , p: ptr, wsz: int ) : int (* overflow status *) = "markstack_push" fun the_markstack_pop (p: &ptr? >> ptr, wsz: &int? >> int): int = "the_markstack_pop" fun the_markstack_push (p: ptr, wsz: int) : int (* overflow status *) = "the_markstack_push" // fun gc_mark_ptr (p: ptr): void = "gc_mark_ptr" // fun gc_overflow_mark_the_topsegtbl (): void = "gc_overflow_mark_the_topsegtbl" // fun gc_mark_the_stack (): void = "gc_mark_the_stack" fun gc_mark_the_globalentrylst (): void = "gc_mark_the_globalentrylst" // implemented in [gcats1_multithread.dats] fun gc_mark_the_threadinfolst (): void = "gc_mark_the_threadinfolst" // implemented in [gcats1_manops.dats] fun gc_mark_the_manmemlst (): void = "gc_mark_the_manmemlst" // fun gc_mark_all (): int = "gc_mark_all" (* ****** ****** *) // [collecting] fun the_sweeplst_array_get {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: !sweeplst_lock_v i | i: int i): chunklst0 = "the_sweeplst_array_get" fun the_sweeplst_array_set {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: !sweeplst_lock_v i | i: int i, itms: chunklst0): void = "the_sweeplst_array_set" fun the_sweeplst_array_clear_one {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: !sweeplst_lock_v i | i: int i): void = "the_sweeplst_array_clear_one" fun the_sweeplst_array_insert_at {i:nat | i < FREEITMLST_ARRAYSIZE} (pf: !sweeplst_lock_v i | itm: ptr, i: int i): void = "the_sweeplst_array_insert_at" // fun gc_sweeplst_build_the_topsegtbl (): void = "gc_sweeplst_build_the_topsegtbl" // fun gc_collect ( _: !gc_main_lock_v , _: !globalentrylst_lock_v , _: !manmemlst_lock_v , _: !threadinfolst_lock_v , _: !sweeplst_lock_all_v | (*none*) ) : void = "gc_collect" fun gc_chunk_threading (chks: chunklst1): freeitmlst0 = "gc_chunk_threading" fun gc_freeitmlst_generate (* gathering or creating *) (itemwsz_log: natLt FREEITMLST_ARRAYSIZE): freeitmlst1 (* ****** ****** *) // [autops]: automatic management for freeing memory fun gc_aut_malloc_bsz (bsz: int): ptr = "gc_aut_malloc_bsz" fun gc_aut_malloc_wsz (wsz: int): ptr = "gc_aut_malloc_wsz" fun gc_aut_calloc_bsz (n(*all*): int, bsz(*each*): int): ptr = "gc_aut_calloc_bsz" fun gc_aut_free (itm: ptr): void = "gc_aut_free" fun gc_aut_realloc_bsz (ptr: ptr, bsz_new: int): ptr = "gc_aut_realloc_bsz" fun gc_aut_realloc_wsz (ptr: ptr, wsz_new: int): ptr (* ****** ****** *) // [manops]: manual management for freeing memory fun gc_man_malloc_bsz (bsz: int): ptr = "gc_man_malloc_bsz" fun gc_man_calloc_bsz (n(*all*): int, bsz(*each*): int): ptr = "gc_man_calloc_bsz" fun gc_man_free (itm: ptr): void = "gc_man_free" fun gc_man_realloc_bsz (ptr: ptr, bsz_new: int): ptr = "gc_man_realloc_bsz" (* ****** ****** *) // some toplevel operations fun gc_chunk_count_limit_set {n:nat} (n: int n): void = "gc_chunk_count_limit_set" fun gc_chunk_count_limit_max_set {n:nat} (n: int n): void = "gc_chunk_count_limit_max_set" // fun gc_markroot_bsz {n:nat} (p: ptr, bsz: int n): void = "gc_markroot_bsz" // fun gc_fprint_stats {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m): void fun gc_print_stats (): void = "gc_print_stats" fun gc_prerr_stats (): void = "gc_prerr_stats" (* ****** ****** *) (* end of [gcats1.sats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_master.hats0000664000175000017500000001477612223166160023055 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // June 2008 // /* ****** ****** */ /* [gc.hats]: the header file for GC implementation */ /* [gc.hats]: it can be used in both ATS and C */ /* ****** ****** */ #define __assert #assert #define __define #define #define __else #else #define __endif #endif #define __error #error #define __if #if #define __ifdef #ifdef #define __include #include #define __print #print #define __undef #undef /* ****** ****** */ __undef __WORDSIZE /* ****** ****** */ __include "config.h" // automatically generated in $(ATSHOME) /* ****** ****** */ #if _ATS_MULTITHREAD0 __undef _ATS_MULTITHREAD // no pthread support #endif #if _ATS_MULTITHREAD1 __define _ATS_MULTITHREAD // pthreads are supported #endif /* ****** ****** */ __undef NBIT_PER_BYTE __undef NBIT_PER_BYTE_LOG __define NBIT_PER_BYTE 8 __define NBIT_PER_BYTE_LOG 3 __define NBIT_PER_BYTE_MASK (NBIT_PER_BYTE - 1) // __assert (NBIT_PER_BYTE == 1 << NBIT_PER_BYTE_LOG) __if (NBIT_PER_BYTE != 1 << NBIT_PER_BYTE_LOG) __error "#assert (NBIT_PER_BYTE != 1 << NBIT_PER_BYTE_LOG)\n" __endif /* ****** ****** */ // __WORDSIZE = 32 or 64 // __print "__WORDSIZE = "; __print __WORDSIZE; __print "\n" /* ****** ****** */ __ifdef __WORDSIZE __if (__WORDSIZE != SIZEOF_VOIDP * NBIT_PER_BYTE) __error "#assert (__WORDSIZE == SIZEOF_VOIDP * NBIT_PER_BYTE)" __endif __else __define __WORDSIZE (SIZEOF_VOIDP * NBIT_PER_BYTE) __endif // end of [ifdef __WORDSIZE] /* ****** ****** */ __if (__WORDSIZE != 32) __if (__WORDSIZE != 64) __error "__WORDSIZE is neither 32 nor 64!\n" __endif __endif /* ****** ****** */ __undef NBIT_PER_WORD __undef NBIT_PER_WORD_LOG /* ****** ****** */ __if (__WORDSIZE == 32) __define NBIT_PER_WORD 32 __define NBIT_PER_WORD_LOG 5 // __assert (NBIT_PER_WORD == 1 << NBIT_PER_WORD_LOG) __if (NBIT_PER_WORD != 1 << NBIT_PER_WORD_LOG) __error "#assert (NBIT_PER_WORD == 1 << NBIT_PER_WORD_LOG)\n" __endif __define NBYTE_PER_WORD 4 __define NBYTE_PER_WORD_LOG 2 // __assert (NBYTE_PER_WORD == 1 << NBYTE_PER_WORD_LOG) __if (NBYTE_PER_WORD != 1 << NBYTE_PER_WORD_LOG) __error "#assert (NBYTE_PER_WORD == 1 << NBYTE_PER_WORD_LOG)\n" __endif __endif // end of [__WORDSIZE == 32] /* ****** ****** */ __if (__WORDSIZE == 64) __define NBIT_PER_WORD 64 __define NBIT_PER_WORD_LOG 6 // __assert (NBIT_PER_WORD == 1 << NBIT_PER_WORD_LOG) __if (NBIT_PER_WORD != 1 << NBIT_PER_WORD_LOG) __error "#assert (NBIT_PER_WORD == 1 << NBIT_PER_WORD_LOG)\n" __endif __define NBYTE_PER_WORD 8 __define NBYTE_PER_WORD_LOG 3 // __assert (NBYTE_PER_WORD == 1 << NBYTE_PER_WORD_LOG) __if (NBYTE_PER_WORD != 1 << NBYTE_PER_WORD_LOG) __error "#assert (NBYTE_PER_WORD == 1 << NBYTE_PER_WORD_LOG)\n" __endif __endif // end of [__WORDSIZE == 64] // __define NBYTE_PER_WORD_MASK (NBYTE_PER_WORD - 1) /* ****** ****** */ __define PTR_CHKSEG_SIZE 11 __define PTR_BOTSEG_SIZE 10 __define PTR_BOTCHKSEG_SIZE (PTR_BOTSEG_SIZE + PTR_CHKSEG_SIZE) __define PTR_TOPSEG_SIZE (NBIT_PER_WORD - PTR_BOTCHKSEG_SIZE - NBYTE_PER_WORD_LOG) // __PRINT "PTR_TOPSEG_SIZE = "; __PRINT PTR_TOPSEG_SIZE; __PRINT "\n" __if (__WORDSIZE == 32) __define TOPSEG_TABLESIZE (1 << PTR_TOPSEG_SIZE) __endif __if (__WORDSIZE == 64) __define TOPSEG_HASHTABLESIZE 4096 __define TOPSEG_HASHTABLESIZE_LOG 12 // __assert (TOPSEG_HASHTABLESIZE == 1 << TOPSEG_HASHTABLESIZE_LOG) __if (TOPSEG_HASHTABLESIZE != 1 << TOPSEG_HASHTABLESIZE_LOG) __error "#assert (TOPSEG_HASHTABLESIZE == 1 << TOPSEG_HASHTABLESIZE_LOG)\n" __endif __endif // end of [__WORDSIZE == 64] // __define CHKSEG_TABLESIZE 2048 // __assert (CHKSEG_TABLESIZE == 1 << PTR_CHKSEG_SIZE) __if (CHKSEG_TABLESIZE != 1 << PTR_CHKSEG_SIZE) __error "assert (CHKSEG_TABLESIZE == 1 << PTR_CHKSEG_SIZE)\n" __endif // __define BOTSEG_TABLESIZE 1024 // __assert (BOTSEG_TABLESIZE == 1 << PTR_BOTSEG_SIZE) __if (BOTSEG_TABLESIZE != 1 << PTR_BOTSEG_SIZE) __error "assert (BOTSEG_TABLESIZE == 1 << PTR_BOTSEG_SIZE)\n" __endif __define BOTSEG_TABLESIZE_MASK (BOTSEG_TABLESIZE - 1) // __define CHUNK_WORDSIZE_LOG PTR_CHKSEG_SIZE __define CHUNK_WORDSIZE (1 << CHUNK_WORDSIZE_LOG) __define CHUNK_WORDSIZE_MASK (CHUNK_WORDSIZE - 1) __define CHUNK_BYTESIZE_LOG (CHUNK_WORDSIZE_LOG + NBYTE_PER_WORD_LOG) __define CHUNK_BYTESIZE (CHUNK_WORDSIZE << NBYTE_PER_WORD_LOG) __define CHUNK_BYTESIZE_MASK (CHUNK_BYTESIZE - 1) // __define MAX_CHUNK_BLOCK_WORDSIZE_LOG CHUNK_WORDSIZE_LOG __define MAX_CHUNK_BLOCK_WORDSIZE (1 << MAX_CHUNK_BLOCK_WORDSIZE_LOG) // __assert (MAX_CHUNK_BLOCK_WORDSIZE <= CHUNK_WORDSIZE) // // the_freeitmlst_array: // [ 2^0 | 2^1 | ... | 2^MAX_CHUNK_BLOCK_WORDSIZE_LOG] __define FREEITMLST_ARRAYSIZE (MAX_CHUNK_BLOCK_WORDSIZE_LOG + 1) // __define MARKSTACK_PAGESIZE 4000 __define MARKSTACK_CUTOFF (CHUNK_WORDSIZE / 4) __define CHUNK_SWEEP_CUTOFF 0.75 // 75% // __assert (0.0 <= CHUNK_SWEEP_CUTOFF) // __assert (CHUNK_SWEEP_CUTOFF <= 1.0) __define CHUNK_LIMIT_EXTEND_CUTOFF 0.75 // 75% // __assert (0.0 <= CHUNK_LIMIT_EXTEND_CUTOFF) // __assert (CHUNK_LIMIT_EXTEND_CUTOFF <= 1.0) // __define GLOBALENTRYPAGESIZE 64 // largely chosen arbitrarily /* ****** ****** */ __define ATS_GC_VERBOSE 0 // 1 __define ATS_GC_RUNTIME_CHECK 0 // 1 /* ****** ****** */ /* end of [gcats1_master.hats] */ ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_multithread.dats0000664000175000017500000002377112223166160024073 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) %{^ /* ****** ****** */ sem_t the_sleep_semaphore ; void gc_sem_init () { sem_init(&the_sleep_semaphore, 0, 0); return ; } /* ****** ****** */ threadinfolst the_threadinfolst_fst ; __thread threadinfolst the_threadinfolst_self ; void prerr_self_pid () { fprintf (stderr, "%i", (int)(the_threadinfolst_self->pid)) ; return ; } /* ****** ****** */ void the_threadinfolst_self_stack_end_set () { void *ptr ; the_threadinfolst_self->stack_end = &ptr ; return ; } void SIGUSR1_handle (int signum) { jmp_buf reg_save ; sigset_t sigset ; the_threadinfolst_self_stack_end_set () ; setjmp(reg_save) ; asm volatile ("": : :"memory") ; sem_post(&the_sleep_semaphore) ; sigfillset(&sigset) ; // blocking all signals sigdelset(&sigset, SIGUSR2) ; // except [SIGUSR2] sigsuspend(&sigset) ; // go into suspension return ; } /* end of [SIGUSR1_handle] */ void SIGUSR2_handle (int signum) { return ; } void gc_signal_init () { int err = 0 ; struct sigaction action1, action2 ; sigset_t *action1_sa_mask, *action2_sa_mask ; action1.sa_handler = &SIGUSR1_handle ; action1_sa_mask = &(action1.sa_mask) ; sigemptyset (action1_sa_mask) ; sigaddset (action1_sa_mask, SIGUSR2) ; // blocking [SIGUSR2] action1.sa_flags = SA_RESTART ; err = sigaction (SIGUSR1, &action1, NULL) ; if (err < 0) { perror ("[sigaction] failed on [SIGUSR1]\n") ; } /* fprintf (stderr, "gc_signal_init: [SIGUSR1] has been initialized\n") ; */ action2.sa_handler = &SIGUSR2_handle ; action2_sa_mask = &(action2.sa_mask) ; sigemptyset (action2_sa_mask) ; sigaddset (action2_sa_mask, SIGUSR1) ; // blocking [SIGUSR1] err = sigaction (SIGUSR2, &action2, NULL) ; if (err < 0) { perror ("[sigaction] failed on [SIGUSR2]\n") ; } /* fprintf (stderr, "gc_signal_init: [SIGUSR2] has been initialized\n") ; */ return ; } /* end of [gc_signal_init] */ /* ****** ****** */ %} // end of [%{^] #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_multithread_" (* ****** ****** *) abstype threadinfolst (int) typedef threadinfolst0 = [n:nat] threadinfolst (n) typedef threadinfolst1 = [n:pos] threadinfolst (n) extern fun gc_mark_threadinfo_freeitmlst (itms: freeitmlst0): void = "gc_mark_threadinfo_freeitmlst" implement gc_mark_threadinfo_freeitmlst (itms) = begin if freeitmlst_is_cons (itms) then let val ptr = freeitmlst2ptr itms; var ofs: int = 0 val chks = gc_ptr_is_valid (ptr, ofs) val chks = ( if chunklst_is_cons chks then chks else begin prerr "GC: Fatal Error: [gc_mark_threadinfo_freeitmlst]"; prerrf (": the pointer [%p] is invalid.", @(ptr)); prerr_newline (); exit {chunklst1} (1) end ) : chunklst1 val markbits = chunklst_markbits_get (chks) val () = // could this really happen? if MARK_GET (markbits, ofs) > 0 then begin // this could happen only if data is mistreated as a pointer!!! MARK_CLEAR (markbits, ofs); chunklst_markcnt_dec (chks) end val () = chunklst_freecnt_inc (chks) // preventing [chks] from being swept in gc_mark_threadinfo_freeitmlst (freeitmlst_tail_get itms) end // end of [if] end // end of [gc_mark_threadinfo_freeitmlst] (* ****** ****** *) %{$ extern ats_ptr_type gc_stack_beg_get () ; extern ats_void_type gc_stack_beg_set (ats_int_type dir) ; extern __thread freeitmlst *the_freeitmlst_array ; ats_void_type gc_threadinfo_init () { threadinfolst current ; // explicit allocation done to avoid a bug involving thread-local arrays the_freeitmlst_array = calloc (FREEITMLST_ARRAYSIZE, sizeof(freeitmlst)) ; if (!the_freeitmlst_array) { fprintf (stderr, "GC Fatal Error: [gc_threadinfo_init]") ; fprintf (stderr, ": [malloc] failed: no memory for [the_freeitmlst_array].\n") ; exit (1) ; } // end of [if] current = (threadinfolst)malloc (sizeof(threadinfo)) ; if (!current) { fprintf ( stderr, "GC Fatal Error: [gc_threadinfo_init]: [malloc] failed.\n" ) ; // end of [fprintf] exit (1) ; } // end of [if] /* thread-local: */ the_threadinfolst_self = current ; current->pid = pthread_self() ; /* fprintf (stdout, "gc_threadinfo_init: current->pid = %i\n", current->pid) ; */ gc_stack_beg_set (gc_stack_dir_get ()) ; current->stack_beg = gc_stack_beg_get () ; current->stack_end = (ats_ptr_type)0 ; current->prev = (threadinfolst)0 ; the_threadinfolst_lock_acquire () ; current->next = the_threadinfolst_fst ; if (the_threadinfolst_fst) the_threadinfolst_fst->prev = current ; the_threadinfolst_fst = current ; the_threadinfolst_lock_release () ; // [the_freeitmlst_array] is thread-local current->freeitmlst_array = the_freeitmlst_array ; /* fprintf (stdout, "gc_threadinfo_init: return\n") ; */ return ; } /* gc_threadinfo_init */ ats_void_type gc_threadinfo_fini () { threadinfolst _prev, _next ; the_threadinfolst_lock_acquire () ; _prev = the_threadinfolst_self->prev ; _next = the_threadinfolst_self->next ; if (_next) { _next->prev = _prev ; } if (_prev) { _prev->next = _next ; } else { // [the_threadinfolst_self] is the first the_threadinfolst_fst = _next ; } the_threadinfolst_lock_release () ; free (the_threadinfolst_self) ; // explicit deallocation done to avoid a bug involving thread-local arrays free (the_freeitmlst_array) ; return ; } /* end of [gc_threadinfo_fini] */ %} (* ****** ****** *) %{$ static inline ats_void_type gc_mark_threadinfolst_one (threadinfolst infolst) { int i, dir ; freeitmlst *freeitmlst_array, *_fr, *_to ; /* scanning the thread freeitmlst array */ i = 0; freeitmlst_array = infolst->freeitmlst_array ; while (i < FREEITMLST_ARRAYSIZE) { gc_mark_threadinfo_freeitmlst (*freeitmlst_array) ; i += 1 ; freeitmlst_array += 1 ; } /* end of [while] */ /* scanning the thread stack */ if (!infolst->stack_end) { fprintf (stderr, "GC Fatal Error: [gc_mark_threadinfolst_one]") ; fprintf (stderr, ": illegal stack info: infolst = %p\n", infolst) ; exit (1) ; } dir = gc_stack_dir_get () ; if (dir > 0) { _fr = infolst->stack_beg ; _to = infolst->stack_end - 1 ; } else { _to = infolst->stack_beg ; _fr = infolst->stack_end + 1 ; } // end of [if] while (_fr <= _to) { gc_mark_ptr (*_fr) ; _fr += 1 ; // termination: obvious } // end of [while] return ; } static inline ats_void_type gc_mark_threadinfolst_all (threadinfolst infolst) { /* fprintf (stderr, "gc_mark_threadinfolst_all: the_threadinfolst_self = "); fprintf (stderr, "%p\n", the_threadinfolst_self) ; */ while (infolst) { /* fprintf (stderr, "gc_mark_threadinfolst_all: infolst = %p\n", infolst) ; */ if (infolst != the_threadinfolst_self) gc_mark_threadinfolst_one (infolst) ; infolst = infolst->next ; } return ; } /* end of [gc_mark_threadinfo_all] */ ats_void_type gc_mark_the_threadinfolst () { gc_mark_threadinfolst_all (the_threadinfolst_fst) ; } /* end of [gc_mark_the_threadinfo] */ %} // end of [%{$] (* ****** ****** *) %{$ extern ats_void_type gc_aut_free (ats_ptr_type) ; extern ats_void_type gc_man_free (ats_ptr_type) ; extern ats_ptr_type gc_man_malloc_bsz (ats_int_type) ; void* gc_pthread_stubfun (void *data0) { void **data ; void *(*start_routine)(void*), *arg, *ret ; data = (void**)data0 ; start_routine = (void *(*)(void*))(data[0]) ; arg = data[1] ; gc_man_free (data) ; gc_threadinfo_init () ; pthread_cleanup_push (gc_threadinfo_fini, (void*)0) ; // fprintf (stderr, "gc_pthread_stubfun: before call to [start_routine]\n") ; ret = start_routine (arg) ; // fprintf (stderr, "gc_pthread_stubfun: after call to [start_routine]\n") ; pthread_cleanup_pop (1) ; // [1] means pop and execute return ret ; } /* end of [gc_pthread_stubfun] */ /* ****** ****** */ int gc_pthread_create ( int detached , ats_ptr_type f, ats_ptr_type env , pthread_t *tid_r ) { void **data ; pthread_t tid ; pthread_attr_t attr; int ret ; // data = gc_man_malloc_bsz (2*sizeof(void*)) ; data[0] = f ; data[1] = env ; // if (detached) { pthread_attr_init (&attr); pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) ; ret = pthread_create (&tid, &attr, &gc_pthread_stubfun, data) ; } else { ret = pthread_create (&tid, NULL/*default*/, &gc_pthread_stubfun, data) ; } // end of [if] if (ret != 0) gc_man_free (data) ; // no thread is created due to error if (tid_r) *tid_r = tid ; return ret ; } /* end of [gc_pthread_create] */ %} // end of [%{$] (* ****** ****** *) (* end of [gcats1_multithread.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_collecting.dats0000664000175000017500000003401412223166160023664 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) // the code handles sweeping and threading in GC (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_collecting_" (* ****** ****** *) extern fun the_sweeplst_array_clear_all (pf: !sweeplst_lock_all_v | (*none*)): void = "the_sweeplst_array_clear_all" implement the_sweeplst_array_clear_all (pf | (*none*)) = let #define N FREEITMLST_ARRAYSIZE fun loop {i:nat | i <= N} .. (pf: !sweeplst_lock_all_v | i: int i): void = if i < N then let prval @(pfi, pfc) = sweeplst_lock_all_takeout (pf | i) val () = the_sweeplst_array_clear_one (pfi | i) val () = (pf := sweeplst_lock_all_complete (pfi, pfc)) in loop (pf | i+1) end // end of [if] in loop (pf | 0) end // end of [the_sweeplst_array_clear_all] (* ****** ****** *) extern fun gc_sweeplst_build_chunk (chks: chunklst1): void = "gc_sweeplst_build_chunk" extern fun gc_sweeplst_build_botsegtbl (tbls: botsegtbllst1): void = "gc_sweeplst_build_botsegtbl" implement gc_sweeplst_build_botsegtbl (tbls) = let fun loop {i:nat | i <= BOTSEG_TABLESIZE} .. (tbls: botsegtbllst1, i: int i): void = begin if i < BOTSEG_TABLESIZE then let val chks = botsegtbllst_get (tbls, i); val () = begin if chunklst_is_cons (chks) then gc_sweeplst_build_chunk (chks) end in loop (tbls, i+1) end // end of [if] end // end of [loop] in loop (tbls, 0) end // end of [gc_sweeplst_build_botsegtbl] (* ****** ****** *) extern fun fprint_the_sweeplst_array_all (): void = "fprint_the_sweeplst_array_all" implement gc_freeitmlst_generate (itemwsz_log) = let #define _log itemwsz_log #define itemwsz (1 << itemwsz_log) (* val () = begin prerr "gc_freeitmlst_generate: _log = "; prerr _log; prerr_newline () end *) val (pf_sweeplst_one | ()) = the_sweeplst_lock_acquire_one (_log) val chks = the_sweeplst_array_get (pf_sweeplst_one | _log) val chks = ( if chunklst_is_cons (chks) then chks else let val () = the_sweeplst_lock_release_one (pf_sweeplst_one | _log) val (pf_main | ()) = gc_main_lock_acquire () val (pf1_sweeplst_one | ()) = the_sweeplst_lock_acquire_one (_log) prval () = pf_sweeplst_one := pf1_sweeplst_one val chks = the_sweeplst_array_get (pf_sweeplst_one | _log) in if chunklst_is_cons chks then begin gc_main_lock_release (pf_main | (*none*)); chks end else let val is_not_reached = the_chunk_count_limit_is_not_reached (pf_main | (*none*)) in if (is_not_reached) then begin chunklst_create_release (pf_main | _log, itemwsz) end else let val (pf_globals | ()) = the_globalentrylst_lock_acquire () val (pf_manmemlst | ()) = the_manmemlst_lock_acquire () val (pf_threads | ()) = the_threadinfolst_lock_acquire () val (pf_sweeplst_all | ()) = begin the_sweeplst_lock_acquire_rest (pf_sweeplst_one | _log) end val () = gc_collect ( pf_main, pf_globals, pf_manmemlst, pf_threads, pf_sweeplst_all | (*none*) ) // end of [gc_collect] val (pf1_sweeplst_one | ()) = begin the_sweeplst_lock_release_rest (pf_sweeplst_all | _log) end prval () = pf_sweeplst_one := pf1_sweeplst_one val () = the_threadinfolst_lock_release (pf_threads | (*none*)) val () = the_manmemlst_lock_release (pf_manmemlst | (*none*)) val () = the_globalentrylst_lock_release (pf_globals | (*none*)) val chks = the_sweeplst_array_get (pf_sweeplst_one | _log) (* val () = begin prerr "gc_freeitmlst_generate: chks = "; prerr (chunklst2ptr chks); prerr_newline () end *) in if chunklst_is_cons chks then begin gc_main_lock_release (pf_main | (*none*)); chks end else begin chunklst_create_release (pf_main | _log, itemwsz) end // end of [if] end // end of [if (is_not_reached) ...] end // end of [if chunklst_is_cons (chks) ...] end // end of [if chunklst_is_cons (chks) ...] ) : chunklst1 (* val () = begin prerr "gc_freeitmlst_generate: chks = "; prerr (chunklst2ptr chks); prerr_newline () end *) val chks1 = chunklst_sweep_next_get chks val () = the_sweeplst_array_set (pf_sweeplst_one | _log, chks1) val () = the_sweeplst_lock_release_one (pf_sweeplst_one | _log) val itms = gc_chunk_threading (chks) (* val () = begin prerr "gc_freeitmlst_generate: itms = "; prerr (freeitmlst2ptr itms); prerr_newline () end *) in if freeitmlst_is_nil itms then begin prerr "GC: Fatal Error"; prerr ": [gc_freeitmlst_generate]: the generated freeitmlst is nil"; prerr_newline (); exit {freeitmlst1} (1) end else begin itms // return value end // end of [if] end // end of [gc_freeitmlst_generate] (* ****** ****** *) %{$ // [chks] must not be NULL! ats_void_type gc_sweeplst_build_chunk (ats_ptr_type chks) { int i, j ; freeitmlst *pi, *pij ; int itemwsz_log, itemtot, markcnt ; int freecnt ; markcnt = chunklst_markcnt_get (chks) ; /* fprintf (stderr, "gc_sweeplst_build_chunk: markcnt = %i\n", markcnt) ; */ #ifdef _ATS_MULTITHREAD // this logic is problematic! freecnt = chunklst_freecnt_get (chks) ; if (freecnt > 0) { fprintf (stderr, "gc_sweeplst_build_chunk: freecnt = %i\n", freecnt) ; return ; } #endif if (markcnt == 0) { chunklst_destroy (chks) ; return ; } itemtot = chunklst_itemtot_get (chks) ; if (markcnt > itemtot * CHUNK_SWEEP_CUTOFF) return ; itemwsz_log = chunklst_itemwsz_log_get (chks) ; /* if (itemwsz_log < 0) { // chks->itemtot = 1 and markcnt = 1 fprintf (stderr, "GC: Fatal Error: [gc_sweeplst_build_chunk]") ; fprintf (stderr, ": itemwsz_log = %i\n", itemwsz_log) ; exit (1) ; } */ /* fprintf (stderr, "gc_sweeplst_build_chunk: itemwsz_log = %i\n", itemwsz_log) ; */ the_sweeplst_array_insert_at (chks, itemwsz_log) ; return ; } /* end of [gc_sweeplst_build_chunk] */ /* ****** ****** */ #if (__WORDSIZE == 32) ats_void_type gc_sweeplst_build_the_topsegtbl () { int i ; botsegtbllst tbls ; the_sweeplst_array_clear_all () ; for (i = 0; i < TOPSEG_TABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; if (tbls) gc_sweeplst_build_botsegtbl (tbls) ; } // end of [for] return ; } /* end of [gc_sweeplst_build_the_topsegtbl] */ #endif // end of [__WORDSIZE == 32] #if (__WORDSIZE == 64) ats_void_type gc_sweeplst_build_the_topsegtbl () { int i ; botsegtbllst tbls ; the_sweeplst_array_clear_all () ; for (i = 0; i < TOPSEG_HASHTABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; while (tbls) { // termination: obvious gc_sweeplst_build_botsegtbl (tbls) ; tbls = tbls->hash_next ; } // end of [while] } // end of [for] return ; } /* end of [gc_sweeplst_build_the_topsegtbl] */ #endif // end of [__WORDSIZE == 64] %} (* ****** ****** *) %{$ #define NCHUNK_PER_MARKSTACKPAGE 32 #define MARKSTACK_EXTEND_INCREMENT 2 extern int the_chunk_count ; extern int the_chunk_count_limit ; extern int the_chunk_count_limit_max ; extern int the_markstackpagecnt ; #ifdef _ATS_MULTITHREAD extern sem_t the_sleep_semaphore ; extern threadinfolst the_threadinfolst_fst ; extern __thread threadinfolst the_threadinfolst_self ; #endif ats_void_type gc_collect () { int overflow, nchunk, nmarkstackpage ; jmp_buf reg_save ; // register contents are roots #ifdef _ATS_MULTITHREAD threadinfolst infolst ; int nother ; #endif /* fprintf( stderr , "GC begs: the_chunk_count = %i and the_chunk_count_limit = %i\n" , the_chunk_count , the_chunk_count_limit ) ; */ setjmp (reg_save) ; // push registers onto the stack asm volatile ("": : :"memory") ; // stop potential optimization nmarkstackpage = (the_chunk_count << CHUNK_WORDSIZE_LOG) ; nmarkstackpage /= (MARKSTACK_PAGESIZE * NCHUNK_PER_MARKSTACKPAGE) ; nmarkstackpage += 1 ; nmarkstackpage -= the_markstackpagecnt ; /* fprintf (stderr, "gc_collect: nmarkstackpage = %i\n", nmarkstackpage) ; */ the_markstack_extend (nmarkstackpage) ; #ifdef _ATS_MULTITHREAD // put all of the other threads into sleep infolst = the_threadinfolst_fst ; nother = 0 ; while (infolst) { if (infolst != the_threadinfolst_self) { fprintf (stderr, "gc_collect: SIGUSR1: infolst->pid = %i\n", (int)(infolst->pid)) ; pthread_kill (infolst->pid, SIGUSR1) ; nother += 1 ; } infolst = infolst->next ; } while (nother) { // ordering is irrelevant fprintf (stderr, "gc_collect: sem_wait: bef: nother = %i\n", nother) ; sem_wait (&the_sleep_semaphore) ; nother -= 1 ; fprintf (stderr, "gc_collect: sem_wait: aft: nother = %i\n", nother) ; } fprintf (stderr, "gc_collect: nother = %i\n", nother) ; #endif // end of [_ATS_MULTITHREAD] gc_markbits_clear_the_topsegtbl () ; // clear all mark bits /* fprintf ( stderr, "gc_collect: gc_markbits_clear_topsegtbl: done\n", nmarkstackpage ) ; // end of [fprintf] */ overflow = gc_mark_all () ; // marking phase /* fprintf (stderr, "gc_collect: gc_mark_all: done\n") ; */ #ifdef _ATS_MULTITHREAD // wake up all of the sleeping threads infolst = the_threadinfolst_fst ; while (infolst) { if (infolst != the_threadinfolst_self) { fprintf (stderr, "gc_collect: SIGUSR2: infolst->pid = %i\n", (int)(infolst->pid)) ; pthread_kill (infolst->pid, SIGUSR2) ; } infolst = infolst->next ; } #endif // end of [_ATS_MULTITHREAD] the_freeitmlst_array_mark_unset () ; /* is this really needed? */ // [gc_mark_threadinfolst_one] is not called on [the_threadinfolst_self] // Therefore [the_freeitmlst_array_clear_all] must be called! the_freeitmlst_array_clear_all () ; /* clear the freeitmlst array */ gc_sweeplst_build_the_topsegtbl () ; // sweep chunks into [the_sweeplst_array] if (overflow > 0) { /* fprintf (stderr, "gc_collect: markstack overflow happend.\n") ; */ the_markstack_extend (MARKSTACK_EXTEND_INCREMENT) ; } /* fprintf( stderr , "GC ends: the_chunk_count = %i and the_chunk_count_limit = %i\n" , the_chunk_count , the_chunk_count_limit ) ; */ if (the_chunk_count_limit_max >= 0) { // [the_chunk_count_limit_max] is finite if (the_chunk_count_limit >= the_chunk_count_limit_max) { // fprintf(stderr, "GC: the_chunk_count_limit = %i\n", the_chunk_count_limit) ; // fprintf(stderr, "GC: the_chunk_count_limit_max = %i\n", the_chunk_count_limit_max) ; fprintf(stderr, "GC: Warning: the maximal chunk count limit is reached!\n") ; return ; } } /* end of [if] */ if (the_chunk_count >= the_chunk_count_limit * CHUNK_LIMIT_EXTEND_CUTOFF) the_chunk_count_limit *= 2 ; /* fprintf( stderr , "GC ends: update: the_chunk_count_limit = %i\n", the_chunk_count_limit ) ; */ return ; } /* end of [gc_collect] */ %} (* ****** ****** *) %{$ ats_ptr_type gc_chunk_threading (ats_ptr_type chks) { int i, j ; int itemwsz, itemtot ; freeitmlst data0, data, data_next ; int markcnt ; byte *markbits ; itemwsz = ((chunklst)chks)->itemwsz ; itemtot = ((chunklst)chks)->itemtot ; markcnt = ((chunklst)chks)->markcnt ; data0 = ((chunklst)chks)->data ; if (markcnt == 0) { // fast threading // threading all the freeitms in the created chunk data = data0 ; data_next = data0 ; for (i = 1; i < itemtot; i += 1) { data_next = (freeitmlst*)data_next + itemwsz ; *(freeitmlst*)data = data_next ; data = data_next ; } // end of [for] *(freeitmlst*)data = (freeitmlst)0 ; goto GC_CHUNK_THREADING_IS_DONE ; } // end of [if] markbits = ((chunklst)chks)-> markbits ; for (i = 0; i < itemtot; i += 1) { if (!MARK_GET (markbits, i)) break ; } if (i == itemtot) { data0 = (freeitmlst)0 ; goto GC_CHUNK_THREADING_IS_DONE ; } data0 = (freeitmlst*)data0 + i * itemwsz; data = data0 ; data_next = data0 ; for (j = i + 1; j < itemtot; j += 1) { data_next = (freeitmlst*)data_next + itemwsz ; if (!MARK_GET (markbits, j)) { *(freeitmlst*)data = data_next ; data = data_next ; } // end of [if] } // end of [for] *(freeitmlst*)data = (freeitmlst)0 ; /* if (itemtot - markcnt != freeitmlst_length (data0)) { fprintf (stderr, "GC: Fatal Error") ; fprintf (stderr, ": [gc_chunk_threading]: consistency check failed.\n") ; fprintf (stderr, "itemtot = %i\n", itemtot) ; fprintf (stderr, "markcnt = %i\n", markcnt) ; fprintf (stderr, "freeitmlst_length(data0) = %i\n", freeitmlst_length(data0)) ; exit (1) ; } */ GC_CHUNK_THREADING_IS_DONE: return data0 ; } /* end of [gc_chunk_threading] */ %} (* ****** ****** *) (* end of [gcats1_collecting.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/Makefile0000664000175000017500000001246612223166160021071 0ustar hwxihwxi######################################################################### ## ## ## Applied Type System ## ## ## ## Hongwei Xi ## ## ## ######################################################################### ## ## ATS/Anairiats - Unleashing the Power of Types! ## ## Copyright (C) 2002-2008 Hongwei Xi, Boston University ## ## All rights reserved ## ## ATS is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free ## Software Foundation; either version 2.1, or (at your option) any later ## version. ## ## ATS is distributed in the hope that it will be useful, but WITHOUT ANY ## WARRANTY; without even the implied warranty of MERCHANTABILITY or ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ## for more details. ## ## You should have received a copy of the GNU General Public License ## along with ATS; see the file COPYING. If not, please write to the ## Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ## 02110-1301, USA. ## ## ###### ###### ## ## Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ## Time: June 2008 ## ###### ###### ## GCC=gcc ATSCC="${ATSHOME}"/bin/atscc #CCFLAG= CCFLAG=-O2 #ATSCCFLAG=-g #ATSCCFLAG=-DGCATS_DEBUG #ATSCCFLAG=-O2 ATSCCFLAG=-O2 -g ###### SOURCES := \ gcats1_misc.dats \ gcats1_freeitmlst.dats \ gcats1_chunk.dats \ gcats1_globalentry.dats \ gcats1_marking.dats \ gcats1_collecting.dats \ gcats1_autops.dats \ gcats1_manops.dats \ gcats1_top.dats \ TARGETS := $(patsubst %.dats, %_dats.c, $(SOURCES)) TARGETS_mt := $(TARGETS) gcats1_multithread_dats.c OBJECTS := $(patsubst %.dats, %_dats.o, $(SOURCES)) OBJECTS_mt := $(OBJECTS) gc_multithread_dats.o ###### # # this generates a slower version: # # gc.o: gcats1_sats.o $(OBJECTS) # ld -r -o gc.o gcats1_sats.o $(OBJECTS) # gc.o: gc0_hats gcats1_sats.o gcats1_all_cats.o ld -r -o $@ gcats1_sats.o gcats1_all_cats.o gc_mt.o: gc1_hats gcats1_sats.o gcats1_mt_all_cats.o ld -r -o $@ gcats1_sats.o gcats1_mt_all_cats.o ###### # # mainly for the purpose of debugging # gcats1_main: gc0_hats gc.cats gcats1_sats.c gcats1_main.dats $(OBJECTS) $(ATSCC) $(CCFLAG) -o gcats1_main gcats1_main.dats gcats1_sats.c $(OBJECTS) gcats1_main_mt: gc1_hats gc.cats gcats1_sats.c gcats1_main.dats $(OBJECTS_mt) $(ATSCC) $(CCFLAG) -pthread -o gcats1_main_mt gcats1_main.dats gcats1_sats.c $(OBJECTS_mt) ###### gc0_hats: ; gcc -E -P -D_ATS_MULTITHREAD0 -x c gcats1_master.hats -o gcats1.hats gc1_hats: ; gcc -E -P -D_ATS_MULTITHREAD1 -x c gcats1_master.hats -o gcats1.hats ###### # # this kind of whole compilation can probably take advantage of # interprocedural optimization: # gcats1_all_cats.o: gcats1_sats.c $(TARGETS) $(ATSCC) $(CCFLAG) -o gcats1_all_cats.o -c -x c gcats1_all.cats gcats1_mt_all_cats.o: gcats1_sats.c $(TARGETS_mt) $(ATSCC) $(CCFLAG) -o gcats1_mt_all_cats.o -c -x c gcats1_all.cats ###### gcats1_sats.c: gcats1.sats $(ATSCC) $(ATSCCFLAG) -cc gcats1.sats gcats1_sats.o: gcats1_sats.c; $(ATSCC) $(CCFLAG) -c gcats1_sats.c ###### gcats1_top_dats.c: gcats1_top.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_top.dats gcats1_top_dats.o: gcats1_top_dats.c; $(ATSCC) $(CCFLAG) -c gcats1_top_dats.c gcats1_misc_dats.c: gcats1_misc.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_misc.dats gcats1_misc_dats.o: gcats1_misc_dats.c $(ATSCC) $(CCFLAG) -c gcats1_misc_dats.c gcats1_freeitmlst_dats.c: gcats1_freeitmlst.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_freeitmlst.dats gcats1_freeitmlst_dats.o: gcats1_freeitmlst_dats.c $(ATSCC) $(CCFLAG) -c gcats1_freeitmlst_dats.c gcats1_chunk_dats.c: gcats1_chunk.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_chunk.dats gcats1_chunk_dats.o: gcats1_chunk_dats.c $(ATSCC) $(CCFLAG) -c gcats1_chunk_dats.c gcats1_globalentry_dats.c: gcats1_globalentry.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_globalentry.dats gcats1_globalentry_dats.o: gcats1_globalentry_dats.c $(ATSCC) $(CCFLAG) -c gcats1_globalentry_dats.c gcats1_multithread_dats.c: gcats1_multithread.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_multithread.dats gcats1_multithread_dats.o: gcats1_multithread_dats.c $(ATSCC) $(CCFLAG) -c gcats1_multithread_dats.c gcats1_marking_dats.c: gcats1_marking.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_marking.dats gcats1_marking_dats.o: gcats1_marking_dats.c $(ATSCC) $(CCFLAG) -c gcats1_marking_dats.c gcats1_collecting_dats.c: gcats1_collecting.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_collecting.dats gcats1_collecting_dats.o: gcats1_collecting_dats.c $(ATSCC) $(CCFLAG) -c gcats1_collecting_dats.c gcats1_autops_dats.c: gcats1_autops.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_autops.dats gcats1_autops_dats.o: gcats1_autops_dats.c $(ATSCC) $(CCFLAG) -c gcats1_autops_dats.c gcats1_manops_dats.c: gcats1_manops.dats $(ATSCC) $(ATSCCFLAG) -cc gcats1_manops.dats gcats1_manops_dats.o: gcats1_manops_dats.c $(ATSCC) $(CCFLAG) -c gcats1_manops_dats.c ###### srclines:: wc -l *.?ats ###### clean:: rm -f *~ rm -f *_?ats.c *_?ats.o rm -f gcats1.hats cleanall:: clean; rm -f gc.o gc_mt.o ###### # # end of [Makefile] # ###### ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1.cats0000664000175000017500000005354212223166160021467 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // /* ****** ****** */ #ifndef __ATS_GC_CATS #define __ATS_GC_CATS /* ****** ****** */ #include "gcats1.hats" /* ****** ****** */ // #include #include #include // extern void free (void*) ; // see [stdlib.h] extern void *malloc (size_t) ; // see [stdlib.h] extern void *memset (void *src, int c, size_t n) ; // see [string.h] // #ifdef _ATS_MULTITHREAD #include #include #include #endif // #include "ats_basics.h" #include "ats_types.h" // /* ****** ****** */ #undef ATS_FREE #define ATS_FREE free #undef ATS_MALLOC #define ATS_MALLOC malloc #undef ATS_GC_MARKROOT #define ATS_GC_MARKROOT(ptr, sz) do { ; } while (0) /* ****** ****** */ static inline ats_int_type log2_floor (ats_int_type n) { int c = 0 ; while (n >>= 1) c += 1 ; return c; } static inline ats_int_type log2_ceil (ats_int_type n) { int c ; c = log2_floor (n) ; if (n > (1 << c)) c += 1 ; return c ; } /* ****** ****** */ typedef unsigned char byte ; /* ****** ****** */ typedef void *freeitmlst ; /* ****** ****** */ typedef uintptr_t ats_uintptr1_type ; typedef struct { ats_ptr_type atslab_ptr ; ats_int_type atslab_size ; } freeitmptrsz_t ; // ------------------------------------------------------ // // a variety of locks // // ------------------------------------------------------ // #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_gc_main_lock ; #endif static inline ats_void_type gc_main_lock_acquire () { #ifdef _ATS_MULTITHREAD // fprintf (stderr, "gc_main_lock_acquire ()\n") ; pthread_mutex_lock (&the_gc_main_lock) ; #endif return ; } static inline ats_void_type gc_main_lock_release () { #ifdef _ATS_MULTITHREAD // fprintf (stderr, "gc_main_lock_release ()\n") ; pthread_mutex_unlock (&the_gc_main_lock) ; #endif return ; } // #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_globalentrylst_lock ; #endif static inline ats_void_type the_globalentrylst_lock_acquire () { #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_globalentrylst_lock) ; #endif return ; } static inline ats_void_type the_globalentrylst_lock_release () { #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_globalentrylst_lock) ; #endif return ; } // #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_manmemlst_lock ; #endif static inline ats_void_type the_manmemlst_lock_acquire () { #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_manmemlst_lock) ; #endif return ; } static inline ats_void_type the_manmemlst_lock_release () { #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_manmemlst_lock) ; #endif return ; } // #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_threadinfolst_lock ; #endif static inline ats_void_type the_threadinfolst_lock_acquire () { #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_threadinfolst_lock) ; #endif // end of [ifdef _ATS_MULTITHREAD] return ; } static inline ats_void_type the_threadinfolst_lock_release () { #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_threadinfolst_lock) ; #endif // end of [ifdef _ATS_MULTITHREAD] return ; } // #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_sweeplst_lock_array[FREEITMLST_ARRAYSIZE] ; #endif static inline ats_void_type the_sweeplst_lock_acquire_one (ats_int_type i) { #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_sweeplst_lock_array[i]) ; #endif return ; } static inline ats_void_type the_sweeplst_lock_release_one (ats_int_type i) { #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_sweeplst_lock_array[i]) ; #endif return ; } static inline ats_void_type the_sweeplst_lock_acquire_all () { #ifdef _ATS_MULTITHREAD int i ; for (i = 0; i < FREEITMLST_ARRAYSIZE; i += 1) { pthread_mutex_lock (&the_sweeplst_lock_array[i]) ; } #endif return ; } // static inline ats_void_type the_sweeplst_lock_release_all () { #ifdef _ATS_MULTITHREAD int i ; for (i = FREEITMLST_ARRAYSIZE - 1; i >= 0; i -= 1) { pthread_mutex_unlock (&the_sweeplst_lock_array[i]) ; } #endif return ; } // static inline ats_void_type the_sweeplst_lock_acquire_rest (ats_int_type i0) { #ifdef _ATS_MULTITHREAD int i ; for (i = 0; i < i0 ; i += 1) { pthread_mutex_lock (&the_sweeplst_lock_array[i]) ; } // skipping [i0] for (i = i0 + 1; i < FREEITMLST_ARRAYSIZE ; i += 1) { pthread_mutex_lock (&the_sweeplst_lock_array[i]) ; } #endif return ; } static inline ats_void_type the_sweeplst_lock_release_rest (ats_int_type i0) { #ifdef _ATS_MULTITHREAD int i ; for (i = FREEITMLST_ARRAYSIZE - 1; i > i0 ; i -= 1) { pthread_mutex_unlock (&the_sweeplst_lock_array[i]) ; } // skipping [i0] for (i = i0 - 1; i >= 0 ; i -= 1) { pthread_mutex_unlock (&the_sweeplst_lock_array[i]) ; } #endif return ; } // ------------------------------------------------------ // // freeitmlst // // ------------------------------------------------------ static inline ats_ptr_type freeitmlst2ptr (ats_ptr_type x) { return x ; } // static inline ats_bool_type freeitmlst_is_nil (ats_ptr_type itms) { return (itms ? ats_false_bool : ats_true_bool) ; } static inline ats_bool_type freeitmlst_is_cons (ats_ptr_type itms) { return (itms ? ats_true_bool : ats_false_bool) ; } static inline ats_ptr_type freeitmlst_cons (ats_ptr_type itm, ats_ptr_type itms) { *(freeitmlst*)itm = itms ; return itm ; } static inline ats_ptr_type freeitmlst_tail_get (ats_ptr_type itms) { return *((freeitmlst*)itms) ; } // extern freeitmlst the_freeitmlst_chunk_data ; static inline ats_void_type freeitmlst_chunk_data_free (ats_ptr_type _data) { free (_data) ; return ; } /* end of [freeitmlst_chunk_data_free] */ static inline ats_void_type freeitmlst_chunk_data_recycle (ats_ptr_type _data) { *((freeitmlst*)_data) = the_freeitmlst_chunk_data; the_freeitmlst_chunk_data = _data ; return ; } /* end of [freeitmlst_chunk_data_recycle] */ // #ifdef _ATS_MULTITHREAD extern __thread freeitmlst *the_freeitmlst_array ; #else /* single thread */ extern freeitmlst the_freeitmlst_array[FREEITMLST_ARRAYSIZE] ; #endif // static inline ats_ptr_type the_freeitmlst_array_get (ats_int_type i) { return the_freeitmlst_array[i] ; } static inline ats_void_type the_freeitmlst_array_set (ats_int_type i, ats_ptr_type itms) { the_freeitmlst_array[i] = itms ; return ; } static inline ats_void_type the_freeitmlst_array_clear_one (ats_int_type i) { the_freeitmlst_array[i] = (freeitmlst)0 ; return ; } static inline ats_void_type the_freeitmlst_array_insert_at (ats_ptr_type itm, ats_int_type i) { *(freeitmlst*)itm = the_freeitmlst_array[i] ; the_freeitmlst_array[i] = (freeitmlst)itm ; return ; } // ------------------------------------------------------ // // chunk operations // // ------------------------------------------------------ typedef struct chunk_struct { int itemwsz ; // word size of each free item: must be positive! // if [itemwsz_log = -1], then the chunk is large int itemwsz_log ; // itemwsz_log = log2 (itemwsz) if itemwsz_log >= 0 int itemtot ; // the total number of free items int markcnt ; // the count of marked free items #ifdef _ATS_MULTITHREAD // the count of freeitms taken from this chunk that are being used by // other threads. // [freecnt != 0] indicates that the chunk currently supplies freeitms // to other threads, and thus cannot be put into the sweeplst array. int freecnt ; #endif struct chunk_struct *sweep_next ; // next swept chunk freeitmlst data ; // pointer to the data freeitmlst data_nonalign ; // pointer to the truncated beginning byte markbits[0] ; // bits for marking } chunk ; typedef chunk *chunklst ; /* ****** ****** */ static inline ats_ptr_type chunklst2ptr (ats_ptr_type x) { return x ; } // static inline ats_bool_type chunklst_is_nil (ats_ptr_type chks) { return (chks ? ats_false_bool : ats_true_bool) ; } static inline ats_bool_type chunklst_is_cons (ats_ptr_type chks) { return (chks ? ats_true_bool : ats_false_bool) ; } static inline ats_void_type chunk_header_free (ats_ptr_type chks) { free (chks) ; return ; } // static inline ats_int_type chunklst_itembsz_get (ats_ptr_type chks) { return (((chunklst)chks)->itemwsz) << NBYTE_PER_WORD_LOG ; } static inline ats_int_type chunklst_itemwsz_get (ats_ptr_type chks) { return ((chunklst)chks)->itemwsz ; } static inline ats_int_type chunklst_itemwsz_log_get (ats_ptr_type chks) { return ((chunklst)chks)->itemwsz_log ; } static inline ats_int_type chunklst_itemtot_get (ats_ptr_type chks) { return ((chunklst)chks)->itemtot ; } static inline ats_int_type chunklst_markcnt_get (ats_ptr_type chks) { return ((chunklst)chks)->markcnt ; } // #ifdef _ATS_MULTITHREAD static inline ats_int_type chunklst_freecnt_get (ats_ptr_type chks) { return ((chunklst)chks)->freecnt ; } static inline ats_void_type chunklst_freecnt_inc (ats_ptr_type chks) { ((chunklst)chks)->freecnt += 1; return ; } #endif /* end of [ifdef _ATS_MULTITHREAD] */ // static inline ats_ptr_type chunklst_data_get (ats_ptr_type chks) { return ((chunklst)chks)->data ; } static inline ats_ptr_type chunklst_data_nonalign_get (ats_ptr_type chks) { return ((chunklst)chks)->data_nonalign ; } // static inline ats_ptr_type chunklst_markbits_get (ats_ptr_type chks) { return ((chunklst)chks)->markbits ; } static inline ats_ptr_type chunklst_sweep_next_get (ats_ptr_type chks) { return ((chunklst)chks)->sweep_next ; } // static inline ats_void_type chunklst_markcnt_dec (ats_ptr_type chks) { ((chunklst)chks)->markcnt -= 1 ; return ; } static inline ats_void_type chunklst_markcnt_inc (ats_ptr_type chks) { ((chunklst)chks)->markcnt += 1 ; return ; } // extern int the_chunk_count ; extern int the_chunk_count_limit ; static inline ats_int_type the_chunk_count_get () { return the_chunk_count ; } // static inline ats_void_type the_chunk_count_dec_by (ats_int_type n) { the_chunk_count -= n; return ; } /* end of [the_chunk_count_dec_by] */ static inline ats_void_type the_chunk_count_inc_by (ats_int_type n) { the_chunk_count += n; return ; } /* end of [the_chunk_count_inc_by] */ // static inline ats_bool_type the_chunk_count_limit_is_reached () { return (the_chunk_count >= the_chunk_count_limit) ? ats_true_bool : ats_false_bool ; } /* the_chunk_count_limit_is_reached */ static inline ats_bool_type the_chunk_count_limit_is_not_reached () { return (the_chunk_count >= the_chunk_count_limit) ? ats_false_bool : ats_true_bool ; } /* the_chunk_count_limit_is_not_reached */ static inline ats_bool_type the_chunk_count_limit_is_reached_within (ats_int_type n) { return (the_chunk_count + n > the_chunk_count_limit) ? ats_true_bool : ats_false_bool ; } /* the_chunk_count_limit_is_reached_within */ /* ****** ****** */ static inline ats_void_type gc_markbits_clear_chunk (ats_ptr_type chks) { int itemtot ; // total number of items int nmarkbit ; // number of bytes for mark bits itemtot = ((chunklst)chks)->itemtot ; nmarkbit = (itemtot + NBIT_PER_BYTE_MASK) >> NBIT_PER_BYTE_LOG ; memset (((chunklst)chks)->markbits, 0, nmarkbit) ; ((chunklst)chks)->markcnt = 0 ; #ifdef _ATS_MULTITHREAD ((chunklst)chks)->freecnt = 0 ; #endif return ; } /* gc_markbits_clear_chunk */ /* ****** ****** */ /* #define MARK_GET_mac(x, i) \ (((x)[(i) / NBIT_PER_BYTE] >> ((i) % NBIT_PER_BYTE)) & 0x1) */ #define MARK_GET_mac(x, i) \ (((x)[(i) >> NBIT_PER_BYTE_LOG] >> ((i) & NBIT_PER_BYTE_MASK)) & 0x1) static inline ats_bool_type MARK_GET (ats_ptr_type x, ats_int_type i) { return MARK_GET_mac((byte*)x, i) ; } /* #define MARK_SET_mac(x, i) \ do { \ (x)[(i) / NBIT_PER_BYTE] |= (1 << ((i) % NBIT_PER_BYTE)) ; \ } while (0) */ #define MARK_SET_mac(x, i) \ do { \ (x)[(i) >> NBIT_PER_BYTE_LOG] |= (1 << ((i) & NBIT_PER_BYTE_MASK)) ; \ } while (0) static inline ats_void_type MARK_SET (ats_ptr_type x, ats_int_type i) { MARK_SET_mac((byte*)x, i) ; return ; } /* #define MARK_CLEAR_mac(x, i) \ do { \ (x)[(i) / NBIT_PER_BYTE] &= ~(1 << ((i) % NBIT_PER_BYTE)) ; \ } while (0) */ #define MARK_CLEAR_mac(x, i) \ do { \ (x)[(i) >> NBIT_PER_BYTE_LOG] &= ~(1 << ((i) & NBIT_PER_BYTE_MASK)) ; \ } while (0) static inline ats_void_type MARK_CLEAR (ats_ptr_type x, ats_int_type i) { MARK_CLEAR_mac((byte*)x, i) ; return ; } /* ****** ****** */ #define PTR_TOPSEG_GET_mac(p) \ ((p) >> (PTR_BOTCHKSEG_SIZE + NBYTE_PER_WORD_LOG)) static inline ats_uintptr1_type PTR_TOPSEG_GET (ats_ptr_type p) { return PTR_TOPSEG_GET_mac((ats_uintptr1_type)p) ; } // #define PTR_BOTSEG_GET_mac(p) \ (((p) >> (PTR_CHKSEG_SIZE + NBYTE_PER_WORD_LOG)) & BOTSEG_TABLESIZE_MASK) static inline ats_int_type PTR_BOTSEG_GET (ats_ptr_type p) { return PTR_BOTSEG_GET_mac((ats_uintptr1_type)p) ; } // #define PTR_CHKSEG_GET_mac(p) \ (((p) >> NBYTE_PER_WORD_LOG) & CHUNK_WORDSIZE_MASK) static inline ats_int_type PTR_CHKSEG_GET (ats_ptr_type p) { return PTR_CHKSEG_GET_mac((ats_uintptr1_type)p) ; } // typedef struct botsegtbl_struct { #if (__WORDSIZE == 64) uintptr_t key ; struct botsegtbl_struct *hash_next ; #endif chunklst headers[BOTSEG_TABLESIZE] ; } botsegtbl ; typedef botsegtbl *botsegtbllst ; // static inline ats_bool_type botsegtbllst_is_nil (ats_ptr_type tbls) { return (tbls ? ats_false_bool : ats_true_bool) ; } static inline ats_bool_type botsegtbllst_is_cons (ats_ptr_type tbls) { return (tbls ? ats_true_bool : ats_false_bool) ; } // static inline ats_ptr_type botsegtbllst_get (ats_ptr_type tbls, ats_int_type i) { return ((botsegtbllst)tbls)->headers[i] ; } static inline ats_void_type botsegtbllst_set (ats_ptr_type tbls, ats_int_type i, ats_ptr_type chks) { ((botsegtbllst)tbls)->headers[i] = chks ; return ; } static inline ats_void_type botsegtbllst_clear (ats_ptr_type tbls, ats_int_type i) { ((botsegtbllst)tbls)->headers[i] = (chunklst)0 ; return ; } // #if (__WORDSIZE == 32) extern botsegtbllst the_topsegtbl[TOPSEG_TABLESIZE] ; static inline ats_ptr_type the_topsegtbl_get_32 (ats_uintptr1_type ofs) { return the_topsegtbl[ofs] ; } static inline ats_void_type the_topsegtbl_set_32 (ats_uintptr1_type ofs, ats_ptr_type tbls) { the_topsegtbl[ofs] = tbls ; return ; } #endif // end of [__WORDSIZE == 32] /* ****** ****** */ #if (__WORDSIZE == 64) extern botsegtbllst the_topsegtbl[TOPSEG_HASHTABLESIZE] ; static inline ats_ptr_type the_topsegtbl_get_64 (ats_uintptr1_type ofs) { botsegtbllst tbls = the_topsegtbl[ofs % TOPSEG_HASHTABLESIZE] ; while (tbls) { if (tbls->key == ofs) break ; tbls = tbls->hash_next ; } /* end of [while] */ return tbls ; } static inline ats_void_type the_topsegtbl_set_64 (ats_uintptr1_type ofs, ats_ptr_type tbls) { the_topsegtbl[ofs % TOPSEG_HASHTABLESIZE] = tbls ; return ; } static inline ats_ptr_type the_topsegtbl_getfst_64 (ats_uintptr1_type ofs) { return the_topsegtbl[ofs % TOPSEG_HASHTABLESIZE] ; } #endif // end of [__WORDSIZE == 64] /* ****** ****** */ // ------------------------------------------------------ // // manmemlst: for manually managed list of allocated memories // // ------------------------------------------------------ typedef struct manmem_struct { int itemwsz ; struct manmem_struct *prev ; struct manmem_struct *next ; byte data[] ; } manmem ; typedef manmem *manmemlst ; /* ****** ****** */ extern manmemlst the_manmemlst ; // static inline ats_ptr_type the_manmemlst_get (void) { return the_manmemlst ; } // static inline ats_bool_type manmemlst_is_nil (ats_ptr_type mms) { return (mms ? ats_false_bool : ats_true_bool) ; } static inline ats_bool_type manmemlst_is_cons (ats_ptr_type mms) { return (mms ? ats_true_bool : ats_false_bool) ; } // static inline ats_int_type manmemlst_itemwsz_get (ats_ptr_type mms) { return ((manmemlst)mms)->itemwsz ; } static inline ats_ptr_type manmemlst_prev_get (ats_ptr_type mms) { return ((manmemlst)mms)->prev ; } static inline ats_ptr_type manmemlst_next_get (ats_ptr_type mms) { return ((manmemlst)mms)->next ; } static inline ats_ptr_type manmemlst_data_get (ats_ptr_type mms) { return ((manmemlst)mms)->data ; } // ------------------------------------------------------ // // multithread // // ------------------------------------------------------ #ifdef _ATS_MULTITHREAD typedef struct threadinfo_struct { pthread_t pid ; ats_ptr_type stack_beg ; ats_ptr_type stack_end ; struct threadinfo_struct *prev ; struct threadinfo_struct *next ; freeitmlst *freeitmlst_array ; } threadinfo ; typedef threadinfo *threadinfolst ; #endif // ------------------------------------------------------ // // marking // // ------------------------------------------------------ typedef struct markstackpage_struct { struct markstackpage_struct *next ; struct markstackpage_struct *prev ; freeitmptrsz_t entries[MARKSTACK_PAGESIZE] ; } markstackpage ; typedef markstackpage *markstackpagelst ; // static inline ats_ptr_type markstackpagelst_nil () { return (markstackpagelst)0 ; } static inline ats_bool_type markstackpagelst_is_nil (ats_ptr_type msps) { return (msps ? ats_false_bool : ats_true_bool) ; } static inline ats_bool_type markstackpagelst_is_cons (ats_ptr_type msps) { return (msps ? ats_true_bool : ats_false_bool) ; } static inline ats_ptr_type markstackpagelst_next_get (ats_ptr_type msps) { return ((markstackpagelst)msps)->next ; } static inline ats_ptr_type markstackpagelst_prev_get (ats_ptr_type msps) { return ((markstackpagelst)msps)->prev ; } // static inline ats_void_type markstackpagelst_entry_get (ats_ptr_type msps, ats_int_type i, ats_ref_type p_r, ats_ref_type wsz_r) { freeitmptrsz_t *ents, *ents_i ; ents = ((markstackpagelst)msps)->entries ; ents_i = &(ents[i]) ; *(ats_ptr_type*)p_r = ents_i->atslab_ptr ; *(ats_int_type*)wsz_r = ents_i->atslab_size ; return ; } /* end of [markstackpage_entry_ptr_get] */ static inline ats_void_type markstackpagelst_entry_set (ats_ptr_type msps, ats_int_type i, ats_ptr_type p, ats_int_type wsz) { freeitmptrsz_t *ents, *ents_i ; ents = ((markstackpagelst)msps)->entries ; ents_i = &(ents[i]) ; ents_i->atslab_ptr = p ; ents_i->atslab_size= wsz ; return ; } /* end of [markstackpage_entry_ptr_set] */ // extern ats_int_type the_markstackposition ; extern ats_ptr_type the_markstackpagelst_cur ; static inline ats_int_type the_markstack_pop (ats_ref_type ptr_r, ats_ref_type wsz_r) { return markstack_pop ( &the_markstackpagelst_cur, &the_markstackposition, ptr_r, wsz_r ) ; } /* end of [the_markstack_pop] */ static inline ats_int_type the_markstack_push (ats_ptr_type ptr, ats_int_type wsz) { return markstack_push ( &the_markstackpagelst_cur, &the_markstackposition, ptr, wsz ) ; } /* end of [the_markstack_push] */ /* ****** ****** */ extern int the_markstatck_overflow ; static inline ats_int_type the_markstack_overflow_get () { return the_markstatck_overflow ; } static inline ats_void_type the_markstack_overflow_set () { the_markstatck_overflow = 1 ; return ; } static inline ats_void_type the_markstack_overflow_clear () { the_markstatck_overflow = 0 ; return ; } // ------------------------------------------------------ // // collecting // // ------------------------------------------------------ extern chunklst the_sweeplst_array[FREEITMLST_ARRAYSIZE] ; static inline ats_void_type fprint_the_sweeplst_array_all () { int i ; fprintf (stderr, "fprint_the_sweeplst_array_all:\n") ; fprintf (stderr, "&the_sweeplst_array = %p\n", &the_sweeplst_array) ; for (i = 0; i < FREEITMLST_ARRAYSIZE; i += 1) { fprintf (stderr, "the_sweeplst_array[%i] = %p\n", i, the_sweeplst_array[i]) ; } return ; } static inline ats_ptr_type the_sweeplst_array_get (ats_int_type i) { /* fprintf (stderr, "the_sweeplst_array_get: i = %i\n", i) ; fprintf (stderr, "the_sweeplst_array_get: chks = %p\n", the_sweeplst_array[i]) ; */ return the_sweeplst_array[i] ; } static inline ats_void_type the_sweeplst_array_set (ats_int_type i, ats_ptr_type chks) { // fprintf (stderr, "the_sweeplst_array_set: i = %i\n", i) ; // fprintf (stderr, "the_sweeplst_array_set: chks = %p\n", chks) ; the_sweeplst_array[i] = chks ; return ; } static inline ats_void_type the_sweeplst_array_clear_one (ats_int_type i) { // fprintf (stderr, "the_sweeplst_array_clear_one: i = %i\n", i) ; the_sweeplst_array[i] = (chunklst)0 ; return ; } static inline ats_void_type the_sweeplst_array_insert_at (ats_ptr_type chks, ats_int_type i) { // fprintf (stderr, "the_sweeplst_array_insert_at: chks = %p\n", chks) ; // fprintf (stderr, "the_sweeplst_array_insert_at: i = %i\n", i) ; ((chunklst)chks)->sweep_next = the_sweeplst_array[i] ; the_sweeplst_array[i] = (chunklst)chks ; return ; } /* end of [the_sweeplst_array_insert] */ /* ****** ****** */ #endif /* __ATS_GC_CATS */ /* end of [gcats1.cats] */ ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/README0000664000175000017500000000202612223166160020300 0ustar hwxihwxi# # # some history on garbage collection in ATS # # Rick Lavoie (coldfury AT cs DOT bu DOT edu) implemented the first garbage collector (GC) for ATS in the summer of 2006. Later, he added into this GC some support for threads. Largely following Rick's work, Hongwei Xi (hwxi AT cs DOT bu DOT edu) implemented a GC for ATS in the summer of 2007. In this implementation, some of the code was written in ATS, but overall ATS did not seem to be ready for a complex task as such. Hongwei had the experience of identifying and then fixing many subtle and inscrutable bugs in this GC but was still unable to stop some mysterious crashes caused by this GC. In June 2008, Hongwei initiated another implementation of GC for ATS. He followed Rick's design closely and wrote a large portion of code in ATS. This GC was coded and tested and then put into practical use in just a period of two weeks (June 20 - July 4). This fast development yields some strong evidence in support of making use of ATS in systems programming. ###### end of [README] ##### ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_freeitmlst.dats0000664000175000017500000000657312223166160023730 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_freeitmlst_" (* ****** ****** *) implement freeitmlst_length (itms) = let fun loop {i,j:nat} (itms: freeitmlst i, j: int j): int (i+j) = if freeitmlst_is_nil itms then j else begin loop (freeitmlst_tail_get itms, j+1) end in loop (itms, 0) end // end of [freeitmlst_length] (* ****** ****** *) implement the_freeitmlst_array_clear_all () = let #define N FREEITMLST_ARRAYSIZE fun loop {i:nat | i <= N} .. (i: int i): void = if i < N then begin the_freeitmlst_array_clear_one (i); loop (i+1) end in loop (0) end // end of [the_freeitmlst_array_clear_all] (* ****** ****** *) fun freeitmlst_mark_unset (itms: freeitmlst0): void = begin if freeitmlst_is_cons (itms) then let var ofs: int = 0; val ptr = freeitmlst2ptr (itms) val chks = gc_ptr_is_valid (ptr, ofs); val chks = ( if chunklst_is_cons chks then chks else begin prerr "freeitmlst_mark_unset: illegal pointer: ptr = "; prerr ptr; prerr_newline (); exit {chunklst1} (1) end ) : chunklst1 val markbits = chunklst_markbits_get (chks) val () = // could this really happen? if MARK_GET (markbits, ofs) > 0 then begin // this could happen only if data is mistreated as a pointer!!! MARK_CLEAR (markbits, ofs); chunklst_markcnt_dec (chks) end in freeitmlst_mark_unset (freeitmlst_tail_get itms) end end // end of [freeitmlst_mark_unset] // implement the_freeitmlst_array_mark_unset () = let #define N FREEITMLST_ARRAYSIZE fun loop {i:nat | i <= N} .. (i: int i): void = if i < N then begin freeitmlst_mark_unset (the_freeitmlst_array_get i); loop (i+1) end // end of [if] in loop (0) end // end of [the_freeitmlst_array_mark_unset] (* ****** ****** *) (* end of [gcats1_freeitmlst.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_autops.dats0000664000175000017500000002735312223166160023064 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_autops_" (* ****** ****** *) #define MALLOC_WORDSIZE_MAX (1 << 30) // temporarily implement gc_aut_malloc_bsz (bsz) = let val wsz = (bsz + NBYTE_PER_WORD_MASK) >> NBYTE_PER_WORD_LOG in gc_aut_malloc_wsz (wsz) end // end of [gc_aut_malloc_wsz] extern fun log2_ceil (n: int): Nat = "log2_ceil" implement gc_aut_malloc_wsz (wsz) = let (* val () = begin prerr "gc_aut_malloc_wsz: wsz = "; prerr wsz; prerr_newline () end // end of [val] *) val itemwsz_log = begin if wsz > MAX_CHUNK_BLOCK_WORDSIZE then ~1 else log2_ceil (wsz) end : Int in case+ 0 of | _ when itemwsz_log >= 0 => let val () = assert // redundant at run-time (itemwsz_log <= MAX_CHUNK_BLOCK_WORDSIZE_LOG) val itms = the_freeitmlst_array_get (itemwsz_log) val itms = ( if freeitmlst_is_nil itms then gc_freeitmlst_generate (itemwsz_log) else itms ) : freeitmlst1 val ptr = freeitmlst2ptr itms #if ATS_GC_RUNTIME_CHECK // checking that [ptr] is valid for [malloc] var ofs: int = 0 val chks = gc_ptr_is_valid (ptr, ofs) val () = assert_errmsg (chunklst_is_cons chks, "gc_malloc_wsz: [chks] is nil: ") val itemwsz = chunklst_itemwsz_get (chks) val markbits = chunklst_markbits_get (chks) val mb = MARK_GET (markbits, ofs) val () = assert_errmsg (mb = 0, "gc_malloc_wsz: [mb = 0] failed: ") val () = MARK_SET (markbits, ofs) val () = chunklst_markcnt_inc (chks) #endif val itms1 = freeitmlst_tail_get itms val () = the_freeitmlst_array_set (itemwsz_log, itms1) (* extern fun prerr_self_pid (): void = "prerr_self_pid" val () = begin prerr "gc_aut_malloc_wsz: pid = "; prerr_self_pid (); prerr_newline () end *) (* val () = begin prerr "gc_aut_malloc_wsz: return: ptr = "; prerr ptr; prerr_newline () end *) in ptr // return value end // end of [_ when ...] | _ => let // [itemwsz_log = -1] #define itemwsz wsz // [itemwsz] is [wsz] val () = // [itemwsz] is too large if itemwsz > MALLOC_WORDSIZE_MAX then let val () = begin prerr "[gc_aut_malloc_wsz]: argument is too large!"; prerr_newline () end in exit (1) end // end of [if] val nchunk = (itemwsz + CHUNK_WORDSIZE_MASK) >> CHUNK_WORDSIZE_LOG val (pf_gc_main | ()) = gc_main_lock_acquire () val is_reached_within = begin the_chunk_count_limit_is_reached_within (pf_gc_main | nchunk) end val () = // do garbage collection if needed if is_reached_within then let val (pf_globals | ()) = the_globalentrylst_lock_acquire () val (pf_manmemlst | ()) = the_manmemlst_lock_acquire () val (pf_threads | ()) = the_threadinfolst_lock_acquire () val (pf_sweeplst_all | ()) = the_sweeplst_lock_acquire_all () val () = gc_collect ( pf_gc_main, pf_globals, pf_manmemlst, pf_threads, pf_sweeplst_all | (*none*) ) // end of [gc_collect] val () = the_sweeplst_lock_release_all (pf_sweeplst_all | (*none*)) val () = the_threadinfolst_lock_release (pf_threads | (*none*)) val () = the_manmemlst_lock_release (pf_manmemlst | (*none*)) val () = the_globalentrylst_lock_release (pf_globals | (*none*)) in // empty end // end of [if] val chks = chunklst_create (pf_gc_main | ~1(*itemwsz_log*), itemwsz) val () = gc_main_lock_release (pf_gc_main | (*none*)) val itms = chunklst_data_get (chks) val ptr = freeitmlst2ptr itms (* val () = begin prerr "gc_aut_malloc_wsz: return: ptr = "; prerr ptr; prerr_newline () end *) in ptr // return value end // end of [_] end // end of [gc_aut_malloc_wsz] (* ****** ****** *) extern fun gc_aut_calloc_bsz (n(*all*): int, bsz(*each*): int): ptr = "gc_aut_calloc_bsz" // end of [gc_aut_calloc_bsz] %{^ static inline ats_void_type gc_aut_calloc_bsz_memset_bsz (ats_ptr_type p, ats_int_type c, ats_int_type bsz) { memset (p, c, bsz) ; return ; } %} implement gc_aut_calloc_bsz (n, bsz) = let (* val () = begin prerr "gc_aut_calloc_bsz: n = "; prerr n; prerr_newline () end val () = begin prerr "gc_aut_calloc_bsz: bsz = "; prerr bsz; prerr_newline () end *) val nbsz = n * bsz val ptr = gc_aut_malloc_bsz (nbsz) val () = _memset_bsz (ptr, 0, nbsz) where { extern fun _memset_bsz (p: ptr, c: int, sz: int): void = "gc_aut_calloc_bsz_memset_bsz" } // end of [where] (* val () = begin prerr "gc_aut_calloc_bsz: return: itms = "; prerr ptr; prerr_newline () end *) in ptr // return value end // end of [gc_aut_calloc_bsz] (* ****** ****** *) // [gc_aut_free] is supported by the availability of linear datatypes. fn gc_aut_free_chunk (chks: chunklst1, ptr: ptr): void = let (* val () = begin prerr "gc_aut_free_chunk: chks = ?"; prerr_newline () end *) val itemwsz_log = chunklst_itemwsz_log_get (chks) (* val () = begin prerr "gc_aut_free_chunk: itemwsz_log = "; prerr itemwsz_log; prerr_newline () end *) in if itemwsz_log >= 0 then let #if ATS_GC_RUNTIME_CHECK // checking that [ptr] is valid for [free] val ofs_chkseg = PTR_CHKSEG_GET (ptr) val itemwsz = 1 << itemwsz_log val markbits = chunklst_markbits_get (chks) val () = assert_errmsg ( ofs_chkseg mod itemwsz = 0 , "gc_aut_free_chunk: [ofs_chkseg mod itemwsz = 0] failed: " ) // end of [val] val ofs = ofs_chkseg >> itemwsz_log val mb = MARK_GET (markbits, ofs) val () = if mb <> 1 then begin prerr "gc_aut_free_chunk: ptr = "; prerr ptr; prerr_newline (); prerr "gc_aut_free_chunk: itemwsz = "; prerr itemwsz; prerr_newline () end val () = assert_errmsg (mb = 1, "gc_aut_free_chunk: [mb = 1] failed: ") val () = MARK_CLEAR (markbits, ofs) val () = chunklst_markcnt_dec (chks) #endif val () = the_freeitmlst_array_insert_at (ptr, itemwsz_log) in // empty end else let // large item val itemtot = chunklst_itemtot_get (chks) in if (itemtot = 1) then let val (pf_main_lock | ()) = gc_main_lock_acquire () val () = chunklst_destroy (pf_main_lock | chks) // the chunk contains no other items val () = gc_main_lock_release (pf_main_lock | (*none*)) in // empty end else begin // no leak is caused here as GC can reclaim the freeitm later // this can happen only if [MAX_CHUNK_BLOCK_WORDSIZE < CHUNK_WORDSIZE] end // end of [it] end // end of [if] end // end of [gc_aut_free_chunk] // implement gc_aut_free (ptr) = let (* val () = begin prerr "gc_aut_free: ptr = "; prerr ptr; prerr_newline () end *) fn err_botsegtbl (ptr: ptr): void = begin prerr "GC: Fatal Error: [gc_aut_free] failed"; prerr ": invalid pointer (botsegtbl is nil): "; prerr ptr; prerr_newline (); exit {void} (1) end fn err_chunk (ptr: ptr): void = begin prerr "GC: Fatal Error: [gc_aut_free] failed"; prerr ": invalid pointer (chunk is nil): "; prerr ptr; prerr_newline (); exit {void} (1) end val (pf | ofs_topseg) = PTR_TOPSEG_GET (ptr) val tbls = the_topsegtbl_get (pf | ofs_topseg) in case+ 0 of | _ when botsegtbllst_is_cons tbls => let val ofs_botseg = PTR_BOTSEG_GET (ptr) val chks = botsegtbllst_get (tbls, ofs_botseg) in case+ 0 of | _ when chunklst_is_cons (chks) => gc_aut_free_chunk (chks, ptr) | _ => err_chunk (ptr) end // end of [_ when ...] | _ => err_botsegtbl (ptr) end // end of [gc_aut_free] // implement gc_aut_free (ptr) = () (* ****** ****** *) implement gc_aut_realloc_bsz (ptr, bsz) = let val wsz = (bsz + NBYTE_PER_WORD_MASK) >> NBYTE_PER_WORD_LOG in gc_aut_realloc_wsz (ptr, wsz) end // end of [gc_aut_relloc_wsz] // %{^ static inline ats_void_type gc_aut_realloc_wsz_memcpy_wsz (ats_ptr_type p_dest, ats_ptr_type p_src, ats_int_type wsz) { memcpy (p_dest, p_src, wsz << NBYTE_PER_WORD_LOG) ; return ; } %} // implement gc_aut_realloc_wsz (ptr, wsz_new) = let (* val () = begin prerr "gc_aut_realloc_wsz: ptr = "; prerr ptr; prerr_newline () end val () = begin prerr "gc_aut_realloc_wsz: wsz_new = "; prerr wsz_new; prerr_newline () end *) fn err (ptr: ptr): ptr = begin prerr "GC: Fatal Error: [gc_aut_free] failed"; prerr ": invalid pointer: "; prerr ptr; prerr_newline (); exit {ptr} (1) end val (pf | ofs_topseg) = PTR_TOPSEG_GET (ptr) val tbls = the_topsegtbl_get (pf | ofs_topseg) fn aux_main (chks: chunklst1, ptr: ptr, wsz_new: int) : ptr = let extern fun _memcpy_wsz (_dest: ptr, _src: ptr, wsz: int): void = "gc_aut_realloc_wsz_memcpy_wsz" val itemwsz = chunklst_itemwsz_get (chks) in case+ 0 of | _ when wsz_new > itemwsz => let (* val () = begin prerr "gc_aut_realloc_wsz: enlarging"; prerr_newline () end *) val ptr_new = gc_aut_malloc_wsz (wsz_new) val () = _memcpy_wsz (ptr_new, ptr, itemwsz) val () = gc_aut_free_chunk (chks, ptr) in ptr_new // return a new value end | _ when 2 * wsz_new <= itemwsz => let (* val () = begin prerr "gc_aut_realloc_wsz: shrinking"; prerr_newline () end *) val ptr_new = gc_aut_malloc_wsz (wsz_new) // note: [wsz_new <= itemwsz / 2 < wsz] val () = _memcpy_wsz (ptr_new, ptr, wsz_new) val () = gc_aut_free_chunk (chks, ptr) in ptr_new // return a new value end | _ => ptr // return the original value end // end of [aux_main] in // if ptr > null then ( case+ 0 of | _ when botsegtbllst_is_cons tbls => let val ofs_botseg = PTR_BOTSEG_GET (ptr) val chks = botsegtbllst_get (tbls, ofs_botseg) in case+ 0 of | _ when chunklst_is_cons (chks) => let val ptr_new = aux_main (chks, ptr, wsz_new) (* val () = begin prerr "gc_aut_realloc_wsz: return: ptr_new = "; prerr ptr_new ; prerr_newline () end *) in ptr_new end // end of [_ when ...] | _ => err (ptr) end | _ => err (ptr) ) else ( gc_aut_malloc_wsz (wsz_new) ) // end of [if] end // end of [gc_aut_realloc] (* ****** ****** *) (* end of [gcats1_autops.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_main.dats0000664000175000017500000000501212223166160022461 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) // mainly for the purpose of debugging (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) implement main (argc, argv) = let val () = gc_init () where { extern fun gc_init (): void = "gc_init" } // (* // val () = gc_markroot_bsz (null + 1024, 401) var ofs: int = 0 val _ = gc_ptr_is_valid (null + 1024 * 1024 * 1024, ofs) // *) // (* val ptr1 = gc_aut_malloc_bsz (1) val () = begin prerr "ptr1 = "; prerr ptr1; prerr_newline () end val ptr2 = gc_aut_malloc_bsz (2) val () = begin prerr "ptr2 = "; prerr ptr2; prerr_newline () end (* val () = gc_aut_free (ptr1) val () = gc_aut_free (ptr2) val _ = gc_aut_malloc_bsz (10) val _ = gc_aut_malloc_bsz (16) val _ = gc_aut_malloc_bsz (16) val _ = gc_aut_malloc_bsz (16) val _ = gc_aut_malloc_bsz (16) val _ = gc_aut_malloc_bsz (32) *) val () = gc_collect () where { extern fun gc_collect (): void = "gc_collect" } // *) in // empty end // end of [main] (* ****** ****** *) (* end of [gc_main.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_globalentry.dats0000664000175000017500000001442012223166160024062 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) // the code handles accumulation of global roots for GC (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_globalentry_" (* ****** ****** *) viewdef entrypage_v (l:addr) = array_v (freeitmptrsz (), GLOBALENTRYPAGESIZE, l) // this may be unnecessarily complicated: a linked list should just be fine. dataviewtype globalentrylst = // the slots with indexes in (u, GLOBALENTRYPAGESIZE) are all used | {u:int | ~1 <= u; u < GLOBALENTRYPAGESIZE} {l:addr} GLOBALENTRYLSTcons of (entrypage_v l | ptr l, int u, globalentrylst) | GLOBALENTRYLSTnil // end of [globalentrylst] // extern fun globalentry_insert {u,n:nat | u < GLOBALENTRYPAGESIZE} {l0,l:addr} ( pf_arr: !entrypage_v l0, pf: freeitm n @ l | p0: ptr l0, u: int u, p: ptr l, wsz: int n ) : void // end of [extern] = "globalentry_insert" extern fun globalentrylst_insert {n:nat} {l:addr} (pf: freeitm n @ l | ents: &globalentrylst, p: ptr l, wsz: int n): void = "globalentrylst_insert" extern fun globalentrylst_extend_insert {n:nat} {l:addr} (pf: freeitm n @ l | ents: &globalentrylst, p: ptr l, wsz: int n): void // implement globalentrylst_insert (pf | ents, p, wsz) = let extern prfun __leak {n:nat} {l:addr} (pf: freeitm n @ l): void in case+ 0 of | _ when wsz > 0 => begin case+ ents of | GLOBALENTRYLSTcons (!pf_arr | p_arr, !used, _) => let val u = !used in if u >= 0 then let val () = globalentry_insert (!pf_arr, pf | p_arr, u, p, wsz) in !used := u - 1; fold@ ents end else begin fold@ ents; globalentrylst_extend_insert (pf | ents, p, wsz) end // end of [if] end // end of [GLOBALENTRYLSTcons] | GLOBALENTRYLSTnil () => begin fold@ ents; globalentrylst_extend_insert (pf | ents, p, wsz) end // end of [GLOBALENTRYLSTnil] end // end of [_ when ...] | _ => begin // no pointer inside! let prval () = __leak (pf) in () end end end // end of [globalentrylst_insert] implement globalentrylst_extend_insert (pf | ents, p, wsz) = let (* val () = begin prerr "globalentrylst_extend_insert: p = "; prerr p; prerr_newline (); prerr "globalentrylst_extend_insert: wsz = "; prerr wsz; prerr_newline () end // end of [val] *) val (pf_arr | p_arr) = entrypage_alloc () where { extern fun entrypage_alloc (): [l:addr] (entrypage_v l | ptr l) = "entrypage_alloc" } val u = GLOBALENTRYPAGESIZE - 1 val () = globalentry_insert (pf_arr, pf | p_arr, u, p, wsz) in ents := GLOBALENTRYLSTcons (pf_arr | p_arr, u - 1, ents) end // end of [globalentrylst_extend_insert] (* ****** ****** *) extern fun gc_mark_entrypage {u:int | ~1 <= u; u < GLOBALENTRYPAGESIZE} {l:addr} (pf: !entrypage_v l | p0: ptr l, u(*used if higher*): int u): void = "gc_mark_entrypage" extern fun gc_mark_globalentrylst (ents: !globalentrylst): void = "gc_mark_globalentrylst" implement gc_mark_globalentrylst (ents) = begin case+ ents of | GLOBALENTRYLSTcons (!pf | p0, u, !ents1) => let val () = gc_mark_entrypage (!pf | p0, u) val () = gc_mark_globalentrylst (!ents1) in fold@ (ents) end // end of [GLOBALENTRYLSTcons] | GLOBALENTRYLSTnil () => begin fold@ (ents) end // end of [GLOBALENTRYLSTnil] end // end of [gc_mark_globalentrylst] (* ****** ****** *) %{$ ats_ptr_type entrypage_alloc () { void* p ; p = malloc (GLOBALENTRYPAGESIZE * sizeof(freeitmptrsz_t)) ; /* fprintf (stderr, "entrypage_alloc: p = %p\n", p) ; */ if (!p) { fprintf (stderr, "GC Fatal Error: [gc_globalentry.dats]") ; fprintf (stderr, ": [entrypage_alloc]: [malloc] failed.\n") ; exit (1) ; } // end of [if] return p ; } /* end of [entrypage_alloc] */ /* ****** ****** */ ats_void_type globalentry_insert (ats_ptr_type p0, ats_int_type u, ats_ptr_type p, ats_int_type wsz) { freeitmptrsz_t *p0_u ; p0_u = (freeitmptrsz_t*)p0 + u ; p0_u->atslab_ptr = p ; p0_u->atslab_size = wsz ; return ; } /* globalentry_insert */ /* ****** ****** */ extern ats_void_type gc_mark_ptr (ats_ptr_type) ; ats_void_type gc_mark_entrypage (ats_ptr_type p0, ats_int_type u/*used if higher*/) { int i, j ; freeitmptrsz_t *p0_i ; freeitmlst *p_j ; int wsz ; i = u + 1 ; p0_i = (freeitmptrsz_t*)p0 + i ; /* fprintf (stderr, "gc_mark_entrypage: enter\n") ; */ while (i < GLOBALENTRYPAGESIZE) { // termination: obvious p_j = (freeitmlst*)(p0_i->atslab_ptr) ; wsz = p0_i->atslab_size ; /* fprintf (stderr, "gc_mark_entrypage: p_j = %p(%i)\n", p_j, p_j) ; */ for (j = 0; j < wsz; j += 1, p_j += 1) { gc_mark_ptr (*p_j) ; } i += 1 ; p0_i += 1 ; } // end of [while] /* fprintf (stderr, "gc_mark_entrypage: leave\n") ; */ return ; } /* end of [gc_mark_entrypage] */ %} (* ****** ****** *) (* end of [gcats1_globalentrylst.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_marking.dats0000664000175000017500000002733212223166160023176 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) // the code handles the stack needed for marking (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_marking_" (* ****** ****** *) implement markstackpagelst_length (msps) = let fun aux {i,j:nat} (msps: markstackpagelst i, j: int j): int (i+j) = if markstackpagelst_is_nil msps then j else begin aux (markstackpagelst_next_get msps, j+1) end // end of [if] in aux (msps, 0) end // end of [markstackpagelst_length] (* ****** ****** *) implement markstack_pop (msps, pos, p_r, wsz_r) = let val i = pos - 1 in if i >= 0 then let val () = markstackpagelst_entry_get (msps, i, p_r, wsz_r) in pos := i; 0 // underflow status end else let val prev = markstackpagelst_prev_get (msps) in if markstackpagelst_is_cons (prev) then let val () = msps := prev val i = MARKSTACK_PAGESIZE - 1 val () = markstackpagelst_entry_get (msps, i, p_r, wsz_r) in pos := i; 0 // underflow status end else begin p_r := (null: ptr); wsz_r := (0: int); 1 // underflow status end // end of [if] end // end of [if] end // end of [markstack_pop] (* ****** ****** *) implement markstack_push (msps, pos, p, wsz) = let val i = pos in if i < MARKSTACK_PAGESIZE then let val () = markstackpagelst_entry_set (msps, i, p, wsz) val i = i + 1; val () = if i < MARKSTACK_PAGESIZE then (pos := i) else let val next = markstackpagelst_next_get (msps) in if markstackpagelst_is_cons (next) then begin msps := next; pos := 0 end else begin pos := MARKSTACK_PAGESIZE end // end of [if] end // end of [if] in 0 // overflow status end else begin 1 // overflow status end // end of [if] end // end of [markstack_push] (* ****** ****** *) extern fun gc_overflow_mark_chunk (chks: chunklst1): void = "gc_overflow_mark_chunk" extern fun gc_overflow_mark_botsegtbl (tbls: botsegtbllst1): void = "gc_overflow_mark_botsegtbl" implement gc_overflow_mark_botsegtbl (tbls) = loop (tbls, 0) where { #define N BOTSEG_TABLESIZE fun loop {i:nat | i <= N} .. (tbls: botsegtbllst1, i: int i): void = if i < BOTSEG_TABLESIZE then let val chks = botsegtbllst_get (tbls, i); val () = begin if chunklst_is_cons (chks) then gc_overflow_mark_chunk (chks) end // end of [val] in loop (tbls, i+1) end // end of [if] } // end of [gc_overflow_mark_botsegtbl] (* ****** ****** *) extern fun the_markstack_overflow_get (): int = "the_markstack_overflow_get" extern fun the_markstack_overflow_set (): void = "the_markstack_overflow_set" extern fun the_markstack_overflow_clear (): void = "the_markstack_overflow_clear" implement gc_mark_all () = let val () = gc_mark_the_globalentrylst () val () = gc_mark_the_manmemlst () #ifdef _ATS_MULTITHREAD val () = gc_mark_the_threadinfolst () #endif val () = the_markstack_overflow_clear () val () = gc_mark_the_stack () val overflow0 = the_markstack_overflow_get () // (* val () = if overflow0 > 0 then begin prerr "GC: [gc_mark_all]: mark stack overflow happened!\n" end // end of [if] // *) val () = loop (overflow0) where { fun loop (overflow: int): void = if (overflow > 0) then let val () = the_markstack_overflow_clear () val () = gc_overflow_mark_the_topsegtbl () val overflow = the_markstack_overflow_get () in loop (overflow) end // end of [if] } // end of [where] in overflow0 end // end of [gc_mark_all] (* ****** ****** *) local // [val] -> [var] extern val the_markstackpagecnt: int = "the_markstackpagecnt" // [val] -> [var] extern val the_markstackpagelst_fst: markstackpagelst0 = "the_markstackpagelst_fst" extern val the_markstackpagelst_cur: markstackpagelst0 = "the_markstackpagelst_cur" // [val] -> [var] extern val the_markstackposition: natLte(MARKSTACK_PAGESIZE) = "the_markstackposition" in // in of [local] implement the_markstackpagecnt = 0 implement the_markstackpagelst_fst = markstackpagelst_nil () implement the_markstackpagelst_cur = the_markstackpagelst_fst implement the_markstackposition = 0 end // end of [local] (* ****** ****** *) %{$ extern ats_ptr_type the_markstackpagelst_fst ; ats_void_type the_markstack_extend (ats_int_type n) { int i ; markstackpagelst p0, p ; p0 = the_markstackpagelst_fst ; if (the_markstackposition != 0) { fprintf ( stderr , "GC: Fatal Error: the_markstack_extend: the_markstackposition = %i.\n" , the_markstackposition ) ; exit (1) ; } // end of [if] for (i = 0; i < n; i += 1) { /* fprintf (stderr, "the_markstack_extend: i = %i\n", i) ; */ p = (markstackpagelst)malloc (sizeof(markstackpage)) ; if (!p) { fprintf ( stderr, "GC Fatal Error: [the_markstack_extend]: malloc failed!\n" ) ; exit (1) ; } // end of [if] if (p0 != NULL) p0->prev = p ; p->next = p0 ; p->prev = NULL ; p0 = p ; } // end of [while] if (n > 0) the_markstackpagecnt += n ; the_markstackpagelst_fst = the_markstackpagelst_cur = p0 ; /* if (the_markstackpagecnt != markstackpagelst_length (p0)) { fprintf ( stderr , "GC: Fatal Error: the_markstack_extend: the_markstackpagecnt = %i.\n" , the_markstackpagecnt ) ; exit (1) ; } // end of [if] */ return ; } /* end of [the_markstack_extend] */ /* ****** ****** */ extern ats_ptr_type gc_ptr_is_valid (ats_ptr_type, ats_ref_type) ; ats_void_type gc_mark_ptr (ats_ptr_type ptr) { chunklst chks ; int ofs ; int itemwsz ; byte *markbits ; int i ; freeitmlst *ptr_i ; freeitmlst ptr_cand ; int overflow ; /* fprintf (stderr, "gc_mark_ptr: first: ptr = %p(%i)\n", ptr, ptr) ; */ chks = (chunklst)gc_ptr_is_valid (ptr, &ofs) ; /* fprintf (stderr, "gc_mark_ptr: chks = %p\n", chks) ; */ if (!chks) return ; // [ptr] is invalid markbits = chks->markbits ; if (MARK_GET(markbits, ofs)) return ; // already marked MARK_SET(markbits, ofs) ; chks->markcnt += 1 ; itemwsz = chks->itemwsz ; while (ptr) { // ptr != NULL /* fprintf (stderr, "gc_mark_ptr: ptr = %p(%i)\n", ptr, ptr) ; fprintf (stderr, "gc_mark_ptr: itemwsz = %i\n", itemwsz); */ if (itemwsz > MARKSTACK_CUTOFF) { overflow = the_markstack_push ( (freeitmlst*)ptr + MARKSTACK_CUTOFF, itemwsz - MARKSTACK_CUTOFF ) ; if (overflow) the_markstack_overflow_set () ; itemwsz = MARKSTACK_CUTOFF ; } // end of [if] // push all the valid pointers onto the markstack except the last one ptr_i = (freeitmlst*)ptr ; for (i = 0; i < itemwsz - 1; i += 1, ptr_i += 1) { ptr_cand = *ptr_i ; /* fprintf (stderr, "gc_mark_ptr: ptr_i = %p(%i)\n", ptr_i, ptr_i) ; fprintf (stderr, "gc_mark_ptr: ptr_cand = %p(%i)\n", ptr_cand, ptr_cand) ; */ chks = (chunklst)gc_ptr_is_valid (ptr_cand, &ofs) ; if (!chks) continue ; // [ptr_cand] is invalid markbits = chks->markbits ; if (MARK_GET(markbits, ofs)) continue ; // already marked MARK_SET(markbits, ofs) ; chks->markcnt += 1 ; overflow = the_markstack_push (ptr_cand, chks->itemwsz) ; if (overflow) the_markstack_overflow_set () ; } // end of [for] ptr_cand = *ptr_i ; /* fprintf (stderr, "gc_mark_ptr: ptr_i = %p(%i)\n", ptr_i, ptr_i) ; fprintf (stderr, "gc_mark_ptr: ptr_cand = %p(%i)\n", ptr_cand, ptr_cand) ; */ chks = (chunklst)gc_ptr_is_valid (ptr_cand, &ofs) ; if (!chks) { // [ptr_cand] is invalid the_markstack_pop (&ptr, &itemwsz) ; continue ; } // end of [if] markbits = chks->markbits ; if (MARK_GET(markbits, ofs)) { // [ptr_cand] is marked the_markstack_pop (&ptr, &itemwsz) ; continue ; } MARK_SET(markbits, ofs) ; chks->markcnt += 1 ; ptr = ptr_cand ; itemwsz = chks->itemwsz ; } // end of [while] } /* end of [gc_mark_ptr] */ %} (* ****** ****** *) %{$ // [chks] must not be NULL! ats_void_type gc_overflow_mark_chunk (ats_ptr_type chks) { int i, j ; freeitmlst *pi, *pij ; int itemwsz, itemtot ; byte *markbits ; itemwsz = chunklst_itemwsz_get (chks) ; itemtot = chunklst_itemtot_get (chks) ; markbits = chunklst_markbits_get (chks) ; pi = (freeitmlst*)chunklst_data_get (chks) ; for (i = 0; i < itemtot; i += 1, pi += itemwsz) { if (MARK_GET(markbits, i)) { for (j = 0, pij = pi; j < itemwsz; j += 1, pij += 1) { gc_mark_ptr (pij) ; } // end of [for] } // end of [if] } // end of [for] } /* end of [gc_overflow_mark_chunk] */ /* ****** ****** */ #if (__WORDSIZE == 32) ats_void_type gc_overflow_mark_the_topsegtbl () { int i ; botsegtbllst tbls ; for (i = 0; i < TOPSEG_TABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; if (tbls) gc_overflow_mark_botsegtbl (tbls) ; } // end of [for] return ; } /* end of [gc_overflow_mark_the_topsegtbl] */ #endif // end of [__WORDSIZE == 32] #if (__WORDSIZE == 64) ats_void_type gc_overflow_mark_the_topsegtbl () { int i ; botsegtbllst tbls ; for (i = 0; i < TOPSEG_HASHTABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; while (tbls) { // terminating: obvious gc_overflow_mark_botsegtbl (tbls) ; tbls = tbls->hash_next ; } // end of [while] } // end of [for] return ; } /* end of [gc_overflow_mark_the_topsegtbl] */ #endif // end of [__WORDSIZE == 64] %} (* ****** ****** *) %{$ extern ats_ptr_type the_globalentrylst ; extern ats_void_type gc_mark_globalentrylst (ats_ptr_type ents) ; ats_void_type gc_mark_the_globalentrylst () { gc_mark_globalentrylst (the_globalentrylst) ; return ; } extern ats_ptr_type gc_stack_beg_get () ; ats_void_type gc_mark_the_stack () { intptr_t dir ; // make sure that [dir] is word-aligned! freeitmlst *_fr, *_to ; dir = gc_stack_dir_get () ; if (dir > 0) { _fr = gc_stack_beg_get () ; _to = (freeitmlst*)(&dir) - 1 ; } else { _to = gc_stack_beg_get () ; _fr = (freeitmlst*)(&dir) + 1 ; } // end of [if] /* fprintf (stderr, "gc_mark_the_stack: _fr = %p(%u)\n", _fr, _fr) ; fprintf (stderr, "gc_mark_the_stack: _to = %p(%u)\n", _to, _to) ; fprintf (stderr, "gc_mark_the_stack: _to - _fr = %i\n", _to - _fr) ; */ while (_fr <= _to) { gc_mark_ptr (*_fr) ; _fr += 1 ; // termination: obvious } // end of [while] return ; } /* end of [gc_mark_the_stack] */ %} (* ****** ****** *) (* end of [gcats1_marking.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_misc.dats0000664000175000017500000000700712223166160022476 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_misc_" (* ****** ****** *) %{^ static int the_stack_direction = 0 ; // // dir=1/-1 : upward/downward // static int gc_stack_dir_get_inner (int *some_ptr) { int some_int ; if (&some_int > some_ptr) return 1 ; else return -1 ; return 0 ; /* deadcode */ } static int gc_stack_dir_get_outer () { // static volatile void* get_inner = &gc_stack_dir_get_inner ; // int some_int ; if (!the_stack_direction) the_stack_direction = ((int(*)(int*))get_inner)(&some_int) ; /* fprintf (stderr, "the_stack_direction = %i\n", the_stack_direction) ; */ return the_stack_direction ; } ats_int_type gc_stack_dir_get () { return gc_stack_dir_get_outer () ; } /* ****** ****** */ #ifdef _ATS_MULTITHREAD static __thread ats_ptr_type the_stack_beg = (ats_ptr_type)0 ; #else /* single thread */ static ats_ptr_type the_stack_beg = (ats_ptr_type)0 ; #endif ats_void_type gc_stack_beg_set (ats_int_type dir) { long int pagesize, pagemask ; uintptr_t beg ; if (the_stack_beg) return ; // already set // pagesize must be a power of 2 pagesize = sysconf(_SC_PAGESIZE) ; // system configuration /* fprintf(stderr, "gc_stack_beg_set: dir = %i\n", dir) ; fprintf(stderr, "gc_stack_beg_set: pagesize = %li\n", pagesize) ; fprintf(stderr, "gc_stack_beg_set: &pagesize = %p\n", &pagesize) ; */ pagemask = ~(pagesize - 1) ; // 1...10...0 if (dir > 0) { beg = (uintptr_t)(&pagesize) ; beg &= pagemask ; } else { beg = (uintptr_t)(&pagesize) + pagesize ; beg &= pagemask ; beg -= sizeof(freeitmlst) ; } the_stack_beg = (ats_ptr_type)beg ; return ; } ats_ptr_type gc_stack_beg_get ( // there is no argument for this function ) { if (!the_stack_beg) { fprintf (stderr, "GC Fatal Error: [gc_stack_beg_get]") ; fprintf (stderr, ": [the_stack_beg] is not yet set.\n") ; exit (1) ; } return the_stack_beg ; } // end of [gc_stack_beg_get] %} // end of [%{^] (* ****** ****** *) (* end of [gcats1_misc.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_chunk.dats0000664000175000017500000003456312223166160022662 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) %{^ #include "config.h" // automatically generated by [configure] // [posix_memalign] is in [stdlib.h] extern int posix_memalign(void **memptr, size_t alignment, size_t size); // [memalign] is in [stdlib.h] or [malloc.h] extern void *memalign(size_t boundary, size_t size); static inline int gcats_memalign ( void **memptr , size_t alignment , size_t size ) { int err ; #if HAVE_POSIX_MEMALIGN // for [posix_memalign] // fprintf (stderr, "posix_memalign: bef\n") ; err = posix_memalign (memptr, alignment, size) ; // fprintf (stderr, "posix_memalign: aft\n") ; #elif HAVE_MEMALIGN // if [memalign] is avaiable void *ptr ; ptr = memalign(alignment, size) ; *memptr = ptr ; err = (ptr ? 0 : -1) ; #else // neither [posix_memalign] nor [memalign] is available void *ptr ; ptr = malloc (size + alignment - 1) ; *memptr = ptr ; err = (ptr ? 0 : -1) ; #endif /* fprintf (stderr, "gcats_memalign: size = %i\n", size); fprintf (stderr, "gcats_memalign: *memptr = %p(%i)\n", *memptr, *memptr); */ return err ; } /* end of [gcats_memalign] */ %} #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_chunk_" (* ****** ****** *) implement chunklst_sweep_length (chks) = let // fun aux {i,j:nat} ( chks: chunklst i, j: int j ) : int (i+j) = let val iscons = chunklst_is_cons (chks) in if iscons then aux (chunklst_sweep_next_get (chks), j+1) else j // end of [if] end // end of [aux] // in aux (chks, 0) end // end of [chunklst_sweep_length] (* ****** ****** *) #if (__WORDSIZE == 32) extern fun the_topsegtbl_get_32 {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i): botsegtbllst0 = "the_topsegtbl_get_32" extern fun the_topsegtbl_set_32 {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i, tbls: botsegtbllst1): void = "the_topsegtbl_set_32" implement the_topsegtbl_get (pf | ofs) = the_topsegtbl_get_32 (pf | ofs) implement the_topsegtbl_get_some (pf | ofs) = let val tbls = the_topsegtbl_get_32 (pf | ofs) in if botsegtbllst_is_nil tbls then let val tbls = botsegtbl_make_32 () val () = the_topsegtbl_set_32 (pf | ofs, tbls) in tbls // [tbls] is not null end else begin tbls // [tbls] is not null end // end of [if] end // end of [the_topsegtbl_get_some] #endif // end of [__WORDSIZE == 32] (* ****** ****** *) #if (__WORDSIZE == 64) extern fun the_topsegtbl_get_64 {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i): botsegtbllst0 = "the_topsegtbl_get_64" extern fun the_topsegtbl_set_64 {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i, tbls: botsegtbllst1): void = "the_topsegtbl_set_64" extern fun the_topsegtbl_getfst_64 {i:nat} (pf: PTR_TOPSEG_GET_p i | ofs: uintptr i): botsegtbllst0 = "the_topsegtbl_getfst_64" implement the_topsegtbl_get (pf | ofs) = the_topsegtbl_get_64 (pf | ofs) implement the_topsegtbl_get_some (pf | ofs) = let val tbls = the_topsegtbl_get_64 (pf | ofs) in if botsegtbllst_is_nil tbls then let (* ** HX (October 8, 2009): ** because the following line was missing, a bug was introduced; ** this bug was so myserious as it rarely manifested itself; there was ** basically no way to fix it by solely relying on a tool like GDB *) val tbls = the_topsegtbl_getfst_64 (pf | ofs) // this line was missing val tbls = botsegtbl_make_64 (pf | ofs, tbls) val () = the_topsegtbl_set_64 (pf | ofs, tbls) in tbls // [tbls] is not null end else begin tbls // [tbls] is not null end // end of [if] end // end of [the_topsegtbl_get_some] #endif // end of [__WORDSIZE == 64] (* ****** ****** *) extern fun chunklst_insert_into_table (chks: chunklst1): void = "chunklst_insert_into_table" extern fun chunklst_remove_from_table (chks: chunklst1): void = "chunklst_remove_from_table" implement chunklst_insert_into_table (chks) = let val _data = chunklst_data_get (chks) val _data = freeitmlst2ptr (_data) val (pf | ofs_topseg) = PTR_TOPSEG_GET (_data) val tbls = the_topsegtbl_get_some (pf | ofs_topseg) val ofs_botseg = PTR_BOTSEG_GET (_data) in botsegtbllst_set (tbls, ofs_botseg, chks) end // end of [chunklst_insert_into_table] implement chunklst_remove_from_table (chks) = let val _data = chunklst_data_get (chks) val _data = freeitmlst2ptr (_data) val (pf | ofs_topseg) = PTR_TOPSEG_GET (_data) val tbls = the_topsegtbl_get (pf | ofs_topseg) in if botsegtbllst_is_cons tbls then let val ofs_botseg = PTR_BOTSEG_GET (_data) in botsegtbllst_clear (tbls, ofs_botseg) end else begin prerr "GC: Fatal Error: [chunklst_remove_from_table]"; prerr ": the chunk to be removed is not in the table!"; prerr_newline (); exit {void} (1) end // end of [if] end // end of [chunklst_remove_from_table] (* ****** ****** *) implement chunklst_create_release (pf_main_lock | itemwsz_log, itemwsz) = let val chks = chunklst_create (pf_main_lock | itemwsz_log, itemwsz) val () = gc_main_lock_release (pf_main_lock | (*none*)) in chks end // end of [chunklst_create_release] (* ****** ****** *) extern fun freeitmlst_chunk_data_free (pf: !gc_main_lock_v | p: freeitmlst1): void = "freeitmlst_chunk_data_free" extern fun freeitmlst_chunk_data_recycle (pf: !gc_main_lock_v | p: freeitmlst1): void = "freeitmlst_chunk_data_recycle" implement chunklst_destroy (pf_main_lock | chks) = let (* val ptr = chunklst2ptr (chks) val () = begin prerr "chunklst_destroy: chks = "; prerr ptr; prerr_newline () end *) val () = chunklst_remove_from_table (chks) val _data_nonalign = chunklst_data_nonalign_get (chks) val itemwsz = chunklst_itemwsz_get (chks) val () = chunk_header_free (chks) where { extern fun chunk_header_free (chks: chunklst1): void = "chunk_header_free" } // end of [where] val nchunk = (itemwsz + CHUNK_WORDSIZE_MASK) >> CHUNK_WORDSIZE_LOG val () = the_chunk_count_dec_by (pf_main_lock | nchunk) in case+ 0 of | _ when itemwsz > MAX_CHUNK_BLOCK_WORDSIZE => let (* val () = begin prerr "chunklst_destroy: itemwsz = "; prerr itemwsz; prerr_newline () end *) in freeitmlst_chunk_data_free (pf_main_lock | _data_nonalign) end // end of [_ when ...] | _ => begin freeitmlst_chunk_data_recycle (pf_main_lock | _data_nonalign) end // end of [_] end // end of [chunklst_destroy] (* ****** ****** *) extern fun gc_markbits_clear_chunk (chks: chunklst1): void = "gc_markbits_clear_chunk" extern fun gc_markbits_clear_botsegtbl (tbls: botsegtbllst1): void = "gc_markbits_clear_botsegtbl" implement gc_markbits_clear_botsegtbl (tbls) = let stadef N = BOTSEG_TABLESIZE fun loop {i:nat | i <= N} .. (tbls: botsegtbllst1, i: int i): void = if i < BOTSEG_TABLESIZE then let val chks = botsegtbllst_get (tbls, i); val () = begin if chunklst_is_cons (chks) then gc_markbits_clear_chunk (chks) end in loop (tbls, i+1) end // end of [if] in loop (tbls, 0) end // end of [gc_markbits_clear_botsegtbl] (* ****** ****** *) %{$ #if (__WORDSIZE == 32) ats_ptr_type botsegtbl_make_32 () { botsegtbllst tbls ; /* fprintf ( stderr, "botsegtbl_make_32: sizeof(botsegtbl) = %i\n", sizeof(botsegtbl) ) ; // end of [fprintf] */ tbls = (botsegtbllst)malloc(sizeof(botsegtbl)) ; if (!tbls) { fprintf (stderr, "Exit: [botsegtbl_make_32: malloc] failed\n") ; exit (1) ; } // end of [if] memset(tbls, 0, sizeof(botsegtbl)) ; /* fprintf (stderr, "botsegtbl_make_32: return: tbls = %p\n", tbls) ; */ return tbls ; } /* end of [botsegtbl_make_32] */ #endif // end of [__WORDSIZE == 32] /* ****** ****** */ #if (__WORDSIZE == 64) ats_ptr_type botsegtbl_make_64 (ats_uintptr1_type ofs, ats_ptr_type tbls0) { botsegtbllst tbls ; /* fprintf ( stderr, "botsegtbl_make_64: sizeof(botsegtbl) = %i\n", sizeof(botsegtbl) ) ; // end of [fprintf] */ tbls = (botsegtbllst)malloc(sizeof(botsegtbl)) ; if (!tbls) { fprintf (stderr, "Exit: [botsegtbl_make_64: malloc] failed\n") ; exit (1) ; } // end of [if] memset(tbls, 0, sizeof(botsegtbl)) ; tbls->key = ofs ; tbls->hash_next = (botsegtbllst)tbls0 ; /* fprintf (stderr, "botsegtbl_make_64: tbls = %p\n", tbls) ; */ return tbls ; } /* end of [botsegtbl_make_64] */ #endif // end of [__WORDSIZE == 64] %} (* ****** ****** *) %{$ ats_ptr_type gc_ptr_is_valid (ats_ptr_type ptr, ats_ref_type ofs_r) { uintptr_t ofs_topseg ; int ofs_botseg, ofs_chkseg, itemwsz ; botsegtbllst tbls = (botsegtbllst)0 ; chunklst chks = (chunklst)0 ; /* fprintf (stderr, "gc_ptr_is_valid: 1: ptr = %p\n", ptr) ; */ if (!ptr) return (chunklst)0 ; /* fprintf (stderr, "gc_ptr_is_valid: 2: ptr = %p\n", ptr) ; */ if ((uintptr_t)ptr & NBYTE_PER_WORD_MASK) return (chunklst)0 ; ofs_topseg = PTR_TOPSEG_GET (ptr) ; /* fprintf (stderr, "gc_ptr_is_valid: 3: ofs_topseg = %li\n", ofs_topseg) ; */ #if (__WORDSIZE == 32) tbls = the_topsegtbl_get_32 (ofs_topseg) ; #endif #if (__WORDSIZE == 64) tbls = the_topsegtbl_get_64 (ofs_topseg) ; #endif if (!tbls) return (chunklst)0 ; ofs_botseg = PTR_BOTSEG_GET (ptr) ; chks = botsegtbllst_get (tbls, ofs_botseg) ; /* fprintf (stderr, "gc_ptr_is_valid: 4: ofs_botseg = %li\n", ofs_botseg) ; */ if (!chks) return (chunklst)0 ; ofs_chkseg = PTR_CHKSEG_GET (ptr) ; itemwsz = chks->itemwsz ; /* fprintf (stderr, "gc_ptr_is_valid: 5: ofs_chkseg = %li\n", ofs_chkseg) ; fprintf (stderr, "gc_ptr_is_valid: 6: itemwsz = %i\n", itemwsz) ; */ /* ** for a large chunk (itemwsz_log = -1), ofs_chkseg == 0 */ if (ofs_chkseg % itemwsz) return (chunklst)0 ; *((int*)ofs_r) = (ofs_chkseg / itemwsz) ; return chks ; } /* end of [gc_ptr_is_valid] */ %} (* ****** ****** *) %{$ /* // itemwsz_log = log (itemwsz) if itemwsz_log >= 0 fun chunklst_create (itemwsz_log: int, itemwsz: int): chunklst1 */ ats_ptr_type chunklst_create (ats_int_type itemwsz_log, ats_int_type itemwsz) { int i, err ; int chunk_bsz, data_ofs ; int itemtot, nmarkbit ; freeitmlst data ; chunklst chks ; /* fprintf (stderr, "chunklst_create: itemwsz_log = %i\n", itemwsz_log) ; fprintf (stderr, "chunklst_create: itemwsz = %i\n", itemwsz) ; */ if (itemwsz_log >= 0) { itemtot = (CHUNK_WORDSIZE >> itemwsz_log) ; nmarkbit = (itemtot + NBIT_PER_BYTE_MASK) >> NBIT_PER_BYTE_LOG ; } else { itemtot = 1 ; nmarkbit = 1 ; } chks = (chunklst)malloc(sizeof(chunk) + nmarkbit) ; if (!chks) { fprintf ( stderr, "GC Fatal Error: [chunklst_create]: [malloc] failed.\n" ) ; // end of [fprintf] exit (1) ; } // end of [if] data = (freeitmlst)0 ; if (itemwsz <= MAX_CHUNK_BLOCK_WORDSIZE) { if (the_freeitmlst_chunk_data) { data = the_freeitmlst_chunk_data; the_freeitmlst_chunk_data = *(freeitmlst*)data ; } // end of [if] } // end of [if] /* fprintf (stderr, "chunklst_create: data = %p(%i)\n", data, data) ; */ if (!data) { if (itemwsz > CHUNK_WORDSIZE) chunk_bsz = itemwsz << NBYTE_PER_WORD_LOG ; else chunk_bsz = CHUNK_BYTESIZE ; /* fprintf (stderr, "gcats_memalign: size = %i\n", chunk_bsz) ; */ err = gcats_memalign (&data, CHUNK_BYTESIZE/*alignment*/, chunk_bsz/*size*/) ; /* fprintf (stderr, "gcats_memalign: err = %i\n", err) ; */ if (err) { fprintf (stderr, "GC: Fatal Error: [gcats_memalign] failed\n") ; exit (1) ; } // end of [if] } // end of [if] /* fprintf (stderr, "chunklst_create: data = %p(%i)\n", data, data) ; */ chks->itemwsz = itemwsz ; chks->itemwsz_log = itemwsz_log ; chks->itemtot = itemtot ; chks->markcnt = 0 ; // for fast threading! #ifdef _ATS_MULTITHREAD chks->freecnt = 0 ; // not in use yet #endif chks->sweep_next = (chunklst)0 ; data_ofs = (uintptr_t)data & (CHUNK_BYTESIZE - 1) ; if (data_ofs) { /* fprintf (stderr, "chunklst_create: data_ofs = %i\n", data_ofs) ; */ chks->data = (byte*)data - data_ofs + CHUNK_BYTESIZE ; } else { chks->data = data ; } chks->data_nonalign = data ; // [data] is *not* zeroed memset (chks->markbits, 0, nmarkbit) ; the_chunk_count_inc_by ((itemwsz + CHUNK_WORDSIZE_MASK) >> CHUNK_WORDSIZE_LOG) ; chunklst_insert_into_table (chks) ; /* fprintf (stderr, "chunklst_create: chks = %p(%i)\n", chks, chks) ; */ return chks ; } /* end of [chunklst_create] */ %} (* ****** ****** *) %{$ #if (__WORDSIZE == 32) ats_void_type gc_markbits_clear_the_topsegtbl () { int i ; botsegtbllst tbls ; for (i = 0; i < TOPSEG_TABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; if (tbls) gc_markbits_clear_botsegtbl (tbls) ; } // end of [for] return ; } /* end of [gc_markbits_clear_the_topsegtbl] */ #endif // end of [__WORDSIZE == 32] #if (__WORDSIZE == 64) ats_void_type gc_markbits_clear_the_topsegtbl () { int i ; botsegtbllst tbls ; for (i = 0; i < TOPSEG_HASHTABLESIZE; i += 1) { tbls = the_topsegtbl[i] ; while (tbls) { // terminating: obvious gc_markbits_clear_botsegtbl (tbls) ; tbls = tbls->hash_next ; } // end of [while] } // end of [for] return ; } /* end of [gc_markbits_clear_the_topsegtbl] */ #endif // end of [__WORDSIZE == 64] %} (* ****** ****** *) (* end of [gcats1_chunk.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/GCATS/gcats1_manops.dats0000664000175000017500000001253312223166160023040 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 2008 // (* ****** ****** *) %{^ #include // for [offsetof] extern void *malloc (size_t bsz) ; // see [stdlib.h] extern void *calloc (size_t n, size_t tsz) ; // see [stdlib.h] extern void free (void*) ; // see [stdlib.h] extern void *realloc (void *ptr, size_t bsz) ; // see [stdlib.h] %} (* ****** ****** *) #include "gcats1.hats" (* ****** ****** *) staload "gcats1.sats" (* ****** ****** *) #define ATSOPT_NAMESPACE "gcats1_manops_" (* ****** ****** *) implement manmemlst_length (mms) = let fun aux {i,j:nat} (mms: manmemlst i, j: int j): int (i+j) = if manmemlst_is_cons mms then aux (manmemlst_next_get mms, j+1) else j // end of [aux] in aux (mms, 0) end // end of [manmemlst_length] (* ****** ****** *) %{^ static inline ats_void_type gc_mark_the_manmemlst_aux (ats_ptr_type p0, ats_int_type sz) { int i ; freeitmlst *p_i ; p_i = (freeitmlst*)p0 ; for (i = 0; i < sz; i += 1, p_i += 1) gc_mark_ptr (*p_i) ; return ; } %} implement gc_mark_the_manmemlst () = let fun auxlst (mms: manmemlst0): void = if manmemlst_is_cons (mms) then let val () = aux ( manmemlst_data_get mms, manmemlst_itemwsz_get mms ) where { extern fun aux (itms: freeitmlst0, sz: int): void = "gc_mark_the_manmemlst_aux" } // end of [aux] in auxlst (manmemlst_next_get mms) end // end of [auxlst] in auxlst (the_manmemlst_get ()) end (* ****** ****** *) %{$ extern manmemlst the_manmemlst ; #ifdef _ATS_MULTITHREAD extern pthread_mutex_t the_manmemlst_lock ; #endif ats_ptr_type gc_man_malloc_bsz (ats_int_type bsz) { manmemlst mms ; mms = (manmemlst)malloc(sizeof(manmem) + bsz) ; if (!mms) { fprintf (stderr, "[gc_man_malloc_bsz]: [malloc] failed.\n") ; exit (1) ; } // end of [if] mms->itemwsz = bsz >> NBYTE_PER_WORD_LOG ; mms->prev = (manmemlst)0 ; #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_manmemlst_lock) ; #endif if (the_manmemlst) { the_manmemlst->prev = mms ; } mms->next = the_manmemlst ; the_manmemlst = mms ; #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_manmemlst_lock) ; #endif return (mms->data) ; } /* end of [gc_man_malloc_bsz] */ // ats_ptr_type gc_man_calloc_bsz (ats_int_type n, ats_int_type bsz) { int nbsz = n * bsz ; ats_ptr_type _data = gc_man_malloc_bsz (nbsz) ; memset (_data, 0, nbsz) ; return (_data) ; } /* end of [gc_man_calloc_bsz] */ // ats_void_type gc_man_free (ats_ptr_type ptr) { manmemlst mms, mms_prev, mms_next ; mms = (manmemlst)((byte*)ptr - offsetof(manmem, data)) ; mms_prev = mms->prev ; mms_next = mms->next ; #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_manmemlst_lock) ; #endif if (mms_next) { mms_next->prev = mms_prev ; } /* end of [if] */ if (mms_prev) { mms_prev->next = mms_next ; } else { the_manmemlst = mms_next ; } /* end of [if] */ #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_manmemlst_lock) ; #endif free (mms) ; return ; } /* end of [gc_man_free] */ // ats_ptr_type gc_man_realloc_bsz (ats_ptr_type ptr, ats_int_type bsz) { // manmemlst mms, mms_prev, mms_next ; // if (!ptr) return gc_man_malloc_bsz (bsz) ; // mms = (manmemlst)((byte*)ptr - offsetof(manmem, data)) ; mms_prev = mms->prev ; mms_next = mms->next ; mms = (manmemlst)realloc(mms, sizeof(manmem) + bsz) ; // if (!mms) { fprintf (stderr, "[gc_man_realloc_bsz]: [realloc] failed.\n") ; exit (1) ; } // end of [if] // mms->itemwsz = bsz >> NBYTE_PER_WORD_LOG ; // #ifdef _ATS_MULTITHREAD pthread_mutex_lock (&the_manmemlst_lock) ; #endif // if (mms_next) { mms_next->prev = mms ; } /* end of [if] */ // if (mms_prev) { mms_prev->next = mms ; } else { the_manmemlst = mms ; } /* end of [if] */ // #ifdef _ATS_MULTITHREAD pthread_mutex_unlock (&the_manmemlst_lock) ; #endif // return (mms->data) ; // } /* end of [gc_man_realloc_bsz] */ %} // end of [%{$] (* ****** ****** *) (* end of [gcats1_manops.dats] *) ats-lang-anairiats-0.2.11/ccomp/runtime/ats_config.h0000664000175000017500000000502312223166160021044 0ustar hwxihwxi/* ******************************************************************** */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************** */ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_CONFIG_H #define ATS_CONFIG_H /* ****** ****** */ // // HX: [config.h] is automatically generated in $(ATSHOME) // #include "config.h" /* ****** ****** */ #define NBIT_PER_BYTE 8 #define NBIT_PER_BYTE_LOG 3 /* ****** ****** */ #ifndef __WORDSIZE #define __WORDSIZE (SIZEOF_VOIDP*NBIT_PER_BYTE) #endif // end of [__WORDSIZE] /* ****** ****** */ #if (__WORDSIZE == 32) #define NBYTE_PER_WORD 4 #define NBYTE_PER_WORD_LOG 2 #if (NBYTE_PER_WORD != (1 << NBYTE_PER_WORD_LOG)) #error "NBYTE_PER_WORD != (1 << NBYTE_PER_WORD_LOG)\n" #endif #elif (__WORDSIZE == 64) #define NBYTE_PER_WORD 8 #define NBYTE_PER_WORD_LOG 3 #if (NBYTE_PER_WORD != (1 << NBYTE_PER_WORD_LOG)) #error "NBYTE_PER_WORD != (1 << NBYTE_PER_WORD_LOG)\n" #endif #else #error "[__WORDSIZE] is not supported.\n" #endif /* ****** ****** */ #define NBIT_PER_WORD (NBIT_PER_BYTE * NBYTE_PER_WORD) #define NBIT_PER_WORD_LOG (NBIT_PER_BYTE_LOG + NBYTE_PER_WORD_LOG) #if (NBIT_PER_WORD != (1 << NBIT_PER_WORD_LOG)) #error "NBIT_PER_WORD != (1 << NBIT_PER_WORD_LOG)\n" #endif /* ****** ****** */ #endif /* ATS_CONFIG_H */ /* end of [ats_config.h] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_prelude.c0000664000175000017500000001423612223166160021240 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #include "config.h" #include #ifdef _ATS_MULTITHREAD #include #endif // end of [_ATS_MULTITHREAD] /* ****** ****** */ #include "ats_types.h" #include "ats_basics.h" #include "ats_memory.h" /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern void ats_exit_errmsg (int err, char *msg) ; /* ****** ****** */ /* ** sizeof(ats_empty_type) == 0 */ ats_empty_type ats_empty_value ; /* ****** ****** */ // // HX: The following variables are used in basics.dats // int ats_stdin_view_lock = 1 ; int ats_stdout_view_lock = 1 ; int ats_stderr_view_lock = 1 ; /* ****** ****** */ /* ** the type of [the_ats_exception_stack] ** is given in the file [ats_exception.h] */ #ifdef _ATS_MULTITHREAD ATSthreadlocalstorage() // thread-local storage #endif // end of [_ATS_MULTITHREAD] void *the_ats_exception_stack = NULL ; /* ****** ****** */ // // HX: some common exceptions // ats_exn_type AssertionExceptionCon = { 10, "AssertionException" } ; ats_exn_ptr_type AssertionException = &AssertionExceptionCon ; ats_exn_type OverflowExceptionCon = { 20, "OverflowException" } ; ats_exn_ptr_type OverflowException = &OverflowExceptionCon ; ats_exn_type DivisionByZeroExceptionCon = { 30, "DivisionByZeroException" } ; ats_exn_ptr_type DivisionByZeroException = &DivisionByZeroExceptionCon ; /* ****** ****** */ ats_exn_type ListSubscriptExceptionCon = { 40, "ListSubscriptException" } ; ats_exn_ptr_type ListSubscriptException = &ListSubscriptExceptionCon ; ats_exn_ptr_type ListSubscriptException_make () { return ListSubscriptException ; } ats_bool_type isListSubscriptException (ats_exn_ptr_type exn) { return (ListSubscriptException->tag==exn->tag ? ats_true_bool : ats_false_bool) ; } ats_exn_type ArraySubscriptExceptionCon = { 50, "ArraySubscriptException" } ; ats_exn_ptr_type ArraySubscriptException = &ArraySubscriptExceptionCon ; ats_exn_ptr_type ArraySubscriptException_make () { return ArraySubscriptException ; } ats_bool_type isArraySubscriptException (ats_exn_ptr_type exn) { return (ArraySubscriptException->tag==exn->tag ? ats_true_bool : ats_false_bool) ; } /* ****** ****** */ // // HX: the numbers less than 1024 are all int ats_exception_con_tag = 1024 ; // reserved for special use /* ****** ****** */ /* ** function for handling uncaught exceptions */ extern void exit (int status) ; // declared in [stdlib.h] ats_void_type ats_uncaught_exception_handle ( const ats_exn_ptr_type exn ) { fprintf(stderr, "exit(ATS): uncaught exception: %s(%d)\n", exn->name, exn->tag ) ; exit(1) ; return ; // deadcode } // end of [ats_uncaught_exception_handle] /* ****** ****** */ /* ** functions for handling match failures */ void ats_caseof_failure_handle ( const char *loc // location of the failure ) { fprintf(stderr, "exit(ATS): %s: match failure.\n", loc) ; exit(1) ; return ; // deadcode } // end of [ats_caseof_failure_handle] void ats_funarg_match_failure_handle ( const char *loc // location of the failure ) { fprintf(stderr, "exit(ATS): %s: funarg match failure.\n", loc) ; exit(1) ; return ; // deadcode } // end of [ats_funarg_match_failure_handle] /* ****** ****** */ /* ** functions for memory allocation and deallocation */ #ifdef _ATS_NGC // no GC #include "ats_prelude_ngc.c" #elif _ATS_GCATS // special GC for ATS #include "ats_prelude_gcats.c" #elif _ATS_GCATS2 // special GC for ATS #include "ats_prelude_gcats2.c" #elif _ATS_GCBDW // Boehm-Demers-Weise conservative GC for C/C++ #include "ats_prelude_gcbdw.c" #else // _ATS_NGC is the default #include "ats_prelude_ngc.c" #endif // end of [ifdef] /* ****** ****** */ #ifdef _ATS_MULTITHREAD /* ****** ****** */ ats_int_type ats_pthread_create_detached ( ats_ptr_type f, ats_ptr_type env, ats_ref_type tid_r ) { int ret ; #ifdef _ATS_NGC pthread_attr_t attr; pthread_attr_init (&attr); pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) ; ret = pthread_create ((pthread_t*)tid_r, &attr, f, env) ; #elif _ATS_GCATS ret = gc_pthread_create (1/*detached*/, f, env, tid_r) ; /* fprintf (stderr, "exit(ATS): there is no support for pthreads under GCATS.\n") ; exit (1) ; */ #elif _ATS_GCBDW fprintf (stderr, "exit(ATS): there is no support for pthreads under GCBDW.\n") ; exit (1) ; #else // _ATS_NGC is the default pthread_attr_t attr; pthread_attr_init (&attr); pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) ; ret = pthread_create ((pthread_t*)tid_r, &attr, f, env) ; #endif // end of [#ifdef] return ret ; } // end of [ats_pthread_create_detached] /* ****** ****** */ ats_void_type ats_pthread_exit () { pthread_exit (NULL) ; // HX: this may cause memory leak if not used properly } // end of [ats_pthread_exit] /* ****** ****** */ #endif /* [ifdef _ATS_MULTITHREAD] */ /* ****** ****** */ /* end of [ats_prelude.c] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_exception.h0000664000175000017500000001077012223166160021602 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. ** */ /* ** ** Authors: ** Likai Liu (liulk AT cs DOT bu DOT edu) // Summer 2005 ** Rick Lavoie (coldfury AT cs DOT bu DOT edu) // Fall 2006 ** Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Summer 2007 ** */ #ifndef ATS_EXCEPTION_H #define ATS_EXCEPTION_H // the file should only be loaded once /* ****** ****** */ /* ** always loaded after the following two files: */ #include "ats_types.h" #include "ats_basics.h" /* ****** ****** */ #ifndef _XOPEN_SOURCE #define _XOPEN_SOURCE // for [sigsetjmp] in gcc-4.5 #endif // end of [_XOPEN_SOURCE] #include /* ****** ****** */ // // HX-2011-04-24: the function [alloca] is declared in extern void *alloca (size_t bsz) ; // [alloca.h] or [stdlib.h] /* ****** ****** */ /* ** function for handling uncaught exceptions */ extern ats_void_type ats_uncaught_exception_handle(const ats_exn_ptr_type exn) ; /* ****** ****** */ /* exception implementation */ typedef struct ats_exception_frame_struct { ats_exn_ptr_type exn ; struct ats_exception_frame_struct *prev ; sigjmp_buf env ; } ats_exception_frame_type ; /* ****** ****** */ #ifdef _ATS_MULTITHREAD extern ATSthreadlocalstorage() void *the_ats_exception_stack ; #else /* single thread */ extern void *the_ats_exception_stack ; #endif // end of [_ATS_MULTITHREAD] /* ****** ****** */ #define ATS_CURRENT_FRAME \ ((ats_exception_frame_type*)the_ats_exception_stack) #define ATS_CURRENT_FRAME_LVAL the_ats_exception_stack #define ATS_ENTER_EXCEPTION_FRAME() \ do { \ ats_exception_frame_type *frame = \ (ats_exception_frame_type*)alloca(sizeof(ats_exception_frame_type)); \ frame->prev = ATS_CURRENT_FRAME ; \ ATS_CURRENT_FRAME_LVAL = frame ; \ } while (0) // end of [do] #define ATS_LEAVE_EXCEPTION_FRAME() \ do { ATS_CURRENT_FRAME_LVAL = ATS_CURRENT_FRAME->prev; } while (0) #define ATS_RAISE(exn) \ do { \ if (ATS_CURRENT_FRAME == 0/*null*/) ats_uncaught_exception_handle(exn); \ ATS_CURRENT_FRAME->exn = exn ; \ siglongjmp(ATS_CURRENT_FRAME->env, 0) ; \ } while (0) // end of [do] /* ****** ****** */ /* ** WARNING: DO NOT USE THE FOLLOWING MACROS: */ #define ATS_TRYWITH_TRY(tmp_exn) \ do { \ ATS_ENTER_EXCEPTION_FRAME() ; \ tmp_exn = (ats_exn_ptr_type)(intptr_t)sigsetjmp(ATS_CURRENT_FRAME->env, 0) ; \ if ((intptr_t)tmp_exn == 0) { /* ... */ #define ATS_TRYWITH_WITH(tmp_exn) \ ATS_LEAVE_EXCEPTION_FRAME() ; \ } else { \ tmp_exn = ATS_CURRENT_FRAME->exn ; \ ATS_LEAVE_EXCEPTION_FRAME() ; /* exception handling */ #define ATS_TRYWITH_END() \ } \ } while(0) /* end of WARNING */ /* ****** ****** */ static inline ats_void_type ats_raise_exn // raising an exception (const ats_exn_ptr_type exn) { ATS_RAISE(exn) ; return ; } /* end of [ats_raise_exn] */ /* ****** ****** */ /* ** ** function for generating new exception constructor tag ** */ extern int ats_exception_con_tag ; static inline int ats_exception_con_tag_new () { ats_exception_con_tag += 1 ; return (ats_exception_con_tag) ; } /* end of [ats_exception_con_tag_new] */ /* functions for handling match failures */ extern ats_void_type ats_caseof_failure(void) ; extern ats_void_type ats_funarg_match_failure(void) ; /* ****** ****** */ #endif /* ATS_EXCEPTION_H */ /* end of [ats_exception.h] */ ats-lang-anairiats-0.2.11/ccomp/runtime/ats_bootstrap.c0000664000175000017500000000360112223166160021607 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi // Authoremail: hwxi AT cs DOT bu DOT edu // Time: June, 2010 // /* ****** ****** */ // // HX: this file is intended for // all C code needed for bootstrapping ATS // /* ****** ****** */ // // HX-2010-06-06: // // this function defintion is only // needed for bootstrapping; after // bootstrapping, [mainats_prelude] // is defined in the following file: // $ATSHOME/prelude/ats_main_prelude.dats] // void mainats_prelude () { return ; } // /* ****** ****** */ /* end of [ats_bootstrap.c] */ ats-lang-anairiats-0.2.11/libatsdoc/0000700000175000017500000000000012223166162015725 5ustar hwxihwxiats-lang-anairiats-0.2.11/libatsdoc/dynloadall.dats0000664000175000017500000000371412223166162020746 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, ATS Trustworthy Software, Inc. ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi ( hwxi AT cs DOT bu DOT edu ) *) (* ****** ****** *) // // HX: for initializing [libatsdoc] // (* ****** ****** *) dynload "libatsdoc/DATS/libatsdoc_error.dats" dynload "libatsdoc/DATS/libatsdoc_filename.dats" dynload "libatsdoc/DATS/libatsdoc_location.dats" dynload "libatsdoc/DATS/libatsdoc_reader.dats" dynload "libatsdoc/DATS/libatsdoc_lexbuf.dats" dynload "libatsdoc/DATS/libatsdoc_symbol.dats" dynload "libatsdoc/DATS/libatsdoc_symmap.dats" dynload "libatsdoc/DATS/libatsdoc_atext.dats" (* ****** ****** *) (* end of [dynloadall.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/CATS/0000700000175000017500000000000012223166162016457 5ustar hwxihwxiats-lang-anairiats-0.2.11/libatsdoc/CATS/libatsdoc_location.cats0000664000175000017500000000352612223166162023211 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (gmhwxi@gmail.com) // Start Time: July, 2011 // /* ****** ****** */ #ifndef LIBATSDOC_LOCATION_CATS #define LIBATSDOC_LOCATION_CATS /* ****** ****** */ typedef struct { ats_lint_type ntot ; ats_int_type nrow ; // line number ats_int_type ncol ; // line offset } libatsdoc_position_struct ; /* ****** ****** */ #endif // end of [LIBATSDOC_LOCATION_CATS] /* ****** ****** */ /* end of [libatsdoc_position.cats] */ ats-lang-anairiats-0.2.11/libatsdoc/CATS/libatsdoc_reader.cats0000664000175000017500000000350612223166162022641 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (gmhwxi@gmail.com) // Start Time: July, 2011 // /* ****** ****** */ #ifndef LIBATSDOC_READER_CATS #define LIBATSDOC_READER_CATS /* ****** ****** */ typedef struct { // ats_ptr_type getchar ; // () - int ats_ptr_type freeres ; // () -> void // } libatsdoc_reader_struct ; /* ****** ****** */ #endif // end of [LIBATSDOC_READER_CATS] /* ****** ****** */ /* end of [libatsdoc_reader.cats] */ ats-lang-anairiats-0.2.11/libatsdoc/CATS/libatsdoc_lexbuf.cats0000664000175000017500000000415012223166162022660 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (gmhwxi@gmail.com) // Start Time: July, 2011 // /* ****** ****** */ #ifndef LIBATSDOC_LEXBUF_CATS #define LIBATSDOC_LEXBUF_CATS /* ****** ****** */ #include "libats/CATS/linqueue_arr.cats" /* ****** ****** */ #include "libatsdoc/CATS/libatsdoc_reader.cats" /* ****** ****** */ typedef struct { // atslib_linqueue_arr_QUEUE cbuf ; // ats_lint_type base ; ats_int_type base_nrow ; // line number ats_int_type base_ncol ; // line offset // ats_int_type nspace ; // leading space // libatsdoc_reader_struct reader ; // for getchar // } libatsdoc_lexbuf_struct ; /* ****** ****** */ #endif // end of [LIBATSDOC_LEXBUF_CATS] /* ****** ****** */ /* end of [libatsdoc_lexbuf.cats] */ ats-lang-anairiats-0.2.11/libatsdoc/SATS/0000700000175000017500000000000012223166162016477 5ustar hwxihwxiats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_lexbuf.sats0000664000175000017500000000711612223166162022725 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: March, 2011 // (* ****** ****** *) %{# #include "libatsdoc/CATS/libatsdoc_lexbuf.cats" %} // end of [%{#] (* ****** ****** *) staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" typedef position = $LOC.position typedef location = $LOC.location (* ****** ****** *) absviewt@ype lexbuf_vt0ype = $extype "libatsdoc_lexbuf_struct" viewtypedef lexbuf = lexbuf_vt0ype (* ****** ****** *) fun lexbuf_initialize_filp {m:file_mode} {l:addr} ( pfmod: file_mode_lte (m, r) , pffil: FILE m @ l | r: &lexbuf? >> lexbuf, p: ptr l ) : void // end of [lexbuf_initialize_filp] fun lexbuf_initialize_getc ( buf: &lexbuf? >> lexbuf, getc: () - int ) : void // end of [lexbuf_initialize_getc] fun lexbuf_initialize_string ( buf: &lexbuf? >> lexbuf, inp: string ) : void // end of [lexbuf_initialize_string] (* ****** ****** *) fun lexbuf_uninitialize ( buf: &lexbuf >> lexbuf? ) : void // end of [lexbuf_uninitialize] (* ****** ****** *) fun lexbuf_get_base (buf: &lexbuf): lint fun lexbuf_get_position (buf: &lexbuf, res: &position? >> position): void // end of [lexbuf_get_position] fun lexbuf_get_nspace (buf: &lexbuf): int fun lexbuf_set_nspace (buf: &lexbuf, n: int): void (* ****** ****** *) fun lexbufpos_diff (buf: &lexbuf, pos: &position): uint // end of [lexbufpos_diff] fun lexbufpos_get_location (buf: &lexbuf, pos: &position): location // end of [lexbufpos_get_location] (* ****** ****** *) fun lexbuf_get_char (buf: &lexbuf, nchr: uint): int fun lexbufpos_get_char (buf: &lexbuf, position: &position): int (* ****** ****** *) fun lexbuf_incby_count (buf: &lexbuf, cnt: uint): void fun lexbuf_reset_position (buf: &lexbuf, pos: &position): void (* ****** ****** *) fun lexbuf_get_strptr0 (buf: &lexbuf, ln: uint): strptr0 fun lexbuf_get_strptr1 (buf: &lexbuf, ln: uint): strptr1 fun lexbufpos_get_strptr0 (buf: &lexbuf, pos: &position): strptr0 fun lexbufpos_get_strptr1 (buf: &lexbuf, pos: &position): strptr1 fun lexbuf_get_substrptr0 (buf: &lexbuf, st: uint, ln: uint): strptr0 fun lexbuf_get_substrptr1 (buf: &lexbuf, st: uint, ln: uint): strptr1 (* ****** ****** *) (* end of [libatsdoc_lexbuf.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_location.sats0000664000175000017500000000707312223166162023252 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) %{# #include "libatsdoc/CATS/libatsdoc_location.cats" %} // end of [%{#] (* ****** ****** *) staload FIL = "libatsdoc/SATS/libatsdoc_filename.sats" typedef filename = $FIL.filename (* ****** ****** *) abst@ype position_t0ype = $extype "libatsdoc_position_struct" typedef position = position_t0ype (* ****** ****** *) fun fprint_position (out: FILEref, pos: position): void overload fprint with fprint_position fun print_position (pos: position): void overload print with print_position (* ****** ****** *) fun position_get_ntot (pos: &position): lint // total char offset fun position_get_nrow (pos: &position): int // line number fun position_get_ncol (pos: &position): int // line offset (* ****** ****** *) fun position_init ( pos0: &position? >> position, ntot: lint, nrow: int, ncol: int ) : void // end of [position_init] fun position_copy ( pos0: &position? >> position, pos1: &position ) : void // end of [position_copy] (* ****** ****** *) fun position_incby_char (pos: &position, i: int): void fun position_decby_count (pos: &position, n: uint): void fun position_incby_count (pos: &position, n: uint): void (* ****** ****** *) abstype location_type typedef location = location_type (* ****** ****** *) (* ** HX: returning the begining char count *) fun location_get_bchar (loc: location): lint (* ****** ****** *) fun fprint_location (out: FILEref, loc: location): void overload fprint with fprint_location fun print_location (loc: location): void overload print with print_location fun prerr_location (loc: location): void overload prerr with prerr_location (* ****** ****** *) val location_dummy : location (* dummy location *) (* ****** ****** *) fun location_make_pos_pos ( pos1: position, pos2: position ) : location // end of [location_make_pos_pos] fun location_make_fil_pos_pos ( fil: filename, pos1: position, pos2: position ) : location // end of [location_make_fil_pos_pos] (* ****** ****** *) fun location_combine (loc1: location, loc2: location): location // end of [location_combine] (* ****** ****** *) (* end of [libatsdoc_location.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_symbol.sats0000664000175000017500000000451512223166162022745 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) abstype symbol_type // boxed typedef symbol = symbol_type typedef symbolist = List (symbol) typedef symbolopt = Option (symbol) (* ****** ****** *) val symbol_empty : symbol (* ****** ****** *) fun eq_symbol_symbol (x1: symbol, x2: symbol):<> bool overload = with eq_symbol_symbol fun neq_symbol_symbol (x1: symbol, x2: symbol):<> bool overload != with eq_symbol_symbol fun compare_symbol_symbol (x1: symbol, x2: symbol):<> Sgn overload compare with compare_symbol_symbol (* ****** ****** *) fun fprint_symbol (out: FILEref, x: symbol): void overload fprint with fprint_symbol fun print_symbol (x: symbol): void overload print with print_symbol fun prerr_symbol (x: symbol): void overload prerr with prerr_symbol (* ****** ****** *) typedef stamp = uint fun symbol_get_name (x: symbol):<> string fun symbol_get_stamp (x: symbol):<> stamp fun symbol_make_string (name: string): symbol (* ****** ****** *) (* end of [libatsdoc_symbol.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_reader.sats0000664000175000017500000000465312223166162022705 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) %{# #include "libatsdoc/CATS/libatsdoc_reader.cats" %} // end of [%{#] (* ****** ****** *) absviewt@ype reader_vt0ype = $extype "libatsdoc_reader_struct" viewtypedef reader = reader_vt0ype (* ****** ****** *) fun reader_initialize_filp {m:file_mode} {l:addr} ( pfmod: file_mode_lte (m, r) , pffil: FILE m @ l | r: &reader? >> reader, p: ptr l ) : void // end of [reader_initialize_filp] (* ****** ****** *) fun reader_initialize_getc ( r: &reader? >> reader, getc: () - int ) : void // end of [reader_initialize_getc] (* ****** ****** *) fun reader_initialize_string ( r: &reader? >> reader, inp: string ) : void // end of [reader_initialize_string] (* ****** ****** *) fun reader_uninitialize ( r: &reader >> reader? ) : void // end of [reader_uninitialize] (* ****** ****** *) fun reader_get_char (r: &reader): int // HX: EOF(-1) is returned at the end (* ****** ****** *) (* end of [libatsdoc_reader.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_symmap.sats0000664000175000017500000000405112223166162022741 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload SYM = "libatsdoc/SATS/libatsdoc_symbol.sats" typedef symbol = $SYM.symbol (* ****** ****** *) absviewtype symmap_vtype (itm:type) stadef symmap = symmap_vtype fun symmap_make_nil {itm:type} ():<> symmap (itm) fun symmap_free {itm:type} (map: symmap (itm)):<> void fun symmap_search {itm:type} (map: !symmap itm, k: symbol):<> Option_vt itm // end of [symmap_search] fun symmap_insert {itm:type} ( map: &symmap (itm), key: symbol, itm: itm ) :<> void // end of [symmap_insert] (* ****** ****** *) (* end of [libatsdoc_symmap.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_filename.sats0000664000175000017500000000733712223166162023225 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload SYM = "libatsdoc/SATS/libatsdoc_symbol.sats" (* ****** ****** *) abstype filename_type typedef filename = filename_type viewtypedef filenameopt_vt = Option_vt (filename) (* ****** ****** *) fun theDirSep_get (): char = "atsopt_filename_theDirSep_get" // end of [theDirSep_get] fun theCurDir_get (): string // current directory fun theParDir_get (): string // parent directory (* ****** ****** *) fun fprint_filename (out: FILEref, fil: filename): void overload fprint with fprint_filename fun print_filename (fil: filename): void overload print with print_filename fun prerr_filename (fil: filename): void overload prerr with prerr_filename fun fprint_filename_full (out: FILEref, fil: filename): void fun print_filename_full (fil: filename): void (* ****** ****** *) fun filename_get_base (fil: filename): string fun filename_get_full (fil: filename): $SYM.symbol (* ****** ****** *) fun filename_append ( dir: string, bas: string ) :<> strptr1 = "atsopt_filename_append" (* ****** ****** *) fun eq_filename_filename (x1: filename, x2: filename):<> bool fun compare_filename_filename (x1: filename, x2: filename):<> Sgn overload compare with compare_filename_filename (* ****** ****** *) val filename_dummy : filename (* dummy *) (* ****** ****** *) fun filename_is_relative (name: string): bool (* ****** ****** *) fun filename_get_current (): filename (* ****** ****** *) absview the_filenamelst_push_v fun the_filenamelst_pop (pf: the_filenamelst_push_v | (*none*)): void fun the_filenamelst_push (fil: filename): (the_filenamelst_push_v | void) // end of [the_filenamelst_push] fun the_filenamelst_push_check (fil: filename): (the_filenamelst_push_v | bool) // end of [the_filenamelst_push_check] fun fprint_the_filenamelst (out: FILEref): void (* ****** ****** *) typedef path = string absview the_pathlst_push_v fun the_pathlst_pop (pf: the_pathlst_push_v | (*none*)): void fun the_pathlst_push (p: path): (the_pathlst_push_v | void) fun the_prepathlst_push (p: path): void (* ****** ****** *) fun filename_make (basename: string, fullname: string) : filename // end of [filename_make] fun filenameopt_make_relative (name: string): filenameopt_vt (* ****** ****** *) (* end of [libatsdoc_filename.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_error.sats0000664000175000017500000000325112223166162022565 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) exception FatalErrorException (* ****** ****** *) fun abort {a:viewt@ype} (): a // raising FatalErrorException (* ****** ****** *) (* end of [libatsdoc_error.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/SATS/libatsdoc_atext.sats0000664000175000017500000000736312223166162022571 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: July, 2011 // (* ****** ****** *) staload F = "libc/SATS/fcntl.sats" stadef fildes_v = $F.fildes_v (* ****** ****** *) staload SYM = "libatsdoc/SATS/libatsdoc_symbol.sats" typedef symbol = $SYM.symbol (* ****** ****** *) abstype atext_type typedef atext = atext_type typedef atextlst = List (atext) typedef atextopt = Option (atext) viewtypedef atextlst_vt = List_vt (atext) viewtypedef atextopt_vt = Option_vt (atext) (* ****** ****** *) fun atext_nil (): atext fun atext_strcst (x: string): atext fun atext_strsub (x: string): atext fun atext_apptxt2 (x1: atext, x2: atext): atext fun atext_appstr2 (x1: string, x2: string): atext fun atext_apptxt3 (x1: atext, x2: atext, x3: atext): atext fun atext_appstr3 (x1: string, x2: string, x3: string): atext fun atext_concatxt (xs: atextlst): atext fun atext_concatxtsep (xs: atextlst, sep: atext): atext (* ****** ****** *) fun atext_newline ((*void*)): atext (* ****** ****** *) // // HX: s2s = string_of_strptr // fun atext_strptr (x: strptr1): atext // atext_strcst ((s2s)x) fun atext_strptr0 (x: strptr0): atext // atext_strptr or atext_nil // fun atext_strcstptr (x: strptr1): atext // atext_strcst ((s2s)x) fun atext_strsubptr (x: strptr1): atext // atext_strsub ((s2s)x) // (* ****** ****** *) fun atext_filepath (path: string): atext (* ****** ****** *) fun theAtextMap_search (s: symbol): atextopt_vt fun theAtextMap_insert (s: symbol, txt: atext): void fun theAtextMap_insert_str (s: string, txt: atext): void (* ****** ****** *) fun fprint_atext (out: FILEref, x: atext): void fun fprint_atextlst (out: FILEref, xs: atextlst): void fun fprint_atextlst_sep (out: FILEref, xs: atextlst, sep: atext): void (* ****** ****** *) fun fprint_strsub (out: FILEref, sub: string): void fun fprint_filsub (out: FILEref, path: string): void (* ****** ****** *) // // HX: [fd] is regular: no support for pipe // fun file2strptr {fd:int} ( pf: !fildes_v fd | fd: int fd ) : strptr0 = "libatsdoc_file2strptr" // end of [file2strptr] (* ****** ****** *) // // HX: this one is generic and should probably be moved into libats // fun{a:t@ype} tostring_fprint (prfx: string, fpr: (FILEref, a) -> void, x: a): strptr0 // end of [tostring_fprint] fun tostring_strsub (sub: string): strptr0 // HX: nullptr means error (* ****** ****** *) (* end of [libatsdoc_atext.sats] *) ats-lang-anairiats-0.2.11/libatsdoc/Makefile0000664000175000017500000000351012223166162017400 0ustar hwxihwxi####################################################################### # # # Applied Type System # # # # Hongwei Xi # # # ####################################################################### # # ATS/Postiats - Unleashing the Potential of Types! # Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software # All rights reserved # # ATS is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free # Software Foundation; either version 2.1, or (at your option) any later # version. # # ATS is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with ATS; see the file COPYING. If not, please write to the # Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # ###### # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Start Time: August, 2011 # ###### ATSHOMEQ="$(ATSHOME)" ###### GCC=gcc ###### all:: Makefile_out all:: ; make -f Makefile_out all:: cleanall ###### Makefile_out: Makefile_inp ; $(GCC) -I $(ATSHOMEQ) -E -P -o $@ -x c $< ###### RMF=rm -f ###### clean:: ; $(RMF) *~ clean:: ; $(RMF) *_?ats.o clean:: ; $(RMF) *_?ats.c cleanall:: clean cleanall:: ; $(RMF) Makefile_out cleanall:: ; $(RMF) libatsdoc.a ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/libatsdoc/DATS/0000700000175000017500000000000012223166162016460 5ustar hwxihwxiats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_symbol.dats0000664000175000017500000001411612223166162022705 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: March, 2011 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_symbol.sats" (* ****** ****** *) local %{^ typedef ats_ptr_type string ; typedef ats_ptr_type symbol ; %} // end of [%{^] staload "libats/SATS/hashtable_linprb.sats" staload _(*anon*) = "libats/DATS/hashtable_linprb.dats" // #define HASHTBLSZ 1024 // symintr encode decode // abstype string_t = $extype"string" extern castfn string_encode (x: string):<> string_t extern castfn string_decode (x: string_t):<> string overload encode with string_encode overload decode with string_decode // abstype symbol_t = $extype"symbol" extern castfn symbol_encode (x: symbol):<> symbol_t extern castfn symbol_decode (x: symbol_t):<> symbol overload encode with symbol_encode overload decode with symbol_decode // typedef key = string_t typedef itm = symbol_t typedef keyitm = (key, itm) // implement keyitem_nullify (x) = () where { extern prfun __assert (x: &keyitm? >> keyitm): void prval () = __assert (x) val () = x.0 := $UN.cast{key} (null) prval () = Opt_some (x) } (* end of [keyitem_nullify] *) // implement keyitem_isnot_null (x) = b where { extern prfun __assert1 (x: &Opt(keyitm) >> keyitm): void prval () = __assert1 (x) val b = $UN.cast{ptr} (x.0) <> null val [b:bool] b = bool1_of_bool (b) extern prfun __assert2 (x: &keyitm >> opt (keyitm, b)): void prval () = __assert2 (x) } (* end of [keyitem_isnot_null] *) // implement hash_key (x, _) = string_hash_33 (decode(x)) implement equal_key_key (x1, x2, _) = compare (decode(x1), decode(x2)) = 0 // end of [equal_key_key] val hash0 = $UN.cast{hash(key)} (null) val eqfn0 = $UN.cast{eqfn(key)} (null) val [l:addr] ptbl = hashtbl_make_hint (hash0, eqfn0, HASHTBLSZ) // val rtbl = HASHTBLref_make_ptr {key,itm} (ptbl) // in // in of [local] // val symbol_null = $UN.cast{symbol} (null) // HX: a hack! // fun symbol_insert ( k: string, i: symbol ) : void = () where { val k = encode (k); val i = encode (i) val (fptbl | ptbl) = HASHTBLref_takeout_ptr (rtbl) var res: symbol_t val _keyisused = hashtbl_insert (ptbl, k, i, res) prval () = fptbl (ptbl) prval () = opt_clear (res) (* val () = assertloc (not(_keyisused)) // HX: no replacement *) } // end of [symbol_insert] fun symbol_search (k: string): symbol = let val (fptbl | ptbl) = HASHTBLref_takeout_ptr (rtbl) var res: itm? val b = hashtbl_search (ptbl, encode(k), res) prval () = fptbl (ptbl) in if b then let prval () = opt_unsome {itm} (res) in decode (res) end else let prval () = opt_unnone {itm} (res) in symbol_null end // end of [if] end // end of [symbol_search] end // end of [local] (* ****** ****** *) assume symbol_type = '{ name= string, stamp= uint } // end of [symbol_type] (* ****** ****** *) implement symbol_get_name (x) = x.name implement symbol_get_stamp (x) = x.stamp (* ****** ****** *) local // var the_symbol_stamp: uint = 0u val (pf_the_symbol_stamp | ()) = vbox_make_view_ptr {uint} (view@ the_symbol_stamp | &the_symbol_stamp) // end of [val] fun stamp_getinc (): uint = n where { prval vbox(pf) = pf_the_symbol_stamp val n = the_symbol_stamp val () = the_symbol_stamp := n + 1u } // end of [stamp_getinc] // in // in of [local] implement symbol_make_string (name) = let // extern fun symbol_is_null (x: symbol):<> bool = "atspre_ptr_is_null" // val x = symbol_search (name) in // case+ 0 of | _ when symbol_is_null (x) => let val stamp = stamp_getinc () val x = '{ name= name, stamp= stamp } // end of [val] (* val () = println! ("symbol_make_string: name = ", name) val () = println! ("symbol_make_string: stamp = ", stamp) *) val () = symbol_insert (name, x) in x // newly created symbol end // end of [_ when ...] | _ => x // HX: symbol of the given name is found // end // [symbol_make_string] end // end of [local] (* ****** ****** *) implement symbol_empty = x where { val x = symbol_make_string "" // // HX-2011-03-20: // make sure that this is the first created symbol // val () = assertloc (x.stamp = 0u) } // end of [symbol_empty] (* ****** ****** *) implement eq_symbol_symbol (x1, x2) = x1.stamp = x2.stamp implement neq_symbol_symbol (x1, x2) = x1.stamp != x2.stamp (* ****** ****** *) implement compare_symbol_symbol (x1, x2) = compare (x1.stamp, x2.stamp) (* ****** ****** *) implement fprint_symbol (out, x) = fprint_string (out, x.name) // end of [fprint_symbol] implement print_symbol (x) = fprint_symbol (stdout_ref, x) implement prerr_symbol (x) = fprint_symbol (stderr_ref, x) (* ****** ****** *) (* end of [libatsdoc_symbol.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_error.dats0000664000175000017500000000350012223166162022524 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_error.sats" (* ****** ****** *) implement abort () = let (* val _ = segfault () where { extern fun segfault (): int = "libatsdoc_error_segfault" } // end of [val] *) in $raise FatalErrorException () end // end of [abort] (* ****** ****** *) (* end of [libatsdoc_error.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_symmap.dats0000664000175000017500000000536312223166162022712 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: April, 2011 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libats/SATS/linmap_avltree.sats" staload _(*anon*) = "libats/DATS/linmap_avltree.dats" (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_symmap.sats" (* ****** ****** *) // typedef key = uint // assume symmap_vtype (itm:type) = map (key, itm) (* ****** ****** *) // val cmp0 = $UN.cast{cmp(key)} (null) // implement compare_key_key (x1, x2, _) = compare_uint_uint (x1, x2) // (* ****** ****** *) implement symmap_make_nil () = linmap_make_nil<> () implement symmap_free {itm} (map) = linmap_free (map) (* ****** ****** *) implement symmap_search {itm} (map, sym) = let val k = $SYM.symbol_get_stamp (sym) var res: itm? val found = linmap_search (map, k, cmp0, res) in if found then let prval () = opt_unsome {itm} (res) in Some_vt (res) end else let prval () = opt_unnone {itm} (res) in None_vt () end (* end of [if] *) end // end of [symmap_search] (* ****** ****** *) implement symmap_insert {itm} (map, sym, i) = { val k = $SYM.symbol_get_stamp (sym) var res: itm val _exist = linmap_insert (map, k, i, cmp0, res) prval () = opt_clear (res) } // end of [symmap_insert] (* ****** ****** *) (* end of [libatsdoc_symmap.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_location.dats0000664000175000017500000001564012223166162023213 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload FIL = "libatsdoc/SATS/libatsdoc_filename.sats" typedef filename = $FIL.filename (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_location.sats" (* ****** ****** *) macdef neof (i) = (,(i) != EOF) (* ****** ****** *) assume position_t0ype = $extype_struct "libatsdoc_position_struct" of { ntot= lint, nrow= int, ncol= int } // end of [position_t0ype] (* ****** ****** *) implement fprint_position (out, pos) = () where { val ntot = pos.ntot val nrow = pos.nrow val ncol = pos.ncol val () = fprintf ( out, "%li(line=%i, offs=%i)", @(ntot+1L, nrow+1, ncol+1) ) (* end of [val] *) } // end of [fprint_position] implement print_position (pos) = fprint_position (stdout_ref, pos) (* ****** ****** *) implement position_get_ntot (pos) = pos.ntot implement position_get_nrow (pos) = pos.nrow implement position_get_ncol (pos) = pos.ncol (* ****** ****** *) implement position_init ( pos0, ntot, nrow, ncol ) = () where { val () = pos0.ntot := ntot val () = pos0.nrow := nrow val () = pos0.ncol := ncol } // end of [position_init] implement position_copy ( pos0, pos1 ) = () where { val () = pos0.ntot := pos1.ntot val () = pos0.nrow := pos1.nrow val () = pos0.ncol := pos1.ncol } // end of [position_copy] (* ****** ****** *) implement position_incby_char (pos, i) = if neof(i) then let // #define c2i int_of_char // val () = pos.ntot := pos.ntot + 1L // end of [val] val () = if i = (c2i)'\n' then let val () = pos.nrow := pos.nrow + 1 val () = pos.ncol := 0 in // nothing end else let val () = pos.ncol := pos.ncol + 1 in // nothing end // end of [if] in // nothing end // end of [position_incby_char] (* ****** ****** *) implement position_decby_count (pos, n) = () where { // #define u2i int_of_uint #define u2l lint_of_uint // val () = pos.ntot := pos.ntot - (u2l)n val () = pos.ncol := pos.ncol - (u2i)n } // end of [position_decby_count] implement position_incby_count (pos, n) = () where { // #define u2i int_of_uint #define u2l lint_of_uint // val () = pos.ntot := pos.ntot + (u2l)n val () = pos.ncol := pos.ncol + (u2i)n } // end of [position_incby_count] (* ****** ****** *) assume location_type = '{ filename= filename // file name , beg_ntot= lint // beginning char position , beg_nrow= int , beg_ncol= int , end_ntot= lint // finishing char position , end_nrow= int , end_ncol= int } // end of [location] (* ****** ****** *) implement location_get_bchar (loc) = loc.beg_ntot (* ****** ****** *) implement fprint_location (out, loc) = () where { val () = $FIL.fprint_filename (out, loc.filename) val () = fprint_string (out, ": ") val () = fprint_lint (out, loc.beg_ntot+1L) val () = fprint_string (out, "(line=") val () = fprint_int (out, loc.beg_nrow+1) val () = fprint_string (out, ", offs=") val () = fprint_int (out, loc.beg_ncol+1) val () = fprint_string (out, ") -- ") val () = fprint_lint (out, loc.end_ntot+1L) val () = fprint_string (out, "(line=") val () = fprint_int (out, loc.end_nrow+1) val () = fprint_string (out, ", offs=") val () = fprint_int (out, loc.end_ncol+1) val () = fprint_string (out, ")") } // end of [fprint_location] implement print_location (loc) = fprint_location (stdout_ref, loc) implement prerr_location (loc) = fprint_location (stderr_ref, loc) (* ****** ****** *) implement location_dummy = '{ filename= $FIL.filename_dummy , beg_ntot= ~1L , beg_nrow= ~1 , beg_ncol= ~1 , end_ntot= ~1L , end_nrow= ~1 , end_ncol= ~1 } // end of [location_dummy] (* ****** ****** *) implement location_make_pos_pos (pos1, pos2) = let val fil = $FIL.filename_get_current () in location_make_fil_pos_pos (fil, pos1, pos2) end // end of [location_make_pos_pos] (* ****** ****** *) implement location_make_fil_pos_pos (fil, pos1, pos2) = '{ filename= fil , beg_ntot= pos1.ntot , beg_nrow= pos1.nrow , beg_ncol= pos1.ncol , end_ntot= pos2.ntot , end_nrow= pos2.nrow , end_ncol= pos2.ncol } // end of [location_make_pos_pos] (* ****** ****** *) local fun location_is_none .<>. (loc: location):<> bool = (loc.beg_ntot < 0L) // end of [location_is_none] fun location_combine_main .<>. ( loc1: location, loc2: location ) :<> location = let // var beg_ntot: lint var beg_nrow: int and beg_ncol: int var end_ntot: lint var end_nrow: int and end_ncol: int // val () = if loc1.beg_ntot <= loc2.beg_ntot then begin beg_nrow := loc1.beg_nrow; beg_ncol := loc1.beg_ncol; beg_ntot := loc1.beg_ntot; end else begin beg_nrow := loc2.beg_nrow; beg_ncol := loc2.beg_ncol; beg_ntot := loc2.beg_ntot; end // end of [if] (* end of [val] *) // val () = if loc1.end_ntot >= loc2.end_ntot then begin end_nrow := loc1.end_nrow; end_ncol := loc1.end_ncol; end_ntot := loc1.end_ntot; end else begin end_nrow := loc2.end_nrow; end_ncol := loc2.end_ncol; end_ntot := loc2.end_ntot; end // end of [if] (* end of [val] *) // in '{ filename = loc1.filename , beg_ntot= beg_ntot , beg_nrow= beg_nrow , beg_ncol= beg_ncol , end_ntot= end_ntot , end_nrow= end_nrow , end_ncol= end_ncol } end // end of [location_combine_main] in // in of [local] implement location_combine (loc1, loc2) = case+ 0 of | _ when location_is_none loc1 => loc2 | _ when location_is_none loc2 => loc1 | _ => location_combine_main (loc1, loc2) // end of [location_combine] end // end of [local] (* ****** ****** *) (* end of [libatsdoc_location.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_filename.dats0000664000175000017500000003500612223166162023161 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload SYM = "libatsdoc/SATS/libatsdoc_symbol.sats" typedef symbol= $SYM.symbol overload = with $SYM.eq_symbol_symbol (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_filename.sats" (* ****** ****** *) local #include "prelude/params_system.hats" #if SYSTEM_IS_UNIX_LIKE #then // val theDirSep: char = '/' val theCurDir: string = "./" val theParDir: string = "../" // #endif in // in of [local] implement theDirSep_get () = theDirSep implement theCurDir_get () = theCurDir implement theParDir_get () = theParDir end // end of [local] (* ****** ****** *) assume filename_type = '{ filename_name= string, filename_full= symbol } // end of [filename] (* ****** ****** *) implement fprint_filename (out, fil) = fprint_string (out, fil.filename_name) // end of [fprint_filename] implement print_filename (fil) = fprint_filename (stdout_ref, fil) implement prerr_filename (fil) = fprint_filename (stderr_ref, fil) (* ****** ****** *) implement fprint_filename_full (out, fil) = let val name = $SYM.symbol_get_name (fil.filename_full) in fprint_string (out, name) end // end of [fprint_filename_full] implement print_filename_full (fil) = fprint_filename_full (stdout_ref, fil) (* ****** ****** *) implement filename_get_base (fil) = fil.filename_name implement filename_get_full (fil) = fil.filename_full (* ****** ****** *) implement eq_filename_filename (x1, x2) = x1.filename_full = x2.filename_full // end of [eq_filename_filename] implement compare_filename_filename (x1, x2) = let val f1 = $SYM.symbol_get_name (x1.filename_full) val f2 = $SYM.symbol_get_name (x2.filename_full) in compare_string_string (f1, f2) end // end of [compare_filename_filename] (* ****** ****** *) implement filename_is_relative (name) = let val name = string1_of_string (name) fn aux {n,i:nat | i <= n} ( name: string n, i: size_t i, dirsep: char ) : bool = if string_isnot_atend (name, i) then (name[i] != dirsep) else false // end of [aux] val dirsep = theDirSep_get () in aux (name, 0, dirsep) end // [filename_is_relative] (* ****** ****** *) implement filename_dummy = '{ filename_name= "", filename_full= $SYM.symbol_empty } // end of [filename_dummy] (* ****** ****** *) fun path_normalize (s0: path): path = let fun loop1 {n0,i0:nat | i0 <= n0} ( dirsep: char , s0: string n0, n0: size_t n0, i0: size_t i0 , dirs: &List_vt strptr1 ) : void = if i0 < n0 then loop2 (dirsep, s0, n0, i0, i0, dirs) else () and loop2 {n0,i0,i:nat | i0 < n0; i0 <= i; i <= n0} ( dirsep: char , s0: string n0, n0: size_t n0, i0: size_t i0, i: size_t i , dirs: &List_vt strptr1 ) : void = if i < n0 then let (* // empty *) in if s0[i] <> dirsep then loop2 (dirsep, s0, n0, i0, i+1, dirs) else let val sbp = string_make_substring (s0, i0, i - i0 + 1) val dir = strptr_of_strbuf (sbp) // this is a no-op cast (* val () = begin print "path_normalize: loop2: dir = "; print dir; print_newline () end // end of [val] *) in dirs := list_vt_cons (dir, dirs); loop1 (dirsep, s0, n0, i + 1, dirs) end // end of [if] end else let val sbp = string_make_substring (s0, i0, i - i0) val dir = strptr_of_strbuf (sbp) // this is a no-op cast (* val () = begin print "path_normalize: loop2: dir = "; print dir; print_newline () end // end of [val] *) in dirs := list_vt_cons (dir, dirs) end // end of [if] // end of [loop1] and [loop2] // viewtypedef strptrlst = List_vt (strptr1) extern castfn p2s {l:agz} (x: !strptr l):<> string // fun dirs_process {n:nat} ( curdir: string, pardir: string , npar: int n, dirs: strptrlst, res: strptrlst ) : strptrlst = case+ dirs of | ~list_vt_cons (dir, dirs) => ( if (p2s)dir = curdir then let val () = strptr_free (dir) in dirs_process (curdir, pardir, npar, dirs, res) end else if (p2s)dir = pardir then let val () = strptr_free (dir) in dirs_process (curdir, pardir, npar + 1, dirs, res) end else ( if npar > 0 then let val () = strptr_free (dir) in dirs_process (curdir, pardir, npar - 1, dirs, res) end else begin dirs_process (curdir, pardir, 0, dirs, list_vt_cons (dir, res)) end (* end of [if] *) ) // end of [if] ) // end of [list_vt_cons] | ~list_vt_nil () => loop (pardir, npar, res) where { fun loop {i,j:nat} ( pardir: string, npar: int i, res: list_vt (strptr1, j) ) : list_vt (strptr1, i+j) = if npar > 0 then let val dir = string1_of_string (pardir) val n = string1_length (dir) val dir = string_make_substring (dir, 0, n) val dir = strptr_of_strbuf (dir) in loop (pardir, npar - 1, list_vt_cons (dir, res)) end else res (* end of [if] *) // end of [loop] } // end of [list_vt_nil] // val dirsep = theDirSep_get () val curdir = theCurDir_get () and pardir = theParDir_get () // var dirs: strptrlst = list_vt_nil () val s0 = string1_of_string s0; val n0 = string_length s0 val () = loop1 (dirsep, s0, n0, 0, dirs) val () = dirs := dirs_process (curdir, pardir, 0, dirs, list_vt_nil ()) val fullname = stringlst_concat (__cast dirs) where { extern castfn __cast (x: !strptrlst): List string } // end of [val] val () = list_vt_free_fun (dirs, lam x => strptr_free (x)) // in string_of_strptr (fullname) end // end of [path_normalize] (* ****** ****** *) local assume the_filenamelst_push_v = unit_v viewtypedef filenamelst = List_vt filename val the_filename = ref_make_elt (filename_dummy) val the_filenamelst = ref_make_elt (list_vt_nil ()) fun filename_occurs (f0: filename): bool = let fun loop {n:nat} .. ( fs: !list_vt (filename, n), f0: filename ) :<> bool = case+ fs of | list_vt_cons (f, !p_fs) => if eq_filename_filename (f0, f) then (fold@ fs; true) else let val ans = loop (!p_fs, f0); prval () = fold@ (fs) in ans end (* end of [if] *) | list_vt_nil () => (fold@ fs; false) // end of [loop] val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) in loop (!p, f0) end // end of [filename_occurs] in // in of [local] implement filename_get_current () = !the_filename implement the_filenamelst_pop (pf | (*none*)) = let prval unit_v () = pf val x = x where { val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) val- ~list_vt_cons (x, xs) = !p val () = !p := xs } // end of [val] val () = !the_filename := x in // nothing end // end of [the_filenamelst_pop] implement the_filenamelst_push (f0) = let val x = !the_filename val () = !the_filename := f0 val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) val () = !p := list_vt_cons (x, !p) in (unit_v () | ()) end // end of [the_filenamelst_push] implement the_filenamelst_push_check (f0) = let (* val () = print ("the_filenamelst_push_check: the_filenamelst(bef) =\n") val () = fprint_the_filenamelst (stdout_ref) *) val (pf | ()) = the_filenamelst_push (f0) (* val () = print ("the_filenamelst_push_check: the_filenamelst(aft) =\n") val () = fprint_the_filenamelst (stdout_ref) *) val isexi = filename_occurs (f0) // HX: is [f0] already in the list? in (pf | isexi) end // end of [the_filenamelst_push_check] implement fprint_the_filenamelst (out) = let fun loop ( out: FILEref, fs: !filenamelst ) : void = case+ fs of | list_vt_cons (f, !p_fs) => let val () = fprint_filename_full (out, f) val () = fprint_newline (out) val () = loop (out, !p_fs) in fold@ (fs) end // end of [list_vt_cons] | list_vt_nil () => fold@ (fs) // end of[ loop] val (vbox pf | p) = ref_get_view_ptr (the_filenamelst) in $effmask_ref (loop (out, !p)) end // end of [fprint_the_filenamelst] end // end of [local] (* ****** ****** *) viewtypedef pathlst = List_vt (path) local assume the_pathlst_push_v = unit_v val the_pathlst = ref_make_elt (list_vt_nil) val the_prepathlst = ref_make_elt (list_vt_nil) in // in of [local] fun the_pathlst_get (): pathlst = xs where { val (vbox pf | p) = ref_get_view_ptr (the_pathlst) val xs = !p val () = !p := list_vt_nil () } // end of [the_pathlst_get] fun the_pathlst_set (xs: pathlst): void = { val (vbox pf | p) = ref_get_view_ptr (the_pathlst) val- ~list_vt_nil () = !p val () = !p := xs } // end of [the_pathlst_get] implement the_pathlst_pop (pf | (*none*)) = { prval unit_v () = pf val (vbox pf | p) = ref_get_view_ptr (the_prepathlst) val- ~list_vt_cons (_, xs) = !p val () = !p := xs } // end of [the_prepathlst_push] implement the_pathlst_push (x) = let val (vbox pf | p) = ref_get_view_ptr (the_prepathlst) val () = !p := list_vt_cons (x, !p) in (unit_v () | ()) end // end of [the_prepathlst_push] (* ****** ****** *) fun the_prepathlst_get (): pathlst = xs where { val (vbox pf | p) = ref_get_view_ptr (the_prepathlst) val xs = !p val () = !p := list_vt_nil () } // end of [the_prepathlst_get] fun the_prepathlst_set (xs: pathlst): void = { val (vbox pf | p) = ref_get_view_ptr (the_prepathlst) val- ~list_vt_nil () = !p val () = !p := xs } // end of [the_prepathlst_get] implement the_prepathlst_push (x) = let val (vbox pf | p) = ref_get_view_ptr (the_prepathlst) in !p := list_vt_cons (x, !p) end // end of [the_prepathlst_push] end // end of [local] (* ****** ****** *) local staload UNISTD = "libc/SATS/unistd.sats" in // in of [local] implement filename_make ( basename, fullname ) = let val fullname_sym = $SYM.symbol_make_string (fullname) in '{ filename_name= basename, filename_full= fullname_sym } end // end of [filename_make] implement filenameopt_make_relative (basename) = let // extern castfn p2s {l:agz} (x: !strptr l):<> string // fun aux_try {n:nat} .. ( paths: list (path, n), basename: string ) : Stropt = case+ paths of | list_cons (path, paths) => let val fullname = filename_append (path, basename) val isexi = test_file_exists ((p2s)fullname) (* val () = begin printf ("filenameopt_make_relative: aux_try: fullname = %s\n", @(fullname)) end // end of [val] *) in if isexi then let val fullname = string1_of_strptr (fullname) in stropt_some (fullname) end else let val () = strptr_free (fullname) in aux_try (paths, basename) end // end of [if] end // end of [list_cons] | list_nil () => stropt_none (* end of [aux_try] *) // fn aux_try_pathlst (basename: string): Stropt = ans where { val paths = the_pathlst_get () val ans = aux_try ($UN.castvwtp1 {List(path)} (paths), basename) val () = the_pathlst_set (paths) } // end of [aux_try_pathlst] fn aux_try_prepathlst (basename: string): Stropt = ans where { val paths = the_prepathlst_get () val ans = aux_try ($UN.castvwtp1 {List(path)} (paths), basename) val () = the_prepathlst_set (paths) } // end of [aux_try_prepathlst] // fun aux_relative (basename: string): Stropt = let val fullnameopt = aux_try_prepathlst (basename) in case+ 0 of | _ when stropt_is_some fullnameopt => fullnameopt | _ when test_file_exists (basename) => let val cwd = $UNISTD.getcwd0 () val fullname = filename_append ((p2s)cwd, basename) val () = strptr_free (cwd) val fullname = string1_of_strptr (fullname) in stropt_some (fullname) end | _ => aux_try_pathlst (basename) end // end of [aux_relative] // val fullnameopt = (case+ 0 of | _ when filename_is_relative basename => aux_relative (basename) | _ => ( if test_file_exists (basename) then let val basename = string1_of_string (basename) in stropt_some basename end else stropt_none ) // end of [_] ) : Stropt // end of [val] // in if stropt_is_some fullnameopt then let val fullname = stropt_unsome fullnameopt val fullname = path_normalize fullname in Some_vt (filename_make (basename, fullname)) end else begin None_vt () end // end of [if] end // end of [filenameopt_make] end // end of [local] (* ****** ****** *) %{$ ats_ptr_type atsopt_filename_append ( ats_ptr_type dir, ats_ptr_type bas ) { int n1, n2, n ; char dirsep, *dirbas ; // dirsep = atsopt_filename_theDirSep_get () ; // n1 = strlen ((char*)dir) ; n2 = strlen ((char*)bas) ; n = n1 + n2 ; if (n1 > 0 && ((char*)dir)[n1-1] != dirsep) n += 1 ; dirbas = ATS_MALLOC (n + 1) ; memcpy (dirbas, dir, n1) ; if (n > n1 + n2) { dirbas[n1] = dirsep ; n1 += 1 ; } memcpy (dirbas + n1, bas, n2) ; dirbas[n] = '\000' ; // return dirbas ; } /* end of [atsopt_filename_append] */ %} // end of [%{$] (* ****** ****** *) (* end of [libatsdoc_filename.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_reader.dats0000664000175000017500000001326112223166162022642 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: July, 2011 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_reader.sats" (* ****** ****** *) viewtypedef freader (v:view) = $extype_struct "libatsdoc_reader_struct" of { pfres= v , getchar= (!v | (*none*)) - int , freeres= ( v | (*none*)) - void } // end of [freader] (* ****** ****** *) absviewt@ype reader0 = reader? // for initialization (* ****** ****** *) local staload "libc/SATS/stdio.sats" assume reader0 = freader (unit_v)? assume reader_vt0ype = [v:view] freader (v) in // in of [local] (* ****** ****** *) implement reader_get_char (r) = r.getchar (r.pfres | (*none*)) (* ****** ****** *) fun reader0_initialize_filp {m:file_mode} {l:addr} ( pfmod: file_mode_lte (m, r) , pffil: FILE m @ l | r: &reader0 >> reader, p: ptr l ) : void = () where { viewdef v = FILE m @ l val getchar = lam (pffil: !v | (*none*)): int = fgetc_err (pfmod | !p) // end of [getchar] val freeres = lam (pffil: v | (*none*)): void = fclose_exn (pffil | p) prval () = r.pfres := pffil val () = r.getchar := getchar val () = r.freeres := freeres } // end of [reader0_initialize_filp] (* ****** ****** *) fun reader0_initialize_getc ( r: &reader0 >> reader, getc: () - int ) : void = () where { viewdef v = unit_v val getchar = __cast (getc) where { extern castfn __cast (f: () - int): (!v | (*none*)) - int // end of [extern] } // end of [val] val freeres = lam ( pf: v | (*none*) ) : void = let prval unit_v () = pf in (*none*) end val () = r.pfres := unit_v () val () = r.getchar := getchar val () = r.freeres := freeres } // end of [reader0_initialize_getc] (* ****** ****** *) fun reader0_initialize_string {n:nat} {l:addr} ( pfgc: free_gc_v (size_t?, l) , pfat: sizeLte n @ l | r: &reader0 >> reader, inp: string n, p: ptr l ) : void = () where { // viewdef v = ( free_gc_v (size_t?, l), sizeLte n @ l ) // end of [viewdef] // val getchar = lam (pf: !v | (*none*)): int = let prval pf1 = pf.1 val i = !p prval () = pf.1 := pf1 in if string_isnot_atend (inp, i) then let val c = string_get_char_at (inp, i) prval pf1 = pf.1 val () = !p := i + 1 prval () = pf.1 := pf1 in (int_of_char)c end else ~1 (*EOF*) // end of [if] end // end of [val] // val freeres = lam (pf: v | (*none*)): void = ptr_free {size_t?} (pf.0, pf.1 | p) // end of [freeres] // val () = r.pfres := (pfgc, pfat) val () = r.getchar := getchar val () = r.freeres := freeres } // end of [reader0_initialize_string] (* ****** ****** *) fun reader0_uninitialize ( r: &reader >> reader0 ) : void = () where { stavar v: view prval pf = r.pfres : v val () = r.freeres (pf | (*none*)) val () = cloptr_free (r.getchar) val () = cloptr_free (r.freeres) prval () = __assert (r) where { extern prfun __assert (r: &freader(v)? >> reader0): void } // end of [prval] } // end of [reader0_uninitialize] (* ****** ****** *) end // end of [local] (* ****** ****** *) local extern prfun reader0_encode (r: &reader? >> reader0): void extern prfun reader0_decode (r: &reader0 >> reader?): void in // in of [local] (* ****** ****** *) implement reader_initialize_filp (pfmod, pffil | r, p) = () where { prval () = reader0_encode (r) val () = reader0_initialize_filp (pfmod, pffil | r, p) } // end of [reader_initialize_filp] implement reader_initialize_getc (r, getc) = () where { prval () = reader0_encode (r) val () = reader0_initialize_getc (r, getc) } // end of [reader_initialize_getc] implement reader_initialize_string (r, inp) = () where { val [n:int] inp = (string1_of_string)inp val (pfgc, pfat | p) = ptr_alloc () val () = !p := (size1_of_int1)0 prval () = reader0_encode (r) val () = reader0_initialize_string (pfgc, pfat | r, inp, p) } // end of preader_initialize_string] (* ****** ****** *) implement reader_uninitialize (r) = () where { val () = reader0_uninitialize (r) prval () = reader0_decode (r) } // end of [reader_uninitialize] (* ****** ****** *) end // end of [local] (* ****** ****** *) (* end of [libatsdoc_reader.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_atext.dats0000664000175000017500000003413312223166162022526 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (gmhwxi AT gmail DOT com) // Start Time: July, 2011 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) // staload UN = "prelude/SATS/unsafe.sats" // staload STDIO = "libc/SATS/stdio.sats" sortdef fm = $STDIO.fm stadef FILE_v = $STDIO.FILE_v macdef SEEK_SET = $STDIO.SEEK_SET macdef feof = $STDIO.feof macdef fopen_err = $STDIO.fopen_err macdef fclose_err = $STDIO.fclose_err macdef fflush_err = $STDIO.fflush_err macdef fgetc_err = $STDIO.fgetc_err macdef fputc_err = $STDIO.fputc_err macdef fseek_err = $STDIO.fseek_err // staload FCNTL = "libc/SATS/fcntl.sats" staload STDLIB = "libc/SATS/stdlib.sats" staload UNISTD = "libc/SATS/unistd.sats" staload WAIT = "libc/sys/SATS/wait.sats" // (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_symbol.sats" staload "libatsdoc/SATS/libatsdoc_symmap.sats" (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_atext.sats" (* ****** ****** *) macdef neof (i) = (,(i) != EOF) (* ****** ****** *) datatype atext = // | ATEXTnil of () // empty text // | ATEXTstrcst of string // string constants | ATEXTstrsub of string // strings containing marked tokens // | ATEXTapptxt2 of (atext, atext) // text concatenation | ATEXTappstr2 of (string, string) // string concatenation // | ATEXTapptxt3 of (atext, atext, atext) // text concatenation | ATEXTappstr3 of (string, string, string) // string concatenation // | ATEXTconcatxt of atextlst // text concatenation | ATEXTconcatxtsep of (atextlst, atext(*sep*)) // text concatenation with separator // end of [atext] where stringlst = List (string) (* ****** ****** *) assume atext_type = atext (* ****** ****** *) implement atext_nil () = ATEXTnil () implement atext_strcst (x) = ATEXTstrcst (x) implement atext_strsub (x) = ATEXTstrsub (x) implement atext_apptxt2 (x1, x2) = ATEXTapptxt2 (x1, x2) implement atext_appstr2 (x1, x2) = ATEXTappstr2 (x1, x2) implement atext_apptxt3 (x1, x2, x3) = ATEXTapptxt3 (x1, x2, x3) implement atext_appstr3 (x1, x2, x3) = ATEXTappstr3 (x1, x2, x3) implement atext_concatxt (xs) = ATEXTconcatxt (xs) implement atext_concatxtsep (xs, sep) = ATEXTconcatxtsep (xs, sep) (* ****** ****** *) implement atext_newline () = ATEXTstrcst ("\n") (* ****** ****** *) // implement atext_strptr (x) = ATEXTstrcst ((string_of_strptr)x) implement atext_strptr0 (x) = let val notnull = strptr_isnot_null (x) in if notnull then atext_strptr (x) else let val () = strptr_free (x) in atext_nil () end // end of [if] end // end of [atext_strptr0] // implement atext_strcstptr (x) = ATEXTstrcst ((string_of_strptr)x) implement atext_strsubptr (x) = ATEXTstrsub ((string_of_strptr)x) // (* ****** ****** *) local staload S = "libc/SATS/stdlib.sats" staload UNI = "libc/SATS/unistd.sats" in // in of [local] %{$ ats_ptr_type libatsdoc_file2strptr (ats_int_type fd) { int err = 0 ; int nerr = 0 ; char* sbp = (char*)0 ; // long int ofs_beg, ofs_end, nbyte ; // ofs_beg = lseek (fd, 0L, SEEK_CUR) ; if (ofs_beg < 0) nerr += 1 ; ofs_end = lseek (fd, 0L, SEEK_END) ; if (ofs_end < 0) nerr += 1 ; ofs_beg = lseek (fd, ofs_beg, SEEK_SET) ; if (ofs_beg < 0) nerr += 1 ; nbyte = ofs_end - ofs_beg ; // if (nerr == 0) { sbp = ATS_MALLOC(nbyte + 1) ; } if (sbp == NULL) nerr += 1 ; // if (nerr == 0) { err = atslib_fildes_read_all_err (fd, sbp, nbyte) ; } if (err < 0) { nerr += 1 ; } // if (nerr == 0) { sbp[ofs_end] = '\0'; return sbp ; } // if (sbp) free (sbp) ; return NULL ; } // end of [libatsdoc_file2strptr] %} // end of [%{$] (* ****** ****** *) implement{a} tostring_fprint (prfx, fpr, x) = let val tmp = sprintf ("%sXXXXXX", @(prfx)) val [m,n:int] tmp = strbuf_of_strptr (tmp) prval () = __assert () where { extern prfun __assert (): [n >= 6] void } prval pfstr = tmp.1 val (pfopt | fd) = $S.mkstemp !(tmp.2) // create it! prval () = tmp.1 := pfstr val tmp = strptr_of_strbuf (tmp) in // if fd >= 0 then let prval $F.open_v_succ (pffil) = pfopt val (fpf | out) = fdopen (pffil | fd, file_mode_w) where { extern fun fdopen {fd:nat} ( pffil: !fildes_v fd | fd: int fd, mode: file_mode ) : (fildes_v fd - void | FILEref) = "mac#fdopen" } // end of [out] val () = fpr (out, x) val _err = fflush_err (out) val _err = fseek_err (out, 0L, SEEK_SET) val res = file2strptr (pffil | fd) prval () = fpf (pffil) val _err = fclose_err (out) val _err = $UNI.unlink ($UN.castvwtp1 (tmp)) val () = strptr_free (tmp) in res (*strptr*) end else let prval $F.open_v_fail () = pfopt; val () = strptr_free (tmp) in strptr_null () end // end of [if] // end // end of [tostring_fprint] (* ****** ****** *) implement tostring_strsub (sub) = tostring_fprint ("libatsdoc_tostring_strsub", fprint_strsub, sub) // end of [tostring_strsub] (* ****** ****** *) local fun filepath2string (path: string): strptr0 = let val [l:addr] (pfopt | filp) = fopen_err (path, file_mode_r) in if filp > null then let prval Some_v (pffil) = pfopt val filr = __cast (pffil | filp) where { extern castfn __cast {m:fm} (pffil: FILE_v (m, l) | p: ptr l): FILEref } // end of [val] val cs = char_list_vt_make_file (filr) val _err = fclose_err (filr) val cs1 = $UN.castvwtp1 {List(char)} (cs) val n = list_length (cs1) val sbf = string_make_list_int (cs1, n) val () = list_vt_free (cs) in strptr_of_strbuf (sbf) end else let prval None_v () = pfopt in strptr_null () end // end of [if] end // end of [filepath2string] in // in of [local] implement atext_filepath (path) = let val [l:addr] str = filepath2string (path) prval () = addr_is_gtez {l} () val isnotnull = strptr_isnot_null (str) in if isnotnull then atext_strptr (str) else let prval () = strptr_free_null (str) in atext_nil () end // end of [if] end // end of [atext_filepath] end // end of [local] (* ****** ****** *) end // end of [local] (* ****** ****** *) local viewtypedef atextmap = symmap (atext) val map0 = symmap_make_nil () val theAtextMap = ref (map0) in // in of [local] implement theAtextMap_search (s) = let val (vbox pf | p) = ref_get_view_ptr (theAtextMap) in symmap_search (!p, s) end // end of [theAtextMap_search] implement theAtextMap_insert (s, x) = let val (vbox pf | p) = ref_get_view_ptr (theAtextMap) in symmap_insert (!p, s, x) end // end of [theAtextMap_insert] implement theAtextMap_insert_str (s, x) = let val s = symbol_make_string (s) in theAtextMap_insert (s, x) end // end of [theAtextMap_insert_str] end // end of [local] (* ****** ****** *) implement fprint_atext (out, x) = ( case+ x of // | ATEXTnil () => () // | ATEXTstrcst (str) => fprint_string (out, str) | ATEXTstrsub (sub) => fprint_strsub (out, sub) // | ATEXTapptxt2 (x1, x2) => { val () = fprint_atext (out, x1) val () = fprint_atext (out, x2) } | ATEXTappstr2 (x1, x2) => { val () = fprint_string (out, x1) val () = fprint_string (out, x2) } // | ATEXTapptxt3 (x1, x2, x3) => { val () = fprint_atext (out, x1) val () = fprint_atext (out, x2) val () = fprint_atext (out, x3) } | ATEXTappstr3 (x1, x2, x3) => { val () = fprint_string (out, x1) val () = fprint_string (out, x2) val () = fprint_string (out, x3) } // | ATEXTconcatxt (xs) => fprint_atextlst (out, xs) | ATEXTconcatxtsep (xs, sep) => fprint_atextlst_sep (out, xs, sep) // ) (* end of [fprint_atext] *) implement fprint_atextlst (out, xs) = list_app_cloptr (xs, lam (x) =<1> fprint_atext (out, x)) // end of [fprint_atextlst] implement fprint_atextlst_sep (out, xs, sep) = let fun loop ( xs: atextlst, i: int ) : void = case+ xs of | list_cons (x, xs) => let val () = if i > 0 then fprint_atext (out, sep) val () = fprint_atext (out, x) in loop (xs, i+1) end // end of [list_cons] | list_nil () => () // end of [loop] in loop (xs, 0) end // end of [fprint_atextlst] (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_reader.sats" extern fun fprsub_reader (out: FILEref, inp: &reader): void (* ****** ****** *) local #define i2c char_of_int fun IDENTFST_test (c: char): bool = case+ 0 of | _ when ('a' <= c andalso c <= 'z') => true | _ when ('A' <= c andalso c <= 'Z') => true | _ when c = '_' => true | _ => false // end of [IDENTFST_test] fun IDENTRST_test (c: char): bool = case+ 0 of | _ when ('a' <= c andalso c <= 'z') => true | _ when ('A' <= c andalso c <= 'Z') => true | _ when ('0' <= c andalso c <= '9') => true | _ when c = '_' => true | _ when c = '\'' => true | _ => false // end of [IDENTRST_test] fun ident_get ( inp: &reader, cur: &int ) : List_vt (char) = let val fst = (i2c)cur in if IDENTFST_test (fst) then let val () = cur := reader_get_char (inp) in list_vt_cons (fst, identrst_get (inp, cur)) end else list_vt_nil () // end of [if] end // end of [ident_get] and identrst_get ( inp: &reader, cur: &int ) : List_vt (char) = let val fst = (i2c)cur in if IDENTRST_test (fst) then let val () = cur := reader_get_char (inp) in list_vt_cons (fst, identrst_get (inp, cur)) end else list_vt_nil () // end of [if] end // end of [identrst_get] fun fprsub_ident {n:nat} ( out: FILEref, cs: list_vt (char, n) ) : void = let val n = list_vt_length (cs) in if n > 0 then let val cs1 = $UN.castvwtp1(cs) val id = string_make_list_int (cs1, n) val id = string_of_strbuf (id) val sym = symbol_make_string (id) val ans = theAtextMap_search (sym) val () = (case+ ans of | ~Some_vt xt => fprint_atext (out, xt) | ~None_vt () => fprintf (out, "#%s$", @(id)) ) // end of [val] // val () = list_vt_free (cs) // in // nothing end else let val ~list_vt_nil () = cs in (*nothing*) end // end of [if] end // end of [fprsub_ident] in // in of [local] implement fprsub_reader (out, inp) = let // fun aux ( out: FILEref, inp: &reader, cur: &int ) : void = if neof(cur) then let val fst = (i2c)cur val () = cur := reader_get_char (inp) in case+ fst of | '#' => aux_SHARP (out, inp, cur) | '\\' => aux_SLASH (out, inp, cur) | _ => let val err = fputc_err (fst, out) in aux (out, inp, cur) end // end of [_] end // end of [if] // and aux_SHARP ( out: FILEref, inp: &reader, cur: &int ) : void = if neof(cur) then let val cs = ident_get (inp, cur) val dlrend = (cur = int_of('$')): bool // fun loop (out: FILEref, cs: List_vt (char)): void = case+ cs of | ~list_vt_cons (c, cs) => let val err = fputc_err (c, out) in loop (out, cs) end // end of [list_cons] | ~list_vt_nil () => () (* end of [loop] *) // val () = if dlrend then let val () = cur := reader_get_char (inp) in fprsub_ident (out, cs) // valid identifier end else let val err = fputc_err ('#', out) in loop (out, cs) end // end of [if] // end of [val] in aux (out, inp, cur) end else let val err = fputc_err ('#', out) in (*nothing*) end // end of [if] // and aux_SLASH ( out: FILEref, inp: &reader, cur: &int ) : void = if neof(cur) then let val fst = (i2c)cur val () = cur := reader_get_char (inp) in case+ fst of | '#' => let val err = fputc_err ('#', out) in aux (out, inp, cur) end // end of ['#'] | '\\' => let val err = fputc_err ('\\', out) in aux (out, inp, cur) end // end of ['\\'] | _ => let val err = fputc_err ('\\', out); val err = fputc_err (fst, out) in aux (out, inp, cur) end // end of [_] end else let val err = fputc_err ('\\', out) in (*nothing*) end // end of [if] // var cur: int val () = cur := reader_get_char (inp) in aux (out, inp, cur) end // end of [fprsub_reader] end // end of [local] (* ****** ****** *) implement fprint_strsub (out, sub) = let var inp: reader val () = reader_initialize_string (inp, sub) val () = fprsub_reader (out, inp) val () = reader_uninitialize (inp) in // nothing end // end of [fprint_strsub] (* ****** ****** *) implement fprint_filsub (out, path) = let val (pfopt | filp) = fopen_err (path, file_mode_r) in // if filp > null then let prval Some_v (pffil) = pfopt var inp: reader val () = reader_initialize_filp (file_mode_lte_r_r, pffil | inp, filp) val () = fprsub_reader (out, inp) val () = reader_uninitialize (inp) in // nothing end else let prval None_v () = pfopt val () = fprintf (stderr_ref, "fprint_filsub: [%s] cannot be opened!\n", @(path)) val () = exit (1) in // nothing end // end of [if] // end // end of [fprint_filsub] (* ****** ****** *) (* end of [libatsdoc_atext.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/DATS/libatsdoc_lexbuf.dats0000664000175000017500000002304212223166162022663 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-20?? Hongwei Xi, ATS Trustworthy Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Start Time: March, 2011 // (* ****** ****** *) staload LOC = "libatsdoc/SATS/libatsdoc_location.sats" (* ****** ****** *) // staload Q = "libats/SATS/linqueue_arr.sats" stadef QUEUE = $Q.QUEUE // staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "libats/DATS/linqueue_arr.dats" staload _(*anon*) = "libats/ngc/DATS/deque_arr.dats" // (* ****** ****** *) staload R = "libatsdoc/SATS/libatsdoc_reader.sats" viewtypedef reader = $R.reader (* ****** ****** *) staload "libatsdoc/SATS/libatsdoc_lexbuf.sats" (* ****** ****** *) // #define uc2i int_of_uchar #define i2uc uchar_of_int // #define u2i int_of_uint #define u2l lint_of_uint #define u2sz size_of_uint // #define l2u uint_of_lint #define l2sz size_of_lint // #define sz2i int_of_size #define sz2l lint_of_size // #define size1 size1_of_size // (* ****** ****** *) macdef neof (i) = (,(i) != EOF) (* ****** ****** *) viewtypedef lexbuf_int_int (m: int, n:int) = $extype_struct "libatsdoc_lexbuf_struct" of { cbuf= QUEUE (uchar, m, n) // character buffer , base= lint , base_nrow=int, base_ncol= int , nspace= int , reader= reader } // end of [lexbuf] typedef lexbuf0 = lexbuf_int_int(0, 0)? (* ****** ****** *) assume lexbuf_vt0ype = [m,n:int] lexbuf_int_int (m, n) // end of [lexbuf_vt0ype] (* ****** ****** *) #define QINISZ 1024 // initial size #define QDELTA 1024 // subsequent increment (* ****** ****** *) implement lexbuf_initialize_filp (pfmod, pffil | buf, p) = () where { // extern prfun lexbuf0_trans (buf: &lexbuf? >> lexbuf0): void // prval () = lexbuf0_trans (buf) val () = $Q.queue_initialize (buf.cbuf, QINISZ) val () = buf.base := 0L val () = buf.base_nrow := 0 val () = buf.base_ncol := 0 val () = buf.nspace := 0 val () = $R.reader_initialize_filp (pfmod, pffil | buf.reader, p) } // end of [lexbuf_initialize_filp] implement lexbuf_initialize_getc (buf, getc) = () where { // extern prfun lexbuf0_trans (buf: &lexbuf? >> lexbuf0): void // prval () = lexbuf0_trans (buf) val () = $Q.queue_initialize (buf.cbuf, QINISZ) val () = buf.base := 0L val () = buf.base_nrow := 0 val () = buf.base_ncol := 0 val () = buf.nspace := 0 val () = $R.reader_initialize_getc (buf.reader, getc) } // end of [lexbuf_initialize_getc] implement lexbuf_initialize_string (buf, inp) = () where { // extern prfun lexbuf0_trans (buf: &lexbuf? >> lexbuf0): void // prval () = lexbuf0_trans (buf) val () = $Q.queue_initialize (buf.cbuf, QINISZ) val () = buf.base := 0L val () = buf.base_nrow := 0 val () = buf.base_ncol := 0 val () = buf.nspace := 0 val () = $R.reader_initialize_string (buf.reader, inp) } // end of [lexbuf_initialize_string] (* ****** ****** *) implement lexbuf_uninitialize (buf) = () where { val () = $Q.queue_uninitialize (buf.cbuf) val () = $R.reader_uninitialize (buf.reader) // extern prfun lexbuf0_untrans (buf: &lexbuf0 >> lexbuf?): void // prval () = lexbuf0_untrans (buf) } // end of [lexbuf_uninitialize] (* ****** ****** *) implement lexbufpos_diff (buf, pos) = let val nchr = $LOC.position_get_ntot (pos) - buf.base in (l2u)nchr end // end of [lexbufpos_diff] (* ****** ****** *) implement lexbuf_get_base (buf) = buf.base implement lexbuf_get_position (buf, pos) = let val ntot = buf.base val nrow = buf.base_nrow val ncol = buf.base_ncol in $LOC.position_init (pos, ntot, nrow, ncol) end // end of [lexbuf_get_position] implement lexbuf_get_nspace (buf) = buf.nspace implement lexbuf_set_nspace (buf, n) = buf.nspace := n (* ****** ****** *) implement lexbufpos_get_location (buf, pos) = let var bpos: position val () = lexbuf_get_position (buf, bpos) // end of [val] in $LOC.location_make_pos_pos (bpos, pos) end // end of [lexbufpos_get_location] (* ****** ****** *) implement lexbuf_get_char (buf, nchr) = let // prval () = $Q.lemma_queue_param (buf.cbuf) // val nchr = (u2sz)nchr val nchr = (size1)nchr val n = $Q.queue_size (buf.cbuf) in if nchr < n then let val c = $Q.queue_get_elt_at (buf.cbuf, nchr) in (uc2i)c end else let val i = $R.reader_get_char (buf.reader) in if neof(i) then let val c = (i2uc)i val m = $Q.queue_cap {uchar} (buf.cbuf) in if m > n then let val () = $Q.queue_insert (buf.cbuf, c) in i end else let val () = $Q.queue_update_capacity (buf.cbuf, m+QDELTA) val () = $Q.queue_insert (buf.cbuf, c) in i end // end of [if] end else i (* EOF *) // end of [if] end (* end of [if] *) end // end of [lexbuf_get_char] (* ****** ****** *) implement lexbufpos_get_char (buf, pos) = let val nchr = $LOC.position_get_ntot (pos) - buf.base val nchr = (l2u)nchr in lexbuf_get_char (buf, nchr) end // end of [lexbufpos_get_char] (* ****** ****** *) implement lexbuf_incby_count (buf, cnt) = let // prval () = $Q.lemma_queue_param (buf.cbuf) // val nchr = u2sz(cnt) val nchr = (size1)nchr val n = $Q.queue_size (buf.cbuf) in if nchr < n then let val () = buf.base := buf.base + (u2l)cnt val () = buf.base_ncol := buf.base_ncol + (u2i)cnt val () = $Q.queue_clear (buf.cbuf, nchr) in // nothing end else let val () = buf.base := buf.base + (sz2l)n val () = buf.base_ncol := buf.base_ncol + (sz2i)n val () = $Q.queue_clear_all {uchar} (buf.cbuf) in // nothing end (* end of [if] *) end // end of [lexbuf_incby_count] (* ****** ****** *) implement lexbuf_reset_position (buf, pos) = let // prval () = $Q.lemma_queue_param (buf.cbuf) // val ntot = $LOC.position_get_ntot (pos) val nchr = ntot - buf.base val () = buf.base := ntot val () = buf.base_nrow := $LOC.position_get_nrow (pos) val () = buf.base_ncol := $LOC.position_get_ncol (pos) val nchr = (l2sz)nchr val nchr = (size1)nchr val n = $Q.queue_size (buf.cbuf) in if nchr < n then let val () = $Q.queue_clear (buf.cbuf, nchr) in // nothing end else let val () = $Q.queue_clear_all {uchar} (buf.cbuf) in // nothing end (* end of [if] *) end // end of [lexbuf_reset_position] (* ****** ****** *) implement lexbuf_get_strptr0 (buf, ln) = lexbuf_get_substrptr0 (buf, 0u, ln) // end of [lexbuf_get_strptr0] implement lexbuf_get_strptr1 (buf, ln) = lexbuf_get_substrptr1 (buf, 0u, ln) // end of [lexbuf_get_strptr] (* ****** ****** *) local // extern fun queue_get_strptr1 {m,n:int} {st,ln:nat | st+ln <= n} ( q: &QUEUE (uchar, m, n), st: size_t st, ln: size_t ln ) : strptr1 // end of [queue_get_strptr1] // implement queue_get_strptr1 (q, st, ln) = let val [l:addr] (pfgc, pfarr | p) = malloc_gc (ln+1) // end of [val] prval (pf1, fpf2) = __assert (pfarr) where { extern prfun __assert {k:nat} ( pfarr: b0ytes(k+1) @ l ) : ( @[uchar?][k] @ l, @[uchar][k] @ l - bytes(k+1) @ l ) (* end of [_assert] *) } // end of [prval] val () = $Q.queue_copyout (q, st, ln, !p) prval () = pfarr := fpf2 (pf1) val () = bytes_strbuf_trans (pfarr | p, ln) in strptr_of_strbuf @(pfgc, pfarr | p) end // end of [queue_get_strptr1] in // in of [local] implement lexbuf_get_substrptr0 (buf, st, ln) = let // prval () = $Q.lemma_queue_param (buf.cbuf) // val i = u2sz(st) val i = (size1)i val k = u2sz(ln) val [k:int] k = (size1)k val n = $Q.queue_size (buf.cbuf) // (* val () = println! ("lexbuf_get_strptr: i = ", i) val () = println! ("lexbuf_get_strptr: k = ", k) val () = println! ("lexbuf_get_strptr: n = ", n) *) // in // if i + k <= n then queue_get_strptr1 (buf.cbuf, i, k) else strptr_null () // end of [if] // end // end of [lexbuf_get_substrptr0] end // end of [local] implement lexbuf_get_substrptr1 (buf, st, ln) = str where { val str = lexbuf_get_substrptr0 (buf, st, ln) val () = assertloc (strptr_isnot_null (str)) } // end of [lexbuf_get_substrptr1] (* ****** ****** *) implement lexbufpos_get_strptr0 (buf, pos) = lexbuf_get_strptr0 (buf, lexbufpos_diff (buf, pos)) // end of [lexbufpos_get_strptr0] implement lexbufpos_get_strptr1 (buf, pos) = lexbuf_get_strptr1 (buf, lexbufpos_diff (buf, pos)) // end of [lexbufpos_get_strptr1] (* ****** ****** *) (* end of [libatsdoc_lexbuf.dats] *) ats-lang-anairiats-0.2.11/libatsdoc/Makefile_inp0000664000175000017500000000514312223166162020252 0ustar hwxihwxi#include "config.h" /* ****** ******* */ #define __ID(x) x /* ****** ******* */ ATSHOMEQ="$(ATSHOME)" ATSCC=$(ATSHOMEQ)/bin/atscc ATSOPT=$(ATSHOMEQ)/bin/atsopt __ID(######) ATSGCFLAG= ATSGCFLAG=-D_ATS_GCATS ATSCCFLAGS=-g ATSCCFLAGS=-g -O ATSCCFLAGS=-g -O2 __ID(######) #if (SIZEOF_VOIDP==4) ATSLIB=$(ATSHOMEQ)/ccomp/lib #endif #if (SIZEOF_VOIDP==8) ATSLIB=$(ATSHOMEQ)/ccomp/lib64 #endif __ID(######) all:: libatsdoc __ID(######) SOURCES := \ libatsdoc_error.sats \ libatsdoc_error.dats \ libatsdoc_symbol.sats \ libatsdoc_symbol.dats \ libatsdoc_symmap.sats \ libatsdoc_symmap.dats \ libatsdoc_filename.sats \ libatsdoc_filename.dats \ libatsdoc_location.sats \ libatsdoc_location.dats \ libatsdoc_reader.sats \ libatsdoc_reader.dats \ libatsdoc_lexbuf.sats \ libatsdoc_lexbuf.dats \ libatsdoc_atext.sats \ libatsdoc_atext.dats \ SOURCESsta := $(filter %.sats, $(SOURCES)) SOURCESdyn := $(filter %.dats, $(SOURCES)) OBJECTS := $(SOURCES) OBJECTS := $(patsubst %.sats, %_sats.o, $(OBJECTS)) OBJECTS := $(patsubst %.dats, %_dats.o, $(OBJECTS)) __ID(######) libatsdoc_error_sats.o : SATS/libatsdoc_error.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_error_dats.o : DATS/libatsdoc_error.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_symbol_sats.o : SATS/libatsdoc_symbol.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_symbol_dats.o : DATS/libatsdoc_symbol.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_symmap_sats.o : SATS/libatsdoc_symmap.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_symmap_dats.o : DATS/libatsdoc_symmap.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_filename_sats.o : SATS/libatsdoc_filename.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_filename_dats.o : DATS/libatsdoc_filename.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_location_sats.o : SATS/libatsdoc_location.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_location_dats.o : DATS/libatsdoc_location.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_reader_sats.o : SATS/libatsdoc_reader.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_reader_dats.o : DATS/libatsdoc_reader.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_lexbuf_sats.o : SATS/libatsdoc_lexbuf.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_lexbuf_dats.o : DATS/libatsdoc_lexbuf.dats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_atext_sats.o : SATS/libatsdoc_atext.sats; $(ATSCC) $(ATSCCFLAGS) -c $< libatsdoc_atext_dats.o : DATS/libatsdoc_atext.dats; $(ATSCC) $(ATSCCFLAGS) -c $< __ID(######) ARR=ar -r __ID(######) libatsdoc: dynloadall.dats $(OBJECTS); $(ATSCC) $(ATSCCFLAGS) -c dynloadall.dats; $(ARR) $(ATSLIB)/libatsdoc.a dynloadall_dats.o $(OBJECTS) __ID(###### end of [Makefile] ######) ats-lang-anairiats-0.2.11/doc/0000700000175000017500000000000012223166160014524 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/0000700000175000017500000000000012223166161015620 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/0000700000175000017500000000000012223166161017163 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/qsort_mt.dats0000664000175000017500000001377312223166161021737 0ustar hwxihwxi// // A parallelized implementation of mergesort // // Time: March 2008 // Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) // (* ****** ****** *) #if undefined (ARG_QUICKSORT_MT_DATS) #then absviewt@ype T extern fun lte_T_T (x: !T, y: !T):<> bool extern fun compare_T_T (x: !T, y: !T):<> Sgn overload compare with compare_T_T overload <= with lte_T_T #endif // end of [undefined (ARG_QUICKSORT_MT_DATS)] (* ****** ****** *) fun insert_one {n,i:nat | i < n} {A:addr} {ofs:int} ( pf_mul: MUL (i, sizeof T, ofs) , pf1: array_v (T, i, A) , pf21: T? @ (A+ofs) , pf22: array_v (T, n-i-1, A+ofs+sizeof T) | x: T, p: ptr (A+ofs), i: int i ) : (array_v (T, n, A) | void) = begin case+ i of | _ when i > 0 => let prval pf1_mul = mul_add_const {~1} (pf_mul) prval (pf11, pf12) = array_v_unextend {T} (pf_mul, pf1) val p1 = p - sizeof val x1 = ptr_get_vt (pf12 | p1) in if x1 <= x then let val () = ptr_set_vt (pf12 | p1, x1) prval pf1 = array_v_extend {T} (pf1_mul, pf11, pf12) val () = !p := x prval pf2 = array_v_cons {T} (pf21, pf22) prval pf = array_v_unsplit {T} (pf_mul, pf1, pf2) in (pf | ()) end else let val () = !p := x1 prval pf2 = array_v_cons {T} (pf21, pf22) in insert_one (pf1_mul, pf11, pf12, pf2 | x, p1, i-1) end end | _ => let val () = assert (i = 0) prval MULbas () = pf_mul prval () = array_v_unnil {T} (pf1) val () = !p := x prval pf = array_v_cons {T} (pf21, pf22) in (pf | ()) end end // end of [insert] (* ****** ****** *) fun insert_all {n,i:nat | i <= n} {A:addr} {ofs:int} ( pf_mul: MUL (i, sizeof T, ofs) , pf: !array_v (T, n, A) | p: ptr (A+ofs), i: int i, n: int n ) : void = begin if i < n then let prval (pf1, pf2) = array_v_split {T} (pf_mul, pf) prval (pf21, pf22) = array_v_uncons {T} (pf2) val x = ptr_get_vt (pf21 | p) val (pf_new | ()) = insert_one (pf_mul, pf1, pf21, pf22 | x, p, i) prval () = pf := pf_new in insert_all (mul_add_const {1} (pf_mul), pf | p+sizeof, i+1, n) end else begin // empty end end // end of [insert_all] (* ****** ****** *) fun insort {n:nat} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, n: int n): void = begin if n >= 2 then let prval pf_mul = MULind (MULbas ()) in insert_all (pf_mul, pf | A+sizeof, 1, n) end else begin // empty end end // end of [insort] (* ****** ****** *) macdef size = size1_of_int1 (* ****** ****** *) fn exch {n,i1,i2:nat | i1 < n; i2 < n; i1 <> i2} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, i1: int i1, i2: int i2): void = let val @(pf1, pf2, fpf | p1, p2) = array_ptr_takeout2_tsz {T} (pf | A, (size)i1, (size)i2, sizeof) val tmp = !p1; val () = !p1 := !p2; val () = !p2 := tmp in pf := fpf (pf1, pf2) end // end of [exch] (* ****** ****** *) fun innerLoop_l {n,l,r:int | 0 <= l; l <= r+1; r < n} {A:addr} .. (pf: !array_v (T, n, A) | A: ptr A, pivot: !T, l: int l, r: int r) : natLte (r+1) = begin if l <= r then let val (pf1, fpf | p1) = array_ptr_takeout_tsz {T} (pf | A, (size)l, sizeof) in if !p1 <= pivot then let prval () = pf := fpf (pf1) in innerLoop_l (pf | A, pivot, l+1, r) end else begin pf := fpf (pf1); l end end else begin l // return value end end // end of [innerLoop_l] fun innerLoop_r {n,l,r:int | 0 <= l; l <= r+1; r < n} {A:addr} .. (pf: !array_v (T, n, A) | A: ptr A, pivot: !T, l: int l, r: int r) : intBtw (l-1, n) = begin if l <= r then let val (pf1, fpf | p1) = array_ptr_takeout_tsz {T} (pf | A, (size)r, sizeof) in if pivot <= !p1 then let prval () = pf := fpf (pf1) in innerLoop_r (pf | A, pivot, l, r-1) end else begin pf := fpf (pf1); r end end else begin r // return value end end // end of [innerLoop_r] fun outerLoop {n,l,r:int | 0 <= l; l <= r+1; r < n} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, pivot: !T, l: int l, r: int r) : natLte n = let val l = innerLoop_l (pf | A, pivot, l, r) val r = innerLoop_r (pf | A, pivot, l, r) in if l < r then begin exch (pf | A, l, r); outerLoop (pf | A, pivot, l+1, r-1) end else begin l // the pivot end end // end of [outerLoop] (* ****** ****** *) fn partition {n:nat | n >= 2} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, n: int n): natLt n = let val (pf_mul | ofs) = (size)n szmul2 sizeof prval pf1_mul = mul_add_const {~1} (pf_mul) prval @(pf1, pf2) = array_v_unextend {T} (pf_mul, pf) val pivot = ptr_get_vt (pf2 | A + ofs - sizeof) val i_pivot = outerLoop (pf1 | A, pivot, 0, n-2) val () = if i_pivot < n - 1 then let val (pf11, fpf1 | p) = begin array_ptr_takeout_tsz {T} (pf1 | A, (size)i_pivot, sizeof) end val () = ptr_set_vt (pf2 | A + ofs - sizeof, !p) val () = !p := pivot; prval () = pf1 := fpf1 (pf11) in // empty end else begin ptr_set_vt (pf2 | A + ofs - sizeof, pivot) end prval () = pf := array_v_extend {T} (pf1_mul, pf1, pf2) in i_pivot end // end of [partition] #define THRESHOLD 16 fun qsort_main {n:nat} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, n: int n) : void = begin if n >= THRESHOLD then let val i_pivot = partition (pf | A, n) val (pf_mul | ofs) = (size)i_pivot szmul2 sizeof prval (pf1, pf2) = array_v_split {T} (pf_mul, pf) prval (pf21, pf22) = array_v_uncons {T} (pf2) prval pf1_mul = mul_add_const {1} (pf_mul) val () = qsort_main (pf1 | A, i_pivot) and () = qsort_main (pf22 | A+ofs+sizeof, n-i_pivot-1) prval () = pf2 := array_v_cons {T} (pf21, pf22) prval () = pf := array_v_unsplit {T} (pf_mul, pf1, pf2) in // empty end else begin // empty end (* end of [if] *) end // end of [qsort] fun qsort {n:nat} {A:addr} (pf: !array_v (T, n, A) | A: ptr A, n: int n): void = begin qsort_main (pf | A, n); insort (pf | A, n) end // end of [qsort] (* ****** ****** *) (* end of [qsort_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/randcompec_mt.dats0000664000175000017500000001024612223166161022672 0ustar hwxihwxi// // randcompec_mt.dats: computing the Euler's constant via randomization // // Author: Chris Double (chris DOT double AT double DOT co DOT nz) // with minor tweaking by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: August, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload "libc/SATS/random.sats" staload "libc/SATS/unistd.sats" staload "libats/SATS/parworkshop.sats" staload _(*anon*) = "libats/DATS/parworkshop.dats" (* ****** ****** *) fn random_double (buf: &drand48_data): double = let var r: double val _ = drand48_r(buf, r) in r end fn attempts (buf: &drand48_data): uint = let fun loop (buf: &drand48_data, sum: double, count: uint): uint = if sum <= 1.0 then loop(buf, sum + random_double(buf), count + 1U) else count in loop(buf, 0.0, 0U) end fn n_attempts (n:int): ulint = let var buf: drand48_data val _ = srand48_r(0L, buf) fun loop (n:int, count: ulint, buf: &drand48_data): ulint = if n = 0 then count else loop(n-1, count + ulint_of(attempts(buf)), buf) in loop(n, 0UL, buf) end dataviewtype command = | {l:addr} Compute of (ulint @ l, ulint @ l - void | ptr l, int) | Quit of () // end of [command] viewtypedef work = command fun fwork {l:addr} (ws: !WORKSHOPptr(work,l), x: &work >> work?): int = case+ x of | ~Compute (pf_p, fpf_p | p, iterations) => let val () = !p := n_attempts (iterations) prval () = fpf_p (pf_p) // the view is returned to the scheduler in 1 end | ~Quit () => 0 // end of [fwork] fun insert_all {l,l2:agz} {n0:pos} ( pf_arr: !array_v(ulint, n0, l2) | ws: !WORKSHOPptr(work, l) , p_arr: ptr l2, n0: int n0, iterations0: int ) : void = let typedef T = ulint fun loop {l,l2:agz} {n:nat} .. ( pf: !array_v(ulint, n, l2) | ws: !WORKSHOPptr(work, l), p: ptr l2, n: int n, iterations: int ) : void = if n > 0 then let prval (pf1, pf2) = array_v_uncons{T}(pf) prval (pf_p, fpf_p) = __borrow(pf1) where { extern prfun __borrow {l:addr} (pf: !T @ l): (T @ l, T @ l - void) } // end of [prval] val () = workshop_insert_work(ws, Compute (pf_p, fpf_p | p, iterations)) val () = loop(pf2 | ws, p + sizeof, n - 1, iterations) prval () = pf := array_v_cons{T}(pf1, pf2) in // nothing end // end of [if] // end of [loop] in loop(pf_arr | ws, p_arr, n0, iterations0 / n0) end // end of [insert_all] (* ****** ****** *) #define NCPU0 1 #define ITER0 1000000 implement main (argc, argv) = let // val () = if (argc = 1) then ( prerr ("The command format: randcompec_mt \n"); exit(1) ) // end of [val] // var ITER: int = ITER0 // default val () = if (argc >= 2) then ITER := int_of (argv.[1]) val ITER = int1_of_int (ITER) // var NCPU: int = NCPU0 // default val () = if (argc >= 3) then NCPU := int_of (argv.[2]) val NCPU = int1_of_int (NCPU) // val () = assert_prerrf_bool1 (NCPU >= 1, "%s: NCPU = %i\n", @(#LOCATION, NCPU)) val () = assert_prerrf_bool1 (ITER >= NCPU, "%s: NCPU = %i\n", @(#LOCATION, ITER)) // val NCPUsz = size1_of_int1 (NCPU) val ws = workshop_make(NCPUsz, fwork) var ncpu: int = 0 val () = while (ncpu < NCPU) let val _err = workshop_add_worker(ws) val () = assert_prerrf_bool (_err = 0, "%s: [workshop_add_worker] failed\n", @(#LOCATION)) // end of [val] in ncpu := ncpu + 1 end // end of [val] // var !p_arr with pf_arr = @[ulint][NCPU](0UL) // val () = insert_all(pf_arr | ws, p_arr, NCPU, ITER) // val () = workshop_wait_blocked_all(ws) // var j: Nat = 0 val nworker = workshop_get_nworker(ws) // = NCPU val () = while (j < nworker) let val () = workshop_insert_work(ws, Quit ()) in j := j + 1 end // end of [val] val () = workshop_wait_quit_all(ws) val () = workshop_free_vt_exn(ws) // var k: Nat = 0 var total: ulint = 0UL val () = for (k := 0; k < NCPU; k := k + 1) total := total + p_arr->[k] val avg = double_of (total) / double_of (NCPU * (ITER / NCPU)) val () = (print "total = "; print total; print_newline ()) val () = print(avg) val () = print_newline () // in // nothing end // end of [main] (* ****** ****** *) (* end of [randomcompec_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/qsort_mt_flt.dats0000664000175000017500000001261212223166161022573 0ustar hwxihwxi// // qsort_mt_flt: // A plain multithreaded quicksort implementation // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) absviewtype work_vt viewtypedef WSptr (l:addr) = WORKSHOPptr (work_vt, l) viewtypedef work = {l:agz} (!WSptr l) - void extern castfn work_encode (x: work): work_vt (* ****** ****** *) typedef fwork_type (a:viewt@ype) = {l:agz} (!WSptr l, &a >> a?) -> int extern fun fwork : fwork_type (work) implement fwork (ws, wk) = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 2)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)2U then let prval () = opt_unsome {work} (wk) val () = wk (ws) val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) #define ARG_QUICKSORT_MT_DATS 1 (* absviewt@ype T extern fun lte_T_T (x: !T, y: !T):<> bool extern fun compare_T_T (x: !T, y: !T):<> Sgn overload compare with compare_T_T overload <= with lte_T_T *) typedef T = double (* ****** ****** *) #include "qsort_mt.dats" (* ****** ****** *) #define CUTOFF %(1 << 20) fun qsort_splt {lws:agz} {n:nat} {A:addr} (ws: !WSptr lws, A: ptr A, n: int n): void = let prval (pf, fpf) = __assert () where { extern prfun __assert (): (array_v (T, n, A), array_v (T, n, A) - void) } // end of [prval] in if n > CUTOFF then let val i_pivot = partition (pf | A, n) val (pf_mul | ofs) = (size)i_pivot szmul2 sizeof prval (pf1, pf2) = array_v_split {T} (pf_mul, pf) prval (pf21, pf22) = array_v_uncons {T} (pf2) prval pf1_mul = mul_add_const {1} (pf_mul) val () = workshop_insert_work (ws, f) where { val f = lam {l:agz} (ws: !WSptr l) : void = qsort_splt (ws, A, i_pivot) val f = work_encode (f) } // end of [val] val () = workshop_insert_work (ws, f) where { val f = lam {l:agz} (ws: !WSptr l) : void = qsort_splt (ws, A+ofs+sizeof, n-i_pivot-1) val f = work_encode (f) } // end of [val] prval () = pf2 := array_v_cons {T} (pf21, pf22) prval () = pf := array_v_unsplit {T} (pf_mul, pf1, pf2) prval () = fpf (pf) in // empty end else let val () = qsort (pf | A, n) prval () = fpf (pf) in // empty end (* end of [if] *) end // end of [qsort_splt] (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) fn array_ptr_print {n:nat} {l:addr} ( pf_arr: !array_v (T, n, l) | A: ptr l, n: size_t n ) : void = let var !p_f = @lam ( pf: !unit_v | i: sizeLt n, x: &T ) : void = begin $effmask_all (if i > 0 then print ", "; printf ("%.2f", @(x))) end // end of [var] prval pfu = unit_v () val () = array_ptr_iforeach_vclo (pfu | !A, !p_f, n) prval unit_v () = pfu in // nothing end // end of [array_ptr_print] (* ****** ****** *) #define N 100.0 fn random_array_ptr_gen {n:nat} (n: size_t n):<> [l:addr | l <> null] ( free_gc_v (T?, n, l), array_v (T, n, l) | ptr l ) = let val ( pfgc, pfarr | parr ) = array_ptr_alloc (n) val () = array_ptr_initialize_fun ( !parr, n, lam (i, x) = x := $effmask_all (N * $RAND.drand48 ()) ) // end of [array_ptr_initialize_fun] in (pfgc, pfarr | parr) end // end of [random_array_ptr_gen] (* ****** ****** *) fn prerr_usage (cmd: string): void = begin prerr ("Usage:\n"); prerrf (" single core: %s [integer]\n", @(cmd)); prerrf (" multiple core: %s [integer(arg)] [integer(core)]\n", @(cmd)); end // end of [prerr_usage] (* ****** ****** *) #define QSZ %(1 << 16) #define NWORKER 1 implement main (argc, argv) = let val () = assert_errmsg_bool1 (argc >= 2, "command format: qsort_mt_flt ") val n = int_of argv.[1] val n = int1_of_int (n) val () = assert_errmsg (n >= 0, #LOCATION) val fwork = __cast (fwork) where { extern castfn __cast (x: fwork_type work):<> fwork_type (work_vt) } // end of [val] val ws = workshop_make (QSZ, fwork) val nworker = (if (argc >= 3) then int_of argv.[2] else NWORKER): int val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) // val nsz = size1_of_int1 (n) val (pfgc, pfarr | A) = random_array_ptr_gen (nsz) val t = qsort_splt (ws, A, n) // val () = workshop_wait_blocked_all (ws) val () = if (n <= 100) then (array_ptr_print (pfarr | A, nsz); print_newline ()) val () = array_ptr_free {T?} (pfgc, pfarr | A) // var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work_vt, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) val () = (print "sorting is finished"; print_newline ()) val () = workshop_free_vt_exn (ws) in // nothing end // end of [main] (* ****** ****** *) (* end of [qsort_mt_flt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/nsieve_mt.dats0000664000175000017500000001254712223166161022056 0ustar hwxihwxi// // Time March 2010 // Author: Hongwei Xi (hwxi @ cs.bu.edu) // // // Erastothene's sieve // This is an excellent example showing the issue of memory bottleneck! // (* command: time nsieve_mt output: Primes up to 40960000 2488465 *) (* ****** ****** *) staload M = "libc/SATS/math.sats" (* ****** ****** *) staload "libc/SATS/pthread.sats" (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) macdef tt = int8_of_int (1) macdef ff = int8_of_int (0) (* ****** ****** *) typedef two = int8 extern fun sieve_once {m,limit:nat | limit <= m} {i,j:nat} {l:addr} ( pf: !array_v (two, m, l) | A: ptr l, limit: int limit, i: int i, j: int j ) : void = "sieve_once_safe" implement sieve_once (pf | A, limit, i, j) = begin if (j < limit) then begin (if A[j] <> ff then A[j] := ff; sieve_once (pf | A, limit, i, j+i)) end // end of [if] end // end of [sieve_once] extern fun sieve_once_unsafe (A: Ptr, limit: int, i: int, j: int): void = "sieve_once_safe" // end of [sieve_once_unsafe] extern fun sieve_many {m,m1,m2:nat | m1 <= m; m2 <= m} {i:nat} {l:addr} (pf: !array_v (two, m, l) | A: ptr l, m1: int m1, m2: int m2, i: int i): void = "sieve_many_safe" // end of [sieve_many] implement sieve_many (pf | p_A, m1, m2, i) = begin if i < m1 then let val () = if p_A->[i] = tt then sieve_once (pf | p_A, m2, i, i+i) in sieve_many (pf | p_A, m1, m2, i+1) end // end of [if] end // end of [sieve_many] fn sqrt_int {m:nat} (m: int m): Nat = let val m_sqrt = int_of_double ($M.sqrt (double_of m + 0.5)) val m_sqrt = int1_of_int m_sqrt val () = assert (m_sqrt >= 0) // redundant at run-time in m_sqrt end // end of [sqrt_int] (* ****** ****** *) viewtypedef work = () - void viewtypedef WSptr (l:addr) = WORKSHOPptr (work, l) (* ****** ****** *) fun fwork {lws:agz} (ws: !WSptr lws, wk: &work >> work?): int = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 2)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)2U then let prval () = opt_unsome {work} (wk) val () = wk () val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) fn nsieve_mt {lws:agz} (ws: !WSptr lws, m: int): void = let val [m:int] m = int1_of_int m // val () = assert_prerrf_bool1 ( m >= 2, "nsieve_mt(%i): argument is illegal; it must be positive.\n", @(m) ) // end of [val] // val msz = size1_of_int1 (m) val [la:addr] (pf_gc, pf | p_A) = array_ptr_alloc_tsz {two} (msz, sizeof) var x0 = tt val () = array_ptr_initialize_elt_tsz {two} (!p_A, msz, x0, sizeof) val m1 = sqrt_int (m) val [m1:int] m1 = (if m1 < m then m1 + 1 else m): natLte m val () = sieve_many (pf | p_A, m1, m1, 2) // find the all the primes upto [m1] // val () = split (pf | ws, p_A, m, m1, 2) where { // fun split {m,m1:nat | m1 <= m} {i:nat} ( pf: !array_v (two, m, la) | ws: !WSptr lws , p_A: ptr la , m: int m , m1: int m1 , i: int i ) : void = begin if i < m1 then let val () = if p_A->[i] = tt then let val () = workshop_insert_work (ws, f) where { val f = lam (): void = sieve_once_unsafe (p_A, m, i, i+i) } // end of [val] in // nothing end // end of [val] in split (pf | ws, p_A, m, m1, i+1) end // end of [if] end // end of [split] // } // val () = workshop_wait_blocked_all (ws) val nworker = workshop_get_nworker (ws) var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) // val count = loop (pf | 2, 0) where { fun loop {i:nat} (pf: !array_v (two, m, la) | i: int i, c: int): int = if i < m then begin if p_A->[i] = tt then loop (pf | i+1, c+1) else loop (pf | i+1, c) end else begin c // return value end } // end of [where] // val () = array_ptr_free {two?} (pf_gc, pf | p_A) in printf ("The number of primes < %8i is %8i\n", @(m, count)) end // end of [nsieve_mt] (* ****** ****** *) // dynload "libats/DATS/parworkshop.dats" // unnecessary (* ****** ****** *) #define QSZ 1024 // HX: arbitrarily choosen; should be >= 1 #define NWORKER 1 implement main (argc, argv) = let var nworker: int = NWORKER val () = assert_errmsg_bool1 ( argc >= 2, ": command format: nsieve_mt " ) val i = int1_of argv.[1] val () = assert_errmsg_bool1 ( i >= 2, "The input integer needs to be at least 2.\n" ) // end of [val] val () = if argc >= 3 then (nworker := int_of argv.[2]) // val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) // val ws = workshop_make (QSZ, fwork) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) // val () = nsieve_mt (ws, i) // val () = workshop_free_vt_exn (ws) in // nothing end // end of [main] (* ****** ****** *) (* end of [nsieve_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/Makefile0000664000175000017500000000555712223166161020653 0ustar hwxihwxi## ## A simple Makefile ## ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) ./*_?ats.html cleanall:: ; $(RMF) ./XREF/*.html ###### checkall:: fib_mt fib_mt: fib_mt.dats $(ATSCC) -o fib_mt -O3 -D_ATS_MULTITHREAD fib_mt.dats -lpthread cleanall:: ; $(RMF) fib_mt ###### checkall:: nsieve_mt nsieve_mt: nsieve_mt.dats $(ATSCC) -o nsieve_mt -O3 -D_ATS_MULTITHREAD nsieve_mt.dats -lm -lpthread cleanall:: ; $(RMF) nsieve_mt checkall:: nsieve2_mt nsieve2_mt: nsieve2_mt.dats $(ATSCC) -o nsieve2_mt -O3 -D_ATS_MULTITHREAD nsieve2_mt.dats -lm -lpthread cleanall:: ; $(RMF) nsieve2_mt ###### checkall:: partial-sums_mt partial-sums_mt: partial-sums_mt.dats $(ATSCC) -o partial-sums_mt -O3 -D_ATS_MULTITHREAD partial-sums_mt.dats -lm -lpthread cleanall:: ; $(RMF) partial-sums_mt ###### checkall:: qsort_mt_flt qsort_mt_flt: qsort_mt_flt.dats $(ATSCC) -o qsort_mt_flt -O3 -D_ATS_MULTITHREAD qsort_mt_flt.dats -lm -lpthread cleanall:: ; $(RMF) qsort_mt_flt checkall:: qsort_mt_int qsort_mt_int: qsort_mt_int.dats $(ATSCC) -o qsort_mt_int -O3 -D_ATS_MULTITHREAD qsort_mt_int.dats -lm -lpthread cleanall:: ; $(RMF) qsort_mt_int ###### checkall:: randcompec_mt randcompec_mt: randcompec_mt.dats $(ATSCC) -o randcompec_mt -O3 -D_ATS_MULTITHREAD randcompec_mt.dats -lpthread cleanall:: ; $(RMF) randcompec_mt checkall:: randcompec2_mt randcompec2_mt: randcompec2_mt.dats $(ATSCC) -o randcompec2_mt -O3 -D_ATS_MULTITHREAD randcompec2_mt.dats -lpthread cleanall:: ; $(RMF) randcompec2_mt checkall:: randcompec3_mt randcompec3_mt: randcompec3_mt.dats $(ATSCC) -o randcompec3_mt -O3 -D_ATS_MULTITHREAD randcompec3_mt.dats -lpthread cleanall:: ; $(RMF) randcompec3_mt ###### xref:: ; $(ATSOPT) --posmark_xref=XREF -d \ $(ATSHOME)/utils/xref/ats_prelude_xref.dats > /dev/null xref:: ; $(ATSOPT) --posmark_xref=XREF -d fib_mt.dats > fib_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d nsieve_mt.dats > nsieve_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d nsieve2_mt.dats > nsieve2_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d partial-sums_mt.dats > partial-sums_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d qsort_mt.dats > qsort_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d qsort_mt_int.dats > qsort_mt_int_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d qsort_mt_flt.dats > qsort_mt_flt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d randcompec_mt.dats > randcompec_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d randcompec2_mt.dats > randcompec2_mt_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d randcompec3_mt.dats > randcompec3_mt_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c $(RMF) *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/randcompec2_mt.dats0000664000175000017500000001131112223166161022746 0ustar hwxihwxi// // randcompec_mt.dats: computing the Euler's constant via randomization // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // modifying code by Chris Double (chris DOT double AT double DOT co DOT nz) // Time: the 6th of October, 2010 // (* ****** ****** *) // // HX-2010-10-06: // Per Shiv's request, I modified Chris Double's code to present // a simple method for passing proofs of views between a parent thread // and it single child. // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload "libc/SATS/pthread.sats" staload "libc/SATS/pthread_uplock.sats" staload "libc/SATS/random.sats" staload "libc/SATS/unistd.sats" staload "libats/SATS/parworkshop.sats" staload _(*anon*) = "libats/DATS/parworkshop.dats" (* ****** ****** *) fn random_double (buf: &drand48_data): double = let var r: double; val _ = drand48_r(buf, r) in r end // end of [random_double] fn attempts (buf: &drand48_data): uint = let fun loop (buf: &drand48_data, sum: double, count: uint): uint = if sum <= 1.0 then loop(buf, sum + random_double(buf), count + 1U) else count in loop(buf, 0.0, 0U) end // end of [attempts] fn n_attempts (n:int): ulint = let var buf: drand48_data val _ = srand48_r(0L, buf) fun loop (n:int, count: ulint, buf: &drand48_data): ulint = if n = 0 then count else loop(n-1, count + ulint_of(attempts(buf)), buf) in loop(n, 0UL, buf) end // end of [n_attempts] dataviewtype command = | {l:addr} Compute of (ulint @ l | ptr l, int, upticket (ulint @ l)) | Quit of () // end of [command] viewtypedef work = command fun fwork {l:addr} (ws: !WORKSHOPptr(work,l), x: &work >> work?): int = case+ x of | ~Compute ( pf | p, iterations, ticket ) => let val () = !p := n_attempts (iterations) val () = pthread_upticket_upload_and_destroy (pf | ticket) in 1 end | ~Quit () => 0 // end of [fwork] (* ****** ****** *) fun insert_all_and_wait {l,l2:agz} {n0:pos} ( pf_arr: !array_v(ulint, n0, l2) | ws: !WORKSHOPptr(work, l) , p_arr: ptr l2, n0: int n0, iterations0: int ) : void = let typedef T = ulint fun aux {l,l2:agz} {n:nat} .. ( // HX: not tail-recursive pf: !array_v(ulint, n, l2) | ws: !WORKSHOPptr(work, l), p: ptr l2, n: int n, iterations: int ) : void = if n > 0 then let viewdef V = ulint @ l2 prval (pf1, pf2) = array_v_uncons{T}(pf) val lock = pthread_uplock_create () val ticket = pthread_upticket_create {V} (lock) val () = workshop_insert_work(ws, Compute (pf1 | p, iterations, ticket)) val () = aux (pf2 | ws, p + sizeof, n - 1, iterations) val (pf1 | ()) = pthread_uplock_download {V} (lock) val () = pthread_uplock_destroy (lock) prval () = pf := array_v_cons{T}(pf1, pf2) in // nothing end // end of [if] // end of [aux] in aux (pf_arr | ws, p_arr, n0, iterations0 / n0) end // end of [insert_all_and_wait] (* ****** ****** *) #define NCPU0 1 #define ITER0 1000000 implement main (argc, argv) = let // val () = if (argc = 1) then ( prerr ("The command format: randcompec_mt \n"); exit(1) ) // end of [val] // var ITER: int = ITER0 // default val () = if (argc >= 2) then ITER := int_of (argv.[1]) val ITER = int1_of_int (ITER) // var NCPU: int = NCPU0 // default val () = if (argc >= 3) then NCPU := int_of (argv.[2]) val NCPU = int1_of_int (NCPU) // val () = assert_prerrf_bool1 (NCPU >= 1, "%s: NCPU = %i\n", @(#LOCATION, NCPU)) val () = assert_prerrf_bool1 (ITER >= NCPU, "%s: NCPU = %i\n", @(#LOCATION, ITER)) // val NCPUsz = size1_of_int1 (NCPU) val ws = workshop_make(NCPUsz, fwork) var ncpu: int = 0 val () = while (ncpu < NCPU) let val _err = workshop_add_worker(ws) val () = assert_prerrf_bool (_err = 0, "%s: [workshop_add_worker] failed\n", @(#LOCATION)) // end of [val] in ncpu := ncpu + 1 end // end of [val] // var !p_arr with pf_arr = @[ulint][NCPU](0UL) // val () = insert_all_and_wait (pf_arr | ws, p_arr, NCPU, ITER) // var k: Nat = 0 var total: ulint = 0UL val () = for (k := 0; k < NCPU; k := k + 1) total := total + p_arr->[k] val avg = double_of (total) / double_of (NCPU * (ITER / NCPU)) val () = (print "total = "; print total; print_newline ()) val () = print(avg) val () = print_newline () // // HX-2010-10-06: the following code is just for cleanup // val () = workshop_wait_blocked_all(ws) // var j: Nat = 0 val nworker = workshop_get_nworker(ws) val () = while (j < nworker) let val () = workshop_insert_work(ws, Quit ()) in j := j + 1 end // end of [val] val () = workshop_wait_quit_all(ws) val () = workshop_free_vt_exn(ws) // in // nothing end // end of [main] (* ****** ****** *) (* end of [randomcompec2_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/fib_mt.dats0000664000175000017500000000642112223166161021317 0ustar hwxihwxi// // fib_mt.dats: computing Fibonacci numbers // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) macdef int64 = int64_of_int fun fib (n: int, sum: &int64): void = if n >= 2 then let val () = fib (n-1, sum); val () = fib (n-2, sum) in // nothing end else sum := sum + (int64)n // end of [if // end of [fib] (* ****** ****** *) dataviewtype cont = | D of (cont, cont) | S of int64 // end of [cont] fun finalize (t: cont): int64 = case+ t of | ~D (t1, t2) => finalize t1 + finalize t2 | ~S sum => sum // end of [finalize] (* ****** ****** *) viewtypedef work = () - void viewtypedef WSptr (l:addr) = WORKSHOPptr (work, l) (* ****** ****** *) fun fwork {l:addr} (ws: !WSptr l, wk: &work >> work?): int = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 1)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)1U then let prval () = opt_unsome {work} (wk) val () = wk () val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) fun fib_split {l:agz} (N: int, ws: !WSptr l, n: int): cont = let in if n > N then let val cont1 = fib_split (N, ws, n-1) and cont2 = fib_split (N, ws, n-2) in D (cont1, cont2) end else let val res = S (?) val S (!p) = res val () = !p := (int64)0 extern prfun __ref {l:addr} (pf: !int64 @ l): int64 @ l prval pf = __ref (view@ !p) extern prfun __unref {l:addr} (pf: int64 @ l): void val f = lam (): void = let val () = fib (n, !p); prval () =__unref (pf) in (*empty*) end // val () = f () val () = workshop_insert_work (ws, f) in fold@ res; res end // end of [val] end // end of [fib_split] (* ****** ****** *) // dynload "libats/DATS/parworkshop.dats" // unnecessary (* ****** ****** *) #define QSZ 1024 #define NWORKER 1 implement main (argc, argv) = let val () = assert_errmsg_bool1 (argc >= 2, "command format: fib_mt ") val n = int_of argv.[1] val N = max (10, n - 16) val nworker = (if (argc >= 3) then int_of argv.[2] else NWORKER): int val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) val ws = workshop_make (QSZ, fwork) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) val t = fib_split (N, ws, n) // val () = (print "spliting is done"; print_newline ()) val () = workshop_wait_blocked_all (ws) val sum = finalize (t) var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) val () = workshop_free_vt_exn (ws) in print "fib("; print n; print ") = "; print sum; print_newline () end // end of [main] (* ****** ****** *) (* end of [fib_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/nsieve2_mt.dats0000664000175000017500000001516112223166161022133 0ustar hwxihwxi// // Time March 2010 // Author: Hongwei Xi (hwxi @ cs.bu.edu) // // // Erastothene's sieve // This is an excellent example showing the issue of memory bottleneck!!! // (* command: time nsieve2_mt output: Primes up to 40960000 2488465 *) (* ****** ****** *) staload M = "libc/SATS/math.sats" (* ****** ****** *) staload "libc/SATS/pthread.sats" (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) macdef tt = int8_of_int (1) macdef ff = int8_of_int (0) (* ****** ****** *) typedef two = int8 (* ****** ****** *) %{^ ATSinline() ats_int_type ceil2 (ats_int_type k, ats_int_type i) { int r = k % i ; if (r == 0) { return k ; } else { return (k + i - r) ; } // end of [if] } // end of [ceil2] %} // end of [%{^] extern fun ceil2 {k,i:nat | i > 0} (k: int k, i: int i): intGte k = "ceil2" (* ****** ****** *) extern fun sieve_once {m,limit:nat | limit <= m} {i,j:nat} {l:addr} (pf: !array_v (two, m, l) | A: ptr l, limit: int limit, i: int i, j: int j) : void = "sieve_once_safe" // end of [sieve_once] implement sieve_once (pf | A, limit, i, j) = begin if (j < limit) then begin (if A[j] <> ff then A[j] := ff; sieve_once (pf | A, limit, i, j+i)) end // end of [if] end // end of [sieve_once] extern fun sieve_many {m,m1,m2:nat | m1 <= m; m2 <= m} {l:addr} (pf: !array_v (two, m, l) | A: ptr l, m1: int m1, m2: int m2): void implement sieve_many (pf | p_A, m1, m2) = () where { var i: intGte 2 = 2 val () = while (i < m1) let val () = if p_A->[i] = tt then sieve_once (pf | p_A, m2, i, i+i) in i := i + 1 end // end of [while] } // end of [sieve_many] (* ****** ****** *) extern fun sieve_many_seg {m,m1,m2,m3:nat | m1 <= m; m2 <= m; m3 <= m} {l:addr} (pf: !array_v (two, m, l) | A: ptr l, m1: int m1, m2: int m2, m3: int m3): void = "sieve_many_seg_safe" extern fun sieve_many_seg_unsafe {m1,m2,m3:nat} {l:addr} (A: ptr l, m1: int m1, m2: int m2, m3: int m3): void = "sieve_many_seg_safe" implement sieve_many_seg (pf | p_A, m1, m2, m3) = () where { (* val () = (print "sieve_many_seg: m2 = "; print m2; print_newline ()) val () = (print "sieve_many_seg: m3 = "; print m3; print_newline ()) *) var i: intGte 2 = 2 val () = while (i < m1) let val () = if p_A->[i] = tt then let val j = ceil2 (m2, i) in sieve_once (pf | p_A, m3, i, j) end // end of [val] in i := i + 1 end // end of [val] } // end of [sieve_seg_many] (* ****** ****** *) fn sqrt_int {m:nat} (m: int m): Nat = let val m_sqrt = int_of_double ($M.sqrt (double_of m + 0.5)) val m_sqrt = int1_of_int m_sqrt val () = assert (m_sqrt >= 0) // redundant at run-time in m_sqrt end // end of [sqrt_int] (* ****** ****** *) viewtypedef work = () - void viewtypedef WSptr (l:addr) = WORKSHOPptr (work, l) (* ****** ****** *) fun fwork {lws:agz} (ws: !WSptr lws, wk: &work >> work?): int = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 2)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)2U then let prval () = opt_unsome {work} (wk) val () = wk () val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) fn nsieve_mt {lws:agz} {m:int | m >= 2} (ws: !WSptr lws, m: int m): void = let // val () = assert_prerrf_bool1 ( m >= 2, "nsieve_mt(%i): argument is illegal; it must be positive.\n", @(m) ) // end of [val] // val msz = size1_of_int1 (m) val [la:addr] (pf_gc, pf | p_A) = array_ptr_alloc_tsz {two?} (msz, sizeof) var x0 = tt val () = array_ptr_initialize_elt_tsz {two} (!p_A, msz, x0, sizeof) val m1 = sqrt_int (m) val [m1:int] m1 = (if m1 < m then m1 + 1 else m): natLte m val () = sieve_many (pf | p_A, m1, m1) // find the all the primes upto [m1] // #define INC %(1 << 16) // val () = split (pf | ws, p_A, m1, m, m1) where { // fun split {m1,m:nat | m1 <= m} {j:nat} ( pf: !array_v (two, m, la) | ws: !WSptr lws , p_A: ptr la , m1: int m1 , m: int m , j: int j ) : void = let val j1 = j + INC in if j1 < m then let val () = workshop_insert_work (ws, f) where { val f = lam (): void = sieve_many_seg_unsafe (p_A, m1, j, j1) } // end of [val] (* val () = sieve_many_seg_unsafe (p_A, m1, j, j1) *) in split (pf | ws, p_A, m1, m, j1) end else let val () = workshop_insert_work (ws, f) where { val f = lam (): void = sieve_many_seg_unsafe (p_A, m1, j, m) } // end of [val] (* val () = sieve_many_seg_unsafe (p_A, m1, j, m) *) in // nothing end // end of [if] end // end of [split] // } // val () = workshop_wait_blocked_all (ws) val nworker = workshop_get_nworker (ws) var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) // val count = loop (pf | 2, 0) where { fun loop {i:nat} (pf: !array_v (two, m, la) | i: int i, c: int): int = if i < m then begin if p_A->[i] = tt then loop (pf | i+1, c+1) else loop (pf | i+1, c) end else begin c // return value end // end of [loop] } // end of [where] // val () = array_ptr_free {two?} (pf_gc, pf | p_A) in printf ("The number of primes < %8i is %8i\n", @(m, count)) end // end of [nsieve_mt] (* ****** ****** *) // dynload "libats/DATS/parworkshop.dats" // unnecessary (* ****** ****** *) #define QSZ 1024 // HX: arbitrarily choosen; should be >= 1 #define NWORKER 1 implement main (argc, argv) = let var nworker: int = NWORKER val () = assert_errmsg_bool1 ( argc >= 2, ": command format: nsieve2_mt " ) val i = int1_of argv.[1] val () = assert_errmsg_bool1 ( i >= 2, "The input integer needs to be at least 2.\n" ) // end of [val] val () = if argc >= 3 then (nworker := int_of argv.[2]) // val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) // val ws = workshop_make (QSZ, fwork) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) // val () = nsieve_mt (ws, i) // val () = workshop_free_vt_exn (ws) in // nothing end // end of [main] (* ****** ****** *) (* end of [nsieve2_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/qsort_mt_int.dats0000664000175000017500000001261112223166161022577 0ustar hwxihwxi// // qsort_mt_int: // A plain multithreaded quicksort implementation // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) absviewtype work_vt viewtypedef WSptr (l:addr) = WORKSHOPptr (work_vt, l) viewtypedef work = {l:agz} (!WSptr l) - void extern castfn work_encode (x: work): work_vt (* ****** ****** *) typedef fwork_type (a:viewt@ype) = {l:agz} (!WSptr l, &a >> a?) -> int extern fun fwork : fwork_type (work) implement fwork (ws, wk) = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 2)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)2U then let prval () = opt_unsome {work} (wk) val () = wk (ws) val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) #define ARG_QUICKSORT_MT_DATS 1 (* absviewt@ype T extern fun lte_T_T (x: !T, y: !T):<> bool extern fun compare_T_T (x: !T, y: !T):<> Sgn overload compare with compare_T_T overload <= with lte_T_T *) typedef T = int (* ****** ****** *) #include "qsort_mt.dats" (* ****** ****** *) #define CUTOFF %(1 << 20) fun qsort_splt {lws:agz} {n:nat} {A:addr} (ws: !WSptr lws, A: ptr A, n: int n): void = let prval (pf, fpf) = __assert () where { extern prfun __assert (): (array_v (T, n, A), array_v (T, n, A) - void) } // end of [prval] in if n > CUTOFF then let val i_pivot = partition (pf | A, n) val (pf_mul | ofs) = (size)i_pivot szmul2 sizeof prval (pf1, pf2) = array_v_split {T} (pf_mul, pf) prval (pf21, pf22) = array_v_uncons {T} (pf2) prval pf1_mul = mul_add_const {1} (pf_mul) val () = workshop_insert_work (ws, f) where { val f = lam {l:agz} (ws: !WSptr l) : void = qsort_splt (ws, A, i_pivot) val f = work_encode (f) } // end of [val] val () = workshop_insert_work (ws, f) where { val f = lam {l:agz} (ws: !WSptr l) : void = qsort_splt (ws, A+ofs+sizeof, n-i_pivot-1) val f = work_encode (f) } // end of [val] prval () = pf2 := array_v_cons {T} (pf21, pf22) prval () = pf := array_v_unsplit {T} (pf_mul, pf1, pf2) prval () = fpf (pf) in // empty end else let val () = qsort (pf | A, n) prval () = fpf (pf) in // empty end (* end of [if] *) end // end of [qsort_splt] (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) fn array_ptr_print {n:nat} {l:addr} ( pf_arr: !array_v (T, n, l) | A: ptr l, n: size_t n ) : void = let var !p_f = @lam (pf: !unit_v | i: sizeLt n, x: &T): void = begin $effmask_all (if i > 0 then print ", "; printf ("%i", @(x))) end // end of [var] prval pfu = unit_v () val () = array_ptr_iforeach_vclo (pfu | !A, !p_f, n) prval unit_v () = pfu in // nothing end // end of [array_ptr_print] (* ****** ****** *) #define N 100000000 fn random_array_ptr_gen {n:nat} (n: size_t n):<> [l:addr | l <> null] ( free_gc_v (T?, n, l), array_v (T, n, l) | ptr l ) = let val ( pfgc, pfarr | parr ) = array_ptr_alloc (n) val () = array_ptr_initialize_fun ( !parr, n, lam (i, x) = x := $effmask_ref ($RAND.randint (N)) ) // end of [array_ptr_make_fun_tsz_cloptr] // in (pfgc, pfarr | parr) end // end of [random_array_ptr_gen] (* ****** ****** *) fn prerr_usage (cmd: string): void = begin prerr ("Usage:\n"); prerrf (" single core: %s [integer]\n", @(cmd)); prerrf (" multiple core: %s [integer(arg)] [integer(core)]\n", @(cmd)); end // end of [prerr_usage] (* ****** ****** *) #define QSZ %(1 << 16) #define NWORKER 1 implement main (argc, argv) = let val () = assert_errmsg_bool1 (argc >= 2, "command format: qsort_mt_int ") val n = int_of argv.[1] val n = int1_of_int (n) val () = assert_errmsg (n >= 0, #LOCATION) val fwork = __cast (fwork) where { extern castfn __cast (x: fwork_type work):<> fwork_type (work_vt) } // end of [val] val ws = workshop_make (QSZ, fwork) val nworker = (if (argc >= 3) then int_of argv.[2] else NWORKER): int val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) // val nsz = size1_of_int1 (n) val (pfgc, pfarr | A) = random_array_ptr_gen (nsz) val t = qsort_splt (ws, A, n) // val () = workshop_wait_blocked_all (ws) val () = if (n <= 100) then (array_ptr_print (pfarr | A, nsz); print_newline ()) val () = array_ptr_free {T?} (pfgc, pfarr | A) // var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work_vt, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) val () = (print "sorting is finished"; print_newline ()) val () = workshop_free_vt_exn (ws) in // nothing end // end of [main] (* ****** ****** *) (* end of [qsort_mt_int.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/partial-sums_mt.dats0000664000175000017500000000671112223166161023202 0ustar hwxihwxi// // partial-sums.dats: // computing partial sums of a power series // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload M = "libc/SATS/math.sats" (* ****** ****** *) staload "libc/SATS/pthread.sats" (* ****** ****** *) staload "libats/SATS/parworkshop.sats" staload _ = "libats/DATS/parworkshop.dats" (* ****** ****** *) fun loop (n: int, i: int, sum: &double): void = if i < n then let val () = sum := sum + $M.pow (2.0 / 3.0, double_of i) in loop (n, i+1, sum) end else () // end of [loop] (* ****** ****** *) dataviewtype ans = | D of (ans, ans) | S of double fun finalize (t: ans): double = case+ t of | ~D (t1, t2) => finalize t1 + finalize t2 | ~S sum => sum // end of [finalize] (* ****** ****** *) viewtypedef work = () - void viewtypedef WSptr (l:addr) = WORKSHOPptr (work, l) (* ****** ****** *) fun fwork {l:agz} (ws: !WSptr l, wk: &work >> work?): int = let val wk = wk val pfun = __cast (wk) where { extern castfn __cast (wk: !work >> opt (work, i >= 2)): #[i:nat] uintptr i } // end of [val] in if pfun >= (uintptr1_of_uint1)2U then let prval () = opt_unsome {work} (wk) val () = wk () val () = cloptr_free (wk) in 1 // the worker is to continue end else let val u = uint1_of_uintptr1 (pfun) val i = int_of_uint (u) prval () = opt_unnone {work} (wk) prval () = cleanup_top {work} (wk) in ~i // the worker is to pause or quit end // end of [if] end // end of [fwork] (* ****** ****** *) fun loop_split {l:agz} (NSPLIT: int, ws: !WSptr l, n: int, i: int): ans = let val ni = n - i in if ni > NSPLIT then let val ni2 = i + (ni / 2) val ans1 = loop_split (NSPLIT, ws, n, ni2) and ans2 = loop_split (NSPLIT, ws, ni2, i) in D (ans1, ans2) end else let val res = S (?) val S (!p) = res val () = !p := 0.0 extern prfun __ref {l:addr} (pf: !double @ l): double @ l prval pf = __ref (view@ !p) extern prfun __unref {l:addr} (pf: double @ l): void val f = lam (): void = let val () = loop (n, i, !p); prval () =__unref (pf) in (*empty*) end // val () = f () val () = workshop_insert_work (ws, f) in fold@ res; res end // end of [val] end // end of [loop_split] (* ****** ****** *) // dynload "libats/DATS/parworkshop.dats" // this no longer necessary (* ****** ****** *) #define QSZ 256 #define NWORKER 1 implement main (argc, argv) = let val () = assert_errmsg_bool1 (argc >= 2, "exit: wrong command format!\n") val n = int_of argv.[1] val ws = workshop_make (QSZ, fwork) val nworker = (if (argc >= 3) then int_of argv.[2] else NWORKER): int val nworker = int1_of_int (nworker) val () = assert_errmsg (nworker > 0, #LOCATION) val _err = workshop_add_nworker (ws, nworker) val () = assert_errmsg (_err = 0, #LOCATION) val N = max (1024, n / 1024) // threshold for splitting val t = loop_split (N, ws, n, 0) // val () = (print "spliting is done"; print_newline ()) val () = workshop_wait_blocked_all (ws) val sum = finalize (t) var i: Nat = 0 val () = while (i < nworker) let val _quit = $extval (work, "(void*)0") val () = workshop_insert_work (ws, _quit) in i := i + 1 end // end of [val] val () = workshop_wait_quit_all (ws) val () = workshop_free_vt_exn (ws) in printf ("%.9f\t(2/3)^k", @(sum)); print_newline (); end // end of [main] (* ****** ****** *) (* end of [partial-sums_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MULTICORE/randcompec3_mt.dats0000664000175000017500000001244112223166161022754 0ustar hwxihwxi// // randcompec_mt.dats: computing the Euler's constant via randomization // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // modifying code by Chris Double (chris DOT double AT double DOT co DOT nz) // Time: Thursday, the 7th of October, 2010 // (* ****** ****** *) // // HX-2010-10-07: // I modified Chris Double's code to present // a typical method (barrier) for passing proofs of views between // a parent thread and its (multiple) children. // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload "libc/SATS/pthread.sats" staload "libc/SATS/pthread_upbarr.sats" staload "libc/SATS/random.sats" staload "libc/SATS/unistd.sats" staload "libats/SATS/parworkshop.sats" staload _(*anon*) = "libats/DATS/parworkshop.dats" (* ****** ****** *) fn random_double (buf: &drand48_data): double = let var r: double; val _ = drand48_r(buf, r) in r end // end of [random_double] fn attempts (buf: &drand48_data): uint = let fun loop (buf: &drand48_data, sum: double, count: uint): uint = if sum <= 1.0 then loop(buf, sum + random_double(buf), count + 1U) else count in loop(buf, 0.0, 0U) end // end of [attempts] fn n_attempts (n:int): ulint = let var buf: drand48_data val _ = srand48_r(0L, buf) fun loop (n:int, count: ulint, buf: &drand48_data): ulint = if n = 0 then count else loop(n-1, count + ulint_of(attempts(buf)), buf) in loop(n, 0UL, buf) end // end of [n_attempts] dataviewtype command = | {l:addr} Compute of (ulint @ l | ptr l, int, upticket (ulint @ l)) | Quit of () // end of [command] viewtypedef work = command fun fwork {l:addr} (ws: !WORKSHOPptr(work,l), x: &work >> work?): int = case+ x of | ~Compute ( pf | p, iterations, ticket ) => let val () = !p := n_attempts (iterations) val () = pthread_upticket_upload_and_destroy (pf | ticket) in 1 end | ~Quit () => 0 // end of [fwork] (* ****** ****** *) fun insert_all {l,l2:agz} {n0:pos} ( pf_arr: array_v(ulint, n0, l2) | ws: !WORKSHOPptr(work, l) , p_arr: ptr l2, n0: int n0, iterations0: int ) : upbarr (array_v(ulint, n0, l2)) = let typedef T = ulint fun loop {v:view} {l,l2:agz} {n:nat} .. ( pf: array_v(ulint, n, l2) | ws: !WORKSHOPptr(work, l) , barr: !upbarr (v) >> upbarr @(v, array_v(ulint, n, l2)) , p: ptr l2, n: int n, iterations: int ) : void = let viewdef V = array_v (ulint, n, l2) in if n > 0 then let viewdef V1 = ulint @ l2 viewdef V2 = array_v (ulint, n-1, l2+sizeof(T)) viewdef v1 = @(v, V1) prval (pf1, pf2) = array_v_uncons{T}(pf) val ticket = pthread_upticket_create {v} {V1} (barr) val () = workshop_insert_work(ws, Compute (pf1 | p, iterations, ticket)) val () = loop {v1} (pf2 | ws, barr, p + sizeof, n - 1, iterations) prval fpf = lam (pf: @(v1,V2)): (v,V) = ((pf.0).0, array_v_cons{T} ((pf.0).1, pf.1)) // end of [prval] prval () = pthread_upbarr_trans (fpf | barr) in // nothing end else let prval () = array_v_unnil (pf) prval () = pthread_upbarr_trans {v} {(v,V)} (lam (pf) => (pf, array_v_nil {T} ()) | barr) in // nothing end // end of [if] end // end of [loop] val barr = pthread_upbarr_create () val () = loop (pf_arr | ws, barr, p_arr, n0, iterations0 / n0) prval () = pthread_upbarr_unitelim (barr) // HX: a convenience proof function in barr end // end of [insert_all] (* ****** ****** *) #define NCPU0 1 #define ITER0 1000000 implement main (argc, argv) = let // val () = if (argc = 1) then ( prerr ("The command format: randcompec_mt \n"); exit(1) ) // end of [val] // var ITER: int = ITER0 // default val () = if (argc >= 2) then ITER := int_of (argv.[1]) val ITER = int1_of_int (ITER) // var NCPU: int = NCPU0 // default val () = if (argc >= 3) then NCPU := int_of (argv.[2]) val NCPU = int1_of_int (NCPU) // val () = assert_prerrf_bool1 (NCPU >= 1, "%s: NCPU = %i\n", @(#LOCATION, NCPU)) val () = assert_prerrf_bool1 (ITER >= NCPU, "%s: NCPU = %i\n", @(#LOCATION, ITER)) // val NCPUsz = size1_of_int1 (NCPU) val ws = workshop_make(NCPUsz, fwork) var ncpu: int = 0 val () = while (ncpu < NCPU) let val _err = workshop_add_worker(ws) val () = assert_prerrf_bool (_err = 0, "%s: [workshop_add_worker] failed\n", @(#LOCATION)) // end of [val] in ncpu := ncpu + 1 end // end of [val] // var !p_arr with pf_arr = @[ulint][NCPU](0UL) // val barr = insert_all (pf_arr | ws, p_arr, NCPU, ITER) val (pf | ()) = pthread_upbarr_download_and_destroy (barr) prval () = pf_arr := pf // var k: Nat = 0 var total: ulint = 0UL val () = for (k := 0; k < NCPU; k := k + 1) total := total + p_arr->[k] val avg = double_of (total) / double_of (NCPU * (ITER / NCPU)) val () = (print "total = "; print total; print_newline ()) val () = print(avg) val () = print_newline () // // HX-2010-10-07: the following code is just for cleanup // val () = workshop_wait_blocked_all(ws) // var j: Nat = 0 val nworker = workshop_get_nworker(ws) val () = while (j < nworker) let val () = workshop_insert_work(ws, Quit ()) in j := j + 1 end // end of [val] val () = workshop_wait_quit_all(ws) val () = workshop_free_vt_exn(ws) // in // nothing end // end of [main] (* ****** ****** *) (* end of [randomcompec3_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/0000700000175000017500000000000012223166161016715 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/clip-all.dats0000664000175000017500000001462412223166161021312 0ustar hwxihwxi// // Cairo: Test clipping with everything clipped out // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) #define SIZE 10.0 #define CLIP_SIZE 2.0 (* ****** ****** *) macdef double = double_of_int fun draw {l:agz} ( cr: !cairo_ref l, width: int, height: int ) : void = () where { // val w = (double)width val h = (double)height val mn = min (w, h) val alpha = mn / SIZE // val () = cairo_translate (cr, (w - mn)/2, (h - mn)/2) val () = cairo_scale (cr, alpha, alpha) // val () = cairo_rectangle (cr, 0.0, 0.0, SIZE, SIZE) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 1.0) // blue color val () = cairo_fill (cr) // val () = cairo_reset_clip (cr) val () = cairo_rectangle (cr, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE) val () = cairo_clip (cr) val () = cairo_rectangle (cr, 3*CLIP_SIZE, 3*CLIP_SIZE, CLIP_SIZE, CLIP_SIZE) val () = cairo_clip (cr) // val () = cairo_translate (cr, 0.5, 0.5) val () = cairo_reset_clip (cr) val () = cairo_rectangle (cr, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE) val () = cairo_clip (cr) val () = cairo_rectangle (cr, 3*CLIP_SIZE, 3*CLIP_SIZE, CLIP_SIZE, CLIP_SIZE) val () = cairo_clip (cr) // val () = cairo_rectangle (cr, 0.0, 0.0, SIZE, SIZE) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 0.0) // yellow color val () = cairo_fill (cr) // val () = cairo_select_font_face ( cr, "Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL ) // end of [val] // val () = cairo_move_to (cr, 0.0, SIZE) val () = cairo_show_text (cr, "cairo") // } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: clip-all" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [clip-all.dats] *) //// /* * Copyright © 2005 Novell, Inc. * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without * fee, provided that the above copyright notice appear in all copies * and that both that copyright notice and this permission notice * appear in supporting documentation, and that the name of * Novell, Inc. not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Novell, Inc. makes no representations about the * suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * NOVELL, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS, IN NO EVENT SHALL NOVELL, INC. BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * Author: Radek Doulík */ #include "cairo-test.h" #define SIZE 10 #define CLIP_SIZE 2 static cairo_test_draw_function_t draw; static const cairo_test_t test = { "clip-all", "Test clipping with everything clipped out", SIZE, SIZE, draw }; static cairo_test_status_t draw (cairo_t *cr, int width, int height) { cairo_rectangle (cr, 0, 0, SIZE, SIZE); cairo_set_source_rgb (cr, 0, 0, 1); cairo_fill (cr); cairo_reset_clip (cr); cairo_rectangle (cr, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE); cairo_clip (cr); cairo_rectangle (cr, 3*CLIP_SIZE, 3*CLIP_SIZE, CLIP_SIZE, CLIP_SIZE); cairo_clip (cr); cairo_translate (cr, .5, .5); cairo_reset_clip (cr); cairo_rectangle (cr, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE, CLIP_SIZE); cairo_clip (cr); cairo_rectangle (cr, 3*CLIP_SIZE, 3*CLIP_SIZE, CLIP_SIZE, CLIP_SIZE); cairo_clip (cr); cairo_rectangle (cr, 0, 0, SIZE, SIZE); cairo_set_source_rgb (cr, 1, 1, 0); cairo_fill (cr); /* https://bugs.freedesktop.org/show_bug.cgi?id=13084 */ cairo_select_font_face (cr, "Bitstream Vera Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL); cairo_move_to (cr, 0., SIZE); cairo_show_text (cr, "cairo"); return CAIRO_TEST_SUCCESS; } int main (void) { return cairo_test (&test); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/stroke-image.dats0000664000175000017500000001555112223166161022204 0ustar hwxihwxi// // Cairo: Test stroke with an image source // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload MATH = "libc/SATS/math.sats" macdef PI = $MATH.M_PI macdef sin = $MATH.sin and cos = $MATH.cos (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) #define PAD 10 #define SIZE 100 #define IMAGE_SIZE (SIZE-PAD*2) #define LINE_WIDTH 10 (* ****** ****** *) macdef double = double_of_int fun draw {l:agz} ( cr: !cairo_ref l, width: int, height: int ) : void = () where { // val w = (double)width val h = (double)height val mn = min (w, h) val alpha = mn / SIZE // val () = cairo_translate (cr, (w - mn)/2, (h - mn)/2) val () = cairo_scale (cr, alpha, alpha) // val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val ()= cairo_paint (cr) val image = cairo_image_surface_create (CAIRO_FORMAT_RGB24, IMAGE_SIZE, IMAGE_SIZE) val cr_image = cairo_create (image) val () = cairo_surface_destroy (image) // Create the image val () = cairo_set_source_rgb (cr_image, 0.0, 0.0, 0.0) val () = cairo_paint (cr_image) val () = cairo_set_source_rgb (cr_image, 0.0, 1.0, 0.0) val () = cairo_set_line_width (cr_image, (double)LINE_WIDTH) val () = cairo_arc ( cr_image , (double)IMAGE_SIZE/2, (double)IMAGE_SIZE/2 , (double)IMAGE_SIZE/2 - (double)LINE_WIDTH/2 , 0.0, 2*PI ) // end of [val] val () = cairo_stroke (cr_image) // Now stroke with it val () = cairo_translate (cr, (double)PAD, (double)PAD) val (fpf_sf | sf) = cairo_get_target (cr_image) val () = cairo_set_source_surface (cr, sf, 0.0, 0.0) prval () = minus_addback (fpf_sf, sf | cr_image) val () = cairo_destroy (cr_image) // val () = cairo_new_path (cr) val () = cairo_set_line_width (cr, (double)LINE_WIDTH) val () = cairo_arc ( cr , (double)IMAGE_SIZE/2, (double)IMAGE_SIZE/2 , (double)IMAGE_SIZE/2 - (double)LINE_WIDTH/2 , 0.0, 2*PI ) // end of [val] val () = cairo_stroke (cr) } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: stroke-image" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [stroke-image.dats] *) //// /* * Copyright © 2006 Mozilla Corporation * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without * fee, provided that the above copyright notice appear in all copies * and that both that copyright notice and this permission notice * appear in supporting documentation, and that the name of * Mozilla Corporation not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Mozilla Corporation makes no representations about the * suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * MOZILLA CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS, IN NO EVENT SHALL MOZILLA CORPORATION BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * Author: Vladimir Vukicevic */ #include "cairo-test.h" static cairo_test_draw_function_t draw; #define PAD 10 #define SIZE 100 #define IMAGE_SIZE (SIZE-PAD*2) #define LINE_WIDTH 10 static const cairo_test_t test = { "stroke-image", "Test stroking with an image source, with a non-identity CTM", SIZE, SIZE, draw }; static cairo_test_status_t draw (cairo_t *cr, int width, int height) { cairo_surface_t *image; cairo_t *cr_image; cairo_set_source_rgb (cr, 0, 0, 0); cairo_paint (cr); image = cairo_image_surface_create (CAIRO_FORMAT_RGB24, IMAGE_SIZE, IMAGE_SIZE); cr_image = cairo_create (image); cairo_surface_destroy (image); /* Create the image */ cairo_set_source_rgb (cr_image, 0, 0, 0); cairo_paint (cr_image); cairo_set_source_rgb (cr_image, 0, 1, 0); cairo_set_line_width (cr_image, LINE_WIDTH); cairo_arc (cr_image, IMAGE_SIZE/2, IMAGE_SIZE/2, IMAGE_SIZE/2 - LINE_WIDTH/2, 0, M_PI * 2.0); cairo_stroke (cr_image); /* Now stroke with it */ cairo_translate (cr, PAD, PAD); cairo_set_source_surface (cr, cairo_get_target (cr_image), 0, 0); cairo_destroy (cr_image); cairo_new_path (cr); cairo_set_line_width (cr, LINE_WIDTH); cairo_arc (cr, IMAGE_SIZE/2, IMAGE_SIZE/2, IMAGE_SIZE/2 - LINE_WIDTH/2, 0, M_PI * 2.0); cairo_stroke (cr); return CAIRO_TEST_SUCCESS; } int main (void) { return cairo_test (&test); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/blurring.dats0000664000175000017500000000642312223166161021437 0ustar hwxihwxi// // Cairo: Test text transform // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) extern fun blur_image_surface {l:agz} {r:int} (sf: !cairo_surface_ref l, radius: int r): void = "blur_image_surface" // end of [blur_image_surface] fun draw {l:agz} (cr: !cairo_ref l, w: int, h: int): void = () where { // val mn = min (w, h) val PNGFILENAME = "data/romedalen.png" val image = cairo_image_surface_create_from_png (PNGFILENAME) val iw = cairo_image_surface_get_width (image) val iw = int1_of_int (iw) val ih = cairo_image_surface_get_height (image) val ih = int1_of_int (ih) val () = cairo_translate (cr, (w-iw)/2.0, (h-ih)/2.0) // val () = blur_image_surface (image, max(iw,ih)/2) // val () = cairo_set_source_surface (cr, image, 0.0, 0.0) val () = cairo_surface_destroy (image) val () = cairo_paint (cr) } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: blurring" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [blurring.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/Makefile0000664000175000017500000000311712223166161020373 0ustar hwxihwxi# # # Some Examples in ATS involving GTK+ programming # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### XRCFLAGS=`pkg-config cairo --cflags` GTKCLFLAGS=`pkg-config gtk+-2.0 --cflags --libs` ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: blurring cleanall:: ; $(RMF) blurring blurring: blurring.dats blur_image_surface_dats.o $(ATSCC) -o $@ blurring.dats blur_image_surface_dats.o $(GTKCLFLAGS) -lm blur_image_surface_dats.o: blur_image_surface.dats $(ATSCC) -c -o $@ blur_image_surface.dats $(XRCFLAGS) ###### checkall:: clip-all cleanall:: ; $(RMF) clip-all clip-all: clip-all.dats $(ATSCC) -o $@ clip-all.dats $(GTKCLFLAGS) ###### checkall:: push-group cleanall:: ; $(RMF) push-group push-group: push-group.dats $(ATSCC) -g -o $@ push-group.dats $(GTKCLFLAGS) ###### checkall:: stroke-image cleanall:: ; $(RMF) stroke-image stroke-image: stroke-image.dats $(ATSCC) -o $@ stroke-image.dats $(GTKCLFLAGS) ###### checkall:: testcairo cleanall:: ; $(RMF) testcairo testcairo: testcairo.dats $(ATSCC) -o $@ testcairo.dats $(GTKCLFLAGS) -lm ###### checkall:: text-rotate cleanall:: ; $(RMF) text-rotate text-rotate: text-rotate.dats $(ATSCC) -o $@ text-rotate.dats $(GTKCLFLAGS) -lm checkall:: text-transform cleanall:: ; $(RMF) text-transform text-transform: text-transform.dats $(ATSCC) -o $@ text-transform.dats $(GTKCLFLAGS) -lm ###### RMF=rm -f ###### clean:: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/text-transform.dats0000664000175000017500000001767712223166161022625 0ustar hwxihwxi// // Cairo: Test text transform // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) #define PAD 5.0 #define SIZE 100.0 #define FONT_SIZE 32.0 (* ****** ****** *) extern fun cairo_show_text0 {l:agz} (cr: !cairo_ref l, utf8: string): void = "mac#atsctrb_cairo_show_text" // end of [cairo_show_text] (* ****** ****** *) fun draw_text {l:agz} (cr: !cairo_ref l): void = () where { var tm: cairo_matrix_t // unintialized // // skew // val () = cairo_matrix_init (tm, 1., 0., ~0.25, 1., 0., 0.) val () = cairo_matrix_scale (tm, FONT_SIZE, FONT_SIZE) val () = cairo_set_font_matrix (cr, tm) val () = cairo_new_path (cr) val () = cairo_move_to (cr, 50., SIZE-PAD) val () = cairo_show_text0 (cr, "A") // // rotate and scale // val () = cairo_matrix_init_rotate (tm, M_PI / 2) val () = cairo_matrix_scale (tm, FONT_SIZE, 2*FONT_SIZE) val () = cairo_set_font_matrix (cr, tm) // val () = cairo_new_path (cr) val () = cairo_move_to (cr, PAD, PAD + 25) val () = cairo_show_text0 (cr, "A") // val () = cairo_matrix_init_rotate (tm, M_PI / 2) val () = cairo_matrix_scale (tm, FONT_SIZE * 2.0, FONT_SIZE) val () = cairo_set_font_matrix (cr, tm) // val () = cairo_new_path (cr) val () = cairo_move_to (cr, PAD, PAD + 50) val () = cairo_show_text0 (cr, "A") // } // end of [draw_text] (* ****** ****** *) fun draw {l:agz} (cr: !cairo_ref l, w: int, h: int): void = () where { // val mn = min (w, h) val alpha = mn/SIZE val () = cairo_translate (cr, (w-mn)/2., (h-mn)/2.) val () = cairo_scale (cr, alpha, alpha) // val () = cairo_set_source_rgb (cr, 1., 1., 1.) val () = cairo_paint (cr) val () = cairo_set_source_rgb (cr, 0., 0., 0.) val () = cairo_select_font_face ( cr, "Bitstream Vera Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL ) // end of [val] val () = draw_text (cr) val () = cairo_translate (cr, SIZE, SIZE) val () = cairo_rotate (cr, M_PI) // val PNGFILENAME = "DATA/romedalen.png" val image = cairo_image_surface_create_from_png (PNGFILENAME) val pattern = cairo_pattern_create_for_surface (image) val () = cairo_surface_destroy (image) val () = cairo_pattern_set_extend (pattern, CAIRO_EXTEND_REPEAT) val () = cairo_set_source (cr, pattern) val () = cairo_pattern_destroy (pattern) val () = draw_text (cr) } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: stroke-image" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [text-transform.dats] *) //// /* * Copyright © 2006 Mozilla Corporation * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without * fee, provided that the above copyright notice appear in all copies * and that both that copyright notice and this permission notice * appear in supporting documentation, and that the name of * Mozilla Corporation not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Mozilla Corporation makes no representations about the * suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * MOZILLA CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS, IN NO EVENT SHALL MOZILLA CORPORATION BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * Author: Vladimir Vukicevic */ #include "cairo-test.h" static cairo_test_draw_function_t draw; #define SIZE 100 #define PAD 5 #define FONT_SIZE 32.0 static const char png_filename[] = "romedalen.png"; static const cairo_test_t test = { "text-transform", "Test various applications of the font matrix", SIZE, SIZE, draw }; static void draw_text (cairo_t *cr) { cairo_matrix_t tm; /* skew */ cairo_matrix_init (&tm, 1, 0, -0.25, 1, 0, 0); cairo_matrix_scale (&tm, FONT_SIZE, FONT_SIZE); cairo_set_font_matrix (cr, &tm); cairo_new_path (cr); cairo_move_to (cr, 50, SIZE-PAD); cairo_show_text (cr, "A"); /* rotate and scale */ cairo_matrix_init_rotate (&tm, M_PI / 2); cairo_matrix_scale (&tm, FONT_SIZE, FONT_SIZE * 2.0); cairo_set_font_matrix (cr, &tm); cairo_new_path (cr); cairo_move_to (cr, PAD, PAD + 25); cairo_show_text (cr, "A"); cairo_matrix_init_rotate (&tm, M_PI / 2); cairo_matrix_scale (&tm, FONT_SIZE * 2.0, FONT_SIZE); cairo_set_font_matrix (cr, &tm); cairo_new_path (cr); cairo_move_to (cr, PAD, PAD + 50); cairo_show_text (cr, "A"); } static cairo_test_status_t draw (cairo_t *cr, int width, int height) { const cairo_test_context_t *ctx = cairo_test_get_context (cr); cairo_pattern_t *pattern; cairo_set_source_rgb (cr, 1., 1., 1.); cairo_paint (cr); cairo_set_source_rgb (cr, 0., 0., 0.); cairo_select_font_face (cr, "Bitstream Vera Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL); draw_text (cr); cairo_translate (cr, SIZE, SIZE); cairo_rotate (cr, M_PI); pattern = cairo_test_create_pattern_from_png (ctx, png_filename); cairo_pattern_set_extend (pattern, CAIRO_EXTEND_REPEAT); cairo_set_source (cr, pattern); cairo_pattern_destroy (pattern); draw_text (cr); return CAIRO_TEST_SUCCESS; } int main (void) { return cairo_test (&test); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/blur_image_surface.dats0000664000175000017500000003007612223166161023432 0ustar hwxihwxi(* ** ** Performing a simple 2D Gaussian blur ** The code is directly translated from on the attached C code ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May, 2010 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynloading (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload MATH = "libc/SATS/math.sats" (* ****** ****** *) %{^ // ATSinline() ats_ptr_type data_get_row ( ats_ptr_type data , ats_int_type stride , ats_int_type i ) { return &((ats_uint8_type*)data)[i*stride] ; } // end of [data_get_row] // ATSinline() ats_uint32_type data_get_elt ( ats_ptr_type data , ats_int_type stride , ats_int_type i , ats_int_type j ) { ats_ptr_type p = &((ats_uint8_type*)data)[i*stride] ; return ((ats_uint32_type*)p)[j] ; } // end of [data_get_elt] // %} // end of [%{^] (* ****** ****** *) typedef kernarr (n:int) = @[uint8][n] fun kernel_initialize {n:nat} ( kernel: &kernarr n? >> kernarr n, n: int n ) : void = () where { typedef a = uint8 prval pf = unit_v () val n2 = n / 2 var !p_clo = @lam (pf: !unit_v | i: sizeLt n, x: &a? >> a): void = let val i = int1_of_size1 (i) val f = double_of (i - n2) val d = 80 * $MATH.exp(~f*f/30) in x := uint8_of_uint(uint_of(int_of(d))) end // end of [var] val n = size1_of_int1 (n) val () = array_ptr_initialize_vclo (pf | kernel, n, !p_clo) prval unit_v () = pf } // end of [kernel_intialize] fun kernel_sum {n:nat}( kernel: &kernarr n, n: int n ) : uint = res where { var i: natLte n var res: uint = 0U val () = for (i := 0; i < n; i := i + 1) res := res + uint_of_uint8 (kernel.[i]) // end of [val] } // end of [kernel_sum] (* ****** ****** *) fun blur_hori_row {n:nat} {w,h:int} {i,j:nat | i < h; j <= w} .. ( kernel: &(@[uint8][n]) , a: uint // sum of [kernel] , s: &(@[uint32][w]), d: &(@[uint32][w]) , r1: int, r2: int, n: int n , w: int w, h: int h , i: int i, j: int j ) : void = if j < w then let val () = case+ 0 of | _ when (r1 < j andalso j < r2) => d.[j] := s.[j] | _ => () where { var x0: uint = 0U and x1: uint = 0U and x2: uint = 0U and x3: uint = 0U var k: natLte n val () = for (k := 0; k < n; k := k+1) let val j1 = j - n/2 + k in if :(k: natLt n) => j1 < 0 then () else if :(k: natLt n) => j1 >= w then () else let val p = s.[j1] val p = uint_of_uint32 (p) val kernel_k = uint_of_uint8 (kernel.[k]) val () = x0 := x0 + ((p >> 24) land 0XffU) * kernel_k val () = x1 := x1 + ((p >> 16) land 0XffU) * kernel_k val () = x2 := x2 + ((p >> 8) land 0XffU) * kernel_k val () = x3 := x3 + ((p >> 0) land 0XffU) * kernel_k in // nothing end // end of [if] // end of [if] end // end of [val] val x = (x0 / a << 24) lor (x1 / a << 16) lor (x2 / a << 8) lor x3 / a val () = d.[j] := (uint32_of_uint)x } // end of [_] in blur_hori_row (kernel, a, s, d, r1, r2, n, w, h, i, j + 1) end // end of [if] // end of [blur_hori_row] (* ****** ****** *) fun blur_vert_row {n:nat} {w,h:int} {i,j:nat | i < h; j <= w} {l:addr} .. ( kernel: &(@[uint8][n]) , a: uint // sum of [kernel] , data: ptr l, stride: int , s: &(@[uint32][w]), d: &(@[uint32][w]) , r1: int, r2: int, n: int n , w: int w, h: int h , i: int i, j: int j ) : void = let extern fun data_get_elt (data: ptr, stride: int, i: natLt h, j: natLt w): uint32 = "data_get_elt" in // in of [let] if j < w then let val () = case+ 0 of | _ when (r1 <= i andalso i < r2) => d.[j] := s.[j] | _ => () where { var x0: uint = 0U and x1: uint = 0U and x2: uint = 0U and x3: uint = 0U var k: natLte n val () = for (k := 0; k < n; k := k+1) let val i1 = i - n/2 + k in if :(k: natLt n) => i1 < 0 then () else if :(k: natLt n) => i1 >= h then () else let val p = data_get_elt (data, stride, i1, j) val p = uint_of_uint32 (p) val kernel_k = uint_of_uint8 (kernel.[k]) val () = x0 := x0 + ((p >> 24) land 0XffU) * kernel_k val () = x1 := x1 + ((p >> 16) land 0XffU) * kernel_k val () = x2 := x2 + ((p >> 8) land 0XffU) * kernel_k val () = x3 := x3 + ((p >> 0) land 0XffU) * kernel_k in // nothing end // end of [if] // end of [if] end // end of [val] val x = (x0 / a << 24) lor (x1 / a << 16) lor (x2 / a << 8) lor x3 / a val () = d.[j] := (uint32_of_uint)x } // end of [_] in blur_vert_row (kernel, a, data, stride, s, d, r1, r2, n, w, h, i, j + 1) end // end of [if] end // end of [blur_vert_row] (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" extern fun blur_image_surface {l:agz} {r:int} (sf: !cairo_surface_ref l, radius: int r): void = "blur_image_surface" // end of [blur_image_surface] (* ****** ****** *) fun blur_image_surface_main {l1,l2:agz} {r:int} {w,h:nat} ( sf1: !cairo_surface_ref l1 , sf2: !cairo_surface_ref l2 , r: int r, w: int w, h: int h ) : void = () where { // extern fun data_get_row {i:nat | i < h} (data: ptr, stride: int, i: int i) : [l:addr] (@[uint32][w] @ l, @[uint32][w] @ l - void | ptr l) = "data_get_row" // end of [extern] // val n = 17 var !p_kernel = @[uint8][n]() val () = kernel_initialize (!p_kernel, n) val a = kernel_sum (!p_kernel, n) // val data1 = cairo_image_surface_get_data (sf1) val stride1 = cairo_image_surface_get_stride (sf1) val data2 = cairo_image_surface_get_data (sf2) val stride2 = cairo_image_surface_get_stride (sf2) var i: natLte h // (* val () = (print "w = "; print w; print_newline ()) val () = (print "h = "; print h; print_newline ()) val () = (print "stride1 = "; print stride1; print_newline ()) val () = (print "stride2 = "; print stride2; print_newline ()) *) // val () = for (i := 0; i < h; i := i + 1) let // val () = (print "i = "; print i; print_newline ()) val (pf_s, fpf_s | p_s) = data_get_row (data1, stride1, i) val (pf_d, fpf_d | p_d) = data_get_row (data2, stride2, i) val () = blur_hori_row ( !p_kernel, a, !p_s, !p_d, r, w-r, n, w, h, i, 0 ) // end of [val] prval () = fpf_s (pf_s) and () = fpf_d (pf_d) in // nothing end // end of [val] // val () = for (i := 0; i < h; i := i + 1) let val (pf_s, fpf_s | p_s) = data_get_row (data2, stride2, i) val (pf_d, fpf_d | p_d) = data_get_row (data1, stride1, i) val () = blur_vert_row ( !p_kernel, a, data2, stride2, !p_s, !p_d, r, h-r, n, w, h, i, 0 ) // end of [val] prval () = fpf_s (pf_s) and () = fpf_d (pf_d) in // nothing end // end of [val] // } // end of [blur_image_surface_main] (* ****** ****** *) implement blur_image_surface (sf, r) = let val status = cairo_surface_status (sf) in case+ 0 of | _ when status = CAIRO_STATUS_SUCCESS => // let val fmt = cairo_image_surface_get_format (sf) val w = let val w = cairo_image_surface_get_width (sf) val w = int1_of_int (w) in if fmt = CAIRO_FORMAT_A1 then 0 else if fmt = CAIRO_FORMAT_A8 then w / 4 else w end : Int // end of [val] val h = cairo_image_surface_get_height (sf) val h = int1_of_int (h) in if (w > 0 && h > 0) then let val sf_tmp = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, w, h) val status = cairo_surface_status (sf) in if (status = CAIRO_STATUS_SUCCESS) then let val () = blur_image_surface_main (sf, sf_tmp, r, w, h) val () = cairo_surface_destroy (sf_tmp) val () = cairo_surface_mark_dirty (sf) in // nothing end else let val () = cairo_surface_destroy (sf_tmp) in // nothing end // end of [if] end (* end of [if] *) end // end of [CAIRO_STATUS_SUCCESS] | _ (* erroneous surface *) => () end // end of [blur_image_surface] (* ****** ****** *) (* end of [blur_image_surface.dats] *) //// /* * Copyright © 2008 Kristian Høgsberg * Copyright © 2009 Chris Wilson * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that * the above copyright notice appear in all copies and that both that copyright * notice and this permission notice appear in supporting documentation, and * that the name of the copyright holders not be used in advertising or * publicity pertaining to distribution of the software without specific, * written prior permission. The copyright holders make no representations * about the suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE * OF THIS SOFTWARE. */ #include #include #define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0]) /* Performs a simple 2D Gaussian blur of radius @radius on surface @surface. */ void blur_image_surface (cairo_surface_t *surface, int radius) { cairo_surface_t *tmp; int width, height; int src_stride, dst_stride; int x, y, z, w; uint8_t *src, *dst; uint32_t *s, *d, a, p; int i, j, k; uint8_t kernel[17]; const int size = ARRAY_LENGTH (kernel); const int half = size / 2; if (cairo_surface_status (surface)) return; width = cairo_image_surface_get_width (surface); height = cairo_image_surface_get_height (surface); switch (cairo_image_surface_get_format (surface)) { case CAIRO_FORMAT_A1: default: /* Don't even think about it! */ return; case CAIRO_FORMAT_A8: /* Handle a8 surfaces by effectively unrolling the loops by a * factor of 4 - this is safe since we know that stride has to be a * multiple of uint32_t. */ width /= 4; break; case CAIRO_FORMAT_RGB24: case CAIRO_FORMAT_ARGB32: break; } tmp = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, width, height); if (cairo_surface_status (tmp)) return; src = cairo_image_surface_get_data (surface); src_stride = cairo_image_surface_get_stride (surface); dst = cairo_image_surface_get_data (tmp); dst_stride = cairo_image_surface_get_stride (tmp); a = 0; for (i = 0; i < size; i++) { double f = i - half; a += kernel[i] = exp (- f * f / 30.0) * 80; } /* Horizontally blur from surface -> tmp */ for (i = 0; i < height; i++) { s = (uint32_t *) (src + i * src_stride); d = (uint32_t *) (dst + i * dst_stride); for (j = 0; j < width; j++) { if (radius < j && j < width - radius) { d[j] = s[j]; continue; } x = y = z = w = 0; for (k = 0; k < size; k++) { if (j - half + k < 0 || j - half + k >= width) continue; p = s[j - half + k]; x += ((p >> 24) & 0xff) * kernel[k]; y += ((p >> 16) & 0xff) * kernel[k]; z += ((p >> 8) & 0xff) * kernel[k]; w += ((p >> 0) & 0xff) * kernel[k]; } d[j] = (x / a << 24) | (y / a << 16) | (z / a << 8) | w / a; } } /* Then vertically blur from tmp -> surface */ for (i = 0; i < height; i++) { s = (uint32_t *) (dst + i * dst_stride); d = (uint32_t *) (src + i * src_stride); for (j = 0; j < width; j++) { if (radius <= i && i < height - radius) { d[j] = s[j]; continue; } x = y = z = w = 0; for (k = 0; k < size; k++) { if (i - half + k < 0 || i - half + k >= height) continue; s = (uint32_t *) (dst + (i - half + k) * dst_stride); p = s[j]; x += ((p >> 24) & 0xff) * kernel[k]; y += ((p >> 16) & 0xff) * kernel[k]; z += ((p >> 8) & 0xff) * kernel[k]; w += ((p >> 0) & 0xff) * kernel[k]; } d[j] = (x / a << 24) | (y / a << 16) | (z / a << 8) | w / a; } } cairo_surface_destroy (tmp); cairo_surface_mark_dirty (surface); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/text-rotate.dats0000664000175000017500000002410212223166161022065 0ustar hwxihwxi// // Cairo: Test text rotation // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) #define WIDTH 150.0 #define HEIGHT 150.0 #define NUM_TEXT 20 #define TEXT_SIZE 12.0 (* ****** ****** *) fun draw {l:agz} ( cr: !cairo_ref l, width: int, height: int ) : void = () where { // val xalpha = width/WIDTH val yalpha = height/HEIGHT val () = cairo_scale (cr, xalpha, yalpha) // val text = "cairo" val () = cairo_set_source_rgb (cr, 1., 1., 1.) val () = cairo_paint (cr) val () = cairo_select_font_face ( cr, "Bitstream Vera Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL ) // end of [val] val () = cairo_set_font_size (cr, TEXT_SIZE) val font_options = cairo_font_options_create () val () = cairo_get_font_options (cr, font_options) val () = cairo_font_options_set_hint_metrics (font_options, CAIRO_HINT_METRICS_OFF) val () = cairo_set_font_options (cr, font_options) val () = cairo_font_options_destroy (font_options) val () = cairo_set_source_rgb (cr, 0., 0., 0.) val () = cairo_translate (cr, WIDTH/2.0, HEIGHT/2.0) var extents: cairo_text_extents_t val () = cairo_text_extents (cr, text, extents) var x_off: double and y_off: double val () = if (NUM_TEXT = 1) then let val () = x_off := 0.0 and () = y_off := 0.0 in // nothing end else let val () = x_off := floor (0.5 + (extents.height+1) / (2 * tan (M_PI/NUM_TEXT))) val () = y_off := ~floor (0.5 + extents.height / 2.0) in // nothing end // end of [if] var i: int // uninitialized val () = for (i := 0; i < NUM_TEXT; i := i+1) let val (pf_save | ()) = cairo_save (cr) val () = cairo_rotate (cr, 2*M_PI*i/NUM_TEXT) val () = cairo_set_line_width (cr, 1.0) val () = cairo_rectangle (cr, x_off - 0.5, y_off - 0.5, extents.width + 1, extents.height + 1) val () = cairo_set_source_rgb (cr, 1., 0., 0.) val () = cairo_stroke (cr) val () = cairo_move_to (cr, x_off - extents.x_bearing, y_off - extents.y_bearing) val () = cairo_set_source_rgb (cr, 0., 0., 0.) val () = cairo_text_path (cr, text) val () = cairo_fill (cr) val () = cairo_restore (pf_save | cr) in // nothing end // end of [val] } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: stroke-image" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [text-rotate.dats] *) //// /* * Copyright © 2004 Red Hat, Inc. * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without * fee, provided that the above copyright notice appear in all copies * and that both that copyright notice and this permission notice * appear in supporting documentation, and that the name of * Red Hat, Inc. not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Red Hat, Inc. makes no representations about the * suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * RED HAT, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS, IN NO EVENT SHALL RED HAT, INC. BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * Author: Carl D. Worth */ /* Bug history * * 2004-11-03 Steve Chaplin * * Reported bug on mailing list: * * From: Steve Chaplin * To: cairo@cairographics.org * Date: Thu, 04 Nov 2004 00:00:17 +0800 * Subject: [cairo] Rotated text bug on drawable target * * The attached file draws text rotated 90 degrees first to a PNG file and * then to a drawable. The PNG file looks fine, the text on the drawable is * unreadable. * * Steve * * 2004-11-03 Carl Worth * * Looks like the major problems with this bug appeared in the great * font rework between 0.1.23 and 0.2.0. And it looks like we need * to fix the regression test suite to test the xlib target (since * the bug does not show up in the png backend). * * Hmm... Actually, things don't look perfect even in the PNG * output. Look at how that 'o' moves around. It's particularly off * in the case where it's rotated by PI. * * And I'm still not sure about what to do for test cases with * text--a new version of freetype will change everything. We may * need to add a simple backend for stroked fonts and add a simple * builtin font to cairo for pixel-perfect tests with text. * * 2005-08-23 * * It appears that the worst placement and glyph selection problems * have now been resolved. In the past some letters were noticeably * of a different size at some rotations, and there was a lot of * drift away from the baseline. These problems do not appear * anymore. * * Another thing that helps is that we now have font options which * we can use to disable hinting in order to get more repeatable * results. I'm doing that in this test now. * * There are still some subtle positioning problems which I'm * assuming are due to the lack of finer-than-whole-pixel glyph * positioning. I'm generating a reference image now by replacing * cairo_show_text with cairo_text_path; cairo_fill. This will let * us look more closely at the remaining positioning problems. (In * particular, I want to make sure we're rounding as well as * possible). * * 2007-02-21 * * Seems like all the "bugs" have been fixed and all remainint is * missing support for subpixel glyph positioning. Removing from * XFAIL now. */ #include "cairo-test.h" #define WIDTH 150 #define HEIGHT 150 #define NUM_TEXT 20 #define TEXT_SIZE 12 static cairo_test_draw_function_t draw; static const cairo_test_t test = { "text-rotate", "Tests show_text under various rotations", WIDTH, HEIGHT, draw }; /* Draw the word cairo at NUM_TEXT different angles */ static cairo_test_status_t draw (cairo_t *cr, int width, int height) { int i, x_off, y_off; cairo_text_extents_t extents; cairo_font_options_t *font_options; const char text[] = "cairo"; /* paint white so we don't need separate ref images for * RGB24 and ARGB32 */ cairo_set_source_rgb (cr, 1., 1., 1.); cairo_paint (cr); cairo_select_font_face (cr, "Bitstream Vera Sans", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL); cairo_set_font_size (cr, TEXT_SIZE); font_options = cairo_font_options_create (); cairo_get_font_options (cr, font_options); cairo_font_options_set_hint_metrics (font_options, CAIRO_HINT_METRICS_OFF); cairo_set_font_options (cr, font_options); cairo_font_options_destroy (font_options); cairo_set_source_rgb (cr, 0, 0, 0); cairo_translate (cr, WIDTH/2.0, HEIGHT/2.0); cairo_text_extents (cr, text, &extents); if (NUM_TEXT == 1) { x_off = y_off = 0; } else { y_off = - floor (0.5 + extents.height / 2.0); x_off = floor (0.5 + (extents.height+1) / (2 * tan (M_PI/NUM_TEXT))); } for (i=0; i < NUM_TEXT; i++) { cairo_save (cr); cairo_rotate (cr, 2*M_PI*i/NUM_TEXT); cairo_set_line_width (cr, 1.0); cairo_rectangle (cr, x_off - 0.5, y_off - 0.5, extents.width + 1, extents.height + 1); cairo_set_source_rgb (cr, 1, 0, 0); cairo_stroke (cr); cairo_move_to (cr, x_off - extents.x_bearing, y_off - extents.y_bearing); cairo_set_source_rgb (cr, 0, 0, 0); #if CAIRO_TEST_GENERATE_REFERENCE_IMAGE cairo_text_path (cr, text); cairo_fill (cr); #else cairo_show_text (cr, text); #endif cairo_restore (cr); } return CAIRO_TEST_SUCCESS; } int main (void) { return cairo_test (&test); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/push-group.dats0000664000175000017500000002323412223166161021723 0ustar hwxihwxi// // Cairo: Test cairo_push_group // The code is directly translated from on the attached C code // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2010 // (* ****** ****** *) staload MATH = "libc/SATS/math.sats" macdef PI = $MATH.M_PI (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) #define UNIT_SIZE 100.0 #define PAD 5.0 #define INNER_PAD 10.0 #define WIDTH (UNIT_SIZE + PAD) + PAD #define HEIGHT (UNIT_SIZE + PAD) + PAD (* ****** ****** *) macdef double = double_of_int (* ****** ****** *) fun draw {l:agz} ( cr: !cairo_ref l, width: int, height: int ) : void = () where { // val w = (double)width val h = (double)height val xalpha = w / WIDTH val yalpha = h / HEIGHT // (* // // HX: 2010-05-17: // cairo_scale (cr, xalpha, yalpha) cannot be called here! it looks // like a bug in cairo. // val () = (print "xalpha = "; print xalpha; print_newline ()) val () = (print "yalpha = "; print yalpha; print_newline ()) *) // val gradient = cairo_pattern_create_linear (UNIT_SIZE - 2*INNER_PAD, 0.0, UNIT_SIZE - 2*INNER_PAD, UNIT_SIZE - 2*INNER_PAD) val () = cairo_pattern_add_color_stop_rgba (gradient, 0.0, 0.3, 0.3, 0.3, 1.0) val () = cairo_pattern_add_color_stop_rgba (gradient, 1.0, 1.0, 1.0, 1.0, 1.0) // var j: int // uninitalized val () = for (j := 0; j < 1; j := j + 1) let var i: int // unintialized val () = for (i := 0; i < 1; i := i + 1) let val (pf1 | ()) = cairo_save (cr) val x = (i * UNIT_SIZE) + (i + 1) * PAD val y = (j * UNIT_SIZE) + (j + 1) * PAD val () = cairo_translate (cr, xalpha * x, yalpha * y) // draw a gradient background val (pf2 | ()) = cairo_save (cr) val () = cairo_scale (cr, xalpha, yalpha) val () = cairo_translate (cr, INNER_PAD, INNER_PAD) val () = cairo_new_path (cr) val () = cairo_rectangle (cr, 0.0, 0.0, UNIT_SIZE - 2*INNER_PAD, UNIT_SIZE - 2*INNER_PAD) val () = cairo_set_source (cr, gradient) val () = cairo_fill (cr) val () = cairo_restore (pf2 | cr) // val (pf2 | ()) = cairo_save (cr) val () = cairo_scale (cr, xalpha, yalpha) val () = cairo_rectangle (cr, 0.0, 0.0, UNIT_SIZE, UNIT_SIZE) val () = cairo_clip (cr) val () = cairo_rectangle (cr, 0.0, 0.0, UNIT_SIZE, UNIT_SIZE) val () = cairo_set_source_rgba (cr, 0.0, 0.0, 0.0, 1.0) val () = cairo_set_line_width (cr, 2.0) val () = cairo_stroke (cr) val () = cairo_restore (pf2 | cr) // // testing [cairo_push_group] // val (pf2 | ()) = cairo_push_group (cr) // val () = cairo_scale (cr, xalpha, yalpha) // // draw a diamond // val () = cairo_move_to (cr, UNIT_SIZE / 2, 0.0); val () = cairo_line_to (cr, UNIT_SIZE, UNIT_SIZE / 2); val () = cairo_line_to (cr, UNIT_SIZE / 2, UNIT_SIZE) val () = cairo_line_to (cr, 0.0, UNIT_SIZE / 2) val () = cairo_close_path (cr) val () = cairo_set_source_rgba (cr, 0.0, 0.0, 1.0, 1.0) val () = cairo_fill (cr) // // draw a circle // val () = cairo_arc ( cr, UNIT_SIZE / 2, UNIT_SIZE / 2, UNIT_SIZE / 3.5, 0.0, 2*PI ) // end of [val] val () = cairo_set_source_rgba (cr, 1.0, 0.0, 0.0, 1.0) val () = cairo_fill (cr) // val () = cairo_pop_group_to_source (pf2 | cr) // val () = cairo_paint_with_alpha (cr, 0.5) val () = cairo_restore (pf1 | cr) in // nothing end // end of [val] in // nothing end // end of [val] // val () = cairo_pattern_destroy (gradient) // } // end of [draw] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: Knockout Groups" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [push-group.dats] *) //// /* * Copyright © 2005 Mozilla Corporation * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without * fee, provided that the above copyright notice appear in all copies * and that both that copyright notice and this permission notice * appear in supporting documentation, and that the name of * Mozilla Corporation not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Mozilla Corporation makes no representations about the * suitability of this software for any purpose. It is provided "as * is" without express or implied warranty. * * MOZILLA CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS, IN NO EVENT SHALL MOZILLA CORPORATION BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * Author: Vladimir Vukicevic */ #include "cairo-test.h" #define UNIT_SIZE 100 #define PAD 5 #define INNER_PAD 10 #define WIDTH (UNIT_SIZE + PAD) + PAD #define HEIGHT (UNIT_SIZE + PAD) + PAD static cairo_test_draw_function_t draw; static const cairo_test_t test = { "push-group", "Verify that cairo_push_group works.", WIDTH, HEIGHT, draw }; static cairo_test_status_t draw (cairo_t *cr, int width, int height) { cairo_pattern_t *gradient; int i, j; gradient = cairo_pattern_create_linear (UNIT_SIZE - (INNER_PAD*2), 0, UNIT_SIZE - (INNER_PAD*2), UNIT_SIZE - (INNER_PAD*2)); cairo_pattern_add_color_stop_rgba (gradient, 0.0, 0.3, 0.3, 0.3, 1.0); cairo_pattern_add_color_stop_rgba (gradient, 1.0, 1.0, 1.0, 1.0, 1.0); for (j = 0; j < 1; j++) { for (i = 0; i < 1; i++) { double x = (i * UNIT_SIZE) + (i + 1) * PAD; double y = (j * UNIT_SIZE) + (j + 1) * PAD; cairo_save (cr); cairo_translate (cr, x, y); /* draw a gradient background */ cairo_save (cr); cairo_translate (cr, INNER_PAD, INNER_PAD); cairo_new_path (cr); cairo_rectangle (cr, 0, 0, UNIT_SIZE - (INNER_PAD*2), UNIT_SIZE - (INNER_PAD*2)); cairo_set_source (cr, gradient); cairo_fill (cr); cairo_restore (cr); /* clip to the unit size */ cairo_rectangle (cr, 0, 0, UNIT_SIZE, UNIT_SIZE); cairo_clip (cr); cairo_rectangle (cr, 0, 0, UNIT_SIZE, UNIT_SIZE); cairo_set_source_rgba (cr, 0, 0, 0, 1); cairo_set_line_width (cr, 2); cairo_stroke (cr); /* start a group */ cairo_push_group (cr); /* draw diamond */ cairo_move_to (cr, UNIT_SIZE / 2, 0); cairo_line_to (cr, UNIT_SIZE , UNIT_SIZE / 2); cairo_line_to (cr, UNIT_SIZE / 2, UNIT_SIZE); cairo_line_to (cr, 0 , UNIT_SIZE / 2); cairo_close_path (cr); cairo_set_source_rgba (cr, 0, 0, 1, 1); cairo_fill (cr); /* draw circle */ cairo_arc (cr, UNIT_SIZE / 2, UNIT_SIZE / 2, UNIT_SIZE / 3.5, 0, M_PI * 2); cairo_set_source_rgba (cr, 1, 0, 0, 1); cairo_fill (cr); cairo_pop_group_to_source (cr); cairo_paint_with_alpha (cr, 0.5); cairo_restore (cr); } } cairo_pattern_destroy (gradient); return CAIRO_TEST_SUCCESS; } int main (void) { return cairo_test (&test); } ats-lang-anairiats-0.2.11/doc/EXAMPLE/cairo/testcairo.dats0000664000175000017500000003142612223166161021611 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) staload MATH = "libc/SATS/math.sats" macdef PI = $MATH.M_PI macdef sin = $MATH.sin and cos = $MATH.cos (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) fun oval_path {l:agz} ( cr: !cairo_ref l , xc: double, yc: double , xr: double, yr: double ) : void = () where { val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, xc, yc) val () = cairo_scale (cr, 1.0, yr / xr) val () = cairo_move_to (cr, xr, 0.0) val () = cairo_arc (cr, 0.0, 0.0, xr, 0.0, 2 * PI) val () = cairo_close_path (cr) val () = cairo_restore (pf | cr) } // end of [oval_path] (* ****** ****** *) #define CHECK_SIZE 32 #define fCHECK_SIZE 32.0 fun fill_checks {l:agz} ( cr: !cairo_ref l, x: int, y: int, width: int, height: int ) : void = () where { #define i2d double_of_int val () = cairo_rectangle (cr, (i2d)x, (i2d)y, (i2d)width, (i2d)height) val () = cairo_set_source_rgb (cr, 0.4, 0.4, 0.4) val () = cairo_fill (cr) val x0 = x mod CHECK_SIZE and y0 = y mod CHECK_SIZE val () = loop1 (cr, y0, 0) where { fun loop1 (cr: !cairo_ref l, y: int, b: int): void = if y < height then let val () = loop2 (cr, y, x0, b) in loop1 (cr, y+CHECK_SIZE, 1-b) end // end of [if] // end of [loop1] and loop2 (cr: !cairo_ref l, y: int, x: int, b: int): void = if x < width then let val () = if (b > 0) then cairo_rectangle (cr, (i2d)x, (i2d)y, fCHECK_SIZE, fCHECK_SIZE) in loop2 (cr, y, x + CHECK_SIZE, 1-b) end // end of [if] // end of [loop2] } // end of [val] val () = cairo_set_source_rgb (cr, 0.7, 0.7, 0.7) val () = cairo_fill (cr) } // end of [fill_checks] (* ****** ****** *) fun draw_3circles {l:agz} ( cr: !cairo_ref l, xc: double, yc: double, radius: double, alpha: double ) : void = () where { // val subradius = radius * (2 / 3. - 0.1) // val () = cairo_set_source_rgba (cr, 1., 0., 0., alpha) val () = oval_path ( cr , xc + radius / 3. * cos (PI * (0.5)) , yc - radius / 3. * sin (PI * (0.5)) , subradius, subradius ) // end of [val] val () = cairo_fill (cr) // val () = cairo_set_source_rgba (cr, 0., 1., 0., alpha) val () = oval_path ( cr , xc + radius / 3. * cos (PI * (0.5 + 2/0.3)) , yc - radius / 3. * sin (PI * (0.5 + 2/0.3)) , subradius, subradius ) // end of [val] val () = cairo_fill (cr) // val () = cairo_set_source_rgba (cr, 0., 0., 1., alpha); val () = oval_path ( cr , xc + radius / 3. * cos (PI * (0.5 + 4/0.3)) , yc - radius / 3. * sin (PI * (0.5 + 4/0.3)) , subradius, subradius ) // end of [val] val () = cairo_fill (cr) // } // end of [draw_3circles] (* ****** ****** *) extern fun draw_main {l:agz} (cr: !cairo_ref l, width: int, height: int) : void = "draw_main" implement draw_main (cr, width, height) = () where { val w = (double_of)width val h = (double_of)height val radius = min (w, h) / 2 - 10 val xc = w / 2 and yc = h / 2 val (fpf_sf | sf) = cairo_get_target (cr) val overlay = cairo_surface_create_similar (sf, CAIRO_CONTENT_COLOR_ALPHA, width, height) val punch = cairo_surface_create_similar (sf, CAIRO_CONTENT_ALPHA, width, height) val circles = cairo_surface_create_similar (sf, CAIRO_CONTENT_COLOR_ALPHA, width, height) prval () = minus_addback (fpf_sf, sf | cr) val () = fill_checks (cr, 0, 0, width, height) // val cr_overlay = cairo_create (overlay) val () = cairo_set_source_rgb (cr_overlay, 0., 0., 0.) val () = oval_path (cr_overlay, xc, yc, radius, radius) val () = cairo_fill (cr_overlay) // val cr_punch = cairo_create (punch); val () = draw_3circles (cr_punch, xc, yc, radius, 1.0) val () = cairo_destroy (cr_punch) // val () = cairo_set_operator (cr_overlay, CAIRO_OPERATOR_DEST_OUT) val () = cairo_set_source_surface (cr_overlay, punch, 0.0, 0.0) val () = cairo_paint (cr_overlay) // val cr_circles = cairo_create (circles) val () = cairo_set_operator (cr_circles, CAIRO_OPERATOR_OVER) val () = draw_3circles (cr_circles, xc, yc, radius, 0.5) val () = cairo_destroy (cr_circles) // val () = cairo_set_operator (cr_overlay, CAIRO_OPERATOR_ADD) val () = cairo_set_source_surface (cr_overlay, circles, 0.0, 0.0) val () = cairo_paint (cr_overlay) // val () = cairo_destroy (cr_overlay) val () = cairo_set_source_surface (cr, overlay, 0.0, 0.0) val () = cairo_paint (cr) // val () = cairo_surface_destroy (overlay) val () = cairo_surface_destroy (punch) val () = cairo_surface_destroy (circles) } // end of [draw_main] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun on_expose_event {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw_main (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [on_expose_event] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"cairo: Knockout Groups" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (on_expose_event), (gpointer)null) val () = g_object_unref (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [val] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [testcairo.dats] *) //// /* testimage.c * Copyright (C) 2005 Red Hat, Inc. * Based on cairo-demo/X11/cairo-knockout.c * * Author: Owen Taylor * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #include #include static void oval_path (cairo_t *cr, double xc, double yc, double xr, double yr) { cairo_save (cr); cairo_translate (cr, xc, yc); cairo_scale (cr, 1.0, yr / xr); cairo_move_to (cr, xr, 0.0); cairo_arc (cr, 0, 0, xr, 0, 2 * G_PI); cairo_close_path (cr); cairo_restore (cr); } /* Create a path that is a circular oval with radii xr, yr at xc, * yc. */ /* Fill the given area with checks in the standard style * for showing compositing effects. * * It would make sense to do this as a repeating surface, * but most implementations of RENDER currently have broken * implementations of repeat + transform, even when the * transform is a translation. */ static void fill_checks (cairo_t *cr, int x, int y, int width, int height) { int i, j; #define CHECK_SIZE 32 cairo_rectangle (cr, x, y, width, height); cairo_set_source_rgb (cr, 0.4, 0.4, 0.4); cairo_fill (cr); /* Only works for CHECK_SIZE a power of 2 */ j = x & (-CHECK_SIZE); for (; j < height; j += CHECK_SIZE) { i = y & (-CHECK_SIZE); for (; i < width; i += CHECK_SIZE) if ((i / CHECK_SIZE + j / CHECK_SIZE) % 2 == 0) cairo_rectangle (cr, i, j, CHECK_SIZE, CHECK_SIZE); } cairo_set_source_rgb (cr, 0.7, 0.7, 0.7); cairo_fill (cr); } /* Draw a red, green, and blue circle equally spaced inside * the larger circle of radius r at (xc, yc) */ static void draw_3circles (cairo_t *cr, double xc, double yc, double radius, double alpha) { double subradius = radius * (2 / 3. - 0.1); cairo_set_source_rgba (cr, 1., 0., 0., alpha); oval_path (cr, xc + radius / 3. * cos (G_PI * (0.5)), yc - radius / 3. * sin (G_PI * (0.5)), subradius, subradius); cairo_fill (cr); cairo_set_source_rgba (cr, 0., 1., 0., alpha); oval_path (cr, xc + radius / 3. * cos (G_PI * (0.5 + 2/.3)), yc - radius / 3. * sin (G_PI * (0.5 + 2/.3)), subradius, subradius); cairo_fill (cr); cairo_set_source_rgba (cr, 0., 0., 1., alpha); oval_path (cr, xc + radius / 3. * cos (G_PI * (0.5 + 4/.3)), yc - radius / 3. * sin (G_PI * (0.5 + 4/.3)), subradius, subradius); cairo_fill (cr); } static void draw (cairo_t *cr, int width, int height) { cairo_surface_t *overlay, *punch, *circles; cairo_t *overlay_cr, *punch_cr, *circles_cr; /* Fill the background */ double radius = 0.5 * (width < height ? width : height) - 10; double xc = width / 2.; double yc = height / 2.; overlay = cairo_surface_create_similar (cairo_get_target (cr), CAIRO_CONTENT_COLOR_ALPHA, width, height); if (overlay == NULL) return; punch = cairo_surface_create_similar (cairo_get_target (cr), CAIRO_CONTENT_ALPHA, width, height); if (punch == NULL) return; circles = cairo_surface_create_similar (cairo_get_target (cr), CAIRO_CONTENT_COLOR_ALPHA, width, height); if (circles == NULL) return; fill_checks (cr, 0, 0, width, height); /* Draw a black circle on the overlay */ overlay_cr = cairo_create (overlay); cairo_set_source_rgb (overlay_cr, 0., 0., 0.); oval_path (overlay_cr, xc, yc, radius, radius); cairo_fill (overlay_cr); /* Draw 3 circles to the punch surface, then cut * that out of the main circle in the overlay */ punch_cr = cairo_create (punch); draw_3circles (punch_cr, xc, yc, radius, 1.0); cairo_destroy (punch_cr); cairo_set_operator (overlay_cr, CAIRO_OPERATOR_DEST_OUT); cairo_set_source_surface (overlay_cr, punch, 0, 0); cairo_paint (overlay_cr); /* Now draw the 3 circles in a subgroup again * at half intensity, and use OperatorAdd to join up * without seams. */ circles_cr = cairo_create (circles); cairo_set_operator (circles_cr, CAIRO_OPERATOR_OVER); draw_3circles (circles_cr, xc, yc, radius, 0.5); cairo_destroy (circles_cr); cairo_set_operator (overlay_cr, CAIRO_OPERATOR_ADD); cairo_set_source_surface (overlay_cr, circles, 0, 0); cairo_paint (overlay_cr); cairo_destroy (overlay_cr); cairo_set_source_surface (cr, overlay, 0, 0); cairo_paint (cr); cairo_surface_destroy (overlay); cairo_surface_destroy (punch); cairo_surface_destroy (circles); } static gboolean on_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer data) { cairo_t *cr; cr = gdk_cairo_create (widget->window); draw (cr, widget->allocation.width, widget->allocation.height); cairo_destroy (cr); return FALSE; } int main (int argc, char **argv) { GtkWidget *window, *darea; gtk_init (&argc, &argv); window = gtk_window_new (GTK_WINDOW_TOPLEVEL); gtk_window_set_default_size (GTK_WINDOW (window), 400, 400); gtk_window_set_title (GTK_WINDOW (window), "cairo: Knockout Groups"); darea = gtk_drawing_area_new (); gtk_container_add (GTK_CONTAINER (window), darea); g_signal_connect (darea, "expose-event", G_CALLBACK (on_expose_event), NULL); g_signal_connect (window, "destroy-event", G_CALLBACK (gtk_main_quit), NULL); gtk_widget_show_all (window); gtk_main (); return 0; } ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/0000700000175000017500000000000012223166161016513 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fact_in_c.dats0000664000175000017500000000205712223166161021315 0ustar hwxihwxi// // // This example shows how C code can be included in ATS programs // Author: Hongwei Xi (August 2007) // // (* ****** ****** *) // // How to compile: // atscc -o fact_in_c -O3 fact_in_c.dats // How to test: // ./fact_in_c // (* ****** ****** *) %{ ats_int_type fact_in_c (ats_int_type n) { int res = 1; while (n > 0) res *= n-- ; return res ; } %} extern fun fact {n:nat} (n: int n): Nat = "fact_in_c" // [fn] declares a non-recursive function // [@(...)] is used in ATS to group arguments for functions of variable arguments fn fact_usage (cmd: string): void = prerrf ("Usage: %s [integer]\n", @(cmd)) // print an error message implement main (argc, argv) = begin if argc >= 2 then let val n = int1_of argv.[1] // turning string into integer val () = assert_errmsg (n >= 0, "The integer argument needs to be nonnegative.\n") val res = fact n in printf ("factorial of %i = %i\n", @(n, res)) end else begin fact_usage (argv.[0]); exit (1) end end // end of [main] (* ****** ****** *) (* end of [fact_in_c.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/HelloWorld.dats0000664000175000017500000000050712223166161021461 0ustar hwxihwxi// // Author: Hongwei Xi (August 2007) // (* ****** ****** *) // // How to compile: // atscc -o HelloWorld HelloWorld.dats // How to test: // ./HelloWorld // (* ****** ****** *) implement main () = begin print ("Hello, world!"); print_newline () end // end of [main] (* ****** ****** *) (* end of [HelloWorld.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/tally.dats0000664000175000017500000000212512223166161020531 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) // imperative style fun tally1 (n: int): int = let var i: int // uninitialized var res: int = 0 in for (i := 1; i <= n; i := i + 1) res := res + i; res end // end of [tally] // functional style fun tally2 (n: Nat): int = loop (0, n, 1) where { fun loop (res: int, n: int, i: int): int = if i <= n then loop (res + i, n, i + 1) else res } // end of [tally2] implement main () = let val ans1 = tally1 (100) val ans2 = tally2 (100) // // HX: functions defined through fixed-point expressions // val ans3 = tally3 (100) where { val tally3 = fix f(n: Nat): int => if n > 0 then n + f(n-1) else 0 } // end of [val] // val ans4 = !p_clo(100) where { var !p_clo = @fix f {n:nat} (n: int n): intGte(0) = if n > 0 then n + f(n-1) else 0 } // end of [val] in printf ("tally(100) = %i\n", @(ans1)); printf ("tally(100) = %i\n", @(ans2)); printf ("tally(100) = %i\n", @(ans3)); printf ("tally(100) = %i\n", @(ans4)); end // end of [main] (* ****** ****** *) (* end of [tally.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/Makefile0000664000175000017500000000664512223166161020202 0ustar hwxihwxi# # # Some introductory examples written in ATS # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) ./XREF/* cleanall:: ; $(RMF) *_?ats.html ###### checkall:: HelloWorld cleanall:: ; $(RMF) HelloWorld HelloWorld: HelloWorld.dats $(ATSCC) -o HelloWorld HelloWorld.dats && ./HelloWorld checkall:: f91 cleanall:: ; $(RMF) f91 f91: f91.dats $(ATSCC) -o f91 f91.dats && ./f91 0 checkall:: fact1 cleanall:: ; $(RMF) fact1 fact1: fact1.dats $(ATSCC) -o fact1 fact1.dats && ./fact1 10 checkall:: fact2 cleanall:: ; $(RMF) fact2 fact2: fact2.dats $(ATSCC) -o fact2 fact2.dats && ./fact2 10 checkall:: fact3 cleanall:: ; $(RMF) fact3 fact3: fact3.dats $(ATSCC) -D_ATS_PROOFCHECK -o fact3 fact3.dats -lats -lgmp && ./fact3 100 checkall:: fact4 cleanall:: ; $(RMF) fact4 fact4: fact4.dats $(ATSCC) -D_ATS_PROOFCHECK -o fact4 fact4.dats -lats -lgmp && ./fact4 10 checkall:: fact_in_c cleanall:: ; $(RMF) fact_in_c fact_in_c: fact_in_c.dats $(ATSCC) -o fact_in_c fact_in_c.dats && ./fact_in_c 10 checkall:: fibs cleanall:: ; $(RMF) fibs fibs: fibs.dats $(ATSCC) -o fibs fibs.dats -lats -lgmp && ./fibs 20 checkall:: revarr cleanall:: ; $(RMF) revarr revarr: revarr.dats $(ATSCC) -o revarr revarr.dats && ./revarr checkall:: revstr cleanall:: ; $(RMF) revstr revstr: revstr.dats $(ATSCC) -o revstr revstr.dats && ./revstr "abcdefghijklmnopqrstuvwxyz" checkall:: tally cleanall:: ; $(RMF) tally tally: tally.dats $(ATSCC) -o tally tally.dats -lats && ./tally ###### html:: ; $(ATSOPT) --posmark_html -d HelloWorld.dats > HelloWorld_dats.html html:: ; $(ATSOPT) --posmark_html -d f91.dats > f91_dats.html html:: ; $(ATSOPT) --posmark_html -d fact1.dats > fact1_dats.html html:: ; $(ATSOPT) --posmark_html -d fact2.dats > fact2_dats.html html:: ; $(ATSOPT) --posmark_html -d fact3.dats > fact3_dats.html html:: html_fact4 html_fact4: ; $(ATSOPT) --posmark_html -d fact4.dats > fact4_dats.html html:: ; $(ATSOPT) --posmark_html -d fact_in_c.dats > fact_in_c_dats.html html:: ; $(ATSOPT) --posmark_html -d fibs.dats > fibs_dats.html html:: ; $(ATSOPT) --posmark_html -d revarr.dats > revarr_dats.html html:: ; $(ATSOPT) --posmark_html -d revstr.dats > revstr_dats.html html:: ; $(ATSOPT) --posmark_html -d tally.dats > tally_dats.html ###### xref:: ; $(ATSOPT) --posmark_xref=XREF -d \ $(ATSHOME)/utils/xref/ats_prelude_xref.dats > /dev/null xref:: ; $(ATSOPT) --posmark_xref=XREF -d HelloWorld.dats > HelloWorld_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d f91.dats > f91_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d fact1.dats > fact1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d fact2.dats > fact2_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d fact3.dats > fact3_dats.html xref:: xref_fact4 xref_fact4: ; $(ATSOPT) --posmark_xref=XREF -d fact4.dats > fact4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d fact_in_c.dats > fact_in_c_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d fibs.dats > fibs_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d revarr.dats > revarr_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d revstr.dats > revstr_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d tally.dats > tally_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) ./INTRO/* $(RMF) *_dats.c *_sats.c ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/revstr.dats0000664000175000017500000000270312223166161020733 0ustar hwxihwxi// // A simple example for illustrating some benefits of dependent types // (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) // // How to compile: // atscc -o revstr revstr.dats // How to test: // ./revstr // (* ****** ****** *) extern fun revstr {m,n:nat} {l:addr} (pf: !strbuf (m, n) @ l | p: ptr l):<> void // end of [revstr] implement revstr {m,n} {l} (pf | p) = loop (pf | p, 0, n) where { val n = strbuf_length (!p) fun loop {i,j:nat | i <= n; i + j == n} .. (pf: !strbuf (m, n) @ l | p: ptr l, i: size_t i, j: size_t j) :<> void = if i < j then let val j1 = j-1 val ci = strbuf_get_char_at (!p, i) val cj = strbuf_get_char_at (!p, j1) val () = strbuf_set_char_at (!p, j1, ci) val () = strbuf_set_char_at (!p, i, cj) in loop (pf | p, i+1, j-1) end // end of [if] } // end of [revstr] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val str = argv.[1] val str = string1_of_string (str) val () = begin print "str = "; print str; print_newline () end // end of [val] val (pfbox | p) = strbuf_of_string1 (str) val () = let prval vbox pf = pfbox in revstr (pf | p) end // end of [val] val () = begin print "str = "; print str; print_newline () end // end of [val] in // empty end // end of [main] (* ****** ****** *) (* end of [revstr.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fibs.dats0000664000175000017500000000567712223166161020346 0ustar hwxihwxi// // // Some implementations of the Fibonacci function // Author: Hongwei Xi (September, 2007) // (* ****** ****** *) // // How to compile: // atscc -o fibs fibs.dats -lats -lgmp // How to test: // ./fibs // (* ****** ****** *) fun fib1 (x: int): int = if x > 1 then fib1 (x-1) + fib1 (x-2) else x // end of [fib1] (* ****** ****** *) fun fib2 (x: Nat): Nat = if x > 1 then fib2 (x-1) + fib2 (x-2) else x // end of [fib2] (* ****** ****** *) fun fib3 (x: Nat): Nat = loop (x, 0, 1) where { fun loop (x: Nat, a0: Nat, a1: Nat): Nat = if x > 0 then loop (x-1, a1, a0 + a1) else a0 } // end of [where] (* ****** ****** *) dataprop FIB (int, int) = | FIB_bas_0 (0, 0) | FIB_bas_1 (1, 1) | {i:nat} {r0,r1:int} FIB_ind (i+2, r0+r1) of (FIB (i, r0), FIB (i+1, r1)) // end of [FIB] fun fib4 {n:nat} (x: int n): [r:int] (FIB (n, r) | int r) = let fun loop {i,j:nat | i+j == n} {r0,r1:int} (pf0: FIB (j, r0), pf1: FIB (j+1, r1) | x: int i, a0: int r0, a1: int r1) : [r:int] (FIB (n, r) | int r) = if x > 0 then loop (pf1, FIB_ind (pf0, pf1) | x-1, a1, a0 + a1) else (pf0 | a0) in loop (FIB_bas_0 (), FIB_bas_1 () | x, 0, 1) end // end of [fib4] (* ****** ****** *) staload "libats/SATS/intinf.sats" dynload "libats/DATS/intinf.dats" (* ****** ****** *) fun fib5 {n:nat} (x: int n) : [r:int] (FIB (n, r) | intinf r) = let fun loop {i,j:nat | i+j==n} {r0,r1:int} ( pf0: FIB (j, r0), pf1: FIB (j+1, r1) | x: int i, a0: intinf r0, a1: intinf r1 ) : [r:int] (FIB (n, r) | intinf r) = if x > 0 then let val a2 = a0 + a1 val () = intinf_free (a0) in loop (pf1, FIB_ind (pf0, pf1) | x-1, a1, a2) end else let val () = intinf_free (a1) in (pf0 | a0) end // end of [if] val intinf_0 = intinf_make 0 and intinf_1 = intinf_make 1 in loop (FIB_bas_0 (), FIB_bas_1 () | x, intinf_0, intinf_1) end // end of [fib5] (* ****** ****** *) implement main (argc, argv) = let // val () = if argc < 2 then begin prerrf ("Usage: %s [integer]\n", @(argv.[0])); exit 1 end val () = assert (argc >= 2) // val n = int1_of (argv.[1]); val () = if n < 0 then begin prerrf ("The argument = %i is illegal.\n", @(n)); exit 1 end // end of [val] val () = assert (n >= 0) // val fib1_n = fib1 n val () = begin printf ("fib1(%i) = ", @(n)); print fib1_n; print_newline () end // end of [val] // val fib2_n = fib2 n val () = begin printf ("fib2(%i) = ", @(n)); print fib2_n; print_newline () end // end of [val] // val fib3_n = fib3 n val () = begin printf ("fib3(%i) = ", @(n)); print fib3_n; print_newline () end // end of [val] // val (_ | fib4_n) = fib4 n val () = begin printf ("fib4(%i) = ", @(n)); print fib4_n; print_newline () end // end of [val] // val (_ | fib5_n) = fib5 n val () = begin printf ("fib5(%i) = ", @(n)); print (fib5_n); print_newline () end // end of [val] val () = intinf_free (fib5_n) // in // empty end // end of [main] (* ****** ****** *) (* end of [fibs.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/revarr.dats0000664000175000017500000000460612223166161020713 0ustar hwxihwxi// // A simple example for illustrating some benefits of dependent types // (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) // // How to compile: // atscc -o revarr revarr.dats // How to test: // ./revarr // (* ****** ****** *) (* // this one does not use dependent types: staload _(*anonymous*) = "prelude/DATS/array0.dats" fun{a:t@ype} revarr (A: array0 a): void = loop (A, 0, n - 1) where { val n: size_t = array0_size A val n: int = int_of_size (n) fun loop (A: array0 a, i: int, j: int): void = if i < j then let val tmp = A[i] in A[i] := A[j]; A[j] := tmp; loop (A, i + 1, j - 1) end // end of [if] // end of [loop] } // end of [revarr] implement main () = let fun pr (A: array0 int): void = loop (A, n, 0) where { val n = array0_size A; val n = int_of_size (n) fun loop (A: array0 int, n: int, i: int): void = if i < n then begin if i > 0 then print ", "; print A[i]; loop (A, n, i+1) end else begin // loop exits end // end of [if] } // end of [pr] val A = array0_make_arrpsz{int}($arrpsz(0, 1, 2, 3, 4, 5)) val () = pr A val () = print_newline () val () = revarr (A) val () = pr A val () = print_newline () in // empty end // end of [main] *) (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" fun{a:t@ype} revarr {n:nat} (A: array (a, n), n: int n): void = loop (A, 0, n - 1) where { fun loop {i:nat;j:int | i <= j+1; i + j == n-1} (A: array (a, n), i: int i, j: int j): void = if i < j then let val tmp = A[i] in A[i] := A[j]; A[j] := tmp; loop (A, i + 1, j - 1) end // end of [if] } // end of [revarr] (* ****** ****** *) implement main () = let fun pr {n:nat} (A: array (int, n), n: int n): void = loop (A, n, 0) where { fun loop {i:nat | i <= n} .. (A: array (int, n), n: int n, i: int i): void = if i < n then begin if i > 0 then print ", "; print A[i]; loop (A, n, i+1) end else begin // loop exits end // end of [if] } // end of [pr] val N = 10 val A = array_make_arrpsz{int}($arrpsz(0, 1, 2, 3, 4, 5, 6, 7, 8, 9)) val () = pr (A, N) val () = print_newline () val () = revarr (A, N) val () = pr (A, N) val () = print_newline () in // empty end // end of [main] (* ****** ****** *) (* end of [revarr.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fact1.dats0000664000175000017500000000201112223166161020374 0ustar hwxihwxi// // A naive implementation of the factorial function (1) // Author: Hongwei Xi (August 2007) // (* ****** ****** *) // // How to compile: // atscc -o fact1 fact1.dats // How to test: // ./fact1 // (* ****** ****** *) // [fun] declares a recursive function fun fact1 (x: int): int = if x > 0 then x * fact1 (x-1) else 1 // [fn] declares a non-recursive function // It is fine to replace [fn] with [fun] as a non-recursive function // is a special kind of recursive function that does not call itself. // [@(...)] is used in ATS to group arguments for variadic functions fn fact1_usage (cmd: string): void = prerrf ("Usage: %s [integer]\n", @(cmd)) // print an error message (* ****** ****** *) implement main (argc, argv) = if argc >= 2 then let val n = int_of argv.[1] // turning string into integer val res = fact1 n in printf ("factorial of %i = %i\n", @(n, res)) end else begin fact1_usage argv.[0]; exit (1) end // end of [if] // end of [main] (* ****** ****** *) (* end of [fact1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fact4.dats0000664000175000017500000000421112223166161020403 0ustar hwxihwxi// // // A Verified Implementation of the Factorial Function // // Author: Hongwei Xi (December, 2009) // // (* The mathematical definition of factorials: fact (0) = 1 fact (n) = n * fact (n-1) ; if n > 0 *) (* ****** ****** *) extern praxi mul_equal {m1,m2:int | m1==m2} {n1,n2:int | n1==n2} (): [m1*n1==m2*n2] void // end of [mul_equal] extern praxi mul_assoc {p,q,r:int} (): [(p*q)*r==p*(q*r)] void // end of [mul_assoc] (* ****** ****** *) sta fact : int -> int extern praxi fact_equal {n1,n2:int | n1==n2} (): [fact(n1)==fact(n2)] void // end of [mul_equal] extern praxi fact_bas (): [fact(0) == 1] void extern praxi fact_ind {n:pos} (): [fact(n) == n * fact(n-1)] void (* ****** ****** *) // // HX: [fact] implements the factorial function // fn fact {n:nat} // in a tail-recursive style (n: int n): int (fact n) = loop (n, 1) where { // [loop] is tail-recusive fun loop {n:nat; x:int} .< n >. (n: int n, x: int x) : int (x * fact n) = if n > 0 then let val [xn:int] (pf_mul_x_n_xn | xn) = x imul2 n prval () = mul_elim (pf_mul_x_n_xn) stadef res1 = fact(n-1) val res = loop (n-1, xn) // res: int (xn*res1) prval () = mul_equal {xn,x*n} {res1,res1} () prval () = mul_assoc {x,n,res1} () // x*n*res1=x*(n*res1) prval () = fact_ind {n} () // fact n = n*res1 prval () = mul_equal {x,x} {fact n,n*res1} () in res end else let prval () = fact_bas () prval () = fact_equal {n,0} () prval () = mul_equal {x,x} {fact(n),1} () in x end // end of [val] } // end of [fact] (* ****** ****** *) // // HX: for a simple test: are there any dounts :) // implement main (argc, argv) = case+ argc of | 2 => begin let val n = int1_of argv.[1] val () = assert_prerrf_bool1 ( n >= 0, "Exit: negative argument: %i\n", @(n) ) val res2 = fact n in printf ("The value of fact(%i) is %i.\n", @(n, res2)) end end // end of [2] | _ => let val cmd = argv.[0] in printf ("Usage: %s [integer]\n", @(cmd)) end // end of [_] // end of [main] (* ****** ****** *) (* end of [fact4.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fact2.dats0000664000175000017500000000203212223166161020400 0ustar hwxihwxi// // A naive implementation of the factorial function (2) // Author: Hongwei Xi (August 2007) // (* ****** ****** *) // // How to compile: // atscc -o fact2 fact2.dats // How to test: // ./fact2 // (* ****** ****** *) typedef Nat = [n:int | n >= 0] int n // type for natural numbers fun fact2 {n:nat} (x: int n): Nat = if x > 0 then x nmul fact2 (x-1) else 1 // [fn] declares a non-recursive function // [@(...)] is used in ATS to group arguments for functions of variable arguments fn fact2_usage (cmd: string): void = prerrf ("Usage: %s [integer]\n", @(cmd)) // print an error message (* ****** ****** *) implement main (argc, argv) = if argc >= 2 then let val n = int1_of argv.[1] // turning string into integer val () = assert_errmsg_bool1 (n >= 0, "The integer argument needs to be nonnegative.\n") val res = fact2 (n) in printf ("factorial of %i = %i\n", @(n, res)) end else begin fact2_usage (argv.[0]); exit (1) end // end of [if] // end of [main] (* ****** ****** *) (* end of [fact2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/fact3.dats0000664000175000017500000000410712223166161020406 0ustar hwxihwxi// // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: August 2007 // // // This is an example of programming with theorem proving: A verified // implmentation of the factioral function is given. // (* ****** ****** *) // // How to compile: // atscc -o fact3 fact3.dats -lgmp // How to test: // ./fact3 100 // (* ****** ****** *) // #include "prelude/HATS/lmacrodef.hats" // for prerrstarln // (* ****** ****** *) staload "libats/SATS/intinf.sats" dynload "libats/DATS/intinf.dats" (* ****** ****** *) // The following dataprop encodes a specification of the factorial function dataprop FACT (int, int) = | FACTzero (0, 1) | {n,r,r1:int | n > 0} FACTsucc (n, r) of (FACT (n-1, r1), MUL (n, r1, r)) // end of [FACT] fun fact3 {n:nat} .. (n: int n): [r:int] (FACT (n, r) | intinf r) = if n > 0 then let val n1 = pred n val (pf1 | r1) = fact3 (n1) val (pf_mul | r) = n * r1 val () = intinf_free (r1) in (FACTsucc (pf1, pf_mul) | r) end else begin (FACTzero () | intinf_make 1) end // end of [if] // end of [fact3] (* ****** ****** *) // [fn] declares a non-recursive function // [@(...)] is used in ATS to group arguments for functions of variable arguments fn fact3_usage (cmd: string): void = prerrstarln (("Usage: ", cmd, " [integer]")) // print an error message (* ****** ****** *) // // Is there still any doubt :) // implement main (argc, argv) = if argc >= 2 then let val n0 = int1_of argv.[1] // turning string into integer val () = assert_errmsg (n0 >= 0, "The integer argument needs to be nonnegative.\n") val (pf | res) = fact3 (n0) val () = begin print "The factorial of "; print n0; print " = "; print (res); print_newline () end // end of [val] in intinf_free (res) end else begin fact3_usage (argv.[0]); exit (1) end // end of [if] // end of [main] (* The factorial of 100 = 93326215443944152681699238856266700490715968264381\ 62146859296389521759999322991560894146397615651828\ 62536979208272237582511852109168640000000000000000\ 00000000 *) (* ****** ****** *) (* end of [fact3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/INTRO/f91.dats0000664000175000017500000000163112223166161020004 0ustar hwxihwxi// // // An implementation of the MacCarthy's 91-function // // Hongwei Xi (Summer 2007) // // // How to compile: // atscc -o f91 f91.dats // How to test: // ./f91 // (* ****** ****** *) // // HX: [f91] is proven to be terminating // fun f91 {i:int} .. (N: int i) :<> [j:int | (i <= 100 && j == 91) || (i > 100 && j == i-10)] int j = if N > 100 then N-10 else f91 (f91 (N+11)) // end of [f91] fun f91_usage (cmd: string): void = prerrf ("Usage: %s [integer]\n", @(cmd)) // print an error message // end of [f91_usage] (* ****** ****** *) implement main (argc, argv) = let val () = if argc <> 2 then (f91_usage (argv.[0]); exit (1)) val () = assert (argc = 2) // this is redundant but easy to pass typechecking val s = argv.[1] val i = int1_of_string (s) val res = f91 (i) in printf ("f91(%i) = %i\n", @(i, res)) end // end of [main] (* ****** ****** *) (* end of [f91.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/0000700000175000017500000000000012223166161016377 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_array.dats0000664000175000017500000000414412223166161023310 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/smlbas/SATS/array.sats" staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/array0.dats" staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "libats/smlbas/DATS/array.dats" (* ****** ****** *) dynload "libats/smlbas/DATS/array.dats" (* ****** ****** *) #define :: list0_cons #define cons list0_cons #define nil list0_nil (* ****** ****** *) implement main () = () where { // // Let the test begin! (* val () = begin // [maxLen] is undefined! print "maxLen = "; print (maxLen ()); print_newline () end // end of [val] *) val A0 = array (10(*asz*), 5) val () = app (lam (x) => (print x), A0) val () = print_newline () // val A1 = fromList (0 :: 1 :: 2 :: 3 :: 4 :: 5 :: 6 :: 7 :: 8 :: 9 :: nil) val () = app (lam (x) => (print x), A1) val () = print_newline () // val () = copy (A1, A0, 0) val () = app (lam (x) => (print x), A0) val () = print_newline () // val () = modify (lam (x) => 9 - x, A1) val () = app (lam (x) => (print x), A1) val () = print_newline () // val () = modifyi (lam (i, x) => x + int_of_size i, A1) val () = app (lam (x) => (print x), A1) val () = print_newline () // val A2 = tabulate (10, lam (i) => int_of_size (i * i)) val () = appi (f, A2) where { macdef _0 = size_of_int1 (0) fn f (i: size_t, x: int): void = let val () = if i > _0 then print ", " in print x end (* end of [f] *) } // end of [val] val () = print_newline () // val () = assert (collate (lam (x, y) => compare (x, y), A2, A2) = 0) val A3 = fromList (0 :: 1 :: 2 :: 3 :: 4 :: 5 :: 6 :: 7 :: 8 :: 9 :: nil) val () = assert (collate (lam (x, y) => compare (x, y), A2, A3) > 0) val () = assert (collate (lam (x, y) => compare (x, y), A3, A2) < 0) // } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_array.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_integer.dats0000664000175000017500000000234612223166161022452 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/integer.sats *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2012 // (* ****** ****** *) // // staload "prelude/SATS/integer.sats" // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libc/SATS/signal.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) fun fhandler ( sgn: signum_t ) : void = let val () = print ( "No input was given in the allowed amount time." ) // end of [val] val () = print_newline () in exit (0) end // end of [fhandler] implement main () = { // var act: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] val () = act.sa_handler := (sighandler)fhandler val err = sigaction_null (SIGALRM, act) // var i: int val () = fprintf (stdout_ref, "Please input an integer:\n", @()) val (pf | n) = alarm_set (10u) val () = fscan_int_exn (stdin_ref, i) val _leftover = alarm_cancel (pf | (*none*)) val () = fprintf (stdout_ref, "The input integer is [%d]\n", @(i)) } // end of [main] (* ****** ****** *) (* end of [prelude_integer.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_hashtable_chain.dats0000664000175000017500000000742012223166161023726 0ustar hwxihwxi(* // // Author: Hongwei Xi (March, 2010) // *) (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload H = "libats/SATS/hashtable_chain.sats" staload _(*anon*) = "libats/DATS/hashtable_chain.dats" stadef HASHTBLptr = $H.HASHTBLptr (* ****** ****** *) // dynload "hashtable_chain.dats" // not needed as [ATS_DYNLOADFLAG = 0] (* ****** ****** *) (* ** the efficiency gained from inlining the comparison ** function seems to be less than 5% (more like a 3%) *) // (* // // Robert Jenkin's 32-bit function: // %{^ ats_int_type __jenkin32 (ats_int_type x) { uint32_t a = x ; a = (a+0x7ed55d16) + (a<<12); a = (a^0xc761c23c) ^ (a>>19); a = (a+0x165667b1) + (a<<5); a = (a+0xd3a2646c) ^ (a<<9); a = (a+0xfd7046c5) + (a<<3); a = (a^0xb55a4f09) ^ (a>>16); return a; } // end of [__jenkin] %} // end of [%{^] extern fun __jenkin32 (x: int):<> int = "__jenkin32" implement $H.hash_key (x, _) = let val h = __jenkin32 (x) in ulint_of_int (h) end // end of [hash_key] implement $H.equal_key_key (x1, x2, _) = (x1 = x2) // *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert_errmsg (n > 0, #LOCATION) (* val () = $RAND.srand48_with_time () *) typedef key = int and itm = string fn hash (x: key): ulint = ulint_of_int (x) fn eq (x1: key, x2: key): bool = (x1 = x2) val [l:addr] ptbl = $H.hashtbl_make {int,string} (hash, eq) var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val kstr = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) in $H.hashtbl_insert (ptbl, key, kstr) end // end [for] val size = $H.hashtbl_size (ptbl) val total = $H.hashtbl_total (ptbl) val () = begin print "size = "; print size; print_newline (); print "total = "; print total; print_newline (); end // end of [val] // fn find {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k0)) val ans = $H.hashtbl_search (ptbl, k0, res) val () = if ans then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [if] val () = print_newline () } // end of [find] // var res: itm? // val k0 = 0 val () = find (ptbl, k0, res) val k1 = 1 val () = find (ptbl, k1, res) val k10 = 10 val () = find (ptbl, k10, res) val k100 = 100 val () = find (ptbl, k100, res) val k1000 = 1000 val () = find (ptbl, k1000, res) val k10000 = 10000 val () = find (ptbl, k10000, res) // #define p2s string_of_strptr var !p_f = @lam (pf: !unit_v | k: key, i: &itm): void = i := p2s (sprintf ("%i", @(k+k+1))) // end of [var] prval pf = unit_v () val () = $H.hashtbl_foreach_vclo {unit_v} (pf | ptbl, !p_f) prval unit_v () = pf // val () = find (ptbl, k10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val ans = $H.hashtbl_remove (ptbl, key, res) prval () = opt_clear (res) in // nothing end // end [for] // val total = $H.hashtbl_total (ptbl) val () = (print "total(aft) = "; print total; print_newline ()) val notfreed = $H.hashtbl_free_vt (ptbl) val () = assert_errmsg (notfreed = false, #LOCATION) prval () = opt_unnone (ptbl) in // empty end // end of [main] (* ****** ****** *) (* end of [libats_hashtable_chain.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_dlist_vt.dats0000664000175000017500000000312112223166161022635 0ustar hwxihwxi(* // some testing code for functions declared in // prelude/SATS/dlist_vt.sats *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 (* ****** ****** *) staload RAND = "libc/SATS/random.sats" staload STDLIB = "libc/SATS/stdlib.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/unsafe.dats" staload _(*anonymous*) = "prelude/DATS/dlist_vt.dats" (* ****** ****** *) #define MAXELT 10 fun dlist_randgen {n:nat} (n: int n) : dlist_vt (int, 0, n) = if n > 0 then let val i = $RAND.randint (MAXELT) in dlist_vt_cons (i, dlist_randgen (n-1)) end else dlist_vt_nil () // end of [dlist_randgen] (* ****** ****** *) implement main (argc, argv) = let #define N 10 val () = $RAND.srand48_with_time () val xs = dlist_randgen (N) val n: int(N) = dlist_vt_length (xs) val () = assertloc (n = N) // val () = dlist_vt_foreach_fun (xs, lam x =<1> print (x)) val () = print_newline () // val xs = dlist_vt_move_end (xs) // val x = dlist_vt_get (xs) val () = print (x) val () = rdlist_vt_foreach_fun (xs, lam x =<1> print (x)) val () = print_newline () // val _1: int(1) = dlist_vt_length (xs) val () = assertloc (_1 = 1) val _1n: int(N-1) = rdlist_vt_length (xs) val () = assertloc (_1n = N-1) // val xs = rdlist_vt_move_end (xs) // val xs = dlist_vt_insert (xs, 0) val _n1: int(N+1) = dlist_vt_length (xs) val () = assertloc (_n1 = N+1) // val () = dlist_vt_free (xs) in print "The run of [prelude_dlist.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_dlist_vt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_ngc_slist.dats0000664000175000017500000000636712223166161022627 0ustar hwxihwxi(* ** testing some functions declared in ** contrib/linux/utils/SATS/slist.sats ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2011 ** *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libats/ngc/SATS/slist.sats" staload _(*anon*) = "libats/ngc/DATS/slist.dats" (* ****** ****** *) %{^ typedef struct { char *name ; int age ; int sex ; void *next ; } person_struct ; ats_ptr_type person_alloc () { return ATS_MALLOC(sizeof(person_struct)) ; } // end of [person_alloc] ats_void_type person_free (ats_ptr_type p) { return ATS_FREE(p) ; } ats_ptr_type person_get_next ( ats_ptr_type x ) { return ((person_struct*)x)->next ; } // end of [person_get_next] ats_void_type person_set_next ( ats_ptr_type x, ats_ptr_type p ) { ((person_struct*)x)->next = p ; return ; } // end of [person_set_next] %} // end of [%{] (* ****** ****** *) viewtypedef person = $extype_struct "person_struct" of { name= strptr1, age= int, sex= int } // end of [person] viewtypedef personlst (n:int) = slist (person, n) (* ****** ****** *) extern fun person_alloc : slnode_alloc_type (person) = "person_alloc" implement slnode_alloc () = person_alloc () (* ****** ****** *) extern fun person_free : slnode_free_type (person) = "person_free" implement slnode_free (pf | x) = person_free (pf | x) (* ****** ****** *) extern fun person_get_next : slnode_get_next_type (person) = "person_get_next" implement slnode_get_next (pf | x) = person_get_next (pf | x) extern fun person_set_next : slnode_set_next_type (person) = "person_set_next" implement slnode_set_next (pf | x, p) = person_set_next (pf | x, p) (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) fun personlst_randgen {n:nat} (n: int n): personlst (n) = let viewtypedef a = person in if n > 0 then let // val (pfopt | p) = person_alloc () val () = assertloc (p > null) prval Some_v (pfnod) = pfopt prval (pfat, fpfnod) = slnode_v_takeout_val {a?} (pfnod) // val id = randint (10) val () = p->name := sprintf ("XYZ-%1d", @(id)) val () = p->age := randint (100) val () = p->sex := randint (2) // prval () = pfnod := fpfnod {a} (pfat) // val xs = personlst_randgen (n-1) in slist_cons (pfnod | p, xs) end else slist_nil () end // end of [personlst_randgen] (* ****** ****** *) implement main () = () where { // val () = srand48_with_time () // #define N 5 val xs1 = personlst_randgen (N) val xs2 = personlst_randgen (N) val xs = slist_append (xs1, xs2) val n = slist_length (xs) val () = println! ("n = ", n) val () = assertloc ( n = N+N ) // val () = slist_foreach_fun (xs , lam (x) => $effmask_all ( printf ("%s(age=%i,sex=%i)\n", @($UN.castvwtp1 {string} (x.name), x.age, x.sex)) ) (* end of [lam] *) ) // end of [val] // val xs = slist_reverse (xs) val () = slist_foreach_fun (xs , lam (x) => $effmask_all ( printf ("%s(age=%i,sex=%i)\n", @($UN.castvwtp1 {string} (x.name), x.age, x.sex)) ) ) // end of [val] // val () = slist_free_fun (xs, lam (x) => strptr_free (x.name)) // } // end of [main] (* ****** ****** *) (* end of [libats_ngc_slist.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_lazy_vt.dats0000664000175000017500000000411312223166161022477 0ustar hwxihwxi(* // some testing code for functions declared in // prelude/SATS/lazy_vt.sats *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/lazy_vt.dats" (* ****** ****** *) staload "contrib/testing/SATS/randgen.sats" staload _(*anon*) = "contrib/testing/DATS/randgen.dats" staload "contrib/testing/SATS/fprint.sats" staload _(*anon*) = "contrib/testing/DATS/fprint.dats" (* ****** ****** *) typedef T = int (* ****** ****** *) #define N 10 implement randgen () = $RAND.randint (N) implement fprint_elt (out, x) = fprint (out, x) (* ****** ****** *) implement main () = () where { // val () = $RAND.srand48_with_time () // #define L1 2 val xs1 = list_vt_randgen (L1) val () = ( print "xs1 = "; list_vt_fprint_elt (stdout_ref, xs1, " -> "); print_newline () ) // end of [val] // #define L2 3 val xs2 = list_vt_randgen (L2) val () = ( print "xs2 = "; list_vt_fprint_elt (stdout_ref, xs2, " -> "); print_newline () ) // end of [val] // typedef T2 = (T, T) implement fprint_elt (out, xx) = fprintf (out, "(%i, %i)", @(xx.0, xx.1)) // val xxs = stream_vt_of_lstlstprod (xs1, xs2) // #define L3 2 val xs3 = list_vt_randgen (L3) val () = ( print "xs3 = "; list_vt_fprint_elt (stdout_ref, xs3, " -> "); print_newline () ) // end of [val] // typedef T3 = (T2, T) implement fprint_elt (out, xxx) = fprintf (out, "(%i, %i, %i)", @((xxx.0).0, (xxx.0).1, xxx.1)) // val xxxs = stream_vt_of_strmlstprod (xxs, xs3) // val (n, xxxs) = list_vt_of_stream_vt (xxxs) val () = assertloc (n = L1*L2*L3) val () = ( print "xxxs = "; list_vt_fprint_elt (stdout_ref, xxxs, " -> "); print_newline () ) // end of [val] // val () = list_vt_free (xxxs) // } // end of [val] (* ****** ****** *) (* end of [prelude_lazy_vt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_random.dats0000664000175000017500000000227412223166161021546 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/stdio.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) fun test_randint () = let #define _1M 1000000 var cnt: int = 0 var i: int // uninitialize val () = for (i := 0; i < _1M; i := i+1) if randint (2) = 0 then cnt := cnt + 1 else () val ratio = (1.0 * cnt / _1M) in printf ("test_randint: ratio = %.6f\n", @(ratio)) end // end of [test_randint] (* ****** ****** *) fun test_randint_r () = let #define _1M 1000000 var cnt: int = 0 var res: int? var buf: drand48_data val _0 = srand48_r (0L, buf) var i: int // uninitialize val () = for (i := 0; i < _1M; i := i+1) let val () = randint_r (buf, 2, res) in if res = 1 then cnt := cnt + 1 else () end // end of [val] val ratio = (1.0 * cnt / _1M) in printf ("test_randint_r: ratio = %.6f\n", @(ratio)) end // end of [test_randint_r] (* ****** ****** *) implement main (argc, argv) = let val () = test_randint () val () = test_randint_r () in // empty end // end of [main] (* ****** ****** *) (* end of [libc_stdio.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_bool.dats0000664000175000017500000000166212223166161021750 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/bool.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: August, 2010 // (* ****** ****** *) // // HX: testing the recently added support for boolean patterns // fn not1 {b:bool} (b: bool b):<> bool (~b) = case+ b of | true => false | false => true // end of [not1] (* ****** ****** *) implement main () = let // val b1 = true and b2 = false // val () = println! ("b1(true) = ", b1) val () = println! ("b2(false) = ", b2) // val () = assert (not1 b1 = ~b1) val () = assert (not1 b2 = ~b2) // val () = assert (~(b1 || b2) = (~b1 && ~b2)) val () = assert (~(b1 && b2) = (~b1 || ~b2)) // val b1 = false and b2 = true val () = assert (~(b1 || b2) = (~b1 && ~b2)) val () = assert (~(b1 && b2) = (~b1 || ~b2)) // in print "[prelude_bool.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_bool.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_ngc_linmap_pavltree.dats0000664000175000017500000002074612223166161024650 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/ngc/SATS/linmap_pavltree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // Author: Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) // Time: February, 2012 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload "libats/ngc/SATS/linmap_pavltree.sats" staload _(*anon*) = "libats/ngc/DATS/linmap_pavltree.dats" viewtypedef map_vt (key:t@ype, itm:viewt@ype) = map (key, itm) (* ****** ****** *) %{^ typedef struct { char *value ; } node_itm ; typedef struct { int key ; char *value ; int height ; void *left ; void *right ; void *parent ; } node_struct ; ats_ptr_type node_alloc () { return ATS_MALLOC(sizeof(node_struct)) ; } // end of [node_alloc] ats_void_type node_free (ats_ptr_type p) { return ATS_FREE(p) ; } // end of [node_free] ats_ptr_type node_takeout_val (ats_ptr_type x) { return &(((node_struct*)x)->value) ; } // end of [node_takeout_val] ATSinline() ats_int_type node_get_height (ats_ptr_type x) { return ((node_struct*)x)->height ; } // end of [node_get_height] ATSinline() ats_void_type node_set_height ( ats_ptr_type x, ats_int_type h1 ) { ((node_struct*)x)->height = h1 ; return ; } // end of [node_set_height] ATSinline() ats_ptr_type node_get_left (ats_ptr_type x) { return ((node_struct*)x)->left ; } // end of [node_get_left] ATSinline() ats_void_type node_set_left ( ats_ptr_type x, ats_ptr_type p ) { ((node_struct*)x)->left = p ; return ; } // end of [node_set_left] ATSinline() ats_ptr_type node_get_right (ats_ptr_type x) { return ((node_struct*)x)->right ; } // end of [node_get_right] ATSinline() ats_void_type node_set_right ( ats_ptr_type x, ats_ptr_type p ) { ((node_struct*)x)->right = p ; return ; } // end of [node_set_right] ATSinline() ats_ptr_type node_get_parent (ats_ptr_type x) { return ((node_struct*)x)->parent ; } // end of [node_get_parent] ATSinline() ats_void_type node_set_parent ( ats_ptr_type x, ats_ptr_type p ) { ((node_struct*)x)->parent = p ; return ; } // end of [node_set_parent] ATSinline() int node_get_key (ats_ptr_type x) { return ((node_struct*)x)->key ; } // end of [node_get_key] ATSinline() void node_set_key (ats_ptr_type x, int k0) { ((node_struct*)x)->key = k0 ; return ; } // end of [node_set_key] %} // end of [%{] (* ****** ****** *) viewtypedef node_itm = $extype_struct "node_itm" of { value= string } // end of [node_itm] (* ****** ****** *) extern fun node_alloc : pavlnode_alloc_type (int, node_itm) = "node_alloc" implement pavlnode_alloc () = node_alloc () extern fun node_free : pavlnode_free_type (int, node_itm) = "node_free" implement pavlnode_free (pf | x) = node_free (pf | x) (* ****** ****** *) extern fun node_takeout_val : pavlnode_takeout_val_type (int, node_itm) = "node_takeout_val" implement pavlnode_takeout_val (pf | x) = node_takeout_val (pf | x) (* ****** ****** *) extern fun node_get_left : pavlnode_get_left_type (int, node_itm) = "node_get_left" implement pavlnode_get_left (pf | x) = node_get_left (pf | x) extern fun node_set_left : pavlnode_set_left_type (int, node_itm)= "node_set_left" implement pavlnode_set_left (pf | x, y) = node_set_left (pf | x, y) extern fun node_get_right : pavlnode_get_right_type (int, node_itm) = "node_get_right" implement pavlnode_get_right (pf | x) = node_get_right (pf | x) extern fun node_set_right : pavlnode_set_right_type (int, node_itm) = "node_set_right" implement pavlnode_set_right (pf | x, y) = node_set_right (pf | x, y) extern fun node_get_parent : pavlnode_get_parent_type (int, node_itm) = "node_get_parent" implement pavlnode_get_parent (pf | x) = node_get_parent (pf | x) extern fun node_set_parent : pavlnode_set_parent_type (int, node_itm) = "node_set_parent" implement pavlnode_set_parent (pf | x, y) = node_set_parent (pf | x, y) extern fun node_get_height : pavlnode_get_height_type (int, node_itm) = "node_get_height" implement pavlnode_get_height (pf | x) = node_get_height (pf | x) extern fun node_set_height : pavlnode_set_height_type (int, node_itm) = "node_set_height" implement pavlnode_set_height (pf | x, y) = node_set_height (pf | x, y) extern fun node_get_key : pavlnode_get_key_type (int, node_itm) = "node_get_key" implement pavlnode_get_key (pf | x) = node_get_key (pf | x) extern fun node_set_key : pavlnode_set_key_type (int, node_itm) = "node_set_key" implement pavlnode_set_key (pf | x, y) = node_set_key (pf | x, y) (* ****** ****** *) implement compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int viewtypedef itm = node_itm fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var res: itm? // uninitialized // var map = linmap_make_nil {key,itm} () val () = loop (map, n, 0) where { fun loop {i,n:nat | i <= n} .. (map: &map_vt (key, itm), n: int n, i: int i): void = if i < n then let val key = i // val key = $RAND.randint n val itm = tostring_int key // val itm = sprintf ("%i", @(key)) val (pfopt | p) = pavlnode_alloc () val () = assertloc (p > null) prval Some_v pfnod = pfopt val () = pavlnode_set_key (pfnod | p, key) // val ( pfat, fpfnod | p_itm ) = pavlnode_takeout_val (pfnod | p) val () = p_itm->value := itm prval () = pfnod := fpfnod {itm} (pfat) // (* val () = printf ("key = %i and itm = %s\n", @(key, itm)) *) var p = p val found = linmap_insert (pfnod | map, p, cmp) in if found then let prval Some_v pfat = pfnod in pavlnode_free (pfat | p) end else let prval None_v () = pfnod in // nothing end; // end of [if] loop (map, n, i+1) end // end of [if] // end of [loop] } // end of [where] // val size = linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = linmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if :(map: map_vt (key, itm)) => n < 100 then let // AS: for making sure iteration works as expected val () = linmap_foreach_fun_iter (map, lam (k, i) => $effmask_all (printf ("%i\t->\t%s\n", @(k, i.value)))) (* prval pf = unit_v (); val () = linmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: &itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i.value))) } // end of [val] prval unit_v () = pf *) in // empty end // end of [val] // fn find ( map: &map_vt (key, itm), k: key, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = linmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print (res.value); print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // val () = loop (map, n, 0) where { fun loop {i,n:nat | i <= n} .. (map: &map_vt (key, itm), n: int n, i: int i): void = if i < n then let val key = i val _(*removed*) = linmap_remove (map, key, cmp) in // nothing end // end of [if] // end of [loop] } // end of [where] // val size = linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val () = linmap_free (map) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_ngc_linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linmap_skiplist.dats0000664000175000017500000000622512223166161024035 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/linmap_skiplist.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload LM = "libats/SATS/linmap_skiplist.sats" staload _(*anon*) = "libats/DATS/linmap_skiplist.dats" stadef map_vt = $LM.map (* ****** ****** *) implement $LM.compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = string fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var res: itm? // uninitialized // val () = $LM.linmap_random_initize () // var map: map_vt (key, itm) = $LM.linmap_make_nil () var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val itm = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) val _(*inserted*) = $LM.linmap_insert (map, key, itm, cmp, res) prval () = opt_clear (res) in // nothing end // end [for] // val size = $LM.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val () = if n < 100 then let prval pf = unit_v (); val () = $LM.linmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: &itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // fn find ( map: &map_vt (key, itm), k: int, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = $LM.linmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i val _(*removed*) = $LM.linmap_remove (map, key, cmp) in // nothing end // end [for] // val size = $LM.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val notfreed = $LM.linmap_free_vt (map) val () = assert_errmsg (notfreed = false, #LOCATION) prval () = opt_unnone (map) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_linmap_skiplist.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_list_vt.dats0000664000175000017500000000675612223166161022512 0ustar hwxihwxi(* // some testing code for functions declared in // prelude/SATS/list_vt.sats *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 (* ****** ****** *) staload RAND = "libc/SATS/random.sats" staload STDLIB = "libc/SATS/stdlib.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) #define MAXELT 100 (* fun list_randgen {n: nat} (n: int n): list_vt (natLt MAXELT, n) = loop (n, list_vt_nil) where { typedef T = natLt MAXELT fun loop {i,j:nat} .. (i: int i, xs: list_vt (T, j)): list_vt (T, i+j) = if i = 0 then xs else loop (i-1, list_vt_cons ($RAND.randint MAXELT, xs)) // end of [loop] } // end of [list_randgen] *) fun list_randgen {n:nat} (n: int n): list_vt (natLt MAXELT, n) = list_vt_tabulate_fun (lam _ = $RAND.randint MAXELT, n) // end of [list_randgen] // end of [val] (* ****** ****** *) implement main (argc, argv) = let fn lstpr {n:nat} (xs: !list_vt (int, n)): void = () where { val xs = __cast (xs) where { extern castfn __cast (xs: !list_vt (int, n)): list (int, n) } // end of [val] val () = list_iforeach_fun (xs, f) where { fn f (i: int, x: int) : void = (if i > 0 then print (", "); print x) // end of [f] } // end of [val] } // end of [lstpr] // val xs = list_vt_of_arrpsz($arrpsz(1, 2, 3, 4, 5, 6, 7, 8, 9)) val () = list_vt_free (xs) // val () = $RAND.srand48_with_time () // a new seed is generated val xs = list_randgen (10) // val () = () where { val () = print "xs (randomly generated) = " val () = lstpr (xs) val () = print_newline () } // end of [val] // val ys = list_vt_of_arrpsz($arrpsz(0, 1, 2, 3, 4, 5, 6, 7, 8, 9)) // val () = () where { val () = print "ys (0-9) = " // for testing [list_vt_of_arraysize] val () = lstpr (ys) val () = print_newline () } // end of [val] // val () = () where { val () = print "length (xs) = " val () = print (list_vt_length xs) // for testing [list_vt_length] val () = print_newline () } // end of [val] // val () = () where { val xs1 = list_vt_copy (xs) val () = print "copy (xs) = "; val () = lstpr (xs1) // for testing [list_vt_copy] val () = list_vt_free (xs1) val () = print_newline () } // end of [val] // val () = () where { val xs1 = list_vt_copy (xs) val ys1 = list_vt_copy (ys) val xs1ys1 = list_vt_append (xs1, ys1) val () = print "append (xs, ys) = "; val () = lstpr (xs1ys1) // for testing [list_vt_append] val () = list_vt_free (xs1ys1) val () = print_newline () } // end of [val] // val () = () where { val xs1 = list_vt_copy (xs) val xs1 = list_vt_reverse (xs1) val () = print "reverse (xs) = "; val () = lstpr (xs1) // for testing [list_vt_reverse] val () = list_vt_free (xs1) val () = print_newline () } // end of [val] // val () = () where { // [list_vt_quicksort] is implemented on top of [qsort] in stdlib.h val () = list_vt_quicksort (xs, cmp) where { fn cmp (x1: &int, x2: &int):<> Sgn = compare (x1, x2) } val () = print "list_vt_quicksort (xs) = " val () = lstpr (xs) val () = print_newline () } // end of [val] // val () = list_vt_free (xs) val () = list_vt_free (ys) in print "The run of [prelude_list.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_list_vt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_iterint.dats0000664000175000017500000001120012223166161022276 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/iterint.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload "libats/SATS/iterint.sats" (* ****** ****** *) (* fun foreach_vclo {v:view} {n:nat} {f:eff} (pf: !v | n: int n, f: &(!v | natLt n) - void): void // end of [foreach_vclo] *) fn sum_foreach_vclo {n:nat} (n: int n): Nat = res where { var res: Nat = 0 viewdef v = Nat @ res var !p_f = @lam (pf: !v | i: natLt n): void = res := res + (i+1) // end of [var] val () = foreach_vclo {v} {n} (view@ res | n, !p_f) } // end of [sum_foreach_vclo] fn test_foreach_vclo () = () where { #define N 100 val sum = sum_foreach_vclo (N) val () = assert_errmsg (sum = N * (N+1) / 2, #LOCATION) } // end of [test_foreach_vclo] (* ****** ****** *) (* fun foreach_cloref {n:nat} {f:eff} (n: int n, f: (natLt n) - void): void // end of [foreach_cloref] *) fn sum_foreach_cloref {n:nat} (n: int n): Nat = !res where { val res = ref_make_elt (0) val f = lam (i: natLt n): void = !res := !res + (i+1) val () = foreach_cloref {n} (n, f) } // end of [sum_foreach_cloref] fn test_foreach_cloref () = () where { #define N 100 val sum = sum_foreach_cloref (N) val () = assert_errmsg (sum = N * (N+1) / 2, #LOCATION) } // end of [test_foreach_cloref] (* ****** ****** *) (* fun foreach2_vclo {v:view} {m,n:nat} {f:eff} (pf: !v | m: int m, n: int n, f: &(!v | natLt m, natLt n) - void) : void // end of [foreach2_vclo] *) fn sum_foreach2_vclo {n:nat} (n: int n): Nat = res where { var res: Nat = 0 viewdef v = Nat @ res var !p_f = @lam (pf: !v | i: natLt n, j: natLt n): void = res := res + (i+1) nmul (j+1) // end of [var] val () = foreach2_vclo {v} {n,n} (view@ res | n, n, !p_f) } // end of [sum_foreach2_vclo] fn test_foreach2_vclo () = () where { #define N 100 #define R %(N * (N+1) / 2) val sum = sum_foreach2_vclo (N) val () = assert_errmsg (sum = R * R, #LOCATION) } // end of [test_foreach2_vclo] (* ****** ****** *) (* fun foreach2_cloref {m,n:nat} {f:eff} (m: int m, n: int n, f: (natLt m, natLt n) - void) : void // end of [foreach2_cloref] *) fn sum_foreach2_cloref {n:nat} (n: int n): Nat = !res where { val res = ref_make_elt (0) val f = lam (i: natLt n, j: natLt n): void = !res := !res + (i+1) nmul (j+1) // end of [val] val () = foreach2_cloref {n,n} (n, n, f) } // end of [sum_foreach2_cloref] fn test_foreach2_cloref () = () where { #define N 100 #define R %(N * (N+1) / 2) val sum = sum_foreach2_cloref (N) val () = assert_errmsg (sum = R * R, #LOCATION) } // end of [test_foreach2_clo] (* ****** ****** *) (* fun repeat_vclo {v:view} {n:nat} {f:eff} (pf: !v | n: int n, f: &(!v | (*none*)) - void): void // end of [repeat_vclo] *) fn sum_repeat_vclo {n:nat} (n: int n): Nat = res where { var i: Nat = 1 var res: Nat = 0 viewdef v = (Nat @ i, Nat @ res) var !p_f = @lam (pf: !v | (*none*)): void = let prval (pf1, pf2) = pf val () = (res := res + i; i := i + 1) prval () = pf := (pf1, pf2) in // nothing end // end of [var] prval pf = (view@ i, view@ res) val () = repeat_vclo {v} {n} (pf | n, !p_f) prval () = (view@ i := pf.0; view@ res := pf.1) } // end of [sum_repeat_vclo] fn test_repeat_vclo () = () where { #define N 111 val sum = sum_repeat_vclo (N) val () = assert_errmsg (sum = N * (N+1) / 2, #LOCATION) } // end of [test_repeat_vclo] (* ****** ****** *) (* fun repeat_cloref {n:nat} {f:eff} (n: int n, f: () - void): void // end of [repeat_cloref] *) fn sum_repeat_cloref {n:nat} (n: int n): Nat = !res where { val i = ref_make_elt (1) val res = ref_make_elt (0) val f = lam (): void = let val () = (!res := !res + !i; !i := !i + 1) in // nothing end // end of [var] val () = repeat_cloref {n} (n, f) } // end of [sum_repeat_cloref] fn test_repeat_cloref () = () where { #define N 111 val sum = sum_repeat_cloref (N) val () = assert_errmsg (sum = N * (N+1) / 2, #LOCATION) } // end of [test_repeat_cloref] (* ****** ****** *) dynload "libats/DATS/iterint.dats" (* ****** ****** *) implement main () = let val () = test_foreach_vclo () val () = test_foreach_cloref () // val () = test_foreach2_vclo () val () = test_foreach2_cloref () // val () = test_repeat_vclo () val () = test_repeat_cloref () in print "[libats_iterint] testing passes!"; print_newline () end // end of [main] (* ****** ****** *) (* end of [libats_iterint.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_stdlib.dats0000664000175000017500000000520512223166161021544 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/stdlib.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2009 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload F = "libc/SATS/fcntl.sats" staload R = "libc/SATS/random.sats" staload STR = "libc/SATS/string.sats" staload UNI = "libc/SATS/unistd.sats" (* ****** ****** *) staload "libc/SATS/stdlib.sats" (* ****** ****** *) fun{a:t@ype} print_array {n:nat} ( A: &(@[a][n]), n: size_t n, pr: (a) -> void ) : void = () where { var i: sizeLte n val _0 = size1_of_int1 (0) val () = for (i := _0; i < n; i := i+1) let val () = if i > 0 then print ", "; val () = pr (A.[i]) in // nothing end // end of [val] } // end of [print_array] (* ****** ****** *) implement main (argc, argv) = let // val (fpf_x | _x) = getenv ("ATSHOME0") val () = (print "${ATSHOME0} = "; print _x; print_newline ()) prval () = fpf_x (_x) val (fpf_nameval | nameval) = (string_takeout_ptr)"ATSHOME0=ATSHOME0" val _err = putenv (nameval) prval () = fpf_nameval (nameval) val (fpf_x | _x) = getenv ("ATSHOME0") val () = (print "${ATSHOME0} = "; print _x; print_newline ()) prval () = fpf_x (_x) // val tmp = $STR.strdup_gc ("foo-XXXXXX") prval pfstr = tmp.1 val (pfopt | i) = mkstemp !(tmp.2) // create it! val () = assertloc (i > 0) val () = printf ("mkstemp: %s\n", @($UN.cast (tmp.2))) prval () = tmp.1 := pfstr prval $F.open_v_succ (pffil) = pfopt val () = $F.close_exn (pffil | i) val () = assertloc ($UNI.unlink ($UN.cast (tmp.2)) = 0) // remove it! val () = strbufptr_free (tmp) // val tmp = $STR.strdup_gc ("bar-XXXXXX") val p = mkdtemp (tmp.1 | tmp.2) // create it! val () = assertloc (p > null) val () = printf ("mkdtemp: %s\n", @($UN.cast (tmp.2))) val () = assertloc ($UNI.rmdir ($UN.cast (tmp.2)) = 0) // remove it! val () = strbufptr_free (tmp) // val () = $R.srand48_with_time () // #define ASZ 10 var !p_arr = @[double][ASZ](0.0) // var i: natLte ASZ // val () = for (i := 0; i < ASZ; i := i+1) let val () = p_arr->[i] := $R.drand48 () in // nothing end // end of [val] // val () = print_array (!p_arr, ASZ, lam x => printf ("%.2f", @(x))) val () = print_newline () val () = qsort {double} (!p_arr, ASZ, sizeof, lam (x1, x2) => compare (x1, x2)) val () = print_array (!p_arr, ASZ, lam x => printf ("%.2f", @(x))) val () = print_newline () // val _err = atexit (lam () => printf ("Bye, bye!\n", @())) val () = assert_errmsg (_err = 0, #LOCATION) // in // empty end // end of [main] (* ****** ****** *) (* end of [libc_stdlib.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linmap_rbtree.dats0000664000175000017500000000623212223166161023454 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/linmap_rbtree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload M = "libats/SATS/linmap_rbtree.sats" staload _(*anon*) = "libats/DATS/linmap_rbtree.dats" stadef map_vt = $M.map (* ****** ****** *) implement $M.compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = string fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var res: itm? // uninitialized // var map: map_vt (key, itm) = $M.linmap_make_nil () var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val itm = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) val _(*inserted*) = $M.linmap_insert (map, key, itm, cmp, res) prval () = opt_clear (res) in // nothing end // end [for] // val size = $M.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = $M.linmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if n < 100 then let prval pf = unit_v (); val () = $M.linmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: &itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // fn find ( map: &map_vt (key, itm), k: int, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = $M.linmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i val _(*removed*) = $M.linmap_remove (map, key, cmp) in // nothing end // end [for] // val size = $M.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val notfreed = $M.linmap_free_vt (map) val () = assert_errmsg (notfreed = false, #LOCATION) prval () = opt_unnone (map) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_linmap_rbtree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funarray_braun.dats0000664000175000017500000000360512223166161023650 0ustar hwxihwxi(* ** ** An implementation of functional arrays based on Braun trees. ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: October, 2008 ** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt // (* ****** ****** *) // How to compile: // atscc -o test test.dats funarray.dats (* ****** ****** *) staload FA = "libats/SATS/funarray_braun.sats" staload _(*anon*) = "libats/DATS/funarray_braun.dats" (* ****** ****** *) typedef farrstr (n:int) = $FA.array (string, n) implement main (argc, argv) = let fn prarr {n:nat} (A: farrstr n, n: int n): void = let val () = $FA.funarray_iforeach_cloref (A, n, lam (i, x) = $effmask_all (printf ("%i\t |->\t %s\n", @(i, x))) ) in // empty end // end of [prarr] // var A = $FA.funarray_make_nil {string} () // val () = loop (argc, argv, 0, A) where { fun loop {n,i:nat | i <= n} ( n: int n, ss: &(@[string][n]), i: int i, A: &farrstr i >> farrstr n ) : void = if i < n then let val () = $FA.funarray_hiadd (A, i, ss.[i]) in loop (n, ss, i+1, A) end else () // end of [loop] } // end of [val] val () = prarr (A, argc) // val () = loop (argc, 0, A) where { fun loop {n,i:nat | i <= n} (n: int n, i: int i, A: &farrstr (n-i) >> farrstr 0): void = if i < n then let val () = $FA.funarray_lorem A in loop (n, i+1, A) end else () // end of [loop] } // end of [val] // val () = loop (argc, argv, 0, A) where { fun loop {n,i:nat | i <= n} (n: int n, ss: &(@[string][n]), i: int i, A: &farrstr i >> farrstr n) : void = begin if i < n then let val () = $FA.funarray_loadd (A, ss.[i]) in loop (n, ss, i+1, A) end else () end // end of [loop] } // end of [val] val () = prarr (A, argc) in // empty end // end of [main] (* ****** ****** *) (* end of [libats_funarray_braun.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_gmp.dats0000664000175000017500000001723412223166161021053 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/gmp.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Author: Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) // Time: August, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libc/SATS/gmp.sats" (* ****** ****** *) fun mpz_test (): void = () where { macdef PI = 31415927U macdef SQRT2 = 141421UL // var x: mpz_vt val () = mpz_init (x) val () = mpz_set (x, PI) val () = assert (mpz_sgn (x) = 1) val () = assert (mpz_get_uint (x) = PI) // val str = mpz_get_str (10, x) val () = (print "str = "; print str; print_newline ()) val () = strptr_free (str) // val () = mpz_set_str_exn (x, "31415927", 10) val () = assert (mpz_cmp (x, PI) = 0) // val () = mpz_neg (x) val () = assert (mpz_sgn (x) = ~1) val () = assert (mpz_cmpabs (x, PI) = 0) val () = mpz_clear (x) // val (pfx_gc, pfx | px) = ptr_alloc () val () = mpz_init2 (!px, 64UL); val () = mpz_set (!px, SQRT2) val () = assert (mpz_get_ulint (!px) = SQRT2) val () = mpz_clear (!px) val () = ptr_free {mpz_vt?} (pfx_gc, pfx | px) // var fac10: mpz_vt val () = mpz_init (fac10) val () = mpz_fac_ui (fac10, 10UL) val () = (print "fac10 = "; print fac10; print_newline ()) val () = mpz_clear (fac10) // var fib10: mpz_vt val () = mpz_init (fib10) val () = mpz_fib_ui (fib10, 10UL) var fib11: mpz_vt and fib12: mpz_vt val () = mpz_init (fib11) and () = mpz_init (fib12) val () = mpz_fib2_ui (fib11, fib12, 12UL) val () = mpz_swap (fib11, fib12) val () = assert (mpz_get_int fib10 + mpz_get_int fib11 = mpz_get_int fib12) // var nprime: mpz_vt val () = mpz_init (nprime) val () = mpz_nextprime2 (nprime, fib12) val () = (print "nprime = "; print nprime; print_newline ()) // val nbit = mpz_size (nprime) val () = (print "nbit = "; print nbit; print_newline ()) val ndigit = mpz_sizeinbase (nprime, 10) val () = (print "ndigit = "; print ndigit; print_newline ()) // val () = mpz_clear (fib10) val () = mpz_clear (fib11) and () = mpz_clear (fib12) val () = mpz_clear (nprime) // var x: mpz_vt; val () = mpz_init_set (x, 100UL) var f: mpz_vt; val () = mpz_init_set (f, 2UL) val () = mpz_remove (x, f) // removing from x every factor of 2 val () = (print "x(25) = "; print x; print_newline ()) val () = mpz_clear (x) val () = mpz_clear (f) // } // end of [mpz_test] (* ****** ****** *) // // e = 1/0! + 1/1! + 1/2! + 1/3! + ... // fn compec1 (N: ulint): double = e where { var res: mpq_vt; val () = mpq_init (res) var nfac: mpz_vt; val () = mpz_init (nfac) var n: ulint var nfacinv: mpq_vt; val () = mpq_init (nfacinv) val () = mpq_set_ui (nfacinv, 1UL, 1UL) val () = for (n := 0UL; n < N; n := n + 1UL) let val () = mpz_fac_ui (nfac, n) val () = mpq_set_den (nfacinv, nfac) val () = mpq_add (res, nfacinv) in // nothing end // end of [val] val e = mpq_get_d (res) val () = mpq_clear (res) val () = mpz_clear (nfac) val () = mpq_clear (nfacinv) } // end of [compec1] (* ****** ****** *) // // e = 1/lim_{n->oo} (1-1/n)^n // fn compec2 (n: ulint): double = e where { var x: mpq_vt; val () = mpq_init (x) val () = mpq_set_ui (x, 1UL, 1UL) val () = mpq_decby (x, 1UL, n) val () = mpq_pow_ui (x, n) val () = mpq_inv (x) val e = mpq_get_d (x) val () = mpq_clear (x) } // end of [compec2] (* ****** ****** *) fun mpq_test (): void = () where { var x: mpq_vt and y: mpq_vt val () = mpq_init (x) and () = mpq_init (y) val () = mpq_set_si (x, 6L, 23UL) val () = mpq_inv (y, x) val () = mpq_add (x, y) val () = mpq_sub (x, y) // val (pf_num, fpf_num | p_num) = mpq_numref (x) val () = (print "num = "; print (!p_num); print_newline ()) prval () = fpf_num (pf_num) val (pf_den, fpf_den | p_den) = mpq_denref (x) val () = (print "den = "; print (!p_den); print_newline ()) prval () = fpf_den (pf_den) val () = (print "x(num/den) = "; print x; print_newline ()) val str = mpq_get_str (10, x) val () = (print "x(num/den) = "; print str; print_newline ()) val () = strptr_free (str) // val () = mpq_set (x, 3.1415926535898) val () = (print "x(num/den) = "; print x; print_newline ()) val () = printf ("x = %10.8f\n", @(mpq_get_d x)) // val () = mpq_clear (x) and () = mpq_clear (y) // val e = compec1 (16UL) // quite accurate val () = printf ("Euler's constant (e) = %.10f\n", @(e)) // val e = compec2 (1024UL) // still not quite accurate val () = printf ("Euler's constant (e) = %.10f\n", @(e)) // } // end of [mpq_test] (* ****** ****** *) fun mpf_test () : void = () where { // #define fPI 3.1415926535898 // var x : mpf_vt and y : mpf_vt var z : mpf_vt // val () = mpf_set_default_prec (128UL) val () = mpf_init (x) val () = assert (mpf_get_prec (x) = 128UL) val () = mpf_set_prec (x, 128UL) // val () = mpf_set_str_exn (x, "3.1415926535898", 10) val fx = mpf_get_d (x) // val () = assert (fx <> fPI) // HX: yes, they are different val () = assert (abs (fx - fPI) < 1E-8) // var state: gmp_randstate_vt val () = gmp_randinit_default (state) val () = mpf_urandomb (x, state, 100UL) val () = (print "x = "; print_mpf (x, 16); print_newline ()) val () = gmp_randclear (state) // var a: mpz_vt val () = mpz_init_set (a, 141421) val () = gmp_randinit_lc_2exp (state, a, 29UL(*c*), 5UL(*m2exp*)) val () = mpf_urandomb (x, state, 100UL) val () = (print "x = "; print_mpf (x, 16); print_newline ()) val () = mpz_clear (a) val () = gmp_randclear (state) // val _err = gmp_randinit_lc_2exp_size (state, 100UL) val () = mpf_urandomb (x, state, 100UL) val () = (print "x = "; print_mpf (x, 16); print_newline ()) val () = gmp_randclear (state) // val () = mpf_random2 (x, (mp_size_t)100, (mp_exp_t)10) val () = (print "x = "; print_mpf (x, 16); print_newline ()) val () = mpf_sqrt (x) val () = mpf_pow_ui (x, 2UL) val () = (print "x = "; print_mpf (x, 16); print_newline ()) var exp: mp_exp_t val str = mpf_get_str (exp, 10, 16, x) val () = (print "str = "; print str; print_newline ()) val () = strptr_free (str) val () = mpf_random2 (x, (mp_size_t)~100, (mp_exp_t)10) val () = (print "x = "; print_mpf (x, 16); print_newline ()) val str = mpf_get_str (exp, 10, 00, x) val () = (print "str = "; print str; print_newline ()) val () = strptr_free (str) // val () = mpf_set_d (x, fPI) val () = assert (mpf_sgn (x) = 1) val () = assert (mpf_get_d (x) = fPI) // val () = mpf_neg (x) val () = assert (mpf_sgn (x) = ~1) val () = assert (mpf_get_d (x) = ~fPI) val () = mpf_abs (x) val () = assert (mpf_get_d (x) = fPI) // val () = mpf_init2 (y, 256UL) val () = mpf_set_d (y, 4*fPI) val () = assert (mpf_cmp_si (y, 12L) > 0) val () = assert (mpf_cmp_ui (y, 13UL) < 0) val () = assert (mpf_cmp_d (y, 12.56) > 0) val () = assert (mpf_get_d (y) = 4*fPI) // val () = mpf_init_set (z, y) val () = mpf_add (z, 123456789UL) val () = mpf_sub (z, 123456789UL) val () = assert (mpf_get_d (y) = mpf_get_d (z)) val () = mpf_ui_sub2 (z, 123456789UL) val () = mpf_ui_sub2 (z, 123456789UL) val () = assert (mpf_get_d (y) = mpf_get_d (z)) // val () = mpf_add (z, x, y) val () = mpf_mul (x, z, y) val () = mpf_div (z, x, y) val () = mpf_sqrt (y, x) (* val () = printf ( "x = %g, y = %g, z = %g\n", @(mpf_get_d (x), mpf_get_d (y), mpf_get_d (z)) ) // end of [val] *) val () = mpf_clear (x) val () = mpf_clear (y) val () = mpf_clear (z) } // end of [mpf_test] (* ****** ****** *) implement main () = () where { // val () = mpz_test () // val () = mpq_test () // val () = mpf_test () // val () = print "[libc_gmp.dats] testing passes!\n" } // end of [main] (* ****** ****** *) (* end of [libc_gmp.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_dlfcn.dats0000664000175000017500000000342012223166161021346 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/dlfcn.sats *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 // (* ****** ****** *) staload "libc/SATS/dlfcn.sats" (* ****** ****** *) typedef ftrig_t = (double) -> double fun ftrig_get {l:addr} .<>. ( pf_lib: !dlopen_v l | p_lib: ptr l, name: string ) : ftrig_t = let val (fpf_msg | msg) = dlerror () // clearing any existing error prval () = fpf_msg (msg) val ftrig = dlsym (pf_lib | p_lib, name) val (fpf_msg | msg) = dlerror () // see if there is any error val p_msg = ptr_of_strptr (msg) prval () = fpf_msg (msg) val () = assert_errmsg (p_msg = null, #LOCATION) in __cast (ftrig) where { extern castfn __cast (x: ptr):<> ftrig_t } end // end of [ftrig_get] (* ****** ****** *) #define PI 3.1415926535898 implement main () = () where { val (pf_lib | p_lib) = dlopen_exn ("libm.so", RTLD_LAZY) // val fsin = ftrig_get (pf_lib | p_lib, "sin") val sin30 = fsin (PI / 6) val () = (print "sin30 = "; print sin30; print_newline ()) val sin45 = fsin (PI / 4) val () = (print "sin45 = "; print sin45; print_newline ()) val sin60 = fsin (PI / 3) val () = (print "sin60 = "; print sin60; print_newline ()) // val fcos = ftrig_get (pf_lib | p_lib, "cos") val cos30 = fcos (PI / 6) val () = (print "cos30 = "; print cos30; print_newline ()) val cos45 = fcos (PI / 4) val () = (print "cos45 = "; print cos45; print_newline ()) val cos60 = fcos (PI / 3) val () = (print "cos60 = "; print cos60; print_newline ()) // (* val () = dlclose_exn (pf_lib | p_lib) *) val err = dlclose (pf_lib | p_lib) val () = assert_errmsg (err = 0, #LOCATION) prval None_v () = pf_lib } // end of [main] (* ****** ****** *) (* end of [libc_dlfcn.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funheap_braun.dats0000664000175000017500000000330512223166161023444 0ustar hwxihwxi(* // some testing code for [libats/funheap_braun] // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 *) (* ****** ****** *) staload H = "libats/SATS/funheap_braun.sats" staload _(*anon*) = "libats/DATS/funheap_braun.dats" typedef elt = int typedef heap_t = $H.heap (elt) (* ****** ****** *) implement main (argc, argv) = () where { val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 100 // default val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [va] val [n:int] n = int1_of_int n val () = assert (n > 0) val cmp = lam (x1: elt, x2: elt): Sgn = compare_int_int (x1, x2) var heap: heap_t = $H.funheap_make_nil () var i: Nat // uninitialized val () = for (i := n; i > 0; i := i-1) let val elt = i val () = $H.funheap_insert (heap, elt, cmp) in // nothing end // end of [val] // val sz = $H.funheap_size (heap) val () = (print "funheap_size (heap) = "; print sz; print_newline ()) val ht = $H.funheap_height (heap) val () = (print "funheap_size (heap) = "; print ht; print_newline ()) // val () = loop (sz, heap) where { val sz = size1_of_size (sz) fun loop {n:nat} .. ( sz: size_t n, heap: &heap_t ) : void = let var x: elt? // uninitialized in if sz > 0 then let val removed = $H.funheap_delmin (heap, x, cmp) val () = assert_errmsg (removed, #LOCATION) prval () = opt_unsome {elt} (x) // val () = (print x; print_newline ()) in loop (sz-1, heap) end // end of [if] end // end of [loop] } // end of [loop] } // end of [main] (* ****** ****** *) (* end of [libats_funheap_braun.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_genarrays.dats0000664000175000017500000000607112223166161022625 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/genarrays.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/fmatrix.dats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" (* ****** ****** *) extern fun{a:t@ype} fprint_elt (out: FILEref, x: a): void fn{a:t@ype} GEMAT_fprint {ord:order} {m,n:nat} {ld:pos} ( out: FILEref , ord: ORDER ord , M: &GEMAT (a, m, n, ord, ld), m: size_t m, n: size_t n, ld: size_t ld ) : void = () where { var !p_clo = @lam ( pf: !unit_v | i: size_t, j: size_t, x: &a ) : void = $effmask_all let val () = if j > 0 then fprint (out, ", ") val () = if (i > 0 andalso j = 0) then print "\n" val () = fprint_elt (out, x) in // empty end // end of [val] prval pf = unit_v () val () = GEMAT_ptr_iforeach_vclo (pf | ord, M, !p_clo, ORDERrow, m, n, ld) where { } // end of [val] prval unit_v () = pf } // end of [GEMAT_fprint] (* ****** ****** *) dynload "libats/DATS/genarrays.dats" dynload "libats/DATS/fmatrix.dats" (* ****** ****** *) typedef T = int implement fprint_elt (out, x) = fprintf (out, "%2i", @(x)) #define sz2i int1_of_size1 implement main () = let #define X 10 val (pf1_mat | p1, fp1) = GEMAT_row_ptr_allocfree (X, X) // val () = GEMAT_ptr_initialize_fun ( ORDERrow, !p1, X, X, X, lam (i, j, x) => x := sz2i i - sz2i j ) // end of [val] // val () = print ("M1 =\n") val () = GEMAT_fprint (stdout_ref, ORDERrow, !p1, X, X, X) val () = print_newline () // val (pf2_mat | p2, fp2) = GEMAT_row_ptr_allocfree (X, X) // // for testing [GEMAT_ptr_copy] val () = GEMAT_ptr_copy (ORDERrow, !p1, !p2, X, X, X, X) val () = print ("M2(=M1) =\n") val () = GEMAT_fprint (stdout_ref, ORDERrow, !p2, X, X, X) val () = print_newline () // val () = GEMAT_ptr_initialize_elt (ORDERrow, !p2, X, X, X, 10) val () = print ("M2 =\n") val () = GEMAT_fprint (stdout_ref, ORDERrow, !p2, X, X, X) val () = print_newline () // val ul = UPLOupper and dg = DIAGnonunit prval (pf1_trm, fpf1_mat) = TRMAT_v_of_GEMAT_v (pf1_mat, ul, dg) prval (pf2_trm, fpf2_mat) = TRMAT_v_of_GEMAT_v (pf2_mat, ul, dg) val () = TRMAT_ptr_copy (ORDERrow, ul, dg, !p1, !p2, X, X, X) prval () = pf1_mat := fpf1_mat (pf1_trm) prval () = pf2_mat := fpf2_mat (pf2_trm) // val ul = UPLOlower and dg = DIAGunit prval (pf1_trm, fpf1_mat) = TRMAT_v_of_GEMAT_v (pf1_mat, ul, dg) prval (pf2_trm, fpf2_mat) = TRMAT_v_of_GEMAT_v (pf2_mat, ul, dg) val () = TRMAT_ptr_copy (ORDERrow, ul, dg, !p1, !p2, X, X, X) prval () = pf1_mat := fpf1_mat (pf1_trm) prval () = pf2_mat := fpf2_mat (pf2_trm) // val () = print ("M2(=M1) =\n") val () = GEMAT_fprint (stdout_ref, ORDERrow, !p2, X, X, X) val () = print_newline () // val () = fp1 (pf1_mat | p1) // freeing M1 val () = fp2 (pf2_mat | p2) // freeing M2 // in print "[libats_genarrays.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [libats_genarrays.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_matrix.dats0000664000175000017500000000317112223166161022316 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/matrix.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) // staload "prelude/SATS/matrix.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/matrix.dats" (* ****** ****** *) implement main (argc, argv) = let val () = () where { #define row 2 #define col 5 val M = matrix_make_arrpsz{int}( row, col, $arrpsz (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ) // end of [val] // // testing [matrix_iforeach_fun] // val () = print "M (0-9) =\n" val () = matrix_iforeach_fun (M, f, row, col) where { fn f ( i: sizeLt row, j: sizeLt col, x: &int ) :<> void = $effmask_all let val () = if i+j > 0 then (if j = 0 then print "\n" else print ", ") in print x end // end of [f] } // end of [val] val () = print_newline () // // testing [matrix_iforeach_vclo] // val () = print "M (0-9) =\n" prval pf = unit_v () val () = matrix_iforeach_vclo {unit_v} (pf | M, !p_f, row, col) where { var !p_f = @lam (pf: !unit_v | i: sizeLt row, j: sizeLt col, x: &int): void = $effmask_all (let val () = if i+j > 0 then (if j = 0 then print "\n" else print ", ") in print x end) // end of [$effmask_all] } // end of [val] val () = print_newline () prval unit_v () = pf } // end of [val] in print "The run of [prelude_matrix.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_matrix.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_matrix0.dats0000664000175000017500000000556112223166161022403 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/matrix0.sats *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // staload "prelude/SATS/matrix0.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/matrix0.dats" (* ****** ****** *) implement main () = let // #define row 5; #define col 2; #define asz 10; // val () = () where { prval pf_mul = mul_istot {row,col} () prval () = mul_elim (pf_mul) // val M = matrix0_make_arrpsz {int}{row,col}( row, col, $arrpsz (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ) // end of [val] // var i: int and j: int // uninitialized val () = for* (j: int?) => (i := 0; i < row; i := i + 1) let val () = for (j := 0; j < col; j := j + 1) let val () = if j > 0 then print ", " in print M[i,j] end // end of [val] val () = print_newline () in // nothing end // end of [val] } // end of [val] // val () = () where { val M = matrix0_make_elt (row, col, 0) var i: int and j: int // uninitialized val () = for* (j: int?) => (i := 0; i < row; i := i + 1) { val () = for (j := 0; j < col; j := j + 1) M[i,j] := i * col + j } // end of [for*] val () = loop1 (0) where { fun loop1 {i:nat | i <= row} (i: int i): void = if i < row then loop2 (i, 0) else () // end of [loop1] and loop2 {i,j:nat | i < row; j <= col} (i: int i, j: int j): void = if j < col then begin if j > 0 then print ", "; print M[i,j]; loop2 (i, j+1) end else begin print_newline (); loop1 (i+1) end // end of [if] // end of [loop2] } // end of [val] } (* end of [val] *) // val () = () where { #define row1 2; #define col1 5 prval pf_mul = mul_istot {row1,col1} () prval () = mul_elim (pf_mul) // val M = matrix0_make_arrpsz {int}{row1,col1}( row1, col1, $arrpsz (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ) // end of [val] val f = lam ( i: size_t, j: size_t, x: &int ) : void = let val i = int_of_size i and j = int_of_size j in $effmask_all (printf ("M[%i,%i] = %i\n", @(i, j, x))) end // end of [val] val () = matrix0_iforeach (M, f) } // end of [val] // val () = () where { #define row 3; #define col 7 val M = matrix0_tabulate (row, col, lam (i, j) => int_of_size ((i+1) * j)) val f = lam (i: size_t, j: size_t, x: &int) : void = let val i = int_of_size i and j = int_of_size j in $effmask_all (printf ("M[%i,%i] = %i\n", @(i, j, x))) end // end of [val] val () = matrix0_iforeach (M, f) } // end of [val] // in print "The run of [prelude_matrix0.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_matrix0.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linbitvec.dats0000664000175000017500000000743012223166161022611 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/linbitvec.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: the 1st of August, 2010 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload "libats/SATS/linbitvec.sats" (* ****** ****** *) fun bitvec_make_rand {n:nat} ( n: size_t n ) : [l:addr] ( free_gc_v l, BITVEC n @ l | ptr l ) = let val (pf_gc, pf_vec | p_vec) = bitvec_make (n) val () = loop (!p_vec, n, 0) where { fun loop {i:nat | i <= n} .. (vec: &BITVEC n, n: size_t n, i: size_t i): void = if i < n then let val b = $RAND.randint (2) val () = bitvec_set_at (vec, i, b) val b1 = bitvec_get_at (vec, i) (* val () = begin prerr "bitvec_make_rand: i = "; prerr i; prerr_newline () end val () = begin prerr "bitvec_make_rand: b = "; prerr b; prerr_newline () end val () = begin prerr "bitvec_make_rand: b1 = "; prerr b1; prerr_newline () end *) val () = $effmask_exn (assert (b = b1)) in loop (vec, n, i+1) end // end of [if] // end of [loop] } // end of [val] in (pf_gc, pf_vec | p_vec) end // end of [bitvec_make_rand] (* ****** ****** *) fun print_bitvec {n:nat} (v: &BITVEC n, n: size_t n) : void = loop (v, n, 0) where { fun loop {i:nat | i <= n} .. (v: &BITVEC n, n: size_t n, i: size_t i): void = if i < n then let val () = if i > 0 then print "," val () = print (bitvec_get_at (v, i)) in loop (v, n, i+1) end // end of [if] } // end of [print_bitvec] (* ****** ****** *) #define N 41 #define N1 0 #define N2 32 // val (pf0_gc, pf0_vec | p0_vec) = bitvec_make_rand (N) val () = print "vec0 = " val () = print_bitvec (!p0_vec, N) val () = print_newline () // val (pf1_gc, pf1_vec | p1_vec) = bitvec_make (N) val () = bitvec_copy (!p1_vec, !p0_vec, N) val () = bitvec_xor (!p1_vec, !p0_vec, N) val () = print "vec1 = " val () = print_bitvec (!p1_vec, N) val () = print_newline () val () = assert (bitvec_is_nil (!p1_vec, N)) // val () = bitvec_neg (!p1_vec, N) val () = print "vec1 = " val () = print_bitvec (!p1_vec, N) val () = print_newline () val () = assert (bitvec_is_all (!p1_vec, N)) // val (pf1_gc, pf1_vec | p1_vec) = bitvec_make (N) val () = bitvec_copy (!p1_vec, !p0_vec, N) val () = bitvec_neg (!p1_vec, N) val () = bitvec_and (!p1_vec, !p0_vec, N) val () = print "vec1 = " val () = print_bitvec (!p1_vec, N) val () = print_newline () val () = assert (bitvec_is_nil (!p1_vec, N)) // val (pf1_gc, pf1_vec | p1_vec) = bitvec_make (N) val () = bitvec_copy (!p1_vec, !p0_vec, N) val () = bitvec_neg (!p1_vec, N) val () = bitvec_or (!p1_vec, !p0_vec, N) val () = print "vec1 = " val () = print_bitvec (!p1_vec, N) val () = print_newline () val () = assert (bitvec_is_all (!p1_vec, N)) // val (pf2_gc, pf2_vec | p2_vec) = bitvec_make_rand (N) val () = print "vec2 = " val () = print_bitvec (!p2_vec, N) val () = print_newline () // val (pf01_gc, pf01_vec | p01_vec) = bitvec_make_rand (N) val () = bitvec_copy (!p01_vec, !p0_vec, N) val () = print "vec01 = " val () = print_bitvec (!p01_vec, N) val () = print_newline () // val () = bitvec_diff (!p01_vec, !p2_vec, N) // val (pf21_gc, pf21_vec | p21_vec) = bitvec_make_rand (N) val () = bitvec_copy (!p21_vec, !p2_vec, N) val () = print "vec21 = " val () = print_bitvec (!p21_vec, N) val () = print_newline () // val () = bitvec_diff (!p21_vec, !p0_vec, N) // val () = bitvec_or (!p21_vec, !p01_vec, N) // val () = bitvec_xor (!p0_vec, !p2_vec, N) val () = assert (bitvec_equal (!p0_vec, !p21_vec, N)) (* ****** ****** *) implement main () = () where { val () = print "[prelude_linbitvec.dats] testing passes!\n" } // end of [main] (* ****** ****** *) (* end of [libats_linbitvec.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linqueue_arr.dats0000664000175000017500000000434712223166161023331 0ustar hwxihwxi(* // // Author: Hongwei Xi (March, 2010) // *) (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload Q = "libats/SATS/linqueue_arr.sats" stadef QUEUE = $Q.QUEUE stadef QUEUE0 = $Q.QUEUE0 (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "libats/DATS/linqueue_arr.dats" staload _(*anon*) = "libats/ngc/DATS/deque_arr.dats" (* ****** ****** *) #define CAP 2000000 #define N1 1500000; #define N2 1000000 (* ****** ****** *) implement main () = () where { typedef itm = int var q: QUEUE0 (itm) // val () = $Q.queue_initialize (q, CAP) // val () = loop (q, N1, 0) where { fun loop {i,j:nat | i+j <= CAP} .. (q: &QUEUE (itm, CAP, j) >> QUEUE (itm, CAP, i+j), i: int i, j: int j): void = if i > 0 then let val () = $Q.queue_insert (q, j) in loop (q, i-1, j+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (q, 0) where { fun loop {i:nat | i <= N2} .. (q: &QUEUE (itm, CAP, N1-i) >> QUEUE (itm, CAP, N1-N2), i: int i): void = if i < N2 then let val x = $Q.queue_remove (q) val () = assert_errmsg (x = i, #LOCATION) in loop (q, i+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (q, N2, N1) where { fun loop {i,j:nat | i <= N2} .. (q: &QUEUE (itm, CAP, N1-i) >> QUEUE (itm, CAP, N1), i: int i, j: int j): void = if i > 0 then let val () = $Q.queue_insert (q, j) in loop (q, i-1, j+1) end // end of [val] // end of [loop] } // end of [val] // #define CAP2 N1 val () = $Q.queue_update_capacity (q, CAP2) // val () = loop (q, 0) where { fun loop {i:nat | i <= N1} .. (q: &QUEUE (itm, CAP2, N1-i) >> QUEUE (itm, CAP2, 0), i: int i): void = if i < N1 then let val x = $Q.queue_remove (q) val () = assert_errmsg (x = N2+i, #LOCATION) in loop (q, i+1) end // end of [val] // end of [loop] } // end of [val] // val () = $Q.queue_uninitialize_vt {itm} (q) // val () = print "[libats_ngc_queue_arr.dats] testing passes!\n" // } // end of [main] (* ****** ****** *) (* end of [libats_ngc_queue_arr.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_dirent.dats0000664000175000017500000001300712223166161021547 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/dirent.sats *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2009 (* ****** ****** *) staload "libc/SATS/stdlib.sats" staload "libc/SATS/dirent.sats" (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/lazy_vt.dats" (* ****** ****** *) extern fun print_direntptr (p: &direntptr_gc): void = "print_direntptr" // end of [print_direntptr] implement print_direntptr (p) = let prval pf_ent = p.1 // p = (pf_gc, pf | p_ent) val (fpf_x | x) = dirent_get_d_name !(p.2) val () = print_strptr (x) prval () = fpf_x (x) in p.1 := pf_ent end // end of [print_direntptr] (* ****** ****** *) fun compare_direntptr_direntptr .<>. (p1: &direntptr_gc, p2: &direntptr_gc):<> int = let prval pf1_ent = p1.1 val (fpf_x1 | x1) = dirent_get_d_name !(p1.2) prval pf2_ent = p2.1 val (fpf_x2 | x2) = dirent_get_d_name !(p2.2) val sgn = compare ($UN.castvwtp1 {string} (x1), $UN.castvwtp1 {string} (x2)) prval () = fpf_x1 (x1) and () = fpf_x2 (x2) prval () = p1.1 := pf1_ent and () = p2.1 := pf2_ent in sgn end // end of [compare_direntptr_direntptr] (* ****** ****** *) fn prerr_usage (cmd: string): void = prerrf ("Usage: %s [dirname]\n", @(cmd)) // end of [prerr_usage] fn ls (dirname: string): void = let val (pfopt_dir | p_dir) = opendir_err (dirname) in if (p_dir > null) then let prval Some_v (pf_dir) = pfopt_dir val ents = direntptr_stream_vt_make_DIR (pf_dir | p_dir) val [n:int] (nent, ents) = list_vt_of_stream_vt (ents) val nent_sz = size1_of_int1 (nent) var !p_arr with pf_arr = @[direntptr_gc][nent]() val () = loop_init {direntptr_gc} (pf_arr | p_arr, ents) where { fun loop_init {a:viewtype} {n:nat} {l:addr} .. ( pf_arr: !array_v (a?, n, l) >> array_v (a, n, l) | p: ptr l, xs: list_vt (a, n) ) : void = case+ xs of | ~list_vt_cons (x, xs) => let prval (pf1_at, pf2_arr) = array_v_uncons {a?} (pf_arr) val () = !p := x val () = loop_init {a} (pf2_arr | p+sizeof, xs) in pf_arr := array_v_cons {a} (pf1_at, pf2_arr) end // end of [list_vt_cons] | ~list_vt_nil () => let prval () = array_v_unnil {a?} (pf_arr) in pf_arr := array_v_nil {a} () end // end of [list_vt_nil] // end of [loop] } // end of [val] // val () = qsort {direntptr_gc} (!p_arr, nent_sz, sizeof, compare_direntptr_direntptr) // end of [qsort] // val () = printf ( "The entries in the directory [%s] are listed as follows:\n", @(dirname) ) // end of [val] // prval pfu = unit_v () val () = let var !p_f = @lam ( pfu: !unit_v | p_ent: &direntptr_gc ) : void = $effmask_all (print_direntptr (p_ent); print_newline ()) // end of [@lam] in array_ptr_foreach_vclo (pfu | !p_arr, !p_f, nent_sz) end // end of [val] prval unit_v () = pfu // val () = array_ptr_clear_fun ( !p_arr, nent_sz, lam p = ptr_free {dirent?} (p.0, p.1 | p.2) ) // end of [val] // in printf ("There are %i entries in the directory [%s]\n", @(nent, dirname)) end else let prval None_v () = pfopt_dir in printf ("*** ERROR ***: the directory [%s] cannot be opened\n", @(dirname)) end // end of [if] end // end of [ls] (* ****** ****** *) fn ls2 (dirname: string): void = let val (pfopt_dir | p_dir) = opendir_err (dirname) in if p_dir > null then let prval Some_v (pf_dir) = pfopt_dir val ents = direntptr_stream_vt_make_DIR (pf_dir | p_dir) val nams = stream_vt_map_fun (ents, f) where { fun f ( p: &direntptr_gc >> direntptr_gc? ) : strptr1 = x1 where { prval pfent = p.1 val (fpf_x | x) = dirent_get_d_name !(p.2) prval () = p.1 := pfent val x1 = strptr_dup (x) prval () = fpf_x (x) val () = ptr_free {dirent?} (p.0, p.1 | p.2) } // end of [fun f] } // end of [nams] val (n, nams) = list_vt_of_stream_vt (nams) val nams = list_vt_mergesort (nams, !p_cmp) where { var !p_cmp = @lam (x1: &strptr1, x2: &strptr1): Sgn = compare ($UN.castvwtp1 {string} (x1), $UN.castvwtp1 {string} (x2)) // end of [p_cmp] } // end of [val] val () = loop (nams) where { fun loop (nams: List_vt (strptr1)): void = case+ nams of | ~list_vt_cons (nam, nams) => loop (nams) where { val () = print_strptr (nam); val () = print_newline (); val () = strptr_free (nam) } // end of [string] | ~list_vt_nil () => () } // end of [val] val () = printf ("There is [%i] entries in total.\n", @(n)) in // nothing end else let prval None_v () = pfopt_dir in printf ("*** ERROR ***: the directory [%s] cannot be opened\n", @(dirname)) end // end of [if] end // end of [ls2] (* ****** ****** *) // listing all of the files in a given directory implement main (argc, argv) = let val () = if (argc < 2) then prerr_usage (argv.[0]) val () = assert (argc >= 2); val dirname = argv.[1] var i: Nat // uninitialized val () = for (i := 1; i < argc; i := i+1) ls (argv.[i]) val () = for (i := 1; i < argc; i := i+1) ls2 (argv.[i]) in // nothing end // end of [main] (* ****** ****** *) (* end of [libc_dirent.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funralist_nested.dats0000664000175000017500000000555612223166161024212 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/funralist_nested.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload RA = "libats/SATS/funralist_nested.sats" staload _(*anon*) = "libats/DATS/funralist_nested.dats" stadef ralist = $RA.ralist (* ****** ****** *) fn genlist {n:nat} (n: int n): ralist (int, n) = let fun loop {i,j:nat | i+j == n} .. (i: int i, xs: ralist (int, j)): ralist (int, n) = if i > 0 then loop (i - 1, $RA.funralist_cons (i, xs)) else xs val xs = $RA.funralist_make_nil () in loop (n, xs) end // end of [genlist] (* ****** ****** *) #define N 100 // default implement main (argc, argv) = () where { val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = N val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = (int1_of_int)n // val () = assertloc (n > 0) val xs = genlist (n) val () = assertloc (n = $RA.funralist_length xs) // var i: int = 0 val () = $RA.funralist_foreach_vclo {int@i} (view@ i | xs, !p_f) where { var !p_f = @lam ( pf: !int @ i | x: int ) : void = $effmask_all let val () = i := i + 1; val () = assert (x = i) in // nothing end // end of [...] } // end of [val] // val () = loop (xs, n, 1) where { fun loop {n:nat} (xs: ralist (int, n), n: int n, k: int): void = if n > 0 then let var x0: int; val xs = $RA.funralist_uncons (xs, x0) val () = assert_errmsg (x0 = k, #LOCATION) in loop (xs, n-1, k+1) end else () // end of [loop] } // end of [val] // var i: Nat = 0 val () = for (i := 0; i < n; i := i + 1) let val xs = $RA.funralist_update (xs, i, i+i+1) val () = assert_errmsg ($RA.funralist_lookup (xs, i) = i+i+1, #LOCATION) in (*nothing*) end // end of [for] } // end of [main] (* ****** ****** *) //// // // // This file is for Solution 4, BU CAS CS 520, Fall, 2008 // // // // testing some of the implemented ralist operations // // How to compile: // // atscc -O3 -o test_ralist test_ralist.dats ralist.sats ralist_solution.dats // staload RA = "funralist.dats" implement main () = let val xs = ralist_gen (100) val n = $RA.ralist_length (xs) val () = begin print "n(100) = "; print n; print_newline () end val x = $RA.ralist_lookup (xs, 50) val () = begin print "x(51) = "; print x; print_newline () end val xs = $RA.ralist_update (xs, 50, ~51) val xs = $RA.ralist_update (xs, 51, ~52) val x = $RA.ralist_lookup (xs, 50) val () = begin print "x(-51) = "; print x; print_newline () end val x = $RA.ralist_lookup (xs, 51) val () = begin print "x(-52) = "; print x; print_newline () end in // empty end // end [main] (* ****** ****** *) (* end [libats_funralist_nested.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_rarray.dats0000664000175000017500000000275412223166161022136 0ustar hwxihwxi(* // // Author: Hongwei Xi (September, 2010) // *) (* ****** ****** *) staload "libats/SATS/rarray.sats" staload _(*anon*) = "libats/DATS/rarray.dats" (* ****** ****** *) fun{a:viewt@ype} array_ptr_rforeach_clo {v:view} {n:nat} {l:addr} .<>. ( pf: !v | A: &(@[a][n]), f: &(!v | &a) - void, n: size_t n ) :<> void = let fun loop {n:nat} {l:addr} .. ( pf: !v, pfarr: !rarray_v (a, n, l) | p: ptr l, n: size_t n, f: &(!v | &a) - void ) :<> void = if n > 0 then let prval @(pf1arr, pf1at) = rarray_v_uncons (pfarr) val p1 = p - sizeof val () = f (pf | !p1) val () = loop (pf, pf1arr | p1, n-1, f) prval () = pfarr := rarray_v_cons {a} (pf1arr, pf1at) in // nothing end else () // end of [if] // end of [loop] prval pfarr = view@ (A) val (pfmul | ofs) = mul2_size1_size1 (n, sizeof) prval pfarr = rarray_v_of_array_v {a} (pfmul, pfarr) val () = loop (pf, pfarr | &A+ofs, n, f) prval () = view@(A) := array_v_of_rarray_v {a} (pfmul, pfarr) in // nothing end // end of [array_ptr_rforeach_clo] (* ****** ****** *) implement main () = () where { var !p_arr = @[int](0, 1, 2, 3, 4, 5, 6, 7, 8, 9) prval pfu = unit_v val () = array_ptr_rforeach_clo (pfu | !p_arr, !p_clo, 10) where { var !p_clo = @lam (pf: !unit_v | x: &int): void = $effmask_all (print x) } // end of [val] val () = print_newline () prval unit_v () = pfu } // end of [main] (* ****** ****** *) (* end of [libats_rarray.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/Makefile0000664000175000017500000002651412223166161020063 0ustar hwxihwxi# # # (kind of) unit testing for ATS library code # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: prelude_array prelude_array: prelude_array.dats $(ATSCC) -O2 -o $@ $< && ./prelude_array cleanall:: ; $(RMF) prelude_array checkall:: prelude_array0 prelude_array0: prelude_array0.dats $(ATSCC) -O2 -o $@ $< && ./prelude_array0 cleanall:: ; $(RMF) prelude_array0 checkall:: prelude_bool prelude_bool: prelude_bool.dats $(ATSCC) -O2 -o $@ $< && ./prelude_bool cleanall:: ; $(RMF) prelude_bool checkall:: prelude_char prelude_char: prelude_char.dats $(ATSCC) -O2 -o $@ $< && ./prelude_char cleanall:: ; $(RMF) prelude_char checkall:: prelude_float prelude_float: prelude_float.dats $(ATSCC) -O2 -o $@ $< && ./prelude_float cleanall:: ; $(RMF) prelude_float checkall:: prelude_integer prelude_integer: prelude_integer.dats $(ATSCC) -O2 -o $@ $< && ./prelude_integer cleanall:: ; $(RMF) prelude_integer checkall:: prelude_lazy_vt prelude_lazy_vt: prelude_lazy_vt.dats $(ATSCC) -O2 -o $@ $< && ./prelude_lazy_vt cleanall:: ; $(RMF) prelude_lazy_vt checkall:: prelude_list prelude_list: prelude_list.dats $(ATSCC) -O2 -o $@ $< && ./prelude_list cleanall:: ; $(RMF) prelude_list checkall:: prelude_list_vt prelude_list_vt: prelude_list_vt.dats $(ATSCC) -O2 -o $@ $< && ./prelude_list_vt cleanall:: ; $(RMF) prelude_list_vt checkall:: prelude_dlist_vt prelude_dlist_vt: prelude_dlist_vt.dats $(ATSCC) -O2 -o $@ $< && ./prelude_dlist_vt cleanall:: ; $(RMF) prelude_dlist_vt checkall:: prelude_matrix prelude_matrix: prelude_matrix.dats $(ATSCC) -O2 -o $@ $< && ./prelude_matrix cleanall:: ; $(RMF) prelude_matrix checkall:: prelude_matrix0 prelude_matrix0: prelude_matrix0.dats $(ATSCC) -O2 -o $@ $< && ./prelude_matrix0 cleanall:: ; $(RMF) prelude_matrix0 checkall:: prelude_string prelude_string: prelude_string.dats $(ATSCC) -O2 -o $@ $< && ./prelude_string cleanall:: ; $(RMF) prelude_string ###### checkall:: libc_math libc_math: libc_math.dats $(ATSCC) -O2 -o $@ $< -lm && ./libc_math cleanall:: ; $(RMF) libc_math checkall:: libc_complex libc_complex: libc_complex.dats $(ATSCC) -O2 -o $@ $< -lm && ./libc_complex cleanall:: ; $(RMF) libc_complex ###### checkall:: libc_dirent libc_dirent: libc_dirent.dats $(ATSCC) -O2 -o $@ $< && ./libc_dirent "." cleanall:: ; $(RMF) libc_dirent checkall:: libc_dlfcn libc_dlfcn: libc_dlfcn.dats $(ATSCC) -rdynamic -O2 -o $@ $< -ldl && ./libc_dlfcn "." cleanall:: ; $(RMF) libc_dlfcn ###### checkall:: libc_gmp libc_gmp: libc_gmp.dats $(ATSCC) -D_GNU_SOURCE -O2 -o $@ $< -lats -lgmp && ./libc_gmp cleanall:: ; $(RMF) libc_gmp ###### checkall:: libc_printf libc_printf: libc_printf.dats $(ATSCC) -o $@ $< && ./libc_printf cleanall:: ; $(RMF) libc_printf ###### checkall:: libc_pwd libc_pwd: libc_pwd.dats $(ATSCC) -O2 -o $@ $< && ./libc_pwd cleanall:: ; $(RMF) libc_pwd ###### checkall:: libc_random libc_random: libc_random.dats $(ATSCC) -O2 -o $@ $< && ./libc_random cleanall:: ; $(RMF) libc_random ###### checkall:: libc_sched libc_sched: libc_sched.dats $(ATSCC) -D_GNU_SOURCE -O2 -o $@ $< && ./libc_sched cleanall:: ; $(RMF) libc_sched ###### checkall:: libc_stdio libc_stdio: libc_stdio.dats ; $(ATSCC) -O2 -o $@ $< && ./libc_stdio cleanall:: ; $(RMF) libc_stdio checkall:: libc_stdlib libc_stdlib: libc_stdlib.dats ; $(ATSCC) -O2 -o $@ $< && ./libc_stdlib cleanall:: ; $(RMF) libc_stdlib ###### checkall:: libc_time libc_time: libc_time.dats $(ATSCC) -D_XOPEN_SOURCE -O2 -o $@ $< && ./libc_time cleanall:: ; $(RMF) libc_time ###### checkall:: libc_unistd libc_unistd: libc_unistd.dats ; $(ATSCC) -O2 -o $@ $< && ./libc_unistd cleanall:: ; $(RMF) libc_unistd ###### checkall:: libc_sys_utsname libc_sys_utsname: libc_sys_utsname.dats ; $(ATSCC) -O2 -o $@ $< && ./libc_sys_utsname cleanall:: ; $(RMF) libc_sys_utsname ###### checkall:: libc_gdbm_gdbm libc_gdbm_gdbm: libc_gdbm_gdbm.dats ; $(ATSCC) -O2 -o $@ $< -lgdbm && ./libc_gdbm_gdbm cleanall:: ; $(RMF) libc_gdbm_gdbm gdbmtest.gdbm # checkall:: libc_gdbm_ndbm libc_gdbm_ndbm: libc_gdbm_ndbm.dats ; $(ATSCC) -O2 -o $@ $< -lgdbm -lgdbm_compat && ./libc_gdbm_ndbm cleanall:: ; $(RMF) libc_gdbm_ndbm ndbmtest.dir ndbmtest.pag ###### checkall:: libats_funarray_braun libats_funarray_braun: libats_funarray_braun.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< \ && ./libats_funarray_braun 0 1 2 3 4 5 6 7 8 9 cleanall:: ; $(RMF) libats_funarray_braun ###### checkall:: libats_fundeque_fingertree libats_fundeque_fingertree: libats_fundeque_fingertree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./libats_fundeque_fingertree 10 cleanall:: ; $(RMF) libats_fundeque_fingertree ###### checkall:: libats_funheap_braun libats_funheap_braun: libats_funheap_braun.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funheap_braun checkall:: libats_funheap_binomial libats_funheap_binomial: libats_funheap_binomial.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funheap_binomial ###### checkall:: libats_funmap_avltree libats_funmap_avltree: libats_funmap_avltree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funmap_avltree checkall:: libats_funmap_rbtree libats_funmap_rbtree: libats_funmap_rbtree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funmap_rbtree ###### checkall:: libats_funralist_nested libats_funralist_nested: libats_funralist_nested.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funralist_nested ###### checkall:: libats_funset_avltree libats_funset_avltree: libats_funset_avltree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_funset_avltree ###### checkall:: libats_funset_listord libats_funset_listord: libats_funset_listord.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 1000 cleanall:: ; $(RMF) libats_funset_listord ###### checkall:: libats_genarrays libats_genarrays: libats_genarrays.dats $(ATSCC) -O2 -o $@ $< && ./libats_genarrays cleanall:: ; $(RMF) libats_genarrays ###### checkall:: libats_hashtable_chain libats_hashtable_chain: libats_hashtable_chain.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./libats_hashtable_chain 100000 cleanall:: ; $(RMF) libats_hashtable_chain checkall:: libats_hashtable_linprb libats_hashtable_linprb: libats_hashtable_linprb.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./libats_hashtable_linprb 100000 cleanall:: ; $(RMF) libats_hashtable_linprb ###### checkall:: libats_intinf libats_intinf: libats_intinf.dats $(ATSCC) -O2 -o $@ $< -lats -lgmp && ./libats_intinf 10 cleanall:: ; $(RMF) libats_intinf checkall:: libats_iterint libats_iterint: libats_iterint.dats $(ATSCC) -O2 -o $@ $< && ./libats_iterint cleanall:: ; $(RMF) libats_iterint ###### checkall:: libats_linbitvec libats_linbitvec: libats_linbitvec.dats $(ATSCC) -O2 -o $@ $< && ./libats_linbitvec cleanall:: ; $(RMF) libats_linbitvec ###### checkall:: libats_linheap_binomial libats_linheap_binomial: libats_linheap_binomial.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_linheap_binomial ###### checkall:: libats_linmap_avltree libats_linmap_avltree: libats_linmap_avltree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_linmap_avltree checkall:: libats_linmap_rbtree libats_linmap_rbtree: libats_linmap_rbtree.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_linmap_rbtree checkall:: libats_linmap_skiplist libats_linmap_skiplist: libats_linmap_skiplist.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_linmap_skiplist ###### checkall:: libats_linset_listord libats_linset_listord: libats_linset_listord.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 1000 cleanall:: ; $(RMF) libats_linset_listord ###### checkall:: libats_linqueue_arr libats_linqueue_arr: libats_linqueue_arr.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 1000000 cleanall:: ; $(RMF) libats_linqueue_arr ###### checkall:: libats_linqueue_lst libats_linqueue_lst: libats_linqueue_lst.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 1000000 cleanall:: ; $(RMF) libats_linqueue_lst ###### checkall:: libats_linordset_randbst libats_linordset_randbst: libats_linordset_randbst.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ 1000000 cleanall:: ; $(RMF) libats_linordset_randbst ###### checkall:: libats_linstack_arr libats_linstack_arr: libats_linstack_arr.dats $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./libats_linstack_arr 1000000 cleanall:: ; $(RMF) libats_linstack_arr ###### checkall:: libats_parworkshop libats_parworkshop: libats_parworkshop.dats $(ATSCC) -D_ATS_MULTITHREAD -O2 -o $@ $< -lpthread -lats_mt && ./libats_parworkshop cleanall:: ; $(RMF) libats_parworkshop ###### checkall:: libats_lockref_spin libats_lockref_spin: libats_lockref_spin.dats $(ATSCC) -D_ATS_MULTITHREAD -O2 -o $@ $< -lpthread -lats_mt && ./libats_lockref_spin cleanall:: ; $(RMF) libats_lockref_spin ###### checkall:: libats_rarray libats_rarray: libats_rarray.dats $(ATSCC) -O2 -o $@ $< && ./libats_rarray cleanall:: ; $(RMF) libats_rarray ###### checkall:: libats_refcount libats_refcount: libats_refcount.dats $(ATSCC) -O2 -o $@ $< -lats -lpcre && ./libats_refcount cleanall:: ; $(RMF) libats_refcount ###### checkall:: libats_regexp libats_regexp: libats_regexp.dats $(ATSCC) -O2 -o $@ $< -lats -lpcre && ./libats_regexp cleanall:: ; $(RMF) libats_regexp ###### checkall:: libats_vector libats_vector: libats_vector.dats $(ATSCC) -O2 -o libats_vector libats_vector.dats && ./libats_vector cleanall:: ; $(RMF) libats_vector ###### checkall:: libats_ngc_slist libats_ngc_slist: libats_ngc_slist.dats $(ATSCC) -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) libats_ngc_slist checkall:: libats_ngc_dlist libats_ngc_dlist: libats_ngc_dlist.dats $(ATSCC) -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) libats_ngc_dlist checkall:: libats_ngc_linmap_avltree libats_ngc_linmap_avltree: libats_ngc_linmap_avltree.dats $(ATSCC) -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_ngc_linmap_avltree checkall:: libats_ngc_linmap_pavltree libats_ngc_linmap_pavltree: libats_ngc_linmap_pavltree.dats $(ATSCC) -O2 -o $@ $< && ./$@ 100000 cleanall:: ; $(RMF) libats_ngc_linmap_pavltree ###### checkall:: libats_smlbas_array libats_smlbas_array: libats_smlbas_array.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas && ./$@ cleanall:: ; $(RMF) libats_smlbas_array checkall:: libats_smlbas_array2 libats_smlbas_array2: libats_smlbas_array2.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas && ./$@ cleanall:: ; $(RMF) libats_smlbas_array2 checkall:: libats_smlbas_char libats_smlbas_char: libats_smlbas_char.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas && ./$@ cleanall:: ; $(RMF) libats_smlbas_char checkall:: libats_smlbas_list libats_smlbas_list: libats_smlbas_list.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas && ./$@ cleanall:: ; $(RMF) libats_smlbas_list checkall:: libats_smlbas_string libats_smlbas_string: libats_smlbas_string.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas && ./$@ cleanall:: ; $(RMF) libats_smlbas_string checkall:: libats_smlbas_time libats_smlbas_time: libats_smlbas_time.dats $(ATSCC) -O2 -o $@ $< -lats_smlbas -lm && ./$@ cleanall:: ; $(RMF) libats_smlbas_time ###### RMF=rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_vector.dats0000664000175000017500000000433412223166161022134 0ustar hwxihwxi(* // // Author: Hongwei Xi (September, 2010) // *) (* ****** ****** *) staload V = "libats/SATS/vector.sats" stadef VSHELL = $V.VSHELL stadef VSHELL0 = $V.VSHELL0 stadef VECTOR = $V.VECTOR (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "libats/DATS/vector.dats" (* ****** ****** *) macdef size1 (x) = size1_of_int1 ,(x) implement main () = () where { #define N 10 #define M %(N+N) typedef T = double var V: VSHELL0 // unintialized val () = $V.vector_initialize (V, N) val () = $V.vector_resize (V, M) // val () = loop (V, 0) where { fun loop {m,n:int} {i:nat | i <= N; n+N <= m+i} .. ( V: &VECTOR (T, m, n) >> VECTOR (T, m, n+N-i), i: size_t i ) :<> void = if i < N then let val () = $V.vector_append (V, (double_of)i) in loop (V, i+1) end // end of [if] // end of [loop] } // end of [val] // var i: natLte (N) val () = for* (V: VECTOR (T, M, N)) => (i := 0; i < N; i := i+1) (printf ("V[%i] = %.1f\n", @(i, $V.vector_get_elt_at (V, (size1)i)))) // val () = loop (V, 0) where { fun loop {m,n:int} {i:nat | i <= N; N <= n+i} .. ( V: &VECTOR (T, m, n) >> VECTOR (T, m, n-N+i), i: size_t i ) :<> void = if i < N then let var x: T // uninitialized val () = $V.vector_remove_at (V, 0, x) in loop (V, i+1) end // end of [if] // end of [loop] } // end of [val] // val () = loop (V, 0) where { fun loop {m,n:int} {i:nat | i <= N; n+N <= m+i} .. ( V: &VECTOR (T, m, n) >> VECTOR (T, m, n+N-i), i: size_t i ) :<> void = if i < N then let val () = $V.vector_prepend (V, (double_of)i) in loop (V, i+1) end // end of [if] // end of [loop] } // end of [val] // viewdef V = unit_v prval pfu = unit_v val () = $V.vector_iforeach_vclo {V} (pfu | V, !p_clo) where { var !p_clo = @lam (pf: !V | i: sizeLt N, x: &T) : void =<> $effmask_all let val i = int1_of_size1(i) in printf ("V[%i] = %.1f\n", @(i,x)) end // end of [@lam] } // end of [val] prval unit_v () = pfu // val () = $V.vector_uninitialize (V) // } // end of [main] (* ****** ****** *) (* end of [libats_vector.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_fundeque_fingertree.dats0000664000175000017500000000420212223166161024652 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/fundeque_fingertree.sats *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: November, 2010 // (* ****** ****** *) staload DQ = "libats/SATS/fundeque_fingertree.sats" staload _(*anon*) = "libats/DATS/fundeque_fingertree.dats" stadef deque = $DQ.deque (* ****** ****** *) symintr <| infixr (+) <| overload <| with $DQ.fundeque_cons symintr |> infixr (+) |> overload |> with $DQ.fundeque_snoc symintr >< infix (+) >< overload >< with $DQ.fundeque_append (* ****** ****** *) implement main (argc, argv) = { // macdef N = 10 val N = (if argc >= 2 then int_of (argv.[1]) else N): int // typedef ideq = [n:nat] $DQ.deque (int, n) // val t = $DQ.fundeque_nil () val t1 = loop (0, t) where { fun loop ( n: int, res: ideq ) : ideq = if n < N then loop (n+1, n <| res) else res // end of [loop] } // end of [val] val t = $DQ.fundeque_nil () val t2 = loop (0, t) where { fun loop ( n: int, res: ideq ) : ideq = if n < N then loop (n+1, res |> n) else res // end of [loop] } // end of [val] val t12 = t1 >< t2 // val () = assertloc ($DQ.fundeque_size (t12) = N+N) // val () = loop (t12) where { fun loop (t: ideq): void = if $DQ.fundeque_is_nil (t) then () else let var x: int val t = $DQ.fundeque_uncons (t, x) val () = print (x) in loop (t) end // end of [if] } // end of [val] val () = print_newline () // val () = loop (t12) where { fun loop (t: ideq): void = if $DQ.fundeque_is_nil (t) then () else let var x: int val t = $DQ.fundeque_unsnoc (t, x) val () = print (x) in loop (t) end // end of [if] } // end of [val] val () = print_newline () // val () = $DQ.fundeque_foreach_cloref (t12, lam x => $effmask_all (print(x))) val () = print_newline () val () = $DQ.fundeque_rforeach_cloref (t12, lam x => $effmask_all (print(x))) val () = print_newline () // } // end of [main] (* ****** ****** *) (* end [libats_fundeque_fingertree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_float.dats0000664000175000017500000000204112223166161022112 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/float.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: August, 2010 // (* ****** ****** *) implement main () = let // val () = assert (float_of (123456789) = float_of "123456789") val () = assert (double_of (123456789) = double_of "123456789") // val () = assert (12345.0f * 6789 = float_of (12345 * 6789)) val () = assert (12345.0f * 6789 <= float_of (12345 * 6789)) val () = assert (12345.0f * 6789 >= float_of (12345 * 6789)) // val () = assert (12345.0 * 6789 = double_of (12345 * 6789)) val () = assert (12345.0 * 6789 <= double_of (12345 * 6789)) val () = assert (12345.0 * 6789 >= double_of (12345 * 6789)) // val x = 12345.6789 and y = 23456.7891 val () = assert (max (x, y) + min (x, y) = x + y) val () = assert (max (x, y) - min (x, y) = abs (x - y)) val () = assert (max (x, y) * min (x, y) = x * y) // in print "[prelude_float.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_float.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_parworkshop.dats0000664000175000017500000000513312223166161023207 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/parworkshop.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload UNISTD = "libc/SATS/unistd.sats" (* ****** ****** *) staload "libc/SATS/pthread.sats" staload "libats/SATS/parworkshop.sats" staload _(*anon*) = "libats/DATS/parworkshop.dats" (* ****** ****** *) #define QSZ 1 // extreme testing condition! (* ****** ****** *) dynload "libats/DATS/parworkshop.dats" (* ****** ****** *) implement main () = () where { typedef work = int val fwork = lam {l:addr} ( ws: !WORKSHOPptr (work, l), x: &work ) : int = $effmask_all let val tid = pthread_self () val tid = lint_of_pthread (tid) val () = (print "tid = "; print tid) val () = (print ": x = "; print x; print_newline ()) // val () = $UNISTD.usleep (1) in x + 1 end // end of [val] // val ws = workshop_make (QSZ, fwork) // val status = workshop_add_worker (ws) val () = (print "status = "; print status; print_newline ()) val nworker = workshop_get_nworker (ws) val () = (print "nworker = "; print nworker; print_newline ()) // val status = workshop_add_worker (ws) val () = (print "status = "; print status; print_newline ()) val nworker = workshop_get_nworker (ws) val () = (print "nworker = "; print nworker; print_newline ()) // val status = workshop_add_worker (ws) val () = (print "status = "; print status; print_newline ()) val nworker = workshop_get_nworker (ws) val () = (print "nworker = "; print nworker; print_newline ()) // var i: Nat = 0 val () = while (i < 10) let val () = workshop_insert_work (ws, i) in i := i + 1 end // end of [val] // val () = workshop_wait_blocked_all (ws) val nblocked = workshop_get_nblocked (ws) val () = (print "nblocked = "; print nblocked; print_newline ()) // val () = workshop_insert_work (ws, ~2) val () = workshop_insert_work (ws, ~2) val () = workshop_insert_work (ws, ~2) // val () = begin print "workshop_wait_paused_all(beg)"; print_newline () end // end of [val] val () = workshop_wait_paused_all (ws) val () = begin print "workshop_wait_paused_all(aft)"; print_newline () end // end of [val] // val npaused = workshop_get_npaused (ws) val () = (print "npaused = "; print npaused; print_newline ()) // val () = workshop_resume_paused_all (ws) // val () = workshop_insert_work (ws, ~1) val () = workshop_insert_work (ws, ~1) val () = workshop_insert_work (ws, ~1) // val () = workshop_free (ws) } // end of [main] (* ****** ****** *) (* end of [libats_parworkshop.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_ngc_dlist.dats0000664000175000017500000001040312223166161022572 0ustar hwxihwxi(* ** testing some functions declared in ** contrib/linux/utils/SATS/slist.sats ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2011 ** *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libats/ngc/SATS/dlist.sats" staload _(*anon*) = "libats/ngc/DATS/dlist.dats" (* ****** ****** *) %{^ typedef struct { char *name ; int age ; int sex ; void *prev ; void *next ; } person_struct ; ats_ptr_type person_alloc () { return ATS_MALLOC(sizeof(person_struct)) ; } // end of [person_alloc] ats_void_type person_free (ats_ptr_type p) { return ATS_FREE(p) ; } ats_ptr_type person_get_prev ( ats_ptr_type x ) { return ((person_struct*)x)->prev ; } // end of [person_get_prev] ats_void_type person_set_prev ( ats_ptr_type x, ats_ptr_type p ) { ((person_struct*)x)->prev = p ; return ; } // end of [person_set_prev] ats_ptr_type person_get_next ( ats_ptr_type x ) { return ((person_struct*)x)->next ; } // end of [person_get_next] ats_void_type person_set_next ( ats_ptr_type x, ats_ptr_type p ) { ((person_struct*)x)->next = p ; return ; } // end of [person_set_next] %} // end of [%{] (* ****** ****** *) viewtypedef person = $extype_struct "person_struct" of { name= strptr1, age= int, sex= int } // end of [person] viewtypedef personlst (nf:int, nr:int) = dlist (person, nf, nr) (* ****** ****** *) extern fun person_alloc : dlnode_alloc_type (person) = "person_alloc" implement dlnode_alloc () = person_alloc () (* ****** ****** *) extern fun person_free : dlnode_free_type (person) = "person_free" implement dlnode_free (pf | x) = person_free (pf | x) (* ****** ****** *) extern fun person_get_prev : dlnode_get_prev_type (person) = "person_get_prev" implement dlnode_get_prev (pf | x) = person_get_prev (pf | x) extern fun person_set_prev : dlnode_set_prev_type (person) = "person_set_prev" implement dlnode_set_prev (pf | x, p) = person_set_prev (pf | x, p) extern fun person_get_next : dlnode_get_next_type (person) = "person_get_next" implement dlnode_get_next (pf | x) = person_get_next (pf | x) extern fun person_set_next : dlnode_set_next_type (person) = "person_set_next" implement dlnode_set_next (pf | x, p) = person_set_next (pf | x, p) (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) fun personlst_randgen {n:nat} (n: int n): personlst (0, n) = let viewtypedef a = person in if n > 0 then let // val (pfopt | p) = person_alloc () val () = assertloc (p > null) prval Some_v (pfnod) = pfopt prval (pfat, fpfnod) = dlnode_v_takeout_val {a?} (pfnod) // val id = randint (10) val () = p->name := sprintf ("XYZ-%1d", @(id)) val () = p->age := randint (100) val () = p->sex := randint (2) // prval () = pfnod := fpfnod {a} (pfat) // val xs = personlst_randgen (n-1) in dlist_cons (pfnod | p, xs) end else dlist_nil () end // end of [personlst_randgen] (* ****** ****** *) implement main () = () where { // val () = srand48_with_time () // #define N 5 val xs = personlst_randgen (N) // val xs = loop (xs) where { fun loop {nf,nr:int | nr > 0} .. (xs: personlst (nf, nr)): personlst (nf+nr-1, 1) = let val () = dlist_appfst_fun (xs , lam (x) => $effmask_all ( printf ("%s(age=%i,sex=%i)\n", @($UN.castvwtp1 {string} (x.name), x.age, x.sex)) ) (* end of [lam] *) ) // end of [val] in if dlist_is_at_end (xs) then xs else loop (dlist_move_forward (xs)) end // end of [loop] } // end of [val] // val xs = loop (xs) where { fun loop {nf,nr:int | nr > 0} (xs: personlst (nf, nr)) : personlst (0, nf+nr) = let val () = dlist_appfst_fun (xs , lam (x) => $effmask_all ( printf ("%s(age=%i,sex=%i)\n", @($UN.castvwtp1 {string} (x.name), x.age, x.sex)) ) (* end of [lam] *) ) // end of [val] prval () = dlist_length_is_nonnegative (xs) in if dlist_is_at_beg (xs) then xs else loop (dlist_move_backward (xs)) end // end of [loop] } // end of [val] // val () = dlist_free_fun (xs, lam (x) => strptr_free (x.name)) // } // end of [main] (* ****** ****** *) (* end of [libats_ngc_dlist.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_array.dats0000664000175000017500000000553112223166161022132 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) // staload "prelude/SATS/array.sats" (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) implement main (argc, argv) = let val () = () where { #define asz 10 val A = array_make_arrpsz {int} ($arrpsz (0, 1, 2, 3, 4, 5, 6, 7, 8, 9)) // end of [val] // testing [array_iforeach_fun] val () = print "A (0-9) = " val () = array_iforeach_fun (A, f, asz) where { fn f ( i: sizeLt asz, x: &int ) :<> void = $effmask_all let val () = if i > 0 then print ", " in print x end // end of [f] } // end of [val] val () = print_newline () // testing [array_iforeach_vclo] prval pf = unit_v () val () = print "A (0-9) = " val () = array_iforeach_vclo {unit_v} (pf | A, !p_f, asz) where { var !p_f = @lam (pf: !unit_v | i: sizeLt asz, x: &int): void = $effmask_all ( let val () = if i > 0 then print ", " in print x end ) // end of [$effmask_all] } // end of [val] val () = print_newline () prval unit_v () = pf } // end of [val] // val () = () where { // // HX: testing array_v_group and array_v_ungroup // typedef T = int #define M 2; #define N 5; #define MN %(M*N) prval pfmn = mul_make {M,N} () var !parr with pfarr = @[T][MN](0) prval pfarr2 = array_v_group {T} (pfmn, pfarr) // val [l0:addr] (pf, fpf | p0) = array2_ptr_takeout (pfarr2 | parr, 0, N) prval pfout = $UN.vtakeout {array_v (T, N, l0)} (pf) prval (pf0, fpf0) = $UN.viewout_decode (pfout) prval () = pfarr2 := fpf (pf) val [l1:addr] (pf, fpf | p1) = array2_ptr_takeout (pfarr2 | parr, 1, N) prval pfout = $UN.vtakeout {array_v (T, N, l1)} (pf) prval (pf1, fpf1) = $UN.viewout_decode (pfout) prval () = pfarr2 := fpf (pf) // val () = array_ptr_iforeach_fun (!p0, f, N) where { val f = lam (i: sizeLt N, x: &T): void = x := int1_of_size1 (i) } // end of [val] prval () = fpf0 (pf0) val () = array_ptr_iforeach_fun (!p1, f, N) where { val f = lam (i: sizeLt N, x: &T): void = x := int1_of_size1 (i+N) } // end of [val] prval () = fpf1 (pf1) // prval () = pfarr := array_v_ungroup {T} (pfmn, pfarr2) // val () = array_ptr_iforeach_fun (!parr, f, MN) where { val f = lam (i: sizeLt MN, x: &T): void = $effmask_all (if i > 0 then print ","; print x) } // end of [val] val () = print_newline () } // end of [val] // in print "The run of [prelude_array.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_array.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funmap_rbtree.dats0000664000175000017500000000573212223166161023466 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/funmap_rbtree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload M = "libats/SATS/funmap_rbtree.sats" staload _(*anon*) = "libats/DATS/funmap_rbtree.dats" (* ****** ****** *) implement $M.compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = string fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var map: $M.map (key, itm) = $M.funmap_make_nil () var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val itm = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) val _(*exists*) = $M.funmap_insert (map, key, itm, cmp) in // nothing end // end [for] // val size = $M.funmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = $M.funmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if n < 100 then let prval pf = unit_v (); val () = $M.funmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // var res: itm? // uninitialized // fn find ( map: $M.map (key, itm), k: int, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = $M.funmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i val _(*removed*) = $M.funmap_remove (map, key, cmp) in // nothing end // end [for] // val size = $M.funmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_funmap_rbtree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funmap_avltree.dats0000664000175000017500000000573612223166161023651 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/funmap_avltree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload M = "libats/SATS/funmap_avltree.sats" staload _(*anon*) = "libats/DATS/funmap_avltree.dats" (* ****** ****** *) implement $M.compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = string fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var map: $M.map (key, itm) = $M.funmap_make_nil () var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val itm = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) val _(*exists*) = $M.funmap_insert (map, key, itm, cmp) in // nothing end // end [for] // val size = $M.funmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = $M.funmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if n < 100 then let prval pf = unit_v (); val () = $M.funmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // var res: itm? // uninitialized // fn find ( map: $M.map (key, itm), k: int, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = $M.funmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i val _(*removed*) = $M.funmap_remove (map, key, cmp) in // nothing end // end [for] // val size = $M.funmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_funmap_avltree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_list.dats0000664000175000017500000000514112223166161023143 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" // end of [staload] (* ****** ****** *) staload "libats/smlbas/SATS/char.sats" staload "libats/smlbas/SATS/list.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/list0.dats" staload _(*anonymous*) = "libats/smlbas/DATS/list.dats" (* ****** ****** *) dynload "libats/smlbas/DATS/char.dats" dynload "libats/smlbas/DATS/list.dats" (* ****** ****** *) implement main () = () where { val abs = list_of_list_vt (string_explode "abcdefghijklmnopqrstuvwxyz") // end of [val] val abs = list0_of_list (abs) // val () = assertloc ('a' = nth (abs, 0)) val () = assertloc ('a' = (try nth (abs, 26) with ~Subscript() => 'a')) // val () = app (lam (c) => print c, abs) val () = print_newline () // val _(*int*) = foldl (lam (c, i) => (if i > 0 then print ", "; print c; i + 1), 0, abs) val () = print_newline () // val _(*int*) = foldr (lam (c, i) => (if i > 0 then print ", "; print c; i + 1), 0, abs) val () = print_newline () // val ABs = map (lam x => toUpper x, abs) val () = app (lam (c) => print c, ABs) val () = print_newline () // val () = app (lam (c) => print c, append (abs, ABs)) val () = print_newline () // val () = app (lam (c) => print c, rev (abs)) val () = print_newline () // val abs1 = tabulate (length abs, lam (i) => chr (ord 'a' + uint_of_int i)) // end of [val] val () = app (lam (c) => print c, abs1) val () = print_newline () // val () = app (lam (c) => print c, take (ABs, 13)) val () = print_newline () val () = app (lam (c) => print c, drop (ABs, 13)) val () = print_newline () // val () = assert (all (lam (x) => x \gte 'a', abs)) val () = assert (~exists (lam (x) => x \lt 'a', abs)) val () = assert (all (lam (x) => x \lte 'z', abs)) val () = assert (~exists (lam (x) => x \gt 'z', abs)) // macdef list0_sing (x) = list0_cons (,(x), list0_nil ()) val abss = map (lam x => list0_sing x, abs) val () = assert (collate (lam (x, y) => compare (x, y), abs, abs1) = 0) // end of [val] val () = assert (collate (lam (x, y) => compare (x, y), abs, concat abss) = 0) // end of [val] } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_list.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linordset_randbst.dats0000664000175000017500000000301412223166161024344 0ustar hwxihwxi(* // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2011 // *) (* ****** ****** *) staload LS = "libats/SATS/linordset_randbst.sats" staload _(*anon*) = "libats/DATS/linordset_randbst.dats" (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) implement $LS.compare_elt_elt (x1, x2, _(*cmp*)) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 implement main (argc, argv) = let var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = int1_of n; val n2 = n / 2 val () = assert (n > 0) val () = $RAND.srand48_with_time () fn cmp (x1: int, x2: int): Sgn = compare (x1, x2) // val rng = $LS.linordset_rngobj_make_drand48 () // var ints1: $LS.set (int) = $LS.linordset_make_nil () var i: int; val () = for (i := 0; i < n2; i := i+1) { val _ = $LS.linordset_insert (rng, ints1, $RAND.randint n, cmp) } (* end of [for] *) // end [val] // val size1 = $LS.linordset_size (ints1) val () = println! ("size1 = ", size1) val height1 = $LS.linordset_height (ints1) val () = println! ("height1 = ", height1) // var x0: int // val ans = $LS.linordset_ordrem (rng, ints1, 0, x0) val () = assertloc (ans) prval () = opt_unsome {int} (x0) val () = println! ("ordrem(ints1, 0) = ", x0) // val () = $LS.linordset_free (ints1) // val () = $LS.linordset_rngobj_free (rng) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_linordset_randbst.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_refcount.dats0000664000175000017500000000267512223166161022465 0ustar hwxihwxi(* // some testing code for [libats/refcount] // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2011 *) (* ****** ****** *) staload "libats/SATS/refcount.sats" staload _(*anon*) = "libats/DATS/refcount.dats" (* ****** ****** *) viewtypedef strnref = nref (strptr0) (* ****** ****** *) fun fprint_strnref ( out: FILEref, x: !strnref ) : void = let val (pf | p) = refcount_takeout (x) val () = fprint_strptr (out, !p) prval () = refcount_addback (pf | x) in // nothing end // end of [fprint_strnref] (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" implement main () = () where { // val msg = "Hello, world!\n" val nmsg = string1_length (msg) val str = string_make_substring (msg, 0, nmsg) val str = strptr_of_strbuf (str) // val r = refcount_make (str) val p = $UN.castvwtp1 {ptr} (r) val () = assert (1u = refcount_get_count r) // val () = fprint_strnref (stdout_ref, r) // val r1 = refcount_ref (r) val () = assert (2u = refcount_get_count (r)) // stadef T = strptr0 var x: T? // val ans = refcount_unref (r, x) val () = assert (ans = false) prval () = opt_unnone {T} (x) val () = assert (1u = refcount_get_count (r1)) // val () = fprint_strnref (stdout_ref, r1) // val ans = refcount_unref (r1, x) val () = assert (ans = true) prval () = opt_unsome {T} (x) // val () = strptr_free (x) // } // end of [main] (* ****** ****** *) (* end of [libats_refcount.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_sys_utsname.dats0000664000175000017500000000265612223166161022644 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/stdlib.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) staload "libc/sys/SATS/utsname.sats" (* ****** ****** *) implement main () = () where { // var name: utsname? val err = uname (name) val () = if err = 0 then let prval () = opt_unsome {utsname} (name) // val (fpf_x | x) = utsname_get_sysname (name) val () = (print "name.sysname = "; print x; print_newline ()) prval () = fpf_x (x) val (fpf_x | x) = utsname_get_nodename (name) val () = (print "name.nodename = "; print x; print_newline ()) prval () = fpf_x (x) val (fpf_x | x) = utsname_get_release (name) val () = (print "name.release = "; print x; print_newline ()) prval () = fpf_x (x) val (fpf_x | x) = utsname_get_version (name) val () = (print "name.version = "; print x; print_newline ()) prval () = fpf_x (x) val (fpf_x | x) = utsname_get_machine (name) val () = (print "name.machine = "; print x; print_newline ()) prval () = fpf_x (x) (* val (fpf_x | x) = utsname_get_domainname (name) val () = (print "name.domainname = "; print x; print_newline ()) prval () = fpf_x (x) *) // in // nothing end else let prval () = opt_unnone {utsname} (name) in // nothing end // end of [val] // } // end of [main] (* ****** ****** *) (* end of [libc_sys_utsname.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funset_avltree.dats0000664000175000017500000000637012223166161023662 0ustar hwxihwxi(* // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2008 // *) (* ****** ****** *) staload FS = "libats/SATS/funset_avltree.sats" staload _(*anon*) = "libats/DATS/funset_avltree.dats" (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) (* ** the efficiency gained from inlining the comparison ** function seems to be less than 5%. *) implement $FS.compare_elt_elt (x1, x2, _(*cmp*)) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = int1_of n; val n2 = n / 2 val () = assert (n > 0) val () = $RAND.srand48_with_time () fn cmp (x1: int, x2: int): Sgn = compare (x1, x2) var ints1: $FS.set (int) = $FS.funset_make_nil () var i: int; val () = for (i := 0; i < n2; i := i+1) { val _ = $FS.funset_insert (ints1, $RAND.randint n, cmp) } // end [val] val size1 = $FS.funset_size (ints1) val () = begin print "size1 = "; print size1; print_newline () end val height1 = $FS.funset_height (ints1) val () = begin print "height1 = "; print height1; print_newline () end var ints2: $FS.set (int) = $FS.funset_make_nil () var i: int; val () = for (i := n2; i < n; i := i+1) { val _ = $FS.funset_insert (ints2, $RAND.randint n, cmp) } (* end of [for] *) // end [val] val size2 = $FS.funset_size (ints2) val () = println! ("size2 = ", size2) val height2 = $FS.funset_height (ints2) val () = println! ("height2 = ", height2) val ints_union = $FS.funset_union (ints1, ints2, cmp) val size = $FS.funset_size (ints_union) val () = println! ("size(ints_union) = ", size) val e_recip = 1.0 - (double_of size) / n val e = 1.0 / e_recip val () = println! ("the constant e = ", e) val ints_intersect = $FS.funset_intersect (ints1, ints2, cmp) val size = $FS.funset_size (ints_intersect) val () = println! ("size(ints_intersect) = ", size) val ints_diff12 = $FS.funset_diff (ints1, ints2, cmp) val size = $FS.funset_size (ints_diff12) val () = println! ("size(ints_diff12) = ", size) val ints_diff21 = $FS.funset_diff (ints2, ints1, cmp) val size = $FS.funset_size (ints_diff21) val () = println! ("size(ints_diff21) = ", size) val ints_symdiff = $FS.funset_symdiff (ints1, ints2, cmp) val size = $FS.funset_size (ints_symdiff) val () = println! ("size(ints_symdiff) = ", size) // val () = print "checking: ints_diff12 \\cup ints_diff12 = ints_symdiff:\n" val () = assert ( $FS.funset_is_equal ( $FS.funset_union (ints_diff12, ints_diff21, cmp) , ints_symdiff , cmp ) (* end of [funset_is_equal] *) ) (* end of [assert] *) val () = print "checking is done successfully.\n" // val () = print "checking: ints_union \\backslash ints_intersect = ints_symdiff:\n" val () = assert ( $FS.funset_is_equal ( $FS.funset_diff (ints_union, ints_intersect, cmp), ints_symdiff, cmp ) (* end of [funset_is_equal] *) ) (* end of [assert] *) val () = print "checking is done successfully.\n" // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_funset_avltree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linheap_binomial.dats0000664000175000017500000000345312223166161024125 0ustar hwxihwxi(* // some testing code for [libats/linheap_binomial] // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: November, 2011 *) (* ****** ****** *) // staload H = "libats/SATS/linheap_binomial.sats" staload _(*anon*) = "libats/DATS/linheap_binomial.dats" // (* ****** ****** *) typedef elt = int viewtypedef heap_t = $H.heap (elt) (* ****** ****** *) implement main (argc, argv) = () where { val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 100 // default val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [va] val [n:int] n = int1_of_int n val () = assert (n > 0) val cmp = lam (x1: &elt, x2: &elt): Sgn = compare_int_int (x1, x2) var heap: heap_t = $H.linheap_make_nil () var i: Nat // uninitialized val () = for (i := n; i > 0; i := i-1) let val elt = i val () = $H.linheap_insert (heap, elt, cmp) in // nothing end // end of [val] // val sz = $H.linheap_size (heap) val () = (print "linheap_size (heap) = "; print sz; print_newline ()) // val () = loop (sz, heap) where { val sz = size1_of_size (sz) fun loop {n:nat} .. ( sz: size_t n, heap: &heap_t ) : void = let var x: elt? // uninitialized in if sz > 0 then let val removed = $H.linheap_delmin (heap, cmp, x) val () = assert_errmsg (removed, #LOCATION) prval () = opt_unsome {elt} (x) // val () = (print x; print_newline ()) in loop (sz-1, heap) end // end of [if] end // end of [loop] } // end of [loop] // val sz = $H.linheap_size (heap) val () = (print "linheap_size (heap) = "; print sz; print_newline ()) // val () = $H.linheap_free (heap) // } // end of [main] (* ****** ****** *) (* end of [libats_linheap_binomial.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_array0.dats0000664000175000017500000000326112223166161022210 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/array0.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) // staload "prelude/SATS/array0.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/array0.dats" (* ****** ****** *) implement main () = let val () = () where { #define asz 10 // val A = array0_make_arrpsz {int} ( $arrpsz (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ) // end of [val] // var i: int // uninitialized val () = for (i := 0; i < asz; i := i + 1) let val () = if i > 0 then print ", " in print A[i] end // end of [val] val () = print_newline () } // end of [val] // val () = () where { #define asz 10 val A = array0_make_elt (asz, 0) var i: int // uninitialized val () = for (i := 0; i < asz; i := i + 1) let val () = if i > 0 then print ", " in print A[i] end // end of [val] val () = print_newline () // val () = for (i := 0; i < asz; i := i + 1) (A[i] := i) // val () = for (i := 0; i < asz; i := i + 1) let val () = if i > 0 then print ", " in print A[i] end // end of [val] val () = print_newline () } // end of [val] // val () = () where { #define asz 10 val A = array0_tabulate (asz, lam (i) => int_of_size i) val () = array0_iforeach (A, lam (i, x) => $effmask_all(print i; print "->"; print x; print_newline ()) ) // end of [val] } // end of [val] in print "The run of [prelude_array0.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_array0.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_list.dats0000664000175000017500000001174312223166161021771 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/list.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload Rand = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) #define MAXELT 100 (* fun random_list_gen {n:nat} (n: int n): list (natLt MAXELT, n) = loop (n, list_nil) where { typedef T = natLt MAXELT fun loop {i,j:nat} .. (i: int i, xs: list (T, j)): list (T, i+j) = if i = 0 then xs else loop (i-1, list_cons ($Rand.randint MAXELT, xs)) // end of [loop] } // end of [random] *) fun random_list_gen {n:nat} (n: int n): list (natLt MAXELT, n) = xs where { val xs = list_vt_tabulate_fun (lam _ = $Rand.randint MAXELT, n) val xs = list_of_list_vt (xs) } // end of [val] (* ****** ****** *) #define l2l list_of_list_vt implement main (argc, argv) = let // // for printing out an integer list // also for testing [list_iforeach] // fn lstpr (xs: List int): void = () where { val () = list_iforeach_fun (xs, f) where { fn f (i: int, x: int) : void = (if i > 0 then print (", "); print x) // end of [f] } // end of [val] } // end of [lstpr] fun lsteq (xs1: List int, xs2: List int): bool = case+ (xs1, xs2) of | (list_nil _, list_nil _) => true | (list_cons (x1, xs1), list_cons (x2, xs2)) when x1 = x2 => lsteq (xs1, xs2) | (_, _) => false // end of [lsteq] // val () = $Rand.srand48_with_time () // a new seed is generated // #define N 20 #define N2 10 #assert (N == 2 * N2) val xs = random_list_gen (N) // for testing [list_vt_tabulate] val () = () where { val () = print "xs (randomly generated) = " val () = lstpr (xs) val () = print_newline () } // end of [val] // val () = () where { val () = print "testing [list_take] and [list_drop]: starts\n" val xs1 = l2l (list_take (xs, N2)) val xs2 = list_drop (xs, N2) val xs12 = xs1 + xs2 // testing list_append val () = assert (lsteq (xs, xs12)) val () = print "testing [list_take] and [list_drop]: finishes\n" } // end of [val] // val () = () where { val () = print "testing [list_reverse]: starts\n" val () = assert (lsteq (xs, l2l (list_reverse (l2l (list_reverse xs))))) val () = print "testing [list_reverse]: finishes\n" } // end of [val] // val () = () where { val () = print "testing [list_nth]: starts\n" val x1 = list_nth (xs, N/3) val x2 = list_nth (l2l (list_reverse xs), N-N/3-1) val () = assert (x1 = x2) val () = print "testing [list_nth]: finishes\n" } // end of [val] // val () = () where { val () = print "filter (xs, evn) = " // for testing [list_filter] val xs = list_filter_fun (xs, lam x =<0> x mod 2 = 0) val xs = list_of_list_vt (xs) val () = lstpr (xs) val () = print_newline () } // end of [val] val () = () where { val () = print "filter (xs, odd) = " // for testing [list_filter] again val xs = list_filter_fun (xs, lam x =<0> x mod 2 > 0) val xs = list_of_list_vt (xs) val () = lstpr (xs) val () = print_newline () } // end of [val] // val () = () where { val () = print "list_app: " var i: int = 0 fn f (pf_i: !int @ i | x: int, p_i: !ptr i): void = () where { val () = if !p_i > 0 then print ", " val () = !p_i := !p_i + 1 val () = print x } // end of [f] val () = list_app_funenv {int @ i} {ptr i} (view@ i | xs, f, &i) val () = print_newline () } // end of [val] // val () = () where { val () = print "map (xs, double) = " // for testing [list_map] val () = lstpr (list_of_list_vt xs) where { val xs = list_map_fun (xs, lam x =<0> 2 * x) } val () = print_newline () } // end of [val] // val () = () where { val () = print "testing [list_head] and [list_last]: starts\n" val () = assert (list_head xs = list_last (l2l (list_reverse xs))) val () = assert (list_last xs = list_head (l2l (list_reverse xs))) val () = print "testing [list_head] and [list_last]: finishes\n" } // end of [val] // val () = () where { val () = print "testing [list_mergesort] and [list_quicksort]: starts\n" val xs_ms = list_mergesort {ptr} (xs, lam (x1, x2, env) =<0> compare (x1, x2), null) val xs_qs = list_quicksort {ptr} (xs, lam (x1, x2, env) =<0> compare (x1, x2), null) val () = lstpr ($UN.castvwtp1 {List(int)} (xs_ms)) val () = print_newline () val () = list_vt_free (xs_ms) val () = lstpr ($UN.castvwtp1 {List(int)} (xs_qs)) val () = print_newline () val () = list_vt_free (xs_qs) val () = print "testing [list_mergesort] and [list_quicksort]: finishes\n" } // end of [val] // in print "The run of [prelude_list.dats] is done successfully!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_list.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_hashtable_linprb.dats0000664000175000017500000001170412223166161024132 0ustar hwxihwxi(* // // Author: Hongwei Xi (March, 2010) // *) (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload H = "libats/SATS/hashtable_linprb.sats" staload _(*anon*) = "libats/DATS/hashtable_linprb.dats" stadef HASHTBLptr = $H.HASHTBLptr (* ****** ****** *) %{^ typedef ats_ptr_type absptr ; %} // end of [%{^] abstype absptr = $extype"absptr" extern castfn enstr (x: string):<> absptr extern castfn destr (x: absptr):<> string (* ****** ****** *) typedef keyitm = @(int,absptr) implement $H.keyitem_nullify (ki) = let val () = ki.1 := __cast (null) where { extern castfn __cast (x: ptr null):<> absptr } // end of [val] prval () = $H.Opt_none {keyitm} (ki) in // nothing end // end of [keyitem_nullify] implement $H.keyitem_isnot_null (ki) = let prval () = __assert (ki) where { extern prfun __assert (x: &($H.Opt keyitm) >> keyitm):<> void } // end of [prval] val i = ki.1 extern castfn __cast (x: absptr):<> ptr val i = __cast (i) val res = (i <> null) val [b:bool] res = bool1_of_bool (res) prval () = __assert (ki) where { extern prfun __assert (x: &keyitm >> opt (keyitm, b)):<> void } // end of [prval] in res end // end of [keyitem_isnot_null] (* ****** ****** *) // dynload "hashtable_linprb.dats" // not needed as [ATS_DYNLOADFLAG = 0] (* ****** ****** *) (* ** the efficiency gained from inlining the comparison ** function seems to be less than 5% (more like a 3%) *) // // Robert Jenkin's 32-bit function: // %{^ ats_int_type __jenkin32 (ats_int_type x) { uint32_t a = x ; a = (a+0x7ed55d16) + (a<<12); a = (a^0xc761c23c) ^ (a>>19); a = (a+0x165667b1) + (a<<5); a = (a+0xd3a2646c) ^ (a<<9); a = (a+0xfd7046c5) + (a<<3); a = (a^0xb55a4f09) ^ (a>>16); return a; } // end of [__jenkin] %} // end of [%{^] extern fun __jenkin32 (x: int):<> int = "__jenkin32" implement $H.hash_key (x, _) = let val h = __jenkin32 (x) in ulint_of_int (h) end // end of [hash_key] implement $H.equal_key_key (x1, x2, _) = (x1 = x2) (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = int1_of n val () = assert_errmsg (n > 0, #LOCATION) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = absptr // fn hash (x: key): ulint = ulint_of_int (x) fn eq (x1: key, x2: key): bool = (x1 = x2) // val [l:addr] ptbl = $H.hashtbl_make (hash, eq) var i: int; val () = for (i := 0; i < n; i := i+1) let (* val () = if (i mod 10000 = 0) then (print "i = "; print i; print_newline ()) *) val key = i // val key = $RAND.randint n val kstr : itm = enstr (tostring key) // = sprintf ("%i", @(key)) var res : itm // val () = printf ("key = %i and itm = %s\n", @(key, kstr)) val ans = $H.hashtbl_insert (ptbl, key, kstr, res) prval () = opt_clear (res) in // nothing end // end [for] val size = $H.hashtbl_size (ptbl) val total = $H.hashtbl_total (ptbl) val () = begin print "size = "; print size; print_newline (); print "total = "; print total; print_newline (); end // end of [val] // var res: itm? // fn find {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k0)) val ans = $H.hashtbl_search (ptbl, k0, res) val () = if ans then let prval () = opt_unsome {itm} (res) in print! ("Some(", destr res, ")") end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [if] val () = print_newline () } // end of [find] // val k0 = 0 val () = find (ptbl, k0, res) val k1 = 1 val () = find (ptbl, k1, res) val k10 = 10 val () = find (ptbl, k10, res) val k100 = 100 val () = find (ptbl, k100, res) val k1000 = 1000 val () = find (ptbl, k1000, res) val k10000 = 10000 val () = find (ptbl, k10000, res) // #define p2s string_of_strptr var !p_f = @lam ( pf: !unit_v | k: key, i: &itm ) : void = i := enstr (p2s (sprintf ("%i", @(k+k+1)))) // end of [var] prval pf = unit_v () val () = $H.hashtbl_foreach_vclo {unit_v} (pf | ptbl, !p_f) prval unit_v () = pf // val () = find (ptbl, k10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val ans = $H.hashtbl_remove (ptbl, key, res) prval () = opt_clear (res) in // nothing end // end [for] // val total = $H.hashtbl_total (ptbl) val () = (print "total(aft) = "; print total; print_newline ()) val notfreed = $H.hashtbl_free_vt (ptbl) val () = assert_errmsg (notfreed = false, #LOCATION) prval () = opt_unnone (ptbl) in // empty end // end of [main] (* ****** ****** *) (* end of [libats_hashtable_linprb.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linset_listord.dats0000664000175000017500000000356612223166161023676 0ustar hwxihwxi(* // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2011 // *) (* ****** ****** *) staload LS = "libats/SATS/linset_listord.sats" staload _(*anon*) = "libats/DATS/linset_listord.dats" (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) (* ** the efficiency gained from inlining the comparison ** function seems to be less than 5%. *) implement $LS.compare_elt_elt (x1, x2, _(*cmp*)) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = int1_of n; val n2 = n / 2 val () = assert (n > 0) val () = $RAND.srand48_with_time () fn cmp (x1: int, x2: int): Sgn = compare (x1, x2) var ints1: $LS.set (int) = $LS.linset_make_nil () var i: int; val () = for (i := 0; i < n2; i := i+1) { val _ = $LS.linset_insert (ints1, $RAND.randint n, cmp) } (* end of [for] *) // end [val] val size1 = $LS.linset_size (ints1) val () = println! ("size1 = ", size1) var ints2: $LS.set (int) = $LS.linset_make_nil () var i: int; val () = for (i := n2; i < n; i := i+1) { val _ = $LS.linset_insert (ints2, $RAND.randint n, cmp) } (* end of [for] *) // end [val] val size2 = $LS.linset_size (ints2) val () = println! ("size2 = ", size2) val ints_union = $LS.linset_union (ints1, ints2, cmp) val size = $LS.linset_size (ints_union) val () = println! ("size(ints_union) = ", size) val e_recip = 1.0 - (double_of size) / n val e = 1.0 / e_recip; val () = begin print "the constant e = "; print e; print_newline () end // end of [val] val () = $LS.linset_free (ints_union) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_linset_listord.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linmap_avltree.dats0000664000175000017500000000623612223166161023637 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/linmap_avltree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload M = "libats/SATS/linmap_avltree.sats" staload _(*anon*) = "libats/DATS/linmap_avltree.dats" stadef map_vt = $M.map (* ****** ****** *) implement $M.compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int and itm = string fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var res: itm? // uninitialized // var map: map_vt (key, itm) = $M.linmap_make_nil () var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i // val key = $RAND.randint n val itm = tostring key // val itm = sprintf ("%i", @(key)) // val () = printf ("key = %i and itm = %s\n", @(key, itm)) val _(*inserted*) = $M.linmap_insert (map, key, itm, cmp, res) prval () = opt_clear (res) in // nothing end // end [for] // val size = $M.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = $M.linmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if n < 100 then let prval pf = unit_v (); val () = $M.linmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: &itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // fn find ( map: &map_vt (key, itm), k: int, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = $M.linmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print res; print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // var i: int; val () = for (i := 0; i < n; i := i+1) let val key = i val _(*removed*) = $M.linmap_remove (map, key, cmp) in // nothing end // end [for] // val size = $M.linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val notfreed = $M.linmap_free_vt (map) val () = assert_errmsg (notfreed = false, #LOCATION) prval () = opt_unnone (map) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_char.dats0000664000175000017500000000740112223166161023106 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/smlbas/SATS/char.sats" (* ****** ****** *) (* fun ord (c: char): uint fun chr (i: uint): char fun succ (c: char): char fun pred (c: char): char *) fn test__ord (): void = () where { val () = assert_errmsg (ord '0' = 0x30U, #LOCATION) val () = assert_errmsg (ord 'a' = uint_of_char 'a', #LOCATION) val () = assert_errmsg (ord 'A' = uint_of_char 'A', #LOCATION) } // end of [test__ord] fn test__chr (): void = () where { val () = assert_errmsg (chr 0x30U = '0', #LOCATION) val () = assert_errmsg (chr (uint_of_char 'a') = 'a', #LOCATION) val () = assert_errmsg (chr (uint_of_char 'A') = 'A', #LOCATION) } // end of [test__chr] fn test__succ (): void = () where { val () = assert_errmsg (succ '0' = '1', #LOCATION) val () = assert_errmsg (succ 'a' = 'b', #LOCATION) val () = assert_errmsg (succ 'A' = 'B', #LOCATION) } // end of [test__succ] fn test__pred (): void = () where { val () = assert_errmsg (pred '1' = '0', #LOCATION) val () = assert_errmsg (pred 'b' = 'a', #LOCATION) val () = assert_errmsg (pred 'B' = 'A', #LOCATION) } // end of [test__pred] (* ****** ****** *) (* fun contains (s: string, c: char): bool fun notContains (s: string, c: char): bool *) fn test__contains (): void = () where { val () = assert_errmsg (contains ("abcdefghijklmnopqrstuvwxyz", 'a'), #LOCATION) val () = assert_errmsg (contains ("abcdefghijklmnopqrstuvwxyz", 'm'), #LOCATION) val () = assert_errmsg (contains ("abcdefghijklmnopqrstuvwxyz", 'n'), #LOCATION) val () = assert_errmsg (contains ("abcdefghijklmnopqrstuvwxyz", 'z'), #LOCATION) } // end of [test__contains] fn test__notContains (): void = () where { val () = assert_errmsg (notContains ("abcdefghijklmnopqrstuvwxyz", 'A'), #LOCATION) val () = assert_errmsg (notContains ("abcdefghijklmnopqrstuvwxyz", 'M'), #LOCATION) val () = assert_errmsg (notContains ("abcdefghijklmnopqrstuvwxyz", 'N'), #LOCATION) val () = assert_errmsg (notContains ("abcdefghijklmnopqrstuvwxyz", 'Z'), #LOCATION) } // end of [test__notContains] (* ****** ****** *) fn test__toLower (): void = () where { val () = assert_errmsg (toLower '0' = '0', #LOCATION) val () = assert_errmsg (toLower 'A' = 'a', #LOCATION) } // end of [test__toLower] fn test__toUpper (): void = () where { val () = assert_errmsg (toUpper '0' = '0', #LOCATION) val () = assert_errmsg (toUpper 'a' = 'A', #LOCATION) } // end of [test__toUpper] (* ****** ****** *) fn test__toCString (): void = () where { val () = assert_errmsg (toCString '\n' = "\\n", #LOCATION) val () = assert_errmsg (toCString '\101' = "A", #LOCATION) val () = assert_errmsg (toCString '\177' = "\\177", #LOCATION) } // end of [test__toCString] (* ****** ****** *) (* fun fromCString (s: string): option0 char *) fn test__fromCString () = () where { (* val oc = fromCString "A" val- option0_some c = oc val () = assert_errmsg (c = 'A', #LOCATION) val oc = fromCString "\\n" val- option0_some c = oc val () = assert_errmsg (c = '\n', #LOCATION) val oc = fromCString "AB" val- option0_none () = oc *) } // end of [test__fromCString] (* ****** ****** *) dynload "libats/smlbas/DATS/char.dats" (* ****** ****** *) implement main () = () where { val () = test__ord () val () = test__chr () val () = test__succ () val () = test__pred () // val () = test__contains () val () = test__notContains () // val () = test__toLower () val () = test__toUpper () // val () = test__toCString () val () = test__fromCString () // val () = print "[libats_smlbas_char.dats] testing passes!\n" } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_array.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_intinf.dats0000664000175000017500000000220612223166161022115 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/intinf.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) staload "libats/SATS/intinf.sats" (* ****** ****** *) fun fact (x: int): Intinf = loop (x, res) where { val x = int1_of_int x val res = intinf_make (1) fun loop {i:int} ( x: int i, res: Intinf ) : Intinf = if x > 0 then let val (pf_mul | res1) = res * x val () = intinf_free (res) in loop (x - 1, res1) end else res // end of [if] // end of [loop] } // end of [fact] fn prerr_usage (cmd: string): void = prerrf ("Usage: %s \n", @(cmd)) // end of [prerr_usage] (* ****** ****** *) dynload "libats/DATS/intinf.dats" implement main (argc, argv) = let val () = if (argc <> 2) then prerr_usage (argv.[0]) val () = assert (argc = 2) val n = int1_of_string (argv.[1]) val res = fact (n) val () = begin printf ("fact (%i) = ", @(n)); print (res); print_newline () end // end of [val] val () = intinf_free (res) in // empty end // end of [main] (* ****** ****** *) (* end of [libats_intinf.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_time.dats0000664000175000017500000000307312223166161021222 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/time.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) staload "libc/SATS/time.sats" (* ****** ****** *) implement main () = () where { // var time: time_t val yn = time_get_and_set (time) val () = assertloc (yn) prval () = opt_unsome{time_t} (time) // val (fpf_p | p) = ctime (time) val () = assertloc (strptr_isnot_null p) val str = strptr_dup (p) prval () = fpf_p (p) val () = (print "ctime = "; print str) // var tm: tm_struct val fmt = "%a %b %d %T %Y" val perr = strptime (__cast str, fmt, tm) where { extern castfn __cast {l:agz} (x: !strptr l): string } // end of [val] val () = assertloc (perr > null) prval () = opt_unsome {tm_struct} (tm) val time2 = mktime (tm) // val diff = difftime (time, time2) val () = println! ("diff = ", diff) (* val () = assertloc ((lint_of)diff = 0L) // HX: why is it 3600? *) val () = strptr_free (str) // val (pfopt | p_tm) = localtime (time) val () = assert_errmsg (p_tm > null, #LOCATION) prval Some_v @(pf, fpf) = pfopt val (fpf_p | p) = asctime (!p_tm) prval () = fpf (pf) val () = (print "asctime(LOC) = "; print p) prval () = fpf_p (p) // val (pfopt | p_tm) = gmtime (time) val () = assert_errmsg (p_tm > null, #LOCATION) prval Some_v @(pf, fpf) = pfopt val (fpf_p | p) = asctime (!p_tm) prval () = fpf (pf) val () = (print "asctime(GMT) = "; print p) prval () = fpf_p (p) // } // end of [main] (* ****** ****** *) (* end of [libc_time.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_stdio.dats0000664000175000017500000000200512223166161021400 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/stdio.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) #define c2i int_of_char #define i2c char_of_int #define _1M 1000000 implement main (argc, argv) = let // val _err = setvbuf_null (stdout_ref, _IOLBF) // end of [val] // var i: int val () = for (i := 0; i < 26; i := i+1) let val c = i2c(c2i('A')+i); val () = print c val _err = usleep (_1M / 26) in // nothing end // end of [val] val () = print_newline () // val () = setbuf_null (stdout_ref) // val () = for (i := 0; i < 26; i := i+1) let val c = i2c(c2i('A')+i); val () = print c val _err = usleep (_1M / 26) in // nothing end // end of [val] val () = print_newline () // in // empty end // end of [main] (* ****** ****** *) (* end of [libc_stdio.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_math.dats0000664000175000017500000000200012223166161021202 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/math.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2009 // (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) local #include "libc/HATS/math.hats" in (*empty*) end (* ****** ****** *) implement main (argc, argv) = let // val DEG = M_PI / 180.0 // val sin30 = sintmp (30 * DEG) val () = println! ("sin(30) = ", sin30) val cos30 = costmp (30 * DEG) val () = println! ("cos(30) = ", cos30) val tan30 = tantmp (30 * DEG) val () = println! ("tan(30) = ", tan30) // val sin60 = sintmp (60 * DEG) val () = println! ("sin(60) = ", sin60) val cos60 = costmp (60 * DEG) val () = println! ("cos(60) = ", cos60) val tan60 = tantmp (60 * DEG) val () = println! ("tan(60) = ", tan60) val () = println! ("tan(30) * tan(60) = ", tan30 * tan60) // val inf = INFINITY val () = println! ("inf = ", inf) // in // empty end // end of [main] (* ****** ****** *) (* end of [libc_math.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_gdbm_gdbm.dats0000664000175000017500000000274412223166161022172 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/printf.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/fcntl.sats" staload "libc/sys/SATS/stat.sats" staload "libc/sys/SATS/types.sats" staload "libc/gdbm/SATS/gdbm.sats" (* ****** ****** *) implement main () = () where { // val mode = lor_mode_mode (S_IRUSR, S_IWUSR) val [lf:addr] dbf = gdbm_open ("gdbmtest.gdbm", 512(*blksz*), GDBM_NEWDB, mode, null) (* val () = printf ("errstr = %s\n", @(gdbm_strerror (gdbm_errno_get ()))) *) val () = assertloc (ptr_of (dbf) > null) val (fpf_k | k) = datum_make0_string ("a") val v = datum_make1_string ("A") val _err = gdbm_store (dbf, k, v, GDBM_INSERT) val () = datum_free (v) val isexi = gdbm_exists (dbf, k) val () = assertloc (isexi > 0) val v = gdbm_fetch (dbf, k) // val () = println! ("k(a) = ", $UN.cast {string} (ptr_of(k.dptr))) val () = println! ("v(A) = ", $UN.cast {string} (ptr_of(v.dptr))) // val () = datum_free (v) val err = gdbm_delete (dbf, k) val () = assertloc (err = 0) val isexi = gdbm_exists (dbf, k) val () = assertloc (isexi = 0) prval () = fpf_k (k.dptr) prval () = cleanup_top {datum(null,0)} (k) (* prval () = fpf_k (datum_takeout_ptr (k)) // HX: an alternative to do it *) // val () = gdbm_close (dbf) // } // end of [main] (* ****** ****** *) (* end of [libc_gdbm_gdbm.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_array2.dats0000664000175000017500000000361712223166161023376 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/smlbas/SATS/array2.sats" staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list0.dats" staload _(*anonymous*) = "libats/smlbas/DATS/array2.dats" (* ****** ****** *) dynload "libats/smlbas/DATS/array2.dats" (* ****** ****** *) #define :: list0_cons #define cons list0_cons #define nil list0_nil (* ****** ****** *) implement main () = () where { // // Let the test begin! // // val M = fromList xss where { val xs1 = 0 :: 1 :: 2 :: nil () val xs2 = 3 :: 4 :: 5 :: nil () val xs3 = 6 :: 7 :: 8 :: nil () val xss = xs1 :: xs2 :: xs3 :: nil () } // end of [val] val () = app (RowMajor, lam x => print x, M) val () = print_newline () val () = app (ColMajor, lam x => print x, M) val () = print_newline () // val () = modify (RowMajor, lam x => x + 1, M) val () = app (RowMajor, lam x => print x, M) val () = print_newline () val () = app (ColMajor, lam x => print x, M) val () = print_newline () // val M_r = tabulate (RowMajor, 3, 3, f) where { val f = lam (i: size_t, j: size_t): int = let val i = int_of_size i and j = int_of_size j val () = printf ("i = %i and j = %i\n", @(i, j)) in i + j end // end of [val] } (* end of [val] *) // val M_c = tabulate (ColMajor, 3, 3, f) where { val f = lam (i: size_t, j: size_t): int = let val i = int_of_size i and j = int_of_size j val () = printf ("i = %i and j = %i\n", @(i, j)) in i + j end // end of [val] } (* end of [val] *) // } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_array.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linstack_arr.dats0000664000175000017500000000332712223166161023307 0ustar hwxihwxi(* // // Author: Hongwei Xi (March, 2010) // *) (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload S = "libats/SATS/linstack_arr.sats" stadef STACK = $S.STACK stadef STACK0 = $S.STACK0 (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "prelude/DATS/reference.dats" staload _(*anon*) = "libats/DATS/linstack_arr.dats" staload _(*anon*) = "libats/ngc/DATS/deque_arr.dats" (* ****** ****** *) // dynload "libats/DATS/linstack_arr.dats" // not needed as [ATS_DYNLOADFLAG = 0] (* ****** ****** *) #define N 2000000 (* ****** ****** *) implement main () = let // typedef itm = int var S: STACK0 (itm) val () = $S.stack_initialize (S, N) // val cap = $S.stack_cap (S) val () = assert_errmsg (cap = N, #LOCATION) val size = $S.stack_size (S) val () = assert_errmsg (size = 0, #LOCATION) // val () = loop (S, N, 0) where { fun loop {i,j:nat | i+j <= N} .. (S: &STACK (itm, N, j) >> STACK (itm, N, i+j), i: int i, j: int j): void = if i > 0 then let val () = $S.stack_insert (S, j) in loop (S, i-1, j+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (S, 0) where { fun loop {i:nat | i <= N} .. (S: &STACK (itm, N, N-i) >> STACK (itm, N, 0), i: int i): void = if i < N then let val x = $S.stack_remove (S) val () = assert_errmsg (x = N-1-i, #LOCATION) in loop (S, i+1) end // end of [val] // end of [loop] } // end of [val] // val () = $S.stack_uninitialize_vt {itm} (S) // in print "[libats_linstack_arr.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [libats_linstack_arr.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_linqueue_lst.dats0000664000175000017500000000443512223166161023345 0ustar hwxihwxi(* // // Author: Hongwei Xi (March, 2010) // *) (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/pointer.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload Q = "libats/SATS/linqueue_lst.sats" stadef QUEUE = $Q.QUEUE stadef QUEUE0 = $Q.QUEUE0 staload _(*anon*) = "libats/DATS/linqueue_lst.dats" (* ****** ****** *) // dynload "libats/DATS/linqueue_lst.dats" // not needed as [ATS_DYNLOADFLAG = 0] (* ****** ****** *) #define CAP 2000000 #define N1 1500000; #define N2 1000000 (* ****** ****** *) implement main () = () where { typedef itm = int var q: QUEUE0 (itm) val () = $Q.queue_initialize {itm} (q) // val () = loop (q, N1, 0) where { fun loop {i,j:nat | i+j <= CAP} .. (q: &QUEUE (itm, j) >> QUEUE (itm, i+j), i: int i, j: int j): void = if i > 0 then let val () = $Q.queue_insert (q, j) in loop (q, i-1, j+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (q, 0) where { fun loop {i:nat | i <= N2} .. (q: &QUEUE (itm, N1-i) >> QUEUE (itm, N1-N2), i: int i): void = if i < N2 then let val x = $Q.queue_remove (q) val () = assert_errmsg (x = i, #LOCATION) in loop (q, i+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (q, N2, N1) where { fun loop {i,j:nat | i <= N2} .. (q: &QUEUE (itm, N1-i) >> QUEUE (itm, N1), i: int i, j: int j): void = if i > 0 then let val () = $Q.queue_insert (q, j) in loop (q, i-1, j+1) end // end of [val] // end of [loop] } // end of [val] // val () = loop (q, 0) where { fun loop {i:nat | i <= N1} .. (q: &QUEUE (itm, N1-i) >> QUEUE (itm, 0), i: int i): void = if i < N1 then let val x = $Q.queue_remove (q) val () = assert_errmsg (x = N2+i, #LOCATION) in loop (q, i+1) end // end of [val] // end of [loop] } // end of [val] // val xs = $Q.queue_uninitialize (q) val () = list_vt_free (xs) // val () = print "[libats_linqueue_lst.dats] testing passes!\n" // } // end of [main] (* ****** ****** *) (* end of [libats_linqueue_lst.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_time.dats0000664000175000017500000000112012223166161023117 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "libats/smlbas/SATS/time.sats" (* ****** ****** *) dynload "libats/smlbas/DATS/real.dats" dynload "libats/smlbas/DATS/time.dats" (* ****** ****** *) implement main () = () where { val t0 = now () val () = begin print "current time = "; fprint (stdout_ref, t0); print_newline () end // end of [val] } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_time.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funset_listord.dats0000664000175000017500000000610712223166161023676 0ustar hwxihwxi(* // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2011 // *) (* ****** ****** *) staload FS = "libats/SATS/funset_listord.sats" staload _(*anon*) = "libats/DATS/funset_listord.dats" (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) (* ** the efficiency gained from inlining the comparison ** function seems to be less than 5%. *) implement $FS.compare_elt_elt (x1, x2, _(*cmp*)) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [val] val [n:int] n = int1_of n; val n2 = n / 2 val () = assert (n > 0) val () = $RAND.srand48_with_time () fn cmp (x1: int, x2: int): Sgn = compare (x1, x2) var ints1: $FS.set (int) = $FS.funset_make_nil () var i: int; val () = for (i := 0; i < n2; i := i+1) { val _ = $FS.funset_insert (ints1, $RAND.randint n, cmp) } (* end of [for] *) // end [val] val size1 = $FS.funset_size (ints1) val () = println! ("size1 = ", size1) var ints2: $FS.set (int) = $FS.funset_make_nil () var i: int; val () = for (i := n2; i < n; i := i+1) { val _ = $FS.funset_insert (ints2, $RAND.randint n, cmp) } (* end of [for] *) // end [val] val size2 = $FS.funset_size (ints2) val () = println! ("size2 = ", size2) val ints_union = $FS.funset_union (ints1, ints2, cmp) val size = $FS.funset_size (ints_union) val () = println! ("size(ints_union) = ", size) val e_recip = 1.0 - (double_of size) / n val e = 1.0 / e_recip; val () = begin print "the constant e = "; print e; print_newline () end // end of [val] val ints_intersect = $FS.funset_intersect (ints1, ints2, cmp) val size = $FS.funset_size (ints_intersect) val () = println! ("size(ints_intersect) = ", size) val ints_diff12 = $FS.funset_diff (ints1, ints2, cmp) val size = $FS.funset_size (ints_diff12) val () = println! ("size(ints_diff12) = ", size) val ints_diff21 = $FS.funset_diff (ints2, ints1, cmp) val size = $FS.funset_size (ints_diff21) val () = println! ("size(ints_diff21) = ", size) val ints_symdiff = $FS.funset_symdiff (ints1, ints2, cmp) val size = $FS.funset_size (ints_symdiff) val () = println! ("size(ints_symdiff) = ", size) // val () = print "checking: ints_diff12 \\cup ints_diff12 = ints_symdiff:\n" val () = assert ( $FS.funset_is_equal ( $FS.funset_union (ints_diff12, ints_diff21, cmp) , ints_symdiff , cmp ) (* end of [funset_is_equal] *) ) (* end of [assert] *) val () = print "checking is done successfully.\n" // val () = print "checking: ints_union \\backslash ints_intersect = ints_symdiff:\n" val () = assert ( $FS.funset_is_equal ( $FS.funset_diff (ints_union, ints_intersect, cmp), ints_symdiff, cmp ) (* end of [funset_is_equal] *) ) (* end of [assert] *) val () = print "checking is done successfully.\n" // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_funset_listord.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_sched.dats0000664000175000017500000000211212223166161021343 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/sched.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) staload "libc/SATS/sched.sats" staload TYPES = "libc/sys/SATS/types.sats" macdef pid_t = $TYPES.pid_of_int extern fun ncore_get (): int implement ncore_get () = let var cs: cpu_set0_t // uninitialized prval () = cpusetinit (cs) // not a real initialization stavar nset: int val nset = cpusetsize_get (cs) val () = (print "nset = "; print nset; print_newline ()) val err = sched_getaffinity ((pid_t)0, nset, cs) val () = assert_errmsg (nset >= 2, #LOCATION) var count: Nat = 0 var i: Nat // uninitialized val () = for* (cs: cpu_set_t nset) => (i := 0; i < 16; i := i + 1) if (CPU_ISSET (i, cs) > 0) then (count := count + 1) // end of [val] in count end // end of [ncore_get] (* ****** ****** *) implement main () = () where { val ncore = ncore_get () val () = (print "ncore = "; print ncore; print_newline ()) } // end of [main] (* ****** ****** *) (* end of [libc_sched.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_smlbas_string.dats0000664000175000017500000000453112223166161023500 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/smlbas/SATS/array.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload Char = "libats/smlbas/SATS/char.sats" staload List = "libats/smlbas/SATS/list.sats" (* ****** ****** *) staload "libats/smlbas/SATS/string.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/list0.dats" staload _(*anonymous*) = "libats/smlbas/DATS/list.dats" (* ****** ****** *) dynload "libats/smlbas/DATS/char.dats" dynload "libats/smlbas/DATS/list.dats" dynload "libats/smlbas/DATS/string.dats" (* ****** ****** *) implement main () = () where { val abs = "abcdefghijklmnopqrstuvwxyz" // val () = assert (isPrefix ("", "abcde")) val () = assert (isPrefix ("abcde", "abcde")) val () = assert (~isPrefix ("abcdef", "abcde")) val () = assert (~isPrefix ("abcdeg", "abcdefg")) val () = assert (isSubstring ("", "abcde")) val () = assert (isSubstring ("abcde", "abcde")) val () = assert (isSubstring ("bcd", "abcde")) val () = assert (~isSubstring ("bcdefgh", "abcdefg")) val () = assert (isSuffix ("", "abcde")) val () = assert (isSuffix ("abcde", "abcde")) val () = assert (isSuffix ("cde", "abcde")) val () = assert (~isSuffix ("def", "abcde")) // val ABs = map (lam c => $Char.toUpper c, abs) val () = print (ABs) val () = print_newline () val abs = map (lam c => $Char.toLower c, ABs) val () = print (abs) val () = print_newline () // val ABs = translate (lam c => str ($Char.succ c), ABs) val () = print (ABs) val () = print_newline () // val words = tokens (lam (c) => c = '|', "|abc||efgh||ijk|") val () = assert (list0_length words = 3) val () = $List.app (lam s => (print "tokens="; print s; print_newline ()), words) val words = fields (lam (c) => c = '|', "|abc||efgh||ijk|") val () = assert (list0_length words = 7) val () = $List.app (lam s => (print "field="; print s; print_newline ()), words) // val abs = explode abs val abss = $List.map (lam c => str c, abs) val abs_sep = concatWith (sep, abss) where { val sep = ", " } val () = print (abs_sep) val () = print_newline () // } // end of [main] (* ****** ****** *) (* end of [libats_smlbas_string.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_gdbm_ndbm.dats0000664000175000017500000000227012223166161022173 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/printf.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/fcntl.sats" staload "libc/sys/SATS/stat.sats" staload "libc/sys/SATS/types.sats" staload "libc/gdbm/SATS/ndbm.sats" (* ****** ****** *) implement main () = () where { // val flag = O_RDWR lor O_CREAT val mode = lor_mode_mode (S_IRUSR, S_IWUSR) val [lf:addr] dbf = dbm_open ("ndbmtest", flag, mode) val () = assertloc (ptr_of (dbf) > null) val (fpf_k | k) = datum_make0_string ("a") val v = datum_make1_string ("A") val _err = dbm_store (dbf, k, v, DBM_INSERT) val () = datum_free (v) val (fpf_v | v) = dbm_fetch (dbf, k) // val () = println! ("k(a) = ", $UN.cast {string} (ptr_of(k.dptr))) val () = println! ("v(A) = ", $UN.cast {string} (ptr_of(v.dptr))) // prval () = fpf_v (datum_takeout_ptr (v)) val _err = dbm_delete (dbf, k) val () = assertloc (_err = 0) prval () = fpf_k (datum_takeout_ptr (k)) // val () = dbm_close (dbf) // } // end of [main] (* ****** ****** *) (* end of [libc_gdbm_ndbm.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_regexp.dats0000664000175000017500000000272412223166161022125 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/SATS/regexp.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) staload "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "libats/SATS/regexp.sats" (* ****** ****** *) fn prerr_usage (cmd: string): void = prerrf ("Usage: %s \n", @(cmd)) // end of [prerr_usage] (* ****** ****** *) dynload "libats/DATS/regexp.dats" (* ****** ****** *) fun print_strposlst {n:nat} (xs: !strposlst n): void = case+ xs of | list_vt_cons (pp, !p_xs) => { val () = printf ("%i-%i\n", @(pp.0, pp.1)) val () = print_strposlst {n} (!p_xs) prval () = fold@ (xs) } // end of [list_vt_cons] | _ => () // end of [print_strposlst] (* ****** ****** *) implement main (argc, argv) = let stavar n: int val intstr = "0123456789": string (n) val intpat = "^([1-9])([0-9]*)$" val re = regexp_compile_exn intpat // val ans = regexp_match_string (re, intstr) val () = if ans then begin printf ("The string [%s] represents a valid integer.\n", @(intstr)) end else begin printf ("The string [%s] does not represent a valid integer.\n", @(intstr)) end // end of [if] // val ans = regexp_match_substring_strposlst (re, intstr, 1, 9) val () = print_strposlst {n} (ans) // val () = list_vt_free (ans) // val () = regexp_free (re) // in // nothing end (* end of [main] *) (* ****** ****** *) (* end of [libats_regexp.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_funheap_binomial.dats0000664000175000017500000000336112223166161024131 0ustar hwxihwxi(* // some testing code for [libats/funheap_binomial] // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: November, 2011 *) (* ****** ****** *) // staload H = "libats/SATS/funheap_binomial.sats" staload _(*anon*) = "libats/DATS/funheap_binomial.dats" // (* ****** ****** *) typedef elt = int typedef heap_t = $H.heap (elt) (* ****** ****** *) implement main (argc, argv) = () where { val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 100 // default val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end // end of [va] val [n:int] n = int1_of_int n val () = assert (n > 0) val cmp = lam (x1: elt, x2: elt): Sgn = compare_int_int (x1, x2) var heap: heap_t = $H.funheap_make_nil () var i: Nat // uninitialized val () = for (i := n; i > 0; i := i-1) let val elt = i val () = $H.funheap_insert (heap, elt, cmp) in // nothing end // end of [val] // val sz = $H.funheap_size (heap) val () = (print "funheap_size (heap) = "; print sz; print_newline ()) // val () = loop (sz, heap) where { val sz = size1_of_size (sz) fun loop {n:nat} .. ( sz: size_t n, heap: &heap_t ) : void = let var x: elt? // uninitialized in if sz > 0 then let val removed = $H.funheap_delmin (heap, cmp, x) val () = assert_errmsg (removed, #LOCATION) prval () = opt_unsome {elt} (x) // val () = (print x; print_newline ()) in loop (sz-1, heap) end // end of [if] end // end of [loop] } // end of [loop] // val sz = $H.funheap_size (heap) val () = (print "funheap_size (heap) = "; print sz; print_newline ()) // } // end of [main] (* ****** ****** *) (* end of [libats_funheap_binomial.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libats_ngc_linmap_avltree.dats0000664000175000017500000001720412223166161024463 0ustar hwxihwxi(* ** some testing code for functions declared in ** libats/ngc/SATS/linmap_avltree.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // Author: Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) // Time: January, 2012 // (* ****** ****** *) staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload "libats/ngc/SATS/linmap_avltree.sats" staload _(*anon*) = "libats/ngc/DATS/linmap_avltree.dats" viewtypedef map_vt (key:t@ype, itm:viewt@ype) = map (key, itm) (* ****** ****** *) %{^ typedef struct { char *value ; } node_itm ; typedef struct { int key ; char *value ; int height ; void *left ; void *right ; } node_struct ; ats_ptr_type node_alloc () { return ATS_MALLOC(sizeof(node_struct)) ; } // end of [node_alloc] ats_void_type node_free (ats_ptr_type p) { return ATS_FREE(p) ; } // end of [node_free] ats_ptr_type node_takeout_val (ats_ptr_type x) { return &(((node_struct*)x)->value) ; } // end of [node_takeout_val] ATSinline() ats_int_type node_get_height (ats_ptr_type x) { return ((node_struct*)x)->height ; } // end of [node_get_height] ATSinline() ats_void_type node_set_height ( ats_ptr_type x, ats_int_type h1 ) { ((node_struct*)x)->height = h1 ; return ; } // end of [node_set_height] ATSinline() ats_ptr_type node_get_left (ats_ptr_type x) { return ((node_struct*)x)->left ; } // end of [node_get_left] ATSinline() ats_void_type node_set_left ( ats_ptr_type x, ats_ptr_type p ) { ((node_struct*)x)->left = p ; return ; } // end of [node_set_left] ATSinline() ats_ptr_type node_get_right (ats_ptr_type x) { return ((node_struct*)x)->right ; } // end of [node_get_right] ATSinline() ats_void_type node_set_right ( ats_ptr_type x, ats_ptr_type p ) { ((node_struct*)x)->right = p ; return ; } // end of [node_set_right] ATSinline() int node_get_key (ats_ptr_type x) { return ((node_struct*)x)->key ; } // end of [node_get_key] ATSinline() void node_set_key (ats_ptr_type x, int k0) { ((node_struct*)x)->key = k0 ; return ; } // end of [node_set_key] %} // end of [%{] (* ****** ****** *) viewtypedef node_itm = $extype_struct "node_itm" of { value= string } // end of [node_itm] (* ****** ****** *) extern fun node_alloc : avlnode_alloc_type (int, node_itm) = "node_alloc" implement avlnode_alloc () = node_alloc () extern fun node_free : avlnode_free_type (int, node_itm) = "node_free" implement avlnode_free (pf | x) = node_free (pf | x) (* ****** ****** *) extern fun node_takeout_val : avlnode_takeout_val_type (int, node_itm) = "node_takeout_val" implement avlnode_takeout_val (pf | x) = node_takeout_val (pf | x) (* ****** ****** *) extern fun node_get_left : avlnode_get_left_type (int, node_itm) = "node_get_left" implement avlnode_get_left (pf | x) = node_get_left (pf | x) extern fun node_set_left : avlnode_set_left_type (int, node_itm)= "node_set_left" implement avlnode_set_left (pf | x, y) = node_set_left (pf | x, y) extern fun node_get_right : avlnode_get_right_type (int, node_itm) = "node_get_right" implement avlnode_get_right (pf | x) = node_get_right (pf | x) extern fun node_set_right : avlnode_set_right_type (int, node_itm) = "node_set_right" implement avlnode_set_right (pf | x, y) = node_set_right (pf | x, y) extern fun node_get_height : avlnode_get_height_type (int, node_itm) = "node_get_height" implement avlnode_get_height (pf | x) = node_get_height (pf | x) extern fun node_set_height : avlnode_set_height_type (int, node_itm) = "node_set_height" implement avlnode_set_height (pf | x, y) = node_set_height (pf | x, y) extern fun node_get_key : avlnode_get_key_type (int, node_itm) = "node_get_key" implement avlnode_get_key (pf | x) = node_get_key (pf | x) extern fun node_set_key : avlnode_set_key_type (int, node_itm) = "node_set_key" implement avlnode_set_key (pf | x, y) = node_set_key (pf | x, y) (* ****** ****** *) implement compare_key_key (x1, x2, cmp) = if x1 < x2 then ~1 else if x1 > x2 then 1 else 0 // end of [compare_key_key] (* ****** ****** *) implement main (argc, argv) = let val () = gc_chunk_count_limit_max_set (~1) // infinite var n: int = 0 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n > 0) val () = $RAND.srand48 (0L) (* val () = $RAND.srand48_with_time () *) // typedef key = int viewtypedef itm = node_itm fn cmp (x1: key, x2: key): Sgn = compare (x1, x2) // var res: itm? // uninitialized // var map = linmap_make_nil {key,itm} () val () = loop (map, n, 0) where { fun loop {i,n:nat | i <= n} .. (map: &map_vt (key, itm), n: int n, i: int i): void = if i < n then let val key = i // val key = $RAND.randint n val itm = tostring_int key // val itm = sprintf ("%i", @(key)) val (pfopt | p) = avlnode_alloc () val () = assertloc (p > null) prval Some_v pfnod = pfopt val () = avlnode_set_key (pfnod | p, key) // val ( pfat, fpfnod | p_itm ) = avlnode_takeout_val (pfnod | p) val () = p_itm->value := itm prval () = pfnod := fpfnod {itm} (pfat) // (* val () = printf ("key = %i and itm = %s\n", @(key, itm)) *) var p = p val found = linmap_insert (pfnod | map, p, cmp) in if found then let prval Some_v pfat = pfnod in avlnode_free (pfat | p) end else let prval None_v () = pfnod in // nothing end; // end of [if] loop (map, n, i+1) end // end of [if] // end of [loop] } // end of [where] // val size = linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val height = linmap_height (map) val () = begin print "height = "; print height; print_newline () end // end of [height] // val () = if :(map: map_vt (key, itm)) => n < 100 then let prval pf = unit_v (); val () = linmap_foreach_vclo {unit_v} (pf | map, !p_clo) where { var !p_clo = @lam (pf: !unit_v | k: key, i: &itm): void = $effmask_all (printf ("%i\t->\t%s\n", @(k, i.value))) } // end of [val] prval unit_v () = pf in // empty end // end of [val] // fn find ( map: &map_vt (key, itm), k: key, res: &itm? ) : void = () where { val () = printf ("%i\t->\t", @(k)) val b = linmap_search (map, k, cmp, res) val () = if b then let prval () = opt_unsome {itm} (res) in print "Some("; print (res.value); print ")" end else let prval () = opt_unnone {itm} (res) in print "None()" end // end of [val] val () = print_newline () } // end of [find] // val () = find (map, 0, res) val () = find (map, 1, res) val () = find (map, 10, res) val () = find (map, 100, res) val () = find (map, 1000, res) val () = find (map, 10000, res) // val () = loop (map, n, 0) where { fun loop {i,n:nat | i <= n} .. (map: &map_vt (key, itm), n: int n, i: int i): void = if i < n then let val key = i val _(*removed*) = linmap_remove (map, key, cmp) in // nothing end // end of [if] // end of [loop] } // end of [where] // val size = linmap_size (map) val () = begin print "size = "; print size; print_newline () end // end of [size] // val () = linmap_free (map) // in // empty end // end of [main] (* ****** ****** *) (* end of [libats_ngc_linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_complex.dats0000664000175000017500000000362212223166161021733 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/complex.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: May, 2009 // (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) implement main (argc, argv) = let // val _1 = ccmplx_of(1) val _i = ccmplx_imag_unit val _1_i = _1 + _i val () = (print "_1_i = "; print _1_i; print_newline ()) val _2_2i = _1_i + _1_i val () = (print "_2_2i = "; print _2_2i; print_newline ()) val _0 = _1_i - _1_i val () = (print "_0 = "; print _0; print_newline ()) val _2i = _1_i * _1_i val () = (print "_2i = "; print _2i; print_newline ()) val _1 = _1_i / _1_i val () = (print "_1 = "; print _1; print_newline ()) // val x = abs (_1_i) val () = (print "|_1_i| = "; print x; print_newline ()) val c = sqrt (_1_i) val () = (print "sqrt(_1_i) = "; print c; print_newline ()) val _1_i = c * c val () = (print "_1_i = "; print _1_i; print_newline ()) val _1_i = pow (c, 2.0f) val () = (print "_1_i = "; print _1_i; print_newline ()) // val _1 = zcmplx_of(1) val _i = zcmplx_imag_unit val _1_i = _1 + _i val () = (print "_1_i = "; print _1_i; print_newline ()) val _2_2i = _1_i + _1_i val () = (print "_2_2i = "; print _2_2i; print_newline ()) val _0 = _1_i - _1_i val () = (print "_0 = "; print _0; print_newline ()) val _2i = _1_i * _1_i val () = (print "_2i = "; print _2i; print_newline ()) val _1 = _1_i / _1_i val () = (print "_1 = "; print _1; print_newline ()) // val x = abs (_1_i) val () = (print "|_1_i| = "; print x; print_newline ()) val z = sqrt (_1_i) val () = (print "sqrt(_1_i) = "; print z; print_newline ()) val _1_i = z * z val () = (print "_1_i = "; print _1_i; print_newline ()) val _1_i = pow (z, 2.0) val () = (print "_1_i = "; print _1_i; print_newline ()) // in // empty end // end of [main] (* ****** ****** *) (* end of [libc_complex.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_printf.dats0000664000175000017500000000140612223166161021564 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/printf.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) staload "libc/SATS/printf.sats" (* ****** ****** *) implement main () = () where { // val ntot = printf ("%s", @("abcdefghijklmnopqrstuvwxyz\n")) val () = assertloc (ntot = 26+1) val () = (print "ntot = "; print ntot; print_newline ()) // val (pfout | pout) = stdout_get () val ntot = fprintf (file_mode_lte_w_w | !pout, "%s", @("ABCDEFGHIJKLMNOPQRSTUVWXYZ\n")) val () = assertloc (ntot = 26+1) val () = (print "ntot = "; print ntot; print_newline ()) val () = stdout_view_set (pfout | (*none*)) // } // end of [main] (* ****** ****** *) (* end of [libc_printf.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_pwd.dats0000664000175000017500000000501512223166161021054 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/pwd.sats *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/pwd.sats" staload "libc/SATS/stdlib.sats" // for [getenv] staload "libc/SATS/unistd_sysconf.sats" // for [_SC_GETPW_R_SIZE_MAX] (* ****** ****** *) fun show_passwd (pw: &passwd): void = let // val (fpf | p) = passwd_get_pw_name (pw) val () = printf ("NAME = %s\n", @($UN.castvwtp1{string}(p))) prval () = fpf (p) // val (fpf | p) = passwd_get_pw_passwd (pw) val () = printf ("PASSWD = %s\n", @($UN.castvwtp1{string}(p))) prval () = fpf (p) // val (fpf | p) = passwd_get_pw_gecos (pw) val () = printf ("RNAME = %s\n", @($UN.castvwtp1{string}(p))) prval () = fpf (p) // val (fpf | p) = passwd_get_pw_dir (pw) val () = printf ("HOME = %s\n", @($UN.castvwtp1{string}(p))) prval () = fpf (p) // val (fpf | p) = passwd_get_pw_shell (pw) val () = printf ("SHELL = %s\n", @($UN.castvwtp1{string}(p))) prval () = fpf (p) // in // nothing end // end of [show_passwd] (* ****** ****** *) implement main () = () where { // val (fpf_logname | logname) = getenv ("LOGNAME") // val () = if strptr_is_null (logname) then { val () = fprintln! (stderr_ref, "[LOGNAME] is undefined!") val () = exit (0) // HX: still considered normal exit } // end of [val] // (* fun getpwnam (nam: !READ(string)): [l:addr] (ptroutopt (passwd, l) | ptr l) = "#atslib_getpwnam" // end of [getpwnam] *) val (pfopt | p_pw) = getpwnam ($UN.castvwtp1{string}(logname)) val () = assertloc (p_pw > null) prval Some_v @(pf_pw, fpf_pw) = pfopt val () = show_passwd (!p_pw) prval () = fpf_pw (pf_pw) // (* fun getpwnam_r {n:nat} ( nam: !READ(string) , pwbuf: &passwd? >> opt (passwd, i==0) , buf: &b0ytes(n) >> bytes(n), n: size_t (n) ) :<> #[i:int | i >= 0] int (0) = "#atslib_getpwnam_r" // end of [getpwnam_r] *) val n = sysconf (_SC_GETPW_R_SIZE_MAX) val () = assertloc (n >= 0L) val n = size_of_lint (n) val n = size1_of_size (n) var !p_buf with pf_buf = @[byte][n]() var pwbuf: passwd var ppwbuf: ptr val err = getpwnam_r ($UN.castvwtp1{string}(logname), pwbuf, !p_buf, n, ppwbuf) val () = assertloc (err = 0) val () = assertloc (ppwbuf = &pwbuf) prval () = opt_unsome {passwd} (pwbuf) val () = show_passwd (pwbuf) // prval () = fpf_logname (logname) // } // end of [main] (* ****** ****** *) (* end of [libc_pwd.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_char.dats0000664000175000017500000000355012223166161021730 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/char.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: August, 2010 // (* ****** ****** *) implement main () = let val () = assert (char_isalpha 'a') val () = assert (~char_isalpha '0') // val () = assert (char_isalnum 'a') val () = assert (char_isalnum '0') val () = assert (~char_isalnum '\n') // val () = assert (char_isprint 'a') val () = assert (~char_isprint '\001') // val () = assert (char_isnull '\000') val () = assert (~char_isnull '\001') // val () = assert (char_ispunct ',') val () = assert (char_ispunct '.') val () = assert (char_ispunct ':') val () = assert (char_ispunct '?') val () = assert (~char_ispunct 'a') val () = assert (~char_ispunct 'A') // val () = assert (char_isspace ' ') val () = assert (char_isspace '\n') val () = assert (char_isspace '\t') val () = assert (~char_isspace '.') // val () = assert (char_isdigit '0') val () = assert (~char_isdigit 'a') // val () = assert (char_isxdigit 'a') val () = assert (char_isxdigit 'A') val () = assert (char_isxdigit '0') val () = assert (~char_isxdigit 'X') // val () = assert (char_islower 'a') val () = assert (~char_islower 'A') val () = assert (~char_islower '0') // val () = assert (char_isupper 'A') val () = assert (~char_isupper 'a') val () = assert (~char_isupper '0') // val () = assert ('a' < 'z') val () = assert ('a' <= 'a') val () = assert ('A' <= 'a') // val () = assert ('z' > 'a') val () = assert ('a' >= 'a') val () = assert ('a' >= 'A') // val () = assert ('a' = 'a') val () = assert ('a' <> 'b') // val () = assert ('9' - '0' = 9) val () = assert ('z' - 'a' = 25) val () = assert ('Z' - 'A' = 25) // in print "[prelude_char.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_char.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/prelude_string.dats0000664000175000017500000001126212223166161022320 0ustar hwxihwxi(* ** some testing code for functions declared in ** prelude/SATS/string.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Spring, 2009 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) #define sbp2str string1_of_strbuf (* ****** ****** *) fn test__lt_string_string () = () where { val ans = lt_string_string ("abcde", "abcde") val () = assert_errmsg (~ans, #LOCATION) val ans = lt_string_string ("abcde", "abcdef") val () = assert_errmsg (ans, #LOCATION) val ans = lt_string_string ("abcde", "bcdef") val () = assert_errmsg (ans, #LOCATION) } // end of [test__lt_string_string] (* ****** ****** *) fn test__lte_string_string () = () where { val ans = lte_string_string ("abcde", "abcde") val () = assert_errmsg (ans, #LOCATION) val ans = lte_string_string ("abcde", "abcdef") val () = assert_errmsg (ans, #LOCATION) val ans = lte_string_string ("abcde", "bcdef") val () = assert_errmsg (ans, #LOCATION) val ans = lte_string_string ("bcdef", "abcde") val () = assert_errmsg (~ans, #LOCATION) } // end of [test__lte_string_string] (* ****** ****** *) fn test__compare_string_string () = () where { val sgn = compare ("abcde", "abcde") val () = assert_errmsg (sgn = 0, #LOCATION) val sgn = compare_string_string ("abcde", "abcdef") val () = assert_errmsg (sgn = ~1, #LOCATION) val sgn = compare_string_string ("abcde", "bcdef") val () = assert_errmsg (sgn = ~1, #LOCATION) val sgn = compare_string_string ("bcdef", "abcde") val () = assert_errmsg (sgn = 1, #LOCATION) } // end of [test__compare_string_string] (* ****** ****** *) fn test__string_make_substring () = () where { val s1 = "abcdefghijklmnopqrstuvwxyz" val s2 = string_make_substring (s1, 11, 3) val s2 = sbp2str (s2) val () = assert_errmsg (s2 = "lmn", #LOCATION) } // end of [test__string_make_substring] (* ****** ****** *) // // HX-2010-03-24: // Note that string0_append and string1_append are the same // at run-time // fn test__string_append () = () where { val s1 = "Hello, " and s2 = "world!" val s12 = sbp2str (s1 + s2) val () = assert_errmsg (s12 = "Hello, world!", #LOCATION) } // end of [test__string_append] (* ****** ****** *) fn test__stringlst_concat () = () where { val abcdef = $lst {string} ("a", "bc", "def") val s = stringlst_concat (abcdef) val s = string_of_strptr (s) val () = assert_errmsg (s = "abcdef", #LOCATION) } // end of [test__stringlst_concat] (* ****** ****** *) implement main (argc, argv) = let // val () = test__lt_string_string () val () = test__lte_string_string () val () = test__compare_string_string () // val () = test__string_make_substring () val () = test__string_append () val () = test__stringlst_concat () // val s1 = "Hello" and s2 = ", world!" val s12 = sbp2str (s1 + s2) // val () = begin print "s12 (Hello, world!) = "; print s12; print_newline () end // end of [val] val cs = string_explode (s12) val () = list_vt_free (cs) // val cs = string_explode (s12) val s12' = sbp2str (sbp) where { val sbp = string_implode (__cast cs) where { extern castfn __cast {n:nat} (cs: !list_vt (char, n)): list (char, n) } // end of [val] } // end of [s12'] val () = list_vt_free (cs) val () = begin print "s12' (Hello, world!) = "; print s12'; print_newline () end // end of [val] val () = assert_errmsg (s12' = "Hello, world!", #LOCATION) // val s12_upper = sbp2str (string_toupper (s12)) val () = begin print "s12_upper (HELLO, WORLD!) = "; print s12_upper; print_newline () end // end of [val] val () = assert_errmsg (s12_upper = "HELLO, WORLD!", #LOCATION) val s12_lower = sbp2str (string_tolower (s12)) val () = begin print "s12_lower (hello, world!) = "; print s12_lower; print_newline () end // end of [val] val () = assert_errmsg (s12_lower = "hello, world!", #LOCATION) // val ind = string_index_of_string ("abcdefghijklmnopqrstuvwsyz", "def") val ind = int1_of_ssize1 (ind) val () = begin print "ind (3) = "; print ind; print_newline () end // end of [val] val () = assert_errmsg (ind = 3, #LOCATION) // val ind = string_index_of_string ("abcdefghijklmnopqrstuvwsyz", "defhij") val ind = int1_of_ssize1 (ind) val () = begin print "ind (-1) = "; print ind; print_newline () end // end of [val] val () = assert_errmsg (ind = ~1, #LOCATION) // prval pf = unit_v () val () = string_foreach__main {..} {ptr} (pf | "Hello, world!", f, null) where { fn f (pf: !unit_v | c: char, _p: !ptr):<1> void = print (c) } // end of [val] val () = print_newline () prval unit_v () = pf in print "[prelude_string.dats] testing passes!\n" end // end of [main] (* ****** ****** *) (* end of [prelude_string.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/TEST/libc_unistd.dats0000664000175000017500000000435312223166161021574 0ustar hwxihwxi(* ** some testing code for functions declared in ** libc/SATS/stdlib.sats *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) staload "libc/SATS/stdio.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) implement main () = () where { // prval () = STDIN_FILENO_gtez () prval () = STDOUT_FILENO_gtez () prval () = STDERR_FILENO_gtez () // val ans = isatty (STDIN_FILENO) val () = (print "isatty (STDIN_FILENO) = "; print ans; print_newline ()) val ans = isatty (STDOUT_FILENO) val () = (print "isatty (STDOUT_FILENO) = "; print ans; print_newline ()) val ans = isatty (STDERR_FILENO) val () = (print "isatty (STDERR_FILENO) = "; print ans; print_newline ()) // val (fpf_name | name) = ttyname (STDIN_FILENO) val () = (print "ttyname (STDIN_FILENO) = "; print name; print_newline ()) prval () = fpf_name (name) val (fpf_name | name) = ttyname (STDOUT_FILENO) val () = (print "ttyname (STDOUT_FILENO) = "; print name; print_newline ()) prval () = fpf_name (name) val (fpf_name | name) = ttyname (STDERR_FILENO) val () = (print "ttyname (STDERR_FILENO) = "; print name; print_newline ()) prval () = fpf_name (name) // // testing [gethostname] and [sethostname] // var !p_buf with pf_buf = @[byte][128]() val (pfopt | err) = gethostname (pf_buf | p_buf, 128) val () = assertloc (err >= 0) prval gethostname_v_succ pf = pfopt val () = (print "gethostname() = "; print_strbuf (!p_buf); print_newline ()) prval () = pf_buf := bytes_v_of_strbuf_v (pf) // val err = sethostname ("xxx.yyy.zzz", 12) val () = if (err < 0) then let val () = perror "sethostname" in (*none*) end // end of [val] // // testing [getdomainname] and [setdomainname] // var !p_buf with pf_buf = @[byte][128]() val (pfopt | err) = getdomainname (pf_buf | p_buf, 128) val () = assertloc (err >= 0) prval getdomainname_v_succ pf = pfopt val () = (print "getdomainname() = "; print_strbuf (!p_buf); print_newline ()) prval () = pf_buf := bytes_v_of_strbuf_v (pf) // val err = setdomainname ("xxx.yyy.zzz", 12) val () = if (err < 0) then let val () = perror "setdomainname" in (*none*) end // end of [val] // } // end of [main] (* ****** ****** *) (* end of [libc_unistd.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/0000700000175000017500000000000012223166161016245 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/gtkcairopascal.dats0000664000175000017500000002467412223166161022142 0ustar hwxihwxi(* ** ** A simple GTK/CAIRO example: ** Illustrating a famous theorm of Pascal's ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2010 ** *) (* ****** ****** *) staload _ = "prelude/DATS/list_vt.dats" staload _ = "prelude/DATS/reference.dats" (* ****** ****** *) staload "libc/SATS/math.sats" macdef PI = M_PI macdef _2PI = 2*PI staload "libc/SATS/random.sats" staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) typedef dbl = double // y = k1 * x + b1 // y = k2 * x + b2 fun line_intersect ( k1: dbl, b1: dbl, k2: dbl, b2: dbl ) : @(dbl, dbl) = (x, y) where { val x = (b1 - b2) / (k2 - k1); val y = k1 * x + b1 } // end of [line_intersect] (* ****** ****** *) fun sort {n:nat} (xs: list_vt (double, n)): list_vt (double, n) = let var !p_cmp = @lam (x1: &double, x2: &double): Sgn = compare (x1, x2) in list_vt_mergesort (xs, !p_cmp) end // end of [sort] (* ****** ****** *) fun draw_colinear {l:agz} ( cr: !cairo_ref l , x1: double, y1: double, x2: double, y2: double, x3: double, y3: double ) : void = if x1 <= x2 then if x1 <= x3 then let val () = cairo_move_to (cr, x1, y1) in if x2 <= x3 then cairo_line_to (cr, x3, y3) else cairo_line_to (cr, x2, y2) end else let val () = cairo_move_to (cr, x3, y3) in cairo_line_to (cr, x2, y2) end else // x2 < x1 if x2 <= x3 then let val () = cairo_move_to (cr, x2, y2) in if x1 <= x3 then cairo_line_to (cr, x3, y3) else cairo_line_to (cr, x1, y1) end else let val () = cairo_move_to (cr, x3, y3) in cairo_line_to (cr, x1, y1) end // end of [if] (* end of [draw_colinear] *) (* ****** ****** *) #define :: list0_cons #define nil list0_nil fun genRandDoubles {n:nat} (n: int n): list_vt (double, n) = if n > 0 then let val x = drand48 () in list_vt_cons (x, genRandDoubles (n-1)) end else list_vt_nil // end of [genRandDoubles] local val () = srand48_with_time () in val theVertexLst : ref (list0 double) = let val ts = genRandDoubles (6) val ts = sort (ts); val ts = list0_of_list_vt (ts) in ref_make_elt (ts) end // enbd of [theVertexLst] end // end of [local] (* ****** ****** *) extern fun draw_pascal_theorem {l:agz} (cr: !cairo_ref l, W: double, H: double): void // end of [draw_pascal_theorem] implement draw_pascal_theorem (cr, W, H) = () where { val ts = !theVertexLst val- t1 :: t2 :: t3 :: t4 :: t5 :: t6 :: nil () = ts val a1 = _2PI * t1 val x1 = cos a1 and y1 = sin a1 val a2 = _2PI * t2 val x2 = cos a2 and y2 = sin a2 val a3 = _2PI * t3 val x3 = cos a3 and y3 = sin a3 val a4 = _2PI * t4 val x4 = cos a4 and y4 = sin a4 val a5 = _2PI * t5 val x5 = cos a5 and y5 = sin a5 val a6 = _2PI * t6 val x6 = cos a6 and y6 = sin a6 // val k12 = (y1 - y2) / (x1 - x2) val b12 = y1 - k12 * x1 val k23 = (y2 - y3) / (x2 - x3) val b23 = y2 - k23 * x2 val k34 = (y3 - y4) / (x3 - x4) val b34 = y3 - k34 * x3 val k45 = (y4 - y5) / (x4 - x5) val b45 = y4 - k45 * x4 val k56 = (y5 - y6) / (x5 - x6) val b56 = y5 - k56 * x5 val k61 = (y6 - y1) / (x6 - x1) val b61 = y6 - k61 * x6 // val (px1, py1) = line_intersect (k12, b12, k45, b45) val (px2, py2) = line_intersect (k23, b23, k56, b56) val (px3, py3) = line_intersect (k34, b34, k61, b61) // val pxs = let #define nil list_vt_nil #define :: list_vt_cons in 1.0 :: ~1.0 :: px1 :: px2 :: px3 :: nil () end // end of [val] val qxs = sort (pxs) val ~list_vt_cons (qx1, qxs) = qxs val ~list_vt_cons (_qx2, qxs) = qxs val ~list_vt_cons (_qx3, qxs) = qxs val ~list_vt_cons (_qx4, qxs) = qxs val ~list_vt_cons (qx5, qxs) = qxs val ~list_vt_nil () = qxs // val dx = qx5 - qx1 // val pys = let #define nil list_vt_nil #define :: list_vt_cons in 1.0 :: ~1.0 :: py1 :: py2 :: py3 :: nil () end // end of [val] val qys = sort (pys) val ~list_vt_cons (qy1, qys) = qys val ~list_vt_cons (_qy2, qys) = qys val ~list_vt_cons (_qy3, qys) = qys val ~list_vt_cons (_qy4, qys) = qys val ~list_vt_cons (qy5, qys) = qys val ~list_vt_nil () = qys // val dy = qy5 - qy1 // val WH = min (W, H) val dxy = max (dx, dy) val alpha = WH / dxy // val () = cairo_translate (cr, (W-WH)/2, (H-WH)/2) // val () = cairo_scale (cr, alpha, alpha) val () = cairo_rectangle (cr, 0.0, 0.0, dxy, dxy) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 1.0) // white color val () = cairo_fill (cr) // val () = cairo_translate ( cr, (dxy - dx) / 2 - (qx1/dx)*dx, (dxy - dy) / 2 - (qy1/dy)*dy ) // end of [val] // val xc = 0.0 and yc = 0.0; val rad = 1.0 val () = cairo_arc (cr, xc, yc, rad, 0.0, _2PI) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 1.0) // blue color val () = cairo_fill (cr) // val () = cairo_move_to (cr, x1, y1) val () = cairo_line_to (cr, x2, y2) val () = cairo_line_to (cr, x3, y3) val () = cairo_line_to (cr, x4, y4) val () = cairo_line_to (cr, x5, y5) val () = cairo_line_to (cr, x6, y6) val () = cairo_close_path (cr) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 0.0) // yellow color val () = cairo_fill (cr) // val () = cairo_set_line_width (cr, 0.01) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) // black color // val () = draw_colinear (cr, x1, y1, x2, y2, px1, py1) val () = draw_colinear (cr, x4, y4, x5, y5, px1, py1) // val () = draw_colinear (cr, x2, y2, x3, y3, px2, py2) val () = draw_colinear (cr, x5, y5, x6, y6, px2, py2) // val () = draw_colinear (cr, x3, y3, x4, y4, px3, py3) val () = draw_colinear (cr, x6, y6, x1, y1, px3, py3) // val () = draw_colinear (cr, px1, py1, px2, py2, px3, py3) // val () = cairo_stroke (cr) // } // end of [draw_pascal_theorem] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" (* ****** ****** *) %{^ GtkWidget *the_drawingarea = NULL; ats_ptr_type the_drawingarea_get () { g_object_ref (G_OBJECT(the_drawingarea)); return the_drawingarea ; } ats_void_type the_drawingarea_set (ats_ptr_type x) { g_object_ref(G_OBJECT(x)) ; if (the_drawingarea) g_object_unref (G_OBJECT(the_drawingarea)); the_drawingarea = x ; return ; } // end of [the_drawingarea_set] %} // end of [%{^] extern fun the_drawingarea_get (): GtkDrawingArea_ref1 = "the_drawingarea_get" extern fun the_drawingarea_set (x: !GtkDrawingArea_ref1): void = "the_drawingarea_set" (* ****** ****** *) fun fnext () = () where { val ts = genRandDoubles (6) val ts = sort (ts) val ts = list0_of_list_vt (ts) // no-op val () = !theVertexLst := ts val darea = the_drawingarea_get () val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = gtk_widget_queue_draw_area (darea, (gint)0, (gint)0, p->width, p->height) prval () = minus_addback (fpf, pf | darea) val () = g_object_unref (darea) } // end of [fnext] fun draw_main {l:agz} ( cr: !cairo_ref l, W: int, H: int ) : void = () where { val W = (double_of)W and H = (double_of)H val () = draw_pascal_theorem (cr, W, H) } // end of [draw_main] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fun fexpose {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let prval () = clstrans {c,GtkDrawingArea,GtkWidget} () val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw_main (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [fexpose] (* ****** ****** *) macdef gs = gstring_of_string (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { // val () = srand48_with_time () // val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // end of [val] val (fpf_x | x) = (gs)"cairo: illustrating Pascal's theorem" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy", G_CALLBACK (gtk_main_quit), (gpointer)null) // val vbox0 = gtk_vbox_new (GFALSE(*homo*), (gint)10(*spacing*)) val () = gtk_container_add (window, vbox0) // val hbox1 = gtk_hbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hbox1) // val darea = gtk_drawing_area_new () val () = the_drawingarea_set (darea) val () = gtk_box_pack_start (vbox0, darea, GTRUE, GTRUE, (guint)0) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (fexpose), (gpointer)null) val () = g_object_unref (darea) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hsep) // val hbox1 = gtk_hbox_new (GFALSE(*homo*), (gint)5(*spacing*)) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GTRUE, (guint)10) // val (fpf_x | x) = (gs)"_Close" val btn_close = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_close, (gsignal)"clicked", G_CALLBACK(gtk_main_quit), (gpointer_vt)window) // end of [val] val () = gtk_box_pack_end (hbox1, btn_close, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_close) // val (fpf_x | x) = (gs)"_Next" val btn_next = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_next, (gsignal)"clicked", G_CALLBACK(fnext), (gpointer)null) // end of [val] val () = gtk_box_pack_end (hbox1, btn_next, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_next) // val () = g_object_unref (hbox1) val () = g_object_unref (vbox0) val () = gtk_widget_show_all (window) val () = g_object_unref (window) val () = gtk_main () } // end of [main1] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [gtkcairopascal.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/GameOf24.dats0000664000175000017500000004370112223166161020447 0ustar hwxihwxi// // Game-of-24 with a rough GUI // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/list_vt.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload MATH = "libc/SATS/math.sats" staload RAND = "libc/SATS/random.sats" (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) datatype exp = | Num of double | Add of (exp, exp) | Sub of (exp, exp) | Mul of (exp, exp) | Div of (exp, exp) // end of [exp] (* ****** ****** *) extern fun eq_exp_exp (x1: exp, x2: exp):<> bool overload = with eq_exp_exp implement eq_exp_exp (x1, x2) = case+ (x1, x2) of | (Num d1, Num d2) => (d1 = d2) | (Add (x11, x12), Add (x21, x22)) => (x11 = x21 andalso x12 = x22) orelse (x11 = x22 andalso x12 = x21) | (Sub (x11, x12), Sub (x21, x22)) => (x11 = x21) andalso (x12 = x22) | (Mul (x11, x12), Mul (x21, x22)) => (x11 = x21 andalso x12 = x22) orelse (x11 = x22 andalso x12 = x21) | (Div (x11, x12), Div (x21, x22)) => (x11 = x21) andalso (x12 = x22) | (_, _) => false // end of [eq_exp_exp] fun explst_remdup (xs: List exp): List exp = case+ xs of | list_cons (x, xs) => let var !p_clo = @lam (pf: !unit_v | x1: exp): bool = ~(x = x1) prval pf = unit_v () val xs = list_filter_vclo {unit_v} (pf | xs, !p_clo) prval unit_v () = pf val xs = list_of_list_vt (xs) in list_cons (x, explst_remdup xs) end // end of [list_cons] | list_nil () => list_nil () // end of [explst_remdup] (* ****** ****** *) fun eval_exp (e: exp): double = case+ e of | Num (a) => a | Add (e1, e2) => eval_exp e1 + eval_exp e2 | Sub (e1, e2) => eval_exp e1 - eval_exp e2 | Mul (e1, e2) => eval_exp e1 * eval_exp e2 | Div (e1, e2) => eval_exp e1 / eval_exp e2 // end of [eval_exp] fun priority_of (e: exp): Nat = (case+ e of | Num _ => 0 | Add _ => 2 | Sub _ => 2 | Mul _ => 1 | Div _ => 1 ) : Nat // end of [priority_of] (* ****** ****** *) fun g_print_exp {l:agz} (gs: !GString_ptr l, e: exp): void = begin case+ e of | Num r => g_string_append_printf (gs, "%.0f", @(r)) | Add (e1, e2) => let val p1 = priority_of (e1) and p2 = priority_of (e2) val () = g_print_exp_ (gs, 2, p1, e1) val _ = g_string_append_c (gs, (gchar)'+') val () = g_print_exp_ (gs, 2, p2, e2) in // nothing end // end of [Add] | Sub (e1, e2) => let val p1 = priority_of (e1) and p2 = priority_of (e2) val () = g_print_exp_ (gs, 2, p1, e1) val _ = g_string_append_c (gs, (gchar)'-') val () = g_print_exp_ (gs, 2, p2, e2) in // nothing end // end of [Sub] | Mul (e1, e2) => let val p1 = priority_of (e1) and p2 = priority_of (e2) val () = g_print_exp_ (gs, 1, p1, e1) val _ = g_string_append_c (gs, (gchar)'*') val () = g_print_exp_ (gs, 1, p2, e2) in // nothing end // end of [Mul] | Div (e1, e2) => let val p1 = priority_of (e1) and p2 = priority_of (e2) val () = g_print_exp_ (gs, 1, p1, e1) val _ = g_string_append_c (gs, (gchar)'/') val () = g_print_exp_ (gs, 1, p2, e2) in // nothing end // end of [Div] end // end of [print_exp] and g_print_exp_ {l:agz} (gs: !GString_ptr l, p0: Nat, p: Nat, e: exp): void = if p < p0 then g_print_exp (gs, e) else let val _ = g_string_append_c (gs, (gchar)'\(') val () = g_print_exp (gs, e) val _ = g_string_append_c (gs, (gchar)')') in // nothing end // end of [if] // end of [print_exp_] fun print_exp (e: exp): void = let val gs = g_string_new () val () = g_print_exp (gs, e) val ptr = g_string_get_str (gs) val () = print (string) where { val string = __cast (ptr) where { extern castfn __cast (x: ptr): string } } // end of [val] in g_string_free_true (gs) end // end of [print_exp] (* ****** ****** *) typedef explst (n:int) = list (exp, n) #define EPSILON 0.000001 fn iseq (a1: double, a2: double): bool = abs (a1 - a2) < EPSILON // end of [isZero] fn explst_add_exp_exp ( ans: double, res: List exp, x1: exp, x2: exp ) : List exp = res where { var res: List exp = res val a1 = eval_exp x1 and a2 = eval_exp x2 val () = if iseq (a1 + a2, ans) then res := list_cons (Add (x1, x2), res) val () = if iseq (a1 - a2, ans) then res := list_cons (Sub (x1, x2), res) val () = if iseq (a2 - a1, ans) then res := list_cons (Sub (x2, x1), res) val () = if iseq (a1 * a2, ans) then res := list_cons (Mul (x1, x2), res) val () = if iseq (a1 / a2, ans) then res := list_cons (Div (x1, x2), res) val () = if iseq (a2 / a1, ans) then res := list_cons (Div (x2, x1), res) } // end of [explst_add_exp_exp] macdef list_revapp = list_reverse_append fun play {n:int | n >= 2} ( ans: double, n: int n, xs: explst n, res: List exp ) : List exp = if n > 2 then let fun aux {n1,n3,n4:nat | n1+1+n3+n4 == n} .. ( xs1: explst n1 , x2: exp, xs2: explst (n3+n4) , xs3: explst n3, xs4: explst n4 , res: List exp ) : List exp = case+ xs4 of | list_cons (x4, xs4) => let val ys = list_revapp (xs3, xs4) val ys = list_revapp (xs1, ys) val ys1 = list_cons (Add (x2, x4), ys) val res = play (ans, n-1, ys1, res) val ys1 = list_cons (Sub (x2, x4), ys) val res = play (ans, n-1, ys1, res) val ys1 = list_cons (Sub (x4, x2), ys) val res = play (ans, n-1, ys1, res) val ys1 = list_cons (Mul (x2, x4), ys) val res = play (ans, n-1, ys1, res) val ys1 = list_cons (Div (x2, x4), ys) val res = play (ans, n-1, ys1, res) val ys1 = list_cons (Div (x4, x2), ys) val res = play (ans, n-1, ys1, res) in aux (xs1, x2, xs2, list_cons (x4, xs3), xs4, res) end // end of [list_cons] | list_nil () => begin case+ xs2 of | list_cons (x21, xs21) => let val xs1 = list_cons (x2, xs1) in aux (xs1, x21, xs21, list_nil, xs21, res) end // end of [list_cons] | list_nil () => res end // end of [list_nil] val+ list_cons (x, xs) = xs in aux (list_nil, x, xs, list_nil, xs, res) end else let // n = 2 val+ list_cons (x1, xs) = xs val+ list_cons (x2, xs) = xs in explst_add_exp_exp (ans, res, x1, x2) end (* end of [if] *) // end of [play] (* ****** ****** *) macdef gs = gstring_of_string (* ****** ****** *) overload gint with gint_of_GtkResponseType (* ****** ****** *) fun answering {c:cls | c <= GtkWindow} {l:agz} ( parent: !gobjref (c, l), xs: List exp ) : void = () where { val dialog = gtk_dialog_new () // val () = gtk_window_set_transient_for (dialog, parent) // val (fpf_win | win) = gtk_dialog_get_window (dialog) val (fpf_x | x) = (gs)"Game-of-24 Answer Dialog" val () = gtk_window_set_title (dialog, x) prval () = fpf_x (x) prval () = minus_addback (fpf_win, win | dialog) // val (fpf_x | x) = (gs)"_Close" val (fpf_button | button) = gtk_dialog_add_button (dialog, x, (GtkResponseType)0) prval () = fpf_x (x) prval () = minus_addback (fpf_button, button | dialog) // val (fpf_vbox0 | vbox0) = gtk_dialog_get_vbox (dialog) // val hbox1 = gtk_hbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (vbox0, hbox1, GTRUE, GTRUE, guint(10)) val () = (case+ xs of | list_cons _ => let // val (fpf_x | x) = (gs)"Solution(s) found:" val frame = gtk_frame_new (x) prval () = fpf_x (x) val () = gtk_box_pack_start (hbox1, frame, GTRUE, GFALSE, guint(10)) val [l_box:addr] vbox2 = gtk_vbox_new (GTRUE, gint(2)) val () = gtk_container_add (frame, vbox2) // val [l_str:addr] gs = g_string_new () val () = loop (vbox2, gs, xs) where { fun loop ( vbox2: !gobjref (GtkVBox, l_box), gs: !GString_ptr l_str, xs: List exp ) : void = case+ xs of | list_cons (x, xs) => let val _ptr = g_string_truncate (gs, gsize(0)) val () = g_print_exp (gs , x) val () = g_string_append_printf (gs, " = 24", @()) val ptr = g_string_get_str (gs) extern castfn __cast (x: ptr): [l:agz] (gstring l - void | gstring l) val (fpf_x | x) = __cast (ptr) val label_msg = gtk_label_new (x) prval () = fpf_x (x) val () = gtk_box_pack_start (vbox2, label_msg, GFALSE, GTRUE, guint(0)) val () = gtk_widget_show_unref (label_msg) in loop (vbox2, gs, xs) end // end of [list_cons] | list_nil () => () } val () = g_string_free_true (gs) val () = gtk_widget_show_unref (vbox2) val () = gtk_widget_show_unref (frame) in // nothing end // end of [if] | list_nil _ => let val (fpf_x | x) = (gs)"No solution found!" val label_ans = gtk_label_new (x) prval () = fpf_x (x) val () = gtk_box_pack_start (hbox1, label_ans, GTRUE, GFALSE, guint(10)) val () = gtk_widget_show_unref (label_ans) in // nothing end // end of [if] ) : void // end of [val] val () = gtk_widget_show_unref (hbox1) // prval () = minus_addback (fpf_vbox0, vbox0 | dialog) // val () = gtk_widget_show (dialog) // this is automatically done // val () = while (true) let val response = gtk_dialog_run (dialog) // val () = (print "response = "; print ((int_of)response); print_newline ()) in case+ 0 of | _ when response = (gint)0 => break | _ when response = (gint)GTK_RESPONSE_DELETE_EVENT => break | _ => () end // end of [val] // val () = gtk_widget_destroy0 (dialog) } // end of [answering] (* ****** ****** *) fun play24 {c:cls | c <= GtkWindow} {l:agz} {n:nat} (parent: !gobjref (c, l), ns: list_vt (int, n)): void = let val xs = loop (ns, list_nil) where { fun loop {i,j:nat} .. (ns: list_vt (int, i), xs: explst j): explst (i+j) = case+ ns of | ~list_vt_cons (n, ns) => let val x = Num (double_of(n)) in loop (ns, list_cons (x, xs)) end // end of [list_vt_cons] | ~list_vt_nil () => xs // end of [loop] } // end of [val] val n = list_length (xs) val () = assert_errmsg (n >= 2, #LOCATION) val ans = 24.0 val res = play (ans, n, xs, list_nil) val res = explst_remdup (res) val () = answering (parent, res) (* val () = loop (res) where { fun loop (xs: List exp): void = case+ xs of | list_cons (x, xs) => loop (xs) where { val () = (print_exp x; print " = "; print 24; print_newline ()) } // end of [list_cons] | list_nil () => () // end of [loop] } // end of [val] *) in // nothing end // end of [play24] (* ****** ****** *) #define MAX 13.0 (* ****** ****** *) fun suit_spinner_gen (): GtkSpinButton_ref1 = let val adj = gtk_adjustment_new (1.0, 1.0, MAX, 1.0, 0.0(*ignored*), 0.0(*ignored*)) val spinner = gtk_spin_button_new (adj, (gdouble)0.0, (guint)0) val () = gtk_spin_button_set_numeric (spinner, GTRUE) val () = gtk_spin_button_set_wrap (spinner, GTRUE) val () = g_object_unref (adj) in spinner end // end of [suit_spinner_gen] (* ****** ****** *) viewtypedef suitSpinnerLst = List_vt (GtkSpinButton_ref1) val theSuitSpinnerLst = ref_make_elt (list_vt_nil) // end of [val] fun theSuitSpinnerLst_add (x: !GtkSpinButton_ref1): void = () where { val (vbox pf_xs | p_xs) = ref_get_view_ptr (theSuitSpinnerLst) val x1 = $effmask_ref (g_object_ref (x)) val () = !p_xs := list_vt_cons (x1, !p_xs) } // end of [theSuitSpinnerLst_add] (* ****** ****** *) fun inputapp (): void = () where { fun loop (xs: !suitSpinnerLst): void = case+ xs of | list_vt_cons (!p_x, !p_xs) => let var min: gdouble and max: gdouble val () = gtk_spin_button_get_range (!p_x, min, max) val max = double_of(max) and min = double_of(min) val v = $MATH.floor (min + (max + 1 - min) * $RAND.drand48 ()) val v = gtk_spin_button_set_value (!p_x, (gdouble)v) val () = loop (!p_xs) prval () = fold@ (xs) in // nothing end // end of [list_vt_cons] | list_vt_nil () => (fold@ xs) // end of [loop] val () = $effmask_ref (loop (!p_xs)) where { val (vbox pf_xs | p_xs) = ref_get_view_ptr (theSuitSpinnerLst) } } // end of [inputapp] (* ****** ****** *) fun evalapp {c:cls | c <= GtkWindow} {l:agz} (parent: !gobjref (c, l)): void = let fun loop (xs: !suitSpinnerLst): List_vt int = case+ xs of | list_vt_cons (!p_x, !p_xs) => let val v = gtk_spin_button_get_value_as_int (!p_x) val v = int_of(v) val vs = loop (!p_xs) val () = fold@ (xs) in list_vt_cons (v, vs) end // end of [list_vt_cons] | list_vt_nil () => (fold@ xs; list_vt_nil) // end of [loop] val (vbox pf_xs | p_xs) = ref_get_view_ptr (theSuitSpinnerLst) val vs = $effmask_ref (loop (!p_xs)) val () = $effmask_ref (play24 (parent, vs)) in // nothing end // end of [evalapp] (* ****** ****** *) staload PRINTF = "libc/SATS/printf.sats" fun suit_spinnerlst_hbox_gen {n:nat} (n: int n): GtkHBox_ref1 = let val hbox = gtk_hbox_new (GTRUE(*homo*), (gint)10(*spacing*)) val () = loop (hbox, n, 1) where { fun loop {c:cls | c <= GtkBox} {l:agz} {n:nat} .. ( box: !gobjref (c, l), n: int n, i: int ) : void = if n > 0 then let val vbox = gtk_vbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (box, vbox, GTRUE, GTRUE, (guint)20) val name = g_strdup_printf ("Card %d:", @(i)) val label = gtk_label_new (name) val () = gstring_free (name) val () = gtk_box_pack_start (vbox, label, GFALSE, GTRUE, (guint)2) val spinner = suit_spinner_gen () val () = theSuitSpinnerLst_add (spinner) val () = gtk_box_pack_start (vbox, spinner, GFALSE, GTRUE, (guint)2) val () = gtk_widget_show_unref (label) val () = gtk_widget_show_unref (spinner) val () = gtk_widget_show_unref (vbox) in loop (box, n-1, i+1) end // end of [if] // end of [loop] } // end of [val] in hbox end // end of [suit_spinnerlst_hbox_gen] (* ****** ****** *) fun quitapp {c:cls | c <= GtkWidget} {l:agz} (widget: !gobjref (c, l), event: &GdkEvent, _: gpointer): gboolean = let val () = gtk_main_quit () in GFALSE // delivered! end // end of [quitapp] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { // val () = $RAND.srand48_with_time () // val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val _sig = g_signal_connect (window, (gsignal)"destroy", G_CALLBACK(gtk_widget_destroy), (gpointer)null) val _sig = g_signal_connect (window, (gsignal)"delete_event", G_CALLBACK(quitapp), (gpointer)null) val (fpf_x | x) = (gs)"Game-of-24" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val vbox0 = gtk_vbox_new (GFALSE(*homo*), (gint)0) // val (fpf_x | x) = (gs)"Game-of-24" val label_title = gtk_label_new (x) prval () = fpf_x (x) val () = gtk_box_pack_start (vbox0, label_title, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (label_title) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GTRUE, GTRUE, (guint)0) val () = gtk_widget_show_unref (hsep) // val hbox_suits = suit_spinnerlst_hbox_gen (4) val () = gtk_box_pack_start (vbox0, hbox_suits, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (hbox_suits) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GTRUE, GTRUE, (guint)0) val () = gtk_widget_show_unref (hsep) // val hbox = gtk_hbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (vbox0, hbox, GTRUE, GTRUE, (guint)10) // val () = () where { // adding the [input] button val (fpf_x | x) = (gs)"Random Input" val button = gtk_button_new_with_label (x) prval () = fpf_x (x) val _sid = g_signal_connect (button, (gsignal)"clicked", G_CALLBACK(inputapp), (gpointer)null) val () = gtk_box_pack_start (hbox, button, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (button) } // end of [val] // val () = () where { // adding the [eval] button val (fpf_x | x) = (gs)"Eval" val button = gtk_button_new_with_label (x) prval () = fpf_x (x) val _sid = g_signal_connect_swapped (button, (gsignal)"clicked", G_CALLBACK(evalapp), window) val () = gtk_box_pack_start (hbox, button, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (button) } // end of [val] // val () = gtk_widget_show_unref (hbox) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GTRUE, GTRUE, (guint)0) val () = gtk_widget_show_unref (hsep) // val hbox = gtk_hbox_new (GFALSE, (gint)0) val (fpf_x | x) = (gs)"_Quit" val button = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect_swapped (button, (gsignal)"clicked", G_CALLBACK(quitapp), window) val () = gtk_box_pack_start (hbox, button, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (button) val () = gtk_box_pack_start (vbox0, hbox, GTRUE, GTRUE, (guint)10) val () = gtk_widget_show_unref (hbox) // val () = gtk_container_add (window, vbox0) val () = gtk_widget_show_unref (vbox0) // val () = gtk_widget_show (window) val () = g_object_unref (window) // ref-count becomes 1! val () = gtk_main () } // end of [main1] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [GameOf24.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/Makefile0000664000175000017500000000474112223166161017727 0ustar hwxihwxi# # # Some Examples in ATS involving GTK+ programming # # ###### ATSUSRQ="$(ATSHOME)" ATSLIBQ="$(ATSHOME)" ifeq ("$(ATSHOME)","") ATSUSRQ="/usr" ATSLIBQ="/usr/lib/ats-anairiats-0.2.3" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### GTKFLAGS=`pkg-config gtk+-2.0 --cflags --libs` ###### .PHONY: all all: checkall ###### checkall: compall cleanall ###### # # Please do the following # cd $ATSHOME/contrib/GTK; make atsctrb_GTK.o # if "atsctrb_GTK.o" is not available # LIBATSGTK=$(ATSLIBQ)/contrib/GTK/atsctrb_GTK.o compall:: GameOf24 GameOf24: GameOf24.dats $(ATSCC) -D_ATS_GCATS -o $@ GameOf24.dats $(LIBATSGTK) $(GTKFLAGS) -lm ###### compall:: gtkcairoclock gtkcairoclock: gtkcairoclock.dats $(ATSCC) -Wl,-rpath,$(ATSLIBQ)/ccomp/lib -o $@ gtkcairoclock.dats $(GTKFLAGS) -lm ###### ATSCTRB=$(ATSLIBQ)/contrib/cairo/atsctrb_cairo.o compall:: gtkcairodisc gtkcairodisc: gtkcairodisc.dats $(ATSCC) -D_ATS_GCATS $(ATSCTRB) -o $@ gtkcairodisc.dats $(GTKFLAGS) -lm ###### compall:: gtkcairopascal gtkcairopascal: gtkcairopascal.dats $(ATSCC) -D_ATS_GCATS -o $@ gtkcairopascal.dats $(GTKFLAGS) -lm ###### ATSCTRB=$(ATSLIBQ)/contrib/cairo/atsctrb_cairo.o compall:: bsearch_demo bsearch_demo: bsearch_demo.dats $(ATSCC) -D_ATS_GCATS $(ATSCTRB) -o $@ bsearch_demo.dats $(GTKFLAGS) -lm ###### html:: ; $(ATSOPT) --posmark_html -d GameOf24.dats > GameOf24_dats.html html:: ; $(ATSOPT) --posmark_html -d gtkcairoclock.dats > gtkcairoclock_dats.html html:: ; $(ATSOPT) --posmark_html -d gtkcairodisk.dats > gtkcairodisk_dats.html html:: ; $(ATSOPT) --posmark_html -d gtkcairopascal.dats > gtkcairopascal_dats.html html:: ; $(ATSOPT) --posmark_html -d bsearch_demo.dats > bsearch_demo_dats.html ###### xref:: ; $(ATSOPT) --posmark_xref=XREF -d \ $(ATSHOME)/utils/xref/ats_prelude_xref.dats > /dev/null xref:: ; $(ATSOPT) --posmark_xref=XREF -d GameOf24.dats > GameOf24_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d gtkcairoclock.dats > gtkcairoclock_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d gtkcairodisk.dats > gtkcairodisk_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d gtkcairopascal.dats > gtkcairopascal_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d bsearch_demo.dats > bsearch_demo_dats.html ###### RMF=rm -f ###### clean:: $(RMF) *~ $(RMF) *_?ats.c cleanall:: clean $(RMF) ./XREF/* $(RMF) ./*_?ats.html $(RMF) GameOf24 $(RMF) gtkcairoclock $(RMF) gtkcairodisc $(RMF) gtkcairopascal $(RMF) bsearch_demo ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/gtkcairodisc.dats0000664000175000017500000002630412223166161021611 0ustar hwxihwxi(* ** ** A simple GTK/CAIRO example: a clock @ home ** The part of clock drawing is largely taken from ** a cairo example I did in December 2009 ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 ** *) (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload "libc/SATS/math.sats" macdef PI = M_PI staload "libc/SATS/random.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" staload "contrib/cairo/SATS/cairo_extra.sats" (* ****** ****** *) stadef dbl = double stadef cr = cairo_ref (* ****** ****** *) val theWidth = 50.0 val theHeight = 50.0 val theRadius = sqrt (theWidth*theWidth + theHeight*theHeight) val theTimeInterval = 30 (* ****** ****** *) typedef disc = @{ x= dbl, y= dbl, r= dbl, vx= dbl, vy= dbl, txt= string } // end of [disc] fn draw_disc {l:agz} (cr: !cr l, d: &disc): void = let val x = d.x and y = d.y val r = d.r val rad = sqrt (x*x + y*y) val r1 = r/5 + 4*r/5 * (1 - rad / theRadius) val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, x, y) val () = cairo_arc (cr, 0.0, 0.0, r1, 0.0, 2*PI) val () = cairo_fill (cr) val w = 1.6*r1 and h = 1.6*r1 val txt = d.txt val () = if txt <> "" then let val () = cairo_set_source_rgb (cr, 0.0, 0.5, 0.5) // dark gray val () = cairo_show_text_inbox (cr, w, h, txt) in // nothing end // end of [val] val () = cairo_restore (pf | cr) in // nothing end // end of [draw_hand] (* ****** ****** *) val theDiscLst: ref (List disc) = ref_make_elt (list_nil) fn draw_theDiscLst {l:agz} (cr: !cr l): void = let fun loop {n:nat} .. (cr: !cr l, ds: !list_vt (disc, n)): void = case+ ds of | list_vt_cons (!p_d, !p_ds) => let val () = draw_disc (cr, !p_d) val () = loop (cr, !p_ds); prval () = fold@ (ds) in // nothing end // end of [list_cons] | list_vt_nil () => fold@ (ds) // end of [loop] val ds = !theDiscLst val (fpf_ds | ds) = __cast (ds) where { viewtypedef T = List_vt (disc) extern castfn __cast {a:type} (x: List disc):<> (T - void | T) } // end of [val] val () = loop (cr, ds) prval () = fpf_ds (ds) in // nothing end // end of [draw_theDiscLst] (* ****** ****** *) extern fun draw_main {l:agz} (cr: !cairo_ref l, width: int, height: int): void implement draw_main (cr, width, height) = () where { val w = (double_of)width val h = (double_of)height val mn = min (w, h) val xc = w / 2 and yc = h / 2 val (pf0 | ()) = cairo_save (cr) val () = cairo_translate (cr, xc, yc) val alpha = mn / 100 val () = cairo_scale (cr, alpha, alpha) // val () = cairo_rectangle (cr, ~50.0, ~50.0, 100.0, 100.0) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 1.0) val () = cairo_fill (cr) // val () = cairo_set_source_rgb (cr, 1.0, 0.5, 0.5) val () = draw_theDiscLst (cr) // val () = cairo_restore (pf0 | cr) } // end of [draw_main] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" (* ****** ****** *) %{^ GtkWidget *the_drawingarea = NULL; ats_ptr_type the_drawingarea_get () { if (the_drawingarea == NULL) { fprintf (stderr, "exit(the_drawingarea_get): not initialized yet\n"); exit(1); } // end of [if] return the_drawingarea ; } // end of [the_drawingarea_get] ats_void_type the_drawingarea_initset (ats_ptr_type x) { static int the_drawingarea_initset_flag = 0 ; if (the_drawingarea_initset_flag) { fprintf (stderr, "exit(the_drawingarea_initset): already initialized\n"); exit(1); } // end of [if] the_drawingarea_initset_flag = 1 ; the_drawingarea = x ; return ; } // end of [the_drawingarea_initset] %} // end of [%{^] extern fun the_drawingarea_get (): [l:agz] (gobjref (GtkDrawingArea, l) - void | gobjref (GtkDrawingArea, l)) = "the_drawingarea_get" // end of [the_drawingarea_get] extern fun the_drawingarea_initset (x: GtkDrawingArea_ref1): void = "the_drawingarea_initset" // end of [the_drawingarea_initset] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fn discGen (): disc = let val r = 10 * drand48 () val x = (theWidth - r) * drand48 () val y = (theWidth - r) * drand48 () val vx = 0.05 * drand48 () val vy = 0.05 * drand48 () in @{ x= x, y= y, r= r, vx= vx, vy= vy, txt= "" } end // end of [discGen] fun fnext () = let val d = discGen () val ds = !theDiscLst (* val n = list_length (ds) val () = (print "fnext: n = "; print n; print_newline ()) *) in !theDiscLst := list_cons (d, ds) end // end of [fnext] fun fprev () = let val ds = !theDiscLst in case ds of | list_cons (d, ds) => !theDiscLst := ds | list_nil () => () end // end of [fprev] (* ****** ****** *) fn update_disc (d: &disc): void = let var xsgn: int = 1 var ysgn: int = 1 val r = d.r val w = theWidth - r val h = theHeight - r val vx = d.vx and vy = d.vy val dx = vx * theTimeInterval val dy = vy * theTimeInterval val x1 = d.x + dx val x1 = ( if x1 > w then (xsgn := ~1; 2*w - x1) else if x1 < ~w then (xsgn := ~1; ~2*w - x1) else x1 ) : double val y1 = d.y + dy val y1 = ( if y1 > h then (ysgn := ~1; 2*h - y1) else if y1 < ~h then (ysgn := ~1; ~2*h - y1) else y1 ) : double in d.x := x1; d.y := y1; d.vx := xsgn * vx; d.vy := ysgn * vy end // end of [update_disc] fn update_theDiscLst (): void = let fun loop {n:nat} .. (ds: !list_vt (disc, n)): void = case+ ds of | list_vt_cons (!p_d, !p_ds) => let val () = update_disc (!p_d) val () = loop (!p_ds); prval () = fold@ (ds) in // nothing end // end of [list_cons] | list_vt_nil () => fold@ (ds) // end of [loop] val ds = !theDiscLst val (fpf_ds | ds) = __cast (ds) where { viewtypedef T = List_vt (disc) extern castfn __cast {a:type} (x: List disc):<> (T - void | T) } // end of [val] val () = loop (ds) prval () = fpf_ds (ds) in // nothing end // end of [update_theDiscLst] (* ****** ****** *) fn fexpose {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let prval () = clstrans {c,GtkDrawingArea,GtkWidget} () val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw_main (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [fexpose] (* ****** ****** *) fn ftimeout (_: gpointer): gboolean = let val (fpf_darea | darea) = the_drawingarea_get () val (fpf_win | win) = gtk_widget_get_window (darea) in if g_object_isnot_null (win) then let val () = update_theDiscLst () prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = gtk_widget_queue_draw_area (darea, (gint)0, (gint)0, p->width, p->height) prval () = minus_addback (fpf, pf | darea) prval () = fpf_darea (darea) in GTRUE end else let prval () = minus_addback (fpf_win, win | darea) prval () = fpf_darea (darea) in GFALSE // HX: terminating the timer end // end of [if] end // end of [ftimeout] (* ****** ****** *) val () = let val ds = !theDiscLst val d = @{ x= 45.0, y= 0.0, r= 12.0, vx= 0.023, vy= 0.037, txt= "Zoe" } // end of [val] val ds = list_cons (d, ds) val d = @{ x= ~45.0, y= 0.0, r= 5.0, vx= 0.037, vy= 0.023, txt= "mom" } // end of [val] val ds = list_cons (d, ds) val d = @{ x= 0.0, y= 15.0, r= 8.0, vx= 0.041, vy= 0.029, txt= "dad" } // end of [val] val ds = list_cons (d, ds) val d = @{ x= 0.0, y= 15.0, r= 10.0, vx= 0.043, vy= 0.019, txt= "grandma" } // end of [val] val ds = list_cons (d, ds) val d = @{ x= 0.0, y= ~25.0, r= 10.0, vx= 0.047, vy= 0.029, txt= "grandpa" } // end of [val] val ds = list_cons (d, ds) in !theDiscLst := ds end // end of [val] (* ****** ****** *) macdef gs = gstring_of_string (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { // val () = srand48_with_time () // val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // end of [val] val (fpf_x | x) = (gs)"cairo: moving discs" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy", G_CALLBACK (gtk_main_quit), (gpointer)null) // val vbox0 = gtk_vbox_new (GFALSE(*homo*), (gint)10(*spacing*)) val () = gtk_container_add (window, vbox0) // val hbox1 = gtk_hbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hbox1) // val darea = gtk_drawing_area_new () val () = gtk_box_pack_start (vbox0, darea, GTRUE, GTRUE, (guint)0) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (fexpose), (gpointer)null) val () = the_drawingarea_initset (darea) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hsep) // val hbox1 = gtk_hbox_new (GFALSE(*homo*), (gint)5(*spacing*)) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GTRUE, (guint)10) // val (fpf_x | x) = (gs)"_Close" val btn_close = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_close, (gsignal)"clicked", G_CALLBACK(gtk_main_quit), (gpointer_vt)window) // end of [val] val () = gtk_box_pack_end (hbox1, btn_close, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_close) // val (fpf_x | x) = (gs)"_Remove" val btn_next = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_next, (gsignal)"clicked", G_CALLBACK(fprev), (gpointer)null) // end of [val] val () = gtk_box_pack_end (hbox1, btn_next, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_next) // val (fpf_x | x) = (gs)"_Add" val btn_next = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_next, (gsignal)"clicked", G_CALLBACK(fnext), (gpointer)null) // end of [val] val () = gtk_box_pack_end (hbox1, btn_next, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_next) // val _rid = gtk_timeout_add ((guint32)theTimeInterval, ftimeout, (gpointer)null) // val () = g_object_unref (hbox1) val () = g_object_unref (vbox0) val () = gtk_widget_show_all (window) val () = g_object_unref (window) val () = gtk_main () } // end of [main1] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [gtkcairodisc.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/bsearch_demo.dats0000664000175000017500000002772712223166161021570 0ustar hwxihwxi(* ** ** A simple GTK/CAIRO example: demonstrating binary search ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: July, 2010 ** *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" staload "contrib/cairo/SATS/cairo_extra.sats" (* ****** ****** *) fun draw_intarray {l:agz} {n:pos} ( cr: !cairo_ref l, W: double, H: double, A: array (int, n), n: int n ) : void = () where { val () = cairo_rectangle (cr, ~W/2, ~H/2, W, H) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 1.0) val () = cairo_fill (cr) // val w = W / n fun loop {i:nat | i <= n} (cr: !cairo_ref l, x: double, i: int i): void = if i < n then let val () = cairo_move_to (cr, x, ~H/2) val () = cairo_rel_line_to (cr, 0.0, H) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_stroke (cr) val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, x + w/2, 0.0) val () = cairo_set_source_rgb (cr, 0.25, 0.25, 0.25) // val txt = sprintf ("%2.2i", @(A[i])) val () = cairo_show_text_inbox (cr, w, H, $UN.castvwtp1{string} (txt)) val () = strptr_free (txt) // val () = cairo_restore (pf | cr) in loop (cr, x+w, i+1) end else let val () = cairo_move_to (cr, x, ~H/2) val () = cairo_rel_line_to (cr, 0.0, H) val () = cairo_stroke (cr) in // nothing end (* end of [if] *) // end of [loop] val () = loop (cr, ~W/2, 0) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_stroke (cr) // } // end of [draw_intarray] (* ****** ****** *) fun{a:t@ype} array_copy {n:nat} ( A: array (a, n), n: size_t n ) : array (a, n) = B where { val (vbox pf1_arr | p1) = array_get_view_ptr (A) val (pf2_gc, pf2_arr | p2) = array_ptr_alloc_tsz {a} (n, sizeof) prval () = free_gc_elim {a?} (pf2_gc) val () = array_ptr_copy_tsz (!p1, !p2, n, sizeof) val B = array_make_view_ptr {a} (pf2_arr | p2) } // end of [array_copy] (* ****** ****** *) datatype trace = TRACE of (int(*lb*), int(*ub*)) typedef tracelst = List (trace) fun bsearch {n:nat} ( A: array (int, n), n: size_t n, x0: int ) : tracelst = let fun aux {i:nat;j:int | i <= j+1; j+1 <= n} .. (lb: int i, ub: int j): tracelst = let val tr = TRACE (lb, ub) val trs = (if lb <= ub then let val m = (lb + ub) / 2 val x = A[m] in if x0 <= x then aux (lb, m-1) else aux (m+1, ub) end else begin list_nil () end) : tracelst (* end of [if] *) in list_cons (tr, trs) end // end of [aux] val n = int1_of_size1 (n) in aux (0, n-1) end // end of [bsearch] (* ****** ****** *) #define N 100 (* ****** ****** *) staload "libc/SATS/random.sats" staload "libc/SATS/stdlib.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "prelude/DATS/list.dats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) val () = srand48_with_time () #define ASZ 20 val key0 = randint (N) val A0: array (int, ASZ) = let val (pf_gc, pf_arr | p_arr) = array_ptr_alloc (ASZ) val () = array_ptr_initialize_fun ( !p_arr, ASZ, lam (_, x) = x := $effmask_ref (randint (N)) ) // end of [val] val () = qsort {int} (!p_arr, ASZ, sizeof, lam (x1, x2) => compare (x1, x2)) prval () = free_gc_elim {int?} (pf_gc) in array_make_view_ptr (pf_arr | p_arr) end // end of [val] val theTracelst = bsearch (A0, ASZ, key0) (* val () = ( print "length of [theTracelst] = "; print (list_length theTracelst); print_newline () ) // end of [val] *) val theTracelstRef = ref (list_nil) (* ****** ****** *) fn update_theTracelstRef (): bool = let val trs = !theTracelstRef in case+ trs of | list_cons (tr, trs) => (!theTracelstRef := trs; true) | _ => false end // end of [update_theTracelstRef] (* ****** ****** *) extern fun draw_trace {l:agz} (cr: !cairo_ref l, w: double, h: double, n: int, tr: trace): void // end of [draw_trace] implement draw_trace (cr, w, h, n, tr) = let val TRACE (lb, ub) = tr val nw = w / n and nh = h / n // val x = lb * nw + nw / 2 and y = nh / 2 val () = cairo_move_to (cr, ~w/2+x, y) val () = cairo_rel_line_to (cr, ~nw/6, nh/3) val () = cairo_rel_line_to (cr, nw/3, 0.0) val () = cairo_close_path (cr) val () = cairo_fill (cr) // val x = ub * nw + nw / 2 and y = ~nh / 2 val () = cairo_move_to (cr, ~w/2+x, y) val () = cairo_rel_line_to (cr, ~nw/6, ~nh/3) val () = cairo_rel_line_to (cr, nw/3, 0.0) val () = cairo_close_path (cr) val () = cairo_fill (cr) // val () = if lb <= ub then let val m = (lb+ub) / 2 val x = ~w/2+m*nw and y = ~nh/2 val () = cairo_rectangle (cr, x, y, nw, nh) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 0.0) // yellow val () = cairo_fill (cr) // val m = int1_of_int (m) val () = assert (m >= 0 && m < ASZ) val m = size1_of_int1 (m) val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, x + nw/2, 0.0) val () = cairo_set_source_rgb (cr, 0.25, 0.25, 0.25) val txt = sprintf ("%2.2i", @(A0[m])) val () = cairo_show_text_inbox (cr, nw, nh, $UN.castvwtp1{string} (txt)) val () = strptr_free (txt) val () = cairo_restore (pf | cr) in // nothing end // end of [val] // in // nothing end // end of [draw_trace] extern fun draw_main {l:agz} (cr: !cairo_ref l, width: int, height: int): void implement draw_main (cr, width, height) = () where { val n = ASZ val w0 = double_of (width) val w = n*w0/(n+2) val h = double_of (height) val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, w0/2, h/3) // val txt = sprintf ("searching for key = %i", @(key0)) val () = cairo_show_text_inbox (cr, w0/2, 2*h/3, $UN.castvwtp1{string} (txt)) val () = strptr_free (txt) // val () = cairo_restore (pf | cr) val (pf | ()) = cairo_save (cr) val () = cairo_translate (cr, w0/2, h/2) val () = draw_intarray (cr, w, h/n, A0, n) val trs = !theTracelstRef val () = ( case+ trs of | list_cons (tr, _) => let val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) in draw_trace (cr, w, h, n, tr) end // end of [list_cons] | list_nil () => () ) : void // end of [val] val () = cairo_restore (pf | cr) } // end of [draw_main] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" (* ****** ****** *) %{^ GtkWidget *the_drawingarea = NULL; ats_ptr_type the_drawingarea_get () { if (the_drawingarea == NULL) { fprintf (stderr, "exit(the_drawingarea_get): not initialized yet\n"); exit(1); } // end of [if] return the_drawingarea ; } // end of [the_drawingarea_get] ats_void_type the_drawingarea_initset (ats_ptr_type x) { static int the_drawingarea_initset_flag = 0 ; if (the_drawingarea_initset_flag) { fprintf (stderr, "exit(the_drawingarea_initset): already initialized\n"); exit(1); } // end of [if] the_drawingarea_initset_flag = 1 ; the_drawingarea = x ; return ; } // end of [the_drawingarea_initset] %} // end of [%{^] extern fun the_drawingarea_get (): [l:agz] (gobjref (GtkDrawingArea, l) - void | gobjref (GtkDrawingArea, l)) = "the_drawingarea_get" // end of [the_drawingarea_get] extern fun the_drawingarea_initset (x: GtkDrawingArea_ref1): void = "the_drawingarea_initset" // end of [the_drawingarea_initset] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) fn fnext (): void = let val ans = update_theTracelstRef () val () = if ~ans then !theTracelstRef := theTracelst val (fpf_darea | darea) = the_drawingarea_get () val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = gtk_widget_queue_draw_area (darea, (gint)0, (gint)0, p->width, p->height) prval () = minus_addback (fpf, pf | darea) prval () = fpf_darea (darea) in // nothing end // end of [fnext] (* ****** ****** *) fn fexpose {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l), event: &GdkEvent): gboolean = let prval () = clstrans {c,GtkDrawingArea,GtkWidget} () val (fpf_win | win) = gtk_widget_get_window (darea) val () = assert_errmsg (g_object_isnot_null (win), #LOCATION) val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw_main (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in GFALSE // HX: what does this mean? end // end of [fexpose] (* ****** ****** *) fn ftimeout (_: gpointer): gboolean = let val (fpf_darea | darea) = the_drawingarea_get () val (fpf_win | win) = gtk_widget_get_window (darea) val res = update_theTracelstRef () val () = if res then ( if g_object_isnot_null (win) then let val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = gtk_widget_queue_draw_area (darea, (gint)0, (gint)0, p->width, p->height) prval () = minus_addback (fpf, pf | darea) in // nothing end // end of [if] ) // end of [val] prval () = minus_addback (fpf_win, win | darea) prval () = fpf_darea (darea) in GTRUE end // end of [ftimeout] (* ****** ****** *) macdef gs = gstring_of_string (* ****** ****** *) val theTimeInterval = 1000 extern fun main1 (): void = "main1" implement main1 () = () where { // val () = srand48_with_time () // val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // end of [val] val (fpf_x | x) = (gs)"cairo: binary search" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy", G_CALLBACK (gtk_main_quit), (gpointer)null) // val vbox0 = gtk_vbox_new (GFALSE(*homo*), (gint)10(*spacing*)) val () = gtk_container_add (window, vbox0) // val hbox1 = gtk_hbox_new (GFALSE, (gint)0) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hbox1) // val darea = gtk_drawing_area_new () val () = gtk_box_pack_start (vbox0, darea, GTRUE, GTRUE, (guint)0) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (fexpose), (gpointer)null) val () = the_drawingarea_initset (darea) // val hsep = gtk_hseparator_new () val () = gtk_box_pack_start (vbox0, hsep, GFALSE, GFALSE, (guint)0) val () = g_object_unref (hsep) // val hbox1 = gtk_hbox_new (GFALSE(*homo*), (gint)5(*spacing*)) val () = gtk_box_pack_start (vbox0, hbox1, GFALSE, GTRUE, (guint)10) // val (fpf_x | x) = (gs)"_Close" val btn_close = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_close, (gsignal)"clicked", G_CALLBACK(gtk_main_quit), (gpointer_vt)window) // end of [val] val () = gtk_box_pack_end (hbox1, btn_close, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_close) // val (fpf_x | x) = (gs)"_Next" val btn_next = gtk_button_new_with_mnemonic (x) prval () = fpf_x (x) val _sid = g_signal_connect (btn_next, (gsignal)"clicked", G_CALLBACK(fnext), (gpointer)null) // end of [val] val () = gtk_box_pack_end (hbox1, btn_next, GFALSE, GFALSE, (guint)4) val () = g_object_unref (btn_next) (* val _rid = gtk_timeout_add ((guint32)theTimeInterval, ftimeout, (gpointer)null) *) val () = g_object_unref (hbox1) val () = g_object_unref (vbox0) val () = gtk_widget_show_all (window) val () = g_object_unref (window) val () = gtk_main () } // end of [main1] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [bsearch_demo.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/GTK/gtkcairoclock.dats0000664000175000017500000002246612223166161021767 0ustar hwxihwxi(* ** ** A simple GTK/CAIRO example: a clock @ home ** The part of clock drawing is largely taken from ** a cairo example I did in December 2009 ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 ** *) (* ****** ****** *) staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) staload "libc/SATS/math.sats" macdef PI = M_PI macdef PI2 = PI/2 staload "libc/SATS/time.sats" (* ****** ****** *) staload "contrib/cairo/SATS/cairo.sats" (* ****** ****** *) stadef dbl = double stadef cr (l:addr) = cairo_ref l (* ****** ****** *) fn draw_hand {l:agz} (cr: !cr l, bot: dbl, top:dbl, len: dbl): void = let val () = cairo_move_to (cr, 0.0, bot/2) val () = cairo_line_to (cr, len, top/2) val () = cairo_line_to (cr, len, ~top/2) val () = cairo_line_to (cr, 0.0, ~bot/2) val () = cairo_close_path (cr) in cairo_fill (cr) end // end of [draw_hand] (* ****** ****** *) val theLastSec = ref_make_elt (~1) fn draw_clock {l:agz} ( cr: !cr l , h: natLt 24, m: natLt 60, s: natLt 60 // hour and minute ) : void = let // val dim = 100.0 // please scale it! val rad = 0.375 * dim // val h = (if h >= 12 then h - 12 else h): natLt 12 val s_ang = s * (PI / 30) - PI2 // val m_ang = m * (PI / 30) + s * (PI / 1800) - PI2 val m_ang = m * (PI / 30) - PI2 val h_ang = h * (PI / 6) + m * (PI / 360) - PI2 // val () = cairo_arc (cr, 0.0, 0.0, rad, 0.0, 2 * PI) val () = cairo_set_source_rgb (cr, 1.0, 1.0, 1.0) (* val () = cairo_set_source_rgb (cr, 1.0, 0.50, 0.50) *) val () = cairo_fill (cr) val () = cairo_arc (cr, 0.0, 0.0, rad, 0.0, 2 * PI) val () = cairo_set_source_rgb (cr, 0.0, 1.0, 0.0) (* val () = cairo_set_source_rgb (cr, 1.0, 0.0, 1.0) *) val () = cairo_set_line_width (cr, 4.0) val () = cairo_stroke (cr) // val rad1 = 0.90 * rad val () = cairo_arc (cr, ~rad1, ~rad1, rad1, 0.0, PI2) val () = cairo_arc (cr, ~rad1, rad1, rad1, ~PI2, 0.) val () = cairo_arc (cr, rad1, rad1, rad1, ~PI, ~PI2) val () = cairo_arc (cr, rad1, ~rad1, rad1, PI2, PI) val () = cairo_fill (cr) // val h_l = 0.60 * rad val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_rotate (cr, h_ang) val () = draw_hand (cr, 3.0, 1.5, h_l) val () = cairo_restore (pf | cr) val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_rotate (cr, h_ang+PI) val () = draw_hand (cr, 3.0, 1.5, h_l/4) val () = cairo_restore (pf | cr) // val m_l = 0.85 * rad val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_rotate (cr, m_ang) val () = draw_hand (cr, 2.0, 1.0, m_l) val () = cairo_restore (pf | cr) val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_rotate (cr, m_ang+PI) val () = draw_hand (cr, 2.0, 1.0, h_l/4) val () = cairo_restore (pf | cr) // val s_l = 0.85 * rad val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 1.0, 0.0, 0.0) val () = cairo_rotate (cr, s_ang) val () = draw_hand (cr, 1.0, 0.5, m_l) val () = cairo_restore (pf | cr) val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 1.0, 0.0, 0.0) val () = cairo_rotate (cr, s_ang+PI) val () = draw_hand (cr, 1.0, 0.5, h_l/4) val () = cairo_restore (pf | cr) // val (pf | ()) = cairo_save (cr) val () = cairo_set_source_rgb (cr, 0.0, 0.0, 0.0) val () = cairo_new_sub_path (cr) val () = cairo_arc (cr, 0.0, 0.0, 2.5, 0.0, 2 * PI) val () = cairo_fill (cr) val () = cairo_restore (pf | cr) in // nothing end // end of [draw_clock] (* ****** ****** *) extern fun draw_main {l:agz} (cr: !cairo_ref l, width: int, height: int): void implement draw_main (cr, width, height) = () where { val w = (double_of)width val h = (double_of)height val mn = min (w, h) val xc = w / 2 and yc = h / 2 val (pf0 | ()) = cairo_save (cr) val () = cairo_translate (cr, xc, yc) val alpha = mn / 100 val () = cairo_scale (cr, alpha, alpha) // var t: time_t // unintialized val yn = time_get_and_set (t) val () = assert_errmsg (yn, #LOCATION) prval () = opt_unsome {time_t} (t) var tm: tm_struct // unintialized val _ptr = localtime_r (t, tm) val () = assert_errmsg (_ptr > null, #LOCATION) prval () = opt_unsome {tm_struct} (tm) val hr = tm.tm_hour and mt = tm.tm_min and sd = tm.tm_sec val hr = int1_of_int (hr) val () = assert (0 <= hr && hr < 24) val mt = int1_of_int (mt) val () = assert (0 <= mt && mt < 60) val sd = int1_of_int (sd) val () = assert (0 <= sd && sd < 60) val () = draw_clock (cr, hr, mt, sd) // val () = cairo_restore (pf0 | cr) } // end of [draw_main] (* ****** ****** *) staload "contrib/glib/SATS/glib.sats" staload "contrib/glib/SATS/glib-object.sats" (* ****** ****** *) staload "contrib/GTK/SATS/gdk.sats" staload "contrib/GTK/SATS/gtkclassdec.sats" staload "contrib/GTK/SATS/gtk.sats" (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] (* ****** ****** *) %{^ GtkWidget *the_drawingarea = NULL; ats_ptr_type the_drawingarea_get () { if (the_drawingarea == NULL) { fprintf (stderr, "exit(the_drawingarea_get): not initialized yet\n"); exit(1); } // end of [if] return the_drawingarea ; } // end of [the_drawingarea_get] ats_void_type the_drawingarea_initset (ats_ptr_type x) { static int the_drawingarea_initset_flag = 0 ; if (the_drawingarea_initset_flag) { fprintf (stderr, "exit(the_drawingarea_initset): already initialized\n"); exit(1); } // end of [if] the_drawingarea_initset_flag = 1 ; the_drawingarea = x ; return ; } // end of [the_drawingarea_initset] %} // end of [%{^] extern fun the_drawingarea_get (): [l:agz] (gobjref (GtkDrawingArea, l) - void | gobjref (GtkDrawingArea, l)) = "the_drawingarea_get" // end of [the_drawingarea_get] extern fun the_drawingarea_initset (x: GtkDrawingArea_ref1): void = "the_drawingarea_initset" // end of [the_drawingarea_initset] (* ****** ****** *) fun draw_drawingarea {c:cls | c <= GtkDrawingArea} {l:agz} (darea: !gobjref (c, l)): void = let // prval () = clstrans {c,GtkDrawingArea,GtkWidget} () // val (fpf_win | win) = gtk_widget_get_window (darea) in if g_object_isnot_null (win) then let val cr = gdk_cairo_create (win) prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = draw_main (cr, (int_of)p->width, (int_of)p->height) prval () = minus_addback (fpf, pf | darea) val () = cairo_destroy (cr) in // nothing end else let prval () = minus_addback (fpf_win, win | darea) in // nothing end (* end of [if] *) end // end of [draw_drawingarea] (* ****** ****** *) fun fexpose (): gboolean = let val (fpf_darea | darea) = the_drawingarea_get () val _ = draw_drawingarea (darea) prval () = fpf_darea (darea) in GFALSE end // end of [fexpose] (* ****** ****** *) fun sec_changed (): bool = let var t: time_t // unintialized val yn = time_get_and_set (t) val () = assert_errmsg (yn, #LOCATION) prval () = opt_unsome {time_t} (t) var tm: tm_struct // unintialized val _ptr = localtime_r (t, tm) val () = assert_errmsg (_ptr > null, #LOCATION) prval () = opt_unsome {tm_struct} (tm) val sd = tm.tm_sec val sd_old = !theLastSec val () = !theLastSec := sd in sd <> sd_old end // end of [sec_changed] fun ftimeout (_: gpointer): gboolean = let val (fpf_darea | darea) = the_drawingarea_get () val (fpf_win | win) = gtk_widget_get_window (darea) in if g_object_isnot_null (win) then let prval () = minus_addback (fpf_win, win | darea) val (pf, fpf | p) = gtk_widget_getref_allocation (darea) val () = if sec_changed () then gtk_widget_queue_draw_area (darea, (gint)0, (gint)0, p->width, p->height) // end of [val] prval () = minus_addback (fpf, pf | darea) prval () = fpf_darea (darea) in GTRUE end else let prval () = minus_addback (fpf_win, win | darea) prval () = fpf_darea (darea) in GFALSE // HX: terminating the timer end // end of [if] end // end of [ftimeout] (* ****** ****** *) extern fun main1 (): void = "main1" implement main1 () = () where { val window = gtk_window_new (GTK_WINDOW_TOPLEVEL) val () = gtk_window_set_default_size (window, (gint)400, (gint)400) // val (fpf_x | x) = (gstring_of_string)"ATS: gtkcairoclock" val () = gtk_window_set_title (window, x) prval () = fpf_x (x) // val darea = gtk_drawing_area_new () val () = gtk_container_add (window, darea) val _sid = g_signal_connect (darea, (gsignal)"expose-event", G_CALLBACK (fexpose), (gpointer)null) val () = the_drawingarea_initset (darea) val _sid = g_signal_connect (window, (gsignal)"delete-event", G_CALLBACK (gtk_main_quit), (gpointer)null) val _sid = g_signal_connect (window, (gsignal)"destroy-event", G_CALLBACK (gtk_widget_destroy), (gpointer)null) // val _rid = gtk_timeout_add ((guint32)100U, ftimeout, (gpointer)null) val () = gtk_widget_show_all (window) val () = g_object_unref (window) val () = gtk_main () } // end of [main1] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { gtk_init ((int*)&argc, (char***)&argv) ; main1 () ; return ; } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [gtkcairolock.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/0000700000175000017500000000000012223166161016744 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glLightMove2.dats0000664000175000017500000000762712223166161022154 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/reference.dats" val spin_x = ref_make_elt (0) val spin_y = ref_make_elt (0) (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_SMOOTH) val () = glEnable (GL_LIGHTING) val () = glEnable (GL_LIGHT0) val () = glEnable (GL_DEPTH_TEST) in // empty end // end of [initialize] extern fun display (): void = "display" implement display () = let #define x_pos 0.0 #define y_pos 0.0 #define z_pos 0.0 #define w_pos 1.0 var !p_pos with pf1 = @[float](x_pos, y_pos, z_pos, w_pos) var !p_light with pf2 = @[float](0.0, 0.0, 1.0, 1.0) val () = glClear (GL_COLOR_BUFFER_BIT lor GL_DEPTH_BUFFER_BIT) // extern fun glLightfv {n:nat} {l:addr} (pf: !array_v (float, n, l) | light: GLenum, pname: GLenum, p: ptr l): void = "mac#atsctrb_glLightfv" // val () = glLightfv (pf1 | GL_LIGHT0, GL_POSITION, p_pos) val () = glLightfv (pf2 | GL_LIGHT0, GL_DIFFUSE, p_light) val () = glLightfv (pf2 | GL_LIGHT0, GL_SPECULAR, p_light) val () = glEnable (GL_LIGHTING) val (pf1_push | ()) = glPushMatrix () val () = glTranslated (0.0, 0.0, ~5.0) val () = glRotated (double_of !spin_x, 1.0, 0.0, 0.0) val () = glRotated (double_of !spin_y, 0.0, 1.0, 0.0) (* val () = glutWireCube ((GLdouble)1.0) val () = glutSolidCube ((GLdouble)1.0) *) (* val () = glutWireSphere (1.0, 32, 60) val () = glutSolidSphere (1.0, 32, 60) *) (* val () = glutWireTorus ((GLdouble)0.50, (GLdouble)1.0, (GLint)16, (GLint)30) val () = glutSolidTorus ((GLdouble)0.50, (GLdouble)1.0, (GLint)16, (GLint)30) *) (* val () = glutWireTeapot ((GLdouble)1.0) *) val () = glutSolidTeapot ((GLdouble)1.0) val () = glPopMatrix (pf1_push | (*none*)) val () = glFlush () in // empty end // end of [display] extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val w_h = (double_of w) / (double_of h) val () = gluPerspective (40.0, w_h, 1.0, 20.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in // empty end // end of [reshape] (* ****** ****** *) macdef int = int_of_GLenum extern fun mouse (button: int, state: int, x: int, y: int): void = "mouse" implement mouse (button, state, x, y) = begin case+ 0 of | _ when (button = (int)GLUT_LEFT_BUTTON) => begin if (state = (int)GLUT_DOWN) then begin !spin_x := (!spin_x + 30) mod 360; glutPostRedisplay () end end // end of [_ when ...] | _ when (button = (int)GLUT_RIGHT_BUTTON) => begin if (state = (int)GLUT_DOWN) then begin !spin_y := (!spin_y + 30) mod 360; glutPostRedisplay () end end // end of [_ when ...] | _ => () end // end of [mouse] (* ****** ****** *) extern fun main_work (): void = "main_work" implement main_work () = let val () = initialize () val () = glutDisplayFunc (display) val () = glutReshapeFunc (reshape) val () = glutMouseFunc (mouse) in glutMainLoop () end // end of [main_work] (* ****** ****** *) implement main_dummy () = () %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; main_work () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glLightMove1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glLightMove1.dats0000664000175000017500000000737312223166161022151 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/reference.dats" val spin = ref_make_elt (0) (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_SMOOTH) val () = glEnable (GL_LIGHTING) val () = glEnable (GL_LIGHT0) val () = glEnable (GL_DEPTH_TEST) in // empty end // end of [initialize] extern fun display (): void = "display" implement display () = let #define x_pos 0.0 #define y_pos 0.0 #define z_pos 1.5 #define w_pos 1.0 var !p_pos with pf_pos = @[float](x_pos, y_pos, z_pos, w_pos) val () = glClear (GL_COLOR_BUFFER_BIT lor GL_DEPTH_BUFFER_BIT) val (pf1_push | ()) = glPushMatrix () val () = glTranslated (0.0, 0.0, ~5.0) val (pf2_push | ()) = glPushMatrix () val () = glRotated (double_of !spin, 0.0, 1.0, 0.0) extern fun glLightfv {n:nat} {l:addr} (pf: !array_v (float, n, l) | light: GLenum, pname: GLenum, p: ptr l): void = "mac#atsctrb_glLightfv" val () = glLightfv (pf_pos | GL_LIGHT0, GL_POSITION, p_pos) val () = glTranslated (x_pos, y_pos, z_pos) val () = glDisable (GL_LIGHTING) val () = glColor3d (0.0, 1.0, 1.0) val () = glutWireCube ((GLdouble)0.1) val () = glEnable (GL_LIGHTING) val () = glPopMatrix (pf2_push | (*none*)) (* val () = glutWireCube ((GLdouble)1.0) val () = glutSolidCube ((GLdouble)1.0) *) (* val () = glutWireSphere ((GLdouble)1.0, (GLint)32, (GLint)60) val () = glutSolidSphere ((GLdouble)1.0, (GLint)32, (GLint)60) *) (* val () = glutWireTorus ((GLdouble)0.50, (GLdouble)1.0, (GLint)16, (GLint)30) val () = glutSolidTorus ((GLdouble)0.50, (GLdouble)1.0, (GLint)16, (GLint)30) *) (* val () = glutWireTeapot ((GLdouble)1.0) *) val () = glutSolidTeapot ((GLdouble)1.0) val () = glPopMatrix (pf1_push | (*none*)) val () = glFlush () in // empty end // end of [display] extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val w_h = (double_of w) / (double_of h) val () = gluPerspective ((GLdouble)40.0, (GLdouble)w_h, (GLdouble)1.0, (GLdouble)20.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in // empty end // end of [reshape] (* ****** ****** *) macdef int = int_of_GLenum extern fun mouse (button: int, state: int, x: int, y: int): void = "mouse" implement mouse (button, state, x, y) = begin case+ 0 of | _ when (button = (int)GLUT_LEFT_BUTTON) => begin if (state = (int)GLUT_DOWN) then begin !spin := (!spin + 30) mod 360; glutPostRedisplay () end end // end of [_ when ...] | _ => () end // end of [mouse] (* ****** ****** *) extern fun main_work (): void = "main_work" implement main_work () = let val () = initialize () val () = glutDisplayFunc (display) val () = glutReshapeFunc (reshape) val () = glutMouseFunc (mouse) in glutMainLoop () end // end of [main_work] (* ****** ****** *) implement main_dummy () = () %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; main_work () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glLightMove1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glColoredTriangle.dats0000664000175000017500000000423312223166161023237 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_SMOOTH) in // empty end // end of [initialize] fn drawTriangle (): void = let val (pf | ()) = glBegin (GL_TRIANGLES) val () = glColor3d (1.0, 0.0, 0.0) val () = glVertex2d (5.0, 5.0) val () = glColor3d (0.0, 1.0, 0.0) val () = glVertex2d (25.0, 5.0) val () = glColor3d (0.0, 0.0, 1.0) val () = glVertex2d (5.0, 25.0) val () = glEnd (pf | (*none*)) in // empty end extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = drawTriangle () val () = glFlush () in // empty end local typedef GLdouble = double in extern fun gluOrtho2D (_: double, _: double, _: double, _: double): void = "gluOrtho2D" end extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = case+ 0 of | _ when h <= w => gluOrtho2D (0.0, 30.0, 0.0, 30.0 * (double_of w) / (double_of h)) | _ (* w < h *) => gluOrtho2D (0.0, 30.0 * (double_of w) / (double_of h), 0.0, 30.0) val () = glMatrixMode (GL_MODELVIEW) in // empty end // end of [reshape] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutMainLoop () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glColoredTriangle.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glTetrix.dats0000664000175000017500000010514712223166161021447 0ustar hwxihwxi(* ** ** A simple implementation of the tetrix game ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2009 ** *) (* ****** ****** *) // // Usage: // // 'i' : counterclockwise rotation // 'k' : clockwise rotation // 'j' : horizontal move to the left // 'l' : horizontal move to the right // ' ' : free fall // // 'n' : show/hide the next piece // 'a' : acceleration // 'd' : deceleration // // ESC : exit // (* ****** ****** *) staload "libc/SATS/random.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/matrix.dats" staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) %{^ static ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) // flag = 1/0: show/hide the current shape extern fun glTetrix_display_main (flag: int): void extern fun glTetrix_display (): void = "glTetrix_display" extern fun glTetrix_finalize (): void extern fun glTetrix_initialize (): void = "glTetrix_initialize" (* ****** ****** *) fn drawRectangle (x0: double, y0: double, wd: double, ht: double) : void = let val (pf_begin | ()) = glBegin (GL_POLYGON) val () = glVertex3d (x0 , y0 , 0.0) val () = glVertex3d (x0 + wd, y0 , 0.0) val () = glVertex3d (x0 + wd, y0 + ht, 0.0) val () = glVertex3d (x0 , y0 + ht, 0.0) val () = glEnd (pf_begin | (*none*)) in // empty end // end of [drawRectangle] (* ****** ****** *) #define FRAME_X 12 #define FRAME_Y 24 #define FRAME_MARGIN 4 val FRAME_MAX = let var max: int = FRAME_X val () = if (max < FRAME_Y) then (max := FRAME_Y) in max + FRAME_MARGIN end // end of [FRAME_MAX] val FRAME_unit = 1.0 / double_of_int (FRAME_MAX) val FRAME_wd = FRAME_X * FRAME_unit val FRAME_ht = FRAME_Y * FRAME_unit val FRAME_xbase = (1.0 - FRAME_wd) / 2 and FRAME_ybase= (1.0 - FRAME_ht) / 2 (* ****** ****** *) // a color is really just an index abst@ype color_t = $extype "ats_int_type" extern typedef "color_t" = color_t extern fun color_index_get (c: color_t): int = "color_index_get" extern fun color_is_none (c: color_t): bool // there is no color = "color_is_none" extern fun color_is_some (c: color_t): bool // there is some color = "color_is_some" macdef NONE_color = $extval (color_t, "-1") macdef FRAME_background_color = $extval (color_t, "0") macdef SHAPE0_color = $extval (color_t, "1") macdef SHAPE1_color = $extval (color_t, "2") macdef SHAPE2_color = $extval (color_t, "3") macdef SHAPE3_color = $extval (color_t, "4") macdef SHAPE4_color = $extval (color_t, "5") macdef SHAPE5_color = $extval (color_t, "6") macdef SHAPE6_color = $extval (color_t, "7") extern fun eq_color_color (c1: color_t, c2: color_t): bool = "eq_color_color" overload = with eq_color_color extern fun neq_color_color (c1: color_t, c2: color_t): bool = "neq_color_color" overload <> with neq_color_color (* ****** ****** *) abstype shape_t (m: int, n: int) typedef shape0 = [m,n:nat] shape_t (m, n) extern fun shape_make {m,n:nat} (xlen: int m, ylen: int n, mat: matrix (color_t, m, n), pts: int): shape_t (m, n) extern fun shape_xlen_get {m,n:nat} (S: shape_t (m, n)): int m extern fun shape_ylen_get {m,n:nat} (S: shape_t (m, n)): int n extern fun shape_matrix_get {m,n:nat} (S: shape_t (m, n)): matrix (color_t, m, n) extern fun shape_points_get (S: shape0): int (* ****** ****** *) typedef rotkind = natLt 4 extern typedef "rotkind_t" = rotkind #define ROTKIND_000 0 #define ROTKIND_090 1 #define ROTKIND_180 2 #define ROTKIND_270 3 extern fun the_rotkind_get (): rotkind = "the_rotkind_get" extern fun the_rotkind_set (rk: rotkind): void = "the_rotkind_set" // flag = 1: draw; flag = 0: undraw extern fun shape_draw_atrot (flag: int, S: shape0, ix_center: int, iy_center: int, rk: rotkind): void (* ****** ****** *) #define NSHAPE 7 extern val theShapeArray : array (shape0, NSHAPE) extern val theShapeColorArray : array (color_t, NSHAPE) (* ****** ****** *) extern val theNextShapeRef : ref (shape0) extern val theCurrentShapeRef : ref (shape0) (* ****** ****** *) extern fun theNextShapeShow_get (): int extern fun theNextShapeShow_toggle (): void local val toggle = ref_make_elt (1) // it is on by default in implement theNextShapeShow_get () = !toggle implement theNextShapeShow_toggle () = (!toggle := 1 - !toggle) end // end of [local] (* ****** ****** *) extern fun theGameOver_get (): bool extern fun theGameOver_set (): void extern fun theGameLevel_get (): int extern fun theTimerTimeInterval_get (): uint extern fun theTimerTimeInterval_inc (): void extern fun theTimerTimeInterval_dec (): void local val theGameOver = ref_make_elt (false) val level = ref_make_elt (1) val interval = ref_make_elt (1000.0) in implement theGameOver_get () = !theGameOver implement theGameOver_set () = !theGameOver := true implement theGameLevel_get () = !level implement theTimerTimeInterval_get () = let val ti = !interval in uint_of_double ti end // end of [theTimerTimeInterval_get] implement theTimerTimeInterval_inc () = let val ti: double = 1.25 * !interval in if ti <= 1000.0 then begin !interval := ti; !level := !level - 1 end end // end of [theTimerTimeInterval_inc] implement theTimerTimeInterval_dec () = let val ti: double = !interval / 1.25 in if ti >= 20.0 then begin !interval := ti; !level := !level + 1 end end // end of [theTimerTimeInterval_dec] end // end of [local] (* ****** ****** *) extern fun theTotalScore_get (): int extern fun theTotalScore_incby (pts: int): void local #define ACCTHRESHOLD 1000 val theTotalScoreRef = ref_make_elt (0) in implement theTotalScore_get () = !theTotalScoreRef implement theTotalScore_incby (pts) = let val score = !theTotalScoreRef; val score_new = score + pts val () = let val level = theGameLevel_get () in if score_new > ACCTHRESHOLD * level then begin theTimerTimeInterval_dec () // acceleration by decreasing the time interval end // end of [if] end // end of [val] in !theTotalScoreRef := score_new end // end of [theTotalScore_incby] end // end of [local] (* ****** ****** *) fn FRAME_glClear (): void = glClear (GL_COLOR_BUFFER_BIT) fn FRAME_glColor3d (): void = glColor3d (0.0, 0.0, 0.0) // black val FRAME_matrix: matrix (color_t, FRAME_X, FRAME_Y) = matrix_make_elt (FRAME_X, FRAME_Y, NONE_color) extern fun FRAME_row_flash (j0: natLt FRAME_Y): void implement FRAME_row_flash (j0: natLt FRAME_Y) = let #define _X FRAME_X; #define _Y FRAME_Y // array allocation in the stack frame var !p_arr with pf_arr = @[color_t][_X](NONE_color) fn restore (arr: &(@[color_t][_X])): void = let var i: natLte _X // uninitialized in for (i := 0; i < _X; i := i+1) FRAME_matrix[i,_Y,j0] := arr.[i] end // end of [restore] fn disappear (arr: &(@[color_t][_X])): void = let var i: natLte _X // uninitialized in for (i := 0; i < _X; i := i+1) FRAME_matrix[i,_Y,j0] := NONE_color end // end of [disappear] val () = save (!p_arr) where { fn save (arr: &(@[color_t][_X])): void = let var i: natLte _X // uninitialized in for (i := 0; i < _X; i := i+1) arr.[i] := FRAME_matrix[i,_Y,j0] end // end of [save] } // end of [val] var n: int = 6 // flash six times in while (n > 0) let val () = n := n - 1 val () = disappear (!p_arr) val () = glTetrix_display_main (0) // theCurrentShape is aborbed! val _(*err*) = usleep (25000) val () = restore (!p_arr) val () = glTetrix_display_main (0) // theCurrentShape is aborbed! val _(*err*) = usleep (25000) in // empty end // end of [while] end // end of [FRAME_row_flash] extern fun FRAME_row_remove (j0: natLt FRAME_Y): void = "FRAME_row_remove" implement FRAME_row_remove (j0) = let fn remove_one (j: natLt (FRAME_Y - 1)): void = let var i: natLte (FRAME_X) // unintialized in for (i := 0; i < FRAME_X; i := i+1) FRAME_matrix[i,FRAME_Y,j] := FRAME_matrix[i,FRAME_Y,j+1] end // end of [remove_one] fn remove_last () = let var i: natLte (FRAME_X) // unintialized in for (i := 0; i < FRAME_X; i := i+1) FRAME_matrix[i,FRAME_Y,FRAME_Y-1] := NONE_color end // end of [remove_last] var j: natLte (FRAME_Y) val () = for (j := j0; j < FRAME_Y - 1; j := j + 1) remove_one (j) val () = remove_last () in // empty end // end of [FRAME_row_remove] (* ****** ****** *) #define POINTS_FOR_FILLED_ROW 100 extern fun FRAME_rows_remove_if (): void = "FRAME_rows_remove_if" implement FRAME_rows_remove_if () = let fn test (j: natLt FRAME_Y): bool = let var ans: bool = true var i: Nat // uninitialized val () = for (i := 0; i < FRAME_X; i := i+1) let val c = FRAME_matrix[i, FRAME_Y, j] in if color_is_none c then (ans := false; break) else () end // end of [val] in ans end // end of [test] var j: Nat = 0 in while (j < FRAME_Y) ( if test (j) then let val () = theTotalScore_incby (POINTS_FOR_FILLED_ROW) in FRAME_row_flash (j); FRAME_row_remove (j) end else (j := j+1) ) // end of [while] end // end of [FRAME_rows_remove] (* ****** ****** *) extern fun the_ix_center_get (): int = "the_ix_center_get" extern fun the_ix_center_set (x: int): void = "the_ix_center_set" extern fun the_iy_center_get (): int = "the_iy_center_get" extern fun the_iy_center_set (y: int): void = "the_iy_center_set" (* ****** ****** *) staload "libc/SATS/math.sats" fn drawArc {n:int | n >= 1} ( pf: !glBegin_v | x0: double, y0: double , radius: double, ang_init: double, ang_delta: double , n: int n ) : void = let val theta = (ang_delta / n) fun loop {i:nat | i <= n} (i: int i, theta_i: double): void = let val () = glVertex3d (x0 + radius * cos (theta_i), y0 + radius * sin (theta_i), 0.0) in if i < n then loop (i + 1, theta_i + theta) end // end of [loop] val () = loop (0, ang_init) in // empty end // end of [drawArc] #define PI 3.1415926535898 // a plain vanilla version fn drawBlock (ix: int, iy: int): void = let #define NARC 8 #define NCORNER 3 val u = FRAME_unit val u_N0 = u / NCORNER val u_N1 = u - u_N0 val x0 = ix * u and y0 = iy * u val (pf_begin | ()) = glBegin (GL_POLYGON) (* // kind of funky looking val () = drawArc (pf_begin | x0 + u_N0, y0 + u_N0, u_N0, ~PI , ~PI/2, NARC) val () = drawArc (pf_begin | x0 + u_N1, y0 + u_N0, u_N0, ~PI/2, 0.0 , NARC) val () = drawArc (pf_begin | x0 + u_N1, y0 + u_N1, u_N0, 0.0 , PI/2, NARC) val () = drawArc (pf_begin | x0 + u_N0, y0 + u_N1, u_N0, PI/2, PI , NARC) *) val () = drawArc (pf_begin | x0 + u_N0, y0 + u_N0, u_N0, ~PI , PI/2, NARC) val () = drawArc (pf_begin | x0 + u_N1, y0 + u_N0, u_N0, ~PI/2, PI/2, NARC) val () = drawArc (pf_begin | x0 + u_N1, y0 + u_N1, u_N0, 0.0 , PI/2, NARC) val () = drawArc (pf_begin | x0 + u_N0, y0 + u_N1, u_N0, PI/2, PI/2, NARC) val () = glEnd (pf_begin | (*none*)) in // empty end // end of [drawBlock] // a placeholder fn glColor3d_color (c: color_t): void = let val index = color_index_get (c) in case+ index of | 1(*SHAPE0*) => glColor3d (1.0, 0.0, 0.0) // red | 2(*SHAPE1*) => glColor3d (0.0, 1.0, 0.0) // green | 3(*SHAPE2*) => glColor3d (0.5, 0.5, 1.0) // light blue | 4(*SHAPE3*) => glColor3d (1.0, 1.0, 0.0) // yellow | 5(*SHAPE4*) => glColor3d (1.0, 1.0, 0.0) // yellow | 6(*SHAPE3*) => glColor3d (1.0, 0.475, 0.475) // pink? | 7(*SHAPE4*) => glColor3d (1.0, 0.475, 0.475) // pink? | _ => glColor3d (1.0, 1.0, 1.0) end // end of [glColor3d_color] // flag = 1: draw; flag = 0: undraw fn shape_draw (flag: int, S: shape0): void = let fn loop_row {m,n:nat} ( flag: int , mat: matrix (color_t, m, n), m: int m, n: int n, j: natLt n ) : void = let var i: Nat // uninitialize in for (i := 0; i < m; i := i + 1) let val c = mat[i, n, j] in if color_is_some (c) then let val () = begin if flag > 0 then glColor3d_color (c) else FRAME_glColor3d () end // end of [val] val () = drawBlock (i, j) in // empty end // end of [if] end // end of [for] end // end of [loop_row] stavar m: int and n: int val xlen: int m = shape_xlen_get (S) val ylen: int n = shape_ylen_get (S) val mat = shape_matrix_get (S) var j: Nat // uninitialized in for (j := 0; j < ylen; j := j + 1) loop_row (flag, mat, xlen, ylen, j) end // end of [shape_draw] (* ****** ****** *) implement shape_draw_atrot (flag, S, ix_center, iy_center, rk) = let val xlen = shape_xlen_get S val ylen = shape_ylen_get S val (pf_matrix | ()) = glPushMatrix () val u = FRAME_unit val () = glTranslated (FRAME_xbase, FRAME_ybase, 0.0) val () = glTranslated (ix_center * u, iy_center * u, 0.0) val () = case+ rk of | ROTKIND_000 => () | ROTKIND_090 => glRotated (90.0, 0.0, 0.0, 1.0) | ROTKIND_180 => glRotated (180.0, 0.0, 0.0, 1.0) | ROTKIND_270 => glRotated (270.0, 0.0, 0.0, 1.0) // end of [val] val xlen2 = xlen / 2 and ylen2 = ylen / 2 val () = glTranslated (~xlen2 * u, ~ylen2 * u, 0.0) val () = shape_draw (flag, S) val () = glPopMatrix (pf_matrix | (*none*)) in // empty end // end of [shape_draw_atrot] (* ****** ****** *) extern fun shape_absorb_atrot ( flag: int, S: shape0, ix_center: int, iy_center: int, rk: rotkind ) : int // end of [shape_absorb_atrot] implement shape_absorb_atrot (flag, S, ix_center, iy_center, rk) = let stavar m: int and n: int val xlen: int m = shape_xlen_get (S) and ylen: int n = shape_ylen_get (S) val xlen2 = xlen / 2 and ylen2 = ylen / 2 val mat = shape_matrix_get (S) fn action ( c: color_t , frame_i: natLt FRAME_X, frame_j: natLt FRAME_Y , ans: &int ) : void = if flag > 0 then begin FRAME_matrix[frame_i, FRAME_Y, frame_j] := c end else let val c0 = FRAME_matrix[frame_i, FRAME_Y, frame_j] in if color_is_some (c0) then (ans := 1) else () end // end of [if] // end of [action] in case+ rk of | ROTKIND_000 => loop1 (0) where { val ix_base: int = ix_center - xlen2 and iy_base: int = iy_center - ylen2 fn* loop1 (i: natLte m): int = if i < xlen then loop2 (i, 0) else 0 and loop2 (i: natLt m, j: natLte n): int = let var ans: int = 0 in if j < ylen then let val c = mat[i, ylen, j] val () = if color_is_some c then let val frame_i = int1_of_int (ix_base + i) val () = assert (0 <= frame_i) val () = assert (frame_i < FRAME_X) val frame_j = int1_of_int (iy_base + j) val () = assert (0 <= frame_j) val () = assert (frame_j < FRAME_Y) in action (c, frame_i, frame_j, ans) end // end of [if] in if ans = 0 then loop2 (i, j+1) else ans end else begin loop1 (i + 1) end // end of [if] end // end of [loop2] } // end of [ROTKIND_000] | ROTKIND_090 => loop1 (0) where { val ix_base: int = ix_center + ylen2 and iy_base: int = iy_center - xlen2 fn* loop1 (i: natLte m): int = if i < xlen then loop2 (i, 0) else 0 and loop2 (i: natLt m, j: natLte n): int = let var ans: int = 0 in if j < ylen then let val c = mat[i, ylen, j] val () = if color_is_some c then let val frame_i = int1_of_int (ix_base - j - 1) val () = assert (0 <= frame_i) val () = assert (frame_i < FRAME_X) val frame_j = int1_of_int (iy_base + i) val () = assert (0 <= frame_j) val () = assert (frame_j < FRAME_Y) in action (c, frame_i, frame_j, ans) end // end of [if] in if ans = 0 then loop2 (i, j+1) else ans end else begin loop1 (i + 1) end // end of [if] end // end of [loop2] } // end of [ROTKIND_090] | ROTKIND_180 => loop1 (0) where { val ix_base: int = ix_center + xlen2 and iy_base: int = iy_center + ylen2 fn* loop1 (i: natLte m): int = if i < xlen then loop2 (i, 0) else 0 and loop2 (i: natLt m, j: natLte n): int = let var ans: int = 0 in if j < ylen then let val c = mat[i, ylen, j] val () = if color_is_some c then let val frame_i = int1_of_int (ix_base - i - 1) val () = assert (0 <= frame_i) val () = assert (frame_i < FRAME_X) val frame_j = int1_of_int (iy_base - j - 1) val () = assert (0 <= frame_j) val () = assert (frame_j < FRAME_Y) in action (c, frame_i, frame_j, ans) end // end of [if] in if ans = 0 then loop2 (i, j+1) else ans end else begin loop1 (i + 1) end // end of [if] end // end of [loop2] } // end of [ROTKIND_180] | ROTKIND_270 => loop1 (0) where { val ix_base: int = ix_center - ylen2 and iy_base: int = iy_center + xlen2 fn* loop1 (i: natLte m): int = if i < xlen then loop2 (i, 0) else 0 and loop2 (i: natLt m, j: natLte n): int = let var ans: int = 0 in if j < ylen then let val c = mat[i, ylen, j] val () = if color_is_some c then let val frame_i = int1_of_int (ix_base + j) val () = assert (0 <= frame_i) val () = assert (frame_i < FRAME_X) val frame_j = int1_of_int (iy_base - i - 1) val () = assert (0 <= frame_j) val () = assert (frame_j < FRAME_Y) in action (c, frame_i, frame_j, ans) end // end of [if] in if ans = 0 then loop2 (i, j+1) else ans end else begin loop1 (i + 1) end // end of [if] end // end of [loop2] } // end of [ROTKIND_270] end // end of [shape_absorb_atrot] (* ****** ****** *) extern fun shape_position_test ( S: shape0, ix_center: int, iy_center: int, rk: rotkind ) : bool // end of [shape_position_test] implement shape_position_test ( S, ix_center, iy_center, rk ) = let val xlen = shape_xlen_get S and ylen = shape_ylen_get S val xlen20 = xlen / 2 and ylen20 = ylen / 2 val xlen21 = xlen - xlen20 and ylen21 = ylen - ylen20 var ix_ll: int = 0 and iy_ll: int = 0 var ix_ur: int = 0 and iy_ur: int = 0 val () = case+ rk of | ROTKIND_000 => begin ix_ll := ix_center - xlen20; iy_ll := iy_center - ylen20; ix_ur := ix_center + xlen21; iy_ur := iy_center + ylen21; end // end of [ROTKIND_000] | ROTKIND_090 => begin ix_ll := ix_center - ylen21; iy_ll := iy_center - xlen20; ix_ur := ix_center + ylen20; iy_ur := iy_center + xlen21; end // end of [ROTKIND_000] | ROTKIND_180 => begin ix_ll := ix_center - xlen21; iy_ll := iy_center - ylen21; ix_ur := ix_center + xlen20; iy_ur := iy_center + ylen20; end // end of [ROTKIND_000] | ROTKIND_270 => begin ix_ll := ix_center - ylen20; iy_ll := iy_center - xlen21; ix_ur := ix_center + ylen21; iy_ur := iy_center + xlen20; end // end of [ROTKIND_000] // end of [val] in if ix_ll < 0 then false else if iy_ll < 0 then false else if ix_ur > FRAME_X then false else if iy_ur > FRAME_Y then false else let val ans = shape_absorb_atrot (0(*flag*), S, ix_center, iy_center, rk) in if ans > 0 then false (*collision*) else true (*no collision*) end // end of [if] end // end of [shape_position_test] (* ****** ****** *) extern fun theCurrentShape_absorb (): void implement theCurrentShape_absorb () = let val S = !theCurrentShapeRef val ix_center = the_ix_center_get () and iy_center = the_iy_center_get () val rk = the_rotkind_get () val _(*0*) = shape_absorb_atrot (1(*flag*), S, ix_center, iy_center, rk) val () = theTotalScore_incby (shape_points_get S) val () = FRAME_rows_remove_if () in // empty end // end of [theCurrentShape_absorb] (* ****** ****** *) extern fun theCurrentShape_update (): void implement theCurrentShape_update () = let val S = !theNextShapeRef val () = !theCurrentShapeRef := S val ylen = shape_ylen_get S val rk_init = ROTKIND_000 val ix_center = (FRAME_X / 2) val iy_center = FRAME_Y - (ylen + 1) / 2 val () = let // collision test val ans = shape_absorb_atrot (0(*flag*), S, ix_center, iy_center, rk_init) in if ans > 0 then // there is collision glTetrix_finalize () // the game is over // end of [if] end // end of [val] val () = the_ix_center_set (ix_center) val () = the_iy_center_set (iy_center) val () = the_rotkind_set (rk_init) val n = randint (NSHAPE) val S = array_get_elt_at (theShapeArray, size1_of_int1 n) val () = !theNextShapeRef := S in // empty end // end of [theCurrentShape_update ()] (* ****** ****** *) extern fun theCurrentShape_xmove_if (delta: int): int = "theCurrentShape_xmove_if" implement theCurrentShape_xmove_if (delta) = let val S = !theCurrentShapeRef val ix_center = the_ix_center_get () and iy_center = the_iy_center_get () val rk = the_rotkind_get () val ix_center_new = ix_center + delta val test = shape_position_test (S, ix_center_new, iy_center, rk) in if test then (the_ix_center_set (ix_center_new); delta) else 0 end // end of [theCurrentShape_xmove_if] (* ****** ****** *) extern fun theCurrentShape_ymove_if (delta: int): int = "theCurrentShape_ymove_if" implement theCurrentShape_ymove_if (delta) = let val S = !theCurrentShapeRef val ix_center = the_ix_center_get () and iy_center = the_iy_center_get () val rk = the_rotkind_get () val iy_center_new = iy_center + delta val test = shape_position_test (S, ix_center, iy_center_new, rk) in if test then begin the_iy_center_set (iy_center_new); delta end else begin 0 // [0] indicates that no move is made end // end of [if] end // end of [theCurrentShape_ymove_if] extern fun theCurrentShape_freefall (): void = "theCurrentShape_freefall" implement theCurrentShape_freefall (): void = let #define FreeFallTimeInterval 2048 fun loop (S: shape0): void = let val _(*err*) = usleep (FreeFallTimeInterval) val res = theCurrentShape_ymove_if (~1) in if res <> 0 then let val () = glTetrix_display_main (1) in loop (S) end else let val () = theCurrentShape_absorb () val () = theCurrentShape_update () in // empty end // end of [if] end // end of [loop] in loop (!theCurrentShapeRef) end // end of [theCurrentShape_freefall] (* ****** ****** *) extern fun theCurrentShape_rotate_if (delta: Nat): int = "theCurrentShape_rotate_if" implement theCurrentShape_rotate_if (delta) = let val S = !theCurrentShapeRef val ix_center = the_ix_center_get () and iy_center = the_iy_center_get () val rk = the_rotkind_get () val rk_new = (rk + delta) nmod1 4 val test = shape_position_test (S, ix_center, iy_center, rk_new) in if test then (the_rotkind_set (rk_new); delta) else 0 end // end of [theCurrentShape_xmove_if] (* ****** ****** *) fn FRAME_draw () = begin drawRectangle (FRAME_xbase, FRAME_ybase, FRAME_wd, FRAME_ht) end // end of [FRAME_draw] fn FRAME_matrix_draw () = let var i: Nat and j: Nat val (pf_matrix | ()) = glPushMatrix () val () = glTranslated (FRAME_xbase, FRAME_ybase, 0.0) val () = for* (j: Nat?) => (i := 0; i < FRAME_X; i := i + 1) begin for* (i: natLt FRAME_X) => (j := 0; j < FRAME_Y; j := j + 1) let val c = FRAME_matrix[i, FRAME_Y, j] in if :(i: natLt FRAME_X) => color_is_some (c) then let val () = glColor3d_color (c); val () = drawBlock (i, j) in // empty end // end of [if] end // end of [for] end // end of [for] val () = glPopMatrix (pf_matrix | (*none*)) in // empty end // end of [FRAME_matrix_draw] implement glTetrix_display_main (flag) = let val () = FRAME_glClear () val () = FRAME_glColor3d () val () = FRAME_draw () val () = FRAME_matrix_draw () val () = if theNextShapeShow_get () > 0 then let val S = !theNextShapeRef val xlen = shape_xlen_get (S) val X = ~2 * ((xlen+1) / 2) val ylen = shape_ylen_get (S) val Y = FRAME_Y - (ylen+1) / 2 in shape_draw_atrot (1(*flag*), S, X, Y, ROTKIND_000) end // end of [if] // end of [val] val () = if flag > 0 then let val S = !theCurrentShapeRef val rotkind = the_rotkind_get () val ix_center = the_ix_center_get () val iy_center = the_iy_center_get () in shape_draw_atrot (1, S, ix_center, iy_center, rotkind) end // end of [val] (* val () = begin prerr "glTetrix_display: ix_center = "; prerr ix_center; prerr_newline () end // end of [val] val () = begin prerr "glTetrix_display: iy_center = "; prerr iy_center; prerr_newline () end // end of [val] *) val () = glFlush () val () = glutSwapBuffers () in // empty end // end of [display] implement glTetrix_display () = glTetrix_display_main (1) // show the current shape (* ****** ****** *) fn FRAME_glClearColor (): void = glClearColor (1.0, 1.0, 1.0, 0.0) // white background implement glTetrix_initialize () = let val () = srand48_with_time () val () = theCurrentShape_update () val () = theCurrentShape_update () // yes, twice! val () = FRAME_glClearColor () val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glOrtho (0.0, 1.0, 0.0, 1.0, ~1.0, 1.0) in // empty end // end of [glTetrix_initialize] (* ****** ****** *) (* implement glTetrix_finalize () = let val level = theGameLevel_get () val score = theTotalScore_get () val () = begin print "Game Over!\n"; printf ("The final level of the game is %i.\n", @(level)); printf ("The final score of the game is %i.\n", @(score)); end // end of [val] in exit (0) end // end of [glTetrix_finalize] *) %{^ static inline ats_void_type glTetrix_glutBitmapCharacter (ats_ref_type ft, ats_char_type c) { glutBitmapCharacter ((void*)ft, (int)c) ; return ; } /* end of [glTetrix_glutBitmapCharacter] */ %} implement glTetrix_finalize () = let val () = theGameOver_set () val () = glutDisplayFunc (lam () => ()) val () = glutKeyboardFunc (f) where { fn f (key: uchar, ix: int, iy: int): void = exit (0) } val str_gameover = "Game Over!" val level = theGameLevel_get () val score = theTotalScore_get () // #define p2s string1_of_strptr val str_level = p2s (sprintf ("The final level of the game is %i.", @(level))) val str_score = p2s (sprintf ("The final score of the game is %i.", @(score))) // abstype FONTref // a reference fun show_string {n:nat} (ft: FONTref, str: string n) : void = loop (ft, str, 0) where { extern fun glutBitmapCharacter (ft: FONTref, c: char): void = "glTetrix_glutBitmapCharacter" fun loop {i:nat | i <= n} .. (ft: FONTref, str: string n, i: size_t i): void = if string_isnot_atend (str, i) then let val () = glutBitmapCharacter (ft, str[i]) in loop (ft, str, i+1) end // end of [if] } // end of [show_string] macdef TIMES_ROMAN_24 = $extval (FONTref, "GLUT_BITMAP_TIMES_ROMAN_24") macdef HELVETICA_18 = $extval (FONTref, "GLUT_BITMAP_HELVETICA_18") val () = glClear(GL_COLOR_BUFFER_BIT) val () = glColor3d (0.0, 0.0, 0.0) val () = glMatrixMode(GL_MODELVIEW) val () = glLoadIdentity () val () = glRasterPos2d (0.25, 0.75) val () = show_string (TIMES_ROMAN_24, str_gameover) val () = glRasterPos2d (0.25, 0.50) val () = show_string (HELVETICA_18, str_level) val () = glRasterPos2d (0.25, 0.45) val () = show_string (HELVETICA_18, str_score) val () = glFlush () val () = glutSwapBuffers () in // exit (0) end // end of [glTetrix_finalize] (* ****** ****** *) extern castfn char_of_uchar (c: uchar): char = "char_of_uchar" extern fun glTetrix_keyboard (key: uchar, ix: int, iy: int): void = "glTetrix_keyboard" implement glTetrix_keyboard (key, _(*ix*), _(*iy*)) = let val key = char_of_uchar (key) in case+ key of | 'i' => let // counterclockwise rotation val _ = theCurrentShape_rotate_if (1) in glutPostRedisplay () end | 'k' => let // clockwise rotation val _ = theCurrentShape_rotate_if (3) in glutPostRedisplay () end | 'j' => let // left horizontal move val _ = theCurrentShape_xmove_if (~1) in glutPostRedisplay () end | 'l' => let // right horizontal move val _ = theCurrentShape_xmove_if ( 1) in glutPostRedisplay () end | ' ' => let val () = theCurrentShape_freefall () in glutPostRedisplay () end | 'n' => let val () = theNextShapeShow_toggle () in glutPostRedisplay () end | 'a' => theTimerTimeInterval_dec () // acceleration | 'd' => theTimerTimeInterval_inc () // deceleration | '\033' => exit (0) | _ => () end // end of [glTetrix_keyboard] (* ****** ****** *) extern fun glTetrix_timer (flag: int): void = "glTetrix_timer" implement glTetrix_timer (flag) = if ~theGameOver_get () then let (* val () = begin prerr "glTetrix_timer: flag = "; prerr flag; prerr_newline () end // end of [va] *) val res = theCurrentShape_ymove_if (~1) (* val () = begin prerr "glTetrix_timer: res = "; prerr res; prerr_newline () end // end of [va] *) val () = if res = 0 then begin theCurrentShape_absorb (); theCurrentShape_update () end // end of [val] val () = glutPostRedisplay () in glutTimerFunc (theTimerTimeInterval_get (), glTetrix_timer, 0) ; end // end of [glTetrix_timer] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) typedef shape_t (m: int, n: int) = '{ xlen= int m , ylen= int n , matrix= matrix (color_t, m, n) , points= int } (* ****** ****** *) local assume shape_t (m: int, n: int) = shape_t (m, n) in implement shape_make (xlen, ylen, mat, pts) = '{ xlen= xlen, ylen= ylen, matrix= mat, points= pts } // end of [shape_make] implement shape_xlen_get (S) = S.xlen implement shape_ylen_get (S) = S.ylen implement shape_matrix_get (S) = S.matrix implement shape_points_get (S) = S.points end // end of [local] (* ****** ****** *) (* XXXX XXXX XXXX XXXX *) #define SHAPE0_X 2 #define SHAPE0_Y 2 val SHAPE0_matrix : matrix (color_t, SHAPE0_X, SHAPE0_Y) = matrix_make_elt (SHAPE0_X, SHAPE0_Y, SHAPE0_color) // end of [val] #define SHAPE0_points 40 (* ****** ****** *) (* XX XX XX XX XX XX XX XX *) #define SHAPE1_X 1 #define SHAPE1_Y 4 val SHAPE1_matrix : matrix (color_t, SHAPE1_X, SHAPE1_Y) = matrix_make_elt (SHAPE1_X, SHAPE1_Y, SHAPE1_color) // end of [val] #define SHAPE1_points 40 (* ****** ****** *) (* XX XX XXXX XXXX XX XX *) #define SHAPE2_X 2 #define SHAPE2_Y 3 val SHAPE2_matrix : matrix (color_t, SHAPE2_X, SHAPE2_Y) = M where { val M = matrix_make_elt (SHAPE2_X, SHAPE2_Y, SHAPE2_color) val () = M[1, SHAPE2_Y, 0] := NONE_color val () = M[1, SHAPE2_Y, 2] := NONE_color } // end of [val] #define SHAPE2_points 50 (* ****** ****** *) (* XX XX XX XX XXXX XXXX *) #define SHAPE3_X 2 #define SHAPE3_Y 3 val SHAPE3_matrix : matrix (color_t, SHAPE3_X, SHAPE3_Y) = M where { val M = matrix_make_elt (SHAPE3_X, SHAPE3_Y, SHAPE3_color) val () = M[1, SHAPE3_Y, 1] := NONE_color val () = M[1, SHAPE3_Y, 2] := NONE_color } // end of [val] #define SHAPE3_points 60 (* ****** ****** *) (* XX XX XX XX XXXX XXXX *) #define SHAPE4_X 2 #define SHAPE4_Y 3 val SHAPE4_matrix : matrix (color_t, SHAPE4_X, SHAPE4_Y) = M where { val M = matrix_make_elt (SHAPE4_X, SHAPE4_Y, SHAPE4_color) val () = M[0, SHAPE4_Y, 1] := NONE_color val () = M[0, SHAPE4_Y, 2] := NONE_color } // end of [val] #define SHAPE4_points 60 (* ****** ****** *) (* XX XX XXXX XXXX XX XX *) #define SHAPE5_X 2 #define SHAPE5_Y 3 val SHAPE5_matrix : matrix (color_t, SHAPE5_X, SHAPE5_Y) = M where { val M = matrix_make_elt (SHAPE5_X, SHAPE5_Y, SHAPE5_color) val () = M[0, SHAPE5_Y, 2] := NONE_color val () = M[1, SHAPE5_Y, 0] := NONE_color } // end of [val] #define SHAPE5_points 60 (* ****** ****** *) (* XX XX XXXX XXXX XX XX *) #define SHAPE6_X 2 #define SHAPE6_Y 3 val SHAPE6_matrix : matrix (color_t, SHAPE6_X, SHAPE6_Y) = M where { val M = matrix_make_elt (SHAPE6_X, SHAPE6_Y, SHAPE6_color) val () = M[0, SHAPE6_Y, 0] := NONE_color val () = M[1, SHAPE6_Y, 2] := NONE_color } // end of [val] #define SHAPE6_points 60 (* ****** ****** *) implement theShapeArray = array_make_arrpsz{shape0}($arrpsz( SHAPE0, SHAPE1, SHAPE2, SHAPE3, SHAPE4, SHAPE5, SHAPE6 )) where { val SHAPE0 = shape_make (SHAPE0_X, SHAPE0_Y, SHAPE0_matrix, SHAPE0_points) val SHAPE1 = shape_make (SHAPE1_X, SHAPE1_Y, SHAPE1_matrix, SHAPE1_points) val SHAPE2 = shape_make (SHAPE2_X, SHAPE2_Y, SHAPE2_matrix, SHAPE2_points) val SHAPE3 = shape_make (SHAPE3_X, SHAPE3_Y, SHAPE3_matrix, SHAPE3_points) val SHAPE4 = shape_make (SHAPE4_X, SHAPE4_Y, SHAPE4_matrix, SHAPE4_points) val SHAPE5 = shape_make (SHAPE5_X, SHAPE5_Y, SHAPE5_matrix, SHAPE5_points) val SHAPE6 = shape_make (SHAPE6_X, SHAPE6_Y, SHAPE6_matrix, SHAPE6_points) } // end of [theShapeArray] implement theNextShapeRef = let val S = array_get_elt_at (theShapeArray, 0) in ref_make_elt (S) end // end of [theNextShapeRef] implement theCurrentShapeRef = let val S = array_get_elt_at (theShapeArray, 0) in ref_make_elt (S) end // end of [theCurrentShapeRef] (* ****** ****** *) %{$ ats_int_type color_index_get (color_t c) { return c ; } ats_bool_type color_is_none (color_t c) { return (c < 0) ? ats_true_bool : ats_false_bool ; } ats_bool_type color_is_some (color_t c) { return (c >= 0) ? ats_true_bool : ats_false_bool ; } ats_bool_type eq_color_color (color_t c1, color_t c2) { return (c1 == c2) ? ats_true_bool : ats_false_bool ; } ats_bool_type neq_color_color (color_t c1, color_t c2) { return (c1 != c2) ? ats_true_bool : ats_false_bool ; } %} (* ****** ****** *) %{$ static int the_rotkind = 0 ; rotkind_t the_rotkind_get () { return the_rotkind ; } ats_void_type the_rotkind_set (rotkind_t rk) { the_rotkind = rk ; return ; } static int the_ix_center = 0 ; static int the_iy_center = 0 ; ats_int_type the_ix_center_get () { return the_ix_center ; } ats_void_type the_ix_center_set (ats_int_type x) { the_ix_center = x ; return ; } ats_int_type the_iy_center_get () { return the_iy_center ; } ats_void_type the_iy_center_set (ats_int_type y) { the_iy_center = y; return ; } %} // end of [%{$] (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc , ats_ptr_type argv ) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_DOUBLE | GLUT_RGB) ; glutInitWindowSize (600, 600) ; glutInitWindowPosition (100, 100) ; glutCreateWindow("Tetrix Game") ; glTetrix_initialize () ; glutDisplayFunc (glTetrix_display) ; // glutReshapeFunc (reshape) ; glutKeyboardFunc (glTetrix_keyboard) ; glTetrix_timer (0) ; glutMainLoop () ; return ; /* deadcode */ } /* end of [mainats] */ %} // end of [%{$] (* ****** ****** *) (* end of [glTetrix.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/drawConvexPoly.dats0000664000175000017500000001352112223166161022623 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March, 2010 // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 (* ****** ****** *) staload GA = "libats/SATS/genarrays.sats" stadef GEVEC = $GA.GEVEC stadef GEVEC_v = $GA.GEVEC_v staload _(*anon*) = "libats/DATS/genarrays.dats" (* ****** ****** *) typedef colorType = $extype_struct "colorType" of { r= float, g= float, b= float } // end of [colorType] viewtypedef polygonType (n:int) = $extype_struct "polygonType" of { n_verts= int n , concave= int , selected_vert= intLt n , verts= ptr // verts[MAX_NUM_VERTS][2] , color= colorType , _rest = undefined_vt } // end of [polygonType] viewtypedef polygonType = [n:nat] polygonType n extern fun polygon_get_vertx {n:nat} {l:addr} (pf_poly: !polygonType n @ l | p_poly: ptr l) :<> [la:addr] ( GEVEC_v (float, n, 2, la), minus (ptr l, GEVEC_v (float, n, 2, la)) | ptr la ) = "mac#polygon_get_vertx" // end of [polygon_get_vertx] extern fun polygon_get_verty {n:nat} {l:addr} (pf_poly: !polygonType n @ l | p_poly: ptr l) :<> [la:addr] ( GEVEC_v (float, n, 2, la), minus (ptr l, GEVEC_v (float, n, 2, la)) | ptr la ) = "mac#polygon_get_verty" // end of [polygon_get_verty] (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) extern fun moveVert {n:nat} (poly: &polygonType n, x: int, y: int): void = "ext#_moveVert" // end of[moveVert] implement moveVert (poly, x, y) = let val i = poly.selected_vert in if (i >= 0) then let val i = (i2sz)i val p_poly = &poly prval pf_poly = view@ poly // val (pf_vertx, fpf_vertx | p_vertx) = polygon_get_vertx (pf_poly | p_poly) val () = $GA.GEVEC_ptr_set_elt_at (!p_vertx, 2, i, (float_of)x) prval () = minus_addback (fpf_vertx, pf_vertx | p_poly) // val (pf_verty, fpf_verty | p_verty) = polygon_get_verty (pf_poly | p_poly) val () = $GA.GEVEC_ptr_set_elt_at (!p_verty, 2, i, (float_of)y) prval () = minus_addback (fpf_verty, pf_verty | p_poly) // prval () = view@ poly := pf_poly in // nothing end // end of [if] end // end of [moveVert] (* ****** ****** *) extern fun selectVert {n:nat} (poly: &polygonType n, x: int, y: int):<> void = "ext#_selectVert" // end of[selectVert] implement selectVert {n} (poly, x, y) = let val n = poly.n_verts in if n > 0 then let val x = (float_of)x and y = (float_of)y val p_poly = &poly prval pf_poly = view@ poly val (pf_vertx, fpf_vertx | p_vertx) = polygon_get_vertx (pf_poly | p_poly) val (pf_verty, fpf_verty | p_verty) = polygon_get_verty (pf_poly | p_poly) // var i: natLt n = 0 val x0 = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, (i2sz)0) val y0 = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, (i2sz)0) var delta: float = square (x0 - x) + square (y0 - y) var k: natLte n // uninitalized val () = for* {k:nat | k <= n} .. (k: int k) => (k := 1; k < n; k := k + 1) let val x1 = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, (i2sz)k) val y1 = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, (i2sz)k) val delta1 = square (x1 - x) + square (y1 - y) val () = if :(k: int k) => (delta1 < delta) then (delta := delta1; i := k) // end of [val] in // continue end // end of [val] // prval () = minus_addback (fpf_vertx, pf_vertx | p_poly) prval () = minus_addback (fpf_verty, pf_verty | p_poly) prval () = view@ poly := pf_poly // // val () = printf ("selectVert: i = %i\n", @(i)) // val () = poly.selected_vert := i in // nothing end // end of [if] end // end of [selectVert] (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" (* ****** ****** *) extern fun drawConvexPoly {n:nat} (poly: &polygonType n): void = "ext#_drawConvexPoly" // end of [drawConvexPoly] implement drawConvexPoly {n} (poly) = let val n = poly.n_verts val p_poly = &poly prval pf_poly = view@ poly val (pf_vertx, fpf_vertx | p_vertx) = polygon_get_vertx (pf_poly | p_poly) val (pf_verty, fpf_verty | p_verty) = polygon_get_verty (pf_poly | p_poly) // val (pf_att | ()) = glPushAttrib(GL_CURRENT_BIT) val () = glColor3f( (GLfloat)poly.color.r, (GLfloat)poly.color.g, (GLfloat)poly.color.b ) // end of [val] val () = case+ 0 of | _ when n = 0 => () | _ when n = 1 => let val (pf_beg | ()) = glBegin (GL_POINTS) val x0 = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, (i2sz)0) val y0 = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, (i2sz)0) val () = glVertex2f ((GLfloat)x0, (GLfloat)y0) val () = glEnd (pf_beg | (*none*)) in // nothing end // end of [n = 1] | _ when n = 2 => let val (pf_beg | ()) = glBegin (GL_POINTS) val x0 = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, (i2sz)0) val y0 = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, (i2sz)0) val () = glVertex2f ((GLfloat)x0, (GLfloat)y0) val x1 = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, (i2sz)1) val y1 = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, (i2sz)1) val () = glVertex2f ((GLfloat)x1, (GLfloat)y1) val () = glEnd (pf_beg | (*none*)) in // nothing end // end of [n = 2] | _ when n >= 3 => let val (pf_beg | ()) = glBegin (GL_POLYGON) var i: sizeLte n // unintialized val () = for (i := (i2sz)0; i < n; i := i + 1) let val x = $GA.GEVEC_ptr_get_elt_at (!p_vertx, 2, i) val y = $GA.GEVEC_ptr_get_elt_at (!p_verty, 2, i) in glVertex2f ((GLfloat)x, (GLfloat)y) end // end of [for] val () = glEnd (pf_beg | (*none*)) in // nothing end // end of [n >= 3] | _ => () val () = glPopAttrib (pf_att | (*none*)) // prval () = minus_addback (fpf_vertx, pf_vertx | p_poly) prval () = minus_addback (fpf_verty, pf_verty | p_poly) prval () = view@ poly := pf_poly in // nothing end // end of [drawConvexPoly] (* ****** ****** *) (* end of [drawConvexPoly.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glCubeView.dats0000664000175000017500000000352312223166161021674 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "libc/SATS/math.sats" staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_FLAT) in // empty end // end of [initialize] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val () = glLoadIdentity () val () = gluLookAt (0.0, 0.0, 5.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0) val () = glScaled (1.0, 2.0, 1.0) val () = glutWireCube ((GLdouble)1.0) (* val () = glutSolidCube ((GLdouble)1.0) *) val () = glFlush () in // empty end // end of [display] extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glFrustum (~1.0, 1.0, ~1.0, 1.0, 1.5, 20.0) val () = glMatrixMode (GL_MODELVIEW) in // empty end // end of [reshape] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow("Icosahedron") ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutMainLoop () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glCubeView] *)ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glBlending2.dats0000664000175000017500000001345412223166161021773 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) #define MAXZ 2.0 #define MINZ ~2.0 #define ZINC 0.001 staload _(*anonymous*) = "prelude/DATS/reference.dats" val solidZ = ref_make_elt (MAXZ) val transparentZ = ref_make_elt (MINZ) (* ****** ****** *) #include "glList.dats" (* ****** ****** *) val cubeLst_ref = glListRef_make () val sphereLst_ref = glListRef_make () extern fun initialize (): void = "initialize" implement initialize () = let var !p_mat_specular with pf1 = @[float](1.0, 1.0, 1.0, 0.15) var !p_mat_shininess with pf2 = @[float](100.0) var !p_position with pf3 = @[float](0.5, 0.5, 1.0, 0.0) (* val () = glMaterialfv (pf1 | GL_FRONT, GL_SPECULAR, p_mat_specular) val () = glMaterialfv (pf2 | GL_FRONT, GL_SHININESS, p_mat_shininess) val () = glLightfv (pf3 | GL_LIGHT0, GL_POSITION, p_position) *) val () = glEnable (GL_LIGHTING) val () = glEnable (GL_LIGHT0) val () = glEnable (GL_DEPTH_TEST) val (pf_sphereLst | sphereLst) = glGenList_exn () val (pf_list | sphereLst) = glNewList (pf_sphereLst | sphereLst, GL_COMPILE) val () = glutSolidSphere ((GLdouble)0.4, (GLint)20, (GLint)16) val () = glEndList (pf_list | (*none*)) val () = glListRef_set (sphereLst_ref, sphereLst) val (pf_cubeLst | cubeLst) = glGenList_exn () val (pf_list | cubeLst) = glNewList (pf_cubeLst | cubeLst, GL_COMPILE) val () = glutSolidCube ((GLdouble)0.6) val () = glEndList (pf_list | (*none*)) val () = glListRef_set (cubeLst_ref, cubeLst) in // empty end // end of [initialize] (* ****** ****** *) local typedef GLfloat = float in extern fun glLightfv {n:nat} {l:addr} (pf: !array_v (GLfloat, n, l) | light: GLenum, pname: GLenum, p: ptr l): void = "mac#atsctrb_glLightfv" extern fun glLightModelfv {n:nat} {l:addr} (pf: !array_v (GLfloat, n, l) | pname: GLenum, params: ptr l): void = "mac#atsctrb_glLightModelfv" extern fun glMaterialfv {n:nat} {l:addr} (pf: !array_v (GLfloat, n, l) | face: GLenum, pname: GLenum, params: ptr l): void = "mac#atsctrb_glMaterialfv" end // end of [local] extern fun display (): void = "display" implement display () = let var !p_mat_solid with pf1 = @[float](0.75, 0.75, 0.0, 1.0) var !p_mat_zero with pf2 = @[float](0.0, 0.0, 0.0, 1.0) var !p_transparent with pf3 = @[float](0.0, 0.8, 0.8, 0.6) var !p_emission with pf4 = @[float](0.0, 0.3, 0.3, 0.6) val () = glClear (GL_COLOR_BUFFER_BIT lor GL_DEPTH_BUFFER_BIT) val (pf_push | ()) = glPushMatrix () val () = glTranslated (~0.15, ~0.15, !solidZ) val () = glMaterialfv (pf2 | GL_FRONT, GL_EMISSION, p_mat_zero) val () = glMaterialfv (pf1 | GL_FRONT, GL_DIFFUSE, p_mat_solid) val () = glCallListRef (sphereLst_ref) val () = glPopMatrix (pf_push | (*none*)) val (pf_push | ()) = glPushMatrix () val () = glTranslated (0.15, 0.15, !transparentZ) val () = glRotated (15.0, 1.0, 1.0, 0.0) val () = glRotated (30.0, 0.0, 1.0, 0.0) val () = glMaterialfv (pf4 | GL_FRONT, GL_EMISSION, p_emission) val () = glMaterialfv (pf3 | GL_FRONT, GL_DIFFUSE, p_transparent) val () = glEnable (GL_BLEND) val () = glDepthMask (GL_FALSE) val () = glBlendFunc (GL_SRC_ALPHA, GL_ONE) val () = glCallListRef (cubeLst_ref) val () = glDepthMask (GL_TRUE) val () = glDisable (GL_BLEND) val () = glPopMatrix (pf_push | (*none*)) in glutSwapBuffers () end // end of [display] (* ****** ****** *) extern fun animate (): void = "animate" implement animate () = let val solidZ_v = !solidZ val transparentZ_v = !transparentZ in if solidZ_v <= MINZ then glutIdleFunc_null () else if transparentZ_v >= MAXZ then glutIdleFunc_null () else let val () = !solidZ := solidZ_v - ZINC val () = !transparentZ := transparentZ_v + ZINC in glutPostRedisplay () end end // end of [animate] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = case+ 0 of | _ when (w <= h) => let val hw = (double_of h) / (double_of w) in glOrtho (~1.5, 1.5, ~1.5 * hw, 1.5 * hw, ~10.0, 10.0) end | _ (* w > h *) => let val wh = (double_of w) / (double_of h) in glOrtho (~1.5 * wh, 1.5 * wh, ~1.5, 1.5, ~10.0, 10.0) end // end of [val] val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in // empty end // end of [reshape] (* ****** ****** *) %{^ ats_char_type char_of_uchar (ats_uchar_type c) { return c ; } %} extern fun char_of_uchar (c: uchar): char = "char_of_uchar" // extern fun keyboard (key: uchar, x: int, y: int): void = "keyboard" implement keyboard (key, x, y) = let val key = char_of_uchar (key) in case+ 0 of | _ when (key = 'a' orelse key = 'A') => begin !solidZ := MAXZ; !transparentZ := MINZ; glutIdleFunc (animate) end | _ when (key = 'r' orelse key = 'R') => begin !solidZ := MAXZ; !transparentZ := MINZ; glutPostRedisplay () end | _ when (key = '\033') => exit (0) | _ => () end // end of [keyboard] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit (&argc, argv) ; glutInitDisplayMode (GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutReshapeFunc (reshape) ; glutKeyboardFunc (keyboard) ; glutDisplayFunc (display) ; glutMainLoop () ; } /* end of [mainats] */ %} (* ****** ****** *) (* end of [glBlending2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/Makefile0000664000175000017500000000565612223166161020434 0ustar hwxihwxi# # # A simple Makefile for some programs involving OpenGL # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSCTRB=$(ATSUSRQ)/contrib/GL/atsctrb_GL.o ATSCTRBGTK=$(ATSUSRQ)/contrib/GTK/atsctrb_GTK.o ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean ###### checkall:: glHello cleanall:: ; $(RMF) glHello glHello: glHello.dats $(ATSCC) -o glHello glHello.dats $(ATSCTRB) -lGL -lglut ###### checkall:: glDoubleBuffer cleanall:: ; $(RMF) glDoubleBuffer glDoubleBuffer: glDoubleBuffer.dats $(ATSCC) -o glDoubleBuffer glDoubleBuffer.dats $(ATSCTRB) -lGL -lglut checkall:: glIcosahedron cleanall:: ; $(RMF) glIcosahedron glIcosahedron: glIcosahedron.dats $(ATSCC) -D_ATS_GCATS -o glIcosahedron glIcosahedron.dats $(ATSCTRB) -lGL -lGLU -lglut -lm checkall:: glClipping cleanall:: ; $(RMF) glClipping glClipping: glClipping.dats $(ATSCC) -o glClipping glClipping.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glCubeView cleanall:: ; $(RMF) glCubeView glCubeView: glCubeView.dats $(ATSCC) -o glCubeView glCubeView.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glPlanet cleanall:: ; $(RMF) glPlanet glPlanet: glPlanet.dats $(ATSCC) -o glPlanet glPlanet.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glColoredTriangle cleanall:: ; $(RMF) glColoredTriangle glColoredTriangle: glColoredTriangle.dats $(ATSCC) -o glColoredTriangle glColoredTriangle.dats $(ATSCTRB) -lGL -lGLU -lglut -lm checkall:: glLitSphere cleanall:: ; $(RMF) glLitSphere glLitSphere: glLitSphere.dats $(ATSCC) -o glLitSphere glLitSphere.dats $(ATSCTRB) -lGL -lglut checkall:: glLightMove1 cleanall:: ; $(RMF) glLightMove1 glLightMove1: glLightMove1.dats $(ATSCC) -o glLightMove1 glLightMove1.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glLightMove2 cleanall:: ; $(RMF) glLightMove2 glLightMove2: glLightMove2.dats $(ATSCC) -o glLightMove2 glLightMove2.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glBlending1 cleanall:: ; $(RMF) glBlending1 glBlending1: glBlending1.dats $(ATSCC) -o glBlending1 glBlending1.dats $(ATSCTRB) -lGL -lGLU -lglut checkall:: glBlending2 cleanall:: ; $(RMF) glBlending2 glBlending2: glBlending2.dats $(ATSCC) -o glBlending2 glBlending2.dats $(ATSCTRB) -lGL -lglut checkall:: glDisplayList1 cleanall:: ; $(RMF) glDisplayList1 glDisplayList1: glDisplayList1.dats $(ATSCC) -o glDisplayList1 glDisplayList1.dats $(ATSCTRB) -lGL -lGLU -lglut -lm ###### # # A little bit animation for fun # checkall:: glFaces cleanall:: ; $(RMF) glFaces glFaces: glFaces.dats $(ATSCC) -o glFaces glFaces.dats $(ATSCTRB) -lGL -lglut -lm ###### # # A simple game of Tetris implemented in ATS # checkall:: glTetrix cleanall:: ; $(RMF) glTetrix glTetrix: glTetrix.dats $(ATSCC) -O2 -o glTetrix glTetrix.dats $(ATSCTRB) -lGL -lglut -lm ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c $(RMF) *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glPlanet.dats0000664000175000017500000000612712223166161021411 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) %{^ static int day = 0 ; static inline ats_int_type day_get () { return day ; } static inline ats_void_type day_set (int x) { day = x ; return ; } %} extern fun day_get (): int = "day_get" extern fun day_set (x: int): void = "day_set" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_FLAT) in // empty end // end of [initialize] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val (pf1_mat | ()) = glPushMatrix () val () = glRotated (270.0, 1.0, 0.0, 0.0) val () = glutWireSphere ((GLdouble)1.0, (GLint)20, (GLint)16) // sun val day = day_get () val mday = day mod 30 and yday = day val m_angle = (double_of mday / 30) * 360.0 and y_angle = (double_of yday / 365) * 360.0 val () = glRotated (y_angle, 0.0, 0.0, 1.0) val () = glTranslated (2.0, 0.0, 0.0) val (pf2_mat | ()) = glPushMatrix () val () = glRotated (15.0, 0.0, 1.0, 0.0) val () = glutWireSphere ((GLdouble)0.25, (GLint)10, (GLint)8) // planet val () = glRotated (m_angle, 0.0, 0.0, 1.0) val () = glTranslated (0.5, 0.0, 0.0) val () = glutWireSphere ((GLdouble)0.10, (GLint)5, (GLint)4) // planet val () = glPopMatrix (pf2_mat | (*none*)) val () = glPopMatrix (pf1_mat | (*none*)) val () = glutSwapBuffers () in // empty end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = gluPerspective (60.0, (double_of w) / (double_of h), 1.0, 20.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () val () = gluLookAt (0.0, 0.0, 5.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0) in // empty end // end of [reshape] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ void keyboard (unsigned char key, int x, int y) { switch (key) { case 'd': day = (day + 5) % 365 ; glutPostRedisplay () ; break ; case 'D': day = (day - 5) % 365 ; glutPostRedisplay () ; break ; case '\033': exit (0) ; default: break ; } return ; } ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_DOUBLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow("Planet") ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutKeyboardFunc (keyboard) ; glutMainLoop () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glPlanet.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glFaces.dats0000664000175000017500000002347112223166161021210 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) staload "libc/SATS/math.sats" staload "libc/SATS/unistd.sats" staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" staload _(*anon*) = "prelude/DATS/reference.dats" (* ****** ****** *) val frame_max = 8 val frame_cur_ref = ref_make_elt (0) val direction_ref = ref_make_elt (1) val iris_x_ofs_max = 1.5 val hair_move_angle1_max = M_PI / 3 val hair_move_angle2_max = M_PI / 2 val hair_move_angle3_max = 2 * M_PI / 3 val head_rotate_angle_max = 30.0 (* ****** ****** *) fn draw_arc {n:int | n >= 1} ( radius: double, ang_init: double, ang_delta: double, n: int n ) : void = let val theta = (ang_delta / n) fun loop {i:nat | i <= n} (i: int i, theta_i: double): void = let val () = glVertex3d (radius * cos (theta_i), radius * sin (theta_i), 0.0) in if i < n then loop (i + 1, theta_i + theta) end val (pf | ()) = glBegin (GL_LINE_STRIP) val () = loop (0, ang_init) val () = glEnd (pf | (*none*)) in // empty end // end of [draw_arc] (* ****** ****** *) fn draw_polygon_eqlat {n:int | n >= 3} (knd: GLenum, radius: double, n: int n) = let val theta = (2 * M_PI) / n fun loop {i:nat | i <= n} (i: int i, theta_i: double): void = if i < n then let val () = glVertex3d (radius * cos (theta_i), radius * sin (theta_i), 0.0) in loop (i + 1, theta_i + theta) end val (pf | ()) = glBegin (knd) val () = loop (0, 0.0) val () = glEnd (pf | (*none*)) in // empty end // end of [draw_polygon_eqlat] (* ****** ****** *) fn draw_eye ( width: double , height: double , iris_x_ofs: double ) : void = let val r = height / 2 val theta = atan2 (height, width) val theta2 = 2 * theta val theta4 = 2 * theta2 val sin_theta = sin (theta) val dist = sqrt (height * height + width * width) val R2 = dist / (2 * sin_theta) val R = R2 / 2 val (pf_push | ()) = glPushMatrix () val () = glTranslated (0.0, R - r, 0.0) val () = draw_arc (R, 1.5 * M_PI - theta2, theta4, 16) val () = glPopMatrix (pf_push | (*none*)) val (pf_push | ()) = glPushMatrix () val () = glTranslated (0.0, r - R, 0.0) val () = draw_arc (R, 0.5 * M_PI - theta2, theta4, 16) val () = glPopMatrix (pf_push | (*none*)) val (pf_push | ()) = glPushMatrix () val () = glTranslated (iris_x_ofs, 0.0, 0.0) val () = glColor3d (0.0, 0.0, 0.0) val () = draw_polygon_eqlat (GL_POLYGON, r / 1.25, 16) val () = glColor3d (1.0, 1.0, 1.0) val () = glTranslated (iris_x_ofs / 2, 0.0, 0.0) val () = draw_polygon_eqlat (GL_POLYGON, r / 8, 16) val () = glColor3d (0.0, 0.0, 0.0) val () = glPopMatrix (pf_push | (*none*)) in // empty end // end of [draw_eye] (* ****** ****** *) fn draw_face (face_radius: double, anim_ratio: double, sgn: int): void = let val hair_length = 4.0 val hair_angle = M_PI / 3 val mouth_angle = 0.425 * M_PI val (pf_push | ()) = glPushMatrix () val () = glScaled (1.0625, 1.3125, 1.0) val () = begin if sgn > 0 then begin glColor3d (anim_ratio, 0.5, 1.0 - anim_ratio) end else begin glColor3d (1.0 - anim_ratio, 0.5, anim_ratio) end end // end of [val] val () = draw_polygon_eqlat (GL_POLYGON, face_radius, 64) val () = glColor3d (0.0, 0.0, 0.0) val (pf_beg | ()) = glBegin (GL_LINES) val x_hair = face_radius * cos (hair_angle) val y_hair = face_radius * sin (hair_angle) val (pf_push1 | ()) = glPushMatrix () val ang1 = ( if sgn > 0 then anim_ratio * hair_move_angle3_max else anim_ratio * hair_move_angle1_max ) : double val ang2 = anim_ratio * hair_move_angle2_max val ang3 = ( if sgn > 0 then anim_ratio * hair_move_angle1_max else anim_ratio * hair_move_angle3_max ) : double val x_delta1 = sgn * hair_length * sin (ang1) val y_delta1 = hair_length * cos (ang1) val x_delta2 = sgn * hair_length * sin (ang2) val y_delta2 = hair_length * cos (ang2) val x_delta3 = sgn * hair_length * sin (ang3) val y_delta3 = hair_length * cos (ang3) val () = glVertex3d (~x_hair, y_hair, 0.0) val () = glVertex3d (~x_hair - x_delta1, y_hair + y_delta1, 0.0) val () = glVertex3d (0.0, face_radius, 0.0) val () = glVertex3d (~x_delta2, face_radius + y_delta2, 0.0) val () = glVertex3d (x_hair, y_hair, 0.0) val () = glVertex3d (x_hair - x_delta3, y_hair + y_delta3, 0.0) val () = glPopMatrix (pf_push1 | (*none*)) val () = glEnd (pf_beg | (*none*)) val () = glPopMatrix (pf_push | (*none*)) // eye drawing val iris_x_ofs = sgn * (anim_ratio * iris_x_ofs_max) val (pf_push | ()) = glPushMatrix () val () = glTranslated (~4.0, 4.0, 0.0) val () = draw_eye (6.0, 3.0, iris_x_ofs) val () = glPopMatrix (pf_push | (*none*)) val (pf_push | ()) = glPushMatrix () val () = glTranslated (4.0, 4.0, 0.0) val () = draw_eye (6.0, 3.0, iris_x_ofs) val () = glPopMatrix (pf_push | (*none*)) // mouth drawing val (pf_push | ()) = glPushMatrix () val () = if sgn > 0 then let val () = glTranslated (0.0, ~4.0, 0.0) val () = draw_arc (2.5, 1.5 * M_PI - mouth_angle, 2 * mouth_angle, 32) in // empty end else let val () = glTranslated (0.0, ~7.0, 0.0) val () = draw_arc (2.5, 0.5 * M_PI - mouth_angle, 2 * mouth_angle, 32) in // empty end // end of [if] val () = glPopMatrix (pf_push | (*none*)) in // empty end // end of [draw_face] (* ****** ****** *) local fn glClearColor_black (): void = glClearColor (0.0, 0.0, 0.0, 0.0) fn glClearColor_white (): void = glClearColor (1.0, 1.0, 1.0, 0.0) in // in of [local] extern fun initialize (): void = "initialize" // end of [initialize] implement initialize () = let val () = glClearColor_white () val () = glShadeModel (GL_FLAT) in // empty end // end of [initialize] end // end of [local] (* ****** ****** *) // extern fun animate (): void = "animate" // // HX: this is a very crude way of doing animation! // implement animate () = let val frame = !frame_cur_ref val frame_new = begin if frame < frame_max then frame + 1 else 0 end : int // end of [val] val () = if frame_new = 0 then let val dir = !direction_ref in !direction_ref := ~dir end // end of [val] val () = !frame_cur_ref := frame_new val _(*err*) = usleep (100000) // one-tenth of a second in glutPostRedisplay () end // end of [animate] (* ****** ****** *) extern fun display (): void = "display" // end of [display] implement display () = let val face_radius = 10.0 val frame = !frame_cur_ref val anim_ratio = (double_of frame) / frame_max val dir = !direction_ref val () = glClear (GL_COLOR_BUFFER_BIT) val () = glLineWidth (2.5) val () = glColor3d (0.0, 0.0, 0.0) val head_rotate_angle = anim_ratio * head_rotate_angle_max val x_ratio = cos (head_rotate_angle * M_PI / 180) val (pf | ()) = glPushMatrix () (* val () = if dir > 0 then begin glTranslatef (~15.0 * x_ratio, 0.0, 0.0) end else begin glTranslatef (~30.0 + 15.0 * x_ratio , 0.0, 0.0) end // end of [if] *) val () = glTranslated (~20.0, 0.0, 0.0) (* val () = if dir > 0 then begin glRotatef (~head_rotate_angle, 0.0, 0.0, 1.0) end else begin glRotatef (head_rotate_angle, 0.0, 0.0, 1.0) end *) val () = draw_face (face_radius, anim_ratio, 1) val () = glPopMatrix (pf | (*none*)) val (pf | ()) = glPushMatrix () (* val () = if dir > 0 then begin glTranslatef (15.0 * x_ratio, 0.0, 0.0) end else begin glTranslatef (30.0 - 15.0 * x_ratio, 0.0, 0.0) end *) val () = glTranslated (20.0, 0.0, 0.0) (* val () = if dir > 0 then begin glRotatef (head_rotate_angle, 0.0, 0.0, 1.0) end else begin glRotatef (~head_rotate_angle, 0.0, 0.0, 1.0) end *) val () = draw_face (face_radius, anim_ratio, ~1) val () = glPopMatrix (pf | (*none*)) in glutSwapBuffers () end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" // end of [reshape] implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glOrtho (~50.0, 50.0, ~50.0, 50.0, ~1.0, 1.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in // empty end // end of [reshape] (* ****** ****** *) extern fun keyboard (key: uchar, x: int, y: int): void = "keyboard" // end of [keyboard] implement keyboard (key, x, y) = let val key = char_of_uchar (key) in case+ 0 of | _ when (key = '\033') => exit (0) | _ => () end // end of [keyboard] (* ****** ****** *) macdef int = int_of_GLenum val animation_status_ref = ref_make_elt (0) extern fun mouse (button: int, state: int, x: int, y: int): void = "mouse" // end of [mouse] implement mouse (button, state, x, y) = begin case+ 0 of | _ when (button = (int)GLUT_LEFT_BUTTON) => begin if (state = (int)GLUT_DOWN) then let val status = !animation_status_ref val () = !animation_status_ref := 1 - status in if status = 0 then glutIdleFunc (animate) else glutIdleFunc_null () end // end of [if] end // end of [_ when ...] | _ => () end // end of [mouse] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_DOUBLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutKeyboardFunc (keyboard) ; glutMouseFunc (mouse) ; glutMainLoop () ; return ; /* deadcode */ } /* end of [mainats] */ %} // end of[%{$] (* ****** ****** *) (* end of [glFaces.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glClipping.dats0000664000175000017500000000502212223166161021724 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_FLAT) in // empty end // end of [initialize] extern fun display (): void = "display" implement display () = let var !p_eqn0 with pf_eqn0 = @[double](1.0, 0.0, 0.0, 0.0) var !p_eqn1 with pf_eqn1 = @[double](0.0, 1.0, 0.0, 0.0) val () = glClear (GL_COLOR_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val (pf_mat | ()) = glPushMatrix () val () = glTranslated (0.0, 0.0, ~5.0) // extern fun glClipPlane {l:addr} (pf: !array_v (double, 4, l) | plane: GLenum, eqn: ptr l): void = "mac#atsctrb_glClipPlane" // val () = glRotated (315.0, 1.0, 0.0, 0.0) val () = glRotated (45.0, 0.0, 1.0, 0.0) val () = glClipPlane (pf_eqn0 | GL_CLIP_PLANE0, p_eqn0) val () = glEnable (GL_CLIP_PLANE0) val () = glClipPlane (pf_eqn1 | GL_CLIP_PLANE1, p_eqn1) val () = glEnable (GL_CLIP_PLANE1) val () = glRotated (90.0, 1.0, 0.0, 0.0) val () = glutWireSphere ((GLdouble)1.0, (GLint)40, (GLint)32) val () = glPopMatrix (pf_mat | (*none*)) val () = glFlush () in // empty end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = gluPerspective (40.0, (double_of w) / (double_of h), 1.0, 20.0) val () = glMatrixMode (GL_MODELVIEW) in // empty end // end of [reshape] (* ****** ****** *) extern fun main_work (): void = "main_work" implement main_work () = let val () = initialize () val () = glutDisplayFunc (display) val () = glutReshapeFunc (reshape) in glutMainLoop () end // end of [main_work] (* ****** ****** *) implement main_dummy () = () %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; main_work () ; return ; /* deadcode */ } %} (* ****** ****** *) (* end of [glClipping.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glIcosahedron.dats0000664000175000017500000002117512223166161022424 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "libc/SATS/math.sats" staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) (* extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glOrtho (~1.0, 1.0, ~1.0, 1.0, ~1.0, 1.0) in // empty end // end of [initialize] *) (* ****** ****** *) viewdef float_3_v (l:addr) = array_v (float, 3, l) fn normalize_float_3 {l:addr} (pf: !float_3_v l | p: ptr l): void = let val x0 = !p.[0] and x1 = !p.[1] and x2 = !p.[2] val mag = sqrtf (x0 * x0 + x1 * x1 + x2 * x2) in !p.[0] := x0 / mag; !p.[1] := x1 / mag; !p.[2] := x2 / mag end fn normacrossprod_float_3 {l1,l2,l3:addr} ( pf1: !float_3_v l1 , pf2: !float_3_v l2 , pf3: !float_3_v l3 | p1: ptr l1, p2: ptr l2, p3: ptr l3 ) : void = let val x0 = !p1.[0] and x1 = !p1.[1] and x2 = !p1.[2] val y0 = !p2.[0] and y1 = !p2.[1] and y2 = !p2.[2] val z0 = x1 * y2 - x2 * y1 val z1 = x2 * y0 - x0 * y2 val z2 = x0 * y1 - x1 * y0 val mag = sqrtf (z0 * z0 + z1 * z1 + z2 * z2) in !p3.[0] := z0 / mag; !p3.[1] := z1 / mag; !p3.[2] := z2 / mag end (* ****** ****** *) extern fun add_float_3_float_3 ( v1: & @[float][3], v2: & @[float][3] ) : [l:addr] (free_gc_v (float?, 3, l), float_3_v l | ptr l) = "add_float_3_float_3" overload + with add_float_3_float_3 %{^ ats_ptr_type add_float_3_float_3 (ats_ptr_type v1, ats_ptr_type v2) { int i ; float *v = ats_malloc_gc (3 * sizeof(float)) ; for (i = 0; i < 3; ++i) v[i] = ((float*)v1)[i] + ((float*)v2)[i] ; return v ; } // end of [add_float_3_float_3] %} // end of [%{^] (* ****** ****** *) fn drawTriangle {l1,l2,l3:addr} ( pf1: !float_3_v l1 , pf2: !float_3_v l2 , pf3: !float_3_v l3 | p1: ptr l1, p2: ptr l2, p3: ptr l3 ) : void = let // extern fun glNormal3fv {l:addr} (pf: !float_3_v l | p: ptr l): void = "mac#atsctrb_glNormal3fv" extern fun glVertex3fv {l:addr} (pf: !float_3_v l | p: ptr l): void = "mac#atsctrb_glVertex3fv" // val (pf | ()) = glBegin (GL_TRIANGLES) val () = glNormal3fv (pf1 | p1) val () = glVertex3fv (pf1 | p1) val () = glNormal3fv (pf2 | p2) val () = glVertex3fv (pf2 | p2) val () = glNormal3fv (pf3 | p3) val () = glVertex3fv (pf3 | p3) val () = glEnd (pf | (*none*)) // in // empty end // end of [drawTriangle] extern fun subdivide {n:nat} {l1,l2,l3:addr} ( pf1: !float_3_v l1 , pf2: !float_3_v l2 , pf3: !float_3_v l3 | p1: ptr l1, p2: ptr l2, p3: ptr l3, n: int n ) : void = "subdivide" implement subdivide ( pf1, pf2, pf3 | p1, p2, p3, n ) = if n > 0 then let val (pf12_gc, pf12 | p12) = !p1 + !p2 val (pf23_gc, pf23 | p23) = !p2 + !p3 val (pf31_gc, pf31 | p31) = !p3 + !p1 val () = normalize_float_3 (pf12 | p12) val () = normalize_float_3 (pf23 | p23) val () = normalize_float_3 (pf31 | p31) val () = subdivide (pf1, pf12, pf31 | p1, p12, p31, n-1) val () = subdivide (pf2, pf23, pf12 | p2, p23, p12, n-1) val () = subdivide (pf3, pf31, pf23 | p3, p31, p23, n-1) val () = subdivide (pf12, pf23, pf31 | p12, p23, p31, n-1) val () = array_ptr_free (pf12_gc, pf12 | p12) val () = array_ptr_free (pf23_gc, pf23 | p23) val () = array_ptr_free (pf31_gc, pf31 | p31) in // empty end else begin drawTriangle (pf1, pf2, pf3 | p1, p2, p3) end // end of [subdivide] (* ****** ****** *) typedef float_3 = array (float, 3) (* ****** ****** *) macdef X = $extval (float, "0.525731112119133606") macdef Z = $extval (float, "0.850650808352039932") typedef float_12_3 = array (float_3, 12) val vdata00 = array_make_arrsz {float} $arrsz(~X, 0.0f, Z) val vdata01 = array_make_arrsz {float} $arrsz( X, 0.0f, Z) val vdata02 = array_make_arrsz {float} $arrsz(~X, 0.0f, ~Z) val vdata03 = array_make_arrsz {float} $arrsz( X, 0.0f, ~Z) val vdata10 = array_make_arrsz {float} $arrsz( 0.0f, Z, X) val vdata11 = array_make_arrsz {float} $arrsz( 0.0f, Z, ~X) val vdata12 = array_make_arrsz {float} $arrsz( 0.0f, ~Z, X) val vdata13 = array_make_arrsz {float} $arrsz( 0.0f, ~Z, ~X) val vdata20 = array_make_arrsz {float} $arrsz( Z, X, 0.0f) val vdata21 = array_make_arrsz {float} $arrsz(~Z, X, 0.0f) val vdata22 = array_make_arrsz {float} $arrsz( Z, ~X, 0.0f) val vdata23 = array_make_arrsz {float} $arrsz(~Z, ~X, 0.0f) val vdata : float_12_3 = array_make_arrsz {float_3} $arrsz( vdata00, vdata01, vdata02, vdata03 , vdata10, vdata11, vdata12, vdata13 , vdata20, vdata21, vdata22, vdata23 ) typedef nat12 = natLt (12) typedef int_3 = array (nat12, 3) typedef int_20_3 = array (int_3, 20) val tind00 = array_make_arrsz {nat12} $arrsz(1, 4, 0) val tind01 = array_make_arrsz {nat12} $arrsz(4, 9, 0) val tind02 = array_make_arrsz {nat12} $arrsz(4, 5, 9) val tind03 = array_make_arrsz {nat12} $arrsz(8, 5, 4) val tind04 = array_make_arrsz {nat12} $arrsz(1, 8, 4) val tind10 = array_make_arrsz {nat12} $arrsz(1, 10, 8) val tind11 = array_make_arrsz {nat12} $arrsz(10, 3, 8) val tind12 = array_make_arrsz {nat12} $arrsz(8, 3, 5) val tind13 = array_make_arrsz {nat12} $arrsz(3, 2, 5) val tind14 = array_make_arrsz {nat12} $arrsz(3, 7, 2) val tind20 = array_make_arrsz {nat12} $arrsz(3, 10, 7) val tind21 = array_make_arrsz {nat12} $arrsz(10, 6, 7) val tind22 = array_make_arrsz {nat12} $arrsz(6, 11, 7) val tind23 = array_make_arrsz {nat12} $arrsz(6, 0, 11) val tind24 = array_make_arrsz {nat12} $arrsz(6, 1, 0) val tind30 = array_make_arrsz {nat12} $arrsz(10, 1, 6) val tind31 = array_make_arrsz {nat12} $arrsz(11, 0, 9) val tind32 = array_make_arrsz {nat12} $arrsz(2, 11, 9) val tind33 = array_make_arrsz {nat12} $arrsz(5, 2, 9) val tind34 = array_make_arrsz {nat12} $arrsz(11, 2, 7) val tindices : int_20_3 = array_make_arrsz {int_3} $arrsz( tind00, tind01, tind02, tind03, tind04 , tind10, tind11, tind12, tind13, tind14 , tind20, tind21, tind22, tind23, tind24 , tind30, tind31, tind32, tind33, tind34 ) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT lor GL_DEPTH_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val (pf | ()) = glBegin (GL_TRIANGLES) val () = loop (0) where { extern fun glNormal3fv (A: array (float, 3)): void = "mac#atsctrb_glNormal3fv" extern fun glVertex3fv (A: array (float, 3)): void = "mac#atsctrb_glVertex3fv" extern fun subdivide {n:nat} ( A1: array (float, 3), A2: array (float, 3), A3: array (float, 3), n: int n ) : void = "subdivide" fun loop {i:nat | i <= 20} (i: int i): void = if i < 20 then let val ti: int_3 = tindices[i] val vdata_ti_0 = vdata[ti[0]] val vdata_ti_1 = vdata[ti[1]] val vdata_ti_2 = vdata[ti[2]] val () = subdivide (vdata_ti_0, vdata_ti_1, vdata_ti_2, 4) (* val () = glNormal3fv (vdata_ti_0) val () = glVertex3fv (vdata[ti[0]]) val () = glNormal3fv (vdata_ti_1) val () = glVertex3fv (vdata[ti[1]]) val () = glNormal3fv (vdata_ti_2) val () = glVertex3fv (vdata[ti[2]]) *) in loop (i+1) end // end of [if] } // end of [where] val () = glEnd (pf | (*none*)) val () = glFlush () in // empty end // end of [display] (* ****** ****** *) implement main_dummy () = () %{$ void initialize () { GLfloat mat_specular[] = { 1.0, 1.0, 1.0, 1.0 } ; GLfloat mat_shininess[] = { 50.0 } ; GLfloat light_position[] = { 1.0, 1.0, 1.0, 0.0 } ; GLfloat white_light[] = { 1.0, 1.0, 1.0, 1.0 } ; GLfloat lmodel_ambient[] = { 0.1, 0.1, 0.1, 1.0 } ; glClearColor (0.0, 0.0, 0.0, 0.0) ; glShadeModel (GL_SMOOTH) ; glMaterialfv (GL_FRONT, GL_SPECULAR, mat_specular) ; glMaterialfv (GL_FRONT, GL_SHININESS, mat_shininess) ; glLightfv (GL_LIGHT0, GL_POSITION, light_position) ; glLightfv (GL_LIGHT0, GL_DIFFUSE, white_light) ; glLightfv (GL_LIGHT0, GL_SPECULAR, white_light) ; glLightModelfv (GL_LIGHT_MODEL_AMBIENT, lmodel_ambient) ; glEnable (GL_LIGHTING) ; glEnable (GL_LIGHT0) ; glEnable (GL_DEPTH_TEST) ; return ; } ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow("Icosahedron") ; initialize () ; glutDisplayFunc (display) ; glutMainLoop () ; return ; /* deadcode */ } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [glIcosahedron.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glDoubleBuffer.dats0000664000175000017500000000605412223166161022531 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) // // A simple example demonstrating the use of double buffering // (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) var spin: double = 0.0 val (pf_spin: vbox (double @ spin) | ()) = vbox_make_view_ptr (view@ spin | &spin) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glShadeModel (GL_FLAT) in // empty end // end of [initialize] extern fun display (): void = "display" implement display () = let val spin = let prval vbox (pf) = pf_spin in spin end val () = glClear (GL_COLOR_BUFFER_BIT) val (pf | ()) = glPushMatrix () val () = glRotated (spin, 0.0, 0.0, 1.0) val () = glColor3d (1.0, 1.0, 1.0) val () = glRectd (~25.0, ~25.0, 25.0, 25.0) val () = glPopMatrix (pf | (*none*)) val () = glutSwapBuffers () in // empty end // end of [display] extern fun spinDisplay (): void = "spinDisplay" implement spinDisplay () = let var spin_v: double = begin let prval vbox (pf) = pf_spin in spin end end val () = spin_v := spin_v + 2.0 val () = if spin_v > 360.0 then spin_v := spin_v - 360.0 val () = begin let prval vbox (pf) = pf_spin in spin := spin_v end end in glutPostRedisplay () end // end of [spinDisplay] extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glOrtho (~50.0, 50.0, ~50.0, 50.0, ~1.0, 1.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in // empty end // end of [reshape] (* ****** ****** *) macdef int = int_of_GLenum extern fun mouse (button: int, state: int, x: int, y: int): void = "mouse" // end of [mouse] implement mouse (button, state, x, y) = begin case+ 0 of | _ when (button = (int)GLUT_LEFT_BUTTON) => begin if (state = (int)GLUT_DOWN) then glutIdleFunc (spinDisplay) end | _ when (button = (int)GLUT_RIGHT_BUTTON) => begin if (state = (int)GLUT_DOWN) then glutIdleFunc_null () end | _ => () end // end of [mouse] extern fun main_work (): void = "main_work" implement main_work () = let val () = initialize () val () = glutDisplayFunc (display) val () = glutReshapeFunc (reshape) val () = glutMouseFunc (mouse) in glutMainLoop () end // end of [main_work] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_DOUBLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; main_work () ; return ; /* deadcode as [main_work] never returns */ } /* end of [mainats] */ %} (* ****** ****** *) (* end of [glDoubleBuffer.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glLitSphere.dats0000664000175000017500000000564112223166161022065 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "libc/SATS/math.sats" staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let var !p_mat_specular with pf1 = @[GLfloat]((GLfloat)1.0, (GLfloat)1.0, (GLfloat)1.0, (GLfloat)1.0) var !p_mat_shininess with pf2 = @[GLfloat]((GLfloat)50.0) var !p_light_position with pf3 = @[GLfloat]((GLfloat)1.0, (GLfloat)1.0, (GLfloat)1.0, (GLfloat)0.0) var !p_white_light with pf4 = @[GLfloat]((GLfloat)1.0, (GLfloat)1.0, (GLfloat)1.0, (GLfloat)1.0) var !p_lmodel_ambient with pf5 = @[GLfloat]((GLfloat)0.1, (GLfloat)0.1, (GLfloat)0.1, (GLfloat)1.0) val () = glClearColor (0.0, 0.0, 0.0, 0.0) ; val () = glShadeModel (GL_SMOOTH) val () = glMaterialfv (GL_FRONT, GL_SPECULAR, !p_mat_specular) val () = glMaterialfv (GL_FRONT, GL_SHININESS, !p_mat_shininess) val () = glLightfv (GL_LIGHT0, GL_POSITION, !p_light_position) val () = glLightfv (GL_LIGHT0, GL_DIFFUSE, !p_white_light) val () = glLightfv (GL_LIGHT0, GL_SPECULAR, !p_white_light) val () = glLightModelfv (GL_LIGHT_MODEL_AMBIENT, !p_lmodel_ambient) val () = glEnable (GL_LIGHTING) val () = glEnable (GL_LIGHT0) val () = glEnable (GL_DEPTH_TEST) in // empty end // end of [initialize] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT lor GL_DEPTH_BUFFER_BIT) val () = glutSolidSphere ((GLdouble)1.0, (GLint)160, (GLint)128) val () = glFlush () in // empty end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = case+ 0 of | _ when (w <= h) => let val hw = (double_of h) / (double_of w) in glOrtho (~1.5, 1.5, ~1.5 * hw, 1.5 * hw, ~10.0, 10.0) end | _ (* w > h *) => let val wh = (double_of w) / (double_of h) in glOrtho (~1.5 * wh, 1.5 * wh, ~1.5, 1.5, ~10.0, 10.0) end val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () in end // end of [reshape] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit (&argc, argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutMainLoop () ; } /* end of [mainats] */ %} (* ****** ****** *) (* end of [glLitSphere.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glBlending1.dats0000664000175000017500000000666112223166161021774 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/reference.dats" val leftFirst = ref_make_elt (false) (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glEnable (GL_BLEND) val () = glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA) val () = glShadeModel (GL_FLAT) val () = glClearColor (0.0, 0.0, 0.0, 0.0) in // empty end // end of [initialize] (* ****** ****** *) fn drawLeftTriangle () = let // drawing a yellow triangle on LHS val (pf | ()) = glBegin (GL_TRIANGLES) val () = glColor4d (1.0, 1.0, 0.0, 0.75) // yellow val () = glVertex3d (0.1, 0.9, 0.0) val () = glVertex3d (0.1, 0.1, 0.0) val () = glVertex3d (0.7, 0.5, 0.0) val () = glEnd (pf | (*none*)) in // empty end // end of [drawleftTriangle] fn drawRightTriangle () = let // drawing a cyan triangle on RHS val (pf | ()) = glBegin (GL_TRIANGLES) val () = glColor4d (0.0, 1.0, 1.0, 0.75) // cyan val () = glVertex3d (0.9, 0.9, 0.0) val () = glVertex3d (0.3, 0.5, 0.0) val () = glVertex3d (0.9, 0.1, 0.0) val () = glEnd (pf | (*none*)) in // empty end // end of [drawRightTriangle] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = case+ 0 of | _ when !leftFirst => begin drawLeftTriangle () ; drawRightTriangle () end | _ => begin drawRightTriangle () ; drawLeftTriangle () end in glFlush () end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = case+ 0 of | _ when (w <= h) => let val hw = (double_of h) / (double_of w) in gluOrtho2D (0.0, 1.0, 0.0, 1.0 * hw) end | _ (* w > h *) => let val wh = (double_of w) / (double_of h) in gluOrtho2D (0.0, 1.0 * wh, 0.0, 1.0) end // end of [val] in // empty end // end of [reshape] (* ****** ****** *) extern fun char_of_uchar (c: uchar): char = "char_of_uchar" %{^ ats_char_type char_of_uchar (ats_uchar_type c) { return c ; } %} extern fun keyboard (key: uchar, x: int, y: int): void = "keyboard" implement keyboard (key, x, y) = let val key = char_of_uchar key in case+ key of | _ when (key = 't' orelse key = 'T') => let val () = !leftFirst := ~(!leftFirst) in glutPostRedisplay () end | _ when (key = '\033') => exit (0) | _ => () end // end of [keyboard] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit (&argc, argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB | GLUT_DEPTH) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutDisplayFunc (display) ; glutReshapeFunc (reshape) ; glutKeyboardFunc (keyboard) ; glutMainLoop () ; } /* end of [mainats] */ %} (* ****** ****** *) (* end of [glBlending1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glHello.dats0000664000175000017500000000306212223166161021224 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun initialize (): void = "initialize" implement initialize () = let val () = glClearColor (0.0, 0.0, 0.0, 0.0) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val () = glOrtho (0.0, 1.0, 0.0, 1.0, ~1.0, 1.0) in // empty end // end of [initialize] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val (pf | ()) = glBegin (GL_POLYGON) val () = glVertex3d (0.25, 0.25, 0.0) val () = glVertex3d (0.75, 0.25, 0.0) val () = glVertex3d (0.75, 0.75, 0.0) val () = glVertex3d (0.25, 0.75, 0.0) val () = glEnd (pf | (*none*)) val () = glFlush () in // empty end // end of [display] (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} // end of [%{^] implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats ( ats_int_type argc, ats_ptr_type argv ) { glutInit ((int*)&argc, (char**)argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow("Hello!") ; initialize () ; glutDisplayFunc (display) ; glutMainLoop () ; return ; /* deadcode */ } // end of [mainats] %} // end of [%{$] (* ****** ****** *) (* end of [glHello.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glDisplayList1.dats0000664000175000017500000001026612223166161022507 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) %{^ extern ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) ; %} (* ****** ****** *) staload "libc/SATS/math.sats" staload "contrib/GL/SATS/gl.sats" staload "contrib/GL/SATS/glu.sats" staload "contrib/GL/SATS/glut.sats" (* ****** ****** *) extern fun drawTorus {c,t:nat} (numc: int c, numt: int t): void = "drawTorus" implement drawTorus {c,t} (numc, numt) = let val PI2 = M_PI + M_PI val angc = PI2 / numc val angt = PI2 / numt fun loop3 {i,j,k:nat | i < c; j <= t; k <= 1} .. (i: int i, j: int j, k: int k): void = let val c = double_of (mod_int_int (i + k, numc)) + 0.5 val t = double_of (mod_int_int (j, numt)) val cangc = c * angc and tangt = t * angt val cos_cangc = cos (cangc) val cos_tangt = cos (tangt) val x = (1.0 + 0.1 * cos_cangc) * cos_tangt val sin_cangc = sin (cangc) val sin_tangt = sin (tangt) val y = (1.0 + 0.1 * cos_cangc) * sin_tangt val z = 0.1 * sin_cangc val () = glVertex3d (x, y, z) in if k > 0 then loop3 (i, j, k-1) else () end fun loop2 {i,j:nat | i < c; j <= t} .. (i: int i, j: int j): void = let val () = loop3 (i, j, 1) in if j < numt then loop2 (i, j+1) end // end of [if] fun loop1 {i:nat | i <= c} .. (i: int i): void = if i < numc then let val (pf | ()) = glBegin (GL_QUAD_STRIP) val () = loop2 (i, 0) val () = glEnd (pf | (*none*)) in loop1 (i+1) end // end of [if] in loop1 (0) end // end of [drawTorus] (* ****** ****** *) #include "glList.dats" (* ****** ****** *) val torusLst_ref = glListRef_make () extern fun initialize (): void = "initialize" implement initialize () = let val (pf_torusLst | torusLst) = glGenList_exn () val (pf_list | torusLst) = glNewList (pf_torusLst | torusLst, GL_COMPILE) val () = drawTorus (8, 25) val () = glEndList (pf_list | (*none*)) val () = glListRef_set (torusLst_ref, torusLst) val () = glShadeModel (GL_FLAT) val () = glClearColor (0.0, 0.0, 0.0, 0.0) in // empty end // end of [initialize] (* ****** ****** *) extern fun display (): void = "display" implement display () = let val () = glClear (GL_COLOR_BUFFER_BIT) val () = glColor3d (1.0, 1.0, 1.0) val () = glCallListRef (torusLst_ref) in glFlush () end // end of [display] (* ****** ****** *) extern fun reshape (w: int, h: int): void = "reshape" implement reshape (w, h) = let val () = glViewport (0, 0, w, h) val () = glMatrixMode (GL_PROJECTION) val () = glLoadIdentity () val wh = (double_of w) / (double_of h) val () = gluPerspective (30.0, wh, 1.0, 100.0) val () = glMatrixMode (GL_MODELVIEW) val () = glLoadIdentity () val () = gluLookAt (0.0, 0.0, 10.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0) in end // end of [reshape] (* ****** ****** *) %{^ ats_char_type char_of_uchar (ats_uchar_type c) { return c ; } %} extern fun char_of_uchar (c: uchar): char = "char_of_uchar" extern fun keyboard (key: uchar, x: int, y: int): void = "keyboard" implement keyboard (key, x, y) = let val key = char_of_uchar (key) in case+ 0 of | _ when (key = 'x' orelse key = 'X') => begin glRotated (30.0, 1.0, 0.0, 0.0); glutPostRedisplay () end | _ when (key = 'y' orelse key = 'Y') => begin glRotated (30.0, 0.0, 1.0, 0.0); glutPostRedisplay () end | _ when (key = 'i' orelse key = 'I') => begin glLoadIdentity (); gluLookAt (0.0, 0.0, 10.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0); glutPostRedisplay () end | _ when (key = '\033') => exit (0) | _ => () end // end of [keyboard] (* ****** ****** *) implement main_dummy () = () (* ****** ****** *) %{$ ats_void_type mainats (ats_int_type argc, ats_ptr_type argv) { glutInit (&argc, argv) ; glutInitDisplayMode (GLUT_SINGLE | GLUT_RGB) ; glutInitWindowSize (500, 500) ; glutInitWindowPosition (100, 100) ; glutCreateWindow(((char**)argv)[0]) ; initialize () ; glutReshapeFunc (reshape) ; glutKeyboardFunc (keyboard) ; glutDisplayFunc (display) ; glutMainLoop () ; } /* end of [mainats] */ %} (* ****** ****** *) (* end of [glDisplayList1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/OpenGL/glList.dats0000664000175000017500000000256412223166161021102 0ustar hwxihwxi(* ** ** A simple OpenGL example ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2008 ** *) (* ****** ****** *) // // staload "contrib/GL/SATS/gl.sats" // (* ****** ****** *) abstype GLlistref extern fun glListRef_make (): GLlistref = "atsctrb_glListRef_make" extern fun glListRef_get (r: GLlistref): [n:nat] GLlist n = "atsctrb_glListRef_get" extern fun glListRef_set {n:nat} (r: GLlistref, n: GLlist n): void = "atsctrb_glListRef_set" extern fun glCallListRef (r: GLlistref): void = "atsctrb_glCallListRef" %{^ static inline ats_ptr_type atsctrb_glListRef_make () { uint *r ; r = ats_malloc_gc (sizeof(uint)) ; *r = (uint)0 ; return r ; } static inline ats_uint_type atsctrb_glListRef_get (ats_ptr_type r) { uint lst ; lst = *(uint*)r ; if (lst == 0) { fprintf (stderr, "Exit: [glListRef_get] failed.") ; exit (1) ; } *(uint*)r = (uint)0 ; return lst ; } static inline ats_void_type atsctrb_glListRef_set (ats_ptr_type r, ats_uint_type lst) { if (*(uint*)r != 0) { fprintf (stderr, "Exit: [glListRef_set] failed.") ; exit (1) ; } *(uint*)r = (uint)lst ; return ; } static inline ats_void_type atsctrb_glCallListRef (ats_ptr_type r) { uint lst ; lst = *(ats_uint_type*)r ; if (lst == 0) { fprintf (stderr, "Exit: [glCallList(%u)] failed.\n", lst) ; exit (1) ; } glCallList (lst) ; return ; } %} ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/0000700000175000017500000000000012223166161016245 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_6.dats0000664000175000017500000001001012223166161020224 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 300 - 301 // section 5.6: Implementing a Shell (Version 2) // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/sys/SATS/wait.sats" staload "libc/SATS/stdlib.sats" // for getenv staload "libc/SATS/unistd.sats" // for environ_get_arrsz (* ****** ****** *) typedef ptrarr0 (n:int) = @[ptr?][n] dataview getargs_v (n0:int, l:addr, int) = | {n:nat | n < n0} getargs_v_succ (n0, l, n) of ( ptrarr (n) @ l, ptrarr (n) @ l - ptrarr0 (n0) @ l ) // end of [getargs_v_succ] | getargs_v_fail (n0, l, ~1) of (ptrarr0 (n0) @ l) // end of [getargs_v] extern fun getargs {n0:nat} {l:addr} ( pfargv: ptrarr0 (n0) @ l | pargv: ptr l, n0: int n0, iseof: &bool? >> bool ) : [n:int] (getargs_v (n0, l, n) | int n) = "mac#getargs" // end of [getargs] (* ****** ****** *) fun printenv {n:pos} ( argc: int n, argv: &(@[string][n]) ) : void = let var m: size_t // uninitialized val (pf, fpf | p) = environ_get_arrsz (m) stavar m: int val m: size_t m = m var i: sizeLte m val _0 = size1_of_int1 (0) val () = for (i := _0; i < m; i := i+1) (printf("%s\n", @(!p.[i]))) // end of [val] prval () = fpf (pf) in // nothing end // end of [printenv] (* ****** ****** *) fun assgnenv {n:pos} (argc: int n, argv: &(@[string][n])): void = let var nerr: int = 0 val () = while (true) let val () = ( if argc <= 2 then (nerr := 1; break; assertfalse()) ) : [n >= 3] void val () = if (setenv (argv.[1], argv.[2], 1(*overwritten*)) < 0) then nerr := 2 // end of [val] in break end // end of [val] val () = (case+ nerr of | 1 => printf ("Incorrect command format for \n", @()) | 2 => printf ("[setenv] failed\n", @()) | _ => () ) : void // end of [val] in // nothing end // end of [assgnenv] (* ****** ****** *) fun quit {n:pos} (argc: int n, argv: &(@[string][n])): void = exit(0) // end of [quit] (* ****** ****** *) extern fun execute2 {n:pos} (argc: int n, argv: &ptrarr(n)): void // end of [execute2] implement execute2 (argc, argv) = let val pid = fork_err () val pid = int_of_pid (pid) in case+ 0 of | _ when pid = 0 => let // child prval (pf1, fpf1) = ptrarr_takeout{string} (view@(argv)) val arg0 = argv.[0] prval () = view@(argv) := fpf1 (pf1) val _err = execvp (arg0, argv) val () = if _err < 0 then prerr "execute2: child: [execvp] failed\n" in _exit (EXIT_FAILURE) end // end of [_ when ...] | _ when pid > 0 => let // parent val _err = int_of_pid (wait_null ()) val () = if _err < 0 then prerr "execute2: parent: [wait] failed\n" in // nothing end // end of [_ when ...] | _ (*pid = -1*) => let val () = prerr "execute2: [fork] failed" in // nothing end // end of [_] end // end of [execute2] (* ****** ****** *) implement main () = while (true) let #define MAXARG 32 var !pargv with pfargv = @[ptr?][MAXARG]() val () = printf ("@ ", @()) var iseof: bool // uninitialized val [n:int] (pfargs | argc) = getargs (pfargv | pargv, MAXARG, iseof) // val () = if argc >= 0 then let var leftover: bool = false prval getargs_v_succ (pf, fpf) = pfargs prval (pf1, fpf1) = ptrarr_takeout{string} (pf) val () = if (argc > 0) then let val arg0 = pargv->[0] in case+ 0 of | _ when arg0 = "quit" => quit (argc, !pargv) | _ when arg0 = "print" => printenv (argc, !pargv) | _ when arg0 = "assgn" => assgnenv (argc, !pargv) | _ => leftover := true end // end of [val] prval () = pf := fpf1 (pf1) val () = if argc > 0 then if leftover then execute2 (argc, !pargv) // end of [val] prval () = pfargv := fpf (pf) in // nothing end else let prval getargs_v_fail (pf) = pfargs prval () = pfargv := pf in // nothing end // end of [val] // in if iseof then exit (EXIT_SUCCESS) end // end of [main] (* ****** ****** *) (* end of [AUP_5_6.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_1_3.dats0000664000175000017500000001725412223166161020465 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 527 - 530 // section 8.1.3: Handling Multiple Clients // (* ****** ****** *) #define SOCKETNAME "MySocket" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/printf.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/select.sats" staload "libc/sys/SATS/types.sats" (* ****** ****** *) staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/socket.sats" staload "libc/sys/SATS/un.sats" staload "libc/sys/SATS/socket_un.sats" (* ****** ****** *) // // HX: this is really an overkill ... // fun fprint_bytes_size {n1,n2:nat | n2 <= n1} (out: FILEref, buf: &(@[byte][n1]), n2: size_t n2): void = let val p_buf = &buf prval () = eqsize_byte_one () // sizeof byte == 1 prval pfmul = mul_make {n2,sizeof(byte)} () prval () = mul_elim {n2,1} (pfmul) prval (pf1, pf2) = array_v_split {byte} {n1} {n2} (pfmul, view@ (buf)) prval pfu = unit_v () typedef env = FILEref val () = array_ptr_foreach_funenv_tsz {byte} {unit_v} {env} (pfu | !p_buf, lam (pf | x, out) =<> $effmask_ref (fprint_byte (out, x)), n2, sizeof, out) prval unit_v () = pfu prval () = view@ (buf) := array_v_unsplit {byte} {n2,n1-n2} (pfmul, pf1, pf2) in // nothing end // end of [print_buf_size] fun print_bytes_size {n1,n2:nat | n2 <= n1} (buf: &(@[byte][n1]), n2: size_t n2): void = fprint_bytes_size (stdout_ref, buf, n2) // end of [print_bytes_size] (* ****** ****** *) fun run_client (sa: &sockaddr_un): bool = let val pid = fork_err () val ipid = int_of_pid (pid) in // case+ 0 of | _ when ipid = 0 => let // child var !p_buf with pf_buf = @[byte][64]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val [fd:int] (pfskt | fd) = socket_family_type_exn (AF_UNIX, SOCK_STREAM) val () = loop (pfskt | fd, sa) where { fun loop ( pfskt: !socket_v (fd, init) >> socket_v (fd, conn) | fd: int fd, sa: &sockaddr_un ) : void = let prval () = sockaddr_un_trans (view@ sa) val (pfopt | err) = connect_err (pfskt | fd, sa, socklen_un) prval () = sockaddr_trans_un (view@ sa) in if err >= 0 then let prval connect_v_succ pf = pfopt; prval () = pfskt := pf in // nothing end else let prval connect_v_fail pf = pfopt; prval () = pfskt := pf val errno = errno_get () in if (errno = ENOENT) then let val _leftover = sleep (1u) in loop (pfskt | fd, sa) end else let val () = exit (EXIT_FAILURE) in loop (pfskt | fd, sa) end // end of [if] end // end of [if] end // end of [loop] } // end of [val] // val cpid = getpid () val cpid = (lint_of_pid)cpid // val _n = snprintf (pf_buf | p_buf, 64, "Hello from %ld!", @(cpid)) val n = strbuf_length (!p_buf) val () = socket_write_substring (pfskt | fd, __cast !p_buf, 0, n) where { extern castfn __cast {m,n:nat} (x: &strbuf (m,n)):<> string n } // end of [val] prval () = pf_buf := bytes_v_of_strbuf_v (pf_buf) val nread = socket_read_exn (pfskt | fd, !p_buf, 64) val () = (print "Client got: "; print_bytes_size (!p_buf, nread); print_newline ()) val () = socket_close_exn (pfskt | fd) in exit (EXIT_SUCCESS) end // end of [ipid = 0] // | _ when ipid > 0 => true // | _ (* ipid=-1 *) => false // end of [case] end // end of [run_client] (* ****** ****** *) fun lower_hwm {fd:nat} (set: &fd_set, fd: int fd): int = if fd > 0 then ( if ~FD_ISSET (fd, set) then lower_hwm (set, fd - 1) else fd ) else 0 // end of [if] // end of [lower_hwm] (* ****** ****** *) fun run_server (sa: &sockaddr_un): bool = let // #define BUFSZ 128 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) // var set: fd_set var read_set: fd_set? val () = FD_ZERO (set) // var fd_hwm: int = ~1 // val [fd:int] (pfopt | sfd) = socket_family_type_err (AF_UNIX, SOCK_STREAM) in // if sfd >= 0 then let prval Some_v (pfskt) = pfopt val () = bind_un_exn (pfskt | sfd, sa) val () = listen_exn (pfskt | sfd, SOMAXCONN) prval pfskt = pfskt val () = if (sfd > fd_hwm) then fd_hwm := sfd // extern prfun __attach {fd:int} (pf: socket_v (fd, conn) | fd: int fd):<> void extern prfun __detach {fd:int} (fd: int fd):<> socket_v (fd, conn) // var nerr: int = 0 val () = FD_SET (sfd, set) val () = while (true) let val () = read_set := set val rtn = select0 (fd_hwm+1, read_set, null, null, null) where { extern fun select0 (n: int, set: &fd_set, _: ptr, _: ptr, _: ptr): int = "mac#atslib_select" // end of [extern] } // end of [val] (* val () = (print "select: rtn = "; print rtn; print_newline ()) *) val () = if (rtn < 0) then let val () = (perror "select"; nerr := nerr + 1; break) in (*nothing*) end // end of [val] var fd: Nat // uninitialized val () = for* (read_set: fd_set) => (fd := 0; fd <= fd_hwm; fd := fd + 1) if FD_ISSET (fd, read_set) then ( if (fd = sfd) then let val (pfopt | cfd) = accept_null_err (pfskt | sfd) in if (cfd >= 0) then let prval Some_v (pfconn) = pfopt prval () = __attach (pfconn | cfd) val () = FD_SET (cfd, set) in if (cfd > fd_hwm) then fd_hwm := cfd end else let prval None_v () = pfopt in (perror "accept"; nerr := nerr + 1; break) end // end of [val] end else let prval pfconn = __detach (fd) val nread = socket_read_err (pfconn | fd, !p_buf, BUFSZ) in if nread >= 0 then let val nread = size1_of_ssize1 (nread) in if nread = 0 then let val () = FD_CLR (fd, set) val () = socket_close_exn (pfconn | fd) val () = if (fd_hwm = fd) then fd_hwm := lower_hwm (set, fd) in // nothing end else let val () = ( print "Server got: "; print_bytes_size (!p_buf, nread); print_newline () ) // end of [val] val () = socket_write_substring (pfconn | fd, "Goodbye!", 0, 8) prval () = __attach (pfconn | fd) in // nothing end // end of [if] end else let prval () = __attach (pfconn | fd) in perror "socket read"; nerr := nerr + 1; break end // end of [if] end // end of [if] ) // end of [if] // end of [for] // end of [val] in if nerr > 0 then break end // end of [val] val () = socket_close_exn (pfskt | sfd) in if nerr = 0 then true else false end else let prval None_v () = pfopt val () = perror "socket" in false end // end of [if] // end // end of [run_server] (* ****** ****** *) implement main () = () where { // var sa: sockaddr_un val _err = unlink (SOCKETNAME) val () = sockaddr_un_init (sa, AF_UNIX, SOCKETNAME) // var nerr: int = 0 // var i: int val () = for (i := 1; i <= 4; i := i+1) let val rtn = run_client (sa) in if ~rtn then (nerr := nerr + 1; break) end // end of [val] val () = if (nerr = 0) then (print "All the clients have been started"; print_newline ()) // val () = if (nerr = 0) then let val rtn = run_server (sa) in if ~rtn then (nerr := nerr + 1) end // end of [val] val () = if (nerr = 0) then (print "The server have been started"; print_newline ()) // val () = if nerr > 0 then exit (EXIT_FAILURE) // val () = exit (EXIT_SUCCESS) // } // end of [main] (* ****** ****** *) (* end of [AUP_8_1_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_15.dats0000664000175000017500000000345612223166161020324 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 320 - 321 // section 5.15: Getting and Setting the Priority // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/SATS/stdlib.sats" // atoi staload "libc/SATS/string.sats" // strncmp staload "libc/SATS/unistd.sats" (* ****** ****** *) %{^ #undef atslib_execvp #define atslib_execvp(arg0, argv) execvp((char*)arg0, (char**)argv) %} // end of [%{^] fun print_usage () = printf ("usage: aupnice [-num] command\n", @()) // end of [print_usage] implement main {n} (argc, argv) = () where { val () = ( if (argc >= 2) then () else (print_usage () ; exit (EXIT_FAILURE); assertfalse ()) ) : [n >= 2] void val arg1 = argv.[1] var incr: int = 10 // default var cmdarg: intGte 1 = 1 val () = if strncmp (arg1, "-", 1) = 0 then (incr := atoi(arg1); cmdarg := 2) stavar cmdarg: int val cmdarg = cmdarg : int (cmdarg) val () = ( if (argc > cmdarg) then () else (print_usage () ; exit (EXIT_FAILURE); assertfalse ()) ) : [n > cmdarg ] void val _err = nice (incr) // this [nice] value is to be inherited val cmdpath = argv.[cmdarg] val cmdpath = string1_of_string (cmdpath) val n = strlen (cmdpath) val ind = string_index_of_char_from_left (cmdpath, '/') val cmdname = ( if ind >= 0 then let val ind = size1_of_ssize1 (ind) in string_of_strbuf (string_make_substring (cmdpath, ind + 1, n-ind-1)) end else cmdpath ) : string val () = argv.[cmdarg] := cmdname val _err = execvp (cmdpath, argv.[cmdarg]) where { extern fun execvp (arg0: string, argv: &string): int = "mac#atslib_execvp" } // end of [val] val () = exit (EXIT_FAILURE) } // end of [main] (* ****** ****** *) (* end of [AUP_5_15.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/utils/0000700000175000017500000000000012223166161017405 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/utils/errinfo.dats0000664000175000017500000000263612223166161021751 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynloading at run-time (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/string.sats" (* ****** ****** *) staload "errinfo.sats" viewtypedef errinfo_struct = $extype_struct "ats_errinfo_type" of { errinfo_loc= string , errinfo_errno= errno_t , errinfo_errstr= strptr0 } // end of [errinfo_struct] assume errinfo_t = errinfo_struct (* ****** ****** *) implement fprint_errinfo (out, ei) = let val en = int_of_errno (ei.errinfo_errno) val () = fprintf (out, "ERROR(%i): ", @(en)) val () = fprint_string (out, ei.errinfo_loc) val () = fprintf (out, ": ", @()) val () = fprint_strptr (out, ei.errinfo_errstr) val () = fprint_newline (out) in // nothing end // end of [fprint_errinfo] (* ****** ****** *) implement errinfo_set_wloc (ei, loc) = let val errno = errno_get () val (fpf_errstr | errstr) = strerror (errno) val () = ei.errinfo_loc := loc val () = () where { val () = ei.errinfo_errstr := strptr_dup (errstr) } // end of [val] prval () = fpf_errstr (errstr) val () = ei.errinfo_errno := errno in // nothing end // end of [errinfo_set_wloc] (* ****** ****** *) implement errinfo_clear (ei) = () where { val () = strptr_free (ei.errinfo_errstr) } // end of [errinfo_clear] (* ****** ****** *) (* end of [errinfo.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/utils/errinfo.sats0000664000175000017500000000364312223166161021767 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staloading at run-time (* ****** ****** *) %{# #include "errinfo.cats" %} // end of [%{#] (* ****** ****** *) staload ERRNO = "libc/SATS/errno.sats" typedef errno_t = $ERRNO.errno_t (* ****** ****** *) absviewt@ype errinfo_t = $extype "ats_errinfo_type" absviewt@ype opterr (i:int, l:addr) = int(i) // castfn opterr_none {l:addr} (pf: errinfo_t? @ l | (*none*)): opterr (0, l) castfn opterr_some {i:int | i < 0} {l:addr} (pf: errinfo_t @ l | i: int i): opterr (i, l) // prfun opterr_unnone {l:addr} (err: opterr (0, l)): errinfo_t? @ l prfun opterr_unsome {i:int | i < 0} {l:addr} (err: opterr (i, l)): errinfo_t @ l // fun opterr_clear {i:int} {l:addr} (err: !opterr (i, l) >> opterr (0, l)): void // fun opterr_set {i:int} {l:addr} (err: opterr (0, l), i: int i): opterr (i, l) // end of [opterr_set] castfn opterr2int {i:int} {l:addr} (err: !opterr (i, l)):<> int (i) fun lt_opterr_int {i1,i2:int} {l:addr} (err: !opterr (i1, l), i2: int i2):<> bool (i1 < i2) = "#atspre_lt_int_int" fun lte_opterr_int {i1,i2:int} {l:addr} (err: !opterr (i1, l), i2: int i2):<> bool (i1 <= i2) = "#atspre_lte_int_int" fun gt_opterr_int {i1,i2:int} {l:addr} (err: !opterr (i1, l), i2: int i2):<> bool (i1 > i2) = "#atspre_gt_int_int" fun gte_opterr_int {i1,i2:int} {l:addr} (err: !opterr (i1, l), i2: int i2):<> bool (i1 >= i2) = "#atspre_gte_int_int" // fun fprint_opterr {i:int} {l:addr} (err: !opterr (i, l)): void // (* ****** ****** *) fun fprint_errinfo (out: FILEref, ei: &errinfo_t): void (* ****** ****** *) fun errinfo_set_wloc (ei: &errinfo_t? >> errinfo_t, loc: string) : void // end of [errinfo_set_wloc] macdef errinfo_set (ei) = errinfo_set_wloc (,(ei), #LOCATION) (* ****** ****** *) fun errinfo_clear (ei: &errinfo_t >> errinfo_t?): void (* ****** ****** *) (* end of [errinfo.sats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/utils/errinfo.cats0000664000175000017500000000031112223166161021734 0ustar hwxihwxi#ifndef ERRINFO_SATS #define ERRINFO_SATS #include typedef struct { char *errinfo_loc ; int errinfo_errno ; char *errinfo_errstr ; } ats_errinfo_type ; #endif // end of [ERRINFO_SATS] ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/utils/getargs.c0000664000175000017500000000260112223166161021220 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // /* ****** ****** */ // // book: AUP (2nd edition), pages 292 - 296 // section 5.4: Implementing a Shell (Version I) // /* ****** ****** */ #include #include #include /* ****** ****** */ #define true 1 #define false 0 typedef int bool ; /* ****** ****** */ #define MAXLINE 256 /* ****** ****** */ int getargs ( char *argv[], int n, bool *iseofp ) { static char cmd[MAXLINE] ; char *cmdp ; int i ; *iseofp = false ; // if (!fgets(cmd, MAXLINE, stdin)) { if (ferror(stdin)) goto FAIL ; *iseofp = true ; return -1 ; } // end of [if] // if (!strchr(cmd, '\n')) { while (1) { switch(getchar()) { case '\n': break ; case EOF: if (ferror(stdin)) goto FAIL ; default: continue ; } break ; } // end of [while] printf ("Line too long -- command ignored\n") ; return -1 ; } // end of [if] // cmdp = &cmd[0] ; for (i = 0; i < n; i += 1) { if ((argv[i] = strtok(cmdp, " \t\n")) == (char*)0) break ; cmdp = NULL ; // tell [strtok] to continue } // end of [for] // if (i >= n) { printf ("Line too long -- command ignored\n") ; return -1 ; } else { return i ; } // end of [if] // FAIL: { return -1 ; } // end of [FAIL] } // end of [getargs] /* ****** ****** */ /* end of [getargs.c] */ ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_1_1.dats0000664000175000017500000001047612223166161020462 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 520 - 524 // section 8.1.1: How Sockets Work // (* ****** ****** *) #define SOCKETNAME "MySocket" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/types.sats" (* ****** ****** *) staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/socket.sats" staload "libc/sys/SATS/un.sats" staload "libc/sys/SATS/socket_un.sats" (* ****** ****** *) // // HX: this is really an overkill ... // fun fprint_bytes_size {n1,n2:nat | n2 <= n1} (out: FILEref, buf: &(@[byte][n1]), n2: size_t n2): void = let val p_buf = &buf prval () = eqsize_byte_one () // sizeof byte == 1 prval pfmul = mul_make {n2,sizeof(byte)} () prval () = mul_elim {n2,1} (pfmul) prval (pf1, pf2) = array_v_split {byte} {n1} {n2} (pfmul, view@ (buf)) prval pfu = unit_v () typedef env = FILEref val () = array_ptr_foreach_funenv_tsz {byte} {unit_v} {env} (pfu | !p_buf, lam (pf | x, out) =<> $effmask_ref (fprint_byte (out, x)), n2, sizeof, out) prval unit_v () = pfu prval () = view@ (buf) := array_v_unsplit {byte} {n2,n1-n2} (pfmul, pf1, pf2) in // nothing end // end of [print_buf_size] fun print_bytes_size {n1,n2:nat | n2 <= n1} (buf: &(@[byte][n1]), n2: size_t n2): void = fprint_bytes_size (stdout_ref, buf, n2) // end of [print_bytes_size] (* ****** ****** *) implement main () = () where { // var sa: sockaddr_un val _err = unlink (SOCKETNAME) val () = sockaddr_un_init (sa, AF_UNIX, SOCKETNAME) // val pid = fork_err () val ipid = int_of_pid (pid) val () = case+ 0 of | _ when ipid = 0 => let // child var !p_buf with pf_buf = @[byte][64]() val [fd:int] (pfskt | fd) = socket_family_type_exn (AF_UNIX, SOCK_STREAM) val () = loop (pfskt | fd, sa) where { fun loop ( pfskt: !socket_v (fd, init) >> socket_v (fd, conn) | fd: int fd, sa: &sockaddr_un ) : void = let prval () = sockaddr_un_trans (view@ sa) val (pfopt | err) = connect_err (pfskt | fd, sa, socklen_un) prval () = sockaddr_trans_un (view@ sa) in if err >= 0 then let prval connect_v_succ pf = pfopt; prval () = pfskt := pf in // nothing end else let prval connect_v_fail pf = pfopt; prval () = pfskt := pf val errno = errno_get () in if (errno = ENOENT) then let val _leftover = sleep (1u) in loop (pfskt | fd, sa) end else let val () = exit (EXIT_FAILURE) in loop (pfskt | fd, sa) end // end of [if] end // end of [if] end // end of [loop] } // end of [val] val () = socket_write_substring (pfskt | fd, "Hello!", 0, 6) var !p_buf with pf_buf = @[byte][64]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val nread = socket_read_exn (pfskt | fd, !p_buf, 64) val () = (print "Client got: "; print_bytes_size (!p_buf, nread); print_newline ()) val () = socket_close_exn (pfskt | fd) in exit (EXIT_SUCCESS) end // end of [ipid = 0] | _ when ipid > 0 => let // parent val [fd:int] (pfskt | fd) = socket_family_type_exn (AF_UNIX, SOCK_STREAM) val () = bind_un_exn (pfskt | fd, sa) val () = listen_exn (pfskt | fd, SOMAXCONN) val (pfskt_c | fd_c) = accept_null_exn (pfskt | fd) var !p_buf with pf_buf = @[byte][64]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val nread = socket_read_exn (pfskt_c | fd_c, !p_buf, 64) val () = (print "Server got: "; print_bytes_size (!p_buf, nread); print_newline ()) val () = socket_write_substring (pfskt_c | fd_c, "Goodbye!", 0, 8) val () = socket_close_exn (pfskt | fd) val () = socket_close_exn (pfskt_c | fd_c) in exit (EXIT_SUCCESS) end // end of [ipid > 0] | _ => let // [fork] failed val () = perror ("fork") in exit (EXIT_FAILURE) end // end of [val] } // end of [main] (* ****** ****** *) (* end of [AUP_8_1_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_2_13.dats0000664000175000017500000000514312223166161020312 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 106 - 107 // section 2.13: lseek system call // (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) staload S = "libats/SATS/linstack_arr.sats" stadef STACK = $S.STACK stadef STACK0 = $S.STACK0 (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" staload _(*anon*) = "libats/DATS/linstack_arr.dats" staload _(*anon*) = "libats/ngc/DATS/deque_arr.dats" (* ****** ****** *) extern fun backward (path: string): void (* ****** ****** *) #define BUFSZ 256 implement backward (path) = let // typedef itm = char var S: STACK0 (itm) // viewtypedef T (i:int) = STACK (itm, BUFSZ, i) viewtypedef T0 = [i:nat] T (i) // fun print_stack {i:nat} .. (S: &T i >> T 0): void = let val i = $S.stack_size (S) in if i > 0 then let val c = $S.stack_remove (S) in print c; print_stack (S) end // end of [if] end // end of [print_stack] // val () = $S.stack_initialize (S, BUFSZ) // val (pf_fd | fd) = open_flag_err (path, O_RDONLY) // val () = assert_errmsg (fd >= 0, #LOCATION) prval open_v_succ (pf_fd) = pf_fd // val _pos1 = ($T.off_of_lint)1L val off = lseek_err (pf_fd | fd, _pos1, $T.SEEK_END) val off = $T.lint_of_off(off) val () = assert_errmsg (off <> ~1L, #LOCATION) // val _neg2 = ($T.off_of_lint)(~2L) val () = while* (S: T0) => (true) let var c: char val off = lseek_err (pf_fd | fd, _neg2, $T.SEEK_CUR) val off = $T.lint_of_off (off) (* val () = (print "while: off = "; print off; print_newline ()) *) val () = assert_errmsg (off <> ~1L, #LOCATION) val n = read (fd, c, (size_of_int1)1) where { extern fun read (_:int, _: &char? >> char, _:size_t): size_t = "atslib_fildes_read_exn" } // end of [val] (* val () = print c *) // val () = if :(S: T0) => (c = '\n') then print_stack (S) val nitm = $S.stack_size (S) val () = if :(S: T0) => (nitm < BUFSZ) then $S.stack_insert (S, c) else errno_set (E2BIG) // line too long // end of [val] // in if off <= 0L then break end // end of [val] // val () = print_stack (S) val () = $S.stack_uninitialize_vt {itm} (S) // val () = close_exn (pf_fd | fd) // in // nothing end // end of [backward] (* ****** ****** *) implement main (argc, argv) = () where { val () = assertloc (argc >= 2) val () = backward (argv.[1]) } // end of [val] (* ****** ****** *) (* end of [AUP_2_13.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_3_6_4.dats0000664000175000017500000001403312223166161020456 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // book: AUP (2nd edition), pages 170 - 174 // section 3.6.4: Implementing getcwd (walking up the tree) // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/sys/SATS/stat.sats" staload "libc/sys/SATS/types.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/dirent.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) viewtypedef pathlist = List_vt (strptr0) (* ****** ****** *) fun push_pathlist (lstrs: &pathlist, name: string): void = let val name = string1_of_string name val n = string1_length (name) val (pf_gc, pf_buf | p) = string_make_substring (name, 0, n) val lstr = strptr_of_strbuf @(pf_gc, pf_buf | p) in lstrs := list_vt_cons {strptr0} (lstr, lstrs) end (* end of [push_pathlist] *) fun free_pathlist (ps: pathlist): void = case+ ps of | ~list_vt_cons (p, ps) => (strptr_free p; free_pathlist ps) | ~list_vt_nil () => () // end of [free_pathlist] (* ****** ****** *) extern fun getcwdx (): strptr0 (* ****** ****** *) fun SAME_INODE .<>. (s1: &stat, s2: &stat): bool = (s1.st_dev = s2.st_dev) andalso (s1.st_ino = s2.st_ino) // end of [SAME_INODE] (* ****** ****** *) macdef errno_is_ENOENT () = (errno_get () = ENOENT) fun loop_dir ( ents: stream_vt dirent, stat: &stat, lstrs: &pathlist, nent: int ) : int = case+ !ents of | ~stream_vt_cons (ent, ents) => let var ent = ent val [l:addr] (fpf_d_name | d_name) = dirent_get_d_name (ent) viewtypedef VT = strptr(l) var stat_entry: stat? // uninitialized val rtn = lstat_err ($UNSAFE.castvwtp1{string}{VT}(d_name), stat_entry) val res = if rtn >= 0 then let prval () = opt_unsome (stat_entry) in case+ 0 of | _ when SAME_INODE (stat, stat_entry) => let val () = ~ents val () = if nent > 0 then push_pathlist (lstrs, "/") val () = push_pathlist (lstrs, $UNSAFE.castvwtp1{string}{VT}(d_name)) in 1 // the entry for the current directory is found end // end of [_ when ...] | _ => loop_dir (ents, stat, lstrs, nent) end else let prval () = opt_unnone {stat} (stat_entry) val () = ~ents in 0 (* error *) end // end of [if] prval () = fpf_d_name (d_name) in res end (* end of [stream_vt_cons] *) | ~stream_vt_nil () => 0 (* error *) // end of [loop_dir] fun getcwdx_main {fd:int} ( pf_fd: fildes_v (fd) | fd: int fd, stat: &stat ) : strptr0 = let var nerr: int = 0 var lstrs: pathlist = list_vt_nil () val () = loop (pf_fd | fd, stat, lstrs, 0(*nent*), nerr) where { fun loop {fd:int} ( pf_fd: !fildes_v (fd) | fd: int fd, stat: &stat, lstrs: &pathlist, nent: int, nerr: &int ) : void = let var stat_parent: stat? // uninitialized val rtn = lstat_err ("..", stat_parent) in if rtn >= 0 then let prval () = opt_unsome (stat_parent) val rtn = chdir ".." val term = if :(stat_parent: stat) => (rtn = ~1 andalso errno_is_ENOENT ()) then true else SAME_INODE (stat, stat_parent) // end of [val] in case+ 0 of | _ when term => push_pathlist (lstrs, "/") // for leading "/" | _ when rtn = ~1 => (nerr := nerr + 1) // loop exists abnormally | _ (*continue*) => let val (pfopt_dir | p_dir) = opendir_err (".") in if p_dir > null then let prval Some_v pf_dir = pfopt_dir val ents = dirent_stream_vt_make_DIR (pf_dir | p_dir) val found = loop_dir (ents, stat, lstrs, nent) in if found > 0 then let val () = stat := stat_parent in loop (pf_fd | fd, stat, lstrs, nent+1, nerr) end else begin errno_set (ENOENT); nerr := nerr + 1 end // end of [if] end else let prval None_v () = pfopt_dir in nerr := nerr + 1 // loop exits abnormally end (* end of if *) end (* end of [_(*continue*)] *) end else let prval () = opt_unnone {stat} (stat_parent) in nerr := nerr + 1 // loop exits abnormally end // end of [if] end (* end of [loop] *) } // end of [val] val _err = fchdir (pf_fd | fd) val () = assert_errmsg (_err <> ~1, #LOCATION) val () = close_exn (pf_fd | fd) val () = if (nerr > 0) then (free_pathlist lstrs; lstrs := list_vt_nil) val lstrs = lstrs in case+ lstrs of | list_vt_cons _ => let val () = fold@ lstrs val path = stringlst_concat (__cast lstrs) where { extern castfn __cast (lstrs: !pathlist): List string } // end of [val] val () = free_pathlist (lstrs) in path end // end of [list_vt_cons] | ~list_vt_nil () => strptr_null () end // end of [getcwdx_main] (* ****** ****** *) implement getcwdx () = let var st: stat? // uinitialized val (pfopt_fd | fd) = open_flag_err (".", O_RDONLY) in if fd <> ~1 then let prval open_v_succ pf_fd = pfopt_fd val rtn = lstat_err (".", st) in if rtn >= 0 then let prval () = opt_unsome (st) in getcwdx_main (pf_fd | fd, st) end else let prval () = opt_unnone {stat} (st) in close_exn (pf_fd | fd); strptr_null () end // end of [if] end else let prval open_v_fail () = pfopt_fd in strptr_null () end // end of [if] end (* end of [getcwdx] *) (* ****** ****** *) implement main () = let val [l:addr] path = getcwdx () prval () = addr_is_gtez {l} () in if strptr_isnot_null path then let val () = printf ("%s\n", @(__cast path)) where { extern castfn __cast {l:agz} (x: !strptr l): string } val () = strptr_free (path) in exit (EXIT_SUCCESS) end else let prval () = strptr_free_null (path) in exit (EXIT_FAILURE) end // end of [if] end (* end of [main] *) (* ****** ****** *) (* end of [AUP_3_6_4.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_1_7.dats0000664000175000017500000000371112223166161020463 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 615 - 618 // section 9.1.7: Signal Handlers // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" // perror staload "libc/SATS/stdlib.sats" // _Exit staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) %{^ volatile sig_atomic_t theSignum ; ATSinline() ats_int_type theSignum_get() { return theSignum ; } ATSinline() ats_void_type theSignum_set(int x) { theSignum = x ; return ; } %} // end of [%{^] extern fun theSignum_get (): int = "theSignum_get" extern fun theSignum_set (x: int): void = "theSignum_set" fun handler (sgn: signum_t): void = () where { val () = theSignum_set ($UNSAFE.cast2int(sgn)) } // end of [val] (* ****** ****** *) implement main () = () where { var act: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] val () = act.sa_handler := (sighandler)handler val () = act.sa_flags := SA_RESTART // HX: even this cannot affect [sleep]! val err = sigaction_null (SIGINT, act) val () = if err < 0 then (perror "sigaction"; exit (EXIT_FAILURE)) val () = printf ("Type CTRL-C in the next 10 seconds.\n", @()) val time0 = time_get () val () = assertloc ($UNSAFE.cast2lint(time0) >= 0L) val _leftover = sleep (10u) val time1 = time_get () val () = assertloc ($UNSAFE.cast2lint(time1) >= 0L) val () = printf ("Slept for %ld seconds.\n", @($UNSAFE.cast2lint(difftime(time1,time0)))) val sgn = theSignum_get () val () = if (sgn > 0) then printf ("Got signal(%d).\n", @(sgn)) else printf ("Got no signal.\n", @()) // end of [if] } // end of [main] (* ****** ****** *) (* end of [AUP_9_1_7.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_2_2_2.dats0000664000175000017500000000770212223166161020677 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 208 - 213 // section 4.2.2: Nonblocking Input // (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) fun setblock {fd:int} ( fd: int fd, block: bool ) : bool = let val f = __getfl (fd) where { extern fun __getfl (fd: int): flag_t = "atslib_fcntl_getfl" } val i = int_of_uint(uint_of_flag (f)) in if i >= 0 then let val f = if block then (f land ~O_NONBLOCK) else (f lor O_NONBLOCK) val err = __setfl (fd, f) where { extern fun __setfl (fd: int, f: flag_t): int = "atslib_fcntl_setfl" } // end of [val] in if err >= 0 then true else false end else false end // end of [setblock] (* ****** ****** *) fun msetblock {n:nat} (fds: &(@[int][n]), n: int n): int = let var nerr: int = 0 var i: natLte n val () = for (i := 0; i < n; i := i+1) let val fd = fds.[i] val fd = int1_of (fd) val res = setblock (fd, false) // inefficient in if ~res then nerr := nerr + 1 end // end of [val] in nerr (* 0/neg : succ/fail *) end // end of [msetblock] %{^ #define atslib_read1(fd, c) read(fd, c, 1) %} // end of [%{^] fun readany {n:nat} ( fds: &(@[int][n]), n: int n, which: &int ) : int = let // extern fun read1 (fd: int, c: &char): ssize_t = "mac#atslib_read1" // var nerr: int = 0 var i: natLte n = 0 var c:char = '\0' val () = while (true) let val () = case+ 0 of | _ when i < n => let val () = c := '\0' val nread = read1 (fds.[i], c) val nread = int_of_ssize (nread) val nread = int1_of_int (nread) in case+ 0 of | _ when nread >= 0 => (which := i; break) | _ (*nread = -1*) => ( if (errno_get () = EAGAIN) then (i := i+1; continue) else (nerr := nerr+1; break) ) // end of [_] end // end of [_ when ...] | _ => let val _leftover = sleep (1u) in i := 0 end // end of [_] // end of [val] in // nothing end // end of [val] in if nerr > 0 then ~1 else (int_of)c end // end of [readany] (* ****** ****** *) fun test_readany () = let var !p_fds = @[int](~1, ~1) var nerr: int = 0 extern prfun __leak {v:view} (pf: v): void val (pf | fd) = open_flag_err ("/dev/tty", O_RDWR) val () = if fd < 0 then let val () = prerr "test_readany: open: 0\n" in nerr := nerr + 1 end // end of [val] prval () = __leak (pf) val () = p_fds->[0] := fd val path = "/dev/pts/3" // HX: change may be needed val (pf | fd) = open_flag_err (path, O_RDWR) val () = if fd < 0 then let val () = prerr "test_readany: open: 1\n" in nerr := nerr + 1 end // end of [val] prval () = __leak (pf) val () = p_fds->[1] := fd // val _err = msetblock (!p_fds, 2) // val () = if (nerr = 0) then let var which: int = ~1 val () = while (true) let val c = readany (!p_fds, 2, which) val () = if c > 0 then let val c = char_of_int(c) val c = (if char_isprint (c) then c else '?'): char val () = printf ("Got %c from terminal %d\n", @(c, which)) in continue end // end of [val] val () = if (c = 0) then printf ("EOF from terminal %d\n", @(which)) else nerr := nerr+1 // end of [val] in break end // end of [val] in // nothing end // end of [val] // var i: natLte 2 val () = for (i := 0; i < 2; i := i+1) let extern fun __close (fd: int): void = "atslib_close_exn" val fd = p_fds->[i] in if fd >= 0 then __close (fd) end // end of [val] // val () = if (nerr > 0) then prerrf ("test_readany: failed.\n", @()) // in // nothing end // end of [test_readany] (* ****** ****** *) implement main () = () where { val () = test_readany () } // end of [main] (* ****** ****** *) (* end of [AUP_4_2_2_2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_7_5.dats0000664000175000017500000000307512223166161020472 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 660 - 663 // section 9.7.5: Realtime Clocks // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef time_t = $T.time_t staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/time.sats" (* ****** ****** *) macdef _2lint(x) = $UNSAFE.cast2lint ,(x) fun test_clocks (): void = () where { var tm: time_t val yn = time_get_and_set (tm) val () = assertloc (yn) prval () = opt_unsome {time_t} (tm) val () = printf ("time() = %ld secs.\n", @(_2lint(tm))) var ts: timespec val () = printf ("CLOCK_REALTIME:\n", @()) val err = clock_gettime (CLOCK_REALTIME, ts) val () = assertloc (err >= 0) prval () = opt_unsome {timespec} (ts) val () = printf ("gettime() = %ld.%09ld secs.\n", @(_2lint(ts.tv_sec), _2lint(ts.tv_nsec))) val err = clock_getres (CLOCK_REALTIME, ts) val () = assertloc (err >= 0) prval () = opt_unsome {timespec} (ts) val () = printf ("getres() = %ld.%09ld secs.\n", @(_2lint(ts.tv_sec), _2lint(ts.tv_nsec))) } // end of [clocks] (* ****** ****** *) implement main () = () where { val () = test_clocks () } // end of [main] (* ****** ****** *) (* end of [AUP_9_7_5.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_2_4_3.dats0000664000175000017500000000664312223166161020462 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // book: AUP (2nd edition), pages 80 - 85 (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/random.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) #define LOCKDIR "/tmp/" %{^ #define LOCKDIR "/tmp/" %} // end of [%{^] (* ****** ****** *) #define MAXTRIES 10 #define NAPLENGTH 2 (* ****** ****** *) %{^ static ats_ptr_type lockpath (ats_ptr_type name) { static char path[100] ; if (snprintf (path, sizeof(path), "%s%s", LOCKDIR, (char*)name) > sizeof(path)) return (char*)0; return path ; } // end of [lockpath] %} // end of [%{^] extern fun lockpath (name: string): Stropt = "lockpath" (* ****** ****** *) extern fun lock (name: string): bool extern fun unlock (name: string): bool (* ****** ****** *) macdef errno_is_EAGAIN () = (errno_get () = EAGAIN) macdef errno_is_EEXIST () = (errno_get () = EEXIST) (* ****** ****** *) implement lock (name) = let val path = lockpath (name) val ans = stropt_is_some (path) in if ans then let val path = stropt_unsome (path) val flag = O_WRONLY lor O_CREAT lor O_EXCL val err = loop (path, flag, 0) where { fun loop ( path: string, flag: flag_t, n: int ) : int(*err*) = let val (pf_fdopt | fd) = open_flag_err (path, flag) in if (fd >= 0) then let prval open_v_succ (pf_fd) = pf_fdopt val () = close_loop_exn (pf_fd | fd) in 0(*success*) end else let prval open_v_fail () = pf_fdopt in if errno_is_EEXIST () then (if n >= MAXTRIES - 1 then (errno_set EAGAIN; ~1) else loop (path, flag, n+1)) else ~1(*failure*) end (* end of [if] *) end // end of [loop] } // end of [val] in if err = 0 then true else false end else false end // end of [lock] (* ****** ****** *) implement unlock (name) = let val path = lockpath (name) val ans = stropt_is_some (path) in if ans then let val path = stropt_unsome (path) val err = unlink (path) in if err <> ~1 then true else false end else false end // end of [unlock] (* ****** ****** *) fn sleep (i: int) = let val _remaining = sleep ((uint1_of_int)i) in () end // end of [sleep] fn testlock (): void = loop (1) where { #define N 4 #define NAME "accounts" fun loop (i: natLte N): void = let val status = (if lock (NAME) then let val pid = getpid () val () = printf ("Process %ld acquired the lock\n", @(lint_of_pid pid)) val _leftover = sleep (randint 5 + 1); // work on the accounts val ans = unlock (NAME) val () = if ~ans then (prerr "Exit: [testlock] failed"; exit 1) in 1(* succ *) end else let val () = if errno_is_EAGAIN () then let val pid = getpid () val () = printf ("Process %ld tired of busy waiting\n", @(lint_of_pid pid)) val () = errno_reset () in // nothing end else (prerr "Exit: [testlock] failed"; exit 1) in 0(* fail *) end) : natLte 2 // end of [val] val _leftover = sleep (randint 5 + 5) // work on somthing else val i = i + status in if i <= N then loop (i) else () end // end of [loop] } // end of [testlock] (* ****** ****** *) implement main () = testlock () (* ****** ****** *) (* end of [AUP_2_4_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_4.dats0000664000175000017500000000601012223166161020227 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 292 - 296 // section 5.4: Implementing a Shell (Version 1) // (* ****** ****** *) staload "libc/SATS/stdlib.sats" // for getenv staload "libc/SATS/unistd.sats" // for environ_get_arrsz (* ****** ****** *) typedef ptrarr0 (n:int) = @[ptr?][n] dataview getargs_v (n0:int, l:addr, int) = | {n:nat | n < n0} getargs_v_succ (n0, l, n) of ( ptrarr (n) @ l, ptrarr (n) @ l - ptrarr0 (n0) @ l ) // end of [getargs_v_succ] | getargs_v_fail (n0, l, ~1) of (ptrarr0 (n0) @ l) // end of [getargs_v] extern fun getargs {n0:nat} {l:addr} ( pfargv: ptrarr0 (n0) @ l | pargv: ptr l, n0: int n0, iseof: &bool? >> bool ) : [n:int] (getargs_v (n0, l, n) | int n) = "mac#getargs" // end of [getargs] (* ****** ****** *) fun printenv {n:pos} ( argc: int n, argv: &(@[string][n]) ) : void = let var m: size_t // uninitialized val (pf, fpf | p) = environ_get_arrsz (m) stavar m: int val m: size_t m = m var i: sizeLte m val _0 = size1_of_int1 (0) val () = for (i := _0; i < m; i := i+1) (printf("%s\n", @(!p.[i]))) // end of [val] prval () = fpf (pf) in // nothing end // end of [printenv] (* ****** ****** *) fun assgnenv {n:pos} (argc: int n, argv: &(@[string][n])): void = let var nerr: int = 0 val () = while (true) let val () = ( if argc <= 2 then (nerr := 1; break; assertfalse()) ) : [n >= 3] void val () = if (setenv (argv.[1], argv.[2], 1(*overwritten*)) < 0) then nerr := 2 // end of [val] in break end // end of [val] val () = (case+ nerr of | 1 => printf ("Incorrect command format for \n", @()) | 2 => printf ("[setenv] failed\n", @()) | _ => () ) : void // end of [val] in // nothing end // end of [assgnenv] (* ****** ****** *) %{^ void execute ( int argc, char *argv[] ) { execvp (argv[0], &argv[0]) ; printf ("Can't execute\n") ; return ; } %} // end of [%{^] extern fun execute {n:pos} (argc: int n, argv: &(@[string][n])): void = "mac#execute" // end of [execute] implement main () = while (true) let #define MAXARG 32 var !pargv with pfargv = @[ptr?][MAXARG]() val () = printf ("@ ", @()) var iseof: bool // uninitialized val (pfargs | argc) = getargs (pfargv | pargv, MAXARG, iseof) // val () = if argc >= 0 then let prval getargs_v_succ (pf, fpf) = pfargs prval (pf1, fpf1) = ptrarr_takeout{string} (pf) val () = if (argc > 0) then let val arg0 = pargv->[0] in case+ 0 of | _ when arg0 = "print" => printenv (argc, !pargv) | _ when arg0 = "assgn" => assgnenv (argc, !pargv) | _ => execute (argc, !pargv) end // end of [val] prval () = pf := fpf1 (pf1) prval () = pfargv := fpf (pf) in // nothing end else let prval getargs_v_fail (pf) = pfargs prval () = pfargv := pf in // nothing end // end of [val] // in if iseof then exit (EXIT_SUCCESS) end // end of [main] (* ****** ****** *) (* end of [AUP_5_4.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_2_14.dats0000664000175000017500000000555712223166161020324 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // book: AUP (2nd edition), pages 108 - 110 // section: 2.14: pready and pwrite system calls // (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef off_t = $T.off_t staload STDIO = "libc/SATS/stdio.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) extern fun backward2 (path: string): void (* ****** ****** *) %{^ ats_ptr_type __buf_tail (ats_ptr_type p_buf, ats_int_type n) { return ((char*)p_buf) + n ; } /* end of [__buf_tail] */ %} // end of [__buf_tail] (* ****** ****** *) #define BUFSZ 256 fun loop_main {fd:int} ( pf_fd: !fildes_v (fd) | fd: int fd , buf: &bytes BUFSZ, n: natLt BUFSZ , bufc: &bytes 1 , ofs: lint , nerr: &int ) : void = if ofs >= 0L then let val nread = pread (pf_fd | fd, bufc, 1, $T.off_of_lint ofs) val nread = int1_of_ssize1 (nread) in case+ 0 of | _ when nread = 1 => let val b = bufc.[0] val c = char_of_byte (b) val ofs1 = ofs - 1L in if c <> '\n' then begin if n = 0 then (errno_set (E2BIG); nerr := nerr + 1) else ( buf.[n-1] := b; loop_main (pf_fd | fd, buf, n-1, bufc, ofs1, nerr) ) // end of [if] end else let // c = '\n' extern fun __buf_tail (buf: &bytes BUFSZ, n: natLt BUFSZ): string = "__buf_tail" val () = printf ("%s", @(__buf_tail (buf, n))) val n = BUFSZ - 1 in buf.[n-1] := b; loop_main (pf_fd | fd, buf, n-1, bufc, ofs1, nerr) end // end of [if] end (* end of [_ when nread = 1] *) | _ when nread = ~1 => begin nerr := nerr + 1 end // end of [_ when ...] | _ => begin errno_reset (); nerr := nerr + 1 end // end of [_] end else begin // loop exits successfully end // end of [loop_main] (* ****** ****** *) implement backward2 (path) = let val (pf_fd | fd) = open_flag_exn (path, O_RDONLY) var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) var !p_bufc with pf_bufc = @[byte][1]() prval () = pf_bufc := bytes_v_of_b0ytes_v (pf_bufc) val () = p_buf->[BUFSZ-1] := byte_of_int (0) val ofs0 = $T.off_of_lint (0L) val fsize = lseek_exn (pf_fd | fd, ofs0, $T.SEEK_END) val fsize1 = $T.lint_of_off (fsize) - 1L var nerr: int = 0 val () = loop_main (pf_fd | fd, !p_buf, BUFSZ-1, !p_bufc, fsize1, nerr) // (* val () = if (nerr > 0) then begin prerrf ("nerr = %i\n", @(nerr)); $STDIO.perror "backward2"; end // end of [val] // *) val () = close_exn (pf_fd | fd) in // empty end // end of [backward2] (* ****** ****** *) implement main (argc, argv) = let val () = assertloc (argc >= 2) val () = backward2 (argv.[1]) in // nothing end // end of [main] (* ****** ****** *) (* end of [AUP_2_14.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_2_6.dats0000664000175000017500000000412312223166161020460 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 535 - 537 // section 8.2.6: getaddrinfo // (* ****** ****** *) staload "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libc/SATS/netdb.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/socket.sats" staload "libc/arpa/SATS/inet.sats" (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) implement main () = () where { typedef AI = addrinfo(0) var hint: AI val () = ptr_zero (__assert () | hint) where { extern prfun __assert (): NULLABLE (AI) } // end of [val] val () = hint.ai_family := AF_INET val () = hint.ai_socktype := SOCK_STREAM var infop: addrinfoptr val err = getaddrinfo ("www.yahoo.com", "80", hint, infop) val () = if err < 0 then let val (fpf_str | str) = gai_strerror (err) val () = (print "GAI ERROR: "; print str; print_newline ()) prval () = fpf_str (str) in // nothing end // end of [val] val () = assertloc (err = 0) prval () = opt_unsome {addrinfoptr} (infop) val () = loop (infop) where { fun loop {l:addr} (infop: !addrinfoptr l): void = if addrinfoptr_isnot_null (infop) then let val prot = addrinfoptr_get_protocol (infop) val prot = $UNSAFE.cast {int} (prot) val (pf, fpf | p) = addrinfoptr_get_addr_in (infop) val nport = ntohs (uint16_of_in_port_nbo(p->sin_port)) val (fpf_str | str) = inet_ntoa (p->sin_addr) prval () = minus_addback (fpf, pf | infop) val () = ( print str; print " port: "; print nport; print " protocol: "; print prot; print_newline () ) // end of [val] prval () = fpf_str (str) val (fpf1 | infop1) = addrinfoptr_get_next (infop) val () = loop (infop1) prval () = minus_addback (fpf1, infop1 | infop) in // nothing end else () // end of [if] // end of [loop] } // end of [val] val () = freeaddrinfo (infop) } // end of [main] (* ****** ****** *) (* end of [AUP_8_2_6.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/data/0000700000175000017500000000000012223166161017156 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/data/fruits.txt0000664000175000017500000000012512223166161021245 0ustar hwxihwxipeach apple orange strawberry plum pear cherry banana apricot tomato pineapple mango ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_1_1.dats0000664000175000017500000000321412223166161020453 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 601 - 603 // section 9.1.1: Introduction to Signals // (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" // perror staload "libc/SATS/stdlib.sats" // _Exit staload "libc/SATS/unistd.sats" (* ****** ****** *) fun handler (sgn: signum_t): void = () where { val (pf_stdout | ()) = stdout_fildes_view_get () val msg = "Got signal\n" val nmsg = string_length (msg) val (pf, fpf | p_msg) = __cast (msg) where { extern castfn __cast {n:nat} (x: string n):<> [l:addr] (bytes(n) @ l, bytes(n) @ l - void | ptr l) // end of [extern] } // end of [val] val _err = write_err // HX: [printf] is unsafe!!! (pf_stdout | STDOUT_FILENO, !p_msg, nmsg) prval () = fpf (pf) val () = stdout_fildes_view_set (pf_stdout | (*none*)) val () = _Exit (EXIT_FAILURE) } // end of [val] (* ****** ****** *) implement main () = () where { var act: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] val () = act.sa_handler := (sighandler)handler val err = sigaction_null (SIGINT, act) val () = if err < 0 then (perror "sigaction"; exit (EXIT_FAILURE)) var i: int val () = for (i := 1; ; i := i+1) let val _leftover = sleep (1u); val () = printf ("%d\n", @(i)) in // nothing end // end of [val] } // end of [main] (* ****** ****** *) (* end of [AUP_9_1_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_7_2.dats0000664000175000017500000000663012223166161020467 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 653 - 656 // section 9.7.2: sleep System Call // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" macdef int_of_pid = $T.int_of_pid staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) // // HX: splitting the code into [mysleep0] and [mysleep1] makes // the logic considerably easy to follow // (* ****** ****** *) fun mysleep0 {n:nat} (nsec: uint n): uInt = let // var set: sigset_t and set2: sigset_t val err = sigemptyset (set) val () = assertloc (err = 0) prval () = opt_unsome {sigset_t} (set) val err = sigaddset (set, SIGALRM) val () = assertloc (err >= 0) val err = sigprocmask (SIG_BLOCK, set, set2) // SIGALRM is blocked val () = assertloc (err >= 0) prval () = opt_unsome {sigset_t} (set2) // var act: sigaction and act2: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] // HX: note that SIGUSR1 kills the process if there is no handler for it val () = act.sa_handler := sighandler(lam (sgn:signum_t): void => ()) val err = sigaction (SIGALRM, act, act2) val () = assertloc (err = 0) prval () = opt_unsome {sigaction} (act2) // val (pf_alarm | _) = alarm_set (nsec) // val () = set := set2 val err = sigdelset (set, SIGALRM) val () = assertloc (err = 0) val rtn = sigsuspend (set) // there is really no need for error-checking! // val err = sigaction_null (SIGALRM, act2) val () = assertloc (err = 0) val err = sigprocmask_null (SIG_SETMASK, set2) val () = assertloc (err = 0) // in alarm_cancel (pf_alarm | (*none*)) end // end [mysleep0] (* ****** ****** *) fun mysleep1 {n:nat} (nsec: uint n): uInt = let val (pf0 | leftover0) = alarm_set (0U) prval () = alarm_v_elim (pf0) in if leftover0 = 0U then mysleep0 (nsec) else if leftover0 <= nsec then let val diff = nsec - leftover0 val leftover1 = mysleep0 (leftover0) val () = if leftover1 > 0U then let val (pf_alarm | _) = alarm_set (leftover1) prval () = __assert (pf_alarm) where { extern prfun __assert {i:nat} (pf: alarm_v i): void } // end of [prval] in // nothing end // end of [val] in diff + leftover1 end else let val diff = leftover0 - nsec val leftover1 = mysleep0 (nsec) val (pf_alarm | _) = alarm_set (diff + leftover1) prval () = __assert (pf_alarm) where { extern prfun __assert {i:nat} (pf: alarm_v i): void } // end of [prval] in leftover1 end // end of [if] end // end of [mysleep1] (* ****** ****** *) implement main () = () where { val leftover = mysleep1 (1U) val () = (print "leftover(0) = "; print leftover; print_newline ()) // val (pf_alarm | _) = alarm_set (4U) // val leftover = mysleep1 (2U) val () = (print "leftover(0) = "; print leftover; print_newline ()) val leftover = mysleep1 (3U) val () = (print "leftover(1) = "; print leftover; print_newline ()) // val _ = alarm_cancel (pf_alarm | (*none*)) } // end of [main] (* ****** ****** *) (* end of [AUP_9_7_2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_8.dats0000664000175000017500000000774412223166161020251 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 248 - 249 // section 4.8: Full-Screen Applications // (* ****** ****** *) staload "libc/SATS/curses.sats" staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) %{^ #define atslib_read1(c) read(STDIN_FILENO, c, 1) %} // end of [%{^] extern fun read1 ( pf: !fildes_v (STDIN_FILENO) | c: &char ) : ssize_t = "mac#atslib_read1" // end of [read1] fun getch (pf: !fildes_v (STDIN_FILENO) | c: &char): int = let val nread = read1 (pf | c) val nread = ssize1_of_ssize (nread) val nread = int1_of_ssize1 (nread) in case+ 0 of | _ when nread <= 0 => let val () = if nread = 0 then errno_set (errno_of_int(0)) in ERR end // end of [_ when ...] | _ (*nread = 1*) => OK end // end of [getch] (* ****** ****** *) fun mainloop ( pf: !fildes_v (STDIN_FILENO) | (*none*) ) : int(*0/1:succ/fail*) = let var c: char = '\000' var nerr: int = 0 val () = while (true) let val _err = clear () val () = if _err = ERR then nerr := nerr+1 (* val () = printf ("[clear] is done\n", @()) *) // val _err = mvaddstr (2, 9, "What do you want to do?") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (3, 9, "1. Check out tape/DVD") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (4, 9, "2. Reserve tape/DVD") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (5, 9, "3. Register new member") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (6, 9, "4. Search for title/actor") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (7, 9, "5. Quit") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = mvaddstr (9, 9, "(Type item number to continue)") val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) val _err = refresh () // HX: otherwise, nothing is shown val () = if _err = ERR then (nerr := nerr+1; break; assertfalse ()) // val _err = getch (pf | c) val () = if _err = ERR then nerr := nerr+1 val () = (case+ 0 of | _ when ('1' <= c andalso c <= '4') => let val _err = clear () val () = if _err = ERR then nerr := nerr+1 val [l:addr] str = sprintf ("You typed %c", @(c)) val _err = mvaddstr (4, 9, __cast str) where { extern castfn __cast (x: !strptr l):<> string } // end of [val] val () = strptr_free (str) val () = if _err = ERR then nerr := nerr+1 val _err = mvaddstr (9, 9, "(Press any key to continue)") val () = if _err = ERR then nerr := nerr+1 val _err = refresh () // HX: otherwise, change is not shown val () = if _err = ERR then nerr := nerr+1 val _err = getch (pf | c) val () = if _err = ERR then nerr := nerr+1 in break end // end of [_ when ...] | _ when c = '5' => break | _ => let val _err = beep () val () = if _err = ERR then nerr := nerr+1 in // nothing end // end of [_] ) : void // end of [val] in // nothing end // end of [val] (* val () = (print "_err = "; print _err; print_newline ()) *) in if nerr > 0 then 1 else 0 end // end of [mainloop] (* ****** ****** *) implement main () = () where { val _ptr = initscr () val () = assert_errmsg (_ptr > null, #LOCATION) val _err = raw () val () = assert_errmsg (_err <> ERR, #LOCATION) val (pf_fd | ()) = stdin_fildes_view_get () val status = mainloop (pf_fd | (*none*)) val () = stdin_fildes_view_set (pf_fd | (*none*)) val _err = clear () val _err = refresh () val _err = endwin () val () = exit (status) } // end of [main] (* ****** ****** *) (* end of [AUP_4_8.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_8_1_1.dats0000664000175000017500000000524412223166161020706 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 578 - 585 // section 8.8.1: Host Functions // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" staload _(*UNSAFE*) = "prelude/DATS/unsafe.dats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/netdb.sats" staload "libc/SATS/string.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/arpa/SATS/inet.sats" (* ****** ****** *) fun display_hostent (h: &hostent): void = let val (fpf_name | name) = hostent_get_name (h) val () = printf ( "name: %s; type: %d; len: %d\n" , @($UNSAFE.castvwtp1{string} (name), h.h_addrtype, h.h_length) ) // end of [printf] prval () = fpf_name (name) // val (pf, fpf | p) = hostent_get_aliases (h) val n = ptrarr_size (!p) prval (pf1 , fpf1) = ptrarr_takeout{string} (pf) val () = loop (!p, n, 0) where { fun loop {n,i:nat | i <= n} .. (A: &(@[string][n]), n: size_t n, i: size_t i): void = if i < n then let val () = printf ("\t%s\n", @(A.[i])) in loop (A, n, i+1) end else () // end of [loop] // end of [loop] } // end of [val] prval () = pf := fpf1 (pf1) prval () = fpf (pf) // val () = if (h.h_addrtype = $UNSAFE.cast2int(AF_INET)) then let // val (pf, fpf | p) = hostent_get_addr_list (h) val n = ptrarr_size (!p) prval (pf1 , fpf1) = ptrarr_takeout{Ptr1} (pf) val () = loop (!p, n, 0) where { fun loop {n,i:nat | i <= n} .. (A: &(@[Ptr1][n]), n: size_t n, i: size_t i): void = if i < n then let val (fpf_addr | addr) = inet_ntoa ($UNSAFE.ptrget(A.[i])) val () = printf ("\t%s\n", @($UNSAFE.castvwtp1{string}(addr))) prval () = fpf_addr (addr) in loop (A, n, i+1) end else () // end of [loop] // end of [loop] } // end of [val] prval () = pf := fpf1 (pf1) prval () = fpf (pf) // in // nothing end // end of [val] // in // nothing end // end of [display_hostent] (* ****** ****** *) fun hostdb (): void = let val (pf | ()) = sethostent (true) val () = while (true) let val (pfopt | p) = gethostent (pf | (*none*)) in if p > null then let prval Some_v @(pf1, fpf1) = pfopt val () = display_hostent (!p) prval () = fpf1 (pf1) in continue end else let prval None_v () = pfopt in break end // end of [if] end // end of [while] val () = endhostent (pf | (*none*)) in // nothing end // end of [hostdb] (* ****** ****** *) implement main () = () where { // val () = hostdb () // } // end of [main] (* ****** ****** *) (* end of [AUP_8_8_1_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/Makefile0000664000175000017500000001653612223166161017734 0ustar hwxihwxi###### # # Makefile file for some examples translated from the book: # Advanced UNIX Programming (2nd edition) by Marc Rochkind # ###### # # Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) # Start Time: Summer, 2009 # Second Time: Fall, 2010 # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all: checkall ###### checkall: compall cleanall ###### compall:: testlock testlock: AUP_2_4_3.dats; $(ATSCC) -o $@ $^ compall:: backward backward: AUP_2_13.dats $(ATSCC) -o $@ $^ && ./$@ "AUP_2_13.dats" compall:: backward2 backward2: AUP_2_14.dats $(ATSCC) -o $@ $^ && ./$@ "AUP_2_14.dats" ####### compall:: pathnames pathnames: AUP_3_4.dats; $(ATSCC) -o $@ $^ && ./$@ compall:: longls longls: AUP_3_5.dats; $(ATSCC) -o $@ $^ && ./$@ compall:: getcwdx getcwdx: AUP_3_6_4.dats; $(ATSCC) -o $@ $^ && ./$@ ####### compall:: test421 test421: AUP_4_2_1.dats; $(ATSCC) -o $@ $^ compall:: test4221 test4221: AUP_4_2_2_1.dats; $(ATSCC) -o $@ $^ compall:: test4222 test4222: AUP_4_2_2_2.dats; $(ATSCC) -o $@ $^ compall:: test423 test423: AUP_4_2_3.dats; $(ATSCC) -o $@ $^ compall:: test435 test435: AUP_4_3_5.dats; $(ATSCC) -o $@ $^ compall:: test47 test47: AUP_4_7.dats; $(ATSCC) -o $@ $^ && ./test47 compall:: test48 test48: AUP_4_8.dats; $(ATSCC) -o $@ $^ -lcurses ####### compall:: test52 test52: AUP_5_2.dats; $(ATSCC) -o $@ $^ && ./test52 ####### getargs.o: utils/getargs.c $(ATSCC) -Wall -c -o $@ $< compall:: aupsh1 aupsh1: AUP_5_4.dats getargs.o $(ATSCC) -o $@ $< getargs.o compall:: aupsh2 aupsh2: AUP_5_6.dats getargs.o $(ATSCC) -o $@ $< getargs.o compall:: aupsh3 aupsh3: AUP_5_10.dats getargs.o $(ATSCC) -o $@ $< getargs.o ####### compall:: test511 test511: AUP_5_11.dats $(ATSCC) -Wall -o $@ AUP_5_11.dats \ && ./test511 ####### compall:: aupnice aupnice: AUP_5_15.dats $(ATSCC) -Wall -o $@ $< ####### compall:: test5173 test5173: AUP_5_17_3.dats $(ATSCC) -D_ATS_MULTITHREAD -Wall -o $@ AUP_5_17_3.dats -lpthread \ && ./test5173 ####### errinfo.o: utils/errinfo.sats utils/errinfo.dats $(ATSCC) -IATS utils -I utils -Wall -c -o $@ utils/errinfo.dats compall:: test631 test631: AUP_6_3_1.dats errinfo.o $(ATSCC) -I utils -Wall -o $@ $< errinfo.o && ./test631 compall:: test65 test65: AUP_6_5.dats errinfo.o $(ATSCC) -I utils -Wall -o $@ $< errinfo.o && ./test65 ####### compall:: test811 test811: AUP_8_1_1.dats; $(ATSCC) -I utils -Wall -o $@ $< && ./test811 compall:: test813 test813: AUP_8_1_3.dats; $(ATSCC) -I utils -Wall -o $@ $< compall:: test814 test814: AUP_8_1_4.dats; $(ATSCC) -I utils -Wall -o $@ $< && ./test814 compall:: test823 test823: AUP_8_2_3.dats; $(ATSCC) -I utils -Wall -o $@ $< && ./test823 compall:: test826 test826: AUP_8_2_6.dats; $(ATSCC) -I utils -Wall -o $@ $< && ./test826 compall:: test83 test83: AUP_8_3.dats; $(ATSCC) -D_XOPEN_SOURCE -Wall -o $@ $< && ./test83 compall:: test8811 test8811: AUP_8_8_1_1.dats; $(ATSCC) -Wall -o $@ $< && ./test8811 compall:: test8812 test8812: AUP_8_8_1_2.dats; $(ATSCC) -Wall -o $@ $< && ./test8812 ####### compall:: test911 test911: AUP_9_1_1.dats; $(ATSCC) -Wall -o $@ $< compall:: test917 test917: AUP_9_1_7.dats; $(ATSCC) -Wall -o $@ $< compall:: test923 test923: AUP_9_2_3.dats; $(ATSCC) -Wall -o $@ $< && ./test923 compall:: test971 test971: AUP_9_7_1.dats; $(ATSCC) -Wall -o $@ $< compall:: test972 test972: AUP_9_7_2.dats; $(ATSCC) -Wall -o $@ $< && ./test972 compall:: test974 test974: AUP_9_7_4.dats; $(ATSCC) -Wall -o $@ $< compall:: test975 # it needs [clock_gettime] and [clock_getres] test975: AUP_9_7_5.dats; $(ATSCC) -Wall -o $@ $< -lrt && ./test975 ####### xref:: ; $(ATSOPT) --posmark_xref=XREF -d \ $(ATSHOME)/utils/xref/ats_prelude_xref.dats > /dev/null xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_2_4_3.dats > AUP_2_4_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_2_13.dats > AUP_2_13_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_2_14.dats > AUP_2_14_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_3_4.dats > AUP_3_4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_3_5.dats > AUP_3_5_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_3_6_4.dats > AUP_3_6_4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_2_1.dats > AUP_4_2_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_2_2_1.dats > AUP_4_2_2_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_2_2_2.dats > AUP_4_2_2_2_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_2_3.dats > AUP_4_2_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_3_5.dats > AUP_4_3_5_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_7.dats > AUP_4_7_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_4_8.dats > AUP_4_8_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_2.dats > AUP_5_2_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_4.dats > AUP_5_4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_6.dats > AUP_5_6_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_10.dats > AUP_5_10_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_11.dats > AUP_5_11_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_15.dats > AUP_5_15_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_5_17_3.dats > AUP_5_17_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_6_3_1.dats > AUP_6_3_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_6_5.dats > AUP_6_5_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_1_1.dats > AUP_8_1_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_1_3.dats > AUP_8_1_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_1_4.dats > AUP_8_1_4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_2_3.dats > AUP_8_2_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_2_6.dats > AUP_8_2_6_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_3.dats > AUP_8_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_8_8_1_1.dats > AUP_8_8_1_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_1_1.dats > AUP_9_1_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_1_7.dats > AUP_9_1_7_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_2_3.dats > AUP_9_2_3_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_7_1.dats > AUP_9_7_1_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_7_2.dats > AUP_9_7_2_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_7_4.dats > AUP_9_7_4_dats.html xref:: ; $(ATSOPT) --posmark_xref=XREF -d AUP_9_7_5.dats > AUP_9_7_5_dats.html ###### RMF = rm -f ####### clean:: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o $(RMF) MySocket $(RMF) errinfo.o $(RMF) getargs.o cleanall:: clean $(RMF) ./*_?ats.html $(RMF) ./XREF/*.html cleanall:: $(RMF) testlock $(RMF) backward $(RMF) backward2 $(RMF) pathnames $(RMF) longls $(RMF) getcwdx cleanall:: $(RMF) test421 $(RMF) test4221 $(RMF) test4222 $(RMF) test423 $(RMF) test435 $(RMF) test47 $(RMF) test48 cleanall:: $(RMF) test52 $(RMF) aupsh1 $(RMF) aupsh2 $(RMF) aupsh3 $(RMF) test511 $(RMF) aupnice $(RMF) test5173 cleanall:: $(RMF) test631 $(RMF) test65 cleanall:: $(RMF) test811 $(RMF) test813 $(RMF) test814 $(RMF) test823 $(RMF) test826 $(RMF) test83 $(RMF) test8811 $(RMF) test8812 cleanall:: $(RMF) test911 $(RMF) test917 $(RMF) test923 $(RMF) test971 $(RMF) test972 $(RMF) test974 $(RMF) test975 ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_2_2_1.dats0000664000175000017500000000537712223166161020704 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 208 - 213 // section 4.2.2: Nonblocking Input // (* ****** ****** *) staload "libc/SATS/errno.sats" // staload "libc/SATS/fcntl.sats" // staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" // (* ****** ****** *) fun setblock {fd:int} ( fd: int fd, block: bool ) : bool = let val f = __getfl (fd) where { extern fun __getfl (fd: int): flag_t = "atslib_fcntl_getfl" } val u = uint_of_flag (f); val i = int_of_uint (u) in if i >= 0 then let val f = if block then (f land ~O_NONBLOCK) else (f lor O_NONBLOCK) val err = __setfl (fd, f) where { extern fun __setfl (fd: int, f: flag_t): int = "atslib_fcntl_setfl" } // end of [val] in if err >= 0 then true else false end else false end // end of [setblock] (* ****** ****** *) #define BUFSZ 1024 #define BUFSZ1 %(BUFSZ-1) #define c2b byte_of_char fun test_setblock () = let var nerr: int = 0 val tstart = time_get () val () = if (lint_of)tstart < 0L then nerr := nerr + 1 val res = setblock (STDIN_FILENO, false) // no blocking! val () = if ~res then nerr := nerr + 1 // val NUL = (c2b)'\000' // val () = // if nerr = 0 then let // var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) // val (pf_fd | ()) = stdin_fildes_view_get () // val () = while (true) let val tnow = time_get () val () = if (lint_of)tnow < 0L then nerr := nerr + 1 val () = if nerr > 0 then break val () = printf ("Waiting for input: (%.0f sec.) ...\n", @(difftime (tnow, tstart))) val n = read_err (pf_fd | STDIN_FILENO, !p_buf, BUFSZ1) val n = int1_of_ssize1 (n) in case+ 0 of | _ when n = 0 => (printf ("EOF\n", @()); break) | _ when n >= 1 => let val () = if !p_buf.[n-1] = (c2b)'\n' then !p_buf.[n-1] := NUL else !p_buf.[n] := NUL val () = printf ( "Read: \"%s\"\n", @(__cast p_buf) ) where { extern castfn __cast (x: ptr):<> string } // end of [val] in // nothing end // end of [_ when ...] | _ (*nread = -1*) => ( if errno_get () = EAGAIN then let val _leftover = sleep(5u) in continue end else (nerr := nerr + 1; break) ) // end of [_] end // end of [val] // val () = stdin_fildes_view_set (pf_fd | (*none*)) // in // nothing end // end of [if] // in if nerr > 0 then (prerr "test_setblock: failed"; prerr_newline ()) end // end of [test_setblock] (* ****** ****** *) #include "prelude/HATS/lmacrodef.hats" // for println (* ****** ****** *) implement main () = () where { val () = test_setblock () } // end of [main] (* ****** ****** *) (* end of [AUP_4_2_2_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_2_1.dats0000664000175000017500000000724612223166161020460 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 204 - 208 // section: 4.2: Reading from a Terminal // (* ****** ****** *) staload "libc/SATS/errno.sats" staload F = "libc/SATS/fcntl.sats" macdef fildes_read_err = $F.read_err staload "libc/SATS/unistd.sats" (* ****** ****** *) #include "prelude/HATS/lmacrodef.hats" // for println (* ****** ****** *) fun getln {n:pos} ( s: &bytes(n), nmax: size_t n, iseof: &bool ) : bool = let val (pf_fd | ()) = stdin_fildes_view_get () val nread = fildes_read_err (pf_fd | STDIN_FILENO, s, nmax - 1) // val res = (case+ 0 of | _ when nread > 0 => true where { val () = iseof := false val nread = size1_of_ssize1 (nread) val nread1 = nread - 1 macdef NUL = byte_of_char('\0') val () = if s.[nread1] = (byte_of_char)'\n' then s.[nread1] := NUL else s.[nread] := NUL // end of [val] } // end of [_ when ...] | _ when nread >= 0 => true where { val () = iseof := true } // end of [_ when ...] | _ (* nread=-1 *) => false ) : bool // end of [val] // val () = stdin_fildes_view_set (pf_fd | (*none*)) in res end // end of [getln] (* ****** ****** *) %{^ #define atslib_read1(c) read(STDIN_FILENO, c, 1) %} // end of [%{^] #define c2b byte_of_char fun getln2 {nmax:pos} ( s: &bytes(nmax), nmax: size_t nmax, iseof: &bool ) : bool = let // extern fun read1 (pf: !fildes_v (STDIN_FILENO) | c: &char): ssize_t = "mac#atslib_read1" (* end of [extern] *) // var c: char = '\000' val (pf_fd | ()) = stdin_fildes_view_get () var n: natLte nmax = 0 val () = iseof := false var res: bool = false val () = while* {n:nat | n < nmax} (n: int n) => (true) let val nread = read1 (pf_fd | c) val nread = int_of_ssize (nread) in case+ 0 of | _ when nread = 0 => let val () = s.[n] := (c2b)'\0' val () = iseof := true val () = res := true in break end // end of [_ when ...] | _ when nread >= 1 => if c = '\n' then let val () = s.[n] := (c2b)'\0' val () = res := true in break end else ( if n+1 < nmax then (s.[n] := c2b(c); n := n+1; continue) else (s.[n] := c2b('\0'); errno_set (E2BIG); break) // end of [if] ) // end of [if] // end of [_ when ...] | _ => break // HX: [read1] failed end // end of [val] val () = stdin_fildes_view_set (pf_fd | (*none*)) in res end // end of [getln2] (* ****** ****** *) #define BUFSZ 1024 implement main () = () where { var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) var iseof: bool = false // val () = println "Please input:" val () = while (true) let val err = getln (!p_buf, BUFSZ, iseof) val () = if ~err then break val () = if iseof then printf ("EOF\n", @()) else printf ("Read: %s\n", @(__cast p_buf)) where { extern castfn __cast (x: ptr): string // cutting a corner } // end of [where] // end of [val] val () = if iseof then break in // nothing end // end of [val] // val () = println "Please input:" val () = while (true) let val err = getln2 (!p_buf, BUFSZ, iseof) val () = if ~err then break val () = if iseof then printf ("EOF\n", @()) else printf ("Read: %s\n", @(__cast p_buf)) where { extern castfn __cast (x: ptr): string // cutting a corner } // end of [where] // end of [val] val () = if iseof then break in // nothing end // end of [val] // } // end of [main] (* ****** ****** *) (* end of [AUP_4_2_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_10.dats0000664000175000017500000001070412223166161020311 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 314 - 315 // section 5.10: Implementing a Shell (Version 3) // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/sys/SATS/wait.sats" staload "libc/SATS/stdlib.sats" // for getenv staload "libc/SATS/unistd.sats" // for environ_get_arrsz (* ****** ****** *) typedef ptrarr0 (n:int) = @[ptr?][n] dataview getargs_v (n0:int, l:addr, int) = | {n:nat | n < n0} getargs_v_succ (n0, l, n) of ( ptrarr (n) @ l, ptrarr (n) @ l - ptrarr0 (n0) @ l ) // end of [getargs_v_succ] | getargs_v_fail (n0, l, ~1) of (ptrarr0 (n0) @ l) // end of [getargs_v] extern fun getargs {n0:nat} {l:addr} ( pfargv: ptrarr0 (n0) @ l | pargv: ptr l, n0: int n0, iseof: &bool? >> bool ) : [n:int] (getargs_v (n0, l, n) | int n) = "mac#getargs" // end of [getargs] (* ****** ****** *) fun printenv {n:pos} ( argc: int n, argv: &(@[string][n]) ) : void = let var m: size_t // uninitialized val (pf, fpf | p) = environ_get_arrsz (m) stavar m: int val m: size_t m = m var i: sizeLte m val _0 = size1_of_int1 (0) val () = for (i := _0; i < m; i := i+1) (printf("%s\n", @(!p.[i]))) // end of [val] prval () = fpf (pf) in // nothing end // end of [printenv] (* ****** ****** *) fun assgnenv {n:pos} (argc: int n, argv: &(@[string][n])): void = let var nerr: int = 0 val () = while (true) let val () = ( if argc <= 2 then (nerr := 1; break; assertfalse()) ) : [n >= 3] void val () = if (setenv (argv.[1], argv.[2], 1(*overwritten*)) < 0) then nerr := 2 // end of [val] in break end // end of [val] val () = (case+ nerr of | 1 => printf ("Incorrect command format for \n", @()) | 2 => printf ("[setenv] failed\n", @()) | _ => () ) : void // end of [val] in // nothing end // end of [assgnenv] (* ****** ****** *) fun quit {n:pos} (argc: int n, argv: &(@[string][n])): void = exit(0) // end of [quit] (* ****** ****** *) extern fun display_status (pid: int, status: int): void implement display_status (pid, status) = let val () = printf ("Process(%i) finished with the status(%i)\n", @(pid, status)) in // nothing end // end of [display_status] (* ****** ****** *) extern fun execute3 {n:pos} (argc: int n, argv: &ptrarr(n)): void // end of [execute3] implement execute3 (argc, argv) = let val pid = fork_err () val pid = int_of_pid (pid) in case+ 0 of | _ when pid = 0 => let // child prval (pf1, fpf1) = ptrarr_takeout{string} (view@(argv)) val arg0 = argv.[0] prval () = view@(argv) := fpf1 (pf1) val _err = execvp (arg0, argv) val () = if _err < 0 then prerr "execute3: child: [execvp] failed\n" in _exit (EXIT_FAILURE) end // end of [_ when ...] | _ when pid > 0 => let // parent var status: int // uinitialized val _err = int_of_pid (wait (status)) val () = if _err >= 0 then let val () = display_status (pid, status) in // nothing end else let val () = prerr "execute3: parent: [wait] failed\n" in (*none*) end // end of [if] in // nothing end // end of [_ when ...] | _ (*pid = -1*) => let val () = prerr "execute3: [fork] failed" in // nothing end // end of [_] end // end of [execute3] (* ****** ****** *) implement main () = while (true) let #define MAXARG 32 var !pargv with pfargv = @[ptr?][MAXARG]() val () = printf ("@ ", @()) var iseof: bool // uninitialized val [n:int] (pfargs | argc) = getargs (pfargv | pargv, MAXARG, iseof) // val () = if argc >= 0 then let var leftover: bool = false prval getargs_v_succ (pf, fpf) = pfargs prval (pf1, fpf1) = ptrarr_takeout{string} (pf) val () = if (argc > 0) then let val arg0 = pargv->[0] in case+ 0 of | _ when arg0 = "quit" => quit (argc, !pargv) | _ when arg0 = "print" => printenv (argc, !pargv) | _ when arg0 = "assgn" => assgnenv (argc, !pargv) | _ => leftover := true end // end of [val] prval () = pf := fpf1 (pf1) val () = if argc > 0 then if leftover then execute3 (argc, !pargv) // end of [val] prval () = pfargv := fpf (pf) in // nothing end else let prval getargs_v_fail (pf) = pfargs prval () = pfargv := pf in // nothing end // end of [val] // in if iseof then exit (EXIT_SUCCESS) end // end of [main] (* ****** ****** *) (* end of [AUP_5_10.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/README0000664000175000017500000000262312223166161017144 0ustar hwxihwxi# # Some AUP examples coded in ATS # ###### AUP_2_4_3: Using a file as a lock AUP_2_13: lseek System Calls AUP_2_14: pread and pwrite System Calls ###### AUP_3_4: Pathnames AUP_3_5: Accessing and Displaying File Metadata AUP_3_6_4: Implementing getcwd (walking up the tree) ###### AUP_4_2_1: Reading from a Terminal AUP_4_2_2_1: Nonblocking Input AUP_4_2_2_2: Nonblocking Input AUP_4_2_3: select System Call AUP_4_3_5: Session-related System Calls AUP_4_7: Terminal-Identification System Calls AUP_4_8: Full-Screen Applications ###### AUP_5_2: Environment (getenv, putenv, setenv, unsetenv) AUP_5_4: Implementing a Shell (Version 1) AUP_5_6: Implementing a Shell (Version 2) AUP_5_10: Implementing a Shell (Version 3) AUP_5_11: Getting User and Group IDs AUP_5_15: Getting and Setting the Priority AUP_5_17_3: Thread Synchronization (Mutexes) ###### AUP_6_3_1: dup and dup2 System Calls AUP_6_5: Two-Way Communication with Unidirectional Pipes ###### AUP_8_1_1: How Sockets Work AUP_8_1_3: Handling Multiple Clients AUP_8_1_4: Byte Order AUP_8_2_3: AF_INET Socket Addresses AUP_8_2_6: getaddrinfo AUP_8_3: Socket Options AUP_8_8_1_1: Host Functions ###### AUP_9_1_1: Introduction to Signals AUP_9_1_7: Signal Handlers AUP_9_2_3: sigsuspend System Call AUP_9_7_1: alarm System Call AUP_9_7_2: sleep System Call AUP_9_7_4: Baisc Interval-Timer System Calls AUP_9_7_5: Realtime Clocks ###### end of [README] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_8_1_2.dats0000664000175000017500000001172712223166161020712 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 578 - 585 // section 8.8.1: Host Functions // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" staload _(*UNSAFE*) = "prelude/DATS/unsafe.dats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/netdb.sats" staload "libc/SATS/string.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket_in.sats" staload "libc/arpa/SATS/inet.sats" (* ****** ****** *) fun display_hostent (h: &hostent): void = let val (fpf_name | name) = hostent_get_name (h) val () = printf ( "name: %s; type: %d; len: %d\n" , @($UNSAFE.castvwtp1{string} (name), h.h_addrtype, h.h_length) ) // end of [printf] prval () = fpf_name (name) // val (pf, fpf | p) = hostent_get_aliases (h) val n = ptrarr_size (!p) prval (pf1 , fpf1) = ptrarr_takeout{string} (pf) val () = loop (!p, n, 0) where { fun loop {n,i:nat | i <= n} .. (A: &(@[string][n]), n: size_t n, i: size_t i): void = if i < n then let val () = printf ("\t%s\n", @(A.[i])) in loop (A, n, i+1) end else () // end of [loop] // end of [loop] } // end of [val] prval () = pf := fpf1 (pf1) prval () = fpf (pf) // val () = if (h.h_addrtype = $UNSAFE.cast2int(AF_INET)) then let // val (pf, fpf | p) = hostent_get_addr_list (h) val n = ptrarr_size (!p) prval (pf1 , fpf1) = ptrarr_takeout{Ptr1} (pf) val () = loop (!p, n, 0) where { fun loop {n,i:nat | i <= n} .. (A: &(@[Ptr1][n]), n: size_t n, i: size_t i): void = if i < n then let val (fpf_addr | addr) = inet_ntoa ($UNSAFE.ptrget(A.[i])) val () = printf ("\t%s\n", @($UNSAFE.castvwtp1{string}(addr))) prval () = fpf_addr (addr) in loop (A, n, i+1) end else () // end of [loop] // end of [loop] } // end of [val] prval () = pf := fpf1 (pf1) prval () = fpf (pf) // in // nothing end // end of [val] // in // nothing end // end of [display_hostent] (* ****** ****** *) fun test_gethostbyname (): void = () where { val NAME = "www.yahoo.com" val (pfopt | p) = gethostbyname (NAME) val () = if (p > null) then let prval Some_v @(pf, fpf) = pfopt val () = display_hostent (!p) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt val () = printf ("The host (%s) is not found!\n", @(NAME)) in (*nothing*) end // end of [val] } // end of [test_gethostbyname] (* ****** ****** *) fun test_gethostbyaddr () = () where { val ADDR = "67.195.160.76" var a: in_addr_nbo_t = inet_addr (ADDR) val () = assertloc ($UNSAFE.cast2int (a) >= 0) val (pfopt | p) = gethostbyaddr (a, sizeof, AF_INET) val () = if (p > null) then let prval Some_v @(pf, fpf) = pfopt val () = display_hostent (!p) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt val () = printf ("The host (%s) is not found!\n", @(ADDR)) in (*nothing*) end // end of [if] } // end of [test_gethostbyaddr] (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" fun fstrnprint {n:nat} (out: FILEref, buf: &bytes(n), n: size_t n): int = let var nerr: int = 0 var i: sizeLte n val _0 = size1_of_int1 (0) val () = for (i := _0; i < n; i := i+1) let val c = char_of_byte (buf.[i]) in if c = '\000' then break else (if ($STDIO.fputc_err (c, out) < 0) then (nerr := nerr + 1; break)) end // end of [val] in nerr end // end of [fstrnprint] (* ****** ****** *) fun test_getnameinfo () = let var sa: sockaddr_in val ADDR = "209.191.122.70" val s_addr = inet_addr (ADDR) val () = assertloc ($UNSAFE.cast2int(s_addr) >= 0) val nport = in_port_nbo_of_int (80) val () = sockaddr_in_init (sa, AF_INET, s_addr, nport) #define NODELEN 256 #define SERVLEN 256 var !p_nodename = @[byte][NODELEN]() var !p_servname = @[byte][SERVLEN]() val err = getnameinfo{sockaddr_in} (sa, sizeof, !p_nodename, NODELEN, !p_servname, SERVLEN, NI_ZERO) val () = if err >= 0 then let val () = fprint (stdout_ref, "node: ") val _err = fstrnprint (stdout_ref, !p_nodename, NODELEN) val () = fprint (stdout_ref, "; service: ") val _err = fstrnprint (stdout_ref, !p_servname, SERVLEN) val () = fprint_newline (stdout_ref) in // nothing end else let val (fpf_str | str) = gai_strerror (err) val () = fprint (stdout_ref, "[getnameinfo] failed: ") val () = fprint_strptr (stdout_ref, str) prval () = fpf_str (str) val () = fprint_newline (stdout_ref) in // nothing end // end of [val] in // nothing end // end of [test_getnameinfo] (* ****** ****** *) implement main () = () where { // val () = test_gethostbyname () val () = test_gethostbyaddr () // val () = test_getnameinfo () // thist a modern version // } // end of [main] (* ****** ****** *) (* end of [AUP_8_8_1_2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_2_3.dats0000664000175000017500000001262712223166161020466 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 628 - 634 // section 9.2.3: sigsuspend System Call // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" macdef int_of_pid = $T.int_of_pid staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) // // HX: any order printing order is possible: child/parent or parent/child // fun try1 () = let val pid = fork_err () val ipid = int_of_pid (pid) in case+ 0 of | _ when ipid = 0 => let val cpid = getpid () val () = printf ("try1: child(%ld)\n", @($UNSAFE.cast2lint(cpid))) in exit (EXIT_SUCCESS) end // end of [_] | _ when ipid > 0 => let val () = printf ("parent(%d)\n", @(ipid)) in // nothing end // end of [ipid > 0] | _ (*ipid=-1*) => let val () = perror ("fork") in exit (EXIT_SUCCESS) end // end of [_] end // end of [try1] (* ****** ****** *) // // this one uses [sigsuspend] // fun try4 () = let typedef T = sigset_t var set: T val err = sigemptyset (set) val () = assertloc (err = 0) prval () = opt_unsome{T} (set) val err = sigaddset (set, SIGUSR1) // SIGUSR1 is blocked val () = assertloc (err = 0) val err = sigprocmask_null (SIG_SETMASK, set) val pid = fork_err () val ipid = int_of_pid (pid) in case+ 0 of | _ when ipid = 0 => let // child // var act: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // HX: note that SIGUSR1 kills the process if there is no handler for it val () = act.sa_handler := sighandler(lam (sgn:signum_t): void => ()) val err = sigaction_null (SIGUSR1, act) val () = assertloc (err = 0) // var suspendset: sigset_t val err = sigfillset (suspendset) val () = assertloc (err = 0) prval () = opt_unsome{T} (suspendset) val err = sigdelset (suspendset, SIGUSR1) // only [SIGUSR1] is allowed val () = assertloc (err = 0) val err = sigsuspend (suspendset) val () = assertloc (err < 0) val () = if (errno_get() = EINTR) then let val cpid = getpid () val () = printf ("try4: child(%ld)\n", @($UNSAFE.cast2lint(cpid))) val () = exit (EXIT_SUCCESS) in // nothing end // end of [val] val () = exit (EXIT_FAILURE) in // nothing end // end of [val] | _ when ipid > 0 => let // parent val () = printf ("parent(%d)\n", @(ipid)) val err = kill (pid, SIGUSR1) val () = assertloc (err = 0) in // nothing end // end of [ipid > 0] | _ (*ipid=-1*) => let val () = perror "fork" in (*nothing*) end // end of [_] end // end of [try4] (* ****** ****** *) // // this one uses [sigwait] // fun try5 () = let var set: sigset_t val err = sigemptyset (set) val () = assertloc (err = 0) prval () = opt_unsome{sigset_t} (set) val err = sigaddset (set, SIGUSR1) val () = assertloc (err = 0) val err = sigprocmask_null (SIG_SETMASK, set) val () = assertloc (err = 0) val pid = fork_err () val ipid = int_of_pid (pid) in case+ 0 of | _ when ipid = 0 => let // child var sgn: signum_t val err = sigwait (set, sgn) // wait for SIGUSR1 val () = assertloc (err = 0) prval () = opt_unsome{signum_t} (sgn) val cpid = getpid () val () = printf ("try5: child(%ld)\n", @($UNSAFE.cast2lint(cpid))) in exit (EXIT_SUCCESS) end // end of [val] | _ when ipid > 0 => let // parent val () = printf ("parent(%d)\n", @(ipid)) val err = kill (pid, SIGUSR1) val () = assertloc (err = 0) in // nothing end // end of [ipid > 0] | _ (*ipid=-1*) => let val () = perror "fork" in (*nothing*) end // end of [_] end // end of [try5] (* ****** ****** *) // // this one uses [pipe] // fun try6 () = let var fd1: int and fd2: int val (pfopt | err) = pipe (fd1, fd2) val () = assertloc (err >= 0) prval Some_v @(pfd1, pfd2) = pfopt val pid = fork_err () val ipid = int_of_pid (pid) in case+ 0 of | _ when ipid = 0 => let // child val () = close_exn (pfd2 | fd2) var c: byte prval pfc = array_v_sing (view@ c) val nread = read_err (pfd1 | fd1, c, 1) prval () = view@ c := array_v_unsing (pfc) val () = close_exn (pfd1 | fd1) val cpid = getpid () val () = printf ("try6: child(%ld)\n", @($UNSAFE.cast2lint(cpid))) in exit (EXIT_SUCCESS) end // end of [ipid = 0] | _ when ipid > 0 => let // parent val () = printf ("parent(%d)\n", @(ipid)) val () = close_exn (pfd1 | fd1) val () = close_exn (pfd2 | fd2) in // nothing end // end of [ipid > 0] | _ (*ipid=-1*) => let // failure val () = close_exn (pfd1 | fd1) val () = close_exn (pfd2 | fd2) val () = perror ("fork") in exit (EXIT_SUCCESS) end // end of [_] end // end of [try6] (* ****** ****** *) implement main () = () where { val () = try1 () val () = try4 () val () = try5 () val () = try6 () val _leftover = sleep (1u) } // end of [main] (* ****** ****** *) (* end of [AUP_9_2_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_7_1.dats0000664000175000017500000000564012223166161020466 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 651 - 653 // section 9.7.1: alarm System Call // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" macdef int_of_pid = $T.int_of_pid staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) // // HX: this is really an overkill ... // fun fprint_bytes_size {n1,n2:nat | n2 <= n1} (out: FILEref, buf: &(@[byte][n1]), n2: size_t n2): void = let val p_buf = &buf prval () = eqsize_byte_one () // sizeof byte == 1 prval pfmul = mul_make {n2,sizeof(byte)} () prval () = mul_elim {n2,1} (pfmul) prval (pf1, pf2) = array_v_split {byte} {n1} {n2} (pfmul, view@ (buf)) prval pfu = unit_v () typedef env = FILEref val () = array_ptr_foreach_funenv_tsz {byte} {unit_v} {env} (pfu | !p_buf, lam (pf | x, out) =<> $effmask_ref (fprint_byte (out, x)), n2, sizeof, out) prval unit_v () = pfu prval () = view@ (buf) := array_v_unsplit {byte} {n2,n1-n2} (pfmul, pf1, pf2) in // nothing end // end of [print_buf_size] fun print_bytes_size {n1,n2:nat | n2 <= n1} (buf: &(@[byte][n1]), n2: size_t n2): void = fprint_bytes_size (stdout_ref, buf, n2) // end of [print_bytes_size] (* ****** ****** *) implement main () = () where { var act: sigaction val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] val () = act.sa_handler := sighandler_of_fun(lam (sgn) => ()) val err = sigaction_null (SIGALRM, act) val () = assertloc (err = 0) macdef NSEC = 5U val () = printf ("You've got %u seconds for input:\n", @(NSEC)) val (pf_alarm | _) = alarm_set (NSEC) val (pf_stdin | ()) = stdin_fildes_view_get () #define BUFSZ 128 var nerr: int = 0 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val nread = read_err (pf_stdin | STDIN_FILENO, !p_buf, BUFSZ) val _leftover = alarm_cancel (pf_alarm | (*none*)) val () = if (nread < 0) then ( if (errno_get() = EINTR) then printf ("Timed out! Please type faster next time.\n", @()) else (nerr := nerr + 1) // end of [if] ) // end of [val] val () = stdin_fildes_view_set (pf_stdin | (*none*)) val () = if nread >= 0 then let val nread = size1_of_ssize1 (nread) val () = if nread > 0 then let val () = print "Got: " val () = print_bytes_size (!p_buf, nread) in // nothing end else printf ("Got: EOF\n", @()) // end of [if] in // nothing end // end of [if] val () = if (nerr > 0) then exit (EXIT_FAILURE) } // end of [main] (* ****** ****** *) (* end of [AUP_9_7_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_11.dats0000664000175000017500000000512512223166161020313 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 315 - 316 // section 5.11: Getting User and Group IDs // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/SATS/grp.sats" staload "libc/SATS/pwd.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) implement main () = () where { // extern castfn __castuid (x: uid_t): lint extern castfn __castgid (x: gid_t): lint extern castfn __cast2 {l:agz} (x: !strptr l): string // val uid = getuid () val (pfopt | p) = getpwuid (uid) val () = if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_name | name) = passwd_get_pw_name (!p) val () = assert (strptr_isnot_null name) val () = printf ( "Real user = %ld (%s)\n", @((__castuid)uid, (__cast2)name) ) // end of [val] prval () = fpf_name (name) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt in exit (EXIT_FAILURE) end // end of [val] // val uid = geteuid () val (pfopt | p) = getpwuid (uid) val () = if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_name | name) = passwd_get_pw_name (!p) val () = assert (strptr_isnot_null name) val () = printf ( "Effective user = %ld (%s)\n", @((__castuid)uid, (__cast2)name) ) // end of [val] prval () = fpf_name (name) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt in exit (EXIT_FAILURE) end // end of [val] // val gid = getgid () val (pfopt | p) = getgrgid (gid) val () = if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_name | name) = group_get_gr_name (!p) val () = assert (strptr_isnot_null name) val () = printf ( "Real group = %ld (%s)\n", @((__castgid)gid, (__cast2)name) ) // end of [val] prval () = fpf_name (name) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt in exit (EXIT_FAILURE) end // end of [val] // val gid = getegid () val (pfopt | p) = getgrgid (gid) val () = if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_name | name) = group_get_gr_name (!p) val () = assert (strptr_isnot_null name) val () = printf ( "Effective group = %ld (%s)\n", @((__castgid)gid, (__cast2)name) ) // end of [val] prval () = fpf_name (name) prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt in exit (EXIT_FAILURE) end // end of [val] // } // end of [main] (* ****** ****** *) (* end of [AUP_5_11.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_17_3.dats0000664000175000017500000000452012223166161020541 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 332 - 338 // section 5.17.3: Thread Synchronization (Mutexes) // (* ****** ****** *) staload "libc/SATS/stdlib.sats" // EXIT_FAILURE staload "libc/SATS/unistd.sats" staload "libc/SATS/pthread.sats" (* ****** ****** *) %{^ static pthread_mutex_t mtx = PTHREAD_MUTEX_INITIALIZER ; #define lock_theX() pthread_mutex_lock(&mtx) #define unlock_theX() pthread_mutex_unlock(&mtx) %} // end of [%{^] var theX: lint = 0L val p_theX = &theX extern fun lock_theX () : (lint @ theX | void) = "mac#lock_theX" extern fun unlock_theX (pf: lint @ theX | (*none*)): void = "mac#unlock_theX" (* ****** ****** *) fun theX_inc_and_get (delta: lint): lint = let val (pf | ()) = lock_theX () val x = !p_theX + delta val () = !p_theX := x val () = unlock_theX (pf | (*none*)) in x // return value end // end of [theX_inc_and_get] (* ****** ****** *) fun thread_func (arg: ptr): ptr = let val arg = (intptr_of)(arg) val arg = lint_of_intptr(arg) val () = while (true) let val x = theX_inc_and_get (0L) in if x < arg then let val () = printf ("Thread 2 says %ld\n", @(theX_inc_and_get(1L))) val _leftover = sleep (1u) in // nothing end else break end // end of [val] val x = theX_inc_and_get (0L) in (ptr_of_intptr)(intptr_of_lint(x)) end // end of [thread_func] (* ****** ****** *) implement main () = () where { var tid: pthread_t val () = assert_errmsg (sizeof <= sizeof, #LOCATION) val (pf, fpf | p) = __assert (null) where { extern castfn __assert (x: ptr null) :<> (pthread_attr_t @ null, pthread_attr_t @ null - void | ptr null) } // end of [prval] val _err = pthread_create (tid, !p, thread_func, (ptr_of_intptr)(intptr_of(6))) prval () = fpf (pf) val () = while (theX_inc_and_get(0L) < 10L) let val () = printf ("Thread 1 says %ld\n", @(theX_inc_and_get(1L))) val _leftover = sleep (1u) in // nothing end // end of [val] var status: ptr = null val () = if (pthread_join (tid, status) > 0) then exit (EXIT_FAILURE) val rtn = lint_of_intptr(intptr_of(status)) val () = printf ("Thread 2's exit status is %ld\n", @(rtn)) val () = exit (EXIT_SUCCESS) } // end of [main] (* ****** ****** *) (* end of [AUP_5_17_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_3_5.dats0000664000175000017500000001567212223166161020244 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 147 - 158 // section 3.5: Accessing and Displaying File Metadata // (* ****** ****** *) // // implementing a command [longls], which is kind of like [ls -l] // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/grp.sats" staload "libc/SATS/pwd.sats" staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/stat.sats" staload "libc/sys/SATS/types.sats" (* ****** ****** *) fun print_mode .<>. (st: &stat): void = let val mode = st.st_mode // macdef TYPE(b) = ,(b) = (mode land S_IFMT) macdef MODE(b) = ,(b) = (mode land ,(b)) // val () = case+ 0 of | _ when TYPE(S_IFBLK) => print 'b' | _ when TYPE(S_IFCHR) => print 'c' | _ when TYPE(S_IFDIR) => print 'd' | _ when TYPE(S_IFIFO) => print 'p' | _ when TYPE(S_IFLNK) => print 'l' | _ when TYPE(S_IFREG) => print '-' | _ when TYPE(S_IFSOCK) => print 's' | _ => print '?' // end of [val] // val () = if MODE(S_IRUSR) then print 'r' else print '-' val () = if MODE(S_IWUSR) then print 'w' else print '-' val () = case+ 0 of | _ when MODE(S_ISUID) => if MODE(S_IXUSR) then print 's' else print 'S' | _ => if MODE(S_IXUSR) then print 'x' else print '-' // end of [val] // val () = if MODE(S_IRGRP) then print 'r' else print '-' val () = if MODE(S_IWGRP) then print 'w' else print '-' val () = case+ 0 of | _ when MODE(S_ISGID) => if MODE(S_IXGRP) then print 's' else print 'S' | _ => if MODE(S_IXGRP) then print 'x' else print '-' // end of [val] // val () = if MODE(S_IROTH) then print 'r' else print '-' val () = if MODE(S_IWOTH) then print 'w' else print '-' val () = case+ 0 of | _ when MODE(S_IFDIR) andalso MODE(S_ISVTX) => if MODE(S_IXOTH) then print 't' else print 'T' | _ => if MODE(S_IXOTH) then print 'x' else print '-' // end of [val] // in // nothing end // end of [print_mode] (* ****** ****** *) fun print_nlink .<>. (st: &stat): void = let val nlink = st.st_nlink val nlink = lint_of_nlink (nlink) in printf ("%5ld", @(nlink)) end // end of [print_nlink] (* ****** ****** *) fun print_owner .<>. (st: &stat): void = let val uid = st.st_uid val (pfopt| p) = getpwuid (uid) in if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_x | x) = passwd_get_pw_name (!p) prval () = fpf (pf) val () = assert_errmsg (strptr_isnot_null x, #LOCATION) val () = printf (" %-8s", @(__cast x)) where { extern castfn __cast {l:addr} (x: !strptr l):<> string } prval () = fpf_x (x) in // nothing end else let prval None_v () = pfopt val uid = lint_of_uid (uid) in printf (" %-8ld", @(uid)) end // end of [if] end (* end of [print_owner] *) (* ****** ****** *) fun print_group .<>. (st: &stat): void = let val gid = st.st_gid val (pfopt| p) = getgrgid (gid) in if p > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_x | x) = group_get_gr_name (!p) prval () = fpf (pf) val () = assert_errmsg (strptr_isnot_null x, #LOCATION) val () = printf (" %-8s", @(__cast x)) where { extern castfn __cast {l:addr} (x: !strptr l):<> string } prval () = fpf_x (x) in // nothing end else let prval None_v () = pfopt val gid = lint_of_gid (gid) in printf (" %-8ld", @(gid)) end // end of [if] end (* end of [print_group] *) (* ****** ****** *) fun print_size .<>. (st: &stat): void = let val mode = st.st_mode // macdef TYPE(b) = ,(b) = (mode land S_IFMT) macdef MODE(b) = ,(b) = (mode land ,(b)) // in case+ 0 of | _ when (TYPE(S_IFCHR) orelse TYPE(S_IFBLK)) => let val rdev = st.st_rdev val rdev = uint_of_dev (rdev) val u1 = rdev >> 8 val u2 = rdev land 0xFFU in printf ("%4u,%4u", @(u1, u2)) end // end of [_ when ...] | _ => let val off = st.st_size val off = lint_of_off (off) val off = ulint_of (off) in printf ("%9lu", @(off)) end (* end of [_] *) end // end of [print_size] (* ****** ****** *) fun print_date .<>. (st: &stat): void = let val now = time_get () in // if (lint_of_time)now >= 0L then let val diff = difftime (now, st.st_mtime) val (pfopt | p) = localtime (st.st_mtime) val () = assert_errmsg (p > null, #LOCATION) prval Some_v @(pf, fpf) = pfopt var !p_buf with pf_buf = @[byte][64]() val fmt = ( if (diff < 0.0 orelse diff > 60*60*24*182.5 (*6months*)) then "%b %e %Y" else "%b %e %H:%M" ) : string val _n = strftime (pf_buf | p_buf, 64, fmt, !p) prval () = fpf (pf) val str = __cast (p_buf) where { extern castfn __cast (x: ptr): string // cutting a corner } // end of [val] prval () = pf_buf := bytes_v_of_strbuf_v (pf_buf) in printf (" %s", @(str)) end else begin printf (" ????????????", @()) end // end of [if] // end // end of [print_date] (* ****** ****** *) fun print_name .<>. (st: &stat, name: string): void = let // nothing in case+ 0 of | _ when S_ISLNK (st.st_mode) => let val n = lint_of_off (st.st_size) val n = n + 1L val n = size_of_lint (n) val n = size1_of_size (n) val (pfgc, pf | p) = malloc_gc (n) val n1 = readlink (pf | name, p, n) val () = if (n1 >= 0) then let val n1 = size1_of_ssize1 (n1) val () = assert_errmsg (n1 < n, #LOCATION) val () = bytes_strbuf_trans (pf | p, n1) val () = printf (" %s -> %s", @(name, __cast p)) where { extern castfn __cast (x: ptr): string // cutting a corner } // end of [val] prval () = pf := bytes_v_of_strbuf_v (pf) in // nothing end else printf (" %s -> [can't read link]", @(name)) // end of [val] in free_gc (pfgc, pf | p) end // end of [_ when ...] | _ => printf (" %s", @(name)) end // end of [print_name] (* ****** ****** *) fun longls .<>. (st: &stat, path: string): void = let val () = print_mode (st) val () = print_nlink (st) val () = print_owner (st) val () = print_group (st) val () = print_size (st) val () = print_date (st) val () = print_name (st, path) val () = print_newline () in // nothing end // end of [longls] (* ****** ****** *) implement main {n} (argc, argv) = () where { // var i: natLte n var st: stat? // uninitialized // val () = for (i := 1; i < argc; i := i+1) let val path = argv.[i] val _err = lstat_err (path, st) val () = if _err >= 0 then let prval () = opt_unsome {stat} (st) val () = longls (st, path) in // nothing end else let prval () = opt_unnone {stat} (st) val () = printf ("longls: cannot access [%s]: No such file or directory\n", @(path)) in // nothing end // end of [if] in // nothing end // end of [val] // } // end of [main] (* ****** ****** *) (* end of [AUP_3_5.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_1_4.dats0000664000175000017500000000206312223166161020456 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 527 - 530 // section 8.1.4: Byte Order // (* ****** ****** *) staload "libc/arpa/SATS/inet.sats" (* ****** ****** *) fun pr (b: byte) = printf ("%x", @(uint_of_byte(b))) implement main () = () where { // var nhost = uint16_of_int (0xD04C) val (pf_x, fpf_x | x) = __cast (nhost) where { extern castfn __cast (n: &uint16) : [l:addr] (bytes(2) @ l, bytes(2) @ l - void | ptr l) // end of [extern] } // end of [val] val () = (pr x->[0]; print ' '; pr x->[1]; print_newline ()) prval () = fpf_x (pf_x) // var nnetwork = htons (nhost) val (pf_x, fpf_x | x) = __cast (nnetwork) where { extern castfn __cast (n: &uint16_nbo) : [l:addr] (bytes(2) @ l, bytes(2) @ l - void | ptr l) // end of [extern] } // end of [val] val () = (pr x->[0]; print ' '; pr x->[1]; print_newline ()) prval () = fpf_x (pf_x) // } // end of [main] (* ****** ****** *) (* end of [AUP_8_1_4.dats] *)ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_3.dats0000664000175000017500000001042212223166161020233 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 544 - 549 // section 8.3: Socket Options // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/string.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/sockopt.sats" staload "libc/sys/SATS/socket.sats" staload "libc/sys/SATS/time.sats" (* ****** ****** *) datatype OPTKIND = OPTKINDint | OPTKINDlinger | OPTKINDtimeval fun show {fd:nat} ( skt: int fd , level: int, option: int, name: string , knd: OPTKIND ) : void = case+ knd of | OPTKINDint () => let var n: int? val err = getsockopt_err{int} (skt, level, option, n, sizeof) in if err >= 0 then let prval () = opt_unsome {int} (n) in printf ("%s = %d\n", @(name, n)) end else let prval () = opt_unnone {int} (n) val (fpf_str | str) = strerror (errno_get()) val () = printf ("%s FAILED (%s)\n", @(name, $UNSAFE.castvwtp1{string} (str))) prval () = fpf_str (str) in // nothing end // end of [if] end (* end of [OPTKINDint] *) | OPTKINDlinger () => let var lg: linger? val err = getsockopt_err{linger} (skt, level, option, lg, sizeof) in if err >= 0 then let prval () = opt_unsome {linger} (lg) in printf ("%s = %d(on/off) / %d sec(linger)\n", @(name, lg.l_onoff, lg.l_linger)) end else let prval () = opt_unnone {linger} (lg) val (fpf_str | str) = strerror (errno_get()) val () = printf ("%s FAILED (%s)\n", @(name, $UNSAFE.castvwtp1{string} (str))) prval () = fpf_str (str) in // nothing end // end of [if] end (* end of [OPTKINDlinger] *) | OPTKINDtimeval () => let var tv: timeval? val err = getsockopt_err{timeval} (skt, level, option, tv, sizeof) in if err >= 0 then let prval () = opt_unsome {timeval} (tv) in printf ("%s = %ld sec / %ld usec\n", @(name, $UNSAFE.cast2lint(tv.tv_sec), $UNSAFE.cast2lint(tv.tv_usec)) ) // end of [printf] end else let prval () = opt_unnone {timeval} (tv) val (fpf_str | str) = strerror (errno_get()) val () = printf ("%s FAILED (%s)\n", @(name, $UNSAFE.castvwtp1{string} (str))) prval () = fpf_str (str) in // nothing end // end of [if] end (* end of [OPTKINDtimeval] *) // end of [show] (* ****** ****** *) fun showall {fd:nat} (skt: int fd, caption: string): void = () where { val () = printf ("\n%s\n", @(caption)) // val () = show (skt, SOL_SOCKET, SO_ACCEPTCONN, "SO_ACCEPTCONN", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_BROADCAST, "SO_BROADCAST", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_DEBUG, "SO_DEBUG", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_DONTROUTE, "SO_DONTROUTE", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_ERROR, "SO_ERROR", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_KEEPALIVE, "SO_KEEPALIVE", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_LINGER, "SO_LINGER", OPTKINDlinger) val () = show (skt, SOL_SOCKET, SO_OOBINLINE, "SO_OOBINLINE", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_RCVBUF, "SO_RCVBUF", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_RCVLOWAT, "SO_RCVLOWAT", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_RCVTIMEO, "SO_RCVTIMEO", OPTKINDtimeval) val () = show (skt, SOL_SOCKET, SO_REUSEADDR, "SO_REUSEADDR", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_SNDBUF, "SO_SNDBUF", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_SNDLOWAT, "SO_SNDLOWAT", OPTKINDint) val () = show (skt, SOL_SOCKET, SO_SNDTIMEO, "SO_SNDTIMEO", OPTKINDtimeval) val () = show (skt, SOL_SOCKET, SO_TYPE, "SO_TYPE", OPTKINDint) // } // end of [showall] (* ****** ****** *) implement main () = () where { // val (pfskt | skt) = socket_family_type_exn (AF_INET, SOCK_STREAM) val () = showall (skt, "AF_INET/SOCKET_STREAM") val () = socket_close_exn (pfskt | skt) // val (pfskt | skt) = socket_family_type_exn (AF_INET, SOCK_DGRAM) val () = showall (skt, "AF_INET/SOCKET_DGRAM") val () = socket_close_exn (pfskt | skt) // } // end of [main] (* ****** ****** *) (* end of [AUP_8_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_3_4.dats0000664000175000017500000000307612223166161020236 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 144 - 146 // section: 3.4: Pathnames // (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/unistd.sats" staload "libc/SATS/unistd_pathconf.sats" (* ****** ****** *) fun get_max_pathname (path: string): lint = let var maxlen: lint = pathconf (path, _PC_PATH_MAX) val () = if (maxlen < 0L) then if errno_get () = (errno_of_int)0 then maxlen := 4096L else () // end of [val] in if maxlen >= 0L then maxlen + 1L else ~1L end // end of [get_max_pathname] (* ****** ****** *) fun mygetcwd (): strptr0 = let val maxlen = get_max_pathname (".") in case+ 0 of | _ when maxlen >= 0L => let val maxlen = ulint_of_lint (maxlen) val nsz = size_of_ulint (maxlen) val [n:int] nsz = size1_of_size (nsz) val [l:addr] (pfgc, pf | p) = malloc_gc (nsz) val p1 = getcwd (pf | p, nsz) val () = assert_errmsg (p1 > null, #LOCATION) prval getcwd_v_succ (pf) = pf in strptr_of_strbuf @(pfgc, pf | p) end // end of [_ when ...] | _ (*maxlen = -1L*) => strptr_null () end // end of [mygetcwd] (* ****** ****** *) implement main () = () where { // val path = "/" val maxlen = get_max_pathname (path) val () = (printf ("get_max_pathname (\"%s\") = ", @(path)); print maxlen; print_newline ()) // val cwd = mygetcwd () val () = (print "cwd = "; print cwd; print_newline ()) val () = strptr_free (cwd) // } // end of [main] (* ****** ****** *) (* end of [AUP_3_4.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_6_3_1.dats0000664000175000017500000001056212223166161020456 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 371 - 375 // section 6.3: dup and dup2 System Calls // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/sys/SATS/wait.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/stdlib.sats" // EXIT_FAILURE staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "utils/errinfo.sats" (* ****** ****** *) fun errinfo_report_wloc (loc: string): void = let var ei: errinfo_t val () = errinfo_set_wloc (ei, loc) val () = fprint_errinfo (stderr_ref, ei) val () = errinfo_clear (ei) in // nothing end // end of [errinfo_report] (* ****** ****** *) fun who2wc (): void = let // exception ERROR of (int) macdef errptexit (status) = let val () = errinfo_report_wloc (#LOCATION) in $raise ERROR (,(status)) end // end of [errptrexit] // fun who2wc_main (): void = let var fd1: int and fd2: int val (pfopt | err) = pipe (fd1, fd2) (* val () = (print "who2wc: fd1 = "; print fd1; print_newline ()) val () = (print "who2wc: fd2 = "; print fd2; print_newline ()) *) in // // HX-2010-10-09: // excessive error-checking makes the code difficult to understand! // if err = 0 then let prval Some_v @(pf1, pf2) = pfopt val pid1 = fork_err () val ipid = int_of_pid (pid1) val () = (case+ 0 of | _ when ipid > 0 => let val pid2 = fork_err () val ipid = int_of_pid (pid2) val () = (case+ 0 of | _ when ipid > 0 => let val () = close_exn (pf1 | fd1) val () = close_exn (pf2 | fd2) var status: int? in if int_of_pid(waitpid (pid2, status, WNONE)) < 0 then errptexit (EXIT_FAILURE) end // end of [pid > 0] | _ when ipid = 0 => let // child 2 prval () = STDIN_FILENO_gtez () val (pf1_ | ()) = stdin_fildes_view_get () val [i:int] (pfopt | err) = dup2 (pf1, pf1_ | fd1, STDIN_FILENO) val () = assertloc (err >= 0) prval Some_v (pf1_) = pfopt val () = stdin_fildes_view_set (pf1_ | (*none*)) val () = (if (err < 0) then errptexit (EXIT_FAILURE) else ()): void val () = close_exn (pf1 | fd1) val () = close_exn (pf2 | fd2) val _ = execlp ("wc", "wc", "-l", null) where { extern fun execlp (_: string, _: string, _: string, _: ptr null): int = "mac#atslib_execlp" // end of [execl] } // end of [val] val () = errptexit (EXIT_FAILURE) in // nothing end // end of [pid = 0] | _ (*ipid=-1*) => let val () = close_exn (pf1 | fd1) val () = close_exn (pf2 | fd2) in errptexit (EXIT_FAILURE) end // end of [_] ) : void // end of [val] var status: int? in if int_of_pid(waitpid (pid1, status, WNONE)) < 0 then errptexit (EXIT_FAILURE) end // end of [pid > 0] | _ when ipid = 0 => let // child 1 prval () = STDOUT_FILENO_gtez () val (pf2_ | ()) = stdout_fildes_view_get () val [i:int] (pfopt | err) = dup2 (pf2, pf2_ | fd2, STDOUT_FILENO) val () = assertloc (err >= 0) prval Some_v (pf2_) = pfopt val () = stdout_fildes_view_set (pf2_ | (*none*)) val () = (if (err < 0) then errptexit (EXIT_FAILURE) else ()): void val () = close_exn (pf1 | fd1) val () = close_exn (pf2 | fd2) val _ = execlp ("who", "who", null) where { extern fun execlp (_: string, _: string, _: ptr null): int = "mac#atslib_execlp" } // end of [val] val () = errptexit (EXIT_FAILURE) in // nothing end // end of [pid = 0] | _ (*ipid=-1*) => let val () = close_exn (pf1 | fd1) val () = close_exn (pf2 | fd2) in errptexit (EXIT_FAILURE) end // end of [_] ) : void // end of [val] in // nothing end else let prval None_v () = pfopt in errptexit (EXIT_FAILURE) end // end of [if] // end // end of [who2wc_main] // in // try who2wc_main () with ~ERROR (status) => exit (status) // end // end of [who2wc] (* ****** ****** *) implement main () = () where { val () = who2wc () val () = printf ("who2wc is finished.\n", @()) } // end of [main] (* ****** ****** *) (* end of [AUP_6_3_1.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_9_7_4.dats0000664000175000017500000000714712223166161020475 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 657 - 660 // section 9.7.4: Baisc Interval-Timer System Calls // (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef time_t = $T.time_t typedef suseconds_t = $T.suseconds_t staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/time.sats" (* ****** ****** *) // // HX: this is really an overkill ... // fun fprint_bytes_size {n1,n2:nat | n2 <= n1} (out: FILEref, buf: &(@[byte][n1]), n2: size_t n2): void = let val p_buf = &buf prval () = eqsize_byte_one () // sizeof byte == 1 prval pfmul = mul_make {n2,sizeof(byte)} () prval () = mul_elim {n2,1} (pfmul) prval (pf1, pf2) = array_v_split {byte} {n1} {n2} (pfmul, view@ (buf)) prval pfu = unit_v () typedef env = FILEref val () = array_ptr_foreach_funenv_tsz {byte} {unit_v} {env} (pfu | !p_buf, lam (pf | x, out) =<> $effmask_ref (fprint_byte (out, x)), n2, sizeof, out) prval unit_v () = pfu prval () = view@ (buf) := array_v_unsplit {byte} {n2,n1-n2} (pfmul, pf1, pf2) in // nothing end // end of [print_buf_size] fun print_bytes_size {n1,n2:nat | n2 <= n1} (buf: &(@[byte][n1]), n2: size_t n2): void = fprint_bytes_size (stdout_ref, buf, n2) // end of [print_bytes_size] (* ****** ****** *) val theMsg = "Hello for the timer!\n" val theMsgLen = string_length (theMsg) fun test_timer (): void = let var act: sigaction? val () = ptr_zero (__assert () | act) where { extern prfun __assert (): NULLABLE (sigaction) } // end of [val] fun handler (sgn: signum_t): void = let val (pf_stdout | ()) = stdout_fildes_view_get () val _err = write_substring_err (pf_stdout | STDOUT_FILENO, theMsg, 0, theMsgLen) val () = stdout_fildes_view_set (pf_stdout | (*none*)) in end // end of [handler] val () = act.sa_flags := SA_RESTART // HX: allowing [read] to restart val () = act.sa_handler := sighandler(handler) val err = sigaction_null (SIGALRM, act) val () = assertloc (err = 0) // var itv: itimerval? val _2 = $UNSAFE.cast{time_t} (2) val () = ptr_zero (__assert () | itv) where { extern prfun __assert (): NULLABLE (itimerval) } // end of [val] val () = itv.it_interval.tv_sec := _2; val () = itv.it_value.tv_sec := _2 val err = setitimer_null (ITIMER_REAL, itv) val () = assertloc (err = 0) // #define BUFSZ 128 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) var nerr: int = 0 val () = while (true) let val (pf_stdin | ()) = stdin_fildes_view_get () val nread = read_err (pf_stdin | STDIN_FILENO, !p_buf, BUFSZ) val () = stdin_fildes_view_set (pf_stdin | (*none*)) in if nread >= 0 then let val nread = size1_of_ssize1 (nread) in if nread > 0 then let val () = print_bytes_size (!p_buf, nread) in continue end else ( printf ("EOF\n", @()); break ) // end of [if] end else let val () = perror "read" in nerr := nerr + 1; break end // end of [if] end // end of [val] val () = if (nerr > 0) then exit (EXIT_FAILURE) in // nothing end // end of [test_timer] (* ****** ****** *) implement main () = () where { val () = test_timer () } // end of [main] (* ****** ****** *) (* end of [AUP_9_7_4.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_2_3.dats0000664000175000017500000000673312223166161020462 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 213 - 218 // section 4.2.3: select System Call // (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/select.sats" (* ****** ****** *) %{^ #define atslib_read1(fd, c) read(fd, c, 1) %} // end of [%{^] fun readany2 {n:nat} ( fds: &(@[int][n]), n: int n, which: &int ) : int = let // var fdset_rd: fd_set val () = FD_ZERO (fdset_rd) // var i: natLte n var maxfd: intGte 0 = 0 // val () = for (i := 0; i < n; i := i+1) { val fd = fds.[i] val fd = int1_of_int (fd) val () = assert (fd >= 0) val () = FD_SET (fd, fdset_rd) val () = if fd > maxfd then maxfd := fd } // end of [val] // var nerr: int = 0 // val nfd = select ( maxfd + 1, fdset_rd, null, null, null ) where { extern fun select ( _: intGte 1, fdset: &fd_set, _: ptr, _: ptr, _: ptr ) : int = "mac#atslib_select" } // end of [val] val () = if nfd < 0 then nerr := nerr + 1 // var c: char = '\0' // val () = if nerr = 0 then ( for (i := 0; i < n; i := i+1) let val fd = fds.[i] val fd = int1_of_int (fd) val () = assert (fd >= 0) in if FD_ISSET (fd, fdset_rd) then let val () = c := '\0' // extern fun read1 (fd: int, c: &char): ssize_t = "mac#atslib_read1" // val nread = read1 (fd, c) val nread = int_of_ssize (nread) val nread = int1_of_int (nread) val () = which := i val () = if (nread < 0) then (nerr := nerr + 1) in break end // end of [if] end // end of [for] ) // end of [if] // in if nerr > 0 then ~1 else (int_of)c end // end of [readany2] (* ****** ****** *) fun test_readany2 () = let var !p_fds = @[int](~1, ~1) var nerr: int = 0 extern prfun __leak {v:view} (pf: v): void val (pf | fd) = open_flag_err ("/dev/tty", O_RDWR) val () = if fd < 0 then let val () = prerr "test_readany: open: 0\n" in nerr := nerr + 1 end // end of [val] prval () = __leak (pf) val () = p_fds->[0] := fd val path = "/dev/pts/5" // HX: change may be needed val (pf | fd) = open_flag_err (path, O_RDWR) val () = if fd < 0 then let val () = prerr "test_readany: open: 1\n" in nerr := nerr + 1 end // end of [val] prval () = __leak (pf) val () = p_fds->[1] := fd // val () = if (nerr = 0) then let var which: int = ~1 val () = while (true) let val c = readany2 (!p_fds, 2, which) val () = if c > 0 then let val c = char_of_int(c) val c = (if char_isprint (c) then c else '?'): char val () = printf ("Got %c from terminal %d\n", @(c, which)) in continue end // end of [val] val () = if (c = 0) then printf ("EOF from terminal %d\n", @(which)) else nerr := nerr+1 // end of [val] in break end // end of [val] in // nothing end // end of [val] // var i: natLte 2 val () = for (i := 0; i < 2; i := i+1) let extern fun __close (fd: int): void = "atslib_close_exn" val fd = p_fds->[i] in if fd >= 0 then __close (fd) end // end of [val] // val () = if (nerr > 0) then prerrf ("test_readany: failed.\n", @()) // in // nothing end // end of [test_readany2] (* ****** ****** *) implement main () = () where { val () = test_readany2 () } // end of [main] (* ****** ****** *) (* end of [AUP_4_2_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_7.dats0000664000175000017500000000340612223166161020237 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 248 - 249 // section 4.7: Terminal-Identification System Calls // (* ****** ****** *) staload "libc/SATS/unistd.sats" (* ****** ****** *) fun print_ttyname (): int = status where { prval () = STDIN_FILENO_gtez () val (fpf_ctty | ctty) = ttyname (STDIN_FILENO) val status = (case+ 0 of | _ when strptr_isnot_null(ctty) => let val () = (print ctty; print_newline ()) prval () = fpf_ctty (ctty) in 0 end // end of [_ when ...] | _ => let val () = (print "not a tty"; print_newline ()) prval () = fpf_ctty (ctty) in 1 end // end of [_] ) : int // end of [val] } // end of [print_ttyname] (* ****** ****** *) fun print_ttyname_r (): int = status where { prval () = STDIN_FILENO_gtez () #define BUFSZ 1024 // big enough? var !p_buf with pf_buf = @[byte][BUFSZ]() val (pfopt | err) = ttyname_r (pf_buf | STDIN_FILENO, p_buf, BUFSZ) val status = if err = 0 then let prval ttyname_v_succ (pf) = pfopt val () = print (__cast p_buf) where { extern castfn __cast (x: ptr): string } // end of [val] val () = print_newline () prval () = pf_buf := bytes_v_of_strbuf_v (pf) in 0 // success end else let // err < 0 prval ttyname_v_fail (pf) = pfopt val () = (print "not a tty?"; print_newline ()) prval () = pf_buf := bytes_v_of_b0ytes_v (pf) in 1 // failure end : int // end of [if] } // end of [print_ttyname] (* ****** ****** *) implement main () = () where { val status = print_ttyname () val status = print_ttyname_r () } // end of [main] (* ****** ****** *) (* end of [AUP_4_7.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_5_2.dats0000664000175000017500000000166412223166161020237 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 248 - 249 // section 5.2: Environment // (* ****** ****** *) staload "libc/SATS/stdlib.sats" // for getenv (* ****** ****** *) (* extern fun getenv (name: string) : [l:addr] (strptr l - void | strptr l) = "mac#atslib_getenv" // end of [atslib_getenv] *) implement main () = () where { val [l:addr] (fpf_x | x) = getenv ("LOGNAME") prval () = addr_is_gtez {l} () val () = if strptr_is_null (x) then let val () = printf ("The variable LOGNAME not found\n", @()) in // nothing end else let val () = printf ( "The value of LOGNAME is \"%s\"\n", @(__cast x) ) where { extern castfn __cast {l:agz} (x: !strptr l):<> string } // end of [val] in end // end of [if] prval () = fpf_x (x) } // end of [main] (* ****** ****** *) (* end of [AUP_5_2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_8_2_3.dats0000664000175000017500000000274312223166161020463 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 535 - 537 // section 8.2.3: AF_INET Socket Addresses // (* ****** ****** *) staload "libc/SATS/fcntl.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/socket.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket_in.sats" staload "libc/arpa/SATS/inet.sats" (* ****** ****** *) #define REQUEST "GET / HTTP/1.0\r\n\r\n" implement main () = () where { // var sa: sockaddr_in // val () = sa.sin_family := AF_INET val () = sa.sin_port := in_port_nbo_of_int (80) val () = sa.sin_addr.s_addr := inet_addr ("209.191.122.70") // val (pfskt | fd) = socket_family_type_exn (AF_INET, SOCK_STREAM) val () = connect_in_exn (pfskt | fd, sa) val len = string_length (REQUEST) val () = socket_write_substring (pfskt | fd, REQUEST, 0, len) #define BUFSZ 1024 // HX: hopefully, this is large enough var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val nread = socket_read_err (pfskt | fd, !p_buf, BUFSZ) val () = assertloc (nread >= 1) val nread = size1_of_ssize1 (nread) val (pfout | ()) = stdout_fildes_view_get () val _err = write_err (pfout | STDOUT_FILENO, !p_buf, nread-1) val () = stdout_fildes_view_set (pfout | (*none*)) val () = socket_close_exn (pfskt | fd) } // end of [main] (* ****** ****** *) (* end of [AUP_8_2_3.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_4_3_5.dats0000664000175000017500000000366512223166161020466 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: September, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 230 - 232 // section 4.3.5: Session-related System Calls // (* ****** ****** *) // staload TYPES = "libc/sys/SATS/types.sats" macdef pid(x) = $TYPES.pid_of_int ,(x) macdef long(x) = $TYPES.lint_of_pid ,(x) // staload "libc/SATS/fcntl.sats" staload "libc/SATS/signal.sats" staload "libc/SATS/termios.sats" staload "libc/SATS/unistd.sats" // (* ****** ****** *) typedef strcst = string (* ****** ****** *) extern fun showpginfo (msg: strcst): void = "showpginfo" implement showpginfo (msg) = () where { var err: int = 0 val () = printf ("%s\n", @(msg)) val () = printf ( "\tprocess ID = %ld; process-group ID = %ld\n", @(long(getsid((pid)0)), long(getpgid((pid)0))) ) // end of [val] val (pfopt | fd) = open_flag_err ("/dev/tty", O_RDWR) val () = assert_errmsg (fd >= 0, #LOCATION) prval open_v_succ (pf) = pfopt val () = printf ( "\tcontrolling terminal's foreground progress-group ID = %ld\n", @(long(tcgetpgrp(fd))) ) // end of [val] val () = printf ("\tcontrolling-terminal's session ID = %ld\n", @(long(tcgetsid(fd)))) val () = close_exn (pf | fd) } // end of [showpginfo] (* ****** ****** *) extern fun maininit (): void = "maininit" implement main () = () where { val () = maininit () val () = showpginfo ("initial call") val () = while (true) let val _leftover = sleep (1000000u) in (*nothing*) end // end of [val] } // end of [main] (* ****** ****** *) %{$ static void catchsig (int signo) { if (signo == SIGCONT) showpginfo ("SIGCONT caught") ; return ; } // end of [catchsig] void maininit () { int err ; struct sigaction act ; memset (&act, 0, sizeof(act)) ; act.sa_handler = catchsig ; err = sigaction (SIGCONT, &act, NULL) ; if (err == -1) exit (1) ; return ; } // end of [main1] %} // end of [%{$] (* ****** ****** *) (* end of [AUP_4_3_5.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/AUP/AUP_6_5.dats0000664000175000017500000001350212223166161020235 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // book: AUP (2nd edition), pages 371 - 375 // section 6.5: Two-Way Communication with Unidirectional Pipes // (* ****** ****** *) staload "libc/sys/SATS/types.sats" staload "libc/SATS/fcntl.sats" staload "libc/SATS/stdlib.sats" // EXIT_FAILURE staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "utils/errinfo.sats" (* ****** ****** *) fun errinfo_report_wloc (loc: string): void = let var ei: errinfo_t val () = errinfo_set_wloc (ei, loc) val () = fprint_errinfo (stderr_ref, ei) val () = errinfo_clear (ei) in // nothing end // end of [errinfo_report] (* ****** ****** *) // // HX-2010-10-10: // error-handling in the following code really caused my head to spin. However, // I do not have a significantly better approach at this moment :( // (* ****** ****** *) fun fsort () = let // exception ERROR of (int) macdef errptexit (status) = let val () = errinfo_report_wloc (#LOCATION) in $raise ERROR (,(status)) end // end of [errptrexit] // fun fsort_main (): void = let var fdin1: int and fdin2: int val [i:int] (pfopt | err) = pipe (fdin1, fdin2) val () = ( // if (err < 0) then let prval None_v () = pfopt in errptexit (EXIT_FAILURE) end else let prval Some_v @(pfin1, pfin2) = pfopt var fdout1: int and fdout2: int val [i:int] (pfopt | err) = pipe (fdout1, fdout2) val () = ( if (err < 0) then let val () = close_exn (pfin1 | fdin1) val () = close_exn (pfin2 | fdin2) prval None_v () = pfopt in errptexit (EXIT_FAILURE) end else let prval Some_v @(pfout1, pfout2) = pfopt val () = fsort_main2 (pfin1, pfin2, pfout1, pfout2 | fdin1, fdin2, fdout1, fdout2) in // nothing end ) : void // end of [val] // in // nothing end ) : void // end of [val] // in // nothing end // end of [fsort_main] // and fsort_main2 {fdin1,fdin2:int} {fdout1,fdout2:int} ( pfin1: fildes_v fdin1, pfin2: fildes_v fdin2 , pfout1: fildes_v fdout1, pfout2: fildes_v fdout2 | fdin1: int fdin1, fdin2: int fdin2 , fdout1: int fdout1, fdout2: int fdout2 ) : void = let prval () = STDIN_FILENO_gtez () prval () = STDOUT_FILENO_gtez () val pid = fork_err () val ipid = (int_of_pid)pid in case+ 0 of | _ when ipid = 0 => let // child // val (pf_ | ()) = stdin_fildes_view_get () val [i:int] (pfopt | err) = dup2 (pfout1, pf_ | fdout1, STDIN_FILENO) val () = assertloc (err >= 0) prval Some_v (pf_) = pfopt val () = stdin_fildes_view_set (pf_ | (*none*)) val () = close_exn (pfout1 | fdout1) val () = close_exn (pfout2 | fdout2) val () = (if (err < 0) then errptexit (EXIT_FAILURE) else ()): void // val (pf_ | ()) = stdout_fildes_view_get () val [i:int] (pfopt | err) = dup2 (pfin2, pf_ | fdin2, STDOUT_FILENO) val () = assertloc (err >= 0) prval Some_v (pf_) = pfopt val () = stdout_fildes_view_set (pf_ | (*none*)) val () = close_exn (pfin1 | fdin1) val () = close_exn (pfin2 | fdin2) val () = (if (err < 0) then errptexit (EXIT_FAILURE) else ()): void val _int = execlp ("sort", "sort", null) where { extern fun execlp (_: string, _: string, _: ptr null): int = "mac#atslib_execlp" } // end of [val] // in errptexit (EXIT_FAILURE) // HX: if execution reaches here, [execlp] has failed end // end of [ipid = 0] | _ when ipid > 0 => let // parent #define BUFSZ 512 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val () = close_exn (pfin2 | fdin2) val () = close_exn (pfout1 | fdout1) val (pfopt | fd) = open_flag_err ("data/fruits.txt", O_RDONLY) var nerr: int = 0 val () = if (fd < 0) then let prval open_v_fail () = pfopt in nerr := nerr + 1 end else let prval open_v_succ (pf) = pfopt val () = while (true) let val nread = read_err (pf | fd, !p_buf, BUFSZ) in if nread >= 0 then let val nread = size1_of_ssize1 (nread) val () = if nread = 0 then break val nwrite = write_err (pfout2 | fdout2, !p_buf, nread) val () = if nwrite < 0 then (nerr := nerr + 1; break) in // nothing end else let val () = nerr := nerr + 1 in break end // end of [if] end // end of [while] val () = close_exn (pf | fd) in // nothing end // end of [val] val () = close_exn (pfout2 | fdout2) val () = ( if (nerr > 0) then let val () = close_exn (pfin1 | fdin1) in errptexit (EXIT_FAILURE) // HX: open ("datafile") failed end else let var nerr: int = 0 val (pf_stdout | ()) = stdout_fildes_view_get () val () = while (true) let val nread = read_err (pfin1 | fdin1, !p_buf, BUFSZ) in if nread >= 0 then let val nread = size1_of_ssize1 (nread) val () = if nread = 0 then break val nwrite = write_err (pf_stdout | STDOUT_FILENO, !p_buf, nread) in if nwrite < 0 then (nerr := nerr + 1; break) end else let val () = nerr := nerr + 1 in break end // end of [if] end // end of [val] val () = stdout_fildes_view_set (pf_stdout | (*none*)) val () = close_exn (pfin1 | fdin1) val () = if nerr > 0 then errptexit (EXIT_FAILURE) in // nothing end // end of [if] ) : void // end of [val] in // nothing end // end of [ipid > 0] | _ => let val () = close_exn (pfin1 | fdin1) val () = close_exn (pfin2 | fdin2) val () = close_exn (pfout1 | fdout1) val () = close_exn (pfout2 | fdout2) in errptexit (EXIT_FAILURE) // [fork] failed end // end of [_] end // end of [fsort_main2] in try fsort_main () with ~ERROR (status) => exit (status) end // end of [fsort] (* ****** ****** *) implement main () = fsort () (* ****** ****** *) (* end of [AUP_6_5.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/0000700000175000017500000000000012223166161021036 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/0000700000175000017500000000000012223166161022565 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/digit_space_other_cnt.dats0000664000175000017500000000275712223166161030011 0ustar hwxihwxi// // K&R, 2nd edition, page 22 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) extern fun digit_val_get {c:char} (c: char c): intBtw (~1, 10) implement digit_val_get (c) = begin if c >= '0' then (if c <= '9' then c - '0' else ~1) else ~1 end // end of [digit_val_get] implement main () = let var nwhite: int = 0 and nother = 0 var !p_ndigit = @[int][10](0) // array allocated on stack val () = loop (!p_ndigit, nwhite, nother) where { fun loop (ndigit: &(@[int][10]), nwhite: &int, nother: &int): void = let val c = getchar () in if (c <> EOF) then let val c = char1_of_int (c) val i = digit_val_get (c) val () = case+ 0 of | _ when i >= 0 => ndigit.[i] := ndigit.[i] + 1 | _ when c = ' ' => nwhite := nwhite + 1 | _ when c = '\n' => nwhite := nwhite + 1 | _ when c = '\t' => nwhite := nwhite + 1 | _ => nother := nother + 1 in loop (ndigit, nwhite, nother) end else begin // loop exits end // end of [if] end // end of [loop] } val () = print "digits =" val () = pr (!p_ndigit, 0) where { fun pr (A: &(@[int][10]), i: natLte 10): void = if i < 10 then (printf (" %d", @(A.[i])); pr (A, i+1)) else () } in printf (", white space = %d, other = %d\n", @(nwhite, nother)) end // end of [main] (* ****** ****** *) (* end of [digit_space_other_cnt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/power.dats0000664000175000017500000000167212223166161024620 0ustar hwxihwxi// // K&R, 2nd edition, page 24 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ****** ****** *) (* #include extern int power (int base, int n) ; int main () { int i ; for (i = 0; i < 10; ++i) { printf ("%d %d %d\n", i, power(2, i), power(-3, i)) ; } return 0 ; } /* end of [main] */ /* ****** ****** */ int power (int base, int n) { int i, p ; p = 1 ; for (i = 1; i <= n; ++i) p = p * base ; return p ; } *) extern fun power (base: int, n: int): int implement power (base, n) = loop (1, 1) where { // note that [loop] is a closure fun loop (i: int, p: int): int = if i <= n then loop (i+1, p * base) else p } // end of [power] (* ****** ****** *) implement main () = let var i: int // uninitialized in for (i := 0; i < 10; i := i + 1) printf ("%d %d %d\n", @(i, power(2, i), power(~3, i))) end // end of [main] (* ****** ****** *) (* end of [power.c] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/fahrenheit_celsius.dats0000664000175000017500000000233412223166161027324 0ustar hwxihwxi// // K&R, 2nd edition, page 15 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // #define LOWER 0 #define UPPER 300 #define STEP 20 (* #define LOWER 0 #define UPPER 300 #define STEP 20 main () { int fahr; for (fahr = LOWER; fahr <= UPPER; fahr += STEP) { printf ("%3d %6.1f\n", fahr, (5.0/9.0) * (fahr - 32)) ; } // end of [for] } /* end of [main] */ *) implement main () = loop (LOWER) where { fun loop (fahr: int): void = if fahr <= UPPER then let val () = printf ("%3d %6.1f\n", @(fahr, (5.0/9.0) * double_of (fahr - 32))) in loop (fahr + STEP) end // end of [loop] } // end of [main] (* // here is a variant implement main () = let var fahr: int = LOWER in while (fahr <= UPPER) begin printf ("%3d %6.1f\n", @(fahr, (5.0/9.0) * double_of (fahr - 32))); fahr := fahr + STEP end // end of [while] end // end of [main] *) (* // here is another variant implement main () = let var fahr: int // uninitialized in for (fahr := LOWER; fahr <= UPPER; fahr := fahr + STEP) begin printf ("%3d %6.1f\n", @(fahr, (5.0/9.0) * double_of (fahr - 32))); end // end of [for] end // end of [main] *) (* ****** ****** *) (* end of [fahrenheit_celsius.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/Makefile0000664000175000017500000000443012223166161024242 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 1 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: hello cleanall:: ; $(RMF) hello hello: hello.dats $(ATSCC) -o hello hello.dats checkall:: fahrenheit_celsius cleanall:: ; $(RMF) fahrenheit_celsius fahrenheit_celsius: fahrenheit_celsius.dats $(ATSCC) -o fahrenheit_celsius fahrenheit_celsius.dats checkall:: echo cleanall:: ; $(RMF) echo echo: echo.dats ; $(ATSCC) -o echo echo.dats checkall:: charcnt cleanall:: ; $(RMF) charcnt charcnt: charcnt.dats ; $(ATSCC) -o charcnt charcnt.dats checkall:: linecnt cleanall:: ; $(RMF) linecnt linecnt: linecnt.dats ; $(ATSCC) -o linecnt linecnt.dats checkall:: wc cleanall:: ; $(RMF) wc wc: wc.dats ; $(ATSCC) -o wc wc.dats checkall:: dsocnt cleanall:: ; $(RMF) dsocnt dsocnt: digit_space_other_cnt.dats $(ATSCC) -o dsocnt digit_space_other_cnt.dats checkall:: power cleanall:: ; $(RMF) power power: power.dats ; $(ATSCC) -o power power.dats checkall:: longest_line cleanall:: ; $(RMF) longest_line longest_line: longest_line.dats $(ATSCC) -o longest_line longest_line.dats checkall:: longest_line_alt cleanall:: ; $(RMF) longest_line_alt longest_line_alt: longest_line_alt.dats $(ATSCC) -o longest_line_alt longest_line_alt.dats ###### html:: ; $(ATSOPT) --posmark_html -d hello.dats > hello_dats.html html:: ; $(ATSOPT) --posmark_html -d fahrenheit_celsius.dats > fahrenheit_celsius_dats.html html:: ; $(ATSOPT) --posmark_html -d echo.dats > echo_dats.html html:: ; $(ATSOPT) --posmark_html -d charcnt.dats > charcnt_dats.html html:: ; $(ATSOPT) --posmark_html -d linecnt.dats > linecnt_dats.html html:: ; $(ATSOPT) --posmark_html -d wc.dats > wc_dats.html html:: ; $(ATSOPT) --posmark_html -d digit_space_other_cnt.dats > digit_space_other_dats.html html:: ; $(ATSOPT) --posmark_html -d power.dats > power_dats.html html:: ; $(ATSOPT) --posmark_html -d longest_line.dats > longest_line_dats.html html:: ; $(ATSOPT) --posmark_html -d longest_line_alt.dats > longest_line_alt_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/longest_line_alt.dats0000664000175000017500000000532112223166161027001 0ustar hwxihwxi// // K&R, 2nd edition, page 29 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ** Handling C strings (byte sequences ending with the null byte) ** in ATS is a constant challenge. This implementation employs byte ** arrays instead of C strings, and it is significantly cleaner than ** the implementation in [longest_line.dats], which uses C strings. *) (* ****** ****** *) staload "libc/SATS/stdio.sats" (****** ****** *) #define MAXLINE 1000 typedef b0ytes (n: int) = @[byte?][n] (* ****** ****** *) fun getline {m:nat} (buf: &bytes m, m: int m): natLte m = loop (buf, m, 0) where { fun loop {i:nat | i <= m} .. (buf: &bytes m, m: int m, i: int i): natLte m = if i < m then let val c = getchar () in if c = EOF then i else let val c = byte_of_int (c); val () = buf.[i] := c in if (c = byte_of_char '\n') then (i+1) else loop (buf, m, i+1) end // end of [if] end else begin m // loop exits end // end of [if] } // end of [getline] (* ****** ****** *) fn copy {m1,m2:int} {n:nat | n <= m1; n <= m2} ( buf_dst: &bytes m1, buf_src: &bytes m2, n: int n ) : void = loop (buf_dst, buf_src, n, 0) where { fun loop {i:nat | i <= n} .. (buf_dst: &bytes m1, buf_src: &bytes m2, n: int n, i: int i): void = if i < n then begin buf_dst.[i] := buf_src.[i]; loop (buf_dst, buf_src, n, i+1) end // end of [if] } // end of [copy] (* ****** ****** *) (* ** It is formally verified in the type system of ATS that there is ** *no* possibility of buffer overlow in this implementation. Period. *) implement main () = let #define M MAXLINE var !p_line with pf_line = @[byte][M]() // allocation on stack val () = pf_line := bytes_v_of_b0ytes_v (pf_line) var !p_longest with pf_longest = @[byte][M]() // allocation on stack val () = pf_longest := bytes_v_of_b0ytes_v (pf_longest) val max = loop (!p_line, !p_longest, 0) where { fun loop {max:nat | max <= M} (line: &bytes M, longest: &bytes M, max: int max) : natLte M = let val n = getline (line, M) in if n > 0 then begin if max < n then begin copy (longest, line, n); loop (line, longest, n) end else begin loop (line, longest, max) end // end of [if] end else begin max // loop exits end // end of [if] end // end of [loop] } val (pf_stdout | p_stdout) = stdout_get () val () = if (max > 0) then let val max_sz = size1_of_int1 max in fwrite_byte_exn (file_mode_lte_w_w | !p_longest, max_sz, !p_stdout) end // end of [val] val () = stdout_view_set (pf_stdout | (*none*)) in // empty end // end of [main] (* ****** ****** *) (* end of [longest_line_alt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/hello.dats0000664000175000017500000000070512223166161024563 0ustar hwxihwxi// // K&R, 2nd edition, page 7 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* #include main () { printf ("hello, world\n") ; } *) implement main () = begin printf ("hello, world\n", @()); // semicolon is optional end // end of [main] (* // here is a variant in ATS: implement main () = begin printf ("%s, %s\n", @("hello", "world")); end // end of [main] *) (* ****** ****** *) (* end of [hello.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/linecnt.dats0000664000175000017500000000131412223166161025111 0ustar hwxihwxi// // K&R, 2nd edition, page 19 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // staload "libc/SATS/stdio.sats" (* #include int main () { int c ; int nl ; while ((c = getchar()) != EOF) if (c == '\n') ++nl ; printf ("%d\n", nl) ; } /* end of [main] */ *) implement main () = let val nl = loop (0) where { fun loop (nl: int): int = let val c = getchar () in if c <> EOF then begin if c = int_of_char '\n' then loop (nl + 1) else loop (nl) end else begin nl // loop exits end // end of [if] end // end of [loop] } in printf ("%d\n", @(nl)) end // end of [main] (* ****** ****** *) (* end of [linecnt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/charcnt.dats0000664000175000017500000000105212223166161025076 0ustar hwxihwxi// // K&R, 2nd edition, page 18 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // staload "libc/SATS/stdio.sats" (* #include int main () { double nc ; for (nc = 0; getchar () != EOF; nc++) ; printf ("%.0f\n", nc) ; } /* end of main */ *) implement main () = let val nc = loop (0.0) where { fun loop (nc: double): double = if getchar () <> EOF then loop (nc + 1.0) else nc } // end of [where] in printf ("%.0f\n", @(nc)) end // end of [main] (* ****** ****** *) (* end of [charcnt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/wc.dats0000664000175000017500000000270612223166161024074 0ustar hwxihwxi// // K&R, 2nd edition, page 20 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* #include #define IN 1 /* inside a word */ #define OUT 0 /* outside a word */ /* count lines, words, and chars in input */ int main () { int c, nl, nw, nc, state ; state = OUT ; nl = nw = nc = 0 ; while ((c = getchar()) != EOF) { ++nc ; if (c == '\n') ++nl ; if (c == ' ' || c == '\n' || c == '\t') state = OUT ; else if (state == OUT) { state = IN ; ++nw ; } } // end of [while] printf ("%d %d %d\n", nl, nw, nc) ; } /* end of [main] */ *) staload "libc/SATS/stdio.sats" #define IN 0; #define OUT 1 implement main () = let fun loop (nl: &int, nw: &int, nc: &int, state: &int): void = let val c = getchar () in if (c <> EOF) then let val () = nc := nc + 1 val c = char_of_int (c) val () = if (c = '\n') then (nl := nl + 1) val () = case+ c of | ' ' => state := OUT | '\n' => state := OUT | '\t' => state := OUT | _ => begin if (state = OUT) then (state := IN; nw := nw + 1) end in loop (nl, nw, nc, state) end else begin // loop exits end // end of [if] end // end of [loop] var nl: int = 0 and nw: int = 0 and nc: int = 0 and state: int = OUT val () = loop (nl, nw, nc, state) in printf ("%d %d %d\n", @(nl, nw, nc)) end // end of [main] (* ****** ****** *) (* end of [wc.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/longest_line.dats0000664000175000017500000000654412223166161026151 0ustar hwxihwxi// // K&R, 2nd edition, page 29 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* ** Handling C strings (byte sequences ending with the null byte) ** in ATS is a constant challenge. This example makes use of several ** advanced features in ATS that are probably difficult for a beginner ** to grasp. So skip it if you find it to be the case. *) (* ****** ****** *) staload "libc/SATS/stdio.sats" (****** ****** *) #define MAXLINE 1000 typedef b0ytes (n: int) = @[byte?][n] (* ****** ****** *) // implemented in C extern fun getline {m:pos} {l:addr} (pf_buf: b0ytes m @ l | p_buf: ptr l, m: int m) : [n:nat | n < m] (strbuf (m, n) @ l | int n) = "__getline" // end of [getline] (* ****** ****** *) // implemented in C extern fun copy {m,n:nat | n < m} {l_to,l_from:addr} ( pf_to: !b0ytes m @ l_to >> strbuf (m, n) @ l_to , pf_from: !strbuf (m, n) @ l_from | p_to: ptr l_to, p_from: ptr l_from ) : void = "__copy" // end of [copy] (* ****** ****** *) #define s2b bytes_v_of_strbuf_v // from [prelude/SATS/string.sats] (* ** It is formally verified in the type system of ATS that there is ** *no* possibility of buffer overlow in this implementation under the ** assumption that both [getline] and [copy] are implemented correctly ** in C. *) implement main () = let #define M MAXLINE var !p_line with pf_line = @[byte][M]() var !p_longest with pf_longest = @[byte][M]() val () = bytes_strbuf_trans (pf_longest | p_longest, 0) val max = loop (pf_line, pf_longest | p_line, p_longest, 0) where { fun loop {max:nat | max < M} ( pf_line: !b0ytes M @ p_line , pf_longest: !strbuf (M, max) @ p_longest >> strbuf (M, max) @ p_longest | p_line: ptr p_line, p_longest: ptr p_longest, max: int (max) ) : #[max: nat | max < M] int max = let val (pf_line_new | n) = getline (pf_line | p_line, M) in if n = 0 then let prval () = pf_line := s2b (pf_line_new) in max // loop exits end else begin if max < n then let prval () = pf_longest := s2b (pf_longest) val () = copy (pf_longest, pf_line_new | p_longest, p_line) prval () = pf_line := s2b (pf_line_new) in loop (pf_line, pf_longest | p_line, p_longest, n) end else let prval () = pf_line := s2b (pf_line_new) in loop (pf_line, pf_longest | p_line, p_longest, max) end (* endif *) end // end of [if] end (* end of [loop] *) } in if (max > 0) then let val () = print_string (str) where { extern castfn string_of_ptr (p: ptr): string val str = string_of_ptr (p_longest) } // end of [val] prval () = pf_longest := s2b (pf_longest) in // empty end else let prval () = pf_longest := s2b (pf_longest) in // empty end // end of [if] end // end of [main] (* ****** ****** *) %{$ ats_int_type __getline ( ats_ptr_type s0, ats_int_type lim ) { int c, i; char *s = (char*)s0 ; for (i = 0; i < lim-1 && (c=getchar()) != EOF && c!='\n'; ++i) s[i] = c; if (c == '\n') { s[i] = c; ++i; } s[i] = '\0'; return i; } // end of [__getline] ats_void_type __copy ( ats_ptr_type to, ats_ptr_type from ) { int i; i = 0; while ((((char*)to)[i] = ((char*)from)[i]) != '\0') ++i; return ; } // end of [__copy] %} // end of [%{$] (* ****** ****** *) (* end of [longest_line.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter01/echo.dats0000664000175000017500000000102212223166161024367 0ustar hwxihwxi// // K&R, 2nd edition, page 17 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // staload "libc/SATS/stdio.sats" (* /* copy input to output */ int main () { int c ; while ((c = getchar()) != EOF) putchar(c) ; } *) implement main () = loop () where { fun loop () = let val c = getchar () in if (c <> EOF) then begin let val _ = putchar (char_of_int c) in loop () end end // end of [if] end // end of [loop] } // end of [main] (* ****** ****** *) (* end of [echo.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter04/0000700000175000017500000000000012223166161022570 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter04/qsort.dats0000664000175000017500000000345512223166161024640 0ustar hwxihwxi// // K&R, 2nd edition, page 87 // (* ****** ****** *) fn swap {n:nat} {i,j:nat | i < n; j < n} (v: &(@[int][n]), i: int i, j: int j):<> void = let val tmp = v.[i] in v.[i] := v.[j]; v.[j] := tmp end // end of [swap] (* ****** ****** *) fun qsort {n:nat} {left,right:int} {0 <= left; left <= right+1; right+1 <= n} .. ( v: &(@[int][n]), left: int left, right: int right ) :<> void = if (left >= right) then () else let val () = swap (v, left, (left + right) / 2) val piv = v.[left]; val left1 = left + 1 val last = loop (v, left1, left1) where { fun loop {last,i:nat} {left < last; last <= i; i <= right+1} .. (v: &(@[int][n]), last: int last, i: int i) : intBtw (left, right+1) = if i <= right then ( if v.[i] < piv then begin swap (v, last, i); loop (v, last+1, i+1) end else begin loop (v, last, i+1) end // end of [if] ) else ( last - 1 // loop exits ) // end of [if] } // end of [val] in swap (v, left, last); qsort (v, left, last-1); qsort (v, last+1, right) end // end of [if] // end of [qsort] (* ****** ****** *) implement main () = let fn pr {n:nat} (v: &(@[int][n]), n: int n): void = loop (v, n, 0) where { fun loop {i:nat | i <= n} .. (v: &(@[int][n]), n: int n, i: int i): void = if i < n then (if i > 0 then print ", "; print v.[i]; loop (v, n, i+1)) // end of [if] } var !p_arr with pf_arr = @[int](8, 7, 1, 3, 9, 4, 2, 0, 6, 5) val () = (print "bef: "; pr (!p_arr, 10); print_newline ()) val () = qsort (!p_arr, 0, 9) val () = (print "aft: "; pr (!p_arr, 10); print_newline ()) in // empty end // end of [main] (* ****** ****** *) (* end of [qsort.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter04/atof.dats0000664000175000017500000000413712223166161024417 0ustar hwxihwxi// // K&R, 2nd edition, page 71 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) extern fun atof (s: string):<> double implement atof (s) = let val [n:int] s = string1_of_string s var i: sizeLte n // uninitialized val () = i := loop (s, 0) where { fun loop {i:nat | i <= n} .. (s: string n, i: size_t i):<> sizeLte n = if string_is_atend (s, i) then i else let val c = s[i] in if char_isspace c then loop (s, i+1) else i end // end of [if] } // end of [val] var sgn: int = 1; val () = if string_is_atend (s, i) then () else let val c = s[i] in case+ c of | '-' => (i := i + 1; sgn := ~1) | '+' => (i := i + 1) | _ (* no sign *) => () end // end of [if] var d: double = 0.0 val () = i := loop (s, i, d) where { fun loop {i:nat | i <= n} .. (s: string n, i: size_t i, d: &double):<> sizeLte n = if string_is_atend (s, i) then i else let val c = s[i] in if char_isdigit c then begin d := 10.0 * d + double_of_int (c - '0'); loop (s, i+1, d) end else begin i // loop exists end // end of [if] end // end of [if] } // end of [val] val () = if string_is_atend (s, i) then () else ( if (s[i] = '.') then (i := i + 1) else () ) // end of [if] var pow: double = 1.0 val () = i := loop (s, i, pow, d) where { fun loop {i:nat | i <= n} .. (s: string n, i: size_t i, pow: &double, d: &double):<> sizeLte n = if string_is_atend (s, i) then i (* loop exists *) else let val c = s[i] in if char_isdigit c then begin d := 10.0 * d + double_of_int (c - '0'); pow := 10.0 * pow; loop (s, i+1, pow, d) end else begin i // loop exists end // end of [if] end // end of [if] } // end of [val] val () = d := d / pow in if sgn >= 0 then d else ~d end // end of [atof] implement main (argc, argv) = let val () = assert (argc >= 2) in print (atof argv.[1]); print_newline () end // end of [main] (* ****** ****** *) (* end of [atof.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter04/Makefile0000664000175000017500000000161412223166161024246 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 4 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: atof cleanall:: ; $(RMF) atof atof: atof.dats ; $(ATSCC) -o atof atof.dats checkall:: printd cleanall:: ; $(RMF) printd printd: printd.dats ; $(ATSCC) -o printd printd.dats checkall:: qsort cleanall:: ; $(RMF) qsort qsort: qsort.dats ; $(ATSCC) -o qsort qsort.dats ###### html:: ; $(ATSOPT) --posmark_html -d atof.dats > atof_dats.html html:: ; $(ATSOPT) --posmark_html -d printd.dats > printd_dats.html html:: ; $(ATSOPT) --posmark_html -d qsort.dats > qsort_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter04/printd.dats0000664000175000017500000000122112223166161024755 0ustar hwxihwxi// // K&R, 2nd edition, page 87 // (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) extern fun printd (n: int): void implement printd (n) = let var n: int = n val () = if (n < 0) then begin let val _ = putchar '-' in n := ~n end end // end of [val] val () = if (n / 10 > 0) then printd (n / 10) val _ = putchar (char_of_int (n mod 10 + int_of_char '0')) in // empty end // end of [printd] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val n = int_of_string (argv.[1]) in printd (n); print_newline () end // end of [main] (* ****** ****** *) (* end of [printd.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Makefile0000664000175000017500000000457212223166161022522 0ustar hwxihwxi# # # Makefile for some K&R examples # # ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: ; make -C Chapter01 checkall checkall:: ; make -C Chapter02 checkall checkall:: ; make -C Chapter03 checkall checkall:: ; make -C Chapter04 checkall checkall:: ; make -C Chapter05 checkall checkall:: ; make -C Chapter06 checkall checkall:: ; make -C Chapter07 checkall checkall:: ; make -C Chapter08 checkall ###### cleanall:: ; make -C Chapter01 cleanall cleanall:: ; make -C Chapter02 cleanall cleanall:: ; make -C Chapter03 cleanall cleanall:: ; make -C Chapter04 cleanall cleanall:: ; make -C Chapter05 cleanall cleanall:: ; make -C Chapter06 cleanall cleanall:: ; make -C Chapter07 cleanall cleanall:: ; make -C Chapter08 cleanall ###### html:: ; make -C Chapter01 html html:: ; make -C Chapter02 html html:: ; make -C Chapter03 html html:: ; make -C Chapter04 html html:: ; make -C Chapter05 html html:: ; make -C Chapter06 html html:: ; make -C Chapter07 html html:: ; make -C Chapter08 html ###### upload:: upload01 upload01:: ; scp Chapter01/*.dats Chapter01/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter01 upload:: upload02 upload02:: ; scp Chapter02/*.dats Chapter02/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter02 upload:: upload03 upload03:: ; scp Chapter03/*.dats Chapter03/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter03 upload:: upload04 upload04:: ; scp Chapter04/*.dats Chapter04/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter04 upload:: upload05 upload05:: ; scp Chapter05/*.dats Chapter05/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter05 upload:: upload06 upload06:: ; scp Chapter06/*.dats Chapter06/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter06 upload:: upload07 upload07:: ; scp Chapter07/*.dats Chapter07/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter07 upload:: upload08 upload08:: ; scp Chapter08/*.dats Chapter08/*_dats.html \ ats-hwxi,ats-lang@web.sourceforge.net:htdocs/htdocs-old/EXAMPLE/KernighanRitchie/Chapter08 ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter03/0000700000175000017500000000000012223166161022567 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter03/atoi.dats0000664000175000017500000000401612223166161024415 0ustar hwxihwxi// // K&R, 2nd edition, page 61 // (* int atoi (char s[]) { int i, n, sgn ; n = 0 ; for (i = 0; isspace(s[i]); ++i) ; /* skip white space */ sgn = (s[i] == '-') ? -1 : 1 ; if (s[i] == '+' || s[i] == '-') ++i ; for (i = 0; s[i] >= '0' && s[i] <= '9'; ++i) n = 10 * n + (s[i] - '0') ; return sgn * n ; } /* end of [atoi] */ *) (* ****** ****** *) extern fun digit_val_get (c: char):<> intBtw (~1, 10) implement digit_val_get (c) = let val c = char1_of_char (c) in if c >= '0' then (if c <= '9' then c - '0' else ~1) else ~1 end // end of [digit_val_get] (* ****** ****** *) extern fun atoi {m,n:nat | n < m} (buf: &strbuf (m, n)):<> int implement atoi {m,n} (buf) = let typedef buf_t = strbuf (m, n) var i: sizeLte n = loop (buf, 0) where { // skip white space fun loop {i:nat | i <= n} .. (buf: &buf_t, i: size_t i):<> sizeLte n = if strbuf_is_atend (buf, i) then i else begin if char_isspace buf[i] then loop (buf, i+1) else i end // end of [if] // end of [loop] } // end of [val] in if strbuf_is_atend (buf, i) then 0 else let val c = buf[i] val sgn = (if c = '-' then ~1 else 1): int; val () = begin if c = '+' then i := i + 1 else if c = '-' then i := i + 1 else () end : void val n = loop (buf, i, 0) where { fun loop {i:nat | i <= n} .. (buf: &buf_t, i: size_t i, res: int):<> int = if strbuf_is_atend (buf, i) then res else let val d = digit_val_get buf[i] in if d >= 0 then loop (buf, i+1, 10 * res + d) else res end // end of [if] // end of [loop] } // end of [val] in sgn * n end // end of [if] end // end of [atoi] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val str = string1_of_string (argv.[1]) val int = atoi (!p_buf) where { val (vbox pf_buf | p_buf) = strbuf_of_string1 str } // end of [val] in printf ("str = %s and int = %i\n", @(str, int)) end // end of [main] (* ****** ****** *) (* end of [atoi.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter03/itoa.dats0000664000175000017500000000637312223166161024425 0ustar hwxihwxi// // K&R, 2nd edition, page 64 // (* /* ** itoa: convert [n] to characters */ void itoa (int n, char s[]) { int i, sgn ; if ((sgn = n) < 0) n = -n ; i = 0 ; do { /* generate digits in reverse order */ s[i++] = n % 10 + '0' ; } while ((n /= 10) > 0) ; if (sgn < 0) s[i++] = '-' ; s[i] = '\0' ; reverse (s) ; return ; } /* end of [iota] */ *) (* ****** ****** *) dataview itoa_v (bsz:int, l:addr, int) = | itoa_v_succ (bsz, l, 0) of strbuf bsz @ l | itoa_v_fail (bsz, l, ~1) of b0ytes bsz @ l // end of [itoa_v] // [itoa_err] reports an error if the buffer is not long enough extern fun itoa_err {bsz:pos} {l:addr} (pf_buf: b0ytes bsz @ l | n: int, p_buf: ptr l, bsz: int bsz) :<> [p:int] (itoa_v (bsz, l, p) | int p) // end of [itoa_err] (* ****** ****** *) typedef chars (n:int) = @[char][n] (* ****** ****** *) %{^ ats_char_type char_of_digit (ats_int_type i) { return (i + '0') ; } %} extern fun char_of_digit (d: natLt 10):<> char = "char_of_digit" (* ****** ****** *) %{^ ats_void_type strbuf_reverse (ats_ptr_type s0) { char *s = (char*)s0 ; int c, i, j ; for (i = 0, j = strlen(s) - 1; i < j; i++, j--) { c = s[i]; s[i] = s[j]; s[j] = c; } return ; } /* end of [strbuf_reverse] */ %} extern fun strbuf_reverse {m,n:nat | n < m} (s: &strbuf (m, n)):<> void = "strbuf_reverse" // end of [strbuf_reverse] (* ****** ****** *) implement itoa_err {bsz} {l} (pf_buf | n, p_buf, bsz) = let fun loop (n: Nat, buf: &chars bsz, bsz: int bsz, i: &Nat): void = if i < bsz then begin if n > 0 then let val d = n nmod 10 val () = buf.[i] := char_of_digit (d) val () = i := i + 1 in loop (n / 10, buf, bsz, i) end else begin // loop exits normally end // end of [if] end // end of [if] // end of [loop] var i: Nat = 0 prval pf1_buf = chars_v_of_b0ytes_v (pf_buf) val n = int1_of_int n val n_abs = (if n >= 0 then n else ~n): Nat val () = $effmask_all (loop (n_abs, !p_buf, bsz, i)) val () = if i = 0 then (p_buf->[0] := '0'; i := 1) val () = if n < 0 then begin if i < bsz then (p_buf->[i] := '-'; i := i + 1) end // end of [val] in if i < bsz then let prval pf_buf = bytes_v_of_chars_v (pf1_buf) val () = bytes_strbuf_trans (pf_buf | p_buf, size1_of_int1 i) val () = strbuf_reverse (!p_buf) in (itoa_v_succ (pf_buf) | 0) end else let prval pf_buf = bytes_v_of_chars_v (pf1_buf) in (itoa_v_fail (pf_buf) | ~1) end // end of [if] end // end of [itoa_err] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val n = int_of_string (argv.[1]) #define bsz 16 var !p_buf with pf_buf = @[byte][bsz]() val (pf_itoa | err) = itoa_err (pf_buf | n, p_buf, bsz) in if :(pf_buf: b0ytes bsz @ p_buf) => err >= 0 then let prval itoa_v_succ pf1_buf = pf_itoa val () = print (__cast p_buf) where { extern castfn __cast (p: ptr): string } val () = print_newline () prval () = pf_buf := bytes_v_of_strbuf_v (pf1_buf) in // empty end else let // err < 0 prval itoa_v_fail pf1_buf = pf_itoa val () = (print "?"; print_newline ()) prval () = pf_buf := pf1_buf in // empty end // end of [if] end // end of [main] (* ****** ****** *) (* end of [itoa.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter03/Makefile0000664000175000017500000000161412223166161024245 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 3 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: atoi cleanall:: ; $(RMF) atoi atoi: atoi.dats ; $(ATSCC) -o atoi atoi.dats checkall:: reverse cleanall:: ; $(RMF) reverse reverse: reverse.dats ; $(ATSCC) -o reverse reverse.dats checkall:: itoa cleanall:: ; $(RMF) itoa itoa: itoa.dats ; $(ATSCC) -o itoa itoa.dats ###### html:: ; $(ATSOPT) --posmark_html -d atoi.dats > atoi_dats.html html:: ; $(ATSOPT) --posmark_html -d reverse.dats > reverse_dats.html html:: ; $(ATSOPT) --posmark_html -d itoa.dats > itoa_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter03/reverse.dats0000664000175000017500000000274512223166161025143 0ustar hwxihwxi// // K&R, 2nd edition, page 62 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) extern fun strbuf_swap {m,n:nat | n < m} (s: &strbuf (m, n), i: natLte n, j: natLte n):<> void = "strbuf_swap" extern fun reverse {m,n:nat | n < m} (s: &strbuf (m, n)): void = "strbuf_reverse" implement reverse {m,n} (s) = loop {0,n} (s, 0, n - 1) where { val n = strbuf_length s; val n = int1_of_size1 n fun loop {i,j:nat | i+j==n} .. (s: &strbuf (m, n), i: int i, j1: int (j-1)): void = if i < j1 then begin strbuf_swap (s, i, j1); loop {i+1,j-1} (s, i+1, j1-1) end // end of [if] } // end of [reverse] %{^ ats_void_type strbuf_swap (ats_ref_type s0, ats_int_type i, ats_int_type j) { char *s = s0; int c ; c = s[i]; s[i] = s[j]; s[j] = c ; return ; } %} (* ****** ****** *) #define BUFLEN 1024 val alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" implement main () = let var !p_buf with pf_buf = @[byte][BUFLEN]() val () = strbuf_initialize_substring (pf_buf | p_buf, alphabet, 0, 26) val () = print "reverse bef: " val () = print_string (__cast p_buf) where { extern castfn __cast (p: ptr): string } val () = print_newline () val () = print "reverse aft: " val () = reverse (!p_buf) val () = print_string (__cast p_buf) where { extern castfn __cast (p: ptr): string } val () = print_newline () prval () = pf_buf := bytes_v_of_strbuf_v (pf_buf) in // empty end // end of [main] (* ****** ****** *) (* end of [reverse.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/0000700000175000017500000000000012223166161022571 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/strcmp.dats0000664000175000017500000000266112223166161024777 0ustar hwxihwxi// // K&R, 2nd edition, page 106 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* int strcmp (char *s, char *t) { int i; for (i = 0; s[i] == t[i]; ++i) if (!s[i]) return 0 ; return s[i] - t[i] ; } *) extern fun strcmp {m1,n1:nat | n1 < m1} {m2,n2:nat | n2 < m2} ( s1: &strbuf (m1, n1), s2: &strbuf (m2, n2) ) :<> Sgn #define NUL '\0' implement strcmp {m1,n1} {m2,n2} (s1, s2) = loop (s1, s2, 0) where { fun loop {i:nat | i <= n1; i <= n2} .. (s1: &strbuf (m1, n1), s2: &strbuf (m2, n2), i: size_t i):<> Sgn = let val c1 = strbuf_test_char_at (s1, i) and c2 = strbuf_test_char_at (s2, i) in if c1 = NUL then if c2 = NUL then 0 else ~1 else if c2 = NUL then 1 else begin if c1 < c2 then ~1 else if c1 > c2 then 1 else loop (s1, s2, i+1) end // end of [if] // end of [if] end // end of [loop] } (* end of [strcmp] *) (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 3) val str1 = string1_of_string (argv.[1]) and str2 = string1_of_string (argv.[2]) val sgn = let val (vbox pf1_buf | p1_buf) = strbuf_of_string1 str1 in $effmask_all let val (vbox pf2_buf | p2_buf) = strbuf_of_string1 str2 in strcmp (!p1_buf, !p2_buf) end // end of [let] end // end of [val] in printf ("strcmp (%s, %s) = %i\n", @(str1, str2, sgn)) end // end of [main] (* ****** ****** *) (* end of [strcmp.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/strcpy.dats0000664000175000017500000000534712223166161025017 0ustar hwxihwxi// // K&R, 2nd edition, page 105 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) extern fun strcpy {m1:nat} {m2,n2:nat | n2 < m1} {l1:addr} ( pf1: !b0ytes m1 @ l1 >> strbuf (m1, n2) @ l1 | p1: ptr l1 , s2: &strbuf (m2, n2) ) :<> void (* ****** ****** *) (* // the following is declared in [prelude/SATS/string.sats] viewdef strbuf_v (m: int, n: int, l:addr) = strbuf (m, n) @ l praxi strbuf_v_null {n:nat} {l:addr} (pf1: char NUL @ l, pf2: b0ytes (n) @ l + 1): strbuf_v (n+1, 0, l) praxi strbuf_v_cons {c: char | c <> NUL} {m,n:nat} {l:addr} (pf1: char c @ l, pf2: strbuf_v (m, n, l+1)): strbuf_v (m+1, n+1, l) dataview strbufopt_v (int, int, addr, char) = | {m:nat} {l:addr} strbufopt_v_none (m, ~1, l, NUL) of b0ytes m @ l | {m,n:nat} {l:addr} {c:char | c <> NUL} strbufopt_v_some (m, n, l, c) of strbuf_v (m, n, l) praxi strbuf_v_uncons {m,n:nat | n < m} {l:addr} (pf: strbuf_v (m, n, l)) : [c:char] @(char c @ l, strbufopt_v (m-1, n-1, l+1, c)) *) (* ****** ****** *) #define NUL '\000' implement strcpy (pf1 | p1, s2) = loop (pf1, view@ s2 | p1, &s2) where { fun loop {m1:nat} {m2,n2:nat | n2 < m1} {l1,l2:addr} .. ( pf1: !b0ytes m1 @ l1 >> strbuf_v (m1, n2, l1) , pf2: !strbuf_v (m2, n2, l2) | p1: ptr l1, p2: ptr l2 ) :<> void = let prval (pf21, pf22) = strbuf_v_uncons (pf2) val c = !p2 prval (pf11, pf12) = array_v_uncons {byte?} (pf1) prval () = pf11 := char_v_of_b0yte_v (pf11) val () = !p1 := c in if c = NUL then let prval () = eqsize_byte_char () prval () = pf1 := strbuf_v_null (pf11, pf12) prval strbufopt_v_none (pf22) = pf22 prval () = pf2 := strbuf_v_null (pf21, pf22) in // empty end else let prval () = eqsize_byte_char () prval strbufopt_v_some (pf22) = pf22 val () = loop (pf12, pf22 | p1+sizeof, p2+sizeof) prval () = pf1 := strbuf_v_cons (pf11, pf12) prval () = pf2 := strbuf_v_cons (pf21, pf22) in // empty end // end of [if] end // end of [loop] } // end of [strcpy] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val str = string1_of_string (argv.[1]) val len = string_length (str) var !p_buf_new with pf_buf_new = @[byte][len+1]() val () = let val (vbox pf_buf | p_buf) = strbuf_of_string1 str in strcpy (pf_buf_new | p_buf_new, !p_buf) end // end of [val] val () = printf ("strcpy (%s) = ", @(str)) val () = print (__cast p_buf_new) where { extern castfn __cast (p: ptr): string } // end of [val] val () = print_newline () prval () = pf_buf_new := bytes_v_of_strbuf_v (pf_buf_new) in // empty end // end of [main] (* ****** ****** *) (* end of [strcpy.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/Makefile0000664000175000017500000000322512223166161024247 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 5 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: getint cleanall:: ; $(RMF) getint getint: getint.dats ; $(ATSCC) -o getint getint.dats checkall:: strlen cleanall:: ; $(RMF) strlen strlen: strlen.dats ; $(ATSCC) -o strlen strlen.dats checkall:: strcpy cleanall:: ; $(RMF) strcpy strcpy: strcpy.dats ; $(ATSCC) -o strcpy strcpy.dats checkall:: strcmp cleanall:: ; $(RMF) strcmp strcmp: strcmp.dats ; $(ATSCC) -o strcmp strcmp.dats checkall:: strcmp_alt cleanall:: ; $(RMF) strcmp_alt strcmp_alt: strcmp_alt.dats; $(ATSCC) -o strcmp_alt strcmp_alt.dats checkall:: month_name cleanall:: ; $(RMF) month_name month_name: month_name.dats ; $(ATSCC) -o month_name month_name.dats checkall:: month_day cleanall:: ; $(RMF) month_day month_day: month_day.dats ; $(ATSCC) -o month_day month_day.dats ###### html:: ; $(ATSOPT) --posmark_html -d getint.dats > getint_dats.html html:: ; $(ATSOPT) --posmark_html -d strlen.dats > strlen_dats.html html:: ; $(ATSOPT) --posmark_html -d strcpy.dats > strcpy_dats.html html:: ; $(ATSOPT) --posmark_html -d strcmp.dats > strcmp_dats.html html:: ; $(ATSOPT) --posmark_html -d strcmp_alt.dats > strcmp_alt_dats.html html:: ; $(ATSOPT) --posmark_html -d month_name.dats > month_name_dats.html html:: ; $(ATSOPT) --posmark_html -d month_day.dats > month_day_dats.html ###### RMF=rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/strcmp_alt.dats0000664000175000017500000000737512223166161025646 0ustar hwxihwxi// // K&R, 2nd edition, page 106 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) extern fun strcmp {m1,n1:nat} {m2,n2:nat} ( s1: &strbuf (m1, n1), s2: &strbuf (m2, n2) ) :<> Sgn (* ****** ****** *) (* // // This is the pointer version of [strcmp]. Handling C-strings // in such a style requires a great deal of effort being spent on // proof manipulation. However, the generated C code from this // implementation is just as efficient as a corresponding version // manually written in C. // // the following is declared in [prelude/SATS/string.sats] viewdef strbuf_v (m: int, n: int, l:addr) = strbuf (m, n) @ l praxi strbuf_v_null {n:nat} {l:addr} (pf1: char NUL @ l, pf2: b0ytes (n) @ l + sizeof(byte)) : strbuf_v (n+1, 0, l) praxi strbuf_v_cons {c: char | c <> NUL} {m,n:nat} {l:addr} (pf1: char c @ l, pf2: strbuf_v (m, n, l + sizeof(byte))) : strbuf_v (m+1, n+1, l) dataview strbufopt_v (int, int, addr, char) = | {m:nat} {l:addr} strbufopt_v_none (m, ~1, l, NUL) of b0ytes m @ l | {m,n:nat} {l:addr} {c:char | c <> NUL} strbufopt_v_some (m, n, l, c) of strbuf_v (m, n, l) praxi strbuf_v_uncons {m,n:nat} {l:addr} (pf: strbuf_v (m, n, l)) : [c:char] @( char c @ l, strbufopt_v (m-1, n-1, l + sizeof(byte), c) ) *) (* ****** ****** *) #define NUL '\000' implement strcmp (s1, s2) = loop (view@ s1, view@ s2 | &s1, &s2) where { fun loop {m1,n1:nat} {m2,n2:nat} {l1,l2:addr} .. ( pf1: !strbuf_v (m1, n1, l1) , pf2: !strbuf_v (m2, n2, l2) | p1: ptr l1, p2: ptr l2 ) :<> Sgn = let prval (pf11, pf12) = strbuf_v_uncons (pf1) prval (pf21, pf22) = strbuf_v_uncons (pf2) val c1 = !p1 and c2 = !p2 in if c1 = NUL then begin if c2 = NUL then let prval strbufopt_v_none (pf12) = pf12 prval () = pf1 := strbuf_v_null (pf11, pf12) prval strbufopt_v_none (pf22) = pf22 prval () = pf2 := strbuf_v_null (pf21, pf22) in 0 // loop exits end else let prval strbufopt_v_none (pf12) = pf12 prval () = pf1 := strbuf_v_null (pf11, pf12) prval strbufopt_v_some (pf22) = pf22 prval () = pf2 := strbuf_v_cons (pf21, pf22) in ~1 // loop exits end // end of [if] end else begin // c1 <> NUL if c2 = NUL then let prval strbufopt_v_some (pf12) = pf12 prval () = pf1 := strbuf_v_cons (pf11, pf12) prval strbufopt_v_none (pf22) = pf22 prval () = pf2 := strbuf_v_null (pf21, pf22) in 1 // loop exits end else let // c2 <> NUL prval strbufopt_v_some (pf12) = pf12 prval strbufopt_v_some (pf22) = pf22 val sgn = compare (c1, c2) in if sgn = 0 then let // c1 = c2 val sgn = loop (pf12, pf22 | p1+sizeof, p2+sizeof) prval () = pf1 := strbuf_v_cons (pf11, pf12) prval () = pf2 := strbuf_v_cons (pf21, pf22) in sgn end else let // c1 <> c2 prval () = pf1 := strbuf_v_cons (pf11, pf12) prval () = pf2 := strbuf_v_cons (pf21, pf22) in sgn // loop exits end (* end of [if] *) end // end of [if] end (* end of [if] *) end // end of [loop] } (* end of [strcmp] *) (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 3) val str1 = string1_of_string (argv.[1]) and str2 = string1_of_string (argv.[2]) val sgn = let val (vbox pf1_buf | p1_buf) = strbuf_of_string1 str1 in $effmask_all let val (vbox pf2_buf | p2_buf) = strbuf_of_string1 str2 in strcmp (!p1_buf, !p2_buf) end // end of [let] end // end of [val] in printf ("strcmp (%s, %s) = %i\n", @(str1, str2, sgn)) end // end of [main] (* ****** ****** *) (* end of [strcmp_alt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/getint.dats0000664000175000017500000000403512223166161024756 0ustar hwxihwxi// // K&R, 2nd edition, page 97 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) staload "libc/SATS/stdio.sats" (* ****** ****** *) extern fun getint {l:addr} (pf: !int? @ l >> int @ l | pn: ptr l): void implement getint {l} (pf | pn) = let var c: int // unintialized val () = loop (c) where { fun loop (c: &int? >> int): void = let val () = c := getchar1 () in if c >= 0 then // c <> EOF (if char_isspace (char_of_int1 c) then loop (c) else ()) else () end // end of [loop] } // end of [val] var isnum: bool = false val () = if c <> EOF then begin case+ char_of_int (c) of | c when char_isdigit c => (isnum := true) | '+' => (isnum := true) | '-' => (isnum := true) | c => ungetc_exn (c, stdin_ref) end // end of [if] in if :(pf: int @ l) => isnum then let var sgn: int = 1 val () = case+ char_of_int (c) of '-' => (sgn := ~1) | _ => () val () = case+ char_of_int (c) of | '+' => (c := getchar ()) | '-' => (c := getchar ()) | _ => () val () = !pn := 0 val () = loop (pf | pn, c) where { fun loop (pf: !int @ l >> int @ l | pn: ptr l, c: &int): void = if c <> EOF then let val c1 = char_of_int c in if char_isdigit (c1) then begin !pn := 10 * !pn + (c1 - '0'); c := getchar (); loop (pf | pn, c) end else begin // loop exists end // end of [if] end // end of [if] } // end of [val] val () = if c <> EOF then ungetc_exn (char_of_int c, stdin_ref) in !pn := sgn * !pn end else begin !pn := 0 // it is not a number end // end of [if] end // end of [getint] (* ****** ****** *) implement main (argc, argv) = let var int1: int // uninitialized val () = getint (view@ int1 | &int1) val () = (print int1; print_newline ()) var int2: int // uninitialized val () = getint (view@ int2 | &int2) val () = (print int2; print_newline ()) in // empty end // end of [main] (* ****** ****** *) (* end of [getint.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/month_name.dats0000664000175000017500000000146512223166161025615 0ustar hwxihwxi// // K&R, 2nd edition, page 113 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) staload "prelude/DATS/array.dats" #define NMONTH 12 extern fun month_name (nmonth: intBtw (1, NMONTH+1)): string local val month_name_arr = array_make_arrsz {string} $arrsz( "January" , "February" , "March" , "April" , "May" , "June" , "July" , "August" , "September" , "October" , "November" , "December" ) // end of [val] in implement month_name (nmonth) = month_name_arr[nmonth-1] end // end of [local] (* ****** ****** *) implement main () = let var i: intGt 0 // uninitialized val () = for (i := 1; i <= NMONTH; i := i + 1) begin printf ("month_name[%i] = %s\n", @(i, month_name (i))) ; end // end of [val] in // empty end // end of [main] (* ****** ****** *) (* end of [month_name.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/strlen.dats0000664000175000017500000000402312223166161024770 0ustar hwxihwxi// // K&R, 2nd edition, page 103 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) /* int strlen (char *s) { char *p = s ; while (*p != '\000') ++p ; return (p - s) ; } */ (* // this is the version in Chapter2: implement strlen {m,n} (s) = loop (s, 0) where { fun loop {i:nat | i <= n} .. (s: &strbuf (m, n), i: int i):<> int n = if strbuf_is_at_end (s, i) then i else loop (s, i+1) // end of [loop] } // end of [strlen] *) (* ****** ****** *) extern fun strlen {m,n:nat} (s: &strbuf (m, n)):<> size_t n (* ****** ****** *) #define NUL '\000' implement strlen {m,n} (s) = let stadef bsz = sizeof(byte) macdef bsz = sizeof fun loop {m,n:nat} {l:addr} {ofs:int} .. ( pf: !strbuf (m, n) @ l , pf_mul: MUL (n, bsz, ofs) | p: ptr l ) :<> ptr (l + ofs) = let prval (pf1, pf2) = strbuf_v_uncons (pf) val c = !p in if (c = NUL) then let prval strbufopt_v_none pf2 = pf2 prval MULbas () = pf_mul in pf := strbuf_v_null (pf1, pf2); p end else let prval () = eqsize_byte_char () prval strbufopt_v_some pf2 = pf2 prval pf1_mul = mul_add_const {~1} (pf_mul) val p_end = loop (pf2, pf1_mul | p+bsz) in pf := strbuf_v_cons (pf1, pf2); p_end end // end of [if] end // end of [loop] val p_beg = &s prval pf_mul = mul_istot {n,bsz} () val p_end = loop (view@ s, pf_mul | p_beg) prval () = eqsize_byte_one () where { extern praxi eqsize_byte_one (): [sizeof byte == 1] void } // end of [val] prval () = mul_elim {n,1} (pf_mul) in size1_of_ptrdiff1 (p_end - p_beg) end // end of [strlen] (* ****** ****** *) implement main (argc, argv) = let val () = assert (argc >= 2) val str = argv.[1] val int = strlen (!p_buf) where { val str = string1_of_string str val (vbox pf_buf | p_buf) = strbuf_of_string1 str } // end of [val] in printf ("strlen (%s) = ", @(str)); print_size int; print_newline () end // end of [main] (* ****** ****** *) (* end of [strlen.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter05/month_day.dats0000664000175000017500000000236012223166161025445 0ustar hwxihwxi// // K&R, 2nd edition, page 111 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) staload "prelude/DATS/matrix.dats" #define NMONTH 12 #define NMONTH1 NMONTH + 1 val daytab = matrix_make_arrsz {int} (2, 13, $arrsz ( 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 , 0, 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 )) // end of [val] fn isleap (year: int): natLt 2 = if year mod 4 = 0 then if year mod 100 = 0 then (if year mod 400 = 0 then 1 else 0) else 1 // end of [if] else 0 // end of [isleap] extern fun month_day (year: int, yday: int, month: &int? >> int, day: &int? >> int): void implement month_day (year, yday, month, day) = let var i: intGt 0 // uninitialized var year: int = year and yday: int = yday val leap = isleap (year) val () = for (i := 1; i < NMONTH; i := i + 1) let val mday = daytab[leap, NMONTH1, i] in if yday <= mday then break else (yday := yday - mday) end // end of [val] in month := i ; day := yday ; end // end of [month_day] (* ****** ****** *) implement main () = let var m: int and d: int val () = month_day (1988, 60, m, d) in printf ("m(2) = %i and d(29) = %i\n", @(m, d)) end // end of [main] (* ****** ****** *) (* end of [month_day.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter06/0000700000175000017500000000000012223166161022572 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter06/getword.dats0000664000175000017500000000453712223166161025147 0ustar hwxihwxi// // K&R, 2nd edition, pages 136 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) extern fun getword {lim:int | lim >= 2} {l:addr} (pf: !b0ytes lim @ l >> strbuf lim @ l | word: ptr l, lim: int lim): void (* ****** ****** *) implement getword {lim} {l} (pf | word, lim) = let var c: int // uninitialized val () = loop (c) where { fun loop (c: &int? >> int): void = let val () = c := getchar1 () in if (c >= 0) then begin if char_isspace (char_of_int1 c) then loop (c) else () end // end of [if] end // end of [loop] } // end of [val] prval () = pf := bytes_v_of_b0ytes_v (pf) var i: natLt lim = 0 val () = if c >= 0 then begin if char_isalpha (char_of_int c) then let prval (pf1, pf2) = array_v_uncons {byte} (pf) val () = (!word := byte_of_int c) val nLeft = loop (pf2 | word + sizeof, lim - 2) where { fun loop {n:nat} {l:addr} .. (pf: !bytes (n+1) @ l | p: ptr l, n: int n): natLte n = if n = 0 then 0 (* loop exits *) else let val c = getchar1 () in if c < 0 then n (* loop exits *) else begin if char_isalnum (char_of_int c) then let prval (pf1, pf2) = array_v_uncons {byte} (pf) val () = (!p := byte_of_int c) val nLeft = loop (pf2 | p + sizeof, n-1) val () = pf := array_v_cons {byte} (pf1, pf2) in nLeft end else begin n // loop exits end // end of [if] end // end of [if] end // end of [if] } // end of [val] prval () = pf := array_v_cons {byte} (pf1, pf2) in i := 1 + nLeft end // end of [if] end // end of [val] in bytes_strbuf_trans (pf | word, size1_of_int1 i) end // end of [getword] (* ****** ****** *) #define BUFSZ 16 implement main (argc, argv) = let var !p_buf with pf_buf = @[byte][BUFSZ]() val () = getword (pf_buf | p_buf, BUFSZ) val () = print_string (__cast p_buf) where { extern castfn __cast (p: ptr): string } // end of [val] val () = print_newline () prval () = pf_buf := bytes_v_of_strbuf_v (pf_buf) in // empty end // end of [main] (* ****** ****** *) (* end of [getword.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter06/Makefile0000664000175000017500000000113612223166161024247 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 6 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: getword cleanall:: ; $(RMF) getword getword: getword.dats ; $(ATSCC) -o getword getword.dats ###### html:: ; $(ATSOPT) --posmark_html -d getword.dats > getword_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter08/0000700000175000017500000000000012223166161022574 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter08/fsize.dats0000664000175000017500000001016412223166161024607 0ustar hwxihwxi// // K&R, 2nd edition, pages 181 - 182 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "libc/SATS/dirent.sats" staload "libc/sys/SATS/stat.sats" staload "libc/sys/SATS/types.sats" (* ****** ****** *) %{^ #define MAXPATHLEN 1024 %} // end of [%{^] #define MAXPATHLEN 1024 (* ****** ****** *) extern fun fsize (name: string): void extern fun dirwalk (dir: string, f: (string) -> void): void (* ****** ****** *) implement main (argc, argv) = let fun loop {n,i:nat | i <= n} (A: &(@[string][n]), n: int n, i: int i): void = if i < n then (fsize A.[i]; loop (A, n, i+1)) else () // end of [loop] in if argc = 1 then fsize "." else loop (argv, argc, 1) end // end of [main] (* ****** ****** *) implement fsize (name) = let var stbuf: stat? // uninitialized val err = stat_err (name, stbuf) in if err >= 0 then let prval () = opt_unsome {stat} (stbuf) val mode = stbuf.st_mode in if S_ISDIR (mode) then dirwalk (name, fsize) else let val sz_off = stbuf.st_size val sz_lint = lint_of_off (sz_off) in printf ("%8ld %s\n", @(sz_lint, name)) end // end of [if] end else let prval () = opt_unnone {stat} (stbuf) in // empty end // end of [if] end // end of [fsize] (* ****** ****** *) extern fun dirent_is_self (dp: &dirent):<> bool = "atslib_dirent_is_self" extern fun dirent_is_parent (dp: &dirent):<> bool = "atslib_dirent_is_parent" %{^ ATSinline() ats_bool_type atslib_dirent_is_self (ats_ref_type dp) { int cmp = strcmp (((ats_dirent_type*)dp)->d_name, ".") ; if (cmp == 0) return ats_true_bool ; return ats_false_bool ; } /* end of [atslib_dirent_is_self] */ ATSinline() ats_bool_type atslib_dirent_is_parent (ats_ref_type dp) { int cmp = strcmp (((ats_dirent_type*)dp)->d_name, "..") ; if (cmp == 0) return ats_true_bool ; return ats_false_bool ; } /* end of [atslib_dirent_is_self] */ %} // end of [%{^] (* ****** ****** *) implement dirwalk (dirname, f) = let (* val () = begin prerr "dirwalk: dirname = "; prerr dirname; prerr_newline () end *) #define M MAXPATHLEN typedef buf_t = bytes M var !p_name with pf_name = @[byte][M]() val () = pf_name := bytes_v_of_b0ytes_v (pf_name) val (pfopt_dir | p_dir) = opendir_err (dirname) in if (p_dir > null) then let prval Some_v pf_dir = pfopt_dir fun loop ( buf: &buf_t, dir: &DIR ) : void = let val (pfopt | p_ent) = readdir (dir) in if (p_ent > null) then let prval Some_v @(pf, fpf) = pfopt val () = case+ 0 of | _ when dirent_is_self (!p_ent) => $effmask_ref (loop (buf, dir)) | _ when dirent_is_parent (!p_ent) => $effmask_ref (loop (buf, dir)) | _ => let val direntnameopt = direntnameopt_make ( buf, dirname, !p_ent ) where { extern fun direntnameopt_make ( buf: &buf_t, dir: string, ent: &dirent ) :<> Stropt = "direntnameopt_make" } // end of [val] val () = begin if stropt_is_some (direntnameopt) then begin $effmask_ref (f (stropt_unsome direntnameopt)) end // end of [if] end // end of [val] in $effmask_ref (loop (buf, dir)) end // end of [_] prval () = fpf (pf) in // nothing end else let prval None_v () = pfopt in (* loop exists *) end // end of [if] end // end of [loop] val () = loop (!p_name, !p_dir) in closedir_exn (pf_dir | p_dir) end else let prval None_v () = pfopt_dir in prerrf ("*** ERROR ***: dirwalk: can't open [%s]\n", @(dirname)) end // end of [if] end // end of [dirwalk] (* ****** ****** *) %{^ ats_ptr_type direntnameopt_make ( ats_ref_type buf, ats_ptr_type dir, ats_ref_type ent ) { int cnt ; cnt = snprintf ((char*)buf, MAXPATHLEN, "%s/%s", dir, ((ats_dirent_type*)ent)->d_name) ; if (cnt < MAXPATHLEN) return buf ; return (ats_ptr_type)0 ; } // end of [direntnameopt_make] %} // end of [%{^] (* ****** ****** *) (* end of [fsize.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter08/Makefile0000664000175000017500000000113612223166161024251 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 8 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif # end of [ifeq] ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: fsize cleanall:: ; $(RMF) fsize fsize: fsize.dats ; $(ATSCC) -o fsize fsize.dats ###### html:: ; $(ATSOPT) --posmark_html -d fsize.dats > fsize_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter02/0000700000175000017500000000000012223166161022566 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter02/Makefile0000664000175000017500000000142312223166161024242 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 2 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif # end of [ifeq] ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: strlen cleanall:: ; $(RMF) strlen strlen: strlen.dats $(ATSCC) -o $@ $^ && ./$@ "abcdefghijklmnopqrstuvwxyz" checkall:: rand cleanall:: ; $(RMF) rand rand: rand.dats ; $(ATSCC) -o $@ $^ && ./$@ ###### html:: ; $(ATSOPT) --posmark_html -d strlen.dats > strlen_dats.html html:: ; $(ATSOPT) --posmark_html -d rand.dats > rand_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter02/strlen.dats0000664000175000017500000000160612223166161024771 0ustar hwxihwxi// // K&R, 2nd edition, page 39 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* int strlen (char s[]) { int i ; i = 0 ; while (s[i] != '\0') ++i ; return i ; } /* end of [strlen] */ *) extern fun strlen {m,n:nat} (buf: &strbuf (m, n)):<> size_t n implement strlen {m,n} (buf) = loop (buf, 0) where { fun loop {i:nat | i <= n} .. (buf: &strbuf (m, n), i: size_t i):<> size_t n = if strbuf_is_atend (buf, i) then i else loop (buf, i+1) } // end of [strlen] (* ****** ****** *) implement main (argc, argv) = let val () = assertloc (argc >= 2) val str = string1_of_string (argv.[1]) val len = strlen (!p_buf) where { val (vbox pf_buf | p_buf) = strbuf_of_string1 str } // end of [val] in print "str = "; print str; print " and len = "; print len; print_newline () end // end of [main] (* ****** ****** *) (* end of [strlen.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter02/rand.dats0000664000175000017500000000254612223166161024412 0ustar hwxihwxi// // K&R, 2nd edition, page 46 // // // Translated into ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) // (* unsigned long int next = 1 ; /* rand: return pseudo-randon integer on 0..32767 */ int rand (void) { next = next * 1103515245L + 12345 ; return (unsigned int)(next / 65536) % 32768 ; } /* end of [rand] */ int srand (unsigned int seed) { next = seed ; return ; } *) (* ****** ****** *) staload TIME = "libc/SATS/time.sats" (* ****** ****** *) extern fun rand (): int extern fun srand (seed: ulint): void (* ****** ****** *) local var next: ulint = 1UL // HX: avoid heap-allocation val next = ref_make_view_ptr {ulint} (view@ (next) | &next) in implement rand () = let val n = !next * 1103515245UL + 12345UL val () = !next := n val quot = uint_of_ulint (n / 65536UL) val quot = uint1_of_uint (quot) in quot uimod 32768 end // end of [rand] implement srand (seed) = !next := seed end // end of [local] (* ****** ****** *) implement main () = let val t = $TIME.time_get () val t = $TIME.lint_of_time t val () = srand (ulint_of_lint t) val r0 = rand () val () = (print "r0 = "; print r0; print_newline ()) val r1 = rand () val () = (print "r1 = "; print r1; print_newline ()) val r2 = rand () val () = (print "r2 = "; print r2; print_newline ()) in // empty end // end of [main] (* ****** ****** *) (* end of [rand.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter07/0000700000175000017500000000000012223166161022573 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter07/filecopy.dats0000664000175000017500000000467112223166161025306 0ustar hwxihwxi// // K&R, 2nd edition, pages 163 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload UNSAFE = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) extern fun filecopy {m1,m2:file_mode} ( pf1: file_mode_lte (m1, r) , pf2: file_mode_lte (m2, w) | ifp: &FILE m1, ofp: &FILE m2 ) : void implement filecopy {m1,m2} (pf1, pf2 | ifp, ofp) = loop (ifp, ofp) where { fun loop (ifp: &FILE m1, ofp: &FILE m2): void = let val c = fgetc_err (pf1 | ifp) in if (c >= 0) then begin // c <> EOF let val _ = fputc_err (pf2 | char_of_int1 c, ofp) in loop (ifp, ofp) end end // end of [if] end // end of [loop] } // end of [filecopy] (* ****** ****** *) implement main {n} (argc, argv) = let val () = case+ argc of | 1 => let val (pf_stdin | p_stdin) = stdin_get () val (pf_stdout | p_stdout) = stdout_get () val () = filecopy (file_mode_lte_r_r, file_mode_lte_w_w | !p_stdin, !p_stdout) val () = stdout_view_set (pf_stdout | (*none*)) val () = stdin_view_set (pf_stdin | (*none*)) in // empty end // end of [1] | _ (*argc >= 2*) => loop (argc, argv, 1) where { fun loop {i:nat | i <= n} (argc: int n, argv: &(@[string][n]), i: int i): void = if i < argc then let val name = argv.[i] val (pfopt | p_ifp) = fopen_err (name, file_mode_r) in if p_ifp > null then let prval Some_v (pf) = pfopt val (pf_stdout | p_stdout) = stdout_get () val () = filecopy (file_mode_lte_r_r, file_mode_lte_w_w | !p_ifp, !p_stdout) val () = stdout_view_set (pf_stdout | (*none*)) val () = fclose_exn (pf | p_ifp) in loop (argc, argv, i+1) end else let prval None_v () = pfopt val () = prerrf ("%s: can't open [%s]\n", @(argv.[0], name)) in exit {void} (1) end // end of [if] end // end of [if] } // end of [_] // end of [val] val (pf_stdout | p_stdout) = stdout_get () val err = ferror (!p_stdout) val () = stdout_view_set (pf_stdout | (*none*)) in if (err <> 0) then begin prerrf ("%s: error writing stdout\n", @(argv.[0])); exit {void} (2) end else begin exit {void} (0) // exit normally end // end of [if] end // end of [main] (* ****** ****** *) (* end of [filecopy.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter07/fgets.dats0000664000175000017500000000715212223166161024601 0ustar hwxihwxi// // K&R, 2nd edition, pages 165 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* /* fgets: get at most n chars from iop */ char *fgets (char *s, int n, FILE *iop) { register int c; register char *cs ; cs = s; while (--n > 0 && (c = fgetc(iop)) != EOF) if (( *cs++ = c) == '\n') break; *cs = '\0'; return (c == EOF && cs == s) ? (char* )0 ; s ; } /* end of [fgets] */ *) (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" (* ****** ****** *) dataview fgets_v (sz:int, addr, addr) = | {l_buf:addr} fgets_v_fail (sz, l_buf, null) of b0ytes (sz) @ l_buf | {n:nat | n < sz} {l_buf:addr | l_buf <> null} fgets_v_succ (sz, l_buf, l_buf) of strbuf (sz, n) @ l_buf extern fun fgets {m:file_mode} {sz,n:nat | n < sz} {l_buf:addr} ( _mod: file_mode_lte (m, r), _buf: b0ytes sz @ l_buf | p_buf: ptr l_buf, n: int n, iop: &FILE m ) : [l:addr] (fgets_v (sz, l_buf, l) | ptr l) (* ****** ****** *) extern praxi lemma_addr_isnot_null {n:pos} {l:addr} (pf: !b0ytes n @ l): [l <> null] void #define i2sz size1_of_int1 implement fgets {m} (pf_mod, pf_buf | p_buf, n, iop) = let var eof: int = 0 prval () = lemma_addr_isnot_null (pf_buf) prval pf_buf = bytes_v_of_b0ytes_v (pf_buf) val nleft = loop (pf_buf | p_buf, n, iop, eof) where { fun loop {sz,n:nat | n < sz} {l:addr} .. ( pf: !bytes sz @ l | p: ptr l, n: int n, iop: &FILE m, eof: &int ) : natLte n = if n > 0 then let val c = $STDIO.fgetc1_err (pf_mod | iop) in if c >= 0 then let // c <> EOF prval @(pf1, pf2) = array_v_uncons {byte} (pf) val () = !p := byte_of_int1 (c) val nleft = begin if char_of_int1 c <> '\n' then loop (pf2 | p+sizeof, n-1, iop, eof) else n-1 end : natLt n // end of [val] prval () = pf := array_v_cons {byte} (pf1, pf2) in nleft end else begin // c = EOF eof := 1; n // loop exits end // end of [if] end else begin 0 // loop exists end // end of [if] } // end of [val] in if eof > 0 then begin if nleft < n then let val () = bytes_strbuf_trans (pf_buf | p_buf, i2sz (n - nleft)) in (fgets_v_succ pf_buf | p_buf) end else begin (fgets_v_fail pf_buf | null) end // end of [if] end else let val () = bytes_strbuf_trans (pf_buf | p_buf, i2sz (n - nleft)) in (fgets_v_succ pf_buf | p_buf) end // end of [if] end // end of [fgets] (* ****** ****** *) #define BUFSZ 1024 implement main (argc, argv) = let #define BUFSZ1 (BUFSZ+1) var !p_buf with pf_buf = @[byte][BUFSZ1]() stadef l_buf = p_buf val (pf_stdin | p_stdin) = stdin_get () val () = loop (pf_buf | p_buf, !p_stdin) where { fun loop ( pf_buf: !b0ytes BUFSZ1 @ l_buf | p_buf: ptr l_buf, iop: &FILE r ) : void = let val (pf1 | p1) = fgets (file_mode_lte_r_r, pf_buf | p_buf, BUFSZ, iop) in if :(pf_buf: b0ytes (BUFSZ+1) @ p_buf) => p1 <> null then let prval fgets_v_succ (pf1) = pf1 val () = print_string (__cast p_buf) where { extern castfn __cast (p: ptr): string } // end of [val] prval () = pf_buf := bytes_v_of_strbuf_v (pf1) in loop (pf_buf | p_buf, iop) end else let prval fgets_v_fail (pf1) = pf1; prval () = pf_buf := pf1 in // no more bytes end // end of [if] end // end of [loop] } // end of [val] val () = stdin_view_set (pf_stdin | (*none*)) in // empty end // end of [main] (* ****** ****** *) (* end of [fgets.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter07/Makefile0000664000175000017500000000164412223166161024254 0ustar hwxihwxi# # # Makefile for K&R examples in Chapter 7 # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) *_?ats.html ###### checkall:: lower cleanall:: ; $(RMF) lower lower: lower.dats ; $(ATSCC) -o lower lower.dats checkall:: fgets cleanall:: ; $(RMF) fgets fgets: fgets.dats ; $(ATSCC) -o fgets fgets.dats checkall:: filecopy cleanall:: ; $(RMF) filecopy filecopy: filecopy.dats ; $(ATSCC) -o filecopy filecopy.dats ###### html:: ; $(ATSOPT) --posmark_html -d lower.dats > lower_dats.html html:: ; $(ATSOPT) --posmark_html -d fgets.dats > fgets_dats.html html:: ; $(ATSOPT) --posmark_html -d filecopy.dats > filecopy_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_?ats.c *_?ats.o ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/KernighanRitchie/Chapter07/lower.dats0000664000175000017500000000102312223166161024610 0ustar hwxihwxi// // K&R, 2nd edition, pages 153 // // Translated to ATS by Hongwei Xi (hwxi AT cs DOT bu DOT edu) (* ****** ****** *) staload "libc/SATS/stdio.sats" (* ****** ****** *) implement main () = let var c: int? in while (true) let val () = c := getchar1 () in if c >= 0 then let // c <> EOF val _ = putchar (char_tolower (char_of_int1 c)) in // empty end else begin break ; end // end of [if] end // end of [while] end // end of [main] (* ****** ****** *) (* end of [lower.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/0000700000175000017500000000000012223166161016353 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/gcd_mt.dats0000664000175000017500000001425012223166161020503 0ustar hwxihwxi// // A multithreaded implementation of GCD in coroutine-style // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: March 10, 2008 // (* ****** ****** *) staload "libc/SATS/pthread.sats" staload _(*anonymous*) = "libc/DATS/pthread.dats" staload "libc/SATS/pthread_uplock.sats" (* ****** ****** *) abstype pthread_mutexref_viewt0ype_type (a: viewt@ype) stadef mutexref_t = pthread_mutexref_viewt0ype_type absview pthread_mutexref_unlock_ticket_viewt0ype_addr_view (viewt@ype, addr) stadef mutexref_unlock_ticket = pthread_mutexref_unlock_ticket_viewt0ype_addr_view extern fun{a:viewt@ype} pthread_mutexref_create (x: a): mutexref_t a extern fun pthread_mutexref_create_tsz {a:viewt@ype} {l:addr} (pf: !a @ l >> a? @ l | p: ptr l, tsz: sizeof_t a): mutexref_t a = "atslib_pthread_mutexref_create_tsz" extern fun pthread_mutexref_lock {a:viewt@ype} (mtxrf: mutexref_t a) : [l:addr] (mutexref_unlock_ticket (a, l), a @ l | ptr l) = "atslib_pthread_mutexref_lock" extern fun pthread_mutexref_unlock {a:viewt@ype} {l:addr} (_tick: mutexref_unlock_ticket (a, l), _at: a @ l | p: ptr l): void = "atslib_pthread_mutexref_unlock" (* ****** ****** *) implement{a} pthread_mutexref_create (x) = let var x = x in pthread_mutexref_create_tsz {a} (view@ (x) | &x, sizeof) end // end of [pthread_mutexref_create] %{^ // // HX-2010-03-28: this style cannot safely support GC // typedef struct { pthread_mutex_t mutex ; void* value[0] ; } pthread_mutexref_struct ; /* ****** ****** */ static inline ats_ptr_type atslib_pthread_mutexref_create_tsz (ats_ptr_type p_x, ats_size_type tsz) { pthread_mutexref_struct *p ; p = ATS_MALLOC(sizeof (pthread_mutexref_struct) + tsz) ; pthread_mutex_init (&(p->mutex), NULL) ; memcpy (&(p->value), p_x, (size_t)tsz) ; return p ; } // end of [atslib_pthread_mutexref_create_tsz] static inline ats_ptr_type atslib_pthread_mutexref_lock (ats_ptr_type p0) { pthread_mutexref_struct *p = p0 ; pthread_mutex_lock (&(p->mutex)) ; return &(p->value) ; } // end of [atslib_pthread_mutexref_lock] static inline ats_void_type atslib_pthread_mutexref_unlock (ats_ptr_type p_value) { pthread_mutex_unlock ( (pthread_mutex_t*)((char*)p_value - sizeof(pthread_mutexref_struct)) ) ; return ; } // end of [atslib_pthread_mutexref_unlock] %} // end of [%{^] (* ****** ****** *) extern prfun gcd_lemma0 {x,y:int} (): [z:nat] GCD (x, y, z) extern prfun gcd_lemma1 {x,y,z:int} (pf: GCD (x, y, z)): GCD (x - y, y, z) extern prfun gcd_lemma2 {x,y,z:int} (pf: GCD (x, y, z)): GCD (x, y - x, z) extern prfun gcd_lemma3 {x:nat;z:int} (pf: GCD (x, x, z)): [x == z] void // viewdef gcd_v (a:addr, b:addr, z:int) = [x,y:pos] @(int x @ a, int y @ b, GCD (x, y, z)) // viewtypedef upticket0 = upticket (void) fun gcd_flag {a,b:addr} {z:int} (pf: !gcd_v (a, b, z) | flag: int, a: ptr a, b: ptr b): bool = let prval @(pfa, pfb, pfgcd) = pf val x = !a and y = !b in if x > y then begin if flag > 0 then let val () = (!a := x - y) prval () = (pf := @(pfa, pfb, gcd_lemma1 pfgcd)) in gcd_flag (pf | flag, a, b) end else begin pf := @(pfa, pfb, pfgcd); false // not done end end else if x < y then begin if flag < 0 then let val () = (!b := y - x) prval () = (pf := @(pfa, pfb, gcd_lemma2 pfgcd)) in gcd_flag (pf | flag, a, b) end else begin pf := @(pfa, pfb, pfgcd); false // not done end end else begin pf := @(pfa, pfb, pfgcd); true // is done! end end // end of [gcd_flag] fun gcd_mt {x0,y0:pos} {z:int} (pfgcd: GCD (x0, y0, z) | x0: int x0, y0: int y0): int z = let var x = x0 and y = y0 viewtypedef VT = @(gcd_v (x, y, z) | int) val ini = @((view@ x, view@ y, pfgcd) | 0) val mut = pthread_mutexref_create (ini) fun gcd_worker (ticket: upticket0, flag: int): void = let val (pf_ticket, pf_at | ptr) = pthread_mutexref_lock (mut) val done = gcd_flag (ptr->0 | flag, &x, &y) val () = pthread_mutexref_unlock (pf_ticket, pf_at | ptr) in if done then begin pthread_upticket_upload_and_destroy (() | ticket) end else begin gcd_worker (ticket, flag) end end // end of [gcd_worker] // val uplock1 = pthread_uplock_create () val upticket1 = pthread_upticket_create {void} (uplock1) var tid: pthread_t val () = pthread_create_detached_cloptr (llam () => gcd_worker (upticket1, 1), tid) // val uplock2 = pthread_uplock_create () val upticket2 = pthread_upticket_create {void} (uplock2) var tid: pthread_t val () = pthread_create_detached_cloptr (llam () => gcd_worker (upticket2, ~1), tid) // val (_(*void*) | ()) = pthread_uplock_download {void} (uplock1) val () = pthread_uplock_destroy (uplock1) val (_(*void*) | ()) = pthread_uplock_download {void} (uplock2) val () = pthread_uplock_destroy (uplock2) // val (pf_ticket, pf_at | ptr) = pthread_mutexref_lock (mut) prval @(pfa, pfb, pfgcd) = ptr->0 prval () = view@ x := pfa prval () = view@ y := pfb val z1 = x and z2 = y prval () = begin // this is a serious problem with persistent locks! discard (pf_ticket); discard (pf_at) end where { extern prval discard {v:view} (pf: v): void } // end of [where] val () = assert (z1 = z2) prval () = gcd_lemma3 (pfgcd) in z1 end // end of [gcd_mt] fun gcd_main {x,y: pos} (x: int x, y: int y): [z:nat] @(GCD (x, y, z) | int z) = let prval pf = gcd_lemma0 {x, y} () in @(pf | gcd_mt (pf | x, y)) end // end of [gcd_main] // // This example shows clearly the superiority of multicore over // singlecore in case of busy waiting. fn usage (cmd: string): void = prerrf ("Usage: %s [positive integer] [positive integer]\n", @(cmd)) implement main (argc, argv) = let val () = if argc < 3 then (usage (argv.[0]); exit (1)) val () = assert (argc >= 3) val x = int1_of (argv.[1]) val () = assert_errmsg_bool1 (x > 0, "The 1st integer argument is not positive.\n") val y = int1_of (argv.[2]) val () = assert_errmsg_bool1 (y > 0, "The 2nd integer argument is not positive.\n") val @(pf | z) = gcd_main (x, y) in printf ( "The greatest common divisor of (%i, %i) is %i.\n", @(x, y, z) ) // end of [printf] end // end of [main] (* ****** ****** *) (* end of [gcd_mt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/sieve.dats0000664000175000017500000000175012223166161020362 0ustar hwxihwxi(* // // Implementing Erathosthene's sieve // // author: Hongwei Xi (November, 2006) // *) (* ****** ****** *) // // lazy list: // datatype llist = lcons of (intGte 2, () - llist) // #define :: lcons // (* ****** ****** *) fun filter (p: intGte 2 - bool, xs: llist): llist = let val+ x :: fxs = xs in if p (x) then x :: (lam () = filter (p, fxs ())) else filter (p, fxs ()) end // end of [filter] // fun sieve (xs: llist): llist = let val+ x :: fxs = xs in x :: (lam () => sieve (filter (lam (x': intGte 2) => x' nmod x <> 0, fxs ()))) end // end of [sieve] // val primes: llist = let fun aux (i: intGte 2): llist = i :: (lam () => aux (i + 1)) in sieve (aux 2) end // end of [primes] // fun print_ints (xs: llist): void = let val+ x :: fxs = xs in print x; print_newline (); print_ints (fxs ()) end // end of [print_ints] (* ****** ****** *) // implement main (argc, argv) = print_ints (primes) // (* ****** ****** *) (* end of [sieve.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/hamming_lazy.dats0000664000175000017500000000263212223166161021726 0ustar hwxihwxi(* // solving hamming problem in lazy style // author: Hongwei Xi (September, 2007) *) (* ****** ****** *) staload "prelude/DATS/lazy.dats" (* ****** ****** *) #define nil stream_nil #define cons stream_cons #define :: stream_cons (* ****** ****** *) fn lte (x: Nat, y: Nat): bool = x <= y (* fn scale (S: stream Nat, n: Nat): stream Nat = stream_map_cloref (S, lam x => n nmul x) // end of [scale] *) macdef scale (S, n) = stream_map_fun (,(S), lam x => ,(n) nmul x) // end of [scale] val rec S: stream Nat = $delay ( 1 :: stream_ordmerge_fun (stream_ordmerge_fun (scale (S, 2), scale (S, 3), lte), scale (S, 5), lte) ) // end of [$delay] fun remove_dup (S0: stream Nat): stream_con Nat = let fun rmv (n: Nat, S0: stream Nat): stream_con Nat = begin case+ !S0 of | x :: S => if (n < x) then n :: $delay (rmv (x, S)) else rmv (n, S) | nil () => nil () end // end of [rmv] in case+ !S0 of n :: S => rmv (n, S) | nil () => nil () end // end of [remove_dup] val S = $delay (remove_dup S) implement main ( argc, argv ) = let // fun loop{n:nat} ( S: stream Nat, n: int n ) : void = let in if n > 0 then ( case+ !S of | x :: S => (print (x: Nat); print_newline (); loop (S, n-1)) | nil () => () ) // end of [if] end // end of [loop] // in loop (S, 100) end // end of [main] (* ****** ****** *) (* end of [hamming_lazy.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/AutoDiff.dats0000664000175000017500000003105712223166161020753 0ustar hwxihwxi(* ** ** Automatic Differentiation ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2008 ** *) staload "libc/SATS/math.sats" staload LIST = "prelude/DATS/list.dats" staload REF = "prelude/DATS/reference.dats" datatype dualnum = | Base of double | Bundle of (int, dualnum, dualnum) typedef dualnumlst (n:int) = list (dualnum, n) typedef dualnumlst1 = dualnumlst 1 typedef dualnumlst2 = dualnumlst 2 typedef dualnumLst = [n:nat] dualnumlst (n) (* ****** ****** *) val zero_dualnum: dualnum = Base 0.0 val one_dualnum: dualnum = Base 1.0 val negone_dualnum: dualnum = Base (~1.0) val two_dualnum: dualnum = Base 2.0 fn epsilon (p: dualnum): int = begin case+ p of Base _ => 0 | Bundle (e, _, _) => e end // end of [epsilon] fn primal (e: int, p: dualnum): dualnum = case+ p of | Base _ => p | Bundle (e1, x, _) => if e1 < e then p else x // end of [primal] fn perturbation (e: int, p: dualnum): dualnum = begin case+ p of | Base _ => zero_dualnum | Bundle (e1, _, x') => if e1 < e then zero_dualnum else x' end // end of [perturbation] val EPSILON = ref_make_elt (0) fn derivative (f: dualnum - dualnum, x: dualnum) : dualnum = let val e = !EPSILON + 1 val () = !EPSILON := e val result = perturbation (e, f (Bundle (e, x, one_dualnum))) val () = !EPSILON := e - 1 in result end // end of [derivative] fun print_dualnum (p: dualnum): void = begin case+ p of | Bundle (_, x, _) => print_dualnum x | Base x => printf ("%.18g", @(x)) end // end of [print_dualnum] fn print_dualnumlst (ps: dualnumLst): void = let fun aux (i: int, ps: dualnumLst): void = case+ ps of | list_cons (p, ps) => begin if i > 0 then print ", "; print_dualnum p; aux (i+1, ps) end | _ => () in aux (0, ps) end // end of [print_dualnumlst] (* ****** ****** *) extern fun neg_dualnum (p: dualnum): dualnum overload ~ with neg_dualnum extern fun recip_dualnum (p: dualnum): dualnum extern fun add_dualnum_dualnum (p1: dualnum, p2: dualnum): dualnum overload + with add_dualnum_dualnum extern fun sub_dualnum_dualnum (p1: dualnum, p2: dualnum): dualnum overload - with sub_dualnum_dualnum extern fun mul_dualnum_dualnum (p1: dualnum, p2: dualnum): dualnum overload * with mul_dualnum_dualnum extern fun div_dualnum_dualnum (p1: dualnum, p2: dualnum): dualnum overload / with div_dualnum_dualnum // implement neg_dualnum (p) = case+ p of | Bundle (e, x, x') => Bundle (e, ~x, ~x') | Base x => Base (~x) // end of [neg_dualnum] // implement add_dualnum_dualnum (p1, p2) = case+ p1 of | Bundle (e1, x1, x1') => begin case+ p2 of | Bundle (e2, x2, x2') => let val e: int = if e1 <= e2 then e2 else e1 val x = primal (e, p1) + primal (e, p2) val x' = perturbation (e, p1) + perturbation (e, p2) in Bundle (e, x, x') end | Base x2 => Bundle (e1, x1 + p2, x1') end | Base x1 => begin case+ p2 of | Bundle (e2, x2, x2') => Bundle (e2, p1 + x2, x2') | Base x2 => Base (x1 + x2) end // end of [add_dualnum_dualnum] // implement sub_dualnum_dualnum (p1, p2) = case+ p1 of | Bundle (e1, x1, x1') => begin case+ p2 of | Bundle (e2, x2, x2') => let val e: int = if e1 <= e2 then e2 else e1 val x = primal (e, p1) - primal (e, p2) val x' = perturbation (e, p1) - perturbation (e, p2) in Bundle (e, x, x') end | Base x2 => Bundle (e1, x1 - p2, x1') end | Base x1 => begin case+ p2 of | Bundle (e2, x2, x2') => Bundle (e2, p1 - x2, ~x2') | Base x2 => Base (x1 - x2) end // end of [sub_dualnum_dualnum] // implement mul_dualnum_dualnum (p1, p2) = case+ p1 of | Bundle (e1, x1, x1') => begin case+ p2 of | Bundle (e2, x2, x2') => let val e: int = if e1 <= e2 then e2 else e1 val x1 = primal (e, p1) and x2 = primal (e, p2) val x = x1 * x2 val x' = x1 * perturbation (e, p2) + x2 * perturbation (e, p1) in Bundle (e, x, x') end | Base x2 => Bundle (e1, x1 * p2, p2 * x1') end | Base x1 => begin case+ p2 of | Bundle (e2, x2, x2') => Bundle (e2, p1 * x2, p1 * x2') | Base x2 => Base (x1 * x2) end // end of [mul_dualnum_dualnum] // implement recip_dualnum (p) = case+ p of | Bundle (e, x, x') => Bundle (e, recip_dualnum x, (~x') / (x * x)) | Base x => Base (1.0 / x) // end of [recip_dualnum_dualnum] implement div_dualnum_dualnum (p1, p2) = p1 * (recip_dualnum p2) // extern fun sqrt_dualnum (p: dualnum): dualnum implement sqrt_dualnum (p) = begin case+ p of | Bundle (e, x, x') => let val x_sqrt = sqrt_dualnum x; val x'_sqrt = x' / (x_sqrt + x_sqrt) in Bundle (e, x_sqrt, x'_sqrt) end | Base x => Base (sqrt x) end // end of [sqrt_dualnum] // extern fun lt_dualnum_dualnum (p1: dualnum, p2: dualnum): bool overload < with lt_dualnum_dualnum implement lt_dualnum_dualnum (p1, p2) = begin case+ p1 of | Bundle (_, x1, _) => begin case+ p2 of | Bundle (_, x2, _) => x1 < x2 | Base x2 => x1 < p2 end | Base x1 => begin case+ p2 of | Bundle (_, x2, _) => p1 < x2 | Base x2 => x1 < x2 end end // end of [lt_dualnum_dualnum] extern fun lte_dualnum_dualnum (p1: dualnum, p2: dualnum): bool overload <= with lte_dualnum_dualnum implement lte_dualnum_dualnum (p1, p2) = begin case+ p1 of | Bundle (_, x1, _) => begin case+ p2 of | Bundle (_, x2, _) => x1 <= x2 | Base x2 => x1 <= p2 end | Base x1 => begin case+ p2 of | Bundle (_, x2, _) => p1 <= x2 | Base x2 => x1 <= x2 end end // end of [lte_dualnum_dualnum] (* ****** ****** *) fn square (p: dualnum): dualnum = p * p fn list_tabulate {n:nat} (f: !natLt n - dualnum, n: int n): dualnumlst n = let fun aux {i:int | ~1 <= i; i < n} (f: !natLt n - dualnum, i: int i, res: list (dualnum, n-i-1)) : list (dualnum, n) = if i >= 0 then aux (f, i-1, list_cons (f i, res)) else res in aux (f, n-1, list_nil ()) end // end of [list_tabulate] fun vplus {n:nat} .. (us: dualnumlst n, vs: dualnumlst n): dualnumlst n = case+ us of | list_cons (u, us) => let val+ list_cons (v, vs) = vs in list_cons (u + v, vplus (us, vs)) end | _ =>> list_nil () // end of [vplus] fun vminus {n:nat} .. (us: dualnumlst n, vs: dualnumlst n): dualnumlst n = case+ us of | list_cons (u, us) => let val+ list_cons (v, vs) = vs in list_cons (u - v, vminus (us, vs)) end | _ =>> list_nil () // end of [vminus] fun vscale {n:nat} (k: dualnum, xs: dualnumlst n): dualnumlst n = case+ xs of | list_cons (x, xs) => list_cons (k * x, vscale (k, xs)) | list_nil () => list_nil () // end of [vscale] fn magnitude_squared (xs: dualnumLst): dualnum = let fun aux {n:nat} .. (xs: dualnumlst n, res: dualnum): dualnum = case+ xs of list_cons (x, xs) => aux (xs, res + x * x) | _ => res in aux (xs, zero_dualnum) end // end of [magnitude_squared] fn magnitude (xs: dualnumLst): dualnum = sqrt_dualnum (magnitude_squared xs) fn distance {n:nat} (us: dualnumlst n, vs: dualnumlst n): dualnum = magnitude (vminus (us, vs)) fun list_nth_get {n:nat} .. (xs: dualnumlst n, i: natLt n): dualnum = if i > 0 then begin let val+ list_cons (_, xs) = xs in list_nth_get (xs, i-1) end end else begin let val+ list_cons (x, _) = xs in x end end // end of [list_nth_get] fun list_nth_set {n:nat} .. (xs: dualnumlst n, i: natLt n, x0: dualnum): dualnumlst n = if i > 0 then let val+ list_cons (x, xs) = xs in list_cons (x, list_nth_set (xs, i-1, x0)) end else begin let val+ list_cons (_, xs) = xs in list_cons (x0, xs) end end // end of [list_nth_set] fn gradient {n:nat} (f: dualnumlst n - dualnum, xs: dualnumlst n) : dualnumlst n = let val fi = lam (i: natLt n): dualnum = derivative (lam xi => f (list_nth_set (xs, i, xi)), list_nth_get (xs, i)) val gxs = list_tabulate (fi, list_length xs) val () = cloptr_free (fi) (* val () = begin print "gradient: xs = "; print_dualnumlst xs; print_newline (); print "gradient: gxs = "; print_dualnumlst gxs; print_newline (); end *) in gxs end // end of [gradient] val PRECISION = Base 1e-5 fn multivariate_argmin {n:nat} (f: dualnumlst n - dualnum, xs: dualnumlst n) : dualnumlst n = let macdef g (xs) = gradient (f, ,(xs)) fun loop ( f: dualnumlst n - dualnum , xs: dualnumlst n, fxs: dualnum, gxs: dualnumlst n, eta: dualnum, i: int ) : dualnumlst n = let macdef g (xs) = gradient (f, ,(xs)) in if magnitude gxs <= PRECISION then xs else if i = 10 then loop (f, xs, fxs, gxs, two_dualnum * eta, 0) else let val xs' = vminus (xs, vscale (eta, gxs)) in if distance (xs, xs') <= PRECISION then xs else let val fxs' = f xs' in if fxs' < fxs then loop (f, xs', fxs', g xs', eta, i+1) else loop (f, xs, fxs, gxs, eta / two_dualnum, 0) // end of [if] end // end of [if] end // end of [if] end // end of [loop in loop (f, xs, f xs, g xs, PRECISION, 0) end // end of [multivariate_argmin] fn multivariate_argmax {n:nat} (f: dualnumlst n - dualnum, xs: dualnumlst n): dualnumlst n = multivariate_argmin (lam xs => ~(f xs), xs) // end of [multivariate_argmax] fn multivariate_max {n:nat} (f: dualnumlst n - dualnum, xs: dualnumlst n): dualnum = f (multivariate_argmax (f, xs)) // end of [multivariate_max] (* ****** ****** *) fn saddle (): void = let val start: dualnumlst2 = list_cons (one_dualnum, list_cons (one_dualnum, list_nil ())) val xy1_star: dualnumlst2 = let fn f1 (xy1: dualnumlst2): dualnum = let val+ list_cons (x1, list_cons (y1, list_nil ())) = xy1 val sum = x1 * x1 + y1 * y1 fn f2 (xy2: dualnumlst2): dualnum = let val+ list_cons (x2, list_cons (y2, list_nil ())) = xy2 in sum - (x2 * x2 + y2 * y2) end // end of [f2] in multivariate_max (f2, start) end // end of [f1] in multivariate_argmin (f1, start) end // end of [xy1_star] val+ list_cons (x1_star, list_cons (y1_star, list_nil ())) = xy1_star val xy2_star: dualnumlst2 = let val sum = x1_star * x1_star + y1_star * y1_star fn f3 (xy2: dualnumlst2): dualnum = let val+ list_cons (x2, list_cons (y2, list_nil ())) = xy2 in sum - (x2 * x2 + y2 * y2) end // end of [f3] in multivariate_argmax (f3, start) end // end of [xy2_star] val+ list_cons (x2_star, list_cons (y2_star, list_nil ())) = xy2_star in // in of [let] print_dualnum x1_star; print_newline (); print_dualnum y1_star; print_newline (); print_dualnum x2_star; print_newline (); print_dualnum y2_star; print_newline (); end // end of [saddle] (* ****** ****** *) fn particle () = let fn naive_euler (w: dualnum): dualnum = let val ten_dualnum = Base 10.0 val delta_t = Base 1e-1 val charge1 = '[ten_dualnum, ten_dualnum - w] val charge2 = '[ten_dualnum, zero_dualnum] val charges: list (dualnumlst2, 2) = '[charge1, charge2] fn p (xs: dualnumlst2): dualnum = let fun aux (charges: List dualnumlst2, res: dualnum): dualnum = case+ charges of | list_cons (charge, charges) => aux (charges, res + recip_dualnum (distance (xs, charge))) | list_nil () => res in aux (charges, zero_dualnum) end fun loop (xs: dualnumlst2, xs_dot: dualnumlst2): dualnum = let val xs_ddot = vscale (negone_dualnum, gradient (p, xs)) val xs_new = vplus (xs, vscale (delta_t, xs_dot)) in if zero_dualnum < list_nth_get (xs_new, 1) then loop (xs_new, vplus (xs_dot, vscale (delta_t, xs_ddot))) else let val delta_t_f = ~(list_nth_get (xs, 1) / list_nth_get (xs_dot, 1)) val xs_t_f = vplus (xs, vscale (delta_t_f, xs_dot)) in square (list_nth_get (xs_t_f, 0)) end // end of [if] end // end of [if] val xs_initial: dualnumlst2 = '[zero_dualnum, Base 8.0] val xs_dot_initial: dualnumlst2 = '[Base 0.75, zero_dualnum] in loop (xs_initial, xs_dot_initial) end // end [naive_euler] val w0 = zero_dualnum val ws_star: dualnumlst1 = multivariate_argmin (f, '[w0]) where { fn f (ws: dualnumlst1): dualnum = let val+ list_cons (w, list_nil ()) = ws in naive_euler w end // end of [f] } // end of [where] val list_cons (w_star, list_nil ()) = ws_star in // in of [let] print_dualnum w_star; print_newline () end // end of [particle] (* ****** ****** *) (* // saddle: 8.2463248261403561e-06 8.2463248261403561e-06 8.2463248261403561e-06 8.2463248261403561e-06 // particle: 0.20719187464861194 *) implement main (argc, argv) = begin saddle (); // test particle (); // test end // end of [main] (* ****** ****** *) (* end of [AutoDiff.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/quicksort1_list.dats0000664000175000017500000002076012223166161022411 0ustar hwxihwxi(* // // A verified implementation of quicksort on lists // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Saturday, September 27, 2008 // // // How to compile: // atscc -o quicksort1_list quicksort1_list.dats // How to test: // ./quicksort1_list // *) (* This is a milestone example in the development of ATS. A list quicksort implementation given below is proven to be terminating and its return is guaranteed to be a sorted permutation of its input list. An implementation of list quicksort in DML was given in 1998 that can guarantee based on its type that it always returns a list of the same length as its input. Since then, a question that has been asked frequently by many people is whether it can be done in DML to give an implementation of list quicksort that can guarantee based on its type that it always returns a list that is a sorted permutation of its input. This is finally done now in ATS, which succeeds DML as well as extends it. *) (* ****** ****** *) staload "libats/SATS/ilistp.sats" stadef nil = ilist_nil stadef cons = ilist_cons (* ****** ****** *) sortdef nats = nat dataprop MSET (ilist, int(*nats*)) = | {x:nat} {xs:ilist} {n:nats} MSETcons (cons (x, xs), x + n) of MSET (xs, n) | MSETnil (nil, 0) // end of [MSET] extern praxi MSET_istot {xs:ilist} (): [n:nats] MSET (xs, n) (* ****** ****** *) dataprop LB (int, ilist) = | {l:nat} {x:nat | l <= x} {xs: ilist} LBcons (l, cons (x, xs)) of LB (l, xs) | {l:nat} LBnil (l, nil) // end of [LB] dataprop UB (ilist, int) = | {u:nat} {x:nat | x <= u} {xs: ilist} UBcons (cons (x, xs), u) of UB (xs, u) | {u:nat} UBnil (nil, u) // end of [UB] (* ****** ****** *) extern praxi LB_MSET_lemma {x:nat} {xs1,xs2:ilist} {n:nats} (_: MSET (xs1, n), _: MSET (xs2, n), _lb: LB (x, xs1)): LB (x, xs2) extern praxi UB_MSET_lemma {x:nat} {xs1,xs2:ilist} {n:nats} (_: MSET (xs1, n), _: MSET (xs2, n), _ub: UB (xs1, x)): UB (xs2, x) (* ****** ****** *) extern prfun LB_lemma_monotone {l1,l2:nat | l1 <= l2} {xs: ilist} (pf: LB (l2, xs)): LB (l1, xs) implement LB_lemma_monotone {l1,l2} (xs) = let prfun aux {xs:ilist} .. (pf: LB (l2, xs)): LB (l1, xs) = begin case+ pf of LBcons (pf) => LBcons (aux pf) | LBnil () => LBnil () end in aux (xs) end // end of [LB_lemma_monotone] (* ****** ****** *) extern prfun UB_lemma_monotone {u1,u2:nat | u1 >= u2} {xs: ilist} (pf: UB (xs, u2)): UB (xs, u1) implement UB_lemma_monotone {u1,u2} (xs) = let prfun aux {xs:ilist} .. (pf: UB (xs, u2)): UB (xs, u1) = begin case+ pf of UBcons (pf) => UBcons (aux pf) | UBnil () => UBnil () end in aux (xs) end // end of [UB_lemma_monotone] (* ****** ****** *) dataprop ISORD1 (ilist) = | ISORD1nil (nil) | {x:nat} {xs:ilist} ISORD1cons (cons (x, xs)) of (LB (x, xs), ISORD1 xs) // end of [ISORD1] (* ****** ****** *) extern prfun APPEND_MSET_lemma {xs,ys,zs:ilist} {n1,n2:nats} (pf1: MSET (xs, n1), pf2: MSET (ys, n2), pf3: APPEND (xs, ys, zs)) : MSET (zs, n1 + n2) implement APPEND_MSET_lemma (pf1, pf2, pf3) = let prfun aux {xs,ys,zs:ilist} {n1,n2:nats} .. (pf1: MSET (xs, n1), pf2: MSET (ys, n2), pf3: APPEND (xs, ys, zs)) : MSET (zs, n1 + n2) = begin case+ pf3 of | APPENDcons (pf3) => let val+ MSETcons (pf1) = pf1 in MSETcons (aux (pf1, pf2, pf3)) end | APPENDnil () => let val+ MSETnil () = pf1 in pf2 end end // end of [aux] in aux (pf1, pf2, pf3) end // end of [APPEND_MSET_lemma] (* ****** ****** *) extern prfun APPEND_ISORD1_lemma {xs1,xs2,xs:ilist} {x:nat} ( pf1: ISORD1 xs1 , pf2: ISORD1 xs2 , pf3: UB (xs1, x) , pf4: LB (x, xs2) , pf5: APPEND (xs1, xs2, xs) ) : ISORD1 (xs) implement APPEND_ISORD1_lemma (pf1, pf2, pf3, pf4, pf5) = let prfun aux {x0:nat} {xs1,xs2,xs:ilist} {x:nat | x0 <= x} .. ( pf1: ISORD1 xs1 , pf2: ISORD1 xs2 , pf3: UB (xs1, x) , pf4: LB (x, xs2) , pf5: APPEND (xs1, xs2, xs) , pf6: LB (x0, xs1) ) : @(ISORD1 xs, LB (x0, xs)) = case+ pf5 of | APPENDcons {x1} (pf5) => let val ISORD1cons (pf1_lb1, pf1) = pf1 val UBcons pf3 = pf3 val (pf_ord, pf_lb1) = aux {x1} (pf1, pf2, pf3, pf4, pf5, pf1_lb1) val LBcons pf6 = pf6 val pf_lb0 = LB_lemma_monotone {x0,x1} (pf_lb1) in (ISORD1cons (pf_lb1, pf_ord), LBcons pf_lb0) end | APPENDnil () => (pf2, LB_lemma_monotone {x0, x} pf4) in case+ pf5 of | APPENDcons {x1} _ => let val UBcons _ = pf3 val ISORD1cons (pf_lb, _) = pf1 val pf_lb = LBcons {x1} {x1} (pf_lb) val (pf_ord, pf_lb) = aux {x1} (pf1, pf2, pf3, pf4, pf5, pf_lb) in pf_ord end | APPENDnil () => pf2 end // end of [APPEND_ISORD1_lemma] (* ****** ****** *) abst@ype T (int) = double extern fun lte_elt_elt {x,y:nat} (x: T x, y: T y):<> bool (x <= y) overload <= with lte_elt_elt datatype list (ilist) = | {x:pos} {xs:ilist} cons (cons (x, xs)) of (T (x), list (xs)) | nil (nil) // end of [list] typedef list = [xs:ilist] list (xs) (* ****** ****** *) extern fun append {xs,ys:ilist} (xs: list (xs), ys: list (ys)):<> [zs:ilist] (APPEND (xs, ys, zs) | list zs) implement append (xs, ys) = let fun aux {xs,ys:ilist} .. (xs: list xs, ys: list ys) :<> [zs:ilist] (APPEND (xs, ys, zs) | list zs) = begin case+ xs of | cons (x, xs) => let val (pf | zs) = aux (xs, ys) in (APPENDcons pf | cons (x, zs)) end | nil () => (APPENDnil () | ys) end // end of [aux] in aux (xs, ys) end // end of [append] (* ****** ****** *) fun qsrt {xs:ilist} {n:nats} .. (pf: MSET (xs, n) | xs: list xs) :<> [xs: ilist] (MSET (xs, n), ISORD1 (xs) | list xs) = begin case+ xs of | cons (x, xs) => let prval MSETcons pf = pf in part ( pf, MSETnil (), MSETnil (), UBnil (), LBnil () | x, xs, nil (), nil () ) end | nil () => let prval MSETnil () = pf in (MSETnil (), ISORD1nil () | nil ()) end end // end of [qsrt] and part {x:pos} {xs0,xs1,xs2:ilist} {n0,n1,n2:nats} .. ( pf0: MSET (xs0, n0) , pf1: MSET (xs1, n1) , pf2: MSET (xs2, n2) , pf_ub: UB (xs1, x) , pf_lb: LB (x, xs2) | x: T x, xs0: list xs0, xs1: list xs1, xs2: list xs2 ) :<> [xs: ilist] (MSET (xs, x+n0+n1+n2), ISORD1 (xs) | list xs) = begin case+ xs0 of | cons (x0, xs0) => let prval MSETcons (pf0) = pf0 in if x0 <= x then part ( pf0, MSETcons pf1, pf2, UBcons (pf_ub), pf_lb | x, xs0, cons (x0, xs1), xs2 ) else part ( pf0, pf1, MSETcons pf2, pf_ub, LBcons (pf_lb) | x, xs0, xs1, cons (x0, xs2) ) end // end of [cons] | nil () => let prval MSETnil () = pf0 val (pf1_set, pf1_ord | xs1) = qsrt (pf1 | xs1) val (pf2_set, pf2_ord | xs2) = qsrt (pf2 | xs2) prval pf_ub = UB_MSET_lemma (pf1, pf1_set, pf_ub) prval pf_lb = LB_MSET_lemma (pf2, pf2_set, pf_lb) prval pf2_ord1 = ISORD1cons (pf_lb, pf2_ord) val (pf_app | xs) = append (xs1, cons (x, xs2)) prval pf_set = APPEND_MSET_lemma (pf1_set, MSETcons pf2_set, pf_app) prval pf_ord = APPEND_ISORD1_lemma ( pf1_ord, pf2_ord1, pf_ub, LBcons {x} (pf_lb), pf_app ) in (pf_set, pf_ord | xs) end end // end of [part] (* ****** ****** *) extern fun quicksort {xs:ilist} {n:nats} (pf: MSET (xs, n) | xs: list xs) :<> [xs: ilist] (MSET (xs, n), ISORD1 (xs) | list xs) implement quicksort (pf | xs) = qsrt (pf | xs) (* ****** ****** *) local assume T (n:int) = double in implement lte_elt_elt {x,y} (x, y) = let extern castfn __cast (_: bool):<> bool (x <= y) in __cast (lte_double_double (x, y)) end // end of [lte_elt_elt] fn print_list (xs: list): void = let fun aux (xs: list, i: int): void = begin case+ xs of | cons (x, xs) => begin if i > 0 then print ", "; printf ("%.1f", @(x)); aux (xs, i+1) end // end of [cons] | nil () => () end // end of [aux] in aux (xs, 0) end // end of [print_list] castfn T .<>. (f: double):<> [x:pos] T (x) = #[1 | f] end // end of [local] (* ****** ****** *) #define :: cons implement main () = let val xs: list = T 2.0 :: T 1.0 :: T 4.0 :: T 3.0 :: T 6.0 :: T 5.0 :: T 2.0 :: T 1.0 :: T 4.0 :: T 3.0 :: T 6.0 :: T 5.0 :: T 2.0 :: T 1.0 :: T 4.0 :: T 3.0 :: T 6.0 :: T 5.0 :: T 2.0 :: T 1.0 :: T 4.0 :: T 3.0 :: T 6.0 :: T 5.0 :: nil () val (_(*pf_set*), _(*pf_ord*) | ys) = quicksort (MSET_istot () | xs) in print "xs = "; print_list xs; print_newline (); // is there any doubt :) print "ys = "; print_list ys; print_newline (); end // end of [main] (* ****** ****** *) (* end of [quicksort1_list.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/longestline.dats0000664000175000017500000000445112223166161021573 0ustar hwxihwxi(* // print out the longest line in a file; this example demonstrates // an interesting example of linear lazy evaluation *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: January, 2009 // staload "libc/SATS/stdio.sats" (* ****** ****** *) // staload "prelude/SATS/list_vt.sats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" viewtypedef cstream_vt = stream_vt (char) // tail-recursion; no persistent heap allocation fn* longestline_loop1 {n:nat} (cs: cstream_vt, cur: list_vt (char, n), n: int n): List_vt (char) = case+ !cs of | ~stream_vt_cons (c, cs) => begin if (c <> '\n') then begin longestline_loop1 (cs, list_vt_cons (c, cur), n+1) end else begin longestline_loop2 (cs, list_vt_nil (), 0, cur, n) end // end of [if] end // end of [stream_vt_cons] | ~stream_vt_nil () => cur // end of [longestline_loop1] and longestline_loop2 {m,n:nat | n <= m} ( cs: cstream_vt , cur: list_vt (char, n), n: int n , max: list_vt (char, m), m: int m ) : List_vt (char) = begin case+ !cs of | ~stream_vt_cons (c, cs) => begin if (c <> '\n') then let val cur = list_vt_cons (c, cur) in if (n < m) then longestline_loop2 (cs, cur, n + 1, max, m) else let // m = n val () = list_vt_free (max) in longestline_loop1 (cs, cur, n + 1) end // end of [if] end else let // c = '\n' val () = list_vt_free (cur) in longestline_loop2 (cs, list_vt_nil (), 0, max, m) end // end of [if] end // end of [stream_vt_cons] | ~stream_vt_nil () => let val () = list_vt_free (cur) in max end // end of [stream_vt_nil] end // end of [longestline_loop2] implement main () = let val (pf_stdin | p_stdin) = stdin_get () val cs = char_stream_vt_make_file (file_mode_lte_r_r, pf_stdin | p_stdin) val longestline = longestline_loop1 {0} (cs, list_vt_nil (), 0) val longestline = list_vt_reverse (longestline) val () = loop (longestline) where { fun loop {n:nat} .. (cs: list_vt (char, n)): void = case+ cs of | ~list_vt_cons (c, cs) => (print c; loop (cs)) | ~list_vt_nil () => () // end of [loop] } val () = print_newline () in // empty end // end of [main] (* ****** ****** *) (* end of [longestline.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/tetrix.dats0000664000175000017500000004633612223166161020577 0ustar hwxihwxi(* ** ** A poor man's game of tetrix ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September 2007 ** *) (* The code was first written in ATS/Proto in October 2006 and ported to ATS/Geizella in September 2007. The use of linear objects here should serve as an informative example for future reference. *) (* ****** ****** *) staload "libc/SATS/random.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) staload "prelude/DATS/array.dats" staload "prelude/DATS/matrix.dats" staload "prelude/DATS/reference.dats" (* ****** ****** *) extern fun save_set_keyboard (): void = "save_set_keyboard" extern fun restore_keyboard (): void = "restore_keyboard" extern fun kbhit (): bool = "kbhit" extern fun readch (): int = "readch" (* ****** ****** *) #define clear "" // clear the screen #define home "" // moving the the home position (upper left corner ) #define civis "[?25l" // invisible cursor #define cnorm "[?25h" // normal cursor #define blink "" #define bold "" #define normal "" #define cuu "" // moving up #define cud "" // moving down #define cuf "" // moving forward #define cub "" // moving backward #define BSZ 2 #define FD 28 // 14 * BSZ #define FW 20 // 10 * BSZ #define XBASE 3 #define YBASE 1 macdef XSCORE = 2 macdef YSCORE = FW + 4 macdef SPEED_LIM = 100 (* ****** ****** *) macdef matrix_make_elt (m, n, c) = matrix_make_elt (size1_of_int1 ,(m), size1_of_int1 ,(n), ,(c)) val frame: matrix (char, FD+1, FW) = matrix_make_elt (FD+1, FW, ' ') fn frame_get_at (i: Int, j: Int): char = if i < 0 then '\0' else if i > FD then '\0' else if j < 0 then '\0' else if j >= FW then '\0' else frame[i, FW, j] // end of [frame_get_at] fn frame_set_at (i: Int, j: Int, c: char): void = if i < 0 then () else if i > FD then () else if j < 0 then () else if j >= FW then () else frame[i, FW, j] := c // end of [frame_set_at] // macdef ignore (x) = let val _ = ,(x) in () end // exception GameIsOverException fn curs_clear (): void = print_string clear fn curs_home (): void = print_string home fn curs_invisible (): void = print_string civis fn curs_normal (): void = print_string cnorm fun curs_upward (n: Nat): void = if n > 0 then (print_string cuu; curs_upward (n-1)) fun curs_downward (n: Nat): void = if n > 0 then (print_string cud; curs_downward (n-1)) fun curs_forward (n: Nat): void = if n > 0 then (print_string cuf; curs_forward (n-1)) fun curs_backward (n: Nat): void = if n > 0 then (print_string cub; curs_backward (n-1)) fun curs_goto (m:Int, n:Int): void = let val m = m + XBASE and n = n + YBASE in curs_home (); if m >= 0 then curs_downward m else curs_upward (~m); if n >= 0 then curs_forward n else curs_backward (~n); end fun print_vertical_line_up (n: Nat): void = if n > 0 then begin print '|'; print_string cub; print_string cuu; print_vertical_line_up (n - 1) end fun print_vertical_line_dn (n: Nat): void = if n > 0 then begin print '|'; print_string cub; print_string cud; print_vertical_line_dn (n - 1) end fun print_horizontal_line (n: Nat): void = if n > 0 then begin print '_'; print_horizontal_line (n - 1) end fn print_frame (): void = begin print_vertical_line_dn (FD isub 1); print '|'; print_horizontal_line FW; print_vertical_line_up FD; end fn print_block (c: char, b: bool): void = if c <> ' ' then (if b then print c else print ' ') else curs_forward 1 // typedef rotate_t = natLt 4 typedef shape (m:int, n:int) = '{ row= int m , col= int n , mat= matrix (char, m, n) } typedef shape = [m,n:pos] shape (m, n) // fn move_test {m,n:pos} (S: shape (m, n), r: rotate_t, xcen: Int, ycen: Int): bool = let val m = S.row and n = S.col and M = S.mat val m2 = nhalf m and n2 = nhalf n fun aux (i: natLte m, j: natLte n): bool = if i < m then if j < n then let val (x, y): (Int, Int) = case+ r of | 0 => (xcen - m2 + i, ycen - n2 + j) | 1 => (xcen - n2 + j, ycen + m2 - i - 1) | 2 => (xcen + m2 - i - 1, ycen + n2 - j - 1) | 3 => (xcen + n2 - j - 1, ycen - m2 + i) val c = frame_get_at (x, y) in if c = '\0' then false else begin if c <> ' ' then begin if M[i,n,j] = ' ' then aux (i, j+1) else false end else begin aux (i, j+1) end // end of [if] end end else begin aux (i+1, 0) end // end of [if] else true // end of [aux] in aux (0, 0) end // end of [move_test] // fn absorb {m,n:pos} (S: shape (m, n), r: rotate_t, xcen: Int, ycen: Int): void = let val m = S.row and n = S.col and M = S.mat val m2 = nhalf m and n2 = nhalf n fun aux (i: natLte m, j: natLte n): void = if i < m then begin if j < n then let val (x, y): (Int, Int) = case+ r of | 0 => (xcen - m2 + i, ycen - n2 + j) | 1 => (xcen - n2 + j, ycen + m2 - i - 1) | 2 => (xcen + m2 - i - 1, ycen + n2 - j - 1) | 3 => (xcen + n2 - j - 1, ycen - m2 + i) val c = M[i, n, j] val () = if c <> ' ' then frame_set_at (x, y, c) in aux (i, j+1) end else begin aux (i+1, 0) end // end of [if] end // end of [if] // end of [aux] in aux (0, 0) end // end of [absorb] // fn iter {n:nat} (n: int n, f: !natLt n - void): void = let fun loop {i:nat | i <= n} (i: int i, f: !natLt n - void) : void = if i < n then (f i; loop (i+1, f)) else () in loop (0, f) end // end of [iter] fn frame_line_flash (i: natLte FD): void = let fun aux (n: Nat): void = if n > 0 then let val f = lam (j: natLt FW): void = print frame[i, FW, j] val () = iter (FW, f) val () = cloptr_free (f) in fflush_stdout (); curs_backward (FW); ignore (usleep (62500)); iter (FW, lam j => print ' '); fflush_stdout (); curs_backward (FW); ignore (usleep (62500)); aux (n-1) end // end of [if] in print_string bold; curs_goto (i, 0); aux (3); print_string normal end // end of [frame_line_flash] fn frame_display (): void = let fun aux1 (j: natLte FW): void = if j < FW then let val c = frame[FD, FW, j] in if c = ' ' then print '_' else print c; aux1 (j + 1) end else begin curs_backward FW; curs_upward 1 end // end of [if] fun aux2 (i: intLte FD, j: natLte FW): void = if i >= 0 then if j < FW then begin print frame[i, FW, j]; aux2 (i, j + 1) end else begin curs_backward FW; curs_upward 1; aux2 (i - 1, 0) end // end of [if] else () in curs_goto (FD, 0); aux1 (0); aux2 (FD - 1, 0) end // end of [frame_display] fn frame_find (): intBtw (~1, FD+1) = let // find a filled-up line fn* aux1 {i:nat} (i: int i): intBtw (~1, FD+1) = if i <= FD then aux2 (i, 0) else (~1) and aux2 {i,j:nat | i <= FD; j <= FW} (i: int i, j: int j): intBtw (~1, FD+1) = if j < FW then begin if frame[i, FW, j] <> ' ' then aux2 (i, j+1) else aux1 (i+1) end else begin i end // end of [if] in aux1 (0) end // end of [frame_find] (* ****** ****** *) fn print_usage (): void = begin curs_goto (XSCORE + 2, YSCORE); print_string ("j: left move"); curs_goto (XSCORE + 3, YSCORE); print_string ("l: right move"); curs_goto (XSCORE + 4, YSCORE); print_string ("i: left rotation"); curs_goto (XSCORE + 5, YSCORE); print_string ("k: right rotation"); curs_goto (XSCORE + 6, YSCORE); print_string ("space: fall straight"); curs_goto (XSCORE + 8, YSCORE); print_string "Please press the RETURN key to start the game."; end // end of [print_usage] // val total_number_of_filled_lines: ref Nat = ref_make_elt 0 fn total_number_of_filled_lines_inc (): void = begin !total_number_of_filled_lines := !total_number_of_filled_lines + 1 end // end of [total_number_of_filled_lines] // fn print_score (): void = begin curs_goto (XSCORE, YSCORE + 7); print (!total_number_of_filled_lines); fflush_stdout () end // end of [print_score] // fun frame_delete (): void = let fn aux1 (i: natLte FD, j: natLte FD): void = let val f = lam (k: natLt FW): void = matrix_set_elt_at__intsz (frame, i, FW, k, frame[j, FW, k]) val () = iter (FW, f) val () = cloptr_free (f) in // empty end // end of [aux1] fn aux2 (i: natLte FD): void = let val f = lam (k: natLt FW): void = frame[i, FW, k] := ' ' val () = iter (FW, f) val () = cloptr_free (f) in // empty end // end of [aux2] fun aux3 (i: intLte FD): void = if i >= 0 then let val j = i-1 in if j < 0 then aux2 i else aux1 (i, j); aux3 (i - 1) end // end of [if] val i = frame_find () in if i >= 0 then begin total_number_of_filled_lines_inc (); frame_line_flash (i); print_score (); aux3 i; frame_display (); frame_delete () end end // end of [frame_delete] // fn display_shape_0 {m,n:pos} (S: shape (m, n), b: bool): void = let val m = S.row and n = S.col and M = S.mat fun aux (i: natLte m, j: natLte n): void = if i < m then if j < n then begin print_block (M[i, n, j], b); aux (i, j + 1) end else begin curs_backward n; curs_downward 1; aux (i+1, 0) end // end of [if] else begin fflush_stdout () end in aux (0, 0) end // end of [display_shape_0] // fn display_shape_1 {m,n:pos} (S: shape (m, n), b: bool): void = let val m = S.row and n = S.col and M = S.mat fun aux (i: intLt m, j: natLte n): void = if j < n then if i >= 0 then begin print_block (M[i, n, j], b); aux (i-1, j) end else begin curs_backward m; curs_downward 1; aux (m-1, j+1) end // end of [if] else begin fflush_stdout () end // end of [if] in aux (m-1, 0) end // end of [display_shape_1] fn display_shape_2 {m,n:pos} (S: shape (m, n), b: bool): void = let val m = S.row and n = S.col and M = S.mat fun aux (i: intLt m, j: intLt n): void = if i >= 0 then if j >= 0 then begin print_block (M[i, n, j], b); aux (i, j - 1) end else begin curs_backward n; curs_downward 1; aux (i-1, n-1) end else begin fflush_stdout () end // end of [if] in aux (m-1, n-1) end // end of [display_shape_2] fn display_shape_3 {m,n:pos} (S: shape (m, n), b: bool): void = let val m = S.row and n = S.col and M = S.mat fun aux (i: natLte m, j: intLt n): void = if j >= 0 then if i < m then begin print_block (M[i, n, j], b); aux (i + 1, j) end else begin curs_backward m; curs_downward 1; aux (0, j-1) end // end of [if] else begin fflush_stdout () end // end of [if] in aux (0, n-1) end // end of [display_shape_3] fn display_shape_at {m,n:pos} (S: shape (m, n), b: bool, r: rotate_t, xcen: Int, ycen: Int): void = let val m = S.row and n = S.col val m2 = nhalf m and n2 = nhalf n in case+ r of | 0 => begin curs_goto (xcen - m2, ycen - n2); display_shape_0 (S, b) end | 1 => begin curs_goto (xcen - n2, ycen + m2 - m); display_shape_1 (S, b) end | 2 => begin curs_goto (xcen + m2 - m, ycen + n2 - n); display_shape_2 (S, b) end | 3 => begin curs_goto (xcen + n2 - n, ycen - m2); display_shape_3 (S, b) end end // end of [display_shape_at] // viewtypedef shapeObj (m:int, n:int) = @{ rot= rotate_t , xlen= int m , ylen= int n , xpos= Int , ypos= Int , speed_lim= Nat , speed_acc= Nat , shape= shape (m, n) } viewtypedef shapeObj = [m,n:pos] shapeObj (m, n) viewtypedef shapeObj0 = shapeObj(0, 0) // fn shapeObj_display {m,n:pos} (S: &shapeObj (m, n)): void = display_shape_at (S.shape, true, S.rot, S.xpos, S.ypos) fn shapeObj_undisplay {m,n:pos} (S: &shapeObj (m, n)): void = display_shape_at (S.shape, false, S.rot, S.xpos, S.ypos) // succeed if 0 is returned fn shapeObj_downward {m,n:pos} (S: &shapeObj (m, n)): int = if move_test (S.shape, S.rot, S.xpos + 1, S.ypos) then (shapeObj_undisplay S; S.xpos := S.xpos + 1; shapeObj_display S; 0) else 1 #define i2c char_of_int fn shapeObj_falling {m,n:pos} (S: &shapeObj (m, n)): void = let var error: int = (0: int) in if ~(move_test (S.shape, 0, S.xpos, S.ypos)) then begin $raise GameIsOverException () end ; // end of [if] while (error < 1) ( ignore (usleep 1000); if kbhit () then let val c = readch () in case+ i2c c of | ' ' => S.speed_lim := 0 | 'l' => begin if move_test (S.shape, S.rot, S.xpos, S.ypos+1) then (shapeObj_undisplay S; S.ypos := S.ypos+1; shapeObj_display S) end | 'j' => begin if move_test (S.shape, S.rot, S.xpos, S.ypos-1) then (shapeObj_undisplay S; S.ypos := S.ypos-1; shapeObj_display S) end | 'i' => let val r = (S.rot + 3) nmod 4 in if move_test (S.shape, r, S.xpos, S.ypos) then (shapeObj_undisplay S; S.rot := r; shapeObj_display S) end | 'k' => let val r = (S.rot + 1) nmod 4 in if move_test (S.shape, r, S.xpos, S.ypos) then (shapeObj_undisplay S; S.rot := r; shapeObj_display S) end | _ => () end ; // end of [if] if S.speed_acc >= S.speed_lim then begin S.speed_acc := 0; error := shapeObj_downward S end else begin S.speed_acc := S.speed_acc + 1 end ) ; // end of [while] absorb (S.shape, S.rot, S.xpos, S.ypos); frame_delete (); end // end of [shapeObj_falling] (* ****** ****** *) fn shape_make {m,n:pos} (M: matrix (char, m, n), m: int m, n: int n): shape (m, n) = '{ row= m, col= n, mat= M } fn shapeObj_make {m,n:pos} (S: shape (m, n)) : [l:addr] (free_gc_v (shapeObj0?, l), shapeObj (m, n) @ l | ptr l) = let val (pf_gc, pf | p) = ptr_alloc_tsz {shapeObj0} (sizeof) in p->rot := 0; p->xlen := S.row; p->ylen := S.col; p->xpos := nhalf (p->xlen); p->ypos := nhalf (FW); p->speed_lim := SPEED_LIM; p->speed_acc := SPEED_LIM; p->shape := S; (pf_gc, pf | p) end // end of [shape_make] (* ****** ****** *) fn set_block_at {m,n:pos} (S: shape (m*BSZ, n*BSZ), i: natLt m, j: natLt n, c: Char) : void = let val nBSZ = S.col and M = S.mat fun aux (p: natLte BSZ, q: natLte BSZ): void = if p < BSZ then begin if q < BSZ then let val () = M[i imul BSZ + p, nBSZ, j imul BSZ + q] := c in aux (p, q+1) end else begin aux (p+1, 0) end // end of [if] end // end of [if] in aux (0, 0) end // end of [set_block_at] (* ****** ****** *) (* XXXX XXXX XXXX XXXX *) val shape_0: shape = let val m = 2 imul BSZ and n = 2 imul BSZ val M = matrix_make_elt (m, n, '@') in shape_make (M, m, n) end (* XX XX XX XX XX XX XX XX *) val shape_1: shape = let val m = 4 imul BSZ and n = BSZ val M = matrix_make_elt (m, n, '%') in shape_make (M, m, n) end (* XX XX XXXXXX XXXXXX *) val shape_2: shape = let val m = 2 imul BSZ and n = 3 imul BSZ val M = matrix_make_elt (m, n, 'N') val S = shape_make (M, m, n) in set_block_at {2,3} (S, 0, 0, ' '); set_block_at {2,3} (S, 0, 2, ' '); S end // end of [shape_2] (* XXXX XXXX XX XX XX XX *) val shape_3: shape = let val m = 3 imul BSZ and n = 2 imul BSZ val M = matrix_make_elt (m, n, 'Z') val S = shape_make (M, m, n) in set_block_at {3,2} (S, 1, 0, ' '); set_block_at {3,2} (S, 2, 0, ' '); S end // end of [shape_3] (* XXXX XXXX XX XX XX XX *) val shape_4: shape = let val m = 3 imul BSZ and n = 2 imul BSZ val M = matrix_make_elt (m, n, 'Z') val S = shape_make (M, m, n) in set_block_at {3,2} (S, 1, 1, ' '); set_block_at {3,2} (S, 2, 1, ' '); S end // end of [shape_4] (* XX XX XXXX XXXX XX XX *) val shape_5: shape = let val m = 3 imul BSZ and n = 2 imul BSZ val M = matrix_make_elt (m, n, 'X') val S = shape_make (M, m, n) in set_block_at {3,2} (S, 0, 1, ' '); set_block_at {3,2} (S, 2, 0, ' '); S end // end of [shape_5] (* XX XX XXXX XXXX XX XX *) val shape_6: shape = let val m = 3 imul BSZ and n = 2 imul BSZ val M = matrix_make_elt (m, n, 'X') val S = shape_make (M, m, n) in set_block_at {3,2} (S, 0, 0, ' '); set_block_at {3,2} (S, 2, 1, ' '); S end // end of [shape_6] val shape_arr = array_make_arrpsz{shape}$arrpsz( shape_0 , shape_1 , shape_2 , shape_3 , shape_4 , shape_5 , shape_6 ) // end of [shape_arr] (* ****** ****** *) extern fun natrand48 {n:pos} (range: int n): natLt n = "natrand48" %{^ ats_int_type natrand48 ( ats_int_type range ) { return (range * atslib_drand48 ()) ; } // end of [natrand48] %} // end of [%{^] fn gen_shape_obj (): [l:addr] ( free_gc_v (shapeObj0?, l), shapeObj @ l | ptr l ) = let val i = natrand48 (7) in shapeObj_make (shape_arr[i]) end // end of [gen_shape_obj] (* ****** ****** *) fn tetrix (): void = let // val () = srand48_with_time () val (pf_stdin | ptr_stdin) = stdin_get () // fun loop (): void = let val (pf_gc, pf | p) = gen_shape_obj () in shapeObj_falling !p; ptr_free {shapeObj0?} (pf_gc, pf | p) ; loop () end // end of [loop] // in save_set_keyboard (); print_string clear; fflush_stdout (); print_usage (); curs_home (); curs_downward (XBASE + 1); print_frame (); curs_invisible () ; while (fgetc_err (file_mode_lte_r_r | !ptr_stdin) <> int_of '\n') () ; curs_goto (XSCORE, YSCORE) ; print_string "score: " ; print_score () ; try loop () with ~GameIsOverException () => begin curs_clear (); curs_normal (); print_string "Game Over! Your score is "; print !total_number_of_filled_lines; print_string "."; print_newline (); restore_keyboard () end ; stdin_view_set (pf_stdin | (*none*)); // deadcode end // end of [tetrix] implement main (argc, argv) = begin try tetrix () with exn => (restore_keyboard (); $raise exn) end // end of [main] (* ****** ****** *) %{$ #include #include /* * From the downloaded sources of the book * "Beginning Linux Programming" - Wrox. * * Copyright Wrox Press. * Licensed by the General Public License (GPL). * See http://www.gnu.org/licenses/gpl.txt for details. */ #include #include #include #include #include #include static struct termios initial_settings, new_settings; static int peek_character = -1; ats_void_type save_set_keyboard () { tcgetattr(0,&initial_settings); new_settings = initial_settings; new_settings.c_lflag &= ~ICANON; new_settings.c_lflag &= ~ECHO; new_settings.c_lflag &= ~ISIG; new_settings.c_cc[VMIN] = 1; new_settings.c_cc[VTIME] = 0; tcsetattr(0, TCSANOW, &new_settings); } ats_void_type restore_keyboard () { tcsetattr(0, TCSANOW, &initial_settings); } ats_int_type kbhit () { char ch; int nread; if (peek_character != -1) return 1; new_settings.c_cc[VMIN]=0; tcsetattr(0, TCSANOW, &new_settings); nread = read(0,&ch,1); new_settings.c_cc[VMIN]=1; tcsetattr(0, TCSANOW, &new_settings); if (nread == 1) { peek_character = ch; return 1; } return 0; } ats_int_type readch () { char ch; if (peek_character != -1) { ch = peek_character; peek_character = -1; return ch; } return -1; } %} // end of [%{$] (* ****** ****** *) (* end of [tetrix.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/mycat.dats0000664000175000017500000003350412223166161020366 0ustar hwxihwxi(* ** ** An implementation of 'cat', kind of ** ** Author: Sylvain Nahas (* sylvain DOT nahas AT googlemail DOT com *) ** Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) ** ** Time: Summer, 2011 *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload FCNTL = "libc/SATS/fcntl.sats" stadef fildes_v = $FCNTL.fildes_v macdef O_RDONLY = $FCNTL.O_RDONLY staload UNISTD = "libc/SATS/unistd.sats" macdef STDIN_FILENO = $UNISTD.STDIN_FILENO macdef STDOUT_FILENO = $UNISTD.STDOUT_FILENO (* ****** ****** *) extern fun{env:viewt@ype} getchars {n:nat} ( env: &env, buf: &bytes(n), n: size_t (n) ) : sizeLte (n) // end of [getchars] extern fun{env:viewt@ype} putchars {n:nat} {n1:nat | n1 <= n} (env: &env, buf: &bytes(n), n1: size_t n1): void // end of [putchars] fun{env1,env2:viewt@ype} catloop {n:nat} ( env1: &env1, env2: &env2 , buf: &bytes(n), n: size_t n ) : void = let val n1 = getchars (env1, buf, n) in if n1 > 0 then (putchars (env2, buf, n1); catloop (env1, env2, buf, n)) else () // end of [if] end // end of [catloop] ;(* ****** ****** *) %{^ typedef struct { int number_nonblank ; int show_ends ; int number ; int squeeze_blank ; int show_tabs ; int show_nonprinting ; } params_t ; %} typedef params = $extype_struct "params_t" of { number_nonblank = bool, // number nonempty output lines show_ends = bool, // display $ at end of each line number = bool, // number all output lines squeeze_blank= bool, // suppress repeated empty output lines show_tabs=bool, // display TAB characters as ^I show_nonprinting=bool // use ^ and M- notation, except for LFD and TAB } extern fun params_copy ( to: ¶ms, from: ¶ms ) : void = "mycat_params_copy" implement params_copy (to, from) = { val () = to.number_nonblank := from.number_nonblank val () = to.show_ends := from.show_ends val () = to.number := from.number val () = to.squeeze_blank := from.squeeze_blank val () = to.show_tabs := from.show_tabs val () = to.show_nonprinting := from.show_nonprinting } // end of [params_copy] (* ****** ****** *) fn is_quoted_output (params: ¶ms): bool = params.number_nonblank || params.show_ends || params.number || params.squeeze_blank || params.show_tabs || params.show_nonprinting (* ****** ****** *) %{^ typedef struct { int fildes ; } envinp_t ; %} viewtypedef envinp (fd:int) = $extype_struct "envinp_t" of { fildes= int (fd) // file descriptor , fildes_v= fildes_v (fd) // file descriptor view } // end of [envinp] %{^ typedef struct { int dummy ; } envstdout_t ; %} viewtypedef envstdout () = $extype_struct "envstdout_t" of { dummy= int } (* ****** ****** *) local sta fd: int in implement getchars (env, buf, n) = let val n1 = $FCNTL.read_exn (env.fildes_v | env.fildes, buf, n) in n1 (* the number of chars read *) end // end of [end] end // end of [local] implement putchars (env, buf, n1) = let val (pf_stdout | ()) = $UNISTD.stdout_fildes_view_get () val n1 = $FCNTL.write_all_err (pf_stdout | STDOUT_FILENO, buf, n1) val () = $UNISTD.stdout_fildes_view_set (pf_stdout | (*none*)) in // nothing end // end of [putchars] (* ****** ****** *) fun readout_raw {fd:int} ( pf: !fildes_v fd | fd: int fd ) : void = let // var env1: envinp(fd) val () = env1.fildes := fd prval () = env1.fildes_v := pf var env2: envstdout () val () = env2.dummy := 0 // #define BUFSZ 4096 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val () = catloop (env1, env2, !p_buf, BUFSZ) // prval () = pf := env1.fildes_v in // nothing end // end of [readout_raw] (* ****** ****** *) absview cbuf_v (l0:addr, n: int, l:addr) %{^ ATSinline() ats_void_type cbuf_putchar ( ats_ptr_type p , ats_char_type c ) { *(char*)p = c ; return ; } // end of [cbuf_putchar] ATSinline() ats_void_type cbuf_clearall ( ats_ptr_type p0, ats_ptr_type p ) { if (p0 < p) { atslib_fildes_write_all_exn (STDOUT_FILENO, p0, (char*)p - (char*)p0) ; } // end of [if] return ; } // end of [cbuf_clearall] %} // end of [%{^] extern fun cbuf_putchar {n:nat} {l0:addr} {l:addr | l < l0 + n} ( pf: !cbuf_v (l0, n, l) >> cbuf_v (l0, n, l+1) | p: ptr l, c: char ) : void = "mac#cbuf_putchar" extern fun cbuf_clearall {n:nat} {l0:addr} {l:addr | l <= l0 + n} ( pf: !cbuf_v (l0, n, l) >> cbuf_v (l0, n, l0) | p0: ptr l0, p: ptr l ) : void = "mac#cbuf_clearall" (* ****** ****** *) fun putchar_quoted_buf {n:nat} {l0:addr} {l:addr | l + 4 <= l0 + n} ( pfbuf: !cbuf_v (l0, n, l) >> cbuf_v (l0, n, l) | params: ¶ms, b: char, p0: ptr l0, p: ptr l ) : #[l:addr | l <= l0+n] ptr l = let #define i2c char_of_int val ch = int_of_uchar ((uchar_of_char)b) macdef putc (p, c) = cbuf_putchar (pfbuf | ,(p), ,(c)) in case+ 0 of | _ when ch < 32 => begin case+ b of | '\t' when ~params.show_tabs => (putc(p, '\t'); p+1) | '\n' => (putc(p, '$') ; putc(p+1, '\n'); p+2) | _ => (putc(p, '^'); putc(p+1, i2c(ch+64)); p+2) end // end of [...] | _ when ch < 127 => ( putc (p, b); p+1 ) | _ when ch = 127 => ( putc (p, '^'); putc (p+1, '?'); p+2 ) | _ when ch < 128 + 32 => ( putc(p, 'M'); putc(p+1, '-'); putc(p+2, '^'); putc(p+3, i2c(ch-128+64)); p+4 ) | _ when ch < 128 + 127 => ( putc(p, 'M'); putc(p+1, '-'); putc(p+2, i2c(ch-128)); p+3 ) | _ => ( putc(p, 'M'); putc(p+1, '-'); putc(p+2, '^'); putc(p+3, '?'); p+4 ) (* end of [_] *) end // end of [putchar_quoted_buf] (* ****** ****** *) %{^ #define CBUFSZ 4096 %} #define CBUFSZ 4096 fun putchars_quoted {n:int} {n1,i:nat | i <= n1; n1 <= n} {l0:addr} {l:addr | l <= l0+CBUFSZ} ( pfbuf: !cbuf_v (l0, CBUFSZ, l) >> cbuf_v (l0, CBUFSZ, l0) | params: ¶ms , cs: &bytes(n), n1: size_t n1, i: size_t i, p0: ptr l0, p: ptr l ) : void = if i < n1 then let val b = (char_of_byte)cs.[i] in if p + 4 <= p0 + CBUFSZ then let val p = putchar_quoted_buf (pfbuf | params, b, p0, p) in putchars_quoted (pfbuf | params, cs, n1, i+1, p0, p) end else let val () = cbuf_clearall (pfbuf | p0, p) val p = putchar_quoted_buf (pfbuf | params, b, p0, p0) in putchars_quoted (pfbuf | params, cs, n1, i+1, p0, p) end end else let val () = cbuf_clearall (pfbuf | p0, p) in // nothing end // end of [if] (* ****** ****** *) %{^ typedef struct { params_t params ; ats_ptr_type p_cbuf ; } envstdoutq_t ; ATSinline() ats_void_type envstdoutq_initialize ( envstdoutq_t *env, params_t *from ) { // extern ats_void_type mycat_params_copy (ats_ptr_type to, ats_ptr_type from) ; // mycat_params_copy (&env->params, from) ; env->p_cbuf = ATS_MALLOC (CBUFSZ) ; return ; } // end of [envstdoutq_initialize] ATSinline() ats_void_type envstdoutq_uninitialize ( envstdoutq_t *env ) { ATS_FREE (env->p_cbuf) ; return ; } // end of [envstdoutq_uninitialize] ATSinline() ats_ptr_type envstdoutq_get_cbuf (envstdoutq_t *env) { return env->p_cbuf ; } // end of [envstdoutq_get_cbuf] %} // end of [%{^] (* ****** ****** *) viewtypedef envstdoutq = $extype_struct "envstdoutq_t" of { params= params , _rest= undefined_vt } extern fun envstdoutq_initialize ( env: &envstdoutq? >> envstdoutq, from: ¶ms ) : void = "mac#envstdoutq_initialize" extern fun envstdoutq_uninitialize ( env: &envstdoutq >> envstdoutq? ) : void = "mac#envstdoutq_uninitialize" local stadef viewout = $UN.viewout in // in of [local] extern fun envstdoutq_get_cbuf (env: &envstdoutq) : [l0:addr] (viewout (cbuf_v (l0, CBUFSZ, l0)) | ptr l0) = "mac#envstdoutq_get_cbuf" implement putchars (env, cs, n1) = let val (pfout | p0) = envstdoutq_get_cbuf (env) prval (pf, fpf) = $UN.viewout_decode (pfout) val () = putchars_quoted (pf | env.params, cs, n1, 0, p0, p0) prval () = fpf (pf) in // nothing end // end of [putchars] end // end of [ (* ****** ****** *) fun readout_quoted {fd:int} ( pf: !fildes_v fd | params: ¶ms, fd: int fd ) : void = let // var env1: envinp(fd) val () = env1.fildes := fd prval () = env1.fildes_v := pf var env2: envstdoutq val () = envstdoutq_initialize (env2, params) // #define BUFSZ 4096 var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val () = catloop (env1, env2, !p_buf, BUFSZ) // prval () = pf := env1.fildes_v val () = envstdoutq_uninitialize (env2) in // nothing end // end of [readout_quoted] (* ****** ****** *) fun cat_stdin (params: ¶ms): void = { val (pf_stdin | ()) = $UNISTD.stdin_fildes_view_get () val isq = is_quoted_output (params) val () = if isq then readout_quoted (pf_stdin | params, STDIN_FILENO) else readout_raw (pf_stdin | STDIN_FILENO) // output directly // end of [if] val () = $UNISTD.stdin_fildes_view_set (pf_stdin | (*none*)) } // end of [cat_stdin] (* ****** ****** *) /* ** open, dump and close file */ fun cat_file ( params: ¶ms, path: string ) : void = let val (pf_fd | fd) = $FCNTL.open_flag_exn(path, O_RDONLY) val isq = is_quoted_output (params) val () = if isq then readout_quoted (pf_fd | params, fd) else readout_raw (pf_fd | fd) // output directly // end of [if] in $FCNTL.close_exn (pf_fd | fd) end // end of [cat_file] (* ****** ****** *) (* an "object-like" notation would be cool! *) exception FunctionalityNotSupported fn number_nonblank(params: ¶ms) : void = $raise FunctionalityNotSupported fn show_ends(params: ¶ms) : void = params.show_ends := true fn number(params: ¶ms) : void = $raise FunctionalityNotSupported fn squeeze_blank(params: ¶ms) : void = $raise FunctionalityNotSupported fn show_tabs(params: ¶ms) : void = params.show_tabs := true fn show_nonprinting (params: ¶ms) : void = params.show_nonprinting := true (* ****** ****** *) #define PROGRAM_VERSION "6.10\n" fn version() = prerr(PROGRAM_VERSION) (* ****** ****** *) fn help () = ( prerr "Usage: cat [OPTION] [FILE]... Concatenate FILE(s), or standard input, to standard output. -A, --show-all equivalent to -vET -b, --number-nonblank number nonempty output lines -e equivalent to -vE -E, --show-ends display $ at end of each line -n, --number number all output lines -s, --squeeze-blank suppress repeated empty output lines -t equivalent to -vT -T, --show-tabs display TAB characters as ^I -u (ignored) -v, --show-nonprinting use ^ and M- notation, except for LFD and TAB --help display this help and exit --version output version information and exit With no FILE, or when FILE is -, read standard input. Examples: cat f - g Output f's contents, then standard input, then g's contents. cat Copy standard input to standard output.\n" ) (* ****** ****** *) /* ** SN: suppose that current parameter is a file path to cat() */ fun parse_file_path {n:int | n >= 1} {m:nat | m < n } ( params: ¶ms, argc: int n, argv: &(@[string][n]), current: int m ) : void = let val () = assert(current < argc) val path = string1_of_string (argv.[current]) val () = assert_errmsg( gte_size1_int1(string1_length(path),1),"path must contain at least one character!" ) // end of [val] val () = cat_file(params, path) val next = current+1 in if next = argc then () else parse_file_path(params, argc, argv, next) // end of [if] end (* end of [parse_file_path] *) (* ****** ****** *) /* ** SN: suppose that current parameter is not a file path */ fun parse_non_file_parameters {n:int | n >= 1} {m:nat | m < n } ( params: ¶ms, argc: int n, argv: &(@[string][n]), current: int m ) : bool = let val () = assert(current < argc) val param = string1_of_string (argv.[current]) in case+ param of | "--help" => ( help(); exit(0); ) | "--version" => ( version(); exit(0); ) | "-A" => ( show_nonprinting(params); show_ends(params); show_tabs(params); false; ) | "--show-all" => ( show_nonprinting(params); show_ends(params); show_tabs(params); false; ) | "-b" => ( number_nonblank(params); false; ) | "--number-nonblank" => ( number_nonblank(params); false; ) | "-e" => ( show_nonprinting(params); show_ends(params); false; ) | "-E" => ( show_ends(params); false; ) | "--show-ends" => ( show_ends(params); false; ) | "-n" => ( number(params); false; ) | "--number" => ( number(params); false; ) | "-s" => ( squeeze_blank(params); false; ) | "--squeeze-blank" => ( squeeze_blank(params); false; ) | "-t" => ( show_tabs(params) ; show_nonprinting(params); false; ) | "-T" => ( show_tabs(params); false; ) | "--show-tabs" => ( show_tabs(params); false; ) | "-u" => (* IGNORED*) false | "-v" => ( show_nonprinting(params); false; ) | "--show-nonprinting" => ( show_nonprinting(params); false; ) | _ => (* unknown parameter => file path? *) true end // end of [parse_non_file_parameters] (* ****** ****** *) fun parse_parameters {n:int | n >= 1} {m:nat | m < n } ( params: ¶ms, argc: int n, argv: &(@[string][n]), current: int m ) : void = let val isfilepath = parse_non_file_parameters (params, argc, argv, current) val next = current + 1 in case+ isfilepath of | false => ( if next = argc then cat_stdin(params) else parse_parameters(params, argc,argv,next) // end of [if] ) // end of [false] | true => parse_file_path(params, argc,argv,current) end // end of [parse_parameters] (* ****** ****** *) implement main(argc, argv) = let var params : params val () = params.number_nonblank := false val () = params.show_ends := false val () = params.number := false val () = params.squeeze_blank:= false val () = params.show_tabs := false val () = params.show_nonprinting := false in if argc = 1 then cat_stdin(params) else parse_parameters(params, argc,argv,1) // end of [if] end (* end of [main] *) (* ****** ****** *) (* end of [mycat.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/passwdgen.dats0000664000175000017500000000215312223166161021240 0ustar hwxihwxi(* ** ** random password generation ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: August, 2008 ** *) (* ****** ****** *) staload Rand = "libc/SATS/random.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) implement main (argc, argv) = let var n: int = 8 val () = begin if argc >= 2 then n := int_of_string (argv.[1]) end val [n:int] n = int1_of n val () = assert (n >= 0) val () = $Rand.srand48_with_time () val passwd = array_make_elt (size1_of_int1 n, '\000') val () = loop (n, 0) where { fun loop {i:nat | i <= n} .. (n: int n, i: int i): void = if (i < n) then let val c = char_of_int ($Rand.randint (94) + 33) in passwd[i] := c; loop (n, i+1) end } // end of [where] val () = loop (n, 0) where { fun loop {i:nat | i <= n} .. (n: int n, i: int i): void = if (i < n) then (print passwd[i]; loop (n, i+1)) } // end of [where] val () = print_newline () in // empty end // end of [main] (* ****** ****** *) (* end of [passwdgen.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Twentyfour/0000700000175000017500000000000012223166161020541 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Twentyfour/Makefile0000664000175000017500000000127312223166161022220 0ustar hwxihwxi## ## Makefile for [twentyfour.dats] ## ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### #GCFLAG=-D_ATS_gc // no longer in use #GCFLAG=-D_ATS_gcats // no longer in use GCFLAG=-D_ATS_GCATS #GCFLAG=-D_ATS_GCBDW ###### .PHONY: all all: checkall cleanall ###### checkall:: cleanall:: clean ###### checkall:: twentyfour twentyfour: twentyfour.dats rational.dats rational.sats $(ATSCC) -O2 $(GCFLAG) -o twentyfour twentyfour.dats rational.dats rational.sats -lm \ && ./twentyfour ###### clean: rm -f *~ rm -f *_dats.c *_sats.c cleanall:: ; rm -f twentyfour ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Twentyfour/rational.sats0000664000175000017500000000477512223166161023277 0ustar hwxihwxi(* // // interface for some operations on rational numbers // // author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // *) (* ****** ****** *) // // assume int_t: t@ype // assume rat_t: t@ype // the header file for rational // (* ****** ****** *) abst@ype int_t = int abst@ype rat_t = @{ numer= int_t, denom= int_t } (* ****** ****** *) // // HX: for testing, please do not change 'val' to 'fun' // (* ****** ****** *) val int_make_int0 : int -<> int_t val rat_make_int_int : (int_t, int_t) - rat_t val rat_make_int : int_t -<> rat_t val rat_zero : rat_t and rat_one : rat_t val rat_numerator: rat_t -<> int_t val rat_denominator : rat_t -<> int_t (* ****** ****** *) exception DivisionByZeroException of () (* ****** ****** *) val abs_rat : rat_t -<> rat_t overload abs with abs_rat val neg_rat : rat_t -<> rat_t overload ~ with neg_rat val add_rat_rat : (rat_t, rat_t) -<> rat_t overload + with add_rat_rat val sub_rat_rat : (rat_t, rat_t) -<> rat_t overload - with sub_rat_rat val mul_rat_rat : (rat_t, rat_t) -<> rat_t overload * with mul_rat_rat val div_rat_rat : (rat_t, rat_t) - rat_t overload / with div_rat_rat val recip_rat : rat_t - rat_t (* ****** ****** *) val square_rat: rat_t -<> rat_t val cube_rat: rat_t -<> rat_t val power_rat: (rat_t, Nat) -<> rat_t (* ****** ****** *) val is_zero : rat_t -<> bool val is_not_zero : rat_t -<> bool val is_negative : rat_t -<> bool val is_not_negative : rat_t -<> bool val is_positive : rat_t -<> bool val is_not_positive : rat_t -<> bool (* ****** ****** *) val lt_rat_rat : (rat_t, rat_t) -<> bool val lte_rat_rat : (rat_t, rat_t) -<> bool val gt_rat_rat : (rat_t, rat_t) -<> bool val gte_rat_rat : (rat_t, rat_t) -<> bool overload < with lt_rat_rat overload <= with lte_rat_rat overload > with gt_rat_rat overload >= with gte_rat_rat val eq_rat_rat : (rat_t, rat_t) -<> bool val neq_rat_rat : (rat_t, rat_t) -<> bool overload = with eq_rat_rat overload <> with neq_rat_rat val compare_rat_rat: (rat_t, rat_t) -<> Sgn overload compare with compare_rat_rat val max_rat_rat : (rat_t, rat_t) -<> rat_t and min_rat_rat : (rat_t, rat_t) -<> rat_t overload max with max_rat_rat overload min with min_rat_rat (* ****** ****** *) val tostring_rat : rat_t -<> string overload tostring with tostring_rat val fprint_rat: fprint_t0ype_type rat_t overload fprint with fprint_rat val print_rat : rat_t - void val prerr_rat : rat_t - void overload print with print_rat overload prerr with prerr_rat (* ****** ****** *) (* end of [rational.sats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Twentyfour/twentyfour.dats0000664000175000017500000002125012223166161023660 0ustar hwxihwxi// // An implemention of the so-called game-of-24 // Some typical uses of macros are presented here. // // The code was first translated to ATS/Proto by Hongwei Xi in // the summer of 2004 from an earlier version in Standard ML // // Translated to ATS/Geizella by Hongwei Xi // Time: June 2007 // (* Given four natural numbers n1, n2, n3 and n4, one chooses two of them and generates a rational number r1 using either addition, subtraction, multiplication or division; one mixes r1 with the remaining two numbers and chooses two of them to generate a rational number r2 using either addition, subtraction, multiplication or division; one then takes r2 and the last remaining number to get a rational number r3 using addition, subtraction, multiplication, or division; if there is a way to make r3 equal 24, then we say that (n1, n2, n3, n4) is a good quad. For instance, (10,10,4,4) is a good quad since we have (10 * 10 - 4) / 4 = 24 Similarly, (5, 7, 7, 11) is a good quad since we have (5 - 11 / 7) * 7 = 24 Game of 24 is a game that determines whether four given natural numbers are a good quad. *) (* typedef int_t = int staload "rational.sats" with { int_t = int_t } dynload "rational.dats" with { int_t = int_t } *) staload "rational.sats" dynload "rational.dats" (* ****** ****** *) // macro definition macdef ignore (x) = let val _ = ,(x) in () end datatype expr = | Num of rat_t | Add of (expr, expr) | Sub of (expr, expr) | Mul of (expr, expr) | Div of (expr, expr) // end of [expr] // macro definition macdef priority_mac e = (case+ ,(e) of | Num _ => 0 | Add _ => 2 | Sub _ => 2 | Mul _ => 1 | Div _ => 1 ) : Nat // end of [priority_mac] // fun priority (e: expr): Nat = ,(priority_mac `(e)) fun print_expr (e: expr): void = begin case+ e of | Num r => print r | Add (e1, e2) => let val p1 = priority_mac e1 and p2 = priority_mac e2 in print_expr_ (2, p1, e1); print '+'; print_expr_ (2, p2, e2) end // end of [Add] | Sub (e1, e2) => let val p1 = priority_mac e1 and p2 = priority_mac e2 in print_expr_ (2, p1, e1); print '-'; print_expr_ (2, p2, e2) end // end of [Sub] | Mul (e1, e2) => let val p1 = priority_mac e1 and p2 = priority_mac e2 in print_expr_ (1, p1, e1); print '*'; print_expr_ (1, p2, e2) end // end of [Mul] | Div (e1, e2) => let val p1 = priority_mac e1 and p2 = priority_mac e2 in print_expr_ (1, p1, e1); print '/'; print_expr_ (1, p2, e2) end // end of [Div] end // end of [print_expr] and print_expr_ (p0: Nat, p: Nat, e: expr): void = if p < p0 then print_expr e else (print "("; print_expr e; print ")") // end of [print_expr_] typedef card = (expr, rat_t) macdef val_of_card_mac c = let val (_, v) = ,(c) in v end // fun val_of_card (c: card): rat_t = val_of_card_mac `(c) #define i2r rat_make_int fun card_of_int0 (i: int): card = let val i = int_make_int0 i in (Num (i2r i), i2r i) end macdef print_card_mac c = let val (e, _): card = ,(c) in print_expr e end // fun print_card (c: card): void = print_card_mac c macrodef cardAdd_mac c1 c2 = `( let val (e1, v1) = ,(c1) and (e2, v2) = ,(c2) in (Add (e1, e2), v1 + v2) end ) // end of [cardAdd_mac] macrodef cardSub_mac c1 c2 = `( let val (e1, v1) = ,(c1) and (e2, v2) = ,(c2) in (Sub (e1, e2), v1 - v2) end ) // end of [cardSub_mac] macrodef cardMul_mac c1 c2 = `( let val (e1, v1) = ,(c1) and (e2, v2) = ,(c2) in (Mul (e1, e2), v1 * v2) end ) // end of [cardMul_mac] macrodef cardDiv_mac c1 c2 = `( let val (e1, v1) = ,(c1) and (e2, v2) = ,(c2) in (Div (e1, e2), v1 / v2) end ) // end of [cardDiv_mac] (* // fun cardAdd (c1: card, c2: card) = ,(cardAdd_mac `(c1) `(c2)) // fun cardSub (c1: card, c2: card) = ,(cardSub_mac `(c1) `(c2)) // fun cardMul (c1: card, c2: card) = ,(cardMul_mac `(c1) `(c2)) // fun cardDiv (c1: card, c2: card) = ,(cardDiv_mac `(c1) `(c2)) *) datatype cards = cards_nil | cards_cons of (card, cards) #define nil cards_nil #define :: cards_cons fn combine (x: card, y: card): cards = let val c1 = ,(cardAdd_mac `(x) `(y)) val c2 = ,(cardSub_mac `(x) `(y)) and c3 = ,(cardSub_mac `(y) `(x)) val c4 = ,(cardMul_mac `(x) `(y)) in if is_zero (val_of_card_mac x) then c1 :: c2 :: c3 :: c4 :: nil () else if is_zero (val_of_card_mac y) then c1 :: c2 :: c3 :: c4 :: nil () else let val c5 = ,(cardDiv_mac `(x) `(y)) and c6 = ,(cardDiv_mac `(y) `(x)) in c1 :: c2 :: c3 :: c4 :: c5 :: c6 :: nil () end end // end of [combine] fun cards_append_r (xs: cards, ys: cards): cards = begin case+ xs of | x :: xs => cards_append_r (xs, x :: ys) | nil () => ys end // end of [cards_append_r] (* ****** ****** *) // this code does not make use of templates datatype ratpairlst = | ratpairlst_nil | ratpairlst_cons of (rat_t, rat_t, ratpairlst) // end of [ratpairlst] #define rp_nil ratpairlst_nil #define rp_cons ratpairlst_cons fn ismem (x0: rat_t, y0: rat_t, xys: ratpairlst): Bool = let fun aux (xys: ratpairlst): Bool = case+ xys of | rp_nil () => false | rp_cons (x, y, xys) => begin if x0 = x then (if y0 = y then true else aux xys) else aux xys end // end of [rp_cons] // end of [aux] in aux xys end // end of [ismem] (* ****** ****** *) exception Fatal fn fatal{a:viewtype} (msg: String): a = (print msg; $raise Fatal) (* ****** ****** *) fun playGame (cs: cards, res: rat_t): Bool = let // [fn*]: mutual tail-call optimization fn* aux_main (zs: cards, xys: ratpairlst): Bool = case- zs of | x :: nil () => if res = val_of_card_mac x then begin (print_card_mac x; print " = "; print res; true) end else false | x :: y :: zs => aux1 (x, nil (), y, nil (), zs, xys) // end of [aux_main] and aux1 (x: card, xs: cards, y: card, ys: cards, zs: cards, xys: ratpairlst) : Bool = if ismem (val_of_card_mac x, val_of_card_mac y, xys) then aux2 (x, xs, y, ys, zs, xys) else aux1_ (combine (x, y), x, xs, y, ys, zs, xys) // end of [if] (* end of [aux1] *) and aux1_ (rs: cards, x: card, xs: cards, y: card, ys: cards, zs: cards, xys: ratpairlst) : Bool = case+ rs of | r :: rs => if aux_main (cards_append_r (xs, cards_append_r (ys, r :: zs)), rp_nil ()) then true else aux1_ (rs, x, xs, y, ys, zs, xys) // end of [::] | nil () => aux2 (x, xs, y, ys, zs, rp_cons (val_of_card_mac x, val_of_card_mac y, xys)) // end of [nil] (* end of [aux1_] *) and aux2 (x: card, xs: cards, y: card, ys: cards, zs: cards, xys: ratpairlst) : Bool = case+ zs of | z :: zs => aux1 (x, xs, z, y :: ys, zs, xys) | nil () => ( case+ cards_append_r (ys, y :: nil ()) of | x1 :: y1 :: zs1 => aux1 (x1, x :: xs, y1, nil (), zs1, xys) | _ => false ) // end of [nil] // end of [aux2] in aux_main (cs, rp_nil ()) end // end of [playGame] val answer = i2r (int_make_int0 24) fun play (n1: int, n2: int, n3: int, n4: int): Bool = let val c1 = card_of_int0 n1 and c2 = card_of_int0 n2 and c3 = card_of_int0 n3 and c4 = card_of_int0 n4 val cs = c1 :: c2 :: c3 :: c4 :: nil () in playGame (cs, answer) end // end of [play] #define BOUND 13 macdef BOUND_f = double_of BOUND staload "libc/SATS/math.sats" staload "libc/SATS/random.sats" fn int_gen (): int = int_of (floor (1.0 + drand48 () * BOUND_f)) // end of [int_gen] (* ****** ****** *) implement main (argc, argv) = let (* // some interesting cases val _ = play (1, 7, 13, 13) val _ = play (2, 3, 5, 12) val _ = play (3, 3, 7, 7) val _ = play (3, 3, 8, 8) val _ = play (4, 4, 10, 10) val _ = play (5, 5, 7, 11) val _ = play (5, 7, 7, 11) *) // // mutual tail recursion // fn* loop1 (i1: int): void = begin (* prerr "loop1: i1 = "; prerr i1; prerr_newline (); *) if i1 <= BOUND then loop2 (i1, i1) else () end // end of [loop1] and loop2 (i1: int, i2: int): void = if i2 <= BOUND then loop3 (i1, i2, i2) else loop1 (i1+1) // end of [loop2] and loop3 (i1: int, i2: int, i3: int): void = if i3 <= BOUND then loop4 (i1, i2, i3, i3) else loop2 (i1, i2+1) // end of [loop3] and loop4 (i1: int, i2: int, i3: int, i4: int): void = if i4 <= BOUND then let val () = printf ("(%i, %i, %i, %i): ", @(i1, i2, i3, i4)) val _ = play (i1, i2, i3, i4) val () = print_newline () in loop4 (i1, i2, i3, i4+1) end else begin loop3 (i1, i2, i3+1) end // end of [if] // end of [loop4] (* val () = srand48_with_time () val n1 = int_gen () and n2 = int_gen () and n3 = int_gen () and n4 = int_gen () val () = printf ("(%i, %i, %i, %i): ", @(n1, n2, n3, n4)) val res = play (n1, n2, n3, n4) val () = if ~res then print ("no solution.\n") else () *) in loop1 1 end // end of [main] (* ****** ****** *) (* end of [twentyfour.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Twentyfour/rational.dats0000664000175000017500000000752712223166161023256 0ustar hwxihwxi(* // Implementing some operations on rational numbers // // author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // *) // require int_t: t@ype and rat_t: t@ype (* staload "rational.sats" with { int_t= int_t } *) staload "rational.sats" assume int_t = int assume rat_t = @{ numer= int_t, denom= int_t } implement int_make_int0 (i) = i implement rat_make_int n = @{ numer= n, denom= 1 } implement rat_make_int_int (m, n) = if n > 0 then let val r = gcd (m, n) in @{ numer= m/r, denom= n/r } end else if n < 0 then let val r = gcd (m, n) in @{ numer= ~m/r, denom= ~n/r } end else begin $raise DivisionByZeroException () end // end of [if] // end of [rat_make_int_int] implement rat_zero = @{ numer=0, denom=1 } implement rat_one = @{ numer=1, denom=1 } implement rat_numerator r = r.numer implement rat_denominator r = r.denom (* ****** ****** *) implement add_rat_rat (r1, r2) = begin $effmask_exn (rat_make_int_int (r1.numer * r2.denom + r2.numer * r1.denom, r1.denom * r2.denom) ) // end of [$effmask_exn] end // end of [add_rat_rat] implement sub_rat_rat (r1, r2) = begin $effmask_exn (rat_make_int_int (r1.numer * r2.denom - r2.numer * r1.denom, r1.denom * r2.denom) ) // end of [$effmask_exn] end // end of [sub_rat_rat] implement mul_rat_rat (r1, r2) = begin $effmask_exn (rat_make_int_int (r1.numer * r2.numer, r1.denom * r2.denom)) end // end of [mul_rat_rat] implement div_rat_rat (r1, r2) = begin rat_make_int_int (r1.numer * r2.denom, r1.denom * r2.numer) end // end of [div_rat_rat] implement recip_rat r = begin if r.numer <> 0 then @{ numer= r.denom, denom= r.numer } else $raise DivisionByZeroException end // end of [recip_rat] (* ****** ****** *) implement square_rat r = @{ numer = square r.numer, denom= square r.denom } implement power_rat (r0, n0) = let var r = r0 and n = n0 and res = rat_one val () = while* {n:nat} .. (n:int n, r: rat_t, res: rat_t) => (true) ( case+ n of | 0 => break | 1 => (res := mul_rat_rat (r, res); break) | _ =>> begin if n mod 2 > 0 then begin n := n / 2; res := mul_rat_rat (r, res); r := square_rat r; continue end else begin n := n / 2; r := square_rat r; continue end end ) // end of [while*] in res end // end of [power_rat] (* ****** ****** *) implement lt_rat_rat (r1, r2) = r1.numer * r2.denom < r2.numer * r1.denom implement lte_rat_rat (r1, r2) = r1.numer * r2.denom <= r2.numer * r1.denom implement gt_rat_rat (r1, r2) = r1.numer * r2.denom > r2.numer * r1.denom implement gte_rat_rat (r1, r2) = r1.numer * r2.denom >= r2.numer * r1.denom implement eq_rat_rat (r1, r2) = if r1.numer = r2.numer then r1.denom = r2.denom else false implement neq_rat_rat (r1, r2) = if r1.numer <> r2.numer then true else r1.denom <> r2.denom (* ****** ****** *) implement compare_rat_rat (r1, r2) = compare (r1.numer * r2.denom, r2.numer * r1.denom) implement max_rat_rat (r1, r2) = if r1.numer * r2.denom >= r2.numer * r1.denom then r1 else r2 implement min_rat_rat (r1, r2) = if r1.numer * r2.denom <= r2.numer * r1.denom then r1 else r2 (* ****** ****** *) implement is_zero r = r.numer = 0 implement is_not_zero r = r.numer <> 0 implement is_negative r = r.numer < 0 implement is_not_negative r = r.numer >= 0 implement is_positive r = r.numer > 0 implement is_not_positive r = r.numer <= 0 (* ****** ****** *) implement fprint_rat (pf_mode | out, r) = if r.denom > 1 then begin fprintf (pf_mode | out, "%i/%i", @(r.numer, r.denom)) end else fprint (pf_mode | out, r.numer) implement print_rat r = print_mac (fprint_rat, r) implement prerr_rat r = prerr_mac (fprint_rat, r) implement tostring_rat r = if r.denom <> 1 then string_of_strptr (tostringf ("%i/%i", @(r.numer, r.denom))) else tostring r.numer // end of [tostring_rat] (* ****** ****** *) (* end of rational.dats *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/coin_flip.dats0000664000175000017500000000633012223166161021210 0ustar hwxihwxi// // // One of the early examples first done in ATS/Geizella // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: circa May 2007 // (* ****** ****** *) // // HX: // The *awkward* style should be not be changed so as to preserve // a bit history about the development of ATS // (* ****** ****** *) staload Rand = "libc/SATS/random.sats" staload Time = "libc/SATS/time.sats" (* ****** ****** *) extern fun array_int_ptr_make : {n:nat} int n - [l:addr] (@[Nat][n] @ l | ptr l) = "ats_array_int_ptr_make" extern fun array_int_ptr_free : {n:nat} {l:addr} (@[Nat?][n] @ l | ptr l) - void = "ats_array_int_ptr_free" extern fun array_int_ptr_get : {n:nat} {l:addr} (! @[Nat][n] @ l | ptr l, natLt n) -<> Nat = "ats_array_int_ptr_get" extern fun array_int_ptr_set : {n:nat} {l:addr} (! @[Nat][n] @ l | ptr l, natLt n, Nat) -<> void = "ats_array_int_ptr_set" %{^ ats_ptr_type ats_array_int_ptr_make (ats_int_type n) { return calloc (n, sizeof(int)) ; } ats_void_type ats_array_int_ptr_free (ats_ptr_type A) { free (A) ; return ; } ats_int_type ats_array_int_ptr_get (ats_ptr_type A, ats_int_type i) { return ((ats_int_type *)A)[i] ; } ats_void_type ats_array_int_ptr_set (ats_ptr_type A, ats_int_type i, ats_int_type x) { ((ats_int_type *)A)[i] = x ; return ; } %} // end of [%{^] (* ****** ****** *) fn heads_one (): bool = $Rand.drand48 () < 0.5 fn heads_many {n:nat} (n: int n): natLte n = aux (n, 0) where { fun aux {i,s:nat | i + s <= n} .. (i: int i, s: int s): natLte n = if i > 0 then if heads_one () then aux (i-1, s+1) else aux (i-1, s) else s } // end of [heads_many] fn test_one {n:nat} {l:addr} (pf: ! @[Nat][n+1] @ l | A: ptr l, n: int n): void = let val cnt = heads_many (n) in array_int_ptr_set (pf | A, cnt, array_int_ptr_get (pf | A, cnt) + 1) end // end of [test_one] fun test_many {m,n:nat} {l:addr} .. (pf: ! @[Nat][n+1] @ l | A: ptr l, m: int m, n: int n): void = if m > 0 then (test_one (pf | A, n); test_many (pf | A, m-1, n)) else () // end of [test_many] #define INC 16 fn test_show_one {l:addr} (times: Nat): void = let fun aux {t,i:nat} .. (t: int t, i: int i): void = if i < t then (print '*'; aux (t, i+INC)) else print_newline () in if times > 0 then aux (times, 0) else print ".\n" end // end of [test_show_one] fun test_show_all {n,i:nat | i <= n+1} {l:addr} .. (pf: ! @[Nat][n+1] @ l | A: ptr l, n: int n, i: int i): void = if i <= n then (test_show_one (array_int_ptr_get (pf | A, i)); test_show_all (pf | A, n, i+1)) else () // end of [test_show_all] // macdef double = $Time.double_of_clock #define M 4096 #define N 32 implement main () = () where { val (pf | A) = array_int_ptr_make (N+1) val clock_sta = double ($Time.clock ()) val () = begin $Rand.srand48_with_time (); test_many (pf | A, M, N); test_show_all (pf | A, N, 1); array_int_ptr_free (pf | A) end val clock_fin = double ($Time.clock ()) val time_spent = (clock_fin - clock_sta) / (double)$Time.CLOCKS_PER_SEC // end of [val] val () = printf ("time spent = %.10f\n", @(time_spent)) } // end of [main] (* ****** ****** *) (* end of [coin_flip.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/sumup.dats0000664000175000017500000000220312223166161020412 0ustar hwxihwxi// // // A simple example of programming with theorem-proving // // (* ****** ****** *) // // Author: Hongwei Xi // Time: June 15, 2008 (when I was visiting Xia Chunhe at BeiHang) // (* ****** ****** *) dataprop SUMUP (int, int) = | SUMUPbas (0, 0) | {n:nat; r:int} SUMUPind (n+1, r+n+1) of SUMUP (n, r) // end of [SUMUP] (* ****** ****** *) fn sumup {n:nat} (n: int n):<> [r:int] (SUMUP (n, r) | int r) = let fun aux {i:nat; r1,r2:int} .. (pf: SUMUP (i, r1) | i: int i, res: int r2):<> int (r1+r2) = case+ i of | 0 => begin let prval SUMUPbas () = pf in res end end | _ =>> let prval SUMUPind pf = pf in aux (pf | i-1, res + i) end prval pf = prsumup {n} () where { prfun prsumup {n:nat} .. ():<> [r:int] SUMUP (n, r) = sif (n > 0) then SUMUPind (prsumup {n-1} ()) else SUMUPbas () } // end of [where] in (pf | aux (pf | n, 0)) end // end of [sumup] (* ****** ****** *) implement main (argc, argv) = let val (_ | res) = sumup (10) in printf ("sumup (10) = %i", @(res)); print_newline () end // end of [main] (* ****** ****** *) (* end of [sumup.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/HttpServer/0000700000175000017500000000000012223166161020461 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/HttpServer/Makefile0000664000175000017500000000142512223166161022137 0ustar hwxihwxi# # # A simple (single threaded) HTTP server implemented in ATS # # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall cleanall checkall:: cleanall:: clean ###### # # If on SunOS, please add [-lsocket] # checkall:: server server: server.dats $(ATSCC) -D_ATS_GCATS -o server -O2 server.dats cleanall:: ; $(RMF) server checkall:: server2 server2: server2.dats $(ATSCC) -D_ATS_GCATS -o server2 -O2 server2.dats cleanall:: ; $(RMF) server2 ###### DIR=/home/fac2/hwxi/public_html/ATS/EXAMPLE/HttpServer update:: cp Makefile $(DIR) cp server.dats $(DIR) ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) *_dats.c *_sats.c ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/HttpServer/server2.dats0000664000175000017500000005564512223166161022761 0ustar hwxihwxi(* // // Another simple web server implemented in ATS; this one is a // concurrent server as it forks out a process for handling each // request. Also, it uses array-quicksort in [stdlib.h] rather // than list-quicksort to sort directory entries. // // The issue of memory leaks is taken care of here in a rather // ad hoc manner! This example really gives a glimpse of the // kind of difficulty involved in eliminating memory leaks!!! // // March 2009: // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // *) (* ****** ****** *) %{^ #include #include %} // end of [%{^] (* ****** ****** *) staload "libc/SATS/dirent.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/printf.sats" staload STDLIB = "libc/SATS/stdlib.sats" staload "libc/SATS/string.sats" staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/socket.sats" staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket_in.sats" staload "libc/sys/SATS/types.sats" staload "libc/sys/SATS/wait.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) extern fun socket_write_substring {fd:int} {n:int} {st,ln:nat | st+ln <= n} ( pf_sock: !socket_v (fd, conn) | fd: int fd, str: string n, st: size_t st, ln: size_t ln ) : void // all bytes must be written if this function returns // end of [socket_write_substring] (* ****** ****** *) implement socket_write_substring {fd} {n} {st,ln} (pfsock | fd, str, st, ln) = let val (pf, fpf | p) = string_takeout_bufptr {n} {st} {ln} (str, st) val () = socket_write_all_exn (pfsock | fd, !p, ln) prval () = fpf (pf) in // nothing end // end of [socket_write_substring] (* ****** ****** *) // // HX: // I don't even know what these strings really mean :) // I copied them from a previous implementation by Rui Shi. // #define HTTP_OK "200" #define HTTP_CREATED "201" #define HTTP_ACCEPTED "202" #define HTTP_NOT_AUTHORITATIVE "203" #define HTTP_NO_CONTENT "204" #define HTTP_RESET "205" #define HTTP_PARTIAL "206" #define HTTP_MULT_CHOICE "300" #define HTTP_MOVED_PERM "301" #define HTTP_MOVED_TEMP "302" #define HTTP_SEE_OTHER "303" #define HTTP_NOT_MODIFIED "304" #define HTTP_USE_PROXY "305" #define HTTP_BAD_REQUEST "400" #define HTTP_UNAUTHORIZED "401" #define HTTP_PAYMENT_REQUIRED "402" #define HTTP_FORBIDDEN "403" #define HTTP_NOT_FOUND "404" #define HTTP_BAD_METHOD "405" #define HTTP_NOT_ACCEPTABLE "406" #define HTTP_PROXY_AUTH "407" #define HTTP_CLIENT_TIMEOUT "408" #define HTTP_CONFLICT "409" #define HTTP_GONE "410" #define HTTP_LENGTH_REQUIRED "411" #define HTTP_PRECON_FAILED "412" #define HTTP_ENTITY_TOO_LARGE "413" #define HTTP_REQ_TOO_LONG "414" #define HTTP_UNSUPPORTED_TYPE "415" (* ****** ****** *) local typedef string2 = @(string, string) val (pfgc, pfarr | ptr, len) = $arrpsz{string2}( ("ats", "text/plain") , ("au", "audio/basic") , ("c", "text/plain") , ("c++", "text/plain") , ("cats", "text/plain") , ("cc", "text/plain") , ("dats", "text/plain") , ("exe", "application/octet-stream") , ("gif", "image/gif") , ("h", "text/plain") , ("hats", "text/plain") , ("htm", "text/html") , ("html", "text/html") , ("java", "text/plain") , ("jpeg", "image/jpeg") , ("jpg", "image/jpeg") , ("ml", "text/plain") , ("pl", "text/plain") , ("ps", "application/postscript") , ("sats", "text/plain") , ("sh", "application/x-shar") , ("sml", "text/plain") , ("snd", "audio/basic") , ("tar", "application/x-tar") , ("text", "text/plain") , ("txt", "text/plain") , ("uu", "application/octet-stream") , ("wav", "audio/x-wav") , ("zip", "application/zip") ) // end of [val] // stavar l: addr and n: int; typedef T = @[string2][n] // prval () = free_gc_elim {string2?} (pfgc) // val (the_doctype_map_prop | ()) = vbox_make_view_ptr {T} {l} (pfarr | ptr) val the_doctype_map_ptr : ptr l = ptr val the_doctype_map_len : size_t n = len // val () = if the_doctype_map_len >= 2 then let prval vbox pf = the_doctype_map_prop val sfx0 = !the_doctype_map_ptr.[0].0 in loop (pf | the_doctype_map_ptr, the_doctype_map_len, 1, sfx0) end where { fun loop {n,i:nat | i <= n} {l:addr} .. (pf: !array_v (string2, n, l) | A: ptr l, n: size_t n, i: size_t i, sfx0: string) :<> void = if i < n then let val sfx1 = !A.[i].0 in if sfx0 < sfx1 then loop (pf | A, n, i+1, sfx1) else $effmask_all begin exit_prerrf {void} (1, "INTERNAL ERROR: the doctype map is not ordered: %s !< %s\n", @(sfx0, sfx1)) end // end of [$effmask_all] end // end of [if] // end of [loop] } // end of [val] extern fun doctype_find (sfx: string): Stropt = "doctype_find" in // in of [local] // // it is probably easier to actually implement bsearch :) // implement doctype_find (sfx) = let prval vbox pf = the_doctype_map_prop var key = @(sfx, nullstr) where { val nullstr = $extval (string, "0") } val p_arr = the_doctype_map_ptr val ind = $effmask_ref $STDLIB.bsearch {string2} (key, !p_arr, the_doctype_map_len, sizeof, cmp) where { val cmp = lam (x1: &string2, x2: &string2): Sgn =<0> compare (x1.0, x2.0) } // end of [val] in if ind >= 0 then let val typ = string1_of_string (the_doctype_map_ptr->[ind].1) in stropt_some (typ) end else stropt_none end // end of [doctype_find] end // end of [local] #define CONTENT_UNKNOWN "content/unknown" extern fun doctype_of_filename (filename: string): string implement doctype_of_filename (filename) = let val filename = string1_of_string (filename) val n = string1_length (filename); val i_dot = string_index_of_char_from_right (filename, '.') val dtopt = (if i_dot >= 0 then let val i_dot = size1_of_ssize1 (i_dot) val i1_dot = i_dot + 1; val ln = n - i1_dot var !p_buf with pf_buf = @[byte][ln+1]() val () = strbuf_initialize_substring (pf_buf | p_buf, filename, i1_dot, ln) val () = strbuf_tolower (!p_buf) val dtopt = doctype_find (!p_buf) where { extern fun doctype_find {m,n:nat} (sfx: &strbuf (m, n)): Stropt = "doctype_find" } // end of [val] prval () = pf_buf := bytes_v_of_strbuf_v (pf_buf) in dtopt end else begin stropt_none end) : Stropt in if stropt_is_some dtopt then stropt_unsome dtopt else CONTENT_UNKNOWN end // end of [doctype_of_filename] (* ****** ****** *) local val msg404_str = "\ HTTP/1.0 404 not found\r\nServer: ATS/Vanilla\r\nContent-type: text/html\r\n

The requested resource cannot be found!

" val msg404_len = string1_length msg404_str in // in of [local] fun msg404_send {fd:int} (pf_conn: !socket_v (fd, conn) | socket_id: int fd): void = () where { val _(*n*) = socket_write_substring (pf_conn | socket_id, msg404_str, 0, msg404_len) } // end of [msg404_send] end // end of [local] (* ****** ****** *) %{^ static inline ats_lint_type size_of_filename(ats_ptr_type filename) { int res ; struct stat buf ; res = stat((char *)filename, &buf) ; if (res < 0) { perror ("stat") ; atspre_exit_prerrf(1, "Exit: [stat(%s)] failed.\n", filename) ; } return buf.st_size ; } %} extern fun size_of_filename (filename: string): lint = "size_of_filename" (* ****** ****** *) %{^ static inline ats_void_type sigpipe_ignore () { int err = sigignore(SIGPIPE) ; if (err < 0) { perror("sigignore") ; ats_exit_errmsg (1, "Exit: [sigpipe_ignore] failed.\n") ; } return ; } %} extern fun sigpipe_ignore (): void = "sigpipe_ignore" (* ****** ****** *) val dir_msg1_str = "HTTP/1.0 200 OK\nServer: ATS/Vanilla\nContent-type: text/html\n\n" val dir_msg1_len = string_length dir_msg1_str // val dir_msg2_str = "

\ A simple web server implemented in ATS\

" val dir_msg2_len = string_length dir_msg2_str // val dir_msg30_str = "
starting time: "
val dir_msg30_len = string_length dir_msg30_str

//

val dir_msg31_str = let
  #define THIRTYTWO 32
  val (pfgc, pfbuf | p_buf) = malloc_gc (THIRTYTWO)
  var ntick = time_get ()
  val p1 = ctime_r (pfbuf | ntick, p_buf) // reentrant function
  val () = assert_errmsg (p1 > null, #LOCATION)
  prval ctime_v_succ (pfbuf) = pfbuf
in
  string1_of_strbuf @(pfgc, pfbuf | p_buf)
end // end of [val]

val dir_msg31_len = string_length dir_msg31_str

//

val dir_msg32_str = "
" val dir_msg32_len = string_length dir_msg32_str // val dir_msg50_str = "
\n" val dir_msg50_len = string_length dir_msg50_str (* ****** ****** *) #define NMSG200 128 fn msg200_of_filename {l:addr} ( pf: !b0ytes NMSG200 @ l >> strbuf (NMSG200, n1) @ l | p: ptr l, filename: string ) : #[n1:nat | n1 < NMSG200][n2:nat] int n2 = let val sz = size_of_filename filename; val dt = doctype_of_filename filename in snprintf (pf | p, NMSG200 , "HTTP/1.0 200 OK\r\nServer: ATS/Vanilla\r\nContent-length: %li\r\nContent-type: %s\r\n\r\n" , @(sz, dt) ) // end of [snprintf] end // end of [msg200_of_filename] (* ****** ****** *) #define BUFSZ 1024 (* ****** ****** *) fn file_send_main {fd: int} ( pf_conn: !socket_v (fd, conn) | fd: int fd, file: &FILE r, filename: string ) : void = let // var !p_buf with pf_buf = @[byte][BUFSZ]() // uninitialized prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) var !p_msg with pf_msg = @[byte][NMSG200]() // uninitialized val msg200_str = msg200_of_filename (pf_msg | p_msg, filename) val msg200_len = strbuf_length (!p_msg) // fun loop (pf_conn: !socket_v (fd, conn), pf_buf: !bytes BUFSZ @ p_buf | fd: int fd, file: &FILE r) : void = let val n = fread_byte (file_mode_lte_r_r | !p_buf, BUFSZ, file) in if n > 0 then let val () = socket_write_all_exn (pf_conn | fd, !p_buf, n) in loop (pf_conn, pf_buf | fd, file) end // end of [if] end (* end of [loop] *) prval () = pf_msg := bytes_v_of_strbuf_v (pf_msg) val () = socket_write_all_exn (pf_conn | fd, !p_msg, msg200_len) in loop (pf_conn, pf_buf | fd, file) end // end of [file_send_main] (* ****** ****** *) extern fun file_send {fd: int} ( pf_conn: !socket_v (fd, conn) | fd: int fd, filename: string ) : void // end of [file_send] implement file_send (pf_conn | fd, filename) = let (* val () = begin prerr "file_send: filename = "; prerr filename; prerr_newline () end // end of [val] *) val [l_fil:addr] (pf_fil_opt | p_fil) = fopen_err (filename, file_mode_r) in if (p_fil > null) then let prval Some_v pf_fil = pf_fil_opt val () = file_send_main (pf_conn | fd, !p_fil, filename) in fclose_exn (pf_fil | p_fil) end else let prval None_v () = pf_fil_opt in msg404_send (pf_conn | fd) end // end of if end // end of [file_send] (* ****** ****** *) fn request_is_get {m,n:nat} (buf: &strbuf (m,n)): bool = strncmp (str, "GET ", 4) = 0 where { extern castfn __cast (p: ptr): string; val str = __cast (&buf) } // end of [request] (* ****** ****** *) %{^ ats_int_type filename_type (ats_ptr_type filename) { int res ; struct stat buf ; /* fprintf (stderr, "filename_type: filename = %s\n", filename) ; */ res = stat((char *)filename, &buf) ; if (res >= 0) { return (S_ISDIR(buf.st_mode)) ? 1 : 0 ; } else { return -1 ; } /* end of [if] */ } %} extern fun filename_type (filename: string): Sgn = "filename_type" (* ****** ****** *) extern fun filename_extract {m,n:nat} (msg: &strbuf (m,n) >> strbuf (m,n1), n: size_t n): #[n1:nat] Ptr = "filename_extract" %{^ ats_ptr_type filename_extract (ats_ptr_type msg, ats_size_type n) { size_t i = 5 ; char *s0 = (char*)msg + i; char *sa = s0 ; char *sb = s0 ; /* fprintf (stderr, "filename_extract: msg = %s\n", msg); */ while (i < n) { if (*sa == ' ') { *sb = '\000'; break ; } if (*sa == '%') { if (i + 2 < n) { sb[0] = (sa[1]-'0') * 16 + (sa[2]-'0') ; i += 3 ; sa += 3 ; sb += 1 ; continue ; } /* end of [if] */ } /* end of [if] */ ++i ; *sb = *sa ; ++sa ; ++sb ; } // end of [while] /* fprintf (stderr, "filename_extract: s0 = %s\n", s0); */ return (i > 5 ? s0 : (char*)0) ; } /* end of [filename_extract] */ %} (* ****** ****** *) (* dataview strbufopt_v (int, int, addr) = | {m,n:nat} strbufopt_v_none (m, n, null) of () | {m,n:nat} {l:addr | l <> null} strbufopt_v_some (m, n, l) of (free_gc_v (m, l), strbuf_v (m, n, l)) viewtypedef strbufoptptr_gc (m:int, n:int, l:addr) = @(strbufopt_v (m, n, l) | ptr l) *) extern fun dirent_name_get (dir: &DIR): Stropt_gc = "dirent_name_get" implement dirent_name_get (dir) = let val (pfopt | p_ent) = readdir (dir) in if p_ent > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_str | str) = dirent_get_d_name (!p_ent) val str1 = strptr_dup (str) prval () = fpf_str (str) prval () = fpf (pf) val strbuf = strbuf_of_strptr (str1) in stropt_gc_some (strbuf) end else let prval None_v () = pfopt in stropt_gc_none () end // end of [if] end // end of [dirent_name_get] (* ****** ****** *) viewtypedef Strlin = Strbufptr_gc (* ****** ****** *) viewtypedef entlst = List_vt (Strlin) viewtypedef entarrptr_gc (n: int, l:addr) = (free_gc_v (Strlin?, n, l), @[Strlin][n] @ l | ptr l) fun dirent_name_get_all (dir: &DIR, asz: &size_t 0? >> size_t n): #[n:nat][l:addr] entarrptr_gc (n, l) = let fun loop (dir: &DIR, res: entlst) : entlst = let val ent = dirent_name_get (dir) in if stropt_gc_is_none ent then let val _(*null*) = stropt_gc_unnone ent in res end else begin loop (dir, list_vt_cons (stropt_gc_unsome ent, res)) end // end of [if] end // end of [loop] val ents = loop (dir, list_vt_nil ()) stavar n: int val n: int n = list_vt_length ents val () = asz := size1_of_int1 (n) val [l:addr] (pfgc, pfarr | p_arr) = array_ptr_alloc (asz) val () = array_ptr_initialize_lst_vt (!p_arr, ents) val () = $STDLIB.qsort {Strlin} {n} (!p_arr, asz, sizeof, cmp) where { extern castfn __cast (x: !Strlin):<> string; val cmp = lam (x1: &Strlin, x2: &Strlin): Sgn = compare_string_string (__cast x1, __cast x2) } // end of [val] in #[n | #[l | (pfgc, pfarr | p_arr)]] end // end of [dirent_name_get_all] (* ****** ****** *) fun directory_send_loop {fd:int} {n:nat} {l:addr} .. ( pf_conn: !socket_v (fd, conn) , pfarr: ! @[Strlin][n] @ l >> @[Strlin?][n] @ l | fd: int fd, parent: string, p_arr: ptr l, asz: size_t n ) : void = let #define MSGSZ 1024; viewtypedef T = Strlin in if asz > 0 then let prval @(pf1_elt, pf2_arr) = array_v_uncons {T} (pfarr) val ent = !p_arr val ft = let val str = __cast ent where { extern castfn __cast (ent: !Strlin): string } // end of [val] in case+ str of | "." => 1 | ".." => 1 | _ => ft where { val str = string1_of_string (str) val parent = string1_of_string (parent) val fil = string1_append (parent, str) val (pfgc, pf_fil | p_fil) = fil val ft = filename_type (name) where { extern castfn __cast (p: ptr): string; val name = __cast p_fil } // end of [val] val () = strbufptr_free @(pfgc, pf_fil | p_fil) } // end of [_] end : Sgn (* end of [val] *) val () = case+ 0 of | _ when ft >= 0 => let var !p_msg with pf_msg = @[byte][MSGSZ](); stadef l_msg = p_msg val _(*n*) : int = let typedef mystrbuf = [n:nat | n < MSGSZ] strbuf (MSGSZ, n) extern castfn __cast (ent: !Strlin): string; val str = __cast ent in case+ :(pf_msg: mystrbuf @ l_msg) => ft of | 0 => snprintf ( pf_msg | p_msg, MSGSZ, "%s
", @(str, str) ) // end of [0] | _ (* 1 *) => snprintf ( // directory pf_msg | p_msg, MSGSZ, "%s/
", @(str, str) ) // end of [_] end // end of [val] val () = strbufptr_free (ent) val len = strbuf_length !p_msg prval () = pf_msg := bytes_v_of_strbuf_v (pf_msg) val _ = socket_write_all_exn (pf_conn | fd, !p_msg, len) in // empty end // end of [0] | _ => strbufptr_free (ent) // end of [val] val () = directory_send_loop (pf_conn, pf2_arr | fd, parent, p_arr+sizeof, asz-1) prval () = pfarr := array_v_cons {T?} (pf1_elt, pf2_arr) in // empty end else let prval () = array_v_unnil {T} (pfarr) prval () = pfarr := array_v_nil {T?} () in // empty end // end of [if] end (* end of [directory_send_loop] *) (* ****** ****** *) local val the_nrequest = ref_make_elt (0) in // in of [local] fn the_nrequest_get () = !the_nrequest fn the_nrequest_inc () = let val n = !the_nrequest in !the_nrequest := n + 1 end // end of [the_nrequest_inc] end // end of [local] (* ****** ****** *) extern fun directory_send {fd: int} (pf_conn: !socket_v (fd, conn) | fd: int fd, dirname: string): void implement directory_send {fd} (pf_conn | fd, dirname): void = let val (pf_dir_opt | p_dir) = opendir_err (dirname) prval () = ptr_is_gtez (p_dir) in if (p_dir = null) then let prval None_v () = pf_dir_opt in msg404_send (pf_conn | fd) end else let prval Some_v pf_dir = pf_dir_opt val _ = socket_write_substring (pf_conn | fd, dir_msg1_str, 0, dir_msg1_len) val _ = socket_write_substring (pf_conn | fd, dir_msg2_str, 0, dir_msg2_len) val _ = socket_write_substring (pf_conn | fd, dir_msg30_str, 0, dir_msg30_len) val _ = socket_write_substring (pf_conn | fd, dir_msg31_str, 0, dir_msg31_len) val _ = socket_write_substring (pf_conn | fd, dir_msg32_str, 0, dir_msg32_len) // #define MSGSZ 64 var !p_msg with pf_msg = @[byte][MSGSZ]() val _(*int*) = snprintf ( pf_msg | p_msg, MSGSZ, "The number of requests handled: %i\n", @(n) ) where { val n = the_nrequest_get () } // end of [val] val len = strbuf_length (!p_msg) prval () = pf_msg := bytes_v_of_strbuf_v (pf_msg) val _ = socket_write_all_exn (pf_conn | fd, !p_msg, len) // val _ = socket_write_substring (pf_conn | fd, dir_msg50_str, 0, dir_msg50_len) var asz: size_t 0? // unintialized val (pfgc, pfarr | p_arr) = dirent_name_get_all (!p_dir, asz) val () = closedir_exn (pf_dir | p_dir) val () = directory_send_loop (pf_conn, pfarr | fd, dirname, p_arr, asz) in array_ptr_free {Strlin?} (pfgc, pfarr | p_arr) end // end of [if] end (* end of [directory_send] *) (* ****** ****** *) #define CWD_PROTECT 1 extern fun main_loop_get {fd:int} {m,n:nat} {l_buf:addr} ( pf_conn: !socket_v (fd, conn), pf_buf: !bytes BUFSZ @ l_buf | fd: int fd, buf: ptr l_buf, msg: &strbuf (m,n) >> strbuf (m, n1), n: size_t n ) : #[n1:nat] void implement main_loop_get {fd} {m,n} (pf_conn, pf_buf | fd, buf, msg, n) = let (* val () = begin prerr "main_loop_get: msg = "; prerr msg; prerr_newline () end where { val msg = __cast (&msg) where { extern castfn __cast (p: Ptr): string } } (* end of [val] *) *) val ptr = filename_extract (msg, n); val () = if ptr <> null then let val name = __filename_extract (ptr) where { extern castfn __filename_extract (ptr: ptr): string } // end of [val] val ft = filename_type name in case+ ft of | 0 => file_send (pf_conn | fd, name) | 1 => directory_send (pf_conn | fd, name) | _ => msg404_send (pf_conn | fd) end else let #ifdef CWD_PROTECT #then // the current directory is protected: val () = msg404_send (pf_conn | fd) #else // the current directory is not protected: val () = directory_send (pf_conn | fd, "./") // list the entries of #endif // end of [#if CWD_PROTECT] in // nothing end // end of [if] // end of [val] in // empty end // end of [main_loop_get] (* ****** ****** *) extern fun main_loop {fd:int} {l_buf:addr} ( pf_fd: socket_v (fd, listen), pf_buf: !bytes BUFSZ @ l_buf | fd: int fd, p_buf: ptr l_buf ) : void // end of [extern] implement main_loop (pf_list, pf_buf | sfd, p_buf): void = let val (pf_accept | cfd) = accept_null_err (pf_list | sfd) in if cfd >= 0 then let val () = the_nrequest_inc () prval Some_v (pf_conn) = pf_accept val pid = fork_exn (); val ipid = int_of_pid (pid) in case+ 0 of | _ when ipid > 0 (* parent *) => let (* val () = (prerr "parent: ipid = "; prerr ipid; prerr_newline ()) *) val () = socket_close_exn (pf_conn | cfd) var status: int // uninitialized val _(*pid*) = waitpid (pid, status, WNONE) in main_loop (pf_list, pf_buf | sfd, p_buf) end // end of [_ when ...] | _ (* child: ipid = 0 *) => exit (0) where { (* val () = (prerr "child: ipid = "; prerr ipid; prerr_newline ()) *) val () = socket_close_exn (pf_list | sfd) val n = socket_read_exn (pf_conn | cfd, !p_buf, BUFSZ) var !p_msg with pf_msg = @[byte][n+1]() prval () = pf_msg := bytes_v_of_b0ytes_v pf_msg val _(*p_msg*) = memcpy (pf_msg | p_msg, !p_buf, n) val () = bytes_strbuf_trans (pf_msg | p_msg, n) val () = case+ 0 of | _ when request_is_get (!p_msg) => let val n = strbuf_length (!p_msg) val () = main_loop_get (pf_conn, pf_buf | cfd, p_buf, !p_msg, n) prval () = pf_msg := bytes_v_of_strbuf_v (pf_msg) in socket_close_exn (pf_conn | cfd) end // end of [_ when ...] | _ => let (* val () = prerr "main_loop: unsupported request: " val () = prerr_string (__cast p_msg) where { extern castfn __cast (p: ptr): string } val () = prerr_newline () *) prval () = pf_msg := bytes_v_of_strbuf_v (pf_msg) in socket_close_exn (pf_conn | cfd) end // end of [val] } (* end of [_] *) // end of [case] end else let prval None_v () = pf_accept val () = (prerr "Error: [accept] failed!"; prerr_newline ()) in main_loop (pf_list, pf_buf | sfd, p_buf) end // end of [if] end (* end of [main_loop] *) (* ****** ****** *) #define BACKLOG 5 // a more or less hitorically arbitrarily value (* ****** ****** *) dynload "libc/sys/DATS/socket.dats" (* ****** ****** *) implement main (argc, argv) = let val port = (if argc > 1 then int1_of (argv.[1]) else 8080): Int val () = assert_prerrf_bool1 (port >= 1024, "The given port <%i> is not supported.\n", @(port)) val (pf_sock | fd) = socket_family_type_exn (AF_INET, SOCK_STREAM) var servaddr: sockaddr_in_struct // uninitialized val servport = in_port_nbo_of_int (port) val in4add_any = in_addr_nbo_of_hbo (INADDR_ANY) val () = sockaddr_in_init (servaddr, AF_INET, in4add_any, servport) val () = bind_in_exn (pf_sock | fd, servaddr) val () = listen_exn (pf_sock | fd, BACKLOG) var !p_buf with pf_buf = @[byte][BUFSZ]() prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val () = sigpipe_ignore () // prevent server crash due to broken pipe in main_loop (pf_sock, pf_buf | fd, p_buf) end // end of [main] (* ****** ****** *) (* end of [server2.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/HttpServer/server.dats0000664000175000017500000005100312223166161022657 0ustar hwxihwxi// A simple web server implemented in ATS // // This is a simple example demonstrating some use of views in // socket programming. The code is largely based on an earlier // version by Rui Shi (shearer AT cs DOT bu DOT edu) // // Note that this is not really a robust implmentation as there // are clearly memory leaks! // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // June 2007: %{^ #include #include %} // end of [%{^] // staload "libc/SATS/dirent.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" staload "libc/sys/SATS/sockaddr.sats" staload "libc/sys/SATS/socket.sats" staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket_in.sats" staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" // #define BUFSZ 1024 #define BACKLOG 5 // #define HTTP_OK "200" #define HTTP_CREATED "201" #define HTTP_ACCEPTED "202" #define HTTP_NOT_AUTHORITATIVE "203" #define HTTP_NO_CONTENT "204" #define HTTP_RESET "205" #define HTTP_PARTIAL "206" #define HTTP_MULT_CHOICE "300" #define HTTP_MOVED_PERM "301" #define HTTP_MOVED_TEMP "302" #define HTTP_SEE_OTHER "303" #define HTTP_NOT_MODIFIED "304" #define HTTP_USE_PROXY "305" #define HTTP_BAD_REQUEST "400" #define HTTP_UNAUTHORIZED "401" #define HTTP_PAYMENT_REQUIRED "402" #define HTTP_FORBIDDEN "403" #define HTTP_NOT_FOUND "404" #define HTTP_BAD_METHOD "405" #define HTTP_NOT_ACCEPTABLE "406" #define HTTP_PROXY_AUTH "407" #define HTTP_CLIENT_TIMEOUT "408" #define HTTP_CONFLICT "409" #define HTTP_GONE "410" #define HTTP_LENGTH_REQUIRED "411" #define HTTP_PRECON_FAILED "412" #define HTTP_ENTITY_TOO_LARGE "413" #define HTTP_REQ_TOO_LONG "414" #define HTTP_UNSUPPORTED_TYPE "415" // local typedef string2 = @(string, string) val (pfgc, pfarr | ptr, len) = $arrpsz{string2}( ("ats", "text/plain") , ("au", "audio/basic") , ("c", "text/plain") , ("c++", "text/plain") , ("cats", "text/plain") , ("cc", "text/plain") , ("dats", "text/plain") , ("exe", "application/octet-stream") , ("gif", "image/gif") , ("h", "text/plain") , ("hats", "text/plain") , ("htm", "text/html") , ("html", "text/html") , ("java", "text/plain") , ("jpeg", "image/jpeg") , ("jpg", "image/jpeg") , ("ml", "text/plain") , ("pl", "text/plain") , ("ps", "application/postscript") , ("sats", "text/plain") , ("sh", "application/x-shar") , ("sml", "text/plain") , ("snd", "audio/basic") , ("tar", "application/x-tar") , ("text", "text/plain") , ("txt", "text/plain") , ("uu", "application/octet-stream") , ("wav", "audio/x-wav") , ("zip", "application/zip") ) // end of [val] in stavar len: int // prval () = free_gc_elim {string2?} (pfgc) // val ( the_doctype_map_prop | () ) = vbox_make_view_ptr (pfarr | ptr) val the_doctype_map_ptr = ptr val the_doctype_map_len: int len = int1_of_size1 (len) end // end of [local] // val () = let // make sure that [doctype_map] is ordered fun aux_check_loop {n,i:nat | i <= n} {l:addr} .. (pf: !array_v (@(string, string), n, l) | A: ptr l, n: int n, i: int i, sfx0: string):<> void = if i < n then let val sfx1 = !A.[i].0 in if sfx0 < sfx1 then aux_check_loop (pf | A, n, i+1, sfx1) else begin $effmask_all (exit_prerrf {void} (1, "Internal Error: the doctype map is not ordered: %s !< %s\n", @(sfx0, sfx1)) ) end // end of [$effmask_all] end // end of [if] fn aux_check {n:nat} {l:addr} (pf: !array_v ((string, string), n, l) | A: ptr l, n: int n):<> void = if n >= 2 then let val sfx = !A.[0].0 in aux_check_loop (pf | A, n, 1, sfx) end else () prval vbox pf = the_doctype_map_prop in aux_check (pf | the_doctype_map_ptr, the_doctype_map_len) end // end of let // extern fun doctype_find (sfx: string): Stropt // end of [doctype_find] implement doctype_find (sfx) = let (* val () = printf ("doctype_find: sfx = %s\n", @(sfx)) *) fun loop {i,j,n:int | 0 <= i; i <= j+1; j+1 <= n} {l:addr} .. ( pf: !array_v ((string, string), n, l) | A: ptr l, i: int i, j: int j ) : Stropt = if i <= j then let val m = i + (j - i) / 2 ; val key = !A.[m].0 (* val () = printf ("doctype_find: key = %s\n", @(key)) *) in case+ compare (key, sfx) of | 1 => loop (pf | A, i, m-1) | ~1 => loop (pf | A, m+1, j) | _ (* 0 *) => stropt_some (string1_of_string !A.[m].1) end else begin stropt_none // = null pointer end prval vbox pf = the_doctype_map_prop in loop {0,len-1,len} ( pf | the_doctype_map_ptr, 0, the_doctype_map_len - 1 ) // end of [loop] end // end of [doctype_find] // extern fun suffix_of_filename (filename: string): Stropt // end of [suffix_of_filename] implement suffix_of_filename filename = let val filename = string1_of_string filename val i = string_index_of_char_from_right (filename, '.') in if i >= 0 then let val n = string_length filename val i1 = size1_of_ssize1 (i) + 1 val sbp = string_make_substring (filename, i1, n-i1) val str = string1_of_strbuf (sbp) in stropt_some (str) end else begin stropt_none // = null pointer end // end of [if] end // end of [suffix_of_filename] (* ****** ****** *) extern fun filename_extract {n:nat} (msg: string n, n: size_t n): Stropt = "filename_extract" // end of [filename_extract] %{$ ats_ptr_type filename_extract ( ats_ptr_type msg, ats_size_type n ) { size_t i = 5 ; char *s = (char *)msg + i; /* fprintf (stdout, "filename_extract: msg = %s\n", msg); */ while (i < n) { if (*((char *)s) == ' ') break ; ++i ; ++s ; } /* fprintf (stdout, "filename_extract: s = %s\n", s); */ if (i > 5) { return atspre_string_make_substring (msg, 5, i-5) ; } else { return (char *)0 ; } } // end of [filename_extract] %} // end of [%{$] // extern fun doctype_of_filename (filename: string): string // end of [doctype_of_filename] implement doctype_of_filename (filename: string) = let val sfx_opt = suffix_of_filename filename val dt_opt = (if stropt_is_none sfx_opt then stropt_some "text/plain" // the doctype for files without suffix else let val sfx = stropt_unsome sfx_opt val sfx = string_tolower (sfx) val sfx = string1_of_strbuf (sfx) in doctype_find sfx end) : Stropt in if stropt_is_none dt_opt then "content/unknown" else stropt_unsome dt_opt end // end of [doctype_of_filename] (* ****** ****** *) extern fun socket_write_all {fd:int} {n,sz:nat | n <= sz} ( pf_socket: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, n: size_t n ) : void = "socket_write_all" extern fun socket_write_substring_all {fd:int} {i,n,sz:nat | i+n <= sz} ( pf_socket: !socket_v (fd, conn) | socket_id: int fd, s: string sz, start: size_t i, n: size_t n ) : void = "socket_write_substring_all" // end of [socket_write_substring_all] (* ****** ****** *) %{^ ATSinline() ats_void_type socket_write_all ( ats_int_type fd, ats_ref_type buf, ats_size_type cnt ) { ssize_t res ; while (cnt) { res = write(fd, buf, cnt) ; if (res < 0) { if (errno == EINTR) continue ; else return ; } if (res == 0) return ; buf = ((char*)buf) + res ; cnt = cnt - res ; } return ; } // end of [socket_write_all] ATSinline() ats_void_type socket_write_substring_all ( ats_int_type fd, ats_ptr_type buf, ats_size_type start, ats_size_type cnt ) { socket_write_all(fd, ((char*)buf)+start, cnt) ; return ; } // end of [socket_write_substring_all] %} // end of [%{^] (* ****** ****** *) val msg404_str = "\ HTTP/1.0 404 not found\r\nServer: ATS/Vanilla\r\nContent-type: text/html\r\n

The requested resource cannot be found!

" val msg404_len = string_length msg404_str fun msg404_send {fd:int} (pf_conn: !socket_v (fd, conn) | socket_id: int fd): void = socket_write_substring_all (pf_conn | socket_id, msg404_str, 0, msg404_len) (* ****** ****** *) extern fun size_of_filename (filename: string): lint = "size_of_filename" // end of [size_of_filename] %{^ ATSinline() ats_lint_type size_of_filename ( ats_ptr_type filename ) { int res ; struct stat buf ; res = stat((char *)filename, &buf) ; if (res < 0) { perror ("stat") ; atspre_exit_prerrf(1, "Exit: [stat(%s)] failed.\n", filename) ; } // end of [if] return buf.st_size ; } // end of [size_of_filename] %} // end of [%{^] fun msg200_of_filename (filename: string): string = let // val sz = size_of_filename filename val dt = doctype_of_filename filename // in // string_of_strptr (sprintf ( "HTTP/1.0 200 OK\r\nServer: ATS/Vanilla\r\nContent-length: %li\r\nContent-type: %s\r\n\r\n", @(sz, dt) ) // end of [sprintf] ) // end of [string_of_strptr] // end // end of [msg200_of_filename] (* ****** ****** *) fun file_send_main {fd: int} ( pf_conn: !socket_v (fd, conn) | fd: int fd, file: &FILE r, filename: string ) : void = let // val [l_buf:addr] (pfopt | p_buf) = malloc_ngc (BUFSZ) val () = assert_errmsg (p_buf > null, #LOCATION) prval malloc_v_succ (pf_ngc, pf_buf) = pfopt prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val msg200_str = msg200_of_filename filename val msg200_str = string1_of_string msg200_str val msg200_len = string1_length msg200_str // fun aux (pf_conn: !socket_v (fd, conn), pf_buf: !bytes BUFSZ @ l_buf | fd: int fd, file: &FILE r) : void = let val n = fread_byte (file_mode_lte_r_r | !p_buf, BUFSZ, file) in if n > 0 then begin socket_write_all (pf_conn | fd, !p_buf, n); aux (pf_conn, pf_buf | fd, file) end end // end of [aux] // in // socket_write_substring_all (pf_conn | fd, msg200_str, 0, msg200_len); aux (pf_conn, pf_buf | fd, file); free_ngc (pf_ngc, pf_buf | p_buf); // end // end of [file_send_main] (* ****** ****** *) extern fun file_send {fd: int} (pf_conn: !socket_v (fd, conn) | fd: int fd, filename: string): void // end of [file_send] implement file_send (pf_conn | fd, filename) = let val [l_file:addr] (pf_file_opt | file) = fopen_err (filename, file_mode_r) in // if (file > null) then let prval Some_v pf_file = pf_file_opt in file_send_main (pf_conn | fd, !file, filename); fclose_exn (pf_file | file) end else let prval None_v () = pf_file_opt in msg404_send (pf_conn | fd) end // end of [if] // end // end of [file_send] (* ****** ****** *) val dir_msg1_str = "HTTP/1.0 200 OK\nServer: ATS/Vanilla\nContent-type: text/html\n\n" val dir_msg1_len = string_length dir_msg1_str val dir_msg2_str = "

\ A simple web server implemented in ATS\

" val dir_msg2_len = string_length dir_msg2_str (* ****** ****** *) extern fun ctime_get (): String = "server_ctime_get" %{^ static ats_ptr_type server_ctime_get (void) { time_t t ; char c, *buf, *p; buf = ats_malloc_gc (32) ; time (&t) ; ctime_r (&t, buf) ; p = buf ; while (c = *p) { if (c == '\n') { *p = '\0' ; break ; } ++p ; } return buf ; } // end of [server_ctime_get] %} (* ****** ****** *) val dir_msg30_str = "
starting time: "
val dir_msg30_len = string_length dir_msg30_str
val dir_msg31_str = ctime_get ()
val dir_msg31_len = string_length dir_msg31_str
val dir_msg32_str = "
" val dir_msg32_len = string_length dir_msg32_str (* ****** ****** *) (* dataviewtype entlst = entlst_nil | entlst_cons of (String, entlst) fun entlst_append ( xs0: &entlst >> entlst, ys: entlst ) : void = case+ xs0 of | entlst_cons (x, !xs) => (entlst_append (!xs, ys); fold@ xs0) | ~entlst_nil () => (xs0 := ys) // end of [entlst_append] fun qsort (xs: entlst): entlst = case+ xs of | entlst_cons (!p_x1, !p_xs1) => let val x1 = !p_x1 and xs1 = !p_xs1 in part ( view@ (!p_x1), view@ (!p_xs1) | xs, x1, p_xs1, xs1, entlst_nil (), entlst_nil () ) end // end of [entlst_cons] | entlst_nil () => (fold@ xs; xs) // end of [qsort] and part {l0,l1:addr} ( pf0: String @ l0, pf1: entlst? @ l1 | node: entlst_cons_unfold (l0, l1) , x0: String, p_xs0: ptr l1, xs: entlst, l: entlst, r: entlst ) : entlst = case+ xs of | entlst_cons (x1, !p_xs1) => let val xs1 = !p_xs1 in if compare (x1, x0) <= 0 then (!p_xs1 := l; fold@ xs; part (pf0, pf1 | node, x0, p_xs0, xs1, xs, r)) else (!p_xs1 := r; fold@ xs; part (pf0, pf1 | node, x0, p_xs0, xs1, l, xs)) // end of [if] end // end of [entlst_cons] | ~entlst_nil () => let var l = qsort l and r = qsort r in !p_xs0 := r; fold@ node; r := node; entlst_append (l, r); l end // end of [entlst_nil] // end of [part] *) %{$ ats_ptr_type dirent_get_name(ats_ptr_type dir) { struct dirent *ent ; ent = readdir((DIR*)dir) ; if (ent) { return atspre_string_make_substring (ent->d_name, 0, strlen(ent->d_name)) ; } else { return (char*)0 ; } } /* end of [dirent_get_name_get] */ %} // end of [%{$] fun dirent_name_get (dir: &DIR): Stropt = let val (pfopt | p_ent) = readdir (dir) in if p_ent > null then let prval Some_v @(pf, fpf) = pfopt val (fpf_str | str) = dirent_get_d_name (!p_ent) val str1 = strptr_dup (str) prval () = fpf_str (str) prval () = fpf (pf) val str1 = string1_of_strptr (str1) in stropt_some (str1) end else let prval None_v () = pfopt in stropt_none end // end of [if] end // end of [dirent_name_get] viewtypedef entlst = List_vt (String) #define entlst_nil list_vt_nil; #define entlst_cons list_vt_cons fun dirent_name_get_all (dir: &DIR): entlst = let fun aux (dir: &DIR, res: entlst): entlst = let val ent = dirent_name_get (dir) in if stropt_is_none ent then res else aux (dir, entlst_cons (stropt_unsome ent, res)) // end of [if] end // end of [let] // end of [aux] val ents = aux (dir, entlst_nil ()) val () = list_vt_quicksort (ents, cmp) where { fn cmp (x1: &String, x2: &String): Sgn = compare (x1, x2) } // end of [list_vt_quicksort] in ents end // end of [dirent_name_get_all] extern fun filename_type (filename: string): int = "filename_type" %{^ ats_int_type filename_type(ats_ptr_type filename) { int res ; struct stat buf ; /* fprintf (stdout, "filename_type: filename = %s\n", filename) ; */ res = stat((char *)filename, &buf) ; if (res >= 0) { return (S_ISDIR(buf.st_mode)) ? 1 : 0 ; } else { return -1 ; } } %} extern fun directory_send_loop {fd:int} ( pf_conn: !socket_v (fd, conn) | fd: int fd, parent: String, ents: entlst ) : void // end of [directory_send_loop] implement directory_send_loop ( pf_conn | fd, parent, ents ) = case+ ents of | ~entlst_cons (ent, ents) => let (* val () = printf ("directory_send_loop: parent = %s\n", @(parent)) val () = printf ("directory_send_loop: ent = %s\n", @(ent)) *) val ft = case ent of | "." => 1 | ".." => 1 | _ => let val name = string1_of_strbuf (parent + ent) in filename_type name end // end of [_] in case+ ft of | 0 => let val msg = sprintf ("%s
", @(ent, ent)) val msg = string1_of_strptr (msg) val len = string_length (msg) in socket_write_substring_all (pf_conn | fd, msg, 0, len); directory_send_loop (pf_conn | fd, parent, ents) end | 1 => let val msg = tostringf ("%s/
", @(ent, ent)) val msg = string1_of_strptr (msg) in socket_write_substring_all (pf_conn | fd, msg, 0, string_length msg); directory_send_loop (pf_conn | fd, parent, ents) end | _ => directory_send_loop (pf_conn | fd, parent, ents) end // end of [cons] | ~entlst_nil () => () // end of [directory_send_loop] (* ****** ****** *) extern fun directory_send {fd: int} (pf_conn: !socket_v (fd, conn) | fd: int fd, dirname: string): void // end of [directory_send] implement directory_send {fd} (pf_conn | fd, dirname): void = let val (pf_dir_opt | p_dir) = opendir_err(dirname) prval () = ptr_is_gtez (p_dir) in if (p_dir = null) then let prval None_v () = pf_dir_opt in msg404_send (pf_conn | fd) end else let prval Some_v pf_dir = pf_dir_opt val () = socket_write_substring_all (pf_conn | fd, dir_msg1_str, 0, dir_msg1_len) val () = socket_write_substring_all (pf_conn | fd, dir_msg2_str, 0, dir_msg2_len) val () = socket_write_substring_all (pf_conn | fd, dir_msg30_str, 0, dir_msg30_len) val () = socket_write_substring_all (pf_conn | fd, dir_msg31_str, 0, dir_msg31_len) val () = socket_write_substring_all (pf_conn | fd, dir_msg32_str, 0, dir_msg32_len) val dirname = string1_of_string dirname val ents = dirent_name_get_all (!p_dir) val () = closedir_exn (pf_dir | p_dir) in directory_send_loop (pf_conn | fd, dirname, ents) end (* end of [if] *) end // end of [directory_send] (* ****** ****** *) fun request_is_get {n:nat} (s: string n): bool = if string_is_atend (s, 0) then false else if s[0] <> 'G' then false else if string_is_atend (s, 1) then false else if s[1] <> 'E' then false else if string_is_atend (s, 2) then false else if s[2] <> 'T' then false else if string_is_atend (s, 3) then false else if s[3] <> ' ' then false else true // end of [request_is_get] (* ****** ****** *) extern fun main_loop_get {fd:int} {n:nat} {l_buf:addr} ( pf_conn: socket_v (fd, conn) , pf_buf: !bytes BUFSZ @ l_buf | fd: int fd, buf: ptr l_buf, msg: string n, n: size_t n ) : void // end of [main_loop_get] implement main_loop_get (pf_conn, pf_buf | fd, buf, msg, n) = let (* val () = printf ("main_loop_get: msg = %s\n", @(msg)) *) val name_opt = filename_extract (msg, n) val () = if stropt_is_none name_opt then directory_send (pf_conn | fd, "./") else let val name = stropt_unsome name_opt val ft = filename_type name in case+ ft of | 0 => file_send (pf_conn | fd, name) | 1 => directory_send (pf_conn | fd, name) | _ => msg404_send (pf_conn | fd) end // end of [if] in socket_close_exn (pf_conn | fd) end // end of [main_loop_get] (* ****** ****** *) extern fun main_loop {fd:int} {l_buf:addr} (pf_list: !socket_v (fd, listen), pf_buf: !bytes BUFSZ @ l_buf | fd: int fd, p_buf: ptr l_buf): void extern fun strbuf_make_bytes {n:nat} {st,ln:nat | st + ln <= n} (buf: &bytes n, st: size_t st, ln: size_t ln) :<> [l:addr] (freebyte_gc_v (ln+1, l), strbuf (ln+1,ln) @ l | ptr l) = "atspre_string_make_substring" implement main_loop (pf_list, pf_buf | sfd, p_buf): void = let val (pf_accept | cfd) = accept_null_err(pf_list | sfd) in if cfd >= 0 then let prval Some_v (pf_conn) = pf_accept val n = socket_read_exn (pf_conn | cfd, !p_buf, BUFSZ) val (pf_gc, pf_sb | p) = strbuf_make_bytes (!p_buf, 0, n) val msg = string1_of_strbuf @(pf_gc, pf_sb | p) in case+ msg of // [msg] is leaked out if not reclaimed!!! | _ when request_is_get (msg) => begin main_loop_get (pf_conn, pf_buf | cfd, p_buf, msg, n); main_loop (pf_list, pf_buf | sfd, p_buf) end // end of [_ when ...] | _ => begin socket_close_exn (pf_conn | cfd); prerrf ("main_loop: unsupported request: %s\n", @(msg)); main_loop (pf_list, pf_buf | sfd, p_buf) end // end of [_] end else let prval None_v () = pf_accept val () = prerr "Error: [accept] failed!\n" in main_loop (pf_list, pf_buf | sfd, p_buf) end // end of [if] end (* end of [main_loop] *) (* ****** ****** *) extern fun sigpipe_ignore (): void = "sigpipe_ignore" %{^ ATSinline() ats_void_type sigpipe_ignore () { int err = sigignore(SIGPIPE) ; if (err < 0) { perror("sigignore") ; ats_exit_errmsg (1, "Exit: [sigpipe_ignore] failed.\n") ; } return ; } // end of [sigpipe_ignore] %} // end of [%{^] (* ****** ****** *) dynload "libc/sys/DATS/socket.dats" implement main (argc, argv) = let val port = (if argc > 1 then int1_of (argv.[1]) else 8080): Int val () = assert_prerrf_bool1 (port >= 1024, "The given port <%i> is not supported.\n", @(port)) val (pf_sock | fd) = socket_family_type_exn (AF_INET, SOCK_STREAM) var servaddr: sockaddr_in_struct // uninitialized val servport = in_port_nbo_of_int (port) val in4add_any = in_addr_nbo_of_hbo (INADDR_ANY) val () = sockaddr_in_init (servaddr, AF_INET, in4add_any, servport) val () = bind_in_exn (pf_sock | fd, servaddr) val () = listen_exn (pf_sock | fd, BACKLOG) val (pfopt | p_buf) = malloc_ngc (BUFSZ) val () = assert_errmsg (p_buf > null, #LOCATION) prval malloc_v_succ (pf_ngc, pf_buf) = pfopt val () = sigpipe_ignore () // prevent server crash due to broken pipe prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) val () = main_loop(pf_sock, pf_buf | fd, p_buf) val () = socket_close_exn (pf_sock | fd) val () = free_ngc (pf_ngc, pf_buf | p_buf) in // empty end // end of [main] (* ****** ****** *) (* end of [server.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/queens_appel.dats0000664000175000017500000000450512223166161021731 0ustar hwxihwxi(* ** This example is taken from Appel's book: ** Modern Compiler Design and Implementation in ML *) (* A program to solve the 8-queens problem *) (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) #define N 8 #define N1 (N - 1) (* ****** ****** *) var NSOL: Nat = 0 val (pfbox_NSOL | ()) = vbox_make_view_ptr {Nat} (view@ NSOL | &NSOL) // end of [val] (* ****** ****** *) val row = array_make_elt (N, 0) val col = array_make_elt (N, 0) val diag1 = array_make_elt (size1_of_int1 N+N1, 0) val diag2 = array_make_elt (size1_of_int1 N+N1, 0) (* ****** ****** *) %{^ #include // for efficiency ats_void_type print_string (ats_ptr_type s) { fputs ((char*)s, stdout) ; return ; } %} // end of [%{^] extern fun print_string (str: string): void = "print_string" fn printboard (): void = let var i: natLte N and j: natLte N val () = for* (j: int?) => (i := 0; i < N; i := i + 1) let val () = for* (i: natLt N) => (j := 0; j < N; j := j + 1) begin print_string (if :(j: natLt N) => (col[i] = j) then " Q" else " .") end // end of [val] in print_string ("\n") end // end of [for] val () = print_string ("\n") in // empty end (* end of [printboard] *) (* ****** ****** *) fun _try (c: natLte N): void = if (c = N) then let val () = let prval vbox pf = pfbox_NSOL in NSOL := NSOL + 1 end // end of [val] in printboard () end else let var r: natLte N // unitialized val () = for (r := 0; r < N; r := r+1) ( if :(r: natLt N) => (row[r] = 0) then begin if :(r: natLt N) => (diag1[r+c] = 0) then begin if :(r: natLt N) => (diag2[r+N1-c] = 0) then begin row[r] := 1; diag1[r+c] := 1; diag2[r+N1-c] := 1; col[c] := r; _try (c+1); row[r] := 0; diag1[r+c] := 0; diag2[r+N1-c] := 0; end (* end of [if] *) end (* end of [if] *) end (* end of [if] *) ) // end of [val] in // empty end // end of [if] // end of [_try] (* ****** ****** *) implement main () = let val () = _try (0) val n = NSOL where { prval vbox pf = pfbox_NSOL } in printf ("The total number of solutions is [%i].\n",@(n)) end // end of [main] (* ****** ****** *) (* end of [queens_appel.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Makefile0000664000175000017500000002431612223166161020035 0ustar hwxihwxi###### # # A variety of examples involving dependent and/or linear types # ###### ATSUSRQ="$(ATSHOME)" ifeq ($(ATSUSRQ),"") ATSUSRQ="/usr" endif ###### ATSCC=$(ATSUSRQ)/bin/atscc ATSOPT=$(ATSUSRQ)/bin/atsopt ###### .PHONY: all all:: checkall all:: cleanall ###### checkall:: cleanall:: clean cleanall:: ; $(RMF) ./XREF/* cleanall:: ; $(RMF) *_?ats.html ###### html:: ###### # # automatic differentiation # checkall:: AutoDiff AutoDiff: AutoDiff.dats # $(ATSCC) -D_ATS_gc -O3 -o $@ $< -lm # $(ATSCC) -D_ATS_gcats -O3 -o $@ $< -lm $(ATSCC) -D_ATS_GCATS -O3 -o $@ $< -lm cleanall:: ; $(RMF) AutoDiff # # BlackScholes formula # checkall:: BlackScholes BlackScholes: BlackScholes.dats; $(ATSCC) -tc $< cleanall:: ; $(RMF) BlackScholes # # random number generation # checkall:: coin_flip coin_flip: coin_flip.dats; $(ATSCC) -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) coin_flip # # an interesting curve # checkall:: curve curve: curve.dats; $(ATSCC) -o $@ $< -lm # && ./curve cleanall:: ; $(RMF) curve # # test for Mersenne primes # checkall:: fft fft: fft.dats; $(ATSCC) -O3 -o fft fft.dats -lm cleanall:: ; $(RMF) fft # # Garsia-Wachs # checkall:: GarsiaWachs GarsiaWachs: GarsiaWachs.dats $(ATSCC) -D_ATS_GCATS -O3 -o $@ $< && ./$@ cleanall:: ; $(RMF) GarsiaWachs # # gaussian elimination # checkall:: GaussElim GaussElim: GaussElim.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) GaussElim # # a multithreaded implementation of GCD # checkall:: gcd_mt gcd_mt: gcd_mt.dats $(ATSCC) -D_ATS_MULTITHREAD -O2 -o $@ $< -lpthread -lats_mt \ && ./gcd_mt 12345 67890 cleanall:: ; $(RMF) gcd_mt # # hamming in lazy style # checkall:: hamming_lazy hamming_lazy: hamming_lazy.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) hamming_lazy # # hanoi tower # checkall:: hanoi hanoi: hanoi.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) hanoi # # integer square root # checkall:: isqrt isqrt: isqrt.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) isqrt # # Knuth-Morris-Pratt string search # checkall:: kmp kmp: kmp.dats; $(ATSCC) -o kmp kmp.dats && ./kmp cleanall:: ; $(RMF) kmp # # Monte Carlo method # checkall:: montecarlo montecarlo: montecarlo.dats $(ATSCC) -O2 -o $@ $< -lm -lats_smlbas && ./$@ cleanall:: ; $(RMF) montecarlo # # mycat # checkall:: mycat mycat: mycat.dats ; $(ATSCC) -O2 -o $@ $< && ./$@ -A mycat.dats cleanall:: ; $(RMF) mycat # # An example of linear lazy evaluation # checkall:: longestline longestline: longestline.dats $(ATSCC) -o $@ $< && ./$@ < ./longestline.dats cleanall:: ; $(RMF) longestline # # # checkall:: myfind myfind: myfind.dats ; $(ATSCC) -o $@ $< cleanall:: ; $(RMF) myfind # # generating a password randomly # checkall:: passwdgen passwdgen: passwdgen.dats $(ATSCC) -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) passwdgen # # implementing natural numbers in ATS # checkall:: Peano Peano: Peano.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) Peano # # generate lexicographically ordered permutations # checkall:: permute permute: permute.dats; $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) permute checkall:: permute_vt permute_vt: permute_vt.dats; $(ATSCC) -D_ATS_GCATS -O2 -o $@ $< && ./$@ cleanall:: ; $(RMF) permute_vt # # Euler's transform in lazy style # checkall:: pi_lazy pi_lazy: pi_lazy.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) pi_lazy # # Verified quicksort implementations # checkall:: quicksort_list quicksort_list: quicksort_list.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) quicksort_list checkall:: quicksort1_list quicksort1_list: quicksort1_list.dats $(ATSCC) -D_ATS_PROOFCHECK -o $@ $< && ./$@ cleanall:: ; $(RMF) quicksort1_list checkall:: quicksort2_list quicksort2_list: quicksort2_list.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) quicksort2_list # # the n-queen problem # checkall:: queens queens: queens.dats; $(ATSCC) -o $@ $< && ./$@ 4 > /dev/null cleanall:: ; $(RMF) queens checkall:: queens_appel queens_appel: queens_appel.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) queens_appel checkall:: queens_lazy_vt queens_lazy_vt: queens_lazy_vt.dats; $(ATSCC) -D_ATS_GCATS -O3 -o $@ $< && ./$@ cleanall:: ; $(RMF) queens_lazy_vt # # Erathosthene's sieve # checkall:: sieve sieve: sieve.dats; $(ATSCC) -o $@ $< # && ./sieve cleanall:: ; $(RMF) sieve checkall:: sieve_lazy sieve_lazy: sieve_lazy.dats $(ATSCC) -D_ATS_GCATS -O3 -o $@ $< # && ./sieve_lazy cleanall:: ; $(RMF) sieve_lazy checkall:: sieve_lazy_vt sieve_lazy_vt: sieve_lazy_vt.dats # $(ATSCC) -O3 -o $@ $< # $(ATSCC) -D_ATS_gcats -O3 -o $@ $< $(ATSCC) -D_ATS_GCATS -O3 -o $@ $< # && ./sieve_lazy_vt cleanall:: ; $(RMF) sieve_lazy_vt # # a simple implementation of string match in CPS-style # checkall:: strmat strmat: strmat.dats; $(ATSCC) -o $@ $< && ./$@ cleanall:: ; $(RMF) strmat # # programming in System F # checkall:: systemf_programming_examples systemf_programming_examples: systemf_programming_examples.dats $(ATSCC) -O3 -o $@ $< && ./systemf_programming_examples cleanall:: ; $(RMF) systemf_programming_examples # # a simple example of programming with theorem-proving # checkall:: sumup sumup: sumup.dats $(ATSCC) -D_ATS_PROOFCHECK -O3 -o $@ $< && ./$@ cleanall:: ; $(RMF) sumup # # a poor man's game of tetrix # checkall:: tetrix tetrix: tetrix.dats; $(ATSCC) -O3 -o tetrix tetrix.dats cleanall:: ; $(RMF) tetrix # # a simple implementation of world count # checkall:: wc wc: wc.dats; $(ATSCC) -O3 -o wc wc.dats && ./wc *.dats cleanall:: ; $(RMF) wc ###### html:: html_AutoDiff html_AutoDiff: ; $(ATSOPT) --posmark_html -d AutoDiff.dats > AutoDiff_dats.html html:: html_coin_flip html_coin_flip: ; $(ATSOPT) --posmark_html -d coin_flip.dats > coin_flip_dats.html html:: html_curve html_curve: ; $(ATSOPT) --posmark_html -d curve.dats > curve_dats.html html:: html_fft html_fft: ; $(ATSOPT) --posmark_html -d fft.dats > fft_dats.html html:: html_GaussElim html_GaussElim: ; $(ATSOPT) --posmark_html -d GaussElim.dats > GaussElim_dats.html html:: html_GarsiaWachs html_GarsiaWachs: ; $(ATSOPT) --posmark_html -d GarsiaWachs.dats > GarsiaWachs_dats.html html:: html_gcd_mt html_gcd_mt: ; $(ATSOPT) --posmark_html -d gcd_mt.dats > gcd_mt_dats.html html:: html_hanoi html_hanoi: ; $(ATSOPT) --posmark_html -d hanoi.dats > hanoi_dats.html html:: html_isqrt html_isqrt: ; $(ATSOPT) --posmark_html -d isqrt.dats > isqrt_dats.html html:: html_kmp html_kmp: ; $(ATSOPT) --posmark_html -d kmp.dats > kmp_dats.html html:: html_longestline html_longestline: ; $(ATSOPT) --posmark_html -d longestline.dats > longestline_dats.html html:: html_passwdgen html_passwdgen: ; $(ATSOPT) --posmark_html -d passwdgen.dats > passwdgen_dats.html html_Peano: ; $(ATSOPT) --posmark_html -d Peano.dats > Peano_dats.html html_permute: ; $(ATSOPT) --posmark_html -d permute.dats > permute_dats.html html:: html_pi_lazy html_pi_lazy: ; $(ATSOPT) --posmark_html -d pi_lazy.dats > pi_lazy_dats.html html:: html_quicksort_list html_quicksort_list: $(ATSOPT) --posmark_html -d quicksort_list.dats > quicksort_list_dats.html html:: html_quicksort2_list html_quicksort2_list: $(ATSOPT) --posmark_html -d quicksort2_list.dats > quicksort2_list_dats.html html:: html_queens html_queens: ; $(ATSOPT) --posmark_html -d queens.dats > queens_dats.html html:: html_queens_appel html_queens_appel: ; $(ATSOPT) --posmark_html -d queens_appel.dats > queens_appel_dats.html html:: html_queens_lazy_vt html_queens_lazy_vt: ; $(ATSOPT) --posmark_html -d queens_lazy_vt.dats > queens_lazy_vt_dats.html html:: html_sieve html_sieve: ; $(ATSOPT) --posmark_html -d sieve.dats > sieve_dats.html html:: html_sieve_lazy html_sieve_lazy: ; $(ATSOPT) --posmark_html -d sieve_lazy.dats > sieve_lazy_dats.html html:: html_strmat html_strmat: ; $(ATSOPT) --posmark_html -d strmat.dats > strmat_dats.html html:: html_sumup html_sumup: ; $(ATSOPT) --posmark_html -d sumup.dats > sumup_dats.html html:: html_systemf_programming_examples html_systemf_programming_examples: $(ATSOPT) --posmark_html -d systemf_programming_examples.dats > systemf_programming_examples_dats.html html:: html_tetrix html_tetrix: ; $(ATSOPT) --posmark_html -d tetrix.dats > tetrix_dats.html html:: html_wc html_wc: ; $(ATSOPT) --posmark_html -d wc.dats > wc_dats.html ###### xref:: $(ATSOPT) --posmark_xref=XREF -d \ $(ATSHOME)/utils/xref/ats_prelude_xref.dats > /dev/null $(ATSOPT) --posmark_xref=XREF -d AutoDiff.dats > AutoDiff_dats.html $(ATSOPT) --posmark_xref=XREF -d coin_flip.dats > coin_flip_dats.html $(ATSOPT) --posmark_xref=XREF -d curve.dats > curve_dats.html $(ATSOPT) --posmark_xref=XREF -d fft.dats > fft_dats.html $(ATSOPT) --posmark_xref=XREF -d GaussElim.dats > GaussElim_dats.html $(ATSOPT) --posmark_xref=XREF -d GarsiaWachs.dats > GarsiaWachs_dats.html $(ATSOPT) --posmark_xref=XREF -d gcd_mt.dats > gcd_mt_dats.html $(ATSOPT) --posmark_xref=XREF -d hanoi.dats > hanoi_dats.html $(ATSOPT) --posmark_xref=XREF -d isqrt.dats > isqrt_dats.html $(ATSOPT) --posmark_xref=XREF -d kmp.dats > kmp_dats.html $(ATSOPT) --posmark_xref=XREF -d longestline.dats > longestline_dats.html $(ATSOPT) --posmark_xref=XREF -d passwdgen.dats > passwdgen_dats.html $(ATSOPT) --posmark_xref=XREF -d Peano.dats > Peano_dats.html $(ATSOPT) --posmark_xref=XREF -d permute.dats > permute_dats.html $(ATSOPT) --posmark_xref=XREF -d pi_lazy.dats > pi_lazy_dats.html $(ATSOPT) --posmark_xref=XREF -d quicksort_list.dats > quicksort_list_dats.html $(ATSOPT) --posmark_xref=XREF -d quicksort2_list.dats > quicksort2_list_dats.html $(ATSOPT) --posmark_xref=XREF -d queens.dats > queens_dats.html $(ATSOPT) --posmark_xref=XREF -d queens_appel.dats > queens_appel_dats.html $(ATSOPT) --posmark_xref=XREF -d queens_lazy_vt.dats > queens_lazy_vt_dats.html $(ATSOPT) --posmark_xref=XREF -d sieve.dats > sieve_dats.html $(ATSOPT) --posmark_xref=XREF -d sieve_lazy.dats > sieve_lazy_dats.html $(ATSOPT) --posmark_xref=XREF -d sieve_lazy_vt.dats > sieve_lazy_vt_dats.html $(ATSOPT) --posmark_xref=XREF -d strmat.dats > strmat_dats.html $(ATSOPT) --posmark_xref=XREF -d sumup.dats > sumup_dats.html $(ATSOPT) --posmark_xref=XREF -d \ systemf_programming_examples.dats > systemf_programming_examples_dats.html $(ATSOPT) --posmark_xref=XREF -d tetrix.dats > tetrix_dats.html $(ATSOPT) --posmark_xref=XREF -d wc.dats > wc_dats.html ###### RMF = rm -f ###### clean: $(RMF) *~ $(RMF) ./MISC/* $(RMF) *_dats.c *_sats.c ###### end of [Makefile] ###### ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/kmp.dats0000664000175000017500000001753712223166161020050 0ustar hwxihwxi(* ** ** An implementation of KMP string search algorithm in ATS ** *) // Author: Hongwei Xi (* hwxi AT CS DOT BU DOT EDU *) // Time: March 2007 // In this implementation, both memory safety and termination // of the algorithm are guaranteed with no use of run-time // checks. Compared to a previous implementation in DML (1998), // which requires run-time checks to ensure safe array access, // the progress made during these years in support of dependent // types for practical programming should be evident. stadef intsz: int = sizeof (Int) // extern val intsz: int intsz = "ats_intsz" val intsz = sizeof extern fun ptr_get_t {i:int} {l:addr} (pf: !int i @ l | p: ptr l):<> int i = "ats_ptr_get_t" extern fun ptr_set_t {i:int} {l:addr} (pf: !(int i)? @ l >> int i @ l | p: ptr l, i: size_t i):<> void = "ats_ptr_set_t" extern fun array_int_ptr_make {n:nat} (n: size_t n):<> [l:addr] (free_ngc_v l, array_v (Int?, n, l) | ptr l) = "ats_array_int_ptr_make" extern fun array_int_ptr_free {n:nat} {l:addr} (_: free_ngc_v l, _: array_v (Int?, n, l) | p: ptr l):<> void = "ats_array_int_ptr_free" %{^ ats_int_type ats_intsz = sizeof(ats_int_type) ; static inline ats_int_type ats_ptr_get_t(ats_ptr_type arg) { return *((ats_int_type *)arg) ; } static inline ats_void_type ats_ptr_set_t(ats_ptr_type arg1, ats_size_type arg2) { *((ats_int_type *)arg1) = arg2; } static inline ats_ptr_type ats_array_int_ptr_make(ats_size_type n) { return ats_calloc_ngc(n, sizeof(int)) ; } static inline ats_void_type ats_array_int_ptr_free (ats_ptr_type A) { ats_free_ngc(A) ; } %} // dataview kmp_v (l:addr, int) = | kmp_v_none (l, 0) | {n:nat} {ofs:int} kmp_v_more (l, n+1) of (MUL (n+1, intsz, ofs), kmp_v (l, n), natLte n @ (l + ofs)) // prfun kmp_v_takeout {n,i:int | 0 < i; i <= n} {l:addr} {ofs:int} .. (pf0_mul: MUL (i, intsz, ofs), pf0_kmp: kmp_v (l, n)) : [i1:nat | i1 < i] ( int i1 @ l + ofs, int i1 @ l + ofs - kmp_v (l, n) ) = let prval kmp_v_more (pf_mul, pf_kmp, pf_elt) = pf0_kmp in sif i == n then let val () = mul_isfun (pf0_mul, pf_mul) in #[.. | (pf_elt, llam pf_elt => kmp_v_more (pf_mul, pf_kmp, pf_elt))] end else let prval (pf1_elt, pf1_rest) = kmp_v_takeout {n-1,i} (pf0_mul, pf_kmp) in #[.. | (pf1_elt, llam pf1_elt => kmp_v_more (pf_mul, pf1_rest pf1_elt, pf_elt))] end // end of [sif] end // end of [kmp_v_takeout] // fn kmp_sub {n,i:int | 0 < i; i <= n} {l:addr} (pf_kmp: !kmp_v (l, n) | tbl: ptr l, i: size_t i) :<> [i1:nat | i1 < i] int (i1) = let val (pf_mul | ofs) = i szmul2 intsz prval (pf_elt, pf_rest) = kmp_v_takeout (pf_mul, pf_kmp) val i1 = ptr_get_t (pf_elt | tbl + ofs) in pf_kmp := pf_rest pf_elt; i1 end // end of [kmp_sub] // extern fun string1_get_char_at {n:nat} (s: string n, i: sizeLt n):<> [c:char | c <> NUL] char c = "atspre_string_get_char_at" fun kmp_table_make_aux {i,j,n:int | 0 <= j; j+1 < i; i <= n} {l:addr} {ofs:int} .. (pf_mul: MUL (i, intsz, ofs), pf_kmp: kmp_v (l, i-1), pf_arr: array_v (Int?, n-i, l+ofs) | w: string n, tbl: ptr l, n: size_t n, i: size_t i, j: size_t j, tbl_ofs: ptr(l+ofs)) :<> (kmp_v (l, n-1) | void) = begin if i < n then if w[i-1] = w[j] then let prval (pf_elt, pf_arr) = array_v_uncons {Int?} pf_arr val () = ptr_set_t (pf_elt | tbl_ofs, j+1) prval pf_kmp = kmp_v_more (pf_mul, pf_kmp, pf_elt) prval pf_mul = mul_add_const {1} (pf_mul) in kmp_table_make_aux (pf_mul, pf_kmp, pf_arr | w, tbl, n, i+1, j+1, tbl_ofs+intsz) end else if j > 0 then let val i1 = kmp_sub (pf_kmp | tbl, j); val i1 = size1_of_int1 i1 in kmp_table_make_aux (pf_mul, pf_kmp, pf_arr | w, tbl, n, i, i1, tbl_ofs) end else let prval (pf_elt, pf_arr) = array_v_uncons {Int?} pf_arr val () = ptr_set_t (pf_elt | tbl_ofs, 0) prval pf_kmp = kmp_v_more (pf_mul, pf_kmp, pf_elt) prval pf_mul = mul_add_const {1} (pf_mul) in kmp_table_make_aux (pf_mul, pf_kmp, pf_arr | w, tbl, n, i+1, 0, tbl_ofs+intsz) end else let prval () = array_v_unnil pf_arr in (pf_kmp | ()) end // end of [if] end // end of [kmp_table_make_aux] // fn kmp_table_make {n:int | n >= 1} (w: string n, n: size_t n) :<> [l:addr] (free_ngc_v (l+intsz), kmp_v (l, n-1) | ptr l) = let val n = string1_length w val [l:addr] (pf_ngc, pf_arr | p_arr) = array_int_ptr_make (n-1) val tbl = p_arr-intsz prval pf_kmp = kmp_v_none {l-intsz} in if n > 1 then let prval (pf_elt, pf_arr) = array_v_uncons {Int?} (pf_arr) val () = ptr_set_t (pf_elt | p_arr, 0) prval pf1_mul = mul_istot {1,intsz} () prval () = mul_elim (pf1_mul) prval pf2_mul = mul_istot {2,intsz} () prval () = mul_elim (pf2_mul) prval pf_kmp = kmp_v_more {l-intsz} (pf1_mul, pf_kmp, pf_elt) val (pf_kmp | ()) = kmp_table_make_aux (pf2_mul, pf_kmp, pf_arr | w, tbl, n, 2, 0, p_arr+intsz) in (pf_ngc, pf_kmp | tbl) end else let prval () = array_v_unnil{Int?} (pf_arr) in (pf_ngc, pf_kmp | tbl) end end // end of [kmp_table_make] // prfun array_v_of_kmp_v {n:nat} {l:addr} .. (pf_kmp: kmp_v (l, n)): array_v (Int?, n, l+intsz) = begin sif n == 0 then let prval kmp_v_none () = pf_kmp in array_v_nil {Int?} () end else let prval kmp_v_more (pf_mul, pf_kmp, pf_elt) = pf_kmp prval pf1_mul = mul_add_const {~1} (pf_mul) prval pf_arr = array_v_of_kmp_v pf_kmp in array_v_extend {Int?} (pf1_mul, pf_arr, pf_elt) end end // end of [array_v_of_kmp_v] fn kmp_table_free {n:nat} {l:addr} (pf_ngc: free_ngc_v (l+intsz), pf_kmp: kmp_v (l, n) | p: ptr l) :<> void = let prval pf_arr = array_v_of_kmp_v pf_kmp in array_int_ptr_free (pf_ngc, pf_arr | p+intsz) end // end of [kmp_table_free] // fn kmp_search {ns:nat; nw:int | nw >= 1} (s: string ns, w: string nw):<> intBtw (~1, ns) = let val ns = string1_length s; val nw = string1_length w val [l:addr] (pf_ngc, pf | tbl) = kmp_table_make (w, nw) val ns = int1_of_size1 ns; val nw = int1_of_size1 nw fun loop {m,i:nat | m+i <= ns; i <= nw} .. (pf: !kmp_v (l, nw-1) | m: int m, i: int i): intBtw (~1, ns) = if i < nw then begin if m+i < ns then if w[i] = s[m+i] then loop (pf | m, i+1) else if i > 0 then let val i1 = kmp_sub (pf | tbl, size1_of_int1 i) in loop (pf | m+i-i1, i1) end else begin loop (pf | m+1, 0) end // end of [if] (* end of [if] *) else begin ~1 (* loop exists *) end // end of [if] end else begin m // loop exits end // end of [if] val ans = loop (pf | 0, 0) in kmp_table_free (pf_ngc, pf | tbl); ans end // end of [kmp_search] // some tests implement main (argc, argv) = begin print "kmp_search(\"abcdefggfedcbabcdefg\", \"fggf\") = "; print (kmp_search("abcdefggfedcbabcdefg", "fggf")); print_newline (); print "kmp_search(\"abcdefggfedcbabcdefg\", \"cbabc\") = "; print (kmp_search("abcdefggfedcbabcdefg", "cbabc")); print_newline (); print "kmp_search(\"abcdefggfedcbabcdefg\", \"baba\") = "; print (kmp_search("abcdefggfedcbabcdefg", "baba")); print_newline (); print "kmp_search(\"abcdefggfedcbabadefg\", \"baba\") = "; print (kmp_search("abcdefggfedcbabadefg", "baba")); print_newline (); end (* ****** ****** *) (* end of [kmp.dats] *) //// // An (untested) implementation in C (* #include int main() { unsigned int Fail[1024]; unsigned int M, K, R, i; const char* P = "AAAABAABACA"; M = strlen(P); K = 1; Fail[K] = 0; while (K <= M) { R = Fail[K]; while ((R > 0) && (P[R-1] != P[K-1])) R = Fail[R]; Fail[K+1] = R+1; K++; } /* K = 1; while (K <= M) { R = Fail[K]; if (P[K-1] == P[R-1]) Fail[K] = Fail[R]; K++; } */ for (i = 1; i <= M+1; i++) printf("Fail[%d] = %d\n", i, Fail[i]); return 0; } *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/permute_vt.dats0000664000175000017500000000515512223166161021444 0ustar hwxihwxi(* ** CAS CS525, Spring 2011 ** Instructor: Hongwei Xi *) (* ****** ****** *) staload "prelude/DATS/list.dats" staload "prelude/DATS/list_vt.dats" staload "prelude/DATS/list0.dats" (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) fun range {m,n:nat} (m:int m, n:int n): list (int, max (n-m+1, 0)) = if m <= n then list_cons (m, range (m+1, n)) else list_nil // end of [range] fun permute {n:nat} (n: int n): List_vt (list (int, n)) = let // fun{a:t@ype} rotout {n:int} {i:nat | i < n} (xs: list (a, n), i: int i): (a, list (a, n-1)) = let val (xfs, xbs) = list_split_at (xs, i) val+ list_cons (x, xbs) = xbs val xs = list_append1_vt (xfs, xbs) in (x, xs) end // end of [rotout] // fun{a:t@ype} perm {n:nat} ( xs: list (a, n), n: int n ) : List_vt (list (a, n)) = let viewtypedef res_vt = List_vt (list (a, n)) in case+ xs of | list_cons (x, xs1) => let fun loop {i:nat | i < n} ( xs1: list (a, n-1), i: int i, res: res_vt ) : res_vt = if i > 0 then let val (x1, xs2) = rotout (xs1, i-1) val xs = list_cons (x1, list_cons (x, xs2)) in loop (xs1, i-1, list_vt_cons (xs, res)) end else list_vt_cons (xs, res) // end of [if] // val xss = loop (xs1, n-1, list_vt_nil) // val f = lam ( xs: list (a, n) ) : res_vt = let val+ list_cons (x, xs1) = xs val xss1 = perm (xs1, n-1) val xss = list_map_cloref ($UN.castvwtp1 {List(list(a,n-1))} (xss1), lam (xs1) = list_cons (x, xs1)) // end of [val] val () = list_vt_free (xss1) in xss end // end of [f] val xsss = list_map_cloref ($UN.castvwtp1 {List(list(a,n))} xss, f) val () = list_vt_free (xss) in list_vt_concat (xsss) end // end of [list_cons] | list_nil () => list_vt_cons (list_nil, list_vt_nil) end // end of [perm] // in perm (range (1, n), n) end // end of [permute] (* ****** ****** *) staload "contrib/testing/SATS/fprint.sats" staload _(*anon*) = "contrib/testing/DATS/fprint.dats" implement fprint_elt (out, x) = fprint (out, x) (* ****** ****** *) implement main () = () where { val xss = permute (5) val xss = list_of_list_vt (xss) fun f (xs: List (int)): void = let val () = list_fprint_elt (stdout_ref, xs, " >> ") in print_newline () end // end of [val] val () = list_foreach_fun (xss, f) } // end of [main] (* ****** ****** *) (* end of [permute.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/quicksort_list.dats0000664000175000017500000001616712223166161022336 0ustar hwxihwxi(* // // A verified implementation of quicksort on lists // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Saturday, September 27, 2008 // // // How to compile: // atscc -o quicksort_list quicksort_list.dats // How to test: // ./quicksort_list // *) (* This is a milestone example in the development of ATS. A list quicksort implementation given below is proven to be terminating and its return is guaranteed to be a sorted permutation of its input list. An implementation of list quicksort in DML was given in 1998 that can guarantee based on its type that it always returns a list of the same length as its input. Since then, a question that has been asked frequently by many people is whether it can be done in DML to give an implementation of list quicksort that can guarantee based on its type that it always returns a list that is a sorted permutation of its input. This is finally done now in ATS, which succeeds DML as well as extends it. For more examples of a similar nature, please follow the link below: http://www.ats-lang.org/EXAMPLE/PCPV *) (* ****** ****** *) staload "libats/SATS/ilistp.sats" stadef nil = ilist_nil stadef cons = ilist_cons (* ****** ****** *) sortdef nats = nat dataprop MSET (ilist, int(*nats*)) = | {x:nat} {xs:ilist} {n:nats} MSETcons (cons (x, xs), x + n) of MSET (xs, n) | MSETnil (nil, 0) // end of [MSET] extern praxi MSET_istot {xs:ilist} (): [n:nats] MSET (xs, n) (* ****** ****** *) dataprop LB (int, ilist) = | {l:nat} {x:nat | l <= x} {xs:ilist} LBcons (l, cons (x, xs)) of LB (l, xs) | {l:nat} LBnil (l, nil) // end of [LB] dataprop UB (ilist, int) = | {u:nat} {x:nat | x <= u} {xs:ilist} UBcons (cons (x, xs), u) of UB (xs, u) | {u:nat} UBnil (nil, u) // end of [UB] (* ****** ****** *) extern praxi LB_MSET_lemma {x:nat} {xs1,xs2:ilist} {n:nats} (_: MSET (xs1, n), _: MSET (xs2, n), _lb: LB (x, xs1)): LB (x, xs2) extern praxi UB_MSET_lemma {x:nat} {xs1,xs2:ilist} {n:nats} (_: MSET (xs1, n), _: MSET (xs2, n), _ub: UB (xs1, x)): UB (xs2, x) (* ****** ****** *) extern prfun LB_lemma_monotone {l1,l2:nat | l1 <= l2} {xs: ilist} (pf: LB (l2, xs)): LB (l1, xs) extern prfun UB_lemma_monotone {u1,u2:nat | u1 >= u2} {xs: ilist} (pf: UB (xs, u2)): UB (xs, u1) (* ****** ****** *) absprop ISORD (ilist) extern prfun isord_nil (): ISORD (nil) extern prfun isord_cons {x:int} {xs:ilist} (pf1: LB (x, xs), pf2: ISORD (xs)): ISORD (cons (x, xs)) // end of [isord_cons] (* ****** ****** *) extern prfun APPEND_MSET_lemma {xs,ys,zs:ilist} {n1,n2:nats} (pf1: MSET (xs, n1), pf2: MSET (ys, n2), pf3: APPEND (xs, ys, zs)) : MSET (zs, n1 + n2) // end of [APPEND_MSET_lemma] extern prfun APPEND_ISORD_lemma {xs1,xs2,xs:ilist} {x:nat} ( pf1: ISORD xs1 , pf2: ISORD xs2 , pf3: UB (xs1, x) , pf4: LB (x, xs2) , pf5: APPEND (xs1, xs2, xs) ) : ISORD (xs) // end of [APPEND_ISORD_lemma] (* ****** ****** *) abst@ype E (a: t@ype, x:int) = a extern castfn eltencode {a:t@ype} (x: a):<> [x:pos] E (a, x) extern castfn eltdecode {a:t@ype} {x:int} (x: E (a, x)):<> a (* ****** ****** *) extern fun{a:t@ype} lte_elt_elt {x,y:nat} (x: E(a, x), y: E (a, y)):<> bool (x <= y) overload <= with lte_elt_elt datatype list (a:t@ype, ilist) = | nil (a, nil) of () | {x:pos} {xs: ilist} cons (a, cons (x, xs)) of (E (a, x), list (a, xs)) // end of [list] typedef list (a:t@ype) = [xs:ilist] list (a, xs) (* ****** ****** *) extern fun{a:t@ype} append {xs,ys:ilist} (xs: list (a, xs), ys: list (a, ys)):<> [zs:ilist] (APPEND (xs, ys, zs) | list (a, zs)) implement{a} append (xs, ys) = let fun aux {xs,ys:ilist} .. (xs: list (a, xs), ys: list (a, ys)) :<> [zs:ilist] (APPEND (xs, ys, zs) | list (a, zs)) = begin case+ xs of | cons (x, xs) => let val (pf | zs) = aux (xs, ys) in (APPENDcons pf | cons (x, zs)) end | nil () => (APPENDnil () | ys) end // end of [aux] in aux (xs, ys) end // end of [append] (* ****** ****** *) fun{a:t@ype} qsrt {xs:ilist} {n:nats} .. (pf: MSET (xs, n) | xs: list (a, xs)) :<> [xs: ilist] (MSET (xs, n), ISORD (xs) | list (a, xs)) = begin case+ xs of | cons (x, xs) => let prval MSETcons pf = pf in part ( pf, MSETnil (), MSETnil (), UBnil (), LBnil () | x, xs, nil (), nil () ) end | nil () => let prval MSETnil () = pf in (MSETnil (), isord_nil () | nil ()) end end // end of [qsrt] and part {x:pos} {xs0,xs1,xs2:ilist} {n0,n1,n2:nats} .. ( pf0: MSET (xs0, n0) , pf1: MSET (xs1, n1) , pf2: MSET (xs2, n2) , pf_ub: UB (xs1, x) , pf_lb: LB (x, xs2) | x: E (a, x), xs0: list (a, xs0), xs1: list (a, xs1), xs2: list (a, xs2) ) :<> [xs: ilist] (MSET (xs, x+n0+n1+n2), ISORD (xs) | list (a, xs)) = begin case+ xs0 of | cons (x0, xs0) => let prval MSETcons (pf0) = pf0 in if x0 <= x then part ( pf0, MSETcons pf1, pf2, UBcons (pf_ub), pf_lb | x, xs0, cons (x0, xs1), xs2 ) else part ( pf0, pf1, MSETcons pf2, pf_ub, LBcons (pf_lb) | x, xs0, xs1, cons (x0, xs2) ) end // end of [cons] | nil () => let prval MSETnil () = pf0 val (pf1_set, pf1_ord | xs1) = qsrt (pf1 | xs1) val (pf2_set, pf2_ord | xs2) = qsrt (pf2 | xs2) prval pf_ub = UB_MSET_lemma (pf1, pf1_set, pf_ub) prval pf_lb = LB_MSET_lemma (pf2, pf2_set, pf_lb) prval pf2_ord1 = isord_cons (pf_lb, pf2_ord) val (pf_app | xs) = append (xs1, cons (x, xs2)) prval pf_set = APPEND_MSET_lemma (pf1_set, MSETcons pf2_set, pf_app) prval pf_ord = APPEND_ISORD_lemma ( pf1_ord, pf2_ord1, pf_ub, LBcons {x} (pf_lb), pf_app ) in (pf_set, pf_ord | xs) end end // end of [part] (* ****** ****** *) extern fun{a:t@ype} quicksort {xs:ilist} {n:nats} (pf: MSET (xs, n) | xs: list (a, xs)) :<> [xs: ilist] (MSET (xs, n), ISORD (xs) | list (a, xs)) implement{a} quicksort (pf | xs) = qsrt (pf | xs) (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) implement lte_elt_elt {x,y} (x, y) = let val x = eltdecode (x) and y = eltdecode(y) extern castfn __cast (_: bool):<> bool (x <= y) in __cast (lte_double_double (x, y)) end // end of [lte_elt_elt] fn print_list ( xs: list (double) ) : void = let fun aux ( xs: list (double), i: int ) : void = begin case+ xs of | cons (x, xs) => let val x = eltdecode (x) in if i > 0 then print ", "; printf ("%.2f", @(x)); aux (xs, i+1) end // end of [cons] | nil () => () end // end of [aux] in aux (xs, 0) end // end of [print_list] fun randgen_list {n:nat} .. (n: int n): list (double) = if n > 0 then let val x = drand48 () val x = eltencode (x) in cons {double} (x, randgen_list (n-1)) end else nil () // end of [randgen_list] (* ****** ****** *) implement main () = let // val () = srand48_with_time () // val xs = randgen_list (20) val () = (print "xs = "; print_list xs; print_newline ()) prval pfmset = MSET_istot () val (pford, pfmset | ys) = quicksort (pfmset | xs) val () = (print "ys = "; print_list ys; print_newline ()) in // nothing end // end of [main] (* ****** ****** *) (* end of [quicksort_list.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/strmat.dats0000664000175000017500000001001412223166161020552 0ustar hwxihwxi// // // Author: Hongwei Xi (May 2007) // // // An implementation of string matching in continuation-passing style. // The code is translated by Hongwei Xi from an earlier version in DML, // which was originally adopted by him from a version by Frank Pfenning // (fp+ AT cs DOT cmu DOT edu) datatype regexp (int) = | Any_char(1) (* any character *) | Empty(1) (* empty string matches Empty *) | Char(1) of Char (* "c" matches Char (c) *) // every char other than "c" matches Char (c) | Char_not(1) of Char // every char in [c1, c2] matches Chars (c1, c2) | Chars(1) of (Char, Char) // every char not in [c1, c2] matches Chars (c1, c2) | Chars_not(1) of (Char, Char) // cs matches Alt(p1, p2) if cs matches either p1 or p2 | {i,j:nat} Alt(i+j+1) of (regexp i, regexp j) // cs matches Seq(p1, p2) if a prefix of cs matches p1 and the rest matches p2 | {i,j:nat} Seq(i+j+1) of (regexp i, regexp j) // cs matches Star(p) if cs matches some, possibly 0, copies of p | {i:nat} Star(i+1) of regexp i typedef Regexp = [i:nat] regexp i // Note that [acc] is verified to be terminating! fun acc {i0,n,i:nat} {b:two | i+b <= i0} .. // metric for termination verification (cs0: string i0, i0: int i0, p: regexp n, i: int i, b: int b, k: {i':nat; b':two | i'+b' <= i+b} (int i', int b') - Bool): Bool = case+ p of | Any_char () => if i > 0 then k (i-1, 1) else false | Empty () => k (i, b) | Char c => if i > 0 then (if c = cs0[i0-i] then k (i-1, 1) else false) else false | Char_not c => if i > 0 then (if c <> cs0[i0-i] then k (i-1, 1) else false) else false | Chars (c1, c2) => if i > 0 then let val c = cs0[i0-i] in if c1 <= c then (if c <= c2 then k (i-1, 1) else false) else false end else false | Chars_not (c1, c2) => if i > 0 then let val c = cs0[i0-i] in if c < c1 then k (i-1, 1) else if c > c2 then k (i-1, 1) else false end else false | Alt (p1, p2) => if acc (cs0, i0, p1, i, b, k) then true else acc (cs0, i0, p2, i, b, k) | Seq (p1, p2) => acc (cs0, i0, p1, i, b, lam (i', b') => acc (cs0, i0, p2, i', b', k)) | Star p0 => if k (i, b) then true else begin acc (cs0, i0, p0, i, 0, lam (i', b') => if b' = 0 then false else acc (cs0, i0, p, i', 1, k) ) // end of [acc] end // end of [if] extern fun accept (cs0: String, p: Regexp): Bool implement accept (cs0, p) = let val i0 = string_length cs0; val i0 = int1_of_size1 i0 in acc (cs0, i0, p, i0, 0, lam (i, _) => i = 0) end // end of [accept] // some tests val regexp_digit = Chars ('0', '9') val regexp_digits = Star (Chars ('0', '9')) val regexp_uint = Alt (Char '0', Seq (Chars ('1', '9'), regexp_digits)) val regexp_int = Alt (regexp_uint, Seq (Alt (Char '-', Char '+'), regexp_uint)) val regexp_dot_sats = Seq (Star Any_char, Seq (Char '.', Seq (Char 's', Seq (Char 'a', Seq (Char 't', Char 's'))))) val regexp_dot_dats = Seq (Star Any_char, Seq (Char '.', Seq (Char 'd', Seq (Char 'a', Seq (Char 't', Char 's'))))) implement main (argc, argv) = let val ans10 = accept ("123456789", regexp_int) val ans11 = accept ("+123456789", regexp_int) val ans12 = accept ("-123456789", regexp_int) val ans20 = accept ("abcde", regexp_int) val ans31 = accept ("abcde.sats", regexp_dot_sats) val ans32 = accept ("abcde.sats", regexp_dot_dats) val ans41 = accept ("abcde.dats", regexp_dot_sats) val ans42 = accept ("abcde.dats", regexp_dot_dats) in print ("ans10(true) = "); print ans10; print_newline (); print ("ans11(true) = "); print ans11; print_newline (); print ("ans12(true) = "); print ans12; print_newline (); print ("ans20(false) = "); print ans20; print_newline (); print ("ans31(true) = "); print ans31; print_newline (); print ("ans32(false) = "); print ans32; print_newline (); print ("ans41(false) = "); print ans41; print_newline (); print ("ans42(true) = "); print ans42; print_newline (); end // end of [main] (* ****** ****** *) (* end of [strmat.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/sieve_lazy_vt.dats0000664000175000017500000000406512223166161022134 0ustar hwxihwxi(* // Implementing Erathosthene's sieve in linear-lazy style // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2008) // *) (* ****** ****** *) staload "prelude/DATS/lazy_vt.dats" (* ****** ****** *) #define nil stream_vt_nil #define :: stream_vt_cons (* ****** ****** *) fun{a:t@ype} stream_vt_nth (xs0: stream_vt a, i: Nat): a = let (* val () = begin print "stream_vt_nth: before: i = "; print i; print_newline () end *) val xs0_con = !xs0 in case+ xs0_con of | ~(x :: xs) => begin if i = 0 then (~xs; x) else stream_vt_nth (xs, i-1) end // end of [::] | ~nil () => $raise StreamSubscriptException () end // end of [stream_vt_nth] (* ****** ****** *) fun from_con {n:int} (n: int n) : stream_vt_con (intGte n) = n :: from (n+1) and from {n:int} (n: int n) : stream_vt (intGte n) = $ldelay (from_con n) // typedef Nat2 = intGte 2 fun sieve_con (ns: stream_vt Nat2) : stream_vt_con (Nat2) = let (* val () = begin print "sieve_con: enter"; print_newline () end *) val ns_con = !ns val- n :: !p_ns = ns_con (* val () = begin print "sieve_con: n = "; print n; print_newline () end // end of [val] *) val ns = !p_ns val () = (!p_ns := sieve (stream_vt_filter_cloptr (ns, lam x => x nmod1 n > 0))) in fold@ ns_con; ns_con end // end of [sieve_con] and sieve (ns: stream_vt Nat2) : stream_vt (Nat2) = $ldelay (sieve_con ns, ~ns) // end of [sieve] // fn primes (): stream_vt Nat2 = sieve (from 2) fn prime (n: Nat): Nat = stream_vt_nth (primes (), n) // implement main (argc, argv) = begin //printf ("prime 1000 = %i\n", @(prime 1000)) ; // 7927 //printf ("prime 5000 = %i\n", @(prime 5000)) ; // 48619 printf ("prime 10000 = %i\n", @(prime 10000)) ; // 104743 //printf ("prime 20000 = %i\n", @(prime 20000)) ; // 224743 //printf ("prime 30000 = %i\n", @(prime 30000)) ; // = 350381 (2 min.) //printf ("prime 50000 = %i\n", @(prime 50000)) ; // = 611957 (6 min.) end // end of [main] (* ****** ****** *) (* end of [sieve_lazy_vt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/sieve_lazy.dats0000664000175000017500000000226312223166161021421 0ustar hwxihwxi(* // Implementing Erathosthene's sieve in lazy style // author: Hongwei Xi (September, 2007) *) (* ****** ****** *) staload "prelude/DATS/lazy.dats" (* ****** ****** *) #define nil stream_nil #define :: stream_cons (* ****** ****** *) fun from {n:int} (n: int n): stream (intGte n) = $delay (n :: from (n+1)) // typedef Nat2 = intGte 2 fun sieve (ns: stream Nat2): stream (Nat2) = $delay (let val- n :: ns = !ns in n :: sieve (stream_filter_cloref (ns, lam x => x nmod n > 0)) end : stream_con Nat2) // end of [sieve] // val primes: stream Nat2 = sieve (from 2) fun prime_get (n: Nat): Nat = stream_nth (primes, n) // implement main (argc, argv) = begin (* printf ("prime 1 = %i\n", @(prime_get 1)) ; printf ("prime 10 = %i\n", @(prime_get 10)) ; printf ("prime 100 = %i\n", @(prime_get 100)) ; printf ("prime 1000 = %i\n", @(prime_get 1000)) ; printf ("prime 999 = %i\n", @(prime_get 999)) ; printf ("prime 5000 = %i\n", @(prime_get 5000)) ; // = 48619 printf ("prime 10000 = %i\n", @(prime_get 10000)) ; // = 104743 *) printf ("prime 10000 = %i\n", @(prime_get 10000)) ; // = 104743 end // end of [main] (* ****** ****** *) (* end of [sieve_lazy.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/queens_lazy_vt.dats0000664000175000017500000000574212223166161022324 0ustar hwxihwxi(* ** An implementation of the QUEENS problem that ** makes use of lazy-evaluation ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: 2009 *) (* ****** ****** *) staload "prelude/DATS/lazy_vt.dats" (* ****** ****** *) fn print_row {n,i:nat | i < n} (n: int n, i: int i): void = let var k: int val () = for (k := 0; k < i; k := k + 1) print '.' val () = print 'Q' val () = for (k := i+1; k < n; k := k + 1) print '.' in // empty end // end of [print_row] typedef board (n:int, k:int) = list (natLt n, k) fn print_board {n:nat} (n: int n, xs: list (natLt n, n)) : void = loop (n, xs) where { fun loop {k:nat | k <= n} (n: int n, xs: board (n, k)): void = case+ xs of | list_cons (x, xs1) => begin print_row (n, x); print_newline (); loop (n, xs1) end // end of [list_cons] | list_nil () => () // end of [loop] } // end of [print_board] (* ****** ****** *) fun test_one {n,k:nat | k < n} .. (x0: natLt n, dist: int, xs: board (n, k)):<> bool = case+ xs of | list_cons (x, xs1) => begin if (x0 = x orelse dist = abs (x - x0)) then false else begin let val ans = test_one {n,k-1} (x0, dist+1, xs1) in ans end end // end of [if] end // end of [list_cons] | list_nil () => true // end of [test_one] (* ****** ****** *) fun board_extend {n,k:nat | k < n} (n: int n, xss: stream_vt (board (n, k))) : stream_vt_con (board (n, k+1)) = case+ !xss of | ~stream_vt_cons (xs, xss) => board_extend_aux (n, xs, xss, 0) | ~stream_vt_nil () => stream_vt_nil () and board_extend_aux {n,k:nat | k < n} {i:nat | i <= n} (n: int n, xs: board (n, k), xss: stream_vt (board (n, k)), x: int i) : stream_vt_con (board (n, k+1)) = if x < n then begin if test_one {n,k} (x, 1, xs) then let val xss = $ldelay (board_extend_aux (n, xs, xss, x+1), ~xss) in stream_vt_cons (list_cons (x, xs), xss) end else begin board_extend_aux (n, xs, xss, x+1) end // end of [if] end else begin board_extend {n, k} (n, xss) end // end of [if] (* ****** ****** *) fun queens {n,k:nat | k <= n} (n: int n, k: int k): stream_vt (board (n, k)) = if k = 0 then begin $ldelay ( stream_vt_cons (list_nil (), $ldelay (stream_vt_nil ())) ) end else begin $ldelay (board_extend {n,k-1} (n, queens (n, k-1))) end // end of [if] (* end of [queens] *) (* ****** ****** *) #define EIGHT 8 implement main (argc, argv) = loop (1, xss) where { val N = if argc >= 2 then int_of_string argv.[1] else EIGHT val [N:int] N = int1_of_int N val () = assert (N >= 0) val xss = queens (N, N) fun loop (i: int, xss: stream_vt (board (N, N))): void = case+ !xss of | ~stream_vt_cons (xs, xss) => begin printf ("solution no. %i:\n", @(i)); print_board (N, xs); print_newline (); loop (i+1, xss) end // end of [stream_vt_cons] | ~stream_vt_nil () => () // end of [loop] } // end of [main] (* ****** ****** *) (* end of [queens_lazy_vt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/permute.dats0000664000175000017500000000504312223166161020727 0ustar hwxihwxi(* ** CAS CS525, Spring 2011 ** Instructor: Hongwei Xi *) (* ****** ****** *) // // Given a natural number n, permute(n) lists all the permutations // of (1, 2, ..., n) in the lexicographic order. // (* ****** ****** *) staload "prelude/DATS/list.dats" staload "prelude/DATS/list_vt.dats" staload "prelude/DATS/list0.dats" (* ****** ****** *) fun range {m,n:nat} (m:int m, n:int n): list (int, max (n-m+1, 0)) = if m <= n then list_cons (m, range (m+1, n)) else list_nil // end of [range] fun permute {n:nat} (n: int n): List (list (int, n)) = let fun{a:t@ype} rotout {n:int} {i:nat | i < n} (xs: list (a, n), i: int i): (a, list (a, n-1)) = let val (xfs, xbs) = list_split_at (xs, i) val+ list_cons (x, xbs) = xbs val xs = list_append1_vt (xfs, xbs) in (x, xs) end // end of [rotout] fun{a:t@ype} perm {n:nat} (xs: list (a, n), n: int n): List (list (a, n)) = let typedef res_t = List (list (a, n)) in case+ xs of | list_cons (x, xs1) => let fun loop {i:nat | i < n} ( xs1: list (a, n-1), i: int i, res: res_t ) : res_t = if i > 0 then let val (x1, xs2) = rotout (xs1, i-1) val xs = list_cons (x1, list_cons (x, xs2)) in loop (xs1, i-1, list_cons (xs, res)) end else list_cons (xs, res) // end of [if] val xss = loop (xs1, n-1, list_nil) val f = lam ( xs: list (a, n) ) : res_t = let val+ list_cons (x, xs1) = xs val xss1 = perm (xs1, n-1) val xss = list_map_cloref (xss1, lam (xs1) = list_cons (x, xs1)) // end of [val] in list_of_list_vt (xss) end // end of [f] val xsss = list_map_cloref (xss, f) val xsss = list_of_list_vt (xsss) in list_of_list_vt (list_concat (xsss)) end // end of [list_cons] | list_nil () => list_cons (list_nil, list_nil) end // end of [perm] in perm (range (1, n), n) end // end of [permute] (* ****** ****** *) staload "contrib/testing/SATS/fprint.sats" staload _(*anon*) = "contrib/testing/DATS/fprint.dats" implement fprint_elt (out, x) = fprint (out, x) (* ****** ****** *) implement main () = () where { val xss = permute (5) fun f (xs: List (int)): void = let val () = list_fprint_elt (stdout_ref, xs, " >> ") in print_newline () end // end of [val] val () = list_foreach_fun (xss, f) } // end of [main] (* ****** ****** *) (* end of [permute.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/quicksort2_list.dats0000664000175000017500000001577412223166161022423 0ustar hwxihwxi(* // // A verified implementation of quicksort on lists: // the returned output list is guaranteed to be a permutation // of the original input // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Tuesday, October 5, 2010 // // // How to compile: // atscc -o quicksort2_list quicksort2_list.dats // How to test: // ./quicksort2_list *) (* ****** ****** *) staload "libc/SATS/random.sats" staload "libats/SATS/ilistp.sats" (* ****** ****** *) stadef nil = ilist_nil stadef cons = ilist_cons (* ****** ****** *) abst@ype E (a: t@ype, x:int) = a extern castfn encode {a:t@ype} (x: a):<> [x:pos] E (a, x) extern castfn decode {a:t@ype} {x:int} (x: E (a, x)):<> a (* ****** ****** *) extern fun{a:t@ype} lte_elt_elt {x,y:nat} (x: E(a, x), y: E (a, y)):<> bool (x <= y) overload <= with lte_elt_elt datatype list (a:t@ype, ilist) = | nil (a, nil) of () | {x:pos} {xs: ilist} cons (a, cons (x, xs)) of (E (a, x), list (a, xs)) // end of [list] typedef list (a:t@ype) = [xs:ilist] list (a, xs) (* ****** ****** *) (* // // HX-2010-10-08: // if you want to show that the output of quicksort is always an ordered list, // please be my guest :) // dataprop LB (x0:int, ilist) = | LBnil (x0, ilist_nil) of () | {x:int | x0 <= x} {xs:ilist} LBcons (x0, ilist_cons (x, xs)) of LB (x0, xs) dataprop UB (x0:int, ilist) = | UBnil (x0, ilist_nil) of () | {x:int | x0 >= x} {xs:ilist} UBcons (x0, ilist_cons (x, xs)) of UB (x0, xs) dataprop ISORD (ilist) = | ISORDnil (ilist_nil) of () | {x:int} {xs:ilist} ISORDcons (ilist_cons (x, xs)) of (LB (x, xs), ISORD (xs)) // end of [ISORD] *) (* ****** ****** *) extern fun{a:t@ype} quicksort {xs:ilist} (xs: list (a, xs)): [ys:ilist] (PERMUTE (xs, ys) | list (a, ys)) // end of [quicksort] (* ****** ****** *) extern fun{a:t@ype} append {xs1,xs2:ilist} (xs1: list (a, xs1), xs2: list (a, xs2)) : [xs3: ilist] (APPEND (xs1, xs2, xs3) | list (a, xs3)) // end of [append] (* ****** ****** *) implement{a} append {xs1,xs2} (xs1, xs2) = case+ xs1 of | cons {x1} (x1, xs11) => let val [xs31:ilist] (pf1 | xs31) = append (xs11, xs2) in (APPENDcons (pf1) | cons (x1, xs31)) end // end of [cons] | nil () => (APPENDnil () | xs2) // end of [append] (* ****** ****** *) propdef MUNION (xs1:ilist, xs2:ilist, xs3:ilist) = {x0:int} {n1,n2:nat} (MSETCNT (x0, xs1, n1), MSETCNT (x0, xs2, n2)) - MSETCNT (x0, xs3, n1+n2) // end of [MUNION] extern prfun append_munion_lemma {xs,ys,zs:ilist} (pf: APPEND (xs,ys,zs)): MUNION (xs, ys, zs) // end of [append_munion_lemma] implement append_munion_lemma (pf) = lemma (pf) where { prfun lemma {xs,ys,zs:ilist} .. (pf: APPEND (xs,ys,zs)): MUNION (xs, ys, zs) = case+ pf of | APPENDcons (pf) => let prval fpf = lemma (pf) in lam (pf1, pf2) => let prval MSETCNTcons pf1 = pf1 in MSETCNTcons (fpf (pf1, pf2)) end // end of [lam] end (* end of [APPENDcons] *) | APPENDnil () => lam (pf1, pf2) => let prval MSETCNTnil () = pf1 in pf2 end // end of [lam] (* end of [APPENDnil] *) // end of [lemma] } // end of [append_munion_lemma] (* ****** ****** *) propdef PART ( x: int, xs0: ilist, xs1: ilist, xs2: ilist, xs: ilist ) = {x0:int} {n0,n1,n2:nat} ( MSETCNT (x0, xs0, n0), MSETCNT (x0, xs1, n1), MSETCNT (x0, xs2, n2) ) - MSETCNT (x0, xs, n0+n1+n2+b2i(x0==x)) // end of [PART] fun{a:t@ype} qsrt {xs:ilist} ( xs: list (a, xs) ) : [ys:ilist] (PERMUTE (xs, ys) | list (a, ys)) = case+ xs of | cons {x} {xs1} (x, xs1) => let val [ys:ilist] (fpf | ys) = part (x, xs1, nil (), nil ()) prval fpf = lam {x0:int} {n:nat} (pf: MSETCNT (x0, xs, n)): MSETCNT (x0, ys, n) = let prval MSETCNTcons pf = pf in fpf (pf, MSETCNTnil, MSETCNTnil) end // end of [prval] in (fpf | ys) end // end of [cons] | nil () => (permute_refl {ilist_nil} () | nil ()) // end of [qsrt] and part {x:pos} {xs,xs1,xs2:ilist} ( x: E (a, x) , xs: list (a, xs) , xs1: list (a, xs1) , xs2: list (a, xs2) ) : [ys:ilist] (PART (x, xs, xs1, xs2, ys) | list (a, ys)) = case xs of | cons (x_, xs_) => ( if (x_ <= x) then let val [ys:ilist] (fpf | ys) = part (x, xs_, cons (x_, xs1), xs2) prval fpf = lam {x0:int} {n0,n1,n2:nat} (pf0: MSETCNT (x0, xs, n0), pf1: MSETCNT (x0, xs1, n1), pf2: MSETCNT (x0, xs2, n2)) : MSETCNT (x0, ys, n0+n1+n2+b2i(x0==x)) = let prval MSETCNTcons pf0 = pf0 prval pf1 = MSETCNTcons (pf1) in fpf (pf0, pf1, pf2) end // end of [prval] in (fpf | ys) end else let val [ys:ilist] (fpf | ys) = part (x, xs_, xs1, cons (x_, xs2)) prval fpf = lam {x0:int} {n0,n1,n2:nat} (pf0: MSETCNT (x0, xs, n0), pf1: MSETCNT (x0, xs1, n1), pf2: MSETCNT (x0, xs2, n2)) : MSETCNT (x0, ys, n0+n1+n2+b2i(x0==x)) = let prval MSETCNTcons pf0 = pf0 prval pf2 = MSETCNTcons (pf2) in fpf (pf0, pf1, pf2) end // end of [prval] in (fpf | ys) end // end of [let] ) // end of [cons] | nil () => let val [ys1:ilist] (fpf1 | ys1) = qsrt (xs1) val [ys2:ilist] (fpf2 | ys2) = qsrt (xs2) val [ys:ilist] (pf3 | ys) = append (ys1, cons (x, ys2)) prval fpf3 = append_munion_lemma (pf3) prval fpf = lam {x0:int} {n0,n1,n2:nat} (pf0: MSETCNT (x0, xs, n0), pf1: MSETCNT (x0, xs1, n1), pf2: MSETCNT (x0, xs2, n2)) : MSETCNT (x0, ys, n0+n1+n2+b2i(x0==x)) = let prval MSETCNTnil () = pf0 prval pf1 = fpf1 (pf1) // pf1 : MSETCNT (x0, ys1, n1) prval pf2 = fpf2 (pf2) // pf2 : MSETCNT (x0, ys2, n2) in fpf3 (pf1, MSETCNTcons (pf2)) end // end of [prval] in (fpf | ys) end // end of [nil] // end of [part] (* ****** ****** *) implement{a} quicksort (xs) = qsrt (xs) (* ****** ****** *) implement lte_elt_elt {x,y} (x, y) = let val x = decode (x) and y = decode(y) extern castfn __cast (_: bool):<> bool (x <= y) in __cast (lte_double_double (x, y)) end // end of [lte_elt_elt] fn print_list ( xs: list (double) ) : void = let fun aux ( xs: list (double), i: int ) : void = begin case+ xs of | cons (x, xs) => let val x = decode (x) in if i > 0 then print ", "; printf ("%.2f", @(x)); aux (xs, i+1) end // end of [cons] | nil () => () end // end of [aux] in aux (xs, 0) end // end of [print_list] fun randgen_list {n:nat} .. (n: int n): list (double) = if n > 0 then let val x = drand48 () val x = encode (x) in cons {double} (x, randgen_list (n-1)) end else nil () // end of [randgen_list] (* ****** ****** *) implement main () = let // val () = srand48_with_time () // val xs = randgen_list (20) val () = (print "xs = "; print_list xs; print_newline ()) val (_fpf | ys) = quicksort (xs) val () = (print "ys = "; print_list ys; print_newline ()) in // nothing end // end of [main] (* ****** ****** *) (* end of [quicksort2_list.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/curve.dats0000664000175000017500000000425012223166161020371 0ustar hwxihwxi(* ** ** Given a line segment BC. Find the locus of the point A such that there ** exists a unique point D for A satisfying: 1) BC bisects AD and 2) ABCD ** are cyclic ** Assume |BC| = K + K ** r = sqrt (K^2 + t^2) ** x^2 + y^2 = r^2; y = r - t ** This leads to: ** 4(x^2+y^2)y^2 = (y^2 + k^2)^2 ** *) (* ****** ****** *) // Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) // 28 December 2008: (* ****** ****** *) staload "libc/SATS/math.sats" (* #define K 20.0 #define K2 K * K fn printrow (y: double): void = let val y2 = y * y val y2K2 = (y2 + K2) val rhs = y2K2 * y2K2 val x2 = rhs / (4.0 * y2) - y2 val x = sqrt (x2) var i: double // uninitialized in for (i := 0.0; i <= x; i := i + 1.0) print '*'; print '\n' end // end of [printrow] fn printrows (Y: double): void = let var y: double // uninitialized in for (y := Y; 2.0 <= y; y := y - 1.0) printrow y; print_newline () end // end of [printrows] implement main (argc, argv) = printrows (K) *) (* ****** ****** *) #define K 20.0 #define K2 K * K fn printbyte (X: double, x: double, i: double): void = let var b: byte = byte_of_int 0 var j: double val () = for (j := 0.0; j < 8.0; j := j + 1.0) let val ij = i + j val () = if ij >= X then break val () = b := b << 1 in if ij < x then (b := b + byte_of_int 1) end // end of [val] in print b end // end of [printbyte] fn printrow (X: double, y: double): void = let val y2 = y * y val y2K2 = (y2 + K2) val rhs = y2K2 * y2K2 val x2 = rhs / (4.0 * y2) - y2 val x = sqrt (x2) var i: double // uninitialized in for (i := 0.0; i < X; i := i + 8.0) printbyte (X, x, i); end // end of [printrow] fn printrows (X:double, Y: double): void = let var y: double // uninitialized in for (y := Y; y >= 1.0; y := y - 1.0) printrow (X, y); end // end of [printrows] implement main (argc, argv) = let val I = if! (argc >= 2, int_of_string argv.[1], 0): int // end of [val] val k = (if I > 0 then double_of_int I else K): double val X = 8 * k and Y = k val () = begin printf ("P4\n%i %i\n", @(int_of X, int_of Y)); printrows (X, Y); end // end of [val] in // empty end // end of [main] (* end of [curve.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/isqrt.dats0000664000175000017500000000522112223166161020406 0ustar hwxihwxi(* ** A verfied implementation of the integer sqare root function ** that is non-tail-recursive and of logarithmic time complexity ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: November, 2009 *) (* ****** ****** *) propdef ISQRT (x: int, n: int) = [x0,x1:nat | x0 <= x; x < x1] (MUL (n, n, x0), MUL (n+1, n+1, x1)) // end of [SQRT] extern prfun ISQRT_4_lemma {x:nat} {n2:nat} (pf: ISQRT (x/4, n2)): [n:int | 2*n2 <= n; n <= 2*n2+1] ISQRT (x, n) // end of [ISQRT_4_lemma] implement ISQRT_4_lemma // nonrec {x} {n2} ([x0:int,x1:int] pf) = let prval pf0 = pf.0 // MUL (n2, n2, x0) // x0 <= x/4 prval pf1 = pf.1 // MUL (n2+1, n2+1, x1) // x/4 < x1 prval pf1_alt = mul_expand_linear {1,1} {1,1} (pf0) prval () = mul_isfun (pf1, pf1_alt) stadef n_1 = n2 + n2 stadef n_2 = n_1 + 1 and n_3 = n_1 + 2 prval pf0_1 = mul_expand_linear {2,0} {2,0} (pf0) stadef x_2 = 4 * x0 + 4 * n2 + 1 prval pf0_2 = mul_expand_linear {1,1} {1,1} (pf0_1) prval pf0_3 = mul_expand_linear {1,2} {1,2} (pf0_1) in sif (x < x_2) then #[n_1 | (pf0_1, pf0_2)] else #[n_2 | (pf0_2, pf0_3)] end // end of [ISORT_4_lemma] (* ****** ****** *) extern // 10 points fun isqrt {x:nat} (x: int x):<> [n:nat] (ISQRT (x, n) | int n) // end of [isqrt] implement isqrt (x) = let fun aux {x:nat}.. // non-tail-recursive (x: int x):<> [n:nat] (ISQRT (x, n) | int n) = if x > 0 then let val x4 = x / 4 val [n2:int] (pf4 | n2) = aux (x4) prval [n:int] pf = ISQRT_4_lemma {x} {n2} (pf4) val n_1 = n2 + n2 val n_2 = n_1 + 1 val (pf_mul | x1) = op imul2 (n_2, n_2) in if x < x1 then let prval () = ( sif (n==2*n2) then () else let prval () = mul_isfun (pf_mul, pf.0) in (*nothing*) end // end of [sif] ) : [n==2*n2] void in (pf | n_1) end else let prval () = ( sif (n==2*n2+1) then () else let prval () = mul_isfun (pf_mul, pf.1) in (*nothing*) end // end of [sif] ) : [n==2*n2+1] void in (pf | n_2) end // end of [if] end else let prval pf0_mul = mul_istot {0,0} () prval () = mul_elim pf0_mul prval pf1_mul = mul_istot {1,1} () prval () = mul_elim pf1_mul in ((pf0_mul, pf1_mul) | 0) end // end of [if] in aux (x) end // end of [isqrt] (* ****** ****** *) val ans = isqrt 1023 val () = printf ("isqrt(1023) = %i\n", @(ans.1)) val ans = isqrt 1024 val () = printf ("isqrt(1024) = %i\n", @(ans.1)) val ans = isqrt 1025 val () = printf ("isqrt(1025) = %i\n", @(ans.1)) (* ****** ****** *) implement main () = () (* ****** ****** *) (* end of [isqrt.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/fft.dats0000664000175000017500000005620712223166161020035 0ustar hwxihwxi (* ** ** This is a primitive irrational-base discrete weighted transform taken ** from pseudocode found in: "Prime Numbers: A Computational Perspective" ** ** The code was originally written by Rick Lavoie and translated to ATS ** by Hongwei Xi (November, 2005) ** ** Absolutely no optimization has gone into this code; written for clarity, ** not speed. ** *) (* ** ** The code is ported to ATS/Geizella by Hongwei Xi (July 2007) ** ** test: 2 ^ 44497 - 1 is a prime! (BITSIZE = 16) ** time: 357.479u 0.234s 5:59.57 99.4% 0+0k 0+0io 0pf+0w ** ** test: 2 ^ 110503 - 1 is a prime! (BITSIZE = 16) ** time: 2171.782u 2.094s 36:18.67 99.7% 0+0k 0+0io 0pf+0w ** *) (* ****** ****** *) %{^ static inline ats_double_type double_of_double (ats_double_type x) { return x ; } %} // end of [%{^] (* ****** ****** *) staload "libc/SATS/math.sats" staload "libc/SATS/stdio.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) typedef real = double macdef PI = 3.1415926535897932384626 extern fun real_of_double (d: double):<> real = "double_of_double" #define d2r real_of_double // This is an experimental effort to differentiate imaginary from real abst@ype imag = $extype "ats_double_type" extern fun imag_of_double (d: double):<> imag = "double_of_double" #define d2i imag_of_double extern fun add_imag_imag (x: imag, y: imag): imag = "atspre_add_double_double" overload + with add_imag_imag extern fun sub_imag_imag (x: imag, y: imag): imag = "atspre_sub_double_double" overload - with sub_imag_imag extern fun mul_imag_imag (x: imag, y: imag): real = "atspre_mul_double_double" extern fun mul_real_imag (x: real, y: imag): imag = "atspre_mul_double_double" extern fun mul_imag_real (x: imag, y: real): imag = "atspre_mul_double_double" overload * with mul_imag_imag overload * with mul_real_imag overload * with mul_imag_real // #define i2d double_of_int // fn compute_signal_sum {n:nat} {l:addr} (pf: !array_v (real, n, l) | A: ptr l, n: int n): real = let fun loop {i:nat | i <= n} .. ( pf: !array_v (real, n, l) | i: int i, res: real ) : real = if i < n then loop (pf | i+1, res + A[i]) else res in loop (pf | 0, d2r 0.0) end // end of [compute_signal_sum] fn convolve_signal {n:nat} {l_r,l_i:addr} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) | R: ptr l_r, I: ptr l_i, n: int n): void = let fun loop {i:nat | i <= n} .. ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | i: int i ) : void = if i < n then let val t_r = R[i] and t_i = I[i] val t_rr = t_r * t_r and t_ii = t_i * t_i and t_ri = t_r * t_i in R[i] := t_rr - t_ii; I[i] := t_ri + t_ri; loop (pf_r, pf_i | i+1) end else begin // this is empty end in loop (pf_r, pf_i | 0) end // end of [convolve_signal] fn round_signal {n:nat} {l_r,l_i:addr} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) | R: ptr l_r, I: ptr l_i, n: int n): void = let fun loop {i:nat | i <= n} .. ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | i: int i ) : void = if i < n then begin R[i] := floor (R[i] + d2r 0.5); I[i] := d2i (0.0); loop (pf_r, pf_i | i+1) end in loop (pf_r, pf_i | 0) end // end of [round_signal] // fun forward_fft {n:nat} {l_r, l_i, l_w:addr} (pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) , pf_w: !array_v (real, n, l_w) | R: ptr l_r, I: ptr l_i, W: ptr l_w, n: int n): real = let fun aux0 {i:nat | i <= n} .. ( pf_r: !array_v (real, n, l_r) , pf_w: !array_v (real, n, l_w) | i: int i ) : void = begin if i < n then (R[i] := R[i] * W[i]; aux0 (pf_r, pf_w | i+1)) else () end fun aux1 {i,m:nat} ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | i: int i, m: int m, a_r: real, a_i: imag ) : void = let val im = i + m in if im < n then let val t1_r = R[im] and t1_i = I[im] val t2_r = R[i] and t2_i = I[i] val () = R[i] := t2_r + t1_r and () = I[i] := t2_i + t1_i val t1_r = t2_r - t1_r and t1_i = t2_i - t1_i val () = R[im] := a_r * t1_r - a_i * t1_i val () = I[im] := a_r * t1_i + a_i * t1_r in aux1 (pf_r, pf_i | im + m, m, a_r, a_i) end else begin // this is empty end end // end of [aux1] fun aux2 {j,m:nat} ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | j: int j, m: int m ) : void = if j < m then let val theta = d2r (PI * (i2d j) / (i2d m)) in aux1 (pf_r, pf_i | j, m, d2r (cos theta), d2i ~(sin theta)); aux2 (pf_r, pf_i | j+1, m) end fun aux3 {m:nat} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) | m: int m) : void = if m >= 1 then (aux2 (pf_r, pf_i | 0, m); aux3 (pf_r, pf_i | nhalf m)) val () = aux0 (pf_r, pf_w | 0) val sum = compute_signal_sum (pf_r | R, n) in aux3 (pf_r, pf_i | nhalf n); sum end // end of [forward_fft] // fun inverse_fft {n:nat} {l_r, l_i, l_w:addr} (pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) , pf_w: !array_v (real, n, l_w) | R: ptr l_r, I: ptr l_i, W: ptr l_w, n: int n): real = let fun aux1 {i,m:nat} ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | i: int i, m: int m, a_r: real, a_i: imag ) : void = let val im = i + m in if im < n then let val c_r = R[im] and c_i = I[im] val t1_r = c_r * a_r - c_i * a_i and t1_i = c_r * a_i + c_i * a_r val t2_r = R[i] and t2_i = I[i] val () = R[i] := t2_r + t1_r and () = I[i] := t2_i + t1_i val () = R[im] := t2_r - t1_r and () = I[im] := t2_i - t1_i in aux1 (pf_r, pf_i | im + m, m, a_r, a_i) end end fun aux2 {j,m:nat} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) | j: int j, m: int m): void = if j < m then let val theta = d2r (PI * (i2d j) / (i2d m)) in aux1 (pf_r, pf_i | j, m, d2r (cos theta), d2i (sin theta)); aux2 (pf_r, pf_i | j+1, m) end fun aux3 {m:nat} ( pf_r: !array_v (real, n, l_r) , pf_i: !array_v (imag, n, l_i) | m: int m ) : void = if m < n then (aux2 (pf_r, pf_i | 0, m); aux3 (pf_r, pf_i | m+m)) fun aux4 {i:nat | i <= n} ( pf_r: !array_v (real, n, l_r) | i: int i, nf: real ) : void = if i < n then (R[i] := R[i] / nf; aux4 (pf_r | i+1, nf)) fun aux5 {i:nat | i <= n} ( pf_r: !array_v (real, n, l_r) , pf_w: !array_v (real, n, l_w) | i: int i ) : void = begin if i < n then (R[i] := R[i] / W[i]; aux5 (pf_r, pf_w | i+1)) else () end val () = aux3 (pf_r, pf_i | 1) val () = aux4 (pf_r | 0, d2r (i2d n)) val sum = compute_signal_sum (pf_r | R, n) val () = aux5 (pf_r, pf_w | 0) in sum end // end of [inverse_fft] // fun modular_reduce {n:nat} {l_r,l_b:addr} (pf_r: !array_v (real, n, l_r), pf_b: !array_v (real, n, l_b) | R: ptr l_r, B: ptr l_b, n: int n): void = let fun aux1 {i:nat | i <= n} ( pf_r: !array_v (real, n, l_r) , pf_b: !array_v (real, n, l_b) | i: int i, carry: real ) : real = if i < n then let val temp = R[i] + carry val bi = B[i] val () = R[i] := fmod (temp, bi) in aux1 (pf_r, pf_b | i+1, floor (temp / bi)) end else begin carry // return value end // end of [if] fun aux2 {i:nat | i <= n} ( pf_r: !array_v (real, n, l_r) , pf_b: !array_v (real, n, l_b) | i: int i, carry: real ) : void = if i < n then if carry = d2r 0.0 then () else let val temp = R[i] + carry val bi = B[i] val () = R[i] := fmod (temp, bi) in aux2 (pf_r, pf_b | i+1, floor (temp / bi)) end else begin aux2 (pf_r, pf_b | 0, carry) end // end of [if] val carry = aux1 (pf_r, pf_b | 0, d2r 0.0) in aux2 (pf_r, pf_b | 0, carry) end // end of [modular_reduce] // fun subtract2 {n:nat} {l_r,l_b:addr} (pf_r: !array_v (real, n, l_r), pf_b: !array_v (real, n, l_b) | R: ptr l_r, B: ptr l_b, n: int n): void = let fun aux {i:nat | i <= n} ( pf_r: !array_v (real, n, l_r) , pf_b: !array_v (real, n, l_b) | i: int i, carry: real ) : void = if i < n then if carry = d2r 0.0 then () else let val ri = R[i] and bi = B[i] in if carry > ri then (R[i] := bi - carry + ri; aux (pf_r, pf_b | i+1, d2r 1.0)) else let val t = ri - carry in R[i] := fmod (t, bi); aux (pf_r, pf_b | i+1, floor (t / bi)) end end else begin // this is empty end // end of [if] // end of [if] in aux (pf_r, pf_b | 0, d2r 2.0) end // end of [substract2] // #define BITSIZE 16 fun compute_optimal_signal_size (exponent: Nat): intGt 0 = let fun aux (i: Nat, p: intGt 0): intGt 0 = if i < BITSIZE then p else aux (nhalf i, p + p) in aux (exponent, 1) end // fun compute_base_signal {n:nat} {l_b:addr} ( pf_b: !array_v (real, n, l_b) | B: ptr l_b, exponent: Nat, n: int n ): void = let fun aux {i:nat | i <= n} (pf_b: !array_v (real, n, l_b) | i: int i): void = if i < n then let val e = i2d exponent val en = e / (i2d n) val eni = en * (i2d i) in B[i] := pow (d2r 2.0, d2r (ceil (eni + en) - ceil (eni))); aux (pf_b | i+1) end // end of [if] in aux (pf_b | 0) end // end of [compute_base_signal] // fun compute_weight_signal {n:nat} {l_w:addr} ( pf_w: !array_v (real, n, l_w) | W: ptr l_w, exponent: Nat, n: int n ) : void = let fun aux {i:nat | i <= n} .. (pf_w: !array_v (real, n, l_w) | i: int i): void = if i < n then let val e = i2d exponent val en = e / (i2d n) val eni = en * (i2d i) in W[i] := pow (d2r 2.0, d2r (ceil eni - eni)); aux (pf_w | i+1) end in aux (pf_w | 0) end // end of [compute_weight_signal] // fun check_zero_signal {n:nat} {l:addr} (pf: !array_v (real, n, l) | A: ptr l, n: int n): bool = let fun aux {i:nat | i <= n} .. (pf: !array_v (real, n, l) | i: int i): bool = if i < n then (if A[i] = d2r 0.0 then aux (pf | i+1) else false) else true in aux (pf | 0) end // end of [check_zero_signal] // fun do_iteration {n:nat} {l_r,l_i,l_b,l_w:addr} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) , pf_b: !array_v (real, n, l_b), pf_w: !array_v (real, n, l_w) | R: ptr l_r, I: ptr l_i, B: ptr l_b, W: ptr l_w, n: int n): void = let val sum_in = forward_fft (pf_r, pf_i, pf_w | R, I, W, n) val () = convolve_signal (pf_r, pf_i | R, I, n) val sum_out = inverse_fft (pf_r, pf_i, pf_w | R, I, W, n) val diff = abs (sum_in * sum_in - sum_out) in if diff > d2r 1.0 then begin print "Possible error: difference = "; print diff; print_newline () end; round_signal (pf_r, pf_i | R, I, n); modular_reduce (pf_r, pf_b | R, B, n); subtract2 (pf_r, pf_b | R, B, n) end // end of [do_iteration] #define STRIDE 100 fun main_loop {n:nat} {l_r,l_i,l_b,l_w:addr} (pf_r: !array_v (real, n, l_r), pf_i: !array_v (imag, n, l_i) , pf_b: !array_v (real, n, l_b), pf_w: !array_v (real, n, l_w) | R: ptr l_r, I: ptr l_i, B: ptr l_b, W: ptr l_w, n: int n, i: Nat, limit: Nat): void = if i < limit then begin if (i mod STRIDE = 0) then (print '.'; fflush_stdout ()); do_iteration (pf_r, pf_i, pf_b, pf_w | R, I, B, W, n); main_loop (pf_r, pf_i, pf_b, pf_w | R, I, B, W, n, i+1, limit) end // end of [if] // Here are the first few Mersenne primes: // 2, 3, 5, 7, 13, 17, 19, 31, 61, 89, 107, 127, 521, 607, // 1279, 2203, 2281, 3217, 4253, 4423, 9689, 9941, 11213, // 19937, 21701, 23209, 44497, 86243, 110503, 132049, 216091, // 756839, 859433, 1257787, 1398269, 2976221, 3021377, 6972593, // 13466917, ... (* ****** ****** *) (* implement{a} array_ptr_alloc (n) = array_ptr_alloc_tsz {a} (n, sizeof) *) staload _(*anonymous*) = "prelude/DATS/array.dats" (* ****** ****** *) // The following function tests whether 2^exponent-1 is a prime: fun is_mersenne_prime (exponent: intGte 2): bool = let val n = compute_optimal_signal_size (exponent) val n_sz = size1_of_int1 n val (pf_gc_r, pf_r | R) = array_ptr_alloc (n_sz) val () = array_ptr_initialize_elt (!R, n_sz, d2r 0.0) val (pf_gc_i, pf_i | I) = array_ptr_alloc (n_sz) val () = array_ptr_initialize_elt (!I, n_sz, d2i 0.0) val (pf_gc_b, pf_b | B) = array_ptr_alloc (n_sz) val () = array_ptr_initialize_elt (!B, n_sz, d2r 0.0) val (pf_gc_w, pf_w | W) = array_ptr_alloc (n_sz) val () = array_ptr_initialize_elt (!W, n_sz, d2r 0.0) val () = compute_base_signal (pf_b | B, exponent, n) val () = compute_weight_signal (pf_w | W, exponent, n) val () = R[0] := d2r 4.0 val () = main_loop (pf_r, pf_i, pf_b, pf_w | R, I, B, W, n, 0, exponent - 2) val () = print_newline () val ans = check_zero_signal (pf_r | R, n) in array_ptr_free {real?} (pf_gc_r, pf_r | R); array_ptr_free {imag?} (pf_gc_i, pf_i | I); array_ptr_free {real?} (pf_gc_b, pf_b | B); array_ptr_free {real?} (pf_gc_w, pf_w | W); ans end // end of [is_mersenne_prime] // fn usage (): void = begin print "A natural number argument >= 2 is needed."; print_newline () end implement main (argc, argv) = let val () = if argc <= 1 then (usage (); exit {void} (1)) val () = assert (argc > 1) val exp = int1_of (argv.[1]) val () = if exp <= 1 then (usage (); exit {void} (1)) val () = assert (exp > 1) in if is_mersenne_prime exp then begin printf ("2 ^ %i - 1 is a prime!\n", @(exp)) end else begin printf ("2 ^ %i - 1 is a composite.\n", @(exp)) end // end of [if] end // end of [main] //// /* FFT.c Very primitive implementation of the irrational-base discrete weighted transform. Written by Rick Lavoie Taken from pseudocode found in "Prime Numbers: A Computational Perspective" Absolutely no optimization has gone into this code. It's written for clarity, not speed. */ #include #include #include #include #define PI 3.1415926535897932384626 // Displays the contents of a signal int display_signal(double* real, double* imag, unsigned int signal_size) { unsigned int i; if (imag == NULL) { // Pass NULL as the second parameter if we just want the real part for (i = 0; i < signal_size; i++) printf("%.2f ", real[i]); } else { for (i = 0; i < signal_size; i++) printf("%.2f+%.2fi ", real[i], imag[i]); } printf("\n"); return 0; } // Adds together the values of a signal. Used for error-checking double compute_signal_sum(double* real, unsigned int signal_size) { unsigned int i; double running_total = 0.0; for (i = 0; i < signal_size; i++) running_total += real[i]; return running_total; } // Computes the forward fast fourier transform of a complex signal. Uses Gentleman-Sande decimation // in frequency variant. weight is a weight signal, and signal_size is the size of the signal. real // and imag are the signal to be transformed. Bitscrambling is not done. double forward_fast_fourier(double* real, double* imag, double* weight, unsigned int signal_size) { unsigned int m, j, i; double a_real, a_imag, temp1_real, temp1_imag, temp2_real, temp2_imag; double sum; for (m = 0; m < signal_size; m++) // Initially multiply the input by the weights real[m] *= weight[m]; sum = compute_signal_sum(real, signal_size); // Taken straight from "Prime Numbers" for (m = signal_size/2; m >= 1; m = m/2) { for (j = 0; j < m; j++) { a_real = cos((2.0*PI*j*signal_size/(2*m))/signal_size); a_imag = -sin((2.0*PI*j*signal_size/(2*m))/signal_size); for (i = j; i < signal_size; i += 2*m) { temp1_real = real[i+m]; temp1_imag = imag[i+m]; temp2_real = real[i]; temp2_imag = imag[i]; real[i] = temp2_real + temp1_real; imag[i] = temp2_imag + temp1_imag; temp1_real = temp2_real - temp1_real; temp1_imag = temp2_imag - temp1_imag; real[i+m] = (a_real * temp1_real) - (a_imag * temp1_imag); imag[i+m] = (a_real * temp1_imag) + (a_imag * temp1_real); } } } return sum; } // Computes the inverse fast fourier transform. Uses Cooley-Turkey decimation in time. Parameters // are the same as the forward transform. Bitscrambling is not done, because the use of the two // different decimations cancels them out. double inverse_fast_fourier(double* real, double* imag, double* weight, unsigned int signal_size) { unsigned int m, j, i; double a_real, a_imag, temp1_real, temp1_imag, temp2_real, temp2_imag; double sum; for (m = 1; m < signal_size; m = 2*m) { for (j = 0; j < m; j++) { a_real = cos((2.0*PI*j*signal_size/(2*m))/signal_size); a_imag = sin((2.0*PI*j*signal_size/(2*m))/signal_size); for (i = j; i < signal_size; i += 2*m) { temp1_real = (real[i+m] * a_real) - (imag[i+m] * a_imag); temp1_imag = (real[i+m] * a_imag) + (imag[i+m] * a_real); temp2_real = real[i]; temp2_imag = imag[i]; real[i] = temp2_real + temp1_real; imag[i] = temp2_imag + temp1_imag; real[i+m] = temp2_real - temp1_real; imag[i+m] = temp2_imag - temp1_imag; } } } for (m = 0; m < signal_size; m++) // Divide by the signal_size to re-normalize the signal real[m] = real[m] / signal_size; sum = compute_signal_sum(real, signal_size); for (m = 0; m < signal_size; m++) // Adjust by the weights real[m] = real[m] / weight[m]; return sum; } // Convulves a transformed signal. IE, square the signal dyadically. int convulve_signal(double* real, double* imag, unsigned int signal_size) { unsigned int i; double temp_real, temp_imag; for (i = 0; i < signal_size; i++) { temp_real = real[i]; temp_imag = imag[i]; real[i] = (temp_real * temp_real) - (temp_imag * temp_imag); // Complex multiplication imag[i] = (temp_real * temp_imag) + (temp_real * temp_imag); } return 0; } // Rounds the floating point signal to closest integers. int round_signal(double* real, double* imag, unsigned int signal_size) { unsigned int i; // I'll eventually add a check to see if we're not rounding too far for (i = 0; i < signal_size; i++) real[i] = floor(real[i] + 0.5); return 0; } // Reduces the signal into their appropriate bases. base is the base signal. int modular_reduce(double* real, double* base, unsigned int signal_size) { unsigned int i; double carry = 0; double temp; for (i = 0; i < signal_size; i++) { temp = real[i] + carry; real[i] = fmod(temp, base[i]); carry = floor(temp/base[i]); } while (carry != 0) { for (i = 0; i < signal_size; i++) { if (carry == 0) break; temp = real[i] + carry; real[i] = fmod(temp, base[i]); carry = floor(temp/base[i]); } } return 0; } // Subtracts 2 from the signal. This is part of the Lucas-Lehmer test. This code won't work // if the base is less than 2. int subtract_2(double* real, double* base, unsigned int signal_size) { unsigned int i; double carry = 2; // Subtract 2 double temp; for (i = 0; i < signal_size; i++) { if (carry == 0) // No more carry, so we can exit early break; else if (carry > real[i]) { // If real[i] is less than the carry real[i] = base[i] - (carry - real[i]); carry = 1; } else { temp = real[i] - carry; // Subtract the carry real[i] = fmod(temp, base[i]); // Modular adjust carry = floor(temp/base[i]); // Get the carry } } return 0; } // Computes the optimal size of a signal, given an exponent unsigned int compute_optimal_signal_size(unsigned int exponent) { unsigned int temp = 1; // "Prime Numbers" says to find a signal_length such that Floor[2^(exponent/temp)] is // an "appropriate" size; while (1) { if ((double)exponent/temp < 16) // I have no clue how to decide what's an ideal bitsize break; // so I'm just using 16 bits and hope it's adequate temp *= 2; } return temp; } // Computes the base signal for an exponent int compute_base_signal(double* base, unsigned int exponent, unsigned int signal_size) { unsigned int i; // "Prime Numbers" says base[i-1] = 2^(Ceil[exponent*i/signal_size] - Ceil[exponent*(i-1)/signal_size]); // Running i from 1 to signal_size; for (i = 1; i <= signal_size; i++) base[i-1] = pow(2, ceil((double)exponent*i/signal_size)-ceil((double)exponent*(i-1)/signal_size)); return 0; } // Computes the weight signal for an exponent int compute_weight_signal(double* weight, unsigned int exponent, unsigned int signal_size) { unsigned int i; double temp; // "Prime Numbers" says weight[i] = 2^(Ceil[exponent*i/signal_size]-(exponent*i/signal_size)) for (i = 0; i < signal_size; i++) { temp = ((double)exponent*i)/signal_size; weight[i] = pow(2, ceil(temp) - temp); } return 0; } int check_zero_signal(double* signal, unsigned int signal_size) { int is_zero = 1; unsigned int i; for (i = 0; i < signal_size; i++) { if (signal[i] != 0) { is_zero = 0; break; } } return is_zero; } // Performs one Lucas-Lehmer iteration using the IBDWT algorithm int do_iteration(double* real, double* imag, double* weight, double* base, unsigned int signal_size) { double sum_in, sum_out, difference; // I know that you can "embed" the real signal into the complex, but for clarity I'm avoiding that sum_in = forward_fast_fourier(real, imag, weight, signal_size); // Square the elements convulve_signal(real, imag, signal_size); // Invert the signal sum_out = inverse_fast_fourier(real, imag, weight, signal_size); // What's the difference between sum_in^2 and sum_out difference = fabs((sum_in * sum_in) - sum_out); if (difference > 10) // Uh oh, an error, they're not matching printf("**POSSIBLE ERROR**: SUMIN and SUMOUT differ by %.2f\n", difference); // Round the signal to integers round_signal(real, imag, signal_size); memset(imag, 0, signal_size*sizeof(double)); // Modular reduce them to their variable base modular_reduce(real, base, signal_size); // Subtract 2 subtract_2(real, base, signal_size); return 0; } int main(int argc, char* argv[]) { double* real; // Real part of the signal double* imag; // Imaginary part of the signal unsigned int signal_size; // Signal length unsigned int exponent; // Exponent for the LL test (Change as needed) double* base; // Variable base of the signal double* weight; // Weight signal unsigned int i; exponent = atoi(argv[1]); // Find out the appropriate size for this exponent signal_size = compute_optimal_signal_size(exponent); // Allocate memory base = malloc(sizeof(double)*signal_size); weight = malloc(sizeof(double)*signal_size); real = malloc(sizeof(double)*signal_size); imag = malloc(sizeof(double)*signal_size); // Clear memory and compute the signals memset(real, 0, sizeof(double) * signal_size); memset(imag, 0, sizeof(double) * signal_size); compute_base_signal(base, exponent, signal_size); compute_weight_signal(weight, exponent, signal_size); real[0] = 4; // LL test starts with 4 for (i = 0; i < exponent-2; i++) { do_iteration(real, imag, weight, base, signal_size); if (i % 100 == 0) printf("%i\r\n", i); } if (check_zero_signal(real, signal_size) == 1) printf("PRIME!!!\n"); else printf("Not Prime\n"); // Clear memory free(base); free(weight); free(real); free(imag); return 0; } (* ****** ****** *) (* end of [fft.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/queens.dats0000664000175000017500000001165512223166161020554 0ustar hwxihwxi(* ** ** This is one of the first programs implemented in ATS. ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Summer, 2004 ** *) (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload "libc/SATS/stdlib.sats" staload "libc/SATS/time.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) // // HX: poor man's animation: solving the eight-queens puzzle // (* ****** ****** *) val clear = "" // clear the screen val home = "" // moving the the home position (upper left corner ) val cuu = "" // moving up val cud = "" // moving down #define PAUSE 0x1000 fun repeat {n:nat} .. (n: int n, f: !() - void): void = if n > 0 then (f (); repeat (n-1, f)) else () fun pause (npause: Nat): void = let fun loop (n: int): void = if n > 0 then let val err = usleep (PAUSE) in loop (n-1) end // end of [loop] in loop (1 << npause) end // end of [pause] fun print_spaces (n: Int): void = if n igt 0 then repeat (n, lam () => print " ") fun print_dots (n: Int): void = // print n dots if n igt 0 then repeat (n, lam () => print " .") fun print_board {s:nat} {l:addr} (pf: !array_v (Nat, s, l) | board: ptr l, len: int s): void = let fun aux {i:nat | i <= s} .. (pf: !array_v (Nat, s, l) | i: int i): void = if i < len then let val (qi: Nat) = board[i] in if qi igt 0 then begin print_dots (qi - 1); print " Q"; print_dots (len - qi); print_newline (); aux (pf | i + 1) end else begin print_dots len; print_newline (); aux (pf | i + 1) end // end of [if] end else begin print_newline () end // end of [if] in aux (pf | 0) end // end of [print_board] // fn board_make {sz:nat} ( sz: int sz ) :<> [l:addr] ( free_gc_v (int?, sz, l), array_v (Nat, sz, l) | ptr l ) = let val sz = size1_of_int1 sz val (pfgc, pfarr | p) = array_ptr_alloc (sz) // end of [val] var x: Nat = 0; val () = array_ptr_initialize_elt (!p, sz, x) // end of [val] in (pfgc, pfarr | p) end // end of [board_make] (* ****** ****** *) fun play {sz:int | sz > 0} ( npause: Nat, len: int sz ) : void = let // var nsol: Nat = 0 val [l:addr] (pf_gc, pf_board | board) = board_make (len) // fun test {i,j:nat | j <= i && i < sz} ( pf1: !array_v (Nat, sz, l) | j: int j, i: int i, qi: Nat ) : Bool = if j < i then let val (qj: Nat) = board[j] in if qi = qj then false else if iabs (qi - qj) = (i - j) then false else test (pf1 | j + 1, i, qi) end else begin true end // end of [if] (* end of [test] *) // fun loop {i:nat | i < sz} ( pf1: !array_v (Nat, sz, l), pf2: !Nat @ nsol | i: int i ) : void = let val next = board[i] + 1 in if next > len then let val () = board[i] := 0 in if i = 0 then begin repeat (len, lam () => (print_spaces (len); print_newline ())) end else begin loop (pf1, pf2 | i - 1) end end else let val () = board[i] := next in if test (pf1 | 0, i, next) then if (i + 1 = len) then let val () = nsol := nsol + 1 val () = print_board (pf1 | board, len) val () = begin print "The solution no. "; print nsol; print " is found!\n"; print_newline () end val () = pause npause val () = print_board (pf1 | board, len) val () = repeat (len + 1, lam () => print cuu) val () = pause npause in loop (pf1, pf2 | i) end else let val () = print_board (pf1 | board, len) val () = repeat (len + 1, lam () => print cuu) val () = pause npause in loop (pf1, pf2 | i + 1) end // end of [if] else begin loop (pf1, pf2 | i) end // end of [if] end // end of [if] end // end of [loop] // in // print (clear); loop (pf_board, view@ nsol | 0); array_ptr_free {int?} (pf_gc, pf_board | board); repeat (len, lam () => print cuu) // end // end of [play] (* ****** ****** *) fn prerr_usage (): void = begin print ("The board size needs to be positive!\n") end // end of [prerr_usage] (* ****** ****** *) implement main ( argc, argv ) = let var len: Nat = 8 var npause: Nat = 4 in // if argc >= 2 then let val i = atoi argv.[1] in len := max (4, int1_of_int i) end ; // if argc >= 3 then let val n = atoi argv.[2] in npause := min (max (0, int1_of_int n), 8) end ; // let val n = len in if n > 0 then let val start = time () val () = play (npause, n) val finish = time () val diff = difftime (finish, start) in printf ("The amount of time spent on this run is %.0f seconds.", @(diff)); print_newline () end else begin prerr_usage () // abnormal exit end // end of [if] end // end of [let] // end // end of [main] (* ****** ****** *) (* end of [queens.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/montecarlo.dats0000664000175000017500000000676212223166161021422 0ustar hwxihwxi// // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: June 8, 2009 // (* ****** ****** *) staload ARRAY2 = "libats/smlbas/SATS/array2.sats" typedef array2 (a:t@ype) = $ARRAY2.array (a) (* ****** ****** *) staload Math = "libc/SATS/math.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/array.dats" staload _(*anonymous*) = "libats/smlbas/DATS/array2.dats" (* ****** ****** *) typedef point = @(double, double) // flat representation fun square (x: double): double = x * x fun dist_pt_pt (pt1: point, pt2: point) = let val dx = pt1.0 - pt2.0 and dy = pt1.1 - pt2.1 in $Math.sqrt (dx * dx + dy * dy) end // end of [dist_pt_pt] (* ****** ****** *) // some params for this program #define N 1000 (* ****** ****** *) val NN: int = N * N val Nr: double = double_of_int (N) val epsilon: double = 1.0 / Nr (* ****** ****** *) typedef pointlst = list0 (point) val thePointlstArray = $ARRAY2.array (N, N, list0_nil) (* ****** ****** *) staload Rand = "libc/SATS/random.sats" extern fun rand_double (): double (* btw 0 and 1 *) // without the adjustment, [rand_double] may return 1.000000 implement rand_double () = $Rand.drand48 () * (1.0 - 1.0 / NN) (* ****** ****** *) extern fun do_one_square (pt: point, i: int, j: int): int implement do_one_square (pt, i, j) = let val i = int1_of_int (i); val () = assert (i >= 0); val i = size1_of_int1 (i) val j = int1_of_int (j); val () = assert (j >= 0); val j = size1_of_int1 (j) val pts = $ARRAY2.sub (thePointlstArray, i, j) fun loop (pt0: point, pts: pointlst, res: int): int = case+ pts of | list0_cons (pt, pts) => let val dist = dist_pt_pt (pt, pt0) in if dist >= epsilon then loop (pt0, pts, res) else loop (pt0, pts, res+1) end // end of [list0_cons] | list0_nil () => res // end of [loop] in loop (pt, pts, 0(*res*)) end (* end of [do_one_square] *) (* ****** ****** *) fun do_one_round (): int = res where { val px = rand_double () and py = rand_double () val pt = @(px, py) val Nx = int_of_double (N * px) val Ny = int_of_double (N * py) fun do_all_squares .<>. ( pt: point, Nx: int, Ny: int ) : int = res where { var i: int = 0 and j: int = 0; var res: int = 0 val () = for (i := Nx-1; i <= Nx+1; i := i+1) let val () = if i < 0 then continue else (if i >= N then break else ()) val () = for (j := Ny-1; j <= Ny+1; j := j+1) let val () = if j < 0 then continue else (if j >= N then break else ()) in res := res + do_one_square (pt, i, j) end (* end of [val] *) in // empty end (* end of [val] *) } (* end of [do_all_squares] *) val res = do_all_squares (pt, Nx, Ny) val Nx = int1_of_int Nx; val () = assert (Nx >= 0); val Nx = size1_of_int1 Nx val Ny = int1_of_int Ny; val () = assert (Ny >= 0); val Ny = size1_of_int1 Ny val pts = $ARRAY2.sub (thePointlstArray, Nx, Ny) val () = $ARRAY2.update (thePointlstArray, Nx, Ny, list0_cons (pt, pts)) } (* end of [do_one_round] *) fun do_all (): int = loop (0, 0(*res*)) where { fun loop (i: int, res: int): int = if i < NN then loop (i+1, res + do_one_round ()) else res // end of [loop] } // end of [do_all] (* ****** ****** *) dynload "libats/smlbas/DATS/array2.dats" (* ****** ****** *) implement main () = let val () = $Rand.srand48_with_time () val PI = 2.0 * do_all () / (N * (N - 1)) in printf ("PI = %.6f\n", @(PI)) end (* end of [main] *) (* ****** ****** *) (* end of [montecarlo.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/pi_lazy.dats0000664000175000017500000000264512223166161020722 0ustar hwxihwxi// // // using Euler's transform to compute the constant pi // // author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // // (* ****** ****** *) staload "prelude/DATS/lazy.dats" (* ****** ****** *) #define nil stream_nil #define cons stream_cons #define :: stream_cons (* ****** ****** *) stadef strcon = stream_con // pi/4 = 1/1 - 1/3 + 1/5 - 1/7 + ... fun pi_stream_con (c: double, sum: double, n: Pos): strcon double = sum :: pi_stream (~c, sum + (c / double_of n), n+2) and pi_stream (c: double, sum: double, n: Pos): stream double = $delay (pi_stream_con (c, sum, n)) fun euler_trans_con (xs0: stream double): strcon double = let val- x0 :: xs1 = !xs0 val- x1 :: xs2 = !xs1 val- x2 :: xs3 = !xs2 val x01 = x0 - x1 and x21 = x2 - x1 in (x2 - x21 * x21 / (x21 + x01)) :: euler_trans xs1 end // end of [euler_trans_con] and euler_trans (xs0: stream double): stream double = $delay (euler_trans_con xs0) fn pi_compute {n:nat} (n: int n): double = let fun loop {i:nat| i <= n} (n: int n, i: int i, xs: stream double): double = if i < n then loop (n, i+1, euler_trans xs) else stream_nth (xs, 0) in loop (n, 0, pi_stream (4.0, 0.0, 1)) end // end of [pi_compute] (* ****** ****** *) implement main (argc, argv) = let val pi = pi_compute (8) // pi_compute (10) gives nan in printf ("pi = %.13f\n", @(pi)) ; end // end of [main] (* ****** ****** *) (* end of [pi_lazy.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/myfind.dats0000664000175000017500000000632612223166161020541 0ustar hwxihwxi(* ** My own [find] function for traversing file trees. *) (* ****** ****** *) // // Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) // 14 February 2011: // (* ****** ****** *) staload "libc/SATS/dirent.sats" (* fun dirent_stream_vt_make_DIR {l_dir:addr} (pf: DIR @ l_dir | p: ptr l_dir): stream_vt (dirent) // end of [dirent_strean_vt_make_DIR] *) (* ****** ****** *) extern fun doit {l:agz} (dirname: string, name: !strptr l): void // end of [doit] fun myfind (dirname: string): void = let val (pf_dir | p_dir) = opendir_exn (dirname) val xs = dirent_stream_vt_make_DIR (pf_dir | p_dir) fun loop ( xs: stream_vt (dirent) ) : void = let val xs_con = !xs in case+ xs_con of | stream_vt_cons (!p_x, xs) => let val (fpf_name | name) = dirent_get_d_name (!p_x) val () = doit (dirname, name) prval () = fpf_name (name) val () = free@ {dirent} (xs_con) in loop (xs) end // end of [stream_vt_cons] | ~stream_vt_nil () => () end // end of [loop] val () = loop (xs) in // nothing end // end of [myfind] (* ****** ****** *) staload S = "libc/sys/SATS/stat.sats" staload T = "libc/sys/SATS/types.sats" staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) fun isexec (x: uint): bool = let val m = $T.uint_of_mode ($S.S_IXUSR) land (x) in if m > 0U then true else false end // end of [isexec] (* ****** ****** *) implement doit (dirname, basename) = let val basename = $UN.castvwtp1 {string} (basename) val () = case+ basename of | "." => () | ".." => () | name when test_file_isdir (basename) > 0 => let val fullname = sprintf ("%s/%s", @(dirname, basename)) val () = myfind ($UN.castvwtp1 {string} (fullname)) val () = strptr_free (fullname) in // nothing end // end of [_ when ...] | name => println! (dirname, "/", basename) // end of [val] in // nothing end // end of [doit] (* ****** ****** *) (* implement doit (dirname, basename) = let val fullname1 = sprintf ("%s/%s", @(dirname, basename)) where { val basename = $UN.castvwtp1 {string} (basename) } // end of [val] val fullname = $UN.castvwtp1 {string} (fullname1) val () = println! ("doit: fullname = ", fullname) val () = case+ $UN.castvwtp1 {string} (basename) of | "." => () | ".." => () | _ when test_file_isdir (fullname) > 0 => let val () = $S.chmod_exn (fullname, $T.mode_of_int (0755)) val () = myfind (fullname) in // nothing end // end of [_ when ...] | _ when test_file_islnk (fullname) > 0 => () | _ when test_file_isreg (fullname) > 0 => let val m = ( if test_file_mode (fullname, isexec) > 0 then 0755 else 0644 ) : int // end of [val] val () = $S.chmod_exn (fullname, $T.mode_of_int (m)) in // nothing end // end of [_ when ...] | _ => () // end of [_] // end of [val] val () = strptr_free (fullname1) in // nothing end // end of [doit] *) (* ****** ****** *) implement main (argc, argv) = let var dirname: string = "." val () = if argc >= 2 then dirname := argv.[1] in myfind (dirname) end // end of [main] (* ****** ****** *) (* end of [myfind.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/BlackScholes.dats0000664000175000017500000000502112223166161021577 0ustar hwxihwxi// // // An implementation of the Black-Scholes formula. The ATS code is // largely _translated_ from the C++ version by Espen Gaarder Haug // attached at the end of this file. // // Hongwei Xi (November 17 2007) // // staload "libc/SATS/math.sats" (* ****** ****** *) #define Pi 3.1415926535897932384626 // The cumulative normal distribution function fn CND (X: double): double = let val a1 = 0.31938153 val a2 = ~0.356563782 val a3 = 1.781477937 val a4 = ~1.821255978 val a5 = 1.330274429 val L = abs(X) val K = 1.0 / (1.0 + 0.2316419 * L) var w: double = a5 val () = w := (w + a4) * K val () = w := (w + a3) * K val () = w := (w + a2) * K val () = w := (w + a1) * K val () = w := 1.0 - 1.0 / sqrt (Pi + Pi) * exp (~(L * L / 2.0)) * w in if X < 0.0 then 1.0 - w else w end fn BlackScholes (CallPutFlag: char, S: double, X: double, T: double, r: double, v: double) : double = let val sqrt_T = sqrt T val d1= (log (S/X) + (r+v*v/2.0) * T) / (v * sqrt_T) val d2 = d1 - v * sqrt_T in case+ CallPutFlag of | 'c' => S * CND(d1) - X * exp(~r*T) * CND(d2) | 'p' => X * exp(~r * T) * CND(~d2) - S * CND (~d1) | _ => begin prerr "The value of [CallPutFlag] is illegal: "; prerr CallPutFlag; prerr_newline (); exit (1) end end // end of [BlackScholes] //// Black-Scholes in C++ By Espen Gaarder Haug C++: a bit harder than most other languages but very fast and powerful. After my opinion the Rolls Royce computer language for mathematical models where you need speed (for closed form solutions like Blacks-Scholes you are naturally doing fine in almost any language, but when it comes to large scale Monte Carlo C++ is really a plus). #ifndef Pi #define Pi 3.141592653589793238462643 #endif // The Black and Scholes (1973) Stock option formula double BlackScholes(char CallPutFlag, double S, double X, double T, double r, double v) { double d1, d2; d1=(log(S/X)+(r+v*v/2)*T)/(v*sqrt(T)); d2=d1-v*sqrt(T); if(CallPutFlag == 'c') return S *CND(d1)-X * exp(-r*T)*CND(d2); else if(CallPutFlag == 'p') return X * exp(-r * T) * CND(-d2) - S * CND(-d1); } // The cumulative normal distribution function double CND( double X ) { double L, K, w ; double const a1 = 0.31938153, a2 = -0.356563782, a3 = 1.781477937; double const a4 = -1.821255978, a5 = 1.330274429; L = fabs(X); K = 1.0 / (1.0 + 0.2316419 * L); w = 1.0 - 1.0 / sqrt(2 * Pi) * exp(-L *L / 2) * (a1 * K + a2 * K *K + a3 * pow(K,3) + a4 * pow(K,4) + a5 * pow(K,5)); if (X < 0 ){ w= 1.0 - w; } return w; } (* ****** ****** *) (* end of [BlackScholes.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/wc.dats0000664000175000017500000000611512223166161017660 0ustar hwxihwxi// // November, 2005: // A naive implementation of the wc program // This is one of the first examples written in ATS // // author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // // February, 2007: // ported to ATS/Geizella by Hongwei Xi staload "libc/SATS/stdio.sats" typedef two = [b:two] int b viewdef bytes_v (n:int, l:addr) = bytes n @ l extern fun array_byte_ptr_alloc {n:nat} (n: int n): [l:addr] (array_v (byte, n, l) | ptr l) = "ats_array_byte_ptr_make" and array_byte_ptr_free {n:nat} {l:addr} (pf: array_v (byte, n, l) | p: ptr l): void = "ats_array_byte_ptr_free" (* ****** ****** *) fn* wc_aux_1 {n:nat} {l_buf,l1,l2,l3:addr} (pf1: !Nat @ l1, pf2: !Nat @ l2, pf3: !Nat @ l3 | fil: &FILE r, buf: &bytes n, n: int n, inword: two, lc: ptr l1, wc: ptr l2, cc: ptr l3) : void = let val [m:int] m = fread_byte (file_mode_lte_r_r | buf, size1_of_int1 n, fil) val m = int1_of_size1 (m) (* val () = printf ("wc_aux_1: m = %i\n", @(m)) *) in if m > 0 then begin !cc := !cc + m; wc_aux_2 {n,m,m} (pf1, pf2, pf3 | fil, buf, n, m, m, inword, lc, wc, cc) end end // end of [wc_aux_1] and wc_aux_2 {n,m,i:nat | i <= m; m <= n} {l_buf,l1,l2,l3:addr} (pf1: !Nat @ l1, pf2: !Nat @ l2, pf3: !Nat @ l3 | fil: &FILE r, buf: &bytes n, n: int n, m: int m, i: int i, inword: two, lc: ptr l1, wc: ptr l2, cc: ptr l3): void = begin if i > 0 then let val c = char_of_byte buf.[m-i] in if c = '\n' then begin !lc := !lc + 1; !wc := !wc + inword; wc_aux_2 {n,m,i-1} (pf1, pf2, pf3 | fil, buf, n, m, i-1, 0, lc, wc, cc) end else if char_isalnum (c) then wc_aux_2 {n,m,i-1} (pf1, pf2, pf3 | fil, buf, n, m, i-1, 1, lc, wc, cc) else begin !wc := !wc + inword; wc_aux_2 {n,m,i-1} (pf1, pf2, pf3 | fil, buf, n, m, i-1, 0, lc, wc, cc) end end else begin wc_aux_1 {n} (pf1, pf2, pf3 | fil, buf, n, inword, lc, wc, cc) end end // end of [wc_aux_2] // #define BUFSZ 1024 fun wc (filename: string): (Nat, Nat, Nat) = let val (pf_fil | ptr_fil) = fopen_exn (filename, file_mode_r) val (pfopt | p_buf) = malloc_ngc (BUFSZ) val () = assert_errmsg (p_buf > null, #LOCATION) prval malloc_v_succ (pf_ngc, pf_buf) = pfopt prval () = pf_buf := bytes_v_of_b0ytes_v (pf_buf) var lc: Nat = 0 and wc: Nat = 0 and cc: Nat = 0 in wc_aux_1 ( view@ lc, view@ wc, view@ cc | !ptr_fil, !p_buf, BUFSZ, 0, &lc, &wc, &cc ); free_ngc (pf_ngc, pf_buf | p_buf); fclose_exn (pf_fil | ptr_fil); @(lc, wc, cc) end // end of [wc] // implement main (argc, argv) = let var i: Nat = 1 var lc_total: Nat = 0 var wc_total: Nat = 0 var cc_total: Nat = 0 in while (i < argc) let val filename = argv.[i] val (lc, wc, cc) = wc (filename) in lc_total := lc_total + lc; wc_total := wc_total + wc; cc_total := cc_total + cc; printf ("%i\t%i\t%i\t%s\n", @(lc, wc, cc, filename)); i := i + 1; end ; if argc > 2 then begin printf ("%i\t%i\t%i\ttotal\n", @(lc_total, wc_total, cc_total)) end ; end // end of [main] (* ****** ****** *) (* end of [wc.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/GaussElim.dats0000664000175000017500000001017312223166161021137 0ustar hwxihwxi(* ** ** An implementation of the Gaussian elimination algorithm in ATS ** The code is a direct translation from an earlier version written ** in DML, the predessor of ATS. ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: January, 2008 *) // staload _(*anonymous*) = "prelude/DATS/array.dats" // typedef matrix (a:t@ype, m: int, n:int) = array (array (a, n), m) fn{a:t@ype} sub2 {m,n:nat} (M: matrix (a, m, n), i: natLt m, j: natLt n): a = let val row = M[i] in row[j] end fn{a:t@ype} update2 {m,n:nat} (M: matrix (a, m, n), i: natLt m, j: natLt n, x: a): void = let val row = M[i] in row[j] := x end // overload [] with sub2 // overload [] with update2 (* ****** ****** *) // an example of [withtype] annotation: fn{a:t@ype} rowSwap (M, i, j) = let val tmp = M[i] in M[i] := M[j]; M[j] := tmp end withtype {m,n:nat} {i,j:nat | i < m; j < m} (matrix (a, m, n), int i, int j) - void fn norm {n,i:nat | i < n} (r: array(double, n), n: int n, i: int i): void = let val x = r[i]; val () = r[i] := 1.0 fun loop {k:nat | k <= n} (k: int k): void = if k < n then (r[k] := r[k] / x; loop (k+1)) else () in loop (i+1) end // end of [norm] fn rowElim {n,i:nat | i < n} (r: array(double, n), s: array(double, n), n: int n, i: int i) : void = let val x = s[i]; val () = s[i] := 0.0 fun loop {k:nat | k <= n} (k: int k): void = if k < n then (s[k] := s[k] - x * r[k]; loop (k+1)) else () in loop (i+1) end // end of [rowElim] fn rowMax {m,n,i:nat | i < m; i < n} (M: matrix (double, m, n), m: int m, i: int i) : natLt m = let val x = abs (sub2 (M, i, i)) fun loop {j,max:nat | max < j; j <= m} .. (j: int j, x: double, max: int max): natLt m = if j < m then let val y = abs (sub2 (M, j, i)) in if (y > x) then loop (j+1, y, j) else loop (j+1, x, max) end else begin max // the return value of the loop end in loop (i + 1, x, i) end // end of [rowMax] fn GaussElim {n:nat} (M: matrix (double, n, n+1), n: int n): void = let fun loop1 {i:nat | i <= n} .. (i: int i): void = begin if i < n then let val max = rowMax(M, n, i) val () = norm (M[max], n+1, i) val () = rowSwap (M, i, max) val () = loop2 (i+1) where { fun loop2 {j:nat | j <= n} .. (j: int j): void = if j < n then (rowElim (M[i], M[j], n+1, i); loop2 (j+1)) } // end of [where] in loop1 (i+1) end // end of [if] end // end of [loop1] in loop1 (0) end // end of [GaussElim] fun print_array {n,i,j:nat | i <= j; j <= n} .. (A: array (double, n), i: int i, j: int j): void = let fun loop {k:int | i < k; k <= j} (k: int k): void = if k < j then (print "\t"; print A[k]; loop (k+1)) else print_newline () in if i < j then (print A[i]; loop (i+1)) else print_newline () end // end of [print_array] fn print_matrix {m,n:nat} (M: matrix(double, m, n), m: int m, n: int n): void = let fun loop {i:nat | i <= m} .. (i: int i) : void = begin if i < m then let val row = M[i]; val () = print_array (row, 0, n) in loop (i+1) end // end of [if] end // end of [loop] in loop (0) end // end of [print_matrix] (* Here is a test *) implement main (argc, argv) = let val A0 = array_make_elt (4, 0.0) val M0: matrix (double, 3, 4) = array_make_elt (3, A0) val () = update2 (M0, 0, 0, 1.0) val () = update2 (M0, 0, 1, 1.0) val () = update2 (M0, 0, 2, 1.0) val () = update2 (M0, 0, 3, ~4.0) val () = M0[1] := array_make_elt (4, 0.0) val () = update2 (M0, 1, 0, ~2.0) val () = update2 (M0, 1, 1, 3.0) val () = update2 (M0, 1, 2, 1.0) val () = update2 (M0, 1, 3, 7.0) val () = M0[2] := array_make_elt (4, 0.0) val () = update2 (M0, 2, 0, 3.0) val () = update2 (M0, 2, 1, ~1.0) val () = update2 (M0, 2, 2, 2.0) val () = update2 (M0, 2, 3, 7.0) // (-9, -8, 13) is the solution to the 1st, 2nd and 3rd variables. in print "Before gaussian elimination:\n"; print_matrix (M0, 3, 4); GaussElim (M0, 3); print "After gaussian elimination:\n"; print_matrix (M0, 3, 4); end // end of [main] (* ****** ****** *) (* end of [GaussElim.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/systemf_programming_examples.dats0000664000175000017500000002167712223166161025253 0ustar hwxihwxi// // BU CAS CS 520: Principles of Programing Languages // Semester: Fall 2005 // (* ****** ****** *) // // Some programming examples in System F // By Hongwei Xi (November 2, 2005) // // HX-2010-08-12: // This code is updated to compile and run under ATS-0.2.1. Voila! // (* ****** ****** *) // // Implementing Church numerals in System F // typedef nat_f = {X:type} (X - X) - X - X // end of [nat_f] (* ****** ****** *) fn pair_get_fst {X,Y:type} '(x: X, _: Y):<> X = x fn pair_get_snd {X,Y:type} '(_: X, y: Y):<> Y = y (* ****** ****** *) typedef int = uintptr val _0 = uintptr_of_uint (0U) val _1 = uintptr_of_uint (1U) #define isucc succ_uintptr fun print_nat_f (n: nat_f): void = print (n {int} (lam x => isucc x) (_0)) (* ****** ****** *) val Z = (lam s => lam z => z): nat_f val S = lam (n: nat_f): nat_f = lam s => lam z => n(s)(s(z)) (* ****** ****** *) val zero = Z val one = S(zero) val two = S(one) val three = S(two) val four = S(three) val five = S(four) (* ****** ****** *) fn add (m: nat_f, n: nat_f):<> nat_f = m (S) (n) fn mul (m: nat_f, n: nat_f):<> nat_f = m {nat_f} (n S) (Z) fn pow (m: nat_f, n: nat_f):<> nat_f = n {nat_f-nat_f} (m {nat_f}) (S) (Z) (* ****** ****** *) val () = begin print_string "pow (3, 5) = "; print_nat_f (pow (three, five)); print_newline () end // end of [val] (* ****** ****** *) fn pred (n: nat_f):<> nat_f = let val z = '(zero, zero) val s = lam '(n1: nat_f, n2: nat_f): '(nat_f, nat_f) = '(S n1, n1) val '(_, res) = n {'(nat_f, nat_f)} s z in res end // end of [pred] (* ****** ****** *) fn fact (n: nat_f):<> nat_f = let typedef X = '(nat_f, nat_f) val z: X = '(one, one) val s = lam ('(x, y): X): X = '(S x, mul (x, y)) in pair_get_snd (n {X} (s) (z)) end // end of [fact] val () = begin print_string "fact (5) = "; print_nat_f (fact five); print_newline () end // end of [val] fun fib (n: nat_f): nat_f = let typedef X = '(nat_f, nat_f) val z: X = '(zero, one) val s = lam ('(x, y): X): X = '(y, add (x, y)) in pair_get_fst (n {X} (s) (z)) end val _ = begin print_string "fib (10) = "; print_nat_f (fib (add (five, five))); print_newline () end fn ack (m: nat_f):<> nat_f - nat_f = let val helper = lam (f: nat_f - nat_f) = lam (n: nat_f): nat_f = f (n {nat_f} (f) (one)) in m {nat_f - nat_f} helper (S) end // end of [ack] val () = begin print_string "ack (3, 5) = "; print_nat_f (ack three five); print_newline () end // end of [val] (* ****** ****** *) // // Implementing Lists in System F // typedef list_f (A: type) = {X:type} (X, (A, X) - X) - X // end of [[list_f] val Nil = lam {A:type}: list_f (A) => lam (n, c) => n val Cons = lam {A:type} (x: A, xs: list_f A): list_f A = lam (n, c) => c (x, xs (n, c)) // end of [Cons] val list_length = lam {A:type} (xs: list_f A): int => let val nil = _0 val cons = lam (_: A, i: int): int = succ i in xs {int} (nil, cons) end // end of [list_length] val list_append = lam {A:type} (xs: list_f A, ys: list_f A): list_f A => xs {list_f A} (ys, Cons{A}) // end of [list_append] val list_reverse = lam {A:type} (xs: list_f A): list_f A => let val nil = Nil {A} val cons = lam (x: A, xs: list_f A): list_f A = list_append (xs, Cons (x, Nil)) in xs {list_f A} (nil, cons) end // end of [list_reverse] (* ****** ****** *) (* // Please note that the above code make use of no recursion! *) (* ****** ****** *) // // The following is some test code: // // condef :: = cons // HX: 2010-08-12: this is what it was #define :: cons #define ipred pred_uintptr fun gen_list_f (i: Nat): list_f (int) = if i = 0 then Nil else Cons (uintptr_of_int1 i, gen_list_f (i - 1)) // end of [gen_list_f] typedef intlst = list0 int fun print_intlist (xs: intlst): void = case xs of | list0_nil () => print_newline () | list0_cons (x, xs) => print_intlist_aux (x, xs) // end of [print_intlist] and print_intlist_aux (x: int, xs: intlst): void = case xs of | list0_nil () => (print x; print_newline ()) | list0_cons (x', xs') => (print x; print_string ", "; print_intlist_aux (x', xs')) // end of [print_intlist_aux] fn print_list (xs: list_f int): void = let val nil = list0_nil () val cons = lam (x: int, xs: intlst): intlst = list0_cons (x, xs) in print_intlist (xs {intlst} (nil, cons)) end // end of [print_list] (* ****** ****** *) val () = let val xs = gen_list_f (5) val xs' = list_reverse xs val xsxs = list_append (xs, xs) val xsxs' = list_reverse xsxs in // print_string "xs = "; print_list xs; print_string "length (xs) = "; print (list_length xs); print_newline (); // print_string "xs' = "; print_list xs'; print_string "list_length (xs') = "; print (list_length xs'); print_newline (); // print_string "xsxs = "; print_list xsxs; print_string "length (xsxs) = "; print (list_length xsxs); print_newline (); // print_string "xsxs' = "; print_list xsxs'; print_string "length (xsxs') = "; print (list_length xsxs'); print_newline () end // end of [val] (* ****** ****** *) // // Implementing generic trees in System F // (* ****** ****** *) typedef gtree (A: type) = {X:type} (X, (A - X) - X) - X // E: {A:type} gtree (A) val E = lam {A:type}: gtree (A) => lam (e, b) => e val B = lam {A:type} (f: A - gtree A): gtree (A) = lam (e, b) => b (lam x => f (x) (e, b)) // end of [B] (* ****** ****** *) typedef A = int typedef btree = gtree (A) (* ****** ****** *) fn print_btree (t: btree): void = let typedef X = () - void val e = (lam () => print_string "E"): X val b = lam (f: (A - X)): X = lam () => begin // 0/1: left/right print_string "B("; f (_0) (); print_string ", "; f (_1) (); print_string ")" end (* end of [lam] *) // end of [b] in t {X} (e, b) () end // end of [print_btree] (* ****** ****** *) fn btree_size (t: btree):<> int = let typedef X = int val e = _0 val b = lam (f: (A - X)): X = isucc (f _1 + f _0) in t {X} (e, b) end // end of [btree_size] fn btree_height (t: btree):<> int = let typedef X = int val e = _0 val b = lam (f: (A - X)): X = max (f _1, f _0) + _1 in t {X} (e, b) end // end of [btree_height] fn btree_isperfect (t: btree):<> bool = let typedef X = Option int val e = (Some _0): X val b = lam (f: A - X): X = case+ (f _0, f _1) of | (Some h1, Some h2) => if h1 = h2 then Some (isucc h1) else None | (_, _) => None // end of [val] in case+ t {X} (e, b) of None () => false | Some _ => true end // end of [btree_isperfect] (* ****** ****** *) fn btree_left (t: btree):<> btree = let typedef X = '(btree, btree) val e = '(E, E): X val b = lam (f: (A - X)): X = let val '(t1, _) = f (_1); val '(t2, _) = f (_0) val f1 = lam (x: A): btree = if x > _0 then t1 else t2 in '(B {A} (f1), t2) end // end of [val] in pair_get_snd (t {X} (e, b)) end // end of [left_child_tree] fn btree_right (t: btree):<> btree = let typedef X = '(btree, btree) val e = '(E, E): X val b = lam (f: (A - X)): X = let val '(t1, _) = f (_1); val '(t2, _) = f (_0) val f1 = lam (x: A): btree = if x > _0 then t1 else t2 in '(B {A} (f1), t1) end // end of [val] in pair_get_snd (t {X} (e, b)) end // end of [right_child_tree] (* ****** ****** *) val t0 = E: btree val t1: btree = let val f = lam (x: int): btree = if x <= _0 then t0 else t0 in B {A} (f) end // end of [val] val t2: btree = let val f = lam (x: int): btree = if x <= _0 then t1 else t0 in B {A} (f) end // end of [val] val () = begin print_string "The tree t2 = "; print_btree t2; print_newline () end // end of [val] (* ****** ****** *) val t3: btree = let val f = lam (x: int): btree = if x <= _0 then t1 else t2 in B {A} (f) end // end of [val] val () = begin print_string "The tree t3 = "; print_btree t3; print_newline () end // end of [val] (* ****** ****** *) val isperfect = btree_isperfect (t1) val () = (print "isperfect(t1) = "; print isperfect; print_newline ()) val isperfect = btree_isperfect (t3) val () = (print "isperfect(t3) = "; print isperfect; print_newline ()) (* ****** ****** *) val t31: btree = btree_left (t3) val t32: btree = btree_right (t3) val () = begin print_string "The left subtree of t3 = "; print_btree t31; print_newline (); print_string "The right subtree of t3 = "; print_btree t32; print_newline (); end // end of [val] (* ****** ****** *) val s: int = btree_size (t3) val h: int = btree_height (t3) val () = begin print_string "The size of t3 = "; print s; print_newline (); print_string "The height of t3 = "; print h; print_newline (); end // end of [val] (* ****** ****** *) implement main () = () (* ****** ****** *) (* end of [systemf_programming_examples.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/hanoi.dats0000664000175000017500000000541412223166161020346 0ustar hwxihwxi// // // // Implementing the Hanoi Tower problem // The code was written by Hongwei Xi in the summer of 2004 // // // staload _(*anonymous*) = "prelude/DATS/array.dats" fn play {sz: pos} (sz: size_t sz): void = let typedef T = natLte sz macdef tsz = sizeof typedef post_t = array (T, sz) var x: T = 0 val leftPost = let val (pf_gc, pf | p) = array_ptr_alloc_tsz {T} (sz, sizeof) val () = array_ptr_initialize_elt_tsz {T} (!p, sz, x, tsz) in array_make_arrpsz {T} @(pf_gc, pf | p, sz) end // end of [val] val middlePost = let val (pf_gc, pf | p) = array_ptr_alloc_tsz {T} (sz, sizeof) val () = array_ptr_initialize_elt_tsz {T} (!p, sz, x, tsz) in array_make_arrpsz {T} @(pf_gc, pf | p, sz) end // end of [val] val rightPost = let val (pf_gc, pf | p) = array_ptr_alloc_tsz {T} (sz, sizeof) val () = array_ptr_initialize_elt_tsz {T} (!p, sz, x, tsz) in array_make_arrpsz {T} @(pf_gc, pf | p, sz) end // end of [val] fn initialize (post: post_t): void = let fun aux (i: natLte sz): void = if i < sz then (post[i] := i + 1; aux (i + 1)) in aux (0) end // end of [initialize] fn showpiece (n: natLte sz): void = let fun aux {i:nat | i <= 2 * sz} .<2*sz-i>. (i: int i): void = if i < (sz - n) then begin print ' '; aux (i + 1) end else if i < (sz + n - 1) then begin print 'O'; aux (i + 1) end else if i < (sz + sz) then begin print ' '; aux (i + 1) end in aux (0) end // end of [showpiece] fn showposts (): void = let fun aux (i: natLte sz): void = if i < sz then begin showpiece (leftPost[i]); showpiece (middlePost[i]); showpiece (rightPost[i]); print_newline (); aux (i + 1) end else begin print_newline () end in aux (0) end // end of [showposts] val () = initialize (leftPost) fun move { n,s,p,p':nat | p <= sz && p' <= sz && s + p + p' == sz + sz && 0 < n && s + n <= sz && n <= p && n <= p' } .. (n: int n, source: post_t, s: int s, post: post_t, p: int p, post': post_t, p': int p') : void = begin if n = 1 then begin post[p-1] := source[s]; source[s] := 0; showposts() end else begin move (n - 1, source, s, post', p', post, p); post[p- 1] := source[s+n-1]; source[s+n-1] := 0; showposts (); move (n - 1, post', p' - n + 1, post, p - 1, source, s + n) end end // end of [move] val sz_int = int1_of_size1 sz in showposts (); move (sz_int, leftPost, 0, rightPost, sz_int, middlePost, sz_int) end // end of [play] (* ****** ****** *) implement main (argc, argv) = play 4 (* ****** ****** *) (* end of [hanoi.dats] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/GarsiaWachs.dats0000664000175000017500000002712612223166161021450 0ustar hwxihwxi// // // An Implementation of the Garsia-Wachs Algorithm // // The code uses a doubly-linked list to support a technique that // is often dubbed Huet's "zipper" in functional programming. See // the attached ocaml code at the end for an application of "zipper" // // // Time: July 15, 2008 // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // %{^ typedef ats_ptr_type tree1 ; typedef struct treelst_struct { int weight ; tree1 tree ; struct treelst_struct *prev ; struct treelst_struct *next ; } *treelst ; // static inline void treelst_free (treelst ts) { ATS_FREE (ts) ; return ; } // static inline treelst TREELSTnil () { return (treelst)0 ; } static inline treelst TREELSTcons (int w, tree1 t, treelst ts) { treelst ts_new ; ts_new = ATS_MALLOC (sizeof(struct treelst_struct)) ; ts_new->weight = w ; ts_new->tree = t ; ts_new->prev = (treelst)0 ; ts_new->next = ts; if (ts) ts->prev = ts_new ; return ts_new ; } // extern tree1 Node1_make (tree1 t1, tree1 t2) ; // [ts] is required to be not null treelst combine_and_insert (treelst ts1, treelst ts2) { int w ; tree1 t ; treelst ts, ts_prev, ts_next, ts2_next ; /* fprintf (stderr, "combine_and_insert: ts1 = %p\n", ts1) ; fprintf (stderr, "combine_and_insert: ts2 = %p\n", ts2) ; */ w = ts1->weight + ts2->weight ; t = Node1_make (ts1->tree, ts2->tree) ; treelst_free (ts2) ; ts1->weight = w ; ts1->tree = t ; /* fprintf (stderr, "combine_and_insert: 1\n") ; */ ts = ts1->prev ; ts2_next = ts2->next ; if (ts == (treelst)0) { ts1->next = ts2_next ; if (ts2_next) ts2_next->prev = ts1 ; return ts1 ; } ts->next = ts2_next ; if (ts2_next) ts2_next->prev = ts ; while (1) { // [ts] is not null at this point! if (ts->weight >= w) { ts_next = ts->next ; ts->next = ts1 ; ts1->prev = ts ; ts1->next = ts_next ; if (ts_next) ts_next->prev = ts1 ; return ts ; } ts_prev = ts->prev ; if (ts_prev == (treelst)0) { ts1->prev = (treelst)0 ; ts1->next = ts ; ts->prev = ts1 ; return ts1 ; } ts = ts_prev ; } } /* end of [trans2_one] */ // static inline treelst trans2_one (treelst ts) { treelst ts1, ts2, ts3 ; ts1 = ts ; ts2 = ts1->next ; ts3 = ts2->next ; while (ts3) { /* fprintf (stderr, "trans2_one: ts1 = %p\n", ts1); fprintf (stderr, "trans2_one: ts2 = %p\n", ts2); fprintf (stderr, "trans2_one: ts3 = %p\n", ts3); */ if (ts1->weight <= ts3->weight) break ; ts1 = ts2; ts2 = ts3 ; ts3 = ts2->next ; } return combine_and_insert (ts1, ts2) ; } static inline tree1 trans2_all (treelst ts, int n) { tree1 t ; while (n >= 2) { ts = trans2_one (ts) ; n -= 1 ; } t = ts->tree ; treelst_free (ts) ; return t ; } %} (* ****** ****** *) typedef depth = Nat typedef weight = Nat typedef refdep = ref depth (* ****** ****** *) // // HX: // The function attaches a ref cell to each element in the input list // It also computes the length of the input list // fun{a:t@ype} trans0 {n:nat} (xws: list (@(a, weight), n), len: &int? >> int n) : list_vt (@(a, weight, refdep), n) = begin case+ xws of | list_cons (xw, xws) => let val r = ref_make_elt 0 val xwrs = trans0 (xws, len); val () = len := len + 1 in list_vt_cons (@(xw.0, xw.1, r), xwrs) end | list_nil () => (len := 0; list_vt_nil ()) end // end of [trans0] (* ****** ****** *) dataviewtype tree1 (a:t@ype) = | Node1 (a) of (tree1 a, tree1 a) | Leaf1 (a) of (a, refdep) // end of [tree1] extern fun tree1_free {a:t@ype} (t: tree1 a): void = "tree1_free" implement tree1_free (t) = begin case+ t of | ~Node1 (t1, t2) => (tree1_free t1; tree1_free t2) | ~Leaf1 _ => () end // end of [tree1_free] extern fun Node1_make {a:t@ype} (t1: tree1 a, t2: tree1 a): tree1 a = "Node1_make" implement Node1_make (t1, t2) = Node1 (t1, t2) (* ****** ****** *) absviewt@ype treelst (a:t@ype, n:int) = $extype "treelst" extern fun TREELSTnil {a:t@ype} (): treelst (a, 0) = "TREELSTnil" extern fun TREELSTcons {a:t@ype} {n:nat} (w: weight, t: tree1 a, ts: treelst (a, n)): treelst (a, n+1) = "TREELSTcons" fun{a:t@ype} trans1 {n:nat} (xwrs: !list_vt (@(a, weight, refdep), n)): treelst (a, n) = begin case+ xwrs of | list_vt_cons (xwr, !xwrs1) => let val ts = TREELSTcons (xwr.1, Leaf1 (xwr.0, xwr.2), trans1 !xwrs1) in fold@ xwrs; ts end | list_vt_nil () => (fold@ xwrs; TREELSTnil ()) end // end of [trans1] (* ****** ****** *) extern fun trans2_all {a:t@ype} {n:int | n >= 1} (ts: treelst (a, n), n: int n): tree1 a = "trans2_all" (* ****** ****** *) fun{a:t@ype} mark_depth_and_free (t: tree1 a): void = let fun aux (t: tree1 a, d: depth): void = begin case+ t of | ~Node1 (t1, t2) => begin let val d1 = d+1 in aux (t1, d1); aux (t2, d1) end end | ~Leaf1 (x, r) => !r := d end // end of [aux] in aux (t, 0) end // end of [mark_depth_and_free] (* ****** ****** *) datatype tree (a:t@ype) = | Node (a) of (tree a, tree a) | Leaf (a) of (a) fun{a:t@ype} tree_build (xwrs: List_vt @(a, weight, refdep)): tree a = let typedef T = @(a, weight, refdep) fun aux (xwrs: &List_vt T, d: depth): tree a = begin case+ xwrs of | list_vt_cons (xwr, !xwrs1) => let val r = xwr.2 in if !r <> d then begin fold@ xwrs; Node (aux (xwrs, d+1), aux (xwrs, d+1)) end else let val xwrs_v = !xwrs1 in free@ {T} {0} (xwrs); xwrs := xwrs_v; Leaf (xwr.0) end // end of [if] end // end of [list_vt_cons] | list_vt_nil () => begin fold@ xwrs; prerr "Fatal Error: tree_build: aux: [xwrs] is empty!"; prerr_newline (); exit {tree a} (1) end end // end of [aux] var xwrs = xwrs; val t = aux (xwrs, 0); val () = case+ xwrs of | ~list_vt_nil () => () | list_vt_cons _ => let val () = begin prerr "Fatal Error: tree_build: aux: [xwrs] is not nil!"; prerr_newline (); exit {void} (1) end in fold@ xwrs; list_vt_free (xwrs) end in t // the return value end (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/list.dats" staload _(*anonymous*) = "prelude/DATS/list_vt.dats" staload _(*anonymous*) = "prelude/DATS/reference.dats" // for the purpose of debugging fun{a:t@ype} print_list {n:nat} (xwrs: !list_vt (@(a, weight, refdep), n)): void = begin case+ xwrs of | list_vt_cons (xwr, !xwrs1) => begin print xwr.1; print "(w)"; print !(xwr.2); print "(r)"; print_newline (); print_list (!xwrs1); fold@ (xwrs) end | _ => () end // end of [print_list] // for the purpose of debugging fun{a:t@ype} print_tree (t: tree a) = let fun aux (t: tree a, d: depth): void = begin case+ t of | Node (t1, t2) => (aux (t1, d+1); aux (t2, d+1)) | Leaf _ => (printf ("Leaf(%i)", @(d)); print_newline ()) end in aux (t, 0) end // end of [print_tree] (* ****** ****** *) // [GW] implements the Garsia-Wachs algorithm extern fun {a:t@ype} GW {n:pos} (xws: list (@(a, weight), n)): tree a implement{a} GW (xws) = let var len: int?; val xwrs = trans0 (xws, len) val ts = trans1 (xwrs); val t1 = trans2_all (ts, len) val () = mark_depth_and_free (t1) (* val () = print_list (xwrs) *) val t = tree_build (xwrs) (* val () = print_tree (t) *) in t // return value end // end of [GW] (* ****** ****** *) implement main (argc, argv) = let val xws = '[ (' ', 186) , ('a', 64) , ('b', 13) , ('c', 22) , ('d', 32) , ('e', 103) , ('f', 21) , ('g', 15) , ('h', 47) , ('i', 57) , ('j', 1) , ('k', 5) , ('l', 32) , ('m', 20) , ('n', 57) , ('o', 63) , ('p', 15) , ('q', 1) , ('r', 48) , ('s', 51) , ('t', 80) , ('u', 23) , ('v', 8) , ('w', 18) , ('x', 1) , ('y', 16) , ('z', 1) ] (* // for the purpose of measurement val xws = xws + xws // 2 val xws = xws + xws // 4 val xws = xws + xws // 8 val xws = xws + xws // 16 val xws = xws + xws // 32 val xws = xws + xws // 64 val xws = xws + xws // 128 val xws = xws + xws // 256 val xws = xws + xws // 512 val xws = xws + xws // 1024 *) val () = let val nxws = list_length (xws) in print "nxws = "; print nxws; print_newline () end // end of [val] val _(*tree*) = GW (xws) val () = let fun loop (n: int): void = begin if n > 0 then let val _ = GW (xws) in loop (n-1) end end in loop (100) end // end of [val] in // empty end // end of [main] (* ****** ****** *) (* end of [GarsiaWachs.dats] *) //// (* Author: Jean-Christophe Fillatre *) (* Garsia-Wachs algorithm for optimum binary tree. See TAOCP vol. 3 page 451. *) type 'a tree = | Leaf of 'a | Node of 'a tree * 'a tree (* phase 1 : build an optimum tree, with leaves in any order *) let phase1 l = let rec extract before = function | [] | [_] -> assert false | [t1,w1; t2,w2] -> before, (Node (t1, t2), w1 + w2), [] | (t1, w1) :: (t2, w2) :: ((_, w3) :: _ as after) when w1 <= w3 -> before, (Node (t1, t2), w1 + w2), after | e1 :: r -> extract (e1 :: before) r in let rec insert after ((_,wk) as tk) = function | [] -> tk :: after (* insertion at the beginning *) | (_, wj) :: _ as before when wj >= wk -> List.rev_append before (tk :: after) (* inefficient *) | tj :: before -> insert (tj :: after) tk before in let rec loop = function | [] -> assert false | [t,_] -> t | l -> let before, tk, after = extract [] l in loop (insert after tk before) in loop l (* optimization (efficient use of the Zipper, to avoid [List.rev_append]) *) let phase1opt l = let rec extract before = function | [] -> assert false | [t,_] -> t | [t1,w1; t2,w2] -> insert [] (Node (t1, t2), w1 + w2) before | (t1, w1) :: (t2, w2) :: ((_, w3) :: _ as after) when w1 <= w3 -> insert after (Node (t1, t2), w1 + w2) before | e1 :: r -> extract (e1 :: before) r and insert after ((_,wt) as t) = function | [] -> extract [] (t :: after) | (_, wj_1) as tj_1 :: before when wj_1 >= wt -> begin match before with | [] -> extract [] (tj_1 :: t :: after) | tj_2 :: before -> extract before (tj_2 :: tj_1 :: t :: after) end | tj :: before -> insert (tj :: after) t before in extract [] l (* phase 2 : mark each leaf with its depth *) let rec mark d = function | Leaf (_, dx) -> dx := d | Node (l, r) -> mark (d + 1) l; mark (d + 1) r (* phase 3 : build a tree from the list of leaves/depths *) let rec build d = function | [] | (Node _, _) :: _ -> assert false | (Leaf (x, dx), _) :: r when !dx = d -> Leaf x, r | l -> let left,l = build (d+1) l in let right,l = build (d+1) l in Node (left, right), l let garsia_wachs l = let l = List.map (fun (x, wx) -> Leaf (x, ref 0), wx) l in let t = phase1opt l in mark 0 t; let t, l = build 0 l in assert (l = []); t (* test *) let alpha = [' ', 186; 'a', 64; 'b', 13; 'c', 22; 'd', 32; 'e', 103; 'f', 21; 'g', 15; 'h', 47; 'i', 57; 'j', 1; 'k', 5; 'l', 32; 'm', 20; 'n', 57; 'o', 63; 'p', 15; 'q', 1; 'r', 48; 's', 51; 't', 80; 'u', 23; 'v', 8; 'w', 18; 'x', 1; 'y', 16; 'z', 1 ] let xws = alpha (* // for the purpose of measurements *) let xws = xws @ xws (* 2 *) let xws = xws @ xws (* 4 *) let xws = xws @ xws (* 8 *) let xws = xws @ xws (* 16 *) let xws = xws @ xws (* 32 *) let xws = xws @ xws (* 64 *) let xws = xws @ xws (* 128 *) let xws = xws @ xws (* 256 *) let xws = xws @ xws (* 512 *) let xws = xws @ xws (* 1024 *) let nxws = List.length (xws) let () = (print_string "nxws = "; print_int nxws; print_newline ()) let rec loop (n) = begin if n > 0 then let t = garsia_wachs xws in loop (n-1) end let () = loop (100) (* end of [GarsiaWachs.ml] *) ats-lang-anairiats-0.2.11/doc/EXAMPLE/MISC/Peano.dats0000664000175000017500000000537512223166161020320 0ustar hwxihwxi(* ** An implementation of natural numbers in ATS ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: November, 2009 *) (* ****** ****** *) (* ** ** How to compile: ** atscc -o Peano Peano.dats -DATS_GATS ** How to test: ** ./Peano *) (* ****** ****** *) datatype NAT (int) = | NATzero (0) | {n:nat} NATsucc (n+1) of NAT n // end of [NAT] (* ****** ****** *) // tail-recursive fun add_NAT_NAT {m,n:nat} .. (m: NAT m, n: NAT n):<> NAT (m+n) = case+ m of | NATzero () => n | NATsucc (m1) => add_NAT_NAT (m1, NATsucc n) // end of [add_NAT_NAT] overload + with add_NAT_NAT (* ****** ****** *) // tail-recursive fun sub_NAT_NAT {m,n:nat} .. (m: NAT m, n: NAT n):<> NAT (m nsub n) = case+ m of | NATzero () => NATzero () | NATsucc m1 => begin case+ n of | NATzero () => m | NATsucc n1 => sub_NAT_NAT (m1, n1) end // end of [NATsucc] // end of [sub_NAT_NAT] overload - with sub_NAT_NAT (* ****** ****** *) // tail-recursive fun mul_NAT_NAT {m,n:nat} .. (m: NAT m, n: NAT n):<> [mn:nat] (MUL (m, n, mn) | NAT mn) = let fun loop {m:nat} {mn:int} {r:nat} .. (pf: MUL (m, n, mn) | m: NAT m, n: NAT n, res: NAT r):<> NAT (mn+r) = case+ m of | NATzero () => let prval MULbas () = pf in res end // end of [NATzero] | NATsucc (m1) => let prval MULind (pf1) = pf in loop (pf1 | m1, n, add_NAT_NAT (res, n)) end // end of [NATsucc] // end of [loop] prval [mn:int] pf = mul_istot {m,n} () // pf: MUL (m, n, mn) prval () = mul_nat_nat_nat (pf) // prove that [mn >= 0] holds in (pf | loop (pf | m, n, NATzero)) end // end of [mul_NAT_NAT] overload * with mul_NAT_NAT (* ****** ****** *) fn ofint_NAT {n:nat} (n: int n):<> NAT n = let fun loop {i:nat | i <= n} .. (i: int i, res: NAT (n-i)):<> NAT n = if i > 0 then loop (i-1, NATsucc res) else res in loop (n, NATzero) end // end of [ofint_NAT] fn toint_NAT {n:nat} (n: NAT n):<> int n = loop (n, 0) where { fun loop {i:nat | i <= n} .. (i: NAT i, res: int (n-i)):<> int n = case+ i of | NATzero () => res | NATsucc i1 => loop (i1, res+1) // end of [loop] } // end of [toint_NAT] (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) #define MAX 100 implement main () = let val () = srand48_with_time () val m = randint (MAX) val n = randint (MAX) val _m = ofint_NAT m and _n = ofint_NAT n val add_m_n = _m + _n val () = ( printf ("%i + %i = %i\n", @(m, n, toint_NAT add_m_n)) ) val sub_m_n = _m - _n val () = ( printf ("%i - %i = %i\n", @(m, n, toint_NAT sub_m_n)) ) val (pf_mn | mul_m_n) = _m * _n val () = ( printf ("%i * %i = %i\n", @(m, n, toint_NAT mul_m_n)) ) in // nothing end // end of [main] (* ****** ****** *) (* end of [Peano.dats] *) ats-lang-anairiats-0.2.11/doc/FAQ.txt0000664000175000017500000001250012223166160015706 0ustar hwxihwxi###### # # Frequently Asked Questions: # ###### Q. What is the difference between sorts and extended sorts? A. The statics of ATS is typed and the types for static terms are called sorts. An extended sort is either a sort or a subset sort. For instance, [int] is a sort and [nat] is a subset sort defined as follows sortdef nat = {a:int | a >= 0} The only use of extended sorts is to form universally or existentially quantified types. For instance, we can form a type as follows {a:t@ype} {n,i:nat | i < n} (array (a, n), int i) -> a which is considered a shorthand for the type below: {a:t@ype} {n,i:int | n >= 0; i >= 0; i < n} (array (a, n), int i) -> a However, the following is a typical erroneous use of subset sorts: datatype list (t@ype+, nat) = ... ^^^ Instead, the sort [int] needs to be chosen to replace the sort [nat]. In order to capture the fact that all lists have nonnegative length, one may introduce a type definition as follows: typedef list' (a:t@ype, n:int) = [n >= 0] list (a, n) A definition as such , however, does not seem particularly useful in practice. ------ Q. What is the difference between props and types? A. In ATS, props are assigned to proofs and types are assigned to programs. While proofs are required to be pure and total, programs can be and often are effectful and partial. ------ Q. What are the differences among [case], [case-] and [case+]? A. [case+] requires that pattern matching be exhaustive. If pattern matching is not exhaustive, then an *error* message is issued. On the other hand, [case] only requires that a *warning* message be issued if pattern matching is not exhaustive. For [case-], no exhaustiveness test is performed. The use of [case-] is recommended only when the code is generated automatically via some tools (e.g., atsyacc). Note that pattern matching must be exhaustive in (valid) proofs. ------ Q. What are the differences among [val], [val+], [val-]? A. The differences are parallel to those among [case], [case+] and [case-]. ------ Q. What do {..} and {...} stand for? A. In the case where a value is passed whose type begins with universal quantifiers, one may need to instantiate these quantifers first before passing the value. The syntax {..} acts like a marker to inform the type-checker that one instantiation is needed here. In order to eliminate all quantifiers, {...} needs to be used. Note that in most cases such markers can be automatically inferred and thus need not to be supplied explicitly by the programmer. ------ Q. What is the difference between [C] and [C()], where [C] is a value constructor of arity 0 (that is associated with some datatype). A. [C] and [C()] are really the same when used as expressions. However, as patterns, [C] and [C()] are completely different: the former is treated as a variable pattern while the latter only matches the value [C()]. For instance, the following program is rejected as the second clause is redundant (since [nil] is a variable pattern that matches anything): fun isEmpty {a:t@ype} (xs: list (a, n)): bool (n == 0) = case+ xs of nil => true | cons _ => false // end of [isEmpty] Instead, the problem, which is quite common for beginners programming in ATS, can be easily fixed as follows: fun isEmpty {a:t@ype} (xs: list (a, n)): bool (n == 0) = case xs of | nil () => true // using [nil _] for [nil ()] is fine, too | cons _ => false // end of [isEmpty] ------ Q. What is the difference between the following two forms of type annoation: 1. let val x : T = e in ... end 2. let val x = e : T in ... end A. In the first case, the type of [e] must be synthesized and this type is then compared with the type T. If type synthesis fails, a type error is reported. In the second case, the type of the expression [e : T] is [T], which is immediately assigned to [x], and [e] is then checked against [T]. If in doublt, please choose the second form of type annotation. ------ Q. What is the symbol for "not equal"? A. The symbol "<>" is used for "not equal". ------ Q. How to write a single precision float point number in ATS? A. Each of the following expressions gives a single precision float point number representing 3.1415926: 3.1415926f (3.1415926: float) float_of_double(3.1415926) ------ Q. What is the difference between the following declarations: fun id1 {a:type} (x: a): a = x // [a] is a boxed type fun{a:t@ype} id2 (x: a): a = x // [a] is of unknown size A. [id1] is a polymorphic function in ATS, and it can be type-checked and compiled. However, [id1] can only be applied to a value of some boxed type. [id2] is a function template in ATS, and it can be type-checked but not compiled immediately. Just like function templates in C++, only instances of [id2] are compiled. If one defined a polymorphic function as follows: fun id3 {a:t@ype} (x:a ): a = x // [a] is of unknown size then this function can be type-checked and compiled. However, the C code generated from this function contains a type (ats_abs_type) of unknown size, and it results in some error when further compiled by a C compiler. Thus, [id3] cannot really be used in practice. ------ ###### end of [FAQ.txt] ###### ats-lang-anairiats-0.2.11/doc/BOOK/0000700000175000017500000000000012223166160015256 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/BOOK/manual/0000700000175000017500000000000012223166160016533 5ustar hwxihwxiats-lang-anairiats-0.2.11/doc/BOOK/manual/manual_main.pdf0000664000175000017500000140107212223166160021530 0ustar hwxihwxi%PDF-1.4 %Çì¢ 5 0 obj <> stream xœVÛŽ5}Ÿ¯è7Üí¸Ê®rù mE ‘0H,ÑnvÈ&d“€ò#|/§Ü³Ý=0\„æa,w¹êøÔ9ÕýfH‘†ä¿ÃÿÅÍîÞã:\¿Ý¥h¥ijÃõîÍŽzÌpø»¸îïg<0ɰ¿BpaV2äiIs²aZVË3Ni¨iØßìƒÇgŸïÇýO»Ïö»G»ôO52ÎEëuf4PÎQmBñ‡°'е6jáù8qÌE¸†g㔵Ee gc+1·ºDV ßâq-15 ߌØÔd5ÜŽ)JSK^~bÍ(\÷µ$R>„Ôfžbi©æp3räF².^x)ªœKx5ƒ*jž)W‹Â%|…H¢¤GyŽCжð~Ýžƒ3‹E<ól¹dþqÿй“på¢ìÜ kjmØ_‚±óàè˜ ÏF"މ ìd ’& 'Ç–›R¸7N%Raf\[G™"ø à™°­®ŒS5án·Ž·ÖTÚfsùΈA5¼El­Q²†'¾ÍbÚw)–VE½‘ ì‰øW­¶ðÑè¡h õ è4©„/Ö ï=ó AMJ¸t=•mÖóqaceÐpéì!cÖD¢Ã”%–•Á¥–l¶*®øntx J{êA­³b*î}xœyu´gª8(†&HÈE—Ñ -³hªàRy“õ9”Ú9wøF*¤¥ºžÀá†0p‰l’_yr¿²†‡Í’Ä5†ög­^Ž®«&hõ‡±NÂÇžÈýR/uÒ‰•-+çõÀ‘ó:¹c“–è¯L~7Â’lÁÎü‰‡Ÿ;«Âd³¿ 0U§ Í­t§ºZ-áŽb!Úf8ô%£ÄU×JÍÉjPý™&ÌRÃ×Îhv²³£» rí„W#o:#Ëê_h\ä¿£ò¬[s È,‰‡©h̋ÿty[GùÚ™²šÑÄWHZµ8Qw›¿\]ìÐ&µZÜœq>‡ï×õ´¨jm˦ÒF/«;>øÄSbžõ©‘»ÇyÁÿéØÝŸåàýÒ3)5ZÏojn ]w«Õ¸Ë½¤˜[¯¶» Ó‹.b:ÝŽˆÎ=V‡éøÐùmŸm讞ê1Þž=ð¿º÷÷Y!þÎ9u䀄y0h}EÍ4w…ç+M”£@,sÑ3Wà5™‡‹súÒÍ€ïÊÿƒ¿>ö 3\¶ìt ÁnºZ§ås‰]kÍú}úWʣݕòèoendstream endobj 6 0 obj 986 endobj 94 0 obj <> stream xœÍ[Ko7rÔ¯˜c7’7ŸMîeáµ7 /œC’ö°ÙƒF’¥$’F¶ä¬çß/«Š"›#ÉN,‚(=ýà£øUÕW™÷«i#Vüÿ{vsòâ‡yuy2mœövò«Ë“÷'ßYÅÿœÝ¬þ¶ ï9¹’¬¶ïÂËZJ+\hÇOVMnµÎWù™œ¦Õ<­¶7'Ãë^~»·¿œü}{òýÉôX&Ü MyýÐ ÅʹÞ¯ìú”ÇÆoÑì[Ë<µoȜޙῡƒ«ô%˜ w^ppsÎæwßó]±ËÙÙÖt÷C1»¼(“º…W½·Þ‡æÖRû`fuäÝërÉî†WÒ†‘¥–ØÓs¬‚ÇÑß”îîÊâôfïpCnk=‚ÁýÆWjcì$ÉÖ`0ÅVÐyDèþŒP%c¢㣻 ¨†ý%Á!âQŒ 1Dò%@ž&Râ²^ ¸·.¢x ¨X„ÅÜŽÉâ?Â;Ü‘ìI„hY#®™luS›¸øŒª²ËL+}“s¦UB&ì¾#h†±µ#ºM޾\ †­ë2¾øøxõ.{á:y© ~Òk,:vø0vÓóSèD¦•“sðc?Wë6VJ§uˆíª¼ÙLUÆ;²B ŽÐ‘Öä{ ÜQäº3 Þ55A7Z›d@­)pžÂ§06E žÖ+‹@[ïë߯µÈØ k)!f†U0íáq²Ömi Ûç`žÍ*‰XîZÈN‘n$×(î[$Þ»„Q©ÚMÊ#ÃÈPœFKa+úž itȨ •kL°8Ã.ëEVŸ9²j8]Á;3®[™òüÐm1£f™¬ŽDÁ³†ü»_¤x¢á;cÎ>?ÂÎÙ–ZñèO°S8žw!aÕQ ¿‡¼²g õëØÍ¸VAÄÌWs­™éή!bj<'d,¶£ƒ·øpÿ†`bº>Ôõ¡J·7£èæÊI0&ðÓ‡ïøk¬+ò{å~Û6i±™¦<ןF˜\ˆ¸Õ o˜¥ƒYïFr1fÂä.g j¯Ç~ÈÓ|’½vy·_¢Ë»`ØNÎëã–eÂó#ÑŽ¥v- ܳ%SÄ›ÁX zs† 0P8Ÿ™|:çËäáGk0¤Íw„ È-áSN~óÕìÐ9.Þ!kðr¯À¾EîV9"e%UøÈH'©Rï8™ÚžCtœtÍaÃWÓ±ÉÉç ƒPÜŒÉ~ÂŒ* Öûdí .½7!ו%gð<À˜ ²½ëì‰Ãé8Ê0ÞœzS ¤¹Š´Jy3ÛsXdáÏ>›úU3–ÉŒv^?kMà»°’ߎކ?Èl5Åáõw9Q¾MËOQàxÕÅ@(W&¢àS±sî¼áu}S¨HJ¥ bf@Á“JÁªÐZL§"·)AE€g¤W\$aºK›I>˜ÖøÄVÂ%³nÔ*ìÞÆ^Ø€xip¼â-,Å)u#šD&°U&E ?`i…öpiÑ!ÓZªòEŠeqgÀH'&Ï㝠G£|r…sÅpE†ªc•ÌÁR…Œá ÞcÔoðSªXY¤€œc‘“Óï‡Rȇa¦ˆ ÀsêLüOKPT:ÌÏIPa0ĔЛÑÞ=J &¹QŒDbÿ\F@ë9ëÈÛY˜ k'qö´¤–ÆhѴѺ)`û%)±àwô颀ê$¹†UÐ(“œÅÑTY2#…·/ª˜Ë2‹q/5ú6;w®5Ýð/.)Àê_Lj<-‡Zsˆµ2Ͱ*$±Ò2T`;Z¯ëú8U%½[fS^éfJ¡Öã4à]Œ‚‘؈}ž,Y„Ÿ9®egTU Dª §T1Æò®› ;î—_c#iÕÄéöÄRÀ¨õ\ýËTfi!ð¹ú,pÈ$+ŠJ*+O¾?ByKõ ;ÐàÙ‹ÿƒ€æ ¯uøFˆ„Ø¡²„ñ$"Ϣ͕6/©@ËÓÀ£|ä ,¤Õ5:GÉûì°ì6‚¿F÷gÚT¬‹*©’ê(µƒ9³øQ]8êBàn³þ]¬SAÁÏóC€Ÿubô³É¡Æ?­þAÐ1 9‹4|W×8L߬Ä’%‚u3Òªrã­ës-¶¤û>·gác}Ç#Xšøo¬þî˜FÕRÊnZ‚ÅD-¥u)(§{]CiŠúJ:„Ï"Í…ðë}eñé=WïÚuK‘ã«oR–‹ßsŸrZ®Ûÿ¨Þ6ǧÒã;ŽXŸ=¥ÁÇ6<žÅ0efŽ “­ôY±ÊQfã\%h$}©^²ùPy v[¾Æ¢ŒD-–}SQ0(ŠpjÊÇÍ™¬¾²÷rJdž;Œ%ÆO¬ÈQS”²,´K%ГÃmŠ´ÙÓ´Š(c,-Ävô¨4ئΆÊA¨6¼$Œ"3¨(w|ᆻ0o„|2cüoqˆ¡2ùiÈÌbØí?V)“z)µ¬±¶–Rá}Á"v‡\‡Q„±¬ÜcöM"濌…a"bDžÆâ«É®<—/*U€F_žÆwc$PÄE2‡È¦ž‚ßÂà´‹®Àµñ6ž°Vx®”ÍÅÂHÅâÍ¡QÊÞ¤½ÀµÖ$+õE'ÝâVV»}JhL/y"÷TÏ*áp”§x¹¬´ÇýšÌâx©×m¶|í¹*üNý‰uT’ÇÙÔ©XÍ©Îh|“…mêÕ¤ÐwDÅ*Pl¶Êô P|…wsÙê»Z´0K¿w4­]Ò«E«{±wÈ1Îú¬Âïc¥PZ`xVè÷¾’ks8mDOžåPø&Q¾+ùœs„¦Îb.sLÿ®ÉÎ>)è^~fb© 7*Ô#ì(îd<ÁÉkÉ=&2—·…sð)#ÇEÄ­•›ä¹nߌ š–äßuæ»'Uêð‚‰3:‘µ/j{…%Êü @áÍÙò£OUVÔ¿_èå>¿ØuNx'z·2s‡Ð¸óøB;–}!x v¥ÌøÌí¡7u`ä@C¬j»b,§.ézU™hHâÎÃVÂö1©ÀO…[wÎÏ4ÂO¨â´N8%{¿L$ê4æÌÆÉeJÔ\ZF´²Å¨uI‹IÀ¤c/õa–pjÉÏøÌ{jNŽ-»å„ ô½«ŠÁäˆ=½ÛõX>&ÉÁ`µ$Œ™ï9.—·<;–eÚùγ¤þ@Qâ1Ubzµ1·Ø må';5û7G¤ª¤F€µO~í) *×rûžÂŸé˜·%ÓÛ1ŸçÉ?3yÀQæXT ]h…Ý®]Ú²¨ñ‹–h×\÷ÄÜE¬3¥Ù´™4›áJEè·„±*ãIÛ¨Ó¸#5‹*ÍS”ÎáTáÑ; uKb¦ß(ã+vÈ"?û² ‘]̶¬ª@+Ú`¿ûe” =$ïSÙ2 ²äñaÆÝ3_Qž¤iÕõ r€ñFià;ÅÈG4«Ax›e\ú¨nêááç«Ñ࿽”›û?ªc=*ˆB–fSä¢2¶·DW!δŽqã³1Hi_‰øjÅã9dúG¿Ö1Ù•ó>¥¹&Û0¿]w™¶·iuÊ®ÕEâ—uÂGRz,Y/Â;¸7Ì…nèa}R 0qŸ·¹—3&þÏ&ߟüq¢endstream endobj 95 0 obj 3410 endobj 103 0 obj <> stream xœíœIsÛ6€gzÔ¯PoÄL…b_zKì¤I'«£æÒéÁõ–&±å8N÷× €=¶ «JÅñŒO$~|À[ÀOS‚é”À_ý}p:ùqOOO>O6Â*b§'“Oêe¦õ×ÁéôáÜÉ6eTNçÇNX0¦¨qç±Dqb¦³¶ÔÖ1B¦šLç§“jwïÁã9š¿Ÿ<šO^OÈ5×°îwk£)\'4’N5›J«1Wp¶ßª4£˜&uµ@®á–sI«3äA¥ BV—Pf’RÅ«#D1ÊšF‚+É2‰ÏNB%Ôïó_š&Âe/®m'….Û¥vr†eÝNŠf– l-¯ J©/ÍÑŒUo܇%˜PQ=DÔÕúC¢zê ®w,ü›4ç¶-‘Ü]Me­‘î¼7ï ‘«Nk æÔÚ©¤ëØKYaÄ}w‰Æ„hס3Òß@õŸHV§ÐÁs×ÛP8rʸÕ#$ª¯hÆ«}W¹$%ªŸ\pm1ªzâ*ü1¨u§w÷5.~€ó¡¿ÐâÂýïÆÛ˜Zà5òß·57ßÕÁ´Á"ìúIàĬSn¼í¸lá“1“xTô‹ÊR«5ð(‹ñH„Ó_Yä‹@¶¥3ø¸t•ŸÚas ß¼z8^ÀÇâNw‘áé?é³HáIÞ›[ó$"ëÇzØRøTø(åN@GÉ ô¢NÔÌ+þÌâ´—¿›iûz\ïÜÔ›6e£ïýÝPè´Æ¬:¡‹Š¬‚¡ÈÁ÷_®e~*†ÅH­'a*†ÎP? ×ó¨R,û9ÀZk=8Çâ¬>Ž ÁX2X´¤!Ü`ÇœõAÈ#„aÉ ¨|m@þ®ÐT(¬.ó&´}åâæ’°¥êr ‹e/‚""ølpÍÚ VmÌ_q¬¿ <ß¡Z ‚z4Ö[ZÅwW~^‡Â“c‘Ôç³}}ðrØ|o%¬ÓÞ¸õâfÊáÆ%Ö½¸ÉÎZ¯&*ŸqÃÑýÆÀ-2mR›µlCnú–ÒfËÑÆ(6}°©Û3÷ïâ*j¬˜¶ÕÃF+e6JO58˜Í“´p$í[&ôr¦;˸/q’ó0yîRåðíÅ™î;Ä‚ä²È`m-»8¶FÀ¸¸Ÿ1{™¥"®Á¿ ªmI‹ š4 &kØæÝþ-äNP…€‡„€±VÒbq nf]yôÏ¥Ä/€^‡¨}Ä™±`Xµ‡¸wž¨ åâ“{ˆJ-ð«Iã7™‘ÕÒ¬*w=gUDVwA‚;î½›a­^¼o^`ø-RÆãÚ:[v‹ùœÓVn4&[Î'+ϧÌ"ÝÑ®ù|…$4Péˆ`ë€9jlÉ<ž˜ø£…W¼W^<æ‚Nn}3õ#=-nõ饽®ñ~âï“Sñ„%qÀFÇ×’ðChXã쬼¹›P¸ÊFk3S³^jò© -Çãú@Hè3~ro…*›ß¤VP?ƒOW¥C„fÔÂyt°{ö!z›KbN‡ië† °8s´TÔxàˆi&åá, +“]4ŒAìôr¤ãšÊLnS'Ë-W†²<³tEz‚Î3c|XΫ¶£F)•tÔPe0eYKFV¿}VUqV™]‘Õ`"«Kû±ÄMgÌHrnÓVÜŽÜ®àÖpÇæÜÚ4¶¶Z#èj ™’‚í^w\ü_yÕåyU+²&/ÊC ©Ö°ðÑBgp'ªvöÕ)±‡¥ ¦67 5FNß(W°ªH»4º^@My@åŠ< _ Ð`¿ïטz+z¶ƒdÌ­øwØtYÛfýƒê°y)󺎌§=u熦-¦p_‰&‹h¾i4^Jx8!A›è¥|³Ý«³Æ§Ô’Y;DÛÜÉ4UNm&½Ù\› ÝKĈ-…6}ßLŸJBíÛ¼%¬NœÁ)‚o¾ ÙgUQ11vOa¦-ç–ç ¼REŠHâÓ&^ Ó²¶_ö#Ów-“ý @ü2iëF³2BZRBp×fo|° ¤·ÚÆšÇ;½ÑóJÞ€òrÚ¯EÁmåšZû‘ßk÷Û,­CÓ„ÎÓ* ýÑš`uÝ0ïB±LhD1A‘ßÅÞíâTËÖ…Ãâvñ°)r‘‚¥ãnýΘ¦—;/%Ïlï {ÆŸ¹ïf‹9 òpÄ^ :d9“Xu[ÉŠî%§nzoL÷lßd›“Åÿƒ7ç–·R&Ó…çÞuF¥W´»Õ \w~è.²&Ø÷¹ñ9:‡w¸'ˆ2õþ¡˜—ŸvnCž¢-|Ë…ØB¾ºµôS|¯Ùÿ{žú,²½H–ö/Ñ“}JIFA7½‹re]ÇÕ}Y‘œlL6#`Å㼵їciBK°âTuuÞ¼'Ã/CÞ¡fa}ȸLˆõë섯5d›fýZƒ´ £’[ƒåb\5ƒŒô˜ìóý¹¡î¬Õ2mÄ벓»ïó!†yËæóvü ô÷oǹ/÷Wp)´ÝñÛlüˆÂ½P¬À6‘ïùéWØÌ¢ó 6Ý STci–Ôé ͹ºæ\'µ¡ì›g¸âÞ ñb/ˆîâ¢CywE­ÝÉ|ÚFY:ýe#Ya“yìò¨øÖμe ,×äÔÝ‘{‹|hT²%m³üv—ðª:¹v9᪜ ÂHÞMÈ›Á¾l§50W„¯M§‰×“æg4-endstream endobj 104 0 obj 2064 endobj 141 0 obj <> stream xœíœ[sÛ6€göÑ¿B㸸è›[';ÝI»iªéËN;±³±¥$NÚæßï9‡ˆRk›pGŽ9Ûˆ}8wê·bÁñ_ø{zuôÏÝâüúˆ·N{ËýâüèÑ >‹ðçôjñí ú9¹Â,Vo ³–Ò ÷ñÜ*îËÔJ×$狎/VWGÍÉ‹ã§+¶úßÑ“ÕÑOGüÏÆ0ð ÜÊ §Ÿ¤XtîäðVÿm$[š_Wÿ}EË-—ýœ¼³J‹~uVwÂ/ÒkÚÉV÷øŽ™æ?ðó#[ÊfÅT˹RºyÂ4´„¶ñ‚l½wÎ6?³¥†¦G‹À‰}¼íJœk•ð~a»®•ÙŠš–)lxÞÁ:œTs?¯a"ÎÃØŠ&½¹‚™4ôë%ÍgL÷ûám>¢w0ÇqWg0ÈK¶TÍ'¸ã5¾çׇ¿²õÜv)R”ËhawLn5µÐô:ÜWßÊ7“HÏðªÞ߬ÚWha[è@Ùj¨ ¡àÌX«Z8~#Pû†b;Ixþ x|l”ÔúˆÌ!§Ÿ˜nÞ¾té°³>;l@7l†÷ŸâÍ?C§pøðÍx“W—éÆ×ñ½Sðµ¾u®XßÌßtþºÚü”æûø“+¢Ó6_Þ³¥‹$Ƈ×ÞmÑoô¤ðµ€%áö…MALëV—K˜eàCdPÙv/‚j@pÐÐH "v5u”€›uPè€c}Þ`ž¼˜î¬}8yRá'º== ÷-LdP±H)ß/@[gvÊÆ*:MÀlŠ a]¹ß/þLi&ò^aë{¡ Óù^8’Œ»dÞk4ý¼·°©¨—ñU§ aYÒ …‡UÌþ ºÊoÿDÚÃD‡ì=$jC¯áÅ ÿ@Ëæ ÃÝtÚÓu þ,îíSô“ÿhNò5Ú•¥™9ÕÎm­tÆïPðÃÒŽ€MßèüJº‘çëø`&!8 ç4ËgÉgIo™É¬<„f}î ŠÊ|­3j÷‚šw{âœÆ„G¿BhBê†arFØQÍÚÆ»Ñ'½{$# hÃ4˜Dª|œß4½Ò+¢E!¾ùì!¶¬o–D3rþ÷6VÚC숄+‰îÍ5»Ù’÷œcgP¬æ3KªÚj.òü¬ùê‘x£8ÆKR³Hü3øï÷'ÉõçÌ™m`A(ׇUÂú¹+&wÐtÌXÖµ6@8*9†rußM@™¢È'2œ9SÑyʬÂH”èmß`q\ÝT³ì!×Àl±‚™»{àŽ°àµ¹ãªíì>îäm¹#™yÁBv'‡ì(( z?Z&l¾ž½ƒFOƒá·WâeAö t"Å2‹l¡ê!¼þÖoEílÌØ¯=…9´¶ vÔ¤îOè®ÿ`²÷ºð^E8ª™¨×m½Ì;SwêDM_K[“r¿zp·¾Çÿ‹nüÇÌû¢Wß’´ RÎwÄ×ï=,ËÐåÅgÁÓ™ì¦åóTè©©Šžš}K84{jO€þ?ú…åiýu A\Æð. ttÝ(¾qzOqؼj-&˜È˜½´C>¥ªº—¦•ËêÈK»!¥{a Íæ7Cú ­W)• i =¤êÖþ¬‹ÿ×y%TE\³™Î¸>\ï’ÕÝoùpÞÚ SÍ`ùWо¢’–hE¯Ï¡)a½Ãöéú-=‰2ö} qC¬ÏRò­¯$¯­{,¾u¸vM5 ±×û¢R0Ü¥J$<ßU;®\× ™v{db‘›Ë£·A>ÊÄÃnóáËÃ^œ{¹ÿâ,_>ÔŒ«ŽtE‰­Ìs8EA:•¶ú:Ž% ÑwÆ:vꑲ¢o‰Æ8O1÷ôÞ‡ÓžÃ!½™'LÁtCaáØÍ éroþ-¥Çbç¼âŽ’§™BÍMe[…'UòªJ[ †æú5óH¶O½øPâÑò-ÕŒë` Ñ™ªÏS Õ‹Gâz‘Û—#ýV”ÎaF}REǸcšêáI«Ç+& Ë»þK8Ü1¡œÈÔ™Ç(Ì èß’AŠ„S}QˆS&á%™\[½tó \ÓôXSˆT76VÑb4«²Óà 0( »è [S¸ÂIòêÇ|õ9ÙaTá—U¡ç¨mŠÜ´ª•ºØá¯EYE%Sº8¡h dôPoTÒ‰æ$Z¢ñoýºá|®"¡¹hÔõy>%vàñ938AÛ%ÎF‘‘¢¼¯n=ÓSMqs*¸Èg|ÐÈùÕ)aô]¢sT‰1Ô€ ŸSÝû:w¶S49úäÓž3õÏï@@˜ ¬¬¾ñq„n;Ôåê;–]lÈø˜9.àЀ‹!¸ÌÔùU$ØÜ÷Xä/Œfxg®ë±2#{Thû&Ä*=ƒ‘/}&òŽDÞ%ö7e!NeöþR+ ¦’5"pCÏH9>ª#LœE¨sëÕ? Ñ…ÁÅä$E¾ºv’Bjž2Ø…áû8`a»,ÎqñD”½S4‡Ûàå!r‘žŠÉŽüĪ’ð½ùrgí3ý¬×O? }sÔ…á3Ö>›7x€ÕÎøþŽÈ~z>¿´1sŽì@!%û¥~ÄM‚±¾Íh–•(âh×é!T|e"ƒÖaN7¾ßŒ-w7“GÎç]Lø½“3:¦ý»û3˜ž±pa ¾²Ú÷åÔsG¾fƒÊ «h!‰Î¤ôm·ÃB"Oú&ããº?$¼Ï‘§oååæÇ±~¢D)òèý®å•ë™¶ËÒ0Ùçb¬ëm«u l;WŸÎ7j>õyêë}_G"ÕÊüèï|¦qsqÝ.;LÅão]›n5åS›µÒƒà³¾i/´KÒÌlº‰ÔL_%“‘\„“éø·(°Ë\Éw“¢ ýƒŽùZfïA²«ëW e¶Ôe5Ñ˲%}ÃÖ—å &éëXCl(¨z}áÌ:9S#œR’i¢É#ç³~Y‘"½$DÍ×2Õ°¿÷Îæt÷2ŸC;û—žÒúñ4Æìs¢ÔÞ˜ÒQiQ3›ÑŒåƒÀrÇã‚?ý]Ú»endstream endobj 142 0 obj 2386 endobj 185 0 obj <> stream xœíœIs·€«”ï¹Ï±ûÀ6öF'ªJ*+¼Å9ˆ‹dE$‡")Ë̯Ï{X0=”†±(R¥ٜƎo0Vlà+†ÿÂï“‹ƒ^«·7l°j2lZ½=øpÀ]šUøur±úˤ³b%¸^½ÄJÃ-”31#™]¦§ôN0¶Ùêèâ ûë«_õGÿ=øÛÑÁÏìž:&ȧ†ÑŽëñä«Q¬ô4Ò`iÿîþÙ3H"˜æÝ»›ž†™Iw·ý¡˜ô M·†÷v’VÉî |h-äTÝËžOƒ2ÊtïÞö®½l”¶ûˆÏ’ !»k|äP·âÝ”Ë!µí| £Rÿ9úGì6êúž‘Òð T0½ÀvðiZi)£|Wx¨»¡—ø0±q€6u?ö¼»„vS÷®×ÝE¨º+øìÎðÇEzºÄ·½ê^Cü9Ö!÷{?J(”C/þ†Þßaîð|¼v…b¦)Ö¦t®|1L“µÆ%ú­?äUÑÙuL¤€©²Å 0$ +ø¨&Sõé. v+L¸ÑJŸªíMÓrf€Ž‰4Mš‹fÈú¶FNÌ"ç¦ý÷þPºyÞ€Oër8¶¬rÏøþs¬ßbÙ„™XD@ê"Âv™?ƒ,BÛî¤Ä7Ö¯X4aujM,ð+8‹*(DÄ—(ÇÁõœ3í‘cPzœÜ³”óô¸gîhµ`d@ à,€†s%8ˆ0éºo¯}ýXjÎñ1§!ئ2HS6›àÛ z ÿ¶¾G¯A;Aq\Øîý™ç23G © hv=¨zø±ÖΕ”jP †þèFú,·ðM/蟤«äÓ²G’`Á‚R£“锃%„ŽÍ Åú¹¨Uß ]LhÊ}5ƒ²‘Pòšô­Ôˆ7*ýú´L1Åí…¦mä5’º•žŽ|".Ý¡c$0¹9'™©’MÊû ÓZ¹A»d0w\—ˆ‘¹]|ÞæbPá^O>˜êÊp}‘ʹŒíö¹‘\HWˆ[…Ú—¾†žJÈl 9ÇÁZ‰'8oSu©ï>ÉfÁèᦀ`&6žµgÒ¨A×LÊ$ ŸN€Ý]Â([,Š‹l¾]zA G7†˜L'óÐûÞ?q3v#`Šc§þŽ$HË‚x7®´5¾Iy–;/t€žµóâäíÔl0ã,›ŽH’ŽQ¤¡Uä”êhsòÄ\¹ª+Ú€Ÿ×^˜N^ûmMª‰+D15}^0þõÓè€ýˆÂĉÎóhV`²$Þ‹ÕµMÃã»ãdª,¡æÁÒIøvXíY[ÆV,ÚÌâQÊL&Ãn’A¥$ûZ‹@sê’*éméÜVJzˆÊ5ƒóÜ4lBÀÚÛ=Ê­g.0U{H9Ô’š 0&‰yC»Â~üró»뤕q]}Ô[ véOØ´4ãò*¿E*}T1€ÏJ¹Ÿ¤œ¦ä‹%*7c`ŸyïF+º ±·ã:±\EB µqµ´–=ØPÛ5rªÜ'Da{Ù(Aðɚ¯–LÖ\6&o}ì­‚ó¢"j]Æ ¹aÎÄx°ÏX‡Åã*ü©VéµÂ:æ§) u{4G>¨ŠÌ¯޼ŸL,õ*üÏõº(Îr¡‰MH ’1ꢯý~TcÚ‚Õ3Fã¿úKæáIþÄýðŽŠ#çUŸ(£3CÅI¦d• žd÷ø&ºÆœ:RX\Ì”P¿‰|æÏCù¤Òšw_áµ?%€ÀÜ*zoåWIËa‹±þÖðs¢©}”QJ™6^~bWü¢½U‹9'fá ®œx5ˆêt;=¤J}¡–I—…LÛYÆdËe¦=Ö•úyšOû¸&{~WÙD=óáp¥ÑÛñðËí.­Ô¼eßdžW$1[”O:Ô @V.³+÷@Ú> ?’_˜ •³ŽõqµÓá \4ÒµvG/˜5Ú$!Z ©W$‰;f¯j¬¤ñ‡äy‘.T¨‡èÎÎúöê¿ÁN3ÓÃ(ŠÙyŒB³}4R2“¼¾Ä£šåñE/¼oœÕ° æÃ4Ô«LJ=À›6zRi(‘¬Þ¤:Ë(4j |¯­ê%îüFqØš¦^þ:¶{#PÖoU…'¿vœ ij‡b•ÏRÄ}A*™}ä«ôD÷&;(r„Ÿ.€jí¸lãœÅ7³1—]ÙÐÂ8IÐPû è a&kúôÖÁrçù:±x²9T2z\H&Åms¾±—¾ÄÌœÆAóóÈíÉöqFÁÌÆÀ÷àMo!%œ­! ñpb™å®x©ïÇ$²6Îí ³È[§;A$»2£v.·kQa@Rß/:#9že Óð¸šÚs¥UrÝWbVèbbÄÄïN_…D0qt?:#P‰·ë±/3ò 6Î,Ü]nàþ*ƒ‰ŽáŽîï7å*ëý¸ÊB1´RJ÷Â~”¢ísÒ¬…ó¾ógBØ‘SMÙ¼o2ŒØ4çE=ø0r*Çe^„ÊÑy¨m÷ˆÜ6‹ÒÙø&Å`û`Œà2y8 Ðù³²íÄ 9vU†DÖ4Ùƒ÷@²tMÄ®ãÕ˜ËR»ã8þðJ°‰RP­Áƒ}ehxÃ}Z[$ÿ†1y»êõl‰  i²Ï9Ò´Æ…+]Å|òAã<†Ä,Ö_κu‰R‘y`×$xåæð7w©o#îH¦È‰#ʪ:Ö{;ètNÜlI³:É*V ”2K6÷à Jú’5Ø>ÿ‡z Î ÎÆoX'µÖÈvo½þ.Ó2=+£;Iy¸ctéLGÜÎÞÝWü ¾;i+]ò{ÍO–¬ôl‡3ÒñN‘Û_¥p'ÄbWE]¥«{ƒ/!PY˜`2Í{UícT𫽵ù³Ã_é$ÜæùMü}SÙ!ÉÔÞ¸çàV ¹ Ô7½«ë½72¤OÞyk—â†'ßwœKm3«· HC@r>…½ÉxDcþH[¶~ˆÄ[×êR:ÿlÛ!æä wÄ~éù¿Ç3Ý/=ü½øj.¹‡sõí1Øþ–Wcrfƒó1¬'à <µâŒÞsâ°},•K™œÚÄáüvú“â° ‹A“!üNàî –<«Dà÷+à ¿¤à<ø-¿½'Þ¸Û ƒ»J{žÛE}øù‹âa|N¼ß¶yÀiÑ#6hS`ñY4Í~⯜™¡&sÑMðo<ì"ãå4êˆÄI.Üáâ›j}óH(ÙMxïOkdæg¾g&˜¶¸[Y$e¹P"<‡·áüÇ„7ySÇ­ø¶€Éi0–Nî <Í~°P}íȘï¢s¡è «f3ØS~CC÷øî°<[ßøây¤/ù˜˜+]Ðo JÝYÍ É=l¶LŽvP–ñ ÏùÈO½OŸ„¢›½O¥mKä¸ Æ¤MÒJœ†½ú*6Sɯ»&wÍ„_IPt¿‰¸›µø”LÏBqaêÉ®€0k˜ð+TÒPëÏÿÎÃ×€endstream endobj 186 0 obj 2655 endobj 224 0 obj <> stream xœÝWKoÔ0¾çWøhÖx?E´„„(á„8TmZ@»„¶”ŠÏÌ$›G»Û‡6¨€z؉=3žùüù³{.Œaè¯û=^Ï£8»,ŒN.“ÅYq^ûˆîçx%žWè—¬°àEuŠÎÎÚ ódJ“Ä¢·ú9kŒˆFT«B¾8Ü;¨TõµØ¯Šw…¹k #˜*­Ó "ZÌ”(ÕGéÔª^w¾ M0¶­)§P:h» .Bý˜óV7$y£¬Î9¥ _)‡–+ß«ÅÚ¬ÔÂ&ôH^¾U^àg 8È2ì8ò¥2” l’VdpöP-J´ÊÒÉ}t4\ %¸öjíâ±X¤¤KÈY„µíÚ‰˜WjUʤÙD\-bÉh\5Ék²¡Ž‚üŽæV&›æ”FyÈSeå~v|C ä1¥ü¡œü‚4> stream xœµ[YoÇò¸¿bí§ÙÀ;ì»{$Ë;ˆ~° ƒ")ʱvW)Ëú÷©ª¾ªçXR–ÃÒìLŸu|õUuëõZôr-ð¿ô÷ùnuò½__]¯DÌàݾZ½^Ij³NïÖO¡]Pk%íúô946J9`œA8-Âz[žÊ7%ÄÚ‹õénÕ}õýƒ¯O7§ÿ[=>]}·Gæ°_ïœr8O\¤\{µvBõVáh?v60]ÐÎÛ½Øle/ƒÖº;ÃÇA¯ºWø¨½tw³Ùª^x|w¹—Ò:ß½—ÁÀ¡“Ñ+=(ç~>ýWZé}ðW`†>¬O¿YþíÇîÁFJÝÃÒºSSZ#†î¿ð8èÞÃRÒ¤°PMU¯¼U¾ËÞÂBT÷&²a‚à À.ð¾~³ Q4»Õ½á³Ã—`avÓjëzì×í®ñçÐ áQ ÚÊ^H‹»Ôôù|³%IiƒmˆGƇ+üBgðn·ÙšøöÚã4ÐÚÀD¾{‰¿±~€q¤qõ m𷤯ôê2vÒuïàw³1´' ­ãë|±IݱvÇ_A×÷4ó{ì ¨Ã%þþ•â¤ýäŸôùz“×XŸpüßAK´<¼¥e½µAñkéz­ÐèN/Ą̀‘%×!Þ×Ç›òtY²K@ág pX#Û£„†Á CwjððCWÚadO`elGE¦T1ÜD›MÃzàVÙ²êZ‹AûÏa*X•"ÓßæíoÁÊ­? )|˜­(ØZØóŠjÀ¦(b´‘Ø9k§ëÑF-š4h¿)_‘ÍZ­*ëIZ°ph'I5Ü/rStJÝ!y‡ò(¤E®œŽƒãÒ˜ÜÉȶÏÞoÉBòGfܸí! ?çY™[Ðø¸mœþ°o”‹ÃÂFºds Öi²É±íqçLÏ»jNì1é!ÿDmØ0kYm+Ë7ÁfÉF§´%Vz±©ÍÓ³A‘v¢ÈÓѲâ&ɰã^¯“xŠ |!tä"(ê/ãG´‘0Š4–CÖá #c¯ŒYà{u‚´‹ºîo‹¦¿Á$ÌOXC‰ ›%4*+îŸY"³0Þ« 04ƶ?mÐuÖ—ò­’ü‚­lýW’·D€õì× M98í§½þ‘…©ÆØ}QÝâbvˆ¢Ü]}— ,:2=10½å&7Å¢4bš•Š Ösqn%„6È|ŒÎ¸”!#;¸9Ì1Û$ôj„ qº Z±¾3þ&e$™àõŒnr‰ J †£àOaÆÄà–À/÷$ƒátGà^ðÛrD¨Zª 4Ae\™=°Á1yOF2”+z‘)Ðó,.¤š([‘¬Ð¢Å´°‹£B´÷E†ÅH†ÆPÆHOœÃò!êã<ÇË2gGÁ‰­·@D ã(ø¢]Œm~²e°¸–µQø“»]ˆ¤k‚jåYÚæÐšcÏ8ÀfùM©¬}(dåä=™ÚBðÔˆ¤°ÿLÝÈ%^ÖnÏ.ã®°ÍqîE?÷)Òi/ Xd‡â¶Ö0xI8E} ‘êeÕ4 wÈtœ.!©l[ÎF²¸%".‡ùñïêŒSõ$Kñ޶Ú©„Nz—tbDº†ÓkãÆˆ¿žì4f¤Œj ª‡äÁYx¹ ‡ôGƒR!%1½¤K¹ P<Ä6èæÍ`¢Ûb ÔÈ3àh°SxòÑû 7ÒNuá•”fú%¦’صв¨4 šÇQ¡§ÌÞ}‰šP:™î åkrDÞ ÷ÉpÝ`' P €Q&AjñÆ7 Þ@'Ã\к=ËÏh]æ³²½ BfÁþ°!9Ú‚"u{(ú’£¥!Gz›ßQ[EïÏ‹è¤ ¹y•¹d—¥0ŒL¿j :¶‚FN`®å@æ<—ÿö”mºú úŸŒ¡jä´3\SrDB†Ò¶wmÏœØ[Þ'qÔ8–>H( ºÐ¦udtÖLÎ+W•HõìÐsBø ¯Zçd~˘ ‚ÐIYKÙ™´9€ÎD~Y;%—§}µ1¥*™žÎs²Ìѯx=d_ƒ†jð̨$¢bÖˆz•m¦c *•BëP‰Õî¤X¢5æŸ#jQÈí¼ÔÄ O¼Âˆ¥hÄ8…¥eòÉL7GÜâ¢2·hšP&›&ã¥-a=´š°v ¦8À%Pcf—íøŒË–› |r½•u¬¬1ä›ÒU’isfnÀŒ•m&NŽ4dWð<•õm¹¸ˆôcîôõÆ¡SYiœ/6ÑDæŒ-©/çt…x_Æ<M»àaa™#S^8Œ J”e<ÚäºEŒˆ%dù Ú?8‰Ç¤3°ÅúRvnëŒà›š[x;-p¼‰V¸]óÊÑTèÖ‡œÊVpVXSk åÐ=ÕŽåÍ ÈS:¾%ÑË Ô¾`Á€+PTÙôâöRARÁL© n¿ÍõÃxñ.ÂåûÕÖ˜™]'Ù¥8жµÏ2¿d| ³ñ;Õ¶õ+š'Æä8š¨&EæøŽžöÒ·fðrwm)ŸŒŸ­´T¬&h*ÐPÙ?àQ ägeÀ«Ô—e4aв—R^•âÚ¯|=ºû%²”üsÔä*-‚s\ØçøÇ“¼ŒR{M»F‚¾e†(÷w¥Í¡É=jGVdI/?«/?//© ÿâCJ,òË&,å—{žSç—¿ÌÈŒíå]ýü²¼œ“3™Gð¤!M]hS˜(ª(ñºlÀ›4{‚¿OªÒg‘xŸ×F?#+¦Tv®»Ÿá¹QXذ n;f!N÷yÀ{Ó˜á¢Ì:ƒ£ò•¬AhâUÌ3NÁäE§?¯×–‚¬Xº@šc!„]<ýv}óæíåê䇵\<Á?þçüõô«õ_VŸ®¿[>¦j呎”=Îb€ñÇS¤B™.J—¢pá<9XHË„s‰5ܾFV™Ä…Â~Fa%R `hì³øø§êÌÕ? €Ó.y¢=On9¦h™6–P!¨ð·¬?šT$ªq¥Ú³ì{~Ò–ª­§”|JUŠäÚM©å*’!FáÕ\¤Iá“ëf¦ú?G¥‚ _1ž¸Lí9¤ªÀˆ™ g‰rŒk3ø->±‹–¼ÐÒ[-OF¸H„Cp%jT½•¢ûrVK8Apžz]ëôw,ÑTNüåfØ ì6‚J?ø(ÇçÐZµf˜Þ•ïº8Ç`ïC¤Ð[ÎL#hë¢Aϱþ·TmÝé3ÁæÇ¾D†…¿+âÉ3¨ü}΄’ ãäò˜Ù†&œŒÌ¶`ß¾=}«üyd“hÈVTVs›Mð&¦¿\hÝsd+þA{H¹Î‘cEb¢…ày€\Ç…p-«#ü9ìq=Bg%àu ,£ÅÁšElR²½s@ àoHDݧÙ#`L![sàˆ’t»Ð«£>¢†#3ºÿÆÂôu®ø˜QýŽåp£ºÈ¨./u Û2ÊJvzê…x¾±çùŸNíGGü)e:­¨Ú¤•Ñ_†BK&õ­I]~t8|ÃÓÇXÓ Ýå7¹äg«å2K+Îֆ˵çâMæ ÒIÉ{¾•Q+†sl F{‹Ôn|{aÓÙ°ŽGQ훟ϡèÞfúšÎ¾8®æêl,€ù†ØzÿáîÌR‡w”˜—²›í¸Ë™õ[åðüÖ‰ˆûó[ðOmCòÝ}bR–R°îeYôåB”À¦ÿÇWiO•«³&Þú8×RnÁµâtš×ØîèaÑŠ,/Ù±¦ŒÁ¾kÏXÑ¥m‹¸¦*%¯¿ T¨z¶½i‘ïM£0âvt9Èj›nø´ç"Œt~Ó¢hGaœ-g”çÖ’Ä$Y(ÙrBÎC6³­#uæ‹XŽ ÌA“˜÷J£ì}æ½xõcµ¡MÎ81ì£û—})‰×BÊž rºWéß«¶‚ˆ‚4æ^s| §w“½&«/v—µö%ê«0vì³ö8 m×"Kˆwq°ƒ~¡Ã|r:‹ ÕuYËÙK5ÕêÑè©à+b©šjƒè×Ã0­Þ—ûžUKó%ªrÎfF€IPéDKà+?*(׿ù¿T ª3•|üIþJEì´„’¢³p> ìyÖ\,V.”3wü¿¤Á£Ïq. Qº$"‰|D² <9gâWÓxíå“ó\qŽŸeÃt žpv`¨É…c´¦ƒc#Høocá/ 2îh;Î •GÔ(2¶xv(×p ?(Ìeµ¾w”£ðzsë¶ckºy,Êy­Eê§?Ì”5rËoM€CFµâu€Q¹åToþŽfS;rt¨ áWaºü$XçËCCg9ž±š*œR‚÷ÅñŒu½W8 R=‚Zbvn¹ *¬oWC£r7¯›Üø»áÖrA/Ìl·VEÅÔ«gw9¢Çz ³f  )"Üz¾nd̽ÆÐØ<'Iû>Çn–Ðm|y£½„ƒ¥Šºj¾£Û¬¦Ñb¶.2¾öü~#uÄo\7Å—¯¾ä>éŒQ¦\ÖJØ[c¸ÚÑ kê^™u{¬I§É)3§©‡™tæÑç+¥ãcAài†ù8'ó() ßcÄÄŸ¶¿ÍÇ× Ô‹øå}¯Õ‚S¾Ô©«WC*Z«È€wŠg«œFã?Á™¹JWó‘3î ÍM˜£ÖŸ?Šd¥Ü4ÂkµX•Ÿ(ñ\°]­zg`–x ´d»1\.Š$¿ì¾Ä'¹µ~ ¢Mwl9È·ú?û¿qªendstream endobj 235 0 obj 3923 endobj 241 0 obj <> stream xœÅ[ÛnÇ òÈ—üÂæ);Žv4}Ÿ’‡HV`v`;ü`Å‹¤˜äÒ\Ê”þܺô¥z¦wE)ëaowOuuÕ©SÕ½?¯†^­ü/þ{zuôøÛ°zµ;úÑN~˜V¯Ž~>RÔgÿ9½Z==†~£^iåVÇÐÙjíÕóLƒ7øÚä§ü†UVÇWGëÏ¿ýÛß»ãÿ=?>úæh8ô-0Õ¤ð=,¤Z 38Õ÷kßmÜ¿ÿûª~ðƒf™¦Ñ«xuÞ5­r›U¦¾Lò¬së/:ÇËô‹TØÇ¬Äû8Ĭos¿3zD Ãl O8zÈ?–Æûê5üt[¾.•ƾÕx’ïòÓ.]ìC¨ ¤VÓ´Úh»:>…Á–‘ªƒVBº‚iÕúÛRÚKXžž\¥]¿Ã¥Þ@ú‹ºßeË ¶³Î®áhK£á[Pëh­+—'JË(S½ ²$ÇËKü{ðr¦Ú Z9­å5‹åÖ——Û8€\íç•1½'ƒkŸÕØûqå ½ÑÿŸ¾8züâ«ÕÝíÛó£Çß­ÔÑã/ðãé×ÏàŸŸ¯~wôüÅ꛽;5mS®W_“í¶^ã®[Øp½¾„½t¸ÞÑ´6KO½ÃÍŠË{îºcŃ' ¡ý <÷Dv¾Æ÷Üáæ²öíÛòý]šhL;ÄzÛt…›1M~šHÿqw]jÜå}?)ý õÏ“¬-d˜3]6·X`t®û2ï¶vÔû,KóÇòý¯ P´ É®‹4gIrÔ:¸‚xt„£gŒ$:XÖ!è}Gžm‹jÑ/ü3¶Þ×]qLÅpÉIx\G×?¬äÖÛ¸E´“:¸Å^è õœœâZ* lBegißÃlß-™Ê¬é‡ßåi‘òý¤â¡>› Õw¨âŒ: á‘Õ "Âe¤ Ù¶W8}¤•ât-çœwPÉ="ôò“hš>šŽå@Œ8ŒÓÿiÅRá¸Ý'iïéã=ÊÌ>’máÚΟÒl-y' ÑÌKÈ›ôV°›,!½þFÍÔ©¹ž±ÏÓ"ôÚ‘ !á¸uäç2:§m„øjŒ“ªGãÀUeÜ%CÅ_X¸)Þ%|R¸xB„'Ö±#ÛôÆh/Ì0FKf°‡`à×hAØ»ÌXªÔzÑ0¼ÑÒ™hCËðmÇè`<†7EëE»Èþ},è2Ymt32먤&Ê#ëM‚‰-ÁfžñŠgܘ0H g¼ŸEêgøˆFhæÐŸ'“ht%$CôLàê%‘[¢}^Î}ž½=O‚¼ÞíuÑÚûdç²W–—­é é!äèÞ¶0ÔY@*fRQ¦Ï¶þŠÙjú6Ý*G¡”¾9-T”„BH4ÁR ’V ÂQS½áɃ“MÅ…ÕG¥P© AÙ@Ò’·£{£Rýø0»r YØVÈЛW#[´ûŒqo{V3@Ì”&øªPÝÚhŒ÷d³¡)ÂeÚ%“ ,[Àjàùƒ°š‚BìÔ„QÀ3e¦r‡¹$f¯!¾Ùô´+sí…ú Þh€£òŠû½6w™”<ƒ›‡‹v…]oœ³Cˆ1|YZ¶ÜièÍÜr1DËÅ»‘Ö‰†—Y8sâÛÍzXÒ¸ràs˜² ‡Ö1'üÄ4Zù¯'ì»H¿aï•íõ”Ko¬‡Ž`~È#ð+°©Ñ:²à&ïP àš@q dɰ=Ê+T?ȧ;°Ÿ> –ã!Øò`së8Ž8í5²rÕûà51}ʲ'Ê>!Íqr*ZÐìAÆiºBä(—èCÐjªº¾"8„]R¢µô¤¼F<¾Á;Ù(– AÌ´Çm@‘_ö=$ñl2Î/ ”Ì—Xk%âEl;OC]¡Ð¢­¦…HÜ¢€rÉÔ–zgˆCT„ Ù^`¯’¼&/œÅÌÄÛrˆLOè["z*6wþ“hs‰„—‰°8Ùç*Ãx ,,®¡‚GbÏð¹1/Sd ½Ó™ú xª}wθ ¨ÐA×àK·ÄÏeË»R£gº\è±–`+DÌßÄÐÈ+«ùÖÇÜ F±ldç"´þ)¿¡}~&$ûi 3d?>\?·UIv?ÏùƬ.Q\ º@ÙFñé²?rUN Æe6½½RxD©MòPlÎõ»ôÕmóq_å·ÒgáJ3úÑÊÃ[†·Ñ€~6|’åḆgdöyØæ’“N2Ký2)xSW]³Ë&p]eoëÍN‡*Í*‹ž°kÜ~W'ÂmËGHLµÿVÉ~fù¥9³~ŒW£MZÄÂIœë³Y]Á|@‚<{3dÈJl`y— ¼[Už'N öQÏÇß‹rÏ]Åö÷äÅ3¢Ã±“ÀQ“/ý“NvZõÌÈkGÌ71tX#ˈ)qÎç4a]sVYëA²:7ö°ÀýC î§ 4€ìaô)¾4Èq¤Ì¹8žBjΈ -~Ä5M3,«V?Æc.9(2ŒÌåñ¥íøíqÏ‹ãop£à { Ò’ƒDTŽ!¾°¨¬´êO¢l,J]<‘'®¸0^L>Y!}cgô30ÈõÚ0›L ¶ËTƒN/Kª±¬Qí §»êˆ©&Ëó)AnQMBòG|cy½3G0zªsæêýcni&š#Ó3½ñ­©áâÛ±US7\†;ˆö|âaˆo'Y+)ˆ¥z(â#µü’î|ð]…ÖŸø¾ö Y °ç3­ÿ7Ø;Å!çƒ`ï!a\ ¬ÇŠÐÜ€éLñ0m‰Å¢@pœj[1b/2›™…&̈vÊ>¨ £‹ÄΓV\ û.ife©Žk5‚gÆ£Vã|^CSØ\–êHSßB±`rxcHekVÛ¨ö#¹LXI…!Ƨº(NÓÖ¸žÏ`bÅ­$çÖt˜¬­ÊÇ—ˆçÆ ;8c]iSü]R;¥{!ÚpÅsרCÝpež«;sðA^aívªsÅ·~Œ Å"`ï)û»È3¾|ÏÓí)Fhë«äWPdÍ ù¬‹7d¨aûEÒ+Ex¢Ìsh˵ëmfº(.§ËžÀ:iž×,ÄŒThó[˜k!,w!…¾¢o5s›q6ŽÌB!\„ºÌTRegß—^¶Šä¥F™‰E;eŒ%XÊWêCÄ-Zl*>˜&˜~ÄÛÉÜGRè !]çÙË!Œ8!p#¹Á<ªG½,¢z<èxHCCp¶‡ê.j€§yqîÉW“,KƒÂ³6ò5áè§ùþÚüBQ ®¼*ÃypMm?¥èŒ¦œ£ÃÈÐ7Ð0½nÓ…‡y£P×}8Ìr˵Bº`‘ì¿OFçèN탒T?œì2hW† Ñ+‡íJäèu!Èq£„‹–{'Ë—Á@:#tê5Fæèw­R‹<-ªÝåªÔ6>ÉöЇ–Òv n<Ÿ‹–ï Íã”â++ûÏ8ª×Ð —b£U¶w&­â;“/iáìhZ±B_Èúüe·Ü oÉÌoüTxˆv£èš ñªÄV¶žcB®­œ-§³q$ì߆îäàf[Åóÿ•5Mš^¼7Î×\—Ä®U&?vkû¤kCší ùµ 5Ì^ù5Nø¡J#U°ønò“Òú&7ÂÉYùOÊ•ðªSùWxÔC  |g\ÞÞ>§^ñb\j¼*šºÉ—]M“æ=Kãu~qìb¡;5¾®ÆH$jV›Éo™§ÆB w¨‚)S n<-=Ÿµæ¼•Ò²Ÿß—Æ?I¶Ï ã›ØÒ½¬>ªÒsÃX[¹¨dÕñôxZú YÞ”ÇmkX4ÙiÉ­Ø„>KûØf^3Wçß¾¦*»äd¥ÄÞÛdµ3Òïè·'-u‰Ý¸•ö%¯ksãÛÖn\—áSnTÅ<ï÷®S©ä ‡ ùMKγèXc"o‹ '‹wVÎsÝZ±˜þU]|,zà—¢š¹æ Y¹|^é9YMÞP;3fñëŠÔW(H˜ëPÓ’ö&ÉU2˜‹bxï|þ‚-|OTa!aÞ0 ÛºXqèµW†âÐ .ìå´«2Üöˇê\[æÀtÉø›£ÿM³ïÏendstream endobj 242 0 obj 4112 endobj 247 0 obj <> stream xœÍ\[oÇ•^ì¾ñeÿÂhóCÓîºtuµ@väXÇ6ˆ÷ÁIÙ ¥¡Dy-¾ägìïÝs©Ë©êêæ²…aª§»º.§Îõ;§úõ¦ïÔ¦Çÿ¿Ï_ž|øõ¸yqsÒwÞN®Ÿ6/N^Ÿ(j³ ÿ<¹ùøÚy½ÑjØœ^Bc«µSú™zgz¿Ù§«ôL÷ýfì7§/O¶¿ÿúɧ§»Ó¿Ÿ<==ùê¤_cØ(Õõ®×<Î䱊gì쨦Mº7jèÞcÿÛªÝ~Øv;³Õ|±wÊt½¶Owvû9܇»¾WÖm¿ØíéçöO»½Þžî ÞWÛoàפè/wÃöSøéÇnšÌöÏøÂ×øüa§è¿õ~}‘~å«g»/¼áQþ°ƒYO^iÿß§ «D‚M WÉ[¡6ƒÑXÓK Í'Ù|o­é<ÜôdÚœžCëß Í¾áÛôÜêXÁ«ÝÞnß.ð⌮ÞàoàþGpK{ 7ûÈ Ìèéémzÿ;Xü;|0ÂZýör§·ìdt°Eva¬@–8¢Fºx=ïÍ0ÁC·ýv»Û«ø6Œ 7ÇíyÚ?zó9Λ¼„_áNç Þp<úç‰ÿbûÝþvíü@Û‹wqt7ÁÏ ØD9Þë]œè;$³&U.Rõ"O§ -ôôïNÓ 4‘Ï!U¦íáPpíaQ±-NâEn?ߦàì<°foÄÍïÓŒ`ypO;xíP<ˆ,±ëïïmoimÔà,Ï׳ ÚƒØ $|¸.ÚÑ+\?ý9ü´SyW_ „ô’C´ŸP6ùqf.IþÿÁ­Å¦Î ‡ÕGÞÀ÷™—µq3Õ‰êÿŒÒÖâ{ û¼CÌS‘%özTqâ,¯böyZ·‚¹ÎˆÍY‡ëú8Ô~mZC5­N Ô•±7 ÔŽÃýqŠ$I#ñd¢9Ê_äèWIˆÔwrÔzŠF¯â°&é)•%Ðò¥5^Þòå”/unëÒÝÖzaYÞdÚ^‚’d»9w­Ä†WÀ˱9ï±ÙÖç¶ó» Klçóº«%«aaA”/ŽW¼À• Ø 2‡ÐØh6fQÖX¢àö@²,•´6Û©-4«¥ÆÊRãó%©c³7fd¥‰C`5ÔQ[Þ©Ô±q¯L¥Éq÷ÓäJÏ49)ßÞvFÇ=‘š=réwƒ{H:R4z•D€½â¤+Í8—¥±Óc¶¨ý*óLö·±ñy[ÄD®òD„%¹IÆá†&×ÔýµŸÐ«´ø¬§Á®IŰIänP3òÞ#[h°ÜLÂ-ÞAòÂ?¶Ò肾4àU0 @½»¸E!«3GíuúùÉéC—-±{OÞàö@ ˆšY§W‘ÙҩÙÜœÄï"¼RvÉòë|¹hˆt"žY`YãO’O»…îØ‘ -Ç{XÇè¶²IF!öŸ Ÿ¨$ý:Ò)óht’\"¦ŸSY»!Å–]-V69YHvè ùer´™Í₩Ý7Æ¢ÄÄËc¼,à-l¬: ä3儸‰×¾$wÈB3:FÎÚJßßå: MF°ca§‘±ŽàšÈ`:gAê÷ 0–IY±–¤8ü´äº³€»vù¡PÈIž oÜ¢<‘Ù2Qž„z2ÆÐ°µ»EÓñî>æ`öÆ‚îÀù%1‰ J\OûÖ|Œ)l|Ü(ž/ÒùÈ%&j1– ·-î­Âš`¥/K³|È.z“€ ã =§u3c$CdN]R8¦3Bá\®;@3CÞ*ˆËOÙj™¤&'è£ì˜ç·°cÑ“i \&å‰×>hVÜ$ÛjG†à;nƒœXï MzzŒšÊšAª@›M¿ÖÑ yr^+b¨'…Ïk {AGéa\!Fı±!çµ£‚»Wå˜='×Ù‚•‰<2ò!ïˆ,årÉþ[4 %µ,QYûŸY§[$$GÎHQ§ðZJµû å’¦b‹¾O©Ï£tÍ´:oà‚ÌMB$ŸAì_¿±Ý $õð¦j=ì¾2 <Ê_×GQÅ(]KVè“‚8y#»n¹úôod côÒ³a¸†Ÿ!ÉI ßÂdÓ–Í *“# l\Bä byáIì*D*ÌZÞNŒ`á¼§Ú’%~aÆÐ†V„´ÜÓÍš& ”Á¤ïc ƒ·ZJ. ¹ö‚ÑVd˜œ3¬ë¬¡2ê¾Ð™`{„‘ãQ,¡ÌAX!æç…ïæZ ñFÎÒòÐî ¼™3FÑ®!&"¿9æ39§VÔÓ!ÂRÚ:¾[0 ´Ä[‡r¿õ0FŸçÈ=‰=á¡Äè¿{M¦†Öw#œLÙÉY ·œ•ÜZ¹˜Ñ›Ñ–ý1"å ÉZ—à‹[ó.ëeɯ˜«œB/wñÄ=1 šgî¹X$¡h42ðmñæ’ÔÛ¬Ê.V˜'ý¥U“`S¦Ê»xzœ¯\¦GWrؘB,4%wÅÛ„OuÌ]Àz¢ =•óLèÖ±ïÿDŽsA¸T*;EÑâ=)¶,:Ð7…VžUô Cá—àŸ¨” ¶LCH¼F°&ÙcT.£dÂ6ðV@ä(Fè vÆ#ó£\‘‘þˆ¦ovªw„Ï?Þ &å¢:£ñ5QYIF “æ]öB Œ–ÀŠÉ„ÍÁßžˆx¿LŒKßÁ/ÑjÎl_±Ì:N†ÂŸ}|Ú„ñ]áV>Þµ]ÜÑ‹>¹»ÓÐ]ÕãOa7Z/é_UdÐ^}Â*¼+È5K˜x¶ŸGJi·‰¯wR"ãXŸ1Ï íVÜÁ8З(S…©`V7½rÉWÓ; š'vŽêm‘΄D:÷‚irʨ¯1¤Ü‘¹«+ÖȼˆëÔ¨D +E ŠP 8?žÔôqJ@ dXrȪ ïN>Î!E¯-ÃלĜPQû!ù+Ù 5iãâú["ϺŸJñv2™ñæ8 UÛP&øõBT=×>V¡7ar,ãèÓ–pG%„͉Ú 5„¦í‰®zŽ‘ëFTÜ\t6òyC¥„{¾É0Æ'»xõ ¶äîöH< výîÅífë÷|nëŠý6+²wwÐN²ÁŠ|Uñ«(Y3n©8eÐm¤sÎ)+Š€+6oÖFó¸DHæ"k`w¡HVYc$T²†ˆ, vІ«TJvІ]©äëP|X¸A×Ñ“J} %Qû9´Í.¥c>z|QèûU5¯&߉]¿OŽj¥×ªíÛ{WO<æhñš»˜3З¨uÒ{r9"` †p¡µK·D®°=ë|?W‘ì ÷áK[Pɨ$¡6yònlºeS²y>7¶j<’¸ß\gÚBŠ°Ï³:TНé¬s6€BwªB”Ð]›Ó§®.® È!õ±¥×1ÕÆŠ'~~TYgÆYÍûZ>Ö²ÈÒ »OyðuhNÙŸJ*÷8*’D(Oè­í ê Ü­é;Gï¤3€7Éz½0^dÇV%ù÷S • +ë„WªÿÊ øÚÕfà¨Áö?«ö.2Q?pfÏ\W@DÚùPà ðÓœ‚ݾa{ƒs¤™=ÊÍešîGö9:vŽÐv…b¶1xA–#Ú=‹°y'±qUN(Á§«±p P‰Øü2ãg)ú¼JáÊÉ,þazOŒùSºù¦lxÏöþùö[ü‹k¢¾Ûr¡:—>b4“ …”ð¼7?ÆÜ˜;ÚG®€‹2¿Lkà.^­‡ŽCQ«2[ §@ Ut!:œŠ»†û¨3ÓëXã: ¢Â½ÿäû&c‰KMˆö(_/1E1”(J“ ØÆÖE.rz¬ç•µ“"+_¼+^´7b&ˆ®Npj+îç6‚hzßÍ f“hØœIºÿ'l´,Bo–®f)ßYï¨8ÿJÒZœ!hÔª½Ÿ€sé‚üeºùIKO[zàˆð/H·ÏßGº1‹œ•‡H7ªnNþÿn¿X‡%[–2”5äJ ¢Xûº4§2Le2ä-ïð¶!F°[Ã@§æöC°ÚxBÌ$Õ¢0Ý®F;ZÆÝ{?#¢ñxwЃ¼kv{ðà;ïÑéæj:?Z0~ï(X÷£µ¸K°±À.·81ïÜÔâG°ÛtT&Tr? N( ƶÀdX¶úMpqI­dR B|Üt·ŇTg§²gA%ž®K…$Ñõˆí-oÎ!i°*D#1hTv†ºŸvÑkÊaØ uu¾(«Þ :™½ä(É_; ö׊#…EéaÖÕœC5¹ˆÎ¹áÒ™¤oãEßÉ,~†Kÿ8Çzók”‚}À]¶ÃJ"«(ú^ßJšÉ 2ßÉ—…E&F~Ù¸%sq¯ŒÇ5³½óWLÁµ×]ªc«¹ÊsÎÇ"GŠãgÉI±k°·ÎØ ŒŽAÞÉžq”—áy@Ø©ISzxÎ3GÒG ?ò™ˆÅ:¤*š»‰=Œe^ŸÏâ™ Y¼cè,Ûp7?ø!-à’㾟Z'"{b¼cû{ V4?[“˜Ý冬äf§º`ëÙA‘¥ù0ñÊ·0„2]òÉZœ?¹n¹p鿥4ÌíªS:–ýzƒJÐÒad`N<Àm'ôPµVTŽýüåÉÇÏN>|öÅæí›/N>üËF|øþùøÏŸÀ?Ï~¿ù—“§Ï6_­žî«çžµ50Æ€á,|ž%ö×Ü+­ Ô3ÓâPj ¾ù6ß¼L7È7“d ªXJEš8‹ùª_œ&X¤ÜŒ,ÕëYå*Õs‹²õÊ3;œ7¬O Ò#:k´%¡»ž_–VVÕ¥…ù\g0¹ãB‰i»ª¿‡›¦fTVqû¤ƒÎÉ=ËzŽ^Ì‹ûC)¦2¬üÐB¨!'KÞuH2ʸîŠ!îÊ×ã!Ÿ ¾Í1»ãù«½àl„Ò£µ‚H\ÿ‚ÒA‰Æag¯Ÿ]Fu«ÞgÍ<Ý©ìœò<¯_vùŸºbõ÷Sw:§éBŠ7GÂ`fîWà„PR,iQi³ “áHmïJu&Ú©/ŠåÅõ^héߤ¶ÆlÅ€ LÔ T29.T(b+÷´ß±†òS:O˜X•Kõª:×O5+SS"îEÈLÑëûõÞ/dü¤ _8îÖ;Žo¨ÒäøJÐ ›ãÛ5D±T*ÑÒÊœƒ…& ‰JÚåêÕ ¯8B™5)ÝX±ú±[·§_ÒÝ᜽o;ïÙ?cà ”|Øñ‰fž°¶?ð -¹´h1ÖC¯Û‡M)ëÀcù•*dL­ôáƒ0"VHoÅœx:¤?]—¤æ}Ššê=Ï(GUõÞ ã©ÖüY7kôpˆÂ(šQ£ÈÞ-0øÑþyšÏ?‘z'|äeæM¹µƒ*ŒFyCÔ©WGÆäÕ—ú¨ ‚)CЀüŒE‘×É÷ÆÇѤ‹l× à23ìM<_#8åJàÍ&+«I%,÷€¯º$}¶ïùÐhßÈå7­ ‚ELo5—ñ—@@Dn±Û‘HYN©®uV"Ž´|˜Gºä–ÊäkÎ%Ös‹ùõ:ÂìÎmôÀPéé³7ÇÝ_ú@èèUØæx>ó,óC.· y»Ì%EjÂq̞ا¬íåâ²¥znðKÆiŒ8&\#€RL`(ùaä¡!“Äb*|ïñóZ\»Eå‚ȤÕr§Ô­õ"~-3¾;À=7 T}”[ý°‹õoãRß}æR7Šoþ\†3tÙ»¼ŒãQ =\n—›)¾“êö(5à ^….@»….>È]Ð"jX"GIŒ‹¥<ÊwE bÈ«]#þ¿À–-%•©7õÏòO¼˜eI_ãáóÈuÁX¨úÎ#£±ùÝî¨CfKç+<•/&CôÁBop)O÷ ?°=I¬E3嬎ÐÉ…ÆÕì-%¼»uTâ<¨G5V"*U¹À)ë^ÎQÏh*ñˆj]ófž¥}ÜÓx–þ>¿U–°ÃõW`èƒj/Ñ×>~S=»–Å1-È$®sZú\<<É$É€²´Ëž>fdJã< ¶uÕd ÓUVZ‚¦vðÈÿkßÂâBÉóâ» 9à`µ­¢éóCæ„ Oú–•ëä'þJ}X«„3>s6dH™_ûÀš.s—+Áp—=Õ§l–«>NB]Ø)ç]wÂK-\ðåÌF-·‘hüªÃ>AYÍ[’®›å^“·ŽQ•rE¼Ü>xWV{Åx©§‡t›û¨ZŠûº­Neö>Êq-Žb96šéO _•tŠsÃg¡¾#3Ÿ»ƒÅº”e·±>F ÏW'ÿA¶zˆendstream endobj 248 0 obj 5196 endobj 252 0 obj <> stream xœ½[ëo·/òQÅ%è‡=×·Z¾–d‚ˆQÑ4‰# ’¢,Ùj#ëd=Ë}g†¯!wïNrœÀðjË%‡Ã™ß¼¸¯C/þ‹Ÿ¿ÚÛf/¯÷†Þi?~ñrïõž >‹øçù«Å“CèçäB ³8|µ”£p0ŽF5¸Å*ßågrvX¾Úë¾zöÅׇËÃÿí==ÜûaoØ6‡Ê œ')VÂH‡ú¹sË•ù÷á?b_Ñã MÞJ‹°ºQ[á¹M ÕÛ± òåÒtß,áåAŽÝKèç®û~¹RШ”î—éîéRÃÐc÷l¹’Î÷ƒèPÑõËÕ(á™Ð0†@ºaïýˆ½‡îÉr•ÇgSÁS ÷FÈî`™î¾\®ÄˆÃX|×)Õ¸)£µ½ŒKºÒ»5^®ñrƒ—xù/^ÞÂhƒCvt¿tØðq¾ü²Äg¸*ÃZñRØ\f—È\äø?÷ýŒ«íΖ8‰Áyµ40©ìÖW8Æ+h ®ŒÝúÞX¦ê>‚oeèÔݾˆ;Ÿ§ð³{Ž >Ç»£¥èh8¼ÁîøÚúÇDôúø ° ›q›vÌ\¾Iãâ ÃHmg´KBÐC)áÞu8dèL—¸ ÈCƒiO‹Ò‡&‚$6ÉÔùU~ S는_”ç/aU~€5$šÊÈz¥aS@¡‡'°¿lQÏ‹èÜdÙ¼-Ó°®ç‰M$·6ÔLjåì÷I›5^ †x?zŸû+T Љ7LÐkÒ·sóâRWq­+ÐSc¼KK°ošþ#ë^â„õI)dßzåÕry50®ò™‹­µ*ßÌÉø˜zƒ‚[¥H0–(ÙY†ƒè†ùãÆ¢„ =/Iœ‘H·ò2Ò C€ÂÃÏ¸ØØq²dÜDàñQxÅþr9ü…íœÓm†mëHqpfÒ´Û€~A+®Ú-¬•Z3ùœpv+‹aŸ5Û–J%0ßG[æ d¢ טȫ¤\•òÂQ}çðÅ¢6¥gžö"–—³ýN‹J­[[PIM€™$׊ÿñžöñ3 †tb—@½Þ¿Ÿ@?ÆŠÊä™aÒzÞ†? ÉI2è²þ­(uB2d:9d\Æõ°‹ Ü¥iç™Ìjná)¢WðþéÁq¤–Ëõr¢yŸ.g)ðÀÎU6l'ïoLa$âíßàV(©Ñ¼Êážæ•ÛTTB©H iÝ$m´¶$>Ô?æäd4a=qçÅÒÌÍçz熢Ĝ¿ • ƒüU ð¸\²ÃÄÙËYŒ³{IºóÛ²Á.%àÜzb~aT1X‚·Ç8ÕHV'XW€ïpÌcšú{{†¶ˆ–Ù(ÒC(GÂøEz³{ÀÞÌF۬ȼOVìz™î Kgñ#Ö褦ONŠí¾%?1Ù>)5ÌssÃü•û]¡$ù;™!j!VË<‡ßÍÛ'\Ÿ§Hì"%˜§6ÔLŒÉÆ]Zbm2¹ù'܃H’‡L+àǦuæÖœ'•Îá6C©Hºp³ÈÕßLj¤( ò´]×Ä8Üó‚iü›Iᘀ¨ ö¼öE¦ñ:±ÅŒÄÚŠ×àAÝ&É=G§Ëîˆ(G0 a‡ùHI*€^ÌwÑ9ÂIÜØºp³¾>uF‰çÿ,â’ñ°hâshšGÂá¥ïЮ0û?A˜&} 6R0G Å«—•A‰ê× „#IùÖš@5xÕk·0 ”E:LŸ?9ØÛ?øvqsu{º·ÿÓBì탗'ß ¾ZüeïéÁâ‡æ»1ì³ÆÃ<Àuò»Cß1@Ú|ø}îœm’–ãÐ-[}é™Úû ! PÇóhfjµºK4m‰©f“œ×)Y’ËÒâøzÞèBI#ˆ©µa@П‡{øµ!i -FÍ‚Ëe 6 ŽÐG@$2~Áiíf”©F  0ÈÍÔèÑì6Ü[NÖÀ‰¬äżMìÅZ¦ ½JØH~Åö6ãCÊl-é}+böÊEôò¼3ïÔš®&M0`c個»ñè ¹Ð¾SÖ]ÈnÌË;îFÃ.Cí=DŸnä÷ÔcÙëwxSMÐÓ/F®ô`Jk…:ˆ™q¡ªÌ¸4Ån]§Ì·é‹éÉIïãÌ|•ìVN“çQ“þ®ò<± “슸¼m åÀ·ä}|+ð»yÒv=©$è’áw•JõCÇu£„ªÚû¡kzk &èÑ×Ë'´c)…gì¡Ù1VÄb¶å1nzÈŠmʽ3Ij‰fx•ª 1)Ðf­E®öâAeƤÚ9‰ók*(Jð¡ºãÊÏ™ÏHP½åì=xƒÈÊ»=*m 3¢ÛJÛ+3ÀRæ Nœöär;—ƒ¦û(hÌ|†8×Ö}9ˆ«ƒkB¦˜¹1šl ;»ý{†˜ v~««Oã=„pÿ™kæ @CÆ>œÌ ÑÓŸu±¥©R;lI€`ÐÝ»¼D€oC!ƒ’³ Ö>(ÆEý‹\ý¸˜)|„²`.yÜ»´‘R%ÍÉèËÏ ÆÒ>L[SÝŠ|³÷¤»¬2Ï:•ä¸Ù‰¶9#öüN„éŸøA‘Ô;ÙVÜb™NFã÷¹œ+œp¤&‚ÀxÃntÒ£S–3 ++&ÌÕþú|Š(§Md/1ÝT~Q4å·¿fcöEYìanü±4~“¿+ßæÆ§ùn¿<¾ÌµcÏKc‰Nxi<=ÞÏ/¸#’ßÎ5Þ”Æ»ÜØç»£òøf‰" À^§Ç³ù.a :y«¬ÄÈÁ˜ke‘ K°Ö{ då› ï‘íŠ޼ޤ!«‘Ë*d½žnPs>žM˜‰˜Ö§"J“-kÕ)‰*Uùd|«é0Y¨šÎå ¶è*w®YýŠw/#Zã‹ÕB¸ej‰m Ï}åxŒ{o Y[Á` ÷ ì ¨,‚cÈW¯À‚[m±aÜÁYc;Z4¼U/W#'ºa"Ô<œ ððÔ"æÁÊ¢*Œý<²tN{ððÒ {A5H|§¤Çf°c(æZ ÄVõJ{ä¸î­í˜ÂžA¡ž)l¤2bzû ZjçtšÚ]á!cÑw^Ã84Þ±W"µÆàà°BíÈgL3³æEDó‚À1„¤ígUjËÂ’rdRç€q?Ã|”ÆFÌ×Mãœè]¿ÌsàÙÜÌ`%"^qoV’€’Ÿ¡ ½í޳Çzû¤ —y8åÐÙ5Ž«“Ç ‚[Á\ž¥FáAÀŠÖS2'&}Æ×oše/£/uX^¨‚IÎK­ÿ·¬üþ¤ö“SJ¶ Û„8¢À?x|W^;W©¬ÛžFÁzxµiV¤ õNá“´Knœæt+ ¹Ž)¼Îàp€¥6ζ$OcHüŠmÓèéŒbÙ”»ú”QÏ$iƒ±o¼Ì7A[àr^NÎàÜî ¸•ŸÃ­ çP>BqçjtBúiðâñ"ñ2Fë”·nËœW¹ñ$yºaàè7gŸ÷sv¬‡â,‡¦ßɸÑOZ¨«]Þp´¨&.Ùº•ÊÄSwöæÕœ;Q½>up®k Øìo4€âh¨"¯ª´©•½ciÓA{LdÊqü@iÓù|»€È‹¦±ý²¦• •¤s)ÀܦèöE"@ÛŒE*˜‡ ¾ÙïpÊ'PãhJõ“#ÊëªpHƒ•÷ƒÁšòù”Ư•üs†#$–9ë³Ç§‘$ó¹Éq.eieçââPÇ' zóX+†Òë­y¨Ö†`ì烇*f‡¤G,·ç×2ÜCàL =n qÞ4ÃH 5[ÓÖÝ&@NñY>K8ŽºîQmˆ–Z¥nÃýþí>¿´kwám|±äˆ‡E¤Æ îçA^•AJQäþii=É„‚0Çe…çsÑTið ²Ösµi@Fvlü{XrxL> Ëzþ”`n»›Ü°-Ïy´6¯¥ºˆbà!ÿž:à+À[­\+ Å!¹1û=çÞA›>ñCJÿ“¹È·9qÓcêˆûõ!weªY ¾,#p>Gùó¹5îž®*)L(s…bÍÔ¼—Ûš †Á¹­¸k9QÅÊS–rò/:­Mþ~5t;ö£ò%7=]uQÞÍæ]j7bþ^À d9Ñ”¾GL æUÃYhTüw‚`K6½9µSÎ7)Àóò ¸M«A“‘=Ù‘”n˜ Þð=H‚à½öØë6HŠUÔ]£‘VRÆpŽÂùCíé?ömdU±­Š@*VåÔo<^PæÑøÉ²2¨õ!ä¨Y)”·ógKîÅO‚5ß7Ü/ BÔã€w”‚Žø›¾=8KQž°½ö¢YÈBm7)–É™ü€³ÁYì²ë:±ÃWqògYxºÓöë9X=CÐ2æ‹9-ï0#‚UA¾¨2©‰¤2ûÙ3Q8çã9|4·š5Ÿ$5>Š_}€’szÉ 5üØ"c&‹Š/‹…?­d“°Æîcß“`·ØÃ3<¹_ér¢ZÃZY›‘-¾}¹ÊÒsÁyÁœ:â?Õ¸¼šî“ìb~»{—_ÿ$ñO²M¼¨‰™lâTÃ×0Óø¶Èãî§ÜÝÇ}ŠÎ K;·fJ¦=ªÙ"âÏ9潌"Ì8”ˆü$wú¬¬QT.ÛY$ý(MÒI¿û³H¿ÛAº|0éïþ,Òßí ]m"}‡÷Sû1•Ë]&M;³+~Æu“_ŒY{™˜4*C–e¾ÒY`[> stream xœí[Y“Çvèq~Åœù-˜¥SDóeËK0Já–F;(‡ðr{±µýxyvr~°ØúÇ’/¶~ÄîÿôüÙ~°üÓâûíå“ÍxàçËÊ:lŒ!6ÏiPßhÐ*õ¿Ð dl9nWƒ ÝùšJ”`rõQgGE‘§¹ñàŠ”ÂJTà­+RËp^¿‘"[ ]á¹úàÄ*ôG ˆ8ª:ÂE|š[Â9~\(ˆa¿¦7 ÏÛ Pyía.Á·NÀ ¨Ç»õ»ŒÄ½pÊ»2ËcrÖ0„g4!DxÜ`óNŸæú9’ Øï6Å q1Æó9he“0¢j;*†ú D£Œégq ¬XÁ{%Óë“Æ!-E ßá)¶VâÀ¥TÒøóLSB¸ÃàjëV’ h!÷¨,Ö SHîö³ž¿â^׿zÀ£=Á¥¶ÒßjÀ0ÐVãj¿7¸üqpƒxÛŠ”pÒÎývŠÁ%øÍ gá„< UêP“¶unÂj"žù&yõEðrtÞŒ¶äóØ’]œ¼Hg*zr§Ã”žÔnå ã€ý‚=³˜1kNܸ²©O÷BÅ,F?- M¹M/Ô°¬‚e®òè…`‚àì– y:¤Ó¿WE~ ö'5)ð *ÒÎ*Òð`øE‘!FY1É»|œÇÁ•ÛQ±`C{tõ„qšf+ Y,—DåÅå^¥å70-PLÍö VEâ$3e 9÷F¼2¥íánAÅÞf$4’tâj™øœ7gYÄ,ˆvV rĨÖHÍÏѰ‹7‘9ec's²¹Æ$ ŸMc¼ò&3yÜvÂÐ^œY"ˆÐ(¥¶·O^èjñËk[3Ë*1´«³”Ê8gVO҇Ǘ¬bERD[Ø­Ô-ˆÙ‚4™—µT/q´ó¸„Æ]{O•‰UÅ)J:.ÔqÄ¿c¤ŽÕϪÓ|ÿýdpÕzÃÑòÓøσx4Äv.!Äc=1€ôÄbÉ6×(d ž^N v¢—IðNÕ£†ð1&/hëA›³® " &³qÖë9¿uä¶µ¿¯ §ÙjŠË¥íyFĬ„H ™ÏëŠÉW’¼ÙÙ±Kç¡m=­$4<'3VW&Kí¡Ó©x™µ‰…2ŽçlÀ/3ªŠri1¦­¤˜„w7.‹šR}Àg¼ªJ›{ð$¤S:–6qNt.ïÐKwµ&¨Ê¢—Ré­fÖ`j‹%oðè«+¤.•Gïªx”ÕŽÊZMÒß ÅO«Êf1Äl«¬°×I¹Þ4emª«TÆ/ÉUÕ¦$Ÿ:–ñÜŽf¢}!X5µ‚ꚥé1¿Þ˜î™¨Bc“X&aO‚ù ôi·Ç‹ )m¨Ÿkèù»5BZŠB# osé­ åaà9L),E(PÌýR€¤‚«è—‡Q¥ó¥”uÄý%³”ß¶Æ1:Ão®ñ¢(papCÀ ŒæxyâÀ‘Áâý„Ôhòr@_×s*MöùyŒ¶¨ñ*s–Ú³/¬ÜYÉŸÄ ‡º/*IÀ\áCj 1(\9ùÈÑ[)Nlm7ƒÅ~ßÞË)i(ŒæD'Ù+÷!ua+ô†”|7c_® e¶Ún8ÃIjÿu¼Àq5PíOk„³GŒ×ƒÂ¥þTÀ‚Æk/P?^ÐÜÞ K@yØ}Ê“ÊÁ¥ÒŠ‘õg!¯Š©`Ç·,¥l,e²Ç@!È,PNÓ\ðUhŽáV‘l {óšcîá0ï5aÖåå4_Ëc°œ:ZìDl)¿ŒtU'þR9›Ä 7#ŽK½‘ðKmˆŽb—†4»9SˆŽ2: JÚ:ð°'h‚ßH"¹Ê¡qtº£=ÎùM~º[6ï•#òŸ¶ý|RÆOò63Œ+ýU¿—¨èÍ–‘*ÏÅžpÊ¡Æ.1:¯ŒYR£¥èüÚâÕgUýn"’½né|´™—aŸmÿʺʢ«>T³Í®K鬄—ÖCŸWS £ÌWï³1™#†dµÀdT­™£º¸vÅIîôósš×qö‚¨’€Nó™“5@PËmÇ¥ø×.Àâ*üûˆv§ÜlaE· Ú!BË%×Qmîž¾A(7\¡ž²ñ Å2J}&š¬ŽÂÄRØ_Þ…;6øºÃ¶É5áh´ ^ú-< †i”ìþLÏäR³Ã.&ꉾÉ-ÑaólTÊ¥Ÿ¬ jⓉ«¥¾ž´låé¶Ê›Š³i¹ò"æ,¹è’÷rãºÙmiœR=¤7ÞRV^‰x2݉óõ¬o*Jºz/ë¹0œ–À¾h7 "’ñ(.ðˉÂKG›ÁAm¡DæÝâ& ya©œxOþbÒò1_ìq*ÌO4y6†øT}.t/E›uMP žL –ˆdèó„T*HÀc®Þä'Úiêysð:Ã8W3|wG¦¤BóALˆ©1§ŸãÚMe'ëj?Õ·B‡(ŸÄTi]-@,å†(%¾ÌÕý%Ð8™ó=V§RiØUñfÑ[ئú¿"%Ua+ó±fw3” Y‡éCd6T¥¤µ¹:\æ2I ‡ ù‹m‰«VCzBÕ!¼./báÖ-a7š€AñS+4±È˜í+Vmvã´ãXò¾åI©|–/Ó·MÍò²ÏÆ’6Dl‚ÿ}>ýMñò‹IËÇÐò…>Ìá餆ހ‚¦û÷$fehø#fý³n³²oþ'¨uMj–œXlj’nQ%x÷¬çþn 7ƒs´ã_s j+ÓXÆZ\t”›”¤m)I?ì!…f^‰€™B3%« s¨N[%¯ü@—*ÖÒêî¼–"P° òs|…¬\ mëOyoôñ/U´cÛØkT±7U©"ßyˆŒ…Sm‰Ù\¡>o kD¥)§å¢w(4U¢h²¯2–Û Ì×y(lÆÉºŽ… àýÈ$·Å…Áœ¯ª8Íã,dÝ3x+~cð¦cøŒü;œ¯Œå—ýÂî½™ðáéwBù®mæz]‡ 8sƒÿ¿šl7dé©Hš.}ñöoΊêæ?qß䳯¢é‡<.8I” ì–Ftå©wKkNFÈ}£)c'æ¦ÒÈA›’z“pøî/ùÝ·%€Š`¯þ8G3)ÑL 7‰–«ÜÈK#ŠB¤Mdâsg£ÙIm¢Ší73U|$­€ùÏlŸ,þ [‚üendstream endobj 260 0 obj 3163 endobj 266 0 obj <> stream xœ½\YsÇ‘v¬ßð¼?`Þ¶Çæ4ë®j:¼Öa›’-ɈØ{C! ÄH (‰ÿ~3³®¬îêÁ” gº««²*¯/Æ1ÊÀÿÒ¿¯Þœ<ÿÊo^¿=c0“ÓæõÉ'’ÆlÒ?¯Þl>:…qAm”´›Ó+l”r2À<“pZ„Í®|+÷”/6§oN†O¾úÓŸO·§ßž|zzòå‰8´†…+0Õ$qH¤Üx3œêŸƒÜîì àãÿNÿ'= Gᄊ„MÁi#ãñrÚ”kFêÑ»:ÓÇ[;üu  å†?maܤ ÃÛ†‹Z›át›¿}º5ðM7|µÝ©0BFRÆíÎ)¸' Ì!‘ø`ÙsÿÀÑbøh»+ó³¥à®ïVªáå6ûx»“§ñxŸí³{0ÎûQ¥}¶ÕÃ7°«ï.a çpôû~ZyÚô3øé‘=ÜoÍp O]¦ÒÒ¥÷ßo%^3Ã[¼»a¸Úªa‡3ÛµgÏà1¡p°ök O-èá]½úç¥ÉoqûñTq2\KÓ·ý®i<ï*‘ q3ñùØ,¯#8îzOÛZƒ'ÂØ¸ ¸c<z„(ЪŠo˜·Þð·záËP"®SB¼FϨI<î³ô£ˆ#ø@L'‘Ÿ).°£Äz[4E`R¦Ðb\YD”!¬ó¯¯’ÌF•ª6–¡#Çû™õ7ÿ¶8Oç¢S…pöx¡Ìyg ÍÆ=Ùx{F†&Zbï v1å¬ß^l»vYiàÄég'§¿ûçpU\ ŒfE—LßðŽŠæ D?ãÇ ¸*ïÅè;áwôìEšNùoíËÇ =J–åðU‹„âó“WiAP¹Ÿëýÿ¦««Ã?÷eôu Å‹…fOKÆ‹ßÉ»¥=Å?×»rQÖ‹¸;+~]놔]už™€ûžéyÇG2m(V>òç¬/£xŸ~ëÅ6*käTu=´ÝcOâ÷ãa?‚5:'dI?Ç`ä¯Î¨«r‘•›rñm –+Ï€𖜦Í4M”‰'®`qÕ6!îax¨iÝ”Aa†i×Á¥Ý7UÏbR­ÍÖd\ÆÈ)Mó$t¨´«Ÿ=Âgø<”D(í¨*"ÔÊ(D„Ö€ù ¿"ÔzB(h [rX޹š‚EСúؘZ¢DбsÐ=KÅPÒH—¤šÁ˜_ ,x‰¼×0ÎLÈ5z+<ÅìX¢¯Ð•g9Â%Qžs™' ¦¦JõPB¿&$£¾'ÿ{޾<9瘯ÉtÚ“¤3¯^E ÂªÀ¹äiUD‹„˜žñ^Eîw%-LN„‹¸?ÜHÎïÅé#î ePŠGšÜóšo¢dÃä. v㈫`Aà?’ÂäÅ™cg_÷õY@Ò[ÁŽÆƒX4Ø<å›–“+I­1n™œ-àñ"Qiµ$¢óuã‡ZK ™Q±§Rµ.æhœ/N>gR© ëŽ,?𨒠jU©rR¿ÍÅcÒ2嬲ÈSÕ9—–Éí ¬§…›M̉[mLãÁ¶.¿—ÀNg6ËÝWib7*Ū˜í¢ÜkÖ§fÏÿ=¯¡9¶`Z‘Ñn""ŒÇg€A †å«¥ùI[+¤ûCe¸ÈåF[Û£»Us¡˜3œ©Åš æ‹huož íê¡À³•Îö€6ŠœÎÐwúm'P–(SÈÄùQ,¨N1Ü"5w—2V¤³,—ñésüý<ã<;ŸíœCΚb¥äsª—ð¨ƒKºIÒÆ}•R SãʽÍs2ÓV_L”Õ¼r›´W‚ü@·'~*'F‡u]S”ÍPb’ˆúCMpÖÝusŒ­]îéŒN&o1Šñê§rÿ›Þ¹êýêLé¢zºK–+Ž FÕ׬¨Í]ÕêZß4¤äģР•ìûôÿM.>°¡jãîÄÄÞ™}îÑJ•IHÝÖÕ¨tð Ý Š„ àcð:™%&>ØŒª"o1z  ¤ÓPÖl êõÀi1Fr˜El!Ãd¬KƒÞ¯ÌH›ÿ6â©Q)Š;W¾b©¤š]æ' ‹ì”lnÖ"}÷FZß;%;:@¦%âÄæ°Z`gUóZºXÅ^²æf– Ý÷ž|æzœt7ÓÓEN¡$ASŸVêÇrªké%¨ÛäžèD=V~˜ùnæOÑkA[(L®%*سLËJ—j”D¸­Ö¡Ê~›:€±s0zÉ›ŠGÅë”f ýx,™©Ø¯M-Õ“Po;{é{(¡{ÚmšÕzÁ},æv³_‹N(vÛ–¶Ñ¦Éo¦á,l)ÓFÒéÝ$º-~®ìõYšŠBÊE¼ÐKN>>ÒSv¢y+¢~ÏÆ6isS(Qm ”n»Z¶GwŸ¢Äó’˜ø¥äZz??ãMæÕž*„{³NŠ`TÙÅ©d‰Çþ'5Uá(]ÇÑÁðÚ}Œ„ÀºaÃö­ —žÜ(IYiò¦/Ú(“’÷r~¾J•ðnOû!Ja*&Á:e&¶‘&®&™´\—öøý»”Ë!NÓPE;i­dÍ[Lƒ|(^&L¥U‰÷P-t´ƒx?žJ¨Ý,5’²l^Ĭn*N¹XKƒ9æ&Þ# TF5½ô5jNÄ0 ¦0Á)‹Ýú=ž¨RÊõ«Þ­}OßM^ñ°)+rsѫݔó ì¬Æs?°Tìÿê{h&^¹3uÀýRÍ\;5ù™i*l«•žw1Ì™ù+{Ž*,ÊÙ£±“f_{“*—ŸÚ”c±ôñ5gxÐúõ"5S [pT;ʳÚò¾,ñ¢Ö2j„Ù_Ye£vùÕ§x$ï?ß6§E|±=DZ‹{¾&fÒÊE;Zޱ½ëàž.¿²¼˜”Çht—†¡Ç±3½Ò#ç%"¿,ÜmjY½qÆc–|ªŸ³dšMòø Û³œñ}9ùÀéÛ^æÞS‹xJÔâ[,'— –ma–e •¶< ti5kµÛÈ3´ûX68å¶§Ô¢½K´¶vîqR÷¶€»Ö~¼.RWû³VÆ#uÍ$L–ê[²VdQ”ºœ¾/uOœtUêVæ;(uÌ0½ÎyDqIº­’ÄœuEø²‘ÛÃcWÅý@>¬ÈfIŒ]¤÷2oŠo,Bz±CêyawWmR*Jt ä‰FSÑ`ásruÅM\R•ªê¸Öwmvƒ—¸KU÷lm"©Ýý8l†åïøÁ¶±MFirJâ÷ú¾X¯tl.¾/5‘&oçqÊq`Þd Îr3ÐY·ô×¶ÄåEJoø²Þ·h2š'ˆfyC0urÐ ”pS5š_Ô×ͨ‹õuc-¾µƒxß²úºƒ±’ê]zôvrvÐXHX>ÝJ‡)®S&lv‚¯!hçrõ\Ú¤R΋$bôJÑj¡½ó©l.½oªEÁýj«í¨°‹=ÿ ¹äýd$A1JK¥ú;œÁ+‰a”¥ô"Æ^ÎOª›;Æ3’ ‘°÷NLméñÓÀ+˜Y'Rõe«ô^ZfÚU;/|}a«„mE½ä’Î ÿYd©êü"®v¾ÿy&ËTÆIL[^kÎKë. û± †ßÖ«¹¡Æ/Þo94?½ËV ,¹Ó¼qrÅIñAóÊå#…?øöŸÉïü-ò\Î4Õƒ‡så”TîåÊEP+¹rGùõS¾\ ÝÍ—ëÐÍAvÓå¹i:USFÇp2‘æ'Í$(cœÀqJ§ÊkÃmxV€ÊÍ¿dÕc•“¿lÕùkø(.šG–<<Ð#J> Í.ï*²ƒí›$î¾Îm×LC—äe:œ4†¯ü¬¦IÅ^äZnhš"ÚT^7¯ºÓ’ò–Ìk3ÑmsvZºñˆf›X! ¶;®.ÞϦx«5lü²Â¸®‡—É=p“Âò#fÀÍ»X$ÁìiþÛ%~A=e ”Ò¿"Mñ8™õ<¨5WúÖ imæ/S/·,ühV•±•ø¾2â+yšäú5‡ÉNÞ·B_2àLFg`È75¹Í“7Äã12õøÏfZÔJFÝ”‘½SY: xÏl˜Ž<¦ c(?­µiÓÉ«Çêfú“"z*‰ùöÉ(?”yÙ<¹¹6+íÃ9Ù™›~è Ýq·ç&f›ÖdûvÍ¥"ërµ–•C±–)JÙd‘GŸgõhoºïI â›C‡ÍF* ÷Æe:ScÓŠ`ØÊ³Ü>uöÑF Úiêäl¤Â\\¦MÃ?æŠ"Ks4.p– YµÉÝú¨uøG ’tžG Œ¯ÙqõÅÚôf ˆ˜«/Ö(°ehÖ¤P_yùð7kúÓãX…«Ä—jÄAš6Áýh¿…á*Qk…ꉚáæ=-¹|ÕwšE8ÿÖDj…_oE|0¿SÂá‹l˜± .ŽÜž²g75™U_ÒÌÒÌs¸”4“å›BÛKàì ÛÿÂ[1aFCKúÝâéíÐÂÎ/OþT_FHendstream endobj 267 0 obj 4851 endobj 275 0 obj <> stream xœí\YoÇ6â7¾ç}ß2ãhGÓÇL÷(0 Û²aNb; òào1&µ—”Dþ頻¾ªgz/™’ D0Dîöt÷T×]_ýbÖ6bÖâþ÷ÑåÞÃïÍìl¹×6V};ÌÎö^ì š3ó¿Ž.gŸïÃ<+gRt³ýS˜¬¥ì……}†¶W­Íã§øL¶íÌ´³ý˽êÉ÷Ÿ}µ_ïÿgïËý½ïöÚuïèfB4mßJ÷žÁöJ Gq¯fqÌHØÞâþ?T¢žwUS«J¹ó^¨¦]µcÿ¨Eõm=WÕ7ðåËZW¯çr€·´¦ú žý¾VOà‡ÑÍ0¨ê{œ ó`‚Ð}õEÝUƒ4üÖvÿÞÿ³'O=$ÕñSÌ:Ù7@UNüÀ­;!qé\wçÌUÛÀ‰†Ùþ1LDJŸÁ¿xTDÜ®]\Ââê è\<ÇO'øƒ>ÝÀQ–xwÔÅ)¬=²§:À–fÜ"Ù¸ü¯VÀ`<&í~žû1kªÃðÜvîE¯a˜maOÜì:}Å•´ŽÓÜcXÛ*Z»¸åë`Ë®:¼Ãdž#9¸—Æålo¤HJ¢ˆNP·øDHw$z-ð $ªs ñã †qÈ*Ô­á]ƒ¬¾ª‘çJ«¦7 =ŽÙ‹k$ŠT)¬‡~€£áÓMT >I",ŒE™ù~ôÇÙògu8˜nuZËjq‘Þy‘6X¼Jg 'óÎr- Gšƒªwd0x2§3ÇŽ©Ò ÕaäÏ1é‹vÚ+ÁÔ™úv:°$&lúÞõ|h¤lœíõ‡6/n,E˜z‡ä ÏKûÚÆô­èÃdó¢öMfh²Ñ¶»¶u‘LÛt`Yr5™ù¦ÜÛT”7íšxn³´’Œé-éñ2ÊÕœ†¢ ,^Ös?Ly÷ÈSªž¿l.tÛHðbh¬{éK4e4m\ ç#3þ~ÿW…?_ã ¬ƒã´­EŽÃ£Ú€ ~J«C_Ĩ”ΔЂ«ñ‡ˆŸ$ü(:<"뛽ýO~/ ^¨_ánZA®I‚I\äì,°l¹¨†—eÐE_lŽyèÝÛ.¿£ k—¦ í[ÝOÆè]¡ôAähÀ; ’(x#vókˆÄ‡I50ºËp§ñ çu¢këjך“½`^QGúæ›/^ÔÍó¹ì òÆ_g{s jè¦Ù­¸C«f̰V%R±:ˆL7B—“êõoø†j«\sÛSP"ÁÓÐÆðHnsüuÒNaÒu¯ItCÁFöÄPÝT2FY¾Ä^®4srß‹¦R]Cù™Œ%äv³V ÔGð ̳æ†Á“º£šŠê–‹VÌtýÄâ…†Á‹ŒhñÞ‘‚k(¸×è0ÆîŠô‰{]¡¹ ”w~Õú²³­ï½/›óL¸ôÛóì÷‘ÙEmÍvZ U?ÕôZ ”Ó‚vÝÛjÁv÷Y¿$Ï ™ˆ ä ð÷3i¤†&cÒ*Í‘£Ê)&õS† &¯ɤʹþ=Éd‹›çµj^–ɽ_ð¢ÿUÒ9¯ØtźªuêÑÚC§¬3D©8Æ»¬”^r7mn¨úiÔUK—‡˜´P¶(´lÑ0˜<þ\ÉŽâGütGÙgµ Fe~/I]nðE-Ãâ#H™‚ÝÛQ1êAŒûÙBœ_‘U„wQë€ØXM¥ËÆ,ˆv¿ áÏ8”vÿmÚz 7­èÌûùz¼ŠÊk+¦<¾E‹°SJX–hòë.GS rÕ'YÍZ…þ„и8j Í€Iž1sÁáQK*µ/ÛŽçÆ[5¸vƒ¿ùUY¼qKm´‹W®.§@¹Çc¦¼kÿŸ\©Oú¿qŸçq ÜŒ&zˆ7õñä:C—_•ÐÜOÆm>øs–4Ç\yÍ1·¦1ÖU )ó #9rÿ¹ØÞÜ{¯#‘Ü*ô×¥ÝJt¤™ÇéÈW%À;‰%©ý`~ Óµ6üIɺŽÒೆÏðø³LÂ÷/Ö&Þ £¿ötòݲóƒg骅Yô9ßÔU^C£uüÃgÉÎW]¥„[òŽ~tY|Ã"Í}ž)Ò<¼u‹Û”¤[ÑD™dºu÷A·>èÖX·b6ónûð§nO[ãû,ݓ çôï}5è3Éì)]TãÓ’N$]LÏ*·,±Þ nбˆ*Õó¿Éa’ŸLn2ë/aÕfŒ¡ÿ‰§sÙß!ÙvÜÓÇÚi‹ ­˜d²qCJ¡Ýëb6ÿ.Á2†»S“J~o»¦Õ¼+ùЫ ùNééÓið"NPNá/Ãì¨~öë4ÛûÚÇÑ‹Çz4z"ÅuçÓÌâ&Æp7èÓTg×é’z˜³IWãg+Þ>Í‚·ûÏaù.M`2·©À-Å•þ:gÎQŒ}çÁË$ìÃà­Ÿ\Kdr’V Š—Œš5†øåÉaÝ¥Cý6VGŒ N&§ž«üË)ÎJ[çâ¸áì÷<ÿ‘S8¶•ÜL´éa¦tíDnÍ›ôÖGI¢Å|!ñçjƒ>¦ ‚àŸÿø(Ô‘ÝÛ[ÐoåÅWßd¼¾ƒkCÖ·Ñ_øÔφº>KýÎ#ǃY+ÿWñ¬Œ ²÷çx“Bò¯ØŠuT´?)âóÒò›qõ{’¨N³¦9ר j«Ž¨$˘eEµBÖÈ‘êEëMÊ]?Ýu’á'In±ã0rîF>ÉF\çZEÛIôžÇ~Bàô¿§ø?rοRÇj¶±öná’‚ÔxXÞÁËÞ£KN9ö£TöÝ›s~àú?ßÄùkƒ·ÛžÒsÙ³†¢˜šèx;jÜ!M˜é¡(WÚámÒØ§BE9J W]õÖ„Ù‘5,ùÙÌÛÐBÉN ç Ä”©NÞ)% HzÀ:5Sw^’ÎAÆÓÀÿÑiÖÔ†[lšâf ìÛy\úÛïöþJ kendstream endobj 276 0 obj 3900 endobj 280 0 obj <> stream xœÍ\éo7–_ìGýý±z7])^E2À,8ñŒ“E’6Ì,¶%9Ž-·#É‘ Ì?ïàñXÅnÉ×bD.ÕA>>¾ã÷ê·Í4ªÍ„ÿ¥Ÿ^ž|ù“ß<»>™Æ`ã<Åͳ“ßN½³Iÿ<½Ü|s ï½ÑÊmN/àe«õ¬Œ§ÙLa³+W噞¦Ÿ6§—'÷?}ýðt{úëÉw§'?žLÇæpp†Š ça"ÕÆk)àPÔvç ?þ÷ô?ÓjœæI3a1ÌÆ*^âl½Š›rÏ*3ú¹Žô`ë†?máãIÏÃ×[x/¥ÃðÃvgà¦1v8Ýæ«ï¶®”‡Ÿ¶;â8)&eÜîf Ï”…1œøî¿ñíiøf»+ã‹©à©…k§ôðh›¯lwjÆa<>OëŒa£ìh쬌™½uámtjFª`±.În°Û]ŒqŒÊ ßâ]Ïíð_õ6Úá®fL~Ej”¶Ú {¤W9f•^u>¯¶UÞ7°¬hGkÔð?Û Çh­ÃÂÌdüì‡+|ÓkÅ×âq3‚ég˜“ ñÎÔ­¢ Ãèh“ÿ|rúoþ¼50²^œÃ’ n§ß_ᯆöà{¸Ä÷pÛÔðü¦«Ñÿá7Ð g[KŸ]ÿ¿nõ°OcX¤ËØ@ãþ$ñ µãYñ—òŒŠoÝÀï^æ( L #_€¤Á®ÛHožãׯøMVã£0óíú&ý*/ß<ƒ&”=Cƒîq¼‰¨A qvãI2#!VVßÁÏò¿@=rÞè Õ4÷ D*ódªáïAi'0Úã$ÃÃíŒ/ûyØ_ñ—ÓÊ@@Ï#í;_ÝHÚX/‘ÍéÞÓª,çõ.n¬ DàmU,$[ãl?sÍxi6\ë.-v¦Á9Ð1ZóYÞ úô%^•í‡ûz$<ÀTí-½Ýa% ‚MÊ;KQŽ`"ä2‡oa|×ñ8ËÓ Wﶺ§VÚ½iŒ´Ý4·»JО¨§û[z)óí«-«MCpTSo@½G§'“9¤=7íÕ;üñ:1Æ·oÓuúñ‚m)(`¾±Ñ“0þ>2]’º¢ÓÑëüáã*ôïhð¿Ã¥ž@ôòkoÝH7¯ëÍÔP0‘òsyõ¼÷ý«÷™)]å5ƒ¶¬(ÿ¥~ú¦Üª~-y˜o6C#ãqXñ)hé±sãT$DŒ÷œ/­ ‹WÒeOôvi`¶qòÑóø``!¦˜,Ö²úæ ÿ f–,jzÞª êhIõöddÑ8ãS9ÄÉâ5lJ¢ÝÓ9åÐ3ff|Ÿ½Â>™aœS¡w™µ]å£j…ò}‘FëÍëÆ¦º §Û¨ŽxXG1rY/W$×P›-ˆ¥g5ãwÙçl½Y”^h67Ù†ÞʦéøÊü F·®,OûËVÕÕøH’ì<êjæŠþãìØÆë²˜‡ÛêF5(A*s<+Å¡]×ãܘÜ2@5ªÕ•íIFX`×S½ÛyÃpùûÂïnG…:îL4£¶ì²!5¨ YýŒ¹Û'% Žòê0_èP ä¶ÿê¼—û@äi °âÇG ¦iM€"­žE./k™ÛìþÉŒuÄ`] K‰÷‹‡ÔЬ3Øy¤œ`–HУo®pÛæY ³~Àrí¬ÂÁçl-%ÊKÓÓØu —U„Äe‘µ«F»Œ¦EeÁ’BZ8ÇŒÌM\‹/nØ¿LÅ ©CJ7z=Íœ–Юˆù WQ*ôžÆßÙɯ±Yq'Ï“ä .‘3P3ï¯0N²!€ñ¢ü«ô™QŒ—–ê2¢·æGÿ…½O ¥²­ˆð‡ ôƒ_‹Ïb?aŒÎ.ã]¢I…¨i‰ô«‰¢ÅÎÜU¡Â_²–Àoàð ÂêcD\,ä+Fºe{.ë–ˆMÅ¡Yq j(®˜”æw;ïq ¹Š¦ƒÿW $Ê—y饅 å o£‹„òy­Íl]¾BL"â»wü{‰ÉVàg l§°³D Eñ.BЇ®“¥Ï I“p4a‡' ½iMŽóòšGá‘1I b„U¹3¥=Þ?8™]ãå>48‘("d €ØµLÑJ_ü‚9z¹–Þ•[Ç™ìÄN3)±Õ^V#Ñ™Ÿ ©'Õ„ñ‰‰Y¢&Eö`›1ÌÈY¤4y$Ì á'={ž† MSh–%_˜ðýˆøN‡3<®:×ÄD”JxÚA8㛤ô³°ÛBE|½KØ©q¨‘ M^nÞâ$ßø+1üuÖâ|ÇPç4†v…o$Âɨ怶Àÿ¬™ÅI'(÷ÓÊx¸Õß*å½y"ï‹ö ¶ÂBäŽj†Ð¨†kå!b òà6Ô*–ÿà¤V¶V¡qò÷Æhæ­?” Ð1p¨G‡¦†(¸HA:D±ÄÝç%h¿©cÿ_YÅôô Þë%3Á†0“:þmÀoñÇW9À­c¬Ãð–ÇÝ€?ÝüÛ¶\~Uƒóç½(ÿ¦Î,O{ã_o;©ƒOYXÏ[þ÷嵋&ÖVj´ À#òÇR$F&G˜k¸BÞ#‡t›á?êï ~§ M“V“–hûfx$\ËMr ªZZ@‚·-rOqºðË%RŽúð’ü‘%$à‡7$é²Ç Øw-ðJªþ  ÎóÖž‡0oÏn“L!P$m&ô›e–e±N…“z¿½Ca×}‘Ëd3k7©‹v®ø]ÜwàM.Zäx/RcŽ ¬tir“d£da/¬»JVÊR™ÃF~/¸ &ˆI\™Â|hç…£˜ê ÛC™¼Zæýï <óàUÊ‚àþGŽ»üã¬I3# E¥þ!ËcR/ðÖ“ þp´{•AÖ2¸æ&åjÝr^»©ˆkB8ƒè^ OÀàó•§âEÚÛŠCиú¥’dPnOg­ T[šk,%-½s£1Nc Äjòš$Ðnå-™ùÞãr…ÈÑW²]‡`£ø}mÖ†!’QÐ]¢m¢»Dôl™f5ŸhvZ%š£vL3=eš§Ø3&`ZY/Là¬U6py_‹âçeèÙèÐ2[Â-Œ±ðíU ‚&º©qiËæ®ˆw²ü— ¾–†»üV`É‚° ;…ìžfÁåx¸r¡dZÛ3ΔDJÂÆ8CEã@æ ¤{zyòÍ£“/}¿¹¹zs~òåÏuòåŸðÇ7?<€}»ù—“ïm~<˜¯]R™¶0R‹5¢Ô”°/"pQh?Lç<ˆ×ÿ^K"o·ØÌàXžo%ùÈËä2*†KY¦+’eV|·bAâ!j%èœeè¥òÍ,„“9ô&Ë¢;Ør§œËΩØ×Mq\˜M—„?]>yÑ Ùsâê–¶å6!ÎŒ"³¹Þ²¡iM&PY²`> ÿJ?öÙµg»Ÿ¡ô?~—C[ ²¸Rµ6‰‚™ëUˆ¿ð4²2Ç?dîéØ:Î+óŸ|S(ùË0“>eA7íe”6_(޾žoš1kÛ¯1ÄLg7±pSiØ¿jŒ"p„rÈb)‹¤w…›»Ä›¦åª2çïß`v&À<`9FÍ`ÉEYçÉué~—O0Îß W0á™Ýíå;³Z™ê1ÛôjRø*€QšU;BA·9Ð $wZs†q· 9µ(nîè'%Ì^‹Î‹j8 òЦõØj¼´J›#NRÜË–­<ï<|ʹ³• N=Ób‡w·Ûe8×îI›zÔá|ñï•l«%’„1tP"@†Âª-þ “|Ñ/^ øÖóeœñEb F'êB˜ÖË>§Ý’þ>¯ý½vŸÜ×cmtjê²çÞV]+yðU醱8eÍt£åýŒôs¦AØìƒëpTá’vQ#0óÊž#E'~4‚73Û¯KY9H<’ôd/Œƒ6âì˜*Û«æ¦IÓÏ<ÅëuÅ?몰™T0¥U• Æ8¶ÉËDS³p-8zžÂa™ªiBˆa],Ý›³ë-‘ã§ëÞ œyâ½ÖM¹ŽÞ­ Q²Çw›Øa¨ÅcªÐÍt›rZŸ.óE‰c-êíIie'yÛ†RŽòºjõÚû•P‡P ö§ ?I€Ùw„ è ͼù¸TG€*`uuð ÁÜg ít$jÑèσ‹˜%úì„bûIKçG…¡‡¢© tÙt„‰ÌSí+¿G¹ÊENñ ªjÔÙÓß¾’ü}P‹}8º䓇®: ?>¹f<½<2…ÒxÜI'Š5³Ëñi72% ‘"©nkQ(&±Ò"Ð8dÁ¹å»ó³l Í}Þ8Ø@PŸÛÁ`[H÷6áZü$·êm-5Ô­<Ý®MªnQ²cvgÁs9¦TNÄr®ÿ@¤P¸©Áy'‚ãûc×]æE‹[ž–Úâu.zJŒ è^W#äÖ6Ú²EŸ ¢Æ”¢Â ØÍl„š­3ëÂ:léªoÁÕ^”°§)5“µBd“[^E3zÕâüÊ£÷*bôósNk0¹ºa¶HN¦ ñaŸÀÍ¢+=ö¡m-éEáÕ¨‘añ\óê›-› ²t[¼¡»É˜­¢ò¦#†í…™¨1ÜoÑQ]”´„‡Ïhy9ÝÐm'¬H²)/ÛWP­-›Óû©µL#;Å=k-ÿ"<¥æé®¨Ú¶ÆÙQgæán¡Ø ùTóDòiíü9ƒOe=žãѶÕê£åÄCE!Ñ*ßt™‘õU%OäK¹e `Ø"¿ÅÍiÉ&aL,çnZ=Ûuú¸F“PgXdc¾.5ךeÜËþ{Z‚%0ãHµÓWz|®¥k×äŠ@8ìí;ÙÛù îïÄõÆžŠ‹¼a·žî„;;á +(©EGzzeãF^Ï{&|ÿ–6—f1͹{åÃïnó‘‘OËQíþ=OËQ“SJÖÑ?äF¢ÒVì”h&ú¿ø þÀ³Ê"9v¦ÊÍD¹÷.·eûÜž3<)¾¬Dùx˜Œ_úKÝ›ÊÍßëÍÚÐxÕ’À7 V8wÑ2X³ŽÏž…n>k@|AV«N«s*QgÛÔ¼|€9ÜyÕlI=v `¦¤)ÐÁºÐ_îºí*Œó¦×'åäÙç+&|š–'8:àÔ²ÎÄÈÎv“k½ê)Ÿ-¾gÎwjÊyžò¤ºXæXºÛD‡uÛÖ"S2ýŒ§€éÙcN±¶Æ«ûà)`ÎD‘A¼Ù6+ÊÍkwî¤#lz™º¹£rËÞ&¨4‰*±màvÎó|Ð Îõo'D]>AyÎ+¢9hUѰÅãVÊt!é“Å¡­!ãÓ`Ž˜bÉËVd_Jy+€²œ[¦xå€ÊÒ_n8[äOr)À,ò„+1äuºRMãsõ¥oêX~¥Ÿý9>)Z‹¬b7´(ò¾h›Xûg\nVë[&úsë\Éà ¸¬¹[üû3µ]Œn¥3›m-–Y(mÊX9¯ªøÜI[±=vÚ/ë9þ]›\+Àíˆzržå"ç‘Rô^xnU5åí=k•=‘w®íEŸ•¼u”—àãP|ÜH‰âúCÌ`ã¤ùø¦ý ý~'•û10>í™ÀyùûA%ÈÃ_“@|Ä)ek±5‘æ!ô”“AÖ~Os <>@2-eÊ|ÿÎsš¥.Ûó· & In-éÊïvë# câƒký$Õ‘þ)ó¨ø,øÀí¦ÄÔ³r˜ŠÏð#¾“ѰŽÃ˜íx2ÕøIϬÑA¬¹–M„8ôԢʼ×;Q¸{²—v#ù³w,ÌBñ‚M{iÊäVÓ"$tѳöMÖž2%ɸ±Dþý®ü~gA“”!¡üñä %endstream endobj 281 0 obj 4864 endobj 286 0 obj <> stream xœÍX[oÛ6~ׯÐ#µU o’È`-¡-°¢ØÒL ¤‘ØuæÁvÚØÉ<`?~<¤x³èØÁŒ­ÀX‡·sù¾ÃC~ÍqEr ýÿñ";¹hóÛU†+Áeƒe~›}͈“÷ÿÆ‹üÇN4§¤Î»©Ì)mˆPëHÜ0,òÒýr}ã¼Åy·ÈÐ닳·]Ñý‘½é²~j:'¤Â ¦f)ƉѸá-‘¹“µT-/`ýKDвFUÁ7?ʆ° “½þ©¨Ñ¯ |Wpô‹úÁÏEIQ§É+Œ[ô[ÑŠJJÊÑYAÐEQ2= >ú¡L/rÕ½ëus%#I^Ó¦RêÄ*±¢äjášP3•²&œ[òšÃ¤’´¬ª•É5ñ¶¿†f®– RÍgè3|o ùÍX5JsBÐ >×ÐŒ ÁjC)T—@/Õl†õì7ÐõšóôìKí ßÊ}TM¢o«Áµ›´ôý“XCÓ¿ñý_œpì…+'\{áÈ ÉNLÿG?é|ïòÖ0ℱuFÁ¡mEˆ”y÷>ë¾»DSð„²´¦X‰Ç*==æš4>ë¾—ËVÍäèrõÇO{E`ã@›Å_ôj(;6Nˆ½§> IßÞ;áÌ —Nxë…Ÿ '=õaØZ»i¦¹úÙ]‡~Vôæ ð ïšä€xíëëðoF¸ñ”ã´gÄ6CbKúÁ_«ˆîRÞ Tž†p´ÂWÊ%¢>䊦]§lø}?W´ÁÚØãïÎ §nRïÎ`«=ZKa<ú·Ùþ`Þ|_B×+»ñ6 k ÉñÊEÚð*­Ùcè'Í!«Ùf·fšdSÿmÀ±ñ‚—IÞFlÀFÑï~€ÄÒ2”5Ñ©5ƒõæ;0bÉ´£íŽŠOù:½M|TBfõªç!µ øÄŽïKç×Ñ㕈ö }ý3tZÀä©síÁ÷)Çϧ©<ÙCœ3 ÞS_…û0tóß9s•òÐöþß’3÷ç‹EìÌùy“ÊηOž º|PÒa~&¡âáfäƒÚJåïA!¤«tÈö„$,>öàl‘Òd;4×’ÔNÿGúgpH–Ñ)éê ˆe fnW'iNBDèìÿA -öÄfâ…3'|Œœ”Fðn`®0o¶€¹ǦfÇL=ߎ{òÇÎV¡¾•ÆÀOÎDxG *Ý?­ ¦VòU„ŸqYq®®²:ìÔ¯˜³¥äöo5Z“ˆ5ªèjžC¶=…«¯q  övDd °°tc¤ê/’QéxŒ$ï,{æÙ”"ÇØV¦($ùIÏ!¤¼=ó0®V8 ý7¼âŒRÉ!¸å¯ý½ÇßSÐÜO·b÷ÂóTáC<ºd‚ìX$C ˈÇù±‰š$L­M-I┵Mo!Ã}Ÿä Pp:¥Sô Œ9±`oã‰6.š8ÁeéÒÖ#îŽÝûêjÀNSÛÂN3»òŽ‹üAwö¸ÜK¸Iœ•á½ô +SO*#ë×Ô£Íà@ò—à ¢W¡ƒWA\W„æ%«Má¡íz o‰³¢†LS‡¹ï¡ÐjÛçLOÔ\¿}¢³î´‚P¡!ÜJ½¦bWj6Á«&á}²‘Rw{)‡™\ÙGÑÿa»¥ÕAåxg\§ÏUaçþ¬ss[é‰põX94Úã>Ì+5¸¼ ¥àS;Öî܃;õ;ñ‡ìjƒ±endstream endobj 287 0 obj 1300 endobj 291 0 obj <> stream xœ½\Y9r6Öoý+ê±Ò«ÊIÞ¤æöÊð±3nÀ³†¡Vëò¶T’ZZ­v±ÿÝÁ+ÈduU·ÔƒZ5™L2H#¾¸øv³Ìb³àéß'¯Î¾úÙmž_Ÿ-³×Á.aóüìí™ 6›ôÏ“W›oÏ¡—)Ìæü4ÖRZᡟ°XµøÍ®ü*ïä²lܲ9u¶ýþço~<ŸÎÿïì‡ó³ŸÎ–›Æ0ðº ljDŠ“Ð“Ç®~ÙŠig¶þüÏù¿¦ļØEF‚·J‹8E«›òL 5;[{ún2ÛßOðñ"íö› Ú/¤ßþaÚ)x¨”ÞžOùד†_BÛíÏÓNú0/"’2O;+áÐЇ@â½aßý¶^¶ßN»Ò? Þjøm„Ü>šò¯ï¦°ØÃ÷ižÁo„ž•¶²[ëÜ,ËÚ(ØF#,R“5Áš­™v!„93S0ˆÖrûhP‹rÖmßMrvNŠÀ¾Škà½} 3˜ƒÅŸï²é#Ï^â˜N½} ƒš2l =N\í­Ø^ÁGÞÙí'ìvÌÚ<t[* ¾’ô÷8§í HLÒZ½½†_Ö©±# ì¯JÓ:záÜößÚ¦óI,b°éyj>ð §1¥¯³.ÓXiòç茄8£*WV6–V?„Íù¿ÿÓ/°8FâPH)®ä.þ h±q™u|ü8VU!-Ûý¶øD÷ÔŸÂÚPãë‰V™uûÇ-›IÜ¥†]HäFosGø¥È½%žg}>›°'±_ígkÓÒïgôÇ š#GÔžM2Θ5½Fb-mÔcüé‰îă þR?@J/®š÷J"U‘ÒI{=áÎ(cf 2js~ Çå2 Kû´~DEmd‘üâI=¬ïËtqô?³Ã]F÷|ô7ßlÖ{Ö˜ó{sЛaCîi*»4—H5­Qüá”>d® Í&ié}+ø×Ïh¶ûË)žu<¹ÞF¤µ¦þ®§Äœs%éÇÉ*l›öZéÚ;6ÇMGƦ4uðššÇ7H“Wy -®{øQˆ ¤ DλÄ/êê¥3çš3§Ä¬ËNÃA‘áJçS‚¢cõ,sË?Ã>8 ÊëÔÒ蛃ŽÆ–dí‚údý ,¯ôRÙ½ƒˆ²ðˆò;òr–RzZü"º!e;d;y=ûv48{Íü[ùÊÆ.Âæ%øÈå@<ñÿ‡³T ÓTð_r[*ݬ@ˆÊvbQL'ƒh_,±ŠÄœŒk.öûV>䟳öÏÜæM+3 ;^æ4œ»ÜÏ].VÊ[̽ßÐ~îrQ¢{™l:]/ èx<”1e¶ÔºŠ¶ ï@5:ó&v¸v0V°$kŒ i|<ߨxžF@„+²“ÄE=óØ wiÿºpôĹ´ã’%|ùº$ñÊXàW„ßn@ÝXÂ>;âqc °õ˜GpöÛGg_=ú÷Íûwžž}õßqöÕïñÏ·øþyôýæÎ~x´ùé þlIË0 Pà*fV6B­ ”­¤AñÏÕt˜F°ã× Ñ«Y¶4" ƒq%T Á ¨ª%û›¢¨_l‚8Ê!w…íÅÓ8u\Ü0·´ùê3öúueºëÚåãØÍéb^(‡˜þ^ļv7ѵ˜§¦Ÿ!æ]è‡ì%âçˆù2ýíC´Å€ÕpÒN-€(ôD!ØNQίúúL¾à2ð$mó|¹ï$éù^¾^ÇÝ<ÖrÞÝœi4Sô$h”u‘Ùȱ6/&6@Të†Z¿ª`ˆ™0c\ÅÚ²§ NÕñTiÄ Òz²ãöÅ‹–Oš/Á‘"¨À‘híf-%ZÈFé’` ×M'‚çÐÞºÈE£ÂØ‚î È× †ÑøÁ‚—‘õpv‘O)YQ÷N$€}œÆ•{PξÀîCJMD”Q©‘}rW¥ö2µFc:ë³æ™ö®8]z-&2´Q]4šâeã5w–ä‡E"»c-¹~bjëaí`¬ª¾(qšŽ”’\*¤ü°ÕBëÿR6:ˆ$žVÌse?l¹á|RYrhÅsãÑRÒö]r5E%9èLRNLXH™ð1>ý˜T×%Š‘˜H)º% –ê®»I¼hZN®ÿ½·“ ‚ð·‰^[F‰öì#ÐHáW¡Ô@µ ¥OЕ œl%e„66•4:JŠ ±Rá‹ ¥8H3Á]·Ui‹öÀ½/–Ò”[¬Óµ†²Jü;ª¬%åtŒÈ•ÚpÕâMøJãÖ.Ù_p_.f† ÐÉñ H) x0ú™Æþ¢†›BòO£zP††Èâ¢8ž4’’¸@7½­ªôÝ$½>%° -ÝÂ"äRr®îñ£,Ñ"à”4ƒ‹OÎ&”§«x£–5.Q€t‹¡|ñÒ¯ÎýPU'z «@“Ú,½%¡Å‡Ù&ÀI1XÌbÚ«KöpJfw‹Š"ˆ±™¨íß xP Û‡|]t|Å èÂÞþ½Ú´kP‘ÁÀAkWÐÕ%™tíÅt"8ØíŨÛÇÓJ±‹“¬ÍÏTîùá2šËP&C3¹¨¼ŬTzá2öHÙf$ŃœÍ|²ŸÒ£‚<Õ&˜ûÄÑ(p5Ž2 y7e,„A™zß„JòV6”Þ^ßI‹•³ùNðÊk‚W÷¾NžÜ›|n¡‡—¨î›Hµ€õ¦¹ÒÃ6ª©´G£äÕ¦Óv¯êNÝ€ÒF RœøAïÉíú`O EVßKœå?p‹$%bEë…¸…©pÙµBž‚•уÂÐçât Á/!tHK:mTºyA¾\—Ã!™/ûb2îÆCnèý†y8Ì`0Æ83ôYtâÇáw”wŒ>0¤g{…‘…<Èã<'Ø`A+Ôpr‚™ë¿Ä,Ž:¿ÎPÓEYp*ÁäËiL!Œ`Û]t’vÁy—è\”K»¿NÛ+ű]x‰òK)» V3H¸ý\~ãÇ«¯£Ÿ½Y}§Ž-þ)#ù›zÙΩ ¡Ræ¸Ç.Ùù¨²ÛQW÷f£>s_ç*0.¼j7Ò7Xy”YiMÀâÖ2~¨Oc³Û/á<]/¬ô‘…5]ÄHš1(œQ„ŽÊÒ\IrQ^Mš×~ìeíà~'»”Ë€|í^Ý›Bó¯øÂPñ8¿…-ýÐU{1¤†Œôl;ä¢ %ã ewŸz¢Dõ³$¾êx¬ÈýÅÑ &C@-ºA{Ruêã¯×?~“Ë0²%[ ûø”8›¨¶'–Ntóœ#|tQͤë3$AÊ Æ•4 ¿¡“ Ô(%:œoúqD“‰p1a$pÈe=J…š÷ÑÍ—`‰¹ã“ø§×ÅÌb¼‡æQ°ÄÒ5 ²‰*Ä…åæ4cõ1?ÆõæQ´u‘«k']¾Ùa zj6eyßÒ¾æ5r¢‘‚Ž{„ O›œÓ&ñÅ5ÂÕT¢bò„ñÅ,7Õ-#Å>T‡ãU>"(`¯Ó)À–Ÿ‹;ˆ†Qu4…qpJÞ©´ 9zbøiÅéÉàs@í´Õ8Äornžf4ì0²öˆ¦”düX‹kÒA‡àTQäN-AšÓyM 8¨ÈÏñpjЮYåÅãônö …3»8=€YoüXÑ[Æ«ôSÕýqzVi -í’Ø>ꆄœqÕúÊ"§5B!'ò`¦ìXÜð£Ú™ (Ÿ¿±DhÎÕN- ²l’œÎ‹Ö&[ØY‘ä»Uú™ïÓ¯nŸ(Vƒ´ÇÈ3ÁI?fj;²ù‡Ð'9 ÞŠjii¶,aþZr3ñ ©äêTÇPqȪHZW<›ãlÏŒÏú°ˆ Ñ÷µï$@Å@TXñy`liL óŒHFõÖb&µxGMàµàÔ>—Ƴ~lˆú±Ã J~„ÇAwÉGX@À%Ñ”mTú€¾†–˜|Ró Æ(U0Í«[£"ëGáÿ›ÌkL}‹ky¢yÝNz§¼Š¼ÍAe )ÃTtÏ· ÇX‹èV`é˜Èk³&{®²\…Ï¥ÔuèS4PwøîJÚ¬\½EIw•Ñ2:¨¹cwÉÕrcí¢ñø*…5¬½¾Yã7NŠýus:4=‘1AþÿmÑ¢¸€^yàCãŸcq¥CņŒÑsŽËžÁüÄ Ìªâä’çàQ!rã8hÿ&°t¡ú֪ʥóØåb¸ôàQÞ]öR´¶B¬6õºÔ(ï×u'¹´Ò‘3Ü˾z:eýqÁ™íæc¯BøALCÆë%Ý)>µÄ¬ÃÁêgɆá"‹m2æS¹ý‡!µ K3%'Ñíb¬[‰Ì#ÍøýM5¸äV> ã.ñ€PštF¡eÒ©:ÈcøïÀP¨­} b]NÁÌÀíÈ6ö›]6Q¡4ùVJ^NDæK<ÒØ"qPʼn"£Œ¤Po\ƒ²þùðçõW9cTôòüKë‘Táçðú-¸‚騱+bï®é‡33‹+üFO½Ÿõ؇Wöሮ³ŸEÛnúƒÞ<ʱPŽaR@Úà\KÖ4i -¶s+{^ pl5w3œœ±4´µ5^Ó!Áæ¶R¿ˆ­Ý'X%cHDÌ#-F­²½_H—€ò0*^ë!SªÇïŸj %ØÛS=póÃúAֵѿËÍÉ:’oÝIuÒ5·¬;Ÿr$)‡®3Çci·ª•>6"¬æ çÎ0•KNAëA,·˜Ð p‘ã=pT?f€›"Uó3×ê*o}]Ÿˆ¢ü€Ó@€«ûâ¥ÖKPLufJfæ1åâÕÃ¥Æ?ç¾ó«n½€ýÃ8嚪Z5Ƭâ‘{á0õ q~êµý,êW ¾qó=›Ìp§M“g^lf~‘Bñ¼sWyzø¼ñا‡Ÿ×Ñh2N7)oÏL~úF­\4•´¾ÝϹˆ"¾—k‡‰V~x|1mUø™Ócr †MÒ•G¼‚8=Ê<Öüµ±¶ëiUÜ¥]:®wÕ½nea»× oÄkƼŒI£ÊÙãmj˜®‹ÑŒ³~RBмHáùeëž¼Wëž‚m_ü¬Òr4¬£Å *úÝîÁ×ÂÓG³a šBn4pñ¨tŽe6N£Úº¼÷-Ñ6fæúJq«¢Gˆ] Ô¢Yž¦ð$æGÄ’¦Æ Ån`.ï[ÔºÏɼmñ ÷1–›qh¥S/<ê*É®Gv ÚT*p÷Í̹aìÅœã[Uãñ̶BʸêÑyž]{£R±âXˆ¦GÎG ªË†ÙÀ¹Z­q©¡ C¦ô¹s.—‹¹³.ŸÍ{%3&•»ñ¸Ée6Öè5ÂÎz¼©³Ã nâì쟜þiëŒót6ÅÈÈÎMaZ,}ïë<˜ ËÓªÞ«Ðr ›\ç™ÑÔ¢Ï,^Œwø\ö^µG=ûîÆ+Aù59I1…¹}“u¹Hv^Ö÷n)rKç`þêîH9—©ô‘4†Ì°" “Ù}poH«\®rôMµ9HA²Ôë–¡''EÿZá7\’Ó àÃX»ô¦¶ÏM}^R Kb ]RªD ”ÇípÚéY¼)bâS# *ðÎRD¢ÜÖ‰‡ ­Öý*U@ós¥P‹J—uc{èÇE°¦Ìý?t¨•ÛïjE‰¤µÏ'h>(§Çý¼C™d]cŸj§Sï:ˆt%)X%°Ç@·•JÒ±C·­æ/â…¤‹‹Ù èÁ7bûhÂà¯Ó&OÌÙõ¼œÊÔziYCzfź®dNjúvhv&ïÚÇÿL9É\Gש´=ŒÊþ§‘;t§¨d¸"3E¼¥4gŽ*ÏN UŸ\ᣩ{] äà‚ò¥'òQψ)¼Ètù•:)®ýêÿ“\hP¼uÙ=Gº@XV:†¹I&t®aZ…êh«¡©Ñm:¬®|í«l‘Aܯq¦Sr¬+KÿªVÙ€1sÌÖ¤àªvi ŽÞ.HÃ}If…y0=ò¶É3¶Iž9©BøÆ€ž£‡@÷ÞŠ\dUp7Î")½Ø»—Ã'ãZxËübx!‡I¾,úË\Xë Ð9㹪õxQ!àÌ bBjVâv^€ø*‰<^±¬èSE‚HnðnkJ¨§Ã;¼ƒ°ÀÉ{ª>´€ü?¢†“ ~ÒÅ+ êltoÃOá$Š‘Ø3C·:Àœ¦Õ`-’JР©¡ÎÐvø†·{O*+éCxl]óêö@ÙØxCA²ÔôŽ#`ô344`>²Á_ÑõØ8ºãÄ¿ž`ia§D3#+OJ©L€W”oâýŒ¹ŸoÐ &a!ÀK/gKV?¿Dœ(‹ f{ø År¥NKæUYcc–P03Þ›]z†äKDNíTØì»æ©Áq-ÕãZRÓ•˜é`וªD¡` rV͈µ›ü|‹*%“÷ZóI]á¹7K¼t./ïöSZóxñ!~ȨBM<Ö…¥=T”÷Ęf©iFD¯MfÚóȉc\Z`¢÷˜!®ØÃgÈ ßw| ‘,¹Ë)¬Ý¢Ö艺,ò­‘Ú5=0jÙO¶0õ ¿Šµ†€U¬y¨.vŽØ9‰Kª\`B‚µL“WªùˆD,:G?¼$¾ÑëÍB9Åì䑿ÂËÇóY4¤éycÁ1 “z %\ô`÷ÐîGåè?‘¶×€9oT.{uOˆBO`ãæt²ÏOWAÄÄ£ ^Ýa¤ª‰¤?ý?—`µendstream endobj 292 0 obj 6117 endobj 299 0 obj <> stream xœÕ\[sÅNåQ/ù §(΂ÎñÎug˜ÂHL™TUñ@(J7a]Œ$‹„ÿžîž[Ïì¬tdɹå£ÝÙ™ž[÷×—éáçE¿‹ÿ ÷O¶|=,ž_lõk§GÛ‹ç[?o ª³öOŸì@='R˜ÅÎ3¨¬¥´Â±·ªw‹UzJßdß/†~±s²µüôëÇŸït;?m}¶³õÕV]f!ĺ·½ôýŒÎ*-üˆ­ĸHeƒòé·ÝÊ,×ZZÿ°²B­{a–O¡ìIg–ß`ùN…½ôöýΡ?ú(°?¿(ba¤]é’¼éVz=ŽFHßT*ËÛ®´ÑØh¥ú5Œs\ì@ËÃn¥–oðçèõNd?Âp†å3| ÕòŸðㇹ‹¯Ûø³‡?™ñç ^¦ÊDú7£³0J½¼À÷_º•„7ç,ó5¡‘=uýe*}“«^¥Â‡a”BSŸ¾M©ngª{¹j—«â3#ê¶ÉîdÃv[d[Û(‘Yƒžní|ðÝò‹Nûå½€X? ¼1Žjy Ë#`ްvº÷ãÙÅGK¼sÕñËr·ŸjïvÂo•ÀÓ(ˆÖ³Nbqü§©Ùeçû8ýGÚ|§—±‡óÜôY‡A©3¢AU`!´4ÈüÕqI´­F Ãx#írÔ"÷‚?/¡r˜e „t©Fßèq­å8¬AòzÏÞ·-²óïð^$-–_™q¹‡•p'GK«t‚[/ðée›àa~duYéi.½ì­ºøPc’VõóÎB©ìòì¼à´U˜þ XȘÑùUHûé̳If¸}rôõÇŽøGº‘vYçŒÖ~Î~Ɖâs¨gGÑ: L)‡1.PÞ¸<»8§“r¥ò~:HãûCJ(Çõ\Š£º-Gz¦’kë"Sàœ‘Qx7´Ã@\RX{ <Öjí B$z‘Ae(Žð0²VM¬G“@(H:ö®”æüµŸcµ(ûrpðmh3álžd¥Ùüa×ÖHʲêÅ*á¡gV€¯“¨;°“ –NÒÓiR4¨‹²ò ¾7£hBŤ]œ×.^û‘²BØŽ`þUOØy“ZçB1Ñ ÙoRáU®¹N…}Kµ6u˜$Ÿ¸m81e³ŒžÇU’Šú=CÅ- ç,’&¥VPs"µ¹]SR#‰¤DÀ>h*Ghp0QTÒXNóXk%k×’ÝR= M("|†]FU)h¤• B•Á8Åfàå[‰a-“|³pû8'E G~7±ð+íÞ¥)5d%ê~‡’š­I}„…(Õ‡ö´áç^”D4Wä âÊKX2,EÖÉèŠýìFf—_“Ö9ÈÍ7ÒówU+5³J‹âa‰TÍX]›ø®WWC¹t’P„é‡Jƒfêë.‹<í×Ê ¿ ÑC@¼C³¿Ï¢…Œ=ª¼¶ÿåH ŸÊs¯Ib„Nº[zo¿´(ƒlNó Àx±`š›Ð›³‚vaHGV–’ ÿq'7ºTqO¿ñž—Wçf­uÜ®`LYáTJÂ’R8 ¯–e1–1Ëd•“òœ–›ÿØ1vLH†Vì‰-l^š´{§çØñO$ lŠA¸%ðVÃ6œû©I¦Ô@ ȬDe¼¡û»wöº[Í[<¸'½fR¢“©Cj¹©ôä ›(K•#“—¾rgŒ!M´1K)mJÛÍÓÌiGìq'V×nhßXBÞžœã“„#|¾bÚâ0Oõu6ùü*–wqc×ÄìÁlëÇbGFÅ”%öb0à¡[»7®-¯†Ãä*Yãí®Dn¿×¡•˜8¶:Zi+ÖFV¸IîZ鬸ž`ò0ÀVV^-Ž5nìê#ï3á–©flƬÙº fØ" &¨sÙü¿‘º,¨o{ƒèŸÝý©æÒÄÒsþÕœA.zð­7ÈBllkð>‘ §&w¨?áëQiÃoOË|åІ]n2ÁÉrf¹óèSluI–9®IcÅoÐÀˆ‘Ú^d2ˆ8öK>ô%W¹ä(‘; Cyeþȥ«DŽù E’@ÖÀQ5"^ø i¦å¤N½ ŠM~*ªCÜFØPPûJ[é½/_°Ãs"µ úN”ÁŒÖ`ÐrÄàÞS;Z7 u3xíh`P\\Ùa¹¬‰êüiìÓGÀžx E뎫nå•öv †#Ê(Iç1À¥­‹£‚€×Ñ#Ž ˜š$W®¥Ð€m}gÖЃšÃÒkɤ,`>˜v1¬%]¶›®‚¬á¨™‰c, s_¥NRIá;èW‰ß'=wš”0™›=‚Ws sNÜ25N·tÀ’Ü^–O) ‹cB:N’{QJnß]vž=‘‡e¥'4½îAÄ´åø(¯êE*¼Ì…}*ü!î§Â3.¥ŒsÝ­d.ÀB¦ð¬)ç¬Ùvnu« ø¥«ãɱ¯eX8æjäÌÉÝ/þýøøCaFźGÆÍ¨bê|e Œ©´²P©OþLŸ¬”‚è#ÝA²¥›f†˜˜î€¨ÁHÙ _Œ£Ìг%öÎ@2T† X=€Jg¥hÎGçM«ç2\3Xü‚j=qÅ+WX6T­­àLž|Ƙ´f¯ÀpZ¯2ÈÐ¥`¢+†Y²¥ÒðEªþŒÌSóæçÀíãkL¥Ñ-*6@Ï,)[€³Ÿ°ÊXr¼V‘ã¢þ¡3M¨'z‰óŽ<²£(ÂlD'’?/”"K¸_ÀT@ Kíº(0½²õÉ“­O¾\\ž¿:ÜzðíBl=ø+þ|ò÷?ß'Ÿ.~·õÙ“ÅW³çšÕÈÂ9£j-äsÂIã©wr<öX!ž jÆ[+“%¡TúD4–‘áJG¶?˜9žãÑ“ÉfPî¬È‘(÷¢²¯Ë½hb”V>VI…)¸ÂœÑh…·AËúc×ÐÃëarM¿ «ß3‹f½IÔxÖÍ£Dù£¼mÿcÊû W_óÓÔ4ªd&àM2Ãn¾^ߙ팟C•\EËÜñÛqÂiª’Šá‚/³ô)íKÑ.¯#º%mÖÛÖEûo0p <ÌàQÄͽÍXý»ÑŸîW‰2]œÕ1À§1m¢9"#Ìj?Ó‰c¿?Å’"—3·u>þŒaÖ”ŸqÜ­Ú–Säþ°^ÚZ­œ;îÇG…i”­¨ó§ÌÆj„DÑÛþ]¦Áh3â¥ZÑ “œË#ŒÝÎ,žýVi`)ÒËþRÈÁÌÍþ01Z”uÇO÷:ºIðB¾¬R>§™3»RÂߪƒè*Þ7Ùørù¶ù”¯Ë‹@á¶aÌÁK¨·>úª®5O“A4ý¿ n™ ÒŒt»"-§ÌwÃF§­Ê‚㆗iº&XÜñi§¡åU×9!JúKy7ŸÒ³¸ÐÍ [¥A÷¢üF„Fù>Iº˜9\§„'`Hk¨oW\w¶ÒÊtòbpù°W>óÉ`´¬g‘QÏBnAfJ¿ªïþÔç¥E.£óšzr5»ØQ J[ßpª˜WÜŠßÛX]  ÁëW[ÿ iäÂendstream endobj 300 0 obj 4222 endobj 304 0 obj <> stream xœ½[[sܶžißô+ö¡d«Ý‚`:ik§vãNê&ŽÞ’LFw»³ò:’[mšß^œ €,V–”¤“‰Å%AààœïÜÁïÃJ-øÿ_ì}ôbZœ_í +og7Ì‹ó½ï÷ŽYðŸã‹Åãƒ0Îë…Vãâà, ¶Z;åÃ<óàÌàËt•žéaXLÃâàb¯ûë‹GOúƒí=9Øûro¸m1Ü SÍ Ö!"ÕbÒa&S}Ý©~9v.üóíÁßùµÜ ‰°Ù;cmÑÙIÍ‹tÏ*³š\žéÓ~ì>ëÃ˃vÝ£>Œ›½Ò¾û¢_špÓÛôñêIoÕ²®{Ñ/µŸWƒ"RVýÒéðLÙ0‡âý(Þû FÝã~™æK…§6\JwÏúxõi¿T¦™à9ïsö eWÆ:]1ÆMÓJ'Þ˜ ÆQ9 *lvœÝØMýržçÕ¬LØ„^)åÂó÷°c´ê޲ÉØî4»šÝ4Øî \z˜¬»ô¬Üäôؽ‚¦qš» ¼¦Fëê^‡i§QMSwž»É›9 'KS+ç‡pùùÞÁï¿u/ÃÿaQ3 àÒÒ–¨éç›(ˆÌd¶yh›‡pgê.`ŽÃ7`¾Ã( w`ìUoa lž ÞŠo«±˜™¾r’C„ÑA˜{—ÈtHDÁz@˜".i'@×UA1P)~®a0L3‚h¼ÅÙ6ð3H~Ö[“I@ñæ5ow(É ½%؆ñÀ²7=ˆÀÌ( rpà±;€èÞà #wp­aìþ‘G †~î¾é 3˜YÆ. N*®øç¨-<Œ·X ûM'îö‹{—•åe’zœUç%l’†Šn~ª/žšæÙÍ3wo¡Kã °m ƈ–è; DMY˜æ<â ¥y:Ø«ï~› ‰H†±Gk¾gÆw•a›ÐzOgœá¬×(+39”ñÜ„ãÞ0„âN‘¤ ¥zyÑK¢€Ê¸3™0x‰Mø€±n7 ¨v„J"ÉYã(äS°y·"Рã°u„À nï+ »`JXy÷Ù‚‹»1o E¨lK„XöAÃÃîi„;ûÉI"¨Ð*Ö]À}°"Y4?À–$ål×Ƶƒ}¤§ztŽ{XA~u’Hs.Lê;˜ ëІT°ÉÖ“ &/‚÷ÜÊ­ðrÑqÖ-Ò+¢­DNdSåœÖ였2˜ˆ„¬ØŽ¶I®ð;É=íí„,8L³_÷UiÆu¿ÃÍjžãdÑ;LÀÓ6+¿ š,%žœø\Î0ß8£@#°Îï® 5*Þ°Lr±æI(Á5ŒueÙX·I\ ¡àßÿ(—ä$|rð\¼?£—Ci¯“¡É&'YˆÃLœÁ_ÃÜKY´{g!8 ²³Ô××…BÅ\ñÁŠ IQ›j^#‡!`Ë’¶Q4Á°¬wøì#®;O`Œ–!Dc2˜@\°&pwc@KœÁ¨·<ɨ(9»e’qð8æ?iÌÇq ù ü¼I¤"Ñÿ…÷f„7Ø´Ý øªÈ¾ãìš&%HÏ/ÓÍWÏùæy©v|÷càG¨Í€Ô.õ@ÄÄÀ¤±Îië¦PïïÒÍ«‡I»Å‘çéæ#ÿl÷;9=ZâÚ©°¥°ÆË5Ť§!Ÿùc¾ó˜î` r†×h …Wm:ÃÓÂñÍýè—& lèæëÂ-‰‘z`À7œòik!pN1¸ø( ø(}–nn šcLô¢Nû†Û.Ã\>àëHCé‘nWl놼ý„‚NéFkäižJPc²0#fJ.b@æÇ«¡}Ñbí%ËœsÌØŠa(Ey×FnÃŒgÃxâ?‚ÀQK›"e€®[ŒO"ÂàW­leTïcGxžn^3Díag0øÞq¦›ïóÍŸËÄW¼¾_ü:N¯0Ùfâ²ò\g§ag®‡Gˆp–)Ï&ÿH/=Îk‹½)øg?³÷»øÛ(´ú8HÃ?¨Äy¦ûSÄëxá‡p`N¤%ùÿLã:Oþ’銓sºð!)©B¡9(–ã¤\Œžë¬~bEz&‚¸zñ-S« :¤Ö·Å“€²%ÁĦW…›bѾdyÅGÈš— °B‘òÎU7a-ì\å 3Ä×;p*’£myøê¶×ƒ¤ž·¬N¶ñ» a¼y&çL"9¥{JŠíV •V Uù„Ŵ̶¬V³'µš%4’  ½â|mõ¨¡a«rb¶F7•ë$laxšŠöÝVJ~»Žî¼å™£þ4#ƒ·…ÐY=OûÛÕó] >yú—}?¥›Ï[NK_¸Œíé¬õøXN„@*C­,d´ñµ$ji©«Ì>F e™ BeÓqFHFfAh•£ª±=¨ŒÇîëäic¼qJC¾½5 \ÒÐÖ[†dL5¨{ä ým)ܹóH7Q…uÆb—¦m<*z™píhrÈú#.ЇåEoWí™l×ôèëÂõÇÆÝ¹P"0íhwëáª(Ú†ìÖ$–Ú®t² `Mjâ´“ÖF‚v‡–B`q*ñU%’Ã>¶U\0gR!»ºg\/æ^å&šyæÉ|PzÜ—÷=-`³r íýÊ[qf À˜XãÞÓ+œXοÏâǺRd:¡¢ûiE祬@5 6S„ÖÀ=•j.2l¶ÖEšLš0gMPìµñBâ26ùgRŽ¢çÚ(Ì?´˜¸eôv5S¸$SöèSoË$ÞV݇ˆSDh°/ ’b˱…]è[ÿ¢)‘A;ñï +‚Qju¿—H«ÞâVkWÖç´4iFW‹ÿ4KtÙåªoŧN ¿ã\׬*žÙ°À•hÑ ñžŠÞÕ Û–¯=àªÕBØ*­U:?tG•ö$)2ü°ó‰sžF¹ñ´o•—ÊãzªÏP6J{÷Yõ¡V1Ç„¿6ç â—äœ-„Àî³!ȉ“2e¬Èû1Ö°Ú&kÖ£§úƒ *E=ú‹~œÀÈQh‡À;‹ÀƒU"×Eû­£… §D¢ñšÎ­b–ƒ°;Zk½1ˆçžÚ>Ÿrز¶A*tΧyÆDH_Z¯Æ¹‚¢BgGàòà%ήo7±U³’OUlŽ€é¤jÞUˆe¤ƒ©Ê ~—‡Û9Ñ•ÐMÌV²_6JKTmº£ X5pŠJÊèÔŽ³©ú— HÁŸ¸_3èPz²©JR å`Òí´ÑìøÁßk‡YOŒ©@ƒƒ)óK‘¶Öb™°‘@„×à9§ÿbZés µäYÚ•ÂÉ€2šL7eï;È;ÕÈH¦~×”EPâ][Í"4šJß®UÝíÇôùÖh¡è`5Ÿ—ÐUÐÀk7²ÁyÊx}*à X1‚à§¾™GûÕäå¤Ád…É€—¥NNð(;ÄlÈâaäDAñQûnsÌpÝQ«»î$ÑZ¨Èk0)MçbÆÿ“g©Ê––%[‹ÂYŠ«›6X{«ø¢¦ü ƒg÷QŸB¡ÇO. jø…–-¦V>}IÑ>8ËÞ-º c2•ScXÔ¨†ówúŸÁDNÒ†t˜/~LrÄAÌIÞí8û¶¹Iéô`¹¶A'r˜D]e„vµ>©&Õ§gjXÖ‘ê¤rè4¡Áä3…xC+q£*.ž4^‰¯G¨´‡>û¦¬uÔ‘™]F\2µÍ¢üÛ]:X:R8³¸+>>f÷žÂq¡î#STÂaYŽÓ&•hŠz£É⤼©-¥í*(¥ ˆ?$ˆ‡ÁséV‹mÁ§¢÷0 (Öꛫ<Í&”„I ŒñY-Ý);²çEŸ‚¨™ê‚„6—hº×ñµCœI¦ýœÀQ”°…e(°Vl‹¯ô €m1g£Åh~¡çóz/z8Æ~ýw€ßâ¡ÙµŽtïzØ¢^Mh¨¸IŸâi§w}×÷Á/ô %àsë]KeÈâóFü4KäêréËPŸZʤó­"aŸP”¢Æ¤Î›üZŽ7ÇÏã °J® 6rÓì¸à{~L‚´#®õimæìT û fy 9÷¸ìÕ@…ãý>­ÜrhÌ«pWü ‹_ù)¹Å¢Q(¢øÀÐQêì “*ëÝEȸ]7†ÂÖ$ÎÜ–"m”-°$S³)ŠâTêò“\|s-k˸é:e©Z‡Q¾üùd}hÚ0ƒ¿°lú”†-y§m™OÁYÇæð®~i{a<à:oyĺí, N―d$$GNÀ_²UÚùØu„‹be/oæmÍHþµlÓ%Òù ¿¶Lؼõ#:ÃÅ’¿•uwå’¾Ö•ÞúCGwÛ5à +;Ì¥ƒ@«™ìŽ‚!Ä«‰¡ûÒ¨c—øË½ÿF<–dendstream endobj 305 0 obj 4189 endobj 310 0 obj <> stream xœå\YÇ‘6öq~EËðC—­.VÞY´d˜Z[^–aÉ ­HÎðXΰ©Ž(rá¡ìˆÈ+2+«§9"ü² ØS••GäwT¿™F±™ð_üûäòäÞ7nóìúd½ží4ož|"¨Ï&þyr¹ùâúy¹‘ÂlNŸBg-¥Æ™'«&¿Ùå«|ONÓÆM›ÓË“í¾yðåépú¿'<=ùúd:4‡Ù1Nv’ažÙ[¥EX±ÕNÌ›Üæ$ ïqüo·bØ™í8¨í.vV¨qfû`Ûo†Â9γ÷Ú´Ùþ7tþ;tþîôÏqZÜÁ,pÚ@±1ÒŽ0C=‹v2B†Ga¯üÙ6Ú©i„åΛÓ3xòj0~´ÚØí9¬cût؉Q)“fwÕìzt¸ÿ)<ú?ÛA°lçâ|pF¬·sÏÓuFÊÞ¨nœa5eÔ!Œ*EMçƒÙ^µ'š¾ôö9ï›45½{ ´Nm³‚MÊíþ ¾«px‰÷5Ý¡‹Ü4N“Ðvû Ÿ •é6Î)Ê{[lâmÁ\ØçñiQ‘柷û§8÷ 7}µ>Ý¥£œÜèRêcˆ`30ã$ÔöËÁ*\­ûÖ GÔ{Ö¦i!¸öf§Ÿbw\ªKÔÍ{ $6œ¸Ûy¶°½‹B¶ýÛa©„,³Å[ϰº)ζ?ÒllºuU8„ ,®$@lbw‰ÜÀ$;æ5¼Ê«Dúí¤™ 7;`ICŒ0EDÀý žejàJ¬#jM‡ˆ0U/ptü›ñ‚_Þs„I€j蹓^rßBçôp:Š.§Ú7 †®0ñ£ápI‡ x³º‰ðú8/ül(ôW}ÞŸA§$d@Hkë¯Cú åsèJÂi§­Þâ,ÊVM€@  `3ûðøxð¨ $º]!+LÛÏášRK(òÔö³Ì¬/ð+âé®¶¿ƒmÏžXä4ü!µS]킈<ýËÉ鯑[UHRá³OÌ–€T§_•«£Æ%i©óÉ Gç\wr3Z5{ÝG©‚pD&Ïs6+øÑÇ;ì^H—£.<¹‘ÞyÆ4pˆUÐÙ´'Üö4†œvÈCé¡îíWÕšk)BZUMºµ “Õ+è¤ ‚ï–e1pE(”NŒ–ƒ5®äùÀVL‡í H?„)…§R_´]36KB÷°¯å×B“‚4ÔP™M_­¨Uæ¬% ˜_©çý4 1’œFà¿[f‘h5ÔS·ß ;O£Ë5ÙÆŒH¢›ö\™“¦s¤S[*åÌs¹áìg½0!&AM‹øAÏSÕ¾°ÌIoR½{4XÔ÷•’Ú/ñ1zö’©OdMgÂöÛ´Œ šB|oµ=Ï’¦‰2‰+R„³Ù>~‡ÖòâœÁ2LJÝ&ð[N,Û óÇhÿkn6på…ñÜåUñÊ ÌLY)- â¯h)ï+³p€ÌÝ•KC…Œ-ÐÎmŒ?MVšŠ‡M„Þ«ü±45Ô<“Q f×Ö†U V_™- L# &?‰F{k ¢TèÞ~.2Ò¹Œ…' 1í>·vE-rRµDr ’%¸w¶»F;¶.ƒÖ–$ô#œÙ¯,Jow‡˜_Kìªkž\ ã;ÂJæT<§èo<>O×AqqØ™Ôc„ÚZÙd'Aèôèž ·}•‘[FãšUžbœÅl䲚Ò¤¶­¹‹ð@Sná‘ÉklyQ ’RÙyã¸Péf2t÷7ÑŠ ‚É "\ºKÏ'1KóøxEÕ.º˜þîH½„• âtÆ‚›;͇9 ” e²æðd¬ f ÿ&X1ü˜&®b¢7ŠPH€µ¯²aû—„бr6õ4Ž=eÅJ6òM´Œ“Qý4[ÚO¢¹Œ6A±”é¨ïCë4·V5ÙÏa5÷ã€#Ö)ÍLí÷¦îÞ¤FÜ œRDÜ­¾@´ü¯ëY>žgPÖ”ðÜ.qgA¯WÉû$eXo840ÓöK>Í¢4âÖ¼ÅX‘0Üg#½Ègt¼$É>oƒìÖµT¥ 8,Tÿ]8æ)ü¡=Ïñª¥É'\Æ¥àiNž»Ÿé\9ŸäÆÚ¢à‡üº,ëÇ|ÿ·iÙša‘ÑdŸó º°ÚÐúcéºëÑœ#^Ææ¦ØiÀqPƒ?{ WŽãŠfÍ{úÖ”%Û,ê.ÏRLît>Š !z¿ß+çÜí´oÀðmf¹,S9 ß­8ÜpNeóN™€8ZÕ—h¡eEzSóÁß§8‡g^ n4…q)<• ŽCæùëdd;™`É­|Óh2 öIG[YÿÒÁWl4vr(¸ŠfŽZž`›c~qƒ-e¹„h«H/‰´#f ¼<€bï5©b2vÙÔ•žæ¢­{ô«ðH¥ÃÅÉ{>Ñ–¦I…-ŒÁnÖ@ª¤%*0XµNÌð€ ‚Ôž 2i,A±X&x£sÖŸ†0JŠ÷¦ŽqÄ3)~I¥¶D̤‡[¢±+‡ÈŽiŒñ_ÎE,“Ò ²Ñ¸ÿ:ù¦S1©pTª£3<€ÂòáS€ÉÌ&LDÕvÉ2ÅSJ8¹¬Z1‘6¤‰M&ˆå#Y_3Qp¸tÜéÀOêñà¦ξ)ÁšÚM˜+ƒæe"„(çn)ÆÀCZ‚§q:¤!ÿ&‹h:Ö_³Cú×â7²¬@^Qc 7A|LFœ ­ˆ,Í!öð!¡lŒµa Üž‡áÙwƒ)N"zÇTÜ‹Õ`$-\÷Òõãü„‘¢P»†,†àJ,´XŸ sÑÓã]3aÍ^ªbñÿ؉%ÌÀ™Dç…¥v†ÝWîšF:‹ eQÄðìÀ‡F]þ–|MNÁ(2HïÇçÕIÄ«þc]ɽâuÌtZµsEçû:΃¹ ûP˜ª¼åg+Ãì%rp„¬0«£g’èf:Ïg%޽§C܇‡Ñ\äÙúREï¢KÛÑËq3sµÊ[¹ØS80HÚ]~`<òTLÞÉe6,S……Ðbaº5E•Z…–ÆMÌ–Ù¥À~”m+2â>ؤIøE‘¤‰¤"cëp¦7ódcI‡ÓŽÝ}Ìe03¥¦®3eB"µ Î+›,%}f綪"Kš-©µ’ “ʽQR’s^' Ca†lS‰dód¡ŠuR{?*QÕÈ'<*9¨ª¢ †L¬˜˜$ÄŸêÂ…”éLòƒO'ñÅÈ’ –×=æïG½m+eŽ*ï Ê Ÿö³°"ϼä±Ëª†)|†‚Òä(½@³Æ¹ht7MÚ›R[/Ê©ä(Øè±”z\)‘îÚ¯$ʃ¶DKFj§úÓ~ÊeB ‹ *É‚ö´¾…?—J¯Z°jçÉ*(’±M`¦.Na<¥Ñ|×^,êšÖR¯3ºƒwªš fÑõ\ £"›[jŸ1ìH1 å‡ëÓ¼òi[Fo`…¤h¥N²xl1Pów€vß ~B×ê‘ߊ­¥¤xáÊ¥Çð¾ç}iyr²2WÙy¾<01ðÉçB 6:åû|¸ÄœVõ5iönbEOw•*¡h̬Ií}å›”nЬnÕB[˜¨À³|Þ "e–& œIø,p$»»ªÙ\£Ù²¿ðû!å ·ßJÛ¤öŠ¿K)¢ƒØã!OÀèA~òròî|iw»«Ý, Ë5pÿî@Y“EñPü²TØèzp«ð:†4c)ÂO„ú¹[-9‡`EJf–ÕÌåyøÕ«u±+Å$Ì'ßÛÙfá»m÷?G:8Júü4TuÔûýOqä ï­Öolƒ¨Ê,Uo[¦Â™›À+'W~,º&ÕãnÞþÇ k€è\5Y¶€œ+uUúò£¾[šB ”ýÿ–¥à.:¢vŸ%Eeºøymó–`0øm+^?(÷Çû’š>Rà-0NÜ}R"/2pškGÉlù;’¥Ry-¸’{ÎÕÁùbõ]õ]4â:ë‘C ão§>+{º©`~ &Ñ}W9×TÌLGev û¶ûQ9¦„49,]ž`‹x\Z™GÞ°>c²:`_ë\¬ ¬ô!,„wƒÈ?EyTY^ŠÞ¿,QX,d^‰"uqëjkäÁÐ-ø¼¼‡Þ®v5KÖäÓmõzm“uèåÓ;Yl:^~8ÕOü,ù‘mTÆXå‹©LF._BŒu‡¢vt–B/t_³ é²ÃxмÌÕ?^þªT˜-¼*•g~¼H¬æè¶ ï?F—EÌ”‘d öAáëGDZ…*½áv(÷~ÇjÒúW @žÉÆÓÍÄÊfÏ?ÐTè&¦“ô?($™q¹.øû ,ÜRÉïŽrHX~«á¯˜-¦“Ÿ\ž|ñðäÞï6o®nÎOîýc#Nîý~|ñ·ÿ„?ÿ°ùÅÉn¾^­.nŒ¥X],¤i4¨ºø:D°Åö=’ÓÛXH³ °ï:£ÀÏŠ±š-.Äb ¸2>¾ø€fëp.·™X”ƒ‡Qí’•«/ò…&« W.Ô«ý›*Õ–ñ 3uëÒpýóJÃ)ÆVã3娫XD.A]K;ÿPY,@©Ê¼S[—œ§KÖ·®Â[z¡«B`Ÿ0ãChYÙ6G¿š°A‡ÅØŽ%·xéCñ”žò¡È'Jn¸ôêñV‡÷Cÿ:Ä÷”#0«ÜS~qï~¬Õç`GøÊRÕo¤°CpW.a€Š¿R’ˆ÷~è* U½c¼ü¥å&*C™æƒ.;TÒÏÆ‹ê=Ê6ñ}0sKHð*ýÎF‚r²Ê»›c=œf]®Úü‡ÕrèI¬sþΊâb.+¢`¬2Æ+Úu¥êÃÍXÉü1«>úlҥߌe-CµhÒ`“…Ü ?ÑkG—ôz†sÈ;ÉJ1_Æ€€\_1¾„&ÿ +sP× ÆuÁÉI .hd8v9J¡sZ¬ÎØÊªnëyý»]ÇÿØ|Â/šs+c¦ß"KkqÃ:’Uñ¾ïndÞ?Pÿ²È²ò0ëáß.kò·½·¨S‚¨$½È?@LWB†‡+]½&¾'Á4‡×8"'ߨf³_‘úRz&g ó¦ö›Â ¨\Ý2¦R“ Ë¦yÅÄ¿àäû€D²šmI/œ÷ä_ÚuRFfÛüöÁ°[}È{¨Ìã–¿ÒùU›õBP_Åo+¶æ7¤ÆP†Nbê듟؀Âendstream endobj 311 0 obj 5086 endobj 317 0 obj <> stream xœ½Ùr·1ÏüŠ}ˮŎfdËÙ–c¦âŠVåAV¹(cr—âR²å$ÿžîÆÑì’:œry8‹}_€^ÍÚFÍZü/þ=¹Ú;øÁÏ^löÚ¦·ƒk‡Ù‹½W{ŠæÌ⟓«ÙG0¯×3­ºÙÑ9L¶Z;Õœ¡u¦ígËü–¿é¶ùvvtµ7ÿê‡Ç_-Žþµ÷ähïû½v׌¨Aá>I5ó õêé\-–ݼ‡Ç³£¿Åªi]«bCïŒUDg½fyÌ*ÓxǾ\tóo°¸Õnþxó†^é~þÝbi`Ð;?Z¤·' oʺù‹¥î‡¦U•f±t¾) 0"ßwbÝ8»±Xføb+øjá½Sz~¸Ho_.–Ê!ß#Ú¸-œq}Û8H:Ôç+X¤[ˆ~ããðÀ]{7¿ßÛ~þÓ¿ý†‡0ª˜bæŠÁ©fþÓ"0D)šÔöÓIiå#=¿Ì Ίmà 2³³%¤ëÇ)à~€°àщGŒÍüg‰Š“âí_‡žÈ9.ÈïÂï›ü`o#Ê€Ö:ž3ß6yð‚ ø]R8èçOóào<ó²iû­øÛiÉçÉ÷ Içtð˜/%’S@™/ª„øëæ¿ÖhÌBš¿$ˆ-ÿ3¿n«5= DIFø÷½£OžÎßdÅ»dzãæ­T”]2¸¯™ÿŒ« î—¬?KqÐ>S">«±pU›ù9pË;Ò2ЉL÷ƒLÛü Í"~Œ °uy‚¹á „>ñµù"YTa¡m^!¡ðPD‘7ŒçY2Q;ÿw~Q>`éÿº÷ûÌF…ì=)$[ÍãÒjywèf´?•÷Ù|›<Øðòf,Kšº*…¨@až‰Ôù4yÕ×É·LœdŒúFïëT jjᤙÁk¼©ùÕó<¨xÕ¹wPH'X@§ÌËGwxh"᜕÷"è×gáÏolÝ·¥v®ÆêüO#— §÷aÆî õ‚á?;²ì?-¦Ý¡Ø‰\aç¼~[Øya‚gyÆeá§1Bl4rK ?¦ ÷_&5GÅÒβ‰@²N‚‰“ˆµ¥‹Ûs8n›Šß®ª:êb؃×cqÞ¡êû<Ÿ÷ߤ5ÑïpÏR¬½ŸHi|$ËÙ†“Èv {a×15™(¡ÄÂlàÏv“¹ƒû7ù FÕ>W•¦ê“€Ðã<íiÍŽžUŒ¢÷÷1Š(ðmh0G·GÖ®-^j¿|Kéõ“"ŠÑÏà˜S´WåÜé¨Ä¼ªnâŒb&¡jÄïoéE–/“ädäãºÊøFÏ–¦ÄŸ¯c`A‡!ºCó—fCòq=m+3·ø‚†h©¼ÂÒ‡ŒÄò5 œ'-°ÀÒP¬ è÷ · ˆ+ú‹ëÖ«´$æçX:YÒtüþr!ôö9‡Ò °´A8A„pÚúFªkG/Ç+‰+Æ+ÃȨøÒ•bû€ïR†P#R¹¤ûål,7 pÕp`0æÊƒ¦‘[oä0¸aˆ$Ñ^D¶GØX ØËÑ›BTéõ8µoAú`Ê6Æ:*’AðPíCÍnLc²N*@¦·r!{òÝà:1V3 CÓjæ¥j”ï(€ïÞ‚Wyƒ­SZ"§”r}4lç[´vÝx¯Õ0_b%¬•ﵟÿß{Õöƒ3Ná Ö+WŽ÷@ƒmÄm룦jÛ·¨N°¼‹uc (÷QNªqÞé.¢êœEjÕ—Wq™òž„á¼ïª£;ø6ø%Ñ7:E IJåàRn²›åú&X¯åAב¹œ/ôX§Úgº0£§ñ- 4ãüÔ0¢f7£OÆõ 9å h§ë©GÃi‚òΆAÛ+Ò4I;‚ÓòP°M¡šÈ&Ú†p•½„Øô6ØDK—Ì4³ëÑñ™ù!l…ˆxâA\òr!ª À"O¼^_2 .y‹õ¯lJ`úô…i@ ~}*m5M‚(azE¤oA"R ¤`$°–K Ó­Š Øh¿EïÇP¬4#S0:P`E‚• 2~ö”„‘Vv5Ŷ`ÉèÚ[IÕ¬²©ŸbUP´‘žK¥|—Òýš? ózU³ÔRóUM·ÚîÒtà2É&j©UVjhXüa âo#È)(ú¶ÞdÕx]u×¶m)8ŒFã²ë` Ú7*Kª>sSÓÒãÂZÕ=}@u‚eqx!­µJ7Fr¬;Ô6[Üàúj‹Cœ·…¯ØkP´ç³·©lŠZq%ÅüE > î>þqÈlßN‘º 󑓺„WRBy=¶S¼ÍúbGšÂ%›Ø%$Gv²÷õb<u¼žpM=BØXL³ªŽo”c½Ýíœ|”º&§ dR6ÏIžÚæAS^”T® }u¡»'ÜD1Ûó“>m-¦7 zµ±¾´˜CrÅ'ìÕnÞY,/bÀµW «Xv)¸¯0Bé>\QB–µxYØëŸF؉C¬(Ï#z&·Ñ/DoÉ”µ±ì®S A¸}Îmã{MU¢ŽK½Ð)fˆI)Zy²sYËßßò÷뢌Œ5ݹ¤H˜VoEO }[K|¦”•F$0o‡zÉz]_JÛBÊ)K¡Õ uÎGQf ×!"“h¸/ô-g(òü'9êi«„OR’¶’.ÛÁ“èγŽÐç+î<œæAþ¼TýTå·^rÍXÖdvoåBâs«jUBtÃYûØ„oÇXÛ(ÑÀº7yËüe[+jªvU ÛÚŠ¦øþ,u›ÓqÙ{ýˆ™¾æ|`ÌOó´)0NæT¢\‰ ÎzaÙ›1ZÕºGÇIÝ£>ˆÖö£è#S&+P9@Gª’F2ËPQF Ñ;"é€>/CÀ8ç½ëS£ÖSê¯ðº…iSî¢&çuá‚8F³¥ØÞ*¢å”l¥”Y;OX¤:ʦÌ"f¹¡ÒkB<6TB6ocë$â†ßÕÊ¿SÑsz9ï~•‹öAùÞ½ráÚoœšjK‘œFôÎB.ã Vsi¿PÓMán-õTvh<6PËêNcÉÚ\‰ZhkÆÄ‡ß­ä`åü„lìUN~øŠÆ™Ô¥ÂÓÉ÷èëV"j8:fX¢›{ÓXäß ’0ÎMM"ñ-ÜÅT7¼°Ï7œƒ½“j×-ù>ÑóÛÀõÐu ‹0áÐFÿŠøe¬øAuOb*~ú?UøÔÖQšØ|¯–³èR SÆ‹"Ç“ÎBŒ-ÁbUëÈ €’Zã(¶<."ŽQ[éÄ£TÊk¬4;ü,Ž™Êó§ýd‚ÖØ^öŽ$¶Fæß¯iÜâòZÓ8°Í§ó±ôåš¡‰MD¯E̽«©‡@ÇRzÜÅ‹t¿sïv!Žï˜£éÌîlKkÜ—í[•ø|y;°Ô‹nc¶B—A_ÍŒ¡6];Úú™òxÊÔÏ´×ÛöxCõ‹Ã½ƒÃog·7¯Ïöþ9S{ßàã‹ï¾„?‡_Íþ´÷äpöýÖ+¥Cõâ$(j£-nÓØxyòj¡²£¯æº0t¦ ²™£U’eTÓé‘Mu¸Á‹Yѱâ BèÜ<ÌÁù/øx›‚ +'^ Wl(.²#f×T»3w]ø Êy´¨Yò½Œ˜ÐìÚ(]M”¤{AçF¸†‰£ìE}ì ™‹ôÑ]y‹eâÞ9øÜ2Ýgxžó9üÃx×@ˆhþ€ApZ'`Å­S)œòá8LÞCâ'e&³aæï— g€&ï5Us×wb^ü¹Ö`ÂW ÓÌ™´=ópÿ£áT¤f\§ú¹^lo DâTá䲘hغ»ï&Z¾hxÉU¸NÊ@èNDKœBÞÉ’•ä([hدÛqmG^“£Í_ª¨3C¿פ{“8Q¤9±^l ¼ÃÁÁ Ýhç(U°àÕ«RD(Q ‡½Jy“L®Šüi-Ol8˜!4ûòjKåpPœÀTéP˜Æ8&£…b½7}"º³3`»nÑ „c‡w¡ TnÛ>µÉ€ÞBPu§K>Å]üÒ䢷¼öès'èAÁ.ÐÓCºý&÷"÷Vu¾&£mµ)Ñ“lF¾ÅœƒÓŒ…¦ùéür7ûU9èÓ Þïæà÷éQ žþc[ñ8 ®vÜÙ&âÓ*yB&Ψª´ú®hæ wl€µ}µó¯N0&ÆæP{µ{+íïËQ×*÷e¤#ܱˆ”÷®Þ…KÕ<öñ ¿‹ÕìW:¬5”쮋‡¾XtP/¨Â£hªer@Ç)¥¦Gî9Up+ÛÔàZíÐ’w¶Ókp7 <£&Í«U]׃Ÿ¯×z{Æ­}¨ †A}œ„{Œ|̸µYÌ Ì;ºý2nüY½Çr%¢ !X "F¸góX»õ½7f‹ûÓÏ1L`ow«;7SñÂÍn=ݽ×EIvï·P ñúžü©ÆÐL“qÉÛôíPÛâ> stream xœ½[mo7>ôãþŠý8“fÇzͨEHÓÍ¡½¾8àÚ¢°ãu’Æöº^'­[ô¿I½Q3Z{\Š ë]DI$E>¤8¿.E'—ÿ…¿ÏÎß ËçÛ…èFã¬pËç‹_’ú,ßgçËO¡ß¨–JöËÃSèl”²r:NX-Æå*}KÏ”ËA,ÏÍgß=úü°=üeñäpñíBÜ6G¿”²V(?­6үؚAºej‘þlW}ÓµÚ ¿VVêNˆ¡9l¥TsºyÔÊæiÛ7_¶øDÊfõ¸U(ö=ƒvø¿RÎÐÀ¯¡ë7í*ô=ŒƒÂWÐ HŽ£¥Ÿÿm‰¸„Õ9ìÉŸ!•C÷ŸÿvˆÌrwèÅ —=¬6Snȵ+tz†ºq)M§%æ¬LopÌJ‹ã–‡'4Pƒ${i‘ºzg{ÖtsÝèrEÈN*Ûµ¢ÓBvh^bÏ¡\s{€o²oV-HWIëÛ»:å´4aI³®g0',ÑY䌥m.‘Y㨭m®Û•ìì`Uæ2Î4çžÇƒ0¡ÑZÓüÑÊÎ81ôa*åde8öÜàT²7£•ͬ–2 5n«¾³£€¯_.ü@‚jTÍ3ä÷Q‹ãW v _¯`UÍæ[ac¦¹Ág}s¼ö}ŽbŸç8ø5~[c·xÜ;œê¦yÕûãtå3$9:TífÛ¢òIca‡=®'þ¤ih!ØÛ4Ã9þÞä1~?= §Ç¸™ÍUVXœ9ìµÖl.i&Å/ÀÄØoÔa¾ysÑ"“µ¶ Â¤|—-êÿ(ÕHœ´Ù̧­*VB‚wÎ:Ç ¤äšãÀóë´Áél%žõñèÁ7Hµ6Í÷øXxÉnØD+Zõ —½Ñ“­ñ«—´¯ÈbC+ÆæÇ´ŽìrŒx€ýHöø%2¤ÐüØâ´µoñ«$¡as9c‘ˆ¢ ñg™ ^“ÎmN‘€I tÄ×¼JZ̨œyʉ£Q©hø©õ´œ“B혌ˆDùš8§¬ëz4Äžkž94˦˜ß³Â‚怵ø33Ï “~œyŸ•¸ Ç‚¥zÕõ`ÞPXFƒ ¤iÑ€•2#­>]Öû{dl:Yª¡Ÿgbéâ*©(uö{ú-ëtbÝs¤`q‰ŒmDûƒ´Ï‹4ª³qÐ õ¿Âv ›³ÌÃ`ÿmaÌ”@óİÍD^G£rÛFGR5…ƒwix½JÃ泄Ô|ÉhÐ$~ú´܉æ"¢0.Qó¦€=Áª ª"9qeš3Ÿ{TUÐgË Úû†I§0 qÔE ê¼— ]/«_ϲÀM)<ð iMà£4é4áDpØ<ˆÐ< Ä \ ZÔÙV˜züQë¥úVˆO k£';@u‡uŽÛø{‹åq ’•øä'è.\XŒïî‡˶ÆgFx•èÒ7¡ÑqÇ©#›\ ˜ ‚_éù¦úü:=?ÊÏ_¦Æ³Ü¸âKbrÏj ¹JÛõ7BÈû$fÏêÓÈÜM\ø65"“éÐ!+…÷~ã Jd”ç5àvÉJ†|†e¥Nq–Oˆ,[òi–8.F êöOßMä–Ì×5n]D d>ôd¶5Vªä·:ø­&ŠsIÉ܈›îÅHf]“ožu'éyÕ¢•G€™öèˆuŠ¢Ù‰Ò3s{‹>v2"†Ð›‡s`ŠóMGOA©üЄÖ0÷ßU¯ûº¦ê%HÌA?¹Äž!3”I›¡Ÿ_Ƴl¶_XPôC'zä€S€££ëxV˜{åæ—[K"ãQXB9SUšA@,è`&´Ü`s÷Áš'P—ñis‘';* ?Ø[ø5Lü͈NFíŸÌ7¯KJŸ@bIp(Zzñ#”ÓÒ†ãÞ¹ÒÊ3¾]œ'H‘<ÈÛè¡yÐç¶vˆø4!š°“›Vj&<Ä9-aÃG™'S¤›í%Ç»4íF³±×$ºÈJtÉ&·· !£S‘† ˜ˆ†LSú¨Y˜ä¬5ñجjð µ ÑdÆOQ3^·Y7?ä$ŸØžÑCÓ@,8÷H°P*-QÓÆ]J…4Žgb«ÁÑjLsÀ9|Üö>Æ6jé¡sßGèìÏâIÀn„aMv{U‡t—Û+p½^DB9Zˆ÷'K%èå´Ì.†œT|œÒÌ溂`<øçïrtgߺ¿Ï»âÌ«Üo¢?‡á~Õ85‹¨2£“©ú+È æTøù:(¶6Äe>¥ãÆÚ||«½NQ.*ÞÃè¦lÆ<“E쥕!W°_ìå ªúÿÆ^S˜»B/µ+ô}* OÖyëC­E9·…dqOeH¦ÕH#wšŸu[&“êI²ÈäÒkA‹„`cC‘Ìù%(ÛêæSÄÉb0@Â•Ô ¼Íl" x­jUt*öÜ#&äáœ1˜[žÊeøÝKŠæ1Á&†óQŠ’Ò2¨Ðï÷é:+@á{[rÂ:1Ö8a»Ð ûá/s»û”´ßt´‘æiaWMiÙ#Õΰ&øƒÛC2ƒS§P†6g;¬]ìvžD§`ï2Ü*G79rÚ¶E)êK®Ä˜˜íàh§‚sj¢m×çˆælCHÌ'ÓW² kt†Dô69Jž„ vàÂ=#:ë3ô›„äª /¬„~pæX^<$¬†tôûHÙôý@p®ž²ñbF@8Gt°LQôú ;Ëp‹;³ÌHÙÛ "§fâ€<ôÎ4 ÁkK`üø¦­‰ƒî ¦Éò}´Ie@3@Æ›–£pù 4I+ñ‹MÊ>é1Ý„¦Øco„r¢äd’6ñÿÒu›A¡ÙûÆyb'0ÝûQ}L½NnyWýÞ‰ìew&“ ²¼°”¯[)iï8Ê4ò­OA_`oÌ*j¯¢OZ–Ôa:½ÎúQ¬•ë|R¿òz2Ž‹))2ÊÈ?äS™’ª$ïêù)?Ï5[¬¿*tü*¹HXÕ¦)óVéÈ¥®ÕÈ* ò)P|§då¶hrœtð°ÙUû{’z :&RC^PµtÝ=»Þú¹B9"¾-ÚÆû^<à}6å“2HÜzß’GÒ9-¿OI¥õ3þœûq㲈µ,S@=ɹ‡;U‚Š; NJ+éù“Ã’½ ‡žÝê0PMgà—ÐK“!,;ŸÂ¸]»‰]?,r_,'Z>™µ¬r‹œz^Ãç×¼1gµžÞ3xöq\íˆy)•Wq•$_‘ß+YÈÇ·`»¿üBsrÆq/4÷¶úû @G¶E5t’йîu\Þ2íÊufW¶”aLjíï¸cãϵ( é²ô=SúñʧOަ,²«ñS:ËÙK¤ûB”þ÷m¨ F¸¨ZG|‹0ÊCÚ½µv~Å̶ߊp)ïb„¯ZÌ`>e2]‘wÒÎR-š¬ÊÉ4ÇÉx³qÉ¢K_µÁïÈ&v•aDgïâDFXòýH#•BÔ3j¡Fñ²,ðòëç ôZ¸q†°”)Ü·Lnê*—"°zíðæ{Üæi¬ZšˆWÄ›ßB1IµêñŒéO§é4>懪`]ÊAQºT,aòq)¥¥;D9Zˆ¤F¬ÍýôéâàéWËë«×ëÅÁ–rqð~|úÍcøóô³å?Ož.¿½µ˜v^j*µÅÙ@Ä6›Æ G˜"'Ä®©)‡,'mªbŒ}ZˆgD¢ánw=sBÕ‰ÛRñZLÔÓF ɯr`$UXÃ^8ÆIÂô±>ŒßUN*ÑÊZ1 …Ç8;Ï I_±“pó[ýú„ƒÂ™ÆP:_1…af%~}²J»UÈXpâý«u§ÌL‡Š³ÆK©ê‡yzNz8½! 㥦 Ò}Ê2¤æÑX,ÅõÊ©9º¶Ÿ}bR;¹·•‡MÞÂI×ãnó8& XúŒ<òŽDLÏR“»ø‰&NÂFéÑGº ‡=†¦'»fÄ¡øEé¹&7&ZxW¼> stream xœÕ[YoÇò¸¿bg ípú˜žn `É2L#A$™€d!OÑáîÊ$e‹ô/üƒSU}UÏô’’" P³3}ÔñÕÙí_—}'–=þþ=Z/öžË³«EßYíLï–g‹_‚Æ,Ã?GëåÃgåRŠayp ƒµ”FXXÇõFõv¹JOé›ìûåØ/Ö‹æÛgß|wÐü²x|°xºèoÛc€7°”¸'R,G +Y\êy#ÛÕÐôðçÅÁa‚èzÓKO˜³FiáY4zn™Þi¡ºÑ䕵Có} “{išoZ笶yÒ®¼TJ7m|zÜjxÚ4ÏÚ•´®ëE#”®] ß„†5o6ïGÝ7ÛUZŸm_5<B6ûm|zÔ®„ÁeFüø”Ê쌱}g´géHo¶éÏL—=P26'øû7üCOÏ£Í?ÒèãðG; Ÿlósƒ/Îãðæ:®fñQ5/ñÏþ¹_zÉ@ÃýÂ0G"ŸÖÐLáàßøçÞ*¿iÞÅ·È,èS/W ¬ap ªã[ùºL,]åMÐ÷f_ïÅ]ló—KyR.ðç‹À,𙏠;vŸ§—癳ÌÎu~ù‚s#ÇåÁ__=ǵTó{’)Éðÿ¼òäzy—¢e¢ê-ñöÎîqÄýÌÛYbë:§*'kÂÈ÷~¿“šª®¸¦ã„ÀÄe Ì’¿Î,e /kØ`óDk!^ãÛ’Y|ÔÊrn«c7ylm 9ƪ®ðÂÁî@Gòvÿ'è¸Û±Tò¾f¬;Álõ]žô!€ÖªŽä‚»uFpA&F€á7ÇÉ­o’¹=”aѼþn"1!¢í “*î=¸ïYý*†™‘98æÑ·¼>O›%§˜ ¡* Å^ŸuÜ,ŒÞ+„ŽöcÒ›˜Ü’Ål*¶£Ê $)¢"é,äàù>)¿êcÅ$F”&-¥l"«J+¦*u·„ âf5á¹}€pX¾˜pÄ' 'ë- gZZHÙAâ,–+5x»£Ñßä@dÿòí6r(%a„Ô_5> ;×Tg` @¦?:®1ÁtN4küõº%g§ÓR¨˜SN\€ø4 FhÜêצ… 䯿ÅÕpަåñá_0ÇY¿mü¾Ýø²Å‘Ós΃é–1|–—y…3%Õ5§P.Áwí¸l6™2¢–m‰’WD ÅJðg fç¥fý¹•þ νNåVIüà·Ø®óðCÁ¦¿Œ%Ý|0ÄãÀ+t§´¡Êq¥ YptÕhµzk<(gö Qç\gÁ•ÿˆÕÝh‘d¢3£‘¨¶¾S½ÍÈßžã £†X¬H`•ŽÝ´ö£,ÎGÀo‘Ûêæ߯°¡~¾t@×Ú›ÄØë°•1~+;tÂJÀ8T—ÆHÁ>_ÀBð"•V NÀ.£“ºj=C01Ÿï ˜‘]ÔÁT⠫ч€>r4Á¢YhÂS66fL8?»bøŽêÆbpTXþcº6…}Œâ*¡ã¤m¤ìä¥·ÞøÒˆŽFN:þ….‹$˜ Ïñ†§-¶®¸õvÓP…ˆ–P®ioü‘oùóËÀÔáîŠ`ZÌ¢¼Á’ëÈö{S3¹u–]\Ù @LRq¦4k+>ÝkyBù¯‡¯yô€ô£p<iÂkÕM+”$èëÀ"3 PGE(éÑõ{Ky®R>MøXè lä¸ìaQG‘$%))dLoÊAûùuÉn‚I8Z'{)•¦3RÎŽ Y°Fµ1ÒÐò¯Ú"}ÏZ—ÛX /(áaùe1=¾\fÁãìF•ˆ—ÚR…JÆz7¶ÓÁ6-pDü—iÁቡN)4'©DÓ”Æ'@Á¦•8(ÀËÜ/}50À¡³ t PW0CòyVïm»"‚òÓ(˜WhÖ2mÌ·ÉÕ•¢S2Bl’ŠWk.êH0t¼ÍÊ®¢§ðq3µS]"¨F ƒ:f·ñ‰}Æ6 ýmÒŠÁâ ©2¾Ÿ¼’Eè-‹ýU`~zòä”ÖSœD\óÓDŽ#i|¬êëyX‘ŠÜéüаý’cŠÂ9[ÚUoHª˜”¥ ÉzhÊRš!a;t¨þ‡¿¤t¯VIQ”´–¹&jÄ‹ÚÜgJr_§ª+åã ÖþvžKᛘLÜTŽ”…è¼}(SáÐ¥œ§ÃÞIF®¥N°fu"s|7…±Z ˆÅ¹2-¥†€:øbc*¿;ï”ÊÍn~Ø`’#çýH¨ ~Ž{ŠPû¹ár’ ÛNóΞ\Hïÿ˜ggŠK",ÔyQK[¶^o¨•$íZ³!­rÎY?gâír¨™qÇœGŽö6tÙþîTÀ[¤1øûÃR˜Y‡ƒEQ&ºcˆ­ïAgóÏ*{Ï÷Ðò®̽J,G$¾Êæ|pÄH®¹ÍÄx ÂÉ• £U¨q¡Pf:cÒ}î‹çöùÓíEšóæ\ …T°öWŒ v ‚ñÕˆÝÜT2ìR¤Ƹj]Ùl¨ 35è†Ý›Jµèc[Ey2”³uÎRåQ®t''4Éœ£5Å%–ß ´q‡‡UÚ¢Niük•ù(®XB³Vð{LÃ׬”̆¬Â@áö¢ôʘ)ßRþ¸Â¯À§ö‰L-ÚR¨—rï|ÂQôXQ¥XA5hÊG>¾+ŠFÓÓ™Xò’u·;ñGœCÕ]͵¢Wx¤sCÍ]$ÕÝV€!zIÀú®5Xýáy—’ äÊSñ¼âIôSÚq+å›008œÆ”×Û”ëd¶ÞUöóSýë«yéÔX=½\ãÙ_X¿ïå€Mã7yÚ4ß ÉÊ×>hý¤›°çiÆÑl[m åmþfÈeâ*ßG<¯fYùF0¯—äIÛbRxyX»4vRÞewd{÷.XU9^ëÎgì?å_Çú}ÒeˆÇÛ©­À†…,T=¡Ã%­HÝüm,3¨áRhÇevÅi#:;º|»#uUo|=70­¯)4Š;‚³–wÄeì%8çfqÉü' º¡\€&~ob7x· ±Üâ˜ß!¾®¡ ßEÜT]#$ šyžÁ‚ÓÏ#„îÌçð<õÿYB9ƒ·“aÙ…ÿÓ!×EºÀ¼ñŒ³H¤5”8¦àhv õ¦OŒ` 4–Š}ŒÁü ¥HÒ¤|Š÷kçÊ!ŸÕÄb™|üá×ý¶ ˆä>Ùõîpþ}Ùô~å—q²¤§‹8ôendstream endobj 329 0 obj 3490 endobj 333 0 obj <> stream xœÍko$Å1"ßü+V(v"voú1=ÝHù'A`)ŠE~ÝÛë³}Îïà§ý¨žéµ×¾"Äzw¦»ºººÞU}oýZ-zü/þ=¾Ø{öí¸xu³×¯½ ®‹W{oöYÄ?Ç‹O`œ× ­†ÅÁKlµvÊœÐ;ÓûÅ*Ëïtß/Æ~qp±·|þí'/ºƒî}~°÷Í^ßÃB©uïzÍëïŒUŒ±³£ ‹ülÔÞ#üï—ª[ Ëugø‹á_+§ÌºïÇåwøû SÊ,?O„€¿Ír¿–Ÿu+íáQ0Ë/áÑ×ð-ŸãcG_ÿ_é÷hiØóNk€ëÂòï†'ÆÑüU·ÂE•ÊÀ VœŸÝ!˜Ñ¤u~<øsÜ8Ò0(Ü8ŸŽZ Ú­ayŸw{DƒÒ£ËžtbD\±]kÖƒ†?CðŒu<›H“•Ö# "|¤ ȃbò’P_Á0üs“Èò¼ˆÛFXÈÞ©¡­ çQÜät.ó¾d|Ô°Rצ“ÿ_y·‚}´6¤oâ*Ú …õiÁëšã¢8õ<Œ½`þˇt™Y,P=Shü¸»åHb š#ƒCiËЄä$H$p YK 6yÝ U§%T&™ (€(<±± J*¼!~Bª#xAŠš÷*Ί;&ÖrI%‰5÷ȪCFË3·Ó˜ òâ¨Òq(~zϬlnC6â®S†U ˆ;+Kàoeׯ:r€Fbù/÷þˆ¦Þ€«2(G§ˆ¯Ü ‚í ÷à}‡‡7úà4=µv£ÞCª€Än”OÏÂhƒEŽC%:è6{§kÕ@ª\,—Š,89$ 8œµî%Û8¨qä÷äð9¢kXë¿©‹#ñDyº°‡ 6#co#ZÎ1Z~X+¯3ZÖ4Ð"'V©±W-룇xÐLPt„P‹à!v˜PKà£k¶ø*ϧò7ÏÆ,ŠÌ ›¥è8à—³Ž4¸E‡ä†ùÞu††_€LÞ‡]¢KÊ Ú\OYr±¢³š N‹^*6Œ¦[£ «Ø2{r[•f#ꖕцçÑbbnÑcw—E³!L@ J m‰®f8Ê 0¯p|/'m„hWZ4}=A¨¨y¼Ô·ñi‹bOjáª6nmå²*Ò{õ¥[ëlF›ZäT¸B@KÐ7~bÉÈCo)ƒ¤ïlj­k2¢skƒ|‘yI;$… æÍÌ—7™¡kî…˜wõ›±žçì!~ V1CK9ó.\ö6ºïXΘ1#€M¨±Ö2!:™Á. Ü£Íù‘T®Ç îá¨S§¾îtÓ%OÔßÜ·™ð£y^³º0ÏÑ?(ç¿ oø€6kŒ[63„(ˆ‰…î;Ñ^‰ŠJK6ÌZÕ*"ó—ˆGRÙˆ}Mr~’`Wƒ¦µkí'6O|“\[x/Ž{GRH qr2€Wpeñú2Ópæ¾›èRá‹»«èÃ+Mú £%%cZg‰M‹µ„ëLêQŒÂHGÅEÅq%†F–Q#yãõšr5ç´…òž6ÑCêUÙT$ ¾>Žº5Žß>ë’ÞƒÕMˆb†["ÜÔt׫DýŸ¢¨œöã8·2N(¤Ìü×,` ×÷C‘¬ ûÑ´Æ£wˆt;ôk)”)¬¬‹nÐHÌ©›ƒˆ-n¦ F¥l‘uüÔ¹Kú‰$³uÌy“Mú`B§–fèôóÔáPËgyô3L»û>?|Q$æÇ’Ç)¹˜ÃJ¥÷G2w‘€^w ÉU+«s(•€`Ì’ÉIù™wùᙌèÒÃ×qur‰ÓÃË2ò® üSkKç-ðé,@×\JœIí8Ì} &Éñý9œUœWçp¤3ÍÒ¬ Õ侜²V{ÓÅD[æ]äé’w‹'Å~òþÇßÂÜ?"MªûÜ ¢ üKIÄ?d¯{â5Ĥ£îêa9åEçBIÇìäP€Àx!ÃR—гx”òLÓøØÖdP:¹ö¬ÔíÌÙ(¢£J=ØéÄY:K?ѹYAHFç>e»!Ñ ˜íÏŒÔù§æájNOU³0˜õ쮓zÎD¢Z¥_ÅŠ%n×Ù ­·#…?û­0ÿ†üÍÞŸûì{eU›åä&æ©Æ¡„ ))q”Œšöì7§¤«…ûmDéJ…áQ¶«¤Q¶`Û£ËíØˆlÞÏŽÇåÙŒ ¿vG3öÞF«Ø«!ÃIÌTA›'ø[¶â†ôgÕƒhºŠØ´¬ÔÉ+•j!MÛsRlOe°æRUEY±±«-#›ˆÜW>ˆ±ZLà Daöp$U&\¸aÌR7Vf(¥ífYºV¶]ÉÊÙš—ÓÊÜ|Y²äkþˆc“:›2Ò9‰ÀYÛøó*IÀ]ü®V¿)Ÿ³-¥Z+ý¸Ðâ}!«d65z¤©I§¦=è‡M Çí¹Â`Džhu„óö=ÍŽ$ÕNfGý–f§’¢Y¡Ô$Ç 4Æøkô̎5P¡4^%Œ¸~;SyOÔ«É[/#o[ØÝ¶°;n<—ß„3Ÿ(RÁLNäÌ«¾—ùáJ"ÏéH-swùíV¯~Å3êø8•#²Âʶ>8ËK pQÉ,Ç0ž+â›È:äÿ³]`'ˆr}™MÒœ‹üP;éaZã_³x ¬Ö[y„›¤0ÃËz üð®¢Ø¼¾½iáMaÀ‰“È@Ý.Öªn.VLŸP~§‹5«'~¸!Æ‘GkÒƒ“xÔñtUpò­ Ê™=¤ ÊÈ»–0¶˜ç¬Å•R˜ÇíI)(;Q ³¤Ä¥4öŦKÊí¦0ÑcV%Q¯2'œæg§™E°À8gZ„ø,¾NâM]/”vKG.CGà«8w¶CÒJj«ÖbÝ9Öš©Ò< Qk쳄ÊÍ>ÄŽÖ§âxÛ[ž'Ÿ6-μ+®©Á_øñp Î |‘›&o·Dä¬%aÕi­Êq制Ðñ$ªœ™³Õ»µ^¬Ì°ì ÏÂܹ]¯bÅ,­œj¤Úq¥*uÄ16} C,÷û|ÒQ7øš¥ÒëO1EµxêůŸ”8'¾yŒÍs¯ÕH8N¥¯óê¦öýŽTùP”È á¿F7u¥íZ›Dq‘›£®Œ`Yè¶k— *`KJ'rY0U©Ô­© kv)uƒ êEÊ|‡hC65Tá•aþÖœüØ‘¦T%nÕ,¹3ÅLªÒtbS“z€ŒkÐPa3Åѱ7ÉRí"•À¯ª0[+Ê+£Y³´*йIɪö„QÛED1èŽ(Jn¨€R‹\I‰“Íó0™E67rg¸ š¦b‚TßFS±kôÆWΙ¯I×MÕÜ—Š5"÷ëˆl9ËB ¢Ò襸ç:'gæað›®qŽˆW#UšWyG)ˆÇ¿)ë%ýßI ÕåQ<õy{?¦5FêµK ´ØÂ¥ŒreBC¸TÕš˜àpˆ"IrRŒ ‰@ZøªÅê´Põô^¤íªê$ -r”U¶³îª&®˜¸¨‰ÄnÎ*î¶¶-RÛYF¥[qH*Ò¹Œç޼M©W§Â6“ËÈî. òCR[ÒdSN-ÊCT™ëÎÊ9·Ò)#‚§UWÅôèci³mÚ>È‹'g²4‹–Äp µ81Qf®•5Í‘¨Ùš<ãT# …ÓnÄiëÅf×j“/“Uئ™×º©¬hÜu­¦D9¸ôf£’x…QØõ¯”œÏ= éLP1eCLþÍE›cF±0F`zæ5ƒK²êñ º®ï¿‡Ð¨ŒÁá½Ðýž@uñ ¸YbGƒ¥08 þªQ{ªÍJiù\Ö`÷¸u±Ïùi®©Ò«¹I¶ÉŠdõ|Þ"ÍŽßctÞ11)ê›á&¹¿º§\'KýÔà\»ì >ÐZjKké>w~ ƒhõ¤ì¾÷ÆE“¨­÷x6ص5îÁѯ‘Z^õ>L!¤&Õ¸(< ·bÀ–nOªDÍ»=SóìN2[û’„«‘œ˜›˜Ó»ž¦e·%¨ÒÄÕmÛÝ:ìDÿÐÜÙ•¶:Ø\ŒÈËžÆ%‹/p¯É( Ë#¼˜£¢ÁpçÂÌe5ÊôuÛ(Rq+.àD€ê¸gˆÐ9¬ÍA) .•/ãðÊ·å+VÔä…(9BšŠŒµ)ÏÅl"A²f`Ûõ½eöý ;˜ª*çÌäD‡%R¨¶*´6mŸ®ßÄ F£òފˬ.qÙƘצHì’ÙÉd•üfa í+,(ÚÄã_Xþ_ì}º¿÷lÿ«ÅíõÛÓ½g[¨½g_àǧý þì?_ünïóýÅ7[{»£BY…{V`PSGª28VN†mí¡èK6û£Ü_7½RøhŸ¸ÿ þ7ûÃtÿ¿œ'™F]ÇUC§tÀö-è X=ùkÍE›”ÑÆl¡ýµ)£3œ¯(sR”¥Þʶ›óÓ-yƒwþJen¦±ª^…i/JUÔ{_ÒìÒ¿>錶ÝDÙ0áXKÂ+™’›Ñ¯¯ •Û®LW†²\Ë‹Ñb†n6?÷”eÞ–ª0†SO,éj™çžŸ£ÎÒb†RHÝÒµ%o^¤ÞlìÓ…(e³õ>T¦VÔòÓÙz–¶OãU.ô‹[dÆ«b¦0ÖŒcîëÉ]v颀÷dÓw뵎ˆW^ím,:L­=¡ØO.’Tµ¶4"G°f¬ûgÁ-$îÔû`<7ÿ=ØûáUÅÄð]ð°V}И’Ý?[mŒñ˜¸Tk­t‰!´}’‹±bˆ˜A-ýÊàû¡Ì¨ûP™âuÖÀ?u˜äêÖ-°ìvg³V¿[3¥'ž¬šÝ0Oº[½$Ïýžåõðeø„h~ÌL䎇ɖ0^·ýömU˜†ÚÏšÛfÒ«*q‹NÁ£Û2j?¡Ž{æ-ÓÌãÔUxØ ï`€OrÿدLW_Ù¼0`¸]‰"¦Éê9Á?½s6Õ÷»k:ìPn‘ᑱ-e"ƒæ†Jia;šÊ6¿·oâöMz×£óð«ù&Žnj©~HéˆË˜)°‰[/Ï3Î[ÖWMÀWs}&ÓÔ«¾Ú”ôí;Ù)-‚›xI]îf²-L8Ï’!Óñ¿ðPÙŠúv‰é›ñW;¢¼e–FѾÖqÒ冨.xÔíVtMzv/ü÷,vÔkPJ¼ÏUµ¢[KöôHàŠ,_]³´6WƨA„K™û[iȇÐ4äx­ŸD‡[ Eiþaà[ÎåÞø}ù\3p›ìäÎÚ´eØ ì‘‰{uU&÷~!ç JNÖw.#Cþ—î¿n]báfu°ÃÓ<9ª…7•\àζI¿]?¬/è'×”nbfŒ‡™Ñ¨¯ì‰,÷ëX˜ fnñÈO-NÎòVŽ\,~¥nî\¥<ïb‡*ð¬R¦d*ÍÆnX ã½ò}¬o4íl0Q‰n½(a|Ö¥ÀûoÐ}iyÑ9ú÷>T¬þu©LÞ}jÔaF•jKu9ÃO|Ú*^¥é_•ÛþoPÄ~r2Gßìýh€rendstream endobj 334 0 obj 4676 endobj 339 0 obj <> stream xœÕ[ioÉ ò‘¿‚p`dÆ©™î9zœ8ˆ¯Ý•±^ø lCxÈ DQÖ±Þòã·ªúªæ)j³v gú¨î®zõªº§õiXŒËaÿÜÿÓå`ÿM;<¹cSuMÑ OŸ%µºÿ¦Ëá“ ´3j¨Êz8Y@ãJ©¦4 §+]˜á(<…:UöN–ƒìÙ›ÇßLòÉ¿Ï'ƒ×ƒbÛ5”€¨®Äqì$Ëa«@’AQï2•júù0yá:”ã¢)”Xg]•v‰MÕ–Ý0”U¥·M”ô4¯³ïrè\¨&{œC»Î”Êd¯ò‘†B­«l’û§çyOeÕdoò‘2ݸ(³§2ÎG‚º²%NÞÔ¬ß[l]dOòQφ‚Ú žëRe¹zšÊÅ´XïÖ©t³A3MÛŽ•[ÒO0õìΠgÙD½Ï°à}%ª€‰ÖÙ#xÔU^`Ý%þœâϹ]{Yf×øº€T\ G ¿š=ƒ¡¬Ô{ø3c1É÷}•ôÈËÏf±ý‚ê{Ýýn ufÞùTìl§ê%T$ÁÊb®¶ˆ¹Š=Þ¿—äÜ …{п\möPˆZòMÿJ¤BÖ_‡ÂqlY†Â*R'/ }—½ÇJ›Ì¤Ýpõ¦ÂøÒññ&v;˺«…µý/Éúƒ‚òÐ)úf„ì¨*š10…ªÇByé¡W£N+]E*7Šô° …+(lk¨³¯3,ºÁ®SÕi*ü˜ëlŽí:D¥ºÂã9¾PÕê3 ý0] æ×•]7œ|?˜/Û^ÃÃcÕjI15Èsë[$a„­ÌX8q4“Ÿ£‚¶ð­¬F‡•YányÌ.Ï÷µ<–Ý$gJ I—!2ƒ „0ö16`ÂÂÖË®B´êk±2¢ƒZl¥@ `;&b‰èº;б*¬³1¾þ: Äú;ÇómÈ®´Bôê’WáìØDÝãÌd “ïœ-œÈPLªtg¬¡h$Â’%T )`Fè!N!69 d`¬h ­‰ÄÆÂ—™Åuå°Ò&ȃXÝf$æW5Hýz êP¥£H®x?5nÆbÐWÐU§Ðªmµ8p*؇kµ–]«º†{Ö1d$X ˆ@BÖ$EDúuÖ@Í¢ã"8±È8ê5„ÔÑxé VZÚ=‹6&¶i ‚öq0I¨ øU©O©úº—4)LÍÔÅ€Íð8ó ”FÚ6¦(ƒÂ­}|oQø8g$:Ò•¶À…(š|“7UÕjX–åó¨7,ƒ< p¤^'R‹Õ9ÖY÷FŸfœNVœZò³˜^9„C‚À°Æ#ILö/Îx'8C”—„hm8F\ ög³Á€a…¡Ö½nƒ!Œå£ÄZ)­ˆS×f"ÄåÁd)—Q fÌÎ<³@f}ÞÒMKºY‹DåµgjFT½¹qÎvsqÛ]ä,2mbLÖžÌÉ0`I­åå§Ô•žö:SL9>ѕɋ˜µîåZZ?H^ø­ë70£æ+¬ßU²þa-|wŒŒ1ßÕ@êW1þÚs'êd{&5·ÛÖV׬p›š éP_CMª.1s5õ²>18¨±Á,â¿¡Ø/]¾¼jºvܦºâÔâèTvâw¢k5I@ýš:ÓuUbýÒ:Óu;®Ú.QÚ¹KkÈQ€€Î‚²6º±>$%¥kG:µŒ£¯½F5ž§ü+pa³²ªhw0\’žôvÃfagUw°o‡XÓv­2vïO›4%öuæN%Üù;dš‡½%u¹q­mE¶?oñç1þLBã·¡vᎪú›Õy,Kç7qw|Í·c¾&ZÕxŽ×Ð@¶p?ž"òîýBÚ[c¸çSZI£ÏÒ,&úß+ÞÝt ?n_Öù|ÀîÍ÷ò¸,CJ·gÊêõ&œHLÓsÀÓ`_ªEâè0m³w¡æ"µ/5Y88¤x˜ºïNõ™üJª¾EЉãtX+­>Ä„­k/bäž]î¿#ñÅ/B VBX¾› !Ću,Îúužº×Üú–¸úûÒªÄÂû’*ñîî‰}‰K…Qú½dJ•ià¥ÞðùìogŸÏnᚽ跛dzs<ðfM¸.•ê£0'x¶§ÔÜùR6@»möÏß•Ê÷"•'œ¢£*ê[Uñ—ˆðø%r áÖ;Óe ÜÜÏÑî%æñ»Øq ²“>Ô{* £ìà!‡\oNgBã¹ÇbµE«[× )®=äFŽOÓFEg-Ä÷]ŸfòüÈÆÕ25Ü-3ˆ[¸³ÿçÌ`=Šö„z‡(îäß5Š‹z=Šÿ†,:ñ½€)n>ÂQçþ—ˆFdì¯)X{[…B–%ÄØ$…„3ëLw ì6›`ù¥øðËpÛ÷QÓe ɘ..ÓgJ¿¹_vð!ËsôÖ;Ei&ºÁ™nKÜ*]ú³ýša5I¥íBŽW” ,õx%A!ºÃVr–€F)):QòÍ+@ë(ªê\e¹6 ¥*‘;/Ó”pûú•4©3u—ƒRaæ“û5^×õX‡/({•t;(MØ>;lKÎC¡GªG!ßžœdßà8K!1g WRT™I”q.qx|Ͷ¦€[€Óæk¶šYàUýÉóªS†à,³9‰3‹WˆâN%¨JN±”@µö (¸­w„ø.ZIÂpÛ0ÄfGGwÕ¢¥¼úûVq»9“¼ôFjy;n6¦»œ¤óû}<£½ƒgÄŸ%p]Ç– REj$¾MÜ üS©eôˆ+iÒ‡‰ÃEÓ!bÜ–O ù`µvgmý0`ŒBæ{À¼ì6~/£}Ó!-.ƒAÏ|ÿ¸V–Òë4qî>sÅ•2Ž;Ç7Qzú¹BTª¼xt.Ärp‘‚£É/%“³/mIlô6æQà»›¾1ÖŠ§ù}Ö»Ÿ ØwŠGüü¶÷½>-'cZY¢|/íV:f ¸¾KÒ3FŒ!=ۈŭ+ÌŒ½]$Î@§®±ë>ÉÑ™Ø(ì•øÇ§t7Ã’¢nëÊ[@ú)äªvçîê]Øò÷•ùQs¼þ\û?ÑY‹ëŠþOüÕÛµKw+ƒ5: MµP$Ð_ Koøg(E}Ç›{øç(öò/»×oVÛ«‡îè,i‰ÕøjìÕ}{·ÛÞÚŽ¹ÎŸÂ…¿Êèn4û¿uIîÇ!èc—©ñ^Œó¼‡ëí’KǬû1»\¯è…+$¯¿Št&öendstream endobj 340 0 obj 3128 endobj 344 0 obj <> stream xœ½\Ys·Nù‘/ù û‡]•v4¸T¹\>䘉|ÉLù!΃xˆvLre’Š-W~|ºWc{P¶\.K³3˜ÐÝøúý´±ñ¿ô÷ÙõÑ“çnqyw4^;†ÅåÑOG‚Æ,Ò_g׋N`œ— )Ìâä% ÖRZáN­ýb]®Ê39Ž 7.N®–Ÿ<ÿðÓ“ÕÉŽžž}}4îšÃ,„F;Ê8OðViWlµaQî9 ä=Òÿ×R¬Öf9¬T¼0ñ×Ú 5Œ£[~¸ZK§‡Q˜å7øèxe–Ÿ¯Öjùþñ ^{ #¼„ß^y#á±ü†ýc%ì‚Ôtçoð?u‚ˆ} —Ë/aÔs¼ça.—8©ønE¨åÉJ ï-ÍŒ/|o"Åg8±Š¿ÿ¹q˜W—_ùhµÆI5£Œ›ø÷Éß»óA »¢LÅÂH;g w$nZ­Ö°·`„ÄW×Z9à¨X¬Õ8[ÃâäF~º² `—›[˜Îü±ü8ô{$–ç°”+¼øöAw.a¤qÄ‘÷V2>¼À?î`ècx1c$b'@ì|â —¯€îmÝíæ¿¸]$ óànµÍ´`9FX \Jâö=ÌðIà˜È’`– ,I{Kì;†—žåO‘ø-,û™ôr g•´E&…Ó~Ÿ) gîóêt³™×õ˜dp<»¼Iœzƒ¼Ä½3\†`—‰ `¯ª®lnP1âíó2ùe<±ø¾pr9¼c7¿_±9”utdêã7l*\D¼Ý嵃¯Ü®:ŸI=+÷žBËG«.Çe¢@"—”-í.j0jj0œrC€ñи‘4 U÷"ŠxMWÊbÊ‹¨wéž%þ'±–ûš?DeΚ%…kB2W‰*¨9ioº§—¯Ë‰ÍÇaó@.6ïö®²ç>+Ëyœ²Èâ&©*AêO ¥èõqoö€#ëÖj‰GœÿèøèÉñç‹ûÛ×GO¾]ˆ£'Ÿá}õ1üuüÉâOGO_oæÉjÒÐBÂ4j8&°Ù{–„¤ EQ§ ö˜ºèÇÑïe˦>xM”ÒeÈV&©1dλf’‚{ý@&!‚WÀÉè›6y¾K“¤ˆ€¾i4?.äv%P©tØÎ)çÂÂ)@ùÛ8µy‰§q|+“hæ a‘VÚºRx¢G·Å”¨°!ÊŒ¦µ“I‘ÉgyL˜FHôsÝOÅn¤sVL|}@P©B@¾R8z4s±6ð2Êm’­_K²cÖ㚤açõ 5-–(H5ƒx@<&9‚.ù>áMX…wºl,v€ÞòìtlçLµ QŒ`©’Cð˜œ@¸©;?/ µ=(¤G‡n'gB(ôŒ,Ù@Ðgp]‹û;ÊjŸØº#eÛŽóW0èDÞ*ßqRÒQVPø‰ä0¶X²X£Ày1èѼÞçöX(ÆjÎä¨'‘¶ãþç¾¾C$¢}Ca0¨äÃ¥eAÑ5òõUÊc·´Žn93#¾‰ÌêÅ™—ÁJ‰åuÅdë]\Fðq7ÙBâÔé]k%óó 6_dóI ¦“ù„Ÿó•Ô@—‰ð,YR“è6ZDSÐ'C"¿ s2 ¥G—‘r<ÒcÀ{zEðÞGè¦“ÞÆßèµÔ¸´ÅѨ™lu­ÿµÖ ÞÒOü’ódÚ.sŒu“3×9¤Š:-`QŠrŒc@®‹Ù ¶dŸ<"ÕVŽ®U¼zÿóO:•ù0NÇËv<æ[Æ@8ò?¸T#ņr><* ½£Ó-aÕV{«aÛ¾#Ç8jëøÐ i»Ý.GïYŽî÷;–3/¶óR—Aꙩ7߯7E¹iwlÌ´3{6f: wl¬7¾?Gwc¦·1Éù:™Ù¼³ƒ=¶eÝÃÛÙ®ÜÁžÞx8{ìîéÃØÓ¥¢¶19­Ç¾¥]zèZF»=ŒvÆÍ·«¶— Üe´ÛÍèùÑî2ºK¥²§.ºŒîRÒ|{“õ¸‡PÉ—»Ñ·òê+­œgòڅϾ#¯>èvååwszΟ®¼ºTê|8{(Íõ§+¯.Ó¿HÆÔñ<àQômœDß697é±VžSµ=…ˆ•øvë¹T½­^„=z:z±ËP†Ž^ô±¢«a/@¢]*u¾œã.¥:çѺzÑ¥b› >\/BW/\œªÀ"g˜1Ya‡[ØÅf¥C¿Uç U90(Ý›ðc N~Y¥ •Æ•òÞÔyFš9ò"yÿ)çc‡Y¦À2UD¾&¦&AÖU Ù*!ù°(¥ÉtmØ\ŒiÚI8ÝTæÊºc vXH: 4Æ%;ª}B\ÖÍE•¬ÓU ('±/¿Ñ‘±ß§| æ}¿\¥4r‰_|hôAàcÔ‡ BÎõ´IŠ}Œ…œ&ñt”‘Ù]LR8Ìú+L–ï.û/¤Á\€ò¬˜ œÙÅöÌ?Oñž%q¦LvVä\=–ÊSZA‹Y6N’˜€{™b–yÀD…Á¸<æ1sâ&>,¿p”4 ç5±b½£B(•‰IW±ò€â¶\ªßTß6 ØšŠO™1¶«âi2.þý_4šEø9›\ØïyL̶ehdB@‘/nב“4u›YÆî~·ž;Ò¼¯¶e”+žpìJ—l²º 5DÊéêIvnвTqÎ ÆG)éoJrÈ™ÞK¦&4aoœòlä´|ЂªÊß­ð;×õ«(ê…±½Ü?á·‰™Í¤Qchê¹ÄÊ(Ôæ·ƒ,LD/¯6é8ÓžvbA¸B;ÿN1Kc;8ŬɞL2Ôw«RÑI¡dêaÅ3i)Þ¯Ï<ÓvŠÍ¨è¹Iþü0±å `´6¬b·EnZaï’R#1öÝÉÍ‘ÜÔ…vU–¹Ur¡©V¶†æ|5“[Âû¶U ƒm+€îÕùá>Éu•)#š‡¸ dxBE ¬îa¥ùä”ÐC„q¯[o¨êaôè¦øƒƒÛÂDÇÍCÆé@yv¶ç‡›ëÉ÷nÖ@ÞÜ`“åv€-èxt][ÐY‚ÞÚX…Le‚™¼;É‹+ðf¥ÇëF“(9× Ôƒ¬v(ÄX®(šySüÏ!tíâ)‡ ²–8Z½Æ ©„®ÈÈæ^–nMK6.YV%v}óX`§JDih. Œ ¶Š#ú@Y&s¦ŽŽN m½Ma4¡žeÜ/ÅN~€'%Ïìelkåpf†÷C<Ä2HØA6ð+‡ï¬¥mTص±@ÔðþÖÁ3Óðv È|/Ç[?X¹‘A¯å»9)QFAr SÞã1)y?³9•É'=WÈT§Iû¸Ì&©&kX5ùÐ-pû”¶2Uýz™ ?Þ”„‰€e{mD쑜 Ö°›fµ! >5Îp#Gª$ƒópìÑÃX§á`^ÇðÍK£¾ à\¹ Á Nbc9e­%mTØY‡|AšÀ"½üw§‚r! ‘h±â¼È|7(ƒi¸´o`ƒ$„ÑÞF¶‘xÜò9°Þ+\ #v¯Y§a;H”@e”ÀŒèy”—P‚0xþ‚–+¬#Gê ¦Ç΃S¶š ¢…µcô98'E Ûj3ÝŽ-ˆþ-:™©ºúí*D ½¨.ªp§àº\%P"«ˆÇȪrfïQaJPFjú#^]æâ;Ù&=MxYKŽÐĶç’éŠs“ ­åtšË~ÐXŽ8¹UaâseˆNh1É»MsfäIˆ™à µ¶R»$Ú&B"'We¶uzÎ[ƒ›/¯»Ö®ë;íl #¾{]!­v‰ñ4CoSï-úQqã­•0˜„NPj˘~º€\¨)Ѫb>=Û†Ý,…—EÞ÷Uv"¦Þn¢„Í ØLsÇq޵IÕ_±=8›% ô >Ç‹G4.9Þ¿*‰®óöÁ«6¡:å<ø\cääÄ/aYn5ŽÕmZ7¤œÿ ÉoYË®'"Oä––Ÿ4…bkÛ¨éàéùøIv± üäY3XZÌĘV;YWäMÙ~PààƒÖºN<ž±y PEôíP]JƒmÜÁfæÑ¤ˆO¤mÐåéV¯‡…0Ze\Lƒð• z¶J>;óI’Xœ¹ß¹o;Io0ùù©ß ]ww|Íãrb­¦ÞØÚÞ—MìèYÝn¡Ç„¹ fñé]c½~­Ç7ûž’úM—ø„FZÿNÌ.{Ù”^ÛôÕ€hÖF¿r«8}‡˜ËƒØš’Ç‹æ¤¸ÇÆàÿRKX¬+»ŸïŸRÙ]Æ¿{ª¦G‰•p”¦;—¸€ ›ùçY;j‚–0shcrÿ7>cJì¥ß“ŒÍåª4£Öl9õä†Î¹õ“¬™ÌY%âñ=ÍÆ0È)P¶îQ^1–5Ù©P •i:F¥ á7ƒª8FM?oW¾Ó¼ë¬y}úfýkÜYl#HªÉ¡Wáé€õÃB>ÓK1Y„ˆ( ©õqÙËC—Y”xÞ¸Û?B@³¤<¹¾UÙ6]¯6BmÚW몠ükSø¼†}ËÒDëü¶Úå´¤Ä>Â%üÃÜ~:wBòS.)ppàbò·¹S— ç¥ýJ^Š©ZÅÚuRÜEôôs¿;^)ÒÜ?¢;žVìvÒïW¿±9^ JrʨšÒñLoÞç.7XÑ!Ñ{ sƒÕoºü>q€•³}ÑŸ’†Nú˦'rÔÒrkVkdý¯ÏI% 3³å™•óTrßwA®úÃèâe[¿ÇD>––zö·äøZPMUr¿¯ÅcZ‹½ÅâÔ&¥ôÕš ‰*ü ¼qETqBTh>ÕfNrà šAªCþµ€x¢ßÆSó˜@¢-I!ÎËP4Ù`žX(‹Ä”„tNSck]9ÝüÒ l|•Ê-³xoþo ä±éd~äÊOîk”’ë÷Þªñã®V³ÓxW³”ƒtØâ“øt‘¹²")ÓE´†é\uûUä`Ã[—´þc»“œBýª“µ©T® íîBÚ´O“^k«Ð³oÍTÎdäCiyWÙKê¡j¾’ÛgelïÅÒT„ÏŠ·zšÓYJ—eÄÐ+·åå`û÷§hN”-_†¦o¬»Dæ8 + ¢Våékvª0öˆp¾¹$x¥)~<Çñ¥*emŠÐb®“啚ť òé»b’毭gáNÕ- kƒé%úéõT<ý `ƒ°çç‘-ÅEdJ7غœM³e\¾úf[KRŽmÙÇi“¦£C3í†QJy§Ï‡}ÌŠ°škŠÏ wñÁ ±p G9ɶi´kd` ôp_èw2à,¥Û”d/÷¡˜5ã­·&Èæÿ`L]ä·~}ô–k®/endstream endobj 345 0 obj 4518 endobj 351 0 obj <> stream xœíYKsÛ6¾ëWð¦&M€ ºÓCÎ4—§:,ÉvëaËuí_, P„Ä(MÝC3ž¡éÅbŸßîômRä4)àÇþžÌG‡'urµ¹äMU4ÉÕèvD5ObMæÉ«VñI–0*’öR1sÆ**•œ¦¨ÊB&¾á+Ф.’v>"oN^¾mÓöÑq;ú0*v銢D5ô#iR3%I‚¨SÂÒL®gí/vÍ‹ª`ưFV%§ÆÅŠ×´IÆi™×•—ô:äçTm.XE^¦Š¯‘”Iòkš•ŠX–œ´©{;N¹z£¼"'iÆd“”P0%O³Š©5Ê• ÆKìû ¸ ò*ÍP~ J­rõ.(#ïR÷ö:ÍhbjX·~²²Ú!xÎGce9¹€Ç÷ðx‚Ç 3%¬ r- Ò\’Cø[=+”;ÖÕ«‘·„Ç£•¾QJ¦v«’7F¢âfà"®‘xï‰wH{â$ääTïR[oˆOžs…Ä™5´¨É%—Eα¨N/þ“'.‘¸ðDïÜ·nÄ?=ç<°»Hl »¬Î)mš¤}?j_œê &Öp“@ÏO˜ŽXS«ø×ä 2.ܲQ9Ç-‹0åV‚†Á;dÖ ù}Àr/ûØ‘8‰m_m ;fMyÑКk—*¡‘h–ŽI#ÀZ¤³R U·KÚ©*¼uÌÁ h#¼”a€î;Q €k_AOfeÐ×-UÞ­g'輋½ürÞEƽSÃÉG‚ˆû˜ú*úÉ´ƒ•ùÊËB/ÐËªÇ ÝŒ –¡4Á{­%¬ÇŠ{Û)k`·v.Pƒ¯¾‚ûÈõ<äz˸ê¨G®³Õ½#R½ÿJj,s,•63ÈÙÆ/¹íx&J˜sU˜D›=cªg¦$n÷¨ 1»({gsÂt×Cé>ðãck¾¿/cýýÈ6‰bPÑ&®À¼†ï+ÝœŸÎ7‚©§]l¶ïNŒfˆYIN±~v·? ?ÇByæ…=í+d €ÑÙ3íôV?{úÚ§^ûÐ9Á‹ÀÙMLÒ8´‡œ%ËsÃ"ðòj£×¾LÕ/iØõ¤~ÀRÒiýfA'hjJþ+2ÿbIo¹vU!‡M籪8;HèïÙóHúFa+gïiÑžíÂd>4‘˜ui:R´²]Y/ÁØÇ>¨® ]½.ë#Éúƒvø¾g =îExê×ý%8Æ_Ä20Œ„~›‡¹2!´ƒ­ÇJC÷tÏàM^bÏè Ý8@±²iÇ µl†…EƒÍ÷™fìΰ~Áü(çH¼ùŽF½Î \øŽÆŽÆÎíéËgÉæp¼}>ìÓQw'Äôœoyo2ïMe;×>wÏØƒIöÕ“ÿÅP¶öé8ÿy¶÷ÍÖ3v=Ïš¸Âìu3;›<^ó—(×ۉ͠$oa¾d‘÷¸|s8¸øëÀ?9zÉÁý}ÿIàäØû=í„0öÙÀA×|¶Õqd›wÀ‹P‰Æ´»“ê \7ꈌðÚxf^Ë:Ÿ=wrñ Ìü«ø·»àÍb&¯c›|U]o)ÖÞÛšÌÅlßÖ4X.s‘æeO4[ÒÙÿ`½®oèýó…+ð$+E.ptª:cJ«€›«2s׉"«÷Ï».á/U%3¡MûuDZšÕ p/ác°2Qä5Ÿ†‘›_./aww5Hªw‚¥FPn¼4lÿ×q{AÑÿ°ú0úth»Çendstream endobj 352 0 obj 1368 endobj 356 0 obj <> stream xœíZYOG~ß_1Š"y{‡îžž‹KvŒ-'ä0Ù¼#»€‰YØìHÄþíé꫺gz®dyØ­©ª®óëšíG$¥úoØYÝ*££i‡¤¯ RGGq‡JžHÿ飗=ÁW±ˆÑ<ê fÎXA+¡§&EFª¨k?Ù{Œ¨$Qo؉_m½xÝKzu6zw2o<¢4%ajº*2N•Å/iYZÉ„ú ôoÇ4éæqšdêC®¾u 𥄔ñ‹¤ËJžšÇ¿Ã­·Iÿœt³ø7¸l ± ÁQ1ñ½âB}΄l?%´HëšqIy#þkI¥²×âcü«àÚZ%Öªà#,J)€+4‹{ :ªª+ƒÀ/ 7aáL}ÿ#!ÀFYÖ‘—IåŽfpb§÷£D¾¦.•Så¬HEdlt˜Šð­Î)S¢,+\Ù.Ï9u3áGV ÉœB€Îá²—¸œÙ¯¡—Tøø>±wέ­ÇVäÔW“ÂejhŠùÜÒ@ØÉÊ”2’E½ÍNoe[‰Oíå.C¸€)µÌ¶gENkát¯‹ŒÄO€|i­¹°+%Ú‰u©Nй@·žI}r½% ç©%ž!qh‰ëhî±%ú¢9)W-Q|Ê3Q[¤GÁ±ýÐz‡,3I«¹tµu¿Ò„œK„ô@NŽmF6¹nbt°…O¼.Eµ4R”Å»~äVîÚL aÿûØ ŽÐÖ÷I0íŠï2”¢‹PŠBÞ뺵ê@¤ç†u@Ý”;!f¥)þC³ E£ûª±ÔÌŠfµ8í,Xx‘ÏÿFAi;=4¶Ä5ôo8äÙ]´UÔ{ž”[‘OB³ @ð€ó¨+¶‘<7øÉ…1£ô•ê’;޾AIÍ&#¦ÚäRÁyUµÒñÜÙ|¿ƒòWÑè£;(è1ª_Ř„J¼‹a–?„qÉ  V&d’›Í!2mÏÚšüúnt‰-÷¶ãÁn[P¬»¡`9ßqKvBZ× þ{Ôm E0.¼*ä8††FÍc›ŠÓ½ÓEhªÆ§Z£ðŽ(Ù3ËvèÕX ÄþÁÝUŸÁ·n@U²˜ÃsÑë­ãs³W ÏÍûG׫v­,_Uç¼B"уu'ŸÜ™ÍÉ¢?ƒn¤ ZªB½F”¿¨QþŠ þˆ¡'À¯–8ö焉pÈÕÆ³¹Û¬[EÄÞ¨Çyo¡ßúŠa˜&þðýê{FLöBñÅæž ñ­kŒ!þÈø$¤h#4.÷‘ˆâ£Pm‡\ƒäÂÓusÛè½çYT@º¦›ç0}Ùum‚½OãµxУªÝØà ê h8C°™“vhl²`²ç®'T Ì1Š–¯`·Œ]/ͦôTµÐÈ»§Ÿ¾VÔ=”£ v;Šzg­ŠîgËð!Tšh&áË&,ó a98Æ^áñX×( xjªiàW꙯aíôB‚S¡ªëÜÒ'¡àa¾ÈøžÜÖÈÜ®消rýÚãr; lV@¤o°ùA>3ž¥EÕ^Ì—,Ïå9^ ~±c†¿ ”W¢}°qÚr!ØhæÆ“íM'Zühÿýîýºÿôs‡ÒGô{D¿«¢Ÿ6÷ý†Ö “Gô»1úB^.ƒbÞ ‚é_4.½°>؃0nÏân `>^Ü €9Gs×°mëO÷Àìoþw`ê—ÒÒ=hàÒ,\q0ÉŸÊæMVô6p '+—$Ð?âÒƒÂ%lŽã’÷—-÷Ęf‹b>$™™C9Š…~ÞnßÊÅ¥Æ!È\0BœSÍ`ßZ§’ÒâtQ'š_÷4c Æöwùv?¥žÄòÅ«– ¿¡c‘ÃÄì—Ç’·œVý­òc)+kƒòzÛâY¬KÖC—…ÄJÑpœ^JIßQ*¥ÀJ¥('(n $†dd¦†ño†¾ëü cuå›endstream endobj 357 0 obj 1751 endobj 361 0 obj <> stream xœ}P=O1 Ýó+<ÆC‚í|\2¶¥˜è‘ 1U¢Ò ÿ_¹»P¤äÉïùù9W Ï@ý¬ïy2ã—C¾Äš©ÂÅ\ ÏXŸóû¦º" œ }©8Šd.êS)*à6´qBA›Œ}wO Û·96s2ôߌ¤µªÜç,!Q§Ò­>¬ K6ëõÙ^×ö”I–`µäyY1Ç+lµÈÁùÏé€É>£6“d»CÕÕÂR캠ŢmxCGŒŠ8f;¢“R=±åţˢGõྤ»¾÷®&»G·ùßR6*N,öo耎s·:?ï9ÿÛÉüVYëendstream endobj 362 0 obj 252 endobj 366 0 obj <> stream xœ½ZYsÜÆN%oû+öHi¡¹¼é°ËJY±ä°*vÊIIL®¤%í(?$¿7Ý=ƒ™,°»”-—J$8˜³¯¿îÁûµäZà¿üûâzõð[¿~³[‰!˜èD\¿Y½_Iê³Î¿.®×Ï _Pk%íúì5t6J9`ž(œa½)OåbíÅúìzÕ=ýöÑ—gýÙ¿V_œ­^®Ä5"ŽœS×I›”k¯ÖN¨Á*œí»îIËí¬±ÝÛ~#´ÖÝ+|ŒÒxÕ½ÃGímÔÝm¿Qƒð2øîª‡Fiï>@cð0aèT/¥£rîïgÎ;0ƒ^âLÂúìëÕÙ¿ëÓ¤°Õ=ê¥Ôì²;Ãé¥5"â¶ä Œ²¾û Z£¬åßÀòN„¨ºçð@Úº{OJJ»g°Eô²û}¹ù…¨kˆ1¸4§¦û ´i­I§$ *‰t «3žâ¬× 4 ÂØ(»‹~c»íu¿1ýxÕËî.á½.òºWÝEæïÿºþ³·Ýø>и7ÐÏçió°‰`aQ5À~a®¿¢äÅsëö NËp¸È „4®ÛåÍÄXºíM·ÅÙ,mò ®‹]Æ=^öãè|T¹³²“òf0:‚É]‚™=iì,a©ü°Ã…·u_ïÐaI †4všS€ ƒ§`Zíaš‘Â1Nˆ%Îv€ÇºÂeHàžÎŒg `FÒ–³ixáàÕ‰;ŸzE²ô²Åk~¶zøìùúöÃÝÕêáßÖrõð+üñøÅøõìéúw«/ž­_.ß÷µ0‘ïûLƒÁUðÚ oüÆ(p°˜TŒv±P©\ãœX¨ô ‚çþiQÉÀ‹éåÃÑx áer𳽜‰×ùš¢¹Òø:Ÿ»ÌbOwœfr–¸Å0v(¡kì81|mÃׇÂa4Uçc >2 Óè-KÑJãP/Kcc›JŽ1dï“0Iy:…‰#BÔkªQ$³á/pY³èc>² ì2AAžrœ’úT|\Ž6Ž›F•¦Ûj+ŒpZÀB­*œHd*‡î˜çŒšcÓ0$DS– †ç£¤%/ÃâXQ³ Ü®)äÿ· ‰8á‚ÿ–Xw›`1«TÎ6Åèù4ù¶­€Oì¢Ö¸6[ÛÁZ#o¿µ XaD“ÅýkIp¯@$•âüÔn«Y3``(Ã>lÞO 1¯Z<ë¥=~㊷\CûÑÁ5¤kLà†r/bxJùd†ΗOvŸ’<•ìh1y‚ 3&TvlŽ-òÃý3´IòÊOWiãi«ÿZ"pfºÉ1ÇkSÛù_È_®þåX“3endstream endobj 367 0 obj 3266 endobj 371 0 obj <> stream xœÝ[ÛnÇ â·ýŠ}œ ¼£¾_$€%S)¶&1`6)R¤,’K‘”mýˆ¿7UÕ÷Ù™åÅ’†V£žîêêîªS§jÚo—làK†ÿÅ¿_ž-¼°Ë㫜ò†ùåñâí‚SŸeüëåÙòáôsb)¸^ÎJÃÈñÌHæ–«ü”ß Æ––-÷ÎÝç/>{¼×ï}¿ØÙ[<_°mshhQžã>ìôª{ѯ„óðo”ú•á¤ëîa¿ª%à 5Œ–RÁT ^k.`*‚ób£î¾€?Ï  ;“fÆ!»ðæiŸ^ PX&(Bw³Ð/h%ŠÙî +lŒw¸1^k1ÚIcí Êfò[e®F ÌYm;ZµÐu+ôõ^ Îá¶xPÆ+ݽGmœµ¼»ÀA‚K&»#P›){ñTÒAÇx²ÎX3ùö €´°¨× ÐYåuwýàÁÊîv6ZH+…†m¶6¼× $žÂ¨(eQ§G±&Ááø<>]ìýékÚàWx öÎv×pÂ'=*¿ÖÃÑ­Oû•êègý#ØÅ뵂ã0úƒ¬Ï°…~ö¡½?„÷ڣ݅Ñi Ú’2i l½BIœ¬%ü3õ)Oï²5Ùéŧ8 D$å«nçaŽñ 4`Të°¼ÓF#ÍÆ4[¦å ÀpöÁX^ÑrË |‰Âñí~Öõ:µ_åSg"=«KSŒ¶d}žà=®GÓzÞ_w=*êÐiœdï¿yS5”=üs´²Y÷Jx1(µ\qÐ/¨†Kƒéáç ÖøsÛ4ódC«Ü§„±ÞËЈ»#80Ù\N?CÞ²Cüg;ÍÔ–XɽOf xìV*E3~’Œñ8Ãäh} ¦ÚöFïÉIAw‡¾ds‡c‘2¬ë5¸±®»DYd‡Ðé4õ¦ƒˆV .  ÅU—<+˜*,ÂSówû~îó¹ê0Ì•„EünM?w?àY(º“þ€«ì)IíפÄãäÎCû{çQv¨öìvî“”¾Îê£À£ñ~Æ<¿8Iåû屆•(«öœAƆ{zX„¹4Z‚ȆU¿Z“Û­¤FHæàfrÐÂq t*ˆ¿éÏú2Ù'O0Ix>èCd“þÆn«¹* ¯l+ŸÖäÎò&ÞÜJÛ²•÷ÒÙ ¬š±Rô¨…›À±‹®2ú‹¨ä- E’Àƒ£é!+ <É*V¸˜HÑ+’áSÈõ!p%"#ŒËÈŽS਒cö» ,­¾¸Å˜9]Ýp1’ýäÒðì4A†"¡q]¹xnJãUnl¬£’Ù8OCËá<%á^ˆåw¡ã²Ðñ¿a«1«ëBŸKÛ%²gmrãÑ žf"U!êòYîÍLo(uÁ,Ñç`H½Èy†"%¬þ)ÑbHÆ|÷¸§³Bµ·M'4“Áµ ¤·àëÑQúÖDGRˆÎ*Öº9% Ñ<(à¼ÁŸoñç$™LèLýNg˜&w´Öþ¤T èOáÙ"»/†¤29R áØ¥x¥t`#Uï*òT¢ëä3½þ'Ž×´aˆuÈ¢]5 ¢g 1PBQ\ȹOÒÈòµ'‰“•ùª|ö)j† 2IšªY úàn¤hŒyvAÀËðüaM™Þ™ªÃúªßœ›PrÖÀõkX]¿B­aqEÜ:q&¨ ý¦Ã.)…$ëYcÞ8Ð Š²t>ûA*žÅAèöãM£‰ªu|ÓW'8ÊãÞHŒÓ<ìšÄ3‘E;´(T*'¦…€úƒs‘"‘õ*5Íz•’ÔmÝ›Ý@*ÍÍ(7N!¯‰Ø¸ùR74ÉY£½9W›ÊˆV……l!.HÎâlügê×dеñä@›zâ^@¾‡‹¯ÎgÖ`§xÅ*.¤e²™^ÐŽ£ØÛ¥”ƒ¡Š ÈtKqÖ¸%è ϱ(÷pwñ`÷ÙòúòÝÑâÁ–|ñà þ<üòüµûùò‹ÝåóÙ*Z«[ªýx6pdO¸V.B(ÓÇ–9"¿# > ç‡)ÜÖÁ¾› ëšì=°Ûœb©lÓ’Ìñº€šÍ îÎ*'¼wJÃ?Ê+g(}iYÆ]Âá iÈ_IôMb¿½‹ØMUNªL!7žåÆÓÜøÙŠú°Éô`=–A°ÚT­hœRb{>K›VÉ´ 휨zfâS=­ð-ãÌ4còìõ”¹q²g©Œ5ÊÂÊÛc<*'1[.µÞNÕ™Œ%¸ýŠhøËè×O©­TbÈM&é— 7A¿¤ a‚êô¬çè—Ô\&;°ƒ´à­,‰Ÿ¡`Ò2qw &‰AÉ Z!ýše^Ò2J#·2¯°RSê,™"Ÿc^tô±÷g^A‚@‚…|ˆH„ÅH$L¥ø¹xa ¾)¹»X° Ä Ïÿ¬J1YÂP M4ª­,ц×ë«Ï®Zz"zR'"_¨†Ri³á›xžŒ ´åyÂÚ–“oåyD³¸ÀO_UœÆ/VN¾ô }I4©²¡šµnÖ´„õdx™& sL°ªÝÄ'7@œUo_()†•Ó‰ÌÇO+ôç]>úT¡o(²>±ä1³¥]Ã1 ˜2ÒvžÇ‘J€‘KÙšøxDkð,ÓH¤¤›<ïCQh' :=62…9 Sš ØÉdÒåâ„Ú‰¯I%£;ÛÛÐj²*c«[S-ÝIT“~¤Ë×jʃ)ÿœôrWϘ’˜úSÚ¬kׯ2º3Ä›;UiݹҰý‚S]ÿ>ÎJ½¤ã#ô+“^f_IÀ ’œÞÔ#‚¹«nÏ‘—¥*‘—ÄØûQõ¥FÔ üËfÒà#¼!’JïÙ4Y•b¼Èß¶‘3N÷ è:[æÁaažß³PIå'×êqD¤"¥Àí6£"e‹£ú7¥‚â/bl’+&( jÊ–4/ö±ðùÿ†ŸR½å´q§ZÇYz¡Wñ™S¸/G×Þ4Ã1ûAnöIY| Ñ&¦ãðô Z……Ì,9÷›®]<] E[e ùx=ýç±låUºí†WD§îBL”Æ‹u"ºÓ™ª|Òᇖp¥ì;}O+[–S¯t¼â5®¯“³ñjÎÙK¼©”N-w*¥þ`¤–á56‹ 9Ybƒ¹øŠæº¢á9¿Ž®Pîz¤Ëhá@Tóå?Í+i㟠·«‡×`+0<Œž7.:’à´õÿ«p0]‹ÕpNŠ}«n÷®¦ôýáùâÑyŽgendstream endobj 372 0 obj 3419 endobj 376 0 obj <> stream xœíZKoÇ’Å|˜ 2£éw·s¢e9r`[°´€r ð-F$W")'ü÷®ª~Ïö.wMå 4ìíéGuuU}_WϧÅ4²Å„ÿÂß“ëƒg¯Íââî`­tzr‹‹ƒOŒÚ,Ÿ“ëÅ7Khgù‚3µXžCcɹfÆq““] ©”ÞñiZ˜i±¼>è¾}}øÝ²_þëàÅòàçƒiÛjÁØ8é‰ûyœÕB2/±–†¹Eª3†·8þÛŽ÷ƒêÆ^Ä ™'¦º%Ô½ìaĉI×½èn9ü0Ýó^u¯àÿý ðÁGç¬ÕÝaϺŸàg÷mÿÏå?@"§AFXœc(‘W[0;åÙ{!a6)`:Ù½ÁÞÏûÑÂËʃ©GÔÔbyewý AÅx˜Õ¢œR¤‡A*‰=1 —:²‘i$®–e2±VqUÖ²~pNŽÖ²îïX«5s¼;ëá½tÜv7P2ÒQÔÝö°«Ê+»#P¡£™îA_£Žu—½-ôQEç x;q˜^ƒ®Åh¬a²ûOÏŠa‹±Oz9rYuŸQ®&Ð^;Ïw ­æ‚wWÐÖ"‚ˆjÝjM[mZZæ|TdG?,ÿò–,á}n\wÞónuý;z¬þÝãŠp-ðëíd!agV×XCÊ¿?…÷Ê¡!úÞ©ã „¶¦»¿â<° gèõ9Iï¨(%™ý¦¹>£  UøÁh*=A¥†ÕƱs;êFj›äÒ9êÒw{Uû9¯² ´‚‡ž F B¹5£ A YáGOKDÓˆ#¡RîÉW8ãѬƒ<^Q`kAy ûJ$_(%¾O :ê'¬c`FÇÅ:pc•?ÔÝŸzÞÕoB±åÒ΂[L2Ê}”§ûXZ¡ÂÓ•˜% ¥¦õ •ùQ»¯1ø={ÍE5ó ™F—\€àà Ð:Jà}Õ'PôP“…éZ’ ücL¶pŠ?«Îjr››ß­5Í…€‡EzÑ“‰Ñÿlh«hâ¸Ã٣Т8FE²(ËIvlŠNˆÍÑ6œ `¼·£[® ¼VÕˆ,Øë§´U…aÃß0:'qÓJ¨÷Áå˜_Ú Å×Qt¯»D¢k=J „››à&n4ºr“¯ÖÌí#4EóàMÛ -ýê`·I›Cx£øD8³€w[ ÆÛy ¸ú) vZæ{¯²NW©rÌ•§©ò¨ôâÂüÐ<‡r³ãÿF» ¸6 Îâ¾ÿúkêo‡øzâ¢À?µº¨säD´%ßç-ù âc‰7iþ—øóU 8ÙOÔø®Ýãš^åâéý‹TzV)7CÓºò®såDz{(¸’1ÛË\y*Ñ™´"È;ûCÞÙ¯Råaî¾L•oråËTùä¥ÓæsèÃæ×ZˆÅb¨«2^QQ @;XžQ Ï+åΊØö]刬KUƶw%äÕnÁÕ‘É4$;Ê#ÜW>±‚k„<ÂÔÆ÷ž C—-n¦`HÖ-‘|T‰Å&v!jrUp êzã?óÏHR@ߦ)£v²²él2=êõ‰~©‚l¨¼ª‚ðæÙu—³G.åtëÒ9úÇšDç-ú®P*\SeÕ}áZ¥Êt2UÈ“à¦5ùY.Þn…$Æì˜VcÆ?0÷ õT¶e`Ê(qÚ¯rUá£ämEÖŽ¦e4{Àøh‰²sÝÑ`TëÃS˜0ðGx#gô#Õê¦À¸&±XÀ,·.{㶃 `Ç'×¶ENÞ=x³å3^¼éÜS5ú%EЫҽ¨ÍÜnÿ÷Ì>O)µ$Æñ¥mûœˆþBLj%Xš´™õ#€•RFüÞ'ÿÉsþsÙ;po'¸™À׆¡¦ÙÈмfŽò=”ŒÕF7ß~@FÈ)Q K\84ØiW6Æ¿W“ÑEZ3‰³!›)”Ö³™Âº`›þ%!X`済ìÞ¿Nú yŸ ”ž<£”4rþ!YÅÇ@ǃ7¿¯~ú&¶jm|ˆ…Œpž..Ÿ„ÅXž™»UÄHRX; É«DÃqB8—2V{V$j–LUÊ0)ˆCêys2Œî%0õ?éî»^ã‰öŸk-qÀ‹M¾J~flj$Lë´œðGÙ½&ñÖRjö’x(ŽZ¶¨õÞ™ó/Ū£]ǘ¿G ô1âÝ>HïKŸc²Òú”{HV OX·$()`–Ò’Fµ`<#¾¶Ä[J<߬bˆzƒ–7§çªÎÞ_'8 ­/Ó–µT½ûIÅçðl·C ÇZ€YŒ™³GÌcêÃ~Ù|gi5¾® >‰¨þ}Mdd{ŽÎ)Q'+º5‚ܹ0:bŸÊ«»Œ>Û¯øVéé#h^èu<#¼{:žÔ;à÷7¡%êÄ`ÐÆ³i4»á™uÏN¢&öœâ22I¿5¹RMèz+tq]A—˜v„.!Ëü1°ø«Yz)^Û`¸Â_M¶ K"À*ÈÒÌëŽs:}iÈ¢”Ó!Kˆ'AÈWõèâDL™eÎË–‰¨ÁÛ„s•‰yù„oë fØÐæ7ÿ´]m“ŠŸviÖ¸6m_š%\;£µ*+ôÙ÷µ?V¦Ì£Þã¶mWˆ{ô¶íq¤Þvl¼ÎÇÆËÙD ´·ßŽÔ°½ëíÈ#'Sñ‡¾Ì‘¿¿ÁH%4ož#3>ßå÷ZËò6Sç"ùŠ×„õG3^ÄfÓ¥¯&>ø.rßendstream endobj 377 0 obj 2590 endobj 381 0 obj <> stream xœ½ZɎǬÛ|E|¨2ÔåÊ=S€¤(J4hÓ¢ú&g§1ÃM“’¨ïà;"r‹¬®ê™!iCà¨:+3r‰í½Èúe5b5âéÿ'×G}éV»£qð:Ø1¬.Ž~9Ôg•þwr½z¼~^®¤0«Í9tÖRZáAN­ýj]žÊ;9Ž+7®6×GÝ“—žnúÍ޾Ýýp4šÃ@ ˆ 牋+'A’GQ?uª_›n„?ÿÚü- ÃhG¼UZÄ-ZíDX•6eÕ }•ôMo†q^uß÷Ð)x!}÷¨Ý?ûµÂ7¢ÛôéáÛ^w/ûµô~›Nâ"†~m…é¦{ܯ¹Ü´ÆÑJi˜JÃk#$LBp^l4Ý ø÷whÂÁÞæ™qÈ3xó¼Ï/P(lT¡ÏŠÐ´=ºî +Lðx0Á99IëÜ ÓÀ>Ä œvw#‡Ñ;ãr«‘†·š~‚¼ÝwØj­²{ÕÃ$$àÏÀ8í­èŽaipè°Èúþ¥ŽVÕÁø'é,ÂZz}·-c®`Û0¥Rìé žFà|O ŸTN«î-ž–ÒAt¯áP¼ÓÁ$)RÉî Œp樆R-K 0…ŸmþòêOtïaU Õ¨ºSP7,Rwç=m±{SÁj å-¼ú{zêI½~Ç·ôt‚†ñ®*{ãøcK]vðLè{RÛòê¶ÄAoó*N¡]²©ã÷}Ò¯m<Å€ó­6§ ÖWÅ€ßfÞ¥ÕIü#pfFǃI’؊خ`Å:¢Ö~ëñô ­õ2O¶mN€Î ûâ–“Çáö˜ìãWÕóÁHô­ŽtKçW‘qNœ{[Öc»Ÿ;2³QZ°Ò"]íç¾¼A«–ŽÎÝì~꽊„ãµ%¥&Oc­'ø½®UszÏ6B:OÍLBÔ?þÀsTÐÛ†À;°ÇÓ>½GU­øŒ±«µ€8¦À¿ICx[#ÀŸ„îŽÏðY`Ì[21µo\A‘‚’Ó{£ÉÆi y.xŒ.Ò*~­¤…fÙ:IÀxyL3awZÉŠ¤]Îò¶12~"¸N5B‹P¤pòB%lky´{I›ù¢ŽÇý\””!Uã:Ò[æ:ëâ:OêRþ]ÕÆMiüq®çwåé›úºžÓx­üœG:9Ð|^à.›DÚ4Ú'÷·«jSxb6ÀЪU„î¦jˆvc 3FÉLµ;ø‘V&0ÝÓ²kðÑ·U*Y­2~d´†²4n¢X®×%F¾)Ž}–Ô+,6y³/Ú5e¶¿aÏ(®±‰þ™há&½âvX­KÚ X„ºghÞ%Ù`ú»r.ïŠîiM—¸tI}Òš¤ röàZ(9¤„ðI ‘Æ‘«¿¡L€–ºFþ¢Üë²ö&ŠL3‡ ”òðs:Âz4Û¢õ9Ëç–%Wt_!ÀÛó.R¿€(%Ó?&(Š0x~ wLÌ“*:!úŸ"B¯)x ~þX^ Q˜¡.å­Žb ‰-9’ž§ßù´ñ•4ãy™¢}Ÿ‡ÚxZ_5IŽåÙÓÝýeîf6œ«Ád‘ Àn›ÌÌlÓÑÑx¸[A¯/²Ã,†Iˆ’’ƒ‡ªˆEÀÚ‘Àå :184œÿ²qΠ–sÑíºCH ƒQ†ªs%nþ×ËŠi0f:ž`bX˜Eaü( Ñ\=l X»º ¨,¶ÙXì—Íž…k4CLv£¬Ð`?¼³Ö&è•ÀRæ`ÄãÿœjÞa fJu% ³«5bùqÂtle:O@sJ9ïÅàDç0-©d$Q^3Au0z8`B/1hŒƒtÆzΈn#`r€}žörL2Lp CФÊJŠƒPNÙ4‡—vŸ©ábêª/áÉy»L—\p9ÈÍÁƒÐ–Ð&ï¥v[HÒ³qĨý8ò¬ áT©¹¥(˜ÁoL:@‡(ëLüP†A¦”mTë~rÁñ™rlA RFôA®´mb("¦ûÎgÏ›2aw>kàÓLέÑð~Û¿àh$;‵À$ Γ–øUaÊÁ :í~Þç kž‰Ë‘Aó€ß.ß‚E3 ù´0ªè<UÐ-ˆ²`—PÛL˺M('gÿü^f|d‰¹Ôc.¨#ÔÀ)¡õÀƒíe¿Õ#ÀVÐuаO7¾mKdÔ–§Óþ3¾Ie«@&ô>Ó}*L*Õ}[­šk5*²ƒ=6 ’=³ì'ä#J$„"r &í<íc$çÝä7ï{gKD‹¥•†ñÅ,Þ¶âòb?bÊ× „CÐÎfVx±jÇHDÃìÓ{9IÐèW!2æHµÙÃì¶PbÍX~€íFú^Xu†Ql¡ú2²wnp´ÛÖÞÐ&ÐæN9€òÑVvvîS7AYã«ù à6V:bÞ¹mXÈ%ô±ÒëëTÕ¸áÈ;ÉÆjF'*ŽoÅÎ×(Ü‘ð=[o8œªA­4^–Fù¿af Ÿ•éf%dQq B³ÔÙ„VÚ?îEÖ–Äó5™_Â+ÑÜT)Úçä)¤¬ÙIÞxUsñ“ÊåI [ú4|Ü´%Ï%šì™C ÒžÊ7´ÑWW)óñìa¤êeú i›8tS´ÀØõ]›×Ÿ•«ƒ‰nOw2VÄüì\ ð÷º{Ô}JìÐV*Ë¿Wî Œ–ÈqJ$ÊØ# KÑ}ÍSÑ|sVÐu¯ýØ;‰erñß¼(¾.}þ”øG%‰ÞÎH䔂¦ÕXoÙ¿z|Y¿®¿—Æ÷µñ<û¬DâáääÉgXh¹ÍÑ E˜¨¡R»G“ÝÍ'3Ý:ËÓU¥ñßÂÇ!ú{ÐÇ„?BÚš•®š2]ó6~R”½s‚¬[OŠÕIº¸,Qo/é%úTêÆºšßF4þÏðÿYƧõD·¨_ïû÷ <¶©Wé*dz‰z; “è‡ ·1n¡.>J™ z¾¡‰øm‡Ò’*”K‘#î ŽñCmeWïÿȧŠ% ÂÞuOÎPÛüÇÛ6ÿʾcýYDÃBVüŠá˨ bl6Ö”fÀdí ,äGJIçÀ€àMú˜£ùJiRÚ#¥KUꜵŸ0ézpþv ´=£©·²T.¤æò­‚äÙ¥E‹;]É¿Fð‚l`SXec²2‰:$ì“ÆdcíULÒ/Yñ/Y+$%Ü`"†ÅšÒD¦!˜ñçK i(cloæ¨K&•3ùõ*™D|G´%Cš+Ì” é#½_2ÔaðÝ~ÔÞ¼ŠÂC=«)îöŠÚø èèΛïD#g)f*O¤˜œß®?$ñ4I5W—¿tJë-èt—¸›‹tþ†þÅÆa/ë½,¡œqi‡i|Ü,Ÿˆ¾¡ù$ì5ÅCÀÔÇIbÍñ ¬(<¸ºàš™ë«o™$ëHÿpô_RŸ’­endstream endobj 382 0 obj 3079 endobj 386 0 obj <> stream xœµZYoÇä7þŠò2cy'}ò 81à€–e›@ì<ð”‘\Y¤,ñß§ªº«™Y±«Ý>«ëøêèþu#&¹ø/ÿzuðçüæõ͘‚‰NÄÍëƒ_$ÙäÿN¯6;‚qAm”´›£ l”r2À:Q8-Âf[¾•>%ÄÆ‹ÍÑÕÁð÷^|}4ý÷àG߈{öˆ8orN9Ü')7^mœP“U¸ÚOÃW#l´³Æ¿Œ[9É µŽñk”Æ«á-~ÕÞF=ÜŽ[5 /ƒÎGh”Öùá4 †AbR:*çþ}ôÏL™|ð)0q ›£Ãƒ£Ï¾…éx„;I¡”NᛵQ\¸ ÓŒv°fˆ:=ÜÀ'œÉ« 'VEZÝêÉðêG£†Ãh rkp1ú¦­bp¸am3†ÚnG3|q³­vŠšÞüg´Ã5.p78?NB„awßÅp…}¸Øé¸µÄ…)Æ3w8Øxø¥†¼ˆ¶Žæ¾%’,ÈÃÄéN Ôó]Þ&Hãå 9¹ù,$5íQès(Qéñ›¶—H#ö¿9¯D Íó•pkCl¾a‡x†´Ã.u0Åçu22Òš¼ëˆFi¯'JwtŠÖQ†Ã²Ú7#ÌV*ä}5üê]:C^–O¿¿@q ø¡ôÜXéܽ¯By\.]HÝ6‘·•µ.$*3’æÜ¡fwJÓp@¹Tà=êÒiZ~«À`nÆÄsê} I ¬‹Ê' ÜàWIZG]—ùCùXûAWb¬c°ýM]ÈSo'´,[X/š#‹MÊFt·|j„ˆ“Ëf¹3ãÅ-™É[„ p¢•x¢uRIÚºÔ>>æ£Uâ \ Çš™LxÑ8rŒÖ|;âÚA85ý§uÕª7Hîo<Ëñ ÞR+Òà©U&Â:i&mœB4Ú2/@á'+cL,Ñ@X0V:2xàì Ç-ÐVŸÔ„µÃIQ ÑÃþÐè‘D˜î-0ô žK«"éb´“‡qßâ¢Îh \“Ú;„UXÈ¡²KMÞ+éb­AÅ@v9t\ÃUôƒÃ`hý×ñøž¶ @5¸²€›¤-(müº»ÊJ ¤EqJÅ.PÙ UÚáKÒ¸,v;$%¾[õlÄ+g%º‚KÊ=×`ƒcY;] ˆÃæ»·¹&' U$îÆFnƆ쬼èT04t/#/®’©H”[ÊqÕÒ5gÂ{ƒ h3AîhmØ™´0§b¿K0GrÄ ©´!!^ŒjØUŽï>TDOÚ͌ʮRiIΑxA„_2J½+c¹àZä"ˆkÒá'“-sÐ" C2г±ñ‹&MåÕŸAxÇ6q!ó¢4IÁ„f­†ë89]`ë%Ã8ïµÎ£­ÙÒz GƒY;°O`èäH;M’°`’^ M<¸™nôï%` ùò¤›‘§žD^2à k®*!jkh¹e)ý’<”°@l8®¬?¡€F4Ž…{ÚÁ CŠ‚L4™â… äw0òU¬Nn&~Ä9ŽönG}€ðI³é£R±Æ )ÛŸîç#_"¾Ç™Ô¶qô‘Qk…¼ïžpƒÝv.Útg€–º~\795žÛ°õW,¶˜||ß_ëIP’°·€?f´«¾Á@êC…±§©uø½j=·:¯Z?GmRªd'3‚ð+:ê?’ Ž[&ìf”XFÍc™ÆÕ½åð4Y€á`¥ï¾Ì& Û·Û‚eÄI#¥@³:íû'T3Nƒ†‹¤mðqÛ¬„º/ñ7„(†6)ñ·À…¦ý_òð%+‹§1+;XÚ!u+ÞÆ4¸·–”Ú<§þ¾¯ Âfæì’Déä%#I! ²ÿvÙ:0Ïʱ6%†Qc^§Ê·y'I9P )&§¥Ž9ü©‘ íºðpÅ­æÆYð=÷®LÌq>ZќټY6ÉäI;ÏXgΘb@y­ŠåÖ`» «w}àÈ2œ;c°²?yhìfq9ð‰–¸ªþ¡¡˜Œ6SÒgÔ¤LÂa£‡KÓ0«±‹öØYQ²(ÿ–€X2R§IÿŠ*-¨en^ŸW'{¼^wE$vv—êQ.@"±ålô~åDÈsB·LpŸ±ï˜QâOÃÞˆ¦Ò0‹h4°eÿÏF•¤š<,+ž™œœprÛV}À]HKnƒ£ÞáJèÂýþ³†ªõ‘¦~Q×D#ü…êznšI}:Wj󔧸Ó8I’Á'#jÕBxÔqiî =èwˆ éF .WÒ?,æ¨@rQ‹& œ¥”}•å]ÊZÇX½æ”ëŠ]gA95Цàpî©h¹®|Rƒá}bݳ"ÎVNN9LJj¿èİ& L_Š“ ˆó^}òjœÂcõÙëKLvœì+Óydˆs2‰lÄÔ\•BW"Éþí)N(¡hX™å(,ªn:9)U+9¥@vÁ_è¬dФs¨RrYi½±…˜œùCíhØØÿHж˜)‡ßGÍÓ’Ñ{ìg‘h€„i‹%÷6è–ÓOlÙ%<{ìfƤ™UHr(í)¥­zLªeU]¹þù¡†=5ŠÊÆAPƒd¬Äc*ð$3Qô·šÄ¶­}¸æx[íä±èÙ™ë;^¬ ò-L]6W˜UBï¤ðÜE)CýIî©ww¥3V\LkbؾÐÝ¥ˆj×Ì?kç¯Ý=œtfæ76}ƒ”…Âõ\”¦K–ÅU¦ò¥Ó åiò³1ëB’ñãã~ÇAÿÓ²jUÃþyð|™!hʰs"±Ü¨?'”׽ȣ'›_M¬eiu’*æþ4»O|¾É7$¿œ­Kß÷ÔŠóZÎ]a´©B{W.Ø¡ñYHÞ¹O¾ÙÄ?Œí…Áù=In‡øû»òñ {"QÕB=ëOÜ{•ÅJƒ¤‰•¼õô®Q¨î>‰5zM}a¡ºx™.ªR92rº'Bíá»X‘î+úRú*eVƒ@©,J6®… ’Ô®ŸÂw0o§Yü‰†®Ö‘ÊXù‚-]óEMÐÞÀ6ß+Áñ‰ø9/.PWϹ%RIÃ51Vƒ¸7Zï®ó¾Ò¬[SõhÁŒ8 ísÆ·A=œÕ¡ÃNÎgañ=¨½^ëX­BWoƒê–*× HÓ‰{,e§Ì FÛh þÌ—0«×/Õq8èd—ꩤ‡øTDš`L²­ñ-IóõÝe:V“ÈvdSÆà¸&HR—'ÅŒY¿ùç”}þê­.°BÚt©[J©«—ºª^ꢓuÑï!æ Äücº–N!ŒkL°úI·¾¤EpºÿãÖ78¾õõvƒ 2u>ú{Ô­Ë{’Òf4!LsKhLº@%ˆ¦qW9D’i0ÆF§ÄèvABÜ«„Ù_¡â= º±Í×Çë(Y2¢-øýp¾Ä))¬»i¬7Ãø®Ëøaµ”Ö®pÅìñ+ŒF<Êp×$ù¯±Ï䚃š/È£¦YDT2‘z¼ ]—d¤Úû­þȲæp·þŽ¢b ¢ Hø’Èë3µ8 áP¹…"¥PS—„½¿Ã®¦¦xè³qÛfò8ã„3x ‰8×Ägïž´#X^Ëý·1½O¨·0øI‡=2ç­–‰ÿÝêM+§ªxOé9iÙqß­¦ŠßÙÕ‰>h_¹Oe¤Cœä‰îåÊÓ;c ÖÜ …²£o¼Í70\ãö÷q 0Ï·ØWóoöh¾>Ò¤ç^” Óê½ls»z“›SrqÉQTm¨Ý'8ï„ù©ðü<Ýî–„v·òšá¬îÄ5¤(–É(?ÒrM»}˜rË‘š«e,6¹\‡:o±’vAävÏvNkËUU¯¨ z™•2UzÄ£8“ÁÆó®Q×Õ«z´qåÀ·­cÜ.c¶¦¼Š –²<ñIøwÍ™"IªË8Ë’FR‚òxÅË^hf9=øÀ&:M}•ªSB¤ÿéB€Fòez üýÁÿd´Œ> stream xœÍ[Û’5Ý౿¢ö¡ ÜåÒ¥J*"öÁ°x0±@°s5Æ3Óž‹ÁÃßì—ì¯mfJJ¥ªU=<áˆq·J%¥R™'O¦ÔË®UËÿÅÿÏO_¸åË«E×z;ݸ|¹¸X(곌ÿž-?Ùƒ~^/µê—{'ÐÙj=(ãŒÝ`:¿\ó'~¦»néºåÞÙbõÏÏ>ßkö~Y|¶·øvÑ횣‡jT8OR-†‘<õýÊ4ë~¥áÏ{ÿŠ/¨¶:ý`¬ K¬Sã’Û¬v-ŒÂ#}Úô«/x¹ÓÃêYýF¯´_}Ó¬ 4cW{MúôYcᓲÃêE³Ö~l;Di›õ 4Ìѯ¾‚'8ˆ/†Ãi^ä!¿nzød;·ú..b šBa—k£Ze{³Ü;ñþÎk‡šR´éZxip®ÕqEÏR*k@ð$.Ì¢a™,Ù×AQ¥`Uk»z„ƒ¯oš5‹}ÙèÕ1.ðômê}„_©-¿rÖ¨Õ~ýgÃW78r~á¤ñ¨#X›F»‚QF1Àõöã¼ÑY kÕ{\ýZ›Ö}==Ÿƒ\B¬6—ð$°(€™ÖzÑ` ‹â™ÎÑ®½Å~W¡Ÿ;˜Ó­¾l ‡[ö½Ö§8Ê+h{}'~gظ*8ÄŽ—y›+´M/ PJÃæ(\Œµ×¤nß…¡P*’òÌžØQ|¢4> ŽþÚ¬Uh&¡neÂOp†æÀ¾?']&‰U[¬ 9_NÇÅœå¡7¸F -¸wP6¾†7ŽcÒÎ áV¿åñuŸxï…Â/(kœnƒïÐÖ¯>#½°7·ƒ½J›³Ü!ít8Îò¿ËŽ·Ÿ\]¼´¦•­ÃÒÖÊ´= ®uVp;JÛ©Ý85‘€ `±‹ »´9åüT®ØÕÛÎë‹´YoÅî\'ó]S§ éúL:ŽZ­iPêŠ_“‘l¨9y[`9ö=¥Ñm¯Æq¹÷åbïCV€g¾"tÞõ‘[{ÝËVÕ¬AüÖ{… ×µæƒŠGá¶Toɶº¶wÖ  hõƒ6šô9ö­ÐELëƒfGß׃v× ô9ZñÎ9¸ ôs5h:b­>ozOmµè§ì=8àÊoLßWaD«ÖÐJT¸(Jfô@[¹Žë·Ü|(O>—<\㦠ù™ý;€Zºîéñ B#5¢jCóи8Áyl?½bŸÀ Ä–³]Þ  #aÝÁqz1"EØü«h G<Ca”ï8¢´Q”ˆöi!bÆ B8à~!Éú:™v|á(­<ô¤!ïBM ¿ˆpÀvÑJpI LŠîKE$Ô8¦¡‚&’®ÓXb~Jc¹ À©¤Ån$ô¯fÈa¬ ÀAb—Àñ2i)Á4@/mÅ&‚iÄ©èÙˆPyS£ˆÒŸÁÍhoð3âMŠfÐé:Ÿ‡Ã×9 *{¸iàͶ ±â¡îoÅ4œt Á'õ«ó% ±£H¯D„NnÇŽp?¾rïÈJÌÐZŽA8ÜU bôéFKÈ‚ ˜=Œ4EدöQî!ë#X>ñôÚÑÃî) XˆÞ¦?¸Ú¼d‰ÅN 268fR䋵”§ŽbxH60Œù‰o½¡P¼/[-~T¬•° ¤q¿% ¥ÔÐ+$…ñÓä7)¥c@S.9VZÑ$ÉÊ^Ö"f߸>ؤýçÒÚ${ f5† ¤‚8Û“ПÓN^ʲz/£a è@cL\ÿ*çdo„¶!¨ëõ„¥g<Çj±;©BbÕ,cÓç¼¥Dd²“êBBg$àwBgc4KUAç$È­àK Ýì¿‚Åyz‘~Mó‹ÜEæPª´B5Ù—"ãòEÒ¼5¿@aÂo)=•*[ëv¾'Ó•°z´6ke|Np=GØZ¡ÒÂâR4Ë0¥€•'|œ˜ã„®o‚mÛéUöÓ©'õ0ñ¸’Î"m‚¾ÓJß~Lï»Iáebåewyem£?ç"YŽÐ¬¯L2_5 ¯‹=“‰†ÐÈiÞc,ó¡n ù± ‰ØFجH>êtõ&ª"0-hšØÔëòÊÞÊnh1—Õºi^S–¼BõõNÚF¾˜3æd!ˆå¹ˆEÐŽ[I•^,BHœ¸Z{Ãr>OB‚,G…ÎÄÔêwú»»ŽmLkD@>æjáÔÊo ·’¢N—YØ @zÍy¹, ®u7¶ ²Ü¥¸E_&ïä;VÉI[ç19£ÌˆÉ{,Ø2·çÀ²)cGå¸Vp |Ó%×MÒ̧‹Ò?nêìR’ºQðôÒ¬~jÄé‰!‡ee…§åÖ;2N$¥º#V^Gj—Vܲ7‚Í2yU¹ïnš‡tUTv+„µºk–«ìÝlÕ“ðÃä‰jþª`:¥‹üUuÆÅüµ×ŠóW:¼X‚? t¾Nã—Oû¥!=<W~ò|ñôùWËëË·Ç‹§ÿ^ªÅÓ/ðÏ'ß| ÿ=ÿçòo‹Ïž/¿=_œÊ—ÎÒÀ(˜ÿÒIÚJµGÝÆC³cgBx0f°¸·ªõÞša^t3P.üø¢[¬KÙ7,û¶š· à•¢ë-7qe8ÀÆ:tv>Îòñ䋳ü)Íö1¥F`j‹äƒ¿=¡Âqq¦ZÉ¿wT0ÞT9—èPÔè$Ù*'n¾–ƒí´‹¤x­mˆ¦áǾÕ'fRem!Ê@º™‹o¶µ€g 9ðÒ‚XµŸ æWE­¿u§*Ç\›¢|€I¡v\VÀ ÉàÀ¢øëYbÚŽÅ¢r½Ö‘¦¤î8]æŠ ÓÇ«Ø_™Z<&¡jé(ºfaØü~ë1õm¬(I#n#ò´ËÀŠtçýì.ãQÜ8-g“²½ŒÞø`–ÅÌPtë=e2œž‘V`Ô:£C¥iCD.éS®nëóOó-:w°vÂ$ÿ‹ÖƒoüÖ‰7BBËSÙŒEêDDzRoo wo=Ƨ‡Ç·H X,ZÑ#Æ7‰̃Ӽ¯‡'Þ†ðVC-„¿WˆëB1n’¹êØáÅ„¿0S}RmÝpëyYEÌôü(Œüà1Šø§*®Ý.áv݃ª³½-ÐûÉ®êl¬3ß±"ëÃM‚X‘­Á<Úd*Äjß'ùwbÃÕ¦¾,à ·bÃ!ŠÛUˆEqæîÍÝ[¡ÜqG‘5œ‘˒¤Ȋ·«n9‚Kšf]ÇÞQÉèµ?ÈÒÅ…C!J¼Bd{äß³G¸9+GÝšiд@ki_Ä5¢£øã×Jh$%/Ðâ½ÏÚ±Ä'PyÿÍ÷4Sª©¤õ&ó™\èpÙK ìÄö\`…¹fÁ¶”Ë]…ÀäÎnŸ7½~…4¶¬‹ˆ9Y‘á”þUTQ_ÞÞ£¢jÂíÏ9ã‹g‰w°«âi´üí“ÔÙÊkïB½`Z}íÇ6ÝŽ_‹ê+ÍßÉ”<ú†&n&aò dO½ŠE@gšuþ[/­­û!ܦ{Fã>h àµª&›U ¼(³BœŠ}J ¬mI7;ÇûXÕ€¼_Ökã #µ…+.¡†‚µÈü\&}oiwL‹¥Ée§JtŸïQétYîA[îtÙ‚›¥Wó­ŒÓz¿lD­>dÂ[¨ZÀ5ÀóùÏîn®iÿþ*UºÏ±ûËݬcqmfvøÚ| .‘¤œV“/ÎùY¤1!Y« éM˜íæjše‰Ô6 ,nèZ=½Ôö‡LŽˆ³°\gN7¶­å£CŒv)â2 Eì²j®@i:Òßv'š­ %«HfH†Ñ”W10Pf nÍ ðÖñjÜAäA$ ¸§žPè–óëô ‘Ó «ÏãYgŸ/lSĶ;Â\6²}aï#æ–ôس6jC¸§»˜·ƒè-–iéô…Ž/ù^H•·k—ÇÊ•&ºhT»÷Ò5­0]øÚQÀåÜo“êå'n½rƽº€‘e.¾ÏÙîeƒ?{p–X[´–ùÝúÁ‹¶XˆzÌÝÁ> stream xœµZÛrÇMé_±».c9÷‹Sy°,¥ÂIJ-U~ˆS6H”l‚ 2"ÿ>Ý=wpÁKb—ŠÀbv¦§§§ûôé]uläÃñûx=;ø`»³íŒNyÃ|w6»šqêÓůãu÷zýœè×Ýâ:+! w Ç3#™ëæù)¿Œu–u‹õ¬óáë¿.†Å¯³·‹Ùû{lÝq>2ÃD˜Ç;#e¹ïr› Þ¡üõr˜ë~d/ÂÃÜp92®ûo¡ípÐý?±ý‡Áé~M#cœSû?°ýí0N@£íß sÙ=ðþxùÚGï3ý÷QÆ¿Zâ‚=G-ƒ)y§…A¡V)øP CsCçJZXH7—l„Åøn±‚Ž Pò#üÀäŒÖ×ÿϪ¿ÿ šl®Q§Õ ÂÜ`Ûzr£G‚Xµ†ÅYã¬è—ƒ9gÒöǃFc( BRˆýé0磔†™©eI7ª$ö,ÿ5ºO™þºg³Ê­· k°î1®žV±…ž5 <Ú™5¾Z epáBÿZ(n te®/âIÞ«cåƒJ¨¨Eßh‘\Ш¨³dœ~n³É6Õt7II fIòë¤/x–bvHã¦)ÈK}òÚþ²¬¬‚úG-þ3ÌsR=š%&‹1[¸+–.JV Ž7Þ×3ž—AÕøí€Û,ÁKó¾ÞTFI:fÙùeð\eG¡º9–¦ð îF›ÈÉ_…õ´ÿhê>þÞœbÚo! “I‘-Lêœà¢¿BϼE“I©%¯üøzÐn4VÒ¢H*ÁÉU'åh(a©®ã€£p1 e"ƽ>œ¾ën®oOf?v|vð7üxýÃ7ðuø¦ûÓìía÷~/(í¨žâ3â4q"DütôÍÅTx @vŒ ÷GK^Ñko>ãÕEk"TÞ”<ÿ&Ø[¥±(f1«ÚŸÑ1È;P4¯bâ«!î’4µ’sÎí评•ô.èzŠ›L; ú€tÜtø}•ß,3|adô?ãG3Xy‡úŸzlø„_‘Ÿb/‰Ñ)ûŸ†,;1u M4'!GɲСëUéZkY¯sãIiü97®§Æï,'tøT:ýÑÖ9޾-¾ØcS4be¿bS²ä&›“~g^§Ÿ¡óùc`5ÁU¥qå`Õ^¬òûÍ”íŽJãù”íÚ½ vrÿ“Ðn½'l¬¶Væ÷cÄs£šj4EÒð(Ø‹„°r$Ë`Úº >*éÐW ²¶Î¡¸¦¯ü®¶X”1s)8 (E¦Ö)2CÎ΋ÈÀ@±NÉ8rÀfxVôŒ}Ÿ2<È]^ö—!ù¸áS>ÄŽ$î‚<·åýEÉH4´ÎÝ€^@1w Ï(#ÿ¹›LB˜¢kBò딆eº$™…œJ£SªK`:Âûz¾BXÂB‚¯Hܯè+ËIzpŸLg`!¢¯ÁEÉóÇ™QVé;“ŸØ ¢@Ú@|ŸÐýYâeqd5¨j½®½¶æ©ï—‰/9ša ´äu .F~y,£œ—lõCo"x&¸]4FíA}gšsȳÞ$³ÆrµeÞ„\Í,£É£;LflÓPíä£à ÏðOÇãJöù'ˆI¾I}õ´—ÚV8Œì$ýß“Àæ*·ƒ4ë”BÞYåsZPõ4¢Né K>òý]Êêu®~8®N{UVØÔY!>Ýçד{lçy =g‘#&z¾/Ébj.yZ—+-ç3 ›£)B>…­¤F`°ª?È"ăy/ëú£> yÀ¥ ë>)¹ãbJ“›¦'å[5~l&B{MÍwFIÄÞ0éuKýkVýM3Í#Éfçh«çÈÉ5%×d¬“†þ|¤¨¤ÞP}Üfß*Ø[˜ÐSç-œCæQ/Ì^° »sfQ3 ð69:g¥œœRÝEŠå…އ8Z{·d«™ “Ñ |­™§µ²3æjZ†ÅUúRÁݤT%š„Iù&£AÊLL¹zpžq #¹hŽO#j‚µ˜o¬€JZÅŸ«­µrÊ4H!^¼O3ßý|Eq¯ñd[9Gß_Q(ŽæÁj‚Ëù€¬“ (WÉ=9¡;Çä{¶ÏQÙ”£""üB†õZU{¦“;E÷5nïÔึžzÈSO>N^(ˆâû@W¤°T.ù¸9rž¨ÙJë4—õ°æòZLSP ˜JïùdP2KµÍ2™ýAW\¨“ ÉÃsz(=¿ÃóäMŒH"wN·Ì/€@D õ’‹‰Ÿo–H…~º¦àâé22œß‹:ª÷”“t Ÿ‰à”g€>ÍýAµ„ üZ¾º÷Žøò °r¥¤Ýä°Qáf6óÐú 7£mT"i¤äÔÿCߦ—BtŽiÇp•"Ò„²b§”¸ãðâŒ\µ7iJ“(º@Óæ%ÇjÊ<ï2¾LÅÓeIp[0¹=z¨=ªB¹–^Šx‹å[ÜÛ¼ÉÛ¨ Ͼ, #>P|ƒŽJá:­”VÝpƒêîørò> stream xœ}MK1 †ïý96‡Ö$ý>®º"‚莽-ž\æ°øÿÁtgñ"…æ%Ï›öähœ5žfs38ò5¶L ÎæbøÚk8ÍpÛµ¯ 'èÚE2Wå4Ê*¸Mm5!‚BÐgcï§ÝCÇþiöÝ ýç‘4£¨ÆÃgY’¡ˆ’ê@m@—lÔë½?­ì)“,‹µšCäå‰9n°å¢¯”t‡É>¢“d»Cík•¥ÚWtA“!DÛñGí1ªâ˜í„NjóÄË*]fQdŸµ2 õnØL¿ÈLª"û¶>âú)ó Q^Róendstream endobj 402 0 obj 237 endobj 406 0 obj <> stream xœ¥Ymo·îçû ö\ߊä\²ª?ØŽƒ¨h:= œÔ%KV¡ÓÉÒ)¶ä¿wfø¾·’cN\r8¯Ï Éñ‡N ²ô/þ=Ù,~»óÛ…œöVøî|ña!™¦‹N6Ýó5Ò9Õ)iºõk¥¬tÈÇ Âu«<ÊkJˆnÝz³è¿ûñÙ÷ëåú?‹—ëÅ«…x@†§}ƒµÊ’œ ¤ìFÕY¡i‰ÛëþÅÅ9°F›þýr%é ?¦¡—zTý5 a4úÝr¥1J7öï–8)ûœtã`”ëõR ¼²öçõ_£zÝ(IƒžBÑÝúo‹õã×ý/¨þŠ”œ÷$™)-°©­w$)œµÚ¡nyÊÑõ'82ÆK—v Ôçb‹Œ§+o=Bÿg¥·(á¢ñž(ùir…„VÂíAb(|Ð hPÔþÙRö·Ë•VfRÓ'Ñ:Ó¯—Ðÿ“€PYÒB÷§‰Ø ZöèÑÛ¥F޳LŒ–’á+ 8‹s×õZ¼2ýÅÒðFž¹¤ŸÏø#ÆA‰ž Ž@cø°úÖAÂ'ãgXgEOârLjލDˆqÔ‘…F¥š¹"„?ÙèÀF™TŽ?IùíUQá c×ÑRÜF‰.Ç$èÖ§TfZÉ$-ÉÄÆAb_èˆ @!VÑoßa»¬ãÇ¢Õ»Öq˜8 ·&¸8 ÛgV¸‰âJ(›‹·Ž¡‹4dä*Z¹Â?†³ƒŒ¥õ[Š1Ù•B Ò1$0TÁBÒ¤JŽ£á1“õi+#‡\E$çįœ-U¿¥å€”HsÜF-´À{ôi팎a‘„>4u S-²´ýÈmKl™äL®†X8 =È@LêíèÓ°Ç –2”·wE³Ë¦Ó´Ér AJKÚ$¨¾x?(ðDUDeK8X‰ÿ’Þíó—¦O“± +¯ÙY…îóuƒ2 À_IÌÛÏp€Sª`Å(ß»Pò¾¸¦`"ƒÉP±"K9ÀXox÷vSå0ÄϦ¨Õ^òÛ]ª?2T†-•ËÆÞ¦å“.\€i2ëß™¼{uA,#ÕÐ-ˆÓ¤ØÝe0ߊ,±¡\ V†Oa+œ•Íœ%çE¹IqÛU>"[…„T¯}l¾²Z5DPî,ŒŠZU´ÈÒ”mUYB IU †ÖHÒ‚í™ëRé“jq*¢ˆ iKRÂ]ˆv1ÌzG¦[Ÿ™xýPNÈtfR ôŸÂö(D&FxÎü3ú¾K“Ò3ÏB (ãÝYS ù©Ï<ÿ\è/âþ(è§e±ž¨„‹µ8…üª¬ï —§,¦”ÉÎj§É“foœ|Ó¸;N~Ê£ÝÜr¢«<ù(O’ƒñ4–ÒûäÏ?’q¿ÒÏ¿ñ‡hö€&GIÝz}Vlô;ø’CAGÙÎîÞÒÏiŒXrü.®)¦[¯Kª.«’–3Î=®‘6¾oTM›Êú¶¬_—õÇyý ñ¹å8Ãá–~ÞÐÏ'oòˆê-›ÀÙâÂÍj…%Ú𠸵wl£5U…ØÜ–É7yòb³P+“Ÿ÷T—AŽéEÊ ’+ůi–|†fz4îjríIbâò]•ýLP:ŒØÌÕ$€·¥«RÂI%ËÌYãMÙ ÀEbÌZIÓ‡eú¢ðùK6þi^ñÈa™¬6ýin“lÝgoj§0ÜΡô鬨Ã: ­«v¹:溉¶ÞëòU b®ã¿…=¹JpØÆ°ý*fzÒ”}Vœø:~WiPàøå4ˆÄ?Þ—°jljÜoÑžIýcèmrª^f›ð ³›\°áª0­­•”¯`Ô€ï[Àe‡ì÷jsàaxn¢æqì%†Þixצx°_™x¿dØU’©ÏZ`z ÿ]cB9kšV\ÅŠ¬çöÆ4?Ø ÿÿ³O;‡e};PÂjÚ«%äSS5EÅx¾™}©zkŸOÍ®óÔß/ýÒŠ8•bóíeô½%XÏ‚XbÉoÃ0çÙ‡`°œBèj×)7bà\‡gá ý¯Ùó£ÅÁÑß»ÝÍÝ»ÅÁ¿:¹8ø~žÿãþ9ú®ûÃâåQ÷êÞd꛲æÑ¢”B-¨M¸Ê%E?!¨S\Û£Êõò "À/ȉ’–•œËJ„¢w°öz–©þËgC](Sx¸\R\»Ò³þrH9»ðó‚v†FúÌ*Î O’A›¾êŒš´Á‰…P“„3ä±æì»žÎuoÚ»7ýo … ï°Á«ìS ÛL]¹_-þ–ˆE|endstream endobj 407 0 obj 2369 endobj 412 0 obj <> stream xœí[YoÇü¸/ù #fí²Ïén _0ƒ>øÁr¢Ì˜ë¥IJaä¿§ªúžéY./?VËžžîê:¿ªêýeÎV|Îð_øÿx=ÛûÆÌß\ÍØÊ*×373ûeÆiÎ<üw¼žró¬˜ ®ç§0Y Ñs ë8ÖKfçËô-=ŒÍ ›¬gÝgß¼øâ`qðŸÙ糯glÛF`)ÇqO$Ÿ+Y\êûN.–ºëá㇃¿…øŠõLxœí¥âþˆ½2ÜÍÓ˜Ôn¥‹•>]ècÜÊîËLr– Û½Xðî«ÅRâÞ,—Ϫûf±ÖÁߦSHÄj±ì¹€Õu·¿ÐÝ?á1¼ p%Ûãøªêé½0ø"o»³qùE$s0(ºïÒûðÍ9ÍE GJ$1Wñ|²Ÿà\oÙªWþȯaùî=~\ãýy‰?Ø?Û)þý6r$FúÁCü8okÁ`ºí^viÍóü³ð~Øèå"óg1 (šåùûs~~Wù mÓ}˜¦æi‡ið¸z7 ¾Êƒ¯Óàûôíºõø2þœ?LƒÈhaVœ;7?øûìàÙ÷þ˜kü¸ÀóÄÔuú™ œU1»qù5`mufsó´d4ã¯~Ë#™?¶¥ÍU¹Ì3¿Ìišv˜ß=.9ç 6žàÄYO˜ê–yEžžÓ„LÇyÞà* ¾ÎÄ¥÷=ë#×?BVü†‚†XöðÙ³zǤöM¹9)`ZÄ’Ò?N‚L£¼®Ã“(‘£ò9ìz‘6xÛÔîÃOá¥)ÉÅ—ŽÒóMKí‹ómÒà:÷³4¸Wé5rí0™+ -HvïÒéÏ ^¥y7Qó“ä”5Ä‹uâfòI§ò&ä€T¯ù¥ŽüVJ¼š/¹\iró'àÈ.’çxo!aÅȬ½…·ºÀ?5 (PAú§Éô‚*”8Ë,~ù²åÀ²»z^{ÕíV_•üŒƒ•ç?¾,éPÎ óäy*«l2d‘½òŸ= /[åÝßNìüçR‚Ë,Bí¬áƒí&‹ŽÙÐïá^'ïUÒß·i…uPbâã#=¬4 `g©©{¥EÅÁïKÛG¬³V 9lq9»Å²[<+Ç-ÏZ[fÛï¾ñ¯ ¡ wAÚÉY?no‹ž¤HûQx–wŽ‘)›8µs½óÔûÝÈö2ïí g<ï½ÀúãÄï.ëéO@¼ÈèÓ…‡¢Í¯‹|2&ï2q5dƒÃY‡žaÈZ|x^.Îy…[ Òä ¢<«(ÆÆÙ—•**¿­'³ÏüùqTKWÁä~%7,¥ŒƒË§@5|ÅÙÌOK0¤¥ð\à ñD0°¸¹0˜°µŒÇùèiõæÂ|¥ "Ф‡c$©¯ †%åˆÊZð… È õ** ¹P(P7¸Žî*ÃBáÊ4˜[œeý‰+lübGɶÕH´ž"×¼.iÒ^‹•®’ÖoЛ, û5{ˆZWÂóz{¡ûäìƒÍ½]ÔÎÚïpEú$Á¤’˜/òNÅúÇøÕgoÈÀ”a\ª_,›.Å䤒¬+\Œ|fåh,j»h®Ÿ|¢Ì<(ÝÁjQ@Þ¡/XFó&g #L¹«3èþ=a¸l¥0òÛPq§Ð÷#§ ´"Ý.)©¨nÑâ’’4kG7¡>ëÉM(å÷l¹ ¥½ \…R‚Šq–ꉮ`àJsrJÊ]EqŽði”=¼ÞÏ7‘XW ÖîA«HI|çWB§È)D)‰þËܶÀ88“)ƒŸ(]4f•”톚Œi'#EbÍØ‚ycETà™ÜÜãS?˜6e°9‡Øn¯÷Þ©†0²Wîk ;Û+_™bþíU9=´WÙÒz`’ÔMIÝèÚÑV¥ÄàÆÉV¥ædx-[•½¯@lUö=™zœ¥ýlUö¾zDtiZà¡]J}G¶Q¿æ¤‰ƒà£MžP¼¿ö$;ë!¥Ôhðò¶Å"›)¼·’"Ji«Ñ)õvÔþ߀§ ¶_ Ÿˆ”»ï·ÂÇQN(S6HvZXܾ¼kÞ7ý\@”áÂWÄSfÉCKáž- zR®ûOdbO@*ƒ’®±dH®C†B\’RÄ}ò;â}àTH è\GóÇÕîæ}TåSo‚EM ½U(è,0bÅ/sÔs:%hˆ À®¨÷pX Y ¶>ÙŸííÿc~}ùöõlï»9Ÿí}‰Ÿ|õ)ü·ÿÙü³Ï÷ç_O2Ô5;ˆ‚]ÍS,ƒB¾œM½¨ƒ’*C´Ü-$HåÔó®öHöVL Úëj´H?£9s'Cß#+3˜fn1­p?n¨Q´©ÀŠ !Ë5¥ÜÿÚk”/7](Oñ覙„ÐÕóŠçWdå8¢93DX— ø\ÖšÔ å Í©C"ƒbhÆ ç*õâ ÕR14 ¥3é“k!PýƒëZ“3co€b­%%ÑÙï$É–:ÖbqbšÈ89tÈN¤Šª¹“Qi²`eá(öú ¾ô5×T{ñã¯pºµÝÄÒÏîžz‚i®ÀUãÿ’ÝJÎ=냠µà AßÝy Àê|´™·dç Á/_´eÓöÛÐFã“ïFµÇb¡¯eP…Í\+ÑÚFd\ Û–$€S«*^„ wᩤñž+pÊbÄñ¤¯}BÑ þ,¢¢Vº¿=‚qý$ä#„(\ÖXãl*Yb­¶Æ¥MŠ=gTÂ6§^cµNÕ ¸¨µ¶‘y$gL…( Œ+Ín $…ñf Šš`-Âêû“I/â²ÊeœJ(^J}‹IQ`M.·ž‡²uy…@ßÁRoªZÖ!8Ö»ƒûš`½P"WáN³“¨xžÎmÄ…Án.¸{ÚÀ€£îSBœHè{ ¹‚ÊR>¾_ÒkWú è#±V¸³ÂÖ‰MwV®©†ÛFVàÉ›¢Vk5ÈšÔ󦉞¦Bgz ƒBÅJ…~1 iÂÆ¦Äž´j?ù-_>6LئҭÐ>  ­nPõŽí™ÚCÍÆPQ8(WkD ºSàÍæ§|* Sñyôæ'/ of͵£“ mÖ1ÄY•]Z‘°Ã®ÉbY*¾À*k–¹\Ì¥oíï=<£Ã’†˜s8§²ƒŒN<0£ÓÀU- !EZQ³cbWÁï:ã–—ÙÉn¹Ù(f0€KÙΫJŽ{”üFB$½Ù ˆ$Ÿ!Z4­˜}Œø.É›¾cPÊ hlÕÞ¦ÝK*ú?yÏ åÁ(ö²{à ]Ä«Û7‘NÇSg+Õ‹R{¶M¥e”cV‹fV…²ƒïåc3Îöc(œB-ð¸Q:ƒ±È6Þ¥ƒ&¶“Hˆ–²¼0 ð@£åqÓË' Ãä$Á‡*80«*m°®KrºÜrÜÙù®“:¶Ž(¸¸rVß±ÈÈäƒ@Ó>(RU#Þbý5?LÒh,޽[,[-Õ¨“l²RÖi¥iÔisì®sÞxÝ‚@ðµ¸4¶µÀfD´Ö ¯!ùë1Õu?ºý¦šŠbü„Œ×4dÏ1¶Ê©:é“dƒ‚söxº:¾úídY#ªõŸgˆŠ,vå/ ßQçA½9RéÛv]šÒ×Ô¦ª©¨¦iª/àm‰¦÷ˆu¯Rr„x9Ò¢´­¢ÛâÈé]ñÝ.5x•ÄNéªd«•òV1 LÒ´®ÄTlP¼ Ó†P&&½·Ô–9ƒtl•+‡Íï'«-sÖc_‡ƒšÙº´L¶y{=YTí»¨†yµ@_qÝ ýJ@梯ï5õãÎM€ñ±¨”G¤9*±cšbX"¬*¹y‡•\QÔnF×)õ¸R˜ ¼Î`¥©ûX7© Ê~ˆ¼O⦓wîY…¦’w!0y/ˆu™‹5]°½ š‘SŽÐ{„nÎ7€éÊ âú‘’Pâesa·qs©éy ‡Q`ã®Cï´šœk϶ÙL‰‹ïÒ”0¼À“ïÈ~†:a¥W ÎÛ|]*¥Á#ñvÍ+à+d’“çã—‰oÀ +é™ ŽM1߀ß-lSð¢Ç¼^ &X# Ûm•½§—[¼Y‰±*ŸÒxAÿ¹À}V"üº(Y§ç¬dq"úf¨J´¦ou­^â*Ý=xp"ky¸1]hÁïV^½¶’oЍÛ§åò Ë†sòy×°ûT²¸L9à­sd…õÖÕœ†óØÔwq£ÛRt/~1_hšÎÝ+ /Åè' ÷Ohé’g®ˆž¥’t¯*Õ 0Ž ï¬Äb|ñΨö¦½›˜*®÷nµíVe*à+šqûÌ×ÍEò5}9:MÇ#+ü뮎g ¦Ýá¡b*îoº šï­N>ea¦Ö¡3åhøQ šÃmA±Ø`;jFß&ÑØê˦Ç(¤Ëriy9S©úÞ®’é6’¢ò=~9Õ‚áz5Höèg·Éó˜¡/½8ú|¼ZÊÕ°ÉÔþ‰‡’¹€v ©j))E©SÁ¶x7Nú›kùR§Nõ~šQ)¬ñÊÞðŠmCkÁ1[8Â~”rûnZºkR×a¬¿I)ïbKˆetºCÖo>„Pb†·à‘SPyÛô:pŠéžÃnZsaJgs5(¹)…?[C˜Ç¤™N§vCµyBàä¬ ­ÄKÔçÜL¸=¿âZI¤ðÉ …¤„f?H6Üf!4¯ª€+¬H)G×`ÍØúìNÆÂnMíÚÊßCÀûïªæ[¦³·rP°*ŽÎ¯ñ׿ë_Ž?Ú kcNº/“훢üvTÿn‡ÃM–f¢G§PÉ5ÏTDÎâ§0[;%c |vR¥¬Ìd¨Q13œ¸³îH=½F…ß—Ö*•`1X¦p†®ÝÇøq[‚ ¡ËŽÀUYÀCo-¿7v®î+ÛêÖÖ$$î~=ûºA‚endstream endobj 413 0 obj 4049 endobj 423 0 obj <> stream xœÍXmOä6þ¾¿":µRB›;Nb¢íqÒU¨Õ¡ýP‰ChË-/-»p» ‚(ÿ½ž±=¶w½{À•k…È&cÏx^žyI>euŲþìïñd°¹ßg§óA]I¡ºZe§ƒO†{2ûs<É~ê}’gœµÙðDoœwLj9ªîšZf%Ýѯ묯³ád¿Ùßy;,† v‡ƒ÷ƒzÝmÆXUw57ç(Ù5‚;Ñ3•­çZ¼ù¹(Ê6¯Š&gæ¦ìXSÕ¬Íw ‘ÿ´a¡ 5cHÙ/Ê&ÿ¥(y¾S°|OßHØ.òŸà–ÙÛ6ÿUÿ¿Ñ ‡ÃŸ­n`¦b ›q ËZÞUZ R¥Óú¢•R-㆕7]È[ŠVSÉ43Ó¦~ÔŒcPê.×pÁÇ\¦Zb­´ö}~Ï7ŽÈ”>£É/àù.sÇmL­áñ(^=²Ì–vá6ƒžÚóBëÔT-ú”º‡M#¸¼&ÍîàrE:> zù‡œôŸÛý-¯µl¹VÁ¶–hžñ¡Ðþ×RvÈo ü.ýú%/ÜI}¾·ù«pÍ1œq.ŽxDÄ$_ž¦¤G¾ ½[z÷¶J÷n‚Õ›V º1Eç£3Ÿ£¥y³©ÍÈõ·±;#È4ù¡¾ÀÁ¼¯S*î †&ŠáI›ÐÝÔʪ×ÙÖ)ÂPŒ"†ñÖ;iND?"]{b; L!0 ˜sRû;ë3-ÔáÐùlч°O¸$cæ`‡„M°Ü65B“ÔÌðQôÒfÞÌ›0LÎÊ¿½$ÊDPkÙ7מXñȧ Ì:×Ëö³*Ÿqäez•ô˜&„Åuì˜"sEÅã<ôªÃ×Þªh¼#ÚnŒZ*DW± À_²^ì<¸ (\¥ ê×rèîˆx•ðhTJ×äÉk '¡Æ$GúûŒ ®>ü¹¡în{”­*ÁD_ƒ!ˆP:Šº¥"ˆâj ·¢‘áᣤԸöZ6ª—ß—)…«1²Ð#ƒª÷/ßðÆÞ ÓT`(íWôïÿ²L0 Õ÷>ßnSõÝa7$KUÄåˆ_­FQàÂvjúMªŒ<œÓé0vöKœL ä˜$]Wé¹×&É<™ï’RwýÞ‰§^…YV){kR§—0¤Æ©“˜Tš…q¦MoJŽ31Ð(RÍÊ´Zª-‡a&@Câuó5:‚/hè)r¦A#{ê KÝõ…„­(O+ç8Œ‹5 ÂúÅG`!(HÜ'Ïá^ÓšJ: -à"rK´A™\ lgKÐÅ#Ì·¿ûÂÏOш–i¦xÚ…Y éèuÊÊËÀ[[´<0G©x/¶ %,^§bé¾¼s¶^‘»¨Êøv†9¡Óþ³Åk1¡ƒw˜„—·¦´°ÊÁ6%ŸŸÙN׳ä‹ÍÿÜ©÷¡SóBäĨ :G„)n;nm²}«ðã8ö «¿l1 ¾8Píp&bpYTÔêØBàj=ÄyDYõšêû¼õäÊQmÉ«z(ôóÚ,*O˘øÓÙ-ãµxœi˜¾ï\ýüÂQæYUaõ›¹í([¤[º§(3uÛEŠá:„ Ó‚Ü+¤0Í6þ€ á£yÕ]ë&OÝË Ž*ÎãýãF•iØ ¾Í¨ùNƒ ȹ`ñË£ì¬ÃšÖÜ ]oásæyÑ‘-øÈ9ßy÷Ê'ů”0pcéN1‘ŒKì¥z+ˆÒ“¢Ð…Æ$h,,¬•ê”ÂeOøF¯…ùá/ȸ´ò.OàíÆµ³Â—/.M-€ci^8Á€qÉ÷…?È®£µF^É;SN ƺ!à9¦¯³Ài‰^WHÏŸáQAè9|†Xàì÷ƒ yçˆendstream endobj 424 0 obj 1407 endobj 428 0 obj <> stream xœÝ[mo·.úñ~Å5HÝ@·Z¾/4ˆã8ˆŠ¶y; âÀЛm%Òâ“lAþEpgø:Üåé$Ån"ÈjË%‡3Ï<3®÷›÷ø_ø{|1ÛÿÎÌ_lf}7H«{;1ûuÆ\Ÿyøs|1ÿ| ý>çLÍ—Ï¡³ä\³Ʊ½ý0_¤»ôŒ÷ýÜôóåŬùâ»G_.Ûåϳ'ËÙ·³þ¶9´ÀP–á<^H67Fp¨Ñ.T3Àå§åßà ¬ëuϽ`vÐB2¿D- ³óÔ&”íéq«º¾gƒh¾j¡“šG-k¾iŸ°fÙ†›'­l¾k|°ðÛ4…èÚ…fFWÍA«šÁcxãHƒÆ7ðU©Ý{¡ñQžf'½q€¯ý ¢·ÐÈ›Òpg­b<È#„‘A…£x=p¡·hN}§¥_ò! ßáeƒ—+¼|†—·x¹ÄË),­·0ÓBñ¾ù›ÿóax"š›øž×Ëè½uÝ|€¿—xù vD!™è”² üÌ–ý8Îÿ|…—•“Àéùj"[˜÷$½ò|4ï9^Îâ}o7L—gx9ÆË:[e•:nrã³Ôx™Ë!ýÝ«üø:5çÆÜä“L9§WXðûçg[&Š}j|–Sã:Ý­j‘w.k .Vî®évîäĸ—Ù­SGxŽª@|½vþ1±æÇåÚþÀLDïïbT{æ<À 5€_8hiŒA[S¼ HJ¸’ ˆ×ƾ‡Þ+·§Ä×Nrë#ÀyÜxÿŠÆÿ .ø”›Ž1k#¹íã³ý`m&›—rDó&®›7?Þ“¯Þ6ñï|‘ÀùKÂåOI£á¹%£¾Ì+ËTA<<[ô${ËQj<Í«9£“OIå¼Ðñ´gn\ÕðR°¼´ÃhÊM–#»é:»C!1±_"Š»‡Ÿ;°Â6Û”&y•¨ç˜.\åâ×ÿ \¤Fâ.¿P zj(µ!#D|â„ýô€þäöõyM••{:ZàÓ—>|‰Q˜‡àípBèÓÄÓ_|Ú¾Hî{³¤«©9‰Ÿ¥Ÿ•ìGFˆUàóx2’'Ùðv¡¦ny¼ ŒySÓ÷^&÷Ãèv¤W…’‰˜“Ç9`•lW] htA¼ß¨¦!ý—£4àvÅÿ—ÍÞjü“ÓÒ*ýT›¡ç˜‘ÈK{É;z½gæ¼) ïsaƒ~Y‚Ñ©ãy¤I u‡èsV*iÛ×;³1F¼IÝÑb”1\ÀëkÌÔz]ƒáä„…ÊÕ–Æq)HÈ»Hæ]tÂMÏ(+¿õ¿w–-öQRä}Ô”àe÷<,ʃO«°hâB‘·›âDÊáLü:2OÞø§‡5ïþ8Ò s Îd“”)œx÷OÙ[ª‘>Ï´.á–“ŸWšóìb¥Æý2=`ÂP2ÉG‹ôò§SböªÏ[ìÌ}}v1o™Òïõ§Aôû¿Ûè»ØÿUz/ö;,É¥Ïùù§î¹êwÆ™óqd$#j[tT°’UW¡9_䦈öƘƒ[cÈ8.ÿŸ¨–mQmS‚>½úþR„qΑ+ÏÿKf-œj —gÑVi¢øt¬X=,uÏÌ]YÍ…Ueª©]é‚´ÆmÌ?)©å ‘jƒ‚ßSª²¨óðïY¾qÈ*ç(äz„L·Õ.#eŠ yÏ1„1b¶˜îþV xÐâÛ#í²ÃÝó¤öésDœè?¤Ó®V•Os…AÞIñ侮¶-jã¾÷"¼+Éü¸c|š€µ¡`unQ_b¹þ¬UÍ ¬å´ét¦·‚Pëþ²!Ý‘-æcÀNÆá€1$,ÄgÆ(² )µÚZ÷8·ºÄë´ÀÜ_c½ŠÓCTŽ•~é@ƒÏ_¶Ä¬ÆVýK›t^€„o…{G½ ÿçù°Æe˜‰á¤¥Ë_eñÖ<\¥Á“|Ùܸßäg:ð0Ù ©ÝÁÌÂ)Ÿwƒ±¡z&aƒT°Âµc”ÕªáíÂZÍ“–Ö\Ãóœ[î"ë´1ÓÚô¸gâ1œYî×–Ýw¢F»Ÿã [,tÐ&ì0\t(ƒÐšºé´„­‰«N=‹ û>H$M¯ÁÑ>ÁfÁ¾Á0&5c¯ÁÇê5:8}™ÍºT#ßõ¸Ñ»„1n€ôõ½¢¶Šw{y¶õ*ú†pšT\ë<\qþ¨Ró±:v µ?eŒ€s+üã›RÜ1민• “ÌV"X@°pUr;Dj$‚Y•£ÑY‘qåÜ„$„î “_ç íz s) f˜s!!ð³—Ïfûÿœ_½º>íÿ0g³ý¯ðòù7áÏÁó?̿͞ÝúJë$XChœÿ8®{°ÈŠHKÞ¿ÈJÍ"Ó4ìzÉJ åªæE Æè9¥\D¾´N¥Ç¯ßÊe¤>¢ÊXG ³½ÄÏzÊ`—²R[Ë´¹ÄÙ]ÖoZ–}å…‹CŽrÝÄ(ÍY0†’m‚¬…j)h÷Zô P=׳ÀUés‹Ïp²§M6Ù÷W…q´‹G 1žL>mÓ«5ë‹°”ùÁ>gùóô³¢†qüÜ LmǾ§/yr-:ïŸMÔ ›p+UhügÀüTÅ­øg¹~ÓÔ^^µ•]ø^^᎞£ÏW&¾ÃA¯yOq0Åï(ùL)Â&Òò^¶½\³Â°<œº%l¢8*²7ë8“½u„Ä™RÃVBbÆÓ3Øk½B‰™Fà ŽóhØ«E}˜Èvêü¿!2øûHäËVCþÌ "²`—a2(Hªas² ØDa7gã–'ç ›vRLH5_8 •yëóÿ£õhÃOwQ„´Ð‰Œ,* Eôå›W¾¬PÛØ>~ìWƒüèá ?¹Û›åÍe&ç¸s|“io·:@RÕŒ ‰¥ÈþgÂ@uò©þ¦E†R³÷øøíO¥dVû„`J[µObE¶RSLÌF ‹îè#ÔIñðîø;hëAø;Ïè÷;ð\v[…²(…×4\k»Ledz`fR¯ÖGôì¾õ]_m«òÈ*,!t!‘4ùN®iD7ɲAÐlÇXWʙʟ!S¹ÉûÓkj9)§½ÝžºlÙ“ð¡IS*ƒ¢|çi'”¶}šò q|Â.¤À‰z=:M<† V˜Ë y7é>ÍVn$;§icZZ¦²k¥50[Þ¥ù’ƒ‰£×$­íhf¿VM¨a{¹¶ä.í¬ƒ©· DNÀôè⊪µ‹y9Ó#È@@u†@¼ Ÿ¿Æ²J ™ùP8î hXÂVëÑBÊ_o±g}-¬77ƒtqûp¶CÜd˜¢®Óiaów¢« Ø'!ªCËn«Š¸’sð²», æì1h0,îöÁX áIè-£û®Å+@!LC¾Ál¹`XÏØ±u"ž¨xÜÆc1:—£l#™25U© ªâÈC …˜%ë R[üâã4î¦U.Âûuíôž3·Úµü· üª¥†QE1êù…¸\væêžr¼‘Ìœ™½×´:AÓ«8òÚ½*_«Ï0¡ÀJç`›7t£F§}YR“þ2ž!!äb9Öc˜+¥S¢ø7åYJ«Zu£XæÏ.þ¸SôÑŽ§xˆCiLßÏ!ä.o( ÂDmKÙ¦' X ÙA…¹ g™?Ÿã™Ó†>㨪¦åVX¦^µä}?bz76 VZRMWa¿ôS ·—ë˜ãÓì‹I­Ñ‰W½çiÃw¦ÀCEî³Ñü¦òIN44¤|¯‹r-]Fç¿.…ºÅ¨ ÿMÊP8ï5¯Þ€»òIPŽÕ²ú)Ï%­ÁÕ:T›jÕm[=Íí¤¿ýènendstream endobj 429 0 obj 3501 endobj 433 0 obj <> stream xœ½ZénÝÖ.Ò÷)ˆ ?ÈB—>û’¢@cGn¸‹íÛhŠ@–,Ù‰%ʺ’c¿G¸3sv’×uÑ´"SäYæÌòÍ7sô¶c#ïþÿ=»Úºþöœ^º¿†ùýìþnñ+¨ˆ9z7•y{üõ ÇÀ@)ì)é%ŽÃiý=þ8C™îpš&ýû¼JÚ¡-®ÃÞ«08,Šò 8oâª?‡qL¢†úFÎ Sÿhи¨“ýÊchà)¬‚ñ‹2´É!hf-‡’Þ}Àñw.è˜Ó>ãj¦ƒ2ìá›´4îf@uKåF¶!-guÆÝaz|zY^fÇÓƒÄð‹0Y-Nõ/‚|°Ãñ¨jçšU.1[4 ZŠÞ;_I5Ѷá [piMGA=‚mƒ3 ˆÛÚ Œ§~4@t Ç•8œbðm'%é…u ‚ë¼–£s1Šã¿€ O6NþÐÝÝÞ¿Ü<ø[Ç7~?þùüsòu÷‹ÍñI÷ô` ¬ˆ‡“(Í9BSÜ€ŸpΤ…áAŒ‚+ÒjPÑ÷¨8)"®ÆÄˆ´õ†p<'½K:ø¶ð€FðU©1kk2H«…ˆµêìè-84£ÔÞZ0ÆhÃ0Ç9,&sâÀâ®k†ÿzØr²ƒƒyðÑJ8œ©ÇÎ%3®– àD9Æg’]£Î¬tzMGz´ XÓ ÷íÐjª:7jÀ¬¬¬OŒQÈhâX‡p›|üyDdéQ<Œaø… GÁêñ­Ë°€ ²¼¼/‚Ÿ¯J° ":Ây†â¡àÅ@Û(œ(,Úž%ÂÕ$©fM·a-Ä)”å&þ_0¢Œ6pÄóÀQ?éÃ%®KhRùE!œÞÐ÷7eå€kKÌ"õ&²2.Qß/×0îUDÈi2#â ÷ùg€qˆY R"ÖÒŒ³ãîÉf÷+ôg€|¥!Ý PV{£‘»zt3XÿtŹáhØCJÁQtÈÖÒq@•Æ2t6È6Vù»Æ' Ã‚ì4Ñ‹šÀ„ÖÀ´á^)Ý~£³&€´PÎùzqD$ØP˵Ä$4&1žNôV*_eë¤{Ú5‡íiâ)‚ï›#K†cÌ’¢ ç‰gE'ºîFŠNš4 Eú´µØYµÅ”Ÿ^ÕjÃG¹ñ¹àœy\L€y‹Èzz*H)A¯’¼bÏj$ÂëXª@ë4¸ÝÎ[³À#\Zô?Œ›;?º=jÃè(È}1&ß\ešÆ¦Qí¡CÞ_¬+y>×Eá|juk|D¥V$7EÑ Ç$‡s¦ {%ÍY"c´EV†qíÉñëÁË[A s«CðZøX˜Â21Lñ±få)³&VvÃiÀ¥ 2hÀ^¤ºÂZŠ¡}Í”°òÿ:ôÒ»³Üð¨Ãç(ÚG ¬q*-%Už£Ä¯›Ü^uUV‹Zð^H6ƒCÿ.NòË'ååñº!¾¼ÈOGIFÝž_îËœ"ÞyyÙ;½,Óü¶5K›q1ªŠ¥Eܫʥ ìÚv‹ØÈ`þ×}¤5ÓÒ‚Ø(8P=t`þa]íàÑæ…ÇçØsafM@²WÛ$¿5ŒÌbÚþж¦Ãðë¡~0Á…ø‹\-À¦jªðÊpÓûZ÷zQòd"='éBæ["6yB°ªÅ¯æü€±f-¼H¨†ˆíªb¦ åªE Œj-j±Ëº°(“Æ%‹jk£Ý|‹¶‡Ån¿VÁ ±ÛBm¯GhC ”@ ž@÷¿k ÁšÎµõUp¾Z‰ådrWó'*¡ú˜Õa ôvJ°x9E›ÁËp@öšîÊ ,Úá6ö#j+ÌŸ)Ì#¥wBëb¡Åõz »1O¨£AÕ”¢mÍ=/VŠÙg¹ UùQ8Ì‚“$fÍGIÎ ¯âÝGŒ6ô[oˆ—ä!g¥€™Â~ÞçRØŠ fÐu_+–±«M€ÜU?HT’]ÿÓ¡ŽÍÈÛÏ)½á‚Pã®ôÀb†Më­H.-+ í1¡°GÔ¦ñ\ ëÂÓöQÉV—ýCvË£ª¢À³ë›Óxs,૘ຩ‡Sú<ù»ÌæµzÞ!ú,׎™\¬:?8†Ywþàw‡# .,AELªÖÆò¾HXFät¬*Í®¼ Öüøößt~®p6‹³}ÑK°ßûú\Ú­`.»@ƨ?Ÿà¥çð’~%¯˜êwh6ÅB)‘z)É÷€Ÿ’¨ÿçJõÛ¢í5\ðÅä¥RHÅIj&Λîuk¶î™ÏƒÏùÅëÒN=~§gít:+ä‘Ô1e¶çùht5§Á*ávOTÍìÆ>Šöü_¶}†Æ©j| ¸@Uôªq F¸™£,ûLEs`¾ûÖ*ûp]‘+Àb…ÏC¼1©Ä3¼R¿h›“¸vö»R»’÷µ×·îi>Õe¢Çt›ÕˆG†Ÿ)Æ;I¨V€R!ÛpRÎþ/+@¼¡uÒã>£Œ%à§Š$mTÿM+ÞM“M·™;`þ«8.›JdŠSogÞ*(u…=’ñ貌›yÌŠV‚Ó˜ +6P]L32Re”˦°•‚®aÚLžûëU2IÉ´½ÈÎo]=¨nðÇvÑ÷–¬™!¡´ë~K½³¾‹£ŒÔ‰ ÷¬ô;Ô—iÀšI¥­R3Ôþ»ï—¥ÿŒN‰ «Q•ðª­Êïé/uÞå.Væ<„üç±!C Úß-?„w7y™RLWN *gˆqbë@0TM*¯û2Ž×…< #ËK¬Ä›þÔ¢îJqúÛ¡)¢vÅg7 ©“/åædûS.@…qI;}8$ÖÔ¹ØY^ ^ ¿¸L^í ÖÝü WÒ«’endstream endobj 434 0 obj 3081 endobj 439 0 obj <> stream xœ}?kÄ0 Åw öW’ÿÄÓöJ¯CÛ; 7”N=(d8úý¡rbÒ›J V¤÷~zñÐ`{úyžÍÝq„ËA_¢d¸˜«¡Eý8Ïp_UW˜Ô/GæLE9‚9`a«¶#ˆPgcÓSuõÛìª9üoGÒŽ¢„Úž5$ÁÈJ* õa£’E}}Ö—n y &%‡Hë/æ8’ÀÖ I|º!=¸ä©ûìT$…¸ØÉ‘}wCh²Õõbç¢=º‹è÷¸†ðnÈÄJOvï’}Õ±¸‘JnŽfyñõæô·H·ß¨àm…m²=m€½V"‰¸ç !jd “¥ÝÃr¯ó ßh`¬endstream endobj 440 0 obj 268 endobj 444 0 obj <> stream xœÅ[IsÜÆNå8—ü…9ä¤4zïÎ)^c¥¢Šm±*;Q¤–„äH*2ýëóÞëí5€YhÊN©JÄ^Þò½ïÖã Ö#þK_\¯ïÖ¯v«qð:Ø1¬_­Þ­Y§?/®×ŸŸÁ8/×R˜õÙK¬¥´Âû^u_~ÿÙ×gýÙ¿W_­¾[ÖøÞ`­´¸NܤX;¹¶£4NöC÷E«ye6Ýë~#á•RÝs¼ B;Ù½ÅKåLPÝm¿‘Ãè„wÝe7…±®{7½ŒôéÇAª ­ý×ÙßÒô༸3£‚[g_ýé‡î[˜A ïaŒÝ&ðAy­ºW=‘atÊç!Öj;0£p¾»¦ ”¶éJ×½¹¡¡$q ,Žé>ÂÄ"غ7·8B!¬ÂKï‡s|‰·Í(•4t88»vpøÎ>*-ÓMÜ_ãÀу{ Í‚ŒíÎz€ÔÊtw0ÒK?.Ìï;¸²£Ñ.RÑ`,"D*ªÁˆ2Ïz<…‚·7Jªa¤9‰¨ª{Ó ÍF#Íâ;øotC^â¨xà¯í®×q #t·}‰£ Æ©npª[ƒ‡»ÞÛn{ÑkXŽM“á¥è^ôSßx…3â ÐÕÁ—ø¥ wW×yXG{Zò®ŒÝÁ¡aùÐnj‹÷C>|Ùß+Ü »¤@š¤}\÷Hc%Ã`5hÇÙ¨DšVÁ(0¸ÐÜ >¡õ ¾ŽË¦iââÃ(l7]ð².†¢;ŽÒ²¯êSâ‡94‡mäuÏ'º©_àeFHâá(ˆâu¥úvϾI‡ß,†Hƒ"CDóÂP”ü»ÅmiCâ–É…?aï$Sy\…Í+µ/ˆ:I² Çáý*X-Y•Ò\Þ±<u_ÿ`˪‘ÇâÃç “ðKH_¥kWè8Àì**Å_ëÀ*¸tÕ¬N²l½È"†lÿ!× @j]£P¨0ú?y×iÄ«ÊíG‘Š # BYV˜½mw9—«V+çÏQ•¥-Vqº[žvWÇ22.ªC¾D—Vúfb"u ,q:¤Šb…r*£w »‰îÚ-Ñ" è%¾4‹éÙOuìDÖÒ«õôù*+ÉüÉ€B–Ý×½U¸"@/Ω‘£L>Q‰¸ç›¢†´ä£>jÒ0¹hÚßï÷À‹àV$;È,í×ÚQ•Ñ#8ïÁÄÀV(¤3&ÞÌ Æ–ñ PÄè0*¶ò'Ç,®iü ›%®Jן㥜a¿„Aþ¶L@w}ÕLfÆ$Æjz•Áv&»/öJ‹c»Ïz[‡gDk@î>޽„« ÞÓQd÷²—q•4æzaפÒƒ£ÕÀ „jðE%Йx0×Xue×#lËu“¹îDd»•‹l7 Q§±Ý-. N€’Í¢?v@ ‹ÑÓ‘à2³75P$æ9úo'l—@ Ñ]ŽƒìÛi[1Ýÿ©Ìüˆš(Ý1³–-ÐÛŒ( —mHƒq3[ŒYh€P:|ô›x.+ãoª-:ßn¯ŠÑhíxá„@3ØJ¶0 ÂŒj"ˆA拏9@74m µñ/{É¢6¾NÐSœ!´à‰YBA™*¦¼8+ñܶƫJ4†2õ8¿Ì¬Pœ0kó[¸²ù ˜IŠìš8kšötŠ{$­ÉŠYìÓ„mÏÒ…Ã&f‘Y|¯_Ä«G¹Èâ›S”!Iú2˜M BÐ-3¸ÑêÚ½îÀu˜9.S3w¯ŽÐIìer®òj¤5pWÓ>ZcØú.¦«ô£ÉÒ¾Zæ°åñ‹>kó˜ ùÙV“S%” M2ÉVxÑœø¨­×‹R3QF&j7äÐaLWA#M?"­‘šp?¢5¸Z¯5hR‹ÐJOí²EhãÐÚcV€­˜àÙŒá4x §Ãs™v ÏŠÃóC]ÚÖÊjiáp­•±Œ.f6GÓà þ,éú^l>ªïhyÝ~«v µC'ĔȞ)ØÕeòÓy SóŽ:»p˜%uE>`6ÆHŒÞ$^ÿoÝw=YªA©*eÄ,¼llжq¨…¬•Ó¤a‚£VD±&¶5S˜iü,Š “ž8÷³<è ²À)H·3 ó㔼ÄI€ÚÈH§Í}¹ /Ê7K0o` µÕKø¢Ç!ã0¾ ÷9Šbt?V².¹ T"€hÔØ‰;pØU´ÕƒGÏÃiâ,2Ù©h ¹“}PëhP“àºL¹S,µZ†É|ŠH· fB7+1 ÕL¼gîž‹5-ªæ|ÉíÒ‰)ŒKäØå£+Ê+¦£ß×?PÖÒëÍʉPÉ ¡Í¥XÕÜÜ×Ü Å©¼>ä†Z]P> Š{f→0ØSÜP&GMýÐcòáb”ò ÜÒh…[)ò'ÊqÝSô/KÞâ.ó^u[faã½#a™&Z&yÚ¢Z%q˜„Œ’Ô.:{÷L/»q!™Äûù,Ï£°N@5(Ì>†‰çYþ«ºLF´ ó&/± 0àÙ-d3£WÏèCL1j¨—Á–Iö$Ýìbõ¾ˆùÊi®"ó5c#(ît0¼ÏºU>£Ý¤”ñMŒFÀ@^ev!n @iKÛ|’È›³MØt›Òδj5íÌ5o™òJèQX$8ºÞ‡7ÒV£¥mÙ¿žE|‡÷ªEÔô11è,ŠfMìÇ¢_ÌjŒÓEb&MR덱ÉIÛ|s¡Âˆ}г³IDiqpÙÇSQ°ZÇŽ‚UWÌ™ô‚[gé i4Æ¢m d7i.êœ)}Vp¸,_R§;m{¾É¶0&ížúösj‹ëL¢MØñz–Ÿõ°±81&V ™€ˆìƒNì@5ÊÖœ•ªªyicÌM òš‚® —Ù>N–^~JjXO¡*8Òªâh`ÔibÿÅ4Œ$i†ÙÚ¤ž½°·ÂA3ˆi>m°RÊBJêð´¬åby’¼¯>Y– iÛ‹TçÂ'í1NðÖ˜¦«Ñ±FöR¤ø …|m\DØèãà"ö‹åZ‹%b+%owŽ‘õ–™àÜVÏû+ZPS4;ðk}<}10K„§>‰ƒnJ6jM‹¬ö‚ä.çü·¿†ÍV=Ù×þàìªÒ# ÌZ€Whó«âaùUeÌà›éÕ” ÓÅœ—ö%ްnvÉaÛòŽ ŽhØpyOu2¹#K´ Iûì`ªØ,xRCîÒ7 ·Üv( L‹ò¨µ<4Ï¥OÓlÅ"¤œT)ÇgI.КKy5³:-Mâ±<&REŸÓ'1âsHÄAôž'g÷olˆ¥²¶¥dÖ¥Ö¨Ð+o¯2‚:%qæ!ö›”ÓøEV¶ Eãñ妾ƒq‹¬,s¬»¹úºôR³‘‹BYøzàC‚|š=Æ…¾šï„MµÜö×¶‹e-—:#Ž•æÞS)+,+UÒ©S¸‘³üÍUúzæìUMsHîMša¯ž¡9Û‰[\­ˆœ|r×*-í‰ëé›KZñ´)[”òêê%PÛN_0ñ£¬±©g·±­qŸv89÷ö*óNdнÛÀµúÕ„âè“´}é#+:Ìü3ž­ÈÁ}ý:h›±'HE%(Cášk- l°8pZ?,…AàÖô‰ªÕN„u¹'%:kçcÈE†èɲ=þ>ØÅÒ pqòÊg=…?Z|e¢b¥¬û¦ép̧Y2¿Âý>.Bò–Sï£Ú@Äô!¾HàlØ+ç}l¶¿v•­ozêâKúb¢ß­AÀ,†z0ðÖÆ£SÑáÅõêó'«ÇOž®o߸\=þçZ¬ƒÿ}þíðçÉ—ëß­¾z²þnÿg¶‹ÄRàëO ¼ã2XÔ„©ÑüPõ¤·üéb+‹Ýx¦v㱩3Fwô\#Ygæ»Õÿè=endstream endobj 445 0 obj 3885 endobj 451 0 obj <> stream xœí[YoÇŒ<ñ9ò¸y1flí¸ïž‘-²%%rÙ!¶cˆIQ&¹’HE!lç·§ªúªî¥H94¤€@ÍÑ]]]õÕÕ5û|!¹ø/þ¿{¼õÑ—~qpº%†ÑLNL‹ƒ­ç[’Æ,â»Ç‹O·aܨJÚÅö> 6J99I8-ÆÅ2_åwJˆ…‹íã­îþ—÷n÷ÛO·lo}±%.Zà5I\'0)^¥I}Õ™~i;¾ÙþCœ á„ ŒM£ÓF†-:ãå´ÈÏ”Ãg…Òg½„£î~ßài”jìîõ²ûk¿ÔøFvÛ}¼xЛîË~©Æ î}g‘‰¡_:e! ÎPHat8*ÎùKo»ßÊå®ñ§|W®>Ï ýèÁÜ¥ò¦Ûîï½Á7ÆÁƒO¤Š¼im€}`Ìv÷äQqø²<$¢÷›ûmœ c+‚ÿèÓnf ý­HšS—Ò€¦qáœPYÿé(†‹}5q4jÐòÝ'ã赃•v|´òÈÿ$ÙÍQµ@C "#Õ¾_J£ý’¾Ý/'©´__ÌINÆ‹QÈDäh ˜uÝI/°%»3\Ùqvo@ÇöÖ×ËÕôƒ–Ó”ÿV›åJ,`à›sµ”nÔb ”¬Æ@çC‹°ób©u Ô`Ù®>|õ Ät">†ÁÞûùÕÌ0þh|ª5.'´JÒ8¹K¤ó‹ë±Ëå Þ)‹“Îàí£^ÒÿÈ5.‹§0~B*2.Žk¹4‰àÍi!žGú¸è¨pP|ð$÷ ÷Ê(\ùÒð‘=le:¸Z½()4ò{TË&‘B—¢TÖÃ6HöIO× Bì¼»È_’-1®MÐÇ~¯h9mmµI&íGÒÐÅâ`%²Ðbê`²!2‰<×$re±{ÇDâÚØn‡ö〠˜ò/ÀxØÁ`…SgEý§Û[¸T—žQ—6žtžµŽ©7½×£Ôµ1ƒwɈšå8•ŽvÍ _ eVŠ:g³ŽËÓ=Ò ìÛ“¸²ˆF¾ø—aÆc©Þc$^ âÞê”aåQÙÒ¨H˨8å'RdÞâp2yäßSçðƒ,s’nDv]X6›×«>jü(þIk±1‘“\ö—Ͳ ˜Ü¾æYð(dÙîrvñ(Éc£ €ÝØÁô;G´ ¾!P¶Œò*/|Üð²|wPã%‘eØâ>$] =‹¾àDFÌQ›àZ$‹A à’ÝNFÚ¼Ërˆ= F†Ÿ€$ÀzT' U„ÛÙ¡)J˜ÆG³­'7Mϵ‰»s¤¾4ak= hävÂL2SLÚ§÷øÍŠØ;Û“a‡06OkNˆ‘[=?pkÓ _œH©7åÜVU†,È”º%‰˜àŠ[÷š9æwÊS’³$ÃÑ'Go13ÿ=0å“Yø=.®Šaù”»œµ<sÑmì÷v6'³E ¸€ÅO˜Ì\.5Ö'œ·/JÞ\SZdܺZêÑWáÓz•šu «רŸjö½23öš6B6‹~ö3$&ºƒÞÎŒú‚LëóýÖïGgÈòº¬-ù"šd%xÅÞÏO8,ƒYý»¸bˆ­öÆÑB\2å6øÞbí±½:tÄI,2å(³zB_œ»Ÿ-m–àubòbtïÑs¢QBF ²«#‹ IÀzK+BR…ÆCv‹c@uäÎîÀ¥Ý÷ùÝíòîïOš ?„ 0ÖêáTm!xGûåýMO v1°²¿?nmðEߨkS\u˜8UÒ€\td}€S’c˜…j#‹´$ƒ¹µ¡¬0¬PINZ’„»ïˆsd*Ä”«È~YCl¼×K¤úßαê ß"B´©C'YüzxVC/³P àyÆRÁzÊ%&7%¸â¡ÉRßË,Á”=å­Ð ;V˜(ÄÂa,!xV|ï|U¦WªÉ"uË®bƒ¾Y–è•'­ÎH0ÚW^‘;åšm-;¦lÄ€J<8æ:á™C,¾$a3Ië >RRe×S•ÃÑÁ™‰vËÊ'tG<7Ì ò^U’ªÛ «\’Z½±$%\ÙŠŠWÒ%ÑŒ«®ÇLv…[.0Ƶ¼ížg°³U‡¤:ÁÁ±ü“¨ä½¶\89k(¨>« c>uÅÁ™ÆÎÑlÎPrÔ‰ÉRbæ£)Ùª˜HãËÌyd³â3%ÐlÝ[u.äTB<ÞYOi •1M¼à.ÇM±8*š ŠþºÃ"öU[-eŒ”¡‘$Ü®—!‘“&òÆ“Œ‹ã¯¶)¿\üÅ8„)zÕ úPÖ` ßIA}´1¼2Ô–£¡…iJ9B¬á Ds°*Ò%5 š•;LíL5,W‰³QÏVZ ÍÁ3LœÂ,$y•ç¼*XŸ=âák'þÙ뢢€¼ ŒÚí¡L(Ø¡¥¹ EÜb9IŒå„{¬—9ÿÀ'±j¦Ì?Pý»SBû)9§TÈóÊԅÃÍn†Ì`Cž„yÄ÷êðb E™®“ ÊMÌäéÐí¤Íy0™ä²WˆM"šÞÕÄ»yZc:>ÅË0Û—os1‹J¹ÓN~¸b¹A~xT¦³µËüªÑš>­Ö¯Ãm+¾œRŠ«Üº{Á,¤”ÞP¬P²—*ë‚r¢ÝrwT.LN§œ EU™ŒqB²£”±|GӽدTg€B”I§ k©ÖAr6GHpšc¥s ­\£Ô3i=ŠÌ‘K¯u§-¯” @ˆ¼uðÙqÍù„†?€yµ1 žõëÞ¡>·ÁM±£’é$7‡k ×LvѪä~‚d긇ˆ9Ïh‰1!Xœ|#[_3ÍX»S¡º…,DK²d÷'‹±H¨‹ —Ó\×";ŠŽ9¯eþáV±ïÃüð¤JíS1v9_®}Mdü¾f–ïy_CDMËKål ÖH3hãè7bâ;ê(„òÏbïÉXé(+¼ý¾ rÄaì}†Ç"“ðƒ´ÌŽ~œò¥0ÕˆpÔKZ¾‡öe´5ˆY<8Qr‚ ÁºÞÒa¼vÞSŠÍª1Ñ}0ÒarNæNÙ8Û9J‰€½ÁRJ(-Ô$°Ž•Þ“+>œµ¯Ù ðÿ ×G5JN«åÙÐÁHÑOjfÏã aS{ ¥”ð±]¦Ì(Lä Q¶‹³¼ŸŒÔó۪ɦi´ì‰Úl]o+ÅÖ-7,œ›v[SÏh1’¶^†<ÃÆbqíô¿ø©Ò|â%ÓH~lHÔ*f0¼5IqEA@L?­õ$Í:yMæ¬t‰quQÄYí@‡’Ÿ[ g:xò‡¨ÁPoè’®;j¤Š¿|qÕß„kðlÒùÁªð#ÃØ}Mk©œ>³µ®¼Œ×HŸ/à ҙøLB<›=J’ÈX­£æ“ªZ3X­µ?ÓcÕµAµâ‚ºžõ’å@›Œ(·1yZUuLSGlcYNÔG›ªìF¤[ž¢T-mp­àé(ÌÇSÖÄxÓĘKŸr×!48Gwõ&) 5µ‹CYfYP—ÞdÛDv*~ê]:"º*ç?›ržÐælL6õÆ”ù泩(e¿!çÁ²™1k‡[˸í¥ΠÃ÷ ¹4å¾fÆËäc&NêÆ’rU¡ÿšÆ…ƒàÆ/%Ö`7^p®½~Ná¯î=à …»ôY&eß“tI¿Ofºeu2 %±dög0¶n•غ¯Ò„–ª÷Ô~öˆGŽ¥³¼°§a‡3öÑÔÌt@³ ”WlÖ/•™Ús¯Áí<68ªó3éž»^°U‹üHŸm•±Ñˆ¶æaiÀMèÖE† žEhHxgõ º÷L÷¹¤ë†qqéD‹ ̦NZe™Ûéxø'åÔ_õá{…ÊCåDûÛµÚFÏ= ƒ¿‰ÕänÑv—XÚ‡-µÞ<(Ö=äÖ¾Hí%ŸRWx?Ëõ³¹‡¬ÚÍñª©ä`3u Z܈°ÇR}fõRíÎmŽ­^*žnõF!‹Ý:!a%áíç¥ÝæØèû¬|ôTvXŸ?¥Z.”¼¯ëÁJ¬¼jg]T7Þ©6 õP‡hÕýTÐyä*–©©'“ NA,qóÇYVG  Yê-r/.œ ºcUc×ÍZ®‰,àu\eÍø†T²»eÙžœ•p¬¦ÃwªK Áì#-$¹ )ëýbë¿Åoë'endstream endobj 452 0 obj 3569 endobj 457 0 obj <> stream xœí]YoÇœ<ñ9äe äaÆÉŽû>œØ€â؉;†m"y°ý@‰ÔaóHɑ俧ªïžcw¹ÔŽ(zmˆÎôQ]×WUÝ;ûlA:º øøýàìàý¯õâÑÕéŒ°ŠØÅ£ƒgÔµY„_Î9„v†-•‹Ã‡ÐX0¦¨q,Qœ˜Å2]¥gŒ…&‹Ã³ƒæ¯_ßûô°=üáà“ïȪ9ä‚ÒŽ(Âü<Ö(.¨§X Mí"ÝÓ †78þ·l—²éZÞp±T”w„ÊæãV6_¿¶KÖ|ƒ¡Õ×í’7÷ZÚ|Â]ˆö­°Ïç-egkþÕ²Üôo-` eæûÃ’qõ–"Éž¯t!™ê€ºD¡ÀQ:}%e¾+ð©ì»äÒvb±‹8†ŽOÚ%í8WD5ç-íÄ6'­Db•nI]ŽÅlg AjÜ(´¬ÓZóÐÔV$³Îât¡©J;!„•HRµV¥Ö¦ÖOZÞIxDLjP.ÛÖDô?··lÉhó€+iF)£Â³m|É5a±Ñw ÐoŒæ®YPO”ßå´Žög’ -”RøË }ý"Ö„Kéj¢zΈn3yñZ^ßµqÔârTƒh§¸5±ß»°ì³“ð$fvrP%VrÔL1ô·àK:.O²ÞÖ,ÝŽýãÞ‚¹Ðz ®NJà~ßnŽZÙQb™lŽñŠ®óÕèü´›²ž9 &ÅBwVZ±¡ !aQ´†ÆÕÕº3‹ªõj7³3S5åó1‡½ ÌÑ+ý:}°5Àì…tdfçNƒuªšjk/<&gɯc¢/çó˜¤åO…¤næ±¹è8›‰ùÂ8tØ÷¯geÔ¹.Xžº¿^ô4{©yd!©-›Qkà '‡?¬h¼,¸ïéJLÑç×Ó ßrL7`áãÐΔé²%W ?ceÍ ÿá¦ä´¹? ˆ=ªïQýíGuÁ4›Õ‹©ö¨îP}æTß÷ï ªÏ!‹ˆê³É¢o v± Õñ6¢ºÆ*ëtÂ~ݵ2º‚õS¥””gì¬#EáåÍÁûÿöð¾‡÷kÁ;ƒ)Ô<ð^Lµ‡wï³0?Àû®¸Wà}YDxŸM׃÷wÞFxW° 1µ§z|q󧩬Leì{d¿Èî@w`Ï3íqÝáú¬°¾#ÞßTŸAÔç’Äõ0ýWo%¦Ó”²a:¿ ¢btZÆo[Š®­²›yný³ò¼ÜM€ü3g^ —Övd÷‡qÐ{•SíÊ74Ñ—ó›ƒòy˜ï±|gÜ¿ž•`>&7æ%˜TØæ¢ULPÁEÌô\õVXÂo A$–àGd’akL6ÑI‹è >p}jÈÎ×ÌF%äÇäš0n+jì 4Yc¯»9™J¿a•· µ÷é÷>ýÞµDŸ> jSíp‡Ú³0? ö®¸GRð’?³¡öP&¯µ7NÆ{ñ›5Éx-…$ã×NÄ%4ŸNÄÓ6ùšlœ€"lZ3‡Ûgãûl|K\׫}³àz1Õ>w¸> ó®ïŠûw%/ø3®er;²ñ?ß®lÜ}ˆo2Aíé”\zä¿=нOÉ÷)ù–Ð-MÇçÙ/§Ú§äºga~€î]qÿ®¤äfƒî¡LnEJþë·.%71%b$%Ç—T4ϦМïñ·Í÷‰ø*4b¶D¼˜jŸˆ;4Ÿ…ùÍwÅý»’ˆü™ ͇2™'_ãù>Üšï.UÇ.“™úØ»§&±ýͼ{jŸ©ï3õ×íœÎ–©Sí3u‡í³0?`û®¸W2õ‚?³aûP&· So¾Ê²O:‰Óï ø_W_¿¯rÉ%CS[‚Åm×çS<%÷¤•x\NúO£[kŒj.ñÍ™X¡‡Ü߯™^¼Éðâx*ˆ{e¦{‹æÅY»¾9,ÊòæA¾ë~\œ‡¡ ®8j)gÂÙŸ·¢yÜb´A©ë€W~‹@¸‡ØÆd–¸áqˆóÜì¸uÖÚrâ§Ðhd®«6£-vo‚“§ ãÅò‹Á݈‘†‹âÁUžušèn>nQ,œë.ÃØI#¥Æ[9 Á¡¿²¶ló4½‘´¼{ŽzèÛ·%ç†ÏŸöj|Ø«H’ Ú#ñ5§KÎ=åî ©Èì—ˆbt쀩„ÐÕml)¸ á•“Òý‹Søå5֪ʀˆíd^8£(ø˜~SÝ37”4̧€ ·ŸÀCzu*ÔáÔ©&R[3®ø4]jx%……*¯ÏG™e¯àofÜ,ÅÐ'Qû÷®ê™Î½†ÃFÃÀ8ZŸ(7?ö\B­å+˜tj=-_áK):'} ê ëˆ&]\â´dÍÑ{ƒ#„ák)ÃÅ•c\ãN¥7Ž*Š*“pc(’ôß™"eÌj”Œ‘a7@-£|ÜZÎ`Ki½¶œ£ÐÊF(èºùµm=d­ðňм«pþ…ÁÀXQhY)64:çÐ/Bî,óUP.ïžµ— xE†BÁgAW+ÍDÜÀ¿ XWÖt¤âÛš÷³¦ùEîœ}ôœhFLò€µÑ0© =P‰Ú‡¾\Hg=7òåÒ:Ç *®xh…t¨Yü]­Þiºp§ƒœÜôÉ,Î=wÜæþI¼¶žó5ùÙ½{*M¢Îã-­`¦t7þ¦÷àÚ½û¶NüÝdÎ z_øG5¡WÖÁÿ;Ðî4`¼§˜r×x3Š!ÎBP#Îb~Üõû11£?’Wv¹×bôBoÓ‚¿A$ú{æ×— Þ/b,ñ ’û~Ò¶§í2¹ÂKXÒ äôEl}Ä)‹.0ÃÙ/2§ŽÜå8åùæi)Õ‚WCÊŽÒ†íV;oõ`bt¼ܤhÆb©4ØöóªZ]Sêôd0Tàv¸ôæãÇì‡% ¶Aª‘;î&Rï¨uR ÊòßÐ’»ÂDÁ•£¤'ÿƒ8 ŒèÙ*¼Ü¹ìg{’Æ,ÔÃýÑlÕô[üûråôߣg—qàí»ô¢þ~q’¨ðc=ÌñÒ7û(7#þNÖŸQ<Óqˆ÷òKª‡Jþ<÷uüòw_f¢–~Dš;#ŸüÓÊpN+{ºr’ǧ•‚ êX^‚Þ· ø> ‘°¶©Ð’ˆUÜ€ÛûY(Â4+K7ñ”£;(TËœÊ=ûZ‡xÓÏ×ÛPé7ÔÕ¡{5f¨³q\\®u©rqìQj=¨¬ÏT•^YC•/D­høÄm³ý³ibƲið-®@:ºÃ4µ“•·²Öld©É—xÝlo rr³`Âm’ìø›f îÐVsm¾;²ZÃ’ÆÄ®†îx)ÚwQUcWëz‚÷—-æ JÉÑ÷¨,ÜP5¡*š‹€¥”(Ÿéø¿>©s©1WžEì\#ù[Š}5¯Á«•¶7}o{b$“@Ÿ}yHÉÒ7weÏÊGW•ߊŽ|ÔÎF§N-LyÜáë~ú¾Ve>,yÞ«x‘ÂLYÜ&€%ø2Ýy¯Š:ŽT>ºs•ž€U/ûz/?÷QŒã[ §D'k3©Dd‘+p­¾¾§áŸƒ”XÆ’´Ûà"Ë N3! Ó+Êœ?ýb­. dE·¢BX&r똤Tß«iÊÙ ¯†åa\=àß+ q>PñdoP²§öB㘰Š‹T(ßÇÜébFÜ瘌pÊÂ`N}{@oPØÖƒ¤9Y¡9÷Ó~¤¯e önÆÜåî û–hi”¶ãà"gøJŭhu œr/OÁŽ…mPhÙDµ›ÝÛlæU€C"»j6·—ö»kmØÐÚ”©ÿVøžˆIõ†9ºµýÊ÷†¬‰ XR‘,4}Xý¬tiÅB¬ ç¶[HŸzç%âé™kÜL¯œ<¶~Óp+ÃâC½šÑ°R³_N¨­¬ÞX0œ¨µk³53Üââ?+s|C®}¥x&ý¯¸‰ïd¸5*•v•Š{1ˆr pzñŽßõNá îw¾ŒÅ>LB‹'Ç*U™'E £ZÄ5jæ÷äŠåæH'V¨ªÝr;zŠ"Í¥/Ý"û‡Q.ðï‹­õ+úÅ®À zVXŠÚ½¢Y¹÷ÆÈÒÛÒ“QâîXà>·¾ø‰,¿ôåz"†ð‰¸Ò§wE( cÐP[õ§~ˆÿRèþöüʽ´xr…ô°‚µ9ÛÂ6C^ãRnÕ X&pSœÜ)¸–;õ²RpŽÅ¾ÙuË€µ½˜¢à²q2ÿwZ…VÊŒZk¯’¶&£Õ‡þÀ¬Iÿ WùžÂØ¿Ê;ËB•ÝÞáªÀãg)ß)òÁx¾nØü*êÏxN–6ÓÃqÐ%ª3=^NèðrœøÃäa0Uâhø´È¾|N)äàÏc)¥._DÕE§2UÊ ;•(H¿ŽÝúÝ€û¾jK¯yqÍÍn—>ŽÛü5÷ϓͿiÇG-÷J{'òAF—ª Êù€n¿Œ¹Îæ*Q©Œ˜a¿rÄ¥Ð7P=@ð-5/Ç|½ªí{#ý3¢x +dˆ+Ãy¬uFí^» uSG4qLšŠªš\)—Ú’~1÷jcâœ;O³Ò˜°UÚþLç=Ó“"táÂWÒ†{;ý±ŸöPO¦¡ŽW൪lÊà:×o#@±Ò®Õ VÔ€×­£ä XõC§ƒ½ÜnWØ]¥£Lpµî”C‡ǾïaÊÔ\P;¬õ-=<<‹7~݃ÁÉKEï™ÃÕ¢–É”¼ÔÏóÁÞg)k—͇ΚÉêè*2õ[ø¨­`˜&h3zÜ{⨵è¹ß…ž¶‹ž&iºš{Ÿ×¨·üæª3¶'Pj a¡“”Q«W–‡÷ ãÉ]BÔØé2>YËöÞiüüÕŒúçµÌap·ôü«ƒÿxc}Hendstream endobj 458 0 obj 4312 endobj 462 0 obj <> stream xœ½\ésů‚oúœ?`óm6h‡écº{HHŠ`s¤BDU©P”eIvbIk$p*|ÞÑÇë™ÆIQ¶wgúxǯßÙË›¡W›ÿ‹ÿ>½8xÿk¿yv}0ôÁNn˜6Ï~8P4fÿyz±ù㌠z£Õ¸9:ƒÁVk§¬3 Î a³ËŸò;= ?lŽ.ºG_ôÉÑöè_¾:nÛc„'°Ô¤p&Rm¼†•.õMg·»‘þúîèOq‚ê7h&l ÎXÅ,:ëÕ´ÉÏ´Ãge¥·c? *˜î³- š‚Ò¡ûh«º¿nwߨîh?<ÞÚîëíN‡ ¾ûnD"úíÎiÛÊâ +‡£âœ/·c÷iY¹¼À=¾ÈßʧÏ3Aõ`îN{ÓÇîï[‹o¬ƒ1Ÿ(i3Æù@ØØ=zœGEðeyH‹>š}?¹0¶ZðÛÄMs¡¿UÒoªËyßë(çãSXÄXÜ|ìà»íž€N@ªÿ)ãƒ×8jJÆîžïéáÛâñ'ðZ Kß§¡Cèn`èó-­i ËtOQ9ûKœ„ áˆ+ÖsöÍÁ­iØ Nvˆœ¹œ€¤k&Ñf@ è%â?ÊBCùt‡8Öœ¦î'`õyBÎ' Ÿã"¤‚Ï® cwŒ²)„dö'°!kF›È:*˜©WdtòFQXK+}²uD&póªhòª wÆõãVâÍî‹òy“‰ù7f¾H¢Ð¸0‰*‹VHy¶ð£µëŽÏ‘"P H¨€ìì"?;eú‘NvdË2Rp™‹ôá2é&‚ Å£ÍH@¢Q§¬bÆÉ©µ'±ÛrÈS¨€< }綦öð= ½ãQßn(=JÃÓÖŸI{ÔüéFjðÝC¦dšt¢Žôué Hd#Êo„w­ï4ÅwYP@cö7´^g!o6ø$“x^žÊ÷,o.ž[mHý]AÔó|nh'næ)!äz›>•™YUÌ# àÐ&õd޵Xi/(–àm¦êCPŒÌ@C‹óqcͧû¦|ħA‘ Y¨—ˆ/3dbyQÎÅ-a­4¡¾m4 ­WÙÉÉÌœm+ôf²ÿÜú #™µ¹c7ƒ¢½^Fë·n«§bQÄy#ÝØ5–ÔöŒ-¨ ½¦ˆä‹cBíÈ F¯OX€è.š¦LØÌÊG¡IÄí“bÆ»)Ñu¶Õ]Ö _‹„ˆj°Š w6ž‘W„”5ɯ©`F/º.£_1v$ ½LNx¿GÚP¶#ݤuWüõmFޤH=?_&Øf sp`åiy½UF"À¶Œa Ð8UЙJV{9çéÓ«œG’åçT‚,¿ˆ‰ûòÀ´D-@ ‹1ÄàÉ8%ˆ-å½T·p€IqPŠØQŠÃ0fPSJï ¼ŒÓœÿ%iLBÎ%lS’±o¼î8ÙÚ^E€Gt1›kYÈur1½+¦‚?õœ7@>Gƒe`› Ò·Å}‹XK:ñ„ÆUaëìhK·­³ÝîV+g­¦|$gX #Ÿ‹¸©Šçêh ‚Ck™©3Ð0h!Þ¦¸Ø°j<߯Ê$—•N‰®E>É#dl"ÚG1€pÂÜ´ ¼šÇÁU¿Å “¤ÇKYKÞ±½îÓ’!C6 -ÅÖ»v ¹bB‹."F=–´–é)?ÙÄJ Ço5Ç„”gœ^*HUpb|Á0“ï¿zÒæÜáY¥fÎG¬æOj“ƒ0Ò– 9{#xã½æxl°Iª‹6†øz'Có2ÙAF0 WC —53…%¯­q²fé;UØ}÷v$O] m5@…h%†¿jÊyD¤µŸ¡Å;L+ J<Æ Î FßÊÜ×¶"ÙS_ÕÝ0‰¥3ÒÒ‹˜´¢¸uຠ翲àf :N–¹Ž‚Q|6XTIüÔT̬j’7(écÊv‰DO+v1ø”çx¬Cü¸ïÎóÇb?Ï9#å¸ê.°²#z#ËvjuºýݑԻ"ˆO¤ÉSh¯‰§™d²µk$¦U¡="̬,u#ÃvÑ aÜRé@‰PŽD±L„SL¯×êº+>®ÃÓa Å@Æ…sôbfiKx:æ¬\qðM1ˆRô*o.@¶¿jÊ£\¯GWÂ>j=Ÿ[A^®!SPòr\rA¦0í’ÁZ´¾L¾¬Ø-‹SqRÙº*’¥xüMŠwëÑa+™¤ôJ”hÜ‘3ÔáBšÊYhå1_Æ?UqJdcUa… MÕû\s£³avÎ"pV•o¤Ùzäü5kŠþº(/æ‘zÙ6W’Aán(‹¬u¢Í‚“ZÇ©ÔÌ1@æ(ÄàÍâ´ 9o燥¡ƒ+<:§›º||cUŒì^W–H›(O¨e¯*[³4K"bmc;×§Cå¹IM>…Û"Åuv–÷Î}xUó qÔVíd[j¤ÎÔ:0¥a{cu4ÍÔkÊþ|pô›oºÄì¨ØEö~œuC'¬:¨>Â$Üöz hzè}˜œÆH¦y;Y€«c{GÀÕ3ðÉ3×Á÷huá‘RvúY2F+²f0Þù´,šÖÑ¡^§ŸìNmÈÛœ¶Ý#œcF=Ê÷bv|êÆc˜CéŸ~Pr¿VÞL@ÈCÀþåOWd‹z¸s’I±<ÕåA:`ÐÎ0B›¬C›S£ N¥: ÚÇ&ÙÇ<¬/›/Àªñb3ZM*~É= ð¶‘lc}yÛª=j×;‹paý[ñe—±Ì8¡‘–O°è0ìJ¨ò,Yüd…r9H”‘–¥öyu·]ØÛQа?£H¬w®Í•# gOtÈâÄN¡™3´)›5 —'-|äÛ†cY>;p³¹ªp`bÁÎ>'­m¾ÁòNîà>Òá¹è/cÚÄû¼ Xyã˜R4ý¤ôµ d#‡GK/|:s«­¯¥ €P W`âëlK@"Šõ…Â',ž4€J„˶L»'ÙdçÝ9&­Ùl€svw£¡¢ý–Å|ìÄ‘¿BеÔŸé êÍÎÆùÏÅU0Ÿ€ÂH~ÏbshQX¥㼧qõÐ{8Êî­Á_îˆ7aLg¢ZÞðŠiìÉ¥ùÊ[9ŽXñI4 oZžš_ Û `Å©Rª­¿¨ÚG ßÏ iM'ûÁ)])™$ldc„‡AÜâ¨C¡TrjTVãõŒê’‰gDÐJ1ÅÌcÿǤ"¦ê‰ˆ¦ø–NU‰½sð7©wÞÊñRš¿riüº¬(W—?⯹óœÃêü"æJIª}Vh•ÚSßžæ­bË\y¯ïøDš«‹ÎÑ÷뜘ÔE‰øˆÓ³ ”ª<φr~S!!åU± “Lël@öW'±54ë°aï—ܘ˜iÍoKG‘ôÒêŒóK@,Ç œ4(ÂUm°SnƒÅ wº?ã³ã;i… Çb5²'Ù¨ÔþÚî†RŽÉ«ôÛjò€WÜæ­ŸÙÚM„^U,Ö™ò<ˆØE.ë¡ÑvFË”¼›q;ÖL3rò_)YžF;ÀÑšËäµ®Èl´@€“E ž£WˆWÌLˆEìýO[ºë‘Üæp6dçÒq,á¶'âi"©´r^ã|/`Ë6ÈBª%¯!Æ»YžkÍÊE€–|žC .‘И¬'íšl}eåRÏ¢X¹JJ‰FQ•$†–‹ÝT+VkÓí§ª•œlÛþ±åðäes×ÍÆª°¾4ø¾¨©]YƒY¬?¸*… ø•ëÊð%¯dRa›^|Ä[q,öº±š1TΟ‰_±R¦>çjt+eL¢¬f“@J™ßŠVŠ€ŽðBíbSÓüUUv¢V¯ÛËägSSS‰žkg`›   Éß@`ÛQ§Û(;C¦ bÌ*ÜOu¹Ý¨X0hz ¦tÅp&ž‹,P¢H†%Nû L«ÑC0+Ü1È È7>¤Þ·êç¥VâàUb#.xŠñt!E0ð¿>'zûtcWp§Ï89ŒòÓqžF yñÊ— ’ËL/h¸ÿtazJBÆÊÄú,)NÃĽD:òui“~̲;/ëž°ÚúY#Ø ±ãërWÓ@Ö¯½Uö‚é>#5Y±ÌÔ{I(¦ʆûD"­˜öâÚט¼ïËèŸ"$"`. W ~# ~_¦¼à‡8â÷E³w á´dµ)ø‹¼‡)>y¯¯R_y’o9`§•[X>¼Š’ žXIù\~ÿcëáuëá^‚Öò,?¨}j1TKr×Ö+ Bˆ'õ'MÔJ YçånW‚8½$lñÑD:¬*ð””ó;ÛE隺*ÑÐÜë–:žä‡Â·?•kVvý6ŠËùćô·ÂF¡ï¼R²„[¡ZvÂ ÙøÑš0£»” "áÜ5K”‡)µú½–×23UÇu~¸1Œ÷n^Ï<Í*?)ò™çæ dhyëÀg¾Ìï¦e~dik;:Þå÷þ-°‚¦ËþßX °ÈÿŠÐþÛf£TÚ ë– ˆ¨vÏ&àµìˆZÙµüu*þþb®-$c£n2LäÛÛñ¡|76^Rp3ØÒ!%·õŸÍ4~_ÈUÃ~~“hÙoÙe_÷¯+RÐÙÁ¯”èy-ƒ½³Æ“ª—uÏt½—~Í¿?NÍÒ‡¹³e*ʸJ7óoÜÓÙܰ\8Xá©…W+½Ãú6ocÉï.:(‘“Å}‹î^?†e(DHmj¬Ü7¼Híâ'ñÒ¹—ê\“Æ’ÔÅQ )šwzùò^¾ý2ÝÀ®úÚ]JV¤–ÿ€æ]KdÅhð}5ˆýîñã¯||¿:ø/®cÅÉendstream endobj 463 0 obj 4522 endobj 469 0 obj <> stream xœå[Iod·œ›Î¹åÒ¹uÇÓo¸“o<6`à ØIÙßûjmZCÏ8˜a¯3:#÷eù8KmVÀôçÿf®K=r®ü—¥ár`\Ï?\,…Ócvþ5>ú|¡ç_.–rþWüøF|=,,É |Uó,¸…Q|ÒKÍŸø¹`ùùÇð†pe°‹ÆÑ9?þÏð³|L¿÷q$dàkìýÏ…Ä>œñßò°¯‘ªzÊù§8Ã_€îgØæ ƒ+øh±äó¿-ÎÊ…›´–†±£“ž’üä»ý?~£èFŽüöJÁgZ˜X›ØK\+«¹ðC…4åØ¥Ò ƒ$ùÃÈSdà%  ¶¯æ/ð÷5~ü”ùv•p=ùH,þ7vzƒO¡Ïþ¼Á_€¢Ñ“¾—Ýih}G¦‰GßÉÏôí"ÓÐŒò.óób‚÷i;óóÔí¤êæ‘G Éj¶MÔzt?^F¦„ ‰'øA{Ëì8ŸgБ¤Â™'ð#Sð(ŽËÌJ|R#ê Ÿÿ óHF žû<Í-yÍ_²°†Ôø´'¬enÌ”|‡†°Ýѳ#©Ç-ņûôÄiZ’…ßÝAçÕ Uÿ¤ÖÉMò΃î¡0™óÛ”FJ¢º|±·ÿÇo毒(Ïó„Çø›6|>HC€ ïW"E!/ëÅq‰e_‰ƒy%õ=JÔ$õ»yIp´ Ë ®"‰ac~-¿±Ÿ=yßçÞ¯ƒ¶[¸Ì»êìeŽðƒ<œû ßÇdén縀Ö)7ºŒ¿Hk4¦ônnñ:]‘—=\RóÇ~œèéÖTFIëe”Œ]gÃø¦&çUZñûÔÍFöÚ|çïÀ‘8›,Í7^g6çžgy¿'Ûmd*›ç½Æ«À9gi+þù‹üüU¯ñº×¸* #•ò /s¯nŽzä®›/+ªx”D-âušn³ȇCö@ºåǼÉ$<ª´Ð§(œ§^Ù.²’®WÅ{ÝÇAj¼ÊGåœ1dm¥¸ bZúL¬¿Lßy%äRÝ2ÕEkA6~UÒ5tǯ‰pM„Çæån"QÐÒŠAPŠJÖ—6¡Ê%Zã– ZÃË=I"?Îüi͹Û):Z¿´ó6Ÿæw×Òæ%So\ûQ½-xl¦=UwÛëÒ]§CIÍdJ‡hCÙÔò~|àìùIÕ‹uia‹Æýá„ù–›iP ¡gç¬m« °Ê‚²×iê6È&êɳyÒFä©me„©2ûRj7Q`½ŠÔHj¯OD;/ ØyŽ%ÇËÀØÒ”£5늳^E•aYñ½³>m„q 7…üQþ÷ î¿\ú§ªøu³ ÄAÍß⊒"6¶½Mƒp6ÇaEMä^ÄqT¨ÌHVãhÆ‘çÖb‘ƒ§¿8Çê2n|4[¯¹€.Nˆ«®ÂÈ!q )ú#œø2¯þÜ/dߤV¸¨ø˜(Ï%×íH5Äê²ÚHl‹`u:Ž…ÈqãÂT¢\³?RЬ@¯6C’a7S¢—˜@\JVåëN@Ät+frƒ u1²žt|E{¼ò΀{m ’nX߀Q©¬ûÞ¯°‚÷Ü$]ÀöUÁ/œ;Ôðg3¸‰êgâXûg£$U= Kœ.P8NM¾åJªWêd!¡ÇÏÆªèRºv])‡ŽáÖË\PœjÐá ÓsR ÝSš.ëbØBÉ–ÂÒÈ´ÑmÞòÈü­±škbÒ6}?²WçÙŽ‹5W¯3ÈÒ12ot|ǃ¨Ó ƒ<¾°pxT޼©(w¼„£Èºâ8 –œ½0¦ð'å’•4¹¤äÞ´b’+ =OJâ½$†(¬©)ÚŠÁR~ ìÀ“cçÁ_숕y)‚àÏaÿÒj€&WõÕ`} qFß÷· ÝÒRM'vš¸UNù;äºÀÅ>±¼"ö ó ¬%”\ È)6pmŒ¶½ÑIaªr»=L欌Ö-7A‚}éc2Ugû²§ˆèÍæõ‚WŽÂëC  Õ’ªqpÙD9ˆCI4*,Ñ¥é³Q ?Ôn0ZPæÎ=¶Œ‡MØÊ°83¨¶„©­ìk ¸B Øo Ä´÷`ù8#S…ôÄHnSkO.ÕòB &°¨ ¨¹mYŠ­ë:gGÞûUÙ@¶¹ãdÊâHÑ„4X@$~N l5rʺ”FYâl²Ý.‡´B­æ;/w³NºgnvšÒB4¾…Mt ƒÀ¤ ÒpeÚ”TŠ$ºÙ¦²êìHþ6s2@P m9h’'ÄŽ#/ÂÉ* Cr‘ÂAv§EOAJÞ«øÚÒŒžüA]¯StT1íSÂÏ)ˆÀ y~¬k¸›¤žG15Ÿ ™È‚˜×H†ÜÉ*|ÀªM#„¹®Ã\ÆÉQ¯õ9<¸ð)Ñå³ ÎFŒJxãq jÛÑã(¥2Ë¡Üðö ÂZàYgàÀaíâ Ó 6JJH1È9¸Ð®/{"ݲ“d<q»"CäWl2XêY/aâKëMiç”0¡…ô„è¬b³ºÈÉLö/åh¹Ó|ejCÉz(¬õåúU¸’ÆI5<’è#UW*ý²–9èäcýØ"÷IЧÓУCß™Ȇ,°´¡*„#ÉT„]B~çs¹l»5‡[CIà˜\šd¼[WP;T凫ܰÊ ^%÷Ù5p®`&õŸSëãyƒˆÁå„ÕjÞ–dÍ6¿*ª¨íG ´ÑK4 ¸è¸¥ßl ðÌŸ±TV¹ÆUÊŽßÂUƦ¦é©=Bê-¹½ça»í¥çaâ^w‘e_¸¿—eÄ̘‹ §™KÑUUäæ´±Æ’»Wxîþ‚À‚”˜Ž2ݯJ±ù ¡èŒî A Ó¢[B%ME|P= ªÜÊÄ(h²ïž?»ˆÄez‰½]6YZ•™sg¥š‚6r˜¼©Nx”b*IX‚¶Ô„häUSí*ÃrM@›ÒI&@Tåç?†mu3´ä×ÕHÞ%"wÚN±"ã*Ì“‚4''yoó×Äó‹ Ñ®N=?<*ËQ~ |†.ä<ò˜%]á¥@ ]Ù–OÌ T&›QJ:oÂL|#2S">eûÉ¢Bœ”#ˆ§ÆQ"üö8Ó¹ðVvHÇ*f9¨ ˆ¦sRpK; ©x,à½Ø…«R±¤^CNŠÒ<ž¤r±ÎÄLBÚ}^šºâ)ˆrô»Dzëž'Ƽòî ÷yÅe€ØˆÈ tj¸ƒ)RF]® ¶T–Qý'i WD²ƒÂ°äX'¹ˆe¹FÄïŒÛAùÜ’…ü ¡ÿ¸è©B¡DÇÚ8}~“s2O°P)UÙé(Õ…jE,¶¨“–ȃÚëWæêâÁ{• (Bç/KN¥ëWcÌÃ{U¶&€Ø&[ãLÚ:[ å>è:u žÉæà"fœÓƒ¡®o»ï1‚€òÁÁ'æõÕB¿ž6Ýãü@hHˆE5ÿ#Ñ5V îõ(F•ñVþ=ÆBªŒ) G‡÷:]á$?¤i-€ÝH´”™EÈ6ºÝR‹ Ð☈s‚ÄO'è×XЬê+†²”°#´¬Í·À!f°zt»§jeõªêMõJ‰Áy6¨$€àº7À«ZêAŒksd¿SäªJ쬚Õ'}ßµDm@LS¹1¹ÍdóXÕ^O@“­µ²[sˆª«ÃÜS)5ö±Ë¡-DÓ#c$4UõÉhx’är \\ ^TÛ70RpµÆî¸!aí²[y·}úÚÊHÕÛesl³y—õ¼ë÷ªµûíu³5Ç;÷é†m–'SÍ6mw›»Ã*è:F ¾Cl<+«]‡ô&»B7xßçEÎ6ÒÈu•ÔlF Èó.ÈGÖèZsj~A%h‰¤;@}»Æ³,±ì–µÀ\H[¤ÕÁÏÄj®W¼@øMJÃL¡f•rmÏ‘lw1È0!š—kÝ ¸ë»ŒÊ1¶Ê´~Þ÷ C¸+1aï±ÒÉÀI«ôƒpR 9Ûî§ ®e7(j{D°£¾E¢¾Ž‘Š Zü:|Ô¾¸;²q³wÓµ[ÏŒœ»lº„ð‡xäþl…Éü*\Õ ïÀÖ\ÝxÔ´TçÃJÞRªýyÀŠ j½..OÉy¾â@U€”ÃE¨ãPc)þÎBäsM?´¹bµò—¶ÚZëÖ\Ù˜dÊ´ú¬Ê&U¸]ìâö·Yëo›Ì$ å.¦‚ë즒Ï\&/? fÐ3å÷|o.¼¥Ðå<« ä¾dÝ{µ%hÙï°»5_çûbˆ+9ãô¬^âT;(pá-H§BmÀÎ|u1ÀÍI虜S`¼@È•­r£éw¼¯RL†]ÞV99Ö马´®½kZèbZT삳%¦$ _hfœÆ™4fÕ¨µ6 þœ”§=À  W}€0ð¢ èlÍÉÙÄg,yÎþ)Mîß잘veÔ¿${’ç¯N_¤dˇ­«÷»¬Ï^H.ï)(çO¹Ü$®#O8ó/À…k¬xKÊ¿£<|HÓþ}/Os%Bˆ#=é‰B£ìhË3Ñt*«sÐ5hyò7´Ýê(G…ãíh¿ºè® A›N-”'!»ÆL0Þu$¥4Ü%_^ž×DÆÅT:0¿;•¢Û÷;1ØpM!¿ÎÊòy?p…7yH<ËÅm¬­Î¢¥³©^N™ºOj¬¢÷ª˜Qܾ!ù$1¥—­î]-‹²½|Ù6Þt©aãX‹ùÔùºþï™—eBÝн͈ ú‡Â®U«ˆ¯”T¯{.à'm±YûýU  ¾áq‘)½e–ïSzpzt|Oç¿U—ýH¹¿Úû3´±endstream endobj 470 0 obj 4303 endobj 479 0 obj <> stream xœí\YoÇòÈ_±y›µÃé»G±’mvbËŒÀ6Iu€äÒ¢äH>þ{ªªïžž=(*q‚ĵ;ÓÓÝUõUu]³?.†ž-üÏÿûèìàðžY<¹<z+G=Œ‹'?0³ðÿ<:[||ã,_p¦G'0Xr®™…yÆA‹Á.VñS¼Ç‡aa†ÅÑÙAwûÞGŸ-žÜ9:øú`Ø´†‚+0ÕÈp·I¶0f²8Õw\®T§áÏGõ°~Ðw­’9µ4l\Äk\ãµ4Ó'KÕ³¢û| ƒF˸í>Z²î«åJàÖ-ý‡;KÙÝ[®¸á»én¢_®4—ýÀ$>Áq«q”æïKÕ}–fN7p/ã·ôénÜÐß`>xvÅ€ÇU÷íRâ©aŒÄ+Œû½ !aû°1ÕݾGy ðfºH“Þ®¾á³0¶˜ðË@Ms¢o"÷G»`²RóJ\Ú˜ž{>+˜×JÅ4rLôFZ!ÇqìG&ºÛxUÀ}Ù=&>j3Èî?Z|.¿z;3ŠÓÃ'Æ4ÌÚ¼ýéÒý`‹ù€8Ä Œ¦¬×Fså¯òæòW¥RÝ| p¥uc/šÝ%Ðt*‘˜ ËU¯í¿88úówÈÛî)üÿ±ÃÐ8ŠîdÉñ+nŠÁº²{ v/ðŽ2c·>ÁÑ’w¼Lÿo.–ÌMq GNÓ>Ôã× XÃ]<Ž¢P¿ÁiI¢ø®àå‹7^$DÓ ñ¸è)~{ƒT´‘ôØúÂï‹8ö3ÃÞO– §’c>ëúÌ™àÿEP¶÷ÇiÓw=5È3x¨M ò_pÞ ð;:ÈÝð3Œœ6ôt™Óâ·[R[Áë%SŠñ?-WQ—³Ë¸;cá†vÀG¼Î»3¤jõ8æc$kpžàr8d abõõÀÍûG[$ Ý+OøŠ‰^‘DúQ„¤õ”}Da¡dèɯs”$6­á«bÄ5"wÝÍtì ¶A€€Y„”„»ã øÊs™}õB“(n6ÂZ(Kòþ¾Í$Þà‚ˆl"c]JQA›ñôOìÄV¦ëÐLp¸ª:N¢H<—\,gDZŽŸÞ|@Å~ĎΤž&]|S./´&š‰¾u«´\ôµ,WK'G9J 0ðÄ‚á¸×}¿Da 5þt©J”yäÚ${e@,D 5A;“]tÀ¨!‘wmÛ`Åi%OŸÖœÌ©³'Ñvehq6•Âh3ާ–ú)¨œ’ã€6NÀ–å°ƒ“„0˜)e[æŸÙ^ 6ú©‚Q{·ƒA&c jЧ¹1™b®ÇxûÒ™AÔ–dƒ×§ "Ùtë&T%äÜ\zF “·âbèµ\¬Àz€5-!3^–Ÿð(ÅC”ä¬Z—¸*HÅq\…}:=÷O}uR Ï‹î=üsÃÍô,Þ?O¼x/"RÝÔ²û \E’Ài”•Ñü†Šté—¸ÿ›a;n¾'äˆî7`âhH™§tùçîã×óx÷Ômžˆu¤Ý#eÌùCAH]ܸBåtîÅ5lý—¸Ã›áSÜ™Èo¸kKJ {¾ŒÃ_¦‹÷s Œç~.0ÿé2lCmgIzê½tŸ•çùi©P°uÓx޾0ÿüT Ûó–èâg)šfcå` Z¥&3¿Q(E¬GS÷&žÍ¨æ¯Ñ :Æ£éE+Š_Èj<È3$EZR¶`}ýý¦Md⌼°‰}˜`õ ÷°‰ce逽½‚#ѹÜ‹+ÙzÇ•xÊQ‘‰pˆd†1³¦g§ÄÜîfX'ØË¹cÄ Ï1)ô„c¦˜H§à ") èòËB¸ž–} Q?šÁaüXTÃ|ip`%|Ñ͵ Ffñð k•¢¦€k ÃàìèhºÚ¨ c[‘{4ÍÙé„Éf9Bã™O€:.ÉoʦvŽ xåº2ñ-Ù•Lä2ñ„eçM,³^á¹—$ƒÞé ¢ÄF-uÓœbœ¸H w@²)‰ÁäÇ¢)‰BhÚœÙÒÞ"À·“t±Ä \œÝ$ #æe ‚ÙŠèá„ ß…t»ÈÎ`äáÓ!Ø(}¯’ñà§ðaˆÜ÷`½lÚˆ®söhs]¼—¼ª¨ñ™I¾®ís"‚`ÈND4£«×)¢a¤Ô€7LMA}\*Åse|é “!’œ5“Ù…Q<óQ¼?£*ºÜÓã xÄ×-IøÔ/3L®@ÖÁ+T!òÉ37BÆè’¢ÆWÞÓãp^ú—nôE¥&Å þ4šàf³¤,Ob&­>B€£þ·Û†€‡FÕ?œ”)ßcBJZâVysÚv-‘œcS/ƒ wŽ;7â'´ÖUü„ƒ‹T‘dCð†\t‹4e³"¼^äÎ"e:àn½Hf_•ÎÆ–tA¸ˆa3Pˆ™ªVn(K!À~GO}˜æÆrSð‹^‹´³ŽÞ^^K~°íãµäæ+¹€˜ÀlpœîÁSvùYÂ;=€ ⊶õ‘`$‹áÉ"1Ão’€nøNž¦ø· 7]»$R ½q¹:)ƒOrR¿sïÄçy[Sx/2[¹“S>c=ÚÂÒœí&¬èM¥¥•´8Ik°|Oi /.=mÄMÅ)(ÅeúBT‰ÁåVÆ^¿ ¬¤³Þ‚Ygv]ÜržWïœ{ h7û-•̰b¢ÀiÕñ,5R%"š  ˆ?’érµµëè´Õ±¯ðDƒé«&³ ø*™ÆïyB¨ 'D,­ ÚºÆ1ÏôÔ“3£ÍžP¯wµËœ‘j«¤MV(3Ùsn5×#ÀuA)¬ÛUPÞs9h±Ç¯·ûó®‰Tv/¤1๽C¤2°ƒFã:@E®éг°yÃìDÓ‹³Ë?™šÞÄŠº1¡Æ]w¼HèYtnߣjBºg¹§„&DYɆ¦[bщOc¹‹Šüjâÿh”^‡¿e>¥bf±³H«wÁŒÁ—Mö—óŸ`+íCKR¶îŠÁÕÞbÜß¼·˜¤ ^Ý<à£Ê5€B×<¨ˆ[1ƒ «ò|o¯³FR)PjÉð”yw: Ê *«žaùé' .lÆ«±FO„à²Å>ÁŠSúÿº»_¢c“êîÇ Íá ÆÙ!û0(ƒs2í×j${–IzOteÅ®ñ^jö[¡FUdß½ºÐRèm¡¥)¸—¬Ñ•óD:¥q^Ÿ¬CË F¹ò(œèàH¹þ4 ÿk›O]ävϼ8Îh!eâŒÜ–# ‰b5}&!üU[²&Tõóº‚'X´ÚŸyŽÒs¡iûQ0¸Ã ³;Tp´,w[G&dÀXVôÀ«Ñç§EŽÊFÜÚ¯¼q#ÅÓÎñ‡é˜"çŠîÄþI-ËP8ùÈÚeœÀš‰Ãš©v(xä5©öÕü‹VÁS4¸¼CÉ3)t•¶‰¾Àü²ŠLMuVæí5eãÙË,BYR¨BåCމC“?ÙN ?)SOCïn;¥ñÄaøR!X•§« =÷`°²]êõ`¨Å.éÉÁˆŒcòÆÎ×8báÇÔ“÷¸lVŒ „ô}ƒ+¼ºÖìí‚™¬kR3ö¡:–¥ÙRbD¢®ƒ rßF®ö#ÔÎ'e÷niccÂd¾e[î%ÆfWЧ§!ÝFÝ£œlõCOø“ʘïuFÆäæ*v0±x¶µ_Í Çh¢…ÂbÊû6²–ܪk4o§…Ø·¯»ic†žèù™Hn|cmÞLÛÉK«pï “_}žÏº<0rí¹ù–î» =Hÿç•=lqüIkÆhd‘ͨ"{.Ãù}£`©Ë_”Ó—“än>·EÛæ®ÝoÚ¨×-#Wšò†iI¬_·àzÑd}󤻑ç9w6{ŽÞ_ÞËÕÍ„”iˆ?|òWY .Á ¹.ßrg›xSÆ\ÄóBÃVŠÞ@4[ªXr/ŽËÃÍVƒ`K5¾‹T4¯‘ë¢ûþÐR(“ÏÂÔ3¡ÎœÍ6ãp#‡ËÔËîH¶G}sP$ÝJ¤G}HæsÖ›€ái¼øC•¨šâ¨V(øK„| £S¥ÿUiñ}oíÓ¿W/Ü<×äà_üÅWkcŸ)ÎE‰‡Uó-ÏÔ)Õêì)rÌØy„ßÏ««eæ-d ªÍ”®³5޽»ú«3Sh\&c’ôoëåiܬu’òCÖSWDt1_’õ9eùÂ,=÷²`DöƨÓ@é^AÒ®.á†.©bìvQÊXSuÎûþ؃Ï^1¸ð ,²ù÷žZQQ7ŸsƒðMw.t÷ïÓNP1“œb€fwŠÒ’ôã j‚äeBtˆnÄ©¢q¾TJ –]òE|¹?C YT‹óð¼9¹¨Âô“ä3þò£ ûшò ë^§Ÿ’ަÁÊeIŠȤ­æÍÎÙŽ²Œ^ùQ–Yí«7ªËtßá½±|¯UŒº·óþ̽K‹Ò³-VS—`lÄß¾c ÜZÀ00–úÛËŠ;Ÿ>öT¤–É%Ä ¼Ù '¢m%uù8Pòÿ‹;`©nP£wM& j+1¨Þ¿áÇGµaK’ÞµJïöâÈPÖŒü«X|Tó¶V$‹Ýa“×Eb×½ “cóçêå&ò´1×Ä\½líhÅßT¯±eøÌ~##2G^ƒŸVÆ›d®«qÕg¯ês«À{ÐÆêqïÓ¬“Ÿö¸ÃÞÖîí€mçyzµÊ9'õÁMåoüÁœÒÅ$Àšø¶LÙð¸ù "×ê¨nr¬Om?úeOd¨KÔí/`©>/W 0©ëåõÞŽ\më)›"öYìwTÊÞÒ¥bÝÏ0ÌU²+¤ÆµB[ÊnþÚŒ– l•°¬|‹ôö>¥í.œi.¦4 2_jwÎnæaYÉØÐ @ 'ÝPñ·/Z½Ðä Y=íÌð?Î~J \î]_Ü7C´¡{ƒÜÅi»4yN|ÄwÝâ‹iˆrÍ u õ²ü¥ŸÍó3úÒPcÀC$DsJžÌíeO•b4ÿA&ëóÊs«Ñ´¨«u¹69ðéóN›¶þ ša~ wÂΊݧ&ÅÿÒ³ÎbƒWêF1‡(>˜ù+˜«´ÁàOõXù§àKcT ƒ3=¿"ÞÅnyS'u£Ž†0W´¿> ¾>ø¢ZN_endstream endobj 480 0 obj 4651 endobj 485 0 obj <> stream xœí<ÙŽGr†çy? »-v)lK»ÚÝÅJÀ»†@ÑNó&gwDäY•}Ìl@ Ø]S•÷•õb%&¹ø/_<;ûü;¿zòêLLÁD'âêÉÙ‹3IcVùëâÙê«sÔJI»: ƒRN˜' §EXmëUýM ±òbuþìlý›ï¾üíùæüξ>?ûöLZ„*­ƒÓF&ˆñ2®ê=¯`ú€óÿym7[»ž6zíÒÅÖI= i×ÚXµþr#%>k×ç›­ SŒÊÀ¥^½1“Ò¸õw›­^ÿq³UÞ¯ÿ€×øŒ¤ypà¯7výÍF®ïÁ7ŽZÿn#ÿûü?3Ôˆ€(ê„Z¹²ÊM`Ò l~³€¢•*=ÃJšIGÞkð™­l6®ÎÒî4PÇJ‡;Ó“·ÑYÜiŒqŠRÃ&5ÌiŒZß߈I í_¿†]NÎ;eùå#€{ŠÎ ³~¹Q“÷JÆõÜŒ iÛ“3Úî™êb”öA(gÖ?XRº°~Šðy·®pN+„_?ÁgŽC);¹ àò÷gçÿògÂ.̆Ði„ƒçoþi ˜õ$ÈKüÀQR­wñÛ!;¬ŸÃ 2ÿÓ“4ø §T4èŸî‰;ÒKØÅ‘ÁÖÄ:®Ü£§£éøï˜ñû2ÚÐèW8Ú"gÑ2+cížçU ®‡ø”¡a7§2-³îž54=ÄßX'Ú6qâî|МoÝe׈p ¡€ ‰î$D ሠÓuøX¾É HX& à¦TaÏ€W[Œ.Æ{¾~Tg+.ó/ нk—»mêöÐl6 ™Å=oÓ¦·@K ÷žèbèÿ›Ì=ø×VD½^# q’çGC£”Cn*ðsvRAä¹3ýÒ3p_ÑB;z–>ÞTb#.²¶Yïh¢Kü¸Æ»š¸1¯@b+m¿À£ î`†SÄC|‚—Æ›p£\ ~FéRžf†%–a¤¦¢ žþ»JŒMx*té“!ETn"`zÅ™’qZ»yý¼Ýí8¶¯ˆ†Y“¶¹šReúXÐ6î'4«Œô’… QÇþeSæ©Ëˆl+ÿX›Õ6ȳ›„z[iø1ëmxZzã -;xëQqã]«,¿+Q›)  t|ð@„÷¨mcðÚ+ ¯Á»>Þ"ÍúŸWVØ0°KPèˆl %ʬ˜ à[Ä5\"`I—¤¬MôšÝcÓ´Ë¡—“aüK$°!­ý& I– dMäÖ]–›*LÏ ]rIÊÌ›Õ) i¨~|bÁÏ\Ï*éyœýU‘9ÃÔîî²J)Ó& w7iÛJ»Ž™"¨˜¼i4@u»zý7ü¸?îÔ?Uýó~Ü­bŽ”Zÿ~\ãÇóbÝÖÿ€¼EÒ#lö¿%ëD\zø‡&Ûm—OëïÏG#ßÕ›OÛÍ6'(@<©”¿Õ›WmäÝÑÍû|?åæ?ÊMÄ"ˆŠIzÙÙ@‘ÕÈày_2cÆÊD±å¶­ˆXz²Ã³U轄DÚt§Šm‘šªðÞ-&4/óŠï,­oÒúE•&½Ó&½ª7¨2”öxÊÞäh†zÕFâZemðomC°î¶§.;~bØ WH‡9:ʈÉPx5i'™÷‘ˆ9Ó\Qo'3žŸG†1¦ò‹JõWUL>kü2⧆.:NÈ"YaÖÙá $ñkáÔ$ç‡aZTK£gÌÉdùü HwU-  )rκ3I˜ó mÀœÀ¥åæõæó,¹øæ+Ï“cËïýÎ~ÏŸ_Žäà–3ü_pvd4G7ÃÞw;¤úFhî5ÄãÂ`vˆ÷<¶md&AË=ßùŸB3ÉÔ‘KUŽRìN“èÇ{ÉØ4ú¶£XÕê7””«úëeáBŸ\hñÃÌp5Âó%í‰ãkÁ—yòŽ/‹š¼ ½÷Á‘4@ØËÈÁÚf£Iþâöw9Pi¡¢Ïù ÿ‚òàSCNM ^§(»4"ò•<¦)„-úúísA‡2ÚšPÆÌÙEöྯ0%@¾2=$Áo×9d_¢þ ‹Eÿ£ttÃÙìYŒ§ì×”À蠀ɥX‘+±ç2À´@ 6öÈŽUœ€%ô‡ï8q‡7ÒúaÞHMEª[=׫ææÖœÂ)à”Œ>N¦$­ÓïKѾÀë=q_ÖžFÈ6ãœáD„ÈTIw3"šÞémˆRÉCs3ʇXÑ:…WBÉ9ÞOØßSLú…(Ôp‘¸Ëü¿cÐãÛ/S/·5Kv¡ªEOí£C#çNIRälÇN6hÏ!&Õ-‡˜p“¶ÑûÃîw&ï„tó]U Yvæ(Í"ºd·‡SÝNÌ#ì^Îí£ï„ÍO…­*™¬‡Bìs? ÿÂ+¥ÜxŸ[cýéCøK„ÑÔ¡Ï™]ª‹$1ÞE7LC¹ÉñÜ­—äæ$çÅœo)\:κhk)D¢î—ÊeS=kqqeíËßN*¾ P¸9d8(‰y&мÒ$¶¡Ê΋è-Gå-êu%¬ÃÔ›qÓEXnúêÞÙç÷þ°zýòÍ£³Ïÿk%Ï>ÿ?¾úÓ¯áëÞoVÿtöõ½Õ·{ëC3XK©E¡ëj`ZŽª-%8vøç;I•Ý2°éϲòsßœíC‡ï„ekО?çFðYÓ¬hqBðZï±¹QíÜÀž\ ü]‰rXw^ëi¿í¹¦‘¤i¯ €tDªŒifñTMmWyªÅCÙiòµ¢ÈyžgÏ«rïe'¢ÚXJd8E2Ìýôl5^TÈR«Î€*á”Úg@÷úêûé—†ŽiØü°ÙyÕÌ![‚ÖÛitªSüÈ×Iþ•vl§gV¢Õ†®/jcf4Ô9>ZÔ½–õ‡1B¤™æ>²¯±ÏBH„‰G–ÌS$­ú½}q c…ÉÈ0^†ˆBQNœ÷ÇÔCöТÑû¬î–81˜´qˆ¡¥‡f¼Î.Ze9ÉbÕ4Q·ÎéÞ?Ì$ÐîáT·áœXSáØ6g¦->a{\ 3Ô¥Šç£GÓËž÷ù<²óŒŽ9&¦}Àá)îÿÉóÖ¡ÅÛ©óîóv¦ÍL6Õ=¿Â4Ç5¿;èÌ—Hïã|iböa?5‘1e‹>,#ò3,^{-qóHOЦ™-ñJá•”&ŽhŒ"Üi"ÞåAIgáDt³œ3 ‹ŒÖÍê»6X#inµƒ…uÖ†3QÌõ&%œÓL*uŒ`À¨Ôx´ÐLÁO4ç5¥cÛÌ£ìy]âɪ0/FÀ–z~Ôn~Ƴò™TuÁÔ”À1À ßðûÃÙaÜï¦&­`pí\â†Úó0Ç£5­ÔA1Ö©ijÔ&C¿¿D´JÞ3Þ¿.¾z–@ÖÛ¥µYüòS/áFÄÔhSɺf¯2Í÷Œ!®(êGQã ó—}K‚R%t¯Ú!•O4E—½ÿÆ›¸¨ØaI!ao@°‹@H5Í·èÞ³mœ[R]Ý "Ÿ ƒ¤Pj  ±û x ãSÅ&·BñÖCýuÔj¨ª|ã>æ.I ç±ÂÅz?RSÕÁPŠ*EE¶IÍo÷¡Ù" õ0ß™æ`½¯J·¹ò ƒ(<°´-k†v6u±Ê°ù Ð#¨rŠcÐDq–¹Û±ë-{-ü|ØRUÊDÔhÁûêö¡´"§¦š|mpʹmz°våŒ A6³ßï+:b“mzœZý?Ô|Wü¼,ÉiåÆX­Ó µï åM~‹¾¿eGgn›¼mоÕ"@¸2Ó°‹´«ïœÈDGBp);YŸO½H¥YØ›<\Dœçf9°õ [\Á³l¡ß\LB#ª¬¶w_b_2k¤à "o±ãM@ZX*«¥qz-l/ˆ »›TH†y—’†Lº_hS¤eÂö®È'Šfpd.«…CÑãÍÜ­ ¼µ÷’ž¨=ŠQ“š û<+;mð hW-$-7“w¦DPGô ÈQO³{Kݤ‹NºnÝ¡­§3ÙÐËÒŽ¬ø\½î(“=YM[`“{L¹Õ/÷Q[iý¤çýÞÅCjtìIJ=s*˜VÙq²éҹ߼UJõÒO׉Ч†RÖVÞY•¢Mâ{CÌ- ‘R2—8‡é(†›s"CÃéÌÝ$~¢Æv 7†k3”~_x„‘¤ÚðûÙ@`š³ÞË~Å.áB]µ ÷}°Á¤·ë^HT¥ñ çEÒQ¦“%{<8¼’%=¦A?‚û–„Û­‡…×ÓJU-Ôvè§hJ#ïëIGN€¨§;c“ÑÑÝÚS"UjnàŒ¥/‘ÜX’nÚ1­µ÷swO}iÕIÓªÉ7;oÃ3@ Yæt©Ñ˜ÃSEK©1AöJVE¥_Ž]?G£ô34ª÷è ì ÀÇëhŠ/ÝK‡"›¢TMʨœ4ö¥é#ç‚£bRËÌÔ->õãNtÑé IHªùÔC7'Fšà€ÔH³&°}˜Í-í?—3gÍfO,ŸŒgÍ–-xò!G縫*O2Xcõ Ö(ÆCûzʭ墲5"ÜÜôØÃý™ýA”íG¼2å„>ZJ·¤ËÆŠ&Pž‡…çYK`éx›‹¾Â#Ž{Q?!nÆöØÞ7ÝËZØØHÛ ¢:&ή©ö”ØÄšêòÌŒNIÃ"(%‰$“Z8DB0fgù¤¾jªÆ2rÆèimÊ ±(ÏíøÔ²U7Î3:i§¹w¬½÷£¦ëûÁ&á”Û5µwÊkIlj-8–ÞäÙ—A×Âü ļ¶ªÜ¤÷Ö¬ñJÊx6ì'^în6õ'±GÙI©æJÒüýË1ÀßÊèžú±¦šoÞÇà.ÜÞGgoVÜf-ßw»h1—RÔЋ‚Ž´s“Ò ö|ˆŸô "G>äwyµ2 Â9/£”rðäŸ~j• ?°ŽÂÏMÎëÈX°;±íoþê0BÓ·gÿ Õ*dendstream endobj 486 0 obj 4885 endobj 490 0 obj <> stream xœÅ\ës·‘Où#ÿŠý”ÛI´#ƒ'¥N~$V*¹³}¬K]9)•H‰’‘+K¤-ÅÎÿ~ÝWc»\*’R.fg0@£Ñèþõü~%F¹ø_ú÷ìâèî7nõôõ‘½V„ÕÓ£ï$µY¥Î.VŸž@;¯VJšÕÉ94ÖJY顟 ì$üjSîÊ;%ÄʉÕÉÅÑúóoîÿþd8ùîè‹“£¯Ä¾1 <®‚Äq"‘råô䱫o×zؘµ‡ËßNþ˜>£°BE‚·“–qŠV;V噲ø¬öôÙ`F!¤ŸÖ_Ð(x©üúþ ×_ › ßÈõÉn¾ôú›a£|€ßnmˆqØX¥G!5~¡°o±Uú濳þCí¹¾À1þ\~Õ»… ÿ‚þàÛr|nÖ4¾ÑÚh|"U¢mš4„™õç_”Viø²>¤N?Ÿý>Áo¡mÓáÿ y6ÝŽþ§p_MvÇzYçF•}¬¯ñr‰—Ÿðò//wÊOU~žâå¸0æ þ'^Þâå%^žàåŸÃF; ìÖ/ð÷s¼¼ÆËUùøa]›ÔÛçåýË^ËËÃçõaíóŒëpÍÐlâÃËÚò¸÷ðŸO~øÏü ’¬W9†äù1ðî¯kœÍ›2/™8cd@¹îLÛˆ@„Å/>%`,—á¯C~Š]…:H&Mzó§‘Í Æ¼æ3‹ãë8~|ú¨×éÚéeyˆD妌´ó);½*ëUm‰cå6¥Áïê§]²ŽëW/ybÜÀ[=ù9;r‹ÓW{rjœ,îZé<]¸Ð‘D\ß+ñóMþžÆ»9+«þºl“_WyéÉSe—ð$¤-YhÑÙâ\’×,©::ùշ럡Ù$¨‡8L+œl/?Ä Qº-jšèà±'r.º³0—š€>@JóÇåáY}¸åÛ7Ýyxh¸à½¹A²ßðï—-9ùÄåDÿ=.ŽlÍÜËf:bŸêë±¹ÕçYÀL—ï©mÈl-çü.Ìÿš¹¿L•¹T5þÆ»SwôùÎe¬}ÃWLOy“.vÊÙ.~Øì;˜ JDÕMæ†5¿,o_½œŒØ ¡ª ßD#¤äèn"0{40œ&í$=Úþ`”Œ^ÿ0lÒÝ«A‚`£ÉÑlâwðÓ’ºÄFÛ«úà úÄÎPYiMÎa=$G½ŽÈ„CMqš¨{ÀS8Ø™'¸ F©$(âíËL+õþ,ƒ»úèïÏcÏzý>Ep¼£7/ðᣊ殹De`DáD•!rò¼5¨59­—†ÛËh@:ŒÍàIš‘O16-÷›‘ÒíUïá«JÞEý>Ï.5J˹èŸgþÃ#E(#¿d·Æ&ASCùJmÙÐåûÚ÷³²B]j£a‹li•\–” œhˆÌlÿ~H“~Ñâ'8ü„Ö.oqH'—d-‰ø-dbòHiõ´Ò$eÔï›frÈÛ<‡—yjw¿³ðªwµ4ÌLlˆá[¢û1\„"±½ì¡'ºáدu q/’`j‰\!ÑrœT½-¾ŠÆ­»Q:k÷ R÷0£/ „_Ñ-‰Ha'990Éž„çYÀ¶û±v{ZŠÐöš›€ô>ŠPœ^ ²:ÁÿITpùÖÍ–÷ÑpaC=åEáMÖS!â©§È좪?œŽud"èa¿ë¢ƒ±ç© S E}àp°øUOúh+.f‚€ô¤‚6¸èa!n“˜—4N'nŒ¤© ÿ.ãì…´™O‰,äÖGI¾éóâ¥>JJLŽ^gI*]?F!IrßJB•YÛÓ‘zµþdPœØ×Ex®âÌÑÍ{%¿Úµc¸¬¥1Ñ•‡ªÜù¤›h¶dÎuÖME µ›X9Ùl`¥.µVÖW+‡ˆß…õ铸/-ôöqÒ_8yF,õ,h±ãJ¯"É[õY躜ÇCßu_Zýw)©T'éP¤ñ¿'´b[¨‚Œœ¢ân˜>¨ÛóAuù`Äè½(NY3£©GÌÒ²Èf’)(¶׋ÖI¡Ø‘ÙCŠizΤìá0ÃàòeZwJí›äR7¾îX¤)"|¶ÅŸr¡O”¶Dö€ª¨©–Ö0©WµÞŒîÉ\(}c[Z©)+ÏÎFo¶Q~ÃHKrQÕN_Kо–Õbïaî…–¹Y|VL¬ð’Á»Öv6´p£^Ïû@‹K˜ù ˆ±Ÿû¦îeZnä-Y]c¦±ªpK3’:~Ú‚bõ2+ •Ó\öÚ>j⺶\³ôöÚ>ò{D·¶/-=šºSzÆPÊ×T›XÀËY°Û*íI;Šîì5‡VÐ6a_2ÎðiŒþb[ý\&ˆl ¬‡ÍLWœs‹«Èúj{u´Ð{Ì9bZFæ|9TÌ£‹f#ø«ÂD¼Gë“„3B#)I'.ÖJFX\LsF>)v­@ Aå^­Â;€hÚµ²únRXuº‹Ò審øuu.Ä–˜1Hàx"FÚ™»…lž>É÷ö&Qd3ºè*?â[L(ôàà4muƒã–ÄŠ&Û‘ªfó'ÈC“ŸéTYÞØÞæƒ’¢v’ë;K [¬¥k¬%¨ºê}ƒážÀô»‰¬<%ª¾_;n)§3ö+¥  >¿Òô÷˜=ûôÁÑÝ^]½º~rt÷/+yt÷K¼|úÕgðσÏW¿8úâÁêëé.%B/¢”ÂqЉ¡Êo€ι=ÄMÍÍ{$nÆ­LtyPhœÁX7%n,næEk xì0¬¼ÑÇŧÍwxÂЀŸàc½DI6|¹SðL·óe"I-‰'§eW•‰KEÎùBÒ¦ìÔªúaà"rpÁDzAQòâ¥sG®•^êÌË.Óü¨‘ÁÛóPk4ºšwˆcœÚ«ÿüäuGÿ9ÛÅ}ý·`Ltð{U1»æjÜho§þ&XEÒKXýMÖRV»£ÿê>6v”òÆ},« ïDX¾$ˆašv'ðy>Î&ÖÒƒq’]ìä¤ýÚêÛîbÊùöà]\x76ö-ygÕÇlm lâÍ»gAI-Üh€ †Ûjty¤90N£B.cቬØ-.Ñ-Ó›ÊʳäXŸãÉÀ ÒéÃêÙ'¼Îk®ûî7P’'XmÚ¸I1˜«C ²LIÑvÔ«Ášµ63)àÊ+¢½0軡.R2 ]b”F#!O)Ãhe¬: àÓ:KÞ£ °úãø¼xÀìäŒÁ:Á{½ˆ“s> ´wÖ¢Z‡×@^êSi£h[g•a-3QÞÆ¸}€í ~Æÿ†ÒÚ”A¡ÿ8èTFÒA¯?Až)-ˆ­`V¼”RwFÕÆ°¯Ò¨“´‰T˜@OøTŠ'®ßÇ8Q(Û6œå¾Í#ƒ)rvQÖß¾ŠÁz"|R1¾Óä¸ U)_"<,&‘ƒà,Ô2Å zpø~ÙqÿX'mr™r 5eÎ}K"üt xÍã¬À¹F‡(Mø>müg{m‹nœÚ¿7zåÆà`|lÐc”¸"…p% ¯¼šìŽ>cÓæ¦ŽwÞ‚÷«Ž°¶Œ(0YŒ(à–Ç2”–0*8mh\1 Qð‰n {¾Ïçgì¹ecº9uÏÂQÜ ~göoб|žî«aQ,+õÜ[þÇ5¾ÝJb¾eéý’#ÙRŠ·WÕÀ¯•ìü]ŒIÂãm KÛ¨ â7¡-bÒ¢)¥ßlR2ôY6BÔVm°» bf¶¨PŠ^ØYL´[c1‚Ì–‚2þ°*Û†³Mö¶Â¹ÞmS°R £‘)¯¾_S”L …ŸR¼(WT쫪CQ€vòX ¾ÌÌì­›éW[4SWLïÁÖö¯:¢F+£–Á`-k0¸ ½Æi´¡×%%óˆcäõT6‰˜«<}?ªZO_’ŒùŸJÉ 3 l”nÔŠ¬ ºa kIx‰X3ûÚümQŒ#Ýžr Î,Šj¨Gç(<8Ë‚D~VéëÙƒY G,JY<@4²xq3A¯™‰Ë¡¢£Äa óRy`¬*`2ÄR9Kâ‰ÉÔS_¡¥µº} Ø¢ÌÚ<[¨©ÐJLi%/ë÷XûQÒqLËCžôuÙ“ªÇš|ùÛ¸+&íƒmΊTÎô «øÊµ/ŒÛ\£1Y”5ª8ò]U•6QÜŠ\ãe´Ä énY°V“ÝJåB9W1Ã1mº‹…£/¢ ÊK+…íî'þ:öª4c‚°[&XÔ¾T¥:'sö¤ˆž±Çuød(ýÌJVý󫨈±zt;¨þÜöÊ¡“U@åÁ2Ùy¯ îK`}/÷cZoQ⇅ ØÀh󪾥pö5ÙR¢‡ÓK =7Q º¸k`ô­qkcõ:µc1{‘ð˜0aiÝ[H߸£˜™o,”MЉEb‡ØÜÚu“ç8sÕÎòÓ—ßlS:ŽÉ¨ð:¥ årÿ5Ë¡½lÂ(ºjŽ6ÏÑ™œ&ƒRjF)‚"yÂÎÁUÆø®)ùúÇ5õ²kâFÖÝz§fîæÕº+¥è½ërÚvйTÁÊG¼§.%ç§oJ)Î48Ó×sð]æÉ }m‹ÐvWS¨ÞhZE+l»ŒYì÷.¦ô™Ià-ž|·¬4£ íy]sfÊg‹ÎR)_>–óS©å;Îwc*ñJ5tV/ÄóZÿ¶|ò»ÒzœTŠO™WÆ_Õs"ì¸ÔU}ß?TvÏCÜôñ½ZûX›–“2dà–ÊS3Ÿ4'Q¸+[FcGƒðƒ_Õ.ιÍ.·é\R>N¦*vÏ-6µ±ŒÐ¤Þ–½TÏ©¥¢¯^påU:xRG«GeºñÎ4ÈŽ2Ì\ÏÚ #)/šâR!Y´ÄãZÍA{d(ÕŒ³“ ;¶/ü¸íÖrý­5Oðì3½oÐ&hg­7=ÛëA݉êžþ¥G)p¢ºˆˆD1™ê1¤jÒRÍ!5ÂÀˆÑûÅá]g×PéƒÀJ–ªiÜwY|qܾ>Ö%Í Ëö4#Ò¤ô·½’–äBâÉìSý€¯ã"# p`?p™ƒ€Ùbi‰ Y«]ÉžÅZaŠä ,¸#ïÁ:[wÑ»L L¿¡ód&·ÙÌÕw¹Ja–¿>ò5IÓ:b*Õ¯éÈKTÁµ¶pæ?'XP K¯„,UŸ±(NÞOB‘«ž=‡ Ñà쀜ˆq¸Šl1Fè]9*èšZ§è9RñPÍ‚’ÇÃÊsŸ¦†8úc/¬Ù,”ÛéƲN‡å ãÒ²~Æ‹g[{ÑãÛÿ0;U!úqîBì]âe“á6+TmlÖÏa.þìx}-ªãÇ]ô®£Ñ*ÆtÌnX†xê6?üiÈ#Žó]Q‘1÷–!ª‹ŒÑ vÊÇ7èH¯(odƒ–gj¢ñՓɵÑ_aÈEþÔVßÏN~tþ6Âq…NßâܾÛÃ-:´ røsD]‘#ϱƒû!ÞÝ«GY ³Ø%â~Yºýe…‚ßÅë‘í{¹WK‹ºàvaII/®_0>¯că¿ì°>[’CèK\jiLï+¯6µÓîHGÿ-³Ôp™é¬©DQègÂ`ö÷HÚÏ3/\d·«"âñ/ª…']SáuúC.÷ùMEã-î­>Þò„whX“ùÍ‹a÷fÑ9^_nŒ_÷ä£ò~÷¹òÏA=H‡/'Ë!Œžâ6­ñ%‹)•ý•Bo¨í¦iFƒG5}UŠÚ£)I;âq϶8!u·;7½¹;ÿD‡ ’‡˜B8žÎD–€ìi©BÁ9…òpÊù5]NløÎI³Ü7¬#áMÊ–Óãy¢×CÜ^„‰(BäKÂfc\ì¤&gZäÍÁ]l‡AàÛ…Kó3à:Ïdòã1™Ã2ÔãÈ}$—ÁöÛ¼ýø)NJq彿N3XL¡1«ìNÿÝÎCc~Šû]JØ…q¿;Ñוڈ”Æ M$Gø`Ø:×óXg•!#8ù  ¨öAúÀÓU¬žüu1˜]ž­žš‘çÎò"n:zî©* ©…sZ=-ôŠ;(¥æ3¯}î Övûê?ȱÐmð·äüúµ›¾©Á.5›½Á,Å3TÐxoa`GÏwvóo hà$è(óâ›ó¿Oã±$~¦½yô·‚ ö¦Í¼Hå2 `TnÅÔGÕò¯›¤L—ß÷gÎc=`ÌyÍ´ÌeAÙ¨ÕnoªÓ‹w‰QŒbâ5<+ù !5Êšrów¦6¹Ó~É™¯†ô7 /é'`9F<øwëlV><ª‚¬e© PäE:½N^–¦–“¼ø£du‹h¤¼rÛOåL³Žøl>pö½©øøë£ÿ«ë¡endstream endobj 491 0 obj 5143 endobj 495 0 obj <> stream xœÍZYoG–ÈÛþŠ}œI¼CßÓ ‰ˆˆ”Ð*/Àƒ±qb{ƒÀBù頻¾g{לR„<žé®®®®ó«6oælàs†ÿÂsÙͧãüð|Æ«œan~8{3ãD3¿öNæ?-Ί¹àz¾|ÄJÃ-ðqÌHfç‹ô–æcó‘Í—'³îç§÷.ûå_³ËÙ“Û¶‡žs>0ÄßÇY#÷5r7Oc£öù?ët¿ÐÝÐËnô/ ÃåÀ¸îþè²{ŠÇ½î~é¹ÿ¸/¿õ 1Ún «ôj`Œ+ãgqfpÎZÓ=‚U¿Ã'®@ÁØ ÊÉÇÀYÝŸ½@nȧ¤zˆ,ðå~/ Œ+ÏÏ¢70|±ü5èUë8êÃÏ50£§ã+<µë øh– iʵ ¥.ZH6€Ý|¹+_áy/ñq <¸²ÛÅï=|ü?à÷ >v¹DñîVüôë.ðñ/ÈâF8݈ÆÝÕb¿Ž–ÜÍzBÍ,­yÞ%ª÷™àVæ¨äç/òüIš‡ý´`à ª»*EŽƒ×qÊç|Þ7Ey–Ϊùu®»ið"¾È§¾N”³øj»;‰m Ž©æ ðxMqƒvE^h\-½Ó¾§£º5ع1?BæzƒÊ¬¯FO!ÖÚÙ kÒ FµFžw=Ϭi ³m#£AÉ4‹Ì˜·ì™õ¹—õ5e¸æE;™àÊËÙܧ´6¾kæè~ö8Ož§ÁƒxÀñE[;0GAJ‰ -äCS-*[%7 Åãã<Ø!JXXí¯<{+é,¼{ 1(}“æëÞV©r ¿Ø]¡¯b”j²²2´å9ŒSªù²/þ#5Ѳ}˜’†x½‚,º:ó¼qåÛ~Á=Qâûªçxzåº+ü<ÅÉø'@Àd’’ÂI%FQ•'Q dêÀnïyàðê4¯_¥}C’5¼Ô•€Ë ähÒÒn¯Μ -´µ¶V3Ø… Èb”i²™²`yŸZ¥#Ps(RœUN,]ÉR‰Á¢ÉKÔ‡µ£ V¬&D$@³~ÊA:ÞÍ›SÞsÎ8~¸mÁ‡dß5½Ô›±M›Õ‡’Rt¸H ¤¥ r%Å õ4È):vc<]†@Wè>bäè²ð[ÆÀ9a½+á"ЍC—¡H‡9±Œ| C>¢éô\¸A~žÓs3$÷ú\yÈSL‹Ú#£Qúò@£óIƒT@Õ»#15ã¨^ÑáÞ{¼ÂýyS2¢¹B›O©Ïª²ÄG°ì<ûê\ü¶H:´·nª²Í ãe晸_½}kÕÞ{J š8f›¹µj/·®™$ð긑2íiRÑ>R¢?;¯ÀËÚÐWÆùÂ&GlwÌ9Ž£l%8‚6a k§´ÂcêݧeÀ”¹r{žÖ€*Û|ËCnÈÛ_pÈÉÕMÈQ¹7Íé- >øU_ZÝw2E·{Û­¦7z“¡H)öÍÒ•þäÛ± öªmijrz)×ÈBèr¾áf´]ŒDn(ΚРöŠÂþ“PÌïå4vñ©— ¡ÈÚ\dǹ¸ fÚ&—Ð\Ö |ŽCÒk\äù¢9ތԗà}¬#£¦î¢(§•tµCÖÞBhGÙšhBhƒ©WÕÊ ²U÷ò Ò¨Í=Ì^DßÛa ŽIc]]ÄÃØÐ„Àk„*úÝìH®£K¤qE,§ÄÜöŽ7}ÑΗµɱP+ òšwc„£VD±[þ€&l×ʼ`¢¯ÜNúò™šÅ?¢jð˜näâeœ¬¯áòœ.€f¼z“~ì|ÊôK^/Eûj0§µÏðÁÀãåAêEÑù›܉½nNÃñf7ßc"\勽£‰cyMÿaáÉì?ålendstream endobj 496 0 obj 2143 endobj 500 0 obj <> stream xœ}QÉJ1½ç+rLº­ª,GgÜÀeÚ€ˆxp@˜ÃàÿƒUÓ±E$Щå½W¯:G‹=YÔÓîÝÁœƒÝìs( ‹Ý›£¡ƶkw°çUp™-S´õ]À9Q‚Éc¶ÝÍ=F´Úz0n=®.+Ô³©fkð¿Q*"UHçL&É,JY¥^]„.:”Ï[½mê1!OÆJN>дb ;×8imQº€Ø#RöîT2qv+ ÷×¹ -Ø@p#tœ‹äÃd¢‡.qè‘‚2XrRTã<@tW‹òÒÐws¶D7³¡{ÑnǃztÏ´’`‚Vˆ›7ïƒØcÑ­73ªm Í¥x]ÿÊ«rûCð¾·ùSè©ýýÓknÍaw²endstream endobj 501 0 obj 295 endobj 505 0 obj <> stream xœ½[[o\Ç Ú7ý…¾ìãÙD:™ûÅmƒºiS´(Š&Ї$¬‹/µ´ëxåØB›ÿ^’sãÌž•dÇ(‚ØgçÂáßrüãJÌr%ð¿ü÷ùõÑg_ûճݑ˜ƒ‰NÄÕ³£$Yå¿Î¯W<…qA­”´«Ó§0Ø(åd:Q8-Âê¤~Õ>%ÄÊ‹ÕéõÑô§¯yº>ý÷ÑŸO¾:w¬qÞìœr¸NbR®¼Z9¡faÚ·ÓkX.hgž¯Oä,ƒÖzz‚ŸQ¯¦Wø©½zºYŸÀL/ƒŸ.×Ð(­óÓkh ~¶*Ln-f¥£rîûÓ¿eÌ샗ȅNýêôïG§Ÿ|;ý(()q>ˆÆ9m@ˆ:==[“„ס qÎàLEéÃtM´qùKE?½ØÐP RHBE‡c¦·@XFãôâG(+¥Ó¸cÂÆ)îMZ#"´JÜŽ3´KipÙÌ™¶=Ãi€7x€ÅÌ,…J;8Øß›ÑÚM?Q³—:¨=ŽqÓ °‘$,hZb’ žC²Hðt;ÐÀĉraY²$JÖôq±6Ó‹µEÊ–x´nŽ ÊíSœ:Ž&Ñ„-ªsa¸I àÓÀ ¬v³+©÷ÖAiz RN?5ŽG!‰-âú,x™ +DD( ”î-ÈGÖ5i5ëSOm;üi6{Α{d Ú#îq} ‚²ƒ™ÎøjYLyÔñ%¯˜ñ®N/à{ÐÐ ÄH^[üéç®À E„ÿo W -R/ 9#PKEl^áoŠQ™L WB ª·›Lv‚–OKG–o´IMfÛeÝËP·Qh5|Ó8]‚•V–“ÍTÅcåöU ±Ž&'¦Ñº¼MJJp’áR A›º„0Šé÷'¡ãÈþ!,\&ÙÒÎbkˆ#éf°8 šm}3²ï”$¸éÛ®“1ËÛí­ÙÃ=nPkCvuðYÚ ®³æ®tuTÚX²÷:*MMNg(Z‹¢Sã¤h—Õ°öŽVgù$D.ž®‘0Ęiò[$Ò÷»¶N‘Cµ’YÑówYÈ Kë‚ÄŒ«w¨]0VÚp‹ÃüÕa  ?Ÿ%1"˜vÕ¦m™#»,rö{ëAÂáù„—G{F0(m­·XÉï â«"/²H@¬}»â6Ì{£³âžôh胩áÏ )Dò‘ưµ¾—ÙyvtwÑcŒaaQB´Õ3IÚH@¤(£òy£Ù#tÓèlÐ`¤(1a=ÓÐh9tΑ¡­T,ÖÁ•™o,H†ŽZ‰½‚¤H „#èÙ€Zç2s`’—I6ij<Ò>É[9Q0J ÝŒ,òSé'©´"æ ~¿ÉzúO:?dèáç£:ùøÇmò€…Öϰ٘t‰' ör¢És¤›W’Êœbi|UÛ×eëÞÔF€¶ Éù5Ö6m¤¬ÇKÓUk|ħïstS®(j°ãf8ßMU®»,$«Is_ ©'äI$TàÔÊH–…dŽ{˜¾[—.T XÍÛŽ~U¹|ÑXßÕÆ›Æ ­··Ëaé=!©?™ì¬UÑÙú?]Ò²ZâŠLdRò³¬¨ÿ eöYæìÊ·øûœŒßDΫ^çß“w4>#}×ô²©=7m+7ÝéØÃóym|Þ9VÆBúzYÖ!£žßts»V`ÄjIîpÃ÷÷yÅ/Ÿ 2¾äÚÊ_¯óOQà]ÔwK'©³Î 6û‹ß0Btêôl4ž·”9X0RµOÁ“Õ=¯ZÛ803—P›è^çs¨9–˜n{ºßxÔp4Ý OW‚Ñ‚dख़};tyúa3³ªÙ€ëÅÌÏÎ7Z®ÊwK<7|Üc)Π¼[²)m¡Á¼—ò6µCјc&øé„Ô¡R¶ì.¢lûÖu\eqcÒÔˆYËWp}š-~Ùøæ´ÄhÙ×%æR H…%›¥Þ§ŽA— V‹¹Ëæºke·=bo3=JÌzÚZ ðû´K]¥TÙ¦dÍò¡K‚mx¶Š¯rWJ¬Ý¶—üžBl8™ìR·½áñ}ÊKD–9½]NS±äcÏËu­H3à X¥˜ +0:s0Åü; Œ•“1p»³ÑYT04G©§à¥ÁK¯"æð)Ón’ÛQ0Xz 1Õ< (y ëK§Üy‘*ZhŸ+Cmüô UQ£$2ñà8q¼é:êûD§±x[„n¯dÌDU”ËËãÉ—'-¦V5jÇ+¸A·“l?¸dšîÆ9j–Ò É©'šhÎI >©ëöB\:8Ê¡8«_x ÌxE>Ór%z05•Ó’8Î×”_½zv¹ÐÚ•õÜݽ¤³1AhÞp§f›~r;§—X‡{~½†–ì›K5ƒ_r^/sr@Û@f d8{öd?d+ûÍ…;,ƽ¾£BØm¨Tï4˜T8€>• xÅFÕÀß²5Þ›¼ï¤:úp¬œÒT5ùKŸê)¥‚"6”„GëIA^/Û/–k·“œБÂ0µ&Ÿ0ég4ZŸî˃@—ô.A/æù”êÅŠTƒªY¾œå§xF²Z§Ì¨ˆSñÉ—ä…0Q³Èà v¢+¾hï)Uñ¶É³Oz,eCèvf˜Ã”À2ÕÖ’D­EÃDír0c¢ aȧ’ë‰é,ß¾ÊY¦E=IŒ«˜Ñ‚Z`ësX+ÖN)ØÂ ÚHiŠÊƒï(ÙNãàÖ±Æéµ^û\=]Ÿ@(å°ü[XÕÁ*$°ŽQ„ÅŸ‚¦5ºÅ†¸¡­u¼nÑò>fgدtÍ^Y*x G°³Q¡Î±>mªk{‘*ì¥7ÉÇÚÂr·cÕù&Ÿçí\¢ è)¨†Ê^ þÉ=Ýôr`#Çs‹(¨'xӉNj—u€°Ã˜Î)f„«‡bÙQ4QÂî„YTL§B ;—JârHsð˜„pð˜ÍìÚˆ‚œˆð?ä”pkÕÍãÂWùõÚ.’£ªƒNGÎK­–8wÍgÕV®7,« M¡æ¿–KàÜ| ¼dô–{d²ž‡ìã¯Ö*ý Bã»Zë)¡ ¯*ëZKîÐdûË-y­ )3çè˶(èMY–Õ8‹ÀÄs4{)´Òö]z›[Yˆ½µXÄ%Xã9|<ƒÕ‡^&]·†è kŸQõ®e¨„¶¦—9Ðâ5*™®·2´S_ìfüRÑÔ“þÍÝá\œ mòA Àf¹]+‹ƦíbMÊK*UŸFŽÔåûÄÇ€„؇ħ°Üê”ÄŠŸ]Ò˜Œró^üß­·€¯›Þ/÷„ÿ Sù@)Ý#¡!V½tE>Càü>‘=ú’%A}‡ û+Ê¡PMªû¢´ûxíœ6\I#¦ÖÐF×{ey^:xtç€;%«w¨!} Ðó8] 2àO¶/±%¹-–’á/L²[9^×W¥g,O›V©Õÿv›-éÈñÉÍ¿ûW3õNP’:åQéñjj‹Ç'ã#DzÀ7Ù!–ï़“³ìTLpüu KZ ¯xBÏ=B˜ª€ÒϽàéfé™àðt‡½eå¹ßþQÙðì§P=Éï·Ò–ûлf.^SÀ;„Ù×ùýH È1埣DÌÉ?+Éùãõ²µð~6l*DX> stream xœík“$EÑÐoû+ÆoÓÂŒ]ïêS Q5@ô\ôƒÆÞîÞ°ãö@ÅßnfÖ+«ººgö>s³ÕÕYYù®Ì¬ùl3îÅfÄÿâ¿ç×'?}ì6ÏîNƽד§Í³“ÏNÍÙÄί7¿:…y^n¤0›Ó§0YKi…8ÓhÕè7»ü-?“ã¸qãæôúdû›Ço¿{:œ~ròÎéÉŸNƵ5 Œ¨Ià:I±q yõ·­vf+áã§¿/ˆýhG›¼UZ„-ZíÄ´ÉcÒ˜½-€~=˜ý8 ¯¶¿`Îä…ôÛ·±ýã°SøDlO‡øåAo;é'øÛm-â°vVHn𠉼ÅYñ³}¯@.pò_åÛï2BxðîN:¯›í_O´…9G„Œ¸)¥}@ÌTyÕwò›t ØGLpfy hÈi‚×TÚ?>\6öá -|…©|±±1 ×´bàŠTvÖ{«.`¡í~¼Êß^àÇKü¸šq""m?Â÷ÃÀß·øÇÇøq“*¾ Ąɳ‰wYÀ ìuL[K7ÕŽY¡iRÙBÜ!(“޼rú“9Ò×x6²ãÑŒÖzò8‰àÈ_Oà~3ÞJ™€ö×Ã"îÊ¿Ÿ?.ƒ“‹†aôºL}#Š2˜Áõiõ"¾Ñ[”d€ÄE“(†Ñ§¸S°7£]ÜIbPÕ „ F‘0JÓæìÓ %î;`ŽÔ\3‡¸Æ”è2>  þ[¦]Wûdî²é¿y°!O¢sÍœbv˜9kêõbXP¯Öqy¹Ÿ¨ÌÀMÁN¼‹vòc0˜H—íçeQ2v@6i=Ñ::—¸z:â &?μm j‘Œ÷x”Wà¢ðßðÿËý©6Y˜è>h¸ÁÏooq†sðׄKéõöÖŠè¶GœñqüóYÀÕ*=¡µ ̳þÆe¬#u¹Æ¿?ϼJï!Äùª,CçøgðtgŽª°º%&+š&dÂ6$ý(€ð Oø…3‚˜ziÔÐJ*"i@Ip/ñ Ø:©P­Ù$T`0ÀAM²™+“$Ö¦õ® ߾’ÔèÉešm¹lÞe4ï†ôVÖ÷"©„oœ˜wFâ+&„Þe_Ò‹ÛD ‡:O(Iì-X;eE°³¨@Ü®]€ÄÊëŠ&Oæ+kk@’æÙ5ÕVBYܨ`»{žäê–±ÑD›((,–ŠÞù]på(®FÑ¢05½óg$ º);KpeñlS lFF60¡+¢2@`èdÐúˆ°]âLÒ\/‘.Xùbd@¾3ÊÐh±„1¤èy¼Û'ŸFO‹Ø”`å^•ÕϺ"G›U}™‚]“.ŒŽ@‘] 2'v–×@rÏý6žÂ]¹$öÑ%Yß,ÎÚ¬ìlld²3jF{•=öyu1ß.FG‚€Š)3'Šñ!3!UrYJš!Ó,'Ωdš…¥£;­K>…,›µV²xˆæñðBÉ"u¯ÊªŒRl7Ìgí"ƒ´zæYûp€)–˜ Ú± iâ:ìÆf-=´‰Ä:®wÜÕýô±´‚›nu–ª0‚RÊÈ ƒw½·Ö+Áû¸—B{­á¨l$9˜3Ø&poD…{ïµêFã}dFìM.Q3TìÞAÌ.FV&xƒrr ù€—zêb£¹e`nâb•V;­ý^ÉÆ®'<ÁÃF<—O£Ç„‘Èd£(Œ_ÀŽÎ,EÃInñÿàP>Sü•,«†4è_CгH…ºè;4·¦¯Õ}òöP611Îa~Ë;ÓŒ¤]µ÷ÃÀnrä]‚Ø3¡m !ƒÊ­œ—´ý«=ÁH§5éj ñ,sXÛD»›xŽ’“ p–ÔφŽês:"³5†\b I™ÑPœÇC¡Y|ÁÖü!c(r·]F€á ‘,Ùm$Û?-6çDWΉý#b1æ³óØ4Æ÷I’Úìù]à–tÓý­¨?.*ËÊ×N30Îìx4Déu•ôúÊßB"Î8¤ðhª”e?qcô£4KŽkÓ!g§Ñ÷˜ö6M| Iâ÷k`ÆG8A Q1µRtkšWº.V¤ZCäo„PFB .€X@  v½]˜8²hð[Ø.`"á@Û+DeúØÞ¦þÞ–ñóGâÆ¨´ŠÙH;^ZŸÛeÙq76î/Q›åkÊQ6—ãÕˆ²/WÐZ•&§T˜\˜~°NOÜ9(zŒßQØ–nýÙ¹,h~MÎÚm×P›]GjšqêëfW5ï-¾õrBuÉmgäθ5bÉ8þk¤w¹Ä°"”@fCŠa­°Ùi%÷ÊL›‚pL'õ^tÂ)krÒ~Ék°3Â]:?·ÄT•êâ6¶?èpðEE)"ÅG)Óí¶]Üáø¤H8¶hŒ¿â™hÛ»ó¸k1®] ­c ·š½.‹GïZÕ[¼ÙõL·ÍŠÖÄ“„Á”hÊ̬ÎÈÛ')tM "­´ôNÌÅ3Áƒ=ð)/E^À•ÆSúQM!ÍŠªÊ!¯HßŃӊ°Ž¬ÝÊJ ·×ÕËÊ{:ª¯œÊc–Ç6§YRñ´l}¤N)ï™ÀÌ3߈[6ÙfÁdjŸŽŸ§\ÿUŒø»K(UiӺšZ÷ùdTWÉw vú\¾@ HQõîßCª”?RQù—øñU®÷]ÆâöŽDï|HÕt‚pžë©ôŽeºy1±þQ¯Ìw–KÕüëºd™Kåù Ù_Æä`üxTêõW¹Py—0‹õúðfýZInòÓ«ÔHâ#¯HºT(m¡ìÇnfÁ{Ü|ÒeÂ]×TÞÔͭï?{vº4i]±Î²C¤žeM§‡÷{lUjõˆ…·c,&­(1ÖtJ°f›èϧ•Yž àa…› 1<ÈYµi"Ñ&År¢m{H•¾I¥”jëæu­7S¾” û9eÑ+Ú/ÒË¥›ÃÒËX’p˜cä…ÕBlÈK*+B€¥CôVU(;«óíÁýäDûÔ@!Y7l < WC˜qïdùÑÄ¢ŸˆU«Yk¿Y›F*ñ‘œMT¸Uü’Ÿê³æU±qÌbE(T7ÉðÌ­¶ª-15Å‹Î9KweÒ v¹2«ôª.5çr '±=tª1”®Ÿ¥âÉ,EÌä4oN,âH¾SðW(zÖïœu €ñju%Çq“º½PTzõTHc”²›\ÝÈ'îËRvÝ)jèë%R¶Ñ* S¬ÕÞ7ž$ü½zr§ù ÷‰˜b £B@YuuO{RSïSdì)°B9ÝuMîìÍûŒ¶†UI.†Ó$…XÖœ¤aE»óPóT*=ñ)J#<5¾wLgîYìù±¹šfwk™Á×S0˜Ê×­6hŸ{}ê^œ#rÆ'~õ¤Y™PÆ¢ä"ëÜb¦ìö_saŠž!nXb_ö:$°X’¯»z‚ú@ð¦]T%3›šÝȧº¹¥e¦lÝ®êRTªS'œš‰OZÙ£¯ÖZOý ‰¥ÄýeœªûçÛ9ׯë6 ‹ä¶òªõb—'øêÅÙN“î·Í£ó÷ë=¼Å¬’ó-j¦“Ç-s³ŒžF•Z ”—±ßA 935M• Ÿel›.Œb¸(ÏŸ&>vp\²Âù~²¸»˜¯sÒñ‹±ÅŸuj¬×’‰n†ýcŒ®ívZ—N<Ç0欧¿›Œö·(¡+JèV”ëxÙú”°šUFéÁÔ_y(e®5Iø„8}ŒÍ$¥3B:ÖT”›^GÑ(ötî=ààÅ{6 =Twâ[G­‚¿º57¼i‡g`Œ½½NÙá|NE§Ø¥(Ä·/³Åºk¾)Ùí-ùU~ti£ÃzMe«2øŒ‹v´3Ó™à1l,ÿ·×¯m¯ÍÜÕÝ;X–á¡!zmXà«Yñ΋´øl¥`5»¶Ò I GIžÜv¼¡ô÷»ÍY쌡­Ã@y*íd&·á¢Ê¶µþÆ“°‚ÝñnäE&òÓ¬gÝzaÝÑøÉz+kjÀ‘ÃB\OùºY“é!á[°ƒ ÉKE–š]zfxð8Xí°µ{_SÛfŸfcÑ5†lKü#,·Ë‡ Ƭ½1S“Z ójÅâ¼1±¬é|Ö1ê¤}­èa±Áí5Jõ÷ˆð¡tÀ5²Qår£Œ ÝßÔ†›Ï‰}ì놓YTÙÒy/?×éõäÔ»Xë‰!£‘riÙûtEËíÅTç—×ïZ•‹$u¢¬%!N9Dœ•º Æšµ›¦Ü¤TjØ5©o´.v’¯þ*º‚-°æ”Š •§B‡VŸ4˜ja7Âàéªú”ÖPYÁP‰Ò°5U/S±OP¾¶4Ÿ×w˜U`Œ©níF%6©ÍDçi¬3¨RCïšï…ñû-©`Y °UÂåÒEˆ>nS©CÚœg¦ŠX¯¼Ø•ø‡ß —~!¦P.ÿÚJ})\<ðR8†¶‚¿x+,³ ©Òo‹|7•V'7ØW×ȺÚê‡WZ‘ 4ÚaikX]ƒ«]ûÍ…C§Ø[–uw#Vñ®=DJMnûk|£áÀƒ¿Q”¾vk’ºr0IE¸ {Qß•Ê?z› ¬Y&ñY Òu§C¿#‘n@âˆrðÚÍ(E¿ºär_ B.rIc¸Å¿TQŠ‚útMÂrG37J¼H$œF™©•§öN=/x—ŠOãÁá”Mõ½úX…AĦZxÂÃà/_!Tµwv‹±3Æ·ÓÔ=ªÈ,t刄ô¡Œ ?ˆ”®yˆ…èÂÈ*О!¥Åh#R˜HMü(¤Žˆ²¿vÓ\NŠ»4‡B10,‚¥n¾o;œßÊX¼“'æP±ÕÔ|¿¬ndÞ}íëM¡ ë÷»â´t›DY…©> stream xœÅYëoÔF—úñþ ´Kl¼¿‚”¨B+èÑ/€¢Ü…T¹»p ˆ øß»³™]{Ïw Ú*’ã›Ýçof×`I öÿùbrÿE“\ÞNÊ¢•]]vÉåäý„ižÄþ;_$¿L_ËΪd:WÌ’óšµj®¬EÙ&9¾á/ˤ)“éb’>zqôdšMÿš<žNžOʱ=ª„±¢¬KnöéÚZHf$®eúi WË·°þ«´Îò*-2‘2ó’×L%«Òß²œ§¿göåDq#åÈ諘'òœÅðú:6‡l;‹Uƒ1ÎÛXl «A°¹—à7¾DC´_ĈÑÈÛRŸVÆé‚µ|ãrÎ ÞGß+[C „6:©•‹’KJCÑ©úÎçl à±(_A v±1\®ÃƆܜ¨_Ìžk )‡$V$øün|b9{ ¥˜-ɳ^X™fÅ_Ø+TïO‰¸ˆÕ5‡—Ï[ÒC4Æô½øù‹4NÈÓ‹†ÀGa8,GÝh<¶¡w÷ ÷ Eëáó2Õp5DÄS‡6h8á«bLd>#>ê‰JÌ|)¡g|·6¤o1Ä/Ž”ªSõZ›¦ Žl¡©´²¶«±Ê†§¶oÑ«ß<‡L*°W´ºH"2(z¡Ae¬ËÿojG6¾‚Æ®XU¤_U¶×Š!J¬cȼ½VDOÞB²­á‚âÿ.^mÝpçíó´õWø¸‰õy{a†Ð½@pP°Á1Ï\„—䱆BËÐYüÊŒ=À±Cr:Y#<âÒaÄõãÄ:èôz/6i?ðÆèJW±•Öß#Sô²Ä}Í:¹Âh£41= ¶ðõ8>;»zxd.Hú-º5Ä—~ÈÓ=¸}°/³Î¼¢Üxˆ~ï˶¶VCV<¢xFD×>qГoÀ”:@Ó ÞÑ„óY¯s¢²ž9 CwìÒ*i—7=ØŽҰ¹]4MMš€âW5ïf×°ë7]ŒšS´Üܧú}‡ ðzJ¼¡Ù<#—‚^0ÚUöãbsYé£!Þü;!/QîQã4‚@£­c_ÒñþÊŠeÂË2öX\I´½9ßÕŒÍ75¢xÒÙTL|k‡¶µ(BÄøS Ô¶hØWbd ûž¤ﺑÍE¥dÓ"ÁuŽ2vÍ~Õïô4ÞÕ­Þ?²IxŠ#õÇ8Á |ÄâJ ³e×K ¡î{Ûß°¦ÐØ£ÅÜ*ø0Âü”qC¿€s¼0Wç$(à ó×Ó8Þuu×éa¢ê zc°ŠÔóWK§P®m6=þ.ó@¾5õ‚UÎAs`]õÄ=£Ï{ à!´ýÜ¡¯¶]3ržëF”+µ»À¸Ã’NPË ¬úËéóÉ?6n0Àendstream endobj 522 0 obj 1807 endobj 526 0 obj <> stream xœí[YoÇ·}Ïû>ÎØÚaß=#E|ȱ;¶:~° ‚—-‘+“KÛBìüöTUß3=<$‘p@Ðr¶§êꯪ«¾îýiÉ:¾døÏÿ}v²Øyb—Gç Öõj0lX-~Zpª³ôž,?Ú…z½X ®—»‡PY axý ÌHÖ/Wñ)¾Œ--[îž,šOž|øén»ûãâÑîâë»l %ÐÕÀq'$_Z=õØÕwnWºQðñÃîß}Þ1ÄlèTÜMÑ(ˇe,Zw&uôq«;Æx/›ÏZ¨3ô\ô͇-o¾jWßðf·õZÕªæWøÞìÃ[_-.w¬m{êA\ßuè{†øÝÂPç(¡ ªû8†$añÍë¢î¾—„1ââx°¹r“p3ÃTƒ…ùŽ4G+äÛmc“Lb§òL'éÝ«Êlhµ&5×¹6Ópáõ~­ð¸¦@´ÍÞÐVrP{Ÿ:÷Xá*sS]Ëm|ÿº6¹u*LÊz^ó™3v)’±¿(ÖyåÞ•VS…òQåãå•sPÕs(ÇúE!B7`ì!…þÖ‡ÝXuSÈÃ"1Ô5ïW Õ-4…„U÷u¨*HY6ÎJ‚ñ !G•d[ü¹­Oµ‡‡±¾>Õ¢¦íL^ó/ˆɳ©éRMH†x¨ÌZ]3ªa¬gà뜆O1cÌ> Á sG¿ÂT%fGHKbáâ¥ð!$“ _”¡Hž;ÞóRÏ:Îë­’zQ׿¢ftà}bôë‘@Ïc=~ó¢HÂS‡[NÔføó6í‡:w “¼ ùƒä[ÊÅpöÌÑWÙæn² Pröw¯ló8óA°j~„ýk]l]q™µK0cöy’m.n dPªù½ ô›“ßF$ÕÝÒÈ”tAèíà@—-·ë)º›µóë_pf))FO9pÚ»j˜#nÎòݽÈsq¾¼=w¹lôÕn ?ƒ³h68àAHþDM*—‚êGc ë¼óuÍrì{˜x+Ú(Òë„°0Y†0t¶Sl~Iyód&]AÒ„Èö‰ˆ`Ñ $ë¢jÒrŽldÓÚT4+r›> KðÂ%0ÏÝ̹ƒ©Ÿˆ4˜,…‰½óN¯J’b“W{KÏUnR Âã,_ºi50²Ç0ÊI‹ÑgoEö´ßꎳA›'Þô§%lÛ†¸´nïR!Ñ/5gºë{$s?z¼ØyüÅr{v±^ì|»ä‹Ïð㣯>†??YþiñèñòëYöu,¹çí¤æ0. ƒó ê.í·óÒi¥º é +dK*¤Å)•tj„Ûyyí ïF›=ˆrsuöÖÞx`–C)ÞQBjŒ©Èºf¥UÌ0Ü‘n]Zˆó:) iŽe¼æGP‡1ä‚ o÷Ç)©FN]A.HäšÏD¯¤Ö^ÅÂÈLÄ,œ˜†ÁSNÔú$|dÛ^¤!öb• OR'´—“ Ó£%”rÿ½TÈB!i|B¯$ å^|*•’LQCO®Ó‘)¯¢îû" <éh¾Áϣɗ ؽ›x/q"Ç5 “2C,’êUó]­YêëƒTø0²TøC ‹,†S®$õT «¤Ú¸ŽyÊuTæAâ)7^ƒ®’&ùGø‰ù«¼? r9SŠg]«Yj%²'Ì=û‡ãç^Ö¦µm«f×êç¨Ý—cÌŒ‡ÒßJŠ/“ÅWxè&<ªWµs‘›´ó Í+ñ¬Y “™Ña/SO5IrIS{¹ªú)p6%ž÷j°Wk“üá-y3eR2&:<&F0ó#óŒž/k‡iý2dÆÕNpJÏ•v’ÒÖåÈ!èz¥ªC@ ‘ΜJ2d ¦§’xŽ]ôሌʯA4ŠAÄÖ›¶ó2ŽÇ¼yÌ‹Áí4'ÆÑ.gr>>L[ %`s¦¸òÖB ÈRPv ÂIõ5â3Á]ýÛ#mTˆ÷†¯ÀŒüN4ªX!ÖM5ª´Æˆ÷Ä#Ò:ïæ¯0’¤¼}i!­‚P7—–å©b…f/èÀ+ù}°o©“ÑIªZ;H¤3*õ]¦¸2ò»€(Ò@öÆ•=’fw"ÞÐqó.Œ/Æxÿq»"+ØýzUÓh/ç¥ãwä’ì¢bbóâÚù­ÔòN¬b–ÎTŒ}&½Í=ã¸sžëg¼Þ4å¾#_Y¥ê¤K♆2õƒ¡’~Ÿ?&a%Ki—ƒa<žö\qPÂÁ.’7š9(ŠÄœž•±¡Ò‚΄‹èœ$1È‘i¦ûFEö<²¡k¹K§ºsçÃùQTybTH-Ëñ® Ž ÓƒAè·`ìYX{—‘BÎpT™î›Ó² íe«ß4ªGžÏgüÅ•7ÌùbParbë³WHŒk—֞Ĵ¶vƒêAÔsÁ£LSïµ;5÷kùRõnÐïIu]|ÿ×Z^—1ÝH1M¾„ÿµé6øº¤ŒÔ9 ß)ûì]_”8ùÏûi%ÓÝØo’”còh’jŽsïWé=…VòôݤfÒÒ ¾žåKœß˜€îý”†§¡SB¿É GwÜ™.‰ûÍåê…®ó[s„´p‰ ¦åÖ eû=Ñ[¸è!¼¬«ü¢NÞa¦/~F~Ì-ÚeÈ=¨Pµt^²~A©‰µû IõîDÉ”‘˜Œ_ L9ÿ ®ABŒ¦Pyô³@dÖ“oâÄÿ‚wŠžû¿Ì;ý;¾?½âý«èKFñf^ˆ€boæ…þïzþ¸®Gܶë!Rÿæ®GŽ\ÏåWËD˽Âõij¦¾î;NÛùŽ·ˆl¢¯xߑޣ²uú >¬Ô¹3(«Ï B\sg."ÒÜ·¨d5|I6Æ›˜ZyYû­-~.×ð˜=™n3'XéÜ%»–òk,” ^¹#(ýGpï>vI¸yÊdsÕ‡»Þù i¦…Ú2Ë?ˆc»¤œU¯º­jG61.@ôGÄù”öý䏯¦Ÿ‚}Ž]<*G€>ÍÝoÞÂfr…÷æ~Ã}cz0xYÇ9Œ›mÂ{Î´Š‰d.À} K?©€´Ñ¬ª°$Ì“Ý ïdøK8.¦$λ<…»ñ±üd-‹úËNTßþ˜~rJh;‰ŠYIí¶EÒЧH†Æã¿ò^½;B4=)ÀÿVºßåÒ-j¼néW®þà[ß¼õû{~Éxvé2|L~ªéoPW™<Ñkd?K&oˆŠ¿ìJüOj»azs~¶Ë‚¼’'Õ§;Ë“ê¼ËÈ“Z÷kžŒAž!–³5Š<© Þ‘ÍZFætÒSPæÅuÒ‚P&ÿëÅ—­7¶endstream endobj 527 0 obj 3436 endobj 531 0 obj <> stream xœíksÇÑv¾ésò)_.UùpsËÎkwWáWLÊÄäÊìP ƒ8!$âø¿§»ç=;{°H(ŠÓÞì {±ñ$4> OÇñõi£Lëäõ“øúÐ7"†€âr¶Š)¢;"ä—ÿ‡ 1¿žhÛ´_I†HýKØYè˜ éÔuì†ùà‘wØU‰Žðû¡m‰xý•`ZIÓÚÆ£~œüJl<×bc¶ûHÿ’Fc3r­{ÿa|Aú(6¶òmÊû}¹³û—;óïç¸ÛãÀÌ!D1C< ¿‡_ºFØ¿äÑí[Ÿøï„ eßSã÷åp·þ ‚ÉS|Ð$€ü[¡ñ»Ø³%ð•ïP@Pï‰×GÐü(sÁ»¾Ÿ’ÉîJ"\ãuäÐK]J‘„ AóŸÂ»eÆø(…žïG(®{îc(ݾïA*@~RI•ÄOAOPVŒGK;þ¯±ˆíÉò äVZ+"<á¯Òÿ¦•ºc³…P–ˆäÐ?ßýÝð³\“’qí5á9Ä ô€þ"·¹Ñr`÷2_.QÄ:Ãù¤I§F‘Cˆ%á@Á%°D-:rí°.ï>ö?Â}¸¬ƒqœ±ì€s=lBh>êr„þÇqqd©7†^§ Ðò8×½†•ðÍÝæΣ8ǽÕf\ã7ÛIJ<$‹à¬å"!BÿsDž®ð“¤L[÷Bx”OˆndeQ‡?úÐEd !EkY@´,°ÀÆ:<ýšaËbä(þúøsóÓÙ;;ŸÝœ}3O—0»°• XNâ:-Ħ¹‚4²Vˆ¾ëW€gL«_x@ZžƒÑHL€J‘> rÏÕëÁh¯Z½5B‡Î¼èÙò ºC„Î*³SÀ"gJ‘yäÓÀj#0mqñÀ jŸAÛ¥¢3ÊŰ–¡-î¼Ï¡Ènõ¨Ñ­¾@M¢½/Œ¥º%])rp½¢é‡±!‰¶- ÕdÀ•üdu^k¼S;å9×xËd×SNÙm”7Ï/»¡U9ÝÑËל´ýÏQÛ>lÒmµýÓ¨`£bÎù׉Ý8Ëœ‹TÏ'f ¿&c’5Ñßë1‹—š…äýÒkf0 ·™;eð2úÄcÓ,GdU¯KÐûhN;‘ÖfRÅó<­9X0æ_×8“ 뜸©®4¢ºbOö‹o¸"_¹bŸ­x¯qÎÇþÄf9Û`U)ú¹X%•UsæAGc½ ’wÖ™±Û£m†#ú_K2åô±ü¹a^t%.Â{ÌÞô4Ë 4ûŽÚŽã®5UL,0 'Œš-€jC+¶$ÿ9©Â:©-×@^†ap< M&±€¬D‡iÄ•”Ò8tóά`˜#§¶ËõaÒ¾¾xÉ€¾×ؘ΢³ÍCÖÛ`wƒ=ŠóíŽì¡7®í‘â€nbýÕr t²ï5»•™©¹€ÝR¬®¡Dm·º•—a§Sìs · Ú˜LDʶïµÐó/A}s&µ”µ-q n¢;¾Ÿƒàk@€¨‚…nLÂõó`g=샋„OÒÖÕø„¨_¤‹7ùâ9EêÖÿ,R Df@ΉHÕ)…ÅJ‘Êk8«Ø3„êÐù"ªQv°Õ¹Zàf¨¡¥ÀwP¥sÎû~"jÊCú³:6! Y¿5¼Çù¬9¼˜$™t;x ü–º(C¯ã&Õ™êÌàwöMånË–Æÿ­½ykoÞÚ›·öæM´7ÚL¨ï5*YS°ÁsŒÓV&äPÚ›!‡€jåÆVA@°®ÊS’5fA\³paŠó\V"•³ß@ofüqñº³›´‰«W{­´®1Ï£G¹~z´ð^r5ºù¶F š¬ð‡B±0°,‘Ò5jÍÞ@`Y2àŸˆK!¤©Yúø§˜^z æùOh>ß_•óYˆŽŽÞf îŠØnºÃ++v¿2bå :ë¢îñ¬—L±\þ0wÙ<§š¶ÂS¶ nl/`™ŒäТ_+“ª®[ V?*ªÖ&ˆ…Õr°½7¬´b¶f4­ór^û¦xdë'1–¨Å6Œ+¬Ëp€Þ€ ”­Ú/ê?(°¨ÄÞ£ÇJ7©èL›º'e82©ÓËÊÓ„ ÅB¬CGå6¢GÿÂ=´CŒ‘ÕXøºíØ`cPú@0º®}Ï} ÈVJ’ &8…F{“X/Ëm0#%ÝŒ¸àž™ ÝòÇŸóïãL=Ðû}Hx§åDe Ògá2®ðX_ æïA¿È׊oxÓŒ3,„â ºK[Eóçp-ÌdW»B ƒP›gCn4QZp7ìó6¦”¿ˆhú hrËG›Ÿ!´WÓ"î.VÁpªfŸ?>󽱨ضÅ!Ÿ6+}”ž^òMï1„²'Œ²𯌵Iû±ž#«2޵Án¥jö€”(æàŽIOQ¤`š5Nl½¦¯Ðt7+”åD”/$£úâ“0tó PŸ˜ 2"ðñ½ÄÊRÜ€Æ[‚~··ÝuC‰×APUËutq±Ÿ‰Q¾è(ÔÏ%Mú]²'"ë+©žÛÞTÈ‹p`&eßVç‚…”2ºv*-ðM ½éŒUº¡Ö~¯»$ëc"½–÷ÖÄ1ÓqѺr¿D‰¤Tò í6"IöHªErðIŠ»b¸ÏýLðŒ`ЍŽÂÃmª‹y¨žf Få­‡²lê$7/\‘:tDJ d30|9÷ü;ʤ¯OãSG¸’­H°ünîÇä3*pêŸgä.ääëÚ’ve²M€119&HÉ/‚:ø1V„!•¸•„Ykr)ÂëÏã-Þİjã¯QÌ\uZø^H ™Ú!šj­üÙ%C×Ç`4©É\g9Àn²ûõ²ÌŒ“Çi `•à8¼“½¬ªcÙcXl}x“£êÁb–r?Âæu'C”¦ò`‡§Lò¬(¹ÇïhÐ_¤¼îF­ƒ×W nk »š° KçwF˜Ý[wÞÝ-„‚ÈÕôéb«™ÔñH‘ÏuCø2âõŽùkBrÒL÷rÁ‡àëL]ñ3nfE¸1ÄŠýûV»y¾Œ×ƒ*©òª·¯ûäjˆ‹mc 9Û> §AŒ9΋0qpCª{"\Í)2@¨š°¡?;ÀÒv[3Z-n&TÊTä7oüãZûJ¤ë¨0=#ŸZ:ñ¡¢×£K¶ÁÝ9±7ÄÈPðA)í=Ô@½!¡\™&áYFÑR¤ûì+!'-D‘ÉÌÉû[¥?ÒUâ+:' `à=z©ÉÄà?á)”¢ &Rä¬x f&}V±‘¬O]ãÚ°–Ùq¡–e(ŠZ¯Èo,àÏoŸ9&Ûo*Œn¢©’;ÓåªCOìòèGN^Ò!Z8¤K¤ã8³ƒQ’Èm«Ø§žå:‘JeDJØt™å®‡¨õò ìEûø´g3 ®Ëqb¡M@çáåZ6÷Ôòç–Ë3wcÕªF1JDg-Åçh„èƒéDõƒÄ…›Ä9ù @[W¿ƒ‰zã~·§×ŸY½±gÉ„gÏAôsîÜ‹~è¿*÷÷(¡êÂÍ›" ¤éN—6xÙO¤œPOoÚ Àe,É´Ȱ‰úª¬¨áÍÝeiº £˜™®ßòØjX±Öæg¬}”ùî ˆ©ìg*µEqû£:—•u‡è¹sعæéR«å> stream xœÕZYo7~ׯØÇÝÖ’—\rw$Ò6½Ð6!´Žaȇ\¾bÙ€Äÿ½3<†ä.×rlI`@¦È!9÷|Cè]VNXVâŸý¿6ÚÜj²£Å¨œ´BեʎFïFLÓdößþYöýèZžq&³éˆç5káUÖUÙfcÑ/ˬ)³éÙ(ÿqëåOÓbz2z5½•wÝ!aŽR ï1L²¬ápR‹Gmç²˼†éov›”uÉ cª­+ÁŒˆµh˜ÊhŽK9©ýA?rR–¬­ò_  Q-ãmþ²`ù_ŸÂ–O ;xUˆ|«óVÁ÷F_ŸOŠqÍ8.qÇÚ©ìž×…Ìö'û¼ãúæG¿CÂy°wÌ› ¶ËüŸBàŠ¨Fà ã–·ªÀ>0&£ ºõí|­OÀ½å)ý2°Á•‚m•“×·¼`¯ ^ÃHÿ. jŽÜHÇ«»ÑX…Wõ€eÛN¸08€‹ò~\Óhøqed©òcŸå)élቴe^À—«éT»´rN£c¿ …jqZódÖçúŽ ¨-›ÓìÛÂO„aUje‡¸c¯iòÔO.h2Éß>.üòy(˜æn_Åéqjp窳E[wH=ûhåJ¨‰Ð¡6=cÆ’’º!*Ç¢ÒN2vûÁË'Œ)eŽIùÄ%¹Ã…ýšð‰ÝP¾®ñÉî†.p=wÊkêOÕƒpi›ÇZXû ª»ÕÞkPAÖD6fÕDJÕå~õùÖ’>s#ïÇFª[wpm¨—wP»øùHñã.zN´/¼7-iòÖO~ ÉeJæg~rµÊ¼W÷—oiÕÄaŒÞ£5¥Ëjj½ÎaöÉÏ#Áw€žøs•Ï“ ž–W±CvsxF2«¬h72y2“¸” ¯ó Ô›¦vé%VCŸÝþ€Ã¹­µÆQü ¾ªã«w%«º]W8®Í;‰½Êû9]L4R31ì­6¹®ÅSW•ÕNí;¡V¿É…X(xYåo¢26cWì¸f˜Â|ö’ù‰Ir3RöÑ“ámK³mžŠ½+‚·Å̯û€ýׇÔÒƒR–¬Í–u:4ƒTrØwƒs›ÒûŠHåò{Šåfc¹\vÓÛÚNÜ›;»"Èæ_¢Âøú}4ýf;¨üÈ^~c-fàIõ4Yþ”¾žy.ÏF‹4•Ÿ 6ðã$J aÁ(¶O­|‰•AêªÓû#£–2TƒÍ]îד>ùMNº–4™ÒXRǹ±çÜj$äz@Ng~[øP‰à¹OÝsÓÏ"4|ÿj÷€¸d¶7RÊÕcPTG`;&Ÿ f½ØÄè>45¹‚¬-\MþÖUQ†u›æ>Ì/¢ÙÀ9Æö 8r:mÓÓâ7½MÔØ«P±$ D ]ÿA@èi]£öýòEêò•6Ù…&1pZÁ>À °Úpƒ¸›ƒ±pwcÀ€à,9œ¡É….L—)ßìã>jô=‰“žS© ¬Ö ½3|u®ø ˜4ÈÁŒòE’þÐqïs_B·{¥8àò–󺶯–Ø1ídì—vr'nnÝÓÈCàPÿÕ+D8Z/ïÉ÷®b=ìÉM(µü§) §ÔãFŒ›Û$ SÏ·®Í­5^1詃Žžàª{à0°@×z]Úmܦ ËRîÑäЃF?v|¿óEgCÜ_ø ¯Ò%µë’»Ðl¿è ³'öƒ•jÿ |莨ɾ.ž]|W Ð9œ«c#¬‹ÏÑ׳ {ÓbÉÀkY?OA†dv ?mù$ðŸSÙÉ)i;fµ“·ö†âkÇ:TœKÚTGÃÆu?q{Àñ}JMQ¶ê;§‡97)óøD&¤Ð>±âÉ“õ{+Å£7)𒸺™î7zÂÈ— 2à<†ûÚL6:¨¡ÔÏ mÇ'ïù2¢]aðUÁºô^Ê,G4ÙiûmµIëAÕN:Å,5émßgŸO¡©íÉ3“Øx–ðkI¡){&[sײ¾÷Û˜Oïiʇ„o?úŒŒp<k>ßnDÏOýªgQ€¢K邨+“®œõ›l7XÇ©ñp•K`Uktï‡N¤Ö¤l½|äÂÞã¯Â!“}uGƒ¾ô#yîÖZÜÈ4µ6n“Ä.…`-棛x×ÀĪ^ÄÙ#‰ëîßÖ'{ŠqÚU€•âV5|кT©Ñ>r¨ùúr»RŸyÊ8_X³~ήu(r;ý!¾²$IÄä&oRz9xX'ÄÔÀ*kD\ÝŸû¨r"Ú’eãJ‚Ö´²~‚ƒAn‰iO†hîÊJÆëV+Èþ$Ç^Øà7D¸Bÿú' „ÐedA?yÁcG÷õ²0F×§6JwHa©™l™Ð/Ù•&™ƒNOièìÞ#³!ѱƒç_Bÿ&ó‹«øLiÙ‚ šADBš Š©ä9§ß]GÒ_肯T­ÚCÿ:ëÍèÂêendstream endobj 539 0 obj 1896 endobj 543 0 obj <> stream xœ½[ÉrÇuø8gÀ{œfí‹o¢)…©ð"ɈðAò ÀE`H0©¿wfÖÒYÝÕØD0ÔÌt×’•õr{Uø°£Ü ü/¾:ß<ýÉoß\nÄLt"nßl>l$µÙæWçÛgGÐ.¨­’v{ô¥œ 0NN‹°Ý×oõbëÅöè|3<ÿé›ïŽvG¿n¾=Úü¸7Ía·RŽÂ •æ‰Ái#“ÄÎx·õ™W0|ÀñÜno‡q§¾ìÔ£vx¾SjÂÅá›”Ø×GðM1j|6ü{ükg‡ŸvZ@Sï ¦Çÿ=ú>‹„«‹EJz“[«Ü³W ,ãw{[©R×¶ÒŒÚ8ZÍÞXƒ}ö0¬$nNHt ª·Ò¡Øzô6:‹Ëˆ1ŽQjX<ÕðÞ /wbÔB{燫Ý^ŽÎ;eùÓKËù ãpØÁŽHk‚“ÃǽW2ò^µio‘ÊŽ.øú÷ÍÑŸN*‚•ˆ¨ áõNÁ¬8°„_Oà…ò¤Ï«Þ‚òNñ‘®~{ñn ôxÚ¾U 'ðò¿|†E¦o—ØÌÑðïó?zžæÛã¾…àê0ž4nx“Ñ”7жØ‘°är½oÇËs—ñè'‰xUD<Áõ[Õ$r録OÂàÐgؤ,HF|…íPÙ*ŠÑ*m+,‚F£îgyðêð¿‚ô$åá±£‹1uÆ‘ìp|…Ð:iãljuUû<‘‡ÔäÀ$ššÓ¶XÒè/¢H•Ô”Œ»ÒéM2ÁòóIù–€®¡1' ¯Ê8ÞY4[û°s€_ÂagG@™@¨ÑZëûfÆhÁÜò@7Oº7Nj»ÄXò4Øå®Jk‹Z‘£‚5YX¿‚oV¨î”\’¨²ÿ²ƒІË¤\­uñ3Õ÷$ׂV£¥«æp…?mý êÖÊRß Øw4BKÍ>à3ü‡}Ž æÊ¬¯a “öT+ø–¡Õ´…W~^Áã òš4.‰ÉFªãs>öIÅT†)ˆñ çK²ÐX â-I1}lŽ#sÒÚ1TƒÌ ¤ˆÑSÂPR…Õ@y^X6ù«êßiKê°y¦Fcuªi~ÔÉáb²ÆPW„,EÃÕíµ…È«FÀi•¸h»>2÷Y6iæÐ=ø'/ák0äPÐób‡«üIàÂÝÄ'9x¹í–•)j~—@Üêáì2ísÚÌnrQAWtaDëä¨ù›Ü2¹Ft$OŸ¼>{̧J ¸ž!˜m"MÖüÛNjIÛ\3.E&­b1ifŰç®~÷ÌÓ"zæ]šûð ÀC,‚„a«¡?æ´Nbô XP<{±yúâÛ«×§›§ÿÙÊÍÓ¿áÿžýðWøxñ|û‡Í·/¶?®Â~æv ì!·Ñ§…I¸_™QUÛm’kgpÉ.¹Žä˜ägW,þöÓ¨ æÞœ(fò‡å-CΧÉÒZ#fAý4Grï{¡xÍnÓ ¢ëz4.mhýþ½x»Y“•¨uL²r["g .S쫌BYÖ )·I¨ždåØõ˜ó‹U.´åMß+(êžIKæÕW˜—mºVâ~É«fל}IÑÛ‹œ<*çk1„u\F¼¤ÁzÒSÙâ„ɺççav¦&<èVY“×N*«Û°tâ¬yUbþͦï…ä\±bõP?h0È÷Jš4TIĦ é|)x}ÍdtÍa|uÀz8äJå3Û£)Â@"’W’0¨[ॡ†qØÑ£qå딌0hU}­Œ¦àòèb‡Á…K¾tÑ} -8‡¯¡X¾¬å‚|sþì_–”¶Q4ROBò ò•ób#¡^nÖðec¨¤h'¦ñç¹Ïä­Yõ±p°,GeU) +oÿ`gÕ0"6‹¾1lð1Â8ÓÛHGÜ¡ÚÎk)æa² ¾mT¡¦½0\C+[î¡•}o„DYÛ¸ÚfÎ%ìØB t €zâl>#ei¼s¡›ÕêÝ'ÉäE™e$Óý(Æ3ó®@NÍ}¥)†KÅÈg±h k‘¯@&u€¬Â­šûÖ0kRj4#(»!¿­Z¦Ž1Yze†ú`4bô®c¬^%ÞÆ?áäy+(— ð+¬&º4$,|äEeË8’ÅOÓ6 ‰'ÝÃVAbŒñ÷€l“…0³L¼ÁÓt0~«ø㘿‡µü³VŠ1O–îRaS¹le"0ÿ‰‘é C;Ï̵ •zÌY˜6)õ¬ÖÄü?‘c³ƒ^P‘ûO猿Ì’Ö–˜€Çj ‘‡ML)|nv”0+ÄQHÏF›å‡ÿØd‰Ä*ƒÉKãssÖ¥ ì»ï¡GÕÁÊ@9¸ºr̵˜ÁpçÁ†oñÅFG6ôŽsowsm*gz,ƒ¨@,ñŒT_+Ø_ +ójA ‰Tž÷`Áj Êë.MDÇMà×kÇY¥’7p‘ùÄh~ÓÀ”Ý9¿À'D\²³)nÆsµA‚in ŠV+Û úþÖ*âå~ìr?¢ÈûYnw;à«zÚŽÉÎ,¨Ÿp¢.zˆÑÝÈè$ÊÝHøÊTŒ­%ô/,¨e…|0à’]þ€m¦„²ÜYAÈZ;e*V.¥+EÖ-8Êó‡rŠ®Ú5äØ,6yÉn±Œó•×k§¹íM±›¹¬Ù¹<†QYlÂWx_-t€ô~õPLˆÓbe+º|…‹ÄÞë²#n˜MçË/êð¤ìTß1ÿ?ÙM ê•H¼Ý^Óu)¯ ·<Û&B3ÐV+YÛ"<b4àìþ`;¸GZAð=)Þa"À‚šÃ\æuÍ!Ù©O°i( W£‚½‘%¡Ÿ.ŠU­›¶l#‹Ëi9Ue¹ÈY#À ±¡Nò›&¥¯¤?»”VÖróeÛËÅ1~©0ØòèdæäËRÉÇ™¬lp.1Vž‹R/•br”6Nû˯âÌ4S…öÎT9m¾Ãm¦å½¦I ùü¥T·rõæDV×-—xûp!·Ÿ°üÅ.à¶µ&Þ·EÚ¼³K²Ù-j<©¤;[™¨`ÓµÔÃu:`ßk¼ª?/.jÉP)…/dýµ+=m28Ú $â܈áÊ#]–/oO«×ízØ0#ægsxCѵŒ7Äi¥uØÊI¹b¶ØÙ95¿7›®SÐóä­gËÆM™…Q3ìïk¶sĦ\¹Z´Jáâä`ë|îõ¬+ݼÍÁÖòαrœ×ǧüÜ€XD q…=*êͧ‹¨ÔäMQw¨Ü±±^ÄÌÙŠ.)ö˜ð(æÛÞÝæùžÂ§^íØ)#ÓX=Ú1kM÷(ÕœD˧YY üVX‘¥y ^½Ì[€ºtè»êQWaõ09ÝG2óç胘]PëFÎýcxh<Ã…Ü’ýF7€_íê}äãYvœõ±LŽqŽ•Ûܾ–mõ¾Bœþ°;—+Á¡D½áb>,¸æW”ò Œnc•ë­Ä§únx]åRñåÔ9”¬âžî,sá™í˜_Tñ¿:+ØIA–?’¡g.°Ã+pžNåëæ¿ì⬰:fGÓdºÎÏb±9?nþ0í/endstream endobj 544 0 obj 3471 endobj 551 0 obj <> stream xœ}Q;k1 Þý+> stream xœí\YoÇ’7þŠÍÛl Žû>ôbËÎ¥À|ȃ”HɲE/-R²‰Øÿ=UÕWõ«UJ¹`XÎôQ]]ÇWÕÕü~#F¹ø_þùøâè½ÏýæéÕ‘ƒ‰NÄÍÓ£ï$µÙä/6ž@» 6JÚÍÉhl”r2À8Q8-Âæ¸>ÕoJˆ›“‹£á·Ÿ?øýÉö䛣ß}v$ö̱ßèœr8O"Rn¼Ú8¡F«p´/‡¶0]ÐÎ;|½=–£ Zëá£4^ —ø¨½z¸Þ«Qxüp¾…—Ò:?¼€—ÁÀað[1*•s=ùS¦ÀŒ>x‰˜8†ÍÉÇG'¿ùrøº+)±3ð9ì wˆ:=<Ý„ס4qÎ KÂpÒ‡á‚ÐÆå'ýðì;jja5 ‡PÑa›áXFãðì[(+¥Ó¸\ÂaŒ¡…JXÙ‚«&ÏfÆõF;Z‡“m€5ie‡ø´Ø%Fí‚ö¥wÎ^Á“ÖøÄ—`a¯`}‘øbõh _N¶H—†®@[#0ýr+qvœWÓÃÙÖ Ï¶Whaõ@UÃî <ûÔï¨EíMMú{Ã2 t“°zd•FD¬’ôõæ@þDh#MþUc{‰´™a‡l€.!¸ô ñ±L^>í^ôÔùh¦€Ô*jøß!i7WøAÑ2ð÷ïʪBë[–}µ-tãç[d)ˆ,÷É4[Wky ›IÑGÏ[ƒó6 §yÒX#`³3!ÔA*\¯†(Ulôos«ò)-x`#Nœ·/(bÀÇhÁµã⎥­}¢5âvܤÕc€wFÀÞHK¼#ŽŸæ}¬¦eS{!†'[E¨c$–_rñzŒBs™M¿œ¦­ÂÖ(#/«€ÃyL§®ÍHI<}°•(æÁ‚X—_à€#†oÔðu‘¶´´ÛðÍ$:êÆðË´ëL ,D G³Þƒ_•#Ê~HÌJKÐS)ÍBÄj%‹ 5é¡aI¯Ḹ«mÙÂÝE¿È éùÎþˆ „ÐÚ´Mf.ÛrzÑk‚|¬ƒ 棒aq´a¢‚µq%ŒíkK¼l’Œåµ“œH,¸(Òó]±ȸ—()U°Š¤ìhq»}ÓY’EÒ§afŒLŒ|Î-ÒDl#pÏäLèK3&o]$•FeV³¬»“é—iK$3B(8ž:£àh!àaV’âBqѨÝ-žë*Y¡È£¨ðï¼S€Üõë-kVd1¤7\·Šl}‘†‰Ð…Y˜Ý5©ÐˆÎ‰ù¼5¹A.û‰X3á¹äúVw=o§âWå*T]¬×¯Ê>“^ЖTëDÆV¦í©Öå_y™\0ÕdíªÔ0å§~ÔüÑKNôL¬©&í»6ÝiqF8åÛ:z×4gÇD®Š‚Ô-Ï´àrl²D°ÍÄ œe—'Ó¶ ó,ž÷ªPk;©/ˆ  tÃ%ÍTg£š"nä—ѹû×Ê–Ššx»(q…1Zp} <ª™ì}Á‚O£­¤IÌh÷† VNcµ*QOà^©ÎÀ[æ d‚tT¦Žóêµ}5d†&ÉZèÀ¬³ƒÜGô€¿@Ìç̤‰N-´hû„P°4—ØïGmýð áŒ&# ¤8/L2çÀ¼Q~@šàPLÔ轆7iÜ¿8,L…y}4².ÃhÈç£ÊR¬ò¸“0‚óN%§(¥6Ï¥d¥@Ãziƒ”‰ž„Ø <‘ úÆÑÒÿt«a_QÝÏa07H6Œje?i¦ÏÁ\mÖD©·z ä*;º dÁ¹ÙZkߣðÁ=ü"3„G½à$*&v–Ôº¡ÞKêBú›Drž:}§Îˆ€˜H1œâZPSm`ßB²2;ÍV Šƒ»H~ÍéøÂeôcUÆW ÚF[ð/Çj‘_ft¥×ÄÀ E>Ð%îpÓñÈL\轆ÂÐËu°+ã-X«ê‰ó ²ÄE1¯· €%m-¹œLbkvÃ\ÈyiÓŒJ=ZGÊÕ “QJMðñ$ŠY"2\‚‰ ­’$÷h¹u©6–À`"3éU{_%ÄU ™P ‹„ظ*Vï— 2¿¾!–ƒxñ˜sÐ.ÉŽM~ÀæÙ( ?@â$!ÉÊðUCbuƒ«´ºà_匯‰á¼ÓÀÌÆ7`×ûކ(\±†Ä8탰xß뜅¼,ÿ”!’’•è(T£ŸÈ¿ÈJ¢ó™Èß/aûÿj[’àȬHugšÍ ÕÜ'î0\Ðj¼k€– x4§øÃÌå7-K‰È×åÀÍÉ˺N¶”ÄQj‰_°ÐT­1l2r-oý1y3cý¢ø‚‘‘ M ©õ –\æÿ«%«)£‡¬YÊÛ†Θ-* {ÕsÀÈ*úµm†&¾¨.ˆë “btõV‘’ÑzvrvÁÒ Í å„·Ú„%ª=jÃÔ\k_£ê–‹Üä¬ËÛ²Îv!§‘Èx/!F†Ø^1CT6-·oа¼LêôÚÖ¼-Ù<66ŒažL0Ã!) …¦ö9ƒQ%\#d“&û#4u†˜’§%íÓ|+!E2¹èœd¬dEdMPPL“%š*ýDq }Ñýº¡à®cóYÛ`–4/m¿Æ!Â5)\Ý¢ŽÝjèšY–ñ¬°Íóxâºô_Ø´ÅÓ+U)kúˆ%èvÍî/‹¯¢D÷ab6WSga‹‚‚3u+Äs¬c„é>.¹ ÚÛdo þ©9Wë{Œ\R(]jk!Ÿƒ‚ ¡ÞÜåK²‘Ìb3r&:`ç  ß΋U ÃhÂÛ2 +¦§Z¼À®­çšq0¥‰ý,~h­ vÜi(ÝEÉÛ1f+\d’ãƒÌ/ƒ\è L²Føw ]d“QßÒŠ˜.Nºm"ÅÉŠÕD×DØrí“uãÈXa;'és—Ú¦¤‹±·WÞM\·$”YDð:0Á¡yEî/Š`:¶û~£5ás±‡R& Û×ZWž%~øð轇Ÿl®_¼SMäØ7JüQ<±Z^µœA_¬¿šˆÎ,;ͦ·Ùán°êwÁš@<ÜÂÌbNä"˜¥"u²¹F§‹?䇴°?¬Ywyó3(ÕÅüÓ3¨ i]2/'¹¹Àꂚ$vºDÄD—K….qˆþÎì”ÀÌ `øW$"Ö,ËÒÆ Ê„W5gÃ’ŠŠ.Êb2‹ãÄ®{æL¾>Ô˜Lr°q϶=ÛïägV$W9õåQ{bô æ§ÊE…lûÒƒc“*¼KŠ™÷ =v”y×ð>i ‹ÃŒ1Ñ. ? eÆ™çÄD§Í’Av˜*U$ïSM×ËâÛ{ZÅ÷lòä…Ì].o1Z¦ý¬S»IwDw–¿Ÿò3îáç7le·sÿ¨p%dÕÅ;æd»©çú^aÓ=sš÷ŸÉÑt  Fh±øBÓ¶þˆÊëTú Þ± ²°è“À¶ˆ1øèËøé2H‰‡±$y«T²9»%Ñ•”l¦V¶;£.¯®Àª8[­u>E)Fuâr³­|#Ç+!è6·õ»Î’¿•c€»ô»b'óˆ ¿ÿcÝ®ã>=\ÀÝ[¾(ÐU´“Œæ\¿–avч 0è !È&­]1I–ºMíˆÆÚÓ;·¯ Ìc#ó“ÓõÏ2×r5† ¥£6>íNLÊ®‘cTÓYÑeJ+G?/ã*ì| Œ÷ÃtÁˆ‰Ü­Àt,©bÂ<­ç¢r’ö¯ÖtiÛêIºjÉZ¢¹(\tz–dË nÇX1KZòar ÚoKˆÖª d»-ÔùÚtš7aÍÊÅkÓm‚Ê!·'FñËXøÖ€É`¾?Á„*pÄä©Z¤3üÎz Äd0a2™+£+–SqóŒIS÷2&uØ~[1Fi\‹9± ;ò{Ó›cïì)=6à飛ÞÐzÃp?×ûz[ªX]ë¥û¨¿–“Ž¦Ð¬ž¢¼~˃«V¹/_¯Î.%nöê³M×pÓg%Â[“oT’Y/2¸=%ö6c”çRUcßêajú ïx%ho‘ƒjè½+æÈ!Ö㙾[:Ðxçƒç2:mñÉ•-gï—OüºZd–Þo:Æ/Åâ][Léö®|ªØfQµèôðµçñS=”Ò[ŠŸ±œÕÝ¡b‰4l³TX¹PôPÝ>pvjÙûÏ4°0¯WÁ:èÈ îÍ[étEM/rO²ª°ði€D´êŒêëÏ›Ã^,;°ÉéÛŸ^YqÛðâG÷Öôp=’l‹/úû ü2@½…ù¨ð1ÎJ¨gŃ«yÅK…)Ã]Cìxá,ÚÇ=gí|lVxÝ]ScÖ EïÒ.Ë“L=ª…ùßos™/ÓgבrQKýƒܽ×[c¬–|á4í ËLN“Y|ãËL /3™%At‡Îë¹Þ®Ðˆ— pÂZ¤½ëÎŒÄcWsƬ é`U`ˆ81¼_”ŠÕú·qØŸ„(êâf+µÌ¨pv2éã§’+ð*¬Ùô±•TT‹·ÙÍ]B+I®ƒfÁ«Ü©,Ó±F»7µìòÿ'‘ÝIdÆh+‡X1 {ç‡-Wu›cG^Ó´÷ØñNO‘ÞOõA Øé×850Ž˜ïèðÑ`ÞÛ¦~wvú(¤ws½ûãGý/?–V¯ð0a„éýÑ> stream xœí\ëÇqòñþ‡ëo»wØïî¡bÙ’,[4¤Ä’Ù(y¤}äžîHQ´£ÿ=UÕïžžÙÝ£î(#Á½Ý™ž~T×ãWžïVlà+†ÿÂßÇ/NîeWç×'lpj4l\Ÿ|w©Í*üyübõñ)´sb%¸^>…ÆJÃô32#™[mÓ·tO0¶²luúâdý›¯>úíéæô/'Ÿžž|y–ÆÐpº9Žã'ÉWV@O»úfm6[½fðñçÓ߇øÀ ~b£3Rq¿D£,W隀¶©›O6z`Œ;¹þl-FÇ…[´áë?l¶ïðõé&|ùt£Ö_m¶ÂðÛ®-Î`ØlPã Ÿ؃3Ø*<ó½þ]î9ßÀ1¾H¿¾ÈÏ>Ü(ø¦¹Xÿ;\„‡·ÂJ¸"×_Ãh­Ê6~rR*˜?ÌL¯?ßÌtôizú£j>Â9øUöô_©‹@¼˜ÿc"ºff›ŒcƒQžÄO¡“õKüø;~<Âøñ ?~oñã?žàÇ›­Õ¬¯ñ÷›ôÜe¢n=sDêö?8~ÜKmèšÈ¤}î6ú× %‘_ÒÆ­ÿ&Ò¢ÚÑz˰•z€îG?µß"V{¨ñáåëʈ<ÆÑÈ~rBøFÎŒ‡hôé†cj,{ƒuE<÷}ØGݽ #€Íî®"ìÕ°Øøà› )\ªÿÏýžã3 YFá¼} ÷vÂz‹#ÂuÖO§ hBOò¸ÐÞŒ#Þ Qn,Úr/ øM îÕ´ûþ'±@&5XcǸ'5Áâ]ˆ1óÙFÒ¢à{¹à »¦Ù °æû8I«…;l˶va_Elû« ¸GÖq¦L—pjè9EAAZüd„ŠúŠÓ|‹G=_>Ý"*þFZÌoÎóuiÄñëˆ{Ë×;¥Q£äűÿ{\#|(Ãð ñK…0?Ìøhᜒ¡€,Ò0ÝÄ‹O6·\¢é³Qh”¤Ð°G?D™eI5HèËJÙÝ5ˆzW?`S€SªNë=q$™å ¶<²Iô$ê*î@üyU©sé¼—‚w® ÖU¥8f!9 [ÎDÁè¨uFC¿õ¼JL_Ës”F ñç«jga&^R.êVßÞc,$ïl;ÎB…n¯å[~ã³M±ìð8‰Ÿ¡"ÖŠ9öuP±jª„ú §ÄàPÃ~\"#q&-<*Á•B=)c€o± 4|·±7äœÂ´ÜŠK¼âVʃ¿8ùøáÉý‡_¬^]½~rrÿë?¹ÿ~|ü‡OàÏÃ߬þéäÓ‡«/gíXG˜ã¸4ÎÀw†½ŒObQL›Å¥6¬X[`# Â3bY#øarµÓ¸ ÏëNk9°h<¹‰m£-òjúu‚4/ƒvŽžßŠÑ+­ËZ0v¨xÄÆë øZËJãô(é2ä ¬NwÙ¼º<Ã#4F !„1Ý~ð9Ê€RR¹à«)¬ZÈrE )$FKÓIZ:-Lè¥È7*b&TÁc)ŠÓ¥+Œ@ÊißBTbêi¬Æ©»8dæã>Ý­Ãuºs(…Sa¸ã3cÈŠ¬a´}^E[Ÿ¬Ò½¸\RE † DªjAv7c5h!Dac=§j–vÁ‚‡d•QVIõx=p5èœÓHcVʈ!(ŽÃTÝbLÕvG”XÌìêe²va‚¡U0¬?(/K´ ̨S´WF.á¡4É m–á‡[Õ"´% ™ìÚ”õ8íDŸ½õ{ƒ‰”Ò†Ðj”¸Éx®=¿ m^A¥”X†ÑÏG`á++鋨#ã¼ñ8c”GYfåVP¡ðzÊ/¡ Tê‘>£$K,#@ë´Ö>ŽâÙ¯ñ@k½#Œ|‹ìlÙqÑßUn ij—’ªh\²Æ~ÅÄa{f—>COa‘¦c2;ðNœdßyLª2ÀÌ0³EküÅ âü®yœñ4¬Ì<{™ü¯ µv^êÑ;]Ø'eÇšÇ[„}Æã L•°Ï{A öá´Y\ÊÁ°ïx÷g?ê›ñ~ì ë¶;g½çK\dáíúCe‘¥à$M&ùå=O¡UÝ 9ÂÔösŠÁ…UR2ÀY¡ Êa¦µß50€sU×÷¼BG¤‘@‡‹®P)^¨L0 “à&ðXkÞ¦Õý%_—6cëáeïñ&¿š{‘¢bÌȤE½ž®&—usdÕUÕ -TÒµñ'pÖì?Å1Î}$ 36/ºY\mãQJäXÔ4îtH\ …ŸÛz[…lÑ4›jзÞYæ|h*q?.¬}¤˜T*&¡æ¬‹WöE´õáÓOðFÚœ­ÈšY*›ÐŽŽ‚OR{g̓媒ÄÒTûCXú¥ï¹µ9F(•!!x®i—-5B@8Bû!r²ÿÑZ‚dŠd-ç<$ccD-mUÁÅò¿ÝÕ´ÜáÛHJïBHÍfaI%i<"Ù½¬)[îtÃê^úÅÔŒóÑñ+>q úìžc1Œòy"g‚’gQ‘ƒÌ53Ñ3øô‰…"ý7š:h'lřǬ˜¡7?—X»~™PIbMé÷¡Ñ Ù’´ªN0šçí £<£¹PF×…HWò;tNûõÔM0+A— FÚ(Ü'× Ä¥àVhWú•C[ˆ°+hJúàYp0œ>ÈãÒ4±€]fÌ Á¼B±˜»$–Ú1vïì>´]GšÈšFÚýÁ’¦èIMl@¾‘ðÁî¬Â°Ñ.Ç£ˆ.1ä-¸‰Q‘m ZVéõè¼&Ëhù"Jv( ÅÐÃÖÓÌ|¤'6z® ×yF 2ÿóÆ[šp=ú½d,„ ýñ*u’'“[z¡Î4qAOŸ•6Kˆ:¦¤8©ø^ŽEçM7ºTkµ}‘<`_ÆóõfD¨cœßBEV¹hº{“‰Ö˜ñ+‚|És øMkœIÞ8“•Ñá·fŸDØ ¡™Ì&áŠÍ iæ8»š¹¸7‰f³þ÷>’ñ†dµ@¡+´z‰Ð£ú*òésâYa~Ԉ݌ºA¿‚—زHTѯ8ƒ›nµ&Ù+øh‹Ë,Òr[™òrÇ•l:KÚp¶Ìå<µ~*;°N/Vov‹4§¥™EM^®×úÑwµ¯ú%UUªõ/ÊQb e]Nˆ%¦fæfÝÊÂxeR»õ ?¸X鯒 ˜kmK7F ;Er·¸e×?×-‹-•Ksî`÷ŠÒ¬åí»Cœ@èÊ&‹ó ß{´wÿ/0O‰Ãè«’® nOƒmqÜZÀ1p‘°@rß Á,êè ¬He%€trû¨Á ¬fhòƒ9#½”A¹—‡(¡B¥1,iZ2nÆLk Ž7nF{£Ã»Õš4&¦ämtÙ¾ßèò$€8J LKejH³üx£êÝÐw°¬ÑžÖ+ߎ€0@Ô€Tt3B…ù†.MÍÀKb]]T½Tœ©‹ÃÀ[keŸ¡ë~%†>k¾YÆC™÷w]ˆ*ŸTÚN7•RaëAoWseã ÜZÉFKØq°ÿ²4—ÑÄ)ü¬&û—‚²ïTn€q$±Â´œE¹Á^-x|¹Ô¢éðª¾E‘5irYߴ¯ÉïûâÛðÜ/n¶ÿÑå¾È”Á˜ìîBøT«à‹¹1ƒáž*šXiâý—ÑfcQtUÀh†”äÉ•#¡ÚÒò~íR½B &)V™_eŽ(ȃh“·.1ËY#–æŒWð Š–•¯)*Ô3ª[×0_ VÖ5,×´„Ý_¨?*Q^kIteÊ ©Ã뙚V^R¤ÞçÒ¹Õ6†Z â;k°ƒÀƒ™0 -ËÈ@5úÇhkßAÿ(=NÆ üŒÛ(xJÝ69„¡Â¹šÅÒî^*nÅ»Åè}œ‡ãu<4åTš Í×`0Qa‰~å-³”¹3ˆbo¯òÔº48Î HÇÂã²ðæNjníLŸ“’¼¦*z«½Ê~R×–÷òhj€(BFÕ¡ŒîM ¾ÊÂD,—ô¹•â3Ž–y•öƒF”1÷² ¦ûb&ZûdE›£yU×Ñ_Uî T>Ág|™ÅBÍ ¶ ™ÙiJÒ\+8ŽÃ\%ìžRAí|>ô3Ôÿoº~ÇlšÒª§vIPŸ'¬—åx&ö¥1èå#ár1ø%…üA8øêr)k7ø%©ŽÑüâx<¶sFtOøKU1ò„K®+@úBªã`µçÝ*š½®Üð:&&oê¬÷ÅÄô õä„ÊÌГÃyéTÁ7 ‚V2Uo)6Îïsé0ÑF‹»Y ˆsp4„»å˜íPï%f‡â´_¢iuð 6Æ á¬„ä®ò€‹g dÿºTYßzQ[?8*ª \ÿ€C(kx_½5Ñä&d+´ÍÑp—x!7Gfƽ«¯ª¡CíôA…tþð€ªCÙ¯êÁê"¤ÃT¹ÆØ“[q­Ð-¸ÅT¹Vƒ‚adÊ5\ö¾aí æÁ—Ýwlõ™®‚7Åøn|LGi ö½[£¤ 2Åóy¤ÙH¡0Iæ#…“šåù¨¡Ä&ó'æÃŒRíü©‰p|f¶-_üK?ÊWÏ!²å¦,(ϼV ®'½ÓȲójšÆŸìkƒnÁm2u‡r{NòM°–xW¹ËSÓé5§æzER5'¦›cÏO¼ÇQʯ ’®´ÕûƒOn †ø&Ú»ÀO°L]Qñ’¶„Ø>Ÿl*(.»Q <¶,½uúöIìÅý‡ÇSôðË“ÿ¼øi5endstream endobj 562 0 obj 5142 endobj 567 0 obj <> stream xœí\YsÇ‘ÞØGüŠñÆÁivÝU’íµ$K»ÜÐÆ®d„ü ;APÈH4cíÿ¾™YWVuõࢼ~p(4twUeeåñåÑóÃfžÄfÆÿÒ¿/^=ýÒm^]Í“×ÁÎaóêè‡#AÏlÒ?/^o>>ç¼ÜHa6'çð°–Ò ó„ÙªÙovå[¹'çyãæÍÉë£ãß}ùÑg'Û“ïŽ>=9úâh>´†Ù1Ív–qà­Ò"RlµaS®9 Ó{œÿëc·Ý™ãi«Žeü²³BM³0ǟõÿÞšãO¶ÒÂ@ãŽ?Ú ¸º“AáDÇ_mŸBšn|¹Ý©ãgð<þññv'h‚O·úø÷0ñŸNþ3‘ˆ» IŒ|ó5…"‹„ˆíNÃäFÈ8T*ËÇî´Ñ8h'ݤhËg0òixƒÿ‹Ïñãü¸ÁßâÇ;ü¸Ä—øñ7X&xد=¾Æ¿ß–qøÌ4ÏB )fƦi/ðCàÇ“ò ]JxÌo>(wž—ogõöY¹xU/þ-_ÄÃQê͎˜àãîþx\h?/$ÀBF:_$ÚœéK_[réÙÀg‘y5ûnM³¨™]ªe½ÿ׸JÃ.ƾ`¼Sï_Õû£ñOFãå#çgãÿ¸-Wqª9ÐŽ~*÷õÑoãW­<^d–;þufI@~öeýzS†Ñ¡Âq’°~~tò˯i¡(l•PÕ×é¤óÅ_×C¸,ò|….ľ*B}SNüWe…߀ {Ôcå(޹¬”ž7òžö÷×vÝÅUâövEhµÊBûmVÉV¨‹Ê¶5ñàN’Ê4"‹1Ë¡ðd%]üs½øª\lÏ´r"}ûU½]¾Pªoå¹lyÞ(ÔX`ñk¾üa¶Pú{»~ØÞò×ßlñD•V“ÏU-T¾ßn3ëN·O:ÏŸ•Kí÷ïåõb œ—qƒ$QCî¡1 /‹{8«Âðÿ~Z­æð¡}±üÐ×EL‹Ã(‡›äíOIæ{¯ÌäPúÄ ¦S‘´Ï€|ЃgŽlŽÈzZ9»ë*6äk$ÐIz'½!8ß œB>Ûôª0RÛã8ôÜ3®º‡Ò¼ÅîÑ99Øløv‹N ·ÿÇñlÞWHŒǤ‘nMßÒ½=óvïpOŠ ‘‚$h"ˆFá À“6àáçñ×H`œY‘¨á7i t<Û&´@’€Ë éÇСœ€ZDÿÄÿÄÿøØáÁ€áåäE2I»€Üæ§›Yò*¤´”¨çY$ãÃÌÓÞY OB×ìd+*9ÿ¦,T6åúQv\e;®)F#;îÐêÉÿW;Ñú³Ùr‹G°nÊñ/T³x“D¡²\OªØnÜl,‘k‚LÌYŒåäœKÇ)!hgϪüÔWÛyRJ*eÓsFo€}Ž Ÿ³“2Á9IÀ>óœ4HÝÒ F¢¢'¿iž†@[Ùh?"êÁkJÚH<Âȹ¿D‘ñð”.ÊY<Áç$A2¯Ijηò®B’nDRCã…BEˬ¸®“¼EÙfðƒ|±Ü+ ̘Ež¦F"j$Œ¸‹o¶ ¹úèÁV/Ï€×>̤¸ÚW/h0Þ}»Í°l7K¨~¤ÇHÍOVÐäi^:-tðŽ,Wsö»:TCGš•ŠvÄEu¨Ú’Ï-OU8 d@)ïL$A»¦,mÿHQÕí–uˆ2„.#qiɽÕÄ‘¦tæw®笖 !(!¤g$u›¥ª‚-rßù%8ÙL`L{ÚJ"—/Íaz©2H¬ êþ¶Z)ºUÙÞžÐó*’剿äÁ4YÑlѦ¼—[3‰9H\ôQãa7±™0ÛÂÀ6@¾%ÞìÐN)ç3Äÿ€çðâõÑÇÏŽž>û¯ÍÍÕ/žþa#Žžþ~|ü?ŸÀ?Ï~·ù—£OŸm¾X=†žÈt ´Ï6çð }ä ª6#[ä­ŒŒÔ1 8gwPØÆTæì ã$` f¯"çMÃ9kœ[åœÖ€¹äßsZ[@œs× zÞkeÇŒƒ §b(´dÜRèÇ6í²ávì{úl›ž¶MŒÁ“°ýdk˜uB3}•ð®›)T´×É÷%=̦<(9Ô»›ºèìT'd˜_¹NOIZØœï4Ñ “¥Ñ|?\2uoÀâ 50>‰¨HEÚ%^fzªžœèŽŒL¸L÷ó)ßlyБP#üròÙÕ}õÔJ»æ 8%Uíã4Äíàäø{ßÖ.òZmÍàÎÁsà«´R«%"Z ›}íGˆæDòrᣜ6‡ƒ×­-"ÕŠ+^)^ØÅpñ€Psa\mXú¾8©!øóuò±àOM3Às‹Dl ì…Ò‚³z•Ut¢ÉH­ŽÒ*yX·DËÈû€ %Ì™ÉÉîPÃEK7óc½m–¤bÿ^mÃa¼¹³CNq ¼ï`óMc¨Ò×ʱa„Ð\W—@9VïüØtšs9èýyŒjà ×ì ‡­Z9p?]ÁeöÊøýŽsÅQ‚Í0&*KZK<_EEdònÇ놰®Ù,¡­;b¥òÆÌºÏÑ¢jmœE±Ž¤Kž}ÛNÛJ÷0¤t929ûâ ÇtéÉ2XÐvh¹'[5Ú%‹Pžº[ž„OÛ¡•ñ“åS¾+Vó"šNžiKОG²?ϳQ­–%z?£’9Ù Èyç˜2¨ƒê²).¡†¶¶<šÊ!ó$€aó°£Ãœ„Æè„‡ð¤C ¸‡ ™r¿cæ‡"û›2IçûÎ¥äÔ¿‚¨2F\oi£TÜ ¸Å6ܽÞö˜1Ó㦠' WZ“F !Uñp.óà=Ù2}/}WQ}2æDE¨-y°"}€á†#Œc¥²ðÂÊi1Öv,K”3ÄÚÃ$¥´+›,\âÎ{.DD-ôLäOËÜf'Ìä™èöÔ/l$È9­¼N›ëÁ°±JÑÊ‹*‹¨ Ee¿ÍÑÖ§ $RÚpÉÄ X’\@è¹–ù,ò½ÚPùéÑ ¡MðWI5¢°“ZfYƒ¤{YO3ö¦›@'K¾^Ïš´ëG¦O; ;C,ë9j@£6¹c§õÈ,)aËl1+‡KØ('Æ X‰ KPIÀuI“«É~Ó~ˆbŒŒqÊCåS“²ìC•2ã:¦ +ªnöP¬SõV <ÏüŽåZA¦ž•_ªó£8tߦMn/ÔP¹„ ûí8§¤l<23"¯ÚLùsfF€0¸ a “³Jò¶´H#rnÒ" Å™9 ùÃP\eN’jð§iÖØè¹Ò°ïHÈ‚[Y?éÍwT:¡ÄBöAô´–3á’©ÌxÏ·¨„¢d«Eç£lŸíI§*:@=¦ðHÛT!ª«×MÞî}àÊ@GvꪂÈV£®£ Âí@²ÙÙ²¨4Ö9½8.Ðyç|ñn9ׄ¥J=áéËüL3ó5Wi/È{ß䑆ðJWy™Jò¡®îÒÞDc‰²”¸›‰Æ¸ÚÑ”úRÄ/yf§bèot¤j6h"š]ÓþHW4¾j†>>Èsbõù¶=åã~%qr¶rˆ¦M«Q(»ÆBÓm,Üw+ÝKYðhíªP­ý_+•Fs÷¬”.4É€¦¤)oåºn°"q]xP…±s½s½Í¡I1y6ÿê$Ìây5{ó³æú%D;Jâ:Ó|·d­’ô^M,½šSên^ ”¼šíЫéꩾ;$> “‹Šž† ÌŸ»<öVXÍL=ÃäëÊfú8WñõÆkñz5ˆ¨D¨n2̦IÕ»÷HJ¾÷<Öö16aeþõh&> n¤R§ï’ˆ“ÆLÚ…Î[ß-¬•fê@#WrXjWòyçŽS8§¬ï¦D 9XˆU£ÙÕ6‹.Å‘˜óà°mmv˜÷ F‘šË¶T³¯ y&j9åœrô~º¥´¥W;vvÁm“€E¢-;m„¥$ÎäL°Ëä ØÀvEüs“†ÓÀí-A=¡¦ôÕ<)Ȭ£bLõW[`OÎóûW¤ÜR 2PbºÀoŸ².¶¨Ú¹¯ÍºY®°.È¡9—6BïÔ"ïÔÒ¥Lå8¹¶VH†?éèTߦƒá¥Â7±à†¨ÕJ‹"]Ù~Ð\…™‰P’L<5¦tg.Vó…ÊSà—IHe˜/Ô6ѕţ‹çrn&OÐÄ…]CI×G+ˆ¢'¥AÂШ‚êì£Æ-ûútæ[6qÌš½(õ¸A'Kää]r.´¿Yeè,êž.uZ[pÛÎÆ‚‹!P]-JÏ,p)XìY.ŒEP\½ATGï6Q5ÚŠbµs_Q¨…i'jݪJn2Q¬ë¦ˆˆŽm“§)¼à½ >$ësû9-ÕÊaÎ7çzn3ai†’´(‘„Õb«û$t1}®QÂÚè:TE“)‰`êš]Õ‘ÔæÝÕo)^Ÿ·ùc&öm´" —ËÆM¢%(-—’hÿ¦]¶µ øæØK]úŽ·èúÈP½ òfM _ÍS$¥ÌŸsÓBÒƒüè¸FÐ’²‹³#‘^46¥Yîߨ„Å¢€ž7 °Ù¸ÜÏ"k™T0S´_fôP§ð ÈÔGÁÅê,Šž„óÅâ]óD!ØštÅ%]RæE^é# øÊ Õ fCµÐç‘Ã8Éz³Šhê¾ã~œ¤eqÔéмELÛ]¼EªHï·Ì¯od—Ya,Ëx¼j̯³í³9êÛhlÛÀŠubœA«g$IäåÂÑêÒ10èYÌýw6œ>ä$÷šáŒ¾Ò³¢³£tƒH6ž!ÙŽß7*lìzÃþª³sÿçOzüwh±Ÿj7l_×`y¬×ã ¦HøÌO¢à¾ÐƆˆjŽ%ÄbÛ qjö%9GfÑ®¦Æ¨bQ²Ýyp1ÅbÙ]à H5áu·N›¸É,À ct¸+mé 2ÙÀîÈÚ¿tYÑÕíR°°èVçEwŽ­üwoHAgâÕ8‡œZýUu–ù†I^ü¿vöxã´“oòò÷ìK ¨˜»½“›ŒHÀß üëQÇ”5M²êbŸÐ½Š9nº”S“\~“°ô¼†±ÍûO‚Ó²ÜûžMràu<2D¬pÞÝh»ÉÕª£¨ó žÉt|[ÒM°9.ÉÊNhÕA—ÍRï3±&y®Ó©#<è’@î­W²® ê:—륛x”,ÈÕlÛ)íJËnSÕ)™Ö.“+'ÛóLØ;ò,¨’ca¹šb…X­þ¾N—åEr$l]&#õ  V s“G.¨gŠm‹%åžR‡o!JÍÆ‰Êq¢M‹E»ØZ—ÇÜ”ǘ=s㢢 ŽµDÝ_Z÷A!ÃçÊÅàå·Öc”"Wav?rÆ]ï %/Í‘Ÿ3ß®¶ÆƒÛrée„’u±|‚=õ_ÆÀvnå)¶Jœµ±P úðFÌ)êÚØƒÑÛò©ò¢±ÿ¬'Yl+¸÷«<Ëq·®„Re>Q߆Ժ¸PQó1&vùö.ÞãŒN‰ ¾÷˜ü˜óK~Û‰½Ô"ú‚â‹ü’®Õ½*0åW{\Éâ—¾e/•¦³¦è¹Ž“ð|<Á­|F‡ÒòF°#ðwIÉÇ-·€i˜\{¬Ÿf/B„Ò-‘œ®1Éçê9¼Ÿ+â¾Ò¿QöÙ‹±ð¿Áø3µÌŸ4ÓX®™RŒ‹~¬¡'G Ú/íü­z™†©U@v›4b0D©­ê׊à¥þÄfzͰr[ùSYßs\Ѽ…«cKWïêÓų-4…ÒäzY6Ó¸0ÎÐD'‰è›¤Á3O½´†©ò‡ºôR#¦o§_ö)ì ë¯PŽ’¿QÕ°ïÍö½*m်+X Gt§‚;ÊË»7¹àNR‘Ä@¹X:º­`±"òð]%¾Ö‹É=«ÆÒÏzIB‹9Õà|—!ëßiÂFPÔsŠ“£¢ALIºx½“mžßÆ_fÉ™Ç.½Â¯æ=‚¾éj’°é˜ú.ÖJ{éF¯A [¸8²àúEÕG’ú²U|R[_Z1„çoÊsërÆçÈ;­¯ºnÅ;¶Ó´®d%™—¢áEBO÷oÜ%ÜФÒ"Ò¥Z_sXØ‘Š`B„»èdˆbX³pÍ×Qº¯FÃg¹a"Ôò'Éû‚KѲü9€F¼öµ,“M±•cÇ!šf-Ô÷œ\ÁãñäÒΡ —ðŒ%Òóo ÈÀá. ¸¹ÕQö,Æ,­aMMf±Ãì6‘›b®~;䡳±þpà*_çà-ÁíRÅ;e‰ã^P"gÒnË«©£)zX=ð§Jºp¦ü3­‹f`úUT¡nºŠ›.>Æh_ª@ù7n‘ õC§’®èJª¿8ú?flÑÛendstream endobj 568 0 obj 4924 endobj 576 0 obj <> stream xœÅ\éoÇ•_ä#ÿŠÉ—ÅL iuÝU^xW–#' l'¶c¢DJŠ)MR–”ãÏ{¯®WÝÕ#’’½0<vW×ñÎß;z~\ƒXø_ú÷É˃û_»Õ³«ƒqð:Ø1¬žüx hÌ*ýóäåêáŒór%…YÂ`-¥æ £U£_mË·rOŽãÊ«£—ëß~ýÉgG›£¿<::øê`Ü·†+0U¸NܤX9 3yœêÛµÝlÍZÂÇwGHˆa´£Œ Þ*-â­v"¬Ê5 cË4ŸnÌ0ŽÂ«õï70"x!ýú“Xÿi³UxG¬6éË£^½ÙJào·v¸ƒa³µR£Ðø„ļÅQé™?nÌúwuæz×ø¢üõE}öp£á›rý%\„‡·Ò)¸¢Ö;0Zó1qsJiØ?ì̬?ß,Lô¨<ýI³é=üÅgúk™"/ÖÇ¿)D—Ê.°Éúq°:’ø&Y¿ÂsxR: ]|ŒOðãîÈðë¿­ñÂüø®Žaý"=KÃÔúo›B¶Ò„°ÕfP^åcšv}V8©t¾Îñ, ;zµj0&€d<]Ú6δޕ‹ºíâßgi×ñhqɧø'}\âÇ¿ã™â)/ðã´•äè×åÑu·çåb!•[?(Ç3j¤ýý+^yÓPGü/ÊÅóÖ÷ê¼åâ÷uäeˆWÍBc˜<~Ý<Ήï#+ó€ê€ŸêÕ]ýš¨¡•Græ½~\$>Â$!²’Œ²òE"s¤„Aòd‚ýo$Øÿ!ùzŽ'™ñTþº0íûr†Ë4œ‘ÄŒ RÞ‘$ÄAW6Tö^Ô‡šéòÅ“rñª÷7uï•ËÿS§¯ÄÝ5T¬kf9£#ÍvrZÙð¯ÞRÛ:T4²“f]’̺–Rù+ü)ØÐõlö`š.KœE@y58 †ˆXÏ&Æ›[Ì =ɇVYÕ*ƈIéeƒ«¬ Iö™¤ -T-J+†çi@Çâ,—¤¶ù"o+ù5þù ŠGÙî½êZ6–ÌL½Þý÷;¥óˆÉ^Z|¿‰X"ËI!çÓJÎûø÷ýª²ÝA»‰^[Ìiñ,Å©õw‰òSt{?ŠÕV™h¬ã%úvŽ×€-oý‹OìÒÓ»Óèÿátïù†QØGnžnîMšá n‡î.¹í4tó,ÎZŸ`Ã}$_æ`[™o!î¶!‰út¢Ç[üpõ˜m}ÖG”!'Sð¥¯6ˆpl‰°´Ý#¶BvJ‡›“DÁ´Ëmv7¢°Ž(šR¶Áv4'H|ò˜ŒfÙ@š?Ú áÈl"žp’€vj=É=±ñMÔÙê4+þŸ©¨“ø9.~îPêH%@g›0–|´'•yôåÆxØŸ!5•°˜Y–Böä\hP½ôÜ=ܼ Í¿†-–âN‰ªÏqÀ˜•!¶í(cW æã‘–œ™~G£2“ZëéÚ[¤ÕI"J =^.GZd¼©„„\¡¯’ Ö_¬c(År€pÅ ÷‡Â¶àžÄu—RªYÌ­Š;•,‹„ȉ=¦Æ)0ƒGìw‚‘´ï …MjÈžd3h4LÕ•5kµÜeKÝ‹:†Ìjí¸ÎòÙ\«ÌlÍò\92g×eÈó {YyQÕk‡‚À¬Èu3qúŠ« hv·é »ÀE;‘u¸¬keo"ëN’Ia¶à¼ª< «ö$ë åAC¸§;>ì6`rN£ÁLÀOÑõlÅ ”“j¿†iå¼ëIŠR šI<(6$ ¨•bƒc+¿Ãœ¸%'Ñ,«´Ìí´#çc¦ÎéFÆ/—c(F<Ê zx ŒðffGJ¸™M ,¦ ¿àÃä{ßâ„*ÅC¦ ;SŠÝÓ"¯Ê¾h¦lÚHË(ÔT›vè±™UÙõ”Ê„lM•§ÉjÍ]9AqV]­zJ“æО—ãÉ‘%2øAQd»/ã0õ/·Ö¹¶¡eJ>ìz»Žê¤4êx‹„ñ2Ýtu#ô8fz€ó 'Ñc_^ã GœE>豈L¦¹ºªç. "˜\^á·:ú¶¤Î@HŸ8÷_~_&¼^™Q!UÈÇ0Kp ƒ3“¢ºµ÷pfþä ý¢&çÅ\z°†¦«®©±™6ûÁˆ‡cŽEÎ]ŒÞàý ¶°AñËЦ„ô‹½ƒ~û`Ü]èG¾¥©ª_³•¥…èx¼›‚Ïyµ*Eņ;Õdu™1fjuÖŽûG»o´fZà3·fÕ?ÃÔÞ9m´Ê¶> șԴª~Y£Å†éÊ6 LlLT†›Â˜ØlÚéÝ=„-ä8 ³r5ºóI¾‹>vˆ×ËÆŸ! d én¹qRƒOÄq^Ð\¯bJ€t7NL¾V&¸{·Ø·A!Tº»»B{53x‚IJ,FL¸ê>?ʰ²ÍSo¥@&®Þ›>Xhš²xU•á%­«xj´&fkÖø¬wû½¬ÌÓ&Á5%aJ¸ÀIÅÌ»¸¯d¿åºRSW †O™Â?ú¿A'U‰P}•]gAåH¨/&†rrwP¦’Ù.)Cu›Æ«‚^¼Š¤˜" ñþÊŒ Û+-à~~ÿ¤1Ã×úE]}Ëž˜o˜Ûiâ†D;•Gba±bÄ¡QðóðyâS”%#ÛtÔ ŠŸT ˆÞ—1¢ÁÑè?Yú8fú¾:P$®ˆ¼Í­Ìó8ç\¯ѱ®¢mÛñàü8gf¥T9åA¤ |ÍÙNÂÌD”"øyš+ÍSc…½NA”°ŒÒoÛD ä ”óðíÝÉiK¡8è¨[*móIÊàzt—c‘õšoòÃæ[ç©0„,³q+¸jùÎ2‰|ñóûÈ+íR–¿%ofõûý ˆì !4áT=Èëh\‡ ö7³õý% œv2¯˜åè郎J~hôº`\GÍÃkûû´ÄÞ'«¥1Ô°lŠ>L,N¦UäŸþÏ@$[P%DÁ< ÀW‘öp¡(p§¤’j–éËæ$yT76/ÿðŠÏKV?ò1B{·qI­ 3«ékªí³²nŸZN0jÕÄýiCE~\Q%¶ïW Ô‘£2˜ûòØÆôððàþá«ëËW'÷ÿ²÷ÿô)üsøÛÕ<:\}uk´ÂFBçOÚ»‡¯K© gZ‚\ž€ò È·'vžÎ"ce4 X·.Í-)Éó„s*º§|³±Ý x–ovƒsÜFJ7ƒ"/¥›ošÎŸæš9åRº¹¬²§ÂkÿÚÎ]È4¦È‹™Uü—nOÀd)V¿láße,Krä#S€ÞAçq9R¥|œ‹¼Cì[;©Rr“bq™âzÃò·é8‡[àACî¦ñóêçû·±v ë¥=Ï÷Û”©¾Â6•pBÏ*ÿÝžˆ[¤zûž‹à•ôCnFÌíq=üË‘€B¡óÍüW,Q–›„ªe"x̌ȇ‰îlú¡X<Õšðþ¬^®Õ-Õswãj*E¶Șt OOí>:Ä9ƒkMê}¹*FC\‹•ûEnQïÇPVʦ¾kQ¨×©Œ_“—­”JI›-ÊÇt“êÓÖ츕ÔNĬ_ b9"È‚•¢‰£˜ŒªÍVÍáĶh«’’zä(µò¸-¤e¥>®…Ž”(å3e ÑŒÓpušŒBŠ1¬§t¬ÐU±‚È,Æ9à‚\)†â“nâ2“Üöba»b¯n¢õÛ½zžÒ,(PÍk´J;ßV™’ß L&L<_¶I"¸ƒS"ÙªíѼ³E{#õ­bÈýOÈ&£ò¹Ð͉6@pÑT`¨C#zÙÃBHEê ÁÉ6€žø€»a´·(* yT—l*hð¼F™—ੌÈßly:EÞ˜Üuˆý˜ AP«¿¬³ý™Â§¬nV=Ï©–.C3Ãi¨±Ž¦ÓÆðEâÚ.h8ñÈå¬ó½0 ­)u`GòÇÀ› £b|“êš`A®²Ÿº -R€Å¶»±˜ƒ¾ÅQH>Câcº7¯œÚÛ;©õÿ° ¡×娢¥IØöC¬t[Iph>Ž4m\‡ùt«nèõ÷ ²“¸®pŸm£9[Œm[Õïc!¹Øp}! ‡ÿÀ |&6í†wþ¶Ù·Wã‰V!²uPDÁ`Mp‹CU¢2;Ë¢5Æ~$^ã O曄~<¿Ì.O—r=ÈTø&®Zçôª˜‰üL2|'ìц~77óT;’ÁÕÎî¢Z@ò6 óã$f9)†O—[·—zÚ(åKtN„Í’¤D>è.|*KѨ|Á–”MCº¢]ÉN2æž''2Ç„+«å©…*Ú ŽrJ$ç†JÒ£uG½ @ecçȧ©¢.[=é°I¡51Ý1P¡ÅßÄâ‡è¥²îm¨õaÒœ£¥$4C¤§ø¦îÄìi¤ü¥2Jàï±^X,ìö2JæýÒcO1‡¬¼}<6q©]ÇvN"Þ¬Ó‚µK¥n¸ˆF+…YÒ&ªKó–ª41hdZ5‡Ÿ»Q)dëÙ˜½š–ŠVͱ^'WТ"à<…-1E1ñmEº.3ཎ® _ÌIÙŸl‘m¯zn:zþ¡š<{ïššqQψáf±²#±ž/AØŒ5ƒÿ•Ð}UYBÜìiÔ’égEðNâ —k°Gcg ‘Tɹë˜5ÍJdMtšüqbÂî8cÆŒ’+zV˜øQ§%+vÜìB%ð¤±Õ9K°kÞŽh6mÉF³Iv[‚vt&ÃÞ-çáj›µÈiaÊHNQÃóòîúÄS£±ÒÓ÷,³Š´7mcQÆ™b 1ïäQ2’S™±Áé„_EH‘uS´eøÒºÌG.㸷¡™›’è51ðÃU,8bò(ö²×ív›£–{J·¾¡´¡ý¹ÎT~ áÓH§œU)• ”©€kþ~ k|)@Ç  þØÀR+X\šÚ²”‰¸î8‰8>†iž>PZÏKŸí+YúwK)ñK8™Áu}o{ߎßvj›mÕÂâq€4Y7-1³ÜD™A–÷ïbV¥6!³*7á%b[5Fðvš± (ÃX o”% óâ[žüöž8š²Ûǧ)`rKxT—Nˆ ÚW“¼‚½àÒV3A€#ònö(náí:¡jQ™ÎûcÛF}{Uzb{ìfg/ö´%F63kÚ·gÜ’7"=çkï …z¯êuËöË«éK:ŸÂiAŸÚ„üí¿1‡ù.3€Q’ì;¦¾P“>½<±ø™[9„À7.qÒÉñ’]RÀÒÁv¬u@žÏ6øCØ+ö9œJ íµfGÁ›ÒÐî¢yOàiVltmßñ¨8Ãw˜Ð¦’ÿN`“ý{k]¨ë%a‚­³Ã)Õp‰«R¥}ÂuPˆÖók𓿠´SâI`Û)¾–´øG^±<Ç, Æû'{©„I1ù¼ÑMé7}1ð¼Ñ>-Ä48øiÄÁ7¢9i4½Gç D±Ù&·'à“ÛäæÎˆ½AÂb‰cFîŽ èŒNFöݰkÞzÖ×{Óoˆ“ñÕî†'ɬò’_®ôÜ>©KíÙE<²›ìáí;¸ÅÔûýaRÂ)7t]Ùòa²¶KïË`÷ýBÆ;úEÛŸÇY Qì´6xÞ¸StyŠëÓ<(ƒ¾­g¯O¾m’ó(ùŽ?^Ám¾}T.Ö‹õ—»Õ‹õG|–o®·?+?¯•‹_öv„ÑN¾Zs¥(ÿWÿ Z¦’endstream endobj 577 0 obj 4968 endobj 586 0 obj <> stream xœí\[oGvÎ3ÿó/Áô®§Õu¯’±ÈZZQàb‡É"ð†¨û®È¡9”eùñ9çÔ½ºz8¤5JAä°ºº.§Îå;—šŸVÓÈVþ ¿_œŸ<øÎ¬ÞìN¦ÑJ§'·zsòÓ £>«ðëÅùêÑ)ô³|Å™Z¾†Î’sÍ,Œã&-&»Ú¤O韦•™V§ç'ë?}÷Õ×§ÃéßNžœž|{2í›C­'=q?³ZHæW¬¥an•Ú ‡á-ŽÿýÚ µ±–þÃF31NL­ܬ¿Øúxˆÿ7C8.×ÿ90¡Æi2ëÍwÆC£µzýdë¯áOúí‚><6 ;HC*lúáô_ÂzqëŽáz=QÙJq=ÂÒÒò4®J  C(Æý«\èòÝT_Úp3 ÚÿKxó.à\â÷øãUj£OøãwHcü“çøã]x¬`ÇÓd×]cÃ_‡Ðäù|HŽrhKàá äj„TÊY¿œøü¾Äˆp[üû,¾D³B;cyêÉQGzü6L¡˜£)iåÒnÎÒÛ´Œ«üö6=y×.×»²{<½©q›/RãËܸÃá-QlW.{þÒ‹Üø*¼ä$íÈ?[?›{’ž_æçÛÞ oc#ÈM§ÿÍÉéï¾_ÿœóª¡Ûu:á¼ç¿ãŸªgz•:þFZÀ¯Ø7®ê¼GÞSã›jÓ¡ñš¦ö|æ[ÙB¿°;)™üîZvzžxœ~TÔ d¸‘ÎOg98¯_¹Â?o2-*aÖ¿íüvå®âóçCçüþ^Nz]N?é¼C´Cý·I üX Ðë¼ÑéУÐEù¿ =o¢P L¾Ï‹ÏoÞäÆLЂa~(_Ÿçǧ©ñinüsj|Òã¼GéÓ¿çÇ_§ÆoJUŸõV„l[‘Oóyôxó:)««R·Nº¿n‹|) n㙑H tv¹ñj¿Þz“'¹êÍeY³0ïz½u<ï5¾Û«‰#•3«¿Ï´#îôÆêw‘ë ½u–Hû:uÁóó*•Üû¢Ö”K:­ h´ …+ô÷ër%siøPõ$ƒ –â¿ózºäË”ª•Jhü"ãå]¦ïkàE¢à€8ÞFÃp™x>±j¡ímñr­¢|§ê°JiCCñ u{íz—-3.*­ñ¶G„ë¼»{iûÿCòUl© ~”ÂÂîñh…t#àoÔ.ªSßÍFÞ€¹tœ5ØKسc.²¥ÆxˆŸÿ-êY°¸ÙHç†1~NŸ¶õà·Ðÿ/¤fQ½û"\ÈÐ"¿føõ¶:²9¿¾)¹¤Ähû8óçfÚ~̦"p-(#$¼ÜÒ Ñ~ÈEg¹õC¯¯g$?ü~·à:œpä 2¤Ãèí‡Ôå1þ@`€˜@Ôh p B€¾õ/Ã³Ôøò„$µþǬ‹ï¤L£žÉçºËð®×˜è—žJèú,×½~éy¯Â\q’Û˜§ð¦ZE<óWIs(y¦vMŠQãKµ™j:Á­•P\7Ú%û®/óz#ÆévŠª#vú>šöìõfeJŒÕóÕ¥¹Øj#h>Z¹ýïÀ½GÍ^2ÀU`S®-͘ ? ”– H ¼qä£àÑãªù£echqeŠàŸÂ7$Ê9@¥÷éc|€[‘¤;ðäÁó0„ÿžo¯ê£Ö‚øýyœò}Ñõ®úù€b`·À%’¦Ûú¥ˆ ÓãNvC|;âˆ86YA `Ëë×nOšàÜsS£Mš‰h€©Y Ç`éÕPÅQtN;·Þ\§…ájÏó“Wi³‰ÿX?Gî'?±{ÕcüA¼„½ÝÐI¤óÂQ_øHw:|À¢?Î≆ˆ׬ â0¢ò®•Ç)PÀ$ïªB8§Šë”6CÅ•&&L‡Žv´¯àÝR\Ÿ" Àø ãzku^Ú«‹È[ÒMâ‚¤Þ öQÈÚnœåH "kû¤AL+KÒhô`ôLl¸2Iœ*/¦Õz #ŸDrY­Ï4kIF ’õfhÎó0Í­›IíÚ&E T¶ƒ÷ˆ§FSê÷(çÊ»ŒY!P$Cb©„m9®5•Ðù\¤ôi›†ëîÎÖXz¾Ç† ¹¦Ô;¬žʪgÜ¥ÄT¡!ŠÒÝï'Ð5’Ù$4ç^[©²ÅŠ/J…˜„i¾xN6¿¾È‰ü«÷ÿ*FÏšëÓsºqâ.œ>‡'{×ô‹2]Õ eãã•'³©ŸYt“…dÌ&øé36 #uåJ›¤G÷Ë•QI`ƒ]¯aƶñKÜ'½ŸêEó-0xóbeHûÎ5±q÷/ 4JIÞmÇÃ">êÂʥŽÏwa|*(œk$òYŠ2Ûxüñµu ÔWBýt''Oµ‘4®ˆ)#œz ¦õÑ»m 9#1Ïn¥¸›²·Iämô_ÿÄ'Yä§Î,샣ìª0ŒÇší­áeŒÀc¶XnÓ9¯·qG1PÀ5jaAâEuR¸¹$aE(ü,<+v·Ë¼x8ôËúœ* úhðC4"ÿ_âóyK|ÎTvxu±OËtŸ ÷amƒ @3¤Ýdr¿¼uÏŒ“X¹U¸Š[éu•ó;Ôï#>˜’u!b΃Òóa³¾Cœ3y9Ê];š]¿k1þ)¤RèúÍ/æR`:æÁ_w‰0ׯÒ娱?ˆ 8í .Ü?z—ÙÆP”=(†rGLâ#&&‡Í1¹-ñ@Ñ»£s&¸ýõœ1›+ŠÔi ‡ë€2§Øï"bQ|æ+q¤[DÍAS „Lzk+˜>ŠáÄTã1gkÛ2Ž2+:MÁ°ro:ˆ6¤äÊlq?ƒ¹g•a,– 1‘´xvpœBŒžGÙéGì ÿ °rü˜;œó0üEüGIA².(m\Ú/|Ø éÖ Ð¹|Ò!º…ñçB  éG ¯4¼.×Þ ›Ò&Év×PzßyàIލS3´Ã}PõpsNØ—A`emI8+ÎGXSE¤ëH½®|÷DsSÈH]ºÑ) #@|ëú!¶y=f1óU8ðý»¡ã ºîgáª*ÉçU41xÍ‘éD<á7uÑsRg‰S§‰ä”Ñ ð6yŸ8÷A˜NZnÀ9¹ìæó#ðy2d‚±à¡`ð¦&$)šÃ Ë^8"xs§zÔHI§|^q5G¼ŠU9mÛ®:ޏ(ŸDC‡¥T©Šh¸áÛ¥˜ 7K–£ŒÓõ$Q0Oá/.ñY²"K–‰øBuÓ/öA$ê¹Ðï¿­$ yã¥g#ÁE…—}S“ÈF‘æw±rÍõ2G#ôô)Ö¹°ÔkÏ£‚I 9¼u<>yìÛ­jor’ •Ú5L,B+Ê3pŰ™gFh’–ÖýÕ€$˜4/4j 4`œ3ºl–ަ ¦N ½™a4ýŒÑ¾ö¸‚Ö8sˆ¶Âë_T÷Þ4)Ζ³»âµI;»«p’”ÛõF™uÃÌnde°/&w2E GLª‰ÛT²…̽7N Πּo1)oÃÚœïÌSË˜Ý ræ¸cÇMrZCô^!°èf9ý­¨¼ÚŽg+.¯°vÂäªÈ`òyúiùµ§ ¾0£¯À¢ ÝÝž™­"#b{ÀÁã¸àô5滯 ‚Ö­^ü"L œÊ.Ö<ð ªÞìÉ«5ž…n2‚ê{t¿ÌuiÌ8·Ó­n­7¢<;'òî`AàýëIQ.ŒŒÆÒɤaeHõ•9%²“®Õ‡ ¬þ4„›)ÙT'Hê&·¨¹qܽöxa’±X_Ö©– p,„\«è¸`óœ¯`¼Ç!1 cÕÅ (I7 \òÈRIV_k_­ËaÔ‰:”Ã’bˆ•„HŠI¯oÏëÄžñÔŸ“bb‡…?|9'Èļm-!Sƒ©Ã&‚M‹Y˸£ÀÇ÷f^?N•91¨ÑïeY^D µ¸÷}¶ÕÅ4 ‹àQ•ðXˆ1Üú©CÄ‚Ùè¨ñ…¨žéšGj|£¯ø'Fq=®%?j|…£pë^N0úþŠsE È›”ÌÎûÑ)܉³Â9  #•CÕqÁ =ˆó}erz46›\ýߎ7¢š½Ï6ÓOƒOš›C%Çy½Cé<ô,¸¡,âb,€ÄÔDMÆUâ;ü ‡­)‚»Û:ýì-S3„Òk›œöd=+—²Î‰æd©*•æÎ’²£¢cŒœ¡ …0q(<4XÌ€âYouëS¯/Åž{‚nò¿§É8e±1¯?'YÝ“a›ìçYè=«ÛÞ)(•#{pôuJ7òŠŠéˆ{÷r2ý„qŸcG–£ë´È­¾Ðu´b¬àÃbåQÐ…‘×>@¹€ áð/ô¥btARN+ü$‡ÃË´@E'¨ gÁ~m@Ö1&¤˜ Ÿôzƒf‚3c¹Y?‚ŽZYtÜé¢.( ]÷øn ´° UÚLÒ‚“Ú×ÛR«Åh9Œeã6*f ª²NŒ¥šué£þáRŠL*¥@ŒµQù{:B­¯ê)½ÍÙÍ&WŒ–±HÑúg¯‚"³©D'fU¾ÁR Œºðß‚* ñm `X"°Mº¡ü3E0©Z[$ý©NhaÎ…Û÷k¹šÈ6E0ƒÏ¯gš*£ÞÄÏ•ÿ:‹"Û¨Kö-]õ•Ë*+”výûsCîøï³3€Ü*=ûK×-ót#´¢Ÿ)p}·~i¾pk9iêÍ£ßym£[ ÕìhªÙKÛšJ!eʆºxG¸x!²]§sü)ÇÉÔ¬z¾àúþ±“WaM*ÐÛÜ@*BÌ…'#ŒÏ´™y¥]ÜsYóLm>i†¼©Ìp1PBË…(ŒXÚ$é‚ÕÓH7ÊôëL÷ýëòÉ ³^˜³wÕT c§r¸i£À·-¹PÆÙT¦$Èv@í¿wM‘˜û¾hχV¼>iôœ­²p¥’Ü[g'߇4ßyñRq;£—Šƒn­»ÊêÂ÷Y ~“æìûfÈ ’6J‚]á%W° pB¡“p‚áñe‚ô:ðb?]ÏÑ„žÕKÜ¿ËþDëäûÖ)çë\?Ä/PœW£Ÿ‰ ôðAηŽãÑsºùLÄÁÂ}YWô·ŽfY®üû>K>߯;f2Û?f·pÌùßÀ¦úˆ¬Â wZ’¼^Xs®3ÒwVöåâ!¤{ÁTõ³‹Ö aý›ÉÑê1­¨. Ä˜)&¯'R-oöÖw:ðË*ó Á1É(§BqÝ8ð‚@Ë7JÛN®GG3E‡§s–ÅÇ€(*ÿro´ÇùÒà0Ø/1AÕ¯ ¤[¸iG噯E©bÍïÑ{ÊQÁéü„ôk—½Gqt(©\};ïNpav¶,nû…RÞFë¾_îжU˜¡´–Í!õêDSTîE™ô·ùdÿ ×Ù׸”A½äaçêòJÙ0*ݦŽÕ%ÆB'ÔÉòMiÄëÈG§ò­* •e¤¨ú·'ÿÁIw¤endstream endobj 587 0 obj 5442 endobj 591 0 obj <> stream xœí[YoÇòÈ_±~ vdíjúî‘ À²-Ç ìÄ#°€)Y1ER¼$ÊñOUõU=Ó³¤$Ò ‚€Àr¶g¦»ºê«³k_.úµXôøÿ?y±uç·xv²Õ¯½l?,žm½ÜôÌ"þ{òbññ6<çåB ³Ø~ k)­ð0ÏÐ[ÕûÅ*_å{²ï®_l¿ØZ~ú̓϶»ín=ÜÞúz«ß´†˜j¸N R,œ„™Mƒ¸ÀŽ^¬„Z32vçÈÆ™–‡ùã¨ý ~ßT‡­…%wñ+}ãǯaOí]†7D.o§¥Í3ÙÎIÅ”øäòàóòäA<-ƒ#¦öâçyð°<úœožðßq6†’J"CIBO#qÂàæê‰­ rêÃ?’òOø±—Ø_aã8ß:)·îfªî§%ô,§’8o…_çÇî•w÷[{?̃G…ËDU}]]åAQQŠ=êÛéÐãZ ÛÂùÃÖέA°|‘–8)%«^]=¾X±mï•;a»VÒ`z³~4”·hÍr‹0¬„†øFfÀ×gÌ ÄæÚ6wÀ‹'üê Dx£‡Ûølýª6¤€ðéÝŒ""ƬTjh¢HiM°};$…ï‚$Znß‘gÊÂêAÛb`ˆwÎ#tÌBž> .%š‡N ƒÈ ´7‰zF‡§2Ç•b€ŒÑÔñÛFÉÚZ0i #ÁòÙ‚EÛÖ²¸…†l­·^ƃ™’Õ2§9Fü)¯•• Ÿö£Ôµ~f†f$”k4Òrd«Ï‚1'J-“ ñDRÏ€QúˆÚ¨BŸv2\”!mÖ1 ìå@ä„ðùð4.e@š–Ç K‰pÙ;i!ŸèŠ€aúƒ›)0&¼¶|~–fdØ9ÜÍŒ?ËŽ†¶’ßx†Ë>!G[Rpÿ¸“t˜O' 74îqVþ‚YÈÀ1¤Èaí}™–‡L,˜Tœ€›ZÙ7ØksŸÚq~ðM”e®f•vT¶_›©xÉžmÛݲk̆„VÙ•¢Žk¢…‘^}+ÈËÆ4:ÞE7üã«NÐëAt˜"c°ø^€iAüaz+Àc%‰Úh¹ïvíLŽB#i×.«[ ÷¯!8Lÿ8¶ú>FŸ•Ó$ ž”ÁKýœß7 M OpXäþ*dY;eí’Üì”ÇJÔÖ¢âvÉš«°Íî„Í6W)±?ËËJÊø¸EO!âƒ*˜+OŒk¥YGÜ1”è"-.Ø‘ „_Š#{ÇÌ"}ý±Ž¤sB3e«sÑ ê€Þ'ÑÉEj™4O¢%Aý¤Ûd=„’#óaHÉ6#"ƒkÆÒ}Cõ¢B ÔlR•¤"Éç'& Íé…Jü*!O1ÐÈÃU´Qkè ÷Ð  :r»„oí*ìÑŠ1fƒ2ÿêx5 ¢P¼¬_ÈÁ.%H :9>ÊÄö,‡ I¬Xº‚Ý×2ûе<ìšÂ^ ظ»ø}Àše¼¸h»:ÿi€'tåESøÄø½Hò_£ÚJâìgâÊ[AÈVJe§A@ˆ§ÈuPXìdž7…«ÅœGh§ %‰·öç´ªïéÏ#VÃö‡Ê~Ë^AZvbÞlqh.¹üy£ãŸÕg'æ`SP}ÐPIŸlhÀý¦·›0~P¾nÊlo *Vr-5ü3k'›Q±¹–¨Ø€Æúj™*³p\—Û)_tÑov—10©ð$’ÝlFnKåHáT˜åúQÈB89Ia 9uÐRn0jR¢ÉÂe†½\€p-ñÈô ÀÈZ;$ÀIzÇ¿úþ=útñ»­‡_Ïr}ì$"ÛÁ4 ¿aÄ=±ý(´4¤…n‘MÑ¢¼/»XôE§‹AÙàû“þW—C4åýb²ã”©—)F‰n'ÊeuTkÑa)7L4Œ9*&§ÍFX/Ç0ªÜoÊ¢„²ãQR,4¹@ŸmÇ-³nÙoN‹Už 1:Ûñ¬’!–½q@¦‹DÏnw*›_YXÿn•-%D<@ÖI&?1²NÓpç}_³$ÆiºwÈÊ*ÅålÈ¡øûÃÌë4Sæ¢zEO2%1‡“Ó¢T•6Ðz’»æ ñª¨€tKJi-}=Êù2¸hR£r>W¥½ÍÙYLþ«âq‚õ_éÞçü4G[Q’Š—(ꨦä–hVd•€Æ7N¢Š%Í õû J‘1œæ1“u²m­R´õ%¥>1 ês€M›X[-TMã`kåÈõJ%¢!“ÞáagŸ/¦³”ŒçÃh¬1à uv.½f‘ƒRýãÊö7‚q–ÀÌÖPÚh6rIc´gX‰ÍÎȋӑ/5Ê•¬_SþA6FëU• æRÈëà”¶tä¯ÅÚÒIÖ[Û·P?¨¬èM`+Î Ö`„Â^ÀOqTÁý &0W΢_ãb•†žÃT€ƒYt<³³®×XY@^9íH ­ójhFÔn­ˆ Â,¥Ì»Îªv˜²Ëôÿ%=ÂÇ4öyWZÞº’Si>BÊ´¥“{Ê »™—j‚-׋ˆ-%ô¼}—às [§€¾m+Æ¢±k f1»°u·rñà2÷ƒ1ÿ.æ«b¼…9W9#‰jVÈå¾Ó½!\ð£tìÈ.Ô ©)Ö+"»Ý¼ús85|U™ÃqƒD¼)=¬Â{;Ôð(…y”KB—WUKùÐ =×-½ ¦¶O‹þ­s¹V‹^ýÚhÛÛ¹>ÏŒcu†½‚¨}kÐǼR”6‰|¾DXÈíMR^ ñäÞÆ:klã¡wx¬…íÒžµg0<îªò‚pªUŸ®°3û&P1ƒÔÒ"‰mg3R©)=·•T2½(’FB9:º•Xé%È(bõ´!ôÝú„’”ÝäNs=ñî¥3ú‰6û‰ª'³Õ•S†íºG ˜B+î·Ž¶«FºÔy<äøžëÑ¥NŸ01›jÍ…ëùpjêýñÒ¡¾£ãöô#‰ÑA>«#ŒšE ï¶»D¬mU+êºî|¡ï),ïõ ÷ŠX×ɽ"—ä ½¡È÷Æ sØSSv¥|¡öܪœ4ÜŃ+çÒO†:ó¬ÒѤµÒO;û¡†÷ð¨tÆCÐc[$Œškj*ƈJO•Ÿ·±fϹP?}lHºéÈB[FA“1Â4ÊÒ&Ž«wãõ>ÐÒ­Ý‚ú¾÷WcõX†)xß]aÌžú&…à´4+Œ6íš›£ ‚Íw¼lSTõˆ€ÿíLDU©Óµ%ºè…ºÅM«;ÆzX·¨íP¶±°+Ž6…¤× u]ÞÛ +¸4Ì$ô]Ÿ¦˜{@¯e”¥Z´íä â2˜æ2˜ ÚËh]Ž–®ËÍà93LËoИúy„Žªæ—»+©WòÆ ³–­èJ  ÄÈàytŸºì•l %B€ôó¿ãq(ãtvè›ÛÖoÉçÃ+> stream xœå]YGr^ØoóìÐ ø¡Ûf—*ïJ-°´’vihIã ¯ PŠ”ÄÑP"uÌþzGD^‘ÙYÕÇLÏŠÍîªÊÈ̸㋬ïVã V#þÿ~z}ñΧnõüõÅ8LÚÛѯž_|w!èšUüëéõêýK¸n’+)ÌêòK¸XKiÅÏñ£Uã´ÚæOù79Ž+7®.¯/Ö|úÞG—›Ë¯/>¼¼øäb\ì„F;Ê0ŽŸ¬Ò"Plµ~•¿s?áóÿgí6[³6jmÇ­j…Y°‘rGë×ïm„À{Íú>ÉÁ{߃_éõ_7rýxcÖnôúsøs Ïúoøó—ÍVÑ—ŸÁƒÿ÷ò?#‰8[/İŽbe¤€šLb6[ !ñÖ­6¯Ùªq€™øÕå\øûX#ÿ¸ÙŠõ3¸aýíf+5Òe×O𣠙Ðïx!]óÜõȺ}µ wÚ`á9q“¬ò°'a¨¿n„öƒ’¸ã``9§î”¦AO£Hwým#ß|‰¤ŒDʸ(ß"ßÐÿo¤Z™õë ÌqÚ­‡UÀN*ý·Í9ÅOBNëGp‡aŽáæx =§F7_‰‹wþ€ÿ{ÿ/¿ƒ¿°úÕŇWŸÌÊyCy’" Ìî-Ž{ ø^Æ…qü;!ɸT ÓdFß]=È9)°£}f2 Ç|ßo`Ÿ¬$*Š-®Ã(<û2n£q]jA Yç]¦vSS[ï¹…5`ûˆRñÙÏÃÖOE'h\›,MI5DÖüi“~ ªG"s¬¶  )W|0²*JÚ“¨L²øÔ)©HEâ÷/@†k¶À%Õ×I(é“2R(òwº¿´£t#¦N¹îjøz£Iâ/qhTE$Iø¶Òƒ8Nš––Ôh¤6_˜=E§¢±z?35:öŽÉ|Ñ’8àMÑj’«´Ð>j߸3D·À ƒS†A£vL÷¥ý5ÍôMðņ »¼¾Æ%71þaßrònq­}¼ðæ)Z:þ--i¾ù6?¦Ëà# [Öš°ˆÐ’&#¯A?ÃX`Æk^7ø”Àë¬_a¶Õ[éã#ËLaYQȶє^à52Kß$ˆ•2_¯¿ÜHÆþå{4 åèÂæâ½¶*™çiQbÒ*³ø .ºëxR,Ì& ãkQ úãÈ>cPÁóèAh]qÆlÜ"´ÑWCµüý²Ã¶«Ç…2ƒ=®,˜‘ÚC›¢#u+Øy²É•'£áU–s\soiqp—Ø I½Ñö&…wÃl~c·ÁqþÓƒN.Ö5ižïaüS¾¹ÝÈY[ .Õ3p#ú*w·¥5™i¡$8›¢Ú‚ŸÌ‹f€4 „hNÚ벯˜M{ùi1îòÔ\f•¸|Î…[ØN´+wÝN¥Àñ—ç_35MGm'Iê!8MiJœ‘öC²µß¢¤º¹ 'Áv¶¶’ :I~™¡zµ)ïZ2fߊab&ëYíþ£®=©²*ëjÄ'eDö@$‹ÑÂÔ#kÆb²Ç<šô¶6otzv²èÑL(¼¶]ÇmÆÅÊ?,‚›ª¨% QIÒ?AÁ*f2c)ÇÖ4‡Mjý'Ø` ·Ç¿ÝMÙÂ,Ë¡ÔT.Lb¬œ¥áõ&;¸µŠPÃ~sXtÅÄ÷–É|¹¶»„à¯È…ÄÌlQ¯â£ Ë…l5XUIJýä:î&TŠÛÚÝ+<í4ÊŸ€$ma…»^9 W K°À¸.Š9“”-Q•ÆéRL0²Èû¨¸àѦϵn÷.ÑRZM’&Æ{²°3-ÕHÓè‹õçݧNÙ‰ôÍÙ©Óã $§î5¬Ü4i…?¥™^·#¤®Ú•.¾yÆts_fÁ1šdl0qëõú ”Wk)¯›gV–’9¦ÖŽ$?†e <úöe÷$¦PnÞ$æl,Õh09ÅTqÙ qýh³m 8Y°Ì”ó®k£v”qdÙ#éqF”€yúɵ÷”‹nˆòm²ñγb.>àû°ÞãHdA+ƒþQ§ÒÊU¤þSÄŽ&øm¬b0¼š]ˆ…ÚIuåTWÿe/w¶_;ŒÛ”eª"îFÞ°'h†xä½³‹}€…j‘Õ@V³““‘ÕŒì'MÅj4êw¹ÒñCOãõšM±ÄBñg™ïú÷ü峡üx9Y]~™/슆«÷¡ê}´Ï(n%¯ëÊÚË@†¼s‘›|™iÿÁ©íGu¶Ê¸FÖîcK’‰^P©ö($æÏÁ•k,j®²•*+73¿§/IxÑ]~Ϲ9æ._eS)†½ÚbÔ®P›­«Œ,HΔ¬<ÆÈú‰rºÆzúûl6Våf\Q•á»D‰qB0ÅP…Щ"ŒdäL#$%jˆ(¯`˜˜Ç¾jÝåAe*ø ?  ãiêô¹Š?ëÈ“$1)‰Å)"Ïö•ŸS5ôDKÌÛæ0eŒñznÄØ2˜1—éSA,ŽY#X¾NIYú¾ä|™‰Ïx™ìš–9¥“g¹¯Üh $S8WÎU>qO°„¯³¸¥yN”ž[ g¥ áìœr utGà'0.lcýi¥"DƤiƒ_70 “ù |ÕÍÛƒËQ4¥D%).ºÏ-#‘wØÃùYÀ‘O±KÖ?—e~µSYá‘×;åüÅ Búáj3Û%ÌÕŽèuÂuÐ)W„ß0W7âé’cËm\àCJÊ0^[„,— ¬:'Š &ØHL§ï@ÏB£”æj£YsþXŸ)GOÑRÛõP…ë2¦ØØÅh ìœáÙÑî{˜àqæÌ—0(¦Œp¥q-KgB0ÎÄ•œ–›’®Â.‚ zwÍ›´hmÄÞxqýk¶rœ¬‡Ç–4¢±àƒÖÚ›~¸.Þ^ÏtíÏzé]`=\߯~×ÏcZ:dõè[@ÊNYU«G«'¬ÒEÇM’ÝY?vËÃþЙÎγ£{çÈCfŽ®;Ç:sX>Wá—;ÎB£yÝûç°?(wÝ¡4õcò±v’JõÚ0#;Çl‹ÚÒüÃ~Ãùn«ÕôPËúfÔ'.ß2ŸÛÞ"î&ä–ª—¿Fõk)o³ }r¬úêeÀtÙ}¢f$ã­’À%ïð¸"Jé×ÿ…›`í¤¦õÇ ËANZwS¯5ï8)á`ˆ²í ±W}»YYpÔŠ î­­³²_ÓÒysDfp®3UÁ6¾'YSª<9mîE°´vèŽv«´·Î®øòbšš…ËbîAglÕD,Ððßm +tåÒF, œ;LuJ—pÙw£@ôý^Å?Ui™Âc¢)æU¥³.% âWÇ4ïéІ;X<À4} }>0A×*Q vT¡™Q…‹Íß–‚‘žsÑÛ@@ûQÅ@ÀËîñ°ƒ¼Áªu†£ÿÜITÉçœi)Nl¨zb&@©etê³Ê ­2ûN±=dV0–ºŒû=9]€²r¢àóU7÷HÁäJlWæuL5­Ûª® ö‘ôØ"Êö/®Á ˆ¦±oMˆÖ ±J•âªj}C` ŒÐe—ª©î½›0É3ÙÇX,`¼“ÖZï¶ÌÇ’”×I Þè@'›‚”Àã]«Rž {>èj4?1©¢Ç^9J†4î©å¨^Õ+4w­Z€¿G0H´{¡Ì• ÀWªVí€f¶‚4†)´¥R[Äo*5nЊêRÜX¬]øJr£ŠÐ6Jæ%|£N»®« Å.ùõa³uJ¯_wÌà7QgzPIžxVî8±ü úØÝC¾0Hšî[›<Ós:u5åø†ªfÛŽl¨ŠhÜœ×L­·Gw– pÇgÏÁS ä­e˜Ùj,ÂM›éÒÛwÂÉBM®V…åÊO@¨Ö`h†—eÂNÓlDvÖ 2u‘?³=œêì çw·k``9ª¹--ðãLkbZgÊà#OÏî3­u’>šVcÝÝL«íû\L ž ®Ø·+[Ðw•ÑÔ+NIF¶éWh4æ71IÒ’.·ž~«8’×È©Óña5©ÎÝf¹@»0®7®Þs& ŠO¨÷Þ ŠÇ˜6(µ8¡˜¨·;í_/€Û}ÀŽ5KÉà@4ûnNçÌik|H®s:ŽôuHeeàG?÷':5vçTD]ºùF< 0ðÞQ5 Ó¬ Ÿýn¹—Öš‚gæÎ`M•'¤fúûŒž%!˜{h»žåŒ±÷t”ÃùÉc?UÔå*[NLÊ HŒøÀ°®–µ_<.L?Wvч+çL䆜hÒb€¸¥ãÜø9Y¤D£5¨ÿ¥¶ØûµÊæBŸO0µt^qpšêCZÌœ‡õ.ü#Èn’SMåˆxn ¡A•jóý»Ê‚ÐŒ¾ªMßÅÏÞ{Ú£’žœŠZTfto×{ž1fX¼ô¾ºÒÔv!B‰ÌyÓ1ƒ ˆÝÜžPÎ}-ó"5<¡’ÄI›‹MO6¹­s/4)A —^L˜ºOØß%ÀóqÖ*nÀü‰+5†ÑTUKÜïùÉé|ž©ÐÜŒà1¼˜ÌlúAÄ1‡[îiušh{ݰÔ n>¿`dÔ¥¥œµÏNÃÀ ɘà.*ôªùÑ3G–(:íü£5×ÅOIË ”ÃLq§yµ›FÔC˜?´|ùÌ*ýzâVCèõ0 G*¦ÞêgÙª³v¯Ô=³t|úI ¥Lú§Ö‚RPÏXr¨Ÿôª¥ƒAP¼1ß BgVW}³ÊÕT†ÎôŠˆlzú’ë2„ÌÊ©9SŽ,ãn†9{Ã(jjØu´·]¶„x›ÃÃDؘ‡ÙáN£ÄÜ)@†PIgÎ{¡ähò4O2¬¿ÑCøÝ<ÁÔùø‡R§8é!ÃZ 6è!%»ˆ0$ú@$lsHçqxXlJ0s Á*©ÿ‚ãÝè÷îÈæ·zzo9¦ynœ·(©öàSûHÉÙ²Ó%§î~â‚4Ljcœ—‰ÙTc‹þª2…A‘h«ózŠè:9‡¡È¡pTÌ÷2ìD"z;ÒHÍ?oúÂÕ$ËËRϽ!e«œGöi"—SͰVTL„AüYß#40²Æq2V“ýÓ^òdºÒ3V¢{6‹vö6–ƒÔá/¼å>æxÍçÝÑåÑîO«¿fn]Ñ_ ®8|BG1Áo÷‹º8ÆE£}ÊD´ö)_øøDì[žKÕXô©ÿ;]Ú&Bt$ô\ˤ :0ö9óÔlkv£ÌO&eˆÍÔdÏ Ò`ŽÆäƒÉ`vÏNp4»…àãbÉ61³ó²³:Ÿ?SMsÝ\—ëâiXÒ‹Ò1Þä®ñüê‹l¶ U_³ÔK$ú¦ÿ–«¸^„£æ8ò’72glc"<áÙs<%yɵ>+_xåÓ!qUéÆaáãô |1Èh—9ïtEÔ'ÐeT0ï,Gî³;g²~–ÅsÍö%/²WÍI>” bs~Û ÔW-îÎZOIñíæ¼uGáð<"GçÂãá¾q+¡NìÀ¾qÝ0Ó·ïà}Ž“ ¥ŽÅtÆÉn½J‡Þûœl„l,rgÜD¸µœs±ÐûÅ}ߘ'úà 2‹,†ý¼pœSxÆ/{)ß™°T1øÜŽPOµø”i„Ib¬Q^¼]Š^¹àÉÆaaçHˆÃ[Tië”~Ë5X8vÁé¢sfž:”úáe΂×üX!fPóC5O9ÕlÒyý×[]U 6<¨~ƒT}®,‹;e •ßEØ}áÏ5#Ý\wiûŠ·+fOâIg¦ê@çD ›ÆòôÁèxZGÿª|°Då¾nñh= N¢Íû_³cܾ!7Ûà÷6U6˜µ‚‹,гõJ(Äðß,Vú¿µ6g‰ÚVöŠ¢ßî§æÃÜ ÒÆHÕ/v±R]q Ÿ5ÐѶûCWMœSÖ!,¦ÍzËÔNNôó€ázˆ£hša’Ð2/ê^Õv`5V PE™¥ãHËëËhù×~x2:Ô¡ÈxÁ™ô@^ºG~Å"½šÃcÖ=ºŒ©¼¹·§¡šÅ$÷û®/õ‚^êñÌr,Ùá0¹Îû¼°>y,»]õ»„‘ºåÏO,HDàœÚ® @²½€ç'ß™ª|EsáƒELYªüž7¨ß°y_°BÞkyöu‹ï`®Ö­hŒSIÿ0Œ‰°-XïûàLÐ÷Ùè{Ιí«_*æX£ßÌ›+éʹ6ÌƒÞ @ͧÓýªy x$L Å¨…Ù“×ÄÈ;}ëìÖ™+Âß±>Ò»Ÿ…QxøÂšÖ~T=žu¨¦>FQá-ÞSÀÐ]'{úM4¦„ì¦ÉÇWŸ¢Óݾ§t§7Pbâë¾uš4†Ž„Ñú¬Gˆ›tµ|‡¼JÐÊ'žŸ¼ðfNÞy°ÒìÝÂüÔ‡w>õ˜EEW’—'ñôBðò”…mO‘ªÃ4¹6‚ÚÔÕàðWk»ÙzÔB­? ˆ~:E3f` ël•†û#:ªVö€§:í+ÂüÝHoªGqFvb÷ßRð1b/O(@LÊÚ|ÛRkðAu3ëÒýòã‹ËÃHh«ããó=†xþ.õK¸¤¿3ÊË„s!» ‚ZkY`ÓÙ§å}%‚¾å@2mÂ[0öõÍÒTIúÐ åXÇ&ŠÇW"jéó)Èx~¶GžõØ^yµ¡Ónáþ!wLOà zŒø=†t)|Wç Lè¥.q|HiÄ1ß0ˆ4}©ÕDœ”¢ùl,è|‡Ÿ’«~¾ÝÈêÄêgQ!ïd­MUBM[@É9 l#ðÚ »ÐR"è³Ø CHæ£Ç> stream xœíZëoÛ6ÿî¿B¥5rEJ–¨¬-ÖmíH·µs1 id‰“eHì6nZ´Ýö·ÇÇÝQ¦ŸqÓ¢0ò‰<ï~÷àÙ/“¢/’þÜÿ£‹Þí'Mr:í}UµuÑ&§½—=aæ$îßÑEòõPÏS2‘b OôäJÊZ(ͧ-ê²PIŽOøNEÒÉð¢—~ûäþÃa6ü«÷`Ø{Ü+í1Ðͪ°R$Ôœ°ÚOë,˜áùðG·@ô‹ºV°VÕe%ìëªm‚4©ç"›o²A¿(„*Óï3=£UBªô~&Ò_²¼„7"fîáAV¥O²\ªVnÒ$ègy-«~!*X!ƒªa–[ós6H¿#Îôöx„ŸÑÚ²J? „LÒD½8—M©)eú›~£gW|Ž®,+-¿–lîes=ÀÕ÷y¤Rúçô;²pJ"-ÿ•.ËzŽ™êªí×NÅ/4“ô†®`k…2§:Ä×f8D¼…0¼Æ§) †á9 g8ù•~¡4ª$e` p¬÷ïÙ¦»È ¦#ÞÀ«Ó¯`x‹Œ÷?Y^µJ?+Ëk ÃN¸ÿ.¾8t ý’¿õQËÂUOÈ"½ƒ«î‚AϘoç‰ï‘xNÙEâ!‘xLÄË€gÑ2~šu‚Äil“3"Žu3å4Ú·Œ/8âZC*ºGÄ>>›ik Z–½Þð‹ýôYŠ68AÃ_ tÎ%á<à@éSö4A´FËvý™3’§N‘ø.´n¨ ÍÕ87Áp‡Ì1Aâ -š"ñYFÔðÊœdfÕÄd¯ËÀ†“âB]Æ1No‘x@Ä×ÄÉèhfS×8v~B~Vÿ\• Ì 6Ü%з²6AWÇC8ZàêN _ÃC»™ A0ë£h*¡Þ‹ª1uŽÄ[4s LÁ³QŽÕ]?Ãkœð}(Ë›áž=QLÐûáØßëtä£ «šgk#«ñÕã ²¿C÷ù†áý† †Ò)—™áE,t‰˜kˆHºÅMãCWÔGe K6‚Èd#û5}ßÛö6(ã6ažb£ðª³Kƒ(ilˆeY¬Ìcºô8׎@˜dá]Lפ7 ¨^¼Üоµ­™7yÝ®‚áõô}—\¬“µ¢0bùš’8mq;Ü8* æPåùi¦à9Ûº:¯0΢Ñmkª‡=K]¡õR_fjº@âUàË.ÝljÐn‰!ÅwcÖ>\TbÄi|kä öšªV¢ÍMTc¤ÞZ‘†ëLiÉÀ9/¦ÌB*˜9 ÓÂÿ¯8 >pø'CäRÏði³ªü…äÌ'¸ù™uí¢©›@Ñ6‹ªÚÀ$´Ï7œZź]Ï3>58ŒŒS_v•ø½5FèwSqlù¨–UeÈv•eúÎ9t;ûn1hª½¯lâEÍ<·cq:£~¾càá:>ÖôqŸû B0"î ïQ÷q÷è^ðÜŒk^ð:1#®š(V°.t¦ 'é ¢.êLmP–ßT ñj¹ä1¡j·Ú­ZÿïVáÓu«Æóìïzí[í[¹˜·^ߊݶ׸êÔ*kÎíVùÀÂL}ýïGfLÏÎIÉ„UA=û= à¡©;x`r\·a±¼äAvýøë|inÿ¥¬ûMX±Îžu$üúÐ;töêÖe©úRuÊ¿:O×M—‹î×¶ë$ÎÕïáA[g6N¬VjS—o»ÝWò„íP¥¨yÛ‡ >^oo£tH¿¤‚üEl&…f»súJŠ~?ó”Þï!ñ˜ ÝÞV´´]á«»…~ñ%l/\ñJ³nsñ³j…MÌåÜüí"uk¦ã—„Ö@^¬ZÍ‘êÕšÙ =ÕsƒûD+›Öÿ ¬L<@·CZµ3‡,ëôMfÛ$&XŸLf ~JÖh½ Wm'«úŸ`Á¯²Êˆ4a/ ß6à¥-ã1mšÆP5l+­Rü¬5\@œÈÁ<¿™™ ’BØ’zJÌ·ácú Ì0„¬Ks‰ÒÆCŽÀmD’¿¡½¦Ì®Ûìc~*ø¸÷æÖ‚Ýendstream endobj 611 0 obj 1839 endobj 615 0 obj <> stream xœíY_oÛ6÷§ÐÞ¤-VHŠ”È")Ö¡-°¡k'lÒ¢b;ðÇnìdé²|÷ñ޲ ÇÆÐmÀŒ ”t$w¿ûÃ;øSÆJž1øóÏ‹Ùàø]“].¬ÔÒÔÌd—ƒOŽk2ÿ¸˜eßµv™à*k'v±¢æÚò1¬®˜Î†á-Ì Æ²†eíl¿|÷âu[´¿ ^µƒ·¶í •q^²š wŽÑu%¹“¸– 7Y 5²×Àÿ,oŠ¡ÊË¢Êk÷2¬yU2®ò—…%cµÉ_œÃ^•·öM”ÆT–¦dþs!òï •¿*dþ‹ýo-¯_íÿŰBâO–ñ‡ö/"hk8ˆèpä™ui¥ ¡ V,iR\¸­¢ªã½C©$lòÚ¢&³vd7NàÄk`8‡á +¾…á3 Æ0<ÚSŒ¶êÖnõMàÓjϹÛò†Ë°ohøyÛ ÀGë§ñ<ž–Bñšö┈ÏR+{<3ùŸö!ìSÃNå:¬|D‚ÕVF§_¥:'â(GD¼‰yº70“õ?iMR• ½lò>ˆO¼=PÖä_#Ø ¯ö;§ ã„s&Å *yÝ}£b*2Åû‚Ôõà,Â$ˆQqpê)g·#Ú0íqñ'LSFZ‘œÓž\âÝ‚s'â)Ù÷XFx[¤•±aófÐ~}@y€®ˆïºÈ-gðyÛ-g²"åÏŸ‡=KOfåHÊið;bÛ {›ò2áeÓ òÝp÷?RjÏqBÄ“D„=Ó ²¶‰e‚ia $ÇŠw®J[% EÀ]Y#„Ι7Ã$ ¨Ïø‘ˆw1Ñ¿-iz‘’ ‡´¢´ÌCêÈGr‡ÝÓΣw #3én7í ¦SZ¶ ŨÔÙ–È¢L@ÅÈ~Ù­©÷ÌnÓTv‹¬:Ü–òl¤þ3)÷¤t·«ìö­¤"—¹’Ê»¬ôzì «š‘µlÚ%½~‰†…Ìßû©a¢|‡„9"”áû˜\$¹¨«ºEgÁ+·W{ýTµö8å+½•›BÓzp‰¦äܘ.Õ|éöa™H‡öáÐ>ì×>Ѧû§óž‰Fƒ2ô<•mG„ði·IÇfî7#>%nîC7rèFÝÈÿ¦‰ L_I>Õ”¤îÃDSã²{SâU¤ÌÝeˆÝš’#Ê‚”eÊ¡S9t*ÿb§ô€Æ%YÈ—«Øâÿ¡–¦Ÿè¾hK³þ $=Ð|X©Ra¯¼¶{,Ø š-û—TÔ5 ?x€“ø#RÞËMÿ^¸B²Q±A²•²ÒJ> stream xœíZYoÛF~ׯ`ßÈÆR¸Ë[°¤mÒIÛ¤*ŠÂ1Á¶5’åH²s8îoïÎ3»äR‡§Ek ©áìpvŽofGzÄ=Äð§ÿM;÷ŸÁé¢÷Ê´Êã*8í¼é0ÉèGÓà«à+yÀY F‚9å–—!Úä=|| —K¼[–ð5\Ny†¢KZ‚Z†WšÛl§ì—D#ñ„ˆo‘¸Ä»ôø=ωHÊ\#ì$â2 º,é¥)Dç±0É•¶AîÀTÊ)ÚPo#‹«ð£øÇcàÈ’XÚkWQ$ç5íu‚‚¬]£^ÇDœÛʦU‰2М†s„Ä…Ï’c"žyŒ&¥"õdªhâ®oÍ>‘Sš/éeY%ÒõIgðåAø"„íc8ɰ˜¢÷Àv^á¯py"¬’æSëÇÚö†º@â‡F\Y†ReêSîHoÈüŸ!qD‹H|uÇ„*wÒXõ‰CŸËæŽ#¤¤ÒVjî[4ô…ïK"^’$i£Æ*Ë\g¾ýOˆÕÞ«¹O“Ü >ìS4+w ” ²Ì<“¾¼—™q7¢ò¹RbåRË!Æô]_@NVGö¾/þ1{{B îͲ=eb´SÔ8…`úAh¢e þ­`ú-/aja ™ÕÓW‰`k"él_d¶7i¸ÏÊkœÖ2è·W‹ÊÀnø²sk‚4¨cc&§Vd¹©M#ò¬Uö•“c¢È"ùÊà˜ªµ•L® —ôB!³ªé䉵 Õm‚`fü®x0V!žÛÆ­µ×–V¥:¶­®ïŽè1¡î™uM7 6OÕíOâdv¥RfJ-α7¾ç|YæÔ„&p`ýη ¹)/ÜÒ(kÃÁŠän8ÔWY1uTíGGmÜsòÍì•Ø$ÒWãÒßÐF`,}ÁôÚ×£Y…ý¢-N/déqM1@Ï­¸£ŠÂœÀiF‹ÃÙì•À†Õ ph’ð',•«.xZ1bmÏDÆÄÑʼÌ7 NÍ27E-OÕn=Á×MÒ¤W®> stream xœí\Ý·‘¿ç}¾‡{¿Íœ5­æW“tì vìÜéq²ˆ$†¡ìÊòû!kW’…ÄùÛ¯ªøUd³gfµ»J¶f{Ød±ªø«‹ÕûÃjÄjÄñÿ“‹£Ç¿³«ç×Gãà´ŸF¿z~ôÑ 6«øßÉÅê³chçäJ ³:þk)'á ?Njt«mþ”¿“㸲ãêøâhýùï>ýÕñæøû£/޾<waVB ã4Ê0Žw“Ò"Hþ¿("ÎÖ 1èQ¬Œœ&KD‚øÍVÃ@FÈð¨Tv«Æ‡¶ÒЦ| O~‹C^âå¯xyŠ—ðrƒ—_àå-^^àå^~‚a¼ƒùNësüý /×阾ëoð××¹ú•Fz™»‹v›ÓÈá9uåÜDBÌn>Í7oÊÍŸÒMœ6ØS¯¶`c¼ SüóÇû1‹ =9ÂöÀ ˜Ñ¡ÄŽHEà®ðdVRÞŸ7åZ$ÿ¸ùsìÆÓ ¯ó÷Wåû³|ó´ˆ÷ }$)g\å›/Ê$a¸ûcizo¢€$†Ðë7ùîw¥é³|óeu“&ël1é´LŽôë£ãÿŽ®ô*úSÒiø*_²¬.øÛYö·Ë<òÓì7?ÝøûÇù‘ŸçÖC–3šFöäZíõw hoi6}8k< tðQQàÇùæ]Üà„khnÛg忇Å`?æï¯c‡`úâ;ßVÚC+þ- öwœM­œ¼ðTw}Ÿd#_ò1 +@ÑAuß$Õ¾-‰.j_-` Œ³¸¿e!ÊͰBÀç¼&U¨‘Lü÷Üö¼g,6ʃÒÍוúf_…•›ç QþJ@Ò€@µp|QËFݶFÃnùº(Èø­ñ8=i0žハà5ë?eÏÈË:+\­¿†K1qŽ5?׺㨇úcofkäkŽdmœu^=¶Ê½‘ü¿‚§ax³~ŽáöUé+"­/ä@ຠ¾R€F†G ò |\{ÞÓ%ÆpJO¸ž LGÓˆW—Ô;yÞÃè¹¾ÀË‹ ù¤P@WuBºÔÅ)£\!¢[Ä1~·†ùØ1Žˆ’àDåä)Ö?%Éiê(…SÔ t.‚~½Ÿ c&æy™Jì/5zV¾yºA¤B9Y2uóà5y°ô@õFä?d ˜ahÒ§:ÊNƒÖ¶•bp9 ,r×Ù¯ÈßdGÊü‡yx&A´8 Á)gR\“±œçܹÓÍïªÈ;_\Í“Ëá´IwÃ_d¬Ï¢RC  s;0NžõTtS PzÆ—žup92—ÀîÈ\áå{>•žæ‰=@,®9Lžh’ph,\;ùl·Ìf:Ƭ¦šâð>•‡x¯Ë,9ß}½2ÇcAóÃ|óû&dF>ôɦvN`O²:®ë°ña«è>Å¥§Tßnµ5ª©S`M–´Ð°¦8÷8"¥Y|9˜ã¸†Y1*Y?÷¿ó €Ì¯³ÚÎëU jø¤,ÎÎzŠ;fÊŠ”/¸ÊÒÍ=œ12Ëï¹å˜e»r³ÀH&²çŒYT9-7Q¶+ÚÏfé"þ)÷Êm¥ûLÖÞű.sãó²k>Ux¤!'(ÌÚpƒ” czçÉI ߢ*»0$˜óÓìnž¥î±ìÚjŒ°äÄfÍ 4Ißaäªç”GOŽfRsi™¸´†Þ­‹\f.ŽA“ ºeÑ»1¡ÿ«ÜÇ+¦è>‡Æûßm˜ª ŸgÖÍ$ž$ÇÔŒÄÙ¯p)Zz˜¨–ÓDç¨i â¨~%¦A&–̈öeœÌ¨ß˜Ç]ÃŒ˜§ßö±ñI n¦Ô òfê4G›üi‘‡W)È´+~çä]¡¯{›y¶ÞløÚÉ8—¾®vsJÏ‚Ï#{Âìì"±Ù•öXàük¢ë=„…– fìJèÃÐÝs¶‰ða<îº÷Ð7=»Õ3 ŸNzAë²ê§VÜ¿,s‰h®*­–Ø1ÏÆtFp¾Î(Ñ6¦¬áEµr*Xn‰ÓcÒª:`X¦vgìÁ9,æi€ØE嵌ç€k Ò¸Þly"Š€ÐP‘€Ë¶zD’з„ÿ´ËÐ}õ2ú4À õRPŸº:©òñÓÈ5‘6sA60ǹ&Á'+G5H—,q¾‘ƒÑ~¤¥#¥”“ „œ“BBorÂR=ý°Ä›èÈ€Ó­¤ÇÓ&øßùñäâè³'GŸüfuóòÕ³£Ç_­ÄÑãÿÅËg¿ý%ü÷äóÕ}ñdõåâV#o:’^CÐ…q OD˜§‰¬’svÀ$‹fSF…×""3ä t™£êÛÉyÈsžà˜ETŠ€t¹z“¢Nê«ÄÃCE‰5ë·/Š™YäºÞ¤pöѦkÕ­€(j$ø°bÉ=²®Ò&ëNã4³®!®k]¡½!ëN)ÏÃYW Bá8C:ÿC 8DÄI‰øè‹8aþ­ñT n'EÒ¯®(=ú¢­VŸ‚€ñ#hh­U±o|ÖcHŒM"‚Ö`hý±j=‘ÅÃÇÁ8-Æ©'‚‹T½+E3÷ÜŠ­5æJÏÊÝ7àÂZYˆ}íZ¬çoÄÆn19H)§©;¼#_Îóz ê6¸çz±™ÆAŒ^2 ºŠáıQ·íÎBŒo²ŠBüØ5PÜÜÅç`߇[à6žµ»3Þ*˜á{qw%õœ·Y‘K€[iÓÞʹN»6ÒCÇqaw½l-øhØâW[cµð(aá)9ËüÜ1é Æ@þá{´¬Äqäo°`0Þ?¼ˆÆ´q O6F!]Ä„¢„•ˆ©a =ƒ—õ, N¹ì#å?RVíÔ»)šxü¸Úス[E·§ü fjZ½ÎgÊ»3,Ôcݵ‹§F²»G#4²ð_íÊÀpº¤÷¶b‚1Դdz„Sp ÞyDq*ÚO«éûiLŒ¹÷`?­Ðó–Ê­,0s˜å&¥u±\Ì Z+”ìZÎWKÃ!v¬E‰÷yìvC»âQÃn(fg? »;ú¡½øEÜÓI?¦í\ÚÏ÷á ³}å¨þ—›-FÕæÔÝqBk¾BbÆR”mŠU‡ç R®’²¥NSþ½ÙŦ­ÿÛMóí—ÀØÔVα¬Úèõ„Y€Mú8Êq¦b ªeI]*«xšòÒ%±ŒÛܮа«æZŒ:ÞuýÅQc}{Xy Î û6å’F¯@ßdÖíŒ%¦`S [ðð€ .àÏBï=S=’<_R²vá#èJ‚rY[OŽ“L°ïL<éÓ!‹ò`V9ÓÓ”‰šªžØ½ ,…̬²ìˆ‚e&ðЀ%ݱ¸ev}šäô{Iw°¤Ök4oüŒÞ̲oªÔ×ÎLIßûG‹h0¦Ä³ÕÝ©­&[WZbj-fu,"?~ÎSyËQ6Ö/¶7sç¯ ”®P‡ª¬oá¨dέˆÞÇuLkfÙQË#wqT.Þ²£–±‚£jalω€Wð3#‚<´ARã/ÐcYóµ4Š~h¼µ]E°âï¬ÈF¸Z·§[éÐôt8° ñVb­=†ÁƒH?‘§`ÅORÜ# ü‹­ûI`y".÷¬¯6Wà{Ñ)/¡5ÅÆh3ᔡ=7Kn°dxùK?tБãa¡£É1ý3„ŽÃÉ…™‡ðwô¤BG(mÚM1ö¥…ÐÁ4†õÆxˆíç«D·ñpñ£BÀìu'ùAx²*ÙjÄU)娭µíêì¤G©=œÁÀ ìîMRóDŠv$Âú—«WÝ@•CK™$ /WýÍ<®&6“=Ä>t홈¦¹WO$¬®Ëâ*?€Ý“D.W3I±1½Åë1m_Ðä?w¯^|•å_ÎÀILN_4Qòu~»~wgF¦ØQ`'Ôº ”%"”¯ÊÄdmªª) Øg‚W_„_ }¸ À'©k %7t³ ¥=-•ër÷&­˜üøYË”·.·—j1Ö3irgˆ)zû×A_V>ZeÂÜNsAKO­JUõÀ™ŒÃܾ]LuvX‰œwz¸ (ÌÄÝt€]î]‡îËŠ‚°µWòM½ ªÌð´EU†1ç€5·L¹d¥…D1)âÙû¤˜ \„‰X¿ˆ[;3¸†¼]G†…)|õ€Ù½Å¬:g°C:ùåî÷Ñ{§…T>)Ë pÔo ç—ÌØ ·îßRæ„÷ÿ($fЪŒ+ÐåŠÛ¿ÊF¥¨þv¯²¥ÔpL—â¯ÕcÅ ’½/ê=A€Ÿª"Ì̪‘xK®ãíz%ë©Ü3d°)Z±RݲëXªÑ¥BÀ†šVlÏxŸÅºà@¼_9‹ƒÕé«ù9œ¶´+ª iùÆæ5-µä(j ìõ4úHü©œ*Û'gÿ¯+P¸ÙðTx"Á.¤"—ŠþÚð"Ü®ŽâN>Ó1±ùän± ‚qKX†Mõ#D¤]È•:ó$#ƒD6T ¡¨Ÿ°¬Mf€Ù´áï!tÀ´F|SuJ@[QìÀéO2z“póDÛÈóµPìDÕ¡š™UÐ? ˜qœ/ߦ³ ƒ:¦ ª3¢ü RF\KXp·yÖ‹œA­öd1 rÀ;±4/]Ï‹{YšY\T3d¹™GáUXkØ՛ȑÈw&¦°… ;z+Â'ó¡F³:Ê~\m@,½[VjÈl Å69ƒ1†·×™³uŽ;šA]x]«ËJXSÌíÄ®Ð)HóIÜ=£ëhIä.ߎ4¡ï§]*Iï&‹\²M$T›ë˜Ðç ¢ð–÷þäÐÔKý#Ooq^@YÖ÷”’c»“½÷½-ú:<3”Ҽ襓:$„žÑžUµØÓŽ£iFç›! ŠÕwr%,¸ú€Ê}¼YX&³DK@ÜG¢hWʱxRó‰\*U*eÑ›r4Mò”‚˜]ÓTË“<$ËòΉ˅Óë:Ù6z‰6TÄÊÜÓ’°WKLÂ4Ô€ŸN&Pj8lxñ‚òæÂ6ØÎë&‚Ÿ[z€vrç1QEø~]žÐ‚¹ù>œ®êë%ÌÖw‘­kQd Aº_Vßž{`ÿ5P­•vÝ¥–ò]ÿ¨ß™xMJ6Ö=8€W§yý×C w»Ê%T±¢œÀ•ÜÉ ÛÉÇvãÃ6J™DQwÆÊ{4í­”Žhk8kfR“h—q¯=ÇOç³å gõzdye|c©“¼È'iOö2'L‹}!dPXÈîºòšË¾ l]i¹#³;ÑŸ½yÇ~o‘ÙíÉ©Ágß9 E¶©µ0¥ÝÍEÓÝ£©}®øK5Œ ï¦)Û=F‘&læ«j™Ã3xK/ä…)<ª´c é‹y 6`´3~œØˆ;Òy¶;ÖäfcÝþkSY:j™V0•ûïq),°hävãkã¾éè cæ.ÐvÁyãßqäÃ'ÔH'¯¤r´ï­7îW½² Nzw•Ò}¿v1]æ(‰Uqig—H³Ìš_û,åùæ„~{TÕüxV¦¤ìï¤oà‡ý£Â¼é¼¯õŸN¢ŒýÕ­ùßbkG–ʺ=eŒ¨gÒGÿOjªLXÊç°,û!|—¿©ëÃ_á•ÐK¬ÚÍW(ÁÝmËw/äóž÷y·«%ÛO>™Ê¥dïV€¹òP=ÞTÙ¾;w¿U2c! ߖװ‹hB{ö¦Æ)Å,˜oo*ÂUÛÞö-¬YÙ¿s¿çÿh@sº_ö’¥pn!Y×Füm»\à•šôWMéâU°ªSE–+¡ ýåÑÿloDÿendstream endobj 626 0 obj 4778 endobj 631 0 obj <> stream xœVËnEÝÏš˜å´ÄtúýXp (bFB±ˆìøt›Ä‰¿çT¿¦ç2YºîGuÕéS§ªçÝ(¸ý•ÿ×÷Ó+?Áƒ‰NÄñ0¼d²Ë¿ëûñ‹vAJÚq¹…±QÊÉ?Q8-Â8·QÛSBŒ^ŒËý0}uuñtaËïÃå2¼ĿŰX«()N)G¯à)«_&Ïf; üüº|[H.œPX N™¯èŒ—qlk ¶ÍÍ—Ìr!dÐÓ7 1H¦ &§جiGN +ƒKf¦+6«1÷g³S† iè„"Á‘U9ó=³Ó׫çuƒb¼h³ëÙgÌ`d¥š¾Ã"ÏÊk¬èé'ìÀÚô6œÖøÌNÏÙ]¶Ó<*ÌzO?7…Z\ÿ¸!}7KÎ{® ÿ?ÀÜ|ÙÌMÿz ^c͘t92{Ãf“6O,PbÁIn)ÃPÓ > /Contents 5 0 R >> endobj 93 0 obj <> /Contents 94 0 R >> endobj 102 0 obj <> /Annots[105 0 R 106 0 R 107 0 R 108 0 R 109 0 R 110 0 R 111 0 R 112 0 R 113 0 R 114 0 R 115 0 R 116 0 R 117 0 R 118 0 R 119 0 R 120 0 R 121 0 R 122 0 R 123 0 R 124 0 R 125 0 R 126 0 R 127 0 R 128 0 R 129 0 R 130 0 R 131 0 R 132 0 R 133 0 R 134 0 R 135 0 R 136 0 R 137 0 R]/Contents 103 0 R >> endobj 140 0 obj <> /Annots[143 0 R 144 0 R 145 0 R 146 0 R 147 0 R 148 0 R 149 0 R 150 0 R 151 0 R 152 0 R 153 0 R 154 0 R 155 0 R 156 0 R 157 0 R 158 0 R 159 0 R 160 0 R 161 0 R 162 0 R 163 0 R 164 0 R 165 0 R 166 0 R 167 0 R 168 0 R 169 0 R 170 0 R 171 0 R 172 0 R 173 0 R 174 0 R 175 0 R 176 0 R 177 0 R 178 0 R 179 0 R 180 0 R 181 0 R]/Contents 141 0 R >> endobj 184 0 obj <> /Annots[187 0 R 188 0 R 189 0 R 190 0 R 191 0 R 192 0 R 193 0 R 194 0 R 195 0 R 196 0 R 197 0 R 198 0 R 199 0 R 200 0 R 201 0 R 202 0 R 203 0 R 204 0 R 205 0 R 206 0 R 207 0 R 208 0 R 211 0 R 212 0 R 213 0 R 214 0 R 215 0 R 216 0 R 217 0 R 218 0 R 219 0 R 220 0 R]/Contents 185 0 R >> endobj 223 0 obj <> /Annots[226 0 R 227 0 R 228 0 R 229 0 R 230 0 R]/Contents 224 0 R >> endobj 233 0 obj <> /Contents 234 0 R >> endobj 240 0 obj <> /Annots[243 0 R]/Contents 241 0 R >> endobj 246 0 obj <> /Contents 247 0 R >> endobj 251 0 obj <> /Contents 252 0 R >> endobj 258 0 obj <> /Contents 259 0 R >> endobj 265 0 obj <> /Contents 266 0 R >> endobj 274 0 obj <> /Contents 275 0 R >> endobj 279 0 obj <> /Annots[282 0 R]/Contents 280 0 R >> endobj 285 0 obj <> /Contents 286 0 R >> endobj 290 0 obj <> /Annots[295 0 R]/Contents 291 0 R >> endobj 298 0 obj <> /Contents 299 0 R >> endobj 303 0 obj <> /Annots[306 0 R]/Contents 304 0 R >> endobj 309 0 obj <> /Annots[312 0 R 313 0 R]/Contents 310 0 R >> endobj 316 0 obj <> /Contents 317 0 R >> endobj 321 0 obj <> /Annots[324 0 R]/Contents 322 0 R >> endobj 327 0 obj <> /Contents 328 0 R >> endobj 332 0 obj <> /Annots[335 0 R]/Contents 333 0 R >> endobj 338 0 obj <> /Contents 339 0 R >> endobj 343 0 obj <> /Annots[346 0 R 347 0 R]/Contents 344 0 R >> endobj 350 0 obj <> /Contents 351 0 R >> endobj 355 0 obj <> /Contents 356 0 R >> endobj 360 0 obj <> /Contents 361 0 R >> endobj 365 0 obj <> /Contents 366 0 R >> endobj 370 0 obj <> /Contents 371 0 R >> endobj 375 0 obj <> /Contents 376 0 R >> endobj 380 0 obj <> /Contents 381 0 R >> endobj 385 0 obj <> /Contents 386 0 R >> endobj 390 0 obj <> /Contents 391 0 R >> endobj 395 0 obj <> /Contents 396 0 R >> endobj 400 0 obj <> /Contents 401 0 R >> endobj 405 0 obj <> /Annots[408 0 R]/Contents 406 0 R >> endobj 411 0 obj <> /Annots[414 0 R 415 0 R 416 0 R 417 0 R 418 0 R 419 0 R]/Contents 412 0 R >> endobj 422 0 obj <> /Contents 423 0 R >> endobj 427 0 obj <> /Contents 428 0 R >> endobj 432 0 obj <> /Annots[435 0 R]/Contents 433 0 R >> endobj 438 0 obj <> /Contents 439 0 R >> endobj 443 0 obj <> /Annots[446 0 R 447 0 R]/Contents 444 0 R >> endobj 450 0 obj <> /Annots[453 0 R]/Contents 451 0 R >> endobj 456 0 obj <> /Contents 457 0 R >> endobj 461 0 obj <> /Annots[464 0 R 465 0 R]/Contents 462 0 R >> endobj 468 0 obj <> /Annots[471 0 R 472 0 R 473 0 R 474 0 R 475 0 R]/Contents 469 0 R >> endobj 478 0 obj <> /Annots[481 0 R]/Contents 479 0 R >> endobj 484 0 obj <> /Contents 485 0 R >> endobj 489 0 obj <> /Contents 490 0 R >> endobj 494 0 obj <> /Contents 495 0 R >> endobj 499 0 obj <> /Contents 500 0 R >> endobj 504 0 obj <> /Annots[507 0 R]/Contents 505 0 R >> endobj 510 0 obj <> /Annots[513 0 R 514 0 R 515 0 R 516 0 R 517 0 R]/Contents 511 0 R >> endobj 520 0 obj <> /Contents 521 0 R >> endobj 525 0 obj <> /Contents 526 0 R >> endobj 530 0 obj <> /Annots[533 0 R 534 0 R]/Contents 531 0 R >> endobj 537 0 obj <> /Contents 538 0 R >> endobj 542 0 obj <> /Annots[545 0 R 546 0 R 547 0 R]/Contents 543 0 R >> endobj 550 0 obj <> /Contents 551 0 R >> endobj 555 0 obj <> /Contents 556 0 R >> endobj 560 0 obj <> /Annots[563 0 R]/Contents 561 0 R >> endobj 566 0 obj <> /Annots[569 0 R 570 0 R 571 0 R 572 0 R]/Contents 567 0 R >> endobj 575 0 obj <> /Annots[578 0 R 579 0 R 580 0 R 581 0 R 582 0 R]/Contents 576 0 R >> endobj 585 0 obj <> /Contents 586 0 R >> endobj 590 0 obj <> /Annots[593 0 R 594 0 R 595 0 R 596 0 R 597 0 R]/Contents 591 0 R >> endobj 600 0 obj <> /Annots[603 0 R 604 0 R 605 0 R 606 0 R]/Contents 601 0 R >> endobj 609 0 obj <> /Contents 610 0 R >> endobj 614 0 obj <> /Contents 615 0 R >> endobj 619 0 obj <> /Contents 620 0 R >> endobj 624 0 obj <> /Annots[627 0 R]/Contents 625 0 R >> endobj 630 0 obj <> /Annots[633 0 R]/Contents 631 0 R >> endobj 3 0 obj << /Type /Pages /Kids [ 4 0 R 93 0 R 102 0 R 140 0 R 184 0 R 223 0 R 233 0 R 240 0 R 246 0 R 251 0 R 258 0 R 265 0 R 274 0 R 279 0 R 285 0 R 290 0 R 298 0 R 303 0 R 309 0 R 316 0 R 321 0 R 327 0 R 332 0 R 338 0 R 343 0 R 350 0 R 355 0 R 360 0 R 365 0 R 370 0 R 375 0 R 380 0 R 385 0 R 390 0 R 395 0 R 400 0 R 405 0 R 411 0 R 422 0 R 427 0 R 432 0 R 438 0 R 443 0 R 450 0 R 456 0 R 461 0 R 468 0 R 478 0 R 484 0 R 489 0 R 494 0 R 499 0 R 504 0 R 510 0 R 520 0 R 525 0 R 530 0 R 537 0 R 542 0 R 550 0 R 555 0 R 560 0 R 566 0 R 575 0 R 585 0 R 590 0 R 600 0 R 609 0 R 614 0 R 619 0 R 624 0 R 630 0 R ] /Count 72 >> endobj 9 0 obj << /Count 72 /First 10 0 R /Last 75 0 R >> endobj 1 0 obj <> 1 << /P (0) >> 2 << /S /D >>] >> /Metadata 660 0 R >> endobj 7 0 obj <>endobj 11 0 obj << /Title(A Simple Example: Hello, world!) /Dest/section.1.1 /Parent 10 0 R /Next 12 0 R >> endobj 13 0 obj << /Title(Comments) /Dest/subsection.1.2.1 /Parent 12 0 R /Next 14 0 R >> endobj 14 0 obj << /Title(Primitive Expressions) /Dest/subsection.1.2.2 /Parent 12 0 R /Prev 13 0 R /Next 15 0 R >> endobj 15 0 obj << /Title(Fixity) /Dest/subsection.1.2.3 /Parent 12 0 R /Prev 14 0 R /Next 16 0 R >> endobj 16 0 obj << /Title(Naming and the Environment) /Dest/subsection.1.2.4 /Parent 12 0 R /Prev 15 0 R /Next 17 0 R >> endobj 17 0 obj << /Title(Conditionals) /Dest/subsection.1.2.5 /Parent 12 0 R /Prev 16 0 R /Next 18 0 R >> endobj 18 0 obj << /Title(Local Bindings) /Dest/subsection.1.2.6 /Parent 12 0 R /Prev 17 0 R /Next 19 0 R >> endobj 19 0 obj << /Title(Function Definitions) /Dest/subsection.1.2.7 /Parent 12 0 R /Prev 18 0 R /Next 20 0 R >> endobj 20 0 obj << /Title(Overloading) /Dest/subsection.1.2.8 /Parent 12 0 R /Prev 19 0 R >> endobj 12 0 obj << /Title(Elements of Programming) /Dest/section.1.2 /Count 8 /Parent 10 0 R /Prev 11 0 R /Next 21 0 R /First 13 0 R /Last 20 0 R >> endobj 21 0 obj << /Title(Tuples and Records) /Dest/section.1.3 /Parent 10 0 R /Prev 12 0 R /Next 22 0 R >> endobj 22 0 obj << /Title(Disjoint Variants) /Dest/section.1.4 /Parent 10 0 R /Prev 21 0 R /Next 23 0 R >> endobj 24 0 obj << /Title(Template Declaration and Implementation) /Dest/subsection.1.5.1 /Parent 23 0 R >> endobj 23 0 obj << /Title(Parametric Polymorphism and Templates) /Dest/section.1.5 /Count 1 /Parent 10 0 R /Prev 22 0 R /Next 25 0 R /First 24 0 R /Last 24 0 R >> endobj 25 0 obj << /Title(Lists) /Dest/section.1.6 /Parent 10 0 R /Prev 23 0 R /Next 26 0 R >> endobj 26 0 obj << /Title(Exceptions) /Dest/section.1.7 /Parent 10 0 R /Prev 25 0 R /Next 27 0 R >> endobj 27 0 obj << /Title(References) /Dest/section.1.8 /Parent 10 0 R /Prev 26 0 R /Next 28 0 R >> endobj 28 0 obj << /Title(Arrays) /Dest/section.1.9 /Parent 10 0 R /Prev 27 0 R /Next 29 0 R >> endobj 29 0 obj << /Title(Higher-Order Functions) /Dest/section.1.10 /Parent 10 0 R /Prev 28 0 R /Next 30 0 R >> endobj 30 0 obj << /Title(Tail-Call Optimization) /Dest/section.1.11 /Parent 10 0 R /Prev 29 0 R /Next 31 0 R >> endobj 31 0 obj << /Title(Static and Dynamic Files) /Dest/section.1.12 /Parent 10 0 R /Prev 30 0 R /Next 32 0 R >> endobj 32 0 obj << /Title(Static Load and Dynamic Load) /Dest/section.1.13 /Parent 10 0 R /Prev 31 0 R /Next 33 0 R >> endobj 33 0 obj << /Title(Input and Output) /Dest/section.1.14 /Parent 10 0 R /Prev 32 0 R /Next 34 0 R >> endobj 34 0 obj << /Title(A Simple Package for Rational Numbers) /Dest/section.1.15 /Parent 10 0 R /Prev 33 0 R >> endobj 10 0 obj << /Title(ATS BASICS) /Dest/chapter.1 /Count 24 /Parent 9 0 R /Next 35 0 R /First 11 0 R /Last 34 0 R >> endobj 37 0 obj << /Title(Compiling Static and Dynamic Files) /Dest/subsection.2.1.1 /Parent 36 0 R /Next 38 0 R >> endobj 38 0 obj << /Title(Typechecking Only) /Dest/subsection.2.1.2 /Parent 36 0 R /Prev 37 0 R /Next 39 0 R >> endobj 39 0 obj << /Title(Generating HTML Files) /Dest/subsection.2.1.3 /Parent 36 0 R /Prev 38 0 R /Next 40 0 R >> endobj 40 0 obj << /Title(Generating HTML Files for cross-referencing) /Dest/subsection.2.1.4 /Parent 36 0 R /Prev 39 0 R /Next 41 0 R >> endobj 41 0 obj << /Title(Generating Usage Information) /Dest/subsection.2.1.5 /Parent 36 0 R /Prev 40 0 R /Next 42 0 R >> endobj 42 0 obj << /Title(Generating Version Information) /Dest/subsection.2.1.6 /Parent 36 0 R /Prev 41 0 R >> endobj 36 0 obj << /Title(The Command atsopt) /Dest/section.2.1 /Count 6 /Parent 35 0 R /Next 43 0 R /First 37 0 R /Last 42 0 R >> endobj 44 0 obj << /Title(Generating Executables) /Dest/subsection.2.2.1 /Parent 43 0 R /Next 45 0 R >> endobj 45 0 obj << /Title(Typechecking Only) /Dest/subsection.2.2.2 /Parent 43 0 R /Prev 44 0 R /Next 46 0 R >> endobj 46 0 obj << /Title(Compilation Only) /Dest/subsection.2.2.3 /Parent 43 0 R /Prev 45 0 R /Next 47 0 R >> endobj 47 0 obj << /Title(Binary Types) /Dest/subsection.2.2.4 /Parent 43 0 R /Prev 46 0 R /Next 48 0 R >> endobj 48 0 obj << /Title(Garbage Collection) /Dest/subsection.2.2.5 /Parent 43 0 R /Prev 47 0 R /Next 49 0 R >> endobj 49 0 obj << /Title(Directories for File Search) /Dest/subsection.2.2.6 /Parent 43 0 R /Prev 48 0 R /Next 50 0 R >> endobj 50 0 obj << /Title(Setting Command-Line Flags) /Dest/subsection.2.2.7 /Parent 43 0 R /Prev 49 0 R >> endobj 43 0 obj << /Title(The Command atscc) /Dest/section.2.2 /Count 7 /Parent 35 0 R /Prev 36 0 R /First 44 0 R /Last 50 0 R >> endobj 35 0 obj << /Title(BATCH COMPILATION) /Dest/chapter.2 /Count 15 /Parent 9 0 R /Prev 10 0 R /Next 51 0 R /First 36 0 R /Last 43 0 R >> endobj 52 0 obj << /Title(C-like Macros) /Dest/section.3.1 /Parent 51 0 R /Next 53 0 R >> endobj 54 0 obj << /Title(Macros in Long Form) /Dest/subsection.3.2.1 /Parent 53 0 R /Next 55 0 R >> endobj 55 0 obj << /Title(Macros in Short Form) /Dest/subsection.3.2.2 /Parent 53 0 R /Prev 54 0 R /Next 56 0 R >> endobj 56 0 obj << /Title(Recursive Macro Definitions) /Dest/subsection.3.2.3 /Parent 53 0 R /Prev 55 0 R >> endobj 53 0 obj << /Title(LISP-like Macros) /Dest/section.3.2 /Count 3 /Parent 51 0 R /Prev 52 0 R /First 54 0 R /Last 56 0 R >> endobj 51 0 obj << /Title(Macros) /Dest/chapter.3 /Count 5 /Parent 9 0 R /Prev 35 0 R /Next 57 0 R /First 52 0 R /Last 53 0 R >> endobj 58 0 obj << /Title(External C Code) /Dest/section.4.1 /Parent 57 0 R /Next 59 0 R >> endobj 59 0 obj << /Title(External Types) /Dest/section.4.2 /Parent 57 0 R /Prev 58 0 R /Next 60 0 R >> endobj 60 0 obj << /Title(External Values) /Dest/section.4.3 /Parent 57 0 R /Prev 59 0 R >> endobj 57 0 obj << /Title(Interaction with C) /Dest/chapter.4 /Count 3 /Parent 9 0 R /Prev 51 0 R /Next 61 0 R /First 58 0 R /Last 60 0 R >> endobj 62 0 obj << /Title(Statics) /Dest/section.5.1 /Parent 61 0 R /Next 63 0 R >> endobj 63 0 obj << /Title(Common Arithmetic and Comparison Functions) /Dest/section.5.2 /Parent 61 0 R /Prev 62 0 R /Next 64 0 R >> endobj 64 0 obj << /Title(Constraint Solving) /Dest/section.5.3 /Parent 61 0 R /Prev 63 0 R /Next 65 0 R >> endobj 65 0 obj << /Title(A Simple Example: Dependent Types for Debugging) /Dest/section.5.4 /Parent 61 0 R /Prev 64 0 R /Next 66 0 R >> endobj 66 0 obj << /Title(Dependent Datatypes) /Dest/section.5.5 /Parent 61 0 R /Prev 65 0 R /Next 67 0 R >> endobj 68 0 obj << /Title(Exhaustiveness) /Dest/subsection.5.6.1 /Parent 67 0 R /Next 69 0 R >> endobj 69 0 obj << /Title(Sequentiality) /Dest/subsection.5.6.2 /Parent 67 0 R /Prev 68 0 R >> endobj 67 0 obj << /Title(Pattern Matching) /Dest/section.5.6 /Count 2 /Parent 61 0 R /Prev 66 0 R /Next 70 0 R /First 68 0 R /Last 69 0 R >> endobj 70 0 obj << /Title(Program Termination Verification) /Dest/section.5.7 /Parent 61 0 R /Prev 67 0 R >> endobj 61 0 obj << /Title(Programming with Dependent Types) /Dest/chapter.5 /Count 9 /Parent 9 0 R /Prev 57 0 R /Next 71 0 R /First 62 0 R /Last 70 0 R >> endobj 72 0 obj << /Title(Nonlinear Constraint Avoidance) /Dest/section.6.1 /Parent 71 0 R /Next 73 0 R >> endobj 73 0 obj << /Title(Proof Functions) /Dest/section.6.2 /Parent 71 0 R /Prev 72 0 R /Next 74 0 R >> endobj 74 0 obj << /Title(Datasorts) /Dest/section.6.3 /Parent 71 0 R /Prev 73 0 R >> endobj 71 0 obj << /Title(Programming with Theorem Proving) /Dest/chapter.6 /Count 3 /Parent 9 0 R /Prev 61 0 R /Next 75 0 R /First 72 0 R /Last 74 0 R >> endobj 76 0 obj << /Title(Safe Memory Access through Pointers) /Dest/section.7.1 /Parent 75 0 R /Next 77 0 R >> endobj 77 0 obj << /Title(Local Variables) /Dest/section.7.2 /Parent 75 0 R /Prev 76 0 R /Next 78 0 R >> endobj 78 0 obj << /Title(Memory Allocation on Stack) /Dest/section.7.3 /Parent 75 0 R /Prev 77 0 R /Next 79 0 R >> endobj 79 0 obj << /Title(Call-By-Reference) /Dest/section.7.4 /Parent 75 0 R /Prev 78 0 R /Next 80 0 R >> endobj 80 0 obj << /Title(Dataviews) /Dest/section.7.5 /Parent 75 0 R /Prev 79 0 R /Next 81 0 R >> endobj 81 0 obj << /Title(Dataviewtypes) /Dest/section.7.6 /Parent 75 0 R /Prev 80 0 R >> endobj 91 0 obj <> endobj 92 0 obj <> endobj 100 0 obj <> endobj 101 0 obj <> endobj 105 0 obj <>endobj 106 0 obj <>endobj 107 0 obj <>endobj 108 0 obj <>endobj 109 0 obj <>endobj 110 0 obj <>endobj 111 0 obj <>endobj 112 0 obj <>endobj 113 0 obj <>endobj 114 0 obj <>endobj 115 0 obj <>endobj 116 0 obj <>endobj 117 0 obj <>endobj 118 0 obj <>endobj 119 0 obj <>endobj 120 0 obj <>endobj 121 0 obj <>endobj 122 0 obj <>endobj 123 0 obj <>endobj 124 0 obj <>endobj 125 0 obj <>endobj 126 0 obj <>endobj 127 0 obj <>endobj 128 0 obj <>endobj 129 0 obj <>endobj 130 0 obj <>endobj 131 0 obj <>endobj 132 0 obj <>endobj 133 0 obj <>endobj 134 0 obj <>endobj 135 0 obj <>endobj 136 0 obj <>endobj 137 0 obj <>endobj 138 0 obj <> endobj 139 0 obj <> endobj 143 0 obj <>endobj 144 0 obj <>endobj 145 0 obj <>endobj 146 0 obj <>endobj 147 0 obj <>endobj 148 0 obj <>endobj 149 0 obj <>endobj 150 0 obj <>endobj 151 0 obj <>endobj 152 0 obj <>endobj 153 0 obj <>endobj 154 0 obj <>endobj 155 0 obj <>endobj 156 0 obj <>endobj 157 0 obj <>endobj 158 0 obj <>endobj 159 0 obj <>endobj 160 0 obj <>endobj 161 0 obj <>endobj 162 0 obj <>endobj 163 0 obj <>endobj 164 0 obj <>endobj 165 0 obj <>endobj 166 0 obj <>endobj 167 0 obj <>endobj 168 0 obj <>endobj 169 0 obj <>endobj 170 0 obj <>endobj 171 0 obj <>endobj 172 0 obj <>endobj 173 0 obj <>endobj 174 0 obj <>endobj 175 0 obj <>endobj 176 0 obj <>endobj 177 0 obj <>endobj 178 0 obj <>endobj 179 0 obj <>endobj 180 0 obj <>endobj 181 0 obj <>endobj 182 0 obj <> endobj 183 0 obj <> endobj 187 0 obj <>endobj 188 0 obj <>endobj 189 0 obj <>endobj 190 0 obj <>endobj 191 0 obj <>endobj 192 0 obj <>endobj 193 0 obj <>endobj 194 0 obj <>endobj 195 0 obj <>endobj 196 0 obj <>endobj 197 0 obj <>endobj 198 0 obj <>endobj 199 0 obj <>endobj 200 0 obj <>endobj 201 0 obj <>endobj 202 0 obj <>endobj 203 0 obj <>endobj 204 0 obj <>endobj 205 0 obj <>endobj 206 0 obj <>endobj 207 0 obj <>endobj 208 0 obj <>endobj 211 0 obj <>endobj 212 0 obj <>endobj 213 0 obj <>endobj 214 0 obj <>endobj 215 0 obj <>endobj 216 0 obj <>endobj 217 0 obj <>endobj 218 0 obj <>endobj 219 0 obj <>endobj 220 0 obj <>endobj 221 0 obj <> endobj 222 0 obj <> endobj 226 0 obj <>endobj 227 0 obj <>endobj 228 0 obj <>endobj 229 0 obj <>endobj 230 0 obj <>endobj 231 0 obj <> endobj 232 0 obj <> endobj 238 0 obj <> endobj 239 0 obj <> endobj 243 0 obj <>endobj 244 0 obj <> endobj 245 0 obj <> endobj 249 0 obj <> endobj 250 0 obj <> endobj 256 0 obj <> endobj 257 0 obj <> endobj 263 0 obj <> endobj 264 0 obj <> endobj 272 0 obj <> endobj 273 0 obj <> endobj 277 0 obj <> endobj 278 0 obj <> endobj 282 0 obj <>endobj 283 0 obj <> endobj 284 0 obj <> endobj 288 0 obj <> endobj 289 0 obj <> endobj 295 0 obj <>endobj 296 0 obj <> endobj 297 0 obj <> endobj 301 0 obj <> endobj 302 0 obj <> endobj 306 0 obj <>endobj 307 0 obj <> endobj 308 0 obj <> endobj 312 0 obj <>endobj 313 0 obj <>endobj 314 0 obj <> endobj 315 0 obj <> endobj 319 0 obj <> endobj 320 0 obj <> endobj 324 0 obj <>endobj 325 0 obj <> endobj 326 0 obj <> endobj 330 0 obj <> endobj 331 0 obj <> endobj 335 0 obj <>endobj 336 0 obj <> endobj 337 0 obj <> endobj 341 0 obj <> endobj 342 0 obj <> endobj 346 0 obj <>endobj 347 0 obj <>endobj 348 0 obj <> endobj 349 0 obj <> endobj 353 0 obj <> endobj 354 0 obj <> endobj 358 0 obj <> endobj 359 0 obj <> endobj 363 0 obj <> endobj 364 0 obj <> endobj 368 0 obj <> endobj 369 0 obj <> endobj 373 0 obj <> endobj 374 0 obj <> endobj 378 0 obj <> endobj 379 0 obj <> endobj 383 0 obj <> endobj 384 0 obj <> endobj 388 0 obj <> endobj 389 0 obj <> endobj 393 0 obj <> endobj 394 0 obj <> endobj 398 0 obj <> endobj 399 0 obj <> endobj 403 0 obj <> endobj 404 0 obj <> endobj 408 0 obj <>endobj 409 0 obj <> endobj 410 0 obj <> endobj 414 0 obj <>endobj 415 0 obj <>endobj 416 0 obj <>endobj 417 0 obj <>endobj 418 0 obj <>endobj 419 0 obj <>endobj 420 0 obj <> endobj 421 0 obj <> endobj 425 0 obj <> endobj 426 0 obj <> endobj 430 0 obj <> endobj 431 0 obj <> endobj 435 0 obj <>endobj 436 0 obj <> endobj 437 0 obj <> endobj 441 0 obj <> endobj 442 0 obj <> endobj 446 0 obj <>endobj 447 0 obj <>endobj 448 0 obj <> endobj 449 0 obj <> endobj 453 0 obj <>endobj 454 0 obj <> endobj 455 0 obj <> endobj 459 0 obj <> endobj 460 0 obj <> endobj 464 0 obj <>endobj 465 0 obj <>endobj 466 0 obj <> endobj 467 0 obj <> endobj 471 0 obj <>endobj 472 0 obj <>endobj 473 0 obj <>endobj 474 0 obj <>endobj 475 0 obj <>endobj 476 0 obj <> endobj 477 0 obj <> endobj 481 0 obj <>endobj 482 0 obj <> endobj 483 0 obj <> endobj 487 0 obj <> endobj 488 0 obj <> endobj 492 0 obj <> endobj 493 0 obj <> endobj 497 0 obj <> endobj 498 0 obj <> endobj 502 0 obj <> endobj 503 0 obj <> endobj 507 0 obj <>endobj 508 0 obj <> endobj 509 0 obj <> endobj 513 0 obj <>endobj 514 0 obj <>endobj 515 0 obj <>endobj 516 0 obj <>endobj 517 0 obj <>endobj 518 0 obj <> endobj 519 0 obj <> endobj 523 0 obj <> endobj 524 0 obj <> endobj 528 0 obj <> endobj 529 0 obj <> endobj 533 0 obj <>endobj 534 0 obj <>endobj 535 0 obj <> endobj 536 0 obj <> endobj 540 0 obj <> endobj 541 0 obj <> endobj 545 0 obj <>endobj 546 0 obj <>endobj 547 0 obj <>endobj 548 0 obj <> endobj 549 0 obj <> endobj 553 0 obj <> endobj 554 0 obj <> endobj 558 0 obj <> endobj 559 0 obj <> endobj 563 0 obj <>endobj 564 0 obj <> endobj 565 0 obj <> endobj 569 0 obj <>endobj 570 0 obj <>endobj 571 0 obj <>endobj 572 0 obj <>endobj 573 0 obj <> endobj 574 0 obj <> endobj 578 0 obj <>endobj 579 0 obj <>endobj 580 0 obj <>endobj 581 0 obj <>endobj 582 0 obj <>endobj 583 0 obj <> endobj 584 0 obj <> endobj 588 0 obj <> endobj 589 0 obj <> endobj 593 0 obj <>endobj 594 0 obj <>endobj 595 0 obj <>endobj 596 0 obj <>endobj 597 0 obj <>endobj 598 0 obj <> endobj 599 0 obj <> endobj 603 0 obj <>endobj 604 0 obj <>endobj 605 0 obj <>endobj 606 0 obj <>endobj 607 0 obj <> endobj 608 0 obj <> endobj 612 0 obj <> endobj 613 0 obj <> endobj 617 0 obj <> endobj 618 0 obj <> endobj 622 0 obj <> endobj 623 0 obj <> endobj 627 0 obj <>endobj 628 0 obj <> endobj 629 0 obj <> endobj 633 0 obj <>endobj 634 0 obj <> endobj 635 0 obj <> endobj 98 0 obj <> endobj 649 0 obj <> endobj 293 0 obj <> endobj 96 0 obj <> endobj 650 0 obj <> endobj 651 0 obj <>stream xœ]O»ƒ0 ÜóþƒðP;!º0Um 8Ê€…0ôïKtèp–Îw'Ÿe×ßz¶ä#8|QcYZÜ`¤É²(+ÐãÁòÄYy!»»òï'Ø dv>¨™äóz)óªÜCè4-^!ʼn¦(ÚÆ˜Vë?éŒæpÖ›3¡*ê*ûO%ES‰ó&àqÌMs“TÀ2ýžñΧl_,iS' endstream endobj 270 0 obj <> endobj 652 0 obj <> endobj 268 0 obj <> endobj 653 0 obj <> endobj 654 0 obj <>stream xœ]‘Ánƒ0 †ï> endobj 655 0 obj <> endobj 261 0 obj <> endobj 87 0 obj <> endobj 656 0 obj <> endobj 254 0 obj <> endobj 85 0 obj <> endobj 657 0 obj <> endobj 236 0 obj <> endobj 658 0 obj <> endobj 83 0 obj <> endobj 82 0 obj <> endobj 209 0 obj <> endobj 659 0 obj <> endobj 99 0 obj <> endobj %BeginResource: file (PDF FontFile obj_636) 636 0 obj <>stream xœuXiT×¶®¶©®rj•¦P4éngqÀœÔ‚2É$£ "ÐŒ (AQe–Vf$ŠC &&&ÑxCb’]äuï)LòîZï½U«ÿœUU½÷þ¾ýío—ˆÒA‰D¢q&¾î!¡^!Æ6 ŒUžÂÑ,~Šˆÿhÿ±x5VýÁ FÓhŒÑ*øhb¿6¯˜…ãÀu<%‰œö%˜¨‚#Bü||C•‹W®\¤t߯tR†‡yøí÷õòT†«Bü•Jc¿Ðý¡!^îÊ­A{ ””ÃÏíW†xí÷ 9àåi 4Qyûyz…ú¹üÏ…¨ü_§E­ßd¬2 Þ´osˆé~³Ð-a[„»ô0ØcéiéµÝÛÊÇw‡ßν6þ¶vË–¯˜j´rÕúód,Z¼Äp)EM£¶SÓ)+jeMͤvP³¨ÔlʆšCÙRú”5—ÚEÙSÆ”eB- ©M”åDm¦R¦Ô"ÊŒZLm¡¶R†Ô6j)õ µŒ2§–SÔ Ê’Ò¥&R“¨”5™šB)©@j,%¥TÔ8j¥MÉ(Š£6$(-Âu‘‘(VôlÄ®WÅSÄAâN­‰Z‡´ÞÒFtÍKæI¼$UÌL&šyÎ~ÌîcGNé0²yÔ„Qá£F/6ÆjLõØMcOJÇHUÒ+ãØqÞã2ÆõŽ÷ß>aþ„]ò´§i'k7É”²*ÙKÙŸ:ãuë¨unp —ÉÝ…Zé iÀº•§ DqƒkÄpqp‡üImO Á_ØgÄçtÀZ‚$xÝáóDr^¤a¬²p$ÿoÚÌ}7I¤üϨŽqÝë™ö+ («»¤ ¨NâšGÃ×ÌõìË'. ön‰ßF>ÄD«Ý’i8ZÇØ¥Å »¶,tÝæ¹I~lj‘}Žg8Ó{>ïɭöÉ´tE-×G›µßƒ.˜|('Ê~-4ä™;IùÑôPe•D‚ìbÀè»{ ýz['yL!;ø¯ Íý“ßolÂs䲃óñm’˜ÜÔœÔľ¬ó^»ØiÏô„”š ýŠ?ׂlæâ±s(±oo¹/Ÿ·Ë³ê¨ÔÔH…”x¨‰ŸÙ$ªDƒ\ >™Ã‹gÎÄxÞ»Ù0–¼{sÀPÿ ^ H¶ãî×o±®«éÆÍ.÷a"pu÷î+¤ƒÚ±wùîQÌó¯Ïs°Á„ ÁcÕêý‰áG"‘Ö_ôÉqó¿ÂÇÅÅIñ%ŠÜȳJú!¬–l9o–cЦ£åæ–fÛ|– ™ëta­÷š »Q}èºwêÓó¬”ÿ«êaC3ð•>ßj?)øÀGeOŠ°ŠƒIj½yš:—†¥Ì•ä’£ç ËyKAiôjª£C˜‡•¢Ã…‘•âY…χîl“hÙØÑ?ÿè‘3âQâ'ièŠKuù«`f&‰œEc5䀮$7:Ë„¾j+I¼It4u!œ$91y†ô=X<”:œï_„$ùJù•¨žÁè%•¤?ÆM”}^ª ¥u’MijBýJæÒÙó™ù¨Æå…°’‡e‡Cz‡Ñ¡”Ã)A{ü|<Ó~žä$‘Uàپᶰ#mÁkHgt±v¡æâ2]hÐH6§GæÓ„ž“™Ü˜,ch4 Ô8:†Æ“áØ Î¥?‡5C)Ž’îÝ.º3®…ŸÑ*j€q0F‰y¯âìO;œt Ugl¾lûu߇ފ~Ïæxd˺¨lU¹ûäñÙqßÒ–xޤ+²åP!÷¨û]ߎ’%5 «R¿Ó¨š­()ÒKŒ/”ŸŠËÚ@wH¤ƒŽ±ŸÂ TßUÂLh1? ¾&ÝüPˆ »1ûŽL‰'l°àWØ&/Þƒ~iIR\‰"/âìTú¬“l<·){+¹#OÇcwì Óð ð~ð0·ä Ò L~n{:­a¤ðGÒxÓñ¾@ôÆ‹ŸòK8\Ë ûTÿòТ¨’Ä+¨ 5fuœc˜ð¤G÷#vkdñ})Öœ<Æ›3»¦ot§½é`*©wqÖˆÞƒTƒž¸lXÚÿ!¸µ@ðkf{zA!ªq:£ªëåÆZ8å/2ùùBd¸Ü‘éHÊ#ÄRájP‘ÓŽáxùŸ¾]WÇ‹o\,ÐþŽ(êV50ÄfªíÙƒ3˜©ÝùcScQÕ]¹,Ô¬ë˜]‚Öòf»F¦‰ß«J ™bºïj¿î’BüŽ4ü=´`²À–FdËpDe¤VŸ 5:2½ÿpb«À‰,TÀ¯¬%òâD>ŠÛÍt$ÂÒ!3ú làMÛ3èz¼c7s;éd4–àÚéP—Ó˜NדbU~x2e°Iœò÷“yò­F1Æô; |Ä›¶ /±ÞÍ4%fDâj, gKðH « *;W“!¼Ž¯JȬ=¶·ar¡Ì$XÄðªËÙAƒi­Ä.=†Ú)tœ5X‰'-³Úœ_&ñRr&-ïXb{KýM örž„0îo¶ý¢¹¹¨¦[^¥å»U¥õ½MÅ0ª˜(ÁETËO­eó§Å¹Ãñ·v"/7³Š£]Á®–±Ïz òïðääxßÚbj»L¬þ «Z„¬Ì]™Û Kñ„Õ0:=ûú ºš$ò0¥™÷ÃÂ%¢'^O, çðgÚ³ïO%™†G3‘pé}ZOVäÿRßò-–…)F/°ÄÕYh+‡ÌŸµàæ|záñ3ˆ}ÑdI˜hc‰ÇÆÇ¡Ô8’@%jç;5¢_ MKtùc`¿Q¢ÆRAÈløjI~n§€x•#Ó”;Œxä¹:…UßðkD§ù|q2ÑY7¦#L‡v„löØw@oiÇÞȃ!(HÏ«ÂGÓ{¿Fiä`Ëû5gÒ5ØÆ ˜©Æ"\Ž)¸–•{û]Cr>4ÀÕˆÊá#1ïYÇÝgÕnˆ5°¼c@ÒÙw/ãdÊÑ,ÅTæLÌÙD2jJKotZ4ÌÀs1¥ÄóñÌÍ‚™ÝgÊ»Ò?Bãû ¢_úøpÐ_Ð…pÄ"C}†æ/0à:ô†î“€'ÿžºÊÄGY½W¦aÌÒ㆙žûÙ ºŸ bðÂ!¼ˆw¥/â<'¦7ñT =TÂDG|r˜Tá™ecšEõü q½.¿ŒÌ$± Õ¤v8ÃKéÆ!%ž×Ãd}Ch·\‚³‡$ä© I/óZ­0¿’ [“!¤b^oPÉáåŒOFÀñ`"Xó§*ñ2<㫹 uûVQu›b'l'dJ‹Î§WÖ'*Ï<jæücU‡‰Ù÷–}§ï›ÂóIñ¥dÒú£þ¾FôËž{ .Ö…ƒ ‹“Q¤{x3t•-þ¥äôÙ;'雸 3ÓyèÌAzhƒïð*ºGþy1auˆÄ]˜Ð–Mð±0buÀ&ŠùXÏY{ÛFØ!vŽÅgÀ¤"r)àK :2Ð f¬ûŠ˜›3¦áxÞëÙ ï^ÁOådfsx§äø³ª[ˆm¹ìf”ŒŽ dõá¨Nþa7ñ=úüX˜+®‚öƒñ4ØóôËKmò{=? ßÐî¯ÖõZ6/Chm¹µ™¹¯!Â"^À5DýJl7¯Á¡\˜ƒÙÀo VHá%ªçµ: X#úñ Ä…Õ G&í;˜Ü'w0è8¹Ž¡‡9·‹K~Z6ézNÁ9TÂÖø”Y{¸E«¼å¦ö{Mмm“¼zð[&:ÊA艧DøÛ¡sxЂ ñ~¥ÃÃvSºšÈü¦ìhQ ‘Xóò)Èa†a;¶Pà"GIoRÞpkEÖ¼HeàN#ó\c7ê.Ûéq±©©1¤Qp`|òíÝ:pl‹¸©}¤³ +`ÜZ=Q6âçñ¾œlUà¸;Óm Ö[µy¦IÍ“P…÷Þˆ ´E§EfdeßÇ}’èén1yå#ä2 ¾~ùÍÆ2<³Pn–y4+%ÔC§ŽŸJÏÉJÉ"âÂ’7ä/ï½*>|A]¬ªMBþWEpµån&ëýv;;ùÕ=~pµæ–‚¼ÚtÈ„û&ú~lE4rÔ³wv3ÙâXß|9÷âÅ"¹”),Ï>HÚ÷Ä=XÒƒÑß’ö`èÛ>Þ…ìŒë°ïù°#¶ëâÿ¿¸´,t± ó4‘C ™'†ƒ”6ÈkœØR|éÿ²ÿdÌZß0æ¡j:z‡ŠÝ.ÍÏwÊtiÜsþ`El º„®/O'ó> %“k Ì;ÐrðÖ¡æ€ÚÐË~g².¼ÓŽ^° ^ÝÊçìàê%?ÝÞ½r¡½»2.  A;É™"]>úÚ?Àl¬¦ô$X>èËyø»¹^ ¬¬¾|©®*ð² ©_6>H†7éëÞa÷f+äšWÇìŠÁo" Ù×Ãwu‹ÔL‰JÞ9Çu…}×M8eôî[ÒûþÍÖ «ëvygí.«ÊP=ÛRWùàrQRÂynôéétQ!ósæ§,ˆÀL7X†ÅŽçë=µÞ7#+Ãïû\ó!žÍÆiϪ€ ôL•<&/ ÆÐë%R¸…÷Öñˆ×y s°ž°À}"~74žAú‡¶†øé?Ÿäs8,ù³{Ê[»ï–ݺ!¯kÏ|ˆÞ²ü4wÏ#–ƒ‘Mj…ÜxÕÕËUµþ—=\\ =Þ½îjAÔ]‚ þ¡ã.ÒÖƒ¶±|£FôÑéψ †étWPFü†AëÒ­nØWízø†€`õø |¢€·LîéÎdl† MÌ‹¤ñ Öó°Àb<Æ­ 89üÂäæv}°mÄ@üJ ;,EEºPX+±>Aôbp™ë‡Šõ }ÃDG['’HÆ-àßiD׊ ‡Ñ áC¼àBxèÉ!©Üb¶/rÆ«xçì¼îöñ„ˆâ ïoc²ê™ L\Äå¹àú=ç+Új¶‡6ë'Ã$ìù{³n8÷¿¶ô˧.ž8Øîâ½›8™‰Žônˆ«e\Ò…ž0WN]Ì k|oñÞ ÿÕ²)ÿݲ»[ ä²EÞh{ØêÝd íOh‡š'0û½èÕb‹ôįøß072«Ò«HYGôì\bdn±*Jš¥ð::-öxÒs òÛzßbóè7ž‘†XáåyXíª€µÐóžtLL<þ’ D7‰Ü%‘ˆ÷tá𩼯Eø$‹­Â4,ýßß‘C¶ø¹Ó.b¯ƒüèý&eU'OÂU¸ž»rúÚÉëd¡mÜ®?ÝÙrÛ*Ç/aIfjajç~¿þ>ˆEùýâÇBôn½LÞ4TKð£¡çôï%ðÏÓ=ðÃü&>’à=W ë`&çáççæ^¾—ôÕê¿«Š>Þ€;^˜š²Ø¦ Rgç •}ü±ˆãûåuè&Âö~u'ÿ¸C»F-mp!Fdeöð–Çͪt¬FwÙöÊšÖ»5ÆŽî~þò›¡\ÿÕÊfô)ûfõ#Ìái‹×aɦkv÷üå² †ûœmÖNÆ#^®€9°ìåWÀÈeöè©s‹~9+»€7¸s ãÐå…6²ή&ëwt<ÕTT_'-ÛoW™¡ÿŽˆl9pX0úð P««»Ø®íýÏ·ºzÝ2Áz¾Éþ‰ \:4ŠƒÂo@¶"ð`aùüŸñll8cž‰užÂHMCî…¹÷´Õk±ÌÚåÐ$R¯C`f°„l‘6òjÎÍ××յܷ¦¦¼¼¶Ö·ÜMÐ"g.®×|«…³:áLÊG‘Bó¡í"Bö¹ådM‡p¨à@Qw¿½fAdøˆìƒ"3‡íž%¡73N Ô yÐÃé}Õà´vµƒõü½ <¥‡ pâ<öúy¸”û_¯¹zµ²ÎïŠ;1*#HKÑ¿‚"¤‘t•@ŠGÔ‰²'ðžç¹²3ùç‰g¸Xlïµ;*ÀS¾ÍÞß-D)è(Jùà~aÔj¡;N ›™à?~‡áSû¿Ní†÷µ­.ŒM0Y;$èQVcñeV6 Œ\9² ŠŠKe•7‚ʼ=T*¹”l’&Ð&ºËÄ—° LÎçèÛëS¹ÓCì–™«–wI§E~¦ž®&1¬Àæµèdˆ¯A §¯Iß]ÏEˆ?"†Z‹ø#Ï q« ¢^X"†0.8¡öÁ皫бmü@+Ù»>‚82 ~p=‡ æ`Þ‡÷½ÁÚ` ß‚ ‚!x6èà…ŠÔÜÀ¹ØÛyÎ]³Æó5ñ”6U¯¾^…nñi·› DÂÇ1ô®åp€1mÏÀ´ÂÌXz(މ˜H;ÀÛ[Ì‚4Á³ƒÐìèg>·[Ä>»mü™ƒ˜ìïtX`—àÉxÆ¢ÍFîUµ…'N“Çœ,H#‹Ñã›öK𲉱6R¬áÂK&¸ºþ¸;× IÝÚðo˜‚ÅÂ'²`x¿q@]hmEìO+ú°þhéV“=¥A5…ùiYùrI^}6í4bÜvܼÎn÷‚„x”¯0aJÒ Ss‰¯:òM“ƒñZkËõá¡éYûþ@©ÓcÇ"=7Õ>Ï­VÄ!møý9Ð Y0z¾¥K3© (›~*)Ì÷0R 0¸’Ã_Ò« ûÂHðzÓü2†lÆr_ÆÁŒ4*ŸÌ…õùi¬BLÓ(ަ¨ÿy:¯ endstream endobj 294 0 obj <> endobj %BeginResource: file (PDF FontFile obj_637) 637 0 obj <>stream xœðýCMTI8$øøø‹vøÙù-‹ ‹ ªø‚÷5÷0÷,FKZCopyright (C) 1997 American Mathematical Society. All Rights ReservedCMTI8Computer Modern12†Cÿ€ÿ$œ‹¬øj¬÷Ÿøsù‘Œ‹Žމ–}ƒ‰ˆƒWFQeD„„ЀЋz–‰’­³™§¶ûüd‚e…6‹z~‹xŠŒ~›ŒÆŽ‹’÷"¢Š¥‰¢‹’™‹ž™‹{‰‹mŒ}Œrއ‹˜‹’“’ÿ$œvÕ÷¯§÷¥§÷;°÷§÷+×÷<ܽÚÙ´°÷TïÃЋó÷=Ë.û+/ûRDl™f·Ü»÷µ¢~­~„ƒ„„‡Ž…‡‰‘~‹|nd(N|„— ÎÝ÷A÷ ¹¿o6û*(Aû Mû08_û&‹z~•‹”™˜‘›Á±‹¬‹§z¯u£|­vµ‹÷ Â÷9Ÿ—}‹†}‰ˆ€‡uFYcV‹k‹b”pj’e“l‹Š‹~‹†Šv ù? û¥•÷tŒû`•¬ Ô  7Ÿ § YiÞæ endstream endobj 97 0 obj <> endobj %BeginResource: file (PDF FontFile obj_638) 638 0 obj <>stream xœ¥Xw\T×¶>ÃxfŽ(ã(sIf°$ŠÝ+ÖH,(RDºX*e†Þ«tdƒ‚ô:ôŽ:T)R *FÁI4Ƙ«Æ’ÄÜë:“Mî{{ ÷ÞÜ÷òÇ}¿÷ãÇlÎÙ{­µ¿ï[ß:jšÅápæîpsð pñÛn¹Ê0ÀAêî¤Z\ÊjqØ÷ÕØ¸xöúÅH@£Y\4kZÉûšc¬Æ\¿Îs(.‡sÐ?~‡·O¨Ÿû1·íu7®Õvð×vðÒôò t”ºû»¹8k{ûyj;†jowððsqiz9­ÖþL*Õž|Ï_ÛÏÅßÅ/ÈÅyµöo/Wwg¯wéê½ð[”ÚS1þ¯uŠ¢6~æe»Ý{‡ÏÎ]~þ{ ƒ‚BCLœM]ö¹šs3w·°ô”ZËl²–éè/W[É]½fíºu)jµÚH-¦Ì¨%Ô~êCê#Ê‚ZJYRV”eM-§l([j;u€ÚA­¢ì¨Ôjê µ‹ZCPk©ÝÔ:jeHéR{©O¨?SÆ” ¥G™R¨`j:5ƒZHͤdÔlÊ‹zšCÍ¥4(5ÚDŠOM#Ç^ç¬á´ªÑjj/¸ŸråÜ×ÓvMk˜6A;У¼i<'Þ ¾ ÿ&³‰`¾Ÿ¾~zÖŒ3Jg¼™i>³oÖ’Y'fo}QÝZýü{Kßóxï›9«æ¸Í;÷èÜ^Ö‚‚Ìy»æB]¡™°_øó|óù¡^}‹àÚΪÉ9[”+¸ðZ¹Q8Aÿ:Û2v;ß4=.ÿXÐÄ«Çñ‘f‰dÝ[Á·K+Öf'hCa'n¥± OíOè9*g— ï¯Ô`ç>^ ¨C6H(0ÃË VýÑ-lUã9^$#àx³hb<æ¸Y4-ƒø:þÊ¢F0­Œ®Š¯B¢ÏÑhcïàеš;è C^£^Ýrô@°ã~qîUzÛ„®p®?s®¸‰ÎÙ²Ù{“‡½Dêèl¼‘w–¬˜QWê¢.ö^'‡-ź²äÊ´'úÂ#TWvŒ ÇŒ?8j¦3°Qû;ì 69,àÁò;FXk±ÛÛ=›Ýz®˜ƒK÷vÔ ]ÑÉñgïr¿ý 9ª}§ À†ð@>Ìsÿ(4œÆ™¼h a/72iÝÊkRÇÀí¡‘4^Éë ÕÂß•YЙ4,äåF(Ûyí$J{^ÀŽÐ/ä]€"Žð²Ãé•ÝüzXGöåÅžeWŸç\¾þÃ}.”°´ð\Zi)ªaΫ6_±Í`£…Âg訸ͳ:¹0ÖîžæR¿Üòpqñ…ðܨŒH$’KmzŽ} œ»7Ÿ\q¬Ú×)9tÖ»ešëjZr²“ã³ÅêðMü ;½ý…œÓñ ›ÙûÂK·{Ò2þpº®Hð>€ÂE¦Õ²¡3}µ7Å |§(ÏøÄ8•µäœ,8Y,é9 +Ûñ^)ðhuå!¢{í«àx+³ÿI*eˆÎïƒrðlqyÄ¿)ÆßؾÂIeÀɪ{Ï8„ãh<Î낸*Æ…¸!vfÕI9§‹D½p¯ó }ù"öãÂÄ€ä`&2;çveàJõàMqJ:^íW¾¿j­Èq™µÑÿÃíšÒ„ÐPäÃxV*F®Ü„÷oˆñ¢<³Û¨)²»J˜zréª0ö¡ÈkΠÕñSÇPgn»³fC^Q ª`êý*=Möà?ŠÝàýè3”„’S’£Îž"Aë*¨Ì–sXœ“2@ˆWªäõI8žþëŒnYod?ÝG·{‡{‡«¿Dß0o-oê;Ùù0·CtFSf]VÏÿu%QÕÞîÆ³ò³HÔÓtäS}σw[g_ä¼ò|ªÉ‰¨“ýšð‡ üü‰0"ršóÏÀ^ú ÏÏRÉŸÔØë…7¦pçeÃìýa¦ÙÜG¤^:žt ÿq|±ž{ÖaÑ08™f†iK3Ó$‘ÙeÄ ä#:vFÖóè/_ÃægâG°¼$wöÖi–ò·TÑ!¹¾é>H´é°Zïif‚v3˜×»÷Ëþúᕌ!cìJ;«Ú²ä*bÉâU2&‹Ì¯ÉK+9U&yǾ¤±>/ì6?‚O1?ìíŠD6îã°ùp¾;y"%‹TzÛT¥¥Ê8îWÔ¶U¥<žÿŠM„‰~šˆÇtVYXp]UU×)[¶f DZ§èJRÙ-±ag·‘¤àèÔ KX ³‡®]BLmy€Ôxç><7^’è.ƒÜﯣÇ̧fc»½^Ö¶b 3=¤GìÕá‹‘‘º+Ãâ.þ~«I€9õ|U˜Z˜–O"¶îf_urZ_²¯¹¬ŽòSá‡h©íîu¦›=tÐbëOƒ5?¿éýî–øò?!˜†¾u~°û‚S­U‘1b`.¢eÒ¥wÚ꛸ fÉ®Gð§×u?ôŒIzï]S|Ž˜ŸomÂïKÔá<–ްCç!²ƒƒW°½\x§äë3Šå¨Š©s«=¸Zo5Ö÷o“¦xÜ<í€[B°(lí!;ÑâêȘ¸HÒ0=Ë‚º/*îõ‹;†‹ïå=ksš sžôù2˜_÷@QI˜ÓLú¤GZÆËáUJÖfàN‚E¥«Ï±Ö¯ëéG¼°ê{ŒõiA£MU_‹–àP jɼTÂÔðIÁaÉZÈéñ6Ðïhi;×^ÖYó\Aq)a|­™‡¿WØ1716ÁïØDbkb{”óªˆ8ó%Ü~³¾ü§1+&¢¢MœQ¤è@…OýùìŠ!RnYŒBbŽ…Ö矬Îl‘üÈ¢ÔŒSe§Ï¨=I”³WpêÙ¿së'qÖ•XújÓÃëEÃL‹_•³“ÔÃ-6-.=V|G¼ò ò{ÈÝrëNNÌ:Ö>ù˜?yÌóÝø÷ÇÔY=¼¨MYÔÆÈe핎Â݉{¤æÖû,L|ôð´ÑŸÖý« &³Msmþû Ñ·Í0_~³n¨£GÑ~¡º?ów{AøCî²WœÃÓ¨ÞmkˆqÔ27)™­ižKçóa.}o·«¤EÁüÌÁAØ,ŒŽ¯À³†}³ÇhÌÿJˆ™Ma;Æ*oÃlú£¿ ·‡6YÀ¼¸Œ\"£ªž>Ø ïÐÀ+”¦ ËØ˜?’OÁX²áÿßï#RþÚëËÃs}h¼é_êñV¨áä„›ã­BP/xô=gÚ*¤^ŽÇOÆf¨ ~|Ëa»Íi÷I‚°°‡¥;§|‹ÒˆË檔IÓ7¼ ø41–«‘Þj¬¿MªùŸçqV–ubí„õpfÏ@Oâ¤Ê%Nª\ù¦rPŸ39U0“ûxB_j߆ÆêªÆFŸj•SY­Lç`®r—u& 11ök:}•ÇŽ)ÓÉåõ«Ü_§úÜ~Æ…WÊmÂÕh“Ù2]OÌ ÌgðÂQ= ŸÕÿ沸ïIð0 ,ÚùÓâØC›MV ]·Dè‡î qrÒ³s$]m—Gÿ»æôΜ‹’‚ûÅ—JZZ¾îj»ªšøúQ›’#ç<„{\v9 GÒŽ|ø°$;féDaxØâú(ôµñ?I-€™JŽ*D4Î^èå°z¯¹ÏÆ…P æ ³,a^âiÛ>ó²?(öò‰”‘5 8¬¶°0=»P,×XX—YD·› 𠼊ð§[I¢iÖ‰Wè#<÷õªíw‘ h°³¿7¥úd5J!Ì­ÿü1ÓŒ0…ÅK?3ô. ©Ì-H?-翬/­Ï!ÞèV»£áú혇Rc%qeirÕPAéƒÇÝK·lÁ”Ô'³ÐWñMTztZ ¹ºï;ø·ÏGägú$Ÿw5ßB7ºoyAç£VÄ¥ƒq^÷)öBüægRÔc5‰ endstream endobj 271 0 obj <> endobj %BeginResource: file (PDF FontFile obj_639) 639 0 obj <>stream xœcd`ab`dddsö Ž´±ÔH3þaú!ËÜÝý}Ùì=<ŒÝ<ÌÝ<,s¿× }·ünÁÿÝT€…‘ÑÍ;*Þ9¿ ²(3=£DAÃYSÁÐÒÒ\Á17µ(391OÁ7±$#57±ÈÉQÎOÎL-©ÔSpÌÉQé(VJ-N-*KM[[PZ’Z¤à›Ÿ’Z”WP”™›ÊÀÀÀhÀÀØÅÀÄÈÈdË÷ŸQÁaË‚…óW}ogþ>ÿG‘hï„ Óº§q¬Ì_œ›Ü˜Uß!÷[ø[Wg{mw—dݪ¦Iûû§Mã+^üÓ~Ûo¡Éì;¹žpïœÅÃÃÀ$%Y< endstream endobj 269 0 obj <> endobj %BeginResource: file (PDF FontFile obj_640) 640 0 obj <>stream xœU‘oLuÇ×ëà6+›ú‚¨×ÓlóOÔÄdɆÄ,¤Ñ– †›•ÈJ¹•ζWÚ+Òµ¥–k{wüºRÚ]ÿÜ,–2Z`°Iân°ø'á…3:£1ξñ…‰Qãýµ9,n/Ü‹'yžO¾Ÿçó`@«†5iºýÈNw úV}RS} ‡joµZëØu8Ôij?ŠŽ>‚íE/í8†½qÌdd]>·Í:ÄQÏŸ§^ii9Lµ9·ÍbvR´™bf®>Ø©Öbc8ßËT›ÝNuïlx¨nÆÃ¸G˜Áÿ’¬Ãåå7E³ƒŒÛ Øå°Ù[èFÐhð0h¨“‚FpëÇþÑØ4åmŒîMۚȮT ¬úØäw8êCGô E^I(ùÏ`¼´´´~cõkH\-Žô0« £&ÃØY…cD÷ öú#*'ó‰HHŠ„EÒÓbd áçåR)=#_2(+«¨~AüpòªñÕ“&ÆIF>ï¿| Z¡›óÛ=}á· DŒ§„t.>9—"³ë…Ík˜›r{}±Qþ¬Aâ]BÐßQ7nšÏ”l6E&¦ÒËÉ"Ñ´mFîÝ€˜5lý$ÝÅ‘X{Q?ŸÈÁ8‘.„»(qdà•ÂÐ×ÌÃìM†-QŽ<¤þÅÛ`žkÞÿe×h/z=ƒüyì«ÖžÓÖQ/™ßÒê­ÖÊ÷åÉKÙ›†Ô|ª’žOàù¬²|mm±¼1mz猗rt†{ßîïƒ;L¶ûLú_±_î,}‹£[5­~Æ‘vzÞ‹þÒÜüì©ÜÂõ®v(¹^b!xŽ0­X?ýýA¯\ëÀ€¡P²<›*ä rY.gî×…Rv~@lX®œzÁ¬Rc÷tNÉ ²òÛ'åHä垆†:ÖkO×±jº5l­þkåAIäAþŒÈÿߥ˜T÷mE]ÐD3}ëÝë¥å™ YXR6a’˜Scãbl‚”ĘO|?p|Ôl…„'RšNd¹Èg÷õÍ"jC8†:+8êTô°#ØMÓ‚(I0Fðéh*ûóOh÷mÏjÿÐ{¬‹f?šUòq²i¤X;ZTçäL¦A=-7^Þs÷!röð‡ºÝ•I€팒€ endstream endobj 90 0 obj <> endobj %BeginResource: file (PDF FontFile obj_641) 641 0 obj <>stream xœUkp×ÞµlyyÄP‚&VBV†@)iCÃcÀdh›Œi ”áѼlÂ[D–lIÆ[ÒjõXÉGÒê¹’L±&`ÒòH•¦)™’´N†–4¥ mÚ„NK!h'S2“Ð{å«Ð^Y†iû§s¥]Ý{u¾sÎw^,S]Ű,[Û´~óS‹.ÿü"¾Å³ªðý* ‘±¦¢XSU0µúð¬ÉïÌÀO|φ'Mgî¦rÌ·˜uL3³“±0&È$˜s„9Åü„ù9sžyù€ù˜âMo²tîµÛÚí _jZаhÅŠå u¬ÆV½¹a½ÞÞnèÐÛéÆÔ°ÙÒj4Ø÷.lxÌdjØT–°5l2Ø Ö=†ûš,Ývƒµa½e§Ájî6÷¬6½ÉÐk´Ù f»Qoê´Z:éYwùa°ëé±Õh{–ªh×[­–žqCÚ¬==7tuëM6c‡Ñ¤·š,meôæ&ƒÍ6~3qd±Ž îÜaºS¶£»µ½Õhm5ZËîÙ͆6ê…Ål3émízsÛ«¾õYƒÝdØeÿl7À0Œ¶ªš1³»vOkk\qŸj¶¦~ÛÌgÜײv#ÃŒŒ“ø5ÆÊ´0[;³` ±a6ÂÊl”±q6Á&Ù«°i6Ãf™{Ë‘¨bz™·™1v û8{­êîªÆªsª‡TNÕoªwWÿ¬æ«5š?ªW«³µÔª½É-㸋uÿRM:Ë$óx}ŽEóq /C jF-ŠCB«ˆIÁ#I¢È“º¶¢A †= u»EÁ#KIQ‡šéE3iv»>ði…”˜J„Ê£–ò"-)w,m:‘TÁ° è*Z;ÐLT_@õh&‹ÞE3Uø)¼Ks¢cÄhì°´µ3?~ìèI¾´ªú?Ï$h½ÐÓ3YþP‚\®Èh_ý3Fªâ´Osû®ô#õm™: ‘üØæ;ŠïQáy¤W# ²NI&•0Dü¹6ö¨¤HŠ´‚( ADT«¡ žºÁþõ† m¡d؆Íf›Íl¶Œ ðl¼k)©¦_«ÐI|Vààðá ÿVކdbœâ×üÅO6y²¶‚¾.‹ÃÑÙ¹Nâ¼Þ·;©ÝKK{`>Gž®…`|u×K¿ò<\:JÊînet×ËâÉ€a8Á¡kᜠ¦œo­}n§‚&‡·á(W1zÂa4¥ BKŠzM†zz ×Áß|¤Ö½¹ eËÆæÑõ ^6Pÿþ¹äòÂ.[<§áÊÒO{éýOnyØžÇÆü-/jà 8þÄ©í#k“ÏçvƒPñà=ÿ©mɶˆAhç5°ž »3kÞìú¡@&aX8²ºš ÛfÝ»×nû¦ä$ðqB R×ß?s!Ì#ÊÏß`ÿsG³Ù#GÎÉ\<JUÜßY–‡ëÔê/G˜î<~¸€l9ðk*üJq®&š†(„(ÓI—Sr»%~±Õ×ÕËQ—?H:*y\­K‡äOçE1 Ú ÈIYáÈ"¼Hƒ«É,‚k** € 募)¨°T\ ‘d3_ºë³ÜÂjR ø³=¤PRßq—zD–G&rµµ€¶8‡¢Ýƒ´M&*¢£k}?¨#Ãw Q£¥h.ªC+ÑJBßd©Žù\VÏã{iŒ»~ªBY´Ws²ëdç©®´xÀ.“MïOH)G\GæGsÎ'åt ök÷;ÒNJ¹GàÉŒ…Y´4”8dm8''ÔfÉ2ãª3 !/hW__Ú—”thöj2ûÛ¢äòAŸ¶/ëÊдNТŸqÍAküµþ¬+ G d¹º±þ ytñ9¶øZ•nÙÝNLâépLóƒÇ¿ÿ»ë§Ó±pâ\Üà¿{xã©W¥d0*çõDÏßÙ¢û4¥îßK>ƒŠ»0Oä*E¿½«IÊ©(¤!#Êîhé ÊÖ;ã4ÈÀ• Ù d|:|„J‡HX”D œZ!)*rb _ -·šF¿®TP;znÑ[i.ÚQT7ÊŽR è²&ïWDw Ï=Àûç65ÖÁŽ“½µöõg†Z€{`ýì¯Øâž¸ÉEtQÄ]|á58/¶ý~Í››~Ü{¸yãï¸jðùröþ¡\wgTáw4RÊŸr‚^¿ÏAÂ¥_Ôû\´„\ÙÒx"ü½8\x¹JG£‚,f@[î\ûÒÿ–F|U“’2d¸rSÁ'ð¥×È Û?θRþ¤„_%ƒõŠ/ r¥¦½WLW:ˆB58Qêù_Ä|Þ~ü~CKÓ–×åõ÷yyâ*>êW¤¤³ÒSŒÑ —ÎÒ8¹©IˆGcãébO—…•Œy]Ôì§p÷éöÓöœ¸GÜjonw¹ƒÐ\©¤î¿][—Õ,éÝBir)„ÐæÃ«¡Å/§#Q:Ð á ²ôåE=ý0á`HŠøÁœ(€+8´åO‹u¥Ë·JŠfØXÿš<¾Bm`h9eâÑ(öDiZ £륰Gö—e½N¦•W‡ƒäh‰~^_-ňóÅ¿ WþOQªž˜ Åkv´P|¥ k*ç,Ù†ôÄG‚tì¶’4IÓÜŠ‚ȶ"=Êò¥ ¥¯kˆ¬A‘yÐ:´Y ­!‰›xÈ:²XtuÄ”›F›…Kªâ”â#4d!xZ}‡ÛçsùøÒã7Ÿk ’ÖsfS±X:ÆÓiâ½r{šT!« ],¶Ünµ4ÞNI$ž¬*íð»ÀZÔ…šJÛ룮ˆ{b̆ êOëÈ*¼£æs˜£eÈçPÿ$Œÿ4áíõþt å¨Tñ8¢Qwè)×FFN*2_×}°øƒj2=Z[˜|i ?¹zynê¤ÂàÔ© óoX-Y+ endstream endobj 262 0 obj <> endobj %BeginResource: file (PDF FontFile obj_642) 642 0 obj <>stream xœ­Y xSeÖ¾!4\Q–@̽ ˆ ‚,Ê¢¢b­ì¶¬¥€¥+mhIÓ5mÓfiöœ›=Mº·¡{ºÐÒ…–²Še¤ Š *ÈŒŽ8óÏÌ/þó¥sûÿþ_Ú2.Ã<ÎÌ“§ÏÓ4½÷~çœ÷¼ï{N8ÄèQ‡Ã´iۺŋü¿ÎõÍàøfŽòý†›ÊFýM6ã¹0~´w&%ž„ŽOD‘ E\练’ÅÙ©Âø„ôYó‚æÏZ¼råòY«Ä¥ c¢D³6E¥'ĈJÇo’fmMŽÆ¥g/œµ:)iÖÿi³¶Ä¥Å¥fÆÅ?;(ù€8#=.u֦䨏TA W‹^K§§¾‘–¾6c]¦$*+zcv̦œØ7ãBö…Æ'·nKÜž´ãÀÊE‹—,%ˆÇˆâq"”˜Cl&¶s‰­Ä“Ä6b;1ŸØAÜ1aÚ„?=RÿhäÄi応”3yÜäú)QS~à_êž& œhL™>vºsú3¤3_žùÕœ¸³Ä„Fý~;^´Ëë[[Á9;ð0mCüÈW"u …јFRÏ仪ëÍPCy¡QߤµÊ]*P1´†‰7œV·³ô`gugU'‰²x.ö…Išd’{ëâ{¿iFó­*PËÀ«£TbñüÍ@f‹‹ª jUtÅ©4úÈÏ·yv­Ü’%£ÔÇ„ ‘’té¬Y(HeX Æc¥Ê®–óY"…TŸ¥“Ò¯²§ £ô…#·Â]j/·SøÌ'¿ô'ô=:ìä»õ»¤ßN›üïä;Ù¡ HôïfÁš¤e/?Áòh6‡óùhBí‡_ÂÇäµÐ‹,‡b/ò¤ œ:”{k!G]ÍÎl˜ü¡J£Z3cèc'”Ðè z Acî~±¶'ÈI³³ØOù주$0ÛmæÆF_EÍèUÞ7¶çSžzñqv=áÎ3GÒŠF]Eî«\Ÿ yù߆^yŽ}”å³±sç¼»é ô(âã{?I±6¶‚»Ï{íx â6ž¦[Ï÷6òXÝÞÐÈŒ9‰!´hÛΈ]@âØ/2D†w`—ƒžºÍ81°ŠÏXXH“Ñ¡4hA‘Om\yesI8Øh6‘Í`å슿ÎA C´¿·@ ZTzz'»Š¸aË—žA]¨F‹o Qtÿïßó1ÿsèéçR´‰ §ýõq™™R 5»Ã‹ž†LÈeîWì¾*I¥5’ùŒj«Ö^‹‘\G7B³Ó†‘ìVBÞN°Øì5–úškÏ©Ž> |žqhšÿ×c!»"ã…"ZÞáN}xh@ªN¦Ï¦óÍ>}Èî‚-‰Qbvœh-O Þ äfå-‡™1›ô_äGFD?×—ï{žïÿL¤SeÒ+â’¥”¼>¥e7,—}ˆ}†»¬'øzGkMm-YÅ€ä%E¤Q·ÁHÊ0,òmz{c‹šè&Üp?Ñn²bHgåÍ·¹Gu¶á¸-뤫Ï÷ï4–%H Dz£Î ñ×µvˆ$ÎyQS3çÂÀ+ÜWœÏ˜ÌN`H—ô˜)Òó©Í,•°ž]Š9á'¼‚ênóúíR±Ú˜«Ñ`0h@OÊ Àæ2›Ê,ÔÛH<¯À- ô™*ëõ¬Œ€|wMv¦ ×c"Õ^dú4Ú¨5æûïâKc)3QQ°¹F™ Œçå(![f‡Š>PåA­Ë¥ÙéƒM*!îÌ4÷šÇ—Æ«†±ã95 „¢]ù´#gþM.r¡\†nÄÿ¬Py }"hI™3«¦Ì[tøäz×þ7âÃ3¤”âTlùþ‘5ìõ“Ÿ5˜>†zQ?ÃK¹è ú„ÿï’3Wœ£“âë j£n$`Œ÷rëPÚ,Œ¬dF}¶–Ê~]šŠ[fï"rßKÛXÞ_=Io¤é³ôé´Qpߌí~€Œ¹ÀÜÞi†vºŽê»tº1®òAJ+y¯£Ð&K±Ÿ\ ocryçZØ#zá4é®oªo ?Q§ƒ’TØrªJkÜ]=чױc£Ÿ{ùR^†:¢ìVÂv2Qü✌ÍÖRê„:q”Ë 3Ó“s"Þì‹=Õ†&ôÜ^Uí¤’mñè"«*ûoÔ¶*c]þþß8$/ ªÀÍ{Ž‹ }sø·x¥®‘“¾ÈkEó,E`ÂI«Ì±*S•™XbÙ¥Ëx9÷PqƒĶu:)ä ›bNþåĈŒÈÁ˜­¢²wǼºH1T—Ø¡Ä^Gÿ]C/xQ³ÏËú||G£Ãñ.•N(s©Mê¸h=ÄÒ1mŽR#û%½¿ÉØZÞ9¤¾Nð€×ùeáUjë0Ãaº:ô˜¥í~¹Uƒd38œþÑ—Quªå­c+ô:ìC¥è½§Ïž/>ÃõøfðM6ŒA3éRK¨E*õÛ­ÍC¾L•,:°Ȉü#M盾ªî§•Ö"('ï÷F.L`çi†ÛÄTd¡ÞÚoû€t¹ô)iJq^,œ²ÂÈçúD§O574TQeÛ»4åÐ •ÕÅÞ²6w†ÆPQŒÆ •·5k£È¨-ºWŽÒ„‹2ÀñrÞñ…r}Ó|WÄæ¼‚+R0Dˆº˜(=DÓÑiŽWwÿÍõ8³ÜM4;s°Cµ?_µ™ù­°ì~üwÐÐ¥oÇòóª $›ÀîbÀæÏ/r$=‹ÎAcÇõ)}ãù-r¯(=5=]fWÛÔTUŠ9”ä=¬…³]q¼©¯ñví5ÊZb+~ÀÔ$-“„ÀrÑEÑYôRúß?Šï•fñùÂ3·Î£ üôGÑK|u²1òHEÒŠÁðaáéš½ŸSörëƒ>-œ ) ¡CX“֘ܭ/…Fh)l8Q¼¯]|ÎAgGÃû ý‡ÑB8EÞ/TˆI|,':#,1ú- Ã¥N¦Êu„îD/Ù<í`ø¡#R‹1t~fMüZ(ñã÷+éï×DµPk¤²ºK®…‡ŽTk§]»Z3["¡•|Uâ¦î'‚ä‘ê°(ƒQkÐøÔï'´’OPÊ"çÔMtü&×'ò=ÅQÂ>lï ‰ÍnѶý»²”Tƹ]ŽT ŸÜÎNKÊ,0%VºöË“‡1lêËÓcÒä»ò÷ÑŠh£Nñ–t}æ‹! ‡4È)jp8«¡˜¬É´ÉRS3÷Çv¦÷ô6µ5”R[Ž)j€üîš^1’TK‹ŸR"vŸ¬ru9šiWgñGSÑÉÚ·‚ª¡$¼‡I´¯“ƒÆ¼ƒÄ—¹èÌÀâ¿; Y¥WzjžJnT!K (€¢^“Z©×ËÀHͤze4Ä –w®ùFcÑSèI¿'Šf& )ýà~êþÊëGœ-õˆGÛ«ÀT\QßÞÖÜv?߃š¶|¤-/øÎúuá.ßÙb+ø È‚ažV€.bÞÂeŽyÊ’òWy,å¶ÒPb 06&ØMèåF}–šJ\É’ì"¿ŸøÑ—àÊ~e"بâS7z<¾9 Ϥ?Ýa^›6ùÐ@ ?Ž]¹zo8»óÚ¬ v íµºk¡„¬”º²å±š­a·ï~ýÝŸª©ÿòQŒÍ„iPðS<0ù"uLH茗{¼U……ÔP)QÛ§Ýþ=ê×·Æ÷0?\ÑØrH]ÒƒµUž¶c‘­îÙøyg×ýMùâÏÅV•K¥3•*jõ‚%º ·§v÷ªý¾¦—>téxK7¸ ÛPëÃUxGêóÞß^âþmâÏ… n94;…—«Èf¿¼¸Õ×gð0|¬à~cË”AwÞÖ8y„A R³ýî´¡Ù ^ìÀ[†8Ö·š‘Ó[L†(ưµYJÀWÈðÎ~gÊu1 Áj·¹|c8øÏììÁw!]­‡ñ„I·aéj½¿t ¹’‹.r{\1ôærÑêäŸíëýœ~–Ðà–’k¨ý[dZ)dƒ² «F^’sóÌêÈ’|»ÁáfLn+íðÔW·B”©<ʦ\>qnN¾B*eW°Ë·nÛ½;¥[[Æd·PE•µÝmà‡¢,µDRœ…þãi4µª`š2¾[ Ú%Î…r‹´ ­Ñ®«#ˆCì'ÅÓ¿¢}7³²\¯¸6 Wçß Ëb[Zõ+g†!S4Ôè~G”îûŒ_rñŒ¹ž!Ín¦Ô¡³æ'í×C"BsZÜæ §ÑIŸ48$X4ò jƒŠ5¸! ñ•jJŒ ö©ìÄ¿#Ì~TF0è•x„¬ÍÛ¶OöÖ¯BßçD‰ƒw¬¹Œ¡Ø3Öòa¶Dbz÷ï Ò¶q‘ Iù pÙÜ[þi#\;Ù³ïð†ÇØÇç²Á‹{—}{ÿþZ¯xÿp[A·½–¶yø]hÅwæ ÛŠ…³Ù•°ßï¥þÏKdÔ ¬¨æ y_ùânqê}¡|´â‰?²“Ø(6†U²¹ìÓwf¡™hÚ‡2†|rp#ÑÖÏѸž"4ë*š@Ÿºóõ·üäZ;}i<+رˆ^Ïr—„¾êgZÎ/f7Où _–-ø¤ÒÃI½‰.àɦ›âÏy¥#í¼ŠWô¡¹¬øª£Õuê®e¥¡Pz@›—2£LYR]]ÑÒ}0z~*;U¨¦2ÙQëüU` Óx¯ Ž•oRFk2*¡,,”eV7X‹ª ‚ôdHSS% ]™­w;оCC’ái²­½ëå Lý-]FWøèYš„fü7{sÍE–C³§þÉä×¹]L%Ý÷6/_ò®žHÙ É·—Nˆ Ï Á&bÏ?GyÜßñø&x žI§nŠû§Mþ}}ŠŸ¹\®ÉL böÄ@.È Ä® ‡»JÉÂüò”줼ؘÖì›ßôÞGåâøÖ[бY± òt•HGMþ¶>O\9ƒÍŽaç±³—]sýDW‡ÛM_BEüv½*ñÍUÛ@°Ýð‘«·­Òc9ç\®¢Ùÿ·†Ö`¿FÀÙyƒ·<, gnyea©ËLYŠÑT{Ýð*Íyˆ1•5V4v½{õ?±J[›p ‰ÆßðÁŸMBSÎ};êói“}è&zœÿ“[‰ÄOã[©ò˜ÚšÂ¦ÂVÚóN%~ÔãèÊÉ·ãª÷-²óµ?ꤳ©æ›!Ô¦§)Dê,Z‘¤©Òeûåø•§ÃÈ$c«¢OÞiBOY¨Éßk}éüj‰#/S,IN­PUÔ•×SëŠïÀ¢:ÚÝöösúù¶Jk4*ò©ˆ­±—_g$˜za9øgL˜gGŸ˜¶é=šbݱ¼À“¹}i¶+Ï•ñä¢UO.yõÕCwZkÍ. LŒ È•µÅà5ŒÃC¼Oþ«ÎfgLÊå®i,(lÝ~1÷$ÿ\4MªWw¤4Ò©^¹ù™º,k’Skç4BùùÇ¿»u§nÍê£Z—Aó~ºýò/ßÀëc[9(h`×w O<ö‡ÉÁ8LµP ä݃y›ä¥ ¥ 0`Ë ó'Õd.3S h c+F®N¦ x¬ðšìPvM ffÿ?+Ü`¶XÀl¦L&†)¨9Šf×U">ͼƒ S« ùØ-³Ó›óò•KqOÔn°ž8e†ôI8­?1´5¨p)!—ÎåI!ɤ‡d³ÖE˜•q·Žðoÿg…Ãh?zñì­ í ö:§‰:ö¶j/fÂf¨A§ÏíÆ2t4µõˆ§©ÜEyÚŠÎãöGõ“íÌZƒ'W±á`ÅA{c¥­•À@!ô×nt,ª¬¬õž<{¸ç8”ƒ]Á£ÔÚP Mžº²¶šì我Q1BjË:©4!gD 1ܦy9(âú}ÕðVÃ$¬†ûÿ©.a}‰,ö¢@†mkþÚcm´zè?ûæþºÁÓƒSU‰J;þæš;h2ÝT4ªCˆøÁ„[v€ßɹsîWæ}â ~­r;íëm«¨­.¤J[Š.ޤU«­žR§ægE%ƒàG[1’šÊÙ85qOr2|ýüöË-®V³ƒq&“Á©Hë!•:€³#Â1a+à0Ò%Æ*5¶ž2…D§f;%;}• §˜‚¢áQB¿/Fq”Ìû‡³*ÇÇ>nÊO5ÑçMYŒ¶£Œ«Ìo~÷LŸÿð}Ã10¹+ëwõ]²væŠÕ"C>–ÛÂø =7|à.ú×™õææŠ=Áá{÷ TWÂÊ# ví¾õŸøÂÂ/0u­7þ€‡ ìFV^C–K\ßFt–Ÿ2;5dïÖÌ”Ýa› „vY}¯ÅÜŽgñ"UYŠ0[¿£G|á7?»|”ú3š]„‚áY èiv*;ŒyÕìh4æÜ‘ö£^Š \Ï>(jk@3êŽÓnOWÿû@ž(Ù‰ÝÎoF´.Ã3ˆÍר‹èÒ®ï¤OÍo×¢©,?èÅ=,/„Úµ0’ ‚%d°4šþÞôÄ%ªã›6´>#Ù“ƒj~bdÅ'Ÿ_G½-×èÖë§=Í@v:°au0{(ò:cOøÎ0±Õ˜-“½ˆSÁñE ðïAÝ¡±h4Fc®œzyN°Z¤×úážCb"³³µ¥Ø‡EªD•rTÇÍcW·ºè#У?2²R‚”VñdÃȘ ³†Ág39Ëȳ3®ÚýÃ:Œc]Ù€Æ{ÐãïsÑ3òùA‡· -¼ýõ@|Yuz;o%±^b‹ìþ´o+Ëo‘i´Z ¦eÆ@ÙäÈIѾÙoʕֺK×Q(šÐqT¼‚}â¹åóB©qTZTXðrE0‡Ðá6™°pÔ•j€F¨“TçÔd{3Ú±þŒéA¯¹îítt^tìÚµ¸ò±©%ÞëLf"ƒñ^ž»7Ð ïÌÕ8ˆÝ ·=W¯y0o¼ƒ¾ãç`|+PJ×ñÊû /dçÏ ¡“…o¥F@8„7>ìÒ¶B1Y¢(IßiÉ^Ór ËߤïÑørݯ´Pw[ú¾†È[ë­bÇÍ}lYB¹¨µµ§åx¹Â+÷Ç®g f Åí2È%…‰É"‰¦¼ìÓ¯ïü±µ7;HªdCÙ•ÔŒ¥W> endobj %BeginResource: file (PDF FontFile obj_643) 643 0 obj <>stream xœ­Wy\S×¶>!@Ž*é)P뉽µV­µâPµ­U¤U(*¢(³€ Ìó a$YI˜gÈÀl@FQA©UZ-¯T­Ãuhink­Zé ÝÞÛw"µýÝ_ß»ÿ¼÷O’“³ö^{¯õ­o}‹G™šP<ÏÜÞq›í"ã¯9†<ÃË&†™| ª±± 3˜Ì‡É¦­/ —XbõtÜ>N£ø<ÞºM»íÃÂ"÷FÏšk?o–íÊ•ËgÙ…øGîóõ åèèâÍ=ÏróÝç°p–]pð¬mÆQ³¶ùGùGÆúû=smí9Ë1ÌÏ?2”¢¨Ù¡®aá‘Q±q>ñþûB–½ýÊ;³ç¬J»zÞ·7<¼Ù.^²”¢œ¨•Ôj+åLm§æQ;)Wj-µ‹ZG9P©¨)+Ê„šA™QŠ¥Ò¨ Ô,j"õ õ5™zŸ²£¦S–”zb¨×¸8pFE¼Ý¼>“u&‡ø~¦<Ó8³EfŸšËÍ\ ÒO&ÔL\81jbˤ Ék&K&Ÿžòê”Z Êâ’NýpêÞ©mÓÞ˜=í»éiÓ¯ÿÆst¡,~3yCEÞ`Ö£³D“³›‡ÑØJØ‚&xŸ!Z§Ø`A«¢OÙõÐ/;(§õ1áfÁÏçO;[â²%)ÿ‹åNˆù0úà¶”ªýš­°ܽÃiáÅ'òŠØ,XðeaÖn‘ÅXèÇxz^íØ6¾aŽáEg¢‡®ù`ó-…^à'w—E‚/¸¯ŠtÉu1 é2Y–˜˜“UÖ„A™*»rm TWuXÁ¹”®GÅ^%¬| ê,un&zk²‚d§Ä…xÌ›`A›¢[Ùíð1´I¹eŠÄ¨†"UnA þ ÷Zãb’©ÌQå€ÔÒb½åÜZU¡º¡GÞ-£õñÜUcóbõ´…A*®3,Òñoâ›|Cîgð…×GÉ2}>á‘é„ùù œ€SþˆB–DwƼ´á=‘GàShƒN¨=ÒÐÓ«í‚#p8¦Þ»Þ¶r——¯O¯Ð]@§ìÐãÁ¦;²Îrt+oZ ¯£=ÞfšúŽ7õ}ñÓ%ÄŒLùp¹¯¿æP¸(E ÐÐÛMó’º].“~þÎ@LWùxÅĉ„÷‡d¶1!ç $^¢§Ï³zPѯ¬‡蓵þ™ÿ÷¿ñrôÀgthtÄJx×\ep¡àA÷­ËJ+Y©<. "è0m²®º®´¹9¸É{m€ƒw +¼‚&"úâ­SÑ«l„.è…..±;YI›ˆó& Ä:ÃÛjË–šèc˜Ä}X o¡î`t97’Àžv ô]µ<à“oâYi™<7èTÈJkA"d•ä)j5«T‚²Z}Äç¨\ËÅ@Ðó_N†H+íoö+ô)¤…WœKÊN¿ÔZhMòlƒ•¬"£”@—AžZôPPâl¤¥²ÒœôŒ©ãHšXø;8V†5Ĉš#%RègxÆÏôxPÏ×oaÿ-¾aÌðˆiS–\akõæR;.¯þ°9@× ®(Å"’Jú1UðmžÖ dâ÷Ù¨`óVÕW;à´rмo V`?©øÏ6„¦Rb­á%=OmHá–âSTSuxÈX7ѲPy4D‡2QÁA½]^ ñ!ËÉ¿F ­‰)6Kʸ˜(mê;¡šÕ Bäβh_EWh‚³+) ÆÙ­óS”ÙeP¹E¹ÅFàž_ñ»×ê1;¾á7¼ÅTŸÐ—µ½Æp^c <•ñF¯mr]÷$Yvê"Rd=›sJåJȳiè ç4Tî*‹‚wÚ•²âÔ|±ÎJ˜$Æ‘ËL®oƒO/ÐÚO˯‹NE: ¶FJÄûsŽæ±è.à8¢3 Ý¯sW¥Ð+×¹oÑ$Ö7VkêK³[<¢†Öã%Í@ÿÄo±h¯@xBì*ýPº9d;ÈàE¿s?òìPOW¯šÍÂÌë‚öû_z2hqùêâLev†L’)ζ…tؾ¢ÛCŽÁ´Ñ -“ó¾®;ôãb2ÃOÄ%ì©Ám§¿®A¨±l컄k/µö[ ÁH\Ã,…ŸjÍu¢ÂÒšÆ. ¿…×£ÃåAÉ‘¢Ì´è0_ ç2a‡¤j ï _iOj¬µlË«æ"—*¹8'[ itbYZe±º ¦*­Ù/ÎK²Ç‡õiñQŽpݺ÷½tþu±¢Ôä„ýH Ç ¸Ì_ç”ä ¾´ýƒíhî»ÚšÒçÚÈîhÜ q­Ó²A¹±zh†\¨©ÒÐ($¿1sÖõìéh?¢1ASXæòÁ®yFzdÆ¡ÐSF-/~8d%¼‡>bÈ,#Ç~^$á8V÷œc›ÊZh…ÖñN½!'¯S$|˜kè`š#µaÁ1ááº}c¶™CßÎå/2á™RhýÿR ÿWM±¼œýS¾µ+ñüC_\úw}aÆ4¢É¸Y‡V7-OQ~{#<¸ãm;™xF%WÉK€n©ª«­M¬ÛŸ˜å±lx>š"ý莟Öð·š›wºê,»o£ßÝ·­„Oѯ3µÌÇim}µÝ’}:6Ù<ƒk“u•Š:½Ž­ /„!"á¯Dƒô÷ÿý?¸uÂÅ?þú½®nq,N"—˜Í2(©Hè…kPM_mþéve8êÙê½à »9™µ+1 ÄÉ#;Ú¨7žAkôºÖ¬áŒòqûØ›LKxuDDxÂ~¶ó©›"Y‘Y 6Å ÊSTÑdÓUZÕÔT[ÛÄ>ßÃFÇ·0XüÕˆ\5ýëBƒÔY[§Gú.ªî>:Р±<ÕçzwD?r×µÏJøO-Vã9'GÌç:–ƒ›Ã{ét0ö1¤O°$Ͻ/õ³\y¡<赺¡1¶:Râ+Û½øä[8=Sä©ï<)ºxÃMϾŒ"ß#En¥´ð_'±FðMÎ1¯ ç…LÁɈˆ¸„°àºd­ê°âøý ‰i¾èh°‡€ðÓla¬kw«Nìð;˜Ù—Jß5%SësF@ƒ½Ÿ]+ä‚ÇŸ0HÅè 3ôX©ãußì8‹3êp°‘?¶§0Ò÷6í÷ØÙÔÑs²ë‹ž¿wi[o‰x¯ÌE.1,'➺øÈôì,¹T´}¾çzï©„‡3½P00øÅe¢{’n~àh·ýŸ|ûÖÅl\Ìï Oˆpp¡—ÞØüà›3‡[ÚÙa§3IÇà2œýD9B?õÇCLø5éiÐÓ_w5·«² ï,Š`½ßetî!‡Õam;Û÷nÚæ˜ôŠèû×¶ ô‹Æ/…6]¸°‹wjìMþ˜=^c*Ô ÑÄCŠèéæ)ñ§† ‘á{²ƒ)“,zúóäñ7åFˆ.ÜãÝľaöØ"FîïîYQœÈ†W&$r²'>ÆÕ¹2ÙZÑÑ{¤¦.9½ŠmHªÎªâ´ŒZ×wÊˬï(¢Òþê¬á=8ÍǯI*P&V‘éh„[ß\Ûkq*N/3Š]£’¤Û®'Â-¬+1I#|Ž:V•)³A2udc1Ðù¹ª#Ÿ^Yñ ô8|ç å©»ÚÑu÷9•M0 •  åýó­õ mtÓ§}¯y„r\¿q_MJ±»õVòtE7G#æ-øˆöäCRZEÕ¬ðŸ]dÙÿX/Þ“¸ëu£Š«bœ²Íœpê²Ï9`Jrr$R©D?Îý„,âdõ^ò™F,SÓ8‚’Ò’ÜœüâÛ_ ð Û‡&¥È‡¯¥X‡txNsÖøÍ;U‡Ô0–#UÇ7|cð`jäŠh6Ñ< ä IÇÙå~@Ï^°XËï>8ÖÔ}@T¼³?¾èïÊÿ‚©d5Úed™O–7²Yò>º÷Ÿ+¨8'ªÏÇÉ­PIgA›Ám*ƒléÛ¾ £Þä´óFò"ÚâztÆWñ5\ÁÍ}«‰ ‘¼•e»!ú*DëzH€œ”X¯Í®’8 íFü3#›%9·‰ÊâA ¿óQuýº ‹‡»øXHTL×ü_Üï"3ÿ•,¿ö -í Ï`ÖÅ7¼‰‰ 6›—?Ç.iÆórPÇÅA| KZH‹ å9b‘{2OxÔåì¿»›Ä¹[2–Á™¾÷ÿµ`¾/Î470°£h§á]Ð9Ï™©OlˆKI—HX¹L.—-ƒòÜæ‚ g?•þŽÐìÜlñŠÕd¢S­çáÖê†z#ÆèƬu¼Î›XÈ •Þx‘kÙ׿òøae¥8ÁÚˆ= ƒÖe¯‚waM®í¡Õ‡ß¹wà²öÈ÷ÍÃyWáï4 ?ØR—ðƒxîÂ8C…jœt©¨Z`(A=·ØVÃfnÜX/Þ”¼`[ˆ'¥/×ùÛõG8†ÅÇÞ±˜ZPF³Ž›–@Qj¸­úëé§ÜÈ!M³eƒŒ#Ç·ÜôÖß>9‚¶Ò’vc¹Ã|ò䡞wâ zÝás}w-iž’啞œ•¹8¥DÌGã"dà'4·½F,ˆ™Ý[‹O€ªªµôP}B}`¦ äR¶æóöÓ@ß9üÎÊww½·ÝQD¶“ýb1¬(ƒÀüY=4ήÁ‰?ãš(š¾ýß½»ú1WÂÆ'̆Ó_r‘¹±äÔsV;­Þ¯‹oÒktM'Ü!™Õ*kúÐÇ1¶i²­^¢·}ÒHy¦> endobj %BeginResource: file (PDF FontFile obj_644) 644 0 obj <>stream xœcd`ab`ddduö ²1T~H3þaú!ËÜÝý£ð§.k7s7˺ŒBß¿ëñ×``fdtóŠtÎ/¨,ÊLÏ(QÐpÖT0´´4WpÌM-ÊLNÌSðM,ÉHÍM,rr‚ó“3SK*õsr‚@:Š‚R‹S‹ÊRS@ö:çç”–¤)øæ§¤å1000101ƒlb>ñŸ1I‹ï?“°C÷š«×lŸÏø½þó÷s?E—uöÈ%%‡ëtsd±/ë>Ø}tÇŸ©ìiõ:rYl[úvïÂGÝ[:8Öd°ëtLß 5ëî÷÷_Þ®a<ðå{É+æïë¾'ˆÎžµuÍì™';ÔýŒã;·úß‚¿yl Œ¢6µÌ\°jÖÆý‘Ýõr+®œ[²§›ãÅnse'ûß\¿yå ý«oèîì.’ü!϶â»;k[Gysd}Ek³}wu7Ço76¾²?íü^:ë{þT¶ß‰ÓØ×p]ç–ãb1ŸÏù|ÏõÙ<¼ /âŸt endstream endobj 86 0 obj <> endobj %BeginResource: file (PDF FontFile obj_645) 645 0 obj <>stream xœXXTW·½ãp‹ uÆ ‚f{£Ñˆ±+ˆ¡)(Å‚tAšˆ RÔƒAŠ4Q)Š€¢XcŒF4 ±åI4mßÉ“wî€ùM^Þ÷½o`¾ápæÞ½×Y{íµ¯„ÒéGI$’¡K|Ü‚C=ƒ¯1¶ pS‰k„‘aT?a”t>Vý>S½ƒFƒ¤hNÞ(ÅÏ2Áj Ë¡T?‰ÄÅIàÖˆ`_oŸP£sçš¹…¹©ŒÂT[Ã6ûû†øxz…ûmŽ0Zììé`d©r71Zäïo¤ý^ˆQ°gˆgð6O£%*/_OU¨¯›¿É¿Ð"EQ‹Të:-Ùê¼4hYðò¡a–ÛV†»Ymß¼*ÂýãHkO/[o{ßÕ[Öø9ø;¬-œ•>ûƒÑsæ^øpܼù'-˜¼Ðej¿iÒõÆ&Ó7™Î0›ù>E¡l¨¹ÔXÊ–úGÙQó¨ñ”=5ZMM¤ÖP“(j2åHM¡ÖRS©uÔbjåD-¡Œ)gj)eB¹P˨éÔrÊ”ZAÍ ,(Kj&µ’zŸ²¢fQ«¨ÙÔÇÔ”55‡ÚDéQá”>5‚êGP†T5’¢©Q”‚â¨þ”5€M™Sƒ¨j0¥¢>¢t©@j5”ZD £d”œNñ”#95J‡\î”d°ääA¿‰ýP¿?¥Ë¤Y:R7Fz0GÿÉÌgŠÂz²•ì\(w§¿Iÿ„þÍd6 hH Ø:hì 4èËÁ u¥ºžº¿ Y4äüPÅÐCë‡ [:,F6\æ&;.ûCî*o— Ãç oæÇðI|‹ÞV½f½Çú¼¾~µþ#¾ ”Ç ®0ô2Œ4ÜoXaxÍðÏ‘+FF޼7ÊiT2”éªå¨¼à|Énõ)T©çñxçÆ.†Þ ëjØ•)»²îÀjb™ÏñêøèÉzx k“‰ãÕ í4†ÿ —Òx£+Ü@•‚¼,ø¦ìUøvéËÏ–êA`%ã’™CÃS¶®°*ã$âîX¬ÄGØÈ(—DÚ›l`´*Ø].¼¿i]¨—…¢Í“•߯œ7íÿAv:$ÒºÂKT#<9#‰þf¨gòîìÍ`‰+ñz|Êr' Ê·†µHM8f £qx|´EúpžÝàAïRçWä]½Xê–îԦб \ðkû°QÑ+Ä$2 .)QY4„±à;÷"Ó›Íq>6†‡2.i‘QŠi·Hê~ô.J…GE<˜­fð4** N•ˆ ðìI ö°â%P0¹º2.²Jy8"Û”¾&Ìâ"Ë [Äa¬$/¬s¿Y+‚Ú£o¢[èvæÍ"NWhªJXqV\vMÖÓžêË¿*Â*b*+-Cæ±U e{Š f“¾MŽÙhnîçêîî¨ SÒKMg/aä_ ÄóðŒ=]Xžy qO./Ç,²Â|rH`JÆ-Jç„;M²³BœÆ¿ þlÕ—wÞ"háémlNOÞaòyfˆæ!½YˆKVÞéÀDà±;iÜÆC…Nº– c‰„û BšŸ_IAd FîÌ?8ƒØÑýŒO›¿¾Z÷Á@¼ð†w)æ¬ç2`õ̯ŎfS±•Òœ”Ò --ÂXƒoao—TØ(òŽ.©nÉ…FãñûxÌ—¦Ð¿ölæÑf%vd##W%‘rÚYÉ:ˆÈ¥…+,:´ÿèþjî}/^ÓŸuߊ8c»Û0ônÞÿ© 8)¾”`p5@y¤6ˆ¬·mXËDNˆŽ¢q”Ã&kÇ¡%t#luev-ŽŽ¦ñH…(²JËk²f““ž  ùGÚº‚ŒHÂÐSþŸIЗß&zPÉ,Óf5[ÓTQ\Ž PîîÃQÜÉÇ̶ôíÂ'¯ÚâÐî½Þ*o?o®ç­È«´bå(^øQ­ £ÅݶñH›´\Rj˜¥)‘„Óé0‡%á.&áý7ÜcïÈžF·©&Ô¹ñ÷XÇÅÕ 3ëdµMî_ÂÔVçôåkà¥àËûf{ÜHPgV­iQï÷ÈS)/¹P±ÖÐÕÛ×N˜–¨ˆyD»`=¦bgýîfÂÏ·/½¨Š. ÉSn9î™å“ËÉ׬>®*¨3<[z¼åèÑøècŠ´¥ô9FW½2¦âk £EV÷àoí/êËa|Áofï$’ð°ë盤"÷Ÿ1h°‹ï~ã3Ub‰eEìµU6“±Ì[yÈšì  < {cý˜J,³ËÑ·ªÂeRi‹8ØÍæfµ¥Ð5¬.<ÙÓ,ôo|œ/yÚ%}*Ìåñ}viA@Wõكي*641tá̲å÷• Óñ´_½ØM&–*ÚŸð~9‚šH?#ÁËo¥ÿª•I5ìÇÚ#)„—¸¬~Ü·j/® M$Qdp’;{Uü&ŽÅ/!–¬^íå›»®;T úe¹ù²—½]åŒ%‘ó›C9;±Éññ¹–¢º+ yèj˜Tɺ¦DäÐÂrO¶oËsV~.|³ç.¯‘§>WÂ7$ñÎ>y亥z¤EˆÓÍu1šTwöú_yX‰äˆCù‚y•$QH—& a¼Û‘³4+é‹ ,,.§ÑUx™Ûš”…‡ã/qø23§å]ER°ižŸ‘d^„ßJá¨<&:4Þgé´]1ÉŸìTD½Ïc¢êv×úßx–J€>Äpn%кêÌÞ öª³¤{ßa@‚¸ÊÀHa Ö ?Ž,.¾Ïxüd´5ƒ 52SxðW`â[]+aGŒ«—Õ>…MÜð¤?lGÃèJÆQêØWëÆ`Ù‚µÖ!iñEŠÛß0Ç3ަþ<‹¹ÒÅ®.ÓÐXN^¾ðœãC…|Gj)¼VGþ>¥ã¤ÚµqNåçî^;£«‰à¡MF Ô‹´‹6©†éeÈî{,¬Æ…tÌ­a§àpx^ðÉÍt‚€‡;{1!5㣴'eú€Iúßt„ª„©U’La‡ôH/D±`H¤uv°ßM{]k01ó5Œ''îv‹'k¾U¬Mž[`,¹xˆ@gáÅ6%¤í4ÅÃ?ý”C ©Z¼*ÑYá½X^–“/yÜ{Éiê«Cy<„´ofÀpÿݰFÍ{ŽlÜꢄröÍra[~¨4•€öã¥åxVØXc½Äí(ÙŸ’KúÇ×Ú":tAz\O•Dxñ Qy· W™¾ ÙãÎ^û+×Ub®»±êsáI•dŸpHºï-Ì5˃—ªœ¶ª ¦žŽŒŠ‹@á[އÖÞhjºQ®Bd»HŽå}d†¯ãApý/NØÇ_Æž‘TuK…ùµüÖ-ps4¿±–waÈ::çæ$Æe+ç²Ù»²³wª°àd»Ã™©Ø¨×¢<›£Z[sO¶)uÕ¿õU™¤UHy*-ÓïÆ:-"êXØ®ù®c`—Z‡Öt°»¢-E]Ø]îJ‰ÑVbfÖ51ë-þ,¶×$b[a}ûÓ—p˜`p†Øn³›`àCÀ3h -\O3¨Êšõågõ=˜ÈÈ;×1±³wý(FÓ§ñ¬ld3:³­?&çkxr‰«q׈ĘÖÃ2r°²Ê§I ¡N«gðØ–õ?p èê´ÑF¤ç}c ’¶¦üšf¥Üy­(7Zw«žGäF—Ѐ•×uj:y¯PïoÄͰ¹ýaØg_½:Zš°ëd}$T«ð^«´D ‰’=¬0Lsƒ¾)¼b޹"rÞ˽w$‚ÖlaqNc[Q–Žô¥o-¦w üjaôYIÕcˆ}&ÖüÊÛ{:…;!n‚Å}þ :€(¡“IÎ@‡Ð!†,½‡%ØpÊ8<Oìž#®ÝÈ?sEayŤ>ºtñ:ânUmü0% Dq`T‹ÐÓ*©ûY°üE*ôS/åg¡…6v+}f ,!?¦ŸZ¶¯î x„€C?¶_üîT{îMtÄû[‹6í‹Jg!ÎAøgX[ck3L‹–ÕŒt3k°}ý@O© ÷ˆSà!¢Qòc—Lt¥( DÉ)0jÄÊ»,ú¦ðB]~·Íˆc³óÐQî¤_ñz<`ö$üᔄ’V;h¿ëê­Ah#2ãÝ´!áÅßìKläÞ<¢´³¾ÃaÚ¬ xoÿ‡%€9ËÃöÈþ#(‡lÞál„ûYÛbfGØþOT¤tó±ª6|z»¼c«eg¾´{ ëßÓ—£ZpçåS©p_ÜzVW²½D ýr'œË·Ÿq]°ÐÝÅÎνé‹Î3 íJrw͇üˈÏvžŒE«mœÌæ:4´×—Uµå*t…‚»ÁÍ^QûNì°R-ŠšÈæNÐ륵cš¶±þÛç*nPã©Ý@æ8W2Ç­ç8h'>ÁUCÖYb2Å“Øñã¿û„¸>Gqì‘äÜälÔªƒŽÏ-°:°²É­(¼<î,*BÅŸ”¦r§Ù=H|-@~™a—#÷µ6„—û8êhëEô˜Üüž­0]Ï710ôŠçØIöxPB„Vn¡\;¥æäÿ¬ì;àŒH±õ:Þ/(x‹ß±à“'Ÿ<tÌ@—„ƒyÌ$>ÓŽ¡Žb¢aâÀ*ZŒED.[Èdôì¼ìÊe—ôÜœXç’+ù|CøÕ˜Ï aÞÿ¡ Ôï¨R•(ןuÈYW@|àôj—â[†w››U”ÆG+²#‰!½ÓÛ¼ÕékˆÐŒ13Çô”v/º£ ×öˆ9†Ëœ¦lðLËV)væÆKÛ2º‡U“¾Lž7dò $¼f‹¦G­óŠ™ryDplÌvÆù‡Õ·6ÕV+ڮ쿇~â„ ¢CÒJÖˆóÅ¿›¹ˆ¡F«¯$9m°²V¶IsÄÑÆ¤Íz‘•Mƒ‰æ*m!^™¼S"ˆl_⻳LˆÃ6!SLzZØörKZ¬}ÐK£ÚY‰é-`zšµJÁK!Þƒñ×ÅÞdïÅžM:ñz»æÉüŒ¢i¾*<8#!½VÝ*-~‡N,‹¥¬©v=½þ^ÀÐнÒÓ Õ)Ñ]N Ø>]õu5/‚ÆÀâQkWa¾îŒRÀì‘>Û ¨R=X ûç.é =2U1öbØé|o0¶¢Ðü‘˜/hÎHBÕ“¤¡ÚP®Ç@Ìú6‘j«™äŽ.¢¹=-5ɤ‘%gdµ÷ÎÕß¼óÀdClÝ­à,˜ó¡õžEÎÈ ­ÝféÁýËÃm=¾}®"?WX_•Q>òʉ-ËÞy°âûNÅœÎ${µoCÄ;Ûûäå§swûÐ º¿¿OL&œ‘ ßgJ!Jï õ0_SOÊÀLáÍ­,’;1¤1Ñx°ÆÏNÒË´˜9]xÖÕtå»J%L ÇñyÈ!ä’ï@.%EÆûnõö9¡ª¨()©¨T'¡ÿ©ãèí}b+Y;AÖNøˆ‡0>ÿëánck¾¬½!ðÑ÷µÀt->«/§ SÅ/bñ€ð•Ë‘)2é°Ý@g±NhSšOnÜáòëTHèõØœ9·óVÜ£=ÜøÚ×, -¼ûQέ›ñ¨*ö²å¨,¡46{Û¹,6Û„> ¦Œu–CÚzÒ‚÷’_îKnç†ó8’µ,ð;.¢öŠºkY\=þŠÿ"¬ÊÙ!+7çe±IχDéårÿG¦Æoü«Œ[H#¿Péä¶%"%:#†¢èóÈ-{mXÍéªïÁÒK wIC…¯¥ämo/|}‰Õ|mz?éÂú·%þÿ®o]aS«Î­•üúH*è©7óxyØx<áäjÅSaq8WËbÃ"k!ˆAßN,ä{GµdF(i3´<ïk"jxÒråêယw7³Ûä´¥ ¼:5%§*Îüð ©òýÈàYóZ³9Î6S½•xB +/ØJÊ.˜”]1)»c¤ì‚´e÷68ØöHZF‚scá½v<áx„c¬I33 åÈââü_a*‚t‡ÇÃT¼¼Óý}16>³:àɘQ'¹  ›¤jaïÀD„úñK÷CKÑbOgKoçp[´Š›Üòñ†Æ[ZÓµ‡[w,¨éúýúÎóŠªKyÄæsdfׇáØ³˜v[b®˜:ÓK6@xÀé)÷–v.úÑtPú¹ä×ËѧF|à<#ÄŒ¨Ú<ÆB ¨ù®«Syçf÷)1Ÿ æ°éAó7®Uª|¶D!.82÷XÆþ#©Ç”Õ°0ítjåár<Á“¯Y½{ùlô óFާï‚޽ϦíÛw5¨U'ÕI@ùP JbïÞ|»j±™: ÌêX‘WãK2³rQ1WT¸y´ÙDü>•P¢Â*Šöÿkñ†àJv]ßã§]uè뺮)QduåÖn+7ßeЗyç« 9¹ÌpáUE¡%%EE%'B‹Taa*….”‰U#¹MH\ç“ÚøôׯõÔ†pÿq ¶vI¢ã]’JCò<ÁƒVþßA¿;vÝ[=¢â}VóÓç‚Ã+E¿NÑbVÄÚ N‹õ¦Òõ&0{“„Í6A¬úkQÞÀý–¤¤pœ·€°[ä+{À«C‚„=R8ªc-ìé Ûʈ J¾P xQ»¢v'ˆÚjÕ.ÌD" vH…±¤Çi¼I¡¯0ÂBu ý¶Ð+H#}õzÞÊÚÏÙq«Ë¼+ŸÊHʈ;¬°bö¦¡ƒ( 5?×r¹·E /%5=pú?R(#ºŽÇ“ ÂA=XNè9¶‡sƒ Uºêž©èaKòËÒ+×y~ù‡.âã“Q¼Ò–ÍûäH2{å)ß]Xonf¹Ü4 0-g«ÒÿQì]ÉqÈÀ/$Lµî¡- âÄu”òM¨Ûê*–¦‰Èzåƒ÷ a åu§TÐQÏåqf6½¾ÀQô L ³Ù°„ÇW1bu£r„° Xq¤1Á*ÄÖ èHQÿ-&N´ endstream endobj 237 0 obj <> endobj %BeginResource: file (PDF FontFile obj_646) 646 0 obj <>stream xœz\SWßÿ›[·àUPŸ{q[÷®[qƒb(РвwØ$a„™œ0ÂÞ {ЏNÁÑÆÙÚj­ŠÕNµÕç\{èçÿ?I€¤o}ÞçU‚Þ{OÎ9¿ùý~OÂ#Ìz<O°ÂÁÑqÆtÝÇqÃy܈^Ü¿ø)(Š;ðÁÞô僾fõ#Æ_³àlAÅ8} ÁçñV¯ß¹"0(Jèíéj3aŧ63æÏÿÌÆÖß]è½oo€ÃÞP/wÿ½¡øÂÏfKà>o÷Ш©6¶~~6›uï±Ùìâ. wßoX{E PX¨»ÐÆ!p¿»0€ gÛ€íËW9¯ ^%\²&tm˜]¸}ÄÞH·õQû¢÷opÿÜc£§×fï->޾[ýüæÌýlä¼QóG/³pì¢q‹Ç/™°ôÓewNÚ5y÷—©®ÓöLÍϔ̊™M£ˆÏ‰ùÄhb#1†ØD,$Æ›‰qÄb<áHL ¶ŸÛˆ‰„1‰ØN,'v+ˆ)„3±’˜Jì$VÓˆÕÄtb 1ƒXKس{b6±Ž˜C¬'æÄb1„JX½k‚O #̈á„91‚ ‰‚!(‚%>!lˆÞÄH¢±ˆèK,&úKˆþÄRb±ŒH؃ˆ]„±›°$\ˆÁ„+A;q¬ðTÄk^ï·^3z•ñó…ü«fÓ͚͛'’ÃHÙ) ^Só¨|êÕ'1½©Þ™½ÿ쳮σ¾“úÞê7¥_Yÿý½úß0}@Ú@ïO%zn¡°ø–;-Ÿ¶œ@O¤¿b?äÎÐ Cc†þaµÆJkd}~XÔ°ëÃ÷ ?8"zÄ™è_kÿ•Ëôgv1ß±Al m¦ÙøØTÛ\Ùä´‘›GÊG^5t”zÔ›ÑCGKǘÉÃÝÕ÷çÊæ Ô>âÕp>|¨åÑÒC…" uGý:ÕV ’dqIIñ †ò¯%Ì[²´Ô7DO¶âs8—¬mîüü+A)û–,©õɹ±™lRz ­àBè[è sdEê—„íGÅ/Zè¨jù5\À ¦AÑ>f9)âiªA!{µ»¯à,²ÏÚ "Ö®"-O¾¾èÜ…ÂÀϱ_ W£7Åtœ˜|³ýø¢µ.Þ‘‘Œ~]N¢áâ\øðü††æ0Ô¼œ,Òbv4)¿ PÁ®Dã–Àqæª ÐP/4< ƪA[A¾( Y£ó0R‚×­Âwÿ0LBÙ—pÛoh›yhØßéVí²>\]4?h¡X»;€ƒ³¹Ó4D~_îàãæk7‘C­ôòçA;uoÃcÄgP8)Ñí¡ ³5Òò]‰{ä$4¿ÖñP»óæ‚2ÖåÓȆC†ü¾~¹‹óþ³Y¼p’~­á]ÖÂ*-Ÿó„~xÅ©¿!3d6u„,š {Á^?ý -´Í¡m¼úáæÍ;woØOŸê°ÌV7Eœ†ËÖðŽhá—×ø\$÷.UþQÉñ‰ÉŒ,Èb„>µ»UÛqÀi<ï0dÖAü/©§/šB@œ4ÈØÄO„¸júœ÷p"üôÙûŽk—v/(dÓ£ÓDõ€jj•n1$ÔÀiøeWª(±§Á°„¾zåÂõûW–Ïž´Ê~Õb¯çg4ÎìèÞãÒF@AÞ/?AK8`æ¯#wºDùy³–¿ÔÉ Ýÿ–Xµÿ)±Èž$¹¦…±—<¸ãtnP‚\ê@ˆdÐ3Ò'!Á‡].ˆate.À<zÜ/I ÞÚ»”1ðÙ”•ÓȾ”ro/Á¬@µ‚žÙka©–ƒt×>ŠØòNIÙsÝH8ô9´sàì9p"²f‘ ó4ÍI~@ó6œ|úd€ø&~º¯LÞµ#gCŽvg‚êܪ7㈘Œ,ÑÀ'Â^_žj©P³È×Y OøJœQp!YT¥O`ëL®†Þì<¾­ýí/ok¿}pr‰¡€`˜ºêÃ1T{R» ‡äÏ_4´¿qçk0½Ãhúj¤XvÂ08TàDÍ@yóªë±ÈAC¡+”m#{ÓwmÉ{(d’KSò‚¥‹;Q ÂúœbEK>ÓêyAV‹ gfãwgþ@´Ú7ÓPèp–žÀÝR «qJm…ît¥®êÕÇèÀcd,2sÞµ P –BއS¾ýýaóõPD”°iÑÊØê®íBV¿ßðä8o1ãU¿¯h/Þoß1h8²Cëÿ@Ö°Ïåcõ*6 D¼lpÍ—šßU<]Àgâ@9’†óŒþCó“=Y6¶t-÷9J%'}éyïþ£ã¥@íå#fä›ãCµœ¯bMÚ0ï™za íp ®2™ÛÄÆ*䂼 Ëߟö´þªN‰ÐxûG q öBáB“t3}jˆ¾£.«»¡0þÙH+|Õ P÷Èâ*½Ã%¬ |LêóêoøèQpÆ‚XßE ©‘‚ŽÈ!'iCî=š[ÛbÄ?‰]yV8„Iî2$:%ˆ0¹>d2ŽÐí:å<| áUrA|n9ŽI½‰c>1[K"z€xðyíßFô8«ž„ô*ß[ÔÀº T€¼&Ê€2©Þ¸ÇeÞi}·+ðìŒ{Ü9•œ;?92a'¨`2232A1U©††‰}×ßÚõºãÑÅt†§¨¡­ò5¼b.ŽÏíÖmYç Q¸¯’Q!zÔ/c[É蜹œL©Ž9{4êzjžˆÇ…–š¸1)”œt‚çÌ[ ô'Dö¼] êÙk¨##4]|Xé9¥šªçŠÂôrJAf:µ O2ò£KA>héÅåTwìgh^k,.i÷t@ÿp®W#]îwF~Pµåò±7>3=…~‚;[Ÿ 1{Æ‚åþjQeQmN‹‚Ù …*­PQrõÕy¿•¬åi´* Ø1iØêëöo[Ú³N3q¸M~&À,.|”g´ H”ƒÛíO[àØ ¶»³bè͇G †$œ`~„,¬ézWPËA k;néóê®­éŸwQ¯#$ì& hŽù>ã]ø‰!ôáÀ} t æÝÌ?ëYc_W5¨!Ô@óÀcnhECû&w§’Œá¸W¨ªËÖ½G1üÿú£f÷ÿ  ÆRàia®†Õ8ÇÚLìkLÑ–N‰‡ñŠëÛn8eq߉Çè–¤v©áhxÇŸý—’X¼c<’¢ý¬ådr™TX6&ZU}¼>H8 }Ȉ2 ·2áüa€£§L,ŠÌlP@UE• ƒ¢£‚÷Ø×úú$´ÊË`zxÞ=- éÀ òèÚ$Š—E$2I1‘»l5wÅíÎÔB®> ¤¬Â«LR ¨JuIݽÑÀ-û˜…úþ8Z@öÀ¯%])2Z ë5¼Ûm°ªsæt¬§4 )EüéY0_¦Œ¯  ¶ìUƒF¶S"ð ï2æqw"ø²\°B·ûr̈É-pÏLT&ä'æƒP˜]˜®ü*ó/PŠÎ`ò£o–Õ]ù·£rŠDLõ$q«ÕãÕZ­R¤ƒ’.âöÊ@Üv‰[5L ›¨5P«ÈÒt*'¶0®P®i #­0#—‚}Ðuzü²ã'JsUlUq¸¨hæ¸.Û3¾«{è+‡§ç9|n)Ä´4–‡ƒ0°Øÿ2ßÿZÑ@]¯¼u¨«^Ì;ýål‚Ì#:œºpdK+˜ØºPµ$¯'u½¶€î¯Wãý½‚íÜ0Ú [F™$£9jGýLòéŒ1ŸF‘–o8™YmXy``XX``yXmmyy-Ó]zçoÂâ›î7u“·Âº6é»0›rÚ³qQ sFÍ>foMÊ1y©¼D^êÛ%•^#”+ s˜#þÑ ¬¨»Ï;nx‹-`ÝŽe-.¥,ß,(Ý›ïÞ N[Ÿk=sö.šâ§dÒÃò’TݼßÊ S’£ý·æ­ù.˜÷ó—-š»ö”Ýw!l†ü—ÐÂTª@±ÎtÀ¡zG¼ãÌz1“ì©Q8¤s ¢{°W»f5 6Mœ†{}È¢jCKÂCâ–þ ŽÂ±aߌ%ÇýþQßlµZk¡U7)¶úˆšþÕoÝ)q2Ñ϶ÿCÖúQÜzµéXU6 @y³ •žjÂ2H4M6‡ï Ú{zk§ÄÙD?˜¨GçGä·÷qíM3½é]ÓÛ8½Ùähaœÿ“¦MZú‘´±srÚfþß ü±^€§ùبßH4àٴׯŸ½„þ¡(¾ø{¬ô…;K Úäú±IGb*ê/´Á>ºÝKËê#@ | ««ÁAµ <ûJý¹ÁÎpàÉÂ5ËÖŽ£§VFÛ3H"ˆìîþ6è¿IÆœ’3ýÝbö2â¥>ÀøKBÂtÙ™ †X ¯Óðò89Ÿ ÄžÌëf‹‹LZ銞&lHt’bz—tct–+¥¡@ŠuDˆÇ:bÚ•ì€)È”—%^tâlL¹ß"o®9¬‚¼Û©ÊôªÄŠÁ:3’\UzÖE“që‰ —‹(J!ËVƒ,ü¼d6P6hà\íÛ´PŽ+èXÏYÓ^À5Ñ-Œ‚›a¢þQ9é“(õeQ™ „6–fdæf35GK¯ÊòÝã“Ëí®üü³ÀuÙ—ÙÌÌì, ¢êB‹ÃÅþÒý󞬂fpÐo/ ÿÍ’_q·4¬ÝÒçã8~%NúCÍðºŽüññspÇe&ã?I Š )¨®R•Ô·z^œˆ†á¿ý cùÅC³å¿AÞ¯O`_HÎê@½œœ¢Ý\hƒŽÒö`k„F¦”+ñ+ÃJ‘#Ï’•€,ëökg¿zta­í»Í+ôûPs-Þ íeœïýp”-Zï‚êEI€OsII^“ [à¸\sUUš– )?ô™T¥“FÞ ,’ÝÛUêe†Fñú‰š©âA¯×|x“k§/¸eH¥n)Û¼3Ñ´4Fáö§¹)‚«1…=Ò³ÓŽ¤]TÜT\TœÏ¸.Pùÿ¡5Ã4 Ü­±8¡uÔÜ9ê#V;éå'ÛηùæáåN›\—³ßøÑßÖœl—©Çs¢>¨ïg‹l>µã›`Æò÷eáë6.6ñÕ,8Z¼|þËû«¶jfj¤çÙµi5W®ÿðòòú «í¶ÌÓ!1|¤†Jl‰ÅOâÃî~Ú;;«Ü€¸t×äj¥§‡×‚*Yª(Ñ%Ížÿ}„Áùí°_ëÔcb3¸1°šŽGO˜„“ßS^œ‘™©Äl¼2J,Œˆö÷-]‰i†nŠƒ 3Ž>LB|ídÄ7§ù|&ìuþ|ÉÑ“ “A/ØöÅýgwÚî¯ (f«}ò·c"“Ë@2HÎ)å¸uó<}œÔpÔm8î6¥â5sÎ|®üŒþŠÌoÍÍ^ –µ#Ká8ó3Æîd!d¶„䊵H ÇŠQ?«1½»„Œõ^^Í Ÿý‚ŒBãÌ7“"4¤9U­nH¯ËOcŠaóß?r Áuñ»~†1úˆ=`ñà.8ˆrft‹µ¯»ÐÏÏ£>¸ñPUCƒ®šýã~ç<õU —ˆóØâÊußkžt¬»¡§‹§`}+æ¸ Ø¶»ìZGm€"‰.J·rñ9eFn6¨ jCJ"¤ž)»ç]Y©8ÆC‡÷ õ ª˜9$€ýËÎ=·Akàohl …™"Ü/hJ9+)ÞŸ b( ³5êÊü–¯ï¢Þ¹L‹åý€Pĸ P¯˜uK-Qâ÷-ò£n›mÎÝvœgÎiÏÕƒ=«†½ÿ»Ý;Í蘭î‘ℤTI"Qâ¢è’òŸ/B³[þîžÁÞ%^­zW´ÃQí0µŽnç5·µ·½Ç/>·âà :#7-ó‚RqIDHbdl2ƒªÿZ•/K‰Ö‘Å¢²Ê¬R,›á÷Ð÷=®îØá±ÑÖ¶eãÙ³-Wï3³WÒ±‘5'N”Õäç—¹ºFŲh+÷~¸¿m§³û¦e‹o9ÓzèÊÃÈÚGKë JýÝ\#cuÅÖ¦æ\U¼6n:ŸÛȉ輬‚lPFUD拤©r©„AÑ>iRLˆ´1Ùq¹‰ð)r·*”¦ËsU\–_Q†ïf±è´37ÔÙ= ¢áÕj•mOÚ 6ñ3¬sŒ2­›+”°A+}æm‹Q»]¸øæ¸ŠC® ÿj厭.ã÷dmQ¯g6­“É#CD^`7µôôНÎm<ÔÀGߎAàVÝ—gš‚,XœÌ¦¸Fƈ€p?%ÍW7«NåVQh=œH‹ÏË/€lêJuuù´µÒ€(Ï[˜dFg‰Ê| CË÷gJKB<¶y&K彿L^þéóú6ätûñmÞ!ΑÏ9À×t~.H¬ž1Ãxà¢jÂEß¡Éta ~âƒKýIÆúà'-¶u\Rïy°IÇ?rIô×-n>QÁ!AªÐú¬LHc2€4)2uÅ¢ÝlBr|2Nž¨Iaå{-´`þšÍ¸Uå(u¡ yñYè)t·’ä¤*¤€EƆF⻉,<‚ì~Å%êãZ[œ“®È)ÔM6_ý!÷T[Ý1òV%fDå£OvCkÍÀëC…Ã~(ÎËÊETv²*8íAV(õ95£ysaùƒ-•€ªÎTe³]`ÿÐX´wœz=ãÛ÷þùc N_~u®®¸¥œ§Z„ϰ~él·Å·R¬VW”Ôæ'ç&+™ªÚÓY‡õö°¯_pXld<‹Æ.3Á>j?ˆ9RŸ«<ÀXþ™‹–Óã.+b2÷^¥ì³û…×Ùm÷–µ…J˜‘ ÎKÌLeá<Ä+Bs°ÐïX4|º· ¦”Uupîé9†S¨sXñN´ýÐWá\ÃEÑ©i:bE-´ŸƒÌQŸÛ î·þ| ÚÞP„V¢h ŠÖ¢5°?²†6/ž\®« ñÑ© >žõòuóÆâ˜ 8 ~úæíïµ'ã7T°ëÐz×ÞkŸœºtìä‰M ¸lÞ£sä 57 Û#¾†GÐùYY¸ú2@Ý> \‘V­¸ê0·jòñ>Ò…]Z0ƒˆë’HÖ1Qâȼ¤xÞFDlŒMŒIÖ) àÞ•Ëí@€µø45¦œ:ù-Y5£ñöPÝÞ[#JÙ€R”•ÄæÈ¬°dMSp¡®íÍÓ|é²çÉçúÑF2fg c­ø)ã0Ð΄&Oþ0Z·߆K°A·1Û†•4e24 Ž&óA³F¤XF£=àG¡Ñd,ðjƃó ¸ñ!TÅ»ÂMæÃÁ¦Ñɹ %a€ŠGG%dħ'±ðÉ_k2㳣˵ª¨¤4;%7UÉ»66ßàÃætZì°K›Ÿ• "ô­¹ñíEØK³ÿ°ë¾P_÷:a“2K‘–Å-—àܺôad—P°36“ÿ&›\ÛZu•^yÛP§ó±ÍFƒïÑâ|Õ­·qîroèØ¬$ª'ÒdÔßÎJœ¢©Ä\ßÊ ¥"+Ÿyßþ~C¡4 (uencV‰4#6‹5q7µÿ‹ð€ÉÝ™ü÷at-çòaU¬¸?êÀ',Q“„iæ_«Er¬£Š¢UåYEJÝÔõn±]§ÑÌtMD…b²Ș£,K¿ûÍ)6;3W÷Git¡$däjd±¤ÅãhSiueÌçÕÂÃ8·t'lÆÂ¡¨2¯ÿ~Ã[4ö‚f¯á0ˆ%ʦÛã`N€ã´¿Ý¿wûS4M°G½ëÐÀ³ºŸnaWBc²w$=»ôÐó´f@)UÊJœšQ«/fV4+O;@ 5C<ØSä)Þ!TRDRˆ¥<—­–C^jÚV -àr>àXè¥Ä3€*­ uB…”E#Ò1in à¨J=êX¬ª¨IQe8áúkÞb·$ã}ÜèúºAdR,Fq÷¹Nq‘2‘<\†×–&•U:Át.˜.0žÕdËh:ÙC}N÷ÔË_K¦õôªù|,Òò¿¸BK’’„Ò}ó‚/ yYÝu<È )yõÜÏŽ¹Þvêø–‚}Ç=@ýQïEóçzÔÆ•zs4‹):uºá ½{Ö*çMvŽs5n»µà¤SÝÎêõ^€ŠÆB5¸, gF†ÝëC!ì¤}E¾ÇC·øÊv ­€à‰ÆÊôÇ{,yö“êQ«P‚³ –z!À¾-:X|°èŒ¢ÒºúE<¢@½Òdm]ì=íšîû(':>ï€AÚ}:Âñá3ºí`íep‘º¿ü $@}Wí\íS%Qéì)LÊMMgîè>vúò¬§‹¿Ø+(Œõ Ê> endobj %BeginResource: file (PDF FontFile obj_647) 647 0 obj <>stream xœ” PçÇßeïvW½’ÄÎíI‹F@Z$H‚á,Hˆˆ''\œpz@ÍA€çÎD÷8t«k|ª…sy|Tq1Ä®^ 1t±Le<ËMõ#Í訑k]Xz‚鼉cn²8 ׉ïî„zPúàã+ýùÝe‡dß›­¯7¸++TüJû‘]ÇŽiô¶:º2&»Ã.™Z³+¤ Fû3T³„ÊÇqÁ«RõQØ¿;TÊ4‰ßÎú—ËsHª­õnk;—q³ôCÕóˆ_ýÉp›2m²Ú¡ÙARn 0øû )YêdþÇÜNºWÛÇy98„ó@¸1y‹†¹ëî»p~¿ƒëªL®ÜºÎ«¿ÆxhˆÐ§ö{|ùÚ´Ý2õ°Cª[#YT³`Óê—‹¥â¡ÕõÏC8¤ìéÂÿ8~™ßj.ZöÖý×>´¬nbU­ñà–&ŽfÔðéÈ̦kbštÓNxt:dZtßréB ù'¨'¡» endstream endobj 210 0 obj <> endobj %BeginResource: file (PDF FontFile obj_648) 648 0 obj <>stream xœ¥W TSwš¿1ŠW‹¯v³mç^ÔÚ±ÝÚÖ™ÙºV[k­o­ï·È3Q’ ïÜäËû áBAÅ7*ŠÕê¬Ug§í®ÝVOÕÎîL§çz™íþ¶™vÎÙÇÉ rÈÿÿÝïû½>1v ÁápÆ/Y»våÜ—“¿>›xŠ“xzLâçÜ}¬õ›qCêqÊ…Ô±íO?ñâãÈ; mš‚^žJp9œekv-))••ñ ‹Ä³—<—1wþüy‹‹óËø¹9ÂŒµ9â¢üâ1þcƦ’\~¾XöbÆâýû36&¿Qž±1¿<¿L’Ÿ7z÷’’âÒ q~YÆÚ’¼ü2!AÓ K–”–•‹WJr¤{×Èråyoçò›÷o-^øú‚W_#ˆÄ:b=ñ ±ØDl&¶ÏÛˆ7‰Äb±“x‹ØE,%^"–ˉÄ*b5ñÄZbñ6ñs‚&&Sˆ©Ä Üb<ÑÌÙÃ9:fÁ˜¯¹ª±Ü±’±Ÿ¦<‘28~Íø{dã„Ô —'Š›õ˜#õש7'åMúlò)OL M OýbÚâi¦iÓî}ËY»…˜<¤†8ÊŒ'–†9h9ÏË]‘WÅÔšÔRRg×»¢q+´Qà Ó¤Ã!¯Ú¬¥Å–r´€Ïáuœ>3ü‘$²¥X$öiP‘ÅÛ˜ÊjT*}`9rÔ G¨¸Â´à|öª f-8c ýöÐ8clrH¯ƒV§"YéðJÚît°wÆMþvÌö„2’˜á oë®rï^â1 ô¤, ®ó5¸ÂNÊlñp´8Û]íÎvGı7Ù‚®˜ÙVïÿô3 ûÜ‚µ;Ù¿«Ê¦ÕbS-(ÉÝ‹N<ìFϺ2Ö|ùnËim^]rŽü§“ M£%aÎÕ+\´7ñ ïaJØ32,ý«”.4ìõÈ™S‘šÊc5nNJ¥ ¤µ.ÓwS–°Ý9ÈÈ-‡òÏ}1ä• j£ÔSÙ3·–ó”¨üš-N[0ùÐÇ<ć8qNbbâKž»ËêùÈf„|J03 ¤‹áMk1Ú, nõFAª£QM³O w© ÕBH«GÔÅ»e…Ý·™v ]>|Œ*dz°TÒ‹Á^pY\'ùçŒDœ«žAô³‡ÜDQ‚äÕËÊÊE5vWI5VúEPHæ¼ÍÊØ ÛÅÏ^ˆÞŠß¡œA{Bdß¾îsòÙYêÑÁZêíTìó£M1|uö•©Jµ2:‹%k2!›d‰»UÇÑÂôÑYÜê1S½nïy›˜˜Ì“u £{€d'°SÙ_°ÏÎ9¿òýðiÛ{ƒ´+ç à$„¦¦úŽ`—ÿ2XÈ©2ªJ¾J¶~/¥Lk8bqyÑÞ^‹Ç}(xÕªp¶l#Ã*WTT0Ô*ÖÇÓËÀ¨gmÞ[UäŽêó‡Ow )MÇéø¥¾î ß Ì×éŒ:“gÌ=.Òå$ù»®ßç¢OÐyž£µéþ °C34Ö”è+Ë |ÿ‘ކž³ëü E[ŵTÙµ-!37²¼²d\V‹ÛBw~}­¥ÈÐAõ†ýòl]µ¶(' t ‰¿ÅiÄÈV¸Åe¢}™§+]ëºá°R¾‚®¼A ¿@¼–äÓ«­‘d,/ßd^UG'–züôx¬Ï6ôrN "åM.Ò -â™ÁS#~ScQ“Ò„ñY놺“­J«æë%Ô|öƒÚ†*(J¡ím4MAÏ¡g>ÝúÏ 2÷ ÷S•¯ó°¸½§Þí«k²+Z¼ú‘¬VdæÉDo‡ T%Ù¸˜õT‘Dµ÷!í£¨Ö æ3 øÕµ£¨¶„À¤ŒnÔ€ÁÄ0µì“Ãiª<£f!¶"ÕÈ5Љܔf0ƒ#øÚŸfóâùšIãT«Mú*-Å)‹Ma9'¥Œ 3«ÌŒ\`‹½!‰ùÏ–lN¤÷nï(ð‰«ÞAnBž˜Æ³ðQN²kŒªJ§PSF½f¿A¦iKu¥{ØiEöÒ•@nWë>|§ó.]_¡À AèÞöÎï( ÒJéÜé²°›üå•âK‡;ƒmmTͶڹ[Eü|a&Tëüp=ø!àó¸=8QñR›J,¨Ú¹ãXÁ;_~ù)×–§îsx°¨ónψ‡ p‰©¼*|@uu•Â(-YÞ  Å¢Í=§vw¿Å>Ŧ³3Ùés/.ü ÍüèkŸCçÄ6gÔ訅³YÔ¹¦ôÔà‘ðt¾CÇÎ=p¨&PšìÓTByÝA¾ˆë:–â;¼sc-]q0¿ÓßÕõÙƒÈIL+ C£–1ªõTñ.IU9”Cm"(m’‡@¾‘ù¢DoչݻÃB‡Ž_4» BÚ&M‹£0{ÞiÕŽ=&S^þòEqñ#±X¼ªé`{´šÀ£n% UXOþp=µìµQ§ehñªÕRT‚Ì!qòý ›O» ÔL2Šÿ#ô+^Påý:=Ô|~Š©\ǪFµ'ýÿ®=£r¾:ð¿QîLé#’ 1‰ßò<= ñ­¤Ýg%«%I‡"+î¦.I¸è“WÀ&†;¼!%Bš“YŒ«2¥R=J&ûÀî€ù£Ê•ï{•I×)MR-Î ­p€î„.æÀhñ¨ÍJzƒE08Ív«¥%ZÒl:0ÚUÈ2üqšSn5º±k€u”@7“ , Îñ›(x€‹Ö¡*^ n[N7Þh·_‚y,ÿÈ2–ËþÃóì’Y—þçßßkê:|æxÝeÚáF/|™”•Q!&ûkØ›T²‡ž$YCw¥q4ë^C„Óýæ>7ÁÅ®üñw®,§ÿ)Å{Ñdô^´5ÞsøÜ¡`]#Ø0ÄB²,ƒª¤¸¡6Ô‹:žÙ´—¿F6»˜ÒIU9û8¹,EŠÓÆBˆ¾–òÆ0-{^þò6H7@HŽ[Ý]PG6É|R‘°"ϱò#ç{.j :®4¡IæýW”,Ñ÷ïG3"œ[7¹‰}‰I<³ÃbÇb’ôl…JÖ]Ôš‹½-ã+ƒ}föåõ7/8áõÐf“ä—µ{Á˜nPógO)Ì%îv··‚d½2TZ±O–»·»ò÷hÚÍ÷ë()ÚÆÓ‰ÄeR‰l¿ ›ËÅÙž“141z†Žž:ÚÓ äµÀ«z=F˜!ÙÁíêGTøû{œrQ÷Ð8^¸º^\Z**•äÍMíMíÔ¢áTž/†å+ê ÿ-_ÿ3Q“h%­íaɪl•¨FrwgÑI¼EÌrÿ°EÈÖÞÞþh‹pš.' ª¿žì—ç“„u¤¦šûHx…›˜Ž‹ UËÅÅââÊ@US4Ú¥ØÌ?ÍãIíÚ¸ {£dîv'FHx¤-eBIanOÅÉúÿÐBÝOŒÁ¡,Öôœƒ;fm|T·Ûl¹¨–ËÇ/Ÿ2Ð`È ÈX!Vdcâ%ØnNbQâ+ž³ÍæðYÝ–X ÈÏû ¯) ym2kqdÕYµn¯ÅUg¡¢èM³ÍìÁ×$aG ŸM)“I+]Ǿ•f2ê±á$D§Çl¯wPçÐK­ h6‡SÚÀ Ñá’I22Žóš2Ò uw^pDÛ,¥Û fnü2E!íF¼ëx’›¡De5`ÑB«Æ õØøì¶º$îžÏƃâõrŽã”êý±½KI,u'Íj 8öña†QµP•¾ñXщ-á® ÕpÈwñ¯ÔLºc´:Íf»=”lÔò-DEãÐt¬PdâïÔû½Ön‹ÏlbÓuém‘RJ|+!º*Ý&'5†T …¢Lìà°"my¢u\°É<€ýÒ­±èr³ØKÉ@j–þi‘¤€$ ë/˜ÕeVúƒá?Y+mŒÒëÁfwùÉÉߌ ‹CSþ{o™¶DSL×n×W*÷¨ L:µÀP©æ?:%îhépQ xv¶úûQ*âyÔË/ܘæTn¥Õå%TþÔº¬Øºï­Í±.ŸíE\¼.¿›ÛûÆÛ³¶P&?ÓYÒ\Ö¸Ï^saçj¹X?Ó¾ç»í¨¨fýOmGõu?lGÜ ƒD^c¢3̹“@Ü¡y =ÏçpÚÁKzÕn%cm 5|† (õ=Ô¦C­KïÕ'ði~­ Òëv{½Z{­ƒŽ 󸟈¤<¯Ýeø4v¥}ø ¤Õ8À©T«•j». ¥Ö<ŒßÕZ½ÔéJ·ÚkÅÁÉŸ (¼A‚ÝÒˆÞøšƒVF¸(ËÌ»Vv8OPYVRðùmneµ˜Íf ÍfSõâ¢u­TbëfHìNvC_s>þš‹6÷óbåÍBay¹PØ\‹57Ç¨É †µ6~³)̹ø7±zh7[™ c2Ù ­–Ñ1ûÇÿZ«Ç9L#%ú­Î ƒš\Za£^¯?…ÍñŽO¼ù5qì¼pê„Gj*Aü7p| endstream endobj 75 0 obj << /Title(Programming with Linear Types) /Dest/chapter.7 /Count 6 /Parent 9 0 R /Prev 71 0 R /First 76 0 R /Last 81 0 R >> endobj 8 0 obj <> /Doc-Start<> /page.1<> /chapter*.1<> /page.2<> /page.3<> /chapter*.2<> /page.4<> /page.5<> /chapter.1<> /section.1.1<> /page.6<> /section.1.2<> /subsection.1.2.1<> /subsection.1.2.2<> /page.7<> /subsection.1.2.3<> /page.8<> /subsection.1.2.4<> /page.9<> /subsection.1.2.5<> /subsection.1.2.6<> /subsection.1.2.7<> /page.10<> /subsection.1.2.8<> /section.1.3<> /page.11<> /page.12<> /section.1.4<> /page.13<> /figure.1.1<> /page.14<> /section.1.5<> /subsection.1.5.1<> /Hfootnote.1<> /page.15<> /section.1.6<> /page.16<> /section.1.7<> /figure.1.2<> /section.1.8<> /page.17<> /figure.1.3<> /section.1.9<> /page.18<> /figure.1.4<> /section.1.10<> /page.19<> /section.1.11<> /page.20<> /figure.1.5<> /section.1.12<> /page.21<> /section.1.13<> /figure.1.6<> /section.1.14<> /page.22<> /figure.1.7<> /page.23<> /section.1.15<> /page.24<> /figure.1.8<> /page.25<> /figure.1.9<> /page.26<> /page.27<> /chapter.2<> /section.2.1<> /subsection.2.1.1<> /page.28<> /subsection.2.1.2<> /subsection.2.1.3<> /subsection.2.1.4<> /subsection.2.1.5<> /subsection.2.1.6<> /section.2.2<> /page.29<> /subsection.2.2.1<> /subsection.2.2.2<> /subsection.2.2.3<> /subsection.2.2.4<> /page.30<> /subsection.2.2.5<> /subsection.2.2.6<> /subsection.2.2.7<> /page.31<> /chapter.3<> /section.3.1<> /section.3.2<> /page.32<> /subsection.3.2.1<> /subsection.3.2.2<> /page.33<> /subsection.3.2.3<> /page.34<> /page.35<> /chapter.4<> /figure.4.1<> /section.4.1<> /page.36<> /figure.4.2<> /page.37<> /figure.4.3<> /page.38<> /figure.4.4<> /section.4.2<> /page.39<> /section.4.3<> /page.40<> /page.41<> /chapter.5<> /section.5.1<> /page.42<> /figure.5.1<> /section.5.2<> /page.43<> /figure.5.2<> /section.5.3<> /page.44<> /section.5.4<> /figure.5.3<> /page.45<> /figure.5.4<> /Item.1<> /Item.2<> /page.46<> /section.5.5<> /figure.5.5<> /page.47<> /section.5.6<> /subsection.5.6.1<> /subsection.5.6.2<> /page.48<> /section.5.7<> /page.49<> /page.50<> /page.51<> /chapter.6<> /figure.6.1<> /section.6.1<> /page.52<> /figure.6.2<> /figure.6.3<> /page.53<> /figure.6.4<> /page.54<> /section.6.2<> /figure.6.5<> /page.55<> /figure.6.6<> /page.56<> /figure.6.7<> /page.57<> /section.6.3<> /page.58<> /page.59<> /chapter.7<> /section.7.1<> /page.60<> /figure.7.1<> /page.61<> /figure.7.2<> /figure.7.3<> /section.7.2<> /page.62<> /figure.7.4<> /section.7.3<> /page.63<> /figure.7.5<> /section.7.4<> /page.64<> /figure.7.6<> /section.7.5<> /figure.7.7<> /page.65<> /section.7.6<> /page.66<> /figure.7.8<> /page.67<> /figure.7.9<> /page.68<> /figure.7.10<> /page.69<> /figure.7.11<> /figure.7.12<> /page.70<>>>endobj 660 0 obj <>stream dvips + GPL Ghostscript 9.06 () 2013-03-15T20:03:37-04:00 2013-03-15T20:03:37-04:00 LaTeX with hyperref package ()()() endstream endobj 2 0 obj <>endobj xref 0 661 0000000000 65535 f 0000261523 00000 n 0000380198 00000 n 0000260838 00000 n 0000246966 00000 n 0000000015 00000 n 0000001071 00000 n 0000261734 00000 n 0000360786 00000 n 0000261465 00000 n 0000264443 00000 n 0000261775 00000 n 0000262735 00000 n 0000261883 00000 n 0000261973 00000 n 0000262089 00000 n 0000262190 00000 n 0000262311 00000 n 0000262418 00000 n 0000262527 00000 n 0000262642 00000 n 0000262884 00000 n 0000262992 00000 n 0000263207 00000 n 0000263099 00000 n 0000263370 00000 n 0000263465 00000 n 0000263565 00000 n 0000263665 00000 n 0000263761 00000 n 0000263874 00000 n 0000263987 00000 n 0000264102 00000 n 0000264221 00000 n 0000264328 00000 n 0000266319 00000 n 0000265281 00000 n 0000264564 00000 n 0000264680 00000 n 0000264792 00000 n 0000264908 00000 n 0000265046 00000 n 0000265169 00000 n 0000266189 00000 n 0000265412 00000 n 0000265516 00000 n 0000265628 00000 n 0000265739 00000 n 0000265846 00000 n 0000265959 00000 n 0000266081 00000 n 0000267004 00000 n 0000266460 00000 n 0000266875 00000 n 0000266550 00000 n 0000266651 00000 n 0000266766 00000 n 0000267421 00000 n 0000267133 00000 n 0000267225 00000 n 0000267329 00000 n 0000268574 00000 n 0000267562 00000 n 0000267646 00000 n 0000267778 00000 n 0000267886 00000 n 0000268023 00000 n 0000268323 00000 n 0000268132 00000 n 0000268228 00000 n 0000268465 00000 n 0000269027 00000 n 0000268729 00000 n 0000268836 00000 n 0000268941 00000 n 0000360647 00000 n 0000269182 00000 n 0000269294 00000 n 0000269399 00000 n 0000269515 00000 n 0000269622 00000 n 0000269721 00000 n 0000308672 00000 n 0000308384 00000 n 0000354136 00000 n 0000306948 00000 n 0000338391 00000 n 0000306284 00000 n 0000332900 00000 n 0000305055 00000 n 0000323908 00000 n 0000269811 00000 n 0000269841 00000 n 0000247126 00000 n 0000001090 00000 n 0000004572 00000 n 0000303230 00000 n 0000316023 00000 n 0000302411 00000 n 0000309185 00000 n 0000269917 00000 n 0000269948 00000 n 0000247290 00000 n 0000004593 00000 n 0000006731 00000 n 0000270014 00000 n 0000270146 00000 n 0000270281 00000 n 0000270416 00000 n 0000270556 00000 n 0000270696 00000 n 0000270836 00000 n 0000270976 00000 n 0000271116 00000 n 0000271256 00000 n 0000271395 00000 n 0000271535 00000 n 0000271670 00000 n 0000271805 00000 n 0000271940 00000 n 0000272079 00000 n 0000272214 00000 n 0000272349 00000 n 0000272484 00000 n 0000272616 00000 n 0000272752 00000 n 0000272887 00000 n 0000273023 00000 n 0000273159 00000 n 0000273295 00000 n 0000273428 00000 n 0000273561 00000 n 0000273695 00000 n 0000273835 00000 n 0000273974 00000 n 0000274113 00000 n 0000274253 00000 n 0000274393 00000 n 0000274532 00000 n 0000274563 00000 n 0000247728 00000 n 0000006753 00000 n 0000009213 00000 n 0000274629 00000 n 0000274764 00000 n 0000274904 00000 n 0000275043 00000 n 0000275183 00000 n 0000275323 00000 n 0000275463 00000 n 0000275603 00000 n 0000275743 00000 n 0000275876 00000 n 0000276011 00000 n 0000276146 00000 n 0000276286 00000 n 0000276425 00000 n 0000276565 00000 n 0000276698 00000 n 0000276833 00000 n 0000276968 00000 n 0000277103 00000 n 0000277233 00000 n 0000277368 00000 n 0000277503 00000 n 0000277637 00000 n 0000277772 00000 n 0000277907 00000 n 0000278042 00000 n 0000278182 00000 n 0000278322 00000 n 0000278456 00000 n 0000278589 00000 n 0000278724 00000 n 0000278859 00000 n 0000278994 00000 n 0000279127 00000 n 0000279262 00000 n 0000279397 00000 n 0000279532 00000 n 0000279667 00000 n 0000279802 00000 n 0000279937 00000 n 0000279968 00000 n 0000248214 00000 n 0000009235 00000 n 0000011964 00000 n 0000280034 00000 n 0000280168 00000 n 0000280302 00000 n 0000280435 00000 n 0000280569 00000 n 0000280703 00000 n 0000280837 00000 n 0000280971 00000 n 0000281104 00000 n 0000281238 00000 n 0000281372 00000 n 0000281506 00000 n 0000281639 00000 n 0000281773 00000 n 0000281907 00000 n 0000282041 00000 n 0000282176 00000 n 0000282309 00000 n 0000282443 00000 n 0000282577 00000 n 0000282710 00000 n 0000282844 00000 n 0000308739 00000 n 0000356146 00000 n 0000282977 00000 n 0000283111 00000 n 0000283245 00000 n 0000283379 00000 n 0000283513 00000 n 0000283646 00000 n 0000283780 00000 n 0000283914 00000 n 0000284048 00000 n 0000284181 00000 n 0000284315 00000 n 0000284346 00000 n 0000248644 00000 n 0000011986 00000 n 0000012852 00000 n 0000284436 00000 n 0000284570 00000 n 0000284704 00000 n 0000284839 00000 n 0000284973 00000 n 0000285108 00000 n 0000285139 00000 n 0000248858 00000 n 0000012873 00000 n 0000016870 00000 n 0000307764 00000 n 0000345744 00000 n 0000285183 00000 n 0000285214 00000 n 0000249032 00000 n 0000016892 00000 n 0000021078 00000 n 0000285293 00000 n 0000285427 00000 n 0000285458 00000 n 0000249222 00000 n 0000021100 00000 n 0000026370 00000 n 0000285548 00000 n 0000285579 00000 n 0000249396 00000 n 0000026392 00000 n 0000030766 00000 n 0000306789 00000 n 0000337640 00000 n 0000285682 00000 n 0000285713 00000 n 0000249570 00000 n 0000030788 00000 n 0000034025 00000 n 0000305888 00000 n 0000326736 00000 n 0000285840 00000 n 0000285871 00000 n 0000249744 00000 n 0000034047 00000 n 0000038972 00000 n 0000304363 00000 n 0000322672 00000 n 0000304109 00000 n 0000322093 00000 n 0000285998 00000 n 0000286029 00000 n 0000249918 00000 n 0000038994 00000 n 0000042968 00000 n 0000286182 00000 n 0000286213 00000 n 0000250092 00000 n 0000042990 00000 n 0000047928 00000 n 0000286368 00000 n 0000286503 00000 n 0000286534 00000 n 0000250282 00000 n 0000047950 00000 n 0000049324 00000 n 0000286650 00000 n 0000286681 00000 n 0000250448 00000 n 0000049346 00000 n 0000055537 00000 n 0000303070 00000 n 0000315136 00000 n 0000286738 00000 n 0000286872 00000 n 0000286903 00000 n 0000250638 00000 n 0000055559 00000 n 0000059855 00000 n 0000287056 00000 n 0000287087 00000 n 0000250812 00000 n 0000059877 00000 n 0000064140 00000 n 0000287240 00000 n 0000287375 00000 n 0000287406 00000 n 0000250994 00000 n 0000064162 00000 n 0000069322 00000 n 0000287509 00000 n 0000287644 00000 n 0000287779 00000 n 0000287810 00000 n 0000251192 00000 n 0000069344 00000 n 0000073203 00000 n 0000287963 00000 n 0000287994 00000 n 0000251366 00000 n 0000073225 00000 n 0000077209 00000 n 0000288147 00000 n 0000288282 00000 n 0000288313 00000 n 0000251556 00000 n 0000077231 00000 n 0000080795 00000 n 0000288416 00000 n 0000288447 00000 n 0000251730 00000 n 0000080817 00000 n 0000085567 00000 n 0000288526 00000 n 0000288661 00000 n 0000288692 00000 n 0000251920 00000 n 0000085589 00000 n 0000088791 00000 n 0000288808 00000 n 0000288839 00000 n 0000252094 00000 n 0000088813 00000 n 0000093405 00000 n 0000288931 00000 n 0000289066 00000 n 0000289201 00000 n 0000289232 00000 n 0000252292 00000 n 0000093427 00000 n 0000094869 00000 n 0000289322 00000 n 0000289353 00000 n 0000252458 00000 n 0000094891 00000 n 0000096716 00000 n 0000289410 00000 n 0000289441 00000 n 0000252624 00000 n 0000096738 00000 n 0000097064 00000 n 0000289498 00000 n 0000289529 00000 n 0000252790 00000 n 0000097085 00000 n 0000100425 00000 n 0000289573 00000 n 0000289604 00000 n 0000252964 00000 n 0000100447 00000 n 0000103940 00000 n 0000289683 00000 n 0000289714 00000 n 0000253138 00000 n 0000103962 00000 n 0000106626 00000 n 0000289793 00000 n 0000289824 00000 n 0000253304 00000 n 0000106648 00000 n 0000109801 00000 n 0000289903 00000 n 0000289934 00000 n 0000253470 00000 n 0000109823 00000 n 0000113092 00000 n 0000290013 00000 n 0000290044 00000 n 0000253636 00000 n 0000113114 00000 n 0000117393 00000 n 0000290184 00000 n 0000290215 00000 n 0000253810 00000 n 0000117415 00000 n 0000120164 00000 n 0000290318 00000 n 0000290349 00000 n 0000253984 00000 n 0000120186 00000 n 0000120497 00000 n 0000290454 00000 n 0000290485 00000 n 0000254150 00000 n 0000120518 00000 n 0000122961 00000 n 0000290529 00000 n 0000290664 00000 n 0000290695 00000 n 0000254340 00000 n 0000122983 00000 n 0000127106 00000 n 0000290776 00000 n 0000290911 00000 n 0000291046 00000 n 0000291181 00000 n 0000291316 00000 n 0000291451 00000 n 0000291586 00000 n 0000291617 00000 n 0000254570 00000 n 0000127128 00000 n 0000128609 00000 n 0000291709 00000 n 0000291740 00000 n 0000254736 00000 n 0000128631 00000 n 0000132206 00000 n 0000291797 00000 n 0000291828 00000 n 0000254910 00000 n 0000132228 00000 n 0000135383 00000 n 0000291970 00000 n 0000292105 00000 n 0000292136 00000 n 0000255100 00000 n 0000135405 00000 n 0000135747 00000 n 0000292289 00000 n 0000292320 00000 n 0000255266 00000 n 0000135768 00000 n 0000139727 00000 n 0000292364 00000 n 0000292500 00000 n 0000292635 00000 n 0000292666 00000 n 0000255464 00000 n 0000139749 00000 n 0000143392 00000 n 0000292780 00000 n 0000292915 00000 n 0000292946 00000 n 0000255646 00000 n 0000143414 00000 n 0000147800 00000 n 0000293073 00000 n 0000293104 00000 n 0000255812 00000 n 0000147822 00000 n 0000152418 00000 n 0000293244 00000 n 0000293379 00000 n 0000293514 00000 n 0000293545 00000 n 0000256002 00000 n 0000152440 00000 n 0000156817 00000 n 0000293685 00000 n 0000293820 00000 n 0000293955 00000 n 0000294090 00000 n 0000294225 00000 n 0000294360 00000 n 0000294391 00000 n 0000256216 00000 n 0000156839 00000 n 0000161564 00000 n 0000294520 00000 n 0000294655 00000 n 0000294686 00000 n 0000256406 00000 n 0000161586 00000 n 0000166545 00000 n 0000294826 00000 n 0000294857 00000 n 0000256580 00000 n 0000166567 00000 n 0000171784 00000 n 0000294999 00000 n 0000295030 00000 n 0000256754 00000 n 0000171806 00000 n 0000174023 00000 n 0000295172 00000 n 0000295203 00000 n 0000256920 00000 n 0000174045 00000 n 0000174414 00000 n 0000295319 00000 n 0000295350 00000 n 0000257086 00000 n 0000174435 00000 n 0000178073 00000 n 0000295394 00000 n 0000295529 00000 n 0000295560 00000 n 0000257268 00000 n 0000178095 00000 n 0000182903 00000 n 0000295700 00000 n 0000295835 00000 n 0000295970 00000 n 0000296105 00000 n 0000296240 00000 n 0000296375 00000 n 0000296406 00000 n 0000257482 00000 n 0000182925 00000 n 0000184806 00000 n 0000296522 00000 n 0000296553 00000 n 0000257648 00000 n 0000184828 00000 n 0000188338 00000 n 0000296610 00000 n 0000296641 00000 n 0000257822 00000 n 0000188360 00000 n 0000192554 00000 n 0000296757 00000 n 0000296892 00000 n 0000297027 00000 n 0000297058 00000 n 0000258020 00000 n 0000192576 00000 n 0000194546 00000 n 0000297185 00000 n 0000297216 00000 n 0000258186 00000 n 0000194568 00000 n 0000198113 00000 n 0000297273 00000 n 0000297408 00000 n 0000297543 00000 n 0000297678 00000 n 0000297709 00000 n 0000258392 00000 n 0000198135 00000 n 0000198521 00000 n 0000297825 00000 n 0000297856 00000 n 0000258558 00000 n 0000198542 00000 n 0000203244 00000 n 0000297900 00000 n 0000297931 00000 n 0000258732 00000 n 0000203266 00000 n 0000208482 00000 n 0000298058 00000 n 0000298193 00000 n 0000298224 00000 n 0000258922 00000 n 0000208504 00000 n 0000213502 00000 n 0000298353 00000 n 0000298488 00000 n 0000298623 00000 n 0000298758 00000 n 0000298893 00000 n 0000298924 00000 n 0000259136 00000 n 0000213524 00000 n 0000218566 00000 n 0000299064 00000 n 0000299199 00000 n 0000299334 00000 n 0000299469 00000 n 0000299604 00000 n 0000299739 00000 n 0000299770 00000 n 0000259358 00000 n 0000218588 00000 n 0000224104 00000 n 0000299886 00000 n 0000299917 00000 n 0000259532 00000 n 0000224126 00000 n 0000228691 00000 n 0000300046 00000 n 0000300181 00000 n 0000300316 00000 n 0000300451 00000 n 0000300586 00000 n 0000300721 00000 n 0000300752 00000 n 0000259754 00000 n 0000228713 00000 n 0000235565 00000 n 0000300879 00000 n 0000301014 00000 n 0000301149 00000 n 0000301285 00000 n 0000301421 00000 n 0000301452 00000 n 0000259968 00000 n 0000235587 00000 n 0000237500 00000 n 0000301579 00000 n 0000301610 00000 n 0000260134 00000 n 0000237522 00000 n 0000238917 00000 n 0000301667 00000 n 0000301698 00000 n 0000260300 00000 n 0000238939 00000 n 0000240986 00000 n 0000301755 00000 n 0000301786 00000 n 0000260466 00000 n 0000241008 00000 n 0000245860 00000 n 0000301843 00000 n 0000301979 00000 n 0000302010 00000 n 0000260656 00000 n 0000245882 00000 n 0000246945 00000 n 0000302152 00000 n 0000302288 00000 n 0000302319 00000 n 0000309655 00000 n 0000315400 00000 n 0000316481 00000 n 0000322329 00000 n 0000322958 00000 n 0000324421 00000 n 0000327115 00000 n 0000333350 00000 n 0000337899 00000 n 0000339019 00000 n 0000346463 00000 n 0000354435 00000 n 0000356505 00000 n 0000302986 00000 n 0000303791 00000 n 0000303878 00000 n 0000304275 00000 n 0000304622 00000 n 0000304710 00000 n 0000305490 00000 n 0000306687 00000 n 0000307650 00000 n 0000308278 00000 n 0000309081 00000 n 0000378568 00000 n trailer << /Size 661 /Root 1 0 R /Info 2 0 R /ID [] >> startxref 380409 %%EOF ats-lang-anairiats-0.2.11/Makefile0000664000175000017500000001772412223166157015454 0ustar hwxihwxi######################################################################### ## ## ## Applied Type System ## ## ## ## Hongwei Xi ## ## ## ######################################################################### ## ## ATS/Anairiats - Unleashing the Potential of Types! ## ## Copyright (C) 2002-2008 Hongwei Xi. ## ## ATS is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free ## Software Foundation; either version 2.1, or (at your option) any later ## version. ## ## ATS is distributed in the hope that it will be useful, but WITHOUT ANY ## WARRANTY; without even the implied warranty of MERCHANTABILITY or ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ## for more details. ## ## You should have received a copy of the GNU General Public License ## along with ATS; see the file COPYING. If not, write to the Free ## Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ## 02110-1301, USA. ## ###### ## ## Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ## Author: Likai Liu (liulk AT cs DOT bu DOT edu) ## Author: Yuri D'Elia (wavexx AT thregr DOT org) ## .SUFFIXES: all:: Makefile ###### # integration with autoconf. SRC_CONFIG_FILES := config.mk.in config.h.in BUILT_CONFIG_FILES := $(SRC_CONFIG_FILES:%.in=%) Makefile: config.mk config.status: configure ./configure touch $@ $(BUILT_CONFIG_FILES): %: config.status $(filter-out %,$(SRC_CONFIG_FILES)) ./config.status touch $(BUILT_CONFIG_FILES) config.h.in: configure.ac autoheader $< touch $@ configure: configure.ac $(SRC_CONFIG_FILES) aclocal automake --add-missing --foreign || true autoconf touch $(BUILT_CONFIG_FILES) -include config.mk ###### DESTDIR := export ATSHOME export ATSHOMERELOC export ATSHOMEQ ###### bindir2=$(DESTDIR)$(bindir) ATSLIBHOME2=$(DESTDIR)$(ATSLIBHOME) ###### # # HX-2011-06-01: # This part is by Georg Bauhaus (bauhaus AT arcor DOT de): # It addresses the issue that the [-D] option is not available # for $(INSTALL) on MacOSX. # .PHONY: install_dirs install_dirs:: config.h # # make all subdirectories needed by install. # cd $(abs_top_srcdir) [ -d $(bindir2) ] || $(MKDIR_P) $(bindir2) $(MKDIR_P) $(ATSLIBHOME2)/bin find ccomp contrib doc libats libc prelude -type d \ -exec $(MKDIR_P) $(ATSLIBHOME2)/\{} \; \ -print install_files:: install_dirs # # recursively install all files in the list except .svn control files. # for d in ccomp/runtime contrib doc libats libc prelude; do \ cd $(abs_top_srcdir) && \ $(INSTALL) -d $(ATSLIBHOME2)/"$$d" && \ find "$$d" -name .svn -prune -o -type f \ -exec $(INSTALL) -m 644 \{} $(ATSLIBHOME2)/\{} \; \ -print && \ find "$$d" -name .svn -prune -o -type l \ -exec cp -d \{} $(ATSLIBHOME2)/\{} \; \ -print; \ done # # install specific files in the list as regular files. # for f in \ COPYING INSTALL *.txt ccomp/lib/*.a ccomp/lib64/*.a config.h; \ do \ [ -f "$$f" ] || continue; \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 644 "$$f" $(ATSLIBHOME2)/"$$f" && \ echo "$$f"; \ done # # install specific files in the list as executables. # for f in bin/*; do \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 755 "$$f" $(ATSLIBHOME2)/"$$f" && \ echo "$$f"; \ done # # install multiple copies of wrapper script, for each binary. # for f in bin/*; do \ b=`basename "$$f"`; \ cd $(abs_top_srcdir) && \ $(INSTALL) -m 755 ats_env.sh $(bindir2)/"$$b" && \ echo [ats_env.sh] is installed into $(bindir2)/"$$b"; \ done install:: install_files ###### all:: \ atsopt1 \ bin/atscc \ bin/atslib \ libfiles \ libfiles_mt \ bin/atspack \ libatsdoca \ ccomp/runtime/GCATS/gc.o \ ccomp/runtime/GCATS/gc_mt.o \ atsopt1_gc \ bin/atslex \ bin/atsdoc \ contrib @echo "ATS/Anairiats has been built up successfully!" @echo "The value of ATSHOME for this build is \"$(ATSHOME)\"." @echo "The value of ATSHOMERELOC for this build is \"$(ATSHOMERELOC)\"." ###### w/o GC ###### atsopt1:: $(MAKE) -C bootstrap1 -f ../Makefile_bootstrap BOOTSTRAP1=1 atsopt cp bootstrap1/atsopt $(ATSHOMEQ)/bin/atsopt ###### with GC ###### atsopt1_gc:: $(MAKE) -C bootstrap1 -f ../Makefile_bootstrap BOOTSTRAP1=1 atsopt_gc cp bootstrap1/atsopt_gc $(ATSHOMEQ)/bin/atsopt ###### contrib libraries ###### contrib:: # ifeq (1,1) # $(MAKE) -C contrib/parcomb all # endif # ifeq ($(HAVE_LIBGLIB20),1) # $(MAKE) -C contrib/glib all # endif # ifeq ($(HAVE_LIBGTK20),1) # $(MAKE) -C contrib/cairo all # $(MAKE) -C contrib/pango all # $(MAKE) -C contrib/GTK all # endif # ifeq ($(HAVE_LIBSDL10),1) # $(MAKE) -C contrib/SDL all # endif ###### some toplevel commands ###### bin/atscc bin/atslib: $(MAKE) -C utils/scripts atscc $(CPF) utils/scripts/atscc $(ATSHOMEQ)/bin $(MAKE) -C utils/scripts atslib $(CPF) utils/scripts/atslib $(ATSHOMEQ)/bin $(MAKE) -C utils/scripts clean bin/atspack: $(MAKE) -C utils/scripts atspack cp utils/scripts/atspack $(ATSHOMEQ)/bin ###### library ###### ATS_PROOFCHECK= # # ATS_PROOFCHECK=-D_ATS_PROOFCHECK # it should be turned on from time to time # # [CC -E] for preprocessing # ATSLIB=$(ATSHOMEQ)/bin/atslib .libfiles_local: .libfiles ; $(CC) -E -P -x c -o $@ $< libfiles: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -O2 --libats_smlbas lib32files: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -m32 -O2 --libats_smlbas lib64files: .libfiles_local $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats_lex $(ATSLIB) $(ATS_PROOFCHECK) -m64 -O2 --libats_smlbas .libfiles_mt_local: .libfiles_mt ; $(CC) -E -P -x c -o $@ $< libfiles_mt: .libfiles_mt_local $(ATSLIB) $(ATS_PROOFCHECK) -D_ATS_MULTITHREAD -O2 --libats_mt libatsdoca: ; $(MAKE) -C libatsdoc ###### a lexer for ATS ###### bin/atslex: cd utils/atslex; $(MAKE) atslex; cp atslex $(ATSHOMEQ)/bin cd utils/atslex; $(MAKE) clean ###### GC runtime ###### bin/atsdoc: cd utils/atsdoc; $(MAKE) atsdoc; cp atsdoc $(ATSHOMEQ)/bin cd utils/atsdoc; $(MAKE) clean ###### GC runtime ###### ccomp/runtime/GCATS/gc.o: cd ccomp/runtime/GCATS; $(MAKE) gc.o; $(MAKE) clean ccomp/runtime/GCATS/gc_mt.o: cd ccomp/runtime/GCATS; $(MAKE) gc_mt.o; $(MAKE) clean ###### CPF=cp -f RMF=rm -f ###### clean:: $(RMF) bootstrap1/*.o $(MAKE) -C utils/scripts clean $(MAKE) -C utils/atslex clean $(MAKE) -C utils/atsdoc clean $(MAKE) -C ccomp/runtime/GCATS clean cleanall:: $(RMF) bootstrap1/*.o $(RMF) $(BUILT_CONFIG_FILES) $(RMF) .libfiles_local $(RMF) .libfiles_mt_local $(RMF) bin/atsopt bin/atscc bin/atslib $(RMF) bin/atspack bin/atslex bin/atsdoc $(RMF) ccomp/lib/libats.a $(RMF) ccomp/lib/libats_mt.a $(RMF) ccomp/lib/libats_lex.a $(RMF) ccomp/lib/libats_smlbas.a $(RMF) ccomp/lib/libatsdoc.a $(RMF) ccomp/lib/output/* $(RMF) ccomp/lib64/libats.a $(RMF) ccomp/lib64/libats_mt.a $(RMF) ccomp/lib64/libats_lex.a $(RMF) ccomp/lib64/libats_smlbas.a $(RMF) ccomp/lib64/libatsdoc.a $(RMF) ccomp/lib64/output/* $(RMF) contrib/glib/atsctrb_glib.o $(RMF) contrib/cairo/atsctrb_cairo.o $(RMF) contrib/pango/atsctrb_pango.o $(RMF) contrib/X11/atsctrb_X11.o $(RMF) contrib/GTK/atsctrb_GTK.o $(RMF) contrib/GL/atsctrb_GL.o $(RMF) contrib/GL/atsctrb_glut.o $(RMF) contrib/GL/atsctrb_gtkglext.o $(RMF) contrib/SDL/atsctrb_SDL.o cleanall:: ; $(MAKE) -C utils/atslex cleanall cleanall:: ; $(MAKE) -C utils/scripts cleanall cleanall:: ; $(MAKE) -C ccomp/runtime/GCATS cleanall distclean:: cleanall distclean:: ; find . -name .svn -prune -o -name \*~ -exec rm \{} \; ###### # # end of [Makefile_dist] # ###### ats-lang-anairiats-0.2.11/bin/0000700000175000017500000000000012223166157014535 5ustar hwxihwxiats-lang-anairiats-0.2.11/bin/.keeper0000664000175000017500000000006112223166157016022 0ustar hwxihwxi// for keeping the directory from being removed. ats-lang-anairiats-0.2.11/ats_env.sh.in0000664000175000017500000000117312223166157016403 0ustar hwxihwxi#!/bin/sh # # Author: Likai Liu (likai AT cs DOT bu DOT edu) # PACKAGE_TARNAME=@PACKAGE_TARNAME@ PACKAGE_VERSION=@PACKAGE_VERSION@ prefix=@prefix@ export ATSHOME="${prefix}/lib/${PACKAGE_TARNAME}-${PACKAGE_VERSION}" export ATSHOMERELOC="ATS-${PACKAGE_VERSION}" if [ ! -d "$ATSHOME" ]; then echo "ATS must be installed at '$ATSHOME'" exit 1 fi prog=`basename $0` case $prog in ats_env.sh) echo "This is a wrapper script for atscc, atslib, and atsopt." echo "The script should be symbolic linked from these aliases." exit 1 ;; *) exec "$ATSHOME/bin/$prog" "$@" ;; esac # # end of [ats_env.sh.in] # ats-lang-anairiats-0.2.11/.libfiles0000664000175000017500000002126712223166157015603 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ** This file is to be preprocessed to generate .libfiles_local, which is ** needed by [atslib] for building libats.a ** */ /* ****** ****** */ #include "config.h" /* ****** ****** */ prelude/basics_sta.sats prelude/basics_dyn.sats prelude/ats_main_prelude.dats /* ****** ****** */ /* PRELUDE files */ /* ****** ****** */ /* ** primary */ // prelude/DATS/basics.dats // prelude/DATS/bool.dats prelude/DATS/char.dats // prelude/DATS/integer.dats prelude/DATS/sizetype.dats // prelude/DATS/float.dats // prelude/DATS/pointer.dats // prelude/DATS/reference.dats // prelude/DATS/string.dats // prelude/SATS/lazy.sats prelude/DATS/lazy.dats // prelude/SATS/lazy_vt.sats prelude/DATS/lazy_vt.dats // prelude/DATS/printf.dats prelude/DATS/filebas.dats // prelude/SATS/extern.sats /* for building external API's */ // /* ****** ****** */ /* ** secondary */ prelude/SATS/arith.sats prelude/DATS/arith.dats // prelude/SATS/array.sats prelude/DATS/array.dats prelude/DATS/array_prf.dats prelude/SATS/array0.sats prelude/DATS/array0.dats // prelude/SATS/list.sats prelude/DATS/list.dats prelude/SATS/list_vt.sats prelude/DATS/list_vt.dats prelude/SATS/list0.sats prelude/DATS/list0.dats // prelude/SATS/dlist_vt.sats prelude/DATS/dlist_vt.dats // prelude/SATS/matrix.sats prelude/DATS/matrix.dats prelude/SATS/matrix0.sats prelude/DATS/matrix0.dats // prelude/SATS/number.sats /* prelude/HATS/number_hats.dats */ // prelude/SATS/option.sats prelude/DATS/option.dats prelude/SATS/option_vt.sats prelude/DATS/option_vt.dats prelude/SATS/option0.sats prelude/DATS/option0.dats // prelude/SATS/ptrarr.sats prelude/DATS/ptrarr.dats // prelude/SATS/syndef.sats prelude/DATS/syndef.dats // prelude/SATS/unsafe.sats prelude/DATS/unsafe.dats // /* ****** ****** */ /* LIBC files */ /* ****** ****** */ #ifdef HAVE_COMPLEX_H libc/SATS/complex.sats libc/DATS/complex.dats #endif libc/SATS/ctype.sats #ifdef HAVE_CURSES_H libc/SATS/curses.sats #endif libc/SATS/dirent.sats libc/DATS/dirent.dats libc/SATS/dlfcn.sats libc/DATS/dlfcn.dats libc/SATS/errno.sats libc/SATS/fcntl.sats libc/DATS/fcntl.dats #ifdef HAVE_GMP_H libc/SATS/gmp.sats libc/DATS/gmp.dats #endif libc/SATS/grp.sats libc/SATS/math.sats libc/DATS/math.dats libc/SATS/float.sats libc/SATS/netdb.sats libc/SATS/printf.sats libc/DATS/printf.dats libc/SATS/pwd.sats libc/SATS/random.sats -D_XOPEN_SOURCE libc/DATS/random.dats -D_XOPEN_SOURCE libc/SATS/sched.sats libc/SATS/signal.sats libc/SATS/stdarg.sats /* libc/DATS/stdarg.dats */ libc/SATS/stdio.sats libc/DATS/stdio.dats libc/SATS/stdlib.sats libc/DATS/stdlib.dats libc/SATS/string.sats libc/DATS/string.dats libc/SATS/strings.sats libc/SATS/time.sats libc/SATS/termios.sats libc/SATS/unistd.sats libc/SATS/unistd_pathconf.sats libc/SATS/unistd_sysconf.sats libc/DATS/unistd.dats libc/SATS/utime.sats /* ****** ****** */ libc/sys/SATS/select.sats libc/sys/SATS/sockaddr.sats libc/sys/SATS/socket.sats libc/sys/DATS/socket.dats libc/sys/SATS/socket_in.sats libc/sys/DATS/socket_in.dats libc/sys/SATS/socket_un.sats libc/sys/DATS/socket_un.dats libc/sys/SATS/stat.sats libc/sys/DATS/stat.dats libc/sys/SATS/statvfs.sats libc/sys/SATS/time.sats libc/sys/SATS/types.sats libc/sys/SATS/un.sats libc/sys/SATS/utsname.sats libc/sys/SATS/wait.sats /* ****** ****** */ libc/arpa/SATS/inet.sats libc/netinet/SATS/in.sats /* ****** ****** */ /* libc/dynloadall.dats */ /* ****** ****** */ /* LIBATS files */ /* ****** ****** */ /* biarray (bidirectional array) implementation */ libats/SATS/biarray.sats libats/DATS/biarray.dats /* bimatrix (bidirectional matrix) implementation */ libats/SATS/bimatrix.sats libats/DATS/bimatrix.dats /* FORTRAN matrix: column-major */ libats/SATS/fmatrix.sats libats/DATS/fmatrix.dats /* FREE LIST implementation */ libats/SATS/freelst.sats libats/DATS/freelst.dats /* functional array implementation based on Braun trees */ libats/SATS/funarray_braun.sats libats/DATS/funarray_braun.dats /* functional deque implementation based on finger trees */ libats/SATS/fundeque_fingertree.sats libats/DATS/fundeque_fingertree.dats /* functional heap implementation based on Braun trees */ libats/SATS/funheap_braun.sats libats/DATS/funheap_braun.dats /* functional heap implementation based on binomial trees */ libats/SATS/funheap_binomial.sats libats/DATS/funheap_binomial.dats /* functional map implementation based on AVL trees */ libats/SATS/funmap_avltree.sats libats/DATS/funmap_avltree.dats /* functional map implementation based on red-black trees */ libats/SATS/funmap_rbtree.sats libats/DATS/funmap_rbtree.dats /* functional set implementation based on AVL trees */ libats/SATS/funset_avltree.sats libats/DATS/funset_avltree.dats /* functional set implementation based on ordered lists */ libats/SATS/funset_listord.sats libats/DATS/funset_listord.dats /* functional mset implementation based on ordered lists */ libats/SATS/funmset_listord.sats libats/DATS/funmset_listord.dats /* functional random-access list based on a nested datatype */ libats/SATS/funralist_nested.sats libats/DATS/funralist_nested.dats /* // // HX-2010-12-28: should these be included? // libats/SATS/gfarray.sats libats/DATS/gfarray.dats libats/SATS/gflist.sats libats/DATS/gflist.dats libats/SATS/gftree.sats libats/DATS/gftree.dats */ /* generic arrays of various dimensions */ libats/SATS/genarrays.sats libats/DATS/genarrays.dats /* hashtable implementation based on separate chaining */ libats/SATS/hashtable_chain.sats libats/DATS/hashtable_chain.dats /* hashtable implementation based on linear probing */ libats/SATS/hashtable_linprb.sats libats/DATS/hashtable_linprb.dats #ifdef HAVE_GMP_H libats/SATS/intinf.sats libats/DATS/intinf.dats #endif libats/SATS/iterint.sats libats/DATS/iterint.dats /* linear bit vector implementation */ libats/SATS/linbitvec.sats libats/DATS/linbitvec.dats /* linear heap implementation based on binomial trees */ libats/SATS/linheap_binomial.sats libats/DATS/linheap_binomial.dats /* linear map implementation based on AVL trees */ libats/SATS/linmap_avltree.sats libats/DATS/linmap_avltree.dats /* linear map implementation based on red-black trees */ libats/SATS/linmap_rbtree.sats libats/DATS/linmap_rbtree.dats /* linear map implementation based on skip-lists */ libats/SATS/linmap_skiplist.sats libats/DATS/linmap_skiplist.dats /* linear set implementation based on AVL trees */ libats/SATS/linset_avltree.sats libats/DATS/linset_avltree.dats /* linear set implementation based on ordered lists */ libats/SATS/linset_listord.sats libats/DATS/linset_listord.dats /* ** linear ordset implementation based on randomized bstrees ** note that the flag __USE_MISC needs to be set in order to ** gain access to the type 'struct drand48_data' */ libats/SATS/linordset_randbst.sats -D_XOPEN_SOURCE -D_BSD_SOURCE libats/DATS/linordset_randbst.dats -D_XOPEN_SOURCE -D_BSD_SOURCE /* linear array-based queue implementation */ libats/SATS/linqueue_arr.sats libats/DATS/linqueue_arr.dats /* linear list-based queue implementation */ libats/SATS/linqueue_lst.sats libats/DATS/linqueue_lst.dats /* linear array-based stack implementation */ libats/SATS/linstack_arr.sats libats/DATS/linstack_arr.dats /* rarray (reversed array) implementation */ libats/SATS/rarray.sats libats/DATS/rarray.dats /* reference counting (effectful) implementation */ libats/SATS/refcount.sats libats/DATS/refcount.dats /* reference counting (reentrant) implementation */ /* libats/SATS/refcountr.sats libats/DATS/refcountr.dats */ #ifdef HAVE_PCRE_H libats/SATS/regexp.sats libats/DATS/regexp.dats #endif /* dynamically resizable array implementation */ libats/SATS/vector.sats libats/DATS/vector.dats /* ****** ****** */ /* linear array-based queue implementation */ libats/ngc/SATS/deque_arr.sats libats/ngc/DATS/deque_arr.dats /* linear singly-linked lists */ libats/ngc/SATS/slist.sats libats/ngc/DATS/slist.dats /* ** AS-2011: ** linear doubly-linked lists */ libats/ngc/SATS/dlist.sats libats/ngc/DATS/dlist.dats /* ** AS-2012-01: ** linear avltree-based maps */ libats/ngc/SATS/linmap_avltree.sats libats/ngc/DATS/linmap_avltree.dats /* ** AS-2012-02: ** linear pavltree-based maps */ libats/ngc/SATS/linmap_pavltree.sats libats/ngc/DATS/linmap_pavltree.dats /* ****** ****** */ /* libats/dynloadall.dats */ /* ****** ****** */ /* end of [.libfiles] */ ats-lang-anairiats-0.2.11/VERSION.txt0000664000175000017500000004236712223166157015703 0ustar hwxihwxi0.2.11
ats-lang-anairiats-0.2.11:

The primary purpose of this release is to push out a version of ATS
that can be used to compile ATS2, the successor of ATS. It is planned
that the development of ATS is to be freezing gradually. In general,
only changes that help the development of ATS2 can be chosen to be added
into ATS.

For the current users of ATS, it is about the time to make a swtich to
ATS2.  As always, I certainly hope that you will be able to unleash the
great potentials of the type system and template system of ATS2.

Happy programming!
###### 0.2.10
ats-lang-anairiats-0.2.10:

The primary purpose of this release is to push out a version of ATS that
can be used to compile ATS2, the successor of ATS that is planned to be
released by the end of August, 2013.

In this version of ATS, various packages in ${ATSHOME}/contrib (e.g., glib
and GTK) are no longer compiled automatically. If needed, please use the
provided Makefiles to compile them manually.

For the current users of ATS, it is time to make a swtich to ATS2. I
certainly hope that you will be able to unleash the great potentials of the
type system and template system of ATS2. Happy programming!
###### 0.2.9
ats-lang-anairiats-0.2.9:

1. Fixing some macros in ccomp/runtime/ats_exception.h
2. Removing the field tmpvar_root in tmpvar and related functions.
3. Adding support for using CMake to build projects written in ATS.
   Kudos to Hanwen!
4. $showtype support for debugging is added (2012-11-24)
5. Adding libats/linmap_skiplist for linear maps based on skip-lists.
6. ((, ..., )) -> @(, ..., )
7. If the assigned external name of a function is empty, then its
   internal name should be used in the place where its external name
   is needed. For example, the following declarations are equivalent:
   fun foo (x: int): void = "ext#"
   fun foo (x: int): void = "ext#foo"
   The following two are equivalent as well:
   fun bar (x: int): void = "mac#"
   fun bar (x: int): void = "mac#bar"
###### 0.2.8
ats-lang-anairiats-0.2.8:

1. Fixing a bug involving assumed abstract types.
2. Adding list_mapopt_* functions.
3. Packaging libatsdoc into ATS-0.2.8
4. Packaging utils/atsdoc into ATS-0.2.8
5. Adding contrib/mysql
6. Adding contrib/jansson (based on previous work by Chris Double)
###### 0.2.7
ats-lang-anairiats-0.2.7:

1. free_gc_viewt0ype_addr_view -> free_gc_t0ype_addr_view
   free_gc_viewt0ype_int_addr_view -> free_gc_t0ype_int_addr_view
2. ptr_free and array_ptr_free: interface change
3. Adding funheap_binomial and linheap_binomial
4. Adding libats/SATS/bimatrix.sats. Thanks to Artyom!
5. The s2exp_syneq function (syn. eq.) now employs eta-expansion
6. !READ(string) -> string (SHARED is introduced to do the opposite)
7. Adding libats/lockptr_spin and libats/lockref_spin (spinlocks)
8. The docbook source for the ATS intro book is now included.
9. The closures in each infile object are made to be linear and they
   are freed when the infile object is freed.
10. The compiler now generates code to prevent an abstract type from
    being implemented (assumed) more than once.
11. && and || are now macros (long overdue!)
12. The libats/ngc/linmap_pavltree package is added. Kudos to Artyom!
13: Adding libats/funmset_listord (functional multiset implementation)
14: Fixing a bug involving tailcall optimization (argument movement)
15: Fixing a minor bug involving p2at_arg_tr.
###### 0.2.6
ats-lang-anairiats-0.2.6:

1. Adding contrib/JNI for interfacing ATS with Java.
2. Adding the --xrefprelude flag to make cross-referencing work again.
3. The keyword [sta] can now also be written as [stacst].
4. If a name refers to several static constants, then the latest declared
   non-functional one is chosen (if there is one).
5. The tutorial (doc/TUTORIAL) is no longer put into the release package.
6. Allowing #FILENAME and #LOCATION to be used as e0xp. For instance, the
   following line is now legal:
   #print (#FILENAME)
7. Fixing a bug related to xref that caused illegal xhtml files to be
   generated (cases of A elements being embedded inside another A element).
   Thanks, David!
8. Introducing ISALIGNED to handle alignment.
9. Introducing NULLABLE to handle ptr_zero and ptr_zero_tsz.
10. Adding libats/funmap_rbtree (functional maps based on red-black trees)
11. Adding contrib/gtkglext (based on gtkglext-1.0)
12. Adding contrib/atspslide for doing slide presentation and other things.
13: Adding libc/gdbm/gdbm (API for gdbm in ATS).
14: Adding libc/gdbm/ndbm (API for gdbm-ndbm in ATS).
15: Adding libats/ngc/DATS/dlist.dats. Thanks to Artyom!
16: [atslib] can now process flags for each individual file. See .libfiles.
17: pervasive changes: free_gc_v (T, ...) => free_gc_v (T?, ...)

###### 0.2.5
ats-lang-anairiats-0.2.5:

1. Fixing a bug in handling call-by-reference. I was really surprised that
   the bug had not shown up earlier.
2. input_line_vt is added in prelude/filebas for returning a linear string
3. Fixing a bug in [valprim_is_mutable]: casting was incorrectly handled.
4. atslib_feof and atslib_ferror are changed to inlined functions (instead
   of macros). This is done to fix Cgwin's defining feof as a macro.
5. Some changes are made to support ATS on FreeBSD.
6. Fixing a bug involving linear closures (of the form ).
7. Adding support for if!: if! (e_cond, e_then, e_else) is for the
   following expression: (if e_cond then e_then else e_else).
8. Adding libats/funset_avltree to support (functional) sets.
9. The original *_clo and *_cloptr functions are renamed as *_vclo and
   *_vcloptr respectively, and the new *_clo and *_cloptr functions no
   longer require a (linear) proof argument.
10. [gc_stack_get_dir] is re-written to fix a bug triggered due to a form
    of over-optimization by gcc-4.6: a volatile function may get inlined.
    Kudos to Matthew for helping me on this one!
11. Fixing a bug that wrongly affected the exn-effect tracking.
12. Adding contrib/GLES2 to support OpenGL/ES2 binding. Thanks to Artyom!
13. Renaming: list_vt_*_clo -> list_vt_*_vclo. Also adding various functions:
    list_vt_*_cloptr and list_vt_*_vcloptr
14. Makefile_macosx is added for building ATS on MAC OS X. Thanks to Georg!
15. Renaming (in various packages): *_clo -> *_vclo and *_cloptr -> *_vcloptr
16. Adding libatsdoc.
17. Adding the [atsdoc] utility for writing documents
18. Adding atsdoc/DOCUMENT/TUTORIALATS
19. Finishing part 3 of the book on Introduction to Programming in ATS
20. Adding contrib/atswebpage for helping build webpages
21. Adding util/atsdoc/DOCUMENT/atslangweb for creating webpages for ATS
###### 0.2.4
ats-lang-anairiats-0.2.3:

1. Adding the package contrib/testing to facilitate construction of
   testing code.
2. Adding support for value templates.
3. Adding various examples in doc/EXAMPLE/PCPV to demonstrate a style
   of program verification that is described as being programmer-centric.
4. Adding the package contrib/scripting to support scripting in ATS.
5. Bison is now the default tool for generate [ats_grammar_yats.c].
6. Adding some functions in prelude/list.
7. Adding some functions in prelude/lazy_vt.
8. ATS/Anairiats is kept up-to-date for bootstrapping.
9. $ATSHOME/contrib/glib/glist: overhauling many function interfaces.
10. The file ats_fixity.dats is splitted into the following two files:
    ats_fixity_prec.dats and ats_fixity_fxty.dats.
11. Adding some functions for parsing various syntax trees.
12. Renaming various 'get' and 'set' functions according to some adopted
    naming convention.
13. Starting to build API in $ATSHOME/contrib/linux for supporting linux
    kernel programming. This is going to be a long journey!
14: Renaming: fun__main -> funenv
    Renaming: fun_tsz__main -> funenv_tsz
    Renaming: clo_tsz__main -> cloenv_tsz
    Renaming: __main -> _funenv (for various higher-order functions)
15: matrix_v (a, m, n, l) is now defined as mtrxt (a, m, n) @ l
16: stack-allocated closures are now statically allocated (instead of
    being dynamically allocated via alloca) (svn-version: 2519)
17: prelude/array and prelude/matrix have been cleaned up considerably
18: naming change: "#foo" -> "mac#foo" (for external macros)
19: using names like "sta#foo" to support external static functions
20: adding contrib/linux to support linux kernel programming (very long term)
21: adding libats/ngc/deque_arr
22: basing libats/linqueue_arr and libats/linstack_arr on libats/ngc/deque_arr
24. ATSstaticdec() and ATSglobaldec() are now employed in emitted C code
    for indicating whether a function is global or static.
25. reloading a pervasive .sats file is allowed; doing so is like a no-op.
###### 0.2.3
ats-lang-anairiats-0.2.3:

As usual, this release contains a large number of fixes. There is
also a lot effort going into documentation. In particular, the grammar
of ATS (ats_grammar.yats) is cleaned considerably.

A (partial) list of the changes since the last release are given as
follows:

1. Adding READ: READ(string) is read-only!
2. Renaming prelude/?ATS/file.?ats to prelude/?ATS/filebas.?ats
3. Adding support -DATS flags: -DATSXYZ=12345 or -DATS XYZ=12345
4. Adding support for ATS/Anairiats to output #line pragma in the C code
   generated by atsopt.
5. Adding support for compiling fixed-point expressions (constructed via
   fix and @fix).
6. Introducing various macros in ccomp/runtime/ats_basics.h to give more
   structure to the C code generated by atsopt.
7. Introducing block expressions: { decseq_syn }
8. Supporting syndef-loaded external identifers
9. DO and WHILE are external ids: both while-loop and do-while-loop are
   supported.
10. print! and println! are now supported.
11. fprint! and fprintln! are now supported.
12. tupz! is now supported.
13. $ATSHOME/utils/atsgrammar is added for documenting the grammar of ATS.
14. Implementing the $ATSHOME/libats/fundeque_fingertree package.
15. "><" (GTLT) can now be used as a dynamic identifier.
16. Syntax like [val  = ] is now ruled out: 'val' needs to be
    replaced with 'prval'.
17. Removing named types (S2Enamed), which is inadequate for its purpose
18. S2Eextype can now carry arguments
19. overhauling partial template implementation
20. ptrout -> vptrout and ptroutopt -> vptroutopt
21. ptropt_v -> optvar_v
22. [ptrself] is introduced as a named type of the name "ats_ptrself_type"
23. The '$fun' suffix is no longer in use. If a function is declared as a
    'val', then the function is now treated as an ordinary value.
###### 0.2.2
ats-lang-anairiats-0.2.2:

As usual, this release contains a large number of fixes. Also, many new
coding examples are added. Compared to the previous version, the ATS
interface for libc functions is greatly extended, and there are now many
examples involving systems programming that are available in the following
directory:

$ATSHOME/doc/EXAMPLES/AUP/.

A (partial) list of the changes since the last release are given as
follows:

1. -D_ATS_TERMINATION_CHECK is changed to -D_ATS_PROOFCHECK; fixing a
   related bug in [d3explst_funarg_tr].
2. Fixing a bug involving type-checking variadic functions
3. Fixing a bug involving solving top-level constraints
4. $ATSHOME/libc/SATS/complex.sats and $ATSHOME/libc/DATS/complex.dats
   are compiled and then added to libats.a
5. Adding support for #undef
6. Thoroughly testing the support for ATS running on Cygwin
7. Implementing libats/vector (dynamically resizable vectors)
8. $ATSHOME may now contain the space character (' ').
9. Fixing a bug involving mishandling of proofs during proof erasure
   (ats_trans4)
10. Fixing a bug involving mishandling negative long integers
11. Adding rarray (reversed array) implementation
12. Adding libc/pwd, which correspond to pwd.h
13. Adding libc/grp, which correspond to grp.h
14. Adding libc/termios, which corresponds to termios.h
15. Adding libc/curses, which corresponds to curses.h
16. Adding libc/utime, which corresponds to utime.h
17. Adding libc/sys/statvfs, which corresponds to sys/statvfs.h
18. Adding libc/ctype, which corresponds to ctype
19. Adding libc/DATS/stdio.dats
20. Modifying the types for malloc_ngc and free_ngc
21. Clearing up libc/pthread and libc/pthread_uplock
22. Implementing lib/pthread_upbarr
23. Incorporating [parcomb] into $ATSHOME/contrib
24. Adding libc/sys/resource, which corresponds to sys/resource.h
25. Adding [assertloc] macdef
26: Adding libc/sys/socket_in and libc/sys/socket_un
27: Adding libc/netdb
28. Adding libc/sys/sockaddr and libc/sys/sockopt
29: Adding prelude/unsafe!!!
30: Adding libats/ptrarr (* for arrays ending with a null ptr *)
###### 0.2.1
ats-lang-anairiats-0.2.1:

As usual, this release contains many bug fixes. Also, many
new coding examples are added.

1. The support for 'atsopt --depgen' is revamped.
2. The support for boolean patterns is made available.
3. Most string-generating functions now return linear strings
   (strptr). This is a change that can have pervasive impact.
4. Some support for GMP/MPQ and GMP/MPF functions are added. See
   libc/SATS/gmp.sat for details.
5. Overhauling the ATS building system.

The following packages are available in ATS/libats:

fmatrix.sats
freelst.sats
funralist_nested.sats
genarrays.sats
hashtable_chain.sats
hashtable_linprb.sats
intinf.sats
iterint.sats
linbitvec.sats (newly added)
linmap_avltree.sats
linqueue_arr.sats
linqueue_lst.sats
linstack_arr.sats
parworkshop.sats
regexp.sats

The following libraries are available in ATS/contrib:

glib
cairo
pango
X11
GTK
GL (OpenGL, GLU and GLUT)
SDL
cURL (only a few functions are available)
Clutter (this one is mostly for experiment)
cblas (joint work with Shivkumar Chandrasekaran)
clapack (joint work with Shivkumar Chandrasekaran)

ATS-0.2.1 bootstrapping times: machine: wildwest@bu.edu model name: Intel(R) Xeon(R) CPU X5570 @ 2.93GHz ats-geizella: 106.902u 21.036s 3:18.53 64.4% 0+0k 42568+441192io 0pf+0w ats-anairiats: 109.940u 29.698s 3:39.33 63.6% 0+0k 57656+568048io 0pf+0w ###### 0.2.0
ats-lang-anairiats-0.2.0:

This is a milestone release. The original plan for OOP support in ATS has
been scratched completely, resulting in about 1500 lines of code being
removed. Instead, some support is added to interface ATS with external code
written in OOP-style.

The following libraries are now available for use:

contrib/glib
contrib/cairo
contrib/pango
contrib/X11
contrib/GTK
contrib/GL (OpenGL, GLU and GLUT)
contrib/SDL

Much more effort is needed to expand the APIs for these libraries. So far,
only the API for cairo is close to completion.
###### 0.1.9
ats-lang-aniriats-0.1.9:

As usual, this release contains many bug fixes. The most notable
addition is a package named 'parworkshop' in $ATSHOME/libats, which
provides some rudimentary support for multicore programming (SMP).
Please see $ATSHOME/doc/EXAMPLE/MULTICORE for some examples.

(*
// this feature is retracted as it is difficult to support
1. overloaded symbols in a macro definition is re-loaded when the macro
   definition is expanded. This change can greatly facilitate the use of
   macros defined in $ATSHOME/prelude/macrodef.sats

2. macro expansion is now handled by [d1exp_tr] in [ats_trans2_dyn1.dats]
   (instead of being done by [d2exp_tr] in [ats_trans3_dyn2.dats])
*)

3. The semantics for symbol overloading is greatly simplified.
4. Adding libc/sched based on /usr/include/sched.x
5. Adding libats/parworkshop to support multicore programming.
6. The examples in doc/EXAMPLE/MULTICORE are modified to run again.
7. Adding support for lliunt and ullint.

......

###### 0.1.8
ats-lang-aniriats-0.1.8:

As usual, this release contains many bug fixes.

Also, the following external package is added into ATS for supporting
programming with Xlib:

$ATSHOME/contrib/X11

Moreover, the following external packages in ATS have been significantly
extended:

$ATSHOME/contrib/GL
$ATSHOME/contrib/cairo
$ATSHOME/contrib/SDL
###### 0.1.7
ats-lang-aniriats-0.1.7:

As usual, this release contains a large number of bug fixes. Also,
the following external packages have been made available for doing
graphics in ATS:

$ATSHOME/contrib/GL
$ATSHOME/contrib/cairo
$ATSHOME/contrib/SDL
###### 0.1.6
ats-lang-aniriats-0.1.6:

As usual, this release contains a large number of bug fixes. Some of the
significant changes are listed as follows:

1. Support for OOP is under development. So far, typechecking is done.
2. Type error message reporting is made more informative. This is ongoing.
3. Adding $ATSHOME/ccomp/lib64 for storing libfiles for 64-bit machines.
4. The Makefile in $ATSHOME is re-designed by Likai Liu. It now allows
   ATS to be installed in a selected directory. Just issue the following
   command before calling 'make':

./configure --prefix=<DESTDIR>

   where <DESTDIR> is the directory for final installation. After 'make'
   is done, please call 'make install'.

###### 0.1.6-unstable 0.1.5 0.1.5-unstable 0.1.4 0.1.4-unstable 0.1.3 0.1.3-unstable 0.1.2 0.1.2-unstable 0.1.1 0.1.1-unstable 0.1.0 0.1.0-unstable 0.0.2 0.0.2-unstable 0.0.1 beta alpha ###### version number usage ##### x.y.z -> x.y.z' : (z' = z + 1) mostly bug fixes; full backward compatibilities are expected. x.y.z -> x.y'.0 : (y' = y + 1) mostly minor changes; backward compatibilities are expected in general. x.y.z -> x'.0.0 : (x' = x + 1) a major change; some backward incompatibilities may appear. ###### end of [VERSION.txt] ###### ats-lang-anairiats-0.2.11/.libfiles_mt0000664000175000017500000000220712223166157016274 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ** This file is to be preprocessed to generate .libfiles_mt_local, which ** is needed by [atslib] for building libats_mt.a ** */ /* ****** ****** */ #include "config.h" /* ****** ****** */ libc/SATS/pthread.sats libc/DATS/pthread.dats libc/SATS/pthread_uplock.sats libc/DATS/pthread_uplock.dats libc/SATS/pthread_upbarr.sats libc/DATS/pthread_upbarr.dats /* ****** ****** */ libats/SATS/lockref_spin.sats libats/DATS/lockref_spin.dats libats/SATS/lockptr_spin.sats libats/DATS/lockptr_spin.dats /* ****** ****** */ libats/SATS/parworkshop.sats libats/DATS/parworkshop.dats /* ****** ****** */ /* end of [.libfiles_mt] */ ats-lang-anairiats-0.2.11/config.h.in0000664000175000017500000000414012223166157016023 0ustar hwxihwxi/* config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if you have the header file. */ #undef HAVE_COMPLEX_H /* Define to 1 if you have the header file. */ #undef HAVE_CURSES_H /* Define to 1 if you have the `drand48_r' function. */ #undef HAVE_DRAND48_R /* Define to 1 if you have the `erand48_r' function. */ #undef HAVE_ERAND48_R /* Define to 1 if you have the header file. */ #undef HAVE_GMP_H /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the `memalign' function. */ #undef HAVE_MEMALIGN /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H /* Define to 1 if you have the header file. */ #undef HAVE_PCRE_H /* Define to 1 if you have the `posix_memalign' function. */ #undef HAVE_POSIX_MEMALIGN /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the home page for this package. */ #undef PACKAGE_URL /* Define to the version of this package. */ #undef PACKAGE_VERSION /* The size of `void*', as computed by sizeof. */ #undef SIZEOF_VOIDP /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Version number of package */ #undef VERSION ats-lang-anairiats-0.2.11/libats/0000700000175000017500000000000012223166162015237 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/CATS/0000700000175000017500000000000012223166162015771 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/CATS/fmatrix.cats0000664000175000017500000000404712223166162020340 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** An interface for ATS to interact with BLAS and LAPACK ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** */ /* ****** ****** */ #ifndef ATS_LIBATS_FMATRIX_CATS #define ATS_LIBATS_FMATRIX_CATS /* ****** ****** */ static inline ats_ptr_type atslib_fmatrix_ptr_takeout_tsz ( ats_ptr_type base , ats_size_type m , ats_size_type i , ats_size_type j , ats_size_type tsz ) { // the representation is column-major return ((char*)base) + (i + j * m) * tsz ; } /* end of [atslib_fmatrix_ptr_takeout_tsz] */ /* ****** ****** */ #endif /* [ATS_LIBATS_FMATRIX_CATS] */ /* end of [fmatrix.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/linordset_randbst.cats0000664000175000017500000000632412223166162022406 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2011 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Start Time: October, 2011 ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LINORDSET_RANDBST_CATS #define ATS_LIBATS_LINORDSET_RANDBST_CATS /* ****** ****** */ // // HX: __USE_MISC must be turned on // #include /* ****** ****** */ typedef struct { void (*free) (void *obj) ; double (*get_double) (void *obj) ; void (*setseed) (void *obj, unsigned long int seed) ; } linordset_rngobj_struct ; typedef linordset_rngobj_struct *linordset_rngobj ; /* ****** ****** */ #ifdef HAVE_DRAND48_R typedef struct { linordset_rngobj_struct rng ; struct drand48_data state ; // the state of RNG } linordset_rngobj_struct_drand48 ; static ats_void_type linordset_rngobj_free_drand48 (void *obj) { ATS_FREE (obj) ; return ; } // end of [rngobj_free_drand48] static ats_double_type linordset_rngobj_get_double_drand48 ( void *obj ) { double result ; drand48_r ( &((linordset_rngobj_struct_drand48*)obj)->state, &result ) ; return result; } // end of [linordset_rngobj_get_double_drand48] static ats_void_type linordset_rngobj_setseed_drand48 ( void *obj, unsigned long int seed ) { srand48_r ( seed, &((linordset_rngobj_struct_drand48*)obj)->state ) ; return ; } // end of [linordset_rngobj_setseed_drand48] ATSinline() ats_ptr_type atslib_linordset_rngobj_make_drand48 ( ) { linordset_rngobj_struct *objrng ; linordset_rngobj_struct_drand48 *obj ; obj = ATS_MALLOC (sizeof(linordset_rngobj_struct_drand48)) ; objrng = &(obj->rng) ; objrng->free = &linordset_rngobj_free_drand48 ; objrng->get_double = &linordset_rngobj_get_double_drand48 ; objrng->setseed = &linordset_rngobj_setseed_drand48 ; return (obj) ; } // end of [linordset_rngobj_make_drand48] #endif // end of [HAVE_DRAND48_R] /* ****** ****** */ #endif /* ATS_LIBATS_LINORDSET_RANDBST_CATS */ /* end of [linordset_randbst.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/genarrays.cats0000664000175000017500000000342412223166162020657 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** An interface for ATS to interact with BLAS ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** */ /* ****** ****** */ #ifndef ATS_LIBATS_GENARRAYS_CATS #define ATS_LIBATS_GENARRAYS_CATS /* ****** ****** */ // it is still empty /* ****** ****** */ #endif /* ATS_LIBATS_GENARRAYS_CATS */ /* end of [genarrays.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/intinf.cats0000664000175000017500000000704112223166162020152 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_INTINF_CATS #define ATS_LIBATS_INTINF_CATS /* ****** ****** */ #include "libc/CATS/gmp.cats" /* ****** ****** */ static inline ats_bool_type atslib_lt_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int((mpz_ptr)i, j) < 0) ; } /* end of [atslib_lt_intinf_int] */ static inline ats_bool_type atslib_lte_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j) <= 0) ; } /* end of [atslib_lte_intinf_int] */ /* ****** ****** */ static inline ats_bool_type atslib_gt_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j) > 0) ; } /* end of [atslib_gt_intinf_int] */ static inline ats_bool_type atslib_gte_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j) >= 0) ; } /* end of [atslib_gte_intinf_int] */ /* ****** ****** */ static inline ats_bool_type atslib_eq_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j) == 0) ; } /* end of [atslib_eq_intinf_int] */ static inline ats_bool_type atslib_eq_intinf_intinf ( ats_ptr_type i, ats_ptr_type j ) { return (atslib_mpz_cmp_mpz ((mpz_ptr)i, (mpz_ptr)j) == 0) ; } /* end of [atslib_eq_intinf_intinf] */ /* ****** ****** */ static inline ats_bool_type atslib_neq_intinf_int ( ats_ptr_type i, ats_int_type j ) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j) != 0) ; } /* end of [atslib_neq_intinf_int] */ static inline ats_bool_type atslib_neq_intinf_intinf ( ats_ptr_type i, ats_ptr_type j ) { return (atslib_mpz_cmp_mpz ((mpz_ptr)i, (mpz_ptr)j) != 0) ; } /* end of [atslib_neq_intinf_intintf] */ /* ****** ****** */ static inline ats_int_type atslib_compare_intinf_int (ats_ptr_type i, ats_int_type j) { return (atslib_mpz_cmp_int ((mpz_ptr)i, j)) ; } /* end of [atslib_compare_intinf_int] */ static inline ats_int_type atslib_compare_intinf_intinf (ats_ptr_type i, ats_ptr_type j) { return (atslib_mpz_cmp_mpz ((mpz_ptr)i, (mpz_ptr)j)) ; } /* end of [atslib_compare_intinf_intintf] */ /* ****** ****** */ #endif /* ATS_LIBATS_INTINF_CATS */ /* end of [intinf.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/linqueue_lst.cats0000664000175000017500000000331512223166162021374 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LINQUEUE_LST_CATS #define ATS_LIBATS_LINQUEUE_LST_CATS /* ****** ****** */ typedef struct { ats_ptr_type ptr1 ; ats_ptr_type ptr2 ; } atslib_linqueue_lst_QUEUE ; /* ****** ****** */ #endif /* ATS_LIBATS_LINQUEUE_LST_CATS */ /* end of [linqueue_lst.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/parworkshop.cats0000664000175000017500000001033312223166162021240 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_PARWORKSHOP_CATS #define ATS_LIBATS_PARWORKSHOP_CATS /* ****** ****** */ #include "libc/CATS/pthread.cats" /* ****** ****** */ #include "libats/CATS/linqueue_arr.cats" /* ****** ****** */ typedef struct { // pthread_mutex_t WSmut ; // atslib_linqueue_arr_QUEUE WQ ; // pthread_cond_t WQemp ; pthread_cond_t WQful ; ats_int_type nworker ; pthread_cond_t WSisz ; // nworker = 0 ats_int_type npaused ; pthread_cond_t WSpaused ; pthread_cond_t WSequ1 ; // npaused = nworker ats_int_type nblocked ; pthread_cond_t WSequ2 ; // nblocked = nworker ats_fun_ptr_type fwork ; ats_int_type refcount ; } atslib_parworkshop_WORKSHOP ; /* ****** ****** */ ATSinline() ats_fun_ptr_type atslib_parworkshop_workshop_get_fwork (ats_ptr_type ws) { return ((atslib_parworkshop_WORKSHOP*)ws)->fwork ; } // end of [atslib_parworkshop_workshop_get_fwork] /* ****** ****** */ ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WSmut (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WSmut ; } // end of [atslib_parworkshop_workshop_get_WSmut] /* ****** ****** */ ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WQemp (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WQemp ; } // end of [atslib_parworkshop_workshop_get_WQemp] ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WQful (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WQful ; } // end of [atslib_parworkshop_workshop_get_WQful] /* ****** ****** */ ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WSisz (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WSisz ; } // end of [atslib_parworkshop_workshop_get_WSisz] ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WSpaused (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WSpaused ; } // end of [atslib_parworkshop_workshop_get_WSpaused] ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WSequ1 (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WSequ1 ; } // end of [atslib_parworkshop_workshop_get_WSequ1] ATSinline() ats_ptr_type atslib_parworkshop_workshop_get_WSequ2 (ats_ptr_type ws) { return &((atslib_parworkshop_WORKSHOP*)ws)->WSequ2 ; } // end of [atslib_parworkshop_workshop_get_WSequ2] /* ****** ****** */ ATSinline() ats_ptr_type atslib_parworkshop_workshop_acquire (ats_ptr_type ws) { pthread_mutex_lock (&((atslib_parworkshop_WORKSHOP*)ws)->WSmut) ; return ws ; } // end of [atslib_parworkshop_workshop_acquire] ATSinline() ats_void_type atslib_parworkshop_workshop_release (ats_ptr_type ws) { pthread_mutex_unlock (&((atslib_parworkshop_WORKSHOP*)ws)->WSmut) ; return ; } // end of [atslib_parworkshop_workshop_release] /* ****** ****** */ #endif /* ATS_LIBATS_PARWORKSHOP_CATS */ /* end of [parworkshop.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/regexp.cats0000664000175000017500000000337312223166162020161 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBATS_REGEXP_CATS #define ATS_LIBATS_REGEXP_CATS /* ****** ****** */ #include /* ****** ****** */ ATSinline() ats_void_type atslib_regexp_free (ats_ptr_type re) { pcre_free (re) ; return ; } // end of [atslib_regexp_free] /* ****** ****** */ #endif /* ATS_LIBATS_REGEXP_CATS */ /* end of [regexp.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/lockref_spin.cats0000664000175000017500000000410212223166162021334 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LOCKREF_SPIN_CATS #define ATS_LIBATS_LOCKREF_SPIN_CATS /* ****** ****** */ #include "libats/CATS/lockptr_spin.cats" /* ****** ****** */ #define atslib_lockref_create_locked atslib_lockptr_create_locked #define atslib_lockref_create_unlocked atslib_lockptr_create_unlocked /* ****** ****** */ #define atslib_lockref_acquire atslib_lockptr_acquire #define atslib_lockref_acquire_try atslib_lockptr_acquire_try #define atslib_lockref_release atslib_lockptr_release /* ****** ****** */ #endif // end of [#ifndef ATS_CONTRIB_LOCKREF_SPIN_CATS] /* ****** ****** */ /* end of [lockref_spin.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/linstack_arr.cats0000664000175000017500000000336212223166162021341 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LINSTACK_ARR_CATS #define ATS_LIBATS_LINSTACK_ARR_CATS /* ****** ****** */ #include "libats/ngc/CATS/deque_arr.cats" /* ****** ****** */ typedef atslib_ngc_deque_arr_DEQUE atslib_linstack_arr_STACK ; /* ****** ****** */ #endif /* ATS_LIBATS_LINSTACK_ARR_CATS */ /* end of [linstack_arr.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/hashtable_chain.cats0000664000175000017500000000424712223166162021765 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** A dynamically resizable vector implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Secptember, 2010 */ /* ****** ****** */ #ifndef ATS_LIBATS_HASHTABLE_CHAIN_CATS #define ATS_LIBATS_HASHTABLE_CHAIN_CATS /* ****** ****** */ ATSinline() ats_void_type atslib_hashtbl_ptr_free__chain (ats_ptr_type pbeg) { ATS_FREE(pbeg) ; return ; } // end of [atslib_hashtbl_ptr_free__chain] /* ****** ****** */ ATSinline() ats_ptr_type atslib_hashtbl_make_null__chain (/*argumentless*/) { return (void*)0; } // end of [atslib_hashtbl_make_null__chain] /* ****** ****** */ ATSinline() ats_void_type atslib_hashtbl_free_null__chain (ats_ptr_type ptbl) { return ; } // end of [atslib_hashtbl_free_null__chain] /* ****** ****** */ #endif /* ATS_LIBATS_HASHTABLE_CHAIN_CATS */ /* end of [hashtable_chain.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/lockptr_spin.cats0000664000175000017500000000441212223166162021371 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LOCKPTR_SPIN_CATS #define ATS_LIBATS_LOCKPTR_SPIN_CATS /* ****** ****** */ #include "libc/CATS/pthread.cats" /* ****** ****** */ extern ats_ptr_type atslib_pthread_spin_create_locked (ats_int_type pshared) ; extern ats_ptr_type atslib_pthread_spin_create_unlocked (ats_int_type pshared) ; /* ****** ****** */ #define atslib_lockptr_create_locked \ atslib_pthread_spin_create_locked #define atslib_lockptr_create_unlocked \ atslib_pthread_spin_create_unlocked /* ****** ****** */ #define atslib_lockptr_acquire atslib_pthread_spin_lock #define atslib_lockptr_acquire_try atslib_pthread_spin_trylock #define atslib_lockptr_release atslib_pthread_spin_unlock /* ****** ****** */ #endif // end of [#ifndef ATS_CONTRIB_LOCKPTR_SPIN_CATS] /* ****** ****** */ /* end of [lockptr_spin.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/vector.cats0000664000175000017500000000335112223166162020165 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** A dynamically resizable vector implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Secptember, 2010 */ /* ****** ****** */ #ifndef ATS_LIBATS_VECTOR_CATS #define ATS_LIBATS_VECTOR_CATS /* ****** ****** */ #define atslib_vector_realloc(p, m, tsz) ats_realloc_gc(p, m*tsz) /* ****** ****** */ #endif /* ATS_LIBATS_VECTOR_CATS */ /* end of [vector.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/linqueue_arr.cats0000664000175000017500000000336212223166162021360 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LINQUEUE_ARR_CATS #define ATS_LIBATS_LINQUEUE_ARR_CATS /* ****** ****** */ #include "libats/ngc/CATS/deque_arr.cats" /* ****** ****** */ typedef atslib_ngc_deque_arr_DEQUE atslib_linqueue_arr_QUEUE ; /* ****** ****** */ #endif /* ATS_LIBATS_LINQUEUE_ARR_CATS */ /* end of [linqueue_arr.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/linbitvec.cats0000664000175000017500000000461512223166162020646 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_LINBITVEC_CATS #define ATS_LIBATS_LINBITVEC_CATS /* ****** ****** */ // // HX: these functions need to be inlined for efficiency! // /* ****** ****** */ static inline ats_int_type atslib_linbitvec_bitvec_get_at ( ats_ptr_type p_vec, ats_size_type i ) { size_t q, r ; q = i >> NBIT_PER_WORD_LOG ; r = i & (NBIT_PER_WORD - 1) ; return (((uintptr_t*)p_vec)[q] >> r) & 0x1 ; } // end of [atslib_linbitvec_bitvec_get_at] static inline ats_void_type atslib_linbitvec_bitvec_set_at ( ats_ptr_type p_vec, ats_size_type i, ats_int_type b ) { size_t q, r ; q = i >> NBIT_PER_WORD_LOG ; r = i & (NBIT_PER_WORD - 1) ; if (b) { ((uintptr_t*)p_vec)[q] |= ((uintptr_t)1 << r) ; } else { ((uintptr_t*)p_vec)[q] &= ~((uintptr_t)1 << r) ; } ; return ; } // end of [linbitvec_bitvec_set_at] /* ****** ****** */ #endif // end of [#ifndef ATS_CONTRIB_LINBITVEC_CATS] /* ****** ****** */ /* end of [linbitvec.cats] */ ats-lang-anairiats-0.2.11/libats/CATS/slseg.cats0000664000175000017500000000347312223166162020005 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_PRELUDE_SLSEG_CATS #define ATS_PRELUDE_SLSEG_CATS /* ****** ****** */ #if(0) // // HX: these are now cast functions // ATSinline() ats_ptr_type atslib_list_vt_of_sllst (ats_ptr_type p) { return p ; } ATSinline() ats_ptr_type atslib_sllst_of_list_vt (ats_ptr_type p) { return p ; } #endif // [#if(0)] /* ****** ****** */ #endif /* ATS_PRELUDE_SLSEG_CATS */ /* end of [slseg.cats] */ ats-lang-anairiats-0.2.11/libats/ngc/0000700000175000017500000000000012223166162016006 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/ngc/CATS/0000700000175000017500000000000012223166162016540 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/ngc/CATS/deque_arr.cats0000664000175000017500000001350412223166162021402 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* ** ** Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** */ /* ****** ****** */ #ifndef ATS_LIBATS_NGC_DEQUE_ARR_CATS #define ATS_LIBATS_NGC_DEQUE_ARR_CATS /* ****** ****** */ typedef struct { ats_size_type cap ; ats_size_type nitm ; ats_ptr_type qarr_lft ; ats_ptr_type qarr_rgt ; ats_ptr_type qarr_beg ; ats_ptr_type qarr_end ; } atslib_ngc_deque_arr_DEQUE ; /* ****** ****** */ #ifndef memcpy // // HX: [memcpy] is not a macro // extern void *memcpy (void *dst, const void* src, size_t n) ; #endif // end of [memcpy] /* ****** ****** */ // // HX: these two are implemented in ATS: // extern ats_void_type atslib_ngc_deque_arr_deque_initialize_tsz ( ats_ptr_type pq , ats_size_type qsz , ats_ptr_type parr , ats_size_type tsz ) ; // end of [atslib_ngc_deque_arr_deque_initialize_tsz] extern ats_ptr_type atslib_ngc_deque_arr_deque_uninitialize (ats_ptr_type) ; /* ****** ****** */ ATSinline() ats_ptr_type atslib_ngc_deque_arr_deque_takeout_tsz ( ats_ref_type q0 , ats_size_type i , ats_size_type tsz ) { atslib_ngc_deque_arr_DEQUE *q = (atslib_ngc_deque_arr_DEQUE*)q0 ; char *p_lft = q->qarr_lft ; char *p_rgt = q->qarr_rgt ; char *p_beg = q->qarr_beg ; char *p_elt = p_beg + i * tsz ; if (p_elt >= p_rgt) { p_elt = p_lft + (p_elt - p_rgt) ; } // end of [if] return p_elt ; } // end of [atslib_ngc_deque_arr_deque_takeout_tsz] /* ****** ****** */ ATSinline() ats_void_type atslib_ngc_deque_arr_deque_insert_end_many_tsz ( ats_ref_type q0 , ats_size_type k , ats_ptr_type p0_xs /* buffer */ , ats_size_type tsz ) { atslib_ngc_deque_arr_DEQUE *q = (atslib_ngc_deque_arr_DEQUE*)q0 ; char *p_xs = (char*)p0_xs ; char *p_lft = q->qarr_lft ; char *p_rgt = q->qarr_rgt ; char *p_end = q->qarr_end ; size_t ktsz = k * tsz ; size_t diff = p_rgt - p_end ; q->nitm += k ; if (ktsz <= diff) { memcpy(p_end, p_xs, ktsz) ; q->qarr_end = p_end + ktsz ; } else { memcpy(p_end, p_xs, diff) ; memcpy(p_lft, p_xs+diff, ktsz-diff) ; q->qarr_end = p_lft + (ktsz-diff) ; } // end of [if] return ; } // end of [atslib_ngc_deque_arr_deque_insert_end_many_tsz] /* ****** ****** */ ATSinline() ats_void_type atslib_ngc_deque_arr_deque_remove_beg_many_tsz ( ats_ref_type q0 , ats_size_type k , ats_ptr_type p0_xs /* buffer */ , ats_size_type tsz ) { atslib_ngc_deque_arr_DEQUE *q = (atslib_ngc_deque_arr_DEQUE*)q0 ; char *p_xs = (char*)p0_xs ; char *p_lft = q->qarr_lft ; char *p_rgt = q->qarr_rgt ; char *p_beg = q->qarr_beg ; size_t ktsz = k * tsz ; size_t diff = p_rgt - p_beg ; q->nitm -= k ; if (ktsz <= diff) { memcpy(p_xs, p_beg, ktsz) ; q->qarr_beg = p_beg + ktsz ; } else { memcpy(p_xs, p_beg, diff) ; memcpy(p_xs+diff, p_lft, ktsz-diff) ; q->qarr_beg = p_lft + (ktsz-diff) ; } // end of [if] return ; } // end of [atslib_ngc_deque_arr_deque_remove_beg_many_tsz] /* ****** ****** */ ATSinline() ats_void_type atslib_ngc_deque_arr_deque_copyout_tsz ( ats_ref_type q0 , ats_size_type i , ats_size_type k , ats_ptr_type p0_xs /* buffer */ , ats_size_type tsz ) { atslib_ngc_deque_arr_DEQUE *q = (atslib_ngc_deque_arr_DEQUE*)q0 ; char *p_xs = (char*)p0_xs ; char *p_lft = q->qarr_lft ; char *p_rgt = q->qarr_rgt ; char *p_beg = q->qarr_beg ; size_t itsz = i * tsz ; char *p_i = p_beg + itsz ; if (p_i >= p_rgt) { p_i = p_lft + (p_i - p_rgt) ; } size_t ktsz = k * tsz ; size_t diff = p_rgt - p_i ; if (ktsz <= diff) { memcpy(p_xs, p_i, ktsz) ; } else { memcpy(p_xs, p_i, diff) ; memcpy(p_xs+diff, p_lft, ktsz-diff) ; } // end of [if] return ; } // end of [atslib_ngc_deque_arr_deque_copyout_tsz] /* ****** ****** */ ATSinline() ats_ptr_type atslib_ngc_deque_arr_deque_update_capacity_tsz ( ats_ref_type q0 , ats_size_type m2 , ats_ptr_type p0_xs /* buffer */ , ats_size_type tsz ) { atslib_ngc_deque_arr_DEQUE *q = (atslib_ngc_deque_arr_DEQUE*)q0 ; char *p_xs = (char*)p0_xs ; char *p_lft = q->qarr_lft ; char *p_rgt = q->qarr_rgt ; char *p_beg = q->qarr_beg ; size_t ntsz = q->nitm * tsz ; size_t diff = p_rgt - p_beg ; // q->cap = m2 ; q->qarr_lft = p_xs ; q->qarr_rgt = p_xs + m2 * tsz ; q->qarr_beg = p_xs ; q->qarr_end = p_xs + ntsz ; // if (ntsz <= diff) { memcpy(p_xs, p_beg, ntsz) ; } else { memcpy(p_xs, p_beg, diff) ; memcpy(p_xs+diff, p_lft, ntsz-diff) ; } // end of [if] // return p_lft ; // } // end of [atslib_ngc_deque_arr_deque_update_capacity_tsz] /* ****** ****** */ #endif /* ATS_LIBATS_NGC_DEQUE_ARR_CATS */ /* end of [deque_arr.cats] */ ats-lang-anairiats-0.2.11/libats/ngc/SATS/0000700000175000017500000000000012223166162016560 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/ngc/SATS/linmap_pavltree.sats0000664000175000017500000002702012223166162022653 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by ** Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) ** Time: January, 2012 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) absview pavlnode_v ( key:t@ype , itm:viewt@ype+ , h:int , ll:addr, lr:addr , lp:addr , l:addr ) // end of [pavlnode_v] viewdef pavlnode_v ( key:t0p, itm:vt0p, l0:addr ) = [h:int] [ll,lr,lp:addr] pavlnode_v (key, itm, h, ll, lr, lp, l0) // end of [pavlnode_v] prfun pavlnode_ptr_is_gtz {key:t0p;itm:vt0p} {h:int} {l,ll,lr,lp:addr} (pf: !pavlnode_v (key, itm, h, ll, lr, lp, l)): [l > null] void // end of [pavlnode_ptr_is_gtz] (* ****** ****** *) typedef pavlnode_get_height_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - int h // end of [pavlnode_get_height_type] fun{key:t0p;itm:vt0p} pavlnode_get_height : pavlnode_get_height_type (key, itm) // specific typedef pavlnode_set_height_type (key:t0p, itm:vt0p) = {h,h1:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) >> pavlnode_v (key, itm, h1, ll, lr, lp, l0) | ptr l0, int h1 ) - void // end of [pavlnode_set_height_type] fun{key:t0p;itm:vt0p} pavlnode_set_height : pavlnode_set_height_type (key, itm) // specific typedef pavlnode_get_left_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - ptr ll // end of [pavlnode_get_left_type] fun{key:t0p;itm:vt0p} pavlnode_get_left : pavlnode_get_left_type (key, itm) // specific typedef pavlnode_set_left_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0,ll1:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) >> pavlnode_v (key, itm, h, ll1, lr, lp, l0) | ptr l0, ptr ll1 ) - void // end of [pavlnode_set_left_type] fun{key:t0p;itm:vt0p} pavlnode_set_left : pavlnode_set_left_type (key, itm) // specific typedef pavlnode_get_right_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - ptr lr // end of [pavlnode_get_right_type] fun{key:t0p;itm:vt0p} pavlnode_get_right : pavlnode_get_right_type (key, itm) // specific typedef pavlnode_set_right_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0,lr1:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) >> pavlnode_v (key, itm, h, ll, lr1, lp, l0) | ptr l0, ptr lr1 ) - void // end of [pavlnode_set_right_type] fun{key:t0p;itm:vt0p} pavlnode_set_right : pavlnode_set_right_type (key, itm) // specific typedef pavlnode_get_parent_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - ptr lp // end of [pavlnode_get_parent_type] fun{key:t0p;itm:vt0p} pavlnode_get_parent : pavlnode_get_parent_type (key, itm) // specific typedef pavlnode_set_parent_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0,lp1:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) >> pavlnode_v (key, itm, h, ll, lr, lp1, l0) | ptr l0, ptr lp1 ) - void // end of [pavlnode_set_parent_type] fun{key:t0p;itm:vt0p} pavlnode_set_parent : pavlnode_set_parent_type (key, itm) // specific (* ****** ****** *) typedef pavlnode_get_key_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - key // end of [pavlnode_get_key_type] fun{key:t0p;itm:vt0p} pavlnode_get_key : pavlnode_get_key_type (key, itm) // specific typedef pavlnode_set_key_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( !pavlnode_v (key?, itm, h, ll, lr, lp, l0) >> pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0, key ) - void fun{key:t0p;itm:vt0p} pavlnode_set_key : pavlnode_set_key_type (key, itm) // specific (* ****** ****** *) typedef pavlnode_takeout_val_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,lp,l0:addr} ( pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l0 ) - [l:addr] ( itm @ l, {itm:vt0p} itm @ l - pavlnode_v (key, itm, h, ll, lr, lp, l0) | ptr l ) // end of [pavlnode_takeout_val_type] fun{key:t0p;itm:vt0p} pavlnode_takeout_val : pavlnode_takeout_val_type (key, itm) (* ****** ****** *) typedef pavlnode_alloc_type (key:t0p, itm:vt0p) = () - [l:addr] [h:int] [ll,lr,lp:addr] ( option_v (pavlnode_v (key?, itm?, h, ll, lr, lp, l), l > null) | ptr l ) // end of [typedef] fun{key:t0p;itm:vt0p} pavlnode_alloc : pavlnode_alloc_type (key, itm) // specific template typedef pavlnode_free_type (key:t0p, itm:vt0p) = {h:int} {l,ll,lr,lp:addr} (pavlnode_v (key, itm?, h, ll, lr, lp, l) | ptr l) - void fun{key:t0p;itm:vt0p} pavlnode_free : pavlnode_free_type (key, itm) // specific template (* ****** ****** *) absviewtype map_t0ype_viewt0ype_type (key:t@ype, itm:viewt@ype+) stadef map = map_t0ype_viewt0ype_type (* ****** ****** *) typedef cmp (key:t0p) = (key, key) - int fun{key:t0p} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) fun{} linmap_make_nil {key:t0p;itm:vt0p} ():<> map (key, itm) (* ****** ****** *) fun{} linmap_is_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool fun{} linmap_isnot_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool (* ****** ****** *) // // HX: this function is O(n)-time and non-tail-recursive // fun{key:t0p;itm:vt0p} linmap_size (m: !map (key, itm)):<> size_t // // HX: this function is O(1) // for gathering stats fun{key:t0p;itm:vt0p} linmap_height (m: !map (key, itm)):<> Nat // (* ****** ****** *) fun{key:t0p;itm:t0p} linmap_search ( m: !map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_search] (* ****** ****** *) // // AS: // if [p0->key] occurs in [m], [p0] replaces the original node associated // with [p0->key] // fun{key:t0p;itm:vt0p} linmap_insert {l_at:addr} ( pf_at: !pavlnode_v (key, itm, l_at) >> option_v (pavlnode_v (key, itm, l_at1), b) | m: &map (key, itm), p0: &ptr l_at >> ptr l_at1, cmp: cmp key ) :<> #[b:bool;l_at1:addr] bool (b) // end of [linmap_insert] (* ****** ****** *) fun{key:t0p;itm:vt0p} linmap_takeout ( m: &map (key, itm) , k0: key, cmp: cmp key ) :<> [l_at:addr] (option_v (pavlnode_v (key, itm, l_at), l_at > null) | ptr l_at) // end of [linmap_takeout] fun{key:t0p;itm:t0p} linmap_remove (m: &map (key, itm), k0: key, cmp: cmp key):<> bool // end of [linmap_remove] (* ****** ****** *) (* // AS: enumerating elements of linear map // TODO: provide an implementation absviewtype enum_t0ype_viewt0ype_type ( key:t@ype, itm:viewt@ype+, nf:int, nr:int, l:addr ) = ptr stadef enum = enum_t0ype_viewt0ype_type // start enumeration from the least element fun{key:t0p;itm:vt0p} enum_first {l:addr} ( pf: map (key, itm) @ l | p: ptr l ) :<> [nr:nat] enum (key, itm, 0, nr, l) // start enumeration from the greatest element fun{key:t0p;itm:vt0p} enum_last {l:addr} ( pf: map (key, itm) @ l | p: ptr l ) :<> [nf:nat] enum (key, itm, nf, 0, l) // navigate to the successor fun{key:t0p;itm:vt0p} enum_succ {nf:int;nr:pos} {l:addr} ( e: enum (key, itm, nf, nr, l) ) :<> enum (key, itm, nf+1, nr-1, l) // navigate to the predecessor fun{key:t0p;itm:vt0p} enum_pred {nf:pos;nr:int} {l:addr} ( e: enum (key, itm, nf, nr, l) ) :<> enum (key, itm, nf-1, nr+1, l) fun{key:t0p;itm:vt0p} enum_is_at_end {nf,nr:int | nr > 0} {l:addr} ( e: !enum (key, itm, nf, nr, l) ) :<> bool (nr <= 1) // end of [enum_is_at_end] fun{key:t0p;itm:vt0p} enum_isnot_at_end {nf,nr:int | nr > 0} {l:addr} ( e: !enum (key, itm, nf, nr, l) ) :<> bool (nr >= 2) // end of [enum_isnot_at_end] fun{key:t0p;itm:vt0p} enum_is_at_beg {nf,nr:int | nr > 0} {l:addr} ( e: !enum (key, itm, nf, nr, l) ) :<> bool (nf <= 0) // end of [enum_is_at_beg] fun{key:t0p;itm:vt0p} enum_isnot_at_beg {nf,nr:int | nr > 0} {l:addr} ( e: !enum (key, itm, nf, nr, l) ) :<> bool (nf >= 1) // end of [enum_isnot_at_beg] fun{key:t0p;itm:vt0p} enum_app_funenv {v:view} {vt:viewtype} {nf,nr:int | nr > 0} {l:addr} ( pfv: !v | e: !enum (key, itm, nf, nr, l) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [enum_app_funenv] fun{key:t0p;itm:vt0p} enum_app_fun {nf,nr:int | nr > 0} {l:addr} ( e: !enum (key, itm, nf, nr, l) , f: (key, &itm) - void ) :<> void // end of [enum_app_fun] prfun enum_free {key:t0p;itm:vt0p} {nf,nr:int} {l:addr} ( x: enum (key, itm, nf, nr, l) ) :<> map (key, itm) @ l *) (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_foreach_funenv] fun{ key:t0p;itm:vt0p } linmap_foreach_fun ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun] fun{ key:t0p;itm:vt0p } linmap_foreach_vclo {v:view} ( pf: !v | m: !map (key, itm), f: &(!v | key, &itm) - void ) :<> void // end of [linmap_foreach_vclo] (* ****** ****** *) // AS: tail-recursive traversal functions (using parent pointers) fun{ key:t0p;itm:vt0p } linmap_foreach_fun_iter ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun_iter] fun{ key:t0p;itm:vt0p } linmap_rforeach_fun_iter ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_rforeach_fun_iter] (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_rforeach_funenv] (* ****** ****** *) // // AS: clearing a map based on [foreach] // fun{ key:t0p;itm:vt0p } linmap_clear_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) >> map (key, itm?) , f: (!v | key, &itm >> itm?, !vt) - void , env: !vt ) :<> void // end of [linmap_clear_funenv] // (* ****** ****** *) // fun{key:t0p;itm:t0p} linmap_free (m: map (key, itm)):<> void // // AS: frees the map if it is empty // fun{ key:t0p;itm:vt0p } linmap_free_vt ( m: !map (key, itm) >> opt (map (key, itm), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linmap_free_vt] (* ****** ****** *) (* end of [linmap_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/ngc/SATS/linmap_avltree.sats0000664000175000017500000002124612223166162022477 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by ** Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) ** Time: January, 2012 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) absview avlnode_v ( key:t@ype , itm:viewt@ype+ , h:int , ll:addr, lr:addr , l:addr ) // end of [avlnode_v] viewdef avlnode_v ( key:t0p, itm:vt0p, l0:addr ) = [h:int] [ll,lr:addr] avlnode_v (key, itm, h, ll, lr, l0) // end of [avlnode_v] prfun avlnode_ptr_is_gtz {key:t0p;itm:vt0p} {h:int} {l,ll,lr:addr} (pf: !avlnode_v (key, itm, h, ll, lr, l)): [l > null] void // end of [avlnode_ptr_is_gtz] (* ****** ****** *) typedef avlnode_get_height_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) | ptr l0 ) - int h // end of [avlnode_get_height_type] fun{key:t0p;itm:vt0p} avlnode_get_height : avlnode_get_height_type (key, itm) // specific typedef avlnode_set_height_type (key:t0p, itm:vt0p) = {h,h1:int} {ll,lr,l0:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) >> avlnode_v (key, itm, h1, ll, lr, l0) | ptr l0, int h1 ) - void // end of [avlnode_set_height_type] fun{key:t0p;itm:vt0p} avlnode_set_height : avlnode_set_height_type (key, itm) // specific typedef avlnode_get_left_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) | ptr l0 ) - ptr ll // end of [avlnode_get_left_type] fun{key:t0p;itm:vt0p} avlnode_get_left : avlnode_get_left_type (key, itm) // specific typedef avlnode_set_left_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0,ll1:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) >> avlnode_v (key, itm, h, ll1, lr, l0) | ptr l0, ptr ll1 ) - void // end of [avlnode_set_left_type] fun{key:t0p;itm:vt0p} avlnode_set_left : avlnode_set_left_type (key, itm) // specific typedef avlnode_get_right_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) | ptr l0 ) - ptr lr // end of [avlnode_get_right_type] fun{key:t0p;itm:vt0p} avlnode_get_right : avlnode_get_right_type (key, itm) // specific typedef avlnode_set_right_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0,lr1:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) >> avlnode_v (key, itm, h, ll, lr1, l0) | ptr l0, ptr lr1 ) - void // end of [avlnode_set_right_type] fun{key:t0p;itm:vt0p} avlnode_set_right : avlnode_set_right_type (key, itm) // specific (* ****** ****** *) typedef avlnode_get_key_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0,l1:addr} ( !avlnode_v (key, itm, h, ll, lr, l0) | ptr l0 ) - key // end of [avlnode_get_key_type] fun{key:t0p;itm:vt0p} avlnode_get_key : avlnode_get_key_type (key, itm) // specific typedef avlnode_set_key_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0:addr} ( !avlnode_v (key?, itm, h, ll, lr, l0) >> avlnode_v (key, itm, h, ll, lr, l0) | ptr l0, key ) - void fun{key:t0p;itm:vt0p} avlnode_set_key : avlnode_set_key_type (key, itm) // specific (* ****** ****** *) (* // // HX: this one requires that [itm] be the first field // prfun avlnode_v_takeout_val {key:t0p;itm:vt0p} {h:int} {ll,lr,l0:addr} (pf: avlnode_v (key, itm, h, ll, lr, l0)) : (itm @ l0, {itm:vt0p} itm @ l0 - avlnode_v (key, itm, h, ll, lr, l0)) // end of [avlnode_v_takeout_val] *) typedef avlnode_takeout_val_type (key:t0p, itm:vt0p) = {h:int} {ll,lr,l0:addr} ( avlnode_v (key, itm, h, ll, lr, l0) | ptr l0 ) - [l:addr] ( itm @ l, {itm:vt0p} itm @ l - avlnode_v (key, itm, h, ll, lr, l0) | ptr l ) // end of [avlnode_takeout_val_type] fun{key:t0p;itm:vt0p} avlnode_takeout_val : avlnode_takeout_val_type (key, itm) (* ****** ****** *) typedef avlnode_alloc_type (key:t0p, itm:vt0p) = () - [l:addr] [h:int] [ll,lr:addr] ( option_v (avlnode_v (key?, itm?, h, ll, lr, l), l > null) | ptr l ) // end of [typedef] fun{key:t0p;itm:vt0p} avlnode_alloc : avlnode_alloc_type (key, itm) // specific template typedef avlnode_free_type (key:t0p, itm:vt0p) = {h:int} {l,ll,lr:addr} (avlnode_v (key, itm?, h, ll, lr, l) | ptr l) - void fun{key:t0p;itm:vt0p} avlnode_free : avlnode_free_type (key, itm) // specific template (* ****** ****** *) absviewtype map_t0ype_viewt0ype_type (key:t@ype, itm:viewt@ype+) stadef map = map_t0ype_viewt0ype_type (* ****** ****** *) typedef cmp (key:t0p) = (key, key) - int fun{key:t0p} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) fun{} linmap_make_nil {key:t0p;itm:vt0p} ():<> map (key, itm) (* ****** ****** *) fun{} linmap_is_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool fun{} linmap_isnot_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool (* ****** ****** *) // // HX: this function is O(n)-time and non-tail-recursive // fun{key:t0p;itm:vt0p} linmap_size (m: !map (key, itm)):<> size_t // // HX: this function is O(1) // for gathering stats fun{key:t0p;itm:vt0p} linmap_height (m: !map (key, itm)):<> Nat // (* ****** ****** *) fun{key:t0p;itm:t0p} linmap_search ( m: !map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_search] (* ****** ****** *) // // AS: // if [p0->key] occurs in [m], [p0] replaces the original node associated // with [p0->key] // fun{key:t0p;itm:vt0p} linmap_insert {l_at:addr} ( pf_at: !avlnode_v (key, itm, l_at) >> option_v (avlnode_v (key, itm, l_at1), b) | m: &map (key, itm), p0: &ptr l_at >> ptr l_at1, cmp: cmp key ) :<> #[b:bool;l_at1:addr] bool (b) // end of [linmap_insert] (* ****** ****** *) fun{key:t0p;itm:vt0p} linmap_takeout ( m: &map (key, itm) , k0: key, cmp: cmp key ) :<> [l_at:addr] (option_v (avlnode_v (key, itm, l_at), l_at > null) | ptr l_at) // end of [linmap_takeout] fun{key:t0p;itm:t0p} linmap_remove (m: &map (key, itm), k0: key, cmp: cmp key):<> bool // end of [linmap_remove] (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_foreach_funenv] fun{ key:t0p;itm:vt0p } linmap_foreach_fun ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun] fun{ key:t0p;itm:vt0p } linmap_foreach_vclo {v:view} ( pf: !v | m: !map (key, itm), f: &(!v | key, &itm) - void ) :<> void // end of [linmap_foreach_vclo] (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_rforeach_funenv] (* ****** ****** *) // // AS: clearing a map based on [foreach] // fun{ key:t0p;itm:vt0p } linmap_clear_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) >> map (key, itm?) , f: (!v | key, &itm >> itm?, !vt) - void , env: !vt ) :<> void // end of [linmap_clear_funenv] // (* ****** ****** *) // fun{key:t0p;itm:t0p} linmap_free (m: map (key, itm)):<> void // // AS: frees the map if it is empty // fun{ key:t0p;itm:vt0p } linmap_free_vt ( m: !map (key, itm) >> opt (map (key, itm), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linmap_free_vt] (* ****** ****** *) (* end of [linmap_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/ngc/SATS/dlist.sats0000664000175000017500000002313212223166162020610 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // Start Time: March, 2011 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) absview dlnode_v ( a:viewt@ype+ , l: addr, lp: addr, ln: addr // lp: previous; ln: next ) // end of [dlnode_v] prfun dlnode_ptr_is_gtz {a:vt0p} {l,lp,ln:addr} (pf: !dlnode_v (a, l, lp, ln)): [l > null] void // end of [dlnode_ptr_is_gtz] (* ****** ****** *) typedef dlnode_get_prev_type (a:viewt@ype) = {l,lp,ln:addr} ( !dlnode_v (a, l, lp, ln) | ptr l ) - ptr lp // end of [dlnode_get_prev_type] fun{a:vt0p} dlnode_get_prev : dlnode_get_prev_type (a) // specific template typedef dlnode_set_prev_type (a:viewt@ype) = {l,lp1,ln:addr} {lp2:addr} ( !dlnode_v (a, l, lp1, ln) >> dlnode_v (a, l, lp2, ln) | ptr l, ptr lp2 ) - void // end of [dlnode_set_prev_type] fun{a:vt0p} dlnode_set_prev : dlnode_set_prev_type (a) // specific template (* ****** ****** *) typedef dlnode_get_next_type (a:viewt@ype) = {l,lp,ln:addr} ( !dlnode_v (a, l, lp, ln) | ptr l ) - ptr ln // end of [dlnode_get_next_type] fun{a:vt0p} dlnode_get_next : dlnode_get_next_type (a) // specific template typedef dlnode_set_next_type (a:viewt@ype) = {l,lp,ln1:addr} {ln2:addr} ( !dlnode_v (a, l, lp, ln1) >> dlnode_v (a, l, lp, ln2) | ptr l, ptr ln2 ) - void // end of [dlnode_set_next_type] fun{a:vt0p} dlnode_set_next : dlnode_set_next_type (a) // specific template (* ****** ****** *) prfun dlnode_v_takeout_val {a:vt0p} {l,lp,ln:addr} (pf: dlnode_v (a, l, lp, ln)) : (a @ l, {a:vt0p} a @ l - dlnode_v (a, l, lp, ln)) // end of [dlnode_v_takeout_val] (* ****** ****** *) typedef dlnode_alloc_type (a:viewt@ype) = () - [l,lp,ln:addr] ( option_v (dlnode_v (a?, l, lp, ln), l > null) | ptr l ) // end of [typedef] fun{a:vt0p} dlnode_alloc : dlnode_alloc_type (a) // specific template typedef dlnode_free_type (a:viewt@ype) = {l,lp,ln:addr} (dlnode_v (a?, l, lp, ln) | ptr l) - void fun{a:vt0p} dlnode_free : dlnode_free_type (a) // specifc template (* ****** ****** *) dataview dlseg_v ( a:viewt@ype+, int, addr, addr, addr, addr ) = | {n:nat} {lf,lfp:addr} {lr,lrn:addr} {lfn:addr} dlseg_v_cons (a, n+1, lf, lfp, lr, lrn) of ( dlnode_v (a, lf, lfp, lfn), dlseg_v (a, n, lfn, lf, lr, lrn) ) // end of [dlseg_v_cons] | {lf:addr} {lr:addr} dlseg_v_nil (a, 0, lf, lr, lr, lf) of () // end of [dlseg_v] dataview rdlseg_v ( a:viewt@ype+, int, addr, addr, addr, addr ) = | {n:nat} {lf,lfp:addr} {lr,lrn:addr} {lrp:addr} rdlseg_v_cons (a, n+1, lf, lfp, lr, lrn) of ( rdlseg_v (a, n, lf, lfp, lrp, lr), dlnode_v (a, lr, lrp, lrn) ) // end of [dlseg_v_cons] | {lf:addr} {lr:addr} rdlseg_v_nil (a, 0, lf, lr, lr, lf) of () // end of [rdlseg_v] (* ****** ****** *) dataview dlist_v ( a:viewt@ype, int, int, lm:addr ) = | {nf:nat;nr:pos} {lf,lmp,lr:addr} dlist_v_cons (a, nf, nr, lm) of ( rdlseg_v (a, nf, lf, null, lmp, lm), dlseg_v (a, nr, lm, lmp, lr, null) ) // end of [dlist_v_cons] | dlist_v_nil (a, 0, 0, null) of () // end of [dlist_v] (* ****** ****** *) fun dlist_ptr_is_nil {a:vt0p} {nf,nr:int} {lm:addr} ( pf: !dlist_v (a, nf, nr, lm) | p: ptr lm ) :<> bool (nr==0) = "atspre_ptr_is_null" fun dlist_ptr_is_cons {a:vt0p} {nf,nr:int} {lm:addr} ( pf: !dlist_v (a, nf, nr, lm) | p: ptr lm ) :<> bool (nr > 0) = "atspre_ptr_isnot_null" (* ****** ****** *) absviewtype dlist (a:viewt@ype+, nf:int, nr: int) = ptr prfun dlist_length_is_nonnegative {a:vt0p} {nf,nr:int} (xs: !dlist (a, nf, nr)): [nf>=0;nr>=0] void // end of [dlist_length_is_nonnegative] prfun dlist_fold {a:vt0p} {nf,nr:int} {lm:addr} (pflst: dlist_v (a, nf, nr, lm) | p: !ptr lm >> dlist (a, nf, nr)): void // end of [dlist_fold] prfun dlist_unfold {a:vt0p} {nf,nr:int} (xs: !dlist (a, nf, nr) >> ptr lm):<> #[lm:addr] (dlist_v (a, nf, nr, lm) | void) // end of [dlist_unfold] castfn dlist_encode {a:vt0p} {nf,nr:int} {lm:addr} (pflst: dlist_v (a, nf, nr, lm) | p: ptr lm):<> dlist (a, nf, nr) // end of [dlist_encode] castfn dlist_decode {a:vt0p} {nf,nr:int} (xs: dlist (a, nf, nr)):<> [lm:addr] (dlist_v (a, nf, nr, lm) | ptr lm) // end of [dlist_decode] (* ****** ****** *) fun dlist_is_nil {a:vt0p} {nf,nr:int} ( xs: !dlist (a, nf, nr) ) :<> bool (nr==0) = "atspre_ptr_is_null" fun dlist_is_cons {a:vt0p} {nf,nr:int} ( xs: !dlist (a, nf, nr) ) :<> bool (nr > 0) = "atspre_ptr_isnot_null" (* ****** ****** *) fun{a:vt0p} dlist_is_at_end {nf,nr:int | nr > 0} ( xs: !dlist (a, nf, nr) ) :<> bool (nr <= 1) // end of [dlist_is_at_end] fun{a:vt0p} dlist_isnot_at_end {nf,nr:int | nr > 0} ( xs: !dlist (a, nf, nr) ) :<> bool (nr >= 2) // end of [dlist_isnot_at_end] fun{a:vt0p} dlist_is_at_beg {nf,nr:int | nr > 0} ( xs: !dlist (a, nf, nr) ) :<> bool (nf <= 0) // end of [dlist_is_at_beg] fun{a:vt0p} dlist_isnot_at_beg {nf,nr:int | nr > 0} ( xs: !dlist (a, nf, nr) ) :<> bool (nf >= 1) // end of [dlist_isnot_at_beg] (* ****** ****** *) fun{a:vt0p} dlist_nil ():<> dlist (a, 0, 0) (* ****** ****** *) fun{a:vt0p} dlist_sing {l,lp,ln:addr} ( pfnod: dlnode_v (a, l, lp, ln) | p: ptr l ) :<> dlist (a, 0, 1) // end of [dlist_sing] castfn dlist_unsing {a:vt0p} ( xs: dlist (a, 0, 1) ) : [l:addr] ( dlnode_v (a, l, null, null) | ptr l ) // end of [dlist_unsing] (* ****** ****** *) fun{a:vt0p} dlist_cons {nr:int} {l1,lp,ln:addr} ( pfnod: dlnode_v (a, l1, lp, ln) | p1: ptr l1, xs: dlist (a, 0, nr) ) : dlist (a, 0, nr+1) fun{a:vt0p} dlist_uncons {nr:pos} ( xs: &dlist (a, 0, nr) >> dlist (a, 0, nr-1) ) : [l,lp,ln:addr] ( dlnode_v (a, l, lp, ln) | ptr l ) // end of [dlist_uncons] (* ******** ******* *) fun{a:vt0p} dlist_insert_after {nf,nr:int | nr > 0} {l1,lp,ln:addr} ( pfnod: dlnode_v (a, l1, lp, ln) | p1: ptr l1 , xs: !dlist (a, nf, nr) >> dlist (a, nf, nr+1) ) :<> void // end of [dlist_insert_after] fun{a:vt0p} dlist_insert_before {nf,nr:int | nr > 0} {l1,lp,ln:addr} ( pfnod: dlnode_v (a, l1, lp, ln) | p1: ptr l1 , xs: !dlist (a, nf, nr) >> dlist (a, nf+1, nr) ) :<> void // end of [dlist_insert_before] (* ******** ******* *) fun{a:vt0p} dlist_move_forward {nf,nr:int | nr >= 2} (xs: dlist (a, nf, nr)):<> dlist (a, nf+1, nr-1) // end of [dlist_move_forward] fun{a:vt0p} dlist_move_backward {nf,nr:int | nf > 0} (xs: dlist (a, nf, nr)):<> dlist (a, nf-1, nr+1) // end of [dlist_move_backward] (* ******** ******* *) fun{a:vt0p} dlist_remove {nf,nr:int | nr >= 2} ( xs: &dlist (a, nf, nr) >> dlist (a, nf, nr-1) ) :<> [l1,lp,ln:addr] ( dlnode_v (a, l1, lp, ln) | ptr l1 ) // end of [dlist_remove] fun{a:vt0p} dlist_remove_after {nf,nr:int | nr >= 2} ( xs: !dlist (a, nf, nr) >> dlist (a, nf, nr-1) ) :<> [l1,lp,ln:addr] ( dlnode_v (a, l1, lp, ln) | ptr l1 ) // end of [dlist_remove_after] fun{a:vt0p} dlist_remove_before {nf,nr:int | nf > 0} ( xs: !dlist (a, nf, nr) >> dlist (a, nf-1, nr) ) :<> [l1,lp,ln:addr] ( dlnode_v (a, l1, lp, ln) | ptr l1 ) // end of [dlist_remove_before] (* ******** ******* *) fun{a:t0p} dlist_free {nf,nr:int} ( xs: dlist (a, nf, nr) ) :<> void // end of [dlist_free] fun{a:vt0p} dlist_free_funenv {v:view} {vt:viewtype} {nf,nr:int} ( pfv: !v | xs: dlist (a, nf, nr), f: (!v | &a >> a?, !vt) - void , env: !vt ) :<> void // end of [dlist_free_funenv] fun{a:vt0p} dlist_free_fun {nf,nr:int} ( xs: dlist (a, nf, nr), f: (&a >> a?) - void ) :<> void // end of [dlist_free_fun] fun{a:vt0p} dlist_free_vclo {v:view} {nf,nr:int} ( pfv: !v | xs: dlist (a, nf, nr), f: &(!v | &a >> a?) - void ) :<> void // end of [dlist_free_vclo] (* ******** ******* *) fun{a:vt0p} dlist_appfst_funenv {v:view} {vt:viewtype} {nf,nr:int | nr > 0} ( pfv: !v | xs: !dlist (a, nf, nr), f: (!v | &a, !vt) - void , env: !vt ) :<> void // end of [dlist_appfst_funenv] fun{a:vt0p} dlist_appfst_fun {nf,nr:int | nr > 0} ( xs: !dlist (a, nf, nr), f: (&a) - void ) :<> void // end of [dlist_appfst_fun] fun{a:vt0p} dlist_appfst_vclo {v:view} {nf,nr:int | nr > 0} ( pfv: !v | xs: !dlist (a, nf, nr), f: &(!v | &a) - void ) :<> void // end of [dlist_appfst_vclo] (* ******** ******* *) (* end of [dlist.sats] *) ats-lang-anairiats-0.2.11/libats/ngc/SATS/slist.sats0000664000175000017500000001455512223166162020640 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // Start Time: February, 2011 // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) absview slnode_v (a:viewt@ype+, la: addr, lb: addr) prfun slnode_ptr_is_gtz {a:viewt@ype} {la,lb:addr} (pf: !slnode_v (a, la, lb)): [la > null] void // end of [slnode_ptr_is_gtz] (* ****** ****** *) typedef slnode_get_next_type (a:viewt@ype) = {la,lb:addr} ( !slnode_v (a, la, lb) | ptr la ) - ptr lb // end of [slnode_get_next_type] fun{a:vt0p} slnode_get_next : slnode_get_next_type (a) // specific typedef slnode_set_next_type (a:viewt@ype) = {la,lb1:addr} {lb2:addr} ( !slnode_v (a, la, lb1) >> slnode_v (a, la, lb2) | ptr la, ptr lb2 ) - void // end of [slnode_set_next_type] fun{a:vt0p} slnode_set_next : slnode_set_next_type (a) // specific (* ****** ****** *) prfun slnode_v_takeout_val {a:vt0p} {la,lb:addr} (pf: slnode_v (a, la, lb)) : (a @ la, {a:vt0p} a @ la - slnode_v (a, la, lb)) // end of [slnode_v_takeout_val] (* ****** ****** *) typedef slnode_alloc_type (a:viewt@ype) = () - [la,lb:addr] ( option_v (slnode_v (a?, la, lb), la > null) | ptr la ) // end of [typedef] fun{a:vt0p} slnode_alloc : slnode_alloc_type (a) // specific typedef slnode_free_type (a:viewt@ype) = {la,lb:addr} (slnode_v (a?, la, lb) | ptr la) - void fun{a:vt0p} slnode_free : slnode_free_type (a) // specifc (* ****** ****** *) dataview slseg_v ( a:viewt@ype+, int, addr, addr ) = | {n:nat} {la,lb,lz:addr | la > null} slseg_v_cons (a, n+1, la, lz) of ( slnode_v (a, la, lb), slseg_v (a, n, lb, lz) ) // end of [slseg_v_cons] | {la:addr} slseg_v_nil (a, 0, la, la) // end of [slseg_v] viewdef slist_v (a: viewt@ype, n:int, l:addr) = slseg_v (a, n, l, null) // end of [slist_v] (* ****** ****** *) fun slist_ptr_is_nil {a:vt0p} {n:int} {l:addr} ( pf: !slist_v (a, n, l) | p: ptr l ) :<> bool (n==0) = "atspre_ptr_is_null" fun slist_ptr_is_cons {a:vt0p} {n:int} {l:addr} ( pf: !slist_v (a, n, l) | p: ptr l ) :<> bool (n > 0) = "atspre_ptr_isnot_null" (* ****** ****** *) prfun slseg_v_append {a:vt0p} {n1,n2:nat} {la,lm,lz:addr} ( pf1seg: slseg_v (a, n1, la, lm), pf2seg: slseg_v (a, n2, lm, lz) ) : slseg_v (a, n1+n2, la, lz) // end of [slseg_v_append] (* ****** ****** *) prfun slseg_v_extend {a:vt0p} {n:nat} {la,ly,lz:addr} ( pfseg: slseg_v (a, n, la, ly), pfnod: slnode_v (a, ly, lz) ) : slseg_v (a, n+1, la, lz) // end of [slseg_v_extend] (* ****** ****** *) fun{a:vt0p} slist_split_at {n:int} {i:nat | i < n} {la:addr} (pflst: slist_v (a, n, la) | p: ptr la, i: size_t i) : [lm:addr] (slseg_v (a, i, la, lm), slist_v (a, n-i, lm) | ptr lm) // end of [slist_split_at] (* ****** ****** *) absviewtype slist (a:viewt@ype+, n:int) prfun slist_fold {a:vt0p} {n:int} {la:addr} (pflst: slist_v (a, n, la) | p: !ptr la >> slist (a, n)): void // end of [slist_fold] prfun slist_unfold {a:vt0p} {n:int} (xs: !slist (a, n) >> ptr la):<> #[la:addr] (slist_v (a, n, la) | void) // end of [slist_unfold] castfn slist_encode {a:vt0p} {n:int} {la:addr} (pflst: slist_v (a, n, la) | p: ptr la):<> slist (a, n) // end of [slist_encode] castfn slist_decode {a:vt0p} {n:int} (xs: slist (a, n)):<> [la:addr] (slist_v (a, n, la) | ptr la) // end of [slist_decode] (* ****** ****** *) fun{a:vt0p} slist_nil ():<> slist (a, 0) fun{a:vt0p} slist_cons {n:nat} {la,lb:addr} ( pfnod: slnode_v (a, la, lb) | p: ptr la, xs: slist (a, n) ) :<> slist (a, n+1) // end of [slist_cons] (* ****** ****** *) fun{a:t0p} slist_free {n:nat} (xs: slist (a, n)):<> void (* ****** ****** *) fun{a:vt0p} slist_free_funenv {v:view} {vt:viewtype} {n:nat} ( pfv: !v | xs: slist (a, n), f: (!v | &a >> a?, !vt) - void, env: !vt ) :<> void // end of [slist_free_funenv] fun{a:vt0p} slist_free_fun {n:nat} (xs: slist (a, n), f: (&a >> a?) - void):<> void // end of [slist_free_fun] fun{a:vt0p} slist_free_vclo {v:view} {n:nat} (pfv: !v | xs: slist (a, n), f: &(!v | &a >> a?) - void):<> void // end of [slist_free_vclo] (* ****** ****** *) fun{a:vt0p} slist_length {n:nat} (xs: !slist (a, n)):<> size_t (n) // end of [slist_length] (* ****** ****** *) fun{a:vt0p} slist_append {m,n:nat} (xs: slist (a, m), ys: slist (a, n)):<> slist (a, m+n) // end of [slist_append] (* ****** ****** *) fun{a:vt0p} slist_reverse {n:nat} (xs: slist (a, n)):<> slist (a, n) (* ****** ****** *) fun{a:vt0p} slist_foreach_funenv {v:view} {vt:viewtype} {n:nat} ( pfv: !v | xs: !slist (a, n), f: (!v | &a, !vt) - void, env: !vt ) :<> void // end of [slist_foreach_funenv] fun{a:vt0p} slist_foreach_fun {n:nat} ( xs: !slist (a, n), f: (&a) - void ) :<> void // end of [slist_foreach_fun] fun{a:vt0p} slist_foreach_vclo {v:view} {n:nat} ( pfv: !v | xs: !slist (a, n), f: &(!v | &a) - void ) :<> void // end of [slist_foreach_clo] (* ****** ****** *) (* end of [slist.sats] *) ats-lang-anairiats-0.2.11/libats/ngc/SATS/deque_arr.sats0000664000175000017500000001734712223166162021453 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** An array-based deque implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/ngc/CATS/deque_arr.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // HX: // a: item type // m: maximal capacity // n: current size // absviewt@ype DEQUE ( a:viewt@ype+, m: int, n: int ) = $extype"atslib_ngc_deque_arr_DEQUE" viewtypedef DEQUE0 ( a:viewt@ype ) = [m,n:int] DEQUE (a, m, n) (* ****** ****** *) prfun lemma_deque_param {a:viewt@ype} {m,n:int} (x: &DEQUE (a, m, n)): [0 <= n; n <= m] void // end of [lemma_deque_param] (* ****** ****** *) fun deque_cap {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> size_t m fun deque_size {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> size_t n (* ****** ****** *) fun deque_is_empty {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> bool (n <= 0) fun deque_isnot_empty {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> bool (n > 0) fun deque_is_full {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> bool (m <= n) fun deque_isnot_full {a:viewt@ype} {m,n:int} (q: &DEQUE (a, m, n)):<> bool (m > n) (* ****** ****** *) // // HX: initializing to a deque of capacity [m] // fun{a:viewt@ype} deque_initialize {m:nat} {l:addr} ( pfgc: free_gc_v (a?, m, l) , pfarr: array_v (a?, m, l) | q: &DEQUE0(a)? >> DEQUE (a, m, 0) , m: size_t m, p: ptr l ) :<> void // end of [deque_initialize] fun deque_initialize_tsz {a:viewt@ype} {m:nat} {l:addr} ( pfgc: free_gc_v (a?, m, l) , pfarr: array_v (a?, m, l) | q: &DEQUE0(a)? >> DEQUE (a, m, 0) , m: size_t m , p: ptr l , tsz: sizeof_t a ) :<> void = "atslib_ngc_deque_arr_deque_initialize_tsz" // end of [deque_initialize_tsz] (* ****** ****** *) // // HX: uninitializeing a deque of nonlinear elements // fun deque_uninitialize {a:t@ype} {m,n:int} ( q: &DEQUE (a, m, n) >> DEQUE0(a)? ) :<> [l:addr] ( free_gc_v (a?, m, l), array_v (a?, m, l) | ptr l ) = "atslib_ngc_deque_arr_deque_uninitialize" // end of [deque_uninitialize] // // HX: uninitializeing an empty deque of capacity [m] // fun deque_uninitialize_vt {a:viewt@ype} {m:int} ( q: &DEQUE (a, m, 0) >> DEQUE0(a)? ) :<> [l:addr] ( free_gc_v (a?, m, l), array_v (a?, m, l) | ptr l ) // end of [deque_uninitialize_vt] (* ****** ****** *) // // HX-2011-03-06: // slightly unsafe but greatly convenient! // fun deque_takeout_tsz {a:viewt@ype} {m,n:int} {i:nat | i < n} ( q: &DEQUE (a, m, n) , i: size_t i, tsz: sizeof_t a ) :<> [l:addr] ( a @ l, a @ l - void | ptr l ) = "atslib_ngc_deque_arr_deque_takeout_tsz" (* ****** ****** *) fun{a:t@ype} deque_get_elt_at {m,n:int} {i:nat | i < n} ( q: &DEQUE (a, m, n), i: size_t i ) :<> a // end of [deque_get_elt_at] fun{a:t@ype} deque_set_elt_at {m,n:int} {i:nat | i < n} ( q: &DEQUE (a, m, n), i: size_t i, x: a ) :<> void // end of [deque_set_elt_at] (* ****** ****** *) fun{a:viewt@ype} deque_insert_beg (*first*) {m,n:int | m > n} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n+1), x: a ) :<> void // end of [deque_insert_beg] (* ****** ****** *) fun{a:viewt@ype} deque_insert_end (*last*) {m,n:int | m > n} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n+1), x: a ) :<> void // end of [deque_insert_end] fun{a:viewt@ype} deque_insert_end_many {m,n:int} {k:nat | n+k <= m} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n+k) , k: size_t k , xs: &(@[a][k]) >> @[a?!][k] ) :<> void // end of [deque_insert_end_many] fun deque_insert_end_many_tsz {a:viewt@ype} {m,n:int} {k:nat | n+k <= m} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n+k) , k: size_t k , xs: &(@[a][k]) >> @[a?!][k] , tsz: sizeof_t (a) ) :<> void = "atslib_ngc_deque_arr_deque_insert_end_many_tsz" // end of [deque_insert_end_many_tsz] (* ****** ****** *) fun{a:viewt@ype} deque_remove_beg (*first*) {m,n:int | n > 0} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n-1) ) :<> a // end of [deque_remove_beg] fun{a:viewt@ype} deque_remove_beg_many {m,n:int} {k:nat | k <= n} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n-k) , k: size_t k , xs: &(@[a?][k]) >> @[a][k] ) :<> void // end of [deque_remove_beg_many] fun deque_remove_beg_many_tsz {a:viewt@ype} {m,n:int} {k:nat | k <= n} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n-k) , k: size_t k , xs: &(@[a?][k]) >> @[a][k] , tsz: sizeof_t a ) :<> void = "atslib_ngc_deque_arr_deque_remove_beg_many_tsz" // end of [deque_remove_beg_many_tsz] (* ****** ****** *) fun{a:viewt@ype} deque_remove_end (*last*) {m,n:int | n > 0} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, n-1) ) :<> a // end of [deque_remove_end] (* ****** ****** *) fun{a:t@ype} deque_clear_beg {m,n1:int} {n2:nat | n2 <= n1} ( q: &DEQUE (a, m, n1) >> DEQUE (a, m, n1-n2), n2: size_t n2 ) :<> void // end of [deque_clear_beg] fun{a:t@ype} deque_clear_end {m,n1:int} {n2:nat | n2 <= n1} ( q: &DEQUE (a, m, n1) >> DEQUE (a, m, n1-n2), n2: size_t n2 ) :<> void // end of [deque_clear_end] fun deque_clear_all {a:t@ype} {m,n:int} ( q: &DEQUE (a, m, n) >> DEQUE (a, m, 0) ) :<> void // end of [deque_clear_all] (* ****** ****** *) fun deque_copyout_tsz {a:t@ype} {m,n:int} {i,k:nat | i+k <= n} ( q: &DEQUE (a, m, n) , i: size_t i , k: size_t k , xs: &(@[a?][k]) >> @[a][k] , tsz: sizeof_t a ) :<> void = "atslib_ngc_deque_arr_deque_copyout_tsz" // end of [deque_copyout_beg_tsz] fun{a:t@ype} deque_copyout {m,n:int} {i,k:nat | i+k <= n} ( q: &DEQUE (a, m, n) , i: size_t i , k: size_t k , xs: &(@[a?][k]) >> @[a][k] ) :<> void // end of [deque_copyout] (* ****** ****** *) fun{a:viewt@ype} deque_update_capacity {m1,n:int} {m2:nat | n <= m2} {l:addr} ( pfgc: free_gc_v (a?, m2, l) , pfarr: array_v (a?, m2, l) | q: &DEQUE (a, m1, n) >> DEQUE (a, m2, n) , m2: size_t (m2), parr: ptr l ) : [l:addr] ( free_gc_v (a?, m1, l), array_v (a?!, m1, l) | ptr l ) // end of [deque_update_capcity] fun deque_update_capacity_tsz {a:viewt@ype} {m1,n:int} {m2:nat | n <= m2} {l:addr} ( pfgc: free_gc_v (a?, m2, l) , pfarr: array_v (a?, m2, l) | q: &DEQUE (a, m1, n) >> DEQUE (a, m2, n) , m2: size_t (m2), parr: ptr l , tsz: sizeof_t (a) ) : [l:addr] ( free_gc_v (a?, m1, l), array_v (a?!, m1, l) | ptr l ) = "atslib_ngc_deque_arr_deque_update_capacity_tsz" (* ****** ****** *) (* end of [deque_arr.sats] *) ats-lang-anairiats-0.2.11/libats/ngc/DATS/0000700000175000017500000000000012223166162016541 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/ngc/DATS/linmap_avltree.dats0000664000175000017500000005771612223166162022454 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by ** Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) ** Time: January, 2012 // based on a version done by HX in May, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/ngc/SATS/linmap_avltree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) // // HX-2010-03-24: this seems to work best! // #define HTDF 1 // max height difference #define HTDF1 %(HTDF+1) #define HTDF_1 %(HTDF-1) (* ****** ****** *) dataview avltree_v ( key:t@ype , itm:viewt@ype+ , int(*height*) , addr(*self*) ) = | {ll,lr:addr} {hl,hr:nat | hl <= hr+HTDF; hr <= hl+HTDF} {h:int | h == 1+max(hl,hr)} {slf:agz} B (key, itm, h, slf) of ( avlnode_v (key, itm, h, ll, lr, slf) , avltree_v (key, itm, hl, ll) , avltree_v (key, itm, hr, lr) ) // end of [B] | E (key, itm, 0, null) // end of [dataview avltree_v] viewdef avltree_v_inc (key:t@ype, itm:viewt@ype, h:int, l:addr) = [h1:nat | h <= h1; h1 <= h+1] avltree_v (key, itm, h1, l) // end of [avltree_v_inc] viewdef avltree_v_dec (key:t@ype, itm:viewt@ype, h:int, l:addr) = [h1:nat | h1 <= h; h <= h1+1] avltree_v (key, itm, h1, l) // end of [avltree_v_dec] (* ****** ****** *) assume map_t0ype_viewt0ype_type ( key:t@ype, itm:viewt@ype ) = [l:addr] [h:nat] (avltree_v (key, itm, h, l) | ptr l) // end of [map_t0ype_viewt0ype_type] (* ****** ****** *) implement{} linmap_make_nil () = (E () | null) (* ****** ****** *) implement{} linmap_is_nil (t) = t.1 = null implement{} linmap_isnot_nil (t) = t.1 > null (* ****** ****** *) implement{key,itm} linmap_size (t) = size (t.0 | t.1) where { fun size {h:nat} {l:addr} .. ( pf: !avltree_v (key, itm, h, l) | p: ptr l ) :<> size_t = if p > null then let prval B (pf_at, pf_l, pf_r) = pf val res = size (pf_l | avlnode_get_left (pf_at | p)) + 1 + size (pf_r | avlnode_get_right (pf_at | p)) // end of [val] prval () = pf := B (pf_at, pf_l, pf_r) in res end else size_of_int 0 // end of [if] // end of [size] } // end of [where] (* ****** ****** *) fn{key:t0p;itm:vt0p} avltree_height {h:nat} {l:addr} ( pf: !avltree_v (key, itm, h, l) | p: ptr l ) :<> int h = if p > null then let prval B (pf_at, pf_l, pf_r) = pf val h = avlnode_get_height (pf_at | p) prval () = pf := B (pf_at, pf_l, pf_r) in h end else let prval E () = pf; prval () = pf := E {key,itm} () in 0 end // end of [if] // end of [avltree_height] implement{key,itm} linmap_height (t) = avltree_height (t.0 | t.1) (* ****** ****** *) implement{key,itm} linmap_search (t, k0, cmp, res) = search (t.0 | t.1, res) where { fun search {h:nat} {slf:addr} .. ( pf: !avltree_v (key, itm, h, slf) | p: ptr slf, res: &itm? >> opt (itm, b) ) : #[b:bool] bool b = if p > null then let prval B (pf_at, pf_l, pf_r) = pf val sgn = compare_key_key (k0, avlnode_get_key (pf_at | p), cmp) in if sgn < 0 then let val tag = search (pf_l | avlnode_get_left (pf_at | p), res) prval () = pf := B (pf_at, pf_l, pf_r) in tag end else if sgn > 0 then let val tag = search (pf_r | avlnode_get_right (pf_at | p), res) prval () = pf := B (pf_at, pf_l, pf_r) in tag end else let val ( pf1_at, fpf | p1 ) = avlnode_takeout_val (pf_at | p) val () = res := !p1 prval () = pf_at := fpf (pf1_at) prval () = opt_some {itm} (res) // [itm] is a t@ype prval () = pf := B (pf_at, pf_l, pf_r) in true // item associated with the key [k0] is found end // end of [if] end else let prval () = opt_none {itm} (res) in false end // end of [if] // end of [search] } // end of [linmap_search] (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} avltree_lrotate {h:int;hl,hr:nat | hl+HTDF1 == hr} {l_t:agz;l_tl,l_tr:addr} ( pf_nod: avlnode_v (key, itm, h, l_tl, l_tr, l_t) , pf_tl: avltree_v (key, itm, hl, l_tl) , pf_tr: avltree_v (key, itm, hr, l_tr) | p: ptr l_t, hl: int hl, hr: int hr ) :<> [l:agz] (avltree_v_inc (key, itm, hr, l) | ptr l) = let val p_tl = avlnode_get_left (pf_nod | p) and p_tr = avlnode_get_right (pf_nod | p) prval B {..} {hrl,hrr} (pf_rnod, pf_trl, pf_trr) = pf_tr val p_trl = avlnode_get_left (pf_rnod | p_tr) and p_trr = avlnode_get_right (pf_rnod | p_tr) val hrl = avltree_height (pf_trl | p_trl) and hrr = avltree_height (pf_trr | p_trr) in if hrl <= hrr+HTDF_1 then let val hrl1 = hrl + 1 val () = avlnode_set_height (pf_nod | p, hrl1) val () = avlnode_set_right (pf_nod | p, p_trl) prval pf_t = B (pf_nod, pf_tl, pf_trl) val () = avlnode_set_height (pf_rnod | p_tr, 1+max(hrl1,hrr)) val () = avlnode_set_left (pf_rnod | p_tr, p) prval pf_tr = B (pf_rnod, pf_t, pf_trr) in (pf_tr | p_tr) // B (1+max(hrl1,hrr), kr, xr, B (hrl1, k, x, tl, trl), trr) end else let // [hrl=hrr+2]: deep rotation prval B {..} {hrll,hrlr} (pf_rlnod, pf_trll, pf_trlr) = pf_trl val p_trll = avlnode_get_left (pf_rlnod | p_trl) and p_trlr = avlnode_get_right (pf_rlnod | p_trl) val hrll = avltree_height (pf_trll | p_trll) and hrlr = avltree_height (pf_trlr | p_trlr) val () = avlnode_set_height (pf_nod | p, 1+max(hl,hrll)) val () = avlnode_set_right (pf_nod | p, p_trll) prval pf_t = B (pf_nod, pf_tl, pf_trll) val () = avlnode_set_height (pf_rnod | p_tr, 1+max(hrlr, hrr)) val () = avlnode_set_left (pf_rnod | p_tr, p_trlr) prval pf_tr = B (pf_rnod, pf_trlr, pf_trr) val () = avlnode_set_height (pf_rlnod | p_trl, hr) val () = avlnode_set_left (pf_rlnod | p_trl, p) val () = avlnode_set_right (pf_rlnod | p_trl, p_tr) prval pf_trl = B (pf_rlnod, pf_t, pf_tr) in (pf_trl | p_trl) // B (hr, krl, xrl, B (1+max(hl,hrll), k, x, tl, trll), B (1+max(hrlr,hrr), kr, xr, trlr, trr)) end // end of [if] end // end of [avltree_lrotate] (* ** right rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} avltree_rrotate {h:int;hl,hr:nat | hl==hr+HTDF1} {l_t:agz;l_tl,l_tr:addr} ( pf_nod: avlnode_v (key, itm, h, l_tl, l_tr, l_t) , pf_tl: avltree_v (key, itm, hl, l_tl) , pf_tr: avltree_v (key, itm, hr, l_tr) | p: ptr l_t, hl: int hl, hr: int hr ) :<> [l:agz] (avltree_v_inc (key, itm, hl, l) | ptr l) = let val p_tl = avlnode_get_left (pf_nod | p) and p_tr = avlnode_get_right (pf_nod | p) prval B {..} {hll,hlr} (pf_lnod, pf_tll, pf_tlr) = pf_tl val p_tll = avlnode_get_left (pf_lnod | p_tl) and p_tlr = avlnode_get_right (pf_lnod | p_tl) val hll = avltree_height (pf_tll | p_tll) and hlr = avltree_height (pf_tlr | p_tlr) in if hll+HTDF_1 >= hlr then let val hlr1 = hlr + 1 val () = avlnode_set_height (pf_nod | p, hlr1) val () = avlnode_set_left (pf_nod | p, p_tlr) prval pf_t = B (pf_nod, pf_tlr, pf_tr) val () = avlnode_set_height (pf_lnod | p_tl, 1+max(hll,hlr1)) val () = avlnode_set_right (pf_lnod | p_tl, p) prval pf_tl = B (pf_lnod, pf_tll, pf_t) in (pf_tl | p_tl) // B (1+max(hll,hlr1), kl, xl, tll, B (hlr1, k, x, tlr, tr)) end else let prval B {..} {hlrl,hlrr} (pf_lrnod, pf_tlrl, pf_tlrr) = pf_tlr val p_tlrl = avlnode_get_left (pf_lrnod | p_tlr) and p_tlrr = avlnode_get_right (pf_lrnod | p_tlr) val hlrl = avltree_height (pf_tlrl | p_tlrl) val hlrr = avltree_height (pf_tlrr | p_tlrr) val () = avlnode_set_height (pf_nod | p, 1+max(hlrr,hr)) val () = avlnode_set_left (pf_nod | p, p_tlrr) prval pf_t = B (pf_nod, pf_tlrr, pf_tr) val () = avlnode_set_height (pf_lnod | p_tl, 1+max(hll,hlrl)) val () = avlnode_set_right (pf_lnod | p_tl, p_tlrl) prval pf_tl = B (pf_lnod, pf_tll, pf_tlrl) val () = avlnode_set_height (pf_lrnod | p_tlr, hl) val () = avlnode_set_left (pf_lrnod | p_tlr, p_tl) val () = avlnode_set_right (pf_lrnod | p_tlr, p) prval pf_tlr = B (pf_lrnod, pf_tl, pf_t) in (pf_tlr | p_tlr) // B (hl, klr, xlr, B (1+max(hll,hlrl), kl, xl, tll, tlrl), B (1+max(hlrr,hr), k, x, tlrr, tr)) end // end of [if] end // end of [avltree_rrotate] (* ****** ****** *) implement{key,itm} linmap_insert {l} (pf_nod | m, p, cmp) = let // fun insert {l_at,l_t:addr} {h:nat} .. ( pf_t: !avltree_v (key, itm, h, l_t) >> avltree_v_inc (key, itm, h, l_t1) , pf_at: !avlnode_v (key, itm, l_at) >> option_v (avlnode_v (key, itm, l_at1), b) | p0: &ptr l_at >> ptr l_at1, p: &ptr l_t >> ptr l_t1, cmp: cmp key ) :<> #[b:bool;l_t1,l_at1:addr] bool b = if p > null then let prval B (pf1_at, pf_tl, pf_tr) = pf_t val sgn = compare_key_key (avlnode_get_key (pf_at | p0), avlnode_get_key (pf1_at | p), cmp) // end of [val] var p_tl = avlnode_get_left (pf1_at | p) and p_tr = avlnode_get_right (pf1_at | p) in if sgn < 0 then let val ans = insert (pf_tl, pf_at | p0, p_tl, cmp) val () = avlnode_set_left (pf1_at | p, p_tl) val hl = avltree_height (pf_tl | p_tl) and hr = avltree_height (pf_tr | p_tr) in if hl - hr <= HTDF then let val () = avlnode_set_height (pf1_at | p, 1+max(hl,hr)) prval () = pf_t := B {key,itm} (pf1_at, pf_tl, pf_tr) in ans // B (1+max(hl,hr), k, x, tl, tr) end else let // hl = hr+HTDF1 val (pf1 | p1) = avltree_rrotate (pf1_at, pf_tl, pf_tr | p, hl, hr) prval () = pf_t := pf1 val () = p := p1 in ans end // end of [if] end else if sgn > 0 then let val ans = insert (pf_tr, pf_at | p0, p_tr, cmp) val () = avlnode_set_right (pf1_at | p, p_tr) val hl = avltree_height (pf_tl | p_tl) and hr = avltree_height (pf_tr | p_tr) in if hr - hl <= HTDF then let val () = avlnode_set_height (pf1_at | p, 1+max(hl, hr)) prval () = pf_t := B (pf1_at, pf_tl, pf_tr) in ans // B (1+max(hl, hr), k, x, tl, tr) end else let // hl+HTDF1 = hr val (pf1 | p1) = avltree_lrotate (pf1_at, pf_tl, pf_tr | p, hl, hr) prval () = pf_t := pf1 val () = p := p1 in ans end // end of [if] end else let (* key already exists *) // swap the two nodes val () = avlnode_set_height (pf_at | p0, avlnode_get_height (pf1_at | p)) val () = avlnode_set_left (pf_at | p0, avlnode_get_left (pf1_at | p)) val () = avlnode_set_right (pf_at | p0, avlnode_get_right (pf1_at | p)) val tmp = p val () = p := p0 val () = p0 := tmp prval () = avlnode_ptr_is_gtz (pf_at) prval () = pf_t := B (pf_at, pf_tl, pf_tr) prval () = pf_at := Some_v (pf1_at) in true // B (h, k, x0, tl, tr) end // end of [if] end else let // a new node is created prval E () = pf_t val () = avlnode_set_height (pf_at | p0, 1) val () = avlnode_set_left (pf_at | p0, null) val () = avlnode_set_right (pf_at | p0, null) prval () = avlnode_ptr_is_gtz (pf_at) prval () = pf_t := B {key,itm} (pf_at, E (), E ()) val () = p := p0 prval () = pf_at := None_v () in false end // end of [if] in insert (m.0, pf_nod | p, m.1, cmp) end // end of [linmap_insert] (* ****** ****** *) fun{key:t0p;itm:vt0p} avltree_takeout_min {h:pos} {l_t:addr} .. ( pf_t: !avltree_v (key, itm, h, l_t) >> avltree_v_dec (key, itm, h, l_t1) | p_t: &ptr l_t >> ptr l_t1 ) :<> #[l_t1:addr] [l:addr] (avlnode_v (key, itm, l) | ptr l) = let prval B (pf_nod, pf_tl, pf_tr) = pf_t var p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) in if p_tl > null then let prval B (pf_lnod, pf_tll, pf_tlr) = pf_tl prval () = pf_tl := B (pf_lnod, pf_tll, pf_tlr) val (pf_at | p_at) = avltree_takeout_min (pf_tl | p_tl) val hl = avltree_height (pf_tl | p_tl) val hr = avltree_height (pf_tr | p_tr) val () = avlnode_set_left (pf_nod | p_t, p_tl) in if hr - hl <= HTDF then let val () = avlnode_set_height (pf_nod | p_t, 1+max(hl,hr)) prval () = pf_t := B (pf_nod, pf_tl, pf_tr) in (pf_at | p_at) end else let val (pf_t1 | p_t1) = avltree_lrotate (pf_nod, pf_tl, pf_tr | p_t, hl, hr) // end of [val] val () = p_t := p_t1 prval () = pf_t := pf_t1 in (pf_at | p_at) end // end of [if] end else let prval E () = pf_tl prval () = pf_t := pf_tr val p_res = p_t val () = p_t := avlnode_get_right (pf_nod | p_t) in (pf_nod | p_res) end // end of [if] end // end of [avltree_takeout_min] (* ****** ****** *) implement{key,itm} linmap_takeout (m, k0, cmp) = takeout (m.0 | m.1) where { fun takeout {h:nat} {l0:addr} .. ( pf_t: !avltree_v (key, itm, h, l0) >> avltree_v_dec (key, itm, h, l1) | p_t: &ptr l0 >> ptr l1 ) : #[l1:addr] [l_at:addr] ( option_v (avlnode_v (key, itm, l_at), l_at > null) | ptr l_at ) = begin if p_t > null then let prval B (pf_nod, pf_tl, pf_tr) = pf_t val sgn = compare_key_key (k0, avlnode_get_key (pf_nod | p_t), cmp) var p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) in case+ 0 of | _ when sgn < 0 => let val ans(*removed*) = takeout (pf_tl | p_tl) val () = avlnode_set_left (pf_nod | p_t, p_tl) val hl = avltree_height (pf_tl | p_tl) and hr = avltree_height (pf_tr | p_tr) in if hr - hl <= HTDF then let val () = avlnode_set_height (pf_nod | p_t, 1+max(hl,hr)) prval () = pf_t := B (pf_nod, pf_tl, pf_tr) in ans end else let // hl+HTDF1 = hr val (pf_t1 | p_t1) = avltree_lrotate (pf_nod, pf_tl, pf_tr | p_t, hl, hr) val () = p_t := p_t1 prval () = pf_t := pf_t1 in ans end // end of [if] end // end of [sgn < 0] | _ when sgn > 0 => let val ans = takeout (pf_tr | p_tr) val () = avlnode_set_right (pf_nod | p_t, p_tr) val hl = avltree_height (pf_tl | p_tl) and hr = avltree_height (pf_tr | p_tr) in if hl - hr <= HTDF then let val () = avlnode_set_height (pf_nod | p_t, 1+max(hl,hr)) prval () = pf_t := B (pf_nod, pf_tl, pf_tr) in ans end else let // hl=hr+HTDF1 val (pf_t1 | p_t1) = avltree_rrotate (pf_nod, pf_tl, pf_tr | p_t, hl, hr) // end of [val] val () = p_t := p_t1 prval () = pf_t := pf_t1 in ans end // end of [if] end // end of [sgn > 0] | _ (*sgn = 0*) => let stavar l_res: addr val p_res = p_t: ptr l_res prval () = avlnode_ptr_is_gtz (pf_nod) prval pf_res = Some_v (pf_nod): option_v (avlnode_v (key, itm, l_res), l_res > null) in if p_tr > null then let prval B (pf1_nod, pf1_tl, pf1_tr) = pf_tr prval () = pf_tr := B (pf1_nod, pf1_tl, pf1_tr) val (pf_t1 | p_t1) = avltree_takeout_min (pf_tr | p_tr) prval () = avlnode_ptr_is_gtz (pf_t1) val hl = avltree_height (pf_tl | p_tl) and hr = avltree_height (pf_tr | p_tr) val () = avlnode_set_left (pf_t1 | p_t1, p_tl) val () = avlnode_set_right (pf_t1 | p_t1, p_tr) in if hl - hr <= HTDF then let val () = avlnode_set_height (pf_t1 | p_t1, 1+max(hl,hr)) val () = p_t := p_t1 prval () = pf_t := B {key,itm} (pf_t1, pf_tl, pf_tr) in (pf_res | p_res) end else let val (pf_t1 | p_t1) = avltree_rrotate (pf_t1, pf_tl, pf_tr | p_t1, hl, hr) prval () = pf_t := pf_t1 val () = p_t := p_t1 in (pf_res | p_res) end // end of [if] end else let prval E () = pf_tr val () = p_t := p_tl prval () = pf_t := pf_tl in (pf_res | p_res) end // end of [if] end // end of [sgn = 0] // end // end of [B] end else let prval E () = pf_t prval () = pf_t := E {key,itm} () val () = p_t := null stavar l_res: addr val p_res = null: ptr l_res prval pf_res = None_v (): option_v (avlnode_v (key, itm, l_res), l_res > null) in (pf_res | p_res) end // end of [if] end // end of [takeout] } // end of [linmap_takeout] (* ****** ****** *) implement{key,itm} linmap_remove (m, k0, cmp) = let val (pf | p) = linmap_takeout (m, k0, cmp) in if p > null then let prval Some_v (pf_nod) = pf in avlnode_free (pf_nod | p); true end else let prval None_v () = pf in false end // end of [if] end // end of [linmap_remove] (* ****** ****** *) implement{key,itm} linmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf, m.0 | m.1, env) where { // fun foreach {h:nat} {l:addr} .. ( pfv: !v , pf1: !avltree_v (key, itm, h, l) | p_t: ptr l, env: !vt ) : void = if p_t > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = avlnode_get_key (pf_nod | p_t) and p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) val () = foreach (pfv, pf_tl | p_tl, env) val (pf_at, fpf | p) = avlnode_takeout_val (pf_nod | p_t) val () = f (pfv | k, !p, env) prval () = pf_nod := fpf {itm} (pf_at) val () = foreach (pfv, pf_tr | p_tr, env) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [foreach] } // end of [linmap_foreach_funenv] implement{key,itm} linmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, &itm) - void):<> (!unit_v | key, &itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [linmap_foreach_fun] (* ****** ****** *) implement{key,itm} linmap_foreach_vclo {v} (pf | m, f) = foreach (pf, m.0 | m.1, f) where { // fun foreach {h:nat} {l:addr} .. ( pfv: !v , pf1: !avltree_v (key, itm, h, l) | p_t: ptr l , f: &(!v | key, &itm) - void ) :<> void = if p_t > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = avlnode_get_key (pf_nod | p_t) and p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) val () = foreach (pfv, pf_tl | p_tl, f) val (pf_at, fpf | p) = avlnode_takeout_val (pf_nod | p_t) val () = f (pfv | k, !p) prval () = pf_nod := fpf {itm} (pf_at) val () = foreach (pfv, pf_tr | p_tr, f) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [foreach] } // end of [linmap_foreach_vclo] (* ****** ****** *) implement{key,itm} linmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf, m.0 | m.1, env) where { // fun rforeach {h:nat} {l:addr} .. ( pfv: !v , pf1: !avltree_v (key, itm, h, l) | p_t: ptr l, env: !vt ) : void = if p_t > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = avlnode_get_key (pf_nod | p_t) and p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) val () = rforeach (pfv, pf_tr | p_tr, env) val (pf_at, fpf | p) = avlnode_takeout_val (pf_nod | p_t) val () = f (pfv | k, !p, env) prval () = pf_nod := fpf {itm} (pf_at) val () = rforeach (pfv, pf_tl | p_tl, env) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [rforeach] } // end of [linmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} linmap_clear_funenv {v} {vt} ( pfv | m, f, env ) = let typedef FT1 = (!v | key, &itm >> itm?, !vt) - void typedef FT2 = (!v | key, &itm >> itm , !vt) - void val () = let extern castfn __cast (f: FT1):<> FT2 in linmap_foreach_funenv (pfv | m, __cast(f), env) end // end of [val] prval () = __assert (m) where { extern praxi __assert (m: !map (key, itm) >> map (key, itm?)): void } // end of [val] in // nothing end // end of [linmap_clear_funenv] (* ****** ****** *) implement{key,itm} linmap_free (m) = let // // HX: freeing is done in the inord fashion // fun _free {h:nat} {l:addr} .. ( pf1: avltree_v (key, itm, h, l) | p_t: ptr l ) : void = if p_t > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val p_tl = avlnode_get_left (pf_nod | p_t) and p_tr = avlnode_get_right (pf_nod | p_t) val () = avlnode_free (pf_nod | p_t) val () = _free (pf_tl | p_tl) and () = _free (pf_tr | p_tr) in // nothing end else let prval E () = pf1 in // nothing end // end of [if] // end of [_free] in _free (m.0 | m.1) end // end of [linmap_free] (* ****** ****** *) implement{key,itm} linmap_free_vt (m) = if m.1 > null then let prval () = opt_some {map (key, itm)} (m) in true end else let // m.1 = null prval E () = m.0 prval () = opt_none {map (key, itm)} (m) in false end // end of [if] // end of [linmap_free_vt] (* ****** ****** *) (* end of [linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/ngc/DATS/linmap_pavltree.dats0000664000175000017500000012434412223166162022624 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees with parent pointers ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by ** Artyom Shalkhakov (artyom DOT shalkhakov AT gmail DOT com) ** Time: January, 2012 // based on a version done by HX in August, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/ngc/SATS/linmap_pavltree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) viewdef pavlnode0_v (key:t0p, itm:vt0p, slf:addr) = [h:int;lft,rgt,pnt:addr] pavlnode_v (key, itm, h, lft, rgt, pnt, slf) // end of [pavlnode0_v] (* ****** ****** *) dataview pavltree_v ( key:t@ype , itm:viewt@ype+ , int(*height*) , addr(*parent*) , addr(*self*) ) = | {ll,lr,lp:addr} {hl,hr:nat | hl <= hr+1; hr <= hl+1} {h:int | h == 1+max(hl,hr)} {slf:agz} B (key, itm, h, lp, slf) of ( pavlnode_v (key, itm, h, ll, lr, lp, slf) , pavltree_v (key, itm, hl, slf, ll) , pavltree_v (key, itm, hr, slf, lr) ) // end of [B] | {lp:addr} E (key, itm, 0, lp, null) // end of [dataview pavltree_v] viewdef pavltree_v_inc (key:t@ype, itm:viewt@ype, h:int, p:addr, l:addr) = [h1:nat | h <= h1; h1 <= h+1] pavltree_v (key, itm, h1, p, l) // end of [pavltree_v_inc] viewdef pavltree_v_dec (key:t@ype, itm:viewt@ype, h:int, p:addr, l:addr) = [h1:nat | h1 <= h; h <= h1+1] pavltree_v (key, itm, h1, p, l) // end of [pavltree_v_dec] (* ****** ****** *) fn{key:t0p;itm:vt0p} pavltree_height_get {h:nat} {pnt,slf:addr} (pf: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf):<> int h = if p > null then let prval B (pf_at, pf_tl, pf_tr) = pf val h = pavlnode_get_height (pf_at | p) prval () = pf := B (pf_at, pf_tl, pf_tr) in h end else let prval E () = pf; prval () = pf := E {key,itm} {pnt} () in 0 end // end of [if] // end of [pavltree_height_get] (* ****** ****** *) fn{key:t0p;itm:vt0p} pavltree_parent_set {h:nat} {pnt0,slf,pnt1:addr} ( pf: !pavltree_v (key, itm, h, pnt0, slf) >> pavltree_v (key, itm, h, pnt1, slf) | p: ptr slf, pp1: ptr pnt1 ) :<> void = if p > null then let prval B (pf_at, pf_tl, pf_tr) = pf val () = pavlnode_set_parent (pf_at | p, pp1) prval () = pf := B (pf_at, pf_tl, pf_tr) in // nothing end else let prval E () = pf; prval () = pf := E {key,itm} {pnt1} () in // nothing end // end of [if] // end of [pavltree_parent_set] (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} pavltree_lrotate {h:int} {hl,hr:nat | hl+2 == hr} {slf:agz;lft,rgh,pnt:addr} ( pf_at: pavlnode_v (key, itm, h, lft, rgh, pnt, slf) , pf_tl: pavltree_v (key, itm, hl, slf, lft) , pf_tr: pavltree_v (key, itm, hr, slf, rgh) | p: ptr slf ) :<> [slf:agz] (pavltree_v_inc (key, itm, hr, pnt, slf) | ptr slf) = let val pp = pavlnode_get_parent (pf_at | p) and pl = pavlnode_get_left (pf_at | p) and pr = pavlnode_get_right (pf_at | p) prval B (pfr_at, pf_trl, pf_trr) = pf_tr val prl = pavlnode_get_left (pfr_at | pr) and prr = pavlnode_get_right (pfr_at | pr) val hrl = pavltree_height_get (pf_trl | prl) and hrr = pavltree_height_get (pf_trr | prr) in if hrl <= hrr then begin pavlnode_set_height (pfr_at | pr, hrl+2); pavlnode_set_parent (pfr_at | pr, pp); pavlnode_set_left (pfr_at | pr, p); pavlnode_set_height (pf_at | p, hrl+1); pavlnode_set_parent (pf_at | p, pr); pavlnode_set_right (pf_at | p, prl); pavltree_parent_set (pf_trl | prl, p); (B {key,itm} (pfr_at, B {key,itm} (pf_at, pf_tl, pf_trl), pf_trr) | pr) end else let // [hrl > hrr]: deep rotation val hr = pavlnode_get_height (pfr_at | pr) prval B (pfrl_at, pf_trll, pf_trlr) = pf_trl val prll = pavlnode_get_left (pfrl_at | prl) and prlr = pavlnode_get_right (pfrl_at | prl) in pavlnode_set_height (pfrl_at | prl, hr); pavlnode_set_parent (pfrl_at | prl, pp); pavlnode_set_left (pfrl_at | prl, p); pavlnode_set_right (pfrl_at | prl, pr); pavlnode_set_height (pf_at | p, hrl); pavlnode_set_parent (pf_at | p, prl); pavlnode_set_right (pf_at | p, prll); pavlnode_set_height (pfr_at | pr, hrl); pavlnode_set_parent (pfr_at | pr, prl); pavlnode_set_left (pfr_at | pr, prlr); pavltree_parent_set (pf_trll | prll, p); pavltree_parent_set (pf_trlr | prlr, pr); (B {key,itm} (pfrl_at, B {key,itm} (pf_at, pf_tl, pf_trll), B {key,itm} (pfr_at, pf_trlr, pf_trr)) | prl) end // end of [if] end // end of [avltree_lrotate] (* ****** ****** *) (* ** right rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} pavltree_rrotate {h:int} {hl,hr:nat | hl == hr+2} {slf:agz;lft,rgh,pnt:addr} ( pf_at: pavlnode_v (key, itm, h, lft, rgh, pnt, slf) , pf_tl: pavltree_v (key, itm, hl, slf, lft) , pf_tr: pavltree_v (key, itm, hr, slf, rgh) | p: ptr slf ) :<> [slf:agz] (pavltree_v_inc (key, itm, hl, pnt, slf) | ptr slf) = let val pp = pavlnode_get_parent (pf_at | p) and pl = pavlnode_get_left (pf_at | p) and pr = pavlnode_get_right (pf_at | p) prval B (pfl_at, pf_tll, pf_tlr) = pf_tl val pll = pavlnode_get_left (pfl_at | pl) and plr = pavlnode_get_right (pfl_at | pl) val hll = pavltree_height_get (pf_tll | pll) and hlr = pavltree_height_get (pf_tlr | plr) in if hll >= hlr then begin pavlnode_set_height (pfl_at | pl, hlr+2); pavlnode_set_parent (pfl_at | pl, pp); pavlnode_set_right (pfl_at | pl, p); pavlnode_set_height (pf_at | p, hlr+1); pavlnode_set_parent (pf_at | p, pl); pavlnode_set_left (pf_at | p, plr); pavltree_parent_set (pf_tlr | plr, p); (B {key,itm} (pfl_at, pf_tll, B {key,itm} (pf_at, pf_tlr, pf_tr)) | pl) end else let // [hll < hlr]: deep rotation val hl = pavlnode_get_height (pfl_at | pl) prval B (pflr_at, pf_tlrl, pf_tlrr) = pf_tlr val plrl = pavlnode_get_left (pflr_at | plr) and plrr = pavlnode_get_right (pflr_at | plr) in pavlnode_set_height (pflr_at | plr, hl); pavlnode_set_parent (pflr_at | plr, pp); pavlnode_set_left (pflr_at | plr, pl); pavlnode_set_right (pflr_at | plr, p); pavlnode_set_height (pfl_at | pl, hlr); pavlnode_set_parent (pfl_at | pl, plr); pavlnode_set_right (pfl_at | pl, plrl); pavlnode_set_height (pf_at | p, hlr); pavlnode_set_parent (pf_at | p, plr); pavlnode_set_left (pf_at | p, plrr); pavltree_parent_set (pf_tlrl | plrl, pl); pavltree_parent_set (pf_tlrr | plrr, p); (B {key,itm} (pflr_at, B {key,itm} (pfl_at, pf_tll, pf_tlrl), B {key,itm} (pf_at, pf_tlrr, pf_tr)) | plr) end // end of [if] end // end of [pavlnode_rrotate] (* ****** ****** *) dataview pavldiff_v ( key:t@ype , itm:viewt@ype+ , (*height*)int , (*missing subtree height*)int , (*child: root of the missing pavltree*)addr , (*direction: left(0) or right(1)*)int , (*root*)addr , (*root parent*)addr , (*self*)addr ) = (* view for a pavltree minus a sub pavltree *) | {n,h:nat | h <= n} {hl,hr:nat | hl <= hr+1; hr <= hl+1; h==max(hl,hr)+1} {lft,rgh,pnt:addr} {dir:two} {rt,rtp:addr} {slf:agz} B1L (key, itm, n, hl, lft, 0, rt, rtp, slf) of ( pavlnode_v (key, itm, h, lft, rgh, pnt, slf) , pavldiff_v (key, itm, n, h, slf, dir, rt, rtp, pnt) , pavltree_v (key, itm, hr, slf, rgh) ) // end of [B1L] | {n,h:nat | h <= n} {hl,hr:nat | hl <= hr+1; hr <= hl+1; h==max(hl,hr)+1} {lft,rgh,pnt:addr} {dir:two} {rt,rtp:addr} {slf:agz} B1R (key, itm, n, hr, rgh, 1, rt, rtp, slf) of ( pavlnode_v (key, itm, h, lft, rgh, pnt, slf) , pavltree_v (key, itm, hl, slf, lft) , pavldiff_v (key, itm, n, h, slf, dir, rt, rtp, pnt) ) // end of [B1R] | {h:nat} {chld:addr} {dir:two} {slf:addr} E1 (key, itm, h, h, chld, dir, chld, slf, slf) of () // end of [pavldiff_v] (* ****** ****** *) prfun pavldiff_pavltree_join {key:t0p;itm:vt0p} {n,h:nat | h <= n} {chld:addr} {dir:two} {rt,rtp,slf:addr} .. ( fpf: pavldiff_v (key, itm, n, h, chld, dir, rt, rtp, slf) , pf0: pavltree_v (key, itm, h, slf, chld) ) :<> pavltree_v (key, itm, n, rtp, rt) = case+ fpf of | B1L (pf_at, fpfl, pfr) => pavldiff_pavltree_join (fpfl, B (pf_at, pf0, pfr)) | B1R (pf_at, pfl, fpfr) => pavldiff_pavltree_join (fpfr, B (pf_at, pfl, pf0)) | E1 () => pf0 // end of [pavldiff_pavltree_join] (* ****** ****** *) prfn pavldiff_takeout {key:t0p;itm:vt0p} {n,h:int} {chld:addr} {dir:int} {rt,rtp:addr} {slf:addr | slf <> rtp} ( fpf: pavldiff_v (key, itm, n, h, chld, dir, rt, rtp, slf) ) :<> [h0:int;lft,rgh,pnt:addr] ( pavlnode_v (key, itm, h0, lft, rgh, pnt, slf) , pavlnode_v (key, itm, h0, lft, rgh, pnt, slf) - pavldiff_v (key, itm, n, h, chld, dir, rt, rtp, slf) ) = case+ fpf of | B1L {..} {_,h0} {..} {lft,rgh,pnt} {..} {rt,rtp} (pf_at, fpfl, pfr) => #[h0,lft,rgh,pnt | (pf_at, llam (pf_at) => B1L (pf_at, fpfl, pfr))] // end of [B1L] | B1R {..} {_,h0} {..} {lft,rgh,pnt} {..} {rt,rtp} (pf_at, pfl, fpfr) => #[h0,lft,rgh,pnt | (pf_at, llam (pf_at) => B1R (pf_at, pfl, fpfr))] // end of [B1R] // end of [pavldiff_takeout] (* ****** ****** *) fn{key:t0p;itm:vt0p} pavldiff_dir_get {n,h:int} {chld:addr | chld > null} {dir:int} {rt:addr} {slf:addr} ( fpf: !pavldiff_v (key, itm, n, h, chld, dir, rt, null, slf) | p: ptr slf, pc: ptr chld ) :<> int dir = let val dir = if p > null then let prval (pf_at, ffpf) = pavldiff_takeout (fpf) val dir = (if pc = pavlnode_get_left (pf_at | p) then 0(*left*) else 1(*right*)): int prval () = fpf := ffpf (pf_at) in dir end else begin 0 // it is arbitrarily chosen (from {0,1}) end : int in __cast (dir) where { extern castfn __cast (_: int):<> int dir } end // end of [pavldiff_dir_get] (* ****** ****** *) fn{key:t0p;itm:vt0p} pavldiff_child_set {n,h:int} {chld:addr} {dir:int} {rt,rtp:addr} {slf:addr | slf <> rtp} {chld1:addr} ( fpf: !pavldiff_v (key, itm, n, h, chld, dir, rt, rtp, slf) >> pavldiff_v (key, itm, n, h, chld1, dir, rt, rtp, slf) // end of [fpf] | p: ptr slf, dir: int dir, pc1: ptr chld1 ) :<> void = if dir = 0 then let prval B1L (pf_at, fpf1, pf2) = fpf val () = pavlnode_set_left (pf_at | p, pc1) prval () = fpf := B1L (pf_at, fpf1, pf2) in // nothing end else let prval B1R (pf_at, pf1, fpf2) = fpf val () = pavlnode_set_right (pf_at | p, pc1) prval () = fpf := B1R (pf_at, pf1, fpf2) in // nothing end // end of [if] // end of [pavldiff_child_set] (* ****** ****** *) extern fun{key:t0p;itm:vt0p} pavltree_split {h0:nat} {rt:addr} ( pf: pavltree_v (key, itm, h0, null, rt) | p: &ptr rt >> ptr slf, k0: key, dir: &int 0 >> int dir, cmp: cmp key ) :<> #[dir:two;slf:addr] [h1:nat | h1 <= h0;chld:addr] ( pavldiff_v (key, itm, h0, h1, chld, dir, rt, null, slf), pavltree_v (key, itm, h1, slf, chld) | ptr chld ) // end of [pavltree_split] implement{key,itm} pavltree_split {h0} {rt} (pf | p, k0, dir, cmp) = let fun loop {h:nat | h <= h0} {chld:addr} {dir:two} {slf:addr} .. ( fpf: pavldiff_v (key, itm, h0, h, chld, dir, rt, null, slf) , pf: pavltree_v (key, itm, h, slf, chld) | p: &ptr slf >> ptr slf, pc: ptr chld, dir: &int dir >> int dir ) : #[dir:two;slf:addr] [h1:nat | h1 <= h] [chld:addr] ( pavldiff_v (key, itm, h0, h1, chld, dir, rt, null, slf) , pavltree_v (key, itm, h1, slf, chld) | ptr chld ) = if pc > null then let prval B (pf_at, pf_l, pf_r) = pf val sgn = compare_key_key (k0, pavlnode_get_key (pf_at | pc), cmp) in if sgn < 0 then let val p_tl = pavlnode_get_left (pf_at | pc) in p := pc; dir := 0(*left*); loop (B1L {key,itm} (pf_at, fpf, pf_r), pf_l | p, p_tl, dir) end else if sgn > 0 then let val p_tr = pavlnode_get_right (pf_at | pc) in p := pc; dir := 1(*right*); loop (B1R {key,itm} (pf_at, pf_l, fpf), pf_r | p, p_tr, dir) end else begin // sgn = 0 (fpf, B (pf_at, pf_l, pf_r) | pc) end // end of [if] end else (fpf, pf | pc) // end of [if] val pc = p in p := null; loop (E1 {key,itm} {h0} (), pf | p, pc, dir) end // end of [pavltree_split] (* ****** ****** *) assume map_t0ype_viewt0ype_type (key:t0p, itm:vt0p) = [h:nat;slf:addr] (pavltree_v (key, itm, h, null, slf) | ptr slf) // end of [map_vt] (* ****** ****** *) implement{} linmap_make_nil {key,itm} () = (E {key,itm} {null} () | null) (* ****** ****** *) implement{} linmap_is_nil {key,itm} (m) = m.1 = null implement{} linmap_isnot_nil {key,itm} (m) = m.1 > null (* ****** ****** *) implement{key,itm} linmap_size (m) = loop (m.0 | m.1) where { fun loop {h:nat} {pnt,slf:addr} .. ( pf: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf ) :<> size_t = if p > null then let prval B (pf_at, pfl, pfr) = pf val res = loop (pfl | pavlnode_get_left (pf_at | p)) + size_of_int 1 + loop (pfr | pavlnode_get_right (pf_at | p)) // end of [val] prval () = pf := B (pf_at, pfl, pfr) in res end else size_of_int 0 // end of [if] // end of [loop] } // end of [linmap_size] (* ****** ****** *) implement{key,itm} linmap_height (m) = let val p = m.1 in if p > null then let prval B (pf_at, pfl, pfr) = m.0 val h = pavlnode_get_height (pf_at | p) prval () = m.0 := B (pf_at, pfl, pfr) in h end else 0 // end of [if] end // end of [linmap_height] (* ****** ****** *) implement{key,itm} linmap_search (m, k0, cmp, res) = search (m.0 | m.1, res) where { fun search {h:nat} {pnt:addr} {slf:addr} .. ( pf: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf , res: &itm? >> opt (itm, tag) ) : #[tag:bool] bool tag = if p > null then let prval B (pf_at, pfl, pfr) = pf val sgn = compare_key_key (k0, pavlnode_get_key (pf_at | p), cmp) in if sgn < 0 then let val tag = search (pfl | pavlnode_get_left (pf_at | p), res) prval () = pf := B (pf_at, pfl, pfr) in tag end else if sgn > 0 then let val tag = search (pfr | pavlnode_get_right (pf_at | p), res) prval () = pf := B (pf_at, pfl, pfr) in tag end else let val (pf_itm, fpf | p_itm) = pavlnode_takeout_val (pf_at | p) val () = res := !p_itm prval () = pf_at := fpf (pf_itm) prval () = opt_some {itm} (res) prval () = pf := B (pf_at, pfl, pfr) in true // item associated with the key [k0] is found end // end of [if] end else let prval () = opt_none {itm} (res) in false end // end of [if] } // end of [linmap_search] (* ****** ****** *) local fun{key:t0p;itm:vt0p} insert_rebalance {n0,h0:nat | h0 <= n0} {h1:nat | h0 <= h1; h1 <= h0+1} {chld0,chld1:addr} {dir:two} {rt:addr} {slf:addr} .. ( fpf: pavldiff_v (key, itm, n0, h0, chld0, dir, rt, null, slf) , pf0: pavltree_v (key, itm, h1, slf, chld1) | h0: int h0, pc0: ptr chld0, dir: int dir, pt: ptr rt, p: ptr slf , pc1: ptr chld1 ) :<> [slf:addr] ( pavltree_v_inc (key, itm, n0, null, slf) | ptr slf ) = if p > null then let val h1 = pavltree_height_get (pf0 | pc1) in if h0 = h1 then begin pavldiff_child_set (fpf | p, dir, pc1); (pavldiff_pavltree_join {key,itm} (fpf, pf0) | pt) end else begin // [h1 = h0+1] if dir = 0 then let prval B1L (pf_at, fpf1, pf2) = fpf val pp = pavlnode_get_parent (pf_at | p) val h0p = pavlnode_get_height (pf_at | p) val dirp = pavldiff_dir_get (fpf1 | pp, p) val () = pavlnode_set_left (pf_at | p, pc1) val h0r = pavltree_height_get (pf2 | pavlnode_get_right (pf_at | p)) in if h1 = h0r + 2 then let val (pf0_new | p_new) = pavltree_rrotate (pf_at, pf0, pf2 | p) in insert_rebalance (fpf1, pf0_new | h0p, p, dirp, pt, pp, p_new) end else let val () = pavlnode_set_height (pf_at | p, max (h1, h0r)+1) prval pf0_new = B {key,itm} (pf_at, pf0, pf2) in insert_rebalance (fpf1, pf0_new | h0p, p, dirp, pt, pp, p) end // end of [if] end else let prval B1R (pf_at, pf1, fpf2) = fpf val pp = pavlnode_get_parent (pf_at | p) val h0p = pavlnode_get_height (pf_at | p) val dirp = pavldiff_dir_get (fpf2 | pp, p) val () = pavlnode_set_right (pf_at | p, pc1) val h0l = pavltree_height_get (pf1 | pavlnode_get_left (pf_at | p)) in if h1 = h0l + 2 then let val (pf0_new | p_new) = pavltree_lrotate (pf_at, pf1, pf0 | p) in insert_rebalance (fpf2, pf0_new | h0p, p, dirp, pt, pp, p_new) end else begin pavlnode_set_height (pf_at | p, max (h0l, h1)+1); insert_rebalance (fpf2, B {key,itm} (pf_at, pf1, pf0) | h0p, p, dirp, pt, pp, p) end // end of [if] end // end of [if] end // end of [if] end else let prval E1 () = fpf in (pf0 | pc1) end // end of [if] // end of [insert_rebalance] in // in of [local] implement{key,itm} linmap_insert {l_at} (pf_at | m, p_at, cmp) = let prval () = pavlnode_ptr_is_gtz (pf_at) var pt = m.1 var p = pt val k0 = pavlnode_get_key (pf_at | p_at) var dir = 0 val (fpf, pf0 | pc0) = pavltree_split (m.0 | p, k0, dir, cmp) in if pc0 > null then let // key already exists // swap the two nodes fn{key:t0p;itm:vt0p} pavldiff_child_set_opt {n,h:int} {chld:addr} {dir:int} {rt:addr} {slf:addr} {chld1:addr} ( fpf: !pavldiff_v (key, itm, n, h, chld, dir, rt, null, slf) >> pavldiff_v (key, itm, n, h, chld1, dir, rt1, null, slf) // end of [fpf] | pt: &ptr rt >> ptr rt1, p: ptr slf, dir: int dir, pc0: ptr chld, pc1: ptr chld1 ) :<> #[rt1:addr] void = if p = null then let prval E1 () = fpf prval () = fpf := E1 {key,itm} {n} {chld1} {dir} {slf} () in pt := pc1 end else pavldiff_child_set (fpf | p, dir, pc1) // end of [pavldiff_child_set_opt] fn pavldiff_pavltree_swap {n,h:nat | h <= n} {chld1,chld2:agz} {dir:two} {rt:addr;slf:addr} ( fpf: !pavldiff_v (key, itm, n, h, chld1, dir, rt, null, slf) >> pavldiff_v (key, itm, n, h, chld2, dir, rt1, null, slf) , pf0: !pavltree_v (key, itm, h, slf, chld1) >> pavltree_v (key, itm, h, slf, chld2) , pf_at: pavlnode0_v (key, itm, chld2) | pt: &ptr rt >> ptr rt1 , p0: ptr chld1 , dir: int dir , p_at: &ptr chld2 >> ptr chld1 ) :<> #[rt1:addr] ( pavlnode0_v (key, itm, chld1) | void ) = let prval B (pf0_at, pf0_tl, pf0_tr) = pf0 val p_tl = pavlnode_get_left (pf0_at | p0) and p_tr = pavlnode_get_right (pf0_at | p0) and pp = pavlnode_get_parent (pf0_at | p0) val () = pavltree_parent_set (pf0_tl | p_tl, p_at) val () = pavltree_parent_set (pf0_tr | p_tr, p_at) val () = pavlnode_set_height (pf_at | p_at, pavlnode_get_height (pf0_at | p0)) val () = pavlnode_set_left (pf_at | p_at, p_tl) val () = pavlnode_set_right (pf_at | p_at, p_tr) val () = pavlnode_set_parent (pf_at | p_at, pp) val () = pavldiff_child_set_opt (fpf | pt, pp, dir, p0, p_at) prval () = pf0 := B {key,itm} (pf_at, pf0_tl, pf0_tr) in p_at := p0; (pf0_at | ()) end // end of [pavldiff_pavltree_swap] val (pf0_at | ()) = pavldiff_pavltree_swap (fpf, pf0, pf_at | pt, pc0, dir, p_at) prval pf = pavldiff_pavltree_join {key,itm} (fpf, pf0) prval () = pf_at := Some_v (pf0_at) prval () = m.0 := pf val () = m.1 := pt in true // swapped the two elements end else let prval E () = pf0 val () = pavlnode_set_height (pf_at | p_at, 1) val () = pavlnode_set_parent (pf_at | p_at, p) val () = pavlnode_set_left (pf_at | p_at, null) val () = pavlnode_set_right (pf_at | p_at, null) prval pf0 = B {key,itm} (pf_at, E (), E ()) prval () = pf_at := None_v () val (pf | p_new) = insert_rebalance (fpf, pf0 | 0, pc0, dir, pt, p, p_at) prval () = m.0 := pf in m.1 := p_new; false // insertion is performed end // end of [if] end // end of [linmap_insert] end // end of [local] (* ****** ****** *) local fun{key:t0p;itm:vt0p} remove_rebalance {n0,h0:nat | h0 <= n0} {h1:nat | h1 <= h0; h0 <= h1+1} {chld0,chld1:addr} {dir:two} {rt:addr} {slf:addr} .. ( fpf: pavldiff_v (key, itm, n0, h0, chld0, dir, rt, null, slf) , pf0: pavltree_v (key, itm, h1, slf, chld1) | h0: int h0, pc0: ptr chld0, dir: int dir, pt: ptr rt, p: ptr slf , pc1: ptr chld1 ) :<> [slf:addr] ( pavltree_v_dec (key, itm, n0, null, slf) | ptr slf ) = if p > null then let val h1 = pavltree_height_get (pf0 | pc1) in if h0 = h1 then begin pavldiff_child_set (fpf | p, dir, pc1); (pavldiff_pavltree_join {key,itm} (fpf, pf0) | pt) end else begin // h0 = h1 + 1 if dir = 0 then let prval B1L (pf_at, fpf1, pf2) = fpf val pp = pavlnode_get_parent (pf_at | p) val h0p = pavlnode_get_height (pf_at | p) val dirp = pavldiff_dir_get (fpf1 | pp, p) val () = pavlnode_set_left (pf_at | p, pc1) val h0r = pavltree_height_get (pf2 | pavlnode_get_right (pf_at | p)) in if h0r = h1 + 2 then let val (pf0_new | p_new) = pavltree_lrotate (pf_at, pf0, pf2 | p) // end of [val] in remove_rebalance (fpf1, pf0_new | h0p, p, dirp, pt, pp, p_new) end else begin pavlnode_set_height (pf_at | p, max (h1, h0r)+1); remove_rebalance (fpf1, B {key,itm} (pf_at, pf0, pf2) | h0p, p, dirp, pt, pp, p) end // end of [if] end else let prval B1R (pf_at, pf1, fpf2) = fpf val pp = pavlnode_get_parent (pf_at | p) val h0p = pavlnode_get_height (pf_at | p) val dirp = pavldiff_dir_get (fpf2 | pp, p) val () = pavlnode_set_right (pf_at | p, pc1) val h0l = pavltree_height_get (pf1 | pavlnode_get_left (pf_at | p)) in if h0l = h1 + 2 then let val (pf0_new | p_new) = pavltree_rrotate (pf_at, pf1, pf0 | p) // end of [val] in remove_rebalance (fpf2, pf0_new | h0p, p, dirp, pt, pp, p_new) end else begin pavlnode_set_height (pf_at | p, max (h0l, h1) + 1); remove_rebalance (fpf2, B {key,itm} (pf_at, pf1, pf0) | h0p, p, dirp, pt, pp, p) end // end of [if] end // end of [if] end // end of [if] end else let prval E1 () = fpf in (pf0 | pc1) end // end of [if] // end of [remove_rebalance] fn{key:t0p;itm:vt0p} pavltree_pavltree_join {hl,hr:nat | hl <= hr+1; hr <= hl+1} {lft,rgh,pnt1,pnt2:addr} ( pf_tl: pavltree_v (key, itm, hl, pnt1, lft) , pf_tr: pavltree_v (key, itm, hr, pnt2, rgh) | pl: ptr lft, pr: ptr rgh ) :<> [pnt,slf:addr] ( pavltree_v_inc (key, itm, max(hl,hr), pnt, slf) | ptr slf ) = let viewdef pavlnode_v (key:t@ype, itm:viewt@ype, lft: addr, slf:addr) = [h:nat] [rgh,pnt:addr] pavlnode_v (key, itm, h, lft, rgh, pnt, slf) // end of [pavlnode_v] fun loop {h0:nat | h0 <= hl} {chld:addr | chld > null} {rt:addr} {slf:addr} .. ( fpf: pavldiff_v (key, itm, hl, h0, chld, 1(*right*), rt, null, slf) , pf0: pavltree_v (key, itm, h0, slf, chld) // view for the missing avltree | pc: ptr (chld), pt: ptr rt, p: ptr slf ) :<> [slf:agz] [lft:addr] ( pavlnode_v (key, itm, lft, slf), pavltree_v_dec (key, itm, hl, slf, lft) | ptr slf ) = let prval B (pf0_at, pf0_l, pf0_r) = pf0 val pc_r = pavlnode_get_right (pf0_at | pc) in if pc_r > null then let prval fpf = B1R {key,itm} (pf0_at, pf0_l, fpf) in loop (fpf, pf0_r | pc_r, pt, pc) end else let prval E () = pf0_r val pc_l = pavlnode_get_left (pf0_at | pc) val () = pavltree_parent_set (pf0_l | pc_l, p) val (pf | pt) = remove_rebalance (fpf, pf0_l | pavlnode_get_height (pf0_at | pc), pc, 1(*right*), pt, p, pc_l) in pavlnode_set_left (pf0_at | pc, pt); pavltree_parent_set (pf | pt, pc); (pf0_at, pf | pc) end // end of [if] end // end of [loop] in if pl > null then let prval fpf = E1 () val () = pavltree_parent_set (pf_tl | pl, null) val (pf_at, pf_tl | p_at) = loop (fpf, pf_tl | pl, pl, null) val () = pavlnode_set_right (pf_at | p_at, pr) val () = pavltree_parent_set (pf_tr | pr, p_at) val pl = pavlnode_get_left (pf_at | p_at) val hl = pavltree_height_get (pf_tl | pl) val hr = pavltree_height_get (pf_tr | pr) in if hl+2 = hr then begin pavltree_lrotate (pf_at, pf_tl, pf_tr | p_at) end else begin pavlnode_set_height (pf_at | p_at, max(hl,hr)+1); (B (pf_at, pf_tl, pf_tr) | p_at) end // end of [if] end else let prval E () = pf_tl in (pf_tr | pr) end // end of [if] end // end of [pavltree_pavltree_join] in // in of [local] implement{key,itm} linmap_takeout (m, k0, cmp) = let val pt = m.1 var p = pt var dir = 0 val [h1:int,chld:addr] (fpf, pf0 | pc0) = pavltree_split (m.0 | p, k0, dir, cmp) // end of [val] viewdef V = pavlnode0_v (key, itm, chld) prval () = ptr_is_gtez (pc0) in if pc0 > null then let prval B (pf0_at, pf0_tl, pf0_tr) = pf0 val (pf0 | pc0_new) = pavltree_pavltree_join ( pf0_tl, pf0_tr | pavlnode_get_left (pf0_at | pc0) , pavlnode_get_right (pf0_at | pc0) ) // end of [val] val () = pavltree_parent_set (pf0 | pc0_new, p) val (pf_new | pt_new) = remove_rebalance (fpf, pf0 | pavlnode_get_height (pf0_at | pc0), pc0, dir, pt, p, pc0_new) // end of [val] in // removed m.0 := pf_new; m.1 := pt_new; (Some_v {V} (pf0_at) | pc0) end else let prval pf = pavldiff_pavltree_join {key,itm} (fpf, pf0) in // not removed m.0 := pf; (None_v {V} () | null) end // end of [if] end // end of [linmap_takeout] end // end of [local] (* ****** ****** *) implement{key,itm} linmap_remove (m, k0, cmp) = let val (pf | p) = linmap_takeout (m, k0, cmp) in if p > null then let prval Some_v (pf_nod) = pf in pavlnode_free (pf_nod | p); true end else let prval None_v () = pf in false end // end of [if] end // end of [linmap_remove] (* ****** ****** *) // // AS: declarations for supporting iterative traversal // dataview pavlenum_v (key:t0p, itm:vt0p, int, int, addr, addr) = | {n,h:nat | h <= n} {chld:agz} {dir:two} {rt,slf:addr} pavlenum_v_some (key, itm, n, h, rt, chld) of ( pavldiff_v (key, itm, n, h, chld, dir, rt, null, slf) , pavltree_v (key, itm, h, slf, chld) ) // end of [pavlenum_v_some] | {n:nat} {rt:addr} pavlenum_v_none (key, itm, n, n, rt, null) of ( pavltree_v (key, itm, n, null, rt) ) // end of [pavlenum_v_none] // end of [pavlenum_v] prfn pavlenum_v_free {key:t0p;itm:vt0p} {h,h1:int} {slf,chld:addr} ( pf: pavlenum_v (key, itm, h, h1, slf, chld) ) :<> pavltree_v (key, itm, h, null, slf) = sif chld > null then let prval pavlenum_v_some (fpf, pf0) = pf in pavldiff_pavltree_join {key,itm} (fpf, pf0) end else let prval pavlenum_v_none pf0 = pf in pf0 end // end of [sif] // end of [pavlenum_v_free] local // // AS-2012-02: // returns the node with the minimum value in the given (sub)tree // fun{ key:t0p;itm:vt0p } min_value1 {n,h:nat} {chld:agz} {rt:addr} .. ( pf: pavlenum_v (key, itm, n, h, rt, chld) | p: ptr chld ) :<> [h1:nat | h1 <= h] [chld1:agz] ( pavlenum_v (key, itm, n, h1, rt, chld1) | ptr chld1 ) = let prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val p_tl = pavlnode_get_left (pf_at | p) in if p_tl > null then begin min_value1 (pavlenum_v_some (B1L (pf_at, fpf, pf_tr), pf_tl) | p_tl) end else begin (pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) | p) end // end of [if] end // end of [min_value1] fn{ key:t0p;itm:vt0p } start_inord {h:nat} {chld:addr} ( pf: pavltree_v (key, itm, h, null, chld) | p: ptr chld ) :<> [h1:int] [chld1:addr] ( pavlenum_v (key, itm, h, h1, chld, chld1) | ptr chld1 ) = if p > null then let prval fpf = E1 () prval pf1 = pavlenum_v_some {key,itm} {h,h} {chld} {0} (fpf, pf) in min_value1 (pf1 | p) end else begin (pavlenum_v_none (pf) | null) end // end of [if] // end of [start_inord] // // AS: steps to the successor // fn{key:t0p;itm:vt0p} step_inord {n,h:int} {chld:agz;slf:addr} ( pf: pavlenum_v (key, itm, n, h, slf, chld) | p: ptr chld ) :<> [h1:nat] [chld1:addr] ( pavlenum_v (key, itm, n, h1, slf, chld1) | ptr chld1 ) = let fun loop {n,h:nat | h <= n} {chld:agz;rt:addr} .. ( pf: pavlenum_v (key, itm, n, h, rt, chld) | p: ptr chld ) :<> [h1:nat | h <= h1; h1 <= n] [chld1:addr] ( pavlenum_v (key, itm, n, h1, rt, chld1) | ptr chld1 ) = let prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val pp = pavlnode_get_parent (pf_at | p) prval pf0 = B (pf_at, pf_tl, pf_tr) val dir = pavldiff_dir_get (fpf | pp, p) in if pp > null then begin if dir = 0(*left*) then let prval B1L (pf_at, fpf1, pf1) = fpf in (pavlenum_v_some {key,itm} (fpf1, B {key,itm} (pf_at, pf0, pf1)) | pp) end else let // dir = 1 prval B1R (pf_at, pf1, fpf1) = fpf prval fpf0 = pavlenum_v_some {key,itm} (fpf1, B {key,itm} (pf_at, pf1, pf0)) in loop (fpf0 | pp) end // end of [if] end else let prval fpf0 = pavldiff_pavltree_join {key,itm} (fpf, pf0) in (pavlenum_v_none fpf0 | null) end // end of [if] end // end of [loop] prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val p_tr = pavlnode_get_right (pf_at | p) in if p_tr > null then let prval pf = pavlenum_v_some (B1R (pf_at, pf_tl, fpf), pf_tr) in min_value1 (pf | p_tr) end else let prval pf = pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) in loop (pf | p) end // end of [if] end // end of [step_inord] fn{ key:t0p;itm:vt0p } foreach_looping1 {h:nat} {slf:addr} ( pf1: !pavltree_v (key, itm, h, null, slf) | p: ptr slf , f: (key, &itm) - void ) : void = let val (pf | p1) = start_inord (pf1 | p) fun loop {n,h:int} {chld,rt:addr} ( pfe: pavlenum_v (key, itm, n, h, rt, chld) | pe: ptr chld ) : ( pavltree_v (key, itm, n, null, rt) | void ) = if pe > null then let prval pavlenum_v_some (fpf, B (pf_nod, pf_tl, pf_tr)) = pfe val k = pavlnode_get_key (pf_nod | pe) val (pf_at, fpf_at | p_at) = pavlnode_takeout_val (pf_nod | pe) val () = f (k, !p_at) prval () = pf_nod := fpf_at {itm} (pf_at) prval pfe = pavlenum_v_some (fpf, B (pf_nod, pf_tl, pf_tr)) val (pfe | pe) = step_inord (pfe | pe) in loop (pfe | pe) end else begin (pavlenum_v_free {key,itm} (pfe) | ()) end // end of [if] val (pf | ()) = loop (pf | p1) prval () = pf1 := pf in // nothing end // end of [foreach_looping1] in // of [local] implement{key,itm} linmap_foreach_fun_iter (m, f) = ( // AS: for not having to prove termination $effmask_all (foreach_looping1 (m.0 | m.1, f)) ) // end of [linmap_foreach_fun_iter] end // end of [local] local // // AS-2012-02: // returns the node with the maximum value in the given (sub)tree // fun{key:t0p;itm:vt0p} max_value1 {n,h:nat} {chld:agz} {rt:addr} .. ( pf: pavlenum_v (key, itm, n, h, rt, chld) | p: ptr chld ) :<> [h1:nat | h1 <= h] [chld1:agz] ( pavlenum_v (key, itm, n, h1, rt, chld1) | ptr chld1 ) = let prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val p_tr = pavlnode_get_right (pf_at | p) in if p_tr > null then begin max_value1 (pavlenum_v_some (B1R (pf_at, pf_tl, fpf), pf_tr) | p_tr) end else begin (pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) | p) end // end of [if] end // end of [max_value1] fn{ key:t0p;itm:vt0p } start_preord {h:nat} {chld:addr} ( pf: pavltree_v (key, itm, h, null, chld) | p: ptr chld ) :<> [h1:int] [chld1:addr] ( pavlenum_v (key, itm, h, h1, chld, chld1) | ptr chld1 ) = if p > null then let prval fpf = E1 () prval pf1 = pavlenum_v_some {key,itm} {h,h} {chld} {0} (fpf, pf) in max_value1 (pf1 | p) end else begin (pavlenum_v_none (pf) | null) end // end of [if] // end of [start_preord] // // AS: steps to the predecessor fn{ key:t0p;itm:vt0p } step_preord {n,h:int} {chld:agz;slf:addr} ( pf: pavlenum_v (key, itm, n, h, slf, chld) | p: ptr chld ) :<> [h1:nat] [chld1:addr] ( pavlenum_v (key, itm, n, h1, slf, chld1) | ptr chld1 ) = let fun loop {n,h:nat | h <= n} {chld:agz;rt:addr} .. ( pf: pavlenum_v (key, itm, n, h, rt, chld) | p: ptr chld ) :<> [h1:nat | h <= h1; h1 <= n] [chld1:addr] ( pavlenum_v (key, itm, n, h1, rt, chld1) | ptr chld1 ) = let prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val pp = pavlnode_get_parent (pf_at | p) prval pf0 = B (pf_at, pf_tl, pf_tr) val dir = pavldiff_dir_get (fpf | pp, p) in if pp > null then begin if dir = 0(*left*) then let prval B1L (pf_at, fpf1, pf1) = fpf prval fpf0 = pavlenum_v_some {key,itm} (fpf1, B {key,itm} (pf_at, pf0, pf1)) in loop (fpf0 | pp) end else let // dir = 1 prval B1R (pf_at, pf1, fpf1) = fpf prval fpf0 = pavlenum_v_some {key,itm} (fpf1, B {key,itm} (pf_at, pf1, pf0)) in (fpf0 | pp) end // end of [if] end else let prval fpf0 = pavldiff_pavltree_join {key,itm} (fpf, pf0) in (pavlenum_v_none fpf0 | null) end // end of [if] end // end of [loop] prval pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) = pf val p_tl = pavlnode_get_left (pf_at | p) in if p_tl > null then let prval pf = pavlenum_v_some (B1L (pf_at, fpf, pf_tr), pf_tl) in max_value1 (pf | p_tl) end else let prval pf = pavlenum_v_some (fpf, B (pf_at, pf_tl, pf_tr)) in loop (pf | p) end // end of [if] end // end of [step_preord] fn{ key:t0p;itm:vt0p } rforeach_looping1 {h:nat} {slf:addr} ( pf1: !pavltree_v (key, itm, h, null, slf) | p: ptr slf , f: (key, &itm) - void ) : void = let val (pf | p1) = start_preord (pf1 | p) fun loop {n,h:int} {chld,rt:addr} ( pfe: pavlenum_v (key, itm, n, h, rt, chld) | pe: ptr chld ) : ( pavltree_v (key, itm, n, null, rt) | void ) = if pe > null then let prval pavlenum_v_some (fpf, B (pf_nod, pf_tl, pf_tr)) = pfe val k = pavlnode_get_key (pf_nod | pe) val (pf_at, fpf_at | p_at) = pavlnode_takeout_val (pf_nod | pe) val () = f (k, !p_at) prval () = pf_nod := fpf_at {itm} (pf_at) prval pfe = pavlenum_v_some (fpf, B (pf_nod, pf_tl, pf_tr)) val (pfe | pe) = step_preord (pfe | pe) in loop (pfe | pe) end else begin (pavlenum_v_free {key,itm} (pfe) | ()) end // end of [if] val (pf | ()) = loop (pf | p1) prval () = pf1 := pf in // nothing end // end of [rforeach_looping1] in // in of [local] implement{key,itm} linmap_rforeach_fun_iter (m, f) = ( // AS: for not having to prove termination $effmask_all (rforeach_looping1 (m.0 | m.1, f)) ) // end of [linmap_rforeach] end // end of [local] (* ****** ****** *) implement{key,itm} linmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf, m.0 | m.1, env) where { // fun foreach {h:nat} {pnt,slf:addr} .. ( pfv: !v , pf1: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf, env: !vt ) : void = if p > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = pavlnode_get_key (pf_nod | p) and p_tl = pavlnode_get_left (pf_nod | p) and p_tr = pavlnode_get_right (pf_nod | p) val () = foreach (pfv, pf_tl | p_tl, env) val (pf_at, fpf | p_at) = pavlnode_takeout_val (pf_nod | p) val () = f (pfv | k, !p_at, env) prval () = pf_nod := fpf {itm} (pf_at) val () = foreach (pfv, pf_tr | p_tr, env) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [foreach] } // end of [linmap_foreach_funenv] implement{key,itm} linmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, &itm) - void):<> (!unit_v | key, &itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [linmap_foreach_fun] (* ****** ****** *) implement{key,itm} linmap_foreach_vclo {v} (pf | m, f) = foreach (pf, m.0 | m.1, f) where { // fun foreach {h:nat} {pnt,slf:addr} .. ( pfv: !v , pf1: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf , f: &(!v | key, &itm) - void ) :<> void = if p > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = pavlnode_get_key (pf_nod | p) and p_tl = pavlnode_get_left (pf_nod | p) and p_tr = pavlnode_get_right (pf_nod | p) val () = foreach (pfv, pf_tl | p_tl, f) val (pf_at, fpf | p_at) = pavlnode_takeout_val (pf_nod | p) val () = f (pfv | k, !p_at) prval () = pf_nod := fpf {itm} (pf_at) val () = foreach (pfv, pf_tr | p_tr, f) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [foreach] } // end of [linmap_foreach_vclo] (* ****** ****** *) implement{key,itm} linmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf, m.0 | m.1, env) where { // fun rforeach {h:nat} {pnt,slf:addr} .. ( pfv: !v , pf1: !pavltree_v (key, itm, h, pnt, slf) | p: ptr slf, env: !vt ) : void = if p > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val k = pavlnode_get_key (pf_nod | p) and p_tl = pavlnode_get_left (pf_nod | p) and p_tr = pavlnode_get_right (pf_nod | p) val () = rforeach (pfv, pf_tr | p_tr, env) val (pf_at, fpf | p_at) = pavlnode_takeout_val (pf_nod | p) val () = f (pfv | k, !p_at, env) prval () = pf_nod := fpf {itm} (pf_at) val () = rforeach (pfv, pf_tl | p_tl, env) prval () = pf1 := B (pf_nod, pf_tl, pf_tr) in // nothing end else let prval E () = pf1; prval () = pf1 := E () in // nothing end // end of [if] // end of [foreach] } // end of [linmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} linmap_clear_funenv {v} {vt} ( pfv | m, f, env ) = let typedef FT1 = (!v | key, &itm >> itm?, !vt) - void typedef FT2 = (!v | key, &itm >> itm , !vt) - void val () = let extern castfn __cast (f: FT1):<> FT2 in linmap_foreach_funenv (pfv | m, __cast(f), env) end // end of [val] prval () = __assert (m) where { extern praxi __assert (m: !map (key, itm) >> map (key, itm?)): void } // end of [val] in // nothing end // end of [linmap_clear_funenv] (* ****** ****** *) implement{key,itm} linmap_free (m) = let // freeing is done in the inord fashion fun _free {h:nat} {pnt,slf:addr} .. ( pf1: pavltree_v (key, itm, h, pnt, slf) | p: ptr slf ) : void = if p > null then let prval B (pf_nod, pf_tl, pf_tr) = pf1 val p_tl = pavlnode_get_left (pf_nod | p) and p_tr = pavlnode_get_right (pf_nod | p) val () = pavlnode_free (pf_nod | p) val () = _free (pf_tl | p_tl) and () = _free (pf_tr | p_tr) in // nothing end else let prval E () = pf1 in // nothing end // end of [if] // end of [_free] in _free (m.0 | m.1) end // end of [linmap_free] (* ****** ****** *) implement{key,itm} linmap_free_vt (m) = if m.1 > null then let prval () = opt_some {map (key, itm)} (m) in true end else let // m.1 = null prval E () = m.0 prval () = opt_none {map (key, itm)} (m) in false end // end of [if] // end of [linmap_free_vt] (* ****** ****** *) (* end of [linmap_pavltree.dats] *) ats-lang-anairiats-0.2.11/libats/ngc/DATS/deque_arr.dats0000664000175000017500000003211712223166162021405 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** An array-based deque implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libats/ngc/SATS/deque_arr.sats" (* ****** ****** *) absview DEQUEarr_v ( a:viewt@ype+ , m:int, n:int , lft:addr, rgt:addr , l_beg:addr, l_end:addr ) // end of [DEQUEarr_v] extern prfun DEQUEarr_v_encode {a:viewt@ype} {m:nat} {lft:addr} {ofs:int} ( pfmul: MUL (m, sizeof a, ofs) , pfarr: array_v (a?, m, lft) ) : DEQUEarr_v (a, m, 0, lft, lft+ofs, lft, lft) // end of [DEQUEarr_v_encode] extern prfun DEQUEarr_v_decode {a:viewt@ype} {m:nat} {lft,rgt,l_beg,l_end:addr} ( pf: DEQUEarr_v (a, m, 0, lft, rgt, l_beg, l_end) ) : array_v (a?, m, lft) // end of [DEQUEarr_v_decode] extern prfun DEQUEarr_v_clear {a:t@ype} {m,n:nat} {lft,rgt,l_beg,l_end:addr} ( pf: DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) ) : DEQUEarr_v (a, m, 0, lft, rgt, lft, lft) // end of [DEQUEarr_v_clear] (* ****** ****** *) viewtypedef DEQUE_vt ( a:viewt@ype , m:int, n:int , lft:addr, rgt:addr , l_beg:addr, l_end:addr ) = $extype_struct "atslib_ngc_deque_arr_DEQUE" of { cap= size_t m , nitm= size_t n , qarr_lft= ptr lft , qarr_rgt= ptr rgt , qarr_beg= ptr l_beg , qarr_end= ptr l_end , pfqarr= DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) , pfqarr_gc= free_gc_v (a?, m, lft) } // end of [DEQUE_vt] typedef DEQUE0_vt (a:viewt@ype) = DEQUE_vt (a, 0, 0, null, null, null, null)? // end of [DEQUE0_vt] (* ****** ****** *) absprop DEQUEptrprv_p ( a:viewt@ype, lft:addr, rgt:addr, l:addr, l_prv:addr ) // end of [DEQUEptrprv_p] extern fun{a:viewt@ype} DEQUEptrprv {m,n:int} {lft,rgt,l_beg,l_end:addr} {l:addr} ( q: &DEQUE_vt (a, m, n, lft, rgt, l_beg, l_end) , p: ptr l ) :<> [l_prv:addr] (DEQUEptrprv_p (a, lft, rgt, l, l_prv) | ptr l_prv) // end of [DEQUEptrprv_p] implement{a} DEQUEptrprv {m,n} {lft,rgt,l_beg,l_end} {l} (q, p) = let var p: Ptr = p val () = if p <= q.qarr_lft then p := q.qarr_rgt stavar l_prv: addr var p_prv: ptr (l_prv) = p - sizeof
prval pf = __assert () where { extern prfun __assert (): DEQUEptrprv_p (a, lft, rgt, l, l_prv) } // end of [prval] in (pf | p_prv) end // end of [DEQUEptrprv] (* ****** ****** *) absprop DEQUEptrnxt_p ( a:viewt@ype, lft:addr, rgt:addr, l:addr, l_nxt:addr ) // end of [DEQUEptrnxt_p] extern fun{a:viewt@ype} DEQUEptrnxt {m,n:int} {lft,rgt,l_beg,l_end:addr} {l:addr} (q: &DEQUE_vt (a, m, n, lft, rgt, l_beg, l_end), p: ptr l) :<> [l_nxt:addr] (DEQUEptrnxt_p (a, lft, rgt, l, l_nxt) | ptr l_nxt) // end of [DEQUEptrnxt_p] implement{a} DEQUEptrnxt {m,n} {lft,rgt,l_beg,l_end} {l} (q, p) = let var p_nxt: Ptr = p + sizeof val () = if p_nxt >= q.qarr_rgt then p_nxt := q.qarr_lft stavar l_nxt: addr val _ = p_nxt: ptr l_nxt prval pf = __assert () where { extern prfun __assert (): DEQUEptrnxt_p (a, lft, rgt, l, l_nxt) } // end of [prval] in (pf | p_nxt) end // end of [DEQUEptrnxt] (* ****** ****** *) assume DEQUE ( a:viewt@ype, m:int, n:int ) = [ lft,rgt,l_beg,l_end:addr ] DEQUE_vt ( a, m, n, lft, rgt, l_beg, l_end ) // end of [DEQUE] (* ****** ****** *) implement deque_cap (q) = q.cap implement deque_size (q) = q.nitm implement deque_is_empty (q) = let prval () = lemma_deque_param (q) in (q.nitm = 0) end // end of [deque_is_empty] implement deque_isnot_empty (q) = let prval () = lemma_deque_param (q) in (q.nitm > 0) end // end of [deque_isnot_empty] implement deque_is_full (q) = let prval () = lemma_deque_param (q) in (q.cap = q.nitm) end // end of [deque_is_full] implement deque_isnot_full (q) = let prval () = lemma_deque_param (q) in (q.cap > q.nitm) end // end of [deque_isnot_full] (* ****** ****** *) implement{a} deque_initialize {m} ( pfgc, pfarr | q, m, parr ) = deque_initialize_tsz {a} {m} (pfgc, pfarr | q, m, parr, sizeof) // end of [deque_initialize] // // HX-2010-03-29: // the function is given the external name: // atslib_lindeque_arr_deque_initialize_tsz // implement deque_initialize_tsz {a} {m} ( pfgc, pfarr | q, m, parr, tsz ) = () where { prval () = __assert (q) where { extern prfun __assert (q: &DEQUE0(a)? >> DEQUE0_vt a):<> void } // end of [val] val () = q.cap := m val () = q.nitm := (size1_of_int1)0 val [ofs:int] (pfmul | ofs) = mul2_size1_size1 (m, tsz) val () = q.qarr_lft := parr val () = q.qarr_rgt := parr + ofs val () = q.qarr_beg := parr val () = q.qarr_end := parr prval pfqarr = DEQUEarr_v_encode {a} (pfmul, pfarr) prval () = q.pfqarr := pfqarr prval () = q.pfqarr_gc := pfgc } // end of [deque_initialize_tsz] (* ****** ****** *) // // HX-2010-03-29: // the function is given the external name: // atslib_ngc_deque_arr_deque_uninitialize // implement deque_uninitialize {a} {m,n} (q) = let // prval () = lemma_deque_param (q) // prval pfgc = q.pfqarr_gc prval pfqarr = DEQUEarr_v_clear (q.pfqarr) prval pfarr = DEQUEarr_v_decode (pfqarr) val parr = q.qarr_lft prval () = __assert (q) where { extern prfun __assert (q: &DEQUE0_vt a >> DEQUE0(a)?):<> void } // end of [val] in (pfgc, pfarr | parr) end // end of [deque_uninitialize] implement deque_uninitialize_vt {a} {m} (q) = let // prval () = lemma_deque_param (q) // prval pfgc = q.pfqarr_gc prval pfarr = DEQUEarr_v_decode (q.pfqarr) val parr = q.qarr_lft prval () = __assert (q) where { extern prfun __assert (q: &DEQUE0_vt a >> DEQUE0(a)?):<> void } // end of [val] in (pfgc, pfarr | parr) end // end of [deque_uninitialize_vt] (* ****** ****** *) implement{a} deque_get_elt_at (q, i) = x where { val ( pfat, fpfat | p ) = deque_takeout_tsz {a} (q, i, sizeof) val x = !p prval () = fpfat (pfat) } // end of [deque_arr_get_elt_at] implement{a} deque_set_elt_at (q, i, x) = () where { val ( pfat, fpfat | p ) = deque_takeout_tsz {a} (q, i, sizeof) val () = !p := x prval () = fpfat (pfat) } // end of [deque_arr_set_elt_at] (* ****** ****** *) extern prfun DEQUEarr_insert_beg {a:viewt@ype} {m,n:nat | m > n} {lft,rgt,l_beg,l_end:addr} {l1_beg:addr} ( pf1: DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) , pf2: DEQUEptrprv_p (a, lft, rgt, l_beg, l1_beg) ) : ( a? @ l1_beg , a @ l1_beg - DEQUEarr_v (a, m, n+1, lft, rgt, l1_beg, l_end) ) // end of [DEQUEarr_insert_beg] implement{a} deque_insert_beg (q, x) = () where { // prval () = lemma_deque_param (q) // val p_beg = q.qarr_beg val (pf_prv | p1_beg) = DEQUEptrprv (q, p_beg) prval (pf_at, fpf) = DEQUEarr_insert_beg {a} (q.pfqarr, pf_prv) val () = !p1_beg := x val () = q.nitm := q.nitm + 1 val () = q.qarr_beg := p1_beg prval () = q.pfqarr := fpf (pf_at) } // end of [deque_insert_beg] (* ****** ****** *) extern prfun DEQUEarr_insert_end {a:viewt@ype} {m,n:nat | m > n} {lft,rgt,l_beg,l_end:addr} {l1_end:addr} ( pf1: DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) , pf2: DEQUEptrnxt_p (a, lft, rgt, l_end, l1_end) ) : ( a? @ l_end , a @ l_end - DEQUEarr_v (a, m, n+1, lft, rgt, l_beg, l1_end) ) // end of [DEQUEarr_insert_end] implement{a} deque_insert_end (q, x) = let // prval () = lemma_deque_param (q) // val p_end = q.qarr_end val (pf_nxt | p1_end) = DEQUEptrnxt (q, p_end) prval (pf_at, fpf) = DEQUEarr_insert_end {a} (q.pfqarr, pf_nxt) val () = !p_end := x val () = q.nitm := q.nitm + 1 val () = q.qarr_end := p1_end prval () = q.pfqarr := fpf (pf_at) in // nothing end // end of [deque_insert_end] implement{a} deque_insert_end_many (q, k, xs) = deque_insert_end_many_tsz {a} (q, k, xs, sizeof) // end of [deque_insert_end_many] (* ****** ****** *) extern prfun DEQUEarr_remove_beg {a:viewt@ype} {m,n:nat | n > 0} {lft,rgt,l_beg,l_end:addr} {l1_beg:addr} ( pf1: DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) , pf2: DEQUEptrnxt_p (a, lft, rgt, l_beg, l1_beg) ) : ( a @ l_beg , a? @ l_beg - DEQUEarr_v (a, m, n-1, lft, rgt, l1_beg, l_end) ) // end of [DEQUEarr_remove_beg] implement{a} deque_remove_beg (q) = x where { // prval () = lemma_deque_param (q) // val p_beg = q.qarr_beg val (pf_nxt | p1_beg) = DEQUEptrnxt (q, p_beg) prval (pf_at, fpf) = DEQUEarr_remove_beg {a} (q.pfqarr, pf_nxt) val x = !p_beg val () = q.nitm := q.nitm - 1 val () = q.qarr_beg := p1_beg prval () = q.pfqarr := fpf (pf_at) } // end of [deque_remove_beg] implement{a} deque_remove_beg_many (q, k, xs) = deque_remove_beg_many_tsz {a} (q, k, xs, sizeof) // end of [deque_remove_beg_many] (* ****** ****** *) extern prfun DEQUEarr_remove_end {a:viewt@ype} {m,n:nat | n > 0} {lft,rgt,l_beg,l_end:addr} {l1_end:addr} ( pf1: DEQUEarr_v (a, m, n, lft, rgt, l_beg, l_end) , pf2: DEQUEptrprv_p (a, lft, rgt, l_end, l1_end) ) : ( a @ l1_end , a? @ l1_end - DEQUEarr_v (a, m, n-1, lft, rgt, l_beg, l1_end) ) // end of [DEQUEarr_remove_end] implement{a} deque_remove_end (q) = x where { // prval () = lemma_deque_param (q) // val p_end = q.qarr_end val (pf_prv | p1_end) = DEQUEptrprv (q, p_end) prval (pf_at, fpf) = DEQUEarr_remove_end {a} (q.pfqarr, pf_prv) val x = !p1_end val () = q.nitm := q.nitm - 1 val () = q.qarr_end := p1_end prval () = q.pfqarr := fpf (pf_at) } // end of [deque_remove_end] (* ****** ****** *) implement{a} deque_clear_beg {m,n1} {n2} (q, n2) = () where { val tsz = sizeof val n1 = q.nitm val p_rgt = q.qarr_rgt val p_beg = q.qarr_beg // extern castfn pdf2sz {i:int} (df: ptrdiff_t i):<> size_t // var p1_beg: ptr = p_beg + n2 * tsz val () = if p1_beg >= p_rgt then p1_beg := q.qarr_lft + pdf2sz (p1_beg \pdiff p_rgt) val p1_beg = ptr1_of_ptr (p1_beg) stavar l1_beg: addr prval _ = p1_beg: ptr (l1_beg) // prval () = __assert (q.pfqarr) where { extern prfun __assert {lft,rgt,l_beg,l_end:addr} ( pf: !DEQUEarr_v (a, m, n1, lft, rgt, l_beg, l_end) >> DEQUEarr_v (a, m, n1-n2, lft, rgt, l1_beg, l_end) ) : void // end of [extern] } // end of [prval] // val () = q.nitm := n1-n2 val () = q.qarr_beg := p1_beg } // end of [deque_clear_beg] implement{a} deque_clear_end {m,n1} {n2} (q, n2) = () where { val tsz = sizeof val n1 = q.nitm val p_rgt = q.qarr_rgt val p_beg = q.qarr_beg // extern castfn pdf2sz {i:int} (df: ptrdiff_t i):<> size_t // var p1_end: ptr = p_beg + (n1-n2) * tsz val () = if p1_end >= p_rgt then p1_end := q.qarr_lft + pdf2sz (p1_end \pdiff p_rgt) val p1_end = ptr1_of_ptr (p1_end) stavar l1_end: addr prval _ = p1_end: ptr (l1_end) // prval () = __assert (q.pfqarr) where { extern prfun __assert {lft,rgt,l_beg,l_end:addr} ( pf: !DEQUEarr_v (a, m, n1, lft, rgt, l_beg, l_end) >> DEQUEarr_v (a, m, n1-n2, lft, rgt, l_beg, l1_end) ) : void // end of [extern] } // end of [prval] // val () = q.nitm := n1-n2 val () = q.qarr_end := p1_end } // end of [deque_clear_end] implement deque_clear_all {a} {m,n} (q) = () where { // prval () = __assert (q.pfqarr) where { extern prfun __assert {lft,rgt,l_beg,l_end:addr} ( pf: !DEQUEarr_v ( a, m, n, lft, rgt, l_beg, l_end ) >> DEQUEarr_v (a, m, 0, lft, rgt, lft, lft) ) : void // end of [extern] } // end of [prval] // #define i2sz size1_of_int1 // val () = q.nitm := (i2sz)0 val p_lft = q.qarr_lft val () = q.qarr_beg := p_lft val () = q.qarr_end := p_lft } // end of [deque_clear_all] (* ****** ****** *) implement{a} deque_copyout (q, i, k, xs) = deque_copyout_tsz {a} (q, i, k, xs, sizeof) // end of [deque_copyout] (* ****** ****** *) implement{a} deque_update_capacity ( pfgc2, pfarr2 | q, m2, xs ) = deque_update_capacity_tsz {a} (pfgc2, pfarr2 | q, m2, xs, sizeof) // end of [deque_update_capacity] (* ****** ****** *) (* end of [deque_arr.dats] *) ats-lang-anairiats-0.2.11/libats/ngc/DATS/slist.dats0000664000175000017500000002442712223166162020601 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "libats/ngc/SATS/slist.sats" (* ****** ****** *) extern castfn p2p {l:addr} (p: !ptr l):<> ptr l (* ****** ****** *) implement slseg_v_append {a} (pf1seg, pf2seg) = let prfun append {n1,n2:nat} {la,lm,lz:addr} .. ( pf1seg: slseg_v (a, n1, la, lm) , pf2seg: slseg_v (a, n2, lm, lz) ) : slseg_v (a, n1+n2, la, lz) = begin case+ pf1seg of | slseg_v_cons (pf1nod, pf1seg) => slseg_v_cons (pf1nod, slseg_v_append (pf1seg, pf2seg)) // end of [slseg_v_cons] | slseg_v_nil () => pf2seg end // end of [append] in append (pf1seg, pf2seg) end // end of [slseg_v_append] (* ****** ****** *) implement slseg_v_extend {a} (pfseg, pfnod) = let prfun extend {n:nat} {la,ly,lz:addr} .. ( pfseg: slseg_v (a, n, la, ly) , pfnod: slnode_v (a, ly, lz) ) : slseg_v (a, n+1, la, lz) = case+ pfseg of | slseg_v_cons (pf1nod, pf1seg) => slseg_v_cons (pf1nod, slseg_v_extend (pf1seg, pfnod)) // end of [slseg_v_cons] | slseg_v_nil () => let prval () = slnode_ptr_is_gtz (pfnod) in slseg_v_cons (pfnod, slseg_v_nil ()) end // end of [slseg_v_nil] // end of [extend] in extend (pfseg, pfnod) end // end of [slseg_v_extend] (* ****** ****** *) implement{a} slist_split_at (pflst | pa, i) = if i > 0 then let prval slseg_v_cons (pfnod, pf1lst) = pflst val pb = slnode_get_next (pfnod | pa) val (pfres1, pfres2 | pm) = slist_split_at (pf1lst | pb, i-1) in (slseg_v_cons (pfnod, pfres1), pfres2 | pm) end else ( slseg_v_nil (), pflst | pa ) // end of [if] // end of [slist_split_at] (* ****** ****** *) implement{a} slist_nil () = slist_encode (slseg_v_nil | null) // end of [slist_nil] implement{a} slist_cons ( pfnod | p_nod, xs ) = let prval () = slnode_ptr_is_gtz (pfnod) val (pflst | p_xs) = slist_decode (xs) val () = slnode_set_next (pfnod | p_nod, p_xs) prval pflst = slseg_v_cons (pfnod, pflst) in slist_encode (pflst | p_nod) end // end of [slist_cons] (* ****** ****** *) implement{a} slist_free (xs) = let fun free {n:nat} {la:addr} .. ( pfseg: slist_v (a, n, la) | p: ptr la ) :<> void = if slist_ptr_is_cons (pfseg | p) then let prval slseg_v_cons (pfnod, pf1seg) = pfseg val p1 = slnode_get_next (pfnod | p) val () = slnode_free (pfnod | p) in free (pf1seg | p1) end else begin let prval slseg_v_nil () = pfseg in () end end // end of [if] // end of [free] val (pfseg | p_xs) = slist_decode (xs) in free (pfseg | p_xs) end (* end of [slist_free] *) (* ****** ****** *) implement{a} slist_free_funenv {v} {vt} (pfv | xs, f, env) = let fun free {n:nat} {la:addr} .. ( pfv: !v, pfseg: slist_v (a, n, la) | p: ptr la, f: (!v | &a >> a?, !vt) - void, env: !vt ) :<> void = if slist_ptr_is_cons (pfseg | p) then let prval slseg_v_cons (pfnod, pf1seg) = pfseg prval (pfat, fpfnod) = slnode_v_takeout_val {a} (pfnod) val () = f (pfv | !p, env) prval () = pfnod := fpfnod {a?} (pfat) val p1 = slnode_get_next (pfnod | p) val () = slnode_free (pfnod | p) in free (pfv, pf1seg | p1, f, env) end else begin let prval slseg_v_nil () = pfseg in () end end // end of [if] // end of [free] val (pfseg | p_xs) = slist_decode (xs) in free (pfv, pfseg | p_xs, f, env) end (* end of [slist_free_funenv] *) implement{a} slist_free_fun (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: (&a >> a?) - void):<> (!unit_v | &a >> a?, !ptr) - void } // end of [where] prval pf = unit_v () val () = slist_free_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf in () end // end of [slist_free_fun] implement{a} slist_free_vclo {v} (pf1 | xs, f) = let viewtypedef clo_t = (!v | &a >> a?) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) prval pf = (pf1, view@ f) fn app (pf: !V | x: &a >> a?, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf val () = !p_f (pf1 | x) prval () = pf := (pf1, pf2) in // nothing end // end of [app] val () = slist_free_funenv {V} {ptr l_f} (pf | xs, app, p_f) prval () = pf1 := pf.0 prval () = view@ f := pf.1 in () end // end of [slist_free_vclo] (* ****** ****** *) implement{a} slist_length (xs) = let fun loop {la:addr} {n,k:nat} .. ( pfseg: !slist_v (a, n, la) | p: !ptr la, k: size_t (k) ) :<> size_t (n+k) = if slist_ptr_is_cons (pfseg | p) then let prval slseg_v_cons (pfnod, pf1seg) = pfseg val p1 = slnode_get_next (pfnod | p) val res = loop (pf1seg | p1, k + 1) prval () = pfseg := slseg_v_cons (pfnod, pf1seg) in res end else k // end of [if] // prval ( pfseg | () ) = slist_unfold (xs) val p_xs = p2p (xs) val res = loop (pfseg | p_xs, 0) prval () = slist_fold (pfseg | xs) // in res end // end of [slist_length] (* ****** ****** *) implement{a} slist_append (xs, ys) = let // fun loop {m,n:nat} {la1,lb1:addr} {la2:addr} .. ( pfnod: !slnode_v (a, la1, lb1) >> slnode_v (a, la1, lb1) , pf1lst: slist_v (a, m, lb1) , pf2lst: slist_v (a, n, la2) | p1: ptr la1, p2: ptr la2 ) :<> #[lb1:addr] ( slist_v (a, m+n, lb1) | void ) = let val p11 = slnode_get_next (pfnod | p1) in if slist_ptr_is_cons (pf1lst | p11) then let prval slseg_v_cons (pf1nod, pf1lst1) = pf1lst val (pflst1 | ()) = loop (pf1nod, pf1lst1, pf2lst | p11, p2) in (slseg_v_cons (pf1nod, pflst1) | ()) end else let prval slseg_v_nil () = pf1lst val () = slnode_set_next (pfnod | p1, p2) in (pf2lst | ()) end (* end of [if] *) end // end of [loop] // val (pf1lst | p_xs) = slist_decode (xs) val (pf2lst | p_ys) = slist_decode (ys) // in if slist_ptr_is_cons (pf1lst | p_xs) then let prval slseg_v_cons (pf1nod, pf1lst1) = pf1lst val (pflst1 | ()) = loop (pf1nod, pf1lst1, pf2lst | p_xs, p_ys) val xs = slist_encode {a} (slseg_v_cons (pf1nod, pflst1) | p_xs) in xs end else let prval slseg_v_nil () = pf1lst val ys = slist_encode {a} (pf2lst | p_ys) in ys end (* end of [if] *) end // end of [slist_append] (* ****** ****** *) implement{a} slist_reverse (xs) = let fun reverse {i,j:nat} .. ( xs: slist (a, i), ys: slist (a, j) ) :<> slist (a, i+j) = let val (pflst | p_xs) = slist_decode (xs) in if slist_ptr_is_cons (pflst | p_xs) then let prval slseg_v_cons (pfnod, pf1lst) = pflst val p_xs1 = slnode_get_next (pfnod | p_xs) val xs1 = slist_encode {a} (pf1lst | p_xs1) val ys = slist_cons (pfnod | p_xs, ys) in reverse (xs1, ys) end else let prval slseg_v_nil () = pflst in ys end (* end of [if] *) end // end of [reverse] in reverse (xs, slist_nil ()) end // end of [slist_reverse] (* ****** ****** *) implement{a} slist_foreach_funenv {v} {vt} (pfv | xs, f, env) = let // fun loop {la,lz:addr} {n:nat} .. ( pfv: !v, pfseg: !slist_v (a, n, la) | p: !ptr la, f: (!v | &a, !vt) - void, env: !vt ) :<> void = if slist_ptr_is_cons (pfseg | p) then let prval slseg_v_cons (pfnod, pf1seg) = pfseg prval (pfat, fpfnod) = slnode_v_takeout_val {a} (pfnod) val () = f (pfv | !p, env) prval () = pfnod := fpfnod (pfat) val p1 = slnode_get_next (pfnod | p) val () = loop (pfv, pf1seg | p1, f, env) in pfseg := slseg_v_cons (pfnod, pf1seg) end // end of [if] (* end of [loop] *) // prval ( pfseg | p_xs ) = slist_unfold (xs) val p_xs = p2p (xs) val () = loop (pfv, pfseg | p_xs, f, env) prval () = slist_fold (pfseg | xs) // in // nothing end // end of [slist_foreach_funenv] (* ****** ****** *) implement{a} slist_foreach_fun (xs, f) = let val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void):<> (!unit_v | &a, !ptr) -<> void } // end of [where] prval pf = unit_v () val () = slist_foreach_funenv {unit_v} {ptr} (pf | xs, f, null) prval unit_v () = pf in // nothing end // end of [slist_foreach_fun] (* ****** ****** *) implement{a} slist_foreach_vclo {v} (pfv | xs, f) = let // stavar l_f: addr val p_f: ptr l_f = &f // typedef clo_t = (!v | &a) - void typedef vt = ptr l_f viewdef V = (v, clo_t @ l_f) // fn app ( pf: !V | x: &a, p_f: !vt ) :<> void = let prval pf1 = pf.1 val () = !p_f (pf.0 | x) prval () = pf.1 := pf1 in // nothing end // end of [app] // prval pfV = (pfv, view@ f) val () = slist_foreach_funenv {V} {vt} (pfV | xs, app, p_f) prval () = pfv := pfV.0 prval () = view@ f := pfV.1 // in // nothing end // end of [slist_foreach_vclo] (* ****** ****** *) (* end of [slist.dats] *) ats-lang-anairiats-0.2.11/libats/ngc/DATS/dlist.dats0000664000175000017500000004241012223166162020552 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Artyom Shalkhakov (artyom.shalkhakov AT gmail DOT com) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // minor modification // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "libats/ngc/SATS/dlist.sats" (* ****** ****** *) extern castfn p2p {l:addr} (p: !ptr l):<> ptr l (* ****** ****** *) #define dcons dlseg_v_cons #define dnil dlseg_v_nil #define rcons rdlseg_v_cons #define rnil rdlseg_v_nil (* ****** ****** *) extern fun dlseg_ptr_is_cons {a:vt0p} {n:nat} {lf,lfp,lr,lrn:addr} ( pf: !dlseg_v (a, n, lf, lfp, lr, lrn) | p: ptr lf ) :<> bool (n > 0) = "atspre_ptr_isnot_null" extern fun rdlseg_ptr_is_cons {a:vt0p} {n:nat} {lf,lfp,lr,lrn:addr} ( pf: !rdlseg_v (a, n, lf, lfp, lr, lrn) | p: ptr lr ) :<> bool (n > 0) = "atspre_ptr_isnot_null" (* ****** ****** *) implement{a} dlist_is_at_end {nf,nr} (xs) = let prval (pf | ()) = dlist_unfold {a} (xs) stavar lm:addr prval pf = pf: dlist_v (a, nf, nr, lm) val p_xs = p2p (xs) prval dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, pf2dl)) = pf val nx = dlnode_get_next (pfhd | p_xs) var res: bool // uninitialized val () = if :(pf: dlist_v (a, nf, nr, lm), res: bool (nr <= 1)) => dlseg_ptr_is_cons {a} (pf2dl | nx) then let prval dlseg_v_cons (pf_at, pf21dl) = pf2dl in pf := dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, dlseg_v_cons (pf_at, pf21dl))); res := false end else let prval dlseg_v_nil () = pf2dl in pf := dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, dlseg_v_nil ())); res := true end // end of [if] prval () = dlist_fold (pf | xs) // HX: no-op at run-time in res end // end of [dlist_is_at_end] implement{a} dlist_isnot_at_end (xs) = ~dlist_is_at_end (xs) implement{a} dlist_is_at_beg {nf,nr} (xs) = let prval (pf | ()) = dlist_unfold (xs) stavar lm:addr prval pf = pf: dlist_v (a, nf, nr, lm) val p_xs = p2p (xs) prval dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, pf2dl)) = pf val pr = dlnode_get_prev (pfhd | p_xs) var res: bool // uninitialized val () = if :(pf: dlist_v (a, nf, nr, lm), res: bool (nf == 0)) => rdlseg_ptr_is_cons {a} (pf1dl | pr) then let prval rdlseg_v_cons (pf11dl, pf_at) = pf1dl in pf := dlist_v_cons (rdlseg_v_cons (pf11dl, pf_at), dlseg_v_cons (pfhd, pf2dl)); res := false end else let prval rdlseg_v_nil () = pf1dl in pf := dlist_v_cons (rdlseg_v_nil (), dlseg_v_cons (pfhd, pf2dl)); res := true end; // end of [if] prval () = dlist_fold (pf | xs) // HX: no-op at run-time in res end // end of [dlist_is_at_beg] implement{a} dlist_isnot_at_beg {nf,nr} (xs) = ~dlist_is_at_beg (xs) (* ****** ****** *) implement{a} dlist_nil () = dlist_encode (dlist_v_nil () | null) (* ****** ****** *) implement{a} dlist_sing {l,lp,ln} ( pfnod | p ) = ( dlnode_set_next (pfnod | p, null); dlnode_set_prev (pfnod | p, null); dlist_encode (dlist_v_cons (rnil (), dcons (pfnod, dnil ())) | p) ) // end of [dlist_sing] (* ****** ****** *) implement{a} dlist_cons {nr} (pfnod | p, xs) = let val () = dlnode_set_prev (pfnod | p, null) val (pflst | p_xs) = dlist_decode {a} (xs) val () = dlnode_set_next (pfnod | p, p_xs) in // if p_xs > null then let prval dlist_v_cons (pf1lst, pf2lst) = pflst prval rdlseg_v_nil () = pf1lst prval dlseg_v_cons (pf2nod, pf2lst) = pf2lst val () = dlnode_set_prev (pf2nod | p_xs, p) prval pf2lst = dlseg_v_cons (pf2nod, pf2lst) prval pflst = dlist_v_cons (rdlseg_v_nil (), dlseg_v_cons {a} (pfnod, pf2lst)) in dlist_encode (pflst | p) end else let prval () = __assert () where { extern prfun __assert (): [nr <= 0] void } // end of [where] prval dlist_v_nil () = pflst prval pflst = dlist_v_cons (rdlseg_v_nil (), dlseg_v_cons {a} (pfnod, dlseg_v_nil ())) in dlist_encode (pflst | p) end (* end of [if] *) // end // end of [dlist_cons] (* ******** ******* *) implement{a} dlist_uncons {nr} (xs) = let val (pf | p_xs) = dlist_decode (xs) prval dlist_v_cons (rnil (), dcons (pfhd, pfdl)) = pf val nx = dlnode_get_next (pfhd | p_xs) in // if nx > null then let prval dcons (pf1_at, pf1dl) = pfdl val () = dlnode_set_prev (pf1_at | nx, null) prval pfdl = dcons {a} (pf1_at, pf1dl) val () = xs := dlist_encode (dlist_v_cons (rnil, pfdl) | nx) in (pfhd | p_xs) end else let prval () = __assert () where { extern prfun __assert (): [nr <= 0] void } // end of [where] prval dnil () = pfdl val () = xs := dlist_encode (dlist_v_nil () | nx) in (pfhd | p_xs) end (* end of [if] *) // end // end of [dlist_uncons] (* ******** ******* *) implement{a} dlist_insert_after {nf,nr} {l1,lp,ln} (pfnod | p1, xs) = let prval (pfdl | ()) = dlist_unfold {a} (xs) val p2 = p2p (xs) // HX: this is optimized away prval dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, pf2dl)) = pfdl val () = dlnode_set_prev (pfnod | p1, p2) val nx = dlnode_get_next (pfhd | p2) val () = dlnode_set_next (pfnod | p1, nx) val () = dlnode_set_next (pfhd | p2, p1) in // if nx > null then let prval dcons (pf_at, pf21dl) = pf2dl val () = dlnode_set_prev (pf_at | nx, p1) prval () = pf2dl := dlseg_v_cons {a} (pf_at, pf21dl) prval pfdl = dlist_v_cons (pf1dl, dcons (pfhd, dcons (pfnod, pf2dl))) prval () = dlist_fold (pfdl | xs) in // nothing end else let prval () = __assert () where { extern prfun __assert (): [nr <= 1] void } // end of [prval] prval dnil () = pf2dl prval () = pf2dl := dnil {a} () prval pfdl = dlist_v_cons (pf1dl, dcons (pfhd, dcons (pfnod, pf2dl))) prval () = dlist_fold (pfdl | xs) in // nothing end (* end of [if] *) // end // end of [dlist_insert_after] (* ****** ****** *) implement{a} dlist_insert_before {nf,nr} {l1,lp,ln} (pfnod | p1, xs) = let prval (pfdl | ()) = dlist_unfold {a} (xs) val p2 = p2p (xs) // HX: this is optimized away prval dlist_v_cons (pf1dl, dcons (pfhd, pf2dl)) = pfdl val () = dlnode_set_next (pfnod | p1, p2) val pr = dlnode_get_prev (pfhd | p2) val () = dlnode_set_prev (pfhd | p2, p1) val () = dlnode_set_prev (pfnod | p1, pr) in // if pr > null then let prval rcons (pf11dl, pf_at) = pf1dl val () = dlnode_set_next (pf_at | pr, p1) prval pf1dl = rcons {a} (rcons {a} (pf11dl, pf_at), pfnod) prval pfdl = dlist_v_cons (pf1dl, dcons {a} (pfhd, pf2dl)) prval () = dlist_fold (pfdl | xs) in // nothing end else let prval () = __assert () where { extern prfun __assert (): [nf <= 0] void } // end of [where] prval rdlseg_v_nil () = pf1dl prval pf1dl = rdlseg_v_cons {a} (rdlseg_v_nil {a} (), pfnod) prval pfdl = dlist_v_cons (pf1dl, dlseg_v_cons {a} (pfhd, pf2dl)) prval () = dlist_fold (pfdl | xs) in // nothing end (* end of [if] *) // end // end of [dlist_insert_before] (* ******** ******* *) implement{a} dlist_remove {nf,nr} (xs) = let val (pfdl | p1) = dlist_decode {a} (xs) // casting prval dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, pf2dl)) = pfdl val pr = dlnode_get_prev (pfhd | p1) val nx = dlnode_get_next (pfhd | p1) prval dcons (pf2_at, pf21dl) = pf2dl val () = dlnode_set_prev (pf2_at | nx, pr) in // if pr > null then let prval rcons (pf11dl, pf1_at) = pf1dl val () = dlnode_set_next (pf1_at | pr, nx) prval pfdl = dlist_v_cons (rcons {a} (pf11dl, pf1_at), dcons {a} (pf2_at, pf21dl)) val () = xs := dlist_encode (pfdl | nx) in (pfhd | p1) end else let prval () = __assert () where { extern prfun __assert (): [nf <= 0] void } // end of [where] prval rnil () = pf1dl prval pfdl = dlist_v_cons (rnil {a} (), dcons {a} (pf2_at, pf21dl)) val () = xs := dlist_encode (pfdl | nx) in (pfhd | p1) end (* end of [if] *) // end // end of [dlist_remove] (* ****** ****** *) implement{a} dlist_remove_after {nf,nr} (xs) = let val (pfdl | ()) = dlist_unfold {a} (xs) // casting val p_xs = p2p (xs) prval dlist_v_cons (pf1dl, dlseg_v_cons (pf2_at, pf2dl)) = pfdl val nx = dlnode_get_next (pf2_at | p_xs) prval dcons (pfhd, pf2dl) = pf2dl val nx2 = dlnode_get_next (pfhd | nx) val () = dlnode_set_next (pf2_at | p_xs, nx2) in // if nx2 > null then let prval dcons (pf21_at, pf21dl) = pf2dl val () = dlnode_set_prev (pf21_at | nx2, p_xs) prval pf2dl = dcons {a} (pf21_at, pf21dl) prval pfdl = dlist_v_cons (pf1dl, dcons {a} (pf2_at, pf2dl)) prval () = dlist_fold (pfdl | xs) in (pfhd | nx) end else let prval () = __assert () where { extern prfun __assert (): [nr <= 2] void } // end of [where] prval dnil () = pf2dl prval pfdl = dlist_v_cons (pf1dl, dcons {a} (pf2_at, dnil {a} ())) prval () = dlist_fold (pfdl | xs) in (pfhd | nx) end (* end of [if] *) // end // end of [dlist_remove_after] (* ****** ****** *) implement{a} dlist_remove_before {nf,nr} (xs) = let val (pfdl | ()) = dlist_unfold {a} (xs) // casting val p_xs = p2p (xs) prval dlist_v_cons (pf1dl, dlseg_v_cons (pf2_at, pf2dl)) = pfdl val pr = dlnode_get_prev (pf2_at | p_xs) prval rcons (pf1dl, pfhd) = pf1dl val pr2 = dlnode_get_prev (pfhd | pr) val () = dlnode_set_prev (pf2_at | p_xs, pr2) in // if pr2 > null then let prval rcons (pf11dl, pf11_at) = pf1dl val () = dlnode_set_next (pf11_at | pr2, p_xs) prval pf1dl = rcons {a} (pf11dl, pf11_at) prval pfdl = dlist_v_cons (pf1dl, dcons {a} (pf2_at, pf2dl)) prval () = dlist_fold (pfdl | xs) in (pfhd | pr) end else let prval () = __assert () where { extern prfun __assert (): [nf <= 0] void } // end of [where] prval rnil () = pf1dl prval pfdl = dlist_v_cons (rnil {a} (), dcons {a} (pf2_at, pf2dl)) prval () = dlist_fold (pfdl | xs) in (pfhd | pr) end (* end of [if] *) // end // end of [dlist_remove_before] (* ****** ****** *) implement{a} dlist_move_forward {nf,nr} (xs) = let val (pf | p1) = dlist_decode {a} (xs) // casting prval dlist_v_cons (pf1dl, dlseg_v_cons (pfhd, pf2dl)) = pf val res = dlnode_get_next (pfhd | p1) prval () = pf := dlist_v_cons (rdlseg_v_cons (pf1dl, pfhd), pf2dl) in dlist_encode (pf | res) end // end of [dlist_move_forward] implement{a} dlist_move_backward {nf,nr} (xs) = let val (pf | p1) = dlist_decode {a} (xs) // casting prval dlist_v_cons ( rdlseg_v_cons (pf1dl, pf1), dlseg_v_cons (pfhd, pf2dl) ) = pf val res = dlnode_get_prev (pfhd | p1) prval () = pf := dlist_v_cons (pf1dl, dlseg_v_cons (pf1, dlseg_v_cons (pfhd, pf2dl))) in dlist_encode (pf | res) end // end of [dlist_move_backward] (* ****** ****** *) implement{a} dlist_free {nf,nr} (xs) = let fun loop0 {n:nat} {lf,lmp,lm:addr} .. ( pf: rdlseg_v (a, n, lf, null, lmp, lm) | p: ptr lmp ) :<> void = if rdlseg_ptr_is_cons (pf | p) then let prval rcons (pf1, pfnod) = pf val p1 = dlnode_get_prev (pfnod | p) val () = dlnode_free (pfnod | p) in loop0 (pf1 | p1) end else begin let prval rnil () = pf in () end end // end of [loop0] fun loop1 {n:nat} {l,lp,lr:addr} .. ( pf: dlseg_v (a, n, l, lp, lr, null) | p: ptr l ) :<> void = if dlseg_ptr_is_cons (pf | p) then let prval dcons (pfnod, pf1) = pf val p1 = dlnode_get_next (pfnod | p) val () = dlnode_free (pfnod | p) in loop1 (pf1 | p1) end else begin let prval dnil () = pf in () end end // end of [loop1] in if dlist_is_cons (xs) then let val (pf | p) = dlist_decode {a} (xs) // casting prval dlist_v_cons (pf1, dcons (pfhd, pf2)) = pf val pr = dlnode_get_prev (pfhd | p) val nx = dlnode_get_next (pfhd | p) val () = dlnode_free (pfhd | p) val () = loop0 (pf1 | pr) val () = loop1 (pf2 | nx) in // nothing end else let prval (pf | ()) = dlist_unfold {a} (xs) // end of [prval] prval () = cleanup_top {ptr} (xs) prval dlist_v_nil () = pf in // nothing end // end of [if] end // end of [dlist_free] (* ****** ****** *) implement{a} dlist_free_funenv {v} {vt} {nf,nr} (pfv | xs, f, env) = let fun loop0 {n:nat} {lf,lmp,lm:addr} .. ( pfv: !v, pf: rdlseg_v (a, n, lf, null, lmp, lm) | p: ptr lmp, f: (!v | &a >> a?, !vt) - void, env: !vt ) :<> void = if rdlseg_ptr_is_cons (pf | p) then let prval rcons (pf1, pfnod) = pf prval (pfat, fpfnod) = dlnode_v_takeout_val {a} (pfnod) val () = f (pfv | !p, env) prval () = pfnod := fpfnod {a?} (pfat) val p1 = dlnode_get_prev (pfnod | p) val () = dlnode_free (pfnod | p) in loop0 (pfv, pf1 | p1, f, env) end else let prval rnil () = pf in () end (* end of [if] *) // end of [loop0] fun loop1 {n:nat} {l,lp,lr:addr} .. ( pfv: !v, pf: dlseg_v (a, n, l, lp, lr, null) | p: ptr l, f: (!v | &a >> a?, !vt) - void, env: !vt ) :<> void = if dlseg_ptr_is_cons (pf | p) then let prval dcons (pfnod, pf1) = pf prval (pfat, fpfnod) = dlnode_v_takeout_val {a} (pfnod) val () = f (pfv | !p, env) prval () = pfnod := fpfnod {a?} (pfat) val p1 = dlnode_get_next (pfnod | p) val () = dlnode_free (pfnod | p) in loop1 (pfv, pf1 | p1, f, env) end else let prval dnil () = pf in () end (* end of [if] *) // end of [loop1] in if dlist_is_cons xs then let val (pf | p) = dlist_decode {a} (xs) // casting prval dlist_v_cons (pf1, dcons (pfhd, pf2)) = pf val pr = dlnode_get_prev (pfhd | p) val nx = dlnode_get_next (pfhd | p) prval (pfat, fpfhd) = dlnode_v_takeout_val {a} (pfhd) val () = f (pfv | !p, env) prval pfhd = fpfhd {a?} (pfat) val () = dlnode_free (pfhd | p) val () = loop0 (pfv, pf1 | pr, f, env) val () = loop1 (pfv, pf2 | nx, f, env) in // nothing end else let prval (pf | ()) = dlist_unfold {a} (xs) // end of [prval] prval () = cleanup_top {ptr} (xs) prval dlist_v_nil () = pf in (*empty*) end // end of [if] end // end of [dlist_free_funenv] implement{a} dlist_free_fun (xs, f) = () where { val f = coerce (f) where { extern castfn coerce (f: (&a >> a?) - void):<> (!unit_v | &a >> a?, !ptr) - void } // end of [where] prval pf = unit_v () val () = dlist_free_funenv {..} {ptr} (pf | xs, f, null) prval unit_v () = pf } // end of [dlist_free_fun] implement{a} dlist_free_vclo {v} (pf1 | xs, f) = () where { viewtypedef clo_t = (!v | &a >> a?) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef V = (v, clo_t @ l_f) prval pf = (pf1, view@ f) fn app (pf: !V | x: &a >> a?, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf val () = !p_f (pf1 | x) prval () = pf := (pf1, pf2) in // nothing end // end of [app] val () = dlist_free_funenv {V} {ptr l_f} (pf | xs, app, p_f) prval () = pf1 := pf.0 prval () = view@ f := pf.1 } // end of [dlist_free_vclo] (* ****** ****** *) implement{a} dlist_appfst_funenv (pfv | xs, f, env) = () where { prval (pf | ()) = dlist_unfold {a} (xs) val p = p2p (xs) prval dlist_v_cons (pf1, dcons (pfhd, pf2)) = pf prval (pfat, fpfhd) = dlnode_v_takeout_val {a} (pfhd) val () = f (pfv | !p, env) prval pfhd = fpfhd {a} (pfat) prval pf = dlist_v_cons (pf1, dcons (pfhd, pf2)) prval () = dlist_fold {a} (pf | xs) } // end of [dlist_appfst_funenv] implement{a} dlist_appfst_fun (xs, f) = () where { prval (pf | ()) = dlist_unfold {a} (xs) val p = p2p (xs) prval dlist_v_cons (pf1, dcons (pfhd, pf2)) = pf prval (pfat, fpfhd) = dlnode_v_takeout_val {a} (pfhd) val () = f (!p) prval pfhd = fpfhd {a} (pfat) prval pf = dlist_v_cons (pf1, dcons (pfhd, pf2)) prval () = dlist_fold {a} (pf | xs) } // end of [dlist_appfst_fun] implement{a} dlist_appfst_vclo (pfv | xs, f) = () where { prval (pf | ()) = dlist_unfold {a} (xs) val p = p2p (xs) prval dlist_v_cons (pf1, dcons (pfhd, pf2)) = pf prval (pfat, fpfhd) = dlnode_v_takeout_val {a} (pfhd) val () = f (pfv | !p) prval pfhd = fpfhd {a} (pfat) prval pf = dlist_v_cons (pf1, dcons (pfhd, pf2)) prval () = dlist_fold {a} (pf | xs) } // end of [dlist_appfst_fun] (* ****** ****** *) (* end of [dlist.dats] *) ats-lang-anairiats-0.2.11/libats/SATS/0000700000175000017500000000000012223166162016011 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/SATS/refcount.sats0000664000175000017500000000442612223166162020554 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) absviewtype nref_viewt0ype_viewtype (a:viewt@ype) = ptr // non-reentrant stadef nref = nref_viewt0ype_viewtype (* ****** ****** *) fun{a:viewt@ype} refcount_make (x: a):<> nref (a) fun{a:viewt@ype} refcount_ref (r: !nref a): nref a fun{a:viewt@ype} refcount_unref ( r: nref a, x: &a? >> opt (a, b) ) : #[b: bool] bool(b) // end of [fun] fun{a:viewt@ype} refcount_unref_fun (r: nref a, f: (&a >> a?) - void): void // end of [refcount_unref_fun] fun{a:viewt@ype} refcount_get_count (r: !nref a): uint (* ****** ****** *) absviewtype nrefout (a:viewt@ype, l:addr) = nref (a) prfun refcount_addback {a:viewt@ype} {l:addr} (pf: a @ l | r: !nrefout (a, l) >> nref (a)): void // end of [refcount_addback] fun{a:viewt@ype} refcount_takeout (r: !nref a >> nrefout (a, l)): #[l:addr] (a @ l | ptr l) // end of [refcount_takeout] (* ****** ****** *) (* end of [refcount.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linmap_rbtree.sats0000664000175000017500000001275512223166162021556 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on red-black trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) absviewtype map_viewtype (key:t@ype, itm:viewt@ype+) stadef map = map_viewtype (* ****** ****** *) typedef cmp (key:t@ype) = (key, key) - int fun{key:t@ype} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) fun{} linmap_make_nil {key:t0p;itm:vt0p} ():<> map (key, itm) (* ****** ****** *) fun{} linmap_is_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool fun{} linmap_isnot_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool (* ****** ****** *) // // this function is O(n)-time and non-tail-recursive // fun{key,itm:t@ype} linmap_size (m: !map (key, itm)):<> size_t (* ****** ****** *) // // HX: this function is O(n) // for gathering stats // fun{key,itm:t@ype} linmap_height (m: !map (key, itm)):<> Nat // // HX: this function is O(log(n)) // for gathering stats // fun{key,itm:t@ype} linmap_black_height (m: !map (key, itm)):<> Nat (* ****** ****** *) fun{ key:t0p;itm:t0p } linmap_search ( m: !map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_search] fun{ key:t0p;itm:vt0p } linmap_search_ref ( m: !map (key, itm), k0: key, cmp: cmp key // unsafe but ... ) :<> Ptr // end of [linmap_search_ref] (* ****** ****** *) // // HX: // if [k0] occurs in [m], [x0] replaces the original value associated // with [k0] // fun{key:t0p;itm:vt0p} linmap_insert ( m: &map (key, itm) , k0: key, x0: itm, cmp: cmp key , res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_insert] (* ****** ****** *) fun{key:t0p;itm:vt0p} linmap_takeout ( m: &map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_takeout] fun{key:t0p;itm:t0p} linmap_remove (m: &map (key, itm), k0: key, cmp: cmp key):<> bool // end of [linmap_remove] (* ****** ****** *) // // HX: note the [foreach] can be used as [clear] // fun{key:t0p;itm:vt0p} linmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_foreach_funenv] fun{key:t0p;itm:vt0p} linmap_foreach_fun ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun] fun{key:t0p;itm:vt0p} linmap_foreach_vclo {v:view} ( pf: !v | m: !map (key, itm), f: &(!v | key, &itm) - void ) :<> void // end of [linmap_foreach_vclo] fun{key:t0p;itm:vt0p} linmap_foreach_cloref (m: !map (key, itm), f: (key, &itm) - void): void // end of [linmap_foreach_cloref] (* ****** ****** *) // // HX: [foreach] in the reverse order // fun{key:t0p;itm:vt0p} linmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_rforeach_funenv] (* ****** ****** *) // // HX: [clear] is based on [foreach] // fun{ key:t0p;itm:vt0p } linmap_clear_funenv {v:view}{vt:viewtype} ( pfv: !v | m: !map (key, itm) >> map (key, itm?) , f: (!v | key, &itm >> itm?, !vt) - void , env: !vt ) : void // end of [linmap_clear_funenv] (* ****** ****** *) // fun{key:t0p;itm:t0p} linmap_free (m: map (key, itm)):<> void // // HX: a linear map can be properly freed only if it is empty // fun{ key:t0p;itm:vt0p } linmap_free_vt ( m: !map (key, itm) >> opt (map (key, itm), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linmap_free_vt] (* ****** ****** *) // // HX: listization is done in the in-order fashion // // // HX-2010-07-01: // this one can be readily implemented based on [foreach] // fun{key:t0p;itm:t0p} linmap_listize (m: !map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize] fun{key:t0p;itm:vt0p} linmap_listize_free (m: map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize_free] (* ****** ****** *) (* end of [linmap_rbtree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funheap_braun.sats0000664000175000017500000000523112223166162021537 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional heap implementation based on Braun trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in November, 2008 ** *) (* ****** ****** *) // // HX-2011-11-13: // This style of heap is VERY inefficient! Please use funheap_binomial // instead, which is about 20 times faster for a heap of the size 1M. // (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) abstype heap_t0ype_type (a:t@ype+) stadef heap = heap_t0ype_type (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - Sgn fun{a:t@ype} compare_elt_elt (x1: a, x2: a, cmp: cmp a):<> Sgn (* ****** ****** *) fun{} funheap_make_nil {a:t@ype} ():<> heap (a) (* ****** ****** *) // fun{a:t@ype} funheap_size (hp: heap a):<> size_t // // HX: primarily for statistics fun{a:t@ype} funheap_height (hp: heap a):<> Nat // (* ****** ****** *) fun{a:t@ype} funheap_insert (hp: &heap (a), x: a, cmp: cmp a):<> void (* ****** ****** *) fun{a:t@ype} funheap_delmin ( hp: &heap (a), res: &a? >> opt (a, b), cmp: cmp a ) :<> #[b:bool] bool b // end of [funheap_delim] (* ****** ****** *) (* end of [funheap_braun.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linset_avltree.sats0000664000175000017500000001141012223166162021736 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A set implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: October, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) sortdef t0p = t@ype (* ****** ****** *) absviewtype set_t0ype_viewtype (a: t@ype+) stadef set = set_t0ype_viewtype (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - int fun{a:t0p} compare_elt_elt (x1: a, x2: a, cmp: cmp (a)):<> int (* ****** ****** *) fun{} linset_make_nil {a:t@ype} ():<> set (a) fun{a:t0p} linset_make_sing (x0: a):<> set (a) // singleton set (* ****** ****** *) fun{} linset_is_empty {a:t0p} (xs: !set a):<> bool fun{} linset_isnot_empty {a:t0p} (xs: !set a):<> bool (* ****** ****** *) // // HX: the time complexity of this function is O(n), where n is fun{a:t@ype} linset_size (xs: !set a):<> size_t // the size of the set // (* ****** ****** *) fun{a:t0p} linset_is_member (xs: !set a, x0: a, cmp: cmp a):<> bool fun{a:t0p} linset_isnot_member (xs: !set a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} linset_free (xs: set (a)):<> void (* ****** ****** *) fun{a:t@ype} linset_copy (xs: !set (a)):<> set (a) (* ****** ****** *) fun{a:t@ype} linset_insert ( xs: &set (a), x0: a, cmp: cmp a ) :<> bool(*[x0] alreay exists in [xs]*) // end of [linset_insert] (* ****** ****** *) fun{a:t@ype} linset_remove ( xs: &set (a), x0: a, cmp: cmp (a) ) :<> bool(*[x0] removed/not: true/false*) // end of [linset_remove] (* ****** ****** *) // // HX: choosing an element in an unspecified manner // fun{a:t@ype} linset_choose ( xs: !set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [linset_choose] // // HX: removing an element chosen in an unspecified manner // fun{a:t@ype} linset_choose_out ( xs: &set a >> set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [linset_choose_out] // (* ****** ****** *) fun{a:t@ype} linset_union (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_intersect (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_diff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_symdiff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) (* ****** ****** *) fun{a:t@ype} linset_is_subset // xs2 contains xs1 (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool // end of [linset_is_subset] fun{a:t@ype} linset_is_supset // xs1 contains xs2 (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool // end of [linset_is_supset] fun{a:t@ype} linset_is_equal (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} linset_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: !set (a) , f: (!v | a, !vt) - void , env: !vt ) :<> void // end of [linset_foreach_funenv] fun{a:t@ype} linset_foreach_fun ( xs: !set (a) , f: (a) - void ) :<> void // end of [linset_foreach_fun] fun{a:t@ype} linset_foreach_vclo {v:view} ( pf: !v | xs: !set (a) , f: &(!v | a) - void ) :<> void // end of [linset_foreach_vclo] fun{a:t@ype} linset_foreach_cloref ( xs: !set (a) , f: (a) - void ) : void // end of [linset_foreach_cloref] (* ****** ****** *) fun{a:t@ype} linset_listize (xs: !set (a)):<> List_vt (a) fun{a:t@ype} linset_listize_free (xs: set (a)):<> List_vt (a) (* ****** ****** *) (* end of [linset_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/fmatrix.sats0000664000175000017500000001735312223166162020404 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Fortran matrices: column-major representation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/fmatrix.cats" %} // end of [%{#] (* ****** ****** *) staload "libats/SATS/genarrays.sats" (* ****** ****** *) // // HX: [fmatrix] is column-major // absviewt@ype fmatrix_viewt0ype_int_int_viewt0ype (a:viewt@ype+,row:int,col:int) = @[@[a][row]][col] stadef fmatrix = fmatrix_viewt0ype_int_int_viewt0ype viewdef fmatrix_v ( a:viewt@ype, row:int, col:int, l:addr ) = fmatrix (a, row, col) @ l (* ****** ****** *) prfun array_v_of_fmatrix_v {a:viewt@ype} {m,n:int} {l:addr} (pf_mat: fmatrix_v (a, m, n, l)) :<> [mn:int] (MUL (m, n, mn), array_v (a, mn, l)) // end of [array_v_of_fmatrix_v] prfun fmatrix_v_of_array_v {a:viewt@ype} {m,n:int} {mn:int} {l:addr} (pf_mul: MUL (m, n, mn), pf_arr: array_v (a, mn, l)) :<> fmatrix_v (a, m, n, l) // end of [fmatrix_v_of_array_v] (* ****** ****** *) fun{a:viewt@ype} fmatrix_ptr_alloc {m,n:nat} ( m: size_t m, n: size_t n ) :<> [mn:nat] [l:agz] ( free_gc_v (a?, mn, l) , MUL (m, n, mn) , fmatrix_v (a?, m, n, l) | ptr l ) // end of [fmatrix_ptr_alloc] (* ****** ****** *) fun fmatrix_ptr_free {a:t@ype} {m,n,mn:nat} {l:addr} ( pf_gc: free_gc_v (a, mn, l) , pf_mn: MUL (m, n, mn) , pf_fmat: fmatrix_v (a, m, n, l) | p: ptr l ) :<> void // end of [fmatrix_ptr_free] (* ****** ****** *) fun{a:viewt@ype} fmatrix_ptr_allocfree {m,n:nat} ( m: size_t m, n: size_t n ) :<> [l:agz] ( fmatrix_v (a?, m, n, l) | ptr l, (fmatrix_v (a?, m, n, l) | ptr l) - void ) // end of [fmatrix_ptr_allocfree] (* ****** ****** *) fun{a:t@ype} fmatrix_ptr_initialize_elt {m,n:nat} {l:addr} ( base: &fmatrix (a?, m, n) >> fmatrix (a, m, n) , m: size_t m, n: size_t n, x: a ) :<> void // end of [fmatrix_initialize_elt] (* ****** ****** *) fun{a:viewt@ype} fmatrix_ptr_initialize_vclo {v:view} {m,n:nat} ( pf: !v | base: &fmatrix (a?, m, n) >> fmatrix (a, m, n) , m: size_t m, n: size_t n , f: &(!v | &(a?) >> a, sizeLt m, sizeLt n) - void ) :<> void // end of [fmatrix_ptr_initialize_vclo] (* ****** ****** *) fun{a:viewt@ype} fmatrix_ptr_takeout {m,n:int} {i,j:nat | i < m; j < n} {l0:addr} ( pf_mat: fmatrix_v (a, m, n, l0) | base: ptr l0 , m: size_t m , i: size_t i, j: size_t j ) :<> [l:addr] ( a @ l , a @ l - fmatrix_v (a, m, n, l0) | ptr l ) // end of [fmatrix_ptr_takeout] (* ****** ****** *) fun{a:t@ype} fmatrix_ptr_get_elt_at {m,n:int} {i,j:nat | i < m; j < n} ( base: &fmatrix (a, m, n), m: size_t m, i: size_t i, j: size_t j ) :<> a // end of [fmatrix_ptr_ptr_get_elt_at] fun{a:t@ype} fmatrix_ptr_set_elt_at {m,n:int} {i,j:nat | i < m; j < n} ( base: &fmatrix (a, m, n), m: size_t m, i: size_t i, j: size_t j, x: a ) :<> void // end of [fmatrix_ptr_ptr_set_elt_at] overload [] with fmatrix_ptr_get_elt_at overload [] with fmatrix_ptr_set_elt_at (* ****** ****** *) fun{a:t@ype} fmatrix_ptr_copy {m,n:nat} ( A: &fmatrix(a, m, n) , B: &fmatrix(a?, m, n) >> fmatrix(a, m, n) , m: size_t m, n: size_t n ) : void // end of [fmatrix_ptr_copy] (* ****** ****** *) prfun GEVEC_v_of_fmatrix_v {a1:viewt@ype} {m,n:nat} {mn:int} {l:addr} ( pf_mul: MUL (m, n, mn), pf_mat: fmatrix_v (a1, m, n, l) ) :<> ( GEVEC_v (a1, mn, 1, l) , {a2:viewt@ype | a1 \tszeq a2} GEVEC_v (a2, mn, 1, l) - fmatrix_v (a2, m, n, l) // [fpf: for going back] ) // end of [GEVEC_v_of_fmatrix_v] (* // this kind of destroys the genericity of GEVEC prfun fmatrix_v_of_GEVEC_v_of {a:viewt@ype} {m,n:nat} {mn:int} {l:addr} ( pf_mul: MUL (m, n, mn), pf_mat: GEVEC_v (a, mn, 1, l) ) :<> ( fmatrix_v (a, m, n, l) , fmatrix_v (a, m, n, l) - GEVEC_v (a, mn, 1, l) ) // end of [GEVEC_v_of_fmatrix_v] *) (* ****** ****** *) prfun GEMAT_v_of_fmatrix_v {a1:viewt@ype} {m,n:nat} {l:addr} ( pf_mat: fmatrix_v (a1, m, n, l) ) :<> ( GEMAT_v (a1, m, n, col, m, l) , {a2:viewt@ype | a1 \tszeq a2} GEMAT_v (a2, m, n, col, m, l) - fmatrix_v (a2, m, n, l) // [fpf: for going back] ) // end of [GEMAT_v_of_fmatrix_v] (* // this kind of destroys the genericity of GEMAT prfun fmatrix_v_of_GEMAT_v {a:viewt@ype} {m,n:nat} {l:addr} ( pf_mat: GEMAT_v (a, m, n, col, m, l) ) :<> ( fmatrix_v (a, m, n, l) , fmatrix_v (a, m, n, l) - GEMAT_v (a, m, n, col, m, l) ) // end of [GEMAT_v_of_fmatrix_v] *) (* ****** ****** *) prfun GBMAT_v_of_fmatrix_v {a:viewt@ype} {m,n,k,kl,ku:nat| k == kl+ku+1} {l:addr} ( pf : fmatrix_v (a, k, n, l), m : size_t m, kl : size_t kl, ku : size_t ku ) :<> ( GBMAT_v (a, m, n, col, kl, ku, k, l) , GBMAT_v (a, m, n, col, kl, ku, k, l) - fmatrix_v (a, k, n, l) ) // end of [GEBAT_v_of_fmatrix_v] (* ****** ****** *) fun fmatrix_ptr_foreach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {ord:order} {m,n:nat} ( pf: !v | M: &fmatrix (a, m, n) , f: (!v | &a, !vt) - void , ord: ORDER ord, m: size_t m, n: size_t n , tsz: sizeof_t a , env: !vt ) :<> void // end of [fmatrix_foreach_funenv_tsz] fun{a:viewt@ype} fmatrix_ptr_foreach_fun {ord:order} {m,n:nat} ( M: &fmatrix (a, m, n) , f: (&a) - void , ord: ORDER ord, m: size_t m, n: size_t n ) :<> void // end of [fmatrix_foreach_fun] fun{a:viewt@ype} fmatrix_ptr_foreach_vclo {v:view} {ord:order} {m,n:nat} ( pf: !v | M: &fmatrix (a, m, n) , f: &(!v | &a) - void , ord: ORDER ord, m: size_t m, n: size_t n ) :<> void // end of [fmatrix_foreach_vclo] (* ****** ****** *) fun fmatrix_ptr_iforeach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {ord:order} {m,n:nat} ( pf: !v | M: &fmatrix (a, m, n) , f: (!v | sizeLt m, sizeLt n, &a, !vt) - void , ord: ORDER ord, m: size_t m, n: size_t n , tsz: sizeof_t a , env: !vt ) :<> void // end of [fmatrix_iforeach_funenv_tsz] fun{a:viewt@ype} fmatrix_ptr_iforeach_fun {ord:order} {m,n:nat} ( M: &fmatrix (a, m, n), f: (sizeLt m, sizeLt n, &a) - void , ord: ORDER ord, m: size_t m, n: size_t n ) :<> void // end of [fmatrix_iforeach_fun] fun{a:viewt@ype} fmatrix_ptr_iforeach_vclo {v:view} {ord:order} {m,n:nat} ( pf: !v | M: &fmatrix (a, m, n), f: &(!v | sizeLt m, sizeLt n, &a) - void , ord: ORDER ord, m: size_t m, n: size_t n ) :<> void // end of [fmatrix_iforeach_vclo] (* ****** ****** *) (* end of [fmatrix.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linordset_randbst.sats0000664000175000017500000001002312223166162022435 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A ordered set implementation ** based on randomized binary search trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: October, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) %{# #include "libats/CATS/linordset_randbst.cats" %} // end of [%{#] (* ****** ****** *) sortdef t0p = t@ype (* ****** ****** *) absviewtype set_viewtype (a: t@ype+) stadef set = set_viewtype (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - int fun{a:t0p} compare_elt_elt (x1: a, x2: a, cmp: cmp (a)):<> int (* ****** ****** *) fun{} linordset_make_nil {a:t@ype} ():<> set (a) fun{a:t0p} linordset_make_sing (x0: a):<> set (a) // singleton set (* ****** ****** *) fun{} linordset_is_empty {a:t0p} (xs: !set a):<> bool fun{} linordset_isnot_empty {a:t0p} (xs: !set a):<> bool (* ****** ****** *) // // HX: the time complexity of this function is O(1) fun{a:t@ype} linordset_size (xs: !set a):<> size_t // // HX: the time complexity fun{a:t@ype} // of this function is O(n) where n is linordset_height (xs: !set a):<> size_t // the size of [xs] // (* ****** ****** *) fun{a:t@ype} linordset_free (xs: set (a)):<> void (* ****** ****** *) fun{a:t@ype} linordset_is_member (xs: !set a, x0: a, cmp: cmp a):<> bool fun{a:t@ype} linordset_isnot_member (xs: !set a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) // // HX: the return value [-1] means that [x0] is not found // fun{a:t0p} linordset_get_order (xs: !set a, x0: a, cmp: cmp a):<> int (* ****** ****** *) absviewtype rngobj_viewtype = ptr viewtypedef rngobj = rngobj_viewtype fun linordset_rngobj_make_drand48 ():<> rngobj = "atslib_linordset_rngobj_make_drand48" // end of [linordset_rngobj_make_drand48] fun linordset_rngobj_free (obj: rngobj):<> void = "atslib_linordset_rngobj_free" // end of [linordset_rngobj_free] (* ****** ****** *) fun{a:t0p} linordset_insert ( // O(log(|xs|)) obj: !rngobj , xs: &set (a), x0: a, cmp: cmp (a) ) :<> bool(*[x0] alreay exists in [xs]*) (* ****** ****** *) fun{a:t@ype} linordset_remove ( // O(log(|xs|)) obj: !rngobj , xs: &set (a), x0: a, cmp: cmp (a) ) :<> bool(*[x0] removed/not: true/false*) (* ****** ****** *) fun{a:t0p} linordset_ordget {d:nat} ( // O(log(|xs|)) xs: !set (a), d: int d, x0: &a? >> opt (a, b) ) :<> #[b:bool] bool (b) // true/false : found/not fun{a:t0p} linordset_ordrem {d:nat} ( // O(log(|xs|)) obj: !rngobj, xs: &set (a), d: int d, x0: &a? >> opt (a, b) ) :<> #[b:bool] bool (b) // true/false : removed/not (* ****** ****** *) (* end of [linordset_randbst.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linheap_binomial.sats0000664000175000017500000000610612223166162022216 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi *) (* Authoremail: hwxi AT cs DOT bu DOT edu *) (* Start time: November, 2011 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) absviewtype heap_viewt0ype_viewtype (a:viewt@ype+) stadef heap = heap_viewt0ype_viewtype (* ****** ****** *) sortdef vt0p = viewt@ype (* ****** ****** *) // typedef cmp (a:vt0p) = (&a, &a) - int // fun{a:vt0p} compare_elt_elt (x1: &a, x2: &a, cmp: cmp a):<> int // (* ****** ****** *) fun{} linheap_make_nil {a:vt0p} ():<> heap (a) (* ****** ****** *) fun{a:vt0p} linheap_size (hp: !heap a): size_t (* ****** ****** *) fun linheap_is_empty {a:vt0p} (hp: !heap (a)):<> bool fun linheap_isnot_empty {a:vt0p} (hp: !heap (a)):<> bool (* ****** ****** *) fun{a:vt0p} linheap_insert ( hp: &heap (a), x: a, cmp: cmp a ) :<> void // end of [linheap_insert] (* ****** ****** *) fun{a:t@ype} linheap_getmin ( hp: !heap (a), cmp: cmp a, res: &a? >> opt (a, b) ) :<> #[b:bool] bool b // end of [linheap_getmin] fun{a:vt0p} linheap_getmin_ref (hp: !heap (a), cmp: cmp a):<> ptr (* ****** ****** *) fun{a:vt0p} linheap_delmin ( hp: &heap (a), cmp: cmp a, res: &a? >> opt (a, b) ) :<> #[b:bool] bool b // end of [linheap_delmin] (* ****** ****** *) fun{a:vt0p} linheap_merge ( hp1: heap (a), hp2: heap (a), cmp: cmp a ) :<> heap (a) // end of [linheap_merge] (* ****** ****** *) fun{a:t0p} linheap_free (hp: heap (a)): void fun{a:vt0p} linheap_free_vt ( hp: !heap(a) >> opt (heap(a), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linheap_free_vt] (* ****** ****** *) (* end of [linheap_binomial.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/imsetp.sats0000664000175000017500000000704012223166162020223 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: reasoning about integer multisets // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) datasort imset = // abstract (* ****** ****** *) sta mnil : imset // for the empty multiset (* ****** ****** *) dataprop MSETEQ (imset, imset) = {xs:imset} MSETEQ (xs, xs) of () (* ****** ****** *) absprop MSIZE (imset, int) prfun msize_istot {xs:imset} (): [n:nat] MSIZE (xs, n) prfun msize_isfun {xs:imset} {n1,n2:int} (pf1: MSIZE (xs, n1), pf2: MSIZE (xs, n2)): [n1==n2] void // end of [msize_isfun] prfun msize_isnat {xs:imset} {n:int} (pf: MSIZE (xs, n)): [n>=0] void // end of [MSIZE_isnat] prfun msize_mnil (): MSIZE (mnil, 0) (* ****** ****** *) absprop MCONS (x: int, xs: imset, res: imset) prfun mcons_istot {x:int} {xs:imset} (): [res:imset] MCONS (x, xs, res) prfun mcons_isfun {x:int} {xs:imset} {res1,res2:imset} (pf1: MCONS (x, xs, res1), pf2: MCONS (x, xs, res2)): MSETEQ (res1, res2) // end of [mcons_isfun] prfun mcons_msize {x:int} {xs:imset} {res:imset} {n:int} (pf1: MCONS (x, xs, res), pf1: MSIZE (xs, n)): MSIZE (res, n+1) // end of [mcons_msize] prfun mcons_uncons {xs:imset} {n:pos} (pf: MSIZE (xs, n)): [x:int;xs1:imset] MCONS (x, xs1, xs) // end of [mcons_uncons] (* ****** ****** *) absprop MUNION ( xs1: imset, xs2: imset, res: imset ) // end of [MUNION] prfun munion_istot {xs,ys:imset} (): [zs:imset] MUNION (xs, ys, zs) // end of [munion_istot] prfun munion_isfun {xs,ys:imset} {zs1,zs2:imset} (pf1: MUNION (xs, ys, zs1), pf2: MUNION (xs, ys, zs2)): MSETEQ (zs1, zs2) // end of [munion_isfun] prfun munion_unit {xs:imset} (): MUNION (mnil, xs, xs) prfun munion_commute {xs,ys:imset} {zs:imset} (pf: MUNION (xs, ys, zs)): MUNION (ys, xs, zs) // end of [munion_commute] prfun munion_associcate {m1,m2,m3:imset} {m12,m23:imset} {m12_3,m1_23:imset} ( pf1: MUNION (m1, m2, m12) , pf2: MUNION (m2, m3, m23) , pf3: MUNION (m12, m3, m12_3) , pf4: MUNION (m1, m23, m1_23) ) : MSETEQ (m12_3, m1_23) // end of [munion_associcate] (* ****** ****** *) (* end of [imsetp.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/fundeque_fingertree.sats0000664000175000017500000000764612223166162022764 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional concatenable deque implementation based on fingertrees ** Please see the JFP paper by Hinze and Paterson on fingertrees for more ** details on this interesting data structure ** ** Contributed by ** Robbie Harwood (rharwood AT cs DOT bu DOT edu) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** ** Time: November, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // HX: indexed by deque size // abstype deque_t0ype_int_type (elt:t@ype+, n:int) stadef deque = deque_t0ype_int_type (* ****** ****** *) fun fundeque_size {a:t@ype} {n:nat} (xt: deque (a, n)):<> int (n) // end of [fundeque_size] (* ****** ****** *) fun{} fundeque_nil {a:t@ype} ():<> deque (a, 0) fun{} fundeque_is_nil {a:t@ype} {n:nat} (xt: deque (a, n)): bool (n==0) // end of [fundeque_is_nil] (* ****** ****** *) fun{a:t@ype} fundeque_cons {n:nat} (x: a, xt: deque (a, n)):<> deque (a, n+1) // end of [fingertree0_cons] fun{a:t@ype} fundeque_uncons {n:pos} (xt: deque (a, n), r: &a? >> a):<> deque (a, n-1) // end of [fundeque_uncons] (* ****** ****** *) fun{a:t@ype} fundeque_snoc {n:nat} (xt: deque (a, n), x: a):<> deque (a, n+1) // end of [fingertree0_snoc] fun{a:t@ype} fundeque_unsnoc {n:pos} (xt: deque (a, n), r: &a? >> a):<> deque (a, n-1) // end of [fundeque_unsnoc] (* ****** ****** *) fun fundeque_append {a:t@ype} {n1,n2:nat} (xt1: deque (a, n1), xt2: deque (a, n2)):<> deque (a, n1+n2) // end of [fundeque_append] (* ****** ****** *) fun{a:t@ype} fundeque_foreach_cloptr {n:nat} (xs: deque (a, n), f: !(a) - void):<> void // end of [fundeque_foreach_cloptr] fun{a:t@ype} fundeque_foreach_vcloptr {v:view} {n:nat} (pf: !v | xs: deque (a, n), f: !(!v | a) - void):<> void // end of [fundeque_foreach_vcloptr] fun{a:t@ype} fundeque_foreach_cloref {n:nat} (xs: deque (a, n), f: (a) - void):<> void // end of [fundeque_foreach_cloref] (* ****** ****** *) fun{a:t@ype} fundeque_rforeach_cloptr {n:nat} (xs: deque (a, n), f: !(a) - void):<> void // end of [fundeque_rforeach_cloptr] fun{a:t@ype} fundeque_rforeach_vcloptr {v:view} {n:nat} (pf: !v | xs: deque (a, n), f: !(!v | a) - void):<> void // end of [fundeque_rforeach_vcloptr] fun{a:t@ype} fundeque_rforeach_cloref {n:nat} (xs: deque (a, n), f: (a) - void):<> void // end of [fundeque_rforeach_cloref] (* ****** ****** *) (* end of [fundeque_fingertree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/freelst.sats0000664000175000017500000000671112223166162020372 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A simple implementation of free-lists (of memory items) ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: August, 2009 ** *) (* ****** ****** *) (* ** memory for storing a pointer to the next item *) sortdef itm = {a:viewt@ype | sizeof a >= sizeof ptr} (* ****** ****** *) abst@ype freeitm_t (a:viewt@ype, l:addr) typedef freeitm_t (a:viewt@ype) = [l:addr] freeitm_t (a, l) (* ****** ****** *) fun freeitm_nxt_get {a:itm} {l:addr} (x: &freeitm_t (a, l)):<> ptr l // x = "atslib_freeitm_nxt_get" fun freeitm_nxt_set {a:itm} {l1,l2:addr} (x: &freeitm_t (a, l1) >> freeitm_t (a, l2), p: ptr l2):<> void // x := p = "atslib_freeitm_nxt_set" (* ****** ****** *) absview freelst_v (a:viewt@ype, l:addr) prfun freelst_v_nil {a:viewt@ype} (): freelst_v (a, null) prfun freelst_v_unnil {a:viewt@ype} (pf: freelst_v (a, null)): void prfun freelst_v_cons {a:viewt@ype} {l0:addr} {l:addr} (pf1: freeitm_t (a, l) @ l0, pf2: freelst_v (a, l)): freelst_v (a, l0) // end of [extern] prfun freelst_v_uncons {a:viewt@ype} {l0:addr | l0 <> null} (pf: freelst_v (a, l0)): [l:addr] (freeitm_t (a, l) @ l0, freelst_v (a, l)) // end of [extern] (* ****** ****** *) fun freelst_cons {a:itm} {l_at,l:addr} ( pf_at: a? @ l_at, pf: !freelst_v (a, l) >> freelst_v (a, l_at) | p_at: ptr l_at, p: ptr l ) :<> void // end of [freelst_cons] fun freelst_uncons {a:itm} {l:addr | l <> null} ( pf: !freelst_v (a, l) >> freelst_v (a, l_nxt) | p: ptr l) :<> #[l_nxt:addr] (a? @ l | ptr l_nxt) // end of [freelst_uncons] (* ****** ****** *) fun{a:itm} freelst_add_bytes {l:addr} {n:nat} {l_arr:addr} ( pf: !freelst_v (a, l) >> freelst_v (a, l), pf_arr: b0ytes n @ l_arr | p: ptr l, p_arr: ptr l_arr, n: size_t n ) :<> #[l:addr] ptr l // end of [freelst_add_bytes] fun freelst_add_bytes_tsz {a:itm} {l:addr} {n:nat} {l_arr:addr} ( pf: !freelst_v (a, l) >> freelst_v (a, l), pf_arr: b0ytes n @ l_arr | p: ptr l, p_arr: ptr l_arr, n: size_t n, tsz: sizeof_t a ) :<> #[l:addr] ptr l // end of [freelst_add_bytes_tsz] (* ****** ****** *) (* end of [freelst.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/gflist_vt.sats0000664000175000017500000000554212223166162020730 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed linear lists (linear gflists) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" // for handling integer sequences (* ****** ****** *) absviewt@ype elt_vt0ype_int (a:viewt@ype, x:int) = a stadef elt = elt_vt0ype_int viewtypedef elt (a:viewt@ype) = [x:int] elt (a, x) (* // HX-2011-09-11: abst@ype elt (a:t@ype, x:int) = !a // according to the new syntax proposal *) prfun eltencode {a:viewt@ype} (x: &a >> elt (a, x)): #[x:int] void prfun eltdecode {a:viewt@ype} {x:int} (x: &elt (a, x) >> a): void (* ****** ****** *) dataviewtype gflist_vt (a:viewt@ype, ilist) = | {x:int} {xs:ilist} gflist_vt_cons (a, ilist_cons (x, xs)) of (elt (a, x), gflist_vt (a, xs)) | gflist_vt_nil (a, ilist_nil) of () // end of [gflist_vt] (* ****** ****** *) prfun list_vt_of_gflist_vt {a:viewt@ype} {xs:ilist} (xs: !gflist_vt (a, xs) >> list_vt (a, n)): #[n:nat] LENGTH (xs, n) // end of [list_of_gflist_vt] prfun gflist_vt_of_list_vt {a:viewt@ype} {n:int} (xs: !list_vt (a, n) >> gflist_vt (a, xs)): #[xs:ilist] LENGTH (xs, n) // end of [gflist_vt_of_list] (* ****** ****** *) fun{a:viewt@ype} gflist_vt_length {xs:ilist} (xs: !gflist_vt (a, xs)):<> [n:nat] (LENGTH (xs, n) | int n) // end of [gflist_vt_length] (* ****** ****** *) (* end of [gflist_vt.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/regexp.sats0000664000175000017500000000707312223166162020222 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libats/CATS/regexp.cats" %} // end of [%{#] (* ****** ****** *) absviewtype REGEXPptr (l:addr) = ptr viewtypedef REGEXPptr0 = [l:agez] REGEXPptr l viewtypedef REGEXPptr1 = [l:addr | l > null] REGEXPptr l castfn ptr_of_REGEXPptr {l:addr} (x: !REGEXPptr l): ptr l overload ptr_of with ptr_of_REGEXPptr (* ****** ****** *) praxi regexp_free_null (p: REGEXPptr null):<> void (* ****** ****** *) fun regexp_compile // implemented in C (pattern: string): REGEXPptr0 = "atslib_regexp_compile" // end of [regexp_compile] fun regexp_compile_exn (pattern: string): REGEXPptr1 (* ****** ****** *) fun regexp_free {l:agz} (p: REGEXPptr l): void = "atslib_regexp_free" // !fun // end of [regexp_free] (* ****** ****** *) fun regexp_match_string {l:agz} (re: !REGEXPptr l, str: string): bool // end of [regexp_match_string] (* ****** ****** *) // // HX: starting from a given offset // fun regexp_match_substring {l:agz} {n:int} {i,ln:nat | i + ln <= n} (re: !REGEXPptr l, str: string n, ofs: int i, len: int ln): bool = "atslib_regexp_match_substring" // end of [regexp_match_substring] (* ****** ****** *) typedef strpos (n:int) = [i,j:int | i <= j; j <= n] (int i, int j) viewtypedef strposlst (n:int) = List_vt (strpos n) fun regexp_match_string_strposlst {l:agz} {n:nat} (re: !REGEXPptr l, str: string n): strposlst (n) // end of [regexp_match_string_strposlst] fun regexp_match_substring_strposlst {l:agz} {n:int} {i,ln:nat | i + ln <= n} (re: !REGEXPptr l, str: string n, ofs: int i, len: int ln): strposlst (ln) = "atslib_regexp_match_substring_strposlst" // end of [regexp_match_substring_strposlst] (* ****** ****** *) fun regexp_split_string_list {l:agz} (re: !REGEXPptr l, str: string): List_vt (strptr1) // end of [regexp_string_split_list] fun regexp_split_substring_list {l:agz} {n:int} {i,ln:nat | i+ln <= n} ( re: !REGEXPptr l, str: string n, ofs: int i, len: int ln ) : List_vt (strptr1) // end of [regexp_string_split_list] (* ****** ****** *) abstype REGEXPref // = ref (REGEXP) castfn regexp_ref_make_ptr {l:agz} (p: REGEXPptr l):<> REGEXPref (* ****** ****** *) (* end of [regexp.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/vector.sats0000664000175000017500000001325712223166162020233 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A dynamically resizable vector implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Secptember, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/vector.cats" %} // end of [%{#] (* ****** ****** *) absview vector_v ( a:viewt@ype+, m: int, n: int, l:addr ) // end of [vector_v] prfun vector_v_encode {a:viewt@ype} {n1,n2:int} {l:addr} {ofs:int} ( pfmul: MUL (n1, sizeof a, ofs) , pfarr1: array_v (a, n1, l), pfarr2: array_v (a?, n2, l+ofs) ) : vector_v (a, n1+n2, n1, l) // end of [vector_v_encode] prfun vector_v_decode {a:viewt@ype} {m,n:int} {l:addr} {ofs:int} ( pfmul: MUL (n, sizeof a, ofs), pfarr: vector_v (a, m, n, l) ): (array_v (a, n, l), array_v (a?, m-n, l+ofs)) // end of [vector_v_decode] (* ****** ****** *) viewtypedef VSHELL ( m:int, n:int, l:addr ) = @{ m= size_t (m) , n= size_t (n) , ptr= ptr (l) , vfree= free_gc_v l } // end of [VECTOR0] viewtypedef VSHELL0 = VSHELL (0, 0, null) (* ****** ****** *) absviewt@ype VECTOR // (elt, capacity, size) (a:viewt@ype+, m:int, n:int) = VSHELL (m, n, null) // end of [VECTOR] viewtypedef VECTOR1 (a:viewt@ype, n:int) = [m:int] VECTOR (a, m, n) prfun VECTOR_encode {a:viewt@ype} {m,n:int} {l:addr} (pf: vector_v (a, m, n, l) | V: &VSHELL (m, n, l) >> VECTOR (a, m, n)):<> void // end of [VECTOR_encode] prfun VECTOR_decode {a:viewt@ype} {m,n:int} {l:addr} (V: &VECTOR (a, m, n) >> VSHELL (m, n, l)):<> #[l:addr] vector_v (a, m, n, l) // end of [VECTOR_decode] (* ****** ****** *) fun vector_cap {a:viewt@ype} {m,n:int} (V: &VECTOR (a, m, n)):<> size_t m fun vector_size {a:viewt@ype} {m,n:int} (V: &VECTOR (a, m, n)):<> size_t n (* ****** ****** *) fun{a:viewt@ype} vector_initialize {m:nat} ( V: &VSHELL0? >> VECTOR (a, m, 0), m: size_t m ) :<> void // end of [vector_initialize] (* ****** ****** *) fun vector_clear {a:t@ype} {m,n:int} (V: &VECTOR (a, m, n) >> VECTOR (a, m, 0)):<> void // end of [vector_clear] fun{a:viewt@ype} vector_clear_fun {m,n:int} ( V: &VECTOR (a, m, n) >> VECTOR (a, m, 0), f: (&a >> a?) - void ) :<> void // end of [vector_clear_fun] (* ****** ****** *) fun{a:t@ype} vector_uninitialize {m,n:int} (V: &VECTOR (a, m, n) >> VSHELL0?):<> void fun{a:viewt@ype} vector_uninitialize_vt {m:int} (V: &VECTOR (a, m, 0) >> VSHELL0?):<> void (* ****** ****** *) fun{a:t@ype} vector_get_elt_at {m,n:int} (V: &VECTOR (a, m, n), i: sizeLt n):<> a // end of [vector_get_elt_at] fun{a:t@ype} vector_set_elt_at {m,n:int} (V: &VECTOR (a, m, n), i: sizeLt n, x: a):<> void // end of [vector_set_elt_at] (* ****** ****** *) fun{a:viewt@ype} vector_append {m,n:int | n < m} (V: &VECTOR (a, m, n) >> VECTOR (a, m, n+1), x: a):<> void // end of [vector_append] fun{a:viewt@ype} vector_prepend {m,n:int | n < m} (V: &VECTOR (a, m, n) >> VECTOR (a, m, n+1), x: a):<> void // end of [vector_prepend] (* ****** ****** *) fun{a:viewt@ype} vector_insert_at {m,n:int | n < m} {i:nat | i <= n} (V: &VECTOR (a, m, n) >> VECTOR (a, m, n+1), i: size_t i, x: &a >> a?!):<> void // end of [vector_insert] fun{a:viewt@ype} vector_remove_at {m,n:int} {i:nat | i < n} (V: &VECTOR (a, m, n) >> VECTOR (a, m, n-1), i: size_t i, x: &a? >> a ):<> void // end of [vector_remove] (* ****** ****** *) fun{a:t@ype} vector_resize {m,n:int} {m1:int | n <= m1} (V: &VECTOR (a, m, n) >> VECTOR (a, m1, n), m1: size_t m1):<> void // end of [vector_resize] (* ****** ****** *) fun vector_foreach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {m,n:int} ( pf: !v | V: &VECTOR (a, m, n) , f: (!v | &a, !vt) -<> void, tsz: sizeof_t a, env: !vt ) :<> void // end of [vector_foreach_funenv_tsz] fun{a:viewt@ype} vector_foreach_vclo {v:view} {m,n:int} (pf: !v | V: &VECTOR (a, m, n), f: &(!v | &a) - void) :<> void // end of [vector_foreach_vclo] (* ****** ****** *) fun vector_iforeach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {m,n:int} ( pf: !v | V: &VECTOR (a, m, n) , f: (!v | sizeLt n, &a, !vt) -<> void, tsz: sizeof_t a, env: !vt ) :<> void // end of [vector_iforeach_funenv_tsz] fun{a:viewt@ype} vector_iforeach_vclo {v:view} {m,n:int} (pf: !v | V: &VECTOR (a, m, n), f: &(!v | sizeLt n, &a) - void) :<> void // end of [vector_iforeach_vclo] (* ****** ****** *) (* end of [vector.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/gftree.sats0000664000175000017500000000404012223166162020173 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed trees // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/itreep.sats" // for handling integer sequences (* ****** ****** *) abst@ype elt (a:t@ype, x:int) = a (* ****** ****** *) datatype gftree (a:t@ype+, itree) = | {x:int} {tl,tr:itree} gftree_cons ( a, itree_cons (x, tl, tr) ) of (elt (a, x), gftree (a, tl), gftree (a, tr)) | gftree_nil (a, itree_nil) of () // end of [gftree] (* ****** ****** *) (* end of [gftree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/genarrays.sats0000664000175000017500000007747312223166162020736 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Various kinds of (generic) arrays ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Start Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/genarrays.cats" %} // end of [%{#] (* ****** ****** *) sortdef inc = {i: int | i > 0} // for leading dimensions (* ****** ****** *) // general vector // elt, size, delta absviewt@ype GEVEC (a:viewt@ype+, n:int, d:int) viewdef GEVEC_v (a:viewt@ype, n:int, d:int, l:addr) = GEVEC (a, n, d) @ l // end of [GEVEC_v] (* ****** ****** *) prfun GEVEC_v_nil {a:viewt@ype} {d:inc} {l:addr} (): GEVEC_v (a, 0, d, l) // end of [GEVEC_v_nil] prfun GEVEC_v_unnil {a:viewt@ype} {d:inc} {l:addr} (pf: GEVEC_v (a, 0, d, l)): void // end of [GEVEC_v_unnil] prfun GEVEC_v_cons {a:viewt@ype} {n:pos} {d:inc} {l:addr} {ofs:int} ( pf_mul: MUL (d, sizeof a, ofs), pf_at: a @ l, pf_vec: GEVEC_v (a, n-1, d, l+ofs) ) : GEVEC_v (a, n, d, l) // end of [GEVEC_v_cons] prfun GEVEC_v_uncons {a:viewt@ype} {n:pos} {d:inc} {l:addr} {ofs:int} ( pf_mul: MUL (d, sizeof a, ofs), pf_vec: GEVEC_v (a, n, d, l) ) : ( a @ l, GEVEC_v (a, n-1, d, l+ofs) ) // end of [GEVEC_v_uncons] (* ****** ****** *) prfun array_v_of_GEVEC_v {a:viewt@ype} {n:nat} {l:addr} (pf: GEVEC_v (a, n, 1, l)): array_v (a, n, l) // end [array_v_of_GEVEC_v] prfun GEVEC_v_of_array_v {a:viewt@ype} {n:nat} {l:addr} (pf: array_v (a, n, l)): GEVEC_v (a, n, 1, l) // end [array_v_of_GEVEC_v] (* ****** ****** *) fun{a:viewt@ype} GEVEC_ptr_takeout {n:nat} {d:inc} {l0:addr} ( pf: GEVEC_v (a, n, d, l0) | p_vec: ptr l0, d: size_t d, i: sizeLt n ) :<> [l:addr] ( a @ l , a @ l - GEVEC_v (a, n, d, l0) | ptr l ) // end of [GEVEC_ptr_takeout] (* ****** ****** *) stadef tszeq (a1:viewt@ype, a2:viewt@ype) = (sizeof a1 == sizeof a2) // end of [tszeq] fun{a1:viewt@ype} GEVEC_ptr_split {n,i:nat | i <= n} {d:inc} {l0:addr} ( pf: GEVEC_v (a1, n, d, l0) | p_vec: ptr l0, d: size_t d, i: size_t i ) :<> [l:addr] ( GEVEC_v (a1, i, d, l0) , GEVEC_v (a1, n-i, d, l) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] GEVEC_v (a2, i, d, l0), GEVEC_v (a2, n-i, d, l) ) - GEVEC_v (a2, n, d, l0) | ptr l ) // end of [GEVEC_ptr_split] (* ****** ****** *) fun{a:t@ype} GEVEC_ptr_get_elt_at {n:nat} {d:inc} (V: &GEVEC (a, n, d), d: size_t d, i: sizeLt n):<> a // end of [GEVEC_ptr_get_elt_at] fun{a:t@ype} GEVEC_ptr_set_elt_at {n:nat} {d:inc} (V: &GEVEC (a, n, d), d: size_t d, i: sizeLt n, x: a):<> void // end of [GEVEC_ptr_set_elt_at] (* ****** ****** *) fun{a:t@ype} GEVEC_ptr_initialize_elt {m:nat} {d:inc} ( X: &GEVEC (a?, m, d) >> GEVEC (a, m, d), m: size_t m, inc: size_t d, alpha: a ) :<> void // end of [GEVEC_ptr_initialize_elt] (* ****** ****** *) fun{a:t@ype} GEVEC_ptr_copy {m:nat} {d1,d2:inc} ( X1: &GEVEC (a, m, d1), X2: &GEVEC (a?, m, d2) >> GEVEC (a, m, d2) , m: size_t m, d1: size_t d1, d2: size_t d2 ) :<> void // end of [GEVEC_ptr_copy] (* ****** ****** *) fun GEVEC_ptr_foreach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {n:nat} {d:inc} ( pf: !v | base: &GEVEC (a, n, d) , f: (!v | &a, !vt) -<> void, vsz: size_t n, inc: size_t d, tsz: sizeof_t a , env: !vt ) :<> void = "atslib_GEVEC_ptr_foreach_funenv_tsz" // end of [GEVEC_ptr_foreach_funenv_tsz] fun{a:viewt@ype} GEVEC_ptr_foreach_fun {n:nat} {d:inc} ( base: &GEVEC (a, n, d) , f: (&a) - void, vsz: size_t n, inc: size_t d ) :<> void // end of [GEVEC_ptr_foreach_fun] fun{a:viewt@ype} GEVEC_ptr_foreach_vclo {v:view} {n:nat} {d:inc} ( pf: !v | base: &GEVEC (a, n, d) , f: &(!v | &a) - void, vsz: size_t n, inc: size_t d ) :<> void // end of [GEVEC_ptr_foreach_vclo] (* ****** ****** *) fun GEVEC_ptr_iforeach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {n:nat} {d:inc} ( pf: !v | base: &GEVEC (a, n, d) , f: (!v | sizeLt n, &a, !vt) -<> void , vsz: size_t n , inc: size_t d , tsz: sizeof_t a , env: !vt ) :<> void = "atslib_GEVEC_ptr_iforeach_funenv_tsz" // end of [GEVEC_ptr_iforeach_funenv_tsz] fun{a:viewt@ype} GEVEC_ptr_iforeach_fun {n:nat} {d:inc} ( base: &GEVEC (a, n, d) , f: (sizeLt n, &a) - void, vsz: size_t n, inc: size_t d ) :<> void // end of [fun] fun GEVEC_ptr_iforeach_cloenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {n:nat} {d:inc} ( pf: !v | base: &GEVEC (a, n, d) , f: &(!v | sizeLt n, &a, !vt) - void , vsz: size_t n , inc: size_t d , tsz: sizeof_t a , env: !vt ) :<> void = "atslib_GEVEC_ptr_iforeach_cloenv_tsz" // end of [fun] fun{a:viewt@ype} GEVEC_ptr_iforeach_vclo {v:view} {n:nat} {d:inc} ( pf: !v | base: &GEVEC (a, n, d) , f: &(!v | sizeLt n, &a) - void, vsz: size_t n, inc: size_t d ) :<> void // end of [GEVEC_ptr_iforeach_vclo] (* ****** ****** *) datasort order = | row | col // row major / column major // end of [order] datatype ORDER (order) = | ORDERrow (row) of () | ORDERcol (col) of () // end of [ORDER] (* ****** ****** *) (* datasort uplo = | upper | lower // upper right / lower left // end of [uplo] *) sortdef uplo = int stadef upper = 1 and lower = 0 datatype UPLO (uplo) = | UPLOupper (upper) of () | UPLOlower (lower) of () // end of [UPLO] (* ****** ****** *) datasort diag = unit | nonunit // unit / non-unit datatype DIAG (diag) = DIAGunit (unit()) | DIAGnonunit (nonunit()) (* ****** ****** *) datasort transpose = TPN | TPT | TPC (* dataprop transpose_NT (transpose) = | TRANSPOSE_NT_N (TPN) of () | TRANSPOSE_NT_T (TPT) of () // end of [transpose_NT] dataprop transpose_NC (transpose) = | TRANSPOSE_NC_N (TPN) of () | TRANSPOSE_NC_C (TPC) of () // end of [transpose_NC] *) datatype TRANSPOSE (transpose) = | TRANSPOSE_N (TPN) of () | TRANSPOSE_T (TPT) of () | TRANSPOSE_C (TPC) of () // end of [TRANSPOSE] (* ****** ****** *) (* ** capturing the relation between transpose and order *) dataprop tranord_p (order, order) = | TRANORDrowcol (row, col) | TRANORDcolrow (col, row) // end of [tranord_p] (* // // capturing the relation between transpose and uplo // dataprop tranuplo_p (uplo, uplo) = | TRANUPLOupperlower (upper, lower) | TRANUPLOlowerupper (lower, upper) // end of [transuplo_p] *) (* ****** ****** *) (* ** capturing the relation between transpose and dimensions *) dataprop trandim_p ( transpose , int // row , int // col , int // new row , int // new col ) = | {m,n:nat} TRANDIM_N (TPN, m, n, m, n) of () | {m,n:nat} TRANDIM_T (TPT, m, n, n, m) of () | {m,n:nat} TRANDIM_C (TPC, m, n, n, m) of () (* | {m,n:nat} TRANDIM_AC (AC, m, n, m, n) of () *) // end of [trandim_p] (* ****** ****** *) datasort side = left | right datatype SIDE (side) = SIDEleft (left) | SIDEright (right) (* ****** ****** *) (* ** capturing the relation between side and row/col *) dataprop sidedim_p ( side, int(*row*), int(*col*), int(*row/col*) ) = | {m,n:nat} SIDEDIM_L (left, m, n, m) | {m,n:nat} SIDEDIM_R (right, m, n, n) // end of [sidedim_p] (* ****** ****** *) // // GEneral MATrix representation // // elt, row, col, ord, ld absviewt@ype GEMAT (a:viewt@ype+, m:int, n:int, ord:order, ld:int) // end of [GEMAT] viewdef GEMAT_v (a:viewt@ype, m:int, n:int, ord: order, ld:int, l:addr) = GEMAT (a, m, n, ord, ld) @ l // end of [GEMAT_v] (* ****** ****** *) prfun GEMAT_v_trans // HX: yes, [ld:int] is fine {a:viewt@ype} {ord1:order} {m,n:nat} {ld:int} {l:addr} ( pf_mat: !GEMAT_v (a, m, n, ord1, ld, l) >> GEMAT_v (a, n, m, ord2, ld, l) ) :<> #[ord2:order] tranord_p (ord1, ord2) // end of [GEMAT_v_trans] (* ****** ****** *) dataprop MATVECINC (order, order, int, int) = | {ld:inc} MATVECINCrowrow (row, row, ld, 1) | {ld:inc} MATVECINCrowcol (row, col, ld, ld) | {ld:inc} MATVECINCcolrow (col, row, ld, ld) | {ld:inc} MATVECINCcolcol (col, col, ld, 1) // end of [MATVECINC] // implemented in [genarrays.dats] fun MATVECINC_get {ord1,ord2:order} {ld:int} {d:inc} ( pf: MATVECINC (ord1, ord2, ld, d) | x1: ORDER ord1, x2: ORDER ord2, ld: size_t ld ) :<> size_t d // end of [MATVECINC_get] (* ****** ****** *) prfun GEMAT_v_nil_row {a:viewt@ype} {ord:order} {n:nat} {ld:inc} {l:addr} () : GEMAT_v (a, 0, n, ord, ld, l) // end of [GEMAT_v_nil_row] prfun GEMAT_v_unnil_row {a:viewt@ype} {ord:order} {n:nat} {ld:inc} {l:addr} (pf: GEMAT_v (a, 0, n, ord, ld, l)): void // end of [GEMAT_v_unnil_row] prfun GEMAT_v_nil_col {a:viewt@ype} {ord:order} {m:nat} {ld:inc} {l:addr} () : GEMAT_v (a, m, 0, ord, ld, l) // end of [GEMAT_v_nil_col] prfun GEMAT_v_unnil_col {a:viewt@ype} {ord:order} {m:nat} {ld:inc} {l:addr} (pf: GEMAT_v (a, m, 0, ord, ld, l)): void // end of [GEMAT_v_unnil_col] (* ****** ****** *) prfun GEMAT_v_uncons_row {a:viewt@ype} {ord:order} {m:pos;n:nat} {ld:inc} {l:addr} (pf: GEMAT_v (a, m, n, ord, ld, l)) : [d:inc] ( MATVECINC (row, ord, ld, d) , GEVEC_v (a, n, d, l) , GEVEC_v (a, n, d, l) - GEMAT_v (a, m, n, ord, ld, l) ) // end of [GEMAT_uncons_row] prfun GEMAT_v_uncons_col {a:viewt@ype} {ord:order} {m:nat;n:pos} {ld:inc} {l:addr} (pf: GEMAT_v (a, m, n, ord, ld, l)) : [d:inc] ( MATVECINC (col, ord, ld, d) , GEVEC_v (a, m, d, l) , GEVEC_v (a, m, d, l) - GEMAT_v (a, m, n, ord, ld, l) ) // end of [GEMAT_v_uncons_col] (* ****** ****** *) prfun GEVEC_v_of_GEMAT_v_row {a1:viewt@ype} {ord:order} {n:nat} {ld:inc} {l:addr} ( pf: GEMAT_v (a1, 1, n, ord, ld, l) ) :<> [d:inc] ( MATVECINC (row, ord, ld, d) , GEVEC_v (a1, n, d, l) , {a2:viewt@ype | a1 \tszeq a2} // [fpf: for unsplitting] GEVEC_v (a2, n, d, l) - GEMAT_v (a2, 1, n, ord, ld, l) ) // end of [GEVEC_v_of_GEMAT_v_row] prfun GEVEC_v_of_GEMAT_v_col {a1:viewt@ype} {ord:order} {m:nat} {ld:inc} {l:addr} ( pf: GEMAT_v (a1, m, 1, ord, ld, l) ) :<> [d:inc] ( MATVECINC (col, ord, ld, d) , GEVEC_v (a1, m, d, l) , {a2:viewt@ype | a1 \tszeq a2} // [fpf: for unsplitting] GEVEC_v (a2, m, d, l) - GEMAT_v (a2, m, 1, ord, ld, l) ) // end of [GEVEC_v_of_GEMAT_v_col] (* ****** ****** *) fun{a:viewt@ype} GEMAT_ptr_takeout {ord:order} {m,n:nat} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a, m, n, ord, ld, l0) | ord: ORDER ord , p_mat: ptr l0 , ld: size_t ld, i: sizeLt m, j: sizeLt n ) :<> [l:addr] ( a @ l , a @ l - GEMAT_v (a, m, n, ord, ld, l0) | ptr l ) // end of [GEMAT_ptr_takeout] (* ****** ****** *) fun{a:t@ype} GEMAT_ptr_get_elt_at {ord:order} {m,n:nat} {ld:inc} ( ord: ORDER ord , A: &GEMAT (a, m, n, ord, ld) , ld: size_t ld, i: sizeLt m, j: sizeLt n ) :<> a // end of [GEMAT_ptr_get_elt_at] fun{a:t@ype} GEMAT_ptr_set_elt_at {ord:order} {m,n:nat} {ld:inc} ( ord: ORDER ord , A: &GEMAT (a, m, n, ord, ld) , ld: size_t ld, i: sizeLt m, j: sizeLt n , x: a ) :<> void // end of [GEMAT_ptr_set_elt_at] (* ****** ****** *) (* ** HX: this is likely to be slightly more efficient ** than GEMAT_ptr_split2x1 *) fun{a:viewt@ype} GEMAT_ptr_tail_row {ord:order} {m:pos;n:nat} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a, m, n, ord, ld, l0) | ord: ORDER ord , p_mat: ptr l0 , ld: size_t ld ) :<> [l:addr] ( GEMAT_v (a, m-1, n, ord, ld, l) , GEMAT_v (a, m-1, n, ord, ld, l) - GEMAT_v (a, m, n, ord, ld, l0) | ptr l ) // end of [GEMAT_ptr_tail_row] (* ** HX: this is likely to be slightly more efficient than GEMAT_ptr_split1x2 *) fun{a:viewt@ype} GEMAT_ptr_tail_col {ord:order} {m:nat;n:pos} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a, m, n, ord, ld, l0) | ord: ORDER ord , p_mat: ptr l0 , ld: size_t ld ) :<> [l:addr] ( GEMAT_v (a, m, n-1, ord, ld, l) , GEMAT_v (a, m, n-1, ord, ld, l) - GEMAT_v (a, m, n, ord, ld, l0) | ptr l ) // end of [GEMAT_ptr_tail_col] (* ****** ****** *) viewtypedef GEMAT_ptr_split1x2_res_t ( a1:viewt@ype, m:int, n:int, j:int, ord:order, ld:int, l0:addr ) = [l1,l2:addr] @( GEMAT_v (a1, m, j, ord, ld, l1) , GEMAT_v (a1, m, n-j, ord, ld, l2) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] GEMAT_v (a2, m, j, ord, ld, l1), GEMAT_v (a2, m, n-j, ord, ld, l2) ) - GEMAT_v (a2, m, n, ord, ld, l0) | ptr l1 // l1 should equal l0 , ptr l2 ) // end of [GEMAT_ptr_split1x2_res_t] fun{a1:viewt@ype} GEMAT_ptr_split1x2 {ord:order} {m,n,j:nat | j <= n} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, j: size_t j ) :<> GEMAT_ptr_split1x2_res_t (a1, m, n, j, ord, ld, l0) // end of [GEMAT_ptr_split1x2] (* ****** ****** *) viewtypedef GEMAT_ptr_split2x1_res_t ( a1:viewt@ype, m:int, n:int, i:int, ord:order, ld:int, l0:addr ) = [l1,l2:addr] @( GEMAT_v (a1, i, n, ord, ld, l1) , GEMAT_v (a1, m-i, n, ord, ld, l2) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] GEMAT_v (a2, i, n, ord, ld, l1) , GEMAT_v (a2, m-i, n, ord, ld, l2) ) - GEMAT_v (a2, m, n, ord, ld, l0) | ptr l1 // l1 should equal l0 , ptr l2 ) // end of [GEMAT_ptr_split2x1_res_t] fun{a1:viewt@ype} GEMAT_ptr_split2x1 {ord:order} {m,n,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, i: size_t i ) :<> GEMAT_ptr_split2x1_res_t (a1, m, n, i, ord, ld, l0) // end of [GEMAT_ptr_split2x1] (* ****** ****** *) viewtypedef GEMAT_ptr_split2x2_res_t ( a1:viewt@ype, m:int, n:int, i:int, j:int, ord:order, ld:int, l0:addr ) = [l11,l12,l21,l22:addr] @( GEMAT_v (a1, i, j, ord, ld, l11) , GEMAT_v (a1, i, n-j, ord, ld, l12) , GEMAT_v (a1, m-i, j, ord, ld, l21) , GEMAT_v (a1, m-i, n-j, ord, ld, l22) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] GEMAT_v (a2, i, j, ord, ld, l11) , GEMAT_v (a2, i, n-j, ord, ld, l12) , GEMAT_v (a2, m-i, j, ord, ld, l21) , GEMAT_v (a2, m-i, n-j, ord, ld, l22) ) - GEMAT_v (a2, m, n, ord, ld, l0) | ptr l11 // l11 should equal l0 , ptr l12 , ptr l21 , ptr l22 ) // end of [GEMAT_ptr_split2x2_res_t] fun{a1:viewt@ype} GEMAT_ptr_split2x2 {ord:order} {m,n,i,j:nat | i <= m; j <= n} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, i: size_t i, j: size_t j ) :<> GEMAT_ptr_split2x2_res_t (a1, m, n, i, j, ord, ld, l0) // end of [GEMAT_ptr_split2x2] (* ****** ****** *) fun{a:t@ype} GEMAT_row_ptr_allocfree {m,n:nat} (m: size_t m, n: size_t n) : [l:addr] ( GEMAT (a?, m, n, row, n) @ l | ptr l , (GEMAT (a?, m, n, row, n) @ l | ptr l) - void ) // end of [GEMAT_row_ptr_allocfree] fun{a:t@ype} GEMAT_col_ptr_allocfree {m,n:nat} (m: size_t m, n: size_t n) : [l:addr] ( GEMAT (a?, m, n, col, m) @ l | ptr l , (GEMAT (a?, m, n, col, m) @ l | ptr l) - void ) // end of [GEMAT_col_ptr_allocfree] (* ****** ****** *) fun{a:t@ype} GEMAT_ptr_initialize_elt {ord:order} {m,n:nat} {ld:inc} ( ord: ORDER ord , X: &GEMAT (a?, m, n, ord, ld) >> GEMAT (a, m, n, ord, ld) , m: size_t m, n: size_t n, ld: size_t ld , alpha: a ) :<> void // end of [GEMAT_ptr_initialize_elt] // // HX: based on [GEMAT_ptr_iforeach_fun] // fun{a:t@ype} GEMAT_ptr_initialize_fun {ord:order} {m,n:nat} {ld:inc} ( ord: ORDER ord , M: &GEMAT (a?, m, n, ord, ld) >> GEMAT (a, m, n, ord, ld) , m: size_t m, n: size_t n, ld: size_t ld , f: (sizeLt m, sizeLt n, &(a?) >> a) -<> void ) :<> void // end of [GEMAT_ptr_initialize_fun] // // HX: based on [GEMAT_ptr_iforeach_vclo] // fun{a:t@ype} GEMAT_ptr_initialize_vclo {v:view} {ord:order} {m,n:nat} {ld:inc} ( pf: !v | ord: ORDER ord , M: &GEMAT (a?, m, n, ord, ld) >> GEMAT (a, m, n, ord, ld) , m: size_t m, n: size_t n, ld: size_t ld , f: &(!v | sizeLt m, sizeLt n, &(a?) >> a) - void ) :<> void // end of [GEMAT_ptr_initialize_vclo] (* ****** ****** *) (* ** M2 <- M1 *) fun{a:t@ype} GEMAT_ptr_copy {ord:order} {m,n:nat} {ld1,ld2:inc} ( ord: ORDER ord , M1: &GEMAT (a, m, n, ord, ld1) , M2: &GEMAT (a?, m, n, ord, ld2) >> GEMAT (a, m, n, ord, ld2) , m: size_t m, n: size_t n, ld1: size_t ld1, ld2: size_t ld2 ) :<> void // end of [GEMAT_ptr_copy] fun GEMAT_ptr_copy_tsz {a:t@ype} {ord:order} {m,n:nat} {ld1,ld2:inc} ( ord: ORDER ord , M1: &GEMAT (a, m, n, ord, ld1) , M2: &GEMAT (a?, m, n, ord, ld2) >> GEMAT (a, m, n, ord, ld2) , m: size_t m, n: size_t n, ld1: size_t ld1, ld2: size_t ld2, tsz: sizeof_t a ) :<> void // end of [GEMAT_ptr_copy_tsz] (* ****** ****** *) fun GEMAT_ptr_foreach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {ord1,ord2:order} {m,n:nat} {ld:inc} ( pf: !v | ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: (!v | &a, !vt) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld , tsz: sizeof_t a , env: !vt ) :<> void // end of [GEMAT_ptr_foreach_funenv_tsz] fun{a:viewt@ype} GEMAT_ptr_foreach_fun {ord1,ord2:order} {m,n:nat} {ld:inc} ( ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: (&a) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld ) :<> void // end of [GEMAT_ptr_foreach_fun] fun{a:viewt@ype} GEMAT_ptr_foreach_vclo {v:view} {ord1,ord2:order} {m,n:nat} {ld:inc} ( pf: !v | ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: &(!v | &a) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld ) :<> void // end of [GEMAT_ptr_foreach_vclo] (* ****** ****** *) fun GEMAT_ptr_iforeach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {ord1,ord2:order} {m,n:nat} {ld:inc} ( pf: !v | ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: (!v | sizeLt m, sizeLt n, &a, !vt) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld , tsz: sizeof_t a , env: !vt ) :<> void // end of [GEMAT_ptr_iforeach_funenv_tsz] fun{a:viewt@ype} GEMAT_ptr_iforeach_fun {ord1,ord2:order} {m,n:nat} {ld:inc} ( ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: (sizeLt m, sizeLt n, &a) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld ) :<> void // end of [GEMAT_ptr_iforeach_fun] fun{a:viewt@ype} GEMAT_ptr_iforeach_vclo {v:view} {ord1,ord2:order} {m,n:nat} {ld:inc} ( pf: !v | ord1: ORDER ord1 , M: &GEMAT (a, m, n, ord1, ld) , f: &(!v | sizeLt m, sizeLt n, &a) - void , ord2: ORDER ord2 , m: size_t m, n: size_t n, ld: size_t ld ) :<> void // end of [GEMAT_ptr_iforeach_vclo] (* ****** ****** *) dataprop realtyp_p (a:t@ype) = | REALTYPfloat (float) of () | REALTYPdouble (double) of () // end of [TYPE_IS_REAL] (* ****** ****** *) // // TRiangular MATrix representation (part of GEMAT) // // elt, row/col, ord, ul absviewt@ype TRMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, dg: diag, ld: int) // end of [TRMAT] viewdef TRMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, dg: diag, ld: int, l:addr) = TRMAT (a, n, ord, ul, dg, ld) @ l // end of [TRMAT_v] (* ****** ****** *) prfun TRMAT_v_nil {a:viewt@ype} {ord:order} {ul:uplo} {dg:diag} {ld:inc} {l:addr} (): TRMAT_v (a, 0, ord, ul, dg, ld, l) // end of [TRMAT_v_nil] prfun TRMAT_v_unnil {a:viewt@ype} {ord:order} {ul:uplo} {dg:diag} {ld:inc} {l:addr} (pf: TRMAT_v (a, 0, ord, ul, dg, ld, l)): void // end of [TRMAT_v_unnil] (* ****** ****** *) prfun TRMAT1x1_v_takeout_unit {a1:viewt@ype} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf: TRMAT_v (a1, 1, ord, ul, unit(), ld, l) ) : ( {a2:viewt@ype | a1 \tszeq a2} () - TRMAT_v (a2, 1, ord, ul, unit(), ld, l) ) // end of [TRMAT1x1_v_takeout_unit] prfun TRMAT1x1_v_takeout_nonunit {a1:viewt@ype} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf: TRMAT_v (a1, 1, ord, ul, nonunit(), ld, l) ) : ( a1 @ l , {a2:viewt@ype | a1 \tszeq a2} a2 @ l - TRMAT_v (a2, 1, ord, ul, nonunit(), ld, l) ) // end of [TRMAT1x1_v_takeout_nonunit] (* ****** ****** *) prfun TRMAT_v_trans {a:viewt@ype} {ord1:order} {ul:uplo} {dg:diag} {m:nat} {ld:inc} {l:addr} ( pf_mat: !TRMAT_v (a, m, ord1, ul, dg, ld, l) >> TRMAT_v (a, m, ord2, 1-ul, dg, ld, l) ) :<> #[ord2:order] tranord_p (ord1, ord2) // end of [TRMAT_v_trans] prfun TRMAT_v_of_GEMAT_v {a:viewt@ype} {ord:order} {ul:uplo} {dg:diag} {n:nat} {ld:inc} {l:addr} ( pf: GEMAT_v (a, n, n, ord, ld, l), ul: UPLO ul, dg: DIAG dg ) :<> ( TRMAT_v (a, n, ord, ul, dg, ld, l) , TRMAT_v (a, n, ord, ul, dg, ld, l) - GEMAT_v (a, n, n, ord, ld, l) ) // end of [TRMAT_v_of_GEMAT_v] (* ****** ****** *) // UN: upper non-unit fun{a:t@ype} TRMAT_UN_ptr_get_elt_at {ord:order} {m,i,j:nat | i <= j; j < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, upper, nonunit(), ld) , ld: size_t ld, i: size_t i, j: size_t j ) :<> a // end of [TRMAT_UN_ptr_get_elt_at] fun{a:t@ype} TRMAT_UN_ptr_set_elt_at {ord:order} {m,i,j:nat | i <= j; j < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, upper, nonunit(), ld) , ld: size_t ld, i: size_t i, j: size_t j , x: a ) :<> void // end of [TRMAT_UN_ptr_set_elt_at] (* ****** ****** *) // UU: upper unit fun{a:t@ype} TRMAT_UU_ptr_get_elt_at {ord:order} {m,i,j:nat | i < j; j < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, upper, unit(), ld) , ld: size_t ld, i: size_t i, j: size_t j ) :<> a // end of [TRMAT_UU_ptr_get_elt_at] fun{a:t@ype} TRMAT_UU_ptr_set_elt_at {ord:order} {m,i,j:nat | i < j; j < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, upper, unit(), ld) , ld: size_t ld, i: size_t i, j: size_t j , x: a ) :<> void // end of [TRMAT_UU_ptr_set_elt_at] (* ****** ****** *) // LN: lower non-unit fun{a:t@ype} TRMAT_LN_ptr_get_elt_at {ord:order} {m,i,j:nat | j <= i; i < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, lower, nonunit(), ld) , ld: size_t ld, i: size_t i, j: size_t j ) :<> a // end of [TRMAT_LN_ptr_get_elt_at] fun{a:t@ype} TRMAT_LN_ptr_set_elt_at {ord:order} {m,i,j:nat | j <= i; i < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, lower, nonunit(), ld) , ld: size_t ld, i: size_t i, j: size_t j , x: a ) :<> void // end of [TRMAT_LN_ptr_set_elt_at] (* ****** ****** *) // LU: lower unit fun{a:t@ype} TRMAT_LU_ptr_get_elt_at {ord:order} {m,i,j:nat | j < i; i < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, lower, unit(), ld) , ld: size_t ld, i: size_t i, j: size_t j ) :<> a // end of [TRMAT_LU_ptr_get_elt_at] fun{a:t@ype} TRMAT_LU_ptr_set_elt_at {ord:order} {m,i,j:nat | j < i; i < m} {ld:inc} ( ord: ORDER ord , A: &TRMAT (a, m, ord, lower, unit(), ld) , ld: size_t ld, i: size_t i, j: size_t j , x: a ) :<> void // end of [TRMAT_LU_ptr_set_elt_at] (* ****** ****** *) viewtypedef TRMAT_U_ptr_split2x2_res_t ( a1:viewt@ype, m:int, i:int, ord:order, dg:diag, ld:int, l0:addr ) = [lu,lo,ll:addr] @( TRMAT_v (a1, i, ord, upper, dg, ld, lu) , GEMAT_v (a1, i, m-i, ord, ld, lo) , TRMAT_v (a1, m-i, ord, upper, dg, ld, ll) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] TRMAT_v (a2, i, ord, upper, dg, ld, lu) , GEMAT_v (a2, i, m-i, ord, ld, lo) , TRMAT_v (a2, m-i, ord, upper, dg, ld, ll) ) - TRMAT_v (a2, m, ord, upper, dg, ld, l0) | ptr lu // l11 should equal l0 , ptr lo , ptr ll ) // end of [TRMAT_U_ptr_split2x2_res_t] fun{a1:viewt@ype} TRMAT_U_ptr_split2x2 {ord:order} {dg:diag} {m,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: TRMAT_v (a1, m, ord, upper, dg, ld, l0) | ord: ORDER ord, A: ptr l0, ld: size_t ld, i: size_t i ) :<> TRMAT_U_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [TRMAT_U_ptr_split2x2] viewtypedef TRMAT_L_ptr_split2x2_res_t ( a1:viewt@ype, m:int, i:int, ord:order, dg:diag, ld:int, l0:addr ) = [lu,lo,ll:addr] @( TRMAT_v (a1, i, ord, lower, dg, ld, lu) , GEMAT_v (a1, m-i, i, ord, ld, lo) , TRMAT_v (a1, m-i, ord, lower, dg, ld, ll) , {a2:viewt@ype | a1 \tszeq a2} ( // [fpf: for unsplitting] TRMAT_v (a2, i, ord, lower, dg, ld, lu) , GEMAT_v (a2, m-i, i, ord, ld, lo) , TRMAT_v (a2, m-i, ord, lower, dg, ld, ll) ) - TRMAT_v (a2, m, ord, lower, dg, ld, l0) | ptr lu // l11 should equal l0 , ptr lo , ptr ll ) // end of [TRMAT_L_ptr_split2x2_res_t] fun{a1:viewt@ype} TRMAT_L_ptr_split2x2 {ord:order} {dg:diag} {m,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: TRMAT_v (a1, m, ord, lower, dg, ld, l0) | ord: ORDER ord, A: ptr l0, ld: size_t ld, i: size_t i ) :<> TRMAT_L_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [TRMAT_L_ptr_split2x2] (* ****** ****** *) (* ** M2 <- M1 *) fun{a:t@ype} TRMAT_ptr_copy {ord:order} {ul:uplo} {dg:diag} {m:nat} {ld1,ld2:inc} ( ord: ORDER ord, ul: UPLO ul, dg: DIAG dg , M1: &TRMAT (a, m, ord, ul, dg, ld1) , M2: &TRMAT (a?, m, ord, ul, dg, ld2) >> TRMAT (a, m, ord, ul, dg, ld2) , m: size_t m, ld1: size_t ld1, ld2: size_t ld2 ) :<> void // end of [TRMAT_ptr_copy] (* ****** ****** *) // // SYmmetric MATrix representation (part of GEMAT) // // elt, row/col, ord, ul absviewt@ype SYMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, ld: int) // end of [SYMAT] viewdef SYMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, ld: int, l:addr) = SYMAT (a, n, ord, ul, ld) @ l // end of [SYMAT_v] prfun SYMAT_v_of_GEMAT_v {a:viewt@ype} {n:nat} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf: GEMAT_v (a, n, n, ord, ld, l), ul: UPLO ul ) :<> ( SYMAT_v (a, n, ord, ul, ld, l) , SYMAT_v (a, n, ord, ul, ld, l) - GEMAT_v (a, n, n, ord, ld, l) ) // end of [SYMAT_v_of_GEMAT_v] (* ****** ****** *) // // HErmitian matrix representation (* part of GEMAT *) // // elt, row/col, ord, ul absviewt@ype HEMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, ld: int) // end of [HEMAT] viewdef HEMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, ld: int, l:addr) = HEMAT (a, n, ord, ul, ld) @ l // end of [HEMAT_v] prfun HEMAT_v_of_SYMAT_v {a:t@ype} {n:nat} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: SYMAT_v (a, n, ord, ul, ld, l) ) :<> HEMAT_v (a, n, ord, ul, ld, l) // end of [HEMAT_v_of_SYMAT_v] prfun SYMAT_v_of_HEMAT_v {a:t@ype} {n:nat} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: HEMAT_v (a, n, ord, ul, ld, l) ) :<> SYMAT_v (a, n, ord, ul, ld, l) // end of [SYMAT_v_of_HEMAT_v] prfun HEMAT_v_of_GEMAT_v {a:viewt@ype} {n:nat} {ord:order} {ul:uplo} {ld:inc} {l:addr} ( pf: GEMAT_v (a, n, n, ord, ld, l), ul: UPLO ul ) :<> ( HEMAT_v (a, n, ord, ul, ld, l) , HEMAT_v (a, n, ord, ul, ld, l) - GEMAT_v (a, n, n, ord, ld, l) ) // end of [HEMAT_v_of_GEMAT_v] (* ****** ****** *) // // General Band MATrix representation // // elt, row, col, ord, lower-bandwidth, upper-bandwidth absviewt@ype GBMAT // dimension: m x n, lower-bandwidth: kl, upper-bandwidth: ku (a:viewt@ype+, m:int, n:int, ord: order, kl: int, ku: int, ld: int) // end of [GBMAT] viewdef GBMAT_v (a:viewt@ype, m:int, n:int, ord: order, kl: int, ku: int, ld: int, l: addr) = GBMAT (a, m, n, ord, kl, ku, ld) @ l // end of [GBMAT_v] (* ****** ****** *) // // Triangular Band MATrix representation // // elt, row/col, ord, ul, diag, bandwidth absviewt@ype TBMAT // dimension: n x n, bandwidth: k (a:viewt@ype+, n:int, ord: order, ul: uplo, dg: diag, k: int, ld: int) // end of [TBMAT] viewdef TBMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, dg: diag, k: int, ld: int, l: addr) = TBMAT (a, n, ord, ul, dg, k, ld) @ l prfun TBMAT_v_of_GEMAT_v {a:viewt@ype} {n,k:nat} {ul:uplo} {dg:diag} {l:addr} ( pf_gmat: GEMAT_v (a, 1+k, n, col, 1+k, l) , ul: UPLO ul , dg: DIAG dg , k: size_t k ) : ( TBMAT_v (a, n, col, ul, dg, k, 1+k, l) , TBMAT_v (a, n, col, ul, dg, k, 1+k, l) - GEMAT_v (a, 1+k, n, col, 1+k, l) ) // end of [TBMAT_v_of_GEMAT_v] (* ****** ****** *) // // Triangular Packed MATrix representation // // elt, row/col, ord, ul, diag absviewt@ype TPMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, dg: diag) // end of [TPMAT] viewdef TPMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, dg: diag, l: addr) = TPMAT (a, n, ord, ul, dg) @ l // end of [TPMAT_v] prfun TPMAT_v_of_GEVEC_v {a:viewt@ype} {ord:order} {ul:uplo} {dg:diag} {m,n:nat} {l:addr} ( pf_mul: MUL (n, n+1, m+m) , pf_vec: GEVEC_v (a, m, 1, l) , ord: ORDER (ord) , ul: UPLO (ul), dg: DIAG (dg) ) :<> ( TPMAT_v (a, n, ord, ul, dg, l) , TPMAT_v (a, n, ord, ul, dg, l) - GEVEC_v (a, m, 1, l) ) // end of [TPMAT_v_of_GEVEC_v] (* ****** ****** *) // // Symmetric Band MATrix representation // // elt, row/col, ord, ul, band-width absviewt@ype SBMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, k:int, ld:int) // end of [SBMAT] viewdef SBMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, k:int, ld:int, l: addr) = SBMAT (a, n, ord, ul, k, ld) @ l // end of [SBMAT_v] (* ****** ****** *) // // Symmetric Packed MATrix representation // // elt, row/col, ord, ul, diag absviewt@ype SPMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo) // end of [SPMAT] viewdef SPMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, l: addr) = SPMAT (a, n, ord, ul) @ l // end of [SPMAT_v] prfun SPMAT_v_of_GEVEC_v {a:viewt@ype} {ord:order} {ul:uplo} {m,n:nat} {l:addr} ( pf_mul: MUL (n, n+1, m+m) , pf_arr: GEVEC_v (a, m, 1, l) , ord: ORDER (ord), ul: UPLO (ul) ) :<> ( SPMAT_v (a, n, ord, ul, l) , SPMAT_v (a, n, ord, ul, l) - GEVEC_v (a, m, 1, l) ) // end of [HPMAT_v_of_GEVEC_v] (* ****** ****** *) // // Hermitian Band MATrix representation // // elt, row/col, ord, ul, band-width absviewt@ype HBMAT // dimension: n x n (a:viewt@ype+, n:int, ord: order, ul: uplo, k:int, ld:int) // end of [HBMAT] viewdef HBMAT_v (a:viewt@ype, n:int, ord: order, ul: uplo, k:int, ld:int, l: addr) = HBMAT (a, n, ord, ul, k, ld) @ l // end of [HBMAT_v] prfun HBMAT_v_of_SBMAT_v {a:t@ype} {ord:order} {ul:uplo} {n:nat} {k:int} {ld:int} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: SBMAT_v (a, n, ord, ul, k, ld, l) ) :<> HBMAT_v (a, n, ord, ul, k, ld, l) // end of [HBMAT_v_of_SBMAT_v] prfun SBMAT_v_of_HBMAT_v {a:t@ype} {ord:order} {ul:uplo} {n:nat} {k:int} {ld:int} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: HBMAT_v (a, n, ord, ul, k, ld, l) ) :<> SBMAT_v (a, n, ord, ul, k, ld, l) // end of [SBMAT_v_of_HBMAT_v] (* ****** ****** *) // // Hermitian Packed MATrix representation // // elt, row/col, ord, ul, diag absviewt@ype HPMAT // dimension: n x n (a:viewt@ype+, n:int, ord:order, ul:uplo) // end of [HPMAT] viewdef HPMAT_v (a:viewt@ype, n:int, ord:order, ul:uplo, l:addr) = HPMAT (a, n, ord, ul) @ l // end of [HPMAT_v] prfun HPMAT_v_of_SPMAT_v {a:t@ype} {ord:order} {ul:uplo} {n:nat} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: SPMAT_v (a, n, ord, ul, l) ) :<> HPMAT_v (a, n, ord, ul, l) // end of [HPMAT_v_of_SPMAT_v] prfun SPMAT_v_of_HPMAT_v {a:t@ype} {ord:order} {ul:uplo} {n:nat} {l:addr} ( pf_typ: realtyp_p (a), pf_mat: HPMAT_v (a, n, ord, ul, l) ) :<> SPMAT_v (a, n, ord, ul, l) // end of [SPMAT_v_of_HPMAT_v] prfun HPMAT_v_of_GEVEC_v {a:viewt@ype} {ord:order} {ul:uplo} {m,n:nat} {l:addr} ( pf_mul: MUL (n, n+1, m+m) , pf_arr: GEVEC_v (a, m, 1, l) , ord: ORDER (ord), ul: UPLO (ul) ) :<> ( HPMAT_v (a, n, ord, ul, l) , HPMAT_v (a, n, ord, ul, l) - GEVEC_v (a, m, 1, l) ) // end of [HPMAT_v_of_GEVEC_v] (* ****** ****** *) (* end of [genarrays.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funmset_listord.sats0000664000175000017500000000674212223166162022153 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May 18, 2011 ** *) (* ****** ****** *) abstype mset_t0ype_type (elt: t@ype+) stadef mset = mset_t0ype_type (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - int fun{a:t@ype} compare_elt_elt (x1: a, x2: a, cmp: cmp (a)):<> int (* ****** ****** *) fun{} funmset_make_nil {a:t@ype} ():<> mset (a) fun{a:t@ype} funmset_make_sing (x: a):<> mset (a) fun{a:t@ype} funmset_make_pair (x1: a, x2: a, cmp: cmp a):<> mset (a) fun{a:t@ype} funmset_make_list (xs: List a, cmp: cmp a):<> mset (a) (* ****** ****** *) fun{a:t@ype} funmset_size (xs: mset (a)): size_t (* ****** ****** *) fun{a:t@ype} funmset_get_ntime (xs: mset a, x0: a, cmp: cmp a):<> uint fun{a:t@ype} funmset_is_member (xs: mset a, x0: a, cmp: cmp a):<> bool fun{a:t@ype} funmset_isnot_member (xs: mset a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} funmset_insert ( xs: &mset (a) , x0: a , cmp: cmp (a) ) :<> void // end of [funmset_insert] fun{a:t@ype} funmset_remove ( xs: &mset (a) , x0: a , cmp: cmp (a) ) :<> bool(*removed/not: true/false*) // end of [funmset_remove] (* ****** ****** *) fun{a:t@ype} funmset_union (xs1: mset (a), xs2: mset (a), cmp: cmp (a)):<> mset (a) fun{a:t@ype} funmset_intersect (xs1: mset (a), xs2: mset (a), cmp: cmp (a)):<> mset (a) (* ****** ****** *) fun{a:t@ype} funmset_is_subset (xs1: mset (a), xs2: mset (a), cmp: cmp (a)):<> bool // end of [funmset_is_subset] fun{a:t@ype} funmset_is_equal (xs1: mset (a), mxs2: mset (a), cmp: cmp (a)):<> bool // end of [funmset_is_equal] (* ****** ****** *) (* ** multiset ordering induced by the ordering on elements *) fun{a:t@ype} funmset_compare (xs1: mset (a), xs2: mset (a), cmp: cmp (a)):<> int // end of [funmset_compare] (* ****** ****** *) // fun{a:t@ype} funmset_listize (xs: mset (a)):<> List_vt (a) // no repeats // fun{a:t@ype} // if an element occurs n times, then it is repeated funmset_mlistize (xs: mset (a)):<> List_vt (a) // n times in the output // (* ****** ****** *) (* end of [funmset_listord.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/itreep.sats0000664000175000017500000001031312223166162020207 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: January, 2011 // (* ****** ****** *) // // HX: reasoning about integer trees // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/imsetp.sats" // for handling integer multiset (* ****** ****** *) datasort itree = | itree_nil of () | itree_cons of (int, itree, itree) // end of [itree] stadef itree_sing (x:int): itree = itree_cons (x, itree_nil, itree_nil) (* ****** ****** *) absprop MSETIZE (itree, imset) (* ****** ****** *) dataprop itreeeq (itree, itree) = | itreeeq_nil ( itree_nil, itree_nil ) of () | {x:int} {t1l,t2l:itree} {t1r,t2r:itree} itreeeq_cons ( itree_cons (x, t1l, t1r), itree_cons (x, t2l, t2r) ) of ( itreeeq (t1l, t2l), itreeeq (t1r, t2r) ) // end of [itreeeq_cons] // end of [itreeeq] (* ****** ****** *) dataprop ITREEEQ (itree, itree) = {t:itree} ITREEEQ (t, t) of () // end of [ITREEEQ] prfun itreeeq_elim {t1,t2:itree} (pf: itreeeq (t1, t2)): ITREEEQ (t1, t2) // end of [itreeeq_elim] (* ****** ****** *) dataprop TREESZ (itree, int) = | TREESZnil (itree_nil, 0) | {x:int} {tl,tr:itree} {nl,nr:nat} TREESZcons ( itree_cons (x, tl, tr), 1 + nl + nr ) of ( TREESZ(tl, nl), TREESZ (tr, nr) ) // end of [TREESZcons] // end of [TREESZ] (* ****** ****** *) absprop LTB (x:int, t:itree) prfun ltb_istot {xs:itree} (): [x:int] LTB (x, xs) prfun ltb_nil {x:int} (): LTB (x, itree_nil) prfun ltb_cons {x0:int} {x:int | x0 < x} {xsl,xsr:itree} (pfl: LTB (x0, xsl), pfr: LTB (x0, xsr)): LTB (x0, itree_cons (x, xsl, xsr)) // end of [ltb_cons] prfun ltb_cons_elim {x0:int} {x:int} {xsl,xsr:itree} (pf: LTB (x0, itree_cons (x, xsl, xsr))): [x0 < x] (LTB (x0, xsl), LTB (x0, xsr)) // end of [ltb_cons_elim] prfun ltb_dec {x1:int} {x2:int | x2 <= x1} {xs:itree} (pf: LTB (x1, xs)): LTB (x2, xs) // end of [ltb_dec] (* ****** ****** *) absprop LTEB (x:int, t:itree) prfun lteb_istot {xs:itree} (): [x:int] LTEB (x, xs) prfun lteb_nil {x:int} (): LTEB (x, itree_nil) prfun lteb_cons {x0:int} {x:int | x0 <= x} {xsl,xsr:itree} (pfl: LTEB (x0, xsl), pfr: LTEB (x0, xsr)): LTEB (x0, itree_cons (x, xsl, xsr)) // end of [lteb_cons] prfun lteb_cons_elim {x0:int} {x:int} {xsl,xsr:itree} (pf: LTEB (x0, itree_cons (x, xsl, xsr))): [x0 <= x] (LTEB (x0, xsl), LTEB (x0, xsr)) // end of [lteb_cons_elim] prfun lteb_dec {x1:int} {x2:int | x2 <= x1} {xs:itree} (pf: LTEB (x1, xs)): LTEB (x2, xs) // end of [lteb_dec] (* ****** ****** *) dataprop ISHEAP (itree) = | ISHEAPnil (itree_nil) of () | {x:int} {tl,tr:itree} ISHEAPcons ( itree_cons (x, tl, tr) ) of ( ISHEAP tl, ISHEAP tr, LTEB (x, tl), LTEB (x, tr) ) // end of [ISHEAPcons] // end of [ISHEAP] (* ****** ****** *) (* end of [itreep.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funralist_nested.sats0000664000175000017500000000663312223166162022302 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional random-access list implementation based on nested datatypes ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in November, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // HX: indexed by list length // abstype ralist_t0ype_int_type (a:t@ype+, n:int) stadef ralist = ralist_t0ype_int_type (* ****** ****** *) fun{} funralist_make_nil {a:t@ype} ():<> ralist (a, 0) (* ****** ****** *) fun{a:t@ype} funralist_length {n:nat} (xs: ralist (a, n)): int n (* ****** ****** *) fun{a:t@ype} funralist_cons {n:nat} (x: a, xs: ralist (a, n)):<> ralist (a, n+1) // end of [funralist_cons] fun{a:t@ype} funralist_uncons {n:pos} (xs: ralist (a, n), x: &a? >> a):<> ralist (a, n-1) // end of [funralist_uncons] (* ****** ****** *) fun{a:t@ype} funralist_head {n:pos} (xs: ralist (a, n)):<> a fun{a:t@ype} funralist_tail {n:pos} (xs: ralist (a, n)):<> ralist (a, n-1) (* ****** ****** *) fun{a:t@ype} funralist_lookup {n:nat} (xs: ralist (a, n), i: natLt n):<> a // end of [funralist_lookup] fun{a:t@ype} funralist_update {n:nat} (xs: ralist (a, n), i: natLt n, x: a):<> ralist (a, n) // end of [funralist_update] (* ****** ****** *) fun{a:t@ype} funralist_foreach_vclo {v:view} {n:nat} {f:eff} (pf: !v | xs: ralist (a, n), f: &(!v | a) - void): void // end of [funralist_foreach_vclo] fun{a:t@ype} funralist_foreach_cloptr {n:nat} {f:eff} (xs: ralist (a, n), f: !(a) - void): void // end of [funralist_foreach_vcloptr] fun{a:t@ype} funralist_foreach_vcloptr {v:view} {n:nat} {f:eff} (pf: !v | xs: ralist (a, n), f: !(!v | a) - void): void // end of [funralist_foreach_vcloptr] fun{a:t@ype} funralist_foreach_cloref {n:nat} {f:eff} (xs: ralist (a, n), f: (a) - void): void // end of [funralist_foreach_cloref] (* ****** ****** *) (* end of [funralist_nested.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linmap_avltree.sats0000664000175000017500000001301112223166162021717 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) absviewtype map_viewtype (key:t@ype, itm:viewt@ype+) stadef map = map_viewtype (* ****** ****** *) typedef cmp (key:t@ype) = (key, key) - int fun{key:t@ype} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) fun{} linmap_make_nil {key:t0p;itm:vt0p} ():<> map (key, itm) (* ****** ****** *) fun{} linmap_is_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool fun{} linmap_isnot_nil {key:t0p;itm:vt0p} (m: !map (key, itm)):<> bool (* ****** ****** *) // // HX: this function is O(n)-time and non-tail-recursive // fun{ key:t0p;itm:vt0p } linmap_size (m: !map (key, itm)):<> size_t // // HX: this function is O(1) // for gathering stats // fun{ key:t0p;itm:vt0p } linmap_height (m: !map (key, itm)):<> Nat (* ****** ****** *) fun{ key:t0p;itm:t0p } linmap_search ( m: !map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [linmap_search] fun{ key:t0p;itm:vt0p } linmap_search_ref ( m: !map (key, itm), k0: key, cmp: cmp key // unsafe but ... ) :<> Ptr // end of [linmap_search_ref] fun{ key:t0p;itm:t0p } linmap_search_opt (m: !map (key, itm), k0: key, cmp: cmp key):<> Option_vt (itm) // end of [linmap_search_opt] (* ****** ****** *) // // HX-2010-03-25: // if [k0] occurs in [m], [x0] replaces the original value associated // with [k0] // fun{ key:t0p;itm:vt0p } linmap_insert ( m: &map (key, itm) , k0: key, x0: itm, cmp: cmp key , res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool (b) // end of [linmap_insert] (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_takeout ( m: &map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool (b) // end of [linmap_takeout] fun{key:t0p;itm:t0p} linmap_remove (m: &map (key, itm), k0: key, cmp: cmp key):<> bool // end of [linmap_remove] (* ****** ****** *) // // HX: note the [foreach] can be used as [clear] // fun{ key:t0p;itm:vt0p } linmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_foreach_funenv] fun{ key:t0p;itm:vt0p } linmap_foreach_fun ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun] fun{ key:t0p;itm:vt0p } linmap_foreach_vclo {v:view} ( pf: !v | m: !map (key, itm), f: &(!v | key, &itm) - void ) :<> void // end of [linmap_foreach_vclo] fun{ key:t0p;itm:vt0p } linmap_foreach_cloref ( m: !map (key, itm), f: (key, &itm) - void ) : void // end of [linmap_foreach_cloref] (* ****** ****** *) // // HX: [foreach] in the reverse order // fun{ key:t0p;itm:vt0p } linmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_rforeach_funenv] (* ****** ****** *) // // HX: [clear] is based on [foreach] // fun{ key:t0p;itm:vt0p } linmap_clear_funenv {v:view}{vt:viewtype} ( pfv: !v | m: !map (key, itm) >> map (key, itm?) , f: (!v | key, &itm >> itm?, !vt) - void , env: !vt ) : void // end of [linmap_clear_funenv] (* ****** ****** *) // fun{key:t0p;itm:t0p} linmap_free (m: map (key, itm)):<> void // // HX: a linear map can be properly freed only if it is empty // fun{ key:t0p;itm:vt0p } linmap_free_vt ( m: !map (key, itm) >> opt (map (key, itm), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linmap_free_vt] (* ****** ****** *) (* // // HX: listization is done in the in-order fashion // *) // // HX-2010-07-01: // this one can be readily implemented based on [foreach] // fun{key:t0p;itm:t0p} linmap_listize (m: !map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize] fun{key:t0p;itm:vt0p} linmap_listize_free (m: map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize_free] (* ****** ****** *) (* end of [linmap_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/rarray.sats0000664000175000017500000001007312223166162020222 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Reversed Arrays (arrays running from right to left) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) dataview rarray_v ( a:viewt@ype+, int(*size*), addr(*loc*) ) = // for arrays in reversal order (from right to left) | {n:nat} {l:addr} rarray_v_cons (a, n+1, l+sizeof a) of (rarray_v (a, n, l), a @ l) | {l:addr} rarray_v_nil (a, 0, l) of () // end of [rarray_v] (* absview rarray_v (a:viewt@ype+, int(*size*), addr(*loc*)) *) (* ****** ****** *) prfun rarray_v_unnil {a:viewt@ype} {l:addr} (pfarr: rarray_v (a, 0, l)):<> void // end of [rarray_v_unnil] prfun rarray_v_uncons {a:viewt@ype} {n:pos} {l:addr} (pfarr: rarray_v (a, n, l)):<> (rarray_v (a, n-1, l-sizeof a), a @ l-sizeof a) // end of [rarray_v_uncons] (* ****** ****** *) prfun rarray_v_of_array_v {a:viewt@ype} {n:nat} {l:addr} {ofs:int} ( pfmul: MUL (n, sizeof a, ofs), pfarr: array_v (a, n, l) ) :<> rarray_v (a, n, l+ofs) // end of [rarray_v_of_array_v] prfun array_v_of_rarray_v {a:viewt@ype} {n:nat} {l:addr} {ofs:int} ( pfmul: MUL (n, sizeof a, ofs), pfarr: rarray_v (a, n, l) ) :<> array_v (a, n, l-ofs) // end of [rarray_v_of_array_v] (* ****** ****** *) fun{a:viewt@ype} array2rarray_ptr {n:nat} {l:addr} (pf: array_v (a, n, l) | p: ptr l, n: size_t n) :<> [ofs:int] (MUL (n, sizeof a, ofs), rarray_v (a, n, l+ofs) | ptr (l+ofs)) // end of [array2rarray_ptr] fun{a:viewt@ype} rarray2array_ptr {n:nat} {l:addr} (pf: rarray_v (a, n, l) | p: ptr l, n: size_t n) :<> [ofs:int] (MUL (n, sizeof a, ofs), array_v (a, n, l-ofs) | ptr (l-ofs)) // end of [rarray2array_ptr] (* ****** ****** *) (* ** HX-2010-09-20: implemented in ATS (libats/DATS/rarray.dats) *) fun rarray_ptr_foreach_funenv_tsz {a:viewt@ype} {v:view} {vt:viewtype} {n:nat} {l:addr} ( pf: !v, pfarr: !rarray_v (a, n, l) | p: ptr l , f: (!v | &a, !vt) -<> void, asz: size_t n, tsz: sizeof_t a , env: !vt ) :<> void // end of [rarray_ptr_foreach_funenv_tsz] fun{a:viewt@ype} rarray_ptr_foreach_fun {n:nat} {l:addr} ( pfarr: !rarray_v (a, n, l) | p: ptr l, f: (&a) - void, asz: size_t n ) :<> void // end of [rarray_ptr_foreach_fun] fun{a:viewt@ype} rarray_ptr_foreach_vclo {v:view} {n:nat} {l:addr} ( pf: !v, pfarr: !rarray_v (a, n, l) | p: ptr l, f: &(!v | &a) - void, asz: size_t n ) :<> void // end of [rarray_ptr_foreach_vclo] (* ****** ****** *) fun{a:viewt@ype} array_ptr_rforeach_vclo {v:view} {n:nat} {l:addr} ( pf: !v | A: &(@[a][n]), f: &(!v | &a) - void, asz: size_t n ) :<> void // end of [array_ptr_rforeach_vclo] (* ****** ****** *) (* end of [rarray.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funarray_braun.sats0000664000175000017500000001267112223166162021746 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional array implementation based on Braun trees ** An functional array as such can also be used as a deque ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) abstype array_t0ype_int_type (a:t@ype+ (*element*), n:int (*size*)) stadef array = array_t0ype_int_type (* ****** ****** *) // // HX-2010-04-04: // this means staloading at run-time is needed! // exception SubscriptException of () (* ****** ****** *) fun{} funarray_make_nil {a:t@ype} ():<(*pure*)> array (a, 0) (* ****** ****** *) // compute the size of [A] fun{a:t@ype} // O(log^2(n)) funarray_size {n:nat} (A: array (a, n)):<(*pure*)> size_t n (* ****** ****** *) // // obtain the element stored in 'A[i]' // fun{a:t@ype} // O(log(n)) funarray_get_elt_at {n:nat} (A: array (a, n), i: natLt n):<(*pure*)> a overload [] with funarray_get_elt_at // // update 'A[i]' with 'x'; note that this creates a new array! // fun{a:t@ype} // O(log(n)) funarray_set_elt_at {n:nat} (A: &array (a, n), i: natLt n, x: a):<(*pure*)> void overload [] with funarray_set_elt_at (* ****** ****** *) // // exchange elements stored in 'A[i]' and 'x' // fun{a:t@ype}// O(log(n)) funarray_xch_elt_at {n:nat} (A: &array (a, n), i: natLt n, x: a):<(*pure*)> a // end of [funarray_xch_elt_at] (* ****** ****** *) fun{a:t@ype} funarray_get_elt_at_exn {n:nat} (A: array (a, n), i: Nat): a fun{a:t@ype} funarray_set_elt_at_exn {n:nat} (A: &array (a, n), i: Nat, x: a): void (* ****** ****** *) // // insert an element to the start of the array // fun{a:t@ype} funarray_loadd {n:nat} // O(log(n)) (A: &array (a, n) >> array (a, n+1), x: a):<(*pure*)> void // end of [funarray_loadd] // // remove an element from the start of the array // fun{a:t@ype} funarray_lorem (* O(log(n)) *) {n:pos} (A: &array (a, n) >> array (a, n-1)):<(*pure*)> void // end of [funarray_lorem] // // remove an element from the start of the array and obtain it // fun{a:t@ype} funarray_lorem_get (* O(log(n)) *) {n:pos} (A: &array (a, n) >> array (a, n-1)):<(*pure*)> a // end of [funarray_lorem_get] (* ****** ****** *) // // insert an element to the end of the array // fun{a:t@ype} funarray_hiadd {n:nat} // O(log(n)) (A: &array (a, n) >> array (a, n+1), n: int n, x: a):<(*pure*)> void // end of [funarray_hiadd] // // remove an element from the end of the array // fun{a:t@ype} funarray_hirem // O(log(n)) {n:pos} (A: &array (a, n) >> array (a, n-1), n: int n):<(*pure*)> void // end of [funarray_hirem] // // remove an element from the end of the array and obtain it // fun{a:t@ype} funarray_hirem_get (* O(log(n)) *) {n:pos} (A: &array (a, n) >> array (a, n-1), n: int n):<(*pure*)> a // end of [funarray_hirem_get] (* ****** ****** *) (* ** HX-2009: ** these higher-order functions are probably not particularly useful as ** they can be readily replaced with for-loops. See the implementation. *) fun{a:t@ype} funarray_foreach_vclo {v:view} {n:nat} (pf: !v | A: array (a, n), n: int n, f: &(!v | a) - void):<> void fun{a:t@ype} funarray_foreach_cloptr {n:nat} (A: array (a, n), n: int n, f: !(a) - void):<> void fun{a:t@ype} funarray_foreach_vcloptr {v:view} {n:nat} (pf: !v | A: array (a, n), n: int n, f: !(!v | a) - void):<> void fun{a:t@ype} funarray_foreach_cloref {n:nat} (A: array (a, n), n: int n, f: a - void): void (* ****** ****** *) fun{a:t@ype} funarray_iforeach_vclo {v:view} {n:nat} (pf: !v | A: array (a, n), n: int n, f: &(!v | natLt n, a) - void):<> void fun{a:t@ype} funarray_iforeach_cloptr {n:nat} (A: array (a, n), n: int n, f: !(natLt n, a) - void):<> void fun{a:t@ype} funarray_iforeach_vcloptr {v:view} {n:nat} (pf: !v | A: array (a, n), n: int n, f: !(!v | natLt n, a) - void):<> void fun{a:t@ype} funarray_iforeach_cloref {n:nat} (A: array (a, n), n: int n, f: (natLt n, a) - void): void (* ****** ****** *) (* end of [funarray_braun.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linqueue_lst.sats0000664000175000017500000000653412223166162021442 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A list-based queue implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: July, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/linqueue_lst.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // HX: a: item type; n: current size // absviewt@ype QUEUE (a:viewt@ype+, n: int) = $extype "atslib_linqueue_lst_QUEUE" // end of [QUEUE] typedef QUEUE0 (a:viewt@ype) = QUEUE (a, 0)? viewtypedef QUEUE1 (a:viewt@ype) = [n:nat] QUEUE (a, n) (* ****** ****** *) fun{a:viewt@ype} queue_size {n:nat} (q: &QUEUE (a, n)):<> size_t n fun queue_is_empty {a:viewt@ype} {n:nat} (q: &QUEUE (a, n)):<> bool (n <= 0) // end of [queue_is_empty] fun queue_isnot_empty {a:viewt@ype} {n:nat} (q: &QUEUE (a, n)):<> bool (n > 0) // end of [queue_isnot_empty] (* ****** ****** *) fun queue_initialize {a:viewt@ype} (q: &QUEUE0 a >> QUEUE (a, 0)):<> void fun{a:viewt@ype} queue_uninitialize {n:nat} (q: &QUEUE (a, n) >> QUEUE0 a):<> list_vt (a, n) (* ****** ****** *) fun{a:viewt@ype} queue_insert (*last*) {n:nat} (q: &QUEUE (a, n) >> QUEUE (a, n+1), x: a):<> void // end of [queue_insert] fun{a:viewt@ype} queue_remove (*first*) {n:nat | n > 0} (q: &QUEUE (a, n) >> QUEUE (a, n-1)):<> a // end of [queue_remove] (* ****** ****** *) fun{a:viewt@ype} queue_foreach_funenv {v:view} {vt:viewtype} {n:nat} ( pf: !v | q: &QUEUE (a, n), f: (!v | &a, !vt) - void, env: !vt ) :<> void // end of [queue_foreach_funenv] fun{a:viewt@ype} queue_foreach_fun {n:nat} (q: &QUEUE (a, n), f: (&a) - void):<> void // end of [queue_foreach_fun] fun{a:viewt@ype} queue_foreach_vclo {v:view} {n:nat} (pf: !v | q: &QUEUE (a, n), f: &(!v | &a) - void):<> void // end of [queue_foreach_vclo] (* ****** ****** *) (* end of [linqueue_lst.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/hashtable_chain.sats0000664000175000017500000001464212223166162022025 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A hashtable implementation ** where buckets are represented as linked lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/hashtable_chain.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) typedef hash (key:t0p) = (key) - ulint typedef eqfn (key:t0p) = (key, key) - bool absviewtype HASHTBLptr (key:t@ype, itm:viewt@ype+, l:addr) viewtypedef HASHTBLptr0 (key:t0p, itm:vt0p) = [l:agez] HASHTBLptr (key, itm, l) // end of [HASHTBLptr0] viewtypedef HASHTBLptr1 (key:t0p, itm:vt0p) = [l:addr | l > null] HASHTBLptr (key, itm, l) // end of [HASHTBLptr1] castfn ptr_of_HASHTBLptr {key:t0p} {itm:vt0p} {l:addr} (x: !HASHTBLptr (key, itm, l)):<> ptr l overload ptr_of with ptr_of_HASHTBLptr (* ****** ****** *) abstype HASHTBLref (key:t@ype, itm:viewt@ype) castfn HASHTBLref_make_ptr {key:t0p;itm:vt0p} {l:agz} (x: HASHTBLptr (key, itm, l)):<> HASHTBLref (key, itm) // end of [HASHTBLref_make_ptr] castfn HASHTBLref_takeout_ptr {key:t0p;itm:vt0p} ( x: HASHTBLref (key, itm) ) : [l:agz] ( HASHTBLptr (key, itm, l) - void | HASHTBLptr (key, itm, l) ) // end of [HASHTBLref_takeout_ptr] (* ****** ****** *) fun{key:t0p} hash_key (x: key, fhash: hash key):<> ulint // end of [hash_key] fun{key:t0p} equal_key_key (x1: key, x2: key, eqfn: eqfn key):<> bool // end of [equal_key_key] (* ****** ****** *) fun hashtbl_size // the (array) size of the hashtable {key:t0p;itm:vt0p} {l:agz} (p: !HASHTBLptr (key, itm, l)):<> size_t // end of [hashtbl_size] fun hashtbl_total // the total number of elements present in the hashtable {key:t0p;itm:vt0p} {l:agz} (tbl: !HASHTBLptr (key, itm, l)):<> size_t // end of [hashtbl_total] // // HX: clear the hashtable: all the chains are freed // fun{key:t0p;itm:t0p} hashtbl_clear {l:agz} (ptbl: !HASHTBLptr (key, itm, l)):<> void // end of [hashtbl_clear] // // HX: clear the hashtable: all the chains are freed // fun{key:t0p;itm:vt0p} hashtbl_clear_fun {l:agz} (ptbl: !HASHTBLptr (key, itm, l), f: (&itm >> itm?) -<> void):<> void // end of [hashtbl_clear_fun] (* ****** ****** *) // // HX-2010-03-20: // this one is a safe version, but it can only handle non-linear items // fun{key:t0p;itm:t0p} hashtbl_search {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_search] // // HX-2010-03-20: // if the returned pointer is used, it must be done before the hashtable // is changed! // fun{key:t0p;itm:vt0p} // unsafe but ... hashtbl_search_ref {l:agz} (ptbl: !HASHTBLptr (key, itm, l), k0: key):<> Ptr // end of [hashtbl_search_ref] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_insert {l:agz} (ptbl: !HASHTBLptr (key, itm, l), k: key, i: itm):<> void // end of [hashtbl_insert] fun{key:t0p;itm:vt0p} hashtbl_remove {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_remove] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_foreach_vclo {v:view} {l:agz} ( pf: !v | ptbl: !HASHTBLptr (key, itm, l), f: &(!v | key, &itm) - void ) :<> void // end of [hashtbl_foreach_vclo] fun{key:t0p;itm:vt0p} hashtbl_foreach_cloref {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), f: !(key, &itm) - void ) :<> void // end of [hashtbl_foreach_cloref] (* ****** ****** *) fun hashtbl_make {key:t0p;itm:vt0p} ( fhash: hash key, eqfn: eqfn key ) : HASHTBLptr1 (key, itm) // end of [hashtbl_make] fun hashtbl_make_hint {key:t0p;itm:vt0p} ( fhash: hash key, eqfn: eqfn key, hint: size_t ) : HASHTBLptr1 (key, itm) = "atslib_hashtbl_make_hint__chain" // end of [hashtbl_make_hint] fun hashtbl_make_null {key:t0p;itm:vt0p} (): HASHTBLptr (key, itm, null) = "atslib_hashtbl_make_null__chain" // end of [hashtbl_make_null] (* ****** ****** *) fun hashtbl_free {key:t0p;itm:t0p} {l:agz} ( tbl: HASHTBLptr (key, itm, l) ) :<> void = "atslib_hashtbl_free__chain" // end of [hashtbl_free] fun hashtbl_free_null {key:t0p;itm:vt0p} ( tbl: HASHTBLptr (key, itm, null) ) :<> void = "atslib_hashtbl_free_null__chain" // end of [hashtbl_free_null] // // HX-2010-03-21: // [hashtbl_clear_fun] may need to be called first to clear up // fun hashtbl_free_vt {key:t0p;itm:vt0p} {l:agz} ( tbl: !HASHTBLptr (key, itm, l) >> opt (HASHTBLptr (key, itm, l), b) ) :<> #[b:bool] bool b(*~freed*) = "atslib_hashtbl_free_vt__chain" // end of [hashtbl_free_vt] (* ****** ****** *) (* // // HX-2010-07-01: it can be readily implemented based on [foreach] // *) fun{key:t0p;itm:t0p} hashtbl_listize {l:agz} (tbl: !HASHTBLptr (key, itm, l)): List_vt @(key, itm) fun{key:t0p;itm:vt0p} hashtbl_listize_free {l:agz} (tbl: HASHTBLptr (key, itm, l)): List_vt @(key, itm) (* ****** ****** *) (* end of [hashtable_chain.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/intinf.sats0000664000175000017500000001661412223166162020220 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX-2010-02-06: // // infinite precision integers based on the gmp package; the primary purpose // of [intinf] is for doing quick demo involving large numbers. If you need // full-fledged support for large numbers, please use the API for GMP in ATS // directly: // // $ATSHOME/libc/SATS/gmp.sats // (* ****** ****** *) %{# #include "libats/CATS/intinf.cats" %} // end of [%{#] (* ****** ****** *) staload "libc/SATS/gmp.sats" (* ****** ****** *) // // HX: a linear type of unspecified size // absviewtype intinf (int) viewtypedef Intinf = [i:int] intinf (i) (* ****** ****** *) symintr intinf_make fun intinf_make_int {i:int} (i: int i):<> intinf (i) overload intinf_make with intinf_make_int fun intinf_make_lint {i:int} (i: lint i):<> intinf (i) overload intinf_make with intinf_make_lint fun intinf_make_llint {i:int} (i: llint i):<> intinf (i) overload intinf_make with intinf_make_llint fun intinf_make_double (d: double):<> Intinf // [d] should be integral overload intinf_make with intinf_make_double fun intinf_make_string (rep: string):<> Intinf overload intinf_make with intinf_make_string fun intinf_make_intinf {i:int} (i: !intinf (i)):<> intinf (i) overload intinf_make with intinf_make_intinf (* ****** ****** *) fun intinf_free (x: Intinf): void (* ****** ****** *) fun intinf_get_int // HX: this is unsafe because of potential {n:int} (n: !intinf n): int n = "mac#atslib_mpz_get_int" // overflow // end of [intinf_get_int] (* ****** ****** *) symintr fprint_intinf fun fprint0_intinf {i:int} (out: FILEref, i: !intinf i): void fun fprint1_intinf {m:file_mode} {i:int} (pf: file_mode_lte (m, w) | fil: &FILE m, i: !intinf i): void overload fprint_intinf with fprint0_intinf overload fprint_intinf with fprint1_intinf fun print_intinf {i:int} (i: !intinf i): void overload print with print_intinf symintr fprint_intinf_base fun fprint0_intinf_base {i:int} ( out: FILEref, b: intBtw (2, 36+1), i: !intinf i ) : void // end of [fprint0_intinf_base] fun fprint1_intinf_base {m:file_mode} {i:int} ( pf: file_mode_lte (m, w) | fil: &FILE m, b: intBtw (2, 36+1), i: !intinf i ) : void // end of [fprint1_intinf_base] overload fprint_intinf_base with fprint0_intinf_base overload fprint_intinf_base with fprint1_intinf_base fun print_intinf_base {i:int} (b: intBtw (2, 36+1), i: !intinf i): void overload print with print_intinf_base (* ****** ****** *) fun pred_intinf {i:int} (i: !intinf i): intinf (i-1) overload pred with pred_intinf fun succ_intinf {i:int} (i: !intinf i): intinf (i+1) overload succ with succ_intinf // fun add_intinf_int {i,j:int} (i: !intinf i, j: int j): intinf (i+j) overload + with add_intinf_int fun add_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): intinf (i+j) overload + with add_intinf_intinf // fun sub_intinf_int {i,j:int} (i: !intinf i, j: int j): intinf (i-j) overload - with sub_intinf_int fun sub_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): intinf (i-j) overload - with sub_intinf_intinf // fun mul_int_intinf {m,n:int} (m: int m, n: !intinf n): [p:int] (MUL (m, n, p) | intinf p) overload * with mul_int_intinf fun mul_intinf_int {m,n:int} (m: !intinf m, n: int n): [p:int] (MUL (m, n, p) | intinf p) overload * with mul_intinf_int fun mul_intinf_intinf {m,n:int} (m: !intinf m, n: !intinf n): [p:int] (MUL (m, n, p) | intinf p) overload * with mul_intinf_intinf (* ****** ****** *) fun square_intinf {n:int} (n: !intinf n): [p:int] (MUL (n, n, p) | intinf p) overload square with square_intinf (* ****** ****** *) // // fdiv: floor division: round toward -infinity // fun fdiv_intinf_int {m,n:int | n > 0} (m: !intinf m, n: int n) : [q,r:int | 0 <= r; r < n] (MUL (q, n, m-r) | intinf q) = "atslib_fdiv_intinf_int" overload / with fdiv_intinf_int // // fmod: floor division: round toward -infinity // fun fmod_intinf_int {m,n:int | n > 0} (m: !intinf m, n: int n) : [q,r:int | 0 <= r; r < n] (MUL (q, n, m-r) | int r) overload mod with fmod_intinf_int (* ****** ****** *) fun lt_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i < j) = "atslib_lt_intinf_int" overload < with lt_intinf_int fun lt_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i < j) = "atslib_lt_intinf_intinf" overload < with lt_intinf_intinf // fun lte_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i <= j) = "atslib_lte_intinf_int" overload <= with lte_intinf_int fun lte_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i <= j) = "atslib_lte_intinf_intinf" overload <= with lte_intinf_intinf // fun gt_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i > j) = "atslib_gt_intinf_int" overload > with gt_intinf_int fun gt_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i > j) = "atslib_gt_intinf_intinf" overload > with gt_intinf_intinf // fun gte_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i >= j) = "atslib_gte_intinf_int" overload >= with gte_intinf_int fun gte_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i >= j) = "atslib_gte_intinf_intinf" overload >= with gte_intinf_intinf // fun eq_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i == j) = "atslib_eq_intinf_int" overload = with eq_intinf_int fun eq_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i == j) = "atslib_eq_intinf_intinf" overload = with eq_intinf_intinf // fun neq_intinf_int {i,j:int} (i: !intinf i, j: int j): bool (i <> j) = "atslib_neq_intinf_int" overload <> with neq_intinf_int fun neq_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): bool (i <> j) = "atslib_neq_intinf_intinf" overload <> with neq_intinf_intinf // fun compare_intinf_int {i,j:int} (i: !intinf i, j: int j): [k:int | sgn_r (i-j, k)] int k = "atslib_compare_intinf_int" overload compare with compare_intinf_int fun compare_intinf_intinf {i,j:int} (i: !intinf i, j: !intinf j): [k:int | sgn_r (i-j, k)] int k = "atslib_compare_intinf_intinf" overload compare with compare_intinf_intinf (* ****** ****** *) (* end of [intinf.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/iterint.sats0000664000175000017500000000667112223166162020411 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: 2008 // (* ****** ****** *) // // some common functions that iterate over natural numbers; // The code mainly serves as an example for writing iterative loops // in ATS // (* ****** ****** *) fun foreach_funenv {v:view} {vt: viewtype} {n:nat} {f:eff} (pf: !v | n: int n, f: (!v | natLt n, !vt) - void, env: !vt): void // end of [foreach_funenv] fun foreach_fun {n:nat} {f:eff} (n: int n, f: (natLt n) - void): void // end of [foreach_fun] fun foreach_vclo {v:view} {n:nat} {f:eff} (pf: !v | n: int n, f: &(!v | natLt n) - void): void // end of [foreach_vclo] // this one is the usual functional version fun foreach_cloref {n:nat} {f:eff} (n: int n, f: (natLt n) - void): void // end of [foreach_cloref] (* ****** ****** *) // // HX-2010-03-23: // the implementation for this function is row-major // fun foreach2_funenv {v:view} {vt: viewtype} {m,n:nat} {f:eff} ( pf: !v | m: int m, n: int n , f: (!v | natLt m, natLt n, !vt) - void , env: !vt ) : void // end of [foreach2_funenv] fun foreach2_fun {m,n:nat} {f:eff} (m: int m, n: int n, f: (natLt m, natLt n) - void) : void // end of [foreach2_fun] fun foreach2_vclo {v:view} {m,n:nat} {f:eff} (pf: !v | m: int m, n: int n, f: &(!v | natLt m, natLt n) - void) : void // end of [foreach2_vclo] // this one is the usual functional version fun foreach2_cloref {m,n:nat} {f:eff} (m: int m, n: int n, f: (natLt m, natLt n) - void) : void // end of [foreach2_cloref] (* ****** ****** *) fun repeat_funenv {v:view} {vt:viewtype} {n:nat} {f:eff} (pf: !v | n: int n, f: (!v | !vt) - void, env: !vt): void // end of [repeat_funenv] fun repeat_fun {n:nat} {f:eff} (n: int n, f: () - void): void fun repeat_vclo {v:view} {n:nat} {f:eff} (pf: !v | n: int n, f: &(!v | (*none*)) - void): void // end of [repeat_vclo] fun repeat_cloref {n:nat} {f:eff} (n: int n, f: () - void): void // end of [repeat_cloref] (* ****** ****** *) (* end of [iterint.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/hashtable_linprb.sats0000664000175000017500000001504212223166162022224 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A hashtable implementation based on linear probing ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) typedef hash (key:t0p) = (key) - ulint typedef eqfn (key:t0p) = (key, key) - bool absviewtype HASHTBLptr (key:t@ype, itm:viewt@ype+, l:addr) viewtypedef HASHTBLptr0 (key:t0p, itm:vt0p) = [l:agez] HASHTBLptr (key, itm, l) // end of [HASHTBLptr0] viewtypedef HASHTBLptr1 (key:t0p, itm:vt0p) = [l:addr | l > null] HASHTBLptr (key, itm, l) // end of [HASHTBLptr1] castfn ptr_of_HASHTBLptr {key:t0p} {itm:vt0p} {l:addr} (x: !HASHTBLptr (key, itm, l)):<> ptr l overload ptr_of with ptr_of_HASHTBLptr (* ****** ****** *) abstype HASHTBLref (key:t@ype, itm:viewt@ype) castfn HASHTBLref_make_ptr {key:t0p;itm:vt0p} {l:agz} ( x: HASHTBLptr (key, itm, l) ) :<> HASHTBLref (key, itm) // end of [castfn] // // HX: unsafe but convenient ... // castfn HASHTBLref_takeout_ptr {key:t0p;itm:vt0p} ( x: HASHTBLref (key, itm) ) : [l:agz] ( HASHTBLptr (key, itm, l) - void | HASHTBLptr (key, itm, l) ) // end of [HASHTBLref_takeout_ptr] (* ****** ****** *) fun{key:t0p} hash_key (x: key, hash: hash key):<> ulint // end of [hash_key] fun{key:t0p} equal_key_key (x1: key, x2: key, eqfn: eqfn key):<> bool // end of [equal_key_key] (* ****** ****** *) absviewt@ype Opt (a:viewt@ype) = a prfun Opt_none {keyitm:vt0p} (x: !keyitm? >> Opt keyitm):<> void prfun Opt_some {keyitm:vt0p} (x: !(keyitm) >> Opt keyitm):<> void prfun Opt_encode {keyitm:vt0p} {b:bool} (x: !opt (keyitm, b) >> Opt keyitm):<> void // end of [Opt_encode] fun{keyitm:vt0p} keyitem_nullify (x: &keyitm? >> Opt keyitm):<> void fun{keyitm:vt0p} keyitem_isnot_null (x: &Opt keyitm >> opt (keyitm, b)):<> #[b:bool] bool b (* ****** ****** *) fun hashtbl_size // the (array) size of the hashtable {key:t0p;itm:vt0p} {l:agz} (p: !HASHTBLptr (key, itm, l)):<> size_t // end of [hashtbl_size] fun hashtbl_total // the total number of elements present in the hashtable {key:t0p;itm:vt0p} {l:agz} (tbl: !HASHTBLptr (key, itm, l)):<> size_t // end of [hashtbl_total] fun{key:t0p;itm:t0p} // clear the hashtable hashtbl_clear {l:agz} (ptbl: !HASHTBLptr (key, itm, l)):<> void // end of [hashtbl_clear] (* ****** ****** *) // // HX-2010-03-20: // if the returned pointer is used, it must be done before the hashtable // is changed! // fun{key:t0p;itm:vt0p} // unsafe but ... hashtbl_search_ref {l:agz} (ptbl: !HASHTBLptr (key, itm, l), k0: key): Ptr // end of [hashtbl_search_ref] // // HX-2010-03-20: // this one is a safe version, but it can only handle non-linear items // fun{key:t0p;itm:t0p} hashtbl_search {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_search] (* ****** ****** *) // // HX-2010-04-03: // if [k] is already in the table, [i] replaces the original one // fun{key:t0p;itm:vt0p} hashtbl_insert {l:agz} ( ptbl: !HASHTBLptr (key, itm, l) , k: key, i: itm, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_insert] // // HX-2010-04-03: // removal seems to be quite efficient as well // fun{key:t0p;itm:vt0p} hashtbl_remove {l:agz} ( ptbl: !HASHTBLptr (key, itm, l) , k0: key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_remove] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_foreach_vclo {v:view} {l:agz} ( pf: !v | ptbl: !HASHTBLptr (key, itm, l), f: &(!v | key, &itm) - void ) :<> void // end of [hashtbl_foreach_vclo] fun{key:t0p;itm:vt0p} hashtbl_foreach_cloref {l:agz} (ptbl: !HASHTBLptr (key, itm, l), f: !(key, &itm) - void):<> void // end of [hashtbl_foreach_cloref] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_make (hash: hash key, eqfn: eqfn key):<> HASHTBLptr1 (key, itm) // end of [hashtbl_make] (* // some prime numbers 53, 97, 193, 389, 769, 1543, 3079, 6151, 12289, 24593, 49157, 98317, 196613, 393241, 786433, 1572869, 3145739, 6291469, 12582917, 25165843, 50331653, 100663319, 201326611, 402653189, 805306457, 1610612741 *) fun{key:t0p;itm:vt0p} hashtbl_make_hint ( hash: hash key, eqfn: eqfn key, hint: size_t ) :<> HASHTBLptr1 (key, itm) = "atslib_hashtbl_make_hint__linprb" // end of [hashtbl_make_hint] (* ****** ****** *) fun hashtbl_free {key:t0p;itm:t0p} {l:agz} ( tbl: HASHTBLptr (key, itm, l) ) :<> void = "atslib_hashtbl_free__linprb" // end of [hashtbl_free] fun hashtbl_free_vt {key:t0p;itm:vt0p} {l:agz} ( tbl: !HASHTBLptr (key, itm, l) >> opt (HASHTBLptr (key, itm, l), b) ) :<> #[b:bool] bool b(*~freed*) = "atslib_hashtbl_free_vt__linprb" // end of [hashtbl_free_vt] (* ****** ****** *) // // HX-2010-07-01: it can be readily implemented based on [foreach] // fun{key:t0p;itm:t0p} hashtbl_listize {l:agz} (tbl: !HASHTBLptr (key, itm, l)):<> List_vt @(key, itm) fun{key:t0p;itm:vt0p} hashtbl_listize_free {l:agz} (tbl: HASHTBLptr (key, itm, l)):<> List_vt @(key, itm) (* ****** ****** *) (* end of [hashtable_linprb.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funmap_rbtree.sats0000664000175000017500000001113212223166162021550 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on red-black trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) abstype map_t0ype_t0ype_type (key:t@ype, itm:t@ype+) stadef map = map_t0ype_t0ype_type (* ****** ****** *) typedef cmp (key:t@ype) = (key, key) - int fun{key:t@ype} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) // // HX: cross-module inlining is supported by templatization // fun{} funmap_make_nil {key,itm:t@ype} ():<> map (key, itm) // fun{} funmap_is_nil {key,itm:t@ype} (m: map (key, itm)):<> bool fun{} funmap_isnot_nil {key,itm:t@ype} (m: map (key, itm)):<> bool // (* ****** ****** *) // // HX: this function is O(n)-time and non-tail-recursive // fun{key,itm:t@ype} funmap_size (m: map (key, itm)):<> size_t // // HX: this function is O(n) // for gathering stats // fun{key,itm:t@ype} funmap_height (m: map (key, itm)):<> Nat // // HX: this function is O(log(n)) // for gathering stats // fun{key,itm:t@ype} funmap_black_height (m: map (key, itm)):<> Nat (* ****** ****** *) fun{key,itm:t@ype} funmap_search ( m: map (key, itm) , k0: key , cmp: cmp key , res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [funmap_search] (* ****** ****** *) // // HX-2010-03-25: // if [k0] occurs in [m], [x0] replaces the original value associated with [k0] // fun{key,itm:t@ype} funmap_insert ( m: &map (key, itm) , k0: key , x0: itm , cmp: cmp key ) :<> bool(*[k0] alreay exists in [m]*) // end of [funmap_insert] fun{key,itm:t@ype} funmap_insert_clo ( m: &map (key, itm) , k0: key , x0: itm , f: &(itm(*new*), itm) - itm , cmp: cmp key ) :<> void // end of [funmap_insert_clo] (* ****** ****** *) fun{key,itm:t@ype} funmap_takeout ( m: &map (key, itm) , k0: key , cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [funmap_takeout] fun{key,itm:t@ype} funmap_remove ( m: &map (key, itm) , k0: key , cmp: cmp key ) :<> bool(*removed/not: true/false*) // end of [funmap_remove] (* ****** ****** *) fun{key,itm:t@ype} funmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: map (key, itm) , f: (!v | key, itm, !vt) - void , env: !vt ) :<> void // end of [funmap_foreach_funenv] fun{key,itm:t@ype} funmap_foreach_fun ( xs: map (key, itm) , f: (key, itm) - void ) :<> void // end of [funmap_foreach_fun] fun{key,itm:t@ype} funmap_foreach_vclo {v:view} ( pf: !v | xs: map (key, itm) , f: &(!v | key, itm) - void ) :<> void // end of [funmap_foreach_vclo] fun{key,itm:t@ype} funmap_foreach_cloref ( xs: map (key, itm) , f: (key, itm) - void ) : void // end of [funmap_foreach_cloref] (* ****** ****** *) fun{key,itm:t@ype} funmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: map (key, itm) , f: (!v | key, itm, !vt) - void , env: !vt ) :<> void // end of [funmap_rforeach_funenv] (* ****** ****** *) fun{key,itm:t@ype} funmap_listize (xs: map (key, itm)):<> List_vt @(key, itm) (* ****** ****** *) (* end of [funmap_rbtree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/gflist.sats0000664000175000017500000000611112223166162020210 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed lists (gflists) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" // for handling integer sequences (* ****** ****** *) abst@ype elt_t0ype_int (a:t@ype, x:int) = a stadef elt = elt_t0ype_int typedef elt (a:t@ype) = [x:int] elt (a, x) (* // HX-2011-09-11: abst@ype elt (a:t@ype, x:int) = !a // according to the new syntax proposal *) castfn eltencode : {a:t@ype} a -> elt (a) castfn eltdecode : {a:t@ype} elt (a) -> a (* ****** ****** *) datatype gflist ( a:t@ype, ilist(*ind*) ) = | {x:int} {xs:ilist} gflist_cons (a, ilist_cons (x, xs)) of (elt (a, x), gflist (a, xs)) | gflist_nil (a, ilist_nil) of () // end of [gflist] (* ****** ****** *) castfn list_of_gflist {a:t@ype} {xs:ilist} (xs: gflist (a, xs)):<> [n:nat] (LENGTH (xs, n) | list (a, n)) // end of [list_of_gflist] castfn gflist_of_list {a:t@ype} {n:int} (xs: list (a, n)):<> [xs:ilist] (LENGTH (xs, n) | gflist (a, xs)) // end of [gflist_of_list] (* ****** ****** *) fun{a:t@ype} gflist_length {xs:ilist} (xs: gflist (a, xs)):<> [n:nat] (LENGTH (xs, n) | int n) // end of [gflist_length] (* ****** ****** *) fun{a:t@ype} gflist_append {xs1,xs2:ilist} (xs1: gflist (a, xs1), xs2: gflist (a, xs2)) : [res:ilist] (APPEND (xs1, xs2, res) | gflist (a, res)) // end of [gflist_append] fun{a:t@ype} gflist_revapp {xs1,xs2:ilist} (xs1: gflist (a, xs1), xs2: gflist (a, xs2)) : [res:ilist] (REVAPP (xs1, xs2, res) | gflist (a, res)) // end of [gflist_revapp] (* ****** ****** *) (* end of [gflist.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linstack_arr.sats0000664000175000017500000000775112223166162021407 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** An array-based stack implementation ** Author: hwxi AT cs DOT bu DOT edu ** Time: March, 2011 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/linstack_arr.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // a: item type // m: maximal capacity // n: current size // absviewt@ype STACK (a:viewt@ype+, m:int, n:int) = $extype "atslib_linstack_arr_STACK" // end of [STACK] viewtypedef STACK0 (a:viewt@ype) = [m,n:int] STACK (a, m, n) (* ****** ****** *) fun stack_cap {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> size_t m fun stack_size {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> size_t n (* ****** ****** *) fun stack_is_empty {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> bool (n <= 0) fun stack_isnot_empty {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> bool (n > 0) fun stack_is_full {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> bool (m <= n) fun stack_isnot_full {a:viewt@ype} {m,n:int} (s: &STACK (a, m, n)):<> bool (m > n) (* ****** ****** *) // // HX: initializing to a stack of capacity [m] // fun{a:viewt@ype} stack_initialize {m:nat} (s: &STACK0(a)? >> STACK (a, m, 0), m: size_t m):<> void // end of [linstackarr_initialize] (* ****** ****** *) // // HX: uninitializing a stack of nonlinear elements // fun stack_uninitialize {a:t@ype} {m,n:int} {l:addr} (s: &STACK (a, m, n) >> STACK0(a)?):<> void // end of [stack_uninitialize] // // HX: uninitializeing an empty stack of capacity [m] // fun stack_uninitialize_vt {a:viewt@ype} {m:int} {l:addr} (s: &STACK (a, m, 0) >> STACK0(a)?):<> void // end of [stack_unintialize_vt] (* ****** ****** *) fun{a:viewt@ype} stack_insert (*last*) // HX: stack_push {m,n:int | m > n} (s: &STACK (a, m, n) >> STACK (a, m, n+1), x: a):<> void // end of [stack_insert] fun{a:viewt@ype} stack_remove (*first*) // HX: stack_pop {m,n:int | n > 0} (s: &STACK (a, m, n) >> STACK (a, m, n-1)):<> a // end of [stack_remove] (* ****** ****** *) fun{a:t@ype} stack_clear {m,n1:int} {n2:nat | n2 <= n1} ( s: &STACK (a, m, n1) >> STACK (a, m, n1-n2), n2: size_t n2 ) :<> void // end of [stack_clear] fun stack_clear_all {a:t@ype} {m,n:int} (s: &STACK (a, m, n) >> STACK (a, m, 0)):<> void // end of [stack_clear_all] (* ****** ****** *) fun{a:viewt@ype} stack_update_capacity {m1,n:int} {m2:nat | n <= m2} {l:addr} ( q: &STACK (a, m1, n) >> STACK (a, m2, n) , m2: size_t (m2) ) : void // end of [stack_update_capcity] (* ****** ****** *) (* end of [linstack_arr.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funheap_binomial.sats0000664000175000017500000000517312223166162022227 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) abstype heap_t0ype_type (a:t@ype+) stadef heap = heap_t0ype_type (* ****** ****** *) // typedef cmp (a:t@ype) = (a, a) - Sgn // fun{a:t@ype} compare_elt_elt (x1: a, x2: a, cmp: cmp a):<> Sgn // (* ****** ****** *) fun{} funheap_make_nil {a:t@ype} ():<> heap (a) (* ****** ****** *) fun{a:t@ype} funheap_size (hp: heap a): size_t (* ****** ****** *) fun funheap_is_empty {a:t@ype} (hp: heap (a)):<> bool fun funheap_isnot_empty {a:t@ype} (hp: heap (a)):<> bool (* ****** ****** *) fun{a:t@ype} funheap_insert (hp: &heap (a), x: a, cmp: cmp a):<> void // end of [funheap_insert] (* ****** ****** *) fun{a:t@ype} funheap_getmin ( hp: heap (a), cmp: cmp a, res: &a? >> opt (a, b) ) :<> #[b:bool] bool b // end of [funheap_getmin] (* ****** ****** *) fun{a:t@ype} funheap_delmin ( hp: &heap (a), cmp: cmp a, res: &a? >> opt (a, b) ) :<> #[b:bool] bool b // end of [funheap_delmin] (* ****** ****** *) fun{a:t@ype} funheap_merge ( hp1: heap (a), hp2: heap (a), cmp: cmp a ) :<> heap (a) // end of [funheap_merge] (* ****** ****** *) (* end of [funheap_binomial.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/gfarray.sats0000664000175000017500000000763112223166162020363 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: fully indexed generic arrays // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" // for handling integer sequences (* ****** ****** *) absviewt@ype elt_v0type_int (a:viewt@ype, x:int) = a stadef elt = elt_v0type_int stadef elt (a:viewt@ype) = [x:int] elt (a, x) prfun eltencode {a:viewt@ype} (x: &a >> elt (a, x)): #[x:int] void prfun eltdecode {a:viewt@ype} {x:int} (x: &elt (a, x) >> a): void (* ****** ****** *) dataview gfarray_v (a:viewt@ype, ilist, addr) = | {x:int} {xs:ilist} {l:addr} gfarray_v_cons (a, ilist_cons (x, xs), l) of (elt (a, x) @ l, gfarray_v (a, xs, l+sizeof(a))) | {l:addr} gfarray_v_nil (a, ilist_nil, l) of () // end of [gfarray_v] (* ****** ****** *) prfun array_of_gfarray {a:viewt@ype} {xs:ilist} {l:addr} (pf: !gfarray_v (a, xs, l) >> array_v (a, n, l)): #[n:nat] LENGTH (xs, n) // end of [array_of_gfarray] prfun gfarray_of_array {a:viewt@ype} {n:int} {l:addr} (pf: !array_v (a, n, l) >> gfarray_v (a, xs, l)): #[xs:ilist] LENGTH (xs, n) // end of [gfarray_of_array] (* ****** ****** *) prfun gfarray_v_split {a:viewt@ype} {xs:ilist} {n,i:nat | i <= n} {l:addr} {ofs:int} ( pflen: LENGTH (xs, n) , pfmul: MUL (i, sizeof a, ofs) , pfarr: gfarray_v (a, xs, l) ) : [xs1,xs2:ilist] ( LENGTH (xs1, i), APPEND (xs1, xs2, xs), gfarray_v (a, xs1, l), gfarray_v (a, xs2, l+ofs) ) // end of [gfarray_v_split] prfun gfarray_v_unsplit {a:viewt@ype} {xs1,xs2:ilist} {n1:int} {l:addr} {ofs:int} ( pflen: LENGTH (xs1, n1) , pfmul: MUL (n1, sizeof a, ofs) , pfarr1: gfarray_v (a, xs1, l) , pfarr2: gfarray_v (a, xs2, l+ofs) ) : [xs:ilist] (APPEND (xs1, xs2, xs), gfarray_v (a, xs, l)) // end of [gfarray_v_unsplit] (* ****** ****** *) prfun gfarray_v_extend {a:viewt@ype} {xs:ilist} {x:int} {xsx:ilist} {n:nat} {l:addr} {ofs:int} ( pfsnoc: SNOC (xs, x, xsx) , pflen: LENGTH (xs, n) , pfmul: MUL (n, sizeof a, ofs) , pfarr: gfarray_v (a, xs, l) , pfat: a @ l+ofs ) : gfarray_v (a, xsx, l) // end of [gfarray_v_extend] prfun gfarray_v_unextend {a:viewt@ype} {xs:ilist} {n:int | n > 0} {l:addr} {ofs:int} ( pflen: LENGTH (xs, n) , pfmul: MUL (n, sizeof a, ofs) , pfarr: gfarray_v (a, xs, l) ) : [xsf:ilist;x:int] ( // xsf: the front SNOC (xsf, x, xs), gfarray_v (a, xsf, l), elt (a, x) @ l+ofs-sizeof a ) // end of [gfarray_v_unextend] (* ****** ****** *) (* end of [gfarray.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funset_listord.sats0000664000175000017500000000710612223166162021771 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May 18, 2011 ** *) (* ****** ****** *) abstype set_t0ype_type (elt: t@ype+) stadef set = set_t0ype_type (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - int fun{a:t@ype} compare_elt_elt (x1: a, x2: a, cmp: cmp (a)):<> int (* ****** ****** *) fun{} funset_make_nil {a:t@ype} ():<> set (a) fun{a:t@ype} funset_make_sing (x0: a):<> set (a) // singleton set fun{a:t@ype} funset_make_list (xs: List a, cmp: cmp a):<> set (a) (* ****** ****** *) fun{a:t@ype} funset_size (xs: set (a)): size_t (* ****** ****** *) fun{a:t@ype} funset_is_member (xs: set a, x0: a, cmp: cmp a):<> bool fun{a:t@ype} funset_isnot_member (xs: set a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} funset_insert ( xs: &set (a) , x0: a , cmp: cmp (a) ) :<> bool(*[x0] alreay exists in [xs]*) // end of [funset_insert] fun{a:t@ype} funset_remove ( xs: &set (a) , x0: a , cmp: cmp (a) ) :<> bool(*removed/not: true/false*) // end of [funset_remove] (* ****** ****** *) fun{a:t@ype} funset_union (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> set (a) fun{a:t@ype} funset_intersect (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> set (a) fun{a:t@ype} funset_diff (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> set (a) fun{a:t@ype} funset_symdiff (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> set (a) (* ****** ****** *) fun{a:t@ype} funset_is_subset (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> bool // end of [funset_is_subset] fun{a:t@ype} funset_is_equal (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> bool (* ****** ****** *) (* ** set ordering induced by the ordering on elements *) fun{a:t@ype} funset_compare (xs1: set (a), xs2: set (a), cmp: cmp (a)):<> int // end of [funset_compare] (* ****** ****** *) fun{a:t@ype} funset_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: set (a) , f: (!v | a, !vt) - void , env: !vt ) :<> void // end of [funset_foreach_funenv] (* ****** ****** *) // castfn funset2list {a:t@ype} (xs: set(a)): List (a) // fun{a:t@ype} funset_listize (xs: set (a)):<> List_vt (a) // = list_copy // (* ****** ****** *) (* end of [funset_listord.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linbitvec.sats0000664000175000017500000001040512223166162020700 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) %{# #include "libats/CATS/linbitvec.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no dynamic loading (* ****** ****** *) abst@ype BITVEC (n:int) // an abstract type of unspecified size (* ****** ****** *) typedef bit = [i:two] int (i) // i = 0 or 1 (* ****** ****** *) fun bitvec_make {n:nat} (n: size_t n):<> [l:addr] (free_gc_v l, BITVEC (n) @ l | ptr l) = "atslib_linbitvec_bitvec_make" // end of [bitvec_make] fun bitvec_make_nil {n:nat} (n: size_t n):<> [l:addr] (free_gc_v l, BITVEC (n) @ l | ptr l) = "atslib_linbitvec_bitvec_make_nil" // end of [bitvec_make_nil] fun bitvec_make_all {n:nat} (n: size_t n):<> [l:addr] (free_gc_v l, BITVEC (n) @ l | ptr l) = "atslib_linbitvec_bitvec_make_all" // end of [bitvec_make_all] fun bitvec_free {n:nat} {l:addr} (pf_gc: free_gc_v l, pf_vec: BITVEC (n) @ l | p: ptr l):<> void = "atslib_linbitvec_bitvec_free" // end of [bitvec_free] (* ****** ****** *) fun bitvec_get_at {n,i:nat | i < n} (vec: &BITVEC n, i: size_t i):<> bit = "atslib_linbitvec_bitvec_get_at" // end of [bitvec_get_at] fun bitvec_set_at {n,i:nat | i < n} (vec: &BITVEC n, i: size_t i, b: bit):<> void = "atslib_linbitvec_bitvec_set_at" // end of [bitvec_set_at] overload [] with bitvec_get_at overload [] with bitvec_set_at (* ****** ****** *) fun bitvec_is_nil {n:nat} (vec: &BITVEC n, n: size_t n): bool = "atslib_linbitvec_bitvec_is_nil" // end of [bitvec_is_nil] fun bitvec_isnot_nil {n:nat} (vec: &BITVEC n, n: size_t n): bool (* ****** ****** *) fun bitvec_is_all {n:nat} (vec: &BITVEC n, n: size_t n): bool = "atslib_linbitvec_bitvec_is_all" // end of [linbitvec_bitvec_is_all] fun bitvec_isnot_all {n:nat} (vec: &BITVEC n, n: size_t n): bool (* ****** ****** *) // vec1 = vec2 ? fun bitvec_equal {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n):<> bool = "atslib_linbitvec_bitvec_equal" // end of [bitvec_equal] fun bitvec_notequal {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n):<> bool (* ****** ****** *) // vec1 <- vec2 fun bitvec_copy {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n):<> void = "atslib_linbitvec_bitvec_copy" // end of [bitvec_copy] (* ****** ****** *) // complement operation fun bitvec_neg {n:nat} (vec: &BITVEC n, n: size_t n): void = "atslib_linbitvec_bitvec_neg" // end of [bitvec_neg] fun bitvec_or {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n): void = "atslib_linbitvec_bitvec_or" // end of [bitvec_or] fun bitvec_and {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n): void = "atslib_linbitvec_bitvec_and" // end of [bitvec_and] fun bitvec_xor {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n): void = "atslib_linbitvec_bitvec_xor" // end of [bitvec_xor] fun bitvec_diff {n:nat} (vec1: &BITVEC n, vec2: &BITVEC n, n: size_t n): void = "atslib_linbitvec_bitvec_diff" // end of [bitvec_diff] (* ****** ****** *) (* end of [linbitvec.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linqueue_arr.sats0000664000175000017500000001244212223166162021417 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** An array-based queue implementation ** Author: hwxi AT cs DOT bu DOT edu ** Time: March, 2011 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) %{# #include "libats/CATS/linqueue_arr.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) // // a: item type // m: maximal capacity // n: current size // absviewt@ype QUEUE ( a:viewt@ype+, m: int, n: int ) = $extype "atslib_linqueue_arr_QUEUE" viewtypedef QUEUE0 (a:viewt@ype) = [m,n:int] QUEUE (a, m, n) (* ****** ****** *) prfun lemma_queue_param {a:viewt@ype} {m,n:int} (x: &QUEUE (a, m, n)): [0 <= n; n <= m] void // end of [lemma_queue_param] (* ****** ****** *) fun queue_cap {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> size_t m fun queue_size {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> size_t n (* ****** ****** *) fun queue_is_empty {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> bool (n <= 0) fun queue_isnot_empty {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> bool (n > 0) fun queue_is_full {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> bool (m <= n) fun queue_isnot_full {a:viewt@ype} {m,n:int} (q: &QUEUE (a, m, n)):<> bool (m > n) (* ****** ****** *) // // HX: initializing to a queue of capacity [m] // fun{a:viewt@ype} queue_initialize {m:nat} (q: &QUEUE0(a)? >> QUEUE (a, m, 0), m: size_t m):<> void // end of [queue_initialize] // // HX: initializing to a queue of capacity [m] // fun queue_initialize_tsz {a:viewt@ype} {m:nat} ( q: &QUEUE0(a)? >> QUEUE (a, m, 0), m: size_t m, tsz: sizeof_t a ) :<> void = "atslib_linqueue_arr_queue_initialize_tsz" // end of [queue_initialize_tsz] (* ****** ****** *) // // HX: uninitializing a queue of nonlinear elements // fun queue_uninitialize {a:t@ype} {m,n:int} {l:addr} ( q: &QUEUE (a, m, n) >> QUEUE0(a)? ) :<> void = "atslib_linqueue_arr_queue_uninitialize" // end of [queue_uninitialize] // // HX: uninitializeing a queue that is empty // fun queue_uninitialize_vt {a:viewt@ype} {m:int} {l:addr} ( q: &QUEUE (a, m, 0) >> QUEUE0(a)? ) :<> void // end of [queue_uninitialize_vt] (* ****** ****** *) fun{a:t@ype} queue_get_elt_at {m,n:int} {i:nat | i < n} ( q: &QUEUE (a, m, n), i: size_t i ) :<> a // end of [queue_get_elt_at] fun{a:t@ype} queue_set_elt_at {m,n:int} {i:nat | i < n} ( q: &QUEUE (a, m, n), i: size_t i, x: a ) :<> void // end of [queue_set_elt_at] (* ****** ****** *) fun{a:viewt@ype} queue_insert (*last*) {m,n:int | m > n} ( q: &QUEUE (a, m, n) >> QUEUE (a, m, n+1), x: a ) :<> void // end of [queue_insert] fun{a:viewt@ype} queue_insert_many {m,n:int} {k:nat | n+k <= m} ( q: &QUEUE (a, m, n) >> QUEUE (a, m, n+k) , k: size_t k , xs: &(@[a][k]) >> @[a?!][k] ) :<> void // end of [queue_insert_many] (* ****** ****** *) fun{a:viewt@ype} queue_remove (*first*) {m,n:int | n > 0} ( q: &QUEUE (a, m, n) >> QUEUE (a, m, n-1) ) :<> a // end of [queue_remove] fun{a:viewt@ype} queue_remove_many {m,n:int} {k:nat | k <= n} ( q: &QUEUE (a, m, n) >> QUEUE (a, m, n-k) , k: size_t k , xs: &(@[a?][k]) >> @[a][k] ) :<> void // end of [queue_remove_many] (* ****** ****** *) fun{a:t@ype} queue_clear {m,n1:int} {n2:nat | n2 <= n1} ( q: &QUEUE (a, m, n1) >> QUEUE (a, m, n1-n2), n2: size_t n2 ) :<> void // end of [queue_clear] fun queue_clear_all {a:t@ype} {m,n:int} (s: &QUEUE (a, m, n) >> QUEUE (a, m, 0)):<> void // end of [queue_clear_all] (* ****** ****** *) fun{a:t@ype} queue_copyout {m,n:int} {i,k:nat | i+k <= n} ( q: &QUEUE (a, m, n) , i: size_t i , k: size_t k , xs: &(@[a?][k]) >> @[a][k] ) :<> void // end of [queue_copyout] (* ****** ****** *) fun{a:viewt@ype} queue_update_capacity {m1,n:int} {m2:nat | n <= m2} {l:addr} ( q: &QUEUE (a, m1, n) >> QUEUE (a, m2, n) , m2: size_t (m2) ) : void // end of [queue_update_capcity] (* ****** ****** *) (* end of [linqueue_arr.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/lockref_spin.sats0000664000175000017500000000540112223166162021377 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) %{# #include "libats/CATS/lockref_spin.cats" %} // end of [%{#] (* ****** ****** *) abstype lock_view_type (v:view, l:addr) stadef lock = lock_view_type typedef lock0 (v:view) = [l:addr] lock (v, l) typedef lock1 (v:view) = [l:addr | l > null] lock (v, l) (* ****** ****** *) castfn ptr_of_lock {v:view} {l:addr} (x: lock (v, l)):<> ptr (l) // end of [ptr_of_lock] (* ****** ****** *) fun lockref_create_locked {v:view} ( pshared: int ) : lock0 (v) = "atslib_lockref_create_locked" // end of [lockref_create_locked] fun lockref_create_unlocked {v:view} ( pf: !v >> option_v (v, l==null) | pshared: int ) : #[l:addr] lock (v, l) = "atslib_lockref_create_unlocked" // end of [lockref_create_unlocked] (* ****** ****** *) fun lockref_acquire {v:view} {l:agz} (x: lock (v, l)): (v | void) = "mac#atslib_lockref_acquire" // end of [lockref_acquire] fun lockref_acquire_try {v:view} {l:agz} (x: lock (v, l)): [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_lockref_acquire_try" // end of [lockref_acquire_try] fun lockref_release {v:view} {l:agz} (pf: v | x: lock (v, l)): void = "mac#atslib_lockref_release" // end of [lockref_release] (* ****** ****** *) (* end of [lockref_spin.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/lockptr_spin.sats0000664000175000017500000000610312223166162021430 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) // // HX-2011-12-10: this one is implemented on the top of pthread spinlock // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) %{# #include "libats/CATS/lockptr_spin.cats" %} // end of [%{#] (* ****** ****** *) abstype lock_view_viewtype (v:view, l:addr) stadef lock = lock_view_viewtype viewtypedef lock0 (v:view) = [l:addr] lock (v, l) viewtypedef lock1 (v:view) = [l:addr | l > null] lock (v, l) (* ****** ****** *) castfn ptr_of_lock {v:view} {l:addr} (x: !lock (v, l)):<> ptr (l) // end of [ptr_of_lock] praxi lock_free_null {v:view} (x: lock (v, null)):<> ptr (null) // end of [lock_free_null] (* ****** ****** *) fun lockptr_create_locked {v:view} ( pshared: int ) : lock0 (v) = "atslib_lockptr_create_locked" // end of [lockptr_create_locked] fun lockptr_create_unlocked {v:view} ( pf: !v >> option_v (v, l==null) | pshared: int ) : #[l:addr] lock (v, l) = "atslib_lockptr_create_unlocked" // end of [lockptr_create_unlocked] (* ****** ****** *) fun lockptr_destroy {v:view} (x: lock1 (v)): (v | void) // end of [lockptr_destroy] (* ****** ****** *) fun lockptr_acquire {v:view} {l:agz} (x: !lock (v, l)): (v | void) = "mac#atslib_lockptr_acquire" // end of [lockptr_acquire] fun lockptr_acquire_try {v:view} {l:agz} (x: lock (v, l)): [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_lockptr_acquire_try" // end of [lockptr_acquire_try] fun lockptr_release {v:view} {l:agz} (pf: v | x: !lock (v, l)): void = "mac#atslib_lockptr_release" // end of [lockptr_release] (* ****** ****** *) (* end of [lockptr_spin.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funmap_avltree.sats0000664000175000017500000001113112223166162021726 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) abstype map_t0ype_t0ype_type (key:t@ype, itm:t@ype+) stadef map = map_t0ype_t0ype_type (* ****** ****** *) typedef cmp (key:t@ype) = (key, key) - int fun{key:t@ype} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) // // HX: cross-module inlining is supported by templatization // fun{} funmap_make_nil {key,itm:t@ype} ():<> map (key, itm) // fun{} funmap_is_nil {key,itm:t@ype} (m: map (key, itm)):<> bool fun{} funmap_isnot_nil {key,itm:t@ype} (m: map (key, itm)):<> bool // (* ****** ****** *) // // HX: this function is O(n)-time and non-tail-recursive // fun{key,itm:t@ype} funmap_size (m: map (key, itm)):<> size_t // // HX: this function is O(1) // for gathering stats // fun{key,itm:t@ype} funmap_height (m: map (key, itm)):<> Nat (* ****** ****** *) fun{ key,itm:t@ype } funmap_search ( m: map (key, itm) , k0: key , cmp: cmp key , res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [funmap_search] fun{ key,itm:t@ype } funmap_search_opt (m: map (key, itm), k0: key, cmp: cmp key) :<> Option_vt (itm) // end of [funmap_search_opt] (* ****** ****** *) // // HX-2010-03-25: // if [k0] occurs in [m], [x0] replaces the original value associated with [k0] // fun{key,itm:t@ype} funmap_insert ( m: &map (key, itm) , k0: key , x0: itm , cmp: cmp key ) :<> bool(*[k0] alreay exists in [m]*) // end of [funmap_insert] fun{key,itm:t@ype} funmap_insert_clo ( m: &map (key, itm) , k0: key , x0: itm , f: &(itm(*new*), itm) - itm , cmp: cmp key ) :<> void // end of [funmap_insert_clo] (* ****** ****** *) fun{key,itm:t@ype} funmap_takeout ( m: &map (key, itm) , k0: key , cmp: cmp key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [funmap_takeout] fun{key,itm:t@ype} funmap_remove ( m: &map (key, itm) , k0: key , cmp: cmp key ) :<> bool(*removed/not: true/false*) // end of [funmap_remove] (* ****** ****** *) fun{key,itm:t@ype} funmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: map (key, itm) , f: (!v | key, itm, !vt) - void , env: !vt ) :<> void // end of [funmap_foreach_funenv] fun{key,itm:t@ype} funmap_foreach_fun ( xs: map (key, itm) , f: (key, itm) - void ) :<> void // end of [funmap_foreach_fun] fun{key,itm:t@ype} funmap_foreach_vclo {v:view} ( pf: !v | xs: map (key, itm) , f: &(!v | key, itm) - void ) :<> void // end of [funmap_foreach_vclo] fun{key,itm:t@ype} funmap_foreach_cloref ( xs: map (key, itm) , f: (key, itm) - void ) : void // end of [funmap_foreach_cloref] (* ****** ****** *) fun{key,itm:t@ype} funmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: map (key, itm) , f: (!v | key, itm, !vt) - void , env: !vt ) :<> void // end of [funmap_rforeach_funenv] (* ****** ****** *) fun{key,itm:t@ype} funmap_listize (xs: map (key, itm)):<> List_vt @(key, itm) (* ****** ****** *) (* end of [funmap_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/parworkshop.sats0000664000175000017500000001143512223166162021304 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Start Time: March, 2010 ** *) (* ****** ****** *) %{# #include "libats/CATS/parworkshop.cats" %} // end of [%{#] (* ****** ****** *) absviewtype WORKSHOPptr (a:viewt@ype, l:addr) // boxed linear type viewtypedef WORKSHOPptr (a:viewt@ype) = [l:agz] WORKSHOPptr (a, l) // note that [l > null] always holds // end of [WORKSHOPptr] (* ****** ****** *) // // HX-2010-03: // the meaning of the return status of [fwork]: // return status > 0 : the worker is to continue // return status = 0 : the worker is to quit // return status = ~1 : the worker is to pause // this is uncommon // fun{a:viewt@ype} workshop_make {n:pos} ( qsz: size_t n , fwork: {l:agz} (!WORKSHOPptr (a, l), &a >> a?) - int ) : WORKSHOPptr a // end of [workshop_make] fun workshop_make_tsz {a:viewt@ype} {n:pos} ( qsz: size_t n , fwork: {l:agz} (!WORKSHOPptr (a, l), &a >> a?) - int , tsz: sizeof_t a ) : WORKSHOPptr a = "atslib_parworkshop_workshop_make_tsz" // end of [workshop_make_tsz] (* ****** ****** *) // // locking/unlocking // fun workshop_get_nworker {a:viewt@ype} {l:agz} ( ws: !WORKSHOPptr (a, l) ) :<> int = "atslib_parworkshop_workshop_get_nworker" // end of [workshop_get_nworker] // // locking/unlocking // fun workshop_get_npaused {a:viewt@ype} {l:agz} ( ws: !WORKSHOPptr (a, l) ) :<> int = "atslib_parworkshop_workshop_get_npaused" // end of [workshop_get_npaused] // // locking/unlocking // fun workshop_get_nblocked {a:viewt@ype} {l:agz} ( ws: !WORKSHOPptr (a, l) ) :<> int = "atslib_parworkshop_workshop_get_nblocked" // end of [workshop_get_nblocked] (* ****** ****** *) fun{a:viewt@ype} workshop_add_worker {l:agz} (ws: !WORKSHOPptr (a, l)): int(*err*) // end of [workshop_add_worker] fun{a:viewt@ype} workshop_add_nworker {l:agz} {n:nat} (ws: !WORKSHOPptr (a, l), n: int n): int(*err*) // end of [workshop_add_nworker] (* ****** ****** *) fun{a:viewt@ype} workshop_insert_work {l:agz} (ws: !WORKSHOPptr (a, l), work: a): void // end of [workshop_insert_work] fun{a:viewt@ype} workshop_remove_work {l:agz} (ws: !WORKSHOPptr (a, l)): a (* ****** ****** *) // // HX: wait until all workers have quit // fun workshop_wait_quit_all {a:viewt@ype} {l:agz} (ws: !WORKSHOPptr (a, l)): void // end of [workshop_wait_quit_all] (* ****** ****** *) // // HX: wait until all workers have paused // fun workshop_wait_paused_all {a:viewt@ype} {l:agz} (ws: !WORKSHOPptr (a, l)): void // end of [workshop_wait_paused_all] // // HX: resume all the workers that are currently paused // fun workshop_resume_paused_all {a:viewt@ype} {l:agz} (ws: !WORKSHOPptr (a, l)): void // end of [workshop_resume_paused_all] (* ****** ****** *) // // HX: wait until all workers have blocked // fun workshop_wait_blocked_all {a:viewt@ype} {l:agz} (ws: !WORKSHOPptr (a, l)): void // end of [workshop_wait_blocked_all] (* ****** ****** *) // // HX-2010-03-31: // freeing a workshop must wait until all workers quit // fun workshop_free {a:t@ype} {l:agz} ( ws: WORKSHOPptr (a, l) ) : void = "atslib_parworkshop_workshop_free" // end of [workshop_free] // // HX: // an exception is raised // if there are still linear works left while there are no workers. // fun workshop_free_vt_exn {a:viewt@ype} {l:agz} ( ws: WORKSHOPptr (a, l) ) : void = "atslib_parworkshop_workshop_free_vt_exn" // end of [workshop_free_vt_exn] (* ****** ****** *) (* end of [parworkshop.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/biarray.sats0000664000175000017500000000701512223166162020355 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Bidirectional Arrays (arrays moving from left to right and vice versa) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) absview biarray_v (a:viewt@ype, n:int, lbeg:addr, lend:addr) (* ****** ****** *) prfun array_v_of_biarray_v {a:viewt@ype} {n:int} {l1,l2:addr} (pf: biarray_v (a, n, l1, l2)): array_v (a, n, l1) // end of [array_v_of_biarray_v] prfun biarray_v_of_array_v {a:viewt@ype} {n:int} {l:addr} {ofs:int} ( pfmul: MUL (n, sizeof(a), ofs), pfarr: array_v (a, n, l) ) : biarray_v (a, n, l, l+ofs) (* ****** ****** *) prfun biarray_v_offset {a:viewt@ype} {n:int} {l1,l2:addr} (pf: !biarray_v (a, n, l1, l2)): MUL (n, sizeof(a), l2-l1) // end of [biarray_v_offset] (* ****** ****** *) prfun biarray_v_nil {a:viewt@ype} {l:addr} (): biarray_v (a, 0, l, l) // end of [biarray_v_nil] prfun biarray_v_unnil {a:viewt@ype} {l1,l2:addr} (pf: biarray_v (a, 0, l1, l2)): [l1==l2] void // end of [biarray_v_unnil] (* ****** ****** *) prfun biarray_v_sing {a:viewt@ype} {l:addr} (pf: a @ l): biarray_v (a, 1, l, l+sizeof(a)) // end of [biarray_v_sing] prfun biarray_v_unsing {a:viewt@ype} {l1,l2:addr} (pf: biarray_v (a, 1, l1, l2)): a @ l1 // end of [biarray_v_unsing] (* ****** ****** *) prfun biarray_v_cons {a:viewt@ype} {n:nat} {lbeg,lend:addr} ( pf1: a @ lbeg, pf2: biarray_v (a, n, lbeg+sizeof(a), lend) ) : biarray_v (a, n+1, lbeg, lend) // end of [biarray_v_cons] prfun biarray_v_uncons {a:viewt@ype} {n:pos} {lbeg,lend:addr} (pf: biarray_v (a, n, lbeg, lend)) : ( a @ lbeg, biarray_v (a, n-1, lbeg+sizeof(a), lend) ) // end of [biarray_v_uncons] (* ****** ****** *) prfun biarray_v_snoc {a:viewt@ype} {n:nat} {lbeg,lend:addr} ( pf1: biarray_v (a, n, lbeg, lend), pf2: a @ lend ) : biarray_v (a, n+1, lbeg, lend+sizeof(a)) prfun biarray_v_unsnoc {a:viewt@ype} {n:pos} {lbeg,lend:addr} (pf: biarray_v (a, n, lbeg, lend)) : ( biarray_v (a, n-1, lbeg, lend-sizeof(a)), a @ lend-sizeof(a) ) // end of [biarray_v_unsnoc] (* ****** ****** *) (* end of [biarray.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linset_listord.sats0000664000175000017500000001134612223166162021764 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A linear map implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: February 17, 2012 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) absviewtype set_t0ype_viewtype (elt: t@ype+) stadef set = set_t0ype_viewtype (* ****** ****** *) typedef cmp (a:t@ype) = (a, a) - int fun{a:t@ype} compare_elt_elt (x1: a, x2: a, cmp: cmp (a)):<> int (* ****** ****** *) fun{} linset_make_nil {a:t@ype} ():<> set (a) fun{a:t@ype} linset_make_sing (x0: a):<> set (a) // singleton set (* ****** ****** *) fun{} linset_is_empty {a:t@ype} (xs: !set a):<> bool fun{} linset_isnot_empty {a:t@ype} (xs: !set a):<> bool (* ****** ****** *) // // HX: the time complexity of this function is O(n), where n is fun{a:t@ype} linset_size (xs: !set a):<> size_t // the size of the set // (* ****** ****** *) fun{a:t@ype} linset_is_member (xs: !set a, x0: a, cmp: cmp a):<> bool fun{a:t@ype} linset_isnot_member (xs: !set a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} linset_free (xs: set (a)):<> void fun{a:t@ype} linset_copy (xs: !set (a)):<> set (a) (* ****** ****** *) fun{a:t@ype} linset_insert ( xs: &set (a), x0: a, cmp: cmp a ) :<> bool(*[x0] alreay exists in [xs]*) // end of [linset_insert] (* ****** ****** *) fun{a:t@ype} linset_remove ( xs: &set (a), x0: a, cmp: cmp (a) ) :<> bool(*[x0] removed/not: true/false*) // end of [linset_remove] (* ****** ****** *) // // HX: choosing an element in an unspecified manner // fun{a:t@ype} linset_choose ( xs: !set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [linset_choose] // // HX: removing an element chosen in an unspecified manner // fun{a:t@ype} linset_choose_out ( xs: &set a >> set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [linset_choose_out] // (* ****** ****** *) fun{a:t@ype} linset_union (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_intersect (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_diff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} linset_symdiff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) (* ****** ****** *) fun{a:t@ype} linset_is_subset // xs2 contains xs1 (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool // end of [linset_is_subset] fun{a:t@ype} linset_is_supset // xs1 contains xs2 (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool // end of [linset_is_supset] fun{a:t@ype} linset_is_equal (xs1: !set a, xs2: !set a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} linset_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: !set (a) , f: (!v | a, !vt) - void , env: !vt ) :<> void // end of [linset_foreach_funenv] fun{a:t@ype} linset_foreach_fun ( xs: !set (a) , f: (a) - void ) :<> void // end of [linset_foreach_fun] fun{a:t@ype} linset_foreach_vclo {v:view} ( pf: !v | xs: !set (a) , f: &(!v | a) - void ) :<> void // end of [linset_foreach_vclo] fun{a:t@ype} linset_foreach_cloref ( xs: !set (a) , f: (a) - void ) : void // end of [linset_foreach_cloref] (* ****** ****** *) fun{a:t@ype} linset_listize (xs: !set (a)):<> List_vt (a) fun{a:t@ype} linset_listize_free (xs: set (a)):<> List_vt (a) (* ****** ****** *) (* end of [linset_listord.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/funset_avltree.sats0000664000175000017500000001121112223166162021743 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May, 2011 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) abstype set_t0ype_type (elt: t@ype+) stadef set = set_t0ype_type (* ****** ****** *) typedef cmp (elt:t@ype) = (elt, elt) - int fun{elt:t@ype} compare_elt_elt (x1: elt, x2: elt, cmp: cmp elt):<> int (* ****** ****** *) fun{} funset_make_nil {a:t@ype} ():<> set (a) fun{a:t@ype} funset_make_sing (x0: a):<> set (a) // singleton set fun{a:t@ype} funset_make_list (xs: List a, cmp: cmp a):<> set (a) (* ****** ****** *) fun{} funset_is_nil {a:t@ype} (xs: set a):<> bool fun{} funset_isnot_nil {a:t@ype} (xs: set a):<> bool (* ****** ****** *) // // HX: the time complexity of this function is O(n), where n is fun{a:t@ype} funset_size (xs: set a):<> size_t // the size of the set // // HX: the time complexity of this function is O(n); it is for fun{a:t@ype} funset_height (xs: set a):<> size_t // gathering stats // (* ****** ****** *) fun{a:t@ype} funset_is_member (xs: set a, x0: a, cmp: cmp a):<> bool fun{a:t@ype} funset_isnot_member (xs: set a, x0: a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} funset_insert ( xs: &set (a), x0: a, cmp: cmp a ) :<> bool(*[x0] alreay exists in [xs]*) // end of [funset_insert] (* ****** ****** *) fun{a:t@ype} funset_remove ( xs: &set (a), x0: a, cmp: cmp (a) ) :<> bool(*[x0] removed/not: true/false*) // end of [funset_remove] (* ****** ****** *) // // HX: choose an element in an unspecified manner // fun{a:t@ype} funset_choose ( xs: set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [funset_choose] // // HX: take out an element in an unspecified manner // fun{a:t@ype} funset_takeout ( xs: &set a >> set a, x: &a? >> opt (a, b) ) : #[b:bool] bool (b) // end of [funset_takeout] // (* ****** ****** *) fun{a:t@ype} funset_union (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} funset_intersect (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} funset_diff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) fun{a:t@ype} funset_symdiff (xs1: set a, xs2: set a, cmp: cmp a):<> set (a) (* ****** ****** *) fun{a:t@ype} funset_is_subset (xs1: set a, xs2: set a, cmp: cmp a):<> bool // end of [funset_is_subset] fun{a:t@ype} funset_is_supset (xs1: set a, xs2: set a, cmp: cmp a):<> bool // end of [funset_is_supset] fun{a:t@ype} funset_is_equal (xs1: set a, xs2: set a, cmp: cmp a):<> bool (* ****** ****** *) fun{a:t@ype} funset_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | xs: set (a) , f: (!v | a, !vt) - void , env: !vt ) :<> void // end of [funset_foreach_funenv] fun{a:t@ype} funset_foreach_fun ( xs: set (a) , f: (a) - void ) :<> void // end of [funset_foreach_fun] fun{a:t@ype} funset_foreach_vclo {v:view} ( pf: !v | xs: set (a) , f: &(!v | a) - void ) :<> void // end of [funset_foreach_vclo] fun{a:t@ype} funset_foreach_cloref ( xs: set (a) , f: (a) - void ) : void // end of [funset_foreach_cloref] (* ****** ****** *) fun{a:t@ype} funset_listize (xs: set (a)):<> List_vt (a) (* ****** ****** *) (* end of [funset_avltree.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/linmap_skiplist.sats0000664000175000017500000001210512223166162022122 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Adam Udi *) (* Authoremail: adamudi AT bu DOT edu *) (* Author: Hongwei Xi *) (* Authoremail: hwxi AT cs DOT bu DOT edu *) (* Start time: December, 2012 *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) absviewtype map_viewtype (key:t@ype, itm:viewt@ype+) stadef map = map_viewtype (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) fun linmap_random_initize (): void (* ****** ****** *) typedef cmp (key:t@ype) = (key, key) - int fun{key:t@ype} compare_key_key (x1: key, x2: key, cmp: cmp key):<> int (* ****** ****** *) fun linmap_make_nil {key:t0p;itm:vt0p} ():<> map (key, itm) // end of [linmap_make_nil] (* ****** ****** *) fun linmap_is_nil {key:t0p;itm:vt0p} (map: !map (key, itm)):<> bool // end of [linmap_is_nil] fun linmap_isnot_nil {key:t0p;itm:vt0p} (map: !map (key, itm)):<> bool // end of [linmap_isnot_nil] (* ****** ****** *) fun linmap_size {key:t0p;itm:vt0p} (map: !map (key, itm)):<> size_t // end of [linmap_size] (* ****** ****** *) fun{ key:t0p;itm:t0p } linmap_search ( map: !map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) : #[b:bool] bool (b) // endfun fun{ key:t0p;itm:vt0p } linmap_search_ref (map: !map (key, itm), k0: key, cmp: cmp key): Ptr // end of [linmap_search_ref] fun{ key:t0p;itm:t0p } linmap_search_opt (map: !map (key, itm), k0: key, cmp: cmp key): Option_vt (itm) // end of [linmap_search_opt] (* ****** ****** *) // // HX-2012-12: // if [k0] occurs in [map], [x0] replaces the // item associated with [k0] in [map] while the // item is stored in [res] instead. // fun{ key:t0p;itm:vt0p } linmap_insert ( map: &map (key, itm) , k0: key, x0: itm, cmp: cmp key, res: &itm? >> opt (itm, b) ) : #[b:bool] bool (b) // endfun (* ****** ****** *) // // HX-2012-12: // insertion always happens regardless whether // [k0] is associated with some item in [map] // fun{ key:t0p;itm:vt0p } linmap_insert_any (map: &map (key, itm), k0: key, x0: itm, cmp: cmp key): void // end of [linmap_insert_any] (* ****** ****** *) fun{ key:t0p;itm:vt0p } linmap_takeout ( map: &map (key, itm) , k0: key, cmp: cmp key, res: &itm? >> opt (itm, b) ) : #[b:bool] bool (b) // endfun fun{ key:t0p;itm:vt0p } linmap_takeout_opt (map: &map (key, itm), k0: key, cmp: cmp key): Option_vt (itm) // end of [linmap_takeout_opt] fun{ key:t0p;itm:t0p } linmap_remove (map: &map (key, itm), k0: key, cmp: cmp key): bool // end of [linmap_remove] (* ****** ****** *) // // HX: note the [foreach] can be used as [clear] // fun{key:t0p;itm:vt0p} linmap_foreach_funenv {v:view} {vt:viewtype} ( pfv: !v | m: !map (key, itm) , f: (!v | key, &itm, !vt) - void , env: !vt ) :<> void // end of [linmap_foreach_funenv] fun{key:t0p;itm:vt0p} linmap_foreach_fun ( m: !map (key, itm), f: (key, &itm) - void ) :<> void // end of [linmap_foreach_fun] fun{key:t0p;itm:vt0p} linmap_foreach_vclo {v:view} ( pfv: !v | m: !map (key, itm), f: &(!v | key, &itm) - void ) :<> void // end of [linmap_foreach_vclo] fun{key:t0p;itm:vt0p} linmap_foreach_cloref (m: !map (key, itm), f: (key, &itm) - void): void // end of [linmap_foreach_cloref] (* ****** ****** *) fun{ key:t0p;itm:t0p } linmap_free (m: map (key, itm)):<> void // // HX: a linear map can be properly freed only if it is empty // fun{ key:t0p;itm:vt0p } linmap_free_vt ( m: !map (key, itm) >> opt (map (key, itm), b) ) :<> #[b:bool] bool b(*~freed*) // end of [linmap_free_vt] (* ****** ****** *) (* // // HX: listization is done ascendingly // *) // fun{ key:t0p;itm:t0p } linmap_listize (map: !map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize] fun{ key:t0p;itm:vt0p } linmap_listize_free (map: map (key, itm)):<> List_vt @(key, itm) // end of [linmap_listize_free] (* ****** ****** *) (* end of [linmap_skiplist.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/ilistp.sats0000664000175000017500000002724712223166162020241 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // HX: reasoning about integer sequences // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/imsetp.sats" // for handling integer multiset (* ****** ****** *) datasort ilist = | ilist_nil of () | ilist_cons of (int, ilist) // end of [ilist] stadef ilist_sing (x:int): ilist = ilist_cons (x, ilist_nil) (* ****** ****** *) absprop MSETIZE (ilist, imset) (* ****** ****** *) dataprop ilisteq (ilist, ilist) = | ilisteq_nil ( ilist_nil, ilist_nil ) of () | {x:int} {xs1,xs2:ilist} ilisteq_cons ( ilist_cons (x, xs1), ilist_cons (x, xs2) ) of ( ilisteq (xs1, xs2) ) // end of [ilisteq_cons] // end of [ilisteq] (* ****** ****** *) dataprop ILISTEQ (ilist, ilist) = {xs:ilist} ILISTEQ (xs, xs) of () // end of [ILISTEQ] prfun ilisteq_elim {xs1,xs2:ilist} (pf: ilisteq (xs1, xs2)): ILISTEQ (xs1, xs2) // end of [ilisteq_elim] (* ****** ****** *) dataprop ISCONS (ilist) = {x:int}{xs:ilist} ISCONS (ilist_cons (x, xs)) // end of [ISCONS] dataprop ISEMP (ilist, bool) = | ISEMPnil (ilist_nil, true) | {x:int} {xs:ilist} ISEMPcons (ilist_cons (x, xs), false) // end of [ISEMP] (* ****** ****** *) dataprop LENGTH (ilist, int) = | LENGTHnil (ilist_nil, 0) of () | {x:int} {xs:ilist} {n:nat} LENGTHcons (ilist_cons (x, xs), n+1) of LENGTH (xs, n) // end of [LENGTH] prfun length_istot {xs:ilist} (): [n:nat] LENGTH (xs, n) prfun length_isfun {xs:ilist} {n1,n2:int} (pf1: LENGTH (xs, n1), pf2: LENGTH (xs, n2)): [n1==n2] void // end of [length_isfun] prfun length_isnat {xs:ilist} {n:int} (pf: LENGTH (xs, n)): [n>=0] void // end of [length_isnat] prfun length_msize {xs:ilist;mxs:imset} {n:int} (pf1: MSETIZE (xs, mxs), pf2: LENGTH (xs, n)): MSIZE (mxs, n) // end of [length_msize] (* ****** ****** *) dataprop SNOC (ilist, int, ilist) = | {x:int} SNOCnil (ilist_nil, x, ilist_sing (x)) of () | {x0:int} {xs1:ilist} {x:int} {xs2:ilist} SNOCcons (ilist_cons (x0, xs1), x, ilist_cons (x0, xs2)) of SNOC (xs1, x, xs2) // end of [SNOC] prfun snoc_istot {xs:ilist} {x:int} (): [xsx:ilist] SNOC (xs, x, xsx) prfun snoc_isfun {xs:ilist} {x:int} {xsx1,xsx2:ilist} (pf1: SNOC (xs, x, xsx1), pf2: SNOC (xs, x, xsx2)): ILISTEQ (xsx1, xsx2) // end of [snoc_isfun] prfun snoc_length_lemma {xs:ilist} {x:int} {xsx:ilist} {n:nat} (pf1: SNOC (xs, x, xsx), pf2: LENGTH (xs, n)): LENGTH (xsx, n+1) // end of [snoc_length_lemma] (* ****** ****** *) dataprop APPEND (ilist, ilist, ilist) = | {ys:ilist} APPENDnil (ilist_nil, ys, ys) of () | {x:int} {xs:ilist} {ys:ilist} {zs:ilist} APPENDcons (ilist_cons (x, xs), ys, ilist_cons (x, zs)) of APPEND (xs, ys, zs) // end of [APPEND] prfun append_istot {xs,ys:ilist} (): [zs:ilist] APPEND (xs, ys, zs) prfun append_isfun {xs,ys:ilist} {zs1,zs2:ilist} (pf1: APPEND (xs, ys, zs1), pf2: APPEND (xs, ys, zs2)): ILISTEQ (zs1, zs2) // end of [append_isfun] (* ****** ****** *) prfun append_unit1 {xs:ilist} (): APPEND (ilist_nil, xs, xs) prfun append_unit2 {xs:ilist} (): APPEND (xs, ilist_nil, xs) prfun append_sing {x:int}{xs:ilist} (): APPEND (ilist_sing(x), xs, ilist_cons (x, xs)) // end of [append_sing] (* ****** ****** *) prfun append_length_lemma {xs1,xs2:ilist} {xs:ilist} {n1,n2:int} ( pf: APPEND (xs1, xs2, xs), pf1len: LENGTH (xs1, n1), pf2len: LENGTH (xs2, n2) ) : LENGTH (xs, n1+n2) // end of [append_length_lemma] prfun append_snoc_lemma {xs1:ilist} {x:int} {xs2:ilist} {xs1x:ilist} {xs:ilist} ( pf1: APPEND (xs1, ilist_cons (x, xs2), xs) , pf2: SNOC (xs1, x, xs1x) ) : APPEND (xs1x, xs2, xs) // end of [append_snoc_lemma] (* ****** ****** *) dataprop REVAPP (ilist, ilist, ilist) = | {ys:ilist} REVAPPnil (ilist_nil, ys, ys) of () | {x:int} {xs:ilist} {ys:ilist} {zs:ilist} REVAPPcons (ilist_cons (x, xs), ys, zs) of REVAPP (xs, ilist_cons (x, ys), zs) // end of [REVAPP] (* ****** ****** *) dataprop NTH (x0:int, ilist, int) = | {xs:ilist} NTHbas (x0, ilist_cons (x0, xs), 0) | {x:int} {xs:ilist} {n:nat} NTHind (x0, ilist_cons (x, xs), n+1) of NTH (x0, xs, n) // end of [NTH] // // HX: reverse NTH // dataprop RNTH (x0:int, ilist, int) = | {xs:ilist} {n:nat} RNTHbas (x0, ilist_cons (x0, xs), n) of LENGTH (xs, n) | {x:int} {xs:ilist} {n:nat} RNTHind (x0, ilist_cons (x, xs), n) of RNTH (x0, xs, n) // end of [RNTH] (* ****** ****** *) prfun nth_rnth_lemma {x:int} {xs:ilist} {n:int} {i:nat | i < n} (pf1: NTH (x, xs, i), pf2: LENGTH (xs, n)): RNTH (x, xs, n-1-i) // end of [nth_rnth_lemma] prfun rnth_nth_lemma {x:int} {xs:ilist} {n:int} {i:nat | i < n} (pf1: RNTH (x, xs, i), pf2: LENGTH (xs, n)): NTH (x, xs, n-1-i) // end of [rnth_nth_lemma] (* ****** ****** *) stadef b2i = int_of_bool (* ****** ****** *) dataprop MSETCNT (x0:int, ilist, int) = | MSETCNTnil (x0, ilist_nil, 0) of () | {x:int} {xs:ilist} {n:nat} MSETCNTcons (x0, ilist_cons (x, xs), n+b2i(x0==x)) of MSETCNT (x0, xs, n) // end of [MSETCNT] prfun msetcnt_istot {x0:int} {xs:ilist} (): [n:nat] MSETCNT (x0, xs, n) prfun msetcnt_isfun {x0:int} {xs:ilist} {n1,n2:int} ( pf1: MSETCNT (x0, xs, n1), pf2: MSETCNT (x0, xs, n2) ) : [n1==n2] void // end of [msetcnt_isfun] prfun msetcnt_first {x:int} {xs:ilist} (): [n:pos] MSETCNT (x, ilist_cons (x, xs), n) // end of [msetcnt_first] (* ****** ****** *) prfun nth_msetcnt_lemma {x:int} {xs:ilist} {i:nat} (pf: NTH (x, xs, i)): [n:pos] MSETCNT (x, xs, n) // end of [nth_msetcnt_lemma] prfun msetcnt_nth_lemma {x:int} {xs:ilist} {n:pos} (pf: MSETCNT (x, xs, n)): [i:nat] NTH (x, xs, i) // end of [msetcnt_nth_lemma] (* ****** ****** *) dataprop INSERT ( x0:int, ilist, int, ilist ) = // INSERT (x0, xs, i, ys): insert x0 in xs at i = ys | {xs:ilist} INSERTbas ( x0, xs, 0, ilist_cons (x0, xs) ) of () // end of [INSERTbas] | {x:int} {xs:ilist} {i:nat} {ys:ilist} INSERTind ( x0, ilist_cons (x, xs), i+1, ilist_cons (x, ys) ) of INSERT (x0, xs, i, ys) // end of [INSERTind] // end of [INSERT] prfun insert_length_lemma {x0:int} {xs:ilist} {i:int} {ys:ilist} {n:nat} (pf1: INSERT (x0, xs, i, ys), pf2: LENGTH (xs, n)): LENGTH (ys, n+1) // end of [insert_length_lemma] prfun nth_insert_lemma {x:int} {xs:ilist} {n:nat} (pf: NTH (x, xs, n)): [ys:ilist] INSERT (x, ys, n, xs) // end of [nth_insert_lemma] (* ****** ****** *) propdef PERMUTE (xs1:ilist, xs2:ilist) = {x0:int} {n:nat} MSETCNT (x0, xs1, n) - MSETCNT (x0, xs2, n) // end of [PERMUTE] prfun permute_refl {xs:ilist} (): PERMUTE (xs, xs) prfun permute_symm {xs1,xs2:ilist} (pf: PERMUTE (xs1, xs2)): PERMUTE (xs2, xs1) prfun permute_trans {xs1,xs2,xs3:ilist} (pf1: PERMUTE (xs1, xs2), pf2: PERMUTE (xs2, xs3)): PERMUTE (xs1, xs3) prfun permute_insert_lemma {x:int} {xs:ilist} {ys:ilist} (pf: PERMUTE (ilist_cons (x, xs), ys)): [ys1:ilist;i:nat] INSERT (x, ys1, i, ys) // end of [permute_insert_lemma] prfun permute_length_lemma {xs1,xs2:ilist} {n:nat} (pf1: PERMUTE (xs1, xs2), pf2: LENGTH (xs1, n)): LENGTH (xs2, n) // end of [permute_length_lemma] prfun permute_seteq_intr {xs1,xs2:ilist} {mxs:imset} (pf1: MSETIZE (xs1, mxs), pf2: MSETIZE (xs2, mxs)): PERMUTE (xs1, xs2) // end of [permute_seteq] prfun permute_seteq_elim {xs1:ilist;mxs1:imset} {xs2:ilist;mxs2:imset} ( pf: PERMUTE (xs1, xs2), pf1: MSETIZE (xs1, mxs1), pf2: MSETIZE (xs2, mxs2) ) : MSETEQ (mxs1, mxs2) // end of [permute_mseteq] (* ****** ****** *) (* // // HX-2010-12-27: see [imsetp.dats] // propdef MUNION (xs1:ilist, xs2:ilist, xs3:ilist) = {x0:int} {n1,n2:nat} (MSETCNT (x0, xs1, n1), MSETCNT (x0, xs2, n2)) - MSETCNT (x0, xs3, n1+n2) // end of [MUNION] prfun append_munion_lemma {xs,ys,zs:ilist} (pf: APPEND (xs,ys,zs)): MUNION (xs, ys, zs) // end of [append_munion_lemma] *) (* ****** ****** *) (* // // HX-2010-12-27: see [imsetp.dats] // propdef MSUBSET (xs1:ilist, xs2:ilist) = {x0:int} {n1,n2:nat} (MSETCNT (x0, xs1, n1), MSETCNT (x0, xs1, n2)) - [n1 <= n2] void // end of [MSUBSET] *) (* ****** ****** *) (* dataprop MSETALL (P: int -> prop, ilist) = | MSETALLnil (P, ilist_nil) of () | {x:int} {xs:ilist} MSETALLcons (P, ilist_cons (x, xs)) of (P x, MSETALL (P, xs)) // end of [MSETALL] prfun msetall_trans {P1:int->prop} {P2:int->prop} {xs:ilist} (pf: MSETALL (P1, xs), fpf: {x:int} P1 x - P2 x): MSETALL (P2, xs) // end of [msetall_trans] *) (* ****** ****** *) absprop LTB (x: int, xs: ilist) // [x] is a strict lower bound for [xs] // end of [LTB] prfun ltb_istot {xs:ilist} (): [x:int] LTB (x, xs) prfun ltb_nil {x:int} (): LTB (x, ilist_nil) prfun ltb_cons {x0:int} {x:int | x0 < x} {xs:ilist} (pf: LTB (x0, xs)): LTB (x0, ilist_cons (x, xs)) // end of [ltb_cons] prfun ltb_cons_elim {x0:int} {x:int} {xs:ilist} (pf: LTB (x0, ilist_cons (x, xs))): [x0 < x] LTB (x0, xs) // end of [ltb_cons_elim] prfun ltb_dec {x1:int} {x2:int | x2 <= x1} {xs:ilist} (pf: LTB (x1, xs)): LTB (x2, xs) // end of [ltb_dec] prfun ltb_permute_lemma {x:int} {xs1,xs2:ilist} (pf1: LTB (x, xs1), pf2: PERMUTE (xs1, xs2)): LTB (x, xs2) // end of [ltb_permute_lemma] (* ****** ****** *) absprop LTEB (x: int, xs: ilist) // [x] is a lower bound for [xs] // end of [LTEB] prfun lteb_istot {xs:ilist} (): [x:int] LTEB (x, xs) prfun lteb_nil {x:int} (): LTEB (x, ilist_nil) prfun lteb_cons {x0:int} {x:int | x0 <= x} {xs:ilist} (pf: LTEB (x0, xs)): LTEB (x0, ilist_cons (x, xs)) // end of [lteb_cons] prfun lteb_cons_elim {x0:int} {x:int} {xs:ilist} (pf: LTEB (x0, ilist_cons (x, xs))): [x0 <= x] LTEB (x0, xs) // end of [lteb_cons_elim] prfun lteb_dec {x1:int} {x2:int | x2 <= x1} {xs:ilist} (pf: LTEB (x1, xs)): LTEB (x2, xs) // end of [lteb_dec] prfun lteb_permute_lemma {x:int} {xs1,xs2:ilist} (pf1: LTEB (x, xs1), pf2: PERMUTE (xs1, xs2)): LTEB (x, xs2) // end of [lteb_permute_lemma] (* ****** ****** *) dataprop ISORD (ilist) = | ISORDnil (ilist_nil) of () | {x:int} {xs:ilist} ISORDcons (ilist_cons (x, xs)) of (ISORD xs, LTEB (x, xs)) // end of [ISORD] (* ****** ****** *) // // SORT (xs, ys): // [ys] is a sorted version of [xs] // absprop SORT (xs: ilist, ys: ilist) prfun sort_elim {xs,ys:ilist} (pf: SORT (xs, ys)): @(PERMUTE (xs, ys), ISORD ys) prfun sort_make {xs,ys:ilist} (pf1: PERMUTE (xs, ys), pf2: ISORD ys): SORT (xs, ys) (* ****** ****** *) (* end of [ilistp.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/optini.sats0000664000175000017500000000322412223166162020224 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // HX-2010-10-10: for handling variable initialization // (* ****** ****** *) dataview optini_v (a:viewt@ype, l:addr, bool) = | optini_v_some (a, l, true) of a @ l | optini_v_none (a, l, false) of a? @ l // end of [optini_v] (* ****** ****** *) (* end of [optini.sats] *) ats-lang-anairiats-0.2.11/libats/SATS/bimatrix.sats0000664000175000017500000001025212223166162020540 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Bidirectional row-major matrices ** (matrices moving from left to right and vice versa) ** Contributed by Artyom Shalkhakov (artyom.shalkhakov AT gmail DOT com) ** Time: November, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) staload "libats/SATS/biarray.sats" (* ****** ****** *) // // bidirectional row-major matrix // absview bimatrix_v (a:viewt@ype+, (*rows*)int, (*cols*)int, addr, addr) (* dataview bimatrix_v ( a:vt0p, (*rows*)int, (*cols*)int, addr, addr ) = | {l1:addr} bimatrix_v_nil (a, 0, 0, l1, l1) | {m,n:nat} {l1,l2,l3:addr} bimatrix_v_cons (a, m+1, n, l1, l3) of ( biarray_v (a, n, l1, l2), bimatrix_v (a, m, n, l2, l3) ) // end of [bimatrix_v] *) (* ****** ****** *) prfun bimatrix_v_of_matrix_v {a:viewt@ype} {m,n:int} {l1:addr} (pf: matrix_v (a, m, n, l1)): [l2:addr] bimatrix_v (a, m, n, l1, l2) // end of [bimatrix_v_of_matrix_v] prfun matrix_v_of_bimatrix_v {a:viewt@ype} {m,n:int} {l1,l2:addr} (pf: bimatrix_v (a, m, n, l1, l2)): matrix_v (a, m, n, l1) // end of [matrix_v_of_bimatrix_v] (* ****** ****** *) prfun bimatrix_v_offset {a:viewt@ype} {m,n:int} {l1,l2:addr} (pf: !bimatrix_v (a, m, n, l1, l2)): [mn:int] (MUL (m, n, mn), MUL (mn, sizeof(a), l2-l1)) // end of [bimatrix_v_offset] (* ****** ****** *) prfun bimatrix_v_nil {a:viewt@ype} {n:nat} {l:addr} (): bimatrix_v (a, 0, n, l, l) // end of [bimatrix_v_nil] prfun bimatrix_v_unnil {a:viewt@ype} {n:nat} {l1,l2:addr} (pf: bimatrix_v (a, 0, n, l1, l2)): [l1==l2] void // end of [bimatrix_v_unnil] (* ****** ****** *) prfun bimatrix_v_sing {a:viewt@ype} {n:nat} {l1,l2:addr} (pf: biarray_v (a, n, l1, l2)): bimatrix_v (a, 1, n, l1, l2) // end of [bimatrix_v_sing] prfun bimatrix_v_unsing {a:viewt@ype} {n:nat} {l1,l2:addr} (pf: bimatrix_v (a, 1, n, l1, l2)): biarray_v (a, n, l1, l2) // end of [bimatrix_v_unsing] prfun bimatrix_v_cons {a:viewt@ype} {m,n:nat} {l1,l2,l3:addr} ( pf1: biarray_v (a, n, l1, l2), pf2: bimatrix_v (a, m, n, l2, l3) ) : bimatrix_v (a, m+1, n, l1, l3) // end of [bimatrix_v_cons] (* ****** ****** *) prfun bimatrix_v_uncons {a:viewt@ype} {m:pos;n:nat} {l1,l3:addr} ( pf: bimatrix_v (a, m, n, l1, l3) ) : [l2:addr] ( biarray_v (a, n, l1, l2), bimatrix_v (a, m-1, n, l2, l3) ) // end of [bimatrix_v_uncons] prfun bimatrix_v_snoc {a:viewt@ype} {m,n:nat} {l1,l2,l3:addr} ( pf1: bimatrix_v (a, m, n, l1, l2), pf2: biarray_v (a, n, l2, l3) ) : bimatrix_v (a, m+1, n, l1, l3) // end of [bimatrix_v_snoc] (* ****** ****** *) prfun bimatrix_v_unsnoc {a:viewt@ype} {m,n:nat} {l1,l3:addr} ( pf: bimatrix_v (a, m, n, l1, l3) ) : [l2:addr] (bimatrix_v (a, m-1, n, l1, l2), biarray_v (a, n, l2, l3)) // end of [bimatrix_v_unsnoc] (* ****** ****** *) (* end of [bimatrix.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/0000700000175000017500000000000012223166162016520 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/smlbas/CATS/0000700000175000017500000000000012223166162017252 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/smlbas/SATS/0000700000175000017500000000000012223166162017272 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/smlbas/SATS/general.sats0000664000175000017500000000426012223166162021621 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: General (http://www.standardml.org/Basis/general.html) // (* ****** ****** *) exception Bind of () exception Match of () exception Chr of () exception Div of () exception Domain of () // out-of-domain type of error exception Empty of () exception Fail of string exception Overflow of () exception Range of () // out-of-range type of error exception Size of () exception Span of () exception Subscript of () exception Undefined of string // for undefined values and functions (* ****** ****** *) fun{a,b,c:t@ype} compose (_: b - c, _: a - b): a - c // end of [compose] fun{a:t@ype} ignore (x: a): void (* ****** ****** *) (* end of [general.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/date.sats0000664000175000017500000000507312223166162021124 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Date (http://www.standardml.org/Basis/date.html) // (* ****** ****** *) staload TIME = "libats/smlbas/SATS/time.sats" (* ****** ****** *) datatype weekday = | Mon | Tue | Wed | Thu | Fri | Sat | Sun // end of [weekday] datatype month = | Jan | Feb | Mar | Apr | May | Jun | Jul | Aug | Sep | Oct | Nov | Dec // end of [month] abstype date // a boxed abstract type exception Date of () (* ****** ****** *) fun date ( year: int, month: month, day: int , hour: int, minute: int, second: int , offset: option0 ($TIME.time) ) : date // end of [date] fun year (_: date): int fun month (_: date): month fun day (_: date): int fun hour (_: date): int fun minute (_: date): int fun second (_: date): int fun weekday (_: date): weekday fun yearday (_: date): int fun offset (_: date): option0 ($TIME.time) fun isDst (_: date): option0 (bool) // fun localOffset (): $Time.time fun compare_date_date (d1: date, d2: date): int (* ****** ****** *) fun toString (d: date): string fun fromString (s: string): date (* ****** ****** *) (* end of [date.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/list.sats0000664000175000017500000000626212223166162021163 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: List (http://www.standardml.org/Basis/list.html) // (* ****** ****** *) fun null {a:t@ype} (xs: list0 a): bool fun{a:t@ype} length (xs: list0 a): int fun{a:t@ype} append (xs: list0 a, ys: list0 a): list0 a fun{a:t@ype} hd (xs: list0 a): a fun{a:t@ype} tl (xs: list0 a): list0 a fun{a:t@ype} last (xs: list0 a): a fun{a:t@ype} getItem (xs: list0 a): option0 @(a, list0 a) fun{a:t@ype} nth (xs: list0 a, n: int): a fun{a:t@ype} take (xs: list0 a, i: int): list0 a fun{a:t@ype} drop (xs: list0 a, i: int): list0 a fun{a:t@ype} rev (xs: list0 a): list0 a fun{a:t@ype} revAppend (xs: list0 a, ys: list0 a): list0 a fun{a:t@ype} concat (xs: list0 (list0 a)): list0 a (* ****** ****** *) fun{a:t@ype} app (f: a - void, xs: list0 a): void fun{a:t@ype}{b:t@ype} map (f: a - b, xs: list0 a) : list0 b fun{a:t@ype}{b:t@ype} mapPartial (f: a - option0 b, xs: list0 a) : list0 b (* ****** ****** *) fun{a:t@ype} find (f: a - bool, xs: list0 a): option0 a fun{a:t@ype} filter (f: a - bool, xs: list0 a): list0 a (* ****** ****** *) fun{a:t@ype} partition (f: a - bool, xs: list0 a): @(list0 a, list0 a) (* ****** ****** *) fun{a,b:t@ype} foldl (f: (a, b) - b, ini: b, xs: list0 a): b fun{a,b:t@ype} foldr (f: (a, b) - b, snk: b, xs: list0 a): b (* ****** ****** *) fun{a:t@ype} all (f: a - bool, xs: list0 a): bool fun{a:t@ype} exists (f: a - bool, xs: list0 a): bool (* ****** ****** *) fun{a:t@ype} tabulate (lsz: int, f: int - a): list0 a fun{a:t@ype} collate (cmp: (a, a) - int, xs: list0 a, ys: list0 a): int // end of [collate] (* ****** ****** *) (* end of [list.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/array.sats0000664000175000017500000000652612223166162021331 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Array (http://www.standardml.org/Basis/array.html) // (* ****** ****** *) abstype array_t0ype_type (a:t@ype) typedef array (a:t@ype) = array_t0ype_type (a) (* ****** ****** *) // this one is undefined! fun maxLen (): size_t // maximal array size allowed (* ****** ****** *) fun{a:t@ype} array (asz: size_t, ini: a): array a fun{a:t@ype} fromList (xs: list0 a): array a fun{a:t@ype} tabulate (asz: size_t, f: size_t - a): array a (* ****** ****** *) fun length {a:t@ype} (A: array a): size_t (* ****** ****** *) fun{a:t@ype} sub (A: array a, i: size_t): a fun{a:t@ype} update (A: array a, i: size_t, x: a): void (* ****** ****** *) fun{a:t@ype} copy (src: array a, dst: array a, di: size_t): void (* ****** ****** *) fun{a:t@ype} app (f: a - void, A: array a): void fun{a:t@ype} appi (f: (size_t, a) - void, A: array a): void (* ****** ****** *) fun{a:t@ype} modify (f: a - a, A: array a): void fun{a:t@ype} modifyi (f: (size_t, a) - a, A: array a): void (* ****** ****** *) fun{a,b:t@ype} foldl (f: (a, b) - b, ini: b, A: array a): b fun{a,b:t@ype} foldli (f: (size_t, a, b) - b, ini: b, A: array a): b fun{a,b:t@ype} foldr (f: (a, b) - b, fin: b, A: array a): b fun{a,b:t@ype} foldri (f: (size_t, a, b) - b, fin: b, A: array a): b (* ****** ****** *) fun{a:t@ype} find (f: a - bool, A: array a): option0 a fun{a:t@ype} findi (f: (size_t, a) - bool, A: array a): option0 @(size_t, a) (* ****** ****** *) fun{a:t@ype} all (f: a - bool, A: array a): bool fun{a:t@ype} exists (f: a - bool, A: array a): bool (* ****** ****** *) // collate: lexicographic ordering // GREATER: > 0; EQUAL: = 0; LESS: < 0 fun{a:t@ype} collate (cmp: (a, a) - int, A1: array a, A2: array a): int (* ****** ****** *) (* end of [array.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/char.sats0000664000175000017500000000572512223166162021130 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Char (http://www.standardml.org/Basis/char.html) // (* ****** ****** *) val minChar : char val maxChar : char val maxOrd : uint (* ****** ****** *) fun ord (c: char): uint fun chr (i: uint): char fun succ (c: char): char fun pred (c: char): char (* ****** ****** *) fun compare (c1: char, c2: char): int fun lt (c1: char, c2: char): bool overload < with lt fun lte (c1: char, c2: char): bool overload <= with lte fun gt (c1: char, c2: char): bool overload > with gt fun gte (c1: char, c2: char): bool overload >= with gte (* ****** ****** *) fun contains (s: string, c: char): bool fun notContains (s: string, c: char): bool (* ****** ****** *) fun isAscii (c: char): bool fun isAlpha (c: char): bool fun isAlphaNum (c: char): bool fun isCntrl (c: char): bool fun isDigit (c: char): bool fun isGraph (c: char): bool fun isHexDigit (c: char): bool fun isLower (c: char): bool fun isPrint (c: char): bool fun isSpace (c: char): bool fun isPunct (c: char): bool fun isUpper (c: char): bool (* ****** ****** *) fun toLower (c: char): char fun toUpper (c: char): char (* ****** ****** *) (* fun toString (c: char): string // not implemented fun fromString (s: string): option0 char // not implemented *) (* ****** ****** *) // // not yet implemented // fun scan : (Char.char, 'a) StringCvt.reader -> (char, 'a) StringCvt.reader // (* ****** ****** *) fun toCString (c: char): string fun fromCString (s: string): option0 char (* ****** ****** *) (* end of [char.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/bool.sats0000664000175000017500000000333712223166162021143 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Bool (http://www.standardml.org/Basis/bool.html) // (* ****** ****** *) fun not (b: bool): bool fun toString (b: bool): string fun fromString (s: string): option0 (bool) (* ****** ****** *) (* end of [bool.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/real.sats0000664000175000017500000000662512223166162021136 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Real (http://www.standardml.org/Basis/real.html) // (* ****** ****** *) abst@ype real_t0ype = double // implemented as floating point number of double precision typedef real = real_t0ype (* ****** ****** *) castfn real_of_double (x: double): real castfn double_of_real (x: real): double (* ****** ****** *) fun fprint_real (out: FILEref, r: real): void overload fprint with fprint_real (* ****** ****** *) fun add_real_real (r1: real, r2: real): real overload + with add_real_real fun sub_real_real (r1: real, r2: real): real overload - with sub_real_real fun mul_real_real (r1: real, r2: real): real overload * with mul_real_real fun div_real_real (r1: real, r2: real): real overload / with div_real_real // this one is name [rem] in [smlbas] fun mod_real_real (r1: real, r2: real): real overload mod with mod_real_real (* ****** ****** *) fun muladd_real_real (r1: real, r2: real, r3: real): real fun mulsub_real_real (r1: real, r2: real, r3: real): real (* ****** ****** *) fun neg_real (r: real): real fun abs_real (r: real): real (* ****** ****** *) fun lt_real_real (r1: real, r2: real): bool overload < with lt_real_real fun lte_real_real (r1: real, r2: real): bool overload <= with lte_real_real fun gt_real_real (r1: real, r2: real): bool overload > with gt_real_real fun gte_real_real (r1: real, r2: real): bool overload >= with gte_real_real fun eq_real_real (r1: real, r2: real): bool overload = with eq_real_real fun neq_real_real (r1: real, r2: real): bool overload <> with neq_real_real fun compare_real_real (r1: real, r2: real): int (* ****** ****** *) fun min_real_real (r1: real, r2: real): real overload min with min_real_real fun max_real_real (r1: real, r2: real): real overload max with max_real_real (* ****** ****** *) fun realCeil (r: real): real fun realFloor (r: real): real fun realRound (r: real): real fun realTrunc (r: real): real (* ****** ****** *) (* end of [real.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/time.sats0000664000175000017500000000442512223166162021145 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Time (http://www.standardml.org/Basis/time.html) // (* ****** ****** *) staload REAL = "libats/smlbas/SATS/real.sats" (* ****** ****** *) abst@ype time_t0ype = $REAL.real typedef time = time_t0ype (* ****** ****** *) fun toReal (x: time): $REAL.real fun fromReal (x: $REAL.real): time (* ****** ****** *) fun fprint_time (out: FILEref, x: time): void overload fprint with fprint_time (* ****** ****** *) fun toSeconds (x: time): lint fun fromSeconds (x: lint): time fun toMilliseconds (x: time): llint fun fromMilliseconds (x: llint): time fun toMicroseconds (x: time): llint fun fromMicroseconds (x: llint): time fun toNanoseconds (x: time): llint fun fromNanoseconds (x: llint): time (* ****** ****** *) fun now (): time (* ****** ****** *) (* end of [time.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/array2.sats0000664000175000017500000000621112223166162021402 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Array2 (http://www.standardml.org/Basis/array2.html) // (* ****** ****** *) abstype array2_t0ype_type (a:t@ype) typedef array (a:t@ype) = array2_t0ype_type (a) (* ****** ****** *) typedef region (a:t@ype) = '{ base= array (a) , row= int, col= int , nrows= option0 int, ncols= option0 int } // end of [region] datatype traversal = RowMajor | ColMajor (* ****** ****** *) fun{a:t@ype} array (row: size_t, col: size_t, ini: a): array (a) // end of [array] (* ****** ****** *) fun{a:t@ype} fromList (xss: list0 (list0 a)): array (a) (* ****** ****** *) // both [row] and [col] need to be positive; otherwize; an exception (Size) // is raised. fun{a:t@ype} tabulate ( trv: traversal, row: size_t, col: size_t, f: (size_t, size_t) - a ) : array (a) // end of [tabulate] (* ****** ****** *) fun{a:t@ype} sub (M: array a, i: size_t, j: size_t): a fun{a:t@ype} update (M: array a, i: size_t, j: size_t, x: a): void (* ****** ****** *) fun dimensions {a:t@ype} (M: array a): @(size_t, size_t) fun nCols {a:t@ype} (M: array a): size_t and nRows {a:t@ype} (M: array a): size_t (* ****** ****** *) fun{a:t@ype} app (trv: traversal, f: a - void, M: array a): void // end of [app] fun{a,b:t@ype} fold ( trv: traversal, f: (a, b) - b, ini: b, M: array a ) : void // end of [fold] fun{a:t@ype} modify (trv: traversal, f: a - a, M: array a): void // end of [modify] (* ****** ****** *) (* // not implemented val row : 'a array * int -> 'a Vector.vector val column : 'a array * int -> 'a Vector.vector val copy ... val appi ... val foldi ... val modifyi ... *) (* ****** ****** *) (* end of [array2.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/string.sats0000664000175000017500000000705612223166162021520 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: String (http://www.standardml.org/Basis/string.html) // (* ****** ****** *) // // HX: this one is undefined! // fun maxSize (): size_t // maximal string size allowed (* ****** ****** *) fun size {n:nat} (s: string n): size_t n fun sub {n,i:nat | i < n} (s: string n, i: size_t i): char fun extract {n,i:nat} {b:bool;j:nat | i+j <= n} (s: string n, i: size_t i, j: option (size_t j, b)) : [k:nat | (b && k == j) || (~b && k == n-i)] string (k) fun substring {n:int} {i,ln:nat | i+ln <= n} (s: string n, ofs: size_t i, len: size_t ln): string (ln) // end of [substring] fun ^ {i,j:nat} (s1: string i, s2: string j): string (i+j) fun concat (ss: list0 string): string fun concatWith (sep: string, ss: list0 string): string fun str (c: char): string (1) fun implode (cs: list0 char): string fun explode (str: string): list0 char (* ****** ****** *) fun map {n:nat} (f: char - char, s: string n): string n // end of [map] fun translate (f: char - string, s: string): string (* ****** ****** *) fun tokens (isdelim: char - bool, s: string): list0 string fun fields (isdelim: char - bool, s: string): list0 string (* ****** ****** *) fun isPrefix (s1: string, s2: string): bool fun isSubstring (s1: string, s2: string): bool fun isSuffix (s1: string, s2: string): bool (* ****** ****** *) fun lt (s1: string, s2: string): bool fun lte (s1: string, s2: string): bool fun gt (s1: string, s2: string): bool fun gte (s1: string, s2: string): bool fun eq (s1: string, s2: string): bool fun neq (s1: string, s2: string): bool fun compare (s1: string, s2: string): int fun collate (f: (char, char) - int, s1: string, s2: string): int (* ****** ****** *) (* these one are yet to be implemented: val toString : string -> String.string val scan : (char, 'a) StringCvt.reader -> (string, 'a) StringCvt.reader val fromString : String.string -> string option val toCString : string -> String.string val fromCString : String.string -> string option *) (* ****** ****** *) (* end of [string.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/listPair.sats0000664000175000017500000000623512223166162021777 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: ListPair (http://www.standardml.org/Basis/list-pair.html) // (* ****** ****** *) exception UnequalLengths of () (* ****** ****** *) fun{a,b:t@ype} zip (xs: list0 a, ys: list0 b): list0 @(a, b) fun{a,b:t@ype} zipEq (xs: list0 a, ys: list0 b): list0 @(a, b) fun{a,b:t@ype} unzip (xys: list0 @(a, b)): @(list0 a, list0 b) (* ****** ****** *) fun{a,b:t@ype} app (f: (a, b) - void, xs: list0 a, ys: list0 b): void // end of [app] fun{a,b:t@ype} appEq (f: (a, b) - void, xs: list0 a, ys: list0 b): void // end of [appEq] (* ****** ****** *) fun{a,b:t@ype}{c:t@ype} map (f: (a, b) - c, xs: list0 a, ys: list0 b): list0 c // end of [map] fun{a,b:t@ype}{c:t@ype} mapEq (f: (a, b) - c, xs: list0 a, ys: list0 b): list0 c // end of [mapEq] (* ****** ****** *) fun{a,b:t@ype}{c:t@ype} foldl (f: (a, b, c) - c, ini: c, xs: list0 a, ys: list0 b): c // end of [foldl] fun{a,b:t@ype}{c:t@ype} foldlEq (f: (a, b, c) - c, ini: c, xs: list0 a, ys: list0 b): c // end of [foldlEq] (* ****** ****** *) fun{a,b:t@ype}{c:t@ype} foldr (f: (a, b, c) - c, ini: c, xs: list0 a, ys: list0 b): c // end of [foldr] fun{a,b:t@ype}{c:t@ype} foldrEq (f: (a, b, c) - c, ini: c, xs: list0 a, ys: list0 b): c // end of [foldrEq] (* ****** ****** *) fun{a,b:t@ype} all (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool // end of [all] fun{a,b:t@ype} allEq (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool // end of [allEq] (* ****** ****** *) fun{a,b:t@ype} exists (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool // end of [exists] (* ****** ****** *) (* end of [listPair.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/SATS/math.sats0000664000175000017500000000435612223166162021143 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Math (http://www.standardml.org/Basis/math.html) // (* ****** ****** *) staload REAL = "libats/smlbas/SATS/real.sats" typedef real = $REAL.real (* ****** ****** *) val pi : real // = 3.1415926535897932384626 val e : real // = 2.718281828 fun sqrt (x: real): real fun sin (x: real): real fun cos (x: real): real fun tan (x: real): real fun asin (x: real): real fun acos (x: real): real fun atan (x: real): real fun atan2 (y: real, x: real): real (* ****** ****** *) fun exp (x: real): real fun pow (x: real, y: real): real (* ****** ****** *) fun ln (x: real): real fun log10 (x: real): real (* ****** ****** *) fun sinh (x: real): real fun cosh (x: real): real fun tanh (x: real): real (* ****** ****** *) (* end of [math.sats] *) ats-lang-anairiats-0.2.11/libats/smlbas/.libfiles0000664000175000017500000000127312223166162020331 0ustar hwxihwxilibats/smlbas/SATS/general.sats libats/smlbas/SATS/array.sats libats/smlbas/DATS/array.dats libats/smlbas/SATS/array2.sats libats/smlbas/DATS/array2.dats libats/smlbas/SATS/bool.sats libats/smlbas/DATS/bool.dats libats/smlbas/SATS/char.sats libats/smlbas/DATS/char.dats libats/smlbas/SATS/date.sats libats/smlbas/DATS/date.dats libats/smlbas/SATS/list.sats libats/smlbas/DATS/list.dats libats/smlbas/SATS/listPair.sats libats/smlbas/DATS/listPair.dats libats/smlbas/SATS/math.sats libats/smlbas/DATS/math.dats libats/smlbas/SATS/real.sats libats/smlbas/DATS/real.dats libats/smlbas/SATS/string.sats libats/smlbas/DATS/string.dats libats/smlbas/SATS/time.sats libats/smlbas/DATS/time.dats ats-lang-anairiats-0.2.11/libats/smlbas/DATS/0000700000175000017500000000000012223166162017253 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/smlbas/DATS/array.dats0000664000175000017500000002225512223166162021270 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Array (http://www.standardml.org/Basis/array.html) // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/array.sats" (* ****** ****** *) implement maxLen () = $raise Undefined "array:maxLen" (* ****** ****** *) assume array_t0ype_type (a:t@ype) = [n:nat] '(array (a, n), size_t n) // end of [assume array_t0ype_type] (* ****** ****** *) implement{a} array (asz, ini) = let val [n:int] asz = size1_of_size (asz) val A = array_make_elt (asz, ini) in '(A, asz) end // end of [array] (* ****** ****** *) implement{a} fromList (xs) = let val [n:int] xs = list_of_list0 (xs) val asz = size1_of_int1 (list_length xs) val A = array_make_lst (asz, xs) in '(A, asz) end // end of [fromList] implement{a} tabulate (asz, f) = let val [n:int] asz = size1_of_size (asz) val ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (asz, sizeof) // var !p_clo = @lam (pf: !unit_v | i: sizeLt n, x: &(a?) >> a): void = $effmask_all (x := f i) (* end of [var] *) // prval pf = unit_v () val () = array_ptr_initialize_vclo {unit_v} {n} (pf | !p_arr, asz, !p_clo) prval unit_v () = pf prval () = free_gc_elim {a?} (pfgc) val A = array_make_view_ptr (pfarr | p_arr) in '(A, asz) end // end of [tabulate] (* ****** ****** *) implement length (A) = A.1 (* ****** ****** *) implement{a} sub (A, i) = let val i = size1_of_size (i) in if i < A.1 then array_get_elt_at (A.0, i) else $raise Subscript () end // end of [sub] implement{a} update (A, i, x) = let val i = size1_of_size (i) in if i < A.1 then array_set_elt_at (A.0, i, x) else $raise Subscript () end // end of [sub] (* ****** ****** *) implement{a} copy ([n1:int] src, [n2:int] dst, di) = let val [di:int] di = size1_of_size (di) val asz1 = src.1 and asz2 = dst.1 val _src = src.0 and _dst = dst.0 in if (di + asz1) <= asz2 then let var i: size_t = size1_of_int1 0 and j: size_t = di in while* {i:nat} (i: size_t i, j: size_t (di + i)) => (i < asz1) begin _dst[j] := _src[i]; i := i + 1; j := j + 1 end // end of [while] end else $raise Subscript () // end of [if] end (* end of [copy] *) (* ****** ****** *) implement{a} app (f, [n:int] A) = () where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) viewdef v = unit_v; viewdef vt = (a) - void prval pf = unit_v () fn _app (pf: !v | x: &a, f: !vt):<> void = $effmask_all (f x) val () = array_ptr_foreach_funenv_tsz {a} {v} {vt} (pf | !p_arr, _app, A.1, sizeof, f) prval unit_v () = pf } // end of [app] implement{a} appi (f, [n:int] A) = () where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) viewdef v = unit_v; viewdef vt = (size_t, a) - void prval pf = unit_v () fn _app (pf: !v | i: sizeLt n, x: &a, f: !vt):<> void = $effmask_all (f (i, x)) val () = array_ptr_iforeach_funenv_tsz {a} {v} {vt} (pf | !p_arr, _app, A.1, sizeof, f) prval unit_v () = pf } // end of [appi] (* ****** ****** *) implement{a} modify (f, [n:int] A) = () where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) viewdef v = unit_v; viewdef vt = (a) - a prval pf = unit_v () fn _app (pf: !v | x: &a, f: !vt):<> void = x := $effmask_all (f (x)) val () = array_ptr_foreach_funenv_tsz {a} {v} {vt} (pf | !p_arr, _app, A.1, sizeof, f) prval unit_v () = pf } // end of [modify] implement{a} modifyi (f, [n:int] A) = () where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) viewdef v = unit_v; viewdef vt = (size_t, a) - a prval pf = unit_v () fn _app (pf: !v | i: sizeLt n, x: &a, f: !vt):<> void = x := $effmask_all (f (i, x)) val () = array_ptr_iforeach_funenv_tsz {a} {v} {vt} (pf | !p_arr, _app, A.1, sizeof, f) prval unit_v () = pf } // end of [modifyi] (* ****** ****** *) implement{a,b} foldl (f, ini, [n:int] A) = res where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) val asz = A.1 var res: b = ini var i: sizeLte n // uninitialized val _0: size_t = size1_of_int1 (0) val () = begin for (i := _0; i < asz; i := i + 1) (res := $effmask_all (f (p_arr->[i], res))) end // end of [val] } // end of [foldl] implement{a,b} foldli (f, ini, [n:int] A) = res where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) val asz = A.1 var res: b = ini var i: sizeLte n // uninitialized val _0: size_t = size1_of_int1 (0) val () = begin for (i := _0; i < asz; i := i + 1) (res := $effmask_all (f (i, p_arr->[i], res))) end // end of [val] } // end of [foldl] (* ****** ****** *) implement{a,b} foldr (f, snk, [n:int] A) = res where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var res: b = snk var i: sizeLte n = A.1 val () = while (i > 0) let val () = i := i - 1 in res := $effmask_all (f (p_arr->[i], res)) end // end of [val] } // end of [foldr] implement{a,b} foldri (f, snk, [n:int] A) = res where { val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var res: b = snk var i: sizeLte n = A.1 val () = while (i > 0) let val () = i := i - 1 in res := $effmask_all (f (i, p_arr->[i], res)) end // end of [val] } // end of [foldri] (* ****** ****** *) implement{a} find (f, [n:int] A) = res where { val asz = A.1 val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var i: sizeLte n // uninitialzed () var res: option0 a = option0_none () val _0 = size1_of_int1 (0) val () = for (i := _0; i < asz; i := i + 1) let val x = p_arr->[i]; val found = $effmask_all (f x) val () = if found then (res := option0_some x; break) else () in // empty end // end of [val] } // end of [find] implement{a} findi (f, [n:int] A) = res where { val asz = A.1 val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var i: sizeLte n // uninitialzed () var res: option0 @(size_t, a) = option0_none () val _0 = size1_of_int1 (0) val () = for (i := _0; i < asz; i := i + 1) let val x = p_arr->[i]; val found = $effmask_all (f (i, x)) val () = if found then (res := option0_some @(i, x); break) else () in // empty end // end of [val] } // end of [findi] (* ****** ****** *) implement{a} all (f, [n:int] A) = res where { val asz = A.1 val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var i: sizeLte n // uninitialzed () var res: bool = true val _0 = size1_of_int1 (0) val () = for (i := _0; i < asz; i := i + 1) let val x = p_arr->[i]; val found = $effmask_all (f x) (* // this does not work because of a bug! val () = if found then () else (res := false; break) *) val () = if :(i: sizeLt n) => found then () else (res := false; break) in // empty end // end of [val] } // end of [all] implement{a} exists (f, [n:int] A) = res where { val asz = A.1 val (vbox pfarr | p_arr) = array_get_view_ptr (A.0) var i: sizeLte n // uninitialzed () var res: bool = false val _0 = size1_of_int1 (0) val () = for (i := _0; i < asz; i := i + 1) let val x = p_arr->[i]; val found = $effmask_all (f x) val () = if :(i: sizeLt n) => found then (res := true; break) else () in // empty end // end of [val] } // end of [exists] (* ****** ****** *) implement{a} collate (cmp, [n1:int] A1, [n2:int] A2) = let fun loop {i:nat | i <= min(n1,n2) } .. ( cmp: (a, a) - int , _A1: array (a, n1), n1: size_t n1 , _A2: array (a, n2), n2: size_t n2 , i: size_t i ) : int = case+ 0 of | _ when i < n1 => if i < n2 then let val sgn = cmp (_A1[i], _A2[i]) in if sgn = 0 then loop (cmp, _A1, n1, _A2, n2, i+1) else sgn end else 1 | _ (* i = n1 *) => if i < n2 then ~1 else 0 // end of [loop] in loop (cmp, A1.0, A1.1, A2.0, A2.1, 0) end // end of [val] (* ****** ****** *) (* end of [array.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/list.dats0000664000175000017500000001762112223166162021126 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: List (http://www.standardml.org/Basis/list.html) // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/list.sats" (* ****** ****** *) implement null (xs) = case+ xs of list0_nil _ => true | list0_cons _ => false // end of [null] implement{a} length (xs) = list0_length (xs) implement{a} append (xs, ys) = list0_append (xs, ys) // tail-recursive implement{a} hd (xs) = case+ xs of | list0_cons (x, _) => x | list0_nil () => $raise Empty () // end of [hd] implement{a} tl (xs) = case+ xs of | list0_cons (_, xs) => xs | list0_nil () => $raise Empty () // end of [hd] implement{a} last (xs) = let fun loop (x: a, xs: list0 a): a = case+ xs of | list0_cons (x, xs) => loop (x, xs) | list0_nil () => x // end of [loop] in case xs of | list0_cons (x, xs) => loop (x, xs) | list0_nil () => $raise Empty () end (* end of [last] *) implement{a} getItem (xs) = case+ xs of | list0_cons (x, xs) => option0_some @(x, xs) | list0_nil () => option0_none () // end of [getItem] (* ****** ****** *) local fun{a:t@ype} ListSubscriptExn2Subscript_raise (exn: exn): a = let in // if isListSubscriptException (exn) then let prval () = __assert (exn) where { extern praxi __assert (exn: exn): void } in $raise Subscript() end else $raise (exn) // end // end of [ListSubscriptExn2Subscript_raise] in (* in of [local] *) implement{a} nth (xs, i) = try list0_nth_exn (xs, i) // [prelude/DATS/list0.dats] with | exn => ListSubscriptExn2Subscript_raise (exn) // end of [nth] implement{a} take (xs, i) = try list0_take_exn (xs, i) // [prelude/DATS/list0.dats] with | exn => ListSubscriptExn2Subscript_raise (exn) // end of [take] implement{a} drop (xs, i) = try list0_drop_exn (xs, i) // [prelude/DATS/list0.dats] with | exn => ListSubscriptExn2Subscript_raise (exn) // end of [drop] end // end of [local] (* ****** ****** *) implement{a} rev (xs) = list0_reverse (xs) implement{a} revAppend (xs, ys) = list0_reverse_append (xs, ys) implement{a} concat (xss) = list0_concat (xss) (* ****** ****** *) implement{a} app (f, xs) = loop (f, xs) where { fun loop (f: a - void, xs: list0 a): void = case+ xs of | list0_cons (x, xs) => (f x; loop (f, xs)) | list0_nil () => () // end of [loop] } // end of [app] (* ****** ****** *) implement{a}{b} map (f, xs) = list0_map_cloref (xs, f) implement{a}{b} mapPartial (f, xs) = res where { typedef res_t = list0 b fun loop ( f: a - option0 b, xs: list0 a, res: &res_t? >> res_t ) : void = case+ xs of | list0_cons (x, xs) => begin case+ f (x) of | option0_some y => let val () = res := list0_cons (y, ?) val+ list0_cons (_, !p_res1) = res in loop (f, xs, !p_res1); fold@ (res) end // end of [option0_some] | option0_none () => loop (f, xs, res) end // end of [list0_cons] | list0_nil () => res := list0_nil () // end of [loop] var res: res_t; val () = loop (f, xs, res) } // end of [mapPartial] (* ****** ****** *) implement{a} find (f, xs) = loop (f, xs) where { fun loop (f: a - bool, xs: list0 a): option0 a = case+ xs of | list0_cons (x, xs) => if f (x) then option0_some x else loop (f, xs) | list0_nil () => option0_none () // end of [loop] } // end of [find] implement{a} filter (f, xs) = list0_filter_cloref (xs, f) (* ****** ****** *) implement{a} partition (f, xs) = (res_p, res_n) where { typedef res_t = list0 a fun loop ( f: a - bool , xs: list0 a , res_p: &res_t? >> res_t , res_n: &res_t? >> res_t ) : void = case+ xs of | list0_cons (x, xs) => begin if f (x) then let val () = res_p := list0_cons (x, ?) val+ list0_cons (_, !p_res1_p) = res_p in loop (f, xs, !p_res1_p, res_n); fold@ res_p end else let val () = res_n := list0_cons (x, ?) val+ list0_cons (_, !p_res1_n) = res_n in loop (f, xs, res_p, !p_res1_n); fold@ res_n end // end of [if] end (* end of [list0_cons] *) | list0_nil () => begin res_p := list0_nil (); res_n := list0_nil () end // end of [list0_nil] // end of [loop] var res_p: res_t and res_n: res_t // uninitialized val () = loop (f, xs, res_p, res_n) } // end of [partition] (* ****** ****** *) implement{a,b} foldl (f, ini, xs) = loop (f, ini, xs) where { fun loop ( f: (a, b) - b, ini: b, xs: list0 a ) : b = case+ xs of | list0_cons (x, xs) => loop (f, f (x, ini), xs) | list0_nil () => ini // end of [loop] } // end of [foldl] implement{a,b} foldr (f, snk, xs) = list0_fold_right (f, xs, snk) (* ****** ****** *) implement{a} all (f, xs) = loop (f, xs) where { fun loop (f: a - bool, xs: list0 a): bool = case+ xs of | list0_cons (x, xs) => if f (x) then loop (f, xs) else false | list0_nil () => true // end of [loop] } // end of [all] implement{a} exists (f, xs) = loop (f, xs) where { fun loop (f: a - bool, xs: list0 a): bool = case+ xs of | list0_cons (x, xs) => if f (x) then true else loop (f, xs) | list0_nil () => false // end of [loop] } // end of [exists] (* ****** ****** *) implement{a} tabulate (lsz, f) = let typedef res_t = list0 a fun loop {n,i:nat | i <= n} .. ( n: int n, i: int i, f: int - a, res: &res_t? >> res_t ) : void = if i < n then let val () = res := list0_cons (f i, ?) val+ list0_cons (_, !p_res1) = res in loop (n, i+1, f, !p_res1); fold@ (res) end else begin res := list0_nil () // loop exits end // end of [if] // end of [loop] val lsz = int1_of_int (lsz) in if lsz >= 0 then let var res: res_t in loop (lsz, 0, f, res); res end else begin $raise Size () end // end of [if] end // end of [tabulate] (* ****** ****** *) implement{a} collate (cmp, xs, ys) = loop (cmp, xs, ys) where { fun loop (cmp: (a, a) - int, xs: list0 a, ys: list0 a): int = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => let val sgn = cmp (x, y) in if sgn = 0 then loop (cmp, xs, ys) else sgn end // end of [list0_cons, list0_cons] | (list0_cons _, list0_nil ()) => 1 | (list0_nil (), list0_cons _) => ~1 | (list0_nil (), list0_nil ()) => 0 // end of [loop] } // end of [collate] (* ****** ****** *) (* end of [list.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/string.dats0000664000175000017500000002464012223166162021460 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: String (http://www.standardml.org/Basis/string.html) // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/string.sats" (* ****** ****** *) staload _(*anonynous*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) #define NUL '\000' (* ****** ****** *) implement maxSize () = $raise Undefined "string:maxSize" (* ****** ****** *) implement size (s) = string1_length (s) implement sub (s, i) = s[i] (* ****** ****** *) implement substring (str, st, ln) = let val sbp = string_make_substring (str, st, ln) in string1_of_strbuf sbp end // end of [substring] implement extract (str, st, oln) = case+ oln of | Some ln => let val sbp = string_make_substring (str, st, ln) in string1_of_strbuf sbp end // end of [Some] | None () => let val n = string1_length (str) val sbp = string_make_substring (str, st, n-st) in string1_of_strbuf (sbp) end // end of [option_none] (* end of [extract] *) (* ****** ****** *) implement ^ (s1, s2) = string1_of_strbuf (s1 + s2) (* ****** ****** *) implement str (c: char) = let val sbp = string_make_char (1, c) in string1_of_strbuf sbp end // end of [str] (* ****** ****** *) implement concat (ss) = let val ss = list_of_list0 (ss) val sbp = stringlst_concat (ss) in string_of_strptr (sbp) end // end of [concat] implement concatWith (sep, ss) = let val [n:int] ss = list_of_list0 (ss) fun loop {i:nat} .. ( sep: string , s: string, ss: list (string, i) , res: &List_vt string? >> list_vt (string, i+i+1) ) : void = let val () = res := list_vt_cons {string} {0} (s, ?) val+ list_vt_cons (_, !p_res1) = res in case+ ss of | list_cons (s1, ss1) => let val () = !p_res1 := list_vt_cons {string} {0} (sep, ?) val+ list_vt_cons (_, !p_res2) = !p_res1 in loop (sep, s1, ss1, !p_res2); fold@ !p_res1; fold@ res end // end of [list_cons] | list_nil () => (!p_res1 := list_vt_nil (); fold@ res) end // end of [loop] in case+ ss of | list_cons (s, ss) => let var res: List_vt string? val () = loop (sep, s, ss, res) val lss_sep = res val sbp = stringlst_concat (__cast lss_sep) where { extern castfn __cast (_: !List_vt string): List string } // end of [val] val () = list_vt_free (lss_sep) in string_of_strptr (sbp) end // end of [list_cons] | list_nil () => "" end // end of [concatWith] (* ****** ****** *) implement implode (cs) = let val sbp = string_implode (list_of_list0 cs) in string1_of_strbuf sbp end // end of [implode] implement explode (str) = begin list0_of_list_vt (string_explode (string1_of_string str)) end // end of [val] (* ****** ****** *) implement map {n} (f, s) = let val n = string1_length (s) val [l:addr] (pf_gc, pf_buf | p_buf) = malloc_gc (n+1) val () = loop (pf_buf | p_buf, 0) where { fun loop {i:nat | i <= n} {l:addr} .. (pf: !b0ytes (n-i+1) @ l >> strbuf (n-i+1, n-i) @ l | p: ptr l, i: size_t i) : void = let prval () = eqsize_byte_char () prval (pf1, pf2) = array_v_uncons {byte?} (pf) prval pf1 = char_v_of_b0yte_v (pf1) in if i < n then let val c = $effmask_ref (s[i]) val [fc:char] fc = char1_of_char (f c) val () = ( if (fc = NUL) then $raise Range () else () ) : [fc <> NUL] void val () = !p := fc val () = loop (pf2 | p + sizeof, i + 1) prval () = pf := strbuf_v_cons (pf1, pf2) in // empty end else let val () = !p := NUL prval () = pf := strbuf_v_null (pf1, pf2) in // empty end // end of [if] end (* end of [loop] *) } // end of [val] in string1_of_strbuf @(pf_gc, pf_buf | p_buf) end // end of [map] (* ****** ****** *) implement translate (f, s) = let viewtypedef res_t = List_vt string val [n:int] s = string1_of_string (s) fun loop {i:nat | i <= n} .. ( f: char - string , s: string n, i: size_t i , res: &res_t? >> res_t ) : void = let val c = string_test_char_at (s, i) in if c <> NUL then let val () = res := list_vt_cons {..} {0} (f c, ?); val+ list_vt_cons (_, !p_res1) = res in loop (f, s, i+1, !p_res1); fold@ res end else begin res := list_vt_nil () end // end of [if] end (* end of [loop] *) var res: res_t; val () = loop (f, s, 0, res) val sbp = stringlst_concat (__cast res) where { extern castfn __cast (_: !List_vt string): List string } // end of [val] val () = list_vt_free (res) in string_of_strptr (sbp) end (* end of [translate] *) (* ****** ****** *) implement tokens (isdelim, s) = let viewtypedef res_t = List_vt string val [n:int] s = string1_of_string (s) fn* loop1 {i:nat | i <= n} .. ( isdelim: char - bool , s: string n, i: size_t i , res: &res_t? >> res_t ) : void = let val c = string_test_char_at (s, i) in if c <> NUL then begin if isdelim c then loop1 (isdelim, s, i+1, res) else loop2 (isdelim, s, i, i, res) end else begin res := list_vt_nil () // loop exits end // end of [if] end (* end of [loop1 *) and loop2 {i0,i:nat | i0 <=i; i <= n} .. ( isdelim: char - bool , s: string n, i0: size_t i0, i: size_t i , res: &res_t? >> res_t ) : void = let val c = string_test_char_at (s, i) in if c <> NUL then begin if isdelim (c) then let val () = res := list_vt_cons {..} {0} (substring (s, i0, i-i0), ?) val+ list_vt_cons (_, !p_res1) = res in loop1 (isdelim, s, i+1, !p_res1); fold@ res end else begin loop2 (isdelim, s, i0, i+1, res) end // end of [if] end else begin res := list_vt_cons (substring (s, i0, i-i0), list_vt_nil ()) end // end of [if] end (* end of [loop2] *) var res: res_t; val () = loop1 (isdelim, s, 0, res) in list0_of_list_vt (res) end // end of [tokens] implement fields (isdelim, s) = let viewtypedef res_t = List_vt string val [n:int] s = string1_of_string (s) fun loop {i0,i:nat | i0 <=i; i <= n} .. ( isdelim: char - bool , s: string n, i0: size_t i0, i: size_t i , res: &res_t? >> res_t ) : void = let val c = string_test_char_at (s, i) in if c <> NUL then begin if isdelim (c) then let val () = res := list_vt_cons {..} {0} (substring (s, i0, i-i0), ?) val+ list_vt_cons (_, !p_res1) = res in loop (isdelim, s, i+1, i+1, !p_res1); fold@ res end else begin loop (isdelim, s, i0, i+1, res) end // end of [if] end else begin res := list_vt_cons (substring (s, i0, i-i0), list_vt_nil ()) end // end of [if] end (* end of [loop] *) var res: res_t; val () = loop (isdelim, s, 0, 0, res) in list0_of_list_vt (res) end // end of [fields] (* ****** ****** *) implement isPrefix (s1, s2) = let val [n1:int] s1 = string1_of_string (s1) val [n2:int] s2 = string1_of_string (s2) fun loop {i:nat | i <= min(n1,n2)} (s1: string n1, s2: string n2, i: size_t i): bool = let val c1 = string_test_char_at (s1, i) in if c1 <> NUL then let val c2 = string_test_char_at (s2, i) in if c1 = c2 then loop (s1, s2, i+1) else false end else true end (* loop *) in loop (s1, s2, 0) end // end of [isPrefix] implement isSubstring (s1, s2) = let val s1 = string1_of_string s1 and s2 = string1_of_string s2 in string_index_of_string (s2, s1) >= 0 end // end of [isSubstring] local staload "libc/SATS/string.sats" in // in of [local] implement isSuffix (s1, s2) = let val s1 = string1_of_string s1 and s2 = string1_of_string s2 val n1 = string1_length s1 and n2 = string1_length s2 in if n1 > n2 then false else (substrcmp (s1, 0, s2, n2 - n1) = 0) end (* end of [isSuffix] *) end // end of [local] (* ****** ****** *) implement lt (s1, s2) = lt_string_string (s1, s2) implement lte (s1, s2) = lte_string_string (s1, s2) implement gt (s1, s2) = gt_string_string (s1, s2) implement gte (s1, s2) = gte_string_string (s1, s2) implement eq (s1, s2) = eq_string_string (s1, s2) implement neq (s1, s2) = neq_string_string (s1, s2) implement compare (s1, s2) = compare_string_string (s1, s2) implement collate (f, s1, s2) = let val [n1:int] s1 = string1_of_string (s1) val [n2:int] s2 = string1_of_string (s2) fun loop {i:nat | i <= min(n1,n2)} ( f: (char, char) - int, s1: string n1, s2: string n2, i: size_t i ) : int = let val c1 = string_test_char_at (s1, i) val c2 = string_test_char_at (s2, i) in if c1 <> NUL then begin if c2 <> NUL then let val sgn = f (c1, c2) in if sgn = 0 then loop (f, s1, s2, i+1) else sgn end else 1 (*s1 > s2*) end else begin if c2 <> NUL then ~1 (*s1 < s2*) else 0 (*s1 = s2*) end // end of [if] end (* loop *) in loop (f, s1, s2, 0) end // end of [collate] (* ****** ****** *) (* end of [string.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/bool.dats0000664000175000017500000000407412223166162021104 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 (* ****** ****** *) // // SML Basis Library: Bool (http://www.standardml.org/Basis/bool.html) // (* ****** ****** *) staload "libats/smlbas/SATS/bool.sats" (* ****** ****** *) implement not (b) = ~b implement toString (b) = if b then "true" else "false" // end of [toString] local staload "libc/SATS/string.sats" in // in of [local] implement fromString (s) = case+ s of | _ when strncmp (s, "true", 4) = 0 => option0_some true | _ when strncmp (s, "false", 5) = 0 => option0_some false | _ => option0_none () // end of [fromString] end // end of [local] (* ****** ****** *) (* end of [bool.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/time.dats0000664000175000017500000000530212223166162021102 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Time (http://www.standardml.org/Basis/time.html) // (* ****** ****** *) staload REAL = "libats/smlbas/SATS/real.sats" macdef r2d (x) = $REAL.double_of_real ,(x) macdef d2r (x) = $REAL.real_of_double ,(x) (* ****** ****** *) staload "libats/smlbas/SATS/time.sats" (* ****** ****** *) assume time_t0ype = $REAL.real (* ****** ****** *) implement toReal (x) = x implement fromReal (x) = x (* ****** ****** *) implement fprint_time (out, x) = $REAL.fprint_real (out, x) (* ****** ****** *) implement toSeconds (x) = lint_of_double (r2d (x)) implement fromSeconds (x) = d2r (double_of_lint (x)) implement toMilliseconds (x) = llint_of_double (1E3 * r2d (x)) implement fromMilliseconds (x) = d2r (1E-3 * double_of_llint (x)) implement toMicroseconds (x) = llint_of_double (1E6 * r2d (x)) implement fromMicroseconds (x) = d2r (1E-6 * double_of_llint (x)) implement toNanoseconds (x) = llint_of_double (1E9 * r2d (x)) implement fromNanoseconds (x) = d2r (1E-9 * double_of_llint (x)) (* ****** ****** *) local staload TIME = "libc/SATS/time.sats" in // in of [local] implement now () = d2r ($TIME.double_of_time ($TIME.time_get ())) end // end of [local] (* ****** ****** *) (* end of [time.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/real.dats0000664000175000017500000000702012223166162021066 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Real (http://www.standardml.org/Basis/real.html) // (* ****** ****** *) %{^ extern double round (double) ; extern double trunc (double) ; %} staload MATH = "libc/SATS/math.sats" (* ****** ****** *) staload "libats/smlbas/SATS/real.sats" (* ****** ****** *) // please note that this does not really assume real_t0ype = double // implement the specification given in [smlbas]. (* ****** ****** *) implement real_of_double (x) = x // cast function implement double_of_real (x) = x // cast function (* ****** ****** *) implement fprint_real (out, x) = fprint_double (out, x) (* ****** ****** *) implement add_real_real (r1, r2) = add_double_double (r1, r2) implement sub_real_real (r1, r2) = sub_double_double (r1, r2) implement mul_real_real (r1, r2) = mul_double_double (r1, r2) implement div_real_real (r1, r2) = div_double_double (r1, r2) implement mod_real_real (r1, r2) = $MATH.fmod (r1, r2) (* ****** ****** *) implement muladd_real_real (r1, r2, r3) = add_double_double (mul_double_double (r1, r2), r3) implement mulsub_real_real (r1, r2, r3) = sub_double_double (mul_double_double (r1, r2), r3) (* ****** ****** *) implement neg_real (r) = neg_double (r) implement abs_real (r) = abs_double (r) (* ****** ****** *) implement lt_real_real (r1, r2) = lt_double_double (r1, r2) implement lte_real_real (r1, r2) = lte_double_double (r1, r2) implement gt_real_real (r1, r2) = gt_double_double (r1, r2) implement gte_real_real (r1, r2) = gte_double_double (r1, r2) implement eq_real_real (r1, r2) = eq_double_double (r1, r2) implement neq_real_real (r1, r2) = neq_double_double (r1, r2) implement compare_real_real (r1, r2) = compare_double_double (r1, r2) (* ****** ****** *) implement min_real_real (r1, r2) = min_double_double (r1, r2) implement max_real_real (r1, r2) = max_double_double (r1, r2) (* ****** ****** *) implement realCeil (r) = $MATH.ceil (r) implement realFloor (r) = $MATH.floor (r) implement realRound (r) = $MATH.round (r) implement realTrunc (r) = $MATH.trunc (r) (* ****** ****** *) (* end of [real.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/math.dats0000664000175000017500000000537012223166162021102 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Math (http://www.standardml.org/Basis/math.html) // (* ****** ****** *) staload LM = "libc/SATS/math.sats" (* ****** ****** *) staload "libats/smlbas/SATS/real.sats" staload "libats/smlbas/SATS/math.sats" (* ****** ****** *) #define d2r real_of_double #define r2d double_of_real (* ****** ****** *) implement e = d2r ($LM.M_E) // = 2.7182818284590452354 implement pi = d2r ($LM.M_PI) // = 3.14159265358979323846 (* ****** ****** *) implement sqrt (x) = d2r ($LM.sqrt (r2d x)) (* ****** ****** *) implement sin (x) = d2r ($LM.sin (r2d x)) implement cos (x) = d2r ($LM.cos (r2d x)) implement tan (x) = d2r ($LM.tan (r2d x)) (* ****** ****** *) implement asin (x) = d2r ($LM.asin (r2d x)) implement acos (x) = d2r ($LM.acos (r2d x)) implement atan (x) = d2r ($LM.atan (r2d x)) implement atan2 (y, x) = d2r ($LM.atan2 (r2d y, r2d x)) (* ****** ****** *) implement exp (x) = d2r ($LM.exp (r2d x)) implement pow (x, y) = d2r ($LM.pow (r2d x, r2d y)) (* ****** ****** *) implement ln (x) = d2r ($LM.log (r2d x)) implement log10 (x) = d2r ($LM.log10 (r2d x)) (* ****** ****** *) implement sinh (x) = d2r ($LM.sinh (r2d x)) implement cosh (x) = d2r ($LM.cosh (r2d x)) implement tanh (x) = d2r ($LM.tanh (r2d x)) (* ****** ****** *) (* end of [math.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/array2.dats0000664000175000017500000003403012223166162021344 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Array2 (http://www.standardml.org/Basis/array2.html) // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/array2.sats" (* ****** ****** *) (* ** HX: note that RowMajor representation is assumed *) assume array2_t0ype_type (a: t@ype) = [m,n:nat] [l:addr] '{ data= ptr l, view= vbox (matrix_v (a, m, n, l)), row= size_t m, col= size_t n } // end of [array2_t0ype_type] (* ****** ****** *) extern fun vbox_make_view_ptr_matrix {a:viewt@ype} {m,n:int} {l:addr} ( pf: matrix_v (a, m, n, l) | p: ptr l):<> (vbox (matrix_v (a, m, n, l)) | void ) = "atspre_vbox_make_view_ptr" // end of [vbox_make_view_ptr_matrix] (* ****** ****** *) implement{a} array (row, col, ini) = let val [m:int] m = size1_of_size row and [n:int] n = size1_of_size col val (pf_mul | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat pf_mul val [l:addr] (pfgc, pfarr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) // end of [val] prval () = free_gc_elim {a?} (pfgc) // return the certificate val () = array_ptr_initialize_elt (!p_arr, mn, ini) prval pf_mat = matrix_v_of_array_v (pf_mul, pfarr) val (pf_mat_box | ()) = vbox_make_view_ptr_matrix (pf_mat | p_arr) in #[m,n | #[l | '{ data= p_arr, view= pf_mat_box, row= m, col= n} ] ] end // end of [array] (* ****** ****** *) extern fun{a:t@ype} array_ptr_initialize_lstlst {m,n:nat} {mn:int} ( pf_mul: MUL (m, n, mn) | base: &(@[a?][mn]) >> @[a][mn], m: size_t m, xss: list (list (a, m), n) ) :<> void // end of [array_ptr_initialize_lstlst] implement{a} array_ptr_initialize_lstlst {m,n}{mn} (pf_mul | base, m, xss) = let val (pf_ofs | ofs) = mul2_size1_size1 (m, sizeof) fun loop {n:nat} {mn:int} {l:addr} .. ( pf_mul: MUL (n, m, mn), pfarr: !array_v (a?, mn, l) >> array_v (a, mn, l) | p_arr: ptr l, xss: list (list (a, m), n) ) : void = case+ xss of | list_nil () => () where { prval MULbas () = pf_mul prval () = array_v_unnil (pfarr); prval () = pfarr := array_v_nil {a} () } // end of [list_nil] | list_cons (xs, xss) => let prval pf1_mul = mul_add_const {~1} {n,m} (pf_mul) prval () = mul_nat_nat_nat (pf1_mul) prval (pf1_arr, pf2_arr) = array_v_split {a?} {mn} {m} (pf_ofs, pfarr) val () = array_ptr_initialize_lst (!p_arr, xs) val () = loop (pf1_mul, pf2_arr | p_arr + ofs, xss) prval () = pfarr := array_v_unsplit {a} (pf_ofs, pf1_arr, pf2_arr) in // nothing end (* end of [list_cons] *) // end of [loop] in loop (mul_commute (pf_mul), view@ base | &base, xss) end // end of [array_ptr_initialize_lstlst] (* ****** ****** *) implement{a} fromList (xss) = let val n = list0_length (xss) val [n:int] n = int1_of_int (n) val () = (if (n > 0) then () else $raise Size ()): [n > 0] void val- list0_cons (xs, xss1) = xss val [m:int] xs = list_of_list0 (xs) val m = list_length (xs) val () = auxcheck (m, xss1) where { fun auxcheck (m: int, xss: list0 (list0 a)): void = case+ xss of | list0_cons (xs, xss) => begin if list0_length (xs) = m then auxcheck (m, xss) else $raise Size () end // end of [list0_cons] | list0_nil () => () // end of [auxcheck] } // end of [val] // // There should be a better way of doing this // val xss = __cast (xss) where { extern castfn __cast (xss: list0 (list0 a)):<> list (list (a, m), n) } (* end of [val] *) // val m = size1_of_int1 (m) and n = size1_of_int1 (n) val (pf_mul | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat pf_mul val [l:addr] (pfgc, pfarr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) // end of [val] prval () = free_gc_elim {a?} (pfgc) // return the certificate val () = array_ptr_initialize_lstlst (pf_mul | !p_arr, m, xss) prval pf_mat = matrix_v_of_array_v (pf_mul, pfarr) val (pf_mat_box | ()) = vbox_make_view_ptr_matrix (pf_mat | p_arr) in #[m,n | #[l | '{ data= p_arr, view= pf_mat_box, row= m, col= n} ] ] end // end of [fromList] (* ****** ****** *) implement{a} tabulate (trv, m, n, f) = let val [m:int] m = size1_of_size (m) and [n:int] n = size1_of_size (n) val () = (if m > 0 then () else $raise Size ()): [m > 0] void val () = (if n > 0 then () else $raise Size ()): [n > 0] void val [mn:int] (pf_mul_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mul_mn) val [l:addr] (pfgc, pfarr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) // end of [val] prval () = free_gc_elim {a?} (pfgc) // return the certificate prval pfarr = __cast pfarr where { extern prfun __cast (pfarr: array_v (a?, mn, l)):<> array_v (a, mn, l) } (* end of [prval] *) val _0 = size1_of_int1 0 and _1 = size1_of_int1 1 val () = case+ :(pfarr: array_v (a, mn, l)) => trv of | RowMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (i: sizeLte m) => (i := _0; i < m; i := i + _1) for* (i: sizeLt m, j: sizeLte n) => (j := _0; j < n; j := j + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in p_arr->[k1] := f (i, j); k := k + _1 end // end of [for] // end of [for] end // end of [RowMajor] | ColMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (j: sizeLte n) => (j := _0; j < n; j := j + _1) let val () = k := j in for* (i: sizeLte m, j: sizeLt n) => (i := _0; i < m; i := i + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in p_arr->[k1] := f (i, j); k := k + n end // end of [for] end // end of [for] end (* end of [ColMajor] *) // end of [val] prval pf_mat = matrix_v_of_array_v {a} (pf_mul_mn, pfarr) val (pf_mat_box | ()) = vbox_make_view_ptr_matrix (pf_mat | p_arr) in #[m,n | #[l | '{ data= p_arr, view= pf_mat_box, row= m, col= n} ] ] end // end of [tabulate] (* ****** ****** *) local prfun lemma_for_matrix_subscripting {m,n:nat} {i:nat | i < m} {mn,p:int} .. (pf1: MUL (m, n, mn), pf2: MUL (i, n, p)): [p+n <= mn] void = let prval MULind pf11 = pf1 in sif i < m-1 then begin lemma_for_matrix_subscripting (pf11, pf2) end else let // i = m-1 prval () = mul_isfun (pf11, pf2) in // empty end // end of [sif] end // end of [lemma_for_matrix_subscripting] in // in of [local] implement{a} sub (M, i, j) = let val m = M.row and n = M.col val i = size1_of_size (i) and j = size1_of_size (j) in if i < m then if j < n then let prval vbox pf_mat = M.view prval (pf_mul_mn, pfarr) = array_v_of_matrix_v {a} (pf_mat) val (pf_mul_i_n | i_n) = mul2_size1_size1 (i, n) prval () = mul_nat_nat_nat pf_mul_i_n prval () = lemma_for_matrix_subscripting (pf_mul_mn, pf_mul_i_n) val M_data = M.data val x = !M_data.[i_n+j] prval () = pf_mat := matrix_v_of_array_v (pf_mul_mn, pfarr) in x // return value end else begin $raise Subscript () end // end of [if] else begin $raise Subscript () end // end of [if] end (* end of [sub] *) implement{a} update (M, i, j, x) = let val m = M.row and n = M.col val i = size1_of_size (i) and j = size1_of_size (j) in if i < m then if j < n then let prval vbox pf_mat = M.view prval (pf_mul_mn, pfarr) = array_v_of_matrix_v {a} (pf_mat) val (pf_mul_i_n | i_n) = mul2_size1_size1 (i, n) prval () = mul_nat_nat_nat pf_mul_i_n prval () = lemma_for_matrix_subscripting (pf_mul_mn, pf_mul_i_n) val M_data = M.data val () = !M_data.[i_n+j] := x prval () = pf_mat := matrix_v_of_array_v (pf_mul_mn, pfarr) in // no return value end else begin $raise Subscript () end // end of [if] else begin $raise Subscript () end // end of [if] end (* end of [sub] *) end // end of [local] (* ****** ****** *) implement dimensions (M) = @(M.row, M.col) implement nRows (M) = M.row implement nCols (M) = M.col (* ****** ****** *) implement{a} app ( trv, f, [m,n:int] [l:addr] M ) = let val p_arr = M.data; prval vbox pf_mat = M.view val m = M.row and n = M.col prval [mn:int] ( pf_mul_mn, pfarr ) = array_v_of_matrix_v {a} (pf_mat) val _0 = size1_of_int1 0 and _1 = size1_of_int1 1 val () = case+ trv of | RowMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (i: sizeLte m) => (i := _0; i < m; i := i + _1) for* (i: sizeLt m, j: sizeLte n) => (j := _0; j < n; j := j + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in $effmask_ref (f (p_arr->[k1])); k := k + _1 end // end of [for] // end of [for] end // end of [RowMajor] | ColMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (j: sizeLte n) => (j := _0; j < n; j := j + _1) let val () = k := j in for* (i: sizeLte m, j: sizeLt n) => (i := _0; i < m; i := i + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in $effmask_ref (f (p_arr->[k1])); k := k + n end // end of [for] end // end of [for] end (* end of [ColMajor] *) // end of [val] in pf_mat := matrix_v_of_array_v (pf_mul_mn, pfarr) end // end of [app] (* ****** ****** *) implement{a,b} fold ( trv, f, ini, [m,n:int] [l:addr] M ) = let val p_arr = M.data; prval vbox pf_mat = M.view val m = M.row and n = M.col prval [mn:int] ( pf_mul_mn, pfarr ) = array_v_of_matrix_v {a} (pf_mat) val _0 = size1_of_int1 0 and _1 = size1_of_int1 1 var res: b = ini val () = case+ trv of | RowMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (i: sizeLte m) => (i := _0; i < m; i := i + _1) for* (i: sizeLt m, j: sizeLte n) => (j := _0; j < n; j := j + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in res := $effmask_ref (f (p_arr->[k1], res)); k := k + _1 end // end of [for] // end of [for] end // end of [RowMajor] | ColMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (j: sizeLte n) => (j := _0; j < n; j := j + _1) let val () = k := j in for* (i: sizeLte m, j: sizeLt n) => (i := _0; i < m; i := i + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in res := $effmask_ref (f (p_arr->[k1], res)); k := k + n end // end of [for] end // end of [for] end (* end of [ColMajor] *) // end of [val] in pf_mat := matrix_v_of_array_v (pf_mul_mn, pfarr) end // end of [fold] (* ****** ****** *) implement{a} modify ( trv, f, [m,n:int] [l:addr] M ) = let val p_arr = M.data; prval vbox pf_mat = M.view val m = M.row and n = M.col prval [mn:int] ( pf_mul_mn, pfarr ) = array_v_of_matrix_v {a} (pf_mat) val _0 = size1_of_int1 0 and _1 = size1_of_int1 1 val () = case+ trv of | RowMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (i: sizeLte m) => (i := _0; i < m; i := i + _1) for* (i: sizeLt m, j: sizeLte n) => (j := _0; j < n; j := j + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in p_arr->[k1] := $effmask_ref (f (p_arr->[k1])); k := k + _1 end // end of [for] // end of [for] end // end of [RowMajor] | ColMajor () => let var i: size_t? and j: size_t? ; var k: size_t = _0 in for* (j: sizeLte n) => (j := _0; j < n; j := j + _1) let val () = k := j in for* (i: sizeLte m, j: sizeLt n) => (i := _0; i < m; i := i + _1) let val k1 = __cast k where { extern castfn __cast (k: size_t):<> sizeLt (mn) } // end of [val] in p_arr->[k1] := $effmask_ref (f (p_arr->[k1])); k := k + n end // end of [for] end // end of [for] end (* end of [ColMajor] *) // end of [val] in pf_mat := matrix_v_of_array_v (pf_mul_mn, pfarr) end // end of [modify] (* ****** ****** *) (* end of [array2.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/listPair.dats0000664000175000017500000001662112223166162021741 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: ListPair (http://www.standardml.org/Basis/list-pair.html) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for dynamic loading (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/listPair.sats" (* ****** ****** *) implement{a,b} zip (xs, ys) = res where { viewtypedef res_t = List_vt @(a, b) fun loop {m,n:nat} .. ( xs: list (a, m), ys: list (b, n), res: &res_t? >> res_t ) :<> void = case+ (xs, ys) of | (list_cons (x, xs), list_cons (y, ys)) => let val () = res := list_vt_cons {..} {0} (@(x, y), ?) val+ list_vt_cons (_, !p_res1) = res in loop (xs, ys, !p_res1); fold@ res end // end of [list_cons, list_cons] | (_, _) =>> (res := list_vt_nil ()) var res: res_t val xs = list_of_list0 (xs) and ys = list_of_list0 (ys) val () = loop (xs, ys, res) val res = list0_of_list_vt (res) } // end of [zip] implement{a,b} zipEq (xs, ys) = let viewtypedef res_t = List_vt @(a, b) fun loop {m,n:nat} .. ( xs: list (a, m), ys: list (b, n), res: &res_t? >> res_t, err: &int ) :<> void = case+ (xs, ys) of | (list_cons (x, xs), list_cons (y, ys)) => let val () = res := list_vt_cons {..} {0} (@(x, y), ?) val+ list_vt_cons (_, !p_res1) = res in loop (xs, ys, !p_res1, err); fold@ res end // end of [list_cons, list_cons] | (list_nil _, list_nil _) => (res := list_vt_nil ()) | (_, _) =>> (err := 1; res := list_vt_nil ()) // end of [loop] var res: res_t?; var err: int = 0 val xs = list_of_list0 (xs) and ys = list_of_list0 (ys) val () = loop (xs, ys, res, err) in if err = 0 then list0_of_list_vt (res) else begin list_vt_free (res); $raise UnequalLengths () end // end of [if] end (* end of [zipEq] *) (* ****** ****** *) implement{a,b} unzip (xys) = (xs, ys) where { val xys = list_of_list0 (xys) val (xs, ys) = list_unzip (xys) val xs = list0_of_list_vt xs and ys = list0_of_list_vt ys } (* end of [unzip] *) (* ****** ****** *) local fun{a,b:t@ype} loop ( f: (a, b) - void, xs: list0 a, ys: list0 b ) : int(*err*) = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => (f (x, y); loop (f, xs, ys)) | (list0_nil (), list0_nil ()) => 0 | (_, _) => 1 // end of [loop] in // in of [local] implement{a,b} app (f, xs, ys) = let val _(*int*) = loop (f, xs, ys) in () end // end of [app] implement{a,b} appEq (f, xs, ys) = let val err = loop (f, xs, ys) in if err > 0 then $raise UnequalLengths () else () end // end of [zipEq] end // end of [local] (* ****** ****** *) local fun{a,b:t@ype}{c:t@ype} loop ( f: (a, b) - c , xs: list0 a, ys: list0 b, res: &List_vt c? >> List_vt c , err: &int ) : void = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => let val () = res := list_vt_cons {..} {0} (f (x, y), ?); val+ list_vt_cons (_, !p_res1) = res in loop (f, xs, ys, !p_res1, err); fold@ res end // end of [list0_cons, list0_cons] | (list0_nil (), list0_nil ()) => res := list_vt_nil () | (_, _) => (err := 1; res := list_vt_nil ()) // end of [app_err] in // in of [local] implement{a,b}{c} map (f, xs, ys) = let var res: List_vt c?; var err: int = 0 val () = loop (f, xs, ys, res, err) in list0_of_list_vt (res) end (* end of [mapEq] *) implement{a,b}{c} mapEq (f, xs, ys) = let var res: List_vt c?; var err: int = 0 val () = loop (f, xs, ys, res, err) in if err = 0 then list0_of_list_vt (res) else begin list_vt_free (res); $raise UnequalLengths () end // end of [if] end (* end of [mapEq] *) end // end of [local] (* ****** ****** *) implement{a,b}{c} foldl (f, ini, xs, ys) = loop (ini, xs, ys) where { fun loop (ini: c, xs: list0 a, ys: list0 b): c = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => loop (f (x, y, ini), xs, ys) | (_, _) => ini // end of [loop] } // end of [foldl] implement{a,b}{c} foldlEq (f, ini, xs, ys) = loop (ini, xs, ys) where { fun loop (ini: c, xs: list0 a, ys: list0 b): c = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => loop (f (x, y, ini), xs, ys) | (list0_nil (), list0_nil ()) => ini | (_, _) => $raise UnequalLengths () // end of [loop] } // end of [foldlEq] (* ****** ****** *) implement{a,b}{c} foldr (f, snk, xs, ys) = aux (snk, xs, ys) where { fun aux (snk: c, xs: list0 a, ys: list0 b): c = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => f (x, y, aux(snk, xs, ys)) | (_, _) => snk // end of [aux] } // end of [foldr] implement{a,b}{c} foldrEq (f, snk, xs, ys) = aux (snk, xs, ys) where { fun aux (snk: c, xs: list0 a, ys: list0 b): c = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => f (x, y, aux (snk, xs, ys)) | (list0_nil (), list0_nil ()) => snk | (_, _) => $raise UnequalLengths () // end of [aux] } // end of [foldrEq] (* ****** ****** *) implement{a,b} all (f, xs, ys) = loop (f, xs, ys) where { fun loop (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => f (x, y) andalso loop (f, xs, ys) | (_, _) => true // end of [loop] } // end of [all] implement{a,b} allEq (f, xs, ys) = loop (f, xs, ys) where { fun loop (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => f (x, y) andalso loop (f, xs, ys) | (list0_nil (), list0_nil ()) => true | (_, _) => false // end of [loop] } // end of [all] (* ****** ****** *) implement{a,b} exists (f, xs, ys) = loop (f, xs, ys) where { fun loop (f: (a, b) - bool, xs: list0 a, ys: list0 b): bool = case+ (xs, ys) of | (list0_cons (x, xs), list0_cons (y, ys)) => f (x, y) orelse loop (f, xs, ys) | (_, _) => false // end of [loop] } // end of [all] (* ****** ****** *) (* end of [listPair.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/date.dats0000664000175000017500000000745212223166162021071 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Date (http://www.standardml.org/Basis/date.html) // (* ****** ****** *) staload "libats/smlbas/SATS/date.sats" (* ****** ****** *) assume date = '{ year= int, month= month, day= int , hour= int, minute= int, second= int , offset= option0 ($TIME.time) } // end of [date] (* ****** ****** *) implement date ( year , month , day , hour , minute , second , ofsopt ) : date = '{ year= year, month= month, day= day , hour= hour, minute= minute, second= second , offset= ofsopt } // end of [date] (* ****** ****** *) fn int_of_month (month: month): int = case+ month of | Jan () => 0 | Feb () => 1 | Mar () => 2 | Apr () => 3 | May () => 4 | Jun () => 5 | Jul () => 6 | Aug () => 7 | Sep () => 8 | Oct () => 9 | Nov () => 10 | Dec () => 11 // end of [int_of_month] (* ****** ****** *) implement year (date) = date.year implement month (date) = date.month implement day (date) = date.day implement hour (date) = date.hour implement minute (date) = date.minute implement second (date) = date.second (* fun weekday (_: date): weekday fun yearday (_: date): int *) implement offset (date) = date.offset (* fun isDst (_: date): option0 (bool) fun localOffset (): $Time.time *) implement compare_date_date (d1, d2) = begin case+ 0 of | _ when d1.year > d2.year => 1 | _ when d1.year < d2.year => ~1 | _ (* same year *) => let val m1 = int_of_month (d1.month) and m2 = int_of_month (d2.month) in case+ 0 of | _ when m1 > m2 => 1 | _ when m1 < m2 => ~1 | _ (* same month *) => begin case+ 0 of | _ when d1.day > d2.day => 1 | _ when d1.day < d2.day => ~1 | _ (* same day *) => begin case+ 0 of | _ when d1.hour > d2.hour => 1 | _ when d1.hour < d2.hour => ~1 | _ (* same hour *) => begin case+ 0 of | _ when d1.minute > d2.minute => 1 | _ when d1.minute < d2.minute => ~1 | _ (* same minute *) => begin case+ 0 of | _ when d1.second > d2.second => 1 | _ when d1.second < d2.second => ~1 | _ (* same second *) => 0 end end end end end end // end of [compare_date_date] (* ****** ****** *) (* fun toString (d: date): string fun fromString (s: string): date *) (* ****** ****** *) (* end of [date.dats] *) ats-lang-anairiats-0.2.11/libats/smlbas/DATS/char.dats0000664000175000017500000000770212223166162021067 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: Summer, 2009 // (* ****** ****** *) // // SML Basis Library: Char (http://www.standardml.org/Basis/char.html) // (* ****** ****** *) staload "libats/smlbas/SATS/general.sats" (* ****** ****** *) staload "libats/smlbas/SATS/char.sats" (* ****** ****** *) implement minChar = '\000' implement maxChar = char_of_int (UCHAR_MAX) implement maxOrd = uint_of_int (UCHAR_MAX) (* ****** ****** *) implement ord (c) = uint_of_char c implement chr (i) = if i <= maxOrd then char_of_uint (i) else $raise Chr () // end of [chr] (* ****** ****** *) implement succ (c) = let val u = ord (c) in if u < maxOrd then char_of_uint (succ_uint u) else $raise Chr () end // end of [succ] implement pred (c) = let val u = ord (c) in if u > 0U(*minOrd*) then char_of_uint (pred_uint u ) else $raise Chr () end // end of [pred] (* ****** ****** *) implement lt (c1, c2) = lt_char_char (c1, c2) implement lte (c1, c2) = lte_char_char (c1, c2) implement gt (c1, c2) = gt_char_char (c1, c2) implement gte (c1, c2) = gte_char_char (c1, c2) implement compare (c1, c2) = compare_char_char (c1, c2) (* ****** ****** *) implement contains (s, c) = string_contains (s, c) implement notContains (s, c) = ~string_contains (s, c) (* ****** ****** *) implement isAscii (c) = char_isascii (c) implement isAlpha (c) = char_isalpha (c) implement isAlphaNum (c) = char_isalnum (c) implement isCntrl (c) = char_iscntrl (c) implement isDigit (c) = char_isdigit (c) implement isGraph (c) = char_isgraph (c) implement isHexDigit (c) = char_isxdigit (c) implement isLower (c) = char_islower (c) implement isPrint (c) = char_isprint (c) implement isSpace (c) = char_isspace (c) implement isPunct (c) = char_ispunct (c) implement isUpper (c) = char_isupper (c) (* ****** ****** *) implement toLower (c) = char_tolower (c) implement toUpper (c) = char_toupper (c) (* ****** ****** *) #define p2s string_of_strptr implement toCString (c) = case+ c of | '\\' => "\\\\" | '\"' => "\\\"" | '?' => "\\?" | '\'' => "\\'" | '\a' => "\\a" | '\b' => "\\b" | '\t' => "\\t" | '\n' => "\\n" | '\v' => "\\v" | '\f' => "\\f" | '\r' => "\\r" | _ when char_isprint c => let val sbp = string_make_char (1, c) in string1_of_strbuf sbp end // end of [_ when ...] | _ => let val u = ord c val u3 = u land 0x7U val u = u >> 3 val u2 = u land 0x7U val u = u >> 3 val u1 = u land 0x7U in p2s (sprintf ("\\%o%o%o", @(u1,u2,u3))) end // end of [_] // end of [toCString] (* ****** ****** *) (* end of [char.dats] *) ats-lang-anairiats-0.2.11/libats/lex/0000700000175000017500000000000012223166162016027 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/lex/tables.dats0000664000175000017500000002240412223166162020174 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Anairiats - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (* hwxi AT cs DOT bu DOT edu *) // Time: July 2007 // (* ****** ****** *) staload "libats/lex/lexing.sats" (* ****** ****** *) staload _(*anonymous*) = "prelude/DATS/reference.dats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) dataviewtype tblopt = | {n:nat} {l:addr} tblopt_some of (array_v (int16, n, l) | ptr l, int n) | tblopt_none extern fun new_tbloptref_some {n:nat} {l:addr} (pf: array_v (int16, n, l) | p: ptr l, n: int n): ref tblopt = "new_tbloptref_some" implement new_tbloptref_some (pf | p, n) = let val tblopt = tblopt_some (pf | p, n) in ref (tblopt) end // end of [new_tbloptref_some] (* ****** ****** *) extern fun table_ptr_free {a:viewt@ype} {n:nat} {l:addr} (pf: array_v (a, n, l) | p: ptr l):<> void = "table_ptr_free" // end of [table_ptr_free] (* ****** ****** *) %{^ // extern void free (void*) ; // ATSinline() ats_void_type table_ptr_free (ats_ptr_type p) { free (p) ; return ; } // %} // end of [%{^] fn tbloptref_free (r_tblopt: ref tblopt): void = let val (vbox pf_tblopt | p_tblopt) = ref_get_view_ptr r_tblopt in case+ !p_tblopt of | ~tblopt_some (pf | p, n) => begin table_ptr_free {int16} (pf | p); !p_tblopt := tblopt_none () end // end of [tblopt_some] | tblopt_none () => fold@ (!p_tblopt) end // end of [tbloptref_free] (* ****** ****** *) assume accept_table_t = ref (tblopt) assume transition_table_t = ref (tblopt) (* ****** ****** *) extern fun __accept_table_make_fun (ntot: int, nfin: int, s: string): accept_table_t = "__accept_table_make_fun" implement __accept_table_make (ntot) = lam nfin => lam s => __accept_table_make_fun (ntot, nfin, s) // end of [__accept_table_make ntot] implement __accept_table_free (r_tblopt): void = tbloptref_free r_tblopt // end of [__accept_table_free] (* ****** ****** *) extern fun int_of_int16 (x: int16):<> int = "ats_int_of_int16" %{^ // ATSinline() ats_int_type ats_int_of_int16 (ats_int16_type i) { return i ; } // %} // end of [%{^] (* ****** ****** *) implement accept_table_get (r_tblopt, nstate) = let // var ans: int = (0: int) var err: int = (0: int) // val () = let val (vbox pf | p_tblopt) = ref_get_view_ptr (r_tblopt) // end of [val] in case+ !p_tblopt of | tblopt_none () => let prval () = fold@ (!p_tblopt) in err := (1: int) end // end of [tblopt_none] | tblopt_some (!pf | p, n) => let val nstate = int1_of_int nstate // no-op cast in if nstate < 0 then begin err := (2: int); fold@ (!p_tblopt) end else if nstate >= n then begin err := (3: int); fold@ (!p_tblopt) end else let prval pf_v = !pf in ans := int_of_int16 (!p.[nstate]); !pf := pf_v; fold@ (!p_tblopt) end (* end of [if] *) end // end of [tblopt_some] end // end of [val] // in case+ err of | 1 => exit_errmsg (1, "lexing: accept_table_get: table is not available\n") | 2 => exit_errmsg (1, "lexing: accept_table_get: state number is illegal\n") | 3 => exit_errmsg (1, "lexing: accept_table_get: state number is illegal\n") | _ => ans end // end of [accept_table_get] (* ****** ****** *) #define NBITS_PER_BYTE 8 // // the characters with ascii from 0 to 127 and the special character -1 // macdef CHAR_MAX_PLUS1 = 1 << 7 // 128 macdef NUMBER_OF_CHARS = CHAR_MAX_PLUS1 + 1 // 129 extern fun __transition_table_make_fun (n: int, s: string): transition_table_t = "__transition_table_make_fun" // end of [__transition_table_make_fun] implement __transition_table_make (n) = lam s => __transition_table_make_fun (n, s) implement __transition_table_free (r_tblopt) = tbloptref_free (r_tblopt) implement transition_table_get (r_tblopt, nstate, c) = let (* val () = printf ( "transition_table_get: nstate = %i and c = %i\n", @(nstate, int_of_char c) ) // end of [val] *) // var ans: int = (0: int) var err: int = (0: int) // val () = let val (vbox pf | p_tblopt) = ref_get_view_ptr (r_tblopt) // end of [val] in case+ !p_tblopt of | tblopt_none () => begin err := (1: int); fold@ (!p_tblopt) end // end of [tblopt_none] | tblopt_some (!pf | p, n) => let (* Note that [int_of_schar] rather than [int_of_char] is used. This change was made after Eckehard Berns (ecki@ecki.to) reported a bug due to [char] being treated as [unsigned char]. *) // [c] is treated as the null character if [c] > CHAR_MAX holds val c = (if c < CHAR_MAX_PLUS1 then c else 0(*null*)): int val c1 = c + 1 val i = int1_of_int ((nstate - 1) * NUMBER_OF_CHARS + c1) (* val () = $effmask_all begin printf ("transition_table_get: nstate = %i\n", @(nstate)) printf ("transition_table_get: n = %i and i = %i\n", @(n,i)) end // end of [val] *) in if i < 0 then begin err := (2: int); fold@ (!p_tblopt) end else if i >= n then begin err := (3: int); fold@ (!p_tblopt) end else let prval pf_v = !pf in ans := int_of_int16 (!p.[i]); !pf := pf_v; fold@ (!p_tblopt) end (* end of [if] *) end // end of [tblopt_some] end // end of [val] // (* val () = begin prerr "transition_table_get: ans = "; prerr ans; prerr_newline () end // end of [val] *) // in case+ err of | 1 => exit_errmsg (1, "lexing: transition_table_get: table is not available\n") | 2 => exit_errmsg (1, "lexing: transition_table_get: state number is illegal\n") | 3 => exit_errmsg (1, "lexing: transition_table_get: state number is illegal\n") | _ => ans end // end of [transition_table_get] (* ****** ****** *) %{ #define NBITS_PER_BYTE 8 #define NUMBER_OF_CHARS ((1 << NBITS_PER_BYTE - 1) + 1) extern void *malloc (size_t bsz) ; extern void *calloc (size_t n, size_t tsz) ; ats_ptr_type __accept_table_make_fun ( ats_int_type ntot, ats_int_type nfin, ats_ptr_type s0 ) { int i, nstate, irule, sz ; ats_int16_type *p0 ; ats_uchar_type *s ; ats_ptr_type res ; // s = (ats_uchar_type*)s0; /* // [calloc] is used as only integers are to be stored; thus, // there is no need to scan the allocated memory during GC; // the allocated memory is freed by a call to [free] */ sz = ntot + 1 ; p0 = calloc(sz, sizeof(ats_int16_type)) ; // for (i = 0 ; i < nfin ; ++i) { nstate = (s[0] << NBITS_PER_BYTE) + s[1] ; s += 2 ; p0[nstate] = (s[0] << NBITS_PER_BYTE) + s[1] ; s += 2 ; /* fprintf (stdout, "%i -> %i\n", nstate, p0[nstate]) ; */ } /* end of [for] */ // res = new_tbloptref_some (p0, sz) ; // /* fprintf (stdout, "__accept_table_make_fun: sz = %i\n", sz); fprintf (stdout, "__accept_table_make_fun: ptr = %p\n", p0); fprintf (stdout, "__accept_table_make_fun: res = %p\n", res); */ return res ; } /* end of [__accept_table_make_fun] */ ats_ptr_type __transition_table_make_fun (ats_int_type n, ats_ptr_type s0) { int i, j, c, sz; ats_int16_type *p0, *p ; ats_uchar_type *s ; ats_ptr_type res ; // sz = n * NUMBER_OF_CHARS ; /* // [malloc] is used to allocate memory for storing integers; // thus, there is no need to scan the allocated memory during GC; // the allocated memory is freed by a call to [free] */ p0 = malloc (sz*sizeof(ats_int16_type)) ; p = p0 ; // s = (ats_uchar_type*)s0; // for (i = 0 ; i < n ; ++i) { for (j = 0 ; j < NUMBER_OF_CHARS ; ++j) { *p = (s[0] << NBITS_PER_BYTE) + s[1] ; /* fprintf (stdout, "__transition_table_make_fun: %i: *p = %i\n", j, *p); */ s += 2 ; ++p ; } /* end of [for] */ } /* end of [for] */ res = new_tbloptref_some (p0, sz) ; /* fprintf (stdout, "__transition_table_make_fun: sz = %i\n", sz); fprintf (stdout, "__transition_table_make_fun: ptr = %p\n", p0); fprintf (stdout, "__transition_table_make_fun: res = %p\n", res); */ return res ; } /* end of [__transition_table_make_fun] */ %} // end of [%{] (* ****** ****** *) (* end of [tables.dats] *) ats-lang-anairiats-0.2.11/libats/lex/lexing.dats0000664000175000017500000005303312223166162020212 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) %{^ #include "libc/CATS/stdio.cats" typedef struct { unsigned char *buf_ptr ; int buf_size ; atslex_infile_t infile ; int fstpos ; int fstpos_line ; // line number int fstpos_loff ; // line offset long int fstpos_toff ; // total offset int lstpos ; int lstpos_line ; // line number int lstpos_loff ; // line offset long int lstpos_toff ; // total offset int curpos ; int curpos_line ; // line number int curpos_loff ; // line offset long int curpos_toff ; // total offset int endpos ; } lexbuf ; // end of [typedef] %} // end of [%{^] (* ****** ****** *) staload "libats/lex/lexing.sats" (* ****** ****** *) assume position_t = '{ line= int, loff= int, toff= lint } // end of [position_t] implement position_line (p) = p.line implement position_loff (p) = p.loff implement position_toff (p) = p.toff implement lt_position_position (p1, p2) = p1.toff < p2.toff implement lte_position_position (p1, p2) = p1.toff <= p2.toff implement eq_position_position (p1, p2) = p1.toff = p2.toff implement neq_position_position (p1, p2) = p1.toff <> p2.toff extern fun position_make_int_int_lint (line: int, loff: int, toff: lint): position_t = "position_make_int_int_lint" implement position_make_int_int_lint (line, loff, toff) = '{ line= line, loff= loff, toff= toff } // end of [position_make_int_int_lint] implement fprint_position (pf | fil, pos) = fprintf1_exn ( pf | fil, "%li(line=%i, offs=%i)", @(pos.toff+1L, pos.line+1, pos.loff+1) ) // end of [fprint_position] implement print_position (pos) = print_mac (fprint_position, pos) implement prerr_position (pos) = prerr_mac (fprint_position, pos) (* ****** ****** *) viewtypedef infile (v:view) = $extype_struct "atslex_infile_t" of { free= (v | (*none*)) - void , getc= (!v | (*none*)) - int } // end of [infile] assume infile_t = infile (* ****** ****** *) implement infile_free (pf | infil) = let val () = infil.free (pf | (*none*)) val () = cloptr_free (infil.getc) val () = cloptr_free (infil.free) // prval () = __assert (infil) where { extern prval __assert {vt:viewt@ype} (x: vt): void } // end of [val] // in // nothing end // end of [infile_free] implement infile_getc (pf | infil) = infil.getc (pf | (*none*)) (* ****** ****** *) implement infile_make_string (inp) = let // val [n:int] str = string1_of_string (inp) // end of [val] val n = string_length (str) // typedef T = sizeLte n val [l:addr] (pf_gc, pf_at | p) = ptr_alloc_tsz {T} (sizeof) viewdef V = (free_gc_v (T?, l), T @ l) // fn _free ( pf: V | (*none*) ) : void = begin ptr_free {T?} (pf.0, pf.1 | p) end // end of [_free] // fn _getc ( pf: !V | (*none*) ) : int = let prval pf_at = (pf.1: T @ l) val i = !p; val ans: int = begin if i < n then (!p := i+1; int_of_char str[i]) else ~1 end // end of [val] in pf.1 := pf_at; ans end // end of [_getc] // val () = !p := size1_of_int1 (0); // in #[ V | ( @(pf_gc, pf_at) | @{ free= _free, getc= _getc } ) ] end // end of [infile_make_string] (* ****** ****** *) implement infile_make_strptr (inp) = let stavar l1:addr; val inp = inp: strptr l1 val [m,n:int] (pf_free, pf_sb | p_sb) = strbuf_of_strptr inp val n = strbuf_length (!p_sb) // typedef T = sizeLte n val [l2:addr] (pf_gc, pf_at | p) = ptr_alloc_tsz {T} (sizeof) // viewdef V = ( freebyte_gc_v (m, l1), strbuf_v (m, n, l1), free_gc_v (T?, l2), T @ l2 ) // end of [V] fn _free ( pf: V | (*none*) ) : void = let val () = strbufptr_free @(pf.0, pf.1 | p_sb) in ptr_free {T?} (pf.2, pf.3 | p) end // end of [_free] // fn _getc ( pf: !V | (*none*) ) : int = let prval pf1_at = pf.1 prval pf2_at = pf.3 val i = !p val isend = strbuf_is_atend (!p_sb, i) val ans = if :(pf2_at: T @ l2) => isend then ~1 else begin !p := i+1; int_of_char (strbuf_get_char_at (!p_sb, i)) end // end of [if] // end of [val] in pf.1 := pf1_at; pf.3 := pf2_at; ans end // end of [_getc] // val () = !p := size1_of_int1 0 // in #[ V | ( @(pf_free, pf_sb, pf_gc, pf_at) | @{ free= _free, getc= _getc } ) ] end // end of [infile_make_strptr] (* ****** ****** *) implement lexbuf_curpos_prerr (lb) = lexbuf_curpos_fprint (stderr_ref, lb) (* ****** ****** *) local // // staload "libc/SATS/stdio.sats" // extern fun fclose_exn {m:file_mode} {l:addr} (pf: FILE m @ l | p: ptr l): void = "mac#atslib_fclose_exn" // end of [fclose_exn] extern fun fgetc_err {m:file_mode} (pf: file_mode_lte (m, r) | f: &FILE m) : int = "mac#atslib_fgetc_err" // end of [fgetc_err] extern fun getchar (): int = "mac#atslib_getchar" in // in of [local] implement infile_make_file {m} {l} ( pf_fil, pf_mod | fil ) = let viewdef V = FILE m @ l fn _free ( pf_fil: V | (*none*) ) : void = fclose_exn (pf_fil | fil) fn _getc ( pf_fil: !V | (*none*) ) : int = fgetc_err (pf_mod | !fil) in #[ V | (pf_fil | @{ free= _free, getc= _getc }) ] end // end of [infile_make_file] implement infile_make_stdin () = let viewdef V = unit_v fn _free (pf: V | (*none*)): void = () where { prval unit_v () = pf } // end of [_free] fn _getc (pf: !V | (*none*)): int = getchar () in #[ V | (unit_v () | @{ free= _free, getc= _getc } ) ] end // end of [infile_make_stdin] end // end of [local] (* ****** ****** *) implement lexing_engine_lexbuf (lxbf, transtbl, acctbl) = let // fun aux ( lxbf: &lexbuf_t, irule: &int, nstate: int ) : int = if nstate > 0 then let val irule_new = accept_table_get (acctbl, nstate) (* val () = printf ("lexing_engine_lexbuf: aux: nstate = %i\n", @(nstate)) val () = printf ("lexing_engine_lexbuf: aux: irule_new = %i\n", @(irule)) *) val () = if irule_new > 0 then begin lexbuf_lstpos_set (lxbf); irule := irule_new end // end of [val] val c: int = lexbuf_char_next (lxbf) // c >= -1 (* val () = printf ("lexing_engine_lexbuf: c = %i\n", @(c)) *) val nstate = transition_table_get (transtbl, nstate, c) (* val () = printf ("lexing_engine_lexbuf: nstate = %i\n", @(nstate)) *) in aux (lxbf, irule, nstate) end else begin lexbuf_curpos_set (lxbf); (* printf ("lexing_engine_lexbuf: end: irule = %i\n", @(irule)); *) irule end (* end of [if] *) // end of [aux] // var irule = (0: int) // in // lexbuf_fstpos_set (lxbf); aux (lxbf, irule, 1) // end // end of [lexing_engine_lexbuf] implement lexing_engine (transtbl, acctbl) = let val (pf_lexbuf | lexbuf) = lexing_lexbuf_get () val irule = lexing_engine_lexbuf (!lexbuf, transtbl, acctbl) in lexing_lexbuf_set (pf_lexbuf | lexbuf); irule end // end of [lexing_engine] (* ****** ****** *) implement lexeme_get (i) = let val ( pf_lexbuf | lexbuf ) = lexing_lexbuf_get () val c = lexeme_get_lexbuf (!lexbuf, i) in lexing_lexbuf_set (pf_lexbuf | lexbuf); c end // end of [lexeme_get] implement lexeme_set (i, c) = let val ( pf_lexbuf | lexbuf ) = lexing_lexbuf_get () val () = lexeme_set_lexbuf (!lexbuf, i, c) in lexing_lexbuf_set (pf_lexbuf | lexbuf) end // end of [lexeme_set] (* ****** ****** *) implement lexeme_strptr () = let val ( pf_lexbuf | lexbuf ) = lexing_lexbuf_get () val res = lexeme_strptr_lexbuf (!lexbuf) val () = lexing_lexbuf_set (pf_lexbuf | lexbuf); in res end // end of [lexeme_strptr] implement lexeme_string () = let val res = lexeme_strptr () in string_of_strptr (res) end // end of [lexeme_string] (* ****** ****** *) implement lexing_is_eof () = let val ( pf_lexbuf | lexbuf ) = lexing_lexbuf_get () val b = lexbuf_is_eof (!lexbuf) in lexing_lexbuf_set (pf_lexbuf | lexbuf); b end // end of [lexing_is_of] (* ****** ****** *) implement lexing_error () = $raise LexingErrorException (* ****** ****** *) val () = let // initialization val () = markroot () where { extern fun markroot (): void = "lexing_lexbuf_markroot" } // end of [val] in // empty end // end of [val] (* ****** ****** *) %{$ ats_ptr_type lexbuf_fstpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; return position_make_int_int_lint (lxbf->fstpos_line, lxbf->fstpos_loff, lxbf->fstpos_toff) ; } // end of [lexbuf_fstpos_get] ats_void_type lexbuf_fstpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; lxbf->fstpos = lxbf->curpos ; lxbf->fstpos_line = lxbf->curpos_line ; lxbf->fstpos_loff = lxbf->curpos_loff ; lxbf->fstpos_toff = lxbf->curpos_toff ; return ; } // end of [lexbuf_fstpos_set] // ats_ptr_type lexbuf_lstpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; return position_make_int_int_lint (lxbf->lstpos_line, lxbf->lstpos_loff, lxbf->lstpos_toff) ; } // end of [lexbuf_lstpos_get] ats_void_type lexbuf_lstpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; lxbf->lstpos = lxbf->curpos ; lxbf->lstpos_line = lxbf->curpos_line ; lxbf->lstpos_loff = lxbf->curpos_loff ; lxbf->lstpos_toff = lxbf->curpos_toff ; return ; } // end of [lexbuf_lstpos_set] // ats_ptr_type lexbuf_curpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; return position_make_int_int_lint (lxbf->curpos_line, lxbf->curpos_loff, lxbf->curpos_toff) ; } // end of [lexbuf_curpos_get] ats_void_type lexbuf_curpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0 ; lxbf->curpos = lxbf->lstpos ; lxbf->curpos_line = lxbf->lstpos_line ; lxbf->curpos_loff = lxbf->lstpos_loff ; lxbf->curpos_toff = lxbf->lstpos_toff ; return ; } // end of [lexbuf_curpos_set] // ats_int_type lexbuf_size_get ( ats_ptr_type lxbf0 ) { int sz ; lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0; sz = lxbf->lstpos - lxbf->fstpos ; if (sz < 0) { sz += lxbf->buf_size ; } return sz ; } // end of [lexbuf_size_get] /* ****** ****** */ #define BUF_SIZE 1024 #define BUF_RESIZE 256 /* ****** ****** */ ats_void_type lexbuf_resize (lexbuf *lxbf) { int fstpos, curpos, lstpos, endpos ; int buf_size, buf_size_new ; unsigned char *buf_ptr, *buf_ptr_new; /* fprintf (stdout, "lexbuf_resize: before: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize: before: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize: before: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize: before: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize: before: endpos = %i\n", lxbf->endpos) ; */ buf_ptr = lxbf->buf_ptr ; buf_size = lxbf->buf_size ; fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; buf_size_new = buf_size + buf_size ; buf_ptr_new = ATS_MALLOC (buf_size_new) ; lxbf->buf_ptr = buf_ptr_new ; lxbf->buf_size = buf_size_new ; lxbf->fstpos = 0 ; if (fstpos <= endpos) { memcpy(buf_ptr_new, buf_ptr+fstpos, endpos-fstpos) ; lxbf->endpos = endpos - fstpos ; } else { memcpy(buf_ptr_new, buf_ptr+fstpos, buf_size-fstpos) ; memcpy(buf_ptr_new+buf_size-fstpos, buf_ptr, endpos) ; lxbf->endpos = buf_size + endpos - fstpos ; } curpos = lxbf->curpos ; if (fstpos <= curpos) { lxbf->curpos = curpos - fstpos ; } else { lxbf->curpos = buf_size + curpos - fstpos ; } lstpos = lxbf->lstpos ; if (fstpos <= lstpos) { lxbf->lstpos = lstpos - fstpos ; } else { lxbf->lstpos = buf_size + lstpos - fstpos ; } /* fprintf (stdout, "lexbuf_resize: after: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize: after: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize: after: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize: after: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize: after: endpos = %i\n", lxbf->endpos) ; */ ATS_FREE (buf_ptr) ; } // end of [lexbuf_resize] ats_void_type lexbuf_resize_if (lexbuf *lxbf) { // int fstpos, endpos ; // /* fprintf (stdout, "lexbuf_resize_if: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize_if: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize_if: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize_if: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize_if: endpos = %i\n", lxbf->endpos) ; */ // fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; // if (fstpos <= endpos) { if (endpos - fstpos + BUF_RESIZE > lxbf->buf_size) { lexbuf_resize(lxbf) ; } } else { if (endpos + BUF_RESIZE >= fstpos) { lexbuf_resize (lxbf) ; } } // end of [if] // return ; } // end of [lexbuf_resize_if] ats_void_type lexbuf_refill ( ats_ptr_type lxbf0 ) { lexbuf *lxbf ; unsigned char *buf_ptr ; int c, fstpos, curpos, endpos ; lxbf = (lexbuf*)lxbf0 ; lexbuf_resize_if (lxbf) ; buf_ptr = lxbf->buf_ptr ; fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; /* fprintf (stdout, "lexbuf_refill: fstpos = %i\n", fstpos) ; fprintf (stdout, "lexbuf_refill: endpos = %i\n", endpos) ; */ if (fstpos <= endpos) { // while (endpos+1 < lxbf->buf_size) { c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; ++endpos ; } // end of [while] // if (fstpos == 0) { lxbf->endpos = endpos ; return ; } // c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; endpos = 0; // } /* end of [if] */ // while (endpos+1 < fstpos) { c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; ++endpos ; } /* end of [while] */ // lxbf->endpos = endpos ; // return ; // } /* end of [lexbuf_refill] */ /* ****** ****** */ ats_void_type lexbuf_curpos_next ( lexbuf *lxbf, int c ) { // int curpos1 = lxbf->curpos + 1 ; // if (curpos1 < lxbf->buf_size) { lxbf->curpos = curpos1; } else { lxbf->curpos = 0; } /* end of [if] */ // if (c == '\n') { lxbf->curpos_line += 1; lxbf->curpos_loff = 0; lxbf->curpos_toff += 1 ; } else { lxbf->curpos_loff += 1 ; lxbf->curpos_toff += 1 ; } /* end of [if] */ // return ; } /* end of [lexbuf_curpos_next] */ /* ****** ****** */ ats_int_type lexbuf_char_next ( ats_ptr_type lxbf0 ) { lexbuf *lxbf ; unsigned char *buf_ptr ; int c, fstpos, curpos, endpos ; // lxbf = (lexbuf*)lxbf0 ; // buf_ptr = lxbf->buf_ptr ; curpos = lxbf->curpos ; endpos = lxbf->endpos ; // if (curpos != endpos) { c = buf_ptr[curpos] ; lexbuf_curpos_next (lxbf, c); return c ; } // end of [if] // lexbuf_refill (lxbf0) ; // buf_ptr = lxbf->buf_ptr ; curpos = lxbf->curpos ; endpos = lxbf->endpos ; /* fprintf (stdout, "lexbuf_char_next: refill: curpos = %i\n", curpos); fprintf (stdout, "lexbuf_char_next: refill: endpos = %i\n", endpos); */ if (curpos != endpos) { c = buf_ptr[curpos] ; lexbuf_curpos_next (lxbf, c); return c ; } // end of [if] // return -1 ; /* [-1] represents a special character */ // } /* end of [lexbuf_char_next] */ /* ****** ****** */ ats_bool_type lexbuf_is_eof ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; if (lxbf->curpos != lxbf->endpos) return ats_false_bool ; lexbuf_refill (lxbf0) ; if (lxbf->curpos != lxbf->endpos) { return ats_false_bool ; } else { return ats_true_bool ; } /* end of [if] */ } /* end of [lexbuf_is_eof] */ /* ****** ****** */ ats_ptr_type lexing_fstpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf*)(lexing_lexbuf_get()) ; pos = lexbuf_fstpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } // end of [lexing_fstpos_get] ats_ptr_type lexing_lstpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf*)(lexing_lexbuf_get()) ; pos = lexbuf_lstpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } // end of [lexing_lstpos_get] ats_ptr_type lexing_curpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf*)(lexing_lexbuf_get()) ; pos = lexbuf_curpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } // end of [lexing_curpos_get] /* ****** ****** */ ats_void_type lexbuf_curpos_fprint ( ats_ptr_type fil, ats_ref_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; fprintf ((FILE*)fil, "%li(line=%i, offset=%i)", lxbf->curpos_toff+1L, lxbf->curpos_line+1, lxbf->curpos_loff+1 ) ; return ; } // end of [lexbuf_curpos_fprint] /* ****** ****** */ ats_ptr_type lexbuf_make_infile ( atslex_infile_t infile ) { lexbuf *lxbf ; unsigned char *buf_ptr ; buf_ptr = ATS_MALLOC (BUF_SIZE) ; lxbf = ATS_MALLOC (sizeof(lexbuf)) ; lxbf->buf_ptr = buf_ptr ; lxbf->buf_size = BUF_SIZE ; lxbf->infile = infile ; lxbf->fstpos = 0 ; lxbf->fstpos_line = 0 ; lxbf->fstpos_loff = 0 ; lxbf->fstpos_toff = 0 ; lxbf->lstpos = 0 ; lxbf->lstpos_line = 0 ; lxbf->lstpos_loff = 0 ; lxbf->lstpos_toff = 0 ; lxbf->curpos = 0 ; lxbf->curpos_line = 0 ; lxbf->curpos_loff = 0 ; lxbf->curpos_toff = 0 ; lxbf->endpos = 0 ; /* printf ("lexbuf_make_infile: lxbf = %p\n", lxbf) ; */ return lxbf ; } // end of [lexbuf_make_infile] ats_void_type lexbuf_free (ats_ptr_type lxbf0) { lexbuf *lxbf ; // lxbf = (lexbuf*)lxbf0 ; lexing_infile_free (lxbf->infile) ; ATS_FREE (lxbf->buf_ptr) ; // return ; } // end of [lexbuf_free] /* ****** ****** */ ats_char_type lexeme_get_lexbuf ( ats_ptr_type lxbf0, ats_int_type i ) { int len, fstpos, lstpos, bufsz ; lexbuf *lxbf ; // if (i < 0) { ats_exit_errmsg ( 1, "lexeme_get_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ // lxbf = (lexbuf*)lxbf0 ; // fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; bufsz = lxbf->buf_size ; if (len < 0) { len += bufsz ; } // if (i > len) { ats_exit_errmsg ( 1, "lexeme_get_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ // i = fstpos + i ; if (i >= bufsz) { i -= bufsz ; } // return *((lxbf->buf_ptr) + i) ; } // end of [lexeme_get_lexbuf] ats_void_type lexeme_set_lexbuf ( ats_ptr_type lxbf0 , ats_int_type i, ats_char_type c ) { int len, fstpos, lstpos, bufsz ; lexbuf *lxbf ; // if (i < 0) { ats_exit_errmsg ( 1, "lexeme_set_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ // lxbf = (lexbuf*)lxbf0 ; // fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; bufsz = lxbf->buf_size ; if (len < 0) { len += bufsz ; } // if (i > len) { ats_exit_errmsg ( 1, "lexeme_set_lexbuf: index is out_of_bounds.\n" ) ; } // end of [if] // i = fstpos + i ; if (i >= bufsz) { i -= bufsz ; } // *((lxbf->buf_ptr) + i) = c ; // return ; } // end of [lexeme_set_lexbuf] /* ****** ****** */ ats_ptr_type lexeme_strptr_lexbuf (ats_ptr_type lxbf0) { int len, fstpos, lstpos ; char *src, *dst0, *dst ; lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0 ; fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; if (len < 0) { len += lxbf->buf_size ; } src = (lxbf->buf_ptr) + fstpos ; dst0 = ATS_MALLOC ((len + 1) * sizeof(char)) ; dst = dst0 ; if (lstpos < fstpos) { while (fstpos < lxbf->buf_size) { *dst = *src ; ++fstpos ; ++src ; ++dst ; } fstpos = 0 ; src = lxbf->buf_ptr ; } while (fstpos < lstpos) { *dst = *src ; ++fstpos ; ++src ; ++dst ; } *dst = '\000' ; return dst0 ; } // end of [lexeme_strptr_lexbuf] /* ****** ****** */ static ats_ptr_type the_lexbuf = (lexbuf*)0 ; ats_void_type lexing_lexbuf_markroot () { ATS_GC_MARKROOT (&the_lexbuf, sizeof(ats_ptr_type)) ; return ; } // end of [lexing_lexbuf_markroot] static ats_int_type the_lexbuf_flag = 0 ; ats_ptr_type lexing_lexbuf_get () { if (the_lexbuf_flag == 0) { ats_exit_errmsg ( 1, "[lexeme_get] failed: The default lexbuf is not set!\n" ); } // end of [if] the_lexbuf_flag = 0 ; return the_lexbuf ; } // end of [lexing_lexbuf_get] ats_void_type lexing_lexbuf_set (ats_ptr_type lxbf) { if (the_lexbuf_flag == 1) { ats_exit_errmsg ( 1, "[lexeme_set] failed: The default lexbuf is already set!\n" ); } the_lexbuf_flag = 1 ; the_lexbuf = lxbf ; /* printf ("lexing_lexbuf_set: lxbf = %p\n", lxbf) ; */ return ; } // end of [lexing_lexbuf_set] ats_void_type lexing_lexbuf_free () { lexbuf_free (lexing_lexbuf_get ()) ; return ; } // end of [lexing_lexbuf_free] %} // end of [%{$] (* ****** ****** *) (* end of [lexing.dats] *) ats-lang-anairiats-0.2.11/libats/lex/lexing.sats0000664000175000017500000001572312223166162020235 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS/Anairiats - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: July 2007 // (* ****** ****** *) %{# #ifndef ATS_LIBATS_LEX_LEXING_SATS #define ATS_LIBATS_LEX_LEXING_SATS typedef struct { ats_clo_ptr_type free ; ats_clo_ptr_type getc ; } atslex_infile_t ; // end of [typedef] #endif // end of [ATS_LIBATS_LEX_LEXING_SATS] %} // end of [%{#] (* ****** ****** *) abstype accept_table_t // boxed type fun accept_table_get (acctbl: accept_table_t, nstate: int): int (* irule *) fun __accept_table_make (nton: int) (nitm: int) (s: string): accept_table_t fun __accept_table_free (acctbl: accept_table_t): void // abstype transition_table_t // boxed type fun __transition_table_make (n: int) (s: string): transition_table_t fun __transition_table_free (transtbl: transition_table_t): void fun transition_table_get // c >= -1 (transtbl: transition_table_t, nstate: int, c: int): int (* nstate *) (* ****** ****** *) abstype position_t // boxed type typedef lint = int_long_t0ype fun position_line (p: position_t):<> int fun position_loff (p: position_t):<> int fun position_toff (p: position_t):<> lint (* ****** ****** *) fun lt_position_position (p1: position_t, p2: position_t):<> bool overload < with lt_position_position fun lte_position_position (p1: position_t, p2: position_t):<> bool overload <= with lte_position_position fun eq_position_position (p1: position_t, p2: position_t):<> bool overload = with eq_position_position fun neq_position_position (p1: position_t, p2: position_t):<> bool overload <> with neq_position_position (* ****** ****** *) fun fprint_position {m:file_mode} (pf: file_mode_lte (m, w) | fil: &FILE m, pos: position_t): void overload fprint with fprint_position fun print_position (pos: position_t): void = "lexing_print_position" fun prerr_position (pos: position_t): void = "lexing_prerr_position" overload print with print_position overload prerr with prerr_position (* ****** ****** *) // // HX: flat type for the input file // absviewt@ype infile_t (v:view) = $extype "atslex_infile_t" // end of [infile_t] fun infile_free {v:view} (pf: v | f: infile_t v): void = "lexing_infile_free" fun infile_getc {v:view} (pf: !v | f: !infile_t v): int = "lexing_infile_getc" fun infile_make_string (inp: string): [v:view] (v | infile_t v) (* ** HX-2011-12-16: [inp] is freed when [infile] is freed *) fun infile_make_strptr (inp: strptr1): [v:view] (v | infile_t v) fun infile_make_file {m:file_mode} {l:addr} ( pf_fil: FILE m @ l, pf_mod: file_mode_lte (m, r) | fil: ptr l ) : [v:view] (v | infile_t v) // end of [infile_make_file] fun infile_make_stdin (): [v:view] (v | infile_t v) (* ****** ****** *) absviewt@ype lexbuf_t (* implemented externally in lexing.dats*) (* ****** ****** *) (* ** HX: this one is implemented in C *) fun lexbuf_curpos_fprint (out: FILEref, lb: &lexbuf_t): void = "lexbuf_curpos_fprint" // end of [lexbuf_curpos_fprint] fun lexbuf_curpos_prerr (lb: &lexbuf_t): void (* ****** ****** *) // implemented externally in [libats/lex/lexing.dats] fun lexbuf_fstpos_get (lb: &lexbuf_t): position_t = "lexbuf_fstpos_get" fun lexbuf_fstpos_set (lb: &lexbuf_t): void = "lexbuf_fstpos_set" fun lexbuf_lstpos_get (lb: &lexbuf_t): position_t = "lexbuf_lstpos_get" fun lexbuf_lstpos_set (lb: &lexbuf_t): void = "lexbuf_lstpos_set" fun lexbuf_curpos_get (lb: &lexbuf_t): position_t = "lexbuf_curpos_get" fun lexbuf_curpos_set (lb: &lexbuf_t): void = "lexbuf_curpos_set" fun lexbuf_size_get (lb: &lexbuf_t): Nat = "lexbuf_size_get" fun lexbuf_char_next (lb: &lexbuf_t): int = "lexbuf_char_next" fun lexbuf_is_eof (lb: &lexbuf_t): bool = "lexbuf_is_eof" fun lexing_engine_lexbuf ( lb: &lexbuf_t, transtbl: transition_table_t, acctbl: accept_table_t ) : int (*nstate*) = "lexing_engine_lexbuf" // end of [fun] (* ****** ****** *) // // This function makes a lexbuf from an infile. // fun lexbuf_make_infile {v:view} ( pf: v | f: infile_t v ) : [l:addr] (lexbuf_t @ l | ptr l) = "lexbuf_make_infile" // end of [fun] (* ****** ****** *) // // This function frees a lexbuf. // fun lexbuf_free {l:addr} (pf: lexbuf_t @ l | p: ptr l): void = "lexbuf_free" // end of [lexbuf_free] (* ****** ****** *) // This function gets the default lexbuf. fun lexing_lexbuf_get (): [l:addr] (lexbuf_t @ l | ptr l) = "lexing_lexbuf_get" // This function sets the default lexbuf. fun lexing_lexbuf_set {l:addr} (pf: lexbuf_t @ l | p: ptr l): void = "lexing_lexbuf_set" // This function frees the default lexbuf. fun lexing_lexbuf_free (): void = "lexing_lexbuf_free" fun lexing_engine (transtbl: transition_table_t, acctbl: accept_table_t): int = "lexing_engine" (* ****** ****** *) fun lexeme_get_lexbuf (lb: &lexbuf_t, index: int): char = "lexeme_get_lexbuf" fun lexeme_get (index: int): char = "lexeme_get" fun lexeme_set_lexbuf (lb: &lexbuf_t, index: int, c: char): void = "lexeme_set_lexbuf" fun lexeme_set (index: int, c: char): void = "lexeme_set" // fun lexeme_strptr_lexbuf (lb: &lexbuf_t): strptr1 = "lexeme_strptr_lexbuf" fun lexeme_strptr (): strptr1 fun lexeme_string (): string = "lexeme_string" // (* ****** ****** *) // // This function is for testing whether the lexbuf reaches the end. // fun lexing_is_eof (): bool = "lexing_is_eof" // (* ****** ****** *) fun lexing_fstpos_get (): position_t = "lexing_fstpos_get" fun lexing_lstpos_get (): position_t = "lexing_lstpos_get" fun lexing_curpos_get (): position_t = "lexing_curpos_get" (* ****** ****** *) exception LexingErrorException // This function reports a lexing error; it raises the exception // [LexingErrorException] fun lexing_error {a:viewt@ype} (): a (* ****** ****** *) (* end of [lexing.sats] *) ats-lang-anairiats-0.2.11/libats/DATS/0000700000175000017500000000000012223166162015772 5ustar hwxihwxiats-lang-anairiats-0.2.11/libats/DATS/bimatrix.dats0000664000175000017500000000345212223166162020506 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Bidirectional row-major matrices ** (matrices moving from left to right and vice versa) ** Contributed by Artyom Shalkhakov (artyom.shalkhakov AT gmail DOT com) ** Time: November, 2011 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/bimatrix.sats" (* ****** ****** *) // // It is yet empty // (* ****** ****** *) (* end of [bimatrix.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/biarray.dats0000664000175000017500000000474412223166162020325 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Bidirectional Arrays (arrays moving from left to right and vice versa) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/biarray.sats" (* ****** ****** *) assume biarray_v ( a:viewt@ype, n:int, lbeg:addr, lend:addr ) = [ofs:int | lend==lbeg+ofs] ( MUL (n, sizeof(a), ofs), array_v (a, n, lbeg) ) // end of [biarray_v] (* ****** ****** *) implement array_v_of_biarray_v (pf) = let prval (pfmul, pfarr) = pf in pfarr end // end of [array_v_of_biarray_v] (* ****** ****** *) implement biarray_v_of_array_v (pfmul, pfarr) = (pfmul, pfarr) (* ****** ****** *) implement biarray_v_offset {a} (pf) = pfmul where { prval (pfmul, pfarr) = pf prval () = pf := biarray_v_of_array_v {a} (pfmul, pfarr) } // end of [biarray_v_offset] (* ****** ****** *) implement biarray_v_unnil (pf) = let val (pfmul, pfarr) = pf; val () = array_v_unnil (pfarr) in mul_elim (pfmul) end // end of [biarray_v_unnil] (* ****** ****** *) (* end of [biarray.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/fundeque_fingertree.dats0000664000175000017500000010442212223166162022714 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional concatenable deque implementation based on fingertrees ** Please see the JFP paper by Hinze and Paterson on fingertrees for more ** details on this interesting data structure ** ** Contributed by ** Robbie Harwood (rharwood AT cs DOT bu DOT edu) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** ** Time: November, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libats/SATS/fundeque_fingertree.sats" (* ****** ****** *) datatype ftnode (a:t@ype+, int(*d*), int(*n*)) = | FTN1 (a, 0, 1) of (a) // singleton | {d:nat} {n1,n2:nat} FTN2 (a, d+1, n1+n2) of (ftnode (a, d, n1), ftnode (a, d, n2)) | {d:nat} {n1,n2,n3:nat} FTN3 (a, d+1, n1+n2+n3) of ( ftnode (a, d, n1), ftnode (a, d, n2), ftnode (a, d, n3) ) // end of [N3] // end of [ftnode] typedef ft0node = ftnode (void, 0, 0) (* ****** ****** *) datatype ftdigit (a:t@ype+, int(*d*), int(*n*)) = | {d:nat} {n:nat} FTD1 (a, d, n) of ftnode (a, d, n) | {d:nat} {n1,n2:nat} FTD2 (a, d, n1+n2) of (ftnode (a, d, n1), ftnode (a, d, n2)) | {d:nat} {n1,n2,n3:nat} FTD3 (a, d, n1+n2+n3) of (ftnode (a, d, n1), ftnode (a, d, n2), ftnode (a, d, n3)) | {d:nat} {n1,n2,n3,n4:nat} FTD4 (a, d, n1+n2+n3+n4) of ( ftnode (a, d, n1), ftnode (a, d, n2), ftnode (a, d, n3), ftnode (a, d, n4) ) // end of [FTD4] // end of [ftdigit] (* ****** ****** *) datatype fingertree ( a:t@ype, int(*d*), int(*n*) ) = | {d:nat} FTemp (a, d, 0) of () // FTemp: () -> fingertree (a) | {d:nat} {n:int} FTsing (a, d, n) of ftnode (a, d, n) // FTsing: ftnode (a) -> fingertree (a) | {d:nat} {npr,nm,nsf:nat} FTdeep (a, d, npr+nm+nsf) of ( ftdigit(a, d, npr), fingertree (a, d+1, nm), ftdigit (a, d, nsf) ) // end of [FTdeep] // end of [fingertree] (* ****** ****** *) prfun ftnode_prop_szpos {a:t@ype} {d:int} {n:int} .. (xn: ftnode (a, d, n)): [n > 0] void = case+ xn of | FTN1 _ => () | FTN2 (xn1, xn2) => { val () = ftnode_prop_szpos (xn1) } // end of [FTN2] | FTN3 (xn1, xn2, xn3) => { val () = ftnode_prop_szpos (xn1) } // end of [FTN3] // end of [ftnode_prop_szpos] (* ****** ****** *) prfun ftdigit_prop_szpos {a:t@ype} {d:int} {n:int} .<>. (xd: ftdigit (a, d, n)): [n > 0] void = case+ xd of | FTD1 (xn1) => ftnode_prop_szpos (xn1) | FTD2 (xn1, _) => ftnode_prop_szpos (xn1) | FTD3 (xn1, _, _) => ftnode_prop_szpos (xn1) | FTD4 (xn1, _, _, _) => ftnode_prop_szpos (xn1) // end of [ftdigit_prop_szpos] (* ****** ****** *) prfun fingertree_prop1_sznat {a:t@ype} {d:int} {n:int} .<>. (xt: fingertree (a, d, n)): [n >= 0] void = case+ xt of | FTemp () => () | FTsing (xn) => ftnode_prop_szpos (xn) | FTdeep (pr, m, sf) => { val () = ftdigit_prop_szpos (pr) and () = ftdigit_prop_szpos (sf) } // end of [FTdeep] // end of [fingertree_prop1_sznat] (* ****** ****** *) fun ftnode_size {a:t@ype} {d:int} {n:nat} .. ( xn: ftnode (a, d, n) ) :<> int n = let macdef nsz (xn) = ftnode_size ,(xn) in case+ xn of | FTN1 _ => 1 | FTN2 (xn1, xn2) => let prval () = ftnode_prop_szpos (xn1) prval () = ftnode_prop_szpos (xn2) in nsz (xn1) + nsz (xn2) end // end of [FTN2] | FTN3 (xn1, xn2, xn3) => let prval () = ftnode_prop_szpos (xn1) prval () = ftnode_prop_szpos (xn2) prval () = ftnode_prop_szpos (xn3) in nsz (xn1) + nsz (xn2) + nsz (xn3) end // endof [FTN3] end // end of [ftnode_size] (* ****** ****** *) fun ftdigit_size {a:t@ype} {d:int} {n:int} .<>. ( xd: ftdigit (a, d, n) ) :<> int n = let macdef nsz (x) = ftnode_size ,(x) in case+ xd of | FTD1 (xn1) => nsz (xn1) | FTD2 (xn1, xn2) => nsz (xn1) + nsz (xn2) | FTD3 (xn1, xn2, xn3) => nsz (xn1) + nsz (xn2) + nsz (xn3) | FTD4 (xn1, xn2, xn3, xn4) => nsz (xn1) + nsz (xn2) + nsz (xn3) + nsz (xn4) end // end of [ftdigit_size] (* ****** ****** *) fun ftnode2ftdigit {a:t@ype} {d:pos} {n:int} .<>. (xn: ftnode (a, d, n)):<> ftdigit (a, d-1, n) = case+ xn of | FTN2 (xn1, xn2) => FTD2 (xn1, xn2) | FTN3 (xn1, xn2, xn3) => FTD3 (xn1, xn2, xn3) // end of [ftnode2ftdigit] (* ****** ****** *) fun ftdigit2fingertree {a:t@ype} {d:nat} {n:int} .<>. (xd: ftdigit (a, d, n)):<> fingertree (a, d, n) = case+ xd of | FTD1 (xn1) => FTsing (xn1) | FTD2 (xn1, xn2) => FTdeep (FTD1 (xn1), FTemp(), FTD1 (xn2)) | FTD3 (xn1, xn2, xn3) => FTdeep (FTD2 (xn1, xn2), FTemp(), FTD1 (xn3)) | FTD4 (xn1, xn2, xn3, xn4) => FTdeep (FTD2 (xn1, xn2), FTemp(), FTD2 (xn3, xn4)) // end of [ftdigit2fingertree] (* ****** ****** *) extern fun fingertree_cons {a:t@ype} {d:nat} {n1,n2:int} ( xn: ftnode (a, d, n1), xt: fingertree (a, d, n2) ) :<> fingertree (a, d, n1+n2) // end of [fingertree_cons] implement fingertree_cons{a} (xn, xt) = cons (xn, xt) where { // fun cons {d:nat} {n1,n2:int | n2 >= 0} .. ( xn: ftnode (a, d, n1), xt: fingertree (a, d, n2) ) :<> fingertree (a, d, n1+n2) = let prval () = ftnode_prop_szpos (xn) in case+ xt of | FTemp () => FTsing (xn) | FTsing (xn1) => let prval () = ftnode_prop_szpos (xn1) in FTdeep (FTD1(xn), FTemp(), FTD1(xn1)) end // end [FTsing] | FTdeep (pr, m, sf) => (case+ pr of | FTD1 (xn1) => FTdeep (FTD2 (xn, xn1), m, sf) | FTD2 (xn1, xn2) => FTdeep (FTD3 (xn, xn1, xn2), m, sf) | FTD3 (xn1, xn2, xn3) => FTdeep (FTD4 (xn, xn1, xn2, xn3), m, sf) | FTD4 (xn1, xn2, xn3, xn4) => let val pr = FTD2 (xn, xn1) // prval () = ftdigit_prop_szpos (sf) prval () = fingertree_prop1_sznat (m) // val m = cons (FTN3 (xn2, xn3, xn4), m) in FTdeep (pr, m, sf) end // end of [FTD4] ) // end of [FTdeep] end // end of [cons] // prval () = fingertree_prop1_sznat (xt) // } // end of [fingertree_cons] (* ****** ****** *) extern fun fingertree_uncons {a:t@ype} {d:nat} {n:pos} ( xt: fingertree (a, d, n), r: &ftnode? >> ftnode (a, d, n1) ) :<> #[n1:nat] fingertree (a, d, n-n1) // end of [fingertree_uncons] implement fingertree_uncons{a} (xt, r) = uncons (xt, r) where { // fun uncons {d:nat} {n:pos} .. ( xt: fingertree (a, d, n), r: &ft0node? >> ftnode (a, d, n1) ) :<> #[n1:nat | n1 <= n] fingertree (a, d, n-n1) = case+ xt of | FTsing (xn) => let val () = r := xn in FTemp () end // end of [Single] | FTdeep (pr, m, sf) => (case+ pr of | FTD1 (xn) => let val () = r := xn prval () = ftdigit_prop_szpos (pr) prval () = ftdigit_prop_szpos (sf) in case+ m of | FTemp () => ftdigit2fingertree (sf) | FTsing (xn1) => FTdeep (ftnode2ftdigit (xn1), FTemp (), sf) | FTdeep (pr1, m1, sf1) => let var r1: ft0node? prval () = ftdigit_prop_szpos (pr1) prval () = fingertree_prop1_sznat (m1) prval () = ftdigit_prop_szpos (sf1) val m = uncons (m, r1) in FTdeep (ftnode2ftdigit (r1), m, sf) end // end of [_] end // end of [FTD1] | FTD2 (xn, xn1) => let val () = r := xn in FTdeep (FTD1 (xn1), m, sf) end // end of [FTD2] | FTD3 (xn, xn1, xn2) => let val () = r := xn in FTdeep (FTD2 (xn1, xn2), m, sf) end // end of [FTD3] | FTD4 (xn, xn1, xn2, xn3) => let val () = r := xn in FTdeep (FTD3 (xn1, xn2, xn3), m, sf) end // end of [FTD4] ) // end of [FTdeep] // end of [uncons] } // end of [fingertree_uncons] (* ****** ****** *) extern fun fingertree_snoc {a:t@ype} {d:nat} {n1,n2:int} ( xt: fingertree (a, d, n2), xn: ftnode (a, d, n1) ) :<> fingertree (a, d, n1+n2) // end of [fingertree_snoc] implement fingertree_snoc{a} (xt, xn) = snoc (xt, xn) where { // fun snoc {d:nat} {n1,n2:int | n2 >= 0} .. ( xt: fingertree (a, d, n2), xn: ftnode (a, d, n1) ) :<> fingertree (a, d, n1+n2) = let prval () = ftnode_prop_szpos (xn) in case+ xt of | FTemp () => FTsing (xn) | FTsing (xn1) => let prval () = ftnode_prop_szpos (xn1) in FTdeep (FTD1(xn1), FTemp(), FTD1(xn)) end // end [FTsing] | FTdeep (pr, m, sf) => (case+ sf of | FTD1 (xn1) => FTdeep (pr, m, FTD2 (xn1, xn)) | FTD2 (xn1, xn2) => FTdeep (pr, m, FTD3 (xn1, xn2, xn)) | FTD3 (xn1, xn2, xn3) => FTdeep (pr, m, FTD4 (xn1, xn2, xn3, xn)) | FTD4 (xn1, xn2, xn3, xn4) => let val sf = FTD2 (xn4, xn) // prval () = ftdigit_prop_szpos (pr) prval () = fingertree_prop1_sznat (m) // val m = snoc (m, FTN3 (xn1, xn2, xn3)) in FTdeep (pr, m, sf) end // end of [FTD4] ) // end of [FTdeep] end // end of [snoc] // prval () = fingertree_prop1_sznat (xt) // } // end of [fingertree_snoc] (* ****** ****** *) assume deque_t0ype_int_type (a:t@ype, n:int) = fingertree (a, 0, n) // end of [deque_t0ype_int_type] (* ****** ****** *) implement fundeque_size {a} (xt) = let fun size {d:int} {n:nat} .. (xt: fingertree (a, d, n)):<> int (n) = case+ xt of | FTemp () => 0 | FTsing (xn) => ftnode_size (xn) | FTdeep (pr, m, sf) => let prval () = ftdigit_prop_szpos (pr) in ftdigit_size (pr) + size (m) + ftdigit_size (sf) end // end of [FTdeep] // end of [size] in size (xt) end // end of [fundeque_size] (* ****** ****** *) implement{} fundeque_nil () = FTemp () implement{} fundeque_is_nil (xt) = case+ xt of | FTemp () => true | FTsing (xn) => let prval () = ftnode_prop_szpos (xn) in false end // end of [FTsing] | FTdeep (pr, _, _) => let prval () = ftdigit_prop_szpos (pr) in false end // end of [FTdeep] // end of [fundeque_is_nil] (* ****** ****** *) extern fun fingertree_unsnoc {a:t@ype} {d:nat} {n:pos} ( xt: fingertree (a, d, n), r: &ftnode? >> ftnode (a, d, n1) ) :<> #[n1:nat] fingertree (a, d, n-n1) // end of [fingertree_unsnoc] implement fingertree_unsnoc{a} (xt, r) = unsnoc (xt, r) where { // fun unsnoc {d:nat} {n:pos} .. ( xt: fingertree (a, d, n), r: &ft0node? >> ftnode (a, d, n1) ) :<> #[n1:nat | n1 <= n] fingertree (a, d, n-n1) = case+ xt of | FTsing (xn) => let val () = r := xn in FTemp () end // end of [Single] | FTdeep (pr, m, sf) => (case+ sf of | FTD1 (xn) => let val () = r := xn prval () = ftdigit_prop_szpos (pr) prval () = ftdigit_prop_szpos (sf) in case+ m of | FTemp () => ftdigit2fingertree (pr) | FTsing (xn1) => FTdeep (pr, FTemp (), ftnode2ftdigit (xn1)) | FTdeep (pr1, m1, sf1) => let var r1: ft0node? prval () = ftdigit_prop_szpos (pr1) prval () = fingertree_prop1_sznat (m1) prval () = ftdigit_prop_szpos (sf1) val m = unsnoc (m, r1) in FTdeep (pr, m, ftnode2ftdigit (r1)) end // end of [_] end // end of [FTD1] | FTD2 (xn1, xn) => let val () = r := xn in FTdeep (pr, m, FTD1 (xn1)) end // end of [FTD2] | FTD3 (xn1, xn2, xn) => let val () = r := xn in FTdeep (pr, m, FTD2 (xn1, xn2)) end // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn) => let val () = r := xn in FTdeep (pr, m, FTD3 (xn1, xn2, xn3)) end // end of [FTD4] ) // end of [FTdeep] // end of [unsnoc] } // end of [fingertree_unsnoc] (* ****** ****** *) implement{a} fundeque_cons (xn, xt) = fingertree_cons (FTN1 (xn), xt) // end of [fundeque_cons] implement{a} fundeque_uncons (xt, r) = xt where { var xn: ft0node? val xt = fingertree_uncons (xt, xn) val+ FTN1 (x) = xn val () = (r := x) } // end of [fundeque_uncons] (* ****** ****** *) implement{a} fundeque_snoc (xt, xn) = fingertree_snoc (xt, FTN1 (xn)) // end of [fundeque_snoc] implement{a} fundeque_unsnoc (xt, r) = xt where { var xn: ft0node? val xt = fingertree_unsnoc (xt, xn) val+ FTN1 (x) = xn val () = (r := x) } // end of [fundeque_unsnoc] (* ****** ****** *) local symintr ++ infix (+) ++ overload ++ with fingertree_cons overload ++ with fingertree_snoc fun ftapp0 {a:t@ype} {d:int} {n1,n2:nat} ( xt1: fingertree (a, d, n1) , xt2: fingertree (a, d, n2) ) : fingertree (a, d, n1+n2) = case+ (xt1, xt2) of | (FTemp (), _) => xt2 | (_, FTemp ()) => xt1 | (FTsing xn1, _) => xn1 ++ xt2 | (_, FTsing xn2) => xt1 ++ xn2 | (FTdeep (pr1, m1, sf1), FTdeep (pr2, m2, sf2)) => FTdeep (pr1, ftadd0 (m1, sf1, pr2, m2), sf2) // end of [ftapp0] and ftadd0 {a:t@ype} {d:int} {nm1,nm2:nat} {nsf1,npr2:nat} ( m1: fingertree (a, d+1, nm1) , sf1: ftdigit (a, d, nsf1) , pr2: ftdigit (a, d, npr2) , m2: fingertree (a, d+1, nm2) ) : fingertree (a, d+1, nm1+nsf1+npr2+nm2) = case+ sf1 of | FTD1 (xn1) => (case+ pr2 of | FTD1 (xn_1) => ftapp1 (m1, FTN2 (xn1, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp1 (m1, FTN3 (xn1, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN2 (xn1, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp2 (m1, FTN3 (xn1, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD1] | FTD2 (xn1, xn2) => (case+ pr2 of | FTD1 (xn_1) => ftapp1 (m1, FTN3 (xn1, xn2, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN2 (xn1, xn2), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN3 (xn1, xn2, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp2 (m1, FTN3 (xn1, xn2, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD2] | FTD3 (xn1, xn2, xn3) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN2 (xn1, xn2), FTN2 (xn3, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn4) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn4, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn4, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD4] // end of [ftadd0] and ftapp1 {a:t@ype} {d:int} {n1,n2:nat} {na:nat} ( xt1: fingertree (a, d, n1) , xna: ftnode (a, d, na) , xt2: fingertree (a, d, n2) ) : fingertree (a, d, n1+na+n2) = case+ (xt1, xt2) of | (FTemp (), _) => xna ++ xt2 | (_, FTemp ()) => xt1 ++ xna | (FTsing xn1, _) => xn1 ++ (xna ++ xt2) | (_, FTsing xn2) => (xt1 ++ xna) ++ xn2 | (FTdeep (pr1, m1, sf1), FTdeep (pr2, m2, sf2)) => FTdeep (pr1, ftadd1 (m1, sf1, xna, pr2, m2), sf2) // end of [ftapp1] and ftadd1 {a:t@ype} {d:int} {nm1,nm2:nat} {nsf1,npr2:nat} {na:nat} ( m1: fingertree (a, d+1, nm1) , sf1: ftdigit (a, d, nsf1) , xna: ftnode (a, d, na) , pr2: ftdigit (a, d, npr2) , m2: fingertree (a, d+1, nm2) ) : fingertree (a, d+1, nm1+nsf1+na+npr2+nm2) = case+ sf1 of | FTD1 (xn1) => (case+ pr2 of | FTD1 (xn_1) => ftapp1 (m1, FTN3 (xn1, xna, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN2 (xn1, xna), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN3 (xn1, xna, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp2 (m1, FTN3 (xn1, xna, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD1] | FTD2 (xn1, xn2) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN2 (xn1, xn2), FTN2 (xna, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xn2, xna), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN3 (xn1, xn2, xna), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD2] | FTD3 (xn1, xn2, xn3) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xna, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xna, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn4) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn4, xna), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD4] // end of [ftadd1] and ftapp2 {a:t@ype} {d:int} {n1,n2:nat} {na,nb:nat} ( xt1: fingertree (a, d, n1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , xt2: fingertree (a, d, n2) ) : fingertree (a, d, n1+na+nb+n2) = case+ (xt1, xt2) of | (FTemp (), _) => xna ++ (xnb ++ xt2) | (_, FTemp ()) => (xt1 ++ xna) ++ xnb | (FTsing xn1, _) => xn1 ++ (xna ++ (xnb ++ xt2)) | (_, FTsing xn2) => ((xt1 ++ xna) ++ xnb) ++ xn2 | (FTdeep (pr1, m1, sf1), FTdeep (pr2, m2, sf2)) => FTdeep (pr1, ftadd2 (m1, sf1, xna, xnb, pr2, m2), sf2) // end of [ftapp2] and ftadd2 {a:t@ype} {d:int} {nm1,nm2:nat} {nsf1,npr2:nat} {na,nb:nat} ( m1: fingertree (a, d+1, nm1) , sf1: ftdigit (a, d, nsf1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , pr2: ftdigit (a, d, npr2) , m2: fingertree (a, d+1, nm2) ) : fingertree (a, d+1, nm1+nsf1+na+nb+npr2+nm2) = case+ sf1 of | FTD1 (xn1) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN2 (xn1, xna), FTN2 (xnb, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xna, xnb), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp2 (m1, FTN3 (xn1, xna, xnb), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD1] | FTD2 (xn1, xn2) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xna), FTN2 (xnb, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN2 (xnb, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD2] | FTD3 (xn1, xn2, xn3) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xna, xnb), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn4) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xn4, xna), FTN2 (xnb, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD4] // end of [ftadd2] and ftapp3 {a:t@ype} {d:int} {n1,n2:nat} {na,nb,nc:nat} ( xt1: fingertree (a, d, n1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , xnc: ftnode (a, d, nc) , xt2: fingertree (a, d, n2) ) : fingertree (a, d, n1+na+nb+nc+n2) = case+ (xt1, xt2) of | (FTemp (), _) => xna ++ (xnb ++ (xnc ++ xt2)) | (_, FTemp ()) => ((xt1 ++ xna) ++ xnb) ++ xnc | (FTsing xn1, _) => xn1 ++ (xna ++ (xnb ++ (xnc ++ xt2))) | (_, FTsing xn2) => (((xt1 ++ xna) ++ xnb) ++ xnc) ++ xn2 | (FTdeep (pr1, m1, sf1), FTdeep (pr2, m2, sf2)) => FTdeep (pr1, ftadd3 (m1, sf1, xna, xnb, xnc, pr2, m2), sf2) // end of [ftapp3] and ftadd3 {a:t@ype} {d:int} {nm1,nm2:nat} {nsf1,npr2:nat} {na,nb,nc:nat} ( m1: fingertree (a, d+1, nm1) , sf1: ftdigit (a, d, nsf1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , xnc: ftnode (a, d, nc) , pr2: ftdigit (a, d, npr2) , m2: fingertree (a, d+1, nm2) ) : fingertree (a, d+1, nm1+nsf1+na+nb+nc+npr2+nm2) = case+ sf1 of | FTD1 (xn1) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xna, xnb), FTN2 (xnc, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp2 (m1, FTN3 (xn1, xna, xnb), FTN3 (xnc, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN2 (xnc, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN3 (xnc, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD1] | FTD2 (xn1, xn2) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN2 (xnb, xnc), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD2] | FTD3 (xn1, xn2, xn3) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN2 (xna, xnb), FTN2 (xnc, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn4) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN2 (xnc, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xnc, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN2 (xnc, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xnc, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD4] // end of [ftadd3] and ftapp4 {a:t@ype} {d:int} {n1,n2:nat} {na,nb,nc,nd:nat} ( xt1: fingertree (a, d, n1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , xnc: ftnode (a, d, nc) , xnd: ftnode (a, d, nd) , xt2: fingertree (a, d, n2) ) : fingertree (a, d, n1+na+nb+nc+nd+n2) = case+ (xt1, xt2) of | (FTemp (), _) => xna ++ (xnb ++ (xnc ++ (xnd ++ xt2))) | (_, FTemp ()) => (((xt1 ++ xna) ++ xnb) ++ xnc) ++ xnd | (FTsing xn1, _) => xn1 ++ (xna ++ (xnb ++ (xnc ++ (xnd ++ xt2)))) | (_, FTsing xn2) => ((((xt1 ++ xna) ++ xnb) ++ xnc) ++ xnd) ++ xn2 | (FTdeep (pr1, m1, sf1), FTdeep (pr2, m2, sf2)) => FTdeep (pr1, ftadd4 (m1, sf1, xna, xnb, xnc, xnd, pr2, m2), sf2) // end of [ftapp4] and ftadd4 {a:t@ype} {d:int} {nm1,nm2:nat} {nsf1,npr2:nat} {na,nb,nc,nd:nat} ( m1: fingertree (a, d+1, nm1) , sf1: ftdigit (a, d, nsf1) , xna: ftnode (a, d, na) , xnb: ftnode (a, d, nb) , xnc: ftnode (a, d, nc) , xnd: ftnode (a, d, nd) , pr2: ftdigit (a, d, npr2) , m2: fingertree (a, d+1, nm2) ) : fingertree (a, d+1, nm1+nsf1+na+nb+nc+nd+npr2+nm2) = case+ sf1 of | FTD1 (xn1) => (case+ pr2 of | FTD1 (xn_1) => ftapp2 (m1, FTN3 (xn1, xna, xnb), FTN3 (xnc, xnd, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN2 (xnc, xnd), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN3 (xnc, xnd, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp3 (m1, FTN3 (xn1, xna, xnb), FTN3 (xnc, xnd, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD1] | FTD2 (xn1, xn2) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN2 (xnb, xnc), FTN2 (xnd, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xnd), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp3 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xnd), FTN3 (xn_1, xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xna), FTN3 (xnb, xnc, xnd), FTN2 (xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD2] | FTD3 (xn1, xn2, xn3) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN2 (xnd, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN3 (xnd, xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN2 (xnd, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xna, xnb, xnc), FTN3 (xnd, xn_1, xn_2), FTN2 (xn_3, xn_4), m2) ) // end of [FTD3] | FTD4 (xn1, xn2, xn3, xn4) => (case+ pr2 of | FTD1 (xn_1) => ftapp3 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xnc, xnd, xn_1), m2) | FTD2 (xn_1, xn_2) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN2 (xnc, xnd), FTN2 (xn_1, xn_2), m2) | FTD3 (xn_1, xn_2, xn_3) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xnc, xnd, xn_1), FTN2 (xn_2, xn_3), m2) | FTD4 (xn_1, xn_2, xn_3, xn_4) => ftapp4 (m1, FTN3 (xn1, xn2, xn3), FTN3 (xn4, xna, xnb), FTN3 (xnc, xnd, xn_1), FTN3 (xn_2, xn_3, xn_4), m2) ) // end of [FTD4] // end of [ftadd4] in // in of [local] implement fundeque_append (xt1, xt2) = $effmask_all (ftapp0 (xt1, xt2)) end // end of [local] (* ****** ****** *) typedef ftnode (a:t@ype, d:int) = [n:int] ftnode (a, d, n) // end of [ftnode] (* ****** ****** *) local extern fun foreach {a:t@ype} {v:view} {d:nat} {n:nat} ( pf: !v | xt: fingertree (a, d, n) , f: (!v | ftnode (a, d)) - void ) : void implement foreach {a} {v} {d} (pf | xt, f) = case+ xt of | FTemp () => () | FTsing (xn) => f (pf | xn) | FTdeep (pr, m, sf) => let val () = (case+ pr of | FTD1 (xn1) => f (pf | xn1) | FTD2 (xn1, xn2) => (f (pf | xn1); f (pf | xn2)) | FTD3 (xn1, xn2, xn3) => (f (pf | xn1); f (pf | xn2); f (pf | xn3)) | FTD4 (xn1, xn2, xn3, xn4) => (f (pf | xn1); f (pf | xn2); f (pf | xn3); f (pf | xn4)) ) : void // end of [val] val () = (case+ m of | FTemp () => () | _ => let var !p_clo = @lam ( pf: !v | xn_1: ftnode (a, d+1) ) : void = let in case+ xn_1 of | FTN2 (xn1, xn2) => (f (pf | xn1); f (pf | xn2)) | FTN3 (xn1, xn2, xn3) => (f (pf | xn1); f (pf | xn2); f (pf | xn3)) end // end of [val] val f_1 = __cast (!p_clo) where { extern castfn __cast (f_1: &(!v | ftnode (a, d+1)) - void): (!v | ftnode (a, d+1)) - void } // end of [val] in foreach (pf | m, f_1) end // end of [_] ) : void // end of [val] val () = (case+ sf of | FTD1 (xn1) => f (pf | xn1) | FTD2 (xn1, xn2) => (f (pf | xn1); f (pf | xn2)) | FTD3 (xn1, xn2, xn3) => (f (pf | xn1); f (pf | xn2); f (pf | xn3)) | FTD4 (xn1, xn2, xn3, xn4) => (f (pf | xn1); f (pf | xn2); f (pf | xn3); f (pf | xn4)) ) : void // end of [val] in // nothing end // end of [FTdeep] // end of [foreach] in // in of [local] implement{a} fundeque_foreach_vcloptr {v} {n} (pf0 | xs, f) = let val f = __cast (f) where { extern castfn __cast (f: !(!v | a) - void):<> (!v | a) - void } // end of [val] var !p_clo = @lam ( pf: !v | xn: ftnode (a, 0) ) : void = let val FTN1 (x) = xn in f (pf | x) end // end of [val] val f0 = __cast (!p_clo) where { extern castfn __cast (f0: &(!v | ftnode (a, 0)) - void):<> (!v | ftnode (a, 0)) - void } // end of [val] in $effmask_all (foreach (pf0 | xs, f0)) end // end of [fundeque_foreach_vcloptr] end // end of [local] (* ****** ****** *) implement{a} fundeque_foreach_cloptr {n} (xs, f) = () where { // viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = fundeque_foreach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [fundeque_foreach_cloptr] implement{a} fundeque_foreach_cloref {n} (xs, f) = let viewtypedef cloptr_type = (!unit_v | a) - void val f = __encode (f) where { extern castfn __encode (f: (a) - void):<> cloptr_type } // end of [val] prval pfu = unit_v () val () = fundeque_foreach_vcloptr (pfu | xs, f) prval unit_v () = pfu val _ptr = __decode (f) where { extern castfn __decode (f: cloptr_type):<> ptr } // end of [val] in // nothing end // end of [fundeque_foreach_cloref] (* ****** ****** *) local extern fun rforeach {a:t@ype} {v:view} {d:nat} {n:nat} ( pf: !v | xt: fingertree (a, d, n) , f: (!v | ftnode (a, d)) - void ) : void implement rforeach {a} {v} {d} (pf | xt, f) = case+ xt of | FTemp () => () | FTsing (xn) => f (pf | xn) | FTdeep (pr, m, sf) => let val () = (case+ sf of | FTD1 (xn1) => f (pf | xn1) | FTD2 (xn1, xn2) => (f (pf | xn2); f (pf | xn1)) | FTD3 (xn1, xn2, xn3) => (f (pf | xn3); f (pf | xn2); f (pf | xn1)) | FTD4 (xn1, xn2, xn3, xn4) => (f (pf | xn4); f (pf | xn3); f (pf | xn2); f (pf | xn1)) ) : void // end of [val] val () = (case+ m of | FTemp () => () | _ => let var !p_clo = @lam ( pf: !v | xn_1: ftnode (a, d+1) ) : void = let in case+ xn_1 of | FTN2 (xn1, xn2) => (f (pf | xn2); f (pf | xn1)) | FTN3 (xn1, xn2, xn3) => (f (pf | xn3); f (pf | xn2); f (pf | xn1)) end // end of [val] val f_1 = __cast (!p_clo) where { extern castfn __cast (f_1: &(!v | ftnode (a, d+1)) - void): (!v | ftnode (a, d+1)) - void } // end of [val] in rforeach (pf | m, f_1) end // end of [_] ) : void // end of [val] val () = (case+ pr of | FTD1 (xn1) => f (pf | xn1) | FTD2 (xn1, xn2) => (f (pf | xn2); f (pf | xn1)) | FTD3 (xn1, xn2, xn3) => (f (pf | xn3); f (pf | xn2); f (pf | xn1)) | FTD4 (xn1, xn2, xn3, xn4) => (f (pf | xn4); f (pf | xn3); f (pf | xn2); f (pf | xn1)) ) : void // end of [val] in // nothing end // end of [FTdeep] // end of [rforeach] in // in of [local] implement{a} fundeque_rforeach_vcloptr {v} {n} (pf0 | xs, f) = let val f = __cast (f) where { extern castfn __cast (f: !(!v | a) - void):<> (!v | a) - void } // end of [val] var !p_clo = @lam ( pf: !v | xn: ftnode (a, 0) ) : void = let val FTN1 (x) = xn in f (pf | x) end // end of [val] val f0 = __cast (!p_clo) where { extern castfn __cast (f0: &(!v | ftnode (a, 0)) - void):<> (!v | ftnode (a, 0)) - void } // end of [val] in $effmask_all (rforeach (pf0 | xs, f0)) end // end of [fundeque_rforeach_vcloptr] end // end of [local] (* ****** ****** *) implement{a} fundeque_rforeach_cloptr {n} (xs, f) = () where { // viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = fundeque_rforeach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [fundeque_rforeach_cloptr] implement{a} fundeque_rforeach_cloref {n} (xs, f) = let viewtypedef cloptr_type = (!unit_v | a) - void val f = __encode (f) where { extern castfn __encode (f: (a) - void):<> cloptr_type } // end of [val] prval pfu = unit_v () val () = fundeque_rforeach_vcloptr (pfu | xs, f) prval unit_v () = pfu val _ptr = __decode (f) where { extern castfn __decode (f: cloptr_type):<> ptr } // end of [val] in // nothing end // end of [fundeque_rforeach_cloref] (* ****** ****** *) (* end of [fundeque_fingertree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linmap_skiplist.dats0000664000175000017500000005255212223166162022076 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (***********************************************************************) (* ** ATS/Postiats - Unleashing the Potential of Types! ** Copyright (C) 2011-2012 Hongwei Xi, ATS Trustful Software, Inc. ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Adam Udi *) (* Authoremail: adamudi AT bu DOT edu *) (* Author: Hongwei Xi *) (* Authoremail: hwxi AT cs DOT bu DOT edu *) (* Start time: December, 2012 *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload "libats/SATS/linmap_skiplist.sats" (* ****** ****** *) #define i2sz size1_of_int1 (* ****** ****** *) #define lgMAX 40 // HX: it should be enough: 2^40 >= 10^12 :) (* ****** ****** *) extern fun linmap_random_lgN {n:int | n >= 1} (lgMAX: int (n)): intBtwe (1, n) // end of [linmap_random_lgN] local staload "libc/SATS/random.sats" in // in of [local] implement linmap_random_initize () = srand48_with_time () implement linmap_random_lgN (n) = let val r = drand48 () fun loop {n:int} {i:int | 1 <= i; i <= n} ( n: int n, i: int i, r: double ) : intBtwe (1, n) = if i < n then if (r <= 0.5) then loop (n, i+1, r+r) else i else n // end of [if] // end of [loop] in loop (n, 1, r) end // end of [linmap_random_lgN] end // end of [local] (* ****** ****** *) abstype node_type ( key:t@ype, itm:viewt@ype+, l:addr, n:int ) // end of [node_type] stadef node = node_type typedef node0 ( key:t0p , itm:vt0p , n:int ) = [l:addr] node (key, itm, l, n) typedef node0 ( key:t0p , itm:vt0p ) = [l:addr;n:nat] node (key, itm, l, n) typedef node1 ( key:t0p , itm:vt0p , n:int ) = [l:agz] node (key, itm, l, n) typedef node1 ( key:t0p , itm:vt0p ) = [l:agz;n:nat] node (key, itm, l, n) (* ****** ****** *) typedef nodeGt0 ( key:t0p, itm:vt0p, ni:int ) = [n:int | n > ni] node0 (key, itm, n) (* ****** ****** *) extern castfn node2ptr {key:t0p;itm:vt0p} {l:addr}{n:int} (nx: node (key, itm, l, n)):<> ptr (l) // end of [node2ptr] (* ****** ****** *) fun{ } node_null {key:t0p;itm:vt0p}{n:nat} .<>. (n: int n):<> node (key, itm, null, n) = $UN.castvwtp0 (null) // end of [node_null] (* ****** ****** *) extern fun{ key:t0p;itm:vt0p } node_make {lgN:int | lgN > 0} (k0: key, x0: itm, lgN: int lgN): node1 (key, itm, lgN) // end of [node_make] extern fun{ key:t0p;itm:vt0p } node_free {lgN:int | lgN > 0} (nx: node1 (key, itm, lgN), res: &itm? >> itm): void // end of [node_free] extern fun{ key:t0p;itm:vt0p } node_get_key (nx: node1 (key, itm)):<> key extern fun{ key:t0p;itm:vt0p } node_getref_item (nx: node1 (key, itm)):<> Ptr1 (* ****** ****** *) abstype nodearr_type (key:t@ype, itm:viewt@ype+, int(*size*)) stadef nodearr = nodearr_type extern fun nodearr_get_at {key:t0p;itm:vt0p} {n:int}{i:nat | i < n} (nxa: nodearr (key, itm, n), i: int i):<> nodeGt0 (key, itm, i) // end of [nodearr_get_at] extern fun nodearr_set_at {key:t0p;itm:vt0p} {n:int}{i:nat | i < n} ( nxa: nodearr (key, itm, n), i: int i, nx0: nodeGt0 (key, itm, i) ) :<> void // end of [nodearr_set_at] extern fun nodearr_make // HX: initized with nulls {key:t0p;itm:vt0p}{n:nat} (n: int n):<> nodearr (key, itm, n) // end of [nodearr_make] (* ****** ****** *) // // HX: internal representation of a node // viewtypedef _node ( key: t0p, itm: vt0p ) = @{ key= key, item=itm, nodearr=ptr, nodeasz= int } // end of [_node] (* ****** ****** *) implement {key,itm} node_make {lgN} ( k0, x0, lgN ) = let viewtypedef VT = _node (key, itm) val (pfat, pfgc | p) = ptr_alloc () val () = p->key := k0 val () = p->item := $UN.castvwtp0{itm?}{itm}(x0) val () = p->nodearr := $UN.cast{ptr}(nodearr_make(lgN)) val () = p->nodeasz := lgN in $UN.castvwtp0 {node1(key,itm,lgN)} @(pfat, pfgc | p) end // end of [node_make] implement {key,itm} node_free (nx, res) = let // viewtypedef VT = _node (key, itm) // val ( pfat, pfgc | p ) = __cast (nx) where { extern castfn __cast ( nx: node1 (key, itm) ) :<> [l:addr] (VT @ l, free_gc_v (VT?, l) | ptr l) } // end of [prval] // val () = res := p->item // val () = __free (p->nodearr) where { extern fun __free : ptr -> void = "ats_free_gc" } // end of [val] // val () = ptr_free {VT?} (pfgc, pfat | p) // in // nothing end // end of [node_free] (* ****** ****** *) extern castfn __cast_node {key:t0p;itm:vt0p} ( nx: node1 (key, itm) ) :<> [l:addr] ( _node (key, itm) @ l , _node (key, itm) @ l - void | ptr l ) // end of [node_cast] implement {key,itm} node_get_key (nx) = let val (pf, fpf | p) = __cast_node (nx) val key = p->key prval () = fpf (pf) in key end // end of [node_get_key] implement {key,itm} node_getref_item (nx) = let val (pf, fpf | p) = __cast_node (nx) val p_item = &(p->item) prval () = fpf (pf) in $UN.cast2Ptr1 (p_item) end // end of [node_getref_item] (* ****** ****** *) local assume nodearr_type (key:t0p, itm:vt0p, n:int) = array (ptr, n) // end of [nodearr_type] in // in of [local] implement nodearr_make (n) = let val asz = i2sz(n) in array_make_elt (asz, null) end // end of [nodearr] implement nodearr_get_at {key,itm}{i} (nxa, i) = let typedef T = nodeGt0 (key, itm, i) val nx0 = $effmask_ref (nxa[i]) in $UN.cast{T}(nx0) end // end of [nodearr_get_at] implement nodearr_set_at {key,itm}{i} (nxa, i, nx0) = let val nx0 = $UN.cast{ptr} (nx0) in $effmask_ref (nxa[i] := nx0) end // end of [nodearr_set_at] end // end of [local] (* ****** ****** *) extern fun{ key:t0p;itm:vt0p } node_get_nodearr {n:nat} (nx: node1 (key, itm, n)):<> nodearr (key, itm, n) // end of [node_get_nodearr] implement {key,itm} node_get_nodearr {n} (nx) = let typedef res = nodearr(key, itm, n) val (pf, fpf | p) = __cast_node (nx) val nxa = p->nodearr prval () = fpf (pf) in $UN.cast {res} (nxa) end // end of [node_get_nodearr] (* ****** ****** *) extern fun{ key:t0p;itm:vt0p } node_get_nodeasz {n:nat} (nx: node1 (key, itm, n)):<> int n implement {key,itm} node_get_nodeasz {n} (nx) = let typedef res = int (n) val (pf, fpf | p) = __cast_node (nx) val nxa = p->nodeasz prval () = fpf (pf) in $UN.cast {res} (nxa) end // end of [node_get_nodearr] (* ****** ****** *) extern fun{ key:t0p;itm:vt0p } node_get_next {n:int}{ni:nat | ni < n} (nx: node1 (key, itm, n), ni: int ni):<> nodeGt0 (key, itm, ni) // end of [node_get_next] extern fun{ key:t0p;itm:vt0p } node_set_next {n,n1:int}{ni:nat | ni < n} ( nx: node1 (key, itm, n), ni: int ni, nx0: nodeGt0 (key, itm, ni) ) :<> void // end of [node_set_next] (* ****** ****** *) implement {key,itm} node_get_next (nx, ni) = let val nxa = node_get_nodearr (nx) in nodearr_get_at (nxa, ni) end // end of [node_get_next] implement {key,itm} node_set_next (nx, ni, nx0) = let val nxa = node_get_nodearr (nx) in nodearr_set_at (nxa, ni, nx0) end // end of [node_set_next] (* ****** ****** *) dataviewtype skiplist ( key:t@ype, itm:viewt@ype+ ) = // HX: [lgN] is the *current* highest level | {N:nat}{lgN:nat | lgN <= lgMAX} SKIPLIST (key, itm) of (size_t(N), int(lgN), nodearr(key, itm, lgMAX)) // end of [skiplist] (* ****** ****** *) assume map_viewtype (key:t0p, itm:vt0p) = skiplist (key, itm) // end of [map_viewtype] (* ****** ****** *) implement linmap_make_nil () = SKIPLIST (i2sz(0), 0, nodearr_make (lgMAX)) // end of [linmap_make_nil] (* ****** ****** *) implement linmap_is_nil (map) = let val SKIPLIST (!p_N, _, _) = map; val N = !p_N in fold@ (map); N = i2sz(0) end // end of [linmap_is_nil] implement linmap_isnot_nil (map) = let val SKIPLIST (!p_N, _, _) = map; val N = !p_N in fold@ (map); N > i2sz(0) end // end of [linmap_isnot_nil] (* ****** ****** *) implement linmap_size (map) = let val SKIPLIST (!p_N, _, _) = map; val N = !p_N in fold@ (map); N end // end of [linmap_size] (* ****** ****** *) // // HX: // for [node_search] to be called, k0 > the key contained in it // extern fun{ key:t0p;itm:vt0p } node_search {n:int} ( nx: node1 (key, itm, n), k0: key, ni: natLte n, cmp: cmp key ) :<> node0 (key, itm) // end of [node_search] extern fun{ key:t0p;itm:vt0p } nodearr_search {n:int} ( nxa: nodearr (key, itm, n), k0: key, ni: natLte n, cmp: cmp key ) :<> node0 (key, itm) // end of [nodearr_search] (* ****** ****** *) implement {key,itm} node_search (nx, k0, ni, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx1 = node_get_next (nx, ni1) val p_nx1 = node2ptr (nx1) in // if p_nx1 > null then let val k1 = node_get_key (nx1) val sgn = compare_key_key (k0, k1, cmp) in if sgn < 0 then node_search (nx, k0, ni1, cmp) else if sgn > 0 then node_search (nx1, k0, ni, cmp) else nx1 // end of [if] end else node_search (nx, k0, ni1, cmp) // end of [if] // end else node_null (0) // end // end of [node_search] implement {key,itm} nodearr_search (nxa, k0, ni, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx = nodearr_get_at {key,itm} (nxa, ni1) // end of [val] val p_nx = node2ptr (nx) in if p_nx > null then let val k = node_get_key (nx) val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then nodearr_search (nxa, k0, ni1, cmp) else if sgn > 0 then node_search (nx, k0, ni, cmp) else nx // end of [if] end else nodearr_search (nxa, k0, ni1, cmp) // end of [if] end else node_null (0) // end of [if] // end // end of [nodearr_search] (* ****** ****** *) implement {key,itm} linmap_search (t, k0, cmp, res) = let val [l:addr] p = linmap_search_ref (t, k0, cmp) in // if p > null then let prval (fpf, pf) = __assert () where { extern praxi __assert (): (itm @ l - void, itm @ l) } // end of [prval] val () = res := !p prval () = fpf (pf) prval () = opt_some {itm} (res) in true end else let prval () = opt_none {itm} (res) in false end // end of [if] // end // end of [linmap_search] (* ****** ****** *) implement {key,itm} linmap_search_ref (map, k0, cmp) = let in // case+ map of | SKIPLIST (N, lgN, nxa) => let prval () = fold@ (map) val nx = nodearr_search (nxa, k0, lgN, cmp) val p_nx = node2ptr (nx) in if p_nx > null then node_getref_item (nx) else null // end of [if] end // end of [SKIPLIST] // end // end of [linmap_search_ref] (* ****** ****** *) // // HX: // for [node_insert] to be called, k0 > the key contained in it // extern fun{ key:t0p;itm:vt0p } node_insert {n:int}{ni:nat | ni <= n} ( nx: node1 (key, itm, n), k0: key, ni: int ni, nx0: node1 (key, itm), cmp: cmp key ) : void // end of [node_insert] extern fun{ key:t0p;itm:vt0p } nodearr_insert {n,n0:int}{ni:nat | ni <= n} ( nxa: nodearr (key, itm, n), k0: key, ni: int ni, nx0: node1 (key, itm), cmp: cmp key ) : void // end of [nodearr_insert] implement {key,itm} node_insert (nx, k0, ni, nx0, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx1 = node_get_next (nx, ni1) val p_nx1 = node2ptr (nx1) in if p_nx1 > null then let val k1 = node_get_key (nx1) val sgn = compare_key_key (k0, k1, cmp) in if sgn <= 0 then let val n0 = node_get_nodeasz (nx0) val () = if (n0 >= ni) then { val () = node_set_next (nx, ni1, nx0) val () = node_set_next (nx0, ni1, nx1) } // end of [val] in node_insert (nx, k0, ni1, nx0, cmp) end else node_insert (nx1, k0, ni, nx0, cmp) // end of [if] end else let val n0 = node_get_nodeasz (nx0) val () = if (n0 >= ni) then { val () = node_set_next (nx, ni1, nx0) } // end of [if] in node_insert (nx, k0, ni1, nx0, cmp) end // end of [if] end else ( // nothing ) // end of [if] // end // end of [node_insert] implement {key,itm} nodearr_insert (nxa, k0, ni, nx0, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx = nodearr_get_at {key,itm} (nxa, ni1) val p_nx = node2ptr (nx) in if p_nx > null then let val k = node_get_key (nx) val sgn = compare_key_key (k0, k, cmp) in if sgn <= 0 then let val n0 = node_get_nodeasz (nx0) val () = if (n0 >= ni) then { val () = nodearr_set_at {key,itm} (nxa, ni1, nx0) // end of [val] val () = node_set_next (nx0, ni1, nx) } // end of [val] in nodearr_insert (nxa, k0, ni1, nx0, cmp) end else node_insert (nx, k0, ni, nx0, cmp) // end of [if] end else let val n0 = node_get_nodeasz (nx0) val () = if (n0 >= ni) then { val () = nodearr_set_at {key,itm} (nxa, ni1, nx0) } // end of [val] in nodearr_insert (nxa, k0, ni1, nx0, cmp) end // end of [if] end else ( // nothing ) // end of [if] // end // end of [nodearr_insert] (* ****** ****** *) implement {key,itm} linmap_insert (map, k0, x0, cmp, res) = let // val [l:addr] p_nx = linmap_search_ref (map, k0, cmp) // end of [val] // in // if p_nx > null then let prval (pf, fpf) = __assert () where { extern praxi __assert : () - (itm @ l, itm @ l - void) } // end of [prval] val () = res := !p_nx prval () = opt_some {itm} (res) val () = !p_nx := x0 prval () = fpf (pf) in true end else let val () = linmap_insert_any (map, k0, x0, cmp) prval () = opt_none {itm} (res) in false end // end of [if] // end // end of [linmap_insert] (* ****** ****** *) implement {key,itm} linmap_insert_any (map, k0, x0, cmp) = let // val lgN0 = linmap_random_lgN (lgMAX) val nx0 = node_make (k0, x0, lgN0) // in // case+ map of | SKIPLIST (!p_N, !p_lgN, nxa) => let val N = !p_N val lgN = !p_lgN val () = !p_N := succ (N) val lgN = ( if (lgN < lgN0) then lgN0 else lgN ) : natLte (lgMAX) val () = !p_lgN := lgN val () = nodearr_insert (nxa, k0, lgN, nx0, cmp) prval () = fold@ (map) in // nothing end // end of [SKIPLIST] // end // end of [linmap_insert_any] (* ****** ****** *) // // HX: // for [node_takeout] to be called, k0 > the key contained in it // extern fun{ key:t0p;itm:vt0p } node_takeout {n:int}{ni:nat | ni <= n} (nx: node1 (key, itm, n), k0: key, ni: int ni, cmp: cmp key): nodeGt0 (key, itm, 0) // end of [node_takeout] extern fun{ key:t0p;itm:vt0p } nodearr_takeout {n:int}{ni:nat | ni <= n} (nxa: nodearr (key, itm, n), k0: key, ni: int ni, cmp: cmp key): nodeGt0 (key, itm, 0) // end of [nodearr_takeout] implement {key,itm} node_takeout (nx, k0, ni, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx1 = node_get_next (nx, ni1) val p_nx1 = node2ptr (nx1) in if p_nx1 > null then let val k1 = node_get_key (nx1) val sgn = compare_key_key (k0, k1, cmp) in if sgn < 0 then node_takeout (nx, k0, ni1, cmp) else if sgn > 0 then node_takeout (nx1, k1, ni, cmp) else let // sgn = 0 val () = node_set_next (nx, ni1, node_get_next (nx1, ni1)) // end of [val] in if ni1 > 0 then node_takeout (nx, k0, ni1, cmp) else nx1 end // end of [if] end else node_takeout (nx, k0, ni1, cmp) // end of [if] end else node_null (1) // end of [of] // end // end of [node_takeout] implement {key,itm} nodearr_takeout (nxa, k0, ni, cmp) = let in // if ni > 0 then let val ni1 = ni - 1 val nx = nodearr_get_at {key,itm} (nxa, ni1) val p_nx = node2ptr (nx) in if p_nx > null then let val k = node_get_key (nx) val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then nodearr_takeout (nxa, k0, ni1, cmp) else if sgn > 0 then node_takeout (nx, k0, ni, cmp) else let // sgn = 0 val () = nodearr_set_at {key,itm} (nxa, ni1, node_get_next (nx, ni1)) in if ni1 > 0 then nodearr_takeout (nxa, k0, ni1, cmp) else nx end end else nodearr_takeout (nxa, k0, ni1, cmp) // end of [if] end else node_null (1) // end of [if] // end // end of [nodearr_takeout] (* ****** ****** *) implement {key,itm} linmap_takeout (map, k0, cmp, res) = let in // case+ map of | SKIPLIST (!p_N, lgN, nxa) => let val N = !p_N val nx = nodearr_takeout (nxa, k0, lgN, cmp) val p_nx = node2ptr (nx) in if p_nx > null then let prval () = __assert (N) where { extern praxi __assert {N:int} (N: size_t N): [N>0] void } // end of [prval] val () = !p_N := pred (N) val () = node_free (nx, res) prval () = opt_some {itm} (res) prval () = fold@ (map) in true end else let prval () = fold@ (map) prval () = opt_none {itm} (res) in false end // end of [if] end // end of [SKIPLIST] // end // end of [linmap_takeout] (* ****** ****** *) implement {key,itm} linmap_remove (map, k0, cmp) = let var res: itm val takeout = linmap_takeout (map, k0, cmp, res) prval () = opt_clear (res) in takeout(*removed*) end // end of [linmap_remove] (* ****** ****** *) fun{ key:t0p;itm:vt0p } node_foreach_funenv {v:view}{vt:viewtype} ( pfv: !v | nx: nodeGt0 (key, itm, 0) , f: (!v | key, &itm, !vt) - void , env: !vt ) : void = let val p_nx = node2ptr (nx) in // if p_nx > null then let val k = node_get_key (nx) val [l:addr] p_i = node_getref_item (nx) prval (pf, fpf) = __assert () where { extern praxi __assert : () - (itm @ l, itm @ l - void) } // end of [prval] val () = f (pfv | k, !p_i, env) prval () = fpf (pf) val nx1 = node_get_next (nx, 0) in node_foreach_funenv (pfv | nx1, f, env) end else () // end of [if] // end // end of [node_foreach_env] implement {key,itm} linmap_foreach_funenv (pfv | map, f, env) = let in // case+ map of | SKIPLIST (N, lgN, nxa) => let val nx = nodearr_get_at (nxa, 0) val () = $effmask_all (node_foreach_funenv (pfv | nx, f, env)) prval () = fold@ (map) in // nothing end // end of [SKIPLIST] // end // end of [linmap_foreach_env] (* ****** ****** *) implement{key,itm} linmap_foreach_fun (map, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, &itm) - void):<> (!unit_v | key, &itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linmap_foreach_funenv {unit_v} {ptr} (pfu | map, f, null) prval unit_v () = pfu // in // nothing end // end of [linmap_foreach_fun] (* ****** ****** *) implement{key,itm} linmap_foreach_vclo {v} (pfv | map, f) = let viewtypedef clo_t = (!v | key, &itm) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef v2 = @(v, clo_t @ l_f) // fn app ( pf: !v2 | k: key, x: &itm, p_f: !ptr l_f ) :<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | k, x) in pf := (pf1, pf2) end // end of [app] // prval pf = (pfv, view@ f) val () = linmap_foreach_funenv {v2} {ptr(l_f)} (pf | map, app, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) in // nothing end // end of [linmap_foreach_vclo] (* ****** ****** *) implement{key,itm} linmap_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, &itm) - void):<> (!unit_v | key, &itm) - void } // end of [val] typedef clo_type = (!unit_v | key, &itm) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pf0 = unit_v () val () = $effmask_ref (linmap_foreach_vclo {unit_v} (pf0 | m, !p_f)) prval unit_v () = pf0 in // empty end // end of [linmap_foreach_cloref] (* ****** ****** *) implement {key,itm} linmap_free_vt (m) = let // viewtypedef VT = map (key, itm) val m1 = __cast (m) where { extern castfn __cast : (!VT >> VT?) -<> VT } // in // case+ m1 of | SKIPLIST (N, lgN, nxa) => let in if N = 0 then let val () = free@ {..}{0}{0} (m1) val () = __free (nxa) where { extern fun __free{n:int} (nxa: nodearr (key, itm, n)):<> void = "ATS_FREE" } // end of [val] prval () = opt_none {VT} (m) in false end else let prval () = fold@ (m1) prval () = __assert (m, m1) where { extern praxi __assert : (!VT? >> VT, VT) - void } // end of [val] prval () = opt_some {VT} (m) in true end // end of [if] end // end of [SKIPLIST] // end // end of [linmap_free_vt] (* ****** ****** *) (* end of [linmap_skiplist.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/lockref_spin.dats0000664000175000017500000000312112223166162021336 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libats/SATS/lockref_spin.sats" (* ****** ****** *) // // HX: it is still empty // (* ****** ****** *) (* end of [lockref_spin.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/iterint.dats0000664000175000017500000001561012223166162020344 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some common functions that iterate over natural numbers; // The code mainly serves as an example for writing iterative loops // in ATS // (* ****** ****** *) staload "libats/SATS/iterint.sats" (* ****** ****** *) implement foreach_funenv {v} {vt} {n} {f} (pf | n, f, env) = let typedef fun_t = (!v | natLt n, !vt) - void fun aux {i:nat | i <= n} .. (pf: !v | f: fun_t, n: int n, i: int i, env: !vt): void = if i < n then (f (pf | i, env); aux (pf | f, n, i+1, env)) else () // end of [aux] in aux (pf | f, n, 0, env) end // end of [foreach_funenv] // implement foreach_fun {n} {f:eff} (n, f) = let typedef fun0_t = (natLt n) - void typedef fun1_t = (!unit_v | natLt n, !ptr) - void val f = coerce f where { extern fun coerce (f: fun0_t):<> fun1_t = "atspre_fun_coerce" } // end of [where] prval pfu = unit_v () val () = foreach_funenv {unit_v} {ptr} (pfu | n, f, null) prval unit_v () = pfu in // nothing end // end of [foreach_fun] // implement foreach_vclo {v} {n} {f:eff} (pf | n, f) = let viewtypedef clo_t = (!v | natLt n) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef v1 = @(v, clo_t @ l_f) prval pf1 = (pf, view@ f) fn app (pf1: !v1 | i: natLt n, p_f: !ptr l_f): void = let prval (pf, pf_clo) = pf1 val () = !p_f (pf | i) prval () = pf1 := (pf, pf_clo) in // empty end // end of [app] val () = foreach_funenv {v1} {ptr l_f} {n} {f} (pf1 | n, app, p_f) in pf := pf1.0; view@ f := pf1.1 end // end of [foreach_vclo] // implement foreach_cloref {n} {f:eff} (n, f) = let typedef cloref_t = (natLt n) - void fn app (pf: !unit_v | i: natLt n, f: !cloref_t): void = f (i) prval pf = unit_v () val () = foreach_funenv {unit_v} {cloref_t} {n} {f} (pf | n, app, f) prval unit_v () = pf in // empty end // end of [foreach_cloref] (* ****** ****** *) implement foreach2_funenv {v} {vt} {m,n} {f} (pf | m, n, f, env) = let typedef fun_t = (!v | natLt m, natLt n, !vt) - void fn* aux1 {i:nat | i <= m} .. (pf: !v | f: fun_t, m: int m, n: int n, i: int i, env: !vt): void = if i < m then aux2 (pf | f, m, n, i, 0, env) else () and aux2 {i,j:nat | i < m; j <= n} .. (pf: !v | f: fun_t, m: int m, n: int n, i: int i, j: int j, env: !vt) : void = if j < n then begin (f (pf | i, j, env); aux2 (pf | f, m, n, i, j+1, env)) end else begin aux1 (pf | f, m, n, i+1, env) end in aux1 (pf | f, m, n, 0, env) end // end of [foreach2_funenv] implement foreach2_fun {m,n} {f:eff} (m, n, f) = let typedef fun0_t = (natLt m, natLt n) - void typedef fun1_t = (!unit_v | natLt m, natLt n, !ptr) - void val f = coerce f where { extern fun coerce (f: fun0_t):<> fun1_t = "atspre_fun_coerce" } // end of [where] prval pfu = unit_v () val () = foreach2_funenv {unit_v} {ptr} (pfu | m, n, f, null) prval unit_v () = pfu in // nothing end // end of [foreach2_fun] implement foreach2_vclo {v} {m,n} {f:eff} (pf | m, n, f) = let viewtypedef clo_t = (!v | natLt m, natLt n) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef v1 = @(v, clo_t @ l_f) prval pf1 = (pf, view@ f) fn app (pf1: !v1 | i: natLt m, j: natLt n, p_f: !ptr l_f): void = let prval (pf, pf_clo) = pf1 val () = !p_f (pf | i, j) prval () = pf1 := (pf, pf_clo) in // empty end // end of [app] val () = foreach2_funenv {v1} {ptr l_f} {m,n} {f} (pf1 | m, n, app, p_f) in pf := pf1.0; view@ f := pf1.1 end // end of [foreach2_vclo] implement foreach2_cloref {m,n} {f:eff} (m, n, f) = let typedef cloref_t = (natLt m, natLt n) - void fn app (pf: !unit_v | i: natLt m, j: natLt n, f: !cloref_t): void = f (i, j) prval pf = unit_v () val () = foreach2_funenv {unit_v} {cloref_t} (pf | m, n, app, f) prval unit_v () = pf in // empty end // end of [foreach2_cloref] (* ****** ****** *) implement repeat_funenv {v} {vt} {n} {f} (pf | n, f, env) = let typedef fun_t = (!v | !vt) - void fun aux {i:nat | i <= n} .. (pf: !v | f: fun_t, i: int i, env: !vt): void = if i > 0 then (f (pf | env); aux (pf | f, i-1, env)) else () // end of [aux] in aux (pf | f, n, env) end // end of [repeat_funenv] implement repeat_fun {n} {f:eff} (n, f) = let typedef fun0_t = () - void typedef fun1_t = (!unit_v | !ptr) - void val f = coerce f where { extern fun coerce (f: fun0_t):<> fun1_t = "atspre_fun_coerce" } // end of [where] prval pfu = unit_v () val () = repeat_funenv {unit_v} {ptr} (pfu | n, f, null) prval unit_v () = pfu in // nothing end // end of [repeat_fun] implement repeat_vclo {v} {n} {f:eff} (pf | n, f) = let viewtypedef clo_t = (!v | (*none*)) - void stavar l_f: addr; val p_f: ptr l_f = &f viewdef v1 = @(v, clo_t @ l_f) prval pf1 = (pf, view@ f) fn app (pf1: !v1 | p_f: !ptr l_f): void = let prval (pf, pf_clo) = pf1 val () = !p_f (pf | (*none*)) prval () = pf1 := (pf, pf_clo) in // empty end // end of [app] val () = repeat_funenv {v1} {ptr l_f} {n} {f} (pf1 | n, app, p_f) in pf := pf1.0; view@ f := pf1.1 end // end of [repeat_vclo] implement repeat_cloref {n} {f} (n, f) = let typedef cloref_t = () - void fn app (pf: !unit_v | f: !cloref_t): void = f () prval pf = unit_v () val () = repeat_funenv {unit_v} {cloref_t} (pf | n, app, f) prval unit_v () = pf in // empty end // end of [repeat_cloref] (* ****** ****** *) (* end of [iterint.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funmset_listord.dats0000664000175000017500000002767212223166162022122 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May 18, 2011 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/list.dats" (* ****** ****** *) staload "libats/SATS/funmset_listord.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{elt} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) assume mset_t0ype_type (elt: t@ype) = List @(Pos, elt) (* ****** ****** *) // // HX: // mset is represented as a sorted mlist in descending order; // note that desending order is chosen to facilitate mset comparion // (* ****** ****** *) implement{} funmset_make_nil () = list_nil () implement{a} funmset_make_sing (x) = list_cons ((1, x), list_nil) implement{a} funmset_make_pair (x1, x2, cmp) = let val sgn = compare_elt_elt (x1, x2, cmp) // end of [val] in // if sgn > 0 then let val nx1 = (1, x1) and nx2 = (1, x2) in list_pair (nx1, nx2) end else if sgn < 0 then let val nx1 = (1, x1) and nx2 = (1, x2) in list_pair (nx2, nx1) end else let val nx = @(2, x1) in list_sing (nx) end // end of [if] // end // end of [funmset_make_pair] implement{a} funmset_make_list (xs, cmp) = let var env: ptr = null // // HX: ~cmp: descending order // var !p_clo = @lam (x1: &a, x2: &a): int = ~cmp (x1, x2) val xs = list_copy (xs) val xs = list_vt_mergesort (xs, !p_clo) fun ntimes {k:nat} .. ( xs: list_vt (a, k), x0: a, n: &Pos >> Pos ) :<> [k1:nat | k1 <= k] list_vt (a, k1) = case+ xs of | list_vt_cons (x, !p_xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn > 0 then let prval () = fold@ (xs) in xs end else let val () = n := n + 1 val xs1 = !p_xs val () = free@ {a}{0} (xs) in ntimes (xs1, x0, n) end // end of [if] end // end of [list_vt_cons] | list_vt_nil () => let prval () = fold@ (xs) in xs end // end of [list_vt_nil] // end of [ntimes] fun loop {k:nat} .. ( xs: list_vt (a, k), res: &mset(a)? >> mset(a) ) :<> void = case+ xs of | ~list_vt_cons (x0, xs) => let var n: Pos = 1 val xs = ntimes (xs, x0, n) val nx0 = @(n, x0) val () = res := list_cons {..}{0} (nx0, ?) val+ list_cons (_, !p_res) = res val () = loop (xs, !p_res) prval () = fold@ (res) in // nothing end // end of [list_vt_cons] | ~list_vt_nil () => let val () = res := list_nil () in (*nothing*) end // end of [list_vt_nil] // end of [loop] var res: mset(a) val () = loop (xs, res) in res end // end of [funmset_make_list] (* ****** ****** *) implement{a} funmset_size (nxs) = let typedef nx = @(Pos, a) fun loop {k:nat} .. ( nxs: list (nx, k), res: size_t ) : size_t = case+ nxs of | list_cons (nx, nxs) => loop (nxs, res + nx.0) | list_nil () => res // end of [loop] in loop (nxs, 0) end // end of [funmset_size] (* ****** ****** *) implement{a} funmset_get_ntime (nxs, x0, cmp) = let typedef nx = @(Pos, a) fun aux {k:nat} .. ( nxs: list (nx, k) ) : Nat = case+ nxs of | list_cons (nx, nxs) => let val sgn = compare_elt_elt (x0, nx.1, cmp) in if sgn > 0 then 0 else (if sgn < 0 then aux (nxs) else nx.0) end // end of [list_cons] | list_nil () => 0 // end of [aux] val n = aux (nxs) in uint1_of_int1 (n) end // end of [funmset_get_ntime] (* ****** ****** *) implement{a} funmset_is_member (xs, x0, cmp) = funmset_get_ntime (xs, x0, cmp) > 0u // end of [funmset_is_member] implement{a} funmset_isnot_member (xs, x0, cmp) = funmset_get_ntime (xs, x0, cmp) = 0u // end of [funmset_isnot_member] (* ****** ****** *) implement{a} funmset_insert (nxs, x0, cmp) = let // typedef nx = @(Pos, a) // fun aux {k:nat} .. ( nxs: list (nx, k) ) : List (nx) = case+ nxs of | list_cons (nx, nxs1) => let val sgn = compare_elt_elt (x0, nx.1, cmp) in if sgn > 0 then list_cons ((1, x0), nxs) else if sgn < 0 then let val nxs1 = aux (nxs1) in list_cons (nx, nxs1) end else let val nx = (nx.0 + 1, nx.1) in list_cons (nx, nxs1) end (* end of [if] *) end // end of [list_cons] | list_nil () => list_cons ((1, x0), list_nil) // end of [aux] // in nxs := aux (nxs) end // end of [funmset_insert] (* ****** ****** *) implement{a} funmset_remove (nxs, x0, cmp) = let // typedef nx = @(Pos, a) // fun aux {k:nat} .. ( nxs: list (nx, k), flag: &int ) : List (nx) = case nxs of | list_cons (nx, nxs1) => let val sgn = compare_elt_elt (x0, nx.1, cmp) in if sgn > 0 then nxs else if sgn < 0 then let val flag0 = flag val nxs1 = aux (nxs1, flag) in if flag = flag0 then nxs else list_cons (nx, nxs1) end else let val n1 = nx.0 - 1 val () = flag := flag + 1 in if n1 > 0 then list_cons ((n1, nx.1), nxs1) else nxs1 end (* end of [if] *) end // end of [list_cons] | list_nil () => list_nil () // end of [aux] // var flag: int = 0 val () = nxs := aux (nxs, flag) // in if flag > 0 then true else false end // end of [funmset_remove] (* ****** ****** *) implement{a} funmset_union (nxs1, nxs2, cmp) = let // typedef nx = @(Pos, a) // fun aux {k1,k2:nat} .. ( nxs1: list (nx, k1), nxs2: list (nx, k2) ) : List (nx) = case nxs1 of | list_cons (nx1, nxs11) => ( case+ nxs2 of | list_cons (nx2, nxs21) => let val sgn = compare_elt_elt (nx1.1, nx2.1, cmp) in if sgn > 0 then list_cons (nx1, aux (nxs11, nxs2)) else if sgn < 0 then list_cons (nx2, aux (nxs1, nxs21)) else let val nx12 = (nx1.0 + nx2.0, nx1.1) in list_cons (nx12, aux (nxs11, nxs21)) end (* end of [if] *) end // end of [list_cons] | list_nil () => nxs1 ) // end of [list_cons] | list_nil () => nxs2 // in aux (nxs1, nxs2) end // end of [funmset_union] (* ****** ****** *) implement{a} funmset_intersect (nxs1, nxs2, cmp) = let // typedef nx = @(Pos, a) // fun aux {k1,k2:nat} .. ( nxs1: list (nx, k1), nxs2: list (nx, k2) ) : List (nx) = case nxs1 of | list_cons (nx1, nxs11) => ( case+ nxs2 of | list_cons (nx2, nxs21) => let val sgn = compare_elt_elt (nx1.1, nx2.1, cmp) // end of [val] in if sgn > 0 then aux (nxs11, nxs2) else if sgn < 0 then aux (nxs1, nxs21) else let val nx12 = ( if nx1.0 <= nx2.0 then nx1 else nx2 ) : nx // end of [val] in list_cons (nx1, aux (nxs11, nxs21)) end // end of [if] end // end of [list_cons] | list_nil () => list_nil () ) // end of [list_cons] | list_nil () => list_nil () // in aux (nxs1, nxs2) end // end of [funmset_intersect] (* ****** ****** *) implement{a} funmset_is_subset (nxs1, nxs2, cmp) = let // typedef nx = (int, a) fun aux // tail-recursive {k1,k2:nat} .. ( nxs1: list (nx, k1), nxs2: list (nx, k2) ) : bool = case+ nxs1 of | list_cons (nx1, nxs11) => ( case+ nxs2 of | list_cons (nx2, nxs21) => let val sgn = compare_elt_elt (nx1.1, nx2.1, cmp) in if sgn > 0 then false else if sgn < 0 then aux (nxs1, nxs21) else ( if nx1.0 <= nx2.0 then aux (nxs11, nxs21) else false ) // end of [if] end // end of [list_cons] | list_nil () => false ) // end of [list_cons] | list_nil () => true // end of [aux] in aux (nxs1, nxs2) end // end of [funmset_is_subset] implement{a} funmset_is_equal (nxs1, nxs2, cmp) = let // typedef nx = (int, a) fun aux // tail-recursive {k1,k2:nat} .. ( nxs1: list (nx, k1), nxs2: list (nx, k2) ) : bool = ( case+ nxs1 of | list_cons (nx1, nxs1) => ( case+ nxs2 of | list_cons (nx2, nxs2) => let val sgn = compare_elt_elt (nx1.1, nx2.1, cmp) in if sgn = 0 then ( if nx1.0 = nx2.0 then aux (nxs1, nxs2) else false ) else false // end of [if] end // end of [list_cons] | list_nil () => false ) // end of [list_cons] | list_nil () => (case+ nxs2 of | list_cons _ => false | list_nil () => true ) // end of [list_nil] ) // end of [aux] // in aux (nxs1, nxs2) end // end of [funmset_is_equal] (* ****** ****** *) implement{a} funmset_compare (nxs1, nxs2, cmp) = let // typedef nx = (int, a) // fun aux // tail-recursive {k1,k2:nat} .. ( nxs1: list (nx, k1), nxs2: list (nx, k2) ) : int = ( case+ nxs1 of | list_cons (nx1, nxs1) => ( case+ nxs2 of | list_cons (nx2, nxs2) => let val sgn = compare_elt_elt (nx1.1, nx2.1, cmp) in if sgn > 0 then 1 else if sgn < 0 then ~1 else let val n1 = nx1.0 and n2 = nx2.0 in if n1 > n2 then 1 else if n1 < n2 then ~1 else aux (nxs1, nxs2) end (* end of [if] *) end // end of [list_cons] | list_nil () => 1 ) // end of [list_cons] | list_nil () => ( case+ nxs2 of list_cons _ => ~1 | list_nil _ => 0 ) ) // end of [aux] // in aux (nxs1, nxs2) end // end of [funmset_compare] (* ****** ****** *) (* ** HX: the returned list is in descending order *) implement{a} funmset_listize (nxs) = let typedef nx = @(Pos, a) viewtypedef res = List_vt (a) in list_map_fun (nxs, lam (nx) =<0> nx.1) end // end of [funmset_listize] (* ****** ****** *) (* ** HX: the returned list is in descending order *) implement{a} funmset_mlistize (nxs) = let typedef nx = @(Pos, a) viewtypedef res = List_vt (a) fn* loop1 {k:nat} .. ( nxs: list (nx, k), res: &res? >> res ) :<> void = case+ nxs of | list_cons (nx, nxs) => loop2 (nx.0, nx.1, nxs, res) | list_nil () => (res := list_vt_nil) (* end of [loop1] *) and loop2 {k,n:nat} .. ( n: int n, x: a, nxs: list (nx, k), res: &res? >> res ) :<> void = if n > 0 then let val () = res := list_vt_cons {..}{0} (x, ?) // end of [val] val list_vt_cons (_, !p_res) = res val () = loop2 (n-1, x, nxs, !p_res) prval () = fold@ (res) in // nothing end else loop1 (nxs, res) // end of [if] (* end of [loop2] *) var res: res // uninitialized val () = loop1 (nxs, res) in res end // end of [funmset_mlistize] (* ****** ****** *) (* end of [funmset_listord.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/genarrays.dats0000664000175000017500000012610512223166162020663 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Various kinds of (generic) arrays ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/fmatrix.sats" staload "libats/SATS/genarrays.sats" (* ****** ****** *) infixl (imul) szmul #define szmul mul_size_size #define sz2sz size1_of_size (* ****** ****** *) implement{a} GEVEC_ptr_takeout {n} {d} {l0} (pf_vec | p_vec, d, i) = let viewdef V0 = GEVEC_v (a, n, d, l0) val ofs = (i * d) szmul sizeof val [ofs:int] ofs = sz2sz (ofs) // no-op casting stadef l = l0 + ofs prval (pf_at, fpf_vec) = __cast (pf_vec) where { extern prfun __cast (pf: V0): (a @ l, a @ l - V0) } // end of [prval] in #[l | (pf_at, fpf_vec | p_vec + ofs) ] end // end of [GEVEC_ptr_takeout] (* ****** ****** *) implement{a1} GEVEC_ptr_split {n,i} {d} {l0} (pf_vec | p_vec, d, i) = let viewdef V0 (a: viewt@ype) = GEVEC_v (a, n, d, l0) val ofs = (i * d) szmul sizeof val [ofs:int] ofs = sz2sz (ofs) // no-op casting stadef l = l0 + ofs viewdef V1 (a: viewt@ype) = GEVEC_v (a, i, d, l0) viewdef V2 (a: viewt@ype) = GEVEC_v (a, n-i, d, l) prval (pf1_vec, pf2_vec, fpf_vec) = __cast (pf_vec) where { extern prfun __cast (pf: V0 a1): (V1 a1, V2 a1, {a2:viewt@ype | a1 \tszeq a2} (V1 a2, V2 a2) - V0 a2) } // end of [prval] in #[l | (pf1_vec, pf2_vec, fpf_vec | p_vec + ofs) ] end // end of [GEVEC_ptr_split] (* ****** ****** *) implement{a} GEVEC_ptr_get_elt_at (V, d, i) = x where { val (pf, fpf | p) = GEVEC_ptr_takeout (view@ V | &V, d, i) val x = !p prval () = view@ V := fpf (pf) } // end of [GEVEC_ptr_get_elt_at] implement{a} GEVEC_ptr_set_elt_at (V, d, i, x) = () where { val (pf, fpf | p) = GEVEC_ptr_takeout (view@ V | &V, d, i) val () = !p := x prval () = view@ V := fpf (pf) } // end of [GEVEC_ptr_set_elt_at] (* ****** ****** *) // X <- alpha implement{a} GEVEC_ptr_initialize_elt {m} {incX} (X, m, incX, alpha) = let val (pf_mul | ofs) = mul2_size1_size1 (incX, sizeof) fun loop {n:nat} {lX:addr} .. ( pf_vec: !GEVEC_v (a?, n, incX, lX) >> GEVEC_v (a, n, incX, lX) | pX: ptr lX, n: size_t n ) : void = if n > 0 then let prval (pf_at, pf1_vec) = GEVEC_v_uncons {a?} (pf_mul, pf_vec) val () = !pX := alpha val () = loop (pf1_vec | pX + ofs, n-1) prval () = pf_vec := GEVEC_v_cons {a} (pf_mul, pf_at, pf1_vec) in // nothing end else let prval () = GEVEC_v_unnil (pf_vec) prval () = pf_vec := GEVEC_v_nil {a} {incX} {lX} () in // nothing end // end of [if] // end of [loop] in loop (view@ X | &X, m) end // end of [GEVEC_ptr_initialize_elt] (* ****** ****** *) implement{a} GEVEC_ptr_copy {m} {d1,d2} (X1, X2, m, d1, d2) = let val (pf1_mul | ofs1) = mul2_size1_size1 (d1, sizeof) val (pf2_mul | ofs2) = mul2_size1_size1 (d2, sizeof) fun loop {mi:nat | mi <= m} {l1,l2:addr} .. ( pf1: !GEVEC_v (a, mi, d1, l1) , pf2: !GEVEC_v (a?, mi, d2, l2) >> GEVEC_v (a, mi, d2, l2) | p1: ptr l1, p2: ptr l2, mi: size_t mi ) : void = if mi > 0 then let prval (pf11, pf12) = GEVEC_v_uncons {a} (pf1_mul, pf1) prval (pf21, pf22) = GEVEC_v_uncons {a?} (pf2_mul, pf2) val () = !p2 := !p1 val () = loop (pf12, pf22 | p1+ofs1, p2+ofs2, mi-1) prval () = pf1 := GEVEC_v_cons {a} (pf1_mul, pf11, pf12) prval () = pf2 := GEVEC_v_cons {a} (pf2_mul, pf21, pf22) in // empty end else let prval () = GEVEC_v_unnil (pf2) in pf2 := GEVEC_v_nil {a} () end // end of [if] in loop (view@ X1, view@ X2 | &X1, &X2, m) end // end of [GEVEC_ptr_copy] (* ****** ****** *) implement GEVEC_ptr_foreach_funenv_tsz {a} {v} {vt} {n} {d} (pf | base, f, vsz, inc, tsz, env) = let val (pf_mul | ofs) = mul2_size1_size1 (inc, tsz) fun loop {l:addr} {n:nat} .. ( pf: !v , pf_vec: !GEVEC_v (a, n, d, l) | p: ptr l, n: size_t n, env: !vt ) : void = if n > 0 then let prval (pf_at, pf1_vec) = GEVEC_v_uncons {a} (pf_mul, pf_vec) val () = f (pf | !p, env) val () = loop (pf, pf1_vec | p+ofs, n-1, env) prval () = pf_vec := GEVEC_v_cons {a} (pf_mul, pf_at, pf1_vec) in // nothing end // end of [if] (* end of [loop] *) in loop (pf, view@ base | &base, vsz, env) end // end of [GEVEC_ptr_foreach_funenv_tsz] // implement{a} GEVEC_ptr_foreach_fun {v} (base, f, n, inc) = let val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void) :<> (!unit_v | &a, !ptr) -<> void } // end of [where] // prval pfu = unit_v () val () = GEVEC_ptr_foreach_funenv_tsz {a} {unit_v} {ptr} (pfu | base, f, n, inc, sizeof, null) prval unit_v () = pfu // in // nothing end // end of [GEVEC_ptr_foreach_fun_tsz] // implement{a} GEVEC_ptr_foreach_vclo {v} (pf_v | base, f, vsz, inc) = let stavar l_f: addr val p_f: ptr l_f = &f typedef clo_t = (!v | &a) - void viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf in !p_f (pf1 | x); pf := @(pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = GEVEC_ptr_foreach_funenv_tsz {a} {V} {ptr l_f} (pf | base, app, vsz, inc, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [GEVEC_ptr_foreach_vclo] (* ****** ****** *) implement GEVEC_ptr_iforeach_funenv_tsz {a} {v} {vt} {n} {d} (pf | base, f, vsz, inc, tsz, env) = let val (pf_mul | ofs) = mul2_size1_size1 (inc, tsz) fun loop {l:addr} {ni:nat | ni <= n} .. ( pf: !v , pf_vec: !GEVEC_v (a, ni, d, l) | p: ptr l, ni: size_t ni, env: !vt ) : void = if ni > 0 then let prval (pf_at, pf1_vec) = GEVEC_v_uncons {a} (pf_mul, pf_vec) val () = f (pf | vsz - ni, !p, env) val () = loop (pf, pf1_vec | p+ofs, ni-1, env) prval () = pf_vec := GEVEC_v_cons {a} (pf_mul, pf_at, pf1_vec) in // nothing end // end of [if] (* end of [loop] *) in loop (pf, view@ base | &base, vsz, env) end // end of [GEVEC_ptr_iforeach_funenv_tsz] implement{a} GEVEC_ptr_iforeach_fun {n} (base, f, n, inc) = let // val f = coerce (f) where { extern castfn coerce (f: (sizeLt n, &a) -<> void) :<> (!unit_v | sizeLt n, &a, !ptr) -<> void } // end of [where] // prval pfu = unit_v () val () = GEVEC_ptr_iforeach_funenv_tsz {a} {unit_v} {ptr} (pfu | base, f, n, inc, sizeof, null) prval unit_v () = pfu // in // nothing end // end of [GEVEC_ptr_iforeach_fun_tsz] (* ****** ****** *) implement GEVEC_ptr_iforeach_cloenv_tsz {a} {v} {vt} {n} {d} (pf | base, f, vsz, inc, tsz, env) = let val (pf_mul | ofs) = mul2_size1_size1 (inc, tsz) fun loop {l:addr} {ni:nat | ni <= n} .. ( pf: !v , pf_vec: !GEVEC_v (a, ni, d, l) | p: ptr l , f: &(!v | sizeLt n, &a, !vt) - void , ni: size_t ni, env: !vt ) : void = if ni > 0 then let prval (pf_at, pf1_vec) = GEVEC_v_uncons {a} (pf_mul, pf_vec) val () = f (pf | vsz - ni, !p, env) val () = loop (pf, pf1_vec | p+ofs, f, ni-1, env) prval () = pf_vec := GEVEC_v_cons {a} (pf_mul, pf_at, pf1_vec) in // nothing end // end of [if] (* end of [loop] *) in loop (pf, view@ base | &base, f, vsz, env) end // end of [GEVEC_ptr_iforeach_cloenv_tsz] // implement{a} GEVEC_ptr_iforeach_vclo {v} {n} (pf | base, f, n, inc) = let stavar l_f: addr val p_f = (&f: ptr l_f) typedef clo_t = (!v | sizeLt n, &a) - void typedef clo1_t = (!v | sizeLt n, &a, !ptr) - void prval () = view@ f := coerce (view@ f) where { extern prfun coerce (pf_clo: clo_t @ l_f): clo1_t @ l_f } // end of [where] val () = GEVEC_ptr_iforeach_cloenv_tsz {a} {v} {ptr} (pf | base, f, n, inc, sizeof, null) prval () = view@ f := coerce (view@ f) where { extern prfun coerce (pf_clo: clo1_t @ l_f): clo_t @ l_f } // end of [prval] in // nothing end // end of [GEVEC_ptr_iforeach_vclo] (* ****** ****** *) implement MATVECINC_get (pf | x1, x2, ld) = case+ (x1, x2) of | (ORDERrow (), ORDERrow ()) => let prval MATVECINCrowrow () = pf in 1 end // end [row, row] | (ORDERrow (), ORDERcol ()) => let prval MATVECINCrowcol () = pf in ld end // end [row, col] | (ORDERcol (), ORDERrow ()) => let prval MATVECINCcolrow () = pf in ld end // end [col, row] | (ORDERcol (), ORDERcol ()) => let prval MATVECINCcolcol () = pf in 1 end // end [col, col] // end of [MATVECINC_get] (* ****** ****** *) implement{a} GEMAT_ptr_takeout {ord} {m, n} {ld} {l0} (pf_mat | ord, p_mat, ld, i, j) = let viewdef V0 = GEMAT_v (a, m, n, ord, ld, l0) val ofs = (case+ ord of | ORDERrow () => (i szmul ld + j) * sizeof | ORDERcol () => (i + j szmul ld) * sizeof ) : size_t val [ofs:int] ofs = sz2sz (ofs) stadef l = l0 + ofs prval (pf_at, fpf_mat) = __cast (pf_mat) where { extern prfun __cast (pf: V0): (a @ l, a @ l - V0) } // end of [prval] in #[l | (pf_at, fpf_mat | p_mat + ofs) ] end // end of [GEMAT_ptr_takeout] (* ****** ****** *) implement{a} GEMAT_ptr_get_elt_at (ord, A, ld, i, j) = let val (pf, fpf | p) = GEMAT_ptr_takeout (view@ A | ord, &A, ld, i, j) val x = !p prval () = view@ A := fpf (pf) in x // the return value end // end of [GEMAT_ptr_get_elt_at] implement{a} GEMAT_ptr_set_elt_at (ord, A, ld, i, j, x) = let val (pf, fpf | p) = GEMAT_ptr_takeout (view@ A | ord, &A, ld, i, j) val () = !p := x prval () = view@ A := fpf (pf) in // nothing end // end of [GEMAT_ptr_set_elt_at] (* ****** ****** *) implement{a} GEMAT_ptr_tail_row {ord} {m,n} {ld} {l0} (pf_mat | ord, p_mat, ld) = let viewdef V0 = GEMAT_v (a, m, n, ord, ld, l0) val ofs = (case+ ord of | ORDERrow () => ld * sizeof | ORDERcol () => sizeof ) : size_t // end of [val] val [ofs:int] ofs = sz2sz (ofs) stadef l = l0 + ofs viewdef V1 = GEMAT_v (a, m-1, n, ord, ld, l) prval (pf1_mat, fpf_mat) = __cast (pf_mat) where { extern prfun __cast (pf: V0): (V1, V1 - V0) } // end of [prval] in #[l | (pf1_mat, fpf_mat | p_mat + ofs) ] end // end of [GEMAT_ptr_tail_row] (* ****** ****** *) implement{a} GEMAT_ptr_tail_col {ord} {m,n} {ld} {l0} (pf_mat | ord, p_mat, ld) = let viewdef V0 = GEMAT_v (a, m, n, ord, ld, l0) val ofs = (case+ ord of | ORDERrow () => sizeof | ORDERcol () => ld * sizeof ) : size_t // end of [val] val [ofs:int] ofs = sz2sz (ofs) stadef l = l0 + ofs viewdef V1 = GEMAT_v (a, m, n-1, ord, ld, l) prval (pf1_mat, fpf_mat) = __cast (pf_mat) where { extern prfun __cast (pf: V0): (V1, V1 - V0) } // end of [prval] in #[l | (pf1_mat, fpf_mat | p_mat + ofs) ] end // end of [GEMAT_ptr_tail_col] (* ****** ****** *) extern fun GEMAT_ptr_split1x2_tsz {a1:viewt@ype} {ord:order} {m,n,j:nat | j <= n} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, j: size_t j, tsz: sizeof_t a1 ) :<> GEMAT_ptr_split1x2_res_t (a1, m, n, j, ord, ld, l0) // end of [GEMAT_ptr_split1x2_tsz] implement GEMAT_ptr_split1x2_tsz {a1} {ord} {m,n,j} {ld} {l0} (pf_mat | ord, p_mat, ld, j, tsz) = let val ofs = (case ord of | ORDERrow () => j szmul tsz | ORDERcol () => (j * ld) szmul tsz ) : size_t // end of [val] val ofs = sz2sz (ofs) val res = (unit_v, unit_v, unit_p | p_mat, p_mat + ofs) extern castfn __cast {vt:viewt@ype} (pf: GEMAT_v (a1, m, n, ord, ld, l0) | res: vt) :<> GEMAT_ptr_split1x2_res_t (a1, m, n, j, ord, ld, l0) // end of [__cast] in __cast (pf_mat | res) end // end of [GEMAT_ptr_split1x2_tsz] implement{a1} GEMAT_ptr_split1x2 (pf_mat | ord, p_mat, ld, j) = GEMAT_ptr_split1x2_tsz {a1} (pf_mat | ord, p_mat, ld, j, sizeof) // end of [GEMAT_ptr_split1x2] (* ****** ****** *) extern fun GEMAT_ptr_split2x1_tsz {a1:viewt@ype} {ord:order} {m,n,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, i: size_t i, tsz: sizeof_t a1 ) :<> GEMAT_ptr_split2x1_res_t (a1, m, n, i, ord, ld, l0) // end of [GEMAT_ptr_split2x1_tsz] implement GEMAT_ptr_split2x1_tsz {a1} {ord} {m,n,i} {ld} {l0} (pf_mat | ord,p_mat, ld, i, tsz) = let val ofs = (case ord of | ORDERrow () => (i * ld) szmul tsz | ORDERcol () => i szmul tsz ) : size_t // end of [val] val ofs = sz2sz (ofs) val res = (unit_v, unit_v, unit_p | p_mat, p_mat + ofs) extern castfn __cast {vt:viewt@ype} (pf: GEMAT_v (a1, m, n, ord, ld, l0) | res: vt) :<> GEMAT_ptr_split2x1_res_t (a1, m, n, i, ord, ld, l0) // end of [__cast] in __cast (pf_mat | res) end // end of [GEMAT_ptr_split2x1_tsz] implement{a1} GEMAT_ptr_split2x1 (pf_mat | ord, p_mat, ld, i) = GEMAT_ptr_split2x1_tsz {a1} (pf_mat | ord, p_mat, ld, i, sizeof) // end of [GEMAT_ptr_split2x1] (* ****** ****** *) extern fun GEMAT_ptr_split2x2_tsz {a1:viewt@ype} {ord:order} {m,n,i,j:nat | i <= m; j <= n} {ld:inc} {l0:addr} ( pf_mat: GEMAT_v (a1, m, n, ord, ld, l0) | ord: ORDER ord, p_mat: ptr l0, ld: size_t ld, i: size_t i, j: size_t j, tsz: sizeof_t a1 ) :<> GEMAT_ptr_split2x2_res_t (a1, m, n, i, j, ord, ld, l0) // end of [GEMAT_ptr_split2x2_tsz] implement GEMAT_ptr_split2x2_tsz {a1} {ord} {m,n,i,j} {ld} {l0} (pf_mat | ord, p_mat, ld, i, j, tsz) = let val res = (case+ ord of | ORDERrow () => let val i_tmp = sz2sz (j * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((i * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_v, unit_p | p_mat, p_mat + i_tmp, p_tmp, p_tmp + i_tmp ) end // end of [ORDERrow] | ORDERcol () => let val i_tmp = sz2sz (i * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((j * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_v, unit_p | p_mat, p_tmp, p_mat + i_tmp, p_tmp + i_tmp ) end // end of [ORDERcol] ) : ( unit_v, unit_v, unit_v, unit_v, unit_p | ptr, ptr, ptr, ptr ) // end of [val] extern castfn __cast {vt:viewt@ype} (pf: GEMAT_v (a1, m, n, ord, ld, l0) | res: vt) :<> GEMAT_ptr_split2x2_res_t (a1, m, n, i, j, ord, ld, l0) // end of [__cast] in __cast (pf_mat | res) end // end of [GEMAT_ptr_split2x2_tsz] implement{a1} GEMAT_ptr_split2x2 (pf_mat | ord, p_mat, ld, i, j) = GEMAT_ptr_split2x2_tsz {a1} (pf_mat | ord, p_mat, ld, i, j, sizeof) // end of [GEMAT_ptr_split2x2] (* ****** ****** *) implement{a} GEMAT_row_ptr_allocfree {m,n} (m, n) = let val [nm:int] [l:addr] (pf_gc, pf_nm, pf_fmat | p) = fmatrix_ptr_alloc (n, m) prval () = mul_nat_nat_nat (pf_nm) prval (pf_gmat, fpf_fmat) = GEMAT_v_of_fmatrix_v (pf_fmat) prval TRANORDcolrow () = GEMAT_v_trans (pf_gmat) val free = lam ( pf_gmat: GEMAT (a?, m, n, row, n) @ l | p: ptr l ) : void = let prval TRANORDrowcol () = GEMAT_v_trans (pf_gmat) in fmatrix_ptr_free {a?} (pf_gc, pf_nm, fpf_fmat {a?} (pf_gmat) | p) end // end of [val] in (pf_gmat | p, free) end // end of [GEMAT_ptr_allocfree] (* ****** ****** *) implement{a} GEMAT_col_ptr_allocfree {m,n} (m, n) = let val [mn:int] [l:addr] (pf_gc, pf_mn, pf_fmat | p) = fmatrix_ptr_alloc (m, n) prval () = mul_nat_nat_nat (pf_mn) prval (pf_gmat, fpf_fmat) = GEMAT_v_of_fmatrix_v (pf_fmat) val free = lam ( pf_gmat: GEMAT (a?, m, n, col, m) @ l | p: ptr l ) : void = fmatrix_ptr_free {a?} (pf_gc, pf_mn, fpf_fmat {a?} (pf_gmat) | p) // end of [val] in (pf_gmat | p, free) end // end of [GEMAT_col_ptr_allocfree] (* ****** ****** *) // X <- alpha implement{a} GEMAT_ptr_initialize_elt {ord} {m,n} {ld} (ord, X, m, n, ld, alpha) = let fun loop_row {m,n:nat} {lx:addr} .. ( pf_gmat: !GEMAT_v (a?, m, n, row, ld, lx) >> GEMAT_v (a, m, n, row, ld, lx) | pX: ptr lx, m: size_t m, n: size_t n ) : void = if m > 0 then let val (pfX1_gmat, pfX2_gmat, fpf_gmat | pX1, pX2) = GEMAT_ptr_split2x1 (pf_gmat | ORDERrow, pX, ld, 1) prval (pf2_inc, pfX1_gvec, fpfX1_gmat) = GEVEC_v_of_GEMAT_v_row (pfX1_gmat) prval MATVECINCrowrow () = pf2_inc val () = GEVEC_ptr_initialize_elt (!pX1, n, 1(*incX*), alpha) prval () = pfX1_gmat := fpfX1_gmat (pfX1_gvec) val () = loop_row (pfX2_gmat | pX2, m-1, n) prval () = pf_gmat := fpf_gmat {a} (pfX1_gmat, pfX2_gmat) in // nothing end else let prval () = GEMAT_v_unnil_row (pf_gmat) prval () = pf_gmat := GEMAT_v_nil_row {a} {row} {n} {ld} {lx} () in // nothing end // end of [if] // end of [loop_row] in case+ ord of | ORDERrow () => loop_row (view@ X | &X, m, n) | ORDERcol () => let prval TRANORDcolrow () = GEMAT_v_trans {a?} {col} (view@ X) // end of [prval] val () = loop_row (view@ X | &X, n, m) prval TRANORDrowcol () = GEMAT_v_trans {a} {row} (view@ X) in // nothing end // end of [ORDERcol] end // end of [GEMAT_ptr_initialize_elt] (* ****** ****** *) implement{a} GEMAT_ptr_initialize_fun {ord} {m,n} {ld} (ord, X, m, n, ld, f) = () where { val _(*ptr*) = __cast (X) where { extern castfn __cast (X: &GEMAT (a?, m, n, ord, ld) >> GEMAT (a, m, n, ord, ld)):<> ptr } // end of [val] val () = GEMAT_ptr_iforeach_fun (ord, X, f, ord, m, n, ld) } // end of [GEMAT_ptr_initialize_fun] implement{a} GEMAT_ptr_initialize_vclo {v} {ord} {m,n} {ld} (pf | ord, X, m, n, ld, f) = () where { // typedef clotype0 = (!v | sizeLt m, sizeLt n, &(a?) >> a) - void typedef clotype1 = (!v | sizeLt m, sizeLt n, &a) - void // // a shortcut worth taking? probably. // val _(*ptr*) = __cast (f) where { extern castfn __cast (f: &clotype0 >> clotype1) :<> ptr } val _(*ptr*) = __cast (X) where { extern castfn __cast (X: &GEMAT (a?, m, n, ord, ld) >> GEMAT (a, m, n, ord, ld)):<> ptr } // end of [val] val () = GEMAT_ptr_iforeach_vclo (pf | ord, X, f, ord, m, n, ld) val _(*ptr*) = __cast (f) where { extern castfn __cast (f: &clotype1 >> clotype0) :<> ptr } } // end of [GEMAT_ptr_initialize_vclo] (* ****** ****** *) implement{a} GEMAT_ptr_copy (ord, M1, M2, m, n, ld1, ld2) = GEMAT_ptr_copy_tsz (ord, M1, M2, m, n, ld1, ld2, sizeof) // end of [GEMAT_ptr_copy] implement GEMAT_ptr_copy_tsz {a} {ord} {m,n} {ld1,ld2} (ord, M1, M2, m, n, ld1, ld2, tsz) = let fun loop_row {mi,n:nat} {l1,l2:addr} .. ( pf1: !GEMAT_v (a, mi, n, row, ld1, l1) , pf2: !GEMAT_v (a?, mi, n, row, ld2, l2) >> GEMAT_v (a, mi, n, row, ld2, l2) | p1: ptr l1, p2: ptr l2, mi: size_t mi, n: size_t n ) : void = if mi > 0 then let val (pf11, pf12, fpf1 | p11, p12) = GEMAT_ptr_split2x1_tsz {a} (pf1 | ORDERrow, p1, ld1, 1, tsz) prval (pf1_inc, pf11, fpf11) = GEVEC_v_of_GEMAT_v_row {a} (pf11) prval MATVECINCrowrow () = pf1_inc prval pf11 = array_v_of_GEVEC_v {a} (pf11) val (pf21, pf22, fpf2 | p21, p22) = GEMAT_ptr_split2x1_tsz {a?} (pf2 | ORDERrow, p2, ld2, 1, tsz) prval (pf2_inc, pf21, fpf21) = GEVEC_v_of_GEMAT_v_row {a?} (pf21) prval MATVECINCrowrow () = pf2_inc prval pf21 = array_v_of_GEVEC_v {a?} (pf21) val () = array_ptr_copy_tsz {a} (!p11, !p21, n, tsz) prval pf11 = GEVEC_v_of_array_v {a} (pf11) prval pf11 = fpf11 (pf11) prval pf21 = GEVEC_v_of_array_v {a} (pf21) prval pf21 = fpf21 (pf21) val () = loop_row (pf12, pf22 | p12, p22, mi-1, n) prval () = pf1 := fpf1 {a} (pf11, pf12) prval () = pf2 := fpf2 {a} (pf21, pf22) in // nothing end else let prval () = GEMAT_v_unnil_row (pf2) in pf2 := GEMAT_v_nil_row {a} () end // end of [if] // end of [loop_row] in case+ ord of | ORDERrow () => loop_row (view@ M1, view@ M2 | &M1, &M2, m, n) // end of [ORDERrow] | ORDERcol () => let prval TRANORDcolrow () = GEMAT_v_trans {a} {col} (view@ M1) prval TRANORDcolrow () = GEMAT_v_trans {a?} {col} (view@ M2) val () = loop_row (view@ M1, view@ M2 | &M1, &M2, n, m) prval TRANORDrowcol () = GEMAT_v_trans {a} {row} (view@ M1) prval TRANORDrowcol () = GEMAT_v_trans {a} {row} (view@ M2) in // nothing end // end of [ORDERcol] end // end of [GEMAT_ptr_copy_tsz] (* ****** ****** *) implement GEMAT_ptr_foreach_funenv_tsz {a} {v} {vt} {ord1,ord2} {m,n} {ld} (pf | ord1, M, f, ord2, m, n, ld, tsz, env) = let fun loop_row {n > 0} {mi:nat | mi <= m} {l:addr} .. ( pf: !v , pf_mat: !GEMAT_v (a, mi, n, ord1, ld, l) | p: ptr l , mi: size_t mi , env: !vt ) : void = if mi > 0 then let val (pf1_mat, pf2_mat, fpf | p1, p2) = GEMAT_ptr_split2x1_tsz {a} (pf_mat | ord1, p, ld, 1, tsz) prval (pf1_inc, pf1_vec, fpf1_mat) = GEVEC_v_of_GEMAT_v_row (pf1_mat) val inc = MATVECINC_get (pf1_inc | ORDERrow, ord1, ld) val () = GEVEC_ptr_foreach_funenv_tsz {a} {v} (pf | !p1, f, n, inc, tsz, env) // end of [val] prval () = pf1_mat := fpf1_mat (pf1_vec) val () = loop_row (pf, pf2_mat | p2, mi-1, env) prval () = pf_mat := fpf (pf1_mat, pf2_mat) in // nothing end // end of [if] fun loop_col {m > 0} {ni:nat | ni <= n} {l:addr} .. ( pf: !v , pf_mat: !GEMAT_v (a, m, ni, ord1, ld, l) | p: ptr l , ni: size_t ni , env: !vt ) : void = if ni > 0 then let val (pf1_mat, pf2_mat, fpf | p1, p2) = GEMAT_ptr_split1x2_tsz (pf_mat | ord1, p, ld, 1, tsz) prval (pf1_inc, pf1_vec, fpf1_mat) = GEVEC_v_of_GEMAT_v_col (pf1_mat) val inc = MATVECINC_get (pf1_inc | ORDERcol, ord1, ld) val () = GEVEC_ptr_foreach_funenv_tsz {a} {v} (pf | !p1, f, m, inc, tsz, env) // end of [val] prval () = pf1_mat := fpf1_mat (pf1_vec) val () = loop_col (pf, pf2_mat | p2, ni-1, env) prval () = pf_mat := fpf (pf1_mat, pf2_mat) in // nothing end // end of [if] in case+ ord2 of | ORDERrow () => if n > 0 then let val () = loop_row (pf, view@ M | &M, m, env) in // nothing end else begin // nothing end // end of [ORDERcol] | ORDERcol () => if m > 0 then let val () = loop_col (pf, view@ M | &M, n, env) in // nothing end else begin // nothing end // end of [ORDERcol] end (* end of [GEMAT_ptr_foreach_funenv_tsz] *) (* ****** ****** *) implement{a} GEMAT_ptr_foreach_fun {ord1,ord2} {m,n} (ord1, base, f, ord2, m, n, ld) = let val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void):<> (!unit_v | &a, !ptr) -<> void } // end of [where] prval pfu = unit_v () val () = GEMAT_ptr_foreach_funenv_tsz {a} {unit_v} {ptr} (pfu | ord1, base, f, ord2, m, n, ld, sizeof, null) prval unit_v () = pfu in // nothing end // end of [GEMAT_ptr_foreach_fun] implement{a} GEMAT_ptr_foreach_vclo {v} {ord1,ord2} {m,n} (pf_v | ord1, M, f, ord2, m, n, ld) = let viewtypedef clo_t = (!v | &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | x) in pf := (pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = GEMAT_ptr_foreach_funenv_tsz {a} {V} {ptr l_f} (pf | ord1, M, app, ord2, m, n, ld, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [GEMAT_ptr_foreach_vclo] (* ****** ****** *) implement GEMAT_ptr_iforeach_funenv_tsz {a} {v} {vt} {ord1,ord2} {m,n} {ld} (pf | ord1, M, f, ord2, m, n, ld, tsz, env) = let fun loop_row {n > 0} {mi:nat | mi <= m} {l:addr} .. ( pf: !v , pf_mat: !GEMAT_v (a, mi, n, ord1, ld, l) | p: ptr l , mi: size_t mi , env: !vt ) : void = if mi > 0 then let val (pf1_mat, pf2_mat, fpf | p1, p2) = GEMAT_ptr_split2x1_tsz {a} (pf_mat | ord1, p, ld, 1, tsz) prval (pf1_inc, pf1_vec, fpf1_mat) = GEVEC_v_of_GEMAT_v_row (pf1_mat) val inc = MATVECINC_get (pf1_inc | ORDERrow, ord1, ld) val () = GEVEC_ptr_iforeach_cloenv_tsz {a} {v} (pf | !p1, !p_clo, n, inc, tsz, env) where { val i = m - mi var !p_clo = @lam (pf: !v | j: sizeLt n, x: &a, env: !vt): void = f (pf | i, j, x, env) // end of [var] } // end of [val] prval () = pf1_mat := fpf1_mat (pf1_vec) val () = loop_row (pf, pf2_mat | p2, mi-1, env) prval () = pf_mat := fpf (pf1_mat, pf2_mat) in // nothing end // end of [if] fun loop_col {m > 0} {nj:nat | nj <= n} {l:addr} .. ( pf: !v , pf_mat: !GEMAT_v (a, m, nj, ord1, ld, l) | p: ptr l , nj: size_t nj , env: !vt ) : void = if nj > 0 then let val (pf1_mat, pf2_mat, fpf | p1, p2) = GEMAT_ptr_split1x2_tsz (pf_mat | ord1, p, ld, 1, tsz) prval (pf1_inc, pf1_vec, fpf1_mat) = GEVEC_v_of_GEMAT_v_col (pf1_mat) val inc = MATVECINC_get (pf1_inc | ORDERcol, ord1, ld) val () = GEVEC_ptr_iforeach_cloenv_tsz {a} {v} (pf | !p1, !p_clo, m, inc, tsz, env) where { val j = n-nj var !p_clo = @lam (pf: !v | i: sizeLt m, x: &a, env: !vt): void = f (pf | i, j, x, env) // end of [var] } // end of [val] prval () = pf1_mat := fpf1_mat (pf1_vec) val () = loop_col (pf, pf2_mat | p2, nj-1, env) prval () = pf_mat := fpf (pf1_mat, pf2_mat) in // nothing end // end of [if] in case+ ord2 of | ORDERrow () => if n > 0 then let val () = loop_row (pf, view@ M | &M, m, env) in // nothing end else begin // nothing end // end of [ORDERcol] | ORDERcol () => if m > 0 then let val () = loop_col (pf, view@ M | &M, n, env) in // nothing end else begin // nothing end // end of [ORDERcol] end (* end of [GEMAT_ptr_iforeach_funenv_tsz] *) (* ****** ****** *) implement{a} GEMAT_ptr_iforeach_fun {ord1,ord2} {m,n} (ord1, base, f, ord2, m, n, ld) = let val f = coerce (f) where { extern castfn coerce (f: (sizeLt m, sizeLt n, &a) -<> void) :<> (!unit_v | sizeLt m, sizeLt n, &a, !ptr) -<> void } // end of [where] prval pfu = unit_v () val () = GEMAT_ptr_iforeach_funenv_tsz {a} {unit_v} {ptr} (pfu | ord1, base, f, ord2, m, n, ld, sizeof, null) prval unit_v () = pfu in // nothing end // end of [GEMAT_ptr_iforeach_fun] (* ****** ****** *) implement{a} GEMAT_ptr_iforeach_vclo {v} {ord1,ord2} {m,n} (pf_v | ord1, M, f, ord2, m, n, ld) = let viewtypedef clo_t = (!v | sizeLt m, sizeLt n, &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) fn app ( pf: !V | i: sizeLt m, j: sizeLt n, x: &a, p_f: !ptr l_f ) :<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | i, j, x) in pf := (pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = GEMAT_ptr_iforeach_funenv_tsz {a} {V} {ptr l_f} (pf | ord1, M, app, ord2, m, n, ld, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [GEMAT_ptr_iforeach_vclo] (* ****** ****** *) // // TRiangular MATrix representation (part of GEMAT) // (* ****** ****** *) local fn{a:t@ype} TRMAT_ptr_get_elt_at_dummy {ord:order} {l:addr} ( ord: ORDER ord, p_mat: ptr l, ld: size_t, i: size_t, j: size_t ) :<> a = let val ofs = (case+ ord of | ORDERrow () => (i szmul ld + j) * sizeof | ORDERcol () => (i + j szmul ld) * sizeof ) : size_t val [ofs:int] ofs = sz2sz (ofs) prval (pf, fpf) = __assert () where { extern prfun __assert (): (a @ l+ofs, a @ l+ofs - void) } // end of [prval] val x = !(p_mat + ofs) prval () = fpf (pf) in x end // end of [TRMAT_ptr_get_elt_at_dummy] fn{a:t@ype} TRMAT_ptr_set_elt_at_dummy {ord:order} {l:addr} ( ord: ORDER ord, p_mat: ptr l, ld: size_t, i: size_t, j: size_t, x: a ) :<> void = let val ofs = (case+ ord of | ORDERrow () => (i szmul ld + j) * sizeof | ORDERcol () => (i + j szmul ld) * sizeof ) : size_t val [ofs:int] ofs = sz2sz (ofs) prval (pf, fpf) = __assert () where { extern prfun __assert (): (a @ l+ofs, a @ l+ofs - void) } // end of [prval] val x = !(p_mat + ofs) := x prval () = fpf (pf) in // nothing end // end of [TRMAT_ptr_get_elt_at_dummy] in // in of [local] implement{a} TRMAT_UN_ptr_get_elt_at (ord, A, ld, i, j) = TRMAT_ptr_get_elt_at_dummy (ord, &A, ld, i, j) // end of [TRMAT_UN_ptr_get_elt_at] implement{a} TRMAT_UN_ptr_set_elt_at (ord, A, ld, i, j, x) = TRMAT_ptr_set_elt_at_dummy (ord, &A, ld, i, j, x) // end of [TRMAT_UN_ptr_set_elt_at] implement{a} TRMAT_UU_ptr_get_elt_at (ord, A, ld, i, j) = TRMAT_ptr_get_elt_at_dummy (ord, &A, ld, i, j) // end of [TRMAT_UU_ptr_get_elt_at] implement{a} TRMAT_UU_ptr_set_elt_at (ord, A, ld, i, j, x) = TRMAT_ptr_set_elt_at_dummy (ord, &A, ld, i, j, x) // end of [TRMAT_UU_ptr_set_elt_at] implement{a} TRMAT_LN_ptr_get_elt_at (ord, A, ld, i, j) = TRMAT_ptr_get_elt_at_dummy (ord, &A, ld, i, j) // end of [TRMAT_LN_ptr_get_elt_at] implement{a} TRMAT_LN_ptr_set_elt_at (ord, A, ld, i, j, x) = TRMAT_ptr_set_elt_at_dummy (ord, &A, ld, i, j, x) // end of [TRMAT_LN_ptr_set_elt_at] implement{a} TRMAT_LU_ptr_get_elt_at (ord, A, ld, i, j) = TRMAT_ptr_get_elt_at_dummy (ord, &A, ld, i, j) // end of [TRMAT_LU_ptr_get_elt_at] implement{a} TRMAT_LU_ptr_set_elt_at (ord, A, ld, i, j, x) = TRMAT_ptr_set_elt_at_dummy (ord, &A, ld, i, j, x) // end of [TRMAT_LU_ptr_set_elt_at] end // end of [local] (* ****** ****** *) extern fun TRMAT_U_ptr_split2x2_tsz {a1:viewt@ype} {ord:order} {dg:diag} {m,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: TRMAT_v (a1, m, ord, upper, dg, ld, l0) | ord: ORDER ord, A: ptr l0, ld: size_t ld, i: size_t i, tsz: sizeof_t a1 ) :<> TRMAT_U_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [TRMAT_U_ptr_split2x2_tsz] implement TRMAT_U_ptr_split2x2_tsz {a1} {ord} {dg} {m,i} {ld} {l0} (pf_mat | ord, p_mat, ld, i, tsz) = let val res = (case+ ord of | ORDERrow () => let val i_tmp = sz2sz (i * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((i * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_p | p_mat, p_mat + i_tmp, p_tmp + i_tmp ) end // end of [ORDERrow] | ORDERcol () => let val i_tmp = sz2sz (i * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((i * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_p | p_mat, p_tmp, p_tmp + i_tmp ) end // end of [ORDERcol] ) : (unit_v, unit_v, unit_v, unit_p | ptr, ptr, ptr) extern castfn __cast {vt:viewt@ype} (pf: TRMAT_v (a1, m, ord, upper, dg, ld, l0) | res: vt) :<> TRMAT_U_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [__cast] in __cast (pf_mat | res) end // end of [TRMAT_U_ptr_split2x2_tsz] implement{a1} TRMAT_U_ptr_split2x2 (pf_mat | ord, A, ld, i) = TRMAT_U_ptr_split2x2_tsz (pf_mat | ord, A, ld, i, sizeof) // end of [TRMAT_U_ptr_split2x2] (* ****** ****** *) extern fun TRMAT_L_ptr_split2x2_tsz {a1:viewt@ype} {ord:order} {dg:diag} {m,i:nat | i <= m} {ld:inc} {l0:addr} ( pf_mat: TRMAT_v (a1, m, ord, lower, dg, ld, l0) | ord: ORDER ord, A: ptr l0, ld: size_t ld, i: size_t i, tsz: sizeof_t a1 ) :<> TRMAT_L_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [TRMAT_L_ptr_split2x2_tsz] implement TRMAT_L_ptr_split2x2_tsz {a1} {ord} {dg} {m,i} {ld} {l0} (pf_mat | ord, p_mat, ld, i, tsz) = let val res = (case ord of | ORDERrow () => let val i_tmp = sz2sz (i * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((i * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_p | p_mat, p_tmp, p_tmp + i_tmp ) end // end of [ORDERrow] | ORDERcol () => let val i_tmp = sz2sz (i * tsz) // no-op casting val p_tmp = p_mat + sz2sz ((i * ld) szmul tsz) in @( unit_v, unit_v, unit_v, unit_p | p_mat, p_mat + i_tmp, p_tmp + i_tmp ) end // end of [ORDERcol] ) : (unit_v, unit_v, unit_v, unit_p | ptr, ptr, ptr) extern castfn __cast {vt:viewt@ype} (pf: TRMAT_v (a1, m, ord, lower, dg, ld, l0) | res: vt) :<> TRMAT_L_ptr_split2x2_res_t (a1, m, i, ord, dg, ld, l0) // end of [__cast] in __cast (pf_mat | res) end // end of [TRMAT_L_ptr_split2x2_tsz] implement{a1} TRMAT_L_ptr_split2x2 (pf_mat | ord, A, ld, i) = TRMAT_L_ptr_split2x2_tsz (pf_mat | ord, A, ld, i, sizeof) // end of [TRMAT_L_ptr_split2x2] (* ****** ****** *) implement{a} TRMAT_ptr_copy {ord} {ul} {dg} {m} {ld1,ld2} (ord, ul, dg, M1, M2, m, ld1, ld2) = let fn loop_UN_row ( M1: &TRMAT (a, m, row, upper, nonunit(), ld1), M2: &TRMAT (a, m, row, upper, nonunit(), ld2) ) : void = let val _0 = size1_of_int1 (0) var i: size_t? // uninitialized var j: size_t? // uninitialized in for* {i:nat | i <= m} .. (i: size_t i) => (i := _0; i < m; i := i + 1) ( for* {j:nat | i <= j} .. (i: size_t i, j: size_t j) => (j := i; j < m; j := j + 1) TRMAT_UN_ptr_set_elt_at (ORDERrow, M2, ld2, i, j, TRMAT_UN_ptr_get_elt_at (ORDERrow, M1, ld1, i, j)) // end of [for] ) // end of [for] end fn loop_UU_row ( M1: &TRMAT (a, m, row, upper, unit(), ld1), M2: &TRMAT (a, m, row, upper, unit(), ld2) ) : void = let val _0 = size1_of_int1 (0) var i: size_t? // uninitialized var j: size_t? // uninitialized in for* {i:nat | i <= m} .. (i: size_t i) => (i := _0; i < m; i := i + 1) ( for* {j:nat | i < j} .. (i: size_t i, j: size_t j) => (j := i+1; j < m; j := j + 1) TRMAT_UU_ptr_set_elt_at (ORDERrow, M2, ld2, i, j, TRMAT_UU_ptr_get_elt_at (ORDERrow, M1, ld1, i, j)) // end of [for] ) // end of [for] end fn loop_LN_row ( M1: &TRMAT (a, m, row, lower, nonunit, ld1), M2: &TRMAT (a, m, row, lower, nonunit, ld2) ) : void = let val _0 = size1_of_int1 (0) var i: size_t? // uninitialized var j: size_t? // uninitialized in for* {i:nat | i <= m} .. (i: size_t i) => (i := _0; i < m; i := i+1) ( for* {j:nat | j <= i+1} .. (i: size_t i, j: size_t j) => (j := _0; j <= i; j := j+1) TRMAT_LN_ptr_set_elt_at (ORDERrow, M2, ld2, i, j, TRMAT_LN_ptr_get_elt_at (ORDERrow, M1, ld1, i, j)) // end of [for] ) // end of [for] end fn loop_LU_row ( M1: &TRMAT (a, m, row, lower, unit(), ld1), M2: &TRMAT (a, m, row, lower, unit(), ld2) ) : void = let val _0 = size1_of_int1 (0) var i: size_t? // uninitialized var j: size_t? // uninitialized in for* {i:nat | i <= m} .. (i: size_t i) => (i := _0; i < m; i := i+1) ( for* {j:nat | j <= i} .. (i: size_t i, j: size_t j) => (j := _0; j < i; j := j+1) TRMAT_LU_ptr_set_elt_at (ORDERrow, M2, ld2, i, j, TRMAT_LU_ptr_get_elt_at (ORDERrow, M1, ld1, i, j)) // end of [for] ) // end of [for] end in case+ ord of | ORDERrow () => let prval () = __cast (view@ M2) where { extern prfun __cast {l:addr} (pf: !TRMAT_v (a?, m, ord, ul, dg, ld2, l) >> TRMAT_v (a, m, ord, ul, dg, ld2, l)): void } // end of [prval] in case+ ul of | UPLOupper () => begin case+ dg of | DIAGnonunit () => loop_UN_row (M1, M2) | DIAGunit () => loop_UU_row (M1, M2) end // end of [UPLOupper] | UPLOlower () => begin case+ dg of | DIAGnonunit () => loop_LN_row (M1, M2) | DIAGunit () => loop_LU_row (M1, M2) end // end of [UPLOlower] end // end of [ORDERrow] | ORDERcol () => let prval pf1_order = TRMAT_v_trans (view@ M1) prval TRANORDcolrow () = pf1_order prval pf2_order = TRMAT_v_trans (view@ M2) prval TRANORDcolrow () = pf2_order val ul1 = (case+ ul of | UPLOupper () => UPLOlower () | UPLOlower () => UPLOupper () ) : UPLO (1-ul) val () = TRMAT_ptr_copy (ORDERrow, ul1, dg, M1, M2, m, ld1, ld2) prval pf1_order = TRMAT_v_trans (view@ M1) prval TRANORDrowcol () = pf1_order prval pf2_order = TRMAT_v_trans (view@ M2) prval TRANORDrowcol () = pf2_order in // nothing end // end of [ORDERcol] end // end of [TRMAT_ptr_copy] (* // // this is probably the proper way to implement [TRMAT_ptr_copy] // but it seems too involved; the code is tested and it is kept mostly // as an example for future reference // implement{a} TRMAT_ptr_copy {ord} {ul} {dg} {m} {ld1,ld2} (ord, ul, dg, M1, M2, m, ld1, ld2) = let fun loop_row_upper {mi:nat} {l1,l2:addr} .. ( pf1: !TRMAT_v (a, mi, row, upper, dg, ld1, l1) , pf2: !TRMAT_v (a?, mi, row, upper, dg, ld2, l2) >> TRMAT_v (a, mi, row, upper, dg, ld2, l2) | p1: ptr l1, p2: ptr l2, mi: size_t mi ) : void = if mi > 0 then let val (pf11, pf12, pf13, fpf1 | p11, p12, p13) = TRMAT_U_ptr_split2x2 (pf1 | ORDERrow, p1, ld1, 1) val (pf21, pf22, pf23, fpf2 | p21, p22, p23) = TRMAT_U_ptr_split2x2 (pf2 | ORDERrow, p2, ld2, 1) // stavar l21 : addr val () = (case+ : (pf21 : TRMAT_v (a, 1, row, upper, dg, ld2, l21)) => dg of | DIAGunit () => let prval fpf21 = TRMAT1x1_v_takeout_unit {a?} (pf21) prval () = pf21 := fpf21 {a} () in // unit end // end of [DIAGunit] | DIAGnonunit () => let prval (pf110, fpf11) = TRMAT1x1_v_takeout_nonunit {a} (pf11) prval (pf210, fpf21) = TRMAT1x1_v_takeout_nonunit {a?} (pf21) val () = !p21 := !p11 prval () = pf11 := fpf11 (pf110) prval () = pf21 := fpf21 (pf210) in // nothing end // end of [DIAGnonunit] ) : void // prval (pf12_inc, pf12, fpf12) = GEVEC_v_of_GEMAT_v_row {a} (pf12) prval MATVECINCrowrow () = pf12_inc prval pf12 = array_v_of_GEVEC_v {a} (pf12) prval (pf22_inc, pf22, fpf22) = GEVEC_v_of_GEMAT_v_row {a?} (pf22) prval MATVECINCrowrow () = pf22_inc prval pf22 = array_v_of_GEVEC_v {a?} (pf22) val () = array_ptr_copy_tsz {a} (!p12, !p22, mi-1, sizeof) prval pf12 = GEVEC_v_of_array_v {a} (pf12) prval pf12 = fpf12 {a} (pf12) prval pf22 = GEVEC_v_of_array_v {a} (pf22) prval pf22 = fpf22 {a} (pf22) // val () = loop_row_upper (pf13, pf23 | p13, p23, mi-1) // prval () = pf1 := fpf1 {a} (pf11, pf12, pf13) prval () = pf2 := fpf2 {a} (pf21, pf22, pf23) in // nothing end else let prval () = TRMAT_v_unnil (pf2) in pf2 := TRMAT_v_nil {a} () end // end of [if] // end of [loop_row_upper_nonunit] fun loop_row_lower {mi:nat} {l1,l2:addr} .. ( pf1: !TRMAT_v (a, mi, row, lower, dg, ld1, l1) , pf2: !TRMAT_v (a?, mi, row, lower, dg, ld2, l2) >> TRMAT_v (a, mi, row, lower, dg, ld2, l2) | p1: ptr l1, p2: ptr l2, mi: size_t mi ) : void = if mi > 0 then let val (pf11, pf12, pf13, fpf1 | p11, p12, p13) = TRMAT_L_ptr_split2x2 (pf1 | ORDERrow, p1, ld1, mi-1) val (pf21, pf22, pf23, fpf2 | p21, p22, p23) = TRMAT_L_ptr_split2x2 (pf2 | ORDERrow, p2, ld2, mi-1) // stavar l23 : addr val () = (case+ : (pf23 : TRMAT_v (a, 1, row, lower, dg, ld2, l23)) => dg of | DIAGunit () => let prval fpf23 = TRMAT1x1_v_takeout_unit {a?} (pf23) prval () = pf23 := fpf23 {a} () in // nothing end // end of [DIAGunit] | DIAGnonunit () => let prval (pf130, fpf13) = TRMAT1x1_v_takeout_nonunit {a} (pf13) prval (pf230, fpf23) = TRMAT1x1_v_takeout_nonunit {a?} (pf23) val () = !p23 := !p13 prval () = pf13 := fpf13 (pf130) prval () = pf23 := fpf23 (pf230) in // nothing end // end of [DIAGnonunit] ) : void // prval (pf12_inc, pf12, fpf12) = GEVEC_v_of_GEMAT_v_row {a} (pf12) prval MATVECINCrowrow () = pf12_inc prval pf12 = array_v_of_GEVEC_v {a} (pf12) prval (pf22_inc, pf22, fpf22) = GEVEC_v_of_GEMAT_v_row {a?} (pf22) prval MATVECINCrowrow () = pf22_inc prval pf22 = array_v_of_GEVEC_v {a?} (pf22) val () = array_ptr_copy_tsz {a} (!p12, !p22, mi-1, sizeof) prval pf12 = GEVEC_v_of_array_v {a} (pf12) prval pf12 = fpf12 {a} (pf12) prval pf22 = GEVEC_v_of_array_v {a} (pf22) prval pf22 = fpf22 {a} (pf22) // val () = loop_row_lower (pf11, pf21 | p11, p21, mi-1) // prval () = pf1 := fpf1 {a} (pf11, pf12, pf13) prval () = pf2 := fpf2 {a} (pf21, pf22, pf23) in // nothing end else let prval () = TRMAT_v_unnil (pf2) in pf2 := TRMAT_v_nil {a} () end // end of [if] // end of [loop_row_upper_nonunit] in case+ ord of | ORDERrow () => begin case+ ul of | UPLOupper () => loop_row_upper (view@ M1, view@ M2 | &M1, &M2, m) // end of [UPLOupper] | UPLOlower () => loop_row_lower (view@ M1, view@ M2 | &M1, &M2, m) // end of [UPLOlower] end // end of [ORDERrow] | ORDERcol () => let prval pf1_order = TRMAT_v_trans (view@ M1) prval TRANORDcolrow () = pf1_order prval pf2_order = TRMAT_v_trans (view@ M2) prval TRANORDcolrow () = pf2_order in case+ ul of | UPLOupper () => let val () = loop_row_lower (view@ M1, view@ M2 | &M1, &M2, m) prval pf1_order = TRMAT_v_trans (view@ M1) prval TRANORDrowcol () = pf1_order prval pf2_order = TRMAT_v_trans (view@ M2) prval TRANORDrowcol () = pf2_order in // nothing end // end of [UPLOupper] | UPLOlower () => let val () = loop_row_upper (view@ M1, view@ M2 | &M1, &M2, m) prval pf1_order = TRMAT_v_trans (view@ M1) prval TRANORDrowcol () = pf1_order prval pf2_order = TRMAT_v_trans (view@ M2) prval TRANORDrowcol () = pf2_order in // nothing end end // end of [ORDERcol] end // end of [TRMAT_ptr_copy] *) (* ****** ****** *) (* end of [genarrays.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linset_listord.dats0000664000175000017500000002137612223166162021732 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A linear set implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: February 17, 2012 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "libats/SATS/linset_listord.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) assume set_t0ype_viewtype (elt: t@ype) = List_vt (elt) (* ****** ****** *) implement{} linset_make_nil () = list_vt_nil () implement{a} linset_make_sing (x) = list_vt_sing (x) (* ****** ****** *) implement{a} linset_size (xs) = size_of_int1 (list_vt_length (xs)) (* ****** ****** *) implement{a} linset_is_member (xs, x0, cmp) = let // fun loop {n:nat} .. ( xs: !list_vt (a, n) ) : bool = case+ xs of | list_vt_cons (x, !p_xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let prval () = fold@ {a} (xs) in false end else if sgn > 0 then let val ans = loop (!p_xs) prval () = fold@ {a} (xs) in ans end else let prval () = fold@ {a} (xs) in true // HX: x0 = x end (* end of [if] *) end // end of [list_vt_cons] | list_vt_nil () => (fold@ (xs); false) // end of [loop] in loop (xs) end // end of [linset_is_member] implement{a} linset_isnot_member (xs, x0, cmp) = ~linset_is_member (xs, x0, cmp) // end of [linset_isnot_member] (* ****** ****** *) implement{a} linset_copy (xs) = list_vt_copy (xs) implement{a} linset_free (xs) = list_vt_free (xs) (* ****** ****** *) implement{a} linset_insert (xs, x0, cmp) = let fun ins {n:nat} .. ( // tail-recursive xs: &list_vt (a, n) >> list_vt (a, n1) ) : #[n1:nat | n <= n1; n1 <= n+1] bool = case+ xs of | list_vt_cons (x, !p_xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let prval () = fold@ (xs) val () = xs := list_vt_cons (x0, xs) in false end else if sgn > 0 then let val res = ins (!p_xs); prval () = fold@ (xs) in res end else let // x0 = x prval () = fold@ (xs) in true // [x0] is already in [xs] end // end of [if] end (* end of [list_vt_cons] *) | ~list_vt_nil () => let val () = xs := list_vt_sing (x0) in false end // end of [list_vt_nil] // end of [ins] in ins (xs) end // end of [linset_insert] (* ****** ****** *) implement{a} linset_remove (xs, x0, cmp) = let fun rem {n:nat} .. ( // tail-recursive xs: &list_vt (a, n) >> list_vt (a, n1) ) : #[n1:nat | n1 <= n; n <= n1+1] bool = case+ xs of | list_vt_cons (x, !p_xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let prval () = fold@ (xs) in false end else if sgn > 0 then let val res = rem (!p_xs); prval () = fold@ (xs) in res end else let // x0 = x val xs1 = !p_xs val () = free@ {a}{0} (xs) val () = xs := xs1 in true // [x0] is removed from [xs] end // end of [if] end (* end of [list_vt_cons] *) | list_vt_nil () => let prval () = fold@ (xs) in false end // end of [list_vt_nil] // end of [rem] in rem (xs) end // end of [linset_remove] (* ****** ****** *) (* ** By Brandon Barker *) implement{a} linset_choose (xs, x0) = let in // case+ xs of | list_vt_cons (x, !p_xs) => let prval () = fold@ xs val () = x0 := x prval () = opt_some {a} (x0) in true end // end of [list_vt_cons] | list_vt_nil () => let prval () = fold@ (xs) prval () = opt_none {a} (x0) in false end // end of [list_vt_nil] // end // end of [linset_choose] implement{a} linset_choose_out (xs0, x0) = let in // case+ xs0 of | ~list_vt_cons (x, xs) => let val () = x0 := x prval () = opt_some {a} (x0) val () = xs0 := xs in true end // end of [list_vt_cons] | list_vt_nil () => let prval () = fold@ (xs0) prval () = opt_none {a} (x0) in false end // end of [list_vt_nil] // end // end of [linset_choose_out] (* ****** ****** *) implement{a} linset_union (xs1, xs2, cmp) = let // viewtypedef res = List_vt (a) fun loop {n1,n2:nat} .. ( xs1: list_vt (a, n1), xs2: list_vt (a, n2), res: &res? >> res ) : void = case+ xs1 of | list_vt_cons (x1, !p_xs1) => ( case+ xs2 of | list_vt_cons (x2, !p_xs2) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn < 0 then let val xs11 = !p_xs1 prval () = fold@ {a} (xs2) val () = loop (xs11, xs2, !p_xs1) prval () = fold@ {a} (xs1) in res := xs1 end else if sgn > 0 then let prval () = fold@ {a} (xs1) val xs21 = !p_xs2 val () = loop (xs1, xs21, !p_xs2) prval () = fold@ (xs2) in res := xs2 end else let // x1 = x2 val xs11 = !p_xs1 val xs21 = !p_xs2 val () = free@ {a}{0} (xs2) val () = loop (xs11, xs21, !p_xs1) prval () = fold@ (xs1) in res := xs1 end // end of [if] end // end of [list_vt_cons] | ~list_vt_nil () => (fold@ (xs1); res := xs1) ) // end of [list_vt_cons] | ~list_vt_nil () => (res := xs2) // end of [loop] var res: res // uninitialized val () = loop (xs1, xs2, res) in res end // end of [linset_union] (* ****** ****** *) local // staload UN = "prelude/SATS/unsafe.sats" // in // implement{a} linset_is_subset (xs1, xs2, cmp) = let fun loop {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : bool = case+ xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn < 0 then false else if sgn > 0 then loop (xs1, xs21) else loop (xs11, xs21) end | list_nil () => false ) // end of [list_cons] | list_nil () => true // end of [loop] in loop ( $UN.castvwtp1 {List(a)} (xs1), $UN.castvwtp1 {List(a)} (xs2) ) // end of [loop] end // end of [linset_is_subset] // implement{a} linset_is_equal (xs1, xs2, cmp) = let fun loop {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : bool = ( case+ xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn = 0 then loop (xs11, xs21) else false end // end of [list_cons] | list_nil () => false ) // end of [list_cons] | list_nil () => (case+ xs2 of | list_cons _ => false | list_nil () => true ) // end of [list_nil] ) // end of [loop] in loop ( $UN.castvwtp1 {List(a)} (xs1), $UN.castvwtp1 {List(a)} (xs2) ) // end of [loop] end // end of [linset_is_equal] // end // end of [local] (* ****** ****** *) implement{a} linset_listize (xs) = list_vt_copy (xs) implement{a} linset_listize_free (xs) = xs (* ****** ****** *) (* end of [linset_listord.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linordset_randbst.dats0000664000175000017500000003301212223166162022402 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A ordered set implementation ** based on randomized binary search trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: October, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynloading at run-time (* ****** ****** *) staload "libats/SATS/linordset_randbst.sats" (* ****** ****** *) %{^ ats_void_type atslib_linordset_rngobj_free (ats_ptr_type obj) { ((linordset_rngobj_struct*)obj)->free (obj) ; return ; } // end of [atslib_linordset_rngobj_free] ats_double_type atslib_linordset_rngobj_eval (ats_ptr_type obj) { return ((linordset_rngobj_struct*)obj)->get_double (obj) ; } // end of [atslib_linordset_rngobj_eval] ats_void_type atslib_linordset_rngobj_setseed (ats_ptr_type obj, ats_ulint_type seed) { ((linordset_rngobj_struct*)obj)->setseed (obj, seed) ; return ; } // end of [atslib_linordset_rngobj_setseed] %} // end of [%{^] (* ****** ****** *) extern fun linordset_rngobj_eval // linordset_rngobj_randbst.cats (obj: !rngobj):<> double = "atslib_linordset_rngobj_eval" // end of [linordset_rngobj_eval] (* ****** ****** *) (* ** 0 if r <= m/(m+n); 1 if r > m/(m+n) *) fn{} randchoose_m_n {m,n:nat} ( obj: !rngobj, m: int m, n: int n ) :<> natLt (2) = let val r = linordset_rngobj_eval (obj) in if (m+n) * r <= (double_of)m then 0 else 1 end // end of [randchoose_m_n] (* ****** ****** *) // // HX: a dataviewtype for binary search trees // dataviewtype bstree (a:t@ype+, int(*size*)) = | {nl,nr:nat} BSTcons (a, 1+nl+nr) of (int (1+nl+nr), a, bstree (a, nl), bstree (a, nr)) | BSTnil (a, 0) of () // end of [bstree] (* ****** ****** *) assume set_viewtype (a:t@ype) = [n:nat] bstree (a, n) (* ****** ****** *) fn{a:t@ype} bstree_size {n:nat} ( t: !bstree (a, n) ) :<> int n = case+ t of | BSTcons (n, _, _, _) => (fold@ t; n) | BSTnil _ => (fold@ t; 0) // end of [bstree_size] implement{a} linordset_size (xs) = size_of_int1 (bstree_size (xs)) (* ****** ****** *) fun{a:t@ype} bstree_height {n:nat} .. ( t: !bstree (a, n) ) :<> size_t = case+ t of | BSTcons ( _, _, !p_tl, !p_tr ) => let val nl = bstree_height (!p_tl) and nr = bstree_height (!p_tr) prval () = fold@ (t) in (size_of_int1)1 + (if nl >= nr then nl else nr) end // end of [BSTcons] | BSTnil _ => (fold@ t; (size_of_int1)0) // end of [bstree_height] implement{a} linordset_height (xs) = bstree_height (xs) (* ****** ****** *) implement{} linordset_make_nil () = BSTnil () implement{a} linordset_make_sing (x) = BSTcons (1, x, BSTnil, BSTnil) (* ****** ****** *) fn{a:t@ype} bstree_is_nil {n:nat} (t: !bstree (a, n)):<> bool (n == 0) = case+ t of | BSTcons _ => (fold@ t; false) | BSTnil _ => (fold@ t; true) // end of [bstree_is_nil] fn{a:t@ype} bstree_is_cons {n:nat} (t: !bstree (a, n)):<> bool (n > 0) = case+ t of | BSTcons _ => (fold@ t; true) | BSTnil _ => (fold@ t; false) // end of [bstree_is_cons] implement{} linordset_is_empty {a} (xs) = bstree_is_nil (xs) implement{} linordset_isnot_empty {a} (xs) = bstree_is_cons (xs) (* ****** ****** *) fun{a:t@ype} bstree_free {n:nat} .. (t: bstree (a, n)):<> void = case+ t of | ~BSTcons (_, _, tl, tr) => (bstree_free tl; bstree_free tr) | ~BSTnil () => () // end of [bstree_free] implement{a} linordset_free (xs) = bstree_free (xs) (* ****** ****** *) fun{a:t@ype} bstree_search {n:nat} .. ( t: !bstree (a, n), x0: a, cmp: cmp(a) ) :<> bool = begin case+ t of | BSTcons (_, x, !p_tl, !p_tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val ans = bstree_search (!p_tl, x0, cmp) in fold@ t; ans end else if sgn > 0 then let val ans = bstree_search (!p_tr, x0, cmp) in fold@ t; ans end else ( // sgn = 0 fold@ t; true ) // end of [if] end // end of [BSTcons] | BSTnil () => let prval () = fold@ (t) in false end // end of [BSTnil] end (* end of [bstree_search] *) implement{a} linordset_is_member (xs, x0, cmp) = bstree_search (xs, x0, cmp) // end of [linordset_is_member] implement{a} linordset_isnot_member (xs, x0, cmp) = ~bstree_search (xs, x0, cmp) // end of [linordset_isnot_member] (* ****** ****** *) fun{a:t@ype} bstree_ordsrch {d:nat} {n:nat} .. ( d: int d , t: !bstree (a, n), x0: a, cmp: cmp(a) ) :<> int = begin case+ t of | BSTcons (n, x, !p_tl, !p_tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val ans = bstree_ordsrch (d, !p_tl, x0, cmp) in fold@ t; ans end else if sgn > 0 then let val nr = bstree_size (!p_tr) val ans = bstree_ordsrch (d+n-nr, !p_tr, x0, cmp) in fold@ t; ans end else let // sgn = 0 val nl = bstree_size (!p_tl) in fold@ t; d+nl end // end of [if] end // end of [BSTcons] | BSTnil () => let prval () = fold@ (t) in ~1 (*notfound*) end // end of [BSTnil] end (* end of [bstree_ordsrch] *) implement{a} linordset_get_order (xs, x0, cmp) = bstree_ordsrch (0, xs, x0, cmp) // end of [linordset_get_order] (* implement{a} linordset_is_member (xs, x0, cmp) = linordset_get_order (xs, x0, cmp) >= 0 // end of [linordset_is_member] *) (* ****** ****** *) fun{a:t@ype} bstree_insert_atroot {n:nat} .. ( t: &bstree (a, n) >> bstree (a, n+i) , x0: a, cmp: cmp a ) :<> #[i:two] int (i) = begin case+ t of | BSTcons ( !p_n, x, !p_tl, !p_tr ) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val ans = bstree_insert_atroot (!p_tl, x0, cmp) in if ans > 0 then let val tl_new = !p_tl val+ BSTcons (!p_nl, _(*xl*), !p_tll, !p_tlr) = tl_new val n = !p_n; val nll = bstree_size !p_tll val () = !p_tl := !p_tlr val () = !p_n := n - nll prval () = fold@ (t) val () = !p_tlr := t val () = !p_nl := n + 1 prval () = fold@ (tl_new) val () = t := tl_new in ans end else begin fold@ t; ans // [x0] is alreay in the tree [t] end // end of [if] end else if sgn > 0 then let val ans = bstree_insert_atroot (!p_tr, x0, cmp) in if ans > 0 then let val tr_new = !p_tr val+ BSTcons (!p_nr, _(*xr*), !p_trl, !p_trr) = tr_new val n = !p_n; val nrr = bstree_size !p_trr val () = !p_tr := !p_trl val () = !p_n := n - nrr prval () = fold@ t val () = !p_trl := t val () = !p_nr := n + 1 prval () = fold@ (tr_new) val () = t := tr_new in ans end else begin fold@ t; ans // [x0] is alreay in the tree [t] end // end of [if] end else begin (* sgn = 0 *) fold@ t; 0 // [x0] is the root of [t] end // end of [if] end (* end of [BSTcons] *) | ~BSTnil () => let val () = t := BSTcons (1, x0, BSTnil (), BSTnil ()) in 1(*inserted*) end // end of [BSTnil] end (* end of [bstree_insert_atroot] *) (* ****** ****** *) fun{a:t@ype} bstree_insert_random {n:nat} .. ( obj: !rngobj , t: &bstree (a, n) >> bstree (a, n+i) , x0: a, cmp: cmp a ) :<> #[i:two] int (i) = begin case+ t of | BSTcons (!p_n, x, !p_tl, !p_tr) => if randchoose_m_n (obj, 1, !p_n) = 0 then let prval () = fold@ (t) in bstree_insert_atroot (t, x0, cmp) end else let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val ans = bstree_insert_random (obj, !p_tl, x0, cmp) in if ans > 0 then (!p_n := !p_n + 1; fold@ t; ans) else (fold@ t; ans) end else if sgn > 0 then let val ans = bstree_insert_random (obj, !p_tr, x0, cmp) in if ans > 0 then (!p_n := !p_n + 1; fold@ t; ans) else (fold@ t; ans) end else begin (* sgn = 0 *) fold@ t; 0(* [x0] is the root of [t] *) end // end of [if] end (* end of [BSTcons] *) | ~BSTnil () => let val () = t := BSTcons (1, x0, BSTnil (), BSTnil ()) in 1 end (* end of [BSTnil] *) end (* end of [bstree_insert_random] *) implement{a} linordset_insert (obj, xs, x0, cmp) = let val ans = bstree_insert_random (obj, xs, x0, cmp) in ans > 0 end // end of [linordset_insert] (* ****** ****** *) fun{a:t@ype} bstree_ordget {n,d:nat | d < n} .. ( t: !bstree (a, n), d: int d ) :<> a = let val+ BSTcons (_, x, !p_tl, !p_tr) = t val nl = bstree_size (!p_tl) in if d < nl then let val res = bstree_ordget (!p_tl, d) in fold@ {a} (t); res end else if d > nl then let val res = bstree_ordget (!p_tr, d-nl-1) in fold@ {a} (t); res end else (fold@ {a} (t); x) end (* end of [bstree_ordget] *) implement{a} linordset_ordget (xs, d, x0) = let val n = bstree_size (xs) in if d < n then let val () = x0 := bstree_ordget (xs, d) prval () = opt_some {a} (x0) in true end else let prval () = opt_none {a} (x0) in false end // end of [if] end // end of [linordset_ordget] (* ****** ****** *) fun{a:t@ype} bstree_join_random {nl,nr:nat} .. ( obj: !rngobj , tl: bstree (a, nl) , tr: bstree (a, nr) ) :<> bstree (a, nl+nr) = begin case+ tl of | BSTcons ( !p_nl, _(*xl*), !p_tll, !p_tlr ) => begin case+ tr of | BSTcons ( !p_nr, _(*xr*), !p_trl, !p_trr ) => let val nl = !p_nl and nr = !p_nr val n = nl + nr in if randchoose_m_n (obj, nl, nr) = 0 then let prval () = fold@ tr val () = !p_tlr := bstree_join_random (obj, !p_tlr, tr) val () = !p_nl := n prval () = fold@ (tl) in tl end else let prval () = fold@ tl val () = !p_trl := bstree_join_random (obj, tl, !p_trl) val () = !p_nr := n prval () = fold@ (tr) in tr end // end of [if] end (* end of [BSTcons] *) | ~BSTnil () => (fold@ tl; tl) end (* end of [BSTcons] *) | ~BSTnil () => tr end // end of [bstree_join_random] (* ****** ****** *) fun{a:t@ype} bstree_ordrem {n,d:nat | d < n} .. ( obj: !rngobj , t: &bstree (a, n) >> bstree (a, n-1), d: int d ) :<> a = let val+ BSTcons (!p_n, x, !p_tl, !p_tr) = t val nl = bstree_size (!p_tl) in if d < nl then let val res = bstree_ordrem (obj, !p_tl, d) val () = !p_n := !p_n - 1 prval () = fold@ {a} (t) in res end else if d > nl then let val res = bstree_ordrem (obj, !p_tr, d-nl-1) val () = !p_n := !p_n - 1 prval () = fold@ {a} (t) in res end else let val t_new = bstree_join_random (obj, !p_tl, !p_tr) val () = free@ {a} {0,0} (t) val () = t := t_new in x (* removed *) end // end of [if] end (* end of [bstree_ordrem] *) implement{a} linordset_ordrem (obj, xs, d, x0) = let val n = bstree_size (xs) in if d < n then let val () = x0 := bstree_ordrem (obj, xs, d) prval () = opt_some {a} (x0) in true end else let prval () = opt_none {a} (x0) in false end (* end of [if] *) end // end of [linordset_ordrem] (* ****** ****** *) fun{a:t@ype} bstree_remove_random {n:nat} .. ( obj: !rngobj , t: &bstree (a, n) >> bstree (a, n-i) , x0: a, cmp: cmp a ) :<> #[i:two | i <= n] int (i) = begin case+ t of | BSTcons {..} {nl,nr} (!p_n, x, !p_tl, !p_tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val ans = bstree_remove_random (obj, !p_tl, x0, cmp) val () = !p_n := !p_n - ans prval () = fold@ (t) in ans end else if sgn > 0 then let val ans = bstree_remove_random (obj, !p_tr, x0, cmp) val () = !p_n := !p_n - ans prval () = fold@ (t) in ans end else let val t_new = bstree_join_random (obj, !p_tl, !p_tr) val () = free@ {a} {0,0} (t) val () = t := t_new in 1 (* removed *) end // end of [0] end (* end of [BSTcons] *) | BSTnil () => (fold@ t; 0) end // end of [bstree_remove_random] implement{a} linordset_remove (obj, xs, x0, cmp) = let val ans = bstree_remove_random (obj, xs, x0, cmp) in ans > 0 end // end of [linordset_remove] (* ****** ****** *) (* end of [linordset_randbst.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/rarray.dats0000664000175000017500000001406212223166162020166 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Reversed Arrays (arrays running from right to left) ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for run-time dynloading (* ****** ****** *) staload "libats/SATS/rarray.sats" (* ****** ****** *) implement rarray_v_unnil (pfarr) = let prval rarray_v_nil () = pfarr in (* nothing *) end // end of [rarray_v_unnil] implement rarray_v_uncons (pfarr) = let prval rarray_v_cons (pf1arr, pf1at) = pfarr in (pf1arr, pf1at) end // end of [rarray_v_uncons] (* ****** ****** *) implement rarray_v_of_array_v {a} (pfmul, pfarr) = aux (pfmul, pfarr) where { prfun aux {n:nat} {l:addr} {ofs:int} .. ( pfmul: MUL (n, sizeof a, ofs), pfarr: array_v (a, n, l) ) : rarray_v (a, n, l+ofs) = sif n > 0 then let prval (pf1arr, pf1at) = array_v_unextend {a} (pfmul, pfarr) prval pf1mul = mul_add_const {~1} (pfmul) prval pf1arr = aux (pf1mul, pf1arr) in rarray_v_cons {a} (pf1arr, pf1at) end else let prval () = array_v_unnil (pfarr) in rarray_v_nil () end // end of [aux] // end of [aux] } // end of [rarray_v_of_array_v] (* ****** ****** *) implement array_v_of_rarray_v {a} (pfmul, pfarr) = aux (pfmul, pfarr) where { prfun aux {n:nat} {l:addr} {ofs:int} .. ( pfmul: MUL (n, sizeof a, ofs), pfarr: rarray_v (a, n, l) ) : array_v (a, n, l-ofs) = sif n > 0 then let prval rarray_v_cons (pf1arr, pf1at) = pfarr prval pf1mul = mul_add_const {~1} (pfmul) prval pf1arr = aux (pf1mul, pf1arr) in array_v_extend {a} (pf1mul, pf1arr, pf1at) end else let prval rarray_v_nil () = pfarr in array_v_nil {a} () end // end of [if] // end of [aux] } // end of [array_v_of_rarray_v] (* ****** ****** *) implement{a} array2rarray_ptr (pfarr | p, n) = let val (pfmul | ofs) = mul2_size1_size1 (n, sizeof) prval pfarr = rarray_v_of_array_v {a} (pfmul, pfarr) in (pfmul, pfarr | p+ofs) end // end of [array2rarray_ptr] implement{a} rarray2array_ptr (pfarr | p, n) = let val (pfmul | ofs) = mul2_size1_size1 (n, sizeof) prval pfarr = array_v_of_rarray_v {a} (pfmul, pfarr) in (pfmul, pfarr | p-ofs) end // end of [rarray2array_ptr] (* ****** ****** *) implement rarray_ptr_foreach_funenv_tsz {a} {v} {vt} {n} (pf, pfarr | p, f, asz, tsz, env) = let fun loop {i:nat | i <= n} {l:addr} .. ( pf: !v, pfarr: !rarray_v (a, i, l) | p: ptr l , f: (!v | &a, !vt) -<> void, i: size_t i, tsz: sizeof_t a , env: !vt ) :<> void = if i > 0 then let prval (pf1arr, pf1at) = rarray_v_uncons {a} (pfarr) val p1 = p-tsz val () = f (pf | !p1, env) val () = loop (pf, pf1arr | p1, f, i-1, tsz, env) prval () = pfarr := rarray_v_cons {a} (pf1arr, pf1at) in // nothing end else let prval () = rarray_v_unnil (pfarr) prval () = pfarr := rarray_v_nil {a} () in // nothing end // end of [if] in loop (pf, pfarr | p, f, asz, tsz, env) end // end of [rarray_ptr_foreach_funenv_tsz] (* ****** ****** *) implement{a} rarray_ptr_foreach_fun {v} {n} (pfarr | p, f, asz) = let viewtypedef fun0_t = (&a) - void viewtypedef fun1_t = (!unit_v | &a, !ptr) - void val f = __cast (f) where { extern castfn __cast (f: fun0_t):<> fun1_t } // prval pfu = unit_v () val () = rarray_ptr_foreach_funenv_tsz {a} {unit_v} {ptr} (pfu, pfarr | p, f, asz, sizeof, null) prval unit_v () = pfu // in // nothing end // end of [rarray_ptr_foreach_fun] (* ****** ****** *) implement{a} rarray_ptr_foreach_vclo {v} {n} (pfv, pfarr | p, f, asz) = let viewtypedef clo_t = (!v | &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | x) in pf := (pf1, pf2) end // end of [app] prval pf = (pfv, view@ f) val () = rarray_ptr_foreach_funenv_tsz {a} {V} {ptr l_f} (pf, pfarr | p, app, asz, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pfv := pf1; view@ f := pf2) in // empty end // end of [rarray_ptr_foreach_vclo] (* ****** ****** *) implement{a} array_ptr_rforeach_vclo (pf | A, f, n) = let prval pfarr = view@ (A) val (pfmul | ofs) = mul2_size1_size1 (n, sizeof) prval pfarr = rarray_v_of_array_v {a} (pfmul, pfarr) val () = rarray_ptr_foreach_vclo (pf, pfarr | &A+ofs, f, n) prval () = view@(A) := array_v_of_rarray_v {a} (pfmul, pfarr) in // nothing end // end of [array_ptr_rforeach_vclo] (* ****** ****** *) (* end of [rarray.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/lockptr_spin.dats0000664000175000017500000000340412223166162021373 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libats/SATS/lockptr_spin.sats" (* ****** ****** *) %{^ ats_void_type atslib_lockptr_destroy (ats_ptr_type lock) { atslib_pthread_spin_destroy((pthread_spinlock_t*)lock) ; ATS_FREE(lock) ; return ; } // end of [atslib_lockptr_destroy] %} // end of [%{^] (* ****** ****** *) (* end of [lockptr_spin.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linmap_avltree.dats0000664000175000017500000005335612223166162021701 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/linmap_avltree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) // // HX-2010-03-24: this seems to work best! // #define HTDF 1 // max height difference #define HTDF1 %(HTDF+1) #define HTDF_1 %(HTDF-1) (* ****** ****** *) dataviewtype avltree ( key:t@ype, itm:viewt@ype+, int(*height*) ) = | {hl,hr:nat | hl <= hr+HTDF; hr <= hl+HTDF} B (key, itm, 1+max(hl,hr)) of (int (1+max(hl,hr)), key, itm, avltree (key, itm, hl), avltree (key, itm, hr)) | E (key, itm, 0) // end of [datatype avltree] typedef avltree0 = avltree (void, void, 0)? viewtypedef avltree_inc (key:t@ype, itm:viewt@ype, h:int) = [h1:nat | h <= h1; h1 <= h+1] avltree (key, itm, h1) // end of [avltree_inc] viewtypedef avltree_dec (key:t@ype, itm:viewt@ype, h:int) = [h1:nat | h1 <= h; h <= h1+1] avltree (key, itm, h1) // end of [avltree_dec] (* ****** ****** *) assume map_viewtype (key:t@ype, itm:viewt@ype) = [h:nat] avltree (key, itm, h) // end of [map_viewtype] (* ****** ****** *) implement{} linmap_make_nil () = E () (* ****** ****** *) implement{} linmap_is_nil (t) = case+ t of | B _ => (fold@ t; false) | E () => (fold@ t; true) // end of [linmap_is_nil] implement{} linmap_isnot_nil (t) = case+ t of | B _ => (fold@ t; true) | E () => (fold@ t; false) // end of [linmap_isnot_nil] (* ****** ****** *) implement{key,itm} linmap_size (t) = size (t) where { fun size {h:nat} .. (t: !avltree (key, itm, h)):<> size_t = begin case+ t of | B (_(*h*), _(*key*), _(*itm*), !ptl, !ptr) => let val sz = (size_of_int1)1 + size (!ptl) + size (!ptr) in (fold@ t; sz) end // end of [B] | E () => (fold@ t; size_of_int1(0)) end // end of [size] } // end of [linmap_size] (* ****** ****** *) fn{key:t0p;itm:vt0p} avltree_height {h:nat} (t: !avltree (key, itm, h)):<> int h = case+ t of B (h, _, _, _, _) => (fold@ t; h) | E _ => (fold@ t; 0) // end of [avltree_height] implement{key,itm} linmap_height (t) = avltree_height (t) (* ****** ****** *) implement {key,itm} linmap_search (t, k0, cmp, res) = let val [l:addr] p = linmap_search_ref (t, k0, cmp) in if p > null then let prval (fpf, pf) = __assert () where { extern praxi __assert (): (itm @ l - void, itm @ l) } // end of [prval] val () = res := !p prval () = fpf (pf) prval () = opt_some {itm} (res) in true end else let prval () = opt_none {itm} (res) in false end // end of [if] end // end of [linmap_search] implement {key,itm} linmap_search_ref (t, k0, cmp) = search (t) where { fun search {h:nat} .. ( t: !avltree (key, itm, h) ) : Ptr = begin case+ t of | B ( _(*h*), k, !p_x, !ptl, !ptr ) => let val sgn = compare_key_key (k0, k, cmp) in case+ 0 of | _ when sgn < 0 => let val res = search (!ptl) in fold@ t; res end // end of [sgn < 0] | _ when sgn > 0 => let val res = search (!ptr) in fold@ t; res end // end of [sgn > 0] | _ => (fold@ t; p_x) end // end of [B] | E () => (fold@ (t); null) end // end of [search] } // end of [linmap_search_ref] (* ****** ****** *) implement {key,itm} linmap_search_opt (t, k0, cmp) = let var res: itm? val ans = linmap_search (t, k0, cmp, res) in if ans then let prval () = opt_unsome {itm} (res) in Some_vt (res) end else let prval () = opt_unnone {itm} (res) in None_vt (*void*) end // end of [if] end // end of [linmap_search_opt] (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} avltree_lrotate {hl,hr:nat | hl+HTDF1 == hr} {l_h,l_k,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h , pf_k: key @ l_k, pf_x: itm @ l_x , pf_tl: avltree (key, itm, hl) @ l_tl , pf_tr: avltree (key, itm, hr) @ l_tr | p_h: ptr l_h , hl : int hl , p_tl: ptr l_tl , hr : int hr , p_tr: ptr l_tr , t: B_unfold (l_h, l_k, l_x, l_tl, l_tr) ) :<> avltree_inc (key, itm, hr) = let val tr = !p_tr val+ B {..} {hrl,hrr} (!p_hr, _, _, !p_trl, !p_trr) = tr val hrl = avltree_height (!p_trl) and hrr = avltree_height (!p_trr) in if hrl <= hrr+HTDF_1 then let val hrl1 = hrl + 1 val () = !p_h := hrl1 // () = !p_tl := tl val () = !p_tr := !p_trl prval () = fold@ (t) val () = !p_hr := 1+max(hrl1,hrr) val () = !p_trl := t // val () = !p_trr := trr prval () = fold@ (tr) in tr // B (1+max(hrl1,hrr), kr, xr, B (hrl1, k, x, tl, trl), trr) end else let // [hrl=hrr+2]: deep rotation val trl = !p_trl val+ B {..} {hrll,hrlr} (!p_hrl, _, _, !p_trll, !p_trlr) = trl val hrll = avltree_height (!p_trll) val hrlr = avltree_height (!p_trlr) val () = !p_h := 1+max(hl,hrll) // val () = !p_tl := tl val () = !p_tr := !p_trll prval () = fold@ t val () = !p_hr := 1+max(hrlr, hrr) val () = !p_trl := !p_trlr // val () = !p_trr := trr prval () = fold@ tr val () = !p_hrl := hr val () = !p_trll := t val () = !p_trlr := tr prval () = fold@ (trl) in trl // B (hr, krl, xrl, B (1+max(hl,hrll), k, x, tl, trll), B (1+max(hrlr,hrr), kr, xr, trlr, trr)) end // end of [if] end // end of [avltree_lrotate] (* ** right rotation for restoring height invariant *) fn{key:t0p;itm:vt0p} avltree_rrotate {hl,hr:nat | hl == hr+HTDF1} {l_h,l_k,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h , pf_k: key @ l_k, pf_x: itm @ l_x , pf_tl: avltree (key, itm, hl) @ l_tl , pf_tr: avltree (key, itm, hr) @ l_tr | p_h: ptr l_h , hl : int hl , p_tl: ptr l_tl , hr : int hr , p_tr: ptr l_tr , t: B_unfold (l_h, l_k, l_x, l_tl, l_tr) ) :<> avltree_inc (key, itm, hl) = let val tl = !p_tl val+ B {..} {hll, hlr} (!p_hl, _, _, !p_tll, !p_tlr) = tl val hll = avltree_height (!p_tll) and hlr = avltree_height (!p_tlr) in if hll+HTDF_1 >= hlr then let val hlr1 = hlr + 1 val () = !p_h := hlr1 val () = !p_tl := !p_tlr // () = !p_tr := tr prval () = fold@ (t) val () = !p_hl := 1+max(hll,hlr1) // val () = !p_tll := tll val () = !p_tlr := t prval () = fold@ (tl) in tl // B (1+max(hll,hlr1), kl, xl, tll, B (hlr1, k, x, tlr, tr)) end else let val tlr = !p_tlr val+ B {..} {hlrl,hlrr} (!p_hlr, _, _, !p_tlrl, !p_tlrr) = tlr val hlrl = avltree_height (!p_tlrl) val hlrr = avltree_height (!p_tlrr) val () = !p_h := 1+max(hlrr,hr) val () = !p_tl := !p_tlrr // val () = !p_tr := tr prval () = fold@ t val () = !p_hl := 1+max(hll,hlrl) // val () = !p_tll := tll val () = !p_tlr := !p_tlrl prval () = fold@ tl val () = !p_hlr := hl val () = !p_tlrl := tl val () = !p_tlrr := t prval () = fold@ (tlr) in tlr // B (hl, klr, xlr, B (1+max(hll,hlrl), kl, xl, tll, tlrl), B (1+max(hlrr,hr), k, x, tlrr, tr)) end // end of [if] end // end of [avltree_rrotate] (* ****** ****** *) implement{key,itm} linmap_insert (m, k0, x0, cmp, res) = let // fun insert {h:nat} .. ( t: &avltree (key, itm, h) >> avltree_inc (key, itm, h) , x0: itm, res: &itm? >> opt (itm, b) ) : #[b:bool] bool b = begin case+ t of | B {..} {hl,hr} (!p_h, !p_k, !p_x, !p_tl, !p_tr) => let prval pf_h = view@ !p_h prval pf_k = view@ !p_k prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr val sgn = compare_key_key (k0, !p_k, cmp) in if sgn < 0 then let val ans = insert (!p_tl, x0, res) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hl - hr <= HTDF then let val () = !p_h := 1+max(hl,hr) prval () = fold@ (t) in ans // B (1+max(hl,hr), k, x, tl, tr) end else let // hl = hr+HTDF1 val () = t := avltree_rrotate (pf_h, pf_k, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) in ans end // end of [if] end else if sgn > 0 then let val ans = insert (!p_tr, x0, res) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let val () = !p_h := 1+max(hl, hr) prval () = fold@ (t) in ans // B (1+max(hl, hr), k, x, tl, tr) end else let // hl+HTDF1 = hr val () = t := avltree_lrotate (pf_h, pf_k, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) in ans end // end of [if] end else let (* key already exists *) val () = res := !p_x prval () = opt_some {itm} (res) val () = !p_x := x0 prval () = fold@ t in true // B (h, k, x0, tl, tr) end // end of [if] end // end of [B] | ~E () => let val () = t := B (1, k0, x0, E (), E ()) // a new node is created prval () = opt_none {itm} (res) in false end // end of [E] end // end of [insert] // in // insert (m, x0, res) // end // end of [linmap_insert] (* ****** ****** *) viewtypedef B_node (key:t@ype, itm:viewt@ype) = B_pstruct (int?, key, itm, avltree0, avltree0) // end of [B_node] extern castfn B_node_make {key:t@ype;itm:viewt@ype} {l_h,l_k,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h, pf_k: key @ l_k, pf_x: itm @ l_x, pf_tl: avltree? @ l_tl, pf_tr: avltree? @ l_tr | x: B_unfold (l_h, l_k, l_x, l_tl, l_tr)) :<> B_node (key, itm) // end of [B_node_make] fun{key:t0p;itm:vt0p} avltree_takeout_min {h:pos} .. ( t: &avltree (key, itm, h) >> avltree_dec (key, itm, h) ) :<> B_node (key, itm) = let val+ B {..} {hl,hr} (!p_h, !p_k, !p_x, !p_tl, !p_tr) = t prval pf_h = view@ !p_h prval pf_k = view@ !p_k prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr in case+ !p_tl of | B _ => let prval () = fold@ (!p_tl) val node = avltree_takeout_min (!p_tl) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let val () = !p_h := 1+max(hl,hr) prval () = fold@ t // B (1+max(hl,hr), k, x, tl, tr) in node end else let val () = t := avltree_lrotate (pf_h, pf_k, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in node end // end of [if] end // end of [B] | ~E () => let val tr = !p_tr; val t0 = t; val () = t := tr in B_node_make {key,itm} (pf_h, pf_k, pf_x, pf_tl, pf_tr | t0) end // end of [E] end // end of [avltree_takeout_min] (* ****** ****** *) // // HX-2010-03-25: unsafe but convenient to implement // extern fun{key:t0p;itm:vt0p} linmap_takeout_ptr {l_res:addr} ( m: &map (key, itm), k0: key, cmp: cmp key, res: ptr l_res ) :<> bool // end of [linmap_takeout_ptr] implement {key,itm} linmap_takeout_ptr {l_res} (m, k0, cmp, p_res) = takeout (m, p_res) where { fun takeout {h:nat} .. ( t: &avltree (key, itm, h) >> avltree_dec (key, itm, h) , p_res: ptr l_res ) : bool = begin case+ t of | B {..} {hl,hr} (!p_h, !p_k, !p_x, !p_tl, !p_tr) => let stavar l_x:addr val p_x = p_x : ptr l_x prval pf_h = view@ !p_h prval pf_k = view@ !p_k prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr val sgn = compare_key_key (k0, !p_k, cmp) in case+ 0 of | _ when sgn < 0 => let val ans(*removed*) = takeout (!p_tl, p_res) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let prval () = !p_h := 1+max(hl,hr) in fold@ (t); ans end else let // hl+HTDF1 = hr val () = t := avltree_lrotate (pf_h, pf_k, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in ans end // end of [if] end // end of [sgn < 0] | _ when sgn > 0 => let val ans = takeout (!p_tr, p_res) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hl - hr <= HTDF then let prval () = !p_h := 1+max(hl,hr) in fold@ (t); ans end else let // hl=hr+HTDF1 val () = t := avltree_rrotate (pf_h, pf_k, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in ans end // end of [if] end // end of [sgn > 0] | _ (*sgn = 0*) => let val () = if :(pf_x: itm? @ l_x) => (p_res > null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := !p_x prval () = fpf (pf) in // nothing end else let extern praxi __assert (pf: !itm @ l_x >> itm? @ l_x): void prval () = __assert (pf_x) // leak happens if [itm] contains resources! in // nothing end // end of [val] var tl = !p_tl and tr = !p_tr val () = free@ {key,itm} {0,0} (t) in case+ tr of | B _ => let prval () = fold@ tr val t1 = avltree_takeout_min (tr) val B (!p1_h, !p1_k, !p1_x, !p1_tl, !p1_tr) = t1 prval pf1_h = view@ !p1_h prval pf1_k = view@ !p1_k prval pf1_x = view@ !p1_x prval pf1_tl = view@ !p1_tl prval pf1_tr = view@ !p1_tr val hl = avltree_height (tl) and hr = avltree_height (tr) val () = !p1_tl := tl and () = !p1_tr := tr in if hl - hr <= HTDF then let val () = !p1_h := 1+max(hl,hr) in fold@ t1; t := t1; true end else let val () = t := avltree_rrotate (pf1_h, pf1_k, pf1_x, pf1_tl, pf1_tr | p1_h, hl, p1_tl, hr, p1_tr, t1) in true end // end of [if] end // end of [B] | E _ => (t := tl; true) end // end of [sgn = 0] end // end of [B] | E () => (fold@ t; false(*~removed*)) end // end of [takeout] } // end of [linmap_takeout_ptr] (* ****** ****** *) implement {key,itm} linmap_takeout (m, k0, cmp, res) = ans where { val ans = linmap_takeout_ptr (m, k0, cmp, &res) val [b:bool] ans = bool1_of_bool (ans) prval pf = __assert (view@ res) where { extern praxi __assert {l_res:addr} (pf: itm? @ l_res):<> opt (itm, b) @ l_res } // end of [prval] prval () = view@ res := pf } // end of [linmap_takeout] implement{key,itm} linmap_remove (m, k0, cmp) = linmap_takeout_ptr (m, k0, cmp, null) (* ****** ****** *) (* fun{key,itm:t@ype} linmap_foreach_funenv {v:view} {vt:viewtype} (pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt):<> void // end of [linmap_foreach_funenv] *) implement{key,itm} linmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf | m, env) where { fun foreach {h:nat} .. (pf: !v | t: !avltree (key, itm, h), env: !vt): void = case+ t of | B (_(*h*), !p_k, !p_x, !p_tl, !p_tr) => begin foreach (pf | !p_tl, env); f (pf | !p_k, !p_x, env); foreach (pf | !p_tr, env); fold@ (t) end // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linmap_foreach_funenv] (* ****** ****** *) implement{key,itm} linmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, &itm) - void):<> (!unit_v | key, &itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [linmap_foreach_fun] (* ****** ****** *) implement{key,itm} linmap_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {h:nat} .. ( pf: !v | t: !avltree (key, itm, h), f: &(!v | key, &itm) - void ) :<> void = case+ t of | B (_(*h*), !p_k, !p_x, !p_tl, !p_tr) => begin foreach (pf | !p_tl, f); f (pf | !p_k, !p_x); foreach (pf | !p_tr, f); fold@ (t) end // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linmap_foreach_vclo] (* ****** ****** *) implement{key,itm} linmap_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, &itm) - void):<> (!unit_v | key, &itm) - void } // end of [val] typedef clo_type = (!unit_v | key, &itm) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pf0 = unit_v () val () = $effmask_ref (linmap_foreach_vclo {unit_v} (pf0 | m, !p_f)) prval unit_v () = pf0 in // empty end // end of [linmap_foreach_cloref] (* ****** ****** *) (* fun{key,itm:t@ype} linmap_rforeach_funenv {v:view} {vt:viewtype} (pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt):<> void // end of [linmap_rforeach_funenv] *) implement{key,itm} linmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf | m, env) where { fun rforeach {h:nat} .. (pf: !v | t: !avltree (key, itm, h), env: !vt): void = case+ t of | B (_(*h*), !p_k, !p_x, !p_tl, !p_tr) => begin rforeach (pf | !p_tr, env); f (pf | !p_k, !p_x, env); rforeach (pf | !p_tl, env); fold@ (t) end // end of [B] | E () => fold@ (t) // end of [rforeach] } // end of [linmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} linmap_clear_funenv {v} {vt} ( pfv | m, f, env ) = let typedef FT1 = (!v | key, &itm >> itm?, !vt) - void typedef FT2 = (!v | key, &itm >> itm , !vt) - void val () = let extern castfn __cast (f: FT1):<> FT2 in linmap_foreach_funenv (pfv | m, __cast(f), env) end // end of [val] prval () = __assert (m) where { extern praxi __assert (m: !map (key, itm) >> map (key, itm?)): void } // end of [val] in // nothing end // end of [linmap_clear_funenv] (* ****** ****** *) implement{key,itm} linmap_free (m) = _free (m) where { fun _free {h:nat} .. (t: avltree (key, itm, h)):<> void = case+ t of | ~B (_, _, _, tl, tr) => (_free tl; _free tr) | ~E () => () // end of [_free] } // end of [linmap_free] implement{key,itm} linmap_free_vt (m) = let viewtypedef VT = map (key, itm) in case+ m of | B _ => true where { prval () = fold@ (m); prval () = opt_some {VT} (m) } // end of [B] | E () => false where { prval () = opt_none {VT} (m) } // end of [E] end // end of [linmap_free_vt] (* ****** ****** *) // // HX: it can also be implemented based on [foreach] // implement{key,itm} linmap_listize (m) = let viewtypedef res_t = List_vt @(key, itm) fun aux {h:nat} .. ( t: !avltree (key, itm, h), res: res_t ) :<> res_t = case+ t of | B (_(*h*), k, x, !p_tl, !p_tr) => let val res = aux (!p_tr, res) val res = list_vt_cons ((k, x), res) val res = aux (!p_tl, res) prval () = fold@ (t) in res end // end of [B] | E () => (fold@ (t); res) // end of [aux] in aux (m, list_vt_nil) end // end of [linmap_listize] (* ****** ****** *) implement{key,itm} linmap_listize_free (m) = let viewtypedef res_t = List_vt @(key, itm) fun aux {h:nat} .. (t: avltree (key, itm, h), res: res_t):<> res_t = case+ t of | ~B (_(*h*), k, x, tl, tr) => let val res = aux (tr, res) val res = list_vt_cons ((k, x), res) val res = aux (tl, res) in res end // end of [B] | ~E () => res // end of [E] // end of [aux] in aux (m, list_vt_nil) end // end of [linmap_listize_free] (* ****** ****** *) (* end of [linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linmap_rbtree.dats0000664000175000017500000006577212223166162021527 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/linmap_rbtree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) #define BLK 0; #define RED 1 sortdef clr = {c:nat | c <= 1} typedef color (c:int) = int c typedef color = [c:clr] color c sortdef t0p = t@ype sortdef vt0p = viewt@ype (* ****** ****** *) dataviewtype rbtree ( key:t@ype, itm: viewt@ype , int(*color*), int(*blackheight*), int(*violation*) ) = | E (key, itm, BLK, 0, 0) | {c,cl,cr:clr} {bh:nat} {v:int} {c == BLK && v == 0 || c == RED && v == cl+cr} T (key, itm, c, bh+1-c, v) of ( color c, key, itm, rbtree0 (key, itm, cl, bh), rbtree0 (key, itm, cr, bh) ) // end of [T] // rbtree0: for trees of no violations where rbtree0 (key:t@ype, itm:viewt@ype, c:int, bh:int) = rbtree (key, itm, c, bh, 0(*vio*)) // end of [rbtree0] (* ****** ****** *) prfn rbtree_get_color {key:t0p;itm:vt0p} {c:clr} {bh:int} {v:int} (t: !rbtree (key, itm, c, bh, v)):<> int (c) = case+ t of | T (c, _, _, _, _) => (fold@ (t); c) | E () => (fold@ (t); BLK) // end of [rbtree_get_color] (* ****** ****** *) assume map_viewtype (key:t0p, itm:vt0p) = [c:clr;bh:nat] rbtree0 (key, itm, c, bh) // end of [map_viewtype] (* ****** ****** *) implement{} linmap_make_nil () = E () (* ****** ****** *) implement{} linmap_is_nil (t) = case+ t of | T _ => (fold@ t; false) | E () => (fold@ t; true) // end of [linmap_is_nil] implement{} linmap_isnot_nil (t) = case+ t of | T _ => (fold@ t; true) | E () => (fold@ t; false) // end of [linmap_isnot_nil] (* ****** ****** *) implement{key,itm} linmap_size (t) = sz (t) where { fun sz {c:clr} {bh:nat} {v:nat} .. (t: !rbtree (key, itm, c, bh, v)):<> size_t = case+ t of | T (_(*c*), _(*key*), _(*itm*), !ptl, !ptr) => let val sz = (size_of_int1)1 + sz (!ptl) + sz (!ptr) in (fold@ t; sz) end // end of [B] | E () => (fold@ t; size_of_int1(0)) // end of [sz] } // end of [linmap_size] (* ****** ****** *) implement{key,itm} linmap_height (t) = ht (t) where { fun ht {c:clr} {bh:nat} {v:nat} .. (t: !rbtree (key, itm, c, bh, v)):<> Nat = case+ t of | T (_(*c*), _(*key*), _(*itm*), !ptl, !ptr) => let val ht = 1 + max (ht (!ptl), ht (!ptr)) in (fold@ t; ht) end // end of [B] | E () => (fold@ t; 0) // end of [ht] } // end of [linmap_height] (* ****** ****** *) implement {key,itm} linmap_search (t, k0, cmp, res) = let val [l:addr] p = linmap_search_ref (t, k0, cmp) in if p > null then let prval (fpf, pf) = __assert () where { extern praxi __assert (): (itm @ l - void, itm @ l) } // end of [prval] val () = res := !p prval () = fpf (pf) prval () = opt_some {itm} (res) in true end else let prval () = opt_none {itm} (res) in false end // end of [if] end // end of [linmap_search] implement {key,itm} linmap_search_ref (t, k0, cmp) = search (t) where { fun search {c:clr} {bh:nat} .. ( t: !rbtree0 (key, itm, c, bh) ) : Ptr = begin case+ t of | T ( _(*c*), k, !p_x, !ptl, !ptr ) => let val sgn = compare_key_key (k0, k, cmp) in case+ 0 of | _ when sgn < 0 => let val res = search (!ptl) in fold@ t; res end // end of [sgn < 0] | _ when sgn > 0 => let val res = search (!ptr) in fold@ t; res end // end of [sgn > 0] | _ => (fold@ (t); p_x) end // end of [B] | E () => (fold@ (t); null) end // end of [search] } // end of [linmap_search_ref] (* ****** ****** *) fn{key:t0p;itm:vt0p} insfix_l // right rotation {cl,cr:clr} {bh:nat} {v:nat} {l_c,l_k,l_x,l_tl,l_tr:addr} ( pf_c: int(BLK) @ l_c , pf_k: key @ l_k , pf_x: itm @ l_x , pf_tl: rbtree (key, itm, cl, bh, v) @ l_tl , pf_tr: rbtree (key, itm, cr, bh, 0) @ l_tr | t: T_unfold (l_c, l_k, l_x, l_tl, l_tr) , p_tl: ptr (l_tl) ) :<> [c:clr] rbtree0 (key, itm, c, bh+1) = let #define B BLK; #define R RED in case+ !p_tl of | T (!p_cl as R, _, _, !p_tll as T (!p_cll as R, _, _, _, _), !p_tlr) => let // val () = !p_cll := B val () = fold@ (!p_tll) // val tl = !p_tl val () = !p_tl := !p_tlr val () = fold@ (t) // val () = !p_tlr := t in fold@ (tl); tl end // end of [T (R, T (R, ...), ...)] | T (!p_cl as R, _, _, !p_tll, !p_tlr as T (!p_clr as R, _, _, !p_tlrl, !p_tlrr)) => let // val tl = !p_tl val () = !p_tl := !p_tlrr val () = fold@ (t) val () = !p_tlrr := t // val tlr = !p_tlr val () = !p_tlr := !p_tlrl val () = !p_cl := B val () = fold@ (tl) val () = !p_tlrl := tl // in fold@ (tlr); tlr end // end of [T (R, ..., T (R, ...))] | _ =>> (fold@ (t); t) end // end of [insfix_l] fn{key:t0p;itm:vt0p} insfix_r // left rotation {cl,cr:clr} {bh:nat} {v:nat} {l_c,l_k,l_x,l_tl,l_tr:addr} ( pf_c: int(BLK) @ l_c , pf_k: key @ l_k , pf_x: itm @ l_x , pf_tl: rbtree (key, itm, cl, bh, 0) @ l_tl , pf_tr: rbtree (key, itm, cr, bh, v) @ l_tr | t: T_unfold (l_c, l_k, l_x, l_tl, l_tr) , p_tr: ptr (l_tr) ) :<> [c:clr] rbtree0 (key, itm, c, bh+1) = let #define B BLK; #define R RED in case+ !p_tr of | T (!p_cr as R, _, _, !p_trl, !p_trr as T (!p_crr as R, _, _, _, _)) => let // val () = !p_crr := B val () = fold@ (!p_trr) // val tr = !p_tr val () = !p_tr := !p_trl val () = fold@ (t) // val () = !p_trl := t in fold@ (tr); tr end // end of [T (R, ..., T (R, ...))] | T (!p_cr as R, _, _, !p_trl as T (!p_crr as R, _, _, !p_trll, !p_trlr), !p_trr) => let // val tr = !p_tr val () = !p_tr := !p_trll val () = fold@ (t) val () = !p_trll := t // val trl = !p_trl val () = !p_trl := !p_trlr val () = !p_cr := B val () = fold@ (tr) val () = !p_trlr := tr // in fold@ (trl); trl end // end of [T (R, T (R, ...), ...)] | _ =>> (fold@ (t); t) end // end of [insfix_r] (* ****** ****** *) implement{key,itm} linmap_insert (m, k0, x0, cmp, res) = let // #define B BLK; #define R RED // fun ins {c:clr} {bh:nat} .. ( t: &rbtree0 (key, itm, c, bh) >> rbtree (key, itm, cl, bh, v) , x0: itm, res: &itm? >> opt (itm, b) ) : #[b: bool; cl:clr; v:nat | v <= c] bool (b) = case+ t of | T ( !p_c, !p_k, !p_x, !p_tl, !p_tr ) => let val sgn = compare_key_key (k0, !p_k, cmp) in if sgn < 0 then let val b = ins (!p_tl, x0, res) stavar cl: int prval cl: int (cl) = rbtree_get_color (!p_tl) in if !p_c = B then let val () = t := insfix_l (view@(!p_c), view@(!p_k), view@(!p_x), view@(!p_tl), view@(!p_tr) | t, p_tl) // end of [val] in b end else let val () = !p_c := R in fold@ {..}{..}{..}{cl} (t); b end // end of [if] end else if sgn > 0 then let val b = ins (!p_tr, x0, res) stavar cr: int prval cr: int (cr) = rbtree_get_color (!p_tr) in if !p_c = B then let val () = t := insfix_r (view@(!p_c), view@(!p_k), view@(!p_x), view@(!p_tl), view@ (!p_tr) | t, p_tr) // end of [val] in b end else let val () = !p_c := R in fold@ {..}{..}{..}{cr} (t); b end // end of [if] end else let val () = res := !p_x prval () = opt_some {itm} (res) val () = !p_x := x0 val () = fold@ {..}{..}{..}{0} (t) in true end (* end of [if] *) end // end of [cons] | ~E () => let prval () = opt_none {itm} (res) val () = t := T {..}{..}{..}{0} (R, k0, x0, E, E) in false end // end of [E] // end of [ins] val b = ins (m, x0, res) // in // case+ m of | T (!p_c as R, _, _, _, _) => (!p_c := B; fold@ (m); b) | _ =>> b // end // end of [linmap_insert] (* ****** ****** *) fn{key:t0p;itm:vt0p} rbtree_clr_trans_blk_red {bh:pos} (t: rbtree (key, itm, BLK, bh, 0)) :<> [v:nat] rbtree (key, itm, RED, bh-1, v) = let val+ T {..}{c,cl,cr} (!p_c, _, _, _, _) = t in !p_c := RED; fold@ {..}{..}{..}{cl+cr} (t); t end // end of [rbtree_clr_trans_blk_red] (* ****** ****** *) fn{key:t0p;itm:vt0p} remfix_l {cl,cr:clr} {bh:nat} {v:nat} {l_c,l_k,l_x,l_tl,l_tr:addr} ( pf_c: int(BLK) @ l_c , pf_k: key @ l_k , pf_x: itm @ l_x , pf_tl: rbtree (key, itm, cl, bh, v) @ l_tl , pf_tr: rbtree (key, itm, cr, bh+1, 0) @ l_tr | t: T_unfold (l_c, l_k, l_x, l_tl, l_tr) , p_c: ptr (l_c) , p_tl: ptr (l_tl) , p_tr: ptr (l_tr) ) :<> [c:clr;v:nat | v <= cr] rbtree (key, itm, c, bh+1, v) = let #define B BLK; #define R RED in case+ !p_tl of | T (!p_cl as R, _, _, _, _) => ( !p_cl := B; fold@ (!p_tl); !p_c := R; fold@ {..}{..}{..}{cr} (t); t ) // end of [T (R, ...)] | _ =>> let in case+ !p_tr of | T {..} {cr,crl,crr} (!p_cr as B, _, _, _, _) => let val () = !p_cr := R; val () = fold@ {..}{..}{..}{crl+crr} (!p_tr) in insfix_r (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_tr) end // end of [T (B, ...)] | T (!p_cr as R, !p_kr, !p_xr, !p_trl, !p_trr) => let val trl = !p_trl val+ T (!p_crl, !p_krl, !p_xrl, !p_trll, !p_trlr) = trl // val tr = !p_tr val () = !p_tr := !p_trll val () = fold@ (t) val () = !p_trll := t // val () = !p_trl := !p_trlr val () = !p_trr := rbtree_clr_trans_blk_red (!p_trr) // val () = !p_cr := B val [c_new:int] t_new = insfix_r ( view@(!p_cr), view@(!p_kr), view@(!p_xr), view@(!p_trl), view@(!p_trr) | tr, p_trr ) // end of [val] val () = !p_trlr := t_new // in !p_crl := R; fold@ {..}{..}{..}{c_new} (trl); trl end // end of [T (R, ...)] end // end of [_] end // end of [remfix_l] fn{key:t0p;itm:vt0p} remfix_r {cl,cr:clr} {bh:nat} {v:nat} {l_c,l_k,l_x,l_tl,l_tr:addr} ( pf_c: int(BLK) @ l_c , pf_k: key @ l_k , pf_x: itm @ l_x , pf_tl: rbtree (key, itm, cl, bh+1, 0) @ l_tl , pf_tr: rbtree (key, itm, cr, bh, v) @ l_tr | t: T_unfold (l_c, l_k, l_x, l_tl, l_tr) , p_c: ptr (l_c) , p_tl: ptr (l_tl) , p_tr: ptr (l_tr) ) :<> [c:clr;v:nat | v <= cl] rbtree (key, itm, c, bh+1, v) = let #define B BLK; #define R RED in case+ !p_tr of | T (!p_cr as R, _, _, _, _) => ( !p_cr := B; fold@ (!p_tr); !p_c := R; fold@ {..}{..}{..}{cl} (t); t ) // end of [T (R, ...)] | _ =>> let in case+ !p_tl of | T {..} {cl,cll,clr} (!p_cl as B, _, _, _, _) => let val () = !p_cl := R; val () = fold@ {..}{..}{..}{cll+clr} (!p_tl) in insfix_l (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_tl) end // end of [T (B, ...)] | T (!p_cl as R, !p_kl, !p_xl, !p_tll, !p_tlr) => let val tlr = !p_tlr val+ T (!p_clr, !p_klr, !p_xlr, !p_tlrl, !p_tlrr) = tlr // val tl = !p_tl val () = !p_tl := !p_tlrr val () = fold@ (t) val () = !p_tlrr := t // val () = !p_tll := rbtree_clr_trans_blk_red (!p_tll) val () = !p_tlr := !p_tlrl // val () = !p_cl := B val [c_new:int] t_new = insfix_l ( view@(!p_cl), view@(!p_kl), view@(!p_xl), view@(!p_tll), view@(!p_tlr) | tl, p_tll ) // end of [val] val () = !p_tlrl := t_new // in !p_clr := R; fold@ {..}{..}{..}{c_new} (tlr); tlr end // end of [T (R, ...)] end // end of [_] end // end of [remfix_r] (* ****** ****** *) typedef rbtree0 = rbtree (void, void, 0, 0, 0)? viewtypedef T_node (key:t@ype, itm:viewt@ype) = T_pstruct (int?, key, itm, rbtree0, rbtree0) // end of [T_node] extern castfn T_node_make {key:t0p;itm:vt0p} {l_c,l_k,l_x,l_tl,l_tr:addr} ( pf_c: int? @ l_c, pf_k: key @ l_k, pf_x: itm @ l_x, pf_tl: rbtree? @ l_tl, pf_tr: rbtree? @ l_tr | x: T_unfold (l_c, l_k, l_x, l_tl, l_tr) ) :<> T_node (key, itm) // end of [T_node_make] fun{key:t0p;itm:vt0p} rbtree_remove_min {c:clr} {bh:nat | bh+c > 0} .. ( t: &rbtree0 (key, itm, c, bh) >> rbtree (key, itm, c1, bh-bhdf, 0) , bhdf: &int? >> int (bhdf) ) :<> #[ bhdf:two; c1:clr | bhdf <= bh; c1 <= c+bhdf ] T_node (key, itm) = let #define B BLK; #define R RED val+ T {..} {c,cl,cr} (!p_c, !p_k, !p_x, !p_tl, !p_tr) = t prval pf_c = view@ !p_c prval pf_k = view@ !p_k prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr in case+ !p_c of | B => (case+ !p_tl of | T _ => let val () = fold@ {..}{..}{..}{0} (!p_tl) val node = rbtree_remove_min (!p_tl, bhdf) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in node end else let val () = t := remfix_l ( pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_c, p_tl, p_tr ) // end of [val] in case+ t of | T (!p_c as R, _, _, _, _) => ( bhdf := 0; !p_c := B; fold@ {..}{..}{..}{0} (t); node ) // end of [T] | _ =>> node end (* end of [if] *) end // end of [T] | ~E () => let val () = bhdf := 1 val tr = !p_tr; val t0 = t; val () = t := tr in T_node_make {key,itm} (pf_c, pf_k, pf_x, pf_tl, pf_tr | t0) end // end of [E] ) // end of [T (B, ...)] | R => begin case+ !p_tl of | T _ => let val () = fold@ {..}{..}{..}{0} (!p_tl) val node = rbtree_remove_min (!p_tl, bhdf) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in node end else let // bhdf = 1 val () = bhdf := 0 val () = !p_tr := rbtree_clr_trans_blk_red (!p_tr) val () = !p_c := B val () = t := insfix_r (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_tr) in node end (* end of [if] *) end // end of [T (B, ...)] | ~E () => let val () = bhdf := 0 val tr = !p_tr; val t0 = t; val () = t := tr in T_node_make {key,itm} (pf_c, pf_k, pf_x, pf_tl, pf_tr | t0) end // end of [E] end (* end of [T (R, ...)] *) end // end of [rbtree_remove_min] (* ****** ****** *) fn{key:t0p;itm:vt0p} rbtree_join {cl,cr:clr} {bh:nat} ( tl: rbtree0 (key, itm, cl, bh) , tr: rbtree0 (key, itm, cr, bh) ) :<> [c:clr;v:nat | v <= cl+cr] rbtree (key, itm, c, bh, v) = case+ tr of | T _ => let val () = fold@ {..}{..}{..}{0} (tr) var tr = tr var bhdf: int val node = rbtree_remove_min (tr, bhdf) stavar cr: int prval cr: int (cr) = rbtree_get_color (tr) val+ T (!p_c, !p_k, !p_x, !p_tl, !p_tr) = node in if bhdf = 0 then let val () = !p_c := RED val () = !p_tl := tl val () = !p_tr := tr in fold@ {..}{..}{..}{cl+cr} (node); node end else let val () = !p_c := BLK val () = !p_tl := tl val () = !p_tr := tr in remfix_r ( view@ (!p_c), view@ (!p_k), view@ (!p_x), view@ (!p_tl), view@ (!p_tr) | node, p_c, p_tl, p_tr ) // end of [remfix_r] end (* end of [if] *) end // end of [T] | ~E () => tl // end of [rbtree_join] (* ****** ****** *) // // HX: unsafe but convenient to implement // extern fun{key:t0p;itm:vt0p} linmap_takeout_ptr {l_res:addr} ( m: &map (key, itm), k0: key, cmp: cmp key, res: ptr l_res ) :<> bool // end of [linmap_takeout] implement{key,itm} linmap_takeout_ptr {l_res} (m, k0, cmp, p_res) = let // #define B BLK; #define R RED // fun takeout {c:clr} {bh:nat} .. ( t: &rbtree0 (key, itm, c, bh) >> rbtree0 (key, itm, c1, bh-bhdf) , bhdf: &int? >> int bhdf , p_res: ptr l_res ) : #[bhdf:two; c1:clr | bhdf <= bh; c1 <= c+bhdf] bool = // case+ t of | T _ => let val () = fold@ {..}{..}{..}{0} (t) val+ T (!p_c, !p_k, !p_x, !p_tl, !p_tr) = t stavar l_x: addr val p_x = p_x : ptr l_x prval pf_c = view@ !p_c prval pf_k = view@ !p_k prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr val sgn = compare_key_key (k0, !p_k, cmp) in case+ !p_c of | B => if sgn < 0 then let val bval = takeout (!p_tl, bhdf, p_res) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in bval end else let // bhdf = 1 val () = t := remfix_l (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_c, p_tl, p_tr) // end of [val] in case+ t of | T (!p_c as R, _, _, _, _) => ( bhdf := 0; !p_c := B; fold@ (t); bval ) // end of [T] | _ =>> bval end // end of [if] end else if sgn > 0 then let val bval = takeout (!p_tr, bhdf, p_res) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in bval end else let // bhdf = 1 val () = t := remfix_r (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_c, p_tl, p_tr) // end of [val] in case+ t of | T (!p_c as R, _, _, _, _) => ( bhdf := 0; !p_c := B; fold@ (t); bval ) // end of [T] | _ =>> bval end // end of [if] end else let // x0 = x val () = if :(pf_x: itm? @ l_x) => (p_res > null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := !p_x prval () = fpf (pf) in // nothing end else let extern praxi __assert (pf: !itm @ l_x >> itm? @ l_x): void prval () = __assert (pf_x) // leak happens if [itm] contains resources! in // nothing end // end of [val] val tl = !p_tl and tr = !p_tr val () = free@ {key,itm}{0,0,0}{0}{0} (t) val bval = true val () = t := rbtree_join (tl, tr) in case+ t of | T (!p_c as R, _, _, _, _) => ( bhdf := 0; !p_c := B; fold@ (t); bval ) // end of [T] | _ =>> (bhdf := 1; bval) end (* end of [if] *) // end of [B] | R => if sgn < 0 then let val bval = takeout (!p_tl, bhdf, p_res) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in bval end else let // bhdf = 1 val () = bhdf := 0 val () = !p_c := BLK val () = t := remfix_l (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_c, p_tl, p_tr) // end of [val] in bval end // end of [if] end else if sgn > 0 then let val bval = takeout (!p_tr, bhdf, p_res) in if bhdf = 0 then let val () = fold@ {..}{..}{..}{0} (t) in bval end else let // bhdf = 1 val () = bhdf := 0 val () = !p_c := BLK val () = t := remfix_r (pf_c, pf_k, pf_x, pf_tl, pf_tr | t, p_c, p_tl, p_tr) // end of [val] in bval end // end of [if] end else let // x0 = x val () = bhdf := 0 val () = if :(pf_x: itm? @ l_x) => (p_res > null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := !p_x prval () = fpf (pf) in // nothing end else let extern praxi __assert (pf: !itm @ l_x >> itm? @ l_x): void prval () = __assert (pf_x) // leak happens if [itm] contains resources! in // nothing end // end of [val] val tl = !p_tl and tr = !p_tr val () = free@ {key,itm}{0,0,0}{0}{0} (t) val bval = true val () = t := rbtree_join (tl, tr) in true end (* end of [if] *) // end of [R] end // end of [T] | E () => (bhdf := 0; fold@ (t); false) // end of [takeout] // var bhdf: int // uninitialized // in // takeout (m, bhdf, p_res) // end // end of [linmap_takeout_ptr] (* ****** ****** *) implement{key,itm} linmap_takeout (m, k0, cmp, res) = ans where { val ans = linmap_takeout_ptr (m, k0, cmp, &res) val [b:bool] ans = bool1_of_bool (ans) prval pf = __assert (view@ res) where { extern praxi __assert {l_res:addr} (pf: itm? @ l_res):<> opt (itm, b) @ l_res // end of [__assert] } // end of [prval] prval () = view@ res := pf } // end of [linmap_takeout] implement{key,itm} linmap_remove (m, k0, cmp) = linmap_takeout_ptr (m, k0, cmp, null) (* ****** ****** *) (* fun{key,itm:t@ype} linmap_foreach_funenv {v:view} {vt:viewtype} (pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt):<> void // end of [linmap_foreach_funenv] *) implement{key,itm} linmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf | m, env) where { fun foreach {c:clr} {bh:nat} .. (pf: !v | t: !rbtree0 (key, itm, c, bh), env: !vt): void = case+ t of | T (_(*c*), !p_k, !p_x, !p_tl, !p_tr) => ( foreach (pf | !p_tl, env); f (pf | !p_k, !p_x, env); foreach (pf | !p_tr, env); fold@ (t) ) // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linmap_foreach_funenv] (* ****** ****** *) implement{key,itm} linmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, &itm) - void):<> (!unit_v | key, &itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [linmap_foreach_fun] (* ****** ****** *) implement{key,itm} linmap_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {c:clr} {bh:nat} .. ( pf: !v | t: !rbtree0 (key, itm, c, bh), f: &(!v | key, &itm) - void ) :<> void = case+ t of | T (_(*c*), !p_k, !p_x, !p_tl, !p_tr) => begin foreach (pf | !p_tl, f); f (pf | !p_k, !p_x); foreach (pf | !p_tr, f); fold@ (t) end // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linmap_foreach_vclo] (* ****** ****** *) implement{key,itm} linmap_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, &itm) - void):<> (!unit_v | key, &itm) - void } // end of [val] typedef clo_type = (!unit_v | key, &itm) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pf0 = unit_v () val () = $effmask_ref (linmap_foreach_vclo {unit_v} (pf0 | m, !p_f)) prval unit_v () = pf0 in // empty end // end of [linmap_foreach_cloref] (* ****** ****** *) (* fun{key,itm:t@ype} linmap_rforeach_funenv {v:view} {vt:viewtype} (pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt):<> void // end of [linmap_rforeach_funenv] *) implement{key,itm} linmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf | m, env) where { fun rforeach {c:clr} {bh:nat} .. (pf: !v | t: !rbtree0 (key, itm, c, bh), env: !vt): void = case+ t of | T (_(*c*), !p_k, !p_x, !p_tl, !p_tr) => ( rforeach (pf | !p_tr, env); f (pf | !p_k, !p_x, env); rforeach (pf | !p_tl, env); fold@ (t) ) // end of [B] | E () => fold@ (t) // end of [rforeach] } // end of [linmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} linmap_clear_funenv {v} {vt} ( pfv | m, f, env ) = let typedef FT1 = (!v | key, &itm >> itm?, !vt) - void typedef FT2 = (!v | key, &itm >> itm , !vt) - void val () = let extern castfn __cast (f: FT1):<> FT2 in linmap_foreach_funenv (pfv | m, __cast(f), env) end // end of [val] prval () = __assert (m) where { extern praxi __assert (m: !map (key, itm) >> map (key, itm?)): void } // end of [val] in // nothing end // end of [linmap_clear_funenv] (* ****** ****** *) implement{key,itm} linmap_free (m) = _free (m) where { fun _free {c:clr} {bh:nat} .. (t: rbtree0 (key, itm, c, bh)):<> void = case+ t of | ~T (_, _, _, tl, tr) => (_free tl; _free tr) | ~E () => () // end of [_free] } // end of [linmap_free] implement {key,itm} linmap_free_vt (m) = let viewtypedef VT = map (key, itm) in case+ m of | T _ => true where { prval () = fold@ (m); prval () = opt_some {VT} (m) } // end of [B] | E () => false where { prval () = opt_none {VT} (m) } // end of [E] end // end of [linmap_free] (* ****** ****** *) // // HX: it can also be implemented based on [foreach] // implement{key,itm} linmap_listize (m) = let viewtypedef res_t = List_vt @(key, itm) fun aux {c:clr} {bh:nat} .. ( t: !rbtree0 (key, itm, c, bh), res: res_t ) :<> res_t = case+ t of | T (c, k, x, !p_tl, !p_tr) => let val res = aux (!p_tr, res) val res = list_vt_cons ((k, x), res) val res = aux (!p_tl, res) prval () = fold@ (t) in res end // end of [B] | E () => (fold@ (t); res) // end of [aux] in aux (m, list_vt_nil ()) end // end of [linmap_listize] (* ****** ****** *) implement{key,itm} linmap_listize_free (m) = let viewtypedef res_t = List_vt @(key, itm) fun aux {c:clr} {bh:nat} .. ( t: rbtree0 (key, itm, c, bh), res: res_t ) :<> res_t = case+ t of | ~T (c, k, x, tl, tr) => let val res = aux (tr, res) val res = list_vt_cons ((k, x), res) val res = aux (tl, res) in res end // end of [B] | ~E () => res // end of [aux] in aux (m, list_vt_nil ()) end // end of [linmap_listize_free] (* ****** ****** *) (* end of [linmap_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/regexp.dats0000664000175000017500000002232612223166162020162 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // some basic IO operations (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list_vt.dats" (* ****** ****** *) staload "libats/SATS/regexp.sats" (* ****** ****** *) #define i2sz size1_of_int1 #define sz2i int1_of_size1 (* ****** ****** *) %{^ ats_ptr_type atslib_regexp_compile (ats_ptr_type pattern) { const char *errptr ; int erroffset ; pcre *rc ; rc = pcre_compile ( (char*)pattern , 0 /* option bits */ , &errptr, &erroffset , (unsigned char*)0 /* tableptr */ ) ; // end of [pcre_compile] return rc ; } /* end of [atslib_regexp_compile] */ %} // end of [%{^] implement regexp_compile_exn (pattern) = let val re0 = regexp_compile (pattern) val p_re0 = ptr_of (re0) in if (p_re0 <> null) then re0 else let val () = prerrf ( "exit(ATS): [pcre_comiple] failed: pattern = %s\n", @(pattern) ) // end of [val] prval () = regexp_free_null (re0) in exit(1) end // end of [if] end // end of [regexp_compile_exn] (* ****** ****** *) implement regexp_match_string (re, str) = let val str = string1_of_string (str) val len = string_length (str); val len = sz2i (len) in regexp_match_substring (re, str, 0(*ofs*), len) end // end of [regexp_match_string] (* ****** ****** *) %{$ ats_bool_type atslib_regexp_match_substring ( ats_ptr_type re, ats_ptr_type str, ats_int_type ofs, ats_int_type len ) { int rc ; // rc = pcre_exec ( (pcre*)re , (pcre_extra*)0 /* [re] is not studied */ , ((char*)str)+ofs, len, 0 // strlenofs , 0 /* option bits */ , (int*)0 /* ovector */ , 0 /* ovecsize */ ) ; // end of [pcre_exec] // if (rc >= 0) return ats_true_bool ; // switch (rc) { case PCRE_ERROR_NOMATCH: return ats_false_bool ; default: fprintf (stderr, "exit(ATS): [regexp_match_substring] failed\n"); exit (1); } /* end of [switch] */ // return ats_false_bool ; /* deadcode */ // } /* end of [atslib_regexp_match_substring] */ %} // end of [%{$] (* ****** ****** *) implement regexp_match_string_strposlst (re, str) = let val len = string_length (str); val len = sz2i (len) in regexp_match_substring_strposlst (re, str, 0(*ofs*), len) end // end of [regexp_match_string_strpostlst] (* ****** ****** *) local extern fun strposlst_make_arrptr {n:nat} (A: &(@[int][n+n]), n: int n): List_vt @(int, int) = "atslib_strposlst_make_arrptr" // end of [strposlst_make_arrptr] in // in of [local] implement strposlst_make_arrptr {n} (A, n) = let typedef int2 = (int, int) stavar l:addr val p = (&A): ptr l // viewdef V1 = array_v (int, n+n, l) and V2 = array_v (int2, n, l) // prval () = __assert (view@ (A)) where { extern prfun __assert (pf: !V1 >> V2): void } // end of [prval] val xs = list_vt_make_array (A, size1_of_int1 (n)) prval () = __assert (view@ (A)) where { extern prfun __assert (pf: !V2 >> V1): void } // end of [prval] // in xs end // end of [strposlst_make_arrptr] end // end of [local] (* ****** ****** *) %{$ ats_ptr_type atslib_regexp_match_substring_strposlst ( ats_ptr_type re, ats_ptr_type str, ats_int_type ofs, ats_int_type len ) { int rc ; int ncapture ; int ovecsize, *ovector ; int err ; // ats_ptr_type res ; // err = pcre_fullinfo ( (pcre*)re, (pcre_extra*)0, PCRE_INFO_CAPTURECOUNT, &ncapture ) ; // end of [pcre_fullinfo] // ovecsize = 3 * (ncapture + 1) ; ovector = ATS_MALLOC (ovecsize * sizeof(int)) ; // rc = pcre_exec ( (pcre*)re , (pcre_extra*)0 /* [re] is not studied */ , ((char*)str)+ofs, len, 0 // strlenofs , 0 /* option bits */ , ovector , ovecsize ) ; // end of [pcre_exec] // if (rc >= 0) { res = atslib_strposlst_make_arrptr (ovector, rc) ; } else { res = (ats_ptr_type)0 ; } // end of [if] // ATS_FREE (ovector) ; // if (rc >= 0) return res ; // switch (rc) { // [rc] is negative case PCRE_ERROR_NOMATCH: return res ; default: fprintf ( stderr, "exit(ATS): [regexp_match_substring_strposlst] failed\n" ) ; exit (1) ; } // end of [switch] // return res ; /* deadcode */ // } /* end of [atslib_regexp_match_substring_strposlst] */ %} // end of [%{$] (* ****** ****** *) %{^ ATSinline() ats_int_type atslib_regexp_split_substring_search ( ats_ptr_type re , ats_ptr_type str , ats_int_type ofs , ats_int_type len , ats_ptr_type ofsvec ) { int rc ; rc = pcre_exec ( (pcre*)re , (pcre_extra*)0 /* [re] is not study */ , ((char*)str)+ofs, len, 0 // strlenofs , 0 /* option bits */ , (int*)ofsvec /* ovector */ , 3 /* ovecsize */ ) ; // end of [pcre_exec] return rc ; } /* end of [atslib_regexp_split_substring_search] */ %} // end of [%{^] (* ****** ****** *) implement regexp_split_string_list (re, str) = let // val str = string1_of_string (str) val len = string1_length (str) val len = int1_of_size1 (len) in regexp_split_substring_list (re, str, 0, len) end // end of [regexp_split_string_list] implement regexp_split_substring_list {l0} {n} (re, str, ofs, len) = let // extern fun search {i,ln:nat | i + ln <= n} {l:addr} ( pf_arr: ! @[int?][3] @ l >> @[int][3] @ l | re: !REGEXPptr l0, str: string n, ofs: int i, len: int ln, l: ptr l ) : int = "atslib_regexp_split_substring_search" // viewtypedef res = List_vt (strptr1) // fun loop {i,ln:nat | i+ln <= n} {l:addr} ( pf_arr: !(@[int?][3] @ l) | re: !REGEXPptr l0 , str: string n, ofs: int i, len: int ln, p: ptr l, res: &res? >> res ) : void = case+ 0 of | _ when (len > 0) => let val rc = search (pf_arr | re, str, ofs, len, p) in case+ rc of | _ when rc >= 0 => let val [i1:int] i1 = int1_of p->[0] and [i2:int] i2 = int1_of p->[1] prval () = __assert () where { extern prfun __assert (): [0 <= i1; i1 <= i2; i2 <= ln] void } // end of [prval] (* val () = if (i1 = i2) then let val () = prerr ( "exit(ATS): [regexp_split_substring_list]: nullable separator" ) // end of [val] val () = prerr_newline () in exit (1) end // end of [val] *) val sbp = string_make_substring (str, (i2sz)ofs, (i2sz)i1) val s = strptr_of_strbuf (sbp) // no-op cast val () = res := list_vt_cons {strptr1} {0} (s, ?) val+ list_vt_cons (_, !p_res) = res val () = loop (pf_arr | re, str, ofs+i2, len-i2, p, !p_res) prval () = fold@ (res) in // nothing end // end of [_ when rc >= 0] | _ => let val sbp = string_make_substring (str, (i2sz)ofs, (i2sz)len) val s = strptr_of_strbuf (sbp) // no-op cast val () = res := list_vt_cons {strptr1} {0} (s, ?) val+ list_vt_cons (_, !p_res) = res val () = loop (pf_arr | re, str, ofs+len, 0, p, !p_res) prval () = fold@ (res) in // nothing end // end of [_] end // end of [_ when (i < n)] | _ (* i = n *) => (res := list_vt_nil) // var !p_arr with pf_arr = @[int][3]() var res: res? // uninitialized val () = loop (pf_arr | re, str, ofs, len, p_arr, res) // in res end // end of [regexp_split_substring_list] (* ****** ****** *) val () = initialize () where { extern fun initialize (): void = "atslib_libats_regexp_initialize" } // end of [val] (* ****** ****** *) %{$ // // HX-2010-02-20: is this really necessary? // ats_void_type atslib_libats_regexp_initialize () { pcre_malloc = (void *(*)(size_t))ats_malloc_gc ; pcre_free = (void (*)(void*))ats_free_gc ; pcre_stack_malloc = (void *(*)(size_t))ats_malloc_gc ; pcre_stack_free = (void (*)(void*))ats_free_gc ; return ; } /* end of [atslib_libats_regexp_initialize] */ %} // end of [%{$] (* ****** ****** *) (* end of [regexp.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/gflist_vt.dats0000664000175000017500000000421712223166162020670 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed lists // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" (* ****** ****** *) staload "libats/SATS/gflist_vt.sats" (* ****** ****** *) implement{a} gflist_vt_length {xs} (xs) = let prval pf = list_vt_of_gflist_vt {a} (xs) // no-op casting // end of [val] val n = list_vt_length (xs) prval () = __assert (xs) where { extern prfun __assert {n:nat} (xs: !list_vt (a, n) >> gflist_vt (a, xs)): void } // end of [prval] in (pf | n) end // end of [gflist_vt_length] (* ****** ****** *) (* end of [gflist_vt.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funheap_braun.dats0000664000175000017500000001440512223166162021504 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional heap implementation based on Braun trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in November, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/funheap_braun.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) datatype brauntree (a:t@ype+, int) = | {n1,n2:nat | n2 <= n1; n1 <= n2+1} B (a, n1+n2+1) of (a, brauntree (a, n1), brauntree (a, n2)) | E (a, 0) of () // end of [brauntree] stadef bt = brauntree // an abbreviation (* ****** ****** *) assume heap_t0ype_type (a:t@ype) = [n:nat] brauntree (a, n) (* ****** ****** *) implement{} funheap_make_nil () = E () (* ****** ****** *) implement{a} funheap_size (hp) = size (hp) where { // // this algorithm is taken from a paper by Chris Okasaki // fun diff {nl,nr:nat | nr <= nl && nl <= nr+1} .. (nr: size_t nr, t: bt (a, nl)):<> int (nl-nr) = begin case+ t of | B (_, tl, tr) => begin if nr > 0 then let val nr2 = nr / 2 in if nr > nr2 + nr2 then diff (nr2, tl) else diff (nr2-1, tr) end else begin 1 // return value end // end of [if] end // end of [B] | E () => 0 end // end of [diff] // fun size {n:nat} .. (t: bt (a, n)):<> size_t n = case+ t of | B (_, tl, tr) => let val nr = size tr; val d1 = diff (nr, tl) + 1 in nr + nr + (size1_of_int1)d1 end // end of [B] | E () => 0 // end of [size] } // end of [funheap_size] (* ****** ****** *) implement{a} funheap_height (hp) = loop (hp, 0) where { fun loop {n:nat} .. (t: bt (a, n), res: Nat):<> Nat = case+ t of B (_, tl, _) => loop (tl, res + 1) | E () => res // end of [loop] } // end of [funheap_height] (* ****** ****** *) implement{a} funheap_insert (hp, x, cmp) = () where { fun insert {n:nat} .. (t: bt (a, n), x: a): bt (a, n+1) = case+ t of | E () => B (x, E (), E ()) | B (x0, t1, t2) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn >= 0 then B (x, insert (t2, x0), t1) else B (x0, insert (t2, x), t1) // end of [if] end // end of [B] // end of [insert] val () = hp := insert (hp, x) } // end of [funheap_insert] (* ****** ****** *) fun{a:t@ype} brauntree_leftrem {n:pos} .. (t: bt (a, n), x_r: &a? >> a):<> bt (a, n-1) = let val+ B (x, t1, t2) = t in case+ t1 of | B _ => let val t1 = brauntree_leftrem (t1, x_r) in B (x, t2, t1) end // end of [B] | E () => (x_r := x; E ()) end // end of [brauntree_leftrem] (* ****** ****** *) fn{a:t@ype} brauntree_siftdn {nl,nr:nat | nr <= nl; nl <= nr+1} ( x: a , tl: bt (a, nl), tr: bt (a, nr) , cmp: cmp a ) :<> bt (a, nl+nr+1) = siftdn (x, tl, tr) where { fun siftdn {nl,nr:nat | nr <= nl; nl <= nr+1} .. (x: a, tl: bt (a, nl), tr: bt (a, nr)) : bt (a, nl+nr+1) = case+ (tl, tr) of | (B (xl, tll, tlr), B (xr, trl, trr)) => begin if compare_elt_elt (xl, x, cmp) >= 0 then begin // xl >= x if compare_elt_elt (xr, x, cmp) >= 0 then B (x, tl, tr) else B (xr, tl, siftdn (x, trl, trr)) // end of [if] end else begin // xl < x if compare_elt_elt (xr, x, cmp) >= 0 then B (xl, siftdn (x, tll, tlr), tr) else begin // xr < x if compare_elt_elt (xl, xr, cmp) >= 0 then B (xr, tl, siftdn (x, trl, trr)) else B (xl, siftdn (x, tll, tlr), tr) // end of [if] end // end of [if] end (* end of [if] *) end (* end of [B _, B _] *) | (_, _) =>> begin case+ tl of | B (xl, _, _) => if compare_elt_elt (xl, x, cmp) >= 0 then B (x, tl, E) else B (xl, B (x, E, E), E) // end of [B] | E () => B (x, E (), E ()) end // end of [_, _] // end of [siftdn] } // end of [brauntree_siftdn] (* ****** ****** *) implement{a} funheap_delmin (hp, res, cmp) = let fn delmin {n:pos} ( t: bt (a, n), res: &a? >> a ) : bt (a, n-1) = let val+ B (x, t1, t2) = t; val () = res := x in case+ t1 of | B _ => let var x_lrm: a // uninitialized val t1 = brauntree_leftrem (t1, x_lrm) in brauntree_siftdn (x_lrm, t2, t1, cmp) end // end of [B] | E () => E () end // end of [demin] in case+ hp of | B _ => let val () = hp := delmin (hp, res) prval () = opt_some {a} (res) in true (*removed*) end // end of [B_] | E _ => let prval () = opt_none {a} (res) in false(*notremoved*) end // end of [E] end // end of [funheap_delmin] (* ****** ****** *) (* end of [funheap_brauntree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funmap_avltree.dats0000664000175000017500000004064012223166162021677 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/funmap_avltree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) // // HX-2010-03-24: this seems to work best! // #define HTDF 1 // max height difference #define HTDF1 %(HTDF+1) #define HTDF_1 %(HTDF-1) (* ****** ****** *) datatype avltree ( key:t@ype, itm:t@ype+, int(*height*) ) = | {hl,hr:nat | hl <= hr+HTDF; hr <= hl+HTDF} B (key, itm, 1+max(hl,hr)) of (int (1+max(hl,hr)), key, itm, avltree (key, itm, hl), avltree (key, itm, hr)) | E (key, itm, 0) // end of [datatype avltree] typedef avltree_inc (key:t@ype, itm:t@ype, h:int) = [h1:nat | h <= h1; h1 <= h+1] avltree (key, itm, h1) // end of [avltree_inc] typedef avltree_dec (key:t@ype, itm:t@ype, h:int) = [h1:nat | h1 <= h; h <= h1+1] avltree (key, itm, h1) // end of [avltree_dec] (* ****** ****** *) assume map_t0ype_t0ype_type ( key:t@ype, itm:t@ype ) = [h:nat] avltree (key, itm, h) (* ****** ****** *) implement{} funmap_make_nil () = E () (* ****** ****** *) implement{} funmap_is_nil (t) = case+ t of | B _ => false | E () => true // end of [funmap_is_nil] implement{} funmap_isnot_nil (t) = case+ t of | B _ => true | E () => false // end of [funmap_isnot_nil] (* ****** ****** *) implement{key,itm} funmap_size (t) = size (t) where { fun size {h:nat} .. (t: avltree (key, itm, h)):<> size_t = begin case+ t of | B (_(*h*), _(*key*), _(*itm*), tl, tr) => (size_of_int1)1 + size (tl) + size (tr) | E () => (size_of_int1)0 end // end of [size] } // end of [funmap_size] (* ****** ****** *) macdef avltree_height (t) = case+ ,(t) of B (h, _, _, _, _) => h | E _ => 0 // end of [avltree_height] implement{key,itm} funmap_height (t) = avltree_height (t) // end of [funmap_height] (* ****** ****** *) implement {key,itm} funmap_search (t, k0, cmp, res) = search (t, res) where { fun search {h:nat} .. ( t: avltree (key, itm, h), res: &itm? >> opt (itm, b) ): #[b:bool] bool b = begin case+ t of | B (_(*h*), k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in case+ 0 of | _ when sgn < 0 => search (tl, res) | _ when sgn > 0 => search (tr, res) | _ => let val () = res := x; prval () = opt_some {itm} (res) in true end // end of [_] end // end of [B] | E () => let prval () = opt_none {itm} (res) in false end // end of [E] end // end of [search] } // end of [funmap_search] implement {key,itm} funmap_search_opt (t, k0, cmp) = let var res: itm? val ans = funmap_search (t, k0, cmp, res) in if ans then let prval () = opt_unsome {itm} (res) in Some_vt (res) end else let prval () = opt_unnone {itm} (res) in None_vt (*void*) end // end of [if] end // end of [funmap_search_opt] (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{key,itm:t@ype} avltree_lrotate {hl,hr:nat | hl+HTDF1 == hr} ( k: key, x: itm , hl : int hl , tl: avltree (key, itm, hl) , hr : int hr , tr: avltree (key, itm, hr) ) :<> avltree_inc (key, itm, hr) = let val+ B {..} {hrl,hrr} (_(*hr*), kr, xr, trl, trr) = tr val hrl = avltree_height trl : int hrl and hrr = avltree_height trr : int hrr in if hrl <= hrr+HTDF_1 then let val hrl1 = hrl + 1 in B (1+max(hrl1,hrr), kr, xr, B (hrl1, k, x, tl, trl), trr) end else let // [hrl=hrr+2]: deep rotation val+ B {..} {hrll,hrlr} (_(*hrl*), krl, xrl, trll, trlr) = trl val hrll = avltree_height trll : int hrll val hrlr = avltree_height trlr : int hrlr in B (hr, krl, xrl, B (1+max(hl,hrll), k, x, tl, trll), B (1+max(hrlr,hrr), kr, xr, trlr, trr)) end // end of [if] end // end of [avltree_lrotate] (* ** right rotation for restoring height invariant *) fn{key,itm:t@ype} avltree_rrotate {hl,hr:nat | hl == hr+HTDF1} ( k: key, x: itm , hl: int hl , tl: avltree (key, itm, hl) , hr: int hr , tr: avltree (key, itm, hr) ) :<> avltree_inc (key, itm, hl) = let val+ B {..} {hll, hlr} (_(*hl*), kl, xl, tll, tlr) = tl val hll = avltree_height tll : int hll and hlr = avltree_height tlr : int hlr in if hll+HTDF_1 >= hlr then let val hlr1 = hlr + 1 in B (1+max(hll,hlr1), kl, xl, tll, B (hlr1, k, x, tlr, tr)) end else let val+ B {..} {hlrl,hlrr} (_(*hlr*), klr, xlr, tlrl, tlrr) = tlr val hlrl = avltree_height tlrl : int hlrl val hlrr = avltree_height tlrr : int hlrr in B (hl, klr, xlr, B (1+max(hll,hlrl), kl, xl, tll, tlrl), B (1+max(hlrr,hr), k, x, tlrr, tr)) end // end of [if] end // end of [avltree_rrotate] (* ****** ****** *) implement{key,itm} funmap_insert (m, k0, x0, cmp) = res where { fun insert {h:nat} .. ( t: avltree (key, itm, h), res: &bool? >> bool ) : avltree_inc (key, itm, h) = begin case+ t of | B {..} {hl,hr} (h, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val [hl:int] tl = insert (tl, res) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then begin B (1+max(hl,hr), k, x, tl, tr) end else begin // hl = hr+HTDF1 avltree_rrotate (k, x, hl, tl, hr, tr) end // end of [if] end else if sgn > 0 then let val [hr:int] tr = insert (tr, res) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl, hr), k, x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (k, x, hl, tl, hr, tr) end // end of [if] end else let (* [k0] already exists *) val () = res := true in B (h, k, x0, tl, tr) end // end of [if] end // end of [B] | E () => let (* [k0] is not in [m] *) val () = res := false in B (1, k0, x0, E (), E ()) end // end of [E] end // end of [insert] var res: bool // uninitialized val () = m := insert (m, res) } // end of [funmap_insert] (* ****** ****** *) implement{key,itm} funmap_insert_clo (m, k0, x0, f, cmp) = () where { fun insert {h:nat} .. (t: avltree (key, itm, h), f: &(itm, itm) - itm) : avltree_inc (key, itm, h) = begin case+ t of | B {..} {hl,hr} (h, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val [hl:int] tl = insert (tl, f) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then begin B (1+max(hl,hr), k, x, tl, tr) end else begin // hl = hr+HTDF1 avltree_rrotate (k, x, hl, tl, hr, tr) end // end of [if] end else if sgn > 0 then let val [hr:int] tr = insert (tr, f) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl, hr), k, x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (k, x, hl, tl, hr, tr) end // end of [if] end else begin (* sgn = 0: item already exists *) B (h, k, f (x0, x), tl, tr) end // end of [if] end // end of [B] | E () => begin B (1, k0, x0, E (), E ()) end // end of [E] end // end of [insert] val () = m := insert (m, f) } // end of [funmap_insert_clo] (* ****** ****** *) fun{key,itm:t@ype} avltree_takeout_min {h:pos} .. ( t: avltree (key, itm, h) , k0: &key? >> key , x0: &itm? >> itm ) :<> avltree_dec (key, itm, h) = let val+ B {..} {hl,hr} (_, k, x, tl, tr) = t in case+ tl of | B _ => let val [hl:int] tl = avltree_takeout_min (tl, k0, x0) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl,hr), k, x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (k, x, hl, tl, hr, tr) end // end of [if] end // end of [B] | E () => (k0 := k; x0 := x; tr) end // end of [avltree_takeout_min] (* ****** ****** *) // // HX-2010-03-25: // this is a bit unsafe but convenient to implement // the pointer [p_res] is assumed to be associated with a proof // of at-view if it is not null // extern fun{key,itm:t@ype} funmap_takeout_ptr {l_res:addr} (m: &map (key, itm), k0: key, cmp: cmp key, p_res: ptr l_res):<> bool // end of [funmap_takeout] implement{key,itm} funmap_takeout_ptr {l_res} (m, k0, cmp, p_res) = b(*removed*) where { fun takeout {h:nat} .. ( t: avltree (key, itm, h) , p_res: ptr l_res, b: &bool? >> bool ) : avltree_dec (key, itm, h) = begin case+ t of | B {..} {hl,hr} (h, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in case+ 0 of | _ when sgn < 0 => let val [hl:int] tl = takeout (tl, p_res, b) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl,hr), k, x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (k, x, hl, tl, hr, tr) end // end of [if] end // end of [sgn < 0] | _ when sgn > 0 => let val [hr:int] tr = takeout (tr, p_res, b) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then begin B (1+max(hl,hr), k, x, tl, tr) end else begin // hl=hr+HTDF1 avltree_rrotate (k, x, hl, tl, hr, tr) end // end of [if] end // end of [sgn > 0] | _ (*sgn = 0*) => let val () = if (p_res <> null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := x prval () = fpf (pf) in // nothing end // end of [val] val () = b := true in case+ tr of | B _ => let var k_min: key? and x_min: itm? val [hr:int] tr = avltree_takeout_min (tr, k_min, x_min) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then begin B (1+max(hl,hr), k_min, x_min, tl, tr) end else begin // hl=hr+HTDF1 avltree_rrotate (k_min, x_min, hl, tl, hr, tr) end // end of [if] end // end of [B] | E _ => tl end // end of [sgn = 0] end // end of [B] | E () => t where { val () = b := false } // end of [E] end // end of [takeout] var b: bool // unitialized val () = m := takeout (m, p_res, b) } // end of [funmap_takeout_ptr] (* ****** ****** *) implement{key,itm} funmap_takeout (m, k0, cmp, res) = ans where { val ans = funmap_takeout_ptr (m, k0, cmp, &res) val [b:bool] ans = bool1_of_bool (ans) prval pf = __assert (view@ res) where { extern praxi __assert {l_res:addr} (pf: itm? @ l_res):<> (opt (itm, b) @ l_res) } // end of [prval] prval () = (view@ res := pf) } // end of [funmap_takeout] implement{key,itm} funmap_remove (m, k0, cmp) = funmap_takeout_ptr (m, k0, cmp, null) // end of [funmap_remove] (* ****** ****** *) (* fun{key,itm:t@ype} funmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt ) :<> void // end of [funmap_foreach_funenv] *) implement{key,itm} funmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf | m, env) where { fun foreach {h:nat} .. (pf: !v | t: avltree (key, itm, h), env: !vt): void = case+ t of | B (_(*h*), k, x, tl, tr) => begin foreach (pf | tl, env); f (pf | k, x, env); foreach (pf | tr, env) end // end of [B] | E () => () // end of [foreach] } // end of [funmap_foreach_funenv] implement{key,itm} funmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, itm) - void):<> (!unit_v | key, itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = funmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [funmap_foreach_fun] (* ****** ****** *) implement{key,itm} funmap_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {h:nat} .. (pf: !v | t: avltree (key, itm, h), f: &(!v | key, itm) - void):<> void = case+ t of | B (_(*h*), k, x, tl, tr) => begin foreach (pf | tl, f); f (pf | k, x); foreach (pf | tr, f) end // end of [B] | E () => () // end of [foreach] } // end of [funmap_foreach_vclo] implement{key,itm} funmap_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, itm) - void):<> (!unit_v | key, itm) - void } // end of [val] typedef clo_type = (!unit_v | key, itm) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pfu = unit_v () val () = $effmask_ref (funmap_foreach_vclo {unit_v} (pfu | m, !p_f)) prval unit_v () = pfu in // empty end // end of [funmap_foreach_cloref] (* ****** ****** *) (* fun{key,itm:t@ype} funmap_rforeach_funenv {v:view} {vt:viewtype} ( pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt ) :<> void // end of [funmap_rforeach_funenv] *) implement{key,itm} funmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf | m, env) where { fun rforeach {h:nat} .. (pf: !v | t: avltree (key, itm, h), env: !vt): void = case+ t of | B (_(*h*), k, x, tl, tr) => begin rforeach (pf | tr, env); f (pf | k, x, env); rforeach (pf | tl, env) end // end of [B] | E () => () // end of [rforeach] } // end of [funmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} funmap_listize (xs) = let typedef keyitm = @(key, itm) viewtypedef res_vt = List_vt keyitm fun listize {h:nat} .. ( t: avltree (key, itm, h), res: res_vt ) :<> res_vt = case+ t of | B (_(*h*), k, x, tl, tr) => let val res = listize (tr, res) val res = list_vt_cons {keyitm} ((k, x), res) val res = listize (tl, res) in res end // end of [B] | E () => res // end of [listize] in listize (xs, list_vt_nil ()) end // end of [funmap_listize] (* ****** ****** *) (* end of [funmap_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linset_avltree.dats0000664000175000017500000006733212223166162021716 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A linear set implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: October, 2011 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/linset_avltree.sats" (* ****** ****** *) sortdef t0p = t@ype (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) // // HX-2010-03-24: this seems to work best! // #define HTDF 1 // max height difference #define HTDF1 %(HTDF+1) #define HTDF_1 %(HTDF-1) (* ****** ****** *) dataviewtype avltree ( a:t@ype+, int(*height*) ) = | {hl,hr:nat | hl <= hr+HTDF; hr <= hl+HTDF} B (a, 1+max(hl,hr)) of (int (1+max(hl,hr)), a, avltree (a, hl), avltree (a, hr)) | E (a, 0) // end of [datatype avltree] typedef avltree0 = avltree (void, 0)? viewtypedef avltree_inc (a:t@ype, h:int) = [h1:nat | h <= h1; h1 <= h+1] avltree (a, h1) // end of [avltree_inc] viewtypedef avltree_dec (a:t@ype, h:int) = [h1:nat | h1 <= h; h <= h1+1] avltree (a, h1) // end of [avltree_dec] (* ****** ****** *) assume set_t0ype_viewtype (a:t@ype) = [h:nat] avltree (a, h) (* ****** ****** *) implement{} linset_make_nil () = E () implement{a} linset_make_sing (x) = B (1, x, E (), E ()) (* ****** ****** *) implement{} linset_is_empty (t) = case+ t of | B _ => (fold@ t; false) | E () => (fold@ t; true) // end of [linset_is_empty] implement{} linset_isnot_empty (t) = case+ t of | B _ => (fold@ t; true) | E () => (fold@ t; false) // end of [linset_isnot_empty] (* ****** ****** *) implement{a} linset_size (t) = size (t) where { fun size {h:nat} .. (t: !avltree (a, h)):<> size_t = begin case+ t of | B (_(*h*), _(*elt*), !ptl, !ptr) => let val sz = (size_of_int1)1 + size (!ptl) + size (!ptr) in (fold@ t; sz) end // end of [B] | E () => (fold@ t; size_of_int1(0)) end // end of [size] } // end of [linset_size] (* ****** ****** *) fn{a:t@ype} avltree_height {h:int} (t: !avltree (a, h)):<> int h = case+ t of B (h, _, _, _) => (fold@ t; h) | _ =>> 0 // end of [avltree_height] (* ****** ****** *) implement{a} linset_is_member (xs, x0, cmp) = aux (xs) where { fun aux {h:nat} .. (t: !avltree (a, h)): bool = case+ t of | B (_, x, !p_tl, !p_tr) => let val sgn = compare_elt_elt (x0, x, cmp) val res = if sgn < 0 then aux (!p_tl) else (if sgn > 0 then aux (!p_tr) else true) // end of [val] in fold@ (t); res end // end of [B] | E () => (fold@ (t); false) // end of [aux] } // end of [linset_is_member] implement{a} linset_isnot_member (xs, x0, cmp) = ~linset_is_member (xs, x0, cmp) (* ****** ****** *) implement{a} linset_free (xs) = let fun aux {h:nat} .. (t: avltree (a, h)):<> void = case+ t of | ~B (_, x, tl, tr) => (aux tl; aux tr) | ~E () => () // end of [aux] in aux (xs) end // end of [linset_free] (* ****** ****** *) implement{a} linset_copy (xs) = let // fun aux {h:nat} .. ( t: !avltree (a, h) ) :<> avltree (a, h) = let in // case+ t of | B (h, x, !p_tl, !p_tr) => let val t2 = B (h, x, aux (!p_tl), aux (!p_tr)) prval () = fold@ (t) in t2 end // end of [B] | E () => let prval () = fold@ (t) in E (*void*) end // end of [E] // end // end of [aux] // in aux (xs) end // end of [linset_copy] (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{a:t0p} avltree_lrotate {hl,hr:nat | hl+HTDF1 == hr} {l_h,l_k,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h , pf_x: a @ l_x , pf_tl: avltree (a, hl) @ l_tl , pf_tr: avltree (a, hr) @ l_tr | p_h: ptr l_h , hl : int hl , p_tl: ptr l_tl , hr : int hr , p_tr: ptr l_tr , t: B_unfold (l_h, l_x, l_tl, l_tr) ) :<> avltree_inc (a, hr) = let val tr = !p_tr val+ B {..} {hrl,hrr} (!p_hr, _, !p_trl, !p_trr) = tr val hrl = avltree_height (!p_trl) and hrr = avltree_height (!p_trr) in if hrl <= hrr+HTDF_1 then let val hrl1 = hrl + 1 val () = !p_h := hrl1 // () = !p_tl := tl val () = !p_tr := !p_trl prval () = fold@ (t) val () = !p_hr := 1+max(hrl1,hrr) val () = !p_trl := t // val () = !p_trr := trr prval () = fold@ (tr) in tr // B (1+max(hrl1,hrr), kr, xr, B (hrl1, k, x, tl, trl), trr) end else let // [hrl=hrr+2]: deep rotation val trl = !p_trl val+ B {..} {hrll,hrlr} (!p_hrl, _, !p_trll, !p_trlr) = trl val hrll = avltree_height (!p_trll) val hrlr = avltree_height (!p_trlr) val () = !p_h := 1+max(hl,hrll) // val () = !p_tl := tl val () = !p_tr := !p_trll prval () = fold@ t val () = !p_hr := 1+max(hrlr, hrr) val () = !p_trl := !p_trlr // val () = !p_trr := trr prval () = fold@ tr val () = !p_hrl := hr val () = !p_trll := t val () = !p_trlr := tr prval () = fold@ (trl) in trl // B (hr, krl, xrl, B (1+max(hl,hrll), k, x, tl, trll), B (1+max(hrlr,hrr), kr, xr, trlr, trr)) end // end of [if] end // end of [avltree_lrotate] (* ** right rotation for restoring height invariant *) fn{a:t0p} avltree_rrotate {hl,hr:nat | hl == hr+HTDF1} {l_h,l_k,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h , pf_x: a @ l_x , pf_tl: avltree (a, hl) @ l_tl , pf_tr: avltree (a, hr) @ l_tr | p_h: ptr l_h , hl : int hl , p_tl: ptr l_tl , hr : int hr , p_tr: ptr l_tr , t: B_unfold (l_h, l_x, l_tl, l_tr) ) :<> avltree_inc (a, hl) = let val tl = !p_tl val+ B {..} {hll, hlr} (!p_hl, _, !p_tll, !p_tlr) = tl val hll = avltree_height (!p_tll) and hlr = avltree_height (!p_tlr) in if hll+HTDF_1 >= hlr then let val hlr1 = hlr + 1 val () = !p_h := hlr1 val () = !p_tl := !p_tlr // () = !p_tr := tr prval () = fold@ (t) val () = !p_hl := 1+max(hll,hlr1) // val () = !p_tll := tll val () = !p_tlr := t prval () = fold@ (tl) in tl // B (1+max(hll,hlr1), kl, xl, tll, B (hlr1, k, x, tlr, tr)) end else let val tlr = !p_tlr val+ B {..} {hlrl,hlrr} (!p_hlr, _, !p_tlrl, !p_tlrr) = tlr val hlrl = avltree_height (!p_tlrl) val hlrr = avltree_height (!p_tlrr) val () = !p_h := 1+max(hlrr,hr) val () = !p_tl := !p_tlrr // val () = !p_tr := tr prval () = fold@ t val () = !p_hl := 1+max(hll,hlrl) // val () = !p_tll := tll val () = !p_tlr := !p_tlrl prval () = fold@ tl val () = !p_hlr := hl val () = !p_tlrl := tl val () = !p_tlrr := t prval () = fold@ (tlr) in tlr // B (hl, klr, xlr, B (1+max(hll,hlrl), kl, xl, tll, tlrl), B (1+max(hlrr,hr), k, x, tlrr, tr)) end // end of [if] end // end of [avltree_rrotate] (* ****** ****** *) implement{a} linset_insert (xs, x0, cmp) = let // fun insert {h:nat} .. ( t: &avltree (a, h) >> avltree_inc (a, h), x0: a ) : #[b:bool] bool b = begin case+ t of | B {..} {hl,hr} (!p_h, !p_x, !p_tl, !p_tr) => let prval pf_h = view@ !p_h prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr val sgn = compare_elt_elt (x0, !p_x, cmp) in if sgn < 0 then let val ans = insert (!p_tl, x0) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hl - hr <= HTDF then let val () = !p_h := 1+max(hl,hr) prval () = fold@ (t) in ans // B (1+max(hl,hr), k, x, tl, tr) end else let // hl = hr+HTDF1 val () = t := avltree_rrotate (pf_h, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) in ans end // end of [if] end else if sgn > 0 then let val ans = insert (!p_tr, x0) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let val () = !p_h := 1+max(hl, hr) prval () = fold@ (t) in ans // B (1+max(hl, hr), k, x, tl, tr) end else let // hl+HTDF1 = hr val () = t := avltree_lrotate (pf_h, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) in ans end // end of [if] end else let (* key already exists *) prval () = fold@ t in true // B (h, k, x0, tl, tr) end // end of [if] end // end of [B] | ~E () => let val () = t := B (1, x0, E (), E ()) in false // a newly created node end // end of [E] end // end of [insert] // in // insert (xs, x0) // end // end of [linset_insert] (* ****** ****** *) viewtypedef B_node (a:t@ype) = B_pstruct (int?, a, avltree0, avltree0) // end of [B_node] extern castfn B_node_make {a:t@ype} {l_h,l_x,l_tl,l_tr:addr} ( pf_h: int? @ l_h, pf_x: a @ l_x, pf_tl: avltree? @ l_tl, pf_tr: avltree? @ l_tr | x: B_unfold (l_h, l_x, l_tl, l_tr) ) :<> B_node (a) // end of [B_node_make] fun{a:t@ype} avltree_takeout_min {h:pos} .. ( t: &avltree (a, h) >> avltree_dec (a, h) ) :<> B_node (a) = let val+ B {..} {hl,hr} (!p_h, !p_x, !p_tl, !p_tr) = t prval pf_h = view@ !p_h prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr in case+ !p_tl of | B _ => let prval () = fold@ (!p_tl) val node = avltree_takeout_min (!p_tl) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let val () = !p_h := 1+max(hl,hr) prval () = fold@ t // B (1+max(hl,hr), k, x, tl, tr) in node end else let val () = t := avltree_lrotate (pf_h, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in node end // end of [if] end // end of [B] | ~E () => let val tr = !p_tr; val t0 = t; val () = t := tr in B_node_make {a} (pf_h, pf_x, pf_tl, pf_tr | t0) end // end of [E] end // end of [avltree_takeout_min] (* ****** ****** *) implement{a} linset_remove (xs, x0, cmp) = remove (xs) where { fun remove {h:nat} .. ( t: &avltree (a, h) >> avltree_dec (a, h) ) : bool = begin case+ t of | B {..} {hl,hr} (!p_h, !p_x, !p_tl, !p_tr) => let stavar l_x:addr val p_x = p_x : ptr l_x prval pf_h = view@ !p_h prval pf_x = view@ !p_x prval pf_tl = view@ !p_tl prval pf_tr = view@ !p_tr val sgn = compare_elt_elt (x0, !p_x, cmp) in case+ 0 of | _ when sgn < 0 => let val ans(*removed*) = remove (!p_tl) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hr - hl <= HTDF then let prval () = !p_h := 1+max(hl,hr) in fold@ (t); ans end else let // hl+HTDF1 = hr val () = t := avltree_lrotate (pf_h, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in ans end // end of [if] end // end of [sgn < 0] | _ when sgn > 0 => let val ans = remove (!p_tr) val hl = avltree_height (!p_tl) and hr = avltree_height (!p_tr) in if hl - hr <= HTDF then let prval () = !p_h := 1+max(hl,hr) in fold@ (t); ans end else let // hl=hr+HTDF1 val () = t := avltree_rrotate (pf_h, pf_x, pf_tl, pf_tr | p_h, hl, p_tl, hr, p_tr, t) // end of [val] in ans end // end of [if] end // end of [sgn > 0] | _ (*sgn = 0*) => let var tl = !p_tl and tr = !p_tr val () = free@ {a} {0,0} (t) in case+ tr of | B _ => let prval () = fold@ tr val t1 = avltree_takeout_min (tr) val B (!p1_h, !p1_x, !p1_tl, !p1_tr) = t1 prval pf1_h = view@ !p1_h prval pf1_x = view@ !p1_x prval pf1_tl = view@ !p1_tl prval pf1_tr = view@ !p1_tr val hl = avltree_height (tl) and hr = avltree_height (tr) val () = !p1_tl := tl and () = !p1_tr := tr in if hl - hr <= HTDF then let val () = !p1_h := 1+max(hl,hr) in fold@ t1; t := t1; true end else let val () = t := avltree_rrotate (pf1_h, pf1_x, pf1_tl, pf1_tr | p1_h, hl, p1_tl, hr, p1_tr, t1) // end of [val] in true end // end of [if] end // end of [B] | E _ => (t := tl; true) end // end of [sgn = 0] end // end of [B] | E () => (fold@ t; false(*~removed*)) end // end of [remove] } // end of [linset_remove] (* ****** ****** *) (* ** left join: height(tl) >= height(tr) *) fun{a:t@ype} avltree_ljoin {hl,hr:nat | hl >= hr} .. ( xn: B_node (a) , tl: avltree (a, hl), tr: avltree (a, hr) ) :<> avltree_inc (a, hl) = let val hl = avltree_height (tl): int hl and hr = avltree_height (tr): int hr in if hl >= hr + HTDF1 then let val+ B {..} {hll, hlr} (!p_hl, !p_xl, !p_tll, !p_tlr) = tl val [hlr:int] tlr = avltree_ljoin (xn, !p_tlr, tr) val () = !p_tlr := tlr val hll = avltree_height (!p_tll): int hll and hlr = avltree_height (!p_tlr): int hlr in if hlr <= hll + HTDF then let val () = !p_hl := max (hll, hlr) + 1 prval () = fold@ {a} (tl) in tl end else let // hll+HTDF1 = hlr prval pf_hl = view@(!p_hl) prval pf_xl = view@(!p_xl) prval pf_tll = view@ (!p_tll) prval pf_tlr = view@ (!p_tlr) in avltree_lrotate ( pf_hl, pf_xl, pf_tll, pf_tlr | p_hl, hll, p_tll, hlr, p_tlr, tl ) // end of [avltree_lrotate] end // end of [if] end else let val B (!p_h, _, !p_tl, !p_tr) = xn val () = !p_h := hl + 1 val () = !p_tl := tl and () = !p_tr := tr in fold@ {a} (xn); xn end // end of [if] end // end of [avltree_ljoin] (* ** right join: height(tl) <= height(tr) *) fun{a:t@ype} avltree_rjoin {hl,hr:nat| hl <= hr} .
. ( xn: B_node (a) , tl: avltree (a, hl), tr: avltree (a, hr) ) :<> avltree_inc (a, hr) = let val hl = avltree_height (tl): int hl and hr = avltree_height (tr): int hr in if hr >= hl + HTDF1 then let val+ B {..} {hrl,hrr} (!p_hr, !p_xr, !p_trl, !p_trr) = tr val [hrl:int] trl = avltree_rjoin
(xn, tl, !p_trl) val () = !p_trl := trl val hrl = avltree_height (!p_trl): int hrl and hrr = avltree_height (!p_trr): int hrr in if hrl <= hrr + HTDF then let val () = !p_hr := max (hrl,hrr) + 1 prval () = fold@ {a} (tr) in tr end else let // hrl = hrr+HTDF1 prval pf_hr = view@(!p_hr) prval pf_xr = view@(!p_xr) prval pf_trl = view@ (!p_trl) prval pf_trr = view@ (!p_trr) in avltree_rrotate ( pf_hr, pf_xr, pf_trl, pf_trr | p_hr, hrl, p_trl, hrr, p_trr, tr ) // end of [avltree_lrotate] end // end of [if] end else let val B (!p_h, _, !p_tl, !p_tr) = xn val () = !p_h := hr + 1 val () = !p_tl := tl and () = !p_tr := tr in fold@ {a} (xn); xn end // end of [if] end // end of [avltree_rjoin] (* ****** ****** *) fn{a:t@ype} avltree_join {hl,hr:nat} ( xn: B_node (a) , tl: avltree (a, hl), tr: avltree (a, hr) ) :<> [h:int | hl <= h; hr <= h; h <= max(hl,hr)+1] avltree (a, h) = let val hl = avltree_height tl: int hl and hr = avltree_height tr: int hr in if hl >= hr then avltree_ljoin (xn, tl, tr) else avltree_rjoin (xn, tl, tr) // end of [if] end // end of [avltree_join] (* ****** ****** *) fn{a:t@ype} avltree_concat {hl,hr:nat} ( tl: avltree (a, hl), tr: avltree (a, hr) ) :<> [h:nat | h <= max(hl,hr)+1] avltree (a, h) = case+ (tl, tr) of | (~E (), _) => tr | (_, ~E ()) => tl | (_, _) =>> let var tr = tr val xn_min = avltree_takeout_min (tr) in avltree_join (xn_min, tl, tr) end // end of [_, _] // end of [avltree_concat] (* ****** ****** *) fun{a:t@ype} avltree_split_at {h:nat} .. ( t: avltree (a, h) , x0: a , xn: &B_node(a)? >> opt (B_node(a), i>0) , tl0: &avltree0 >> avltree (a, hl) , tr0: &avltree0 >> avltree (a, hr) , cmp: cmp a ) :<> #[i:two; hl,hr:nat | hl <= h; hr <= h] int i = case+ t of | B (!p_h, !p_x, !p_tl, !p_tr) => let val x = !p_x val tl = !p_tl and tr = !p_tr val t = B_node_make {a} (view@(!p_h), view@(!p_x), view@(!p_tl), view@(!p_tr) | t) val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val i = avltree_split_at (tl, x0, xn, tl0, tr0, cmp) in tr0 := avltree_join (t, tr0, tr); i end else if sgn > 0 then let val i = avltree_split_at (tr, x0, xn, tl0, tr0, cmp) in tl0 := avltree_join (t, tl, tl0); i end else let val () = xn := t val ()= tl0 := tl and () = tr0 := tr prval () = opt_some {B_node(a)} (xn) in 1 // [x0] found in t end // end of [if] end // end of [B] | ~E () => let val () = tl0 := E () and () = tr0 := E () prval () = opt_none {B_node(a)} (xn) in 0 // [x0] not found in t end // end of [E] // end of [avltree_split_at] (* ****** ****** *) implement{a} linset_choose (xs, x0) = case+ xs of | B (_(*h*), x, _(*tl*), _(*tr*)) => let prval () = fold@ (xs) val () = x0 := x prval () = opt_some {a} (x0) in true end // end of [B] | E () => let prval () = fold@ (xs) prval () = opt_none {a} (x0) in false end // end of [E] // end of [linset_choose] implement{a} linset_choose_out (xs, x0) = case+ xs of | ~B (_(*h*), x, tl, tr) => let val () = x0 := x val () = xs := avltree_concat (tl, tr) prval () = opt_some {a} (x0) in true end // end of [E] | E () => let prval () = fold@ (xs) prval () = opt_none {a} (x0) in false end // end of [E] // end of [linset_choose_out] (* ****** ****** *) fn{} B_node_free_opt {a:t@ype} {i:nat} ( xn: opt (B_node(a), i > 0), i: int i ) :<> void = let viewtypedef T = B_node(a) in if i > 0 then let prval () = opt_unsome {T} (xn) val+ B _ = xn in free@ {a} {0,0} (xn) end else let prval () = opt_unnone {T} (xn) prval () = cleanup_top {T} (xn) in (*nothing*) end // end of [if] end // end of [B_node_free_opt] (* ****** ****** *) implement{a} linset_union (t1, t2, cmp) = union (t1, t2) where { fun union {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (~E (), _) => t2 | (_, ~E ()) => t1 | (_, _) =>> let val+ B (!p_h1, !p_x1, !p_t1l, !p_t1r) = t1 val x1 = !p_x1 val t1l = !p_t1l and t1r = !p_t1r var xn: B_node (a) var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, xn, t2l0, t2r0, cmp) val () = B_node_free_opt<> {a} (xn, i) val t12l = union (t1l, t2l0) and t12r = union (t1r, t2r0) val t1 = B_node_make {a} ( view@(!p_h1), view@(!p_x1), view@(!p_t1l), view@(!p_t1r) | t1 ) // end of [val] in avltree_join (t1, t12l, t12r) end // end of [_, _] end // end of [uni] // end of [union] } // end of [linset_union] (* ****** ****** *) implement{a} linset_intersect (t1, t2, cmp) = inter (t1, t2) where { fun inter {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (~E (), _) => (linset_free (t2); E ()) | (_, ~E ()) => (linset_free (t1); E ()) | (_, _) =>> let val+ ~B (_(*h1*), x1, t1l, t1r) = t1 stadef T = B_node(a) var xn: T? var t2l0: avltree0 and t2r0: avltree0 val+ i = avltree_split_at (t2, x1, xn, t2l0, t2r0, cmp) val t12l = inter (t1l, t2l0) and t12r = inter (t1r, t2r0) in if i = 0 then let prval () = opt_unnone {T} (xn) in avltree_concat (t12l, t12r) end else let prval () = opt_unsome {T} (xn) in avltree_join (xn, t12l, t12r) end // end of [if] end // end of [_, _] end // end of [inter] // end of [inter] } // end of [linset_intersect] (* ****** ****** *) implement{a} linset_diff (t1, t2, cmp) = diff (t1, t2) where { fun diff {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (~E (), _) => (linset_free (t2); E ()) | (_, ~E ()) => t1 | (_, _) =>> let val+ B (!p_h1, !p_x1, !p_t1l, !p_t1r) = t1 val x1 = !p_x1 val t1l = !p_t1l and t1r = !p_t1r var xn: B_node(a) var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, xn, t2l0, t2r0, cmp) val () = B_node_free_opt {a} (xn, i) val t12l = diff (t1l, t2l0) and t12r = diff (t1r, t2r0) in if i > 0 then let val () = free@ {a} {0,0} (t1) in avltree_concat (t12l, t12r) end else let val t1 = B_node_make {a} ( view@(!p_h1), view@(!p_x1), view@(!p_t1l), view@(!p_t1r) | t1 ) // end of [val] in avltree_join (t1, t12l, t12r) end (* end of [if] *) end // end of [_, _] end // end of [diff] // end of [diff] } // end of [linset_diff] (* ****** ****** *) implement{a} linset_symdiff (t1, t2, cmp) = symdiff (t1, t2) where { fun symdiff {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (~E (), _) => t2 | (_, ~E ()) => t1 | (_, _) =>> let val+ B (!p_h1, !p_x1, !p_t1l, !p_t1r) = t1 val x1 = !p_x1 val t1l = !p_t1l and t1r = !p_t1r var xn: B_node(a) var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, xn, t2l0, t2r0, cmp) val () = B_node_free_opt {a} (xn, i) val t12l = symdiff (t1l, t2l0) and t12r = symdiff (t1r, t2r0) in if i > 0 then let val () = free@ {a} {0,0} (t1) in avltree_concat (t12l, t12r) end else let val t1 = B_node_make {a} ( view@(!p_h1), view@(!p_x1), view@(!p_t1l), view@(!p_t1r) | t1 ) // end of [val] in avltree_join (t1, t12l, t12r) end (* end of [if] *) end // end of [_, _] end // end of [symdiff] // end of [diff] } // end of [linset_symdiff] (* ****** ****** *) implement{a} linset_is_subset (xs1, xs2, cmp) = let fun is_subset {h1:nat} .

. ( t1: !avltree (a, h1), t2: !set(a), cmp: cmp(a) ) : bool = case+ t1 of | B (_, x, !p_t1l, !p_t1r) => let val test = linset_is_member (t2, x, cmp) in if test then ( if is_subset (!p_t1l, t2, cmp) then let val res = is_subset (!p_t1r, t2, cmp) in fold@ t1; res end else (fold@ t1; false) // end of [if] ) else (fold@ t1; false) // end of [if] end // end of [B] | E _ => (fold@ (t1); true) // end of [is_subset] in is_subset (xs1, xs2, cmp) end // end of [linset_is_supset] implement{a} linset_is_supset (xs1, xs2, cmp) = linset_is_subset (xs2, xs1, cmp) // end of [linset_is_supset] implement{a} linset_is_equal (xs1, xs2, cmp) = if linset_is_supset (xs1, xs2, cmp) then linset_is_subset (xs1, xs2, cmp) else false // end of [if] (* end of [linset_is_equal] *) (* ****** ****** *) implement{a} linset_foreach_funenv {v} {vt} (pf | xs, f, env) = foreach (pf | xs, env) where { fun foreach {h:nat} .. (pf: !v | t: !avltree (a, h), env: !vt): void = case+ t of | B ( _(*h*), x, !p_tl, !p_tr ) => let val () = foreach (pf | !p_tl, env) val () = f (pf | x, env) val () = foreach (pf | !p_tr, env) in fold@ (t) end // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linset_foreach_funenv] implement{a} linset_foreach_fun (xs, f) = let // val f = coerce (f) where { extern castfn coerce (f: (a) - void):<> (!unit_v | a, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = linset_foreach_funenv {unit_v} {ptr} (pfu | xs, f, null) prval unit_v () = pfu // in // nothing end // end of [linset_foreach_fun] (* ****** ****** *) implement{a} linset_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {h:nat} .. ( pf: !v | t: !avltree (a, h), f: &(!v | a) - void ) :<> void = case+ t of | B ( _(*h*), x, !p_tl, !p_tr ) => let val () = foreach (pf | !p_tl, f) val () = f (pf | x) val () = foreach (pf | !p_tr, f) in fold@ (t) end // end of [B] | E () => fold@ (t) // end of [foreach] } // end of [linset_foreach_vclo] implement{a} linset_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (a) - void):<> (!unit_v | a) - void } // end of [val] typedef clo_type = (!unit_v | a) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pfu = unit_v () val () = $effmask_ref (linset_foreach_vclo {unit_v} (pfu | m, !p_f)) prval unit_v () = pfu in // empty end // end of [linset_foreach_cloref] (* ****** ****** *) implement{a} linset_listize (xs) = let viewtypedef res_t = List_vt (a) fun aux {h:nat} .. (t: !avltree (a, h), res: res_t):<> res_t = case+ t of | B (_(*h*), x, !p_tl, !p_tr) => let val res = aux (!p_tr, res) val res = list_vt_cons (x, res) val res = aux (!p_tl, res) prval () = fold@ (t) in res end // end of [B] | E () => (fold@ (t); res) // end of [aux] in aux (xs, list_vt_nil) end // end of [linset_listize] (* ****** ****** *) implement{a} linset_listize_free (xs) = let viewtypedef res_t = List_vt (a) fun aux {h:nat} .. (t: avltree (a, h), res: res_t):<> res_t = case+ t of | ~B (_(*h*), x, tl, tr) => let val res = aux (tr, res) val res = list_vt_cons (x, res) val res = aux (tl, res) in res end // end of [B] | ~E () => res // end of [E] // end of [aux] in aux (xs, list_vt_nil) end // end of [linset_listize_free] (* ****** ****** *) (* end of [linset_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/hashtable_chain.dats0000664000175000017500000005467512223166162022001 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A hashtable implementation ** where buckets are represented as linked lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/hashtable_chain.sats" (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) implement{key} hash_key (x, hash) = hash (x) implement{key} equal_key_key (x1, x2, eqfn) = eqfn (x1, x2) (* ****** ****** *) dataviewtype chain ( key:t@ype, itm:viewt@ype+, int ) = | {n:nat} CHAINcons (key, itm, n+1) of (key, itm, chain (key, itm, n)) | CHAINnil (key, itm, 0) // end of [chain] viewtypedef chain ( key:t0p, itm:vt0p ) = [n:nat] chain (key, itm, n) viewtypedef chain0 = chain (void, void, 0) stadef chainsz = sizeof (chain0) extern typedef "chain0_ptr" = chain0 (* ****** ****** *) fun{key:t0p;itm:t0p} chain_free {n:nat} .. ( kis: chain (key, itm, n) ) :<> void = begin case+ kis of | ~CHAINcons (_(*key*), _(*itm*), kis) => chain_free (kis) | ~CHAINnil () => () end // end of [chain_free] fun{key:t0p;itm:vt0p} chain_free_fun {n:nat} .. ( kis: chain (key, itm, n), f: (&itm >> itm?) -<> void ) :<> void = begin case+ kis of | CHAINcons (_(*key*), !p_itm, kis1) => let val () = f (!p_itm) val () = free@ {key,itm}{0} (kis) in chain_free_fun (kis1, f) end (* end of [CHAINcon] *) | ~CHAINnil () => () end // end of [chain_free_fun] (* ****** ****** *) fun{key:t0p;itm:vt0p} chain_search {n:nat} .. ( kis: !chain (key, itm, n) , k0: key , eqfn: eqfn key ) :<> Ptr = case+ kis of | CHAINcons (k, !i, !kis1) => let val keq = equal_key_key (k0, k, eqfn) in if keq then (fold@ kis; i) else let val ans = chain_search (!kis1, k0, eqfn) in fold@ kis; ans end // end of [if] end // end of [cons] | CHAINnil () => (fold@ kis; null) // end of [chain_search] (* ****** ****** *) fn{key:t0p;itm:vt0p} chain_insert {n:nat} ( kis: &chain (key,itm,n) >> chain (key,itm,n+1), k: key, i: itm ) :<> void = kis := CHAINcons (k, i, kis) // end of [chain_insert] (* ****** ****** *) stadef b2i = int_of_bool fun{key:t0p;itm:vt0p} chain_remove {n:nat} .. ( kis: &chain (key,itm,n) >> chain (key,itm,n-b2i b) , k0: key, eqfn: eqfn key, res: &itm? >> opt (itm, b) ) :<> #[b:bool | b2i b <= n] bool b = begin case+ kis of | CHAINcons (k, !i, !kis1) => let val keq = equal_key_key (k0, k, eqfn) in if keq then let val () = res := !i prval () = opt_some {itm} (res) val kis1 = !kis1 in free@ {key,itm}{n} (kis); kis := kis1; true end else let val ans = chain_remove {n-1} (!kis1, k0, eqfn, res) in fold@ kis; ans end // end of [if] end // end of [cons] | CHAINnil () => let prval () = opt_none {itm} (res) prval () = fold@ kis in false end // end of [nil] end // end of [chain_remove] fun{key:t0p;itm:vt0p} chain_foreach_vclo {v:view} {n:nat} {f:eff} .. ( pf: !v | kis: !chain (key, itm, n), f: &(!v | key, &itm) - void ) : void = begin case+ kis of | CHAINcons (k, !i, !kis1) => begin f (pf | k, !i); chain_foreach_vclo (pf | !kis1, f); fold@ kis end // end of [cons] | CHAINnil () => fold@ kis end // end of [chain_foreach_vclo] (* ****** ****** *) dataview hashtbl_v // it is just an array of chains (key:t@ype, itm:viewt@ype+, int(*sz*), int(*tot*), addr, addr) = | {sz,tot,n:nat} {l_beg,l_end:addr} hashtbl_v_cons (key, itm, sz+1, tot+n, l_beg, l_end) of (chain (key, itm, n) @ l_beg, hashtbl_v (key, itm, sz, tot, l_beg+chainsz, l_end)) | {l:addr} hashtbl_v_nil (key, itm, 0, 0, l, l) // end of [hashtbl_v] viewtypedef HASHTBL ( key: t0p, itm: vt0p , sz: int, tot: int , l_beg: addr, l_end: addr ) = @{ pfgc= free_gc_v (l_beg) , pftbl= hashtbl_v (key, itm, sz, tot, l_beg, l_end) , sz= size_t sz , tot= size_t tot , pbeg= ptr l_beg , hash= hash key , eqfn = eqfn key } // end of [HASHTBL] viewtypedef HASHTBL ( key: t0p, itm: vt0p ) = [ sz,tot:int;l_beg,l_end:addr;0 < sz; 0 <= tot ] HASHTBL (key, itm, sz, tot, l_beg, l_end) // end of [HASHTBL] extern typedef "HASHTBL_struct" = HASHTBL (void, void) (* ****** ****** *) extern castfn HASHTBLptr_get_hashtbl {key:t0p;itm:vt0p} {l:agz} ( ptbl: !HASHTBLptr (key, itm, l) ) :<> ( HASHTBL (key, itm) @ l , minus (HASHTBLptr (key, itm, l), HASHTBL (key, itm) @ l) | ptr l ) // end of [HASHTBLptr_get_hashtble] (* ****** ****** *) implement hashtbl_size {key,itm} (ptbl) = sz where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val sz = p->sz prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_size] implement hashtbl_total {key,itm} (ptbl) = tot where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val tot = p->tot prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_total] (* ****** ****** *) fun{key:t0p;itm:t0p} hashtbl_ptr_clear {sz,tot:nat} {l_beg,l_end:addr} .. ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) >> hashtbl_v (key, itm, sz, 0(*tot*), l_beg, l_end) | sz: size_t sz, p_beg: ptr l_beg ) :<> void = begin if sz > 0 then let prval hashtbl_v_cons (pf1, pf2) = pf val () = chain_free (!p_beg) val () = !p_beg := CHAINnil () val () = hashtbl_ptr_clear (pf2 | sz-1, p_beg+sizeof) prval () = pf := hashtbl_v_cons (pf1, pf2) in // empty end else let prval hashtbl_v_nil () = pf; prval () = pf := hashtbl_v_nil () in // empty end // end of [if] end // end of [hashtbl_ptr_clear] implement{key,itm} hashtbl_clear (ptbl) = () where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val () = hashtbl_ptr_clear (p->pftbl | p->sz, p->pbeg) val () = p->tot := (size1_of_int1)0 // reset it to zero prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_clear] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_clear_fun {sz,tot:nat} {l_beg,l_end:addr} .. ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) >> hashtbl_v (key, itm, sz, 0(*tot*), l_beg, l_end) | sz: size_t sz , p_beg: ptr l_beg , f: (&itm >> itm?) -<> void ) :<> void = begin if sz > 0 then let prval hashtbl_v_cons (pf1, pf2) = pf val () = chain_free_fun (!p_beg, f) val () = !p_beg := CHAINnil () val () = hashtbl_ptr_clear_fun (pf2 | sz-1, p_beg+sizeof, f) prval () = pf := hashtbl_v_cons (pf1, pf2) in // empty end else let prval hashtbl_v_nil () = pf; prval () = pf := hashtbl_v_nil () in // empty end // end of [if] end // end of [hashtbl_ptr_clear] implement{key,itm} hashtbl_clear_fun (ptbl, f) = () where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val () = hashtbl_ptr_clear_fun (p->pftbl | p->sz, p->pbeg, f) val () = p->tot := (size1_of_int1)0 // reset it to zero prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_clear] (* ****** ****** *) extern fun hashtbl_ptr_make {key:t0p;itm:vt0p} {sz:pos} (sz: size_t sz) :<> [l_beg,l_end:addr] @( free_gc_v l_beg , hashtbl_v (key, itm, sz, 0(*tot*), l_beg, l_end) | ptr l_beg ) = "atslib_hashtbl_ptr_make__chain" // end of [hashtbl_ptr_make] extern fun hashtbl_ptr_free {key:t0p;itm:vt0p} {sz:pos} {l_beg,l_end:addr} ( pf_gc: free_gc_v l_beg , pf_tbl: hashtbl_v (key, itm, sz, 0(*tot*), l_beg, l_end) | p_beg: ptr l_beg ) :<> void = "atslib_hashtbl_ptr_free__chain" // end of [hashtbl_ptr_free] (* ****** ****** *) extern prfun // HX: proof is omitted hashtbl_v_split {key:t0p;itm:vt0p} {sz,sz1,tot:nat | sz1 <= sz} {l_beg,l_end:addr} {ofs:int} ( pf_mul: MUL (sz1, chainsz, ofs) , pf_tbl: hashtbl_v (key, itm, sz, tot, l_beg, l_end) ) :<> [tot1:nat | tot1 <= tot] @( hashtbl_v (key, itm, sz1, tot1, l_beg, l_beg+ofs) , hashtbl_v (key, itm, sz-sz1, tot-tot1, l_beg+ofs, l_end) ) // end of [hashtbl_v_split] extern prfun // HX: proof is omitted hashtbl_v_unsplit {key:t0p;itm:vt0p} {sz1,sz2,tot1,tot2:nat} {l_beg,l_mid,l_end:addr} ( pf1: hashtbl_v (key, itm, sz1, tot1, l_beg, l_mid) , pf2: hashtbl_v (key, itm, sz2, tot2, l_mid, l_end) ) : hashtbl_v ( key, itm, sz1+sz2, tot1+tot2, l_beg, l_end ) // end of [hashtbl_v_unsplit] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_split {sz,sz1,tot:nat | sz1 <= sz} {l_beg,l_end:addr} ( pf_tbl: hashtbl_v (key, itm, sz, tot, l_beg, l_end) | p_beg: ptr l_beg, sz1: size_t sz1 ) :<> [tot1:nat | tot1 <= tot] [l_mid:addr] @( hashtbl_v (key, itm, sz1, tot1, l_beg, l_mid) , hashtbl_v (key, itm, sz-sz1, tot-tot1, l_mid, l_end) | ptr l_mid ) = let val (pf_mul | ofs) = mul2_size1_size1 (sz1, sizeof) prval (pf1_tbl, pf2_tbl) = hashtbl_v_split {key,itm} (pf_mul, pf_tbl) in (pf1_tbl, pf2_tbl | p_beg + ofs) end // end of [hashtbl_ptr_split] (* ****** ****** *) extern castfn size1_of_ulint (x: ulint):<> [i:nat] size_t i (* ****** ****** *) #define i2sz size1_of_int1 #define sz1mod mod1_size1_size1 (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_search_ofs {sz,ofs,tot:nat | ofs < sz} {l_beg,l_end:addr} ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) | p_beg: ptr l_beg, k0: key, eqfn: eqfn key, ofs: size_t ofs ) :<> Ptr (* null or pointing to the found item *) = let val (pf1, pf2 | p_mid) = hashtbl_ptr_split {sz,ofs,tot} (pf | p_beg, ofs) prval hashtbl_v_cons (pf21, pf22) = pf2 val p_itm = chain_search (!p_mid, k0, eqfn) prval pf2 = hashtbl_v_cons (pf21, pf22) prval () = pf := hashtbl_v_unsplit (pf1, pf2) in p_itm end // end of [hashtbl_ptr_search_ofs] implement{key,itm} hashtbl_search_ref (ptbl, k0) = let val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h); val ofs = sz1mod (h, p->sz) val [l:addr] p_itm = hashtbl_ptr_search_ofs (p->pftbl | p->pbeg, k0, p->eqfn, ofs) // end of [val] prval () = minus_addback (fpf, pf | ptbl) in p_itm end // end of [hashtbl_search_ref] implement{key,itm} hashtbl_search (ptbl, k0, res) = let val [l:addr] p_itm = hashtbl_search_ref (ptbl, k0) in if p_itm > null then let prval (fpf, pf) = __assert () where { extern praxi __assert (): (itm @ l - void, itm @ l) } // end of [prval] val () = res := !p_itm prval () = fpf (pf) prval () = opt_some {itm} (res) in true end else let prval () = opt_none {itm} (res) in false end // end of [if] end // end of [hashtbl_search] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_insert_ofs {sz,ofs,tot:nat | ofs < sz} {l_beg,l_end:addr} ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) >> hashtbl_v (key, itm, sz, tot+1, l_beg, l_end) | p_beg: ptr l_beg, k: key, i: itm, ofs: size_t ofs ) :<> void = let val (pf1, pf2 | p_mid) = hashtbl_ptr_split {sz,ofs,tot} (pf | p_beg, ofs) prval hashtbl_v_cons (pf21, pf22) = pf2 val ans = chain_insert (!p_mid, k, i) prval pf2 = hashtbl_v_cons (pf21, pf22) prval () = pf := hashtbl_v_unsplit (pf1, pf2) in // empty end // end of [hashtbl_ptr_insert_ofs] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_remove_ofs {sz,ofs,tot:nat | ofs < sz} {l_beg,l_end:addr} ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) >> hashtbl_v (key, itm, sz, tot-b2i b, l_beg, l_end) | p_beg: ptr l_beg, k0: key, eqfn: eqfn key, ofs: size_t ofs , res: &itm? >> opt (itm, b) ) :<> #[b:bool | b2i b <= tot] bool b = let val (pf1, pf2 | p_mid) = hashtbl_ptr_split {sz,ofs,tot} (pf | p_beg, ofs) prval hashtbl_v_cons (pf21, pf22) = pf2 val ans = chain_remove (!p_mid, k0, eqfn, res) prval pf2 = hashtbl_v_cons (pf21, pf22) prval () = pf := hashtbl_v_unsplit (pf1, pf2) in ans end // end of [hashtbl_ptr_remove_ofs] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_insert_chain {sz:pos;tot,n:nat} {l_beg,l_end:addr} .. ( pf: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) >> hashtbl_v (key, itm, sz, tot+n, l_beg, l_end) | sz: size_t sz , p_beg: ptr l_beg , kis: chain (key, itm, n) , hash: hash key ) :<> void = begin case+ kis of | ~CHAINcons (k, i, kis1) => let // insertion must be done in the reverse order! val () = hashtbl_ptr_insert_chain (pf | sz, p_beg, kis1, hash) val h = hash_key (k, hash) val h = size1_of_ulint (h) val [ofs:int] ofs = sz1mod (h, sz) val (pf1, pf2 | p_mid) = hashtbl_ptr_split {sz,ofs,tot+n-1} (pf | p_beg, ofs) prval hashtbl_v_cons (pf21, pf22) = pf2 val () = chain_insert (!p_mid, k, i) prval pf2 = hashtbl_v_cons (pf21, pf22) prval () = pf := hashtbl_v_unsplit (pf1, pf2) in // empty end // end of [cons] | ~CHAINnil () => () end // end of [hashtbl_ptr_insert_chain] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_relocate {sz1:nat;sz2:pos;tot1,tot2:nat} {l1_beg,l2_beg,l1_end,l2_end:addr} .. ( pf1: !hashtbl_v (key, itm, sz1, tot1, l1_beg, l1_end) >> hashtbl_v (key, itm, sz1, 0(*tot*), l1_beg, l1_end) , pf2: !hashtbl_v (key, itm, sz2, tot2, l2_beg, l2_end) >> hashtbl_v (key, itm, sz2, tot1+tot2, l2_beg, l2_end) | sz1: size_t sz1, sz2: size_t sz2 , p1_beg: ptr l1_beg, p2_beg: ptr l2_beg , hash: hash key ) :<> void = begin if sz1 > 0 then let prval hashtbl_v_cons (pf11, pf12) = pf1 val kis = !p1_beg; val () = !p1_beg := CHAINnil () val () = hashtbl_ptr_insert_chain (pf2 | sz2, p2_beg, kis, hash) val () = hashtbl_ptr_relocate (pf12, pf2 | sz1-1, sz2, p1_beg+sizeof, p2_beg, hash) prval () = pf1 := hashtbl_v_cons (pf11, pf12) in // empty end else let prval hashtbl_v_nil () = pf1; prval () = pf1 := hashtbl_v_nil () in // empty end // end of [if] end // end of [hashtbl_ptr_relocate] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_resize {l:agz} {sz_new:pos} ( ptbl: !HASHTBLptr (key, itm, l), sz_new: size_t sz_new ) :<> void = () where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val (pfgc2, pftbl2 | pbeg2) = hashtbl_ptr_make (sz_new) val () = hashtbl_ptr_relocate (p->pftbl, pftbl2 | p->sz, sz_new, p->pbeg, pbeg2, p->hash) // end of [val] val () = hashtbl_ptr_free (p->pfgc, p->pftbl | p->pbeg) prval () = p->pfgc := pfgc2 prval () = p->pftbl := pftbl2 val () = p->sz := sz_new val () = p->pbeg := pbeg2 prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_resize] (* ****** ****** *) %{^ #define HASHTBL_MINSZ 97 %} // end of [%{^] #define HASHTBL_MINSZ 97 // it is chosen, more or less, arbitrarily #define HASHTABLE_DOUBLE_FACTOR 5.0 #assert (HASHTABLE_DOUBLE_FACTOR > 2.0) #define HASHTABLE_HALF_FACTOR 0.5 #assert (HASHTABLE_HALF_FACTOR < 1.0) (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_resize_double {l:agz} ( ptbl: !HASHTBLptr (key, itm, l) ) :<> void = let val sz = hashtbl_size (ptbl) val sz = size1_of_size (sz) // casting: no-op in if sz > 0 then hashtbl_resize (ptbl, sz + sz) else () end // end of [hashtbl_resize_double] fn{key:t0p;itm:vt0p} hashtbl_resize_half {l:agz} ( ptbl: !HASHTBLptr (key, itm, l) ) :<> void = let val sz = hashtbl_size (ptbl) val sz = size1_of_size (sz) // casting: no-op val sz2 = sz / 2 in if sz2 >= HASHTBL_MINSZ then hashtbl_resize (ptbl, sz2) else () // end of [if] end // end of [hashtbl_resize_half] (* ****** ****** *) implement{key,itm} hashtbl_insert (ptbl, k, i) = () where { var ratio: double = 0.0 val (pf, fpf | p) = HASHTBLptr_get_hashtbl (ptbl) val tot1 = p->tot + 1 val () = ratio := double_of_size (tot1) / double_of_size (p->sz) val h = hash_key (k, p->hash) val h = size1_of_ulint (h); val ofs = sz1mod (h, p->sz) val () = hashtbl_ptr_insert_ofs (p->pftbl | p->pbeg, k, i, ofs) val () = p->tot := tot1 prval () = minus_addback (fpf, pf | ptbl) val () = if ratio >= HASHTABLE_DOUBLE_FACTOR then hashtbl_resize_double (ptbl) // end of [if] } // end of [hashtbl_insert] (* ****** ****** *) implement{key,itm} hashtbl_remove {l} (ptbl, k0, res) = ans where { var ratio: double = 1.0 val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h); val ofs = sz1mod (h, p->sz) val ans = hashtbl_ptr_remove_ofs (p->pftbl | p->pbeg, k0, p->eqfn, ofs, res) // end of [val] val () = ( if :(pf: HASHTBL (key, itm) @ l) => ans then let val tot1 = p->tot - 1 val () = ratio := double_of_size tot1 / double_of_size (p->sz) val () = p->tot := tot1 in // nothing end else () // end of [if] ) : void // end of [val] prval () = minus_addback (fpf, pf | ptbl) val () = if ratio <= HASHTABLE_HALF_FACTOR then hashtbl_resize_half (ptbl) // end of [if] } // end of [hashtbl_remove] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_foreach_vclo {v:view} {sz,tot:nat} {l_beg,l_end:addr} {f:eff} .. ( pfv: !v , pf_tbl: !hashtbl_v (key, itm, sz, tot, l_beg, l_end) | sz: size_t sz, p_beg: ptr l_beg, f: &(!v | key, &itm) - void ) : void = begin if sz > 0 then let prval hashtbl_v_cons (pf1_tbl, pf2_tbl) = pf_tbl val () = chain_foreach_vclo (pfv | !p_beg, f) val () = // segfault during typechecking if {v} is not provided!!! hashtbl_ptr_foreach_vclo {v} (pfv, pf2_tbl | sz-1, p_beg+sizeof, f) prval () = pf_tbl := hashtbl_v_cons (pf1_tbl, pf2_tbl) in // empty end // end of [if] end // end of [hashtbl_ptr_foreach_vclo] implement{key,itm} hashtbl_foreach_vclo {v} (pfv | ptbl, f) = () where { val (pf, fpf | p) = HASHTBLptr_get_hashtbl {key,itm} (ptbl) val () = begin hashtbl_ptr_foreach_vclo {v} (pfv, p->pftbl | p->sz, p->pbeg, f) end // end of [val] prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_foreach_vclo] implement{key,itm} hashtbl_foreach_cloref (tbl, f) = () where { val f = __cast (f) where { extern castfn __cast (f: (key, &itm) - void):<> (!unit_v | key, &itm) - void } // end of [val] typedef T = (!unit_v | key, &itm) - void val [l:addr] (pfbox | p_f) = cloref_get_view_ptr {T} (f) viewdef V = T @ l prval (pf, fpf) = __assert (pfbox) where { extern praxi __assert (_: vbox V): (V, V - void) } // end of [prval] prval pf0 = unit_v () val () = hashtbl_foreach_vclo {unit_v} (pf0 | tbl, !p_f) prval unit_v () = pf0 prval () = fpf (pf) } // end of [hashtbl_foreach_cloref] (* ****** ****** *) (* // some prime numbers 53, 97, 193, 389, 769, 1543, 3079, 6151, 12289, 24593, 49157, 98317, 196613, 393241, 786433, 1572869, 3145739, 6291469, 12582917, 25165843, 50331653, 100663319, 201326611, 402653189, 805306457, 1610612741 *) implement hashtbl_make {key,itm} (hash, eqfn) = hashtbl_make_hint {key,itm} (hash, eqfn, 0) // end of [hashtbl_make] (* ****** ****** *) implement{key,itm} hashtbl_listize (ptbl) = let typedef keyitm = @(key, itm) var res: List_vt keyitm = list_vt_nil () viewdef V = List_vt keyitm @ res var !p_clo = @lam ( pf: !V | k: key, x: &itm ) : void = (res := list_vt_cons ((k, x), res)) // end of [var] val () = hashtbl_foreach_vclo {V} (view@ res | ptbl, !p_clo) in list_vt_reverse (res) // list-reversing for the shadowing semantics end // end of [hashtbl_listize] implement{key,itm} hashtbl_listize_free {l} (ptbl) = kis where { typedef keyitm0 = @(key, itm?) viewtypedef keyitm = @(key, itm) val ptbl = __cast (ptbl) where { extern castfn __cast (x: HASHTBLptr (key, itm, l)): HASHTBLptr (key, itm?, l) } // end of [val] val kis = hashtbl_listize (ptbl) val () = hashtbl_free (ptbl) val kis = __cast (kis) where { extern castfn __cast {n:int} (x: list_vt (keyitm0, n)): list_vt (keyitm, n) } // end of [val] } // end of [hashtbl_listize_free] (* ****** ****** *) %{$ // // HX: shortcuts? yes. worth it? probably. // ats_ptr_type atslib_hashtbl_ptr_make__chain (ats_size_type sz) { ats_ptr_type pbeg ; /* ** HX: it is mandatory to initialize with zeros! */ pbeg = ATS_CALLOC(sz, sizeof(chain0_ptr)) ; return pbeg ; } // end of [atslib_hashtbl_ptr_make__chain] ats_ptr_type atslib_hashtbl_make_hint__chain ( ats_clo_ref_type hash, ats_clo_ref_type eqfn , ats_size_type hint ) { size_t sz ; HASHTBL_struct *ptbl ; void *pbeg ; ptbl = ATS_MALLOC(sizeof(HASHTBL_struct)) ; sz = ( hint > 0 ? hint : HASHTBL_MINSZ ) ; /* zeroing the allocated memory is mandatory! */ pbeg = ATS_CALLOC(sz, sizeof(chain0_ptr)) ; ptbl->atslab_sz = sz ; ptbl->atslab_tot = 0 ; ptbl->atslab_pbeg = pbeg ; ptbl->atslab_hash = hash ; ptbl->atslab_eqfn = eqfn ; return ptbl ; } // end of [atslib_hashtbl_make_hint__chain] %} // end of [%{$] (* ****** ****** *) %{$ ats_void_type atslib_hashtbl_free__chain (ats_ptr_type ptbl) { ATS_FREE(((HASHTBL_struct*)ptbl)->atslab_pbeg) ; ATS_FREE(ptbl) ; return ; } // end of [atslib_hashtbl_free__chain] ats_bool_type atslib_hashtbl_free_vt__chain (ats_ptr_type ptbl) { if (((HASHTBL_struct*)ptbl)->atslab_tot != 0) return ats_true_bool ; ATS_FREE(((HASHTBL_struct*)ptbl)->atslab_pbeg) ; ATS_FREE(ptbl) ; return ats_false_bool ; } // end of [atslib_hashtbl_free_vt__chain] %} // end of [%{$] (* ****** ****** *) (* end of [hashtable_chain.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funheap_binomial.dats0000664000175000017500000002453412223166162022173 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/funheap_binomial.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) (* ** binomial trees: ** btree(a, n) is for a binomial tree of rank(n) *) datatype btree (a:t@ype+, int(*rank*)) = | {n:nat} btnode (a, n) of (int (n), a, btreelst (a, n)) // end of [btree] and btreelst (a:t@ype+, int(*rank*)) = | {n:nat} btlst_cons (a, n+1) of (btree (a, n), btreelst (a, n)) | btlst_nil (a, 0) // end of [btreelst] (* ****** ****** *) fun{a:t@ype} btree_rank {n:nat} .<>. ( bt: btree (a, n) ) :<> int (n) = let val btnode (n, _, _) = bt in n end // end of [btree_rank] (* ****** ****** *) datatype bheap ( a:t@ype+, int(*rank*), int(*size*) ) = | {n:nat} bheap_nil (a, n, 0) of () | {n:nat}{p:int}{sz:nat}{n1:int | n1 > n} bheap_cons (a, n, p+sz) of (EXP2 (n, p) | btree (a, n), bheap (a, n1, sz)) // end of [bheap] (* ****** ****** *) fun{a:t@ype} btree_btree_merge {n:nat} .<>. ( bt1: btree (a, n) , bt2: btree (a, n) , cmp: cmp a ) :<> btree (a, n+1) = let val+ btnode (n, x1, bts1) = bt1 val+ btnode (n, x2, bts2) = bt2 val sgn = compare_elt_elt (x1, x2, cmp) in if sgn <= 0 then btnode (n+1, x1, btlst_cons (bt2, bts1)) else btnode (n+1, x2, btlst_cons (bt1, bts2)) // end of [if] end // end of [btree_btree_merge] (* ****** ****** *) fun{a:t@ype} btree_bheap_merge {sz:nat}{n,n1:nat | n <= n1}{p:int} .. ( pf: EXP2 (n, p) | bt: btree (a, n), n: int (n), hp: bheap (a, n1, sz) , cmp: cmp a ) :<> [n2:int | n2 >= min(n, n1)] bheap (a, n2, sz+p) = case+ hp of | bheap_nil () => bheap_cons (pf | bt, bheap_nil {a} {n+1} ()) // end of [bheap_nil] | bheap_cons (pf1 | bt1, hp1) => let val n1 = btree_rank (bt1) in if n < n1 then bheap_cons (pf | bt, hp) else if n > n1 then bheap_cons (pf1 | bt1, btree_bheap_merge (pf | bt, n, hp1, cmp)) else let prval () = exp2_ispos (pf1) prval () = exp2_isfun (pf, pf1) val bt = btree_btree_merge (bt, bt1, cmp) in btree_bheap_merge (EXP2ind (pf) | bt, n+1, hp1, cmp) end // end of [if] end (* end of [bheap_cons] *) // end of [btree_bheap_merge] (* ****** ****** *) fun{a:t@ype} bheap_bheap_merge {n1,n2:nat} {sz1,sz2:nat} .. ( hp1: bheap (a, n1, sz1) , hp2: bheap (a, n2, sz2) , cmp: cmp a ) :<> [n:int | n >= min(n1, n2)] bheap (a, n, sz1+sz2) = case+ hp1 of | bheap_nil () => hp2 | bheap_cons (pf1 | bt1, hp11) => ( case+ hp2 of | bheap_nil () => hp1 | bheap_cons (pf2 | bt2, hp21) => let // prval () = exp2_ispos (pf1) prval () = exp2_ispos (pf2) // val n1 = btree_rank (bt1) val n2 = btree_rank (bt2) in if n1 < n2 then bheap_cons (pf1 | bt1, bheap_bheap_merge (hp11, hp2, cmp)) else if n1 > n2 then bheap_cons (pf2 | bt2, bheap_bheap_merge (hp1, hp21, cmp)) else let prval () = exp2_isfun (pf1, pf2) val bt12 = btree_btree_merge (bt1, bt2, cmp) in btree_bheap_merge (EXP2ind (pf1) | bt12, n1+1, bheap_bheap_merge (hp11, hp21, cmp), cmp) end // end of [if] end (* end of [bheap_cons] *) ) // end of [bheap_cons] // end of [bheap_bheap_merge] (* ****** ****** *) fun{a:t@ype} bheap_find_min {n:nat}{sz:pos} .<>. ( hp0: bheap (a, n, sz), cmp: cmp a ) :<> a = let // fun find {n:nat}{sz:nat} .. ( hp: bheap (a, n, sz), x0: &a, cmp: cmp a ) :<> void = case+ hp of | bheap_cons (pf |bt, hp) => let prval () = exp2_ispos (pf) val+ btnode (_, x, _) = bt val () = if compare_elt_elt (x0, x, cmp) > 0 then (x0 := x) in find (hp, x0, cmp) end | bheap_nil () => () (* end of [find] *) // val+ bheap_cons (pf0 | bt0, hp1) = hp0 val+ btnode (_, x0, _) = bt0 var x0: a = x0 val () = find (hp1, x0, cmp) in x0 end // end of [bheap_find_min] (* ****** ****** *) fun{a:t@ype} bheap_remove_min {n:nat}{sz:pos} .<>. ( hp0: bheap (a, n, sz), cmp: cmp a ) :<> [ n1,n2,p:int | n1 >= n; n2 >= n;sz >= p ] ( EXP2 (n2, p) | bheap (a, n1, sz-p), btree (a, n2) ) = let val+ bheap_cons (pf0 | bt0, hp1) = hp0 val+ btnode (_, x0, _) = bt0 // // HX: [find] and [remove] can be merged into one // fun find {n:nat}{sz:nat} .. ( hp0: bheap (a, n, sz), x0: &a, pos: &Nat, cmp: cmp a ) :<> void = case+ hp0 of | bheap_cons (pf | bt, hp) => let prval () = exp2_ispos (pf) val+ btnode (_, x, _) = bt val sgn = compare_elt_elt (x0, x, cmp) val () = if sgn > 0 then (x0 := x; pos := pos+1) in find (hp, x0, pos, cmp) end // [bheap_cons] | bheap_nil () => () (* end of [find] *) // var x0: a = x0 and pos: Nat = 0 val () = find (hp1, x0, pos, cmp) // fun remove {n:nat}{sz:nat} {pos:nat} .. ( hp0: bheap (a, n, sz), pos: int (pos) , btmin: &btree(a, 0)? >> btree (a, n2) ) :<> #[ n1,n2,p:int | n1 >= n; n2 >= n; sz >= p ] ( EXP2 (n2, p) | bheap (a, n1, sz-p) ) = let // prval () = __assert () where { extern praxi __assert (): [sz > 0] void } // end of [prval] // val+ bheap_cons (pf | bt, hp) = hp0 prval () = exp2_ispos (pf) in if pos > 0 then let val (pfmin | hp) = remove (hp, pos-1, btmin) in (pfmin | bheap_cons (pf | bt, hp)) end else let val () = btmin := bt in (pf | hp) end // end of [if] end (* end of [remove] *) // var btmin: btree (a, 0)? val (pf | hp) = remove (hp0, pos, btmin) // in (pf | hp, btmin) end // end of [bheap_remove_min] (* ****** ****** *) assume heap_t0ype_type (a:t@ype) = [n,sz:nat] bheap (a, n, sz) // end of [heap_t0ype_type] (* ****** ****** *) implement{} funheap_make_nil {a} () = bheap_nil {a} {0} () (* ****** ****** *) local extern fun pow2 {n:nat} (n: int n) : [p:pos] (EXP2 (n, p) | size_t (p)) = "atslib_funheap_binomial_pow2" // end of [pow2] %{^ ats_size_type atslib_funheap_binomial_pow2 (ats_int_type n) { size_t res = 1 ; return (res << n) ; } // end of [atslib_funheap_binomial_pow2] %} // end of [%{^] in // in of [loca] implement{a} funheap_size (hp) = let // fun aux {n:nat}{sz:nat} .. (hp: bheap (a, n, sz)): size_t (sz) = case+ hp of | bheap_cons (pf | bt, hp) => let val btnode (n, _, _) = bt; val (pf1 | p) = pow2 (n) prval () = exp2_isfun (pf, pf1) in p + aux (hp) end // end of [bheap_cons] | bheap_nil () => 0 (* end of [aux] *) // in aux (hp) end // end of [funheap_size] end // end of [local] (* ****** ****** *) implement{a} funheap_insert (hp, x0, cmp) = let val bt = btnode (0, x0, btlst_nil ()) in hp := btree_bheap_merge (EXP2bas () | bt, 0, hp, cmp) end // end of [funheap_insert] (* ****** ****** *) implement funheap_is_empty {a} (hp) = ( case+ hp of | bheap_cons (_ | _, _) => false | bheap_nil () => true ) // end of [funheap_is_empty] implement funheap_isnot_empty {a} (hp) = ( case+ hp of | bheap_cons (_ | _, _) => true | bheap_nil () => false ) // end of [funheap_isnot_empty] (* ****** ****** *) implement{a} funheap_getmin (hp0, cmp, res) = let (* val () = ( print ("funheap_getmin: enter"); print_newline () ) // end of [val] *) in // case+ hp0 of | bheap_cons (pf0 | _, _) => let prval () = exp2_ispos (pf0) val () = res := bheap_find_min (hp0, cmp) prval () = opt_some {a} (res) in true end // end of [bheap_cons] | bheap_nil () => let prval () = opt_none {a} (res) in false end // end of [bheap_nil] // end // end of [funheap_getmin] (* ****** ****** *) implement{a} funheap_delmin (hp0, cmp, res) = let (* val () = ( print ("funheap_delmin: enter"); print_newline () ) // end of [val] *) in // case+ hp0 of | bheap_cons (pf0 | _, _) => let prval () = exp2_ispos (pf0) val (_(*pf*) | hp_new, btmin) = bheap_remove_min (hp0, cmp) val btnode (_, x, bts) = btmin val () = res := x prval () = opt_some {a} (res) val hp1 = loop (bts, bheap_nil) where { fun loop {n:nat}{sz:nat} .. ( bts: btreelst (a, n), hp: bheap (a, n, sz) ) :<> [sz:nat] bheap (a, 0, sz) = case+ bts of | btlst_cons (bt, bts) => let prval pf = exp2_istot () in loop (bts, bheap_cons (pf | bt, hp)) end // end of [btlst_cons] | btlst_nil () => hp // end of [loop] } // end of [val] val () = hp0 := bheap_bheap_merge (hp_new, hp1, cmp) in true end // end of [bheap_cons] | bheap_nil () => let prval () = opt_none {a} (res) in false end // end of [bheap_nil] // end of [case] // end // end of [funheap_delmin] (* ****** ****** *) implement{a} funheap_merge (hp1, hp2, cmp) = bheap_bheap_merge (hp1, hp2, cmp) // end of [funheap_merge] (* ****** ****** *) (* end of [funheap_binomail.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funset_listord.dats0000664000175000017500000002536712223166162021744 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional map implementation based on ordered lists ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May 18, 2011 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload _(*anon*) = "prelude/DATS/list.dats" (* ****** ****** *) staload "libats/SATS/funset_listord.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{elt} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) assume set_t0ype_type (elt: t@ype) = List (elt) (* ****** ****** *) // // HX: // a set is represented as a sorted list in descending order; // note that descending order is chosen to faciliate set comparison // (* ****** ****** *) implement{} funset_make_nil () = list_nil () implement{a} funset_make_sing (x) = list_cons (x, list_nil) implement{a} funset_make_list (xs, cmp) = let // typedef env = cmp(a) // fn fcmp (x: a, y: a, cmp: !env):<> int = cmp (x, y) val xs = list_mergesort {env} (xs, fcmp, cmp) // [xs] is ascending! // fun loop1 {m:pos} .. ( xs: list_vt (a, m), ys: List_vt (a), cmp: cmp a ) :<> List_vt (a) = let val- list_vt_cons (x, !p_xs) = xs val xs1 = !p_xs val () = !p_xs := ys prval () = fold@ (xs) in loop2 (x, xs1, xs, cmp) end // end of [loop1] and loop2 {n:nat} .. ( x0: a, xs: list_vt (a, n), ys: List_vt (a), cmp: cmp a ) :<> List_vt (a) = case+ xs of | list_vt_cons (x, !p_xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let // HX: [xs] is ascending! prval () = fold@ (xs) in loop1 (xs, ys, cmp) end else let val xs1 = !p_xs val () = free@ {a}{0} (xs) in loop2 (x0, xs1, ys, cmp) end // end of [if] end (* end of [list_vt_cons] *) | ~list_vt_nil () => ys // end of [loop2] in // case+ xs of | list_vt_cons _ => let prval () = fold@ {a} (xs) val ys = loop1 (xs, list_vt_nil, cmp) in list_of_list_vt (ys) end // end of [list_vt_cons] | ~list_vt_nil () => list_nil () // end // end of [funset_make_list] (* ****** ****** *) implement{a} funset_size (xs) = size1_of_int1 (list_length (xs)) (* ****** ****** *) implement{a} funset_is_member (xs, x0, cmp) = let fun aux {n:nat} .. (xs: list (a, n)): bool = case+ xs of | list_cons (x, xs) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn > 0 then false else (if sgn < 0 then aux (xs) else true) end // end of [list_cons] | list_nil () => false // end of [aux] in aux (xs) end // end of [funset_is_member] implement{a} funset_isnot_member (xs, x0, cmp) = not (funset_is_member (xs, x0, cmp)) (* ****** ****** *) implement{a} funset_insert (xs, x0, cmp) = let fun aux {n:nat} .. ( xs: list (a, n), flag: &int ) : List (a) = case+ xs of | list_cons (x, xs1) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn > 0 then let val () = flag := flag + 1 in list_cons (x0, xs) end else if sgn < 0 then let val flag0 = flag val xs1 = aux (xs1, flag) in if flag = flag0 then xs else list_cons (x, xs1) end else xs // end of [if] end // end of [list_cons] | list_nil () => let val () = flag := flag + 1 in list_cons (x0, list_nil) end // end of [val] // end of [val] var flag: int = 0 val () = xs := aux (xs, flag) in if flag = 0 then true else false end // end of [funset_insert] (* ****** ****** *) implement{a} funset_remove (xs, x0, cmp) = let fun aux {n:nat} .. ( xs: list (a, n), flag: &int ) : List (a) = case xs of | list_cons (x, xs1) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn > 0 then xs else if sgn < 0 then let val flag0 = flag val xs1 = aux (xs1, flag) in if flag = flag0 then xs else list_cons (x, xs1) end else let val () = flag := flag + 1 in xs1 end (* end of [if] *) end // end of [list_cons] | list_nil () => list_nil () // end of [aux] var flag: int = 0 val () = xs := aux (xs, flag) in if flag > 0 then true else false end // end of [funset_remove] (* ****** ****** *) implement{a} funset_union (xs1, xs2, cmp) = let fun aux // non-tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : List (a) = case xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then list_cons (x1, aux (xs11, xs2)) else if sgn < 0 then list_cons (x2, aux (xs1, xs21)) else list_cons (x1, aux (xs11, xs21)) // end of [if] end // end of [list_cons] | list_nil () => xs1 ) // end of [list_cons] | list_nil () => xs2 in aux (xs1, xs2) end // end of [funset_union] (* ****** ****** *) implement{a} funset_intersect (xs1, xs2, cmp) = let fun aux // non-tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : List (a) = case xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then aux (xs11, xs2) else if sgn < 0 then aux (xs1, xs21) else list_cons (x1, aux (xs11, xs21)) // end of [if] end // end of [list_cons] | list_nil () => list_nil () ) // end of [list_cons] | list_nil () => list_nil () in aux (xs1, xs2) end // end of [funset_intersect] (* ****** ****** *) implement{a} funset_diff (xs1, xs2, cmp) = let fun aux // non-tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : List (a) = case xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then list_cons (x1, aux (xs11, xs2)) else if sgn < 0 then aux (xs1, xs21) else aux (xs11, xs21) // end of [if] end // end of [list_cons] | list_nil () => xs1 ) // end of [list_cons] | list_nil () => xs2 in aux (xs1, xs2) end // end of [funset_diff] (* ****** ****** *) implement{a} funset_symdiff (xs1, xs2, cmp) = let fun aux // non-tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : List (a) = case xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then list_cons (x1, aux (xs11, xs2)) else if sgn < 0 then list_cons (x2, aux (xs1, xs21)) else aux (xs11, xs21) // end of [if] end // end of [list_cons] | list_nil () => xs1 ) // end of [list_cons] | list_nil () => xs2 in aux (xs1, xs2) end // end of [funset_symdiff] (* ****** ****** *) implement{a} funset_is_subset (xs1, xs2, cmp) = let fun aux // tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : bool = case+ xs1 of | list_cons (x1, xs11) => ( case+ xs2 of | list_cons (x2, xs21) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then false else if sgn < 0 then aux (xs1, xs21) else aux (xs11, xs21) end | list_nil () => false ) // end of [list_cons] | list_nil () => true in aux (xs1, xs2) end // end of [funset_is_subset] implement{a} funset_is_equal (xs1, xs2, cmp) = let fun aux // tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : bool = ( case+ xs1 of | list_cons (x1, xs1) => ( case+ xs2 of | list_cons (x2, xs2) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn = 0 then aux (xs1, xs2) else false end | list_nil () => false ) // end of [list_cons] | list_nil () => (case+ xs2 of | list_cons _ => false | list_nil () => true ) // end of [list_nil] ) // end of [aux] in aux (xs1, xs2) end // end of [funset_is_equal] (* ****** ****** *) implement{a} funset_compare (xs1, xs2, cmp) = let // fun aux // tail-recursive {n1,n2:nat} .. ( xs1: list (a, n1), xs2: list (a, n2) ) : int = ( case+ xs1 of | list_cons (x1, xs1) => ( case+ xs2 of | list_cons (x2, xs2) => let val sgn = compare_elt_elt (x1, x2, cmp) in if sgn > 0 then 1 else ( if sgn < 0 then ~1 else aux (xs1, xs2) ) // end of [if] end // end of [list_cons] | list_nil () => 1 ) // end of [list_cons] | list_nil () => ( case+ xs2 of list_cons _ => ~1 | list_nil _ => 0 ) ) // end of [aux] // in aux (xs1, xs2) end // end of [funset_compare] (* ****** ****** *) implement{a} funset_foreach_funenv {v}{vt} (pf | xs, f, env) = ( case+ xs of | list_cons (x, xs) => let val () = f (pf | x, env) in funset_foreach_funenv (pf | xs, f, env) end // end of [list_cons] | list_nil () => () ) // end of [funset_foreach_funenv] (* ****** ****** *) implement{a} funset_listize (xs) = list_copy (xs) (* ****** ****** *) (* end of [funset_listord.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funralist_nested.dats0000664000175000017500000002462312223166162022243 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional random-access list implementation based on nested datatypes ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in DML (circa. 2000) ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libats/SATS/funralist_nested.sats" (* ****** ****** *) typedef P (a1:t@ype) (a2:t@ype) = '(a1, a2) datatype ralist (a:t@ype+, int) = | {n:pos} RAevn (a, n+n) of ralist (P a a, n) | {n:nat} RAodd (a, n+n+1) of (a, ralist (P a a, n)) | RAnil (a, 0) // end of [ralist] (* ****** ****** *) macdef P x0 x1 = '( ,(x0), ,(x1) ) (* ****** ****** *) assume ralist_t0ype_int_type (a:t@ype, n:int) = ralist (a, n) (* ****** ****** *) implement{} funralist_make_nil {a} () = RAnil () (* ****** ****** *) implement{a} funralist_length (xs) = length (xs) where { fun{a:t@ype} length {n:nat} .. (xs: ralist (a, n)):<> int n = let typedef a2 = P a a in case+ xs of | RAevn xxs => 2 * length (xxs) | RAodd (_, xxs) => 2 * length (xxs) + 1 | RAnil () => 0 end // end of [length] } // end of [funralist_length] (* ****** ****** *) implement{a} funralist_cons (x0, xs) = cons (x0, xs) where { fun{a:t@ype} cons {n:nat} .. (x0: a, xs: ralist (a, n)):<> ralist (a, n+1) = let typedef a2 = P a a in case+ xs of | RAevn xxs => RAodd (x0, xxs) | RAodd (x, xxs) => RAevn (cons (P x0 x, xxs)) | RAnil _ => RAodd (x0, RAnil ()) end // end of [cons] } // end of [funralist_cons] (* ****** ****** *) implement{a} funralist_uncons (xs, x0) = uncons (xs, x0) where { fun{a:t@ype} uncons {n:pos} .. (xs: ralist (a, n), x0: &a? >> a) :<> ralist (a, n-1) = let typedef a2 = P a a in case+ xs of | RAevn xxs => let var xx0: a2 // uninitialized val xxs = uncons (xxs, xx0); val () = x0 := xx0.0 in RAodd {a} (xx0.1, xxs) end // end of [RAevn] | RAodd (x, xxs) => let val () = x0 := x in case+ xxs of RAnil _ => RAnil () | _ =>> RAevn xxs end // end of [RAodd] end // end of [uncons] } // end of [funralist_uncons] (* ****** ****** *) implement{a} funralist_head (xs) = head (xs) where { fun{a:t@ype} head {n:pos} .. (xs: ralist (a, n)):<> a = let typedef a2 = P a a in case+ xs of | RAevn xxs => let val xx = funralist_head xxs in xx.0 end | RAodd (x, _) => x end // end of [head] } // end of [funralist_head] (* ****** ****** *) implement{a} funralist_tail (xs) = tail (xs) where { fun{a:t@ype} tail {n:pos} .. (xs: ralist (a, n)):<> ralist (a, n-1) = let typedef a2 = P a a in case+ xs of | RAevn xxs => let var xx: a2 // uninitialized val xxs = funralist_uncons (xxs, xx) in RAodd (xx.1, xxs) end // end of [RAevn] | RAodd (_, xxs) => begin case+ xxs of RAnil () => RAnil () | _ =>> RAevn xxs end // end of [RAodd] end // end of [tail] } // end of [funralist_tail] (* ****** ****** *) implement{a} funralist_lookup (xs, i) = lookup (xs, i) where { fun{a:t@ype} lookup {n,i:nat | i < n} .. (xs: ralist (a, n), i: int i):<> a = let typedef a2 = P a a in case+ xs of | RAevn xxs => let val x01 = lookup (xxs, nhalf i) in if i nmod 2 = 0 then x01.0 else x01.1 end // end of [RAevn] | RAodd (x, xxs) => begin if i = 0 then x else let val x01 = lookup (xxs, nhalf (i-1)) in if i nmod 2 = 0 then x01.1 else x01.0 end // end of [if] end // end of [RAodd] end // end of [lookup] } // end of [funralist_lookup] (* ****** ****** *) // // Here is an example of constructing linear closures explicitly // dataviewtype closure_ (a:t@ype) = {param: viewtype} CLOSURE_ (a) of (param, (param, a) - a) // end of [closure_] fn{a:t@ype} cloapp (c: closure_ a, x: a):<> a = let val+ ~CLOSURE_ {..} {param} (p, f) = c; val f = f: (param, a) - a in f (p, x) end // end of [cloapp] fun{a:t@ype} fupdate {n,i:nat | i < n} .. (xs: ralist (a, n), i: int i, c: closure_ a):<> ralist (a, n) = let fn f0 (c: closure_ a, xx: P a a):<> P a a = '(cloapp (c, xx.0), xx.1) fn f1 (c: closure_ a, xx: P a a):<> P a a = '(xx.0, cloapp (c, xx.1)) in case+ xs of | RAevn xxs => let val i2 = i / 2; val parity = i - (i2 + i2) in if parity = 0 then begin RAevn (fupdate

(xxs, i2, CLOSURE_ {P a a} (c, f0))) end else begin RAevn (fupdate

(xxs, i2, CLOSURE_ {P a a} (c, f1))) end // end of [if] end // end of [RAevn] | RAodd (x, xxs) => begin if i = 0 then RAodd (cloapp (c, x), xxs) else let val i1 = i - 1; val i2 = i1 / 2; val parity = i1 - (i2 + i2) in if parity = 0 then begin RAodd (x, fupdate

(xxs, i2, CLOSURE_ {P a a} (c, f0))) end else begin RAodd (x, fupdate

(xxs, i2, CLOSURE_ {P a a} (c, f1))) end // end of [if] end // end of [if] end // end of [RAodd] end // end of [fupdate] implement{a} funralist_update (xs, i, x) = let val f0 = lam (x_box: box_vt a, _: a): a = let val+ ~box_vt (x) = x_box in x end in fupdate (xs, i, CLOSURE_ (box_vt x, f0)) end // end of [funralist_update] (* ****** ****** *) local fun{a:t@ype} foreach {v:view} {n:nat} {f:eff} .. ( pf0: !v | xs: ralist (a, n), f: (!v | a) - void ) : void = let extern fun donothing ():<> void = "atspre_donothing" in case+ xs of | RAnil () => () | RAevn xxs => let var !p_f2 with pf_f2 = @lam (pf0: !v | xx: P a a): void = (f (pf0 | xx.0); f (pf0 | xx.1)) typedef clo_type = (!v | P a a) - void typedef cloref_type = (!v | P a a) - void val f2 = __encode (pf_f2 | p_f2) where { // cutting a corner here! extern castfn __encode (pf: !clo_type @ p_f2 | p: ptr p_f2):<> cloref_type } // end of [val] val () = foreach

(pf0 | xxs, f2) in donothing () // HX-2011-02-26: prevent tail-recursion optimization end // end of [RAevn] | RAodd (x, xxs) => let val () = f (pf0 | x) in case+ xxs of | RAnil () => () | _ =>> let var !p_f2 with pf_f2 = @lam (pf0: !v | xx: P a a): void = (f (pf0 | xx.0); f (pf0 | xx.1)) typedef clo_type = (!v | P a a) - void typedef cloref_type = (!v | P a a) - void val f2 = __encode (pf_f2 | p_f2) where { // cutting a corner here! extern castfn __encode (pf: !clo_type @ p_f2 | p: ptr p_f2):<> cloref_type } // end of [val] val () = foreach

(pf0 | xxs, f2) in donothing () // HX-2011-02-26: prevent tail-recursion optimization end // end of [_] end // end of [RAodd] end // end of [foreach] in // in of [local] implement{a} funralist_foreach_vcloptr {v} {n} {f:eff} (pf0 | xs, f) = let typedef cloref_type = (!v | a) - void viewtypedef cloptr_type = (!v | a) - void val f = __cast (f) where { extern castfn __cast (f: !cloptr_type):<> cloref_type } // end of [val] in foreach (pf0 | xs, f) end // end of [funralist_foreach_vcloptr] end // end of [local] (* ****** ****** *) implement{a} funralist_foreach_vclo {v} {n} {f:eff} (pf0 | xs, f) = let typedef clo_type = (!v | a) - void viewtypedef cloptr_type = (!v | a) - void val f = __encode (view@ f | &f) where { extern castfn __encode {l:addr} (pf: !clo_type @ l | p: ptr l):<> cloptr_type } // end of [where] val () = funralist_foreach_vcloptr {v} (pf0 | xs, f) val _ptr = __decode (f) where { extern castfn __decode (f: cloptr_type):<> ptr // HX: this matches [__encode] } // end of [val] in // empty end // end of [funralist_foreach_vclo] implement{a} funralist_foreach_cloptr {n} {f:eff} (xs, f) = () where { // viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = funralist_foreach_vcloptr {unit_v} (pfu | xs, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [funralist_foreach_cloptr] implement{a} funralist_foreach_cloref {n} {f:eff} (xs, f) = let viewtypedef cloptr_type = (!unit_v | a) - void val f = __encode (f) where { extern castfn __encode (f: (a) - void):<> cloptr_type } // end of [val] prval pfu = unit_v () val () = funralist_foreach_vcloptr (pfu | xs, f) prval unit_v () = pfu val _ptr = __decode (f) where { extern castfn __decode (f: cloptr_type):<> ptr } // end of [val] in // nothing end // end of [funralist_foreach_cloref] (* ****** ****** *) (* end of [funralist_nested.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linheap_binomial.dats0000664000175000017500000003554012223166162022164 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi *) (* Authoremail: hwxi AT cs DOT bu DOT edu *) (* Start time: November, 2011 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/linheap_binomial.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) (* ** binomial trees: ** btree(a, n) is for a binomial tree of rank(n) *) dataviewtype btree (a:viewt@ype+, int(*rank*)) = | {n:nat} btnode (a, n) of (int (n), a, btreelst (a, n)) // end of [btree] and btreelst (a:viewt@ype+, int(*rank*)) = | {n:nat} btlst_cons (a, n+1) of (btree (a, n), btreelst (a, n)) | btlst_nil (a, 0) // end of [btreelst] (* ****** ****** *) fun{a:vt0p} btree_rank {n:nat} .<>. ( bt: !btree (a, n) ) :<> int (n) = let val btnode (n, _, _) = bt in fold@ (bt) ; n end // end of [btree_rank] fun{a:t@ype} btreelst_free {n:nat} .. (bts: btreelst (a, n)):<> void = case+ bts of | ~btlst_cons (bt, bts) => let val ~btnode (_, _, bts1) = bt in btreelst_free (bts1); btreelst_free (bts) end | ~btlst_nil () => () // end of [btreelst_free] (* ****** ****** *) dataviewtype bheap ( a:viewt@ype+, int(*rank*), int(*size*) ) = | {n:nat} bheap_nil (a, n, 0) of () | {n:nat}{p:int}{sz:nat}{n1:int | n1 > n} bheap_cons (a, n, p+sz) of (EXP2 (n, p) | btree (a, n), bheap (a, n1, sz)) // end of [bheap] (* ****** ****** *) fun{a:t@ype} bheap_free {n:nat}{sz:nat} .. (hp: bheap (a, n, sz)):<> void = case+ hp of | ~bheap_cons (pf | bt, hp) => let prval () = exp2_ispos (pf) val ~btnode (_, _, bts) = bt in btreelst_free (bts); bheap_free (hp) end | ~bheap_nil () => () // end of [bheap_free] (* ****** ****** *) fun{a:vt0p} btree_btree_merge {n:nat} .<>. ( bt1: btree (a, n) , bt2: btree (a, n) , cmp: cmp a ) :<> btree (a, n+1) = let val btnode (!p_n1, !p_x1, !p_bts1) = bt1 val btnode (!p_n2, !p_x2, !p_bts2) = bt2 val sgn = compare_elt_elt (!p_x1, !p_x2, cmp) in if sgn <= 0 then let prval () = fold@ (bt2) val () = !p_n1 := !p_n1 + 1 val () = !p_bts1 := btlst_cons (bt2, !p_bts1) in fold@ (bt1); bt1 end else let prval () = fold@ (bt1) val () = !p_n2 := !p_n2 + 1 val () = !p_bts2 := btlst_cons (bt1, !p_bts2) in fold@ (bt2); bt2 end // end of [if] end // end of [btree_btree_merge] (* ****** ****** *) fun{a:vt0p} btree_bheap_merge {sz:nat}{n,n1:nat | n <= n1}{p:int} .. ( pf: EXP2 (n, p) | bt: btree (a, n), n: int (n), hp: bheap (a, n1, sz) , cmp: cmp a ) :<> [n2:int | n2 >= min(n, n1)] bheap (a, n2, sz+p) = case+ hp of | ~bheap_nil () => bheap_cons (pf | bt, bheap_nil {a} {n+1} ()) // end of [bheap_nil] | bheap_cons (pf1 | !p_bt1, !p_hp1) => let val n1 = btree_rank (!p_bt1) in if n < n1 then let prval () = fold@ (hp) in bheap_cons {a} (pf | bt, hp) end else if n > n1 then let val () = !p_hp1 := btree_bheap_merge (pf | bt, n, !p_hp1, cmp) prval () = fold@ (hp) in hp end else let prval () = exp2_ispos (pf1) prval () = exp2_isfun (pf, pf1) val bt1 = !p_bt1 val bt = btree_btree_merge (bt, bt1, cmp) val hp1 = !p_hp1 val () = free@ {a}{0}{0}{0}{1} (hp) in btree_bheap_merge (EXP2ind (pf) | bt, n+1, hp1, cmp) end // end of [if] end (* end of [bheap_cons] *) // end of [btree_bheap_merge] (* ****** ****** *) fun{a:vt0p} bheap_bheap_merge {n1,n2:nat} {sz1,sz2:nat} .. ( hp1: bheap (a, n1, sz1) , hp2: bheap (a, n2, sz2) , cmp: cmp a ) :<> [n:int | n >= min(n1, n2)] bheap (a, n, sz1+sz2) = case+ hp1 of | ~bheap_nil () => hp2 | bheap_cons (pf1 | !p_bt1, !p_hp11) => ( case+ hp2 of | ~bheap_nil () => (fold@ (hp1); hp1) | bheap_cons (pf2 | !p_bt2, !p_hp21) => let // prval () = exp2_ispos (pf1) prval () = exp2_ispos (pf2) // val n1 = btree_rank (!p_bt1) and n2 = btree_rank (!p_bt2) in if n1 < n2 then let prval () = fold@ (hp2) val () = !p_hp11 := bheap_bheap_merge (!p_hp11, hp2, cmp) prval () = fold@ (hp1) in hp1 end else if n1 > n2 then let prval () = fold@ (hp1) val () = !p_hp21 := bheap_bheap_merge (hp1, !p_hp21, cmp) prval () = fold@ (hp2) in hp2 end else let prval () = exp2_isfun (pf1, pf2) val bt12 = btree_btree_merge (!p_bt1, !p_bt2, cmp) val hp11 = !p_hp11 and hp21 = !p_hp21 val () = free@ {a}{0}{0}{0}{1} (hp1) val () = free@ {a}{0}{0}{0}{1} (hp2) in btree_bheap_merge (EXP2ind (pf1) | bt12, n1+1, bheap_bheap_merge (hp11, hp21, cmp), cmp) end // end of [if] end (* end of [bheap_cons] *) ) // end of [bheap_cons] // end of [bheap_bheap_merge] (* ****** ****** *) local staload UN = "prelude/SATS/unsafe.sats" staload _(*anon*) = "prelude/DATS/unsafe.dats" in // in of [local] fun{a:vt0p} bheap_search_ref {n:nat}{sz:pos} .<>. ( hp0: !bheap (a, n, sz), cmp: cmp a ) :<> ptr = let // fun search {n:nat}{sz:nat}{l:addr} .. ( hp0: !bheap (a, n, sz), p_x0: ptr l, cmp: cmp a ) :<> ptr = case+ hp0 of | bheap_cons (pf | !p_bt, !p_hp) => let prval () = exp2_ispos (pf) val btnode (_, !p_x, _) = !p_bt prval (pfat, fpf) = __assert () where { extern praxi __assert (): (a@l, a@l - void) } // end of [prval] val sgn = compare_elt_elt (!p_x0, !p_x, cmp) prval () = fpf (pfat) prval () = fold@ (!p_bt) val res = ( if sgn > 0 then search (!p_hp, p_x, cmp) else search (!p_hp, p_x0, cmp) ) : ptr // end of [val] prval () = fold@ (hp0) in res end // end of [bheap_cons] | bheap_nil () => let prval () = fold@ (hp0) in p_x0 end // end of [bheap_nil] (* end of [search] *) // val+ bheap_cons (pf0 | !p_bt0, !p_hp1) = hp0 val+ btnode (_, !p_x0, _) = !p_bt0 prval () = fold@ (!p_bt0) val res = search (!p_hp1, p_x0, cmp) prval () = fold@ (hp0) in res end // end of [bheap_search_ref] (* ****** ****** *) fun{a:vt0p} bheap_remove {n:nat}{sz:pos} .<>. ( hp0: &bheap (a, n, sz) >> bheap (a, n1, sz-p) , cmp: cmp a ) :<> #[ n1,n2,p:int | n1 >= n; n2 >= n; sz >= p ] ( EXP2 (n2, p) | btree (a, n2) ) = let // // HX: [search] and [remove] can be merged into one // fun search {n:nat}{sz:nat} .. ( hp0: !bheap (a, n, sz), x0: &a, pos: &Nat, cmp: cmp a ) :<> void = let in case+ hp0 of | bheap_cons (pf | !p_bt, !p_hp) => let prval () = exp2_ispos (pf) val+ btnode (_, !p_x, _) = !p_bt prval () = __assert (p_x) where { extern praxi __assert {l:addr} (p: ptr l): [l > null] void } // end of [prval] val sgn = compare_elt_elt (x0, !p_x, cmp) val () = if sgn > 0 then ($UN.ptrset (&x0, $UN.ptrget(p_x)); pos := pos+1) prval () = fold@ (!p_bt) val () = search (!p_hp, x0, pos, cmp) prval () = fold@ (hp0) in // nothing end // [bheap_cons] | bheap_nil () => fold@ (hp0) end // end of [search] // val+ bheap_cons (pf0 | !p_bt0, !p_hp1) = hp0 val+ btnode (_, !p_x, _) = !p_bt0 prval () = __assert (p_x) where { extern praxi __assert {l:addr} (p: ptr l): [l > null] void } // end of [prval] prval () = fold@ {a} (!p_bt0) var x0: a = $UN.ptrget (p_x) and pos: Nat = 0 val () = search (!p_hp1, x0, pos, cmp) prval () = __clear (x0) where { extern praxi __clear (x: &a >> a?): void } // end of [prval] prval () = fold@ {a} (hp0) // fun remove {n:nat}{sz:nat} {pos:nat} .. ( hp0: &bheap (a, n, sz) >> bheap (a, n1, sz-p) , pos: int (pos) , btmin: &btree(a, 0)? >> btree (a, n2) ) :<> #[ n1,n2,p:int | n1 >= n; n2 >= n; sz >= p ] ( EXP2 (n2, p) | void ) = let // prval () = __assert () where { extern praxi __assert (): [sz > 0] void } // end of [prval] // val+ bheap_cons (pf | !p_bt, !p_hp) = hp0 prval () = exp2_ispos (pf) in if pos > 0 then let val (pfmin | ()) = remove (!p_hp, pos-1, btmin) prval () = fold@ (hp0) in (pfmin | ()) end else let val () = btmin := !p_bt val hp = !p_hp val () = free@ {a}{0}{0}{0}{1} (hp0) val () = hp0 := hp in (pf | ()) end // end of [if] end (* end of [remove] *) // var btmin: btree (a, 0)? val (pf | ()) = remove (hp0, pos, btmin) // in (pf | btmin) end // end of [bheap_remove] end // end of [local] (* ****** ****** *) assume heap_viewt0ype_viewtype (a:vt0p) = [n,sz:nat] bheap (a, n, sz) // end of [heap_viewt0ype_viewtype] (* ****** ****** *) implement{} linheap_make_nil {a} () = bheap_nil {a} {0} () (* ****** ****** *) local extern fun pow2 {n:nat} (n: int n) : [p:pos] (EXP2 (n, p) | size_t (p)) = "atslib_linheap_binomial_pow2" // end of [pow2] %{^ ats_size_type atslib_linheap_binomial_pow2 (ats_int_type n) { size_t res = 1 ; return (res << n) ; } // end of [atslib_linheap_binomial_pow2] %} // end of [%{^] in // in of [loca] implement{a} linheap_size (hp0) = let // fun aux {n:nat}{sz:nat} .. (hp0: !bheap (a, n, sz)): size_t (sz) = case+ hp0 of | bheap_cons (pf | !p_bt, !p_hp) => let val n = btree_rank (!p_bt); val (pf1 | p) = pow2 (n) prval () = exp2_isfun (pf, pf1) val sz = p + aux (!p_hp) in fold@ (hp0); sz end // end of [bheap_cons] | bheap_nil () => (fold@ (hp0); size1_of_int1(0)) (* end of [aux] *) // in aux (hp0) end // end of [linheap_size] end // end of [local] (* ****** ****** *) implement linheap_is_empty {a} (hp) = ( case+ hp of | bheap_cons (_ | _, _) => (fold@ (hp); false) | bheap_nil {a}{n} () => (fold@ {a}{n} (hp); true) ) // end of [linheap_is_empty] implement linheap_isnot_empty {a} (hp) = ( case+ hp of | bheap_cons (_ | _, _) => (fold@ (hp); true) | bheap_nil {a}{n} () => (fold@ {a}{n} (hp); false) ) // end of [linheap_isnot_empty] (* ****** ****** *) implement{a} linheap_insert (hp, x0, cmp) = let val bt = btnode (0, x0, btlst_nil ()) in hp := btree_bheap_merge (EXP2bas () | bt, 0, hp, cmp) end // end of [linheap_insert] (* ****** ****** *) implement{a} linheap_getmin (hp0, cmp, res) = let val p_min = linheap_getmin_ref (hp0, cmp) // end of [val] val [l:addr] p_min = ptr1_of_ptr (p_min) in // if p_min > null then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (a @ l, a @ l - void) } // end of [prval] val () = res := !p_min prval () = fpf (pf) prval () = opt_some {a} (res) in true end else let prval () = opt_none {a} (res) in false end // end of [if] // end // end of [linheap_getmin] implement{a} linheap_getmin_ref (hp0, cmp) = let (* val () = ( print ("linheap_getmin_ref: enter"); print_newline () ) // end of [val] *) in // case+ hp0 of | bheap_cons (pf | _, _) => let prval () = exp2_ispos (pf); prval () = fold@ (hp0) in bheap_search_ref (hp0, cmp) end // end of [bheap_cons] | bheap_nil {a}{n} () => (fold@ {a}{n} (hp0); null) // end // end of [linheap_getmin_ref] (* ****** ****** *) local staload _(*anon*) = "prelude/DATS/list_vt.dats" in // in of [local] implement{a} linheap_delmin (hp, cmp, res) = let (* val () = ( print ("linheap_delmin: enter"); print_newline () ) // end of [val] *) in // case+ hp of | bheap_cons (pf0 | _, _) => let prval () = exp2_ispos (pf0) prval () = fold@ (hp) val (_(*pf*) | btmin) = bheap_remove (hp, cmp) val ~btnode (_, x, bts) = btmin val () = res := x prval () = opt_some {a} (res) val hp1 = hp1 where { fun loop {n:nat}{sz:nat} .. ( bts: btreelst (a, n), hp: bheap (a, n, sz) ) :<> [sz:nat] bheap (a, 0, sz) = case+ bts of | ~btlst_cons (bt, bts) => let prval pf = exp2_istot () in loop (bts, bheap_cons (pf | bt, hp)) end // end of [btlst_cons] | ~btlst_nil () => hp // end of [loop] val hp1 = loop (bts, bheap_nil) (* // // HX: This unsafe trick seems to gain by 5% // viewtypedef T = btree (a, 0) val xs = __cast (bts) where { extern castfn __cast {n:nat} (bts: btreelst (a, n)):<> List_vt (T) } (* end of [val] *) val xs = list_vt_reverse (xs) val hp1 = __cast (xs) where { extern castfn __cast (xs: List_vt (T)):<> [sz:nat] bheap (a, 0, sz) } (* end of [val] *) *) } // end of [val] val () = hp := bheap_bheap_merge (hp, hp1, cmp) in true end // end of [bheap_cons] | bheap_nil {a}{n} () => let prval () = opt_none {a} (res) in fold@ {a}{n} (hp); false end // end of [bheap_nil] // end of [case] // end // end of [linheap_delmin] end // end of [local] (* ****** ****** *) implement{a} linheap_merge (hp1, hp2, cmp) = bheap_bheap_merge (hp1, hp2, cmp) // end of [linheap_merge] (* ****** ****** *) implement{a} linheap_free (hp) = bheap_free (hp) (* ****** ****** *) implement{a} linheap_free_vt (hp) = let viewtypedef VT = heap (a) in case+ hp of | bheap_cons (pf | _, _) => true where { prval () = fold@ (hp); prval () = opt_some {VT} (hp) } // end of [B] | bheap_nil () => false where { prval () = opt_none {VT} (hp) } // end of [E] end // end of [linheap_free_vt] (* ****** ****** *) (* end of [linheap_binomail.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/vector.dats0000664000175000017500000003242612223166162020174 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A dynamically resizable vector implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: Secptember, 2010 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "libats/SATS/vector.sats" (* ****** ****** *) implement vector_cap {a} (V) = m where { prval pf = VECTOR_decode {a} (V) val m = V.m prval () = VECTOR_encode {a} (pf | V) } // end of[ vector_cap] implement vector_size {a} (V) = n where { prval pf = VECTOR_decode {a} (V) val n = V.n prval () = VECTOR_encode {a} (pf | V) } // end of[ vector_size] (* ****** ****** *) extern prfun vector_v_encode01 {a:viewt@ype} {n:int} {l:addr} (pf: array_v (a?, n, l)): vector_v (a, n, 0, l) // end of [vector_v_encode01] implement{a} vector_initialize {m} (V, m) = let val [l:addr] (pfgc, pfarr | p) = array_ptr_alloc (m) prval pfgc = __cast (pfgc) where { extern prfun __cast (pf: free_gc_v (a?, m, l)): free_gc_v l } // end of [prval] prval pfarr = vector_v_encode01 {a} (pfarr) val () = V.m := m val () = V.n := size1_of_int1 (0) val () = V.ptr := p val () = V.vfree := pfgc prval () = VECTOR_encode {a} (pfarr | V) in // nothing end // end of [vector_initialize] (* ****** ****** *) implement vector_clear {a} {m,n} (V) = let prval pf = VECTOR_decode {a} (V) prval pfmul = mul_istot {n,sizeof a} () prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval pf = array_v_unsplit {a?} (pfmul, pf1, pf2) prval pf = vector_v_encode01 {a} (pf) val () = V.n := (size1_of_int1)0 prval () = VECTOR_encode {a} (pf | V) in // nothing end // end of [vector_clear] (* ****** ****** *) implement{a} vector_clear_fun {m,n} (V, f) = let prval () = __assert () where { extern prfun __assert (): [m>=n;n>=0] void } prval pf0 = VECTOR_decode {a} (V) // prval pfmul = mul_istot {n,sizeof a} () prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf0) // val n = V.n val p = V.ptr val () = array_ptr_clear_fun (!p, n, f) // prval pf = array_v_unsplit {a?} (pfmul, pf1, pf2) // prval pf = vector_v_encode01 {a} (pf) // val () = V.n := (size1_of_int1)0 prval () = VECTOR_encode {a} (pf | V) in // nothing end // end of [vector_clear_fun] (* ****** ****** *) implement{a} vector_uninitialize {m,n} (V) = let prval pf = VECTOR_decode {a} (V) prval pfmul = mul_istot {n,sizeof a} () prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval pf = array_v_unsplit {a?} (pfmul, pf1, pf2) val () = __free (V.vfree, pf | V.ptr) where { extern fun __free {l:addr} (pf_gc: free_gc_v l, pf: array_v (a?, m, l) | p: ptr l):<> void = "ats_free_gc" // end of [__free] } // end of [val] in // nothing end // end of [vector_unintialize] implement{a} vector_uninitialize_vt {m} (V) = let prval pf = VECTOR_decode {a} (V) prval pfmul = mul_istot {0,sizeof a} () prval () = mul_elim {0,sizeof a} (pfmul) prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval () = array_v_unnil (pf1) val () = __free (V.vfree, pf2 | V.ptr) where { extern fun __free {l:addr} (pf_gc: free_gc_v l, pf: array_v (a?, m, l) | p: ptr l):<> void = "ats_free_gc" // end of [__free] } // end of [val] in // nothing end // end of [vector_unintialize_vt] (* ****** ****** *) implement{a} vector_get_elt_at {m,n} (V, i) = let prval pf = VECTOR_decode {a} (V) val p = V.ptr prval pfmul = mul_istot {n,sizeof a} () prval @(pf1, pf2) = vector_v_decode {a} (pfmul, pf) val x = array_ptr_get_elt_at (!p, i) prval () = pf := vector_v_encode {a} (pfmul, pf1, pf2) prval () = VECTOR_encode {a} (pf | V) in x end // end of [vector_get_elt_at] implement{a} vector_set_elt_at {m,n} (V, i, x) = let prval pf = VECTOR_decode {a} (V) val p = V.ptr prval pfmul = mul_istot {n,sizeof a} () prval @(pf1, pf2) = vector_v_decode {a} (pfmul, pf) val () = array_ptr_set_elt_at (!p, i, x) prval () = pf := vector_v_encode {a} (pfmul, pf1, pf2) prval () = VECTOR_encode {a} (pf | V) in // nothing end // end of [vector_get_elt_at] (* ****** ****** *) (* // // HX: this is a bit less efficient // implement{a} vector_append {m,n} (V, x) = let prval () = __assert () where { extern prfun __assert (): [n>=0] void } val n = vector_get_size (V) in vector_insert_at (V, n, x) end // end of [vector_append] *) implement{a} vector_append (V, x) = let prval pf = VECTOR_decode {a} (V) val n = V.n prval () = __assert (n) where { extern prfun __assert {n:int} (_: size_t n): [n>=0] void } // end of [val] val (pfmul | ofs) = mul2_size1_size1 (n, sizeof) prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval (pf21, pf22) = array_v_uncons {a?} (pf2) val p = V.ptr + ofs; val () = !p := x prval pf1 = array_v_extend {a} (pfmul, pf1, pf21) prval pfmul = MULind (pfmul) prval pf = vector_v_encode {a} (pfmul, pf1, pf22) val () = V.n := n + 1 prval () = VECTOR_encode {a} (pf | V) in // nothing end // end of [vector_append] (* ****** ****** *) implement{a} vector_prepend {m,n} (V, x) = let prval () = __assert () where { extern prfun __assert (): [n>=0] void } var x: a = x in vector_insert_at (V, 0, x) end // end of [vector_prepend] (* ****** ****** *) implement{a} vector_insert_at {m,n} {i} (V, i, x) = let prval () = __assert () where { extern prfun __assert (): [m>=n;n>=0] void } prval pf = VECTOR_decode {a} (V) // stavar l0:addr val p0 : ptr l0 = V.ptr val [ofs1:int] (pfmul1 | ofs1) = mul2_size1_size1 (i, sizeof) val n = V.n val [ofs:int] (pfmul | ofs) = mul2_size1_size1 (n, sizeof) // prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval (pf11, pf12) = array_v_split {a} {n} {i} (pfmul1, pf1) prval (pf21, pf22) = array_v_uncons {a?} (pf2) prval pf3 = array_v_nil {a} {l0+ofs+sizeof a} () // prval pfmul2 = mul_distribute2 (pfmul, mul_negate (pfmul1)) // val (pfr1, pfr2 | ()) = loop (pfmul2, pf12, pf21, pf3 | p0+ofs, n-i) where { fun loop {n1,n2:nat} {l:addr} {ofs:int} .. ( pfmul: MUL (n1, sizeof a, ofs) , pf1: array_v (a, n1, l), pf2: a? @ (l+ofs), pf3: array_v (a, n2, l+ofs+sizeof a) | p1: ptr (l+ofs), n1: size_t n1 ) :<> (a? @ l, array_v (a, n1+n2, l+sizeof a) | void) = if n1 > 0 then let prval (pf11, pf12) = array_v_unextend {a} (pfmul, pf1) prval pfmul = mul_add_const {~1} (pfmul) val p2 = p1 - sizeof; val () = !p1 := !p2 prval pf3 = array_v_cons {a} (pf2, pf3) in loop (pfmul, pf11, pf12, pf3 | p2, n1-1) end else let prval () = mul_elim {0,sizeof a} (pfmul) prval () = array_v_unnil (pf1) in (pf2, pf3 | ()) end // end of [if] // end of [loop] } // end of [val] val p = p0 + ofs1; val () = !p := x prval pf12 = array_v_cons {a} (pfr1, pfr2) prval pf1 = array_v_unsplit {a} (pfmul1, pf11, pf12) prval pfmul = MULind (pfmul) prval pf = vector_v_encode {a} (pfmul, pf1, pf22) // val () = V.n := n + 1 prval () = VECTOR_encode {a} (pf | V) // in // nothing end // end of [vector_insert_at] (* ****** ****** *) implement{a} vector_remove_at {m,n} {i} (V, i, x) = let // stadef tsz = sizeof (a) // prval () = __assert () where { extern prfun __assert (): [m>=n;n>=0] void } prval pf = VECTOR_decode {a} (V) // stavar l0:addr val p0 : ptr l0 = V.ptr val [ofs1:int] (pfmul1 | ofs1) = mul2_size1_size1 (i, sizeof) prval pfmul = mul_istot {n,tsz} () prval pfmul2 = mul_distribute2 (pfmul, mul_negate (pfmul1)) prval pfmul2 = mul_add_const {~1} (pfmul2) // prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf) prval (pf11, pf12) = array_v_split {a} {n} {i} (pfmul1, pf1) prval (pf121, pf122) = array_v_uncons {a} (pf12) val p = p0 + ofs1; val () = x := !p // val n = V.n val (pf11, pf12 | ()) = loop ( pfmul1, pfmul2, pf11, pf121, pf122 | p, n-i-1 ) where { fun loop {n1,n2:nat} {ofs1,ofs2:int} .. ( pfmul1: MUL (n1, tsz, ofs1) , pfmul2: MUL (n2, tsz, ofs2) , pf1: array_v (a, n1, l0) , pf21: a? @ (l0+ofs1) , pf22: array_v (a, n2, l0+ofs1+tsz) | p: ptr (l0+ofs1), n2: size_t (n2) ) :<> (array_v (a, n1+n2, l0), a? @ (l0+ofs1+ofs2) | void) = if n2 > 0 then let prval (pf221, pf222) = array_v_uncons {a} (pf22) val p1 = p+sizeof; val () = !p := !p1 prval pf1 = array_v_extend {a} (pfmul1, pf1, pf21) prval pfmul1 = mul_add_const {1} (pfmul1) prval pfmul2 = mul_add_const {~1} (pfmul2) in loop (pfmul1, pfmul2, pf1, pf221, pf222 | p1, n2-1) end else let prval () = array_v_unnil (pf22) prval () = mul_elim {0,tsz} (pfmul2) in (pf1, pf21 | ()) end // end of [if] // end of [loop] } // end of [val] // prval pf2 = array_v_cons {a?} (pf12, pf2) prval MULind (pfmul) = pfmul prval pf = vector_v_encode {a} (pfmul, pf11, pf2) // val () = V.n := n - 1 prval () = VECTOR_encode {a} (pf | V) // in // nothing end // end of [vector_remove_at] (* ****** ****** *) implement{a} vector_resize {m,n} {m1} (V, m1) = let prval pf = VECTOR_decode {a} (V) // val p1 = realloc ( V.vfree, pf | V.ptr, m1, sizeof ) where { extern fun realloc {l:addr} {n <= m1} ( pf_gc: !free_gc_v l >> free_gc_v l , pf: !vector_v (a, m, n, l) >> vector_v (a, m1, n, l) | p: ptr l, m1: size_t m1, tsz: sizeof_t a ) :<> #[l:addr] ptr l = "mac#atslib_vector_realloc" } // end of[ val] // val () = V.m := m1 val () = V.ptr := p1 prval () = VECTOR_encode {a} (pf | V) in // nothing end // end of [vector_resize] (* ****** ****** *) implement vector_foreach_funenv_tsz {a} {v} {vt} {m,n} (pf | V, f, tsz, env) = let prval () = __assert () where { extern praxi __assert (): [m>=n;n>=0] void } // end of [prval] prval pf0 = VECTOR_decode {a} (V) prval pfmul = mul_istot {n,sizeof a} () prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf0) val p = V.ptr val () = array_ptr_foreach_funenv_tsz (pf | !p, f, V.n, tsz, env) prval pf0 = vector_v_encode {a} (pfmul, pf1, pf2) prval () = VECTOR_encode {a} (pf0 | V) in // nothing end // end of [vector_foreach_funenv_tsz] (* ****** ****** *) implement{a} vector_foreach_vclo {v} {m,n} (pf_v | V, f) = let viewtypedef clo_t = (!v | &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | x) in pf := (pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = vector_foreach_funenv_tsz {a} {V} {ptr l_f} (pf | V, app, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [vector_foreach_vclo] (* ****** ****** *) implement vector_iforeach_funenv_tsz {a} {v} {vt} {m,n} (pf | V, f, tsz, env) = let prval () = __assert () where { extern praxi __assert (): [m>=n;n>=0] void } // end of [prval] prval pf0 = VECTOR_decode {a} (V) prval pfmul = mul_istot {n,sizeof a} () prval (pf1, pf2) = vector_v_decode {a} (pfmul, pf0) val p = V.ptr val () = array_ptr_iforeach_funenv_tsz (pf | !p, f, V.n, tsz, env) prval pf0 = vector_v_encode {a} (pfmul, pf1, pf2) prval () = VECTOR_encode {a} (pf0 | V) in // nothing end // end of [vector_iforeach_funenv_tsz] (* ****** ****** *) implement{a} vector_iforeach_vclo {v} {m,n} (pf_v | A, f) = let viewtypedef clo_t = (!v | sizeLt n, &a) - void stavar l_f: addr val p_f: ptr l_f = &f viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | i: sizeLt n, x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf; val () = !p_f (pf1 | i, x) in pf := (pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = vector_iforeach_funenv_tsz {a} {V} {ptr l_f} (pf | A, app, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [vector_iforeach_vclo] (* ****** ****** *) (* end of [vector.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/gfarray.dats0000664000175000017500000000352312223166162020321 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed arrays // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" (* ****** ****** *) staload "libats/SATS/gfarray.sats" (* ****** ****** *) // // HX-2010-12-28: it is empty for now // (* ****** ****** *) (* end of [gfarray.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funarray_braun.dats0000664000175000017500000002662412223166162021713 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional array implementation based on Braun trees ** An functional array as such can also be used as a deque ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: April, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) // // HX: staloading can actually be skipped as the // following declared datatype [brauntree] is list-like! // #define ATS_DYNLOADFLAG 0 // no dynloading at run-time (* ****** ****** *) staload "libats/SATS/funarray_braun.sats" (* ****** ****** *) datatype brauntree (a:t@ype+, int) = | {n1,n2:nat | n2 <= n1; n1 <= n2+1} B (a, n1+n2+1) of (a, brauntree (a, n1), brauntree (a, n2)) | E (a, 0) of () // end of [brauntree] stadef bt = brauntree // an abbreviation (* ****** ****** *) assume array_t0ype_int_type (a:t@ype, n:int) = brauntree (a, n) (* ****** ****** *) implement{} funarray_make_nil {a} () = E () (* ****** ****** *) implement{a} funarray_size (A) = size (A) where { // // HX: this algorithm is taken from a paper by Chris Okasaki // fun diff {nl,nr:nat | nr <= nl && nl <= nr+1} .. (nr: size_t nr, t: bt (a, nl)):<> int (nl-nr) = case+ t of | B (_, tl, tr) => begin if nr > 0 then let val nr2 = nr / 2 in if nr > nr2 + nr2 then diff (nr2, tl) else diff (nr2-1, tr) end else begin 1 // return value end // end of [if] end // end of [B] | E () => 0 // end of [diff] // fun size {n:nat} .. (t: bt (a, n)):<> size_t n = case+ t of | B (_, tl, tr) => let val nr = size tr val d1 = size1_of_int1 (1 + diff (nr, tl)) in 2 * size tr + d1 end // end of [B] | E () => 0 // end of [size] } // end of [funarray_size] (* ****** ****** *) implement{a} funarray_get_elt_at (A, i) = get_at (A, i) where { fun get_at {n,i:nat | i < n} .. (t: bt (a, n), i: int i):<> a = begin if i > 0 then let val i2 = i / 2 in if i > i2 + i2 then let val+ B (_, tl, _) = t in get_at (tl, i2) end else let val+ B (_, _, tr) = t in get_at (tr, i2-1) end // end of [if] end else let val+ B (x, _, _) = t in x end // end of [if] end (* end of [get_at] *) } // end of [funarray_get_at] implement{a} funarray_set_elt_at (A, i, x0) = A := set_at (A, i, x0) where { fun set_at {n,i:nat | i < n} .. (t: bt (a, n), i: int i, x0: a):<> bt (a, n) = if i > 0 then let val+ B (x, tl, tr) = t; val i2 = i / 2 in if i > i2 + i2 then begin B (x, set_at (tl, i2, x0), tr) end else begin B (x, tl, set_at (tr, i2-1, x0)) end // end of [if] end else let val+ B (_, t1, t2) = t in B (x0, t1, t2) end // end of [if] // end of [set_at] } // end of [funarray_set_at] (* ****** ****** *) implement{a} funarray_xch_elt_at (A, i, x0) = let fun xch_at {n,i:nat | i < n} .. (t: bt (a, n), i: int i, x0: &a >> a):<> bt (a, n) = if i > 0 then let val+ B (x, tl, tr) = t; val i2 = i / 2 in if i > i2 + i2 then begin B (x, xch_at (tl, i2, x0), tr) end else begin B (x, tl, xch_at (tr, i2-1, x0)) end // end of [if] end else let val x1 = x0; val+ B (x, t1, t2) = t; val () = x0 := x in B (x1, t1, t2) end // end of [if] // end of [xch_at] var x0 = x0 val () = A := xch_at (A, i, x0) in x0 (* return value *) end // end of [funarray_xch_at] (* ****** ****** *) implement{a} funarray_get_elt_at_exn (A, i) = get_at (A, i) where { fun get_at {n,i:nat} .. (t: bt (a, n), i: int i): a = if i > 0 then let val i2 = i / 2 in if i > i2 + i2 then begin case+ t of | B (_, tl, _) => get_at (tl, i2) | _ => $raise SubscriptException() end else begin case+ t of | B (_, _, tr) => get_at (tr, i2-1) | _ => $raise SubscriptException() end // end of [if] end else begin case+ t of // i = 0 | B (x, _, _) => x | _ => $raise SubscriptException end // end of [if] } // end of [funarray_get_at_exn] implement{a} funarray_set_elt_at_exn (A, i, x0) = A := set_at (A, i, x0) where { fun set_at {n,i:nat} .. (t: bt (a, n), i: int i, x0: a): bt (a, n) = if i > 0 then let val i2 = i / 2 in if i > i2 + i2 then begin case+ t of | B (x, tl, tr) => let val tl = set_at (tl, i2, x0) in B (x, tl, tr) end // end of [B] | _ => $raise SubscriptException end else begin case+ t of | B (x, tl, tr) => let val tr = set_at (tr, i2-1, x0) in B (x, tl, tr) end // end of [B] | _ => $raise SubscriptException end // end of [if] end else begin case+ t of // i = 0 | B (x, tl, tr) => B (x0, tl, tr) | _ => $raise SubscriptException() end // end of [if] } // end of [funarray_set_at_exn] (* ****** ****** *) implement{a} funarray_loadd (A, x0) = A := loadd (A, x0) where { fun loadd {n:nat} .. (t: bt (a, n), x0: a):<> bt (a, n+1) = begin case+ t of | B (x, tl, tr) => B (x0, loadd (tr, x), tl) | E () => B (x0, E (), E ()) end // end of [loadd] } // end of [funarray_loadd] implement{a} funarray_lorem (A) = A := lorem (A) where { fun lorem {n:int | n > 0} .. (t: bt (a, n)):<> bt (a, n-1) = let val+ B (_, tl, tr) = t in case+ tl of | B (xl, _, _) => B (xl, tr, lorem tl) | E () => E () end // end of [lorem] } // end of [brauntree_lorem] implement{a} funarray_lorem_get {n} (A) = let fun lorem {n:int | n > 0} .. (t: bt (a, n)):<> bt (a, n-1) = let val+ B (_, tl, tr) = t in case+ tl of | B (xl, _, _) => B (xl, tr, lorem tl) | E () => E () end // end of [lorem] val+ B (x0, tl, tr) = A val () = case+ :(A: array (a, n-1)) => tl of | B (xl, _, _) => (A := B (xl, tr, lorem tl)) | E () => (A := E ()) // end of [val] in x0 (* return value *) end // end of [funarray_lorem_get] (* ****** ****** *) implement{a} funarray_hiadd (A, n, x0) = A := hiadd (A, n, x0) where { fun hiadd {n:nat} .. (t: bt (a, n), n: int n, x0: a):<> bt (a, n+1) = if n > 0 then let val+ B (x, tl, tr) = t; val n2 = n / 2 in if n > n2 + n2 then begin B (x, hiadd (tl, n2, x0), tr) end else begin B (x, tl, hiadd (tr, n2-1, x0)) end end else begin B (x0, E (), E ()) end // end of [if] } // end of [funarray_hiadd] implement{a} funarray_hirem (A, n) = A := hirem (A, n) where { fun hirem {n:pos} .. (t: bt (a, n), n: int n):<> bt (a, n-1) = let val+ B (x, tl, tr) = t; val n2 = n / 2 in case+ tl of | B _ => begin if n > n2 + n2 then begin B (x, tl, hirem (tr, n2)) end else begin B (x, hirem (tl, n2), tr) end // end of [if] end // end of [B] | E () => E () end // end of [hirem] } // end of [funarray_hirem] implement{a} funarray_hirem_get (A, n) = let fun hirem_get {n:pos} .. ( t: bt (a, n), n: int n, x0: &a? >> a ) :<> bt (a, n-1) = let val+ B (x, tl, tr) = t; val n2 = n / 2 in case+ tl of | B _ => begin if n > n2 + n2 then begin B (x, tl, hirem_get (tr, n2, x0)) end else begin B (x, hirem_get (tl, n2, x0), tr) end // end of [if] end // end of [B] | E () => (x0 := x; E ()) end // end of [hirem_get] var x0: a // unintialized val () = A := hirem_get (A, n, x0) in x0 (* return value *) end // end of [funarray_hirem_get] (* ****** ****** *) implement{a} funarray_foreach_vclo {v} {n} (pf | A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (pf | A[i]) end // end of [funarray_foreach_vclo] implement{a} funarray_foreach_cloptr {n} (A, n, f) = () where { // viewtypedef cloptr0_t = (a) - void viewtypedef cloptr1_t = (!unit_v | a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = funarray_foreach_vcloptr {unit_v} (pfu | A, n, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [funarray_foreach_cloptr] implement{a} funarray_foreach_vcloptr {v} {n} (pf | A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (pf | A[i]) end // end of [funarray_foreach_vcloptr] implement{a} funarray_foreach_cloref {n} (A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (A[i]) end // end of [funarray_foreach_cloref] (* ****** ****** *) implement{a} funarray_iforeach_vclo {v} {n} (pf | A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (pf | i, A[i]) end // end of [funarray_iforeach_vclo] implement{a} funarray_iforeach_cloptr {n} (A, n, f) = () where { // viewtypedef cloptr0_t = (natLt n, a) - void viewtypedef cloptr1_t = (!unit_v | natLt n, a) - void // prval () = __assert(f) where { extern prfun __assert (f: !cloptr0_t >> cloptr1_t): void } // end of [val] prval pfu = unit_v () val () = funarray_iforeach_vcloptr {unit_v} (pfu | A, n, f) prval unit_v () = pfu prval () = __assert(f) where { extern prfun __assert (f: !cloptr1_t >> cloptr0_t): void } // end of [val] } // end of [funarray_iforeach_cloptr] implement{a} funarray_iforeach_vcloptr {v} {n} (pf | A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (pf | i, A[i]) end // end of [funarray_iforeach_vcloptr] implement{a} funarray_iforeach_cloref {n} (A, n, f) = let var i: natLte n in for* {i:nat | i <= n} .. // term metric (i: int i) => (i := 0; i < n; i := i+1) f (i, A[i]) end // end of [funarray_iforeach_cloref] (* ****** ****** *) (* end of [funarray_braun.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/refcount.dats0000664000175000017500000001125612223166162020515 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 (* ****** ****** *) staload _(*anon*) = "prelude/DATS/pointer.dats" (* ****** ****** *) staload "libats/SATS/refcount.sats" (* ****** ****** *) implement{a} refcount_make (x) = r where { viewtypedef VT = @(uint, a) val [l:addr] (pfgc, pfat | p) = ptr_alloc () val () = p->0 := 1u and () = p->1 := x val r = __cast (pfgc, pfat | p) where { extern castfn __cast (pf1: free_gc_v (VT?, l), pf2: VT@l | p: ptr l):<> nref(a) // end of [extern] } // end of [val] } // end of [refcount] (* ****** ****** *) implement{a} refcount_ref (r) = r1 where { viewtypedef VT = @(uint, a) val (pfat, fpf | p) = __cast (r) where { extern castfn __cast (r: !nref (a)):<> [l:addr] (VT@l, VT@l - void | ptr l) // end of [extern] } // end of [val] val () = p->0 := p->0 + 1u prval () = fpf (pfat) val r1 = __ref (r) where { extern castfn __ref (r: !nref a):<> nref a } // end of [val] } // end of [refcount_ref] (* ****** ****** *) implement{a} refcount_unref (r, x) = let // viewtypedef VT = @(uint, a) val [l:addr] p = __cast (r) where { extern castfn __cast (r: !nref (a)):<> [l:addr] ptr (l) // end of [extern] } // end of [val] prval (pfat, fpf) = __assert () where { extern praxi __assert (): (VT@l, VT@l - void) } // end of [prval] val n = p->0 prval () = fpf (pfat) // in // if n > 1u then let prval (pfat, fpf) = __assert () where { extern praxi __assert (): (VT@l, VT@l - void) } // end of [prval] val () = p->0 := n - 1u prval () = fpf (pfat) prval () = opt_none {a} (x) prval () = __unref (r) where { extern prfun __unref (r: nref (a)): void } // end of [prval] in false // refcount is still positive end else let prval (pfat, fpf) = __assert () where { extern praxi __assert (): (VT@l, (VT?)@l - void) } // end of [prval] val () = x := p->1 prval () = fpf (pfat) prval () = opt_some {a} (x) val () = __free (r) where { extern fun __free (r: nref (a)):<> void = "ats_free_gc" } // end of [prval] in true // refcount has reached 0 end // end of [if] // end // end of [refcount_unref] implement{a} refcount_unref_fun (r, f) = let var x: a? val res = refcount_unref (r, x) in if res then let val () = opt_unsome {a} (x) in f (x) end else let val () = opt_unnone {a} (x) in // nothing end // end of [if] end // end of [refcount_unref_fun] (* ****** ****** *) implement{a} refcount_get_count (r) = n where { viewtypedef VT = @(uint, a) // val (pfat, fpf | p) = __cast (r) where { extern castfn __cast (r: !nref (a)):<> [l:addr] (VT@l, VT@l - void | ptr l) // end of [extern] } // end of [val] val n = p->0 prval () = fpf (pfat) // } // end of [refcount_get_count] (* ****** ****** *) implement{a} refcount_takeout (r) = (pf1at | p1) where { viewtypedef VT = @(uint, a) // val (pfat, fpf | p) = __cast (r) where { extern castfn __cast (r: !nref (a)):<> [l:addr] (VT@l, VT@l - void | ptr l) // end of [extern] } // end of [val] // val [l1:addr] p1 = &(p->1) : Ptr // prval () = fpf (pfat) // prval pf1at = __assert (r) where { extern praxi __assert (r: !nref (a) >> nrefout (a, l1)): a @ l1 } // end of [prval] } // end of [refcount_takeout] (* ****** ****** *) (* end of [refcount.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/ilistp.dats0000664000175000017500000001633212223166162020174 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: October, 2010 // (* ****** ****** *) // // HX: reasoning about integer sequences and multisets // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // loaded by [ats_main_prelude] (* ****** ****** *) staload "libats/SATS/ilistp.sats" (* ****** ****** *) implement length_istot () = istot () where { prfun istot {xs:ilist} .. (): [n:nat] LENGTH (xs, n) = scase xs of | ilist_cons (x, xs) => LENGTHcons (istot {xs} ()) | ilist_nil () => LENGTHnil () // end of [prfun] } // end of [length_istot] implement length_isfun (pf1, pf2) = let prfun isfun {xs:ilist} {n1,n2:int} .. ( pf1: LENGTH (xs, n1), pf2: LENGTH (xs, n2) ) : [n1==n2] void = scase xs of | ilist_cons (x, xs) => let prval LENGTHcons (pf1) = pf1 and LENGTHcons (pf2) = pf2 prval () = isfun {xs} (pf1, pf2) in // nothing end // end of [ilist_cons] | ilist_nil () => let prval LENGTHnil () = pf1 and LENGTHnil () = pf2 in (*nothing*) end // end of [ilist_nil] // end of [isfun] in isfun (pf1, pf2) end // end of [length_isfun] (* ****** ****** *) implement length_isnat {xs} (pf) = length_isfun (pf, length_istot {xs} ()) // end of [length_isnat] (* ****** ****** *) implement append_unit1 () = APPENDnil () implement append_unit2 () = let prfun lemma {xs:ilist} .. (): APPEND (xs, ilist_nil, xs) = scase xs of | ilist_cons (x, xs) => APPENDcons (lemma {xs} ()) | ilist_nil () => APPENDnil () in lemma () end // end of [append_unit2] implement append_sing () = APPENDcons (APPENDnil ()) (* ****** ****** *) implement append_length_lemma (pf, pf1len, pf2len) = let // prfun lemma {xs1,xs2:ilist} {xs:ilist} {n1,n2:int} .. ( pf: APPEND (xs1, xs2, xs), pf1len: LENGTH (xs1, n1), pf2len: LENGTH (xs2, n2) ) : LENGTH (xs, n1+n2) = let prval () = length_isnat (pf2len) in scase xs1 of | ilist_cons (x1, xs1) => let prval APPENDcons (pf) = pf prval LENGTHcons (pf1len) = pf1len prval pflen = lemma (pf, pf1len, pf2len) in LENGTHcons (pflen) end // end of [ilist_cons] | ilist_nil () => let prval APPENDnil () = pf prval LENGTHnil () = pf1len in pf2len end // end of [ilist_nil] end // end of [append_length_lemma] // in lemma (pf, pf1len, pf2len) end // end of [append_length_lemma] (* ****** ****** *) implement msetcnt_istot {x0} {xs} () = let prfun istot {xs:ilist} .. (): [n:nat] MSETCNT (x0, xs, n) = scase xs of | ilist_cons (x, xs) => MSETCNTcons (istot {xs} ()) | ilist_nil () => MSETCNTnil () // end of [istot] in istot {xs} () end // end of [msetcnt_istot] implement msetcnt_isfun {x0} (pf1, pf2) = let prfun isfun {xs:ilist} {n1,n2:int} .. ( pf1: MSETCNT (x0, xs, n1), pf2: MSETCNT (x0, xs, n2) ) : [n1==n2] void = scase xs of | ilist_cons (x, xs) => let prval MSETCNTcons pf1 = pf1 and MSETCNTcons pf2 = pf2 prval () = isfun (pf1, pf2) in // nothing end // end of [ilist_cons] | ilist_nil () => let prval MSETCNTnil () = pf1 and MSETCNTnil () = pf2 in (* nothing *) end // end of [ilist_nil] // end of [isfun] in isfun (pf1, pf2) end // end of [msetcnt_isfun] implement msetcnt_first {x} {xs} () = let prval pf = msetcnt_istot {x} {xs} () in MSETCNTcons (pf) end // end of [msetcnt_first] (* ****** ****** *) implement nth_msetcnt_lemma {x} (pf) = let prfun lemma {xs:ilist} {i:int} .. (pf: NTH (x, xs, i)): [n:pos] MSETCNT (x, xs, n) = case+ pf of | NTHind (pf) => MSETCNTcons (lemma (pf)) | NTHbas () => msetcnt_first () // end of [lemma] in lemma (pf) end // end of [nth_msetcnt_lemma] implement msetcnt_nth_lemma {x} (pf) = let prfun lemma {xs:ilist} {n:pos} .. (pf: MSETCNT (x, xs, n)): [i:nat] NTH (x, xs, i) = let prval MSETCNTcons {..} {x1} {xs1} (pf1) = pf in sif x == x1 then NTHbas () else NTHind (lemma (pf1)) end // end of [lemma] in lemma (pf) end // end of [msetcnt_nth_lemma] (* ****** ****** *) implement insert_length_lemma {x0} (pf1, pf2) = let prfun lemma {xs:ilist} {i:int} {ys:ilist} {n:nat} .. (pf1: INSERT (x0, xs, i, ys), pf2: LENGTH (xs, n)): LENGTH (ys, n+1) = case+ pf1 of | INSERTbas () => LENGTHcons (pf2) | INSERTind (pf1) => let prval LENGTHcons pf2 = pf2 in LENGTHcons (lemma (pf1, pf2)) end // end of [INSERTind] // end of [lemma] in lemma (pf1, pf2) end // end of [insert_length_lemma] implement nth_insert_lemma {x} (pf) = let prfun lemma {xs:ilist} {n:int} .. (pf: NTH (x, xs, n)): [ys:ilist] INSERT (x, ys, n, xs) = case+ pf of | NTHind (pf) => INSERTind (lemma (pf)) | NTHbas {..} {xs1} () => INSERTbas {x} {xs1} () // end of [lemma] in lemma (pf) end // end of [nth_insert_lemma] (* ****** ****** *) implement permute_refl () = lam pf => pf implement permute_symm {xs1,xs2} (fpf) = lam {x0:int} {n:nat} ( pf: MSETCNT (x0, xs2, n) ) : MSETCNT (x0, xs1, n) = let prval pf1 = msetcnt_istot {x0} {xs1} () prval pf2 = fpf (pf1) prval () = msetcnt_isfun (pf, pf2) in pf1 end // end of [permute_symm] implement permute_trans (fpf1, fpf2) = lam pf => fpf2 (fpf1 (pf)) (* ****** ****** *) (* implement append_munion_lemma (pf) = lemma (pf) where { prfun lemma {xs,ys,zs:ilist} .. (pf: APPEND (xs,ys,zs)): MUNION (xs, ys, zs) = case+ pf of | APPENDcons (pf) => let prval fpf = lemma (pf) in lam (pf1, pf2) => let prval MSETCNTcons pf1 = pf1 in MSETCNTcons (fpf (pf1, pf2)) end // end of [lam] end (* end of [APPENDcons] *) | APPENDnil () => lam (pf1, pf2) => let prval MSETCNTnil () = pf1 in pf2 end // end of [lam] (* end of [APPENDnil] *) // end of [lemma] } // end of [append_munion_lemma] *) (* ****** ****** *) (* end of [ilistp.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funmap_rbtree.dats0000664000175000017500000004622012223166162021520 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** A red-black tree implementation ** ** The insertion operation is based on the algorithm in the following ** paper by Chris Okasaki: ** ** Red-Black Trees in a Functional Setting (Functional Pearls) ** ** J. of Functional Programming, vol. 9 (4), pp. 471-477, January, 1993 ** ** The removal operation, which seems novel in its implementation, is by ** Hongwei Xi ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: September, 2011 // based on a version done in October, 2008 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/funmap_rbtree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{key} compare_key_key (x1, x2, cmp) = cmp (x1, x2) (* ****** ****** *) #define BLK 0; #define RED 1 sortdef clr = {c:nat | c <= 1} typedef color (c:int) = int c typedef color = [c:clr] color c (* ****** ****** *) datatype rbtree ( key:t@ype, itm: t@ype , int(*color*), int(*blackheight*), int(*violation*) ) = | E (key, itm, BLK, 0, 0) | {c,cl,cr:clr} {bh:nat} {v:int} {c == BLK && v == 0 || c == RED && v == cl+cr} T (key, itm, c, bh+1-c, v) of ( color c, key, itm, rbtree0 (key, itm, cl, bh), rbtree0 (key, itm, cr, bh) ) // end of [T] // rbtree0: for trees of no violations where rbtree0 (key:t@ype, itm:t@ype, c:int, bh:int) = rbtree (key, itm, c, bh, 0(*vio*)) // end of [rbtree0] (* ****** ****** *) assume map_t0ype_t0ype_type ( key:t@ype, itm:t@ype ) = [c:clr;bh:nat] rbtree0 (key, itm, c, bh) (* ****** ****** *) implement{} funmap_make_nil () = E () (* ****** ****** *) implement{} funmap_is_nil (t) = case+ t of | T _ => false | E () => true // end of [funmap_is_nil] implement{} funmap_isnot_nil (t) = case+ t of | T _ => true | E () => false // end of [funmap_isnot_nil] (* ****** ****** *) implement{key,itm} funmap_size (t) = sz (t) where { fun sz {c:clr} {bh:nat} .. (t: rbtree0 (key, itm, c, bh)):<> size_t = begin case+ t of | T (_(*c*), _(*key*), _(*itm*), tl, tr) => (size_of_int1)1 + sz (tl) + sz (tr) | E () => (size_of_int1)0 end // end of [sz] } // end of [funmap_size] (* ****** ****** *) implement{key,itm} funmap_height (t) = ht (t) where { fun ht {c:clr} {bh:nat} .. (t: rbtree0 (key, itm, c, bh)):<> Nat = begin case+ t of | T (_(*c*), _(*key*), _(*itm*), tl, tr) => 1 + max (ht tl, ht tr) | E () => 0 end // end of [ht] } // end of [funmap_height] (* ****** ****** *) implement{key,itm} funmap_black_height (t) = case+ t of | T (c, _, _, tl, _) => let val bhl = funmap_black_height (tl) in bhl + 1 end // end of [T] | E () => 0 // end of [E] // end of [funmap_black_height] (* ****** ****** *) implement{key,itm} funmap_search (t, k0, cmp, res) = search (t, res) where { fun search {c:clr} {bh:nat} {u:nat} .. ( t: rbtree (key, itm, c, bh, u), res: &itm? >> opt (itm, b) ) : #[b:bool] bool b = begin case+ t of | T (_(*c*), k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in case+ 0 of | _ when sgn < 0 => search (tl, res) | _ when sgn > 0 => search (tr, res) | _ => let val () = res := x; prval () = opt_some {itm} (res) in true end // end of [_] end // end of [T] | E () => let prval () = opt_none {itm} (res) in false end // end of [E] end // end of [search] } // end of [funmap_search] (* ****** ****** *) fn{key,itm:t@ype} insfix_l // right rotation {cl,cr:clr} {bh:nat} {v:nat} ( k: key, x: itm , tl: rbtree (key, itm, cl, bh, v) , tr: rbtree (key, itm, cr, bh, 0) ) :<> [c:clr] rbtree0 (key, itm, c, bh+1) = let #define B BLK; #define R RED in case+ (tl) of | T (R, kl, xl, T (R, kll, xll, tlll, tllr), tlr) => T (R, kl, xl, T (B, kll, xll, tlll, tllr), T (B, k, x, tlr, tr)) | T (R, kl, xl, tll, T (R, klr, xlr, tlrl, tlrr)) => T (R, klr, xlr, T (B, kl, xl, tll, tlrl), T (B, k, x, tlrr, tr)) | _ =>> T (B, k, x, tl, tr) end // end of [insfix_l] fn{key,itm:t@ype} insfix_r // right rotation {cl,cr:clr} {bh:nat} {v:nat} ( k: key, x: itm , tl: rbtree (key, itm, cl, bh, 0) , tr: rbtree (key, itm, cr, bh, v) ) :<> [c:clr] rbtree0 (key, itm, c, bh+1) = let #define B BLK; #define R RED in case+ (tr) of | T (R, kr, xr, trl, T (R, krr, xrr, trrl, trrr)) => T (R, kr, xr, T (B, k, x, tl, trl), T (B, krr, xrr, trrl, trrr)) | T (R, kr, xr, T (R, krl, xrl, trll, trlr), trr) => T (R, krl, xrl, T (B, k, x, tl, trll), T (B, kr, xr, trlr, trr)) | _ =>> T (B, k, x, tl, tr) end // end of [insfix_r] (* ****** ****** *) implement{key,itm} funmap_insert (m, k0, x0, cmp) = res where { #define B BLK; #define R RED fun ins {c:clr} {bh:nat} .. ( t: rbtree0 (key, itm, c, bh), res: &bool? >> bool ) : [c1:clr; v:nat | v <= c] rbtree (key, itm, c1, bh, v) = case+ t of | T (c, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val [cl,v:int] tl = ins (tl, res) in if c = B then insfix_l (k, x, tl, tr) else T {..}{..}{..}{cl} (R, k, x, tl, tr) end else if sgn > 0 then let val [cr,v:int] tr = ins (tr, res) in if c = B then insfix_r (k, x, tl, tr) else T {..}{..}{..}{cr} (R, k, x, tl, tr) end else ( res := true; t // no insertion ) // end of [if] end // end of [T] | E () => (res := false; T {..}{..}{..}{0} (R, k0, x0, E, E)) // end of [ins] var res: bool val m1 = ins (m, res) val () = case+ m1 of | T (R, k, x, tl, tr) => m := T (B, k, x, tl, tr) | _ =>> m := m1 // end of [vall } // end of [funmap_insert] (* ****** ****** *) implement{key,itm} funmap_insert_clo (m, k0, x0, f, cmp) = () where { #define B BLK; #define R RED fun ins {c:clr} {bh:nat} .. ( t: rbtree0 (key, itm, c, bh), f: &(itm, itm) - itm ) : [c1:clr;v:nat | v <= c] rbtree (key, itm, c1, bh, v) = case+ t of | T (c, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val [cl,v:int] tl = ins (tl, f) in if c = B then insfix_l (k, x, tl, tr) else T {..}{..}{..}{cl} (R, k, x, tl, tr) end else if sgn > 0 then let val [cr,v:int] tr = ins (tr, f) in if c = B then insfix_r (k, x, tl, tr) else T {..}{..}{..}{cr} (R, k, x, tl, tr) end else T {..}{..}{..}{0} (c, k, f (x0, x), tl, tr) // end of [if] end // end of [T] | E () => T {..}{..}{..}{0} (R, k0, x0, E, E) // end of [ins] val m1 = ins (m, f) val () = case+ m1 of | T (R, k, x, tl, tr) => m := T (B, k, x, tl, tr) | _ =>> m := m1 // end of [vall } // end of [funmap_insert] (* ****** ****** *) fn{key,itm:t@ype} rbtree_clr_trans_blk_red {bh:pos} (t: rbtree (key, itm, BLK, bh, 0)) :<> [v:nat] rbtree (key, itm, RED, bh-1, v) = let val+ T {..}{c,cl,cr} (BLK, k, x, tl, tr) = t in T {..}{..}{..}{cl+cr} (RED, k, x, tl, tr) end // end of [rbtree_clr_trans_blk_red] (* ****** ****** *) fn{key,itm:t@ype} remfix_l {cl,cr:clr} {bh:nat} {v:nat} ( k: key, x: itm , tl: rbtree (key, itm, cl, bh, v) , tr: rbtree (key, itm, cr, bh+1, 0) ) :<> [c:clr;v:nat | v <= cr] rbtree (key, itm, c, bh+1, v) = let #define B BLK; #define R RED in case+ tl of | T (R, kl, xl, tll, tlr) => T {..}{..}{..}{cr} (R, k, x, T (B, kl, xl, tll, tlr), tr) // end of [T (R, ...)] | _ =>> begin case+ tr of | T {..} {cr,crl,crr} (B, kr, xr, trl, trr) => insfix_r (k, x, tl, T {..}{..}{..}{crl+crr} (R, kr, xr, trl, trr)) | T (R, kr, xr, trl, trr) => let val+ T (B, krl, xrl, trll, trlr) = trl val [c_new:int] t_new = insfix_r (kr, xr, trlr, rbtree_clr_trans_blk_red trr) in T {..}{..}{..}{c_new} (R, krl, xrl, T (B, k, x, tl, trll), t_new) end // end of [T (R, ...)] end // end of [_] end // end of [remfix_l] fn{key,itm:t@ype} remfix_r {cl,cr:clr} {bh:nat} {v:nat} ( k: key, x: itm , tl: rbtree (key, itm, cl, bh+1, 0) , tr: rbtree (key, itm, cr, bh, v) ) :<> [c:clr;v:nat | v <= cl] rbtree (key, itm, c, bh+1, v) = let #define B BLK; #define R RED in case+ tr of | T (R, kr, xr, trl, trr) => T {..}{..}{..}{cl} (R, k, x, tl, T (B, kr, xr, trl, trr)) // end of [T (R, ...)] | _ =>> begin case+ tl of | T {..} {cl,cll,clr} (B, kl, xl, tll, tlr) => insfix_l (k, x, T {..}{..}{..}{cll+clr} (R, kl, xl, tll, tlr), tr) | T (R, kl, xl, tll, tlr) => let val+ T (B, klr, xlr, tlrl, tlrr) = tlr val [c_new:int] t_new = insfix_l (kl, xl, rbtree_clr_trans_blk_red tll, tlrl) in T {..}{..}{..}{c_new} (R, klr, xlr, t_new, T (B, k, x, tlrr, tr)) end // end of [T (R, ...)] end // end of [_] end // end of [remfix_r] (* ****** ****** *) fun{key,itm:t@ype} rbtree_remove_min {c:clr} {bh:nat | bh+c > 0} .. ( t: rbtree0 (key, itm, c, bh) , k0: &key? >> key , x0: &itm? >> itm , bhdf: &int? >> int (bhdf) ) :<> #[bhdf:two | bhdf <= bh] [c1:clr | c1 <= c+bhdf] rbtree (key, itm, c1, bh-bhdf, 0) = let #define B BLK; #define R RED in case+ t of | T (B, k, x, tl, tr) => begin case+ tl of | T _ => let val tl = rbtree_remove_min (tl, k0, x0, bhdf) in if bhdf = 0 then T {..}{..}{..}{0} (B, k, x, tl, tr) else let val t = remfix_l (k, x, tl, tr) in case+ t of | T (R, k, x, tl, tr) => (bhdf := 0; T (B, k, x, tl, tr)) | _ =>> t end (* end of [if] *) end // end of [T] | E _ => (k0 := k; x0 := x; bhdf := 1; tr) end (* end of [T (B, ...)] *) | T (R, k, x, tl, tr) => begin case+ tl of | T _ => let val tl = rbtree_remove_min (tl, k0, x0, bhdf) in if bhdf = 0 then T {..}{..}{..}{0} (R, k, x, tl, tr) else let // bhdf = 1 val () = bhdf := 0 in insfix_r (k, x, tl, rbtree_clr_trans_blk_red tr) end (* end of [if] *) end // end of [T (B, ...)] | E () => (k0 := k; x0 := x; bhdf := 0; tr) end (* end of [T (R, ...)] *) end // end of [rbtree_remove_min] (* ****** ****** *) fn{key,itm:t@ype} rbtree_join {cl,cr:clr} {bh:nat} ( tl: rbtree0 (key, itm, cl, bh) , tr: rbtree0 (key, itm, cr, bh) ) :<> [c:clr;v:nat | v <= cl+cr] rbtree (key, itm, c, bh, v) = case+ tr of | T _ => let var k0: key and x0: itm var bhdf: int // uninmitialized val [cr:int] tr = rbtree_remove_min (tr, k0, x0, bhdf) in if bhdf = 0 then T {..}{..}{..}{cl+cr} (RED, k0, x0, tl, tr) else remfix_r (k0, x0, tl, tr) end // end of [T] | E () => tl // end of [rbtree_join] (* ****** ****** *) // // HX-2011-09-24: // the pointer [p_res] is assumed to be associated with a proof // of at-view if it is not null // extern fun{key,itm:t@ype} funmap_takeout_ptr {l_res:addr} (m: &map (key, itm), k0: key, cmp: cmp key, p_res: ptr l_res):<> bool // end of [funmap_takeout] implement{key,itm} funmap_takeout_ptr {l_res} (m, k0, cmp, p_res) = b(*removed*) where { #define B BLK; #define R RED fun takeout {c:clr} {bh:nat} .. ( t: rbtree0 (key, itm, c, bh) , bhdf: &int? >> int bhdf , p_res: ptr l_res , b: &bool? >> bool ) : #[ bhdf:two | bhdf <= bh ] [ c1:clr | c1 <= c+bhdf ] rbtree0 (key, itm, c1, bh-bhdf) = case+ t of | T (B, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val tl = takeout (tl, bhdf, p_res, b) in if bhdf = 0 then T {..}{..}{..}{0} (B, k, x, tl, tr) else let // bhdf = 1 val t = remfix_l (k, x, tl, tr) in case+ t of | T (R, k, x, tl, tr) => (bhdf := 0; T (B, k, x, tl, tr)) | _ =>> t end // end of [if] end else if sgn > 0 then let val tr = takeout (tr, bhdf, p_res, b) in if bhdf = 0 then T {..}{..}{..}{0} (B, k, x, tl, tr) else let // bhdf = 1 val t = remfix_r (k, x, tl, tr) in case+ t of | T (R, k, x, tl, tr) => (bhdf := 0; T (B, k, x, tl, tr)) | _ =>> t end // end of [if] end else let // x0 = x val () = if (p_res > null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := x prval () = fpf (pf) in // nothing end // end of [val] val () = b := true val t = rbtree_join (tl, tr) in case+ t of | T (R, k, x, tl, tr) => (bhdf := 0; T (B, k, x, tl, tr)) | _ =>> (bhdf := 1; t) end (* end of [if] *) end // end of [T (B, ...)] | T (R, k, x, tl, tr) => let val sgn = compare_key_key (k0, k, cmp) in if sgn < 0 then let val tl = takeout (tl, bhdf, p_res, b) in if bhdf = 0 then T {..}{..}{..}{0} (R, k, x, tl, tr) else let // bhdf = 1 val () = bhdf := 0 in remfix_l (k, x, tl, tr) end // end of [if] end else if sgn > 0 then let val tr = takeout (tr, bhdf, p_res, b) in if bhdf = 0 then T {..}{..}{..}{0} (R, k, x, tl, tr) else let // bhdf = 1 val () = bhdf := 0 in remfix_r (k, x, tl, tr) end // end of [if] end else let // x0 = x val () = bhdf := 0 val () = if (p_res > null) then let prval (pf, fpf) = __assert () where { extern praxi __assert (): (itm? @ l_res, itm @ l_res -<> void) } // end of [prval] val () = !p_res := x prval () = fpf (pf) in // nothing end // end of [val] val () = b := true in rbtree_join (tl, tr) end (* end of [if] *) end // end of [T (R, ...)] | E () => (bhdf := 0; b := false; t) // end of [rem] var bhdf: int // uninitialized var b: bool val () = m := takeout (m, bhdf, p_res, b) } // end of [funmap_takeout_ptr] (* ****** ****** *) implement{key,itm} funmap_takeout (m, k0, cmp, res) = ans where { val ans = funmap_takeout_ptr (m, k0, cmp, &res) val [b:bool] ans = bool1_of_bool (ans) prval pf = __assert (view@ res) where { extern praxi __assert {l_res:addr} (pf: itm? @ l_res):<> (opt (itm, b) @ l_res) } // end of [prval] prval () = (view@ res := pf) } // end of [funmap_takeout] implement{key,itm} funmap_remove (m, k0, cmp) = funmap_takeout_ptr (m, k0, cmp, null) // end of [funmap_remove] (* ****** ****** *) (* fun{key,itm:t@ype} funmap_foreach_funenv {v:view} {vt:viewtype} ( pf: !v | m: map (key, itm), f: (!v | key, itm, !vt) - void, env: !vt ) :<> void // end of [funmap_foreach_funenv] *) implement{key,itm} funmap_foreach_funenv {v} {vt} (pf | m, f, env) = foreach (pf | m, env) where { fun foreach {c:clr} {bh:nat} {u:nat} .. (pf: !v | t: rbtree (key, itm, c, bh, u), env: !vt): void = case+ t of | T (_(*c*), k, x, tl, tr) => ( foreach (pf | tl, env); f (pf | k, x, env); foreach (pf | tr, env) ) // end of [T] | E () => () // end of [foreach] } // end of [funmap_foreach_funenv] implement{key,itm} funmap_foreach_fun (m, f) = let // val f = coerce (f) where { extern castfn coerce (f: (key, itm) - void):<> (!unit_v | key, itm, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = funmap_foreach_funenv {unit_v} {ptr} (pfu | m, f, null) prval unit_v () = pfu // in // nothing end // end of [funmap_foreach_fun] (* ****** ****** *) implement{key,itm} funmap_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {c:clr} {bh:nat} {u:nat} .. ( pf: !v | t: rbtree (key, itm, c, bh, u), f: &(!v | key, itm) - void ) :<> void = case+ t of | T (_(*c*), k, x, tl, tr) => begin foreach (pf | tl, f); f (pf | k, x); foreach (pf | tr, f) end // end of [T] | E () => () // end of [foreach] } // end of [funmap_foreach_vclo] implement{key,itm} funmap_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, itm) - void):<> (!unit_v | key, itm) - void } // end of [val] typedef clo_type = (!unit_v | key, itm) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pfu = unit_v () val () = $effmask_ref (funmap_foreach_vclo {unit_v} (pfu | m, !p_f)) prval unit_v () = pfu in // empty end // end of [funmap_foreach_cloref] (* ****** ****** *) implement{key,itm} funmap_rforeach_funenv {v} {vt} (pf | m, f, env) = rforeach (pf | m, env) where { fun rforeach {c:clr} {bh:nat} {u:nat} .. (pf: !v | t: rbtree (key, itm, c, bh, u), env: !vt): void = case+ t of | T (_(*c*), k, x, tl, tr) => ( rforeach (pf | tr, env); f (pf | k, x, env); rforeach (pf | tl, env) ) // end of [T] | E () => () // end of [rforeach] } // end of [funmap_rforeach_funenv] (* ****** ****** *) implement{key,itm} funmap_listize (xs) = let typedef keyitm = @(key, itm) viewtypedef res_vt = List_vt keyitm fun listize {c:clr} {bh:nat} {u:nat} .. ( t: rbtree (key, itm, c, bh, u), res: res_vt ) :<> res_vt = case+ t of | T (_(*c*), k, x, tl, tr) => let val res = listize (tr, res) val res = list_vt_cons {keyitm} ((k, x), res) val res = listize (tl, res) in res end // end of [T] | E () => res // end of [listize] in listize (xs, list_vt_nil ()) end // end of [funmap_listize] (* ****** ****** *) (* end of [funmap_avltree.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/hashtable_linprb.dats0000664000175000017500000005514012223166162022171 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A hashtable implementation based on linear probing ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/hashtable_linprb.sats" (* ****** ****** *) sortdef t0p = t@ype and vt0p = viewt@ype (* ****** ****** *) // // HX-2010-03-20: // special versions of these two functions can be implemented // on the spot for gaining some efficiency // implement{key} hash_key (x, hash) = hash (x) implement{key} equal_key_key (x1, x2, eqfn) = eqfn (x1, x2) (* ****** ****** *) stadef sizeof2 (a1:viewt@ype, a2: viewt@ype) = sizeof @(a1, a2) // end of [sizeof2] stadef b2i = int_of_bool dataview hashtbl_v // it is just an array of chains (key:t@ype, itm:viewt@ype+, int(*sz*), addr, addr) = | {sz:nat} {b:bool} {l_beg,l_end:addr} hashtbl_v_cons (key, itm, sz+1, l_beg, l_end) of (Opt @(key, itm) @ l_beg, hashtbl_v (key, itm, sz, l_beg+sizeof2(key,itm), l_end)) | {l:addr} hashtbl_v_nil (key, itm, 0, l, l) // end of [hashtbl_v] viewtypedef HASHTBL ( key: t0p, itm: vt0p, sz: int, l_beg: addr, l_end: addr ) = @{ pfgc= free_gc_v (l_beg) , pftbl= hashtbl_v (key, itm, sz, l_beg, l_end) , sz= size_t sz , tot= size_t , pbeg= ptr l_beg , hash= hash key , eqfn = eqfn key } // end of [HASHTBL] viewtypedef HASHTBL (key: t0p, itm: vt0p) = [sz:int;l_beg,l_end:addr] [sz > 0] HASHTBL (key, itm, sz, l_beg, l_end) // end of [HASHTBL] extern typedef "HASHTBL" = HASHTBL (void, void) extern castfn HASHTBLptr_tblget {key:t0p;itm:vt0p} {l:agz} (ptbl: !HASHTBLptr (key, itm, l)) :<> (HASHTBL (key, itm) @ l, minus (HASHTBLptr (key, itm, l), HASHTBL (key, itm) @ l) | ptr l) // end of [HASHTBLptr_get] (* ****** ****** *) implement hashtbl_size {key,itm} (ptbl) = sz where { val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val sz = p->sz prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_size] implement hashtbl_total {key,itm} (ptbl) = tot where { val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val tot = p->tot prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_total] implement{key,itm} hashtbl_clear (ptbl) = () where { viewtypedef keyitm = @(key, itm) val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val () = __clear (p->pbeg, p->sz, sizeof) where { extern fun __clear (pbeg: ptr, sz: size_t, keyitmsz: size_t):<> void = "atslib_hashtbl_ptr_clear__linprb" } // end of [val] val () = p->tot := (size_of_int1)0 prval () = minus_addback (fpf, pf | ptbl) } // [hashtbl_clear] (* ****** ****** *) extern fun hashtbl_ptr_make {key:t0p;itm:vt0p} {sz:pos} (sz: size_t sz, keyitmsz: sizeof_t @(key,itm)) :<> [l_beg,l_end:addr] @( free_gc_v l_beg, hashtbl_v (key, itm, sz, l_beg, l_end) | ptr l_beg ) // end of [hashtbl_ptr_make] = "atslib_hashtbl_ptr_make__linprb" // end of [hashtbl_ptr_make] extern fun hashtbl_ptr_free {key:t0p;itm:vt0p} {sz:pos} {l_beg,l_end:addr} ( pf_gc: free_gc_v l_beg , pf_tbl: hashtbl_v (key, itm, sz, l_beg, l_end) | p_beg: ptr l_beg ) :<> void = "atslib_hashtbl_ptr_free__linprb" // end of [hashtbl_ptr_free] (* ****** ****** *) extern prfun // proof is omitted hashtbl_v_split {key:t0p;itm:vt0p} {sz,sz1:nat | sz1 <= sz} {l_beg,l_end:addr} {ofs:int} ( pf_mul: MUL (sz1, sizeof2 (key,itm), ofs) , pf_tbl: hashtbl_v (key, itm, sz, l_beg, l_end) ) :<> @( hashtbl_v (key, itm, sz1, l_beg, l_beg+ofs) , hashtbl_v (key, itm, sz-sz1, l_beg+ofs, l_end) ) // end of [hashtbl_v_split] extern prfun // proof is omitted hashtbl_v_unsplit {key:t0p;itm:vt0p} {sz1,sz2:nat} {l_beg,l_mid,l_end:addr} ( pf1: hashtbl_v (key, itm, sz1, l_beg, l_mid) , pf2: hashtbl_v (key, itm, sz2, l_mid, l_end) ) : hashtbl_v (key, itm, sz1+sz2, l_beg, l_end) // end of [hashtbl_v_unsplit] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_split {sz,sz1:nat | sz1 <= sz} {l_beg,l_end:addr} ( pf_tbl: hashtbl_v (key, itm, sz, l_beg, l_end) | pbeg: ptr l_beg, sz1: size_t sz1 ) :<> [l_mid:addr] @( hashtbl_v (key, itm, sz1, l_beg, l_mid) , hashtbl_v (key, itm, sz-sz1, l_mid, l_end) | ptr l_mid ) = let viewtypedef keyitm = @(key, itm) val (pf_mul | ofs) = mul2_size1_size1 (sz1, sizeof) prval (pf1_tbl, pf2_tbl) = hashtbl_v_split {key,itm} (pf_mul, pf_tbl) in (pf1_tbl, pf2_tbl | pbeg + ofs) end // end of [hashtbl_ptr_split] (* ****** ****** *) extern castfn size1_of_ulint (x: ulint):<> [i:nat] size_t i (* ****** ****** *) #define i2sz size1_of_int1 #define sz1mul mul_size1_size1 #define sz1mod mod1_size1_size1 (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_probe_ofs {sz,ofs:nat | ofs < sz} {l_beg,l_end:addr} ( pf: !hashtbl_v (key, itm, sz, l_beg, l_end) | pbeg: ptr l_beg , k0: key, eqfn: eqfn key, sz: size_t sz, ofs: size_t ofs , found: &bool? >> bool ) :<> Ptr (* pointing to the found item or where it should be *) = let val (pf1, pf2 | p_mid) = hashtbl_ptr_split {sz,ofs} (pf | pbeg, ofs) viewtypedef keyitm = @(key, itm) val keyitmsz = sizeof fun loop {n:nat} {l1,l2:addr} .. ( pf: !hashtbl_v (key, itm, n, l1, l2) | p1: ptr l1, n: size_t n, pres: &Ptr, found: &bool ) : void = if n > 0 then let prval hashtbl_v_cons (pf1, pf2) = pf val isnotnull = keyitem_isnot_null (!p1) val () = if isnotnull then let prval () = opt_unsome {keyitm} (!p1) val k = p1->0 prval () = Opt_some {keyitm} (!p1) in if equal_key_key (k0, k, eqfn) then (pres := p1; found := true) else loop (pf2 | p1 + keyitmsz, n-1, pres, found) // end of [if] end else let prval () = Opt_encode {keyitm} (!p1) in pres := p1 end // end of [if] prval () = pf := hashtbl_v_cons (pf1, pf2) in // nothing end // end of [if] // end of [loop] var pres: Ptr = null val () = found := false val () = loop (pf2 | p_mid, sz - ofs, pres, found) val () = if :(found: bool) => pres = null then loop (pf1 | pbeg, ofs, pres, found) else () prval () = pf := hashtbl_v_unsplit (pf1, pf2) in pres end // end of [hashtbl_ptr_probe_ofs] implement{key,itm} hashtbl_search_ref (ptbl, k0) = let val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h); val ofs = sz1mod (h, p->sz) var found: bool // uninitalized val [l:addr] pkeyitm = hashtbl_ptr_probe_ofs (p->pftbl | p->pbeg, k0, p->eqfn, p->sz, ofs, found) prval () = minus_addback (fpf, pf | ptbl) in if found then let prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm) @ l, (key,itm) @ l - void) } // end of [prval] val pitm = &(pkeyitm->1) prval () = fpf (pf) in pitm end else null end // end of [hashtbl_search_ref] (* ****** ****** *) implement{key,itm} hashtbl_search (ptbl, k0, res) = let val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h); val ofs = sz1mod (h, p->sz) var found: bool // uninitalized val [l:addr] pkeyitm = hashtbl_ptr_probe_ofs (p->pftbl | p->pbeg, k0, p->eqfn, p->sz, ofs, found) prval () = minus_addback (fpf, pf | ptbl) in if found then let prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm) @ l, (key,itm) @ l - void) } // end of [prval] val () = res := pkeyitm->1 prval () = opt_some {itm} (res) prval () = fpf (pf) in true end else let prval () = opt_none {itm} (res) in false end // end of [if] end // end of [hashtbl_search] (* ****** ****** *) #define HASHTABLE_DOUBLE_FACTOR 2 (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_relocate {sz1:nat;sz2:pos} .. {l1_beg,l2_beg,l1_end,l2_end:addr} ( pf1: !hashtbl_v (key, itm, sz1, l1_beg, l1_end) , pf2: !hashtbl_v (key, itm, sz2, l2_beg, l2_end) | sz1: size_t sz1, sz2: size_t sz2, p1_beg: ptr l1_beg, p2_beg: ptr l2_beg , fhash: hash key, eqfn: eqfn key ) :<> void = let viewtypedef keyitm = @(key, itm) in if sz1 > 0 then let prval hashtbl_v_cons (pf11, pf12) = pf1 val isnotnull = keyitem_isnot_null (!p1_beg) val () = if isnotnull then let prval () = opt_unsome {keyitm} (!p1_beg) val k0 = p1_beg->0 val i0 = p1_beg->1 prval () = Opt_none {keyitm} (!p1_beg) val h = hash_key (k0, fhash) val h = size1_of_ulint (h); val ofs = sz1mod (h, sz2) var found: bool // uninitalized val [l:addr] pkeyitm = hashtbl_ptr_probe_ofs (pf2 | p2_beg, k0, eqfn, sz2, ofs, found) prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm?) @ l, (key,itm) @ l - void) } // end of [prval] val () = pkeyitm->0 := k0 val () = pkeyitm->1 := i0 prval () = fpf (pf) in // nothing end else let prval () = Opt_encode {keyitm} (!p1_beg) in (*nothing*) end // end of [if] val () = hashtbl_ptr_relocate (pf12, pf2 | sz1-1, sz2, p1_beg+sizeof, p2_beg, fhash, eqfn) prval () = pf1 := hashtbl_v_cons (pf11, pf12) in // empty end // end of [if] end // end of [hashtbl_ptr_relocate] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_resize {l:agz} {sz_new:pos} ( ptbl: !HASHTBLptr (key, itm, l), sz_new: size_t sz_new ) :<> void = () where { viewtypedef keyitm = @(key, itm) val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val (pfgc2, pftbl2 | pbeg2) = hashtbl_ptr_make {key,itm} (sz_new, sizeof) val () = hashtbl_ptr_relocate (p->pftbl, pftbl2 | p->sz, sz_new, p->pbeg, pbeg2, p->hash, p->eqfn) val () = hashtbl_ptr_free (p->pfgc, p->pftbl | p->pbeg) prval () = p->pfgc := pfgc2 prval () = p->pftbl := pftbl2 val () = p->sz := sz_new val () = p->pbeg := pbeg2 prval () = minus_addback (fpf, pf | ptbl) (* val () = $effmask_all begin print "hashtbl_resize(aft): sz_new = "; print sz_new; print_newline () end // end of [val] *) } // end of [hashtbl_resize] (* ****** ****** *) fn{key:t0p;itm:vt0p} hashtbl_ptr_reinsert {sz:pos} {l_beg,l_end:addr} ( pf: !hashtbl_v (key, itm, sz, l_beg, l_end) | sz: size_t sz, p_beg: ptr l_beg, fhash: hash key, pkeyitm: Ptr ) :<> void = let viewtypedef keyitm = @(key, itm) viewtypedef keyitmopt = Opt @(key, itm) extern praxi __assert1 {l:addr} (p: ptr l): (keyitmopt @ l, keyitmopt @ l - void) extern praxi __assert2 {l:addr} (p: ptr l): ((key,itm?) @ l, (key,itm) @ l - void) extern praxi __assert3 {l:addr} (p: ptr l): ((key,itm) @ l, keyitmopt @ l - void) val p_end = p_beg + sz1mul (sz, sizeof) fun ins {l1,l2:addr} (p1: ptr l1, p2: ptr l2, i0: &itm >> opt (itm, b)): #[b:bool] bool b = if p1 < p2 then let prval (pf, fpf) = __assert1 (p1) val isnotnull = keyitem_isnot_null (!p1) prval () = Opt_encode {keyitm} (!p1) prval () = fpf (pf) in if isnotnull then ins (p1+sizeof, p2, i0) // trying the next slot else let // an empty slot is found prval (pf, fpf) = __assert2 (p1) val () = p1->1 := i0 prval () = fpf (pf) prval () = opt_none {itm} (i0) in false(*inserted*) // nothing is left end // end of [if] end else let prval () = opt_some {itm} (i0) in true(*notinserted*) // item is left end // end of [if] // end of [ins] fun rem {l1,l2:addr} (p1: ptr l1, p2: ptr l2): bool = if p1 < p2 then let prval (pf, fpf) = __assert1 (p1) val isnotnull = keyitem_isnot_null (!p1) prval () = Opt_encode {keyitm} (!p1) prval () = fpf (pf) in if isnotnull then let prval (pf, fpf) = __assert3 (p1) var i0 = p1->1 val h = hash_key (p1->0, fhash) val () = keyitem_nullify (!p1) prval () = fpf (pf) val h = size1_of_ulint (h) val ofs = sz1mod (h, sz) val p_cur = p_beg + sz1mul (ofs, sizeof) val b1 = ins (p_cur, p_end, i0) val () = if :(i0: itm?) => (b1) then let prval () = opt_unsome {itm} (i0) val b2 = ins (p_beg, p_cur, i0) prval () = __assert (b2) where { // the item must have been inserted at this point extern praxi __assert {b:bool} (b: bool b): [b==false] void } // end of [val] prval () = opt_unnone {itm} (i0) in // nothing end else let prval () = opt_unnone {itm} (i0) in // nothing end // end of [if] in rem (p1+sizeof, p2) end else true(*done*) end else false(*notdone*) // end of [rem] val done = $effmask_all ( if rem (pkeyitm+sizeof, p_end) then true else rem (p_beg, pkeyitm) ) : bool in // nothing end // end of [hashtbl_ptr_reinsert] (* ****** ****** *) implement{key,itm} hashtbl_insert (ptbl, k0, i0, res) = found where { val (pf0, fpf0 | p) = HASHTBLptr_tblget {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h) val sz = p->sz val ofs = sz1mod (h, sz) var found: bool // uninitalized var doubleTag: int = 0 val [l:addr] pkeyitm = hashtbl_ptr_probe_ofs (p->pftbl | p->pbeg, k0, p->eqfn, sz, ofs, found) val [b:bool] found = bool1_of_bool (found) val () = (if :(res: opt (itm, b)) => found then let prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm) @ l, (key,itm) @ l - void) } // end of [prval] val i = pkeyitm->1 val () = pkeyitm->1 := i0 val () = res := i prval () = fpf (pf) prval () = opt_some {itm} (res) in // nothing end else let val tot = p->tot val () = p->tot := tot + 1 // prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm?) @ l, (key,itm) @ l - void) } // end of [prval] val () = pkeyitm->0 := k0 val () = pkeyitm->1 := i0 prval () = fpf (pf) // prval () = opt_none {itm} (res) // val () = if ( HASHTABLE_DOUBLE_FACTOR * (double_of_size)tot >= (double_of_size)sz ) then doubleTag := 1 // end of [if] // in // nothing end) : void // end of [if] prval () = minus_addback (fpf0, pf0 | ptbl) val () = if (doubleTag > 0) then hashtbl_resize (ptbl, sz + sz) } // end of [hashtbl_insert] (* ****** ****** *) (* fun{key:t@ype;itm:viewt@ype} hashtbl_remove {l:agz} ( ptbl: !HASHTBLptr (key, itm, l), k0: key, res: &itm? >> opt (itm, b) ) :<> #[b:bool] bool b // end of [hashtbl_remove] *) implement{key,itm} hashtbl_remove {l} (ptbl, k0, res) = found where { val (pf0, fpf0 | p) = HASHTBLptr_tblget {key,itm} (ptbl) val h = hash_key (k0, p->hash) val h = size1_of_ulint (h) val sz = p->sz val ofs = sz1mod (h, sz) var found: bool // uninitalized // var halfTag: int = 0 // no shrinking val [l:addr] pkeyitm = hashtbl_ptr_probe_ofs (p->pftbl | p->pbeg, k0, p->eqfn, sz, ofs, found) val [b:bool] found = bool1_of_bool (found) val () = (if :(res: opt (itm, b)) => found then let val tot = p->tot val () = p->tot := tot - 1 prval (pf, fpf) = __assert () where { extern praxi __assert (): ((key,itm) @ l, (key,itm?) @ l - void) } // end of [prval] val () = res := pkeyitm->1 prval () = fpf (pf) prval () = opt_some {itm} (res) in hashtbl_ptr_reinsert (p->pftbl | sz, p->pbeg, p->hash, pkeyitm) end else let prval () = opt_none {itm} (res) in // nothing end) : void // end of [if] prval () = minus_addback (fpf0, pf0 | ptbl) } // end of [hashtbl_remove] (* ****** ****** *) fun{key:t0p;itm:vt0p} hashtbl_ptr_foreach_vclo {v:view} {sz:nat} {l_beg,l_end:addr} {f:eff} .. ( pf: !v, pf_tbl: !hashtbl_v (key, itm, sz, l_beg, l_end) | sz: size_t sz, pbeg: ptr l_beg, f: &(!v | key, &itm) - void ) : void = begin if sz > 0 then let viewtypedef keyitm = @(key, itm) prval hashtbl_v_cons (pf1_tbl, pf2_tbl) = pf_tbl val isnotnull = keyitem_isnot_null (!pbeg) val () = if isnotnull then let prval () = opt_unsome {keyitm} (!pbeg) val () = f (pf | pbeg->0, pbeg->1) prval () = Opt_some {keyitm} (!pbeg) in // nothing end else let prval () = Opt_encode {keyitm} (!pbeg) in // nothing end // end of [val] val () = // segfault during typechecking if {v} is not provided!!! hashtbl_ptr_foreach_vclo {v} (pf, pf2_tbl | sz-1, pbeg+sizeof, f) prval () = pf_tbl := hashtbl_v_cons (pf1_tbl, pf2_tbl) in // empty end // end of [if] end // end of [hashtbl_ptr_foreach_vclo] implement{key,itm} hashtbl_foreach_vclo {v} (pf0 | ptbl, f) = () where { val (pf, fpf | p) = HASHTBLptr_tblget {key,itm} (ptbl) val () = begin hashtbl_ptr_foreach_vclo {v} (pf0, p->pftbl | p->sz, p->pbeg, f) end // end of [val] prval () = minus_addback (fpf, pf | ptbl) } // end of [hashtbl_foreach_vclo] implement{key,itm} hashtbl_foreach_cloref (tbl, f) = let val f = __cast (f) where { extern castfn __cast (f: (key, &itm) - void):<> (!unit_v | key, &itm) - void } // end of [val] typedef T = (!unit_v | key, &itm) - void val [l:addr] (pfbox | p_f) = cloref_get_view_ptr {T} (f) viewdef V = T @ l prval (pf, fpf) = __assert (pfbox) where { extern praxi __assert (_: vbox V): (V, V - void) } // end of [prval] prval pf0 = unit_v () val () = hashtbl_foreach_vclo {unit_v} (pf0 | tbl, !p_f) prval unit_v () = pf0 prval () = fpf (pf) in // empty end // end of [hashtbl_foreach_cloref] (* ****** ****** *) // #define HASHTABLE_MINSZ 97 // HX: it is chosen arbitrarily // extern fun hashtbl_make_hint_tsz {key:t@ype;itm:viewt@ype} ( hash: hash key , eqfn: eqfn key , hint: size_t , keyitmsz: sizeof_t @(key,itm) ) :<> HASHTBLptr1 (key, itm) // tot = 0 = "atslib_hashtbl_make_hint_tsz__linprb" // end of [hashtbl_make_hint_tsz] implement{key,itm} hashtbl_make (_hash, _eqfn) = let viewtypedef keyitm = @(key, itm) in hashtbl_make_hint_tsz {key,itm} (_hash, _eqfn, 0, sizeof) end // end of [hashtbl_make] implement{key,itm} hashtbl_make_hint (_hash, _eqfn, hint) = let viewtypedef keyitm = @(key, itm) in hashtbl_make_hint_tsz {key,itm} (_hash, _eqfn, hint, sizeof) end // end of [hashtbl_make_hint] (* ****** ****** *) // // HX-2010-07-01: is this really needed? // implement{key,itm} hashtbl_listize (ptbl) = let typedef keyitm = @(key, itm) var res: List_vt keyitm = list_vt_nil () viewdef V = List_vt keyitm @ res var !p_clo = @lam ( pf: !V | k: key, x: &itm ) : void = (res := list_vt_cons ((k, x), res)) // end of [var] val () = hashtbl_foreach_vclo {V} (view@ res | ptbl, !p_clo) in res end // end of [hashtbl_listize] implement{key,itm} hashtbl_listize_free {l} (ptbl) = kis where { typedef keyitm0 = @(key, itm?) viewtypedef keyitm = @(key, itm) val ptbl = __cast (ptbl) where { extern castfn __cast (x: HASHTBLptr (key, itm, l)):<> HASHTBLptr (key, itm?, l) } // end of [val] val kis = hashtbl_listize (ptbl) val () = hashtbl_free (ptbl) val kis = __cast (kis) where { extern castfn __cast {n:int} (x: list_vt (keyitm0, n)):<> list_vt (keyitm, n) } // end of [val] } // end of [hashtbl_listize_free] (* ****** ****** *) %{$ // // declared in [string.h] // #ifndef memset extern void *memset (void *buf, int chr, size_t n) ; #endif // ats_ptr_type atslib_hashtbl_ptr_make__linprb (ats_size_type sz, ats_size_type keyitmsz) { ats_ptr_type pbeg ; /* zeroing the allocated memory is mandatory! */ pbeg = ATS_CALLOC(sz, keyitmsz) ; return pbeg ; } // end of [atslib_hashtbl_ptr_make__linprb] // ats_void_type atslib_hashtbl_ptr_clear__linprb ( ats_ptr_type ptbl, ats_size_type sz, ats_size_type keyitmsz ) { memset (ptbl, 0, sz * keyitmsz) ; return ; } // end of [atslib_hashtbl_clear__linprb] // ats_void_type atslib_hashtbl_ptr_free__linprb (ats_ptr_type pbeg) { ATS_FREE(pbeg) ; return ; } // end of [atslib_hashtbl_ptr_free__linprb] // %} // end of [%{$] (* ****** ****** *) %{$ // // HX: shortcuts? yes. worth it? probably. // #define HASHTABLE_MINSZ 97 // it is chosen arbitrarily // ats_ptr_type atslib_hashtbl_make_hint_tsz__linprb ( ats_clo_ref_type hash , ats_clo_ref_type eqfn , ats_size_type hint , ats_size_type keyitmsz ) { size_t sz ; HASHTBL *ptbl ; void *pbeg ; ptbl = ATS_MALLOC(sizeof(HASHTBL)) ; sz = (hint > 0 ? hint : HASHTABLE_MINSZ) ; /* zeroing the allocated memory is mandatory! */ pbeg = ATS_CALLOC(sz, keyitmsz) ; ptbl->atslab_sz = sz ; ptbl->atslab_tot = 0 ; ptbl->atslab_pbeg = pbeg ; ptbl->atslab_hash = hash ; ptbl->atslab_eqfn = eqfn ; return ptbl ; } // end of [atslib_hashtbl_make_hint_tsz__linprb] // ats_void_type atslib_hashtbl_free__linprb (ats_ptr_type ptbl) { ATS_FREE(((HASHTBL*)ptbl)->atslab_pbeg) ; ATS_FREE(ptbl) ; return ; } // end of [atslib_hashtbl_free__linprb] // ats_void_type atslib_hashtbl_free_null__linprb (ats_ptr_type ptbl) { return ; } // end of [atslib_hashtbl_free_null__linprb] // ats_int_type atslib_hashtbl_free_vt__linprb (ats_ptr_type ptbl) { if (((HASHTBL*)ptbl)->atslab_tot != 0) return 1 ; ATS_FREE(((HASHTBL*)ptbl)->atslab_pbeg) ; ATS_FREE(ptbl) ; return 0 ; } // end of [atslib_hashtbl_free_vt__linprb] // %} // end of [%{$] (* ****** ****** *) (* end of [hashtable_linprb.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/intinf.dats0000664000175000017500000002216412223166162020157 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // infinite precision integers based on the gmp package (* ****** ****** *) %{^ #include "libc/CATS/gmp.cats" %} // end of [%{^] (* ****** ****** *) staload "libc/SATS/gmp.sats" staload "libats/SATS/intinf.sats" (* ****** ****** *) assume intinf (i: int) = // HX: [i] is a fake [l:addr] (free_gc_v (mpz_vt?, l), mpz_vt @ l | ptr l) // end of [intinf] (* ****** ****** *) implement intinf_make_int {i} (i) = let val (pf_gc, pf_at | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init_set_int (!p, i) in @(pf_gc, pf_at | p) end // end of [intinf_make_int] implement intinf_make_lint (i) = let val @(pf_gc, pf_at | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val i = lint_of_lint1 (i) where { extern castfn lint_of_lint1 {i:int} (x: lint i):<> lint } // end of [val] val () = mpz_init_set_lint (!p, i) in @(pf_gc, pf_at | p) end // end of [intinf_make_lint] implement intinf_make_llint (i) = let val @(pf_gc, pf_at | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val i = llint_of_llint1 (i) where { extern castfn llint_of_llint1 {i:int} (x: llint i):<> llint } // end of [val] val i = double_of_llint (i) val () = mpz_init_set_double (!p, i) in @(pf_gc, pf_at | p) end // end of [intinf_make_llint] implement intinf_make_double (d) = let val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init_set_double (!p, d) in #[0 | (pfgc, pfat | p)] // HX: [0] is just a place holder end // end of [intinf_make_double] implement intinf_make_string (rep) = let val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init_set_str_exn (!p, rep, 10(*base*)) in #[0 | (pfgc, pfat | p)] // HX: [0] is just a place holder end // end of [intinf_make_double] (* ****** ****** *) implement intinf_free @(pf_gc, pf_at | p) = (mpz_clear (!p); ptr_free {mpz_vt?} (pf_gc, pf_at | p)) // end of [intinfptr_free] (* ****** ****** *) implement fprint0_intinf (out, intinf) = fprint0_intinf_base (out, 10, intinf) // end of [fprint0_intinf] implement fprint1_intinf (pf | fil, intinf) = fprint1_intinf_base (pf | fil, 10, intinf) // end of [fprint1_intinf] implement print_intinf (intinf) = print_mac (fprint1_intinf, intinf) (* ****** ****** *) implement fprint0_intinf_base (out, base, intinf) = let val [l:addr] (pffil | p) = __cast (out) where { extern castfn __cast (out: FILEref): [l:addr] (FILE(w) @ l | ptr l) // end of [extern] } // end of [val] val () = fprint1_intinf_base (file_mode_lte_w_w | !p, base, intinf) prval () = __free (pffil) where { extern praxi __free (pf: FILE(w) @ l): void } // end of [prval] in (*nothing*) end // end of [fprint0_intinf_base] implement fprint1_intinf_base (pf | fil, base, intinf) = () where { prval pfat = intinf.1 val n = mpz_out_str (pf | fil, base, !(intinf.2)) prval () = intinf.1 := pfat val () = assert_errmsg (n > 0, "exit(ATS): [fprint_intinf_base] failed.\n") } // end of [fprint1_intinf_base] implement print_intinf_base (base, intinf) = let val (pf_stdout | p_stdout) = stdout_get () val () = fprint1_intinf_base (file_mode_lte_w_w | !p_stdout, base, intinf) val () = stdout_view_set (pf_stdout | (*none*)) in // empty end // end of [print_intinf_base] (* ****** ****** *) implement pred_intinf (intinf) = let prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_sub (!p, !(intinf.2), 1) prval () = intinf.1 := pf in @(pfgc, pfat | p) end // end of [pred_intinf] implement succ_intinf (intinf) = let prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_add (!p, !(intinf.2), 1) prval () = intinf.1 := pf in @(pfgc, pfat | p) end // end of [succ_intinf] (* ****** ****** *) implement add_intinf_int (intinf, i) = let prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_add (!p, !(intinf.2), i) prval () = intinf.1 := pf in @(pfgc, pfat | p) end // end of [add_intinf_int] implement add_intinf_intinf (intinf1, intinf2) = let prval pf1 = intinf1.1 prval pf2 = intinf2.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_add (!p, !(intinf1.2), !(intinf2.2)) prval () = intinf1.1 := pf1 prval () = intinf2.1 := pf2 in @(pfgc, pfat | p) end // end of [add_intinf_intinf] (* ****** ****** *) implement sub_intinf_int (intinf, i) = let prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_sub (!p, !(intinf.2), i) prval () = intinf.1 := pf in @(pfgc, pfat | p) end // end of [sub_intinf_int] implement sub_intinf_intinf (intinf1, intinf2) = let prval pf1 = intinf1.1 prval pf2 = intinf2.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_sub (!p, !(intinf1.2), !(intinf2.2)) prval () = intinf1.1 := pf1 prval () = intinf2.1 := pf2 in @(pfgc, pfat | p) end // end of [sub_intinf_intinf] (* ****** ****** *) implement mul_int_intinf {m,n} (int, intinf) = let prval pfmul = mul_make {m,n} () prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_mul (!p, !(intinf.2), int) prval () = intinf.1 := pf in @(pfmul | @(pfgc, pfat | p)) end // end of [mul_int_intinf] implement mul_intinf_int {m,n} (intinf, int) = let prval pfmul = mul_make {m,n} () prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_mul (!p, !(intinf.2), int) prval () = intinf.1 := pf in @(pfmul | @(pfgc, pfat | p)) end // end of [mul_intinf_int] implement mul_intinf_intinf {m,n} (intinf1, intinf2) = let prval pfmul = mul_make {m,n} () prval pf1 = intinf1.1 prval pf2 = intinf2.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p); val () = mpz_mul (!p, !(intinf1.2), !(intinf2.2)) prval () = intinf1.1 := pf1 prval () = intinf2.1 := pf2 in @(pfmul | @(pfgc, pfat | p)) end // end of [mul_intinf_intinf] (* ****** ****** *) implement square_intinf {n} (intinf) = let prval pf = intinf.1 prval pfmul = mul_make {n,n} () val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init_set (!p, !(intinf.2)); val () = mpz_mul (!p, !(intinf.2)) prval () = intinf.1 := pf in @(pfmul | @(pfgc, pfat | p)) end // end of [square_intinf] (* ****** ****** *) implement fdiv_intinf_int {m,n} (intinf, i) = let prval [q,r:int] pfmul = lemma () where { extern prfun lemma () : [q,r:int | 0 <= r; r < n] MUL (q, n, m-r) } // end of [prval] prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p) val ui = ulint_of_int i; val _(*remainder*) = mpz_fdiv_q (!p, !(intinf.2), ui) prval () = intinf.1 := pf in #[q,r | @(pfmul | @(pfgc, pfat | p))] end // end of [fdiv_intinf_int] implement fmod_intinf_int {m,n} (intinf, i) = let prval [q,r:int] pfmul = div_lemma {m,n} () where { extern praxi div_lemma {m,n:int | n > 0} () : [q,r:int | 0 <= r; r < n] MUL (q, n, m-r) } // end of [prval] prval pf = intinf.1 val @(pfgc, pfat | p) = ptr_alloc_tsz {mpz_vt} (sizeof) val () = mpz_init (!p) val ui = ulint_of_int i; val _(*remainder*) = mpz_mod (!p, !(intinf.2), ui) prval () = intinf.1 := pf val r = mpz_get_int (!p) val [r1:int] r = int1_of_int r prval () = __assert () where { extern prfun __assert (): [r==r1] void } val () = intinf_free @(pfgc, pfat | p) in #[q,r | @(pfmul | r)] end // end of [fmod_intinf_int] (* ****** ****** *) (* end of [intinf.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/gflist.dats0000664000175000017500000000542212223166162020156 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: December, 2010 // (* ****** ****** *) // // HX: generic fully indexed lists // (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) staload "libats/SATS/ilistp.sats" (* ****** ****** *) staload "libats/SATS/gflist.sats" (* ****** ****** *) implement{a} gflist_length (xs) = let val (pf | xs) = list_of_gflist {a} (xs) // no-op casting // end of [val] val n = list_length (xs) in (pf | n) end // end of [gflist_length] (* ****** ****** *) implement{a} gflist_append {xs,ys} (xs, ys) = let val (_pf | xs) = list_of_gflist {a} (xs) val (_pf | ys) = list_of_gflist {a} (ys) val res = list_append (xs, ys) val [res:ilist] (_pf | res) = gflist_of_list (res) prval pfres = __assert () where { extern prfun __assert (): APPEND (xs, ys, res) } // end of [prval] in (pfres | res) end // end of [gflist_append] (* ****** ****** *) implement{a} gflist_revapp {xs,ys} (xs, ys) = let val (_pf | xs) = list_of_gflist {a} (xs) val (_pf | ys) = list_of_gflist {a} (ys) val res = list_reverse_append (xs, ys) val [res:ilist] (_pf | res) = gflist_of_list (res) prval pfres = __assert () where { extern prfun __assert (): REVAPP (xs, ys, res) } // end of [prval] in (pfres | res) end // end of [gflist_append] (* ****** ****** *) (* end of [gflist.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/freelst.dats0000664000175000017500000000707112223166162020334 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A simple implementation of free-lists (of memory items) ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: August, 2009 ** *) (* ****** ****** *) staload "libats/SATS/freelst.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) %{^ ats_ptr_type atslib_freeitm_nxt_get (ats_ptr_type x) { return *((ats_ptr_type*)x) ; } /* end of [freeitm_nxt_get] */ ats_void_type atslib_freeitm_nxt_set (ats_ptr_type x, ats_ptr_type p) { *((ats_ptr_type*)x) = p ; return ; } /* end of [freeitm_nxt_set] */ %} (* ****** ****** *) implement freelst_cons {a} {l_at,l} (pf_at, pf | p_at, p) = let // extern prfun freeitm_of (pf: !a? @ l_at >> freeitm_t a @ l_at): void // prval () = freeitm_of (pf_at) val () = freeitm_nxt_set {a} (!p_at, p) prval () = pf := freelst_v_cons {a} (pf_at, pf) in // nothing end // end of [freelst_cons] implement freelst_uncons {a} {l} (pf | p) = let prval (pf1, pf2) = freelst_v_uncons {a} (pf) val p1 = freeitm_nxt_get {a} (!p); prval () = pf := pf2 // extern prfun of_freeitm (pf: !freeitm_t a @ l >> a? @ l): void // prval () = of_freeitm (pf1) in (pf1 | p1) end // end of [freelst_uncons] (* ****** ****** *) implement{a} freelst_add_bytes (pf, pf_arr | p, p_arr, n) = freelst_add_bytes_tsz (pf, pf_arr | p, p_arr, n, sizeof) // end of [freelst_add_bytes] implement freelst_add_bytes_tsz {a} {l} {n} {l_arr} (pf, pf_arr | p, p_arr, n, tsz) = let // extern prfun freeitm_of_bytes {l0:addr} (pf: b0ytes (sizeof a) @ l0): freeitm_t a @ l0 // extern prfun bytes_v_split {n,i:nat | i <= n} {l:addr} (pf: b0ytes n @ l): @(b0ytes i @ l, b0ytes (n-i) @ (l+i)) // in if n >= tsz then let prval (pf1, pf2_arr) = bytes_v_split {n,sizeof a} (pf_arr) prval pf1 = freeitm_of_bytes (pf1) val () = freeitm_nxt_set {a} (!p_arr, p) prval () = pf := freelst_v_cons (pf1, pf) in freelst_add_bytes_tsz (pf, pf2_arr | p_arr, p_arr + tsz, n - tsz, tsz) end else let // prval () = __leak (pf_arr) where { extern prfun __leak {v:view} (pf: v): void } // in p // loop exits end // end of [if] end (* end of [freelst_add_bytes_tsz] *) (* ****** ****** *) (* end of [freelst.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linqueue_arr.dats0000664000175000017500000001063112223166162021357 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** An array-based queue implementation ** Author: hwxi AT cs DOT bu DOT edu ** Time: March, 2011 *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload DQ = "libats/ngc/SATS/deque_arr.sats" (* ****** ****** *) staload "libats/SATS/linqueue_arr.sats" (* ****** ****** *) assume QUEUE ( a:viewt@ype, m:int, n:int ) = $DQ.DEQUE (a, m, n) (* ****** ****** *) implement queue_cap (q) = $DQ.deque_cap (q) implement queue_size (q) = $DQ.deque_size (q) implement queue_is_empty (q) = $DQ.deque_is_empty (q) implement queue_isnot_empty (q) = $DQ.deque_isnot_empty (q) implement queue_is_full (q) = $DQ.deque_is_full (q) implement queue_isnot_full (q) = $DQ.deque_isnot_full (q) (* ****** ****** *) implement{a} queue_initialize (q, m) = let val (pfgc, pfarr | parr) = array_ptr_alloc (m) in $DQ.deque_initialize (pfgc, pfarr | q, m, parr) end // end of [queue_initialize] implement queue_initialize_tsz {a} (q, m, tsz) = let val (pfgc, pfarr | parr) = array_ptr_alloc_tsz {a} (m, tsz) in $DQ.deque_initialize_tsz {a} (pfgc, pfarr | q, m, parr, tsz) end // end of [queue_initialize_tsz] (* ****** ****** *) // // HX-2010-03-29: // the function is given the external name: // atslib_linqueue_arr_queue_uninitialize // implement queue_uninitialize {a} (q) = () where { val (pfgc, pfarr | parr) = $DQ.deque_uninitialize (q) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [queue_uninitialize] implement queue_uninitialize_vt {a} (q) = () where { val (pfgc, pfarr | parr) = $DQ.deque_uninitialize_vt (q) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [queue_uninitialize_vt] (* ****** ****** *) implement{a} queue_get_elt_at (q, i) = $DQ.deque_get_elt_at (q, i) // end of [queue_get_elt_at] implement{a} queue_set_elt_at (q, i, x) = $DQ.deque_set_elt_at (q, i, x) // end of [queue_set_elt_at] (* ****** ****** *) implement{a} queue_insert (q, x) = $DQ.deque_insert_end (q, x) // end of [queue_insert] implement{a} queue_insert_many (q, k, xs) = $DQ.deque_insert_end_many (q, k, xs) // end of [queue_insert_many] (* ****** ****** *) implement{a} queue_remove (q) = $DQ.deque_remove_beg (q) implement{a} queue_remove_many (q, k, xs) = $DQ.deque_remove_beg_many (q, k, xs) // end of [queue_remove_many] (* ****** ****** *) implement{a} queue_clear (q, n2) = $DQ.deque_clear_beg (q, n2) // end of [queue_clear] implement queue_clear_all (q) = $DQ.deque_clear_all (q) (* ****** ****** *) implement{a} queue_copyout (q, i, k, xs) = $DQ.deque_copyout (q, i, k, xs) // end of [queue_copyout] (* ****** ****** *) implement{a} queue_update_capacity (q, m2) = () where { val (pfgc, pfarr | parr) = array_ptr_alloc (m2) val (pfgc, pfarr | parr) = $DQ.deque_update_capacity (pfgc, pfarr | q, m2, parr) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [queue_update_capacity] (* ****** ****** *) (* end of [linqueue_arr.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/parworkshop.dats0000664000175000017500000004460112223166162021247 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 ** *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload LQ = "libats/SATS/linqueue_arr.sats" staload _(*anon*) = "libats/DATS/linqueue_arr.dats" staload _(*anon*) = "libats/ngc/DATS/deque_arr.dats" // implements [queue] // end of [staload] (* ****** ****** *) staload PT = "libc/SATS/pthread.sats" stadef pthread_t = $PT.pthread_t stadef mutex = $PT.mutex_vt and cond = $PT.cond_vt (* ****** ****** *) staload "libats/SATS/parworkshop.sats" (* ****** ****** *) %{^ ats_ptr_type atslib_parworkshop_workshop_make_tsz ( ats_size_type qsz, ats_fun_ptr_type fwork, ats_size_type tsz ) { atslib_parworkshop_WORKSHOP *p ; // p = ATS_MALLOC (sizeof(atslib_parworkshop_WORKSHOP)) ; pthread_mutex_init (&p->WSmut, (pthread_mutexattr_t*)0) ; // atslib_linqueue_arr_queue_initialize_tsz (&p->WQ, qsz, tsz) ; // pthread_cond_init (&p->WQemp, (pthread_condattr_t*)0) ; pthread_cond_init (&p->WQful, (pthread_condattr_t*)0) ; p->nworker = 0 ; pthread_cond_init (&p->WSisz, (pthread_condattr_t*)0) ; p->npaused = 0 ; pthread_cond_init (&p->WSpaused, (pthread_condattr_t*)0) ; pthread_cond_init (&p->WSequ1, (pthread_condattr_t*)0) ; p->nblocked = 0 ; pthread_cond_init (&p->WSequ2, (pthread_condattr_t*)0) ; p->fwork = fwork ; p->refcount = 0 ; // return (p) ; // } // end of [atslib_parworkshop_workshop_make_tsz] %} // end of [%{^] (* ****** ****** *) %{^ ats_void_type atslib_parworkshop_workshop_free_lin (ats_ptr_type p0, ats_int_type lin) { // atslib_parworkshop_WORKSHOP *p = p0 ; atslib_linqueue_arr_QUEUE *p_WQ = &(p->WQ) ; // pthread_mutex_lock (&p->WSmut); // while (1) { if (p->nworker != 0) { pthread_cond_wait (&p->WSisz, &p->WSmut) ; } else { break ; } // end of [if] } // end of [while] // // [p->WSmut] is held at this point if (lin && p_WQ->nitm != 0) { fprintf (stderr , "exit(ATS): [atslib_parworkshop_workshop_free_lin]: work queue is not empty\n" ) ; exit (1) ; } // end of [if] // atslib_linqueue_arr_queue_uninitialize (p_WQ) ; // pthread_mutex_destroy (&p->WSmut) ; pthread_cond_destroy (&p->WQemp) ; pthread_cond_destroy (&p->WQful) ; pthread_cond_destroy (&p->WSisz) ; pthread_cond_destroy (&p->WSpaused) ; pthread_cond_destroy (&p->WSequ1) ; pthread_cond_destroy (&p->WSequ2) ; // ATS_FREE(p) ; // return ; } // end of [atslib_parworkshop_workshop_free_lin] ats_void_type atslib_parworkshop_workshop_free (ats_ptr_type p0) { atslib_parworkshop_workshop_free_lin (p0, 0) ; return ; } // end of [atslib_parworkshop_workshop_free] ats_void_type atslib_parworkshop_workshop_free_vt_exn (ats_ptr_type p0) { atslib_parworkshop_workshop_free_lin (p0, 1) ; return ; } // end of [atslib_parworkshop_workshop_free] %} // end of [%{^] (* ****** ****** *) implement{a} workshop_make (qsz, f) = workshop_make_tsz (qsz, f, sizeof) // end of [workshop_make] (* ****** ****** *) extern fun workshop_get_fwork {a:viewt@ype} {l:addr} ( ws: !WORKSHOPptr (a, l) ) :<> ( !WORKSHOPptr (a, l), &a >> a? ) - int // HX: a function is returned! = "mac#atslib_parworkshop_workshop_get_fwork" // end of [workshop_get_fwork] (* ****** ****** *) extern fun workshop_nworker_inc {a:viewt@ype} {l:addr} ( ws: !WORKSHOPptr (a, l) ) :<> void = "mac#atslib_parworkshop_workshop_nworker_inc" // end of [workshop_nworker_inc] (* ****** ****** *) viewtypedef WORKSHOP (a:viewt@ype) = $extype_struct "atslib_parworkshop_WORKSHOP" of { // // WSmut = $PT.mutex_vt // WQ = $LQ.QUEUE0 (a) , WQemp = $PT.cond_vt , WQful = $PT.cond_vt , nworker = int // number of workers affiliated with the workshop , WSisz = $PT.cond_vt // nworker = 0 , npaused = int // number of workers paused , WSpaused = $PT.cond_vt , WSequ1 = $PT.cond_vt // npaused = nworker , nblocked = int // number of workers blocked , WSequ2 = $PT.cond_vt // nblocked = nworker , fwork = {l:addr} (!WORKSHOPptr (a, l), &a >> a?) - int , refcount = int } // end of [WORKSHOP] (* ****** ****** *) extern fun workshop_acquire {a:viewt@ype} {l:addr} ( ws: !WORKSHOPptr (a, l) ) :<> ( WORKSHOP (a) @ l | ptr l ) = "mac#atslib_parworkshop_workshop_acquire" extern fun workshop_release {a:viewt@ype} {l:addr} ( pf: WORKSHOP (a) @ l | p_ws: ptr l ) :<> void = "mac#atslib_parworkshop_workshop_release" // end of [workshop_release] (* ****** ****** *) extern fun workshop_get_WSmut {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_mut:addr] ( mutex (WORKSHOP a @ l) @ l_mut , minus (ptr l, mutex (WORKSHOP a @ l) @ l_mut) | ptr l_mut ) = "mac#atslib_parworkshop_workshop_get_WSmut" extern fun workshop_get_WQemp {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_emp:addr] ( cond @ l_emp , minus (ptr l, cond @ l_emp) | ptr l_emp ) = "mac#atslib_parworkshop_workshop_get_WQemp" extern fun workshop_get_WQful {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_ful:addr] ( cond @ l_ful , minus (ptr l, cond @ l_ful) | ptr l_ful ) = "mac#atslib_parworkshop_workshop_get_WQful" (* ****** ****** *) extern fun workshop_get_WSisz {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_isz:addr] ( cond @ l_isz , minus (ptr l, cond @ l_isz) | ptr l_isz ) = "mac#atslib_parworkshop_workshop_get_WSisz" extern fun workshop_get_WSpaused {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_pau:addr] ( cond @ l_pau , minus (ptr l, cond @ l_pau) | ptr l_pau ) = "mac#atslib_parworkshop_workshop_get_WSpaused" extern fun workshop_get_WSequ1 {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_equ:addr] ( cond @ l_equ , minus (ptr l, cond @ l_equ) | ptr l_equ ) = "mac#atslib_parworkshop_workshop_get_WSequ1" extern fun workshop_get_WSequ2 {a:viewt@ype} {l:addr} ( pf: !WORKSHOP (a) @ l | p: ptr l ) :<> [l_equ:addr] ( cond @ l_equ , minus (ptr l, cond @ l_equ) | ptr l_equ ) = "mac#atslib_parworkshop_workshop_get_WSequ2" (* ****** ****** *) implement workshop_get_nworker (ws) = nworker where { val (pf_ws | p_ws) = workshop_acquire (ws) val nworker = p_ws->nworker val () = workshop_release (pf_ws | p_ws) } // end of [workshop_get_nworker] implement workshop_get_npaused (ws) = npaused where { val (pf_ws | p_ws) = workshop_acquire (ws) val npaused = p_ws->npaused val () = workshop_release (pf_ws | p_ws) } // end of [workshop_get_npaused] implement workshop_get_nblocked (ws) = nblocked where { val (pf_ws | p_ws) = workshop_acquire (ws) val nblocked = p_ws->nblocked val () = workshop_release (pf_ws | p_ws) } // end of [workshop_get_nblocked] (* ****** ****** *) extern fun workshop_nworker_inc {a:viewt@ype} {l:addr} (ws: !WORKSHOPptr (a, l)):<> void // end of [workshop_nworker_inc] implement workshop_nworker_inc (ws) = () where { val (pf_ws | p_ws) = workshop_acquire (ws) val () = p_ws->nworker := p_ws->nworker + 1 val () = workshop_release (pf_ws | p_ws) } // end of [workshop_nworker_inc] (* ****** ****** *) extern fun workshop_ref {a:viewt@ype} {l:addr} (ws: !WORKSHOPptr (a, l)): WORKSHOPptr (a, l) // end of [workshop_ref] implement workshop_ref {a} {l} (ws) = ws where { val (pf_ws | p_ws) = workshop_acquire (ws) val () = p_ws->refcount := p_ws->refcount + 1 val () = workshop_release (pf_ws | p_ws) val ws = __cast (ws) where { extern castfn __cast (ws: !WORKSHOPptr (a, l)):<> WORKSHOPptr (a, l) } // end of [val] } // end of [workshop_ref] (* ****** ****** *) extern fun workshop_unref {a:viewt@ype} {l:addr} (ws: WORKSHOPptr (a, l)): void // end of [workshop_unref] implement workshop_unref {a} {l} (ws) = () where { val (pf_ws | p_ws) = workshop_acquire (ws) val () = p_ws->refcount := p_ws->refcount - 1 val () = workshop_release (pf_ws | p_ws) val _ptr = __cast (ws) where { extern castfn __cast (ws: WORKSHOPptr (a, l)):<> ptr l } // end of [val] } // end of [workshop_unref] (* ****** ****** *) // // HX: // return status > 0 : continue // return status = 0 : quit // nworker decreases by 1 // return status = ~1 : pause // it can be resumed later // implement{a} workshop_add_worker {l} (ws) = err where { viewtypedef env = WORKSHOPptr (a, l) fun worker (ws: env): void = let var wk = workshop_remove_work (ws) val fwork = workshop_get_fwork (ws) val status = fwork (ws, wk) in case+ 0 of | _ when status > 0 => worker (ws) | _ when (status = 0) => let // status = 0 val (pf_ws | p_ws) = workshop_acquire (ws) val nworker1 = p_ws->nworker - 1 val () = p_ws->nworker := nworker1 val () = if (nworker1 = 0) then let val _err = $PT.pthread_cond_broadcast (p_ws->WSisz) in (*none*) end // end of [val] val () = if (nworker1 = p_ws->npaused) then let val _err = $PT.pthread_cond_broadcast (p_ws->WSequ1) in (*none*) end // end of [val] val () = if (nworker1 = p_ws->nblocked) then let val _err = $PT.pthread_cond_broadcast (p_ws->WSequ2) in (*none*) end // end of [val] val () = workshop_release (pf_ws | p_ws) val () = workshop_unref (ws) in // the pthread exits normally end // end of [_] | _ => let // for handling uncommon requests viewdef V_ws = WORKSHOP a @ l val (pf_ws | p_ws) = workshop_acquire (ws) val npaused1 = p_ws->npaused + 1 val () = p_ws->npaused := npaused1 val nworker = p_ws->nworker val () = if (npaused1 = nworker) then let val _err = $PT.pthread_cond_broadcast (p_ws->WSequ1) in (*none*) end // end of [val] val [l_mut:addr] (pf_mut, fpf_mut | p_mut) = workshop_get_WSmut {a} {l} (pf_ws | p_ws) val [l_pau:addr] (pf_pau, fpf_pau | p_pau) = workshop_get_WSpaused {a} {l} (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_pau, !p_mut) val p1_ws = p_ws prval () = minus_addback (fpf_mut, pf_mut | p1_ws) prval () = minus_addback (fpf_pau, pf_pau | p1_ws) val npaused = p_ws->npaused val () = p_ws->npaused := npaused - 1 val () = workshop_release (pf_ws | p_ws) in worker (ws) end // end of [status < 0] end // end of [val] val ws_new = workshop_ref (ws) var tid: pthread_t // uninitialized val err = $PT.pthread_create_detached {env} (worker, ws_new, tid) val () = if err > 0 then let // no new worker is added prval () = opt_unsome {env} (ws_new); val () = workshop_unref (ws_new) in // (*nothing*) end else let // a new worker is added successully val () = workshop_nworker_inc (ws) prval () = opt_unnone {env} (ws_new) prval () = cleanup_top {env} (ws_new) in // (*nothing*) end // end of [val] } // end of [workshop_add_worker] (* ****** ****** *) implement{a} workshop_add_nworker {l} {n} (ws, n) = loop (ws, n, 0, 0(*err*)) where { fun loop {i:nat | i <= n} .. ( ws: !WORKSHOPptr (a, l), n: int n, i: int i, err0: int ) : int = if i < n then let val err = workshop_add_worker (ws) in loop (ws, n, i+1, err0 + err) end else err0 // end of [if] // end of [loop] } // end of [workshop_add_nworker] (* ****** ****** *) implement{a} workshop_insert_work {l} (ws, wk) = let (* val () = begin print "workshop_insert_work: start"; print_newline () end // end of [val] *) val (pf_ws | p_ws) = workshop_acquire (ws) viewdef V_ws = WORKSHOP a @ l fun loop ( pf_ws: V_ws | p_ws: ptr l, wk: a ) : void = let val p1_ws = p_ws val isful = $LQ.queue_is_full {a} (p_ws->WQ) in if isful then let val [l_mut:addr] (pf_mut, fpf_mut | p_mut) = workshop_get_WSmut {a} {l} (pf_ws | p_ws) val [l_ful:addr] (pf_ful, fpf_ful | p_ful) = workshop_get_WQful {a} {l} (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_ful, !p_mut) prval () = minus_addback (fpf_mut, pf_mut | p1_ws) prval () = minus_addback (fpf_ful, pf_ful | p1_ws) in loop (pf_ws | p_ws, wk) end else let val isemp = $LQ.queue_is_empty {a} (p_ws->WQ) // end of [val] val () = $LQ.queue_insert (p_ws->WQ, wk) val () = if isemp then let // val () = p_ws->nblocked := 0 // val [l_emp:addr] (pf_emp, fpf_emp | p_emp) = workshop_get_WQemp {a} {l} (pf_ws | p_ws) val _err = $PT.pthread_cond_broadcast (!p_emp) prval () = minus_addback (fpf_emp, pf_emp | p_ws) in // nothing end // end of [val] val () = workshop_release (pf_ws | p_ws) in // nothing end // end of [if] end (* end of [loop] *) in loop (pf_ws | p_ws, wk) end // end of [workshop_insert_work] (* ****** ****** *) implement{a} workshop_remove_work {l} (ws) = let val (pf_ws | p_ws) = workshop_acquire (ws) viewdef V_ws = WORKSHOP a @ l fun loop (pf_ws: V_ws | p_ws: ptr l): a = let val p1_ws = p_ws val isemp = $LQ.queue_is_empty {a} (p_ws->WQ) in if isemp then let // val nblock1 = p_ws->nblocked + 1 val () = p_ws->nblocked := nblock1 val () = if (nblock1 = p_ws->nworker) then let val _err = $PT.pthread_cond_broadcast (p_ws->WSequ2) in (*none*) end // end of [val] // val [l_mut:addr] ( pf_mut, fpf_mut | p_mut ) = workshop_get_WSmut {a} {l} (pf_ws | p_ws) val [l_emp:addr] ( pf_emp, fpf_emp | p_emp ) = workshop_get_WQemp {a} {l} (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_emp, !p_mut) prval () = minus_addback (fpf_mut, pf_mut | p1_ws) prval () = minus_addback (fpf_emp, pf_emp | p1_ws) in loop (pf_ws | p_ws) end else let val isful = $LQ.queue_is_full {a} (p_ws->WQ) // end of [val] val wk = $LQ.queue_remove (p_ws->WQ) val () = if isful then let val [l_ful:addr] (pf_ful, fpf_ful | p_ful) = workshop_get_WQful {a} {l} (pf_ws | p_ws) val _err = $PT.pthread_cond_broadcast (!p_ful) prval () = minus_addback (fpf_ful, pf_ful | p_ws) in // nothing end // end of [val] val () = workshop_release (pf_ws | p_ws) in wk (* return value *) end // end of [if] end (* end of [loop] *) in loop (pf_ws | p_ws) end // end of [workshop_remove_work] (* ****** ****** *) implement workshop_wait_quit_all {a} {l} (ws) = () where { viewdef V_ws = WORKSHOP a @ l val (pf_ws | p_ws) = workshop_acquire (ws) fun loop ( pf_ws: !V_ws | p_ws: ptr l ) : void = let val nworker = p_ws->nworker in if nworker > 0 then let val (pf_mut, fpf_mut | p_mut) = workshop_get_WSmut (pf_ws | p_ws) val (pf_isz, fpf_isz | p_isz) = workshop_get_WSisz (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_isz, !p_mut) prval () = minus_addback (fpf_mut, pf_mut | p_ws) prval () = minus_addback (fpf_isz, pf_isz | p_ws) in loop (pf_ws | p_ws) end else () // end of [if] end // end of [loop] val () = loop (pf_ws | p_ws) val () = workshop_release (pf_ws | p_ws) } // end of [workshop_wait_quit_all] implement workshop_wait_paused_all {a} {l} (ws) = () where { viewdef V_ws = WORKSHOP a @ l val (pf_ws | p_ws) = workshop_acquire (ws) fun loop ( pf_ws: !V_ws | p_ws: ptr l ) : void = let val nworker = p_ws->nworker val npaused = p_ws->npaused in if nworker > npaused then let val (pf_mut, fpf_mut | p_mut) = workshop_get_WSmut (pf_ws | p_ws) val (pf_equ, fpf_equ | p_equ) = workshop_get_WSequ1 (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_equ, !p_mut) prval () = minus_addback (fpf_mut, pf_mut | p_ws) prval () = minus_addback (fpf_equ, pf_equ | p_ws) in loop (pf_ws | p_ws) end else () // end of [if] end // end of [loop] val () = loop (pf_ws | p_ws) val () = workshop_release (pf_ws | p_ws) } // end of [workshop_wait_paused_all] implement workshop_resume_paused_all {a} {l} (ws) = () where { viewdef V_ws = WORKSHOP a @ l val (pf_ws | p_ws) = workshop_acquire (ws) val _err = $PT.pthread_cond_broadcast (p_ws->WSpaused) val () = workshop_release (pf_ws | p_ws) } // end of [workshop_wait_paused_all] (* ****** ****** *) implement workshop_wait_blocked_all {a} {l} (ws) = () where { viewdef V_ws = WORKSHOP a @ l val (pf_ws | p_ws) = workshop_acquire (ws) fun loop ( pf_ws: !V_ws | p_ws: ptr l ) : void = let val nworker = p_ws->nworker val nblocked = p_ws->nblocked in if nworker > nblocked then let val (pf_mut, fpf_mut | p_mut) = workshop_get_WSmut (pf_ws | p_ws) val (pf_equ, fpf_equ | p_equ) = workshop_get_WSequ2 (pf_ws | p_ws) val _err = $PT.pthread_cond_wait {V_ws} (pf_ws | !p_equ, !p_mut) prval () = minus_addback (fpf_mut, pf_mut | p_ws) prval () = minus_addback (fpf_equ, pf_equ | p_ws) in loop (pf_ws | p_ws) end else () // end of [if] end // end of [loop] val () = loop (pf_ws | p_ws) val () = workshop_release (pf_ws | p_ws) } // end of [workshop_wait_blocked_all] (* ****** ****** *) (* end of [parworkshop.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linqueue_lst.dats0000664000175000017500000002607312223166162021404 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A list-based queue implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: July, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload "libats/SATS/linqueue_lst.sats" (* ****** ****** *) viewtypedef wptr(a:viewt@ype) = (a, ptr) // with [ptr] dataview slseg_v ( a:viewt@ype+, int, addr, addr ) = | {n:nat} {la,lb,lz:addr} slseg_v_cons (a, n+1, la, lz) of ( free_gc_v (wptr(a)?, la), (a, ptr lb) @ la, slseg_v (a, n, lb, lz) ) // end of [slseg_v_cons] | {la:addr} slseg_v_nil (a, 0, la, la) // end of [slseg_v] viewdef slist_v (a: viewt@ype, n:int, l:addr) = slseg_v (a, n, l, null) // end of [slist_v] (* ****** ****** *) extern prfun slseg_v_extend {a:viewt@ype} {n:nat} {la,ly,lz:addr} ( pf_sl: slseg_v (a, n, la, ly) , pf_gc: free_gc_v (wptr(a)?, ly) , pf_at: (a, ptr lz) @ ly ) : slseg_v (a, n+1, la, lz) // end of [slseg_v_extend] implement slseg_v_extend {a} (pf_sl, pf_gc, pf_at) = let prfun extend {n:nat} {la,ly,lz:addr} .. ( pf_sl: slseg_v (a, n, la, ly) , pf_gc: free_gc_v (wptr(a)?, ly) , pf_at: (a, ptr lz) @ ly ) : slseg_v (a, n+1, la, lz) = case+ pf_sl of | slseg_v_cons (pf1_gc, pf1_at, pf1_sl) => begin slseg_v_cons {a} (pf1_gc, pf1_at, slseg_v_extend (pf1_sl, pf_gc, pf_at)) end // end of [slseg_v_cons] | slseg_v_nil () => slseg_v_cons {a} (pf_gc, pf_at, slseg_v_nil ()) // end of [extend] in extend (pf_sl, pf_gc, pf_at) end // end of [slseg_v_extend] (* ****** ****** *) extern fun{a:viewt@ype} slseg_length {n:nat} {la,lz:addr} ( pf_sl: !slseg_v (a, n, la, lz) | p1: ptr la, p2: ptr lz ) :<> size_t (n) // end of [slseg_length] implement{a} slseg_length {n} {la,lz} (pf_sl | p1, p2) = let fun loop {la,lz:addr} {n,k:nat} .. ( pf_sl: !slseg_v (a, n, la, lz) | p1: ptr la, p2: ptr lz, k: size_t k ) :<> size_t (n+k) = if p1 <> p2 then let prval slseg_v_cons (pf_gc, pf_at, pf1_sl) = pf_sl val res = loop (pf1_sl | p1->1, p2, k+1) prval () = pf_sl := slseg_v_cons {a} (pf_gc, pf_at, pf1_sl) in res end else let prval () = __assert () where { extern prfun __assert (): [n <= 0] void } // end of [prval] in k end // end of [if] in loop (pf_sl | p1, p2, 0) end // end of [slseg_length] (* ****** ****** *) absview slseg1_v ( a:viewt@ype+, n:int, la:addr, lz:addr ) // end of [slseg1_v] (* ****** ****** *) extern prfun slseg1_v_decode0 {a:viewt@ype} {n:nat} {l2:addr} (pf: slseg1_v (a, n, null, l2)):<> [n == 0] void // end of [slseg1_v_decode0] extern prfun slseg1_v_encode0 {a:viewt@ype} {l2:addr} (): slseg1_v (a, 0, null, l2) // end of [slseg1_v_encode0] (* ****** ****** *) extern prfun slseg1_v_decode1 {a:viewt@ype} {n:int} {l1,l2:addr | l1 > null} (pf: slseg1_v (a, n, l1, l2)) :<> [n > 0] ( slseg_v (a, n-1, l1, l2) , free_gc_v (wptr(a)?, l2) , (a, ptr?) @ l2 ) // end of [slseg1_v_decode1] extern prfun slseg1_v_encode1 {a:viewt@ype} {n:int} {l1,l2:addr} ( pf_sl: slseg_v (a, n, l1, l2) , pf_gc: free_gc_v (wptr(a)?, l2) , pf_at: (a, ptr?) @ l2 ) :<> slseg1_v (a, n+1, l1, l2) // end of [slseg1_v_encode1] (* ****** ****** *) viewtypedef QUEUE_vt ( a:viewt@ype , n:int , l1: addr , l2: addr ) = $extype_struct "atslib_linqueue_lst_QUEUE" of { pf= slseg1_v (a, n, l1, l2), ptr1= ptr (l1), ptr2= ptr (l2) } // end of [QUEUE_vt] viewtypedef QUEUE0_vt (a:viewt@ype) = QUEUE_vt (a, 0, null, null)? (* ****** ****** *) assume QUEUE ( a:viewt@ype, n:int ) = [l1,l2:addr] QUEUE_vt (a, n, l1, l2) // end of [QUEUE] (* ****** ****** *) implement{a} queue_size {n} (q) = let val p1 = q.ptr1; prval () = ptr_is_gtez (p1) in if (p1 > null) then let prval (pf_sl, pf_gc, pf_at) = slseg1_v_decode1 {a} (q.pf) val n1 = slseg_length (pf_sl | p1, q.ptr2) // n1 = n-1 prval () = q.pf := slseg1_v_encode1 {a} (pf_sl, pf_gc, pf_at) in n1 + 1 end else let stavar l2:addr; prval p2 = q.ptr2 : ptr l2 prval () = slseg1_v_decode0 {a} {n} (q.pf) prval () = q.pf := slseg1_v_encode0 {a} {l2} () in size1_of_int1 (0) end // end of [if] end // end of [queue_size] (* ****** ****** *) implement queue_is_empty {a} {n} (q) = let val p1 = q.ptr1 in if p1 > null then let prval () = __assert () where { extern prfun __assert (): [n > 0] void } in false end else let prval () = __assert () where { extern prfun __assert (): [n <= 0] void } in true end // end of [if] end // end of [queue_is_empty] implement queue_isnot_empty (q) = ~queue_is_empty (q) (* ****** ****** *) implement queue_initialize {a} (q) = () where { prval () = __assert (q) where { extern prfun __assert (q: &QUEUE0 a >> QUEUE0_vt a):<> void } // end of [val] prval () = q.pf := slseg1_v_encode0 {a} {null} () val () = q.ptr1 := null val () = q.ptr2 := null } // end of [queue_initialize] (* ****** ****** *) local extern castfn list_vt_of_slist {a:viewt@ype} {n:nat} {la:addr} (pf: slist_v (a, n, la) | p: ptr la):<> list_vt (a, n) // end of [list_vt_of_slist] in // in of [local] implement{a} queue_uninitialize (q) = let val p1 = q.ptr1; prval () = ptr_is_gtez (p1) extern prfun __assert (q: &QUEUE0_vt a >> QUEUE0 a):<> void in if p1 > null then let prval (pf_sl, pf_gc, pf_at) = slseg1_v_decode1 (q.pf) val p2 = q.ptr2 prval () = __assert (q) val () = p2->1 := null // HX-2011-08-13: bugfix: prval -> val!!! prval pf_sl_new = slseg_v_extend {a} (pf_sl, pf_gc, pf_at) in list_vt_of_slist (pf_sl_new | p1) end else let prval () = slseg1_v_decode0 (q.pf) prval () = __assert (q) in list_vt_nil () end (* end of [if] *) end // end of [queue_uninitialize] end // end of [local] (* ****** ****** *) implement{a} queue_insert (q, x) = let viewtypedef VT = wptr(a) and VT0 = @(a, ptr?) val (pf_gc_new, pf_at_new | p_new) = ptr_alloc () val () = p_new->0 := x val p1 = q.ptr1; prval () = ptr_is_gtez (p1) in if p1 > null then let prval (pf_sl, pf_gc, pf_at) = slseg1_v_decode1 {a} (q.pf) val p2 = q.ptr2 val () = p2->1 := p_new prval pf_sl_new = slseg_v_extend {a} (pf_sl, pf_gc, pf_at) prval () = q.pf := slseg1_v_encode1 (pf_sl_new, pf_gc_new, pf_at_new) val () = q.ptr2 := p_new in // nothing end else let prval () = slseg1_v_decode0 {a} (q.pf) prval () = q.pf := slseg1_v_encode1 {a} (slseg_v_nil (), pf_gc_new, pf_at_new) val () = q.ptr1 := p_new val () = q.ptr2 := p_new in // nothing end (* end of [if] *) end // end of [queue_insert] (* ****** ****** *) implement{a} queue_remove {n} (q) = let viewtypedef VT = wptr(a) stavar l1:addr; val p1 = q.ptr1 : ptr l1 stavar l2:addr; val p2 = q.ptr2 : ptr l2 prval () = __assert () where { extern prfun __assert (): [l1 > null] void // HX: since n>0 holds } // end of [prval] prval (pf_sl, pf_gc, pf_at) = slseg1_v_decode1 (q.pf) in if (p1 <> p2) then let prval slseg_v_cons (pf1_gc, pf1_at, pf1_sl) = pf_sl prval () = q.pf := slseg1_v_encode1 {a} (pf1_sl, pf_gc, pf_at) val () = q.ptr1 := p1->1 val x = p1->0; val () = ptr_free {VT?} (pf1_gc, pf1_at | p1) in x end else let prval () = __assert () where { extern prfun __assert (): [n <= 1] void } // end of [prval] prval slseg_v_nil () = pf_sl prval () = q.pf := slseg1_v_encode0 {a} {null} () val () = q.ptr1 := null and () = q.ptr2 := null val x = p2->0; val () = ptr_free {VT?} (pf_gc, pf_at | p2) in x end // end of [if] end // end of [queue_remove] (* ****** ****** *) implement{a} queue_foreach_funenv {v} {vt} {n} (pf | q, f, env) = let val p1 = q.ptr1 in if p1 > null then let // val p2 = q.ptr2 prval ( pf_sl, pf_gc, pf_at ) = slseg1_v_decode1 {a} (q.pf) // end of [prval] // val () = loop ( pf, pf_sl | p1, p2, f, env ) where { fun loop {n:nat} {l1,l2:addr} .. ( pf: !v, pf_sl: !slseg_v (a, n, l1, l2) | p1: ptr l1, p2: ptr l2, f: (!v | &a, !vt) - void, env: !vt ) :<> void = if (p1 <> p2) then let prval slseg_v_cons (pf1_gc, pf1_at, pf1_sl) = pf_sl val () = f (pf | p1->0, env) val p1_nxt = p1->1 val () = loop (pf, pf1_sl | p1_nxt, p2, f, env) // HX: tail-call prval () = pf_sl := slseg_v_cons {a} (pf1_gc, pf1_at, pf1_sl) in // nothing end // end of [if] } // end of [val] // val () = f (pf | p2->0, env) prval () = q.pf := slseg1_v_encode1 {a} (pf_sl, pf_gc, pf_at) // in // nothing end (* end of [if] *) end // end of [queue_foreach_funenv] (* ****** ****** *) implement{a} queue_foreach_fun {n} (q, f) = let // val f = coerce (f) where { extern castfn coerce (f: (&a) - void):<> (!unit_v | &a, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = queue_foreach_funenv {unit_v} {ptr} (pfu | q, f, null) prval unit_v () = pfu // in // empty end // end of [queue_foreach_fun] (* ****** ****** *) implement{a} queue_foreach_vclo {v} {n} (pf | q, f) = let stavar l_f: addr val p_f: ptr l_f = &f typedef clo_t = (!v | &a) - void typedef vt = ptr l_f viewdef v1 = (v, clo_t @ l_f) fn app (pf1: !v1 | x: &a, p_f: !vt):<> void = let prval pf11 = pf1.1 val () = !p_f (pf1.0 | x) prval () = pf1.1 := pf11 in // nothing end // end of [app] prval pf1 = (pf, view@ f) val () = queue_foreach_funenv {v1} {vt} (pf1 | q, app, p_f) prval () = pf := pf1.0 prval () = view@ f := pf1.1 in // nothing end // end of [queue_foreach_vclo] (* ****** ****** *) (* end of [linqueue_lst.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/fmatrix.dats0000664000175000017500000002444012223166162020341 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** Fortran matrices: column-major representation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) ** ** Time: Summer, 2009 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no need for dynamic loading (* ****** ****** *) staload "libats/SATS/genarrays.sats" staload _(*anonymous*) = "libats/DATS/genarrays.dats" (* ****** ****** *) staload "libats/SATS/fmatrix.sats" (* ****** ****** *) implement{a} fmatrix_ptr_alloc (m, n) = let val (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) val (pfgc, pfarr | p_arr) = array_ptr_alloc_tsz {a} (mn, sizeof) prval pf_fmat = fmatrix_v_of_array_v (pf_mn, pfarr) in (pfgc, pf_mn, pf_fmat | p_arr) end // end of [fmatrix_ptr_alloc] (* ****** ****** *) implement fmatrix_ptr_free {a} (pfgc, pf_mn, pf_fmat | p_fmat) = let prval (pf2_mn, pfarr) = array_v_of_fmatrix_v (pf_fmat) prval () = mul_isfun (pf2_mn, pf_mn) val () = array_ptr_free {a?} (pfgc, pfarr | p_fmat) in // nothing end // end of [fmatrix_ptr_free] (* ****** ****** *) implement{a} fmatrix_ptr_allocfree (m, n) = let val (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) val [l:addr] ( pfgc, pfarr | p_arr ) = array_ptr_alloc_tsz {a} (mn, sizeof) prval pf_fmat = fmatrix_v_of_array_v (pf_mn, pfarr) in #[l | ( pf_fmat | p_arr , lam (pf_fmat | p_arr) = let prval (pf2_mn, pfarr) = array_v_of_fmatrix_v (pf_fmat) prval () = mul_isfun (pf2_mn, pf_mn) in array_ptr_free {a?} (pfgc, pfarr | p_arr) end ) ] end // end of [fmatrix_ptr_allocfree] (* ****** ****** *) implement{a} fmatrix_ptr_initialize_elt (base, m, n, x) = () where { prval pf_mat = view@ base prval (pf_mn1, pfarr) = array_v_of_fmatrix_v (pf_mat) val (pf_mn2 | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn2) prval () = mul_isfun (pf_mn1, pf_mn2) var x: a = x val () = array_ptr_initialize_elt_tsz {a} (base, mn, x, sizeof) prval () = view@ base := fmatrix_v_of_array_v (pf_mn1, pfarr) } // end of [fmatrix_ptr_initialize] (* ****** ****** *) // // HX: initialization is done column by colmun // implement{a} // worth it??? fmatrix_ptr_initialize_vclo {v} {m,n} (pf | base, m, n, f) = () where { prval pf_mat = view@ base prval (pf1_mn, pfarr) = array_v_of_fmatrix_v (pf_mat) val [mn:int] (pf2_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf2_mn) prval () = mul_isfun (pf1_mn, pf2_mn) // typedef clo_t = (!v | &(a?) >> a, sizeLt m, sizeLt n) - void // fun loop_one {mi:nat | mi <= m} {l:addr} .. ( pfarr: !array_v (a?, mi, l) >> array_v (a, mi, l) , pf: !v | p: ptr l, f: &clo_t, mi: size_t mi, j: sizeLt n ) : void = if mi > 0 then let prval (pf1_elt, pf2_arr) = array_v_uncons {a?} (pfarr) val () = f (pf | !p, m - mi, j) val () = loop_one (pf2_arr, pf | p+sizeof, f, mi - 1, j) prval () = pfarr := array_v_cons {a} (pf1_elt, pf2_arr) in // nothing end else let prval () = array_v_unnil {a?} (pfarr) prval () = pfarr := array_v_nil {a} () in // nothing end // end of [loop_one] // fun loop_all {nj:nat | nj <= n} {p:int} {l:addr} .. ( pf_mul: MUL (nj, m, p) , pfarr: !array_v (a?, p, l) >> array_v (a, p, l) , pf: !v | p: ptr l , f: &clo_t , nj: size_t nj ) : void = if nj > 0 then let prval () = mul_nat_nat_nat (pf_mul) prval pf1_mul = mul_add_const {~1} (pf_mul) prval () = mul_nat_nat_nat (pf1_mul) val (pfmul, pf1_arr, pf2_arr | p1) = array_ptr_split_tsz {a?} (pfarr | p, m, sizeof) val () = loop_one (pf1_arr, pf | p, f, m, n-nj) val () = loop_all (pf1_mul, pf2_arr, pf | p1, f, nj-1) prval () = pfarr := array_v_unsplit {a} (pfmul, pf1_arr, pf2_arr) // end of [prval] in // nothing end else let prval MULbas () = pf_mul prval () = array_v_unnil {a?} (pfarr) prval () = pfarr := array_v_nil {a} () in // nothing end // end of [loop_all] // prval pf_nm = mul_commute (pf1_mn) val () = loop_all (pf_nm, pfarr, pf | &base, f, n) // prval () = view@ base := fmatrix_v_of_array_v (pf1_mn, pfarr) } // end of [fmatrix_ptr_initialize_vclo] (* ****** ****** *) local // // HX: implemented in [libats/CATS/fmatrix.cats] // extern fun fmatrix_ptr_takeout_tsz {a:viewt@ype} {m,n:int} {i,j:nat | i < m; j < n} {l0:addr} ( pf_mat: fmatrix_v (a, m, n, l0) | base: ptr l0, m: size_t m, i: size_t i, j: size_t j, tsz: sizeof_t a ) :<> [l:addr] ( a @ l , a @ l - fmatrix_v (a, m, n, l0) | ptr l ) = "atslib_fmatrix_ptr_takeout_tsz" // end of [fmatrix_ptr_takeout_tsz] in // in of [local] implement{a} fmatrix_ptr_takeout (pf_mat | base, m, i, j) = begin fmatrix_ptr_takeout_tsz {a} (pf_mat | base, m, i, j, sizeof) end // end of [fmatrix_ptr_takeout] implement{a} fmatrix_ptr_get_elt_at (base, m, i, j) = x where { prval pf_mat = view@ base val (pf_elt, fpf_mat | p_elt) = fmatrix_ptr_takeout_tsz {a} (pf_mat | &base, m, i, j, sizeof) // end of [val] val x = !p_elt prval () = view@ base := fpf_mat (pf_elt) } // end of [fmatrix_ptr_get_elt_at] implement{a} fmatrix_ptr_set_elt_at (base, m, i, j, x) = () where { prval pf_mat = view@ base val (pf_elt, fpf_mat | p_elt) = fmatrix_ptr_takeout_tsz {a} (pf_mat | &base, m, i, j, sizeof) // end of [val] val () = !p_elt := x prval () = view@ base := fpf_mat (pf_elt) } // end of [fmatrix_ptr_set_elt_at] end // end of [local] (* ****** ****** *) implement{a} fmatrix_ptr_copy {m,n} (A, B, m, n) = let val [mn:int] (pf_mn | mn) = mul2_size1_size1 (m, n) prval () = mul_nat_nat_nat (pf_mn) prval (pf2_mn, pfA_arr) = array_v_of_fmatrix_v {a} {m,n} (view@ A) prval (pf3_mn, pfB_arr) = array_v_of_fmatrix_v {a?} {m,n} (view@ B) prval () = mul_isfun (pf_mn, pf2_mn) prval () = mul_isfun (pf_mn, pf3_mn) stavar lA: addr and lB: addr prval pfA_arr = pfA_arr: array_v (a, mn, lA) prval pfB_arr = pfB_arr: array_v (a?, mn, lB) val () = array_ptr_copy_tsz {a} {mn} (A, B, mn, sizeof) prval () = view@ A := fmatrix_v_of_array_v {a} {m,n} {mn} (pf2_mn, pfA_arr) prval () = view@ B := fmatrix_v_of_array_v {a} {m,n} {mn} (pf3_mn, pfB_arr) in // nothing end // end of [fmatrix_ptr_copy] (* ****** ****** *) // // HX: loop proceeds column by column // implement fmatrix_ptr_foreach_funenv_tsz {a} {v} {vt} {ord} {m,n} (pf | M, f, ord, m, n, tsz, env) = if m > 0 then let prval (pf_mat, fpf) = GEMAT_v_of_fmatrix_v {a} (view@ M) val () = GEMAT_ptr_foreach_funenv_tsz (pf | ORDERcol, M, f, ord, m, n, m, tsz, env) prval () = view@ M := fpf (pf_mat) in // nothing end (* end of [fmatrix_ptr_foreach_funenv_tsz] *) (* ****** ****** *) implement{a} fmatrix_ptr_foreach_fun (M, f, ord, m, n) = let val f = coerce (f) where { extern castfn coerce (f: (&a) -<> void) :<> (!unit_v | &a, !ptr) -<> void } // end of [where] prval pfu = unit_v () val () = fmatrix_ptr_foreach_funenv_tsz {a} {unit_v} {ptr} (pfu | M, f, ord, m, n, sizeof, null) prval unit_v () = pfu in // nothing end // end of [fmatrix_ptr_foreach_fun] (* ****** ****** *) implement{a} fmatrix_ptr_foreach_vclo {v} (pf_v | M, f, ord, m, n) = let stavar l_f: addr val p_f: ptr l_f = &f typedef clo_t = (!v | &a) - void viewdef V = @(v, clo_t @ l_f) fn app (pf: !V | x: &a, p_f: !ptr l_f):<> void = let prval (pf1, pf2) = pf in !p_f (pf1 | x); pf := @(pf1, pf2) end // end of [app] prval pf = (pf_v, view@ f) val () = fmatrix_ptr_foreach_funenv_tsz {a} {V} {ptr l_f} (pf | M, app, ord, m, n, sizeof, p_f) prval (pf1, pf2) = pf prval () = (pf_v := pf1; view@ f := pf2) in // empty end // end of [fmatrix_ptr_foreach_vclo] (* ****** ****** *) // // HX: loop proceeds column by column // implement fmatrix_ptr_iforeach_funenv_tsz {a} {v} {vt} {ord} {m,n} (pf | M, f, ord, m, n, tsz, env) = if m > 0 then let prval (pf_mat, fpf) = GEMAT_v_of_fmatrix_v {a} (view@ M) val () = GEMAT_ptr_iforeach_funenv_tsz (pf | ORDERcol, M, f, ord, m, n, m, tsz, env) prval () = view@ M := fpf (pf_mat) in // nothing end (* end of [fmatrix_ptr_iforeach_funenv_tsz] *) (* ****** ****** *) implement{a} fmatrix_ptr_iforeach_fun {ord} {m,n} (M, f, ord, m, n) = if m > 0 then let prval (pf_mat, fpf) = GEMAT_v_of_fmatrix_v {a} (view@ M) val () = GEMAT_ptr_iforeach_fun (ORDERcol, M, f, ord, m, n, m) prval () = view@ M := fpf (pf_mat) in // nothing end (* end of [fmatrix_ptr_iforeach_fun] *) (* ****** ****** *) implement{a} fmatrix_ptr_iforeach_vclo {v} {ord} {m,n} (pf | M, f, ord, m, n) = if m > 0 then let prval (pf_mat, fpf) = GEMAT_v_of_fmatrix_v {a} (view@ M) val () = GEMAT_ptr_iforeach_vclo (pf | ORDERcol, M, f, ord, m, n, m) prval () = view@ M := fpf (pf_mat) in // nothing end (* end of [fmatrix_ptr_iforeach_vclo] *) (* ****** ****** *) (* end of [fmatrix.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linstack_arr.dats0000664000175000017500000000713612223166162021346 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A array-based stack implementation ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: March, 2010 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no static loading at run-time (* ****** ****** *) staload DQ = "libats/ngc/SATS/deque_arr.sats" (* ****** ****** *) staload "libats/SATS/linstack_arr.sats" (* ****** ****** *) assume STACK ( a:viewt@ype, m:int, n:int ) = $DQ.DEQUE (a, m, n) (* ****** ****** *) implement stack_cap (s) = $DQ.deque_cap (s) implement stack_size (s) = $DQ.deque_size (s) implement stack_is_empty (s) = $DQ.deque_is_empty (s) implement stack_isnot_empty (s) = $DQ.deque_isnot_empty (s) implement stack_is_full (s) = $DQ.deque_is_full (s) implement stack_isnot_full (s) = $DQ.deque_isnot_full (s) (* ****** ****** *) implement{a} stack_initialize {m} (s, m) = let val (pfgc, pfarr | parr) = array_ptr_alloc (m) in $DQ.deque_initialize {m} (pfgc, pfarr | s, m, parr) end // end of [stack_initialize] (* ****** ****** *) implement stack_uninitialize {a} {m,n} (s) = () where { val (pfgc, pfarr | parr) = $DQ.deque_uninitialize {a} (s) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [stack_uninitialize] implement stack_uninitialize_vt {a} {m} (s) = () where { val (pfgc, pfarr | parr) = $DQ.deque_uninitialize_vt {a} (s) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [stack_uninitialize_vt] (* ****** ****** *) implement{a} stack_insert (s, x) = $DQ.deque_insert_end (s, x) // end of [stack_insert] implement{a} stack_remove (s) = $DQ.deque_remove_end (s) (* ****** ****** *) implement{a} stack_clear (s, n2) = $DQ.deque_clear_end (s, n2) // end of [stack_clear] implement stack_clear_all (s) = $DQ.deque_clear_all (s) (* ****** ****** *) implement{a} stack_update_capacity (s, m2) = () where { val (pfgc, pfarr | parr) = array_ptr_alloc (m2) val (pfgc, pfarr | parr) = $DQ.deque_update_capacity (pfgc, pfarr | s, m2, parr) val () = array_ptr_free {a?} (pfgc, pfarr | parr) } // end of [stack_update_capacity] (* ****** ****** *) (* end of [linstack_arr.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/linbitvec.dats0000664000175000017500000001564012223166162020650 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libats/SATS/linbitvec.sats" (* ****** ****** *) implement bitvec_isnot_nil (vec, n) = ~bitvec_is_nil (vec, n) implement bitvec_isnot_all (vec, n) = ~bitvec_is_all (vec, n) (* ****** ****** *) implement bitvec_notequal (vec1, vec2, n) = ~bitvec_equal (vec1, vec2, n) (* ****** ****** *) %{^ // // declared in [string.h] // #ifndef memset extern void *memset (void *buf, int chr, size_t n) ; #endif // ats_ptr_type atslib_linbitvec_bitvec_make (ats_size_type nbit) { uintptr_t *p_vec ; size_t nwrd ; nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; p_vec = ATS_CALLOC (nwrd, NBYTE_PER_WORD) ; // initialized to zero return p_vec ; } // end of [atslib_linbitvec_bitvec_make] // ats_ptr_type // HX: same as [atslib_linbitvec_bitvec_make] for now atslib_linbitvec_bitvec_make_nil (ats_size_type nbit) { uintptr_t *p_vec ; size_t nwrd ; nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; p_vec = ATS_CALLOC (nwrd, NBYTE_PER_WORD) ; // initialized to zero return p_vec ; } // end of [atslib_linbitvec_bitvec_make_nil] // ats_ptr_type atslib_linbitvec_bitvec_make_all (ats_size_type nbit) { uintptr_t *p_vec, zc; size_t nwrd ; int next ; nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; next = (nwrd << NBIT_PER_WORD_LOG) - nbit ; // extra bits p_vec = ATS_CALLOC (nwrd, NBYTE_PER_WORD) ; // initialized to zero memset (p_vec, 0xFF, nwrd * NBYTE_PER_WORD) ; /* ** extra bits, which are in the front, must be set to zero!!! */ if (nwrd > 0) { zc = ~0; p_vec[nwrd-1] &= (zc >> next) ; } return p_vec ; } // end of [atslib_linbitvec_bitvec_make_all] // ats_void_type atslib_linbitvec_bitvec_free (ats_ptr_type p_vec) { ATS_FREE (p_vec) ; return ; } // end of [atslib_linbitvec_bitvec_free] // %} // end of [%{^] (* ****** ****** *) %{^ // ats_bool_type atslib_linbitvec_bitvec_is_nil ( ats_ptr_type p0, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p = p0 ; if (!nwrd) return ats_true_bool ; if (*p != 0) return ats_false_bool ; while (--nwrd > 0) { if (*++p != 0) return ats_false_bool ; } return ats_true_bool ; } // end of [atslib_linbitvec_bitvec_is_nil] // ats_bool_type atslib_linbitvec_bitvec_is_all ( ats_ptr_type p0, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; int next = (nwrd << NBIT_PER_WORD_LOG) - nbit ; // extra bits uintptr_t *p = p0, zc = ~0 ; while (nwrd > 1) { if (*p != zc) return ats_false_bool ; --nwrd ; ++p ; } ; /* ** extra bits, which are in the front, must be zero!!! */ if (nwrd) { if (*p != (zc >> next)) return ats_false_bool ; } ; return ats_true_bool ; } // end of [atslib_linbitvec_bitvec_is_all] // %} // end of [%{^] (* ****** ****** *) %{^ // ats_bool_type atslib_linbitvec_bitvec_equal ( ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ats_true_bool ; if (*p1 != *p2) return ats_false_bool ; while (--nwrd > 0) { if (*++p1 != *++p2) return ats_false_bool ; } ; return ats_true_bool ; } // end of [atslib_linbitvec_bitvec_copy] // %} // end of [%{^] (* ****** ****** *) %{^ // ats_void_type atslib_linbitvec_bitvec_copy ( ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ; *p1 = *p2 ; while (--nwrd > 0) { *(++p1) = *(++p2) ; } return ; } // end of [atslib_linbitvec_bitvec_copy] // %} // end of [%{^] (* ****** ****** *) %{^ // ats_void_type atslib_linbitvec_bitvec_neg ( ats_ptr_type p0, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; int next = (nwrd << NBIT_PER_WORD_LOG) - nbit ; // extra bits uintptr_t *p = p0, zc = ~0 ; while (nwrd > 1) { *p = ~(*p) ; --nwrd ; ++p ; } /* ** extra bits, which are in the front, must be set to zero!!! */ if (nwrd > 0) { *p = ~(*p) ; *p &= (zc >> next) ; } return ; } // end of [atslib_linbitvec_bitvec_neg] // ats_void_type atslib_linbitvec_bitvec_or ( ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ; *p1 |= *p2 ; while (--nwrd > 0) { *(++p1) |= *(++p2) ; } return ; } // end of [atslib_linbitvec_bitvec_or] // ats_void_type atslib_linbitvec_bitvec_and ( ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ; *p1 &= *p2 ; while (--nwrd > 0) { *(++p1) &= *(++p2) ; } return ; } // end of [atslib_linbitvec_bitvec_and] // ats_void_type atslib_linbitvec_bitvec_xor ( // symmetric difference ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ; *p1 ^= *p2 ; while (--nwrd > 0) { *(++p1) ^= *(++p2) ; } return ; } // end of [atslib_linbitvec_bitvec_xor] // ats_void_type atslib_linbitvec_bitvec_diff ( // difference ats_ptr_type p10, ats_ptr_type p20, ats_size_type nbit ) { int nwrd = (nbit + NBIT_PER_WORD - 1) >> NBIT_PER_WORD_LOG ; uintptr_t *p1 = p10, *p2 = p20 ; if (!nwrd) return ; *p1 &= ~(*p2) ; while (--nwrd > 0) { *(++p1) &= ~(*(++p2)) ; } return ; } // end of [atslib_linbitvec_bitvec_diff] // %} // end of [%{^] (* ****** ****** *) (* end of [linbitvec.dats] *) ats-lang-anairiats-0.2.11/libats/DATS/funset_avltree.dats0000664000175000017500000005032112223166162021712 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* ** ** A functional set implementation based on AVL trees ** ** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu) ** Time: May, 2011 // based on a version done in October, 2008 ** *) (* ****** ****** *) // // License: LGPL 3.0 (available at http://www.gnu.org/licenses/lgpl.txt) // (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading at run-time (* ****** ****** *) staload "libats/SATS/funset_avltree.sats" (* ****** ****** *) // // a specialized version can be implemented on the spot // implement{a} compare_elt_elt (x1, x2, cmp) = cmp (x1, x2) // (* ****** ****** *) // // HX-2010-03-24: this seems to work best! // #define HTDF 1 // max height difference #define HTDF1 %(HTDF+1) #define HTDF_1 %(HTDF-1) (* ****** ****** *) datatype avltree ( a:t@ype+, int(*height*) ) = | {hl,hr:nat | hl <= hr+HTDF; hr <= hl+HTDF} B (a, 1+max(hl,hr)) of (int (1+max(hl,hr)), a, avltree (a, hl), avltree (a, hr)) | E (a, 0) // end of [datatype avltree] typedef avltree_inc (a:t@ype, h:int) = [h1:nat | h <= h1; h1 <= h+1] avltree (a, h1) // end of [avltree_inc] typedef avltree_dec (a:t@ype, h:int) = [h1:nat | h1 <= h; h <= h1+1] avltree (a, h1) // end of [avltree_dec] (* ****** ****** *) assume set_t0ype_type (a:t@ype) = [h:nat] avltree (a, h) (* ****** ****** *) implement{} funset_make_nil () = E () implement{a} funset_make_sing (x) = B (1, x, E, E) implement{a} funset_make_list (xs, cmp) = res where { fun loop {n:nat} .. ( xs: list (a, n), res: &set a ) : void = case+ xs of | list_cons (x, xs) => let val _(*inserted*) = funset_insert (res, x, cmp) in loop (xs, res) end // end of [list_cons] | list_nil () => () var res: set a = funset_make_nil () val () = loop (xs, res) } // end of [funset_make_list] (* ****** ****** *) implement{} funset_is_nil (xs) = case+ xs of B _ => false | E () => true implement{} funset_isnot_nil (xs) = case+ xs of B _ => true | E () => false (* ****** ****** *) implement{a} funset_size (xs) = aux (xs) where { fun aux {h:nat} .. (t: avltree (a, h)):<> size_t = case+ t of | B (_, _, tl, tr) => aux (tl) + 1 + aux (tr) | E () => 0 // end of [aux] } // end of [funset_size] implement{a} funset_height (xs) = aux (xs) where { fun aux {h:nat} .. (t: avltree (a, h)):<> size_t = case+ t of | B (_, _, tl, tr) => (size_of_int1)1 + max_size_size (aux (tl), aux (tr)) | E () => 0 // end of [aux] } // end of [funset_size] (* ****** ****** *) macdef avltree_height (t) = case+ ,(t) of B (h, _, _, _) => h | E _ => 0 // end of [avltree_height] (* ****** ****** *) implement{a} funset_is_member (xs, x0, cmp) = aux (xs) where { fun aux {h:nat} .. (t: avltree (a, h)): bool = case+ t of | B (_, x, tl, tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then aux (tl) else (if sgn > 0 then aux (tr) else true) end | E () => false // end of [aux] } // end of [funset_is_member] implement{a} funset_isnot_member (xs, x0, cmp) = ~funset_is_member (xs, x0, cmp) (* ****** ****** *) (* ** left rotation for restoring height invariant *) fn{a:t@ype} avltree_lrotate {hl,hr:nat | hl+HTDF1 == hr} ( x: a , hl : int hl , tl: avltree (a, hl) , hr : int hr , tr: avltree (a, hr) ) :<> avltree_inc (a, hr) = let val+ B {..} {hrl,hrr} (_(*hr*), xr, trl, trr) = tr val hrl = avltree_height trl : int hrl and hrr = avltree_height trr : int hrr in if hrl <= hrr+HTDF_1 then let val hrl1 = hrl + 1 in B (1+max(hrl1,hrr), xr, B (hrl1, x, tl, trl), trr) end else let // [hrl=hrr+2]: deep rotation val+ B {..} {hrll,hrlr} (_(*hrl*), xrl, trll, trlr) = trl val hrll = avltree_height trll : int hrll val hrlr = avltree_height trlr : int hrlr in B (hr, xrl, B (1+max(hl,hrll), x, tl, trll), B (1+max(hrlr,hrr), xr, trlr, trr)) end // end of [if] end // end of [avltree_lrotate] (* ** right rotation for restoring height invariant *) fn{a:t@ype} avltree_rrotate {hl,hr:nat | hl == hr+HTDF1} ( x: a , hl: int hl , tl: avltree (a, hl) , hr: int hr , tr: avltree (a, hr) ) :<> avltree_inc (a, hl) = let val+ B {..} {hll, hlr} (_(*hl*), xl, tll, tlr) = tl val hll = avltree_height tll : int hll and hlr = avltree_height tlr : int hlr in if hll+HTDF_1 >= hlr then let val hlr1 = hlr + 1 in B (1+max(hll,hlr1), xl, tll, B (hlr1, x, tlr, tr)) end else let val+ B {..} {hlrl,hlrr} (_(*hlr*), xlr, tlrl, tlrr) = tlr val hlrl = avltree_height tlrl : int hlrl val hlrr = avltree_height tlrr : int hlrr in B (hl, xlr, B (1+max(hll,hlrl), xl, tll, tlrl), B (1+max(hlrr,hr), x, tlrr, tr)) end // end of [if] end // end of [avltree_rrotate] (* ****** ****** *) implement{a} funset_insert (xs, x0, cmp) = res where { fun insert {h:nat} .. ( t: avltree (a, h), res: &bool? >> bool ) : avltree_inc (a, h) = begin case+ t of | B {..} {hl,hr} (h, x, tl, tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val [hl:int] tl = insert (tl, res) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then begin B (1+max(hl,hr), x, tl, tr) end else begin // hl = hr+HTDF1 avltree_rrotate (x, hl, tl, hr, tr) end // end of [if] end else if sgn > 0 then let val [hr:int] tr = insert (tr, res) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl, hr), x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (x, hl, tl, hr, tr) end // end of [if] end else let (* [k0] already exists *) val () = res := true in B (h, x0, tl, tr) end // end of [if] end // end of [B] | E () => let (* [x0] is not in [m] *) val () = res := false in B (1, x0, E (), E ()) end // end of [E] end // end of [insert] var res: bool // uninitialized val () = xs := insert (xs, res) } // end of [funset_insert] (* ****** ****** *) fun{a:t@ype} avltree_takeout_min {h:pos} .. ( t: avltree (a, h), x0: &a? >> a ) :<> avltree_dec (a, h) = let val+ B {..} {hl,hr} (_, x, tl, tr) = t in case+ tl of | B _ => let val [hl:int] tl = avltree_takeout_min (tl, x0) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then begin B (1+max(hl,hr), x, tl, tr) end else begin // hl+HTDF1 = hr avltree_lrotate (x, hl, tl, hr, tr) end // end of [if] end // end of [B] | E () => (x0 := x; tr) end // end of [avltree_takeout_min] (* ****** ****** *) implement{a} funset_remove (m, x0, cmp) = b(*removed*) where { fun remove {h:nat} .. ( t: avltree (a, h), b: &bool? >> bool ) : avltree_dec (a, h) = begin case+ t of | B {..} {hl,hr} (h, x, tl, tr) => let val sgn = compare_elt_elt (x0, x, cmp) in case+ 0 of | _ when sgn < 0 => let val [hl:int] tl = remove (tl, b) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hr - hl <= HTDF then B (1+max(hl,hr), x, tl, tr) else // hl+HTDF1 = hr avltree_lrotate (x, hl, tl, hr, tr) // end of [if] end // end of [sgn < 0] | _ when sgn > 0 => let val [hr:int] tr = remove (tr, b) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then B (1+max(hl,hr), x, tl, tr) else // hl=hr+HTDF1 avltree_rrotate (x, hl, tl, hr, tr) // end of [if] end // end of [sgn > 0] | _ (*sgn = 0*) => let val () = b := true in case+ tr of | B _ => let var x_min: a? val [hr:int] tr = avltree_takeout_min (tr, x_min) val hl = avltree_height (tl) : int hl and hr = avltree_height (tr) : int hr in if hl - hr <= HTDF then B (1+max(hl,hr), x_min, tl, tr) else // hl=hr+HTDF1 avltree_rrotate (x_min, hl, tl, hr, tr) // end of [if] end // end of [B] | E _ => tl end // end of [sgn = 0] end // end of [B] | E () => t where { val () = b := false } // end of [E] end // end of [remove] var b: bool // unitialized val () = m := remove (m, b) } // end of [funset_remove] (* ****** ****** *) (* ** left join: height(tl) >= height(tr) *) fun{a:t@ype} avltree_ljoin {hl,hr:nat | hl >= hr} .. ( x: a, tl: avltree (a, hl), tr: avltree (a, hr) ) :<> avltree_inc (a, hl) = let val hl = avltree_height (tl): int hl and hr = avltree_height (tr): int hr in if hl >= hr + HTDF1 then let val+ B {..} {hll, hlr} (_, xl, tll, tlr) = tl val [hlr:int] tlr = avltree_ljoin (x, tlr, tr) val hll = avltree_height (tll): int hll and hlr = avltree_height (tlr): int hlr in if hlr <= hll + HTDF then B (max(hll,hlr)+1, xl, tll, tlr) else // hll+HTDF1 = hlr avltree_lrotate (xl, hll, tll, hlr, tlr) // end of [if] end else begin B (hl+1, x, tl, tr) end // end of [if] end // end of [avltree_ljoin] (* ****** ****** *) (* ** right join: height(tl) <= height(tr) *) fun{a:t@ype} avltree_rjoin {hl,hr:nat | hl <= hr} .


. ( x: a, tl: avltree (a, hl), tr: avltree (a, hr) ) :<> avltree_inc (a, hr) = let val hl = avltree_height (tl): int hl and hr = avltree_height (tr): int hr in if hr >= hl + HTDF1 then let val+ B {..} {hrl,hrr} (_, xr, trl, trr) = tr val [hrl:int] trl = avltree_rjoin (x, tl, trl) val hrl = avltree_height (trl): int hrl and hrr = avltree_height (trr): int hrr in if hrl <= hrr + HTDF then B (max(hrl,hrr)+1, xr, trl, trr) else // hrl = hrr+HTDF1 avltree_rrotate (xr, hrl, trl, hrr, trr) // end of [if] end else begin B (hr+1, x, tl, tr) end // end of [if] end // end of [avltree_rjoin] (* ****** ****** *) fn{a:t@ype} avltree_join {hl,hr:nat} ( x: a, tl: avltree (a, hl), tr: avltree (a, hr) ) :<> [h:int | hl <= h; hr <= h; h <= max(hl,hr)+1] avltree (a, h) = let val hl = avltree_height tl: int hl and hr = avltree_height tr: int hr in if hl >= hr then avltree_ljoin (x, tl, tr) else avltree_rjoin (x, tl, tr) end // end of [avltree_join] (* ****** ****** *) fn{a:t@ype} avltree_concat {hl,hr:nat} ( tl: avltree (a, hl), tr: avltree (a, hr) ) :<> [h:nat | h <= max(hl,hr)+1] avltree (a, h) = case+ (tl, tr) of | (E (), _) => tr | (_, E ()) => tl | (_, _) =>> let var x_min: a // uninitialized val tr = avltree_takeout_min (tr, x_min) in avltree_join (x_min, tl, tr) end // end of [_, _] // end of [avltree_concat] (* ****** ****** *) typedef avltree0 = avltree (void, 0)? fun{a:t@ype} avltree_split_at {h:nat} .. ( t: avltree (a, h), x0: a , tl0: &avltree0 >> avltree (a, hl) , tr0: &avltree0 >> avltree (a, hr) , cmp: cmp a ) :<> #[i:two; hl,hr:nat | hl <= h; hr <= h] int i = case+ t of | B (_(*h*), x, tl, tr) => let val sgn = compare_elt_elt (x0, x, cmp) in if sgn < 0 then let val i = avltree_split_at (tl, x0, tl0, tr0, cmp) in tr0 := avltree_join (x, tr0, tr); i end else if sgn > 0 then let val i = avltree_split_at (tr, x0, tl0, tr0, cmp) in tl0 := avltree_join (x, tl, tl0); i end else begin tl0 := tl; tr0 := tr; 1 // [x] is found in [t] end // end of [if] end // end of [B] | E () => (tl0 := E (); tr0 := E (); 0) // end of [avltree_split_at] (* ****** ****** *) implement{a} funset_choose (xs, x0) = case+ xs of | B (_(*h*), x, _(*tl*), _(*tr*)) => let val () = x0 := x prval () = opt_some {a} (x0) in true end // end of [B] | E () => let prval () = opt_none {a} (x0) in false end // end of [E] // end of [funset_choose] implement{a} funset_takeout (xs, x0) = case+ xs of | B (_(*h*), x, tl, tr) => let val () = x0 := x val () = xs := avltree_concat (tl, tr) prval () = opt_some {a} (x0) in true end // end of [E] | E () => let prval () = opt_none {a} (x0) in false end // end of [E] // end of [funset_takeout] (* ****** ****** *) implement{a} funset_union (t1, t2, cmp) = union (t1, t2) where { fun union {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (E (), _) => t2 | (_, E ()) => t1 | (_, _) =>> let val+ B (_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) val t12l = union (t1l, t2l0) and t12r = union (t1r, t2r0) in avltree_join (x1, t12l, t12r) end // end of [_, _] end // end of [uni] // end of [union] // [union] is a keyword } // end of [funset_union] (* ****** ****** *) implement{a} funset_intersect (t1, t2, cmp) = inter (t1, t2) where { fun inter {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (E (), _) => E () | (_, E ()) => E () | (_, _) =>> let val+ B (_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) val t12l = inter (t1l, t2l0) and t12r = inter (t1r, t2r0) in if i = 0 then avltree_concat (t12l, t12r) else avltree_join (x1, t12l, t12r) // end of [if] end // end of [_, _] end // end of [inter] // end of [inter] } // end of [funset_intersect] (* ****** ****** *) implement{a} funset_diff (t1, t2, cmp) = diff (t1, t2) where { fun diff {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (E (), _) => E () | (_, E ()) => t1 | (_, _) =>> let val+ B (_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) val t12l = diff (t1l, t2l0) and t12r = diff (t1r, t2r0) in if i > 0 then avltree_concat (t12l, t12r) else avltree_join (x1, t12l, t12r) // end of [if] end // end of [_, _] end // end of [diff] // end of [diff] } // end of [funset_diff] (* ****** ****** *) implement{a} funset_symdiff (t1, t2, cmp) = symdiff (t1, t2) where { fun symdiff {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : [h:nat] avltree (a, h) = begin case+ (t1, t2) of | (E (), _) => t2 | (_, E ()) => t1 | (_, _) =>> let val+ B (_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) val t12l = symdiff (t1l, t2l0) and t12r = symdiff (t1r, t2r0) in if i > 0 then avltree_concat (t12l, t12r) else avltree_join (x1, t12l, t12r) end // end of [_, _] end // end of [symdiff] // end of [diff] } // end of [funset_symdiff] (* ****** ****** *) implement{a} funset_is_subset (t1, t2, cmp) = test (t1, t2) where { fun test {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : bool = begin case+ (t1, t2) of | (E (), _) => true | (_, E ()) => false | (_, _) =>> let val+ B(_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) in if i > 0 then (if test (t1l, t2l0) then test (t1r, t2r0) else false) else false end // end of [_, _] end // end of [test] } // end of [funset_is_subset] implement{a} funset_is_supset (t1, t2, cmp) = funset_is_subset (t2, t1, cmp) // end of [funset_is_supset] (* ****** ****** *) implement{a} funset_is_equal (t1, t2, cmp) = test (t1, t2) where { fun test {h1,h2:nat} .

. ( t1: avltree (a, h1), t2: avltree (a, h2) ) : bool = begin case+ (t1, t2) of | (E _, E _) => true | (E _, B _) => false | (B _, E _) => false | (_, _) =>> let val+ B(_(*h1*), x1, t1l, t1r) = t1 var t2l0: avltree0 and t2r0: avltree0 val i = avltree_split_at (t2, x1, t2l0, t2r0, cmp) in if i > 0 then (if test (t1l, t2l0) then test (t1r, t2r0) else false) else false end // end of [_, _] end // end of [test] } // end of [funset_is_equal] (* ****** ****** *) implement{a} funset_foreach_funenv {v} {vt} (pf | xs, f, env) = foreach (pf | xs, env) where { fun foreach {h:nat} .. (pf: !v | t: avltree (a, h), env: !vt): void = case+ t of | B (_(*h*), x, tl, tr) => begin foreach (pf | tl, env); f (pf | x, env); foreach (pf | tr, env) end // end of [B] | E () => () // end of [foreach] } // end of [funset_foreach_funenv] implement{a} funset_foreach_fun (xs, f) = let // val f = coerce (f) where { extern castfn coerce (f: (a) - void):<> (!unit_v | a, !ptr) - void } // end of [val] // prval pfu = unit_v () val () = funset_foreach_funenv {unit_v} {ptr} (pfu | xs, f, null) prval unit_v () = pfu // in // nothing end // end of [funset_foreach_fun] (* ****** ****** *) implement{a} funset_foreach_vclo {v} (pf | m, f) = foreach (pf | m, f) where { fun foreach {h:nat} .. ( pf: !v | t: avltree (a, h), f: &(!v | a) - void ) :<> void = case+ t of | B (_(*h*), x, tl, tr) => begin foreach (pf | tl, f); f (pf | x); foreach (pf | tr, f) end // end of [B] | E () => () // end of [foreach] } // end of [funset_foreach_vclo] implement{a} funset_foreach_cloref (m, f) = let val f = __cast (f) where { extern castfn __cast (f: (a) - void):<> (!unit_v | a) - void } // end of [val] typedef clo_type = (!unit_v | a) - void val (vbox pf_f | p_f) = cloref_get_view_ptr {clo_type} (f) prval pfu = unit_v () val () = $effmask_ref (funset_foreach_vclo {unit_v} (pfu | m, !p_f)) prval unit_v () = pfu in // empty end // end of [funset_foreach_cloref] (* ****** ****** *) implement{a} funset_listize (xs) = let viewtypedef res_vt = List_vt (a) fun listize {h:nat} .. ( t: avltree (a, h), res: res_vt ) :<> res_vt = case+ t of | B (_(*h*), x, tl, tr) => let val res = listize (tr, res) val res = list_vt_cons {a} (x, res) val res = listize (tl, res) in res end // end of [B] | E () => res // end of [listize] in listize (xs, list_vt_nil ()) end // end of [funset_listize] (* ****** ****** *) (* end of [funset_avltree.dats] *) ats-lang-anairiats-0.2.11/Makefile_bootstrap0000664000175000017500000001706612223166157017550 0ustar hwxihwxi######################################################################### ## ## ## Applied Type System ## ## ## ## Hongwei Xi ## ## ## ######################################################################### ## ## ATS/Anairiats - Unleashing the Potential of Types! ## ## Copyright (C) 2002-2008 Hongwei Xi, Boston University ## ## All rights reserved ## ## ATS is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free ## Software Foundation; either version 2.1, or (at your option) any later ## version. ## ## ATS is distributed in the hope that it will be useful, but WITHOUT ANY ## WARRANTY; without even the implied warranty of MERCHANTABILITY or ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ## for more details. ## ## You should have received a copy of the GNU General Public License ## along with ATS; see the file COPYING. If not, please write to the ## Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ## 02110-1301, USA. ## ## ###### ###### ## ## Original Version ## Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) ## Time: December 2007 ## Major Revision ## Author: Yuri D'Elia (wavexx AT thregr DOT org) ## Time: June 2010 ## ###### ###### ## # # The bootstrapping procedure: # # 1. Use [gcc] to compile the C code in [bootstrap0-anairiats] to build # the ATS compiler [atsopt] # # Alternatively, use [ocamlopt] to compile the Objective Caml code in # [bootstrap0-geizella] to build the ATS compiler [atsopt] # # 2. Use [atsopt] to compile the ATS code in [src] into C code and store # it in [bootstrap1] # # 3. Use [gcc] to compile the C code in [bootstrap1] to build the ATS # compiler [atsopt] # # 4. Use [atsopt] to compile the ATS code in [utils/scripts] to build the # batch compilation command [atscc] # # 5. Use [atscc] to build libats, GC and atslex. # ###### .SUFFIXES: all:: ###### include ../config.mk ###### #ATSHOMEQ = "$(ATSHOME)" ATSRUNTIME := $(ATSHOMEQ)/ccomp/runtime BOOTSTRAP1=1 ifdef BOOTSTRAP1 ATSCCFLAGS=-I$(ATSHOMEQ) -I$(ATSRUNTIME) -O2 -g endif LIBGMP= ifdef HAVE_LIBGMP LIBGMP=-lgmp endif LIBOBJS := $(LIBGMP) ###### SOURCES := \ ats_array.sats ats_array.dats \ ats_charlst.sats ats_charlst.dats \ ats_comarg.sats ats_comarg.dats \ ats_counter.sats ats_counter.dats \ ats_debug.sats ats_debug.dats \ ats_effect.sats ats_effect.dats \ ats_error.sats ats_error.dats \ ats_filename.sats ats_filename.dats \ ats_fixity.sats ats_fixity_prec.dats ats_fixity_fxty.dats \ ats_global.sats ats_global.dats \ ats_hashtbl.sats ats_hashtbl.dats \ ats_intinf.sats ats_intinf.dats \ ats_keyword.sats ats_keyword.dats \ ats_label.sats ats_label.dats \ ats_location.sats ats_location.dats \ ats_namespace.sats ats_namespace.dats \ ats_posmark.sats ats_posmark.dats \ ats_stamp.sats ats_stamp.dats \ ats_symbol.sats ats_symbol.dats \ ats_symenv.sats ats_symenv.dats \ ats_symtbl.sats ats_symtbl.dats \ ats_list.sats ats_list.dats \ ats_map_lin.sats ats_map_lin.dats \ ats_reference.sats ats_reference.dats \ ats_set_fun.sats ats_set_fun.dats \ ats_parser.sats ats_parser.dats \ ats_syntax.sats ats_syntax.dats \ ats_syntax_depgen.dats \ ats_syntax_taggen.dats \ ats_syntax_posmark.dats \ ats_staexp1.sats ats_staexp1.dats \ ats_staexp1_print.dats \ ats_dynexp1.sats ats_dynexp1.dats \ ats_dynexp1_print.dats \ ats_dynexp1_syndef.dats \ ats_dynexp1_syndef.sats \ ats_trans1_env.sats ats_trans1_env.dats \ ats_e1xp_eval.sats ats_e1xp_eval.dats \ ats_trans1.sats ats_trans1_sta.dats ats_trans1_dyn.dats \ ats_staexp2.sats ats_staexp2.dats \ ats_staexp2_print.dats \ ats_staexp2_scst.dats \ ats_staexp2_svVar.dats \ ats_staexp2_dcon.dats \ ats_staexp2_util1.dats ats_staexp2_util2.dats \ ats_staexp2_pprint.sats ats_staexp2_pprint.dats \ ats_dynexp2.sats ats_dynexp2.dats \ ats_dynexp2_dcst.dats \ ats_dynexp2_dmac.dats \ ats_dynexp2_dvar.dats \ ats_dynexp2_print.dats \ ats_dynexp2_util.dats \ ats_trans2_env.sats ats_trans2_env.dats \ ats_stadyncst2.sats ats_stadyncst2.dats \ ats_trans2.sats \ ats_trans2_sta.dats \ ats_trans2_dyn1.dats ats_trans2_dyn2.dats \ ats_macro2.sats ats_macro2.dats \ ats_patcst2.sats ats_patcst2.dats \ ats_string_parse.sats ats_string_parse.dats \ ats_printf_c.lats \ ats_dynexp3.sats ats_dynexp3.dats \ ats_dynexp3_print.dats \ ats_trans3_env.sats \ ats_trans3_env.dats \ ats_trans3_env_eff.dats \ ats_trans3_env_loop.dats \ ats_trans3_env_met.dats \ ats_trans3_env_scst.dats \ ats_trans3_env_state.dats \ ats_trans3_env_print.dats \ ats_staexp2_solve.sats ats_staexp2_solve.dats \ ats_trans3.sats ats_trans3_pat.dats \ ats_trans3_assgn.dats \ ats_trans3_deref.dats \ ats_trans3_view.dats \ ats_trans3_util.dats \ ats_trans3_exp_up.dats \ ats_trans3_exp_dn.dats \ ats_trans3_loop.dats ats_trans3_dec.dats \ ats_constraint.sats ats_constraint.dats \ ats_constraint_print.dats \ ats_solver_fm.sats ats_solver_fm.dats \ ats_hiexp.sats ats_hiexp.dats \ ats_hiexp_print.dats ats_hiexp_util.dats \ ats_trans4.sats ats_trans4.dats \ ats_ccomp.sats ats_ccomp.dats \ ats_ccomp_env.sats ats_ccomp_env.dats \ ats_ccomp_print.dats \ ats_ccomp_util.dats \ ats_ccomp_trans.dats \ ats_ccomp_trans_clau.dats \ ats_ccomp_trans_tailcal.dats \ ats_ccomp_trans_temp.dats \ ats_ccomp_emit.dats \ ats_ccomp_main.dats \ OBJECTS := $(SOURCES) OBJECTS := $(patsubst %.sats, %_sats.o, $(OBJECTS)) OBJECTS := $(patsubst %.lats, %_lats.dats, $(OBJECTS)) OBJECTS := $(patsubst %.dats, %_dats.o, $(OBJECTS)) ATSOPT_GC_OBJECTS := \ ../ccomp/runtime/GCATS/gc.o PRELUDE_DATS_OBJECTS := \ prelude_dats_basics_dats.o \ prelude_dats_bool_dats.o \ prelude_dats_char_dats.o \ prelude_dats_integer_dats.o \ prelude_dats_array_dats.o \ prelude_dats_string_dats.o \ prelude_dats_printf_dats.o \ prelude_dats_filebas_dats.o \ LIBC_SATS_OBJECTS := \ libc_sats_gmp_sats.o \ libc_sats_time_sats.o \ LIBC_DATS_OBJECTS := \ libc_dats_unistd_dats.o \ LIBATS_LEX_OBJECTS := \ libats_lex_lexing_sats.o \ libats_lex_lexing_dats.o \ libats_lex_tables_dats.o \ OBJECTS += \ ats_lexer_lats_dats.o \ ats_lexer_sats.o \ ats_grammar_yats.o \ $(PRELUDE_DATS_OBJECTS) \ $(LIBC_SATS_OBJECTS) $(LIBC_DATS_OBJECTS) \ $(LIBATS_LEX_OBJECTS) \ ats_main_dats.c \ ../ccomp/runtime/ats_prelude.c \ ../ccomp/runtime/ats_bootstrap.c \ ###### COMPILE = $(CC) $(ATSCCFLAGS) -o $@ #COMPILE = $(CC) $(CPPFLAGS) $(CFLAGS) $(ATSCCFLAGS) -o $@ CLINK = $(CC) $(ATSCCFLAGS) $(LDFLAGS) -o $@ #CLINK = $(CC) $(CPPFLAGS) $(CFLAGS) $(ATSCCFLAGS) $(LDFLAGS) -o $@ ###### # # HX-2011-01-26: please select the proper one # # if [yacc] or [byacc] is used to generate [ats_grammar_yats.c] # ATSYACCFLAGS=$(ATSCCFLAGS) # # select it if [bison] is used to generate [ats_grammar_yats.c] ATSYACCFLAGS=-D_ATS_YYVALISLOCAL $(ATSCCFLAGS) # ats_grammar_yats.o: ats_grammar_yats.c; $(CC) $(ATSYACCFLAGS) -o $@ -c $< ###### %.o: %.c $(COMPILE) -c $< ###### all:: atsopt atsopt: $(OBJECTS) $(CLINK) $(OBJECTS) $(LIBOBJS) atsopt_gc: $(OBJECTS) $(ATSOPT_GC_OBJECTS) $(CLINK) -D_ATS_GCATS $(OBJECTS) $(ATSOPT_GC_OBJECTS) $(LIBOBJS) ###### clean:: rm -f *.o cleanall:: clean rm -f atsopt ###### ## end of [Makefile] ## ###### ats-lang-anairiats-0.2.11/libc/0000700000175000017500000000000012223166162014672 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/CATS/0000700000175000017500000000000012223166162015424 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/CATS/pthread.cats0000664000175000017500000000730712223166162017752 0ustar hwxihwxi/* ******************************************************************* */ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /* ******************************************************************* */ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ** A linker error is issued if a user does not define _ATS_MULTITHREAD and ** tries to use them anyways */ /* ****** ****** */ #ifndef ATS_LIBC_PTHREAD_CATS #define ATS_LIBC_PTHREAD_CATS /* ****** ****** */ #ifdef _ATS_MULTITHREAD // // #define THREAD_SAFE // HX: what is this? // #include #include #include // #include // /* ****** ****** */ #define atslib_pthread_attr_init pthread_attr_init #define atslib_pthread_attr_destroy pthread_attr_destroy ATSinline() ats_void_type atslib_pthread_attr_init_exn (ats_ref_type p_attr) { if (pthread_attr_init((pthread_attr_t*)p_attr)) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [pthread_attr_init_exn] failed\n") ; } // end of [if] return ; } // end of [atslib_pthread_attr_init_exn] ATSinline() ats_void_type atslib_pthread_attr_destroy_exn (ats_ref_type p_attr) { if (pthread_attr_destroy((pthread_attr_t*)p_attr)) { ats_exit_errmsg (EXIT_FAILURE, "exit(ATS): [pthread_attr_destroy_exn] failed\n") ; } // end of [if] return ; } // end of [atslib_pthread_attr_destroy_exn] /* ****** ****** */ #define atslib_pthread_create pthread_create /* ****** ****** */ #define atslib_pthread_self pthread_self /* ****** ****** */ #define atslib_pthread_join pthread_join /* ****** ****** */ #define atslib_pthread_exit pthread_exit /* ****** ****** */ #define atslib_pthread_cancel pthread_cancel #define atslib_pthread_testcancel pthread_testcancel /* ****** ****** */ #define atslib_pthread_cleanup_pop pthread_cleanup_pop /* ****** ****** */ #define atslib_pthread_spin_destroy pthread_spin_destroy #define atslib_pthread_spin_lock pthread_spin_lock #define atslib_pthread_spin_trylock pthread_spin_trylock #define atslib_pthread_spin_unlock pthread_spin_unlock /* ****** ****** */ #define atslib_pthread_mutex_destroy pthread_mutex_destroy #define atslib_pthread_mutex_lock pthread_mutex_lock #define atslib_pthread_mutex_trylock pthread_mutex_trylock #define atslib_pthread_mutex_unlock pthread_mutex_unlock /* ****** ****** */ #define atslib_pthread_cond_wait pthread_cond_wait #define atslib_pthread_cond_signal pthread_cond_signal #define atslib_pthread_cond_broadcast pthread_cond_broadcast /* ****** ****** */ #endif // end of [_ATS_MULTITHREAD] /* ****** ****** */ #endif // end of [ATS_LIBC_PTHREAD_CATS] /* end of [pthread.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/gmp.cats0000664000175000017500000006577212223166162017120 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_GMP_CATS #define ATS_LIBC_GMP_CATS /* ****** ****** */ #include #include /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ #include "prelude/CATS/basics.cats" /* ****** ****** */ typedef unsigned long int ulint ; /* ****** ****** */ // [mpz_t] is one-element array of [__mpz_struct] typedef __mpz_struct ats_mpz_viewt0ype ; // [mpq_t] is one-element array of [__mpq_struct] typedef __mpq_struct ats_mpq_viewt0ype ; // [mpf_t] is one-element array of [__mpf_struct] typedef __mpf_struct ats_mpf_viewt0ype ; // [mpz_ptr] is defined in [gmp.h] // call-by-reference typedef ats_ref_type ats_mpz_ptr_type ; typedef ats_ref_type ats_mpq_ptr_type ; typedef ats_ref_type ats_mpf_ptr_type ; /* ****** ****** */ // // [gmp_randstate_t] is // one-element array of [__gmp_randstate_struct] // typedef __gmp_randstate_struct ats_gmp_randstate_viewt0ype ; /* ****** ****** */ // // init/clear/realloc // #define atslib_mpz_init mpz_init #define atslib_mpz_init2 mpz_init2 #define atslib_mpz_clear mpz_clear #define atslib_mpz_realloc2 mpz_realloc2 /* ****** ****** */ // // HX: integral number operations // /* ****** ****** */ // // get functions // #define atslib_mpz_get_int mpz_get_si #define atslib_mpz_get_uint mpz_get_ui #define atslib_mpz_get_lint mpz_get_si #define atslib_mpz_get_ulint mpz_get_ui #define atslib_mpz_get_double mpz_get_d ATSinline() ats_ptr_type atslib_mpz_get_str ( ats_int_type base, ats_mpz_ptr_type x ) { return mpz_get_str((char*)0, base, (mpz_ptr)x) ; } // end of [atslib_mpz_get_str] // // set functions // #define atslib_mpz_set_mpz mpz_set #define atslib_mpz_set_int mpz_set_si #define atslib_mpz_set_uint mpz_set_ui #define atslib_mpz_set_lint mpz_set_si #define atslib_mpz_set_ulint mpz_set_ui #define atslib_mpz_set_double mpz_set_d #define atslib_mpz_set_mpq mpz_set_q #define atslib_mpz_set_mpf mpz_set_f #define atslib_mpz_set_str mpz_set_str ATSinline() ats_void_type atslib_mpz_set_str_exn ( ats_mpz_ptr_type x, ats_ptr_type s, ats_int_type base ) { int n ; n = mpz_set_str((mpz_ptr)x, (char*)s, base) ; if (n < 0) { atspre_exit_prerrf(1, "exit(ATS): [mpz_set_str(%s)]: failed\n", s) ; } // end of [if] return ; } // end of [atslib_mpz_set_str_exn] // // init and set functions // #define atslib_mpz_init_set_mpz mpz_init_set #define atslib_mpz_init_set_int mpz_init_set_si #define atslib_mpz_init_set_uint mpz_init_set_ui #define atslib_mpz_init_set_lint mpz_init_set_si #define atslib_mpz_init_set_ulint mpz_init_set_ui #define atslib_mpz_init_set_double mpz_init_set_d ATSinline() ats_void_type atslib_mpz_init_set_mpq (ats_mpz_ptr_type x, ats_mpq_ptr_type y) { mpz_init((mpz_ptr)x) ; mpz_set_q((mpz_ptr)x, (mpq_ptr)y); return ; } // end of [atslib_mpz_init_set_mpq] ATSinline() ats_void_type atslib_mpz_init_set_mpf (ats_mpz_ptr_type x, ats_mpf_ptr_type y) { mpz_init((mpz_ptr)x) ; mpz_set_f((mpz_ptr)x, (mpf_ptr)y); return ; } // end of [atslib_mpz_init_set_mpf] #define atslib_mpz_init_set_str mpz_init_set_str ATSinline() ats_void_type atslib_mpz_init_set_str_exn ( ats_mpz_ptr_type x, ats_ptr_type s, ats_int_type base ) { int err ; err = mpz_init_set_str((mpz_ptr)x, (char*)s, base) ; if (err < 0) { atspre_exit_prerrf(1, "exit(ATS): [mpz_init_set_str(%s)] failed\n", s) ; } // end of [if] return ; } // end of [atslib_mpz_init_set_str_exn] /* ****** ****** */ #define atslib_mpz_swap mpz_swap /* ****** ****** */ ATSinline() ats_bool_type atslib_mpz_odd_p (ats_ref_type x) { return mpz_odd_p((mpz_ptr)x) ? ats_true_bool : ats_false_bool ; } // end of [atslib_mpz_odd_p] ATSinline() ats_bool_type atslib_mpz_even_p (ats_ref_type x) { return mpz_even_p((mpz_ptr)x) ? ats_true_bool : ats_false_bool ; } // end of [atslib_mpz_even_p] #define atslib_mpz_fits_int_p mpz_fits_int_p #define atslib_mpz_fits_uint_p mpz_fits_uint_p #define atslib_mpz_fits_lint_p mpz_fits_long_p #define atslib_mpz_fits_ulint_p mpz_fits_ulong_p #define atslib_mpz_fits_sint_p mpz_fits_sshort_p #define atslib_mpz_fits_usint_p mpz_fits_ushort_p #define atslib_mpz_size mpz_size #define atslib_mpz_sizeinbase mpz_sizeinbase /* ****** ****** */ // // negation // #define atslib_mpz_neg2 mpz_neg ATSinline() ats_void_type atslib_mpz_neg1 (ats_mpz_ptr_type x) { mpz_neg((mpz_ptr)x, (mpz_ptr)x) ; return ; } // end of [atslib_mpz_neg1] // // absolute value // #define atslib_mpz_abs2 mpz_abs ATSinline() ats_void_type atslib_mpz_abs1 (ats_mpz_ptr_type x) { mpz_abs((mpz_ptr)x, (mpz_ptr)x) ; return ; } // end of [atslib_mpz_abs1] /* ****** ****** */ // // addition, subtraction and multiplcation // /* ****** ****** */ // // addition // #define atslib_mpz_add3_mpz mpz_add #define atslib_mpz_add3_int(x, y, z) \ atslib_mpz_add3_lint(x, y, (ats_lint_type)z) #define atslib_mpz_add3_uint mpz_add_ui ATSinline() ats_void_type atslib_mpz_add3_lint (ats_mpz_ptr_type x, ats_mpz_ptr_type y, ats_lint_type z) { if (z >= 0) { mpz_add_ui ((mpz_ptr)x, (mpz_ptr)y, (ulint)z) ; } else { mpz_sub_ui ((mpz_ptr)x, (mpz_ptr)y, (ulint)-z) ; } return ; } // end of [atslib_mpz_add3_lint] #define atslib_mpz_add3_ulint mpz_add_ui // ATSinline() ats_void_type atslib_mpz_add2_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_add ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)y) ; return ; } // end of [atslib_mpz_add2_mpz] ATSinline() ats_void_type atslib_mpz_add2_lint ( ats_mpz_ptr_type x, ats_lint_type y ) { if (y >= 0) { mpz_add_ui ((mpz_ptr)x, (mpz_ptr)x, (ulint)y) ; } else { mpz_sub_ui ((mpz_ptr)x, (mpz_ptr)x, (ulint)-y) ; } // end of [if] return ; } // end of [atslib_mpz_add2_lint] ATSinline() ats_void_type atslib_mpz_add2_ulint ( ats_mpz_ptr_type x, ats_ulint_type y ) { mpz_add_ui ((mpz_ptr)x, (mpz_ptr)x, y) ; return ; } // end of [atslib_mpz_add2_ulint] #define atslib_mpz_add2_int(x, y) atslib_mpz_add2_lint(x, (ats_lint_type)y) #define atslib_mpz_add2_uint(x, y) atslib_mpz_add2_lint(x, (ats_ulint_type)y) // // subtraction // #define atslib_mpz_sub3_mpz mpz_sub #define atslib_mpz_sub3_int(x, y, z) \ atslib_mpz_sub3_lint(x, y, (ats_lint_type)z) #define atslib_mpz_sub3_uint mpz_sub_ui ATSinline() ats_void_type atslib_mpz_sub3_lint ( ats_mpz_ptr_type x, ats_mpz_ptr_type y, ats_lint_type z ) { if (z >= 0) { mpz_sub_ui ((mpz_ptr)x, (mpz_ptr)y, (ulint)z) ; } else { mpz_add_ui ((mpz_ptr)x, (mpz_ptr)y, (ulint)-z) ; } return ; } // end of [atslib_mpz_sub3_lint] #define atslib_mpz_sub3_ulint mpz_sub_ui #define atslib_mpz_ui_sub3 mpz_ui_sub ATSinline() ats_void_type atslib_mpz_sub2_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_sub ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)y) ; return ; } // end of [atslib_mpz_sub2_mpz] ATSinline() ats_void_type atslib_mpz_sub2_lint ( ats_mpz_ptr_type x, ats_lint_type y ) { if (y >= 0) { mpz_sub_ui ((mpz_ptr)x, (mpz_ptr)x, y) ; } else { mpz_add_ui ((mpz_ptr)x, (mpz_ptr)x, -y) ; } return ; } // end of [atslib_mpz_sub2_lint] ATSinline() ats_void_type atslib_mpz_sub2_ulint ( ats_mpz_ptr_type x, ats_ulint_type y ) { mpz_sub_ui ((mpz_ptr)x, (mpz_ptr)x, y) ; return ; } // end of [atslib_mpz_sub2_ulint] #define atslib_mpz_sub2_int(x, y) atslib_mpz_sub2_lint(x, (ats_lint_type)y) #define atslib_mpz_sub2_uint(x, y) atslib_mpz_sub2_ulint(x, (ats_ulint_type)y) // // multiplication // #define atslib_mpz_mul3_mpz mpz_mul #define atslib_mpz_mul3_int mpz_mul_si #define atslib_mpz_mul3_uint mpz_mul_ui #define atslib_mpz_mul3_lint mpz_mul_si #define atslib_mpz_mul3_ulint mpz_mul_ui ATSinline() ats_void_type atslib_mpz_mul2_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_mul ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)y) ; return ; } // end of [atslib_mpz_mul2_mpz] ATSinline() ats_void_type atslib_mpz_mul2_lint ( ats_mpz_ptr_type x, ats_lint_type y ) { mpz_mul_si ((mpz_ptr)x, (mpz_ptr)x, y) ; return ; } // end of [atslib_mpz_mul2_lint] ATSinline() ats_void_type atslib_mpz_mul2_ulint ( ats_mpz_ptr_type x, ats_ulint_type y ) { mpz_mul_ui ((mpz_ptr)x, (mpz_ptr)x, y) ; return ; } // end of [atslib_mpz_mul2_ulint] #define atslib_mpz_mul2_int(x, y) atslib_mpz_mul2_lint (x, (ats_lint_type)y) #define atslib_mpz_mul2_uint(x, y) atslib_mpz_mul2_ulint (x, (ats_ulint_type)y) ATSinline() ats_void_type atslib_mpz_mul1_mpz (ats_mpz_ptr_type x) { mpz_mul ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)x) ; return ; } // end of [atslib_mpz_mul1_mpz] ATSinline() ats_void_type atslib_mpz_mul_2exp ( // x = y * 2^n ats_mpz_ptr_type x, ats_mpz_ptr_type y, ats_ulint_type n ) { mpz_mul_2exp((mpz_ptr)x, (mpz_ptr)y, n) ; return ; } // end of [atslib_mpz_mul_2exp] /* ****** ****** */ // // truncate division // #define atslib_mpz_tdiv4_qr_mpz mpz_tdiv_qr #define atslib_mpz_tdiv4_qr_ulint mpz_tdiv_qr_ui #define atslib_mpz_tdiv3_q_mpz mpz_tdiv_q #define atslib_mpz_tdiv3_q_ulint mpz_tdiv_q_ui ATSinline() ats_void_type atslib_mpz_tdiv2_q_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type d ) { mpz_tdiv_q ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)d) ; return ; } // end of [atslib_mpz_tdiv2_q_mpz] ATSinline() ats_ulint_type atslib_mpz_tdiv2_q_ulint ( ats_mpz_ptr_type x, ats_ulint_type d ) { return mpz_tdiv_q_ui ((mpz_ptr)x, (mpz_ptr)x, d) ; } // end of [atslib_mpz_tdiv2_q_ulint] /* ****** ****** */ // // floor division // #define atslib_mpz_fdiv4_qr_mpz mpz_fdiv_qr #define atslib_mpz_fdiv4_qr_ulint mpz_fdiv_qr_ui #define atslib_mpz_fdiv3_q_mpz mpz_fdiv_q #define atslib_mpz_fdiv3_q_ulint mpz_fdiv_q_ui ATSinline() ats_void_type atslib_mpz_fdiv2_q_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type d ) { mpz_fdiv_q ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)d) ; return ; } // end of [atslib_mpz_fdiv2_q_mpz] ATSinline() ats_ulint_type atslib_mpz_fdiv2_q_ulint ( ats_mpz_ptr_type x, ats_ulint_type d ) { return mpz_fdiv_q_ui ((mpz_ptr)x, (mpz_ptr)x, d) ; } // end of [atslib_mpz_fdiv2_q_ulint] #define atslib_mpz_fdiv3_r_mpz mpz_fdiv_r #define atslib_mpz_fdiv3_r_ulint mpz_fdiv_r_ui ATSinline() ats_void_type atslib_mpz_fdiv2_r_mpz ( ats_mpz_ptr_type x, ats_mpz_ptr_type d ) { mpz_fdiv_r ((mpz_ptr)x, (mpz_ptr)x, (mpz_ptr)d) ; return ; } // end of [atslib_mpz_fdiv2_r_mpz] ATSinline() ats_ulint_type atslib_mpz_fdiv2_r_ulint ( ats_mpz_ptr_type x, ats_ulint_type d ) { return mpz_fdiv_r_ui ((mpz_ptr)x, (mpz_ptr)x, d) ; } // end of [atslib_mpz_fdiv2_r_ulint] /* ****** ****** */ #define atslib_mpz_divisible_p mpz_divisible_p #define atslib_mpz_divisible_ui_p mpz_divisible_ui_p #define atslib_mpz_congruent_p mpz_congruent_p #define atslib_mpz_congruent_ui_p mpz_congruent_ui_p /* ****** ****** */ #define atslib_mpz_mod3_mpz mpz_mod #define atslib_mpz_mod2_mpz(n, d) mpz_mod((mpz_ptr)n, (mpz_ptr)n, (mpz_ptr)d) #define atslib_mpz_mod3_ulint mpz_mod_ui #define atslib_mpz_mod2_ulint(n, d) mpz_mod_ui((mpz_ptr)n, (mpz_ptr)n, d) #define atslib_mpz_divexact3 mpz_divexact #define atslib_mpz_divexact2(n, d) mpz_divexact((mpz_ptr)n, (mpz_ptr)n, (mpz_ptr)d) #define atslib_tdiv3_q_2exp tdiv_q_2exp #define atslib_tdiv3_r_2exp tdiv_r_2exp #define atslib_fdiv3_q_2exp fdiv_q_2exp #define atslib_fdiv3_r_2exp fdiv_r_2exp #define atslib_mpz_divisible_ui_2exp_p mpz_divisible_ui_2exp_p #define atslib_mpz_congruent_ui_2exp_p mpz_congruent_ui_2exp_p /* ****** ****** */ #define atslib_mpz_sqrt2 mpz_sqrt ATSinline() ats_void_type atslib_mpz_sqrt1 (ats_ref_type dst) { mpz_sqrt ((mpz_ptr)dst, (mpz_ptr)dst) ; return ; } // end of [atslib_mpz_sqrt1] #define atslib_mpz_sqrtrem3 mpz_sqrtrem #define atslib_mpz_perfect_square_p mpz_perfect_square_p /* ****** ****** */ #define atslib_mpz_powm4_mpz mpz_powm #define atslib_mpz_powm4_ui mpz_powm_ui /* ****** ****** */ #define atslib_mpz_pow3_ui mpz_pow_ui ATSinline() ats_void_type atslib_mpz_pow2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpz_pow_ui ((mpz_ptr)dst, (mpz_ptr)dst, src2) ; return ; } // end of [atslib_mpz_pow2_ui] /* ****** ****** */ // addmul and submul compibination #define atslib_mpz_addmul3_mpz mpz_addmul #define atslib_mpz_addmul3_uint mpz_addmul_ui #define atslib_mpz_addmul3_ulint mpz_addmul_ui #define atslib_mpz_submul3_mpz mpz_submul #define atslib_mpz_submul3_uint mpz_submul_ui #define atslib_mpz_submul3_ulint mpz_submul_ui /* ****** ****** */ // comparison functions #define atslib_mpz_cmp_mpz mpz_cmp #define atslib_mpz_cmp_lint(x, y) mpz_cmp_si((mpz_ptr)x, y) #define atslib_mpz_cmp_ulint(x, y) mpz_cmp_ui((mpz_ptr)x, y) #define atslib_mpz_cmp_int atslib_mpz_cmp_lint #define atslib_mpz_cmp_uint atslib_mpz_cmp_ulint ATSinline() ats_int_type atslib_mpz_cmp_double ( ats_ref_type x, ats_double_type y ) { return mpz_cmp_d((mpz_ptr)x, y) ; } // end of [atslib_mpz_cmp_double] #define atslib_mpz_cmpabs_mpz mpz_cmpabs #define atslib_mpz_cmpabs_uint mpz_cmpabs_ui #define atslib_mpz_cmpabs_ulint mpz_cmpabs_ui #define atslib_mpz_cmpabs_double mpz_cmpabs_d #define atslib_mpz_sgn mpz_sgn /* ****** ****** */ #define atslib_mpz_gcd3_mpz mpz_gcd #define atslib_mpz_gcd2_mpz(dst, src2) \ mpz_gcd((mpz_ptr)dst, (mpz_ptr)dst, (mpz_ptr)src2) #define atslib_mpz_gcd3_ui mpz_gcd_ui #define atslib_mpz_gcd2_ui(dst, src2) mpz_gcd_ui((mpz_ptr)dst, (mpz_ptr)dst, src2) #define atslib_mpz_gcdext mpz_gcdext #define atslib_mpz_lcm3_mpz mpz_lcm #define atslib_mpz_lcm2_mpz(dst, src2) \ mpz_lcm((mpz_ptr)dst, (mpz_ptr)dst, (mpz_ptr)src2) #define atslib_mpz_lcm3_ui mpz_lcm_ui #define atslib_mpz_lcm2_ui(dst, src2) mpz_lcm_ui((mpz_ptr)dst, (mpz_ptr)dst, src2) #define atslib_mpz_invert3 mpz_invert /* ****** ****** */ // // various number-theoretic functions // ATSinline() ats_void_type atslib_mpz_nextprime1 (ats_ref_type dst) { mpz_nextprime((mpz_ptr)dst, (mpz_ptr)dst); return ; } // end of [atslib_mpz_nextprime1] #define atslib_mpz_nextprime2 mpz_nextprime #define atslib_mpz_jacobi mpz_jacobi #define atslib_mpz_legendre mpz_legendre #define atslib_mpz_kronecker_mpz mpz_kronecker #define atslib_mpz_kronecker_si mpz_kronecker_si #define atslib_mpz_kronecker_ui mpz_kronecker_ui #define atslib_mpz_si_kronecker mpz_si_kronecker #define atslib_mpz_ui_kronecker mpz_ui_kronecker #define atslib_mpz_fac_ui mpz_fac_ui #define atslib_mpz_bin3_ui mpz_bin_ui #define atslib_mpz_bin2_ui(n, k) \ mpz_bin_ui ((mpz_ptr)n, (mpz_ptr)n, (mpz_ptr)k) #define atslib_mpz_bin_uiui mpz_bin_uiui #define atslib_mpz_fib_ui mpz_fib_ui #define atslib_mpz_fib2_ui mpz_fib2_ui #define atslib_mpz_remove3 mpz_remove ATSinline() ats_void_type atslib_mpz_remove2 ( ats_ptr_type dst, ats_ptr_type src2 ) { mpz_remove ((mpz_ptr)dst, (mpz_ptr)dst, (mpz_ptr)src2); return ; } // end of [atslib_mpz_remove2] /* ****** ****** */ // // some MPZ input/output/print functions // #define atslib_mpz_inp_str mpz_inp_str #define atslib_mpz_out_str mpz_out_str extern ats_void_type atslib_mpz_out_str_exn ( ats_ptr_type, ats_int_type, ats_mpf_ptr_type ) ; // end of [extern] ATSinline() ats_void_type atslib_fprint_mpz ( ats_ptr_type file, const ats_mpz_ptr_type x ) { atslib_mpz_out_str_exn (file, 10/*base*/, x) ; return ; } // end of [atslib_fprint_mpz] #define atslib_mpz_inp_raw mpz_inp_raw #define atslib_mpz_out_raw mpz_out_raw /* ****** ****** */ // // // HX: rational number operations // // /* ****** ****** */ #define atslib_mpq_canonicalize mpq_canonicalize #define atslib_mpq_init mpq_init #define atslib_mpq_clear mpq_clear #define atslib_mpq_get_d mpq_get_d ATSinline() ats_ptr_type atslib_mpq_get_str ( ats_int_type base, ats_mpq_ptr_type x ) { return mpq_get_str((char*)0, base, (mpq_ptr)x) ; } // end of [atslib_mpq_get_str] #define atslib_mpq_get_num mpq_get_num #define atslib_mpq_get_den mpq_get_den ATSinline() ats_ptr_type atslib_mpq_numref (ats_ptr_type x) { return mpq_numref ((mpq_ptr)x) ; } // end of [atslib_mpq_numref] ATSinline() ats_ptr_type atslib_mpq_denref (ats_ptr_type x) { return mpq_denref ((mpq_ptr)x) ; } // end of [atslib_mpq_denref] #define atslib_mpq_set_mpq mpq_set #define atslib_mpq_set_mpz mpq_set_z #define atslib_mpq_set_si mpq_set_si #define atslib_mpq_set_ui mpq_set_ui #define atslib_mpq_set_d mpq_set_d #define atslib_mpq_set_mpf mpq_set_f #define atslib_mpq_set_num mpq_set_num #define atslib_mpq_set_den mpq_set_den /* ****** ****** */ #define atslib_mpq_neg2 mpq_neg ATSinline() ats_void_type atslib_mpq_neg1 (ats_mpq_ptr_type x) { mpq_neg((mpq_ptr)x, (mpq_ptr)x) ; return ; } // end of [atslib_mpq_neg1] /* ****** ****** */ #define atslib_mpq_inv2 mpq_inv ATSinline() ats_void_type atslib_mpq_inv1 (ats_mpq_ptr_type x) { mpq_inv((mpq_ptr)x, (mpq_ptr)x) ; return ; } // end of [atslib_mpq_inv1] /* ****** ****** */ #define atslib_mpq_add3_mpq mpq_add ATSinline() ats_void_type atslib_mpq_add2_mpq ( ats_ref_type dst, ats_ref_type src2 ) { mpq_add ((mpq_ptr)dst, (mpq_ptr) dst, (mpq_ptr)src2); return ; } // end of [atslib_mpq_add2_mpq] #define atslib_mpq_sub3_mpq mpq_sub ATSinline() ats_void_type atslib_mpq_sub2_mpq ( ats_ref_type dst, ats_ref_type src2 ) { mpq_sub ((mpq_ptr)dst, (mpq_ptr) dst, (mpq_ptr)src2); return ; } // end of [atslib_mpq_sub2_mpq] #define atslib_mpq_mul3_mpq mpq_mul ATSinline() ats_void_type atslib_mpq_mul2_mpq ( ats_ref_type dst, ats_ref_type src2 ) { mpq_mul ((mpq_ptr)dst, (mpq_ptr) dst, (mpq_ptr)src2); return ; } // end of [atslib_mpq_mul2_mpq] #define atslib_mpq_div3_mpq mpq_div ATSinline() ats_void_type atslib_mpq_div2_mpq ( ats_ref_type dst, ats_ref_type src2 ) { mpq_div ((mpq_ptr)dst, (mpq_ptr) dst, (mpq_ptr)src2); return ; } // end of [atslib_mpq_div2_mpq] /* ****** ****** */ #define atslib_mpq_equal mpq_equal #define atslib_mpq_cmp_mpq mpq_cmp #define atslib_mpq_cmp_ui mpq_cmp_ui #define atslib_mpq_sgn mpq_sgn /* ****** ****** */ // // some MPQ input/output/print functions // #define atslib_mpq_inp_str mpq_inp_str #define atslib_mpq_out_str mpq_out_str extern ats_void_type atslib_mpq_out_str_exn ( ats_ptr_type, ats_int_type, ats_mpf_ptr_type ) ; // end of [extern] ATSinline() ats_void_type atslib_fprint_mpq ( ats_ptr_type file, const ats_mpq_ptr_type x ) { atslib_mpq_out_str_exn (file, 10/*base*/, x) ; return ; } // end of [atslib_fprint_mpq] /* ****** ****** */ // // // HX: floating number operations // // /* ****** ****** */ #define atslib_mpf_get_default_prec mpf_get_default_prec #define atslib_mpf_set_default_prec mpf_set_default_prec /* ****** ****** */ #define atslib_mpf_init mpf_init #define atslib_mpf_init2 mpf_init2 #define atslib_mpf_clear mpf_clear #define atslib_mpf_get_prec mpf_get_prec #define atslib_mpf_set_prec mpf_set_prec #define atslib_mpf_set_prec_raw mpf_set_prec_raw #define atslib_mpf_get_d mpf_get_d #define atslib_mpf_get_d_2exp mpf_get_d_2exp #define atslib_mpf_get_si mpf_get_si #define atslib_mpf_get_ui mpf_get_ui ATSinline() ats_ptr_type atslib_mpf_get_str ( ats_ptr_type exp , ats_int_type base, ats_size_type ndigit , ats_mpf_ptr_type x ) { return mpf_get_str((char*)0, (mp_exp_t*)exp, base, ndigit, (mpf_ptr)x) ; } // end of [atslib_mpf_get_str] /* ****** ****** */ #define atslib_mpf_set_mpf mpf_set #define atslib_mpf_set_si mpf_set_si #define atslib_mpf_set_ui mpf_set_ui #define atslib_mpf_set_mpz mpf_set_z #define atslib_mpf_set_mpq mpf_set_q #define atslib_mpf_set_d mpf_set_d #define atslib_mpf_set_str mpf_set_str ATSinline() ats_void_type atslib_mpf_set_str_exn ( ats_mpf_ptr_type x, ats_ptr_type s, ats_int_type base ) { int n ; n = mpf_set_str((mpf_ptr)x, (char*)s, base) ; if (n < 0) { atspre_exit_prerrf(1, "exit(ATS): [mpf_set_str(%s)]: failed\n", s) ; } // end of [if] return ; } // end of [atslib_mpf_set_str_exn] /* ****** ****** */ #define atslib_mpf_init_set_mpf mpf_init_set #define atslib_mpf_init_set_d mpf_init_set_d #define atslib_mpf_init_set_si mpf_init_set_si #define atslib_mpf_init_set_ui mpf_init_set_ui #define atslib_mpf_init_set_str mpf_init_set_str #define atslib_mpf_swap mpf_swap /* ****** ****** */ #define atslib_mpf_ceil mpf_ceil #define atslib_mpf_floor mpf_floor #define atslib_mpf_trunc mpf_trunc #define atslib_mpf_integer_p mpf_integer_p #define atslib_mpf_int_p mpf_int_p #define atslib_mpf_uint_p mpf_uint_p #define atslib_mpf_lint_p mpf_slong_p #define atslib_mpf_ulint_p mpf_ulong_p #define atslib_mpf_sint_p mpf_sshort_p #define atslib_mpf_usint_p mpf_ushort_p #define atslib_mpf_fits_int_p mpf_fits_int_p #define atslib_mpf_fits_uint_p mpf_fits_uint_p #define atslib_mpf_fits_lint_p mpf_fits_long_p #define atslib_mpf_fits_ulint_p mpf_fits_ulong_p #define atslib_mpf_fits_sint_p mpf_fits_sshort_p #define atslib_mpf_fits_usint_p mpf_fits_ushort_p /* ****** ****** */ #define abslib_mpf_neg2 mpf_neg2 ATSinline() ats_void_type atslib_mpf_neg1 (ats_ref_type x) { mpf_neg ((mpf_ptr)x, (mpf_ptr)x) ; return ; } // end of [atslib_mpf_neg1] #define abslib_mpf_abs2 mpf_abs2 ATSinline() ats_void_type atslib_mpf_abs1 (ats_ref_type x) { mpf_abs ((mpf_ptr) x, (mpf_ptr) x) ; return ; } // end of [atslib_mpf_abs1] /* ****** ****** */ #define atslib_mpf_add3_mpf mpf_add #define atslib_mpf_add3_mpf_ui mpf_add_ui ATSinline() ats_void_type atslib_mpf_add2_mpf ( ats_ref_type dst, ats_ref_type src2 ) { mpf_add ((mpf_ptr)dst, (mpf_ptr) dst, (mpf_ptr)src2); return ; } // end of [atslib_mpf_add2_mpf] ATSinline() ats_void_type atslib_mpf_add2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_add_ui ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_add2_ui] /* ****** ****** */ #define atslib_mpf_sub3_mpf mpf_sub #define atslib_mpf_sub3_ui mpf_sub_ui #define atslib_mpf_ui_sub3 mpf_ui_sub ATSinline() ats_void_type atslib_mpf_sub2_mpf ( ats_ref_type dst, ats_ref_type src2 ) { mpf_sub ((mpf_ptr) dst, (mpf_ptr) dst, (mpf_ptr) src2) ; return ; } // end of [atslib_mpf_sub2_mpf] ATSinline() ats_void_type atslib_mpf_sub2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_sub_ui ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_sub2_ui] ATSinline() ats_void_type atslib_mpf_ui_sub2 ( ats_ref_type dst, ats_ulint_type src1 ) { mpf_ui_sub ((mpf_ptr)dst, src1, (mpf_ptr)dst) ; return ; } // end of [atslib_mpf_ui_sub2] /* ****** ****** */ #define atslib_mpf_mul3_mpf mpf_mul #define atslib_mpf_mul3_ui mpf_mul_ui ATSinline() ats_void_type atslib_mpf_mul2_mpf ( ats_ref_type dst, ats_ref_type src2 ) { mpf_mul ((mpf_ptr)dst, (mpf_ptr)dst, (mpf_ptr)src2) ; return ; } // end of [atslib_mpf_mul2_mpf] ATSinline() ats_void_type atslib_mpf_mul2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_mul_ui ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_mul2_ui] /* ****** ****** */ #define atslib_mpf_div3_mpf mpf_div #define atslib_mpf_div3_ui mpf_div_ui #define atslib_mpf_ui_div3 mpf_ui_div ATSinline() ats_void_type atslib_mpf_div2_mpf (ats_ref_type dst, ats_ref_type src2) { mpf_div ((mpf_ptr)dst, (mpf_ptr)dst, (mpf_ptr)src2) ; return ; } // end of [atslib_mpf_div2_mpf] ATSinline() ats_void_type atslib_mpf_div2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_div_ui ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_div2_ui] ATSinline() ats_void_type atslib_mpf_ui_div2 ( ats_ref_type dst, ats_ulint_type src1 ) { mpf_ui_div ((mpf_ptr)dst, src1, (mpf_ptr)dst) ; return ; } // end of [atslib_mpf_ui_div2] /* ****** ****** */ #define atslib_mpf_sqrt2_mpf mpf_sqrt #define atslib_mpf_sqrt2_ui mpf_sqrt_ui ATSinline() ats_void_type atslib_mpf_sqrt1_mpf (ats_ref_type dst) { mpf_sqrt ((mpf_ptr)dst, (mpf_ptr)dst) ; return ; } // end of [atslib_mpf_sqrt1] /* ****** ****** */ #define atslib_mpf_pow3_ui mpf_pow_ui ATSinline() ats_void_type atslib_mpf_pow2_ui ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_pow_ui ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_pow2_ui] /* ****** ****** */ #define atslib_mpf_mul3_2exp mpf_mul_2exp ATSinline() ats_void_type atslib_mpf_mul2_2exp ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_mul_2exp ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_mul2_2exp] /* ****** ****** */ #define atslib_mpf_div3_2exp mpf_div_2exp ATSinline() ats_void_type atslib_mpf_div2_2exp ( ats_ref_type dst, ats_ulint_type src2 ) { mpf_div_2exp ((mpf_ptr)dst, (mpf_ptr)dst, src2) ; return ; } // end of [atslib_mpf_div2_2exp] /* ****** ****** */ #define atslib_mpf_eq mpf_eq #define atslib_mpf_cmp_mpf mpf_cmp #define atslib_mpf_cmp_si mpf_cmp_si #define atslib_mpf_cmp_ui mpf_cmp_ui #define atslib_mpf_cmp_d mpf_cmp_d #define atslib_mpf_sgn mpf_sgn /* ****** ****** */ #define atslib_mpf_reldiff mpf_reldiff /* ****** ****** */ // // HX: input/output/print functions // #define atslib_mpf_out_str mpf_out_str #define atslib_mpf_inp_str mpf_inp_str extern ats_void_type atslib_mpf_out_str_exn ( ats_ptr_type, ats_int_type, ats_size_type, ats_mpf_ptr_type ) ; // end of [extern] ATSinline() ats_void_type atslib_fprint_mpf ( ats_ptr_type file, ats_mpf_ptr_type x, ats_size_type ndigit ) { atslib_mpf_out_str_exn (file, 10/*base*/, ndigit, x) ; return ; } // end of [atslib_fprint_mpf] ATSinline() ats_void_type atslib_print_mpf ( const ats_mpf_ptr_type x, ats_size_type ndigit ) { atslib_mpf_out_str_exn (stdout, 10/*base*/, ndigit, x) ; return ; } // end of [atslib_print_mpf] ATSinline() ats_void_type atslib_prerr_mpf ( const ats_mpf_ptr_type x, ats_size_type ndigit ) { atslib_mpf_out_str_exn (stderr, 10/*base*/, ndigit, x) ; return ; } // end of [atslib_prerr_mpf] /* ****** ****** */ // // random number generators for MPZ, MPQ and MPF // #define atslib_gmp_randclear gmp_randclear #define atslib_gmp_randinit_default gmp_randinit_default #define atslib_gmp_randinit_lc_2exp gmp_randinit_lc_2exp #define atslib_gmp_randinit_lc_2exp_size gmp_randinit_lc_2exp_size // #define atslib_gmp_randseed_mpz gmp_randseed #define atslib_gmp_randseed_ui gmp_randseed_ui // #define atslib_mpz_urandomb mpz_urandomb #define atslib_mpz_urandomm mpz_urandomm #define atslib_mpz_rrandomb mpz_rrandomb #define atslib_mpz_random mpz_random #define atslib_mpz_random2 mpz_random2 // #define atslib_mpf_random2 mpf_random2 #define atslib_mpf_urandomb mpf_urandomb /* ****** ****** */ #endif /* ATS_LIBC_GMP_CATS */ /* end of [gmp.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/float.cats0000664000175000017500000000354212223166162017425 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_FLOAT_CATS #define ATS_LIBC_FLOAT_CATS /* ****** ****** */ #include /* ****** ****** */ #ifndef DBL_RADIX #define DBL_RADIX FLT_RADIX #endif #ifndef LDBL_RADIX #define LDBL_RADIX FLT_RADIX #endif /* ****** ****** */ #ifndef DBL_ROUNDS #define DBL_ROUNDS FLT_ROUNDS #endif #ifndef LDBL_ROUNDS #define LDBL_ROUNDS FLT_ROUNDS #endif /* ****** ****** */ #endif /* ATS_LIBC_FLOAT_CATS */ /* end of [float.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/dirent.cats0000664000175000017500000000712212223166162017603 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_DIRENT_CATS #define ATS_LIBC_DIRENT_CATS /* ****** ****** */ #include #include #include #include // for [perror] /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ /* typedef ino_t ats_ino_type ; // defined in sys/CATS/types.cats */ /* ****** ****** */ typedef DIR ats_DIR_type ; typedef struct dirent ats_dirent_type ; /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg (ats_int_type n, ats_ptr_type msg) ; // end of [ats_exit_errmsg] // // HX: implemented in [prelude/CATS/printf.cats] // extern ats_void_type atspre_exit_prerrf (ats_int_type code, ats_ptr_type fmt, ...) ; // end of [atspre_exit_prerrf] /* ****** ****** */ ATSinline() ats_ino_type atslib_dirent_get_d_ino (ats_ptr_type dir) { return ((ats_dirent_type*)dir)->d_ino ; } // end of [atslib_dirent_get_d_ino] ATSinline() ats_ptr_type atslib_dirent_get_d_name (ats_ptr_type dir) { return ((ats_dirent_type*)dir)->d_name ; } // end of [atslib_dirent_get_d_name] /* ****** ****** */ #define atslib_opendir_err opendir ATSinline() ats_ptr_type atslib_opendir_exn (ats_ref_type path) { DIR* ret = opendir (path) ; if (!ret) { perror ("opendir") ; atspre_exit_prerrf (errno, "exit(ATS): [opendir(%s)] failed.\n", path) ; } // end of [if] return ret ; } /* end of [atslib_opendir_exn] */ /* ****** ****** */ #define atslib_closedir_err closedir ATSinline() ats_void_type atslib_closedir_exn (ats_ptr_type dir) { int err = closedir (dir) ; if (err < 0) { perror ("closedir") ; ats_exit_errmsg (errno, "exit(ATS): [closedir] failed.\n") ; } // end of [if] return ; } /* end of [atslib_closedir_exn] */ /* ****** ****** */ #define atslib_readdir readdir ATSinline() ats_int_type atslib_readdir_r ( ats_ptr_type dir, ats_ref_type ent, ats_ref_type ret ) { int err = readdir_r ( (DIR*)dir, (ats_dirent_type*)ent, (ats_dirent_type**)ret ) ; return err ; } /* end of [atslib_readdir_r] */ /* ****** ****** */ #define atslib_rewinddir rewinddir #define atslib_seekdir seekdir #define atslib_telldir telldir /* ****** ****** */ #endif /* ATS_LIBC_DIRENT_CATS */ ats-lang-anairiats-0.2.11/libc/CATS/math.cats0000664000175000017500000001056012223166162017247 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_MATH_CATS #define ATS_LIBC_MATH_CATS /* ****** ****** */ #include /* ****** ****** */ // // HX: fpclassify // #define atslib_fpclassify(x) fpclassify(x) #define atslib_isfinite(x) isfinite(x) #define atslib_isnormal(x) isnormal(x) /* ****** ****** */ // // HX: [isinf] and [isnan] are BSD provision // #define atslib_isinf isinf #define atslib_isinff isinff #define atslib_isinfl isinfl #define atslib_isnan isnan #define atslib_isnanf isnanf #define atslib_isnanl isnanl /* ****** ****** */ #define atslib_ceil ceil #define atslib_ceilf ceilf #define atslib_ceill ceill #define atslib_floor floor #define atslib_floorf floorf #define atslib_floorl floorl #define atslib_round round #define atslib_roundf roundf #define atslib_roundl roundl #define atslib_trunc trunc #define atslib_truncf truncf #define atslib_truncl truncl #define atslib_fmod fmod #define atslib_fmodf fmodf #define atslib_fmodl fmodl /* ****** ****** */ #define atslib_fmax fmax #define atslib_fmaxf fmaxf #define atslib_fmaxl fmaxl #define atslib_fmin fmin #define atslib_fminf fminf #define atslib_fminl fminl #define atslib_fdim fdim #define atslib_fdimf fdimf #define atslib_fdiml fdiml #define atslib_fma fma #define atslib_fmaf fmaf #define atslib_fmal fmal /* ****** ****** */ #define atslib_sqrt sqrt #define atslib_sqrtf sqrtf #define atslib_sqrtl sqrtl #define atslib_cbrt cbrt #define atslib_cbrtf cbrtf #define atslib_cbrtl cbrtl #define atslib_pow pow #define atslib_powf powf #define atslib_powl powl /* ****** ****** */ #define atslib_exp exp #define atslib_expf expf #define atslib_expl expl /* ****** ****** */ #define atslib_log log #define atslib_logf logf #define atslib_logl logl #define atslib_log10 log10 #define atslib_log10f log10f #define atslib_log10l log10l /* ****** ****** */ #define atslib_asin asin #define atslib_asinf asinf #define atslib_asinl asinl #define atslib_acos acos #define atslib_acosf acosf #define atslib_acosl acosl #define atslib_atan atan #define atslib_atanf atanf #define atslib_atanl atanl #define atslib_atan2 atan2 #define atslib_atan2f atan2f #define atslib_atan2l atan2l /* ****** ****** */ #define atslib_asinh asinh #define atslib_asinhf asinhf #define atslib_asinhl asinhl #define atslib_acosh acosh #define atslib_acoshf acoshf #define atslib_acoshl acoshl #define atslib_atanh atanh #define atslib_atanhf atanhf #define atslib_atanhl atanhl /* ****** ****** */ #define atslib_sin sin #define atslib_sinf sinf #define atslib_sinl sinl #define atslib_cos cos #define atslib_cosf cosf #define atslib_cosl cosl #define atslib_tan tan #define atslib_tanf tanf #define atslib_tanl tanl /* ****** ****** */ #define atslib_sinh sinh #define atslib_sinhf sinhf #define atslib_sinhl sinhl #define atslib_cosh cosh #define atslib_coshf coshf #define atslib_coshl coshl #define atslib_tanh tanh #define atslib_tanhf tanhf #define atslib_tanhl tanhl /* ****** ****** */ #endif /* ATS_LIBC_MATH_CATS */ /* end of [math.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/netdb.cats0000664000175000017500000000625612223166162017421 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_NETDB_CATS #define ATS_LIBC_NETDB_CATS /* ****** ****** */ #include #include #include /* ****** ****** */ typedef struct addrinfo ats_addrinfo_type ; typedef struct hostent ats_hostent_type ; /* ****** ****** */ // #define atslib_addrinfoptr_get_addr(x) (((ats_addrinfo_type*)x)->ai_addr) #define atslib_addrinfoptr_get_addrlen(x) (((ats_addrinfo_type*)x)->ai_addrlen) // #define atslib_addrinfoptr_get_cannonname(x) (((ats_addrinfo_type*)x)->ai_cannonname) // #define atslib_addrinfoptr_get_family(x) (((ats_addrinfo_type*)x)->ai_family) #define atslib_addrinfoptr_get_protocol(x) (((ats_addrinfo_type*)x)->ai_protocol) #define atslib_addrinfoptr_get_socktype(x) (((ats_addrinfo_type*)x)->ai_socktype) // #define atslib_addrinfoptr_get_next(x) (((ats_addrinfo_type*)x)->ai_next) // /* ****** ****** */ #define atslib_getaddrinfo(node, port, hint, res) \ getaddrinfo((char*)node, (char*)port, (ats_addrinfo_type*)hint, (ats_addrinfo_type**)res) #define atslib_gai_strerror gai_strerror #define atslib_freeaddrinfo freeaddrinfo /* ****** ****** */ #define atslib_hostent_get_name(h) \ (((ats_hostent_type*)h)->h_name) #define atslib_hostent_get_aliases(h) \ (((ats_hostent_type*)h)->h_aliases) #define atslib_hostent_get_addr_list(h) \ (((ats_hostent_type*)h)->h_addr_list) #define atslib_sethostent sethostent #define atslib_gethostent gethostent #define atslib_endhostent endhostent /* ****** ****** */ #define atslib_gethostbyname gethostbyname #define atslib_gethostbyaddr gethostbyaddr /* ****** ****** */ #define atslib_getnameinfo getnameinfo /* ****** ****** */ #define atslib_gethostid gethostid #define atslib_sethostid sethostid /* ****** ****** */ #endif /* ATS_LIBC_NETDB_CATS */ /* end of [netdb.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/fcntl.cats0000664000175000017500000001310012223166162017415 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_FCNTL_CATS #define ATS_LIBC_FCNTL_CATS /* ****** ****** */ #include #include /* ****** ****** */ #include "libc/sys/CATS/types.cats" /* ****** ****** */ // // HX: functions declared in [unistd.h] // extern ssize_t read (int fd, void *buf, size_t cnt) ; extern ssize_t write (int fd, const void *buf, size_t cnt) ; /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ typedef ats_int_type ats_fcntlflag_type ; /* ****** ****** */ ATSinline() ats_int_type atslib_lnot_disjflag (ats_fcntlflag_type df) { return (~df) ; } // end of [atslib_lnot_disjflag] ATSinline() ats_int_type atslib_lor_flag_disjflag ( ats_fcntlflag_type f, ats_fcntlflag_type df ) { return (f | df) ; } // end of [atslib_lor_flag_disjflag] ATSinline() ats_int_type atslib_land_flag_conjflag ( ats_fcntlflag_type f, ats_fcntlflag_type cf ) { return (f & cf) ; } // end of [atslib_land_flag_conjflag] /* ****** ****** */ ATSinline() ats_int_type atslib_open_flag_err ( ats_ptr_type path, ats_fcntlflag_type flag ) { return open((char*)path, flag) ; } // end of [atslib_open_flag_err] ATSinline() ats_int_type atslib_open_flag_mode_err ( ats_ptr_type path , ats_fcntlflag_type flag , ats_mode_type mode ) { return open((char*)path, flag, mode) ; } // end of [atslib_open_flag_mode_err] /* ****** ****** */ ATSinline() ats_int_type atslib_open_flag_exn (ats_ptr_type path, ats_fcntlflag_type flag) { int fd = open((char*)path, flag) ; if (fd < 0) { perror ("open") ; ats_exit_errmsg(1, "exit(ATS): [open_flag] failed.\n") ; } // end of [if] return fd ; } // end of [atslib_open_flag_exn] ATSinline() ats_int_type atslib_open_flag_mode_exn ( ats_ptr_type path , ats_fcntlflag_type flag , ats_mode_type mode ) { int fd = open((char*)path, flag, mode) ; if (fd < 0) { perror ("open") ; ats_exit_errmsg(1, "exit(ATS): [open_flag_mode] failed.\n") ; } // end of [if] return fd ; } // end of [atslib_open_flag_mode_exn] /* ****** ****** */ ATSinline() ats_int_type atslib_close_err (ats_int_type fd) { return close(fd) ; } /* ****** ****** */ ATSinline() ats_ssize_type atslib_fildes_read_err (ats_int_type fd, ats_ptr_type buf, ats_size_type cnt) { return read(fd, buf, cnt) ; } // end of [atslib_fildes_read_err] ATSinline() ats_size_type atslib_fildes_read_exn (ats_int_type fd, ats_ptr_type buf, ats_size_type cnt) { ats_ssize_type res ; res = read(fd, buf, cnt) ; if (res < 0) { perror("read") ; ats_exit_errmsg(1, "exit(ATS): [fildes_read] failed.\n") ; } // end of [if] return res ; } // end of [atslib_fildes_read_exn] /* ****** ****** */ ATSinline() ats_ssize_type atslib_fildes_write_err (ats_int_type fd, ats_ptr_type buf, ats_size_type cnt) { return write(fd, buf, cnt) ; } // end of [atslib_fildes_write_err] ATSinline() ats_size_type atslib_fildes_write_exn (ats_int_type fd, ats_ptr_type buf, ats_size_type cnt) { ats_ssize_type res ; res = write(fd, buf, cnt) ; if (res < 0) { perror("write") ; ats_exit_errmsg(1, "exit(ATS): [fildes_write] failed.\n") ; } // end of [if] return res ; } // end of [atslib_fildes_write_exn] /* ****** ****** */ ATSinline() ats_ssize_type atslib_fildes_write_substring_err ( ats_int_type fd, ats_ptr_type str, ats_size_type start, ats_size_type n ) { return write(fd, ((char*)str)+start, n) ; } // end of [atslib_fildes_write_substring_err] ATSinline() ats_size_type atslib_fildes_write_substring_exn ( ats_int_type fd, ats_ptr_type str, ats_size_type start, ats_size_type n ) { ats_ssize_type res ; res = write(fd, ((char*)str)+start, n) ; if (res < 0) { perror("write") ; ats_exit_errmsg(1, "exit(ATS): [fildes_write] failed.\n") ; } // end of [if] return res ; } // end of [ats_fildes_write_substring_exn] /* ****** ****** */ ATSinline() ats_fcntlflag_type atslib_fcntl_getfl (ats_int_type fd) { return fcntl(fd, F_GETFL) ; } ATSinline() ats_int_type atslib_fcntl_setfl ( ats_int_type fd, ats_fcntlflag_type flag ) { return fcntl(fd, F_SETFL, flag) ; } // end of [atslib_fcntl_setfl] /* ****** ****** */ #endif /* ATS_LIBC_FCNTL_CATS */ ats-lang-anairiats-0.2.11/libc/CATS/grp.cats0000664000175000017500000000431212223166162017104 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_GRP_CATS #define ATS_LIBC_GRP_CATS /* ****** ****** */ #include #include /* ****** ****** */ typedef struct group ats_group_type ; /* ****** ****** */ ATSinline() ats_ptr_type atslib_group_get_gr_name (ats_ptr_type gr) { return ((ats_group_type*)gr)->gr_name ; } // end of [group_get_gr_name] ATSinline() ats_ptr_type atslib_group_get_gr_passwd (ats_ptr_type gr) { return ((ats_group_type*)gr)->gr_passwd ; } // end of [group_get_gr_passwd] ATSinline() ats_ptr_type atslib_group_get_gr_mem (ats_ptr_type gr) { return ((ats_group_type*)gr)->gr_mem ; } // end of [group_get_gr_mem] /* ****** ****** */ #define atslib_getgrnam getgrnam #define atslib_getgrgid getgrgid /* ****** ****** */ #endif /* ATS_LIBC_GRP_CATS */ /* end of [grp.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/errno.cats0000664000175000017500000000455412223166162017451 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_ERRNO_CATS #define ATS_LIBC_ERRNO_CATS /* ****** ****** */ #include /* ****** ****** */ #define ENONE 0 // indicating no error /* ****** ****** */ ATSinline() ats_int_type atslib_errno_get () { return errno ; } // end of [atslib_errno_get] ATSinline() ats_void_type atslib_errno_set (ats_int_type n) { errno = n ; return ; } // end of [atslib_errno_set] ATSinline() ats_void_type atslib_errno_reset () { errno = 0/*ENONE*/ ; return ; } // end of [atslib_errno_reset] /* ****** ****** */ ATSinline() ats_bool_type atslib_eq_errno_errno (ats_int_type n1, ats_int_type n2) { return (n1 == n2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_eq_errno_errno] ATSinline() ats_bool_type atslib_neq_errno_errno (ats_int_type n1, ats_int_type n2) { return (n1 != n2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_neq_errno_errno] /* ****** ****** */ #endif /* ATS_LIBC_ERRNO_CATS */ /* end of [errno.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/dlfcn.cats0000664000175000017500000000525112223166162017405 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_DLFCN_CATS #define ATS_LIBC_DLFCN_CATS /* ****** ****** */ #include #include extern void exit (int) ; /* ****** ****** */ ATSinline() ats_int_type atslib_lor_dlopen_flag_dlopen_flagext (ats_int_type flag, ats_int_type ext) { return (flag | ext) ; } // end of [atslib_lor_dlopen_flag_dlopen_flagext] /* ****** ****** */ #define atslib_dlopen dlopen ATSinline() ats_ptr_type atslib_dlopen_exn ( ats_ptr_type filename, ats_int_type flag ) { void *p ; char *msg ; p = dlopen ((char*)filename, (int)flag) ; if (!p) { msg = dlerror () ; // HX: [msg] cannot be null fprintf (stderr, (ats_ptr_type)"exit(ATS): %s\n", msg) ; exit (1) ; } // end of [if] return p ; } // end of [atslib_dlopen_exn] /* ****** ****** */ #define atslib_dlclose dlclose ATSinline() ats_void_type atslib_dlclose_exn (ats_ptr_type handle) { int err ; char *msg ; err = dlclose ((void*)handle) ; if (err != 0) { msg = dlerror () ; // HX: [msg] cannot be null fprintf (stderr, (ats_ptr_type)"exit(ATS): %s\n", msg) ; exit (1) ; } // end of [if] return ; } // end of [atslib_dlclose_exn] /* ****** ****** */ #define atslib_dlerror dlerror #define atslib_dlsym dlsym /* ****** ****** */ #endif /* ATS_LIBC_DLFCN_CATS */ ats-lang-anairiats-0.2.11/libc/CATS/unistd.cats0000664000175000017500000001220512223166162017622 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_UNISTD_CATS #define ATS_LIBC_UNISTD_CATS /* ****** ****** */ #include #include #include // for [wait] #include /* ****** ****** */ #include "libc/sys/CATS/types.cats" // for [pid_t] /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ #define atslib_dup dup #define atslib_dup2 dup2 /* ****** ****** */ #define atslib__exit _exit // equivalent to _Exit in stdlib /* ****** ****** */ ATSinline() ats_ptr_type atslib_strarr_get ( ats_ptr_type A, ats_size_type i ) { return ((char**)A)[i] ; } // end of [atslib_strarr_get] /* ****** ****** */ #define atslib_execv execv #define atslib_execvp execvp #define atslib_execl execl // HX: no interface in ATS #define atslib_execlp execlp // HX: no interface in ATS /* ****** ****** */ #define atslib_fork_err fork /* ****** ****** */ #define atslib_getcwd getcwd /* ****** ****** */ #define atslib_alarm_set alarm #define atslib_alarm_cancel() alarm(0U) /* ****** ****** */ #define atslib_sleep sleep #define atslib_usleep usleep /* ****** ****** */ #define atslib_getpagesize getpagesize /* ****** ****** */ #define atslib_getuid getuid #define atslib_geteuid geteuid #define atslib_getgid getgid #define atslib_getegid getegid /* ****** ****** */ #define atslib_getpid getpid #define atslib_getppid getppid #define atslib_setsid setsid #define atslib_getsid getsid #define atslib_setpgid setpgid #define atslib_getpgid getpgid /* ****** ****** */ #define atslib_getlogin getlogin #define atslib_getlogin_r getlogin_r /* ****** ****** */ #define atslib_access access /* ****** ****** */ #define atslib_chroot chroot /* ****** ****** */ #define atslib_chdir chdir #define atslib_fchdir fchdir /* ****** ****** */ #define atslib_nice nice /* ****** ****** */ #define atslib_rmdir rmdir /* ****** ****** */ #define atslib_link link #define atslib_unlink unlink /* ****** ****** */ #define atslib_fildes_lseek_err lseek ATSinline() ats_off_type atslib_fildes_lseek_exn ( ats_int_type fd , ats_off_type ofs , ats_int_type whence ) { off_t ofs_new ; ofs_new = lseek(fd, ofs, whence) ; if (ofs_new == (ats_off_type)(-1)) { perror ("lseek") ; ats_exit_errmsg (1, "exit(ATS): [lseek] failed\n") ; } return ofs_new ; } /* end of [atslib_fildes_lseek_exn] */ /* ****** ****** */ #define atslib_fildes_pread pread #define atslib_fildes_pwrite pwrite /* ****** ****** */ #define atslib_sync sync #define atslib_fsync fsync #define atslib_fdatasync fdatasync /* ****** ****** */ #define atslib_pathconf pathconf #define atslib_fpathconf fpathconf /* ****** ****** */ #define atslib_readlink readlink /* ****** ****** */ #define atslib_tcsetpgrp tcsetpgrp #define atslib_tcgetpgrp tcgetpgrp /* ****** ****** */ #define atslib_ttyname ttyname #define atslib_ttyname_r ttyname_r #define atslib_isatty isatty /* ****** ****** */ ATSinline() ats_int_type atslib_gethostname ( ats_ptr_type bufp, ats_size_type len ) { int rtn ; rtn = gethostname((char*)bufp, len) ; if (rtn == 0) ((char*)bufp)[len] = '\0' ; // HX: force it to be null terminated! return rtn ; } // end of [atslib_gethostname] #define atslib_sethostname sethostname /* ****** ****** */ ATSinline() ats_int_type atslib_getdomainname ( ats_ptr_type bufp, ats_size_type len ) { int rtn ; rtn = getdomainname((char*)bufp, len) ; if (rtn == 0) ((char*)bufp)[len] = '\0' ; // HX: force it to be null terminated! return rtn ; } // end of [atslib_getdomainname] #define atslib_setdomainname setdomainname /* ****** ****** */ #define atslib_pause pause /* ****** ****** */ #endif /* ATS_LIBC_UNISTD_CATS */ /* end of [unistd.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/curses.cats0000664000175000017500000000433412223166162017624 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_CURSES_CATS #define ATS_LIBC_CURSES_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_initscr initscr #define atslib_endwin endwin #define atslib_isendwin isendwin /* ****** ****** */ #define atslib_raw raw #define atslib_noraw noraw /* ****** ****** */ #define atslib_clear clear #define atslib_clrtobot clrtobot #define atslib_clrtoeol clrtoeol #define atslib_erase erase /* ****** ****** */ #define atslib_beep beep #define atslib_flush flush /* ****** ****** */ #define atslib_addstr addstr #define atslib_addnstr addnstr #define atslib_mvaddstr mvaddstr #define atslib_mvaddnstr mvaddnstr /* ****** ****** */ #define atslib_refresh refresh #define atslib_doupdate doupdate /* ****** ****** */ #endif /* ATS_LIBC_CURSES_CATS */ /* end of [curses.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/pthread_uplock.cats0000664000175000017500000000501712223166162021323 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ /* ** A linking error is issued if a user does not define ** [_ATS_MULTITHREAD] while triing to use them anyways */ /* #ifndef _ATS_MULTITHREAD #error "[pthread_uplock.cats]: _ATS_MULTITHREAD is undefined!" #endif */ /* ****** ****** */ #ifndef ATS_LIBC_PTHREAD_UPLOCK_CATS #define ATS_LIBC_PTHREAD_UPLOCK_CATS /* ****** ****** */ #ifdef _ATS_MULTITHREAD /* ****** ****** */ #include #include #include #include /* ****** ****** */ // locks and tickets for uploading typedef struct { pthread_mutex_t mutex_res; /* for resource protection */ } ats_pthread_uplock_t ; /* linear lock uploading */ typedef ats_pthread_uplock_t ats_pthread_upticket_t ; /* ****** ****** */ ATSinline() ats_void_type atslib_pthread_uplock_destroy (ats_ptr_type p) { pthread_mutex_destroy (&((ats_pthread_uplock_t*)p)->mutex_res) ; ATS_FREE(p) ; } // end of [atslib_pthread_uplock_destroy] /* ****** ****** */ #endif // end of [#ifdef _ATS_MULTITHREAD] /* ****** ****** */ #endif // end of [#ifndef ATS_LIBC_PTHREAD_UPLOCK_CATS] /* ****** ****** */ /* end of [pthread_uplock.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/pthread_upbarr.cats0000664000175000017500000000461712223166162021326 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ /* ** A linking error is issued if a user does not define ** [_ATS_MULTITHREAD] while triing to use them anyways */ /* #ifndef _ATS_MULTITHREAD #error "[pthread_upbarr.cats]: _ATS_MULTITHREAD is undefined!" #endif */ /* ****** ****** */ #ifndef ATS_LIBC_PTHREAD_UPBARR_CATS #define ATS_LIBC_PTHREAD_UPBARR_CATS /* ****** ****** */ #ifdef _ATS_MULTITHREAD /* ****** ****** */ #include #include #include #include /* ****** ****** */ // barrs and tickets for uploading typedef struct { int count ; /* outstanding tickets */ pthread_cond_t cond_eqz; /* for signaling [count==0] */ pthread_mutex_t mutex_res; /* for resource protection */ } ats_pthread_upbarr_t ; /* linear barr uploading */ typedef ats_pthread_upbarr_t ats_pthread_upticket_t ; /* ****** ****** */ #endif // end of [#ifdef _ATS_MULTITHREAD] /* ****** ****** */ #endif // end of [#ifndef ATS_LIBC_PTHREAD_UPBARR_CATS] /* ****** ****** */ /* end of [pthread_upbarr.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/string.cats0000664000175000017500000000543012223166162017624 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_STRING_CATS #define ATS_LIBC_STRING_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_strcmp strcmp ATSinline() ats_int_type atslib_substrcmp ( ats_ptr_type str1, ats_size_type i1 , ats_ptr_type str2, ats_size_type i2 ) { return strcmp((char*)str1+i1, (char*)str2+i2) ; } /* end of [atslib_substrcmp] */ /* ****** ****** */ #define atslib_strncmp strncmp ATSinline() ats_int_type atslib_substrncmp ( ats_ptr_type str1, ats_size_type i1 , ats_ptr_type str2, ats_size_type i2 , ats_size_type n) { return strncmp(((char*)str1)+i1, ((char*)str2)+i2, n) ; } // end of [atslib_substrncmp] /* ****** ****** */ #define atslib_strlen strlen /* ****** ****** */ #define atslib_strchr strchr #define atslib_strrchr strrchr #define atslib_strstr strstr /* ****** ****** */ #define atslib_strspn strspn #define atslib_strcspn strcspn /* ****** ****** */ #define atslib_strcpy strcpy #define atslib_strcat strcat #define atslib_strncat strncat // HX: no interface in ATS /* ****** ****** */ #define atslib_strpbrk strpbrk /* ****** ****** */ #define atslib_memchr memchr #define atslib_memcmp memcmp #define atslib_memcpy memcpy #define atslib_memset memset /* ****** ****** */ #define atslib_strerror strerror #define atslib_strerror_r strerror_r /* ****** ****** */ #endif /* ATS_LIBC_STRING_CATS */ /* end of [string.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/unistd_sysconf.cats0000664000175000017500000000326212223166162021371 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_UNISTD_SYSCONF_CATS #define ATS_LIBC_UNISTD_SYSCONF_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_sysconf sysconf /* ****** ****** */ #endif /* ATS_LIBC_UNISTD_SYSCONF_CATS */ /* end of [unistd_sysconf.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/strings.cats0000664000175000017500000000336112223166162020010 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_STRINGS_CATS #define ATS_LIBC_STRINGS_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_ffs ffs /* ****** ****** */ #define atslib_strcasecmp strcasecmp #define atslib_strncasecmp strncasecmp /* ****** ****** */ #endif /* ATS_LIBC_STRINGS_CATS */ /* end of [strings.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/ctype.cats0000664000175000017500000000400312223166162017435 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_CTYPE_CATS #define ATS_LIBC_CTYPE_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_isalnum isalnum #define atslib_isalpha isalpha #define atslib_isascii isascii #define atslib_isblank isblank #define atslib_iscntrl iscntrl #define atslib_isdigit isdigit #define atslib_isgraph isgraph #define atslib_islower islower #define atslib_isprint isprint #define atslib_ispunct ispunct #define atslib_isspace isspace #define atslib_isupper isupper #define atslib_isxdigit isxdigit /* ****** ****** */ #endif /* ATS_LIBC_CTYPE_CATS */ /* end of [ctype.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/termios.cats0000664000175000017500000000426512223166162020005 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_TERMIOS_CATS #define ATS_LIBC_TERMIOS_CATS /* ****** ****** */ #include /* ****** ****** */ typedef cc_t ats_cc_type ; typedef tcflag_t ats_tcflag_type ; typedef speed_t ats_speed_type ; /* ****** ****** */ #define atslib_tcgetattr tcgetattr #define atslib_tcsetattr tcsetattr /* ****** ****** */ #define atslib_cfgetispeed cfgetispeed #define atslib_cfsetispeed cfsetispeed #define atslib_cfgetospeed cfgetospeed #define atslib_cfsetospeed cfsetospeed /* ****** ****** */ #define atslib_tcflow tcflow #define atslib_tcdrain tcdrain #define atslib_tcflush tcflush #define atslib_tcsendbreak tcsendbreak /* ****** ****** */ #define atslib_tcgetsid tcgetsid /* ****** ****** */ #endif /* ATS_LIBC_TERMIOS_CATS */ /* end of [termios.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/SIMD_v2df.cats0000664000175000017500000000614312223166162017775 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ // // for supporting SIMD on vectors of 2 doubles // /* ****** ****** */ #ifndef ATS_LIBC_SIMD_V2DF_CATS #define ATS_LIBC_SIMD_V2DF_CATS /* ****** ****** */ // for vectors of two doubles typedef double v2df __attribute__((vector_size(16))) ; typedef v2df ats_v2df_type ; /* ****** ****** */ static ats_v2df_type atslib_v2df_0_0 = { 0.0, 0.0 } ; static ats_v2df_type atslib_v2df_1_1 = { 1.0, 1.0 } ; /* ****** ****** */ static inline ats_v2df_type atslib_v2df_make_double_double ( ats_double_type d0, ats_double_type d1 ) { v2df dd = { d0, d1 } ; return dd ; } /* end of [ats_v2df_make_double_double] */ static inline ats_v2df_type atslib_v2df_make_int_int ( ats_int_type i0, ats_int_type i1 ) { v2df dd = { i0, i1 } ; return dd ; } /* end of [ats_v2df_make_int_int] */ /* ****** ****** */ static inline ats_double_type atslib_v2df_get_fst (ats_v2df_type dd) { return ((double*)&dd)[0] ; } static inline ats_double_type atslib_v2df_get_snd (ats_v2df_type dd) { return ((double*)&dd)[1] ; } static inline ats_v2df_type atslib_add_v2df_v2df ( ats_v2df_type dd1, ats_v2df_type dd2 ) { return (dd1 + dd2) ; } /* end of [atslib_add_v2df_v2df] */ static inline ats_v2df_type atslib_sub_v2df_v2df ( ats_v2df_type dd1, ats_v2df_type dd2 ) { return (dd1 - dd2) ; } /* end of [atslib_sub_v2df_v2df] */ static inline ats_v2df_type atslib_mul_v2df_v2df ( ats_v2df_type dd1, ats_v2df_type dd2 ) { return (dd1 * dd2) ; } /* end of [atslib_mul_v2df_v2df] */ static inline ats_v2df_type atslib_div_v2df_v2df ( ats_v2df_type dd1, ats_v2df_type dd2 ) { return (dd1 / dd2) ; } /* end of [atslib_div_v2df_v2df] */ /* ****** ****** */ #endif /* ATS_LIBC_SIMD_V2DF_CATS */ /* end of [SIMD_v2df.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/time.cats0000664000175000017500000001124612223166162017256 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_TIME_CATS #define ATS_LIBC_TIME_CATS /* ****** ****** */ #include /* ****** ****** */ #include "libc/sys/CATS/types.cats" /* ****** ****** */ typedef struct tm ats_tm_struct_type ; typedef struct timespec ats_timespec_type ; typedef struct itimerspec ats_itimerspec_type ; /* ****** ****** */ #define atslib_difftime difftime /* ****** ****** */ ATSinline() ats_int_type atslib_tm_get_sec (ats_ptr_type tm) { return ((struct tm*)tm)->tm_sec ; } // end of [atslib_tm_get_sec] ATSinline() ats_int_type atslib_tm_get_min (ats_ptr_type tm) { return ((struct tm*)tm)->tm_min ; } // end of [atslib_tm_get_min] ATSinline() ats_int_type atslib_tm_get_hour (ats_ptr_type tm) { return ((struct tm*)tm)->tm_hour ; } // end of [atslib_tm_get_hour] ATSinline() ats_int_type atslib_tm_get_mday (ats_ptr_type tm) { return ((struct tm*)tm)->tm_mday ; } // end of [atslib_tm_get_mday] ATSinline() ats_int_type atslib_tm_get_mon (ats_ptr_type tm) { return ((struct tm*)tm)->tm_mon ; } // end of [atslib_tm_get_mon] ATSinline() ats_int_type atslib_tm_get_year (ats_ptr_type tm) { return ((struct tm*)tm)->tm_year ; } // end of [atslib_tm_get_year] ATSinline() ats_int_type atslib_tm_get_wday (ats_ptr_type tm) { return ((struct tm*)tm)->tm_wday ; } // end of [atslib_tm_get_wday] ATSinline() ats_int_type atslib_tm_get_yday (ats_ptr_type tm) { return ((struct tm*)tm)->tm_yday ; } // end of [atslib_tm_get_yday] ATSinline() ats_int_type atslib_tm_get_isdst (ats_ptr_type tm) { return ((struct tm*)tm)->tm_isdst ; } // end of [atslib_tm_get_isdst] // /* ****** ****** */ ATSinline() ats_time_type atslib_time_get () { return time((time_t*)0) ; } ATSinline() ats_int_type atslib_time_get_and_set (ats_ref_type p) { time_t err = time((time_t*)p) ; return (err > 0) ? ats_true_bool : ats_false_bool ; } // end of [atslib_time_get_and_set] /* ****** ****** */ #define atslib_ctime ctime #define atslib_ctime_r ctime_r /* ****** ****** */ #define atslib_localtime localtime #define atslib_localtime_r localtime_r #define atslib_gmtime gmtime #define atslib_gmtime_r gmtime_r /* ****** ****** */ #define atslib_mktime mktime /* ****** ****** */ #define atslib_asctime asctime #define atslib_strftime strftime /* ****** ****** */ extern int getdate_err ; ATSinline() ats_int_type atslib_getdate_err_get() { return getdate_err ;} // ATSinline() ats_void_type atslib_getdate_err_set(ats_int_type n) { getdate_err = n ; return ; } // #define atslib_getdate getdate #define atslib_strptime strptime /* ****** ****** */ #define atslib_tzset tzset /* ****** ****** */ #define atslib_clock clock /* ****** ****** */ #define atslib_nanosleep nanosleep #define atslib_nanosleep_null(ts) nanosleep_null(ts, NULL) /* ****** ****** */ #define atslib_clock_gettime clock_gettime #define atslib_clock_getres clock_getres #define atslib_clock_settime clock_settime /* ****** ****** */ #define atslib_timer_create timer_create #define atslib_timer_create_null(cid, p_tid) timer_create(cid, NULL, p_tid) #define atslib_timer_delete timer_delete #define atslib_timer_gettime timer_gettime #define atslib_timer_settime timer_settime #define atslib_timer_getoverrun timer_getoverrun /* ****** ****** */ #endif /* ATS_LIBC_TIME_CATS */ /* end of [time.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/sched.cats0000664000175000017500000000552012223166162017404 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 // /* ****** ****** */ #ifndef ATS_LIBC_SCHED_CATS #define ATS_LIBC_SCHED_CATS /* ****** ****** */ #include #include "libc/sys/CATS/types.cats" /* ****** ****** */ typedef struct sched_param ats_sched_param_type ; /* ****** ****** */ #ifdef __USE_GNU /* ****** ****** */ ATSinline() ats_size_type atslib_cpusetsize_get (ats_ref_type mask) { return sizeof(cpu_set_t) ; } // end of [atslib_cpusetsize_get] /* ****** ****** */ /* fun sched_getaffinity {n:nat} ( pid: pid_t, n: size_t n, cs: &cpu_set_t n? >> opt (cpu_set_t n, i==0) ) : #[i:int | i <= 0] int i(*err*) = "atslib_sched_getaffinity" // end of [sched_getaffinity] */ ATSinline() ats_int_type atslib_sched_getaffinity ( ats_pid_type pid, ats_size_type n, ats_ref_type mask ) { return sched_getaffinity (pid, n, (cpu_set_t*)mask) ; } // end of [atslib_sched_getaffinity] /* fun sched_setaffinity {n:nat} (pid: pid_t, n: size_t n, mask: &cpu_set_t n): int(*err*) = "atslib_sched_setaffinity" */ ATSinline() ats_int_type atslib_sched_setaffinity ( ats_pid_type pid, ats_size_type n, ats_ref_type mask ) { return sched_setaffinity (pid, n, (cpu_set_t*)mask) ; } // end of [atslib_sched_setaffinity] /* ****** ****** */ #define atslib_CPU_ZERO CPU_ZERO #define atslib_CPU_CLR CPU_CLR #define atslib_CPU_SET CPU_SET #define atslib_CPU_ISSET CPU_ISSET /* ****** ****** */ #endif // end of [__USE_GNU] /* ****** ****** */ #endif /* ATS_LIBC_SCHED_CATS */ ats-lang-anairiats-0.2.11/libc/CATS/pwd.cats0000664000175000017500000000546712223166162017122 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_PWD_CATS #define ATS_LIBC_PWD_CATS /* ****** ****** */ #include #include /* ****** ****** */ typedef struct passwd ats_passwd_type ; /* ****** ****** */ ATSinline() ats_ptr_type atslib_passwd_get_pw_name (ats_ptr_type pw) { return ((ats_passwd_type*)pw)->pw_name ; } // end of [passwd_get_pw_name] ATSinline() ats_ptr_type atslib_passwd_get_pw_passwd (ats_ptr_type pw) { return ((ats_passwd_type*)pw)->pw_passwd ; } // end of [passwd_get_pw_passwd] ATSinline() ats_ptr_type atslib_passwd_get_pw_gecos (ats_ptr_type pw) { return ((ats_passwd_type*)pw)->pw_gecos ; } // end of [passwd_get_pw_gecos] ATSinline() ats_ptr_type atslib_passwd_get_pw_dir (ats_ptr_type pw) { return ((ats_passwd_type*)pw)->pw_dir ; } // end of [passwd_get_pw_dir] ATSinline() ats_ptr_type atslib_passwd_get_pw_shell (ats_ptr_type pw) { return ((ats_passwd_type*)pw)->pw_shell ; } // end of [passwd_get_pw_shell] /* ****** ****** */ #define atslib_getpwnam getpwnam #define atslib_getpwnam_r(nam, pwbuf, buf, n, ppwbuf) \ getpwnam_r(nam, (ats_passwd_type*)pwbuf, (char*)buf, n, (ats_passwd_type**)ppwbuf) /* ****** ****** */ #define atslib_getpwuid getpwuid #define atslib_getpwuid_r(uid, pwbuf, buf, n, ppwbuf) \ getpwuid_r(uid, (ats_passwd_type*)pwbuf, (char*)buf, n, (ats_passwd_type**)ppwbuf) /* ****** ****** */ #endif /* ATS_LIBC_PWD_CATS */ /* end of [pwd.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/random.cats0000664000175000017500000000600012223166162017570 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_RANDOM_CATS #define ATS_LIBC_RANDOM_CATS /* ****** ****** */ #include #include #include /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ typedef struct drand48_data ats_drand48_data_type ; /* ****** ****** */ ATSinline() ats_void_type atslib_srand48 (ats_lint_type seed) { srand48 ((long int)seed) ; return ; } // end of [atslib_srand48] ATSinline() ats_void_type atslib_srand48_with_time () { srand48 ((long int)(time ((time_t*)0))) ; return ; } // end of [atslib_srand48_with_time] /* ****** ****** */ ATSinline() ats_double_type atslib_drand48 () { return drand48() ; } ATSinline() ats_lint_type atslib_lrand48 () { return lrand48() ; } ATSinline() ats_lint_type atslib_mrand48 () { return mrand48() ; } /* ****** ****** */ ATSinline() ats_int_type atslib_srand48_r (ats_lint_type seed, ats_ref_type buf) { return srand48_r (seed, (ats_drand48_data_type*)buf) ; } // end of [atslib_srand48_r] /* ****** ****** */ ATSinline() ats_int_type atslib_drand48_r (ats_ref_type buf, ats_ref_type res) { return drand48_r ((ats_drand48_data_type*)buf, (ats_double_type*)res) ; } // end of [drand48_r] ATSinline() ats_int_type atslib_lrand48_r (ats_ref_type buf, ats_ref_type res) { return lrand48_r ((ats_drand48_data_type*)buf, (ats_lint_type*)res) ; } // end of [lrand48_r] ATSinline() ats_int_type atslib_mrand48_r (ats_ref_type buf, ats_ref_type res) { return mrand48_r ((ats_drand48_data_type*)buf, (ats_lint_type*)res) ; } // end of [lrand48_r] /* ****** ****** */ #endif /* ATS_LIBC_RANDOM_CATS */ /* end of [random.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/stdio.cats0000664000175000017500000003116612223166162017445 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_STDIO_CATS #define ATS_LIBC_STDIO_CATS /* ****** ****** */ #include #include /* ****** ****** */ #include "ats_types.h" typedef fpos_t ats_fpos_type ; typedef FILE ats_FILE_viewtype ; /* --------------------------------------- */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; // // HX: implemented in [prelude/CATS/printf.cats] // extern ats_void_type atspre_exit_prerrf(ats_int_type code, ats_ptr_type fmt, ...) ; /* --------------------------------------- */ extern ats_void_type atspre_stdin_view_get() ; extern ats_void_type atspre_stdout_view_get() ; extern ats_void_type atspre_stderr_view_get() ; extern ats_void_type atspre_stdin_view_set() ; extern ats_void_type atspre_stdout_view_set() ; extern ats_void_type atspre_stderr_view_set() ; /* --------------------------------------- */ ATSinline() ats_void_type atslib_clearerr (ats_ptr_type fil) { clearerr ((FILE*)fil) ; return ; } /* --------------------------------------- */ #define atslib_fclose_err fclose ATSinline() ats_void_type atslib_fclose_exn(ats_ptr_type fil) { int err = fclose((FILE*)fil) ; if (err < 0) { perror ("fclose") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [fclose] failed\n") ; } // end of [if] return ; } ATSinline() ats_void_type atslib_fclose_stdin() { atspre_stdin_view_get() ; atslib_fclose_exn(stdin) ; return ; } ATSinline() ats_void_type atslib_fclose_stdout() { atspre_stdout_view_get() ; atslib_fclose_exn(stdout) ; return ; } ATSinline() ats_void_type atslib_fclose_stderr() { atspre_stderr_view_get() ; atslib_fclose_exn(stderr) ; return ; } /* ****** ****** */ /* #define atslib_feof feof // HX: cgwin defines [feof] as a macro */ ATSinline() ats_int_type atslib_feof(ats_ref_type filp) { return feof((FILE*)filp) ; } /* ****** ****** */ /* #define atslib_ferror ferror */ ATSinline() ats_int_type atslib_ferror(ats_ref_type filp) { return ferror((FILE*)filp) ; } /* ****** ****** */ #define atslib_fflush_err fflush ATSinline() ats_void_type atslib_fflush_exn( ats_ptr_type fil ) { int err = fflush((FILE*)fil) ; if (err < 0) { perror ("fflush") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [fflush] failed\n") ; } // end of [if] return ; } /* end of [atslib_fflush_exn] */ ATSinline() ats_void_type atslib_fflush_stdout (void) { atspre_stdout_view_get (); atslib_fflush_exn (stdout); atspre_stdout_view_set () ; return ; } /* end of [atslib_fflush_stdout] */ /* --------------------------------------- */ #define atslib_fgetc_err fgetc ATSinline() ats_int_type atslib_getchar () { int i ; atspre_stdin_view_get (); i = getchar (); atspre_stdin_view_set () ; return i ; } /* end of [atslib_getchar] */ /* --------------------------------------- */ #define atslib_fgets_err fgets ATSinline() ats_void_type atslib_fgets_exn ( ats_ptr_type buf , ats_int_type n , ats_ptr_type fil ) { ats_ptr_type p ; p = fgets((char*)buf, (int)n, (FILE*)fil) ; if (!p) { if (feof((FILE*)fil)) { *(char*)buf = '\000' ; // EOF is reached } else { perror ("fgets") ; ats_exit_errmsg(1, (ats_ptr_type)"exit(ATS): [fgets] failed\n") ; } // end of [if] } /* end of [if] */ return ; } /* end of [atslib_fgets_exn] */ /* --------------------------------------- */ #define atslib_fgetpos fgetpos /* --------------------------------------- */ #define atslib_fileno fileno /* --------------------------------------- */ #define atslib_fopen_err fopen ATSinline() ats_ptr_type atslib_fopen_exn ( ats_ptr_type name, ats_ptr_type mode ) { FILE *fil = fopen((char*)name, (char*)mode) ; if (!fil) { perror ("fopen") ; atspre_exit_prerrf (1, "exit(ATS): [fopen(\"%s\", \"%s\")] failed\n", name, mode) ; } // end of [if] return fil ; } /* atslib_fopen_exn */ /* --------------------------------------- */ #define atslib_fputc_err fputc ATSinline() ats_void_type atslib_fputc_exn ( ats_char_type c, ats_ptr_type fil ) { int n = fputc((unsigned char)c, (FILE*)fil) ; if (n < 0) { perror ("fputc") ; atspre_exit_prerrf (1, "exit(ATS): [fputc(%c)] failed\n", c) ; } return ; } // end of [atslib_fputc_exn] /* --------------------------------------- */ #define atslib_fputs_err fputs ATSinline() ats_void_type atslib_fputs_exn( ats_ptr_type s, ats_ptr_type fil ) { int n = fputs ((char*)s, (FILE*)fil) ; if (n < 0) { perror ("fputs") ; atspre_exit_prerrf (1, "exit(ATS): [fputs(%s)] failed\n", s) ; } return ; } // end of [atslib_fputs_exn] /* --------------------------------------- */ #define atslib_fread fread ATSinline() ats_size_type atslib_fread_byte ( ats_ptr_type buf , ats_size_type n , ats_ptr_type fil ) { return fread ((void*)buf, 1, n, (FILE*)fil) ; } // end of [atslib_fread_byte] ATSinline() ats_void_type atslib_fread_byte_exn ( ats_ptr_type buf , ats_size_type ntotal , ats_ptr_type fil ) { int nread ; nread = fread ((void*)buf, 1, ntotal, (FILE*)fil) ; if (nread < ntotal) { perror ("fread") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [fread] failed\n") ; } return ; } // end of [atslib_fread_byte_exn] /* --------------------------------------- */ #define atslib_freopen_err freopen ATSinline() ats_void_type atslib_freopen_exn( ats_ptr_type name , ats_ptr_type mode , ats_ptr_type fil ) { FILE *fil_new = freopen(name, mode, (FILE*)fil) ; if (!fil_new) { perror ("freopen") ; atspre_exit_prerrf ( 1, "exit(ATS): [freopen(\"%s\", \"%s\")] failed\n", name, mode ) ; } return ; } // end of [atslib_freopen_exn] /* --------------------------------------- */ ATSinline() ats_void_type atslib_freopen_stdin (ats_ptr_type name) { FILE *fil_new ; atspre_stdin_view_get() ; fil_new = freopen(name, "r", stdin) ; if (!fil_new) { perror ("freopen") ; atspre_exit_prerrf ( 1, "exit(ATS): [freopen_stdin(\"%s\")] failed\n", name ) ; } atspre_stdin_view_set() ; return ; } // end of [atslib_freopen_stdin] ATSinline() ats_void_type atslib_freopen_stdout (ats_ptr_type name) { FILE *fil_new ; atspre_stdout_view_get () ; fil_new = freopen(name, "w", stdout) ; if (!fil_new) { perror ("freopen") ; atspre_exit_prerrf ( 1, "exit(ATS): [freopen_stdout(\"%s\")] failed\n", name ) ; } atspre_stdout_view_set () ; return ; } // end of [atslib_freopen_stdout] ATSinline() ats_void_type atslib_freopen_stderr (ats_ptr_type name) { FILE *fil_new ; atspre_stderr_view_get() ; fil_new = freopen(name, "w", stderr) ; if (!fil_new) { perror ("freopen") ; atspre_exit_prerrf ( 1, "exit(ATS): [freopen_stderr(\"%s\")] failed\n", name ) ; } atspre_stderr_view_set() ; return ; } // end of [atslib_freopen_stderr] /* --------------------------------------- */ #define atslib_fseek_err fseek ATSinline() ats_void_type atslib_fseek_exn ( ats_ptr_type fil , ats_lint_type offset , ats_int_type whence ) { int err ; err = fseek ((FILE*)fil, offset, whence) ; if (err < 0) { perror ("fseek") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [fseek] failed\n") ; } return ; } // end of [atslib_fseek_exn] /* --------------------------------------- */ #define atslib_ftell_err ftell ATSinline() ats_lint_type atslib_ftell_exn( ats_ptr_type fil ) { long int ret = ftell((FILE*)fil) ; if (ret < 0) { perror ("ftell") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [ftell] failed\n") ; } return ret ; } // end of [atslib_ftell_exn] /* --------------------------------------- */ #define atslib_fwrite fwrite ATSinline() ats_size_type atslib_fwrite_byte ( ats_ptr_type buf , ats_size_type n , ats_ptr_type fil ) { return fwrite((void*)buf, 1, n, (FILE*)fil) ; } /* end of [atslib_fwrite_byte] */ ATSinline() ats_void_type atslib_fwrite_byte_exn ( ats_ptr_type buf0 , ats_size_type ntotal , ats_ptr_type fil ) { char *buf = (char*) buf0 ; size_t nwritten ; nwritten = fwrite((void*)buf, 1, ntotal, (FILE*)fil) ; if (nwritten < ntotal) { perror ("fwrite") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [fwrite] failed\n") ; } return ; } /* end of [atslib_fwrite_all_byte] */ /* --------------------------------------- */ ATSinline() ats_void_type atslib_perror( ats_ptr_type msg ) { atspre_stderr_view_get () ; perror ((char*)msg) ; atspre_stderr_view_set () ; return ; } // end of [atslib_perror] /* --------------------------------------- */ ATSinline() ats_int_type atslib_putchar( ats_char_type c ) { int i ; atspre_stdout_view_get () ; i = putchar((unsigned char)c) ; atspre_stdout_view_set () ; return i ; } /* end of [atslib_putchar] */ /* --------------------------------------- */ ATSinline() ats_int_type atslib_puts_err( ats_ptr_type str ) { int err ; atspre_stdout_view_get () ; err = puts ((char*)str) ; atspre_stdout_view_set () ; return err ; } /* end of [atslib_puts_err] */ ATSinline() ats_void_type atslib_puts_exn( ats_ptr_type str ) { int err ; atspre_stdout_view_get () ; err = puts ((char*)str) ; atspre_stdout_view_set () ; if (err < 0) { perror ("puts") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [remove] failed\n") ; } /* end of [if] */ return ; } /* end of [atslib_puts_exn] */ /* --------------------------------------- */ #define atslib_remove_err remove ATSinline() ats_void_type atslib_remove_exn( ats_ptr_type path ) { int err = remove((char*)path) ; if (err < 0) { perror ("remove") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [remove] failed\n") ; } return ; } // end of [atslib_remove_exn] /* --------------------------------------- */ #define atslib_rename_err rename ATSinline() ats_void_type atslib_rename_exn( ats_ptr_type oldpath, ats_ptr_type newpath ) { int err = rename((char*)oldpath, (char*)newpath) ; if (err < 0) { perror ("rename") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [rename] failed\n") ; } return ; } // end of [atslib_rename_exn] /* --------------------------------------- */ #define atslib_rewind rewind /* --------------------------------------- */ #define atslib_tmpfile_err tmpfile ATSinline() ats_ptr_type atslib_tmpfile_exn () { FILE* fil = tmpfile() ; if (!fil) { perror ("tmpfile") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [tmpfile] failed\n") ; } return fil ; } // end of [atslib_tmpfile_exn] /* --------------------------------------- */ #define atslib_ungetc_err ungetc ATSinline() ats_void_type atslib_ungetc_exn ( ats_char_type c, ats_ptr_type fil ) { int err = ungetc((unsigned char)c, (FILE*)fil) ; if (err < 0) { perror ("ungetc") ; ats_exit_errmsg (1, (ats_ptr_type)"exit(ATS): [ungetc] failed\n") ; } // end of [if] return ; } // end of [atslib_ungetc_exn] /* --------------------------------------- */ ATSinline() ats_void_type atslib_setbuf_null ( ats_ptr_type fil ) { setbuf((FILE*)fil, NULL) ; return ; } // end of [atslib_setbuf_null] #define atslib_setbuffer setbuffer #define atslib_setlinebuf setlinebuf ATSinline() ats_int_type atslib_setvbuf_null ( ats_ptr_type fil , ats_int_type mode ) { return setvbuf((FILE*)fil, NULL, mode, 0) ; } // end of [atslib_setbuf_null] #define atslib_setvbuf setvbuf /* --------------------------------------- */ #endif /* ATS_LIBC_STDIO_CATS */ /* end of [stdio.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/stdlib.cats0000664000175000017500000000642312223166162017602 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_STDLIB_CATS #define ATS_LIBC_STDLIB_CATS /* ****** ****** */ #include #include /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ // implemented in [prelude/CATS/printf.cats] extern ats_void_type atspre_exit_prerrf(ats_int_type code, ats_ptr_type fmt, ...) ; /* ****** ****** */ #define atslib_atoi atoi #define atslib_atof atof #define atslib_atol atol #define atslib_atoll atoll /* ****** ****** */ #define atslib_strtoi_errnul(str, base) strtoi(str, NULL, base) #define atslib_strtol_errnul(str, base) strtol(str, NULL, base) #define atslib_strtoll_errnul(str, base) strtoll(str, NULL, base) /* ****** ****** */ #define atslib_getenv getenv #define atslib_putenv putenv #define atslib_setenv setenv #define atslib_unsetenv unsetenv /* ****** ****** */ #define atslib_abort aboirt #define atslib__Exit _Exit #define atslib_atexit atexit /* ****** ****** */ #define atslib_system system /* ****** ****** */ #define atslib_mkstemp mkstemp #define atslib_mkdtemp mkdtemp /* ****** ****** */ // // HX: [atslib_bsearch] is slightly different from [bsearch] // ATSinline() ats_int_type atslib_bsearch ( ats_ref_type key, ats_ref_type base, ats_size_type nmemb, ats_size_type size, ats_fun_ptr_type compar ) { void *p ; p = bsearch ( key, base, nmemb, size, (int(*)(const void*, const void*))compar ) ; // end of [bsearch] if (!p) return -1 ; return ((char*)p - (char*)base) / size ; } /* end of [atslib_bsearch] */ /* ****** ****** */ // // HX: [atslib_qsort] is the same as [qsort] // ATSinline() ats_void_type atslib_qsort ( ats_ref_type base, ats_size_type nmemb, ats_size_type size, ats_ptr_type compar ) { qsort(base, nmemb, size, (int(*)(const void*, const void*))compar) ; return ; } /* end of [atslib_qsort] */ /* ****** ****** */ #endif /* ATS_LIBC_STDLIB_CATS */ /* end of [stdlib.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/stdarg.cats0000664000175000017500000000470712223166162017610 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_STDARG_CATS #define ATS_LIBC_STDARG_CATS /* ****** ****** */ #include /* ****** ****** */ ATSinline() ats_bool_type atslib_va_arg_bool (ats_ref_type ap) { return va_arg(*(va_list*)ap, ats_int_type) ; } // end of ... ATSinline() ats_char_type // note the need for alignment atslib_va_arg_char (ats_ref_type ap) { return va_arg(*(va_list*)ap, ats_int_type) ; } // end of ... ATSinline() ats_int_type atslib_va_arg_int (ats_ref_type ap) { return va_arg(*(va_list*)ap, ats_int_type) ; } // end of ... ATSinline() ats_ptr_type atslib_va_arg_ptr (ats_ref_type ap) { return va_arg(*(va_list*)ap, ats_ptr_type) ; } // end of ... /* ****** ****** */ ATSinline() ats_void_type atslib_va_end (ats_ref_type ap) { va_end(*(va_list*)ap) ; return ; } /* ****** ****** */ ATSinline() ats_void_type atslib_va_copy (ats_ref_type dst, va_list src) { va_copy(*(va_list*)dst, src) ; return ; // do dst and src share? } // end of [atslib_va_copy] /* ****** ****** */ #endif /* ATS_LIBC_STDARG_CATS */ /* end of [stdarg.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/printf.cats0000664000175000017500000000523612223166162017624 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_PRINTF_CATS #define ATS_LIBC_PRINTF_CATS /* ****** ****** */ #include /* ****** ****** */ #include /* ****** ****** */ ATSinline() ats_int_type atslib_vprintf ( ats_ptr_type fmt , ats_ref_type arg ) { return vprintf ((char*)fmt, *(va_list*)arg) ; } /* end of [atslib_vprintf] */ ATSinline() ats_int_type atslib_vfprintf ( ats_ptr_type out , ats_ptr_type fmt , ats_ref_type arg ) { return vfprintf ((FILE*)out, (char*)fmt, *(va_list*)arg) ; } /* end of [atslib_vfprintf] */ /* ****** ****** */ #if (0) // // HX: [snprintf] is now implemented in $ATSHOME/libc/DATS/printf.dats // ATSinline() ats_int_type atslib_snprintf ( ats_ptr_type buf , ats_size_type sz , ats_ptr_type fmt , ... ) { int ntot ; va_list ap ; va_start(ap, fmt) ; ntot = vsnprintf (buf, sz, (char*)fmt, ap) ; va_end(ap) ; return ntot ; } /* end of [atslib_snprintf] */ #endif // end of [#if(0)] /* ****** ****** */ ATSinline() ats_int_type atslib_vsnprintf ( ats_ptr_type buf , ats_size_type sz , ats_ptr_type fmt , ats_ref_type arg ) { int n ; n = vsnprintf (buf, sz, (char*)fmt, *(va_list*)arg) ; return n ; } /* end of [atslib_vsnprintf] */ /* ****** ****** */ #endif /* ATS_LIBC_PRINTF_CATS */ /* end of [printf.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/unistd_pathconf.cats0000664000175000017500000000333312223166162021506 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_UNISTD_PATHCONF_CATS #define ATS_LIBC_UNISTD_PATHCONF_CATS /* ****** ****** */ #include /* ****** ****** */ #define atslib_pathconf pathconf #define atslib_fpathconf fpathconf /* ****** ****** */ #endif /* ATS_LIBC_UNISTD_PATHCONF_CATS */ /* end of [unistd_pathconf.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/signal.cats0000664000175000017500000000575612223166162017606 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SIGNAL_CATS #define ATS_LIBC_SIGNAL_CATS /* ****** ****** */ #include /* ****** ****** */ typedef ats_int_type signum_t ; typedef void (*sighandler_t)(signum_t) ; /* ****** ****** */ typedef struct sigaction ats_sigaction_type ; /* ****** ****** */ #define atslib_sigaction sigaction #define atslib_sigaction_null(signum, act) \ sigaction(signum, act, (ats_sigaction_type*)0) /* ****** ****** */ #define atslib_sigemptyset sigemptyset #define atslib_sigfillset sigfillset #define atslib_sigaddset sigaddset #define atslib_sigdelset sigdelset /* ****** ****** */ #define atslib_pthread_sigmask pthread_sigmask #define atslib_pthread_sigmask_null(how, newset) pthread_sigmask(how, newset, NULL) #define atslib_sigprocmask sigprocmask #define atslib_sigprocmask_null(how, newset) sigprocmask(how, newset, NULL) /* ****** ****** */ #define atslib_signal signal #define atslib_sigset sigset #define atslib_sighold sighold #define atslib_sigignore sigignore #define atslib_sigrelse sigrelse /* ****** ****** */ #define atslib_kill kill #define atslib_killpg killpg #define atslib_pthread_kill pthread_kill #define atslib_raise raies /* ****** ****** */ #define atslib_sigwait sigwait #define atslib_sigsuspend sigsuspend #define atslib_sigpause sigpause /* ****** ****** */ #define atslib_sigpending sigpending #define atslib_siginterrupt siginterrupt /* ****** ****** */ #define atslib_psignal psignal extern char* strsignal (signum_t sgn) ; // declared in #define atslib_strsignal strsignal /* ****** ****** */ #endif /* ATS_LIBC_SIGNAL_CATS */ ats-lang-anairiats-0.2.11/libc/CATS/complex.cats0000664000175000017500000002356012223166162017771 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_COMPLEX_CATS #define ATS_LIBC_COMPLEX_CATS /* ****** ****** */ #include // extern FILE *stdout ; // declared in [stdio.h] // extern FILE *stderr ; // declared in [stdio.h] /* ****** ****** */ #include #include /* ****** ****** */ typedef float complex ats_fcomplex_type ; typedef double complex ats_dcomplex_type ; typedef long double complex ats_lcomplex_type ; /* ****** ****** */ extern float sinf (float) ; // should be in [math.h] extern float cosf (float) ; // should be in [math.h] /* ****** ****** */ /* ** complex numbers of single precision */ /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_ccmplx_of_int (ats_int_type i) { return i ; } ATSinline() ats_fcomplex_type atslib_ccmplx_of_float (ats_float_type f) { return f ; } ATSinline() ats_fcomplex_type atslib_ccmplx_make_cart (ats_float_type r, ats_float_type i) { return (r + i * I) ; } ATSinline() ats_fcomplex_type atslib_ccmplx_make_polar (ats_float_type r, ats_float_type t) { return (r * cosf(t)) + (r * sinf(t)) * I ; } /* ****** ****** */ ATSinline() ats_float_type atslib_crealf (ats_fcomplex_type c) { return crealf(c) ; } ATSinline() ats_float_type atslib_cimagf (ats_fcomplex_type c) { return cimagf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_neg_ccmplx (ats_fcomplex_type c) { return (-c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_add_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 + c2) ; } /* end of [atslib_add_ccmplx_ccmplx] */ ATSinline() ats_fcomplex_type atslib_sub_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 - c2) ; } /* end of [atslib_sub_ccmplx_ccmplx] */ ATSinline() ats_fcomplex_type atslib_mul_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 * c2) ; } /* end of [atslib_mul_ccmplx_ccmplx] */ ATSinline() ats_fcomplex_type atslib_div_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 / c2) ; } /* end of [atslib_div_ccmplx_ccmplx] */ /* ****** ****** */ ATSinline() ats_bool_type atslib_eq_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 == c2 ? ats_true_bool : ats_false_bool) ; } /* end of [atslib_eq_ccmplx_ccmplx] */ ATSinline() ats_bool_type atslib_neq_ccmplx_ccmplx (ats_fcomplex_type c1, ats_fcomplex_type c2) { return (c1 != c2 ? ats_true_bool : ats_false_bool) ; } /* end of [atslib_neq_ccmplx_ccmplx] */ /* ****** ****** */ ATSinline() ats_float_type atslib_cabsf (ats_fcomplex_type c) { return cabsf(c) ; } ATSinline() ats_fcomplex_type atslib_csqrtf (ats_fcomplex_type c) { return csqrtf(c) ; } /* ****** ****** */ ATSinline() ats_float_type atslib_cargf (ats_fcomplex_type c) { return cargf(c) ; } ATSinline() ats_fcomplex_type atslib_conjf (ats_fcomplex_type c) { return conjf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_csinf (ats_fcomplex_type c) { return csinf(c) ; } ATSinline() ats_fcomplex_type atslib_ccosf (ats_fcomplex_type c) { return ccosf(c) ; } ATSinline() ats_fcomplex_type atslib_ctanf (ats_fcomplex_type c) { return ctanf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_casinf (ats_fcomplex_type c) { return casinf(c) ; } ATSinline() ats_fcomplex_type atslib_cacosf (ats_fcomplex_type c) { return cacosf(c) ; } ATSinline() ats_fcomplex_type atslib_catanf (ats_fcomplex_type c) { return catanf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_csinhf (ats_fcomplex_type c) { return csinhf(c) ; } ATSinline() ats_fcomplex_type atslib_ccoshf (ats_fcomplex_type c) { return ccoshf(c) ; } ATSinline() ats_fcomplex_type atslib_ctanhf (ats_fcomplex_type c) { return ctanhf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_casinhf (ats_fcomplex_type c) { return casinhf(c) ; } ATSinline() ats_fcomplex_type atslib_cacoshf (ats_fcomplex_type c) { return cacoshf(c) ; } ATSinline() ats_fcomplex_type atslib_catanhf (ats_fcomplex_type c) { return catanhf(c) ; } /* ****** ****** */ ATSinline() ats_fcomplex_type atslib_cexpf (ats_fcomplex_type c) { return cexpf(c) ; } ATSinline() ats_fcomplex_type atslib_clogf (ats_fcomplex_type c) { return clogf(c) ; } ATSinline() ats_fcomplex_type atslib_cpowf ( ats_fcomplex_type c1 , ats_fcomplex_type c2 ) { return cpowf(c1, c2) ; } /* end of [atslib_cpowf] */ #define atslib_pow_ccmplx_float(c1, c2) atslib_cpowf(c1,(ats_fcomplex_type)c2) /* ****** ****** */ ATSinline() ats_float_type atslib_cprojf (ats_fcomplex_type c) { return cprojf(c) ; } /* ****** ****** */ /* ** complex numbers of double precision */ /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_zcmplx_of_int (ats_int_type i) { return i ; } ATSinline() ats_dcomplex_type atslib_zcmplx_of_double (ats_double_type d) { return d ; } ATSinline() ats_dcomplex_type atslib_zcmplx_make_cart (ats_double_type r, ats_double_type i) { return (r + i * I) ; } ATSinline() ats_dcomplex_type atslib_zcmplx_make_polar (ats_double_type r, ats_double_type t) { return (r * cos(t)) + (r * sin(t)) * I ; } /* ****** ****** */ ATSinline() ats_double_type atslib_creal (ats_dcomplex_type z) { return creal(z) ; } ATSinline() ats_double_type atslib_cimag (ats_dcomplex_type z) { return cimag(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_neg_zcmplx (ats_dcomplex_type z) { return (-z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_add_zcmplx_zcmplx (ats_dcomplex_type z1, ats_dcomplex_type z2) { return (z1 + z2) ; } /* end of [atslib_add_zcmplx_zcmplx] */ ATSinline() ats_dcomplex_type atslib_sub_zcmplx_zcmplx (ats_dcomplex_type z1, ats_dcomplex_type z2) { return (z1 - z2) ; } /* end of [atslib_sub_zcmplx_zcmplx] */ ATSinline() ats_dcomplex_type atslib_mul_zcmplx_zcmplx (ats_dcomplex_type z1, ats_dcomplex_type z2) { return (z1 * z2) ; } /* end of [atslib_mul_zcmplx_zcmplx] */ ATSinline() ats_dcomplex_type atslib_div_zcmplx_zcmplx (ats_dcomplex_type z1, ats_dcomplex_type z2) { return (z1 / z2) ; } /* end of [atslib_div_zcmplx_zcmplx] */ /* ****** ****** */ ATSinline() ats_bool_type atslib_eq_zcmplx_zcmplx (ats_dcomplex_type c1, ats_dcomplex_type c2) { return (c1 == c2 ? ats_true_bool : ats_false_bool) ; } /* end of [atslib_eq_zcmplx_zcmplx] */ ATSinline() ats_bool_type atslib_neq_zcmplx_zcmplx (ats_dcomplex_type c1, ats_dcomplex_type c2) { return (c1 != c2 ? ats_true_bool : ats_false_bool) ; } /* end of [atslib_neq_zcmplx_zcmplx] */ /* ****** ****** */ ATSinline() ats_double_type atslib_cabs (ats_dcomplex_type z) { return cabs(z) ; } ATSinline() ats_dcomplex_type atslib_csqrt (ats_dcomplex_type z) { return csqrt(z) ; } /* ****** ****** */ ATSinline() ats_double_type atslib_carg (ats_dcomplex_type z) { return carg(z) ; } ATSinline() ats_dcomplex_type atslib_conj (ats_dcomplex_type z) { return conj(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_csin (ats_dcomplex_type z) { return csin(z) ; } ATSinline() ats_dcomplex_type atslib_ccos (ats_dcomplex_type z) { return ccos(z) ; } ATSinline() ats_dcomplex_type atslib_ctan (ats_dcomplex_type z) { return ctan(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_casin (ats_dcomplex_type z) { return casin(z) ; } ATSinline() ats_dcomplex_type atslib_cacos (ats_dcomplex_type z) { return cacos(z) ; } ATSinline() ats_dcomplex_type atslib_catan (ats_dcomplex_type z) { return catan(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_csinh (ats_dcomplex_type z) { return csinh(z) ; } ATSinline() ats_dcomplex_type atslib_ccosh (ats_dcomplex_type z) { return ccosh(z) ; } ATSinline() ats_dcomplex_type atslib_ctanh (ats_dcomplex_type z) { return ctanh(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_casinh (ats_dcomplex_type z) { return casinh(z) ; } ATSinline() ats_dcomplex_type atslib_cacosh (ats_dcomplex_type z) { return cacosh(z) ; } ATSinline() ats_dcomplex_type atslib_catanh (ats_dcomplex_type z) { return catanh(z) ; } /* ****** ****** */ ATSinline() ats_dcomplex_type atslib_cexp (ats_dcomplex_type z) { return cexp(z) ; } ATSinline() ats_dcomplex_type atslib_clog (ats_dcomplex_type z) { return clog(z) ; } ATSinline() ats_dcomplex_type atslib_cpow ( ats_dcomplex_type z1 , ats_dcomplex_type z2 ) { return cpow(z1, z2) ; } /* end of [atslib_cpow] */ #define atslib_pow_zcmplx_double(z1, z2) atslib_cpow(z1,(ats_dcomplex_type)z2) /* ****** ****** */ ATSinline() ats_double_type atslib_cproj (ats_dcomplex_type z) { return cproj(z) ; } /* ****** ****** */ #endif /* ATS_LIBC_COMPLEX_CATS */ /* end of [complex.cats] */ ats-lang-anairiats-0.2.11/libc/CATS/utime.cats0000664000175000017500000000331112223166162017435 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_UTIME_CATS #define ATS_LIBC_UTIME_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct utimbuf ats_utimbuf_type ; /* ****** ****** */ #define atslib_utime utime /* ****** ****** */ #endif /* ATS_LIBC_UTIME_CATS */ /* end of [utime.cats] */ ats-lang-anairiats-0.2.11/libc/SATS/0000700000175000017500000000000012223166162015444 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/SATS/pthread_upbarr.sats0000664000175000017500000000633212223166162021362 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/pthread_upbarr.cats" %} // end of [%{#] (* ****** ****** *) // // HX: any pthread-error leads to CRASH: [ats_crash] is called // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for static loading at run-time (* ****** ****** *) // // linear barrier for uploading // absviewtype upbarr_view_viewtype (v:view) stadef upbarr = upbarr_view_viewtype // // HX: [upticket] is declared in pthread_uplock.sats as well // absviewtype upticket_view_viewtype (v:view) stadef upticket = upticket_view_viewtype (* ****** ****** *) prfun pthread_upbarr_trans {v1:view} {v2:view} (f: v1 - v2 | barr: !upbarr (v1) >> upbarr (v2)): void // end of [pthread_upbarr_trans] prfun pthread_upbarr_unitelim {v:view} (barr: !upbarr @(unit_v, v) >> upbarr (v)): void // end of [pthread_upbarr_unitelim] (* ****** ****** *) viewtypedef upbarr0 = upbarr (unit_v) fun pthread_upbarr_create (): upbarr (unit_v) = "atslib_pthread_upbarr_create" // end of [pthread_upbarr_create] fun pthread_upbarr_download {v:view} (barr: !upbarr (v) >> upbarr0): (v | void) = "atslib_pthread_upbarr_download" // end of [pthread_upbarr_download] fun pthread_upbarr_destroy (barr: upbarr0): void = "atslib_pthread_upbarr_destroy" // end of [pthread_upbarr_destroy] fun pthread_upbarr_download_and_destroy {v:view} (barr: upbarr (v)): (v | void) (* ****** ****** *) fun pthread_upticket_create {v1:view} {v2:view} (barr: !upbarr (v1) >> upbarr @(v1, v2)): upticket (v2) = "atslib_pthread_upbarr_upticket_create" // end of [pthread_upticket_create] fun pthread_upticket_upload_and_destroy {v:view} (pf: v | ticket: upticket v): void = "atslib_pthread_upbarr_upticket_upload_and_destroy" // end of [pthread_upticket_upload_and_destroy] (* ****** ****** *) (* end of [pthread_upbarr.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/dirent.sats0000664000175000017500000000712112223166162017642 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef ino_t = $TYPES.ino_t typedef off_t = $TYPES.off_t (* ****** ****** *) %{# #include "libc/CATS/dirent.cats" // included after types.cats %} // end of [%{#] (* ****** ****** *) // defined in dirent.cats abst@ype DIR_t0ype = $extype"ats_DIR_type" // = DIR typedef DIR = DIR_t0ype abst@ype dirent_t0ype = $extype"ats_dirent_type" // = struct dirent typedef dirent = dirent_t0ype (* ****** ****** *) fun dirent_get_d_ino (ent: &dirent):<> ino_t = "atslib_direct_get_d_ino" // end of [dirent_get_d_ino] fun dirent_get_d_name (ent: &dirent):<> [l:agz] (strptr l - void | strptr l) = "atslib_dirent_get_d_name" // end of [dirent_get_d_name] (* ****** ****** *) fun opendir_err (s: string) : [l_dir:addr] (option_v (DIR @ l_dir, l_dir > null) | ptr l_dir) = "mac#atslib_opendir_err" // macro! fun opendir_exn (s: string) : [l_dir:addr] (DIR @ l_dir | ptr l_dir) = "atslib_opendir_exn" // end of [opendir_exn] // function! (* ****** ****** *) fun closedir_err {l_dir:addr} ( pf: DIR @ l_dir | p: ptr l_dir ) :<> int = "mac#atslib_closedir_err" // macro! fun closedir_exn {l_dir:addr} ( pf: DIR @ l_dir | p: ptr l_dir ) : void = "atslib_closedir_exn" // function! (* ****** ****** *) fun readdir ( dir: &DIR ) :<> [l_ent:addr] ( vptroutopt (dirent, l_ent) | ptr l_ent ) = "mac#atslib_readdir" // end of [readdir] (* ****** ****** *) fun rewinddir (dir: &DIR): void = "mac#atslib_rewinddir" fun seekdir (dir: &DIR, off: off_t): void = "mac#atslib_seekdir" fun telldir (dir: &DIR): off_t = "mac#atslib_telldir" (* ****** ****** *) viewtypedef direntptr_gc = [l:addr] (free_gc_v (dirent?, l), dirent @ l | ptr l) // end of [direntptr_gc] // // HX: [dirent_stream_vt_make_DIR] is reentrant // fun dirent_stream_vt_make_DIR {l_dir:addr} (pf: DIR @ l_dir | p: ptr l_dir): stream_vt (dirent) // end of [dirent_strean_vt_make_DIR] // // HX: [direntptr_stream_vt_make_DIR] is reentrant // fun direntptr_stream_vt_make_DIR {l_dir:addr} (pf: DIR @ l_dir | p: ptr l_dir): stream_vt (direntptr_gc) // end of [direntptr_stream_vt_make_DIR] (* ****** ****** *) (* end of [dirent.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/termios.sats0000664000175000017500000002370012223166162020040 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/termios.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef pid_t = $TYPES.pid_t (* ****** ****** *) sta NCCS: int // = 32? // abst@ype cc_t = $extype"ats_cc_type" castfn char_of_cc (x: cc_t):<> char castfn cc_of_char (x: char):<> cc_t // abst@ype tcflag_t = $extype"ats_tcflag_type" castfn uint_of_tcflag (x: tcflag_t):<> uint castfn tcflag_of_uint (x: uint):<> tcflag_t // abst@ype speed_t = $extype"ats_speed_type" castfn speed_of_uint (x: uint):<> speed_t castfn uint_of_speed (x: speed_t):<> uint // abst@ype termios_rest typedef termios_struct = $extype_struct "ats_termios_type" of { c_iflag= tcflag_t , c_oflag= tcflag_t , c_cflag= tcflag_t , c_lflag= tcflag_t , c_line= cc_t , c_cc= @[cc_t][NCCS] (* , c_ispeed= speed_t // not documented , c_ospeed= speed_t // not documented *) , _rest= undefined_t // unknown quantity } // end of [termios_struct] typedef termios = termios_struct (* ****** ****** *) (* ** c_cc characters *) macdef VINTR = $extval (cc_t, "VINTR") macdef VQUIT = $extval (cc_t, "VQUIT") macdef VERASE = $extval (cc_t, "VERASE") macdef VKILL = $extval (cc_t, "VKILL") macdef VEOF = $extval (cc_t, "VEOF") macdef VTIME = $extval (cc_t, "VTIME") macdef VMIN = $extval (cc_t, "VMIN") macdef VSWTC = $extval (cc_t, "VSWTC") macdef VSTART = $extval (cc_t, "VSTART") macdef VSTOP = $extval (cc_t, "VSTOP") macdef VSUSP = $extval (cc_t, "VSUSP") macdef VEOL = $extval (cc_t, "VEOL") macdef VREPRINT = $extval (cc_t, "VREPRINT") macdef VDISCARD = $extval (cc_t, "VDISCARD") macdef VWERASE = $extval (cc_t, "VWERASE") macdef VLNEXT = $extval (cc_t, "VLNEXT") macdef VEOL2 = $extval (cc_t, "VEOL2") (* ****** ****** *) (* ** c_iflag bits *) macdef IGNBRK = $extval (tcflag_t, "IGNBRK") macdef BRKINT = $extval (tcflag_t, "BRKINT") macdef IGNPAR = $extval (tcflag_t, "IGNPAR") macdef PARMRK = $extval (tcflag_t, "PARMRK") macdef INPCK = $extval (tcflag_t, "INPCK") macdef ISTRIP = $extval (tcflag_t, "ISTRIP") macdef INLCR = $extval (tcflag_t, "INLCR") macdef IGNCR = $extval (tcflag_t, "IGNCR") macdef ICRNL = $extval (tcflag_t, "ICRNL") macdef IUCLC = $extval (tcflag_t, "IUCLC") macdef IXON = $extval (tcflag_t, "IXON") macdef IXANY = $extval (tcflag_t, "IXANY") macdef IXOFF = $extval (tcflag_t, "IXOFF") macdef IMAXBEL = $extval (tcflag_t, "IMAXBEL") macdef IUTF8 = $extval (tcflag_t, "IUTF8") (* ****** ****** *) (* ** c_oflag bits *) macdef OPOST = $extval (tcflag_t, "OPOST") macdef OLCUC = $extval (tcflag_t, "OLCUC") macdef ONLCR = $extval (tcflag_t, "ONLCR") macdef OCRNL = $extval (tcflag_t, "OCRNL") macdef ONOCR = $extval (tcflag_t, "ONOCR") macdef ONLRET = $extval (tcflag_t, "ONLRET") macdef OFILL = $extval (tcflag_t, "OFILL") macdef OFDEL = $extval (tcflag_t, "OFDEL") macdef NLDLY = $extval (tcflag_t, "NLDLY") macdef NL0 = $extval (tcflag_t, "NL0") macdef NL1 = $extval (tcflag_t, "NL1") macdef CRDLY = $extval (tcflag_t, "CRDLY") macdef CR0 = $extval (tcflag_t, "CR0") macdef CR1 = $extval (tcflag_t, "CR1") macdef CR2 = $extval (tcflag_t, "CR2") macdef CR3 = $extval (tcflag_t, "CR3") macdef TABDLY = $extval (tcflag_t, "TABDLY") macdef TAB0 = $extval (tcflag_t, "TAB0") macdef TAB1 = $extval (tcflag_t, "TAB1") macdef TAB2 = $extval (tcflag_t, "TAB2") macdef TAB3 = $extval (tcflag_t, "TAB3") macdef BSDLY = $extval (tcflag_t, "BSDLY") macdef BS0 = $extval (tcflag_t, "BS0") macdef BS1 = $extval (tcflag_t, "BS1") macdef FFDLY = $extval (tcflag_t, "FFDLY") macdef FF0 = $extval (tcflag_t, "FF0") macdef FF1 = $extval (tcflag_t, "FF1") macdef VTDLY = $extval (tcflag_t, "VTDLY") macdef VT0 = $extval (tcflag_t, "VT0") macdef VT1 = $extval (tcflag_t, "VT1") macdef XTABS = $extval (tcflag_t, "XTABS") (* ****** ****** *) (* ** c_cflag bit meaning *) macdef CBAUD = $extval (tcflag_t, "CBAUD") macdef B0 = $extval (tcflag_t, "B0") macdef B50 = $extval (tcflag_t, "B50") macdef B75 = $extval (tcflag_t, "B75") macdef B110 = $extval (tcflag_t, "B110") macdef B134 = $extval (tcflag_t, "B134") macdef B150 = $extval (tcflag_t, "B150") macdef B200 = $extval (tcflag_t, "B200") macdef B300 = $extval (tcflag_t, "B300") macdef B600 = $extval (tcflag_t, "B600") macdef B1200 = $extval (tcflag_t, "B1200") macdef B1800 = $extval (tcflag_t, "B1800") macdef B2400 = $extval (tcflag_t, "B2400") macdef B4800 = $extval (tcflag_t, "B4800") macdef B9600 = $extval (tcflag_t, "B9600") macdef B19200 = $extval (tcflag_t, "B19200") macdef B38400 = $extval (tcflag_t, "B38400") macdef EXTA = $extval (tcflag_t, "EXTA") macdef EXTB = $extval (tcflag_t, "EXTB") macdef CSIZE = $extval (tcflag_t, "CSIZE") macdef CS5 = $extval (tcflag_t, "CS5") macdef CS6 = $extval (tcflag_t, "CS6") macdef CS7 = $extval (tcflag_t, "CS7") macdef CS8 = $extval (tcflag_t, "CS8") macdef CSTOPB = $extval (tcflag_t, "CSTOPB") macdef CREAD = $extval (tcflag_t, "CREAD") macdef PARENB = $extval (tcflag_t, "PARENB") macdef PARODD = $extval (tcflag_t, "PARODD") macdef HUPCL = $extval (tcflag_t, "HUPCL") macdef CLOCAL = $extval (tcflag_t, "CLOCAL") macdef CBAUDEX = $extval (tcflag_t, "CBAUDEX") macdef B57600 = $extval (tcflag_t, "B57600") macdef B115200 = $extval (tcflag_t, "B115200") macdef B230400 = $extval (tcflag_t, "B230400") macdef B460800 = $extval (tcflag_t, "B460800") macdef B500000 = $extval (tcflag_t, "B500000") macdef B576000 = $extval (tcflag_t, "B576000") macdef B921600 = $extval (tcflag_t, "B921600") macdef B1000000 = $extval (tcflag_t, "B1000000") macdef B1152000 = $extval (tcflag_t, "B1152000") macdef B1500000 = $extval (tcflag_t, "B1500000") macdef B2000000 = $extval (tcflag_t, "B2000000") macdef B2500000 = $extval (tcflag_t, "B2500000") macdef B3000000 = $extval (tcflag_t, "B3000000") macdef B3500000 = $extval (tcflag_t, "B3500000") macdef B4000000 = $extval (tcflag_t, "B4000000") macdef __MAX_BAUD = $extval (tcflag_t, "__MAX_BAUD") macdef CIBAUD = $extval (tcflag_t, "CIBAUD") macdef CMSPAR = $extval (tcflag_t, "CMSPAR") macdef CRTSCTS = $extval (tcflag_t, "CRTSCTS") (* ****** ****** *) (* ** c_lflag bits *) macdef ISIG = $extval (tcflag_t, "ISIG") macdef ICANON = $extval (tcflag_t, "ICANON") macdef XCASE = $extval (tcflag_t, "XCASE") macdef ECHO = $extval (tcflag_t, "ECHO") macdef ECHOE = $extval (tcflag_t, "ECHOE") macdef ECHOK = $extval (tcflag_t, "ECHOK") macdef ECHONL = $extval (tcflag_t, "ECHONL") macdef NOFLSH = $extval (tcflag_t, "NOFLSH") macdef TOSTOP = $extval (tcflag_t, "TOSTOP") macdef ECHOCTL = $extval (tcflag_t, "ECHOCTL") macdef ECHOPRT = $extval (tcflag_t, "ECHOPRT") macdef ECHOKE = $extval (tcflag_t, "ECHOKE") macdef FLUSHO = $extval (tcflag_t, "FLUSHO") macdef PENDIN = $extval (tcflag_t, "PENDIN") macdef IEXTEN = $extval (tcflag_t, "IEXTEN") (* ****** ****** *) (* ** tcflow() and TCXONC use these *) macdef TCOOFF = $extval (int, "TCOOFF") macdef TCOON = $extval (int, "TCOON") macdef TCIOFF = $extval (int, "TCIOFF") macdef TCION = $extval (int, "TCION") (* ** tcflush() and TCFLSH use these *) macdef TCIFLUSH = $extval (int, "TCIFLUSH") macdef TCOFLUSH = $extval (int, "TCOFLUSH") macdef TCIOFLUSH = $extval (int, "TCIOFLUSH") (* ** tcsetattr uses these *) macdef TCSANOW = $extval (int, "TCSANOW") macdef TCSADRAIN = $extval (int, "TCSADRAIN") macdef TCSAFLUSH = $extval (int, "TCSAFLUSH") (* ****** ****** *) fun tcgetattr // 0/-1 : succ/fail // set errno {fd:nat} ( fd: int, tm: &termios ) : int = "mac#atslib_tcgetattr" // end of [tcgetattr] fun tcsetattr // 0/-1 : succ/fail // set errno {fd:nat} ( fd: int fd, actions: int, tm: &termios ) : int = "mac#atslib_tcsetattr" // end of [tcsetattr] (* ****** ****** *) fun cfgetispeed (tm: &termios):<> speed_t = "mac#atslib_cfgetispeed" // no error fun cfsetispeed (tm: &termios, x: speed_t):<> int = "mac#atslib_cfsetispeed" // 0/-1: succ/fail fun cfgetospeed (tm: &termios):<> speed_t = "mac#atslib_cfgetospeed"// no error fun cfsetospeed (tm: &termios, x: speed_t):<> int = "mac#atslib_cfsetospeed"// 0/-1 : succ/fail (* ****** ****** *) fun tcflow {fd:nat} ( fd: int fd, action: int ) : int = "mac#atslib_tcflow" // 0/-1 : succ/fail // end of [fun] fun tcdrain {fd:nat} (fd: int fd): int = "mac#atslib_tcdrain" // 0/-1 : succ/fail // end of [fun] fun tcflush {fd:nat} ( fd: int fd, queue: int ) : int = "mac#atslib_tcflush" // 0/-1 : succ/fail // end of [tcflush] fun tcsendbreak {fd:nat} ( fd: int fd, dura: int ) : int = "mac#atslib_tcsendbreak" // 0/-1 : succ/fail // end of [fun] (* ****** ****** *) // // HX-2010-09-27: only available on SUS systems; not on FreeBSD // fun tcgetsid {fd:nat} (fd: int fd): pid_t = "mac#atslib_tcgetsid" // -1 is returned on error // end of [tcgetsid] (* ****** ****** *) (* end of [termios.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/errno.sats0000664000175000017500000001321212223166162017500 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/errno.cats" %} // end of [%{#] (* ****** ****** *) abst@ype errno_t = int castfn int_of_errno (e: errno_t):<> [i:nat] int i overload int_of with int_of_errno castfn errno_of_int {i:nat} (i: int i):<> errno_t (* ****** ****** *) // macdef ENONE = $extval (errno_t, "ENONE") // = 0 // macdef E2BIG = $extval (errno_t, "E2BIG") macdef EACCES = $extval (errno_t, "EACCES") macdef EADDRINUSE = $extval (errno_t, "EADDRINUSE") macdef EADDRNOTAVAIL = $extval (errno_t, "EADDRNOTAVAIL") macdef EAGAIN = $extval (errno_t, "EAGAIN") macdef EALREADY = $extval (errno_t, "EALREADY") macdef EBADF = $extval (errno_t, "EBADF") macdef EBADMSG = $extval (errno_t, "EBADMSG") macdef ECANCELED = $extval (errno_t, "ECANCELED") macdef ECHILD = $extval (errno_t, "ECHILD") macdef ECONNABORTED = $extval (errno_t, "ECONNABORTED") macdef ECONNREFUSED = $extval (errno_t, "ECONNREFUSED") macdef ECONNRESET = $extval (errno_t, "ECONNRESET") macdef EDEADLK = $extval (errno_t, "EDEADLK") macdef EDESTADDRREQ = $extval (errno_t, "EDESTADDRREQ") macdef EDOM = $extval (errno_t, "EDOM") macdef EEXIST = $extval (errno_t, "EEXIST") macdef EFAULT = $extval (errno_t, "EFAULT") macdef EFBIG = $extval (errno_t, "EFBIG") macdef EHOSTUNREACH = $extval (errno_t, "EHOSTUNREACH") macdef EIDRM = $extval (errno_t, "EIDRM") macdef EILSEQ = $extval (errno_t, "EILSEQ") macdef EINPROGRESS = $extval (errno_t, "EINPROGRESS") macdef EINTR = $extval (errno_t, "EINTR") macdef EINVAL = $extval (errno_t, "EINVAL") macdef EIO = $extval (errno_t, "EIO") macdef EISCONN = $extval (errno_t, "EISCONN") macdef EISDIR = $extval (errno_t, "EISDIR") macdef ELOOP = $extval (errno_t, "ELOOP") macdef EMFILE = $extval (errno_t, "EMFILE") macdef EMLINK = $extval (errno_t, "EMLINK") macdef EMSGSIZE = $extval (errno_t, "EMSGSIZE") macdef ENAMETOOLONG = $extval (errno_t, "ENAMETOOLONG") macdef ENETDOWN = $extval (errno_t, "ENETDOWN") macdef ENETRESET = $extval (errno_t, "ENETRESET") macdef ENETUNREACH = $extval (errno_t, "ENETUNREACH") macdef ENFILE = $extval (errno_t, "ENFILE") macdef ENOBUFS = $extval (errno_t, "ENOBUFS") macdef ENODATA = $extval (errno_t, "ENODATA") macdef ENODEV = $extval (errno_t, "ENODEV") macdef ENOENT = $extval (errno_t, "ENOENT") macdef ENOEXEC = $extval (errno_t, "ENOEXEC") macdef ENOLCK = $extval (errno_t, "ENOLCK") macdef ENOLINK = $extval (errno_t, "ENOLINK") macdef ENOMEM = $extval (errno_t, "ENOMEM") macdef ENOMSG = $extval (errno_t, "ENOMSG") macdef ENOPROTOOPT = $extval (errno_t, "ENOPROTOOPT") macdef ENOSPC = $extval (errno_t, "ENOSPC") macdef ENOSR = $extval (errno_t, "ENOSR") macdef ENOSTR = $extval (errno_t, "ENOSTR") macdef ENOSYS = $extval (errno_t, "ENOSYS") macdef ENOTCONN = $extval (errno_t, "ENOTCONN") macdef ENOTDIR = $extval (errno_t, "ENOTDIR") macdef ENOTEMPTY = $extval (errno_t, "ENOTEMPTY") macdef ENOTSOCK = $extval (errno_t, "ENOTSOCK") macdef ENOTSUP = $extval (errno_t, "ENOTSUP") macdef ENOTTY = $extval (errno_t, "ENOTTY") macdef ENXIO = $extval (errno_t, "ENXIO") macdef EOPNOTSUPP = $extval (errno_t, "EOPNOTSUPP") macdef EOVERFLOW = $extval (errno_t, "EOVERFLOW") macdef EPERM = $extval (errno_t, "EPERM") macdef EPIPE = $extval (errno_t, "EPIPE") macdef EPROTO = $extval (errno_t, "EPROTO") macdef EPROTONOSUPPORT = $extval (errno_t, "EPROTONOSUPPORT") macdef EPROTOTYPE = $extval (errno_t, "EPROTOTYPE") macdef ERANGE = $extval (errno_t, "ERANGE") macdef EROFS = $extval (errno_t, "EROFS") macdef ESPIPE = $extval (errno_t, "ESPIPE") macdef ESRCH = $extval (errno_t, "ESRCH") macdef ETIME = $extval (errno_t, "ETIME") macdef ETIMEDOUT = $extval (errno_t, "ETIMEDOUT") macdef ETXTBSY = $extval (errno_t, "ETXTBSY") macdef EWOULDBLOCK = $extval (errno_t, "EWOULDBLOCK") macdef EXDEV = $extval (errno_t, "EXDEV") (* ****** ****** *) // // HX: due to some special treatment for [errno] // fun errno_get ():<> errno_t = "atslib_errno_get" fun errno_set (n: errno_t):<> void = "atslib_errno_set" fun errno_reset ():<> void = "atslib_errno_reset" (* ****** ****** *) fun eq_errno_errno (n1: errno_t, n2: errno_t):<> bool = "atslib_eq_errno_errno" overload = with eq_errno_errno fun neq_errno_errno (n1: errno_t, n2: errno_t):<> bool = "atslib_neq_errno_errno" overload <> with neq_errno_errno (* ****** ****** *) (* end of [errno.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/stdarg.sats0000664000175000017500000000527612223166162017652 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/stdarg.cats" %} // end of [%{#] (* ****** ****** *) (* // // HX: this is declared in $ATSHOME/prelude/basics_sta.sats // absviewt@ype va_list (ts: types) = $extype"ats_va_list_viewtype" *) absviewt@ype va_list1 (t: t@ype, ts: types) = va_list (ts) (* ****** ****** *) typedef va_arg_type (t:t@ype) = {ts:types} (&va_list1 (t, ts) >> va_list ts) -<> t // end of [va_arg_type] fun{t:t@ype} va_arg : va_arg_type (t) fun va_arg_int : va_arg_type (int) = "atslib_va_arg_int" fun va_arg_ptr : va_arg_type (ptr) = "atslib_va_arg_ptr" fun va_arg_bool : va_arg_type (bool) = "atslib_va_arg_bool" fun va_arg_char : va_arg_type (char) = "atslib_va_arg_char" fun va_arg_string : va_arg_type (string) = "atslib_va_arg_ptr" (* ****** ****** *) (* fun va_start ... // this one is built-in *) fun va_end (ap: &va_list >> va_list?):<> void = "atslib_va_end" (* ****** ****** *) praxi va_clear {ts:types} (arg: &va_list (ts) >> va_list):<> void // end of [va_clear] fun va_copy {ts:types} (dst: &va_list? >> va_list ts, src: va_list ts):<> void = "atslib_va_copy" // end of [va_copy] (* ****** ****** *) (* HX-2010-10-01: the following functions are in libc/printf vprintf vfprintf vsnprint *) (* ****** ****** *) (* end of [stdarg.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/ctype.sats0000664000175000017500000000433212223166162017502 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/ctype.cats" %} // end of [%{#] (* ****** ****** *) fun isalnum (c: int):<> int = "mac#atslib_isalnum" fun isalpha (c: int):<> int = "mac#atslib_isalpha" fun isascii (c: int):<> int = "mac#atslib_isascii" fun isblank (c: int):<> int = "mac#atslib_isblank" fun iscntrl (c: int):<> int = "mac#atslib_iscntrl" fun isdigit (c: int):<> int = "mac#atslib_isdigit" fun isgraph (c: int):<> int = "mac#atslib_isgraph" fun islower (c: int):<> int = "mac#atslib_islower" fun isprint (c: int):<> int = "mac#atslib_isprint" fun ispunct (c: int):<> int = "mac#atslib_ispunct" fun isspace (c: int):<> int = "mac#atslib_isspace" fun isupper (c: int):<> int = "mac#atslib_isupper" fun isxdigit (c: int):<> int = "mac#atslib_isxdigit" (* ****** ****** *) (* end of [ctype.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/unistd_sysconf.sats0000664000175000017500000004065412223166162021437 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/unistd_sysconf.cats" %} // end of [%{#] (* ****** ****** *) typedef sysconfname = int (* ****** ****** *) macdef _SC_ARG_MAX = $extval (sysconfname, "_SC_ARG_MAX") macdef _SC_CHILD_MAX = $extval (sysconfname, "_SC_CHILD_MAX") macdef _SC_CLK_TCK = $extval (sysconfname, "_SC_CLK_TCK") macdef _SC_NGROUPS_MAX = $extval (sysconfname, "_SC_NGROUPS_MAX") macdef _SC_OPEN_MAX = $extval (sysconfname, "_SC_OPEN_MAX") macdef _SC_STREAM_MAX = $extval (sysconfname, "_SC_STREAM_MAX") macdef _SC_TZNAME_MAX = $extval (sysconfname, "_SC_TZNAME_MAX") macdef _SC_JOB_CONTROL = $extval (sysconfname, "_SC_JOB_CONTROL") macdef _SC_SAVED_IDS = $extval (sysconfname, "_SC_SAVED_IDS") macdef _SC_REALTIME_SIGNALS = $extval (sysconfname, "_SC_REALTIME_SIGNALS") macdef _SC_PRIORITY_SCHEDULING = $extval (sysconfname, "_SC_PRIORITY_SCHEDULING") macdef _SC_TIMERS = $extval (sysconfname, "_SC_TIMERS") macdef _SC_ASYNCHRONOUS_IO = $extval (sysconfname, "_SC_ASYNCHRONOUS_IO") macdef _SC_PRIORITIZED_IO = $extval (sysconfname, "_SC_PRIORITIZED_IO") macdef _SC_SYNCHRONIZED_IO = $extval (sysconfname, "_SC_SYNCHRONIZED_IO") macdef _SC_FSYNC = $extval (sysconfname, "_SC_FSYNC") macdef _SC_MAPPED_FILES = $extval (sysconfname, "_SC_MAPPED_FILES") macdef _SC_MEMLOCK = $extval (sysconfname, "_SC_MEMLOCK") macdef _SC_MEMLOCK_RANGE = $extval (sysconfname, "_SC_MEMLOCK_RANGE") macdef _SC_MEMORY_PROTECTION = $extval (sysconfname, "_SC_MEMORY_PROTECTION") macdef _SC_MESSAGE_PASSING = $extval (sysconfname, "_SC_MESSAGE_PASSING") macdef _SC_SEMAPHORES = $extval (sysconfname, "_SC_SEMAPHORES") macdef _SC_SHARED_MEMORY_OBJECTS = $extval (sysconfname, "_SC_SHARED_MEMORY_OBJECTS") macdef _SC_AIO_LISTIO_MAX = $extval (sysconfname, "_SC_AIO_LISTIO_MAX") macdef _SC_AIO_MAX = $extval (sysconfname, "_SC_AIO_MAX") macdef _SC_AIO_PRIO_DELTA_MAX = $extval (sysconfname, "_SC_AIO_PRIO_DELTA_MAX") macdef _SC_DELAYTIMER_MAX = $extval (sysconfname, "_SC_DELAYTIMER_MAX") macdef _SC_MQ_OPEN_MAX = $extval (sysconfname, "_SC_MQ_OPEN_MAX") macdef _SC_MQ_PRIO_MAX = $extval (sysconfname, "_SC_MQ_PRIO_MAX") macdef _SC_VERSION = $extval (sysconfname, "_SC_VERSION") macdef _SC_PAGESIZE = $extval (sysconfname, "_SC_PAGESIZE") macdef _SC_PAGE_SIZE = $extval (sysconfname, "_SC_PAGE_SIZE") macdef _SC_RTSIG_MAX = $extval (sysconfname, "_SC_RTSIG_MAX") macdef _SC_SEM_NSEMS_MAX = $extval (sysconfname, "_SC_SEM_NSEMS_MAX") macdef _SC_SEM_VALUE_MAX = $extval (sysconfname, "_SC_SEM_VALUE_MAX") macdef _SC_SIGQUEUE_MAX = $extval (sysconfname, "_SC_SIGQUEUE_MAX") macdef _SC_TIMER_MAX = $extval (sysconfname, "_SC_TIMER_MAX") // macdef _SC_BC_BASE_MAX = $extval (sysconfname, "_SC_BC_BASE_MAX") macdef _SC_BC_DIM_MAX = $extval (sysconfname, "_SC_BC_DIM_MAX") macdef _SC_BC_SCALE_MAX = $extval (sysconfname, "_SC_BC_SCALE_MAX") macdef _SC_BC_STRING_MAX = $extval (sysconfname, "_SC_BC_STRING_MAX") macdef _SC_COLL_WEIGHTS_MAX = $extval (sysconfname, "_SC_COLL_WEIGHTS_MAX") macdef _SC_EQUIV_CLASS_MAX = $extval (sysconfname, "_SC_EQUIV_CLASS_MAX") macdef _SC_EXPR_NEST_MAX = $extval (sysconfname, "_SC_EXPR_NEST_MAX") macdef _SC_LINE_MAX = $extval (sysconfname, "_SC_LINE_MAX") macdef _SC_RE_DUP_MAX = $extval (sysconfname, "_SC_RE_DUP_MAX") macdef _SC_CHARCLASS_NAME_MAX = $extval (sysconfname, "_SC_CHARCLASS_NAME_MAX") // macdef _SC_2_VERSION = $extval (sysconfname, "_SC_2_VERSION") macdef _SC_2_C_BIND = $extval (sysconfname, "_SC_2_C_BIND") macdef _SC_2_C_DEV = $extval (sysconfname, "_SC_2_C_DEV") macdef _SC_2_FORT_DEV = $extval (sysconfname, "_SC_2_FORT_DEV") macdef _SC_2_FORT_RUN = $extval (sysconfname, "_SC_2_FORT_RUN") macdef _SC_2_SW_DEV = $extval (sysconfname, "_SC_2_SW_DEV") macdef _SC_2_LOCALEDEF = $extval (sysconfname, "_SC_2_LOCALEDEF") // macdef _SC_PII = $extval (sysconfname, "_SC_PII") macdef _SC_PII_XTI = $extval (sysconfname, "_SC_PII_XTI") macdef _SC_PII_SOCKET = $extval (sysconfname, "_SC_PII_SOCKET") macdef _SC_PII_INTERNET = $extval (sysconfname, "_SC_PII_INTERNET") macdef _SC_PII_OSI = $extval (sysconfname, "_SC_PII_OSI") macdef _SC_POLL = $extval (sysconfname, "_SC_POLL") macdef _SC_SELECT = $extval (sysconfname, "_SC_SELECT") macdef _SC_UIO_MAXIOV = $extval (sysconfname, "_SC_UIO_MAXIOV") macdef _SC_IOV_MAX = _SC_UIO_MAXIOV = $extval (sysconfname, "_SC_IOV_MAX = _SC_UIO_MAXIOV") macdef _SC_PII_INTERNET_STREAM = $extval (sysconfname, "_SC_PII_INTERNET_STREAM") macdef _SC_PII_INTERNET_DGRAM = $extval (sysconfname, "_SC_PII_INTERNET_DGRAM") macdef _SC_PII_OSI_COTS = $extval (sysconfname, "_SC_PII_OSI_COTS") macdef _SC_PII_OSI_CLTS = $extval (sysconfname, "_SC_PII_OSI_CLTS") macdef _SC_PII_OSI_M = $extval (sysconfname, "_SC_PII_OSI_M") macdef _SC_T_IOV_MAX = $extval (sysconfname, "_SC_T_IOV_MAX") // macdef _SC_THREADS = $extval (sysconfname, "_SC_THREADS") macdef _SC_THREAD_SAFE_FUNCTIONS = $extval (sysconfname, "_SC_THREAD_SAFE_FUNCTIONS") macdef _SC_GETGR_R_SIZE_MAX = $extval (sysconfname, "_SC_GETGR_R_SIZE_MAX") macdef _SC_GETPW_R_SIZE_MAX = $extval (sysconfname, "_SC_GETPW_R_SIZE_MAX") macdef _SC_LOGIN_NAME_MAX = $extval (sysconfname, "_SC_LOGIN_NAME_MAX") macdef _SC_TTY_NAME_MAX = $extval (sysconfname, "_SC_TTY_NAME_MAX") macdef _SC_THREAD_DESTRUCTOR_ITERATIONS = $extval (sysconfname, "_SC_THREAD_DESTRUCTOR_ITERATIONS") macdef _SC_THREAD_KEYS_MAX = $extval (sysconfname, "_SC_THREAD_KEYS_MAX") macdef _SC_THREAD_STACK_MIN = $extval (sysconfname, "_SC_THREAD_STACK_MIN") macdef _SC_THREAD_THREADS_MAX = $extval (sysconfname, "_SC_THREAD_THREADS_MAX") macdef _SC_THREAD_ATTR_STACKADDR = $extval (sysconfname, "_SC_THREAD_ATTR_STACKADDR") macdef _SC_THREAD_ATTR_STACKSIZE = $extval (sysconfname, "_SC_THREAD_ATTR_STACKSIZE") macdef _SC_THREAD_PRIORITY_SCHEDULING = $extval (sysconfname, "_SC_THREAD_PRIORITY_SCHEDULING") macdef _SC_THREAD_PRIO_INHERIT = $extval (sysconfname, "_SC_THREAD_PRIO_INHERIT") macdef _SC_THREAD_PRIO_PROTECT = $extval (sysconfname, "_SC_THREAD_PRIO_PROTECT") macdef _SC_THREAD_PROCESS_SHARED = $extval (sysconfname, "_SC_THREAD_PROCESS_SHARED") // macdef _SC_NPROCESSORS_CONF = $extval (sysconfname, "_SC_NPROCESSORS_CONF") macdef _SC_NPROCESSORS_ONLN = $extval (sysconfname, "_SC_NPROCESSORS_ONLN") macdef _SC_PHYS_PAGES = $extval (sysconfname, "_SC_PHYS_PAGES") macdef _SC_AVPHYS_PAGES = $extval (sysconfname, "_SC_AVPHYS_PAGES") macdef _SC_ATEXIT_MAX = $extval (sysconfname, "_SC_ATEXIT_MAX") macdef _SC_PASS_MAX = $extval (sysconfname, "_SC_PASS_MAX") // macdef _SC_XOPEN_VERSION = $extval (sysconfname, "_SC_XOPEN_VERSION") macdef _SC_XOPEN_XCU_VERSION = $extval (sysconfname, "_SC_XOPEN_XCU_VERSION") macdef _SC_XOPEN_UNIX = $extval (sysconfname, "_SC_XOPEN_UNIX") macdef _SC_XOPEN_CRYPT = $extval (sysconfname, "_SC_XOPEN_CRYPT") macdef _SC_XOPEN_ENH_I18N = $extval (sysconfname, "_SC_XOPEN_ENH_I18N") macdef _SC_XOPEN_SHM = $extval (sysconfname, "_SC_XOPEN_SHM") // macdef _SC_2_CHAR_TERM = $extval (sysconfname, "_SC_2_CHAR_TERM") macdef _SC_2_C_VERSION = $extval (sysconfname, "_SC_2_C_VERSION") macdef _SC_2_UPE = $extval (sysconfname, "_SC_2_UPE") // macdef _SC_XOPEN_XPG2 = $extval (sysconfname, "_SC_XOPEN_XPG2") macdef _SC_XOPEN_XPG3 = $extval (sysconfname, "_SC_XOPEN_XPG3") macdef _SC_XOPEN_XPG4 = $extval (sysconfname, "_SC_XOPEN_XPG4") // macdef _SC_CHAR_BIT = $extval (sysconfname, "_SC_CHAR_BIT") macdef _SC_CHAR_MAX = $extval (sysconfname, "_SC_CHAR_MAX") macdef _SC_CHAR_MIN = $extval (sysconfname, "_SC_CHAR_MIN") macdef _SC_INT_MAX = $extval (sysconfname, "_SC_INT_MAX") macdef _SC_INT_MIN = $extval (sysconfname, "_SC_INT_MIN") macdef _SC_LONG_BIT = $extval (sysconfname, "_SC_LONG_BIT") macdef _SC_WORD_BIT = $extval (sysconfname, "_SC_WORD_BIT") macdef _SC_MB_LEN_MAX = $extval (sysconfname, "_SC_MB_LEN_MAX") macdef _SC_NZERO = $extval (sysconfname, "_SC_NZERO") macdef _SC_SSIZE_MAX = $extval (sysconfname, "_SC_SSIZE_MAX") macdef _SC_SCHAR_MAX = $extval (sysconfname, "_SC_SCHAR_MAX") macdef _SC_SCHAR_MIN = $extval (sysconfname, "_SC_SCHAR_MIN") macdef _SC_SHRT_MAX = $extval (sysconfname, "_SC_SHRT_MAX") macdef _SC_SHRT_MIN = $extval (sysconfname, "_SC_SHRT_MIN") macdef _SC_UCHAR_MAX = $extval (sysconfname, "_SC_UCHAR_MAX") macdef _SC_UINT_MAX = $extval (sysconfname, "_SC_UINT_MAX") macdef _SC_ULONG_MAX = $extval (sysconfname, "_SC_ULONG_MAX") macdef _SC_USHRT_MAX = $extval (sysconfname, "_SC_USHRT_MAX") // macdef _SC_NL_ARGMAX = $extval (sysconfname, "_SC_NL_ARGMAX") macdef _SC_NL_LANGMAX = $extval (sysconfname, "_SC_NL_LANGMAX") macdef _SC_NL_MSGMAX = $extval (sysconfname, "_SC_NL_MSGMAX") macdef _SC_NL_NMAX = $extval (sysconfname, "_SC_NL_NMAX") macdef _SC_NL_SETMAX = $extval (sysconfname, "_SC_NL_SETMAX") macdef _SC_NL_TEXTMAX = $extval (sysconfname, "_SC_NL_TEXTMAX") // macdef _SC_XBS5_ILP32_OFF32 = $extval (sysconfname, "_SC_XBS5_ILP32_OFF32") macdef _SC_XBS5_ILP32_OFFBIG = $extval (sysconfname, "_SC_XBS5_ILP32_OFFBIG") macdef _SC_XBS5_LP64_OFF64 = $extval (sysconfname, "_SC_XBS5_LP64_OFF64") macdef _SC_XBS5_LPBIG_OFFBIG = $extval (sysconfname, "_SC_XBS5_LPBIG_OFFBIG") // macdef _SC_XOPEN_LEGACY = $extval (sysconfname, "_SC_XOPEN_LEGACY") macdef _SC_XOPEN_REALTIME = $extval (sysconfname, "_SC_XOPEN_REALTIME") macdef _SC_XOPEN_REALTIME_THREADS = $extval (sysconfname, "_SC_XOPEN_REALTIME_THREADS") // macdef _SC_ADVISORY_INFO = $extval (sysconfname, "_SC_ADVISORY_INFO") macdef _SC_BARRIERS = $extval (sysconfname, "_SC_BARRIERS") macdef _SC_BASE = $extval (sysconfname, "_SC_BASE") macdef _SC_C_LANG_SUPPORT = $extval (sysconfname, "_SC_C_LANG_SUPPORT") macdef _SC_C_LANG_SUPPORT_R = $extval (sysconfname, "_SC_C_LANG_SUPPORT_R") macdef _SC_CLOCK_SELECTION = $extval (sysconfname, "_SC_CLOCK_SELECTION") macdef _SC_CPUTIME = $extval (sysconfname, "_SC_CPUTIME") macdef _SC_THREAD_CPUTIME = $extval (sysconfname, "_SC_THREAD_CPUTIME") macdef _SC_DEVICE_IO = $extval (sysconfname, "_SC_DEVICE_IO") macdef _SC_DEVICE_SPECIFIC = $extval (sysconfname, "_SC_DEVICE_SPECIFIC") macdef _SC_DEVICE_SPECIFIC_R = $extval (sysconfname, "_SC_DEVICE_SPECIFIC_R") macdef _SC_FD_MGMT = $extval (sysconfname, "_SC_FD_MGMT") macdef _SC_FIFO = $extval (sysconfname, "_SC_FIFO") macdef _SC_PIPE = $extval (sysconfname, "_SC_PIPE") macdef _SC_FILE_ATTRIBUTES = $extval (sysconfname, "_SC_FILE_ATTRIBUTES") macdef _SC_FILE_LOCKING = $extval (sysconfname, "_SC_FILE_LOCKING") macdef _SC_FILE_SYSTEM = $extval (sysconfname, "_SC_FILE_SYSTEM") macdef _SC_MONOTONIC_CLOCK = $extval (sysconfname, "_SC_MONOTONIC_CLOCK") macdef _SC_MULTI_PROCESS = $extval (sysconfname, "_SC_MULTI_PROCESS") macdef _SC_SINGLE_PROCESS = $extval (sysconfname, "_SC_SINGLE_PROCESS") macdef _SC_NETWORKING = $extval (sysconfname, "_SC_NETWORKING") macdef _SC_READER_WRITER_LOCKS = $extval (sysconfname, "_SC_READER_WRITER_LOCKS") macdef _SC_SPIN_LOCKS = $extval (sysconfname, "_SC_SPIN_LOCKS") macdef _SC_REGEXP = $extval (sysconfname, "_SC_REGEXP") macdef _SC_REGEX_VERSION = $extval (sysconfname, "_SC_REGEX_VERSION") macdef _SC_SHELL = $extval (sysconfname, "_SC_SHELL") macdef _SC_SIGNALS = $extval (sysconfname, "_SC_SIGNALS") macdef _SC_SPAWN = $extval (sysconfname, "_SC_SPAWN") macdef _SC_SPORADIC_SERVER = $extval (sysconfname, "_SC_SPORADIC_SERVER") macdef _SC_THREAD_SPORADIC_SERVER = $extval (sysconfname, "_SC_THREAD_SPORADIC_SERVER") macdef _SC_SYSTEM_DATABASE = $extval (sysconfname, "_SC_SYSTEM_DATABASE") macdef _SC_SYSTEM_DATABASE_R = $extval (sysconfname, "_SC_SYSTEM_DATABASE_R") macdef _SC_TIMEOUTS = $extval (sysconfname, "_SC_TIMEOUTS") macdef _SC_TYPED_MEMORY_OBJECTS = $extval (sysconfname, "_SC_TYPED_MEMORY_OBJECTS") macdef _SC_USER_GROUPS = $extval (sysconfname, "_SC_USER_GROUPS") macdef _SC_USER_GROUPS_R = $extval (sysconfname, "_SC_USER_GROUPS_R") macdef _SC_2_PBS = $extval (sysconfname, "_SC_2_PBS") macdef _SC_2_PBS_ACCOUNTING = $extval (sysconfname, "_SC_2_PBS_ACCOUNTING") macdef _SC_2_PBS_LOCATE = $extval (sysconfname, "_SC_2_PBS_LOCATE") macdef _SC_2_PBS_MESSAGE = $extval (sysconfname, "_SC_2_PBS_MESSAGE") macdef _SC_2_PBS_TRACK = $extval (sysconfname, "_SC_2_PBS_TRACK") macdef _SC_SYMLOOP_MAX = $extval (sysconfname, "_SC_SYMLOOP_MAX") macdef _SC_STREAMS = $extval (sysconfname, "_SC_STREAMS") macdef _SC_2_PBS_CHECKPOINT = $extval (sysconfname, "_SC_2_PBS_CHECKPOINT") // macdef _SC_V6_ILP32_OFF32 = $extval (sysconfname, "_SC_V6_ILP32_OFF32") macdef _SC_V6_ILP32_OFFBIG = $extval (sysconfname, "_SC_V6_ILP32_OFFBIG") macdef _SC_V6_LP64_OFF64 = $extval (sysconfname, "_SC_V6_LP64_OFF64") macdef _SC_V6_LPBIG_OFFBIG = $extval (sysconfname, "_SC_V6_LPBIG_OFFBIG") // macdef _SC_HOST_NAME_MAX = $extval (sysconfname, "_SC_HOST_NAME_MAX") macdef _SC_TRACE = $extval (sysconfname, "_SC_TRACE") macdef _SC_TRACE_EVENT_FILTER = $extval (sysconfname, "_SC_TRACE_EVENT_FILTER") macdef _SC_TRACE_INHERIT = $extval (sysconfname, "_SC_TRACE_INHERIT") macdef _SC_TRACE_LOG = $extval (sysconfname, "_SC_TRACE_LOG") // macdef _SC_LEVEL1_ICACHE_SIZE = $extval (sysconfname, "_SC_LEVEL1_ICACHE_SIZE") macdef _SC_LEVEL1_ICACHE_ASSOC = $extval (sysconfname, "_SC_LEVEL1_ICACHE_ASSOC") macdef _SC_LEVEL1_ICACHE_LINESIZE = $extval (sysconfname, "_SC_LEVEL1_ICACHE_LINESIZE") macdef _SC_LEVEL1_DCACHE_SIZE = $extval (sysconfname, "_SC_LEVEL1_DCACHE_SIZE") macdef _SC_LEVEL1_DCACHE_ASSOC = $extval (sysconfname, "_SC_LEVEL1_DCACHE_ASSOC") macdef _SC_LEVEL1_DCACHE_LINESIZE = $extval (sysconfname, "_SC_LEVEL1_DCACHE_LINESIZE") macdef _SC_LEVEL2_CACHE_SIZE = $extval (sysconfname, "_SC_LEVEL2_CACHE_SIZE") macdef _SC_LEVEL2_CACHE_ASSOC = $extval (sysconfname, "_SC_LEVEL2_CACHE_ASSOC") macdef _SC_LEVEL2_CACHE_LINESIZE = $extval (sysconfname, "_SC_LEVEL2_CACHE_LINESIZE") macdef _SC_LEVEL3_CACHE_SIZE = $extval (sysconfname, "_SC_LEVEL3_CACHE_SIZE") macdef _SC_LEVEL3_CACHE_ASSOC = $extval (sysconfname, "_SC_LEVEL3_CACHE_ASSOC") macdef _SC_LEVEL3_CACHE_LINESIZE = $extval (sysconfname, "_SC_LEVEL3_CACHE_LINESIZE") macdef _SC_LEVEL4_CACHE_SIZE = $extval (sysconfname, "_SC_LEVEL4_CACHE_SIZE") macdef _SC_LEVEL4_CACHE_ASSOC = $extval (sysconfname, "_SC_LEVEL4_CACHE_ASSOC") macdef _SC_LEVEL4_CACHE_LINESIZE = $extval (sysconfname, "_SC_LEVEL4_CACHE_LINESIZE") // macdef _SC_IPV6 = $extval (sysconfname, "_SC_IPV6") macdef _SC_RAW_SOCKETS = $extval (sysconfname, "_SC_RAW_SOCKETS") // macdef _SC_V7_ILP32_OFF32 = $extval (sysconfname, "_SC_V7_ILP32_OFF32") macdef _SC_V7_ILP32_OFFBIG = $extval (sysconfname, "_SC_V7_ILP32_OFFBIG") macdef _SC_V7_LP64_OFF64 = $extval (sysconfname, "_SC_V7_LP64_OFF64") macdef _SC_V7_LPBIG_OFFBIG = $extval (sysconfname, "_SC_V7_LPBIG_OFFBIG") // macdef _SC_SS_REPL_MAX = $extval (sysconfname, "_SC_SS_REPL_MAX") // macdef _SC_TRACE_EVENT_NAME_MAX = $extval (sysconfname, "_SC_TRACE_EVENT_NAME_MAX") macdef _SC_TRACE_NAME_MAX = $extval (sysconfname, "_SC_TRACE_NAME_MAX") macdef _SC_TRACE_SYS_MAX = $extval (sysconfname, "_SC_TRACE_SYS_MAX") macdef _SC_TRACE_USER_EVENT_MAX = $extval (sysconfname, "_SC_TRACE_USER_EVENT_MAX") // macdef _SC_XOPEN_STREAMS = $extval (sysconfname, "_SC_XOPEN_STREAMS") // macdef _SC_THREAD_ROBUST_PRIO_INHERIT = $extval (sysconfname, "_SC_THREAD_ROBUST_PRIO_INHERIT") macdef _SC_THREAD_ROBUST_PRIO_PROTEC = $extval (sysconfname, "_SC_THREAD_ROBUST_PRIO_PROTEC") (* ****** ****** *) fun sysconf (name: sysconfname): lint = "mac#atslib_sysconf" (* ****** ****** *) (* end of [unistd_sysconf.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/unistd.sats0000664000175000017500000003231712223166162017670 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/unistd.cats" %} // end of [%{#] (* ****** ****** *) // staload TYPES = "libc/sys/SATS/types.sats" // typedef off_t = $TYPES.off_t typedef pid_t = $TYPES.pid_t typedef uid_t = $TYPES.uid_t typedef gid_t = $TYPES.gid_t // typedef mode_t = $TYPES.mode_t // typedef whence_t = $TYPES.whence_t // (* ****** ****** *) staload FCNTL = "libc/SATS/fcntl.sats" stadef fildes_v = $FCNTL.fildes_v (* ****** ****** *) sta STDIN_FILENO : int sta STDOUT_FILENO : int sta STDERR_FILENO : int // praxi STDIN_FILENO_gtez (): [STDIN_FILENO >= 0] void praxi STDOUT_FILENO_gtez (): [STDOUT_FILENO >= 0] void praxi STDERR_FILENO_gtez (): [STDERR_FILENO >= 0] void // macdef STDIN_FILENO = $extval (int STDIN_FILENO, "STDIN_FILENO") macdef STDOUT_FILENO = $extval (int STDOUT_FILENO, "STDOUT_FILENO") macdef STDERR_FILENO = $extval (int STDERR_FILENO, "STDERR_FILENO") (* ****** ****** *) // // HX: implemented in [$ATSHOME/prelude/CATS/basics.cats] // fun stdin_fildes_view_get (): (fildes_v (STDIN_FILENO) | void) = "atspre_stdin_view_get" fun stdin_fildes_view_set (pf: fildes_v (STDIN_FILENO) | (*none*)): void = "atspre_stdin_view_set" // end of [stdin_fildes_view_set] fun stdout_fildes_view_get (): (fildes_v (STDOUT_FILENO) | void) = "atspre_stdout_view_get" fun stdout_fildes_view_set (pf: fildes_v (STDOUT_FILENO) | (*none*)): void = "atspre_stdout_view_set" // end of [stdout_fildes_view_set] fun stderr_fildes_view_get (): (fildes_v (STDERR_FILENO) | void) = "atspre_stderr_view_get" fun stderr_fildes_view_set (pf: fildes_v (STDERR_FILENO) | (*none*)): void = "atspre_stderr_view_set" // end of [stderr_fildes_view_get] (* ****** ****** *) fun dup {fd:int} ( pf: !fildes_v fd | fd: int fd ) : [fd1: int] ( option_v (fildes_v fd1, fd1 >= 0) | int fd1 ) = "mac#atslib_dup" // end of [dup] (* ****** ****** *) symintr dup2 fun dup2_exi {fd:int;fd2:nat} ( pf: !fildes_v fd , pf2: fildes_v fd2 | fd: int fd, fd2: int fd2 ) : [i:int] ( option_v (fildes_v fd2, i >= 0) | int i // i == fd2 if i >= 0 ) = "mac#atslib_dup2" fun dup2_noexi {fd:int;fd2:nat} ( pf: !fildes_v fd | fd: int fd, fd2: int fd2 ) : [i:int] ( option_v (fildes_v fd2, i >= 0) | int i // i == fd2 if i >= 0 ) = "mac#atslib_dup2" overload dup2 with dup2_exi overload dup2 with dup2_noexi (* ****** ****** *) fun _exit (status: int): void = "mac#atslib__exit" // !macro (* ****** ****** *) fun execv {n:pos} (path: string, argv: &ptrarr(n)): int = "mac#atslib_execv" fun execvp {n:pos} (path: string, argv: &ptrarr(n)): int = "mac#atslib_execvp" (* ****** ****** *) fun fork_err (): pid_t = "atslib_fork_err" // = fork (* ****** ****** *) // // HX-2010-10-08: // these functions, which are implemented in [$ATSHOME/libc/DATS/unistd.dats], // are now kept for historic reasons. // fun fork_exn (): pid_t = "atslib_fork_exn" // function! // // HX: the parent returns immediately // fun fork_exec_cloptr_exn {v:view} (pf: !v | f: (v | (*none*)) - void): void = "atslib_fork_exec_cloptr_exn" // end of [fork_exec_cloptr_exn] // // HX: the parent waits until the (only) child finishes // fun fork_exec_and_wait_cloptr_exn (proc: () - void): int = "atslib_fork_exec_and_wait_cloptr_exn" // end of [fork_exec_and_wait_cloptr_exn] (* ****** ****** *) dataview getcwd_v ( m:int, l:addr, addr ) = | {l>null} {n:nat} getcwd_v_succ (m, l, l) of strbuf_v (m, n, l) | getcwd_v_fail (m, l, null) of b0ytes (m) @ (l) // end of [getcwd_v] fun getcwd {m:nat} {l:addr} ( pf: !b0ytes (m) @ l >> getcwd_v (m, l, l1) | p: ptr l, m: size_t m ) : #[l1:addr] ptr (l1) = "mac#atslib_getcwd" // end of [getcwd] (* ****** ****** *) // // HX: implemented in [$ATSHOME/libc/DATS/unistd.dats] // fun getcwd0 (): strptr1 = "atslib_getcwd0" // // HX: [get_current_dir_name] is available if _GNU_SOURCE is on // (* ****** ****** *) absview alarm_v (int) praxi alarm_v_elim (pf: alarm_v (0)): void fun alarm_set {i:nat} (t: uint i): (alarm_v (i) | uInt) = "mac#atslib_alarm_set" // end of [alarm_set] fun alarm_cancel {i:int} (pf: alarm_v (i) | (*none*)): uInt = "mac#atslib_alarm_cancel" // end of [alarm_cancel] (* ****** ****** *) // // HX: [sleep] may be implemented using SIGARM // fun sleep {i:nat} (t: uint i): [j:nat | j <= i] uint j = "mac#atslib_sleep" // end of [sleep] (* ****** ****** *) #define MILLION 1000000 // // some systems require that the argument of usleep <= 1 million // fun usleep // succ/fail: 0/~1 (n: natLte MILLION(*microsec*)): int(*err*)= "mac#atslib_usleep" // end of [usleep] (* ****** ****** *) fun getpagesize ():<> int = "mac#atslib_getpagesize" // macro (* ****** ****** *) fun getuid ():<> uid_t = "mac#atslib_getuid" // user fun geteuid ():<> uid_t = "mac#atslib_geteuid" // effective user (* ****** ****** *) // // HX: for superuser // 0/-1 : succ/fail // fun setuid ( uid: uid_t ) :<> int = "mac#atslib_setuid" // end of [setuid] fun seteuid ( uid: uid_t ) :<> int = "mac#atslib_seteuid" // 0/-1 : succ/fail // end of [seteuid] (* ****** ****** *) fun getgid ():<> gid_t = "mac#atslib_getgid" // group fun getegid ():<> gid_t = "mac#atslib_getegid" // effective group (* ****** ****** *) // // HX: for superuser // 0/-1 : succ/fail // fun setgid ( gid: gid_t ) :<> int = "mac#atslib_setgid" // !macro // end of [setgid] fun setegid ( gid: gid_t ) :<> int = "mac#atslib_setegid" // 0/-1 : succ/fail // end of [setegid] (* ****** ****** *) fun getpid (): pid_t = "mac#atslib_getpid" // process ID fun getppid (): pid_t = "mac#atslib_getppid" // parent process ID (* ****** ****** *) // // HX: session IDs // fun setsid (): pid_t = "mac#atslib_setsid" // -1 is returned on error fun getsid (pid: pid_t): pid_t = "mac#atslib_getsid" // -1 is returned on error (* ****** ****** *) // // HX: process group IDs // fun getpgid ( pid: pid_t ) :<> pid_t = "mac#atslib_getpgid" // -1 is returned on error // end of [fun] fun setpgid ( pid: pid_t, pgid: pid_t ) : int = "mac#atslib_setpgid" // 0/-1 : succ/fail // end of [fun] fun getpgrp ( // there is no argument ) : pid_t = "mac#atslib_getpgrp" // = getpgid (0) // no error // end of [getpgrp] fun setpgrp ( // there is no argument ) : int = "mac#atslib_setpgrp" // = setpgid (0, 0) // end of [setpgrp] (* ****** ****** *) // // HX: non-reentrant version // fun getlogin ( // there is no argument ) : [l:addr] ( strptr l - void | strptr l ) = "mac#atslib_getlogin" // macro // end of [getlogin] dataview getlogin_v (m:int, l:addr, int) = | {n:nat} getlogin_v_succ (m, l, 0) of strbuf_v (m, n, l) | {i:int | i <> 0} getlogin_v_fail (m, l, i) of b0ytes (m) @ l // end of [getlogin_v] fun getlogin_r {m:int} {l:addr} ( pf: !b0ytes (m) @ l >> getlogin_v (m, l, i) | p: ptr l, n: size_t ) : #[i:int] int i = "mac#atslib_getlogin_r" // 0/!0: succ/fail // end of [fun] (* ****** ****** *) // macdef R_OK = $extval (uint, "R_OK") // test for read permission macdef W_OK = $extval (uint, "W_OK") // test for write permission macdef X_OK = $extval (uint, "X_OK") // test for execute permission macdef F_OK = $extval (uint, "F_OK") // test for existence // fun access (path: string, mode: uint): int = "mac#atslib_access" // end of [access] (* ****** ****** *) fun chroot (path: string): int = "mac#atslib_chroot" // 0/-1 : succ/fail // end of [chroot] (* ****** ****** *) fun chdir (path: string): int(*err*) = "mac#atslib_chdir" fun fchdir {fd:int} (pf: !fildes_v (fd) | fd: int): int(*err*) = "mac#atslib_fchdir" // end of [fchdir] (* ****** ****** *) fun nice (incr: int): int = "mac#atslib_nice" // NZERO/-1 : succ/fail // errno set // end of [nice] (* ****** ****** *) // // HX: succ/fail: 0/-1 // fun rmdir (path: string): int = "mac#atslib_rmdir" (* ****** ****** *) fun link ( src: string, dst: string ) : int = "mac#atslib_link" fun unlink (path: string): int = "mac#atslib_unlink" (* ****** ****** *) fun lseek_err {fd:int} (pf: !fildes_v (fd) | fd: int fd, ofs: off_t, whence: whence_t): off_t = "atslib_fildes_lseek_err" // end of [lseek_err] fun lseek_exn {fd:int} (pf: !fildes_v (fd) | fd: int fd, ofs: off_t, whence: whence_t): off_t = "atslib_fildes_lseek_exn" // end of [lseek_exn] (* ****** ****** *) fun pread {fd:int} {n,sz:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n, ofs: off_t ) : ssizeBtw(~1, n+1) = "atslib_fildes_pread" // end of [fildes_pread] fun pwrite {fd:int} {n,sz:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n, ofs: off_t ) : ssizeBtw(~1, n+1) = "atslib_fildes_pwrite" // end of [fildes_pwrite] (* ****** ****** *) fun sync (): void = "mac#atslib_sync" // [fsync] returns 0 on success or -1 on error fun fsync {fd:int} // (sets errno) (pf: !fildes_v (fd) | fd: int fd): int = "mac#atslib_fsync" // end of [fsync] // [fdatasync] returns 0 on success or -1 on error fun fdatasync {fd:int} // (sets errno) (pf: !fildes_v (fd) | fd: int fd): int = "mac#atslib_fdatasync" // end of [fdatasync] (* ****** ****** *) fun readlink {n:nat} {l:addr} ( pf: !b0ytes(n) @ l >> bytes(n) @ l | path: string, p: ptr l, n: size_t n ) : [n1:int | n1 <= n] ssize_t (n1) = "mac#atslib_readlink" // end of [readlink] (* ****** ****** *) fun pipe ( fd1: &int? >> int fd1, fd2: &int? >> int fd2 ) : #[fd1,fd2:int] [i:int | i <= 0] (option_v ((fildes_v fd1, fildes_v fd2), i==0) | int i) = "atslib_pipe" // function! // end of [pipe] (* ****** ****** *) fun tcsetpgrp {fd:nat} ( fd: int fd, pgid: pid_t ) : int = "mac#atslib_tcsetpgrp" // 0/-1 : succ/fail // end of [tcsetpgrp] fun tcgetpgrp {fd:nat} (fd: int fd): pid_t = "mac#atslib_tcgetpgrp" // -1 is returned on error // end of [tcgetpgrp] (* ****** ****** *) fun ttyname {fd:nat} ( fd: int fd ) : [l:addr] ( strptr l - void | strptr l ) = "mac#atslib_ttyname" // end of [ttyname] dataview ttyname_v (m:int, l:addr, int) = | {n:nat | m > n} ttyname_v_succ (m, l, 0) of strbuf_v (m, n, l) | {i:int | i > 0} ttyname_v_fail (m, l, i) of b0ytes m @ l fun ttyname_r {fd:nat} {m:nat} {l:addr} ( pf: b0ytes m @ l | fd: int fd, p: ptr l, m: size_t m ) :<> [i:int | i >= 0] (ttyname_v (m, l, i) | int i) = "mac#atslib_ttyname_r" // if it fails, errno is returned // end of [ttyname_r] (* ****** ****** *) fun isatty {fd:nat} (fd: int fd): int = "mac#atslib_isatty" // 1/0 : yes/no // end of [isatty] (* ****** ****** *) fun environ_get_arrsz (n: &size_t? >> size_t n): #[n:nat] [l:addr] ( array_v (string, n, l), array_v (string, n, l) - void | ptr l ) = "atslib_environ_get_arrsz" // end of [environ_get_arrsz] (* ****** ****** *) dataview gethostname_v (m:int, l:addr, int) = | gethostname_v_fail (m, l, ~1) of (b0ytes m @ l) | {n:nat | n < m} gethostname_v_succ (m, l, 0) of strbuf_v (m, n, l) // end of [gethostname_v] fun gethostname {m:pos} {l:addr} ( pf: b0ytes(m) @ l | p: ptr l, m: size_t m ) : [i:nat] ( gethostname_v (m, l, i) | int i ) = "atslib_gethostname" // function! // end of [gethostname] // // HX: [m] should most likely be [n+1]. // fun sethostname {m,n:nat | n < m} (name: string n, m: size_t m): int = "mac#atslib_sethostname" // end of [sethostname] (* ****** ****** *) dataview getdomainname_v (m:int, l:addr, int) = | getdomainname_v_fail (m, l, ~1) of (b0ytes m @ l) | {n:nat | n < m} getdomainname_v_succ (m, l, 0) of strbuf_v (m, n, l) // end of [getdomainname_vt] fun getdomainname {m:pos} {l:addr} ( pf: b0ytes(m) @ l | p: ptr l, m: size_t m ) : [i:nat] ( getdomainname_v (m, l, i) | int i ) = "atslib_getdomainname" // function! // end of [getdomainname] // // HX: [m] should most likely be [n+1]. // fun setdomainname {m,n:nat | n < m} (name: string n, m: size_t m): int = "mac#atslib_setdomainname" // end of [setdomainname] (* ****** ****** *) fun pause (): int = "mac#atslib_pause" // if it returns, the return value is -1 (* ****** ****** *) (* end of [unistd.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/stdlib.sats0000664000175000017500000001037112223166162017637 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/stdlib.cats" %} // end of [%{#] (* ****** ****** *) staload FCNTL = "libc/SATS/fcntl.sats" // for [mkstemp] stadef open_v = $FCNTL.open_v (* ****** ****** *) macdef EXIT_SUCCESS = $extval (int, "EXIT_SUCCESS") macdef EXIT_FAILURE = $extval (int, "EXIT_FAILURE") (* ****** ****** *) fun atoi (inp: string):<> int = "mac#atslib_atoi" fun atof (inp: string):<> double = "mac#atslib_atof" fun atol (inp: string):<> lint = "mac#atslib_atol" fun atoll (inp: string):<> llint = "mac#atslib_atoll" (* ****** ****** *) fun strtoi_errnul ( inp: string, base: intBtw (2, 36+1) ) :<> int = "mac#atslib_strtoi_errnul" fun strtol_errnul ( inp: string, base: intBtw (2, 36+1) ) :<> lint = "mac#atslib_strtol_errnul" fun strtoll_errnul ( inp: string, base: intBtw (2, 36+1) ) :<> llint = "mac#atslib_strtoll_errnul" (* ****** ****** *) fun getenv ( name: string ) : [l:addr] ( strptr l - void | strptr l ) = "mac#atslib_getenv" // end of [getenv] // // HX-201-09-29: // [nameval] is copied and put into the environment. // potential memory leak!!! // fun putenv {l:agz} (nameval: !strptr l): int // 0/nz : succ/fail // // HX-2010-09-29: // [name] and [value] are copied into the environment // also note that the original value may be leaked out!!! // fun setenv ( // 0/-1 : succ/fail name: string, value: string, overwrite: int ) : int = "mac#atslib_setenv" // end of [atslib_setenv] fun unsetenv (name: string): int = "mac#atslib_unsetenv" // 0/-1: succ/fail // end of [unsetenv] (* ****** ****** *) fun system (cmd: string): int = "mac#atslib_system" (* ****** ****** *) fun abort (): void = "mac#atslib_abort" (* ****** ****** *) fun _Exit (status: int): void = "mac#atslib__Exit" fun atexit (f: () -> void): int = "mac#atslib_atexit" (* ****** ****** *) (* // HX: [mktemp] is not given an interface as it is BAD!!! *) (* ****** ****** *) // // HX: the last six characters of path much be XXXXXX // fun mkstemp {m,n:int | n >= 6} ( path: &strbuf (m, n) ) : [i:int] ( open_v (i) | int i ) = "mac#atslib_mkstemp" // end of [mkstemp] fun mkdtemp {m,n:int | n >= 6} {l:addr} ( pf: !strbuf (m, n) @ l | p: ptr l ) : [l1:addr | l1==l || l1==null] ptr (l1) = "mac#atslib_mkdtemp" // null/nonnull: fail/succ // end of [mkdtemp] (* ****** ****** *) // // HX: this one returns an integer (not a pointer)! // fun bsearch {a:viewt@ype} {n:nat} ( key: &a , base: &(@[a][n]), nmemb: size_t n, size: sizeof_t a , compar: (&a, &a) - int ) :<> intBtw (~1, n) = "atslib_bsearch" // function! // end of [bsearch] (* ****** ****** *) // // HX: a generic quicksort function // fun qsort {a:viewt@ype} {n:nat} ( base: &(@[a][n]) , nmemb: size_t n, size: sizeof_t a , compar: (&a, &a) - int ) :<> void = "atslib_qsort" // function! // end of [qsort] (* ****** ****** *) (* end of [stdlib.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/dlfcn.sats0000664000175000017500000000704112223166162017444 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: February, 2010 (* ****** ****** *) %{# #include "libc/CATS/dlfcn.cats" %} (* ****** ****** *) absview dlopen_v (addr) // abstract view for [dlopen] (* ****** ****** *) abst@ype dlopen_flag_t = int macdef RTLD_LAZY = $extval (dlopen_flag_t, "RTLD_LAZY") macdef RTLD_NOW = $extval (dlopen_flag_t, "RTLD_NOW") abst@ype dlopen_flagext_t = int macdef RTLD_GLOBAL = $extval (dlopen_flagext_t, "RTLD_GLOBAL") macdef RTLD_LOCAL = $extval (dlopen_flagext_t, "RTLD_LOCAL") // since glibc-2.2 macdef RTLD_NODELETE = $extval (dlopen_flagext_t, "RTLD_NODELETE") // since glibc-2.2 macdef RTLD_NOLOAD = $extval (dlopen_flagext_t, "RTLD_NOLOAD") // since glibc-2.3.4 macdef RTLD_DEEPBIND = $extval (dlopen_flagext_t, "RTLD_DEEPBIND") (* ****** ****** *) fun lor_dlopen_flag_dlopen_flagext (flag: dlopen_flag_t, ext: dlopen_flagext_t):<> dlopen_flag_t = "atslib_lor_dlopen_flag_dlopen_flagext" overload lor with lor_dlopen_flag_dlopen_flagext (* ****** ****** *) (* void *dlopen(const char *filename, int flag); *) fun dlopen (filename: string, flag: dlopen_flag_t) :<> [l:addr] (option_v (dlopen_v l, l > null) | ptr l) = "mac#atslib_dlopen" // end of [dlopen] fun dlopen_exn (filename: string, flag: dlopen_flag_t) : [l:agz] (dlopen_v l | ptr l) = "atslib_dlopen_exn" // this is a function // end of [dlopen_exn] (* ****** ****** *) // success/failure: err = 0/1 fun dlclose {l:agz} ( pf: !dlopen_v l >> option_v (dlopen_v l, i > 0) | handle: ptr l ) :<> #[i:int | i >= 0] int(i) (*err*) = "mac#atslib_dlclose" // end of [dlclose] fun dlclose_exn {l:agz} (pf: dlopen_v l | handle: ptr l): void = "atslib_dlclose_exn" // this is a function // end of [dlclose_exn] (* ****** ****** *) // // HX: // for reporting error; // there is no error if the return is null // fun dlerror () : [l:addr] (strptr (l) - void | strptr (l)) = "mac#atslib_dlerror" // end of [dlerror] fun dlerror_clr (): void // end of [dlerror_clr] (* ****** ****** *) fun dlsym {l:addr} (pf: !dlopen_v l | handle: ptr l, sym: string): ptr = "mac#atslib_dlsym" // end of [dlsym] (* ****** ****** *) (* end of [dlfcn.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/complex.sats0000664000175000017500000002524512223166162020033 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/complex.cats" %} // end of [%{#} (* ****** ****** *) #define ATS_STALOADFLAG 0 // no static loading at run-time (* ****** ****** *) (* ** complex numbers of single precision *) abst@ype ccmplx_t0ype = $extype"ats_fcomplex_type" typedef ccmplx = ccmplx_t0ype symintr ccmplx_of (* ****** ****** *) fun fprint_ccmplx {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: ccmplx): void = "atslib_fprint_ccmplx" overload fprint with fprint_ccmplx fun print_ccmplx (c: ccmplx): void and prerr_ccmplx (c: ccmplx): void overload print with print_ccmplx overload prerr with prerr_ccmplx (* ****** ****** *) val ccmplx_imag_unit : ccmplx = "atslib_ccmplx_imag_unit" // imaginary unit // end of [val] (* ****** ****** *) fun ccmplx_of_int (i: int):<> ccmplx = "atslib_ccmplx_of_int" overload ccmplx_of with ccmplx_of_int fun ccmplx_of_float (f: float):<> ccmplx = "atslib_ccmplx_of_float" overload ccmplx_of with ccmplx_of_float fun ccmplx_make_cart (f1: float, f2: float):<> ccmplx = "atslib_ccmplx_make_cart" fun ccmplx_make_polar (f1: float, f2: float):<> ccmplx = "atslib_ccmplx_make_polar" (* ****** ****** *) fun crealf (c: ccmplx):<> float = "atslib_crealf" fun ccmplx_real (c: ccmplx):<> float = "atslib_crealf" fun cimagf (c: ccmplx):<> float = "atslib_cimagf" fun ccmplx_imag (c: ccmplx):<> float = "atslib_cimagf" (* ****** ****** *) fun neg_ccmplx (c: ccmplx):<> ccmplx = "atslib_neg_ccmplx" overload ~ with neg_ccmplx fun add_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_add_ccmplx_ccmplx" overload + with add_ccmplx_ccmplx fun sub_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_sub_ccmplx_ccmplx" overload - with sub_ccmplx_ccmplx fun mul_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_mul_ccmplx_ccmplx" overload * with mul_ccmplx_ccmplx fun div_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_div_ccmplx_ccmplx" overload / with div_ccmplx_ccmplx (* ****** ****** *) fun eq_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> bool = "atslib_eq_ccmplx_ccmplx" overload = with eq_ccmplx_ccmplx fun neq_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> bool = "atslib_neq_ccmplx_ccmplx" overload <> with neq_ccmplx_ccmplx (* ****** ****** *) fun cabsf (c: ccmplx):<> float = "atslib_cabsf" fun abs_ccmplx (c: ccmplx):<> float = "atslib_cabsf" overload abs with abs_ccmplx fun csqrtf (c: ccmplx):<> ccmplx = "atslib_csqrtf" fun sqrt_ccmplx (c: ccmplx):<> ccmplx = "atslib_csqrtf" overload sqrt with sqrt_ccmplx (* ****** ****** *) fun cargf (c: ccmplx):<> float = "atslib_cargf" fun arg_ccmplx (c: ccmplx):<> float = "atslib_cargf" fun conjf (c: ccmplx):<> ccmplx = "atslib_conjf" fun conj_ccmplx (c: ccmplx):<> ccmplx = "atslib_conjf" (* ****** ****** *) fun csinf (c: ccmplx):<> ccmplx = "atslib_csinf" fun sin_ccmplx (c: ccmplx):<> ccmplx = "atslib_csinf" fun ccosf (c: ccmplx):<> ccmplx = "atslib_ccosf" fun cos_ccmplx (c: ccmplx):<> ccmplx = "atslib_ccosf" fun ctanf (c: ccmplx):<> ccmplx = "atslib_ctanf" fun tan_ccmplx (c: ccmplx):<> ccmplx = "atslib_ctanf" (* ****** ****** *) fun casinf (c: ccmplx):<> ccmplx = "atslib_casinf" fun asin_ccmplx (c: ccmplx):<> ccmplx = "atslib_casinf" fun cacosf (c: ccmplx):<> ccmplx = "atslib_cacosf" fun acos_ccmplx (c: ccmplx):<> ccmplx = "atslib_cacosf" fun catanf (c: ccmplx):<> ccmplx = "atslib_catanf" fun atan_ccmplx (c: ccmplx):<> ccmplx = "atslib_catanf" (* ****** ****** *) fun csinhf (c: ccmplx):<> ccmplx = "atslib_csinhf" fun sinh_ccmplx (c: ccmplx):<> ccmplx = "atslib_csinhf" fun ccoshf (c: ccmplx):<> ccmplx = "atslib_ccoshf" fun cosh_ccmplx (c: ccmplx):<> ccmplx = "atslib_ccoshf" fun ctanhf (c: ccmplx):<> ccmplx = "atslib_ctanhf" fun tanh_ccmplx (c: ccmplx):<> ccmplx = "atslib_ctanhf" (* ****** ****** *) fun casinhf (c: ccmplx):<> ccmplx = "atslib_casinhf" fun asinh_ccmplx (c: ccmplx):<> ccmplx = "atslib_casinhf" fun cacoshf (c: ccmplx):<> ccmplx = "atslib_cacoshf" fun acosh_ccmplx (c: ccmplx):<> ccmplx = "atslib_cacoshf" fun catanhf (c: ccmplx):<> ccmplx = "atslib_catanhf" fun atanh_ccmplx (c: ccmplx):<> ccmplx = "atslib_catanhf" (* ****** ****** *) fun cexpf (c: ccmplx):<> ccmplx = "atslib_cexpf" fun exp_ccmplx (c: ccmplx):<> ccmplx = "atslib_cexpf" fun clogf (c: ccmplx):<> ccmplx = "atslib_clogf" fun log_ccmplx (c: ccmplx):<> ccmplx = "atslib_clogf" fun cpowf (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_cpowf" fun pow_ccmplx_ccmplx (c1: ccmplx, c2: ccmplx):<> ccmplx = "atslib_cpowf" overload pow with pow_ccmplx_ccmplx fun pow_ccmplx_float (c1: ccmplx, c2: float):<> ccmplx = "mac#atslib_pow_ccmplx_float" // macro! overload pow with pow_ccmplx_float (* ****** ****** *) fun cprojf (c: ccmplx):<> float = "atslib_cprojf" (* ****** ****** *) (* ** complex numbers of double precision *) (* ****** ****** *) abst@ype zcmplx_t0ype = $extype"ats_dcomplex_type" typedef zcmplx = zcmplx_t0ype symintr zcmplx_of (* ****** ****** *) fun fprint_zcmplx {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: zcmplx): void = "atslib_fprint_zcmplx" overload fprint with fprint_zcmplx fun print_zcmplx (z: zcmplx): void and prerr_zcmplx (z: zcmplx): void overload print with print_zcmplx overload prerr with prerr_zcmplx (* ****** ****** *) val zcmplx_imag_unit : zcmplx = "atslib_zcmplx_imag_unit" // imaginary unit // end of [val] (* ****** ****** *) fun zcmplx_of_int (i: int):<> zcmplx = "atslib_zcmplx_of_int" overload zcmplx_of with zcmplx_of_int fun zcmplx_of_double (d: double):<> zcmplx = "atslib_zcmplx_of_double" overload zcmplx_of with zcmplx_of_double fun zcmplx_make_cart (d1: double, d2: double):<> zcmplx = "atslib_zcmplx_make_cart" fun zcmplx_make_polar (d1: double, d2: double):<> zcmplx = "atslib_zcmplx_make_polar" (* ****** ****** *) fun creal (z: zcmplx):<> double = "atslib_creal" fun zcmplx_real (z: zcmplx):<> double = "atslib_creal" fun cimag (z: zcmplx):<> double = "atslib_cimag" fun zcmplx_imag (z: zcmplx):<> double = "atslib_cimag" (* ****** ****** *) fun neg_zcmplx (z: zcmplx):<> zcmplx = "atslib_neg_zcmplx" overload ~ with neg_zcmplx fun add_zcmplx_zcmplx (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_add_zcmplx_zcmplx" overload + with add_zcmplx_zcmplx fun sub_zcmplx_zcmplx (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_sub_zcmplx_zcmplx" overload - with sub_zcmplx_zcmplx fun mul_zcmplx_zcmplx (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_mul_zcmplx_zcmplx" overload * with mul_zcmplx_zcmplx fun div_zcmplx_zcmplx (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_div_zcmplx_zcmplx" overload / with div_zcmplx_zcmplx (* ****** ****** *) fun eq_zcmplx_zcmplx (c1: zcmplx, c2: zcmplx):<> bool = "atslib_eq_zcmplx_zcmplx" overload = with eq_zcmplx_zcmplx fun neq_zcmplx_zcmplx (c1: zcmplx, c2: zcmplx):<> bool = "atslib_neq_zcmplx_zcmplx" overload <> with neq_zcmplx_zcmplx (* ****** ****** *) fun cabs (z: zcmplx):<> double = "atslib_cabs" fun abs_zcmplx (z: zcmplx):<> double = "atslib_cabs" overload abs with abs_zcmplx fun csqrt (z: zcmplx):<> zcmplx = "atslib_csqrt" fun sqrt_zcmplx (z: zcmplx):<> zcmplx = "atslib_csqrt" overload sqrt with sqrt_zcmplx (* ****** ****** *) fun carg (z: zcmplx):<> double = "atslib_carg" fun arg_zcmplx (z: zcmplx):<> double = "atslib_carg" fun conj (z: zcmplx):<> zcmplx = "atslib_conj" fun conj_zcmplx (z: zcmplx):<> zcmplx = "atslib_conj" (* ****** ****** *) fun csin (z: zcmplx):<> zcmplx = "atslib_csin" fun sin_zcmplx (z: zcmplx):<> zcmplx = "atslib_csin" fun ccos (z: zcmplx):<> zcmplx = "atslib_ccos" fun cos_zcmplx (z: zcmplx):<> zcmplx = "atslib_ccos" fun ctan (z: zcmplx):<> zcmplx = "atslib_ctan" fun tan_zcmplx (z: zcmplx):<> zcmplx = "atslib_ctan" (* ****** ****** *) fun casin (z: zcmplx):<> zcmplx = "atslib_casin" fun asin_zcmplx (z: zcmplx):<> zcmplx = "atslib_casin" fun cacos (z: zcmplx):<> zcmplx = "atslib_cacos" fun acos_zcmplx (z: zcmplx):<> zcmplx = "atslib_cacos" fun catan (z: zcmplx):<> zcmplx = "atslib_catan" fun atan_zcmplx (z: zcmplx):<> zcmplx = "atslib_catan" (* ****** ****** *) fun csinh (z: zcmplx):<> zcmplx = "atslib_csinh" fun sinh_zcmplx (z: zcmplx):<> zcmplx = "atslib_csinh" fun ccosh (z: zcmplx):<> zcmplx = "atslib_ccosh" fun cosh_zcmplx (z: zcmplx):<> zcmplx = "atslib_ccosh" fun ctanh (z: zcmplx):<> zcmplx = "atslib_ctanh" fun tanh_zcmplx (z: zcmplx):<> zcmplx = "atslib_ctanh" (* ****** ****** *) fun casinh (z: zcmplx):<> zcmplx = "atslib_casinh" fun asinh_zcmplx (z: zcmplx):<> zcmplx = "atslib_casinh" fun cacosh (z: zcmplx):<> zcmplx = "atslib_cacosh" fun acosh_zcmplx (z: zcmplx):<> zcmplx = "atslib_cacosh" fun catanh (z: zcmplx):<> zcmplx = "atslib_catanh" fun atanh_zcmplx (z: zcmplx):<> zcmplx = "atslib_catanh" (* ****** ****** *) fun cexp (z: zcmplx):<> zcmplx = "atslib_cexp" fun exp_zcmplx (z: zcmplx):<> zcmplx = "atslib_cexp" fun clog (z: zcmplx):<> zcmplx = "atslib_clog" fun log_zcmplx (z: zcmplx):<> zcmplx = "atslib_clog" fun cpow (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_cpow" fun pow_zcmplx_zcmplx (z1: zcmplx, z2: zcmplx):<> zcmplx = "atslib_cpow" overload pow with pow_zcmplx_zcmplx fun pow_zcmplx_double (z1: zcmplx, z2: double):<> zcmplx = "mac#atslib_pow_zcmplx_double" // macro! overload pow with pow_zcmplx_double (* ****** ****** *) fun cproj (z: zcmplx):<> double = "atslib_cproj" (* ****** ****** *) (* end of [complex.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/signal.sats0000664000175000017500000002226212223166162017635 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. ** *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/signal.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef pid_t = $TYPES.pid_t typedef uid_t = $TYPES.uid_t typedef clock_t = $TYPES.clock_t staload PTHREAD = "libc/SATS/pthread.sats" typedef pthread_t = $PTHREAD.pthread_t (* ****** ****** *) // // HX: defined in [libc/CATS/signal.cats] // abst@ype signum_t = $extype"signum_t" // macdef SIGHUP = $extval (signum_t, "SIGHUP") // 1 macdef SIGINT = $extval (signum_t, "SIGINT") // 2 macdef SIGQUIT = $extval (signum_t, "SIGQUIT") // 3 macdef SIGILL = $extval (signum_t, "SIGILL") // 4 macdef SIGABRT = $extval (signum_t, "SIGABRT") // 6 macdef SIGFPE = $extval (signum_t, "SIGFPE") // 8 macdef SIGKILL = $extval (signum_t, "SIGKILL") // 9 macdef SIGSEGV = $extval (signum_t, "SIGSEGV") // 11 macdef SIGPIPE = $extval (signum_t, "SIGPIPE") // 13 macdef SIGALRM = $extval (signum_t, "SIGALRM") // 14 macdef SIGTERM = $extval (signum_t, "SIGTERM") // 15 macdef SIGUSR1 = $extval (signum_t, "SIGUSR1") macdef SIGUSR2 = $extval (signum_t, "SIGUSR2") macdef SIGCHLD = $extval (signum_t, "SIGCHLD") macdef SIGCONT = $extval (signum_t, "SIGCONT") macdef SIGSTOP = $extval (signum_t, "SIGSTOP") macdef SIGTSTP = $extval (signum_t, "SIGTSTP") macdef SIGTTIN = $extval (signum_t, "SIGTTIN") macdef SIGTTOU = $extval (signum_t, "SIGTTOU") // macdef SIGBUS = $extval (signum_t, "SIGBUS") macdef SIGTRAP = $extval (signum_t, "SIGTRAP") // 5 // macdef SIGIO = $extval (signum_t, "SIGIO") (* ****** ****** *) abstype sighandler_t // this is a boxed type // macdef SIG_DFL = $extval (sighandler_t, "SIG_DFL") macdef SIG_IGN = $extval (sighandler_t, "SIG_IGN") macdef SIG_HOLD = $extval (sighandler_t, "SIG_HOLD") macdef SIG_ERR = $extval (sighandler_t, "SIG_ERR") // symintr sighandler castfn sighandler_of_fun (f: signum_t - void): sighandler_t overload sighandler with sighandler_of_fun (* ****** ****** *) abst@ype sigset_t = $extype"sigset_t" fun sigemptyset // 0/-1 : fail/succ // errno set: EINVAL (set: &sigset_t? >> opt (sigset_t, i==0)) : #[i:int | i <= 0] int (i) = "mac#atslib_sigemptyset" // end of [sigemptyset] fun sigfillset // 0/-1 : fail/succ // errno set: EINVAL (set: &sigset_t? >> opt (sigset_t, i==0)) : #[i:int | i <= 0] int (i) = "mac#atslib_sigfillset" // end of [sigfillset] fun sigaddset // 0/-1 : fail/succ // errno set: EINVAL (set: &sigset_t, sgn: signum_t): int = "mac#atslib_sigaddset" // end of [sigaddset] fun sigdelset // 0/-1 : fail/succ // errno set: EINVAL (set: &sigset_t, sgn: signum_t): int = "mac#atslib_sigdelset" // end of [sigdelset] fun sigismember // 0/1/-1 : false/true/error // errno set: EINVAL (set: &sigset_t, sgn: signum_t): int = "mac#atslib_sigismember" // end of [sigismember] (* ****** ****** *) abst@ype sigmaskhow_t = int macdef SIG_BLOCK = $extval (sigmaskhow_t, "SIG_BLOCK") macdef SIG_UNBLOCK = $extval (sigmaskhow_t, "SIG_UNBLOCK") macdef SIG_SETMASK = $extval (sigmaskhow_t, "SIG_SETMASK") /* ****** ****** */ fun pthread_sigmask ( how: sigmaskhow_t , newset: &sigset_t, oldset: &sigset_t? >> opt (sigset_t, i==0) ) : #[i:int | i <= 0] int (i) = "mac#atslib_pthread_sigmask" fun pthread_sigmask_null (how: sigmaskhow_t, newset: &sigset_t): int = "mac#atslib_pthread_sigmask" // end of [pthread_sigmask_null] fun sigprocmask ( how: sigmaskhow_t , newset: &sigset_t, oldset: &sigset_t? >> opt (sigset_t, i==0) ) : #[i:int | i <= 0] int (i) = "mac#atslib_sigprocmask" fun sigprocmask_null (how: sigmaskhow_t, newset: &sigset_t): int = "mac#atslib_sigprocmask_null" // end of [sigprocmask_null] (* ****** ****** *) abst@ype sigval_t = $extype"sigval_t" abst@ype saflag_t = uint macdef SA_NOCLDSTOP = $extval (saflag_t, "SA_NOCLDSTOP") macdef SA_NOCLDWAIT = $extval (saflag_t, "SA_NOCLDWAIT") macdef SA_NODEFER = $extval (saflag_t, "SA_NODEFER") macdef SA_ONSTACK = $extval (saflag_t, "SA_ONSTACK") macdef SA_RESETHAND = $extval (saflag_t, "SA_RESETHAND") macdef SA_RESTART = $extval (saflag_t, "SA_RESTART") macdef SA_SIGINFO = $extval (saflag_t, "SA_SIGINFO") (* ****** ****** *) typedef siginfo_t = $extype_struct "siginfo_t" of { si_signo= int // signal number , si_sigerror= int // error value , si_code= int // signal code , si_trapno= int // trap number that caused HW signal , si_pid= pid_t // proc ID of the sending process , si_uid= uid_t // real user ID of the sending process , si_status= int // exit value or signal , si_utime= clock_t // user time consumed , si_stime= clock_t // system time consumed , si_value= sigval_t // signal value , si_int= int // signal (POSIX.1b) , si_ptr= ptr // signal (POSIX.1b) , si_overrun= int // timer overrun count (POSIX.1b) , si_timerid= int // timer ID (POSIX.1b) , si_addr= ptr // memory location that caused fault , si_band= int // band event , si_fd= int // file descriptor } // end of [siginfo_t] (* ****** ****** *) // // HX: this one is deprecated; please use [sigaction] // fun signal (sgn: signum_t, act: sighandler_t): sighandler_t = "mac#atslib_signal" // end of [signal] fun sigset (sgn: signum_t, act: sighandler_t): sighandler_t = "mac#atslib_sigset" // end of [sigset] // HX: for unblocking a signal fun sigrelse (sgn: signum_t): int = "mac#atslib_sigrelse" // 0/-1 : succ/fail // HX: sighold(sgn) = sigset (sgn, SIG_HOLD) fun sighold (sgn: signum_t): int = "mac#atslib_sighold" // 0/-1 : succ/fail // HX: sigignore(sgn) = sigset (sgn, SIG_IGN) fun sigignore (sgn: signum_t): int = "mac#atslib_sigignore" // 0/-1 : succ/fail (* ****** ****** *) typedef sigaction_struct = $extype_struct "ats_sigaction_type" of { sa_handler= sighandler_t , sa_sigaction= (int, &siginfo_t, ptr) - void , sa_mask= sigset_t , sa_flags= saflag_t , sa_restorer= () - void } // end of [sigaction_struct] typedef sigaction = sigaction_struct fun sigaction ( sgn: signum_t , newact: &sigaction, oldact: &sigaction? >> opt (sigaction, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_sigaction" // 0/-1 : succ/fail fun sigaction_null (sgn: signum_t, newact: &sigaction): int = "mac#atslib_sigaction_null" // end of [sigaction_null] (* ****** ****** *) fun kill // 0/-1 : succ/fail // errno set (proc: pid_t, sgn: signum_t): int = "mac#atslib_kill" // end of [kill] // // HX: killpg (pgrp, sgn) = kill (-pgrp, sgn) // fun killpg // 0/-1 : succ/fail // errno set (pgrp: pid_t, sgn: signum_t): int = "mac#atslib_killpg" // end of [killpg] fun pthread_kill // 0/errno : succ/fail (tid: pthread_t, sgn: signum_t): int = "mac#atslib_pthread_kill" // end of [pthread_kill] // // HX: raise(sgn) = pthread_kill (pthread_self, sgn) // fun raise // 0/errno : succ/fail (sgn: signum_t): int = "mac#atslib_raise" // 0/nz : succ/fail // end of [raise] (* ****** ****** *) fun sigwait ( // 0/errno : succ/fail set: &sigset_t, sgn: &signum_t? >> opt (signum_t, i==0) ) : #[i:int | i >= 0] int(i) = "mac#atslib_sigwait" // end of [sigwait] (* ****** ****** *) // // HX: deprecated; please use [sigsuspend] // fun sigpause // -1: fail // errno set (sgn: signum_t): int = "mac#atslib_pause" // end of [sigpause] // // HX: -1: fail // errno set // normally, EINTR is set // fun sigsuspend (mask: &sigset_t): int = "mac#atslib_sigsuspend" (* ****** ****** *) fun sigpending ( // 0/-1: succ/fail // errno set set: &sigset_t? >> opt (sigset_t, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_sigpending" // end of [sigpending] (* ****** ****** *) fun siginterrupt // 0/-1 : succ/fail // errno set (sgn: signum_t, flag: int): int = "mac#atslib_siginterrupt" // end of [siginterrupt] (* ****** ****** *) // HX: print onto stderr fun psignal (sgn: signum_t, msg: string): void = "mac#atslib_psignal" // end of [psignal] fun strsignal (sgn: signum_t) // HX: errno set? : [l:addr] (strptr(l) - void | strptr(l)) = "mac#atslib_strsignal" // end of [strsignal] (* ****** ****** *) (* end of [signal.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/sched.sats0000664000175000017500000000604312223166162017445 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // Time: April, 2010 (* ****** ****** *) %{# #include "libc/CATS/sched.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for staload at run-time (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef pid_t = $TYPES.pid_t (* ****** ****** *) typedef sched_param_struct = $extype_struct "ats_sched_param_type" of { sched_priority= int , _rest = undefined_t // for unknown fields } // end of [sched_param] typedef sched_param = sched_param_struct (* ****** ****** *) // // HX-2010-04-02: // [n] is the size of [cpu_set_t] in byte! // abst@ype cpu_set0_t = $extype"cpu_set_t" abst@ype cpu_set_t (n:int) = cpu_set0_t (* ****** ****** *) prfun cpusetinit (x: !cpu_set0_t? >> cpu_set_t n): #[n:nat] void fun cpusetsize_get {n:nat} (cs: &cpu_set_t n):<> size_t n = "atslib_cpusetsize_get" // end of [cpusetsize_get] (* ****** ****** *) // // HX: pid=0: myself // fun sched_getaffinity {n:nat} ( pid: pid_t, n: size_t n, cs: &cpu_set_t n ) : int(*err*) = "atslib_sched_getaffinity" // end of [fun] fun sched_setaffinity {n:nat} ( pid: pid_t, n: size_t n, cs: &cpu_set_t n ) : int(*err*) = "atslib_sched_setaffinity" // end of [fun] (* ****** ****** *) fun CPU_ZERO {n:nat} (cpuset: &cpu_set_t n):<> void = "mac#atslib_CPU_ZERO" fun CPU_CLR {n,i:nat | i < 8*n} (cpu: int i, cpuset: &cpu_set_t n):<> void = "mac#atslib_CPU_CLR" fun CPU_SET {n,i:nat | i < 8*n} (cpu: int i, cpuset: &cpu_set_t n):<> void = "mac#atslib_CPU_SET" fun CPU_ISSET {n,i:nat | i < 8*n} (cpu: int i, cpuset: &cpu_set_t n):<> int = "mac#atslib_CPU_ISSET" (* ****** ****** *) (* end of [sched.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/strings.sats0000664000175000017500000000524612223166162020054 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/strings.cats" %} // end of [%{#] (* ****** ****** *) /* // int bcmp(const void *, const void *, size_t); (LEGACY ) // void bcopy(const void *, void *, size_t); (LEGACY ) // void bzero(void *, size_t); (LEGACY ) // int ffs(int); // find first (least significant) bit set in a word // HX: handled // char *index(const char *, int); (LEGACY ) // char *rindex(const char *, int); (LEGACY ) // int strcasecmp(const char *, const char *); // HX: handled // int strncasecmp(const char *, const char *, size_t); // HX: handled */ (* ****** ****** *) // // HX: // find the first (least significant) bit set in a word // note that position starts from 1 until 32 or 64; 0 is returned // if no bit is set // fun ffs (i: int): [n:int | n >= 0] int n = "mac#atslib_ffs" (* ****** ****** *) // // HX: string comparison like [strcmp] but case is ignored // fun strcasecmp ( str1: string, str2: string ) : int= "mac#atslib_strcasecmp" // end of [strcasecmp] (* ****** ****** *) // // HX: string comparison like [strncmp] but case is ignored // fun strncasecmp ( str1: string, str2: string, n: size_t ) : int = "mac#atslib_strncasecmp" // end of [strncasecmp] (* ****** ****** *) (* end of [strings.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/float.sats0000664000175000017500000000762012223166162017466 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* author: Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) *) (* ****** ****** *) // // HX-2011-08-01: note that [float.h] is rather new (gcc 4.6) // (* ****** ****** *) %{# #include "libc/CATS/float.cats" %} // end of [%{#] (* ****** ****** *) (* #define ATS_STALOADFLAG 0 // no need for static loading at run-time *) (* ****** ****** *) fun{a:t@ype} RADIX_tmp (): int macdef FLT_RADIX = $extval (int, "FLT_RADIX") macdef DBL_RADIX = $extval (int, "DBL_RADIX") macdef LDBL_RADIX = $extval (int, "LDBL_RADIX") fun{a:t@ype} ROUNDS_tmp (): int macdef FLT_ROUNDS = $extval (int, "FLT_ROUNDS") macdef DBL_ROUNDS = $extval (int, "DBL_ROUNDS") macdef LDBL_ROUNDS = $extval (int, "LDBL_ROUNDS") (* ****** ****** *) fun{a:t@ype} DIG_tmp (): int macdef DBL_DIG = $extval (int, "DBL_DIG") macdef FLT_DIG = $extval (int, "FLT_DIG") macdef LDBL_DIG = $extval (int, "LDBL_DIG") fun{a:t@ype} MANT_DIG_tmp (): int macdef DBL_MANT_DIG = $extval (int, "DBL_MANT_DIG") macdef FLT_MANT_DIG = $extval (int, "FLT_MANT_DIG") macdef LDBL_MANT_DIG = $extval (int, "LDBL_MANT_DIG") (* ****** ****** *) fun{a:t@ype} MAX_EXP_tmp ():<> int macdef DBL_MAX_EXP = $extval (int, "DBL_MAX_EXP") macdef FLT_MAX_EXP = $extval (int, "FLT_MAX_EXP") macdef LDBL_MAX_EXP = $extval (int, "LDBL_MAX_EXP") fun{a:t@ype} MIN_EXP_tmp ():<> int macdef DBL_MIN_EXP = $extval (int, "DBL_MIN_EXP") macdef FLT_MIN_EXP = $extval (int, "FLT_MIN_EXP") macdef LDBL_MIN_EXP = $extval (int, "LDBL_MIN_EXP") (* ****** ****** *) fun{a:t@ype} MAX_10_EXP_tmp ():<> int macdef DBL_MAX_10_EXP = $extval (int, "DBL_MAX_10_EXP") macdef FLT_MAX_10_EXP = $extval (int, "FLT_MAX_10_EXP") macdef LDBL_MAX_10_EXP = $extval (int, "LDBL_MAX_10_EXP") fun{a:t@ype} MIN_10_EXP_tmp ():<> int macdef DBL_MIN_10_EXP = $extval (int, "DBL_MIN_10_EXP") macdef FLT_MIN_10_EXP = $extval (int, "FLT_MIN_10_EXP") macdef LDBL_MIN_10_EXP = $extval (int, "LDBL_MIN_10_EXP") (* ****** ****** *) fun{a:t@ype} MAX_tmp ():<> a macdef DBL_MAX = $extval (double, "DBL_MAX") macdef FLT_MAX = $extval (float, "FLT_MAX") macdef LDBL_MAX = $extval (ldouble, "LDBL_MAX") fun{a:t@ype} MIN_tmp ():<> a macdef DBL_MIN = $extval (double, "DBL_MIN") macdef FLT_MIN = $extval (float, "FLT_MIN") macdef LDBL_MIN = $extval (ldouble, "LDBL_MIN") (* ****** ****** *) fun{a:t@ype} EPSILON_tmp ():<> a macdef DBL_EPSILON = $extval (double, "DBL_EPSILON") macdef FLT_EPSILON = $extval (float, "FLT_EPSILON") macdef LDBL_EPSILON = $extval (ldouble, "LDBL_EPSILON") (* ****** ****** *) (* end of [float.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/pwd.sats0000664000175000017500000000775712223166162017166 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/pwd.cats" %} // end of [%{#] (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef gid_t = $T.gid_t typedef uid_t = $T.uid_t (* ****** ****** *) (* struct passwd { char *pw_name; /* Username. */ char *pw_passwd; /* Password. */ __uid_t pw_uid; /* User ID. */ __gid_t pw_gid; /* Group ID. */ char *pw_gecos; /* Real name. */ char *pw_dir; /* Home directory. */ char *pw_shell; /* Shell program. */ } ; *) abst@ype passwd_rest // unknown quantity typedef passwd_struct = $extype_struct "ats_passwd_type" of { pw_name= ptr // char* , pw_passwd= ptr // char* , pw_uid= uid_t , pw_gid= gid_t , pw_gecos= ptr // char* , pw_dir= ptr // char* , pw_shell= ptr // char* , _rest= undefined_t } // end of [passwd] typedef passwd = passwd_struct (* ****** ****** *) fun passwd_get_pw_name ( pwd: &READ(passwd) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_passwd_get_pw_name" // function! // end of [passwd_get_pw_name] fun passwd_get_pw_passwd ( pwd: &READ(passwd) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_passwd_get_pw_passwd" // function! // end of [passwd_get_pw_passwd] fun passwd_get_pw_gecos ( pwd: &READ(passwd) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_passwd_get_pw_gecos" // function! // end of [passwd_get_pw_gecos] fun passwd_get_pw_dir ( pwd: &READ(passwd) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_passwd_get_pw_dir" // function! // end of [passwd_get_pw_dir] fun passwd_get_pw_shell ( pwd: &READ(passwd) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_passwd_get_pw_shell" // function! // end of [passwd_get_pw_shell] (* ****** ****** *) // HX: non-reentrant fun getpwnam ( nam: string ) : [l:addr] ( vptroutopt (passwd, l) | ptr l ) = "mac#atslib_getpwnam" // end of [getpwnam] // HX: reentrant fun getpwnam_r {n:nat} ( nam: string , pwbuf: &passwd? >> opt (passwd, i==0) , buf: &b0ytes(n) >> bytes(n) , n: size_t (n) , ppwbuf: &ptr? >> ptr ) :<> #[i:int | i >= 0] int (i) = "mac#atslib_getpwnam_r" // end of [getpwnam_r] (* ****** ****** *) // HX: non-reentrant fun getpwuid ( uid: uid_t ) : [l:addr] ( vptroutopt (passwd, l) | ptr l ) = "mac#atslib_getpwuid" // end of [getpwuid] // HX: reentrant fun getpwuid_r {n:nat} ( uid: uid_t , pwbuf: &passwd? >> opt (passwd, i==0) , buf: &b0ytes(n) >> bytes(n) , n: size_t (n) , ppwbuf: &ptr? >> ptr ) :<> #[i:int | i >= 0] int (i) = "mac#atslib_getpwuid_r" // end of [getpwuid_r] (* ****** ****** *) (* end of [pwd.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/random.sats0000664000175000017500000000746312223166162017646 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // Some simple random number generators // For more realistic ones, please see the gsl_rng.h and gsl_randist.h // in the GNU Science Library // (* ****** ****** *) %{# #include "libc/CATS/random.cats" %} // end of [%{#] (* ****** ****** *) // // typedef lint = long_int_t0ype // already defined elsewhere // // a seeding function fun srand48 (li: lint): void = "atslib_srand48" // using epoch time for the seed fun srand48_with_time (): void = "atslib_srand48_with_time" // using microsecond for the seed fun srand48_with_gettimeofday (): int (*err*) // 0/-1: succ/fail (* ****** ****** *) // // HX: the range of [drand48] is supposed to be [0.0, 1.0) // However, it is actually [0.0, 1.0] // try 10 million times !!! // fun drand48 (): double = "atslib_drand48" fun lrand48 (): lint = "atslib_lrand48" // signed [0, 2^31) fun mrand48 (): lint = "atslib_mrand48" // signed [-2^31, 2^31) (* ****** ****** *) abst@ype drand48_data = $extype"ats_drand48_data_type" (* ****** ****** *) fun srand48_r ( // the return is always 0 seed: lint, buf: &drand48_data? >> drand48_data ) :<> int = "atslib_srand48_r" // end of [srand48_r] (* ****** ****** *) fun drand48_r ( // the return is always 0 buf: &drand48_data, result: &double? >> double ) :<> int = "atslib_drand48_r" // end of [drand48_r] fun lrand48_r ( // the return is always 0 buf: &drand48_data, result: &lint? >> lint ) :<> int = "atslib_lrand48_r" // end of [lrand48_r] fun mrand48_r ( // the return is always 0 buf: &drand48_data, result: &lint? >> lint ) :<> int = "atslib_mrand48_r" // end of [mrand48_r] (* ****** ****** *) // // HX: non-reentrant // fun randint {n:pos} (n: int n): natLt n = "atslib_randint" // end of [randint] fun randsize {n:pos} (n: size_t n): sizeLt n = "atslib_randsize" // end of [randsize] (* ****** ****** *) // // HX: [randperm] returns a randomly generated permutation // fun randperm {n:nat} (n: int n) : [l:agz] (free_gc_v (int?, n, l), array_v (natLt n, n, l) | ptr l) // end of [randperm] (* ****** ****** *) // // HX: reentrant // fun randint_r {n:pos} ( buf: &drand48_data, n: int n, res: &int? >> natLt n ) :<> void = "atslib_randint_r" // end of [randint_r] fun randsize_r {n:pos} ( buf: &drand48_data, n: size_t n, res: &size_t? >> sizeLt n ) :<> void = "atslib_randsize_r" // end of [randsize_r] (* ****** ****** *) (* end of [random.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/gmp.sats0000664000175000017500000013242512223166162017146 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // MPZ and MPQ (* Author: Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu) *) // MPF (* ****** ****** *) %{# #include "libc/CATS/gmp.cats" %} // end of [%{#] (* ****** ****** *) // integral numbers absviewt@ype mpz_viewt0ype = $extype"ats_mpz_viewt0ype" stadef mpz_vt = mpz_viewt0ype // rational numbers absviewt@ype mpq_viewt0ype = $extype"ats_mpq_viewt0ype" stadef mpq_vt = mpq_viewt0ype // floating point numbers absviewt@ype mpf_viewt0ype = $extype"ats_mpf_viewt0ype" stadef mpf_vt = mpf_viewt0ype (* ****** ****** *) abst@ype mp_limb_t = $extype"mp_limb_t" abst@ype mp_limb_signed_t = $extype"mp_limb_signed_t" (* ****** ****** *) abst@ype mp_exp_t = $extype"mp_exp_t" // int or lint symintr mp_exp_t castfn mp_exp_t_of_int (x: int):<> mp_exp_t overload mp_exp_t with mp_exp_t_of_int castfn mp_exp_t_of_lint (x: lint):<> mp_exp_t overload mp_exp_t with mp_exp_t_of_lint abst@ype mp_size_t = $extype"mp_size_t" // int or lint symintr mp_size_t castfn mp_size_t_of_int (x: int):<> mp_size_t overload mp_size_t with mp_size_t_of_int castfn mp_size_t_of_lint (x: lint):<> mp_size_t overload mp_size_t with mp_size_t_of_lint (* ****** ****** *) typedef mp_base_t = intBtw (2, 36+1) // for outputing MP numbers (* ****** ****** *) // // integral number operations // (* ****** ****** *) // [x] is initialized with 0 fun mpz_init (x: &mpz_vt? >> mpz_vt):<> void = "mac#atslib_mpz_init" // macro! // end of [mpz_init] // [x] is initialized with 0 while given [n]-bit space fun mpz_init2 (x: &mpz_vt? >> mpz_vt, n: ulint) :<> void = "mac#atslib_mpz_init2" // end of [mpz_init2] // [x] is cleared fun mpz_clear (x: &mpz_vt >> mpz_vt?):<> void = "mac#atslib_mpz_clear" // macro! // end of [mpz_clear] // [x] is reallocated; the original value of [x] is carried over // if there is enough space or 0 is assigned to [x] fun mpz_realloc2 (x: &mpz_vt >> mpz_vt, n: ulint):<> void = "mac#atslib_mpz_realloc2" // end of [mpz_realloc2] (* ****** ****** *) symintr mpz_get fun mpz_get_int (x: &mpz_vt):<> int = "mac#atslib_mpz_get_int" overload mpz_get with mpz_get_int fun mpz_get_uint (x: &mpz_vt):<> uint = "mac#atslib_mpz_get_uint" overload mpz_get with mpz_get_uint fun mpz_get_lint (x: &mpz_vt):<> lint = "mac#atslib_mpz_get_lint" overload mpz_get with mpz_get_lint fun mpz_get_ulint (x: &mpz_vt):<> ulint = "mac#atslib_mpz_get_ulint" overload mpz_get with mpz_get_ulint fun mpz_get_double (x: &mpz_vt):<> double = "mac#atslib_mpz_get_double" overload mpz_get with mpz_get_double fun mpz_get_str // HX: a special case of the original namesake in GMP (base: mp_base_t, x: &mpz_vt):<> strptr1 = "atslib_mpz_get_str" // fun! // end of [mpz_get_str] (* ****** ****** *) symintr mpz_set // x := y fun mpz_set_mpz (x: &mpz_vt, y: &mpz_vt):<> void = "mac#atslib_mpz_set_mpz" overload mpz_set with mpz_set_mpz fun mpz_set_int (x: &mpz_vt, y: int):<> void = "mac#atslib_mpz_set_int" overload mpz_set with mpz_set_int fun mpz_set_uint (x: &mpz_vt, y: uint):<> void = "mac#atslib_mpz_set_uint" overload mpz_set with mpz_set_uint fun mpz_set_lint (x: &mpz_vt, y: lint):<> void = "mac#atslib_mpz_set_lint" overload mpz_set with mpz_set_lint fun mpz_set_ulint (x: &mpz_vt, y: ulint):<> void = "mac#atslib_mpz_set_ulint" overload mpz_set with mpz_set_ulint fun mpz_set_double (x: &mpz_vt, y: double):<> void = "mac#atslib_mpz_set_double" overload mpz_set with mpz_set_double fun mpz_set_mpq (x: &mpz_vt, y: &mpq_vt):<> void = "mac#atslib_mpz_set_mpq" overload mpz_set with mpz_set_mpq fun mpz_set_mpf (x: &mpz_vt, y: &mpf_vt):<> void = "mac#atslib_mpz_set_mpf" overload mpz_set with mpz_set_mpf // // HX: the function returns 0 if the string is valid, or -1 otherwise. // fun mpz_set_str (x: &mpz_vt, s: string, base: mp_base_t):<> int = "mac#atslib_mpz_set_str" // macro // end of [mpz_set_str] fun mpz_set_str_exn (x: &mpz_vt, s: string, base: mp_base_t):<> void = "atslib_mpz_set_str_exn" // fun! // end of [mpz_set_str_exn] (* ****** ****** *) symintr mpz_init_set // x := y fun mpz_init_set_mpz (x: &mpz_vt? >> mpz_vt, y: &mpz_vt):<> void = "mac#atslib_mpz_init_set_mpz" overload mpz_init_set with mpz_init_set_mpz fun mpz_init_set_int (x: &mpz_vt? >> mpz_vt, y: int):<> void = "mac#atslib_mpz_init_set_int" overload mpz_init_set with mpz_init_set_int fun mpz_init_set_uint (x: &mpz_vt? >> mpz_vt, y: uint):<> void = "mac#atslib_mpz_init_set_uint" overload mpz_init_set with mpz_init_set_uint fun mpz_init_set_lint (x: &mpz_vt? >> mpz_vt, y: lint):<> void = "mac#atslib_mpz_init_set_lint" overload mpz_init_set with mpz_init_set_lint fun mpz_init_set_ulint (x: &mpz_vt? >> mpz_vt, y: ulint):<> void = "mac#atslib_mpz_init_set_ulint" overload mpz_init_set with mpz_init_set_ulint fun mpz_init_set_double (x: &mpz_vt? >> mpz_vt, y: double):<> void = "mac#atslib_mpz_init_set_double" overload mpz_init_set with mpz_init_set_double fun mpz_init_set_mpq (x: &mpz_vt? >> mpz_vt, y: &mpq_vt):<> void = "atslib_mpz_init_set_mpq" // fun! overload mpz_init_set with mpz_init_set_mpq fun mpz_init_set_mpf (x: &mpz_vt? >> mpz_vt, y: &mpf_vt):<> void = "atslib_mpz_init_set_mpf" // fun! overload mpz_init_set with mpz_init_set_mpf // // the function returns 0 if the string is valid, or -1 otherwise. // fun mpz_init_set_str (x: &mpz_vt? >> mpz_vt, s: string, base: mp_base_t):<> int = "mac#atslib_mpz_init_set_str" // macro! // end of [// end of [mpz_init_set_str] // the function exits the string is invalid. fun mpz_init_set_str_exn (x: &mpz_vt? >> mpz_vt, s: string, base: mp_base_t):<> void = "atslib_mpz_init_set_str_exn" // function! // end of [mpz_init_set_str_exn] (* ****** ****** *) fun mpz_swap (dst1: &mpz_vt, dst2: &mpz_vt): void = "mac#atslib_mpz_swap" (* ****** ****** *) fun mpz_odd_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_odd_p" fun mpz_even_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_even_p" fun mpz_fits_int_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_int_p" fun mpz_fits_uint_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_uint_p" fun mpz_fits_lint_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_lint_p" fun mpz_fits_ulint_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_ulint_p" fun mpz_fits_sint_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_sint_p" fun mpz_fits_usint_p (src: &mpz_vt):<> bool = "mac#atslib_mpz_fits_usint_p" fun mpz_size (src: &mpz_vt): size_t = "mac#atslib_mpz_size" fun mpz_sizeinbase (src: &mpz_vt, base: mp_base_t): size_t = "mac#atslib_mpz_sizeinbase" (* ****** ****** *) // negation symintr mpz_neg // x := -y fun mpz_neg2 (x: &mpz_vt, y: &mpz_vt):<> void = "mac#atslib_mpz_neg2" overload mpz_neg with mpz_neg2 // x := -x fun mpz_neg1 (x: &mpz_vt):<> void = "atslib_mpz_neg1" // function! overload mpz_neg with mpz_neg1 // absolute value symintr mpz_abs // x := | y | fun mpz_abs2 (x: &mpz_vt, y: &mpz_vt):<> void = "mac#atslib_mpz_abs2" overload mpz_abs with mpz_abs2 // x := | x | fun mpz_abs1 (x: &mpz_vt):<> void = "atslib_mpz_abs1" // function! overload mpz_abs with mpz_abs1 // addition symintr mpz_add // x := y + z fun mpz_add3_mpz (x: &mpz_vt, y: &mpz_vt, z: &mpz_vt):<> void = "mac#atslib_mpz_add3_mpz" overload mpz_add with mpz_add3_mpz fun mpz_add3_int (x: &mpz_vt, y: &mpz_vt, z: int):<> void = "mac#atslib_mpz_add3_int" overload mpz_add with mpz_add3_int fun mpz_add3_uint (x: &mpz_vt, y: &mpz_vt, z: uint):<> void = "mac#atslib_mpz_add3_uint" overload mpz_add with mpz_add3_uint fun mpz_add3_lint (x: &mpz_vt, y: &mpz_vt, z: lint):<> void = "atslib_mpz_add3_lint" // fun! overload mpz_add with mpz_add3_lint fun mpz_add3_ulint (x: &mpz_vt, y: &mpz_vt, z: ulint):<> void = "mac#atslib_mpz_add3_ulint" overload mpz_add with mpz_add3_ulint // x := x + y fun mpz_add2_mpz (x: &mpz_vt, y: &mpz_vt):<> void = "atslib_mpz_add2_mpz" overload mpz_add with mpz_add2_mpz fun mpz_add2_int (x: &mpz_vt, y: int):<> void = "mac#atslib_mpz_add2_int" // !macro overload mpz_add with mpz_add2_int fun mpz_add2_uint (x: &mpz_vt, y: uint):<> void = "mac#atslib_mpz_add2_uint" // !macro overload mpz_add with mpz_add2_uint fun mpz_add2_lint (x: &mpz_vt, y: lint):<> void = "atslib_mpz_add2_lint" overload mpz_add with mpz_add2_lint fun mpz_add2_ulint (x: &mpz_vt, y: ulint):<> void = "atslib_mpz_add2_ulint" overload mpz_add with mpz_add2_ulint // subtraction symintr mpz_sub // x := y - z fun mpz_sub3_mpz (x: &mpz_vt, y: &mpz_vt, z: &mpz_vt):<> void = "mac#atslib_mpz_sub3_mpz" overload mpz_sub with mpz_sub3_mpz fun mpz_sub3_int (x: &mpz_vt, y: &mpz_vt, z: int):<> void = "mac#atslib_mpz_sub3_int" overload mpz_sub with mpz_sub3_int fun mpz_sub3_uint (x: &mpz_vt, y: &mpz_vt, z: uint):<> void = "mac#atslib_mpz_sub3_uint" overload mpz_sub with mpz_sub3_uint fun mpz_sub3_lint (x: &mpz_vt, y: &mpz_vt, z: lint):<> void = "atslib_mpz_sub3_lint" // fun! overload mpz_sub with mpz_sub3_lint fun mpz_sub3_ulint (x: &mpz_vt, y: &mpz_vt, z: ulint):<> void = "mac#atslib_mpz_sub3_ulint" overload mpz_sub with mpz_sub3_ulint fun mpz_ui_sub3 (dst: &mpz_vt, src1: ulint, src2: &mpz_vt): void = "mac#atslib_mpz_ui_sub3" // end of [mpz_ui_sub3] // HX: no overloading for this one // x := x - y fun mpz_sub2_mpz (x: &mpz_vt, y: &mpz_vt):<> void = "atslib_mpz_sub2_mpz" overload mpz_sub with mpz_sub2_mpz fun mpz_sub2_int (x: &mpz_vt, y: int):<> void = "mac#atslib_mpz_sub2_int" // !macro overload mpz_sub with mpz_sub2_int fun mpz_sub2_uint (x: &mpz_vt, y: uint):<> void = "mac#atslib_mpz_sub2_uint" // !macro overload mpz_sub with mpz_sub2_uint fun mpz_sub2_lint (x: &mpz_vt, y: lint):<> void = "atslib_mpz_sub2_lint" overload mpz_sub with mpz_sub2_lint fun mpz_sub2_ulint (x: &mpz_vt, y: ulint):<> void = "atslib_mpz_sub2_ulint" overload mpz_sub with mpz_sub2_ulint (* ****** ****** *) // multiplication symintr mpz_mul // x := y * z fun mpz_mul3_mpz (x: &mpz_vt, y: &mpz_vt, z: &mpz_vt):<> void = "mac#atslib_mpz_mul3_mpz" overload mpz_mul with mpz_mul3_mpz fun mpz_mul3_int (x: &mpz_vt, y: &mpz_vt, z: int):<> void = "mac#atslib_mpz_mul3_int" overload mpz_mul with mpz_mul3_int fun mpz_mul3_uint (x: &mpz_vt, y: &mpz_vt, z: uint):<> void = "mac#atslib_mpz_mul3_uint" overload mpz_mul with mpz_mul3_uint fun mpz_mul3_lint (x: &mpz_vt, y: &mpz_vt, z: lint):<> void = "mac#atslib_mpz_mul3_lint" overload mpz_mul with mpz_mul3_lint fun mpz_mul3_ulint (x: &mpz_vt, y: &mpz_vt, z: ulint):<> void = "mac#atslib_mpz_mul3_ulint" overload mpz_mul with mpz_mul3_ulint // x := x * y fun mpz_mul2_mpz (x: &mpz_vt, y: &mpz_vt):<> void = "atslib_mpz_mul2_mpz" overload mpz_mul with mpz_mul2_mpz fun mpz_mul2_int (x: &mpz_vt, y: int):<> void = "mac#atslib_mpz_mul2_int" // !mac overload mpz_mul with mpz_mul2_int fun mpz_mul2_uint (x: &mpz_vt, y: uint):<> void = "mac#atslib_mpz_mul2_uint" // !mac overload mpz_mul with mpz_mul2_uint fun mpz_mul2_lint (x: &mpz_vt, y: lint):<> void = "atslib_mpz_mul2_lint" overload mpz_mul with mpz_mul2_lint fun mpz_mul2_ulint (x: &mpz_vt, y: ulint):<> void = "atslib_mpz_mul2_ulint" overload mpz_mul with mpz_mul2_ulint // x := x * x fun mpz_mul1_mpz (x: &mpz_vt):<> void = "atslib_mpz_mul1_mpz" overload mpz_mul with mpz_mul1_mpz (* ****** ****** *) (* ** ** Author: Zhiqiang Ren (aren AT cs DOT bu DOT edu) ** ** Function: mpz_mul_2exp ** Input: arg1, arg2 ** Output: res ** Return: void ** Description: Set res so that res = arg1 * (2 ^ arg2) ** Remarks: The same object can be passed for both res and arg1. ** Others: ** It's up to an application to call functions like mpz_mul_2exp when appropriate. ** General purpose functions like mpz_mul make no attempt to identify powers of two ** or other special forms. *) fun mpz_mul_2exp (res: &mpz_vt, arg1: &mpz_vt, arg2: ulint):<> void = "mac#atslib_mpz_mul_2exp" // end of [mpz_mul_2exp] (* ****** ****** *) // // integer truncate division // symintr mpz_tdiv_qr // (q, r) = n / d fun mpz_tdiv4_qr_mpz (q: &mpz_vt, r: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_tdiv4_qr_mpz" // end of [mpz_tdiv4_qr_mpz] overload mpz_tdiv_qr with mpz_tdiv4_qr_mpz // (q, r) = n / d fun mpz_tdiv4_qr_ulint (q: &mpz_vt, r: &mpz_vt, n: &mpz_vt, d: ulint):<> void = "mac#atslib_mpz_tdiv4_qr_ulint" // end of [mpz_tdiv4_qr_ulint] overload mpz_tdiv_qr with mpz_tdiv4_qr_ulint symintr mpz_tdiv_q // [q] := [n] / [d] fun mpz_tdiv3_q_mpz (q: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_tdiv3_q_mpz" overload mpz_tdiv_q with mpz_tdiv3_q_mpz // [q] := [n] / [d] fun mpz_tdiv3_q_ulint (q: &mpz_vt, n: &mpz_vt, d: ulint):<> void = "mac#atslib_mpz_tdiv3_q_ulint" overload mpz_tdiv_q with mpz_tdiv3_q_ulint // [q] := [q] / [d] fun mpz_tdiv2_q_mpz (q: &mpz_vt, d: &mpz_vt):<> void = "atslib_mpz_tdiv2_q_mpz" overload mpz_tdiv_q with mpz_tdiv2_q_mpz // [q] := [q] / [d] fun mpz_tdiv2_q_ulint (q: &mpz_vt, d: ulint):<> void = "atslib_mpz_tdiv2_q_ulint" overload mpz_tdiv_q with mpz_tdiv2_q_ulint (* ****** ****** *) // // integer floor division // (* ** ** Author: Zhiqiang Ren (aren AT cs DOT bu DOT edu) ** ** Function: mpz_fdiv_qr ** Input: dividend, divisor ** Output: quot, rem ** Return: void ** Description: ** Set quot and rem so that dividend = quot * divisor + rem ** Rounds quot down towards negative infinity, and rem will ** have the same sign as divisor, and 0 <= |rem| < |divisor|. ** 'f' stands for "floor". e.g. 5 = (-2) * (-3) + (-1); -5 = 1 * (-3) + (-2) ** Remarks: ** The same object cannot be passed for both quot and rem, or the result will be ** unpredictable. No other constraints on the pass of other arguments, e.g. the same ** object can be passed to both quot and dividend. *) symintr mpz_fdiv_qr fun mpz_fdiv4_qr_mpz (quot: &mpz_vt, rem: &mpz_vt, dividend: &mpz_vt, divisor: &mpz_vt):<> void = "mac#atslib_mpz_fdiv4_qr_mpz" overload mpz_fdiv_qr with mpz_fdiv4_qr_mpz fun mpz_fdiv4_qr_ulint (quot: &mpz_vt, rem: &mpz_vt, dividend: &mpz_vt, divisor: ulint):<> ulint = "mac#atslib_mpz_fdiv4_qr_ulint" overload mpz_fdiv_qr with mpz_fdiv4_qr_ulint symintr mpz_fdiv_q // [q] := [n] / [d] fun mpz_fdiv3_q_mpz (q: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_fdiv3_q_mpz" overload mpz_fdiv_q with mpz_fdiv3_q_mpz fun mpz_fdiv3_q_ulint (q: &mpz_vt, n: &mpz_vt, d: ulint):<> ulint = "mac#atslib_mpz_fdiv3_q_ulint" overload mpz_fdiv_q with mpz_fdiv3_q_ulint fun mpz_fdiv2_q_mpz (q: &mpz_vt, d: &mpz_vt):<> void = "atslib_mpz_fdiv2_q_mpz" overload mpz_fdiv_q with mpz_fdiv2_q_mpz fun mpz_fdiv2_q_ulint (q: &mpz_vt, d: ulint):<> ulint = "atslib_mpz_fdiv2_q_ulint" overload mpz_fdiv_q with mpz_fdiv2_q_ulint symintr mpz_fdiv_r fun mpz_fdiv3_r_mpz (r: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_fdiv3_r_mpz" overload mpz_fdiv_r with mpz_fdiv3_r_mpz fun mpz_fdiv3_r_ulint (r: &mpz_vt, n: &mpz_vt, d: ulint):<> ulint = "mac#atslib_mpz_fdiv3_r_ulint" overload mpz_fdiv_r with mpz_fdiv3_r_ulint fun mpz_fdiv2_r_mpz (r: &mpz_vt, d: &mpz_vt):<> void = "atslib_mpz_fdiv2_r_mpz" overload mpz_fdiv_r with mpz_fdiv2_r_mpz fun mpz_fdiv2_r_ulint (r: &mpz_vt, d: ulint):<> ulint = "atslib_mpz_fdiv2_r_ulint" overload mpz_fdiv_r with mpz_fdiv2_r_ulint (* ****** ****** *) symintr mpz_mod fun mpz_mod3_mpz (r: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_mod3_mpz" overload mpz_mod with mpz_mod3_mpz fun mpz_mod2_mpz (n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_mod2_mpz" overload mpz_mod with mpz_mod2_mpz fun mpz_mod3_ulint (r: &mpz_vt, n: &mpz_vt, d: ulint):<> ulint = "mac#atslib_mpz_mod3_ulint" overload mpz_mod with mpz_mod3_ulint fun mpz_mod2_ulint (n: &mpz_vt, d: ulint):<> ulint = "mac#atslib_mpz_mod2_ulint" overload mpz_mod with mpz_mod2_ulint (* ****** ****** *) // // HX-2010-08-11: // this one is much faster but it needs a proof that n is a multiple of d // symintr mpz_divexact fun mpz_divexact3 // q := n/d (q: &mpz_vt, n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_divexact3" overload mpz_divexact with mpz_divexact3 fun mpz_divexact2 // n := n/d (n: &mpz_vt, d: &mpz_vt):<> void = "mac#atslib_mpz_divexact2" overload mpz_divexact with mpz_divexact2 (* ****** ****** *) // // HX: n = 0 mod (d) // fun mpz_divisible_p (n: &mpz_vt, d: &mpz_vt):<> int = "mac#atslib_mpz_divisible_p" fun mpz_divisible_ui_p (n: &mpz_vt, d: ulint):<> int = "mac#atslib_mpz_divisible_ui_p" // // HX: n = c mod (d) // fun mpz_congruent_p (n: &mpz_vt, c: &mpz_vt, d: &mpz_vt):<> int = "mac#atslib_mpz_congruent_p" fun mpz_congruent_ui_p (n: &mpz_vt, c: ulint, d: ulint):<> int = "mac#atslib_mpz_congruent_ui_p" (* ****** ****** *) symintr mpz_tdiv_q_2exp fun mpz_tdiv3_q_2exp // dst = src1 tdiv src2 (dst: mpz_vt, src1: mpz_vt, src2: ulint): void = "mac#atslib_tdiv3_q_2exp" overload mpz_tdiv_q_2exp with mpz_tdiv3_q_2exp symintr mpz_tdiv_r_2exp fun mpz_tdiv3_r_2exp // dst = src1 tmod src2 (dst: mpz_vt, src1: mpz_vt, src2: ulint): void = "mac#atslib_tdiv3_r_2exp" overload mpz_tdiv_r_2exp with mpz_tdiv3_r_2exp symintr mpz_fdiv_q_2exp fun mpz_fdiv3_q_2exp // dst := src1 fdiv src2 (dst: mpz_vt, src1: mpz_vt, src2: ulint): void = "mac#atslib_fdiv3_q_2exp" overload mpz_fdiv_q_2exp with mpz_fdiv3_q_2exp symintr mpz_fdiv_r_2exp fun mpz_fdiv3_r_2exp // dst := src1 fmod src2 (dst: mpz_vt, src1: mpz_vt, src2: ulint): void = "mac#atslib_fdiv3_r_2exp" overload mpz_fdiv_r_2exp with mpz_fdiv3_r_2exp (* ****** ****** *) fun mpz_divisible_ui_2exp_p // n = 0 mod (2^b) (n: &mpz_vt, b: ulint):<> int = "mac#atslib_mpz_divisible_ui_2exp_p" // end of [mpz_divisible_ui_2exp_p] fun mpz_congruent_ui_2exp_p // n = c mod (2^b) (n: &mpz_vt, c: &mpz_vt, b: ulint):<> int = "mac#atslib_mpz_congruent_ui_2exp_p" // end of [mpz_congruent_ui_2exp_p] (* ****** ****** *) symintr mpz_sqrt fun mpz_sqrt2 // dst := sqrt (src) (dst: &mpz_vt, src: &mpz_vt): void = "mac#atslib_mpz_sqrt2" overload mpz_sqrt with mpz_sqrt2 fun mpz_sqrt1 (dst: &mpz_vt): void = "atslib_mpz_sqrt1" // !function overload mpz_sqrt with mpz_sqrt1 symintr mpz_sqrtrem fun mpz_sqrtrem3 (dst1: &mpz_vt, dst2: &mpz_vt, src: &mpz_vt): void = "mac#atslib_mpz_sqrtrem3" overload mpz_sqrtrem with mpz_sqrtrem3 fun mpz_perfect_square_p (src: &mpz_vt): int = "mac#atslib_mpz_perfect_square_p" (* ****** ****** *) symintr mpz_powm fun mpz_powm4_mpz (dst: &mpz_vt, base: &mpz_vt, exp: &mpz_vt, mod: &mpz_vt): void = "mac#atslib_mpz_powm4_mpz" overload mpz_powm with mpz_powm4_mpz fun mpz_powm4_ui (dst: &mpz_vt, base: &mpz_vt, exp: ulint, mod: &mpz_vt): void = "mac#atslib_mpz_powm4_ui" overload mpz_powm with mpz_powm4_ui (* ****** ****** *) symintr mpz_pow_ui fun mpz_pow3_ui (dst: &mpz_vt, src1: &mpz_vt, src2: ulint): void = "mac#atslib_mpz_pow3_ui" overload mpz_pow_ui with mpz_pow3_ui fun mpz_pow2_ui (dst: &mpz_vt, src2: ulint): void = "atslib_mpz_pow2_ui" // !fun overload mpz_pow_ui with mpz_pow2_ui (* ****** ****** *) // add/mul combination symintr mpz_addmul fun mpz_addmul3_mpz (x: &mpz_vt, y: &mpz_vt, z: &mpz_vt):<> void = "mac#atslib_mpz_addmul3_mpz" overload mpz_addmul with mpz_addmul3_mpz fun mpz_addmul3_uint (x: &mpz_vt, y: &mpz_vt, z: uint):<> void = "mac#atslib_mpz_addmul3_uint" overload mpz_addmul with mpz_addmul3_uint fun mpz_addmul3_ulint (x: &mpz_vt, y: &mpz_vt, z: ulint):<> void = "mac#atslib_mpz_addmul3_ulint" overload mpz_addmul with mpz_addmul3_ulint // sub/mul combination symintr mpz_submul fun mpz_submul3_mpz (x: &mpz_vt, y: &mpz_vt, z: &mpz_vt):<> void = "mac#atslib_mpz_submul3_mpz" overload mpz_submul with mpz_submul3_mpz fun mpz_submul3_uint (x: &mpz_vt, y: &mpz_vt, z: uint):<> void = "mac#atslib_mpz_submul3_uint" overload mpz_submul with mpz_submul3_uint fun mpz_submul3_ulint (x: &mpz_vt, y: &mpz_vt, z: ulint):<> void = "mac#atslib_mpz_submul3_ulint" overload mpz_submul with mpz_submul3_ulint (* ****** ****** *) // comparison functions symintr mpz_cmp fun mpz_cmp_mpz (x: &mpz_vt, y: &mpz_vt):<> int = "mac#atslib_mpz_cmp_mpz" overload mpz_cmp with mpz_cmp_mpz fun mpz_cmp_int (x: &mpz_vt, y: int):<> int = "mac#atslib_mpz_cmp_int" overload mpz_cmp with mpz_cmp_int fun mpz_cmp_uint (x: &mpz_vt, y: uint):<> int = "mac#atslib_mpz_cmp_uint" overload mpz_cmp with mpz_cmp_uint fun mpz_cmp_lint (x: &mpz_vt, y: lint):<> int = "mac#atslib_mpz_cmp_lint" overload mpz_cmp with mpz_cmp_lint fun mpz_cmp_ulint (x: &mpz_vt, y: ulint):<> int = "mac#atslib_mpz_cmp_ulint" overload mpz_cmp with mpz_cmp_ulint fun mpz_cmp_double (x: &mpz_vt, y: double):<> int = "mac#atslib_mpz_cmp_double" overload mpz_cmp with mpz_cmp_double symintr mpz_cmpabs fun mpz_cmpabs_mpz (x: &mpz_vt, y: &mpz_vt):<> int = "mac#atslib_mpz_cmpabs_mpz" overload mpz_cmpabs with mpz_cmpabs_mpz fun mpz_cmpabs_uint (x: &mpz_vt, y: uint):<> int = "mac#atslib_mpz_cmpabs_uint" overload mpz_cmpabs with mpz_cmpabs_uint fun mpz_cmpabs_ulint (x: &mpz_vt, y: ulint):<> int = "mac#atslib_mpz_cmpabs_ulint" overload mpz_cmpabs with mpz_cmpabs_ulint fun mpz_cmpabs_double (x: &mpz_vt, y: double):<> int = "mac#atslib_mpz_cmpabs_double" overload mpz_cmpabs with mpz_cmpabs_double (* ****** ****** *) fun mpz_sgn (x: &mpz_vt):<> Sgn = "mac#atslib_mpz_sgn" (* ****** ****** *) symintr mpz_gcd fun mpz_gcd3_mpz ( dst: &mpz_vt, src1: &mpz_vt, src2: &mpz_vt ) :<> void = "mac#atslib_mpz_gcd3_mpz" // end of [fun] overload mpz_gcd with mpz_gcd3_mpz fun mpz_gcd2_mpz (dst: &mpz_vt, src2: &mpz_vt):<> void = "mac#atslib_mpz_gcd2_mpz" overload mpz_gcd with mpz_gcd2_mpz fun mpz_gcd3_ui ( dst: &mpz_vt, src1: &mpz_vt, src2: ulint ) :<> ulint = "mac#atslib_mpz_gcd3_ui" // end of [fun] overload mpz_gcd with mpz_gcd3_ui fun mpz_gcd2_ui (dst: &mpz_vt, src2: ulint):<> ulint = "mac#atslib_mpz_gcd2_ui" overload mpz_gcd with mpz_gcd2_ui fun mpz_gcdext // for given a and b, g, s and t are computed s.t. g = a*s + b*t (g: &mpz_vt, s: &mpz_vt, t: &mpz_vt, a: &mpz_vt, b: &mpz_vt) : void = "mac#atslib_mpz_gcdext" // end of [mpz_gcdext] (* ****** ****** *) symintr mpz_lcm fun mpz_lcm3_mpz (dst: &mpz_vt, src1: &mpz_vt, src2: &mpz_vt): void = "mac#atslib_mpz_lcm3_mpz" overload mpz_lcm with mpz_lcm3_mpz fun mpz_lcm2_mpz (dst: &mpz_vt, src2: &mpz_vt): void = "mac#atslib_mpz_lcm2_mpz" overload mpz_lcm with mpz_lcm2_mpz fun mpz_lcm3_ui (dst: &mpz_vt, src1: &mpz_vt, src2: ulint): void = "mac#atslib_mpz_lcm3_ui" overload mpz_lcm with mpz_lcm3_ui fun mpz_lcm2_ui (dst: &mpz_vt, src2: ulint): void = "mac#atslib_mpz_lcm2_ui" overload mpz_lcm with mpz_lcm2_ui (* ****** ****** *) symintr mpz_invert fun mpz_invert3 (dst: &mpz_vt, src1: &mpz_vt, src2: &mpz_vt): int = "mac#atslib_mpz_invert3" // end of [mpz_invert3] overload mpz_invert with mpz_invert3 (* ****** ****** *) // // various number-theoretic functions // symintr mpz_nextprime fun mpz_nextprime1 (dst: &mpz_vt): void = "mac#atslib_mpz_nextprime1" // !mac overload mpz_nextprime with mpz_nextprime1 fun mpz_nextprime2 (dst: &mpz_vt, src: &mpz_vt): void = "mac#atslib_mpz_nextprime2" overload mpz_nextprime with mpz_nextprime2 // HX: Note that jacobi (a, b) is only defined for b that is odd fun mpz_jacobi (a: &mpz_vt, b: &mpz_vt): int = "mac#atslib_mpz_jacobi" fun mpz_legendre (a: &mpz_vt, b: &mpz_vt): int = "mac#atslib_mpz_legendre" symintr mpz_kronecker fun mpz_kronecker_mpz (a: &mpz_vt, b: &mpz_vt): int = "mac#atslib_mpz_kronecker_mpz" overload mpz_kronecker with mpz_kronecker_mpz fun mpz_kronecker_si (a: &mpz_vt, b: lint): int = "mac#atslib_mpz_kronecker_si" overload mpz_kronecker with mpz_kronecker_si fun mpz_kronecker_ui (a: &mpz_vt, b: ulint): int = "mac#atslib_mpz_kronecker_ui" overload mpz_kronecker with mpz_kronecker_ui fun mpz_si_kronecker (a: lint, b: &mpz_vt): int = "mac#atslib_mpz_kronecker_si" fun mpz_ui_kronecker (a: ulint, b: &mpz_vt): int = "mac#atslib_mpz_kronecker_ui" fun mpz_fac_ui (x: &mpz_vt, n: ulint): void = "mac#atslib_mpz_fac_ui" symintr mpz_bin_ui fun mpz_bin3_ui (dst: &mpz_vt, n: &mpz_vt, k: ulint): void = "mac#atslib_mpz_bin3_ui" overload mpz_bin_ui with mpz_bin3_ui fun mpz_bin2_ui (dst: &mpz_vt, n: &mpz_vt, k: ulint): void = "mac#atslib_mpz_bin2_ui" overload mpz_bin_ui with mpz_bin2_ui fun mpz_bin_uiui (dst: &mpz_vt, n: ulint, k: ulint): void = "mac#atslib_mpz_bin_uiui" fun mpz_fib_ui (x: &mpz_vt, n: ulint): void = "mac#atslib_mpz_fib_ui" fun mpz_fib2_ui (x1: &mpz_vt, x2: &mpz_vt, n: ulint): void = "mac#atslib_mpz_fib2_ui" symintr mpz_remove fun mpz_remove3 (dst: &mpz_vt, src1: &mpz_vt, src2: &mpz_vt): void = "mac#atslib_mpz_remove3" overload mpz_remove with mpz_remove3 fun mpz_remove2 (dst: &mpz_vt, src2: &mpz_vt): void = "atslib_mpz_remove2" // !fun overload mpz_remove with mpz_remove2 (* ****** ****** *) // // some MPZ input/output/print functions // fun mpz_inp_str {m:file_mode} ( pf_mode: file_mode_lte (m, r) | x: &mpz_vt, file: &FILE m, base: mp_base_t ) : size_t = "mac#atslib_mpz_inp_str" // end of [mpz_inp_str] fun mpz_out_str {m:file_mode} ( pf_mode: file_mode_lte (m, w) | file: &FILE m, base: mp_base_t, x: &mpz_vt ) : size_t = "mac#atslib_mpz_out_str" // end of [mpz_out_str] fun fprint0_mpz (out: FILEref, x: &mpz_vt): void = "atslib_fprint_mpz" overload fprint with fprint0_mpz fun fprint1_mpz {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: &mpz_vt): void = "atslib_fprint_mpz" overload fprint with fprint1_mpz fun print_mpz (x: &mpz_vt) : void overload print with print_mpz fun prerr_mpz (x: &mpz_vt) : void overload prerr with prerr_mpz fun tostrptr_mpz (x: &mpz_vt):<> strptr1 overload tostrptr with tostrptr_mpz fun tostring_mpz (x: &mpz_vt):<> string overload tostring with tostring_mpz (* ****** ****** *) fun mpz_inp_raw {m:file_mode} ( pf_mode: file_mode_lte (m, r) | x: &mpz_vt, file: &FILE m ) : size_t = "mac#atslib_mpz_inp_raw" // returns 0 for error // end of [mpz_inp_raw] fun mpz_out_raw {m:file_mode} ( pf_mode: file_mode_lte (m, w) | file: &FILE m, x: &mpz_vt ) : size_t = "mac#atslib_mpz_out_raw" // returns 0 for error // end of [mpz_out_raw] (* ****** ****** *) // // // rational number operations // // (* ****** ****** *) fun mpq_canonicalize (x: &mpq_vt):<> void = "mac#atslib_mpq_canonicalize" (* ****** ****** *) // [x] is initialized with 0 fun mpq_init (x: &mpq_vt? >> mpq_vt):<> void = "mac#atslib_mpq_init" // macro! // end of [mpq_init] fun mpq_clear (x: &mpq_vt >> mpq_vt?): void = "mac#atslib_mpq_clear" (* ****** ****** *) fun mpq_get_d (src: &mpq_vt): double = "mac#atslib_mpq_get_d" fun mpq_get_num (dst: &mpz_vt, src: &mpq_vt):<> void = "mac#atslib_mpq_get_num" fun mpq_get_den (dst: &mpz_vt, src: &mpq_vt):<> void = "mac#atslib_mpq_get_den" fun mpq_get_str // HX: a special case of the original namesake in GMP (base: mp_base_t, x: &mpq_vt):<> strptr1 = "atslib_mpq_get_str" // fun! // end of [mpq_get_str] (* ****** ****** *) fun mpq_numref (dst: &mpq_vt) :<> [l:addr] (mpz_vt @ l, mpz_vt @ l - void | ptr l) = "mac#atslib_mpq_numref" fun mpq_denref (dst: &mpq_vt) :<> [l:addr] (mpz_vt @ l, mpz_vt @ l - void | ptr l) = "mac#atslib_mpq_denref" (* ****** ****** *) symintr mpq_set fun mpq_set_mpq (dst: &mpq_vt, src: &mpq_vt): void = "mac#atslib_mpq_set_mpq" overload mpq_set with mpq_set_mpq fun mpq_set_mpz (dst: &mpq_vt, src: &mpz_vt): void = "mac#atslib_mpq_set_mpz" overload mpq_set with mpq_set_mpz fun mpq_set_si (dst: &mpq_vt, src1: lint, src2: ulint): void = "mac#atslib_mpq_set_si" overload mpq_set with mpq_set_si fun mpq_set_ui (dst: &mpq_vt, src1: ulint, src2: ulint): void = "mac#atslib_mpq_set_ui" overload mpq_set with mpq_set_ui fun mpq_set_d (dst: &mpq_vt, src: double): void = "mac#atslib_mpq_set_d" overload mpq_set with mpq_set_d fun mpq_set_mpf (dst: &mpq_vt, src: &mpf_vt): void = "mac#atslib_mpq_set_mpf" overload mpq_set with mpq_set_mpf // HX: may need to call [mpq_canonicalize] fun mpq_set_num (dst: &mpq_vt, src: &mpz_vt):<> void = "mac#atslib_mpq_set_num" fun mpq_set_den (dst: &mpq_vt, src: &mpz_vt):<> void = "mac#atslib_mpq_set_den" (* ****** ****** *) symintr mpq_neg // x := -y fun mpq_neg2 (x: &mpq_vt, y: &mpq_vt):<> void = "mac#atslib_mpq_neg2" overload mpq_neg with mpq_neg2 // x := -x fun mpq_neg1 (x: &mpq_vt):<> void = "atslib_mpq_neg1" // function! overload mpq_neg with mpq_neg1 (* ****** ****** *) symintr mpq_inv // x := -y fun mpq_inv2 (x: &mpq_vt, y: &mpq_vt):<> void = "mac#atslib_mpq_inv2" overload mpq_inv with mpq_inv2 // x := -x fun mpq_inv1 (x: &mpq_vt):<> void = "atslib_mpq_inv1" // function! overload mpq_inv with mpq_inv1 (* ****** ****** *) symintr mpq_add fun mpq_add3_mpq (dst: &mpq_vt, src1: &mpq_vt, src2: &mpq_vt): void = "mac#atslib_mpq_add3_mpq" overload mpq_add with mpq_add3_mpq fun mpq_add2_mpq // dst := dst + src2 (dst: &mpq_vt, src2: &mpq_vt): void = "atslib_mpq_add2_mpq" // fun! overload mpq_add with mpq_add2_mpq symintr mpq_sub fun mpq_sub3_mpq (dst: &mpq_vt, src1: &mpq_vt, src2: &mpq_vt): void = "mac#atslib_mpq_sub3_mpq" overload mpq_sub with mpq_sub3_mpq fun mpq_sub2_mpq // dst := dst - src2 (dst: &mpq_vt, src2: &mpq_vt): void = "atslib_mpq_sub2_mpq" // fun! overload mpq_sub with mpq_sub2_mpq symintr mpq_mul fun mpq_mul3_mpq (dst: &mpq_vt, src1: &mpq_vt, src2: &mpq_vt): void = "mac#atslib_mpq_mul3_mpq" overload mpq_mul with mpq_mul3_mpq fun mpq_mul2_mpq // dst := dst * src2 (dst: &mpq_vt, src2: &mpq_vt): void = "atslib_mpq_mul2_mpq" // fun! overload mpq_mul with mpq_mul2_mpq symintr mpq_div fun mpq_div3_mpq (dst: &mpq_vt, src1: &mpq_vt, src2: &mpq_vt): void = "mac#atslib_mpq_div3_mpq" overload mpq_div with mpq_div3_mpq fun mpq_div2_mpq // dst := dst / src2 (dst: &mpq_vt, src2: &mpq_vt): void = "atslib_mpq_div2_mpq" // fun! overload mpq_div with mpq_div2_mpq (* ****** ****** *) // HX-2010-08-11: implemented in ATS // x := x + p/q fun mpq_incby (x: &mpq_vt, p: ulint, q: ulint): void // x := x - p/q fun mpq_decby (x: &mpq_vt, p: ulint, q: ulint): void (* ****** ****** *) // HX-2010-08-11: implemented in ATS symintr mpq_pow_ui fun mpq_pow3_ui (dst: &mpq_vt, src1: &mpq_vt, src2: ulint): void overload mpq_pow_ui with mpq_pow3_ui fun mpq_pow2_ui (dst: &mpq_vt, src2: ulint): void overload mpq_pow_ui with mpq_pow2_ui (* ****** ****** *) fun mpq_equal (src1: &mpq_vt, src2: &mpq_vt):<> bool = "mac#atslib_mpq_equal" // end of [mpq_equal] symintr mpq_cmp fun mpq_cmp_mpq (x: &mpq_vt, y: &mpq_vt):<> int = "mac#atslib_mpq_cmp_mpq" overload mpq_cmp with mpq_cmp_mpq fun mpq_cmp_uint (x: &mpq_vt, y: uint):<> int = "mac#atslib_mpq_cmp_uint" overload mpq_cmp with mpq_cmp_uint fun mpq_cmp_ulint (x: &mpq_vt, y: ulint):<> int = "mac#atslib_mpq_cmp_ulint" overload mpq_cmp with mpq_cmp_ulint (* ****** ****** *) fun mpq_sgn (x: &mpq_vt):<> Sgn = "mac#atslib_mpq_sgn" (* ****** ****** *) (* // // some MPQ input/output/print functions // *) fun mpq_inp_str {m:file_mode} ( pf_mode: file_mode_lte (m, r) | x: &mpq_vt, file: &FILE m, base: mp_base_t ) : size_t = "mac#atslib_mpq_inp_str" // end of [mpq_inp_str] fun mpq_out_str {m:file_mode} ( pf_mode: file_mode_lte (m, w) | file: &FILE m, base: mp_base_t, x: &mpq_vt ) : size_t = "mac#atslib_mpq_out_str" // end of [mpq_out_str] fun fprint0_mpq (out: FILEref, x: &mpq_vt): void = "atslib_fprint_mpq" overload fprint with fprint0_mpq fun fprint1_mpq {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: &mpq_vt): void = "atslib_fprint_mpq" overload fprint with fprint1_mpq fun print_mpq (x: &mpq_vt) : void overload print with print_mpq fun prerr_mpq (x: &mpq_vt) : void overload prerr with prerr_mpq (* ****** ****** *) // // // floating number operations // // (* ****** ****** *) // // HX-2010-07-28: [mpf_set_default_prec] is used to make sure that // sta mpf_set_default_prec : bool // [mpf_set_default_prec] is called fun mpf_get_default_prec {mpf_set_default_prec} (): ulint = "mac#atslib_mpf_get_default_prec" // end of [mpf_get_default_prec] fun mpf_set_default_prec (prec: ulint): [mpf_set_default_prec] void = "mac#atslib_mpf_set_default_prec" // end of [mpf_set_default_prec] (* ****** ****** *) // // HX-2010-07-28: // [mpf_init] must be called after [mpf_set_default_prec] is called // fun mpf_init {mpf_set_default_prec} (x: &mpf_vt? >> mpf_vt):<> void = "mac#atslib_mpf_init" // end of [mpf_init] fun mpf_init2 (x: &mpf_vt? >> mpf_vt, prec: ulint): void = "mac#atslib_mpf_init2" // end of [mpf_init2] fun mpf_clear (x: &mpf_vt >> mpf_vt?): void = "mac#atslib_mpf_clear" (* ****** ****** *) fun mpf_get_prec (x: &mpf_vt): ulint = "mac#atslib_mpf_get_prec" fun mpf_set_prec (x: &mpf_vt, prec: ulint): void = "mac#atslib_mpf_set_prec" fun mpf_set_prec_raw // HX: a low-level function (dst: &mpf_vt, prec: ulint): void = "mac#atslib_mpf_set_prec_raw" // end of [mpf_set_prec_raw] (* ****** ****** *) fun mpf_get_d (src: &mpf_vt): double = "mac#atslib_mpf_get_d" fun mpf_get_d_2exp (exp: &lint, src: &mpf_vt): double = "mac#atslib_mpf_get_d_2exp" fun mpf_get_si (src: &mpf_vt): lint = "mac#atslib_mpf_get_si" fun mpf_get_ui (src: &mpf_vt): ulint = "mac#atslib_mpf_get_ui" fun mpf_get_str ( // HX: a special case of the original namesake in GMP exp: &mp_exp_t? >> mp_exp_t, base: mp_base_t, ndigit: size_t, x: &mpf_vt ) : strptr1 = "atslib_mpf_get_str" // function! // end of [mpf_get_str] (* ****** ****** *) symintr mpf_set fun mpf_set_mpf (dst: &mpf_vt, src: &mpf_vt): void = "mac#atslib_mpf_set_mpf" overload mpf_set with mpf_set_mpf fun mpf_set_mpz (dst: &mpf_vt, src: &mpz_vt): void = "mac#atslib_mpf_set_mpz" overload mpf_set with mpf_set_mpz fun mpf_set_si (dst: &mpf_vt, src: lint): void = "mac#atslib_mpf_set_si" overload mpf_set with mpf_set_si fun mpf_set_ui (dst: &mpf_vt, src: ulint): void = "mac#atslib_mpf_set_ui" overload mpf_set with mpf_set_ui fun mpf_set_mpq (dst: &mpf_vt, src: &mpq_vt): void = "mac#atslib_mpf_set_mpq" overload mpf_set with mpf_set_mpq fun mpf_set_d (dst: &mpf_vt, src: double): void = "mac#atslib_mpf_set_d" overload mpf_set with mpf_set_d // // HX: the function returns 0 if the string is valid, or -1 otherwise. // fun mpf_set_str // succ/fail: 0/-1 (dst: &mpf_vt, str: string, base: int): int = "mac#atslib_mpf_set_str" overload mpf_set with mpf_set_str fun mpf_set_str_exn (dst: &mpf_vt, str: string, base: int): void = "atslib_mpf_set_str_exn" // !fun // end of [mpf_set_str_exn] (* ****** ****** *) symintr mpf_init_set // dst := src fun mpf_init_set_mpf {mpf_set_default_prec} (dst: &mpf_vt? >> mpf_vt, src: &mpf_vt): void = "mac#atslib_mpf_init_set_mpf" overload mpf_init_set with mpf_init_set_mpf fun mpf_init_set_si {mpf_set_default_prec} (dst: &mpf_vt? >> mpf_vt, src: lint): void = "mac#atslib_mpf_init_set_si" overload mpf_init_set with mpf_init_set_si fun mpf_init_set_ui {mpf_set_default_prec} (dst: &mpf_vt? >> mpf_vt, src: ulint): void = "mac#atslib_mpf_init_set_ui" overload mpf_init_set with mpf_init_set_ui fun mpf_init_set_d {mpf_set_default_prec} (dst: &mpf_vt? >> mpf_vt, src: double): void = "mac#atslib_mpf_init_set_d" overload mpf_init_set with mpf_init_set_d fun mpf_init_set_str {mpf_set_default_prec} (rop: &mpf_vt? >> mpf_vt, str: string, base: int): int(*err*) = "mac#atslib_mpf_init_set_str" // macro overload mpf_init_set with mpf_init_set_str (* ****** ****** *) fun mpf_swap (dst1: &mpf_vt, dst2: &mpf_vt): void = "mac#atslib_mpf_swap" (* ****** ****** *) fun mpf_ceil (dst: &mpf_vt, src: &mpf_vt):<> void = "mac#atslib_mpf_ceil" fun mpf_floor (dst: &mpf_vt, src: &mpf_vt):<> void = "mac#atslib_mpf_floor" fun mpf_trunc (dst: &mpf_vt, src: &mpf_vt):<> void = "mac#atslib_mpf_trunc" fun mpf_integer_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_integer_p" fun mpf_int_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_int_p" fun mpf_uint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_uint_p" fun mpf_lint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_lint_p" fun mpf_ulint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_ulint_p" fun mpf_sint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_sint_p" fun mpf_usint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_usint_p" fun mpf_fits_int_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_int_p" fun mpf_fits_uint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_uint_p" fun mpf_fits_lint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_lint_p" fun mpf_fits_ulint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_ulint_p" fun mpf_fits_sint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_sint_p" fun mpf_fits_usint_p (src: &mpf_vt):<> bool = "mac#atslib_mpf_fits_usint_p" (* ****** ****** *) symintr mpf_neg // x := -y fun mpf_neg2 (x: &mpf_vt, y: &mpf_vt): void = "mac#atslib_mpf_neg2" overload mpf_neg with mpf_neg2 // x := -x fun mpf_neg1 (x: &mpf_vt): void = "atslib_mpf_neg1" // !function overload mpf_neg with mpf_neg1 (* ****** ****** *) symintr mpf_abs // x := |y| fun mpf_abs2 (x: &mpf_vt, y: &mpf_vt): void = "mac#atslib_mpf_abs2" overload mpf_abs with mpf_abs2 // x := |x| fun mpf_abs1 (x: &mpf_vt): void = "atslib_mpf_abs1" // !function overload mpf_abs with mpf_abs1 (* ****** ****** *) symintr mpf_add fun mpf_add3_mpf (dst: &mpf_vt, src1: &mpf_vt, src2: &mpf_vt): void = "mac#atslib_mpf_add3_mpf" overload mpf_add with mpf_add3_mpf fun mpf_add3_ui (dst: &mpf_vt, src1: &mpf_vt, src2: ulint): void = "mac#atslib_mpf_add3_ui" overload mpf_add with mpf_add3_ui fun mpf_add2_mpf (dst: &mpf_vt, src: &mpf_vt): void = "atslib_mpf_add2_mpf" // fun! overload mpf_add with mpf_add2_mpf fun mpf_add2_ui (dst: &mpf_vt, src: ulint): void = "atslib_mpf_add2_ui" // fun! overload mpf_add with mpf_add2_ui (* ****** ****** *) symintr mpf_sub fun mpf_sub3_mpf (dst: &mpf_vt, src1: &mpf_vt, src2: &mpf_vt): void = "mac#atslib_mpf_sub_mpf" overload mpf_sub with mpf_sub3_mpf fun mpf_sub3_ui (dst: &mpf_vt, src1: &mpf_vt, src2: ulint): void = "mac#atslib_mpf_sub3_ui" overload mpf_sub with mpf_sub3_ui fun mpf_ui_sub3 (dst: &mpf_vt, src1: ulint, src2: &mpf_vt): void = "mac#atslib_mpf_ui_sub3" // end of [mpf_ui_sub3] fun mpf_sub2_mpf (dst: &mpf_vt, src2: &mpf_vt): void = "atslib_mpf_sub2" // !fun overload mpf_sub with mpf_sub2_mpf fun mpf_sub2_ui (dst: &mpf_vt, src2: ulint): void = "atslib_mpf_sub2_ui" // !fun overload mpf_sub with mpf_sub2_ui // HX-2010-08-08: no overloading for this one fun mpf_ui_sub2 (dst: &mpf_vt, src1: ulint): void = "atslib_mpf_ui_sub2" // !fun (* ****** ****** *) symintr mpf_mul fun mpf_mul3_mpf (dst: &mpf_vt, src1: &mpf_vt, src2: &mpf_vt): void = "mac#atslib_mpf_mul3_mpf" overload mpf_mul with mpf_mul3_mpf fun mpf_mul3_ui (dst: &mpf_vt, src1: &mpf_vt, src2: ulint): void = "mac#atslib_mpf_mul3_ui" overload mpf_mul with mpf_mul3_ui fun mpf_mul2_mpf (dst: &mpf_vt, src: &mpf_vt): void = "atslib_mpf_mul2_mpf" // !function overload mpf_mul with mpf_mul2_mpf fun mpf_mul2_ui (dst: &mpf_vt, src: &mpf_vt): void = "atslib_mpf_mul2_ui" // !fun overload mpf_mul with mpf_mul2_ui (* ****** ****** *) symintr mpf_div fun mpf_div3_mpf (dst: &mpf_vt, src1: &mpf_vt, src2: &mpf_vt): void = "mac#atslib_mpf_div3_mpf" overload mpf_div with mpf_div3_mpf fun mpf_div3_ui (dst: &mpf_vt, src1: &mpf_vt, src2: ulint): void = "mac#atslib_mpf_div3_ui" overload mpf_div with mpf_div3_ui fun mpf_ui_div3 (dst: &mpf_vt, src1: ulint, src2: &mpf_vt): void = "mac#atslib_mpf_ui_div3" // end of [mpf_ui_div3] fun mpf_div2_mpf (dst: &mpf_vt, src2: &mpf_vt): void = "atslib_mpf_div2" // !function overload mpf_div with mpf_div2_mpf fun mpf_div2_ui (dst: &mpf_vt, src2: ulint): void = "atslib_mpf_div2_ui" // !fun overload mpf_div with mpf_div2_ui // HX-2010-08-08: no overloading for this one fun mpf_ui_div2 (dst: &mpf_vt, src1: ulint): void = "atslib_mpf_ui_div2" // !fun (* ****** ****** *) symintr mpf_sqrt fun mpf_sqrt2_mpf // dst := sqrt (src) (dst: &mpf_vt, src: &mpf_vt): void = "mac#atslib_mpf_sqrt2_mpf" overload mpf_sqrt with mpf_sqrt2_mpf fun mpf_sqrt2_ui (dst: &mpf_vt, src: ulint): void = "mac#atslib_mpf_sqrt2_ui" overload mpf_sqrt with mpf_sqrt2_ui // dst := sqrt (dst) fun mpf_sqrt1_mpf (dst: &mpf_vt): void = "atslib_mpf_sqrt1_mpf" // !fun overload mpf_sqrt with mpf_sqrt1_mpf (* ****** ****** *) symintr mpf_pow_ui fun mpf_pow3_ui // dst := src1^^src2 (dst: &mpf_vt, src1: &mpf_vt, src2: ulint): void = "mac#atslib_mpf_pow3_ui" overload mpf_pow_ui with mpf_pow3_ui // dst := src1^^src2 fun mpf_pow2_ui (dst: &mpf_vt, src2: ulint): void = "atslib_mpf_pow2_ui" // !fun overload mpf_pow_ui with mpf_pow2_ui (* ****** ****** *) symintr mpf_mul_2exp fun mpf_mul3_2exp ( dst: &mpf_vt, src1: &mpf_vt, src2: ulint ) : void = "mac#atslib_mpf_mul3_2exp" overload mpf_mul_2exp with mpf_mul3_2exp fun mpf_mul2_2exp (dst: &mpf_vt, src2: ulint): void = "atslib_mpf_mul2_2exp" // !function overload mpf_mul_2exp with mpf_mul2_2exp (* ****** ****** *) symintr mpf_div_2exp fun mpf_div3_2exp ( dst: &mpf_vt, src1: &mpf_vt, src2: ulint ) : void = "mac#atslib_mpf_div3_2exp" overload mpf_div_2exp with mpf_div3_2exp fun mpf_div2_2exp ( dst: &mpf_vt, src2: ulint ) : void = "atslib_mpf_div2_2exp" // !function overload mpf_div_2exp with mpf_div2_2exp (* ****** ****** *) fun mpf_eq ( src1: &mpf_vt, src2: &mpf_vt, src3: ulint ) :<> bool = "mac#atslib_mpf_eq" // end of [mpf_eq] symintr mpf_cmp fun mpf_cmp_mpf ( src1: &mpf_vt, src2: &mpf_vt ) :<> int = "mac#atslib_mpf_cmp_mpf" overload mpf_cmp with mpf_cmp_mpf fun mpf_cmp_d ( src1: &mpf_vt, src2: double ) :<> int = "mac#atslib_mpf_cmp_d" overload mpf_cmp with mpf_cmp_d fun mpf_cmp_ui (src1: &mpf_vt, src2: ulint):<> int = "mac#atslib_mpf_cmp_ui" overload mpf_cmp with mpf_cmp_ui fun mpf_cmp_si (src1: &mpf_vt, src2: lint):<> int = "mac#atslib_mpf_cmp_si" overload mpf_cmp with mpf_cmp_si (* ****** ****** *) fun mpf_sgn (x: &mpf_vt):<> Sgn = "mac#atslib_mpf_sgn" // end of [mpf_sgn] (* ****** ****** *) fun mpf_reldiff ( dst: &mpf_vt, src1: &mpf_vt, src2: &mpf_vt ) : void = "mac#atslib_mpf_reldiff" // end of [mpf_reldiff] (* ****** ****** *) (* // // some MPF input/output/print functions // *) fun mpf_inp_str {m:file_mode} ( pf_mode: file_mode_lte (m, r) | x: &mpf_vt, file: &FILE m, base: mp_base_t ) : size_t = "mac#atslib_mpf_inp_str" // end of [mpf_inp_str] fun mpf_out_str {m:file_mode} ( pf_mode: file_mode_lte (m, w) | file: &FILE m, base: mp_base_t, ndigit: size_t, x: &mpf_vt ) : size_t = "mac#atslib_mpf_out_str" // end of [mpf_out_str] fun fprint0_mpf (out: FILEref, x: &mpf_vt, ndigit: size_t): void = "atslib_fprint_mpf" fun fprint1_mpf {m:file_mode} (pf: file_mode_lte (m, w) | out: &FILE m, x: &mpf_vt, ndigit: size_t): void = "atslib_fprint_mpf" fun print_mpf (x: &mpf_vt, ndigit: size_t) : void = "atslib_print_mpf" fun prerr_mpf (x: &mpf_vt, ndigit: size_t) : void = "atslib_prerr_mpf" (* ****** ****** *) // // // low-level MPN functions // // HX-2010-08-13: // These low-level functions should probably be supported. Any volunteer? // (* ****** ****** *) // // // random number generators for MPZ, MPQ and MPF // // (* ****** ****** *) absviewt@ype gmp_randstate_vt = $extype"ats_gmp_randstate_viewt0ype" fun gmp_randclear ( state: &gmp_randstate_vt >> gmp_randstate_vt? ) : void = "mac#atslib_gmp_randclear" // end of [gmp_randclear] fun gmp_randinit_default ( state: &gmp_randstate_vt? >> gmp_randstate_vt ) : void = "mac#atslib_gmp_randinit_default" // end of [gmp_randinit_default] fun gmp_randinit_lc_2exp ( state: &gmp_randstate_vt? >> gmp_randstate_vt , a: &mpz_vt, c: ulint, m2exp: ulint ) : void = "mac#atslib_gmp_randinit_lc_2exp" // end of [gmp_randinit_lc_2exp] fun gmp_randinit_lc_2exp_size ( state: &gmp_randstate_vt? >> gmp_randstate_vt, _size: ulint ) : int(*err*) = "mac#atslib_gmp_randinit_lc_2exp_size" // end of [gmp_randinit_lc_2exp_size] (* ****** ****** *) symintr gmp_randseed fun gmp_randseed_mpz ( state: &gmp_randstate_vt, seed: &mpz_vt ) : void = "mac#atslib_gmp_randseed_mpz" overload gmp_randseed with gmp_randseed_mpz fun gmp_randseed_ui ( state: &gmp_randstate_vt, seed: ulint ) : void = "mac#atslib_gmp_randseed_ui" overload gmp_randseed with gmp_randseed_ui (* ****** ****** *) fun mpz_urandomb ( dst: &mpz_vt, state: &gmp_randstate_vt, nbit: ulint ) : void = "mac#atslib_mpz_urandomb" // end of [mpz_urandomb] fun mpz_urandomm ( // each generated X belongs to [0, range) dst: &mpz_vt, state: &gmp_randstate_vt, range: &mpz_vt ) : void = "mac#atslib_mpz_urandomm" // end of [mpz_urandomm] fun mpz_rrandomb ( dst: &mpz_vt, state: &gmp_randstate_vt, nbit: ulint ) : void = "mac#atslib_mpz_rrandomb" // end of [mpz_rrandomb] fun mpz_random (dst: &mpz_vt, max_size: mp_size_t): void = "mac#atslib_mpz_random" fun mpz_random2 (dst: &mpz_vt, max_size: mp_size_t): void = "mac#atslib_mpz_random2" (* ****** ****** *) // // HX-2010-08-08: a negative number is generated if [max_size] is negative // fun mpf_random2 ( dst: &mpf_vt, max_size: mp_size_t, exp: mp_exp_t ) : void = "mac#atslib_mpf_random2" // end of [mpf_random2] fun mpf_urandomb ( dst: &mpf_vt, state: &gmp_randstate_vt, nbit: ulint ) : void = "mac#atslib_mpf_urandomb" // end of [mpf_urandomb] (* ****** ****** *) (* end of [gmp.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/netdb.sats0000664000175000017500000002055612223166162017460 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/netdb.cats" %} // end of [%{#] (* ****** ****** *) staload SA = "libc/sys/SATS/sockaddr.sats" typedef sa_family_t = $SA.sa_family_t stadef socklen_t = $SA.socklen_t stadef sockaddr = $SA.sockaddr_struct staload SOCKET = "libc/sys/SATS/socket.sats" typedef socktype_t = $SOCKET.socktype_t typedef sockprot_t = $SOCKET.sockprot_t staload IN = "libc/netinet/SATS/in.sats" typedef sockaddr_in = $IN.sockaddr_in_struct typedef sockaddr_in6 = $IN.sockaddr_in6_struct (* staload UN = "libc/sys/SATS/un.sats" typedef sockaddr_un = $UN.sockaddr_un_struct *) (* ****** ****** *) abst@ype ai_flag_t = uint // macdef AI_NONE = $extval (ai_flag_t, "0x0") // macdef AI_ALL = $extval (ai_flag_t, "AI_ALL") macdef AI_ADDRCONFIG = $extval (ai_flag_t, "AI_ADDRCONFIG") macdef AI_CANNONNAME = $extval (ai_flag_t, "AI_CANNONNAME") macdef AI_NUMERICHOST = $extval (ai_flag_t, "AI_NUMERICHOST") macdef AI_NUMERICSERV = $extval (ai_flag_t, "AI_NUMERICSERV") macdef AI_PASSIVE = $extval (ai_flag_t, "AI_PASSIVE") macdef AI_V4MAPPED = $extval (ai_flag_t, "AI_V4MAPPED") // fun lor_ai_flag_ai_flag ( x1: ai_flag_t, x2: ai_flag_t ) : ai_flag_t = "mac#atspre_lor_uint_uint" overload lor with lor_ai_flag_ai_flag (* ****** ****** *) typedef addrinfo_struct (n:int) = $extype_struct "ats_addrinfo_type" of { ai_flags= ai_flag_t , ai_family= sa_family_t , ai_socktype= socktype_t , ai_protocol= sockprot_t , ai_addrlen=socklen_t(n) // , ai_addr= ptr // sockaddr* // , ai_canonname= string // char* // , ai_next= ptr // struct addrinfo* } // end of [addrinfo_struct] stadef addrinfo = addrinfo_struct absviewtype addrinfoptr (l:addr) = ptr viewtypedef addrinfoptr = [l:addr] addrinfoptr(l) fun addrinfoptr_is_null {l:addr} ( x: !addrinfoptr l ) : bool (l==null) = "mac#atspre_ptr_is_null" fun addrinfoptr_isnot_null {l:addr} ( x: !addrinfoptr l ) : bool (l > null) = "mac#atspre_ptr_isnot_null" fun addrinfoptr_get_next {l:agz} (x: !addrinfoptr l) :<> [l1:addr] ( minus (addrinfoptr l, addrinfoptr l1) | addrinfoptr l1 ) = "mac#atslib_addrinfoptr_get_next" // end of [addrinfoptr_get_next] fun addrinfoptr_get_canonname {l:agz} ( x: !addrinfoptr l ) :<> [l1:addr] ( minus (addrinfoptr l, strptr l1) | strptr l1 ) = "mac#atslib_addrinfoptr_get_canonname" // end of [addrinfoptr_get_cannonname] fun addrinfoptr_get_family {l:agz} (x: !addrinfoptr l):<> sa_family_t = "mac#atslib_addrinfoptr_get_family" // end of [addrinfoptr_get_family] fun addrinfoptr_get_socktype {l:agz} (x: !addrinfoptr l):<> socktype_t = "mac#atslib_addrinfoptr_get_socktype" // end of [addrinfoptr_get_socktype] fun addrinfoptr_get_protocol {l:agz} (x: !addrinfoptr l):<> sockprot_t = "mac#atslib_addrinfoptr_get_protocol" // end of [addrinfoptr_get_protocol] (* ****** ****** *) // // HX: if the info is obtained by setting hint.ai_family = AF_INET // fun addrinfoptr_get_addr_in {l:agz} ( x: !addrinfoptr l ) :<> [l1:addr] ( sockaddr_in @ l1, minus (addrinfoptr l, sockaddr_in @ l1) | ptr l1 ) = "mac#atslib_addrinfoptr_get_addr" // end of [fun] // // HX: if the info is obtained by setting hint.ai_family = AF_INET6 // fun addrinfoptr_get_addr_in6 {l:agz} ( x: !addrinfoptr l ) :<> [l1:addr] ( sockaddr_in6 @ l1, minus (addrinfoptr l, sockaddr_in6 @ l1) | ptr l1 ) = "mac#atslib_addrinfoptr_get_addr" // end of [fun] (* // HX-2010-10-13: I doubt this is usefull fun addrinfoptr_get_addr_un {l:agz} (x: !addrinfoptr l) :<> [l1:addr] ( sockaddr_un @ l1, minus (addrinfoptr l, sockaddr_un @ l1) | ptr l1 ) = "mac#atslib_addrinfoptr_get_addr" // end of [addrinfoptr_get_addr_un] *) (* ****** ****** *) fun getaddrinfo ( nodename: string , portname: string , hint: &addrinfo(0) , infop: &addrinfoptr? >> opt (addrinfoptr, i == 0) ) : #[i:int | i <= 0] int (i) // HX: error codes are negative = "mac#atslib_getaddrinfo" // end of [getaddrinfo] (* ****** ****** *) fun gai_strerror ( code: int ) : [l:agz] ( strptr l - void | strptr l ) = "mac#atslib_gai_strerror" (* ****** ****** *) fun freeaddrinfo (infop: addrinfoptr): void = "mac#atslib_freeaddrinfo" // end of [freeaddrinfo] (* ****** ****** *) typedef hostent_struct = $extype_struct "ats_hostent_type" of { h_addrtype= int // address family , h_length= int // length of each address // , h_name= string // official hostname // , h_aliases= ptr(strarr) // array of alternative names // , h_addr_list= ptr(strarr) // array of pointers to network address } // end of [hostent_struct] typedef hostent = hostent_struct fun hostent_get_name ( h: &hostent ) : [l:agz] ( strptr l - void | strptr l ) = "mac#atslib_hostent_get_name" // end of [hostent_get_name] fun hostent_get_aliases ( h: &hostent ) : [n:nat;l:agz] ( ptrarr n @ l, ptrarr n @ l - void | ptr l ) = "mac#atslib_hostent_get_aliases" // end of [hostent_get_aliases] fun hostent_get_addr_list ( h: &hostent ) : [n:nat;l:agz] ( ptrarr n @ l, ptrarr n @ l - void | ptr l ) = "mac#atslib_hostent_get_addr_list" // end of [hostent_get_addr_list] (* ****** ****** *) absview sethostent_v fun sethostent {b:bool} ( stayopen: bool (b) ) : ( sethostent_v | void ) = "mac#atslib_sethostent" // end of [sethostent] fun gethostent ( pf: !sethostent_v | (*none*) ) : [l:addr] ( vptroutopt (hostent, l) | ptr l ) = "mac#atslib_gethostent" // end of [gethostent] fun endhostent ( pf: sethostent_v | (*none*) ) : void = "mac#atslib_endhostent" // end of [endhostent] (* ****** ****** *) // // HX: [gethostbyname] does not handle [IPv6] addresses // fun gethostbyname ( name: string ) : [l:addr] ( vptroutopt (hostent, l) | ptr l ) = "mac#atslib_gethostbyname" // end of [gethostbyname] // // HX: [addr] is often obtained by calling [inet_addr] // fun gethostbyaddr {a:t@ype} ( addr: &a, n: sizeof_t(a), af: sa_family_t ) : [l:addr] ( vptroutopt (hostent, l) | ptr l ) = "mac#atslib_gethostbyaddr" // end of [gethostbyaddr] (* ****** ****** *) abst@ype niflag_t = int macdef NI_ZERO = $extval (niflag_t, "0") macdef NI_NUMERICHOST = $extval (niflag_t, "NI_NUMERICHOST") macdef NI_NUMERICSERV = $extval (niflag_t, "NI_NUMERICSERV") macdef NI_NOFQDN = $extval (niflag_t, "NI_NOFQDN") macdef NI_NAMEREQD = $extval (niflag_t, "NI_NAMEREQD") macdef NI_DGRAM = $extval (niflag_t, "NI_DGRAM") macdef NI_IDN = $extval (niflag_t, "NI_IDN") // HX: -D_GNU_SOUCRCE // // HX: note that [a] should be a [sockaddr]! // [nodename] and [servname] are fill with null-terminated strings if // a call to [getnameinfo] succeeds // fun getnameinfo{a:t@ype} {n1,n2:nat} ( sa: &a, salen: sizeof_t (a) , nodename: &b0ytes(n1) >> bytes(n1), nodelen: size_t(n1) , servname: &b0ytes(n2) >> bytes(n2), servlen: size_t(n1) , flags: niflag_t ) : [i:int | i <= 0] int (i) = "mac#atslib_getnameinfo" // 0/neg : succ/fail // end of [getnameinfo] (* ****** ****** *) fun gethostid (): lint = "mac#atslib_gethostid" fun sethostid (id: lint): int = "mac#atslib_sethostid" // for superuser only (* ****** ****** *) (* end of [netdb.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/fcntl.sats0000664000175000017500000001624412223166162017471 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/fcntl.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef mode_t = $TYPES.mode_t (* ****** ****** *) abst@ype flag_t = $extype"ats_fcntlflag_type" (* castfn flag_of_uint (u: uint):<> flag_t *) castfn uint_of_flag (f: flag_t):<> uint overload uint_of with uint_of_flag abst@ype disjflag_t = flag_t // for [lor] abst@ype conjflag_t = flag_t // for [land] // for masks (* ****** ****** *) macdef O_RDONLY = $extval (flag_t, "O_RDONLY") macdef O_WRONLY = $extval (flag_t, "O_WRONLY") macdef O_RDWR = $extval (flag_t, "O_RDWR") macdef O_CREAT = $extval (disjflag_t, "O_CREAT") macdef O_APPEND = $extval (disjflag_t, "O_APPEND") macdef O_EXCL = $extval (disjflag_t, "O_EXCL") macdef O_NOCTTY = $extval (disjflag_t, "O_NOCTTY") macdef O_NONBLOCK = $extval (disjflag_t, "O_NONBLOCK") macdef O_SYNC = $extval (disjflag_t, "O_SYNC") macdef O_TRUNC = $extval (disjflag_t, "O_TRUNC") (* macdef O_NDELAY macdef O_NOFOLLOW macdef O_DIRECTORY macdef O_DIRECT macdef O_ASYNC macdef O_LARGEFILE *) fun lnot_disjflag (df: disjflag_t): conjflag_t = "atslib_lnot_disjflag" overload ~ with lnot_disjflag fun lor_flag_disjflag (f: flag_t, df: disjflag_t): flag_t = "atslib_lor_flag_disjflag" overload lor with lor_flag_disjflag fun land_flag_conjflag (f: flag_t, cf: conjflag_t): flag_t = "atslib_land_flag_conjflag" overload land with land_flag_conjflag (* ****** ****** *) absview fildes_v (int) // file descriptor view (* ****** ****** *) dataview open_v (int) = | {i:nat} open_v_succ (i) of fildes_v (i) | open_v_fail (~1) of () // end of [open_v] fun open_flag_err (path: string, flag: flag_t): [i: int] (open_v (i) | int i) = "atslib_open_flag_err" // end of [open_flag_err] fun open_flag_mode_err ( path: string, flag: flag_t, mode: mode_t ) : [i: int] (open_v (i) | int i) = "atslib_open_flag_mode_err" // end of [open_flag_mode_err] fun open_flag_exn (path: string, flag: flag_t): [i: int] (fildes_v i | int i) = "atslib_open_flag_exn" // end of [open_flag_exn] fun open_flag_mode_exn (path: string, flag: flag_t, mode: mode_t) : [i: int] (fildes_v (i) | int i) = "atslib_open_flag_mode_exn" // end of [open_flag_mode_exn] (* ****** ****** *) dataview close_v (fd: int, int) = | close_v_succ (fd, 0) of () | close_v_fail (fd, ~1) of fildes_v (fd) // end of [close_v] fun close_err {fd:int} (pf: fildes_v (fd) | fd: int fd) : [i:int] (close_v (fd, i) | int i) = "atslib_close_err" // end of [close_err] fun close_exn {fd:int} (pf: fildes_v (fd) | fd: int fd): void = "atslib_close_exn" // end of [close_exn] // // HX: implemented in [libc/DATS/fcntl.dats] // fun close_loop_err {fd:int} (pf: fildes_v (fd) | fd: int fd) :<> [i:int] (close_v (fd, i) | int i) // end of [close_loop_err] // // HX: implemented in [libc/DATS/fcntl.dats] // fun close_loop_exn {fd:int} (pf: fildes_v (fd) | fd: int fd): void // end of [close_loop_exn] (* ****** ****** *) // // HX: implemented in [libc/CATS/fcntl.cats] // fun read_err {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &b0ytes(sz) >> bytes(sz), ntotal: size_t n ) : ssizeBtw(~1, n+1) = "atslib_fildes_read_err" // end of [read_err] fun read_exn {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &b0ytes(sz) >> bytes(sz), ntotal: size_t n ) : sizeLte n = "atslib_fildes_read_exn" // end of [read_exn] (* ****** ****** *) // // HX: // this one is implemented in [libc/DATS/fcntl.dats] // note that it is used only when it is known ahead how many bytes are expected; // otherwise, there is the risk of forever blocking!!! // fun read_all_err {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntot: size_t n ) : ssizeBtw (~1, n+1) = "atslib_fildes_read_all_err" // end of [read_all_err] fun read_all_exn {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntot: size_t n ) : sizeLte n = "atslib_fildes_read_all_exn" // end of [read_all_exn] (* ****** ****** *) // // HX: implemented in [libc/CATS/fcntl.cats] // fun write_err {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw(~1, n+1) = "atslib_fildes_write_err" // end of [write_err] fun write_exn {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : sizeLte n = "atslib_fildes_write_exn" // end of [write_exn] (* ****** ****** *) // // HX: implemented in [libc/DATS/fcntl.dats] // fun write_all_err {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw(~1, n+1) = "atslib_fildes_write_all_err" // end of [write_all_err] // // HX: all bytes must have been written if this function returns // fun write_all_exn {fd:int} {sz,n:nat | n <= sz} ( pf: !fildes_v (fd) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : void = "atslib_fildes_write_all_exn" // end of [write_all_exn] (* ****** ****** *) // // HX: implemented in [libc/CATS/fcntl.cats] // fun write_substring_err {fd:int} {sz:int} {i,n:nat | i+n <= sz} ( pf: !fildes_v (fd) | fd: int fd, str: string sz, start: size_t i, n: size_t n ) : ssizeBtw(~1, n+1) = "atslib_fildes_write_substring_err" // end of [write_substring_err] fun write_substring_exn {fd:int} {sz:int} {i,n:nat | i+n <= sz} ( pf: !fildes_v (fd) | fd: int fd, str: string sz, start: size_t i, n: size_t n ) : sizeLte n = "atslib_fildes_write_substring_exn" // end of [write_substring_exn] (* ****** ****** *) fun fcntl_getfl {fd:int} (pf: !fildes_v (fd) | fd: int fd): flag_t = "atslib_fcntl_getfl" // end of [fcntl_getfl] fun fcntl_setfl {fd:int} (pf: !fildes_v (fd) | fd: int fd, flag: flag_t): int = "atslib_fcntl_setfl" // end of [fcntl_setfl] (* ****** ****** *) (* end of [fcntl.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/utime.sats0000664000175000017500000000400012223166162017471 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/utime.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef time_t = $TYPES.time_t (* ****** ****** *) typedef utimbuf_struct = $extype_struct "ats_utimbuf_type" of { actime= time_t // access time , modtime= time_t // modification time } // end of [utimbuf_struct] typedef utimbuf = utimbuf_struct (* ****** ****** *) fun utime ( path: string, buf: &utimbuf(*const*) ) : int = "mac#atslib_utime" // -1 on error and errno is set // end of [utime] (* ****** ****** *) (* end of [utime.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/time.sats0000664000175000017500000002342712223166162017322 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/time.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" (* ****** ****** *) typedef tm_struct = $extype_struct "ats_tm_struct_type" of { tm_sec= int (* seconds *) , tm_min= int (* minutes *) , tm_hour= int (* hours *) , tm_mday= int (* day of the month *) , tm_mon= int (* month *) , tm_year= int (* year *) , tm_wday= int (* day of the week *) , tm_yday= int (* day in the year *) , tm_isdst= int (* daylight saving time *) } // end of [tm_struct] (* ****** ****** *) typedef time_t = $TYPES.time_t // // HX: these are implemented in libc/sys/CATS/types.cats // fun lint_of_time (t: time_t):<> lint = "atslib_lint_of_time" overload lint_of with lint_of_time fun double_of_time (t: time_t):<> double = "atslib_double_of_time" overload double_of with double_of_time (* ****** ****** *) fun difftime ( finish: time_t, start: time_t ) :<> double = "mac#atslib_difftime" // end of [difftime] (* ****** ****** *) (* ** HX (2010-01-15): ** These functions are now kept for backward compatibility *) fun tm_get_sec (tm: &READ(tm_struct)):<> int = "atslib_tm_get_sec" fun tm_get_min (tm: &READ(tm_struct)):<> int = "atslib_tm_get_min" fun tm_get_hour (tm: &READ(tm_struct)):<> int = "atslib_tm_get_hour" fun tm_get_mday (tm: &READ(tm_struct)):<> int = "atslib_tm_get_mday" fun tm_get_mon (tm: &READ(tm_struct)):<> int = "atslib_tm_get_mon" fun tm_get_year (tm: &READ(tm_struct)):<> int = "atslib_tm_get_year" fun tm_get_wday (tm: &READ(tm_struct)):<> int = "atslib_tm_get_wday" fun tm_get_yday (tm: &READ(tm_struct)):<> int = "atslib_tm_get_yday" fun tm_get_isdst (tm: &READ(tm_struct)):<> int = "atslib_tm_get_isdst" (* ****** ****** *) // symintr time // // HX: error-checking is not forced // fun time_get (): time_t = "atslib_time_get" overload time with time_get // fun time_get_and_set // HX: error must be checked! (p: &time_t? >> opt (time_t, b)): #[b:bool] bool (b) = "atslib_time_get_and_set" // function! overload time with time_get_and_set // (* ****** ****** *) // // HX: [ctime] is non-reentrant // HX: the returned string ends with a newline. // fun ctime ( t: &READ(time_t) ) : [l:addr] ( strptr l - void | strptr l ) = "mac#atslib_ctime" // endfun // (* ****** ****** *) // #define CTIME_BUFSZ 26 // dataview ctime_v (m:int, addr, addr) = | {l:addr} ctime_v_fail (m, l, null) of b0ytes (m) @ l | {l:addr | l > null} ctime_v_succ (m, l, l) of strbuf (m, CTIME_BUFSZ-1) @ l // end of [ctime_v] fun ctime_r {m:int | m >= CTIME_BUFSZ}{l:addr} ( pf: !b0ytes (m) @ l >> ctime_v (m, l, l1) | t: &READ(time_t), p: ptr l ) :<> #[l1:addr] ptr l1 = "mac#atslib_ctime_r" // end of [ctime_r] (* ****** ****** *) // // HX: // [localtime] is non-reentrant // fun localtime ( time: &READ(time_t) ) : [l:addr] ( vptroutopt (tm_struct, l) | ptr l ) = "mac#atslib_localtime" // endfun // (* ****** ****** *) // // HX: [localtime_r] is reentrant // fun localtime_r ( time: &READ(time_t) , tm: &tm_struct? >> opt (tm_struct, l > null) ) :<> #[l:addr] ptr (l) = "mac#atslib_localtime_r" // end of [localtime_r] (* ****** ****** *) // // HX: [gmtime] is non-reentrant // fun gmtime ( time: &READ(time_t) ) : [l:addr] ( vptroutopt (tm_struct, l) | ptr l ) = "mac#atslib_gmtime" // end of [gmtime] // // HX: [gmtime_r] is reentrant // fun gmtime_r ( time: &READ(time_t), tm: &tm_struct? >> opt (tm_struct, l > null) ) :<> #[l:addr] ptr l = "mac#atslib_gmtime_r" // end of [gmtime_r] (* ****** ****** *) fun mktime ( tm: &READ(tm_struct) ) : time_t = "mac#atslib_mktime" // returns -1 on error // end of [mktime] (* ****** ****** *) fun asctime ( tm: &READ(tm_struct) ) : [l:addr] ( strptr l - void | strptr l ) = "mac#atslib_asctime" // end of [asctime] (* ****** ****** *) fun strftime {m:pos} {l:addr} ( pf: !b0ytes m @ l >> strbuf (m, n) @ l | p: ptr l , m: size_t m , fmt: string , tm: &READ(tm_struct) ) :<> #[n:nat | n < m] size_t n = "mac#atslib_strftime" // this a macro! // end of [strftime] (* ****** ****** *) (* // // HX-2010-09-26: // the function is not in FreeBSD or Darwin; // [getdate] sets [getdate_err] if an error occurs // fun getdate_err_get ():<> int = "atslib_getdate_err_get" fun getdate_err_set (x: int):<> void = "atslib_getdate_err_set" fun getdate (str: string): [l:addr] (ptroutopt (tm_struct, l) | ptr l) = "mac#atslib_getdate" // end of [getdate] *) // // -D_XOPEN_SOURCE // fun strptime ( str: string, fmt: string , tm: &tm_struct? >> opt (tm_struct, l > null) ) : #[l:addr] ptr l = "mac#atslib_strptime" // HX: it returns NULL on error // end of [strptime] (* ****** ****** *) (* extern int daylight ; // not in FreeBSD or Darwin extern long int timezone ; // not in FreeBSD or Darwin extern char *tzname[2] ; // not in FreeBSD or Darwin *) fun tzset (): void = "mac#atslib_tzset" (* ****** ****** *) typedef clock_t = $TYPES.clock_t macdef CLOCKS_PER_SEC = $extval (clock_t, "CLOCKS_PER_SEC") // // HX: these are implemented in libc/sys/CATS/types.cats // fun lint_of_clock (c: clock_t):<> lint = "atslib_lint_of_clock" overload lint_of with lint_of_clock fun double_of_clock (c: clock_t):<> double = "atslib_double_of_clock" overload double_of with double_of_clock // fun clock (): clock_t = "mac#atslib_clock" // HX: it returns -1 on error (* ****** ****** *) typedef timespec_struct = $extype_struct "ats_timespec_type" of { tv_sec= time_t // seconds , tv_nsec= lint // nanoseconds } // end of [timespec_struct] typedef timespec = timespec_struct (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set to EINTR // fun nanosleep ( nsec: &READ(timespec) , rem: ×pec? >> opt (timespec, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_nanosleep" // end of [nanosleep] fun nanosleep_null (nsec: &READ(timespec)): int = "mac#atslib_nanosleep_null" // end of [nanosleep_null] (* ****** ****** *) typedef clockid_t = $TYPES.clockid_t macdef CLOCK_REALTIME = $extval (clockid_t, "CLOCK_REALTIME") macdef CLOCK_MONOTONIC = $extval (clockid_t, "CLOCK_MONOTONIC") (* macdef CLOCK_THREAD_CPUTIME_ID = $extval (clockid_t, "CLOCK_THREAD_CPUTIME_ID") macdef CLOCK_PROCESS_CPUTIME_ID = $extval (clockid_t, "CLOCK_PROCESS_CPUTIME_ID") *) (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set // fun clock_gettime ( id: clockid_t , tp: ×pec? >> opt (timespec, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_clock_gettime" // end of [clock_gettime] // // HX: 0/-1 : succ/fail // errno set // fun clock_getres ( id: clockid_t , tp: ×pec? >> opt (timespec, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_clock_getres" // end of [clock_getres] // // HX: 0/-1 : succ/fail // errno set // HX: superuser privilege is needed for this one // fun clock_settime (id: clockid_t, tp: &READ(timespec)): int = "mac#atslib_clock_settime" // end of [clock_settime] (* ****** ****** *) absview timer_v (i:int) typedef timer_t (i:int) = $TYPES.timer_t (i) (* ****** ****** *) typedef itimerspec_struct = $extype_struct "ats_itimerspec_type" of { it_interval= timespec (*reset*), it_value= timespec (*current*) } // end of [itimerspec_struct] typedef itimerspec = itimerspec_struct (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set // fun timer_create_null ( cid: clockid_t , tid: &timer_t? >> opt (timer_t(id), i==0) ) : #[i,id:int | i <= 0] ( option_v (timer_v(id), i==0) | int (i) ) = "mac#atslib_timer_create_null" // end of [timer_create_null] // // HX: 0/-1 : succ/fail // errno set // fun timer_delete {id:int} ( pf: !timer_v(id) >> option_v (timer_v(id), i < 0) | tid: timer_t (id) ) : #[i:int | i <= 0] int (i) = "mac#atslib_timer_delete" // end of [timer_delete] (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set // fun timer_gettime {id:int} ( pf: !timer_v (id) | tid: timer_t (id) , itp: &itimerspec? >> opt (itimerspec, i==0) ) : #[i: int | i <= 0] int (i) = "mac#atslib_timer_gettime" // end of [timer_gettime] fun timer_settime {id:int} ( pf: !timer_v (id) | tid: timer_t (id) , newitp: &READ(itimerspec) , olditp: &itimerspec? >> opt (itimerspec, i==0) ) : #[i: int | i <= 0] int (i) = "mac#atslib_timer_settime" // end of [timer_settime] (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set // fun timer_getoverrun {id:int} ( pf: !timer_v (id) | tid: timer_t (id) ) : intGte (~1) = "mac#atslib_timer_getoverrun" // end of [timer_getoverrun] (* ****** ****** *) (* end of [time.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/curses.sats0000664000175000017500000000524412223166162017665 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/curses.cats" %} // end of [%{#] (* ****** ****** *) typedef strcst = string (* ****** ****** *) macdef OK = $extval (int, "OK") // OK = 0 macdef ERR = $extval (int, "ERR") // ERR = -1 (* ****** ****** *) fun initscr () : ptr = "mac#atslib_initscr" // the return value points to stdscr fun endwin (): int = "mac#atslib_endwin" fun isendwin (): bool = "mac#atslib_isendwin" (* ****** ****** *) fun raw (): int = "mac#atslib_raw" fun noraw (): int = "mac#atslib_noraw" (* ****** ****** *) fun clear (): int = "mac#atslib_clear" fun clrtobot (): int = "mac#atslib_clrtobot" fun clrtoeol (): int = "mac#atslib_clrtoeol" fun erase (): int = "mac#atslib_erase" (* ****** ****** *) fun beep (): int = "mac#atslib_beep" fun flush (): int = "mac#atslib_flush" (* ****** ****** *) fun addstr (str: strcst): int = "mac#atslib_addstr" fun addnstr (str: strcst, n: int): int = "mac#atslib_addnstr" fun mvaddstr ( y: int, x: int, str: strcst ) : int = "mac#atslib_mvaddstr" fun mvaddnstr ( y: int, x: int, str: strcst, n: int ) : int = "mac#atslib_mvaddnstr" (* ****** ****** *) fun refresh (): int = "mac#atslib_refresh" fun doupdate (): int = "mac#atslib_doupdate" (* ****** ****** *) (* end of [curses.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/pthread_uplock.sats0000664000175000017500000000556312223166162021371 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/pthread_uplock.cats" %} // end of [%{#] (* ****** ****** *) // // HX: no consideration for errors: any pthread-error leads to SEGFAULTS // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for static loading at run-time (* ****** ****** *) // // linear lock for uploading // absviewtype uplock0_viewtype stadef uplock0 = uplock0_viewtype absviewtype uplock_view_viewtype (v:view) stadef uplock = uplock_view_viewtype absviewtype upticket_view_viewtype (v:view) stadef upticket = upticket_view_viewtype (* ****** ****** *) fun pthread_uplock_create (): uplock0 = "atslib_pthread_uplock_create" // end of [pthread_uplock_create] fun pthread_uplock_download {v:view} (lock: !uplock (v) >> uplock0): (v | void) = "atslib_pthread_uplock_download" // end of [pthread_uplock_download] fun pthread_uplock_destroy (lock: uplock0): void = "atslib_pthread_uplock_destroy" // end of [pthread_uplock_destroy] fun pthread_uplock_download_and_destroy {v:view} (lock: uplock v): (v | void) (* ****** ****** *) fun pthread_upticket_create {v:view} (lock: !uplock0 >> uplock (v)): upticket (v) = "atslib_pthread_uplock_upticket_create" // end of [pthread_upticket_create] fun pthread_upticket_upload_and_destroy {v:view} (pf: v | ticket: upticket v): void = "atslib_pthread_uplock_upticket_upload_and_destroy" // end of [pthread_upticket_upload_and_destroy] (* ****** ****** *) (* end of [pthread_uplock.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/pthread.sats0000664000175000017500000002255212223166162020011 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // some history: // // Rui Shi and Hongwei Xi first did [pthread] in ATS/Proto, on which // this version is primarily based. // (* ****** ****** *) %{# #include "libc/CATS/pthread.cats" %} // end of [%{#] (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for static loading at run-time (* ****** ****** *) abst@ype pthread_t = $extype"pthread_t" castfn int_of_pthread (x: pthread_t):<> int castfn lint_of_pthread (x: pthread_t):<> lint fun pthread_self (): pthread_t = "mac#atslib_pthread_self" (* ****** ****** *) absviewt@ype pthread_attr_t = $extype"pthread_attr_t" (* ****** ****** *) fun pthread_attr_init ( attr: &pthread_attr_t? >> opt (pthread_attr_t, i == 0) ) : #[i:nat] int (i) = "mac#atslib_pthread_attr_init" // end of [pthread_attr_init] // // HX: possible failure: ENOMEM, which is remote // fun pthread_attr_init_exn (attr: &pthread_attr_t? >> pthread_attr_t): void = "atslib_pthread_attr_init_exn" // end of [pthread_attr_init_exn] (* ****** ****** *) // // HX: this function does not fail? // fun pthread_attr_destroy ( attr: &pthread_attr_t >> opt (pthread_attr_t, i > 0) ) : #[i:nat] int (i) = "mac#atslib_pthread_attr_destroy" // end of [pthread_attr_destroy] fun pthread_attr_destroy_exn (attr: &pthread_attr_t >> pthread_attr_t?): void = "atslib_pthread_attr_destroy_exn" // end of [pthread_attr_destroy_exn] (* ****** ****** *) fun pthread_create ( tid: &pthread_t? >> pthread_t , attr: &pthread_attr_t , f: ptr -> ptr, arg: ptr ) : int = "mac#atslib_pthread_create" // end of [pthread_create] (* ****** ****** *) fun pthread_join ( tid: pthread_t , status: &ptr? >> ptr ) : int = "mac#atslib_pthread_join" // end of [pthread_join] (* ****** ****** *) // // HX: it implemented in [$ATSHOME/ccomp/runtime/ats_prelude.c] // fun pthread_create_detached {vt:viewtype} ( f: (vt) - void , env: !vt >> opt (vt, i > 0) , tid: &pthread_t? >> pthread_t ) : #[i:nat] int i = "ats_pthread_create_detached" // end of [pthread_create_detached] // // HX: [pthread_create_detached_exn] is implemented in // [$ATSHOME/libc/DATS/pthread.dats] // fun pthread_create_detached_exn {vt:viewtype} ( f: (vt) - void, env: vt, tid: &pthread_t? >> pthread_t ) : void // env is to be processed by f // end of [pthread_create_detached_exn] // // HX: [pthread_create_detached_cloptr] is implemented in // [$ATSHOME/libc/DATS/pthread.dats] // fun pthread_create_detached_cloptr ( // // HX: closure is freed to avoid leak! // f: () - void, tid: &pthread_t? >> pthread_t ) : void // end of [pthread_create_detached_cloptr] (* ****** ****** *) // // HX: [pval] is used for supporting [pthread_join] // fun pthread_exit (pval: ptr): void = "mac#atslib_pthread_exit" // macro! // end of [pthread_exit] (* ****** ****** *) fun pthread_cancel (tid: pthread_t): int = "mac#atslib_pthread_cancel" // macro! // end of [pthread_cancel] fun pthread_testcancel (): void = "mac#atslib_pthread_testcancel" // macro! (* ****** ****** *) absview pthread_cleanup_v fun pthread_cleanup_push {vt:viewtype} ( handler: (vt) -> void, arg: vt ) : ( pthread_cleanup_v | void ) = "mac#atslib_pthread_cleanup_push" // end of [pthread_cleanup_push] fun pthread_cleanup_pop (pf: pthread_cleanup_v | execute: int): void = "mac#atslib_pthread_cleanup_pop" // end of [pthread_cleanup_pop] (* ****** ****** *) absviewt@ype pthread_spinlock_view_viewt0ype (v:view) = $extype"pthread_spinlock_t" // end of [absviewt@ype] stadef spinlock_vt = pthread_spinlock_view_viewt0ype fun pthread_spin_init_locked {v:view} ( spn: &spinlock_vt? >> opt (spinlock_vt(v), i==0) , pshared : int ) : #[i:nat] int i = "atslib_pthread_spin_init_locked" // end of [pthread_spin_init_locked] fun pthread_spin_init_unlocked {v:view} ( pf: !v >> option_v (v, i > 0) | spn: &spinlock_vt? >> opt (spinlock_vt(v), i==0) , pshared : int ) : #[i:nat] int i = "atslib_pthread_spin_init_unlocked" // end of [pthread_spin_init_unlocked] (* ****** ****** *) fun pthread_spin_create_locked {v:view} ( pshared: int ) : [l:addr] ( option_v ((free_gc_v l, spinlock_vt v @ l), l > null) | ptr l ) = "atslib_pthread_spin_create_locked" // end of [pthread_spin_create_locked] fun pthread_spin_create_unlocked {v:view} ( pf: !v >> option_v (v, l==null) | pshared: int ) : #[l:addr] ( option_v ((free_gc_v l, spinlock_vt v @ l), l > null) | ptr l ) = "atslib_pthread_spin_create_unlocked" // end of [pthread_spin_create_unlocked] (* ****** ****** *) fun pthread_spin_destroy {v:view} {l:addr} ( p: &spinlock_vt(v) >> opt (spinlock_vt(v), i > 0) ) : #[i:nat] ( option_v (v, i==0) | int i ) = "mac#atslib_pthread_spin_destroy" // end of [pthread_spin_destroy] (* ****** ****** *) fun pthread_spin_lock {v:view} ( spn: &spinlock_vt v ) :<> [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_pthread_spin_lock" // macro! // end of [pthread_spin_lock] fun pthread_spin_trylock {v:view} ( spn: &spinlock_vt v ) :<> [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_pthread_spin_trylock" // macro! // end of [pthread_spin_trylock] fun pthread_spin_unlock {v:view} ( resource: v | spn: &spinlock_vt v ) :<> [i:nat] ( option_v (v, i > 0) | int i ) = "mac#atslib_pthread_spin_unlock" // macro! // end of [pthread_spin_unlock] (* ****** ****** *) absviewt@ype pthread_mutex_view_viewt0ype (v:view) = $extype"pthread_mutex_t" // end of [absviewt@ype] stadef mutex_vt = pthread_mutex_view_viewt0ype (* ****** ****** *) // // HX: this one does initialization and locking // fun pthread_mutex_init_locked {v:view} ( mut: &mutex_vt? >> opt (mutex_vt(v), i==0) ) : #[i:nat] int i = "atslib_pthread_mutex_init_locked" // end of [pthread_mutex_init_locked] fun pthread_mutex_init_unlocked {v:view} ( pf: !v >> option_v (v, i > 0) | mut: &mutex_vt? >> opt (mutex_vt(v), i==0) ) : #[i:nat] int i = "atslib_pthread_mutex_init_unlocked" // end of [pthread_mutex_init_unlocked] (* ****** ****** *) fun pthread_mutex_create_locked {v:view} ( // there is no argument ) : [l:addr] ( option_v ((free_gc_v l, mutex_vt v @ l), l > null) | ptr l ) = "atslib_pthread_mutex_create_locked" // end of [pthread_mutex_create_locked] fun pthread_mutex_create_unlocked {v:view} ( pf: !v >> option_v (v, l==null) | (*none*) ) : #[l:addr] ( option_v ((free_gc_v l, mutex_vt v @ l), l > null) | ptr l ) = "atslib_pthread_mutex_create_unlocked" // end of [pthread_mutex_create_unlocked] (* ****** ****** *) // // HX-2010-03-14: // it should be called 'uninitialize' or 'clear' in ATS // fun pthread_mutex_destroy {v:view} {l:addr} (p: &mutex_vt(v) >> opt (mutex_vt(v), i > 0)) : #[i:nat] ( option_v (v, i==0) | int i ) = "mac#atslib_pthread_mutex_destroy" // end of [pthread_mutex_destroy] (* ****** ****** *) fun pthread_mutex_lock {v:view} ( mut: &mutex_vt v ) :<> [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_pthread_mutex_lock" // macro! // end of [pthread_mutex_lock] fun pthread_mutex_trylock {v:view} ( mut: &mutex_vt v ) :<> [i:nat] (option_v (v, i==0) | int i) = "mac#atslib_pthread_mutex_trylock" // macro! // end of [pthread_mutex_trylock] fun pthread_mutex_unlock {v:view} ( resource: v | mut: &mutex_vt v ) :<> [i:nat] ( option_v (v, i > 0) | int i ) = "mac#atslib_pthread_mutex_unlock" // macro! // end of [pthread_mutex_unlock] (* ****** ****** *) absviewt@ype pthread_cond_viewt0ype = $extype"pthread_cond_t" stadef cond_vt = pthread_cond_viewt0ype (* ****** ****** *) fun pthread_cond_create ( // there is no arugment ) : [l:addr] ( option_v ((free_gc_v l, cond_vt @ l), l > null) | ptr l ) = "atslib_pthread_cond_create" fun pthread_cond_wait {v:view} ( resource: !v | cond: &cond_vt, p: &mutex_vt v ) :<> int = "mac#atslib_pthread_cond_wait" // end of [pthread_cond_wait] fun pthread_cond_signal (cond: &cond_vt):<> int = "mac#atslib_pthread_cond_signal" // end of [pthread_cond_signal] fun pthread_cond_broadcast (cond: &cond_vt):<> int = "mac#atslib_pthread_cond_broadcast" // end of [pthread_cond_broadcast] (* ****** ****** *) (* end of [pthread.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/string.sats0000664000175000017500000001433312223166162017666 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the ** Free Software Foundation; either version 2.1, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) // Start Time: 2008 // (* ****** ****** *) %{# #include "libc/CATS/string.cats" %} // end of [%{#] (* ****** ****** *) staload ERRNO = "libc/SATS/errno.sats" typedef errno_t = $ERRNO.errno_t (* ****** ****** *) fun strcmp ( str1: string, str2: string ) : int = "mac#atslib_strcmp" // end of [strcmp] fun substrcmp {n1:int} {i1:nat | i1 <= n1} {n2:int} {i2:nat | i2 <= n2} ( str1: string n1, i1: size_t i1, str2: string n2, i2: size_t i2 ) : int = "atslib_substrcmp" // end of [substrcmp] (* ****** ****** *) fun strncmp ( str1: string, str2: string, n: size_t ) :<> int = "mac#atslib_strncmp" // end of [strncmp] fun substrncmp {n1:int} {i1:nat | i1 <= n1} {n2:int} {i2:nat | i2 <= n2} {n:nat} ( str1: string n1, i1: size_t i1 , str2: string n2, i2: size_t i2 , n: size_t n ) :<> int = "mac#atslib_substrncmp" // end of [fun] (* ****** ****** *) fun strlen {n:nat} (str: string n):<> size_t n = "mac#atslib_strlen" // !mac // end of [strlen] (* ****** ****** *) (* char *strchr(const char*, int); *) fun strchr (str: string, c: int):<> ptr = "mac#atslib_strchr" // end of [strchr] (* char *strrchr(const char*, int); *) fun strrchr (str: string, c: int):<> ptr = "mac#atslib_strrchr" // end of [strrchr] (* char *strstr(const char*, const char* ): *) fun strstr (haystack: string, needle: string):<> ptr = "mac#atslib_strstr" // end of [strstr] (* ****** ****** *) fun strspn {n:nat} (str: string n, accept: string):<> sizeLte n = "mac#atslib_strspn" // macro! // end of [strspn] fun strcspn {n:nat} (str: string n, reject: string):<> sizeLte n = "mac#atslib_strcspn" // macro! // end of [strcspn] (* ****** ****** *) fun strcpy {m:int} {n:nat | n < m} {l:addr} {ofs:int} ( pf_buf: !b0ytes m @ l >> strbuf (m, n) @ l | sbf: ptr l, str: string n ) :<> ptr l = "mac#atslib_strcpy" // macro! // end of [strcpy] (* ****** ****** *) fun strcat {m:int} {n1,n2:nat | n1 + n2 < m} {l:addr} ( pf_buf: !strbuf (m, n1) @ l >> strbuf (m, n1+n2) @ l | sbf: ptr l, str: string n2 ) :<> ptr l = "mac#atslib_strcat" // macro! // end of [strcat] (* char *strncat(char *dst, const char *src, size_t n): note that there is really no need for this function given that [strcat] is safe! *) (* ****** ****** *) (* char *strpbrk(const char *str, const char *accept); *) dataprop strpbrk_p (l:addr, n:int, l_ret:addr) = | {i:nat | i < n} {l_ret == l+i} strpbrk_p_some (l, n, l_ret) | {l_ret == null} strpbrk_p_none (l, n, l_ret) // end of [strpbrk_p] fun strpbrk {m,n:nat} {l:addr} ( pf: !strbuf (m, n) @ l | p: ptr l, accept: string ) :<> [l_ret:addr] (strpbrk_p (l, n, l_ret) | ptr l_ret) = "mac#atslib_strpbrk" // macro! // end of [strpbrk] (* ****** ****** *) // // HX: implemented in [string.dats] // fun strdup_gc {n:nat} (str: string n) :<> [l:addr] (freebyte_gc_v (n+1, l), strbuf (n+1, n) @ l | ptr l) = "atslib_strdup_gc" // end of [strdup_gc] (* ****** ****** *) dataprop memchr_p ( l:addr, n:int, addr(*ret*) ) = // [l] should be positive | {i:nat | i < n} memchr_p_some (l, n, l+i) | memchr_p_none (l, n, null) // end of [memchr_p] fun memchr {n:nat} {n1:int | n <= n1} {l:addr} ( pf: !bytes n1 @ l | p: ptr l, chr: int, n: size_t n ) : [l_ret:addr] (memchr_p (l, n, l_ret) | ptr l_ret) = "mac#atslib_memchr" // end of [memchr] (* ****** ****** *) fun memcmp {n:nat} {n1,n2:int | n <= n1; n <= n2} ( buf1: &bytes n1, buf2: &bytes n2, n: size_t n ) :<> int = "mac#atslib_memcmp" // end of [memcmp] (* ****** ****** *) fun memcpy {n:nat} {n1,n2:int | n <= n1; n <= n2} {l:addr} ( pf_dst: !bytes n1 @ l | p_dst: ptr l, p_src: &bytes n2, n: size_t n ) :<> ptr l = "mac#atslib_memcpy" // end of [memcpy] (* ****** ****** *) fun memset {n:nat} {n1:int | n <= n1} {l:addr} ( pf: !bytes n1 @ l | p: ptr l, chr: int, n: size_t n ) :<> ptr l = "mac#atslib_memset" // end of [memset] (* ****** ****** *) // // HX: [strerror] is not reentrant: // memory for the returned string is statically allocated // fun strerror ( errno: errno_t ) : [l:agz] (strptr l - void | strptr l) = "mac#atslib_strerror" // macro! // end of [strerror] (* ****** ****** *) dataview strerror_v ( m:int, l:addr, int(*err*) ) = | {n:nat} strerror_succ (m, l, 0) of strbuf (m, n) @ l | strerror_fail (m, l, ~1) of b0ytes m @ l // end of [strerror_v] // // HX: [strerror_r] is reentrant // this is the POSIX version // fun strerror_r {m:nat} {l:addr} ( pf: b0ytes m @ l | errno: errno_t, p_buf: ptr l, m: size_t m ) : [i:int] @(strerror_v (m, l, i) | int i) = "mac#atslib_strerror_r" // end of [strerror_r] (* ****** ****** *) (* // // HX-2010-10-21: // this one is moved into libc/SATS/signal.sats: // fun strsignal (sgn: signum_t) : [l:addr] (strptr(l) - void | strptr(l)) = "mac#atslib_strsignal" // end of [strsignal] *) (* ****** ****** *) (* end of [string.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/unistd_pathconf.sats0000664000175000017500000000650312223166162021550 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/unistd_pathconf.cats" %} // end of [%{#] (* ****** ****** *) typedef pathconfname = int (* ****** ****** *) macdef _PC_LINK_MAX = $extval (pathconfname, "_PC_LINK_MAX") macdef _PC_MAX_CANON = $extval (pathconfname, "_PC_MAX_CANON") macdef _PC_MAX_INPUT = $extval (pathconfname, "_PC_MAX_INPUT") macdef _PC_NAME_MAX = $extval (pathconfname, "_PC_NAME_MAX") macdef _PC_PATH_MAX = $extval (pathconfname, "_PC_PATH_MAX") macdef _PC_PIPE_BUF = $extval (pathconfname, "_PC_PIPE_BUF") macdef _PC_CHOWN_RESTRICTED = $extval (pathconfname, "_PC_CHOWN_RESTRICTED") macdef _PC_NO_TRUNC = $extval (pathconfname, "_PC_NO_TRUNC") macdef _PC_VDISABLE = $extval (pathconfname, "_PC_VDISABLE") macdef _PC_SYNC_IO = $extval (pathconfname, "_PC_SYNC_IO") macdef _PC_ASYNC_IO = $extval (pathconfname, "_PC_ASYNC_IO") macdef _PC_PRIO_IO = $extval (pathconfname, "_PC_PRIO_IO") macdef _PC_SOCK_MAXBUF = $extval (pathconfname, "_PC_SOCK_MAXBUF") macdef _PC_FILESIZEBITS = $extval (pathconfname, "_PC_FILESIZEBITS") macdef _PC_REC_INCR_XFER_SIZE = $extval (pathconfname, "_PC_REC_INCR_XFER_SIZE") macdef _PC_REC_MAX_XFER_SIZE = $extval (pathconfname, "_PC_REC_MAX_XFER_SIZE") macdef _PC_REC_MIN_XFER_SIZE = $extval (pathconfname, "_PC_REC_MIN_XFER_SIZE") macdef _PC_REC_XFER_ALIGN = $extval (pathconfname, "_PC_REC_XFER_ALIGN") macdef _PC_ALLOC_SIZE_MIN = $extval (pathconfname, "_PC_ALLOC_SIZE_MIN") macdef _PC_SYMLINK_MAX = $extval (pathconfname, "_PC_SYMLINK_MAX") macdef _PC_2_SYMLINK = $extval (pathconfname, "_PC_2_SYMLINK") (* ****** ****** *) fun pathconf ( path: string, name: pathconfname ) : lint = "mac#atslib_pathconf" // end of [pathconf] (* ****** ****** *) // // HX-2010-09-21: for simplicity, [fd] is assumed to be valid // fun fpathconf {fd:nat} (fd: int fd, name: pathconfname): lint = "mac#atslib_fpathconf" // end of [fpathconf] (* ****** ****** *) (* end of [unistd_pathconf.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/grp.sats0000664000175000017500000000610712223166162017150 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/grp.cats" %} // end of [%{#] (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef gid_t = $T.gid_t (* ****** ****** *) (* struct group { char *gr_name; /* Group name. */ char *gr_passwd; /* Password. */ __gid_t gr_gid; /* Group ID. */ char **gr_mem; /* Member list. */ // null-terminated } ; *) abst@ype group_rest // unknown quantity typedef group_struct = $extype_struct "ats_group_type" of { gr_name= ptr // char* , gr_passwd= ptr // char* , gr_gid= gid_t , gr_mem= ptr // char** // member list // null-terminated , _rest= undefined_t } // end of [group] typedef group = group_struct (* ****** ****** *) fun group_get_gr_name ( grp: &READ(group) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_group_get_gr_name" // function! // end of [group_get_gr_name] fun group_get_gr_passwd ( grp: &READ(group) ) : [l:addr] ( strptr l - void | strptr l ) = "atslib_group_get_gr_passwd" // function! // end of [group_get_gr_passwd] (* ****** ****** *) // // HX: ptrarr: null-terminated array of pointers // fun group_get_gr_mem ( grp: &READ(group) ) : [n:nat;l:addr] ( ptrarr(n) @ l, ptrarr(n) @ l - void | ptr l ) = "atslib_group_get_gr_mem" // end of [group_get_gr_mem] (* ****** ****** *) // // HX: non-reentrant // fun getgrnam ( nam: string ) : [l:addr] ( vptroutopt (group, l) | ptr l ) = "mac#atslib_getgrnam" // end of [getgrnam] (* ****** ****** *) // // HX: non-reentrant // fun getgrgid ( gid: gid_t ) : [l:addr] ( vptroutopt (group, l) | ptr l ) = "mac#atslib_getgrgid" // end of [getgrgid] (* ****** ****** *) (* end of [grp.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/SIMD_v2df.sats0000664000175000017500000000532012223166162020031 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // for supporting SIMD on vectors of 2 doubles // (* ****** ****** *) #define ATS_STALOADFLAG 0 // no need for static loading at run-time (* ****** ****** *) %{# #include "libc/CATS/SIMD_v2df.cats" %} // end of [%{#] (* ****** ****** *) abst@ype v2df = $extype"ats_v2df_type" (* ****** ****** *) val v2df_0_0: v2df = "atslib_v2df_0_0" val v2df_1_1: v2df = "atslib_v2df_1_1" (* ****** ****** *) symintr v2df_make fun v2df_make_double_double (d0: double, d1: double): v2df = "atslib_v2df_make_double_double" // end of [v2df_make_double_double] overload v2df_make with v2df_make_double_double fun v2df_make_int_int (i0: int, i1: int): v2df = "atslib_v2df_make_int_int" // end of [v2df_make_int_int] // fun v2df_get_fst (dd: v2df): double = "atslib_v2df_get_fst" fun v2df_get_snd (dd: v2df): double = "atslib_v2df_get_snd" // fun add_v2df_v2df (_: v2df, _: v2df): v2df = "atslib_add_v2df_v2df" overload + with add_v2df_v2df fun sub_v2df_v2df (_: v2df, _: v2df): v2df = "atslib_sub_v2df_v2df" overload - with sub_v2df_v2df fun mul_v2df_v2df (_: v2df, _: v2df): v2df = "atslib_mul_v2df_v2df" overload * with mul_v2df_v2df fun div_v2df_v2df (_: v2df, _: v2df): v2df = "atslib_div_v2df_v2df" overload / with div_v2df_v2df (* ****** ****** *) (* end of [SIMD_v2df.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/stdio.sats0000664000175000017500000006017512223166162017507 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // This is essentially the first example of its kind: // building API for C functions // (* ****** ****** *) // // HX-2010-07-13: // There are really two versions here: version-0 and version-1; the former // is unsafe and prone to resource-leaks; it should be avoided once the programmer // becomes comfortable with linear types in ATS. // // HX-2010-10-03: // This design is overly complicated mostly for historic reasons; // it is _not_ suggested that this one be used as an example for learning how to // set up interfaces for C functions // (* ****** ****** *) %{# #include "libc/CATS/stdio.cats" %} // end of [%{#] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" typedef whence_t = $TYPES.whence_t macdef SEEK_SET = $TYPES.SEEK_SET macdef SEEK_CUR = $TYPES.SEEK_CUR macdef SEEK_END = $TYPES.SEEK_END (* ****** ****** *) sortdef fm = file_mode typedef bytes (n:int) = @[byte][n] typedef b0ytes (n:int) = @[byte?][n] viewdef FILE_v (m:fm, l:addr) = FILE m @ l viewdef FILEopt_v (m:fm, l:addr) = option_v (FILE m @ l, l > null) (* ****** ****** *) praxi stdin_isnot_null : [stdin_addr > null] void praxi stdout_isnot_null : [stdout_addr > null] void praxi stderr_isnot_null : [stderr_addr > null] void // ------------------------------------------------ macdef EOF = $extval (int, "EOF") // HX: it must be -1 // ------------------------------------------------ (* // void clearerr (FILE *stream); The function [clearerr] clears the end-of-file and error indicators for the stream pointed to by stream. *) symintr clearerr fun clearerr0 (f: FILEref):<> void = "mac#atslib_clearerr" overload clearerr with clearerr0 fun clearerr1 {m:fm} (f: &FILE m):<> void = "mac#atslib_clearerr" overload clearerr with clearerr1 // ------------------------------------------------ (* // int fclose (FILE *stream); The [fclose] function will flush the stream pointed to by fp (writing any buffered output data using [fflush] and close the underlying file descriptor. The behaviour of [fclose] is undefined if the stream parameter is an illegal pointer, or is a descriptor already passed to a previous invocation of [fclose]. Upon successful completion 0 is returned. Otherwise, EOF is returned and the global variable errno is set to indicate the error. In either case any further access (including another call to fclose()) to the stream results in undefined behaviour. *) symintr fclose_err fun fclose0_err (r: FILEref):<> int = "mac#atslib_fclose_err" overload fclose_err with fclose0_err fun fclose1_err {m:fm} {l:addr} ( pf: !FILE_v (m, l) >> option_v (FILE_v (m, l), i < 0) | p: ptr l ) :<> #[i:int | i <= 0] int i = "mac#atslib_fclose_err" overload fclose_err with fclose1_err symintr fclose_exn fun fclose0_exn (r: FILEref): void = "atslib_fclose_exn" overload fclose_exn with fclose0_exn fun fclose1_exn {m:fm} {l:addr} (pf: FILE m @ l | p: ptr l): void = "atslib_fclose_exn" overload fclose_exn with fclose1_exn // ------------------------------------------------ // // HX-2010-10-02: // This one ignores all errors except EINTR, which forces // a retry. // fun fclose1_loop // implemented in $ATSHOME/libc/DATS/stdio.dats {m:fm} {l:addr} (pf: FILE m @ l | p: ptr l):<> int // 0/neg : succ/fail // end of [fclose1_loop] // ------------------------------------------------ fun fclose_stdin (): void = "atslib_fclose_stdin" fun fclose_stdout (): void = "atslib_fclose_stdout" fun fclose_stderr (): void = "atslib_fclose_stderr" // ------------------------------------------------ (* // // int feof (FILE *stream); // The function feof() returns a nonzero value if the end of the given file stream has been reached. // *) symintr feof fun feof0 (f: FILEref):<> int = "atslib_feof" overload feof with feof0 fun feof1 {m:fm} (f: &FILE m):<> int = "atslib_feof" overload feof with feof1 // ------------------------------------------------ (* // // int ferror (FILE *stream); // The function [ferror] tests the error indicator for the stream pointed to by stream, returning non-zero if it is set. The error indicator can only be reset by the [clearerr] function. // *) symintr ferror fun ferror0 (f: FILEref):<> int = "atslib_ferror" overload ferror with ferror0 fun ferror1 {m:fm} (f: &FILE m):<> int = "atslib_ferror" overload ferror with ferror1 // ------------------------------------------------ (* // // int fflush (FILE *stream); // The function fflush forces a write of all user-space buffered data for the given output or update stream via the streams underlying write function. The open status of the stream is unaffected. // Upon successful completion 0 is returned. Otherwise, EOF is returned and the global variable errno is set to indicate the error. // *) symintr fflush_err fun fflush0_err (f: FILEref):<> int = "mac#atslib_fflush_err" overload fflush_err with fflush0_err fun fflush1_err {m:fm} ( pf: file_mode_lte (m, w) | f: &FILE m ) :<> [i:int | i <= 0] int (i) = "mac#atslib_fflush_err" overload fflush_err with fflush1_err // symintr fflush_exn fun fflush0_exn (f: FILEref): void = "atslib_fflush_exn" overload fflush_exn with fflush0_exn fun fflush1_exn {m:fm} (pf: file_mode_lte (m, w) | f: &FILE m): void = "atslib_fflush_exn" overload fflush_exn with fflush1_exn fun fflush_stdout (): void = "atslib_fflush_stdout" // ------------------------------------------------ (* // // int fgetc (FILE *stream) // [fgetc] reads the next character from stream and returns it as an unsigned char cast to an int, or EOF on end of file or error. // *) symintr fgetc_err fun fgetc0_err (f: FILEref):<> int = "mac#atslib_fgetc_err" overload fgetc_err with fgetc0_err fun fgetc1_err // [EOF] must be a negative number! {m:fm} ( pf: file_mode_lte (m, r) | f: &FILE m ) :<> [i:int | i <= UCHAR_MAX] int i = "mac#atslib_fgetc_err" overload fgetc_err with fgetc1_err // ------------------------------------------------ (* // // char *fgets (char *str, int size, FILE *stream); // [fgets] reads in at most one less than [size] characters from stream and stores them into the buffer pointed to by s. Reading stops after an EOF or a newline. If a newline is read, it is stored into the buffer. A '\0' is stored after the last character in the buffer. *) dataview fgets_v (sz:int, n0: int, addr, addr) = | {l_buf:addr} fgets_v_fail (sz, n0, l_buf, null) of b0ytes (sz) @ l_buf | {n:nat | n < n0} {l_buf:addr | l_buf > null} fgets_v_succ (sz, n0, l_buf, l_buf) of strbuf (sz, n) @ l_buf // end of [fgets_v] fun fgets_err {sz,n0:int | 0 < n0; n0 <= sz} {m:fm} {l_buf:addr} ( pf_mod: file_mode_lte (m, r) , pf_buf: b0ytes (sz) @ l_buf | p: ptr l_buf, n0: int n0, f: &FILE m ) :<> [l:addr] (fgets_v (sz, n0, l_buf, l) | ptr l) = "mac#atslib_fgets_err" // end of [fgets_err] // // HX: // this function returns an empty strbuf // if EOF is reached but no character is read // fun fgets_exn {sz,n0:int | 0 < n0; n0 <= sz} {m:fm} {l_buf:addr} ( pf_mod: file_mode_lte (m, r), pf_buf: !b0ytes (sz) @ l_buf >> [n:nat | n < n0] strbuf (sz, n) @ l_buf | p: ptr l_buf, n0: int n0, f: &FILE m ) : void = "atslib_fgets_exn" // end of [fgets_exn] // ------------------------------------------------ (* // // int fgetpos(FILE *stream, fpos_t *pos); // The [fgetpos] function stores the file position indicator of the given file stream in the given position variable. The position variable is of type fpos_t (which is defined in stdio.h) and is an object that can hold every possible position in a FILE. [fgetpos] returns zero upon success, and a non-zero value upon failure. // *) abst@ype fpos_t = $extype"ats_fpos_type" fun fgetpos0_err ( fil: FILEref, pos: &fpos_t? >> fpos_t ) :<> [i:int | i <= 0] int (i) = "mac#atslib_fgetpos" // end of [fgetpos0_err] fun fgetpos1_err {m:fm} ( fil: &FILE m, pos: &fpos_t? >> opt (fpos_t, i==0) ) :<> #[i:int | i <= 0] int (i) = "mac#atslib_fgetpos" // end of [fgetpos1_err] // ------------------------------------------------ (* // // int fileno (FILE* filp) ; // The function fileno examines the argument stream and returns its integer descriptor. In case fileno detects that its argument is not a valid stream, it must return -1 and set errno to EBADF. *) symintr fileno fun fileno0_err (f: FILEref):<> int = "mac#atslib_fileno" overload fileno with fileno0_err fun fileno1_err {m:fm} (f: &FILE m):<> int = "mac#atslib_fileno" overload fileno with fileno1_err // ------------------------------------------------ (* // // FILE *fopen (const char *path, const char *mode); // The fopen function opens the file whose name is the string pointed to by path and associates a stream with it. The argument mode points to a string beginning with one of the follow ing sequences (Additional characters may follow these sequences.): r Open text file for reading. The stream is positioned at the beginning of the file. r+ Open for reading and writing. The stream is positioned at the beginning of the file. w Truncate file to zero length or create text file for writing. The stream is positioned at the beginning of the file. w+ Open for reading and writing. The file is created if it does not exist, otherwise it is truncated. The stream is positioned at the beginning of the file. a Open for appending (writing at end of file). The file is created if it does not exist. The stream is positioned at the end of the file. a+ Open for reading and appending (writing at end of file). The file is created if it does not exist. The stream is positioned at the end of the file. *) fun fopen_err {m:fm} (path: string, m: file_mode m) :<> [l:addr] (FILEopt_v (m, l) | ptr l) = "mac#atslib_fopen_err" // end of [fopen_err] fun fopen_exn {m:fm} (path: string, m: file_mode m) : [l:addr] (FILE m @ l | ptr l) = "atslib_fopen_exn" // end of [fopen_exn] fun fopen_ref_exn {m:fm} (path: string, m: file_mode m): FILEref = "atslib_fopen_exn" // end of [fopen_ref_exn] // ------------------------------------------------ (* // int fputc (int c, FILE *stream) The function [fputc] writes the given character [c] to the given output stream. The return value is the character, unless there is an error, in which case the return value is EOF. *) symintr fputc_err fun fputc0_err ( c: char, f: FILEref ) :<> int = "mac#atslib_fputc_err" overload fputc_err with fputc0_err fun fputc1_err {m:fm} (pf: file_mode_lte (m, w) | c: char, f: &FILE m) :<> [i:int | i <= UCHAR_MAX] int i = "mac#atslib_fputc_err" overload fputc_err with fputc1_err symintr fputc_exn fun fputc0_exn (c: char, f: FILEref): void = "atslib_fputc_exn" overload fputc_exn with fputc0_exn fun fputc1_exn {m:fm} (pf: file_mode_lte (m, w) | c: char, f: &FILE m): void = "atslib_fputc_exn" overload fputc_exn with fputc1_exn // ------------------------------------------------ (* // int fputs (const char* s, FILE *stream) The function [fputs] writes a string to a file. it returns a non-negative number on success, or EOF on error. *) symintr fputs_err fun fputs0_err ( str: string, fil: FILEref ) :<> int = "mac#atslib_fputs_err" overload fputs_err with fputs0_err fun fputs1_err {m:fm} (pf: file_mode_lte (m, w) | str: string, f: &FILE m):<> int = "mac#atslib_fputs_err" overload fputs_err with fputs1_err symintr fputs_exn fun fputs0_exn (str: string, fil: FILEref): void = "atslib_fputs_exn" overload fputs_exn with fputs0_exn fun fputs1_exn {m:fm} (pf: file_mode_lte (m, w) | str: string, f: &FILE m): void = "atslib_fputs_exn" overload fputs_exn with fputs1_exn // ------------------------------------------------ (* // // size_t fread (void *ptr, size_t size, size_t nmemb, FILE *stream); // The function [fread] reads [nmemb] elements of data, each [size] bytes long, from the stream pointed to by stream, storing them at the location given by ptr. The return value is the number of items that are actually read. // [fread] does not distinguish between end-of-file and error, and callers must use [feof] and [ferror] to determine which occurred. // *) fun fread {sz:pos} {n_buf:int} {n,nsz:nat | nsz <= n_buf} {m:fm} ( pf_mod: file_mode_lte (m, r) , pf_mul: MUL (n, sz, nsz) | buf: &bytes (n_buf) , sz: size_t sz, n: size_t n , f: &FILE m ) :<> sizeLte n = "mac#atslib_fread" // end of [fread] fun fread_byte {n_buf:int} {n:nat | n <= n_buf} {m:fm} ( pf_mod: file_mode_lte (m, r) | buf: &bytes (n_buf), n: size_t n, f: &FILE m ) :<> sizeLte n = "atslib_fread_byte" // end of [fread_byte] fun fread_byte_exn {n_buf:int} {n:nat | n <= n_buf} {m:fm} ( pf_mod: file_mode_lte (m, r) | buf: &bytes (n_buf), n: size_t n, f: &FILE m ) : void = "atslib_fread_byte_exn" // end of [fread_byte_exn] // ------------------------------------------------ (* // // FILE *freopen (const char *path, const char *mode, FILE *stream); // The [freopen] function opens the file whose name is the string pointed to by path and associates the stream pointed to by stream with it. The original stream (if it exists) is closed. The mode argument is used just as in the fopen function. The primary use of the freopen function is to change the file associated with a standard text stream (stderr, stdin, or stdout). // *) symintr freopen_err fun freopen0_err {m_new:fm} ( path: string, m_new: file_mode m_new, f: FILEref ) :<> void = "mac#atslib_freopen_err" overload freopen_err with freopen0_err fun freopen1_err {m_old,m_new:fm} {l0:addr} ( pf: FILE m_old @ l0 | path: string, m: file_mode m_new, p: ptr l0 ) :<> [l:addr | l==null || l == l0] (FILEopt_v (m_new, l) | ptr l) = "mac#atslib_freopen_err" overload freopen_err with freopen1_err symintr freopen_exn fun freopen0_exn {m_new:fm} ( path: string, m_new: file_mode m_new, f: FILEref ) : void = "atslib_freopen_exn" overload freopen_exn with freopen0_exn fun freopen1_exn {m_old,m_new:fm} {l0:addr} ( pf: FILE m_old @ l0 | path: string, m: file_mode m_new, p: ptr l0 ) : (FILE m_new @ l0 | void) = "atslib_freopen_exn" overload freopen_exn with freopen1_exn fun freopen_stdin (s: string): void = "atslib_freopen_stdin" // end of [freopen_stdin] fun freopen_stdout (s: string): void = "atslib_freopen_stdout" // end of [freopen_stdout] fun freopen_stderr (s: string): void = "atslib_freopen_stderr" // end of [freopen_stderr] // ------------------------------------------------ (* // int fseek (FILE *stream, long offset, int whence) The [fseek] function sets the file position indicator for the stream pointed to by stream. The new position, measured in bytes, is obtained by adding offset bytes to the position specified by whence. If whence is set to [SEEK_SET], [SEEK_CUR], or [SEEK_END], the offset is relative to the start of the file, the current position indicator, or end-of-file, respectively. A successful call to the [fseek] function clears the end- of-file indicator for the stream and undoes any effects of the [ungetc] function on the same stream. Upon success, [fseek] returns 0. Otherwise, it returns -1. *) symintr fseek_err fun fseek0_err ( f: FILEref, offset: lint, whence: whence_t ) :<> int = "mac#atslib_fseek_err" overload fseek_err with fseek0_err fun fseek1_err {m:fm} ( f: &FILE m, offset: lint, whence: whence_t ) :<> int = "mac#atslib_fseek_err" overload fseek_err with fseek1_err symintr fseek_exn fun fseek0_exn (f: FILEref, offset: lint, whence: whence_t): void = "atslib_fseek_exn" overload fseek_exn with fseek0_exn fun fseek1_exn {m:fm} (f: &FILE m, offset: lint, whence: whence_t): void = "atslib_fseek_exn" overload fseek_exn with fseek1_exn // ------------------------------------------------ (* // void fsetpos(FILE *stream, const fpos_t *pos); The [fsetpos] function moves the file position indicator for the given stream to a location specified by the position object. The type fpos_t is defined in stdio.h. The return value for fsetpos() is zero upon success, non-zero on failure. *) fun fsetpos {m:fm} (f: &FILE m, pos: &fpos_t): int = "mac#atslib_fsetpos" // end of [fsetpos] // ------------------------------------------------ (* // // long ftell (FILE *stream) // [ftell] returns the current offset of the given file stream upon on success. Otherwise, -1 is returned and the global variable errno is set to indicate the error. // *) symintr ftell_err fun ftell0_err (f: FILEref):<> lint = "mac#atslib_ftell_err" overload ftell_err with ftell0_err fun ftell1_err {m:fm} (f: &FILE m):<> lint = "mac#atslib_ftell_err" overload ftell_err with ftell1_err symintr ftell_exn fun ftell0_exn (f: FILEref): lint = "atslib_ftell_exn" overload ftell_exn with ftell0_exn fun ftell1_exn {m:fm} (f: &FILE m): lint = "atslib_ftell_exn" overload ftell_exn with ftell1_exn // ------------------------------------------------ (* // // size_t fwrite (const void *ptr, size_t size, size_t nmemb, FILE *stream); // The function [fwrite] writes [nmemb] elements of data, each [size] bytes long, to the stream pointed to by stream, obtaining them from the location given by [ptr]. The return value is the number of items that are actually written. // *) fun fwrite // [sz]: the size of each item {sz:pos} {bsz:int} {n,nsz:nat | nsz <= bsz} {m:fm} ( pf_mod: file_mode_lte (m, w), pf_mul: MUL (n, sz, nsz) | buf: &bytes (bsz), sz: size_t sz, n: size_t n, fil: &FILE m ) :<> natLte n = "mac#atslib_fwrite" // // HX: [fwrite_byte] is a special case of [fwrite] // fun fwrite_byte // [fwrite_byte] only writes once {bsz:int} {n:nat | n <= bsz} {m:fm} ( pf_mod: file_mode_lte (m, w) | buf: &bytes (bsz), n: size_t n, fil: &FILE m ) :<> sizeLte n = "atslib_fwrite_byte" // // HX: an uncatchable exception is thrown if not all bytes are written // fun fwrite_byte_exn {bsz:int} {n:nat | n <= bsz} {m:fm} ( pf_mod: file_mode_lte (m, w) | buf: &bytes (bsz), n: size_t n, fil: &FILE m ) : void = "atslib_fwrite_byte_exn" // ------------------------------------------------ (* // // perror - print a system error message // The routine [perror(s)] produces a message on the standard error output, describing the last error encountered during a call to a system or library function. First (if s is not NULL and *s is not NULL) the argument string s is printed, followed by a colon and a blank. Then the message and a newline. // *) fun perror (msg: string):<> void = "atslib_perror" // end of [perror] // ------------------------------------------------ macdef getc = fgetc_err macdef putc = fputc_err // ------------------------------------------------ fun getchar ():<> int = "atslib_getchar" fun getchar1 () :<> [i:int | i <= UCHAR_MAX] int i = "atslib_getchar" // end of [getchar1] fun putchar (c: char):<> int = "atslib_putchar" fun putchar1 (c: char):<> [i:int | i <= UCHAR_MAX] int i = "atslib_putchar" // end of [putchar1] // ------------------------------------------------ // [puts] puts a newline at the end fun puts_err (inp: string):<> int = "atslib_puts_err" fun puts_exn (inp: string): void = "atslib_puts_exn" // ------------------------------------------------ fun remove_err (inp: string):<> int = "mac#atslib_remove_err" fun remove_exn (inp: string): void = "atslib_remove_exn" // ------------------------------------------------ fun rename_err ( oldpath: string, newpath: string ) :<> int = "mac#atslib_rename_err" fun rename_exn ( oldpath: string, newpath: string ) : void = "atslib_rename_exn" // ------------------------------------------------ // // HX: [rewind] generates no error // symintr rewind fun rewind0 {m:fm} (fil: FILEref):<> void = "mac#atslib_rewind" overload rewind with rewind0 fun rewind1 {m:fm} (fil: &FILE m):<> void = "atslib_rewind" overload rewind with rewind1 // ------------------------------------------------ fun tmpfile_err ( ) :<> [l:agez] (FILEopt_v (rw, l) | ptr l) = "mac#atslib_tmpfile_err" fun tmpfile_exn ( ) : [l:addr] (FILE_v (rw, l) | ptr l) = "atslib_tmpfile_exn" fun tmpfile_ref_exn (): FILEref = "atslib_tmpfile_exn" // ------------------------------------------------ (* // // int ungetc(int c, FILE *stream); // [ungetc] pushes [c] back to stream, cast to unsigned char, where it is available for subsequent read operations. Pushed-back characters will be returned in reverse order; only one pushback is guaranteed. // *) symintr ungetc_err fun ungetc0_err (c: char, f: FILEref):<> int = "mac#atslib_ungetc_err" overload ungetc_err with ungetc0_err fun ungetc1_err {m:fm} (c: char, f: &FILE m):<> [i:int | i <= UCHAR_MAX] int i = "mac#atslib_ungetc_err" overload ungetc_err with ungetc1_err symintr ungetc_exn fun ungetc0_exn (c: char, f: FILEref): void = "atslib_ungetc_exn" overload ungetc_exn with ungetc0_exn fun ungetc1_exn {m:fm} (c: char, f: &FILE m): void = "atslib_ungetc_exn" overload ungetc_exn with ungetc1_exn // ------------------------------------------------ sta BUFSIZ : int praxi BUFSIZ_gtez (): [BUFSIZ >= 0] void macdef BUFSIZ = $extval (int(BUFSIZ), "BUFSIZ") abst@ype bufmode_t = int macdef _IOFBF = $extval (bufmode_t, "_IOFBF") // fully buffered macdef _IOLBF = $extval (bufmode_t, "_IOLBF") // line buffered macdef _IONBF = $extval (bufmode_t, "_IONBF") // no buffering symintr setbuf_null fun setbuf0_null (f: FILEref): void = "mac#atslib_setbuf_null" overload setbuf_null with setbuf0_null fun setbuf1_null {m:fm} (f: &FILE m): void = "mac#atslib_setbuf_null" overload setbuf_null with setbuf1_null // // HX-2010-10-03: // the buffer can be freed only after it is no longer used by // the stream to which it is attached!!! // symintr setbuffer fun setbuffer0 {n1,n2:nat | n2 <= n1} {l:addr} (pf_buf: !b0ytes n1 @ l | f: FILEref, p_buf: ptr l, n2: size_t n2): void = "mac#atslib_setbuffer" overload setbuffer with setbuffer0 fun setbuffer1 {m:fm} {n1,n2:nat | n2 <= n1} {l:addr} (pf_buf: !b0ytes n1 @ l | f: &FILE m, p_buf: ptr l, n2: size_t n2): void = "mac#atslib_setbuffer" overload setbuffer with setbuffer1 symintr setlinebuf fun setlinebuf0 (f: FILEref): void = "mac#atslib_setlinebuf" overload setlinebuf with setlinebuf0 fun setlinebuf1 {m:fm} (f: &FILE m): void = "mac#atslib_setlinebuf" overload setlinebuf with setlinebuf1 symintr setvbuf_null fun setvbuf0_null (f: FILEref, mode: bufmode_t): int = "mac#atslib_setvbuf_null" overload setvbuf_null with setvbuf0_null fun setvbuf1_null {m:fm} (f: &FILE m, mode: bufmode_t): int = "mac#atslib_setvbuf_null" overload setvbuf_null with setvbuf1_null symintr setvbuf fun setvbuf0 {n1,n2:nat | n2 <= n1} {l:addr} (pf_buf: !b0ytes(n1) @ l | fil: FILEref, mode: bufmode_t, n2: size_t n2): int = "mac#ats_setvbuf" overload setvbuf with setvbuf0 fun setvbuf1 {m:fm} {n1,n2:nat | n2 <= n1} {l:addr} (pf_buf: !b0ytes(n1) @ l | fil: &FILE m, mode: bufmode_t, n2: size_t n2): int = "mac#ats_setvbuf" overload setvbuf with setvbuf1 // ------------------------------------------------ (* end of [stdio.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/math.sats0000664000175000017500000002254412223166162017314 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/CATS/math.cats" %} // end of [%{#] (* ****** ****** *) (* #define ATS_STALOADFLAG 0 // there is no need for staloading *) (* ****** ****** *) macdef M_E = 2.7182818284590452354 // e macdef M_PI = 3.14159265358979323846 // pi macdef M_PI_2 = 1.57079632679489661923 // pi/2 macdef M_PI_4 = 0.78539816339744830962 // pi/4 (* ****** ****** *) macdef INFINITY = $extval (float, "INFINITY") (* ****** ****** *) // // HX-2011-08-01: // each floating point number can be put in one of these categories: // macdef FP_NAN = $extval (int, "FP_NAN") macdef FP_INFINITE = $extval (int, "FP_INFINITE") macdef FP_ZERO = $extval (int, "FP_ZERO") macdef FP_SUBNORMAL = $extval (int, "FP_SUBNORMAL") macdef FP_NORMAL = $extval (int, "FP_NORMAL") fun{a:t@ype} fpclassify (x: a):<> int fun fpclassify_double (x: double):<> int = "mac#atslib_fpclassify" fun fpclassify_float (x: float):<> int = "mac#atslib_fpclassify" fun fpclassify_ldouble (x: ldouble):<> int = "mac#atslib_fpclassify" (* ****** ****** *) fun{a:t@ype} isfinite (x: a):<> int fun isfinite_double (x: double):<> int = "mac#atslib_isfinite" fun isfinite_float (x: float):<> int = "mac#atslib_isfinite" fun isfinite_ldouble (x: ldouble):<> int = "mac#atslib_isfinite" fun{a:t@ype} isnormal (x: a):<> int fun isnormal_double (x: double):<> int = "mac#atslib_isnormal" fun isnormal_float (x: float):<> int = "mac#atslib_isnormal" fun isnormal_ldouble (x: ldouble):<> int = "mac#atslib_isnormal" (* ****** ****** *) // // HX: BSD provision // fun{a:t@ype} isinftmp (x: a):<> int fun isinf (d: double):<> int = "mac#atslib_isinf" fun isinff (f: float):<> int = "mac#atslib_isinff" fun isinfl (ld: ldouble):<> int = "mac#atslib_isinfl" fun{a:t@ype} isnantmp (x: a):<> int fun isnan (d: double):<> int = "mac#atslib_isnan" fun isnanf (f: float):<> int = "mac#atslib_isnanf" fun isnanl (ld: ldouble):<> int = "mac#atslib_isnanl" (* ****** ****** *) fun{a:t@ype} ceiltmp (x: a):<> a fun ceil (d: double):<> double = "mac#atslib_ceil" fun ceilf (f: float):<> float = "mac#atslib_ceilf" fun ceill (ld: ldouble):<> ldouble = "mac#atslib_ceill" (* ****** ****** *) fun{a:t@ype} floortmp (x: a):<> a fun floor (d: double):<> double = "mac#atslib_floor" fun floorf (f: float):<> float = "mac#atslib_floorf" fun floorl (ld: ldouble):<> ldouble = "mac#atslib_floorl" (* ****** ****** *) fun{a:t@ype} roundtmp (x: a):<> a fun round (d: double):<> double = "mac#atslib_round" fun roundf (f: float):<> float = "mac#atslib_roundf" fun roundl (ld: ldouble):<> ldouble = "mac#atslib_roundl" (* ****** ****** *) fun{a:t@ype} trunctmp (x: a):<> a fun trunc (d: double):<> double = "mac#atslib_trunc" fun truncf (f: float):<> float = "mac#atslib_truncf" fun truncl (ld: ldouble):<> ldouble = "mac#atslib_truncl" (* ****** ****** *) fun{a:t@ype} fmodtmp (x1: a, x2: a):<> a fun fmod (d1: double, d2: double):<> double = "mac#atslib_fmod" fun fmodf (f1: float, f2: float):<> float = "mac#atslib_fmodf" fun fmodl (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_fmodl" (* ****** ****** *) fun{a:t@ype} fmaxtmp (x1: a, x2: a):<> a fun fmax (d1: double, d2: double):<> double = "mac#atslib_fmax" fun fmaxf (f1: float, f2: float):<> float = "mac#atslib_fmaxf" fun fmaxl (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_fmaxl" fun{a:t@ype} fmintmp (x1: a, x2: a):<> a fun fmin (d1: double, d2: double):<> double = "mac#atslib_fmin" fun fminf (f1: float, f2: float):<> float = "mac#atslib_fminf" fun fminl (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_fminl" fun{a:t@ype} fdimtmp (x1: a, x2: a):<> a fun fdim (d1: double, d2: double):<> double = "mac#atslib_fdim" fun fdimf (f1: float, f2: float):<> float = "mac#atslib_fdimf" fun fdiml (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_fdiml" // // HX: fma (x, y, z) = x * y + z // fun{a:t@ype} fmatmp (x1: a, x2: a, x3: a):<> a fun fma (d1: double, d2: double, d3: double):<> double = "mac#atslib_fma" fun fmaf (f1: float, f2: float, f3: float):<> float = "mac#atslib_fmaf" fun fmal (ld1: ldouble, ld2: ldouble, ld3: ldouble):<> ldouble = "mac#atslib_fmal" (* ****** ****** *) // // HX: already available in [prelude/SATS/float.sats] // fun{a:t@ype} sqrttmp (x: a):<> a fun sqrt (d: double):<> double = "mac#atslib_sqrt" fun sqrtf (f: float):<> float = "mac#atslib_sqrtf" fun sqrtl (ld: ldouble):<> ldouble = "mac#atslib_sqrtl" fun{a:t@ype} cbrttmp (x: a):<> a fun cbrt (d: double):<> double = "mac#atslib_cbrt" fun cbrtf (f: float):<> float = "mac#atslib_cbrtf" fun cbrtl (ld: ldouble):<> ldouble = "mac#atslib_cbrtl" fun{a:t@ype} powtmp (x1: a, x2: a):<> a fun pow (d1: double, d2: double):<> double = "mac#atslib_pow" fun powf (f1: float, f2: float):<> float = "mac#atslib_powf" fun powl (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_powl" (* ****** ****** *) fun{a:t@ype} exptmp (x: a):<> a fun exp (d: double):<> double = "mac#atslib_exp" fun expf (f: float):<> float = "mac#atslib_expf" fun expl (ld: ldouble):<> ldouble = "mac#atslib_expl" (* ****** ****** *) fun{a:t@ype} logtmp (x: a):<> a fun log (d: double):<> double = "mac#atslib_log" fun logf (f: float):<> float = "mac#atslib_logf" fun logl (ld: ldouble):<> ldouble = "mac#atslib_logl" fun{a:t@ype} log10tmp (x: a):<> a fun log10 (d: double):<> double = "mac#atslib_log10" fun log10f (f: float):<> float = "mac#atslib_log10f" fun log10l (ld: ldouble):<> ldouble = "mac#atslib_log10l" (* ****** ****** *) fun{a:t@ype} asintmp (x: a):<> a fun asin (d: double):<> double = "mac#atslib_asin" fun asinf (f: float):<> float = "mac#atslib_asinf" fun asinl (ld: ldouble):<> ldouble = "mac#atslib_asinl" fun{a:t@ype} acostmp (x: a):<> a fun acos (d: double):<> double = "mac#atslib_acos" fun acosf (f: float):<> float = "mac#atslib_acosf" fun acosl (ld: ldouble):<> ldouble = "mac#atslib_acosl" fun{a:t@ype} atantmp (x: a):<> a fun atan (d: double):<> double = "mac#atslib_atan" fun atanf (f: float):<> float = "mac#atslib_atanf" fun atanl (ld: ldouble):<> ldouble = "mac#atslib_atanl" fun{a:t@ype} atan2tmp (x1: a, x2: a):<> a fun atan2 (d1: double, d2: double):<> double = "mac#atslib_atan2" fun atan2f (f1: float, f2: float):<> float = "mac#atslib_atan2f" fun atan2l (ld1: ldouble, ld2: ldouble):<> ldouble = "mac#atslib_atan2l" (* ****** ****** *) fun{a:t@ype} asinhtmp (x: a):<> a fun asinh (d: double):<> double = "mac#atslib_asinh" fun asinhf (f: float):<> float = "mac#atslib_asinhf" fun asinhl (ld: ldouble):<> ldouble = "mac#atslib_asinhl" fun{a:t@ype} acoshtmp (x: a):<> a fun acosh (d: double):<> double = "mac#atslib_acosh" fun acoshf (f: float):<> float = "mac#atslib_acoshf" fun acoshl (ld: ldouble):<> ldouble = "mac#atslib_acoshl" fun{a:t@ype} atanhtmp (x: a):<> a fun atanh (d: double):<> double = "mac#atslib_atanh" fun atanhf (f: float):<> float = "mac#atslib_atanhf" fun atanhl (ld: ldouble):<> ldouble = "mac#atslib_atanhl" (* ****** ****** *) fun{a:t@ype} sintmp (x: a):<> a fun sin (d: double):<> double = "mac#atslib_sin" fun sinf (f: float):<> float = "mac#atslib_sinf" fun sinl (ld: ldouble):<> ldouble = "mac#atslib_sinl" fun{a:t@ype} costmp (x: a):<> a fun cos (d: double):<> double = "mac#atslib_cos" fun cosf (f: float):<> float = "mac#atslib_cosf" fun cosl (ld: ldouble):<> ldouble = "mac#atslib_cosl" fun{a:t@ype} tantmp (x: a):<> a fun tan (d: double):<> double = "mac#atslib_tan" fun tanf (f: float):<> float = "mac#atslib_tanf" fun tanl (ld: ldouble):<> ldouble = "mac#atslib_tanl" (* ****** ****** *) fun{a:t@ype} sinhtmp (x: a):<> a fun sinh (d: double):<> double = "mac#atslib_sinh" fun sinhf (f: float):<> float = "mac#atslib_sinhf" fun sinhl (ld: ldouble):<> ldouble = "mac#atslib_sinhl" fun{a:t@ype} coshtmp (x: a):<> a fun cosh (d: double):<> double = "mac#atslib_cosh" fun coshf (f: float):<> float = "mac#atslib_coshf" fun coshl (ld: ldouble):<> ldouble = "mac#atslib_coshl" fun{a:t@ype} tanhtmp (x: a):<> a fun tanh (d: double):<> double = "mac#atslib_tanh" fun tanhf (f: float):<> float = "mac#atslib_tanhf" fun tanhl (ld: ldouble):<> ldouble = "mac#atslib_tanhl" (* ****** ****** *) (* end of [math.sats] *) ats-lang-anairiats-0.2.11/libc/SATS/printf.sats0000664000175000017500000000660412223166162017664 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // HX: note that there is also a [printf.sats] in $ATSHOME/prelude/SATS (* ****** ****** *) %{# #include "libc/CATS/printf.cats" %} // end of [%{#] (* ****** ****** *) // // HX: [printf] and [fprintf] are // implemented in $ATSHOME/libc/DATS/printf.dats // based on [vprintf] and [vfprintf] // fun printf {ts:types} (fmt: printf_c ts, arg: ts): int // end of [prinf] fun fprintf {m:file_mode} {ts:types} ( pf_mod: file_mode_lte (m, w) | out: &FILE m, fmt: printf_c ts, arg: ts ) : int // HX: [fprintf] is implemented in ATS // end of [vfprinf] (* ****** ****** *) fun vprintf {ts:types} (fmt: printf_c ts, arg: &va_list (ts) >> va_list): int = "atslib_vprintf" // function! // end of [vprintf] fun vfprintf {m:file_mode} {ts:types} ( pf_mod: file_mode_lte (m, w) | out: &FILE m, fmt: printf_c ts, arg: &va_list (ts) >> va_list ) : int = "atslib_vfprintf" // function! // end of [vfprinf] (* ****** ****** *) (* // // HX: it is correct but too detailed! // fun snprintf {ts:types} {m1,m2:nat | m2 <= m1} {l:addr} ( pf: &(b0ytes m1 @ l) >> strbuf (m1, n1) @ l | p: ptr l, m2: size_t m2, fmt: printf_c ts, arg: ts) : #[n1,n2:nat | (m2 > n2 && n1 == n2) || (n2 >= m2 && n1+1 == m2)] int n2 = "atspre_snprintf" *) // // HX: implemented in $ATSHOME/libc/DATS/printf.dats // fun snprintf {ts:types} {m1,m2:nat | m2 <= m1} {l:addr} ( pf: !array_v(byte?, m1, l) >> strbuf (m1, n1) @ l | p: ptr l, m2: size_t m2, fmt: printf_c ts, arg: ts ) :<> #[n1:nat | n1 < m2] [n2:nat] int n2 = "atslib_snprintf" // end of [snprintf] (* ****** ****** *) // // HX: implemented in $ATSHOME/libc/CATS/printf.cats // fun vsnprintf {ts:types} {m1,m2:nat | m2 <= m1} {l:addr} ( pf: !array_v (byte?, m1, l) >> strbuf (m1, n1) @ l | p: ptr l, m2: size_t m2 , fmt: printf_c ts, arg: &va_list (ts) >> va_list ) :<> #[n1:nat | n1 < m2] [n2:nat] int n2 = "atslib_vsnprintf" // end of [vsnprintf] (* ****** ****** *) (* end of [printf.sats] *) ats-lang-anairiats-0.2.11/libc/sys/0000700000175000017500000000000012223166162015510 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/sys/CATS/0000700000175000017500000000000012223166162016242 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/sys/CATS/types.cats0000664000175000017500000001267712223166162020313 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_TYPES_CATS #define ATS_LIBC_SYS_TYPES_CATS /* ****** ****** */ #include #include /* ****** ****** */ // // typedef blksize_t ats_blksize_type ; // I/O block size // typedef blkcnt_t ats_blkcnt_type ; // number of blocks allowed /* ****** ****** */ // // HX: it should be defined in [sys/types.h] but it is actually in [time.h] // typedef clock_t ats_clock_type ; // for CLOCKS_PER_SEC ATSinline() ats_lint_type atslib_lint_of_clock (clock_t t) { return t ; } ATSinline() ats_double_type atslib_double_of_clock (clock_t t) { return t ; } /* ****** ****** */ // HX: not supported on Mac OSX ? // typedef clockid_t ats_clockid_type ; // for clock ID type /* ****** ****** */ typedef dev_t ats_dev_type ; // for device IDs ATSinline() ats_bool_type atslib_eq_dev_dev (dev_t x1, dev_t x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_eq_dev_dev] /* ****** ****** */ typedef fsblkcnt_t ats_fsblkcnt_type ; // file system block counts typedef fsfilcnt_t ats_fsfilcnt_type ; // file system file counts typedef gid_t ats_gid_type ; // for group IDs /* ****** ****** */ typedef ino_t ats_ino_type ; // for file serial numbers ATSinline() ats_bool_type atslib_eq_ino_ino (ino_t x1, ino_t x2) { return (x1 == x2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_eq_ino_ino] /* ****** ****** */ typedef key_t ats_key_type ; // for XSI interprocess communication /* ****** ****** */ typedef mode_t ats_mode_type ; // file mode ATSinline() ats_bool_type atslib_eq_mode_mode (ats_mode_type m1, ats_mode_type m2) { return (m1 == m2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_eq_mode_mode] ATSinline() ats_bool_type atslib_neq_mode_mode (ats_mode_type m1, ats_mode_type m2) { return (m1 != m2 ? ats_true_bool : ats_false_bool) ; } // end of [atslib_neq_mode_mode] ATSinline() ats_mode_type atslib_lor_mode_mode (ats_mode_type m1, ats_mode_type m2) { return (m1 | m2) ; } // end of [atslib_lor_mode_mode] ATSinline() ats_mode_type atslib_land_mode_mode (ats_mode_type m1, ats_mode_type m2) { return (m1 & m2) ; } // end of [atslib_land_mode_mode] /* ****** ****** */ typedef nlink_t ats_nlink_type ; // number of hard links to a file /* ****** ****** */ typedef off_t ats_off_type ; // file size in bytes #if (0) // // HX: these are now cast functions // ATSinline() ats_lint_type atslib_lint_of_off (ats_off_type off) { return off ; } ATSinline() ats_off_type atslib_off_of_lint (ats_lint_type li) { return li ; } #endif // end of [if(0)] /* ****** ****** */ typedef pid_t ats_pid_type ; // for process IDs // signed integer type #if (0) // // HX: these are now cast functions // ATSinline() ats_pid_type atslib_pid_of_int (ats_int_type i) { return (i) ; } ATSinline() ats_int_type atslib_int_of_pid (ats_pid_type p) { return (p) ; } ATSinline() ats_lint_type atslib_lint_of_pid (ats_pid_type p) { return (p) ; } #endif // end of [if(0)] /* ****** ****** */ // // HX: already defined in [ats_types.h] // typedef size_t ats_size_type ; // for sizes of objects // typedef ssize_t ats_ssize_type ; // for sizes or error indication // /* ****** ****** */ typedef time_t ats_time_type ; // for time in seconds ATSinline() ats_lint_type atslib_lint_of_time (time_t t) { return t ; } ATSinline() ats_double_type atslib_double_of_time (time_t t) { return t ; } /* ****** ****** */ // // HX: where is [timer_t] declared? // typedef timer_t ats_timer_type ; // for timers returned by timer_create () // #ifdef _XOPEN_SOURCE // for POSIX and XPG things typedef useconds_t ats_useconds_type ; // for time in microseconds typedef suseconds_t ats_suseconds_type ; // for signed time in microseconds #endif // end of [_XOPEN_SOURCE] /* ****** ****** */ typedef uid_t ats_uid_type ; #if (0) // // HX: these are now cast functions // ATSinline() ats_int_type atslib_int_of_uid (ats_uid_type u) { return u ; } ATSinline() ats_uid_type atslib_uid_of_int (ats_int_type i) { return i ; } #endif // end of [if(0)] /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_TYPES_CATS] */ /* end of [types.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/poll.cats0000664000175000017500000000371312223166162020104 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_POLL_CATS #define ATS_LIBC_SYS_POLL_CATS /* ****** ****** */ #include typedef struct pollfd ats_pollfd_type ; /* ****** ****** */ ATSinline() ats_int_type atslib_poll ( ats_ref_type fds , ats_int_type nfds // cast to nfds_t (unsigned long) , ats_int_type timeout ) { return poll((ats_pollfd_type*)fds, nfds, timeout) ; } // end of [atslib_poll] /* ****** ****** */ #define atslib_poll poll #define atslib_ppoll ppoll /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_POLL_CATS] */ /* end of [poll.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/socket_in.cats0000664000175000017500000000412412223166162021111 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SOCKET_IN_CATS #define ATS_LIBC_SYS_SOCKET_IN_CATS /* ****** ****** */ #include #include /* ****** ****** */ #ifndef memset extern void *memset (void *p, int c, size_t n) ; #endif // end of [#ifndef] /* ****** ****** */ ATSinline() ats_void_type atslib_sockaddr_in_init ( ats_ptr_type sa0 , sa_family_t af , in_addr_t inp , in_port_t port ) { struct sockaddr_in *sa = sa0 ; (void)memset(sa, 0, sizeof (struct sockaddr_in)) ; sa->sin_family = af ; sa->sin_addr.s_addr = inp ; sa->sin_port = port ; } // end of [sockaddr_in_init] /* ****** ****** */ #endif /* ATS_LIBC_SYS_SOCKET_IN_CATS */ /* end of [socket_in.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/un.cats0000664000175000017500000000333712223166162017562 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_UN_CATS #define ATS_LIBC_SYS_UN_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct sockaddr_un ats_sockaddr_un_type ; #define atslib_socklen_un (sizeof(ats_sockaddr_un_type)) /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_UN_CATS] */ /* end of [un.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/resource.cats0000664000175000017500000000373312223166162020767 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_RESOURCE_CATS #define ATS_LIBC_SYS_RESOURCE_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct rlimit ats_rlimit_type ; typedef struct rusage ats_rusage_type ; /* ****** ****** */ #define atslib_getrlimit getrlimit #define atslib_setrlimit setrlimit /* ****** ****** */ #define atslib_getrusage getrusage /* ****** ****** */ #define atslib_getpriority getpriority #define atslib_setpriority setpriority /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_RESOURCE_CATS] */ /* end of [resource.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/utsname.cats0000664000175000017500000000441412223166162020611 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_UTSNAME_CATS #define ATS_LIBC_SYS_UTSNAME_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct utsname ats_utsname_type ; /* ****** ****** */ #define atslib_utsname_get_sysname(x) (&(((ats_utsname_type*)x)->sysname[0])) #define atslib_utsname_get_nodename(x) (&(((ats_utsname_type*)x)->nodename[0])) #define atslib_utsname_get_release(x) (&(((ats_utsname_type*)x)->release[0])) #define atslib_utsname_get_version(x) (&(((ats_utsname_type*)x)->version[0])) #define atslib_utsname_get_machine(x) (&(((ats_utsname_type*)x)->machine[0])) #ifdef _GNU_SOURCE #define atslib_utsname_get_domainname(x) (&(((ats_utsname_type*)x)->domainname[0])) #endif // end of [_GNU_SOURCE] /* ****** ****** */ #define atslib_uname uname /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_UTSNAME_CATS] */ /* end of [utsname.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/time.cats0000664000175000017500000000453312223166162020075 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_TIME_CATS #define ATS_LIBC_SYS_TIME_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct timeval ats_timeval_type ; typedef struct timezone ats_timezone_type ; /* ****** ****** */ #define atslib_gettimeofday_tv(tv) gettimeofday(tv, NULL) #define atslib_gettimeofday_tz(tz) gettimeofday(NULL, tz) #define atslib_settimeofday_tv(tv) settimeofday(tv, NULL) #define atslib_settimeofday_tz(tz) settimeofday(NULL, tz) #define atslib_settimeofday_tvtz(tv, tz) settimeofday(tv, tz) /* ****** ****** */ #define atslib_utimes utimes #define atslib_futimes futimes #define atslib_futimesat futimesat /* ****** ****** */ typedef struct itimerval ats_itimerval_type ; #define atslib_getitimer getitimer #define atslib_setitimer setitimer #define atslib_setitimer_null(which, itval) setitimer(which, itval, NULL) /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_TIME_CATS] */ /* end of [time.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/stat.cats0000664000175000017500000000545312223166162020114 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_STAT_CATS #define ATS_LIBC_SYS_STAT_CATS /* ****** ****** */ #include #include "libc/sys/CATS/types.cats" typedef struct stat ats_stat_type ; /* ****** ****** */ extern void perror (const char *msg) ; // declared in [stdio.h] // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ ATSinline() ats_bool_type atslib_S_ISBLK (ats_mode_type m) { return S_ISBLK(m) ; } ATSinline() ats_bool_type atslib_S_ISCHR (ats_mode_type m) { return S_ISCHR(m) ; } ATSinline() ats_bool_type atslib_S_ISDIR (ats_mode_type m) { return S_ISDIR(m) ; } ATSinline() ats_bool_type atslib_S_ISFIFO (ats_mode_type m) { return S_ISFIFO(m) ; } ATSinline() ats_bool_type atslib_S_ISREG (ats_mode_type m) { return S_ISREG(m) ; } ATSinline() ats_bool_type atslib_S_ISLNK (ats_mode_type m) { return S_ISLNK(m) ; } ATSinline() ats_bool_type atslib_S_ISSOCK (ats_mode_type m) { return S_ISSOCK(m) ; } /* ****** ****** */ #define atslib_chmod_err chmod /* ****** ****** */ #define atslib_mkdir_err mkdir /* ****** ****** */ #define atslib_stat_err stat #define atslib_fstat_err fstat #define atslib_lstat_err lstat /* ****** ****** */ #define atslib_umask umask /* ****** ****** */ #define atslib_mkfifo mkfifo /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_STAT_CATS] */ /* end of [stat.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/wait.cats0000664000175000017500000000603712223166162020104 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_WAIT_CATS #define ATS_LIBC_SYS_WAIT_CATS #include #include /* ****** ****** */ #include "libc/sys/CATS/types.cats" /* ****** ****** */ #if(0) // // HX-2010-10-8: these will also work: // #define atslib_WIFEXITED(status) WIFEXITED(status) #define atslib_WIFSIGNALED(status) WIFSIGNALED(status) #define atslib_WIFSTOPPED(status) WIFSTOPPED(status) // #define atslib_WEXITSTATUS(status) WEXITSTATUS(status) #define atslib_WTERMSIG(status) WTERMSIG(status) #define atslib_WSTOPSIG(status) WSTOPSIG(status) // #endif // end of [#if(0)] /* ****** ****** */ ATSinline() ats_int_type atslib_WIFEXITED (ats_int_type status) { return WIFEXITED(status) ; } // end of [atslib_WIFEXITED] ATSinline() ats_int_type atslib_WEXITSTATUS (ats_int_type status) { return WEXITSTATUS(status) ; } // end of [atslib_WEXITSTATUS] /* ****** ****** */ ATSinline() ats_int_type atslib_WIFSIGNALED (ats_int_type status) { return WIFSIGNALED(status) ; } // end of [atslib_WIFSIGNALED] ATSinline() ats_int_type atslib_WTERMSIG (ats_int_type status) { return WTERMSIG(status) ; } // end of [atslib_WTERMSIG] /* ****** ****** */ ATSinline() ats_int_type atslib_WIFSTOPPED (ats_int_type status) { return WIFSTOPPED(status) ; } // end of [atslib_WIFSTOPPED] ATSinline() ats_int_type atslib_WSTOPSIG (ats_int_type status) { return WSTOPSIG(status) ; } // end of [atslib_WSTOPSIG] /* ****** ****** */ ATSinline() ats_pid_type atslib_wait_null () { return wait((int*)0) ; } #define atslib_wait wait #define atslib_waitpid waitpid /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_WAIT_CATS] */ /* end of [wait.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/socket_un.cats0000664000175000017500000000403712223166162021130 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SOCKET_UN_CATS #define ATS_LIBC_SYS_SOCKET_UN_CATS /* ****** ****** */ #include #include /* ****** ****** */ #ifndef strcpy extern char *strcpy (char *dst, const char *src) ; // in [string.h] #endif // end of [strcpy] /* ****** ****** */ ATSinline() ats_void_type atslib_sockaddr_un_init ( ats_ptr_type sa0 , sa_family_t af, ats_ptr_type name ) { struct sockaddr_un *sa = sa0 ; sa->sun_family = af ; (void)strcpy(&(sa->sun_path[0]), name) ; return ; } // end of [sockaddr_un_init] /* ****** ****** */ #endif /* ATS_LIBC_SYS_SOCKET_UN_CATS */ /* end of [socket_un.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/select.cats0000664000175000017500000000457612223166162020425 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SELECT_CATS #define ATS_LIBC_SYS_SELECT_CATS /* ****** ****** */ #include typedef fd_set ats_fd_set_type ; typedef struct timeval ats_timeval_type ; /* ****** ****** */ ATSinline() ats_void_type atslib_FD_ZERO ( ats_ref_type fdset ) { FD_ZERO ((fd_set*)fdset) ; return ; } // end of [atslib_FD_ZERO] ATSinline() ats_void_type atslib_FD_SET ( ats_int_type fd, ats_ref_type fdset ) { FD_SET (fd, (fd_set*)fdset) ; return ; } // end of [atslib_FD_SET] ATSinline() ats_void_type atslib_FD_CLR ( ats_int_type fd, ats_ref_type fdset ) { FD_CLR (fd, (fd_set*)fdset) ; return ; } // end of [atslib_FD_CLR] ATSinline() ats_bool_type atslib_FD_ISSET ( ats_int_type fd, ats_ref_type fdset ) { return FD_ISSET (fd, (fd_set*)fdset) ; } // end of [atslib_FD_ISSET] /* ****** ****** */ #define atslib_select select #define atslib_pselect pselect /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_SELECT_CATS] */ /* end of [select.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/sockaddr.cats0000664000175000017500000000330312223166162020723 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SOCKADDR_CATS #define ATS_LIBC_SYS_SOCKADDR_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct sockaddr_storage ats_sockaddr_storage_type ; /* ****** ****** */ #endif /* ATS_LIBC_SYS_SOCKADDR_CATS */ /* end of [sockaddr.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/statvfs.cats0000664000175000017500000000343312223166162020627 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_STATVFS_CATS #define ATS_LIBC_SYS_STATVFS_CATS /* ****** ****** */ #include #include "libc/sys/CATS/types.cats" typedef struct statvfs ats_statvfs_type ; /* ****** ****** */ #define atslib_statvfs statvfs #define atslib_fstatvfs fstatvfs /* ****** ****** */ #endif /* end of [ATS_LIBC_SYS_STATVFS_CATS] */ /* end of [statvfs.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/sockopt.cats0000664000175000017500000000325312223166162020617 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SOCKOPT_CATS #define ATS_LIBC_SYS_SOCKOPT_CATS /* ****** ****** */ #include /* ****** ****** */ typedef struct linger ats_linger_type ; /* ****** ****** */ #endif /* ATS_LIBC_SYS_SOCKOPT_CATS */ /* end of [sockopt.cats] */ ats-lang-anairiats-0.2.11/libc/sys/CATS/socket.cats0000664000175000017500000000623412223166162020427 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_SYS_SOCKET_CATS #define ATS_LIBC_SYS_SOCKET_CATS /* ****** ****** */ #include #include // for [perror] /* ****** ****** */ #include /* ****** ****** */ #include "libc/CATS/fcntl.cats" /* ****** ****** */ typedef int ats_socket_type ; /* ****** ****** */ ATSinline() ats_int_type atslib_socket_family_type_err ( sa_family_t af, ats_socket_type st ) { return socket(af, st, 0) ; } // end of [atslib_socket_family_type_err] /* ****** ****** */ #define atslib_connect_err connect /* ****** ****** */ #define atslib_bind_err bind /* ****** ****** */ #define atslib_listen_err listen /* ****** ****** */ ATSinline() ats_int_type atslib_accept_null_err (ats_int_type sfd) { return accept(sfd, (struct sockaddr*)0, (socklen_t*)0) ; } // end of [atslib_accept_null_err] #define atslib_accept_err accept /* ****** ****** */ #define atslib_socket_close_err atslib_close_err /* ****** ****** */ #define atslib_shutdown_err shutdown /* ****** ****** */ #define atslib_socket_read_err atslib_fildes_read_err #define atslib_socket_write_err atslib_fildes_write_err #define atslib_socket_read_all_err atslib_fildes_read_all_err #define atslib_socket_write_all_err atslib_fildes_write_all_err /* ****** ****** */ // // HX: [fdopen] is declared in stdio.h // #define atslib_socket_fdopen_err fdopen /* ****** ****** */ ATSinline() ats_int_type atslib_setsockopt ( ats_int_type fd , ats_int_type level , ats_int_type option , ats_ref_type value , ats_size_type valen ) { return setsockopt(fd, level, option, (void*)value, (socklen_t)valen) ; } // end of [setsockopt] /* ****** ****** */ #define atslib_sockatmark sockatmark /* ****** ****** */ #endif /* ATS_LIBC_SYS_SOCKET_CATS */ /* end of [socket.cats] */ ats-lang-anairiats-0.2.11/libc/sys/SATS/0000700000175000017500000000000012223166162016262 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/sys/SATS/sockaddr.sats0000664000175000017500000001053412223166162020767 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) abst@ype sa_family_t = $extype"sa_family_t" // // HX: these are the primary ones: // macdef AF_UNIX = $extval (sa_family_t, "AF_UNIX") macdef AF_INET = $extval (sa_family_t, "AF_INET") macdef AF_INET6 = $extval (sa_family_t, "AF_INET6") macdef AF_UNSPEC = $extval (sa_family_t, "AF_UNSPEC") // macdef AF_LOCAL = $extval (sa_family_t, "AF_LOCAL") macdef AF_FILE = $extval (sa_family_t, "AF_FILE") macdef AF_AX25 = $extval (sa_family_t, "AF_AX25") macdef AF_IPX = $extval (sa_family_t, "AF_IPX") macdef AF_APPLETALK = $extval (sa_family_t, "AF_APPLETALK") macdef AF_NETROM = $extval (sa_family_t, "AF_NETROM") macdef AF_BRIDGE = $extval (sa_family_t, "AF_BRIDGE") macdef AF_ATMPVC = $extval (sa_family_t, "AF_ATMPVC") macdef AF_X25 = $extval (sa_family_t, "AF_X25") macdef AF_ROSE = $extval (sa_family_t, "AF_ROSE") macdef AF_DECnet = $extval (sa_family_t, "AF_DECnet") macdef AF_NETBEUI = $extval (sa_family_t, "AF_NETBEUI") macdef AF_SECURITY = $extval (sa_family_t, "AF_SECURITY") macdef AF_KEY = $extval (sa_family_t, "AF_KEY") macdef AF_NETLINK = $extval (sa_family_t, "AF_NETLINK") macdef AF_ROUTE = $extval (sa_family_t, "AF_ROUTE") macdef AF_PACKET = $extval (sa_family_t, "AF_PACKET") macdef AF_ASH = $extval (sa_family_t, "AF_ASH") macdef AF_ECONET = $extval (sa_family_t, "AF_ECONET") macdef AF_ATMSVC = $extval (sa_family_t, "AF_ATMSVC") macdef AF_RDS = $extval (sa_family_t, "AF_RDS") macdef AF_SNA = $extval (sa_family_t, "AF_SNA") macdef AF_IRDA = $extval (sa_family_t, "AF_IRDA") macdef AF_PPPOX = $extval (sa_family_t, "AF_PPPOX") macdef AF_WANPIPE = $extval (sa_family_t, "AF_WANPIPE") macdef AF_LLC = $extval (sa_family_t, "AF_LLC") macdef AF_CAN = $extval (sa_family_t, "AF_CAN") macdef AF_TIPC = $extval (sa_family_t, "AF_TIPC") macdef AF_BLUETOOTH = $extval (sa_family_t, "AF_BLUETOOTH") macdef AF_IUCV = $extval (sa_family_t, "AF_IUCV") macdef AF_RXRPC = $extval (sa_family_t, "AF_RXRPC") macdef AF_ISDN = $extval (sa_family_t, "AF_ISDN") macdef AF_PHONET = $extval (sa_family_t, "AF_PHONET") macdef AF_IEEE802154 = $extval (sa_family_t, "AF_IEEE802154") macdef AF_MAX = $extval (sa_family_t, "AF_MAX") (* ****** ****** *) sta socklen_max: int // length of [sockaddr_storage] (* ****** ****** *) abst@ype socklen_t(n:int) = $extype"socklen_t" castfn socklen_of_int1 {n:nat} (n: int n): socklen_t n castfn socklen_of_size1 {n:nat} (n: size_t n): socklen_t n (* ****** ****** *) abst@ype sockaddr_struct(n:int) // a generic type (* ****** ****** *) abst@ype sockaddr_storage_struct = $extype"ats_sockaddr_storage_type" typedef sockaddr_max_struct = sockaddr_storage_struct (* ****** ****** *) macdef socklen_max = $extval (socklen_t(socklen_max), "atslib_socklen_max") praxi sockaddr_max_trans {l:addr} (pf: !sockaddr_max_struct @ l >> sockaddr_struct(socklen_max) @ l): void praxi sockaddr_trans_max {l:addr} (pf: !sockaddr_struct(socklen_max) @ l >> sockaddr_max_struct @ l): void (* ****** ****** *) (* end of [sockaddr.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/resource.sats0000664000175000017500000001235312223166162021025 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/resource.cats" %} // end of [%{#] (* ****** ****** *) staload TIME = "libc/sys/SATS/time.sats" typedef timeval = $TIME.timeval (* ****** ****** *) typedef rlimit_struct = $extype_struct "ats_rlimit_type" of { rlimit_cur= int // soft limit , rlimit_max= int // hard limit // ceiling for rlimit_cur } // end of [rlimit_struct] typedef rlimit = rlimit_struct (* ****** ****** *) abst@ype resource_t = int macdef RLIMIT_CPU = $extval (resource_t, "RLIMIT_CPU") macdef RLIMIT_FSIZE = $extval (resource_t, "RLIMIT_FSIZE") macdef RLIMIT_DATA = $extval (resource_t, "RLIMIT_DATA") macdef RLIMIT_STACK = $extval (resource_t, "RLIMIT_STACK") macdef RLIMIT_CORE = $extval (resource_t, "RLIMIT_CORE") macdef RLIMIT_RSS = $extval (resource_t, "RLIMIT_RSS") macdef RLIMIT_NOFILE = $extval (resource_t, "RLIMIT_NOFILE") macdef RLIMIT_AS = $extval (resource_t, "RLIMIT_AS") macdef RLIMIT_NPROC = $extval (resource_t, "RLIMIT_NPROC") macdef RLIMIT_MEMLOCK = $extval (resource_t, "RLIMIT_MEMLOCK") macdef RLIMIT_LOCKS = $extval (resource_t, "RLIMIT_LOCKS") macdef RLIMIT_SIGPENDING = $extval (resource_t, "RLIMIT_SIGPENDING") macdef RLIMIT_MSGQUEUE = $extval (resource_t, "RLIMIT_MSGQUEUE") macdef RLIMIT_NICE = $extval (resource_t, "RLIMIT_NICE") macdef RLIMIT_RTPRIO = $extval (resource_t, "RLIMIT_RTPRIO") macdef RLIMIT_NLIMITS = $extval (resource_t, "RLIMIT_NLIMITS") macdef RLIM_NLIMITS = $extval (resource_t, "RLIM_NLIMITS") (* ****** ****** *) macdef RLIM_INFINITY = $extval (ullint, "RLIM_INFINITY") macdef RLIM_SAVED_CUR = $extval (ullint, "RLIM_SAVED_CUR") macdef RLIM_SAVED_MAX = $extval (ullint, "RLIM_SAVED_MAX") (* ****** ****** *) macdef // minimal priority a process can have PRIO_MIN = $extval (int, "PRIO_MIN") macdef // maximal priority a process can have PRIO_MAX = $extval (int, "PRIO_MAX") (* ****** ****** *) fun getrlimit ( // 0/-1 : succ/fail/ errno set res: resource_t , lim: &rlimit? >> opt (rlimit, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_getrlimit" // end of [getrlimit] fun setrlimit ( // 0/-1 : succ/fail/ errno set res: resource_t , lim: &rlimit(*const*) ) : int = "mac#atslib_setrlimit" // end of [setrlimit] (* ****** ****** *) typedef rusage_struct = $extype_struct "ats_rusage_struct" of { ru_utime= timeval // user time used , ru_stime= timeval // system time used (* , ru_maxrss= lint // maximal resident set size , ru_ixrss= lint // integral shared memory size , ru_idrss= lint // integral unshared data size , ru_isrss= lint // integral unshared stack size , ru_minflt= lint // page reclaims , ru_majflt= lint // page faults , ru_nswap= lint // swaps , ru_inblock= lint // block input operations , ru_oublock= lint // block output operations , ru_msgsnd= lint // message sent , ru_msgrcv= lint // message received , ru_nsignals= lint // signals received , ru_nvcsw= lint // voluntary context switch , ru_nivcsw= lint // involuntary context switch *) , _rest = undefined_t // unknown quantity } // en dof [rusage_struct] typedef rusage = rusage_struct fun getrusage ( // 0/-1 : succ/fail/ errno set who: int, rusage: &rusage? >> opt (rusage, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_getrusage" // end of [getrusage] (* ****** ****** *) abst@ype priowhich_t = int castfn int_of_priowhich (x: priowhich_t):<> int macdef PRIO_PROCESS = $extval (priowhich_t, "PRIO_PROCESS") macdef PRIO_PGRP = $extval (priowhich_t, "PRIO_PGRP") macdef PRIO_USER = $extval (priowhich_t, "PRIO_USER") (* ****** ****** *) // // HX: -1 maybe a legitimate return value for getpriority // fun getpriority ( which: priowhich_t, who: int ) : int = "mac#atslib_getpriority" // end of [getpriority] // // HX: 0/-1 : succ/fail // errno set // fun setpriority ( which: priowhich_t, who: int, prio: int ) : int = "mac#atslib_setpriority" // end of [setpriority] (* ****** ****** *) (* end of [resource.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/types.sats0000664000175000017500000001372012223166162020341 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/types.cats" %} // end of [%{#] (* ****** ****** *) abst@ype blksize_t = $extype"ats_blksize_type" // I/O block size abst@ype blkcnt_t = $extype"ats_blkcnt_type" // number of blocks allowed (* ****** ****** *) abst@ype clock_t = $extype"ats_clock_type" // for CLOCKS_PER_SEC fun lint_of_clock (c: clock_t):<> lint = "atslib_lint_of_clock" overload lint_of with lint_of_clock fun double_of_clock (c: clock_t):<> double = "atslib_double_of_clock" overload double_of with double_of_clock (* ****** ****** *) abst@ype clockid_t = $extype"ats_clockid_type" // for clock ID type (* ****** ****** *) abst@ype dev_t = $extype"ats_dev_type" // for device IDs castfn dev_of_uint (x: uint):<> dev_t castfn uint_of_dev (x: dev_t):<> uint fun eq_dev_dev (x1: dev_t, x2: dev_t): bool = "atslib_eq_dev_dev" overload = with eq_dev_dev (* ****** ****** *) abst@ype fsblkcnt_t = $extype"ats_fsblkcnt_type" // file system block counts castfn ulint_of_fsblkcnt (x: fsblkcnt_t): ulint abst@ype fsfilcnt_t = $extype"ats_fsfilcnt_type" // file system file counts castfn ulint_of_fsfilcnt (x: fsfilcnt_t): ulint (* ****** ****** *) abst@ype ino_t = $extype"ats_ino_type" // for file serial numbers castfn int_of_ino (x: ino_t):<> int fun eq_ino_ino (x1: ino_t, x2: ino_t): bool = "atslib_eq_ino_ino" overload = with eq_ino_ino (* ****** ****** *) abst@ype key_t = $extype"ats_key_type" // for XSI interprocess communication (* ****** ****** *) abst@ype mode_t = $extype"ats_mode_type" // file mode // castfn mode_of_int (x: int):<> mode_t castfn int_of_mode (x: mode_t):<> int castfn mode_of_uint (x: uint):<> mode_t castfn uint_of_mode (x: mode_t):<> uint // fun eq_mode_mode (m1: mode_t, m2: mode_t):<> bool = "atslib_eq_mode_mode" overload = with eq_mode_mode fun neq_mode_mode (m1: mode_t, m2: mode_t):<> bool = "atslib_neq_mode_mode" overload <> with neq_mode_mode // fun lor_mode_mode (m1: mode_t, m2: mode_t): mode_t = "atslib_lor_mode_mode" overload lor with lor_mode_mode fun land_mode_mode (m1: mode_t, m2: mode_t): mode_t = "atslib_land_mode_mode" overload land with land_mode_mode (* ****** ****** *) abst@ype nlink_t = $extype"ats_nlink_type" // number of hard links to a file castfn nlink_of_int (x: int): nlink_t castfn int_of_nlink (x: nlink_t): int castfn nlink_of_lint (x: lint): nlink_t castfn lint_of_nlink (x: nlink_t): lint (* ****** ****** *) abst@ype whence_t = $extype"ats_int_type" macdef SEEK_SET = $extval (whence_t, "SEEK_SET") macdef SEEK_CUR = $extval (whence_t, "SEEK_CUR") macdef SEEK_END = $extval (whence_t, "SEEK_END") (* ****** ****** *) abst@ype off_t = $extype"ats_off_type" // file size in bytes castfn off_of_lint (li: lint):<> off_t castfn lint_of_off (off: off_t):<> lint castfn off_of_size (sz: size_t):<> off_t (* ****** ****** *) // // HX: for process IDs // a signed integer type // abst@ype pid_t = $extype"ats_pid_type" castfn pid_of_int (int: int):<> pid_t castfn int_of_pid (pid: pid_t):<> int castfn pid_of_lint (lint: lint):<> pid_t castfn lint_of_pid (pid: pid_t):<> lint (* ****** ****** *) abst@ype gid_t = $extype"ats_gid_type" // for user IDs castfn int_of_gid (gid: gid_t):<> int castfn gid_of_int (int: int):<> gid_t castfn lint_of_gid (gid: gid_t):<> lint castfn gid_of_lint (lint: lint):<> gid_t (******* ****** *) abst@ype uid_t = $extype"ats_uid_type" // for user IDs castfn int_of_uid (uid: uid_t):<> int castfn uid_of_int (int: int):<> uid_t castfn lint_of_uid (uid: uid_t):<> lint castfn uid_of_lint (lint: lint):<> uid_t (******* ****** *) (* // // HX-2010-09-19: // [size_t0ype] and [ssize_t0ype] are declared in $ATSHOME/prelude/basic_sta.sats // abst@ype size_t = $extype"ats_size_type" // for sizes of objects abst@ype ssize_t = $extype"ats_ssize_type" // for sizes or error indication *) (******* ****** *) abst@ype time_t = $extype"ats_time_type" // for time in seconds castfn lint_of_time (t: time_t):<> lint overload lint_of with lint_of_time fun double_of_time (t: time_t):<> double_t0ype = "atslib_double_of_time" overload double_of with double_of_time (******* ****** *) // // HX: for timers returned by [timer_create] // abst@ype timer_t (id:int) = $extype"ats_timer_type" // end of [timer_t] (******* ****** *) abst@ype useconds_t = $extype"ats_useconds_type" // for time in microseconds castfn lint_of_useconds (x: useconds_t):<> lint overload lint_of with lint_of_useconds abst@ype suseconds_t = $extype"ats_suseconds_type" // for time in microseconds castfn lint_of_suseconds (x: suseconds_t):<> lint overload lint_of with lint_of_suseconds (* ****** ****** *) (* end of [types.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/socket_in.sats0000664000175000017500000000522412223166162021153 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: some convenience functions // (* ****** ****** *) %{# #include "libc/sys/CATS/socket_in.cats" %} // end of [%{#] (* ****** ****** *) staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket.sats" (* ****** ****** *) fun sockaddr_in_init ( sa: &sockaddr_in_struct? >> sockaddr_in_struct , af: sa_family_t, inp: in_addr_nbo_t, port: in_port_nbo_t ) :<> void = "atslib_sockaddr_in_init" // end of [sockaddr_in_init] (* ****** ****** *) fun bind_in_exn {fd:int} ( pf_sock: !socket_v (fd, init) >> socket_v (fd, bind) | fd: int fd, servaddr: &sockaddr_in_struct // len=sizeof(sockaddr_in_struct) ) : void // end of [bind_in_exn] (* ****** ****** *) fun connect_in_exn {fd:int} ( pf: !socket_v (fd, init) >> socket_v (fd, conn) | fd: int fd, servaddr: &sockaddr_in_struct // len=sizeof(sockaddr_in_struct) ) : void // end of [connect_in_exn] (* ****** ****** *) fun accept_in_err {sfd:int} ( pfskt: !socket_v (sfd, listen) | sfd: int sfd , sa: &sockaddr_in_struct? >> opt (sockaddr_in_struct, cfd >= 0) , salen: &socklen_t(0)? >> socklen_t(n) ) : #[cfd:int;n:nat] (accept_v (sfd, cfd) | int cfd) // end of [accept_in_err] (* ****** ****** *) (* end of [socket_in.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/utsname.sats0000664000175000017500000000563012223166162020652 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/utsname.cats" %} // end of [%{#] (* ****** ****** *) abst@ype utsname_rest typedef utsname_struct = $extype_struct "ats_utsname_type" of { _rest= utsname_rest // unknown quantity } // end of [utsname_struct] typedef utsname = utsname_struct (* ****** ****** *) fun utsname_get_sysname (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_sysname" // end of [utsname_get_sysname] fun utsname_get_nodename (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_nodename" // end of [utsname_get_nodename] fun utsname_get_release (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_release" // end of [utsname_get_release] fun utsname_get_version (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_version" // end of [utsname_get_version] fun utsname_get_machine (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_machine" // end of [utsname_get_machine] fun utsname_get_domainname (x: &utsname):<> [l:agz] (strptr l - void | strptr l) = "mac#atslib_utsname_get_domainname" // end of [utsname_get_domainname] (* ****** ****** *) // // HX: 0/-1 : succ/fail // errno set // fun uname ( x: &utsname? >> opt (utsname, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_uname" // end of [uname] (* ****** ****** *) (* end of [utsname.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/select.sats0000664000175000017500000000376112223166162020460 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/select.cats" %} // end of [%{#] (* ****** ****** *) abst@ype fd_set_t0ype = $extype"ats_fd_set_type" typedef fd_set = fd_set_t0ype (* ****** ****** *) fun FD_ZERO (fdset: &fd_set? >> fd_set):<> void = "atslib_FD_ZERO" fun FD_SET {fd:nat} (fd: int fd, fdset: &fd_set):<> void = "atslib_FD_SET" fun FD_CLR {fd:nat} (fd: int fd, fdset: &fd_set):<> void = "atslib_FD_CLR" fun FD_ISSET {fd:nat} (fd: int fd, fdset: &fd_set):<> bool = "atslib_FD_ISSET" // end of [FD_ISSET] (* ****** ****** *) (* end of [select.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/statvfs.sats0000664000175000017500000000466712223166162020701 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/statvfs.cats" %} // end of [%{#] (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" typedef fsblkcnt_t = $T.fsblkcnt_t typedef fsfilcnt_t = $T.fsfilcnt_t (* ****** ****** *) typedef statvfs_struct = $extype_struct "ats_statvfs_type" of { f_bsize= ulint , f_frsize= ulint , f_blocks= fsblkcnt_t , f_bfree= fsblkcnt_t , f_bavail= fsblkcnt_t , f_files= fsfilcnt_t , f_ffree= fsfilcnt_t , f_favail= fsfilcnt_t , f_fsid= ulint , f_flag= ulint , f_namemax= ulint , _rest = undefined_t // unknown quantity } // end of [statvfs] typedef statvfs = statvfs_struct (* ****** ****** *) fun statvfs ( // -1 on error // errno set path: string, buf: &statvfs? >> opt (statvfs, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_statvfs" // end of [statvfs] fun fstatvfs {fd:nat} ( // -1 on error // errno set fd: int fd, buf: &statvfs? >> opt (statvfs, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_fstatvfs" // end of [fstatvfs] (* ****** ****** *) (* end of [statvfs.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/stat.sats0000664000175000017500000001322712223166162020152 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/stat.cats" %} // end of [%{#] (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" // typedef dev_t = $T.dev_t typedef ino_t = $T.ino_t typedef mode_t = $T.mode_t typedef nlink_t = $T.nlink_t // typedef gid_t = $T.gid_t typedef uid_t = $T.uid_t // typedef off_t = $T.off_t // typedef blkcnt_t = $T.blkcnt_t typedef blksize_t = $T.blksize_t // typedef time_t = $T.time_t (* ****** ****** *) abst@ype stat_rest // unknown quantity typedef stat_struct = $extype_struct "ats_stat_type" of { st_dev= dev_t // device , st_ino= ino_t // 32-bit file serial number , st_mode= mode_t // file mode , st_nlink= nlink_t // link count , st_uid= uid_t // user ID of the file's owner , st_gid= gid_t // group ID of the file's group , st_rdev= dev_t // device number if device , st_size= off_t // size of file in bytes , st_blksize= blksize_t // optimal block size for I/O , st_blocks= blkcnt_t // number 512-byte blocks allocated , st_atime= time_t // time of last access , st_mtime= time_t // time of last modification , st_ctime= time_t // time of last status change , _rest= stat_rest // this abstract field cannot be accessed } // end of [stat_t] typedef stat = stat_struct (* ****** ****** *) // // HX: bit masks and values // macdef S_IFMT = $extval (mode_t, "S_IFMT") macdef S_IFBLK = $extval (mode_t, "S_IFBLK") macdef S_IFCHR = $extval (mode_t, "S_IFCHR") macdef S_IFDIR = $extval (mode_t, "S_IFDIR") macdef S_IFIFO = $extval (mode_t, "S_IFIFO") macdef S_IFLNK = $extval (mode_t, "S_IFLNK") macdef S_IFREG = $extval (mode_t, "S_IFREG") macdef S_IFSOCK = $extval (mode_t, "S_IFSOCK") (* ****** ****** *) macdef S_IRWXU = $extval (mode_t, "S_IRWXU") macdef S_IRUSR = $extval (mode_t, "S_IRUSR") macdef S_IWUSR = $extval (mode_t, "S_IWUSR") macdef S_IXUSR = $extval (mode_t, "S_IXUSR") macdef S_IRWXG = $extval (mode_t, "S_IRWXG") macdef S_IRGRP = $extval (mode_t, "S_IRGRP") macdef S_IWGRP = $extval (mode_t, "S_IWGRP") macdef S_IXGRP = $extval (mode_t, "S_IXGRP") macdef S_IRWXO = $extval (mode_t, "S_IRWXO") macdef S_IROTH = $extval (mode_t, "S_IROTH") macdef S_IWOTH = $extval (mode_t, "S_IWOTH") macdef S_IXOTH = $extval (mode_t, "S_IXOTH") macdef S_ISUID = $extval (mode_t, "S_ISUID") macdef S_ISGID = $extval (mode_t, "S_ISGID") macdef S_ISVTX = $extval (mode_t, "S_ISVTX") (* ****** ****** *) // // HX: macros // fun S_ISBLK (m: mode_t): bool = "atslib_S_ISBLK" fun S_ISCHR (m: mode_t): bool = "atslib_S_ISCHR" fun S_ISDIR (m: mode_t): bool = "atslib_S_ISDIR" fun S_ISFIFO (m: mode_t): bool = "atslib_S_ISFIFO" fun S_ISREG (m: mode_t): bool = "atslib_S_ISREG" fun S_ISLNK (m: mode_t): bool = "atslib_S_ISLNK" fun S_ISSOCK (m: mode_t): bool = "atslib_S_ISSOCK" (* ****** ****** *) // // HX: (0/1/-1 : false/true/error) // fun isfdtype {fd:nat} (fd: int fd, fdtype: mode_t): int // end of [isfdtype] (* ****** ****** *) fun chmod_err (path: string, mode: mode_t): int = "mac#atslib_chmod_err" // macro! fun chmod_exn (path: string, mode: mode_t): void = "atslib_chmod_exn" // function! (* ****** ****** *) fun mkdir_err (path: string, mode: mode_t): int = "mac#atslib_mkdir_err" // macro! fun mkdir_exn (path: string, mode: mode_t): void = "atslib_mkdir_exn" // function! (* ****** ****** *) fun stat_err ( path: string , st: &stat? >> opt (stat, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_stat_err" // macro! fun stat_exn ( path: string, st: &stat? >> stat ) : void = "atslib_stat_exn" // end of [stat_exn] fun fstat_err {fd:nat} ( fd: int fd , st: &stat? >> opt (stat, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_fstat_err" // macro! fun fstat_exn {fd:nat} (fd: int fd, st: &stat? >> stat): void = "atslib_fstat_exn" // end of [fstat_exn] fun lstat_err ( path: string , st: &stat? >> opt (stat, i==0) ) : #[i:int | i <= 0] int i = "mac#atslib_lstat_err" // macro! fun lstat_exn ( path: string, buf: &stat? >> stat ) : void = "atslib_lstat_exn" // end of [lstat_exn] (* ****** ****** *) fun umask ( mask_new: mode_t(*new*) ) : mode_t(*old*) // this one *always* succeeds = "mac#atslib_umask" // end of [umask] (* ****** ****** *) fun mkfifo // 0/-1 : succ/fail // errno set (path: string, perm: mode_t): int = "mac#atslib_mkfifo" // end of [mkfifo] (* ****** ****** *) (* end of [stat.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/time.sats0000664000175000017500000001127312223166162020134 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/time.cats" %} // end of [%{#] (* ****** ****** *) staload FCNTL = "libc/SATS/fcntl.sats" viewdef fildes_v (fd: int) = $FCNTL.fildes_v (fd) staload TYPES = "libc/sys/SATS/types.sats" typedef time_t = $TYPES.time_t typedef suseconds_t = $TYPES.suseconds_t (* ****** ****** *) typedef timeval_struct = $extype_struct "ats_timeval_type" of { // = struct timeval tv_sec= time_t // seconds , tv_usec= suseconds_t // microseconds } // end of [timeval_struct] typedef timeval = timeval_struct (* ****** ****** *) (* // HX: these macros seem only available in BSD fun timerisset (tv: &timeval):<> bool = "mac#atslib_timerisset" fun timerclear (tv: &timeval >> timeval):<> bool = "mac#atslib_timerclear" *) (* ****** ****** *) typedef timezone_struct = $extype_struct "ats_timezone_type" of { // = struct timezone tz_minuteswest= int // minutes west of GMT , tz_dsttime= int // nonzero if DST is ever in effect } // end of [timezone_struct] typedef timezone = timezone_struct (* ****** ****** *) // symintr gettimeofday // fun gettimeofday_tv ( tv: &timeval? >> opt (timeval, i==0) ) :<> #[i:int | i <= 0] int i = "mac#atslib_gettimeofday_tv" overload gettimeofday with gettimeofday_tv // fun gettimeofday_tz ( tz: &timezone? >> opt (timezone, i==0) ) :<> #[i:int | i <= 0] int i = "mac#atslib_gettimeofday_tz" overload gettimeofday with gettimeofday_tz // (* ****** ****** *) // symintr settimeofday // fun settimeofday_tv (tv: &timeval):<> [i:int | i <= 0] int i = "mac#atslib_settimeofday_tv" overload settimeofday with settimeofday_tv // fun settimeofday_tz (tz: &timezone):<> [i:int | i <= 0] int i = "mac#atslib_settimeofday_tz" overload settimeofday with settimeofday_tz // fun settimeofday_tvtz ( tv: &timeval, tz: &timezone ) :<> [i:int | i <= 0] int i = "mac#atslib_settimeofday_tvtz" overload settimeofday with settimeofday_tvtz // (* ****** ****** *) fun utimes ( // -1 on error // errno set path: string, buf: &(@[timeval][2]) ) : int = "mac#atslib_utimes" // end of [utimes] fun futimes {fd:int} ( // -1 on error // errno set pf: fildes_v fd | fd: int fd, buf: &(@[timeval][2]) ) : int = "mac#atslib_futimes" // end of [futimes] fun futimesat ( // -1 on error // errno set dirfd: int, path: string, buf: &(@[timeval][2]) ) : int = "mac#atslib_futimesat" // end of [futimesat] (* ****** ****** *) abst@ype itimerknd_t = int macdef ITIMER_REAL = $extval (itimerknd_t, "ITIMER_REAL") macdef ITIMER_VIRTUAL = $extval (itimerknd_t, "ITIMER_VIRTUAL") macdef ITIMER_PROF = $extval (itimerknd_t, "ITIMER_PROF") typedef itimerval_struct = $extype_struct "ats_itimerval_type" of { it_interval= timeval, it_value= timeval } // end of [itimerval_struct] typedef itimerval = itimerval_struct // // HX: -1/0 : succ/fail // errno set // fun getitimer ( which: itimerknd_t , itval: &itimerval? >> opt (itimerval, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_getitimer" // end of [getitimer] fun setitimer ( which: itimerknd_t , itval: &itimerval , itval_old: &itimerval? >> opt (itimerval, i==0) ) : #[i:int | i <= 0] int(i) = "mac#atslib_setitimer" // end of [setitimer] fun setitimer_null ( which: itimerknd_t , itval: &itimerval ) : int = "mac#atslib_setitimer_null" // end of [setitimer_null] (* ****** ****** *) (* end of [time.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/wait.sats0000664000175000017500000000703112223166162020137 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/sys/SATS/types.sats" (* ****** ****** *) %{# #include "libc/sys/CATS/wait.cats" %} // end of [%{#] (* ****** ****** *) absprop WIFEXITED_p (s:int, b:bool) fun WIFEXITED {s:int} (status: int s): [b:bool] (WIFEXITED_p (s, b) | bool b) = "atslib_WIFEXITED" // end of [WIFEXITED] fun WEXITSTATUS {s:int} (pf: WIFEXITED_p (s, true) | status: int s): int = "atslib_WEXITSTATUS" // end of [WEXITSTATUS] (* ****** ****** *) absprop WIFSIGNALED_p (s:int, b:bool) fun WIFSIGNALED {s:int} (status: int s): [b:bool] (WIFSIGNALED_p (s, b) | bool b) = "atslib_WIFSIGNALED" // end of [WIFSIGNALED] fun WTERMSIG {s:int} (pf: WIFSIGNALED_p (s, true) | status: int s): int = "atslib_WTERMSIG" // end of [WTERMSIG] (* ****** ****** *) absprop WIFSTOPPED_p (s:int, b:bool) fun WIFSTOPPED {s:int} (status: int s): [b:bool] (WIFSTOPPED_p (s, b) | bool b) = "atslib_WIFSTOPPED" // end of [WIFSTOPPED] fun WSTOPSIG {s:int} (pf: WIFSTOPPED_p (s, true) | status: int s): int = "atslib_WSTOPSIG" // end of [WSTOPSIG] (* ****** ****** *) absprop WIFCONTINUED_p (s:int, b:bool) fun WIFCONTINUED {s:int} (status: int s): [b:bool] (WIFCONTINUED_p (s, b) | bool b) = "atslib_WIFCONTINUED" // end of [WIFCONTINUED] (* ****** ****** *) absprop WCOREDUMP_p (s:int, b:bool) fun WCOREDUMP {s:int} (status: int s): [b:bool] (WCOREDUMP_p (s, b) | bool b) // end of [WCOREDUMP] (* ****** ****** *) fun wait_null (): pid_t = "atslib_wait_null" fun wait (status: &int? >> int): pid_t = "mac#atslib_wait" (* ****** ****** *) abst@ype waitopt_t = $extype"ats_int_type" macdef WNOHANG = $extval (waitopt_t, "WNOHANG") macdef WUNTRACED = $extval (waitopt_t, "WUNTRACED") macdef WCONTINUED = $extval (waitopt_t, "WCONTINUED") macdef WNONE = $extval (waitopt_t, "0") // default value for [waitopt_t] fun lor_waitopt_waitopt (opt1: waitopt_t, opt2: waitopt_t): waitopt_t overload lor with lor_waitopt_waitopt (* ****** ****** *) fun waitpid ( chldpid: pid_t, status: &int? >> int, options: waitopt_t ) : pid_t = "mac#atslib_waitpid" // macro! // end of [waitpid] (* ****** ****** *) (* end of [wait.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/socket.sats0000664000175000017500000002351712223166162020472 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/socket.cats" %} // end of [%{#] (* ****** ****** *) staload SA = "libc/sys/SATS/sockaddr.sats" typedef sa_family_t = $SA.sa_family_t stadef socklen_t = $SA.socklen_t stadef sockaddr_struct = $SA.sockaddr_struct (* ****** ****** *) abst@ype socktype_t = int (* // HX: using $UNSAFE.cast2int instead castfn int_of_socktype (x: socktype_t):<> int overload int_of with int_of_socktype *) macdef SOCK_STREAM = $extval (socktype_t, "SOCK_STREAM") macdef SOCK_DGRAM = $extval (socktype_t, "SOCK_DGRAM") macdef SOCK_RAW = $extval (socktype_t, "SOCK_RAW") macdef SOCK_RDM = $extval (socktype_t, "SOCK_RDM") macdef SOCK_PACKET = $extval (socktype_t, "SOCK_PACKET") macdef SOCK_SEQPACKET = $extval (socktype_t, "SOCK_SEQPACKET") macdef SOCK_DCCP = $extval (socktype_t, "SOCK_DCCP") abst@ype socktypeflag_t = int macdef SOCK_CLOEXEC = $extval (socktypeflag_t, "SOCK_CLOEXEC") macdef SOCK_NONBLOCK = $extval (socktypeflag_t, "SOCK_NONBLOCK") fun lor_socktype_socktypeflag ( t: socktype_t, f: socktypeflag_t ) :<> socktype_t = "atspre_lor_uint_uint" overload lor with lor_socktype_socktypeflag (* ****** ****** *) abst@ype sockprot_t = int (* // HX: using $UNSAFE.cast2int instead castfn int_of_sockprot (x: sockprot_t):<> int overload int_of with int_of_sockprot *) (* ****** ****** *) // // HX: // client: init -> connect // server: init -> bind -> listen -> accept // datasort status = init | bind | listen | conn absview socket_v (int, status) fun socket_family_type_err ( af: sa_family_t, t: socktype_t ) : [fd:int] ( option_v (socket_v (fd, init), fd >= 0) | int fd ) = "atslib_socket_family_type_err" // end of [socket_family_type_err] fun socket_family_type_exn (af: sa_family_t, t: socktype_t): [fd:nat] (socket_v (fd, init) | int fd) // end of [socket_family_type_exn] (* ****** ****** *) dataview connect_v (fd: int, int) = | connect_v_succ (fd, 0) of socket_v (fd, conn) | connect_v_fail (fd, ~1) of socket_v (fd, init) // end of [connect_v] fun connect_err {fd:int} {n:int} ( pfskt: socket_v (fd, init) | fd: int fd , servaddr: &sockaddr_struct(n), salen: socklen_t(n) ) : [i:int | i <= 0] ( connect_v (fd, i) | int i ) = "mac#atslib_connect_err" // end of [connect_err] (* ****** ****** *) dataview bind_v (fd:int, int) = | bind_v_fail (fd, ~1) of socket_v (fd, init) | bind_v_succ (fd, 0) of socket_v (fd, bind) // end of [bind_v] fun bind_err {fd:int} {n:int} ( pfskt: socket_v (fd, init) | fd: int fd , servaddr: &sockaddr_struct(n), salen: socklen_t(n) ) : [i:int] ( bind_v (fd, i) | int i ) = "mac#atslib_bind_err" // end of [bind_err] (* ****** ****** *) macdef SOMAXCONN = $extval (Pos, "SOMAXCONN") dataview listen_v (fd:int, int) = | listen_v_fail (fd, ~1) of socket_v (fd, bind) | listen_v_succ (fd, 0) of socket_v (fd, listen) // end of [listen_v] fun listen_err {fd:int} (pfskt: socket_v (fd, bind) | fd: int fd, backlog: Pos) : [i:int] (listen_v (fd, i) | int i) = "atslib_listen_err" // end of [listen_err] fun listen_exn {fd:int} ( pfskt: !socket_v (fd, bind) >> socket_v (fd, listen) | fd: int fd, backlog: Pos // [backlog = 0] is not supported on all systems ) : void // end of [listen_exn] (* ****** ****** *) dataview accept_v (fd:int, int(*err*)) = | accept_v_fail (fd, ~1) of () | {cfd:nat} accept_v_succ (fd, cfd) of socket_v (cfd, conn) // end of [accept_v] fun accept_err {sfd:int} {n:int} ( pfskt: !socket_v (sfd, listen) | sfd: int sfd , sa: &sockaddr_struct(n)? >> opt (sockaddr_struct(n), cfd >= 0) , salen: &socklen_t(n) >> socklen_t(n1) ) : #[cfd:int;n1:nat] (accept_v (sfd, cfd) | int cfd) = "mac#atslib_accept_err" // end of [accept_err] (* ****** ****** *) fun accept_null_err {sfd:int} (pfskt: !socket_v (sfd, listen) | sfd: int sfd) : [cfd:int] (option_v (socket_v (cfd, conn), cfd >= 0) | int cfd) = "atslib_accept_null_err" // end of [accept_null_err] fun accept_null_exn {sfd:int} ( pfskt: !socket_v (sfd, listen) | sfd: int sfd ) : [cfd:nat] (socket_v (cfd, conn) | int cfd) // for client side // end of [accept_null_exn] (* ****** ****** *) fun socket_close_err {fd:int} {s:status} ( pfskt: socket_v (fd, s) | fd: int fd ) : [i:int | i <= 0] (option_v (socket_v (fd, s), i < 0) | int i) = "mac#atslib_socket_close_err" // = atslib_close_err // end of [socket_close_err] // // HX: this one is like [fildes_close_loop_exn] // fun socket_close_exn {fd:int} {s:status} (pfskt: socket_v (fd, s) | fd: int fd): void // end of [socket_close_exn] (* ****** ****** *) abst@ype shutkind_t = int macdef SHUT_RD = $extval (shutkind_t, "SHUT_RD") macdef SHUT_WR = $extval (shutkind_t, "SHUT_WR") macdef SHUT_RDWR = $extval (shutkind_t, "SHUT_RDWR") // // HX: what error can occur? // fun shutdown_err {fd:int} ( // 0/-1 : succ/fail // errno set pfskt: socket_v (fd, conn) | fd: int fd, how: shutkind_t ) : [i:int | i <= 0] ( option_v (socket_v (fd, conn), i < 0) | int i ) = "mac#atslib_shutdown_err" // end of [shutdown_err] fun shutdown_exn // HX: this one is preferred! {fd:int} // 0/-1 : succ/fail // errno set (pfskt: socket_v (fd, conn) | fd: int fd, how: shutkind_t): void // end of [shutdown_exn] (* ****** ****** *) // // HX: actually implemented in [libc/CATS/fcntl.cats] // fun socket_read_err {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw(~1, n+1) = "mac#atslib_socket_read_err" // = atslib_fildes_read_err // end of [socket_read_err] // // HX: implemented in [libc/sys/DATSsocket.dats] // fun socket_read_exn {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : sizeLte n // end of [socket_read_exn] (* ****** ****** *) // // HX: actually implemented in [libc/CATS/fcntl.cats] // fun socket_write_err {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw(~1, n+1) = "mac#atslib_socket_write_err" // = atslib_fildes_write_err // end of [socket_write_err] // // HX: [socket_write_exn]: plesae use [socket_write_all_exn] instead // (* ****** ****** *) // // HX: // this one is actually implemented in [libc/DATS/fcntl.dats] // note that it is used only when it is known ahead how many bytes are expected; // otherwise, there is the risk of forever blocking!!! // fun socket_read_all_err {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw (~1, n+1) = "mac#atslib_socket_read_all_err" // = atslib_fildes_read_all_err // end of [socket_read_all_err] (* ****** ****** *) // // HX: this one is actually implemented in [libc/DATS/fcntl.dats] // fun socket_write_all_err {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : ssizeBtw(~1, n+1) = "mac#atslib_socket_write_all_err" // = atslib_fildes_write_all_err // end of [socket_write_all_err] // // HX: this one is implemented in [libc/sys/DATS/socket.dats] // fun socket_write_all_exn {fd:int} {n,sz:nat | n <= sz} ( pfskt: !socket_v (fd, conn) | fd: int fd, buf: &bytes sz, ntotal: size_t n ) : void // all bytes must be written if this function returns = "atslib_socket_write_all_exn" // end of [socket_write_all_exn] (* ****** ****** *) fun socket_write_substring {fd:int} {n:int} {st,ln:nat | st+ln <= n} ( pf_sock: !socket_v (fd, conn) | fd: int fd, str: string n, st: size_t st, ln: size_t ln ) : void // all bytes must be written if this function returns // end of [socket_write_substring] (* ****** ****** *) dataview socket_fdopen_v (fd: int, m: file_mode, addr) = | socket_fdopen_v_fail (fd, m, null) of socket_v (fd, conn) | {l:agz} socket_fdopen_v_succ (fd, m, l) of FILE m @ l fun socket_fdopen_err {fd:int} {m:file_mode} ( pf: socket_v (fd, conn) | fd: int fd, m: file_mode m ) : [l:addr] ( socket_fdopen_v (fd, m, l) | ptr l ) = "mac#atslib_socket_fdopen_err" // end of [socket_fdopen_err] (* ****** ****** *) fun setsockopt {a:t@ype} {fd:nat} ( fd: int fd , level: int , option: int , value: &a , valen: sizeof_t a ) : int = "atslib_setsockopt" // function! // end of [setsockopt] fun getsockopt_err {a:t@ype} {fd:nat} ( fd: int fd , level: int, option: int , value: &a? >> opt (a, i==0), valen: sizeof_t a ) : #[i:int | i <= 0] int i = "atslib_getsockopt_err" // function! // end of [getsockopt_err] (* ****** ****** *) fun sockatmark {fd:nat} (fd: int fd): int = "mac#atslib_sockatmark" (* ****** ****** *) (* end of [socket.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/poll.sats0000664000175000017500000000607612223166162020151 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/poll.cats" %} // end of [%{#] (* ****** ****** *) macdef POLLIN = $extval (usint, "POLLIN") // there is data to read macdef POLLPRI = $extval (usint, "POLLPRI") // there is urgent data to read macdef POLLOUT = $extval (usint, "POLLOUT") // writing now will not block // // HX: -D_XOPEN_SOURCE // macdef POLLRDNORM = $extval (usint, "POLLRDNORM") // normal data may be read macdef POLLRDBAND = $extval (usint, "POLLRDBAND") // priority data may be read macdef POLLWRNORM = $extval (usint, "POLLWRNORM") // writing now will not block macdef POLLWRBAND = $extval (usint, "POLLWRBAND") // priority data may be written // // HX: these are only available in Linux // macdef POLLMSG = $extval (usint, "POLLMSG") macdef POLLREMOVE = $extval (usint, "POLLREMOVE") macdef POLLRDHUP = $extval (usint, "POLLRDHUP") macdef POLLERR = $extval (usint, "POLLERR") // error condition macdef POLLHUP = $extval (usint, "POLLHUP") // hung up macdef POLLNVAL = $extval (usint, "POLLNVAL") // invalid polling request (* ****** ****** *) // // HX: typedef usint = uint_short_t0ype // typedef pollfd_struct = $extype_struct "ats_pollfd_type" of { fd= int // file descriptor to poll , events= usint // types of events poller cares about , revents= usint // types of events that actually occurred } // end of [pollfd_struct] typedef pollfd = pollfd_struct (* ****** ****** *) // // HX-2010-09-26: // By definition, we should assigne nfds_t (unsigned long) to nfds. // Is this really necessary? // fun poll {n:nat} (fds: &(@[pollfd][n]), nfds: int n, timeout: int): int = "atslib_poll" // end of [poll] (* ****** ****** *) (* end of [poll.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/socket_un.sats0000664000175000017500000000451512223166162021171 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // // HX: some convenience functions // (* ****** ****** *) %{# #include "libc/sys/CATS/socket_un.cats" %} // end of [%{#] (* ****** ****** *) staload "libc/sys/SATS/un.sats" staload "libc/sys/SATS/socket.sats" (* ****** ****** *) fun sockaddr_un_init ( sa: &sockaddr_un_struct? >> sockaddr_un_struct , af: sa_family_t, name: string ) :<> void = "atslib_sockaddr_un_init" // end of [sockaddr_un_init] (* ****** ****** *) fun connect_un_exn {fd:int} ( pf: !socket_v (fd, init) >> socket_v (fd, conn) | fd: int fd, servaddr: &sockaddr_un_struct // len=sizeof(sockaddr_un_struct) ) : void // end of [connect_un_exn] (* ****** ****** *) fun bind_un_exn {fd:int} ( pf_sock: !socket_v (fd, init) >> socket_v (fd, bind) | fd: int fd, servaddr: &sockaddr_un_struct // len=sizeof(sockaddr_un_struct) ) : void // end of [bind_un_exn] (* ****** ****** *) (* end of [socket_un.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/un.sats0000664000175000017500000000473012223166162017620 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/sys/CATS/un.cats" %} // end of [%{#] (* ****** ****** *) staload SA = "libc/sys/SATS/sockaddr.sats" typedef sa_family_t = $SA.sa_family_t stadef socklen_t = $SA.socklen_t // int: length of a sockaddr stadef sockaddr_struct = $SA.sockaddr_struct (* ****** ****** *) typedef sockaddr_un_struct = $extype_struct "ats_sockaddr_un_type" of { sun_family= sa_family_t , sun_path= @[byte][0] // @[byte][X] for X <= 100; X is implementation-dependent } // end of [sockaddr_un_struct] typedef sockaddr_un = sockaddr_un_struct // sta socklen_un : int // length of [sockaddr_un] (* stadef socklen_un = sizeof (sockaddr_un_struct) *) macdef socklen_un = $extval (socklen_t(socklen_un), "atslib_socklen_un") // praxi socklen_lte_un (): [socklen_un <= $SA.socklen_max] void praxi sockaddr_un_trans {l:addr} (pf: !sockaddr_un_struct @ l >> sockaddr_struct(socklen_un) @ l): void praxi sockaddr_trans_un {l:addr} (pf: !sockaddr_struct(socklen_un) @ l >> sockaddr_un_struct @ l): void // (* ****** ****** *) (* end of [un.sats] *) ats-lang-anairiats-0.2.11/libc/sys/SATS/sockopt.sats0000664000175000017500000001037712223166162020664 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) %{# #include "libc/sys/CATS/sockopt.cats" %} // end of [%{#] (* ****** ****** *) // // socket-level (in contrast to protocol-level) // macdef SOL_SOCKET = $extval (int, "SOL_SOCKET") (* ****** ****** *) macdef SO_DEBUG = $extval (int, "SO_DEBUG") macdef SO_REUSEADDR = $extval (int, "SO_REUSEADDR") macdef SO_TYPE = $extval (int, "SO_TYPE") macdef SO_ERROR = $extval (int, "SO_ERROR") macdef SO_DONTROUTE = $extval (int, "SO_DONTROUTE") macdef SO_BROADCAST = $extval (int, "SO_BROADCAST") macdef SO_SNDBUF = $extval (int, "SO_SNDBUF") macdef SO_RCVBUF = $extval (int, "SO_RCVBUF") macdef SO_SNDBUFFORCE = $extval (int, "SO_SNDBUFFORCE") macdef SO_RCVBUFFORCE = $extval (int, "SO_RCVBUFFORCE") macdef SO_KEEPALIVE = $extval (int, "SO_KEEPALIVE") macdef SO_OOBINLINE = $extval (int, "SO_OOBINLINE") macdef SO_NO_CHECK = $extval (int, "SO_NO_CHECK") macdef SO_PRIORITY = $extval (int, "SO_PRIORITY") macdef SO_LINGER = $extval (int, "SO_LINGER") macdef SO_BSDCOMPAT = $extval (int, "SO_BSDCOMPAT") macdef SO_PASSCRED = $extval (int, "SO_PASSCRED") macdef SO_PEERCRED = $extval (int, "SO_PEERCRED") macdef SO_RCVLOWAT = $extval (int, "SO_RCVLOWAT") macdef SO_SNDLOWAT = $extval (int, "SO_SNDLOWAT") macdef SO_RCVTIMEO = $extval (int, "SO_RCVTIMEO") macdef SO_SNDTIMEO = $extval (int, "SO_SNDTIMEO") macdef SO_SECURITY_AUTHENTICATION = $extval (int, "SO_SECURITY_AUTHENTICATION") macdef SO_SECURITY_ENCRYPTION_TRANSPORT = $extval (int, "SO_SECURITY_ENCRYPTION_TRANSPORT") macdef SO_SECURITY_ENCRYPTION_NETWORK = $extval (int, "SO_SECURITY_ENCRYPTION_NETWORK") macdef SO_BINDTODEVICE = $extval (int, "SO_BINDTODEVICE") macdef SO_ATTACH_FILTER = $extval (int, "SO_ATTACH_FILTER") macdef SO_DETACH_FILTER = $extval (int, "SO_DETACH_FILTER") macdef SO_PEERNAME = $extval (int, "SO_PEERNAME") macdef SO_TIMESTAMP = $extval (int, "SO_TIMESTAMP") macdef SCM_TIMESTAMP = $extval (int, "SCM_TIMESTAMP") macdef SO_ACCEPTCONN = $extval (int, "SO_ACCEPTCONN") macdef SO_PEERSEC = $extval (int, "SO_PEERSEC") macdef SO_PASSSEC = $extval (int, "SO_PASSSEC") macdef SO_TIMESTAMPNS = $extval (int, "SO_TIMESTAMPNS") macdef SCM_TIMESTAMPNS = $extval (int, "SCM_TIMESTAMPNS") macdef SO_MARK = $extval (int, "SO_MARK") macdef SO_TIMESTAMPING = $extval (int, "SO_TIMESTAMPING") macdef SCM_TIMESTAMPING = $extval (int, "SCM_TIMESTAMPING") macdef SO_PROTOCOL = $extval (int, "SO_PROTOCOL") macdef SO_DOMAIN = $extval (int, "SO_DOMAIN") macdef SO_RXQ_OVFL = $extval (int, "SO_RXQ_OVFL") (* ****** ****** *) // // HX: this one is used for SO_LINGER // typedef linger_struct = $extype_struct "ats_linger_type" of { l_onoff= int // on/off 1/0 , l_linger= int // time to linger in seconds } // end of [linger_struct] typedef linger = linger_struct (* ****** ****** *) (* end of [sockopt.sats] *) ats-lang-anairiats-0.2.11/libc/sys/DATS/0000700000175000017500000000000012223166162016243 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/sys/DATS/socket_un.dats0000664000175000017500000000602312223166162021127 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/stdio.sats" // for [perror] staload "libc/SATS/stdlib.sats" // for [EXIT_FAILURE] (* ****** ****** *) staload "libc/sys/SATS/un.sats" staload "libc/sys/SATS/socket.sats" (* ****** ****** *) staload "libc/sys/SATS/socket_un.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement connect_un_exn (pfsock | sfd, servaddr) = let prval () = sockaddr_un_trans (view@ servaddr) val (pfopt | err) = connect_err (pfsock | sfd, servaddr, socklen_un) prval () = sockaddr_trans_un (view@ servaddr) in if err >= 0 then let prval connect_v_succ (pf) = pfopt prval () = pfsock := pf in // nothing end else let prval connect_v_fail (pf) = pfopt prval () = pfsock := pf val () = perror ("connect") val () = exit (EXIT_FAILURE) in connect_un_exn (pfsock | sfd, servaddr) // HX: this is deadcode end // end of [if] end // end of [connect_un_exn] (* ****** ****** *) implement bind_un_exn (pfsock | sfd, servaddr) = let prval () = sockaddr_un_trans (view@ servaddr) val (pfopt | err) = bind_err (pfsock | sfd, servaddr, socklen_un) prval () = sockaddr_trans_un (view@ servaddr) in if err >= 0 then let prval bind_v_succ (pf) = pfopt prval () = pfsock := pf in // nothing end else let prval bind_v_fail (pf) = pfopt prval () = pfsock := pf val () = perror ("bind") val () = exit (EXIT_FAILURE) in bind_un_exn (pfsock | sfd, servaddr) // HX: this is deadcode end // end of [if] end // end of [bind_un_exn] (* ****** ****** *) (* end of [socket_un.dats] *) ats-lang-anairiats-0.2.11/libc/sys/DATS/stat.dats0000664000175000017500000000725012223166162020113 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/stdio.sats" // for [perror] (* ****** ****** *) staload "libc/sys/SATS/stat.sats" (* ****** ****** *) %{^ /* ****** ****** */ ats_void_type atslib_chmod_exn ( ats_ptr_type path, ats_mode_type mode ) { int err = chmod ((char*)path, mode) ; if (err < 0) { perror ("chmod"); ats_exit_errmsg (1, "exit(ATS): [chmod] failed.\n") ; } // end of [if] return ; } /* end of [atslib_chmod_exn] */ /* ****** ****** */ ats_void_type atslib_mkdir_exn ( ats_ptr_type path, ats_mode_type mode ) { int err = mkdir ((char*)path, mode) ; if (err < 0) { perror ("mkdir"); ats_exit_errmsg (1, "exit(ATS): [mkdir] failed.\n") ; } // end of [if] return ; } /* end of [atslib_mkdir_exn] */ /* ****** ****** */ ats_void_type atslib_stat_exn ( ats_ptr_type name, ats_ptr_type buf ) { int err ; err = stat ((char*)name, (ats_stat_type*)buf) ; if (err < 0) { perror ("stat"); ats_exit_errmsg (1, "exit(ATS): [stat] failed.\n") ; } // end of [if] return ; } /* end of [atslib_stat_exn] */ /* ****** ****** */ ats_void_type atslib_fstat_exn ( ats_int_type fd, ats_ptr_type buf ) { int err ; err = fstat (fd, (ats_stat_type*)buf) ; if (err < 0) { perror ("fstat"); ats_exit_errmsg (1, "exit(ATS): [fstat] failed.\n") ; } // end of [if] return ; } /* end of [atslib_fstat_exn] */ /* ****** ****** */ ats_void_type atslib_lstat_exn ( ats_ptr_type name, ats_ptr_type buf ) { int err ; err = lstat ((char*)name, (ats_stat_type*)buf) ; if (err < 0) { perror ("lstat"); ats_exit_errmsg (1, "exit(ATS): [lstat] failed.\n") ; } // end of [if] return ; } /* end of [atslib_lstat_exn] */ /* ****** ****** */ %} // end of [%{^] (* ****** ****** *) staload T = "libc/sys/SATS/types.sats" implement isfdtype (fd, m0) = let var stbuf: stat? val err = fstat_err (fd, stbuf) in if (err >= 0) then let prval () = opt_unsome {stat} (stbuf) val m1 = $T.lor_mode_mode (stbuf.st_mode, S_IFMT) in if $T.eq_mode_mode (m0, m1) then 1 else 0 end else let prval () = opt_unnone {stat} (stbuf) in ~1 (* error indication *) end // end of [if] end // end of [isfdtype] (* ****** ****** *) (* end of [stat.dats] *) ats-lang-anairiats-0.2.11/libc/sys/DATS/socket.dats0000664000175000017500000001361412223166162020431 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload UN = "prelude/SATS/unsafe.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" // for [errno_get] staload "libc/SATS/stdio.sats" // for [perror] staload "libc/SATS/stdlib.sats" // for [EXIT_FAILURE] (* ****** ****** *) staload "libc/sys/SATS/socket.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement socket_family_type_exn (af, socktp) = let val (pfopt | fd) = socket_family_type_err (af, socktp) in if fd >= 0 then let prval Some_v (pf) = pfopt in (pf | fd) end else let prval None_v () = pfopt val () = perror "socket" val () = exit_errmsg (EXIT_FAILURE, "exit(ATS): [socket] failed\n") in socket_family_type_exn (af, socktp) end // end of [if] end // end of [socket_family_type_exn] (* ****** ****** *) implement socket_close_exn (pfskt | fd) = let val (pfopt | i) = socket_close_err (pfskt | fd) in if i >= 0 then let prval None_v () = pfopt in (*nothing*) end else let prval Some_v (pfskt) = pfopt in if (errno_get () = EINTR) then socket_close_exn (pfskt | fd) else let val () = perror "close" val () = prerrf ("exit(ATS): [socket_close] failed.\n", @()) val () = exit_main {void} {..} {unit_v} (pfskt | EXIT_FAILURE) prval unit_v () = pfskt in // nothing end // end of [if] end // end of [if] end // end of [socket_close_exn] (* ****** ****** *) implement listen_exn (pfskt | fd, nbacklog) = let val (pfopt | err) = listen_err (pfskt | fd, nbacklog) in if (err >= 0) then let prval listen_v_succ (pf) = pfopt prval () = pfskt := pf in // nothing end else let prval listen_v_fail (pf) = pfopt prval () = pfskt := pf val () = perror "listen" val () = exit_errmsg (EXIT_FAILURE, "exit(ATS): [listen] failed\n") in listen_exn (pfskt | fd, nbacklog) // HX: this is deadcode end // end of [if] end // end of [listen_exn] (* ****** ****** *) implement accept_null_exn (pfskt | sfd) = let val (pfopt | cfd) = accept_null_err (pfskt | sfd) in if (cfd >= 0) then let prval Some_v (pfconn) = pfopt in (pfconn | cfd) end else let prval None_v () = pfopt val () = perror "accept" val () = exit_errmsg (EXIT_FAILURE, "exit(ATS): [accept] failed\n") in accept_null_exn (pfskt | sfd) // HX: this is deadcode end // end of [if] end // end of [accept_null_exn] (* ****** ****** *) implement shutdown_exn (pfskt | fd, how) = let val (pfopt | err) = shutdown_err (pfskt | fd, how) in if err >= 0 then let prval None_v () = pfopt in (*nothing*) end else let prval Some_v (pf) = pfopt prval () = pfskt := pf val () = perror "shutdown" val () = exit_errmsg (EXIT_FAILURE, "exit(ATS): [shutdown] failed\n") in shutdown_exn (pfskt | fd, how) // HX: this is deadcode end (* end of [if] *) end // end of [shutdown_exn] (* ****** ****** *) implement socket_read_exn (pfskt | fd, buf, ntot) = let val nread = socket_read_err (pfskt | fd, buf, ntot) in if nread >= 0 then size1_of_ssize1 (nread) else let val () = perror "socket_read" in exit_errmsg (EXIT_FAILURE, "[socket_read] failed.\n") end // end of [if] end // end of [socket_read_exn] (* ****** ****** *) implement socket_write_all_exn (pfskt | fd, buf, ntot) = let var err: int = 1 val nwrit = socket_write_all_err (pfskt | fd, buf, ntot) val () = if nwrit >= 0 then let val nwrit = size1_of_ssize1 (nwrit) in if (nwrit = ntot) then (err := 0) end // end of [if] in if err > 0 then let val () = perror "socket_write" in exit_errmsg (EXIT_FAILURE, "[socket_write_all] failed.\n") end (* end of [if] *) end // end of [socket_write_all_exn] (* ****** ****** *) implement socket_write_substring {fd} {n} {st,ln} (pfsock | fd, str, st, ln) = let // val (pf, fpf | p) = string_takeout_bufptr {n} {st} {ln} (str, st) val () = socket_write_all_exn (pfsock | fd, !p, ln) prval () = fpf (pf) in // nothing end // end of [socket_write_substring] (* ****** ****** *) %{$ ats_int_type atslib_getsockopt_err ( ats_int_type fd , ats_int_type level , ats_int_type option , ats_ref_type value , ats_size_type valen ) { socklen_t valen_int = (socklen_t)valen ; int err = getsockopt (fd, level, option, (void*)value, &valen_int) ; /* if (err == 0) { if (valen_int != (socklen_t)valen) ats_crash () ; } // end of [if] */ return err ; } // end of [atslib_getsockopt_err] %} // end of [%{$] (* ****** ****** *) (* end of [socket.dats] *) ats-lang-anairiats-0.2.11/libc/sys/DATS/socket_in.dats0000664000175000017500000000745412223166162021124 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/stdio.sats" // for [perror] staload "libc/SATS/stdlib.sats" // for [EXIT_FAILURE] (* ****** ****** *) staload "libc/netinet/SATS/in.sats" staload "libc/sys/SATS/socket.sats" (* ****** ****** *) staload "libc/sys/SATS/socket_in.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement bind_in_exn (pfsock | sfd, servaddr) = let prval () = sockaddr_in_trans (view@ servaddr) val (pfopt | err) = bind_err (pfsock | sfd, servaddr, socklen_in) prval () = sockaddr_trans_in (view@ servaddr) in if err >= 0 then let prval bind_v_succ (pf) = pfopt prval () = pfsock := pf in // nothing end else let prval bind_v_fail (pf) = pfopt prval () = pfsock := pf val () = perror ("bind") val () = exit (EXIT_FAILURE) in bind_in_exn (pfsock | sfd, servaddr) // HX: this is deadcode end // end of [if] end // end of [bind_in_exn] (* ****** ****** *) implement connect_in_exn (pfsock | sfd, servaddr) = let prval () = sockaddr_in_trans (view@ servaddr) val (pfopt | err) = connect_err (pfsock | sfd, servaddr, socklen_in) prval () = sockaddr_trans_in (view@ servaddr) in if err >= 0 then let prval connect_v_succ (pf) = pfopt prval () = pfsock := pf in // nothing end else let prval connect_v_fail (pf) = pfopt prval () = pfsock := pf val () = perror ("connect") val () = exit (EXIT_FAILURE) in connect_in_exn (pfsock | sfd, servaddr) // HX: this is deadcode end // end of [if] end // end of [connect_in_exn] (* ****** ****** *) (* fun accept_in_err {sfd:int} ( pfskt: !socket_v (sfd, listen) | sfd: int sfd , sa: &sockaddr_in_struct? >> opt (sockaddr_in_struct, cfd >= 0) , salen: &socklen_t(0)? >> socklen_t(n) ) : #[cfd:int;n:nat] (accept_v (sfd, cfd) | int cfd) // end of [accept_in_err] *) implement accept_in_err (pfskt | sfd, sa, salen) = let // extern prfun trans1 {l:addr} (pf: !sockaddr_in? @ l >> sockaddr_struct(socklen_in)? @ l): void extern prfun trans2 {b:bool} {l:addr} (pf: !opt (sockaddr_struct(socklen_in), b) @ l >> opt (sockaddr_in, b) @ l): void // prval () = trans1 (view@(sa)) val () = salen := socklen_in val (pfopt | cfd) = accept_err (pfskt | sfd, sa, salen) prval () = trans2 (view@(sa)) // in (pfopt | cfd) end // end of [accept_in_err] (* ****** ****** *) (* end of [socket_in.dats] *) ats-lang-anairiats-0.2.11/libc/arpa/0000700000175000017500000000000012223166162015615 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/arpa/CATS/0000700000175000017500000000000012223166162016347 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/arpa/CATS/inet.cats0000664000175000017500000000613012223166162020176 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_ARPA_INET_CATS #define ATS_LIBC_ARPA_INET_CATS /* ****** ****** */ #include #include /* ****** ****** */ #ifndef EXIT_SUCCESS #define EXIT_SUCCESS 0 #endif #ifndef EXIT_FAILURE #define EXIT_FAILURE 1 #endif /* ****** ****** */ extern void perror (const char *msg) ; // in [stdio.h] /* ****** ****** */ #include "libc/netinet/CATS/in.cats" /* ****** ****** */ // // HX: implemented in [prelude/DATS/basics.dats] // extern ats_void_type ats_exit_errmsg(ats_int_type n, ats_ptr_type msg) ; /* ****** ****** */ // #define atslib_htons htons #define atslib_ntohs ntohs // #define atslib_htonl htonl #define atslib_ntohl ntohl // /* ****** ****** */ ATSinline() ats_bool_type atslib_inet_aton_err ( ats_ptr_type cp, ats_ref_type inp ) { int rtn ; rtn = inet_aton((char*)cp, (ats_in_addr_type*)inp) ; return (rtn ? ats_true_bool : ats_false_bool) ; } // end of [atslib_inet_aton_err] ATSinline() ats_void_type atslib_inet_aton_exn ( ats_ptr_type cp, ats_ref_type inp ) { int rtn ; rtn = inet_aton((char*)cp, (ats_in_addr_type*)inp) ; if (rtn == 0) { ats_exit_errmsg(EXIT_FAILURE, "exit(ATS): [inet_aton] failed.\n") ; } // end of [if] return ; } /* end of [atslib_inet_aton_exn] */ /* ****** ****** */ #define atslib_inet_addr inet_addr #define atslib_inet_network inet_network /* ****** ****** */ #define atslib_inet_makeaddr inet_makeaddr /* ****** ****** */ #define atslib_inet_ntoa inet_ntoa /* ****** ****** */ #define atslib_inet4_pton(cp, inp) inet_pton(AF_INET4, cp, inp) #define atslib_inet6_pton(cp, inp) inet_pton(AF_INET6, cp, inp) /* ****** ****** */ #endif /* end of [ATS_LIBC_ARPA_INET_CATS] */ /* end of [in.cats] */ ats-lang-anairiats-0.2.11/libc/arpa/SATS/0000700000175000017500000000000012223166162016367 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/arpa/SATS/inet.sats0000664000175000017500000000761012223166162020242 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/arpa/CATS/inet.cats" %} // end of [%{#] (* ****** ****** *) staload IN = "libc/netinet/SATS/in.sats" typedef in_port_nbo_t = $IN.in_port_nbo_t typedef in_addr_hbo_t = $IN.in_addr_hbo_t typedef in_addr_nbo_t = $IN.in_addr_nbo_t typedef in_addr_struct = $IN.in_addr_struct (* ****** ****** *) abst@ype uint16_t0ype_netbyteord = uint16_t0ype typedef uint16_nbo = uint16_t0ype_netbyteord fun htons (i: uint16_t0ype): uint16_t0ype_netbyteord = "atslib_htons" fun ntohs (i: uint16_t0ype_netbyteord): uint16_t0ype = "atslib_ntohs" abst@ype uint32_t0ype_netbyteord = uint32_t0ype typedef uint32_nbo = uint32_t0ype_netbyteord fun htonl (i: uint32_t0ype): uint32_t0ype_netbyteord = "atslib_htonl" fun ntohl (i: uint32_t0ype_netbyteord): uint32_t0ype = "atslib_ntohl" (* ****** ****** *) castfn in_port_of_uint16_nbo (x: uint16_nbo): in_port_nbo_t castfn uint16_of_in_port_nbo (x: in_port_nbo_t): uint16_nbo (* ****** ****** *) fun inet_aton_err ( cp: string , inp: &in_addr_struct? >> opt (in_addr_struct, b) ) : #[b:bool] bool b = "atslib_inet_aton_err" // end of [inet_aton_err] fun inet_aton_exn ( cp: string, inp: &in_addr_struct? >> in_addr_struct ) : void = "atslib_inet_aton_exn" // end of [inet_aton_exn] (* ****** ****** *) // // HX: note that this one cannot tell // -1 from 255.255.255.255 (a valid address) // fun inet_addr (cp: string): in_addr_nbo_t = "mac#atslib_inet_addr" fun inet_network (cp: string): in_addr_hbo_t = "mac#atslib_inet_network" (* ****** ****** *) fun inet_makeaddr (net: int, host: int): in_addr_struct = "mac#atslib_inet_makeaddr" // end of [inet_makeaddr] (* ****** ****** *) // // HX: this function is not reentrant // fun inet_ntoa ( inp: in_addr_struct ) : [l:agz] ( strptr l - void | strptr l ) = "mac#atslib_inet_ntoa" // end of [inet_ntoa] (* ****** ****** *) fun inet_lnaof (addr: in_addr_struct): in_addr_hbo_t = "mac#atslib_inet_lnaof" // end of [inet_lnaof] fun inet_netof (addr: in_addr_struct): in_addr_hbo_t = "mac#atslib_inet_netof" // end of [inet_netof] (* ****** ****** *) fun inet4_pton ( cp: string // af=AF_INET , inp: &in_addr_struct? >> opt (in_addr_struct, i > 0) ) : #[i:int] int (i) = "mac#atslib_inet4_pton" // end of [inet4_pton] fun inet6_pton ( cp: string // af= AF_INET6 , inp: &in_addr_struct? >> opt (in_addr_struct, i > 0) ) : #[i:int] int (i) = "mac#atslib_inet6_pton" // end of [inet6_pton] (* ****** ****** *) (* end of [inet.sats] *) ats-lang-anairiats-0.2.11/libc/arpa/DATS/0000700000175000017500000000000012223166162016350 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/netinet/0000700000175000017500000000000012223166162016340 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/netinet/CATS/0000700000175000017500000000000012223166162017072 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/netinet/CATS/in.cats0000664000175000017500000000473212223166162020376 0ustar hwxihwxi/************************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /************************************************************************/ /* ** ATS - Unleashing the Power of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi. ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #ifndef ATS_LIBC_NETINET_IN_CATS #define ATS_LIBC_NETINET_IN_CATS /* ****** ****** */ #include #include /* ****** ****** */ typedef struct sockaddr_in ats_sockaddr_in_type ; #define atslib_socklen_in (sizeof(ats_sockaddr_in_type)) typedef struct sockaddr_in6 ats_sockaddr_in6_type ; #define atslib_socklen_in6 (sizeof(ats_sockaddr_in6_type)) /* ****** ****** */ ATSinline() in_port_t // in_port_nbo_t atslib_in_port_nbo_of_int (ats_int_type n) { in_port_t nport = n ; return htons (nport) ; } // end of [atslib_in_port_nbo_of_int] /* ****** ****** */ ATSinline() in_addr_t // in_addr_nbo_t atslib_in_addr_nbo_of_hbo (in_addr_t addr_hbo) { return htonl (addr_hbo) ; } /* end of [atslib_in_addr_nbo_of_hbo] */ /* ****** ****** */ typedef struct in_addr ats_in_addr_type ; ATSinline() in_addr_t // in_addr_nbo_t atslib_in_addr_struct_get_s_addr (ats_in_addr_type inp) { return (inp.s_addr) ; } /* end of [atslib_in_addr_struct_get_s_addr] */ /* ****** ****** */ #endif /* end of [ATS_LIBC_NETINET_IN_CATS] */ /* end of [in.cats] */ ats-lang-anairiats-0.2.11/libc/netinet/SATS/0000700000175000017500000000000012223166162017112 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/netinet/SATS/in.sats0000664000175000017500000002155612223166162020441 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) %{# #include "libc/netinet/CATS/in.cats" %} // end of [%{#] (* ****** ****** *) staload SA = "libc/sys/SATS/sockaddr.sats" typedef sa_family_t = $SA.sa_family_t stadef socklen_t = $SA.socklen_t // int: length of a sockaddr stadef sockaddr_struct = $SA.sockaddr_struct (* ****** ****** *) abst@ype ipproto_t = int macdef IPPROTO_IP = $extval (ipproto_t, "IPPROTO_IP") macdef IPPROTO_HOPOPTS = $extval (ipproto_t, "IPPROTO_HOPOPTS") macdef IPPROTO_ICMP = $extval (ipproto_t, "IPPROTO_ICMP") macdef IPPROTO_IGMP = $extval (ipproto_t, "IPPROTO_IGMP") macdef IPPROTO_IPIP = $extval (ipproto_t, "IPPROTO_IPIP") macdef IPPROTO_TCP = $extval (ipproto_t, "IPPROTO_TCP") macdef IPPROTO_EGP = $extval (ipproto_t, "IPPROTO_EGP") macdef IPPROTO_PUP = $extval (ipproto_t, "IPPROTO_PUP") macdef IPPROTO_UDP = $extval (ipproto_t, "IPPROTO_UDP") macdef IPPROTO_IDP = $extval (ipproto_t, "IPPROTO_IDP") macdef IPPROTO_TP = $extval (ipproto_t, "IPPROTO_TP") macdef IPPROTO_DCCP = $extval (ipproto_t, "IPPROTO_DCCP") macdef IPPROTO_IPV6 = $extval (ipproto_t, "IPPROTO_IPV6") macdef IPPROTO_ROUTING = $extval (ipproto_t, "IPPROTO_ROUTING") macdef IPPROTO_FRAGMENT = $extval (ipproto_t, "IPPROTO_FRAGMENT") macdef IPPROTO_RSVP = $extval (ipproto_t, "IPPROTO_RSVP") macdef IPPROTO_GRE = $extval (ipproto_t, "IPPROTO_GRE") macdef IPPROTO_ESP = $extval (ipproto_t, "IPPROTO_ESP") macdef IPPROTO_AH = $extval (ipproto_t, "IPPROTO_AH") macdef IPPROTO_ICMPV6 = $extval (ipproto_t, "IPPROTO_ICMPV6") macdef IPPROTO_NONE = $extval (ipproto_t, "IPPROTO_NONE") macdef IPPROTO_DSTOPTS = $extval (ipproto_t, "IPPROTO_DSTOPTS") macdef IPPROTO_MTP = $extval (ipproto_t, "IPPROTO_MTP") macdef IPPROTO_ENCAP = $extval (ipproto_t, "IPPROTO_ENCAP") macdef IPPROTO_PIM = $extval (ipproto_t, "IPPROTO_PIM") macdef IPPROTO_COMP = $extval (ipproto_t, "IPPROTO_COMP") macdef IPPROTO_SCTP = $extval (ipproto_t, "IPPROTO_SCTP") macdef IPPROTO_UDPLITE = $extval (ipproto_t, "IPPROTO_UDPLITE") macdef IPPROTO_RAW = $extval (ipproto_t, "IPPROTO_RAW") macdef IPPROTO_MAX = $extval (ipproto_t, "IPPROTO_MAX") (* ****** ****** *) abst@ype in_port_t = $extype"in_port_t" macdef IPPORT_ECHO = $extval (in_port_t, "IPPORT_ECHO") macdef IPPORT_DISCARD = $extval (in_port_t, "IPPORT_DISCARD") macdef IPPORT_SYSTAT = $extval (in_port_t, "IPPORT_SYSTAT") macdef IPPORT_DAYTIME = $extval (in_port_t, "IPPORT_DAYTIME") macdef IPPORT_NETSTAT = $extval (in_port_t, "IPPORT_NETSTAT") macdef IPPORT_FTP = $extval (in_port_t, "IPPORT_FTP") macdef IPPORT_TELNET = $extval (in_port_t, "IPPORT_TELNET") macdef IPPORT_SMTP = $extval (in_port_t, "IPPORT_SMTP") macdef IPPORT_TIMESERVER = $extval (in_port_t, "IPPORT_TIMESERVER") macdef IPPORT_NAMESERVER = $extval (in_port_t, "IPPORT_NAMESERVER") macdef IPPORT_WHOIS = $extval (in_port_t, "IPPORT_WHOIS") macdef IPPORT_MTP = $extval (in_port_t, "IPPORT_MTP") macdef IPPORT_TFTP = $extval (in_port_t, "IPPORT_TFTP") macdef IPPORT_RJE = $extval (in_port_t, "IPPORT_RJE") macdef IPPORT_FINGER = $extval (in_port_t, "IPPORT_FINGER") macdef IPPORT_TTYLINK = $extval (in_port_t, "IPPORT_TTYLINK") macdef IPPORT_SUPDUP = $extval (in_port_t, "IPPORT_SUPDUP") macdef IPPORT_EXECSERVER = $extval (in_port_t, "IPPORT_EXECSERVER") macdef IPPORT_LOGINSERVER = $extval (in_port_t, "IPPORT_LOGINSERVER") macdef IPPORT_CMDSERVER = $extval (in_port_t, "IPPORT_CMDSERVER") macdef IPPORT_EFSSERVER = $extval (in_port_t, "IPPORT_EFSSERVER") macdef IPPORT_BIFFUDP = $extval (in_port_t, "IPPORT_BIFFUDP") macdef IPPORT_WHOSERVER = $extval (in_port_t, "IPPORT_WHOSERVER") macdef IPPORT_ROUTESERVER = $extval (in_port_t, "IPPORT_ROUTESERVER") macdef IPPORT_RESERVED = $extval (in_port_t, "IPPORT_RESERVED") macdef IPPORT_USERRESERVED = $extval (in_port_t, "IPPORT_USERRESERVED") (* ****** ****** *) (* macdef INET_ADDRSTRLEN = 16 // for IPv4 dotted-decimal string macdef INET6_ADDRSTRLEN = 46 // for IPv6 hex string *) (* ****** ****** *) symintr in_port_nbo_of abst@ype in_port_nbo_t = $extype"in_port_t" castfn in_port_nbo_of_in_port (n: in_port_t): in_port_nbo_t overload in_port_nbo_of with in_port_nbo_of_in_port fun in_port_nbo_of_int (n: int): in_port_nbo_t = "atslib_in_port_nbo_of_int" overload in_port_nbo_of with in_port_nbo_of_int (* ****** ****** *) (* abst@ype in_addr_t = $extype"in_addr_t" *) abst@ype in_addr_hbo_t = $extype "in_addr_t" abst@ype in_addr_nbo_t = $extype "in_addr_t" (* ****** ****** *) fun in_addr_nbo_of_hbo (n: in_addr_hbo_t): in_addr_nbo_t = "atslib_in_addr_nbo_of_hbo" // end of [in_addr_nbo_of_hbo] (* constant addresses in host-byte-order *) // Address to accept any incoming messages: 0x00000000 macdef INADDR_ANY = $extval (in_addr_hbo_t, "INADDR_ANY") // Address to send to all hosts: 0xffffffff macdef INADDR_BROADCAST = $extval (in_addr_hbo_t, "INADDR_BROADCAST") // Address indicating an error return: 0xffffffff macdef INADDR_NONE = $extval (in_addr_hbo_t, "INADDR_NONE") // Network number for local host loopback #define IN_LOOPBACKNET 127 // Address to loopback in software to local host: 127.0.0.1 macdef INADDR_LOOPBACK = $extval (in_addr_hbo_t, "INADDR_LOOPBACK") (* Defines for Multicast INADDR *) // 0xe0000000 // 224.0.0.0 macdef INADDR_UNSPEC_GROUP = $extval (in_addr_hbo_t, "INADDR_UNSPEC_GROUP") // 0xe0000001 // 224.0.0.1 macdef INADDR_ALLHOSTS_GROUP = $extval (in_addr_hbo_t, "INADDR_ALLHOSTS_GROUP") // 0xe0000002 // 224.0.0.2 macdef INADDR_ALLRTRS_GROUP = $extval (in_addr_hbo_t, "INADDR_ALLRTRS_GROUP") // 0xe00000ff // 224.0.0.255 macdef INADDR_MAX_LOCAL_GROUP = $extval (in_addr_hbo_t, "INADDR_MAX_LOCAL_GROUP") (* ****** ****** *) typedef in_addr_struct = $extype_struct "ats_in_addr_type" of { s_addr= in_addr_nbo_t // IPv4 address of ulint } // end of [in_addr_struct] fun in_addr_struct_get_s_addr (inp: in_addr_struct): in_addr_nbo_t = "atslib_in_addr_struct_get_s_addr" // end of [in_addr_struct_get_s_addr] (* ****** ****** *) typedef sockaddr_in_struct = $extype_struct "ats_sockaddr_in_type" of { sin_family= sa_family_t , sin_port= in_port_nbo_t // uint16 , sin_addr= in_addr_struct } // end of [sockaddr_in_struct] typedef sockaddr_in = sockaddr_in_struct // sta socklen_in : int // length of [sockaddr_in] (* stadef socklen_in = sizeof (sockaddr_in_struct) *) macdef socklen_in = $extval (socklen_t(socklen_in), "atslib_socklen_in") // praxi socklen_lte_in (): [socklen_in <= $SA.socklen_max] void praxi sockaddr_in_trans {l:addr} (pf: !sockaddr_in_struct @ l >> sockaddr_struct(socklen_in) @ l): void praxi sockaddr_trans_in {l:addr} (pf: !sockaddr_struct(socklen_in) @ l >> sockaddr_in_struct @ l): void (* ****** ****** *) typedef in6_addr_struct = $extype_struct "ats_in6_addr_type" of { s6_addr= @[uint8][16] // IPv6 address of 16 bytes } // end of [in6_addr_struct] (* ****** ****** *) typedef sockaddr_in6_struct = $extype_struct "ats_sockaddr_in6_type" of { sin6_family= sa_family_t , sin6_port= in_port_nbo_t // uint16 , sin6_flowinfo= uint32 , sin6_addr= in6_addr_struct , sin6_scope_id= uint32 } // end of [sockaddr_in_struct] typedef sockaddr_in6 = sockaddr_in6_struct sta socklen_in6 : int // length of [sockaddr_in6] abst@ype sockaddr_in6_struct = $extype "ats_sockaddr_in6_type" macdef socklen_in6 = $extval (socklen_t(socklen_in6), "atslib_socklen_in6") // praxi socklen_lte_in6 (): [socklen_in6 <= $SA.socklen_max] void praxi sockaddr_in6_trans {l:addr} (pf: !sockaddr_in6_struct @ l >> sockaddr_struct(socklen_in6) @ l): void praxi sockaddr_trans_in6 {l:addr} (pf: !sockaddr_struct(socklen_in6) @ l >> sockaddr_in6_struct @ l): void // (* ****** ****** *) (* end of [in.sats] *) ats-lang-anairiats-0.2.11/libc/netinet/DATS/0000700000175000017500000000000012223166162017073 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/DATS/0000700000175000017500000000000012223166162015425 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/DATS/unistd.dats0000664000175000017500000001103312223166162017622 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) %{^ extern char **environ ; // in [unistd.h] extern void _exit (int status) ; // in [unistd.h] extern pid_t wait (int*) ; // in [sys/wait.h] %} // end of [%{^] (* ****** ****** *) staload TYPES = "libc/sys/SATS/types.sats" (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/unistd.sats" (* ****** ****** *) implement fork_exn () = pid where { val pid = fork_err () val iserr = $TYPES.int_of_pid(pid) < 0 val () = if iserr then let val errno = int_of (errno_get ()) val () = perror ("fork") in exit_errmsg (errno, "exit(ATS): [fork] failed.\n") end // end of [val] } // end of [atslib_fork_exn] (* ****** ****** *) %{^ ats_void_type atslib_fork_exec_cloptr_exn (ats_ptr_type f_child) { pid_t pid ; pid = fork () ; // if (pid < 0) { ats_exit_errmsg (errno, "exit(ATS): [fork] failed.\n") ; } // end of [if] // /* this is the parent */ if (pid > 0) { ATS_FREE (f_child) ; return ; } // /* this is the child */ ((ats_void_type (*)(ats_clo_ptr_type))((ats_clo_ptr_type)f_child)->closure_fun)(f_child) ; _exit (0) ; /* no need to flush STDIN, STDOUT and STDERR */ // return ; /* deadcode */ } /* end of [atslib_fork_exec_cloptr] */ /* ****** ****** */ ats_int_type atslib_fork_exec_and_wait_cloptr_exn (ats_ptr_type f_child) { pid_t pid ; int status ; // pid = fork () ; // if (pid < 0) { ats_exit_errmsg (errno, "exit(ATS): [fork] failed.\n") ; } // end of [if] // if (pid > 0) { ATS_FREE (f_child) ; if (wait (&status) < 0) return -1 ; return status ; } // end of [if] // /* this is the child */ ((ats_void_type (*)(ats_clo_ptr_type))((ats_clo_ptr_type)f_child)->closure_fun)(f_child) ; _exit (0) ; /* no need to flush STDIN, STDOUT and STDERR */ // return 0 ; /* deadcode */ } /* atslib_fork_exec_and_wait_cloptr_exn */ %} // end of [%{^] /* ****** ****** */ %{^ #define atslib_GETCWD_BUFSZ 64 ats_ptr_type atslib_getcwd0 () { char *buf, *res ; int sz = atslib_GETCWD_BUFSZ ; // buf = (char*)ats_malloc_gc(atslib_GETCWD_BUFSZ) ; // // HX: this strategy may not be so attractive; // an alternative is to use pathconf to get the maximum pathname length // while (1) { res = getcwd (buf, sz) ; if (!res) { ATS_FREE (buf) ; sz = sz + sz ; buf = ATS_MALLOC (sz) ; continue ; } // end of [if] break ; } // end of [while] // return buf ; } // end of [atslib_getcwd0] %} // end of [%{^] (* ****** ****** *) %{^ ats_int_type atslib_pipe ( ats_ptr_type pfd1, ats_ptr_type pfd2 ) { int err ; int pfd[2] ; err = pipe(pfd) ; if (err==0) { *(int*)pfd1 = pfd[0] ; *(int*)pfd2 = pfd[1] ; } // end of [if] return err ; } // end of [atslib_pipe] %} // end of [%{^] (* ****** ****** *) %{^ // extern ats_size_type atspre_ptrarr_size (ats_ptr_type p0) ; // ats_ptr_type atslib_environ_get_arrsz (size_t *sizep) { *sizep = atspre_ptrarr_size (environ) ; return environ; } // end of [atslib_environ_get_arrsz] // %} // end of [%{^] (* ****** ****** *) (* end of [unistd.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/errno.dats0000664000175000017500000000302312223166162017441 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) // it is empty so far (* ****** ****** *) (* end of [errno.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/pthread_upbarr.dats0000664000175000017500000001064212223166162021323 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/pthread_upbarr.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement pthread_upbarr_unitelim {v} (barr) = let prfn fpf (pf: @(unit_v, v)): v = let prval unit_v () = pf.0 in pf.1 end in pthread_upbarr_trans (fpf | barr) end // end of [pthread_upbarr_unitelim] (* ****** ****** *) implement pthread_upbarr_download_and_destroy (barr) = (pf | ()) where { val (pf | ()) = pthread_upbarr_download (barr) val () = pthread_upbarr_destroy (barr) } // end of [pthread_upbarr_download_and_destroy] (* ****** ****** *) %{^ /* ****** ****** */ ats_ptr_type atslib_pthread_upbarr_create () { ats_pthread_upbarr_t *p ; p = ATS_MALLOC(sizeof(ats_pthread_upbarr_t)) ; p->count = 0 ; if (pthread_cond_init (&p->cond_eqz, NULL)) goto FAIL ; if (pthread_mutex_init (&p->mutex_res, NULL)) goto FAIL ; return p ; FAIL: { ATS_FREE(p) ; ats_crash() ; return (ats_ptr_type)0 ; } // end of [if] } // end of [atslib_pthread_upbarr_create] /* ****** ****** */ ats_ptr_type atslib_pthread_upbarr_upticket_create (ats_ptr_type p) { if (pthread_mutex_lock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] ((ats_pthread_upticket_t*)p)->count += 1 ; if (pthread_mutex_unlock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] return p ; } // end of [atslib_pthread_upbarr_upticket_create] /* ****** ****** */ ats_void_type atslib_pthread_upbarr_download (ats_ptr_type p) { int count ; pthread_cond_t *eqz = &((ats_pthread_upbarr_t*)p)->cond_eqz ; pthread_mutex_t *res = &((ats_pthread_upbarr_t*)p)->mutex_res ; // if (pthread_mutex_lock(res)) ats_crash() ; // while (1) { count = ((ats_pthread_upbarr_t*)p)->count ; if (count == 0) break ; if (pthread_cond_wait (eqz, res)) ats_crash() ; } // end of [while] // if (pthread_mutex_unlock(res)) ats_crash() ; // return ; } // end of [atslib_pthread_upbarr_download] /* ****** ****** */ ats_void_type atslib_pthread_upbarr_destroy (ats_ptr_type p) { pthread_cond_destroy (&((ats_pthread_upbarr_t*)p)->cond_eqz) ; pthread_mutex_destroy (&((ats_pthread_upbarr_t*)p)->mutex_res) ; ATS_FREE(p) ; } // end of [atslib_pthread_upbarr_destroy] /* ****** ****** */ ats_void_type atslib_pthread_upbarr_upticket_upload_and_destroy (ats_ptr_type p) { int count1 ; // if (pthread_mutex_lock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] count1 = ((ats_pthread_upticket_t*)p)->count - 1 ; ((ats_pthread_upticket_t*)p)->count = count1 ; if (pthread_mutex_unlock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] // if (count1 == 0) { if (pthread_cond_signal(&((ats_pthread_upticket_t*)p)->cond_eqz)) ats_crash() ; // end of [if] } // end of [if] // return ; } // end of [atslib_pthread_upbarr_upticket_upload_and_destroy] /* ****** ****** */ %} // end of [%{^] (* ****** ****** *) (* end of [pthread_upbarr.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/fcntl.dats0000664000175000017500000001531512223166162017431 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/stdio.sats" staload "libc/SATS/stdlib.sats" (* ****** ****** *) staload "libc/SATS/fcntl.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading is needed (* ****** ****** *) macdef errno_is_EINTR () = (errno_get () = EINTR) (* ****** ****** *) #define i2sz size1_of_int1 #define ssz2sz size1_of_ssize1 #define i2ssz ssize1_of_int1 #define sz2ssz ssize1_of_size1 (* ****** ****** *) implement close_loop_err {fd} (pf_fd | fd) = $effmask_all (loop (pf_fd | fd)) where { fun loop (pf_fd: fildes_v (fd) | fd: int fd) : [i:int] (close_v (fd, i) | int i) = let val (pf_err | i) = close_err (pf_fd | fd) in if i >= 0 then (pf_err | i) else begin if errno_is_EINTR () then let prval close_v_fail pf_fd = pf_err in loop (pf_fd | fd) end else (pf_err | i) // end of [if] end // end of [if] end (* end of [loop] *) } // end of [close_loop_err] implement close_loop_exn (pf_fd | fd) = let val (pf_err | i) = close_loop_err (pf_fd | fd) in if (i >= 0) then let prval close_v_succ () = pf_err in (*empty*) end else let prval close_v_fail pf_fd = pf_err val () = perror ("close") val () = prerrf ("exit(ATS): [close_loop] failed\n", @()) val () = exit_main {void} {..} {unit_v} (pf_fd | EXIT_FAILURE) prval unit_v () = pf_fd in // empty end // end of [if] end // end of [close_loop_exn] (* ****** ****** *) extern praxi bytes_v_split {n,i:nat | i <= n} {l:addr} (pf: bytes n @ l): @(bytes i @ l, bytes (n-i) @ l + i) extern praxi bytes_v_unsplit {n1,n2:nat} {l:addr} (pf1: bytes n1 @ l, pf2: bytes n2 @ l + n1): bytes (n1+n2) @ l (* ****** ****** *) implement read_all_err {fd} {sz,n} (pf_fd | fd, buf, ntotal) = let fun loop {nleft:nat | nleft <= n} {l:addr} ( pf_fd: !fildes_v (fd) , pf_buf: !bytes (sz-n+nleft) @ l | fd: int fd, p_buf: ptr l, nleft: size_t nleft, err: &int ) : sizeLte n = if nleft > 0 then let val [nread:int] nread = read_err (pf_fd | fd, !p_buf, nleft) in if nread > 0 then let val nread = ssz2sz nread prval @(pf1_buf, pf2_buf) = bytes_v_split {sz-n+nleft,nread} (pf_buf) val nleft2 = loop (pf_fd, pf2_buf | fd, p_buf + nread, nleft - nread, err) prval () = pf_buf := bytes_v_unsplit (pf1_buf, pf2_buf) in nleft2 end else let // nread <= 0 val retry = begin if nread < 0 then errno_is_EINTR () else false (*EOF*) end : bool // end of [val] in if retry then loop (pf_fd, pf_buf | fd, p_buf, nleft, err) else (if nread < 0 then err := err + 1; nleft) end // end of [if] end else begin i2sz 0 // all bytes are read end // end of [if] // end of [loop] var err: int = 0 val nleft = loop (pf_fd, view@ buf | fd, &buf, ntotal, err) in if err = 0 then sz2ssz (ntotal - nleft) else i2ssz (~1) end // end of [read_all_err] implement read_all_exn (pf_fd | fd, buf, ntotal) = let val nread = read_all_err (pf_fd | fd, buf, ntotal) in if nread >= 0 then ssz2sz (nread) else let val () = perror "read" in exit_errmsg (EXIT_FAILURE, "exit(ATS): [read_all] failed\n") end (* end of [if] *) end // end of [read_all_exn] (* ****** ****** *) implement write_all_err {fd} {sz,n} (pf_fd | fd, buf, ntotal) = let fun loop {nleft:nat | nleft <= n} {l:addr} ( pf_fd: !fildes_v (fd) , pf_buf: !bytes (sz-n+nleft) @ l | fd: int fd, p_buf: ptr l, nleft: size_t nleft, err: &int ) : sizeLte n = if nleft > 0 then let val [nwrit:int] nwrit = write_err (pf_fd | fd, !p_buf, nleft) in if nwrit > 0 then let val nwrit = ssz2sz (nwrit) prval @(pf1_buf, pf2_buf) = bytes_v_split {sz-n+nleft,nwrit} (pf_buf) val nleft2 = loop (pf_fd, pf2_buf | fd, p_buf + nwrit, nleft - nwrit, err) prval () = pf_buf := bytes_v_unsplit (pf1_buf, pf2_buf) in nleft2 end else let val retry = (if nwrit < 0 then errno_is_EINTR () else true): bool in if retry then loop (pf_fd, pf_buf | fd, p_buf, nleft, err) else (err := err + 1; nleft) end // end of [if] end else begin i2sz 0 // all bytes are written end // end of [if] // end of [loop] var err: int = 0 val nleft = loop (pf_fd, view@ buf | fd, &buf, ntotal, err) in if err = 0 then sz2ssz (ntotal - nleft) else i2ssz (~1) end // end of [write_all_err] (* ****** ****** *) implement write_all_exn (pf_fd | fd, buf, ntotal) = let var err: int = 0 val nwrit = write_all_err (pf_fd | fd, buf, ntotal) val () = if nwrit >= 0 then let val nwrit = ssz2sz (nwrit) in if nwrit < ntotal then (err := err + 1) end else (err := err + 1) // end of [if] in if err > 0 then let val () = perror "write" in exit_errmsg (EXIT_FAILURE, "exit(ATS): [write_all]: failed\n") end (* end of [if] *) end // end of [write_all_exn] (* ****** ****** *) %{$ ats_void_type atslib_close_exn (ats_int_type fd) { int err = close(fd) ; if (err < 0) { perror ("close") ; fprintf (stderr, "exit(ATS): [close(%i)] failed\n", (fd)) ; exit (EXIT_FAILURE) ; } // end of [atslib_close_exn] return ; } // end of [atslib_close_exn] %} // end of [%{$] (* ****** ****** *) (* end of [fcntl.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/string.dats0000664000175000017500000000351012223166162017623 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. ** *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/string.sats" (* ****** ****** *) implement strdup_gc (str) = let val n = strlen (str) val (pf_gc, pf_buf | p_buf) = malloc_gc (n + 1) val p_buf = strcpy (pf_buf | p_buf, str) in @(pf_gc, pf_buf | p_buf) end // end of [strdup_gc] (* ****** ****** *) (* end of string.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/complex.dats0000664000175000017500000000534212223166162017771 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "libc/SATS/complex.sats" (* ****** ****** *) %{^ // ccmplx = ats_fcomplex_type // zcmplx = ats_dcomplex_type ats_fcomplex_type atslib_ccmplx_imag_unit = _Complex_I ; ats_dcomplex_type atslib_zcmplx_imag_unit = _Complex_I ; // // print functions // ats_void_type atslib_fprint_ccmplx (ats_ptr_type out, ats_fcomplex_type c) { int n ; float c_i = cimagf(c) ; if (c_i >= 0.0) { n = fprintf((FILE *)out, "%f+i*%f", crealf(c), c_i) ; } else { n = fprintf((FILE *)out, "%f-i*%f", crealf(c), -c_i) ; } return ; } // end of [ats_fprint_ccmplx] ats_void_type atslib_fprint_zcmplx (ats_ptr_type out, ats_dcomplex_type z) { int n ; double z_i = cimag(z) ; if (z_i >= 0.0) { n = fprintf((FILE *)out, "%f+i*%f", creal(z), z_i) ; } else { n = fprintf((FILE *)out, "%f-i*%f", creal(z), -z_i) ; } return ; } // end of [ats_fprint_zcmplx] %} // end of [{%{^] (* ****** ****** *) implement print_ccmplx (c) = print_mac (fprint_ccmplx, c) implement prerr_ccmplx (c) = prerr_mac (fprint_ccmplx, c) implement print_zcmplx (z) = print_mac (fprint_zcmplx, z) implement prerr_zcmplx (z) = prerr_mac (fprint_zcmplx, z) (* ****** ****** *) (* end of [complex.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/dlfcn.dats0000664000175000017500000000345412223166162017412 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/dlfcn.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading is needed (* ****** ****** *) implement dlerror_clr () = let val (fpf_msg | msg) = dlerror () // clearing any existing error prval () = fpf_msg (msg) in // nothing end // end of [dlerror_clr] (* ****** ****** *) (* end of [dlfcn.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/stdarg.dats0000664000175000017500000000352112223166162017603 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/stdarg.sats" (* ****** ****** *) implement va_arg (ap) = va_arg_int (ap) implement va_arg (ap) = va_arg_ptr (ap) implement va_arg (ap) = va_arg_bool (ap) implement va_arg (ap) = va_arg_char (ap) (* // this one is the same as [var_arg] // implement va_arg (ap) = va_arg_string (ap) *) (* ****** ****** *) (* end of [stdarg.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/stdio.dats0000664000175000017500000000414712223166162017446 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/errno.sats" staload "libc/SATS/stdio.sats" (* ****** ****** *) implement fclose1_loop (pf | p) = let val err = fclose1_err (pf | p) in if err = 0 then let prval None_v () = pf in 0 end else let prval Some_v pf = pf val errno = errno_get () in if (errno = EINTR) then fclose1_loop (pf | p) else let prval () = __assert (pf) where { extern prfun __assert {v:view} (pf: v): void } // end of [prval] in err end // end of [if] end // end of [if] end // end of [if] (* ****** ****** *) (* end of [stdio.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/stdlib.dats0000664000175000017500000000552112223166162017602 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/string.sats" staload "libc/SATS/stdlib.sats" (* ****** ****** *) implement putenv {l} (nameval) = let val n = strptr_length (nameval) val [n:int] n = size1_of_size (n) val [l1:addr] (pfopt | p) = malloc_ngc (n + 1) in if p > null then let prval malloc_v_succ (pfngc, pfbuf) = pfopt val _p = __copy (pfbuf | p, nameval) where { extern fun __copy ( pf: !b0ytes (n+1) @ l1 >> strbuf (n+1, n) @ l1 | p: ptr l1, name: !strptr l ) :<> void = "mac#atslib_strcpy" } // end of [val] val (pfopt | err) = __putenv (pfbuf | p) where { extern fun __putenv {m,n:int} {l:addr} (pfbuf: strbuf (n+1, n) @ l1 | p: ptr l1) : [i:int] (option_v (bytes(n+1) @ l1, i <> 0) | int i)= "mac#putenv" } // end of [val] val () = if err = 0 then let prval None_v () = pfopt prval () = __assert (pfngc) where { extern prfun __assert {v:view} (pf: v):<> void } // end of [prval] in // nothing end else let // err <> 0 prval Some_v (pfbuf) = pfopt val () = free_ngc (pfngc, pfbuf | p) in // nothing end // end of [if] in err end else let prval malloc_v_fail () = pfopt in ~1 // HX: [ENOMEM] should already be set end (* end of [if] *) end // end of [putenv] (* ****** ****** *) (* end of [stdlib.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/random.dats0000664000175000017500000001233512223166162017602 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload _(*anon*) = "prelude/DATS/array.dats" (* ****** ****** *) staload "libc/sys/SATS/time.sats" // for gettimeofday staload "libc/sys/SATS/types.sats" // for several lint_of* functions (* ****** ****** *) staload "libc/SATS/random.sats" (* ****** ****** *) implement srand48_with_gettimeofday () = let var tv: timeval? val err = gettimeofday (tv) val () = if err = 0 then let prval () = opt_unsome {timeval} (tv) val seed = (lint_of)tv.tv_sec * 1000000L + (lint_of)tv.tv_usec val () = srand48 (seed) in // nothing end else let prval () = opt_unnone {timeval} (tv) in // nothing end // end of [if] in err (* 0/-1 : succ/fail *) end // end of [srand48_with_gettimeofday] (* ****** ****** *) implement randint {n} (n) = let val d01 = drand48 () val r = int_of (d01 * n) val [r:int] r = int1_of (r) prval () = __assert () where { extern prfun __assert (): [0 <= r; r <= n] void } // end of [prval] in if r < n then r else 0 end // end of [randint] local staload UN = "prelude/SATS/unsafe.sats" in // in of [local] implement randsize {n} (n) = let val d01 = drand48 () val r = ullint_of_double (d01 * (double_of_size)n) val r = $UN.cast2size (r) val [r:int] r = size1_of_size (r) prval () = __assert () where { extern prfun __assert (): [0 <= r; r <= n] void } // end of [prval] in if r < n then r else (size1_of_int1)0 end // end of [randsize] end // end of [local] (* ****** ****** *) implement randperm {n} (n) = let typedef elt = natLt (n) val asz = size1_of_int1 (n) val (pfgc, pfarr | p) = array_ptr_alloc (asz) val () = loop (pfarr | n, p, 0) where { fun loop {i:nat | i <= n} {l:addr} .. ( pfarr: !array_v (int?, n-i, l) >> array_v (elt, n-i, l) | n: int n, p: ptr l, i: int i ) :<> void = if i < n then let prval (pfat1, pfarr2) = array_v_uncons {int?} (pfarr) val () = !p := i val () = loop (pfarr2 | n, p + sizeof, i+1) prval () = pfarr := array_v_cons {elt} (pfat1, pfarr2) in // nothing end else let prval () = array_v_unnil {int?} (pfarr) prval () = pfarr := array_v_nil {elt} () in // nothing end // end of [if] // end of [loop] } // end of [val] val () = loop (pfarr | n, p, 0) where { fun loop {i:nat | i <= n} {l:addr} .. ( pfarr: !array_v (elt, n-i, l) | n: int n, p: ptr l, i: int i ) : void = if n - i >= 2 then let val k = randint (n-i) val () = array_ptr_exch__intsz (!p, 0, k) prval (pfat1, pfarr2) = array_v_uncons {elt} (pfarr) val () = loop (pfarr2 | n, p+sizeof, i+1) prval () = pfarr := array_v_cons {elt} (pfat1, pfarr2) in // nothing end // end of [if] // end of [loop] } // end of [val] in (pfgc, pfarr | p) end // end of [randperm] (* ****** ****** *) implement randint_r {n} (buf, n, res) = let var d01: double val _0 = drand48_r (buf, d01) val r = int_of (d01 * n) val [r:int] r = int1_of (r) prval () = __assert () where { extern prfun __assert (): [0 <= r; r <= n] void } // end of [prval] in if r < n then res := r else res := 0 end // end of [randint_r] local staload UN = "prelude/SATS/unsafe.sats" in // in of [local] implement randsize_r {n} (buf, n, res) = let var d01: double val _0 = drand48_r (buf, d01) val r = ullint_of (d01 * (double_of_size)n) val r = $UN.cast2size (r) val [r:int] r = size1_of_size (r) prval () = __assert () where { extern prfun __assert (): [0 <= r; r <= n] void } // end of [prval] in if r < n then res := r else res := (size1_of_int1)0 end // end of [randint_r] end // end of [local] (* ****** ****** *) (* end of [random.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/math.dats0000664000175000017500000000322012223166162017244 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) // HX: It is currently empty (* ****** ****** *) (* end of [math.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/gmp.dats0000664000175000017500000001274712223166162017114 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // there is no need for dynloading at run-time (* ****** ****** *) staload "libc/SATS/gmp.sats" (* ****** ****** *) %{ ats_void_type atslib_mpz_inp_str_exn ( ats_mpz_ptr_type x , ats_ptr_type file , ats_int_type base ) { size_t n = mpz_inp_str(x, (FILE*)file, base) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpz_inp_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpz_inp_str_exn] ats_void_type atslib_mpz_out_str_exn ( ats_ptr_type file , ats_int_type base , const ats_mpz_ptr_type x ) { size_t n = mpz_out_str((FILE*)file, base, (mpz_ptr)x) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpz_out_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpz_out_str_exn] %} // end of [%{] implement print_mpz (x) = print_mac (fprint1_mpz, x) implement prerr_mpz (x) = prerr_mac (fprint1_mpz, x) implement tostrptr_mpz (x) = mpz_get_str (10, x) implement tostring_mpz (x) = let val str = mpz_get_str (10, x) in string_of_strptr (str) end // end of [tostring_mpz] (* ****** ****** *) implement mpq_incby (x, p, q) = let val (pf_xp, fpf_xp | p_xp) = mpq_numref (x) val (pf_xq, fpf_xq | p_xq) = mpq_denref (x) val () = mpz_mul (!p_xp, q) val () = mpz_addmul (!p_xp, !p_xq, p) val () = mpz_mul (!p_xq, q) prval () = fpf_xp (pf_xp) prval () = fpf_xq (pf_xq) in mpq_canonicalize (x) end // end of [mpq_incby] implement mpq_decby (x, p, q) = let val (pf_xp, fpf_xp | p_xp) = mpq_numref (x) val (pf_xq, fpf_xq | p_xq) = mpq_denref (x) val () = mpz_mul (!p_xp, q) val () = mpz_submul (!p_xp, !p_xq, p) val () = mpz_mul (!p_xq, q) prval () = fpf_xp (pf_xp) prval () = fpf_xq (pf_xq) in mpq_canonicalize (x) end // end of [mpq_decby] (* ****** ****** *) implement mpq_pow3_ui (res, x, n) = let // val (pf_resp, fpf_resp | p_resp) = mpq_numref (res) val (pf_xp, fpf_xp | p_xp) = mpq_numref (x) val () = mpz_pow_ui (!p_resp, !p_xp, n) prval () = fpf_xp (pf_xp) prval () = fpf_resp (pf_resp) // val (pf_resq, fpf_resq | p_resq) = mpq_denref (res) val (pf_xq, fpf_xq | p_xq) = mpq_denref (x) val () = mpz_pow_ui (!p_resq, !p_xq, n) prval () = fpf_xq (pf_xq) prval () = fpf_resq (pf_resq) // in // no need for cannonicalizing end // end of [mpq_pow3_ui] implement mpq_pow2_ui (x, n) = let // val (pf_xp, fpf_xp | p_xp) = mpq_numref (x) val () = mpz_pow_ui (!p_xp, n) prval () = fpf_xp (pf_xp) // val (pf_xq, fpf_xq | p_xq) = mpq_denref (x) val () = mpz_pow_ui (!p_xq, n) prval () = fpf_xq (pf_xq) // in // no need for cannonicalizing end // end of [mpq_pow2_ui] (* ****** ****** *) %{ ats_void_type atslib_mpq_inp_str_exn ( ats_mpq_ptr_type x , ats_ptr_type file , ats_int_type base ) { size_t n = mpq_inp_str(x, (FILE*)file, base) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpq_inp_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpq_inp_str_exn] ats_void_type atslib_mpq_out_str_exn ( ats_ptr_type file , ats_int_type base , const ats_mpq_ptr_type x ) { size_t n = mpq_out_str((FILE*)file, base, (mpq_ptr)x) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpq_out_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpq_out_str_exn] %} // end of [%{] implement print_mpq (x) = print_mac (fprint1_mpq, x) implement prerr_mpq (x) = prerr_mac (fprint1_mpq, x) (* ****** ****** *) %{ ats_void_type atslib_mpf_inp_str_exn ( ats_mpf_ptr_type x , ats_ptr_type file , ats_int_type base ) { size_t n = mpf_inp_str(x, (FILE*)file, base) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpf_inp_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpf_inp_str_exn] ats_void_type atslib_mpf_out_str_exn ( ats_ptr_type file , ats_int_type base , ats_size_type ndigit , const ats_mpf_ptr_type x ) { size_t n = mpf_out_str((FILE*)file, base, ndigit, (mpf_ptr)x) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpf_out_str] failed.\n") ; } // end of [if] return ; } // end of [atslib_mpf_out_str_exn] %} // end of [%{] (* ****** ****** *) (* end of [gmp.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/pthread_uplock.dats0000664000175000017500000000607712223166162021334 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/pthread_uplock.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) implement pthread_uplock_download_and_destroy (lock) = (pf | ()) where { val (pf | ()) = pthread_uplock_download (lock) val () = pthread_uplock_destroy (lock) } // end of [pthread_uplock_download_and_destroy] (* ****** ****** *) %{^ /* ****** ****** */ ats_ptr_type atslib_pthread_uplock_create () { ats_pthread_uplock_t *p ; p = (ats_pthread_uplock_t*)ATS_MALLOC(sizeof(ats_pthread_uplock_t)) ; if (pthread_mutex_init(&p->mutex_res, NULL)) { ATS_FREE(p) ; ats_crash() ; } // end of [if] return p ; } // end of [atslib_pthread_uplock_create] ats_ptr_type atslib_pthread_uplock_upticket_create (ats_ptr_type p) { if (pthread_mutex_lock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] return p ; } // end of [atslib_pthread_uplock_upticket_create] ats_void_type atslib_pthread_uplock_upticket_upload_and_destroy (ats_ptr_type p) { if (pthread_mutex_unlock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] return ; } // end of [atslib_pthread_uplock_upticket_upload_and_destroy] /* ****** ****** */ ats_void_type atslib_pthread_uplock_download (ats_ptr_type p) { if (pthread_mutex_lock(&((ats_pthread_uplock_t*)p)->mutex_res)) ats_crash() ; // end of [if] if (pthread_mutex_unlock(&((ats_pthread_upticket_t*)p)->mutex_res)) ats_crash() ; // end of [if] return ; } // end of [atslib_pthread_uplock_download] /* ****** ****** */ %} // end of [%{^] (* ****** ****** *) (* end of [pthread_uplock.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/printf.dats0000664000175000017500000000470212223166162017623 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/stdarg.sats" (* ****** ****** *) staload "libc/SATS/printf.sats" (* ****** ****** *) implement printf (fmt, arg) = let // [va_start (arg, fmt)] is emitted by 'atsopt' val ntot = vprintf (fmt, arg) val () = va_end (arg) in ntot (* the number of bytes output by the call *) end // end of [fprintf] (* ****** ****** *) implement fprintf (pfmod | out, fmt, arg) = let // [va_start (arg, fmt)] is emitted by 'atsopt' val ntot = vfprintf (pfmod | out, fmt, arg) val () = va_end (arg) in ntot (* the number of bytes output by the call *) end // end of [fprintf] (* ****** ****** *) implement snprintf (pf_buf | p_buf, m2, fmt, arg) = let // [va_start (arg, fmt)] is emitted by 'atsopt' val ntot = vsnprintf (pf_buf | p_buf, m2, fmt, arg) val () = va_end (arg) in ntot (* the number of bytes should be output by the call *) end // end of [snprintf] (* ****** ****** *) (* end of [printf.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/pthread.dats0000664000175000017500000001320112223166162017742 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2010 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload STDIO = "libc/SATS/stdio.sats" (* ****** ****** *) staload "libc/SATS/pthread.sats" (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) (* fun pthread_create_detached_cloptr (f: () - void): void // closure must be freed to avoid leak! // end of [pthread_create_detached_cloptr] *) implement pthread_create_detached_exn {vt} (f, env, tid) = let var env = env val ret = pthread_create_detached (f, env, tid) in if :(env: vt?) => (ret = 0) then let prval () = opt_unnone {vt} (env) in // nothing end else let prval () = opt_unsome {vt} (env) prval () = __leak (env) where { extern praxi __leak (x: !vt >> vt?):<> void } // end of [prval] val () = $STDIO.perror ("pthread_create") in exit_errmsg (1, "exit(ATS): [pthread_create] failed\n") end // end of [if] end // end of [pthread_create_detached_exn] implement pthread_create_detached_cloptr (f, tid) = let fun app (f: () - void): void = (f (); cloptr_free (f)) in pthread_create_detached_exn(app, f, tid) end // end of [pthread_create_detached_cloptr] (* ****** ****** *) %{^ /* ****** ****** */ ats_int_type atslib_pthread_spin_init_locked (ats_ptr_type p, ats_int_type pshared) { int err ; err = pthread_spin_init((pthread_spinlock_t*)p, pshared) ; if (err) return err ; err = pthread_spin_lock((pthread_spinlock_t*)p) ; if (err) { pthread_spin_destroy((pthread_spinlock_t*)p) ; return err ; } // end of [if] return 0 ; } // end of [atslib_pthread_spin_init_locked] ATSinline() ats_int_type atslib_pthread_spin_init_unlocked (ats_ptr_type p, ats_int_type pshared) { int err = pthread_spin_init((pthread_spinlock_t*)p, pshared) ; return err ; } // end of [atslib_pthread_spin_init_unlocked] /* ****** ****** */ ats_ptr_type atslib_pthread_spin_create_locked (ats_int_type pshared) { int err ; pthread_spinlock_t *p ; p = (pthread_spinlock_t*)ATS_MALLOC(sizeof(pthread_spinlock_t)) ; err = atslib_pthread_spin_init_locked(p, pshared) ; if (err) { ATS_FREE(p) ; return (pthread_spinlock_t*)0 ; } // end of [if] return p ; } // end of [atslib_pthread_spin_create_locked] ats_ptr_type atslib_pthread_spin_create_unlocked (ats_int_type pshared) { int err ; pthread_spinlock_t *p ; p = (pthread_spinlock_t*)ATS_MALLOC(sizeof(pthread_spinlock_t)) ; err = atslib_pthread_spin_init_unlocked(p, pshared) ; if (err) { ATS_FREE(p) ; return (pthread_spinlock_t*)0 ; } // end of [if] return p ; } // end of [atslib_pthread_spin_create_unlocked] /* ****** ****** */ ats_int_type atslib_pthread_mutex_init_locked (ats_ptr_type p) { int err ; err = pthread_mutex_init((pthread_mutex_t*)p, NULL) ; if (err) return err ; err = pthread_mutex_lock((pthread_mutex_t*)p) ; if (err) { pthread_mutex_destroy((pthread_mutex_t*)p) ; return err ; } // end of [if] return 0 ; } // end of [atslib_pthread_mutex_init_locked] ATSinline() ats_int_type atslib_pthread_mutex_init_unlocked (ats_ptr_type p) { int err = pthread_mutex_init((pthread_mutex_t*)p, NULL) ; return err ; } // end of [atslib_pthread_mutex_init_unlocked] /* ****** ****** */ ats_ptr_type atslib_pthread_mutex_create_locked () { int err ; pthread_mutex_t *p ; p = (pthread_mutex_t*)ATS_MALLOC(sizeof(pthread_mutex_t)) ; err = atslib_pthread_mutex_init_locked(p) ; if (err) { ATS_FREE(p) ; return (pthread_mutex_t*)0 ; } // end of [if] return p ; } // end of [atslib_pthread_mutex_create_locked] ats_ptr_type atslib_pthread_mutex_create_unlocked () { int err ; pthread_mutex_t *p ; p = (pthread_mutex_t*)ATS_MALLOC(sizeof(pthread_mutex_t)) ; err = atslib_pthread_mutex_init_unlocked(p) ; if (err) { ATS_FREE(p) ; return (pthread_mutex_t*)0 ; } // end of [if] return p ; } // end of [atslib_pthread_mutex_create_unlocked] /* ****** ****** */ ats_ptr_type atslib_pthread_cond_create () { pthread_cond_t *p ; p = (pthread_cond_t*)ATS_MALLOC(sizeof(pthread_cond_t)) ; if (pthread_cond_init(p, NULL)) { ATS_FREE(p) ; return (pthread_cond_t*)0 ; } // end of [if] return p ; } // end of [atslib_pthread_cond_create] /* ****** ****** */ %} // end of [%{^] (* ****** ****** *) (* end of [pthread.dats] *) ats-lang-anairiats-0.2.11/libc/DATS/dirent.dats0000664000175000017500000000764212223166162017614 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2009 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_DYNLOADFLAG 0 // no dynamic loading (* ****** ****** *) staload "libc/SATS/dirent.sats" (* ****** ****** *) implement dirent_stream_vt_make_DIR {l_dir:addr} (pf_dir | p_dir) = $ldelay ( res where { var res: stream_vt_con dirent ; val () = f (pf_dir | p_dir, res) } // end of [where] , $effmask_exn (closedir_exn (pf_dir | p_dir)) ) where { extern fun readdir_r (_: &DIR, _: &dirent? >> dirent, _: &ptr? >> Ptr):<> int = "mac#atslib_readdir_r" fn f ( pf_dir: DIR @ l_dir | p_dir: ptr l_dir, res: &stream_vt_con dirent? >> stream_vt_con dirent ) : void = let var ret: ptr // uninitialized val () = (res := stream_vt_cons {dirent} (?, ?)) val+ stream_vt_cons (!p_x, !p_xs) = res val err = readdir_r (!p_dir, !p_x, ret) val islast = if (err <> 0) then true else (ret = null) in if islast then let val () = $effmask_exn (closedir_exn (pf_dir | p_dir)) in free@ {dirent} res; res := stream_vt_nil () end else let val () = !p_xs := dirent_stream_vt_make_DIR (pf_dir | p_dir) in fold@ res end // end of [if] end // end of [f] } // end of [dirent_stream_vt_make_DIR] (* ****** ****** *) implement direntptr_stream_vt_make_DIR {l_dir:addr} (pf_dir | p_dir) = $ldelay ( res where { var res: stream_vt_con dirent ; val () = f (pf_dir | p_dir, res) } // end of [where] , $effmask_exn (closedir_exn (pf_dir | p_dir)) ) where { extern fun readdir_r (_: &DIR, _: &dirent? >> dirent, _: &ptr? >> Ptr):<> int = "mac#atslib_readdir_r" fn f ( pf_dir: DIR @ l_dir | p_dir: ptr l_dir , res: &stream_vt_con direntptr_gc? >> stream_vt_con direntptr_gc ) : void = let var ret: ptr // uninitialized val (pf_ent_gc, pf_ent | p_ent) = ptr_alloc_tsz {dirent} (sizeof) val err = readdir_r (!p_dir, !p_ent, ret) val islast = if (err <> 0) then true else (ret = null) in if islast then let val () = ptr_free {dirent?} (pf_ent_gc, pf_ent | p_ent) val () = $effmask_exn (closedir_exn (pf_dir | p_dir)) in res := stream_vt_nil () end else let val x = (pf_ent_gc, pf_ent | p_ent): direntptr_gc val () = (res := stream_vt_cons {direntptr_gc} (x, ?)) val+ stream_vt_cons (!p_x, !p_xs) = res val () = !p_xs := direntptr_stream_vt_make_DIR (pf_dir | p_dir) in fold@ res end // end of [if] end (* end of [f] *) } // end of [direntptr_stream_vt_make_DIR] (* ****** ****** *) (* end of [dirent.dats] *) ats-lang-anairiats-0.2.11/libc/gdbm/0000700000175000017500000000000012223166162015603 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/gdbm/CATS/0000700000175000017500000000000012223166162016335 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/gdbm/CATS/gdbm.cats0000664000175000017500000000530512223166162020141 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #include /* ****** ****** */ #include "libc/gdbm/CATS/datum.cats" /* ****** ****** */ ATSinline() gdbm_error atslib_gdbm_errno_get () { return gdbm_errno ; } /* ****** ****** */ #define atslib_gdbm_open gdbm_open #define atslib_gdbm_close gdbm_close #define atslib_gdbm_store gdbm_store #define atslib_gdbm_fetch gdbm_fetch #define atslib_gdbm_exists gdbm_exists #define atslib_gdbm_delete gdbm_delete #define atslib_gdbm_firstkey gdbm_firstkey #define atslib_gdbm_nextkey gdbm_nextkey #define atslib_gdbm_reorganize gdbm_reorganize #define atslib_gdbm_sync gdbm_sync #define atslib_gdbm_export gdbm_export #define atslib_gdbm_import gdbm_import #define atslib_gdbm_strerror gdbm_strerror /* ****** ****** */ #define atslib_gdbm_setopt gdbm_setopt /* #define getdbm_getopt getdbm_setopt // HX: they are the same! */ #define atslib_gdbm_getopt gdbm_setopt #ifdef GDBM_GETDBNAME ATSinline() gdbm_getdbname ( ats_ptr_type dbf ) { int err ; char *dbname ; err = gdbm_setopt((GDBM_FILE)dbf, GDBM_GETDBNAME, &dbname, sizeof(void*)) ; if (err < 0) return (char*)0 ; return dbname ; } // end of [gdbm_getdbname] #endif // end of [GDBM_GETDBNAME] /* ****** ****** */ #define atslib_gdbm_fdesc gdbm_fdesc /* ****** ****** */ /* end of [gdbm.cats] */ ats-lang-anairiats-0.2.11/libc/gdbm/CATS/ndbm.cats0000664000175000017500000000405212223166162020146 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #include /* ****** ****** */ #include "libc/gdbm/CATS/datum.cats" /* ****** ****** */ #define atslib_ndbm_open dbm_open #define atslib_ndbm_close dbm_close #define atslib_ndbm_store dbm_store #define atslib_ndbm_fetch dbm_fetch #define atslib_ndbm_delete dbm_delete #define atslib_ndbm_firstkey dbm_firstkey #define atslib_ndbm_nextkey dbm_nextkey #define atslib_ndbm_error dbm_error #define atslib_ndbm_clearerr dbm_clearerr #define atslib_ndbm_dirfno dbm_dirfno #define atslib_ndbm_pagfno dbm_pagfno #define atslib_ndbm_rdonly dbm_rdonly /* ****** ****** */ /* end of [ndbm.cats] */ ats-lang-anairiats-0.2.11/libc/gdbm/CATS/datum.cats0000664000175000017500000000523412223166162020343 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ /* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) */ /* ****** ****** */ #include "libc/CATS/string.cats" /* ****** ****** */ typedef datum ats_datum_type ; /* ****** ****** */ ATSinline() ats_bool_type atslib_gdbm_datum_is_valid (ats_datum_type x) { return (x.dptr != NULL) ; } // end of [atslib_gdbm_datum_is_valid] ATSinline() ats_ptr_type atslib_gdbm_datum_takeout_ptr (ats_datum_type x) { return x.dptr ; } // end of [atslib_gdbm_datum_takeout_ptr] /* ****** ****** */ extern ats_ptr_type atslib_strdup_gc (ats_ptr_type str) ; ATSinline() ats_datum_type atslib_gdbm_datum_make0_string (char *str) { datum res ; res.dptr = str ; res.dsize = (int)(atslib_strlen(str) + 1) ; // HX: account for the trailing null char! return res ; } // end of [atslib_gdbm_datum_make0_string] ATSinline() ats_datum_type atslib_gdbm_datum_make1_string (char *str) { datum res ; res.dptr = (char*)atslib_strdup_gc(str) ; res.dsize = (int)(atslib_strlen(str) + 1) ; // HX: account for the trailing null char! return res ; } // end of [atslib_gdbm_datum_make1_string] /* ****** ****** */ ATSinline() ats_void_type atslib_gdbm_datum_free (ats_datum_type x) { if (x.dptr != NULL) ATS_FREE (x.dptr) ; return ; } // end of [atslib_gdbm_datum_free] /* ****** ****** */ /* end of [datum.cats] */ ats-lang-anairiats-0.2.11/libc/gdbm/SATS/0000700000175000017500000000000012223166162016355 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/gdbm/SATS/datum.sats0000664000175000017500000000534712223166162020410 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) absviewtype dptr_addr_int_viewtype (l:addr, n:int) stadef dptr = dptr_addr_int_viewtype castfn ptr_of_dptr {l:addr} {n:int} (x: !dptr(l, n)):<> ptr (l) overload ptr_of with ptr_of_dptr viewtypedef datum (l:addr, n:int) = $extype_struct "datum" of { dptr= dptr(l, n), dsize= int(n) } // end of [datum] viewtypedef datum0 = [l:addr;n:int] datum (l, n) viewtypedef datum1 = [l:addr;n:int | l > null; n >= 0] datum (l, n) // for valid data // end of [datum1] (* ****** ****** *) viewdef fdptr (l:addr, n:int) = dptr (l, n) - void (* ****** ****** *) fun datum_is_valid {n:int} {l:addr} (x: datum (l, n)): bool (l > null) = "mac#atslib_gdbm_datum_is_valid" // end of [datum_is_valid] fun datum_takeout_ptr {l:addr} {n:int} (x: datum (l, n)):<> dptr (l, n) = "mac#atslib_gdbm_datum_takeout_ptr" // end of [datum_takeout_ptr] (* ****** ****** *) // // HX: implemented in [gdbm.cats] // fun datum_make0_string (str: string): [l:agz;n:nat] (dptr (l, n) - void | datum (l, n)) = "mac#atslib_gdbm_datum_make0_string" // end of [datum_make0_string] fun datum_make1_string (str: string): datum1 = "mac#atslib_gdbm_datum_make1_string" // end of [datum_make1_string] fun datum_free (x: datum0): void = "mac#atslib_gdbm_datum_free" (* ****** ****** *) (* end of [datum.sats] *) ats-lang-anairiats-0.2.11/libc/gdbm/SATS/ndbm.sats0000664000175000017500000001010112223166162020176 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) %{# #include "libc/gdbm/CATS/ndbm.cats" %} // end of [%{#] (* ****** ****** *) staload FCNTL = "libc/SATS/fcntl.sats" typedef flag_t = $FCNTL.flag_t staload TYPES = "libc/sys/SATS/types.sats" typedef mode_t = $TYPES.mode_t (* ****** ****** *) #include "libc/gdbm/SATS/datum.sats" (* ****** ****** *) absviewtype DBMptr (lf:addr) viewtypedef DBMptr0 = [lf:agez] DBMptr (lf) castfn DBMptr_free_null (dbf: DBMptr null): ptr null castfn ptr_of_DBMptr {l:addr} (dbf: !DBMptr l): ptr l overload ptr_of with ptr_of_DBMptr (* ****** ****** *) (* DBM * dbm_open (char *file , int flags , int mode ) *) fun dbm_open ( file: string, flags: flag_t, mode: mode_t ) : DBMptr0 = "mac#atslib_ndbm_open" (* ****** ****** *) fun dbm_close {lf:addr} (dbf: DBMptr lf): void = "mac#atslib_ndbm_close" // end of [dbm_close] (* ****** ****** *) (* datum dbm_fetch (DBM *dbf , datum key ) *) fun dbm_fetch {lf:agz} {l:agz} {n:nat} ( dbf: !DBMptr (lf), key: !datum (l, n) ) : [l1:addr;n1:int] (fdptr (l1, n1) | datum (l1, n1)) = "mac#atslib_ndbm_fetch" (* ****** ****** *) macdef DBM_INSERT = $extval (int, "DBM_INSERT") macdef DBM_REPLACE = $extval (int, "DBM_REPLACE") (* int dbm_store (DBM *dbf , datum key , datum content , int mode ) *) fun dbm_store {lf:agz} {l1,l2:agz} {n1,n2:nat} ( dbf: !DBMptr (lf), key: !datum (l1, n1), content: !datum (l2, n2), mode: int ) : int = "mac#atslib_ndbm_store" (* ****** ****** *) (* int dbm_delete (DBM *dbf , datum key ) *) fun dbm_delete {lf:agz} {l:agz} {n:nat} ( dbf: !DBMptr lf, key: !datum (l, n) ) : int(*err*) = "mac#dbm_delete" // succ/fail: 0/-1 // end of [dbm_delete] (* ****** ****** *) (* datum dbm_firstkey (DBM *dbf ) *) fun dbm_firstkey {lf:agz} ( dbf: !DBMptr (lf) ) : [l1:addr;n1:int] (fdptr (l1, n1) | datum (l1, n1)) = "mac#atslib_ndbm_firstkey" fun dbm_nextkey {lf:agz} ( dbf: !DBMptr (lf) ) : [l1:addr;n1:int] (fdptr (l1, n1) | datum (l1, n1)) = "mac#atslib_ndbm_nextkey" (* ****** ****** *) fun dbm_error {lf:agz} (dbf: !DBMptr (lf)): int = "mac#atslib_ndbm_error" // end of [dbm_error] fun dbm_clearerr {lf:agz} (dbf: !DBMptr (lf)): void = "mac#atslib_ndbm_clearerr" // end of [dbm_clearerr] (* ****** ****** *) fun dbm_dirfno {lf:agz} (dbf: !DBMptr (lf)): int = "mac#atslib_ndbm_dirfno" // end of [dbm_dirfno] fun dbm_pagfno {lf:agz} (dbf: !DBMptr (lf)): int = "mac#atslib_ndbm_pagfno" // end of [dbm_pagfno] (* ****** ****** *) fun dbm_rdonly {lf:agz} (dbf: !DBMptr (lf)): int = "mac#atslib_ndbm_rdonly" // end of [dbm_rdonly] (* ****** ****** *) (* end of [ndbm.sats] *) ats-lang-anairiats-0.2.11/libc/gdbm/SATS/gdbm.sats0000664000175000017500000002365512223166162020211 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** Copyright (C) 2002-2011 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, write to the Free ** Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) #define ATS_STALOADFLAG 0 // there is no need for staloading at run-time (* ****** ****** *) %{# #include "libc/gdbm/CATS/gdbm.cats" %} // end of [%{#] (* ****** ****** *) staload FCNTL = "libc/SATS/fcntl.sats" typedef flag_t = $FCNTL.flag_t staload TYPES = "libc/sys/SATS/types.sats" typedef mode_t = $TYPES.mode_t (* ****** ****** *) #include "libc/gdbm/SATS/datum.sats" (* ****** ****** *) absviewtype GDBM_FILE (lf:addr) // HX: a boxed viewtype castfn GDBM_FILE_free_null (dbf: GDBM_FILE (null)):<> ptr null castfn ptr_of_GDBM_FILE {lf:addr} (dbf: !GDBM_FILE lf):<> ptr (lf) overload ptr_of with ptr_of_GDBM_FILE (* ****** ****** *) // abst@ype gdbm_error = int // macdef GDBM_NO_ERROR = $extval (gdbm_error, "GDBM_NO_ERROR") macdef GDBM_MALLOC_ERROR = $extval (gdbm_error, "GDBM_MALLOC_ERROR") macdef GDBM_BLOCK_SIZE_ERROR = $extval (gdbm_error, "GDBM_BLOCK_SIZE_ERROR") macdef GDBM_FILE_OPEN_ERROR = $extval (gdbm_error, "GDBM_FILE_OPEN_ERROR") macdef GDBM_FILE_WRITE_ERROR = $extval (gdbm_error, "GDBM_FILE_WRITE_ERROR") macdef GDBM_FILE_SEEK_ERROR = $extval (gdbm_error, "GDBM_FILE_SEEK_ERROR") macdef GDBM_FILE_READ_ERROR = $extval (gdbm_error, "GDBM_FILE_READ_ERROR") macdef GDBM_BAD_MAGIC_NUMBER = $extval (gdbm_error, "GDBM_BAD_MAGIC_NUMBER") macdef GDBM_EMPTY_DATABASE = $extval (gdbm_error, "GDBM_EMPTY_DATABASE") macdef GDBM_CANT_BE_READER = $extval (gdbm_error, "GDBM_CANT_BE_READER") macdef GDBM_CANT_BE_WRITER = $extval (gdbm_error, "GDBM_CANT_BE_WRITER") macdef GDBM_READER_CANT_DELETE = $extval (gdbm_error, "GDBM_READER_CANT_DELETE") macdef GDBM_READER_CANT_STORE = $extval (gdbm_error, "GDBM_READER_CANT_STORE") macdef GDBM_READER_CANT_REORGANIZE = $extval (gdbm_error, "GDBM_READER_CANT_REORGANIZE") macdef GDBM_UNKNOWN_UPDATE = $extval (gdbm_error, "GDBM_UNKNOWN_UPDATE") macdef GDBM_ITEM_NOT_FOUND = $extval (gdbm_error, "GDBM_ITEM_NOT_FOUND") macdef GDBM_REORGANIZE_FAILED = $extval (gdbm_error, "GDBM_REORGANIZE_FAILED") macdef GDBM_CANNOT_REPLACE = $extval (gdbm_error, "GDBM_CANNOT_REPLACE") macdef GDBM_ILLEGAL_DATA = $extval (gdbm_error, "GDBM_ILLEGAL_DATA") macdef GDBM_OPT_ALREADY_SET = $extval (gdbm_error, "GDBM_OPT_ALREADY_SET") macdef GDBM_OPT_ILLEGAL = $extval (gdbm_error, "GDBM_OPT_ILLEGAL") macdef GDBM_BYTE_SWAPPED = $extval (gdbm_error, "GDBM_BYTE_SWAPPED") macdef GDBM_BAD_FILE_OFFSET = $extval (gdbm_error, "GDBM_BAD_FILE_OFFSET") macdef GDBM_BAD_OPEN_FLAGS = $extval (gdbm_error, "GDBM_BAD_OPEN_FLAGS") // fun gdbm_errno_get (): gdbm_error = "mac#atslib_gdbm_errno_get" // (* ****** ****** *) val gdbm_version : string = "mac#atslib_gdbm_version" // pre-allocated val gdbm_version_number : array (int, 3) = "mac#atslib_gdbm_version_number" // pre-allocated // end of [gdbm_version_number] (* ****** ****** *) fun gdm_version_cmp (x: &(@[int][3]), y: &(@[int][3])):<> int = "mac#atslib_gdbm_version_cmp" // end of [gdm_version_cmp] (* ****** ****** *) (* #define GDBM_READER 0 /* A reader. */ #define GDBM_WRITER 1 /* A writer. */ #define GDBM_WRCREAT 2 /* A writer. Create the db if needed. */ #define GDBM_NEWDB 3 /* A writer. Always create a new db. */ #define GDBM_FAST 0x10 /* Write fast! => No fsyncs. OBSOLETE. */ #define GDBM_SYNC 0x20 /* Sync operations to the disk. */ #define GDBM_NOLOCK 0x40 /* Don't do file locking operations. */ *) macdef GDBM_READER = $extval (int, "GDBM_READER") macdef GDBM_WRITER = $extval (int, "GDBM_WRITER") macdef GDBM_WRCREAT = $extval (int, "GDBM_WRCREAT") macdef GDBM_NEWDB = $extval (int, "GDBM_NEWDB") macdef GDBM_FAST = $extval (int, "GDBM_FAST") macdef GDBM_SYNC = $extval (int, "GDBM_SYNC") macdef GDBM_NOLOCK = $extval (int, "GDBM_NOLOCK") (* GDBM_FILE gdbm_open (name, block_size, flags, mode, fatal_func); *) // // fatal_func: (string) -> void // fun gdbm_open ( name: string , block_size: int, flags: int, mode: mode_t, fatal_func: ptr ) : [lf:agez] GDBM_FILE (lf) = "mac#atslib_gdbm_open" // end of [gdbm_open] (* ****** ****** *) (* void gdbm_close(dbf); *) fun gdbm_close {lf:addr} ( dbf: GDBM_FILE lf ) : void = "mac#atslib_gdbm_close" // end of [gdbm_close] (* ****** ****** *) (* int gdbm_store(dbf, key, content, flag); *) (* #define GDBM_INSERT 0 /* Never replace old data with new. */ #define GDBM_REPLACE 1 /* Always replace old data with new. */ *) macdef GDBM_INSERT = $extval (int, "GDBM_INSERT") macdef GDBM_REPLACE = $extval (int, "GDBM_REPLACE") fun gdbm_store {lf:agz} {l1,l2:addr} {n1,n2:nat} ( dbf: !GDBM_FILE lf, key: !datum(l1, n1), content: !datum(l2, n2), flag: int ) : int(*err*) = "mac#atslib_gdbm_store" // end of [gdbm_store] (* ****** ****** *) (* datum gdbm_fetch(dbf, key); *) fun gdbm_fetch {lf:agz} {l:agz} {n:int} ( dbf: !GDBM_FILE lf, key: !datum (l, n) ) : datum0 = "mac#atslib_gdbm_fetch" // the return value is malloced // end of [gdbm_fetch] (* int gdbm_exists(dbf, key); *) fun gdbm_exists {lf:agz} {l:agz} {n:int} ( dbf: !GDBM_FILE lf, key: !datum (l, n) ) : int // true/false: 1/0 = "mac#atslib_gdbm_exists" // end of [gdbm_exists] (* ****** ****** *) (* int gdbm_delete(dbf, key); *) fun gdbm_delete {lf:agz} {l:agz} {n:int} ( dbf: !GDBM_FILE lf, key: !datum (l, n) ) : int // succ/fail: 0/-1 = "mac#atslib_gdbm_delete" // end of [gdbm_delete] (* ****** ****** *) (* datum gdbm_firstkey(dbf); *) fun gdbm_firstkey {lf:agz} ( dbf: !GDBM_FILE lf ) : datum0 = "mac#atslib_gdbm_firstkey" // end of [gdbm_firstkey] (* ****** ****** *) (* datum gdbm_nextkey(dbf, key); *) fun gdbm_nextkey {lf:agz} {l:agz} {n:int} ( dbf: !GDBM_FILE l, prev: !datum(l, n) ) : datum0 = "mac#atslib_gdbm_nextkey" // end of [gdbm_nextkey] (* ****** ****** *) (* int gdbm_reorganize(dbf); *) fun gdbm_reorganize {lf:agz} (dbf: !GDBM_FILE lf): int = "mac#atslib_gdbm_reorganize" // end of [gdbm_reorganize] (* ****** ****** *) (* void gdbm_sync(dbf); *) fun gdbm_sync {lf:agz} (dbf: !GDBM_FILE lf): void = "mac#atslib_gdbm_sync" // end of [gdbm_sync] (* ****** ****** *) (* int gdbm_export (GDBM FILE dbf, const char *exportfile,int flag, int mode); *) fun gdbm_export {lf:agz} ( dbf: !GDBM_FILE lf, exportfile: string, flag: int, mode: mode_t ) : int = "mac#atslib_gdbm_export" // end of [gdbm_export] (* ****** ****** *) (* int gdbm_import (GDBM FILE dbf , const char *importfile , int flag); *) fun gdbm_import {lf:agz} ( dbf: !GDBM_FILE lf, importfile: string, flag: int ) : int = "mac#atslib_gdbm_import" // end of [gdbm_import] (* ****** ****** *) (* char *gdbm_strerror(int errno); *) fun gdbm_strerror (errno: gdbm_error): string(*pre-allocated*) = "mac#atslib_gdbm_strerror" // end of [gdbm_strerror] (* ****** ****** *) (* int gdbm_setopt(dbf, option, value, size); *) abst@ype gdbmsetopt(a:t@ype) = int abst@ype gdbmgetopt(a:t@ype) = int // macdef GDBM_CACHESIZE = $extval (gdbmsetopt(size_t), "GDBM_CACHESIZE") macdef GDBM_SETCACHESIZE = $extval (gdbmsetopt(size_t), "GDBM_SETCACHESIZE") macdef GDBM_GETCACHESIZE = $extval (gdbmgetopt(size_t), "GDBM_GETCACHESIZE") // macdef GDBM_GETFLAGS = $extval (gdbmgetopt(int), "GDBM_GETFLAGS") // macdef GDBM_FASTMODE = $extval (gdbmsetopt(int), "GDBM_FASTMODE") // macdef GDBM_SYNCMODE = $extval (gdbmsetopt(int), "GDBM_SYNCMODE") macdef GDBM_SETSYNCMODE = $extval (gdbmsetopt(int), "GDBM_SETSYNCMODE") macdef GDBM_GETSYNCMODE = $extval (gdbmgetopt(int), "GDBM_GETSYNCMODE") // macdef GDBM_COALESCEBLKS = $extval (gdbmsetopt(int), "GDBM_COALESCEBLKS") macdef GDBM_SETCOALESCEBLKS = $extval (gdbmsetopt(int), "GDBM_SETCOALESCEBLKS") macdef GDBM_GETCOALESCEBLKS = $extval (gdbmgetopt(int), "GDBM_GETCOALESCEBLKS") // macdef GDBM_SETMAXMAPSIZE = $extval (gdbmsetopt(size_t), "GDBM_SETMAXMAPSIZE") macdef GDBM_GETMAXMAPSIZE = $extval (gdbmgetopt(size_t), "GDBM_GETMAXMAPSIZE") // macdef GDBM_SETMMAP = $extval (gdbmsetopt(int), "GDBM_SETMMAP") macdef GDBM_GETMMAP = $extval (gdbmgetopt(int), "GDBM_GETMMAP") // (* GDBM_GETDBNAME = $extval (gdbmgetopt(ptr), "GDBM_GETDBNAME") *) // (* ****** ****** *) fun gdbm_setopt {a:t@ype} {lf:agz} ( dbf: !GDBM_FILE lf , option: gdbmsetopt(a), value: &a, size: sizeof_t(a) ) : int(*err*) = "mac#atslib_gdbm_setopt" // end of [gdbm_setopt] fun gdbm_getopt {a:t@ype} {lf:agz} ( dbf: !GDBM_FILE lf , option: gdbmgetopt(a), value: &a? >> a, size: sizeof_t(a) ) : int(*err*) = "mac#atslib_gdbm_getopt" // end of [gdbm_setopt] fun gdbm_getdbname {lf:agz} (dbf: !GDBM_FILE (lf)): strptr0 = "atslib_gdbm_getdbname" // end of [gdbm_getdbname] (* ****** ****** *) (* int gdbm_fdesc(dbf); *) fun gdbm_fdesc {lf:agz} (dbf: !GDBM_FILE lf): int(*fd*) = "mac#atslib_gdbm_fdesc" // end of [gdbm_fdesc] (* ****** ****** *) (* end of [gdbm.sats] *) ats-lang-anairiats-0.2.11/libc/gdbm/DATS/0000700000175000017500000000000012223166162016336 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/HATS/0000700000175000017500000000000012223166162015431 5ustar hwxihwxiats-lang-anairiats-0.2.11/libc/HATS/math.hats0000664000175000017500000001423412223166162017263 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/math.sats" (* ****** ****** *) // // HX: fpclassify, isfinite and isnormal are macros // implement fpclassify (x) = fpclassify_float (x) implement fpclassify (x) = fpclassify_double (x) implement fpclassify (x) = fpclassify_ldouble (x) implement isfinite (x) = isfinite_float (x) implement isfinite (x) = isfinite_double (x) implement isfinite (x) = isfinite_ldouble (x) implement isnormal (x) = isnormal_float (x) implement isnormal (x) = isnormal_double (x) implement isnormal (x) = isnormal_ldouble (x) // HX: BSD function implement isinftmp (x) = isinff (x) implement isinftmp (x) = isinf (x) implement isinftmp (x) = isinfl (x) // HX: BSD function implement isnantmp (x) = isnanf (x) implement isnantmp (x) = isnan (x) implement isnantmp (x) = isnanl (x) (* ****** ****** *) implement ceiltmp (x) = ceil (x) implement ceiltmp (x) = ceilf (x) implement ceiltmp (x) = ceill (x) implement floortmp (x) = floor (x) implement floortmp (x) = floorf (x) implement floortmp (x) = floorl (x) (* ****** ****** *) implement roundtmp (x) = round (x) implement roundtmp (x) = roundf (x) implement roundtmp (x) = roundl (x) implement trunctmp (x) = trunc (x) implement trunctmp (x) = truncf (x) implement trunctmp (x) = truncl (x) (* ****** ****** *) implement fmodtmp (x1, x2) = fmod (x1, x2) implement fmodtmp (x1, x2) = fmodf (x1, x2) implement fmodtmp (x1, x2) = fmodl (x1, x2) (* ****** ****** *) implement fmaxtmp (x1, x2) = fmax (x1, x2) implement fmaxtmp (x1, x2) = fmaxf (x1, x2) implement fmaxtmp (x1, x2) = fmaxl (x1, x2) implement fmintmp (x1, x2) = fmin (x1, x2) implement fmintmp (x1, x2) = fminf (x1, x2) implement fmintmp (x1, x2) = fminl (x1, x2) implement fdimtmp (x1, x2) = fdim (x1, x2) implement fdimtmp (x1, x2) = fdimf (x1, x2) implement fdimtmp (x1, x2) = fdiml (x1, x2) implement fmatmp (x1, x2, x3) = fma (x1, x2, x3) implement fmatmp (x1, x2, x3) = fmaf (x1, x2, x3) implement fmatmp (x1, x2, x3) = fmal (x1, x2, x3) (* ****** ****** *) implement sqrttmp (x) = sqrt (x) implement sqrttmp (x) = sqrtf (x) implement sqrttmp (x) = sqrtl (x) implement cbrttmp (x) = cbrt (x) implement cbrttmp (x) = cbrtf (x) implement cbrttmp (x) = cbrtl (x) implement powtmp (x1, x2) = pow (x1, x2) implement powtmp (x1, x2) = powf (x1, x2) implement powtmp (x1, x2) = powl (x1, x2) (* ****** ****** *) implement exptmp (x) = exp (x) implement exptmp (x) = expf (x) implement exptmp (x) = expl (x) (* ****** ****** *) implement logtmp (x) = log (x) implement logtmp (x) = logf (x) implement logtmp (x) = logl (x) implement log10tmp (x) = log10 (x) implement log10tmp (x) = log10f (x) implement log10tmp (x) = log10l (x) (* ****** ****** *) implement asintmp (x) = asin (x) implement asintmp (x) = asinf (x) implement asintmp (x) = asinl (x) implement acostmp (x) = acos (x) implement acostmp (x) = acosf (x) implement acostmp (x) = acosl (x) implement atantmp (x) = atan (x) implement atantmp (x) = atanf (x) implement atantmp (x) = atanl (x) implement atan2tmp (x1, x2) = atan2f (x1, x2) implement atan2tmp (x1, x2) = atan2 (x1, x2) implement atan2tmp (x1, x2) = atan2l (x1, x2) (* ****** ****** *) implement asinhtmp (x) = asinh (x) implement asinhtmp (x) = asinhf (x) implement asinhtmp (x) = asinhl (x) implement acoshtmp (x) = acosh (x) implement acoshtmp (x) = acoshf (x) implement acoshtmp (x) = acoshl (x) (* ****** ****** *) implement sintmp (x) = sin (x) implement sintmp (x) = sinf (x) implement sintmp (x) = sinl (x) implement costmp (x) = cos (x) implement costmp (x) = cosf (x) implement costmp (x) = cosl (x) implement tantmp (x) = tan (x) implement tantmp (x) = tanf (x) implement tantmp (x) = tanl (x) (* ****** ****** *) implement sinhtmp (x) = sinh (x) implement sinhtmp (x) = sinhf (x) implement sinhtmp (x) = sinhl (x) implement coshtmp (x) = cosh (x) implement coshtmp (x) = coshf (x) implement coshtmp (x) = coshl (x) implement tanhtmp (x) = tanh (x) implement tanhtmp (x) = tanhf (x) implement tanhtmp (x) = tanhl (x) (* ****** ****** *) (* end of [math.hats] *) ats-lang-anairiats-0.2.11/libc/HATS/float.hats0000664000175000017500000000600312223166162017432 0ustar hwxihwxi(***********************************************************************) (* *) (* Applied Type System *) (* *) (* Hongwei Xi *) (* *) (***********************************************************************) (* ** ATS - Unleashing the Potential of Types! ** ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU General Public License as published by the Free ** Software Foundation; either version 2.1, or (at your option) any later ** version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. *) (* ****** ****** *) (* author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) *) (* ****** ****** *) staload "libc/SATS/float.sats" (* ****** ****** *) implement DIG_tmp () = DBL_DIG implement DIG_tmp () = FLT_DIG implement DIG_tmp () = LDBL_DIG implement MANT_DIG_tmp () = DBL_MANT_DIG implement MANT_DIG_tmp () = FLT_MANT_DIG implement MANT_DIG_tmp () = LDBL_MANT_DIG (* ****** ****** *) implement RADIX_tmp () = DBL_RADIX implement RADIX_tmp () = FLT_RADIX implement RADIX_tmp () = LDBL_RADIX (* ****** ****** *) implement MAX_EXP_tmp () = DBL_MAX_EXP implement MAX_EXP_tmp () = FLT_MAX_EXP implement MAX_EXP_tmp () = LDBL_MAX_EXP implement MIN_EXP_tmp () = DBL_MIN_EXP implement MIN_EXP_tmp () = FLT_MIN_EXP implement MIN_EXP_tmp () = LDBL_MIN_EXP (* ****** ****** *) implement MAX_10_EXP_tmp () = DBL_MAX_10_EXP implement MAX_10_EXP_tmp () = FLT_MAX_10_EXP implement MAX_10_EXP_tmp () = LDBL_MAX_10_EXP implement MIN_10_EXP_tmp () = DBL_MIN_10_EXP implement MIN_10_EXP_tmp () = FLT_MIN_10_EXP implement MIN_10_EXP_tmp () = LDBL_MIN_10_EXP (* ****** ****** *) implement MAX_tmp () = DBL_MAX implement MAX_tmp () = FLT_MAX implement MAX_tmp () = LDBL_MAX implement MIN_tmp () = DBL_MIN implement MIN_tmp () = FLT_MIN implement MIN_tmp () = LDBL_MIN (* ****** ****** *) implement EPSILON_tmp () = DBL_EPSILON implement EPSILON_tmp () = FLT_EPSILON implement EPSILON_tmp () = LDBL_EPSILON (* ****** ****** *) (* end of [float.hats] *) ats-lang-anairiats-0.2.11/test.sh.in0000664000175000017500000000066112223166157015724 0ustar hwxihwxi#!/bin/sh # # For running some tests with the newly built compiler # Author: Matthew Danish (md AT cs DOT bu DOT edu) # Time: 2010 # ###### PACKAGE_TARNAME=@PACKAGE_TARNAME@ PACKAGE_VERSION=@PACKAGE_VERSION@ ###### CURDIR="`pwd`" ATSHOME="$CURDIR" ATSHOMERELOC="ATS-$PACKAGE_VERSION" TESTDIR=doc/EXAMPLE/TEST make -C ${TESTDIR} cleanall make -C ${TESTDIR} checkall EXITCODE=$? exit $EXITCODE ###### end of [test.sh.in] ###### ats-lang-anairiats-0.2.11/configure0000700000175000017500000052042012223166157015677 0ustar hwxihwxi#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.68 for ATS/Anairiats 0.2.11. # # Report bugs to . # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software # Foundation, Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test \$(( 1 + 1 )) = 2 || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV export CONFIG_SHELL case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org and hwxi@cs.bu.edu $0: about your system, including any error possibly output $0: before this message. Then install a modern shell, or $0: manually run the script under such a shell if you do $0: have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME='ATS/Anairiats' PACKAGE_TARNAME='ats-anairiats' PACKAGE_VERSION='0.2.11' PACKAGE_STRING='ATS/Anairiats 0.2.11' PACKAGE_BUGREPORT='hwxi@cs.bu.edu' PACKAGE_URL='' ac_unique_file="config.h.in" # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS HAVE_LIBPCRE HAVE_LIBGMP EGREP GREP CPP PKG_CONFIG_LIBDIR PKG_CONFIG_PATH PKG_CONFIG LN_S am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__quote am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p MKDIR_P INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W am__isrc INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking enable_dependency_tracking ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS PKG_CONFIG PKG_CONFIG_PATH PKG_CONFIG_LIBDIR CPP' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used" >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures ATS/Anairiats 0.2.11 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/ats-anairiats] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of ATS/Anairiats 0.2.11:";; esac cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory PKG_CONFIG path to pkg-config utility PKG_CONFIG_PATH directories to add to pkg-config's search path PKG_CONFIG_LIBDIR path overriding pkg-config's built-in search path CPP C preprocessor Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF ATS/Anairiats configure 0.2.11 generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ( $as_echo "## ----------------------------- ## ## Report this to hwxi@cs.bu.edu ## ## ----------------------------- ##" ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel # ac_fn_c_try_run LINENO # ---------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes # that executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES # -------------------------------------------- # Tries to find the compile-time value of EXPR in a program that includes # INCLUDES, setting VAR accordingly. Returns whether the value could be # computed ac_fn_c_compute_int () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if test "$cross_compiling" = yes; then # Depending upon the size, compute the lo and hi bounds. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) >= 0)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_lo=0 ac_mid=0 while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_hi=$ac_mid; break else as_fn_arith $ac_mid + 1 && ac_lo=$as_val if test $ac_lo -le $ac_mid; then ac_lo= ac_hi= break fi as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) < 0)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_hi=-1 ac_mid=-1 while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_lo=$ac_mid; break else as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val if test $ac_mid -le $ac_hi; then ac_lo= ac_hi= break fi as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done else ac_lo= ac_hi= fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext # Binary search between lo and hi bounds. while test "x$ac_lo" != "x$ac_hi"; do as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_hi=$ac_mid else as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done case $ac_lo in #(( ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; '') ac_retval=1 ;; esac else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 static long int longval () { return $2; } static unsigned long int ulongval () { return $2; } #include #include int main () { FILE *f = fopen ("conftest.val", "w"); if (! f) return 1; if (($2) < 0) { long int i = longval (); if (i != ($2)) return 1; fprintf (f, "%ld", i); } else { unsigned long int i = ulongval (); if (i != ($2)) return 1; fprintf (f, "%lu", i); } /* Do not output a trailing newline, as this causes \r\n confusion on some platforms. */ return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : echo >>conftest.val; read $3 &5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case declares $2. For example, HP-UX 11i declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by ATS/Anairiats $as_me 0.2.11, which was generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo $as_echo "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo $as_echo "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then $as_echo "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then $as_echo "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then # We do not want a PATH search for config.site. case $CONFIG_SITE in #(( -*) ac_site_file1=./$CONFIG_SITE;; */*) ac_site_file1=$CONFIG_SITE;; *) ac_site_file1=./$CONFIG_SITE;; esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file See \`config.log' for more details" "$LINENO" 5; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_headers="$ac_config_headers config.h" ac_config_files="$ac_config_files config.mk" ac_config_files="$ac_config_files ats_env.sh" ac_config_files="$ac_config_files test.sh" am__api_version='1.11' ac_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; esac # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error $? "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi test "$2" = conftest.file ) then # Ok. : else as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` if test x"${MISSING+set}" != xset; then case $am_aux_dir in *\ * | *\ *) MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; *) MISSING="\${SHELL} $am_aux_dir/missing" ;; esac fi # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if test x"${install_sh}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi test -d ./--version && rmdir ./--version if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. MKDIR_P="$ac_install_sh -d" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } mkdir_p="$MKDIR_P" case $mkdir_p in [\\/$]* | ?:[\\/]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='ats-anairiats' VERSION='0.2.11' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AMTAR='$${TAR-tar}' am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo this is the am__doit target .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 $as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # Ignore all kinds of additional output from `make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include am__quote= _am_result=GNU ;; esac # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=.include am__quote="\"" _am_result=BSD ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 $as_echo "$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok `-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 $as_echo_n "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 $as_echo "no, using $LN_S" >&6; } fi if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_pt_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_pt_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_path_PKG_CONFIG" fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in complex.h do : ac_fn_c_check_header_mongrel "$LINENO" "complex.h" "ac_cv_header_complex_h" "$ac_includes_default" if test "x$ac_cv_header_complex_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_COMPLEX_H 1 _ACEOF fi done for ac_header in curses.h do : ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default" if test "x$ac_cv_header_curses_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_CURSES_H 1 _ACEOF fi done for ac_header in gmp.h do : ac_fn_c_check_header_mongrel "$LINENO" "gmp.h" "ac_cv_header_gmp_h" "$ac_includes_default" if test "x$ac_cv_header_gmp_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_GMP_H 1 _ACEOF fi done HAVE_LIBGMP=${ac_cv_header_gmp_h%no} for ac_header in pcre.h do : ac_fn_c_check_header_mongrel "$LINENO" "pcre.h" "ac_cv_header_pcre_h" "$ac_includes_default" if test "x$ac_cv_header_pcre_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_PCRE_H 1 _ACEOF fi done HAVE_LIBPCRE=${ac_cv_header_pcre_h%no} # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void*" >&5 $as_echo_n "checking size of void*... " >&6; } if ${ac_cv_sizeof_voidp+:} false; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void*))" "ac_cv_sizeof_voidp" "$ac_includes_default"; then : else if test "$ac_cv_type_voidp" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "cannot compute sizeof (void*) See \`config.log' for more details" "$LINENO" 5; } else ac_cv_sizeof_voidp=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_voidp" >&5 $as_echo "$ac_cv_sizeof_voidp" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_VOIDP $ac_cv_sizeof_voidp _ACEOF for ac_func in drand48_r erand48_r do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done for ac_func in posix_memalign memalign do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else case $cache_file in #( */* | ?:*) mv -f confcache "$cache_file"$$ && mv -f "$cache_file"$$ "$cache_file" ;; #( *) mv -f confcache "$cache_file" ;; esac fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' else am__EXEEXT_TRUE='#' am__EXEEXT_FALSE= fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error $? "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by ATS/Anairiats $as_me 0.2.11, which was generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ ATS/Anairiats config.status 0.2.11 configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" Copyright (C) 2010 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' MKDIR_P='$MKDIR_P' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error $? "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "config.mk") CONFIG_FILES="$CONFIG_FILES config.mk" ;; "ats_env.sh") CONFIG_FILES="$CONFIG_FILES ats_env.sh" ;; "test.sh") CONFIG_FILES="$CONFIG_FILES test.sh" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap 'exit_status=$? : "${ac_tmp:=$tmp}" { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do ac_tt=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_tt"; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" case $ac_file in -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" } >"$ac_tmp/config.h" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_arg="$ac_file" _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$_am_arg" : 'X\(//\)[^/]' \| \ X"$_am_arg" : 'X\(//\)$' \| \ X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$_am_arg" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || { # Autoconf 2.62 quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. case $CONFIG_FILES in *\'*) eval set x "$CONFIG_FILES" ;; *) set x $CONFIG_FILES ;; esac shift for mf do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir=$dirpart/$fdir; as_fn_mkdir_p # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done } ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi ats-lang-anairiats-0.2.11/configure.ac0000664000175000017500000001101412223166157016264 0ustar hwxihwxidnl ========================================================================= dnl = = dnl = Applied Type System = dnl = = dnl = Hongwei Xi = dnl = = dnl ========================================================================= dnl = dnl = ATS - Unleashing the Power of Types! dnl = dnl = Copyright (C) 2002-2010 Hongwei Xi. dnl = dnl = ATS is free software; you can redistribute it and/or modify it under dnl = the terms of the GNU General Public License as published by the Free dnl = Software Foundation; either version 2.1, or (at your option) any later dnl = version. dnl = dnl = ATS is distributed in the hope that it will be useful, but WITHOUT ANY dnl = WARRANTY; without even the implied warranty of MERCHANTABILITY or dnl = FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License dnl = for more details. dnl = dnl = You should have received a copy of the GNU General Public License dnl = along with ATS; see the file COPYING. If not, write to the Free dnl = Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA dnl = 02110-1301, USA. dnl = dnl = dnl = Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) dnl = Author: Likai Liu (liulk AT cs DOT bu DOT edu) dnl = dnl = beg of [configure.ac] dnl = Autoconf requirements dnl = AC_INIT(package, version, bug-report-address) dnl = information on the package dnl = checks for programs dnl = checks for libraries dnl = checks for header files dnl = checks for types dnl = checks for structures dnl = checks for compiler characteristics dnl = checks for library functions dnl = checks for system services dnl = AC_CONFIG_FILES([file...]) dnl = AC_INIT([ATS/Anairiats], [0.1.8], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.1.9], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.0], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.1], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.2], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.3], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.4], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.5], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.6], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.7], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.8], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.9], [hwxi@cs.bu.edu]) dnl = AC_INIT([ATS/Anairiats], [0.2.10], [hwxi@cs.bu.edu]) AC_INIT([ATS/Anairiats], [0.2.11], [hwxi@cs.bu.edu]) AC_CONFIG_SRCDIR([config.h.in]) AC_CONFIG_HEADER([config.h]) AC_CONFIG_FILES([config.mk]) AC_CONFIG_FILES([ats_env.sh]) AC_CONFIG_FILES([test.sh]) AM_INIT_AUTOMAKE AC_PROG_CC AC_PROG_INSTALL AC_PROG_MKDIR_P AC_PROG_LN_S PKG_PROG_PKG_CONFIG dnl = check for complex.h AC_CHECK_HEADERS(complex.h) dnl = check for curses.h AC_CHECK_HEADERS(curses.h) dnl = check for gmp.h AC_CHECK_HEADERS(gmp.h) AC_SUBST(HAVE_LIBGMP, ${ac_cv_header_gmp_h%no}) dnl = check for pcre.h AC_CHECK_HEADERS(pcre.h) AC_SUBST(HAVE_LIBPCRE, ${ac_cv_header_pcre_h%no}) dnl = check for [cairo/cairo] dnl = AC_CHECK_HEADERS(cairo/cairo.h) dnl = check for [glib-2.0.0] dnl = AM_PATH_GLIB_2_0(2.10.0, [ dnl = AC_DEFINE([HAVE_LIBGLIB20], [1], [Define to 1 if you have glib-2.0]) dnl = have_glib=1 dnl = ]) dnl = AC_SUBST(HAVE_LIBGLIB20, $have_glib) dnl = check for [gtk+-2.0.0] dnl = AM_PATH_GTK_2_0(2.10.0, [ dnl = AC_DEFINE([HAVE_LIBGTK20], [1], [Define to 1 if you have gtk+2.0]) dnl = have_gtk=1 dnl = ]) dnl = AC_SUBST(HAVE_LIBGTK20, $have_gtk) dnl = check for [GL/gl.h GL/glut.h] dnl = AC_CHECK_HEADERS(GL/gl.h GL/glut.h) dnl = check for [SDL] dnl = AM_PATH_SDL(1.0.0, [ dnl = AC_DEFINE([HAVE_LIBSDL10], [1], [Define to 1 if you have SDL-1.0]) dnl = have_sdl=1 dnl = ]) dnl = AC_SUBST(HAVE_LIBSDL10, $have_sdl) dnl = check for SIZEOF_VOIDP AC_CHECK_SIZEOF(void*) dnl = check for some functions AC_CHECK_FUNCS(drand48_r erand48_r) AC_CHECK_FUNCS(posix_memalign memalign) dnl = AH_TEMPLATE([HAVE_GCBDW], dnl = [Informs us the availability of Boehm-Demers-Weiser dnl = garbage collection installed on the system.]) dnl = PKG_CHECK_MODULES([GCBDW], [Boehm-Demers-Weiser GC >= 7.1], [AC_DEFINE(HAVE_GCBDW)], [true]) dnl = CFLAGS="$CFLAGS $GCBDW_CFLAGS" dnl = LDFLAGS="$LDFLAGS $GCBDW_LDFLAGS" AC_OUTPUT dnl = end of [configure.ac] ats-lang-anairiats-0.2.11/bootstrap1/0000700000175000017500000000000012223166160016055 5ustar hwxihwxiats-lang-anairiats-0.2.11/bootstrap1/ats_trans1_sats.c0000664000175000017500000000324612223166157021361 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans1_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hashtbl_sats.c0000664000175000017500000000253212223166157021573 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__HashTableIsNullException) ; /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__HashTableIsNullException.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__HashTableIsNullException.name = "ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__HashTableIsNullException" ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hashtbl_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_gmp.cats0000664000175000017500000000737012223166157020414 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // August 2008 /* ****** ****** */ /* ats_gmp.cats: in case [GMP] is unavailable */ /* ****** ****** */ #ifndef ATS_SRC_GMP_CATS #define ATS_SRC_GMP_CATS /* ****** ****** */ #include #include /* ****** ****** */ #include "ats_types.h" /* ****** ****** */ #include "prelude/CATS/basics.cats" /* ****** ****** */ typedef ats_lint_type lint ; typedef ats_llint_type mpz ; typedef mpz *mpz_ptr ; typedef mpz ats_mpz_viewt0ype ; typedef ats_ref_type ats_mpz_ptr_type ; typedef ats_ref_type ats_mpq_ptr_type ; typedef ats_ref_type ats_mpf_ptr_type ; /* ****** ****** */ static inline lint mpz_get_si (mpz_ptr x) { return *x ; } /* ****** ****** */ static inline void mpz_init (mpz_ptr x) { return ; } static inline void mpz_init_set_si (mpz_ptr x, lint y) { *x = y ; return ; } static inline int mpz_init_set_str ( mpz_ptr x, char *nptr, int base ) { char *endptr ; *x = strtoll (nptr, &endptr, base) ; if (!endptr) return (-1) ; return 0 ; } // end of [mpz_init_set_str] /* ****** ****** */ static inline int mpz_cmp (mpz_ptr x, mpz_ptr y) { return (*x - *y) ; } static inline int mpz_cmp_si (mpz_ptr x, lint y) { return (*x - y) ; } static inline void mpz_neg (mpz_ptr x, mpz_ptr y) { *x = -(*y) ; return ; } static inline void mpz_add (mpz_ptr x, mpz_ptr y, mpz_ptr z) { *x = *y + *z ; return ; } static inline void mpz_add_si (mpz_ptr x, mpz_ptr y, lint z) { *x = *y + z ; return ; } static inline void mpz_sub (mpz_ptr x, mpz_ptr y, mpz_ptr z) { *x = *y - *z ; return ; } static inline void mpz_sub_si (mpz_ptr x, mpz_ptr y, lint z) { *x = *y - z ; return ; } static inline void mpz_mul (mpz_ptr x, mpz_ptr y, mpz_ptr z) { *x = *y * *z ; return ; } static inline void mpz_mul_si (mpz_ptr x, mpz_ptr y, lint z) { *x = *y * z ; return ; } /* ****** ****** */ static inline void mp_set_memory_functions () { return ; } /* ****** ****** */ static inline ats_void_type atslib_mpz_init_set_int ( ats_mpz_ptr_type x, ats_int_type y ) { mpz_init_set_si((mpz_ptr)x, y) ; return ; } // end of [atslib_mpz_init_set_int] static inline ats_void_type atslib_fprint_mpz ( ats_ptr_type file, const ats_mpz_ptr_type x ) { fprintf ((FILE*)file, "%lld", *(mpz_ptr)x) ; return ; } // end of [atslib_fprint_mpz] /* ****** ****** */ #endif /* ATS_SRC_GMP_CATS */ /* end of [ats_gmp.cats] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_main.cats0000664000175000017500000001252212223166157020550 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // September 2008 /* ****** ****** */ #ifndef ATS_SRC_MAIN_CATS #define ATS_SRC_MAIN_CATS /* ****** ****** */ // // HX-2010-10-21: this one seems to be a macro // #ifndef strncmp extern int strncmp (const char *s1, const char *s2, size_t n) ; #endif // end of ... /* ****** ****** */ extern ats_void_type ats_posmark_xref_flag_set (ats_ptr_type flag) ; ATSinline() ats_bool_type atsopt_is_posmark_xref_prefix (ats_ptr_type s0) { int cmp, n1, n2, ln ; char *s, *flag ; static char* POSMARK_XREF = "--posmark_xref" ; s = (char*)s0 ; n1 = strlen (POSMARK_XREF) ; cmp = strncmp (POSMARK_XREF, s, n1) ; if (cmp == 0) { n2 = strlen (s) ; if (s[n1] == '=') n1 += 1 ; ln = n2 - n1 ; if (ln > 0) { if (s[n2-1] == '/') { ln -= 1 ; } flag = (char*)ATS_MALLOC(ln + 2) ; strncpy (flag, &s[n1], ln) ; flag[ln] = '/' ; flag[ln+1] = '\000' ; } else { flag = "" ; } // end of [if] /* fprintf (stderr, "atsopt_is_posmark_xref_prefix: flag = %s\n", flag) ; */ ats_posmark_xref_flag_set ((ats_ptr_type)flag) ; } // end of [if] return (cmp == 0 ? ats_true_bool : ats_false_bool) ; } /* end of [atsopt_is_posmark_xref_prefix] */ /* ****** ****** */ static int the_DATS_wait = 0 ; ATSinline() ats_void_type atsopt_DATS_wait_set () { the_DATS_wait = 1 ; return ; } // end of [atsopt_DATS_wait_set] ATSinline() ats_bool_type atsopt_DATS_wait_is_set () { return (the_DATS_wait ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_DATS_wait_is_set] ATSinline() ats_void_type atsopt_DATS_wait_clear () { the_DATS_wait = 0 ; return ; } // end of [atsopt_DATS_wait_clear] ats_bool_type atsopt_is_DATS_flag (ats_ptr_type s0) { return ( strncmp((char*)s0, "-DATS", 5)==0 ? ats_true_bool : ats_false_bool ) ; } // end of [atsopt_is_DATS_flag] ats_ptr_type atsopt_DATS_extract (ats_ptr_type s0) { int n ; char* s ; n = strlen ((char*)s0) - 5 ; if (n <= 0) return (ats_ptr_type)0 ; s = (char*)ATS_MALLOC(n + 1) ; memcpy (s, (char*)s0 + 5, n) ; s[n] = '\0' ; return (ats_ptr_type)s ; } // end of [atsopt_DATS_extract] /* ****** ****** */ static int the_IATS_wait = 0 ; ATSinline() ats_void_type atsopt_IATS_wait_set () { the_IATS_wait = 1 ; return ; } // end of [atsopt_IATS_wait_set] ATSinline() ats_bool_type atsopt_IATS_wait_is_set () { return (the_IATS_wait ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_IATS_wait_is_set] ATSinline() ats_void_type atsopt_IATS_wait_clear () { the_IATS_wait = 0 ; return ; } // end of [atsopt_IATS_wait_clear] ats_bool_type atsopt_is_IATS_flag (ats_ptr_type s0) { return ( strncmp((char*)s0, "-IATS", 5)==0 ? ats_true_bool : ats_false_bool ) ; // end of [return] } // end of [atsopt_is_IATS_flag] ats_ptr_type atsopt_IATS_extract (ats_ptr_type s0) { int n ; char* s ; n = strlen ((char*)s0) - 5 ; if (n <= 0) return (ats_ptr_type)0 ; s = (char*)ATS_MALLOC(n + 1) ; memcpy (s, (char*)s0 + 5, n) ; s[n] = '\0' ; return (ats_ptr_type)s ; } // end of [atsopt_IATS_extract] /* ****** ****** */ // // HX: global // char *atsopt_ATSHOME = NULL ; // no need for marking as a root int atsopt_ATSHOME_length = 0; ats_ptr_type atsopt_ATSHOME_getenv_exn () { char *value0 ; value0 = getenv ("ATSHOME") ; // this value cannot be GCed if (!value0) { fprintf (stderr, "The environment variable ATSHOME is undefined.\n") ; exit (1) ; } atsopt_ATSHOME = value0 ; atsopt_ATSHOME_length = strlen (value0) ; return (ats_ptr_type)value0 ; } /* end of [atsopt_ATSHOME_getenv_exn] */ /* ****** ****** */ // // HX: global // char *atsopt_ATSHOMERELOC = NULL ; // no need for marking as a root ats_void_type atsopt_ATSHOMERELOC_set () { atsopt_ATSHOMERELOC = getenv ("ATSHOMERELOC") ; // this value cannot be GCed /* fprintf (stderr, "atsopt_ATSHOMERELOC_set: ATSHOMERELOC = %s\n", atsopt_ATSHOMERELOC) ; */ return ; } // end of [atsopt_ATSHOMERELOC_set] /* ****** ****** */ #endif // [ATS_SRC_MAIN_CATS] /* end of [ats_main.cats] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symtbl_sats.c0000664000175000017500000000220212223166157021452 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symtbl_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_trans_temp_dats.c0000664000175000017500000030104712223166157023467 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_hash ; ats_ptr_type atslab_eq ; ats_int_type atslab_size ; ats_int_type atslab_nitm ; ats_ptr_type atslab_table[] ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_12 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPvar_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imul) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_uimod) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_ulint) (ats_ulint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_ulint_type, atspre_string_hash_33) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_tostringf) (ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_takeout_tsz) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp) (atsopt_count_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp_t) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_var_name_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_htp_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, __ats_htp_free) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__print_the_stactx) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_free) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_pop) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef) (ats_ptr_type, ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__sasp__stactx_token_v = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__sasp__stactx_vt = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPvar_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_ptr_type stactx_nil_2 () ; static ats_ptr_type ref_make_elt_01686_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type aux_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_list_inf_0287_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type map_list_inf_01936_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type loop_8 (ats_ptr_type arg0) ; static ats_int_type bst_size_0195_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01932_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_0223_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01934_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type bst_free_0191_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type map_free_01930_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type aux_char_23 (ats_ref_type arg0, ats_char_type arg1) ; static ats_void_type aux_string_24 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) ; static ats_void_type aux_hityp_25 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_hityplst_26 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_hityplstlst_27 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux1_hityplstlst_28 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type fprint_tmpcstvar_29 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type print_tmpcstvar_30 (ats_ptr_type arg0) ; static ats_void_type prerr_tmpcstvar_31 (ats_ptr_type arg0) ; static ats_void_type aux_33 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_33_closure_make () ; static ats_void_type aux_33_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type auxlst_34 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type auxlst_34_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type auxlst_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type auxlstlst_35 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type auxlstlst_35_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type auxlstlst_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type template_arg_match_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type chain_insert_048_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type table_insert_074_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ht_insert_0105_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_42 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_ptr_type htp_resize_0134_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type hashtbl_insert_01711_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type chain_search_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type table_search_064_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type ht_search_0100_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type hashtbl_search_01710_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp7) ; ATSstatic (ats_ptr_type, statmp8) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp232) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 2828(line=94, offs=4) -- 2895(line=95, offs=48) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_trans_temp)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 2899(line=96, offs=4) -- 3017(line=98, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; __ats_lab_prerr_loc_interror_1: /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_ccomp_trans_temp)")) ; return /* (tmp1) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 3233(line=110, offs=4) -- 3294(line=110, offs=65) */ ATSstaticdec() ats_ptr_type stactx_nil_2 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_stactx_nil_2: tmp3 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var) ; return (tmp3) ; } /* end of [stactx_nil_2] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01686_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_ref_make_elt_01686_ats_ptr_type: /* ats_ptr_type tmp6 ; */ tmp6 = arg0 ; tmp5 = atspre_ref_make_elt_tsz ((&tmp6), sizeof(ats_ptr_type)) ; return (tmp5) ; } /* end of [ref_make_elt_01686_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8374(line=278, offs=7) -- 8728(line=288, offs=6) */ ATSstaticdec() ats_ptr_type aux_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (anairiats_rec_2, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_aux_7: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp19 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_2) ; tmp20 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp21 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp22.atslab_0 = tmp18 ; tmp22.atslab_1 = tmp19 ; tmp23 = ats_ptrget_mac(ats_ptr_type, tmp20) ; tmp26 = ats_ptrget_mac(ats_ptr_type, tmp21) ; tmp25 = aux_7 (tmp26, arg1) ; tmp24 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp24, atslab_0, tmp22) ; ats_selptrset_mac(anairiats_sum_3, tmp24, atslab_1, tmp25) ; arg0 = tmp23 ; arg1 = tmp24 ; goto __ats_lab_aux_7 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp17 = arg1 ; break ; } while (0) ; return (tmp17) ; } /* end of [aux_7] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8278(line=274, offs=22) -- 8777(line=291, offs=4) */ ATSstaticdec() ats_ptr_type bst_list_inf_0287_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_bst_list_inf_0287_ats_ptr_type_2cats_ptr_type: tmp27 = (ats_sum_ptr_type)0 ; tmp16 = aux_7 (arg0, tmp27) ; return (tmp16) ; } /* end of [bst_list_inf_0287_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 11607(line=396, offs=14) -- 11717(line=401, offs=4) */ ATSstaticdec() ats_ptr_type map_list_inf_01936_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_map_list_inf_01936_ats_ptr_type_2cats_ptr_type: // tmp15 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp28 = ats_ptrget_mac(ats_ptr_type, tmp15) ; tmp14 = bst_list_inf_0287_ats_ptr_type_2cats_ptr_type (tmp28) ; return (tmp14) ; } /* end of [map_list_inf_01936_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 3592(line=122, offs=7) -- 3934(line=133, offs=28) */ ATSstaticdec() ats_void_type loop_8 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp30) ; ATSlocal (anairiats_rec_2, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_loop_8: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp34 = ats_select_mac(tmp31, atslab_0) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2var (tmp34) ; /* tmp35 = */ atspre_print_string (ATSstrcst(" -> ")) ; tmp37 = ats_select_mac(tmp31, atslab_1) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp_t (tmp37) ; /* tmp38 = */ atspre_print_newline () ; arg0 = tmp32 ; goto __ats_lab_loop_8 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp30) */ ; } /* end of [loop_8] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 3460(line=118, offs=18) -- 3997(line=137, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__print_the_stactx () { /* local vardec */ // ATSlocal_void (tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__print_the_stactx: tmp11 = atspre_ref_get_view_ptr (statmp4) ; tmp12 = ats_selsin_mac(tmp11, atslab_1) ; tmp29 = ats_ptrget_mac(ats_ptr_type, tmp12) ; tmp13 = map_list_inf_01936_ats_ptr_type_2cats_ptr_type (tmp29) ; /* tmp10 = */ loop_8 (tmp13) ; return /* (tmp10) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__print_the_stactx] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_0195_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp67) ; ATSlocal (ats_int_type, tmp68) ; __ats_lab_bst_size_0195_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp67 = tmp68 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp67 = 0 ; break ; } while (0) ; return (tmp67) ; } /* end of [bst_size_0195_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_int_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_int_type, tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_int_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; __ats_lab_bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_5_1: tmp54 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp55 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp56 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp57 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp59 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp55) ; tmp58 = atspre_ilte (tmp59, 0) ; if (tmp58) { tmp61 = ats_ptrget_mac(ats_ptr_type, tmp56) ; tmp60 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (tmp61, arg1, arg2, arg3) ; // if (tmp60 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp62 = &ats_caselptrlab_mac(anairiats_sum_1, tmp60, atslab_0) ; tmp63 = &ats_caselptrlab_mac(anairiats_sum_1, tmp60, atslab_3) ; tmp64 = &ats_caselptrlab_mac(anairiats_sum_1, tmp60, atslab_4) ; tmp65 = ats_ptrget_mac(ats_int_type, tmp54) ; tmp69 = ats_ptrget_mac(ats_ptr_type, tmp63) ; tmp66 = bst_size_0195_ats_ptr_type_2cats_ptr_type (tmp69) ; tmp70 = ats_ptrget_mac(ats_ptr_type, tmp64) ; ats_ptrget_mac(ats_ptr_type, tmp56) = tmp70 ; tmp71 = atspre_isub (tmp65, tmp66) ; ats_ptrget_mac(ats_int_type, tmp54) = tmp71 ; ats_ptrget_mac(ats_ptr_type, tmp64) = arg0 ; tmp72 = atspre_iadd (tmp65, 1) ; ats_ptrget_mac(ats_int_type, tmp62) = tmp72 ; tmp53 = tmp60 ; } else { tmp74 = ats_ptrget_mac(ats_ptr_type, tmp57) ; tmp73 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (tmp74, arg1, arg2, arg3) ; // if (tmp73 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp75 = &ats_caselptrlab_mac(anairiats_sum_1, tmp73, atslab_0) ; tmp76 = &ats_caselptrlab_mac(anairiats_sum_1, tmp73, atslab_3) ; tmp77 = &ats_caselptrlab_mac(anairiats_sum_1, tmp73, atslab_4) ; tmp78 = ats_ptrget_mac(ats_int_type, tmp54) ; tmp80 = ats_ptrget_mac(ats_ptr_type, tmp77) ; tmp79 = bst_size_0195_ats_ptr_type_2cats_ptr_type (tmp80) ; tmp81 = ats_ptrget_mac(ats_ptr_type, tmp76) ; ats_ptrget_mac(ats_ptr_type, tmp57) = tmp81 ; tmp82 = atspre_isub (tmp78, tmp79) ; ats_ptrget_mac(ats_int_type, tmp54) = tmp82 ; ats_ptrget_mac(ats_ptr_type, tmp76) = arg0 ; tmp83 = atspre_iadd (tmp78, 1) ; ats_ptrget_mac(ats_int_type, tmp75) = tmp83 ; tmp53 = tmp73 ; } /* end of [if] */ break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp84 = (ats_sum_ptr_type)0 ; tmp85 = (ats_sum_ptr_type)0 ; tmp53 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_3, tmp84) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_4, tmp85) ; break ; } while (0) ; return (tmp53) ; } /* end of [bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_int_type, tmp52) ; ATSlocal (ats_bool_type, tmp86) ; ATSlocal (ats_int_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_int_type, tmp90) ; ATSlocal (ats_int_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_int_type, tmp94) ; ATSlocal (ats_int_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_bst_insert_random_0234_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_4_1: tmp47 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp48 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp49 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp50 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp52 = ats_ptrget_mac(ats_int_type, tmp47) ; tmp51 = atsopt_map_lin_dice (1, tmp52) ; if (tmp51) { tmp46 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp87 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp48) ; tmp86 = atspre_ilte (tmp87, 0) ; if (tmp86) { tmp89 = ats_ptrget_mac(ats_ptr_type, tmp49) ; tmp88 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp89, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp49) = tmp88 ; tmp91 = ats_ptrget_mac(ats_int_type, tmp47) ; tmp90 = atspre_iadd (tmp91, 1) ; ats_ptrget_mac(ats_int_type, tmp47) = tmp90 ; tmp46 = arg0 ; } else { tmp93 = ats_ptrget_mac(ats_ptr_type, tmp50) ; tmp92 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp93, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp50) = tmp92 ; tmp95 = ats_ptrget_mac(ats_int_type, tmp47) ; tmp94 = atspre_iadd (tmp95, 1) ; ats_ptrget_mac(ats_int_type, tmp47) = tmp94 ; tmp46 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp96 = (ats_sum_ptr_type)0 ; tmp97 = (ats_sum_ptr_type)0 ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp46, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp46, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp46, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp46, atslab_3, tmp96) ; ats_selptrset_mac(anairiats_sum_1, tmp46, atslab_4, tmp97) ; break ; } while (0) ; return (tmp46) ; } /* end of [bst_insert_random_0234_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01932_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_map_insert_01932_ats_ptr_type_2cats_ptr_type: // tmp43 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp44 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp98 = ats_ptrget_mac(ats_ptr_type, tmp44) ; tmp45 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp98, arg1, arg2, tmp43) ; ats_ptrget_mac(ats_ptr_type, tmp44) = tmp45 ; return /* (tmp42) */ ; } /* end of [map_insert_01932_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 4053(line=140, offs=16) -- 4178(line=144, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_add: tmp40 = atspre_ref_get_view_ptr (statmp4) ; tmp41 = ats_selsin_mac(tmp40, atslab_1) ; tmp99 = ats_ptrget_mac(ats_ptr_type, tmp41) ; /* tmp39 = */ map_insert_01932_ats_ptr_type_2cats_ptr_type (tmp99, arg0, arg1) ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_add] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_0223_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_int_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_10_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_2) ; tmp109 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp110 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp111 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp107) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (tmp111 != -1) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp112 = ats_ptrget_mac(ats_ptr_type, tmp109) ; arg0 = tmp112 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp111 != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp113 = ats_ptrget_mac(ats_ptr_type, tmp110) ; arg0 = tmp113 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp111 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp106 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp106, atslab_0, tmp108) ; break ; } while (0) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp106 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp106) ; } /* end of [bst_search_0223_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01934_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp114) ; __ats_lab_map_search_01934_ats_ptr_type_2cats_ptr_type: // tmp104 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp105 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp114 = ats_ptrget_mac(ats_ptr_type, tmp105) ; tmp103 = bst_search_0223_ats_ptr_type_2cats_ptr_type (tmp114, arg1, tmp104) ; return (tmp103) ; } /* end of [map_search_01934_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 4233(line=147, offs=17) -- 4348(line=151, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp115) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_find: tmp101 = atspre_ref_get_view_ptr (statmp4) ; tmp102 = ats_selsin_mac(tmp101, atslab_1) ; tmp115 = ats_ptrget_mac(ats_ptr_type, tmp102) ; tmp100 = map_search_01934_ats_ptr_type_2cats_ptr_type (tmp115, arg0) ; return (tmp100) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_find] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 4404(line=154, offs=17) -- 4734(line=171, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_push () { /* local vardec */ // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_push: tmp117 = atspre_ref_get_view_ptr (statmp4) ; tmp118 = ats_selsin_mac(tmp117, atslab_1) ; tmp119 = ats_ptrget_mac(ats_ptr_type, tmp118) ; tmp120 = stactx_nil_2 () ; ats_ptrget_mac(ats_ptr_type, tmp118) = tmp120 ; tmp121 = atspre_ref_get_view_ptr (statmp8) ; tmp122 = ats_selsin_mac(tmp121, atslab_1) ; tmp124 = ats_ptrget_mac(ats_ptr_type, tmp122) ; tmp123 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp123, atslab_0, tmp119) ; ats_selptrset_mac(anairiats_sum_0, tmp123, atslab_1, tmp124) ; ats_ptrget_mac(ats_ptr_type, tmp122) = tmp123 ; return /* (tmp116) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_push] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_0191_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; // ATSlocal_void (tmp146) ; __ats_lab_bst_free_0191_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp146 = */ bst_free_0191_ats_ptr_type_2cats_ptr_type (tmp144) ; arg0 = tmp145 ; goto __ats_lab_bst_free_0191_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; return /* (tmp143) */ ; } /* end of [bst_free_0191_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_01930_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_map_free_01930_ats_ptr_type_2cats_ptr_type: // tmp142 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp141 = */ bst_free_0191_ats_ptr_type_2cats_ptr_type (tmp142) ; return /* (tmp141) */ ; } /* end of [map_free_01930_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 4789(line=174, offs=16) -- 5511(line=204, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_pop () { /* local vardec */ // ATSlocal_void (tmp125) ; ATSlocal (ats_int_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; // ATSlocal_void (tmp133) ; ATSlocal (ats_bool_type, tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_pop: /* ats_int_type tmp126 ; */ tmp126 = 0 ; tmp127 = atspre_ref_get_view_ptr (statmp8) ; tmp128 = ats_selsin_mac(tmp127, atslab_1) ; tmp130 = ats_ptrget_mac(ats_ptr_type, tmp128) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp130 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp131 = ats_caselptrlab_mac(anairiats_sum_0, tmp130, atslab_0) ; tmp132 = ats_caselptrlab_mac(anairiats_sum_0, tmp130, atslab_1) ; ATS_FREE(tmp130) ; ats_ptrget_mac(ats_ptr_type, tmp128) = tmp132 ; tmp129 = tmp131 ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (tmp130 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp126 = 1 ; tmp129 = stactx_nil_2 () ; break ; } while (0) ; tmp134 = atspre_gt_int_int (tmp126, 0) ; if (tmp134) { /* tmp135 = */ prerr_interror_0 () ; /* tmp136 = */ atspre_prerr_string (ATSstrcst(": the_stactx_pop")) ; /* tmp137 = */ atspre_prerr_newline () ; /* tmp133 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp138 = atspre_ref_get_view_ptr (statmp4) ; tmp139 = ats_selsin_mac(tmp138, atslab_1) ; tmp147 = ats_ptrget_mac(ats_ptr_type, tmp139) ; /* tmp140 = */ map_free_01930_ats_ptr_type_2cats_ptr_type (tmp147) ; ats_ptrget_mac(ats_ptr_type, tmp139) = tmp129 ; return /* (tmp125) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 5657(line=213, offs=23) -- 5793(line=220, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var_normalize: tmp148 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_find (arg0) ; return (tmp148) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 6042(line=235, offs=7) -- 6112(line=236, offs=62) */ ATSstaticdec() ats_void_type aux_char_23 (ats_ref_type arg0, ats_char_type arg1) { /* local vardec */ // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_aux_char_23: tmp151 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp151, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp151, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp151 ; return /* (tmp150) */ ; } /* end of [aux_char_23] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 6148(line=239, offs=7) -- 6346(line=243, offs=8) */ ATSstaticdec() ats_void_type aux_string_24 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) { /* local vardec */ // ATSlocal_void (tmp152) ; ATSlocal (ats_bool_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_char_type, tmp155) ; ATSlocal (ats_size_type, tmp156) ; __ats_lab_aux_string_24: tmp153 = atspre_string_is_atend (arg1, arg2) ; if (tmp153) { /* empty */ } else { tmp155 = atspre_string_get_char_at (arg1, arg2) ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp154, atslab_0, tmp155) ; ats_selptrset_mac(anairiats_sum_5, tmp154, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp154 ; tmp156 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp156 ; goto __ats_lab_aux_string_24 ; // tail call } /* end of [if] */ return /* (tmp152) */ ; } /* end of [aux_string_24] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 6399(line=246, offs=7) -- 6898(line=261, offs=10) */ ATSstaticdec() ats_void_type aux_hityp_25 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; // ATSlocal_void (tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_bool_type, tmp166) ; __ats_lab_aux_hityp_25: tmp158 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hityp_node) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp158)->tag != 1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_7, tmp158, atslab_0) ; tmp160 = ats_caselptrlab_mac(anairiats_sum_7, tmp158, atslab_1) ; /* tmp161 = */ aux_string_24 (arg0, ats_castfn_mac(ats_ptr_type, tmp159), 0) ; /* tmp157 = */ aux_hityplstlst_27 (arg0, tmp160, 1) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hityp_name) ; tmp163 = ats_caselptrlab_mac(anairiats_sum_8, tmp162, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_8, tmp162, atslab_1) ; tmp166 = atspre_gt_int_int (tmp163, 0) ; if (tmp166) { tmp165 = ATSstrcst("ats_ptr_type") ; } else { tmp165 = tmp164 ; } /* end of [if] */ /* tmp157 = */ aux_string_24 (arg0, ats_castfn_mac(ats_ptr_type, tmp165), 0) ; break ; } while (0) ; return /* (tmp157) */ ; } /* end of [aux_hityp_25] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 6949(line=264, offs=7) -- 7249(line=273, offs=24) */ ATSstaticdec() ats_void_type aux_hityplst_26 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; // ATSlocal_void (tmp170) ; ATSlocal (ats_bool_type, tmp171) ; // ATSlocal_void (tmp172) ; ATSlocal (ats_int_type, tmp173) ; __ats_lab_aux_hityplst_26: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp171 = atspre_gt_int_int (arg2, 0) ; if (tmp171) { /* tmp170 = */ aux_char_23 (arg0, ',') ; } else { /* empty */ } /* end of [if] */ /* tmp172 = */ aux_hityp_25 (arg0, tmp168) ; tmp173 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp169 ; arg2 = tmp173 ; goto __ats_lab_aux_hityplst_26 ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: break ; } while (0) ; return /* (tmp167) */ ; } /* end of [aux_hityplst_26] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 7289(line=276, offs=7) -- 7610(line=285, offs=24) */ ATSstaticdec() ats_void_type aux_hityplstlst_27 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; // ATSlocal_void (tmp177) ; ATSlocal (ats_bool_type, tmp178) ; // ATSlocal_void (tmp179) ; ATSlocal (ats_int_type, tmp180) ; __ats_lab_aux_hityplstlst_27: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp178 = atspre_gt_int_int (arg2, 0) ; if (tmp178) { /* tmp177 = */ aux_char_23 (arg0, ';') ; } else { /* empty */ } /* end of [if] */ /* tmp179 = */ aux_hityplst_26 (arg0, tmp175, 0) ; tmp180 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp176 ; arg2 = tmp180 ; goto __ats_lab_aux_hityplstlst_27 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: break ; } while (0) ; return /* (tmp174) */ ; } /* end of [aux_hityplstlst_27] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 7653(line=288, offs=7) -- 7976(line=297, offs=24) */ ATSstaticdec() ats_void_type aux1_hityplstlst_28 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; ATSlocal (ats_bool_type, tmp185) ; // ATSlocal_void (tmp186) ; ATSlocal (ats_int_type, tmp187) ; __ats_lab_aux1_hityplstlst_28: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp185 = atspre_gt_int_int (arg2, 0) ; if (tmp185) { /* tmp184 = */ aux_char_23 (arg0, '_') ; } else { /* empty */ } /* end of [if] */ /* tmp186 = */ aux_hityplst_26 (arg0, tmp182, 0) ; tmp187 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp183 ; arg2 = tmp187 ; goto __ats_lab_aux1_hityplstlst_28 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: break ; } while (0) ; return /* (tmp181) */ ; } /* end of [aux1_hityplstlst_28] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 5975(line=232, offs=3) -- 8261(line=308, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp188) ; // ATSlocal_void (tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; // ATSlocal_void (tmp191) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make: /* ats_ptr_type tmp188 ; */ tmp188 = (ats_sum_ptr_type)0 ; /* tmp189 = */ aux_string_24 ((&tmp188), ats_castfn_mac(ats_ptr_type, arg0), 0) ; tmp190 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode (arg1) ; /* tmp191 = */ aux1_hityplstlst_28 ((&tmp188), tmp190, 1) ; tmp149 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev (tmp188) ; return (tmp149) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 8404(line=316, offs=4) -- 8622(line=321, offs=4) */ ATSstaticdec() ats_void_type fprint_tmpcstvar_29 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_fprint_tmpcstvar_29: do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp193 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp193) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp194 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp194) ; break ; } while (0) ; return /* (tmp192) */ ; } /* end of [fprint_tmpcstvar_29] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 8656(line=323, offs=4) -- 8730(line=323, offs=78) */ ATSstaticdec() ats_void_type print_tmpcstvar_30 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; // ATSlocal_void (tmp198) ; __ats_lab_print_tmpcstvar_30: tmp196 = atspre_stdout_get () ; tmp197 = ats_selsin_mac(tmp196, atslab_1) ; /* tmp198 = */ fprint_tmpcstvar_29 (tmp197, arg0) ; /* tmp195 = */ atspre_stdout_view_set () ; return /* (tmp195) */ ; } /* end of [print_tmpcstvar_30] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 8734(line=324, offs=4) -- 8808(line=324, offs=78) */ ATSstaticdec() ats_void_type prerr_tmpcstvar_31 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; // ATSlocal_void (tmp202) ; __ats_lab_prerr_tmpcstvar_31: tmp200 = atspre_stderr_get () ; tmp201 = ats_selsin_mac(tmp200, atslab_1) ; /* tmp202 = */ fprint_tmpcstvar_29 (tmp201, arg0) ; /* tmp199 = */ atspre_stderr_view_set () ; return /* (tmp199) */ ; } /* end of [prerr_tmpcstvar_31] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 9175(line=350, offs=7) -- 9301(line=354, offs=6) */ ATSstaticdec() ats_void_type aux_33 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; __ats_lab_aux_33: tmp205 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (arg1) ; /* tmp204 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_add (arg0, tmp205) ; return /* (tmp204) */ ; } /* end of [aux_33] */ typedef struct { ats_fun_ptr_type closure_fun ; } aux_33_closure_type ; ats_void_type aux_33_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { aux_33 (arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_33_closure_init (aux_33_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_33_clofun ; return ; } /* end of function */ ats_clo_ptr_type aux_33_closure_make () { aux_33_closure_type *p_clo = ATS_MALLOC(sizeof(aux_33_closure_type)) ; aux_33_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 9327(line=356, offs=7) -- 9967(line=375, offs=6) */ ATSstaticdec() ats_void_type auxlst_34 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; // ATSlocal_void (tmp211) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; __ats_lab_auxlst_34: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_31_1 ; } __ats_lab_29_2: tmp207 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp208 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp210 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp211 = */ aux_33 (tmp207, tmp209) ; arg0 = tmp208 ; arg1 = tmp210 ; goto __ats_lab_auxlst_34 ; // tail call break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_31_1 ; } __ats_lab_30_2: break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: __ats_lab_31_2: /* tmp212 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp213 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; /* tmp214 = */ atspre_prerr_string (ATSstrcst(": template argument mismatch for [")) ; /* tmp215 = */ prerr_tmpcstvar_31 (env1) ; /* tmp216 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp217 = */ atspre_prerr_newline () ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp206) */ ; } /* end of [auxlst_34] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxlst_34_closure_type ; ats_void_type auxlst_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { auxlst_34 (((auxlst_34_closure_type*)cloptr)->closure_env_0, ((auxlst_34_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_34_closure_init (auxlst_34_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_34_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_34_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxlst_34_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_34_closure_type)) ; auxlst_34_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 9996(line=377, offs=7) -- 10657(line=396, offs=6) */ ATSstaticdec() ats_void_type auxlstlst_35 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp218) ; ATSlocal (anairiats_rec_2, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; __ats_lab_auxlstlst_35: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_34_1 ; } __ats_lab_32_2: tmp219 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp222 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp224 = ats_select_mac(tmp219, atslab_0) ; /* tmp223 = */ auxlst_34 (env0, env1, tmp224, tmp221) ; arg0 = tmp220 ; arg1 = tmp222 ; goto __ats_lab_auxlstlst_35 ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_34_1 ; } __ats_lab_33_2: break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: __ats_lab_34_1: __ats_lab_34_2: /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp226 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; /* tmp227 = */ atspre_prerr_string (ATSstrcst(": template argument mismatch for [")) ; /* tmp228 = */ prerr_tmpcstvar_31 (env1) ; /* tmp229 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp230 = */ atspre_prerr_newline () ; /* tmp218 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp218) */ ; } /* end of [auxlstlst_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxlstlst_35_closure_type ; ats_void_type auxlstlst_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { auxlstlst_35 (((auxlstlst_35_closure_type*)cloptr)->closure_env_0, ((auxlstlst_35_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type auxlstlst_35_closure_init (auxlstlst_35_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlstlst_35_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxlstlst_35_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxlstlst_35_closure_type *p_clo = ATS_MALLOC(sizeof(auxlstlst_35_closure_type)) ; auxlstlst_35_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 9047(line=342, offs=4) -- 10736(line=400, offs=4) */ ATSstaticdec() ats_void_type template_arg_match_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp203) ; ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_template_arg_match_32: tmp231 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode (arg3) ; /* tmp203 = */ auxlstlst_35 (arg0, arg1, arg2, tmp231) ; return /* (tmp203) */ ; } /* end of [template_arg_match_32] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2766(line=87, offs=3) -- 2870(line=89, offs=24) */ ATSstaticdec() ats_void_type chain_insert_048_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_chain_insert_048_ats_ptr_type_2cats_ptr_type: tmp257 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp257, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_11, tmp257, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_11, tmp257, atslab_2, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp257 ; return /* (tmp256) */ ; } /* end of [chain_insert_048_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 4157(line=133, offs=3) -- 4487(line=143, offs=4) */ ATSstaticdec() ats_void_type table_insert_074_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp252) ; ATSlocal (ats_size_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_table_insert_074_ats_ptr_type_2cats_ptr_type: tmp253 = atspre_size1_of_int1 (arg1) ; tmp254 = atspre_array_ptr_takeout_tsz (arg0, tmp253, sizeof(ats_ptr_type)) ; tmp255 = ats_selsin_mac(tmp254, atslab_2) ; /* tmp252 = */ chain_insert_048_ats_ptr_type_2cats_ptr_type (tmp255, arg2, arg3) ; return /* (tmp252) */ ; } /* end of [table_insert_074_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5954(line=202, offs=20) -- 6152(line=209, offs=4) */ ATSstaticdec() ats_void_type ht_insert_0105_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp246) ; ATSlocal (ats_uint_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_int_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; // ATSlocal_void (tmp251) ; ATSlocal (ats_int_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; __ats_lab_ht_insert_0105_ats_ptr_type_2cats_ptr_type: tmp248 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_hash) ; tmp247 = ((ats_uint_type(*)(ats_ptr_type))tmp248) (arg1) ; tmp250 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_size) ; tmp249 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp247), tmp250) ; /* tmp251 = */ table_insert_074_ats_ptr_type_2cats_ptr_type (&ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_table[0]), tmp249, arg1, arg2) ; tmp259 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_nitm) ; tmp258 = atspre_add_int_int (tmp259, 1) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_nitm) = tmp258 ; return /* (tmp246) */ ; } /* end of [ht_insert_0105_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 6239(line=213, offs=26) -- 6492(line=221, offs=4) */ ATSstaticdec() ats_void_type ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; __ats_lab_ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp273 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp274 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; ATS_FREE(arg1) ; /* tmp276 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (arg0, tmp273, tmp274) ; arg0 = arg0 ; arg1 = tmp275 ; goto __ats_lab_ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: break ; } while (0) ; return /* (tmp272) */ ; } /* end of [ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8835(line=312, offs=7) -- 9180(line=321, offs=6) */ ATSstaticdec() ats_void_type loop_42 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp268) ; ATSlocal (ats_bool_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_int_type, tmp277) ; __ats_lab_loop_42: tmp269 = atspre_ilt (arg3, arg0) ; if (tmp269) { tmp270 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get (&ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_table[0]), arg3) ; /* tmp271 = */ ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (arg2, tmp270) ; tmp277 = atspre_iadd (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp277 ; goto __ats_lab_loop_42 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp268) */ ; } /* end of [loop_42] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8621(line=308, offs=5) -- 9290(line=326, offs=4) */ ATSstaticdec() ats_ptr_type htp_resize_0134_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_int_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; __ats_lab_htp_resize_0134_ats_ptr_type_2cats_ptr_type: tmp263 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_size) ; tmp265 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hash) ; tmp266 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_eq) ; tmp264 = ats_htp_make (tmp265, tmp266, arg1) ; tmp267 = ats_selsin_mac(tmp264, atslab_1) ; /* tmp278 = */ loop_42 (tmp263, arg0, tmp267, 0) ; /* tmp279 = */ __ats_htp_free (arg0) ; tmp262 = tmp267 ; return (tmp262) ; } /* end of [htp_resize_0134_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 11172(line=403, offs=16) -- 11905(line=428, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_insert_01711_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_bool_type, tmp240) ; ATSlocal (ats_int_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_bool_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_int_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; // ATSlocal_void (tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_hashtbl_insert_01711_ats_ptr_type_2cats_ptr_type: tmp236 = atspre_ref_get_view_ptr (arg0) ; tmp237 = ats_selsin_mac(tmp236, atslab_1) ; tmp238 = ats_ptrget_mac(ats_ptr_type, tmp237) ; tmp239 = ats_selsin_mac(tmp238, atslab_1) ; tmp240 = atspre_pneq (tmp239, atspre_null_ptr) ; if (tmp240) { tmp241 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, tmp239), atslab_size) ; tmp242 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_10, tmp239), atslab_nitm) ; tmp244 = atspre_imul (tmp241, 5) ; tmp243 = atspre_lt_int_int (tmp242, tmp244) ; if (tmp243) { /* tmp245 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (tmp239, arg1, arg2) ; tmp260 = tmp239 ; ats_ptrget_mac(ats_ptr_type, tmp237) = tmp260 ; tmp235 = (ats_sum_ptr_type)0 ; } else { tmp280 = atspre_iadd (tmp241, tmp241) ; tmp261 = htp_resize_0134_ats_ptr_type_2cats_ptr_type (tmp239, tmp280) ; tmp281 = ats_selsin_mac(tmp261, atslab_1) ; /* tmp282 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (tmp281, arg1, arg2) ; tmp283 = tmp281 ; ats_ptrget_mac(ats_ptr_type, tmp237) = tmp283 ; tmp235 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } else { tmp284 = tmp239 ; ats_ptrget_mac(ats_ptr_type, tmp237) = tmp284 ; tmp235 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp235, atslab_0, arg2) ; } /* end of [if] */ return (tmp235) ; } /* end of [hashtbl_insert_01711_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 11060(line=418, offs=1) -- 11384(line=435, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add: tmp234 = hashtbl_insert_01711_ats_ptr_type_2cats_ptr_type (statmp232, arg0, arg1) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp234 != (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (tmp234 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: ATS_FREE(tmp234) ; /* tmp285 = */ prerr_interror_0 () ; /* tmp286 = */ atspre_prerr_string (ATSstrcst(": tmpnamtbl_add: fullname = ")) ; /* tmp287 = */ atspre_prerr_string (arg0) ; /* tmp288 = */ atspre_prerr_newline () ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp233) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2269(line=73, offs=3) -- 2695(line=83, offs=4) */ ATSstaticdec() ats_ptr_type chain_search_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_bool_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; __ats_lab_chain_search_039_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp307 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp308 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp309 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp310 = ((ats_bool_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp307) ; if (tmp310) { tmp306 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp306, atslab_0, tmp308) ; } else { tmp311 = ats_ptrget_mac(ats_ptr_type, tmp309) ; arg0 = tmp311 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_chain_search_039_ats_ptr_type_2cats_ptr_type ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: tmp306 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp306) ; } /* end of [chain_search_039_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 3727(line=119, offs=3) -- 4085(line=129, offs=4) */ ATSstaticdec() ats_ptr_type table_search_064_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_size_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp312) ; __ats_lab_table_search_064_ats_ptr_type_2cats_ptr_type: tmp303 = atspre_size1_of_int1 (arg1) ; tmp304 = atspre_array_ptr_takeout_tsz (arg0, tmp303, sizeof(ats_ptr_type)) ; tmp305 = ats_selsin_mac(tmp304, atslab_2) ; tmp312 = ats_ptrget_mac(ats_ptr_type, tmp305) ; tmp302 = chain_search_039_ats_ptr_type_2cats_ptr_type (tmp312, arg2, arg3) ; return (tmp302) ; } /* end of [table_search_064_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5707(line=192, offs=20) -- 5890(line=199, offs=4) */ ATSstaticdec() ats_ptr_type ht_search_0100_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_uint_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_int_type, tmp300) ; ATSlocal (ats_int_type, tmp301) ; ATSlocal (ats_ptr_type, tmp313) ; __ats_lab_ht_search_0100_ats_ptr_type_2cats_ptr_type: tmp299 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_hash) ; tmp298 = ((ats_uint_type(*)(ats_ptr_type))tmp299) (arg1) ; tmp301 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_size) ; tmp300 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp298), tmp301) ; tmp313 = ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_eq) ; tmp297 = table_search_064_ats_ptr_type_2cats_ptr_type (&ats_select_mac(ats_ptrget_mac(anairiats_rec_10, arg0), atslab_table[0]), tmp300, arg1, tmp313) ; return (tmp297) ; } /* end of [ht_search_0100_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 10666(line=380, offs=16) -- 11067(line=396, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_search_01710_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_bool_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; __ats_lab_hashtbl_search_01710_ats_ptr_type_2cats_ptr_type: tmp291 = atspre_ref_get_view_ptr (arg0) ; tmp292 = ats_selsin_mac(tmp291, atslab_1) ; tmp293 = ats_ptrget_mac(ats_ptr_type, tmp292) ; tmp294 = ats_selsin_mac(tmp293, atslab_1) ; tmp295 = atspre_pneq (tmp294, atspre_null_ptr) ; if (tmp295) { tmp296 = ht_search_0100_ats_ptr_type_2cats_ptr_type (tmp294, arg1) ; tmp314 = tmp294 ; ats_ptrget_mac(ats_ptr_type, tmp292) = tmp314 ; tmp290 = tmp296 ; } else { tmp315 = tmp294 ; ats_ptrget_mac(ats_ptr_type, tmp292) = tmp315 ; tmp290 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp290) ; } /* end of [hashtbl_search_01710_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 11437(line=438, offs=16) -- 11496(line=439, offs=47) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp289) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find: tmp289 = hashtbl_search_01710_ats_ptr_type_2cats_ptr_type (statmp232, arg0) ; return (tmp289) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 11592(line=448, offs=1) -- 12928(line=487, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; // ATSlocal_void (tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef: tmp317 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ (arg5, arg2) ; tmp318 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (tmp317) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_push () ; /* tmp320 = ats_selsin_mac(tmp319, atslab_1) */ ; /* tmp321 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_push () ; /* tmp322 = ats_selsin_mac(tmp321, atslab_1) */ ; tmp323 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_arg (arg6) ; /* tmp324 = */ template_arg_match_32 (arg0, arg3, tmp323, arg4) ; /* tmp325 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add (arg5, tmp318) ; /* tmp326 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp327 = ats_selsin_mac(tmp326, atslab_1) */ ; tmp329 = (ats_sum_ptr_type)0 ; /* tmp328 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (tmp317, tmp329) ; tmp330 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (tmp317) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp331, atslab_0, tmp330) ; tmp332 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp331), atslab_1) ; tmp333 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp332) = tmp333 ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_exp (arg6) ; tmp335 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp334), atslab_hiexp_loc) ; tmp337 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp334), atslab_hiexp_node) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp337)->tag != 22) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_7, tmp337, atslab_0) ; tmp339 = ats_caselptrlab_mac(anairiats_sum_7, tmp337, atslab_1) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (tmp335, tmp331, tmp338, tmp339, tmp317) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: /* tmp340 = */ prerr_loc_interror_1 (tmp335) ; /* tmp341 = */ atspre_prerr_string (ATSstrcst(": ccomp_tmpdef: hie = ")) ; /* tmp342 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (tmp334) ; /* tmp343 = */ atspre_prerr_newline () ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__the_stactx_pop () ; /* tmp346 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_pop () ; tmp316 = tmp318 ; return (tmp316) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 13011(line=493, offs=3) -- 13865(line=518, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (atsopt_count_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; // ATSlocal_void (tmp357) ; // ATSlocal_void (tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make: tmp348 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef (arg0) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp348)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp350 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg0) ; tmp351 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_stamp (arg0) ; tmp353 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp350) ; tmp354 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp (tmp351) ; tmp352 = atspre_tostringf (ATSstrcst("%s$%s"), tmp353, tmp354) ; tmp349 = ats_castfn_mac(ats_ptr_type, tmp352) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp348)->tag != 1) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_9, tmp348, atslab_0) ; tmp349 = tmp355 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp348)->tag != 3) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_9, tmp348, atslab_0) ; tmp349 = tmp356 ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (((ats_sum_ptr_type)tmp348)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: /* tmp357 = */ prerr_interror_0 () ; /* tmp358 = */ atspre_prerr_string (ATSstrcst(": tmpnamtbl_cst_name_make: d2c = ")) ; /* tmp359 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (arg0) ; /* tmp360 = */ atspre_prerr_newline () ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp347 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make (tmp349, arg1) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 13937(line=522, offs=3) -- 14231(line=531, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_var_name_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (atsopt_count_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_var_name_make: tmp362 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp363 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg0) ; tmp365 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp362) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp (tmp363) ; tmp364 = atspre_tostringf (ATSstrcst("%s$%s"), tmp365, tmp366) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_name_make (ats_castfn_mac(ats_ptr_type, tmp364), arg1) ; return (tmp361) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_var_name_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 14324(line=537, offs=3) -- 15674(line=576, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_cst (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; ATSlocal (ats_int_type, tmp383) ; // ATSlocal_void (tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_cst: tmp368 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize (arg4) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make (arg3, tmp368) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find (tmp369) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp370 != (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_47_1: tmp372 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_find (arg3) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp372 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_4, tmp372, atslab_0) ; ATS_FREE(tmp372) ; tmp371 = tmp373 ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (tmp372 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: /* tmp374 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg1) ; /* tmp375 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; /* tmp376 = */ atsopt_debug_prerrf (ATSstrcst(": %s: ccomp_exp_template_cst"), ATSstrcst("ats_ccomp_trans_temp.dats")) ; /* tmp377 = */ atspre_prerr_string (ATSstrcst(": the template definition for [")) ; /* tmp378 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (arg3) ; /* tmp379 = */ atspre_prerr_string (ATSstrcst("] is unavailable at [")) ; /* tmp380 = */ atspre_prerr_string (tmp369) ; /* tmp381 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp382 = */ atspre_prerr_newline () ; /* tmp371 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp383 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp384 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set (0) ; tmp386 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp386)->tag = 0 ; ats_selptrset_mac(anairiats_sum_9, tmp386, atslab_0, arg3) ; tmp385 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef (arg1, arg0, arg2, tmp386, tmp368, tmp369, tmp371) ; /* tmp387 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set (tmp383) ; tmp367 = tmp385 ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp370 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp388 = ats_caselptrlab_mac(anairiats_sum_4, tmp370, atslab_0) ; ATS_FREE(tmp370) ; tmp367 = tmp388 ; break ; } while (0) ; return (tmp367) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_temp.dats: 15767(line=582, offs=3) -- 17368(line=628, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_var (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; ATSlocal (ats_int_type, tmp405) ; ATSlocal (ats_int_type, tmp406) ; // ATSlocal_void (tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; // ATSlocal_void (tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_var: tmp390 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize (arg4) ; tmp391 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_var_name_make (arg3, tmp390) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_find (tmp391) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (tmp392 != (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_51_1: tmp394 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_find (arg3) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp394 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp395 = ats_caselptrlab_mac(anairiats_sum_4, tmp394, atslab_0) ; ATS_FREE(tmp394) ; tmp393 = tmp395 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (tmp394 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg1) ; /* tmp397 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; /* tmp398 = */ atsopt_debug_prerrf (ATSstrcst(": %s: ccomp_exp_template_var"), ATSstrcst("ats_ccomp_trans_temp.dats")) ; /* tmp399 = */ atspre_prerr_string (ATSstrcst(": the template definition for [")) ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg3) ; /* tmp401 = */ atspre_prerr_string (ATSstrcst("] is unavailable at [")) ; /* tmp402 = */ atspre_prerr_string (tmp391) ; /* tmp403 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp404 = */ atspre_prerr_newline () ; /* tmp393 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (arg3) ; tmp406 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set (tmp405) ; tmp409 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp409)->tag = 1 ; ats_selptrset_mac(anairiats_sum_9, tmp409, atslab_0, arg3) ; tmp408 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__ccomp_tmpdef (arg1, arg0, arg2, tmp409, tmp390, tmp391, tmp393) ; /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set (tmp406) ; tmp389 = tmp408 ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (tmp392 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp411 = ats_caselptrlab_mac(anairiats_sum_4, tmp392, atslab_0) ; ATS_FREE(tmp392) ; tmp389 = tmp411 ; break ; } while (0) ; return (tmp389) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_var] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__TMPvar_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp8, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp232, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp7 = stactx_nil_2 () ; statmp4 = ref_make_elt_01686_ats_ptr_type (statmp7) ; statmp9 = (ats_sum_ptr_type)0 ; statmp8 = ref_make_elt_01686_ats_ptr_type (statmp9) ; statmp232 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint (1024) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_trans_temp_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_fixity_sats.c0000664000175000017500000000550112223166157021461 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCrgt_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYnon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYinf_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpre_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpos_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMatm_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMopr_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERinf_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpre_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpos_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCrgt_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYnon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYinf_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpre_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpos_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMatm_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMopr_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERinf_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpre_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpos_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_fixity_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_dcst_dats.c0000664000175000017500000010053212223166157022534 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_d2cst_loc ; ats_ptr_type atslab_d2cst_fil ; ats_ptr_type atslab_d2cst_sym ; ats_ptr_type atslab_d2cst_kind ; ats_ptr_type atslab_d2cst_decarg ; ats_ptr_type atslab_d2cst_arilst ; ats_ptr_type atslab_d2cst_typ ; ats_ptr_type atslab_d2cst_extdef ; ats_ptr_type atslab_d2cst_def ; atsopt_count_type atslab_d2cst_stamp ; ats_ptr_type atslab_d2cst_hityp ; } anairiats_rec_0 ; /* external typedefs */ typedef anairiats_rec_0 d2cst_struct ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2cst_stamp_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_castfn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_praxi) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prfun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prval) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_mac) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_sta) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__d2cst_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_int_type _compare_d2cst_d2cst_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 2494(line=86, offs=3) -- 3092(line=112, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (atsopt_count_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_make: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2cst_stamp_make () ; tmp2 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp3 = ats_selsin_mac(tmp2, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_loc) = arg2 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_fil) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_sym) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_kind) = arg3 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_decarg) = arg4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_arilst) = arg5 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_typ) = arg6 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_extdef) = arg7 ; tmp4 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_def) = tmp4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_stamp) = tmp1 ; tmp5 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp3), atslab_d2cst_hityp) = tmp5 ; /* tmp6 = */ atspre_vbox_make_view_ptr (tmp3) ; /* tmp7 = ats_selsin_mac(tmp6, atslab_1) */ ; tmp0 = tmp3 ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3141(line=114, offs=25) -- 3198(line=115, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc: tmp9 = ats_selsin_mac(arg0, atslab_1) ; tmp8 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp9), atslab_d2cst_loc) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3224(line=117, offs=25) -- 3281(line=118, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_fil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_fil: tmp11 = ats_selsin_mac(arg0, atslab_1) ; tmp10 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_d2cst_fil) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_fil] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3307(line=120, offs=25) -- 3364(line=121, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym: tmp13 = ats_selsin_mac(arg0, atslab_1) ; tmp12 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp13), atslab_d2cst_sym) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3391(line=123, offs=26) -- 3449(line=124, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_kind (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_kind: tmp15 = ats_selsin_mac(arg0, atslab_1) ; tmp14 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp15), atslab_d2cst_kind) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_kind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3478(line=126, offs=28) -- 3538(line=127, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_arilst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_arilst: tmp17 = ats_selsin_mac(arg0, atslab_1) ; tmp16 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp17), atslab_d2cst_arilst) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_arilst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3567(line=129, offs=28) -- 3627(line=130, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg: tmp19 = ats_selsin_mac(arg0, atslab_1) ; tmp18 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp19), atslab_d2cst_decarg) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3656(line=132, offs=28) -- 3734(line=133, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_decarg (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_decarg: tmp21 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp21), atslab_d2cst_decarg) = arg1 ; return /* (tmp20) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_decarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3760(line=135, offs=25) -- 3817(line=136, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ: tmp23 = ats_selsin_mac(arg0, atslab_1) ; tmp22 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp23), atslab_d2cst_typ) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3846(line=138, offs=28) -- 3906(line=139, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef: tmp25 = ats_selsin_mac(arg0, atslab_1) ; tmp24 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp25), atslab_d2cst_extdef) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 3932(line=141, offs=25) -- 3989(line=142, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_def (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_def: tmp27 = ats_selsin_mac(arg0, atslab_1) ; tmp26 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp27), atslab_d2cst_def) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_def] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4015(line=144, offs=25) -- 4084(line=145, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_def (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_def: tmp29 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp29), atslab_d2cst_def) = arg1 ; return /* (tmp28) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_def] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4112(line=147, offs=27) -- 4171(line=148, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_stamp: tmp31 = ats_selsin_mac(arg0, atslab_1) ; tmp30 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp31), atslab_d2cst_stamp) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4252(line=151, offs=27) -- 4311(line=152, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp: tmp33 = ats_selsin_mac(arg0, atslab_1) ; tmp32 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp33), atslab_d2cst_hityp) ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4361(line=157, offs=3) -- 4412(line=157, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2cst_d2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2cst_d2cst: tmp35 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst (arg0, arg1) ; tmp34 = atspre_ilt (tmp35, 0) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2cst_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4441(line=159, offs=3) -- 4493(line=159, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2cst_d2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp36) ; ATSlocal (ats_int_type, tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2cst_d2cst: tmp37 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst (arg0, arg1) ; tmp36 = atspre_ilte (tmp37, 0) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2cst_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4522(line=162, offs=3) -- 4573(line=162, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2cst_d2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2cst_d2cst: tmp39 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst (arg0, arg1) ; tmp38 = atspre_ieq (tmp39, 0) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2cst_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4602(line=164, offs=3) -- 4654(line=164, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2cst_d2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp40) ; ATSlocal (ats_int_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2cst_d2cst: tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst (arg0, arg1) ; tmp40 = atspre_ineq (tmp41, 0) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2cst_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 4659(line=166, offs=4) -- 4958(line=176, offs=4) */ ATSstaticdec() ats_int_type _compare_d2cst_d2cst_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (atsopt_count_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (atsopt_count_type, tmp46) ; __ats_lab__compare_d2cst_d2cst_18: tmp43 = ats_selsin_mac(arg0, atslab_1) ; tmp44 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp43), atslab_d2cst_stamp) ; tmp45 = ats_selsin_mac(arg1, atslab_1) ; tmp46 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp45), atslab_d2cst_stamp) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp44, tmp46) ; return (tmp42) ; } /* end of [_compare_d2cst_d2cst_18] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 5023(line=179, offs=21) -- 5088(line=180, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst: tmp47 = _compare_d2cst_d2cst_18 (arg0, arg1) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 5168(line=185, offs=24) -- 5315(line=191, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun: tmp49 = ats_selsin_mac(arg0, atslab_1) ; tmp50 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_d2cst_kind) ; tmp48 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun (tmp50) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 5389(line=195, offs=27) -- 5546(line=201, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extmac (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extmac: tmp52 = ats_selsin_mac(arg0, atslab_1) ; tmp53 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp52), atslab_d2cst_extdef) ; tmp51 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_mac (tmp53) ; return (tmp51) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extmac] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 5603(line=204, offs=27) -- 5760(line=210, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta: tmp55 = ats_selsin_mac(arg0, atslab_1) ; tmp56 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp55), atslab_d2cst_extdef) ; tmp54 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_sta (tmp56) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 5837(line=214, offs=27) -- 5987(line=220, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn: tmp58 = ats_selsin_mac(arg0, atslab_1) ; tmp59 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp58), atslab_d2cst_kind) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_castfn (tmp59) ; return (tmp57) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 6046(line=224, offs=26) -- 6195(line=230, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi: tmp61 = ats_selsin_mac(arg0, atslab_1) ; tmp62 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp61), atslab_d2cst_kind) ; tmp60 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_praxi (tmp62) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 6249(line=232, offs=26) -- 6398(line=238, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun: tmp64 = ats_selsin_mac(arg0, atslab_1) ; tmp65 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp64), atslab_d2cst_kind) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prfun (tmp65) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 6452(line=240, offs=26) -- 6601(line=246, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval: tmp67 = ats_selsin_mac(arg0, atslab_1) ; tmp68 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp67), atslab_d2cst_kind) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prval (tmp68) ; return (tmp66) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 6655(line=248, offs=26) -- 6804(line=254, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof: tmp70 = ats_selsin_mac(arg0, atslab_1) ; tmp71 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp70), atslab_d2cst_kind) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (tmp71) ; return (tmp69) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 6861(line=258, offs=25) -- 7044(line=264, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp: tmp73 = ats_selsin_mac(arg0, atslab_1) ; tmp74 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp73), atslab_d2cst_decarg) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp74 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp74 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp72 = ats_false_bool ; break ; } while (0) ; return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7164(line=271, offs=16) -- 7210(line=272, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg0) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp76) ; return (tmp75) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7285(line=278, offs=14) -- 7371(line=280, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst: tmp78 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg1) ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp78) ; return /* (tmp77) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7420(line=282, offs=23) -- 7457(line=282, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cst: tmp80 = atspre_stdout_get () ; tmp81 = ats_selsin_mac(tmp80, atslab_1) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (tmp81, arg0) ; /* tmp79 = */ atspre_stdout_view_set () ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7480(line=283, offs=23) -- 7517(line=283, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst: tmp84 = atspre_stderr_get () ; tmp85 = ats_selsin_mac(tmp84, atslab_1) ; /* tmp86 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (tmp85, arg0) ; /* tmp83 = */ atspre_stderr_view_set () ; return /* (tmp83) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7566(line=288, offs=17) -- 7634(line=289, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst: /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) ; return /* (tmp87) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7689(line=292, offs=26) -- 7731(line=292, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cstlst: tmp89 = atspre_stdout_get () ; tmp90 = ats_selsin_mac(tmp89, atslab_1) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst (tmp90, arg0) ; /* tmp88 = */ atspre_stdout_view_set () ; return /* (tmp88) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2cstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dcst.dats: 7757(line=293, offs=26) -- 7799(line=293, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cstlst: tmp93 = atspre_stderr_get () ; tmp94 = ats_selsin_mac(tmp93, atslab_1) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cstlst (tmp94, arg0) ; /* tmp92 = */ atspre_stderr_view_set () ; return /* (tmp92) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cstlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_d2cst_set_hityp ( ats_ptr_type d2c, ats_ptr_type ohit ) { ((d2cst_struct*)d2c)->atslab_d2cst_hityp = ohit ; return ; } /* end of [atsopt_d2cst_set_hityp] */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_dcst_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_patcst2_sats.c0000664000175000017500000000640112223166157021525 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCbool_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCchar_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCcon_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCempty_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCfloat_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCint_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCintc_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCrec_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCstring_9) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTcons_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCbool_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCchar_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCcon_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCempty_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCfloat_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCint_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCintc_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCrec_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCstring_9.tag = 9 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_patcst2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_print_dats.c0000664000175000017500000032223012223166157022444 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_0 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_instr_loc ; ats_ptr_type atslab_instr_node ; } anairiats_rec_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_branch_lab ; ats_ptr_type atslab_branch_inss ; } anairiats_rec_17 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargtmpref_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPchar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPenv_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPext_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloat_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloatsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPint_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPintsp_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_var_offs_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPsizeof_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPstring_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmpref_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKbool_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKcon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKexn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKfloat_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplab_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplabint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTcaseof_fail_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTfunarg_fail_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTraise_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTmatpnt_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_arr_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_tail_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_clo_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_fun_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_val_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_partval_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextern_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextval_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfreeptr_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunlab_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdynload_file_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloopexn_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_arg_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRpatck_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_offs_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_offs_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtmplabint_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_beg_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_end_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_tst_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offset) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branch) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_19 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_35 (ats_ref_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 1973(line=56, offs=14) -- 2009(line=56, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmplab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmplab: tmp1 = atspre_stdout_get () ; tmp2 = ats_selsin_mac(tmp1, atslab_1) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (tmp2, arg0) ; /* tmp0 = */ atspre_stdout_view_set () ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmplab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2033(line=58, offs=14) -- 2069(line=58, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmplab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmplab: tmp5 = atspre_stderr_get () ; tmp6 = ats_selsin_mac(tmp5, atslab_1) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (tmp6, arg0) ; /* tmp4 = */ atspre_stderr_view_set () ; return /* (tmp4) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmplab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2115(line=63, offs=14) -- 2153(line=63, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvar: tmp9 = atspre_stdout_get () ; tmp10 = ats_selsin_mac(tmp9, atslab_1) ; /* tmp11 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (tmp10, arg0) ; /* tmp8 = */ atspre_stdout_view_set () ; return /* (tmp8) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2177(line=65, offs=14) -- 2215(line=65, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvar: tmp13 = atspre_stderr_get () ; tmp14 = ats_selsin_mac(tmp13, atslab_1) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (tmp14, arg0) ; /* tmp12 = */ atspre_stderr_view_set () ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2265(line=70, offs=18) -- 2335(line=71, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst: /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar) ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2392(line=75, offs=17) -- 2435(line=75, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; // ATSlocal_void (tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvarlst: tmp18 = atspre_stdout_get () ; tmp19 = ats_selsin_mac(tmp18, atslab_1) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst (tmp19, arg0) ; /* tmp17 = */ atspre_stdout_view_set () ; return /* (tmp17) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_tmpvarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2462(line=77, offs=17) -- 2505(line=77, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvarlst: tmp22 = atspre_stderr_get () ; tmp23 = ats_selsin_mac(tmp22, atslab_1) ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvarlst (tmp23, arg0) ; /* tmp21 = */ atspre_stderr_view_set () ; return /* (tmp21) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_tmpvarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2551(line=82, offs=14) -- 2587(line=82, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlab: tmp26 = atspre_stdout_get () ; tmp27 = ats_selsin_mac(tmp26, atslab_1) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (tmp27, arg0) ; /* tmp25 = */ atspre_stdout_view_set () ; return /* (tmp25) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2611(line=84, offs=14) -- 2647(line=84, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; // ATSlocal_void (tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlab: tmp30 = atspre_stderr_get () ; tmp31 = ats_selsin_mac(tmp30, atslab_1) ; /* tmp32 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (tmp31, arg0) ; /* tmp29 = */ atspre_stderr_view_set () ; return /* (tmp29) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2697(line=89, offs=18) -- 2766(line=90, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst: /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab) ; return /* (tmp33) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2823(line=94, offs=17) -- 2864(line=94, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlablst: tmp35 = atspre_stdout_get () ; tmp36 = ats_selsin_mac(tmp35, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst (tmp36, arg0) ; /* tmp34 = */ atspre_stdout_view_set () ; return /* (tmp34) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2891(line=96, offs=17) -- 2932(line=96, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlablst: tmp39 = atspre_stderr_get () ; tmp40 = ats_selsin_mac(tmp39, atslab_1) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlablst (tmp40, arg0) ; /* tmp38 = */ atspre_stderr_view_set () ; return /* (tmp38) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 2980(line=101, offs=16) -- 6660(line=208, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_int_type, tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; ATSlocal (ats_int_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_int_type, tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; ATSlocal (ats_bool_type, tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; ATSlocal (ats_char_type, tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; ATSlocal (ats_int_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; // ATSlocal_void (tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; // ATSlocal_void (tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim: tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_valprim_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp43)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_1, tmp43, atslab_0) ; /* tmp45 = */ atspre_fprint_string (arg0, ATSstrcst("VParg(")) ; /* tmp46 = */ atspre_fprint_int (arg0, tmp44) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp43)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_1, tmp43, atslab_0) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("VPargref(")) ; /* tmp49 = */ atspre_fprint_int (arg0, tmp47) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp43)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_1, tmp43, atslab_0) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("VPargtmpref(")) ; /* tmp52 = */ atspre_fprint_int (arg0, tmp50) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp43)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_2, tmp43, atslab_0) ; /* tmp54 = */ atspre_fprint_string (arg0, ATSstrcst("VPbool(")) ; /* tmp55 = */ atspre_fprint_bool (arg0, tmp53) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp43)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_0) ; tmp57 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_1) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst("VPcast(")) ; /* tmp59 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp56) ; /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp57) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp43)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_4, tmp43, atslab_0) ; /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("VPchar(")) ; /* tmp64 = */ atspre_fprint_char (arg0, tmp62) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp43)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp65 = ats_caselptrlab_mac(anairiats_sum_5, tmp43, atslab_0) ; tmp66 = ats_caselptrlab_mac(anairiats_sum_5, tmp43, atslab_1) ; /* tmp67 = */ atspre_fprint_string (arg0, ATSstrcst("VPclo(")) ; /* tmp68 = */ atspre_fprint_int (arg0, tmp65) ; /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp66) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp72 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp43)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp74 = */ atspre_fprint_string (arg0, ATSstrcst("VPcst(")) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp73) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp43)->tag != 8) { goto __ats_lab_9_0 ; } __ats_lab_8_1: /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst("VPcstsp(")) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp43)->tag != 9) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp79 = */ atspre_fprint_string (arg0, ATSstrcst("VPenv(")) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp (arg0, tmp78) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp43)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp42 = */ atspre_fprintf_exn (arg0, ATSstrcst("VPext(\"%s\")"), tmp81) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp43)->tag != 11) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp83 = */ atspre_fprint_string (arg0, ATSstrcst("VPfix(")) ; tmp85 = ats_ptrget_mac(ats_ptr_type, tmp82) ; /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp85) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp43)->tag != 12) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp42 = */ atspre_fprintf_exn (arg0, ATSstrcst("VPfloat(%s)"), tmp86) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp43)->tag != 13) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp42 = */ atspre_fprintf_exn (arg0, ATSstrcst("VPfloatsp(%s)"), tmp87) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp43)->tag != 14) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp89 = */ atspre_fprint_string (arg0, ATSstrcst("VPfun(")) ; /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp88) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp43)->tag != 15) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst("VPint(")) ; /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp91) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp43)->tag != 16) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_0) ; /* tmp42 = */ atspre_fprintf_exn (arg0, ATSstrcst("VPintsp(%s)"), tmp94) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp43)->tag != 17) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp96 = */ atspre_fprint_string (arg0, ATSstrcst("VPptrof(")) ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp95) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp43)->tag != 18) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_0) ; tmp99 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_1) ; /* tmp100 = */ atspre_fprint_string (arg0, ATSstrcst("VPptrof_ptr_offs(")) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp98) ; /* tmp102 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp103 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp99) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp43)->tag != 19) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp104 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_0) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_3, tmp43, atslab_1) ; /* tmp106 = */ atspre_fprint_string (arg0, ATSstrcst("VPptrof_var_offs(")) ; /* tmp107 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp104) ; /* tmp108 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp109 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp105) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp43)->tag != 20) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst("VPsizeof(")) ; tmp113 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp110) ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp113) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp43)->tag != 21) { goto __ats_lab_22_0 ; } __ats_lab_21_1: /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("VPstring(...)")) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp43)->tag != 22) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp114 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp115 = */ atspre_fprint_string (arg0, ATSstrcst("VPtmp(")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp114) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp43)->tag != 23) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_6, tmp43, atslab_0) ; /* tmp118 = */ atspre_fprint_string (arg0, ATSstrcst("VPtmpref(")) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp117) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp43)->tag != 24) { goto __ats_lab_25_0 ; } __ats_lab_24_1: /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("VPtop()")) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (((ats_sum_ptr_type)tmp43)->tag != 25) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("VPvoid()")) ; break ; } while (0) ; return /* (tmp42) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 6713(line=211, offs=15) -- 6750(line=211, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprim (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; // ATSlocal_void (tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprim: tmp121 = atspre_stdout_get () ; tmp122 = ats_selsin_mac(tmp121, atslab_1) ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (tmp122, arg0) ; /* tmp120 = */ atspre_stdout_view_set () ; return /* (tmp120) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprim] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 6775(line=213, offs=15) -- 6812(line=213, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprim (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprim: tmp125 = atspre_stderr_get () ; tmp126 = ats_selsin_mac(tmp125, atslab_1) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (tmp126, arg0) ; /* tmp124 = */ atspre_stderr_view_set () ; return /* (tmp124) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprim] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 6863(line=218, offs=19) -- 6933(line=219, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst: /* tmp128 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim) ; return /* (tmp128) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 6992(line=223, offs=18) -- 7034(line=223, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprimlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; // ATSlocal_void (tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprimlst: tmp130 = atspre_stdout_get () ; tmp131 = ats_selsin_mac(tmp130, atslab_1) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (tmp131, arg0) ; /* tmp129 = */ atspre_stdout_view_set () ; return /* (tmp129) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_valprimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 7062(line=225, offs=18) -- 7104(line=225, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprimlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; // ATSlocal_void (tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprimlst: tmp134 = atspre_stderr_get () ; tmp135 = ats_selsin_mac(tmp134, atslab_1) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (tmp135, arg0) ; /* tmp133 = */ atspre_stderr_view_set () ; return /* (tmp133) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 7201(line=232, offs=7) -- 7641(line=244, offs=32) */ ATSstaticdec() ats_void_type aux_19 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; // ATSlocal_void (tmp142) ; ATSlocal (ats_bool_type, tmp143) ; // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_int_type, tmp147) ; __ats_lab_aux_19: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp141 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_2) ; tmp143 = atspre_gt_int_int (arg1, 0) ; if (tmp143) { /* tmp142 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp144 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp139) ; /* tmp145 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp146 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp140) ; tmp147 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp147 ; arg2 = tmp141 ; goto __ats_lab_aux_19 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: break ; } while (0) ; return /* (tmp138) */ ; } /* end of [aux_19] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 7172(line=231, offs=7) -- 7703(line=248, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst: /* tmp137 = */ aux_19 (arg0, 0, arg1) ; return /* (tmp137) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 8048(line=262, offs=11) -- 8429(line=272, offs=28) */ ATSstaticdec() ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; // ATSlocal_void (tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; __ats_lab_aux_21: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp153 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; /* tmp155 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp156 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (arg0, tmp153) ; /* tmp157 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; arg0 = arg0 ; arg1 = tmp154 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: break ; } while (0) ; return /* (tmp152) */ ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 7789(line=254, offs=7) -- 8504(line=275, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offset (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offset: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst(".")) ; /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp149) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp151 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp148 = */ aux_21 (arg0, tmp151) ; break ; } while (0) ; return /* (tmp148) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offset] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 8559(line=278, offs=18) -- 8628(line=279, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst: /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offset) ; return /* (tmp158) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 8703(line=285, offs=14) -- 9658(line=310, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp159) ; ATSlocal (ats_bool_type, tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_char_type, tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; // ATSlocal_void (tmp176) ; // ATSlocal_void (tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp161 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKbool(")) ; /* tmp162 = */ atspre_fprint_bool (arg0, tmp160) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; /* tmp164 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKchar(")) ; /* tmp165 = */ atspre_fprint_char (arg0, tmp163) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp167 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKcon(")) ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp166) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp170 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKexn(")) ; /* tmp171 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp169) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp173 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKfloat(")) ; /* tmp174 = */ atspre_fprint_string (arg0, tmp172) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp176 = */ atspre_fprint_string (arg0, ATSstrcst("PATCKint(")) ; /* tmp177 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp175) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (((ats_sum_ptr_type)arg1)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp178 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp159 = */ atspre_fprintf_exn (arg0, ATSstrcst("PATCKstring(\"%s\")"), tmp178) ; break ; } while (0) ; return /* (tmp159) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 9711(line=313, offs=17) -- 9779(line=314, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patcklst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp179) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patcklst: /* tmp179 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck) ; return /* (tmp179) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patcklst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 9856(line=320, offs=17) -- 10899(line=351, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_int_type, tmp185) ; // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; // ATSlocal_void (tmp191) ; // ATSlocal_void (tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp182 = */ atspre_fprint_string (arg0, ATSstrcst("KONTtmplab(")) ; /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (arg0, tmp181) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp184 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; /* tmp186 = */ atspre_fprint_string (arg0, ATSstrcst("KONTtmplabint(")) ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (arg0, tmp184) ; /* tmp188 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp189 = */ atspre_fprint_int (arg0, tmp185) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_42_0 ; } __ats_lab_41_1: /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("KONTcaseof_fail(...)")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp191 = */ atspre_fprint_string (arg0, ATSstrcst("KONTfunarg_fail(..., ")) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp190) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_44_0 ; } __ats_lab_43_1: /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("KONTmatpnt(...)")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp193 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; /* tmp194 = */ atspre_fprint_string (arg0, ATSstrcst("KONTraise(")) ; /* tmp195 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp193) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("KONTnone()")) ; break ; } while (0) ; return /* (tmp180) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 10953(line=354, offs=16) -- 11020(line=355, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kontlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kontlst: /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont) ; return /* (tmp196) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kontlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 11093(line=361, offs=14) -- 22650(line=722, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_int_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; // ATSlocal_void (tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; // ATSlocal_void (tmp249) ; // ATSlocal_void (tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; // ATSlocal_void (tmp264) ; // ATSlocal_void (tmp265) ; // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; // ATSlocal_void (tmp268) ; // ATSlocal_void (tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; // ATSlocal_void (tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; // ATSlocal_void (tmp289) ; // ATSlocal_void (tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; // ATSlocal_void (tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; // ATSlocal_void (tmp307) ; // ATSlocal_void (tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; // ATSlocal_void (tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; ATSlocal (ats_int_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; // ATSlocal_void (tmp350) ; ATSlocal (ats_int_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; // ATSlocal_void (tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_int_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_int_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; // ATSlocal_void (tmp404) ; // ATSlocal_void (tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; // ATSlocal_void (tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; // ATSlocal_void (tmp424) ; // ATSlocal_void (tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; // ATSlocal_void (tmp434) ; // ATSlocal_void (tmp435) ; // ATSlocal_void (tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; // ATSlocal_void (tmp441) ; // ATSlocal_void (tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_int_type, tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_int_type, tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp461) ; // ATSlocal_void (tmp462) ; // ATSlocal_void (tmp463) ; // ATSlocal_void (tmp464) ; // ATSlocal_void (tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; // ATSlocal_void (tmp467) ; // ATSlocal_void (tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; // ATSlocal_void (tmp472) ; // ATSlocal_void (tmp473) ; // ATSlocal_void (tmp474) ; // ATSlocal_void (tmp475) ; // ATSlocal_void (tmp476) ; // ATSlocal_void (tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; // ATSlocal_void (tmp482) ; // ATSlocal_void (tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; // ATSlocal_void (tmp489) ; // ATSlocal_void (tmp490) ; // ATSlocal_void (tmp491) ; // ATSlocal_void (tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; // ATSlocal_void (tmp497) ; // ATSlocal_void (tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; // ATSlocal_void (tmp502) ; // ATSlocal_void (tmp503) ; // ATSlocal_void (tmp504) ; // ATSlocal_void (tmp505) ; // ATSlocal_void (tmp506) ; // ATSlocal_void (tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_int_type, tmp509) ; // ATSlocal_void (tmp510) ; // ATSlocal_void (tmp511) ; // ATSlocal_void (tmp512) ; // ATSlocal_void (tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; // ATSlocal_void (tmp521) ; // ATSlocal_void (tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; // ATSlocal_void (tmp524) ; // ATSlocal_void (tmp525) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr: tmp198 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_instr_node) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp198)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_11, tmp198, atslab_0) ; tmp200 = ats_caselptrlab_mac(anairiats_sum_11, tmp198, atslab_1) ; tmp201 = ats_caselptrlab_mac(anairiats_sum_11, tmp198, atslab_2) ; /* tmp202 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRarr_heap(")) ; /* tmp203 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp199) ; /* tmp204 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp205 = */ atspre_fprint_int (arg0, tmp200) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp208 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp201) ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp208) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp198)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_0) ; tmp210 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_1) ; tmp211 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_2) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_3) ; /* tmp213 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRarr_stack(")) ; /* tmp214 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp209) ; /* tmp215 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp216 = */ atspre_fprint_int (arg0, tmp210) ; /* tmp217 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp218 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp211) ; /* tmp219 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp212) ; /* tmp220 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp221) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp198)->tag != 2) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_0) ; tmp223 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_1) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_2) ; tmp225 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_3) ; /* tmp226 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRassgn_arr(")) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp222) ; /* tmp228 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp223) ; /* tmp230 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp224) ; /* tmp232 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp225) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp198)->tag != 3) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp234 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_0) ; tmp235 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_1) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_2) ; /* tmp237 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRassgn_clo(")) ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp234) ; /* tmp239 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp240 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp235) ; /* tmp241 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp242 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp236) ; /* tmp243 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp244 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp198)->tag != 4) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp245 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_0) ; tmp246 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_1) ; tmp247 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_2) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_3) ; /* tmp249 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRcall(")) ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp245) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp253 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp246) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp253) ; /* tmp254 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp255 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp247) ; /* tmp256 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp257 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (arg0, tmp248) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp198)->tag != 5) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp259 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRcall_tail(")) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp258) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp198)->tag != 6) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp261 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp262 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp263 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp264 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRcond(")) ; /* tmp265 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp261) ; /* tmp266 = */ atspre_fprint_newline (arg0) ; /* tmp267 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRcond_then:")) ; /* tmp268 = */ atspre_fprint_newline (arg0) ; /* tmp269 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (arg0, tmp262) ; /* tmp270 = */ atspre_fprint_newline (arg0) ; /* tmp271 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRcond_else:")) ; /* tmp272 = */ atspre_fprint_newline (arg0) ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (arg0, tmp263) ; /* tmp274 = */ atspre_fprint_newline (arg0) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp198)->tag != 7) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp276 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp277 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRdefine_clo(")) ; /* tmp278 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp275) ; /* tmp279 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp276) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp198)->tag != 8) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp283 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRdefine_fun(")) ; /* tmp284 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp281) ; /* tmp285 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp282) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp198)->tag != 9) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp287 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp289 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRdefine_val(")) ; /* tmp290 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp287) ; /* tmp291 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp292 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp288) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp198)->tag != 10) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp295 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRdefine_partval(")) ; /* tmp296 = */ atspre_fprint_string (arg0, tmp293) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp294) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp198)->tag != 11) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp197 = */ atspre_fprintf_exn (arg0, ATSstrcst("INSTRextern(\"%s\")"), tmp299) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp198)->tag != 12) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp302 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRextval(")) ; /* tmp303 = */ atspre_fprint_string (arg0, tmp300) ; /* tmp304 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp305 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp301) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp198)->tag != 13) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp307 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRfreeptr(")) ; /* tmp308 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp306) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp198)->tag != 14) { goto __ats_lab_61_0 ; } __ats_lab_60_1: /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRfunction(...)")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp198)->tag != 15) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp309 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp310 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRfunlab(")) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (arg0, tmp309) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp198)->tag != 16) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp312 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp313 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRdynload_file(")) ; /* tmp314 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp312) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp198)->tag != 17) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp317 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRload_ptr(")) ; /* tmp318 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp315) ; /* tmp319 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp320 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp316) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp198)->tag != 18) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp321 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp322 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp323 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp324 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRload_ptr_offs(")) ; /* tmp325 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp321) ; /* tmp326 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp322) ; /* tmp328 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp323) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp198)->tag != 19) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp332 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRload_var(")) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp330) ; /* tmp334 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp335 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp331) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp198)->tag != 20) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp336 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp337 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp338 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp339 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRload_var_offs(")) ; /* tmp340 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp336) ; /* tmp341 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp342 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp337) ; /* tmp343 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp338) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp198)->tag != 21) { goto __ats_lab_68_0 ; } __ats_lab_67_1: /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRloop(...)")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp198)->tag != 22) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp345 = ats_caselptrlab_mac(anairiats_sum_15, tmp198, atslab_0) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_15, tmp198, atslab_1) ; /* tmp347 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRloopexn(")) ; /* tmp348 = */ atspre_fprint_int (arg0, tmp345) ; /* tmp349 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp350 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (arg0, tmp346) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp198)->tag != 23) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_15, tmp198, atslab_0) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_15, tmp198, atslab_1) ; /* tmp353 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_arg(")) ; /* tmp354 = */ atspre_fprint_int (arg0, tmp351) ; /* tmp355 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp352) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp198)->tag != 24) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_0) ; tmp358 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_1) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_2) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_13, tmp198, atslab_3) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_con(")) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp357) ; /* tmp363 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp365 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp358) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp365) ; /* tmp366 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp359) ; /* tmp368 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp369 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprimlst (arg0, tmp360) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp198)->tag != 25) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_0) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_1) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_2) ; tmp373 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_3) ; /* tmp374 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_lazy_delay(")) ; /* tmp375 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp370) ; /* tmp376 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp377 = */ atspre_fprint_int (arg0, tmp371) ; /* tmp378 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp380 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp372) ; /* tmp379 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp380) ; /* tmp381 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp382 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp373) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp198)->tag != 26) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp383 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_0) ; tmp384 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_1) ; tmp385 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_2) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_12, tmp198, atslab_3) ; /* tmp387 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_lazy_force(")) ; /* tmp388 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp383) ; /* tmp389 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp390 = */ atspre_fprint_int (arg0, tmp384) ; /* tmp391 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp393 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp385) ; /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp393) ; /* tmp394 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp395 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp386) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp198)->tag != 27) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp396 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp397 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp398 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp399 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_rec_box(")) ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp396) ; /* tmp401 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp403 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp397) ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp403) ; /* tmp404 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp405 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst (arg0, tmp398) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp198)->tag != 28) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp406 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp408 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp409 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_rec_flt(")) ; /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp406) ; /* tmp411 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp413 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp407) ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp413) ; /* tmp414 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_labvalprimlst (arg0, tmp408) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp198)->tag != 30) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp417 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp418 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_val(")) ; /* tmp419 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp416) ; /* tmp420 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp421 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp417) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp198)->tag != 29) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp422 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp423 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp424 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRmove_ref(")) ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp422) ; /* tmp426 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp427 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp423) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp198)->tag != 31) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp428 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp429 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp430 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp431 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRpatck(")) ; /* tmp432 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp428) ; /* tmp433 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp434 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_patck (arg0, tmp429) ; /* tmp435 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp436 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_kont (arg0, tmp430) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp198)->tag != 32) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp437 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp438 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp439 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRraise(")) ; /* tmp440 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp437) ; /* tmp441 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp442 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp438) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp198)->tag != 34) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp443 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_0) ; tmp444 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_1) ; tmp445 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_2) ; tmp446 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_3) ; /* tmp447 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRselcon(")) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp443) ; /* tmp449 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp450 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp444) ; /* tmp451 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp453 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp445) ; /* tmp452 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp453) ; /* tmp454 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp455 = */ atspre_fprint_int (arg0, tmp446) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp198)->tag != 35) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_0) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_1) ; tmp458 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_2) ; tmp459 = ats_caselptrlab_mac(anairiats_sum_16, tmp198, atslab_3) ; /* tmp460 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRselcon_ptr(")) ; /* tmp461 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp456) ; /* tmp462 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp463 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp457) ; /* tmp464 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp466 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp458) ; /* tmp465 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp466) ; /* tmp467 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp468 = */ atspre_fprint_int (arg0, tmp459) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp198)->tag != 33) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp469 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp470 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp471 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp472 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRselect(")) ; /* tmp473 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp469) ; /* tmp474 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp470) ; /* tmp476 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp477 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp471) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp198)->tag != 37) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp478 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp479 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp480 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRstore_ptr(")) ; /* tmp481 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp478) ; /* tmp482 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp483 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp479) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp198)->tag != 38) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp486 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp487 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRstore_ptr_offs(")) ; /* tmp488 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp484) ; /* tmp489 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp490 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp485) ; /* tmp491 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp492 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp486) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp198)->tag != 39) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp493 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_0) ; tmp494 = ats_caselptrlab_mac(anairiats_sum_3, tmp198, atslab_1) ; /* tmp495 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRstore_var(")) ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp493) ; /* tmp497 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp498 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp494) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp198)->tag != 40) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp499 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_0) ; tmp500 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_1) ; tmp501 = ats_caselptrlab_mac(anairiats_sum_14, tmp198, atslab_2) ; /* tmp502 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRstore_var_offs(")) ; /* tmp503 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp499) ; /* tmp504 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp505 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_offsetlst (arg0, tmp500) ; /* tmp506 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp507 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_valprim (arg0, tmp501) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp198)->tag != 36) { goto __ats_lab_87_0 ; } __ats_lab_86_1: /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRswitch(...)")) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp198)->tag != 41) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp508 = ats_caselptrlab_mac(anairiats_sum_7, tmp198, atslab_0) ; tmp509 = ats_caselptrlab_mac(anairiats_sum_7, tmp198, atslab_1) ; /* tmp510 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRtmplabint(")) ; /* tmp511 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (arg0, tmp508) ; /* tmp512 = */ atspre_fprint_string (arg0, ATSstrcst("_")) ; /* tmp513 = */ atspre_fprint_int (arg0, tmp509) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp198)->tag != 42) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp514 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp515 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRprfck_beg(")) ; /* tmp516 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp514) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp198)->tag != 43) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp517 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp518 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRprfck_end(")) ; /* tmp519 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp517) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp198)->tag != 44) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp520 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp521 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRprfck_tst(")) ; /* tmp522 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp520) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp198)->tag != 45) { goto __ats_lab_92_0 ; } __ats_lab_91_1: /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRtrywith(...)")) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: // if (((ats_sum_ptr_type)tmp198)->tag != 46) { ats_deadcode_failure_handle () ; } __ats_lab_92_1: tmp523 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; /* tmp524 = */ atspre_fprint_string (arg0, ATSstrcst("INSTRvardec(")) ; /* tmp525 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (arg0, tmp523) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp197) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 22699(line=725, offs=13) -- 22736(line=725, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instr: tmp527 = atspre_stdout_get () ; tmp528 = ats_selsin_mac(tmp527, atslab_1) ; /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr (tmp528, arg0) ; /* tmp526 = */ atspre_stdout_view_set () ; return /* (tmp526) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 22759(line=727, offs=13) -- 22796(line=727, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; // ATSlocal_void (tmp533) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instr: tmp531 = atspre_stderr_get () ; tmp532 = ats_selsin_mac(tmp531, atslab_1) ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr (tmp532, arg0) ; /* tmp530 = */ atspre_stderr_view_set () ; return /* (tmp530) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 22845(line=732, offs=17) -- 23030(line=739, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp534) ; // ATSlocal_void (tmp535) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst: /* tmp535 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("\n"), &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: /* tmp534 = */ atspre_fprint_newline (arg0) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: break ; } while (0) ; return /* (tmp534) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 23085(line=742, offs=16) -- 23127(line=742, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instrlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; // ATSlocal_void (tmp539) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instrlst: tmp537 = atspre_stdout_get () ; tmp538 = ats_selsin_mac(tmp537, atslab_1) ; /* tmp539 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (tmp538, arg0) ; /* tmp536 = */ atspre_stdout_view_set () ; return /* (tmp536) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_instrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 23153(line=744, offs=16) -- 23195(line=744, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instrlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; // ATSlocal_void (tmp543) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instrlst: tmp541 = atspre_stderr_get () ; tmp542 = ats_selsin_mac(tmp541, atslab_1) ; /* tmp543 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (tmp542, arg0) ; /* tmp540 = */ atspre_stderr_view_set () ; return /* (tmp540) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 23246(line=749, offs=19) -- 23423(line=753, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branch (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp544) ; // ATSlocal_void (tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; // ATSlocal_void (tmp547) ; // ATSlocal_void (tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branch: tmp546 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_branch_lab) ; /* tmp545 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (arg0, tmp546) ; /* tmp547 = */ atspre_fprint_string (arg0, ATSstrcst(": ")) ; /* tmp548 = */ atspre_fprint_newline (arg0) ; tmp549 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_branch_inss) ; /* tmp544 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instrlst (arg0, tmp549) ; return /* (tmp544) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branch] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 23512(line=758, offs=7) -- 23724(line=765, offs=24) */ ATSstaticdec() ats_void_type aux_35 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; // ATSlocal_void (tmp554) ; __ats_lab_aux_35: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp552 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp553 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; /* tmp554 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branch (arg0, tmp552) ; arg0 = arg0 ; arg1 = tmp553 ; goto __ats_lab_aux_35 ; // tail call break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: break ; } while (0) ; return /* (tmp551) */ ; } /* end of [aux_35] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_print.dats: 23484(line=757, offs=7) -- 23787(line=769, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branchlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp550) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branchlst: /* tmp550 = */ aux_35 (arg0, arg1) ; return /* (tmp550) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_branchlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_scst_dats.c0000664000175000017500000014337712223166157022566 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_s2cst_sym ; ats_ptr_type atslab_s2cst_fil ; ats_ptr_type atslab_s2cst_loc ; ats_ptr_type atslab_s2cst_srt ; ats_ptr_type atslab_s2cst_isabs ; ats_bool_type atslab_s2cst_iscon ; ats_bool_type atslab_s2cst_isrec ; ats_bool_type atslab_s2cst_isasp ; ats_ptr_type atslab_s2cst_iscpy ; ats_ptr_type atslab_s2cst_islst ; ats_ptr_type atslab_s2cst_arilst ; ats_ptr_type atslab_s2cst_argvar ; ats_ptr_type atslab_s2cst_conlst ; ats_ptr_type atslab_s2cst_def ; ats_ptr_type atslab_s2cst_sup ; ats_ptr_type atslab_s2cst_supcls ; ats_ptr_type atslab_s2cst_sVarset ; atsopt_count_type atslab_s2cst_stamp ; ats_int_type atslab_s2cst_tag ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTOPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2cst_stamp_make) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_bool_type, ats_bool_type, ats_bool_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2cst_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type s2rt_arity_list_0 (ats_ptr_type arg0) ; static ats_int_type _compare_s2cst_s2cst_36 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux_41 (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type aux_46 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_51 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 2881(line=84, offs=5) -- 3078(line=89, offs=21) */ ATSstaticdec() ats_ptr_type s2rt_arity_list_0 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_s2rt_arity_list_0: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp3 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp1) ; tmp4 = s2rt_arity_list_0 (tmp2) ; tmp0 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp0, atslab_0, tmp3) ; ats_selptrset_mac(anairiats_sum_1, tmp0, atslab_1, tmp4) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp0 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp0) ; } /* end of [s2rt_arity_list_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 3280(line=102, offs=22) -- 4143(line=138, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_bool_type arg4, ats_bool_type arg5, ats_bool_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (atsopt_count_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2cst_stamp_make () ; tmp7 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_2)) ; tmp8 = ats_selsin_mac(tmp7, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_sym) = arg0 ; tmp9 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_fil) = tmp9 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_loc) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_srt) = arg2 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_isabs) = arg3 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_iscon) = arg4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_isrec) = arg5 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_isasp) = arg6 ; tmp10 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_iscpy) = tmp10 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_islst) = arg7 ; tmp11 = s2rt_arity_list_0 (arg2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_arilst) = tmp11 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_argvar) = arg8 ; tmp12 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_conlst) = tmp12 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_def) = arg9 ; tmp13 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_sup) = tmp13 ; tmp14 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_supcls) = tmp14 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_sVarset) = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_stamp) = tmp6 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp8), atslab_s2cst_tag) = -1 ; /* tmp15 = */ atspre_vbox_make_view_ptr (tmp8) ; /* tmp16 = ats_selsin_mac(tmp15, atslab_1) */ ; tmp5 = tmp8 ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4213(line=142, offs=25) -- 4270(line=143, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym: tmp18 = ats_selsin_mac(arg0, atslab_1) ; tmp17 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp18), atslab_s2cst_sym) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4296(line=145, offs=25) -- 4353(line=146, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_fil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_fil: tmp20 = ats_selsin_mac(arg0, atslab_1) ; tmp19 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp20), atslab_s2cst_fil) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_fil] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4378(line=147, offs=25) -- 4447(line=148, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_fil (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_fil: tmp22 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp22), atslab_s2cst_fil) = arg1 ; return /* (tmp21) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_fil] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4473(line=150, offs=25) -- 4530(line=151, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_loc: tmp24 = ats_selsin_mac(arg0, atslab_1) ; tmp23 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp24), atslab_s2cst_loc) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4556(line=153, offs=25) -- 4613(line=154, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt: tmp26 = ats_selsin_mac(arg0, atslab_1) ; tmp25 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp26), atslab_s2cst_srt) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4641(line=156, offs=27) -- 4700(line=157, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs: tmp28 = ats_selsin_mac(arg0, atslab_1) ; tmp27 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp28), atslab_s2cst_isabs) ; return (tmp27) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4728(line=159, offs=27) -- 4787(line=160, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscon (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscon: tmp30 = ats_selsin_mac(arg0, atslab_1) ; tmp29 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp30), atslab_s2cst_iscon) ; return (tmp29) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscon] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4815(line=162, offs=27) -- 4874(line=163, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isrec (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isrec: tmp32 = ats_selsin_mac(arg0, atslab_1) ; tmp31 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp32), atslab_s2cst_isrec) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isrec] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4902(line=165, offs=27) -- 4961(line=166, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isasp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isasp: tmp34 = ats_selsin_mac(arg0, atslab_1) ; tmp33 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp34), atslab_s2cst_isasp) ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isasp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 4989(line=168, offs=27) -- 5064(line=169, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_isasp (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ // ATSlocal_void (tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_isasp: tmp36 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp36), atslab_s2cst_isasp) = arg1 ; return /* (tmp35) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_isasp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5092(line=171, offs=27) -- 5151(line=172, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscpy (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscpy: tmp38 = ats_selsin_mac(arg0, atslab_1) ; tmp37 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp38), atslab_s2cst_iscpy) ; return (tmp37) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscpy] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5179(line=174, offs=27) -- 5254(line=175, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_iscpy (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_iscpy: tmp40 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp40), atslab_s2cst_iscpy) = arg1 ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_iscpy] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5282(line=177, offs=27) -- 5341(line=178, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_islst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_islst: tmp42 = ats_selsin_mac(arg0, atslab_1) ; tmp41 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp42), atslab_s2cst_islst) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_islst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5369(line=180, offs=27) -- 5444(line=181, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_islst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_islst: tmp44 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp44), atslab_s2cst_islst) = arg1 ; return /* (tmp43) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_islst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5473(line=183, offs=28) -- 5533(line=184, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_arilst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_arilst: tmp46 = ats_selsin_mac(arg0, atslab_1) ; tmp45 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp46), atslab_s2cst_arilst) ; return (tmp45) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_arilst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5562(line=186, offs=28) -- 5622(line=187, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_argvar (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_argvar: tmp48 = ats_selsin_mac(arg0, atslab_1) ; tmp47 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp48), atslab_s2cst_argvar) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_argvar] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5651(line=189, offs=28) -- 5711(line=190, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst: tmp50 = ats_selsin_mac(arg0, atslab_1) ; tmp49 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp50), atslab_s2cst_conlst) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5740(line=192, offs=28) -- 5816(line=193, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst: tmp52 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp52), atslab_s2cst_conlst) = arg1 ; return /* (tmp51) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5863(line=197, offs=25) -- 5920(line=198, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_def (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_def: tmp54 = ats_selsin_mac(arg0, atslab_1) ; tmp53 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp54), atslab_s2cst_def) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_def] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 5946(line=200, offs=25) -- 6015(line=201, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def: tmp56 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp56), atslab_s2cst_def) = arg1 ; return /* (tmp55) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6062(line=205, offs=25) -- 6119(line=206, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sup (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sup: tmp58 = ats_selsin_mac(arg0, atslab_1) ; tmp57 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp58), atslab_s2cst_sup) ; return (tmp57) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6171(line=209, offs=25) -- 6288(line=213, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup: tmp60 = ats_selsin_mac(arg0, atslab_1) ; tmp61 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp60), atslab_s2cst_sup) ; tmp62 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp62, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp62, atslab_1, tmp61) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp60), atslab_s2cst_sup) = tmp62 ; return /* (tmp59) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6343(line=215, offs=28) -- 6403(line=216, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_supcls (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_supcls: tmp64 = ats_selsin_mac(arg0, atslab_1) ; tmp63 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp64), atslab_s2cst_supcls) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_supcls] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6432(line=219, offs=18) -- 6552(line=223, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_supcls (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_supcls: tmp66 = ats_selsin_mac(arg0, atslab_1) ; tmp67 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp66), atslab_s2cst_supcls) ; tmp68 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp68, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp68, atslab_1, tmp67) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp66), atslab_s2cst_supcls) = tmp68 ; return /* (tmp65) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_supcls] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6632(line=227, offs=29) -- 6693(line=228, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sVarset (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sVarset: tmp70 = ats_selsin_mac(arg0, atslab_1) ; tmp69 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp70), atslab_s2cst_sVarset) ; return (tmp69) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6723(line=230, offs=29) -- 6796(line=231, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_sVarset (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_sVarset: tmp72 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp72), atslab_s2cst_sVarset) = arg1 ; return /* (tmp71) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6824(line=233, offs=27) -- 6883(line=234, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp: tmp74 = ats_selsin_mac(arg0, atslab_1) ; tmp73 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp74), atslab_s2cst_stamp) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 6911(line=236, offs=27) -- 6986(line=237, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_stamp (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_stamp: tmp76 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp76), atslab_s2cst_stamp) = arg1 ; return /* (tmp75) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7012(line=239, offs=25) -- 7069(line=240, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_tag (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_tag: tmp78 = ats_selsin_mac(arg0, atslab_1) ; tmp77 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp78), atslab_s2cst_tag) ; return (tmp77) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_tag] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7095(line=242, offs=25) -- 7164(line=243, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_tag (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_tag: tmp80 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp80), atslab_s2cst_tag) = arg1 ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_tag] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7214(line=248, offs=3) -- 7265(line=248, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2cst_s2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2cst_s2cst: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst (arg0, arg1) ; tmp81 = atspre_ilt (tmp82, 0) ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2cst_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7294(line=250, offs=3) -- 7346(line=250, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2cst_s2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2cst_s2cst: tmp84 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst (arg0, arg1) ; tmp83 = atspre_ilte (tmp84, 0) ; return (tmp83) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2cst_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7375(line=253, offs=3) -- 7426(line=253, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp85) ; ATSlocal (ats_int_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst: tmp86 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst (arg0, arg1) ; tmp85 = atspre_ieq (tmp86, 0) ; return (tmp85) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7455(line=255, offs=3) -- 7507(line=255, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2cst_s2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp87) ; ATSlocal (ats_int_type, tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2cst_s2cst: tmp88 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst (arg0, arg1) ; tmp87 = atspre_ineq (tmp88, 0) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2cst_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7512(line=257, offs=4) -- 7811(line=267, offs=4) */ ATSstaticdec() ats_int_type _compare_s2cst_s2cst_36 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (atsopt_count_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (atsopt_count_type, tmp93) ; __ats_lab__compare_s2cst_s2cst_36: tmp90 = ats_selsin_mac(arg0, atslab_1) ; tmp91 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp90), atslab_s2cst_stamp) ; tmp92 = ats_selsin_mac(arg1, atslab_1) ; tmp93 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp92), atslab_s2cst_stamp) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp91, tmp93) ; return (tmp89) ; } /* end of [_compare_s2cst_s2cst_36] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 7876(line=270, offs=21) -- 7941(line=271, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp94) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst: tmp94 = _compare_s2cst_s2cst_36 (arg0, arg1) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2cst_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 8026(line=277, offs=19) -- 8129(line=280, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract: tmp96 = ats_selsin_mac(arg0, atslab_1) ; tmp97 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp96), atslab_s2cst_isabs) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp97 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp95 = ats_true_bool ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp97 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp95 = ats_false_bool ; break ; } while (0) ; return (tmp95) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 8185(line=283, offs=15) -- 8298(line=286, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_data (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_data: tmp99 = ats_selsin_mac(arg0, atslab_1) ; tmp100 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp99), atslab_s2cst_isabs) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp98 = ats_false_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp100 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp98 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp99), atslab_s2cst_iscon) ; break ; } while (0) ; return (tmp98) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_data] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 8376(line=290, offs=7) -- 8807(line=302, offs=6) */ ATSstaticdec() ats_bool_type aux_41 (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (atsopt_count_type, tmp104) ; ATSlocal (ats_bool_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_aux_41: tmp103 = ats_selsin_mac(arg0, atslab_1) ; tmp104 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp103), atslab_s2cst_stamp) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp104, arg1) ; if (tmp105) { tmp102 = ats_true_bool ; } else { tmp106 = ats_selsin_mac(arg0, atslab_1) ; tmp107 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp106), atslab_s2cst_sup) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp107 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_3, tmp107, atslab_0) ; arg0 = tmp108 ; arg1 = arg1 ; goto __ats_lab_aux_41 ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp107 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp102 = ats_false_bool ; break ; } while (0) ; } /* end of [if] */ return (tmp102) ; } /* end of [aux_41] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 8351(line=289, offs=16) -- 8958(line=308, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp101) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (atsopt_count_type, tmp110) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup: tmp109 = ats_selsin_mac(arg1, atslab_1) ; tmp110 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp109), atslab_s2cst_stamp) ; tmp101 = aux_41 (arg0, tmp110) ; return (tmp101) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 9015(line=311, offs=19) -- 9148(line=315, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike: tmp112 = ats_selsin_mac(arg0, atslab_1) ; tmp113 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp112), atslab_s2cst_islst) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp113 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp111 = ats_true_bool ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp113 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp111 = ats_false_bool ; break ; } while (0) ; return (tmp111) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 9208(line=318, offs=19) -- 9468(line=326, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular: tmp115 = ats_selsin_mac(arg0, atslab_1) ; tmp116 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, tmp115), atslab_s2cst_conlst) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (tmp116 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_10_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_4, tmp116, atslab_0) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (tmp117 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } tmp118 = ats_caselptrlab_mac(anairiats_sum_3, tmp117, atslab_1) ; if (tmp118 != (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp114 = ats_true_bool ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp114 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp116 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp114 = ats_false_bool ; break ; } while (0) ; return (tmp114) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 9592(line=333, offs=16) -- 10055(line=354, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_dat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_dat: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp121, arg3) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp120 = arg3 ; break ; } while (0) ; tmp122 = (ats_sum_ptr_type)0 ; tmp123 = (ats_sum_ptr_type)0 ; tmp124 = (ats_sum_ptr_type)0 ; tmp119 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (arg0, arg1, tmp120, tmp122, ats_true_bool, ats_false_bool, ats_false_bool, tmp123, arg4, tmp124) ; return (tmp119) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_dat] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 10205(line=362, offs=9) -- 10543(line=372, offs=8) */ ATSstaticdec() ats_ptr_type aux_46 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_aux_46: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp127 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp128 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp129 = aux_46 (tmp128, arg1) ; tmp130 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp127, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp130, tmp129) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp126 = arg1 ; break ; } while (0) ; return (tmp126) ; } /* end of [aux_46] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 10132(line=360, offs=3) -- 10855(line=387, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_cls (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_cls: tmp131 = aux_46 (arg2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; tmp132 = (ats_sum_ptr_type)0 ; tmp133 = (ats_sum_ptr_type)0 ; tmp134 = (ats_sum_ptr_type)0 ; tmp135 = (ats_sum_ptr_type)0 ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (arg0, arg1, tmp131, tmp132, ats_true_bool, ats_false_bool, ats_false_bool, tmp133, tmp134, tmp135) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_cls] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 10928(line=392, offs=14) -- 11004(line=393, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst: tmp137 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym (arg1) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp137) ; return /* (tmp136) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11053(line=396, offs=23) -- 11090(line=396, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; // ATSlocal_void (tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cst: tmp139 = atspre_stdout_get () ; tmp140 = ats_selsin_mac(tmp139, atslab_1) ; /* tmp141 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (tmp140, arg0) ; /* tmp138 = */ atspre_stdout_view_set () ; return /* (tmp138) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11113(line=397, offs=23) -- 11150(line=397, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; // ATSlocal_void (tmp145) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst: tmp143 = atspre_stderr_get () ; tmp144 = ats_selsin_mac(tmp143, atslab_1) ; /* tmp145 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (tmp144, arg0) ; /* tmp142 = */ atspre_stderr_view_set () ; return /* (tmp142) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11234(line=404, offs=7) -- 11592(line=416, offs=27) */ ATSstaticdec() ats_void_type aux_51 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_bool_type, tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_int_type, tmp153) ; __ats_lab_aux_51: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp149 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp151 = atspre_gt_int_int (arg2, 0) ; if (tmp151) { /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp148) ; tmp153 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp149 ; arg2 = tmp153 ; goto __ats_lab_aux_51 ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: break ; } while (0) ; return /* (tmp147) */ ; } /* end of [aux_51] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11205(line=403, offs=7) -- 11662(line=420, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp146) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst: /* tmp146 = */ aux_51 (arg0, arg1, 0) ; return /* (tmp146) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11717(line=422, offs=26) -- 11759(line=422, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cstlst: tmp155 = atspre_stdout_get () ; tmp156 = ats_selsin_mac(tmp155, atslab_1) ; /* tmp157 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst (tmp156, arg0) ; /* tmp154 = */ atspre_stdout_view_set () ; return /* (tmp154) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2cstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_scst.dats: 11785(line=423, offs=26) -- 11827(line=423, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; // ATSlocal_void (tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cstlst: tmp159 = atspre_stderr_get () ; tmp160 = ats_selsin_mac(tmp159, atslab_1) ; /* tmp161 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cstlst (tmp160, arg0) ; /* tmp158 = */ atspre_stderr_view_set () ; return /* (tmp158) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cstlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_scst_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_trans_dats.c0000664000175000017500000131033012223166157022436 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_13 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_19 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_20 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_hilab_loc ; ats_ptr_type atslab_hilab_node ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_23 ; typedef struct { anairiats_rec_23 atslab_0 ; } anairiats_sum_24 ; typedef struct { ats_ptr_type atslab_hifundec_loc ; ats_ptr_type atslab_hifundec_var ; ats_ptr_type atslab_hifundec_def ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_hivaldec_loc ; ats_ptr_type atslab_hivaldec_pat ; ats_ptr_type atslab_hivaldec_def ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_hivardec_loc ; ats_int_type atslab_hivardec_knd ; ats_ptr_type atslab_hivardec_ptr ; ats_ptr_type atslab_hivardec_ini ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_hiimpdec_loc ; ats_ptr_type atslab_hiimpdec_cst ; ats_int_type atslab_hiimpdec_tmp ; ats_ptr_type atslab_hiimpdec_decarg ; ats_ptr_type atslab_hiimpdec_tmparg ; ats_ptr_type atslab_hiimpdec_def ; ats_ptr_type atslab_hiimpdec_cstset ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_hidec_loc ; ats_ptr_type atslab_hidec_node ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_s2aspdec_fil ; ats_ptr_type atslab_s2aspdec_loc ; ats_ptr_type atslab_s2aspdec_cst ; ats_ptr_type atslab_s2aspdec_def ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_hiimpdec_prf_loc ; ats_ptr_type atslab_hiimpdec_prf_cst ; ats_ptr_type atslab_hiimpdec_prf_cstset ; } anairiats_rec_31 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDval_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrinit_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrpsz_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_ptr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcaseof_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcastfn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEdynload_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEextval_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloatsp_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfreeat_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEif_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEintsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_delay_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_ldelay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElet_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloop_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloopexn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_ptr_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_var_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEraise_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErefarg_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsizeof_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtrywith_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlist_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDsaspdec_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdcstdec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdatdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDexndec_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextval_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextern_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDfundecs_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_rec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvardecs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_prf_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlocal_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDstaload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdynload_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKbool_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKcon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKexn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKfloat_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTcaseof_fail_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTfunarg_fail_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTraise_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTmark_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTnil_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_tailrecur) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_kind) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_nil) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_cons) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_cltype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_hipat_set_asvar) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_lam) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_typ) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_var_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_prfck) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_lev) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funlab_set_tailjoined) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarlst_make) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argref) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argtmpref) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_castfn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_clo) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cstsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_var_offs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_cond) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_beg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_end) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_heap) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_stack) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_arr) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_clo) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call_tail) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_clo) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_fun) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_val) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_partval) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_extval) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr_offs) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loop) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn) (ats_ref_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_arg) (ats_ref_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_force) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_rec) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_raise) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon_ptr) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_var_offs) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_switch) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_trywith) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match) (ats_ref_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_cst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_var) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst) (ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_tailjoin_funentrylst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst) (ats_ref_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynctx_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_the_dyncstset_add_if) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_add) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_add) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_top) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_push) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_clo) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_fun) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_val) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_get_free) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make_dynctx) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_rec) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_sum) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_dec) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__sasp__dynctx_push_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__sasp__dynctx_mark_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__sasp__dynctx_vt = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__sasp__envmap_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTmark_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTnil_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_ccomp_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_ptr_type bst_search_068_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01951_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type bst_size_040_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_079_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01949_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ref_make_elt_04328_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type dynctx_nil_13 () ; static ats_ptr_type bst_join_random_088_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_remove_random_0102_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type map_remove_01950_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type the_dynctx_del_16 (ats_ptr_type arg0) ; static ats_ptr_type aux_21 (ats_ptr_type arg0) ; static ats_void_type aux_23 (ats_ptr_type arg0) ; static ats_void_type bst_free_036_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type map_free_01947_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type map_foreach_inf_01954_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_free_34 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_36 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type auxlst_37 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type auxlst_37_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type auxlst_37_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_39 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_clo_ptr_type aux_39_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type aux_39_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type auxlst_40 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_clo_ptr_type auxlst_40_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type auxlst_40_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_43 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_43_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type aux_43_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_match_rec_42 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_var_45 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) ; static ats_clo_ptr_type aux_var_45_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_var_45_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) ; static ats_void_type aux_pat_46 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type aux_pat_46_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_pat_46_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type auxlst_pat_47 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type auxlst_pat_47_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type auxlst_pat_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_match_sum_44 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_void_type aux_var_49 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type hiexp_refarg_tr_50 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type hiexplst_refarg_tr_51 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_exp_assgn_ptr_53 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type ccomp_exp_assgn_var_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type ccomp_exp_freeat_55 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type funarg_valprim_make_56 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_patck_58 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_match_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_funarg_57 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_61 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_62 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_62_closure_make (ats_int_type env0) ; static ats_void_type aux_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type aux_63 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_63_closure_make (ats_int_type env0) ; static ats_void_type aux_63_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type ccomp_exp_lam_64 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type ccomp_exp_fixdef_65 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ccomp_exp_lazy_delay_66 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type ccomp_exp_lazy_ldelay_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ccomp_exp_ptrof_ptr_68 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ccomp_exp_ptrof_var_69 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ccomp_exp_refarg_70 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_72 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ccomp_exp_seq_71 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_exp_loop_74 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_void_type instrlst_add_freeptr_79 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type valprim_mov_81 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux1_arg_82 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux2_arg_83 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux1_mov_84 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type aux2_mov_85 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type tailcall_arg_move_80 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type ccomp_exp_app_tmpvar_86 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_void_type aux_88 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_88_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_88_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type ccomp_exp_assgn_arr_87 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_exp_arrinit_tmpvar_89 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_void_type ccomp_exp_arrpsz_tmpvar_90 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type ccomp_exp_lst_tmpvar_rest_91 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9, ats_ptr_type arg10, ats_ptr_type arg11, ats_ptr_type arg12) ; static ats_void_type ccomp_exp_lst_tmpvar_92 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_void_type aux_94 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_exp_seq_tmpvar_93 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2var_typ_ptr_get_98 (ats_ptr_type arg0) ; static ats_ptr_type ccomp_fundeclst_init_99 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_push_101 (ats_ptr_type arg0) ; static ats_void_type auxlst_push_102 (ats_ptr_type arg0) ; static ats_ptr_type aux_ccomp_103 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxlst_ccomp_104 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_fntdeclst_main_100 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type ccomp_fundeclst_main_105 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_107 (ats_int_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_107_closure_make (ats_int_type env0, ats_ptr_type env1) ; static ats_void_type aux_107_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_valdeclst_106 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux1_109 (ats_int_type env0, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux1_109_closure_make (ats_int_type env0) ; static ats_ptr_type aux1_109_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux2_110 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type ccomp_valdeclst_rec_108 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type ccomp_vardec_sta_111 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_bool_type hiexp_is_laminit_112 (ats_ptr_type arg0) ; static ats_void_type aux_laminit_114 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_lamfixinit_115 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ccomp_vardec_dyn_113 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type ccomp_vardec_116 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_118 (ats_int_type env0, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_118_closure_make (ats_int_type env0) ; static ats_void_type aux_118_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_vardeclst_117 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_120 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type ccomp_impdec_119 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type f_122 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type ccomp_impdec_prfck_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp88) ; ATSstatic (ats_ptr_type, statmp89) ; ATSstatic (ats_ptr_type, statmp90) ; ATSstatic (ats_ptr_type, statmp91) ; ATSstatic (ats_ptr_type, statmp92) ; ATSstatic (ats_ptr_type, statmp93) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 2237(line=73, offs=4) -- 2325(line=74, offs=52) */ ATSstaticdec() ats_void_type prerr_loc_ccomp_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_ccomp_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_ccomp_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 2358(line=77, offs=4) -- 2418(line=77, offs=64) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_trans)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 2422(line=78, offs=4) -- 2535(line=80, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_ccomp_trans)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_068_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_int_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_0_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp14 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp15 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp16 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp12) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp16 != -1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp17 = ats_ptrget_mac(ats_ptr_type, tmp14) ; arg0 = tmp17 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp16 != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp18 = ats_ptrget_mac(ats_ptr_type, tmp15) ; arg0 = tmp18 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp16 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp11 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp11, atslab_0, tmp13) ; break ; } while (0) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: tmp11 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp11) ; } /* end of [bst_search_068_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01951_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_map_search_01951_ats_ptr_type_2cats_ptr_type: // tmp9 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp10 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp19 = ats_ptrget_mac(ats_ptr_type, tmp10) ; tmp8 = bst_search_068_ats_ptr_type_2cats_ptr_type (tmp19, arg1, tmp9) ; return (tmp8) ; } /* end of [map_search_01951_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 2790(line=94, offs=13) -- 2916(line=99, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__envmap_find (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__envmap_find: tmp6 = atspre_ref_get_view_ptr (arg0) ; tmp7 = ats_selsin_mac(tmp6, atslab_1) ; tmp20 = ats_ptrget_mac(ats_ptr_type, tmp7) ; tmp5 = map_search_01951_ats_ptr_type_2cats_ptr_type (tmp20, arg1) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__envmap_find] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_040_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_int_type, tmp52) ; __ats_lab_bst_size_040_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp51 = tmp52 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp51 = 0 ; break ; } while (0) ; return (tmp51) ; } /* end of [bst_size_040_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_int_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_int_type, tmp49) ; ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_int_type, tmp55) ; ATSlocal (ats_int_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_int_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_6_1: tmp38 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp40 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp41 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp43 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp39) ; tmp42 = atspre_ilte (tmp43, 0) ; if (tmp42) { tmp45 = ats_ptrget_mac(ats_ptr_type, tmp40) ; tmp44 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (tmp45, arg1, arg2, arg3) ; // if (tmp44 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp46 = &ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_0) ; tmp47 = &ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_3) ; tmp48 = &ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_4) ; tmp49 = ats_ptrget_mac(ats_int_type, tmp38) ; tmp53 = ats_ptrget_mac(ats_ptr_type, tmp47) ; tmp50 = bst_size_040_ats_ptr_type_2cats_ptr_type (tmp53) ; tmp54 = ats_ptrget_mac(ats_ptr_type, tmp48) ; ats_ptrget_mac(ats_ptr_type, tmp40) = tmp54 ; tmp55 = atspre_isub (tmp49, tmp50) ; ats_ptrget_mac(ats_int_type, tmp38) = tmp55 ; ats_ptrget_mac(ats_ptr_type, tmp48) = arg0 ; tmp56 = atspre_iadd (tmp49, 1) ; ats_ptrget_mac(ats_int_type, tmp46) = tmp56 ; tmp37 = tmp44 ; } else { tmp58 = ats_ptrget_mac(ats_ptr_type, tmp41) ; tmp57 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (tmp58, arg1, arg2, arg3) ; // if (tmp57 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp59 = &ats_caselptrlab_mac(anairiats_sum_2, tmp57, atslab_0) ; tmp60 = &ats_caselptrlab_mac(anairiats_sum_2, tmp57, atslab_3) ; tmp61 = &ats_caselptrlab_mac(anairiats_sum_2, tmp57, atslab_4) ; tmp62 = ats_ptrget_mac(ats_int_type, tmp38) ; tmp64 = ats_ptrget_mac(ats_ptr_type, tmp61) ; tmp63 = bst_size_040_ats_ptr_type_2cats_ptr_type (tmp64) ; tmp65 = ats_ptrget_mac(ats_ptr_type, tmp60) ; ats_ptrget_mac(ats_ptr_type, tmp41) = tmp65 ; tmp66 = atspre_isub (tmp62, tmp63) ; ats_ptrget_mac(ats_int_type, tmp38) = tmp66 ; ats_ptrget_mac(ats_ptr_type, tmp60) = arg0 ; tmp67 = atspre_iadd (tmp62, 1) ; ats_ptrget_mac(ats_int_type, tmp59) = tmp67 ; tmp37 = tmp57 ; } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp68 = (ats_sum_ptr_type)0 ; tmp69 = (ats_sum_ptr_type)0 ; tmp37 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_3, tmp68) ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_4, tmp69) ; break ; } while (0) ; return (tmp37) ; } /* end of [bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_079_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_bool_type, tmp35) ; ATSlocal (ats_int_type, tmp36) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_int_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; __ats_lab_bst_insert_random_079_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_5_1: tmp31 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp33 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp34 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp36 = ats_ptrget_mac(ats_int_type, tmp31) ; tmp35 = atsopt_map_lin_dice (1, tmp36) ; if (tmp35) { tmp30 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp71 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp32) ; tmp70 = atspre_ilte (tmp71, 0) ; if (tmp70) { tmp73 = ats_ptrget_mac(ats_ptr_type, tmp33) ; tmp72 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp73, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp33) = tmp72 ; tmp75 = ats_ptrget_mac(ats_int_type, tmp31) ; tmp74 = atspre_iadd (tmp75, 1) ; ats_ptrget_mac(ats_int_type, tmp31) = tmp74 ; tmp30 = arg0 ; } else { tmp77 = ats_ptrget_mac(ats_ptr_type, tmp34) ; tmp76 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp77, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp34) = tmp76 ; tmp79 = ats_ptrget_mac(ats_int_type, tmp31) ; tmp78 = atspre_iadd (tmp79, 1) ; ats_ptrget_mac(ats_int_type, tmp31) = tmp78 ; tmp30 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp80 = (ats_sum_ptr_type)0 ; tmp81 = (ats_sum_ptr_type)0 ; tmp30 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp30, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, tmp30, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp30, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp30, atslab_3, tmp80) ; ats_selptrset_mac(anairiats_sum_2, tmp30, atslab_4, tmp81) ; break ; } while (0) ; return (tmp30) ; } /* end of [bst_insert_random_079_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01949_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp82) ; __ats_lab_map_insert_01949_ats_ptr_type_2cats_ptr_type: // tmp27 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp28 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp82 = ats_ptrget_mac(ats_ptr_type, tmp28) ; tmp29 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp82, arg1, arg2, tmp27) ; ats_ptrget_mac(ats_ptr_type, tmp28) = tmp29 ; return /* (tmp26) */ ; } /* end of [map_insert_01949_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 3146(line=106, offs=6) -- 3371(line=110, offs=8) */ ATSstaticdec() ats_void_type f_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp23) ; ATSlocal (ats_bool_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_ptr_type, tmp83) ; __ats_lab_f_7: tmp25 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (arg0) ; tmp24 = atspre_gt_int_int (tmp25, 0) ; if (tmp24) { tmp83 = ats_ptrget_mac(ats_ptr_type, arg2) ; /* tmp23 = */ map_insert_01949_ats_ptr_type_2cats_ptr_type (tmp83, arg0, arg1) ; } else { /* empty */ } /* end of [if] */ return /* (tmp23) */ ; } /* end of [f_7] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_04328_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ref_make_elt_04328_ats_ptr_type: /* ats_ptr_type tmp86 ; */ tmp86 = arg0 ; tmp85 = atspre_ref_make_elt_tsz ((&tmp86), sizeof(ats_ptr_type)) ; return (tmp85) ; } /* end of [ref_make_elt_04328_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 2971(line=102, offs=20) -- 3518(line=115, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make_dynctx (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make_dynctx: /* ats_ptr_type tmp22 ; */ tmp22 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) ; /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynctx_foreach_main (arg0, &f_7, (&tmp22)) ; tmp21 = ref_make_elt_04328_ats_ptr_type (tmp22) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make_dynctx] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 3726(line=129, offs=4) -- 3789(line=130, offs=38) */ ATSstaticdec() ats_ptr_type dynctx_nil_13 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; __ats_lab_dynctx_nil_13: tmp87 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) ; return (tmp87) ; } /* end of [dynctx_nil_13] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 4256(line=150, offs=16) -- 4619(line=165, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add: tmp95 = atspre_ref_get_view_ptr (statmp88) ; tmp96 = ats_selsin_mac(tmp95, atslab_1) ; tmp98 = ats_ptrget_mac(ats_ptr_type, tmp96) ; /* tmp97 = */ map_insert_01949_ats_ptr_type_2cats_ptr_type (tmp98, arg0, arg1) ; tmp99 = atspre_ref_get_view_ptr (statmp92) ; tmp100 = ats_selsin_mac(tmp99, atslab_1) ; tmp102 = ats_ptrget_mac(ats_ptr_type, tmp100) ; tmp101 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp101)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp101, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp101, atslab_1, tmp102) ; ats_ptrget_mac(ats_ptr_type, tmp100) = tmp101 ; return /* (tmp94) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 4678(line=170, offs=17) -- 4888(line=179, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () { /* local vardec */ // ATSlocal_void (tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark: tmp104 = atspre_ref_get_view_ptr (statmp92) ; tmp105 = ats_selsin_mac(tmp104, atslab_1) ; tmp107 = ats_ptrget_mac(ats_ptr_type, tmp105) ; tmp106 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp106)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp106, atslab_0, tmp107) ; ats_ptrget_mac(ats_ptr_type, tmp105) = tmp106 ; return /* (tmp103) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 5380(line=174, offs=25) -- 6039(line=193, offs=4) */ ATSstaticdec() ats_ptr_type bst_join_random_088_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_bool_type, tmp146) ; ATSlocal (ats_int_type, tmp147) ; ATSlocal (ats_int_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_bst_join_random_088_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_15_1: tmp139 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp140 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp141 = &ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp142 = &ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_3) ; tmp144 = ats_ptrget_mac(ats_int_type, tmp139) ; tmp145 = ats_ptrget_mac(ats_int_type, tmp141) ; tmp143 = atspre_iadd (tmp144, tmp145) ; tmp147 = ats_ptrget_mac(ats_int_type, tmp139) ; tmp148 = ats_ptrget_mac(ats_int_type, tmp141) ; tmp146 = atsopt_map_lin_dice (tmp147, tmp148) ; if (tmp146) { tmp150 = ats_ptrget_mac(ats_ptr_type, tmp140) ; tmp149 = bst_join_random_088_ats_ptr_type_2cats_ptr_type (tmp150, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp140) = tmp149 ; ats_ptrget_mac(ats_int_type, tmp139) = tmp143 ; tmp138 = arg0 ; } else { tmp152 = ats_ptrget_mac(ats_ptr_type, tmp142) ; tmp151 = bst_join_random_088_ats_ptr_type_2cats_ptr_type (arg0, tmp152) ; ats_ptrget_mac(ats_ptr_type, tmp142) = tmp151 ; ats_ptrget_mac(ats_int_type, tmp141) = tmp143 ; tmp138 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp138 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp138 = arg1 ; break ; } while (0) ; return (tmp138) ; } /* end of [bst_join_random_088_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 6466(line=208, offs=30) -- 7610(line=243, offs=4) */ ATSstaticdec() ats_ptr_type bst_remove_random_0102_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_int_type, tmp134) ; ATSlocal (ats_int_type, tmp135) ; ATSlocal (ats_int_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_bst_remove_random_0102_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_11_1: tmp119 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp120 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp121 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp122 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp123 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp124 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg4) (arg1, tmp120) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp124 != -1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp126 = ats_ptrget_mac(ats_ptr_type, tmp122) ; tmp125 = bst_remove_random_0102_ats_ptr_type_2cats_ptr_type (tmp126, arg1, arg2, arg3, arg4) ; tmp127 = ats_selsin_mac(tmp125, atslab_2) ; tmp129 = ats_ptrget_mac(ats_int_type, tmp119) ; tmp130 = ats_ptrget_mac(ats_int_type, arg2) ; tmp128 = atspre_isub (tmp129, tmp130) ; ats_ptrget_mac(ats_int_type, tmp119) = tmp128 ; ats_ptrget_mac(ats_ptr_type, tmp122) = tmp127 ; tmp118 = arg0 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (tmp124 != 1) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp132 = ats_ptrget_mac(ats_ptr_type, tmp123) ; tmp131 = bst_remove_random_0102_ats_ptr_type_2cats_ptr_type (tmp132, arg1, arg2, arg3, arg4) ; tmp133 = ats_selsin_mac(tmp131, atslab_2) ; tmp135 = ats_ptrget_mac(ats_int_type, tmp119) ; tmp136 = ats_ptrget_mac(ats_int_type, arg2) ; tmp134 = atspre_isub (tmp135, tmp136) ; ats_ptrget_mac(ats_int_type, tmp119) = tmp134 ; ats_ptrget_mac(ats_ptr_type, tmp123) = tmp133 ; tmp118 = arg0 ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (tmp124 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp153 = ats_ptrget_mac(ats_ptr_type, tmp122) ; tmp154 = ats_ptrget_mac(ats_ptr_type, tmp123) ; tmp137 = bst_join_random_088_ats_ptr_type_2cats_ptr_type (tmp153, tmp154) ; ats_ptrget_mac(ats_int_type, arg2) = 1 ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp155, atslab_0, tmp121) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp155 ; ATS_FREE(arg0) ; tmp118 = tmp137 ; break ; } while (0) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: ats_ptrget_mac(ats_int_type, arg2) = 0 ; tmp156 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp156 ; tmp118 = arg0 ; break ; } while (0) ; return (tmp118) ; } /* end of [bst_remove_random_0102_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10217(line=356, offs=12) -- 10550(line=365, offs=4) */ ATSstaticdec() ats_ptr_type map_remove_01950_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_int_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_map_remove_01950_ats_ptr_type_2cats_ptr_type: // tmp113 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp114 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* ats_int_type tmp115 ; */ /* ats_ptr_type tmp116 ; */ tmp157 = ats_ptrget_mac(ats_ptr_type, tmp114) ; tmp117 = bst_remove_random_0102_ats_ptr_type_2cats_ptr_type (tmp157, arg1, (&tmp115), (&tmp116), tmp113) ; tmp158 = ats_selsin_mac(tmp117, atslab_2) ; ats_ptrget_mac(ats_ptr_type, tmp114) = tmp158 ; tmp112 = tmp116 ; return (tmp112) ; } /* end of [map_remove_01950_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 4925(line=183, offs=4) -- 5349(line=197, offs=4) */ ATSstaticdec() ats_void_type the_dynctx_del_16 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; __ats_lab_the_dynctx_del_16: tmp109 = atspre_ref_get_view_ptr (statmp88) ; tmp110 = ats_selsin_mac(tmp109, atslab_1) ; tmp159 = ats_ptrget_mac(ats_ptr_type, tmp110) ; tmp111 = map_remove_01950_ats_ptr_type_2cats_ptr_type (tmp159, arg0) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp111 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: ATS_FREE(tmp111) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (tmp111 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: /* tmp160 = */ prerr_interror_1 () ; /* tmp161 = */ atspre_prerr_string (ATSstrcst(": the_dynctx_del: d2v = ")) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg0) ; /* tmp163 = */ atspre_prerr_newline () ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp108) */ ; } /* end of [the_dynctx_del_16] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 5467(line=202, offs=7) -- 5823(line=210, offs=6) */ ATSstaticdec() ats_ptr_type aux_21 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; // ATSlocal_void (tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; // ATSlocal_void (tmp172) ; __ats_lab_aux_21: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp167 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp168 = */ the_dynctx_del_16 (tmp166) ; arg0 = tmp167 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp165 = tmp169 ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: /* tmp170 = */ prerr_interror_1 () ; /* tmp171 = */ atspre_prerr_string (ATSstrcst(": the_dynctx_unmark: aux")) ; /* tmp172 = */ atspre_prerr_newline () ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp165) ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 5406(line=200, offs=19) -- 6017(line=219, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () { /* local vardec */ // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark: tmp173 = atspre_ref_get_view_ptr (statmp92) ; tmp174 = ats_selsin_mac(tmp173, atslab_1) ; tmp176 = ats_ptrget_mac(ats_ptr_type, tmp174) ; tmp175 = aux_21 (tmp176) ; ats_ptrget_mac(ats_ptr_type, tmp174) = tmp175 ; return /* (tmp164) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 6101(line=225, offs=7) -- 6292(line=229, offs=6) */ ATSstaticdec() ats_void_type aux_23 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; // ATSlocal_void (tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; __ats_lab_aux_23: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp180 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp181 = */ the_dynctx_del_16 (tmp179) ; arg0 = tmp180 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; ATS_FREE(arg0) ; arg0 = tmp182 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: break ; } while (0) ; return /* (tmp178) */ ; } /* end of [aux_23] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 6079(line=224, offs=17) -- 6498(line=237, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_free () { /* local vardec */ // ATSlocal_void (tmp177) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; // ATSlocal_void (tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_free: tmp183 = atspre_ref_get_view_ptr (statmp92) ; tmp184 = ats_selsin_mac(tmp183, atslab_1) ; tmp186 = ats_ptrget_mac(ats_ptr_type, tmp184) ; /* tmp185 = */ aux_23 (tmp186) ; tmp187 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTnil_2) ; ats_ptrget_mac(ats_ptr_type, tmp184) = tmp187 ; return /* (tmp177) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 6561(line=242, offs=17) -- 6981(line=256, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; // ATSlocal_void (tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find: tmp189 = atspre_ref_get_view_ptr (statmp88) ; tmp190 = ats_selsin_mac(tmp189, atslab_1) ; tmp192 = ats_ptrget_mac(ats_ptr_type, tmp190) ; tmp191 = map_search_01951_ats_ptr_type_2cats_ptr_type (tmp192, arg0) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp191 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp193 = ats_caselptrlab_mac(anairiats_sum_3, tmp191, atslab_0) ; ATS_FREE(tmp191) ; tmp188 = tmp193 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp191 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp195 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc (arg0) ; /* tmp194 = */ prerr_loc_interror_2 (tmp195) ; /* tmp196 = */ atspre_prerr_string (ATSstrcst(": the_dynctx_find: d2v = ")) ; /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg0) ; /* tmp198 = */ atspre_prerr_newline () ; /* tmp188 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_036_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; // ATSlocal_void (tmp221) ; __ats_lab_bst_free_036_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp219 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp221 = */ bst_free_036_ats_ptr_type_2cats_ptr_type (tmp219) ; arg0 = tmp220 ; goto __ats_lab_bst_free_036_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: break ; } while (0) ; return /* (tmp218) */ ; } /* end of [bst_free_036_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_01947_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; __ats_lab_map_free_01947_ats_ptr_type_2cats_ptr_type: // tmp217 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp216 = */ bst_free_036_ats_ptr_type_2cats_ptr_type (tmp217) ; return /* (tmp216) */ ; } /* end of [map_free_01947_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 7043(line=261, offs=16) -- 7786(line=282, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_pop () { /* local vardec */ // ATSlocal_void (tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_bool_type, tmp208) ; // ATSlocal_void (tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; // ATSlocal_void (tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; // ATSlocal_void (tmp215) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_pop: /* ats_int_type tmp200 ; */ tmp200 = 0 ; tmp201 = atspre_ref_get_view_ptr (statmp90) ; tmp202 = ats_selsin_mac(tmp201, atslab_1) ; tmp204 = ats_ptrget_mac(ats_ptr_type, tmp202) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp204 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_1, tmp204, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_1, tmp204, atslab_1) ; ATS_FREE(tmp204) ; ats_ptrget_mac(ats_ptr_type, tmp202) = tmp206 ; tmp203 = tmp205 ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (tmp204 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp200 = 1 ; tmp203 = dynctx_nil_13 () ; break ; } while (0) ; tmp208 = atspre_gt_int_int (tmp200, 0) ; if (tmp208) { /* tmp209 = */ prerr_interror_1 () ; /* tmp210 = */ atspre_prerr_string (ATSstrcst(": the_dynctx_pop")) ; /* tmp211 = */ atspre_prerr_newline () ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp212 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; tmp213 = atspre_ref_get_view_ptr (statmp88) ; tmp214 = ats_selsin_mac(tmp213, atslab_1) ; tmp222 = ats_ptrget_mac(ats_ptr_type, tmp214) ; /* tmp215 = */ map_free_01947_ats_ptr_type_2cats_ptr_type (tmp222) ; ats_ptrget_mac(ats_ptr_type, tmp214) = tmp203 ; return /* (tmp199) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 7841(line=285, offs=17) -- 8175(line=298, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_push () { /* local vardec */ // ATSlocal_void (tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_push: tmp224 = atspre_ref_get_view_ptr (statmp88) ; tmp225 = ats_selsin_mac(tmp224, atslab_1) ; tmp226 = ats_ptrget_mac(ats_ptr_type, tmp225) ; tmp227 = dynctx_nil_13 () ; ats_ptrget_mac(ats_ptr_type, tmp225) = tmp227 ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp229 = ats_selsin_mac(tmp228, atslab_1) */ ; tmp230 = atspre_ref_get_view_ptr (statmp90) ; tmp231 = ats_selsin_mac(tmp230, atslab_1) ; tmp233 = ats_ptrget_mac(ats_ptr_type, tmp231) ; tmp232 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp232, atslab_0, tmp226) ; ats_selptrset_mac(anairiats_sum_1, tmp232, atslab_1, tmp233) ; ats_ptrget_mac(ats_ptr_type, tmp231) = tmp232 ; return /* (tmp223) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_push] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8937(line=300, offs=25) -- 9308(line=314, offs=4) */ ATSstaticdec() ats_void_type bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; __ats_lab_bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp238 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp239 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp240 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp241 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp243 = ats_ptrget_mac(ats_ptr_type, tmp240) ; /* tmp242 = */ bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type (tmp243, arg1, arg2) ; /* tmp244 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type, ats_ptr_type))arg1) (tmp238, tmp239, arg2) ; tmp245 = ats_ptrget_mac(ats_ptr_type, tmp241) ; arg0 = tmp245 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: break ; } while (0) ; return /* (tmp237) */ ; } /* end of [bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 11800(line=406, offs=17) -- 11939(line=411, offs=4) */ ATSstaticdec() ats_void_type map_foreach_inf_01954_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp246) ; __ats_lab_map_foreach_inf_01954_ats_ptr_type_2cats_ptr_type: // tmp236 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp246 = ats_ptrget_mac(ats_ptr_type, tmp236) ; /* tmp235 = */ bst_foreach_inf_0143_ats_ptr_type_2cats_ptr_type (tmp246, arg1, arg2) ; return /* (tmp235) */ ; } /* end of [map_foreach_inf_01954_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 8241(line=304, offs=3) -- 8301(line=304, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynctx_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynctx_foreach_main: /* tmp234 = */ map_foreach_inf_01954_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2) ; return /* (tmp234) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynctx_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 8378(line=310, offs=13) -- 8508(line=315, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make () { /* local vardec */ ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make: tmp248 = atspre_ref_get_view_ptr (statmp88) ; tmp249 = ats_selsin_mac(tmp248, atslab_1) ; tmp250 = ats_ptrget_mac(ats_ptr_type, tmp249) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make_dynctx (tmp250) ; return (tmp247) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 8637(line=323, offs=7) -- 8917(line=330, offs=6) */ ATSstaticdec() ats_void_type aux_free_34 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; // ATSlocal_void (tmp255) ; __ats_lab_aux_free_34: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; ATS_FREE(arg2) ; /* tmp255 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr (arg0, arg1, tmp253) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp254 ; goto __ats_lab_aux_free_34 ; // tail call break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; return /* (tmp252) */ ; } /* end of [aux_free_34] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 8614(line=322, offs=27) -- 8995(line=333, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp251) ; ATSlocal (ats_ptr_type, tmp256) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free: tmp256 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_get_free () ; /* tmp251 = */ aux_free_34 (arg0, arg1, tmp256) ; return /* (tmp251) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 9451(line=359, offs=7) -- 10463(line=388, offs=6) */ ATSstaticdec() ats_void_type aux_36 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; // ATSlocal_void (tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; // ATSlocal_void (tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; // ATSlocal_void (tmp278) ; __ats_lab_aux_36: tmp259 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_loc) ; tmp260 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_node) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp260)->tag != 0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp261 = ats_caselptrlab_mac(anairiats_sum_4, tmp260, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp261 ; goto __ats_lab_aux_36 ; // tail call break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp260)->tag != 1) { goto __ats_lab_40_0 ; } __ats_lab_39_1: break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp260)->tag != 2) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_7, tmp260, atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp262 ; goto __ats_lab_aux_36 ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp260)->tag != 13) { goto __ats_lab_42_0 ; } __ats_lab_41_1: break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp264 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_asvar) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp264 != (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp265 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (tmp259) ; tmp267 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp267, atslab_0, tmp265) ; /* tmp266 = */ atsopt_hipat_set_asvar (arg2, tmp267) ; tmp263 = tmp265 ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (tmp264 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp268 = ats_caselptrlab_mac(anairiats_sum_3, tmp264, atslab_0) ; tmp263 = tmp268 ; break ; } while (0) ; tmp270 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_typ) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp270) ; tmp271 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp269) ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp272)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_1, env1) ; tmp274 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp274, atslab_0, tmp272) ; tmp275 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp274), atslab_1) ; tmp276 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp275) = tmp276 ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select (arg0, tmp259, tmp271, env0, tmp274) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp271) ; /* tmp278 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp263, tmp277) ; /* tmp258 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp277, arg2, env2) ; break ; } while (0) ; return /* (tmp258) */ ; } /* end of [aux_36] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_36_closure_type ; ats_void_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { aux_36 (((aux_36_closure_type*)cloptr)->closure_env_0, ((aux_36_closure_type*)cloptr)->closure_env_1, ((aux_36_closure_type*)cloptr)->closure_env_2, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_36_closure_init (aux_36_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_36_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_36_closure_type *p_clo = ATS_MALLOC(sizeof(aux_36_closure_type)) ; aux_36_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 10486(line=389, offs=7) -- 10781(line=396, offs=6) */ ATSstaticdec() ats_void_type auxlst_37 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; // ATSlocal_void (tmp283) ; __ats_lab_auxlst_37: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; /* tmp283 = */ aux_36 (env0, env1, env2, arg0, tmp280, tmp281) ; arg0 = arg0 ; arg1 = tmp282 ; goto __ats_lab_auxlst_37 ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: break ; } while (0) ; return /* (tmp279) */ ; } /* end of [auxlst_37] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } auxlst_37_closure_type ; ats_void_type auxlst_37_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { auxlst_37 (((auxlst_37_closure_type*)cloptr)->closure_env_0, ((auxlst_37_closure_type*)cloptr)->closure_env_1, ((auxlst_37_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_37_closure_init (auxlst_37_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_37_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_37_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { auxlst_37_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_37_closure_type)) ; auxlst_37_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 9403(line=358, offs=3) -- 10829(line=399, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_rec (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp257) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_rec: /* tmp257 = */ auxlst_37 (arg1, arg3, arg4, arg0, arg2) ; return /* (tmp257) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 10948(line=405, offs=7) -- 11903(line=431, offs=6) */ ATSstaticdec() ats_void_type aux_39 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; // ATSlocal_void (tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; // ATSlocal_void (tmp301) ; __ats_lab_aux_39: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hipat_loc) ; tmp287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp287)->tag != 0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_4, tmp287, atslab_0) ; arg0 = arg0 ; arg1 = tmp288 ; arg2 = arg2 ; goto __ats_lab_aux_39 ; // tail call break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp287)->tag != 1) { goto __ats_lab_49_0 ; } __ats_lab_48_1: break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp287)->tag != 2) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp289 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_2) ; arg0 = arg0 ; arg1 = tmp289 ; arg2 = arg2 ; goto __ats_lab_aux_39 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp287)->tag != 13) { goto __ats_lab_51_0 ; } __ats_lab_50_1: break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp291 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hipat_asvar) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp291 != (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp292 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (tmp286) ; tmp294 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp294, atslab_0, tmp292) ; /* tmp293 = */ atsopt_hipat_set_asvar (arg1, tmp294) ; tmp290 = tmp292 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (tmp291 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp295 = ats_caselptrlab_mac(anairiats_sum_3, tmp291, atslab_0) ; tmp290 = tmp295 ; break ; } while (0) ; tmp297 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hipat_typ) ; tmp296 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp297) ; tmp298 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp296) ; /* tmp299 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon (arg0, tmp286, tmp298, env0, env1, arg2) ; tmp300 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp298) ; /* tmp301 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp290, tmp300) ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp300, arg1, env2) ; break ; } while (0) ; return /* (tmp285) */ ; } /* end of [aux_39] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_39_closure_type ; ats_void_type aux_39_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { aux_39 (((aux_39_closure_type*)cloptr)->closure_env_0, ((aux_39_closure_type*)cloptr)->closure_env_1, ((aux_39_closure_type*)cloptr)->closure_env_2, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_39_closure_init (aux_39_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_39_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_39_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_39_closure_type *p_clo = ATS_MALLOC(sizeof(aux_39_closure_type)) ; aux_39_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 11926(line=432, offs=7) -- 12136(line=438, offs=6) */ ATSstaticdec() ats_void_type auxlst_40 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; // ATSlocal_void (tmp305) ; ATSlocal (ats_int_type, tmp306) ; __ats_lab_auxlst_40: do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp303 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp304 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp305 = */ aux_39 (env0, env1, env2, arg0, tmp303, arg2) ; tmp306 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp304 ; arg2 = tmp306 ; goto __ats_lab_auxlst_40 ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: break ; } while (0) ; return /* (tmp302) */ ; } /* end of [auxlst_40] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } auxlst_40_closure_type ; ats_void_type auxlst_40_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { auxlst_40 (((auxlst_40_closure_type*)cloptr)->closure_env_0, ((auxlst_40_closure_type*)cloptr)->closure_env_1, ((auxlst_40_closure_type*)cloptr)->closure_env_2, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_40_closure_init (auxlst_40_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_40_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_40_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { auxlst_40_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_40_closure_type)) ; auxlst_40_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 10888(line=402, offs=17) -- 12190(line=441, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_sum (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp284) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_sum: /* tmp284 = */ auxlst_40 (arg1, arg4, arg5, arg0, arg3, 0) ; return /* (tmp284) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_sum] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 12266(line=446, offs=13) -- 14679(line=513, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_bool_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_char_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; ATSlocal (ats_bool_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; // ATSlocal_void (tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; // ATSlocal_void (tmp325) ; ATSlocal (ats_bool_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck: tmp308 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_loc) ; tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_hipat_node) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp309)->tag != 0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_4, tmp309, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp310 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck ; // tail call break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp309)->tag != 1) { goto __ats_lab_58_0 ; } __ats_lab_57_1: break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp309)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp311 = ats_caselptrlab_mac(anairiats_sum_7, tmp309, atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp311 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp309)->tag != 3) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp312 = ats_caselptrlab_mac(anairiats_sum_9, tmp309, atslab_0) ; tmp313 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp313)->tag = 0 ; ats_selptrset_mac(anairiats_sum_9, tmp313, atslab_0, tmp312) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp313, arg3) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp309)->tag != 4) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp314 = ats_caselptrlab_mac(anairiats_sum_10, tmp309, atslab_0) ; tmp315 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp315)->tag = 1 ; ats_selptrset_mac(anairiats_sum_10, tmp315, atslab_0, tmp314) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp315, arg3) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp309)->tag != 5) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp316 = ats_caselptrlab_mac(anairiats_sum_11, tmp309, atslab_1) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_11, tmp309, atslab_2) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_11, tmp309, atslab_3) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (tmp316) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (tmp316) ; if (tmp320) { tmp321 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp321)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp321, atslab_0, tmp316) ; } else { tmp321 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp321)->tag = 2 ; ats_selptrset_mac(anairiats_sum_5, tmp321, atslab_0, tmp316) ; } /* end of [if] */ /* tmp322 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp321, arg3) ; tmp323 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp318) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_sum (arg0, arg1, tmp316, tmp317, tmp323, arg3) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp309)->tag != 6) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_12, tmp309, atslab_1) ; /* tmp325 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (tmp324) ; tmp326 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (tmp324) ; if (tmp326) { tmp327 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp327)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp327, atslab_0, tmp324) ; } else { tmp327 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp327)->tag = 2 ; ats_selptrset_mac(anairiats_sum_5, tmp327, atslab_0, tmp324) ; } /* end of [if] */ /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp327, arg3) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp309)->tag != 8) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp328 = ats_caselptrlab_mac(anairiats_sum_5, tmp309, atslab_0) ; tmp329 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp329)->tag = 4 ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_0, tmp328) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp329, arg3) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp309)->tag != 7) { goto __ats_lab_65_0 ; } __ats_lab_64_1: break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp309)->tag != 9) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_4, tmp309, atslab_1) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp331)->tag = 5 ; ats_selptrset_mac(anairiats_sum_5, tmp331, atslab_0, tmp330) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp331, arg3) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp309)->tag != 11) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_7, tmp309, atslab_1) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_7, tmp309, atslab_2) ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp333) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_patck_rec (arg0, arg1, tmp332, tmp334, arg3) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp309)->tag != 12) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_5, tmp309, atslab_0) ; tmp336 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp336)->tag = 6 ; ats_selptrset_mac(anairiats_sum_5, tmp336, atslab_0, tmp335) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (arg0, tmp308, arg1, tmp336, arg3) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp309)->tag != 13) { goto __ats_lab_69_0 ; } __ats_lab_68_1: break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: /* tmp337 = */ prerr_loc_interror_2 (tmp308) ; /* tmp338 = */ atspre_prerr_string (ATSstrcst(": ccomp_patck: hip0 = ")) ; /* tmp339 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat (arg2) ; /* tmp340 = */ atspre_prerr_newline () ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp307) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 14860(line=526, offs=5) -- 15618(line=557, offs=4) */ ATSstaticdec() ats_void_type aux_43 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; // ATSlocal_void (tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; // ATSlocal_void (tmp358) ; __ats_lab_aux_43: do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_73_0 ; } __ats_lab_70_1: tmp343 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp345 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; tmp347 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp344), atslab_hipat_asvar) ; do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (tmp347 != (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp344), atslab_hipat_loc) ; tmp350 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp344), atslab_hipat_typ) ; tmp349 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp350) ; tmp351 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp349) ; tmp352 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp352)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp352, atslab_0, tmp343) ; ats_selptrset_mac(anairiats_sum_4, tmp352, atslab_1, env2) ; tmp354 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp354, atslab_0, tmp352) ; tmp355 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp354), atslab_1) ; tmp356 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp355) = tmp356 ; /* tmp353 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select (arg0, tmp348, tmp351, env1, tmp354) ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp351) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (tmp347 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_3, tmp347, atslab_0) ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (tmp357) ; break ; } while (0) ; /* tmp358 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, env0, tmp346, tmp344) ; arg0 = arg0 ; arg1 = tmp345 ; goto __ats_lab_aux_43 ; // tail call break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_74_0 ; } __ats_lab_73_1: break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: break ; } while (0) ; return /* (tmp342) */ ; } /* end of [aux_43] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_43_closure_type ; ats_void_type aux_43_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { aux_43 (((aux_43_closure_type*)cloptr)->closure_env_0, ((aux_43_closure_type*)cloptr)->closure_env_1, ((aux_43_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_43_closure_init (aux_43_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_43_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_43_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_43_closure_type *p_clo = ATS_MALLOC(sizeof(aux_43_closure_type)) ; aux_43_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 14729(line=517, offs=4) -- 15663(line=561, offs=4) */ ATSstaticdec() ats_void_type ccomp_match_rec_42 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp341) ; __ats_lab_ccomp_match_rec_42: /* tmp341 = */ aux_43 (arg1, arg2, arg4, arg0, arg3) ; return /* (tmp341) */ ; } /* end of [ccomp_match_rec_42] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 16182(line=580, offs=7) -- 17351(line=617, offs=6) */ ATSstaticdec() ats_void_type aux_var_45 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; // ATSlocal_void (tmp362) ; ATSlocal (ats_bool_type, tmp363) ; ATSlocal (ats_int_type, tmp364) ; ATSlocal (ats_bool_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; // ATSlocal_void (tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; __ats_lab_aux_var_45: tmp361 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_loc) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (arg5, arg1) ; do { /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: tmp364 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count (arg5) ; tmp363 = atspre_eq_int_int (tmp364, 0) ; if (!tmp363) { goto __ats_lab_76_1 ; } break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: __ats_lab_76_1: tmp365 = atspre_gt_int_int (arg4, 0) ; if (!tmp365) { goto __ats_lab_77_1 ; } tmp366 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp366) ; /* tmp368 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon_ptr (arg0, tmp361, tmp367, env0, env1, arg2) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp367) ; /* tmp360 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (arg5, tmp369) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: __ats_lab_77_1: tmp371 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_typ) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp371) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp370) ; /* tmp373 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon (arg0, tmp361, tmp372, env0, env1, arg2) ; tmp374 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp372) ; /* tmp360 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (arg5, tmp374) ; break ; } while (0) ; return /* (tmp360) */ ; } /* end of [aux_var_45] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_var_45_closure_type ; ats_void_type aux_var_45_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { aux_var_45 (((aux_var_45_closure_type*)cloptr)->closure_env_0, ((aux_var_45_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3, arg4, arg5) ; return ; } /* end of function */ ATSinline() ats_void_type aux_var_45_closure_init (aux_var_45_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_var_45_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_var_45_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_var_45_closure_type *p_clo = ATS_MALLOC(sizeof(aux_var_45_closure_type)) ; aux_var_45_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 17382(line=619, offs=7) -- 18903(line=661, offs=6) */ ATSstaticdec() ats_void_type aux_pat_46 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_int_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; // ATSlocal_void (tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; // ATSlocal_void (tmp389) ; ATSlocal (ats_int_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; __ats_lab_aux_pat_46: tmp376 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_node) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp376)->tag != 0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp377 = ats_caselptrlab_mac(anairiats_sum_4, tmp376, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp377 ; goto __ats_lab_aux_pat_46 ; // tail call break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp376)->tag != 1) { goto __ats_lab_80_0 ; } __ats_lab_79_1: break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp376)->tag != 2) { goto __ats_lab_83_0 ; } __ats_lab_80_1: tmp378 = ats_caselptrlab_mac(anairiats_sum_7, tmp376, atslab_0) ; tmp379 = ats_caselptrlab_mac(anairiats_sum_7, tmp376, atslab_1) ; tmp380 = ats_caselptrlab_mac(anairiats_sum_7, tmp376, atslab_2) ; /* tmp381 = */ aux_var_45 (env0, env1, arg0, arg1, arg2, arg3, tmp378, tmp379) ; tmp382 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (tmp379) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp384 = atspre_gt_int_int (tmp378, 0) ; if (!tmp384) { goto __ats_lab_82_1 ; } tmp385 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_loc) ; tmp387 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_typ) ; tmp386 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp387) ; tmp388 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp386) ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr (arg0, tmp385, tmp388, tmp382) ; tmp383 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp388) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp383 = tmp382 ; break ; } while (0) ; /* tmp375 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, arg1, tmp383, tmp380) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp376)->tag != 13) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp390 = ats_caselptrlab_mac(anairiats_sum_12, tmp376, atslab_0) ; tmp391 = ats_caselptrlab_mac(anairiats_sum_12, tmp376, atslab_1) ; /* tmp375 = */ aux_var_45 (env0, env1, arg0, arg1, arg2, arg3, tmp390, tmp391) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp393 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_asvar) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (tmp393 == (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp394 = ats_caselptrlab_mac(anairiats_sum_3, tmp393, atslab_0) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (tmp394) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: // if (tmp393 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_86_1: /* tmp395 = */ prerr_interror_1 () ; /* tmp396 = */ atspre_prerr_string (ATSstrcst(": ccomp_match_sum: aux_pat: hip0 = ")) ; /* tmp397 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat (arg3) ; /* tmp398 = */ atspre_prerr_newline () ; /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp375 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, arg1, tmp392, arg3) ; break ; } while (0) ; return /* (tmp375) */ ; } /* end of [aux_pat_46] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_pat_46_closure_type ; ats_void_type aux_pat_46_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { aux_pat_46 (((aux_pat_46_closure_type*)cloptr)->closure_env_0, ((aux_pat_46_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type aux_pat_46_closure_init (aux_pat_46_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_pat_46_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_pat_46_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_pat_46_closure_type *p_clo = ATS_MALLOC(sizeof(aux_pat_46_closure_type)) ; aux_pat_46_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 18934(line=663, offs=7) -- 19255(line=672, offs=6) */ ATSstaticdec() ats_void_type auxlst_pat_47 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; // ATSlocal_void (tmp402) ; ATSlocal (ats_int_type, tmp403) ; __ats_lab_auxlst_pat_47: do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp401 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; /* tmp402 = */ aux_pat_46 (env0, env1, arg0, arg1, arg2, tmp400) ; tmp403 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp403 ; arg3 = tmp401 ; goto __ats_lab_auxlst_pat_47 ; // tail call break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_88_1: break ; } while (0) ; return /* (tmp399) */ ; } /* end of [auxlst_pat_47] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxlst_pat_47_closure_type ; ats_void_type auxlst_pat_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { auxlst_pat_47 (((auxlst_pat_47_closure_type*)cloptr)->closure_env_0, ((auxlst_pat_47_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_pat_47_closure_init (auxlst_pat_47_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_pat_47_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_pat_47_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxlst_pat_47_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_pat_47_closure_type)) ; auxlst_pat_47_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 15696(line=563, offs=4) -- 19327(line=675, offs=4) */ ATSstaticdec() ats_void_type ccomp_match_sum_44 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp359) ; __ats_lab_ccomp_match_sum_44: /* tmp359 = */ auxlst_pat_47 (arg2, arg5, arg0, arg1, 0, arg4) ; return /* (tmp359) */ ; } /* end of [ccomp_match_sum_44] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 19713(line=691, offs=7) -- 20792(line=728, offs=6) */ ATSstaticdec() ats_void_type aux_var_49 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; ATSlocal (ats_bool_type, tmp408) ; ATSlocal (ats_int_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_bool_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; __ats_lab_aux_var_49: /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (arg4, arg2) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: tmp409 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count (arg4) ; tmp408 = atspre_gt_int_int (tmp409, 0) ; if (!tmp408) { goto __ats_lab_93_1 ; } tmp411 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg3), atslab_valprim_node) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp411)->tag != 6) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp410 = ats_true_bool ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp412 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (arg4) ; if (!tmp412) { goto __ats_lab_92_1 ; } tmp410 = ats_false_bool ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: __ats_lab_92_1: tmp410 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable (arg3) ; break ; } while (0) ; if (tmp410) { tmp414 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg3), atslab_valprim_typ) ; tmp413 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp414) ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, arg1, tmp413, arg3) ; tmp416 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp413) ; /* tmp406 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (arg4, tmp416) ; } else { /* tmp406 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (arg4, arg3) ; } /* end of [if] */ break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: __ats_lab_93_1: break ; } while (0) ; return /* (tmp406) */ ; } /* end of [aux_var_49] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 19403(line=680, offs=13) -- 22113(line=772, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; // ATSlocal_void (tmp421) ; ATSlocal (ats_int_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; // ATSlocal_void (tmp427) ; ATSlocal (ats_bool_type, tmp428) ; ATSlocal (ats_int_type, tmp429) ; ATSlocal (ats_bool_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; // ATSlocal_void (tmp435) ; // ATSlocal_void (tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match: tmp405 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_loc) ; tmp417 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_hipat_node) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp417)->tag != 0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp418 = ats_caselptrlab_mac(anairiats_sum_4, tmp417, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp418 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match ; // tail call break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp417)->tag != 1) { goto __ats_lab_96_0 ; } __ats_lab_95_1: break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp417)->tag != 2) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp419 = ats_caselptrlab_mac(anairiats_sum_7, tmp417, atslab_1) ; tmp420 = ats_caselptrlab_mac(anairiats_sum_7, tmp417, atslab_2) ; /* tmp421 = */ aux_var_49 (arg0, tmp405, arg1, arg2, tmp419) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp420 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp417)->tag != 3) { goto __ats_lab_98_0 ; } __ats_lab_97_1: break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp417)->tag != 4) { goto __ats_lab_99_0 ; } __ats_lab_98_1: break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp417)->tag != 5) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp422 = ats_caselptrlab_mac(anairiats_sum_11, tmp417, atslab_0) ; tmp423 = ats_caselptrlab_mac(anairiats_sum_11, tmp417, atslab_1) ; tmp424 = ats_caselptrlab_mac(anairiats_sum_11, tmp417, atslab_2) ; tmp425 = ats_caselptrlab_mac(anairiats_sum_11, tmp417, atslab_3) ; tmp426 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp425) ; /* tmp427 = */ ccomp_match_sum_44 (arg0, arg1, arg2, tmp423, tmp424, tmp426) ; tmp428 = atspre_lt_int_int (tmp422, 0) ; if (tmp428) { /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free (arg2) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp417)->tag != 6) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp429 = ats_caselptrlab_mac(anairiats_sum_12, tmp417, atslab_0) ; tmp430 = atspre_lt_int_int (tmp429, 0) ; if (tmp430) { /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free (arg2) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp417)->tag != 7) { goto __ats_lab_102_0 ; } __ats_lab_101_1: break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp417)->tag != 9) { goto __ats_lab_103_0 ; } __ats_lab_102_1: break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp417)->tag != 8) { goto __ats_lab_104_0 ; } __ats_lab_103_1: break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp417)->tag != 11) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp431 = ats_caselptrlab_mac(anairiats_sum_7, tmp417, atslab_1) ; tmp432 = ats_caselptrlab_mac(anairiats_sum_7, tmp417, atslab_2) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp432) ; /* tmp404 = */ ccomp_match_rec_42 (arg0, arg1, arg2, tmp431, tmp433) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp417)->tag != 12) { goto __ats_lab_106_0 ; } __ats_lab_105_1: break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)tmp417)->tag != 13) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp434 = ats_caselptrlab_mac(anairiats_sum_12, tmp417, atslab_1) ; /* tmp404 = */ aux_var_49 (arg0, tmp405, arg1, arg2, tmp434) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: __ats_lab_107_1: /* tmp435 = */ prerr_loc_interror_2 (tmp405) ; /* tmp436 = */ atspre_prerr_string (ATSstrcst(": ccomp_match: hip0 = ")) ; /* tmp437 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat (arg3) ; /* tmp438 = */ atspre_prerr_newline () ; /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp404) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 22666(line=797, offs=4) -- 23797(line=827, offs=4) */ ATSstaticdec() ats_ptr_type hiexp_refarg_tr_50 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_int_type, tmp441) ; ATSlocal (ats_int_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_bool_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; // ATSlocal_void (tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; // ATSlocal_void (tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; __ats_lab_hiexp_refarg_tr_50: tmp440 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_node) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)tmp440)->tag != 35) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp441 = ats_caselptrlab_mac(anairiats_sum_15, tmp440, atslab_0) ; tmp442 = ats_caselptrlab_mac(anairiats_sum_15, tmp440, atslab_1) ; tmp443 = ats_caselptrlab_mac(anairiats_sum_15, tmp440, atslab_2) ; tmp444 = atspre_gt_int_int (tmp442, 0) ; if (!tmp444) { goto __ats_lab_109_1 ; } tmp445 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp443), atslab_hiexp_loc) ; tmp446 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (tmp445) ; tmp447 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (tmp445) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (tmp446, arg1) ; tmp450 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp450, atslab_0, tmp447) ; /* tmp449 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (tmp446, tmp450) ; tmp451 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp443), atslab_hiexp_typ) ; tmp453 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp451) ; tmp452 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp453) ; /* tmp454 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec (arg0, tmp445, tmp452) ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref (tmp452) ; tmp456 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp456, atslab_0, tmp455) ; ats_selptrset_mac(anairiats_sum_1, tmp456, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp456 ; /* tmp457 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp446, tmp455) ; tmp459 = (ats_sum_ptr_type)0 ; tmp458 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var (tmp445, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, tmp446, tmp459, tmp443) ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var (tmp445, tmp451, tmp446) ; tmp461 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg (tmp445, tmp451, tmp441, tmp442, tmp460) ; tmp462 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp462, atslab_0, tmp458) ; tmp463 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp462), atslab_1) ; tmp464 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp464, atslab_0, tmp461) ; ats_ptrget_mac(ats_ptr_type, tmp463) = tmp464 ; tmp463 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp464), atslab_1) ; tmp464 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp463) = tmp464 ; tmp439 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq (tmp445, tmp451, tmp462) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: tmp439 = arg3 ; break ; } while (0) ; return (tmp439) ; } /* end of [hiexp_refarg_tr_50] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 23834(line=829, offs=5) -- 24317(line=846, offs=4) */ ATSstaticdec() ats_ptr_type hiexplst_refarg_tr_51 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; __ats_lab_hiexplst_refarg_tr_51: do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp466 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp467 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp468 = hiexp_refarg_tr_50 (arg0, arg1, arg2, tmp466) ; tmp469 = hiexplst_refarg_tr_51 (arg0, arg1, arg2, tmp467) ; tmp465 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp465, atslab_0, tmp468) ; ats_selptrset_mac(anairiats_sum_1, tmp465, atslab_1, tmp469) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: tmp465 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp465) ; } /* end of [hiexplst_refarg_tr_51] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 24404(line=851, offs=21) -- 24573(line=855, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_int_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make: tmp471 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (arg0) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (tmp471 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp472 = ats_caselptrlab_mac(anairiats_sum_16, tmp471, atslab_0) ; tmp473 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make () ; tmp470 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_clo (tmp472, arg0, tmp473) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (tmp471 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: tmp470 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun (arg0) ; break ; } while (0) ; return (tmp470) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 24631(line=859, offs=4) -- 24951(line=871, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_assgn_ptr_53 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_ccomp_exp_assgn_ptr_53: tmp475 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg2) ; tmp476 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, arg3) ; tmp477 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg4) ; /* tmp474 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs (arg0, arg1, tmp475, tmp476, tmp477) ; return /* (tmp474) */ ; } /* end of [ccomp_exp_assgn_ptr_53] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 24988(line=873, offs=4) -- 25309(line=885, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_assgn_var_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; __ats_lab_ccomp_exp_assgn_var_54: tmp479 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var (arg2) ; tmp480 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, arg3) ; tmp481 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg4) ; /* tmp478 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_var_offs (arg0, arg1, tmp479, tmp480, tmp481) ; return /* (tmp478) */ ; } /* end of [ccomp_exp_assgn_var_54] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 25368(line=889, offs=4) -- 25516(line=894, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_freeat_55 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; __ats_lab_ccomp_exp_freeat_55: tmp483 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_loc) ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; /* tmp482 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr (arg0, tmp483, tmp484) ; return /* (tmp482) */ ; } /* end of [ccomp_exp_freeat_55] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 25570(line=898, offs=4) -- 25952(line=907, offs=4) */ ATSstaticdec() ats_ptr_type funarg_valprim_make_56 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_int_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_bool_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; __ats_lab_funarg_valprim_make_56: tmp486 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_hityp_node) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)tmp486)->tag != 3) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp487 = ats_caselptrlab_mac(anairiats_sum_12, tmp486, atslab_0) ; tmp488 = ats_caselptrlab_mac(anairiats_sum_12, tmp486, atslab_1) ; tmp489 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp488) ; tmp490 = atspre_eq_int_int (tmp487, 0) ; if (tmp490) { tmp485 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg (arg0, tmp489) ; } else { tmp485 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argref (arg0, tmp489) ; } /* end of [if] */ break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp486)->tag != 12) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp491 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (arg1) ; tmp485 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argtmpref (arg0, tmp491) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: __ats_lab_116_1: tmp492 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (arg1) ; tmp485 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg (arg0, tmp492) ; break ; } while (0) ; return (tmp485) ; } /* end of [funarg_valprim_make_56] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 26123(line=916, offs=7) -- 26798(line=936, offs=6) */ ATSstaticdec() ats_ptr_type aux_patck_58 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; // ATSlocal_void (tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_int_type, tmp501) ; __ats_lab_aux_patck_58: do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp495 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp496 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp497 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp495), atslab_hipat_typ) ; tmp498 = funarg_valprim_make_56 (arg1, tmp497) ; /* tmp499 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp498, tmp495, arg3) ; tmp501 = atspre_add_int_int (arg1, 1) ; tmp500 = aux_patck_58 (arg0, tmp501, tmp496, arg3) ; tmp494 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp494, atslab_0, tmp498) ; ats_selptrset_mac(anairiats_sum_1, tmp494, atslab_1, tmp500) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp494 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp494) ; } /* end of [aux_patck_58] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 26827(line=937, offs=7) -- 27231(line=950, offs=6) */ ATSstaticdec() ats_void_type aux_match_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; // ATSlocal_void (tmp507) ; __ats_lab_aux_match_59: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; ATS_FREE(arg2) ; // if (arg3 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp505 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp506 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; /* tmp507 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, arg1, tmp503, tmp505) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp504 ; arg3 = tmp506 ; goto __ats_lab_aux_match_59 ; // tail call break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_120_1: break ; } while (0) ; return /* (tmp502) */ ; } /* end of [aux_match_59] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 25989(line=909, offs=4) -- 27398(line=955, offs=4) */ ATSstaticdec() ats_void_type ccomp_funarg_57 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp493) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; __ats_lab_ccomp_funarg_57: tmp508 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp508)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp508, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp508, atslab_1, arg4) ; tmp509 = aux_patck_58 (arg0, 0, arg3, tmp508) ; /* tmp493 = */ aux_match_59 (arg0, arg1, tmp509, arg3) ; return /* (tmp493) */ ; } /* end of [ccomp_funarg_57] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 27724(line=968, offs=9) -- 27963(line=974, offs=8) */ ATSstaticdec() ats_void_type aux_61 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; __ats_lab_aux_61: do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp513 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp514 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp515 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp515, atslab_0, tmp513) ; ats_selptrset_mac(anairiats_sum_1, tmp515, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp515 ; arg0 = arg0 ; arg1 = tmp514 ; goto __ats_lab_aux_61 ; // tail call break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_122_1: break ; } while (0) ; return /* (tmp512) */ ; } /* end of [aux_61] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 28888(line=1004, offs=9) -- 29001(line=1006, offs=8) */ ATSstaticdec() ats_void_type aux_62 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp537) ; ATSlocal (ats_bool_type, tmp538) ; ATSlocal (ats_int_type, tmp539) ; __ats_lab_aux_62: tmp539 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_lev (arg0) ; tmp538 = atspre_lt_int_int (tmp539, env0) ; if (tmp538) { /* tmp537 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (arg0) ; } else { /* empty */ } /* end of [if] */ return /* (tmp537) */ ; } /* end of [aux_62] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux_62_closure_type ; ats_void_type aux_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_62 (((aux_62_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_62_closure_init (aux_62_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_62_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_62_closure_make (ats_int_type env0) { aux_62_closure_type *p_clo = ATS_MALLOC(sizeof(aux_62_closure_type)) ; aux_62_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 29142(line=1010, offs=9) -- 29310(line=1016, offs=8) */ ATSstaticdec() ats_void_type aux_63 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_bool_type, tmp544) ; ATSlocal (ats_int_type, tmp545) ; __ats_lab_aux_63: tmp543 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp545 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (tmp543) ; tmp544 = atspre_lt_int_int (tmp545, env0) ; if (tmp544) { /* tmp542 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add (arg0) ; } else { /* empty */ } /* end of [if] */ return /* (tmp542) */ ; } /* end of [aux_63] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux_63_closure_type ; ats_void_type aux_63_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_63 (((aux_63_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_63_closure_init (aux_63_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_63_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_63_closure_make (ats_int_type env0) { aux_63_closure_type *p_clo = ATS_MALLOC(sizeof(aux_63_closure_type)) ; aux_63_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 27463(line=959, offs=3) -- 29785(line=1030, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; // ATSlocal_void (tmp516) ; ATSlocal (ats_int_type, tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; // ATSlocal_void (tmp522) ; // ATSlocal_void (tmp523) ; ATSlocal (ats_int_type, tmp524) ; // ATSlocal_void (tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; // ATSlocal_void (tmp536) ; // ATSlocal_void (tmp540) ; ATSlocal (ats_clo_ptr_type, tmp541) ; // ATSlocal_void (tmp546) ; ATSlocal (ats_clo_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; // ATSlocal_void (tmp550) ; // ATSlocal_void (tmp551) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab: /* ats_ptr_type tmp511 ; */ tmp511 = (ats_sum_ptr_type)0 ; /* tmp516 = */ aux_61 ((&tmp511), arg1) ; tmp517 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp518 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc () ; /* tmp519 = ats_selsin_mac(tmp518, atslab_1) */ ; /* tmp520 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push () ; /* tmp521 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push () ; /* tmp522 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp523 = ats_selsin_mac(tmp522, atslab_1) */ ; tmp524 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp525 = */ ccomp_funarg_57 ((&tmp511), tmp524, arg0, arg2, arg4) ; tmp527 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_typ) ; tmp526 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp527) ; tmp528 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret (tmp526) ; /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push (arg4) ; /* tmp530 = ats_selsin_mac(tmp529, atslab_1) */ ; /* tmp531 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar ((&tmp511), arg3, tmp528) ; /* tmp532 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop () ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; tmp534 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop () ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop () ; /* tmp536 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec () ; /* ats_clo_ptr_type tmp541 ; */ tmp541 = aux_62_closure_make (tmp517) ; /* tmp540 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr (tmp534, tmp541) ; ATS_FREE(tmp541) ; /* ats_clo_ptr_type tmp547 ; */ tmp547 = aux_63_closure_make (tmp517) ; /* tmp546 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_cloptr (tmp535, tmp547) ; ATS_FREE(tmp547) ; tmp548 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp511) ; tmp549 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make (arg0, arg4, tmp517, tmp534, tmp535, tmp528, tmp548) ; /* tmp550 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst (arg4) ; /* tmp551 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate (tmp549) ; tmp510 = tmp549 ; return (tmp510) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 29849(line=1034, offs=4) -- 30583(line=1060, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_lam_64 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; // ATSlocal_void (tmp555) ; // ATSlocal_void (tmp556) ; // ATSlocal_void (tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; // ATSlocal_void (tmp564) ; __ats_lab_ccomp_exp_lam_64: tmp553 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (arg1) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ (tmp553) ; /* tmp555 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp556 = ats_selsin_mac(tmp555, atslab_1) */ ; tmp558 = (ats_sum_ptr_type)0 ; /* tmp557 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (tmp554, tmp558) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (tmp554) ; tmp560 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp560, atslab_0, tmp559) ; tmp561 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp560), atslab_1) ; tmp562 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp561) = tmp562 ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (arg0, tmp560, arg2, arg3, tmp554) ; /* tmp564 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; tmp552 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (tmp554) ; return (tmp552) ; } /* end of [ccomp_exp_lam_64] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 30614(line=1062, offs=4) -- 30773(line=1066, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_fixdef_65 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; __ats_lab_ccomp_exp_fixdef_65: tmp566 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp566 ; tmp565 = tmp566 ; return (tmp565) ; } /* end of [ccomp_exp_fixdef_65] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 30828(line=1070, offs=4) -- 31055(line=1076, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_lazy_delay_66 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; __ats_lab_ccomp_exp_lazy_delay_66: tmp568 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ats_selptrset_mac(anairiats_sum_16, tmp568, atslab_0, -1) ; tmp570 = (ats_sum_ptr_type)0 ; tmp571 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp569 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp568, tmp570, tmp571) ; tmp572 = (ats_sum_ptr_type)0 ; tmp567 = ccomp_exp_lam_64 (arg0, tmp569, tmp572, arg1) ; return (tmp567) ; } /* end of [ccomp_exp_lazy_delay_66] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 31093(line=1078, offs=4) -- 31646(line=1090, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_lazy_ldelay_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; // ATSlocal_void (tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; __ats_lab_ccomp_exp_lazy_ldelay_67: tmp574 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ats_selptrset_mac(anairiats_sum_16, tmp574, atslab_0, 1) ; tmp575 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp576 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (arg0) ; /* tmp577 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp576) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var (arg0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool, tmp576) ; tmp579 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if (arg0, tmp575, tmp578, arg1, arg2) ; tmp580 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var (arg0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool, 0, tmp576) ; tmp582 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp582, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; tmp583 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp582), atslab_1) ; tmp584 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp583) = tmp584 ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp574, tmp582, tmp575) ; tmp585 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp585, atslab_0, tmp580) ; tmp586 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp585), atslab_1) ; tmp587 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp586) = tmp587 ; tmp573 = ccomp_exp_lam_64 (arg0, tmp581, tmp585, tmp579) ; return (tmp573) ; } /* end of [ccomp_exp_lazy_ldelay_67] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 31706(line=1094, offs=4) -- 32115(line=1109, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_ptrof_ptr_68 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; __ats_lab_ccomp_exp_ptrof_ptr_68: tmp589 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; tmp590 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, arg2) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (tmp590 == (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp588 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs (tmp589, tmp590) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: // if (tmp590 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_124_1: tmp588 = tmp589 ; break ; } while (0) ; return (tmp588) ; } /* end of [ccomp_exp_ptrof_ptr_68] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 32152(line=1111, offs=4) -- 33290(line=1152, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_ptrof_var_69 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_int_type, tmp594) ; ATSlocal (ats_int_type, tmp595) ; ATSlocal (ats_bool_type, tmp597) ; ATSlocal (ats_bool_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; // ATSlocal_void (tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; __ats_lab_ccomp_exp_ptrof_var_69: /* ats_ptr_type tmp592 ; */ tmp592 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (arg1) ; tmp593 = ats_caselptrlab_mac(anairiats_rec_13, tmp592, atslab_valprim_node) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp593)->tag != 11) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp591 = tmp592 ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: tmp594 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (arg1) ; tmp595 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; do { /* branch: __ats_lab_127 */ __ats_lab_127_0: __ats_lab_127_1: tmp597 = atspre_lt_int_int (tmp594, tmp595) ; if (!tmp597) { goto __ats_lab_128_1 ; } tmp598 = atspre_gt_int_int (tmp594, 0) ; if (tmp598) { tmp599 = ats_caselptrlab_mac(anairiats_rec_13, tmp592, atslab_valprim_typ) ; tmp600 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make (arg1, tmp599) ; /* tmp601 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add (tmp600) ; tmp602 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env (tmp600, tmp599) ; tmp592 = tmp602 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: __ats_lab_128_1: break ; } while (0) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, arg2) ; tmp591 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_var_offs (tmp592, tmp603) ; break ; } while (0) ; return (tmp591) ; } /* end of [ccomp_exp_ptrof_var_69] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 33351(line=1156, offs=4) -- 34218(line=1182, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_refarg_70 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_bool_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; // ATSlocal_void (tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; // ATSlocal_void (tmp620) ; // ATSlocal_void (tmp621) ; __ats_lab_ccomp_exp_refarg_70: do { /* branch: __ats_lab_129 */ __ats_lab_129_0: __ats_lab_129_1: tmp605 = atspre_eq_int_int (arg1, 0) ; if (!tmp605) { goto __ats_lab_130_1 ; } tmp604 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg2) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: __ats_lab_130_1: tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg2), atslab_hiexp_node) ; do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp606)->tag != 47) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp607 = ats_caselptrlab_mac(anairiats_sum_5, tmp606, atslab_0) ; tmp608 = (ats_sum_ptr_type)0 ; tmp604 = ccomp_exp_ptrof_var_69 (arg0, tmp607, tmp608) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp606)->tag != 37) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp609 = ats_caselptrlab_mac(anairiats_sum_4, tmp606, atslab_0) ; tmp610 = ats_caselptrlab_mac(anairiats_sum_4, tmp606, atslab_1) ; tmp604 = ccomp_exp_ptrof_ptr_68 (arg0, tmp609, tmp610) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp606)->tag != 38) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp611 = ats_caselptrlab_mac(anairiats_sum_4, tmp606, atslab_0) ; tmp612 = ats_caselptrlab_mac(anairiats_sum_4, tmp606, atslab_1) ; tmp604 = ccomp_exp_ptrof_var_69 (arg0, tmp611, tmp612) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp606)->tag != 14) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp613 = ats_caselptrlab_mac(anairiats_sum_5, tmp606, atslab_0) ; tmp615 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg2), atslab_hiexp_typ) ; tmp614 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp615) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext (tmp613, tmp614) ; tmp604 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof (tmp616) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: tmp618 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg2), atslab_hiexp_loc) ; /* tmp617 = */ prerr_loc_interror_2 (tmp618) ; /* tmp619 = */ atspre_prerr_string (ATSstrcst(": ccomp_exp_refarg: hie = ")) ; /* tmp620 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (arg2) ; /* tmp621 = */ atspre_prerr_newline () ; /* tmp604 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp604) ; } /* end of [ccomp_exp_refarg_70] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 34349(line=1188, offs=7) -- 34637(line=1196, offs=6) */ ATSstaticdec() ats_ptr_type aux_72 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; __ats_lab_aux_72: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp625 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp626 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; arg0 = arg0 ; arg1 = tmp624 ; arg2 = tmp625 ; goto __ats_lab_aux_72 ; // tail call break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp623 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; break ; } while (0) ; return (tmp623) ; } /* end of [aux_72] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 34276(line=1186, offs=4) -- 34764(line=1201, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_exp_seq_71 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; __ats_lab_ccomp_exp_seq_71: do { /* branch: __ats_lab_138 */ __ats_lab_138_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp627 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp628 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp622 = aux_72 (arg0, tmp627, tmp628) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: tmp622 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; } while (0) ; return (tmp622) ; } /* end of [ccomp_exp_seq_71] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 34837(line=1206, offs=15) -- 35875(line=1235, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_int_type, tmp631) ; ATSlocal (ats_int_type, tmp632) ; // ATSlocal_void (tmp633) ; ATSlocal (ats_bool_type, tmp634) ; ATSlocal (ats_bool_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_bool_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; // ATSlocal_void (tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var: /* ats_ptr_type tmp630 ; */ tmp630 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (arg0) ; tmp631 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (arg0) ; tmp632 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: __ats_lab_140_1: tmp634 = atspre_lt_int_int (tmp631, tmp632) ; if (!tmp634) { goto __ats_lab_144_1 ; } tmp635 = atspre_gt_int_int (tmp631, 0) ; if (tmp635) { tmp636 = ats_caselptrlab_mac(anairiats_rec_13, tmp630, atslab_valprim_node) ; do { /* branch: __ats_lab_141 */ __ats_lab_141_0: __ats_lab_141_1: tmp637 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const (tmp630) ; if (!tmp637) { goto __ats_lab_142_0 ; } break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp636)->tag != 6) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp638 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp633 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (tmp638) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: __ats_lab_143_1: tmp639 = ats_caselptrlab_mac(anairiats_rec_13, tmp630, atslab_valprim_typ) ; tmp640 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make (arg0, tmp639) ; /* tmp641 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add (tmp640) ; tmp642 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env (tmp640, tmp639) ; tmp630 = tmp642 ; break ; } while (0) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: __ats_lab_144_1: break ; } while (0) ; tmp629 = tmp630 ; return (tmp629) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 35927(line=1239, offs=4) -- 37604(line=1286, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_loop_74 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; // ATSlocal_void (tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; // ATSlocal_void (tmp666) ; __ats_lab_ccomp_exp_loop_74: /* ats_ptr_type tmp644 ; */ tmp644 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp646 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp647 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp ((&tmp644), tmp646) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_146_1: break ; } while (0) ; tmp648 = tmp644 ; tmp649 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp648) ; tmp650 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make () ; tmp651 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make () ; do { /* branch: __ats_lab_147 */ __ats_lab_147_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp652 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make () ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: __ats_lab_148_1: tmp652 = tmp650 ; break ; } while (0) ; /* tmp653 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_push (tmp650, tmp651, tmp652) ; /* ats_ptr_type tmp654 ; */ tmp654 = (ats_sum_ptr_type)0 ; tmp655 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp ((&tmp654), arg3) ; tmp656 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp654) ; /* ats_ptr_type tmp657 ; */ tmp657 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp659 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp ((&tmp657), tmp659) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_150_1: break ; } while (0) ; tmp661 = tmp657 ; tmp662 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp661) ; /* ats_ptr_type tmp663 ; */ tmp663 = (ats_sum_ptr_type)0 ; tmp664 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp ((&tmp663), arg5) ; tmp665 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp663) ; /* tmp666 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_pop () ; /* tmp643 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loop (arg0, arg1, tmp650, tmp651, tmp652, tmp649, tmp655, tmp656, tmp662, tmp665) ; return /* (tmp643) */ ; } /* end of [ccomp_exp_loop_74] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 37674(line=1291, offs=11) -- 43399(line=1468, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; ATSlocal (ats_ptr_type, tmp672) ; // ATSlocal_void (tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; // ATSlocal_void (tmp677) ; ATSlocal (ats_bool_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_char_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_bool_type, tmp686) ; // ATSlocal_void (tmp687) ; // ATSlocal_void (tmp688) ; // ATSlocal_void (tmp689) ; // ATSlocal_void (tmp690) ; // ATSlocal_void (tmp691) ; // ATSlocal_void (tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; // ATSlocal_void (tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; // ATSlocal_void (tmp710) ; // ATSlocal_void (tmp711) ; // ATSlocal_void (tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; // ATSlocal_void (tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; // ATSlocal_void (tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp730) ; // ATSlocal_void (tmp731) ; // ATSlocal_void (tmp732) ; // ATSlocal_void (tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; // ATSlocal_void (tmp735) ; ATSlocal (ats_int_type, tmp736) ; // ATSlocal_void (tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_int_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_int_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_bool_type, tmp761) ; // ATSlocal_void (tmp762) ; // ATSlocal_void (tmp763) ; // ATSlocal_void (tmp764) ; // ATSlocal_void (tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; // ATSlocal_void (tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; // ATSlocal_void (tmp776) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp: tmp668 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_loc) ; tmp669 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_node) ; do { /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp669)->tag != 3) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp670 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_0) ; tmp671 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_1) ; tmp672 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_2) ; /* tmp673 = */ ccomp_exp_assgn_ptr_53 (arg0, tmp668, tmp670, tmp671, tmp672) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp669)->tag != 4) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp674 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_0) ; tmp675 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_1) ; tmp676 = ats_caselptrlab_mac(anairiats_sum_8, tmp669, atslab_2) ; /* tmp677 = */ ccomp_exp_assgn_var_54 (arg0, tmp668, tmp674, tmp675, tmp676) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: if (((ats_sum_ptr_type)tmp669)->tag != 5) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp678 = ats_caselptrlab_mac(anairiats_sum_9, tmp669, atslab_0) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool (tmp678) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp669)->tag != 7) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp679 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp680 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp681 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp680) ; tmp683 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp682 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp683) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_castfn (tmp679, tmp681, tmp682) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp669)->tag != 8) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp684 = ats_caselptrlab_mac(anairiats_sum_10, tmp669, atslab_0) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char (tmp684) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp669)->tag != 10) { goto __ats_lab_159_0 ; } __ats_lab_156_1: tmp685 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; do { /* branch: __ats_lab_157 */ __ats_lab_157_0: __ats_lab_157_1: tmp686 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof (tmp685) ; if (!tmp686) { goto __ats_lab_158_1 ; } /* tmp687 = */ prerr_loc_ccomp_0 (tmp668) ; /* tmp688 = */ atspre_prerr_string (ATSstrcst(": [")) ; /* tmp689 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (tmp685) ; /* tmp690 = */ atspre_prerr_string (ATSstrcst("] is a proof constant")) ; /* tmp691 = */ atspre_prerr_string (ATSstrcst(", which must not occur at run-time.")) ; /* tmp692 = */ atspre_prerr_newline () ; /* tmp667 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: __ats_lab_158_1: tmp694 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp693 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp694) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst (tmp685, tmp693) ; break ; } while (0) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp669)->tag != 11) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp695 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp697 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp696 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp697) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cstsp (tmp668, tmp695, tmp696) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp669)->tag != 12) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp698 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; /* tmp699 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file (arg0, tmp668, tmp698) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp669)->tag != 13) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: if (((ats_sum_ptr_type)tmp669)->tag != 14) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp700 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp702 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp701 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp702) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext (tmp700, tmp701) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp669)->tag != 15) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp703 = ats_caselptrlab_mac(anairiats_sum_7, tmp669, atslab_1) ; tmp704 = ats_caselptrlab_mac(anairiats_sum_7, tmp669, atslab_2) ; tmp706 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp705 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp706) ; tmp707 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; tmp708 = ref_make_elt_04328_ats_ptr_type (tmp707) ; tmp709 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix (tmp708, tmp705) ; /* tmp710 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp711 = ats_selsin_mac(tmp710, atslab_1) */ ; /* tmp712 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp703, tmp709) ; tmp713 = ccomp_exp_fixdef_65 (arg0, tmp704, tmp708) ; /* tmp714 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; tmp667 = tmp713 ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: if (((ats_sum_ptr_type)tmp669)->tag != 16) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp715 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float (tmp715) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: if (((ats_sum_ptr_type)tmp669)->tag != 17) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp716 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp718 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp717 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp718) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp (tmp716, tmp717) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)tmp669)->tag != 18) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp719 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; /* tmp720 = */ ccomp_exp_freeat_55 (arg0, tmp719) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp669)->tag != 20) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp721 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (tmp721) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp669)->tag != 21) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp722 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp723 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp725 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp724 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp725) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp (tmp722, tmp723, tmp724) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: if (((ats_sum_ptr_type)tmp669)->tag != 22) { goto __ats_lab_170_0 ; } __ats_lab_169_1: tmp726 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp727 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp728 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp667 = ccomp_exp_lam_64 (tmp668, tmp728, tmp726, tmp727) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp669)->tag != 27) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp729 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp730 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; /* tmp731 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp732 = ats_selsin_mac(tmp731, atslab_1) */ ; /* tmp733 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (arg0, tmp729) ; tmp734 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp730) ; /* tmp735 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; tmp667 = tmp734 ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)tmp669)->tag != 29) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp736 = ats_caselptrlab_mac(anairiats_sum_17, tmp669, atslab_0) ; tmp738 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get (tmp736) ; /* tmp737 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn (arg0, tmp668, tmp736, tmp738) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp669)->tag != 31) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp739 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp740 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp667 = ccomp_exp_ptrof_ptr_68 (arg0, tmp739, tmp740) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp669)->tag != 32) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp741 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp742 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp667 = ccomp_exp_ptrof_var_69 (arg0, tmp741, tmp742) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp669)->tag != 35) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp743 = ats_caselptrlab_mac(anairiats_sum_15, tmp669, atslab_0) ; tmp744 = ats_caselptrlab_mac(anairiats_sum_15, tmp669, atslab_2) ; tmp667 = ccomp_exp_refarg_70 (arg0, tmp743, tmp744) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp669)->tag != 39) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp745 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp667 = ccomp_exp_seq_71 (arg0, tmp745) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp669)->tag != 41) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp746 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; tmp747 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp746) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof (tmp747) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp669)->tag != 42) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp748 = ats_caselptrlab_mac(anairiats_sum_18, tmp669, atslab_0) ; tmp749 = ats_caselptrlab_mac(anairiats_sum_18, tmp669, atslab_1) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string (tmp748, tmp749) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)tmp669)->tag != 43) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp750 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp751 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp753 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp752 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp753) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_cst (arg0, tmp668, tmp752, tmp750, tmp751) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp669)->tag != 44) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp754 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_0) ; tmp755 = ats_caselptrlab_mac(anairiats_sum_4, tmp669, atslab_1) ; tmp757 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp756 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp757) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_template_var (arg0, tmp668, tmp756, tmp754, tmp755) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)tmp669)->tag != 45) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp759 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp758 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp759) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top (tmp758) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp669)->tag != 47) { goto __ats_lab_184_0 ; } __ats_lab_181_1: tmp760 = ats_caselptrlab_mac(anairiats_sum_5, tmp669, atslab_0) ; do { /* branch: __ats_lab_182 */ __ats_lab_182_0: __ats_lab_182_1: tmp761 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf (tmp760) ; if (!tmp761) { goto __ats_lab_183_1 ; } /* tmp762 = */ prerr_loc_ccomp_0 (tmp668) ; /* tmp763 = */ atspre_prerr_string (ATSstrcst(": [")) ; /* tmp764 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp760) ; /* tmp765 = */ atspre_prerr_string (ATSstrcst("] is a proof variable")) ; /* tmp766 = */ atspre_prerr_string (ATSstrcst(", which must not occur at run-time.")) ; /* tmp767 = */ atspre_prerr_newline () ; /* tmp667 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: __ats_lab_183_1: tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var (tmp760) ; break ; } while (0) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp669)->tag != 28) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp768 = ats_caselptrlab_mac(anairiats_sum_19, tmp669, atslab_0) ; tmp769 = ats_caselptrlab_mac(anairiats_sum_19, tmp669, atslab_1) ; tmp770 = ats_caselptrlab_mac(anairiats_sum_19, tmp669, atslab_2) ; tmp771 = ats_caselptrlab_mac(anairiats_sum_19, tmp669, atslab_3) ; /* tmp772 = */ ccomp_exp_loop_74 (arg0, tmp668, tmp768, tmp769, tmp770, tmp771) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: __ats_lab_185_1: tmp774 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp773 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp774) ; tmp775 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp773) ; /* tmp776 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, arg1, tmp775) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp775) ; break ; } while (0) ; return (tmp667) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 43467(line=1473, offs=14) -- 43690(line=1481, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst: do { /* branch: __ats_lab_186 */ __ats_lab_186_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_186_1: tmp778 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp779 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp780 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp778) ; tmp781 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (arg0, tmp779) ; tmp777 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp777, atslab_0, tmp780) ; ats_selptrset_mac(anairiats_sum_1, tmp777, atslab_1, tmp781) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_187_1: tmp777 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp777) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 43743(line=1484, offs=17) -- 43980(line=1492, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (ats_ptr_type, tmp783) ; ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst: do { /* branch: __ats_lab_188 */ __ats_lab_188_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_189_0 ; } __ats_lab_188_1: tmp783 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp784 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp785 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (arg0, tmp783) ; tmp786 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst (arg0, tmp784) ; tmp782 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp782, atslab_0, tmp785) ; ats_selptrset_mac(anairiats_sum_1, tmp782, atslab_1, tmp786) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_189_1: tmp782 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp782) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 44036(line=1495, offs=17) -- 44306(line=1503, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst: do { /* branch: __ats_lab_190 */ __ats_lab_190_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_191_0 ; } __ats_lab_190_1: tmp788 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_0) ; tmp789 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_1) ; tmp790 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_2) ; tmp791 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp789) ; tmp792 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst (arg0, tmp790) ; tmp787 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ats_selptrset_mac(anairiats_sum_20, tmp787, atslab_0, tmp788) ; ats_selptrset_mac(anairiats_sum_20, tmp787, atslab_1, tmp791) ; ats_selptrset_mac(anairiats_sum_20, tmp787, atslab_2, tmp792) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_191_1: tmp787 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp787) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 44361(line=1507, offs=5) -- 44644(line=1515, offs=4) */ ATSstaticdec() ats_void_type instrlst_add_freeptr_79 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; // ATSlocal_void (tmp796) ; __ats_lab_instrlst_add_freeptr_79: do { /* branch: __ats_lab_192 */ __ats_lab_192_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp794 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp795 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; ATS_FREE(arg2) ; /* tmp796 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr (arg0, arg1, tmp794) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp795 ; goto __ats_lab_instrlst_add_freeptr_79 ; // tail call break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_193_1: break ; } while (0) ; return /* (tmp793) */ ; } /* end of [instrlst_add_freeptr_79] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 45089(line=1537, offs=7) -- 45299(line=1544, offs=6) */ ATSstaticdec() ats_ptr_type valprim_mov_81 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; // ATSlocal_void (tmp801) ; __ats_lab_valprim_mov_81: tmp800 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg2), atslab_valprim_typ) ; tmp799 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp800) ; /* tmp801 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, arg1, tmp799, arg2) ; tmp798 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp799) ; return (tmp798) ; } /* end of [valprim_mov_81] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 45328(line=1546, offs=7) -- 46255(line=1578, offs=6) */ ATSstaticdec() ats_ptr_type aux1_arg_82 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_int_type, tmp807) ; ATSlocal (ats_bool_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_int_type, tmp811) ; ATSlocal (ats_bool_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_int_type, tmp814) ; __ats_lab_aux1_arg_82: do { /* branch: __ats_lab_194 */ __ats_lab_194_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } __ats_lab_194_1: tmp803 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp804 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp806 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp803), atslab_valprim_node) ; do { /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp806)->tag != 0) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp807 = ats_caselptrlab_mac(anairiats_sum_17, tmp806, atslab_0) ; tmp808 = atspre_lt_int_int (tmp807, arg2) ; if (!tmp808) { goto __ats_lab_201_1 ; } tmp805 = valprim_mov_81 (arg0, arg1, tmp803) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp806)->tag != 17) { goto __ats_lab_199_0 ; } __ats_lab_196_1: tmp809 = ats_caselptrlab_mac(anairiats_sum_5, tmp806, atslab_0) ; tmp810 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp809), atslab_valprim_node) ; do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp810)->tag != 1) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp811 = ats_caselptrlab_mac(anairiats_sum_17, tmp810, atslab_0) ; tmp812 = atspre_lt_int_int (tmp811, arg2) ; if (!tmp812) { goto __ats_lab_198_1 ; } tmp805 = valprim_mov_81 (arg0, arg1, tmp803) ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: __ats_lab_198_1: tmp805 = tmp803 ; break ; } while (0) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp806)->tag != 4) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp805 = valprim_mov_81 (arg0, arg1, tmp803) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp806)->tag != 6) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp805 = valprim_mov_81 (arg0, arg1, tmp803) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: __ats_lab_201_1: tmp805 = tmp803 ; break ; } while (0) ; tmp814 = atspre_add_int_int (arg2, 1) ; tmp813 = aux1_arg_82 (arg0, arg1, tmp814, tmp804) ; tmp802 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp802, atslab_0, tmp805) ; ats_selptrset_mac(anairiats_sum_1, tmp802, atslab_1, tmp813) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_202_1: tmp802 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp802) ; } /* end of [aux1_arg_82] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 46286(line=1580, offs=7) -- 46545(line=1588, offs=36) */ ATSstaticdec() ats_ptr_type aux2_arg_83 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; __ats_lab_aux2_arg_83: do { /* branch: __ats_lab_203 */ __ats_lab_203_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp816 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp817 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp818 = aux2_arg_83 (arg0, arg1, tmp817) ; tmp815 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp815, atslab_0, tmp816) ; ats_selptrset_mac(anairiats_sum_1, tmp815, atslab_1, tmp818) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_204_1: tmp815 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp815) ; } /* end of [aux2_arg_83] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 46742(line=1597, offs=7) -- 47053(line=1608, offs=28) */ ATSstaticdec() ats_void_type aux1_mov_84 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; // ATSlocal_void (tmp823) ; ATSlocal (ats_int_type, tmp824) ; __ats_lab_aux1_mov_84: do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp821 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp822 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; ATS_FREE(arg3) ; /* tmp823 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_arg (arg0, arg1, arg2, tmp821) ; tmp824 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp824 ; arg3 = tmp822 ; goto __ats_lab_aux1_mov_84 ; // tail call break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_208_1: break ; } while (0) ; return /* (tmp820) */ ; } /* end of [aux1_mov_84] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 47089(line=1611, offs=7) -- 47572(line=1625, offs=28) */ ATSstaticdec() ats_void_type aux2_mov_85 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; // ATSlocal_void (tmp830) ; __ats_lab_aux2_mov_85: do { /* branch: __ats_lab_209 */ __ats_lab_209_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_212_0 ; } __ats_lab_209_1: tmp826 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp827 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; ATS_FREE(arg3) ; do { /* branch: __ats_lab_210 */ __ats_lab_210_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp828 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp829 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; /* tmp830 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, arg1, tmp828, tmp826) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp829 ; arg3 = tmp827 ; goto __ats_lab_aux2_mov_85 ; // tail call break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_211_1: arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp827 ; goto __ats_lab_aux2_mov_85 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_212_1: break ; } while (0) ; return /* (tmp825) */ ; } /* end of [aux2_mov_85] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 44703(line=1519, offs=4) -- 47745(line=1632, offs=4) */ ATSstaticdec() ats_void_type tailcall_arg_move_80 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp797) ; ATSlocal (ats_ptr_type, tmp819) ; __ats_lab_tailcall_arg_move_80: do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (arg2 != 0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp819 = aux1_arg_82 (arg0, arg1, 0, arg4) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: __ats_lab_206_1: tmp819 = aux2_arg_83 (arg0, arg1, arg4) ; break ; } while (0) ; do { /* branch: __ats_lab_213 */ __ats_lab_213_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_214_0 ; } __ats_lab_213_1: /* tmp797 = */ aux2_mov_85 (arg0, arg1, arg3, tmp819) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_214_1: /* tmp797 = */ aux1_mov_84 (arg0, arg1, 0, tmp819) ; break ; } while (0) ; return /* (tmp797) */ ; } /* end of [tailcall_arg_move_80] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 47801(line=1636, offs=4) -- 51286(line=1756, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_app_tmpvar_86 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_int_type, tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; ATSlocal (ats_bool_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_int_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; // ATSlocal_void (tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_bool_type, tmp864) ; ATSlocal (ats_int_type, tmp865) ; ATSlocal (ats_bool_type, tmp867) ; ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_ptr_type, tmp869) ; ATSlocal (ats_bool_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_int_type, tmp872) ; ATSlocal (ats_bool_type, tmp873) ; // ATSlocal_void (tmp874) ; // ATSlocal_void (tmp875) ; ATSlocal (ats_bool_type, tmp876) ; __ats_lab_ccomp_exp_app_tmpvar_86: /* ats_ptr_type tmp832 ; */ tmp832 = (ats_sum_ptr_type)0 ; tmp834 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg4), atslab_hiexp_node) ; do { /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp834)->tag != 35) { goto __ats_lab_220_0 ; } __ats_lab_215_1: tmp835 = ats_caselptrlab_mac(anairiats_sum_15, tmp834, atslab_1) ; tmp836 = ats_caselptrlab_mac(anairiats_sum_15, tmp834, atslab_2) ; tmp837 = atspre_gt_int_int (tmp835, 0) ; if (!tmp837) { goto __ats_lab_220_1 ; } tmp838 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp836) ; tmp840 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp838), atslab_valprim_node) ; do { /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp840)->tag != 6) { goto __ats_lab_217_0 ; } __ats_lab_216_1: break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp840)->tag != 14) { goto __ats_lab_218_0 ; } __ats_lab_217_1: break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp840)->tag != 11) { goto __ats_lab_219_0 ; } __ats_lab_218_1: break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: __ats_lab_219_1: tmp841 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp841, atslab_0, tmp838) ; ats_selptrset_mac(anairiats_sum_1, tmp841, atslab_1, tmp832) ; tmp832 = tmp841 ; break ; } while (0) ; tmp833 = tmp838 ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: __ats_lab_220_1: tmp833 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg4) ; break ; } while (0) ; tmp842 = hiexplst_refarg_tr_51 (arg0, arg2, (&tmp832), arg5) ; tmp843 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (arg0, tmp842) ; tmp844 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp832) ; tmp846 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp833), atslab_valprim_node) ; do { /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp846)->tag != 14) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp847 = ats_caselptrlab_mac(anairiats_sum_5, tmp846, atslab_0) ; tmp845 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp845, atslab_0, tmp847) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp846)->tag != 6) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp848 = ats_caselptrlab_mac(anairiats_sum_7, tmp846, atslab_1) ; tmp845 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp845, atslab_0, tmp848) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: if (((ats_sum_ptr_type)tmp846)->tag != 7) { goto __ats_lab_228_0 ; } __ats_lab_223_1: tmp849 = ats_caselptrlab_mac(anairiats_sum_5, tmp846, atslab_0) ; tmp850 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find (tmp849) ; do { /* branch: __ats_lab_224 */ __ats_lab_224_0: if (tmp850 == (ats_sum_ptr_type)0) { goto __ats_lab_227_0 ; } __ats_lab_224_1: tmp851 = ats_caselptrlab_mac(anairiats_sum_3, tmp850, atslab_0) ; ATS_FREE(tmp850) ; tmp852 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp851), atslab_valprim_node) ; do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (((ats_sum_ptr_type)tmp852)->tag != 14) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp853 = ats_caselptrlab_mac(anairiats_sum_5, tmp852, atslab_0) ; tmp845 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp845, atslab_0, tmp853) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: __ats_lab_226_1: tmp845 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: // if (tmp850 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_227_1: tmp845 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: if (((ats_sum_ptr_type)tmp846)->tag != 11) { goto __ats_lab_231_0 ; } __ats_lab_228_1: tmp854 = ats_caselptrlab_mac(anairiats_sum_5, tmp846, atslab_0) ; tmp855 = ats_ptrget_mac(ats_ptr_type, tmp854) ; tmp856 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp855), atslab_valprim_node) ; do { /* branch: __ats_lab_229 */ __ats_lab_229_0: if (((ats_sum_ptr_type)tmp856)->tag != 14) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp857 = ats_caselptrlab_mac(anairiats_sum_5, tmp856, atslab_0) ; tmp845 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp845, atslab_0, tmp857) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: __ats_lab_230_1: tmp845 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: __ats_lab_231_1: tmp845 = (ats_sum_ptr_type)0 ; break ; } while (0) ; /* ats_int_type tmp858 ; */ tmp858 = 0 ; /* ats_ptr_type tmp859 ; */ tmp859 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_232 */ __ats_lab_232_0: if (tmp845 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } __ats_lab_232_1: tmp861 = ats_caselptrlab_mac(anairiats_sum_3, tmp845, atslab_0) ; ATS_FREE(tmp845) ; do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (tmp844 != (ats_sum_ptr_type)0) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp865 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_ret (arg6) ; tmp864 = atspre_gt_int_int (tmp865, 0) ; if (tmp864) { tmp858 = 1 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: // if (tmp844 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_234_1: break ; } while (0) ; tmp867 = atspre_gt_int_int (tmp858, 0) ; if (tmp867) { tmp868 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_find (tmp861) ; do { /* branch: __ats_lab_235 */ __ats_lab_235_0: if (tmp868 == (ats_sum_ptr_type)0) { goto __ats_lab_236_0 ; } __ats_lab_235_1: tmp869 = ats_caselptrlab_mac(anairiats_sum_3, tmp868, atslab_0) ; ATS_FREE(tmp868) ; tmp859 = tmp869 ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: // if (tmp868 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_236_1: tmp858 = 0 ; break ; } while (0) ; } else { /* empty */ } /* end of [if] */ tmp870 = atspre_gt_int_int (tmp858, 0) ; if (tmp870) { tmp871 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_top () ; tmp873 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab (tmp861, tmp871) ; if (tmp873) { tmp872 = 0 ; } else { tmp872 = 1 ; } /* end of [if] */ /* tmp874 = */ tailcall_arg_move_80 (arg0, arg1, tmp872, tmp859, tmp843) ; /* tmp860 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call_tail (arg0, arg1, tmp861) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: // if (tmp845 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_237_1: break ; } while (0) ; tmp876 = atspre_eq_int_int (tmp858, 0) ; if (tmp876) { /* tmp875 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call (arg0, arg1, arg6, arg3, tmp833, tmp843) ; } else { /* empty */ } /* end of [if] */ /* tmp831 = */ instrlst_add_freeptr_79 (arg0, arg1, tmp844) ; return /* (tmp831) */ ; } /* end of [ccomp_exp_app_tmpvar_86] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 51464(line=1764, offs=7) -- 52029(line=1779, offs=24) */ ATSstaticdec() ats_void_type aux_88 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_ptr_type, tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; // ATSlocal_void (tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; ATSlocal (ats_int_type, tmp894) ; __ats_lab_aux_88: do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp879 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp880 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp881 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp879), atslab_hiexp_loc) ; tmp882 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp879) ; tmp883 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int (arg1) ; tmp886 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (tmp883) ; tmp887 = (ats_sum_ptr_type)0 ; tmp885 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp885, atslab_0, tmp886) ; ats_selptrset_mac(anairiats_sum_1, tmp885, atslab_1, tmp887) ; tmp888 = (ats_sum_ptr_type)0 ; tmp884 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp884, atslab_0, tmp885) ; ats_selptrset_mac(anairiats_sum_1, tmp884, atslab_1, tmp888) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp889)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp889, atslab_0, tmp884) ; ats_selptrset_mac(anairiats_sum_4, tmp889, atslab_1, env1) ; tmp891 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp891, atslab_0, tmp889) ; tmp892 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp891), atslab_1) ; tmp893 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp892) = tmp893 ; /* tmp890 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs (arg0, tmp881, env0, tmp891, tmp882) ; tmp894 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp894 ; arg2 = tmp880 ; goto __ats_lab_aux_88 ; // tail call break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_239_1: break ; } while (0) ; return /* (tmp878) */ ; } /* end of [aux_88] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_88_closure_type ; ats_void_type aux_88_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { aux_88 (((aux_88_closure_type*)cloptr)->closure_env_0, ((aux_88_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_88_closure_init (aux_88_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_88_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_88_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_88_closure_type *p_clo = ATS_MALLOC(sizeof(aux_88_closure_type)) ; aux_88_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 51345(line=1760, offs=4) -- 52079(line=1783, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_assgn_arr_87 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp877) ; __ats_lab_ccomp_exp_assgn_arr_87: /* tmp877 = */ aux_88 (arg1, arg2, arg0, 0, arg3) ; return /* (tmp877) */ ; } /* end of [ccomp_exp_assgn_arr_87] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 52137(line=1787, offs=4) -- 53240(line=1824, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_arrinit_tmpvar_89 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ // ATSlocal_void (tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_int_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; // ATSlocal_void (tmp900) ; ATSlocal (ats_ptr_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; // ATSlocal_void (tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; __ats_lab_ccomp_exp_arrinit_tmpvar_89: do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp897 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp896 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp897) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_241_1: tmp898 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg5) ; tmp899 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int (tmp898) ; tmp896 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (tmp899) ; break ; } while (0) ; /* tmp900 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_stack (arg0, arg1, arg6, arg2, tmp896, arg3) ; do { /* branch: __ats_lab_242 */ __ats_lab_242_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_245_0 ; } __ats_lab_242_1: do { /* branch: __ats_lab_243 */ __ats_lab_243_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_243_1: tmp901 = ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_0) ; tmp902 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (arg3) ; /* tmp903 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, tmp901, tmp902) ; tmp904 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof (arg3) ; /* tmp895 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_arr (arg0, arg1, arg6, tmp896, tmp902, tmp904) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_244_1: break ; } while (0) ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_245_1: tmp905 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (arg6) ; /* tmp895 = */ ccomp_exp_assgn_arr_87 (arg0, tmp905, arg3, arg5) ; break ; } while (0) ; return /* (tmp895) */ ; } /* end of [ccomp_exp_arrinit_tmpvar_89] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 53303(line=1828, offs=4) -- 54151(line=1858, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_arrpsz_tmpvar_90 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp906) ; ATSlocal (ats_int_type, tmp907) ; // ATSlocal_void (tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; // ATSlocal_void (tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; __ats_lab_ccomp_exp_arrpsz_tmpvar_90: tmp907 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg3) ; /* tmp908 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_heap (arg0, arg1, arg4, tmp907, arg2) ; tmp910 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp909 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp910) ; tmp911 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp909) ; tmp912 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (arg4) ; tmp913 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (arg4) ; tmp915 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (2) ; tmp914 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp914)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp914, atslab_0, tmp915) ; ats_selptrset_mac(anairiats_sum_4, tmp914, atslab_1, tmp913) ; tmp917 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp917, atslab_0, tmp914) ; tmp918 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp917), atslab_1) ; tmp919 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp918) = tmp919 ; /* tmp916 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs (arg0, arg1, tmp909, tmp912, tmp917) ; /* tmp906 = */ ccomp_exp_assgn_arr_87 (arg0, tmp911, arg2, arg3) ; return /* (tmp906) */ ; } /* end of [ccomp_exp_arrpsz_tmpvar_90] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 54214(line=1862, offs=5) -- 55336(line=1901, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_lst_tmpvar_rest_91 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9, ats_ptr_type arg10, ats_ptr_type arg11, ats_ptr_type arg12) { /* local vardec */ // ATSlocal_void (tmp920) ; ATSlocal (ats_ptr_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; // ATSlocal_void (tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; // ATSlocal_void (tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; // ATSlocal_void (tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; // ATSlocal_void (tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; __ats_lab_ccomp_exp_lst_tmpvar_rest_91: do { /* branch: __ats_lab_246 */ __ats_lab_246_0: if (arg6 == (ats_sum_ptr_type)0) { goto __ats_lab_247_0 ; } __ats_lab_246_1: tmp921 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp922 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; tmp923 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp921), atslab_hiexp_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp921) ; tmp926 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp926, atslab_0, tmp924) ; tmp927 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp926), atslab_1) ; tmp928 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp928, atslab_0, arg7) ; ats_ptrget_mac(ats_ptr_type, tmp927) = tmp928 ; tmp927 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp928), atslab_1) ; tmp928 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp927) = tmp928 ; /* tmp925 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (arg0, tmp923, arg11, arg5, arg4, tmp926) ; tmp930 = (ats_sum_ptr_type)0 ; /* tmp929 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs (arg0, tmp923, arg10, tmp930, arg12) ; tmp932 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs (arg12, arg8) ; /* tmp931 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp923, arg9, tmp932) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = arg5 ; arg6 = tmp922 ; arg7 = arg7 ; arg8 = arg8 ; arg9 = arg9 ; arg10 = arg10 ; arg11 = arg11 ; arg12 = arg12 ; goto __ats_lab_ccomp_exp_lst_tmpvar_rest_91 ; // tail call break ; /* branch: __ats_lab_247 */ __ats_lab_247_0: // if (arg6 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_247_1: tmp934 = (ats_sum_ptr_type)0 ; /* tmp933 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (arg0, arg1, arg11, arg3, arg2, tmp934) ; tmp935 = (ats_sum_ptr_type)0 ; /* tmp920 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs (arg0, arg1, arg10, tmp935, arg12) ; break ; } while (0) ; return /* (tmp920) */ ; } /* end of [ccomp_exp_lst_tmpvar_rest_91] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 55379(line=1903, offs=4) -- 57352(line=1959, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_lst_tmpvar_92 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; ATSlocal (ats_bool_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; // ATSlocal_void (tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; ATSlocal (ats_ptr_type, tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_bool_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; // ATSlocal_void (tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; // ATSlocal_void (tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_ptr_type, tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; // ATSlocal_void (tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; __ats_lab_ccomp_exp_lst_tmpvar_92: tmp938 = atspre_gt_int_int (arg2, 0) ; if (tmp938) { tmp937 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_nil ; } else { tmp937 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil ; } /* end of [if] */ tmp939 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get (tmp937) ; /* tmp940 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (tmp939) ; tmp942 = (ats_sum_ptr_type)0 ; tmp941 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make (tmp939, tmp942) ; do { /* branch: __ats_lab_248 */ __ats_lab_248_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_249_0 ; } __ats_lab_248_1: tmp943 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp944 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; tmp945 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp943), atslab_hiexp_loc) ; tmp947 = atspre_gt_int_int (arg2, 0) ; if (tmp947) { tmp946 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_cons ; } else { tmp946 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons ; } /* end of [if] */ tmp948 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get (tmp946) ; /* tmp949 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (tmp948) ; tmp950 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (arg3) ; tmp952 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp952, atslab_0, tmp950) ; tmp953 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp952), atslab_1) ; tmp954 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp954, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ats_ptrget_mac(ats_ptr_type, tmp953) = tmp954 ; tmp953 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp954), atslab_1) ; tmp954 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp953) = tmp954 ; tmp951 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make (tmp948, tmp952) ; tmp955 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp943) ; tmp956 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp957 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top (tmp956) ; tmp959 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp959, atslab_0, tmp955) ; tmp960 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp959), atslab_1) ; tmp961 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp961, atslab_0, tmp957) ; ats_ptrget_mac(ats_ptr_type, tmp960) = tmp961 ; tmp960 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp961), atslab_1) ; tmp961 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp960) = tmp961 ; /* tmp958 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (arg0, tmp945, arg5, tmp951, tmp948, tmp959) ; tmp962 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (arg5) ; tmp963 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp951) ; tmp964 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp963), atslab_hityp_name) ; tmp965 = ats_caselptrlab_mac(anairiats_sum_21, tmp964, atslab_1) ; tmp967 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (tmp965) ; tmp966 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp967) ; tmp969 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (1) ; tmp968 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp968)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp968, atslab_0, tmp969) ; ats_selptrset_mac(anairiats_sum_4, tmp968, atslab_1, tmp966) ; tmp970 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp970, atslab_0, tmp968) ; tmp971 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp970), atslab_1) ; tmp972 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp971) = tmp972 ; tmp973 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp956) ; tmp974 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp973) ; tmp976 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs (tmp962, tmp970) ; /* tmp975 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp945, tmp973, tmp976) ; tmp977 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp956) ; tmp978 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp977) ; /* tmp936 = */ ccomp_exp_lst_tmpvar_rest_91 (arg0, arg1, tmp939, tmp941, tmp948, tmp951, tmp944, tmp957, tmp970, tmp973, tmp974, tmp977, tmp978) ; break ; /* branch: __ats_lab_249 */ __ats_lab_249_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_249_1: tmp979 = (ats_sum_ptr_type)0 ; /* tmp936 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (arg0, arg1, arg5, tmp941, tmp939, tmp979) ; break ; } while (0) ; return /* (tmp936) */ ; } /* end of [ccomp_exp_lst_tmpvar_92] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 57516(line=1967, offs=7) -- 57870(line=1980, offs=10) */ ATSstaticdec() ats_void_type aux_94 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; __ats_lab_aux_94: do { /* branch: __ats_lab_250 */ __ats_lab_250_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } __ats_lab_250_1: tmp982 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp983 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp984 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; arg0 = arg0 ; arg1 = tmp982 ; arg2 = tmp983 ; arg3 = arg3 ; goto __ats_lab_aux_94 ; // tail call break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_251_1: /* tmp981 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, arg1, arg3) ; break ; } while (0) ; return /* (tmp981) */ ; } /* end of [aux_94] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 57416(line=1963, offs=4) -- 58013(line=1986, offs=4) */ ATSstaticdec() ats_void_type ccomp_exp_seq_tmpvar_93 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp980) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; __ats_lab_ccomp_exp_seq_tmpvar_93: do { /* branch: __ats_lab_252 */ __ats_lab_252_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_253_0 ; } __ats_lab_252_1: tmp985 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp986 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp980 = */ aux_94 (arg0, tmp985, tmp986, arg2) ; break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_253_1: break ; } while (0) ; return /* (tmp980) */ ; } /* end of [ccomp_exp_seq_tmpvar_93] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 58098(line=1992, offs=3) -- 67667(line=2241, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; ATSlocal (ats_ptr_type, tmp992) ; ATSlocal (ats_int_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_bool_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; ATSlocal (ats_char_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_int_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; ATSlocal (ats_int_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; ATSlocal (ats_bool_type, tmp1015) ; // ATSlocal_void (tmp1016) ; // ATSlocal_void (tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; // ATSlocal_void (tmp1019) ; ATSlocal (ats_ptr_type, tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; // ATSlocal_void (tmp1023) ; ATSlocal (ats_bool_type, tmp1024) ; // ATSlocal_void (tmp1025) ; // ATSlocal_void (tmp1026) ; // ATSlocal_void (tmp1027) ; // ATSlocal_void (tmp1028) ; // ATSlocal_void (tmp1029) ; // ATSlocal_void (tmp1030) ; // ATSlocal_void (tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (ats_ptr_type, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; ATSlocal (ats_ptr_type, tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_ptr_type, tmp1042) ; ATSlocal (ats_ptr_type, tmp1043) ; ATSlocal (ats_ptr_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; // ATSlocal_void (tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; // ATSlocal_void (tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_ptr_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_ptr_type, tmp1060) ; ATSlocal (ats_ptr_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; ATSlocal (ats_ptr_type, tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_ptr_type, tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_int_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; // ATSlocal_void (tmp1086) ; // ATSlocal_void (tmp1087) ; // ATSlocal_void (tmp1088) ; // ATSlocal_void (tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; ATSlocal (ats_ptr_type, tmp1091) ; ATSlocal (ats_ptr_type, tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_int_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_int_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; ATSlocal (ats_ptr_type, tmp1102) ; ATSlocal (ats_ptr_type, tmp1103) ; ATSlocal (ats_ptr_type, tmp1104) ; ATSlocal (ats_ptr_type, tmp1105) ; ATSlocal (ats_ptr_type, tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; ATSlocal (ats_int_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; ATSlocal (ats_ptr_type, tmp1110) ; ATSlocal (ats_ptr_type, tmp1111) ; ATSlocal (ats_ptr_type, tmp1112) ; ATSlocal (ats_ptr_type, tmp1113) ; ATSlocal (ats_bool_type, tmp1114) ; ATSlocal (ats_ptr_type, tmp1115) ; ATSlocal (ats_int_type, tmp1116) ; ATSlocal (ats_ptr_type, tmp1117) ; ATSlocal (ats_ptr_type, tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; ATSlocal (ats_ptr_type, tmp1120) ; ATSlocal (ats_ptr_type, tmp1121) ; ATSlocal (ats_ptr_type, tmp1122) ; ATSlocal (ats_ptr_type, tmp1123) ; ATSlocal (ats_ptr_type, tmp1124) ; ATSlocal (ats_ptr_type, tmp1125) ; ATSlocal (ats_ptr_type, tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; ATSlocal (ats_ptr_type, tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; ATSlocal (ats_ptr_type, tmp1130) ; ATSlocal (ats_ptr_type, tmp1131) ; ATSlocal (ats_ptr_type, tmp1132) ; ATSlocal (ats_int_type, tmp1133) ; ATSlocal (ats_ptr_type, tmp1134) ; ATSlocal (ats_ptr_type, tmp1135) ; ATSlocal (ats_ptr_type, tmp1136) ; ATSlocal (ats_ptr_type, tmp1137) ; ATSlocal (ats_ptr_type, tmp1138) ; ATSlocal (ats_ptr_type, tmp1139) ; ATSlocal (ats_int_type, tmp1140) ; ATSlocal (ats_ptr_type, tmp1141) ; // ATSlocal_void (tmp1142) ; ATSlocal (ats_ptr_type, tmp1143) ; ATSlocal (ats_ptr_type, tmp1144) ; ATSlocal (ats_ptr_type, tmp1145) ; ATSlocal (ats_ptr_type, tmp1146) ; ATSlocal (ats_ptr_type, tmp1147) ; ATSlocal (ats_ptr_type, tmp1148) ; ATSlocal (ats_ptr_type, tmp1149) ; ATSlocal (ats_ptr_type, tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; ATSlocal (ats_ptr_type, tmp1152) ; ATSlocal (ats_ptr_type, tmp1153) ; ATSlocal (ats_ptr_type, tmp1154) ; // ATSlocal_void (tmp1155) ; // ATSlocal_void (tmp1156) ; // ATSlocal_void (tmp1157) ; // ATSlocal_void (tmp1158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar: tmp988 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_loc) ; tmp989 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_node) ; do { /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp989)->tag != 0) { goto __ats_lab_255_0 ; } __ats_lab_254_1: tmp990 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_0) ; tmp991 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_1) ; tmp992 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_2) ; tmp993 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp994 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp990) ; /* tmp987 = */ ccomp_exp_app_tmpvar_86 (arg0, tmp988, tmp993, tmp994, tmp991, tmp992, arg2) ; break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: if (((ats_sum_ptr_type)tmp989)->tag != 2) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp995 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp996 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp995) ; /* tmp987 = */ ccomp_exp_arrpsz_tmpvar_90 (arg0, tmp988, tmp997, tmp996, arg2) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: if (((ats_sum_ptr_type)tmp989)->tag != 3) { goto __ats_lab_257_0 ; } __ats_lab_256_1: tmp998 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_0) ; tmp999 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_1) ; tmp1000 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_2) ; /* tmp987 = */ ccomp_exp_assgn_ptr_53 (arg0, tmp988, tmp998, tmp999, tmp1000) ; break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: if (((ats_sum_ptr_type)tmp989)->tag != 4) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp1001 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_0) ; tmp1002 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_1) ; tmp1003 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_2) ; /* tmp987 = */ ccomp_exp_assgn_var_54 (arg0, tmp988, tmp1001, tmp1002, tmp1003) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp989)->tag != 5) { goto __ats_lab_259_0 ; } __ats_lab_258_1: tmp1004 = ats_caselptrlab_mac(anairiats_sum_9, tmp989, atslab_0) ; tmp1005 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool (tmp1004) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1005) ; break ; /* branch: __ats_lab_259 */ __ats_lab_259_0: if (((ats_sum_ptr_type)tmp989)->tag != 7) { goto __ats_lab_260_0 ; } __ats_lab_259_1: tmp1006 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1006) ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: if (((ats_sum_ptr_type)tmp989)->tag != 8) { goto __ats_lab_261_0 ; } __ats_lab_260_1: tmp1007 = ats_caselptrlab_mac(anairiats_sum_10, tmp989, atslab_0) ; tmp1008 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char (tmp1007) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1008) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)tmp989)->tag != 6) { goto __ats_lab_262_0 ; } __ats_lab_261_1: tmp1009 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_0) ; tmp1010 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_1) ; tmp1011 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_2) ; tmp1012 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp1013 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (arg0, tmp1010) ; tmp1015 = atspre_gt_int_int (tmp1009, 0) ; if (tmp1015) { tmp1014 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; } else { tmp1014 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp1014)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp1014, atslab_0, tmp988) ; } /* end of [if] */ /* tmp1016 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp1017 = ats_selsin_mac(tmp1016, atslab_1) */ ; tmp1018 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst (tmp1012, tmp1013, tmp1011, arg2, tmp1014) ; /* tmp1019 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_switch (arg0, tmp988, tmp1018) ; break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp989)->tag != 9) { goto __ats_lab_263_0 ; } __ats_lab_262_1: tmp1020 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_0) ; tmp1021 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_1) ; tmp1022 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_2) ; tmp1024 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_proof (tmp1021) ; if (tmp1024) { /* tmp1025 = */ prerr_loc_ccomp_0 (tmp988) ; /* tmp1026 = */ atspre_prerr_string (ATSstrcst(": [")) ; /* tmp1027 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (tmp1021) ; /* tmp1028 = */ atspre_prerr_string (ATSstrcst("] is a proof constructor")) ; /* tmp1029 = */ atspre_prerr_string (ATSstrcst(", which must not occur at run-time.")) ; /* tmp1030 = */ atspre_prerr_newline () ; /* tmp1023 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp1031 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (tmp1021) ; tmp1032 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1020) ; tmp1033 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_explst (arg0, tmp1022) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (arg0, tmp988, arg2, tmp1032, tmp1021, tmp1033) ; break ; /* branch: __ats_lab_263 */ __ats_lab_263_0: if (((ats_sum_ptr_type)tmp989)->tag != 10) { goto __ats_lab_264_0 ; } __ats_lab_263_1: tmp1034 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg1) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1034) ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: if (((ats_sum_ptr_type)tmp989)->tag != 12) { goto __ats_lab_265_0 ; } __ats_lab_264_1: tmp1035 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file (arg0, tmp988, tmp1035) ; break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: if (((ats_sum_ptr_type)tmp989)->tag != 13) { goto __ats_lab_266_0 ; } __ats_lab_265_1: break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: if (((ats_sum_ptr_type)tmp989)->tag != 14) { goto __ats_lab_267_0 ; } __ats_lab_266_1: tmp1036 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1038 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1037 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1038) ; tmp1039 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext (tmp1036, tmp1037) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1039) ; break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: if (((ats_sum_ptr_type)tmp989)->tag != 16) { goto __ats_lab_268_0 ; } __ats_lab_267_1: tmp1040 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1041 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float (tmp1040) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1041) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: if (((ats_sum_ptr_type)tmp989)->tag != 17) { goto __ats_lab_269_0 ; } __ats_lab_268_1: tmp1042 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1044 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1043 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1044) ; tmp1045 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp (tmp1042, tmp1043) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1045) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: if (((ats_sum_ptr_type)tmp989)->tag != 18) { goto __ats_lab_270_0 ; } __ats_lab_269_1: tmp1046 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; /* tmp987 = */ ccomp_exp_freeat_55 (arg0, tmp1046) ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: if (((ats_sum_ptr_type)tmp989)->tag != 19) { goto __ats_lab_271_0 ; } __ats_lab_270_1: tmp1047 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_0) ; tmp1048 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_1) ; tmp1049 = ats_caselptrlab_mac(anairiats_sum_8, tmp989, atslab_2) ; tmp1050 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1047) ; /* ats_ptr_type tmp1051 ; */ tmp1051 = (ats_sum_ptr_type)0 ; /* tmp1052 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar ((&tmp1051), tmp1048, arg2) ; /* ats_ptr_type tmp1053 ; */ tmp1053 = (ats_sum_ptr_type)0 ; /* tmp1054 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar ((&tmp1053), tmp1049, arg2) ; tmp1055 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp1051) ; tmp1056 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp1053) ; tmp1057 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_cond (tmp988, tmp1050, tmp1055, tmp1056) ; tmp1058 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1058, atslab_0, tmp1057) ; ats_selptrset_mac(anairiats_sum_1, tmp1058, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp1058 ; break ; /* branch: __ats_lab_271 */ __ats_lab_271_0: if (((ats_sum_ptr_type)tmp989)->tag != 20) { goto __ats_lab_272_0 ; } __ats_lab_271_1: tmp1059 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1060 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (tmp1059) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1060) ; break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: if (((ats_sum_ptr_type)tmp989)->tag != 21) { goto __ats_lab_273_0 ; } __ats_lab_272_1: tmp1061 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1062 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1064 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1063 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1064) ; tmp1065 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp (tmp1061, tmp1062, tmp1063) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1065) ; break ; /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)tmp989)->tag != 22) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp1066 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1067 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1069 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1068 = ccomp_exp_lam_64 (tmp988, tmp1069, tmp1066, tmp1067) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1068) ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)tmp989)->tag != 24) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp1070 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1072 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1070), atslab_hiexp_typ) ; tmp1071 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1072) ; tmp1073 = ccomp_exp_lazy_delay_66 (tmp988, tmp1070) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay (arg0, tmp988, arg2, 0, tmp1071, tmp1073) ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)tmp989)->tag != 25) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp1074 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1075 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1077 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1074), atslab_hiexp_typ) ; tmp1076 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1077) ; tmp1078 = ccomp_exp_lazy_ldelay_67 (tmp988, tmp1074, tmp1075) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay (arg0, tmp988, arg2, 1, tmp1076, tmp1078) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: if (((ats_sum_ptr_type)tmp989)->tag != 26) { goto __ats_lab_277_0 ; } __ats_lab_276_1: tmp1079 = ats_caselptrlab_mac(anairiats_sum_12, tmp989, atslab_0) ; tmp1080 = ats_caselptrlab_mac(anairiats_sum_12, tmp989, atslab_1) ; tmp1081 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1080) ; tmp1083 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1082 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1083) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_force (arg0, tmp988, arg2, tmp1079, tmp1082, tmp1081) ; break ; /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp989)->tag != 27) { goto __ats_lab_278_0 ; } __ats_lab_277_1: tmp1084 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1085 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; /* tmp1086 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp1087 = ats_selsin_mac(tmp1086, atslab_1) */ ; /* tmp1088 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (arg0, tmp1084) ; /* tmp1089 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, tmp1085, arg2) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; break ; /* branch: __ats_lab_278 */ __ats_lab_278_0: if (((ats_sum_ptr_type)tmp989)->tag != 28) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp1090 = ats_caselptrlab_mac(anairiats_sum_19, tmp989, atslab_0) ; tmp1091 = ats_caselptrlab_mac(anairiats_sum_19, tmp989, atslab_1) ; tmp1092 = ats_caselptrlab_mac(anairiats_sum_19, tmp989, atslab_2) ; tmp1093 = ats_caselptrlab_mac(anairiats_sum_19, tmp989, atslab_3) ; /* tmp987 = */ ccomp_exp_loop_74 (arg0, tmp988, tmp1090, tmp1091, tmp1092, tmp1093) ; break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: if (((ats_sum_ptr_type)tmp989)->tag != 29) { goto __ats_lab_280_0 ; } __ats_lab_279_1: tmp1094 = ats_caselptrlab_mac(anairiats_sum_17, tmp989, atslab_0) ; tmp1095 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get (tmp1094) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn (arg0, tmp988, tmp1094, tmp1095) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: if (((ats_sum_ptr_type)tmp989)->tag != 30) { goto __ats_lab_281_0 ; } __ats_lab_280_1: tmp1096 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_0) ; tmp1097 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_1) ; tmp1098 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_2) ; tmp1099 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1097) ; /* tmp987 = */ ccomp_exp_lst_tmpvar_92 (arg0, tmp988, tmp1096, tmp1099, tmp1098, arg2) ; break ; /* branch: __ats_lab_281 */ __ats_lab_281_0: if (((ats_sum_ptr_type)tmp989)->tag != 31) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp1100 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1101 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1102 = ccomp_exp_ptrof_ptr_68 (arg0, tmp1100, tmp1101) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1102) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: if (((ats_sum_ptr_type)tmp989)->tag != 32) { goto __ats_lab_283_0 ; } __ats_lab_282_1: tmp1103 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1104 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1105 = ccomp_exp_ptrof_var_69 (arg0, tmp1103, tmp1104) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1105) ; break ; /* branch: __ats_lab_283 */ __ats_lab_283_0: if (((ats_sum_ptr_type)tmp989)->tag != 33) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp1106 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1107 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1106) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_raise (arg0, tmp988, arg2, tmp1107) ; break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: if (((ats_sum_ptr_type)tmp989)->tag != 34) { goto __ats_lab_287_0 ; } __ats_lab_284_1: tmp1108 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_0) ; tmp1109 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_1) ; tmp1110 = ats_caselptrlab_mac(anairiats_sum_7, tmp989, atslab_2) ; tmp1111 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1109) ; do { /* branch: __ats_lab_285 */ __ats_lab_285_0: if (tmp1110 == (ats_sum_ptr_type)0) { goto __ats_lab_286_0 ; } tmp1112 = ats_caselptrlab_mac(anairiats_sum_20, tmp1110, atslab_2) ; if (tmp1112 != (ats_sum_ptr_type)0) { goto __ats_lab_286_0 ; } __ats_lab_285_1: tmp1113 = ats_caselptrlab_mac(anairiats_sum_20, tmp1110, atslab_1) ; tmp1114 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin (tmp1111) ; if (!tmp1114) { goto __ats_lab_286_1 ; } arg0 = arg0 ; arg1 = tmp1113 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar ; // tail call break ; /* branch: __ats_lab_286 */ __ats_lab_286_0: __ats_lab_286_1: tmp1115 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_labexplst (arg0, tmp1110) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_rec (arg0, tmp988, arg2, tmp1108, tmp1111, tmp1115) ; break ; } while (0) ; break ; /* branch: __ats_lab_287 */ __ats_lab_287_0: if (((ats_sum_ptr_type)tmp989)->tag != 35) { goto __ats_lab_288_0 ; } __ats_lab_287_1: tmp1116 = ats_caselptrlab_mac(anairiats_sum_15, tmp989, atslab_0) ; tmp1117 = ats_caselptrlab_mac(anairiats_sum_15, tmp989, atslab_2) ; tmp1118 = ccomp_exp_refarg_70 (arg0, tmp1116, tmp1117) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1118) ; break ; /* branch: __ats_lab_288 */ __ats_lab_288_0: if (((ats_sum_ptr_type)tmp989)->tag != 36) { goto __ats_lab_289_0 ; } __ats_lab_288_1: tmp1119 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1120 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1121 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1119) ; tmp1122 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, tmp1120) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select (arg0, tmp988, arg2, tmp1121, tmp1122) ; break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: if (((ats_sum_ptr_type)tmp989)->tag != 37) { goto __ats_lab_290_0 ; } __ats_lab_289_1: tmp1123 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1124 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1125 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1123) ; tmp1126 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, tmp1124) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr_offs (arg0, tmp988, arg2, tmp1125, tmp1126) ; break ; /* branch: __ats_lab_290 */ __ats_lab_290_0: if (((ats_sum_ptr_type)tmp989)->tag != 38) { goto __ats_lab_291_0 ; } __ats_lab_290_1: tmp1127 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1128 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1129 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var (tmp1127) ; tmp1130 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, tmp1128) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs (arg0, tmp988, arg2, tmp1129, tmp1130) ; break ; /* branch: __ats_lab_291 */ __ats_lab_291_0: if (((ats_sum_ptr_type)tmp989)->tag != 39) { goto __ats_lab_292_0 ; } __ats_lab_291_1: tmp1131 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; /* tmp987 = */ ccomp_exp_seq_tmpvar_93 (arg0, tmp1131, arg2) ; break ; /* branch: __ats_lab_292 */ __ats_lab_292_0: if (((ats_sum_ptr_type)tmp989)->tag != 42) { goto __ats_lab_293_0 ; } __ats_lab_292_1: tmp1132 = ats_caselptrlab_mac(anairiats_sum_18, tmp989, atslab_0) ; tmp1133 = ats_caselptrlab_mac(anairiats_sum_18, tmp989, atslab_1) ; tmp1134 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string (tmp1132, tmp1133) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1134) ; break ; /* branch: __ats_lab_293 */ __ats_lab_293_0: if (((ats_sum_ptr_type)tmp989)->tag != 45) { goto __ats_lab_294_0 ; } __ats_lab_293_1: tmp1136 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_hiexp_typ) ; tmp1135 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1136) ; tmp1137 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top (tmp1135) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1137) ; break ; /* branch: __ats_lab_294 */ __ats_lab_294_0: if (((ats_sum_ptr_type)tmp989)->tag != 46) { goto __ats_lab_295_0 ; } __ats_lab_294_1: tmp1138 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_0) ; tmp1139 = ats_caselptrlab_mac(anairiats_sum_4, tmp989, atslab_1) ; tmp1140 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* ats_ptr_type tmp1141 ; */ tmp1141 = (ats_sum_ptr_type)0 ; tmp1143 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp ((&tmp1141), tmp1138) ; /* tmp1142 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val ((&tmp1141), tmp988, arg2, tmp1143) ; tmp1144 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp1141) ; tmp1145 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp1146 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp1145) ; tmp1147 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp1146) ; tmp1148 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1148, atslab_0, tmp1147) ; tmp1149 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1148), atslab_1) ; tmp1150 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1149) = tmp1150 ; tmp1151 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp1151)->tag = 5 ; ats_selptrset_mac(anairiats_sum_5, tmp1151, atslab_0, tmp1147) ; tmp1152 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst (tmp1140, tmp1148, tmp1139, arg2, tmp1151) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_trywith (arg0, tmp988, tmp1144, tmp1146, tmp1152) ; break ; /* branch: __ats_lab_295 */ __ats_lab_295_0: if (((ats_sum_ptr_type)tmp989)->tag != 47) { goto __ats_lab_296_0 ; } __ats_lab_295_1: tmp1153 = ats_caselptrlab_mac(anairiats_sum_5, tmp989, atslab_0) ; tmp1154 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_exp_var (tmp1153) ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (arg0, tmp988, arg2, tmp1154) ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: __ats_lab_296_1: /* tmp1155 = */ prerr_loc_interror_2 (tmp988) ; /* tmp1156 = */ atspre_prerr_string (ATSstrcst(": ccomp_exp_tmpvar: hie0 = ")) ; /* tmp1157 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (arg1) ; /* tmp1158 = */ atspre_prerr_newline () ; /* tmp987 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp987) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 67743(line=2247, offs=3) -- 68138(line=2260, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1159) ; ATSlocal (ats_ptr_type, tmp1160) ; ATSlocal (ats_ptr_type, tmp1161) ; ATSlocal (ats_ptr_type, tmp1162) ; ATSlocal (ats_ptr_type, tmp1163) ; ATSlocal (ats_ptr_type, tmp1164) ; ATSlocal (ats_ptr_type, tmp1165) ; ATSlocal (ats_ptr_type, tmp1166) ; ATSlocal (ats_ptr_type, tmp1167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilab: tmp1160 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg1), atslab_hilab_node) ; do { /* branch: __ats_lab_297 */ __ats_lab_297_0: if (((ats_sum_ptr_type)tmp1160)->tag != 1) { goto __ats_lab_298_0 ; } __ats_lab_297_1: tmp1161 = ats_caselptrlab_mac(anairiats_sum_4, tmp1160, atslab_0) ; tmp1162 = ats_caselptrlab_mac(anairiats_sum_4, tmp1160, atslab_1) ; tmp1163 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1162) ; tmp1164 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_explstlst (arg0, tmp1161) ; tmp1159 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp1159)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp1159, atslab_0, tmp1164) ; ats_selptrset_mac(anairiats_sum_4, tmp1159, atslab_1, tmp1163) ; break ; /* branch: __ats_lab_298 */ __ats_lab_298_0: // if (((ats_sum_ptr_type)tmp1160)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_298_1: tmp1165 = ats_caselptrlab_mac(anairiats_sum_4, tmp1160, atslab_0) ; tmp1166 = ats_caselptrlab_mac(anairiats_sum_4, tmp1160, atslab_1) ; tmp1167 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1166) ; tmp1159 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp1159)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp1159, atslab_0, tmp1165) ; ats_selptrset_mac(anairiats_sum_4, tmp1159, atslab_1, tmp1167) ; break ; } while (0) ; return (tmp1159) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 68191(line=2264, offs=3) -- 68386(line=2270, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1168) ; ATSlocal (ats_ptr_type, tmp1169) ; ATSlocal (ats_ptr_type, tmp1170) ; ATSlocal (ats_ptr_type, tmp1171) ; ATSlocal (ats_ptr_type, tmp1172) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst: do { /* branch: __ats_lab_299 */ __ats_lab_299_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_300_0 ; } __ats_lab_299_1: tmp1169 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1170 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1171 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilab (arg0, tmp1169) ; tmp1172 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst (arg0, tmp1170) ; tmp1168 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1168, atslab_0, tmp1171) ; ats_selptrset_mac(anairiats_sum_1, tmp1168, atslab_1, tmp1172) ; break ; /* branch: __ats_lab_300 */ __ats_lab_300_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_300_1: tmp1168 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1168) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_hilablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 68439(line=2275, offs=4) -- 69497(line=2306, offs=2) */ ATSstaticdec() ats_ptr_type d2var_typ_ptr_get_98 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1173) ; ATSlocal (ats_ptr_type, tmp1174) ; ATSlocal (ats_ptr_type, tmp1175) ; ATSlocal (ats_ptr_type, tmp1176) ; // ATSlocal_void (tmp1177) ; // ATSlocal_void (tmp1178) ; // ATSlocal_void (tmp1179) ; // ATSlocal_void (tmp1180) ; ATSlocal (ats_ptr_type, tmp1181) ; ATSlocal (ats_ptr_type, tmp1182) ; ATSlocal (ats_ptr_type, tmp1183) ; // ATSlocal_void (tmp1184) ; // ATSlocal_void (tmp1185) ; // ATSlocal_void (tmp1186) ; // ATSlocal_void (tmp1187) ; ATSlocal (ats_ptr_type, tmp1188) ; ATSlocal (anairiats_rec_23, tmp1189) ; // ATSlocal_void (tmp1190) ; // ATSlocal_void (tmp1191) ; // ATSlocal_void (tmp1192) ; // ATSlocal_void (tmp1193) ; __ats_lab_d2var_typ_ptr_get_98: tmp1175 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (arg0) ; do { /* branch: __ats_lab_301 */ __ats_lab_301_0: if (tmp1175 == (ats_sum_ptr_type)0) { goto __ats_lab_302_0 ; } __ats_lab_301_1: tmp1176 = ats_caselptrlab_mac(anairiats_sum_3, tmp1175, atslab_0) ; tmp1174 = tmp1176 ; break ; /* branch: __ats_lab_302 */ __ats_lab_302_0: // if (tmp1175 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_302_1: /* tmp1177 = */ prerr_interror_1 () ; /* tmp1178 = */ atspre_prerr_string (ATSstrcst(": d2var_typ_ptr_get: d2v = ")) ; /* tmp1179 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg0) ; /* tmp1180 = */ atspre_prerr_newline () ; /* tmp1174 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1182 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (tmp1174) ; do { /* branch: __ats_lab_303 */ __ats_lab_303_0: if (tmp1182 == (ats_sum_ptr_type)0) { goto __ats_lab_304_0 ; } __ats_lab_303_1: tmp1183 = ats_caselptrlab_mac(anairiats_sum_3, tmp1182, atslab_0) ; tmp1181 = tmp1183 ; break ; /* branch: __ats_lab_304 */ __ats_lab_304_0: // if (tmp1182 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_304_1: /* tmp1184 = */ prerr_interror_1 () ; /* tmp1185 = */ atspre_prerr_string (ATSstrcst(": d2var_typ_ptr_get: d2v_view = ")) ; /* tmp1186 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp1174) ; /* tmp1187 = */ atspre_prerr_newline () ; /* tmp1181 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1188 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (tmp1181) ; do { /* branch: __ats_lab_305 */ __ats_lab_305_0: if (tmp1188 == (ats_sum_ptr_type)0) { goto __ats_lab_306_0 ; } __ats_lab_305_1: tmp1189 = ats_caselptrlab_mac(anairiats_sum_24, tmp1188, atslab_0) ; ATS_FREE(tmp1188) ; tmp1173 = ats_select_mac(tmp1189, atslab_0) ; break ; /* branch: __ats_lab_306 */ __ats_lab_306_0: // if (tmp1188 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_306_1: /* tmp1190 = */ prerr_interror_1 () ; /* tmp1191 = */ atspre_prerr_string (ATSstrcst(": d2var_typ_ptr_get: s2e_view = ")) ; /* tmp1192 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp1181) ; /* tmp1193 = */ atspre_prerr_newline () ; /* tmp1173 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp1173) ; } /* end of [d2var_typ_ptr_get_98] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 69557(line=2310, offs=5) -- 70229(line=2327, offs=4) */ ATSstaticdec() ats_ptr_type ccomp_fundeclst_init_99 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1194) ; ATSlocal (ats_ptr_type, tmp1195) ; ATSlocal (ats_ptr_type, tmp1196) ; ATSlocal (ats_ptr_type, tmp1197) ; ATSlocal (ats_ptr_type, tmp1198) ; // ATSlocal_void (tmp1199) ; ATSlocal (ats_ptr_type, tmp1200) ; ATSlocal (ats_ptr_type, tmp1201) ; ATSlocal (ats_ptr_type, tmp1202) ; ATSlocal (ats_ptr_type, tmp1203) ; ATSlocal (ats_ptr_type, tmp1204) ; ATSlocal (ats_ptr_type, tmp1205) ; // ATSlocal_void (tmp1206) ; ATSlocal (ats_ptr_type, tmp1207) ; __ats_lab_ccomp_fundeclst_init_99: do { /* branch: __ats_lab_307 */ __ats_lab_307_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_308_0 ; } __ats_lab_307_1: tmp1195 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1196 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1197 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp1195), atslab_hifundec_loc) ; tmp1198 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp1195), atslab_hifundec_var) ; /* tmp1199 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (tmp1198, arg0) ; tmp1201 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp1195), atslab_hifundec_loc) ; tmp1200 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp_some (tmp1201, tmp1198) ; tmp1203 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp1197, 1, tmp1200) ; tmp1202 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1203) ; tmp1204 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_var_typ (tmp1198, tmp1202) ; tmp1205 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (tmp1204) ; /* tmp1206 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp1198, tmp1205) ; tmp1207 = ccomp_fundeclst_init_99 (arg0, tmp1196) ; tmp1194 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1194, atslab_0, tmp1204) ; ats_selptrset_mac(anairiats_sum_1, tmp1194, atslab_1, tmp1207) ; break ; /* branch: __ats_lab_308 */ __ats_lab_308_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_308_1: tmp1194 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1194) ; } /* end of [ccomp_fundeclst_init_99] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 70493(line=2337, offs=8) -- 70990(line=2354, offs=8) */ ATSstaticdec() ats_void_type aux_push_101 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1211) ; ATSlocal (ats_ptr_type, tmp1212) ; ATSlocal (ats_ptr_type, tmp1213) ; // ATSlocal_void (tmp1214) ; __ats_lab_aux_push_101: tmp1213 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (arg0) ; tmp1212 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarlst_make (tmp1213) ; /* tmp1214 = */ atsopt_funlab_set_tailjoined (arg0, tmp1212) ; /* tmp1211 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (arg0, tmp1212) ; return /* (tmp1211) */ ; } /* end of [aux_push_101] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 71023(line=2355, offs=9) -- 71288(line=2362, offs=8) */ ATSstaticdec() ats_void_type auxlst_push_102 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1215) ; ATSlocal (ats_ptr_type, tmp1216) ; ATSlocal (ats_ptr_type, tmp1217) ; // ATSlocal_void (tmp1218) ; ATSlocal (ats_ptr_type, tmp1219) ; __ats_lab_auxlst_push_102: do { /* branch: __ats_lab_309 */ __ats_lab_309_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_310_0 ; } __ats_lab_309_1: tmp1216 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1217 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp1218 = */ aux_push_101 (tmp1216) ; tmp1219 = ats_ptrget_mac(ats_ptr_type, tmp1217) ; arg0 = tmp1219 ; goto __ats_lab_auxlst_push_102 ; // tail call break ; /* branch: __ats_lab_310 */ __ats_lab_310_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_310_1: break ; } while (0) ; return /* (tmp1215) */ ; } /* end of [auxlst_push_102] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 71396(line=2365, offs=8) -- 72017(line=2380, offs=8) */ ATSstaticdec() ats_ptr_type aux_ccomp_103 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1221) ; ATSlocal (ats_ptr_type, tmp1222) ; ATSlocal (ats_ptr_type, tmp1223) ; ATSlocal (ats_ptr_type, tmp1224) ; ATSlocal (ats_ptr_type, tmp1225) ; ATSlocal (ats_ptr_type, tmp1226) ; ATSlocal (ats_ptr_type, tmp1227) ; ATSlocal (ats_ptr_type, tmp1228) ; ATSlocal (ats_ptr_type, tmp1229) ; ATSlocal (ats_ptr_type, tmp1230) ; // ATSlocal_void (tmp1231) ; // ATSlocal_void (tmp1232) ; // ATSlocal_void (tmp1233) ; // ATSlocal_void (tmp1234) ; __ats_lab_aux_ccomp_103: tmp1222 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_hifundec_loc) ; tmp1223 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (arg1) ; tmp1224 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1224, atslab_0, tmp1223) ; tmp1225 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1224), atslab_1) ; tmp1226 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1225) = tmp1226 ; tmp1227 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_hifundec_def) ; tmp1228 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1227), atslab_hiexp_node) ; do { /* branch: __ats_lab_311 */ __ats_lab_311_0: if (((ats_sum_ptr_type)tmp1228)->tag != 22) { goto __ats_lab_312_0 ; } __ats_lab_311_1: tmp1229 = ats_caselptrlab_mac(anairiats_sum_4, tmp1228, atslab_0) ; tmp1230 = ats_caselptrlab_mac(anairiats_sum_4, tmp1228, atslab_1) ; tmp1221 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (tmp1222, tmp1224, tmp1229, tmp1230, arg1) ; break ; /* branch: __ats_lab_312 */ __ats_lab_312_0: __ats_lab_312_1: /* tmp1231 = */ prerr_interror_1 () ; /* tmp1232 = */ atspre_prerr_string (ATSstrcst(": ccomp_fntdeclst_main; aux_ccomp: hie_def = ")) ; /* tmp1233 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (tmp1227) ; /* tmp1234 = */ atspre_prerr_newline () ; /* tmp1221 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp1221) ; } /* end of [aux_ccomp_103] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 72048(line=2381, offs=9) -- 72467(line=2390, offs=39) */ ATSstaticdec() ats_ptr_type auxlst_ccomp_104 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1235) ; ATSlocal (ats_ptr_type, tmp1236) ; ATSlocal (ats_ptr_type, tmp1237) ; ATSlocal (ats_ptr_type, tmp1238) ; ATSlocal (ats_ptr_type, tmp1239) ; ATSlocal (ats_ptr_type, tmp1240) ; ATSlocal (ats_ptr_type, tmp1241) ; __ats_lab_auxlst_ccomp_104: do { /* branch: __ats_lab_313 */ __ats_lab_313_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_314_0 ; } __ats_lab_313_1: tmp1236 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1237 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; ATS_FREE(arg1) ; // if (arg0 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp1238 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1239 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1240 = aux_ccomp_103 (tmp1238, tmp1236) ; tmp1241 = auxlst_ccomp_104 (tmp1239, tmp1237) ; tmp1235 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1235, atslab_0, tmp1240) ; ats_selptrset_mac(anairiats_sum_1, tmp1235, atslab_1, tmp1241) ; break ; /* branch: __ats_lab_314 */ __ats_lab_314_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_314_1: tmp1235 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1235) ; } /* end of [auxlst_ccomp_104] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 70274(line=2331, offs=4) -- 72643(line=2396, offs=4) */ ATSstaticdec() ats_void_type ccomp_fntdeclst_main_100 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1208) ; // ATSlocal_void (tmp1209) ; // ATSlocal_void (tmp1210) ; // ATSlocal_void (tmp1220) ; ATSlocal (ats_ptr_type, tmp1242) ; // ATSlocal_void (tmp1243) ; __ats_lab_ccomp_fntdeclst_main_100: /* tmp1209 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp1210 = ats_selsin_mac(tmp1209, atslab_1) */ ; /* tmp1220 = */ auxlst_push_102 (arg2) ; tmp1242 = auxlst_ccomp_104 (arg1, arg2) ; /* tmp1243 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; /* tmp1208 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_tailjoin_funentrylst (arg0, tmp1242) ; return /* (tmp1208) */ ; } /* end of [ccomp_fntdeclst_main_100] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 72686(line=2400, offs=5) -- 73869(line=2429, offs=4) */ ATSstaticdec() ats_void_type ccomp_fundeclst_main_105 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1244) ; ATSlocal (ats_ptr_type, tmp1245) ; ATSlocal (ats_ptr_type, tmp1246) ; ATSlocal (ats_ptr_type, tmp1247) ; ATSlocal (ats_ptr_type, tmp1248) ; ATSlocal (ats_ptr_type, tmp1249) ; // ATSlocal_void (tmp1250) ; ATSlocal (ats_ptr_type, tmp1251) ; ATSlocal (ats_ptr_type, tmp1252) ; ATSlocal (ats_ptr_type, tmp1253) ; ATSlocal (ats_ptr_type, tmp1254) ; ATSlocal (ats_ptr_type, tmp1255) ; ATSlocal (ats_ptr_type, tmp1256) ; ATSlocal (ats_ptr_type, tmp1257) ; // ATSlocal_void (tmp1258) ; // ATSlocal_void (tmp1259) ; // ATSlocal_void (tmp1260) ; ATSlocal (ats_ptr_type, tmp1261) ; ATSlocal (ats_ptr_type, tmp1262) ; ATSlocal (ats_ptr_type, tmp1263) ; // ATSlocal_void (tmp1264) ; // ATSlocal_void (tmp1265) ; // ATSlocal_void (tmp1266) ; // ATSlocal_void (tmp1267) ; __ats_lab_ccomp_fundeclst_main_105: do { /* branch: __ats_lab_315 */ __ats_lab_315_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_318_0 ; } __ats_lab_315_1: tmp1245 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1246 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; ATS_FREE(arg1) ; // if (arg0 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp1247 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1248 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1249 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp1247), atslab_hifundec_def) ; tmp1251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1249), atslab_hiexp_node) ; do { /* branch: __ats_lab_316 */ __ats_lab_316_0: if (((ats_sum_ptr_type)tmp1251)->tag != 22) { goto __ats_lab_317_0 ; } __ats_lab_316_1: tmp1252 = ats_caselptrlab_mac(anairiats_sum_4, tmp1251, atslab_0) ; tmp1253 = ats_caselptrlab_mac(anairiats_sum_4, tmp1251, atslab_1) ; tmp1254 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (tmp1245) ; tmp1255 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1255, atslab_0, tmp1254) ; tmp1256 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1255), atslab_1) ; tmp1257 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1256) = tmp1257 ; /* tmp1258 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp1259 = ats_selsin_mac(tmp1258, atslab_1) */ ; tmp1261 = (ats_sum_ptr_type)0 ; /* tmp1260 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (tmp1245, tmp1261) ; tmp1263 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp1247), atslab_hifundec_loc) ; tmp1262 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (tmp1263, tmp1255, tmp1252, tmp1253, tmp1245) ; /* tmp1250 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; break ; /* branch: __ats_lab_317 */ __ats_lab_317_0: __ats_lab_317_1: /* tmp1264 = */ prerr_interror_1 () ; /* tmp1265 = */ atspre_prerr_string (ATSstrcst(": ccomp_fundeclst_main: hie_def = ")) ; /* tmp1266 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (tmp1249) ; /* tmp1267 = */ atspre_prerr_newline () ; /* tmp1250 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; arg0 = tmp1248 ; arg1 = tmp1246 ; goto __ats_lab_ccomp_fundeclst_main_105 ; // tail call break ; /* branch: __ats_lab_318 */ __ats_lab_318_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_318_1: break ; } while (0) ; return /* (tmp1244) */ ; } /* end of [ccomp_fundeclst_main_105] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 74046(line=2439, offs=7) -- 74742(line=2458, offs=6) */ ATSstaticdec() ats_void_type aux_107 (ats_int_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1269) ; ATSlocal (ats_ptr_type, tmp1270) ; ATSlocal (ats_ptr_type, tmp1271) ; ATSlocal (ats_ptr_type, tmp1272) ; ATSlocal (ats_ptr_type, tmp1273) ; ATSlocal (ats_ptr_type, tmp1274) ; ATSlocal (ats_ptr_type, tmp1275) ; ATSlocal (ats_ptr_type, tmp1276) ; ATSlocal (ats_ptr_type, tmp1277) ; // ATSlocal_void (tmp1278) ; // ATSlocal_void (tmp1279) ; // ATSlocal_void (tmp1280) ; __ats_lab_aux_107: do { /* branch: __ats_lab_319 */ __ats_lab_319_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_322_0 ; } __ats_lab_319_1: tmp1270 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1271 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1272 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1270), atslab_hivaldec_loc) ; tmp1274 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1270), atslab_hivaldec_def) ; tmp1273 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1274) ; tmp1275 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1270), atslab_hivaldec_pat) ; do { /* branch: __ats_lab_320 */ __ats_lab_320_0: if (((ats_sum_ptr_type)env1)->tag != 2) { goto __ats_lab_321_0 ; } __ats_lab_320_1: tmp1276 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; break ; /* branch: __ats_lab_321 */ __ats_lab_321_0: __ats_lab_321_1: tmp1277 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1270), atslab_hivaldec_loc) ; tmp1276 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp1276)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp1276, atslab_0, tmp1277) ; break ; } while (0) ; /* tmp1278 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp1273, tmp1275, tmp1276) ; /* tmp1279 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, env0, tmp1273, tmp1275) ; /* tmp1280 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free (arg0, tmp1272) ; arg0 = arg0 ; arg1 = tmp1271 ; goto __ats_lab_aux_107 ; // tail call break ; /* branch: __ats_lab_322 */ __ats_lab_322_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_322_1: break ; } while (0) ; return /* (tmp1269) */ ; } /* end of [aux_107] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_107_closure_type ; ats_void_type aux_107_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { aux_107 (((aux_107_closure_type*)cloptr)->closure_env_0, ((aux_107_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_107_closure_init (aux_107_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_107_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_107_closure_make (ats_int_type env0, ats_ptr_type env1) { aux_107_closure_type *p_clo = ATS_MALLOC(sizeof(aux_107_closure_type)) ; aux_107_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 73928(line=2433, offs=4) -- 74786(line=2461, offs=4) */ ATSstaticdec() ats_void_type ccomp_valdeclst_106 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp1268) ; __ats_lab_ccomp_valdeclst_106: /* tmp1268 = */ aux_107 (arg1, arg2, arg0, arg3) ; return /* (tmp1268) */ ; } /* end of [ccomp_valdeclst_106] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 74987(line=2469, offs=9) -- 75505(line=2481, offs=35) */ ATSstaticdec() ats_ptr_type aux1_109 (ats_int_type env0, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1282) ; ATSlocal (ats_ptr_type, tmp1283) ; ATSlocal (ats_ptr_type, tmp1284) ; ATSlocal (ats_ptr_type, tmp1285) ; ATSlocal (ats_ptr_type, tmp1286) ; ATSlocal (ats_ptr_type, tmp1287) ; ATSlocal (ats_ptr_type, tmp1288) ; ATSlocal (ats_ptr_type, tmp1289) ; // ATSlocal_void (tmp1290) ; ATSlocal (ats_ptr_type, tmp1291) ; __ats_lab_aux1_109: do { /* branch: __ats_lab_323 */ __ats_lab_323_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_324_0 ; } __ats_lab_323_1: tmp1283 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1284 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1285 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1283), atslab_hivaldec_pat) ; tmp1287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp1285), atslab_hipat_typ) ; tmp1286 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1287) ; tmp1288 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp1286) ; tmp1289 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp1288) ; /* tmp1290 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, env0, tmp1289, tmp1285) ; tmp1291 = aux1_109 (env0, arg0, tmp1284) ; tmp1282 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1282, atslab_0, tmp1288) ; ats_selptrset_mac(anairiats_sum_1, tmp1282, atslab_1, tmp1291) ; break ; /* branch: __ats_lab_324 */ __ats_lab_324_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_324_1: tmp1282 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1282) ; } /* end of [aux1_109] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux1_109_closure_type ; ats_ptr_type aux1_109_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { return aux1_109 (((aux1_109_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux1_109_closure_init (aux1_109_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux1_109_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux1_109_closure_make (ats_int_type env0) { aux1_109_closure_type *p_clo = ATS_MALLOC(sizeof(aux1_109_closure_type)) ; aux1_109_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 75600(line=2485, offs=9) -- 76005(line=2496, offs=26) */ ATSstaticdec() ats_void_type aux2_110 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1293) ; ATSlocal (ats_ptr_type, tmp1294) ; ATSlocal (ats_ptr_type, tmp1295) ; ATSlocal (ats_ptr_type, tmp1296) ; ATSlocal (ats_ptr_type, tmp1297) ; // ATSlocal_void (tmp1298) ; ATSlocal (ats_ptr_type, tmp1299) ; __ats_lab_aux2_110: do { /* branch: __ats_lab_325 */ __ats_lab_325_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_326_0 ; } __ats_lab_325_1: tmp1294 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1295 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp1296 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1297 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1299 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp1294), atslab_hivaldec_def) ; /* tmp1298 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, tmp1299, tmp1296) ; arg0 = arg0 ; arg1 = tmp1295 ; arg2 = tmp1297 ; goto __ats_lab_aux2_110 ; // tail call break ; /* branch: __ats_lab_326 */ __ats_lab_326_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_326_1: break ; } while (0) ; return /* (tmp1293) */ ; } /* end of [aux2_110] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 74840(line=2465, offs=4) -- 76047(line=2499, offs=2) */ ATSstaticdec() ats_void_type ccomp_valdeclst_rec_108 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1281) ; ATSlocal (ats_ptr_type, tmp1292) ; __ats_lab_ccomp_valdeclst_rec_108: tmp1292 = aux1_109 (arg1, arg0, arg2) ; /* tmp1281 = */ aux2_110 (arg0, arg2, tmp1292) ; return /* (tmp1281) */ ; } /* end of [ccomp_valdeclst_rec_108] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 76105(line=2503, offs=4) -- 76616(line=2517, offs=4) */ ATSstaticdec() ats_void_type ccomp_vardec_sta_111 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1300) ; ATSlocal (ats_ptr_type, tmp1301) ; ATSlocal (ats_ptr_type, tmp1302) ; // ATSlocal_void (tmp1303) ; ATSlocal (ats_ptr_type, tmp1304) ; ATSlocal (ats_ptr_type, tmp1305) ; ATSlocal (ats_ptr_type, tmp1306) ; ATSlocal (ats_ptr_type, tmp1307) ; // ATSlocal_void (tmp1308) ; // ATSlocal_void (tmp1309) ; ATSlocal (ats_ptr_type, tmp1310) ; ATSlocal (ats_ptr_type, tmp1311) ; ATSlocal (ats_ptr_type, tmp1312) ; __ats_lab_ccomp_vardec_sta_111: tmp1301 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_loc) ; tmp1302 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_ptr) ; /* tmp1303 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (tmp1302, arg1) ; tmp1304 = d2var_typ_ptr_get_98 (tmp1302) ; tmp1305 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp1301, 0, tmp1304) ; tmp1307 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1305) ; tmp1306 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp1307) ; /* tmp1308 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec (arg0, tmp1301, tmp1306) ; tmp1310 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref (tmp1306) ; /* tmp1309 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp1302, tmp1310) ; tmp1311 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_ini) ; do { /* branch: __ats_lab_327 */ __ats_lab_327_0: if (tmp1311 == (ats_sum_ptr_type)0) { goto __ats_lab_328_0 ; } __ats_lab_327_1: tmp1312 = ats_caselptrlab_mac(anairiats_sum_3, tmp1311, atslab_0) ; /* tmp1300 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar (arg0, tmp1312, tmp1306) ; break ; /* branch: __ats_lab_328 */ __ats_lab_328_0: // if (tmp1311 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_328_1: break ; } while (0) ; return /* (tmp1300) */ ; } /* end of [ccomp_vardec_sta_111] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 76672(line=2521, offs=5) -- 76848(line=2526, offs=15) */ ATSstaticdec() ats_bool_type hiexp_is_laminit_112 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp1313) ; ATSlocal (ats_ptr_type, tmp1314) ; ATSlocal (ats_ptr_type, tmp1315) ; __ats_lab_hiexp_is_laminit_112: tmp1314 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_hiexp_node) ; do { /* branch: __ats_lab_329 */ __ats_lab_329_0: if (((ats_sum_ptr_type)tmp1314)->tag != 23) { goto __ats_lab_330_0 ; } __ats_lab_329_1: tmp1313 = ats_true_bool ; break ; /* branch: __ats_lab_330 */ __ats_lab_330_0: if (((ats_sum_ptr_type)tmp1314)->tag != 15) { goto __ats_lab_331_0 ; } __ats_lab_330_1: tmp1315 = ats_caselptrlab_mac(anairiats_sum_7, tmp1314, atslab_2) ; arg0 = tmp1315 ; goto __ats_lab_hiexp_is_laminit_112 ; // tail call break ; /* branch: __ats_lab_331 */ __ats_lab_331_0: __ats_lab_331_1: tmp1313 = ats_false_bool ; break ; } while (0) ; return (tmp1313) ; } /* end of [hiexp_is_laminit_112] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 77721(line=2554, offs=6) -- 79371(line=2602, offs=10) */ ATSstaticdec() ats_void_type aux_laminit_114 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp1334) ; ATSlocal (ats_ptr_type, tmp1335) ; ATSlocal (ats_ptr_type, tmp1336) ; ATSlocal (ats_ptr_type, tmp1337) ; ATSlocal (ats_ptr_type, tmp1338) ; ATSlocal (ats_ptr_type, tmp1339) ; ATSlocal (ats_ptr_type, tmp1340) ; ATSlocal (ats_ptr_type, tmp1341) ; ATSlocal (ats_ptr_type, tmp1343) ; ATSlocal (ats_ptr_type, tmp1344) ; // ATSlocal_void (tmp1345) ; // ATSlocal_void (tmp1346) ; // ATSlocal_void (tmp1347) ; ATSlocal (ats_ptr_type, tmp1348) ; ATSlocal (ats_ptr_type, tmp1349) ; ATSlocal (ats_ptr_type, tmp1350) ; ATSlocal (ats_ptr_type, tmp1351) ; ATSlocal (ats_ptr_type, tmp1352) ; ATSlocal (ats_ptr_type, tmp1353) ; // ATSlocal_void (tmp1354) ; ATSlocal (ats_ptr_type, tmp1355) ; ATSlocal (ats_bool_type, tmp1356) ; ATSlocal (ats_ptr_type, tmp1357) ; ATSlocal (ats_ptr_type, tmp1358) ; ATSlocal (ats_ptr_type, tmp1359) ; // ATSlocal_void (tmp1361) ; // ATSlocal_void (tmp1362) ; // ATSlocal_void (tmp1363) ; __ats_lab_aux_laminit_114: tmp1335 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_node) ; do { /* branch: __ats_lab_334 */ __ats_lab_334_0: if (((ats_sum_ptr_type)tmp1335)->tag != 23) { goto __ats_lab_337_0 ; } __ats_lab_334_1: tmp1336 = ats_caselptrlab_mac(anairiats_sum_4, tmp1335, atslab_0) ; tmp1337 = ats_caselptrlab_mac(anairiats_sum_4, tmp1335, atslab_1) ; tmp1338 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_loc) ; tmp1340 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_typ) ; tmp1339 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1340) ; tmp1341 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ (tmp1339) ; do { /* branch: __ats_lab_335 */ __ats_lab_335_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_336_0 ; } __ats_lab_335_1: tmp1343 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; ATS_FREE(arg4) ; tmp1344 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun (tmp1341) ; ats_ptrget_mac(ats_ptr_type, tmp1343) = tmp1344 ; break ; /* branch: __ats_lab_336 */ __ats_lab_336_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_336_1: break ; } while (0) ; /* tmp1345 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp1346 = ats_selsin_mac(tmp1345, atslab_1) */ ; tmp1348 = (ats_sum_ptr_type)0 ; /* tmp1347 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (tmp1341, tmp1348) ; tmp1349 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (tmp1341) ; tmp1350 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1350, atslab_0, tmp1349) ; tmp1351 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1350), atslab_1) ; tmp1352 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1351) = tmp1352 ; tmp1353 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (tmp1338, tmp1350, tmp1336, tmp1337, tmp1341) ; /* tmp1354 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; tmp1356 = atspre_gt_int_int (arg1, 0) ; if (tmp1356) { tmp1355 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_cltype (tmp1341) ; } else { tmp1355 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo ; } /* end of [if] */ tmp1357 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp1355) ; tmp1358 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp1357) ; tmp1359 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__cloenv_make () ; /* tmp1334 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_clo (arg0, tmp1338, arg2, tmp1358, tmp1341, tmp1359) ; break ; /* branch: __ats_lab_337 */ __ats_lab_337_0: __ats_lab_337_1: do { /* branch: __ats_lab_338 */ __ats_lab_338_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_339_0 ; } __ats_lab_338_1: ATS_FREE(arg4) ; break ; /* branch: __ats_lab_339 */ __ats_lab_339_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_339_1: break ; } while (0) ; /* tmp1361 = */ prerr_interror_1 () ; /* tmp1362 = */ atspre_prerr_string (ATSstrcst(": aux_laminit: match failure")) ; /* tmp1363 = */ atspre_prerr_newline () ; /* tmp1334 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp1334) */ ; } /* end of [aux_laminit_114] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 79423(line=2605, offs=6) -- 80384(line=2633, offs=10) */ ATSstaticdec() ats_void_type aux_lamfixinit_115 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp1364) ; ATSlocal (ats_ptr_type, tmp1365) ; ATSlocal (ats_ptr_type, tmp1366) ; ATSlocal (ats_ptr_type, tmp1367) ; ATSlocal (ats_ptr_type, tmp1368) ; ATSlocal (ats_ptr_type, tmp1369) ; ATSlocal (ats_ptr_type, tmp1370) ; ATSlocal (ats_ptr_type, tmp1371) ; // ATSlocal_void (tmp1372) ; // ATSlocal_void (tmp1373) ; // ATSlocal_void (tmp1374) ; // ATSlocal_void (tmp1375) ; ATSlocal (ats_ptr_type, tmp1376) ; // ATSlocal_void (tmp1377) ; // ATSlocal_void (tmp1378) ; // ATSlocal_void (tmp1379) ; __ats_lab_aux_lamfixinit_115: tmp1365 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg3), atslab_hiexp_node) ; do { /* branch: __ats_lab_340 */ __ats_lab_340_0: if (((ats_sum_ptr_type)tmp1365)->tag != 23) { goto __ats_lab_341_0 ; } __ats_lab_340_1: tmp1366 = (ats_sum_ptr_type)0 ; /* tmp1364 = */ aux_laminit_114 (arg0, arg1, arg2, arg3, tmp1366) ; break ; /* branch: __ats_lab_341 */ __ats_lab_341_0: if (((ats_sum_ptr_type)tmp1365)->tag != 15) { goto __ats_lab_342_0 ; } __ats_lab_341_1: tmp1367 = ats_caselptrlab_mac(anairiats_sum_7, tmp1365, atslab_1) ; tmp1368 = ats_caselptrlab_mac(anairiats_sum_7, tmp1365, atslab_2) ; tmp1369 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; tmp1370 = ref_make_elt_04328_ats_ptr_type (tmp1369) ; tmp1371 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix (tmp1370, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_ptr) ; /* tmp1372 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_mark () ; /* tmp1373 = ats_selsin_mac(tmp1372, atslab_1) */ ; /* tmp1374 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp1367, tmp1371) ; tmp1376 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp1376, atslab_0, tmp1370) ; /* tmp1375 = */ aux_laminit_114 (arg0, arg1, arg2, tmp1368, tmp1376) ; /* tmp1364 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_unmark () ; break ; /* branch: __ats_lab_342 */ __ats_lab_342_0: __ats_lab_342_1: /* tmp1377 = */ prerr_interror_1 () ; /* tmp1378 = */ atspre_prerr_string (ATSstrcst(": aux_lamfixinit: match failure")) ; /* tmp1379 = */ atspre_prerr_newline () ; /* tmp1364 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp1364) */ ; } /* end of [aux_lamfixinit_115] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 76882(line=2529, offs=4) -- 81110(line=2657, offs=4) */ ATSstaticdec() ats_void_type ccomp_vardec_dyn_113 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1316) ; ATSlocal (ats_ptr_type, tmp1317) ; ATSlocal (ats_ptr_type, tmp1318) ; // ATSlocal_void (tmp1319) ; ATSlocal (ats_ptr_type, tmp1320) ; ATSlocal (ats_ptr_type, tmp1321) ; ATSlocal (ats_ptr_type, tmp1322) ; ATSlocal (ats_ptr_type, tmp1323) ; ATSlocal (ats_ptr_type, tmp1324) ; // ATSlocal_void (tmp1325) ; // ATSlocal_void (tmp1326) ; ATSlocal (ats_ptr_type, tmp1327) ; ATSlocal (ats_ptr_type, tmp1328) ; ATSlocal (ats_ptr_type, tmp1329) ; ATSlocal (ats_ptr_type, tmp1330) ; // ATSlocal_void (tmp1331) ; // ATSlocal_void (tmp1332) ; // ATSlocal_void (tmp1333) ; ATSlocal (ats_ptr_type, tmp1380) ; ATSlocal (ats_ptr_type, tmp1381) ; ATSlocal (ats_ptr_type, tmp1382) ; ATSlocal (ats_ptr_type, tmp1383) ; ATSlocal (ats_ptr_type, tmp1384) ; ATSlocal (ats_ptr_type, tmp1385) ; ATSlocal (ats_bool_type, tmp1386) ; // ATSlocal_void (tmp1387) ; // ATSlocal_void (tmp1388) ; // ATSlocal_void (tmp1389) ; // ATSlocal_void (tmp1390) ; __ats_lab_ccomp_vardec_dyn_113: tmp1317 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_loc) ; tmp1318 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_ptr) ; /* tmp1319 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (tmp1318, arg1) ; tmp1321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc (tmp1318) ; tmp1320 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (tmp1321, tmp1318) ; tmp1322 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp1317, 0, tmp1320) ; tmp1324 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1322) ; tmp1323 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp1324) ; /* tmp1325 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec (arg0, tmp1317, tmp1323) ; tmp1327 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (tmp1323) ; /* tmp1326 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp1318, tmp1327) ; tmp1329 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_ini) ; do { /* branch: __ats_lab_332 */ __ats_lab_332_0: if (tmp1329 == (ats_sum_ptr_type)0) { goto __ats_lab_333_0 ; } __ats_lab_332_1: tmp1330 = ats_caselptrlab_mac(anairiats_sum_3, tmp1329, atslab_0) ; tmp1328 = tmp1330 ; break ; /* branch: __ats_lab_333 */ __ats_lab_333_0: __ats_lab_333_1: /* tmp1331 = */ prerr_loc_interror_2 (tmp1317) ; /* tmp1332 = */ atspre_prerr_string (ATSstrcst(": ccomp_vardec_dyn: no initialization.")) ; /* tmp1333 = */ atspre_prerr_newline () ; /* tmp1328 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1380 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1328), atslab_hiexp_node) ; do { /* branch: __ats_lab_343 */ __ats_lab_343_0: if (((ats_sum_ptr_type)tmp1380)->tag != 1) { goto __ats_lab_344_0 ; } __ats_lab_343_1: tmp1381 = ats_caselptrlab_mac(anairiats_sum_8, tmp1380, atslab_0) ; tmp1382 = ats_caselptrlab_mac(anairiats_sum_8, tmp1380, atslab_1) ; tmp1383 = ats_caselptrlab_mac(anairiats_sum_8, tmp1380, atslab_2) ; tmp1384 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1328), atslab_hiexp_loc) ; tmp1385 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1381) ; /* tmp1316 = */ ccomp_exp_arrinit_tmpvar_89 (arg0, tmp1384, arg1, tmp1385, tmp1382, tmp1383, tmp1323) ; break ; /* branch: __ats_lab_344 */ __ats_lab_344_0: __ats_lab_344_1: tmp1386 = hiexp_is_laminit_112 (tmp1328) ; if (!tmp1386) { goto __ats_lab_345_1 ; } /* tmp1316 = */ aux_lamfixinit_115 (arg0, arg1, tmp1323, tmp1328) ; break ; /* branch: __ats_lab_345 */ __ats_lab_345_0: __ats_lab_345_1: /* tmp1387 = */ prerr_interror_1 () ; /* tmp1388 = */ atspre_prerr_string (ATSstrcst(": ccomp_vardec_dyn: hie_ini = ")) ; /* tmp1389 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (tmp1328) ; /* tmp1390 = */ atspre_prerr_newline () ; /* tmp1316 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp1316) */ ; } /* end of [ccomp_vardec_dyn_113] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 81144(line=2659, offs=4) -- 81409(line=2667, offs=4) */ ATSstaticdec() ats_void_type ccomp_vardec_116 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1391) ; ATSlocal (ats_int_type, tmp1392) ; ATSlocal (ats_bool_type, tmp1393) ; __ats_lab_ccomp_vardec_116: tmp1392 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg2), atslab_hivardec_knd) ; do { /* branch: __ats_lab_346 */ __ats_lab_346_0: __ats_lab_346_1: tmp1393 = atspre_eq_int_int (tmp1392, 0) ; if (!tmp1393) { goto __ats_lab_347_1 ; } /* tmp1391 = */ ccomp_vardec_sta_111 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_347 */ __ats_lab_347_0: __ats_lab_347_1: /* tmp1391 = */ ccomp_vardec_dyn_113 (arg0, arg1, arg2) ; break ; } while (0) ; return /* (tmp1391) */ ; } /* end of [ccomp_vardec_116] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 81563(line=2676, offs=7) -- 81830(line=2683, offs=24) */ ATSstaticdec() ats_void_type aux_118 (ats_int_type env0, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1395) ; ATSlocal (ats_ptr_type, tmp1396) ; ATSlocal (ats_ptr_type, tmp1397) ; // ATSlocal_void (tmp1398) ; __ats_lab_aux_118: do { /* branch: __ats_lab_348 */ __ats_lab_348_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_349_0 ; } __ats_lab_348_1: tmp1396 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1397 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp1398 = */ ccomp_vardec_116 (arg0, env0, tmp1396) ; arg0 = arg0 ; arg1 = tmp1397 ; goto __ats_lab_aux_118 ; // tail call break ; /* branch: __ats_lab_349 */ __ats_lab_349_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_349_1: break ; } while (0) ; return /* (tmp1395) */ ; } /* end of [aux_118] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux_118_closure_type ; ats_void_type aux_118_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { aux_118 (((aux_118_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_118_closure_init (aux_118_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_118_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_118_closure_make (ats_int_type env0) { aux_118_closure_type *p_clo = ATS_MALLOC(sizeof(aux_118_closure_type)) ; aux_118_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 81460(line=2671, offs=4) -- 81876(line=2687, offs=4) */ ATSstaticdec() ats_void_type ccomp_vardeclst_117 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1394) ; __ats_lab_ccomp_vardeclst_117: /* tmp1394 = */ aux_118 (arg1, arg0, arg2) ; return /* (tmp1394) */ ; } /* end of [ccomp_vardeclst_117] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 82005(line=2696, offs=5) -- 85104(line=2809, offs=4) */ ATSstaticdec() ats_void_type aux_120 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp1400) ; ATSlocal (ats_ptr_type, tmp1401) ; ATSlocal (ats_ptr_type, tmp1402) ; ATSlocal (ats_ptr_type, tmp1403) ; ATSlocal (ats_bool_type, tmp1404) ; ATSlocal (ats_ptr_type, tmp1405) ; ATSlocal (ats_ptr_type, tmp1406) ; ATSlocal (ats_ptr_type, tmp1407) ; ATSlocal (ats_ptr_type, tmp1408) ; ATSlocal (ats_ptr_type, tmp1409) ; // ATSlocal_void (tmp1410) ; // ATSlocal_void (tmp1411) ; ATSlocal (ats_bool_type, tmp1412) ; ATSlocal (ats_ptr_type, tmp1413) ; ATSlocal (ats_ptr_type, tmp1414) ; // ATSlocal_void (tmp1415) ; // ATSlocal_void (tmp1416) ; // ATSlocal_void (tmp1417) ; // ATSlocal_void (tmp1418) ; // ATSlocal_void (tmp1419) ; ATSlocal (ats_ptr_type, tmp1420) ; ATSlocal (ats_ptr_type, tmp1421) ; ATSlocal (ats_ptr_type, tmp1422) ; ATSlocal (ats_ptr_type, tmp1423) ; ATSlocal (ats_ptr_type, tmp1424) ; ATSlocal (ats_ptr_type, tmp1425) ; ATSlocal (ats_ptr_type, tmp1426) ; ATSlocal (ats_ptr_type, tmp1427) ; ATSlocal (ats_ptr_type, tmp1428) ; ATSlocal (ats_bool_type, tmp1429) ; ATSlocal (ats_ptr_type, tmp1430) ; ATSlocal (ats_ptr_type, tmp1431) ; ATSlocal (ats_ptr_type, tmp1432) ; // ATSlocal_void (tmp1433) ; ATSlocal (ats_ptr_type, tmp1434) ; ATSlocal (ats_bool_type, tmp1435) ; ATSlocal (ats_ptr_type, tmp1436) ; ATSlocal (ats_ptr_type, tmp1437) ; // ATSlocal_void (tmp1438) ; // ATSlocal_void (tmp1439) ; // ATSlocal_void (tmp1440) ; // ATSlocal_void (tmp1441) ; __ats_lab_aux_120: tmp1401 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg4), atslab_hiexp_node) ; do { /* branch: __ats_lab_350 */ __ats_lab_350_0: if (((ats_sum_ptr_type)tmp1401)->tag != 22) { goto __ats_lab_357_0 ; } __ats_lab_350_1: tmp1402 = ats_caselptrlab_mac(anairiats_sum_4, tmp1401, atslab_0) ; tmp1403 = ats_caselptrlab_mac(anairiats_sum_4, tmp1401, atslab_1) ; tmp1404 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (arg2) ; if (!tmp1404) { goto __ats_lab_358_1 ; } tmp1406 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg4), atslab_hiexp_typ) ; tmp1405 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1406) ; tmp1407 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_typ (arg2, arg3, tmp1405) ; tmp1408 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (tmp1407) ; tmp1409 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (tmp1407) ; /* tmp1410 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add (arg2, tmp1409) ; do { /* branch: __ats_lab_351 */ __ats_lab_351_0: __ats_lab_351_1: tmp1412 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (arg3) ; if (!tmp1412) { goto __ats_lab_352_1 ; } tmp1413 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name (tmp1407) ; /* tmp1411 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add (tmp1413, tmp1409) ; break ; /* branch: __ats_lab_352 */ __ats_lab_352_0: __ats_lab_352_1: tmp1414 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_kind (arg2) ; do { /* branch: __ats_lab_353 */ __ats_lab_353_0: if (((ats_sum_ptr_type)tmp1414)->tag != 1) { goto __ats_lab_356_0 ; } __ats_lab_353_1: do { /* branch: __ats_lab_354 */ __ats_lab_354_0: if (tmp1408 != (ats_sum_ptr_type)0) { goto __ats_lab_355_0 ; } __ats_lab_354_1: /* tmp1415 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_fun (arg2) ; /* tmp1411 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_fun (arg0, arg1, arg2, tmp1407) ; break ; /* branch: __ats_lab_355 */ __ats_lab_355_0: // if (tmp1408 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_355_1: /* tmp1416 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_clo (arg2) ; /* tmp1411 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_clo (arg0, arg1, arg2, tmp1407) ; break ; } while (0) ; break ; /* branch: __ats_lab_356 */ __ats_lab_356_0: __ats_lab_356_1: break ; } while (0) ; break ; } while (0) ; /* tmp1417 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () ; /* tmp1418 = ats_selsin_mac(tmp1417, atslab_1) */ ; tmp1420 = (ats_sum_ptr_type)0 ; /* tmp1419 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (tmp1407, tmp1420) ; tmp1421 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg4), atslab_hiexp_loc) ; tmp1422 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (tmp1407) ; tmp1423 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1423, atslab_0, tmp1422) ; tmp1424 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1423), atslab_1) ; tmp1425 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1424) = tmp1425 ; tmp1426 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_arg_body_funlab (tmp1421, tmp1423, tmp1402, tmp1403, tmp1407) ; /* tmp1400 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () ; break ; /* branch: __ats_lab_357 */ __ats_lab_357_0: if (((ats_sum_ptr_type)tmp1401)->tag != 15) { goto __ats_lab_358_0 ; } __ats_lab_357_1: tmp1427 = ats_caselptrlab_mac(anairiats_sum_7, tmp1401, atslab_1) ; tmp1428 = ats_caselptrlab_mac(anairiats_sum_7, tmp1401, atslab_2) ; tmp1429 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_lam (tmp1428) ; if (!tmp1429) { goto __ats_lab_358_1 ; } tmp1431 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg4), atslab_hiexp_typ) ; tmp1430 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1431) ; tmp1432 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst (arg2, tmp1430) ; /* tmp1433 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_add (tmp1427, tmp1432) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp1428 ; goto __ats_lab_aux_120 ; // tail call break ; /* branch: __ats_lab_358 */ __ats_lab_358_0: __ats_lab_358_1: tmp1434 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, arg4) ; do { /* branch: __ats_lab_359 */ __ats_lab_359_0: __ats_lab_359_1: tmp1435 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (arg3) ; if (!tmp1435) { goto __ats_lab_360_1 ; } tmp1436 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize (arg3) ; tmp1437 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make (arg2, tmp1436) ; /* tmp1438 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpnamtbl_add (tmp1437, tmp1434) ; /* tmp1439 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_add (tmp1437, tmp1434) ; /* tmp1400 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_partval (arg0, arg1, tmp1437, tmp1434) ; break ; /* branch: __ats_lab_360 */ __ats_lab_360_0: __ats_lab_360_1: /* tmp1440 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add (arg2, tmp1434) ; /* tmp1441 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_val (arg2, tmp1434) ; /* tmp1400 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_val (arg0, arg1, arg2, tmp1434) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp1400) */ ; } /* end of [aux_120] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 81930(line=2691, offs=4) -- 85723(line=2837, offs=4) */ ATSstaticdec() ats_void_type ccomp_impdec_119 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1399) ; ATSlocal (ats_ptr_type, tmp1442) ; ATSlocal (ats_bool_type, tmp1443) ; ATSlocal (ats_ptr_type, tmp1444) ; ATSlocal (ats_ptr_type, tmp1445) ; ATSlocal (ats_ptr_type, tmp1446) ; ATSlocal (ats_ptr_type, tmp1447) ; __ats_lab_ccomp_impdec_119: tmp1442 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_hiimpdec_cst) ; do { /* branch: __ats_lab_361 */ __ats_lab_361_0: __ats_lab_361_1: tmp1443 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn (tmp1442) ; if (!tmp1443) { goto __ats_lab_362_1 ; } break ; /* branch: __ats_lab_362 */ __ats_lab_362_0: __ats_lab_362_1: tmp1444 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_hiimpdec_decarg) ; do { /* branch: __ats_lab_363 */ __ats_lab_363_0: if (tmp1444 == (ats_sum_ptr_type)0) { goto __ats_lab_364_0 ; } __ats_lab_363_1: break ; /* branch: __ats_lab_364 */ __ats_lab_364_0: // if (tmp1444 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_364_1: tmp1445 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_hiimpdec_loc) ; tmp1446 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_hiimpdec_tmparg) ; tmp1447 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_hiimpdec_def) ; /* tmp1399 = */ aux_120 (arg0, tmp1445, tmp1442, tmp1446, tmp1447) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp1399) */ ; } /* end of [ccomp_impdec_119] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 86455(line=2872, offs=6) -- 86870(line=2885, offs=6) */ ATSstaticdec() ats_void_type f_122 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1458) ; ATSlocal (ats_bool_type, tmp1459) ; ATSlocal (ats_bool_type, tmp1460) ; ATSlocal (ats_ptr_type, tmp1461) ; ATSlocal (ats_ptr_type, tmp1462) ; ATSlocal (ats_ptr_type, tmp1463) ; ATSlocal (ats_bool_type, tmp1464) ; ATSlocal (ats_ptr_type, tmp1465) ; ATSlocal (ats_ptr_type, tmp1466) ; ATSlocal (ats_ptr_type, tmp1467) ; __ats_lab_f_122: do { /* branch: __ats_lab_365 */ __ats_lab_365_0: __ats_lab_365_1: tmp1459 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi (arg0) ; if (!tmp1459) { goto __ats_lab_366_1 ; } break ; /* branch: __ats_lab_366 */ __ats_lab_366_0: __ats_lab_366_1: tmp1460 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun (arg0) ; if (!tmp1460) { goto __ats_lab_367_1 ; } tmp1462 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst (arg0) ; tmp1463 = ats_ptrget_mac(ats_ptr_type, arg1) ; tmp1461 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1461, atslab_0, tmp1462) ; ats_selptrset_mac(anairiats_sum_1, tmp1461, atslab_1, tmp1463) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1461 ; break ; /* branch: __ats_lab_367 */ __ats_lab_367_0: __ats_lab_367_1: tmp1464 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval (arg0) ; if (!tmp1464) { goto __ats_lab_368_1 ; } tmp1466 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst (arg0) ; tmp1467 = ats_ptrget_mac(ats_ptr_type, arg1) ; tmp1465 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1465, atslab_0, tmp1466) ; ats_selptrset_mac(anairiats_sum_1, tmp1465, atslab_1, tmp1467) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1465 ; break ; /* branch: __ats_lab_368 */ __ats_lab_368_0: __ats_lab_368_1: break ; } while (0) ; return /* (tmp1458) */ ; } /* end of [f_122] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 85818(line=2843, offs=4) -- 87280(line=2902, offs=4) */ ATSstaticdec() ats_void_type ccomp_impdec_prfck_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1448) ; ATSlocal (ats_ptr_type, tmp1449) ; ATSlocal (ats_ptr_type, tmp1450) ; // ATSlocal_void (tmp1451) ; // ATSlocal_void (tmp1452) ; // ATSlocal_void (tmp1453) ; ATSlocal (ats_ptr_type, tmp1454) ; ATSlocal (ats_ptr_type, tmp1455) ; ATSlocal (ats_ptr_type, tmp1456) ; ATSlocal (ats_ptr_type, tmp1457) ; // ATSlocal_void (tmp1468) ; ATSlocal (ats_ptr_type, tmp1469) ; ATSlocal (ats_ptr_type, tmp1470) ; ATSlocal (ats_ptr_type, tmp1471) ; ATSlocal (ats_ptr_type, tmp1472) ; // ATSlocal_void (tmp1473) ; // ATSlocal_void (tmp1474) ; __ats_lab_ccomp_impdec_prfck_121: tmp1449 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_prfck (arg1) ; tmp1450 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (tmp1449) ; /* tmp1451 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push (tmp1449) ; /* tmp1452 = ats_selsin_mac(tmp1451, atslab_1) */ ; /* tmp1453 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst (tmp1449) ; tmp1454 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_beg (arg1) ; /* ats_ptr_type tmp1455 ; */ tmp1456 = (ats_sum_ptr_type)0 ; tmp1455 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1455, atslab_0, tmp1454) ; ats_selptrset_mac(anairiats_sum_1, tmp1455, atslab_1, tmp1456) ; tmp1457 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; /* tmp1468 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main (arg2, &f_122, (&tmp1455)) ; tmp1469 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_end (arg1) ; tmp1470 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1470, atslab_0, tmp1469) ; ats_selptrset_mac(anairiats_sum_1, tmp1470, atslab_1, tmp1455) ; tmp1471 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp1470) ; tmp1472 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make (arg0, tmp1449, 0, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil, tmp1457, tmp1471) ; /* tmp1473 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate (tmp1472) ; /* tmp1474 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop () ; /* tmp1448 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add (arg1, tmp1450) ; return /* (tmp1448) */ ; } /* end of [ccomp_impdec_prfck_121] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 87354(line=2907, offs=11) -- 90782(line=3005, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_dec (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1475) ; ATSlocal (ats_ptr_type, tmp1476) ; ATSlocal (ats_ptr_type, tmp1477) ; ATSlocal (ats_ptr_type, tmp1478) ; ATSlocal (ats_ptr_type, tmp1479) ; ATSlocal (ats_ptr_type, tmp1480) ; ATSlocal (ats_ptr_type, tmp1481) ; ATSlocal (ats_bool_type, tmp1482) ; ATSlocal (ats_ptr_type, tmp1483) ; ATSlocal (ats_ptr_type, tmp1484) ; ATSlocal (ats_bool_type, tmp1485) ; ATSlocal (ats_ptr_type, tmp1486) ; ATSlocal (ats_ptr_type, tmp1487) ; ATSlocal (ats_ptr_type, tmp1488) ; ATSlocal (ats_ptr_type, tmp1489) ; ATSlocal (ats_ptr_type, tmp1490) ; ATSlocal (ats_ptr_type, tmp1491) ; ATSlocal (ats_ptr_type, tmp1492) ; // ATSlocal_void (tmp1493) ; ATSlocal (ats_int_type, tmp1494) ; ATSlocal (ats_ptr_type, tmp1495) ; ATSlocal (ats_ptr_type, tmp1496) ; ATSlocal (ats_ptr_type, tmp1497) ; ATSlocal (ats_ptr_type, tmp1498) ; ATSlocal (ats_int_type, tmp1499) ; ATSlocal (ats_ptr_type, tmp1500) ; ATSlocal (ats_ptr_type, tmp1501) ; ATSlocal (ats_bool_type, tmp1502) ; ATSlocal (ats_ptr_type, tmp1503) ; ATSlocal (ats_ptr_type, tmp1504) ; ATSlocal (ats_int_type, tmp1505) ; ATSlocal (ats_ptr_type, tmp1506) ; ATSlocal (ats_int_type, tmp1507) ; ATSlocal (ats_ptr_type, tmp1508) ; ATSlocal (ats_int_type, tmp1509) ; ATSlocal (ats_ptr_type, tmp1510) ; ATSlocal (ats_ptr_type, tmp1511) ; ATSlocal (ats_ptr_type, tmp1512) ; ATSlocal (ats_ptr_type, tmp1513) ; ATSlocal (ats_ptr_type, tmp1514) ; ATSlocal (ats_ptr_type, tmp1515) ; ATSlocal (ats_ptr_type, tmp1516) ; // ATSlocal_void (tmp1517) ; ATSlocal (ats_ptr_type, tmp1518) ; // ATSlocal_void (tmp1519) ; ATSlocal (ats_ptr_type, tmp1520) ; ATSlocal (ats_int_type, tmp1521) ; ATSlocal (ats_ptr_type, tmp1522) ; // ATSlocal_void (tmp1523) ; // ATSlocal_void (tmp1524) ; // ATSlocal_void (tmp1525) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_dec: tmp1476 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_hidec_loc) ; tmp1477 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_hidec_node) ; do { /* branch: __ats_lab_369 */ __ats_lab_369_0: if (((ats_sum_ptr_type)tmp1477)->tag != 1) { goto __ats_lab_370_0 ; } __ats_lab_369_1: tmp1478 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; tmp1479 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp1478), atslab_s2aspdec_cst) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_add (tmp1479) ; break ; /* branch: __ats_lab_370 */ __ats_lab_370_0: if (((ats_sum_ptr_type)tmp1477)->tag != 2) { goto __ats_lab_373_0 ; } __ats_lab_370_1: tmp1480 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1481 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; do { /* branch: __ats_lab_371 */ __ats_lab_371_0: __ats_lab_371_1: tmp1482 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (tmp1480) ; if (!tmp1482) { goto __ats_lab_372_1 ; } break ; /* branch: __ats_lab_372 */ __ats_lab_372_0: __ats_lab_372_1: /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp1481, &atsopt_the_dyncstset_add_if) ; break ; } while (0) ; break ; /* branch: __ats_lab_373 */ __ats_lab_373_0: if (((ats_sum_ptr_type)tmp1477)->tag != 3) { goto __ats_lab_376_0 ; } __ats_lab_373_1: tmp1483 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1484 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; do { /* branch: __ats_lab_374 */ __ats_lab_374_0: __ats_lab_374_1: tmp1485 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof (tmp1483) ; if (!tmp1485) { goto __ats_lab_375_1 ; } break ; /* branch: __ats_lab_375 */ __ats_lab_375_0: __ats_lab_375_1: /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds (tmp1484) ; break ; } while (0) ; break ; /* branch: __ats_lab_376 */ __ats_lab_376_0: if (((ats_sum_ptr_type)tmp1477)->tag != 4) { goto __ats_lab_377_0 ; } __ats_lab_376_1: tmp1486 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds (tmp1486) ; break ; /* branch: __ats_lab_377 */ __ats_lab_377_0: if (((ats_sum_ptr_type)tmp1477)->tag != 5) { goto __ats_lab_378_0 ; } __ats_lab_377_1: tmp1487 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1488 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; tmp1489 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp1488) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_add (tmp1487, tmp1489) ; break ; /* branch: __ats_lab_378 */ __ats_lab_378_0: if (((ats_sum_ptr_type)tmp1477)->tag != 6) { goto __ats_lab_379_0 ; } __ats_lab_378_1: tmp1490 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1491 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; tmp1492 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp1491) ; /* tmp1493 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_add (tmp1490, tmp1492) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_extval (arg0, tmp1476, tmp1490, tmp1492) ; break ; /* branch: __ats_lab_379 */ __ats_lab_379_0: if (((ats_sum_ptr_type)tmp1477)->tag != 7) { goto __ats_lab_380_0 ; } __ats_lab_379_1: tmp1494 = ats_caselptrlab_mac(anairiats_sum_12, tmp1477, atslab_0) ; tmp1495 = ats_caselptrlab_mac(anairiats_sum_12, tmp1477, atslab_1) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_add (tmp1476, tmp1494, tmp1495) ; break ; /* branch: __ats_lab_380 */ __ats_lab_380_0: if (((ats_sum_ptr_type)tmp1477)->tag != 8) { goto __ats_lab_385_0 ; } __ats_lab_380_1: tmp1496 = ats_caselptrlab_mac(anairiats_sum_8, tmp1477, atslab_0) ; tmp1497 = ats_caselptrlab_mac(anairiats_sum_8, tmp1477, atslab_1) ; tmp1498 = ats_caselptrlab_mac(anairiats_sum_8, tmp1477, atslab_2) ; tmp1499 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; do { /* branch: __ats_lab_381 */ __ats_lab_381_0: if (tmp1496 != (ats_sum_ptr_type)0) { goto __ats_lab_384_0 ; } __ats_lab_381_1: tmp1500 = ccomp_fundeclst_init_99 (tmp1499, tmp1498) ; do { /* branch: __ats_lab_382 */ __ats_lab_382_0: if (tmp1498 == (ats_sum_ptr_type)0) { goto __ats_lab_383_0 ; } tmp1501 = ats_caselptrlab_mac(anairiats_sum_1, tmp1498, atslab_1) ; if (tmp1501 == (ats_sum_ptr_type)0) { goto __ats_lab_383_0 ; } __ats_lab_382_1: tmp1502 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_tailrecur (tmp1497) ; if (!tmp1502) { goto __ats_lab_383_1 ; } /* tmp1475 = */ ccomp_fntdeclst_main_100 (tmp1476, tmp1498, tmp1500) ; break ; /* branch: __ats_lab_383 */ __ats_lab_383_0: __ats_lab_383_1: /* tmp1475 = */ ccomp_fundeclst_main_105 (tmp1498, tmp1500) ; break ; } while (0) ; break ; /* branch: __ats_lab_384 */ __ats_lab_384_0: // if (tmp1496 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_384_1: break ; } while (0) ; break ; /* branch: __ats_lab_385 */ __ats_lab_385_0: if (((ats_sum_ptr_type)tmp1477)->tag != 9) { goto __ats_lab_386_0 ; } __ats_lab_385_1: tmp1503 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1504 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; tmp1505 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp1475 = */ ccomp_valdeclst_106 (arg0, tmp1505, tmp1503, tmp1504) ; break ; /* branch: __ats_lab_386 */ __ats_lab_386_0: if (((ats_sum_ptr_type)tmp1477)->tag != 11) { goto __ats_lab_387_0 ; } __ats_lab_386_1: tmp1506 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; tmp1507 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp1475 = */ ccomp_valdeclst_rec_108 (arg0, tmp1507, tmp1506) ; break ; /* branch: __ats_lab_387 */ __ats_lab_387_0: if (((ats_sum_ptr_type)tmp1477)->tag != 12) { goto __ats_lab_388_0 ; } __ats_lab_387_1: tmp1508 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; tmp1509 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; /* tmp1475 = */ ccomp_vardeclst_117 (arg0, tmp1509, tmp1508) ; break ; /* branch: __ats_lab_388 */ __ats_lab_388_0: if (((ats_sum_ptr_type)tmp1477)->tag != 13) { goto __ats_lab_389_0 ; } __ats_lab_388_1: tmp1510 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; tmp1511 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, tmp1510), atslab_hiimpdec_cst) ; /* tmp1475 = */ ccomp_impdec_119 (arg0, tmp1510) ; break ; /* branch: __ats_lab_389 */ __ats_lab_389_0: if (((ats_sum_ptr_type)tmp1477)->tag != 14) { goto __ats_lab_390_0 ; } __ats_lab_389_1: tmp1512 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; tmp1513 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, tmp1512), atslab_hiimpdec_prf_cst) ; tmp1514 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, tmp1512), atslab_hiimpdec_prf_cstset) ; /* tmp1475 = */ ccomp_impdec_prfck_121 (tmp1476, tmp1513, tmp1514) ; break ; /* branch: __ats_lab_390 */ __ats_lab_390_0: if (((ats_sum_ptr_type)tmp1477)->tag != 15) { goto __ats_lab_391_0 ; } __ats_lab_390_1: tmp1515 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_0) ; tmp1516 = ats_caselptrlab_mac(anairiats_sum_4, tmp1477, atslab_1) ; /* tmp1517 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (arg0, tmp1515) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (arg0, tmp1516) ; break ; /* branch: __ats_lab_391 */ __ats_lab_391_0: if (((ats_sum_ptr_type)tmp1477)->tag != 17) { goto __ats_lab_392_0 ; } __ats_lab_391_1: tmp1518 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; /* tmp1519 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_add (tmp1518) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file (arg0, tmp1476, tmp1518) ; break ; /* branch: __ats_lab_392 */ __ats_lab_392_0: if (((ats_sum_ptr_type)tmp1477)->tag != 16) { goto __ats_lab_393_0 ; } __ats_lab_392_1: tmp1520 = ats_caselptrlab_mac(anairiats_sum_18, tmp1477, atslab_0) ; tmp1521 = ats_caselptrlab_mac(anairiats_sum_18, tmp1477, atslab_1) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_add (tmp1520, tmp1521) ; break ; /* branch: __ats_lab_393 */ __ats_lab_393_0: if (((ats_sum_ptr_type)tmp1477)->tag != 0) { goto __ats_lab_394_0 ; } __ats_lab_393_1: tmp1522 = ats_caselptrlab_mac(anairiats_sum_5, tmp1477, atslab_0) ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (arg0, tmp1522) ; break ; /* branch: __ats_lab_394 */ __ats_lab_394_0: __ats_lab_394_1: /* tmp1523 = */ prerr_loc_interror_2 (tmp1476) ; /* tmp1524 = */ atspre_prerr_string (ATSstrcst(": ccomp_dec: not implemented yet.")) ; /* tmp1525 = */ atspre_prerr_newline () ; /* tmp1475 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp1475) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans.dats: 90831(line=3009, offs=3) -- 90998(line=3013, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1526) ; ATSlocal (ats_ptr_type, tmp1527) ; ATSlocal (ats_ptr_type, tmp1528) ; // ATSlocal_void (tmp1529) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst: do { /* branch: __ats_lab_395 */ __ats_lab_395_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_396_0 ; } __ats_lab_395_1: tmp1527 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1528 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp1529 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__ccomp_dec (arg0, tmp1527) ; arg0 = arg0 ; arg1 = tmp1528 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst ; // tail call break ; /* branch: __ats_lab_396 */ __ats_lab_396_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_396_1: break ; } while (0) ; return /* (tmp1526) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTcons_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTmark_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTnil_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp88, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp89, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp90, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp91, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp92, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp93, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp89 = dynctx_nil_13 () ; statmp88 = ref_make_elt_04328_ats_ptr_type (statmp89) ; statmp91 = (ats_sum_ptr_type)0 ; statmp90 = ref_make_elt_04328_ats_ptr_type (statmp91) ; statmp93 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__DYNMARKLSTnil_2) ; statmp92 = ref_make_elt_04328_ats_ptr_type (statmp93) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_trans_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_solver_fm_dats.c0000664000175000017500000031411212223166157022123 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" /* external codes at top */ #include "ats_solver_fm.cats" /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICvec_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICveclst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1mark_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_alloc_tsz) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_void_type, atspre_array_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_array_ptr_copy_tsz) (ats_ref_type, ats_ref_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_prefix) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_i0nt_of_int) (ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_gt_i0nt_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_gte_i0nt_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_lt_i0nt_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_eq_i0nt_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_neq_i0nt_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_solver_fm_gt_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_neg_i0nt) (ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_add_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_sub_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_mul_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_div_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_succ_i0nt) (ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_pred_i0nt) (ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_mod_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_gcd_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_solver_fm_fprint_i0nt) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec) (ats_ref_type, ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__prerr_intvec) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atsopt_solver_fm_intvecptr_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_solver_fm_intvecptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvecptr) (ats_ref_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr) (ats_ref_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst) (ats_ref_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_gte) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_eq) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_eq) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_solver_fm_intvec_copy) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_solver_fm_intvec_copy) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale) (ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_copy_and_scale) (ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by) (ats_ref_type, ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_sub_by) (ats_ref_type, ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale) (ats_ref_type, ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_combine_at) (ats_ref_type, ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_split_at) (ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at) (ats_ref_type, ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_elim_at) (ats_ptr_type, ats_ref_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst) (ats_int_type, ats_ref_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__sasp__intvecptr_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1cons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1mark_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_0) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type aux_3 (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) ; static ats_ptr_type intvec_ptr_alloc_6 (ats_int_type arg0) ; static ats_void_type intvec_ptr_free_7 (ats_ptr_type arg0) ; static ats_void_type icstr_free_9 (ats_ptr_type arg0) ; static ats_void_type aux_15 (ats_ptr_type arg0) ; static ats_void_type auxlst_16 (ats_ptr_type arg0) ; static ats_void_type intveclst_free_19 (ats_ptr_type arg0) ; static ats_void_type fprint_intveclst_20 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type print_intveclst_21 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type aux_23 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) ; static ats_int_type intvec_coeff_gcd_22 (ats_ref_type arg0, ats_int_type arg1) ; static ats_void_type aux_25 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type aux_27 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_int_type aux_29 (ats_ref_type arg0, ats_int_type arg1) ; static ats_int_type aux_32 (ats_ref_type arg0, ats_int_type arg1) ; static ats_int_type aux1_34 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) ; static ats_int_type aux2_35 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type auxbeg_45 (ats_int_type env0, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type auxbeg_45_closure_make (ats_int_type env0) ; static ats_void_type auxbeg_45_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_int_type auxcomb_46 (ats_int_type env0, ats_int_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type auxcomb_46_closure_make (ats_int_type env0, ats_int_type env1) ; static ats_int_type auxcomb_46_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_int_type auxcomblst_47 (ats_int_type env0, ats_int_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type auxcomblst_47_closure_make (ats_int_type env0, ats_int_type env1) ; static ats_int_type auxcomblst_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_solve_49 (ats_ref_type arg0, ats_int_type arg1) ; static ats_void_type intveclst1_free_52 (ats_ptr_type arg0) ; static ats_ptr_type intveclst1_backtrack_53 (ats_ptr_type arg0) ; static ats_void_type fprint_intveclst1_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type print_intveclst1_55 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type loop_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ref_type arg3) ; static ats_int_type aux_main_60 (ats_int_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4) ; static ats_int_type aux_main_disj_61 (ats_int_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_ptr_type arg5) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_int_type, statmp1) ; ATSstatic (ats_int_type, statmp2) ; ATSstatic (ats_int_type, statmp3) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 1838(line=52, offs=4) -- 1896(line=52, offs=62) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_solver_fm)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 2150(line=68, offs=22) -- 2182(line=68, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_i0nt (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_i0nt: tmp5 = atspre_stdout_get () ; tmp6 = ats_selsin_mac(tmp5, atslab_1) ; /* tmp7 = */ atsopt_solver_fm_fprint_i0nt (tmp6, arg0) ; /* tmp4 = */ atspre_stdout_view_set () ; return /* (tmp4) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_i0nt] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 2272(line=74, offs=7) -- 2532(line=80, offs=6) */ ATSstaticdec() ats_void_type aux_3 (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_bool_type, tmp10) ; // ATSlocal_void (tmp11) ; ATSlocal (ats_bool_type, tmp12) ; // ATSlocal_void (tmp13) ; ATSlocal (ats_int_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; __ats_lab_aux_3: tmp10 = atspre_ilt (arg3, arg2) ; if (tmp10) { tmp12 = atspre_igt (arg3, 0) ; if (tmp12) { /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp14 = ats_caselptrind_mac(ats_int_type, arg1, [arg3]) ; /* tmp13 = */ atsopt_solver_fm_fprint_i0nt (arg0, tmp14) ; tmp15 = atspre_iadd (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp15 ; goto __ats_lab_aux_3 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp9) */ ; } /* end of [aux_3] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 2237(line=73, offs=23) -- 2578(line=83, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec: /* tmp8 = */ aux_3 (arg0, arg1, arg2, 0) ; return /* (tmp8) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 2650(line=88, offs=14) -- 2818(line=93, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_intvec (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_intvec: tmp17 = atspre_stdout_get () ; tmp18 = ats_selsin_mac(tmp17, atslab_1) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (tmp18, arg0, arg1) ; /* tmp16 = */ atspre_stdout_view_set () ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_intvec] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 2868(line=96, offs=14) -- 3036(line=101, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__prerr_intvec (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__prerr_intvec: tmp21 = atspre_stderr_get () ; tmp22 = ats_selsin_mac(tmp21, atslab_1) ; /* tmp23 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (tmp22, arg0, arg1) ; /* tmp20 = */ atspre_stderr_view_set () ; return /* (tmp20) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__prerr_intvec] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 3087(line=105, offs=4) -- 3257(line=110, offs=61) */ ATSstaticdec() ats_ptr_type intvec_ptr_alloc_6 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_size_type, tmp25) ; __ats_lab_intvec_ptr_alloc_6: tmp25 = atspre_size1_of_int1 (arg0) ; tmp24 = atspre_array_ptr_alloc_tsz (tmp25, sizeof(ats_int_type)) ; return (tmp24) ; } /* end of [intvec_ptr_alloc_6] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 3291(line=113, offs=4) -- 3454(line=117, offs=45) */ ATSstaticdec() ats_void_type intvec_ptr_free_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp26) ; __ats_lab_intvec_ptr_free_7: /* tmp26 = */ atspre_array_ptr_free (arg0) ; return /* (tmp26) */ ; } /* end of [intvec_ptr_free_7] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 3657(line=131, offs=18) -- 3808(line=137, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvecptr (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvecptr: tmp28 = ats_varget_mac(ats_ptr_type, arg1) ; /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (arg0, tmp28, arg2) ; return /* (tmp27) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvecptr] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 3887(line=143, offs=5) -- 4039(line=147, offs=4) */ ATSstaticdec() ats_void_type icstr_free_9 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_icstr_free_9: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp29 = */ atsopt_solver_fm_intvecptr_free (tmp30) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free (tmp31) ; break ; } while (0) ; return /* (tmp29) */ ; } /* end of [icstr_free_9] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 4088(line=150, offs=15) -- 4210(line=153, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp34 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp35 = */ icstr_free_9 (tmp33) ; arg0 = tmp34 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp32) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 4292(line=159, offs=3) -- 4939(line=181, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp36) ; ATSlocal (ats_int_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; // ATSlocal_void (tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_int_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp38 = &ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp39 = */ atspre_fprint_string (arg0, ATSstrcst("ICvec(")) ; /* tmp40 = */ atspre_fprint_string (arg0, ATSstrcst("knd=")) ; /* tmp41 = */ atspre_fprint_int (arg0, tmp37) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp44 = ats_ptrget_mac(ats_ptr_type, tmp38) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvecptr (arg0, tmp44, arg2) ; /* tmp45 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; /* tmp36 = */ atspre_fprint_newline (arg0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp47 = &ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("ICveclst(")) ; /* tmp49 = */ atspre_fprint_string (arg0, ATSstrcst("knd=")) ; /* tmp50 = */ atspre_fprint_int (arg0, tmp46) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp53 = ats_ptrget_mac(ats_ptr_type, tmp47) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst (arg0, tmp53, arg2) ; /* tmp54 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; /* tmp36 = */ atspre_fprint_newline (arg0) ; break ; } while (0) ; return /* (tmp36) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 5002(line=185, offs=3) -- 5266(line=192, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp56 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp57 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp59 = ats_ptrget_mac(ats_ptr_type, tmp56) ; /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr (arg0, tmp59, arg2) ; tmp60 = ats_ptrget_mac(ats_ptr_type, tmp57) ; arg0 = arg0 ; arg1 = tmp60 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: break ; } while (0) ; return /* (tmp55) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 5339(line=197, offs=13) -- 5504(line=202, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstr (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; // ATSlocal_void (tmp64) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstr: tmp62 = atspre_stdout_get () ; tmp63 = ats_selsin_mac(tmp62, atslab_1) ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstr (tmp63, arg0, arg1) ; /* tmp61 = */ atspre_stdout_view_set () ; return /* (tmp61) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstr] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 5555(line=205, offs=16) -- 5725(line=210, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstrlst (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; // ATSlocal_void (tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstrlst: tmp66 = atspre_stdout_get () ; tmp67 = ats_selsin_mac(tmp66, atslab_1) ; /* tmp68 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_icstrlst (tmp67, arg0, arg1) ; /* tmp65 = */ atspre_stdout_view_set () ; return /* (tmp65) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__print_icstrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 5786(line=216, offs=5) -- 5980(line=221, offs=4) */ ATSstaticdec() ats_void_type aux_15 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; ATSlocal (ats_int_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_aux_15: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp70 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp72 = ats_ptrget_mac(ats_int_type, tmp70) ; tmp71 = atspre_sub_int_int (0, tmp72) ; ats_ptrget_mac(ats_int_type, tmp70) = tmp71 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp73 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp74 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp76 = ats_ptrget_mac(ats_int_type, tmp73) ; tmp75 = atspre_sub_int_int (1, tmp76) ; ats_ptrget_mac(ats_int_type, tmp73) = tmp75 ; tmp77 = ats_ptrget_mac(ats_ptr_type, tmp74) ; /* tmp69 = */ auxlst_16 (tmp77) ; break ; } while (0) ; return /* (tmp69) */ ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 6002(line=223, offs=5) -- 6193(line=228, offs=4) */ ATSstaticdec() ats_void_type auxlst_16 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; // ATSlocal_void (tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; __ats_lab_auxlst_16: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp79 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp80 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp82 = ats_ptrget_mac(ats_ptr_type, tmp79) ; /* tmp81 = */ aux_15 (tmp82) ; tmp83 = ats_ptrget_mac(ats_ptr_type, tmp80) ; arg0 = tmp83 ; goto __ats_lab_auxlst_16 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: break ; } while (0) ; return /* (tmp78) */ ; } /* end of [auxlst_16] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 6258(line=232, offs=24) -- 6277(line=232, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; // ATSlocal_void (tmp85) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate: /* tmp85 = */ aux_15 (arg0) ; tmp84 = arg0 ; return (tmp84) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 6304(line=233, offs=27) -- 6329(line=233, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_negate (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp86) ; // ATSlocal_void (tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_negate: /* tmp87 = */ auxlst_16 (arg0) ; tmp86 = arg0 ; return (tmp86) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_negate] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 6607(line=247, offs=5) -- 6873(line=254, offs=4) */ ATSstaticdec() ats_void_type intveclst_free_19 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; __ats_lab_intveclst_free_19: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp91 = */ intvec_ptr_free_7 (tmp89) ; arg0 = tmp90 ; goto __ats_lab_intveclst_free_19 ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: break ; } while (0) ; return /* (tmp88) */ ; } /* end of [intveclst_free_19] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 6906(line=256, offs=5) -- 7422(line=269, offs=4) */ ATSstaticdec() ats_void_type fprint_intveclst_20 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_fprint_intveclst_20: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp94 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (arg0, tmp93, arg2) ; /* tmp96 = */ atspre_fprint_newline (arg0) ; tmp97 = ats_ptrget_mac(ats_ptr_type, tmp94) ; arg0 = arg0 ; arg1 = tmp97 ; arg2 = arg2 ; goto __ats_lab_fprint_intveclst_20 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: break ; } while (0) ; return /* (tmp92) */ ; } /* end of [fprint_intveclst_20] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 7457(line=271, offs=5) -- 7713(line=278, offs=4) */ ATSstaticdec() ats_void_type print_intveclst_21 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; __ats_lab_print_intveclst_21: tmp99 = atspre_stdout_get () ; tmp100 = ats_selsin_mac(tmp99, atslab_1) ; /* tmp101 = */ fprint_intveclst_20 (tmp100, arg0, arg1) ; /* tmp98 = */ atspre_stdout_view_set () ; return /* (tmp98) */ ; } /* end of [print_intveclst_21] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 7931(line=290, offs=7) -- 8387(line=307, offs=6) */ ATSstaticdec() ats_void_type aux_23 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp103) ; ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_int_type, tmp105) ; ATSlocal (ats_bool_type, tmp106) ; ATSlocal (ats_bool_type, tmp107) ; ATSlocal (ats_int_type, tmp108) ; ATSlocal (ats_bool_type, tmp109) ; ATSlocal (ats_int_type, tmp110) ; ATSlocal (ats_int_type, tmp111) ; __ats_lab_aux_23: tmp104 = atspre_igt (arg1, 0) ; if (tmp104) { tmp105 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp106 = atsopt_solver_fm_neq_i0nt_int (tmp105, 0) ; if (tmp106) { tmp107 = atsopt_solver_fm_neq_i0nt_int (tmp105, 1) ; if (tmp107) { tmp108 = atsopt_solver_fm_gcd_i0nt_i0nt (tmp105, ats_ptrget_mac(ats_int_type, arg2)) ; ats_ptrget_mac(ats_int_type, arg2) = tmp108 ; tmp109 = atsopt_solver_fm_neq_i0nt_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; if (tmp109) { tmp110 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp110 ; arg2 = arg2 ; goto __ats_lab_aux_23 ; // tail call } else { /* empty */ } /* end of [if] */ } else { ats_ptrget_mac(ats_int_type, arg2) = tmp105 ; } /* end of [if] */ } else { tmp111 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp111 ; arg2 = arg2 ; goto __ats_lab_aux_23 ; // tail call } /* end of [if] */ } else { /* empty */ } /* end of [if] */ return /* (tmp103) */ ; } /* end of [aux_23] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 7859(line=288, offs=5) -- 8471(line=311, offs=4) */ ATSstaticdec() ats_int_type intvec_coeff_gcd_22 (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_int_type, tmp112) ; // ATSlocal_void (tmp113) ; ATSlocal (ats_int_type, tmp114) ; __ats_lab_intvec_coeff_gcd_22: /* ats_int_type tmp112 ; */ tmp112 = atsopt_solver_fm_i0nt_of_int (0) ; tmp114 = atspre_isub (arg1, 1) ; /* tmp113 = */ aux_23 (arg0, tmp114, (&tmp112)) ; tmp102 = tmp112 ; return (tmp102) ; } /* end of [intvec_coeff_gcd_22] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 8653(line=320, offs=7) -- 8897(line=328, offs=6) */ ATSstaticdec() ats_void_type aux_25 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp116) ; ATSlocal (ats_bool_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_bool_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; __ats_lab_aux_25: tmp117 = atspre_igte (arg1, 0) ; if (tmp117) { tmp118 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp120 = atsopt_solver_fm_neq_i0nt_int (tmp118, 0) ; if (tmp120) { tmp121 = atsopt_solver_fm_div_i0nt_i0nt (tmp118, arg2) ; ats_caselptrind_mac(ats_int_type, arg0, [arg1]) = tmp121 ; } else { /* empty */ } /* end of [if] */ tmp122 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp122 ; arg2 = arg2 ; goto __ats_lab_aux_25 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp116) */ ; } /* end of [aux_25] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 8632(line=319, offs=26) -- 9532(line=353, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_gte (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp115) ; ATSlocal (ats_int_type, tmp123) ; ATSlocal (ats_bool_type, tmp124) ; ATSlocal (ats_int_type, tmp125) ; // ATSlocal_void (tmp126) ; ATSlocal (ats_int_type, tmp127) ; ATSlocal (ats_bool_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_int_type, tmp131) ; ATSlocal (ats_int_type, tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_gte: tmp123 = intvec_coeff_gcd_22 (arg0, arg1) ; tmp124 = atsopt_solver_fm_gt_i0nt_int (tmp123, 1) ; if (tmp124) { tmp125 = ats_caselptrind_mac(ats_int_type, arg0, [0]) ; tmp127 = atspre_isub (arg1, 1) ; /* tmp126 = */ aux_25 (arg0, tmp127, tmp123) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp128 = atsopt_solver_fm_gte_i0nt_int (tmp125, 0) ; if (!tmp128) { goto __ats_lab_17_1 ; } tmp129 = atsopt_solver_fm_div_i0nt_i0nt (tmp125, tmp123) ; ats_caselptrind_mac(ats_int_type, arg0, [0]) = tmp129 ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp132 = atsopt_solver_fm_sub_i0nt_i0nt (tmp125, tmp123) ; tmp131 = atsopt_solver_fm_succ_i0nt (tmp132) ; tmp130 = atsopt_solver_fm_div_i0nt_i0nt (tmp131, tmp123) ; ats_caselptrind_mac(ats_int_type, arg0, [0]) = tmp130 ; break ; } while (0) ; } else { /* empty */ } /* end of [if] */ return /* (tmp115) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_gte] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 9760(line=364, offs=7) -- 10004(line=372, offs=6) */ ATSstaticdec() ats_void_type aux_27 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp134) ; ATSlocal (ats_bool_type, tmp135) ; ATSlocal (ats_int_type, tmp136) ; ATSlocal (ats_bool_type, tmp138) ; ATSlocal (ats_int_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; __ats_lab_aux_27: tmp135 = atspre_igte (arg1, 0) ; if (tmp135) { tmp136 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp138 = atsopt_solver_fm_neq_i0nt_int (tmp136, 0) ; if (tmp138) { tmp139 = atsopt_solver_fm_div_i0nt_i0nt (tmp136, arg2) ; ats_caselptrind_mac(ats_int_type, arg0, [arg1]) = tmp139 ; } else { /* empty */ } /* end of [if] */ tmp140 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp140 ; arg2 = arg2 ; goto __ats_lab_aux_27 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp134) */ ; } /* end of [aux_27] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 9739(line=363, offs=25) -- 10269(line=383, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_eq (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_int_type, tmp141) ; ATSlocal (ats_bool_type, tmp142) ; ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_bool_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_int_type, tmp147) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_eq: tmp141 = intvec_coeff_gcd_22 (arg0, arg1) ; tmp142 = atsopt_solver_fm_gt_i0nt_int (tmp141, 1) ; if (tmp142) { tmp143 = ats_caselptrind_mac(ats_int_type, arg0, [0]) ; tmp145 = atsopt_solver_fm_mod_i0nt_i0nt (tmp143, tmp141) ; tmp144 = atsopt_solver_fm_eq_i0nt_int (tmp145, 0) ; if (tmp144) { tmp147 = atspre_isub (arg1, 1) ; /* tmp146 = */ aux_27 (arg0, tmp147, tmp141) ; tmp133 = 0 ; } else { tmp133 = -1 ; } /* end of [if] */ } else { tmp133 = 0 ; } /* end of [if] */ return (tmp133) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_eq] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 10480(line=393, offs=7) -- 10695(line=398, offs=8) */ ATSstaticdec() ats_int_type aux_29 (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp149) ; ATSlocal (ats_bool_type, tmp150) ; ATSlocal (ats_bool_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; ATSlocal (ats_int_type, tmp153) ; ATSlocal (ats_bool_type, tmp154) ; ATSlocal (ats_int_type, tmp155) ; __ats_lab_aux_29: tmp150 = atspre_igt (arg1, 0) ; if (tmp150) { tmp152 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp151 = atsopt_solver_fm_neq_i0nt_int (tmp152, 0) ; if (tmp151) { tmp149 = 0 ; } else { tmp153 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp153 ; goto __ats_lab_aux_29 ; // tail call } /* end of [if] */ } else { tmp155 = ats_caselptrind_mac(ats_int_type, arg0, [0]) ; tmp154 = atsopt_solver_fm_gte_i0nt_int (tmp155, 0) ; if (tmp154) { tmp149 = 1 ; } else { tmp149 = -1 ; } /* end of [if] */ } /* end of [if] */ return (tmp149) ; } /* end of [aux_29] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 10459(line=392, offs=24) -- 10794(line=403, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp148) ; ATSlocal (ats_int_type, tmp156) ; ATSlocal (ats_int_type, tmp157) ; // ATSlocal_void (tmp158) ; ATSlocal (ats_bool_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte: tmp157 = atspre_isub (arg1, 1) ; tmp156 = aux_29 (arg0, tmp157) ; tmp159 = atspre_ieq (tmp156, 0) ; if (tmp159) { /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_gte (arg0, arg1) ; } else { /* empty */ } /* end of [if] */ tmp148 = tmp156 ; return (tmp148) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 11005(line=413, offs=23) -- 11627(line=431, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_bool_type, tmp164) ; // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_bool_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (ats_ptrget_mac(ats_ptr_type, arg0) == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg0), atslab_0) ; tmp162 = &ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg0), atslab_1) ; tmp163 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte (tmp161, arg1) ; tmp164 = atspre_ineq (tmp163, 0) ; if (tmp164) { /* tmp165 = */ intvec_ptr_free_7 (tmp161) ; tmp166 = ats_ptrget_mac(ats_ptr_type, tmp162) ; ATS_FREE(ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp166 ; tmp167 = atspre_igt (tmp163, 0) ; if (tmp167) { arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte ; // tail call } else { tmp160 = -1 ; } /* end of [if] */ } else { arg0 = tmp162 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (ats_ptrget_mac(ats_ptr_type, arg0) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp160 = 0 ; break ; } while (0) ; return (tmp160) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 11837(line=441, offs=7) -- 12057(line=446, offs=8) */ ATSstaticdec() ats_int_type aux_32 (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp169) ; ATSlocal (ats_bool_type, tmp170) ; ATSlocal (ats_bool_type, tmp171) ; ATSlocal (ats_int_type, tmp172) ; ATSlocal (ats_int_type, tmp173) ; ATSlocal (ats_bool_type, tmp174) ; ATSlocal (ats_int_type, tmp175) ; __ats_lab_aux_32: tmp170 = atspre_igt (arg1, 0) ; if (tmp170) { tmp172 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp171 = atsopt_solver_fm_neq_i0nt_int (tmp172, 0) ; if (tmp171) { tmp169 = 0 ; } else { tmp173 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp173 ; goto __ats_lab_aux_32 ; // tail call } /* end of [if] */ } else { tmp175 = ats_caselptrind_mac(ats_int_type, arg0, [0]) ; tmp174 = atsopt_solver_fm_eq_i0nt_int (tmp175, 0) ; if (tmp174) { tmp169 = 1 ; } else { tmp169 = -1 ; } /* end of [if] */ } /* end of [if] */ return (tmp169) ; } /* end of [aux_32] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 11816(line=440, offs=23) -- 12083(line=449, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_eq (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp168) ; ATSlocal (ats_int_type, tmp176) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_eq: tmp176 = atspre_isub (arg1, 1) ; tmp168 = aux_32 (arg0, tmp176) ; return (tmp168) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_eq] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 12445(line=466, offs=7) -- 13282(line=492, offs=8) */ ATSstaticdec() ats_int_type aux1_34 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp178) ; ATSlocal (ats_bool_type, tmp179) ; ATSlocal (ats_bool_type, tmp180) ; ATSlocal (ats_int_type, tmp181) ; ATSlocal (ats_int_type, tmp182) ; ATSlocal (ats_bool_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; ATSlocal (ats_bool_type, tmp186) ; ATSlocal (ats_bool_type, tmp187) ; ATSlocal (ats_bool_type, tmp188) ; ATSlocal (ats_int_type, tmp189) ; ATSlocal (ats_int_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; __ats_lab_aux1_34: tmp179 = atsopt_solver_fm_eq_i0nt_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; if (tmp179) { tmp178 = arg2 ; } else { tmp180 = atspre_igt (arg1, 0) ; if (tmp180) { tmp181 = ats_caselptrind_mac(ats_int_type, arg0, [arg1]) ; tmp183 = atsopt_solver_fm_gte_i0nt_int (tmp181, 0) ; if (tmp183) { tmp182 = tmp181 ; } else { tmp182 = atsopt_solver_fm_neg_i0nt (tmp181) ; } /* end of [if] */ /* ats_int_type tmp184 ; */ tmp184 = 0 ; tmp186 = atsopt_solver_fm_gt_i0nt_int (tmp182, 0) ; if (tmp186) { tmp187 = atsopt_solver_fm_gt_i0nt_i0nt (ats_ptrget_mac(ats_int_type, arg3), tmp182) ; if (tmp187) { ats_ptrget_mac(ats_int_type, arg3) = tmp182 ; tmp184 = 1 ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp188 = atspre_gt_int_int (tmp184, 0) ; if (tmp188) { tmp189 = atspre_isub (arg1, 1) ; tmp190 = arg1 ; arg0 = arg0 ; arg1 = tmp189 ; arg2 = tmp190 ; arg3 = arg3 ; goto __ats_lab_aux1_34 ; // tail call } else { tmp191 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp191 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_aux1_34 ; // tail call } /* end of [if] */ } else { tmp178 = arg2 ; } /* end of [if] */ } /* end of [if] */ return (tmp178) ; } /* end of [aux1_34] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 13289(line=493, offs=7) -- 13854(line=509, offs=8) */ ATSstaticdec() ats_int_type aux2_35 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp192) ; ATSlocal (ats_bool_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_bool_type, tmp195) ; ATSlocal (ats_int_type, tmp196) ; ATSlocal (ats_int_type, tmp197) ; ATSlocal (ats_bool_type, tmp198) ; ATSlocal (ats_int_type, tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_int_type, tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; __ats_lab_aux2_35: tmp193 = atspre_igt (arg2, 0) ; if (tmp193) { tmp194 = ats_caselptrind_mac(ats_int_type, arg0, [arg2]) ; tmp195 = atsopt_solver_fm_gt_i0nt_int (tmp194, 0) ; if (tmp195) { /* ats_int_type tmp196 ; */ tmp196 = tmp194 ; tmp197 = atspre_isub (arg2, 1) ; tmp192 = aux1_34 (arg0, tmp197, arg2, (&tmp196)) ; } else { tmp198 = atsopt_solver_fm_lt_i0nt_int (tmp194, 0) ; if (tmp198) { /* ats_int_type tmp199 ; */ tmp199 = atsopt_solver_fm_neg_i0nt (tmp194) ; tmp200 = atspre_isub (arg2, 1) ; tmp192 = aux1_34 (arg0, tmp200, arg2, (&tmp199)) ; } else { tmp201 = atspre_isub (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp201 ; goto __ats_lab_aux2_35 ; // tail call } /* end of [if] */ } /* end of [if] */ } else { /* tmp202 = */ prerr_interror_0 () ; /* tmp203 = */ atspre_prerr_string (ATSstrcst(": intvec_absmin_coeff_index_get: all coefficients are zero: ")) ; /* tmp204 = */ atspre_prerr_newline () ; /* tmp205 = */ atspre_prerr_string (ATSstrcst("vec = ")) ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__prerr_intvec (arg0, arg1) ; /* tmp207 = */ atspre_prerr_newline () ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return (tmp192) ; } /* end of [aux2_35] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 12424(line=465, offs=35) -- 14329(line=526, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp177) ; ATSlocal (ats_int_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get: tmp208 = atspre_isub (arg1, 1) ; tmp177 = aux2_35 (arg0, arg1, tmp208) ; return (tmp177) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 14576(line=539, offs=13) -- 14743(line=544, offs=4) */ ATSglobaldec() ats_ptr_type ats_solver_fm_intvec_copy (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; // ATSlocal_void (tmp212) ; ATSlocal (ats_size_type, tmp213) ; __ats_lab_ats_solver_fm_intvec_copy: tmp210 = intvec_ptr_alloc_6 (arg1) ; tmp211 = ats_selsin_mac(tmp210, atslab_2) ; tmp213 = atspre_size1_of_int1 (arg1) ; /* tmp212 = */ atspre_array_ptr_copy_tsz (arg0, tmp211, tmp213, sizeof(ats_int_type)) ; tmp209 = tmp211 ; return (tmp209) ; } /* end of [ats_solver_fm_intvec_copy] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 15076(line=563, offs=3) -- 15275(line=569, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp214) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_bool_type, tmp216) ; ATSlocal (ats_int_type, tmp217) ; ATSlocal (ats_int_type, tmp218) ; ATSlocal (ats_int_type, tmp219) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate: /* ats_int_type tmp215 ; */ tmp215 = atspre_isub (arg1, 1) ; /* loop initialization */ /* empty */ ats_loop_beg_mac(__ats_lab_20) tmp216 = atspre_igte (tmp215, 0) ; if (!tmp216) break ; tmp218 = ats_caselptrind_mac(ats_int_type, arg0, [tmp215]) ; tmp217 = atsopt_solver_fm_neg_i0nt (tmp218) ; ats_caselptrind_mac(ats_int_type, arg0, [tmp215]) = tmp217 ; tmp219 = atspre_isub (tmp215, 1) ; tmp215 = tmp219 ; ats_loop_end_mac(__ats_lab_20, __ats_lab_21) return /* (tmp214) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 15428(line=577, offs=18) -- 15679(line=588, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp220) ; ATSlocal (ats_bool_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_bool_type, tmp223) ; ATSlocal (ats_int_type, tmp224) ; ATSlocal (ats_int_type, tmp225) ; ATSlocal (ats_int_type, tmp226) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale: tmp221 = atsopt_solver_fm_neq_i0nt_int (arg2, 1) ; if (tmp221) { /* ats_int_type tmp222 ; */ tmp222 = atspre_isub (arg1, 1) ; /* loop initialization */ /* empty */ ats_loop_beg_mac(__ats_lab_22) tmp223 = atspre_igte (tmp222, 0) ; if (!tmp223) break ; tmp225 = ats_caselptrind_mac(ats_int_type, arg0, [tmp222]) ; tmp224 = atsopt_solver_fm_mul_i0nt_i0nt (arg2, tmp225) ; ats_caselptrind_mac(ats_int_type, arg0, [tmp222]) = tmp224 ; tmp226 = atspre_isub (tmp222, 1) ; tmp222 = tmp226 ; ats_loop_end_mac(__ats_lab_22, __ats_lab_23) } else { /* empty */ } /* end of [if] */ return /* (tmp220) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 15944(line=602, offs=3) -- 16201(line=612, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_copy_and_scale (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_bool_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; // ATSlocal_void (tmp231) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_copy_and_scale: tmp228 = atsopt_solver_fm_neq_i0nt_int (arg2, 1) ; if (tmp228) { tmp229 = ats_solver_fm_intvec_copy (arg0, arg1) ; tmp230 = ats_selsin_mac(tmp229, atslab_2) ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale (tmp230, arg1, arg2) ; tmp227 = tmp230 ; } else { tmp227 = ats_solver_fm_intvec_copy (arg0, arg1) ; } /* end of [if] */ return (tmp227) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_copy_and_scale] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 16435(line=624, offs=19) -- 16651(line=631, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp232) ; ATSlocal (ats_int_type, tmp233) ; ATSlocal (ats_bool_type, tmp234) ; ATSlocal (ats_int_type, tmp235) ; ATSlocal (ats_int_type, tmp236) ; ATSlocal (ats_int_type, tmp237) ; ATSlocal (ats_int_type, tmp238) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by: /* ats_int_type tmp233 ; */ tmp233 = atspre_isub (arg2, 1) ; /* loop initialization */ /* empty */ ats_loop_beg_mac(__ats_lab_24) tmp234 = atspre_igte (tmp233, 0) ; if (!tmp234) break ; tmp236 = ats_caselptrind_mac(ats_int_type, arg0, [tmp233]) ; tmp237 = ats_caselptrind_mac(ats_int_type, arg1, [tmp233]) ; tmp235 = atsopt_solver_fm_add_i0nt_i0nt (tmp236, tmp237) ; ats_caselptrind_mac(ats_int_type, arg0, [tmp233]) = tmp235 ; tmp238 = atspre_isub (tmp233, 1) ; tmp233 = tmp238 ; ats_loop_end_mac(__ats_lab_24, __ats_lab_25) return /* (tmp232) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 16878(line=644, offs=19) -- 17100(line=651, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_sub_by (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp239) ; ATSlocal (ats_int_type, tmp240) ; ATSlocal (ats_bool_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_int_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; ATSlocal (ats_int_type, tmp245) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_sub_by: /* ats_int_type tmp240 ; */ tmp240 = atspre_isub (arg2, 1) ; /* loop initialization */ /* empty */ ats_loop_beg_mac(__ats_lab_26) tmp241 = atspre_igte (tmp240, 0) ; if (!tmp241) break ; tmp243 = ats_caselptrind_mac(ats_int_type, arg0, [tmp240]) ; tmp244 = ats_caselptrind_mac(ats_int_type, arg1, [tmp240]) ; tmp242 = atsopt_solver_fm_sub_i0nt_i0nt (tmp243, tmp244) ; ats_caselptrind_mac(ats_int_type, arg0, [tmp240]) = tmp242 ; tmp245 = atspre_isub (tmp240, 1) ; tmp240 = tmp245 ; ats_loop_end_mac(__ats_lab_26, __ats_lab_27) return /* (tmp239) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_sub_by] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 17358(line=663, offs=35) -- 17744(line=675, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp246) ; ATSlocal (ats_bool_type, tmp247) ; ATSlocal (ats_bool_type, tmp248) ; ATSlocal (ats_int_type, tmp249) ; ATSlocal (ats_bool_type, tmp250) ; ATSlocal (ats_int_type, tmp251) ; ATSlocal (ats_int_type, tmp252) ; ATSlocal (ats_int_type, tmp253) ; ATSlocal (ats_int_type, tmp254) ; ATSlocal (ats_int_type, tmp255) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale: tmp247 = atsopt_solver_fm_eq_i0nt_int (arg3, 0) ; if (tmp247) { /* empty */ } else { tmp248 = atsopt_solver_fm_eq_i0nt_int (arg3, 1) ; if (tmp248) { /* tmp246 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by (arg0, arg1, arg2) ; } else { /* ats_int_type tmp249 ; */ tmp249 = atspre_isub (arg2, 1) ; /* loop initialization */ /* empty */ ats_loop_beg_mac(__ats_lab_28) tmp250 = atspre_igte (tmp249, 0) ; if (!tmp250) break ; tmp252 = ats_caselptrind_mac(ats_int_type, arg0, [tmp249]) ; tmp254 = ats_caselptrind_mac(ats_int_type, arg1, [tmp249]) ; tmp253 = atsopt_solver_fm_mul_i0nt_i0nt (arg3, tmp254) ; tmp251 = atsopt_solver_fm_add_i0nt_i0nt (tmp252, tmp253) ; ats_caselptrind_mac(ats_int_type, arg0, [tmp249]) = tmp251 ; tmp255 = atspre_isub (tmp249, 1) ; tmp249 = tmp255 ; ats_loop_end_mac(__ats_lab_28, __ats_lab_29) } /* end of [if] */ } /* end of [if] */ return /* (tmp246) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 18042(line=690, offs=19) -- 18284(line=698, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_combine_at (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_int_type, tmp257) ; ATSlocal (ats_int_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; // ATSlocal_void (tmp262) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_combine_at: tmp257 = ats_caselptrind_mac(ats_int_type, arg0, [arg3]) ; tmp259 = ats_caselptrind_mac(ats_int_type, arg1, [arg3]) ; tmp258 = atsopt_solver_fm_neg_i0nt (tmp259) ; tmp260 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_copy_and_scale (arg1, arg2, tmp257) ; tmp261 = ats_selsin_mac(tmp260, atslab_2) ; /* tmp262 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale (tmp261, arg0, arg2, tmp258) ; tmp256 = tmp261 ; return (tmp256) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_combine_at] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 18659(line=716, offs=5) -- 19354(line=741, offs=4) */ ATSstaticdec() ats_void_type auxbeg_45 (ats_int_type env0, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_int_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_bool_type, tmp270) ; ATSlocal (ats_bool_type, tmp271) ; __ats_lab_auxbeg_45: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp266 = &ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp267 = ats_caselptrind_mac(ats_int_type, tmp265, [env0]) ; tmp268 = ats_ptrget_mac(ats_ptr_type, tmp266) ; tmp270 = atsopt_solver_fm_gt_i0nt_int (tmp267, 0) ; if (tmp270) { ats_ptrget_mac(ats_ptr_type, tmp266) = ats_ptrget_mac(ats_ptr_type, arg0) ; ats_ptrget_mac(ats_ptr_type, arg0) = arg3 ; } else { tmp271 = atsopt_solver_fm_lt_i0nt_int (tmp267, 0) ; if (tmp271) { ats_ptrget_mac(ats_ptr_type, tmp266) = ats_ptrget_mac(ats_ptr_type, arg2) ; ats_ptrget_mac(ats_ptr_type, arg2) = arg3 ; } else { ats_ptrget_mac(ats_ptr_type, tmp266) = ats_ptrget_mac(ats_ptr_type, arg1) ; ats_ptrget_mac(ats_ptr_type, arg1) = arg3 ; } /* end of [if] */ } /* end of [if] */ arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp268 ; goto __ats_lab_auxbeg_45 ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: break ; } while (0) ; return /* (tmp264) */ ; } /* end of [auxbeg_45] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } auxbeg_45_closure_type ; ats_void_type auxbeg_45_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { auxbeg_45 (((auxbeg_45_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3) ; return ; } /* end of function */ ATSinline() ats_void_type auxbeg_45_closure_init (auxbeg_45_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxbeg_45_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxbeg_45_closure_make (ats_int_type env0) { auxbeg_45_closure_type *p_clo = ATS_MALLOC(sizeof(auxbeg_45_closure_type)) ; auxbeg_45_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 19381(line=743, offs=5) -- 20325(line=769, offs=4) */ ATSstaticdec() ats_int_type auxcomb_46 (ats_int_type env0, ats_int_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_int_type, tmp277) ; // ATSlocal_void (tmp278) ; ATSlocal (ats_bool_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_bool_type, tmp281) ; __ats_lab_auxcomb_46: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp273 = ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg2), atslab_0) ; tmp274 = &ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; tmp275 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_combine_at (tmp273, arg1, env0, env1) ; tmp276 = ats_selsin_mac(tmp275, atslab_2) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte (tmp276, env0) ; tmp279 = atspre_ineq (tmp277, 0) ; if (tmp279) { /* tmp278 = */ intvec_ptr_free_7 (tmp276) ; } else { tmp280 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp280, atslab_0, tmp276) ; ats_selptrset_mac(anairiats_sum_1, tmp280, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp280 ; } /* end of [if] */ tmp281 = atspre_igte (tmp277, 0) ; if (tmp281) { arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp274 ; goto __ats_lab_auxcomb_46 ; // tail call } else { tmp272 = -1 ; } /* end of [if] */ break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (ats_ptrget_mac(ats_ptr_type, arg2) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp272 = 0 ; break ; } while (0) ; return (tmp272) ; } /* end of [auxcomb_46] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_int_type closure_env_1 ; } auxcomb_46_closure_type ; ats_int_type auxcomb_46_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2) { return auxcomb_46 (((auxcomb_46_closure_type*)cloptr)->closure_env_0, ((auxcomb_46_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type auxcomb_46_closure_init (auxcomb_46_closure_type *p_clo, ats_int_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxcomb_46_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxcomb_46_closure_make (ats_int_type env0, ats_int_type env1) { auxcomb_46_closure_type *p_clo = ATS_MALLOC(sizeof(auxcomb_46_closure_type)) ; auxcomb_46_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 20408(line=773, offs=5) -- 20907(line=789, offs=4) */ ATSstaticdec() ats_int_type auxcomblst_47 (ats_int_type env0, ats_int_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_int_type, tmp285) ; // ATSlocal_void (tmp286) ; ATSlocal (ats_bool_type, tmp287) ; // ATSlocal_void (tmp288) ; __ats_lab_auxcomblst_47: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp283 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp284 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; ATS_FREE(arg2) ; tmp285 = auxcomb_46 (env0, env1, arg0, tmp283, arg1) ; /* tmp286 = */ intvec_ptr_free_7 (tmp283) ; tmp287 = atspre_igte (tmp285, 0) ; if (tmp287) { arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp284 ; goto __ats_lab_auxcomblst_47 ; // tail call } else { /* tmp288 = */ intveclst_free_19 (tmp284) ; tmp282 = tmp285 ; } /* end of [if] */ break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp282 = 0 ; break ; } while (0) ; return (tmp282) ; } /* end of [auxcomblst_47] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_int_type closure_env_1 ; } auxcomblst_47_closure_type ; ats_int_type auxcomblst_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { return auxcomblst_47 (((auxcomblst_47_closure_type*)cloptr)->closure_env_0, ((auxcomblst_47_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type auxcomblst_47_closure_init (auxcomblst_47_closure_type *p_clo, ats_int_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxcomblst_47_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxcomblst_47_closure_make (ats_int_type env0, ats_int_type env1) { auxcomblst_47_closure_type *p_clo = ATS_MALLOC(sizeof(auxcomblst_47_closure_type)) ; auxcomblst_47_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 18607(line=712, offs=9) -- 21196(line=803, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_split_at (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp263) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; // ATSlocal_void (tmp292) ; ATSlocal (ats_int_type, tmp293) ; // ATSlocal_void (tmp294) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_split_at: /* ats_ptr_type tmp289 ; */ tmp289 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp290 ; */ tmp290 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp291 ; */ tmp291 = (ats_sum_ptr_type)0 ; /* tmp292 = */ auxbeg_45 (arg2, (&tmp289), (&tmp290), (&tmp291), ats_ptrget_mac(ats_ptr_type, arg0)) ; tmp293 = auxcomblst_47 (arg1, arg2, (&tmp290), (&tmp289), tmp291) ; /* tmp294 = */ intveclst_free_19 (tmp289) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp290 ; tmp263 = tmp293 ; return (tmp263) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_split_at] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 21414(line=814, offs=7) -- 21887(line=827, offs=6) */ ATSstaticdec() ats_int_type aux_solve_49 (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_int_type, tmp298) ; ATSlocal (ats_int_type, tmp299) ; ATSlocal (ats_bool_type, tmp300) ; __ats_lab_aux_solve_49: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (ats_ptrget_mac(ats_ptr_type, arg0) == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp297 = ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg0), atslab_0) ; tmp298 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get (tmp297, arg1) ; tmp299 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_split_at (arg0, arg1, tmp298) ; tmp300 = atspre_igte (tmp299, 0) ; if (tmp300) { arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_aux_solve_49 ; // tail call } else { tmp296 = -1 ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (ats_ptrget_mac(ats_ptr_type, arg0) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp296 = 0 ; break ; } while (0) ; return (tmp296) ; } /* end of [aux_solve_49] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 21392(line=813, offs=21) -- 22145(line=838, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp295) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_int_type, tmp302) ; // ATSlocal_void (tmp303) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve: /* ats_ptr_type tmp301 ; */ tmp301 = arg0 ; tmp302 = aux_solve_49 ((&tmp301), arg1) ; /* tmp303 = */ intveclst_free_19 (tmp301) ; tmp295 = tmp302 ; return (tmp295) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 22364(line=848, offs=16) -- 22687(line=858, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at (ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp304) ; ATSlocal (ats_int_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_bool_type, tmp307) ; ATSlocal (ats_bool_type, tmp308) ; // ATSlocal_void (tmp309) ; ATSlocal (ats_int_type, tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_int_type, tmp312) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at: tmp305 = ats_caselptrind_mac(ats_int_type, arg0, [arg3]) ; tmp306 = ats_caselptrind_mac(ats_int_type, arg1, [arg3]) ; tmp307 = atsopt_solver_fm_eq_i0nt_int (tmp305, 0) ; if (tmp307) { /* empty */ } else { tmp308 = atsopt_solver_fm_gte_i0nt_int (tmp306, 0) ; if (tmp308) { /* tmp309 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale (arg0, arg2, tmp306) ; tmp310 = atsopt_solver_fm_neg_i0nt (tmp305) ; /* tmp304 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale (arg0, arg1, arg2, tmp310) ; } else { tmp312 = atsopt_solver_fm_neg_i0nt (tmp306) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_scale (arg0, arg2, tmp312) ; /* tmp304 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_add_by_scale (arg0, arg1, arg2, tmp305) ; } /* end of [if] */ } /* end of [if] */ return /* (tmp304) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 22897(line=866, offs=19) -- 23228(line=877, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_elim_at (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; // ATSlocal_void (tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_elim_at: do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp314 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp315 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at (tmp314, arg1, arg2, arg3) ; tmp317 = ats_ptrget_mac(ats_ptr_type, tmp315) ; arg0 = tmp317 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_elim_at ; // tail call break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: break ; } while (0) ; return /* (tmp313) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_elim_at] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 23615(line=892, offs=5) -- 23913(line=899, offs=4) */ ATSstaticdec() ats_void_type intveclst1_free_52 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; __ats_lab_intveclst1_free_52: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp319 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp320 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; ATS_FREE(arg0) ; /* tmp321 = */ intvec_ptr_free_7 (tmp319) ; arg0 = tmp320 ; goto __ats_lab_intveclst1_free_52 ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; ATS_FREE(arg0) ; arg0 = tmp322 ; goto __ats_lab_intveclst1_free_52 ; // tail call break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: break ; } while (0) ; return /* (tmp318) */ ; } /* end of [intveclst1_free_52] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 23946(line=901, offs=5) -- 24285(line=908, offs=4) */ ATSstaticdec() ats_ptr_type intveclst1_backtrack_53 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; // ATSlocal_void (tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; __ats_lab_intveclst1_backtrack_53: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp325 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; ATS_FREE(arg0) ; /* tmp326 = */ intvec_ptr_free_7 (tmp324) ; arg0 = tmp325 ; goto __ats_lab_intveclst1_backtrack_53 ; // tail call break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp323 = tmp327 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp323 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2) ; break ; } while (0) ; return (tmp323) ; } /* end of [intveclst1_backtrack_53] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 24345(line=912, offs=5) -- 25090(line=933, offs=4) */ ATSstaticdec() ats_void_type fprint_intveclst1_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_int_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; __ats_lab_fprint_intveclst1_54: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp329 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_2) ; tmp332 = &ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_3) ; /* tmp333 = */ atspre_fprintf_exn (arg0, ATSstrcst("(%i;%i): "), tmp329, tmp331) ; /* tmp334 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__fprint_intvec (arg0, tmp330, arg2) ; /* tmp335 = */ atspre_fprint_newline (arg0) ; tmp336 = ats_ptrget_mac(ats_ptr_type, tmp332) ; arg0 = arg0 ; arg1 = tmp336 ; arg2 = arg2 ; goto __ats_lab_fprint_intveclst1_54 ; // tail call break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp337 = &ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp338 = ats_ptrget_mac(ats_ptr_type, tmp337) ; arg0 = arg0 ; arg1 = tmp338 ; arg2 = arg2 ; goto __ats_lab_fprint_intveclst1_54 ; // tail call break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: break ; } while (0) ; return /* (tmp328) */ ; } /* end of [fprint_intveclst1_54] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 25126(line=935, offs=5) -- 25361(line=943, offs=4) */ ATSstaticdec() ats_void_type print_intveclst1_55 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; // ATSlocal_void (tmp342) ; __ats_lab_print_intveclst1_55: tmp340 = atspre_stdout_get () ; tmp341 = ats_selsin_mac(tmp340, atslab_1) ; /* tmp342 = */ fprint_intveclst1_54 (tmp341, arg0, arg1) ; /* tmp339 = */ atspre_stdout_view_set () ; return /* (tmp339) */ ; } /* end of [print_intveclst1_55] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 25575(line=953, offs=16) -- 26494(line=982, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp343) ; ATSlocal (ats_int_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_int_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_bool_type, tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; // ATSlocal_void (tmp351) ; ATSlocal (ats_bool_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp344 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp345 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_1) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_2) ; tmp347 = &ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_3) ; tmp348 = atspre_lte_int_int (arg0, tmp344) ; if (tmp348) { tmp350 = ats_ptrget_mac(ats_ptr_type, tmp347) ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst (arg0, arg1, tmp350, arg3) ; tmp352 = atspre_igt (tmp346, 0) ; /* tmp351 = */ atspre_assert (tmp352) ; /* tmp343 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elim_at (arg1, tmp345, arg3, tmp346) ; } else { tmp353 = ats_ptrget_mac(ats_ptr_type, tmp347) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp353 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp354 = &ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp355 = ats_ptrget_mac(ats_ptr_type, tmp354) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp355 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst ; // tail call break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: break ; } while (0) ; return /* (tmp343) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 26749(line=995, offs=7) -- 27660(line=1017, offs=6) */ ATSstaticdec() ats_void_type loop_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp357) ; ATSlocal (ats_int_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; // ATSlocal_void (tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_loop_58: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp360 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp361 = ats_solver_fm_intvec_copy (tmp359, arg2) ; tmp362 = ats_selsin_mac(tmp361, atslab_2) ; /* tmp363 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst (tmp358, tmp362, arg1, arg2) ; tmp364 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp364, atslab_0, tmp362) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp364 ; // if (ats_ptrget_mac(ats_ptr_type, arg3) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp365 = &ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg3), atslab_1) ; tmp366 = ats_ptrget_mac(ats_ptr_type, tmp360) ; arg0 = tmp366 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp365 ; goto __ats_lab_loop_58 ; // tail call break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp367 = &ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp368 = ats_ptrget_mac(ats_ptr_type, tmp367) ; arg0 = tmp368 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_loop_58 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp369 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp369 ; break ; } while (0) ; return /* (tmp357) */ ; } /* end of [loop_58] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 26713(line=993, offs=3) -- 27781(line=1024, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp370) ; // ATSlocal_void (tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make: /* ats_ptr_type tmp370 ; */ /* tmp371 = */ loop_58 (arg0, arg1, arg2, (&tmp370)) ; tmp356 = tmp370 ; return (tmp356) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 27882(line=1031, offs=5) -- 33491(line=1167, offs=4) */ ATSstaticdec() ats_int_type aux_main_60 (ats_int_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_int_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_bool_type, tmp379) ; ATSlocal (ats_bool_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_bool_type, tmp385) ; // ATSlocal_void (tmp386) ; ATSlocal (ats_int_type, tmp387) ; ATSlocal (ats_int_type, tmp388) ; // ATSlocal_void (tmp389) ; ATSlocal (ats_int_type, tmp390) ; ATSlocal (ats_bool_type, tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_bool_type, tmp393) ; // ATSlocal_void (tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_int_type, tmp397) ; ATSlocal (ats_int_type, tmp398) ; ATSlocal (ats_bool_type, tmp399) ; ATSlocal (ats_int_type, tmp400) ; ATSlocal (ats_bool_type, tmp401) ; ATSlocal (ats_int_type, tmp402) ; // ATSlocal_void (tmp403) ; ATSlocal (ats_bool_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; // ATSlocal_void (tmp408) ; ATSlocal (ats_int_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; // ATSlocal_void (tmp411) ; ATSlocal (ats_bool_type, tmp412) ; // ATSlocal_void (tmp413) ; ATSlocal (ats_int_type, tmp414) ; ATSlocal (ats_int_type, tmp415) ; ATSlocal (ats_bool_type, tmp417) ; ATSlocal (ats_int_type, tmp418) ; ATSlocal (ats_int_type, tmp419) ; ATSlocal (ats_bool_type, tmp421) ; ATSlocal (ats_int_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; // ATSlocal_void (tmp424) ; ATSlocal (ats_bool_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_int_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_bool_type, tmp430) ; ATSlocal (ats_int_type, tmp431) ; ATSlocal (ats_int_type, tmp432) ; ATSlocal (ats_bool_type, tmp433) ; ATSlocal (ats_int_type, tmp434) ; // ATSlocal_void (tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_int_type, tmp439) ; ATSlocal (ats_int_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_int_type, tmp447) ; ATSlocal (ats_int_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; // ATSlocal_void (tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_int_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_int_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_bool_type, tmp461) ; ATSlocal (ats_int_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_int_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; __ats_lab_aux_main_60: do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { goto __ats_lab_61_0 ; } __ats_lab_55_1: tmp374 = &ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg4), atslab_0) ; tmp375 = &ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg4), atslab_1) ; tmp376 = ats_ptrget_mac(ats_ptr_type, tmp374) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp376)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_56_1: tmp377 = ats_caselptrlab_mac(anairiats_sum_0, tmp376, atslab_0) ; tmp378 = &ats_caselptrlab_mac(anairiats_sum_0, tmp376, atslab_1) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: tmp380 = atspre_eq_int_int (tmp377, 2) ; if (tmp380) { tmp379 = ats_true_bool ; } else { tmp379 = atspre_eq_int_int (tmp377, -2) ; } /* end of [if] */ if (!tmp379) { goto __ats_lab_58_1 ; } tmp382 = ats_ptrget_mac(ats_ptr_type, tmp378) ; tmp381 = ats_solver_fm_intvec_copy (tmp382, arg3) ; tmp383 = ats_selsin_mac(tmp381, atslab_2) ; tmp385 = atspre_lt_int_int (tmp377, 0) ; if (tmp385) { /* tmp386 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate (tmp383, arg3) ; tmp388 = ats_caselptrind_mac(ats_int_type, tmp383, [0]) ; tmp387 = atsopt_solver_fm_pred_i0nt (tmp388) ; ats_caselptrind_mac(ats_int_type, tmp383, [0]) = tmp387 ; } else { /* empty */ } /* end of [if] */ /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst (0, tmp383, ats_ptrget_mac(ats_ptr_type, arg2), arg3) ; tmp390 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_gte (tmp383, arg3) ; tmp391 = atspre_igt (tmp390, 0) ; if (tmp391) { /* tmp392 = */ intvec_ptr_free_7 (tmp383) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp375 ; goto __ats_lab_aux_main_60 ; // tail call } else { tmp393 = atspre_ilt (tmp390, 0) ; if (tmp393) { /* tmp394 = */ intvec_ptr_free_7 (tmp383) ; tmp373 = -1 ; } else { tmp395 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp395)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp395, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp395, atslab_1, tmp383) ; ats_selptrset_mac(anairiats_sum_2, tmp395, atslab_2, 0) ; ats_selptrset_mac(anairiats_sum_2, tmp395, atslab_3, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp395 ; /* ats_ptr_type tmp396 ; */ tmp396 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make (ats_ptrget_mac(ats_ptr_type, arg1), ats_ptrget_mac(ats_ptr_type, arg2), arg3) ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte ((&tmp396), arg3) ; tmp399 = atspre_igte (tmp397, 0) ; if (tmp399) { tmp400 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve (tmp396, arg3) ; tmp401 = atspre_igte (tmp400, 0) ; if (tmp401) { tmp402 = atspre_add_int_int (arg0, 1) ; tmp398 = aux_main_60 (tmp402, arg1, arg2, arg3, tmp375) ; } else { tmp398 = -1 ; } /* end of [if] */ } else { /* tmp403 = */ intveclst_free_19 (tmp396) ; tmp398 = -1 ; } /* end of [if] */ tmp373 = tmp398 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: __ats_lab_58_1: tmp404 = atspre_eq_int_int (tmp377, 1) ; if (!tmp404) { goto __ats_lab_59_1 ; } tmp406 = ats_ptrget_mac(ats_ptr_type, tmp378) ; tmp405 = ats_solver_fm_intvec_copy (tmp406, arg3) ; tmp407 = ats_selsin_mac(tmp405, atslab_2) ; /* tmp408 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_elimlst (0, tmp407, ats_ptrget_mac(ats_ptr_type, arg2), arg3) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_inspect_eq (tmp407, arg3) ; tmp410 = atspre_igt (tmp409, 0) ; if (tmp410) { /* tmp411 = */ intvec_ptr_free_7 (tmp407) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp375 ; goto __ats_lab_aux_main_60 ; // tail call } else { tmp412 = atspre_ilt (tmp409, 0) ; if (tmp412) { /* tmp413 = */ intvec_ptr_free_7 (tmp407) ; tmp373 = -1 ; } else { tmp414 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_absmin_coeff_index_get (tmp407, arg3) ; /* ats_int_type tmp415 ; */ tmp415 = ats_caselptrind_mac(ats_int_type, tmp407, [tmp414]) ; tmp417 = atsopt_solver_fm_lt_i0nt_int (tmp415, 0) ; if (tmp417) { tmp418 = atsopt_solver_fm_neg_i0nt (tmp415) ; tmp415 = tmp418 ; } else { /* empty */ } /* end of [if] */ /* ats_int_type tmp419 ; */ tmp419 = 0 ; tmp421 = atsopt_solver_fm_gt_i0nt_int (tmp415, 1) ; if (tmp421) { tmp422 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_normalize_eq (tmp407, arg3) ; tmp419 = tmp422 ; } else { /* empty */ } /* end of [if] */ /* ats_ptr_type tmp423 ; */ tmp425 = atspre_igte (tmp419, 0) ; if (tmp425) { tmp426 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp426)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp426, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp426, atslab_1, tmp407) ; ats_selptrset_mac(anairiats_sum_2, tmp426, atslab_2, tmp414) ; ats_selptrset_mac(anairiats_sum_2, tmp426, atslab_3, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp426 ; tmp427 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_make (ats_ptrget_mac(ats_ptr_type, arg1), ats_ptrget_mac(ats_ptr_type, arg2), arg3) ; tmp423 = tmp427 ; tmp428 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_inspect_gte ((&tmp423), arg3) ; tmp419 = tmp428 ; } else { tmp429 = (ats_sum_ptr_type)0 ; tmp423 = tmp429 ; /* tmp424 = */ intvec_ptr_free_7 (tmp407) ; } /* end of [if] */ tmp430 = atspre_igte (tmp419, 0) ; if (tmp430) { tmp431 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intveclst_solve (tmp423, arg3) ; tmp433 = atspre_igte (tmp431, 0) ; if (tmp433) { tmp434 = atspre_add_int_int (arg0, 1) ; tmp432 = aux_main_60 (tmp434, arg1, arg2, arg3, tmp375) ; } else { tmp432 = -1 ; } /* end of [if] */ tmp373 = tmp432 ; } else { /* tmp435 = */ intveclst_free_19 (tmp423) ; tmp373 = -1 ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp437 = ats_ptrget_mac(ats_ptr_type, tmp378) ; tmp436 = ats_solver_fm_intvec_copy (tmp437, arg3) ; tmp438 = ats_selsin_mac(tmp436, atslab_2) ; tmp440 = ats_caselptrind_mac(ats_int_type, tmp438, [0]) ; tmp439 = atsopt_solver_fm_pred_i0nt (tmp440) ; ats_caselptrind_mac(ats_int_type, tmp438, [0]) = tmp439 ; tmp441 = atsopt_solver_fm_intvecptr_make_view_ptr (tmp438) ; tmp442 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp442)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp442, atslab_0, 2) ; ats_selptrset_mac(anairiats_sum_0, tmp442, atslab_1, tmp441) ; tmp444 = ats_ptrget_mac(ats_ptr_type, tmp378) ; tmp443 = ats_solver_fm_intvec_copy (tmp444, arg3) ; tmp445 = ats_selsin_mac(tmp443, atslab_2) ; /* tmp446 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__intvec_negate (tmp445, arg3) ; tmp448 = ats_caselptrind_mac(ats_int_type, tmp445, [0]) ; tmp447 = atsopt_solver_fm_pred_i0nt (tmp448) ; ats_caselptrind_mac(ats_int_type, tmp445, [0]) = tmp447 ; tmp449 = atsopt_solver_fm_intvecptr_make_view_ptr (tmp445) ; tmp450 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp450)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp450, atslab_0, 2) ; ats_selptrset_mac(anairiats_sum_0, tmp450, atslab_1, tmp449) ; tmp452 = ats_ptrget_mac(ats_ptr_type, tmp378) ; /* tmp451 = */ atsopt_solver_fm_intvecptr_free (tmp452) ; tmp453 = ats_ptrget_mac(ats_ptr_type, tmp374) ; ATS_FREE(tmp453) ; tmp456 = (ats_sum_ptr_type)0 ; tmp455 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp455, atslab_0, tmp450) ; ats_selptrset_mac(anairiats_sum_1, tmp455, atslab_1, tmp456) ; tmp454 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp454, atslab_0, tmp442) ; ats_selptrset_mac(anairiats_sum_1, tmp454, atslab_1, tmp455) ; tmp457 = aux_main_disj_61 (arg0, arg1, arg2, arg3, tmp375, tmp454) ; tmp458 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp458)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp458, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_0, tmp458, atslab_1, tmp454) ; ats_ptrget_mac(ats_ptr_type, tmp374) = tmp458 ; tmp373 = tmp457 ; break ; } while (0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (((ats_sum_ptr_type)tmp376)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp459 = ats_caselptrlab_mac(anairiats_sum_0, tmp376, atslab_0) ; tmp460 = &ats_caselptrlab_mac(anairiats_sum_0, tmp376, atslab_1) ; tmp461 = atspre_eq_int_int (tmp459, 0) ; if (tmp461) { tmp463 = ats_ptrget_mac(ats_ptr_type, tmp460) ; tmp462 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed (tmp463) ; tmp465 = ats_ptrget_mac(ats_ptr_type, tmp460) ; tmp466 = ats_ptrget_mac(ats_ptr_type, tmp375) ; tmp464 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_append (tmp465, tmp466) ; ats_ptrget_mac(ats_ptr_type, tmp375) = tmp464 ; tmp467 = aux_main_60 (arg0, arg1, arg2, arg3, tmp375) ; tmp468 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_prefix (tmp375, tmp462) ; ats_ptrget_mac(ats_ptr_type, tmp460) = tmp468 ; tmp373 = tmp467 ; } else { tmp469 = ats_ptrget_mac(ats_ptr_type, tmp460) ; tmp373 = aux_main_disj_61 (arg0, arg1, arg2, arg3, tmp375, tmp469) ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (ats_ptrget_mac(ats_ptr_type, arg4) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: tmp373 = 0 ; break ; } while (0) ; return (tmp373) ; } /* end of [aux_main_60] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 33520(line=1169, offs=5) -- 34511(line=1196, offs=4) */ ATSstaticdec() ats_int_type aux_main_disj_61 (ats_int_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_int_type arg3, ats_ref_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_int_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_int_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_bool_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; __ats_lab_aux_main_disj_61: do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp471 = &ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_0) ; tmp472 = &ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_1) ; tmp473 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp473)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp473, atslab_0, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp473 ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp474)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp474, atslab_0, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp474 ; tmp476 = ats_ptrget_mac(ats_ptr_type, tmp471) ; tmp475 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp475, atslab_0, tmp476) ; ats_selptrset_mac(anairiats_sum_1, tmp475, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp475 ; tmp477 = aux_main_60 (arg0, arg1, arg2, arg3, arg4) ; // if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp478 = ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg4), atslab_0) ; tmp479 = ats_caselptrlab_mac(anairiats_sum_1, ats_ptrget_mac(ats_ptr_type, arg4), atslab_1) ; ATS_FREE(ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, tmp471) = tmp478 ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp479 ; tmp480 = intveclst1_backtrack_53 (ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp480 ; tmp481 = intveclst1_backtrack_53 (ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp481 ; tmp482 = atspre_igte (tmp477, 0) ; if (tmp482) { tmp470 = 0 ; } else { tmp483 = ats_ptrget_mac(ats_ptr_type, tmp472) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp483 ; goto __ats_lab_aux_main_disj_61 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp470 = -1 ; break ; } while (0) ; return (tmp470) ; } /* end of [aux_main_disj_61] */ /* // /home/hwxi/research/Anairiats/src/ats_solver_fm.dats: 27860(line=1029, offs=20) -- 34748(line=1204, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_solve (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp372) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_int_type, tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_solve: /* ats_ptr_type tmp484 ; */ tmp484 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2) ; /* ats_ptr_type tmp485 ; */ tmp485 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2) ; tmp486 = aux_main_60 (0, (&tmp485), (&tmp484), arg1, arg0) ; /* tmp487 = */ intveclst1_free_52 (tmp484) ; /* tmp488 = */ intveclst1_free_52 (tmp485) ; tmp372 = tmp486 ; return (tmp372) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_solve] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1cons_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1mark_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__INTVECLST1nil_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp1, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_int_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp1 = atsopt_solver_fm_i0nt_of_int (0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_0, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_0 = statmp1 ; statmp2 = atsopt_solver_fm_i0nt_of_int (1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1 = statmp2 ; statmp3 = atsopt_solver_fm_i0nt_of_int (-1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1 = statmp3 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_solver_fm_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_fixity_prec_dats.c0000664000175000017500000003247312223166157022463 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_compare_int_int) (ats_int_type, ats_int_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int) (ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__sasp__prec_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__neginf_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__posinf_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__backslash_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__infixtemp_prec) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exi_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__uni_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exist_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__dynload_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ptrof_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__foldat_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__freeat_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__viewat_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmark_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmarkbang_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__r0ead_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__trans_prec_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__crypt_prec_dyn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_prec_dyn) ; /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_int_type, statmp0) ; ATSstatic (ats_int_type, statmp1) ; ATSstatic (ats_int_type, statmp2) ; ATSstatic (ats_int_type, statmp3) ; ATSstatic (ats_int_type, statmp4) ; ATSstatic (ats_int_type, statmp5) ; ATSstatic (ats_int_type, statmp6) ; ATSstatic (ats_int_type, statmp7) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_prec.dats: 3092(line=118, offs=23) -- 3099(line=118, offs=30) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec: tmp8 = arg0 ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_prec.dats: 3125(line=120, offs=25) -- 3218(line=121, offs=77) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_bool_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: __ats_lab_0_1: tmp10 = atspre_lte_int_int (arg0, -1000000) ; if (!tmp10) { goto __ats_lab_1_1 ; } tmp9 = -1000000 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp11 = atspre_gte_int_int (arg0, 1000000) ; if (!tmp11) { goto __ats_lab_2_1 ; } tmp9 = 1000000 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp9 = arg0 ; break ; } while (0) ; return (tmp9) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_prec.dats: 3292(line=126, offs=26) -- 3321(line=126, offs=55) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_inc (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp12) ; ATSlocal (ats_int_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_inc: tmp13 = atspre_add_int_int (arg0, arg1) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int (tmp13) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_prec.dats: 3348(line=127, offs=26) -- 3377(line=127, offs=55) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_dec (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_dec: tmp15 = atspre_sub_int_int (arg0, arg1) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int (tmp15) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_prec.dats: 3429(line=131, offs=29) -- 3464(line=131, offs=64) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec: tmp16 = atspre_compare_int_int (arg0, arg1) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp1, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp6, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_int_type)) ; /* marking external values for GC */ /* code for dynamic loading */ ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__neginf_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__neginf_prec = -1000000 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__posinf_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__posinf_prec = 1000000 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec = 70 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec = 80 ; statmp0 = atspre_add_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__backslash_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__backslash_prec = statmp0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__infixtemp_prec, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__infixtemp_prec = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exi_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exi_prec_sta = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__uni_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__uni_prec_sta = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exist_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exist_prec_dyn = 0 ; statmp1 = atspre_add_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__dynload_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__dynload_prec_dyn = statmp1 ; statmp2 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ptrof_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ptrof_prec_dyn = statmp2 ; statmp3 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__foldat_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__foldat_prec_dyn = statmp3 ; statmp4 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__freeat_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__freeat_prec_dyn = statmp4 ; statmp5 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__viewat_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__viewat_prec_dyn = statmp5 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta = 1 ; statmp6 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmark_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmark_prec_sta = statmp6 ; statmp7 = atspre_sub_int_int (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmarkbang_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmarkbang_prec_sta = statmp7 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__r0ead_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__r0ead_prec_sta = 100 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__trans_prec_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__trans_prec_sta = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__crypt_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__crypt_prec_dyn = 0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_prec_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_prec_dyn = 100 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_fixity_prec_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_keyword_dats.c0000664000175000017500000002742612223166157021624 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* ** HX-2011-01-26: ** extern YYSTYPE yylval ; // generated by [bison] */ typedef void YYSTYPE ; #define YYSTYPE_IS_DECLARED 1 #include "ats_grammar_yats.h" typedef struct { char *key ; int val ; } keyval ; #define KEYWORD_TABLE_SIZE 1024 keyval theKeywordTable[KEYWORD_TABLE_SIZE] = {0} ; static void keyval_insert ( char *key, int val ) { unsigned int hash_val ; int i ; keyval *itm ; // hash_val = atspre_string_hash_33 ((char*)key) ; i = hash_val % KEYWORD_TABLE_SIZE ; itm = &theKeywordTable[i] ; // while (itm->key) { i += 1 ; if (i == KEYWORD_TABLE_SIZE) i = 0 ; itm = &theKeywordTable[i] ; } // end of [while] // itm->key = (char*)key ; itm->val = (int)val ; return ; } // end of [keyval_insert] ats_int_type atsopt_keyword_search (ats_ptr_type key) { unsigned int hash_val ; int i ; keyval *itm ; // hash_val = atspre_string_hash_33 (key) ; i = hash_val % KEYWORD_TABLE_SIZE ; itm = &theKeywordTable[i] ; // while (itm->key) { if (!strcmp((char*)key, itm->key)) return itm->val ; i += 1 ; if (i == KEYWORD_TABLE_SIZE) i = 0 ; itm = &theKeywordTable[i] ; } // end of [while] // return -1 ; } // end of [atsopt_keyword_search] static ats_void_type atsopt_keyval_table_initialize ( // no argument for this function ) { // // HX: [theKeywordTable] is already initialized: // #if(0) memset (&theKeywordTable[0], 0, sizeof(theKeywordTable)) ; #endif // // HX: symbolic keywords // keyval_insert("&", AMPERSAND) ; keyval_insert("`", BACKQUOTE) ; keyval_insert("!", BANG) ; keyval_insert("|", BAR) ; keyval_insert(":", COLON) ; keyval_insert("$", DOLLAR) ; keyval_insert(".", DOT) ; keyval_insert("=", EQ) ; keyval_insert("#", HASH) ; keyval_insert("~", TILDE) ; keyval_insert("..", DOTDOT) ; keyval_insert("...", DOTDOTDOT) ; keyval_insert("=>", EQGT) ; // implication without decoration keyval_insert("=<", EQLT) ; // implication decoration keyval_insert("=<>", EQLTGT) ; // implication with empty decoration keyval_insert("=/=>", EQSLASHEQGT) ; keyval_insert("=>>", EQGTGT) ; keyval_insert("=/=>>", EQSLASHEQGTGT) ; keyval_insert("<", LT) ; keyval_insert(">", GT) ; keyval_insert("><", GTLT) ; keyval_insert(".<", DOTLT) ; keyval_insert(">.", GTDOT) ; // .<...>. : metric keyval_insert(".<>.", DOTLTGTDOT) ; keyval_insert("->", MINUSGT) ; // implication keyval_insert("-<", MINUSLT) ; // -<...> : decorated implication keyval_insert("-<>", MINUSLTGT) ; keyval_insert(":<", COLONLT) ; // :<...> : decorated implication keyval_insert(":<>", COLONLTGT) ; // // HX: alphanumeric keywords // keyval_insert("absprop", ABSPROP) ; keyval_insert("abstype", ABSTYPE) ; keyval_insert("absview", ABSVIEW) ; keyval_insert("absvtype", ABSVIEWTYPE) ; keyval_insert("absviewtype", ABSVIEWTYPE) ; keyval_insert("and", AND) ; keyval_insert("as", AS) ; keyval_insert("assume", ASSUME) ; keyval_insert("begin", BEGIN) ; keyval_insert("break", BREAK) ; keyval_insert("case", CASE) ; keyval_insert("castfn", CASTFN) ; // for casting functions keyval_insert("classdec", CLASSDEC) ; keyval_insert("continue", CONTINUE) ; keyval_insert("datasort", DATASORT) ; keyval_insert("dataparasort", DATAPARASORT) ; keyval_insert("dataprop", DATAPROP) ; keyval_insert("datatype", DATATYPE) ; keyval_insert("dataview", DATAVIEW) ; keyval_insert("datavtype", DATAVIEWTYPE) ; keyval_insert("dataviewtype", DATAVIEWTYPE) ; keyval_insert("do", DO) ; keyval_insert("dyn", DYN) ; keyval_insert("dynload", DYNLOAD) ; keyval_insert("else", ELSE) ; keyval_insert("end", END) ; keyval_insert("exception", EXCEPTION) ; keyval_insert("extern", EXTERN) ; keyval_insert("fix", FIX) ; keyval_insert("fn", FN) ; keyval_insert("for", FOR) ; keyval_insert("fun", FUN) ; keyval_insert("if", IF) ; keyval_insert("implement", IMPLEMENT) ; keyval_insert("in", IN) ; keyval_insert("infix", INFIX) ; keyval_insert("infixl", INFIXL) ; keyval_insert("infixr", INFIXR) ; keyval_insert("lam", LAM) ; keyval_insert("let", LET) ; keyval_insert("llam", LLAM) ; keyval_insert("local", LOCAL) ; keyval_insert("macdef", MACDEF) ; keyval_insert("macrodef", MACRODEF) ; /* keyval_insert("method", METHOD) ; keyval_insert("modcls", MODCLS) ; */ keyval_insert("nonfix", NONFIX) ; keyval_insert("overload", OVERLOAD) ; keyval_insert("par", PAR) ; keyval_insert("postfix", POSTFIX) ; keyval_insert("praxi", PRAXI) ; keyval_insert("prefix", PREFIX) ; keyval_insert("prfn", PRFN) ; keyval_insert("prfun", PRFUN) ; keyval_insert("prval", PRVAL) ; keyval_insert("of", OF) ; keyval_insert("op", OP) ; keyval_insert("propdef", PROPDEF) ; keyval_insert("rec", REC) ; keyval_insert("scase", SCASE) ; keyval_insert("sif", SIF) ; keyval_insert("sortdef", SORTDEF) ; keyval_insert("sta", STACST) ; // HX-2011-09-09: BWC keyval_insert("stacst", STACST) ; // HX-2011-09-09: sta -> stacst keyval_insert("stadef", STADEF) ; keyval_insert("staif", STAIF) ; keyval_insert("staload", STALOAD) ; keyval_insert("stavar", STAVAR) ; /* keyval_insert("struct", STRUCT) ; keyval_insert("super", SUPER) ; */ keyval_insert("symelim", SYMELIM) ; keyval_insert("symintr", SYMINTR) ; keyval_insert("then", THEN) ; keyval_insert("try", TRY) ; keyval_insert("typedef", TYPEDEF) ; /* keyval_insert("union", UNION) ; */ keyval_insert("val", VAL) ; keyval_insert("var", VAR) ; keyval_insert("viewdef", VIEWDEF) ; keyval_insert("vtypedef", VIEWTYPEDEF) ; keyval_insert("viewtypedef", VIEWTYPEDEF) ; keyval_insert("when", WHEN) ; keyval_insert("where", WHERE) ; keyval_insert("while", WHILE) ; keyval_insert("with", WITH) ; keyval_insert("withprop", WITHPROP) ; keyval_insert("withtype", WITHTYPE) ; keyval_insert("withview", WITHVIEW) ; keyval_insert("withvtype", WITHVIEWTYPE) ; keyval_insert("withviewtype", WITHVIEWTYPE) ; // keyval_insert("$arrpsz", DLRARRPSZ) ; keyval_insert("$decrypt", DLRDECRYPT) ; keyval_insert("$delay", DLRDELAY) ; // $delay keyval_insert("$dynload", DLRDYNLOAD) ; /* keyval_insert("$exec", DLREXEC) ; */ keyval_insert("$effmask_all", DLREFFMASK_ALL) ; keyval_insert("$effmask_exn", DLREFFMASK_EXN) ; keyval_insert("$effmask_ntm", DLREFFMASK_NTM) ; keyval_insert("$effmask_ref", DLREFFMASK_REF) ; keyval_insert("$extern", DLREXTERN) ; keyval_insert("$extval", DLREXTVAL) ; keyval_insert("$extype", DLREXTYPE) ; keyval_insert("$extype_struct", DLREXTYPE_STRUCT) ; keyval_insert("$encrypt", DLRENCRYPT) ; /* keyval_insert("$fold", DLRFOLD) ; */ keyval_insert("$ldelay", DLRLDELAY) ; // linear $delay keyval_insert("$lst", DLRLST_T) ; keyval_insert("$lst_t", DLRLST_T) ; keyval_insert("$lst_vt", DLRLST_VT) ; keyval_insert("$raise", DLRRAISE) ; keyval_insert("$rec_t", DLRREC_T) ; keyval_insert("$rec_vt", DLRREC_VT) ; keyval_insert("$tup_t", DLRTUP_T) ; keyval_insert("$tup_vt", DLRTUP_VT) ; keyval_insert("$showtype", DLRSHOWTYPE) ; /* keyval_insert("$unfold", DLRUNFOLD) ; */ // keyval_insert("#assert", SRPASSERT) ; keyval_insert("#define", SRPDEFINE) ; keyval_insert("#elif", SRPELIF) ; keyval_insert("#elifdef", SRPELIFDEF) ; keyval_insert("#elifndef", SRPELIFNDEF) ; keyval_insert("#else", SRPELSE) ; keyval_insert("#endif", SRPENDIF) ; keyval_insert("#error", SRPERROR) ; keyval_insert("#if", SRPIF) ; keyval_insert("#ifdef", SRPIFDEF) ; keyval_insert("#ifndef", SRPIFNDEF) ; keyval_insert("#include", SRPINCLUDE) ; keyval_insert("#print", SRPPRINT) ; keyval_insert("#then", SRPTHEN) ; keyval_insert("#undef", SRPUNDEF) ; // keyval_insert("#FILENAME", SRPFILENAME) ; keyval_insert("#LOCATION", SRPLOCATION) ; /* // // HX: these keywords are hard-wired into [ats_lexer.lats]: // keyval_insert("fn*", FNSTAR) keyval_insert("for*", FORSTAR) keyval_insert("while*", WHILESTAR) // keyval_insert("@lam", ATLAM) ; keyval_insert("@llam", ATLLAM) ; keyval_insert("@fix", ATFIX) ; // keyval_insert("fold@", FOLDAT) ; keyval_insert("free@", FREEAT) ; keyval_insert("view@", VIEWAT) ; // keyval_insert("r@ead", R0EAD) ; // keyval_insert("val+", VALPLUS) ; keyval_insert("val-", VALMINUS) ; keyval_insert("case+", CASEPLUS) ; keyval_insert("case-", CASEMINUS) ; // keyval_insert("prop+", PROPPLUS) ; keyval_insert("prop-", PROPMINUS) ; keyval_insert("type+", TYPEPLUS) ; keyval_insert("type-", TYPEMINUS) ; keyval_insert("view+", VIEWPLUS) ; keyval_insert("view-", VIEWMINUS) ; keyval_insert("vtype+", VIEWTYPEPLUS) ; keyval_insert("vtype-", VIEWTYPEMINUS) ; keyval_insert("viewtype+", VIEWTYPEPLUS) ; keyval_insert("viewtype-", VIEWTYPEMINUS) ; // keyval_insert("abst@ype", ABST0YPE) ; keyval_insert("absviewt@ype", ABSVIEWT0YPE) ; // keyval_insert("t@ype", T0YPE) ; keyval_insert("t@ype+", T0YPEPLUS) ; keyval_insert("t@ype-", T0YPEMINUS) ; keyval_insert("vt@ype", VIEWT0YPE) ; keyval_insert("vt@ype+", VIEWT0YPEPLUS) ; keyval_insert("vt@ype-", VIEWT0YPEMINUS) ; keyval_insert("viewt@ype", VIEWT0YPE) ; keyval_insert("viewt@ype+", VIEWT0YPEPLUS) ; keyval_insert("viewt@ype-", VIEWT0YPEMINUS) ; */ return ; } // end of [atsopt_keyval_table_initialize] /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atsopt_keyval_table_initialize) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ // ATSstatic_void (statmp0) ; /* external value variable declarations */ /* function implementations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ /* statmp0 = */ atsopt_keyval_table_initialize () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_keyword_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_posmark_sats.c0000664000175000017500000000221312223166157021616 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_posmark_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_charlst_sats.c0000664000175000017500000000245612223166157021613 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1.tag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_charlst_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_namespace_sats.c0000664000175000017500000000222112223166157022075 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_namespace_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_print_dats.c0000664000175000017500000036433012223166157022743 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_d2sym_loc ; ats_ptr_type atslab_d2sym_qua ; ats_ptr_type atslab_d2sym_sym ; ats_ptr_type atslab_d2sym_itm ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_i2nvarg_var ; ats_ptr_type atslab_i2nvarg_typ ; } anairiats_rec_11 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_14 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_d2lab_loc ; ats_ptr_type atslab_d2lab_node ; } anairiats_rec_23 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMe1xp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacdef_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Edynload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloatsp_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eintsp_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALarrsub_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_lin_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_mut_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALnone_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2expopt) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labp2atlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarg) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_16 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 1892(line=58, offs=24) -- 2008(line=61, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym: tmp2 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_d2sym_qua) ; /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (arg0, tmp2) ; tmp3 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_d2sym_sym) ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp3) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 2057(line=63, offs=23) -- 2094(line=63, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2sym (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2sym: tmp5 = atspre_stdout_get () ; tmp6 = ats_selsin_mac(tmp5, atslab_1) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym (tmp6, arg0) ; /* tmp4 = */ atspre_stdout_view_set () ; return /* (tmp4) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 2117(line=64, offs=23) -- 2154(line=64, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym: tmp9 = atspre_stderr_get () ; tmp10 = ats_selsin_mac(tmp9, atslab_1) ; /* tmp11 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym (tmp10, arg0) ; /* tmp8 = */ atspre_stderr_view_set () ; return /* (tmp8) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 2201(line=68, offs=25) -- 3201(line=93, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMcon(")) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst (arg0, tmp13) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp17 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMcst(")) ; /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp16) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp20 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMe1xp(")) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (arg0, tmp19) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp23 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMmacdef(")) ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac (arg0, tmp22) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp25 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp26 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMmacvar(")) ; /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp25) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp29 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMsymdef(")) ; /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst (arg0, tmp28) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (((ats_sum_ptr_type)arg1)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp32 = */ atspre_fprint_string (arg0, ATSstrcst("D2ITEMvar(")) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp31) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3252(line=95, offs=24) -- 3290(line=95, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2item (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2item: tmp35 = atspre_stdout_get () ; tmp36 = ats_selsin_mac(tmp35, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item (tmp36, arg0) ; /* tmp34 = */ atspre_stdout_view_set () ; return /* (tmp34) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2item] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3314(line=96, offs=24) -- 3352(line=96, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2item (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2item: tmp39 = atspre_stderr_get () ; tmp40 = ats_selsin_mac(tmp39, atslab_1) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item (tmp40, arg0) ; /* tmp38 = */ atspre_stderr_view_set () ; return /* (tmp38) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2item] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3402(line=101, offs=18) -- 3480(line=102, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst: /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2item) ; return /* (tmp42) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3536(line=105, offs=27) -- 3579(line=105, offs=70) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2itemlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2itemlst: tmp44 = atspre_stdout_get () ; tmp45 = ats_selsin_mac(tmp44, atslab_1) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst (tmp45, arg0) ; /* tmp43 = */ atspre_stdout_view_set () ; return /* (tmp43) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3606(line=106, offs=27) -- 3649(line=106, offs=70) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2itemlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; // ATSlocal_void (tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2itemlst: tmp48 = atspre_stderr_get () ; tmp49 = ats_selsin_mac(tmp48, atslab_1) ; /* tmp50 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2itemlst (tmp49, arg0) ; /* tmp47 = */ atspre_stderr_view_set () ; return /* (tmp47) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 3694(line=111, offs=13) -- 6533(line=201, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; // ATSlocal_void (tmp58) ; ATSlocal (ats_int_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; ATSlocal (ats_bool_type, tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; ATSlocal (ats_bool_type, tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; ATSlocal (ats_char_type, tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; ATSlocal (ats_bool_type, tmp79) ; // ATSlocal_void (tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_int_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; ATSlocal (ats_int_type, tmp103) ; ATSlocal (ats_int_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; // ATSlocal_void (tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; ATSlocal (ats_int_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; ATSlocal (ats_bool_type, tmp119) ; // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at: tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_p2at_node) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp52)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_3, tmp52, atslab_0) ; tmp54 = ats_caselptrlab_mac(anairiats_sum_3, tmp52, atslab_1) ; /* tmp55 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tann(")) ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (arg0, tmp53) ; /* tmp57 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp54) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp52)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tany()")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp52)->tag != 2) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_4, tmp52, atslab_0) ; tmp60 = ats_caselptrlab_mac(anairiats_sum_4, tmp52, atslab_1) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_4, tmp52, atslab_2) ; /* tmp62 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tas(")) ; tmp64 = atspre_gt_int_int (tmp59, 0) ; if (tmp64) { /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("!")) ; } else { /* empty */ } /* end of [if] */ /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp60) ; /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (arg0, tmp61) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp52)->tag != 3) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_5, tmp52, atslab_0) ; /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tbool(")) ; /* tmp70 = */ atspre_fprint_bool (arg0, tmp68) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp52)->tag != 4) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_6, tmp52, atslab_0) ; /* tmp72 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tchar(")) ; /* tmp73 = */ atspre_fprint_char (arg0, tmp71) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp52)->tag != 5) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_7, tmp52, atslab_0) ; tmp75 = ats_caselptrlab_mac(anairiats_sum_7, tmp52, atslab_1) ; tmp76 = ats_caselptrlab_mac(anairiats_sum_7, tmp52, atslab_5) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tcon(")) ; tmp79 = atspre_lt_int_int (tmp74, 0) ; if (tmp79) { /* tmp78 = */ atspre_fprint_string (arg0, ATSstrcst("~")) ; } else { /* empty */ } /* end of [if] */ /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp75) ; /* tmp81 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (arg0, tmp76) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp52)->tag != 6) { goto __ats_lab_14_0 ; } __ats_lab_13_1: /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tempty()")) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp52)->tag != 7) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_3, tmp52, atslab_1) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst("P2Texist(")) ; /* tmp85 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp86 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (arg0, tmp83) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp52)->tag != 8) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; /* tmp89 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tfloat(")) ; /* tmp90 = */ atspre_fprint_string (arg0, tmp88) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp52)->tag != 9) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_3, tmp52, atslab_0) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tint(")) ; /* tmp93 = */ atspre_fprint_string (arg0, tmp91) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp52)->tag != 10) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_8, tmp52, atslab_0) ; tmp95 = ats_caselptrlab_mac(anairiats_sum_8, tmp52, atslab_1) ; /* tmp96 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tlist(")) ; /* tmp97 = */ atspre_fprint_int (arg0, tmp94) ; /* tmp98 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp99 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (arg0, tmp95) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp52)->tag != 11) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; /* tmp101 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tlst(")) ; /* tmp102 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (arg0, tmp100) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp52)->tag != 12) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_9, tmp52, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_9, tmp52, atslab_1) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_9, tmp52, atslab_2) ; /* tmp106 = */ atspre_fprint_string (arg0, ATSstrcst("P2Trec(")) ; /* tmp107 = */ atspre_fprint_int (arg0, tmp103) ; /* tmp108 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp109 = */ atspre_fprint_int (arg0, tmp104) ; /* tmp110 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labp2atlst (arg0, tmp105) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp52)->tag != 13) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; /* tmp113 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tstring(\"")) ; /* tmp114 = */ atspre_fprint_string (arg0, tmp112) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("\")")) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp52)->tag != 14) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_8, tmp52, atslab_0) ; tmp116 = ats_caselptrlab_mac(anairiats_sum_8, tmp52, atslab_1) ; /* tmp117 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tvar(")) ; tmp119 = atspre_gt_int_int (tmp115, 0) ; if (tmp119) { /* tmp118 = */ atspre_fprint_string (arg0, ATSstrcst("!")) ; } else { /* empty */ } /* end of [if] */ /* tmp120 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp116) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (((ats_sum_ptr_type)tmp52)->tag != 15) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; /* tmp122 = */ atspre_fprint_string (arg0, ATSstrcst("P2Tvbox(")) ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp121) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp51) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 6580(line=203, offs=22) -- 6616(line=203, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2at: tmp125 = atspre_stdout_get () ; tmp126 = ats_selsin_mac(tmp125, atslab_1) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (tmp126, arg0) ; /* tmp124 = */ atspre_stdout_view_set () ; return /* (tmp124) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 6638(line=204, offs=22) -- 6674(line=204, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at: tmp129 = atspre_stderr_get () ; tmp130 = ats_selsin_mac(tmp129, atslab_1) ; /* tmp131 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (tmp130, arg0) ; /* tmp128 = */ atspre_stderr_view_set () ; return /* (tmp128) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 6722(line=209, offs=16) -- 6796(line=210, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst: /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at) ; return /* (tmp132) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 6849(line=213, offs=25) -- 6890(line=213, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2atlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; // ATSlocal_void (tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2atlst: tmp134 = atspre_stdout_get () ; tmp135 = ats_selsin_mac(tmp134, atslab_1) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (tmp135, arg0) ; /* tmp133 = */ atspre_stdout_view_set () ; return /* (tmp133) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 6915(line=214, offs=25) -- 6956(line=214, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2atlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2atlst: tmp138 = atspre_stderr_get () ; tmp139 = ats_selsin_mac(tmp138, atslab_1) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (tmp139, arg0) ; /* tmp137 = */ atspre_stderr_view_set () ; return /* (tmp137) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 7041(line=220, offs=7) -- 7571(line=233, offs=6) */ ATSstaticdec() ats_void_type aux_16 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_bool_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_int_type, tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_bool_type, tmp153) ; __ats_lab_aux_16: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_10, arg2, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_10, arg2, atslab_1) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_10, arg2, atslab_2) ; tmp147 = atspre_gt_int_int (arg1, 0) ; if (tmp147) { /* tmp146 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp143) ; /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2at (arg0, tmp144) ; tmp151 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp151 ; arg2 = tmp145 ; goto __ats_lab_aux_16 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (((ats_sum_ptr_type)arg2)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp153 = atspre_gt_int_int (arg1, 0) ; if (tmp153) { /* tmp152 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp142 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; break ; } while (0) ; return /* (tmp142) */ ; } /* end of [aux_16] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 7011(line=219, offs=23) -- 7616(line=236, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labp2atlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labp2atlst: /* tmp141 = */ aux_16 (arg0, 0, arg1) ; return /* (tmp141) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labp2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 7694(line=241, offs=16) -- 7886(line=247, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarg (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarg: tmp156 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_i2nvarg_var) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp156) ; /* tmp157 = */ atspre_fprint_string (arg0, ATSstrcst(": ")) ; tmp158 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_i2nvarg_typ) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2expopt (arg0, tmp158) ; return /* (tmp154) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 7943(line=250, offs=19) -- 8023(line=251, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst: /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarg) ; return /* (tmp159) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8082(line=255, offs=18) -- 8126(line=255, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvarglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvarglst: tmp161 = atspre_stdout_get () ; tmp162 = ats_selsin_mac(tmp161, atslab_1) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst (tmp162, arg0) ; /* tmp160 = */ atspre_stdout_view_set () ; return /* (tmp160) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvarglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8154(line=257, offs=18) -- 8198(line=257, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvarglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvarglst: tmp165 = atspre_stderr_get () ; tmp166 = ats_selsin_mac(tmp165, atslab_1) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst (tmp166, arg0) ; /* tmp164 = */ atspre_stderr_view_set () ; return /* (tmp164) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvarglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8253(line=263, offs=3) -- 8650(line=273, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate: /* tmp169 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; tmp171 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_i2nvresstate_svs) ; /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp171) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; tmp174 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_i2nvresstate_gua) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp174) ; /* tmp175 = */ atspre_fprint_string (arg0, ATSstrcst("] (")) ; tmp177 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_i2nvresstate_arg) ; /* tmp176 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvarglst (arg0, tmp177) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp168) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8713(line=276, offs=20) -- 8757(line=276, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvresstate (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; // ATSlocal_void (tmp181) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvresstate: tmp179 = atspre_stdout_get () ; tmp180 = ats_selsin_mac(tmp179, atslab_1) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate (tmp180, arg0) ; /* tmp178 = */ atspre_stdout_view_set () ; return /* (tmp178) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_i2nvresstate] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8787(line=278, offs=20) -- 8831(line=278, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvresstate (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; // ATSlocal_void (tmp185) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvresstate: tmp183 = atspre_stderr_get () ; tmp184 = ats_selsin_mac(tmp183, atslab_1) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_i2nvresstate (tmp184, arg0) ; /* tmp182 = */ atspre_stderr_view_set () ; return /* (tmp182) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_i2nvresstate] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 8882(line=284, offs=3) -- 9155(line=292, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp187 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst (arg0, tmp187) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp188 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_2) ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp188) ; break ; } while (0) ; return /* (tmp186) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9210(line=295, offs=16) -- 9250(line=295, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparg (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; // ATSlocal_void (tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparg: tmp190 = atspre_stdout_get () ; tmp191 = ats_selsin_mac(tmp190, atslab_1) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg (tmp191, arg0) ; /* tmp189 = */ atspre_stdout_view_set () ; return /* (tmp189) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9276(line=297, offs=16) -- 9316(line=297, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparg (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; // ATSlocal_void (tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparg: tmp194 = atspre_stderr_get () ; tmp195 = ats_selsin_mac(tmp194, atslab_1) ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg (tmp195, arg0) ; /* tmp193 = */ atspre_stderr_view_set () ; return /* (tmp193) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9368(line=302, offs=20) -- 9450(line=303, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp197) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst: /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparg) ; return /* (tmp197) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9511(line=307, offs=19) -- 9556(line=307, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; // ATSlocal_void (tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparglst: tmp199 = atspre_stdout_get () ; tmp200 = ats_selsin_mac(tmp199, atslab_1) ; /* tmp201 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst (tmp200, arg0) ; /* tmp198 = */ atspre_stdout_view_set () ; return /* (tmp198) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9585(line=309, offs=19) -- 9630(line=309, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; // ATSlocal_void (tmp205) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparglst: tmp203 = atspre_stderr_get () ; tmp204 = ats_selsin_mac(tmp203, atslab_1) ; /* tmp205 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst (tmp204, arg0) ; /* tmp202 = */ atspre_stderr_view_set () ; return /* (tmp202) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 9676(line=314, offs=14) -- 21587(line=682, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; // ATSlocal_void (tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; // ATSlocal_void (tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; // ATSlocal_void (tmp262) ; ATSlocal (ats_bool_type, tmp263) ; // ATSlocal_void (tmp264) ; // ATSlocal_void (tmp265) ; ATSlocal (ats_char_type, tmp266) ; // ATSlocal_void (tmp267) ; // ATSlocal_void (tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; // ATSlocal_void (tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; // ATSlocal_void (tmp288) ; // ATSlocal_void (tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; ATSlocal (ats_int_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; // ATSlocal_void (tmp331) ; // ATSlocal_void (tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; // ATSlocal_void (tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; // ATSlocal_void (tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; // ATSlocal_void (tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; // ATSlocal_void (tmp369) ; // ATSlocal_void (tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; // ATSlocal_void (tmp372) ; // ATSlocal_void (tmp373) ; ATSlocal (ats_int_type, tmp374) ; ATSlocal (ats_int_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_int_type, tmp386) ; ATSlocal (ats_int_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; // ATSlocal_void (tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; ATSlocal (ats_int_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; // ATSlocal_void (tmp430) ; ATSlocal (ats_int_type, tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; ATSlocal (ats_int_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; // ATSlocal_void (tmp442) ; // ATSlocal_void (tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; ATSlocal (ats_int_type, tmp450) ; ATSlocal (ats_int_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; // ATSlocal_void (tmp456) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; // ATSlocal_void (tmp459) ; // ATSlocal_void (tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; // ATSlocal_void (tmp463) ; // ATSlocal_void (tmp464) ; // ATSlocal_void (tmp465) ; // ATSlocal_void (tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; // ATSlocal_void (tmp468) ; // ATSlocal_void (tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; // ATSlocal_void (tmp476) ; // ATSlocal_void (tmp477) ; // ATSlocal_void (tmp478) ; // ATSlocal_void (tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; // ATSlocal_void (tmp482) ; // ATSlocal_void (tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_int_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; // ATSlocal_void (tmp490) ; // ATSlocal_void (tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; // ATSlocal_void (tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; // ATSlocal_void (tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; // ATSlocal_void (tmp499) ; // ATSlocal_void (tmp500) ; // ATSlocal_void (tmp501) ; // ATSlocal_void (tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; // ATSlocal_void (tmp504) ; // ATSlocal_void (tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; // ATSlocal_void (tmp507) ; // ATSlocal_void (tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; // ATSlocal_void (tmp510) ; // ATSlocal_void (tmp511) ; // ATSlocal_void (tmp512) ; // ATSlocal_void (tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp: tmp207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_d2exp_node) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp207)->tag != 1) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp210 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eann_seff(")) ; /* tmp211 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp208) ; /* tmp212 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp213 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (arg0, tmp209) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp207)->tag != 0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp216 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eann_funclo(")) ; /* tmp217 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp214) ; /* tmp218 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp219 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp215) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp207)->tag != 2) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp222 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eann_type(")) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp220) ; /* tmp224 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp221) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp207)->tag != 3) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp227 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp228 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eapps(")) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp226) ; /* tmp230 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exparglst (arg0, tmp227) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp207)->tag != 4) { goto __ats_lab_35_0 ; } __ats_lab_32_1: tmp232 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_0) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_1) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_2) ; /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst("D2Earrinit(")) ; /* tmp236 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp232) ; /* tmp237 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (tmp233 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_15, tmp233, atslab_0) ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp239) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (tmp233 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: break ; } while (0) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp234) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp207)->tag != 5) { goto __ats_lab_38_0 ; } __ats_lab_35_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp243 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp244 = */ atspre_fprint_string (arg0, ATSstrcst("D2Earrpsz(")) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp242 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_15, tmp242, atslab_0) ; /* tmp245 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp246) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp242 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; /* tmp247 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp248 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp243) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp207)->tag != 6) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_0) ; tmp250 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_1) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("D2Earrsub(")) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym (arg0, tmp249) ; /* tmp253 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp254 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp250) ; /* tmp255 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp256 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp207)->tag != 7) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp259 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eassgn(")) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp257) ; /* tmp261 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp262 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp258) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp207)->tag != 8) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp263 = ats_caselptrlab_mac(anairiats_sum_5, tmp207, atslab_0) ; if (tmp263) { /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ebool(true)")) ; } else { /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ebool(false)")) ; } /* end of [if] */ break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp207)->tag != 9) { goto __ats_lab_42_0 ; } __ats_lab_41_1: /* tmp264 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ecaseof(")) ; /* tmp265 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp207)->tag != 10) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_6, tmp207, atslab_0) ; /* tmp267 = */ atspre_fprint_string (arg0, ATSstrcst("D2Echar(")) ; /* tmp268 = */ atspre_fprint_char (arg0, tmp266) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp207)->tag != 11) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_17, tmp207, atslab_0) ; tmp270 = ats_caselptrlab_mac(anairiats_sum_17, tmp207, atslab_3) ; /* tmp271 = */ atspre_fprint_string (arg0, ATSstrcst("D2Econ(")) ; /* tmp272 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp269) ; /* tmp273 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp274 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp270) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp207)->tag != 12) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp276 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ecst(")) ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp275) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp207)->tag != 13) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp279 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ecstsp(")) ; /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (arg0, tmp278) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp207)->tag != 14) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_8, tmp207, atslab_0) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_8, tmp207, atslab_1) ; /* tmp283 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ecrypt(")) ; /* tmp284 = */ atspre_fprint_int (arg0, tmp281) ; /* tmp285 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp282) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp207)->tag != 34) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp287 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp288 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elazy_delay(")) ; /* tmp289 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp287) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp207)->tag != 35) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp292 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elazy_ldelay(")) ; /* tmp293 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp290) ; /* tmp294 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp291) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp207)->tag != 15) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp296 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ederef(")) ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp296) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp207)->tag != 16) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp300 = */ atspre_fprint_string (arg0, ATSstrcst("D2Edynload(")) ; /* tmp301 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp299) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp207)->tag != 17) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp302 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp303 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp304 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eeffmask(")) ; /* tmp305 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst (arg0, tmp302) ; /* tmp306 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp303) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp207)->tag != 18) { goto __ats_lab_53_0 ; } __ats_lab_52_1: /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eempty()")) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp207)->tag != 19) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp309 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eexist(")) ; /* tmp310 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp311 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp312 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp308) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp207)->tag != 20) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp313 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp314 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp315 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eextval(")) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp313) ; /* tmp317 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp318 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp319 = */ atspre_fprint_string (arg0, tmp314) ; /* tmp320 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp207)->tag != 21) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp321 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_0) ; tmp322 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_1) ; tmp323 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_2) ; /* tmp324 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efix(")) ; /* tmp325 = */ atspre_fprint_int (arg0, tmp321) ; /* tmp326 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp322) ; /* tmp328 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp323) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp207)->tag != 22) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp331 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efloat(")) ; /* tmp332 = */ atspre_fprint_string (arg0, tmp330) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp207)->tag != 23) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp333 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp334 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efloatsp(")) ; /* tmp335 = */ atspre_fprint_string (arg0, tmp333) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp207)->tag != 24) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp336 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp337 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efoldat(")) ; /* tmp338 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp336) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp207)->tag != 25) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp339 = ats_caselptrlab_mac(anairiats_sum_18, tmp207, atslab_1) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_18, tmp207, atslab_2) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_18, tmp207, atslab_3) ; tmp342 = ats_caselptrlab_mac(anairiats_sum_18, tmp207, atslab_4) ; /* tmp343 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efor(")) ; /* tmp344 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp345 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp346 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp339) ; /* tmp347 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp348 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp340) ; /* tmp349 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp350 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp341) ; /* tmp351 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp352 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp342) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp207)->tag != 26) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp354 = */ atspre_fprint_string (arg0, ATSstrcst("D2Efreeat(")) ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp353) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp207)->tag != 27) { goto __ats_lab_64_0 ; } __ats_lab_61_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_1) ; tmp357 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_2) ; tmp358 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_3) ; /* tmp359 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eif(")) ; /* tmp360 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp356) ; /* tmp363 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp357) ; do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (tmp358 == (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp366 = ats_caselptrlab_mac(anairiats_sum_15, tmp358, atslab_0) ; /* tmp367 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp365 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp366) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (tmp358 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: break ; } while (0) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp207)->tag != 28) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; /* tmp369 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eint(")) ; /* tmp370 = */ atspre_fprint_string (arg0, tmp368) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp207)->tag != 29) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eintsp(")) ; /* tmp373 = */ atspre_fprint_string (arg0, tmp371) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp207)->tag != 30) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp374 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_0) ; tmp375 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_1) ; tmp376 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_2) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_3) ; /* tmp378 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elam_dyn(")) ; /* tmp379 = */ atspre_fprint_int (arg0, tmp374) ; /* tmp380 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp381 = */ atspre_fprint_int (arg0, tmp375) ; /* tmp382 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp383 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (arg0, tmp376) ; /* tmp384 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp385 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp377) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp207)->tag != 31) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp386 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_0) ; tmp387 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_1) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_2) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_19, tmp207, atslab_3) ; /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elaminit_dyn(")) ; /* tmp391 = */ atspre_fprint_int (arg0, tmp386) ; /* tmp392 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp393 = */ atspre_fprint_int (arg0, tmp387) ; /* tmp394 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp395 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_p2atlst (arg0, tmp388) ; /* tmp396 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp397 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp389) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp207)->tag != 32) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp398 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_1) ; tmp399 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_2) ; /* tmp400 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elam_met(")) ; /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp398) ; /* tmp402 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp403 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp399) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp207)->tag != 33) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp404 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_0) ; tmp405 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_1) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_2) ; /* tmp407 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elam_sta(")) ; /* tmp408 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp404) ; /* tmp409 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp405) ; /* tmp411 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp406) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp207)->tag != 36) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp414 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elet(")) ; /* tmp415 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp416 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp417 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp413) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp207)->tag != 40) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp418 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp419 = */ atspre_fprint_string (arg0, ATSstrcst("D2Emac(")) ; /* tmp420 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac (arg0, tmp418) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp207)->tag != 41) { goto __ats_lab_76_0 ; } __ats_lab_72_1: tmp421 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp422 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp421)->tag != 0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst("%(")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp421)->tag != 1) { goto __ats_lab_75_0 ; } __ats_lab_74_1: /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst(",(")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (((ats_sum_ptr_type)tmp421)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst("`(")) ; break ; } while (0) ; /* tmp424 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp422) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp207)->tag != 37) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_8, tmp207, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_8, tmp207, atslab_1) ; /* tmp427 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elist(")) ; /* tmp428 = */ atspre_fprint_int (arg0, tmp425) ; /* tmp429 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp430 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp426) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp207)->tag != 38) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp431 = ats_caselptrlab_mac(anairiats_sum_20, tmp207, atslab_0) ; /* tmp432 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eloopexn(")) ; /* tmp433 = */ atspre_fprint_int (arg0, tmp431) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp207)->tag != 39) { goto __ats_lab_81_0 ; } __ats_lab_78_1: tmp434 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_0) ; tmp435 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_1) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_4, tmp207, atslab_2) ; /* tmp437 = */ atspre_fprint_string (arg0, ATSstrcst("D2Elst(")) ; /* tmp438 = */ atspre_fprint_int (arg0, tmp434) ; /* tmp439 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp435 == (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp441 = ats_caselptrlab_mac(anairiats_sum_15, tmp435, atslab_0) ; /* tmp442 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp441) ; /* tmp440 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (tmp435 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: break ; } while (0) ; /* tmp443 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp436) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp207)->tag != 42) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp445 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eptrof(")) ; /* tmp446 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp444) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp207)->tag != 43) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp447 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp448 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eraise(")) ; /* tmp449 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp447) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp207)->tag != 44) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_9, tmp207, atslab_0) ; tmp451 = ats_caselptrlab_mac(anairiats_sum_9, tmp207, atslab_1) ; tmp452 = ats_caselptrlab_mac(anairiats_sum_9, tmp207, atslab_2) ; /* tmp453 = */ atspre_fprint_string (arg0, ATSstrcst("D2Erec(")) ; /* tmp454 = */ atspre_fprint_int (arg0, tmp450) ; /* tmp455 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp456 = */ atspre_fprint_int (arg0, tmp451) ; /* tmp457 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp458 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst (arg0, tmp452) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp207)->tag != 45) { goto __ats_lab_85_0 ; } __ats_lab_84_1: /* tmp459 = */ atspre_fprint_string (arg0, ATSstrcst("D2Escaseof(")) ; /* tmp460 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp207)->tag != 46) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp463 = */ atspre_fprint_string (arg0, ATSstrcst("D2Esel(")) ; /* tmp464 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp461) ; /* tmp465 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (arg0, tmp462) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp207)->tag != 47) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp467 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp468 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eseq(")) ; /* tmp469 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (arg0, tmp467) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp207)->tag != 48) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp470 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp471 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eshowtype(")) ; /* tmp472 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp470) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp207)->tag != 49) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp473 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_1) ; tmp474 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_2) ; tmp475 = ats_caselptrlab_mac(anairiats_sum_16, tmp207, atslab_3) ; /* tmp476 = */ atspre_fprint_string (arg0, ATSstrcst("D2Esif(")) ; /* tmp477 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp478 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp473) ; /* tmp480 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp481 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp474) ; /* tmp482 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp483 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp475) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp207)->tag != 51) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_21, tmp207, atslab_0) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_21, tmp207, atslab_1) ; /* tmp206 = */ atspre_fprintf_exn (arg0, ATSstrcst("D2Estring(\"%s\", %i)"), tmp484, tmp485) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp207)->tag != 50) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp486 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp487 = */ atspre_fprint_string (arg0, ATSstrcst("D2Estruct(")) ; /* tmp488 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst (arg0, tmp486) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp207)->tag != 52) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp490 = */ atspre_fprint_string (arg0, ATSstrcst("D2Esym(")) ; /* tmp491 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2sym (arg0, tmp489) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp207)->tag != 53) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp492 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; tmp493 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_1) ; /* tmp494 = */ atspre_fprint_string (arg0, ATSstrcst("D2Etmpid(")) ; /* tmp495 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp492) ; /* tmp496 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp497 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst (arg0, tmp493) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp207)->tag != 54) { goto __ats_lab_94_0 ; } __ats_lab_93_1: /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("D2Etop()")) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp207)->tag != 55) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp498 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_1) ; /* tmp499 = */ atspre_fprint_string (arg0, ATSstrcst("D2Etrywith(")) ; /* tmp500 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp498) ; /* tmp501 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp502 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp207)->tag != 56) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp504 = */ atspre_fprint_string (arg0, ATSstrcst("D2Evar(")) ; /* tmp505 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp503) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp207)->tag != 57) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp506 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; /* tmp507 = */ atspre_fprint_string (arg0, ATSstrcst("D2Eviewat(")) ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp506) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp207)->tag != 58) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp509 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; /* tmp510 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ewhere(")) ; /* tmp511 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp509) ; /* tmp512 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp513 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (((ats_sum_ptr_type)tmp207)->tag != 59) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: tmp514 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_1) ; tmp515 = ats_caselptrlab_mac(anairiats_sum_10, tmp207, atslab_2) ; /* tmp516 = */ atspre_fprint_string (arg0, ATSstrcst("D2Ewhile(")) ; /* tmp517 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp518 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp519 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp514) ; /* tmp520 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp521 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp515) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp206) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 21636(line=684, offs=23) -- 21673(line=684, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; // ATSlocal_void (tmp525) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exp: tmp523 = atspre_stdout_get () ; tmp524 = ats_selsin_mac(tmp523, atslab_1) ; /* tmp525 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (tmp524, arg0) ; /* tmp522 = */ atspre_stdout_view_set () ; return /* (tmp522) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 21696(line=685, offs=23) -- 21733(line=685, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp: tmp527 = atspre_stderr_get () ; tmp528 = ats_selsin_mac(tmp527, atslab_1) ; /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (tmp528, arg0) ; /* tmp526 = */ atspre_stderr_view_set () ; return /* (tmp526) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 21782(line=690, offs=17) -- 21858(line=691, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp530) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst: /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp) ; return /* (tmp530) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 21913(line=694, offs=26) -- 21955(line=694, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; // ATSlocal_void (tmp534) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explst: tmp532 = atspre_stdout_get () ; tmp533 = ats_selsin_mac(tmp532, atslab_1) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (tmp533, arg0) ; /* tmp531 = */ atspre_stdout_view_set () ; return /* (tmp531) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 21981(line=695, offs=26) -- 22023(line=695, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; // ATSlocal_void (tmp538) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explst: tmp536 = atspre_stderr_get () ; tmp537 = ats_selsin_mac(tmp536, atslab_1) ; /* tmp538 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst (tmp537, arg0) ; /* tmp535 = */ atspre_stderr_view_set () ; return /* (tmp535) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22075(line=700, offs=20) -- 22157(line=701, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp539) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst: /* tmp539 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explst) ; return /* (tmp539) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22218(line=704, offs=29) -- 22265(line=704, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; // ATSlocal_void (tmp543) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explstlst: tmp541 = atspre_stdout_get () ; tmp542 = ats_selsin_mac(tmp541, atslab_1) ; /* tmp543 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst (tmp542, arg0) ; /* tmp540 = */ atspre_stdout_view_set () ; return /* (tmp540) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22294(line=705, offs=29) -- 22341(line=705, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; // ATSlocal_void (tmp547) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst: tmp545 = atspre_stderr_get () ; tmp546 = ats_selsin_mac(tmp545, atslab_1) ; /* tmp547 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst (tmp546, arg0) ; /* tmp544 = */ atspre_stderr_view_set () ; return /* (tmp544) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22429(line=712, offs=7) -- 22865(line=724, offs=6) */ ATSstaticdec() ats_void_type aux_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; // ATSlocal_void (tmp553) ; ATSlocal (ats_bool_type, tmp554) ; // ATSlocal_void (tmp555) ; // ATSlocal_void (tmp556) ; // ATSlocal_void (tmp557) ; ATSlocal (ats_int_type, tmp558) ; __ats_lab_aux_40: do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp550 = ats_caselptrlab_mac(anairiats_sum_22, arg2, atslab_0) ; tmp551 = ats_caselptrlab_mac(anairiats_sum_22, arg2, atslab_1) ; tmp552 = ats_caselptrlab_mac(anairiats_sum_22, arg2, atslab_2) ; tmp554 = atspre_gt_int_int (arg1, 0) ; if (tmp554) { /* tmp553 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp555 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp550) ; /* tmp556 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp557 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp551) ; tmp558 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp558 ; arg2 = tmp552 ; goto __ats_lab_aux_40 ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: break ; } while (0) ; return /* (tmp549) */ ; } /* end of [aux_40] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22399(line=711, offs=7) -- 22910(line=727, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp548) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst: /* tmp548 = */ aux_40 (arg0, 0, arg1) ; return /* (tmp548) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 22971(line=730, offs=19) -- 23018(line=730, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_labd2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; // ATSlocal_void (tmp562) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_labd2explst: tmp560 = atspre_stdout_get () ; tmp561 = ats_selsin_mac(tmp560, atslab_1) ; /* tmp562 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst (tmp561, arg0) ; /* tmp559 = */ atspre_stdout_view_set () ; return /* (tmp559) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_labd2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23047(line=732, offs=19) -- 23094(line=732, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_labd2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; // ATSlocal_void (tmp566) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_labd2explst: tmp564 = atspre_stderr_get () ; tmp565 = ats_selsin_mac(tmp564, atslab_1) ; /* tmp566 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_labd2explst (tmp565, arg0) ; /* tmp563 = */ atspre_stderr_view_set () ; return /* (tmp563) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_labd2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23140(line=737, offs=14) -- 23415(line=745, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; // ATSlocal_void (tmp571) ; // ATSlocal_void (tmp572) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab: tmp568 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2lab_node) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp568)->tag != 0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp569 = ats_caselptrlab_mac(anairiats_sum_1, tmp568, atslab_0) ; /* tmp567 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp569) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: // if (((ats_sum_ptr_type)tmp568)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_102_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_1, tmp568, atslab_0) ; /* tmp571 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp572 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst (arg0, tmp570) ; /* tmp567 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; break ; } while (0) ; return /* (tmp567) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23464(line=747, offs=23) -- 23501(line=747, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; // ATSlocal_void (tmp576) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lab: tmp574 = atspre_stdout_get () ; tmp575 = ats_selsin_mac(tmp574, atslab_1) ; /* tmp576 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab (tmp575, arg0) ; /* tmp573 = */ atspre_stdout_view_set () ; return /* (tmp573) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23524(line=748, offs=23) -- 23561(line=748, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; // ATSlocal_void (tmp580) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lab: tmp578 = atspre_stderr_get () ; tmp579 = ats_selsin_mac(tmp578, atslab_1) ; /* tmp580 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab (tmp579, arg0) ; /* tmp577 = */ atspre_stderr_view_set () ; return /* (tmp577) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23610(line=753, offs=17) -- 23686(line=754, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp581) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst: /* tmp581 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lab) ; return /* (tmp581) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23741(line=757, offs=26) -- 23783(line=757, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; // ATSlocal_void (tmp585) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lablst: tmp583 = atspre_stdout_get () ; tmp584 = ats_selsin_mac(tmp583, atslab_1) ; /* tmp585 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (tmp584, arg0) ; /* tmp582 = */ atspre_stdout_view_set () ; return /* (tmp582) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23809(line=758, offs=26) -- 23851(line=758, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; // ATSlocal_void (tmp589) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lablst: tmp587 = atspre_stderr_get () ; tmp588 = ats_selsin_mac(tmp587, atslab_1) ; /* tmp589 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (tmp588, arg0) ; /* tmp586 = */ atspre_stderr_view_set () ; return /* (tmp586) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 23939(line=765, offs=14) -- 25325(line=812, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; // ATSlocal_void (tmp593) ; // ATSlocal_void (tmp594) ; // ATSlocal_void (tmp595) ; // ATSlocal_void (tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; // ATSlocal_void (tmp599) ; // ATSlocal_void (tmp600) ; // ATSlocal_void (tmp601) ; // ATSlocal_void (tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; // ATSlocal_void (tmp605) ; // ATSlocal_void (tmp606) ; // ATSlocal_void (tmp607) ; // ATSlocal_void (tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; // ATSlocal_void (tmp611) ; // ATSlocal_void (tmp612) ; // ATSlocal_void (tmp613) ; // ATSlocal_void (tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; // ATSlocal_void (tmp616) ; // ATSlocal_void (tmp617) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val: do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_1) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_3) ; /* tmp593 = */ atspre_fprint_string (arg0, ATSstrcst("L2VALarrsub(")) ; /* tmp594 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp591) ; /* tmp595 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp596 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2explstlst (arg0, tmp592) ; /* tmp590 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp597 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp598 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp599 = */ atspre_fprint_string (arg0, ATSstrcst("L2VALptr(")) ; /* tmp600 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp597) ; /* tmp601 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp602 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (arg0, tmp598) ; /* tmp590 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp603 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp604 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp605 = */ atspre_fprint_string (arg0, ATSstrcst("L2VALvar_lin(")) ; /* tmp606 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp603) ; /* tmp607 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp608 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (arg0, tmp604) ; /* tmp590 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp609 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp610 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp611 = */ atspre_fprint_string (arg0, ATSstrcst("L2VALvar_mut(")) ; /* tmp612 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp609) ; /* tmp613 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp614 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2lablst (arg0, tmp610) ; /* tmp590 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (((ats_sum_ptr_type)arg1)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: tmp615 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp616 = */ atspre_fprint_string (arg0, ATSstrcst("L2VALnone(")) ; /* tmp617 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp615) ; /* tmp590 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp590) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 25374(line=814, offs=23) -- 25411(line=814, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_l2val (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; // ATSlocal_void (tmp621) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_l2val: tmp619 = atspre_stdout_get () ; tmp620 = ats_selsin_mac(tmp619, atslab_1) ; /* tmp621 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val (tmp620, arg0) ; /* tmp618 = */ atspre_stdout_view_set () ; return /* (tmp618) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_l2val] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_print.dats: 25434(line=815, offs=23) -- 25471(line=815, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_l2val (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; // ATSlocal_void (tmp625) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_l2val: tmp623 = atspre_stderr_get () ; tmp624 = ats_selsin_mac(tmp623, atslab_1) ; /* tmp625 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_l2val (tmp624, arg0) ; /* tmp622 = */ atspre_stderr_view_set () ; return /* (tmp622) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_l2val] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_parser_dats.c0000664000175000017500000004135012223166157021424 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "libc/CATS/stdio.cats" // for [atslib_fopen_exn] /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGi0de_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0rtid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGsi0de_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGdi0de_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0exp_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0exp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_sta_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_dyn_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESi0de_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESs0exp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0exp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0eclst_3) ; /* external dynamic constant declarations */ ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atslib_fopen_exn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_full) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_file) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_stdin) () ; ATSextern_fun(ats_ptr_type, lexbuf_make_infile) (ats_ptr_type) ; ATSextern_fun(ats_void_type, lexing_lexbuf_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, lexing_lexbuf_free) () ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_none) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_i0de) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0rtid) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_si0de) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_di0de) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0exp) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0exp) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_dyn) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_yyres) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_yyres) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, yyparse_main) (ats_int_type) ; ATSextern_fun(ats_ptr_type, atsopt_yyres_i0de) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_yyres_s0exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_yyres_d0exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_yyres_d0eclst) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_bool_type flag_is_sta_0 (ats_int_type arg0) ; static ats_bool_type flag_is_dyn_1 (ats_int_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2174(line=71, offs=4) -- 2216(line=71, offs=46) */ ATSstaticdec() ats_bool_type flag_is_sta_0 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp0) ; __ats_lab_flag_is_sta_0: tmp0 = atspre_eq_int_int (arg0, 0) ; return (tmp0) ; } /* end of [flag_is_sta_0] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2220(line=72, offs=4) -- 2262(line=72, offs=46) */ ATSstaticdec() ats_bool_type flag_is_dyn_1 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp1) ; __ats_lab_flag_is_dyn_1: tmp1 = atspre_gt_int_int (arg0, 0) ; return (tmp1) ; } /* end of [flag_is_dyn_1] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2439(line=83, offs=22) -- 2459(line=83, offs=42) */ ATSglobaldec() ats_ptr_type atsopt_yyres_i0de (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_atsopt_yyres_i0de: tmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp2)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_0, arg0) ; return (tmp2) ; } /* end of [atsopt_yyres_i0de] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2552(line=88, offs=23) -- 2575(line=88, offs=46) */ ATSglobaldec() ats_ptr_type atsopt_yyres_s0exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_atsopt_yyres_s0exp: tmp3 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp3)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp3, atslab_0, arg0) ; return (tmp3) ; } /* end of [atsopt_yyres_s0exp] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2668(line=93, offs=23) -- 2691(line=93, offs=46) */ ATSglobaldec() ats_ptr_type atsopt_yyres_d0exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_atsopt_yyres_d0exp: tmp4 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp4)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp4, atslab_0, arg0) ; return (tmp4) ; } /* end of [atsopt_yyres_d0exp] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2793(line=98, offs=25) -- 2820(line=98, offs=52) */ ATSglobaldec() ats_ptr_type atsopt_yyres_d0eclst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_atsopt_yyres_d0eclst: tmp5 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp5)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp5, atslab_0, arg0) ; return (tmp5) ; } /* end of [atsopt_yyres_d0eclst] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 2933(line=109, offs=16) -- 3325(line=121, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp6) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_none ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_i0de ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0rtid ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_si0de ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_di0de ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0exp ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0exp ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_sta ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (((ats_sum_ptr_type)arg0)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_dyn ; break ; } while (0) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 3410(line=128, offs=3) -- 3765(line=141, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_yyres (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_int_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_yyres: tmp8 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg (arg0) ; tmp9 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_stdin () ; tmp10 = ats_selsin_mac(tmp9, atslab_1) ; tmp11 = lexbuf_make_infile (tmp10) ; tmp12 = ats_selsin_mac(tmp11, atslab_1) ; /* tmp13 = */ lexing_lexbuf_set (tmp12) ; tmp14 = yyparse_main (tmp8) ; /* tmp15 = */ lexing_lexbuf_free () ; tmp7 = tmp14 ; return (tmp7) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_yyres] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 3839(line=145, offs=3) -- 4114(line=155, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_d0eclst (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_bool_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_d0eclst: /* ats_ptr_type tmp17 ; */ tmp17 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGnone_0) ; tmp19 = flag_is_sta_0 (arg0) ; if (tmp19) { tmp20 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_sta_7) ; tmp17 = tmp20 ; } else { /* empty */ } /* end of [if] */ tmp22 = flag_is_dyn_1 (arg0) ; if (tmp22) { tmp23 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_dyn_8) ; tmp17 = tmp23 ; } else { /* empty */ } /* end of [if] */ tmp24 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_yyres (tmp17) ; if (((ats_sum_ptr_type)tmp24)->tag != 3) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_parser.dats: 4082(line=153, offs=8) -- 4109(line=153, offs=35)") ; } tmp25 = ats_caselptrlab_mac(anairiats_sum_0, tmp24, atslab_0) ; tmp16 = tmp25 ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_d0eclst] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 4212(line=161, offs=3) -- 4906(line=183, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_yyres (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_int_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_yyres: tmp27 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__token_of_yybeg (arg0) ; tmp28 = atsopt_filename_full (arg1) ; tmp29 = atslib_fopen_exn (tmp28, "r") ; tmp30 = ats_selsin_mac(tmp29, atslab_1) ; tmp31 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_file (tmp30) ; tmp32 = ats_selsin_mac(tmp31, atslab_1) ; tmp33 = lexbuf_make_infile (tmp32) ; tmp34 = ats_selsin_mac(tmp33, atslab_1) ; /* tmp35 = */ lexing_lexbuf_set (tmp34) ; tmp36 = yyparse_main (tmp27) ; /* tmp37 = */ lexing_lexbuf_free () ; tmp26 = tmp36 ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_yyres] */ /* // /home/hwxi/research/Anairiats/src/ats_parser.dats: 4986(line=187, offs=3) -- 5287(line=198, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_bool_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_bool_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst: /* ats_ptr_type tmp39 ; */ tmp39 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGnone_0) ; tmp41 = flag_is_sta_0 (arg0) ; if (tmp41) { tmp42 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_sta_7) ; tmp39 = tmp42 ; } else { /* empty */ } /* end of [if] */ tmp44 = flag_is_dyn_1 (arg0) ; if (tmp44) { tmp45 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_dyn_8) ; tmp39 = tmp45 ; } else { /* empty */ } /* end of [if] */ tmp46 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_yyres (tmp39, arg1) ; if (((ats_sum_ptr_type)tmp46)->tag != 3) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_parser.dats: 5255(line=196, offs=8) -- 5282(line=196, offs=35)") ; } tmp47 = ats_caselptrlab_mac(anairiats_sum_0, tmp46, atslab_0) ; tmp38 = tmp47 ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_parser_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_dyn1_dats.c0000664000175000017500000075060012223166157022301 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_d1cstdec_fil ; ats_ptr_type atslab_d1cstdec_loc ; ats_ptr_type atslab_d1cstdec_sym ; ats_ptr_type atslab_d1cstdec_typ ; ats_ptr_type atslab_d1cstdec_extdef ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_s1arg_loc ; ats_ptr_type atslab_s1arg_sym ; ats_ptr_type atslab_s1arg_srt ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_p1at_loc ; ats_ptr_type atslab_p1at_node ; } anairiats_rec_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_12 ; typedef struct { anairiats_rec_0 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_d0ynq_loc ; ats_ptr_type atslab_d0ynq_node ; } anairiats_rec_16 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_19 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_l0ab_loc ; ats_ptr_type atslab_l0ab_lab ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_i1nvarg_loc ; ats_ptr_type atslab_i1nvarg_sym ; ats_ptr_type atslab_i1nvarg_typ ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_i1nvresstate_qua ; ats_ptr_type atslab_i1nvresstate_arg ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_loopi1nv_loc ; ats_ptr_type atslab_loopi1nv_qua ; ats_ptr_type atslab_loopi1nv_met ; ats_ptr_type atslab_loopi1nv_arg ; ats_ptr_type atslab_loopi1nv_res ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_m1atch_loc ; ats_ptr_type atslab_m1atch_exp ; ats_ptr_type atslab_m1atch_pat ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_c1lau_loc ; ats_ptr_type atslab_c1lau_pat ; ats_ptr_type atslab_c1lau_gua ; ats_int_type atslab_c1lau_seq ; ats_int_type atslab_c1lau_neg ; ats_ptr_type atslab_c1lau_exp ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_sc1lau_loc ; ats_ptr_type atslab_sc1lau_pat ; ats_ptr_type atslab_sc1lau_exp ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_sc2lau_loc ; ats_ptr_type atslab_sc2lau_pat ; ats_ptr_type atslab_sc2lau_exp ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_sp2at_loc ; ats_ptr_type atslab_sp2at_exp ; ats_ptr_type atslab_sp2at_node ; } anairiats_rec_30 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_31 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_32 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_33 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_34 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_35 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_36 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_37 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_38 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_39 ; typedef struct { ats_ptr_type atslab_tmpqi0de_loc ; ats_ptr_type atslab_tmpqi0de_qua ; ats_ptr_type atslab_tmpqi0de_sym ; } anairiats_rec_40 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_41 ; typedef struct { ats_ptr_type atslab_d1lab_loc ; ats_ptr_type atslab_d1lab_node ; } anairiats_rec_42 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tas_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tchar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Texist_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfloat_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfree_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tint_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlst_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tqid_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trec_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tref_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trefas_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tstring_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Ttup_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrinit_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrpsz_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrsub_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecrypt_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eexist_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eextval_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efix_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloat_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloatsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efoldat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efor_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efreeat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eif_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eint_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eintsp_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elet_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eloopexn_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elst_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Emacsyn_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eptrof_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eraise_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Erec_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Escaseof_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esel_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estruct_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etmpid_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etrywith_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etup_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eviewat_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhere_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhile_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__SP2Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMe1xp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacdef_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDassgn_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDderef_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDnone_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_neg_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerrf_exn) (ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, ats_array_ptr_alloc_tsz) (ats_int_type, ats_size_type) ; ATSextern_fun(ats_void_type, ats_array_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_COLONEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VBOX) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_stringsp) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_beg) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_end) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0ynq_none) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_d1exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_length) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_conlst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_tag) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_ind) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2arg_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_types) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_sarglst_svarlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlstord_linearity_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlstord_linearity_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_vbox) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_floatsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_for) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_intsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met_new) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_loopexn) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_scaseof) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_showtype) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_top) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_trywith) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_while) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_lab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sc2lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__sp1at_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_prop) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_dn_impredicative) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1lab_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDassgn_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDderef_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDnone_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_void_type dyncstuseloc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2exp_arity_list_4 (ats_ptr_type arg0) ; static ats_ptr_type d1cstdec_tr_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1arg_arg_tr_7 (ats_ptr_type arg0) ; static ats_ptr_type s1arglst_arg_tr_8 (ats_ptr_type arg0) ; static ats_ptr_type d2con_select_arity_9 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type d2con_select_arity_err_none_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_ptr_type p1at_make_p1at_11 (ats_ptr_type arg0) ; static ats_ptr_type d1exp_make_d1exp_12 (ats_ptr_type arg0) ; static ats_ptr_type aux1_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type err_15 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ref_type arg5) ; static ats_ptr_type p1at_con_tr_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) ; static ats_ptr_type err1_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err2_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p1at_qid_app_dyn_tr_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7) ; static ats_ptr_type p1at_app_tr_22 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) ; static ats_ptr_type p1at_free_tr_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type qid_is_vbox_24 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_varet_type err_26 (ats_ptr_type arg0) ; static ats_ptr_type p1at_vbox_tr_25 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2sym_lrbrackets_32 (ats_ptr_type arg0) ; static ats_ptr_type d1exp_arrsub_tr_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d1exp_assgn_tr_34 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d1exp_deref_tr_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type macro_def_check_36 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type macro_var_check_37 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type specdynid_of_qid_38 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d1exp_qid_tr_39 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d1exp_qid_app_sta_tr_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type d1exp_qid_app_dyn_tr_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8) ; static ats_ptr_type d1exp_idextapp_tr_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d1exp_wths1explst_tr_43 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type i1nvarglst_tr_44 (ats_ptr_type arg0) ; static ats_ptr_type i1nvresstate_tr_45 (ats_ptr_type arg0) ; static ats_ptr_type loopi1nv_tr_46 (ats_ptr_type arg0) ; static ats_ptr_type m1atch_tr_47 (ats_ptr_type arg0) ; static ats_ptr_type m1atchlst_tr_48 (ats_ptr_type arg0) ; static ats_ptr_type c1lau_tr_49 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type c1laulst_tr_50 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type sc1lau_tr_dn_51 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type sc1laulst_tr_dn_52 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_56 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type array_ptr_initialize_elt_01688_ats_int_type (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_ptr_type array_ptr_make_elt_01689_ats_int_type (ats_int_type arg0, ats_int_type arg1) ; static ats_void_type check_57 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type loop_errmsg_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_int_type arg5) ; static ats_void_type sc2laulst_covercheck_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type proc_60 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type lamvararg_proc_59 (ats_ptr_type arg0) ; static anairiats_rec_31 d1exp_arg_body_tr_61 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 3098(line=111, offs=4) -- 3185(line=113, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 3219(line=116, offs=4) -- 3279(line=116, offs=64) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans2_dyn1)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 3284(line=118, offs=4) -- 3397(line=120, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans2_dyn1)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 3454(line=124, offs=4) -- 3799(line=133, offs=4) */ ATSstaticdec() ats_void_type dyncstuseloc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_lint_type, tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_lint_type, tmp9) ; __ats_lab_dyncstuseloc_posmark_3: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc (arg1) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_beg (tmp7, tmp6) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_end (tmp9, tmp6) ; return /* (tmp5) */ ; } /* end of [dyncstuseloc_posmark_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 3859(line=137, offs=5) -- 4224(line=147, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_arity_list_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_int_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_s2exp_arity_list_4: tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp11)->tag != 11) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_2, tmp11, atslab_4) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_2, tmp11, atslab_5) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp12) ; tmp15 = s2exp_arity_list_4 (tmp13) ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp10, atslab_0, tmp14) ; ats_selptrset_mac(anairiats_sum_3, tmp10, atslab_1, tmp15) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp11)->tag != 9) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_4, tmp11, atslab_2) ; arg0 = tmp16 ; goto __ats_lab_s2exp_arity_list_4 ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp11)->tag != 30) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_4, tmp11, atslab_2) ; arg0 = tmp17 ; goto __ats_lab_s2exp_arity_list_4 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp11)->tag != 15) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_4, tmp11, atslab_2) ; arg0 = tmp18 ; goto __ats_lab_s2exp_arity_list_4 ; // tail call break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: tmp10 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp10) ; } /* end of [s2exp_arity_list_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 4279(line=151, offs=4) -- 4905(line=171, offs=4) */ ATSstaticdec() ats_ptr_type d1cstdec_tr_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_bool_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; __ats_lab_d1cstdec_tr_5: tmp20 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg2), atslab_d1cstdec_sym) ; tmp21 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg2), atslab_d1cstdec_loc) ; tmp22 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg2), atslab_d1cstdec_fil) ; tmp23 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg2), atslab_d1cstdec_typ) ; /* ats_ptr_type tmp24 ; */ tmp25 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (arg0) ; if (tmp25) { tmp24 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_prop (tmp23) ; } else { tmp24 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype (tmp23) ; } /* end of [if] */ tmp26 = s2exp_arity_list_4 (tmp24) ; tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg2), atslab_d1cstdec_extdef) ; tmp28 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_make (tmp20, tmp22, tmp21, arg0, arg1, tmp26, tmp24, tmp27) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcst (tmp28) ; tmp19 = tmp28 ; return (tmp19) ; } /* end of [d1cstdec_tr_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 4958(line=175, offs=3) -- 5192(line=183, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp33 = d1cstdec_tr_5 (arg0, arg1, tmp31) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr (arg0, arg1, tmp32) ; tmp30 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp30, atslab_0, tmp33) ; ats_selptrset_mac(anairiats_sum_6, tmp30, atslab_1, tmp34) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp30 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 5245(line=187, offs=4) -- 5361(line=190, offs=4) */ ATSstaticdec() ats_ptr_type s1arg_arg_tr_7 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_s1arg_arg_tr_7: tmp36 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s1arg_loc) ; tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s1arg_sym) ; tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s1arg_srt) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr (tmp39) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2arg_make (tmp36, tmp37, tmp38) ; return (tmp35) ; } /* end of [s1arg_arg_tr_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 5392(line=192, offs=5) -- 5553(line=196, offs=4) */ ATSstaticdec() ats_ptr_type s1arglst_arg_tr_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_s1arglst_arg_tr_8: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp42 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp43 = s1arg_arg_tr_7 (tmp41) ; tmp44 = s1arglst_arg_tr_8 (tmp42) ; tmp40 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp40, atslab_0, tmp43) ; ats_selptrset_mac(anairiats_sum_6, tmp40, atslab_1, tmp44) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp40 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp40) ; } /* end of [s1arglst_arg_tr_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 5608(line=200, offs=5) -- 5945(line=210, offs=2) */ ATSstaticdec() ats_ptr_type d2con_select_arity_9 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_bool_type, tmp48) ; ATSlocal (ats_int_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_d2con_select_arity_9: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp49 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full (tmp46) ; tmp48 = atspre_eq_int_int (tmp49, arg1) ; if (tmp48) { tmp50 = d2con_select_arity_9 (tmp47, arg1) ; tmp45 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp45, atslab_0, tmp46) ; ats_selptrset_mac(anairiats_sum_6, tmp45, atslab_1, tmp50) ; } else { arg0 = tmp47 ; arg1 = arg1 ; goto __ats_lab_d2con_select_arity_9 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp45 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp45) ; } /* end of [d2con_select_arity_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 6369(line=227, offs=5) -- 6665(line=235, offs=4) */ ATSstaticdec() ats_ptr_type d2con_select_arity_err_none_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; __ats_lab_d2con_select_arity_err_none_10: /* tmp52 = */ prerr_loc_error2_0 (arg0) ; /* tmp53 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg1) ; /* tmp55 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp56 = */ atspre_prerrf_exn (ATSstrcst("] does not refer to any constructor of arity %i."), arg3) ; /* tmp57 = */ atspre_prerr_newline () ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp51) ; } /* end of [d2con_select_arity_err_none_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 6732(line=239, offs=5) -- 7250(line=257, offs=4) */ ATSstaticdec() ats_ptr_type p1at_make_p1at_11 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_p1at_make_p1at_11: tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_node) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp59)->tag != 14) { goto __ats_lab_16_0 ; } __ats_lab_11_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_9, tmp59, atslab_0) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_9, tmp59, atslab_1) ; tmp62 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (tmp60, tmp61) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp62 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_12_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_0) ; ATS_FREE(tmp62) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp63)->tag != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_11, tmp63, atslab_0) ; tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_loc) ; tmp65 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp (tmp66, tmp64) ; arg0 = tmp65 ; goto __ats_lab_p1at_make_p1at_11 ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp58 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp62 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp58 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp58 = arg0 ; break ; } while (0) ; return (tmp58) ; } /* end of [p1at_make_p1at_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 7283(line=259, offs=5) -- 7824(line=277, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_make_d1exp_12 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_d1exp_make_d1exp_12: tmp68 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp68)->tag != 41) { goto __ats_lab_22_0 ; } __ats_lab_17_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_9, tmp68, atslab_0) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_9, tmp68, atslab_1) ; tmp71 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (tmp69, tmp70) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp71 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_10, tmp71, atslab_0) ; ATS_FREE(tmp71) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp72)->tag != 2) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp75 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp74 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp (tmp75, tmp73) ; arg0 = tmp74 ; goto __ats_lab_d1exp_make_d1exp_12 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp67 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (tmp71 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp67 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp67 = arg0 ; break ; } while (0) ; return (tmp67) ; } /* end of [d1exp_make_d1exp_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 7917(line=283, offs=5) -- 8855(line=311, offs=4) */ ATSstaticdec() ats_ptr_type aux1_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (anairiats_rec_0, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (anairiats_rec_0, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (anairiats_rec_0, tmp86) ; ATSlocal (ats_int_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_aux1_13: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_13, arg2, atslab_0) ; tmp78 = ats_caselptrlab_mac(anairiats_sum_13, arg2, atslab_1) ; tmp80 = ats_select_mac(tmp77, atslab_0) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (arg1, tmp80) ; tmp81 = ats_select_mac(tmp79, atslab_0) ; tmp82 = ats_select_mac(tmp79, atslab_1) ; tmp84 = ats_select_mac(tmp77, atslab_1) ; tmp83 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp81, tmp84) ; tmp86.atslab_0 = tmp82 ; tmp86.atslab_1 = tmp83 ; tmp85 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp85, atslab_0, tmp86) ; ats_selptrset_mac(anairiats_sum_13, tmp85, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp85 ; arg0 = arg0 ; arg1 = tmp81 ; arg2 = tmp78 ; arg3 = arg3 ; goto __ats_lab_aux1_13 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp87 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf (arg0) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg (arg0) ; tmp88 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (arg1, tmp89) ; tmp90 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (arg0) ; tmp92 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_ind (arg0) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp92 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_10, tmp92, atslab_0) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (arg1, tmp93) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp90, tmp94) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp92 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp91 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp90) ; break ; } while (0) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse (ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp95 ; tmp76 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun (tmp87, tmp88, tmp91) ; break ; } while (0) ; return (tmp76) ; } /* end of [aux1_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 9021(line=321, offs=6) -- 9326(line=329, offs=6) */ ATSstaticdec() ats_ptr_type err_15 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; __ats_lab_err_15: /* tmp98 = */ prerr_loc_error2_0 (arg0) ; /* tmp99 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_con_tr: aux2"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp100 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp102 = */ atspre_prerr_string (ATSstrcst("] is applied to too many static arguments.")) ; /* tmp103 = */ atspre_prerr_newline () ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp97) ; } /* end of [err_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 8875(line=313, offs=5) -- 10425(line=358, offs=4) */ ATSstaticdec() ats_ptr_type aux2_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ref_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (anairiats_rec_0, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (anairiats_rec_0, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (anairiats_rec_0, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (anairiats_rec_0, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (anairiats_rec_0, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (anairiats_rec_0, tmp127) ; __ats_lab_aux2_14: do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_27_1: tmp104 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_0) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_1) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp104)->tag != 0) { goto __ats_lab_31_0 ; } __ats_lab_28_1: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_13, arg3, atslab_0) ; tmp107 = ats_caselptrlab_mac(anairiats_sum_13, arg3, atslab_1) ; tmp109 = ats_select_mac(tmp106, atslab_0) ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (arg2, tmp109) ; tmp110 = ats_select_mac(tmp108, atslab_0) ; tmp111 = ats_select_mac(tmp108, atslab_1) ; tmp113 = ats_select_mac(tmp106, atslab_1) ; tmp112 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp110, tmp113) ; tmp115.atslab_0 = tmp111 ; tmp115.atslab_1 = tmp112 ; tmp114 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp114, atslab_0, tmp115) ; ats_selptrset_mac(anairiats_sum_13, tmp114, atslab_1, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp114 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp110 ; arg3 = tmp107 ; arg4 = tmp105 ; arg5 = arg5 ; goto __ats_lab_aux2_14 ; // tail call break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp96 = err_15 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp104)->tag != 1) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp96 = aux1_13 (arg1, arg2, arg3, arg5) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (((ats_sum_ptr_type)tmp104)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_11, tmp104, atslab_0) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_13, arg3, atslab_0) ; tmp118 = ats_caselptrlab_mac(anairiats_sum_13, arg3, atslab_1) ; tmp119 = s1arglst_arg_tr_8 (tmp116) ; tmp121 = ats_select_mac(tmp117, atslab_0) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_sarglst_svarlst (arg0, arg2, tmp119, tmp121) ; tmp122 = ats_select_mac(tmp120, atslab_0) ; tmp123 = ats_select_mac(tmp120, atslab_1) ; tmp125 = ats_select_mac(tmp117, atslab_1) ; tmp124 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp122, tmp125) ; tmp127.atslab_0 = tmp123 ; tmp127.atslab_1 = tmp124 ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp126, atslab_0, tmp127) ; ats_selptrset_mac(anairiats_sum_13, tmp126, atslab_1, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp126 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp122 ; arg3 = tmp118 ; arg4 = tmp105 ; arg5 = arg5 ; goto __ats_lab_aux2_14 ; // tail call break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp96 = err_15 (arg0, arg1) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp96 = aux1_13 (arg1, arg2, arg3, arg5) ; break ; } while (0) ; return (tmp96) ; } /* end of [aux2_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 10468(line=362, offs=4) -- 10818(line=372, offs=4) */ ATSstaticdec() ats_ptr_type p1at_con_tr_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_p1at_con_tr_16: tmp129 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua (arg2) ; /* ats_ptr_type tmp130 ; */ tmp130 = (ats_sum_ptr_type)0 ; tmp131 = aux2_14 (arg1, arg2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil, tmp129, arg3, (&tmp130)) ; tmp132 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (arg5) ; tmp128 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con (arg0, 1, arg2, tmp130, tmp131, arg4, tmp132) ; return (tmp128) ; } /* end of [p1at_con_tr_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 10875(line=375, offs=22) -- 11052(line=381, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_con_instantiate (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_con_instantiate: /* ats_ptr_type tmp134 ; */ tmp134 = (ats_sum_ptr_type)0 ; tmp136 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua (arg1) ; tmp137 = (ats_sum_ptr_type)0 ; tmp135 = aux2_14 (arg0, arg1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil, tmp136, tmp137, (&tmp134)) ; tmp133.atslab_0 = tmp134 ; tmp133.atslab_1 = tmp135 ; return (tmp133) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_con_instantiate] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 11322(line=398, offs=6) -- 11671(line=408, offs=6) */ ATSstaticdec() ats_ptr_type err1_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; // ATSlocal_void (tmp141) ; // ATSlocal_void (tmp142) ; // ATSlocal_void (tmp143) ; // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; __ats_lab_err1_19: /* tmp140 = */ prerr_loc_error2_0 (arg0) ; /* tmp141 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_qid_app_dyn_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp142 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg1) ; /* tmp144 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp145 = */ atspre_prerr_string (ATSstrcst("] does not refer to a constructor.")) ; /* tmp146 = */ atspre_prerr_newline () ; /* tmp139 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp139) ; } /* end of [err1_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 11697(line=410, offs=6) -- 12019(line=420, offs=6) */ ATSstaticdec() ats_ptr_type err2_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; __ats_lab_err2_20: /* tmp148 = */ prerr_loc_error2_0 (arg0) ; /* tmp149 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_qid_app_dyn_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp150 = */ atspre_prerr_string (ATSstrcst(": unrecognized dynamic constructor [")) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg1) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp153 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp154 = */ atspre_prerr_newline () ; /* tmp147 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp147) ; } /* end of [err2_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 13314(line=460, offs=13) -- 13488(line=464, offs=29) */ ATSstaticdec() ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; __ats_lab_aux_21: do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp174 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any (arg0) ; tmp175 = aux_21 (arg0, tmp173) ; tmp172 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp172, atslab_0, tmp174) ; ats_selptrset_mac(anairiats_sum_6, tmp172, atslab_1, tmp175) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp172 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp172) ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 11134(line=387, offs=4) -- 13762(line=475, offs=4) */ ATSstaticdec() ats_ptr_type p1at_qid_app_dyn_tr_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_int_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_p1at_qid_app_dyn_tr_18: tmp155 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (arg3, arg4) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp155 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_36_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_10, tmp155, atslab_0) ; ATS_FREE(tmp155) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp157)->tag != 0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_11, tmp157, atslab_0) ; tmp156 = tmp158 ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp156 = err1_19 (arg2, arg3, arg4) ; break ; } while (0) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (tmp155 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: tmp156 = err2_20 (arg2, arg3, arg4) ; break ; } while (0) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg7 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } tmp160 = ats_caselptrlab_mac(anairiats_sum_6, arg7, atslab_1) ; if (tmp160 != (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_40_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_6, arg7, atslab_0) ; tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp161), atslab_p1at_node) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp162)->tag != 1) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp159 = ats_true_bool ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp159 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp159 = ats_false_bool ; break ; } while (0) ; tmp163 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg7) ; if (tmp159) { tmp164 = tmp156 ; } else { tmp164 = d2con_select_arity_9 (tmp156, tmp163) ; } /* end of [if] */ do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp164 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_6, tmp164, atslab_0) ; tmp165 = tmp166 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp165 = d2con_select_arity_err_none_10 (arg2, arg3, arg4, tmp163) ; break ; } while (0) ; if (tmp159) { do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (arg7 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } tmp168 = ats_caselptrlab_mac(anairiats_sum_6, arg7, atslab_1) ; if (tmp168 != (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_46_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_6, arg7, atslab_0) ; tmp170 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf (tmp165) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg (tmp165) ; tmp176 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp169), atslab_p1at_loc) ; tmp167 = aux_21 (tmp176, tmp171) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: tmp167 = arg7 ; break ; } while (0) ; } else { tmp167 = arg7 ; } /* end of [if] */ tmp138 = p1at_con_tr_16 (arg0, arg1, tmp165, arg5, arg6, tmp167) ; return (tmp138) ; } /* end of [p1at_qid_app_dyn_tr_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 13820(line=479, offs=4) -- 14435(line=498, offs=4) */ ATSstaticdec() ats_ptr_type p1at_app_tr_22 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; __ats_lab_p1at_app_tr_22: tmp178 = p1at_make_p1at_11 (arg2) ; tmp179 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp178), atslab_p1at_node) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp179)->tag != 14) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_9, tmp179, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_9, tmp179, atslab_1) ; tmp182 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp178), atslab_p1at_loc) ; tmp177 = p1at_qid_app_dyn_tr_18 (arg0, arg1, tmp182, tmp180, tmp181, arg3, arg4, arg5) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: /* tmp183 = */ prerr_loc_error2_0 (arg0) ; /* tmp184 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_app_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp185 = */ atspre_prerr_string (ATSstrcst(": the application in the pattern is not allowed.")) ; /* tmp186 = */ atspre_prerr_newline () ; /* tmp177 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp177) ; } /* end of [p1at_app_tr_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 14540(line=504, offs=4) -- 15051(line=518, offs=4) */ ATSstaticdec() ats_ptr_type p1at_free_tr_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_int_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_int_type, tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; __ats_lab_p1at_free_tr_23: tmp188 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (arg1) ; tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp188), atslab_p2at_node) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp189)->tag != 5) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_0) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_1) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_2) ; tmp193 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_3) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_4) ; tmp195 = ats_caselptrlab_mac(anairiats_sum_15, tmp189, atslab_5) ; tmp196 = atspre_neg_int (tmp190) ; tmp187 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con (arg0, tmp196, tmp191, tmp192, tmp193, tmp194, tmp195) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: /* tmp197 = */ prerr_loc_error2_0 (arg0) ; /* tmp198 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_free_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp199 = */ atspre_prerr_string (ATSstrcst(": values that match this pattern are not allowed to be freed.")) ; /* tmp200 = */ atspre_prerr_newline () ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp187) ; } /* end of [p1at_free_tr_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 15102(line=522, offs=4) -- 15244(line=526, offs=4) */ ATSstaticdec() ats_bool_type qid_is_vbox_24 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_qid_is_vbox_24: tmp202 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d0ynq_node) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp202)->tag != 0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp201 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VBOX) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp201 = ats_false_bool ; break ; } while (0) ; return (tmp201) ; } /* end of [qid_is_vbox_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 15344(line=530, offs=6) -- 15523(line=535, offs=6) */ ATSstaticdec() ats_varet_type err_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; __ats_lab_err_26: /* tmp205 = */ prerr_loc_error2_0 (arg0) ; /* tmp206 = */ atspre_prerr_string (ATSstrcst(": the [vbox] pattern is syntactically incorrect.")) ; /* tmp207 = */ atspre_prerr_newline () ; /* tmp204 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp204) */ ; } /* end of [err_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 15273(line=528, offs=4) -- 15835(line=546, offs=4) */ ATSstaticdec() ats_ptr_type p1at_vbox_tr_25 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp208) ; ATSlocal (ats_bool_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_bool_type, tmp217) ; __ats_lab_p1at_vbox_tr_25: tmp209 = atspre_neq_int_int (arg1, 0) ; if (tmp209) { /* tmp208 = */ err_26 (arg0) ; } else { /* empty */ } /* end of [if] */ do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } tmp211 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp211 != (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp210 = tmp212 ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: /* tmp210 = */ err_26 (arg0) ; break ; } while (0) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp210) ; tmp214 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp213), atslab_p2at_node) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp214)->tag != 14) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_17, tmp214, atslab_0) ; tmp216 = ats_caselptrlab_mac(anairiats_sum_17, tmp214, atslab_1) ; tmp217 = atspre_eq_int_int (tmp215, 0) ; if (!tmp217) { goto __ats_lab_59_1 ; } tmp203 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_vbox (arg0, tmp216) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: /* tmp203 = */ err_26 (arg0) ; break ; } while (0) ; return (tmp203) ; } /* end of [p1at_vbox_tr_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 15901(line=551, offs=9) -- 20872(line=697, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_int_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_int_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_bool_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_char_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_bool_type, tmp274) ; ATSlocal (ats_bool_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; // ATSlocal_void (tmp302) ; ATSlocal (ats_int_type, tmp303) ; ATSlocal (ats_int_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; // ATSlocal_void (tmp307) ; ATSlocal (ats_bool_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; ATSlocal (ats_bool_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr: tmp219 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_loc) ; /* ats_int_type tmp220 ; */ tmp220 = 0 ; tmp222 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_node) ; do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp222)->tag != 0) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp223) ; tmp226 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp224) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (tmp219, tmp225, tmp226) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp222)->tag != 1) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any (tmp219) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp222)->tag != 2) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any (tmp219) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp222)->tag != 3) { goto __ats_lab_69_0 ; } __ats_lab_63_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_18, tmp222, atslab_0) ; tmp228 = ats_caselptrlab_mac(anairiats_sum_18, tmp222, atslab_2) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_18, tmp222, atslab_3) ; tmp230 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp227), atslab_p1at_loc) ; tmp231 = p1at_make_p1at_11 (tmp227) ; tmp232 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp231), atslab_p1at_node) ; do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp232)->tag != 14) { goto __ats_lab_67_0 ; } __ats_lab_64_1: tmp233 = ats_caselptrlab_mac(anairiats_sum_9, tmp232, atslab_0) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_9, tmp232, atslab_1) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: __ats_lab_65_1: tmp235 = qid_is_vbox_24 (tmp233, tmp234) ; if (!tmp235) { goto __ats_lab_66_1 ; } tmp221 = p1at_vbox_tr_25 (tmp219, tmp228, tmp229) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp220 = 2 ; tmp236 = (ats_sum_ptr_type)0 ; tmp221 = p1at_qid_app_dyn_tr_18 (tmp219, tmp230, tmp230, tmp233, tmp234, tmp236, tmp228, tmp229) ; break ; } while (0) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp232)->tag != 4) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp237 = ats_caselptrlab_mac(anairiats_sum_9, tmp232, atslab_0) ; tmp238 = ats_caselptrlab_mac(anairiats_sum_9, tmp232, atslab_1) ; tmp220 = 2 ; tmp221 = p1at_app_tr_22 (tmp219, tmp230, tmp237, tmp238, tmp228, tmp229) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: __ats_lab_68_1: /* tmp239 = */ prerr_loc_error2_0 (tmp219) ; /* tmp240 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p1at_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp241 = */ atspre_prerr_string (ATSstrcst(": the application in the pattern is not allowed.")) ; /* tmp242 = */ atspre_prerr_newline () ; /* tmp221 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp222)->tag != 4) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp243 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp244 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; tmp245 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp243), atslab_p1at_loc) ; tmp220 = 1 ; tmp246 = (ats_sum_ptr_type)0 ; tmp221 = p1at_app_tr_22 (tmp219, tmp245, tmp243, tmp244, 0, tmp246) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp222)->tag != 5) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; tmp250 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp247), atslab_i0de_loc) ; tmp251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp247), atslab_i0de_sym) ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp250, tmp251) ; tmp220 = 2 ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp248) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as (tmp219, 0, tmp249, tmp252) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp222)->tag != 6) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_20, tmp222, atslab_0) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_char (tmp219, tmp253) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp222)->tag != 8) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp254 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp255 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; /* tmp256 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp257 = ats_selsin_mac(tmp256, atslab_1) */ ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr (tmp254) ; tmp259 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp255) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp220 = 1 ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist (tmp219, tmp258, tmp259) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp222)->tag != 7) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty (tmp219) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp222)->tag != 9) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp261 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_float (tmp219, tmp261) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp222)->tag != 10) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp221 = p1at_free_tr_23 (tmp219, tmp262) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp222)->tag != 11) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp263 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp264 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string (tmp263) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_int (tmp219, tmp263, tmp264) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp222)->tag != 14) { goto __ats_lab_88_0 ; } __ats_lab_77_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; tmp267 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, tmp265), atslab_d0ynq_node) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp267)->tag != 0) { goto __ats_lab_87_0 ; } __ats_lab_78_1: tmp268 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (tmp266) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp268 == (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_79_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_10, tmp268, atslab_0) ; ATS_FREE(tmp268) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp269)->tag != 2) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp270 = ats_caselptrlab_mac(anairiats_sum_11, tmp269, atslab_0) ; tmp271 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp (tmp219, tmp270) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp271) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp269)->tag != 1) { goto __ats_lab_85_0 ; } __ats_lab_81_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_11, tmp269, atslab_0) ; tmp273 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (tmp272) ; do { /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp274 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp273, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE) ; if (!tmp274) { goto __ats_lab_83_1 ; } tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool (tmp219, ats_true_bool) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp275 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp273, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE) ; if (!tmp275) { goto __ats_lab_84_1 ; } tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool (tmp219, ats_false_bool) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp276 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp219, tmp266) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (tmp219, 0, tmp276) ; break ; } while (0) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp277 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp219, tmp266) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (tmp219, 0, tmp277) ; break ; } while (0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: // if (tmp268 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_86_1: tmp278 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp219, tmp266) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (tmp219, 0, tmp278) ; break ; } while (0) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: __ats_lab_87_1: tmp279 = (ats_sum_ptr_type)0 ; tmp280 = (ats_sum_ptr_type)0 ; tmp221 = p1at_qid_app_dyn_tr_18 (tmp219, tmp219, tmp219, tmp265, tmp266, tmp279, 0, tmp280) ; break ; } while (0) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp222)->tag != 12) { goto __ats_lab_91_0 ; } __ats_lab_88_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_17, tmp222, atslab_0) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_17, tmp222, atslab_1) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (tmp282 == (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp283 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (tmp282) ; tmp220 = 2 ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup (tmp219, 0, tmp281, tmp283) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (tmp282 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty (tmp219) ; break ; } while (0) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp222)->tag != 13) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp284 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp220 = 2 ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (tmp284) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst (tmp219, tmp285) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp222)->tag != 15) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp286 = ats_caselptrlab_mac(anairiats_sum_17, tmp222, atslab_0) ; tmp287 = ats_caselptrlab_mac(anairiats_sum_17, tmp222, atslab_1) ; tmp288 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr (tmp287) ; tmp220 = 2 ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec (tmp219, tmp286, 0, tmp288) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp222)->tag != 16) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp289 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp291 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp289), atslab_i0de_loc) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp289), atslab_i0de_sym) ; tmp290 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp291, tmp292) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (tmp219, 1, tmp290) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp222)->tag != 17) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_9, tmp222, atslab_1) ; tmp296 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp293), atslab_i0de_loc) ; tmp297 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp293), atslab_i0de_sym) ; tmp295 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp296, tmp297) ; tmp220 = 2 ; tmp298 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp294) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as (tmp219, 1, tmp295, tmp298) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp222)->tag != 18) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_11, tmp222, atslab_0) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_string (tmp219, tmp299) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp222)->tag != 19) { goto __ats_lab_97_0 ; } __ats_lab_96_1: /* tmp300 = */ prerr_loc_interror_2 (tmp219) ; /* tmp301 = */ atspre_prerr_string (ATSstrcst(": p1at_tr: P1Tsvararg")) ; /* tmp302 = */ atspre_prerr_newline () ; /* tmp221 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (((ats_sum_ptr_type)tmp222)->tag != 20) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp303 = ats_caselptrlab_mac(anairiats_sum_21, tmp222, atslab_0) ; tmp304 = ats_caselptrlab_mac(anairiats_sum_21, tmp222, atslab_1) ; tmp305 = ats_caselptrlab_mac(anairiats_sum_21, tmp222, atslab_2) ; tmp220 = 2 ; tmp306 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (tmp305) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup (tmp219, tmp303, tmp304, tmp306) ; break ; } while (0) ; tmp308 = atspre_gte_int_int (tmp220, 1) ; if (tmp308) { tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp221), atslab_p2at_svs) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlstord_linearity_test (tmp219, tmp309) ; } else { /* empty */ } /* end of [if] */ tmp311 = atspre_gte_int_int (tmp220, 2) ; if (tmp311) { tmp312 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp221), atslab_p2at_dvs) ; /* tmp310 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlstord_linearity_test (tmp219, tmp312) ; } else { /* empty */ } /* end of [if] */ tmp218 = tmp221 ; return (tmp218) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 20915(line=700, offs=12) -- 20957(line=700, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp313) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr: tmp313 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr) ; return (tmp313) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 20983(line=703, offs=15) -- 21250(line=710, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr: do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp318 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, tmp315), atslab_l0ab_lab) ; tmp319 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp316) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr (tmp317) ; tmp314 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp314)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp314, atslab_0, tmp318) ; ats_selptrset_mac(anairiats_sum_4, tmp314, atslab_1, tmp319) ; ats_selptrset_mac(anairiats_sum_4, tmp314, atslab_2, tmp320) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp314 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: tmp314 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; break ; } while (0) ; return (tmp314) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labp1atlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 21323(line=716, offs=3) -- 21740(line=729, offs=24) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_int_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr: tmp322 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_node) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp322)->tag != 0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp323 = ats_caselptrlab_mac(anairiats_sum_9, tmp322, atslab_0) ; tmp324 = ats_caselptrlab_mac(anairiats_sum_9, tmp322, atslab_1) ; tmp325 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp323) ; tmp326 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_dn_impredicative (tmp324, arg1) ; tmp327 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (tmp327, tmp325, tmp326) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp322)->tag != 12) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp328 = ats_caselptrlab_mac(anairiats_sum_17, tmp322, atslab_0) ; tmp329 = ats_caselptrlab_mac(anairiats_sum_17, tmp322, atslab_1) ; tmp330 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr (tmp329, arg1) ; tmp331 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p1at_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list (tmp331, tmp328, tmp330) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: __ats_lab_103_1: tmp321 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (arg0) ; break ; } while (0) ; return (tmp321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 21793(line=734, offs=3) -- 22280(line=748, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr: do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp333 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp334 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp335 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr (tmp333, arg1) ; tmp337 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp335), atslab_p2at_node) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp337)->tag != 10) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_17, tmp337, atslab_0) ; tmp339 = ats_caselptrlab_mac(anairiats_sum_17, tmp337, atslab_1) ; tmp340 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp335), atslab_p2at_loc) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup (tmp340, 0, tmp338, tmp339) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: tmp336 = tmp335 ; break ; } while (0) ; tmp341 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr (tmp334, arg1) ; tmp332 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp332, atslab_0, tmp336) ; ats_selptrset_mac(anairiats_sum_6, tmp332, atslab_1, tmp341) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: tmp332 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp332) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_arg_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 22333(line=753, offs=4) -- 22930(line=769, offs=4) */ ATSstaticdec() ats_ptr_type d2sym_lrbrackets_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_int_type, tmp344) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_bool_type, tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; __ats_lab_d2sym_lrbrackets_32: /* ats_ptr_type tmp343 ; */ tmp343 = (ats_sum_ptr_type)0 ; /* ats_int_type tmp344 ; */ tmp344 = 0 ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp346 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_108_1: tmp347 = ats_caselptrlab_mac(anairiats_sum_10, tmp346, atslab_0) ; ATS_FREE(tmp346) ; do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp347)->tag != 5) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_11, tmp347, atslab_0) ; tmp343 = tmp348 ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: __ats_lab_110_1: tmp344 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (tmp346 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: tmp344 = 1 ; break ; } while (0) ; tmp350 = atspre_gt_int_int (tmp344, 0) ; if (tmp350) { /* tmp351 = */ prerr_loc_interror_2 (arg0) ; /* tmp352 = */ atspre_prerr_string (ATSstrcst(": d2sym_lrbrackets")) ; /* tmp353 = */ atspre_prerr_newline () ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp354 = d0ynq_none () ; tmp342 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make (arg0, tmp354, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS, tmp343) ; return (tmp342) ; } /* end of [d2sym_lrbrackets_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 22964(line=771, offs=4) -- 23242(line=779, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_arrsub_tr_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; __ats_lab_d1exp_arrsub_tr_33: tmp356 = d2sym_lrbrackets_32 (arg0) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (arg1) ; tmp358 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr (arg3) ; tmp355 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub (arg0, tmp356, tmp357, arg2, tmp358) ; return (tmp355) ; } /* end of [d1exp_arrsub_tr_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 23296(line=783, offs=4) -- 23626(line=793, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_assgn_tr_34 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; __ats_lab_d1exp_assgn_tr_34: do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } tmp360 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; if (tmp360 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } tmp361 = ats_caselptrlab_mac(anairiats_sum_6, tmp360, atslab_1) ; if (tmp361 != (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp362 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp363 = ats_caselptrlab_mac(anairiats_sum_6, tmp360, atslab_0) ; tmp364 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp362) ; tmp365 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp363) ; tmp359 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn (arg0, tmp364, tmp365) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: /* tmp366 = */ prerr_loc_interror_2 (arg0) ; /* tmp367 = */ atspre_prerr_string (ATSstrcst(": d1exp_assgn_tr")) ; /* tmp368 = */ atspre_prerr_newline () ; /* tmp359 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp359) ; } /* end of [d1exp_assgn_tr_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 23658(line=795, offs=4) -- 23943(line=803, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_deref_tr_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; // ATSlocal_void (tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; __ats_lab_d1exp_deref_tr_35: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } tmp370 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; if (tmp370 != (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp371) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref (arg0, tmp372) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: __ats_lab_115_1: /* tmp373 = */ prerr_loc_interror_2 (arg0) ; /* tmp374 = */ atspre_prerr_string (ATSstrcst(": d1exp_deref_tr")) ; /* tmp375 = */ atspre_prerr_newline () ; /* tmp369 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp369) ; } /* end of [d1exp_deref_tr_35] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 23996(line=807, offs=4) -- 24769(line=830, offs=4) */ ATSstaticdec() ats_void_type macro_def_check_36 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_bool_type, tmp378) ; ATSlocal (ats_bool_type, tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_bool_type, tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; __ats_lab_macro_def_check_36: tmp377 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get () ; tmp378 = atspre_gt_int_int (tmp377, 0) ; if (tmp378) { tmp379 = atspre_gt_int_int (arg1, 0) ; if (tmp379) { /* tmp380 = */ prerr_loc_error2_0 (arg0) ; /* tmp381 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp382 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp383 = */ atspre_prerr_string (ATSstrcst("] refers to a macro definition in long form")) ; /* tmp384 = */ atspre_prerr_string (ATSstrcst(", but one in short form is expected.")) ; /* tmp385 = */ atspre_prerr_newline () ; /* tmp376 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ } else { tmp386 = atspre_eq_int_int (arg1, 0) ; if (tmp386) { /* tmp387 = */ prerr_loc_error2_0 (arg0) ; /* tmp388 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp390 = */ atspre_prerr_string (ATSstrcst("] refers to a macro definition in short form")) ; /* tmp391 = */ atspre_prerr_string (ATSstrcst(", but one in long form is expected.")) ; /* tmp392 = */ atspre_prerr_newline () ; /* tmp376 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ } /* end of [if] */ return /* (tmp376) */ ; } /* end of [macro_def_check_36] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 24805(line=832, offs=4) -- 25136(line=844, offs=4) */ ATSstaticdec() ats_void_type macro_var_check_37 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp393) ; ATSlocal (ats_int_type, tmp394) ; ATSlocal (ats_bool_type, tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; __ats_lab_macro_var_check_37: tmp394 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get () ; tmp395 = atspre_gt_int_int (tmp394, 0) ; if (tmp395) { /* tmp396 = */ prerr_loc_error2_0 (arg0) ; /* tmp397 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp398 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp399 = */ atspre_prerr_string (ATSstrcst("] incorrectly refers to a macro argument variable.")) ; /* tmp400 = */ atspre_prerr_newline () ; /* tmp393 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp393) */ ; } /* end of [macro_var_check_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 25274(line=852, offs=4) -- 25584(line=861, offs=4) */ ATSstaticdec() ats_ptr_type specdynid_of_qid_38 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_bool_type, tmp403) ; ATSlocal (ats_bool_type, tmp404) ; __ats_lab_specdynid_of_qid_38: tmp402 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d0ynq_node) ; do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp402)->tag != 0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp403 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_COLONEQ) ; if (tmp403) { tmp401 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDassgn_0) ; } else { tmp404 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; if (tmp404) { tmp401 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDderef_1) ; } else { tmp401 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDnone_2) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: __ats_lab_117_1: tmp401 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDnone_2) ; break ; } while (0) ; return (tmp401) ; } /* end of [specdynid_of_qid_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 25639(line=865, offs=4) -- 27577(line=922, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_qid_tr_39 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_int_type, tmp419) ; // ATSlocal_void (tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; // ATSlocal_void (tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; // ATSlocal_void (tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; __ats_lab_d1exp_qid_tr_39: tmp406 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (arg1, arg2) ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (tmp406 == (ats_sum_ptr_type)0) { goto __ats_lab_128_0 ; } __ats_lab_118_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_10, tmp406, atslab_0) ; ATS_FREE(tmp406) ; do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)tmp407)->tag != 0) { goto __ats_lab_122_0 ; } __ats_lab_119_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; tmp409 = d2con_select_arity_9 (tmp408, 0) ; do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (tmp409 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp411 = ats_caselptrlab_mac(anairiats_sum_6, tmp409, atslab_0) ; tmp410 = tmp411 ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp410 = d2con_select_arity_err_none_10 (arg0, arg1, arg2, 0) ; break ; } while (0) ; tmp412 = (ats_sum_ptr_type)0 ; tmp413 = (ats_sum_ptr_type)0 ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con (arg0, tmp410, tmp412, 0, tmp413) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp407)->tag != 1) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp414 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; /* tmp415 = */ dyncstuseloc_posmark_3 (arg0, tmp414) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst (arg0, tmp414) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp407)->tag != 2) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; tmp417 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp (arg0, tmp416) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp417) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp407)->tag != 3) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp418 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind (tmp418) ; /* tmp420 = */ macro_def_check_36 (arg0, tmp419, arg2) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac (arg0, tmp418) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp407)->tag != 4) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp421 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; /* tmp422 = */ macro_var_check_37 (arg0, arg2) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (arg0, tmp421) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: if (((ats_sum_ptr_type)tmp407)->tag != 5) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; tmp424 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make (arg0, arg1, arg2, tmp423) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym (arg0, tmp424) ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (((ats_sum_ptr_type)tmp407)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_11, tmp407, atslab_0) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (arg0, tmp425) ; break ; } while (0) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: // if (tmp406 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_128_1: /* tmp426 = */ prerr_loc_error2_0 (arg0) ; /* tmp427 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp428 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg1) ; /* tmp430 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp431 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp432 = */ atspre_prerr_newline () ; /* tmp405 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp405) ; } /* end of [d1exp_qid_tr_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 27628(line=926, offs=4) -- 30192(line=995, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_qid_app_sta_tr_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; // ATSlocal_void (tmp456) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; // ATSlocal_void (tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp461) ; // ATSlocal_void (tmp462) ; // ATSlocal_void (tmp463) ; // ATSlocal_void (tmp464) ; // ATSlocal_void (tmp465) ; // ATSlocal_void (tmp466) ; __ats_lab_d1exp_qid_app_sta_tr_40: tmp434 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (arg4) ; tmp435 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (arg2, arg3) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: if (tmp435 == (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_129_1: tmp436 = ats_caselptrlab_mac(anairiats_sum_10, tmp435, atslab_0) ; ATS_FREE(tmp435) ; do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp436)->tag != 0) { goto __ats_lab_133_0 ; } __ats_lab_130_1: tmp437 = ats_caselptrlab_mac(anairiats_sum_11, tmp436, atslab_0) ; tmp438 = d2con_select_arity_9 (tmp437, 0) ; do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (tmp438 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_6, tmp438, atslab_0) ; tmp439 = tmp440 ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: // if (tmp438 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_132_1: tmp439 = d2con_select_arity_err_none_10 (arg1, arg2, arg3, 0) ; break ; } while (0) ; tmp441 = (ats_sum_ptr_type)0 ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con (arg0, tmp439, tmp434, 0, tmp441) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp436)->tag != 1) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp442 = ats_caselptrlab_mac(anairiats_sum_11, tmp436, atslab_0) ; tmp443 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst (arg1, tmp442) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta (arg0, tmp443, tmp434) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp436)->tag != 6) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_11, tmp436, atslab_0) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (arg1, tmp444) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta (arg0, tmp445, tmp434) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp436)->tag != 3) { goto __ats_lab_136_0 ; } __ats_lab_135_1: /* tmp446 = */ prerr_loc_error2_0 (arg1) ; /* tmp447 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_app_sta_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp448 = */ atspre_prerr_string (ATSstrcst(": the identifier refers to a macro definition")) ; /* tmp449 = */ atspre_prerr_string (ATSstrcst(", which cannot be applied to static arguments.")) ; /* tmp450 = */ atspre_prerr_newline () ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp436)->tag != 4) { goto __ats_lab_137_0 ; } __ats_lab_136_1: /* tmp451 = */ prerr_loc_error2_0 (arg1) ; /* tmp452 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_app_sta_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp453 = */ atspre_prerr_string (ATSstrcst(": the identifier refers to a macro argument variable")) ; /* tmp454 = */ atspre_prerr_string (ATSstrcst(", which cannot be applied.")) ; /* tmp455 = */ atspre_prerr_newline () ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: __ats_lab_137_1: /* tmp456 = */ prerr_loc_error2_0 (arg1) ; /* tmp457 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_app_sta_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp458 = */ atspre_prerr_string (ATSstrcst(": the identifier refers to a dynamic term that cannot be applied.")) ; /* tmp459 = */ atspre_prerr_newline () ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: // if (tmp435 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_1: /* tmp460 = */ prerr_loc_error2_0 (arg1) ; /* tmp461 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_app_sta_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp462 = */ atspre_prerr_string (ATSstrcst(": unrecognized dynamic identifier [")) ; /* tmp463 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg2) ; /* tmp464 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg3) ; /* tmp465 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp466 = */ atspre_prerr_newline () ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp433) ; } /* end of [d1exp_qid_app_sta_tr_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 30254(line=999, offs=4) -- 33112(line=1079, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_qid_app_dyn_tr_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8) { /* local vardec */ ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_int_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; // ATSlocal_void (tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; // ATSlocal_void (tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_int_type, tmp484) ; // ATSlocal_void (tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; // ATSlocal_void (tmp489) ; // ATSlocal_void (tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; // ATSlocal_void (tmp496) ; // ATSlocal_void (tmp497) ; // ATSlocal_void (tmp498) ; // ATSlocal_void (tmp499) ; // ATSlocal_void (tmp500) ; // ATSlocal_void (tmp501) ; // ATSlocal_void (tmp502) ; __ats_lab_d1exp_qid_app_dyn_tr_41: tmp468 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (arg5) ; tmp469 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (arg8) ; tmp470 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (arg3, arg4) ; do { /* branch: __ats_lab_139 */ __ats_lab_139_0: if (tmp470 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_139_1: tmp471 = ats_caselptrlab_mac(anairiats_sum_10, tmp470, atslab_0) ; ATS_FREE(tmp470) ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp471)->tag != 0) { goto __ats_lab_143_0 ; } __ats_lab_140_1: tmp472 = ats_caselptrlab_mac(anairiats_sum_11, tmp471, atslab_0) ; tmp473 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg8) ; tmp474 = d2con_select_arity_9 (tmp472, tmp473) ; do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (tmp474 == (ats_sum_ptr_type)0) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp476 = ats_caselptrlab_mac(anairiats_sum_6, tmp474, atslab_0) ; tmp475 = tmp476 ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: // if (tmp474 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_142_1: tmp475 = d2con_select_arity_err_none_10 (arg2, arg3, arg4, tmp473) ; break ; } while (0) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con (arg0, tmp475, tmp468, arg7, tmp469) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp471)->tag != 1) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp477 = ats_caselptrlab_mac(anairiats_sum_11, tmp471, atslab_0) ; /* tmp478 = */ dyncstuseloc_posmark_3 (arg2, tmp477) ; tmp479 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst (arg2, tmp477) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (arg0, arg1, tmp479, tmp468, arg6, arg7, tmp469) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp471)->tag != 2) { goto __ats_lab_145_0 ; } __ats_lab_144_1: /* tmp480 = */ prerr_loc_interror_2 (arg2) ; /* tmp481 = */ atspre_prerr_string (ATSstrcst(": d1exp_qid_app_dyn_tr: D2ITEMe1xp")) ; /* tmp482 = */ atspre_prerr_newline () ; /* tmp467 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp471)->tag != 3) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_11, tmp471, atslab_0) ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind (tmp483) ; /* tmp485 = */ macro_def_check_36 (arg2, tmp484, arg4) ; tmp486 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac (arg2, tmp483) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (arg0, arg1, tmp486, tmp468, arg6, arg7, tmp469) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp471)->tag != 4) { goto __ats_lab_147_0 ; } __ats_lab_146_1: /* tmp487 = */ prerr_loc_error2_0 (arg2) ; /* tmp488 = */ atspre_prerr_string (ATSstrcst(": the identifer refers to a macro argument variable")) ; /* tmp489 = */ atspre_prerr_string (ATSstrcst(", which cannot be applied.")) ; /* tmp490 = */ atspre_prerr_newline () ; /* tmp467 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: if (((ats_sum_ptr_type)tmp471)->tag != 5) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp491 = ats_caselptrlab_mac(anairiats_sum_11, tmp471, atslab_0) ; tmp492 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make (arg2, arg3, arg4, tmp491) ; tmp493 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym (arg2, tmp492) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (arg0, arg1, tmp493, tmp468, arg6, arg7, tmp469) ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: // if (((ats_sum_ptr_type)tmp471)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_148_1: tmp494 = ats_caselptrlab_mac(anairiats_sum_11, tmp471, atslab_0) ; tmp495 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (arg2, tmp494) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (arg0, arg1, tmp495, tmp468, arg6, arg7, tmp469) ; break ; } while (0) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: // if (tmp470 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_149_1: /* tmp496 = */ prerr_loc_error2_0 (arg2) ; /* tmp497 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_qid_app_dyn_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp498 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; /* tmp499 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg3) ; /* tmp500 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg4) ; /* tmp501 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp502 = */ atspre_prerr_newline () ; /* tmp467 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp467) ; } /* end of [d1exp_qid_app_dyn_tr_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 33175(line=1083, offs=5) -- 33514(line=1098, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_idextapp_tr_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp503) ; // ATSlocal_void (tmp504) ; // ATSlocal_void (tmp505) ; // ATSlocal_void (tmp506) ; // ATSlocal_void (tmp507) ; // ATSlocal_void (tmp508) ; __ats_lab_d1exp_idextapp_tr_42: do { /* branch: __ats_lab_150 */ __ats_lab_150_0: __ats_lab_150_1: /* tmp504 = */ prerr_loc_error2_0 (arg0) ; /* tmp505 = */ atspre_prerr_string (ATSstrcst(": the external id [")) ; /* tmp506 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp507 = */ atspre_prerr_string (ATSstrcst("] cannot be handled.")) ; /* tmp508 = */ atspre_prerr_newline () ; /* tmp503 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp503) ; } /* end of [d1exp_idextapp_tr_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 33613(line=1103, offs=5) -- 34601(line=1130, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_wths1explst_tr_43 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; // ATSlocal_void (tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; // ATSlocal_void (tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; __ats_lab_d1exp_wths1explst_tr_43: tmp510 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp510)->tag != 2) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp511 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_0) ; tmp512 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_1) ; tmp513 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp511) ; tmp514 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative (tmp512, arg1) ; tmp515 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (tmp515, tmp513, tmp514) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp510)->tag != 0) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp516 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_0) ; tmp517 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_1) ; tmp518 = d1exp_wths1explst_tr_43 (tmp516, arg1) ; tmp519 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr (tmp517) ; tmp520 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff (tmp520, tmp518, tmp519) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: if (((ats_sum_ptr_type)tmp510)->tag != 1) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp521 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_0) ; tmp522 = ats_caselptrlab_mac(anairiats_sum_9, tmp510, atslab_1) ; tmp523 = d1exp_wths1explst_tr_43 (tmp521, arg1) ; tmp524 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo (tmp524, tmp523, tmp522) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: __ats_lab_154_1: tmp526 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; /* tmp525 = */ prerr_loc_error2_0 (tmp526) ; /* tmp527 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_wths1explst_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp528 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be ascribed a type but it is not.")) ; /* tmp529 = */ atspre_prerr_newline () ; /* tmp509 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp509) ; } /* end of [d1exp_wths1explst_tr_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 34664(line=1134, offs=5) -- 35907(line=1169, offs=4) */ ATSstaticdec() ats_ptr_type i1nvarglst_tr_44 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; // ATSlocal_void (tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; // ATSlocal_void (tmp545) ; // ATSlocal_void (tmp546) ; // ATSlocal_void (tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; // ATSlocal_void (tmp549) ; // ATSlocal_void (tmp550) ; // ATSlocal_void (tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; // ATSlocal_void (tmp553) ; // ATSlocal_void (tmp554) ; // ATSlocal_void (tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; // ATSlocal_void (tmp557) ; // ATSlocal_void (tmp558) ; __ats_lab_i1nvarglst_tr_44: do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_162_0 ; } __ats_lab_155_1: tmp531 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp532 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp534 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_sym) ; tmp533 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (tmp534) ; do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (tmp533 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_156_1: tmp535 = ats_caselptrlab_mac(anairiats_sum_10, tmp533, atslab_0) ; ATS_FREE(tmp533) ; do { /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp535)->tag != 6) { goto __ats_lab_160_0 ; } __ats_lab_157_1: tmp536 = ats_caselptrlab_mac(anairiats_sum_11, tmp535, atslab_0) ; tmp538 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_typ) ; do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (tmp538 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp539 = ats_caselptrlab_mac(anairiats_sum_10, tmp538, atslab_0) ; tmp540 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp539) ; tmp537 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp537, atslab_0, tmp540) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (tmp538 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp537 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp541 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make (tmp536, tmp537) ; tmp542 = i1nvarglst_tr_44 (tmp532) ; tmp530 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp530, atslab_0, tmp541) ; ats_selptrset_mac(anairiats_sum_6, tmp530, atslab_1, tmp542) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: __ats_lab_160_1: tmp544 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_loc) ; /* tmp543 = */ prerr_loc_error2_0 (tmp544) ; /* tmp545 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1nvarglst_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp546 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; tmp548 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_sym) ; /* tmp547 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp548) ; /* tmp549 = */ atspre_prerr_string (ATSstrcst("] does not refer to a variable.")) ; /* tmp550 = */ atspre_prerr_newline () ; /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (tmp533 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: tmp552 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_loc) ; /* tmp551 = */ prerr_loc_error2_0 (tmp552) ; /* tmp553 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1nvarglst_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp554 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; tmp556 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp531), atslab_i1nvarg_sym) ; /* tmp555 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp556) ; /* tmp557 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp558 = */ atspre_prerr_newline () ; /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_162_1: tmp530 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp530) ; } /* end of [i1nvarglst_tr_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 35938(line=1171, offs=4) -- 36149(line=1177, offs=4) */ ATSstaticdec() ats_ptr_type i1nvresstate_tr_45 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (anairiats_rec_0, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; __ats_lab_i1nvresstate_tr_45: tmp561 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1nvresstate_qua) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp561) ; tmp562 = ats_select_mac(tmp560, atslab_0) ; tmp563 = ats_select_mac(tmp560, atslab_1) ; tmp565 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1nvresstate_arg) ; tmp564 = i1nvarglst_tr_44 (tmp565) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make (tmp562, tmp563, tmp564) ; return (tmp559) ; } /* end of [i1nvresstate_tr_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 36182(line=1179, offs=4) -- 36563(line=1188, offs=4) */ ATSstaticdec() ats_ptr_type loopi1nv_tr_46 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (anairiats_rec_0, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; __ats_lab_loopi1nv_tr_46: tmp568 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_loopi1nv_qua) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp568) ; tmp569 = ats_select_mac(tmp567, atslab_0) ; tmp570 = ats_select_mac(tmp567, atslab_1) ; tmp572 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_loopi1nv_met) ; do { /* branch: __ats_lab_163 */ __ats_lab_163_0: if (tmp572 == (ats_sum_ptr_type)0) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp573 = ats_caselptrlab_mac(anairiats_sum_10, tmp572, atslab_0) ; tmp574 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int (tmp573) ; tmp571 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp571, atslab_0, tmp574) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: // if (tmp572 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_164_1: tmp571 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp576 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_loopi1nv_arg) ; tmp575 = i1nvarglst_tr_44 (tmp576) ; tmp578 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_loopi1nv_res) ; tmp577 = i1nvresstate_tr_45 (tmp578) ; tmp579 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_loopi1nv_loc) ; tmp566 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make (tmp579, tmp569, tmp570, tmp571, tmp575, tmp577) ; return (tmp566) ; } /* end of [loopi1nv_tr_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 36613(line=1192, offs=4) -- 37151(line=1209, offs=4) */ ATSstaticdec() ats_ptr_type m1atch_tr_47 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; // ATSlocal_void (tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; // ATSlocal_void (tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; __ats_lab_m1atch_tr_47: tmp582 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_m1atch_exp) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp582) ; tmp584 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_m1atch_pat) ; do { /* branch: __ats_lab_165 */ __ats_lab_165_0: if (tmp584 == (ats_sum_ptr_type)0) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp585 = ats_caselptrlab_mac(anairiats_sum_10, tmp584, atslab_0) ; tmp586 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp585) ; tmp588 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp586), atslab_p2at_svs) ; tmp587 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (tmp588) ; /* tmp589 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp587) ; tmp591 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp586), atslab_p2at_dvs) ; tmp590 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp591) ; /* tmp592 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp590) ; tmp583 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp583, atslab_0, tmp586) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: // if (tmp584 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_166_1: tmp583 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp593 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_m1atch_loc) ; tmp580 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make (tmp593, tmp581, tmp583) ; return (tmp580) ; } /* end of [m1atch_tr_47] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 37178(line=1211, offs=4) -- 37262(line=1212, offs=53) */ ATSstaticdec() ats_ptr_type m1atchlst_tr_48 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp594) ; __ats_lab_m1atchlst_tr_48: tmp594 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &m1atch_tr_47) ; return (tmp594) ; } /* end of [m1atchlst_tr_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 37313(line=1217, offs=4) -- 38708(line=1258, offs=4) */ ATSstaticdec() ats_ptr_type c1lau_tr_49 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_int_type, tmp602) ; // ATSlocal_void (tmp603) ; ATSlocal (ats_bool_type, tmp604) ; // ATSlocal_void (tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; // ATSlocal_void (tmp607) ; // ATSlocal_void (tmp608) ; ATSlocal (ats_bool_type, tmp609) ; // ATSlocal_void (tmp610) ; ATSlocal (ats_bool_type, tmp611) ; // ATSlocal_void (tmp612) ; // ATSlocal_void (tmp613) ; ATSlocal (ats_bool_type, tmp614) ; // ATSlocal_void (tmp615) ; // ATSlocal_void (tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; // ATSlocal_void (tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; // ATSlocal_void (tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_int_type, tmp629) ; ATSlocal (ats_int_type, tmp630) ; __ats_lab_c1lau_tr_49: tmp596 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_pat) ; tmp598 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp596), atslab_p1at_node) ; do { /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp598)->tag != 12) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp599 = ats_caselptrlab_mac(anairiats_sum_17, tmp598, atslab_1) ; tmp597 = tmp599 ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: __ats_lab_168_1: tmp600 = (ats_sum_ptr_type)0 ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp597, atslab_0, tmp596) ; ats_selptrset_mac(anairiats_sum_6, tmp597, atslab_1, tmp600) ; break ; } while (0) ; tmp601 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1atlst_tr (tmp597) ; tmp602 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp601) ; tmp604 = atspre_ineq (tmp602, arg0) ; if (tmp604) { tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_loc) ; /* tmp605 = */ prerr_loc_error2_0 (tmp606) ; /* tmp607 = */ atsopt_debug_prerrf (ATSstrcst(": %s: c1lau_tr"), ATSstrcst("ats_trans2_dyn1.dats")) ; tmp609 = atspre_ilt (tmp602, arg0) ; if (tmp609) { /* tmp608 = */ atspre_prerr_string (ATSstrcst(": this clause should contain more patterns.")) ; } else { /* empty */ } /* end of [if] */ tmp611 = atspre_igt (tmp602, arg0) ; if (tmp611) { /* tmp610 = */ atspre_prerr_string (ATSstrcst(": this clause should contain fewer patterns.")) ; } else { /* empty */ } /* end of [if] */ /* tmp612 = */ atspre_prerr_newline () ; /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp614 = atspre_ieq (tmp602, arg0) ; /* tmp603 = */ atspre_assert (tmp614) ; } else { /* empty */ } /* end of [if] */ /* tmp615 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp616 = ats_selsin_mac(tmp615, atslab_1) */ ; tmp618 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (tmp601) ; tmp617 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (tmp618) ; /* tmp619 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp617) ; tmp621 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (tmp601) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp621) ; /* tmp622 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp620) ; tmp624 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_gua) ; tmp623 = m1atchlst_tr_48 (tmp624) ; tmp626 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_exp) ; tmp625 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp626) ; /* tmp627 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp628 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_loc) ; tmp629 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_seq) ; tmp630 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_c1lau_neg) ; tmp595 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make (tmp628, tmp601, tmp623, tmp629, tmp630, tmp625) ; return (tmp595) ; } /* end of [c1lau_tr_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 38735(line=1260, offs=5) -- 38914(line=1264, offs=4) */ ATSstaticdec() ats_ptr_type c1laulst_tr_50 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; __ats_lab_c1laulst_tr_50: do { /* branch: __ats_lab_169 */ __ats_lab_169_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_170_0 ; } __ats_lab_169_1: tmp632 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp633 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp634 = c1lau_tr_49 (arg0, tmp632) ; tmp635 = c1laulst_tr_50 (arg0, tmp633) ; tmp631 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp631, atslab_0, tmp634) ; ats_selptrset_mac(anairiats_sum_6, tmp631, atslab_1, tmp635) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_170_1: tmp631 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp631) ; } /* end of [c1laulst_tr_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 38964(line=1268, offs=4) -- 39266(line=1276, offs=4) */ ATSstaticdec() ats_ptr_type sc1lau_tr_dn_51 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp636) ; // ATSlocal_void (tmp637) ; // ATSlocal_void (tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; // ATSlocal_void (tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; __ats_lab_sc1lau_tr_dn_51: /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp638 = ats_selsin_mac(tmp637, atslab_1) */ ; tmp640 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_sc1lau_pat) ; tmp639 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__sp1at_tr_dn (tmp640, arg1) ; tmp642 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_sc1lau_exp) ; tmp641 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp642) ; /* tmp643 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp644 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_sc1lau_loc) ; tmp636 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sc2lau_make (tmp644, tmp639, tmp641) ; return (tmp636) ; } /* end of [sc1lau_tr_dn_51] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 39294(line=1278, offs=5) -- 39605(line=1287, offs=31) */ ATSstaticdec() ats_ptr_type sc1laulst_tr_dn_52 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; __ats_lab_sc1laulst_tr_dn_52: do { /* branch: __ats_lab_171 */ __ats_lab_171_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp646 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp647 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp648 = sc1lau_tr_dn_51 (tmp646, arg1) ; tmp649 = sc1laulst_tr_dn_52 (tmp647, arg1) ; tmp645 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp645, atslab_0, tmp648) ; ats_selptrset_mac(anairiats_sum_6, tmp645, atslab_1, tmp649) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_172_1: tmp645 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp645) ; } /* end of [sc1laulst_tr_dn_52] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 1730(line=49, offs=7) -- 2141(line=60, offs=8) */ ATSstaticdec() ats_void_type aux_56 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp673) ; ATSlocal (ats_bool_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_int_type, tmp676) ; __ats_lab_aux_56: tmp674 = atspre_igt (arg1, 0) ; if (tmp674) { ats_ptrget_mac(ats_int_type, arg0) = arg2 ; tmp675 = atspre_padd_size (arg0, sizeof(ats_int_type)) ; tmp676 = atspre_isub (arg1, 1) ; arg0 = tmp675 ; arg1 = tmp676 ; arg2 = arg2 ; goto __ats_lab_aux_56 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp673) */ ; } /* end of [aux_56] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 1705(line=48, offs=26) -- 2267(line=66, offs=4) */ ATSstaticdec() ats_void_type array_ptr_initialize_elt_01688_ats_int_type (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp672) ; __ats_lab_array_ptr_initialize_elt_01688_ats_int_type: /* tmp672 = */ aux_56 (arg0, arg1, arg2) ; return /* (tmp672) */ ; } /* end of [array_ptr_initialize_elt_01688_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 2363(line=71, offs=20) -- 2513(line=76, offs=4) */ ATSstaticdec() ats_ptr_type array_ptr_make_elt_01689_ats_int_type (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; // ATSlocal_void (tmp671) ; __ats_lab_array_ptr_make_elt_01689_ats_int_type: tmp669 = ats_array_ptr_alloc_tsz (arg0, sizeof(ats_int_type)) ; tmp670 = ats_selsin_mac(tmp669, atslab_2) ; /* tmp671 = */ array_ptr_initialize_elt_01688_ats_int_type (tmp670, arg0, arg1) ; tmp668 = tmp670 ; return (tmp668) ; } /* end of [array_ptr_make_elt_01689_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 40673(line=1314, offs=9) -- 41226(line=1326, offs=26) */ ATSstaticdec() ats_void_type check_57 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_int_type, tmp684) ; // ATSlocal_void (tmp685) ; ATSlocal (ats_bool_type, tmp686) ; // ATSlocal_void (tmp687) ; ATSlocal (ats_bool_type, tmp688) ; ATSlocal (ats_int_type, tmp689) ; ATSlocal (ats_int_type, tmp690) ; __ats_lab_check_57: do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp679 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp680 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp681 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp679), atslab_sc2lau_pat) ; tmp682 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp681), atslab_sp2at_node) ; // tmp683 = ats_caselptrlab_mac(anairiats_sum_6, tmp682, atslab_0) ; tmp684 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_tag (tmp683) ; tmp686 = atspre_igte (ats_castfn_mac(ats_int_type, tmp684), 0) ; /* tmp685 = */ atspre_assert (tmp686) ; tmp688 = atspre_ilt (ats_castfn_mac(ats_int_type, tmp684), arg1) ; /* tmp687 = */ atspre_assert (tmp688) ; tmp690 = ats_caselptrind_mac(ats_int_type, arg0, [ats_castfn_mac(ats_int_type, tmp684)]) ; tmp689 = atspre_add_int_int (tmp690, 1) ; ats_caselptrind_mac(ats_int_type, arg0, [ats_castfn_mac(ats_int_type, tmp684)]) = tmp689 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp680 ; goto __ats_lab_check_57 ; // tail call break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_178_1: break ; } while (0) ; return /* (tmp678) */ ; } /* end of [check_57] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 41351(line=1331, offs=9) -- 42579(line=1357, offs=10) */ ATSstaticdec() ats_int_type loop_errmsg_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_int_type arg5) { /* local vardec */ ATSlocal (ats_int_type, tmp692) ; ATSlocal (ats_bool_type, tmp693) ; ATSlocal (ats_int_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_bool_type, tmp697) ; ATSlocal (ats_int_type, tmp698) ; ATSlocal (ats_bool_type, tmp699) ; // ATSlocal_void (tmp700) ; // ATSlocal_void (tmp701) ; // ATSlocal_void (tmp702) ; // ATSlocal_void (tmp703) ; // ATSlocal_void (tmp704) ; // ATSlocal_void (tmp705) ; ATSlocal (ats_int_type, tmp706) ; ATSlocal (ats_int_type, tmp707) ; // ATSlocal_void (tmp708) ; // ATSlocal_void (tmp709) ; // ATSlocal_void (tmp710) ; // ATSlocal_void (tmp711) ; // ATSlocal_void (tmp712) ; // ATSlocal_void (tmp713) ; ATSlocal (ats_int_type, tmp714) ; ATSlocal (ats_int_type, tmp715) ; __ats_lab_loop_errmsg_58: tmp693 = atspre_ilt (arg4, arg2) ; if (tmp693) { tmp694 = ats_caselptrind_mac(ats_int_type, arg1, [arg4]) ; do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_183_0 ; } __ats_lab_179_1: tmp695 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_0) ; tmp696 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_1) ; do { /* branch: __ats_lab_180 */ __ats_lab_180_0: __ats_lab_180_1: tmp697 = atspre_eq_int_int (tmp694, 1) ; if (!tmp697) { goto __ats_lab_181_1 ; } tmp698 = atspre_iadd (arg4, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp696 ; arg4 = tmp698 ; arg5 = arg5 ; goto __ats_lab_loop_errmsg_58 ; // tail call break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: __ats_lab_181_1: tmp699 = atspre_eq_int_int (tmp694, 0) ; if (!tmp699) { goto __ats_lab_182_1 ; } /* tmp700 = */ prerr_loc_error2_0 (arg0) ; /* tmp701 = */ atspre_prerr_string (ATSstrcst(": ill-formed static case-expression")) ; /* tmp702 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp703 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp695) ; /* tmp704 = */ atspre_prerr_string (ATSstrcst("] is missing.")) ; /* tmp705 = */ atspre_prerr_newline () ; tmp706 = atspre_iadd (arg4, 1) ; tmp707 = atspre_add_int_int (arg5, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp696 ; arg4 = tmp706 ; arg5 = tmp707 ; goto __ats_lab_loop_errmsg_58 ; // tail call break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: __ats_lab_182_1: /* tmp708 = */ prerr_loc_error2_0 (arg0) ; /* tmp709 = */ atspre_prerr_string (ATSstrcst(": ill-formed static case-expression")) ; /* tmp710 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp711 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp695) ; /* tmp712 = */ atspre_prerr_string (ATSstrcst("] occurs repeatedly.")) ; /* tmp713 = */ atspre_prerr_newline () ; tmp714 = atspre_iadd (arg4, 1) ; tmp715 = atspre_add_int_int (arg5, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp696 ; arg4 = tmp714 ; arg5 = tmp715 ; goto __ats_lab_loop_errmsg_58 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_183_1: tmp692 = arg5 ; break ; } while (0) ; } else { tmp692 = arg5 ; } /* end of [if] */ return (tmp692) ; } /* end of [loop_errmsg_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 39638(line=1290, offs=4) -- 42751(line=1363, offs=4) */ ATSstaticdec() ats_void_type sc2laulst_covercheck_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; // ATSlocal_void (tmp653) ; // ATSlocal_void (tmp654) ; // ATSlocal_void (tmp655) ; // ATSlocal_void (tmp656) ; // ATSlocal_void (tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; // ATSlocal_void (tmp660) ; // ATSlocal_void (tmp661) ; // ATSlocal_void (tmp662) ; // ATSlocal_void (tmp663) ; // ATSlocal_void (tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_int_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp677) ; // ATSlocal_void (tmp691) ; ATSlocal (ats_int_type, tmp716) ; // ATSlocal_void (tmp717) ; ATSlocal (ats_bool_type, tmp718) ; __ats_lab_sc2laulst_covercheck_53: do { /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp652 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_0) ; tmp651 = tmp652 ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: __ats_lab_174_1: /* tmp653 = */ prerr_loc_error2_0 (arg0) ; /* tmp654 = */ atspre_prerr_string (ATSstrcst(": the static expression being analyzed is of the sort [")) ; /* tmp655 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg2) ; /* tmp656 = */ atspre_prerr_string (ATSstrcst("], which is not a base sort as is required.")) ; /* tmp657 = */ atspre_prerr_newline () ; /* tmp651 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp651)->tag != 2) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp659 = ats_caselptrlab_mac(anairiats_sum_11, tmp651, atslab_0) ; tmp658 = tmp659 ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: __ats_lab_176_1: /* tmp660 = */ prerr_loc_error2_0 (arg0) ; /* tmp661 = */ atspre_prerr_string (ATSstrcst(": the static expression being analyzed is of the sort [")) ; /* tmp662 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg2) ; /* tmp663 = */ atspre_prerr_string (ATSstrcst("], which is not a datasort as is required.")) ; /* tmp664 = */ atspre_prerr_newline () ; /* tmp658 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp665 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_conlst (tmp658) ; tmp666 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_length (tmp665) ; tmp667 = array_ptr_make_elt_01689_ats_int_type (tmp666, 0) ; tmp677 = ats_selsin_mac(tmp667, atslab_2) ; /* tmp691 = */ check_57 (tmp677, tmp666, arg1) ; tmp716 = loop_errmsg_58 (arg0, tmp677, tmp666, tmp665, 0, 0) ; /* tmp717 = */ ats_array_ptr_free (tmp677) ; tmp718 = atspre_gt_int_int (tmp716, 0) ; if (tmp718) { /* tmp650 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp650) */ ; } /* end of [sc2laulst_covercheck_53] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 42864(line=1369, offs=7) -- 44193(line=1400, offs=33) */ ATSstaticdec() ats_ptr_type proc_60 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_bool_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_int_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; // ATSlocal_void (tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; // ATSlocal_void (tmp734) ; // ATSlocal_void (tmp735) ; // ATSlocal_void (tmp736) ; ATSlocal (ats_int_type, tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_bool_type, tmp739) ; ATSlocal (ats_int_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_bool_type, tmp742) ; __ats_lab_proc_60: do { /* branch: __ats_lab_184 */ __ats_lab_184_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_191_0 ; } __ats_lab_184_1: tmp721 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp722 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp723 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp721), atslab_p2at_node) ; do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)tmp723)->tag != 0) { goto __ats_lab_190_0 ; } __ats_lab_185_1: tmp724 = ats_caselptrlab_mac(anairiats_sum_9, tmp723, atslab_0) ; tmp725 = ats_caselptrlab_mac(anairiats_sum_9, tmp723, atslab_1) ; do { /* branch: __ats_lab_186 */ __ats_lab_186_0: __ats_lab_186_1: tmp726 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_types (tmp725) ; if (!tmp726) { goto __ats_lab_189_1 ; } do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (tmp722 != (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp728 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp721), atslab_p2at_loc) ; tmp729 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg (tmp725) ; tmp727 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (tmp728, tmp724, tmp729) ; tmp730 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp730 ; tmp731 = (ats_sum_ptr_type)0 ; tmp720 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_0, tmp727) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_1, tmp731) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: // if (tmp722 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_188_1: tmp733 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp721), atslab_p2at_loc) ; /* tmp732 = */ prerr_loc_error2_0 (tmp733) ; /* tmp734 = */ atsopt_debug_prerrf (ATSstrcst(": %s: lamvararg_proc: proc"), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp735 = */ atspre_prerr_string (ATSstrcst(": this function argument must be the last one.")) ; /* tmp736 = */ atspre_prerr_newline () ; /* tmp720 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: __ats_lab_189_1: tmp737 = ats_ptrget_mac(ats_int_type, arg1) ; tmp738 = proc_60 (tmp722, arg1) ; tmp739 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp737) ; if (tmp739) { tmp720 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_0, tmp721) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_1, tmp738) ; } else { tmp720 = arg0 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: __ats_lab_190_1: tmp740 = ats_ptrget_mac(ats_int_type, arg1) ; tmp741 = proc_60 (tmp722, arg1) ; tmp742 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp740) ; if (tmp742) { tmp720 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_0, tmp721) ; ats_selptrset_mac(anairiats_sum_6, tmp720, atslab_1, tmp741) ; } else { tmp720 = arg0 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_191_1: tmp720 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp720) ; } /* end of [proc_60] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 42810(line=1367, offs=4) -- 44259(line=1405, offs=4) */ ATSstaticdec() ats_ptr_type lamvararg_proc_59 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_int_type, tmp743) ; __ats_lab_lamvararg_proc_59: /* ats_int_type tmp743 ; */ tmp743 = 0 ; tmp719 = proc_60 (arg0, (&tmp743)) ; return (tmp719) ; } /* end of [lamvararg_proc_59] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 44291(line=1407, offs=4) -- 45503(line=1445, offs=4) */ ATSstaticdec() anairiats_rec_31 d1exp_arg_body_tr_61 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_31, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_int_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_int_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; // ATSlocal_void (tmp754) ; // ATSlocal_void (tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; // ATSlocal_void (tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; // ATSlocal_void (tmp761) ; // ATSlocal_void (tmp762) ; // ATSlocal_void (tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_bool_type, tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; __ats_lab_d1exp_arg_body_tr_61: /* ats_ptr_type tmp745 ; */ tmp745 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; tmp746 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr (arg0, (&tmp745)) ; tmp747 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse (tmp745) ; tmp745 = tmp747 ; /* ats_int_type tmp748 ; */ tmp748 = 0 ; tmp750 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp746), atslab_p2at_node) ; do { /* branch: __ats_lab_192 */ __ats_lab_192_0: if (((ats_sum_ptr_type)tmp750)->tag != 10) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp751 = ats_caselptrlab_mac(anairiats_sum_17, tmp750, atslab_0) ; tmp752 = ats_caselptrlab_mac(anairiats_sum_17, tmp750, atslab_1) ; tmp748 = tmp751 ; tmp749 = tmp752 ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: __ats_lab_193_1: tmp753 = (ats_sum_ptr_type)0 ; tmp749 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp749, atslab_0, tmp746) ; ats_selptrset_mac(anairiats_sum_6, tmp749, atslab_1, tmp753) ; break ; } while (0) ; /* tmp754 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp755 = ats_selsin_mac(tmp754, atslab_1) */ ; tmp757 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp746), atslab_p2at_svs) ; tmp756 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (tmp757) ; /* tmp758 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp756) ; tmp760 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp746), atslab_p2at_dvs) ; tmp759 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp760) ; /* tmp761 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp759) ; /* tmp762 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc () ; /* tmp763 = ats_selsin_mac(tmp762, atslab_1) */ ; tmp765 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none (tmp745) ; if (tmp765) { tmp764 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (arg1) ; } else { tmp764 = d1exp_wths1explst_tr_43 (arg1, tmp745) ; } /* end of [if] */ /* tmp766 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec () ; /* tmp767 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp768 = lamvararg_proc_59 (tmp749) ; tmp744.atslab_0 = tmp748 ; tmp744.atslab_1 = tmp768 ; tmp744.atslab_2 = tmp764 ; return (tmp744) ; } /* end of [d1exp_arg_body_tr_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 45575(line=1450, offs=10) -- 60521(line=1845, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (ats_ptr_type, tmp783) ; ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_int_type, tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_bool_type, tmp831) ; ATSlocal (ats_char_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_int_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_int_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_int_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; // ATSlocal_void (tmp846) ; // ATSlocal_void (tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; // ATSlocal_void (tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_int_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_ptr_type, tmp867) ; // ATSlocal_void (tmp868) ; // ATSlocal_void (tmp869) ; // ATSlocal_void (tmp870) ; // ATSlocal_void (tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; // ATSlocal_void (tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; ATSlocal (ats_ptr_type, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_ptr_type, tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; // ATSlocal_void (tmp888) ; // ATSlocal_void (tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; // ATSlocal_void (tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; ATSlocal (ats_ptr_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_int_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (anairiats_rec_31, tmp917) ; ATSlocal (ats_int_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; ATSlocal (ats_ptr_type, tmp920) ; ATSlocal (ats_int_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (anairiats_rec_31, tmp924) ; ATSlocal (ats_int_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; // ATSlocal_void (tmp932) ; // ATSlocal_void (tmp933) ; // ATSlocal_void (tmp934) ; // ATSlocal_void (tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; // ATSlocal_void (tmp938) ; // ATSlocal_void (tmp939) ; ATSlocal (anairiats_rec_0, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; // ATSlocal_void (tmp944) ; ATSlocal (ats_int_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_bool_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; ATSlocal (ats_ptr_type, tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_int_type, tmp957) ; // ATSlocal_void (tmp958) ; // ATSlocal_void (tmp959) ; ATSlocal (ats_bool_type, tmp960) ; // ATSlocal_void (tmp961) ; ATSlocal (ats_bool_type, tmp962) ; // ATSlocal_void (tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; // ATSlocal_void (tmp969) ; // ATSlocal_void (tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; // ATSlocal_void (tmp973) ; ATSlocal (ats_int_type, tmp974) ; ATSlocal (ats_ptr_type, tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_int_type, tmp977) ; ATSlocal (ats_int_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_bool_type, tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; // ATSlocal_void (tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; // ATSlocal_void (tmp992) ; // ATSlocal_void (tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; // ATSlocal_void (tmp996) ; // ATSlocal_void (tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; // ATSlocal_void (tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_ptr_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; ATSlocal (ats_int_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; ATSlocal (ats_ptr_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; // ATSlocal_void (tmp1017) ; ATSlocal (ats_int_type, tmp1018) ; ATSlocal (ats_ptr_type, tmp1019) ; ATSlocal (ats_ptr_type, tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; ATSlocal (ats_bool_type, tmp1023) ; ATSlocal (ats_ptr_type, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; ATSlocal (ats_ptr_type, tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (ats_ptr_type, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; ATSlocal (ats_ptr_type, tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_ptr_type, tmp1042) ; ATSlocal (ats_ptr_type, tmp1043) ; ATSlocal (ats_int_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; ATSlocal (ats_ptr_type, tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; ATSlocal (ats_ptr_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_ptr_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_int_type, tmp1060) ; ATSlocal (ats_int_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; // ATSlocal_void (tmp1068) ; // ATSlocal_void (tmp1069) ; ATSlocal (ats_ptr_type, tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; // ATSlocal_void (tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; // ATSlocal_void (tmp1076) ; // ATSlocal_void (tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; // ATSlocal_void (tmp1081) ; // ATSlocal_void (tmp1082) ; // ATSlocal_void (tmp1083) ; // ATSlocal_void (tmp1084) ; // ATSlocal_void (tmp1085) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr: tmp770 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp771 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp771)->tag != 2) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp772 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp773 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp774 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp772) ; tmp775 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp773) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (tmp770, tmp774, tmp775) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp771)->tag != 0) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp776 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp777 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp778 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp776) ; tmp779 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr (tmp777) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff (tmp770, tmp778, tmp779) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp771)->tag != 1) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp780 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp781 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp782 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp780) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo (tmp770, tmp782, tmp781) ; break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp771)->tag != 3) { goto __ats_lab_206_0 ; } __ats_lab_197_1: tmp783 = ats_caselptrlab_mac(anairiats_sum_18, tmp771, atslab_0) ; tmp784 = ats_caselptrlab_mac(anairiats_sum_18, tmp771, atslab_1) ; tmp785 = ats_caselptrlab_mac(anairiats_sum_18, tmp771, atslab_2) ; tmp786 = ats_caselptrlab_mac(anairiats_sum_18, tmp771, atslab_3) ; tmp787 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp783), atslab_d1exp_loc) ; tmp788 = d1exp_make_d1exp_12 (tmp783) ; tmp789 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp788), atslab_d1exp_node) ; do { /* branch: __ats_lab_198 */ __ats_lab_198_0: if (((ats_sum_ptr_type)tmp789)->tag != 41) { goto __ats_lab_202_0 ; } __ats_lab_198_1: tmp790 = ats_caselptrlab_mac(anairiats_sum_9, tmp789, atslab_0) ; tmp791 = ats_caselptrlab_mac(anairiats_sum_9, tmp789, atslab_1) ; tmp792 = specdynid_of_qid_38 (tmp790, tmp791) ; do { /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp792)->tag != 2) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp793 = (ats_sum_ptr_type)0 ; tmp769 = d1exp_qid_app_dyn_tr_41 (tmp770, tmp787, tmp787, tmp790, tmp791, tmp793, tmp784, tmp785, tmp786) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp792)->tag != 0) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp769 = d1exp_assgn_tr_34 (tmp770, tmp786) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: // if (((ats_sum_ptr_type)tmp792)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_201_1: tmp769 = d1exp_deref_tr_35 (tmp770, tmp786) ; break ; } while (0) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)tmp789)->tag != 4) { goto __ats_lab_205_0 ; } __ats_lab_202_1: tmp794 = ats_caselptrlab_mac(anairiats_sum_9, tmp789, atslab_0) ; tmp795 = ats_caselptrlab_mac(anairiats_sum_9, tmp789, atslab_1) ; tmp796 = d1exp_make_d1exp_12 (tmp794) ; tmp797 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp796), atslab_d1exp_node) ; do { /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)tmp797)->tag != 41) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp798 = ats_caselptrlab_mac(anairiats_sum_9, tmp797, atslab_0) ; tmp799 = ats_caselptrlab_mac(anairiats_sum_9, tmp797, atslab_1) ; tmp800 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp796), atslab_d1exp_loc) ; tmp769 = d1exp_qid_app_dyn_tr_41 (tmp770, tmp787, tmp800, tmp798, tmp799, tmp795, tmp784, tmp785, tmp786) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: __ats_lab_204_1: tmp801 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp796) ; tmp802 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (tmp795) ; tmp803 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp786) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (tmp770, tmp787, tmp801, tmp802, tmp784, tmp785, tmp803) ; break ; } while (0) ; break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: __ats_lab_205_1: tmp804 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp788) ; tmp805 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp786) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn (tmp770, tmp804, tmp784, tmp785, tmp805) ; break ; } while (0) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp771)->tag != 4) { goto __ats_lab_209_0 ; } __ats_lab_206_1: tmp806 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp807 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp808 = d1exp_make_d1exp_12 (tmp806) ; tmp809 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp808), atslab_d1exp_node) ; do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (((ats_sum_ptr_type)tmp809)->tag != 41) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp810 = ats_caselptrlab_mac(anairiats_sum_9, tmp809, atslab_0) ; tmp811 = ats_caselptrlab_mac(anairiats_sum_9, tmp809, atslab_1) ; tmp812 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp808), atslab_d1exp_loc) ; tmp769 = d1exp_qid_app_sta_tr_40 (tmp770, tmp812, tmp810, tmp811, tmp807) ; break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: __ats_lab_208_1: tmp813 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp808) ; tmp814 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (tmp807) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta (tmp770, tmp813, tmp814) ; break ; } while (0) ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)tmp771)->tag != 5) { goto __ats_lab_214_0 ; } __ats_lab_209_1: tmp815 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp816 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp817 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; do { /* branch: __ats_lab_210 */ __ats_lab_210_0: if (tmp816 == (ats_sum_ptr_type)0) { goto __ats_lab_213_0 ; } __ats_lab_210_1: do { /* branch: __ats_lab_211 */ __ats_lab_211_0: if (tmp817 == (ats_sum_ptr_type)0) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp818 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: // if (tmp817 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_212_1: tmp818 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; break ; } while (0) ; break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: // if (tmp816 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_213_1: tmp818 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; break ; } while (0) ; tmp819 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp815, tmp818) ; tmp820 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr (tmp816) ; tmp821 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp817) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit (tmp770, tmp819, tmp820, tmp821) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp771)->tag != 6) { goto __ats_lab_217_0 ; } __ats_lab_214_1: tmp822 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp823 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; do { /* branch: __ats_lab_215 */ __ats_lab_215_0: if (tmp822 == (ats_sum_ptr_type)0) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp825 = ats_caselptrlab_mac(anairiats_sum_10, tmp822, atslab_0) ; tmp826 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp825, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; tmp824 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp824, atslab_0, tmp826) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: // if (tmp822 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_216_1: tmp824 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp827 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp823) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz (tmp770, tmp824, tmp827) ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp771)->tag != 7) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp828 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp829 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp830 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; tmp769 = d1exp_arrsub_tr_33 (tmp770, tmp828, tmp829, tmp830) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp771)->tag != 8) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp831 = ats_caselptrlab_mac(anairiats_sum_32, tmp771, atslab_0) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool (tmp770, tmp831) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp771)->tag != 10) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp832 = ats_caselptrlab_mac(anairiats_sum_20, tmp771, atslab_0) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char (tmp770, tmp832) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp771)->tag != 11) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp833 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp (tmp770, tmp833) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp771)->tag != 9) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp834 = ats_caselptrlab_mac(anairiats_sum_33, tmp771, atslab_0) ; tmp835 = ats_caselptrlab_mac(anairiats_sum_33, tmp771, atslab_1) ; tmp836 = ats_caselptrlab_mac(anairiats_sum_33, tmp771, atslab_2) ; tmp837 = ats_caselptrlab_mac(anairiats_sum_33, tmp771, atslab_3) ; tmp838 = i1nvresstate_tr_45 (tmp835) ; tmp839 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp836) ; tmp840 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp839) ; tmp841 = c1laulst_tr_50 (tmp840, tmp837) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof (tmp770, tmp834, tmp838, tmp840, tmp839, tmp841) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp771)->tag != 12) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp842 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_0) ; tmp843 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_1) ; tmp844 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp843) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt (tmp770, tmp842, tmp844) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: if (((ats_sum_ptr_type)tmp771)->tag != 13) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp845 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; /* tmp846 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp847 = ats_selsin_mac(tmp846, atslab_1) */ ; tmp848 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp845) ; /* tmp849 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp850 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (tmp770) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let (tmp770, tmp848, tmp850) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: if (((ats_sum_ptr_type)tmp771)->tag != 14) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp851 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_dynload (tmp770, tmp851) ; break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: if (((ats_sum_ptr_type)tmp771)->tag != 15) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp852 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp853 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp854 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp853) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask (tmp770, tmp852, tmp854) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: if (((ats_sum_ptr_type)tmp771)->tag != 16) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (tmp770) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: if (((ats_sum_ptr_type)tmp771)->tag != 17) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp855 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp856 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp857 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr (tmp855) ; tmp858 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp856) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist (tmp770, tmp857, tmp858) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: if (((ats_sum_ptr_type)tmp771)->tag != 18) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp859 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp860 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp861 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype (tmp859) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval (tmp770, tmp861, tmp860) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: if (((ats_sum_ptr_type)tmp771)->tag != 19) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp862 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_0) ; tmp863 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_1) ; tmp864 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_2) ; tmp866 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp863), atslab_i0de_loc) ; tmp867 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp863), atslab_i0de_sym) ; tmp865 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp866, tmp867) ; /* tmp868 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix (tmp865, ats_true_bool) ; /* tmp869 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push () ; /* tmp870 = ats_selsin_mac(tmp869, atslab_1) */ ; /* tmp871 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar (tmp865) ; tmp872 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp864) ; /* tmp873 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix (tmp770, tmp862, tmp865, tmp872) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: if (((ats_sum_ptr_type)tmp771)->tag != 20) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp874 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp875 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float (tmp875, tmp874) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: if (((ats_sum_ptr_type)tmp771)->tag != 21) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp876 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp877 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_floatsp (tmp877, tmp876) ; break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: if (((ats_sum_ptr_type)tmp771)->tag != 22) { goto __ats_lab_233_0 ; } __ats_lab_232_1: tmp878 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp879 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp880 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (tmp878) ; tmp881 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp879) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat (tmp770, tmp880, tmp881) ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)tmp771)->tag != 23) { goto __ats_lab_236_0 ; } __ats_lab_233_1: tmp882 = ats_caselptrlab_mac(anairiats_sum_35, tmp771, atslab_0) ; tmp883 = ats_caselptrlab_mac(anairiats_sum_35, tmp771, atslab_1) ; tmp884 = ats_caselptrlab_mac(anairiats_sum_35, tmp771, atslab_2) ; tmp885 = ats_caselptrlab_mac(anairiats_sum_35, tmp771, atslab_3) ; tmp886 = ats_caselptrlab_mac(anairiats_sum_35, tmp771, atslab_4) ; tmp887 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp883) ; /* tmp888 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp889 = ats_selsin_mac(tmp888, atslab_1) */ ; tmp890 = loopi1nv_tr_46 (tmp882) ; tmp892 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp884), atslab_d1exp_node) ; do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (((ats_sum_ptr_type)tmp892)->tag != 16) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp891 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool (tmp770, ats_true_bool) ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: __ats_lab_235_1: tmp891 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp884) ; break ; } while (0) ; tmp893 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp885) ; tmp894 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp886) ; /* tmp895 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_for (tmp770, tmp890, tmp887, tmp891, tmp893, tmp894) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)tmp771)->tag != 24) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp896 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp897 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp898 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (tmp896) ; tmp899 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp897) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat (tmp770, tmp898, tmp899) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: if (((ats_sum_ptr_type)tmp771)->tag != 25) { goto __ats_lab_238_0 ; } __ats_lab_237_1: tmp900 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp901 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; tmp769 = d1exp_idextapp_tr_42 (tmp770, tmp900, tmp901) ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: if (((ats_sum_ptr_type)tmp771)->tag != 26) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp902 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_0) ; tmp903 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_1) ; tmp904 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_2) ; tmp905 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_3) ; tmp906 = i1nvresstate_tr_45 (tmp902) ; tmp907 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp903) ; tmp908 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp904) ; tmp909 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr (tmp905) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if (tmp770, tmp906, tmp907, tmp908, tmp909) ; break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: if (((ats_sum_ptr_type)tmp771)->tag != 27) { goto __ats_lab_240_0 ; } __ats_lab_239_1: tmp910 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp911 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string (tmp910) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int (tmp770, tmp910, tmp911) ; break ; /* branch: __ats_lab_240 */ __ats_lab_240_0: if (((ats_sum_ptr_type)tmp771)->tag != 28) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp912 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp913 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_stringsp (tmp912) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_intsp (tmp770, tmp912, tmp913) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: if (((ats_sum_ptr_type)tmp771)->tag != 29) { goto __ats_lab_242_0 ; } __ats_lab_241_1: tmp914 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_0) ; tmp915 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_1) ; tmp916 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_2) ; tmp917 = d1exp_arg_body_tr_61 (tmp915, tmp916) ; tmp918 = ats_select_mac(tmp917, atslab_0) ; tmp919 = ats_select_mac(tmp917, atslab_1) ; tmp920 = ats_select_mac(tmp917, atslab_2) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn (tmp770, tmp914, tmp918, tmp919, tmp920) ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: if (((ats_sum_ptr_type)tmp771)->tag != 30) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp921 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_0) ; tmp922 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_1) ; tmp923 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_2) ; tmp924 = d1exp_arg_body_tr_61 (tmp922, tmp923) ; tmp925 = ats_select_mac(tmp924, atslab_0) ; tmp926 = ats_select_mac(tmp924, atslab_1) ; tmp927 = ats_select_mac(tmp924, atslab_2) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn (tmp770, tmp921, tmp925, tmp926, tmp927) ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: if (((ats_sum_ptr_type)tmp771)->tag != 31) { goto __ats_lab_244_0 ; } __ats_lab_243_1: tmp928 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp929 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; tmp930 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up (tmp928) ; tmp931 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp929) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met_new (tmp770, tmp930, tmp931) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: if (((ats_sum_ptr_type)tmp771)->tag != 32) { goto __ats_lab_245_0 ; } __ats_lab_244_1: /* tmp932 = */ prerr_loc_error2_0 (tmp770) ; /* tmp933 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_tr: D1Elam_sta_ana: "), ATSstrcst("ats_trans2_dyn1.dats")) ; /* tmp934 = */ atspre_prerr_string (ATSstrcst(": illegal use of static lambda-abstraction in analysis form.")) ; /* tmp935 = */ atspre_prerr_newline () ; /* tmp769 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: if (((ats_sum_ptr_type)tmp771)->tag != 33) { goto __ats_lab_246_0 ; } __ats_lab_245_1: tmp936 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp937 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; /* tmp938 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp939 = ats_selsin_mac(tmp938, atslab_1) */ ; tmp940 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp936) ; tmp941 = ats_select_mac(tmp940, atslab_0) ; tmp942 = ats_select_mac(tmp940, atslab_1) ; tmp943 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp937) ; /* tmp944 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta (tmp770, tmp941, tmp942, tmp943) ; break ; /* branch: __ats_lab_246 */ __ats_lab_246_0: if (((ats_sum_ptr_type)tmp771)->tag != 34) { goto __ats_lab_253_0 ; } __ats_lab_246_1: tmp945 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_0) ; tmp946 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_1) ; do { /* branch: __ats_lab_247 */ __ats_lab_247_0: __ats_lab_247_1: tmp947 = atspre_eq_int_int (tmp945, 0) ; if (!tmp947) { goto __ats_lab_248_1 ; } tmp948 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp946) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay (tmp770, tmp948) ; break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: __ats_lab_248_1: tmp949 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp946), atslab_d1exp_node) ; do { /* branch: __ats_lab_249 */ __ats_lab_249_0: if (((ats_sum_ptr_type)tmp949)->tag != 36) { goto __ats_lab_252_0 ; } __ats_lab_249_1: tmp950 = ats_caselptrlab_mac(anairiats_sum_17, tmp949, atslab_1) ; do { /* branch: __ats_lab_250 */ __ats_lab_250_0: if (tmp950 == (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } tmp951 = ats_caselptrlab_mac(anairiats_sum_6, tmp950, atslab_1) ; if (tmp951 == (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } tmp952 = ats_caselptrlab_mac(anairiats_sum_6, tmp951, atslab_1) ; if (tmp952 != (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } __ats_lab_250_1: tmp953 = ats_caselptrlab_mac(anairiats_sum_6, tmp950, atslab_0) ; tmp954 = ats_caselptrlab_mac(anairiats_sum_6, tmp951, atslab_0) ; tmp955 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp953) ; tmp956 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp954) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay (tmp770, tmp955, tmp956) ; break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: __ats_lab_251_1: tmp957 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp950) ; /* tmp958 = */ prerr_loc_error2_0 (tmp770) ; tmp960 = atspre_igt (tmp957, 2) ; if (tmp960) { /* tmp959 = */ atspre_prerr_string (ATSstrcst(": fewer arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ tmp962 = atspre_ilt (tmp957, 2) ; if (tmp962) { /* tmp961 = */ atspre_prerr_string (ATSstrcst(": more arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ /* tmp963 = */ atspre_prerr_newline () ; /* tmp769 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: __ats_lab_252_1: tmp964 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp946) ; tmp966 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp946), atslab_d1exp_loc) ; tmp965 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (tmp966) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay (tmp770, tmp964, tmp965) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: if (((ats_sum_ptr_type)tmp771)->tag != 35) { goto __ats_lab_254_0 ; } __ats_lab_253_1: tmp967 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp968 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; /* tmp969 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp970 = ats_selsin_mac(tmp969, atslab_1) */ ; tmp971 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp967) ; tmp972 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp968) ; /* tmp973 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let (tmp770, tmp971, tmp972) ; break ; /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp771)->tag != 36) { goto __ats_lab_257_0 ; } __ats_lab_254_1: tmp974 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_0) ; tmp975 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_1) ; do { /* branch: __ats_lab_255 */ __ats_lab_255_0: if (tmp975 == (ats_sum_ptr_type)0) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp976 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp975) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list (tmp770, tmp974, tmp976) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: // if (tmp975 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_256_1: tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (tmp770) ; break ; } while (0) ; break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: if (((ats_sum_ptr_type)tmp771)->tag != 37) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp977 = ats_caselptrlab_mac(anairiats_sum_37, tmp771, atslab_0) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_loopexn (tmp770, tmp977) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp771)->tag != 38) { goto __ats_lab_261_0 ; } __ats_lab_258_1: tmp978 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_0) ; tmp979 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_1) ; tmp980 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_2) ; tmp982 = atspre_gt_int_int (tmp978, 0) ; if (tmp982) { tmp981 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } else { tmp981 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ do { /* branch: __ats_lab_259 */ __ats_lab_259_0: if (tmp979 == (ats_sum_ptr_type)0) { goto __ats_lab_260_0 ; } __ats_lab_259_1: tmp984 = ats_caselptrlab_mac(anairiats_sum_10, tmp979, atslab_0) ; tmp985 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp984, tmp981) ; tmp983 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp983, atslab_0, tmp985) ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: // if (tmp979 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_260_1: tmp983 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp986 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp980) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst (tmp770, tmp978, tmp983, tmp986) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)tmp771)->tag != 39) { goto __ats_lab_265_0 ; } __ats_lab_261_1: tmp987 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp988 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; do { /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp987)->tag != 0) { goto __ats_lab_263_0 ; } __ats_lab_262_1: /* tmp989 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec (tmp770) ; tmp991 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp988) ; tmp990 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn (tmp770, tmp987, tmp991) ; /* tmp992 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc (tmp770) ; tmp769 = tmp990 ; break ; /* branch: __ats_lab_263 */ __ats_lab_263_0: if (((ats_sum_ptr_type)tmp987)->tag != 1) { goto __ats_lab_264_0 ; } __ats_lab_263_1: /* tmp993 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec (tmp770) ; tmp995 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp988) ; tmp994 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn (tmp770, tmp987, tmp995) ; /* tmp996 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc (tmp770) ; tmp769 = tmp994 ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: // if (((ats_sum_ptr_type)tmp987)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_264_1: /* tmp997 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc (tmp770) ; tmp999 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp988) ; tmp998 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn (tmp770, tmp987, tmp999) ; /* tmp1000 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec (tmp770) ; tmp769 = tmp998 ; break ; } while (0) ; break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: if (((ats_sum_ptr_type)tmp771)->tag != 41) { goto __ats_lab_266_0 ; } __ats_lab_265_1: tmp1001 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp1002 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp769 = d1exp_qid_tr_39 (tmp770, tmp1001, tmp1002) ; break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: if (((ats_sum_ptr_type)tmp771)->tag != 40) { goto __ats_lab_267_0 ; } __ats_lab_266_1: tmp1003 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1004 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1003) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof (tmp770, tmp1004) ; break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: if (((ats_sum_ptr_type)tmp771)->tag != 42) { goto __ats_lab_268_0 ; } __ats_lab_267_1: tmp1005 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1006 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1005) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise (tmp770, tmp1006) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: if (((ats_sum_ptr_type)tmp771)->tag != 43) { goto __ats_lab_269_0 ; } __ats_lab_268_1: tmp1007 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_0) ; tmp1008 = ats_caselptrlab_mac(anairiats_sum_17, tmp771, atslab_1) ; tmp1009 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr (tmp1008) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec (tmp770, tmp1007, 0, tmp1009) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: if (((ats_sum_ptr_type)tmp771)->tag != 44) { goto __ats_lab_270_0 ; } __ats_lab_269_1: tmp1010 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp1011 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp1012 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; tmp1013 = i1nvresstate_tr_45 (tmp1010) ; tmp1014 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (tmp1011) ; tmp1015 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp1014), atslab_s2exp_srt) ; tmp1016 = sc1laulst_tr_dn_52 (tmp1012, tmp1015) ; /* tmp1017 = */ sc2laulst_covercheck_53 (tmp770, tmp1016, tmp1015) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_scaseof (tmp770, tmp1013, tmp1014, tmp1016) ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: if (((ats_sum_ptr_type)tmp771)->tag != 45) { goto __ats_lab_273_0 ; } __ats_lab_270_1: tmp1018 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_0) ; tmp1019 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_1) ; tmp1020 = ats_caselptrlab_mac(anairiats_sum_34, tmp771, atslab_2) ; tmp1021 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1019) ; tmp1022 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1lab_tr (tmp1020) ; tmp1023 = atspre_gt_int_int (tmp1018, 0) ; if (tmp1023) { tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel_ptr (tmp770, tmp1021, tmp1022) ; } else { tmp1024 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, tmp1021), atslab_d2exp_node) ; do { /* branch: __ats_lab_271 */ __ats_lab_271_0: if (((ats_sum_ptr_type)tmp1024)->tag != 46) { goto __ats_lab_272_0 ; } __ats_lab_271_1: tmp1025 = ats_caselptrlab_mac(anairiats_sum_9, tmp1024, atslab_0) ; tmp1026 = ats_caselptrlab_mac(anairiats_sum_9, tmp1024, atslab_1) ; tmp1027 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp1026, tmp1022) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel (tmp770, tmp1025, tmp1027) ; break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: __ats_lab_272_1: tmp1029 = (ats_sum_ptr_type)0 ; tmp1028 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1028, atslab_0, tmp1022) ; ats_selptrset_mac(anairiats_sum_6, tmp1028, atslab_1, tmp1029) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel (tmp770, tmp1021, tmp1028) ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)tmp771)->tag != 46) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp1030 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1031 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_loc) ; tmp1032 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp1030) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq (tmp1031, tmp1032) ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)tmp771)->tag != 48) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp1033 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1034 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1033) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_showtype (tmp770, tmp1034) ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)tmp771)->tag != 49) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp1035 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_0) ; tmp1036 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_1) ; tmp1037 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_2) ; tmp1038 = ats_caselptrlab_mac(anairiats_sum_36, tmp771, atslab_3) ; tmp1039 = i1nvresstate_tr_45 (tmp1035) ; tmp1040 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool (tmp1036) ; tmp1041 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1037) ; tmp1042 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1038) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif (tmp770, tmp1039, tmp1040, tmp1041, tmp1042) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: if (((ats_sum_ptr_type)tmp771)->tag != 50) { goto __ats_lab_277_0 ; } __ats_lab_276_1: tmp1043 = ats_caselptrlab_mac(anairiats_sum_39, tmp771, atslab_0) ; tmp1044 = ats_caselptrlab_mac(anairiats_sum_39, tmp771, atslab_1) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string (tmp770, tmp1043, tmp1044) ; break ; /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp771)->tag != 51) { goto __ats_lab_278_0 ; } __ats_lab_277_1: tmp1045 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1046 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr (tmp1045) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct (tmp770, tmp1046) ; break ; /* branch: __ats_lab_278 */ __ats_lab_278_0: if (((ats_sum_ptr_type)tmp771)->tag != 52) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp1047 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp1048 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; tmp1049 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp1047), atslab_tmpqi0de_loc) ; tmp1050 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp1047), atslab_tmpqi0de_qua) ; tmp1051 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp1047), atslab_tmpqi0de_sym) ; tmp1052 = d1exp_qid_tr_39 (tmp1049, tmp1050, tmp1051) ; tmp1053 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up (tmp1048) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid (tmp770, tmp1052, tmp1053) ; break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: if (((ats_sum_ptr_type)tmp771)->tag != 53) { goto __ats_lab_280_0 ; } __ats_lab_279_1: tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_top (tmp770) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: if (((ats_sum_ptr_type)tmp771)->tag != 54) { goto __ats_lab_281_0 ; } __ats_lab_280_1: tmp1054 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp1055 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp1056 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; tmp1057 = i1nvresstate_tr_45 (tmp1054) ; tmp1058 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1055) ; tmp1059 = c1laulst_tr_50 (1, tmp1056) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_trywith (tmp770, tmp1057, tmp1058, tmp1059) ; break ; /* branch: __ats_lab_281 */ __ats_lab_281_0: if (((ats_sum_ptr_type)tmp771)->tag != 55) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp1060 = ats_caselptrlab_mac(anairiats_sum_21, tmp771, atslab_0) ; tmp1061 = ats_caselptrlab_mac(anairiats_sum_21, tmp771, atslab_1) ; tmp1062 = ats_caselptrlab_mac(anairiats_sum_21, tmp771, atslab_2) ; tmp1063 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (tmp1062) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup (tmp770, tmp1060, tmp1061, tmp1063) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: if (((ats_sum_ptr_type)tmp771)->tag != 56) { goto __ats_lab_283_0 ; } __ats_lab_282_1: tmp1064 = ats_caselptrlab_mac(anairiats_sum_11, tmp771, atslab_0) ; tmp1065 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1064) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat (tmp770, tmp1065) ; break ; /* branch: __ats_lab_283 */ __ats_lab_283_0: if (((ats_sum_ptr_type)tmp771)->tag != 57) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp1066 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_0) ; tmp1067 = ats_caselptrlab_mac(anairiats_sum_9, tmp771, atslab_1) ; /* tmp1068 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp1069 = ats_selsin_mac(tmp1068, atslab_1) */ ; tmp1070 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp1067) ; tmp1071 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1066) ; /* tmp1072 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where (tmp770, tmp1071, tmp1070) ; break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: if (((ats_sum_ptr_type)tmp771)->tag != 58) { goto __ats_lab_285_0 ; } __ats_lab_284_1: tmp1073 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_0) ; tmp1074 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_1) ; tmp1075 = ats_caselptrlab_mac(anairiats_sum_4, tmp771, atslab_2) ; /* tmp1076 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp1077 = ats_selsin_mac(tmp1076, atslab_1) */ ; tmp1078 = loopi1nv_tr_46 (tmp1073) ; tmp1079 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1074) ; tmp1080 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1075) ; /* tmp1081 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_while (tmp770, tmp1078, tmp1079, tmp1080) ; break ; /* branch: __ats_lab_285 */ __ats_lab_285_0: __ats_lab_285_1: /* tmp1082 = */ prerr_loc_interror_2 (tmp770) ; /* tmp1083 = */ atspre_prerr_string (ATSstrcst(": d1exp_tr: d1e0 = ")) ; /* tmp1084 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_d1exp (arg0) ; /* tmp1085 = */ atspre_prerr_newline () ; /* tmp769 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp769) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 60566(line=1848, offs=13) -- 60609(line=1848, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1086) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr: tmp1086 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr) ; return (tmp1086) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 60635(line=1850, offs=16) -- 60683(line=1850, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1087) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr: tmp1087 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explst_tr) ; return (tmp1087) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 60707(line=1853, offs=13) -- 60786(line=1854, offs=57) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr: do { /* branch: __ats_lab_286 */ __ats_lab_286_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_287_0 ; } __ats_lab_286_1: tmp1089 = ats_caselptrlab_mac(anairiats_sum_10, arg0, atslab_0) ; tmp1090 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1089) ; tmp1088 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp1088, atslab_0, tmp1090) ; break ; /* branch: __ats_lab_287 */ __ats_lab_287_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_287_1: tmp1088 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1088) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 60837(line=1858, offs=16) -- 61016(line=1861, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1091) ; ATSlocal (ats_ptr_type, tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_ptr_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr: do { /* branch: __ats_lab_288 */ __ats_lab_288_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_289_0 ; } __ats_lab_288_1: tmp1092 = ats_caselptrlab_mac(anairiats_sum_41, arg0, atslab_0) ; tmp1093 = ats_caselptrlab_mac(anairiats_sum_41, arg0, atslab_1) ; tmp1094 = ats_caselptrlab_mac(anairiats_sum_41, arg0, atslab_2) ; tmp1095 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, tmp1092), atslab_l0ab_lab) ; tmp1096 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp1093) ; tmp1097 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr (tmp1094) ; tmp1091 = ATS_MALLOC(sizeof(anairiats_sum_41)) ; ats_selptrset_mac(anairiats_sum_41, tmp1091, atslab_0, tmp1095) ; ats_selptrset_mac(anairiats_sum_41, tmp1091, atslab_1, tmp1096) ; ats_selptrset_mac(anairiats_sum_41, tmp1091, atslab_2, tmp1097) ; break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_289_1: tmp1091 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1091) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__labd1explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn1.dats: 61064(line=1865, offs=10) -- 61212(line=1867, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1lab_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; ATSlocal (ats_ptr_type, tmp1102) ; ATSlocal (ats_ptr_type, tmp1103) ; ATSlocal (ats_ptr_type, tmp1104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1lab_tr: tmp1099 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1lab_node) ; do { /* branch: __ats_lab_290 */ __ats_lab_290_0: if (((ats_sum_ptr_type)tmp1099)->tag != 0) { goto __ats_lab_291_0 ; } __ats_lab_290_1: tmp1100 = ats_caselptrlab_mac(anairiats_sum_11, tmp1099, atslab_0) ; tmp1101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1lab_loc) ; tmp1098 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_lab (tmp1101, tmp1100) ; break ; /* branch: __ats_lab_291 */ __ats_lab_291_0: // if (((ats_sum_ptr_type)tmp1099)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_291_1: tmp1102 = ats_caselptrlab_mac(anairiats_sum_11, tmp1099, atslab_0) ; tmp1103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1lab_loc) ; tmp1104 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1explstlst_tr (tmp1102) ; tmp1098 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind (tmp1103, tmp1104) ; break ; } while (0) ; return (tmp1098) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1lab_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDassgn_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDderef_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__SPDIDnone_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_dyn1_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_main_dats.c0000664000175000017500000040703512223166160022235 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "libc/CATS/time.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "libc/CATS/time.cats" // only needed for ATS/Geizella /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_d2ec_loc ; ats_ptr_type atslab_d2ec_node ; } anairiats_rec_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextcode_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstaload_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYrec_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYsum_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYuni_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_clo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_fun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_val_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV2con_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV3con_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_neq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_int_type, atslib_tm_get_min) (ats_ref_type) ; ATSextern_fun(ats_int_type, atslib_tm_get_hour) (ats_ref_type) ; ATSextern_fun(ats_int_type, atslib_tm_get_mday) (ats_ref_type) ; ATSextern_fun(ats_int_type, atslib_tm_get_mon) (ats_ref_type) ; ATSextern_fun(ats_int_type, atslib_tm_get_year) (ats_ref_type) ; ATSextern_fun(ats_time_type, atslib_time_get) () ; ATSextern_fun(ats_int_type, atsopt_gline_flag_get) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atsopt_dynloadflag_get) () ; ATSextern_fun(ats_ptr_type, atsopt_dynloadfun_name_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_fil) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extmac) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_void) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_argc_argv) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_dummy) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_identifier) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_static) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_markroot) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry_prototype) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_mainfun) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__typdeflst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__saspcstlst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_free) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynconset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_the_dyncstset_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lablst) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV2con_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV3con_0) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type emit_time_stamp_1 (ats_ref_type arg0) ; static ats_void_type emit_include_header_2 (ats_ref_type arg0) ; static ats_void_type emit_include_cats_3 (ats_ref_type arg0) ; static ats_bool_type atarray_name_test_4 (ats_ptr_type arg0) ; static ats_void_type aux_6 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) ; static ats_void_type fprint_atarray_name_5 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_8 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_typdef_rec_7 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type emit_typdef_sum_9 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_typdeflst_free_11 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_saspcstlst_13 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_conlst_16 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_cst_17 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_18 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_datcstlst_15 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_20 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_exnconlst_19 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_22 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_free_glocstlst_21 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_24 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_free_partvalst_23 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type f_con_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type _emit_dynconset_25 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type emit_dynconset_27 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_d2cst_fun_class_28 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_d2cst_val_class_29 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_d2cst_dec_30 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_d2cst_dec_prfck_31 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type f_cst_33 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type f_cst_if_34 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type _emit_dyncstset_proc_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_dyncstset_35 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type emit_dyncstset_prfck_36 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_38 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type emit_instrlst_vt_37 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_funentry_lablst_39 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type emit_funentry_lablst_prototype_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_42 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type instrlst_vt_tmpvarmap_gen_41 (ats_ptr_type arg0) ; static ats_int_type aux_44 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_extvalist_dec_43 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_46 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_extvalist_markroot_45 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_48 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_stafile_extcode_47 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_stafilelst_extcode_49 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_staload_dec_51 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_staload_app_52 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_conlst_54 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_cst_55 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_56 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type aux_staload_datcstlst_53 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_58 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type aux_staload_exnconlst_57 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_staload_50 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_dynload_dec_60 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type f_61 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_dynload_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_int_type aux_63 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type emit_extypelst_free_62 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_bool_type test_65 (ats_int_type arg0, ats_int_type arg1) ; static ats_void_type aux_main_66 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_int_type emit_extcodelst_64 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) ; static ats_bool_type main_void_is_implemented_67 () ; static ats_bool_type main_argc_argv_is_implemented_68 () ; static ats_bool_type main_dummy_is_implemented_69 () ; static ats_int_type mainatsknd_get_70 () ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 2315(line=79, offs=4) -- 2374(line=79, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_main)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 2400(line=83, offs=4) -- 3349(line=116, offs=4) */ ATSstaticdec() ats_void_type emit_time_stamp_1 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; ATSlocal (ats_time_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; ATSlocal (ats_int_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; ATSlocal (ats_int_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_int_type, tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; __ats_lab_emit_time_stamp_1: /* ats_time_type tmp2 ; */ tmp2 = atslib_time_get () ; tmp3 = atslib_localtime ((&tmp2)) ; tmp4 = ats_selsin_mac(tmp3, atslab_1) ; tmp5 = atspre_pgt (tmp4, atspre_null_ptr) ; if (tmp5) { tmp6 = atslib_tm_get_min (tmp4) ; tmp7 = atslib_tm_get_hour (tmp4) ; tmp8 = atslib_tm_get_mday (tmp4) ; tmp10 = atslib_tm_get_mon (tmp4) ; tmp9 = atspre_add_int_int (1, tmp10) ; tmp12 = atslib_tm_get_year (tmp4) ; tmp11 = atspre_add_int_int (1900, tmp12) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst("/*\n")) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst("**\n")) ; /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst("** The C code is generated by ATS/Anairiats\n")) ; /* tmp16 = */ atspre_fprint_string (arg0, ATSstrcst("** The compilation time is: ")) ; /* tmp17 = */ atspre_fprintf_exn (arg0, ATSstrcst("%i-%i-%i: %2ih:%2im\n"), tmp11, tmp9, tmp8, tmp7, tmp6) ; /* tmp18 = */ atspre_fprint_string (arg0, ATSstrcst("**\n")) ; /* tmp1 = */ atspre_fprint_string (arg0, ATSstrcst("*/\n\n")) ; } else { /* empty */ } /* end of [if] */ return /* (tmp1) */ ; } /* end of [emit_time_stamp_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 3403(line=120, offs=4) -- 4094(line=133, offs=4) */ ATSstaticdec() ats_void_type emit_include_header_2 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_emit_include_header_2: /* tmp20 = */ atspre_fprint_string (arg0, ATSstrcst("/* include some .h files */\n")) ; /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("#ifndef _ATS_HEADER_NONE\n")) ; /* tmp22 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"ats_config.h\"\n")) ; /* tmp23 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"ats_basics.h\"\n")) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"ats_types.h\"\n")) ; /* tmp25 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"ats_exception.h\"\n")) ; /* tmp26 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"ats_memory.h\"\n")) ; /* tmp27 = */ atspre_fprint_string (arg0, ATSstrcst("#endif /* _ATS_HEADER_NONE */\n")) ; /* tmp19 = */ atspre_fprint_char (arg0, '\n') ; return /* (tmp19) */ ; } /* end of [emit_include_header_2] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 4152(line=137, offs=4) -- 6066(line=169, offs=4) */ ATSstaticdec() ats_void_type emit_include_cats_3 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; // ATSlocal_void (tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_emit_include_cats_3: /* tmp29 = */ atspre_fprint_string (arg0, ATSstrcst("/* include some .cats files */\n")) ; /* tmp30 = */ atspre_fprint_string (arg0, ATSstrcst("#ifndef _ATS_PRELUDE_NONE\n")) ; /* tmp31 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/basics.cats\"\n")) ; /* tmp32 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/bool.cats\"\n")) ; /* tmp33 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/char.cats\"\n")) ; /* tmp34 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/byte.cats\"\n")) ; /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/float.cats\"\n")) ; /* tmp36 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/integer.cats\"\n")) ; /* tmp37 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/integer_ptr.cats\"\n")) ; /* tmp38 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/integer_fixed.cats\"\n")) ; /* tmp39 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/sizetype.cats\"\n")) ; /* tmp40 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/pointer.cats\"\n")) ; /* tmp41 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/reference.cats\"\n")) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/string.cats\"\n")) ; /* tmp43 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/lazy.cats\"\n")) ; /* tmp44 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/lazy_vt.cats\"\n")) ; /* tmp45 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/printf.cats\"\n")) ; /* tmp46 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/list.cats\"\n")) ; /* tmp47 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/option.cats\"\n")) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/array.cats\"\n")) ; /* tmp49 = */ atspre_fprint_string (arg0, ATSstrcst("#include \"prelude/CATS/matrix.cats\"\n")) ; /* tmp28 = */ atspre_fprint_string (arg0, ATSstrcst("#endif /* _ATS_PRELUDE_NONE */\n")) ; return /* (tmp28) */ ; } /* end of [emit_include_cats_3] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 6122(line=173, offs=4) -- 6349(line=181, offs=4) */ ATSstaticdec() ats_bool_type atarray_name_test_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_char_type, tmp52) ; __ats_lab_atarray_name_test_4: tmp51 = atspre_string_is_atend (ats_castfn_mac(ats_ptr_type, arg0), 0) ; if (tmp51) { tmp50 = ats_false_bool ; } else { tmp52 = atspre_string_get_char_at (ats_castfn_mac(ats_ptr_type, arg0), 0) ; tmp50 = atspre_eq_char_char (tmp52, '[') ; } /* end of [if] */ return (tmp50) ; } /* end of [atarray_name_test_4] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 6492(line=188, offs=5) -- 6785(line=202, offs=4) */ ATSstaticdec() ats_void_type aux_6 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) { /* local vardec */ // ATSlocal_void (tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_char_type, tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_size_type, tmp59) ; __ats_lab_aux_6: tmp55 = atspre_string_isnot_atend (arg1, arg2) ; if (tmp55) { tmp56 = atspre_string_get_char_at (arg1, arg2) ; tmp58 = atspre_neq_char_char (tmp56, ']') ; if (tmp58) { /* tmp57 = */ atspre_fprint_char (arg0, tmp56) ; } else { /* empty */ } /* end of [if] */ tmp59 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp59 ; goto __ats_lab_aux_6 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp54) */ ; } /* end of [aux_6] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 6384(line=183, offs=4) -- 6908(line=208, offs=4) */ ATSstaticdec() ats_void_type fprint_atarray_name_5 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_bool_type, tmp60) ; __ats_lab_fprint_atarray_name_5: tmp60 = atspre_string_isnot_atend (ats_castfn_mac(ats_ptr_type, arg1), 0) ; if (tmp60) { /* tmp53 = */ aux_6 (arg0, ats_castfn_mac(ats_ptr_type, arg1), 1) ; } else { /* empty */ } /* end of [if] */ return /* (tmp53) */ ; } /* end of [fprint_atarray_name_5] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 7054(line=215, offs=5) -- 7930(line=248, offs=4) */ ATSstaticdec() ats_void_type aux_8 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; // ATSlocal_void (tmp66) ; ATSlocal (ats_bool_type, tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; __ats_lab_aux_8: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_0_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp64 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp65 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_2) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp67 = atarray_name_test_4 (tmp64) ; if (!tmp67) { goto __ats_lab_2_1 ; } /* tmp68 = */ fprint_atarray_name_5 (arg0, tmp64) ; /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst(" atslab_")) ; /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label (arg0, tmp63) ; /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst("[] ;\n")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: /* tmp71 = */ atspre_fprint_string (arg0, tmp64) ; /* tmp72 = */ atspre_fprint_string (arg0, ATSstrcst(" atslab_")) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label (arg0, tmp63) ; /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n")) ; break ; } while (0) ; arg0 = arg0 ; arg1 = tmp65 ; goto __ats_lab_aux_8 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp62) */ ; } /* end of [aux_8] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 6945(line=210, offs=4) -- 8141(line=259, offs=4) */ ATSstaticdec() ats_void_type emit_typdef_rec_7 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; __ats_lab_emit_typdef_rec_7: /* tmp74 = */ atspre_fprint_string (arg0, ATSstrcst("typedef\n")) ; /* tmp75 = */ atspre_fprint_string (arg0, ATSstrcst("struct {\n")) ; /* tmp76 = */ aux_8 (arg0, arg1) ; /* tmp61 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; return /* (tmp61) */ ; } /* end of [emit_typdef_rec_7] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 8289(line=267, offs=5) -- 8641(line=283, offs=4) */ ATSstaticdec() ats_void_type aux_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; ATSlocal (ats_int_type, tmp84) ; __ats_lab_aux_10: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; /* tmp81 = */ atspre_fprint_string (arg0, tmp79) ; /* tmp82 = */ atspre_fprintf_exn (arg0, ATSstrcst(" atslab_%i"), arg1) ; /* tmp83 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n")) ; tmp84 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp84 ; arg2 = tmp80 ; goto __ats_lab_aux_10 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; return /* (tmp78) */ ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 8174(line=261, offs=4) -- 9451(line=312, offs=4) */ ATSstaticdec() ats_void_type emit_typdef_sum_9 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_bool_type, tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_bool_type, tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_bool_type, tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; __ats_lab_emit_typdef_sum_9: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp85 = atspre_eq_int_int (arg1, 0) ; if (!tmp85) { goto __ats_lab_7_1 ; } /* tmp86 = */ atspre_fprint_string (arg0, ATSstrcst("typedef struct {\n")) ; /* tmp87 = */ aux_10 (arg0, 0, arg2) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp88 = atspre_eq_int_int (arg1, 1) ; if (!tmp88) { goto __ats_lab_8_1 ; } /* tmp89 = */ atspre_fprint_string (arg0, ATSstrcst("typedef struct {\n")) ; /* tmp90 = */ atspre_fprint_string (arg0, ATSstrcst("int tag ;\n")) ; /* tmp91 = */ aux_10 (arg0, 0, arg2) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp92 = atspre_eq_int_int (arg1, -1) ; if (!tmp92) { goto __ats_lab_9_1 ; } /* tmp93 = */ atspre_fprint_string (arg0, ATSstrcst("typedef struct {\n")) ; /* tmp94 = */ atspre_fprint_string (arg0, ATSstrcst("int tag ;\n")) ; /* tmp95 = */ atspre_fprint_string (arg0, ATSstrcst("char *name ;\n")) ; /* tmp96 = */ aux_10 (arg0, 0, arg2) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: /* tmp97 = */ prerr_interror_0 () ; /* tmp98 = */ atspre_prerr_string (ATSstrcst(": aux_sum_con: tag = ")) ; /* tmp99 = */ atspre_prerr_int (arg1) ; /* tmp100 = */ atspre_prerr_newline () ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp77) */ ; } /* end of [emit_typdef_sum_9] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 9593(line=320, offs=5) -- 10300(line=348, offs=4) */ ATSstaticdec() ats_int_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_bool_type, tmp107) ; // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; // ATSlocal_void (tmp110) ; ATSlocal (ats_int_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; // ATSlocal_void (tmp113) ; ATSlocal (ats_int_type, tmp114) ; __ats_lab_aux_12: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_10_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_2) ; ATS_FREE(arg2) ; tmp107 = atspre_gt_int_int (arg1, 0) ; if (tmp107) { /* tmp106 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp103)->tag != 0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_2, tmp103, atslab_0) ; /* tmp110 = */ emit_typdef_rec_7 (arg0, tmp109) ; /* tmp108 = */ atspre_fprintf_exn (arg0, ATSstrcst(" %s ;\n"), tmp104) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp103)->tag != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_3, tmp103, atslab_0) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_3, tmp103, atslab_1) ; /* tmp113 = */ emit_typdef_sum_9 (arg0, tmp111, tmp112) ; /* tmp108 = */ atspre_fprintf_exn (arg0, ATSstrcst(" %s ;\n"), tmp104) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)tmp103)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: break ; } while (0) ; tmp114 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp114 ; arg2 = tmp105 ; goto __ats_lab_aux_12 ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp102 = arg1 ; break ; } while (0) ; return (tmp102) ; } /* end of [aux_12] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 9484(line=314, offs=4) -- 10346(line=352, offs=4) */ ATSstaticdec() ats_int_type emit_typdeflst_free_11 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp101) ; __ats_lab_emit_typdeflst_free_11: tmp101 = aux_12 (arg0, 0, arg1) ; return (tmp101) ; } /* end of [emit_typdeflst_free_11] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 10511(line=362, offs=5) -- 11112(line=384, offs=4) */ ATSstaticdec() ats_int_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_aux_14: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp118 = &ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp119 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_fil (tmp117) ; if (tmp119 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 10652(line=371, offs=10) -- 10684(line=371, offs=42)") ; } tmp120 = ats_caselptrlab_mac(anairiats_sum_4, tmp119, atslab_0) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym (tmp117) ; tmp121 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp122) ; /* tmp123 = */ atspre_fprint_string (arg0, ATSstrcst("int ")) ; /* tmp124 = */ atsopt_emit_filename (arg0, tmp120) ; /* tmp125 = */ atspre_fprint_string (arg0, ATSstrcst("__sasp__")) ; /* tmp126 = */ atsopt_emit_identifier (arg0, tmp121) ; /* tmp127 = */ atspre_fprint_string (arg0, ATSstrcst(" = 0 ;\n")) ; tmp128 = atspre_add_int_int (arg1, 1) ; tmp129 = ats_ptrget_mac(ats_ptr_type, tmp118) ; arg0 = arg0 ; arg1 = tmp128 ; arg2 = tmp129 ; goto __ats_lab_aux_14 ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp116 = arg1 ; break ; } while (0) ; return (tmp116) ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 10405(line=356, offs=5) -- 11157(line=388, offs=4) */ ATSstaticdec() ats_int_type emit_saspcstlst_13 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp115) ; __ats_lab_emit_saspcstlst_13: tmp115 = aux_14 (arg0, 0, arg1) ; return (tmp115) ; } /* end of [emit_saspcstlst_13] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 11317(line=398, offs=5) -- 11674(line=417, offs=4) */ ATSstaticdec() ats_void_type aux_conlst_16 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; __ats_lab_aux_conlst_16: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp133 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp134 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobal(ats_sum_type, ")) ; /* tmp135 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp132) ; /* tmp136 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; arg0 = arg0 ; arg1 = tmp133 ; goto __ats_lab_aux_conlst_16 ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; return /* (tmp131) */ ; } /* end of [aux_conlst_16] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 11704(line=419, offs=4) -- 11847(line=424, offs=2) */ ATSstaticdec() ats_void_type aux_cst_17 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_aux_cst_17: tmp138 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst (arg1) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp138 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_4, tmp138, atslab_0) ; /* tmp137 = */ aux_conlst_16 (arg0, tmp139) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (tmp138 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: break ; } while (0) ; return /* (tmp137) */ ; } /* end of [aux_cst_17] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 11875(line=426, offs=5) -- 12148(line=441, offs=4) */ ATSstaticdec() ats_int_type aux_18 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; // ATSlocal_void (tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_aux_18: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp142 = &ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; /* tmp143 = */ aux_cst_17 (arg0, tmp141) ; tmp144 = atspre_add_int_int (arg1, 1) ; tmp145 = ats_ptrget_mac(ats_ptr_type, tmp142) ; arg0 = arg0 ; arg1 = tmp144 ; arg2 = tmp145 ; goto __ats_lab_aux_18 ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp140 = arg1 ; break ; } while (0) ; return (tmp140) ; } /* end of [aux_18] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 11211(line=392, offs=4) -- 12195(line=445, offs=4) */ ATSstaticdec() ats_int_type emit_datcstlst_15 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp130) ; __ats_lab_emit_datcstlst_15: tmp130 = aux_18 (arg0, 0, arg1) ; return (tmp130) ; } /* end of [emit_datcstlst_15] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 12354(line=455, offs=5) -- 12810(line=475, offs=4) */ ATSstaticdec() ats_int_type aux_20 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_int_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_aux_20: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp149 = &ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobal(ats_exn_type, ")) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp148) ; /* tmp152 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; tmp153 = atspre_add_int_int (arg1, 1) ; tmp154 = ats_ptrget_mac(ats_ptr_type, tmp149) ; arg0 = arg0 ; arg1 = tmp153 ; arg2 = tmp154 ; goto __ats_lab_aux_20 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp147 = arg1 ; break ; } while (0) ; return (tmp147) ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 12248(line=449, offs=4) -- 12857(line=479, offs=4) */ ATSstaticdec() ats_int_type emit_exnconlst_19 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp146) ; __ats_lab_emit_exnconlst_19: tmp146 = aux_20 (arg0, 0, arg1) ; return (tmp146) ; } /* end of [emit_exnconlst_19] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 13018(line=489, offs=5) -- 14100(line=530, offs=4) */ ATSstaticdec() ats_int_type aux_22 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; ATSlocal (ats_int_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; ATSlocal (ats_int_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; // ATSlocal_void (tmp177) ; ATSlocal (ats_int_type, tmp178) ; __ats_lab_aux_22: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; ATS_FREE(arg2) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobal(ats_clo_ptr_type, ")) ; /* tmp160 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp157) ; /* tmp161 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; tmp162 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp162 ; arg2 = tmp158 ; goto __ats_lab_aux_22 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; ATS_FREE(arg2) ; /* tmp165 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobal(ats_fun_ptr_type, ")) ; /* tmp166 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp163) ; /* tmp167 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; tmp168 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp168 ; arg2 = tmp164 ; goto __ats_lab_aux_22 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp170 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp171 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_2) ; ATS_FREE(arg2) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobal(")) ; tmp174 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp170), atslab_valprim_typ) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp174) ; /* tmp175 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp176 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp169) ; /* tmp177 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; tmp178 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp178 ; arg2 = tmp171 ; goto __ats_lab_aux_22 ; // tail call break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (((ats_sum_ptr_type)arg2)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp156 = arg1 ; break ; } while (0) ; return (tmp156) ; } /* end of [aux_22] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 12910(line=483, offs=4) -- 14145(line=534, offs=4) */ ATSstaticdec() ats_int_type emit_free_glocstlst_21 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp155) ; __ats_lab_emit_free_glocstlst_21: tmp155 = aux_22 (arg0, 0, arg1) ; return (tmp155) ; } /* end of [emit_free_glocstlst_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 14311(line=544, offs=5) -- 14870(line=568, offs=4) */ ATSstaticdec() ats_int_type aux_24 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; ATSlocal (ats_int_type, tmp192) ; __ats_lab_aux_24: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_2) ; ATS_FREE(arg2) ; /* tmp184 = */ atspre_fprint_string (arg0, ATSstrcst("/*\n")) ; /* tmp185 = */ atspre_fprint_string (arg0, ATSstrcst("ATSstatic(")) ; tmp187 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp182), atslab_valprim_typ) ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp187) ; /* tmp188 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp189 = */ atspre_fprint_string (arg0, tmp181) ; /* tmp190 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; /* tmp191 = */ atspre_fprint_string (arg0, ATSstrcst("*/\n")) ; tmp192 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp192 ; arg2 = tmp183 ; goto __ats_lab_aux_24 ; // tail call break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp180 = arg1 ; break ; } while (0) ; return (tmp180) ; } /* end of [aux_24] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 14203(line=538, offs=4) -- 14915(line=572, offs=4) */ ATSstaticdec() ats_int_type emit_free_partvalst_23 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp179) ; __ats_lab_emit_free_partvalst_23: tmp179 = aux_24 (arg0, 0, arg1) ; return (tmp179) ; } /* end of [emit_free_partvalst_23] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 15288(line=591, offs=4) -- 15933(line=613, offs=4) */ ATSstaticdec() ats_void_type f_con_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_int_type, tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; ATSlocal (ats_bool_type, tmp202) ; // ATSlocal_void (tmp203) ; __ats_lab_f_con_26: // tmp196 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp197 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp198 = ats_ptrget_mac(ats_int_type, tmp197) ; tmp199 = atspre_add_int_int (tmp198, 1) ; ats_ptrget_mac(ats_int_type, tmp197) = tmp199 ; /* tmp200 = */ atspre_fprint_string (tmp196, ATSstrcst("ATSextern_val(")) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp202 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (arg0) ; if (!tmp202) { goto __ats_lab_32_1 ; } /* tmp201 = */ atspre_fprint_string (tmp196, ATSstrcst("ats_exn_type, ")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: /* tmp201 = */ atspre_fprint_string (tmp196, ATSstrcst("ats_sum_type, ")) ; break ; } while (0) ; /* tmp203 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (tmp196, arg0) ; /* tmp195 = */ atspre_fprint_string (tmp196, ATSstrcst(") ;\n")) ; return /* (tmp195) */ ; } /* end of [f_con_26] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 14973(line=576, offs=4) -- 16188(line=623, offs=4) */ ATSstaticdec() ats_int_type _emit_dynconset_25 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_ptr_type, tmp204) ; // ATSlocal_void (tmp205) ; __ats_lab__emit_dynconset_25: /* ats_int_type tmp194 ; */ tmp194 = 0 ; tmp204 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp204, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp204, atslab_1, (&tmp194)) ; /* tmp205 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynconset_foreach_main (arg1, &f_con_26, tmp204) ; // ATS_FREE(tmp204) ; tmp193 = tmp194 ; return (tmp193) ; } /* end of [_emit_dynconset_25] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 16221(line=625, offs=4) -- 16361(line=630, offs=47) */ ATSstaticdec() ats_int_type emit_dynconset_27 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp206) ; __ats_lab_emit_dynconset_27: tmp206 = _emit_dynconset_25 (arg0, arg1) ; return (tmp206) ; } /* end of [emit_dynconset_27] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 16459(line=639, offs=4) -- 16765(line=651, offs=4) */ ATSstaticdec() ats_void_type emit_d2cst_fun_class_28 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp207) ; ATSlocal (ats_bool_type, tmp208) ; __ats_lab_emit_d2cst_fun_class_28: tmp208 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta (arg1) ; if (tmp208) { /* tmp207 = */ atspre_fprint_string (arg0, ATSstrcst("ATSstatic_fun")) ; } else { /* tmp207 = */ atspre_fprint_string (arg0, ATSstrcst("ATSextern_fun")) ; } /* end of [if] */ return /* (tmp207) */ ; } /* end of [emit_d2cst_fun_class_28] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 16803(line=653, offs=4) -- 17087(line=666, offs=4) */ ATSstaticdec() ats_void_type emit_d2cst_val_class_29 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp209) ; ATSlocal (ats_bool_type, tmp210) ; __ats_lab_emit_d2cst_val_class_29: tmp210 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extsta (arg1) ; if (tmp210) { /* tmp209 = */ atspre_fprint_string (arg0, ATSstrcst("ATSstatic_val")) ; } else { /* tmp209 = */ atspre_fprint_string (arg0, ATSstrcst("ATSextern_val")) ; } /* end of [if] */ return /* (tmp209) */ ; } /* end of [emit_d2cst_val_class_29] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 17146(line=670, offs=4) -- 19783(line=778, offs=4) */ ATSstaticdec() ats_void_type emit_d2cst_dec_30 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_bool_type, tmp214) ; ATSlocal (ats_bool_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; // ATSlocal_void (tmp220) ; // ATSlocal_void (tmp221) ; // ATSlocal_void (tmp222) ; ATSlocal (ats_bool_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; // ATSlocal_void (tmp231) ; // ATSlocal_void (tmp232) ; ATSlocal (ats_bool_type, tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; __ats_lab_emit_d2cst_dec_30: tmp212 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some (arg1) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp212) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp214 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof (arg1) ; if (!tmp214) { goto __ats_lab_34_1 ; } break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: __ats_lab_34_1: tmp215 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_extmac (arg1) ; if (!tmp215) { goto __ats_lab_35_1 ; } break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: tmp216 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp213), atslab_hityp_node) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp216)->tag != 2) { goto __ats_lab_42_0 ; } __ats_lab_36_1: tmp217 = ats_caselptrlab_mac(anairiats_sum_6, tmp216, atslab_0) ; tmp218 = ats_caselptrlab_mac(anairiats_sum_6, tmp216, atslab_1) ; tmp219 = ats_caselptrlab_mac(anairiats_sum_6, tmp216, atslab_2) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp217 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: /* tmp220 = */ emit_d2cst_val_class_29 (arg0, arg1) ; /* tmp221 = */ atspre_fprint_string (arg0, ATSstrcst("(ats_ptr_type, ")) ; /* tmp222 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp211 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (tmp217 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp223 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (arg1) ; if (!tmp223) { goto __ats_lab_40_1 ; } tmp224 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode (tmp218) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp219) ; /* tmp226 = */ emit_d2cst_fun_class_28 (arg0, arg1) ; /* tmp227 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp225) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp231 = */ atspre_fprint_string (arg0, ATSstrcst(") (")) ; /* tmp232 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep (arg0, tmp224, ATSstrcst(", ")) ; /* tmp211 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp233 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn (arg1) ; if (!tmp233) { goto __ats_lab_41_1 ; } break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: /* tmp234 = */ emit_d2cst_val_class_29 (arg0, arg1) ; /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst("(ats_ptr_type, ")) ; /* tmp236 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp211 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: /* tmp237 = */ emit_d2cst_val_class_29 (arg0, arg1) ; /* tmp238 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp239 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp212) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp211 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp211) */ ; } /* end of [emit_d2cst_dec_30] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 19836(line=782, offs=4) -- 20581(line=815, offs=4) */ ATSstaticdec() ats_void_type emit_d2cst_dec_prfck_31 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_bool_type, tmp245) ; ATSlocal (ats_bool_type, tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; // ATSlocal_void (tmp249) ; // ATSlocal_void (tmp250) ; // ATSlocal_void (tmp251) ; ATSlocal (ats_bool_type, tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; __ats_lab_emit_d2cst_dec_prfck_31: tmp243 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some (arg1) ; tmp244 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp243) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp245 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi (arg1) ; if (!tmp245) { goto __ats_lab_44_1 ; } break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun (arg1) ; if (!tmp246) { goto __ats_lab_45_1 ; } /* tmp247 = */ atspre_fprint_string (arg0, ATSstrcst("extern\n")) ; /* tmp248 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; /* tmp249 = */ atspre_fprint_char (arg0, ' ') ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("_prfck (")) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp252 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval (arg1) ; if (!tmp252) { goto __ats_lab_46_1 ; } /* tmp253 = */ atspre_fprint_string (arg0, ATSstrcst("extern\n")) ; /* tmp254 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; /* tmp255 = */ atspre_fprint_char (arg0, ' ') ; /* tmp256 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, arg1) ; /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("_prfck (")) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: break ; } while (0) ; return /* (tmp242) */ ; } /* end of [emit_d2cst_dec_prfck_31] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 21094(line=836, offs=4) -- 21340(line=845, offs=4) */ ATSstaticdec() ats_void_type f_cst_33 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_int_type, tmp264) ; ATSlocal (ats_int_type, tmp265) ; __ats_lab_f_cst_33: // tmp261 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp262 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp263 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_2) ; tmp264 = ats_ptrget_mac(ats_int_type, tmp262) ; tmp265 = atspre_add_int_int (tmp264, 1) ; ats_ptrget_mac(ats_int_type, tmp262) = tmp265 ; /* tmp260 = */ ((ats_void_type(*)(ats_ref_type, ats_ptr_type))tmp263) (tmp261, arg0) ; return /* (tmp260) */ ; } /* end of [f_cst_33] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 21365(line=847, offs=4) -- 21525(line=853, offs=4) */ ATSstaticdec() ats_void_type f_cst_if_34 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; __ats_lab_f_cst_if_34: tmp267 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg (arg0) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp267 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp267 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: /* tmp266 = */ f_cst_33 (arg0, arg1) ; break ; } while (0) ; return /* (tmp266) */ ; } /* end of [f_cst_if_34] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 20634(line=819, offs=4) -- 21814(line=865, offs=4) */ ATSstaticdec() ats_int_type _emit_dyncstset_proc_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; ATSlocal (ats_ptr_type, tmp268) ; // ATSlocal_void (tmp269) ; __ats_lab__emit_dyncstset_proc_32: /* ats_int_type tmp259 ; */ tmp259 = 0 ; tmp268 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp268, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp268, atslab_1, (&tmp259)) ; ats_selptrset_mac(anairiats_sum_0, tmp268, atslab_2, arg2) ; /* tmp269 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main (arg1, &f_cst_if_34, tmp268) ; // ATS_FREE(tmp268) ; tmp258 = tmp259 ; return (tmp258) ; } /* end of [_emit_dyncstset_proc_32] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 21847(line=867, offs=4) -- 22008(line=871, offs=68) */ ATSstaticdec() ats_int_type emit_dyncstset_35 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp270) ; __ats_lab_emit_dyncstset_35: tmp270 = _emit_dyncstset_proc_32 (arg0, arg1, &emit_d2cst_dec_30) ; return (tmp270) ; } /* end of [emit_dyncstset_35] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 22040(line=874, offs=4) -- 22213(line=878, offs=74) */ ATSstaticdec() ats_int_type emit_dyncstset_prfck_36 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp271) ; __ats_lab_emit_dyncstset_prfck_36: tmp271 = _emit_dyncstset_proc_32 (arg0, arg1, &emit_d2cst_dec_prfck_31) ; return (tmp271) ; } /* end of [emit_dyncstset_prfck_36] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 22383(line=889, offs=5) -- 22750(line=907, offs=4) */ ATSstaticdec() ats_int_type aux_38 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; ATSlocal (ats_bool_type, tmp277) ; // ATSlocal_void (tmp278) ; ATSlocal (ats_int_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; __ats_lab_aux_38: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp274 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp275 = &ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp277 = atspre_gt_int_int (arg1, 0) ; if (tmp277) { /* tmp276 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp278 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr (arg0, tmp274) ; tmp279 = atspre_add_int_int (arg1, 1) ; tmp280 = ats_ptrget_mac(ats_ptr_type, tmp275) ; arg0 = arg0 ; arg1 = tmp279 ; arg2 = tmp280 ; goto __ats_lab_aux_38 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp273 = arg1 ; break ; } while (0) ; return (tmp273) ; } /* end of [aux_38] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 22272(line=883, offs=4) -- 22869(line=915, offs=4) */ ATSstaticdec() ats_void_type emit_instrlst_vt_37 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp272) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_bool_type, tmp282) ; __ats_lab_emit_instrlst_vt_37: tmp281 = aux_38 (arg0, 0, arg1) ; tmp282 = atspre_gt_int_int (tmp281, 0) ; if (tmp282) { /* tmp272 = */ atspre_fprint_newline (arg0) ; } else { /* empty */ } /* end of [if] */ return /* (tmp272) */ ; } /* end of [emit_instrlst_vt_37] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 22925(line=919, offs=5) -- 23743(line=950, offs=4) */ ATSstaticdec() ats_void_type emit_funentry_lablst_39 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; // ATSlocal_void (tmp288) ; ATSlocal (ats_bool_type, tmp289) ; // ATSlocal_void (tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; ATSlocal (ats_bool_type, tmp293) ; // ATSlocal_void (tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; __ats_lab_emit_funentry_lablst_39: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp284 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp285 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp286 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck (tmp284) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (tmp284) ; tmp289 = atspre_gt_int_int (tmp286, 0) ; if (tmp289) { /* tmp288 = */ atspre_fprint_string (arg0, ATSstrcst("#ifdef _ATS_PROOFCHECK\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp290 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry (arg0, tmp287) ; /* tmp291 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; tmp293 = atspre_gt_int_int (tmp286, 0) ; if (tmp293) { /* tmp292 = */ atspre_fprint_string (arg0, ATSstrcst("#endif /* _ATS_PROOFCHECK */\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp294 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; tmp295 = ats_ptrget_mac(ats_ptr_type, tmp285) ; arg0 = arg0 ; arg1 = tmp295 ; goto __ats_lab_emit_funentry_lablst_39 ; // tail call break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: break ; } while (0) ; return /* (tmp283) */ ; } /* end of [emit_funentry_lablst_39] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 23782(line=952, offs=5) -- 24234(line=969, offs=4) */ ATSstaticdec() ats_int_type emit_funentry_lablst_prototype_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; // ATSlocal_void (tmp300) ; ATSlocal (ats_int_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_emit_funentry_lablst_prototype_40: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp297 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp298 = &ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp299 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (tmp297) ; /* tmp300 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry_prototype (arg0, tmp299) ; tmp301 = atspre_add_int_int (arg1, 1) ; tmp302 = ats_ptrget_mac(ats_ptr_type, tmp298) ; arg0 = arg0 ; arg1 = tmp301 ; arg2 = tmp302 ; goto __ats_lab_emit_funentry_lablst_prototype_40 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp296 = arg1 ; break ; } while (0) ; return (tmp296) ; } /* end of [emit_funentry_lablst_prototype_40] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 24381(line=976, offs=5) -- 24670(line=991, offs=4) */ ATSstaticdec() ats_void_type aux_42 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; __ats_lab_aux_42: do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp306 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add (arg0, tmp305) ; tmp308 = ats_ptrget_mac(ats_ptr_type, tmp306) ; arg0 = arg0 ; arg1 = tmp308 ; goto __ats_lab_aux_42 ; // tail call break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: break ; } while (0) ; return /* (tmp304) */ ; } /* end of [aux_42] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 24304(line=973, offs=5) -- 24750(line=997, offs=4) */ ATSstaticdec() ats_ptr_type instrlst_vt_tmpvarmap_gen_41 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; __ats_lab_instrlst_vt_tmpvarmap_gen_41: /* ats_ptr_type tmp309 ; */ tmp309 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil () ; /* tmp310 = */ aux_42 ((&tmp309), arg0) ; tmp303 = tmp309 ; return (tmp303) ; } /* end of [instrlst_vt_tmpvarmap_gen_41] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 24924(line=1007, offs=5) -- 25300(line=1023, offs=4) */ ATSstaticdec() ats_int_type aux_44 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; // ATSlocal_void (tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_int_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_aux_44: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp313 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp314 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp315 = &ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_2) ; tmp317 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp314), atslab_valprim_typ) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp317) ; /* tmp318 = */ atspre_fprintf_exn (arg0, ATSstrcst(" %s ;\n"), tmp313) ; tmp319 = atspre_add_int_int (arg1, 1) ; tmp320 = ats_ptrget_mac(ats_ptr_type, tmp315) ; arg0 = arg0 ; arg1 = tmp319 ; arg2 = tmp320 ; goto __ats_lab_aux_44 ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: tmp312 = arg1 ; break ; } while (0) ; return (tmp312) ; } /* end of [aux_44] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 24814(line=1001, offs=4) -- 25347(line=1027, offs=4) */ ATSstaticdec() ats_int_type emit_extvalist_dec_43 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp311) ; __ats_lab_emit_extvalist_dec_43: tmp311 = aux_44 (arg0, 0, arg1) ; return (tmp311) ; } /* end of [emit_extvalist_dec_43] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 25498(line=1035, offs=5) -- 26033(line=1057, offs=4) */ ATSstaticdec() ats_int_type aux_46 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; __ats_lab_aux_46: do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp323 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp324 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp325 = &ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_2) ; /* tmp326 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_GC_MARKROOT (&")) ; /* tmp327 = */ atspre_fprint_string (arg0, tmp323) ; /* tmp328 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(")) ; tmp330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp324), atslab_valprim_typ) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp330) ; /* tmp331 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;\n")) ; tmp332 = atspre_add_int_int (arg1, 1) ; tmp333 = ats_ptrget_mac(ats_ptr_type, tmp325) ; arg0 = arg0 ; arg1 = tmp332 ; arg2 = tmp333 ; goto __ats_lab_aux_46 ; // tail call break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp322 = arg1 ; break ; } while (0) ; return (tmp322) ; } /* end of [aux_46] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 25383(line=1029, offs=4) -- 26080(line=1061, offs=4) */ ATSstaticdec() ats_int_type emit_extvalist_markroot_45 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp321) ; __ats_lab_emit_extvalist_markroot_45: tmp321 = aux_46 (arg0, 0, arg1) ; return (tmp321) ; } /* end of [emit_extvalist_markroot_45] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 26644(line=1085, offs=5) -- 27183(line=1107, offs=4) */ ATSstaticdec() ats_void_type aux_48 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; // ATSlocal_void (tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_int_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_bool_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; __ats_lab_aux_48: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_63_1: tmp344 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp345 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp347 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp344), atslab_d2ec_node) ; do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp347)->tag != 13) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_3, tmp347, atslab_0) ; tmp349 = ats_caselptrlab_mac(anairiats_sum_3, tmp347, atslab_1) ; tmp350 = atspre_gte_int_int (tmp348, 0) ; if (tmp350) { /* empty */ } else { /* tmp346 = */ atspre_fprint_string (arg0, tmp349) ; } /* end of [if] */ break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp347)->tag != 22) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_10, tmp347, atslab_1) ; /* tmp346 = */ emit_stafile_extcode_47 (arg0, tmp351) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: break ; } while (0) ; arg0 = arg0 ; arg1 = tmp345 ; goto __ats_lab_aux_48 ; // tail call break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: break ; } while (0) ; return /* (tmp343) */ ; } /* end of [aux_48] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 26143(line=1065, offs=5) -- 27227(line=1111, offs=4) */ ATSstaticdec() ats_void_type emit_stafile_extcode_47 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; __ats_lab_emit_stafile_extcode_47: tmp335 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (arg1) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find (tmp335) ; do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (tmp336 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_4, tmp336, atslab_0) ; ATS_FREE(tmp336) ; tmp337 = tmp338 ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (tmp336 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: /* tmp339 = */ prerr_interror_0 () ; /* tmp340 = */ atspre_prerr_string (ATSstrcst(": emit_stafile_extcode: fil = ")) ; /* tmp341 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (arg1) ; /* tmp342 = */ atspre_prerr_newline () ; /* tmp337 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp334 = */ aux_48 (arg0, tmp337) ; return /* (tmp334) */ ; } /* end of [emit_stafile_extcode_47] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 27266(line=1113, offs=5) -- 27654(line=1129, offs=4) */ ATSstaticdec() ats_void_type emit_stafilelst_extcode_49 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; // ATSlocal_void (tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; __ats_lab_emit_stafilelst_extcode_49: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp354 = &ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; /* tmp355 = */ emit_stafile_extcode_47 (arg0, tmp353) ; tmp356 = ats_ptrget_mac(ats_ptr_type, tmp354) ; arg0 = arg0 ; arg1 = tmp356 ; goto __ats_lab_emit_stafilelst_extcode_49 ; // tail call break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_69_1: break ; } while (0) ; return /* (tmp352) */ ; } /* end of [emit_stafilelst_extcode_49] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 27879(line=1143, offs=5) -- 28532(line=1167, offs=4) */ ATSstaticdec() ats_void_type aux_staload_dec_51 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_int_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; // ATSlocal_void (tmp362) ; ATSlocal (ats_bool_type, tmp363) ; // ATSlocal_void (tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_int_type, tmp368) ; ATSlocal (ats_bool_type, tmp369) ; __ats_lab_aux_staload_dec_51: do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp359 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp361 = &ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp363 = atspre_eq_int_int (tmp360, 0) ; if (tmp363) { /* tmp362 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; } else { /* empty */ } /* end of [if] */ /* tmp364 = */ atspre_fprint_string (arg0, ATSstrcst("extern ats_void_type ")) ; /* tmp365 = */ atsopt_emit_filename (arg0, tmp359) ; /* tmp366 = */ atspre_fprint_string (arg0, ATSstrcst("__staload (void) ;\n")) ; tmp367 = ats_ptrget_mac(ats_ptr_type, tmp361) ; tmp368 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp367 ; arg2 = tmp368 ; goto __ats_lab_aux_staload_dec_51 ; // tail call break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp369 = atspre_gt_int_int (arg2, 0) ; if (tmp369) { /* tmp358 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; return /* (tmp358) */ ; } /* end of [aux_staload_dec_51] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 28568(line=1169, offs=5) -- 29192(line=1194, offs=4) */ ATSstaticdec() ats_void_type aux_staload_app_52 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_int_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; // ATSlocal_void (tmp374) ; ATSlocal (ats_bool_type, tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_int_type, tmp379) ; ATSlocal (ats_bool_type, tmp380) ; __ats_lab_aux_staload_app_52: do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp373 = &ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp375 = atspre_eq_int_int (tmp372, 0) ; if (tmp375) { /* tmp374 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; } else { /* empty */ } /* end of [if] */ /* tmp376 = */ atsopt_emit_filename (arg0, tmp371) ; /* tmp377 = */ atspre_fprint_string (arg0, ATSstrcst("__staload () ;\n")) ; tmp378 = ats_ptrget_mac(ats_ptr_type, tmp373) ; tmp379 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp378 ; arg2 = tmp379 ; goto __ats_lab_aux_staload_app_52 ; // tail call break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: tmp380 = atspre_gt_int_int (arg2, 0) ; if (tmp380) { /* tmp370 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; return /* (tmp370) */ ; } /* end of [aux_staload_app_52] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 29305(line=1199, offs=7) -- 29882(line=1217, offs=6) */ ATSstaticdec() ats_void_type aux_conlst_54 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_bool_type, tmp386) ; ATSlocal (ats_int_type, tmp387) ; // ATSlocal_void (tmp388) ; ATSlocal (ats_int_type, tmp389) ; // ATSlocal_void (tmp390) ; __ats_lab_aux_conlst_54: do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp383 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp384 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp387 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (tmp383) ; tmp386 = atspre_gt_int_int (tmp387, 0) ; if (tmp386) { /* tmp385 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; } else { /* empty */ } /* end of [if] */ /* tmp388 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp383) ; tmp389 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (tmp383) ; /* tmp390 = */ atspre_fprintf_exn (arg0, ATSstrcst(".tag = %i ;\n"), tmp389) ; arg0 = arg0 ; arg1 = tmp384 ; goto __ats_lab_aux_conlst_54 ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: break ; } while (0) ; return /* (tmp382) */ ; } /* end of [aux_conlst_54] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 29911(line=1218, offs=6) -- 30064(line=1223, offs=4) */ ATSstaticdec() ats_void_type aux_cst_55 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; __ats_lab_aux_cst_55: tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst (arg1) ; do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (tmp392 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp393 = ats_caselptrlab_mac(anairiats_sum_4, tmp392, atslab_0) ; /* tmp391 = */ aux_conlst_54 (arg0, tmp393) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (tmp392 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: break ; } while (0) ; return /* (tmp391) */ ; } /* end of [aux_cst_55] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 30091(line=1224, offs=7) -- 30428(line=1237, offs=6) */ ATSstaticdec() ats_int_type aux_56 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; // ATSlocal_void (tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_int_type, tmp399) ; __ats_lab_aux_56: do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp395 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp396 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp397 = */ aux_cst_55 (arg0, tmp395) ; tmp398 = ats_ptrget_mac(ats_ptr_type, tmp396) ; tmp399 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp398 ; arg2 = tmp399 ; goto __ats_lab_aux_56 ; // tail call break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp394 = arg2 ; break ; } while (0) ; return (tmp394) ; } /* end of [aux_56] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 29228(line=1196, offs=5) -- 30472(line=1240, offs=4) */ ATSstaticdec() ats_int_type aux_staload_datcstlst_53 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp381) ; __ats_lab_aux_staload_datcstlst_53: tmp381 = aux_56 (arg0, arg1, 0) ; return (tmp381) ; } /* end of [aux_staload_datcstlst_53] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 30592(line=1246, offs=5) -- 31382(line=1274, offs=4) */ ATSstaticdec() ats_int_type aux_58 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; // ATSlocal_void (tmp404) ; // ATSlocal_void (tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_int_type, tmp411) ; __ats_lab_aux_58: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp402 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp403 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp402) ; /* tmp405 = */ atspre_fprint_string (arg0, ATSstrcst(".tag = ats_exception_con_tag_new () ;\n")) ; /* tmp406 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp402) ; /* tmp407 = */ atspre_fprint_string (arg0, ATSstrcst(".name = \"")) ; /* tmp408 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp402) ; /* tmp409 = */ atspre_fprint_string (arg0, ATSstrcst("\" ;\n")) ; tmp410 = ats_ptrget_mac(ats_ptr_type, tmp403) ; tmp411 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp410 ; arg2 = tmp411 ; goto __ats_lab_aux_58 ; // tail call break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_81_1: tmp401 = arg2 ; break ; } while (0) ; return (tmp401) ; } /* end of [aux_58] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 30514(line=1242, offs=5) -- 31429(line=1278, offs=4) */ ATSstaticdec() ats_int_type aux_staload_exnconlst_57 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp400) ; __ats_lab_aux_staload_exnconlst_57: tmp400 = aux_58 (arg0, arg1, 0) ; return (tmp400) ; } /* end of [aux_staload_exnconlst_57] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 27719(line=1133, offs=4) -- 32605(line=1315, offs=4) */ ATSstaticdec() ats_void_type emit_staload_50 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp357) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; // ATSlocal_void (tmp425) ; ATSlocal (ats_int_type, tmp426) ; ATSlocal (ats_int_type, tmp427) ; // ATSlocal_void (tmp428) ; __ats_lab_emit_staload_50: /* tmp412 = */ aux_staload_dec_51 (arg0, arg2, 0) ; /* tmp413 = */ atspre_fprint_string (arg0, ATSstrcst("ats_void_type\n")) ; /* tmp414 = */ atsopt_emit_filename (arg0, arg1) ; /* tmp415 = */ atspre_fprint_string (arg0, ATSstrcst("__staload () {\n")) ; /* tmp416 = */ atspre_fprint_string (arg0, ATSstrcst("static int ")) ; /* tmp417 = */ atsopt_emit_filename (arg0, arg1) ; /* tmp418 = */ atspre_fprint_string (arg0, ATSstrcst("__staload_flag = 0 ;\n")) ; /* tmp419 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp420 = */ atsopt_emit_filename (arg0, arg1) ; /* tmp421 = */ atspre_fprint_string (arg0, ATSstrcst("__staload_flag) return ;\n")) ; /* tmp422 = */ atsopt_emit_filename (arg0, arg1) ; /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst("__staload_flag = 1 ;\n\n")) ; /* tmp424 = */ aux_staload_app_52 (arg0, arg2, 0) ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free (arg2) ; tmp426 = aux_staload_datcstlst_53 (arg0, arg3) ; tmp427 = aux_staload_exnconlst_57 (arg0, arg4) ; /* tmp428 = */ atspre_fprint_string (arg0, ATSstrcst("return ;\n")) ; /* tmp357 = */ atspre_fprint_string (arg0, ATSstrcst("} /* staload function */\n\n")) ; return /* (tmp357) */ ; } /* end of [emit_staload_50] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 32962(line=1336, offs=7) -- 33810(line=1363, offs=6) */ ATSstaticdec() ats_void_type aux_dynload_dec_60 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; // ATSlocal_void (tmp434) ; // ATSlocal_void (tmp435) ; // ATSlocal_void (tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_int_type, tmp441) ; ATSlocal (ats_bool_type, tmp442) ; __ats_lab_aux_dynload_dec_60: do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp432 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp433 = &ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst("ats_int_type ")) ; /* tmp435 = */ atsopt_emit_filename (arg0, tmp432) ; /* tmp436 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload_flag = 0 ;\n")) ; /* tmp437 = */ atspre_fprint_string (arg0, ATSstrcst("extern ats_void_type ")) ; /* tmp438 = */ atsopt_emit_filename (arg0, tmp432) ; /* tmp439 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload (void) ;\n")) ; tmp440 = ats_ptrget_mac(ats_ptr_type, tmp433) ; tmp441 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp440 ; arg2 = tmp441 ; goto __ats_lab_aux_dynload_dec_60 ; // tail call break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_83_1: tmp442 = atspre_gt_int_int (arg2, 0) ; if (tmp442) { /* tmp431 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; return /* (tmp431) */ ; } /* end of [aux_dynload_dec_60] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 35093(line=1410, offs=8) -- 35731(line=1427, offs=8) */ ATSstaticdec() ats_void_type f_61 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp461) ; ATSlocal (ats_bool_type, tmp462) ; ATSlocal (ats_bool_type, tmp463) ; // ATSlocal_void (tmp464) ; ATSlocal (ats_bool_type, tmp465) ; // ATSlocal_void (tmp466) ; __ats_lab_f_61: do { /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp462 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_praxi (arg0) ; if (!tmp462) { goto __ats_lab_85_1 ; } break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp463 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prfun (arg0) ; if (!tmp463) { goto __ats_lab_86_1 ; } /* tmp464 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg1, arg0) ; /* tmp461 = */ atspre_fprint_string (arg1, ATSstrcst("_prfck () ;\n")) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp465 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_prval (arg0) ; if (!tmp465) { goto __ats_lab_87_1 ; } /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg1, arg0) ; /* tmp461 = */ atspre_fprint_string (arg1, ATSstrcst("_prfck () ;\n")) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: __ats_lab_87_1: break ; } while (0) ; return /* (tmp461) */ ; } /* end of [f_61] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 32656(line=1319, offs=4) -- 36946(line=1471, offs=4) */ ATSstaticdec() ats_void_type emit_dynload_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; // ATSlocal_void (tmp443) ; // ATSlocal_void (tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_bool_type, tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; ATSlocal (ats_bool_type, tmp455) ; // ATSlocal_void (tmp456) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; // ATSlocal_void (tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; // ATSlocal_void (tmp469) ; // ATSlocal_void (tmp470) ; ATSlocal (ats_int_type, tmp471) ; // ATSlocal_void (tmp472) ; ATSlocal (ats_int_type, tmp473) ; // ATSlocal_void (tmp474) ; // ATSlocal_void (tmp475) ; // ATSlocal_void (tmp476) ; // ATSlocal_void (tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_bool_type, tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; __ats_lab_emit_dynload_59: tmp430 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_get () ; /* tmp443 = */ aux_dynload_dec_60 (arg0, tmp430, 0) ; /* tmp444 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free (tmp430) ; /* tmp445 = */ atspre_fprint_string (arg0, ATSstrcst("// dynload flag declaration\n")) ; tmp447 = atspre_eq_int_int (arg1, 0) ; if (tmp447) { /* tmp446 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; } else { /* empty */ } /* end of [if] */ /* tmp448 = */ atspre_fprint_string (arg0, ATSstrcst("extern ats_int_type ")) ; /* tmp449 = */ atsopt_emit_filename (arg0, arg2) ; /* tmp450 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload_flag ;\n\n")) ; /* tmp451 = */ atspre_fprint_string (arg0, ATSstrcst("ats_void_type\n")) ; /* tmp452 = */ atsopt_emit_filename (arg0, arg2) ; /* tmp453 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload () {\n")) ; tmp455 = atspre_eq_int_int (arg1, 0) ; if (tmp455) { /* tmp454 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; } else { /* empty */ } /* end of [if] */ /* tmp456 = */ atsopt_emit_filename (arg0, arg2) ; /* tmp457 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload_flag = 1 ;\n")) ; /* tmp458 = */ atsopt_emit_filename (arg0, arg2) ; /* tmp459 = */ atspre_fprint_string (arg0, ATSstrcst("__staload () ;\n\n")) ; /* tmp460 = */ atspre_fprint_string (arg0, ATSstrcst("#ifdef _ATS_PROOFCHECK\n")) ; tmp468 = atsopt_the_dyncstset_get () ; /* tmp467 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main (tmp468, &f_61, arg0) ; /* tmp469 = */ atspre_fprint_string (arg0, ATSstrcst("#endif /* _ATS_PROOFCHECK */\n")) ; /* tmp470 = */ atspre_fprint_string (arg0, ATSstrcst("\n/* marking static variables for GC */\n")) ; tmp471 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_markroot (arg0, arg4) ; /* tmp472 = */ atspre_fprint_string (arg0, ATSstrcst("\n/* marking external values for GC */\n")) ; tmp473 = emit_extvalist_markroot_45 (arg0, arg5) ; /* tmp474 = */ atspre_fprint_string (arg0, ATSstrcst("\n/* code for dynamic loading */\n")) ; /* tmp475 = */ emit_instrlst_vt_37 (arg0, arg3) ; /* tmp476 = */ atspre_fprint_string (arg0, ATSstrcst("return ;\n")) ; /* tmp477 = */ atspre_fprint_string (arg0, ATSstrcst("} /* end of [dynload function] */\n\n")) ; tmp478 = atsopt_dynloadfun_name_get () ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: __ats_lab_88_1: tmp479 = atspre_stropt_is_some (tmp478) ; if (!tmp479) { goto __ats_lab_89_1 ; } /* tmp480 = */ atspre_fprintf_exn (arg0, ATSstrcst("ats_void_type %s () {\n"), ats_castfn_mac(ats_ptr_type, tmp478)) ; /* tmp481 = */ atsopt_emit_filename (arg0, arg2) ; /* tmp429 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload () ; return ;\n}\n\n")) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: break ; } while (0) ; return /* (tmp429) */ ; } /* end of [emit_dynload_59] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 37106(line=1480, offs=5) -- 37604(line=1499, offs=4) */ ATSstaticdec() ats_int_type aux_63 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_int_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; // ATSlocal_void (tmp491) ; // ATSlocal_void (tmp492) ; ATSlocal (ats_bool_type, tmp493) ; // ATSlocal_void (tmp494) ; ATSlocal (ats_int_type, tmp495) ; __ats_lab_aux_63: do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp486 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_2) ; ATS_FREE(arg2) ; tmp487 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp485) ; tmp488 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp487), atslab_hityp_name) ; tmp489 = ats_caselptrlab_mac(anairiats_sum_12, tmp488, atslab_0) ; tmp490 = ats_caselptrlab_mac(anairiats_sum_12, tmp488, atslab_1) ; /* tmp491 = */ atspre_fprintf_exn (arg0, ATSstrcst("typedef %s "), tmp490) ; tmp493 = atspre_gt_int_int (tmp489, 0) ; if (tmp493) { /* tmp492 = */ atspre_fprint_char (arg0, '*') ; } else { /* empty */ } /* end of [if] */ /* tmp494 = */ atspre_fprintf_exn (arg0, ATSstrcst("%s ;\n"), tmp484) ; tmp495 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp495 ; arg2 = tmp486 ; goto __ats_lab_aux_63 ; // tail call break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: tmp483 = arg1 ; break ; } while (0) ; return (tmp483) ; } /* end of [aux_63] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 36997(line=1475, offs=4) -- 37650(line=1503, offs=4) */ ATSstaticdec() ats_int_type emit_extypelst_free_62 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp482) ; __ats_lab_emit_extypelst_free_62: tmp482 = aux_63 (arg0, 0, arg1) ; return (tmp482) ; } /* end of [emit_extypelst_free_62] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 37856(line=1515, offs=4) -- 38016(line=1523, offs=4) */ ATSstaticdec() ats_bool_type test_65 (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp497) ; ATSlocal (ats_bool_type, tmp498) ; ATSlocal (ats_bool_type, tmp499) ; __ats_lab_test_65: tmp498 = atspre_eq_int_int (arg0, 0) ; if (tmp498) { tmp497 = atspre_lte_int_int (arg1, 0) ; } else { tmp499 = atspre_eq_int_int (arg0, 1) ; if (tmp499) { tmp497 = atspre_eq_int_int (arg1, 1) ; } else { tmp497 = ats_true_bool ; } /* end of [if] */ } /* end of [if] */ return (tmp497) ; } /* end of [test_65] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 38044(line=1525, offs=5) -- 38781(line=1559, offs=4) */ ATSstaticdec() ats_void_type aux_main_66 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_int_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_bool_type, tmp505) ; ATSlocal (ats_int_type, tmp506) ; // ATSlocal_void (tmp507) ; ATSlocal (ats_bool_type, tmp508) ; // ATSlocal_void (tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_int_type, tmp511) ; __ats_lab_aux_main_66: do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp501 = ats_caselptrlab_mac(anairiats_sum_13, ats_ptrget_mac(ats_ptr_type, arg2), atslab_0) ; tmp502 = ats_caselptrlab_mac(anairiats_sum_13, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; tmp503 = ats_caselptrlab_mac(anairiats_sum_13, ats_ptrget_mac(ats_ptr_type, arg2), atslab_2) ; tmp504 = &ats_caselptrlab_mac(anairiats_sum_13, ats_ptrget_mac(ats_ptr_type, arg2), atslab_3) ; tmp505 = test_65 (arg1, tmp502) ; if (tmp505) { tmp506 = atsopt_gline_flag_get () ; tmp508 = atspre_gte_int_int (tmp506, 1) ; if (tmp508) { /* tmp507 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma (arg0, tmp501) ; } else { /* empty */ } /* end of [if] */ /* tmp509 = */ atspre_fprint_string (arg0, tmp503) ; tmp510 = ats_ptrget_mac(ats_ptr_type, tmp504) ; ATS_FREE(ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp510 ; tmp511 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp511 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_aux_main_66 ; // tail call } else { arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp504 ; arg3 = arg3 ; goto __ats_lab_aux_main_66 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (ats_ptrget_mac(ats_ptr_type, arg2) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: break ; } while (0) ; return /* (tmp500) */ ; } /* end of [aux_main_66] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 37708(line=1507, offs=4) -- 38859(line=1565, offs=4) */ ATSstaticdec() ats_int_type emit_extcodelst_64 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp496) ; ATSlocal (ats_int_type, tmp512) ; // ATSlocal_void (tmp513) ; __ats_lab_emit_extcodelst_64: /* ats_int_type tmp512 ; */ tmp512 = 0 ; /* tmp513 = */ aux_main_66 (arg0, arg1, arg2, (&tmp512)) ; tmp496 = tmp512 ; return (tmp496) ; } /* end of [emit_extcodelst_64] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 38913(line=1569, offs=4) -- 39096(line=1574, offs=4) */ ATSstaticdec() ats_bool_type main_void_is_implemented_67 () { /* local vardec */ ATSlocal (ats_bool_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; __ats_lab_main_void_is_implemented_67: tmp515 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_void) ; tmp516 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find (tmp515) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (tmp516 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: ATS_FREE(tmp516) ; tmp514 = ats_true_bool ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: // if (tmp516 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_95_1: tmp514 = ats_false_bool ; break ; } while (0) ; return (tmp514) ; } /* end of [main_void_is_implemented_67] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 39138(line=1576, offs=4) -- 39331(line=1581, offs=4) */ ATSstaticdec() ats_bool_type main_argc_argv_is_implemented_68 () { /* local vardec */ ATSlocal (ats_bool_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; __ats_lab_main_argc_argv_is_implemented_68: tmp518 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_argc_argv) ; tmp519 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find (tmp518) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (tmp519 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: ATS_FREE(tmp519) ; tmp517 = ats_true_bool ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (tmp519 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp517 = ats_false_bool ; break ; } while (0) ; return (tmp517) ; } /* end of [main_argc_argv_is_implemented_68] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 39378(line=1583, offs=4) -- 39563(line=1588, offs=4) */ ATSstaticdec() ats_bool_type main_dummy_is_implemented_69 () { /* local vardec */ ATSlocal (ats_bool_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; __ats_lab_main_dummy_is_implemented_69: tmp521 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_dummy) ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find (tmp521) ; do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (tmp522 == (ats_sum_ptr_type)0) { goto __ats_lab_99_0 ; } __ats_lab_98_1: ATS_FREE(tmp522) ; tmp520 = ats_true_bool ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: // if (tmp522 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_99_1: tmp520 = ats_false_bool ; break ; } while (0) ; return (tmp520) ; } /* end of [main_dummy_is_implemented_69] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 39727(line=1597, offs=4) -- 40373(line=1615, offs=4) */ ATSstaticdec() ats_int_type mainatsknd_get_70 () { /* local vardec */ ATSlocal (ats_int_type, tmp523) ; ATSlocal (ats_bool_type, tmp524) ; ATSlocal (ats_bool_type, tmp525) ; ATSlocal (ats_bool_type, tmp526) ; // ATSlocal_void (tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; ATSlocal (ats_bool_type, tmp530) ; __ats_lab_mainatsknd_get_70: tmp524 = main_void_is_implemented_67 () ; tmp525 = main_argc_argv_is_implemented_68 () ; if (tmp524) { tmp526 = atspre_neg_bool (tmp525) ; if (tmp526) { tmp523 = 0 ; } else { /* tmp527 = */ atspre_prerr_string (ATSstrcst("error(ccomp)")) ; /* tmp528 = */ atspre_prerr_string (ATSstrcst(": it is not allowed to implement both [main_void] and [main_argc_argv]")) ; /* tmp529 = */ atspre_prerr_newline () ; /* tmp523 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ } else { if (tmp525) { tmp523 = 1 ; } else { tmp530 = main_dummy_is_implemented_69 () ; if (tmp530) { tmp523 = 2 ; } else { tmp523 = -1 ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return (tmp523) ; } /* end of [mainatsknd_get_70] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_main.dats: 40444(line=1621, offs=1) -- 48786(line=1937, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; // ATSlocal_void (tmp537) ; // ATSlocal_void (tmp538) ; // ATSlocal_void (tmp539) ; ATSlocal (ats_bool_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; // ATSlocal_void (tmp542) ; // ATSlocal_void (tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; // ATSlocal_void (tmp545) ; ATSlocal (ats_int_type, tmp546) ; // ATSlocal_void (tmp547) ; ATSlocal (ats_bool_type, tmp548) ; // ATSlocal_void (tmp549) ; ATSlocal (ats_int_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; // ATSlocal_void (tmp552) ; ATSlocal (ats_bool_type, tmp553) ; // ATSlocal_void (tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; ATSlocal (ats_int_type, tmp556) ; // ATSlocal_void (tmp557) ; ATSlocal (ats_bool_type, tmp558) ; // ATSlocal_void (tmp559) ; ATSlocal (ats_bool_type, tmp560) ; // ATSlocal_void (tmp561) ; ATSlocal (ats_int_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_bool_type, tmp564) ; // ATSlocal_void (tmp565) ; ATSlocal (ats_bool_type, tmp566) ; // ATSlocal_void (tmp567) ; ATSlocal (ats_int_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_bool_type, tmp570) ; // ATSlocal_void (tmp571) ; ATSlocal (ats_bool_type, tmp572) ; // ATSlocal_void (tmp573) ; // ATSlocal_void (tmp574) ; ATSlocal (ats_int_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; // ATSlocal_void (tmp577) ; ATSlocal (ats_bool_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; // ATSlocal_void (tmp580) ; ATSlocal (ats_int_type, tmp581) ; // ATSlocal_void (tmp582) ; ATSlocal (ats_bool_type, tmp583) ; // ATSlocal_void (tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; // ATSlocal_void (tmp586) ; ATSlocal (ats_int_type, tmp587) ; // ATSlocal_void (tmp588) ; ATSlocal (ats_bool_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; // ATSlocal_void (tmp591) ; ATSlocal (ats_int_type, tmp592) ; // ATSlocal_void (tmp593) ; ATSlocal (ats_bool_type, tmp594) ; // ATSlocal_void (tmp595) ; ATSlocal (ats_bool_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; // ATSlocal_void (tmp598) ; ATSlocal (ats_int_type, tmp599) ; ATSlocal (ats_bool_type, tmp600) ; // ATSlocal_void (tmp601) ; ATSlocal (ats_bool_type, tmp602) ; // ATSlocal_void (tmp603) ; ATSlocal (ats_int_type, tmp604) ; ATSlocal (ats_bool_type, tmp605) ; // ATSlocal_void (tmp606) ; ATSlocal (ats_bool_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; // ATSlocal_void (tmp609) ; ATSlocal (ats_int_type, tmp610) ; ATSlocal (ats_bool_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; // ATSlocal_void (tmp613) ; ATSlocal (ats_bool_type, tmp614) ; // ATSlocal_void (tmp615) ; ATSlocal (ats_int_type, tmp616) ; ATSlocal (ats_bool_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; ATSlocal (ats_bool_type, tmp620) ; // ATSlocal_void (tmp621) ; ATSlocal (ats_int_type, tmp622) ; ATSlocal (ats_bool_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_bool_type, tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; // ATSlocal_void (tmp628) ; // ATSlocal_void (tmp629) ; ATSlocal (ats_int_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_bool_type, tmp632) ; ATSlocal (ats_int_type, tmp633) ; ATSlocal (ats_bool_type, tmp634) ; // ATSlocal_void (tmp635) ; // ATSlocal_void (tmp636) ; // ATSlocal_void (tmp637) ; // ATSlocal_void (tmp638) ; // ATSlocal_void (tmp639) ; // ATSlocal_void (tmp640) ; ATSlocal (ats_bool_type, tmp641) ; // ATSlocal_void (tmp642) ; // ATSlocal_void (tmp643) ; // ATSlocal_void (tmp644) ; ATSlocal (ats_int_type, tmp645) ; // ATSlocal_void (tmp646) ; ATSlocal (ats_bool_type, tmp647) ; // ATSlocal_void (tmp648) ; ATSlocal (ats_int_type, tmp649) ; // ATSlocal_void (tmp650) ; ATSlocal (ats_bool_type, tmp651) ; // ATSlocal_void (tmp652) ; // ATSlocal_void (tmp653) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main: /* ats_ptr_type tmp532 ; */ tmp532 = (ats_sum_ptr_type)0 ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_declst ((&tmp532), arg3) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_free () ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lablst () ; tmp536 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp532) ; /* tmp537 = */ emit_time_stamp_1 (arg1) ; /* tmp538 = */ emit_include_header_2 (arg1) ; tmp540 = atspre_gt_int_int (arg0, 0) ; if (tmp540) { /* tmp539 = */ emit_include_cats_3 (arg1) ; } else { /* empty */ } /* end of [if] */ tmp541 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_get () ; /* tmp542 = */ atspre_fprint_string (arg1, ATSstrcst("/* prologues from statically loaded files */\n")) ; /* tmp543 = */ emit_stafilelst_extcode_49 (arg1, tmp541) ; /* ats_ptr_type tmp544 ; */ tmp544 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_get () ; /* tmp545 = */ atspre_fprint_string (arg1, ATSstrcst("/* external codes at top */\n")) ; tmp546 = emit_extcodelst_64 (arg1, 0, (&tmp544)) ; tmp548 = atspre_gt_int_int (tmp546, 0) ; if (tmp548) { /* tmp547 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp549 = */ atspre_fprint_string (arg1, ATSstrcst("/* type definitions */\n")) ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__typdeflst_get () ; tmp550 = emit_typdeflst_free_11 (arg1, tmp551) ; tmp553 = atspre_gt_int_int (tmp550, 0) ; if (tmp553) { /* tmp552 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp554 = */ atspre_fprint_string (arg1, ATSstrcst("/* external typedefs */\n")) ; tmp555 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_get () ; tmp556 = emit_extypelst_free_62 (arg1, tmp555) ; tmp558 = atspre_gt_int_int (tmp556, 0) ; if (tmp558) { /* tmp557 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ tmp560 = atspre_gt_int_int (arg0, 0) ; if (tmp560) { /* tmp561 = */ atspre_fprint_string (arg1, ATSstrcst("/* external dynamic constructor declarations */\n")) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_get () ; tmp562 = emit_dynconset_27 (arg1, tmp563) ; tmp564 = atspre_gt_int_int (tmp562, 0) ; if (tmp564) { /* tmp559 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp566 = atspre_gt_int_int (arg0, 0) ; if (tmp566) { /* tmp567 = */ atspre_fprint_string (arg1, ATSstrcst("/* external dynamic constant declarations */\n")) ; tmp569 = atsopt_the_dyncstset_get () ; tmp568 = emit_dyncstset_35 (arg1, tmp569) ; tmp570 = atspre_gt_int_int (tmp568, 0) ; if (tmp570) { /* tmp565 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp572 = atspre_gt_int_int (arg0, 0) ; if (tmp572) { /* tmp573 = */ atspre_fprint_string (arg1, ATSstrcst("/* external dynamic terminating constant declarations */\n")) ; /* tmp574 = */ atspre_fprint_string (arg1, ATSstrcst("#ifdef _ATS_PROOFCHECK\n")) ; tmp576 = atsopt_the_dyncstset_get () ; tmp575 = emit_dyncstset_prfck_36 (arg1, tmp576) ; tmp578 = atspre_eq_int_int (tmp575, 0) ; if (tmp578) { /* tmp577 = */ atspre_fprint_string (arg1, ATSstrcst("/* empty */\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp571 = */ atspre_fprint_string (arg1, ATSstrcst("#endif /* _ATS_PROOFCHECK */\n\n")) ; } else { /* empty */ } /* end of [if] */ tmp579 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_get () ; /* tmp580 = */ atspre_fprint_string (arg1, ATSstrcst("/* assuming abstract types */\n")) ; tmp581 = emit_saspcstlst_13 (arg1, tmp579) ; tmp583 = atspre_gt_int_int (tmp581, 0) ; if (tmp583) { /* tmp582 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp584 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__saspcstlst_free (tmp579) ; tmp585 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_get () ; /* tmp586 = */ atspre_fprint_string (arg1, ATSstrcst("/* sum constructor declarations */\n")) ; tmp587 = emit_datcstlst_15 (arg1, tmp585) ; tmp589 = atspre_gt_int_int (tmp587, 0) ; if (tmp589) { /* tmp588 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ tmp590 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_get () ; /* tmp591 = */ atspre_fprint_string (arg1, ATSstrcst("/* exn constructor declarations */\n")) ; tmp592 = emit_exnconlst_19 (arg1, tmp590) ; tmp594 = atspre_gt_int_int (tmp592, 0) ; if (tmp594) { /* tmp593 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ tmp596 = atspre_gt_int_int (arg0, 0) ; if (tmp596) { tmp597 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_get () ; /* tmp598 = */ atspre_fprint_string (arg1, ATSstrcst("/* global dynamic (non-functional) constant declarations */\n")) ; tmp599 = emit_free_glocstlst_21 (arg1, tmp597) ; tmp600 = atspre_gt_int_int (tmp599, 0) ; if (tmp600) { /* tmp595 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp602 = atspre_gt_int_int (arg0, 0) ; if (tmp602) { /* tmp603 = */ atspre_fprint_string (arg1, ATSstrcst("/* internal function declarations */\n")) ; tmp604 = emit_funentry_lablst_prototype_40 (arg1, 0, tmp535) ; tmp605 = atspre_gt_int_int (tmp604, 0) ; if (tmp605) { /* tmp601 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp607 = atspre_gt_int_int (arg0, 0) ; if (tmp607) { tmp608 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_get () ; /* tmp609 = */ atspre_fprint_string (arg1, ATSstrcst("/* partial value template declarations */\n")) ; tmp610 = emit_free_partvalst_23 (arg1, tmp608) ; tmp611 = atspre_gt_int_int (tmp610, 0) ; if (tmp611) { /* tmp606 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp612 = instrlst_vt_tmpvarmap_gen_41 (tmp536) ; tmp614 = atspre_gt_int_int (arg0, 0) ; if (tmp614) { /* tmp615 = */ atspre_fprint_string (arg1, ATSstrcst("/* static temporary variable declarations */\n")) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_static (arg1, tmp612) ; tmp617 = atspre_gt_int_int (tmp616, 0) ; if (tmp617) { /* tmp613 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp618 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_get () ; tmp620 = atspre_gt_int_int (arg0, 0) ; if (tmp620) { /* tmp621 = */ atspre_fprint_string (arg1, ATSstrcst("/* external value variable declarations */\n\n")) ; tmp622 = emit_extvalist_dec_43 (arg1, tmp618) ; tmp623 = atspre_gt_int_int (tmp622, 0) ; if (tmp623) { /* tmp619 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp625 = atspre_gt_int_int (arg0, 0) ; if (tmp625) { /* tmp626 = */ atspre_fprint_string (arg1, ATSstrcst("/* function implementations */\n\n")) ; /* tmp627 = */ emit_funentry_lablst_39 (arg1, tmp535) ; tmp624 = tmp535 ; } else { tmp624 = tmp535 ; } /* end of [if] */ /* tmp628 = */ atspre_fprint_string (arg1, ATSstrcst("/* static load function */\n\n")) ; /* tmp629 = */ emit_staload_50 (arg1, arg2, tmp541, tmp585, tmp590) ; tmp630 = mainatsknd_get_70 () ; tmp632 = atspre_gt_int_int (arg0, 0) ; if (tmp632) { tmp634 = atspre_gte_int_int (tmp630, 0) ; if (tmp634) { tmp633 = 0 ; } else { tmp633 = atsopt_dynloadflag_get () ; } /* end of [if] */ /* tmp635 = */ atspre_fprint_string (arg1, ATSstrcst("/* dynamic load function */\n\n")) ; /* tmp636 = */ emit_dynload_59 (arg1, tmp633, arg2, tmp536, tmp612, tmp618) ; tmp631 = tmp536 ; } else { tmp631 = tmp536 ; } /* end of [if] */ /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (tmp631) ; /* tmp638 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free (tmp612) ; /* tmp639 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free (tmp618) ; do { /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: tmp641 = atspre_gte_int_int (tmp630, 0) ; if (!tmp641) { goto __ats_lab_101_1 ; } /* tmp642 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_mainfun (arg1, arg2) ; /* tmp640 = */ atspre_fprint_char (arg1, '\n') ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: __ats_lab_101_1: break ; } while (0) ; /* tmp643 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (tmp624) ; /* tmp644 = */ atspre_fprint_string (arg1, ATSstrcst("/* external codes at mid */\n")) ; tmp645 = emit_extcodelst_64 (arg1, 1, (&tmp544)) ; tmp647 = atspre_gt_int_int (tmp645, 0) ; if (tmp647) { /* tmp646 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp648 = */ atspre_fprint_string (arg1, ATSstrcst("/* external codes at bot */\n")) ; tmp649 = emit_extcodelst_64 (arg1, 2, (&tmp544)) ; tmp651 = atspre_gt_int_int (tmp649, 0) ; if (tmp651) { /* tmp650 = */ atspre_fprint_char (arg1, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp652 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free (tmp585) ; /* tmp653 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free (tmp590) ; /* tmp531 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free (tmp544) ; return /* (tmp531) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV2con_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__ENV3con_0.tag = 0 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_main_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_map_lin_sats.c0000664000175000017500000000177612223166160021570 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_map_lin_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_stamp_sats.c0000664000175000017500000000223412223166160021263 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_stamp_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_pprint_dats.c0000664000175000017500000002231412223166160023103 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type _fpprint_s2exp_0 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_pprint.dats: 1683(line=46, offs=5) -- 2491(line=66, offs=4) */ ATSstaticdec() ats_void_type _fpprint_s2exp_0 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_bool_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; __ats_lab__fpprint_s2exp_0: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp1)->tag != 33) { goto __ats_lab_3_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp3 = atspre_gt_int_int (arg2, 0) ; if (!tmp3) { goto __ats_lab_3_1 ; } tmp4 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (tmp2) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp4 == (ats_sum_ptr_type)0) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_2, tmp4, atslab_0) ; tmp6 = atspre_sub_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp5 ; arg2 = tmp6 ; goto __ats_lab__fpprint_s2exp_0 ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: // if (tmp4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_2_1: /* tmp7 = */ atspre_fprint_string (arg0, ATSstrcst("S2EVar(")) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (arg0, tmp2) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp1)->tag != 33) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; /* tmp10 = */ atspre_fprint_string (arg0, ATSstrcst("S2EVar?(")) ; /* tmp11 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (arg0, tmp9) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp1)->tag != 34) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst("S2Evararg(")) ; /* tmp14 = */ _fpprint_s2exp_0 (arg0, tmp12, arg2) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, arg1) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [_fpprint_s2exp_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_pprint.dats: 2597(line=72, offs=25) -- 2863(line=78, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp: tmp16 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, arg0), atslab_1) ; /* tmp15 = */ _fpprint_s2exp_0 (tmp16, arg1, 99) ; return /* (tmp15) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_pprint.dats: 2902(line=80, offs=24) -- 2941(line=80, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprint_s2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprint_s2exp: /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp (stdout, arg0) ; return /* (tmp17) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprint_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_pprint.dats: 2965(line=81, offs=24) -- 3004(line=81, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp: /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp (stderr, arg0) ; return /* (tmp18) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_pprint_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_filename_dats.c0000664000175000017500000016272212223166160021711 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include // ATSinline() ats_bool_type atsopt_filename_isexi (ats_ptr_type name) { struct stat st ; return stat ((char*)name, &st) ? ats_false_bool : ats_true_bool ; } /* end of [atsopt_filename_isexi] */ // /* type definitions */ typedef struct { ats_ptr_type atslab_filename_part ; ats_ptr_type atslab_filename_full ; ats_ptr_type atslab_filename_full_sym ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isucc) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_sub_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_lt_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_lt_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_lte_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_gt_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_gte_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, atspre_compare_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_string_make_substring) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_stringlst_concat) (ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_val(ats_ptr_type, atspre_stropt_none) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_empty) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_STDIN) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_char_type, atsopt_filename_theDirsep_get) () ; ATSextern_fun(ats_ptr_type, atsopt_filename_theCurdir_get) () ; ATSextern_fun(ats_ptr_type, atsopt_filename_thePredir_get) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; ATSextern_fun(ats_bool_type, atsopt_filename_isexi) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_merge) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__eq_filename_filename) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__neq_filename_filename) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_filename_fprint_filename_base) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atslib_getcwd0) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_fun_coerce) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__sasp__filename_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_bool_type aux_5 (ats_ptr_type arg0, ats_size_type arg1, ats_char_type arg2) ; static ats_void_type loop1_19 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ref_type arg4) ; static ats_void_type loop2_20 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ref_type arg5) ; static ats_ptr_type loop_22 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type dirs_process_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type list_vt_free_01906_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type ref_make_elt_01875_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type the_pathlst_get_25 () ; static ats_void_type the_pathlst_reset_26 () ; static ats_ptr_type the_prepathlst_get_29 () ; static ats_void_type the_filename_reset_31 () ; static ats_void_type the_filenamelst_reset_32 () ; static ats_void_type __ats_fun_34 () ; static ats_bool_type loop1_38 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop2_39 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type partname_fullize_45 (ats_ptr_type arg0) ; static ats_ptr_type aux_try_47 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_try_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_relative_49 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp10) ; ATSstatic (ats_ptr_type, statmp91) ; ATSstatic (ats_ptr_type, statmp94) ; ATSstatic (ats_ptr_type, statmp95) ; ATSstatic (ats_ptr_type, statmp96) ; ATSstatic (ats_ptr_type, statmp97) ; ATSstatic (ats_ptr_type, statmp120) ; ATSstatic (ats_ptr_type, statmp121) ; ATSstatic (ats_ptr_type, statmp122) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2106(line=69, offs=4) -- 2163(line=69, offs=61) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_filename)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2496(line=92, offs=25) -- 2510(line=92, offs=39) */ ATSglobaldec() ats_char_type atsopt_filename_theDirsep_get () { /* local vardec */ ATSlocal (ats_char_type, tmp1) ; __ats_lab_atsopt_filename_theDirsep_get: tmp1 = '/' ; return (tmp1) ; } /* end of [atsopt_filename_theDirsep_get] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2535(line=93, offs=25) -- 2549(line=93, offs=39) */ ATSglobaldec() ats_ptr_type atsopt_filename_theCurdir_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_atsopt_filename_theCurdir_get: tmp2 = ATSstrcst("./") ; return (tmp2) ; } /* end of [atsopt_filename_theCurdir_get] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2574(line=94, offs=25) -- 2588(line=94, offs=39) */ ATSglobaldec() ats_ptr_type atsopt_filename_thePredir_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_atsopt_filename_thePredir_get: tmp3 = ATSstrcst("../") ; return (tmp3) ; } /* end of [atsopt_filename_thePredir_get] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2765(line=106, offs=6) -- 2909(line=108, offs=66) */ ATSstaticdec() ats_bool_type aux_5 (ats_ptr_type arg0, ats_size_type arg1, ats_char_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_char_type, tmp7) ; __ats_lab_aux_5: tmp6 = atspre_string_is_atend (arg0, arg1) ; if (tmp6) { tmp5 = ats_true_bool ; } else { tmp7 = atspre_string_get_char_at (arg0, arg1) ; tmp5 = atspre_neq_char_char (tmp7, arg2) ; } /* end of [if] */ return (tmp5) ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 2709(line=104, offs=3) -- 2990(line=113, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp4) ; ATSlocal (ats_char_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative: tmp8 = atsopt_filename_theDirsep_get () ; tmp4 = aux_5 (ats_castfn_mac(ats_ptr_type, arg0), 0, tmp8) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 4969(line=209, offs=3) -- 5015(line=209, offs=49) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lt_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lt_filename_filename: tmp12 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; tmp11 = atspre_lt_string_string (tmp12, tmp13) ; return (tmp11) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lt_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5084(line=213, offs=3) -- 5131(line=213, offs=50) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lte_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lte_filename_filename: tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; tmp16 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; tmp14 = atspre_lte_string_string (tmp15, tmp16) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__lte_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5200(line=217, offs=3) -- 5246(line=217, offs=49) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gt_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gt_filename_filename: tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; tmp19 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; tmp17 = atspre_gt_string_string (tmp18, tmp19) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gt_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5315(line=221, offs=3) -- 5362(line=221, offs=50) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gte_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gte_filename_filename: tmp21 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; tmp22 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; tmp20 = atspre_gte_string_string (tmp21, tmp22) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__gte_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5452(line=225, offs=3) -- 5506(line=225, offs=57) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__eq_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__eq_filename_filename: tmp24 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full_sym) ; tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full_sym) ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp24, tmp25) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__eq_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5596(line=229, offs=3) -- 5651(line=229, offs=58) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__neq_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__neq_filename_filename: tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full_sym) ; tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full_sym) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol (tmp27, tmp28) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__neq_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5723(line=232, offs=37) -- 5780(line=233, offs=47) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__compare_filename_filename (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__compare_filename_filename: tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; tmp31 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; tmp29 = atspre_compare_string_string (tmp30, tmp31) ; return (tmp29) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__compare_filename_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5867(line=239, offs=17) -- 5926(line=240, offs=44) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename: tmp33 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename_full) ; /* tmp32 = */ atspre_fprint_string (arg0, tmp33) ; return /* (tmp32) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 5981(line=243, offs=26) -- 6017(line=243, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename: tmp35 = atspre_stdout_get () ; tmp36 = ats_selsin_mac(tmp35, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (tmp36, arg0) ; /* tmp34 = */ atspre_stdout_view_set () ; return /* (tmp34) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6043(line=244, offs=26) -- 6079(line=244, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename: tmp39 = atspre_stderr_get () ; tmp40 = ats_selsin_mac(tmp39, atslab_1) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (tmp40, arg0) ; /* tmp38 = */ atspre_stderr_view_set () ; return /* (tmp38) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6206(line=252, offs=31) -- 6247(line=252, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename_base (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename_base: tmp43 = atspre_stdout_get () ; tmp44 = ats_selsin_mac(tmp43, atslab_1) ; /* tmp45 = */ atsopt_filename_fprint_filename_base (tmp44, arg0) ; /* tmp42 = */ atspre_stdout_view_set () ; return /* (tmp42) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__print_filename_base] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6278(line=253, offs=31) -- 6319(line=253, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename_base (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename_base: tmp47 = atspre_stderr_get () ; tmp48 = ats_selsin_mac(tmp47, atslab_1) ; /* tmp49 = */ atsopt_filename_fprint_filename_base (tmp48, arg0) ; /* tmp46 = */ atspre_stderr_view_set () ; return /* (tmp46) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename_base] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6473(line=266, offs=7) -- 6669(line=270, offs=65) */ ATSstaticdec() ats_void_type loop1_19 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (ats_bool_type, tmp52) ; __ats_lab_loop1_19: tmp52 = atspre_lt_size1_size1 (arg3, arg2) ; if (tmp52) { /* tmp51 = */ loop2_20 (arg0, arg1, arg2, arg3, arg3, arg4) ; } else { /* empty */ } /* end of [if] */ return /* (tmp51) */ ; } /* end of [loop1_19] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6676(line=271, offs=7) -- 7681(line=303, offs=8) */ ATSstaticdec() ats_void_type loop2_20 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3, ats_size_type arg4, ats_ref_type arg5) { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_char_type, tmp56) ; ATSlocal (ats_size_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_size_type, tmp59) ; ATSlocal (ats_size_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_size_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_size_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_loop2_20: tmp54 = atspre_lt_size1_size1 (arg4, arg2) ; if (tmp54) { tmp56 = atspre_string_get_char_at (arg1, arg4) ; tmp55 = atspre_neq_char_char (tmp56, arg0) ; if (tmp55) { tmp57 = atspre_add_size1_int1 (arg4, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp57 ; arg5 = arg5 ; goto __ats_lab_loop2_20 ; // tail call } else { tmp60 = atspre_sub_size1_size1 (arg4, arg3) ; tmp59 = atspre_add_size1_int1 (tmp60, 1) ; tmp58 = atspre_string_make_substring (arg1, arg3, tmp59) ; tmp61 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp61, atslab_0, ats_castfn_mac(ats_ptr_type, tmp58)) ; ats_selptrset_mac(anairiats_sum_1, tmp61, atslab_1, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp61 ; tmp62 = atspre_add_size1_int1 (arg4, 1) ; /* tmp53 = */ loop1_19 (arg0, arg1, arg2, tmp62, arg5) ; } /* end of [if] */ } else { tmp64 = atspre_sub_size1_size1 (arg4, arg3) ; tmp63 = atspre_string_make_substring (arg1, arg3, tmp64) ; tmp65 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp65, atslab_0, ats_castfn_mac(ats_ptr_type, tmp63)) ; ats_selptrset_mac(anairiats_sum_1, tmp65, atslab_1, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp65 ; } /* end of [if] */ return /* (tmp53) */ ; } /* end of [loop2_20] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 8490(line=323, offs=13) -- 8684(line=327, offs=19) */ ATSstaticdec() ats_ptr_type loop_22 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_bool_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_loop_22: tmp76 = atspre_igt (arg1, 0) ; if (tmp76) { tmp77 = atspre_isub (arg1, 1) ; tmp78 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp78, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp78, atslab_1, arg2) ; arg0 = arg0 ; arg1 = tmp77 ; arg2 = tmp78 ; goto __ats_lab_loop_22 ; // tail call } else { tmp75 = arg2 ; } /* end of [if] */ return (tmp75) ; } /* end of [loop_22] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 7735(line=305, offs=7) -- 8717(line=329, offs=8) */ ATSstaticdec() ats_ptr_type dirs_process_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_bool_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_bool_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_dirs_process_21: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; ATS_FREE(arg3) ; tmp69 = atspre_eq_string_string (tmp67, arg0) ; if (tmp69) { arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp68 ; arg4 = arg4 ; goto __ats_lab_dirs_process_21 ; // tail call } else { tmp70 = atspre_eq_string_string (tmp67, arg1) ; if (tmp70) { tmp71 = atspre_iadd (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp71 ; arg3 = tmp68 ; arg4 = arg4 ; goto __ats_lab_dirs_process_21 ; // tail call } else { tmp72 = atspre_igt (arg2, 0) ; if (tmp72) { tmp73 = atspre_isub (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp73 ; arg3 = tmp68 ; arg4 = arg4 ; goto __ats_lab_dirs_process_21 ; // tail call } else { tmp74 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp74, atslab_0, tmp67) ; ats_selptrset_mac(anairiats_sum_1, tmp74, atslab_1, arg4) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = 0 ; arg3 = tmp68 ; arg4 = tmp74 ; goto __ats_lab_dirs_process_21 ; // tail call } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp66 = loop_22 (arg1, arg2, arg4) ; break ; } while (0) ; return (tmp66) ; } /* end of [dirs_process_21] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7914(line=306, offs=27) -- 8015(line=310, offs=4) */ ATSstaticdec() ats_void_type list_vt_free_01906_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_list_vt_free_01906_ats_ptr_type: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp90 ; goto __ats_lab_list_vt_free_01906_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp89) */ ; } /* end of [list_vt_free_01906_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 6456(line=265, offs=16) -- 9271(line=346, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_char_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_size_type, tmp83) ; // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize: tmp79 = atsopt_filename_theDirsep_get () ; tmp80 = atsopt_filename_theCurdir_get () ; tmp81 = atsopt_filename_thePredir_get () ; /* ats_ptr_type tmp82 ; */ tmp82 = (ats_sum_ptr_type)0 ; tmp83 = atspre_string_length (ats_castfn_mac(ats_ptr_type, arg0)) ; /* tmp84 = */ loop1_19 (tmp79, ats_castfn_mac(ats_ptr_type, arg0), tmp83, 0, (&tmp82)) ; tmp86 = (ats_sum_ptr_type)0 ; tmp85 = dirs_process_21 (tmp80, tmp81, 0, tmp82, tmp86) ; tmp82 = tmp85 ; tmp87 = atspre_stringlst_concat (ats_castfn_mac(ats_ptr_type, tmp82)) ; /* tmp88 = */ list_vt_free_01906_ats_ptr_type (tmp82) ; tmp50 = ats_castfn_mac(ats_ptr_type, tmp87) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01875_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_ref_make_elt_01875_ats_ptr_type: /* ats_ptr_type tmp93 ; */ tmp93 = arg0 ; tmp92 = atspre_ref_make_elt_tsz ((&tmp93), sizeof(ats_ptr_type)) ; return (tmp92) ; } /* end of [ref_make_elt_01875_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 9558(line=362, offs=5) -- 9600(line=362, offs=47) */ ATSstaticdec() ats_ptr_type the_pathlst_get_25 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_the_pathlst_get_25: tmp98 = ats_ptrget_mac(ats_ptr_type, statmp94) ; return (tmp98) ; } /* end of [the_pathlst_get_25] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 9605(line=363, offs=5) -- 9661(line=363, offs=61) */ ATSstaticdec() ats_void_type the_pathlst_reset_26 () { /* local vardec */ // ATSlocal_void (tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_the_pathlst_reset_26: tmp100 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp94) = tmp100 ; return /* (tmp99) */ ; } /* end of [the_pathlst_reset_26] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 9689(line=366, offs=17) -- 9937(line=374, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_pop () { /* local vardec */ // ATSlocal_void (tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_pop: tmp102 = ats_ptrget_mac(ats_ptr_type, statmp94) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp102 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_1, tmp102, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp94) = tmp103 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp102 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: /* tmp104 = */ prerr_interror_0 () ; /* tmp105 = */ atspre_prerr_string (ATSstrcst(": pathlst_pop: the_pathlst is empty.")) ; /* tmp106 = */ atspre_prerr_newline () ; /* tmp101 = */ ats_exit (1) ; break ; } while (0) ; return /* (tmp101) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 9996(line=378, offs=3) -- 10466(line=398, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_push: tmp109 = ats_ptrget_mac(ats_ptr_type, statmp94) ; tmp108 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp108, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp108, atslab_1, tmp109) ; ats_ptrget_mac(ats_ptr_type, statmp94) = tmp108 ; return /* (tmp107) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_push] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 10522(line=402, offs=5) -- 10570(line=402, offs=53) */ ATSstaticdec() ats_ptr_type the_prepathlst_get_29 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_the_prepathlst_get_29: tmp110 = ats_ptrget_mac(ats_ptr_type, statmp96) ; return (tmp110) ; } /* end of [the_prepathlst_get_29] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 10602(line=405, offs=21) -- 10935(line=414, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_prepathlst_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_bool_type, tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_prepathlst_push: tmp113 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative (arg0) ; if (tmp113) { /* tmp114 = */ prerr_interror_0 () ; /* tmp115 = */ atspre_prerr_string (ATSstrcst(": the_prepathlst_push: dirname = ")) ; /* tmp116 = */ atspre_prerr_string (arg0) ; /* tmp117 = */ atspre_prerr_newline () ; /* tmp112 = */ ats_exit (1) ; } else { /* empty */ } /* end of [if] */ tmp119 = ats_ptrget_mac(ats_ptr_type, statmp96) ; tmp118 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp118, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp118, atslab_1, tmp119) ; ats_ptrget_mac(ats_ptr_type, statmp96) = tmp118 ; return /* (tmp111) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_prepathlst_push] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11201(line=429, offs=4) -- 11262(line=429, offs=65) */ ATSstaticdec() ats_void_type the_filename_reset_31 () { /* local vardec */ // ATSlocal_void (tmp123) ; __ats_lab_the_filename_reset_31: ats_ptrget_mac(ats_ptr_type, statmp120) = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy ; return /* (tmp123) */ ; } /* end of [the_filename_reset_31] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11266(line=430, offs=4) -- 11330(line=430, offs=68) */ ATSstaticdec() ats_void_type the_filenamelst_reset_32 () { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_the_filenamelst_reset_32: tmp125 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp121) = tmp125 ; return /* (tmp124) */ ; } /* end of [the_filenamelst_reset_32] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11359(line=432, offs=28) -- 11387(line=432, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get: tmp126 = ats_ptrget_mac(ats_ptr_type, statmp120) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11419(line=434, offs=31) -- 11554(line=438, offs=4) */ ATSstaticdec() ats_void_type __ats_fun_34 () { /* local vardec */ // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; __ats_lab___ats_fun_34: /* tmp128 = */ prerr_interror_0 () ; /* tmp129 = */ atspre_prerr_string (ATSstrcst(": the_filenamelst_pop: the_filenamelst is empty")) ; /* tmp130 = */ atspre_prerr_newline () ; /* tmp127 = */ ats_exit (1) ; return /* (tmp127) */ ; } /* end of [__ats_fun_34] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11622(line=441, offs=21) -- 11820(line=447, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop () { /* local vardec */ // ATSlocal_void (tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop: tmp132 = ats_ptrget_mac(ats_ptr_type, statmp121) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp132 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_1, tmp132, atslab_0) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_1, tmp132, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp120) = tmp133 ; ats_ptrget_mac(ats_ptr_type, statmp121) = tmp134 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp132 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp131 = */ __ats_fun_34 () ; break ; } while (0) ; return /* (tmp131) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 11885(line=449, offs=32) -- 12117(line=458, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push: tmp137 = ats_ptrget_mac(ats_ptr_type, statmp120) ; tmp138 = ats_ptrget_mac(ats_ptr_type, statmp121) ; tmp136 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp136, atslab_0, tmp137) ; ats_selptrset_mac(anairiats_sum_1, tmp136, atslab_1, tmp138) ; ats_ptrget_mac(ats_ptr_type, statmp121) = tmp136 ; ats_ptrget_mac(ats_ptr_type, statmp120) = arg0 ; return /* (tmp135) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 12532(line=472, offs=9) -- 12693(line=475, offs=29) */ ATSstaticdec() ats_bool_type loop1_38 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_bool_type, tmp146) ; __ats_lab_loop1_38: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__eq_filename_filename (tmp144, arg1) ; if (tmp146) { tmp143 = ats_true_bool ; } else { arg0 = tmp145 ; arg1 = arg1 ; goto __ats_lab_loop1_38 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp143 = ats_false_bool ; break ; } while (0) ; return (tmp143) ; } /* end of [loop1_38] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13059(line=485, offs=11) -- 13297(line=490, offs=28) */ ATSstaticdec() ats_void_type loop2_39 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_bool_type, tmp158) ; __ats_lab_loop2_39: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp156 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp157 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (tmp155) ; tmp158 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__neq_filename_filename (tmp155, arg1) ; if (tmp158) { arg0 = tmp156 ; arg1 = arg1 ; goto __ats_lab_loop2_39 ; // tail call } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: break ; } while (0) ; return /* (tmp154) */ ; } /* end of [loop2_39] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 12187(line=461, offs=26) -- 13465(line=498, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push_xit (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_bool_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push_xit: tmp141 = ats_ptrget_mac(ats_ptr_type, statmp120) ; tmp142 = ats_ptrget_mac(ats_ptr_type, statmp121) ; tmp140 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp140, atslab_0, tmp141) ; ats_selptrset_mac(anairiats_sum_1, tmp140, atslab_1, tmp142) ; tmp147 = loop1_38 (tmp140, arg1) ; if (tmp147) { /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (ats_castfn_mac(ats_ptr_type, arg0)) ; /* tmp150 = */ atspre_prerr_string (ATSstrcst(": error(0)")) ; /* tmp151 = */ atspre_prerr_string (ATSstrcst(": loading or including the file [")) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (arg1) ; /* tmp153 = */ atspre_prerr_string (ATSstrcst("] generates a looping trace that is given as follows:\n")) ; /* tmp159 = */ loop2_39 (tmp140, arg1) ; /* tmp160 = */ atspre_prerr_newline () ; /* tmp148 = */ ats_exit (1) ; } else { /* empty */ } /* end of [if] */ ats_ptrget_mac(ats_ptr_type, statmp121) = tmp140 ; ats_ptrget_mac(ats_ptr_type, statmp120) = arg1 ; return /* (tmp139) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push_xit] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13572(line=504, offs=25) -- 13593(line=504, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part: tmp161 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_part) ; return (tmp161) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13618(line=505, offs=25) -- 13639(line=505, offs=46) */ ATSglobaldec() ats_ptr_type atsopt_filename_full (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_atsopt_filename_full: tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full) ; return (tmp162) ; } /* end of [atsopt_filename_full] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13668(line=506, offs=29) -- 13693(line=506, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym: tmp163 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename_full_sym) ; return (tmp163) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13747(line=512, offs=3) -- 13791(line=512, offs=47) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full: tmp164 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull (arg0, arg0) ; return (tmp164) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 13859(line=517, offs=3) -- 14019(line=523, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull: tmp166 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg1) ; tmp165 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp165, atslab_filename_part, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp165, atslab_filename_full, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp165, atslab_filename_full_sym, tmp166) ; return (tmp165) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 14081(line=527, offs=5) -- 14374(line=539, offs=4) */ ATSstaticdec() ats_ptr_type partname_fullize_45 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_bool_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_partname_fullize_45: tmp168 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative (arg0) ; if (tmp168) { tmp169 = atslib_getcwd0 () ; tmp170 = atsopt_filename_append (tmp169, arg0) ; tmp167 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize (tmp170) ; } else { tmp167 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize (arg0) ; } /* end of [if] */ return (tmp167) ; } /* end of [partname_fullize_45] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 14518(line=547, offs=7) -- 14687(line=553, offs=33) */ ATSstaticdec() ats_ptr_type aux_try_47 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_aux_try_47: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp174 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp172 = aux2_try_48 (tmp173, tmp174, arg1) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp172 = atspre_stropt_none ; break ; } while (0) ; return (tmp172) ; } /* end of [aux_try_47] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 14716(line=555, offs=7) -- 15163(line=570, offs=6) */ ATSstaticdec() ats_ptr_type aux2_try_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_bool_type, tmp177) ; __ats_lab_aux2_try_48: tmp176 = atsopt_filename_append (arg0, arg2) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp177 = atsopt_filename_isexi (tmp176) ; if (!tmp177) { goto __ats_lab_15_1 ; } tmp175 = ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp176)) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: tmp175 = aux_try_47 (arg1, arg2) ; break ; } while (0) ; return (tmp175) ; } /* end of [aux2_try_48] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 15194(line=572, offs=7) -- 15871(line=592, offs=6) */ ATSstaticdec() ats_ptr_type aux_relative_49 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_bool_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_bool_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; __ats_lab_aux_relative_49: tmp179 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp180 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part (tmp179) ; tmp181 = atsopt_filename_merge (tmp180, arg0) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp182 = atsopt_filename_isexi (tmp181) ; if (!tmp182) { goto __ats_lab_17_1 ; } tmp178 = ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp181)) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp184 = the_pathlst_get_25 () ; tmp183 = aux_try_47 (tmp184, arg0) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp185 = atspre_stropt_is_some (tmp183) ; if (!tmp185) { goto __ats_lab_19_1 ; } tmp178 = tmp183 ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp186 = the_prepathlst_get_29 () ; tmp178 = aux_try_47 (tmp186, arg0) ; break ; } while (0) ; break ; } while (0) ; return (tmp178) ; } /* end of [aux_relative_49] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 14443(line=543, offs=3) -- 16406(line=609, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_bool_type, tmp188) ; ATSlocal (ats_bool_type, tmp189) ; ATSlocal (ats_bool_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp188 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_is_relative (ats_castfn_mac(ats_ptr_type, arg0)) ; if (!tmp188) { goto __ats_lab_21_1 ; } tmp187 = aux_relative_49 (ats_castfn_mac(ats_ptr_type, arg0)) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp189 = atsopt_filename_isexi (ats_castfn_mac(ats_ptr_type, arg0)) ; if (tmp189) { tmp187 = ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, arg0)) ; } else { tmp187 = atspre_stropt_none ; } /* end of [if] */ break ; } while (0) ; tmp190 = atspre_stropt_is_some (tmp187) ; if (tmp190) { tmp191 = partname_fullize_45 (ats_castfn_mac(ats_ptr_type, tmp187)) ; tmp192 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_partfull (ats_castfn_mac(ats_ptr_type, tmp187), tmp191) ; tmp171 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp171, atslab_0, tmp192) ; } else { tmp171 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp171) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 16499(line=614, offs=23) -- 16541(line=615, offs=38) */ ATSglobaldec() ats_void_type atsopt_filename_prerr () { /* local vardec */ // ATSlocal_void (tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_atsopt_filename_prerr: tmp194 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; /* tmp193 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (tmp194) ; return /* (tmp193) */ ; } /* end of [atsopt_filename_prerr] */ /* // /home/hwxi/research/Anairiats/src/ats_filename.dats: 16615(line=619, offs=28) -- 16701(line=621, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__atsopt_filename_initialize () { /* local vardec */ // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__atsopt_filename_initialize: /* tmp196 = */ the_pathlst_reset_26 () ; /* tmp197 = */ the_filename_reset_31 () ; /* tmp195 = */ the_filenamelst_reset_32 () ; return /* (tmp195) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__atsopt_filename_initialize] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp10, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp91, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp94, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp95, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp96, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp97, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp120, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp121, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp122, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp9 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, statmp9, atslab_filename_part, ATSstrcst("")) ; ats_selptrset_mac(anairiats_rec_0, statmp9, atslab_filename_full, ATSstrcst("")) ; ats_selptrset_mac(anairiats_rec_0, statmp9, atslab_filename_full_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_empty) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy = statmp9 ; statmp10 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, statmp10, atslab_filename_part, ATSstrcst("stdin")) ; ats_selptrset_mac(anairiats_rec_0, statmp10, atslab_filename_full, ATSstrcst("stdin")) ; ats_selptrset_mac(anairiats_rec_0, statmp10, atslab_filename_full_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_STDIN) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin = statmp10 ; statmp91 = ref_make_elt_01875_ats_ptr_type (ATSstrcst("")) ; statmp95 = (ats_sum_ptr_type)0 ; statmp94 = ref_make_elt_01875_ats_ptr_type (statmp95) ; statmp97 = (ats_sum_ptr_type)0 ; statmp96 = ref_make_elt_01875_ats_ptr_type (statmp97) ; statmp120 = ref_make_elt_01875_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; statmp122 = (ats_sum_ptr_type)0 ; statmp121 = ref_make_elt_01875_ats_ptr_type (statmp122) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_ptr_type atsopt_filename_merge ( ats_ptr_type ful, ats_ptr_type bas ) { char c, dirsep ; char *p0, *p1, *p ; int n, n1, n2, found = 0 ; char *fulbas ; p0 = p = (char*)ful ; dirsep = atsopt_filename_theDirsep_get () ; while (1) { c = *p++ ; if (c == 0) break ; if (c == dirsep) { found = 1 ; p1 = p ; } } if (!found) return bas ; n1 = (p1 - p0); n2 = strlen ((char*)bas) ; n = n1 + n2 ; fulbas = ATS_MALLOC (n+1) ; memcpy (fulbas, ful, n1) ; memcpy (fulbas + n1, bas, n2) ; fulbas[n] = '\000' ; return fulbas ; } // end of [atsopt_filename_merge] ats_ptr_type atsopt_filename_append ( ats_ptr_type dir, ats_ptr_type bas ) { int n1, n2, n ; char dirsep, *dirbas ; // dirsep = atsopt_filename_theDirsep_get () ; // n1 = strlen ((char*)dir) ; n2 = strlen ((char*)bas) ; n = n1 + n2 ; if (n1 > 0 && ((char*)dir)[n1-1] != dirsep) n += 1 ; dirbas = ATS_MALLOC (n + 1) ; memcpy (dirbas, dir, n1) ; if (n > n1 + n2) { dirbas[n1] = dirsep ; n1 += 1 ; } memcpy (dirbas + n1, bas, n2) ; dirbas[n] = '\000' ; // return dirbas ; } /* end of [atsopt_filename_append] */ // ats_void_type atsopt_filename_fprint_filename_base (ats_ptr_type out, ats_ptr_type fil) { char dirsep, *name, *basename ; dirsep = atsopt_filename_theDirsep_get () ; name = (char*)atsopt_filename_full (fil) ; basename = strrchr (name, dirsep) ; if (basename) { ++basename ; fputs (basename, (FILE*)out) ; } else { fputs (name, (FILE*)out) ; } /* end of [if] */ return ; } /* end of [atsopt_filename_fprint_filename_base] */ // /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_filename_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans1_dyn_dats.c0000664000175000017500000110345712223166160022214 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ // static ats_bool_type atsopt_string_suffix_is_dats (ats_ptr_type s0) { char *s = strrchr (s0, '.') ; if (!s) return ats_false_bool ; if (strcmp (s, ".dats") != 0) return ats_false_bool ; return ats_true_bool ; } // end of [atsopt_string_suffix_is_dats] // /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_p0arg_loc ; ats_ptr_type atslab_p0arg_sym ; ats_ptr_type atslab_p0arg_ann ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_d0arg_loc ; ats_ptr_type atslab_d0arg_node ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_6 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_d0cstdec_fil ; ats_ptr_type atslab_d0cstdec_loc ; ats_ptr_type atslab_d0cstdec_sym ; ats_ptr_type atslab_d0cstdec_arg ; ats_ptr_type atslab_d0cstdec_eff ; ats_ptr_type atslab_d0cstdec_res ; ats_ptr_type atslab_d0cstdec_extdef ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_p1at_loc ; ats_ptr_type atslab_p1at_node ; } anairiats_rec_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_p0at_loc ; ats_ptr_type atslab_p0at_node ; } anairiats_rec_12 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_clo_ref_type atslab_1 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_d0exp_loc ; ats_ptr_type atslab_d0exp_node ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_f0arg_loc ; ats_ptr_type atslab_f0arg_node ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_s0exp_loc ; ats_ptr_type atslab_s0exp_node ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_i0nvarg_loc ; ats_ptr_type atslab_i0nvarg_sym ; ats_ptr_type atslab_i0nvarg_typ ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_i0nvresstate_qua ; ats_ptr_type atslab_i0nvresstate_arg ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_loopi0nv_qua ; ats_ptr_type atslab_loopi0nv_met ; ats_ptr_type atslab_loopi0nv_arg ; ats_ptr_type atslab_loopi0nv_res ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_m0atch_loc ; ats_ptr_type atslab_m0atch_exp ; ats_ptr_type atslab_m0atch_pat ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_c0lau_loc ; ats_ptr_type atslab_c0lau_pat ; ats_int_type atslab_c0lau_seq ; ats_int_type atslab_c0lau_neg ; ats_ptr_type atslab_c0lau_body ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_guap0at_loc ; ats_ptr_type atslab_guap0at_pat ; ats_ptr_type atslab_guap0at_gua ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_sc0lau_loc ; ats_ptr_type atslab_sc0lau_pat ; ats_ptr_type atslab_sc0lau_body ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_arrqi0de_loc ; ats_ptr_type atslab_arrqi0de_qua ; ats_ptr_type atslab_arrqi0de_sym ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_casehead_tok ; ats_int_type atslab_casehead_knd ; ats_ptr_type atslab_casehead_inv ; } anairiats_rec_29 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_30 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_31 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_32 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_33 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_34 ; typedef struct { ats_ptr_type atslab_ifhead_tok ; ats_ptr_type atslab_ifhead_inv ; } anairiats_rec_35 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_36 ; typedef struct { ats_ptr_type atslab_tryhead_tok ; ats_ptr_type atslab_tryhead_inv ; } anairiats_rec_37 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_38 ; typedef struct { ats_ptr_type atslab_v0aldec_loc ; ats_ptr_type atslab_v0aldec_pat ; ats_ptr_type atslab_v0aldec_def ; ats_ptr_type atslab_v0aldec_ann ; } anairiats_rec_39 ; typedef struct { ats_ptr_type atslab_f0undec_loc ; ats_ptr_type atslab_f0undec_sym ; ats_ptr_type atslab_f0undec_sym_loc ; ats_ptr_type atslab_f0undec_arg ; ats_ptr_type atslab_f0undec_eff ; ats_ptr_type atslab_f0undec_res ; ats_ptr_type atslab_f0undec_def ; ats_ptr_type atslab_f0undec_ann ; } anairiats_rec_40 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_41 ; typedef struct { ats_ptr_type atslab_v0ardec_loc ; ats_int_type atslab_v0ardec_knd ; ats_ptr_type atslab_v0ardec_sym ; ats_ptr_type atslab_v0ardec_sym_loc ; ats_ptr_type atslab_v0ardec_typ ; ats_ptr_type atslab_v0ardec_wth ; ats_ptr_type atslab_v0ardec_ini ; } anairiats_rec_42 ; typedef struct { ats_ptr_type atslab_m0acdef_loc ; ats_ptr_type atslab_m0acdef_sym ; ats_ptr_type atslab_m0acdef_arg ; ats_ptr_type atslab_m0acdef_def ; } anairiats_rec_43 ; typedef struct { ats_ptr_type atslab_i0mpdec_loc ; ats_ptr_type atslab_i0mpdec_qid ; ats_ptr_type atslab_i0mpdec_arg ; ats_ptr_type atslab_i0mpdec_res ; ats_ptr_type atslab_i0mpdec_def ; } anairiats_rec_44 ; typedef struct { ats_ptr_type atslab_impqi0de_loc ; ats_ptr_type atslab_impqi0de_qua ; ats_ptr_type atslab_impqi0de_sym ; ats_ptr_type atslab_impqi0de_arg ; } anairiats_rec_45 ; typedef struct { ats_ptr_type atslab_guad0ec_loc ; ats_ptr_type atslab_guad0ec_node ; } anairiats_rec_46 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_47 ; typedef struct { anairiats_rec_47 atslab_0 ; } anairiats_sum_48 ; typedef struct { ats_ptr_type atslab_d0ec_loc ; ats_ptr_type atslab_d0ec_node ; } anairiats_rec_49 ; typedef struct { ats_ptr_type atslab_e0xp_loc ; ats_ptr_type atslab_e0xp_node ; } anairiats_rec_50 ; typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_51 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMatm_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMopr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpre_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpos_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDlam_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatlam_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDllam_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatllam_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDfix_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatfix_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDifix_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTassert_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTerror_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTprint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tchar_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Texist_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfloat_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfree_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tide_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tint_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist2_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Topide_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tqid_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trec_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tref_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trefas_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tstring_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tsvararg_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup2_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGdyn_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta1_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGmet_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfixity_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cnonfix_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpundef_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpact_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatsrts_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csrtdefs_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacons_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacsts_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstavars_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cclassdec_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextype_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextcode_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_par_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cmacdefs_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdynload_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrpsz_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Echar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecstsp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecrypt_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edecseq_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edelay_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edynload_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eeffmask_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eextval_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloat_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloatsp_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efoldat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efreeat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eide_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eidext_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eint_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eintsp_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eloopexn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eopide_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eptrof_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eqid_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Escaseof_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_lab_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esexparg_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eshowtype_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estring_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estruct_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etmpid_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etop_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALstring_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_none) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATSOPT_NAMESPACE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_STALOADFLAG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFLAG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFUN_NAME) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_full) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push_xit) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__dynload_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exist_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ptrof_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__foldat_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__freeat_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__viewat_prec_dyn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__crypt_prec_dyn) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app) (ats_clo_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash) (ats_ptr_type, ats_clo_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make) (ats_ptr_type, ats_clo_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain_ntm) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, atsopt_namespace_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_dynloadflag_set) (ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_dynloadfun_name_set) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm) (ats_bool_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_undef) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_one) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_all) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_as) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_free) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list2) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_lst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_rec) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ref) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_refas) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_svararg) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup2) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_effc) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo_opt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrpsz) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrsub) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_caseof) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_crypt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_decseq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_effmask) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_fix) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_floatsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_foldat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_for) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_freeat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_intsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_laminit_dyn) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_met) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_ana) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_syn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lazy_delay) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list2) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lst) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_macsyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ptrof) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_raise) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_rec) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_scaseof) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sexparg) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_showtype) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sif) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_struct) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tmpid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_top) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_trywith) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup2) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_where) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_lab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_ind) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1atch_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__c1lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__sc1lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvarg_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_include) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symintr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datsrts) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_srtdefs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacons) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacsts) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stavars) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_sexpdefs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_saspdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dcstdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_exndecs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_classdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_overload) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extype) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extcode) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_par) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_rec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_fundecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_vardecs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_macdefs) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_impdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_local) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_staload) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1cstdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1aldec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__f1undec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1ardec_make) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1acdef_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1mpdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_idextapp_resolve) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_app_syndef) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_localjoin) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_restore) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_search) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_false) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_assert) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_error) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_prerr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__sp0at_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_fixity_tr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_nonfix_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdeflst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0taconlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavarlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0aspdec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_extnam_ismac) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, atsopt_extnam_issta) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, atsopt_extnam_isext) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, atsopt_string_suffix_is_dats) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_ptr_type dcstextdef_tr_2 (ats_ptr_type arg0) ; static ats_ptr_type aux1_3 (ats_ptr_type arg0) ; static ats_ptr_type aux2_4 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) ; static ats_ptr_type aux3_5 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type d0cstdec_tr_6 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d0cstdeclst_tr_7 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type f_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_8_closure_make () ; static ats_ptr_type f_8_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_10 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_11_closure_make () ; static ats_ptr_type __ats_fun_11_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type p1at_make_opr_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_12 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_13_closure_make () ; static ats_ptr_type __ats_fun_13_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s0vararg_tr_14 (ats_ptr_type arg0) ; static ats_ptr_type p0at_tr_errmsg_opr_15 (ats_ptr_type arg0) ; static ats_ptr_type f_19 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_19_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type f_19_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_item_17 (ats_ptr_type arg0) ; static ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_itemlst_18 (ats_ptr_type arg0) ; static ats_ptr_type f_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_23_closure_make () ; static ats_ptr_type f_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_25 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_26_closure_make () ; static ats_ptr_type __ats_fun_26_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d1exp_make_opr_24 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_27 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_28_closure_make () ; static ats_ptr_type __ats_fun_28_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s0exparg_tr_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s0expdarg_tr_30 (ats_ptr_type arg0) ; static ats_ptr_type s0expdarglst_tr_31 (ats_ptr_type arg0) ; static ats_int_type lamkind_isat_32 (ats_ptr_type arg0) ; static ats_int_type lamkind_islin_33 (ats_ptr_type arg0) ; static ats_ptr_type aux_35 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_clo_ptr_type aux_35_closure_make (ats_ptr_type env0, ats_int_type env1) ; static ats_ptr_type aux_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_void_type termination_metric_check_36 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type i0nvarg_tr_37 (ats_ptr_type arg0) ; static ats_ptr_type i0nvarglst_tr_38 (ats_ptr_type arg0) ; static ats_ptr_type i0nvresstate_tr_39 (ats_ptr_type arg0) ; static ats_ptr_type loopi0nv_tr_40 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type m0atch_tr_41 (ats_ptr_type arg0) ; static ats_ptr_type m0atchlst_tr_42 (ats_ptr_type arg0) ; static ats_ptr_type c0lau_tr_43 (ats_ptr_type arg0) ; static ats_ptr_type c0laulst_tr_44 (ats_ptr_type arg0) ; static ats_ptr_type sc0lau_tr_45 (ats_ptr_type arg0) ; static ats_ptr_type sc0laulst_tr_46 (ats_ptr_type arg0) ; static ats_ptr_type opr_errmsg_48 (ats_ptr_type arg0) ; static ats_ptr_type f_51 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_51_closure_make (ats_ptr_type env0, ats_int_type env1) ; static ats_ptr_type f_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_52 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_52_closure_make (ats_ptr_type env0, ats_int_type env1) ; static ats_ptr_type f_52_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_53 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_53_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_53_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_54 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_54_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type f_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_55 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_55_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type f_55_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_56 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_56_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type f_56_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_57 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_57_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_58 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type f_58_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) ; static ats_ptr_type f_58_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_59 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type f_59_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) ; static ats_ptr_type f_59_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_60 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_60_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_item_49 (ats_ptr_type arg0) ; static ats_ptr_type aux_61 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_itemlst_50 (ats_ptr_type arg0) ; static ats_ptr_type v0aldec_tr_66 (ats_ptr_type arg0) ; static ats_ptr_type v0aldeclst_tr_67 (ats_ptr_type arg0) ; static ats_ptr_type f0undec_tr_68 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type f0undeclst_tr_69 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v0ardec_tr_70 (ats_ptr_type arg0) ; static ats_ptr_type v0ardeclst_tr_71 (ats_ptr_type arg0) ; static ats_ptr_type m0acdef_tr_72 (ats_ptr_type arg0) ; static ats_ptr_type m0acdeflst_tr_73 (ats_ptr_type arg0) ; static ats_ptr_type aux_75 (ats_ptr_type arg0) ; static ats_ptr_type i0mpdec_tr_74 (ats_ptr_type arg0) ; static ats_ptr_type loop_77 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type guad0ec_tr_76 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type the_filenamelst_push_xit_78 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type i0nclude_tr_79 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s0taload_tr_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_namespace_85 () ; static ats_void_type aux_dynloadflag_86 () ; static ats_void_type aux_dynloadfun_name_87 () ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp137) ; ATSstatic (ats_ptr_type, statmp141) ; ATSstatic (ats_ptr_type, statmp256) ; ATSstatic (ats_ptr_type, statmp260) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 2833(line=95, offs=4) -- 2918(line=96, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error1_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error1_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 2952(line=99, offs=4) -- 3064(line=101, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_prerr_loc_interror_1: /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp2 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans1_dyn)")) ; return /* (tmp2) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 3537(line=123, offs=4) -- 4086(line=142, offs=6) */ ATSstaticdec() ats_ptr_type dcstextdef_tr_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_bool_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_bool_type, tmp9) ; __ats_lab_dcstextdef_tr_2: tmp5 = atspre_stropt_is_none (arg0) ; if (tmp5) { tmp4 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; } else { /* ats_ptr_type tmp6 ; */ tmp6 = ats_castfn_mac(ats_ptr_type, arg0) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: __ats_lab_0_1: tmp7 = atsopt_extnam_ismac (ats_castfn_mac(ats_ptr_type, arg0), (&tmp6)) ; if (!tmp7) { goto __ats_lab_1_1 ; } tmp4 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp4)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp4, atslab_0, tmp6) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp8 = atsopt_extnam_issta (ats_castfn_mac(ats_ptr_type, arg0), (&tmp6)) ; if (!tmp8) { goto __ats_lab_2_1 ; } tmp4 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp4)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp4, atslab_0, tmp6) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp9 = atsopt_extnam_isext (ats_castfn_mac(ats_ptr_type, arg0), (&tmp6)) ; if (!tmp9) { goto __ats_lab_3_1 ; } tmp4 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp4)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp4, atslab_0, tmp6) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp4 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp4)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp4, atslab_0, tmp6) ; break ; } while (0) ; } /* end of [if] */ return (tmp4) ; } /* end of [dcstextdef_tr_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 4232(line=151, offs=5) -- 4724(line=165, offs=4) */ ATSstaticdec() ats_ptr_type aux1_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_aux1_3: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_4_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp11), atslab_p0arg_ann) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (tmp13 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_4, tmp13, atslab_0) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp14) ; tmp16 = aux1_3 (tmp12) ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp10, atslab_0, tmp15) ; ats_selptrset_mac(anairiats_sum_2, tmp10, atslab_1, tmp16) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (tmp13 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp11), atslab_p0arg_loc) ; /* tmp17 = */ prerr_loc_error1_0 (tmp18) ; /* tmp19 = */ atspre_prerr_string (ATSstrcst(": unascribed variable: [")) ; tmp21 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp11), atslab_p0arg_sym) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp21) ; /* tmp22 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp23 = */ atspre_prerr_newline () ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp10 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp10) ; } /* end of [aux1_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 4747(line=167, offs=5) -- 6918(line=222, offs=4) */ ATSstaticdec() ats_ptr_type aux2_4 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ref_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_int_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_bool_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_bool_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_int_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_int_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_bool_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_int_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; // ATSlocal_void (tmp70) ; ATSlocal (ats_bool_type, tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; __ats_lab_aux2_4: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg6 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_8_1: tmp25 = ats_caselptrlab_mac(anairiats_sum_2, arg6, atslab_0) ; tmp26 = ats_caselptrlab_mac(anairiats_sum_2, arg6, atslab_1) ; tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp25), atslab_d0arg_node) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp27)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_1, tmp27, atslab_0) ; tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp25), atslab_d0arg_loc) ; tmp31 = aux1_3 (tmp28) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list (tmp29, tmp31) ; tmp33 = atspre_add_int_int (arg4, 1) ; tmp32 = aux2_4 (arg0, arg1, arg2, arg3, tmp33, arg5, tmp26, arg7) ; tmp34 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp32), atslab_s1exp_loc) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp29, tmp34) ; tmp37 = atspre_gt_int_int (arg4, 0) ; if (tmp37) { tmp36 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp36, atslab_0, 1) ; } else { tmp36 = arg0 ; } /* end of [if] */ tmp39 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg5), 0) ; if (tmp39) { tmp40 = (ats_sum_ptr_type)0 ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (tmp34, tmp36, 0, 0, tmp40) ; } else { tmp38 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (tmp34, tmp36, arg1, arg2, arg3) ; } /* end of [if] */ tmp41 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg5), 1) ; ats_ptrget_mac(ats_int_type, arg5) = tmp41 ; tmp42 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp42, atslab_0, tmp30) ; tmp43 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp42), atslab_1) ; tmp44 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp44, atslab_0, tmp32) ; ats_ptrget_mac(ats_ptr_type, tmp43) = tmp44 ; tmp43 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp44), atslab_1) ; tmp44 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp43) = tmp44 ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (tmp35, tmp38, tmp35, tmp42) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp27)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_8, tmp27, atslab_0) ; tmp46 = ats_caselptrlab_mac(anairiats_sum_8, tmp27, atslab_1) ; tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp25), atslab_d0arg_loc) ; tmp49 = aux1_3 (tmp45) ; tmp50 = aux1_3 (tmp46) ; tmp48 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2 (tmp47, tmp49, tmp50) ; tmp52 = atspre_add_int_int (arg4, 1) ; tmp51 = aux2_4 (arg0, arg1, arg2, arg3, tmp52, arg5, tmp26, arg7) ; tmp53 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp51), atslab_s1exp_loc) ; tmp54 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp47, tmp53) ; tmp56 = atspre_gt_int_int (arg4, 0) ; if (tmp56) { tmp55 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp55, atslab_0, 1) ; } else { tmp55 = arg0 ; } /* end of [if] */ tmp58 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg5), 0) ; if (tmp58) { tmp59 = (ats_sum_ptr_type)0 ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (tmp53, tmp55, 0, 0, tmp59) ; } else { tmp57 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (tmp53, tmp55, arg1, arg2, arg3) ; } /* end of [if] */ tmp60 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg5), 1) ; ats_ptrget_mac(ats_int_type, arg5) = tmp60 ; tmp61 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp61, atslab_0, tmp48) ; tmp62 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp61), atslab_1) ; tmp63 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp63, atslab_0, tmp51) ; ats_ptrget_mac(ats_ptr_type, tmp62) = tmp63 ; tmp62 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp63), atslab_1) ; tmp63 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp62) = tmp63 ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (tmp54, tmp57, tmp54, tmp61) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (((ats_sum_ptr_type)tmp27)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_1, tmp27, atslab_0) ; tmp65 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp25), atslab_d0arg_loc) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp64) ; tmp67 = aux2_4 (arg0, arg1, arg2, arg3, arg4, arg5, tmp26, arg7) ; tmp68 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp67), atslab_s1exp_loc) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp65, tmp68) ; tmp71 = atspre_eq_int_int (ats_ptrget_mac(ats_int_type, arg5), 0) ; if (tmp71) { /* tmp72 = */ prerr_loc_error1_0 (tmp68) ; /* tmp73 = */ atspre_prerr_string (ATSstrcst(": illegal use of effect annotation")) ; /* tmp74 = */ atspre_prerr_newline () ; /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni (tmp69, tmp66, tmp67) ; break ; } while (0) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg6 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp24 = arg7 ; break ; } while (0) ; return (tmp24) ; } /* end of [aux2_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 6940(line=224, offs=4) -- 8274(line=268, offs=4) */ ATSstaticdec() ats_ptr_type aux3_5 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (anairiats_rec_0, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_int_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_int_type, tmp92) ; ATSlocal (ats_bool_type, tmp93) ; // ATSlocal_void (tmp94) ; ATSlocal (ats_bool_type, tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_bool_type, tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; ATSlocal (ats_int_type, tmp101) ; __ats_lab_aux3_5: /* ats_ptr_type tmp76 ; */ tmp76 = (ats_sum_ptr_type)0 ; /* ats_int_type tmp77 ; */ tmp77 = 0 ; /* ats_int_type tmp78 ; */ if (arg2) { tmp78 = 1 ; } else { tmp78 = 0 ; } /* end of [if] */ /* ats_ptr_type tmp79 ; */ tmp79 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_13_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_4, arg4, atslab_0) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (tmp81) ; tmp83 = ats_select_mac(tmp82, atslab_0) ; tmp84 = ats_select_mac(tmp82, atslab_1) ; tmp85 = ats_select_mac(tmp82, atslab_2) ; tmp86 = ats_select_mac(tmp82, atslab_3) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp83 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_4, tmp83, atslab_0) ; tmp76 = tmp88 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp83 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: break ; } while (0) ; tmp77 = tmp84 ; tmp89 = atspre_add_int_int (tmp78, tmp85) ; tmp78 = tmp89 ; tmp90 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp90, atslab_0, tmp86) ; tmp79 = tmp90 ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: break ; } while (0) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (tmp76 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_7, tmp76, atslab_0) ; tmp93 = atspre_neq_int_int (tmp92, -1) ; if (tmp93) { tmp95 = atspre_eq_int_int (tmp92, 0) ; if (tmp95) { /* tmp96 = */ prerr_loc_error1_0 (arg0) ; /* tmp94 = */ atspre_prerr_string (ATSstrcst(": a closure at the toplevel")) ; } else { /* empty */ } /* end of [if] */ tmp98 = atspre_eq_int_int (tmp92, 1) ; if (tmp98) { /* tmp99 = */ prerr_loc_error1_0 (arg0) ; /* tmp97 = */ atspre_prerr_string (ATSstrcst(": a closure pointer is not allowed at the toplevel")) ; } else { /* empty */ } /* end of [if] */ /* tmp100 = */ atspre_prerr_newline () ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (tmp76 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; /* ats_int_type tmp101 ; */ tmp101 = 0 ; tmp75 = aux2_4 (tmp76, tmp77, tmp78, tmp79, 0, (&tmp101), arg3, arg5) ; return (tmp75) ; } /* end of [aux3_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 8317(line=272, offs=4) -- 8752(line=287, offs=4) */ ATSstaticdec() ats_ptr_type d0cstdec_tr_6 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_d0cstdec_tr_6: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_fil) ; tmp104 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_loc) ; tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_res) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp106) ; tmp107 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_arg) ; tmp108 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_eff) ; tmp109 = aux3_5 (tmp104, arg0, arg1, tmp107, tmp108, tmp105) ; tmp111 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_extdef) ; tmp110 = dcstextdef_tr_2 (tmp111) ; tmp112 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d0cstdec_sym) ; tmp102 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1cstdec_make (tmp103, tmp104, tmp112, tmp109, tmp110) ; return (tmp102) ; } /* end of [d0cstdec_tr_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 8782(line=289, offs=5) -- 9019(line=294, offs=21) */ ATSstaticdec() ats_ptr_type d0cstdeclst_tr_7 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_d0cstdeclst_tr_7: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp114 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp115 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_1) ; tmp116 = d0cstdec_tr_6 (arg0, arg1, tmp114) ; tmp117 = d0cstdeclst_tr_7 (arg0, arg1, tmp115) ; tmp113 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp113, atslab_0, tmp116) ; ats_selptrset_mac(anairiats_sum_2, tmp113, atslab_1, tmp117) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp113 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp113) ; } /* end of [d0cstdeclst_tr_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 9242(line=308, offs=4) -- 10139(line=335, offs=6) */ ATSstaticdec() ats_ptr_type f_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_f_8: tmp120 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p1at_loc) ; tmp121 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_p1at_loc) ; tmp119 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp120, tmp121) ; tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_p1at_node) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp123)->tag != 12) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp124 = ats_caselptrlab_mac(anairiats_sum_11, tmp123, atslab_0) ; tmp125 = ats_caselptrlab_mac(anairiats_sum_11, tmp123, atslab_1) ; tmp126 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_p1at_loc) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (tmp119, arg0, tmp126, tmp124, tmp125) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp123)->tag != 19) { goto __ats_lab_25_0 ; } __ats_lab_22_1: tmp127 = ats_caselptrlab_mac(anairiats_sum_1, tmp123, atslab_0) ; tmp128 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p1at_node) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp128)->tag != 4) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp129 = ats_caselptrlab_mac(anairiats_sum_8, tmp128, atslab_0) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_8, tmp128, atslab_1) ; tmp131 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp130, tmp127) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta (tmp119, tmp129, tmp131) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp133 = (ats_sum_ptr_type)0 ; tmp132 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp132, atslab_0, tmp127) ; ats_selptrset_mac(anairiats_sum_2, tmp132, atslab_1, tmp133) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta (tmp119, arg0, tmp132) ; break ; } while (0) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp134 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_p1at_loc) ; tmp136 = (ats_sum_ptr_type)0 ; tmp135 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp135, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp135, atslab_1, tmp136) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (tmp119, arg0, tmp134, 0, tmp135) ; break ; } while (0) ; tmp118 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp118)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp118, atslab_0, tmp122) ; return (tmp118) ; } /* end of [f_8] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_8_closure_type ; ats_ptr_type f_8_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_8 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_8_closure_init (f_8_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_8_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_8_closure_make () { f_8_closure_type *p_clo = ATS_MALLOC(sizeof(f_8_closure_type)) ; f_8_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10295(line=343, offs=5) -- 10314(line=343, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp139) ; __ats_lab___ats_fun_10: tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p1at_loc) ; return (tmp139) ; } /* end of [__ats_fun_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10319(line=344, offs=5) -- 10385(line=344, offs=71) */ ATSstaticdec() ats_ptr_type __ats_fun_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp140) ; __ats_lab___ats_fun_11: tmp140 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (arg0, arg1, arg2, 0, arg3) ; return (tmp140) ; } /* end of [__ats_fun_11] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_11_closure_type ; ats_ptr_type __ats_fun_11_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_11 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_11_closure_init (__ats_fun_11_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_11_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_11_closure_make () { __ats_fun_11_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_11_closure_type)) ; __ats_fun_11_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10213(line=341, offs=5) -- 10429(line=348, offs=4) */ ATSstaticdec() ats_ptr_type p1at_make_opr_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_p1at_make_opr_9: tmp138 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (&__ats_fun_10, __ats_fun_11_closure_make (), arg0, arg1) ; return (tmp138) ; } /* end of [p1at_make_opr_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10537(line=352, offs=5) -- 10556(line=352, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_12 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; __ats_lab___ats_fun_12: tmp142 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p1at_loc) ; return (tmp142) ; } /* end of [__ats_fun_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10562(line=353, offs=5) -- 10628(line=353, offs=71) */ ATSstaticdec() ats_ptr_type __ats_fun_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp143) ; __ats_lab___ats_fun_13: tmp143 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (arg0, arg1, arg2, 0, arg3) ; return (tmp143) ; } /* end of [__ats_fun_13] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_13_closure_type ; ats_ptr_type __ats_fun_13_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_13 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_13_closure_init (__ats_fun_13_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_13_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_13_closure_make () { __ats_fun_13_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_13_closure_type)) ; __ats_fun_13_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10724(line=359, offs=4) -- 10909(line=363, offs=37) */ ATSstaticdec() ats_ptr_type s0vararg_tr_14 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_s0vararg_tr_14: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp145 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (tmp145) ; tmp144 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp144)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp144, atslab_0, tmp146) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp144 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGone_0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp144 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGall_1) ; break ; } while (0) ; return (tmp144) ; } /* end of [s0vararg_tr_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 10959(line=368, offs=4) -- 11151(line=375, offs=4) */ ATSstaticdec() ats_ptr_type p0at_tr_errmsg_opr_15 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; __ats_lab_p0at_tr_errmsg_opr_15: /* tmp148 = */ prerr_loc_error1_0 (arg0) ; /* tmp149 = */ atspre_prerr_string (ATSstrcst(": the operator needs to be applied.")) ; /* tmp150 = */ atspre_prerr_newline () ; /* tmp147 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp147) ; } /* end of [p0at_tr_errmsg_opr_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 11862(line=410, offs=9) -- 12037(line=416, offs=8) */ ATSstaticdec() ats_ptr_type f_19 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; __ats_lab_f_19: tmp172 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p1at_loc) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp172) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_exist (tmp171, env1, arg0) ; tmp170 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp170)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp170, atslab_0, tmp173) ; return (tmp170) ; } /* end of [f_19] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } f_19_closure_type ; ats_ptr_type f_19_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_19 (((f_19_closure_type*)cloptr)->closure_env_0, ((f_19_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_19_closure_init (f_19_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_19_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_19_closure_make (ats_ptr_type env0, ats_ptr_type env1) { f_19_closure_type *p_clo = ATS_MALLOC(sizeof(f_19_closure_type)) ; f_19_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 11220(line=381, offs=1) -- 14020(line=486, offs=4) */ ATSstaticdec() ats_ptr_type aux_item_17 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_char_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_bool_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_bool_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_int_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_int_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_aux_item_17: tmp153 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_p0at_loc) ; tmp154 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_p0at_node) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp154)->tag != 0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_0) ; tmp156 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_1) ; tmp157 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp155) ; tmp158 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp156) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ann (tmp153, tmp157, tmp158) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp159) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp154)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp161 = aux_itemlst_18 (arg0) ; tmp160 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (tmp153, statmp137, tmp161) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp160) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp154)->tag != 2) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp162 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_0) ; tmp163 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_1) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp163) ; tmp164 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_as (tmp153, tmp162, tmp165) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp164) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp154)->tag != 3) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_13, tmp154, atslab_0) ; tmp167 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char (tmp153, tmp166) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp167) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp154)->tag != 4) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp169 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (tmp168) ; tmp174 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp174)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp174, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exist_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp174, atslab_1, f_19_closure_make (tmp153, tmp169)) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp174) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp154)->tag != 5) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp176 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float (tmp153, tmp175) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp176) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp154)->tag != 6) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp179 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp177) ; tmp178 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_free (tmp153, tmp179) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp178) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp154)->tag != 7) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp181 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp180, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; if (!tmp181) { goto __ats_lab_37_1 ; } tmp152 = statmp141 ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp154)->tag != 7) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp183 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp182, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE) ; if (!tmp183) { goto __ats_lab_38_1 ; } tmp184 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any (tmp153) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp184) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp154)->tag != 7) { goto __ats_lab_41_0 ; } __ats_lab_38_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp186 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide (tmp153, tmp185) ; tmp187 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp185) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (tmp187 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp188 = ats_caselptrlab_mac(anairiats_sum_4, tmp187, atslab_0) ; ATS_FREE(tmp187) ; tmp152 = p1at_make_opr_9 (tmp186, tmp188) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (tmp187 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp186) ; break ; } while (0) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp154)->tag != 8) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp189 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp190 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int (tmp153, tmp189) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp190) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp154)->tag != 9) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp192 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp191) ; tmp193 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list (tmp153, tmp192) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp193) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp154)->tag != 10) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp194 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_0) ; tmp195 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_1) ; tmp196 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp194) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp195) ; tmp198 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list2 (tmp153, tmp196, tmp197) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp198) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp154)->tag != 11) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp200 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp199) ; tmp201 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_lst (tmp153, tmp200) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp201) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp154)->tag != 12) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp203 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide (tmp153, tmp202) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp203) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp154)->tag != 13) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp204 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_0) ; tmp205 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_1) ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid (tmp153, tmp204, tmp205) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp206) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp154)->tag != 14) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp207 = ats_caselptrlab_mac(anairiats_sum_11, tmp154, atslab_0) ; tmp208 = ats_caselptrlab_mac(anairiats_sum_11, tmp154, atslab_1) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr (tmp208) ; tmp209 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_rec (tmp153, tmp207, tmp210) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp209) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp154)->tag != 15) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp212 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ref (tmp153, tmp211) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp212) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp154)->tag != 16) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_0) ; tmp214 = ats_caselptrlab_mac(anairiats_sum_8, tmp154, atslab_1) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp214) ; tmp215 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_refas (tmp153, tmp213, tmp216) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp215) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp154)->tag != 18) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp217 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp219 = s0vararg_tr_14 (tmp217) ; tmp218 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_svararg (tmp153, tmp219) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp218) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp154)->tag != 17) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string (tmp153, tmp220) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp221) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp154)->tag != 19) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_11, tmp154, atslab_0) ; tmp223 = ats_caselptrlab_mac(anairiats_sum_11, tmp154, atslab_1) ; tmp224 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp223) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup (tmp153, tmp222, tmp224) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp225) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (((ats_sum_ptr_type)tmp154)->tag != 20) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_15, tmp154, atslab_0) ; tmp227 = ats_caselptrlab_mac(anairiats_sum_15, tmp154, atslab_1) ; tmp228 = ats_caselptrlab_mac(anairiats_sum_15, tmp154, atslab_2) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp227) ; tmp230 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (tmp228) ; tmp231 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup2 (tmp153, tmp226, tmp229, tmp230) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, tmp231) ; break ; } while (0) ; return (tmp152) ; } /* end of [aux_item_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 14100(line=490, offs=7) -- 14351(line=499, offs=6) */ ATSstaticdec() ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_aux_20: tmp234 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_p0at_node) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp234)->tag != 1) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp235 = ats_caselptrlab_mac(anairiats_sum_8, tmp234, atslab_0) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_8, tmp234, atslab_1) ; tmp238 = aux_item_17 (tmp236) ; tmp237 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp237, atslab_0, tmp238) ; ats_selptrset_mac(anairiats_sum_2, tmp237, atslab_1, arg0) ; arg0 = tmp237 ; arg1 = tmp235 ; goto __ats_lab_aux_20 ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp239 = aux_item_17 (arg1) ; tmp233 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp233, atslab_0, tmp239) ; ats_selptrset_mac(anairiats_sum_2, tmp233, atslab_1, arg0) ; break ; } while (0) ; return (tmp233) ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 14049(line=488, offs=5) -- 14395(line=502, offs=4) */ ATSstaticdec() ats_ptr_type aux_itemlst_18 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp240) ; __ats_lab_aux_itemlst_18: tmp240 = (ats_sum_ptr_type)0 ; tmp232 = aux_20 (tmp240, arg0) ; return (tmp232) ; } /* end of [aux_itemlst_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 11202(line=378, offs=9) -- 14537(line=508, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr: tmp241 = aux_item_17 (arg0) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp241)->tag != 0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_1, tmp241, atslab_0) ; tmp151 = tmp242 ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (((ats_sum_ptr_type)tmp241)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: tmp243 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_p0at_loc) ; tmp151 = p0at_tr_errmsg_opr_15 (tmp243) ; break ; } while (0) ; return (tmp151) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 14580(line=511, offs=12) -- 14624(line=512, offs=36) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr: tmp244 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr) ; return (tmp244) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0atlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 14673(line=516, offs=15) -- 14914(line=526, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_0) ; tmp247 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_1) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp247) ; tmp250 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr (tmp248) ; tmp245 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp245)->tag = 2 ; ats_selptrset_mac(anairiats_sum_16, tmp245, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_16, tmp245, atslab_1, tmp249) ; ats_selptrset_mac(anairiats_sum_16, tmp245, atslab_2, tmp250) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp245 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp245 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1) ; break ; } while (0) ; return (tmp245) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labp0atlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15116(line=538, offs=4) -- 15445(line=552, offs=4) */ ATSstaticdec() ats_ptr_type f_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_f_23: tmp253 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp254 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_d1exp_loc) ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp253, tmp254) ; tmp255 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_app_syndef (tmp252, arg0, arg1) ; tmp251 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp251)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp251, atslab_0, tmp255) ; return (tmp251) ; } /* end of [f_23] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_23_closure_type ; ats_ptr_type f_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_23 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_23_closure_init (f_23_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_23_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_23_closure_make () { f_23_closure_type *p_clo = ATS_MALLOC(sizeof(f_23_closure_type)) ; f_23_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15611(line=562, offs=5) -- 15631(line=562, offs=25) */ ATSstaticdec() ats_ptr_type __ats_fun_25 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; __ats_lab___ats_fun_25: tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; return (tmp258) ; } /* end of [__ats_fun_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15636(line=563, offs=5) -- 15703(line=563, offs=72) */ ATSstaticdec() ats_ptr_type __ats_fun_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp259) ; __ats_lab___ats_fun_26: tmp259 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, arg1, arg2, 0, arg3) ; return (tmp259) ; } /* end of [__ats_fun_26] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_26_closure_type ; ats_ptr_type __ats_fun_26_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_26 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_26_closure_init (__ats_fun_26_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_26_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_26_closure_make () { __ats_fun_26_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_26_closure_type)) ; __ats_fun_26_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15520(line=558, offs=5) -- 15747(line=567, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_make_opr_24 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_d1exp_make_opr_24: tmp257 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (&__ats_fun_25, __ats_fun_26_closure_make (), arg0, arg1) ; return (tmp257) ; } /* end of [d1exp_make_opr_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15852(line=571, offs=5) -- 15872(line=571, offs=25) */ ATSstaticdec() ats_ptr_type __ats_fun_27 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; __ats_lab___ats_fun_27: tmp261 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; return (tmp261) ; } /* end of [__ats_fun_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 15878(line=572, offs=5) -- 15945(line=572, offs=72) */ ATSstaticdec() ats_ptr_type __ats_fun_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; __ats_lab___ats_fun_28: tmp262 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, arg1, arg2, 0, arg3) ; return (tmp262) ; } /* end of [__ats_fun_28] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_28_closure_type ; ats_ptr_type __ats_fun_28_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_28 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_28_closure_init (__ats_fun_28_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_28_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_28_closure_make () { __ats_fun_28_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_28_closure_type)) ; __ats_fun_28_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 16038(line=578, offs=4) -- 16254(line=584, offs=63) */ ATSstaticdec() ats_ptr_type s0exparg_tr_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; __ats_lab_s0exparg_tr_29: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_one (arg0) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_all (arg0) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp264 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp265 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp264) ; tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_seq (arg0, tmp265) ; break ; } while (0) ; return (tmp263) ; } /* end of [s0exparg_tr_29] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 16283(line=587, offs=4) -- 16613(line=601, offs=4) */ ATSstaticdec() ats_ptr_type s0expdarg_tr_30 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; // ATSlocal_void (tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; __ats_lab_s0expdarg_tr_30: tmp267 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (arg0) ; tmp268 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp267), atslab_d1exp_node) ; do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp268)->tag != 47) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_1, tmp268, atslab_0) ; tmp266 = tmp269 ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: __ats_lab_65_1: tmp271 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_d0exp_loc) ; /* tmp270 = */ prerr_loc_interror_1 (tmp271) ; /* tmp272 = */ atspre_prerr_string (ATSstrcst(": d0exp_tr: D0Efoldat")) ; /* tmp273 = */ atspre_prerr_newline () ; /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp266) ; } /* end of [s0expdarg_tr_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 16644(line=603, offs=5) -- 16798(line=606, offs=21) */ ATSstaticdec() ats_ptr_type s0expdarglst_tr_31 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; __ats_lab_s0expdarglst_tr_31: do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp276 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp277 = s0expdarg_tr_30 (tmp275) ; tmp278 = s0expdarglst_tr_31 (tmp276) ; tmp274 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp274, atslab_0, tmp277) ; ats_selptrset_mac(anairiats_sum_2, tmp274, atslab_1, tmp278) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: tmp274 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp274) ; } /* end of [s0expdarglst_tr_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 18309(line=662, offs=5) -- 18526(line=670, offs=23) */ ATSstaticdec() ats_int_type lamkind_isat_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp279) ; __ats_lab_lamkind_isat_32: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp279 = 0 ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp279 = 1 ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp279 = 0 ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp279 = 1 ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp279 = 0 ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp279 = 1 ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (((ats_sum_ptr_type)arg0)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: tmp279 = 0 ; break ; } while (0) ; return (tmp279) ; } /* end of [lamkind_isat_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 18557(line=673, offs=5) -- 18717(line=679, offs=11) */ ATSstaticdec() ats_int_type lamkind_islin_33 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp280) ; __ats_lab_lamkind_islin_33: do { /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp280 = 0 ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp280 = 0 ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp280 = 1 ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp280 = 1 ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp280 = 0 ; break ; } while (0) ; return (tmp280) ; } /* end of [lamkind_islin_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 18862(line=688, offs=7) -- 20786(line=741, offs=6) */ ATSstaticdec() ats_ptr_type aux_35 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_bool_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_int_type, tmp300) ; ATSlocal (ats_bool_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; __ats_lab_aux_35: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_80_1: tmp283 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp284 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp285 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp283), atslab_f0arg_loc) ; tmp287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp283), atslab_f0arg_node) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp287)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp286 = atspre_add_int_int (arg3, 1) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp286 = arg3 ; break ; } while (0) ; tmp288 = aux_35 (env0, env1, arg0, tmp284, arg2, tmp286) ; tmp289 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp288), atslab_d1exp_loc) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (env0 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp291 = ats_caselptrlab_mac(anairiats_sum_4, env0, atslab_0) ; tmp290 = tmp291 ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (env0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: tmp290 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp285, tmp289) ; break ; } while (0) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp283), atslab_f0arg_node) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp292)->tag != 1) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_1, tmp292, atslab_0) ; tmp294 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp293) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_syn (tmp290, tmp285, tmp294, tmp288) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp292)->tag != 2) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp295 = ats_caselptrlab_mac(anairiats_sum_1, tmp292, atslab_0) ; tmp296 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (tmp295) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_ana (tmp290, tmp285, tmp296, tmp288) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp292)->tag != 0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp297 = ats_caselptrlab_mac(anairiats_sum_1, tmp292, atslab_0) ; tmp298 = atspre_eq_int_int (arg3, 0) ; if (!tmp298) { goto __ats_lab_88_1 ; } tmp299 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp297) ; tmp300 = lamkind_isat_32 (arg0) ; tmp301 = atspre_eq_int_int (tmp300, 0) ; if (tmp301) { tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn (tmp290, env1, tmp299, tmp288) ; } else { tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_laminit_dyn (tmp290, env1, tmp299, tmp288) ; } /* end of [if] */ break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp292)->tag != 0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp302 = ats_caselptrlab_mac(anairiats_sum_1, tmp292, atslab_0) ; tmp303 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp302) ; tmp305 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp305, atslab_0, 1) ; tmp304 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo_opt (tmp289, tmp288, tmp305) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn (tmp290, env1, tmp303, tmp304) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (((ats_sum_ptr_type)tmp292)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_1, tmp292, atslab_0) ; tmp307 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp306) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_met (tmp290, tmp285, tmp307, tmp288) ; break ; } while (0) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp282 = arg2 ; break ; } while (0) ; return (tmp282) ; } /* end of [aux_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; } aux_35_closure_type ; ats_ptr_type aux_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { return aux_35 (((aux_35_closure_type*)cloptr)->closure_env_0, ((aux_35_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type aux_35_closure_init (aux_35_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_35_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_35_closure_make (ats_ptr_type env0, ats_int_type env1) { aux_35_closure_type *p_clo = ATS_MALLOC(sizeof(aux_35_closure_type)) ; aux_35_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 18794(line=685, offs=19) -- 21708(line=777, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr: tmp308 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (arg7) ; do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_4, arg5, atslab_0) ; tmp312 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp310), atslab_s0exp_loc) ; tmp313 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp308), atslab_d1exp_loc) ; tmp311 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp312, tmp313) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp310) ; tmp309 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type (tmp311, tmp308, tmp314) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_92_1: tmp309 = tmp308 ; break ; } while (0) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg6 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp316 = ats_caselptrlab_mac(anairiats_sum_4, arg6, atslab_0) ; tmp317 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp309), atslab_d1exp_loc) ; tmp315 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_effc (tmp317, tmp309, tmp316) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg6 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: tmp315 = tmp309 ; break ; } while (0) ; do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp319 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp320 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp315), atslab_d1exp_loc) ; tmp318 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo (tmp320, tmp315, tmp319) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: tmp318 = tmp315 ; break ; } while (0) ; tmp281 = aux_35 (arg1, arg3, arg0, arg4, tmp318, 0) ; return (tmp281) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 21764(line=781, offs=4) -- 22213(line=795, offs=18) */ ATSstaticdec() ats_void_type termination_metric_check_36 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_bool_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; __ats_lab_termination_metric_check_36: do { /* branch: __ats_lab_97 */ __ats_lab_97_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; if (arg1) { tmp323 = ats_true_bool ; } else { tmp323 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain_ntm (tmp322) ; } /* end of [if] */ if (tmp323) { /* empty */ } else { /* tmp324 = */ prerr_loc_error1_0 (arg0) ; /* tmp325 = */ atspre_prerr_string (ATSstrcst(": a termination metric is missing")) ; /* tmp326 = */ atspre_prerr_newline () ; /* tmp321 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: break ; } while (0) ; return /* (tmp321) */ ; } /* end of [termination_metric_check_36] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 22293(line=800, offs=4) -- 22437(line=804, offs=4) */ ATSstaticdec() ats_ptr_type i0nvarg_tr_37 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; __ats_lab_i0nvarg_tr_37: tmp329 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_i0nvarg_typ) ; tmp328 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp329) ; tmp330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_i0nvarg_loc) ; tmp331 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_i0nvarg_sym) ; tmp327 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvarg_make (tmp330, tmp331, tmp328) ; return (tmp327) ; } /* end of [i0nvarg_tr_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 22466(line=806, offs=5) -- 22615(line=809, offs=21) */ ATSstaticdec() ats_ptr_type i0nvarglst_tr_38 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; __ats_lab_i0nvarglst_tr_38: do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp333 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp334 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp335 = i0nvarg_tr_37 (tmp333) ; tmp336 = i0nvarglst_tr_38 (tmp334) ; tmp332 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp332, atslab_0, tmp335) ; ats_selptrset_mac(anairiats_sum_2, tmp332, atslab_1, tmp336) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: tmp332 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp332) ; } /* end of [i0nvarglst_tr_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 22646(line=812, offs=4) -- 22909(line=821, offs=4) */ ATSstaticdec() ats_ptr_type i0nvresstate_tr_39 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; __ats_lab_i0nvresstate_tr_39: tmp339 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_i0nvresstate_qua) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (tmp339 == (ats_sum_ptr_type)0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_4, tmp339, atslab_0) ; tmp338 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp340) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: // if (tmp339 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_102_1: tmp338 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp342 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_i0nvresstate_arg) ; tmp341 = i0nvarglst_tr_38 (tmp342) ; tmp337 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make (tmp338, tmp341) ; return (tmp337) ; } /* end of [i0nvresstate_tr_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 22942(line=823, offs=4) -- 23383(line=838, offs=4) */ ATSstaticdec() ats_ptr_type loopi0nv_tr_40 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; __ats_lab_loopi0nv_tr_40: tmp345 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_loopi0nv_qua) ; do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (tmp345 == (ats_sum_ptr_type)0) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_4, tmp345, atslab_0) ; tmp344 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp346) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: // if (tmp345 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_104_1: tmp344 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_loopi0nv_met) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (tmp348 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp350 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp349) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp347, atslab_0, tmp350) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: // if (tmp348 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_106_1: tmp347 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp352 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_loopi0nv_arg) ; tmp351 = i0nvarglst_tr_38 (tmp352) ; tmp354 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_loopi0nv_res) ; tmp353 = i0nvresstate_tr_39 (tmp354) ; tmp343 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make (arg0, tmp344, tmp347, tmp351, tmp353) ; return (tmp343) ; } /* end of [loopi0nv_tr_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 23433(line=842, offs=4) -- 23676(line=851, offs=4) */ ATSstaticdec() ats_ptr_type m0atch_tr_41 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; __ats_lab_m0atch_tr_41: tmp357 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_m0atch_exp) ; tmp356 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp357) ; tmp359 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_m0atch_pat) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp359 == (ats_sum_ptr_type)0) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp360 = ats_caselptrlab_mac(anairiats_sum_4, tmp359, atslab_0) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp360) ; tmp358 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp358, atslab_0, tmp361) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: // if (tmp359 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_108_1: tmp358 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp362 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_m0atch_loc) ; tmp355 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1atch_make (tmp362, tmp356, tmp358) ; return (tmp355) ; } /* end of [m0atch_tr_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 23703(line=853, offs=4) -- 23788(line=855, offs=39) */ ATSstaticdec() ats_ptr_type m0atchlst_tr_42 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp363) ; __ats_lab_m0atchlst_tr_42: tmp363 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &m0atch_tr_41) ; return (tmp363) ; } /* end of [m0atchlst_tr_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 23818(line=858, offs=4) -- 24085(line=866, offs=4) */ ATSstaticdec() ats_ptr_type c0lau_tr_43 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_int_type, tmp373) ; ATSlocal (ats_int_type, tmp374) ; __ats_lab_c0lau_tr_43: tmp365 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_c0lau_pat) ; tmp367 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp365), atslab_guap0at_gua) ; tmp366 = m0atchlst_tr_42 (tmp367) ; tmp369 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, tmp365), atslab_guap0at_pat) ; tmp368 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp369) ; tmp371 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_c0lau_body) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp371) ; tmp372 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_c0lau_loc) ; tmp373 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_c0lau_seq) ; tmp374 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_c0lau_neg) ; tmp364 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__c1lau_make (tmp372, tmp368, tmp366, tmp373, tmp374, tmp370) ; return (tmp364) ; } /* end of [c0lau_tr_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24111(line=868, offs=4) -- 24188(line=869, offs=37) */ ATSstaticdec() ats_ptr_type c0laulst_tr_44 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; __ats_lab_c0laulst_tr_44: tmp375 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &c0lau_tr_43) ; return (tmp375) ; } /* end of [c0laulst_tr_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24217(line=872, offs=4) -- 24389(line=878, offs=4) */ ATSstaticdec() ats_ptr_type sc0lau_tr_45 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; __ats_lab_sc0lau_tr_45: tmp378 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_sc0lau_pat) ; tmp377 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__sp0at_tr (tmp378) ; tmp380 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_sc0lau_body) ; tmp379 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp380) ; tmp381 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_sc0lau_loc) ; tmp376 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__sc1lau_make (tmp381, tmp377, tmp379) ; return (tmp376) ; } /* end of [sc0lau_tr_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24416(line=880, offs=4) -- 24499(line=881, offs=39) */ ATSstaticdec() ats_ptr_type sc0laulst_tr_46 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp382) ; __ats_lab_sc0laulst_tr_46: tmp382 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &sc0lau_tr_45) ; return (tmp382) ; } /* end of [sc0laulst_tr_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24583(line=889, offs=4) -- 24779(line=896, offs=4) */ ATSstaticdec() ats_ptr_type opr_errmsg_48 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; __ats_lab_opr_errmsg_48: tmp386 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_d0exp_loc) ; /* tmp385 = */ prerr_loc_error1_0 (tmp386) ; /* tmp387 = */ atspre_prerr_string (ATSstrcst(": the operator needs to be applied.")) ; /* tmp388 = */ atspre_prerr_newline () ; /* tmp384 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp384) ; } /* end of [opr_errmsg_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 27100(line=965, offs=10) -- 27271(line=968, offs=12) */ ATSstaticdec() ats_ptr_type f_51 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; __ats_lab_f_51: tmp445 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp444 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp445) ; tmp446 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_crypt (tmp444, env1, arg0) ; tmp443 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp443)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp443, atslab_0, tmp446) ; return (tmp443) ; } /* end of [f_51] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; } f_51_closure_type ; ats_ptr_type f_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_51 (((f_51_closure_type*)cloptr)->closure_env_0, ((f_51_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_51_closure_init (f_51_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_51_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_51_closure_make (ats_ptr_type env0, ats_int_type env1) { f_51_closure_type *p_clo = ATS_MALLOC(sizeof(f_51_closure_type)) ; f_51_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 27746(line=985, offs=10) -- 27924(line=989, offs=10) */ ATSstaticdec() ats_ptr_type f_52 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; __ats_lab_f_52: tmp459 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp458 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp459) ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lazy_delay (tmp458, env1, arg0) ; tmp457 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp457)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp457, atslab_0, tmp460) ; return (tmp457) ; } /* end of [f_52] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; } f_52_closure_type ; ats_ptr_type f_52_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_52 (((f_52_closure_type*)cloptr)->closure_env_0, ((f_52_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_52_closure_init (f_52_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_52_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_52_closure_make (ats_ptr_type env0, ats_int_type env1) { f_52_closure_type *p_clo = ATS_MALLOC(sizeof(f_52_closure_type)) ; f_52_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 28068(line=994, offs=10) -- 29025(line=1018, offs=14) */ ATSstaticdec() ats_ptr_type f_53 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; // ATSlocal_void (tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; // ATSlocal_void (tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; // ATSlocal_void (tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; // ATSlocal_void (tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; // ATSlocal_void (tmp479) ; // ATSlocal_void (tmp480) ; __ats_lab_f_53: tmp463 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp463)->tag != 50) { goto __ats_lab_128_0 ; } __ats_lab_125_1: tmp464 = ats_caselptrlab_mac(anairiats_sum_31, tmp463, atslab_0) ; tmp466 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (tmp464) ; do { /* branch: __ats_lab_126 */ __ats_lab_126_0: if (tmp466 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp467 = ats_caselptrlab_mac(anairiats_sum_4, tmp466, atslab_0) ; ATS_FREE(tmp466) ; tmp465 = tmp467 ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (tmp466 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: tmp469 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; /* tmp468 = */ prerr_loc_error1_0 (tmp469) ; /* tmp470 = */ atspre_prerr_string (ATSstrcst(": the file [")) ; /* tmp471 = */ atspre_prerr_string (tmp464) ; /* tmp472 = */ atspre_prerr_string (ATSstrcst("] is not available for dynamic loading")) ; /* tmp473 = */ atspre_prerr_newline () ; /* tmp465 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp475 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp474 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp475) ; tmp476 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_dynload (tmp474, tmp465) ; tmp462 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp462)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp462, atslab_0, tmp476) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: __ats_lab_128_1: tmp478 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; /* tmp477 = */ prerr_loc_error1_0 (tmp478) ; /* tmp479 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression must be a string constant")) ; /* tmp480 = */ atspre_prerr_newline () ; /* tmp462 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp462) ; } /* end of [f_53] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_53_closure_type ; ats_ptr_type f_53_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_53 (((f_53_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_53_closure_init (f_53_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_53_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_53_closure_make (ats_ptr_type env0) { f_53_closure_type *p_clo = ATS_MALLOC(sizeof(f_53_closure_type)) ; f_53_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 29202(line=1024, offs=10) -- 29376(line=1027, offs=12) */ ATSstaticdec() ats_ptr_type f_54 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; __ats_lab_f_54: tmp485 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp485) ; tmp486 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_effmask (tmp484, env1, arg0) ; tmp483 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp483)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp483, atslab_0, tmp486) ; return (tmp483) ; } /* end of [f_54] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } f_54_closure_type ; ats_ptr_type f_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_54 (((f_54_closure_type*)cloptr)->closure_env_0, ((f_54_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_54_closure_init (f_54_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_54_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_54_closure_make (ats_ptr_type env0, ats_ptr_type env1) { f_54_closure_type *p_clo = ATS_MALLOC(sizeof(f_54_closure_type)) ; f_54_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 31098(line=1077, offs=10) -- 31271(line=1080, offs=12) */ ATSstaticdec() ats_ptr_type f_55 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; __ats_lab_f_55: tmp534 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp534) ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_foldat (tmp533, env1, arg0) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp532)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp532, atslab_0, tmp535) ; return (tmp532) ; } /* end of [f_55] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } f_55_closure_type ; ats_ptr_type f_55_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_55 (((f_55_closure_type*)cloptr)->closure_env_0, ((f_55_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_55_closure_init (f_55_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_55_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_55_closure_make (ats_ptr_type env0, ats_ptr_type env1) { f_55_closure_type *p_clo = ATS_MALLOC(sizeof(f_55_closure_type)) ; f_55_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 31906(line=1098, offs=10) -- 32089(line=1102, offs=12) */ ATSstaticdec() ats_ptr_type f_56 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; __ats_lab_f_56: tmp554 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp553 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp554) ; tmp555 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_freeat (tmp553, env1, arg0) ; tmp552 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp552)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp552, atslab_0, tmp555) ; return (tmp552) ; } /* end of [f_56] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } f_56_closure_type ; ats_ptr_type f_56_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_56 (((f_56_closure_type*)cloptr)->closure_env_0, ((f_56_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_56_closure_init (f_56_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_56_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_56_closure_make (ats_ptr_type env0, ats_ptr_type env1) { f_56_closure_type *p_clo = ATS_MALLOC(sizeof(f_56_closure_type)) ; f_56_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 35355(line=1196, offs=10) -- 35523(line=1200, offs=10) */ ATSstaticdec() ats_ptr_type f_57 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; __ats_lab_f_57: tmp644 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp643 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp644) ; tmp645 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ptrof (tmp643, arg0) ; tmp642 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp642)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp642, atslab_0, tmp645) ; return (tmp642) ; } /* end of [f_57] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_57_closure_type ; ats_ptr_type f_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_57 (((f_57_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_57_closure_init (f_57_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_57_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_57_closure_make (ats_ptr_type env0) { f_57_closure_type *p_clo = ATS_MALLOC(sizeof(f_57_closure_type)) ; f_57_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 36337(line=1223, offs=10) -- 36511(line=1226, offs=12) */ ATSstaticdec() ats_ptr_type f_58 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; __ats_lab_f_58: tmp670 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp670, env0) ; tmp671 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel (tmp669, env1, arg0, env2) ; tmp668 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp668)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp668, atslab_0, tmp671) ; return (tmp668) ; } /* end of [f_58] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; ats_ptr_type closure_env_2 ; } f_58_closure_type ; ats_ptr_type f_58_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_58 (((f_58_closure_type*)cloptr)->closure_env_0, ((f_58_closure_type*)cloptr)->closure_env_1, ((f_58_closure_type*)cloptr)->closure_env_2, arg0) ; } /* end of function */ ATSinline() ats_void_type f_58_closure_init (f_58_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&f_58_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type f_58_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { f_58_closure_type *p_clo = ATS_MALLOC(sizeof(f_58_closure_type)) ; f_58_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 36757(line=1234, offs=10) -- 36931(line=1237, offs=12) */ ATSstaticdec() ats_ptr_type f_59 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; __ats_lab_f_59: tmp679 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp678 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp679, env0) ; tmp680 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel (tmp678, env1, arg0, env2) ; tmp677 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp677)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp677, atslab_0, tmp680) ; return (tmp677) ; } /* end of [f_59] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; ats_ptr_type closure_env_2 ; } f_59_closure_type ; ats_ptr_type f_59_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_59 (((f_59_closure_type*)cloptr)->closure_env_0, ((f_59_closure_type*)cloptr)->closure_env_1, ((f_59_closure_type*)cloptr)->closure_env_2, arg0) ; } /* end of function */ ATSinline() ats_void_type f_59_closure_init (f_59_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&f_59_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type f_59_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { f_59_closure_type *p_clo = ATS_MALLOC(sizeof(f_59_closure_type)) ; f_59_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 38927(line=1295, offs=10) -- 39094(line=1298, offs=12) */ ATSstaticdec() ats_ptr_type f_60 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; __ats_lab_f_60: tmp732 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d1exp_loc) ; tmp731 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp732) ; tmp733 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_viewat (tmp731, arg0) ; tmp730 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp730)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp730, atslab_0, tmp733) ; return (tmp730) ; } /* end of [f_60] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_60_closure_type ; ats_ptr_type f_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_60 (((f_60_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_60_closure_init (f_60_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_60_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_60_closure_make (ats_ptr_type env0) { f_60_closure_type *p_clo = ATS_MALLOC(sizeof(f_60_closure_type)) ; f_60_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24810(line=898, offs=5) -- 40191(line=1333, offs=4) */ ATSstaticdec() ats_ptr_type aux_item_49 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_int_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_char_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_int_type, tmp442) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_int_type, tmp456) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (anairiats_rec_33, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (anairiats_rec_0, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_int_type, tmp509) ; ATSlocal (ats_int_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_int_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_bool_type, tmp520) ; // ATSlocal_void (tmp521) ; ATSlocal (ats_int_type, tmp522) ; ATSlocal (ats_int_type, tmp523) ; ATSlocal (ats_bool_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_bool_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_int_type, tmp588) ; ATSlocal (anairiats_rec_33, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (anairiats_rec_0, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_int_type, tmp593) ; ATSlocal (ats_int_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_int_type, tmp596) ; ATSlocal (ats_bool_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_int_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; // ATSlocal_void (tmp608) ; // ATSlocal_void (tmp609) ; // ATSlocal_void (tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; // ATSlocal_void (tmp613) ; // ATSlocal_void (tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_int_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_int_type, tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_int_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_int_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_int_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_int_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_int_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_int_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp734) ; ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; // ATSlocal_void (tmp737) ; // ATSlocal_void (tmp738) ; // ATSlocal_void (tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; // ATSlocal_void (tmp742) ; // ATSlocal_void (tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; __ats_lab_aux_item_49: tmp390 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_d0exp_loc) ; tmp391 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_d0exp_node) ; do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp391)->tag != 0) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp393 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp394 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp392) ; tmp395 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp393) ; tmp396 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type (tmp390, tmp394, tmp395) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp396) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp391)->tag != 1) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp398 = aux_itemlst_50 (arg0) ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (tmp390, statmp256, tmp398) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_idextapp_resolve (tmp390, tmp397) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp399) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp391)->tag != 2) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp401 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp402 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp403 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp400) ; tmp404 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr (tmp401) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp402) ; tmp406 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrinit (tmp390, tmp403, tmp404, tmp405) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp406) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp391)->tag != 3) { goto __ats_lab_115_0 ; } __ats_lab_112_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp408 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp407) ; tmp410 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp408) ; tmp412 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp410), atslab_d1exp_node) ; do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp412)->tag != 36) { goto __ats_lab_114_0 ; } __ats_lab_113_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_11, tmp412, atslab_1) ; tmp411 = tmp413 ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp414 = (ats_sum_ptr_type)0 ; tmp411 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp411, atslab_0, tmp410) ; ats_selptrset_mac(anairiats_sum_2, tmp411, atslab_1, tmp414) ; break ; } while (0) ; tmp415 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrpsz (tmp390, tmp409, tmp411) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp415) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp391)->tag != 4) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp417 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp418 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp420 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, tmp416), atslab_arrqi0de_loc) ; tmp421 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, tmp416), atslab_arrqi0de_qua) ; tmp422 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, tmp416), atslab_arrqi0de_sym) ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (tmp420, tmp421, tmp422) ; tmp423 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr (tmp418) ; tmp424 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrsub (tmp390, tmp419, tmp417, tmp423) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp424) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp391)->tag != 5) { goto __ats_lab_119_0 ; } __ats_lab_116_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp427 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp428 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp425), atslab_casehead_knd) ; tmp430 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp425), atslab_casehead_inv) ; tmp429 = i0nvresstate_tr_39 (tmp430) ; tmp431 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp426) ; tmp433 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp431), atslab_d1exp_node) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)tmp433)->tag != 36) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp434 = ats_caselptrlab_mac(anairiats_sum_11, tmp433, atslab_1) ; tmp432 = tmp434 ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: __ats_lab_118_1: tmp435 = (ats_sum_ptr_type)0 ; tmp432 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp432, atslab_0, tmp431) ; ats_selptrset_mac(anairiats_sum_2, tmp432, atslab_1, tmp435) ; break ; } while (0) ; tmp436 = c0laulst_tr_44 (tmp427) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_caseof (tmp390, tmp428, tmp429, tmp432, tmp436) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp437) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)tmp391)->tag != 6) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_13, tmp391, atslab_0) ; tmp439 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char (tmp390, tmp438) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp439) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: if (((ats_sum_ptr_type)tmp391)->tag != 7) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp (tmp390, tmp440) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp441) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: if (((ats_sum_ptr_type)tmp391)->tag != 8) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp442 = ats_caselptrlab_mac(anairiats_sum_30, tmp391, atslab_0) ; tmp447 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp447)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp447, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__crypt_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp447, atslab_1, f_51_closure_make (tmp390, tmp442)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp447) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp391)->tag != 9) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp448 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; /* tmp449 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () ; /* tmp450 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc () ; /* tmp451 = ats_selsin_mac(tmp450, atslab_1) */ ; tmp452 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp448) ; /* tmp453 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec () ; /* tmp454 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop () ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_decseq (tmp390, tmp452) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp455) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp391)->tag != 10) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_30, tmp391, atslab_0) ; tmp461 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp461)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp461, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp461, atslab_1, f_52_closure_make (tmp390, tmp456)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp461) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp391)->tag != 11) { goto __ats_lab_129_0 ; } __ats_lab_124_1: tmp481 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp481)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp481, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__dynload_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp481, atslab_1, f_53_closure_make (tmp390)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp481) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp391)->tag != 12) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp482 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp487 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp487)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp487, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__delay_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp487, atslab_1, f_54_closure_make (tmp390, tmp482)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp487) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp391)->tag != 13) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp488 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty (tmp390) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp488) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp391)->tag != 14) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp490 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp491 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp492 = s0exparg_tr_29 (tmp489, tmp490) ; tmp493 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp491) ; tmp494 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_exist (tmp390, tmp492, tmp493) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp494) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp391)->tag != 15) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp495 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp496 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp497 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp495) ; tmp498 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_extval (tmp390, tmp497, tmp496) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp498) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp391)->tag != 16) { goto __ats_lab_136_0 ; } __ats_lab_133_1: tmp499 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_0) ; tmp500 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_1) ; tmp501 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_2) ; tmp502 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_3) ; tmp503 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_4) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_5) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (tmp503 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp506 = ats_caselptrlab_mac(anairiats_sum_4, tmp503, atslab_0) ; tmp507 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (tmp506) ; tmp508 = ats_select_mac(tmp507, atslab_0) ; tmp509 = ats_select_mac(tmp507, atslab_1) ; tmp510 = ats_select_mac(tmp507, atslab_2) ; tmp511 = ats_select_mac(tmp507, atslab_3) ; tmp512 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp512, atslab_0, tmp511) ; tmp505.atslab_0 = tmp508 ; tmp505.atslab_1 = tmp509 ; tmp505.atslab_2 = tmp512 ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (tmp503 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: tmp513 = (ats_sum_ptr_type)0 ; tmp514 = (ats_sum_ptr_type)0 ; tmp505.atslab_0 = tmp513 ; tmp505.atslab_1 = 0 ; tmp505.atslab_2 = tmp514 ; break ; } while (0) ; tmp515 = ats_select_mac(tmp505, atslab_0) ; tmp516 = ats_select_mac(tmp505, atslab_1) ; tmp517 = ats_select_mac(tmp505, atslab_2) ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp390) ; tmp518 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr (tmp499, tmp519, tmp515, tmp516, tmp501, tmp502, tmp517, tmp504) ; tmp520 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric (tmp518) ; /* tmp521 = */ termination_metric_check_36 (tmp390, tmp520, tmp517) ; tmp522 = lamkind_isat_32 (tmp499) ; tmp524 = atspre_gt_int_int (tmp522, 0) ; if (tmp524) { tmp523 = 0 ; } else { tmp523 = 1 ; } /* end of [if] */ tmp525 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_fix (tmp390, tmp523, tmp500, tmp518) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp525) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp391)->tag != 17) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp526 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp527 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float (tmp390, tmp526) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp527) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp391)->tag != 18) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp528 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp529 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_floatsp (tmp390, tmp528) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp529) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp391)->tag != 19) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp530 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp531 = s0expdarglst_tr_31 (tmp530) ; tmp536 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp536)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp536, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__foldat_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp536, atslab_1, f_55_closure_make (tmp390, tmp531)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp536) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp391)->tag != 20) { goto __ats_lab_142_0 ; } __ats_lab_139_1: tmp537 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_0) ; tmp538 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_1) ; tmp539 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_2) ; tmp540 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_3) ; tmp541 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_4) ; tmp542 = ats_caselptrlab_mac(anairiats_sum_32, tmp391, atslab_5) ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (tmp537 == (ats_sum_ptr_type)0) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp544 = ats_caselptrlab_mac(anairiats_sum_4, tmp537, atslab_0) ; tmp543 = loopi0nv_tr_40 (tmp538, tmp544) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: // if (tmp537 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_141_1: tmp543 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil (tmp538) ; break ; } while (0) ; tmp545 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp539) ; tmp546 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp540) ; tmp547 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp541) ; tmp548 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp542) ; tmp549 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_for (tmp390, tmp543, tmp545, tmp546, tmp547, tmp548) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp549) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp391)->tag != 21) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp550 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp551 = s0expdarglst_tr_31 (tmp550) ; tmp556 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp556)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp556, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__freeat_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp556, atslab_1, f_56_closure_make (tmp390, tmp551)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp556) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp391)->tag != 22) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp557 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp557, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; if (!tmp558) { goto __ats_lab_144_1 ; } tmp389 = statmp260 ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp391)->tag != 22) { goto __ats_lab_147_0 ; } __ats_lab_144_1: tmp559 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide (tmp390, tmp559) ; tmp561 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp559) ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (tmp561 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp562 = ats_caselptrlab_mac(anairiats_sum_4, tmp561, atslab_0) ; ATS_FREE(tmp561) ; tmp389 = d1exp_make_opr_24 (tmp560, tmp562) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: // if (tmp561 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_146_1: tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp560) ; break ; } while (0) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: if (((ats_sum_ptr_type)tmp391)->tag != 23) { goto __ats_lab_150_0 ; } __ats_lab_147_1: tmp563 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp564 = (ats_sum_ptr_type)0 ; tmp565 = (ats_sum_ptr_type)0 ; tmp566 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp (tmp390, tmp563, tmp564, tmp565) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp563) ; do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (tmp567 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp568 = ats_caselptrlab_mac(anairiats_sum_4, tmp567, atslab_0) ; ATS_FREE(tmp567) ; tmp389 = d1exp_make_opr_24 (tmp566, tmp568) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: // if (tmp567 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_149_1: tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp566) ; break ; } while (0) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)tmp391)->tag != 24) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp569 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_0) ; tmp570 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_1) ; tmp571 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_2) ; tmp572 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_3) ; tmp574 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, tmp569), atslab_ifhead_inv) ; tmp573 = i0nvresstate_tr_39 (tmp574) ; tmp575 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp570) ; tmp576 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp571) ; tmp577 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr (tmp572) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if (tmp390, tmp573, tmp575, tmp576, tmp577) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp578) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp391)->tag != 25) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp579 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp580 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int (tmp390, tmp579) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp580) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp391)->tag != 26) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp581 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_intsp (tmp390, tmp581) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp582) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: if (((ats_sum_ptr_type)tmp391)->tag != 27) { goto __ats_lab_156_0 ; } __ats_lab_153_1: tmp583 = ats_caselptrlab_mac(anairiats_sum_36, tmp391, atslab_0) ; tmp584 = ats_caselptrlab_mac(anairiats_sum_36, tmp391, atslab_1) ; tmp585 = ats_caselptrlab_mac(anairiats_sum_36, tmp391, atslab_2) ; tmp586 = ats_caselptrlab_mac(anairiats_sum_36, tmp391, atslab_3) ; tmp587 = ats_caselptrlab_mac(anairiats_sum_36, tmp391, atslab_4) ; tmp588 = lamkind_islin_33 (tmp583) ; do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (tmp586 == (ats_sum_ptr_type)0) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp590 = ats_caselptrlab_mac(anairiats_sum_4, tmp586, atslab_0) ; tmp591 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (tmp590) ; tmp592 = ats_select_mac(tmp591, atslab_0) ; tmp593 = ats_select_mac(tmp591, atslab_1) ; tmp594 = ats_select_mac(tmp591, atslab_2) ; tmp595 = ats_select_mac(tmp591, atslab_3) ; tmp597 = atspre_gt_int_int (tmp588, 0) ; if (tmp597) { tmp596 = 1 ; } else { tmp596 = tmp593 ; } /* end of [if] */ tmp598 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp598, atslab_0, tmp595) ; tmp589.atslab_0 = tmp592 ; tmp589.atslab_1 = tmp596 ; tmp589.atslab_2 = tmp598 ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: // if (tmp586 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_155_1: tmp599 = (ats_sum_ptr_type)0 ; tmp600 = (ats_sum_ptr_type)0 ; tmp589.atslab_0 = tmp599 ; tmp589.atslab_1 = tmp588 ; tmp589.atslab_2 = tmp600 ; break ; } while (0) ; tmp601 = ats_select_mac(tmp589, atslab_0) ; tmp602 = ats_select_mac(tmp589, atslab_1) ; tmp603 = ats_select_mac(tmp589, atslab_2) ; tmp605 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp605, atslab_0, tmp390) ; tmp604 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr (tmp583, tmp605, tmp601, tmp602, tmp584, tmp585, tmp603, tmp587) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp604) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp391)->tag != 28) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp606 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp607 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; /* tmp608 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () ; /* tmp609 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc () ; /* tmp610 = ats_selsin_mac(tmp609, atslab_1) */ ; tmp611 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp606) ; tmp612 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp607) ; /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec () ; /* tmp614 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop () ; tmp615 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_let (tmp390, tmp611, tmp612) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp615) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp391)->tag != 29) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp616 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp617 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp616) ; tmp618 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list (tmp390, tmp617) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp618) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp391)->tag != 30) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp619 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp620 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp621 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp619) ; tmp622 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp620) ; tmp623 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list2 (tmp390, tmp621, tmp622) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp623) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp391)->tag != 31) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_30, tmp391, atslab_0) ; tmp625 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn (tmp390, tmp624) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp625) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp391)->tag != 32) { goto __ats_lab_163_0 ; } __ats_lab_160_1: tmp626 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_0) ; tmp627 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_1) ; tmp628 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_2) ; tmp629 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp627) ; tmp630 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp628) ; tmp632 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp630), atslab_d1exp_node) ; do { /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp632)->tag != 36) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp633 = ats_caselptrlab_mac(anairiats_sum_11, tmp632, atslab_1) ; tmp631 = tmp633 ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: __ats_lab_162_1: tmp634 = (ats_sum_ptr_type)0 ; tmp631 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp631, atslab_0, tmp630) ; ats_selptrset_mac(anairiats_sum_2, tmp631, atslab_1, tmp634) ; break ; } while (0) ; tmp635 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lst (tmp390, tmp626, tmp629, tmp631) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp635) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp391)->tag != 33) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp636 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp637 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp639 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp637) ; tmp638 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_macsyn (tmp390, tmp636, tmp639) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp638) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: if (((ats_sum_ptr_type)tmp391)->tag != 34) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp640 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp641 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide (tmp390, tmp640) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp641) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: if (((ats_sum_ptr_type)tmp391)->tag != 35) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp646 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp646)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp646, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ptrof_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp646, atslab_1, f_57_closure_make (tmp390)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp646) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)tmp391)->tag != 36) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp647 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp648 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp649 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (tmp390, tmp647, tmp648) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp649) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp391)->tag != 37) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp650 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp652 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp650) ; tmp651 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_raise (tmp390, tmp652) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp651) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp391)->tag != 38) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp653 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_0) ; tmp654 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_1) ; tmp655 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr (tmp654) ; tmp656 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_rec (tmp390, tmp653, tmp655) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp656) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: if (((ats_sum_ptr_type)tmp391)->tag != 39) { goto __ats_lab_170_0 ; } __ats_lab_169_1: tmp657 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp658 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp659 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp661 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp657), atslab_casehead_inv) ; tmp660 = i0nvresstate_tr_39 (tmp661) ; tmp662 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp658) ; tmp663 = sc0laulst_tr_46 (tmp659) ; tmp664 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_scaseof (tmp390, tmp660, tmp662, tmp663) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp664) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp391)->tag != 40) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp665 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_0) ; tmp666 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_1) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_lab (tmp390, tmp666) ; tmp672 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp672)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp672, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ats_selptrset_mac(anairiats_sum_14, tmp672, atslab_1, f_58_closure_make (tmp390, tmp665, tmp667)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp672) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)tmp391)->tag != 41) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp673 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_0) ; tmp674 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_1) ; tmp675 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr (tmp674) ; tmp676 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_ind (tmp390, tmp675) ; tmp681 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp681)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp681, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ats_selptrset_mac(anairiats_sum_14, tmp681, atslab_1, f_59_closure_make (tmp390, tmp673, tmp676)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp681) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp391)->tag != 42) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp682 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp684 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp682) ; tmp683 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (tmp390, tmp684) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp683) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp391)->tag != 43) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp685 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp686 = s0exparg_tr_29 (tmp390, tmp685) ; tmp687 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sexparg (tmp390, tmp686) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp687) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp391)->tag != 44) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp688 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp688) ; tmp689 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_showtype (tmp390, tmp690) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp689) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp391)->tag != 45) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp691 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_0) ; tmp692 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_1) ; tmp693 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_2) ; tmp694 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_3) ; tmp696 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, tmp691), atslab_ifhead_inv) ; tmp695 = i0nvresstate_tr_39 (tmp696) ; tmp697 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp692) ; tmp698 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp693) ; tmp699 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp694) ; tmp700 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sif (tmp390, tmp695, tmp697, tmp698, tmp699) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp700) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp391)->tag != 46) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp701 = ats_caselptrlab_mac(anairiats_sum_31, tmp391, atslab_0) ; tmp702 = ats_caselptrlab_mac(anairiats_sum_31, tmp391, atslab_1) ; tmp703 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string (tmp390, tmp701, tmp702) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp703) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp391)->tag != 47) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp704 = ats_caselptrlab_mac(anairiats_sum_1, tmp391, atslab_0) ; tmp705 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr (tmp704) ; tmp706 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_struct (tmp390, tmp705) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp706) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)tmp391)->tag != 48) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp707 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp708 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; tmp709 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr (tmp708) ; tmp710 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tmpid (tmp390, tmp707, tmp709) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp710) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp391)->tag != 49) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp711 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_top (tmp390) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp711) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)tmp391)->tag != 50) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp712 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_0) ; tmp713 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_1) ; tmp714 = ats_caselptrlab_mac(anairiats_sum_16, tmp391, atslab_2) ; tmp716 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, tmp712), atslab_tryhead_inv) ; tmp715 = i0nvresstate_tr_39 (tmp716) ; tmp717 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp713) ; tmp718 = c0laulst_tr_44 (tmp714) ; tmp719 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_trywith (tmp390, tmp715, tmp717, tmp718) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp719) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp391)->tag != 51) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp720 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_0) ; tmp721 = ats_caselptrlab_mac(anairiats_sum_11, tmp391, atslab_1) ; tmp722 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp721) ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup (tmp390, tmp720, tmp722) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp723) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp391)->tag != 52) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp724 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_0) ; tmp725 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_1) ; tmp726 = ats_caselptrlab_mac(anairiats_sum_15, tmp391, atslab_2) ; tmp727 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp725) ; tmp728 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (tmp726) ; tmp729 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup2 (tmp390, tmp724, tmp727, tmp728) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp729) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: if (((ats_sum_ptr_type)tmp391)->tag != 53) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp734 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp734)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp734, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__viewat_prec_dyn) ; ats_selptrset_mac(anairiats_sum_14, tmp734, atslab_1, f_60_closure_make (tmp390)) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp734) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp391)->tag != 54) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp735 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_0) ; tmp736 = ats_caselptrlab_mac(anairiats_sum_8, tmp391, atslab_1) ; /* tmp737 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () ; /* tmp738 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc () ; /* tmp739 = ats_selsin_mac(tmp738, atslab_1) */ ; tmp740 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp736) ; tmp741 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp735) ; /* tmp742 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec () ; /* tmp743 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop () ; tmp744 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_where (tmp390, tmp741, tmp740) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp744) ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: // if (((ats_sum_ptr_type)tmp391)->tag != 55) { ats_deadcode_failure_handle () ; } __ats_lab_185_1: tmp745 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_0) ; tmp746 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_1) ; tmp747 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_2) ; tmp748 = ats_caselptrlab_mac(anairiats_sum_34, tmp391, atslab_3) ; do { /* branch: __ats_lab_186 */ __ats_lab_186_0: if (tmp745 == (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_186_1: tmp750 = ats_caselptrlab_mac(anairiats_sum_4, tmp745, atslab_0) ; tmp749 = loopi0nv_tr_40 (tmp746, tmp750) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: // if (tmp745 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_187_1: tmp749 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil (tmp746) ; break ; } while (0) ; tmp751 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp747) ; tmp752 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp748) ; tmp753 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while (tmp390, tmp749, tmp751, tmp752) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, tmp753) ; break ; } while (0) ; return (tmp389) ; } /* end of [aux_item_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 40271(line=1336, offs=7) -- 40504(line=1341, offs=32) */ ATSstaticdec() ats_ptr_type aux_61 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; __ats_lab_aux_61: tmp756 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_d0exp_node) ; do { /* branch: __ats_lab_188 */ __ats_lab_188_0: if (((ats_sum_ptr_type)tmp756)->tag != 1) { goto __ats_lab_189_0 ; } __ats_lab_188_1: tmp757 = ats_caselptrlab_mac(anairiats_sum_8, tmp756, atslab_0) ; tmp758 = ats_caselptrlab_mac(anairiats_sum_8, tmp756, atslab_1) ; tmp760 = aux_item_49 (tmp758) ; tmp759 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp759, atslab_0, tmp760) ; ats_selptrset_mac(anairiats_sum_2, tmp759, atslab_1, arg0) ; arg0 = tmp759 ; arg1 = tmp757 ; goto __ats_lab_aux_61 ; // tail call break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: __ats_lab_189_1: tmp761 = aux_item_49 (arg1) ; tmp755 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp755, atslab_0, tmp761) ; ats_selptrset_mac(anairiats_sum_2, tmp755, atslab_1, arg0) ; break ; } while (0) ; return (tmp755) ; } /* end of [aux_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 40220(line=1335, offs=5) -- 40550(line=1345, offs=4) */ ATSstaticdec() ats_ptr_type aux_itemlst_50 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp762) ; __ats_lab_aux_itemlst_50: tmp762 = (ats_sum_ptr_type)0 ; tmp754 = aux_61 (tmp762, arg0) ; return (tmp754) ; } /* end of [aux_itemlst_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 24566(line=887, offs=10) -- 40677(line=1351, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr: tmp763 = aux_item_49 (arg0) ; do { /* branch: __ats_lab_190 */ __ats_lab_190_0: if (((ats_sum_ptr_type)tmp763)->tag != 0) { goto __ats_lab_191_0 ; } __ats_lab_190_1: tmp764 = ats_caselptrlab_mac(anairiats_sum_1, tmp763, atslab_0) ; tmp383 = tmp764 ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: // if (((ats_sum_ptr_type)tmp763)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_191_1: tmp383 = opr_errmsg_48 (arg0) ; break ; } while (0) ; return (tmp383) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 40722(line=1354, offs=13) -- 40768(line=1355, offs=37) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp765) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr: tmp765 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr) ; return (tmp765) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 40819(line=1359, offs=16) -- 40869(line=1360, offs=41) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp766) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr: tmp766 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explst_tr) ; return (tmp766) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0explstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 40923(line=1364, offs=16) -- 41089(line=1367, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr: do { /* branch: __ats_lab_192 */ __ats_lab_192_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp768 = ats_caselptrlab_mac(anairiats_sum_38, arg0, atslab_0) ; tmp769 = ats_caselptrlab_mac(anairiats_sum_38, arg0, atslab_1) ; tmp770 = ats_caselptrlab_mac(anairiats_sum_38, arg0, atslab_2) ; tmp771 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp769) ; tmp772 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr (tmp770) ; tmp767 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ats_selptrset_mac(anairiats_sum_38, tmp767, atslab_0, tmp768) ; ats_selptrset_mac(anairiats_sum_38, tmp767, atslab_1, tmp771) ; ats_selptrset_mac(anairiats_sum_38, tmp767, atslab_2, tmp772) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_193_1: tmp767 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp767) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labd0explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 41140(line=1371, offs=13) -- 41219(line=1372, offs=57) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr: do { /* branch: __ats_lab_194 */ __ats_lab_194_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp774 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp775 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp774) ; tmp773 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp773, atslab_0, tmp775) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_195_1: tmp773 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp773) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 41322(line=1381, offs=4) -- 41628(line=1393, offs=4) */ ATSstaticdec() ats_ptr_type v0aldec_tr_66 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (ats_ptr_type, tmp783) ; __ats_lab_v0aldec_tr_66: tmp778 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_v0aldec_pat) ; tmp777 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__p0at_tr (tmp778) ; tmp780 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_v0aldec_def) ; tmp779 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp780) ; tmp782 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_v0aldec_ann) ; tmp781 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr (tmp782) ; tmp783 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_v0aldec_loc) ; tmp776 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1aldec_make (tmp783, tmp777, tmp779, tmp781) ; return (tmp776) ; } /* end of [v0aldec_tr_66] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 41656(line=1395, offs=4) -- 41737(line=1396, offs=68) */ ATSstaticdec() ats_ptr_type v0aldeclst_tr_67 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp784) ; __ats_lab_v0aldeclst_tr_67: tmp784 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &v0aldec_tr_66) ; return (tmp784) ; } /* end of [v0aldeclst_tr_67] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 41789(line=1401, offs=4) -- 42734(line=1433, offs=4) */ ATSstaticdec() ats_ptr_type f0undec_tr_68 (ats_bool_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (anairiats_rec_41, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (anairiats_rec_0, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_int_type, tmp792) ; ATSlocal (ats_int_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; // ATSlocal_void (tmp807) ; ATSlocal (ats_bool_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; __ats_lab_f0undec_tr_68: tmp786 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_loc) ; tmp787 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_eff) ; do { /* branch: __ats_lab_196 */ __ats_lab_196_0: if (tmp787 == (ats_sum_ptr_type)0) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp789 = ats_caselptrlab_mac(anairiats_sum_4, tmp787, atslab_0) ; tmp790 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (tmp789) ; tmp791 = ats_select_mac(tmp790, atslab_0) ; tmp792 = ats_select_mac(tmp790, atslab_1) ; tmp793 = ats_select_mac(tmp790, atslab_2) ; tmp794 = ats_select_mac(tmp790, atslab_3) ; tmp795 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp795, atslab_0, tmp794) ; tmp788.atslab_0 = tmp791 ; tmp788.atslab_1 = tmp795 ; break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: // if (tmp787 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_197_1: if (arg0) { tmp796 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; } else { tmp796 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; } /* end of [if] */ tmp797 = (ats_sum_ptr_type)0 ; tmp798 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp798, atslab_0, tmp796) ; tmp788.atslab_0 = tmp797 ; tmp788.atslab_1 = tmp798 ; break ; } while (0) ; tmp799 = ats_select_mac(tmp788, atslab_0) ; tmp800 = ats_select_mac(tmp788, atslab_1) ; tmp802 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp802)->tag = 6 ; ats_selptrset_mac(anairiats_sum_1, tmp802, atslab_0, tmp786) ; tmp803 = (ats_sum_ptr_type)0 ; tmp804 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_arg) ; tmp805 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_res) ; tmp806 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_def) ; tmp801 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr (tmp802, tmp803, tmp799, 0, tmp804, tmp805, tmp800, tmp806) ; if (arg1) { tmp808 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric (tmp801) ; /* tmp807 = */ termination_metric_check_36 (tmp786, tmp808, tmp800) ; } else { /* empty */ } /* end of [if] */ tmp810 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_ann) ; tmp809 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr (tmp810) ; tmp811 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_sym) ; tmp812 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg2), atslab_f0undec_sym_loc) ; tmp785 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__f1undec_make (tmp786, tmp811, tmp812, tmp801, tmp809) ; return (tmp785) ; } /* end of [f0undec_tr_68] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 42763(line=1435, offs=5) -- 43052(line=1445, offs=4) */ ATSstaticdec() ats_ptr_type f0undeclst_tr_69 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_bool_type, tmp814) ; ATSlocal (ats_bool_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; __ats_lab_f0undeclst_tr_69: tmp814 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof (arg0) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive (arg0) ; do { /* branch: __ats_lab_198 */ __ats_lab_198_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp816 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp817 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp818 = f0undec_tr_68 (tmp814, tmp815, tmp816) ; tmp819 = f0undeclst_tr_69 (arg0, tmp817) ; tmp813 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp813, atslab_0, tmp818) ; ats_selptrset_mac(anairiats_sum_2, tmp813, atslab_1, tmp819) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_199_1: tmp813 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp813) ; } /* end of [f0undeclst_tr_69] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 43104(line=1449, offs=4) -- 43428(line=1460, offs=4) */ ATSstaticdec() ats_ptr_type v0ardec_tr_70 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_int_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; __ats_lab_v0ardec_tr_70: tmp821 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_loc) ; tmp822 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_knd) ; tmp824 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_typ) ; tmp823 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp824) ; tmp825 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_wth) ; tmp827 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_ini) ; tmp826 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0expopt_tr (tmp827) ; tmp828 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_sym) ; tmp829 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_v0ardec_sym_loc) ; tmp820 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1ardec_make (tmp821, tmp822, tmp828, tmp829, tmp823, tmp825, tmp826) ; return (tmp820) ; } /* end of [v0ardec_tr_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 43456(line=1462, offs=4) -- 43537(line=1463, offs=68) */ ATSstaticdec() ats_ptr_type v0ardeclst_tr_71 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp830) ; __ats_lab_v0ardeclst_tr_71: tmp830 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &v0ardec_tr_70) ; return (tmp830) ; } /* end of [v0ardeclst_tr_71] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 43589(line=1468, offs=4) -- 43770(line=1475, offs=4) */ ATSstaticdec() ats_ptr_type m0acdef_tr_72 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; __ats_lab_m0acdef_tr_72: tmp833 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg0), atslab_m0acdef_def) ; tmp832 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp833) ; tmp834 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg0), atslab_m0acdef_loc) ; tmp835 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg0), atslab_m0acdef_sym) ; tmp836 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg0), atslab_m0acdef_arg) ; tmp831 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1acdef_make (tmp834, tmp835, tmp836, tmp832) ; return (tmp831) ; } /* end of [m0acdef_tr_72] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 43798(line=1477, offs=4) -- 43879(line=1478, offs=68) */ ATSstaticdec() ats_ptr_type m0acdeflst_tr_73 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp837) ; __ats_lab_m0acdeflst_tr_73: tmp837 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &m0acdef_tr_72) ; return (tmp837) ; } /* end of [m0acdeflst_tr_73] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 44116(line=1489, offs=9) -- 44296(line=1491, offs=44) */ ATSstaticdec() ats_ptr_type aux_75 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; __ats_lab_aux_75: do { /* branch: __ats_lab_200 */ __ats_lab_200_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp844 = ats_caselptrlab_mac(anairiats_sum_38, arg0, atslab_1) ; tmp845 = ats_caselptrlab_mac(anairiats_sum_38, arg0, atslab_2) ; tmp846 = aux_75 (tmp845) ; tmp843 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp843, atslab_0, tmp844) ; ats_selptrset_mac(anairiats_sum_2, tmp843, atslab_1, tmp846) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_201_1: tmp843 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp843) ; } /* end of [aux_75] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 43931(line=1483, offs=4) -- 44616(line=1504, offs=4) */ ATSstaticdec() ats_ptr_type i0mpdec_tr_74 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; __ats_lab_i0mpdec_tr_74: tmp839 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_loc) ; tmp840 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_qid) ; tmp842 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_45, tmp840), atslab_impqi0de_arg) ; tmp841 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr (tmp842) ; tmp847 = aux_75 (tmp841) ; tmp849 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp849)->tag = 6 ; ats_selptrset_mac(anairiats_sum_1, tmp849, atslab_0, tmp839) ; tmp850 = (ats_sum_ptr_type)0 ; tmp851 = (ats_sum_ptr_type)0 ; tmp852 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_arg) ; tmp853 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_res) ; tmp854 = (ats_sum_ptr_type)0 ; tmp855 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_def) ; tmp848 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_lams_dyn_tr (tmp849, tmp850, tmp851, 0, tmp852, tmp853, tmp854, tmp855) ; tmp856 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_i0mpdec_loc) ; tmp838 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1mpdec_make (tmp856, tmp840, tmp847, tmp848) ; return (tmp838) ; } /* end of [i0mpdec_tr_74] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 44729(line=1510, offs=7) -- 45439(line=1528, offs=10) */ ATSstaticdec() ats_ptr_type loop_77 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_bool_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_ptr_type, tmp867) ; ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_bool_type, tmp869) ; ATSlocal (ats_ptr_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_bool_type, tmp876) ; __ats_lab_loop_77: do { /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_203_0 ; } __ats_lab_202_1: tmp859 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp860 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp862 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp859) ; tmp861 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if (arg0, tmp862) ; tmp863 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (tmp861) ; if (tmp863) { tmp858 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp860) ; } else { tmp858 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp864 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_0) ; tmp865 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_1) ; tmp866 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_2) ; tmp868 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp864) ; tmp867 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if (arg0, tmp868) ; tmp869 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (tmp867) ; if (tmp869) { tmp858 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp865) ; } else { tmp858 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp866) ; } /* end of [if] */ break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_204_1: tmp870 = ats_caselptrlab_mac(anairiats_sum_34, arg1, atslab_0) ; tmp871 = ats_caselptrlab_mac(anairiats_sum_34, arg1, atslab_1) ; tmp872 = ats_caselptrlab_mac(anairiats_sum_34, arg1, atslab_2) ; tmp873 = ats_caselptrlab_mac(anairiats_sum_34, arg1, atslab_3) ; tmp875 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp870) ; tmp874 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if (arg0, tmp875) ; tmp876 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (tmp874) ; if (tmp876) { tmp858 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp871) ; } else { arg0 = tmp872 ; arg1 = tmp873 ; goto __ats_lab_loop_77 ; // tail call } /* end of [if] */ break ; } while (0) ; return (tmp858) ; } /* end of [loop_77] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 44665(line=1508, offs=4) -- 45516(line=1532, offs=4) */ ATSstaticdec() ats_ptr_type guad0ec_tr_76 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp877) ; __ats_lab_guad0ec_tr_76: tmp877 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_46, arg1), atslab_guad0ec_node) ; tmp857 = loop_77 (arg0, tmp877) ; return (tmp857) ; } /* end of [guad0ec_tr_76] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 45565(line=1536, offs=4) -- 45757(line=1541, offs=4) */ ATSstaticdec() ats_void_type the_filenamelst_push_xit_78 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp878) ; __ats_lab_the_filenamelst_push_xit_78: /* tmp878 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push_xit (ats_castfn_mac(ats_ptr_type, arg0), arg1) ; return /* (tmp878) */ ; } /* end of [the_filenamelst_push_xit_78] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 45824(line=1545, offs=4) -- 47112(line=1590, offs=4) */ ATSstaticdec() ats_ptr_type i0nclude_tr_79 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp879) ; // ATSlocal_void (tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_int_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_bool_type, tmp884) ; // ATSlocal_void (tmp885) ; // ATSlocal_void (tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; // ATSlocal_void (tmp888) ; // ATSlocal_void (tmp889) ; // ATSlocal_void (tmp890) ; // ATSlocal_void (tmp891) ; // ATSlocal_void (tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; // ATSlocal_void (tmp894) ; __ats_lab_i0nclude_tr_79: /* tmp880 = */ the_filenamelst_push_xit_78 (arg0, arg2) ; tmp881 = atsopt_filename_full (arg2) ; tmp882 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get () ; tmp883 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if (tmp881) ; tmp884 = atspre_stropt_is_some (tmp883) ; if (tmp884) { /* tmp886 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push () ; /* tmp885 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable () ; } else { /* empty */ } /* end of [if] */ tmp887 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst (arg1, arg2) ; if (tmp884) { /* tmp889 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp887) ; /* tmp890 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (ats_true_bool, tmp881, tmp883) ; /* tmp891 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; /* tmp888 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop () ; } else { /* empty */ } /* end of [if] */ /* tmp892 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set (tmp882) ; tmp893 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp887) ; /* tmp894 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop () ; tmp879 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_include (arg0, tmp893) ; return (tmp879) ; } /* end of [i0nclude_tr_79] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 47596(line=1615, offs=4) -- 50011(line=1689, offs=4) */ ATSstaticdec() ats_ptr_type s0taload_tr_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_int_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (anairiats_rec_47, tmp900) ; ATSlocal (ats_int_type, tmp901) ; // ATSlocal_void (tmp902) ; ATSlocal (ats_int_type, tmp903) ; ATSlocal (ats_bool_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_bool_type, tmp906) ; // ATSlocal_void (tmp907) ; // ATSlocal_void (tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; // ATSlocal_void (tmp910) ; // ATSlocal_void (tmp911) ; // ATSlocal_void (tmp912) ; // ATSlocal_void (tmp913) ; // ATSlocal_void (tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; ATSlocal (ats_bool_type, tmp920) ; // ATSlocal_void (tmp921) ; // ATSlocal_void (tmp922) ; // ATSlocal_void (tmp923) ; __ats_lab_s0taload_tr_80: tmp896 = atsopt_filename_full (arg2) ; tmp897 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_search (tmp896) ; /* ats_int_type tmp898 ; */ tmp898 = 1 ; do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (tmp897 == (ats_sum_ptr_type)0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp900 = ats_caselptrlab_mac(anairiats_sum_48, tmp897, atslab_0) ; ATS_FREE(tmp897) ; tmp901 = ats_select_mac(tmp900, atslab_0) ; tmp898 = tmp901 ; tmp899 = ats_select_mac(tmp900, atslab_1) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: // if (tmp897 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_206_1: /* tmp902 = */ the_filenamelst_push_xit_78 (arg0, arg2) ; tmp904 = atsopt_string_suffix_is_dats (tmp896) ; if (tmp904) { tmp903 = 1 ; } else { tmp903 = 0 ; } /* end of [if] */ tmp905 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if (tmp896) ; tmp906 = atspre_stropt_is_some (tmp905) ; if (tmp906) { /* tmp908 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push () ; /* tmp907 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable () ; } else { /* empty */ } /* end of [if] */ tmp909 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst (tmp903, arg2) ; if (tmp906) { /* tmp911 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp909) ; /* tmp912 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (ats_true_bool, tmp896, tmp905) ; /* tmp913 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; /* tmp910 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop () ; } else { /* empty */ } /* end of [if] */ /* tmp914 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_save () ; tmp915 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp909) ; tmp917 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_STALOADFLAG) ; do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (tmp917 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp918 = ats_caselptrlab_mac(anairiats_sum_4, tmp917, atslab_0) ; ATS_FREE(tmp917) ; tmp919 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp918) ; tmp920 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_false (tmp919) ; if (tmp920) { tmp898 = 0 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: // if (tmp917 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_208_1: break ; } while (0) ; /* tmp921 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_restore () ; /* tmp922 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop () ; /* tmp923 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert (tmp896, tmp898, tmp915) ; tmp899 = tmp915 ; break ; } while (0) ; tmp895 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_staload (arg0, arg1, arg2, tmp898, tmp899) ; return (tmp895) ; } /* end of [s0taload_tr_80] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 50076(line=1694, offs=9) -- 57960(line=1912, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp924) ; ATSlocal (ats_ptr_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; // ATSlocal_void (tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; // ATSlocal_void (tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; // ATSlocal_void (tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; // ATSlocal_void (tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_ptr_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; // ATSlocal_void (tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; ATSlocal (ats_int_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_ptr_type, tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; ATSlocal (ats_ptr_type, tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; ATSlocal (ats_ptr_type, tmp992) ; ATSlocal (ats_ptr_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_ptr_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; ATSlocal (ats_bool_type, tmp1015) ; ATSlocal (ats_bool_type, tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; ATSlocal (ats_ptr_type, tmp1019) ; ATSlocal (ats_ptr_type, tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; ATSlocal (ats_ptr_type, tmp1023) ; ATSlocal (ats_ptr_type, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; ATSlocal (ats_ptr_type, tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (ats_int_type, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; ATSlocal (ats_ptr_type, tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_ptr_type, tmp1042) ; ATSlocal (ats_ptr_type, tmp1043) ; ATSlocal (ats_ptr_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; ATSlocal (ats_ptr_type, tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; ATSlocal (ats_ptr_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_ptr_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_ptr_type, tmp1060) ; ATSlocal (ats_ptr_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; ATSlocal (ats_ptr_type, tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_int_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_ptr_type, tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; ATSlocal (ats_ptr_type, tmp1088) ; // ATSlocal_void (tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; // ATSlocal_void (tmp1091) ; // ATSlocal_void (tmp1092) ; // ATSlocal_void (tmp1093) ; // ATSlocal_void (tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_ptr_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; // ATSlocal_void (tmp1101) ; ATSlocal (ats_ptr_type, tmp1102) ; // ATSlocal_void (tmp1103) ; // ATSlocal_void (tmp1104) ; // ATSlocal_void (tmp1105) ; // ATSlocal_void (tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; ATSlocal (ats_ptr_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; // ATSlocal_void (tmp1110) ; // ATSlocal_void (tmp1111) ; // ATSlocal_void (tmp1112) ; ATSlocal (ats_ptr_type, tmp1113) ; // ATSlocal_void (tmp1114) ; // ATSlocal_void (tmp1115) ; ATSlocal (ats_ptr_type, tmp1116) ; // ATSlocal_void (tmp1117) ; ATSlocal (ats_ptr_type, tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; ATSlocal (ats_ptr_type, tmp1120) ; ATSlocal (ats_ptr_type, tmp1121) ; ATSlocal (ats_ptr_type, tmp1122) ; ATSlocal (ats_int_type, tmp1123) ; ATSlocal (ats_ptr_type, tmp1124) ; ATSlocal (ats_ptr_type, tmp1125) ; ATSlocal (ats_ptr_type, tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; // ATSlocal_void (tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; // ATSlocal_void (tmp1130) ; // ATSlocal_void (tmp1131) ; // ATSlocal_void (tmp1132) ; // ATSlocal_void (tmp1133) ; ATSlocal (ats_ptr_type, tmp1134) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_tr: tmp925 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_node) ; do { /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)tmp925)->tag != 0) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp926 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp927 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; /* tmp928 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_fixity_tr (tmp926, tmp927) ; tmp929 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none (tmp929) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)tmp925)->tag != 1) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp930 = ats_caselptrlab_mac(anairiats_sum_1, tmp925, atslab_0) ; /* tmp931 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_nonfix_tr (tmp930) ; tmp932 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none (tmp932) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp925)->tag != 3) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp933 = ats_caselptrlab_mac(anairiats_sum_1, tmp925, atslab_0) ; tmp934 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symintr (tmp934, tmp933) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp925)->tag != 5) { goto __ats_lab_215_0 ; } __ats_lab_212_1: tmp935 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp936 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp937 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; do { /* branch: __ats_lab_213 */ __ats_lab_213_0: if (tmp936 == (ats_sum_ptr_type)0) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp939 = ats_caselptrlab_mac(anairiats_sum_4, tmp936, atslab_0) ; tmp938 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp939) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: // if (tmp936 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_214_1: tmp938 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none (tmp937) ; break ; } while (0) ; /* tmp940 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add (tmp935, tmp938) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef (tmp937, tmp935, tmp938) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp925)->tag != 4) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp941 = ats_caselptrlab_mac(anairiats_sum_1, tmp925, atslab_0) ; tmp942 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp943 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_undef (tmp942) ; /* tmp944 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add (tmp941, tmp943) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef (tmp942, tmp941, tmp943) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp925)->tag != 6) { goto __ats_lab_220_0 ; } __ats_lab_216_1: tmp945 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp946 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp947 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp946) ; tmp948 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp947) ; do { /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp945)->tag != 0) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp950 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_50, tmp946), atslab_e0xp_loc) ; /* tmp949 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_assert (tmp950, tmp948) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp945)->tag != 1) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp951 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_50, tmp946), atslab_e0xp_loc) ; /* tmp949 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_error (tmp951, tmp948) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: // if (((ats_sum_ptr_type)tmp945)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_219_1: /* tmp949 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_prerr (tmp948) ; break ; } while (0) ; tmp952 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none (tmp952) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp925)->tag != 7) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp953 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_0) ; tmp954 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_1) ; tmp955 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_2) ; tmp956 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr (tmp954) ; tmp957 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdeclst_tr (tmp955) ; tmp958 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp959 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp959, atslab_0, tmp956) ; ats_selptrset_mac(anairiats_sum_2, tmp959, atslab_1, tmp957) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datsrts (tmp958, tmp953, tmp959) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp925)->tag != 8) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp960 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp961 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp962 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr (tmp960) ; tmp963 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdeflst_tr (tmp961) ; tmp964 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp965 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp965, atslab_0, tmp962) ; ats_selptrset_mac(anairiats_sum_2, tmp965, atslab_1, tmp963) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_srtdefs (tmp964, tmp965) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp925)->tag != 9) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp966 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_0) ; tmp967 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_1) ; tmp968 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_2) ; tmp969 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr (tmp967) ; tmp970 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0taconlst_tr (tmp968) ; tmp971 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp972 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp972, atslab_0, tmp969) ; ats_selptrset_mac(anairiats_sum_2, tmp972, atslab_1, tmp970) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacons (tmp971, tmp966, tmp972) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: if (((ats_sum_ptr_type)tmp925)->tag != 10) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp973 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp974 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp975 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr (tmp973) ; tmp976 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacstlst_tr (tmp974) ; tmp977 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp978 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp978, atslab_0, tmp975) ; ats_selptrset_mac(anairiats_sum_2, tmp978, atslab_1, tmp976) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacsts (tmp977, tmp978) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: if (((ats_sum_ptr_type)tmp925)->tag != 11) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp979 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp980 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp981 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr (tmp979) ; tmp982 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavarlst_tr (tmp980) ; tmp983 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp984 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp984, atslab_0, tmp981) ; ats_selptrset_mac(anairiats_sum_2, tmp984, atslab_1, tmp982) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stavars (tmp983, tmp984) ; break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: if (((ats_sum_ptr_type)tmp925)->tag != 12) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp985 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_0) ; tmp986 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_1) ; tmp987 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_2) ; tmp988 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (tmp985) ; tmp989 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr (tmp986) ; tmp990 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr (tmp987) ; tmp991 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp992 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp992, atslab_0, tmp989) ; ats_selptrset_mac(anairiats_sum_2, tmp992, atslab_1, tmp990) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_sexpdefs (tmp991, tmp988, tmp992) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: if (((ats_sum_ptr_type)tmp925)->tag != 13) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp993 = ats_caselptrlab_mac(anairiats_sum_1, tmp925, atslab_0) ; tmp994 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp995 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0aspdec_tr (tmp993) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_saspdec (tmp994, tmp995) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: if (((ats_sum_ptr_type)tmp925)->tag != 15) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp996 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_0) ; tmp997 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_1) ; tmp998 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_2) ; tmp999 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_3) ; tmp1000 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr (tmp997) ; tmp1001 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr (tmp998) ; tmp1002 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr (tmp999) ; tmp1003 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1004 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1004, atslab_0, tmp1000) ; ats_selptrset_mac(anairiats_sum_2, tmp1004, atslab_1, tmp1001) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datdecs (tmp1003, tmp996, tmp1004, tmp1002) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: if (((ats_sum_ptr_type)tmp925)->tag != 16) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp1005 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1006 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1007 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr (tmp1005) ; tmp1008 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndeclst_tr (tmp1006) ; tmp1009 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1010 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1010, atslab_0, tmp1007) ; ats_selptrset_mac(anairiats_sum_2, tmp1010, atslab_1, tmp1008) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_exndecs (tmp1009, tmp1010) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: if (((ats_sum_ptr_type)tmp925)->tag != 14) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp1011 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_0) ; tmp1012 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_1) ; tmp1013 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_2) ; tmp1014 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_3) ; tmp1015 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun (tmp1011) ; tmp1016 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (tmp1011) ; tmp1017 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr (tmp1012) ; tmp1018 = d0cstdec_tr_6 (tmp1015, tmp1016, tmp1013) ; tmp1019 = d0cstdeclst_tr_7 (tmp1015, tmp1016, tmp1014) ; tmp1020 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1021 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1021, atslab_0, tmp1018) ; ats_selptrset_mac(anairiats_sum_2, tmp1021, atslab_1, tmp1019) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dcstdecs (tmp1020, tmp1011, tmp1017, tmp1021) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: if (((ats_sum_ptr_type)tmp925)->tag != 17) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp1022 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1023 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1024 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp1023) ; tmp1025 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_classdec (tmp1025, tmp1022, tmp1024) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: if (((ats_sum_ptr_type)tmp925)->tag != 18) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp1026 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1027 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1028 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_overload (tmp1028, tmp1026, tmp1027) ; break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: if (((ats_sum_ptr_type)tmp925)->tag != 19) { goto __ats_lab_233_0 ; } __ats_lab_232_1: tmp1029 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1030 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1031 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1032 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp1030) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extype (tmp1031, tmp1029, tmp1032) ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)tmp925)->tag != 20) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp1033 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1034 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1035 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1036 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0exp_tr (tmp1034) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extval (tmp1035, tmp1033, tmp1036) ; break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: if (((ats_sum_ptr_type)tmp925)->tag != 21) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp1037 = ats_caselptrlab_mac(anairiats_sum_11, tmp925, atslab_0) ; tmp1038 = ats_caselptrlab_mac(anairiats_sum_11, tmp925, atslab_1) ; tmp1039 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extcode (tmp1039, tmp1037, tmp1038) ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: if (((ats_sum_ptr_type)tmp925)->tag != 22) { goto __ats_lab_236_0 ; } __ats_lab_235_1: tmp1040 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_0) ; tmp1041 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_1) ; tmp1042 = ats_caselptrlab_mac(anairiats_sum_16, tmp925, atslab_2) ; tmp1043 = v0aldec_tr_66 (tmp1041) ; tmp1044 = v0aldeclst_tr_67 (tmp1042) ; tmp1045 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1046 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1046, atslab_0, tmp1043) ; ats_selptrset_mac(anairiats_sum_2, tmp1046, atslab_1, tmp1044) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs (tmp1045, tmp1040, tmp1046) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)tmp925)->tag != 23) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp1047 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1048 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1049 = v0aldec_tr_66 (tmp1047) ; tmp1050 = v0aldeclst_tr_67 (tmp1048) ; tmp1051 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1052 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1052, atslab_0, tmp1049) ; ats_selptrset_mac(anairiats_sum_2, tmp1052, atslab_1, tmp1050) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_par (tmp1051, tmp1052) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: if (((ats_sum_ptr_type)tmp925)->tag != 24) { goto __ats_lab_238_0 ; } __ats_lab_237_1: tmp1053 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1054 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1055 = v0aldec_tr_66 (tmp1053) ; tmp1056 = v0aldeclst_tr_67 (tmp1054) ; tmp1057 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1058 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1058, atslab_0, tmp1055) ; ats_selptrset_mac(anairiats_sum_2, tmp1058, atslab_1, tmp1056) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_rec (tmp1057, tmp1058) ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: if (((ats_sum_ptr_type)tmp925)->tag != 25) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp1059 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_0) ; tmp1060 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_1) ; tmp1061 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_2) ; tmp1062 = ats_caselptrlab_mac(anairiats_sum_34, tmp925, atslab_3) ; tmp1063 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr (tmp1060) ; tmp1065 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1065, atslab_0, tmp1061) ; ats_selptrset_mac(anairiats_sum_2, tmp1065, atslab_1, tmp1062) ; tmp1064 = f0undeclst_tr_69 (tmp1059, tmp1065) ; tmp1066 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_fundecs (tmp1066, tmp1059, tmp1063, tmp1064) ; break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: if (((ats_sum_ptr_type)tmp925)->tag != 26) { goto __ats_lab_240_0 ; } __ats_lab_239_1: tmp1067 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1068 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1069 = v0ardec_tr_70 (tmp1067) ; tmp1070 = v0ardeclst_tr_71 (tmp1068) ; tmp1071 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1072 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1072, atslab_0, tmp1069) ; ats_selptrset_mac(anairiats_sum_2, tmp1072, atslab_1, tmp1070) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_vardecs (tmp1071, tmp1072) ; break ; /* branch: __ats_lab_240 */ __ats_lab_240_0: if (((ats_sum_ptr_type)tmp925)->tag != 27) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp1073 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_0) ; tmp1074 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_1) ; tmp1075 = ats_caselptrlab_mac(anairiats_sum_15, tmp925, atslab_2) ; tmp1076 = m0acdef_tr_72 (tmp1074) ; tmp1077 = m0acdeflst_tr_73 (tmp1075) ; tmp1078 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1079 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp1079, atslab_0, tmp1076) ; ats_selptrset_mac(anairiats_sum_2, tmp1079, atslab_1, tmp1077) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_macdefs (tmp1078, tmp1073, tmp1079) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: if (((ats_sum_ptr_type)tmp925)->tag != 28) { goto __ats_lab_242_0 ; } __ats_lab_241_1: tmp1080 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1081 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1082 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr (tmp1080) ; tmp1083 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1084 = i0mpdec_tr_74 (tmp1081) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_impdec (tmp1083, tmp1082, tmp1084) ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: if (((ats_sum_ptr_type)tmp925)->tag != 29) { goto __ats_lab_245_0 ; } __ats_lab_242_1: tmp1085 = ats_caselptrlab_mac(anairiats_sum_1, tmp925, atslab_0) ; tmp1087 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (tmp1085) ; do { /* branch: __ats_lab_243 */ __ats_lab_243_0: if (tmp1087 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_243_1: tmp1088 = ats_caselptrlab_mac(anairiats_sum_4, tmp1087, atslab_0) ; ATS_FREE(tmp1087) ; tmp1086 = tmp1088 ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: // if (tmp1087 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_244_1: tmp1090 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; /* tmp1089 = */ prerr_loc_error1_0 (tmp1090) ; /* tmp1091 = */ atspre_prerr_string (ATSstrcst(": the file [")) ; /* tmp1092 = */ atspre_prerr_string (tmp1085) ; /* tmp1093 = */ atspre_prerr_string (ATSstrcst("] is not available for dynamic loading")) ; /* tmp1094 = */ atspre_prerr_newline () ; /* tmp1086 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1095 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dynload (tmp1095, tmp1086) ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: if (((ats_sum_ptr_type)tmp925)->tag != 30) { goto __ats_lab_248_0 ; } __ats_lab_245_1: tmp1096 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1097 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1099 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (tmp1097) ; do { /* branch: __ats_lab_246 */ __ats_lab_246_0: if (tmp1099 == (ats_sum_ptr_type)0) { goto __ats_lab_247_0 ; } __ats_lab_246_1: tmp1100 = ats_caselptrlab_mac(anairiats_sum_4, tmp1099, atslab_0) ; ATS_FREE(tmp1099) ; tmp1098 = tmp1100 ; break ; /* branch: __ats_lab_247 */ __ats_lab_247_0: // if (tmp1099 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_247_1: tmp1102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; /* tmp1101 = */ prerr_loc_error1_0 (tmp1102) ; /* tmp1103 = */ atspre_prerr_string (ATSstrcst(": the file [")) ; /* tmp1104 = */ atspre_prerr_string (tmp1097) ; /* tmp1105 = */ atspre_prerr_string (ATSstrcst("] is not available for static loading")) ; /* tmp1106 = */ atspre_prerr_newline () ; /* tmp1098 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1107 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = s0taload_tr_80 (tmp1107, tmp1096, tmp1098) ; break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: if (((ats_sum_ptr_type)tmp925)->tag != 31) { goto __ats_lab_249_0 ; } __ats_lab_248_1: tmp1108 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1109 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; /* tmp1110 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () ; /* tmp1111 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc () ; /* tmp1112 = ats_selsin_mac(tmp1111, atslab_1) */ ; tmp1113 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp1108) ; /* tmp1114 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec () ; /* tmp1115 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () ; tmp1116 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp1109) ; /* tmp1117 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_localjoin () ; tmp1118 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_local (tmp1118, tmp1113, tmp1116) ; break ; /* branch: __ats_lab_249 */ __ats_lab_249_0: if (((ats_sum_ptr_type)tmp925)->tag != 32) { goto __ats_lab_250_0 ; } __ats_lab_249_1: tmp1119 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_0) ; tmp1120 = ats_caselptrlab_mac(anairiats_sum_8, tmp925, atslab_1) ; tmp1121 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp1122 = guad0ec_tr_76 (tmp1119, tmp1120) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_list (tmp1121, tmp1122) ; break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: // if (((ats_sum_ptr_type)tmp925)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_250_1: tmp1123 = ats_caselptrlab_mac(anairiats_sum_11, tmp925, atslab_0) ; tmp1124 = ats_caselptrlab_mac(anairiats_sum_11, tmp925, atslab_1) ; tmp1126 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (tmp1124) ; do { /* branch: __ats_lab_251 */ __ats_lab_251_0: if (tmp1126 == (ats_sum_ptr_type)0) { goto __ats_lab_252_0 ; } __ats_lab_251_1: tmp1127 = ats_caselptrlab_mac(anairiats_sum_4, tmp1126, atslab_0) ; ATS_FREE(tmp1126) ; tmp1125 = tmp1127 ; break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: // if (tmp1126 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_252_1: tmp1129 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; /* tmp1128 = */ prerr_loc_error1_0 (tmp1129) ; /* tmp1130 = */ atspre_prerr_string (ATSstrcst(": the file [")) ; /* tmp1131 = */ atspre_prerr_string (tmp1124) ; /* tmp1132 = */ atspre_prerr_string (ATSstrcst("] is not available for inclusion")) ; /* tmp1133 = */ atspre_prerr_newline () ; /* tmp1125 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp1134 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_d0ec_loc) ; tmp924 = i0nclude_tr_79 (tmp1134, tmp1123, tmp1125) ; break ; } while (0) ; return (tmp924) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 58045(line=1916, offs=12) -- 58087(line=1916, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr: tmp1135 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_tr) ; return (tmp1135) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 58131(line=1921, offs=12) -- 58219(line=1923, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__initialize () { /* local vardec */ // ATSlocal_void (tmp1136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__initialize: /* tmp1136 = */ atsopt_dynloadflag_set (1) ; return /* (tmp1136) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__initialize] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 58326(line=1929, offs=9) -- 59026(line=1947, offs=8) */ ATSstaticdec() ats_void_type aux_namespace_85 () { /* local vardec */ // ATSlocal_void (tmp1138) ; ATSlocal (ats_ptr_type, tmp1139) ; ATSlocal (ats_ptr_type, tmp1140) ; ATSlocal (ats_ptr_type, tmp1141) ; ATSlocal (ats_ptr_type, tmp1142) ; // ATSlocal_void (tmp1143) ; ATSlocal (ats_ptr_type, tmp1144) ; // ATSlocal_void (tmp1145) ; // ATSlocal_void (tmp1146) ; __ats_lab_aux_namespace_85: tmp1139 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATSOPT_NAMESPACE) ; do { /* branch: __ats_lab_253 */ __ats_lab_253_0: if (tmp1139 == (ats_sum_ptr_type)0) { goto __ats_lab_256_0 ; } __ats_lab_253_1: tmp1140 = ats_caselptrlab_mac(anairiats_sum_4, tmp1139, atslab_0) ; ATS_FREE(tmp1139) ; tmp1141 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp1140) ; do { /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp1141)->tag != 3) { goto __ats_lab_255_0 ; } __ats_lab_254_1: tmp1142 = ats_caselptrlab_mac(anairiats_sum_1, tmp1141, atslab_0) ; /* tmp1138 = */ atsopt_namespace_set (ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp1142))) ; break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: __ats_lab_255_1: tmp1144 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_51, tmp1140), atslab_e1xp_loc) ; /* tmp1143 = */ prerr_loc_error1_0 (tmp1144) ; /* tmp1145 = */ atspre_prerr_string (ATSstrcst(": a string definition is required for [ATSOPT_NAMESPACE].")) ; /* tmp1146 = */ atspre_prerr_newline () ; /* tmp1138 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: // if (tmp1139 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_256_1: break ; } while (0) ; return /* (tmp1138) */ ; } /* end of [aux_namespace_85] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 59124(line=1951, offs=9) -- 59472(line=1960, offs=8) */ ATSstaticdec() ats_void_type aux_dynloadflag_86 () { /* local vardec */ // ATSlocal_void (tmp1148) ; ATSlocal (ats_ptr_type, tmp1149) ; ATSlocal (ats_ptr_type, tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; ATSlocal (ats_int_type, tmp1152) ; ATSlocal (ats_bool_type, tmp1153) ; __ats_lab_aux_dynloadflag_86: tmp1149 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFLAG) ; do { /* branch: __ats_lab_257 */ __ats_lab_257_0: if (tmp1149 == (ats_sum_ptr_type)0) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp1150 = ats_caselptrlab_mac(anairiats_sum_4, tmp1149, atslab_0) ; ATS_FREE(tmp1149) ; tmp1151 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp1150) ; tmp1153 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (tmp1151) ; if (tmp1153) { tmp1152 = 1 ; } else { tmp1152 = 0 ; } /* end of [if] */ /* tmp1148 = */ atsopt_dynloadflag_set (tmp1152) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: // if (tmp1149 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_258_1: break ; } while (0) ; return /* (tmp1148) */ ; } /* end of [aux_dynloadflag_86] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 59576(line=1964, offs=9) -- 60318(line=1983, offs=8) */ ATSstaticdec() ats_void_type aux_dynloadfun_name_87 () { /* local vardec */ // ATSlocal_void (tmp1155) ; ATSlocal (ats_ptr_type, tmp1156) ; ATSlocal (ats_ptr_type, tmp1157) ; ATSlocal (ats_ptr_type, tmp1158) ; ATSlocal (ats_ptr_type, tmp1159) ; // ATSlocal_void (tmp1160) ; ATSlocal (ats_ptr_type, tmp1161) ; // ATSlocal_void (tmp1162) ; // ATSlocal_void (tmp1163) ; __ats_lab_aux_dynloadfun_name_87: tmp1156 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFUN_NAME) ; do { /* branch: __ats_lab_259 */ __ats_lab_259_0: if (tmp1156 == (ats_sum_ptr_type)0) { goto __ats_lab_262_0 ; } __ats_lab_259_1: tmp1157 = ats_caselptrlab_mac(anairiats_sum_4, tmp1156, atslab_0) ; ATS_FREE(tmp1156) ; tmp1158 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp1157) ; do { /* branch: __ats_lab_260 */ __ats_lab_260_0: if (((ats_sum_ptr_type)tmp1158)->tag != 3) { goto __ats_lab_261_0 ; } __ats_lab_260_1: tmp1159 = ats_caselptrlab_mac(anairiats_sum_1, tmp1158, atslab_0) ; /* tmp1155 = */ atsopt_dynloadfun_name_set (ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp1159))) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: __ats_lab_261_1: tmp1161 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_51, tmp1157), atslab_e1xp_loc) ; /* tmp1160 = */ prerr_loc_error1_0 (tmp1161) ; /* tmp1162 = */ atspre_prerr_string (ATSstrcst(": a string definition is required for [ATS_DYNLOADFUN_NAME].")) ; /* tmp1163 = */ atspre_prerr_newline () ; /* tmp1155 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: // if (tmp1156 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_262_1: break ; } while (0) ; return /* (tmp1155) */ ; } /* end of [aux_dynloadfun_name_87] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_dyn.dats: 58263(line=1926, offs=10) -- 60377(line=1986, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__finalize () { /* local vardec */ // ATSlocal_void (tmp1137) ; // ATSlocal_void (tmp1147) ; // ATSlocal_void (tmp1154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__finalize: /* tmp1147 = */ aux_namespace_85 () ; /* tmp1154 = */ aux_dynloadflag_86 () ; /* tmp1137 = */ aux_dynloadfun_name_87 () ; return /* (tmp1137) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__finalize] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp137, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp141, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp256, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp260, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp137 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (f_8_closure_make ()) ; statmp141 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (&__ats_fun_12, __ats_fun_13_closure_make ()) ; statmp256 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (f_23_closure_make ()) ; statmp260 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (&__ats_fun_27, __ats_fun_28_closure_make ()) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* extern char *atspre_string_make_substring (char*, size_t, size_t) ; */ ats_bool_type atsopt_extnam_ismac ( ats_ptr_type ext, ats_ptr_type ext_new ) { int sgn ; char* p ; int len ; /* sgn = strncmp ((char*)ext, "#", 1) ; if (sgn) sgn = strncmp ((char*)ext, "mac#", 4) ; */ sgn = strncmp ((char*)ext, "mac#", 4) ; // if (sgn == 0) { p = strchr ((char*)ext, '#') ; len = strlen (p) ; *(char**)ext_new = (char*)atspre_string_make_substring(p, 1, len-1) ; return ats_true_bool ; } // end of [if] return ats_false_bool ; } // end of [atsopt_extnam_ismac] ats_bool_type atsopt_extnam_issta ( ats_ptr_type ext, ats_ptr_type ext_new ) { int sgn ; char* p ; int len ; sgn = strncmp ((char*)ext, "sta#", 4) ; if (sgn == 0) { p = strchr ((char*)ext, '#') ; len = strlen (p) ; *(char**)ext_new = (char*)atspre_string_make_substring(p, 1, len-1) ; return ats_true_bool ; } // end of [if] return ats_false_bool ; } // end of [atsopt_extnam_issta] ats_bool_type atsopt_extnam_isext ( ats_ptr_type ext, ats_ptr_type ext_new ) { int sgn ; char* p ; int len ; sgn = strncmp ((char*)ext, "ext#", 4) ; if (sgn == 0) { p = strchr ((char*)ext, '#') ; len = strlen (p) ; *(char**)ext_new = (char*)atspre_string_make_substring(p, 1, len-1) ; return ats_true_bool ; } // end of [if] return ats_false_bool ; } // end of [atsopt_extnam_isext] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans1_dyn_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp3_dats.c0000664000175000017500000046277212223166160021533 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_d3lab1_loc ; ats_ptr_type atslab_d3lab1_node ; } anairiats_rec_13 ; typedef struct { ats_ptr_type atslab_c3lau_loc ; ats_ptr_type atslab_c3lau_pat ; ats_ptr_type atslab_c3lau_gua ; ats_int_type atslab_c3lau_seq ; ats_int_type atslab_c3lau_neg ; ats_ptr_type atslab_c3lau_exp ; } anairiats_rec_14 ; typedef struct { ats_ptr_type atslab_sc3lau_loc ; ats_ptr_type atslab_sc3lau_pat ; ats_ptr_type atslab_sc3lau_exp ; } anairiats_rec_15 ; typedef struct { ats_ptr_type atslab_v3aldec_loc ; ats_ptr_type atslab_v3aldec_pat ; ats_ptr_type atslab_v3aldec_def ; } anairiats_rec_16 ; typedef struct { ats_ptr_type atslab_v3ardec_loc ; ats_int_type atslab_v3ardec_knd ; ats_ptr_type atslab_v3ardec_dvar_ptr ; ats_ptr_type atslab_v3ardec_dvar_viw ; ats_ptr_type atslab_v3ardec_typ ; ats_ptr_type atslab_v3ardec_ini ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_d3ec_loc ; ats_ptr_type atslab_d3ec_node ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_i3mpdec_loc ; ats_ptr_type atslab_i3mpdec_cst ; ats_ptr_type atslab_i3mpdec_decarg ; ats_ptr_type atslab_i3mpdec_tmparg ; ats_ptr_type atslab_i3mpdec_def ; } anairiats_rec_19 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_21 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_22 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_23 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_24 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_25 ; typedef struct { ats_ptr_type atslab_d3lab0_loc ; ats_ptr_type atslab_d3lab0_node ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_m3atch_loc ; ats_ptr_type atslab_m3atch_exp ; ats_ptr_type atslab_m3atch_pat ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_f3undec_loc ; ats_ptr_type atslab_f3undec_var ; ats_ptr_type atslab_f3undec_def ; } anairiats_rec_28 ; /* external typedefs */ typedef anairiats_rec_9 *d3exp_t ; typedef anairiats_rec_0 *p3at_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvbox_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrinit_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrpsz_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_ptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_var_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ebool_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecaseof_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Echar_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Econ_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecstsp_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecrypt_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eextval_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efix_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloatsp_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efoldat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efreeat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eif_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eint_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eintsp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_dyn_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elaminit_dyn_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_met_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_sta_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_delay_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_ldelay_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_force_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elet_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloop_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloopexn_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elst_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eraise_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erec_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erefarg_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Escaseof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esif_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estring_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estruct_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etrywith_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_ptr_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_var_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ewhere_59) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Csaspdec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdcstdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdatdec_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cexndec_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextype_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextval_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextcode_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_par_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_rec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cfundecs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvardecs_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cimpdec_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clocal_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cstaload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdynload_17) ; /* external dynamic constant declarations */ ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_eff) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type d3exp_eff_union_15 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3expopt_eff_union_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3explst_eff_union_17 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3explstlst_eff_union_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labd3explst_eff_union_19 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3lab1_eff_union_20 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3lab1lst_eff_union_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type c3laulst_eff_union_22 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type sc3laulst_eff_union_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v3aldeclst_eff_union_24 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v3ardeclst_eff_union_25 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3ec_eff_union_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3eclst_eff_union_27 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux_39 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2000(line=65, offs=3) -- 2122(line=70, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_ann (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_ann: tmp1 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp1)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp1, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp1, atslab_1, arg3) ; tmp2 = (ats_sum_ptr_type)0 ; tmp0 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp0, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp0, atslab_p3at_node, tmp1) ; ats_selptrset_mac(anairiats_rec_0, tmp0, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp0, atslab_p3at_typ_lft, tmp2) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2166(line=73, offs=3) -- 2268(line=78, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_any (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_any: tmp4 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp4)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp4, atslab_0, arg2) ; tmp5 = (ats_sum_ptr_type)0 ; tmp3 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp3, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp3, atslab_p3at_node, tmp4) ; ats_selptrset_mac(anairiats_rec_0, tmp3, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp3, atslab_p3at_typ_lft, tmp5) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_any] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2311(line=81, offs=3) -- 2440(line=86, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as: tmp7 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp7)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp7, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp7, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp7, atslab_2, arg4) ; tmp8 = (ats_sum_ptr_type)0 ; tmp6 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp6, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp6, atslab_p3at_node, tmp7) ; ats_selptrset_mac(anairiats_rec_0, tmp6, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp6, atslab_p3at_typ_lft, tmp8) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2482(line=88, offs=21) -- 2581(line=93, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool: tmp10 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp10)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp10, atslab_0, arg2) ; tmp11 = (ats_sum_ptr_type)0 ; tmp9 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp9, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp9, atslab_p3at_node, tmp10) ; ats_selptrset_mac(anairiats_rec_0, tmp9, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp9, atslab_p3at_typ_lft, tmp11) ; return (tmp9) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2603(line=95, offs=21) -- 2706(line=100, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char (ats_ptr_type arg0, ats_ptr_type arg1, ats_char_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char: tmp13 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp13)->tag = 4 ; ats_selptrset_mac(anairiats_sum_5, tmp13, atslab_0, arg2) ; tmp14 = (ats_sum_ptr_type)0 ; tmp12 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp12, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp12, atslab_p3at_node, tmp13) ; ats_selptrset_mac(anairiats_rec_0, tmp12, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp12, atslab_p3at_typ_lft, tmp14) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2729(line=103, offs=3) -- 2881(line=108, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con: tmp16 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp16)->tag = 5 ; ats_selptrset_mac(anairiats_sum_6, tmp16, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp16, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_6, tmp16, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_6, tmp16, atslab_3, arg5) ; tmp17 = (ats_sum_ptr_type)0 ; tmp15 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_p3at_node, tmp16) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_p3at_typ_lft, tmp17) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 2925(line=110, offs=22) -- 3023(line=115, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_empty (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_empty: tmp19 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6) ; tmp20 = (ats_sum_ptr_type)0 ; tmp18 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp18, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp18, atslab_p3at_node, tmp19) ; ats_selptrset_mac(anairiats_rec_0, tmp18, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp18, atslab_p3at_typ_lft, tmp20) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3048(line=118, offs=3) -- 3166(line=123, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_exist: tmp22 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp22)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp22, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp22, atslab_1, arg3) ; tmp23 = (ats_sum_ptr_type)0 ; tmp21 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp21, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp21, atslab_p3at_node, tmp22) ; ats_selptrset_mac(anairiats_rec_0, tmp21, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp21, atslab_p3at_typ_lft, tmp23) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3214(line=126, offs=3) -- 3324(line=131, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_float (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_float: tmp25 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp25)->tag = 8 ; ats_selptrset_mac(anairiats_sum_2, tmp25, atslab_0, arg2) ; tmp26 = (ats_sum_ptr_type)0 ; tmp24 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp24, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp24, atslab_p3at_node, tmp25) ; ats_selptrset_mac(anairiats_rec_0, tmp24, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp24, atslab_p3at_typ_lft, tmp26) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3370(line=134, offs=3) -- 3494(line=139, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int: tmp28 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp28)->tag = 9 ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_1, arg3) ; tmp29 = (ats_sum_ptr_type)0 ; tmp27 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp27, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp27, atslab_p3at_node, tmp28) ; ats_selptrset_mac(anairiats_rec_0, tmp27, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp27, atslab_p3at_typ_lft, tmp29) ; return (tmp27) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3538(line=142, offs=3) -- 3670(line=147, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_lst: tmp31 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp31)->tag = 10 ; ats_selptrset_mac(anairiats_sum_1, tmp31, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp31, atslab_1, arg3) ; tmp32 = (ats_sum_ptr_type)0 ; tmp30 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp30, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp30, atslab_p3at_node, tmp31) ; ats_selptrset_mac(anairiats_rec_0, tmp30, atslab_p3at_typ, arg2) ; ats_selptrset_mac(anairiats_rec_0, tmp30, atslab_p3at_typ_lft, tmp32) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3714(line=150, offs=3) -- 3842(line=155, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_rec (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_rec: tmp34 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp34)->tag = 11 ; ats_selptrset_mac(anairiats_sum_7, tmp34, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp34, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_7, tmp34, atslab_2, arg4) ; tmp35 = (ats_sum_ptr_type)0 ; tmp33 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp33, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp33, atslab_p3at_node, tmp34) ; ats_selptrset_mac(anairiats_rec_0, tmp33, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp33, atslab_p3at_typ_lft, tmp35) ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 3889(line=158, offs=3) -- 3994(line=163, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string: tmp37 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp37)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp37, atslab_0, arg2) ; tmp38 = (ats_sum_ptr_type)0 ; tmp36 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp36, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp36, atslab_p3at_node, tmp37) ; ats_selptrset_mac(anairiats_rec_0, tmp36, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp36, atslab_p3at_typ_lft, tmp38) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 4041(line=166, offs=3) -- 4161(line=171, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var: tmp40 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp40)->tag = 13 ; ats_selptrset_mac(anairiats_sum_8, tmp40, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp40, atslab_1, arg3) ; tmp41 = (ats_sum_ptr_type)0 ; tmp39 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp39, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp39, atslab_p3at_node, tmp40) ; ats_selptrset_mac(anairiats_rec_0, tmp39, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp39, atslab_p3at_typ_lft, tmp41) ; return (tmp39) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 4206(line=174, offs=3) -- 4311(line=179, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_vbox (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_vbox: tmp43 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp43)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp43, atslab_0, arg2) ; tmp44 = (ats_sum_ptr_type)0 ; tmp42 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp42, atslab_p3at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp42, atslab_p3at_node, tmp43) ; ats_selptrset_mac(anairiats_rec_0, tmp42, atslab_p3at_typ, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp42, atslab_p3at_typ_lft, tmp44) ; return (tmp42) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_vbox] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 4774(line=203, offs=5) -- 4866(line=204, offs=42) */ ATSstaticdec() ats_ptr_type d3exp_eff_union_15 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_d3exp_eff_union_15: tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_eff) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff (arg0, tmp46) ; return (tmp45) ; } /* end of [d3exp_eff_union_15] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 4872(line=206, offs=5) -- 5007(line=208, offs=62) */ ATSstaticdec() ats_ptr_type d3expopt_eff_union_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_d3expopt_eff_union_16: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp47 = d3exp_eff_union_15 (arg0, tmp48) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp47 = arg0 ; break ; } while (0) ; return (tmp47) ; } /* end of [d3expopt_eff_union_16] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 5044(line=211, offs=5) -- 5252(line=216, offs=19) */ ATSstaticdec() ats_ptr_type d3explst_eff_union_17 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_d3explst_eff_union_17: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp51 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp52 = d3exp_eff_union_15 (arg0, tmp50) ; arg0 = tmp52 ; arg1 = tmp51 ; goto __ats_lab_d3explst_eff_union_17 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp49 = arg0 ; break ; } while (0) ; return (tmp49) ; } /* end of [d3explst_eff_union_17] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 5305(line=219, offs=5) -- 5531(line=224, offs=19) */ ATSstaticdec() ats_ptr_type d3explstlst_eff_union_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_d3explstlst_eff_union_18: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp55 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp56 = d3explst_eff_union_17 (arg0, tmp54) ; arg0 = tmp56 ; arg1 = tmp55 ; goto __ats_lab_d3explstlst_eff_union_18 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp53 = arg0 ; break ; } while (0) ; return (tmp53) ; } /* end of [d3explstlst_eff_union_18] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 5587(line=227, offs=5) -- 5851(line=232, offs=30) */ ATSstaticdec() ats_ptr_type labd3explst_eff_union_19 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_labd3explst_eff_union_19: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_12, arg1, atslab_1) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_12, arg1, atslab_2) ; tmp60 = d3exp_eff_union_15 (arg0, tmp58) ; arg0 = tmp60 ; arg1 = tmp59 ; goto __ats_lab_labd3explst_eff_union_19 ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp57 = arg0 ; break ; } while (0) ; return (tmp57) ; } /* end of [labd3explst_eff_union_19] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 5917(line=235, offs=4) -- 6084(line=238, offs=24) */ ATSstaticdec() ats_ptr_type d3lab1_eff_union_20 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; __ats_lab_d3lab1_eff_union_20: tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_d3lab1_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp62)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_1, tmp62, atslab_0) ; tmp61 = d3explstlst_eff_union_18 (arg0, tmp63) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (((ats_sum_ptr_type)tmp62)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp61 = arg0 ; break ; } while (0) ; return (tmp61) ; } /* end of [d3lab1_eff_union_20] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 6119(line=241, offs=5) -- 6331(line=246, offs=19) */ ATSstaticdec() ats_ptr_type d3lab1lst_eff_union_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_d3lab1lst_eff_union_21: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp65 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp66 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp67 = d3lab1_eff_union_20 (arg0, tmp65) ; arg0 = tmp67 ; arg1 = tmp66 ; goto __ats_lab_d3lab1lst_eff_union_21 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp64 = arg0 ; break ; } while (0) ; return (tmp64) ; } /* end of [d3lab1lst_eff_union_21] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 6385(line=249, offs=5) -- 6603(line=254, offs=19) */ ATSstaticdec() ats_ptr_type c3laulst_eff_union_22 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_c3laulst_eff_union_22: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp72 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp69), atslab_c3lau_exp) ; tmp71 = d3exp_eff_union_15 (arg0, tmp72) ; arg0 = tmp71 ; arg1 = tmp70 ; goto __ats_lab_c3laulst_eff_union_22 ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp68 = arg0 ; break ; } while (0) ; return (tmp68) ; } /* end of [c3laulst_eff_union_22] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 6656(line=257, offs=5) -- 6884(line=262, offs=19) */ ATSstaticdec() ats_ptr_type sc3laulst_eff_union_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_sc3laulst_eff_union_23: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp75 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp77 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, tmp74), atslab_sc3lau_exp) ; tmp76 = d3exp_eff_union_15 (arg0, tmp77) ; arg0 = tmp76 ; arg1 = tmp75 ; goto __ats_lab_sc3laulst_eff_union_23 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp73 = arg0 ; break ; } while (0) ; return (tmp73) ; } /* end of [sc3laulst_eff_union_23] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 6938(line=265, offs=5) -- 7164(line=270, offs=19) */ ATSstaticdec() ats_ptr_type v3aldeclst_eff_union_24 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; __ats_lab_v3aldeclst_eff_union_24: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp82 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, tmp79), atslab_v3aldec_def) ; tmp81 = d3exp_eff_union_15 (arg0, tmp82) ; arg0 = tmp81 ; arg1 = tmp80 ; goto __ats_lab_v3aldeclst_eff_union_24 ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp78 = arg0 ; break ; } while (0) ; return (tmp78) ; } /* end of [v3aldeclst_eff_union_24] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 7219(line=273, offs=5) -- 7562(line=281, offs=19) */ ATSstaticdec() ats_ptr_type v3ardeclst_eff_union_25 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_v3ardeclst_eff_union_25: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp85 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp86 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp84), atslab_v3ardec_ini) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp86 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_10, tmp86, atslab_0) ; tmp88 = d3exp_eff_union_15 (arg0, tmp87) ; arg0 = tmp88 ; arg1 = tmp85 ; goto __ats_lab_v3ardeclst_eff_union_25 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (tmp86 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: arg0 = arg0 ; arg1 = tmp85 ; goto __ats_lab_v3ardeclst_eff_union_25 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp83 = arg0 ; break ; } while (0) ; return (tmp83) ; } /* end of [v3ardeclst_eff_union_25] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 7617(line=284, offs=5) -- 8366(line=302, offs=4) */ ATSstaticdec() ats_ptr_type d3ec_eff_union_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_d3ec_eff_union_26: tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_d3ec_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp90)->tag != 7) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_1) ; tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp91), atslab_d3exp_eff) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff (arg0, tmp92) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp90)->tag != 8) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp89 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp90)->tag != 9) { goto __ats_lab_27_0 ; } __ats_lab_24_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_0) ; tmp94 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_1) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp93)->tag != 3) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp89 = arg0 ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp89 = v3aldeclst_eff_union_24 (arg0, tmp94) ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp90)->tag != 13) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_2, tmp90, atslab_0) ; tmp89 = v3ardeclst_eff_union_25 (arg0, tmp95) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp90)->tag != 14) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_2, tmp90, atslab_0) ; tmp97 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp96), atslab_i3mpdec_def) ; tmp89 = d3exp_eff_union_15 (arg0, tmp97) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp90)->tag != 15) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_0) ; tmp99 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_1) ; tmp100 = d3eclst_eff_union_27 (arg0, tmp98) ; tmp89 = d3eclst_eff_union_27 (tmp100, tmp99) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp89 = arg0 ; break ; } while (0) ; return (tmp89) ; } /* end of [d3ec_eff_union_26] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 8399(line=304, offs=5) -- 8629(line=310, offs=4) */ ATSstaticdec() ats_ptr_type d3eclst_eff_union_27 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_d3eclst_eff_union_27: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp104 = d3ec_eff_union_26 (arg0, tmp102) ; arg0 = tmp104 ; arg1 = tmp103 ; goto __ats_lab_d3eclst_eff_union_27 ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp101 = arg0 ; break ; } while (0) ; return (tmp101) ; } /* end of [d3eclst_eff_union_27] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 8707(line=314, offs=26) -- 8826(line=318, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ann_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ann_type: tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_eff) ; tmp107 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp107)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp107, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp107, atslab_1, arg2) ; tmp105 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_d3exp_eff, tmp106) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_d3exp_typ, arg2) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_d3exp_node, tmp107) ; return (tmp105) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ann_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 8854(line=321, offs=3) -- 9135(line=328, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn: tmp110 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg3), atslab_d3exp_eff) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff (arg2, tmp110) ; tmp111 = d3explst_eff_union_17 (tmp109, arg5) ; tmp112 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp112)->tag = 1 ; ats_selptrset_mac(anairiats_sum_20, tmp112, atslab_0, arg3) ; ats_selptrset_mac(anairiats_sum_20, tmp112, atslab_1, arg4) ; ats_selptrset_mac(anairiats_sum_20, tmp112, atslab_2, arg5) ; tmp108 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp108, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp108, atslab_d3exp_eff, tmp111) ; ats_selptrset_mac(anairiats_rec_9, tmp108, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp108, atslab_d3exp_node, tmp112) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 9187(line=330, offs=25) -- 9318(line=334, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta: tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp115 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp115)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp115, atslab_0, arg2) ; tmp113 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_d3exp_eff, tmp114) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_d3exp_node, tmp115) ; return (tmp113) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 9365(line=339, offs=15) -- 9663(line=349, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrinit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrinit: tmp117 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp118 = d3expopt_eff_union_16 (tmp117, arg3) ; tmp119 = d3explst_eff_union_17 (tmp118, arg4) ; tmp120 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp120)->tag = 3 ; ats_selptrset_mac(anairiats_sum_21, tmp120, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp120, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp120, atslab_2, arg4) ; tmp116 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp116, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp116, atslab_d3exp_eff, tmp119) ; ats_selptrset_mac(anairiats_rec_9, tmp116, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp116, atslab_d3exp_node, tmp120) ; return (tmp116) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrinit] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 9714(line=352, offs=14) -- 9924(line=360, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrpsz (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrpsz: tmp123 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp122 = d3explst_eff_union_17 (tmp123, arg3) ; tmp124 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp124)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp124, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp124, atslab_1, arg3) ; tmp121 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_d3exp_eff, tmp122) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_d3exp_node, tmp124) ; return (tmp121) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrpsz] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 10000(line=365, offs=3) -- 10288(line=373, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr: tmp126 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_eff) ; tmp127 = d3lab1lst_eff_union_21 (tmp126, arg2) ; tmp128 = d3exp_eff_union_15 (tmp127, arg3) ; tmp129 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp130 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp130)->tag = 5 ; ats_selptrset_mac(anairiats_sum_21, tmp130, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp130, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp130, atslab_2, arg3) ; tmp125 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_d3exp_eff, tmp128) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_d3exp_typ, tmp129) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_d3exp_node, tmp130) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 10346(line=376, offs=3) -- 10590(line=383, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var: tmp133 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp132 = d3lab1lst_eff_union_21 (tmp133, arg2) ; tmp134 = d3exp_eff_union_15 (tmp132, arg3) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp136 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp136)->tag = 6 ; ats_selptrset_mac(anairiats_sum_21, tmp136, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp136, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp136, atslab_2, arg3) ; tmp131 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp131, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp131, atslab_d3exp_eff, tmp134) ; ats_selptrset_mac(anairiats_rec_9, tmp131, atslab_d3exp_typ, tmp135) ; ats_selptrset_mac(anairiats_rec_9, tmp131, atslab_d3exp_node, tmp136) ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 10647(line=388, offs=3) -- 10757(line=392, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_bool (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_bool: tmp138 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp139 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp139)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp139, atslab_0, arg2) ; tmp137 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp137, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp137, atslab_d3exp_eff, tmp138) ; ats_selptrset_mac(anairiats_rec_9, tmp137, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp137, atslab_d3exp_node, tmp139) ; return (tmp137) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 10811(line=397, offs=3) -- 11080(line=405, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_caseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_caseof: tmp141 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp142 = d3explst_eff_union_17 (tmp141, arg3) ; tmp143 = c3laulst_eff_union_22 (tmp142, arg4) ; tmp144 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp144)->tag = 8 ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_2, arg4) ; tmp140 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp140, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp140, atslab_d3exp_eff, tmp143) ; ats_selptrset_mac(anairiats_rec_9, tmp140, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp140, atslab_d3exp_node, tmp144) ; return (tmp140) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_caseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 11130(line=408, offs=3) -- 11240(line=412, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_char (ats_ptr_type arg0, ats_ptr_type arg1, ats_char_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_char: tmp146 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp147 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp147)->tag = 9 ; ats_selptrset_mac(anairiats_sum_5, tmp147, atslab_0, arg2) ; tmp145 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp145, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp145, atslab_d3exp_eff, tmp146) ; ats_selptrset_mac(anairiats_rec_9, tmp145, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp145, atslab_d3exp_node, tmp147) ; return (tmp145) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 11367(line=417, offs=9) -- 11557(line=421, offs=29) */ ATSstaticdec() ats_bool_type aux_39 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_aux_39: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp150 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp151 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp150), atslab_d3exp_node) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp152)->tag != 52) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp149 = ats_true_bool ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: arg0 = tmp151 ; goto __ats_lab_aux_39 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp149 = ats_false_bool ; break ; } while (0) ; return (tmp149) ; } /* end of [aux_39] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 11287(line=415, offs=3) -- 11904(line=435, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_bool_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_con: tmp153 = aux_39 (arg4) ; /* ats_ptr_type tmp154 ; */ tmp154 = arg1 ; if (tmp153) { tmp156 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ (arg4) ; tmp157 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp (arg2, tmp156) ; tmp154 = tmp157 ; } else { /* empty */ } /* end of [if] */ tmp159 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp158 = d3explst_eff_union_17 (tmp159, arg4) ; tmp160 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp160)->tag = 10 ; ats_selptrset_mac(anairiats_sum_20, tmp160, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_20, tmp160, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_20, tmp160, atslab_2, arg4) ; tmp148 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp148, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp148, atslab_d3exp_eff, tmp158) ; ats_selptrset_mac(anairiats_rec_9, tmp148, atslab_d3exp_typ, tmp154) ; ats_selptrset_mac(anairiats_rec_9, tmp148, atslab_d3exp_node, tmp160) ; return (tmp148) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_con] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 11950(line=438, offs=13) -- 12072(line=442, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt: tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg3), atslab_d3exp_eff) ; tmp163 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp163)->tag = 13 ; ats_selptrset_mac(anairiats_sum_8, tmp163, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp163, atslab_1, arg3) ; tmp161 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp161, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp161, atslab_d3exp_eff, tmp162) ; ats_selptrset_mac(anairiats_rec_9, tmp161, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp161, atslab_d3exp_node, tmp163) ; return (tmp161) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12139(line=447, offs=11) -- 12253(line=451, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cst: tmp165 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp166 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (arg1) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp167)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp167, atslab_0, arg1) ; tmp164 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp164, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp164, atslab_d3exp_eff, tmp165) ; ats_selptrset_mac(anairiats_rec_9, tmp164, atslab_d3exp_typ, tmp166) ; ats_selptrset_mac(anairiats_rec_9, tmp164, atslab_d3exp_node, tmp167) ; return (tmp164) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12299(line=454, offs=13) -- 12406(line=458, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cstsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cstsp: tmp169 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp170 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp170)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp170, atslab_0, arg2) ; tmp168 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp168, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp168, atslab_d3exp_eff, tmp169) ; ats_selptrset_mac(anairiats_rec_9, tmp168, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp168, atslab_d3exp_node, tmp170) ; return (tmp168) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12477(line=463, offs=15) -- 12600(line=467, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_dynload: tmp172 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp174 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp174)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp174, atslab_0, arg1) ; tmp171 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp171, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp171, atslab_d3exp_eff, tmp172) ; ats_selptrset_mac(anairiats_rec_9, tmp171, atslab_d3exp_typ, tmp173) ; ats_selptrset_mac(anairiats_rec_9, tmp171, atslab_d3exp_node, tmp174) ; return (tmp171) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12626(line=470, offs=15) -- 12755(line=474, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask: tmp176 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp177 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_typ) ; tmp178 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp178)->tag = 15 ; ats_selptrset_mac(anairiats_sum_1, tmp178, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp178, atslab_1, arg2) ; tmp175 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp175, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp175, atslab_d3exp_eff, tmp176) ; ats_selptrset_mac(anairiats_rec_9, tmp175, atslab_d3exp_typ, tmp177) ; ats_selptrset_mac(anairiats_rec_9, tmp175, atslab_d3exp_node, tmp178) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12779(line=477, offs=13) -- 12881(line=481, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty: tmp180 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp181 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16) ; tmp179 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp179, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp179, atslab_d3exp_eff, tmp180) ; ats_selptrset_mac(anairiats_rec_9, tmp179, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp179, atslab_d3exp_node, tmp181) ; return (tmp179) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 12906(line=484, offs=14) -- 13019(line=488, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_extval: tmp183 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp184 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp184)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp184, atslab_0, arg2) ; tmp182 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp182, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp182, atslab_d3exp_eff, tmp183) ; ats_selptrset_mac(anairiats_rec_9, tmp182, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp182, atslab_d3exp_node, tmp184) ; return (tmp182) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13066(line=491, offs=11) -- 13214(line=498, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_fix (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_fix: tmp186 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp187)->tag = 18 ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_2, arg4) ; tmp185 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp185, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp185, atslab_d3exp_eff, tmp186) ; ats_selptrset_mac(anairiats_rec_9, tmp185, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp185, atslab_d3exp_node, tmp187) ; return (tmp185) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13260(line=501, offs=13) -- 13368(line=505, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float: tmp189 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp190 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp190)->tag = 19 ; ats_selptrset_mac(anairiats_sum_2, tmp190, atslab_0, arg2) ; tmp188 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp188, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp188, atslab_d3exp_eff, tmp189) ; ats_selptrset_mac(anairiats_rec_9, tmp188, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp188, atslab_d3exp_node, tmp190) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13394(line=508, offs=15) -- 13504(line=512, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_floatsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_floatsp: tmp192 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp193 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp193)->tag = 20 ; ats_selptrset_mac(anairiats_sum_2, tmp193, atslab_0, arg2) ; tmp191 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp191, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp191, atslab_d3exp_eff, tmp192) ; ats_selptrset_mac(anairiats_rec_9, tmp191, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp191, atslab_d3exp_node, tmp193) ; return (tmp191) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13529(line=515, offs=14) -- 13649(line=519, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_foldat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_foldat: tmp195 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp196 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp197 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp197)->tag = 21 ; ats_selptrset_mac(anairiats_sum_2, tmp197, atslab_0, arg1) ; tmp194 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp194, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp194, atslab_d3exp_eff, tmp195) ; ats_selptrset_mac(anairiats_rec_9, tmp194, atslab_d3exp_typ, tmp196) ; ats_selptrset_mac(anairiats_rec_9, tmp194, atslab_d3exp_node, tmp197) ; return (tmp194) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_foldat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13674(line=522, offs=14) -- 13793(line=526, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_freeat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_freeat: tmp199 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp200 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp201 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp201)->tag = 22 ; ats_selptrset_mac(anairiats_sum_2, tmp201, atslab_0, arg1) ; tmp198 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp198, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp198, atslab_d3exp_eff, tmp199) ; ats_selptrset_mac(anairiats_rec_9, tmp198, atslab_d3exp_typ, tmp200) ; ats_selptrset_mac(anairiats_rec_9, tmp198, atslab_d3exp_node, tmp201) ; return (tmp198) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_freeat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 13814(line=529, offs=10) -- 14102(line=539, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_if (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_if: tmp203 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp204 = d3exp_eff_union_15 (tmp203, arg3) ; tmp205 = d3exp_eff_union_15 (tmp204, arg4) ; tmp206 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp206)->tag = 23 ; ats_selptrset_mac(anairiats_sum_21, tmp206, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp206, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp206, atslab_2, arg4) ; tmp202 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp202, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp202, atslab_d3exp_eff, tmp205) ; ats_selptrset_mac(anairiats_rec_9, tmp202, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp202, atslab_d3exp_node, tmp206) ; return (tmp202) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_if] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 14145(line=542, offs=11) -- 14270(line=546, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int: tmp208 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp209 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp209)->tag = 24 ; ats_selptrset_mac(anairiats_sum_1, tmp209, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp209, atslab_1, arg3) ; tmp207 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp207, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp207, atslab_d3exp_eff, tmp208) ; ats_selptrset_mac(anairiats_rec_9, tmp207, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp207, atslab_d3exp_node, tmp209) ; return (tmp207) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 14316(line=549, offs=13) -- 14443(line=553, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_intsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_intsp: tmp211 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp212)->tag = 25 ; ats_selptrset_mac(anairiats_sum_1, tmp212, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp212, atslab_1, arg3) ; tmp210 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp210, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp210, atslab_d3exp_eff, tmp211) ; ats_selptrset_mac(anairiats_rec_9, tmp210, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp210, atslab_d3exp_node, tmp212) ; return (tmp210) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 14514(line=558, offs=3) -- 14683(line=562, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn: tmp214 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp215 = ATS_MALLOC(sizeof(anairiats_sum_22)) ; ((ats_sum_ptr_type)tmp215)->tag = 26 ; ats_selptrset_mac(anairiats_sum_22, tmp215, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_22, tmp215, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_22, tmp215, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_22, tmp215, atslab_3, arg5) ; tmp213 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp213, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp213, atslab_d3exp_eff, tmp214) ; ats_selptrset_mac(anairiats_rec_9, tmp213, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp213, atslab_d3exp_node, tmp215) ; return (tmp213) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 14741(line=565, offs=3) -- 14914(line=569, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_laminit_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_laminit_dyn: tmp217 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp218 = ATS_MALLOC(sizeof(anairiats_sum_22)) ; ((ats_sum_ptr_type)tmp218)->tag = 27 ; ats_selptrset_mac(anairiats_sum_22, tmp218, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_22, tmp218, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_22, tmp218, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_22, tmp218, atslab_3, arg5) ; tmp216 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp216, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp216, atslab_d3exp_eff, tmp217) ; ats_selptrset_mac(anairiats_rec_9, tmp216, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp216, atslab_d3exp_node, tmp218) ; return (tmp216) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_laminit_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 14993(line=574, offs=3) -- 15144(line=578, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_met (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_met: tmp220 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp221 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_typ) ; tmp222 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp222)->tag = 28 ; ats_selptrset_mac(anairiats_sum_1, tmp222, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp222, atslab_1, arg2) ; tmp219 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp219, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp219, atslab_d3exp_eff, tmp220) ; ats_selptrset_mac(anairiats_rec_9, tmp219, atslab_d3exp_typ, tmp221) ; ats_selptrset_mac(anairiats_rec_9, tmp219, atslab_d3exp_node, tmp222) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_met] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 15198(line=581, offs=3) -- 15345(line=585, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_sta: tmp224 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp225 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp225)->tag = 29 ; ats_selptrset_mac(anairiats_sum_21, tmp225, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp225, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp225, atslab_2, arg4) ; tmp223 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp223, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp223, atslab_d3exp_eff, tmp224) ; ats_selptrset_mac(anairiats_rec_9, tmp223, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp223, atslab_d3exp_node, tmp225) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 15423(line=591, offs=3) -- 15538(line=595, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_delay (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_delay: tmp227 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp228 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp228)->tag = 30 ; ats_selptrset_mac(anairiats_sum_2, tmp228, atslab_0, arg2) ; tmp226 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp226, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp226, atslab_d3exp_eff, tmp227) ; ats_selptrset_mac(anairiats_rec_9, tmp226, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp226, atslab_d3exp_node, tmp228) ; return (tmp226) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 15599(line=599, offs=3) -- 15729(line=603, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_ldelay (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_ldelay: tmp230 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp231)->tag = 31 ; ats_selptrset_mac(anairiats_sum_1, tmp231, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp231, atslab_1, arg3) ; tmp229 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp229, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp229, atslab_d3exp_eff, tmp230) ; ats_selptrset_mac(anairiats_rec_9, tmp229, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp229, atslab_d3exp_node, tmp231) ; return (tmp229) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_ldelay] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 15790(line=607, offs=3) -- 15915(line=611, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force: tmp233 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp234 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp234)->tag = 32 ; ats_selptrset_mac(anairiats_sum_8, tmp234, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp234, atslab_1, arg3) ; tmp232 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp232, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp232, atslab_d3exp_eff, tmp233) ; ats_selptrset_mac(anairiats_rec_9, tmp232, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp232, atslab_d3exp_node, tmp234) ; return (tmp232) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 15987(line=615, offs=21) -- 16168(line=621, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let: tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp236 = d3eclst_eff_union_27 (tmp237, arg1) ; tmp238 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_typ) ; tmp239 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp239)->tag = 33 ; ats_selptrset_mac(anairiats_sum_1, tmp239, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp239, atslab_1, arg2) ; tmp235 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp235, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp235, atslab_d3exp_eff, tmp236) ; ats_selptrset_mac(anairiats_rec_9, tmp235, atslab_d3exp_typ, tmp238) ; ats_selptrset_mac(anairiats_rec_9, tmp235, atslab_d3exp_node, tmp239) ; return (tmp235) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 16236(line=626, offs=3) -- 16710(line=637, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loop (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loop: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp241 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp242), atslab_d3exp_eff) ; break ; } while (0) ; tmp243 = d3exp_eff_union_15 (tmp241, arg2) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg3 != (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp244 = tmp243 ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg3 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: tmp245 = ats_caselptrlab_mac(anairiats_sum_10, arg3, atslab_0) ; tmp244 = d3exp_eff_union_15 (tmp243, tmp245) ; break ; } while (0) ; tmp246 = d3exp_eff_union_15 (tmp244, arg4) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp248 = ATS_MALLOC(sizeof(anairiats_sum_23)) ; ((ats_sum_ptr_type)tmp248)->tag = 34 ; ats_selptrset_mac(anairiats_sum_23, tmp248, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_23, tmp248, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_23, tmp248, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_23, tmp248, atslab_3, arg4) ; tmp240 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp240, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp240, atslab_d3exp_eff, tmp246) ; ats_selptrset_mac(anairiats_rec_9, tmp240, atslab_d3exp_typ, tmp247) ; ats_selptrset_mac(anairiats_rec_9, tmp240, atslab_d3exp_node, tmp248) ; return (tmp240) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loop] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 16758(line=639, offs=25) -- 16878(line=643, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loopexn (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loopexn: tmp250 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp251 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp252 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp252)->tag = 35 ; ats_selptrset_mac(anairiats_sum_24, tmp252, atslab_0, arg1) ; tmp249 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp249, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp249, atslab_d3exp_eff, tmp250) ; ats_selptrset_mac(anairiats_rec_9, tmp249, atslab_d3exp_typ, tmp251) ; ats_selptrset_mac(anairiats_rec_9, tmp249, atslab_d3exp_node, tmp252) ; return (tmp249) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 16947(line=647, offs=21) -- 17160(line=653, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lst: tmp255 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp254 = d3explst_eff_union_17 (tmp255, arg4) ; tmp256 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp256)->tag = 36 ; ats_selptrset_mac(anairiats_sum_3, tmp256, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp256, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp256, atslab_2, arg4) ; tmp253 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp253, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp253, atslab_d3exp_eff, tmp254) ; ats_selptrset_mac(anairiats_rec_9, tmp253, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp253, atslab_d3exp_node, tmp256) ; return (tmp253) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 17233(line=658, offs=3) -- 17425(line=664, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr: tmp259 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp258 = d3lab1lst_eff_union_21 (tmp259, arg3) ; tmp260 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp260)->tag = 37 ; ats_selptrset_mac(anairiats_sum_1, tmp260, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp260, atslab_1, arg3) ; tmp257 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp257, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp257, atslab_d3exp_eff, tmp258) ; ats_selptrset_mac(anairiats_rec_9, tmp257, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp257, atslab_d3exp_node, tmp260) ; return (tmp257) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 17483(line=667, offs=3) -- 17673(line=673, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var: tmp263 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp262 = d3lab1lst_eff_union_21 (tmp263, arg3) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp264)->tag = 38 ; ats_selptrset_mac(anairiats_sum_1, tmp264, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp264, atslab_1, arg3) ; tmp261 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp261, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp261, atslab_d3exp_eff, tmp262) ; ats_selptrset_mac(anairiats_rec_9, tmp261, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp261, atslab_d3exp_node, tmp264) ; return (tmp261) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 17746(line=678, offs=13) -- 17933(line=684, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_raise (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_raise: tmp267 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_eff (tmp267, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; tmp268 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp268)->tag = 39 ; ats_selptrset_mac(anairiats_sum_2, tmp268, atslab_0, arg2) ; tmp265 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp265, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp265, atslab_d3exp_eff, tmp266) ; ats_selptrset_mac(anairiats_rec_9, tmp265, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp265, atslab_d3exp_node, tmp268) ; return (tmp265) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 17980(line=688, offs=11) -- 18189(line=696, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec: tmp271 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp270 = labd3explst_eff_union_19 (tmp271, arg4) ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp272)->tag = 40 ; ats_selptrset_mac(anairiats_sum_7, tmp272, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp272, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_7, tmp272, atslab_2, arg4) ; tmp269 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp269, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp269, atslab_d3exp_eff, tmp270) ; ats_selptrset_mac(anairiats_rec_9, tmp269, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp269, atslab_d3exp_node, tmp272) ; return (tmp269) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 18236(line=699, offs=14) -- 18386(line=705, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg: tmp274 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg4), atslab_d3exp_eff) ; tmp275 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp275)->tag = 41 ; ats_selptrset_mac(anairiats_sum_7, tmp275, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp275, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_7, tmp275, atslab_2, arg4) ; tmp273 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp273, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp273, atslab_d3exp_eff, tmp274) ; ats_selptrset_mac(anairiats_rec_9, tmp273, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp273, atslab_d3exp_node, tmp275) ; return (tmp273) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 18437(line=708, offs=15) -- 18650(line=717, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_scaseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_scaseof: tmp277 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp278 = sc3laulst_eff_union_23 (tmp277, arg3) ; tmp279 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp279)->tag = 42 ; ats_selptrset_mac(anairiats_sum_1, tmp279, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp279, atslab_1, arg3) ; tmp276 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp276, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp276, atslab_d3exp_eff, tmp278) ; ats_selptrset_mac(anairiats_rec_9, tmp276, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp276, atslab_d3exp_node, tmp279) ; return (tmp276) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_scaseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 18698(line=720, offs=11) -- 18879(line=726, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel: tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp281 = d3lab1lst_eff_union_21 (tmp282, arg3) ; tmp283 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp283)->tag = 43 ; ats_selptrset_mac(anairiats_sum_1, tmp283, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp283, atslab_1, arg3) ; tmp280 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp280, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp280, atslab_d3exp_eff, tmp281) ; ats_selptrset_mac(anairiats_rec_9, tmp280, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp280, atslab_d3exp_node, tmp283) ; return (tmp280) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 18927(line=728, offs=25) -- 19112(line=734, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_d3exp_eff) ; tmp285 = d3lab1lst_eff_union_21 (tmp286, arg3) ; tmp287 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp287)->tag = 44 ; ats_selptrset_mac(anairiats_sum_1, tmp287, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp287, atslab_1, arg3) ; tmp284 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp284, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp284, atslab_d3exp_eff, tmp285) ; ats_selptrset_mac(anairiats_rec_9, tmp284, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp284, atslab_d3exp_node, tmp287) ; return (tmp284) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 19164(line=736, offs=25) -- 19346(line=742, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var: tmp290 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp289 = d3lab1lst_eff_union_21 (tmp290, arg3) ; tmp291 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp291)->tag = 45 ; ats_selptrset_mac(anairiats_sum_1, tmp291, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp291, atslab_1, arg3) ; tmp288 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp288, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp288, atslab_d3exp_eff, tmp289) ; ats_selptrset_mac(anairiats_rec_9, tmp288, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp288, atslab_d3exp_node, tmp291) ; return (tmp288) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 19394(line=744, offs=21) -- 19559(line=750, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq: tmp294 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp293 = d3explst_eff_union_17 (tmp294, arg2) ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp295)->tag = 46 ; ats_selptrset_mac(anairiats_sum_2, tmp295, atslab_0, arg2) ; tmp292 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp292, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp292, atslab_d3exp_eff, tmp293) ; ats_selptrset_mac(anairiats_rec_9, tmp292, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp292, atslab_d3exp_node, tmp295) ; return (tmp292) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 19605(line=753, offs=3) -- 19844(line=760, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sif (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sif: tmp297 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg3), atslab_d3exp_eff) ; tmp298 = d3exp_eff_union_15 (tmp297, arg4) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp299)->tag = 47 ; ats_selptrset_mac(anairiats_sum_21, tmp299, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp299, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp299, atslab_2, arg4) ; tmp296 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp296, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp296, atslab_d3exp_eff, tmp298) ; ats_selptrset_mac(anairiats_rec_9, tmp296, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp296, atslab_d3exp_node, tmp299) ; return (tmp296) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sif] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 19890(line=762, offs=24) -- 20010(line=766, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string: tmp301 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp302 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp302)->tag = 48 ; ats_selptrset_mac(anairiats_sum_25, tmp302, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_25, tmp302, atslab_1, arg3) ; tmp300 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp300, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp300, atslab_d3exp_eff, tmp301) ; ats_selptrset_mac(anairiats_rec_9, tmp300, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp300, atslab_d3exp_node, tmp302) ; return (tmp300) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 20060(line=768, offs=24) -- 20248(line=774, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_struct (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_struct: tmp305 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp304 = labd3explst_eff_union_19 (tmp305, arg2) ; tmp306 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp306)->tag = 49 ; ats_selptrset_mac(anairiats_sum_2, tmp306, atslab_0, arg2) ; tmp303 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp303, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp303, atslab_d3exp_eff, tmp304) ; ats_selptrset_mac(anairiats_rec_9, tmp303, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp303, atslab_d3exp_node, tmp306) ; return (tmp303) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_struct] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 20316(line=778, offs=24) -- 20440(line=782, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst: tmp308 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp309 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp309)->tag = 50 ; ats_selptrset_mac(anairiats_sum_1, tmp309, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp309, atslab_1, arg3) ; tmp307 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp307, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp307, atslab_d3exp_eff, tmp308) ; ats_selptrset_mac(anairiats_rec_9, tmp307, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp307, atslab_d3exp_node, tmp309) ; return (tmp307) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 20465(line=784, offs=24) -- 20589(line=788, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar: tmp311 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp312 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp312)->tag = 51 ; ats_selptrset_mac(anairiats_sum_1, tmp312, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp312, atslab_1, arg3) ; tmp310 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp310, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp310, atslab_d3exp_eff, tmp311) ; ats_selptrset_mac(anairiats_rec_9, tmp310, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp310, atslab_d3exp_node, tmp312) ; return (tmp310) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 20632(line=792, offs=21) -- 20731(line=796, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top: tmp314 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp315 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52) ; tmp313 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp313, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp313, atslab_d3exp_eff, tmp314) ; ats_selptrset_mac(anairiats_rec_9, tmp313, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp313, atslab_d3exp_node, tmp315) ; return (tmp313) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 20757(line=798, offs=25) -- 20961(line=805, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith: tmp317 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_eff) ; tmp318 = c3laulst_eff_union_22 (tmp317, arg2) ; tmp319 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_typ) ; tmp320 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp320)->tag = 53 ; ats_selptrset_mac(anairiats_sum_1, tmp320, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp320, atslab_1, arg2) ; tmp316 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp316, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp316, atslab_d3exp_eff, tmp318) ; ats_selptrset_mac(anairiats_rec_9, tmp316, atslab_d3exp_typ, tmp319) ; ats_selptrset_mac(anairiats_rec_9, tmp316, atslab_d3exp_node, tmp320) ; return (tmp316) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 21009(line=807, offs=21) -- 21114(line=811, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var: tmp322 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp323 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp323)->tag = 54 ; ats_selptrset_mac(anairiats_sum_2, tmp323, atslab_0, arg2) ; tmp321 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp321, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp321, atslab_d3exp_eff, tmp322) ; ats_selptrset_mac(anairiats_rec_9, tmp321, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp321, atslab_d3exp_node, tmp323) ; return (tmp321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 21188(line=816, offs=3) -- 21363(line=821, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_ptr: tmp325 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_23)) ; ((ats_sum_ptr_type)tmp326)->tag = 57 ; ats_selptrset_mac(anairiats_sum_23, tmp326, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_23, tmp326, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_23, tmp326, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_23, tmp326, atslab_3, arg5) ; tmp324 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp324, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp324, atslab_d3exp_eff, tmp325) ; ats_selptrset_mac(anairiats_rec_9, tmp324, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp324, atslab_d3exp_node, tmp326) ; return (tmp324) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 21394(line=824, offs=3) -- 21569(line=829, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_var: tmp328 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp329 = ATS_MALLOC(sizeof(anairiats_sum_23)) ; ((ats_sum_ptr_type)tmp329)->tag = 58 ; ats_selptrset_mac(anairiats_sum_23, tmp329, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_23, tmp329, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_23, tmp329, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_23, tmp329, atslab_3, arg5) ; tmp327 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp327, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp327, atslab_d3exp_eff, tmp328) ; ats_selptrset_mac(anairiats_rec_9, tmp327, atslab_d3exp_typ, arg1) ; ats_selptrset_mac(anairiats_rec_9, tmp327, atslab_d3exp_node, tmp329) ; return (tmp327) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 21625(line=833, offs=34) -- 21787(line=838, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_ptr: tmp331 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp332 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp333 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp333)->tag = 55 ; ats_selptrset_mac(anairiats_sum_21, tmp333, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp333, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp333, atslab_2, arg3) ; tmp330 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp330, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp330, atslab_d3exp_eff, tmp331) ; ats_selptrset_mac(anairiats_rec_9, tmp330, atslab_d3exp_typ, tmp332) ; ats_selptrset_mac(anairiats_rec_9, tmp330, atslab_d3exp_node, tmp333) ; return (tmp330) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 21822(line=840, offs=34) -- 21984(line=845, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var: tmp335 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp337)->tag = 56 ; ats_selptrset_mac(anairiats_sum_21, tmp337, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp337, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp337, atslab_2, arg3) ; tmp334 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp334, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp334, atslab_d3exp_eff, tmp335) ; ats_selptrset_mac(anairiats_rec_9, tmp334, atslab_d3exp_typ, tmp336) ; ats_selptrset_mac(anairiats_rec_9, tmp334, atslab_d3exp_node, tmp337) ; return (tmp334) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22029(line=849, offs=23) -- 22212(line=855, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_where (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_where: tmp340 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_eff) ; tmp339 = d3eclst_eff_union_27 (tmp340, arg2) ; tmp341 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_typ) ; tmp342 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp342)->tag = 59 ; ats_selptrset_mac(anairiats_sum_1, tmp342, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp342, atslab_1, arg2) ; tmp338 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp338, atslab_d3exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp338, atslab_d3exp_eff, tmp339) ; ats_selptrset_mac(anairiats_rec_9, tmp338, atslab_d3exp_typ, tmp341) ; ats_selptrset_mac(anairiats_rec_9, tmp338, atslab_d3exp_node, tmp342) ; return (tmp338) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_where] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22280(line=859, offs=22) -- 22355(line=861, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_ind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_ind: tmp344 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp344)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp344, atslab_0, arg1) ; tmp343 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp343, atslab_d3lab0_loc, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp343, atslab_d3lab0_node, tmp344) ; return (tmp343) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22378(line=863, offs=22) -- 22441(line=865, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_lab: tmp346 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp346)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp346, atslab_0, arg1) ; tmp345 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp345, atslab_d3lab0_loc, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp345, atslab_d3lab0_node, tmp346) ; return (tmp345) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22464(line=867, offs=22) -- 22559(line=869, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_ind (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_ind: tmp348 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp348)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp348, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp348, atslab_1, arg2) ; tmp347 = ATS_MALLOC(sizeof(anairiats_rec_13)) ; ats_selptrset_mac(anairiats_rec_13, tmp347, atslab_d3lab1_loc, arg0) ; ats_selptrset_mac(anairiats_rec_13, tmp347, atslab_d3lab1_node, tmp348) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22582(line=871, offs=22) -- 22657(line=873, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_lab (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_lab: tmp350 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp350)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp350, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp350, atslab_1, arg2) ; tmp349 = ATS_MALLOC(sizeof(anairiats_rec_13)) ; ats_selptrset_mac(anairiats_rec_13, tmp349, atslab_d3lab1_loc, arg0) ; ats_selptrset_mac(anairiats_rec_13, tmp349, atslab_d3lab1_node, tmp350) ; return (tmp349) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22702(line=877, offs=23) -- 22778(line=879, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__m3atch_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp351) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__m3atch_make: tmp351 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp351, atslab_m3atch_loc, arg0) ; ats_selptrset_mac(anairiats_rec_27, tmp351, atslab_m3atch_exp, arg1) ; ats_selptrset_mac(anairiats_rec_27, tmp351, atslab_m3atch_pat, arg2) ; return (tmp351) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__m3atch_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22801(line=881, offs=22) -- 22940(line=886, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__c3lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp352) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__c3lau_make: tmp352 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_gua, arg2) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_seq, arg3) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_neg, arg4) ; ats_selptrset_mac(anairiats_rec_14, tmp352, atslab_c3lau_exp, arg5) ; return (tmp352) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__c3lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 22987(line=888, offs=23) -- 23063(line=890, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__sc3lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp353) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__sc3lau_make: tmp353 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp353, atslab_sc3lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp353, atslab_sc3lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_15, tmp353, atslab_sc3lau_exp, arg2) ; return (tmp353) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__sc3lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23133(line=894, offs=24) -- 23210(line=896, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp354) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make: tmp354 = ATS_MALLOC(sizeof(anairiats_rec_16)) ; ats_selptrset_mac(anairiats_rec_16, tmp354, atslab_v3aldec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_16, tmp354, atslab_v3aldec_pat, arg1) ; ats_selptrset_mac(anairiats_rec_16, tmp354, atslab_v3aldec_def, arg2) ; return (tmp354) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23262(line=899, offs=3) -- 23455(line=906, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp355) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make: tmp355 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_knd, arg1) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_dvar_ptr, arg2) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_dvar_viw, arg3) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_typ, arg4) ; ats_selptrset_mac(anairiats_rec_17, tmp355, atslab_v3ardec_ini, arg5) ; return (tmp355) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23526(line=910, offs=24) -- 23603(line=912, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__f3undec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp356) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__f3undec_make: tmp356 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp356, atslab_f3undec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_28, tmp356, atslab_f3undec_var, arg1) ; ats_selptrset_mac(anairiats_rec_28, tmp356, atslab_f3undec_def, arg2) ; return (tmp356) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__f3undec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23674(line=916, offs=24) -- 23836(line=921, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__i3mpdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp357) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__i3mpdec_make: tmp357 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp357, atslab_i3mpdec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp357, atslab_i3mpdec_cst, arg1) ; ats_selptrset_mac(anairiats_rec_19, tmp357, atslab_i3mpdec_decarg, arg2) ; ats_selptrset_mac(anairiats_rec_19, tmp357, atslab_i3mpdec_tmparg, arg3) ; ats_selptrset_mac(anairiats_rec_19, tmp357, atslab_i3mpdec_def, arg4) ; return (tmp357) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__i3mpdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23904(line=925, offs=21) -- 23955(line=927, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none: tmp359 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cnone_0) ; tmp358 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp358, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp358, atslab_d3ec_node, tmp359) ; return (tmp358) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 23977(line=929, offs=21) -- 24038(line=931, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list: tmp361 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp361)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp361, atslab_0, arg1) ; tmp360 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp360, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp360, atslab_d3ec_node, tmp361) ; return (tmp360) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24063(line=933, offs=24) -- 24125(line=935, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_saspdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_saspdec: tmp363 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp363)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp363, atslab_0, arg1) ; tmp362 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp362, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp362, atslab_d3ec_node, tmp363) ; return (tmp362) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_saspdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24150(line=937, offs=24) -- 24224(line=939, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dcstdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dcstdec: tmp365 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp365)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp365, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp365, atslab_1, arg2) ; tmp364 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp364, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp364, atslab_d3ec_node, tmp365) ; return (tmp364) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dcstdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24248(line=941, offs=23) -- 24321(line=943, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_datdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_datdec: tmp367 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp367)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp367, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp367, atslab_1, arg2) ; tmp366 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp366, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp366, atslab_d3ec_node, tmp367) ; return (tmp366) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_datdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24345(line=945, offs=23) -- 24408(line=947, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_exndec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_exndec: tmp369 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp369)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp369, atslab_0, arg1) ; tmp368 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp368, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp368, atslab_d3ec_node, tmp369) ; return (tmp368) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_exndec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24432(line=949, offs=23) -- 24513(line=951, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extype (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extype: tmp371 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp371)->tag = 6 ; ats_selptrset_mac(anairiats_sum_1, tmp371, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp371, atslab_1, arg2) ; tmp370 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp370, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp370, atslab_d3ec_node, tmp371) ; return (tmp370) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24537(line=953, offs=23) -- 24618(line=955, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extval: tmp373 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp373)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp373, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp373, atslab_1, arg2) ; tmp372 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp372, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp372, atslab_d3ec_node, tmp373) ; return (tmp372) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24643(line=957, offs=24) -- 24727(line=959, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extcode (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extcode: tmp375 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp375)->tag = 8 ; ats_selptrset_mac(anairiats_sum_8, tmp375, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp375, atslab_1, arg2) ; tmp374 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp374, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp374, atslab_d3ec_node, tmp375) ; return (tmp374) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extcode] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24752(line=961, offs=24) -- 24832(line=963, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs: tmp377 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp377)->tag = 9 ; ats_selptrset_mac(anairiats_sum_1, tmp377, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp377, atslab_1, arg2) ; tmp376 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp376, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp376, atslab_d3ec_node, tmp377) ; return (tmp376) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24861(line=965, offs=28) -- 24929(line=967, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_par (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_par: tmp379 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp379)->tag = 10 ; ats_selptrset_mac(anairiats_sum_2, tmp379, atslab_0, arg1) ; tmp378 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp378, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp378, atslab_d3ec_node, tmp379) ; return (tmp378) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_par] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 24958(line=969, offs=28) -- 25026(line=971, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_rec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_rec: tmp381 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp381)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp381, atslab_0, arg1) ; tmp380 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp380, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp380, atslab_d3ec_node, tmp381) ; return (tmp380) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25051(line=973, offs=24) -- 25147(line=975, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_fundecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_fundecs: tmp383 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp383)->tag = 12 ; ats_selptrset_mac(anairiats_sum_21, tmp383, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp383, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp383, atslab_2, arg3) ; tmp382 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp382, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp382, atslab_d3ec_node, tmp383) ; return (tmp382) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_fundecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25172(line=977, offs=24) -- 25236(line=979, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_vardecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_vardecs: tmp385 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp385)->tag = 13 ; ats_selptrset_mac(anairiats_sum_2, tmp385, atslab_0, arg1) ; tmp384 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp384, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp384, atslab_d3ec_node, tmp385) ; return (tmp384) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_vardecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25260(line=981, offs=23) -- 25321(line=983, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_impdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_impdec: tmp387 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp387)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp387, atslab_0, arg1) ; tmp386 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp386, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp386, atslab_d3ec_node, tmp387) ; return (tmp386) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_impdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25344(line=985, offs=22) -- 25438(line=987, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_local (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_local: tmp389 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp389)->tag = 15 ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp389, atslab_1, arg2) ; tmp388 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp388, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp388, atslab_d3ec_node, tmp389) ; return (tmp388) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25486(line=989, offs=24) -- 25582(line=991, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_staload (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_staload: tmp391 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp391)->tag = 16 ; ats_selptrset_mac(anairiats_sum_20, tmp391, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp391, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_20, tmp391, atslab_2, arg3) ; tmp390 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp390, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp390, atslab_d3ec_node, tmp391) ; return (tmp390) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_staload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 25632(line=993, offs=24) -- 25694(line=995, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dynload: tmp393 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp393)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp393, atslab_0, arg1) ; tmp392 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp392, atslab_d3ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp392, atslab_d3ec_node, tmp393) ; return (tmp392) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 26027(line=1016, offs=3) -- 26148(line=1019, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ: do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp395 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp396 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp397 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp395), atslab_d3exp_typ) ; tmp398 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ (tmp396) ; tmp394 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp394, atslab_0, tmp397) ; ats_selptrset_mac(anairiats_sum_11, tmp394, atslab_1, tmp398) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: tmp394 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp394) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3.dats: 26211(line=1023, offs=3) -- 26437(line=1028, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp401 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_1) ; tmp402 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_2) ; tmp403 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp401), atslab_d3exp_typ) ; tmp404 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ (tmp402) ; tmp399 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp399, atslab_0, tmp400) ; ats_selptrset_mac(anairiats_sum_12, tmp399, atslab_1, tmp403) ; ats_selptrset_mac(anairiats_sum_12, tmp399, atslab_2, tmp404) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp399 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp399) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_p3at_set_typ ( ats_ptr_type p3t, ats_ptr_type s2e) { ((p3at_t)p3t)->atslab_p3at_typ = s2e ; return ; } // end of [atsopt_p3at_set_typ] ats_void_type atsopt_p3at_set_typ_lft ( ats_ptr_type p3t, ats_ptr_type os2e) { ((p3at_t)p3t)->atslab_p3at_typ_lft = os2e ; return ; } // end of [atsopt_p3at_set_typ_lft] ats_void_type ats_dynexp3_d3exp_set_typ ( ats_ptr_type d3e, ats_ptr_type s2e ) { ((d3exp_t)d3e)->atslab_d3exp_typ = s2e ; return ; } // end of [ats_dynexp3_d3exp_set_typ] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp3_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_posmark_dats.c0000664000175000017500000026413412223166160021605 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "libc/CATS/stdio.cats" #include "libc/CATS/stdlib.cats" /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_lint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMcomment_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMextern_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMkeyword_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMneuexp_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstaexp_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMprfexp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstdec_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstuse_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstdec_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstimp_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstuse_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_char_type, atspre_char_of_int) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isalnum) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_int_of_char) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_div_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_mod_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_compare_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_char) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_isucc) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_lint_type, atspre_lint_of_int) (ats_int_type) ; ATSextern_fun(ats_lint_type, atspre_succ_lint) (ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_lt_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_gt_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_void_type, atspre_fprint_lint) (ats_ref_type, ats_lint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_atend) (ats_ptr_type, ats_size_type) ; ATSextern_val(ats_ptr_type, atspre_stropt_none) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_bool_type, atspre_test_file_exists) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_array_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atslib_fopen_exn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_fclose_exn) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_fputc_exn) (ats_char_type, ats_ref_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, atsopt_filename_full) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ats_array_ptr_alloc_tsz) (ats_int_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_fun_coerce) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ats_posmark_xref_flag_get) () ; ATSextern_fun(ats_ptr_type, posmark_htmlfilename_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ats_posmark_xref_flag_get) () ; ATSextern_fun(ats_void_type, ats_posmark_initialize) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMcomment_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMextern_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMkeyword_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMneuexp_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstaexp_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMprfexp_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstdec_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstuse_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstdec_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstimp_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstuse_11) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_int_type int_of_posmark_0 (ats_ptr_type arg0) ; static ats_int_type compare_posmark_posmark_1 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type ref_make_elt_01952_ats_int_type (ats_int_type arg0) ; static ats_ptr_type ref_make_elt_01952_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type the_posmarklst_get_8 () ; static ats_void_type the_posmarklst_insert_9 (ats_lint_type arg0, ats_ptr_type arg1) ; static ats_void_type list_vt_free_01912_anairiats_rec_2 (ats_ptr_type arg0) ; static ats_void_type aux_15 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type list_vt_copy_01910_anairiats_rec_2 (ats_ptr_type arg0) ; static ats_int_type cmp_39 (ats_ref_type arg0, ats_ref_type arg1) ; static ats_ptr_type loop_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_42 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_int_type list_vt_length_01914_anairiats_rec_2 (ats_ptr_type arg0) ; static ats_void_type aux_45 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type array_ptr_initialize_lst_vt_01888_anairiats_rec_2 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type array_ptr_make_lst_vt_01889_anairiats_rec_2 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type posmarklst_sort_38 (ats_ptr_type arg0) ; static ats_void_type lpfin1_47 (ats_ptr_type env0, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_clo_ptr_type lpfin1_47_closure_make (ats_ptr_type env0) ; static ats_void_type lpfin1_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type lpfin2_48 (ats_ptr_type env0, ats_ref_type arg0, ats_ref_type arg1) ; static ats_clo_ptr_type lpfin2_48_closure_make (ats_ptr_type env0) ; static ats_void_type lpfin2_48_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1) ; static ats_void_type loop1_49 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_clo_ptr_type loop1_49_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type loop1_49_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_void_type loop2_50 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6) ; static ats_clo_ptr_type loop2_50_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type loop2_50_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6) ; static ats_void_type loop1_49_0loop2_50 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ...) ; static ats_clo_ptr_type loop1_49_0loop2_50_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type loop1_49_0loop2_50_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ...) ; static ats_void_type posmark_file_file_46 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type loop_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) ; static ats_void_type fprint_stadyncstpos_53 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type posmark_process_htm_52 (ats_ref_type arg0, ats_lint_type arg1, ats_ptr_type arg2) ; static ats_void_type fputchr_htm_55 (ats_char_type arg0, ats_ref_type arg1) ; static ats_char_type char_of_xdigit_57 (ats_int_type arg0) ; static ats_ptr_type loop_59 (ats_ptr_type arg0, ats_size_type arg1, ats_ptr_type arg2) ; static ats_ptr_type posmark_xref_testnot_58 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp26) ; ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp32) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp34) ; // ATSstatic_void (statmp347) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 3495(line=130, offs=4) -- 4197(line=150, offs=61) */ ATSstaticdec() ats_int_type int_of_posmark_0 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp0) ; ATSlocal (ats_int_type, tmp1) ; ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_bool_type, tmp4) ; ATSlocal (ats_int_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_int_type, tmp13) ; ATSlocal (ats_bool_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_bool_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_bool_type, tmp20) ; ATSlocal (ats_int_type, tmp21) ; ATSlocal (ats_bool_type, tmp22) ; __ats_lab_int_of_posmark_0: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp0 = 0 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp2 = atspre_gt_int_int (tmp1, 0) ; if (tmp2) { tmp0 = 1 ; } else { tmp0 = atspre_isub (100, 1) ; } /* end of [if] */ break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp4 = atspre_gt_int_int (tmp3, 0) ; if (tmp4) { tmp0 = 2 ; } else { tmp0 = atspre_isub (100, 2) ; } /* end of [if] */ break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp6 = atspre_gt_int_int (tmp5, 0) ; if (tmp6) { tmp0 = 3 ; } else { tmp0 = atspre_isub (100, 3) ; } /* end of [if] */ break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp8 = atspre_gt_int_int (tmp7, 0) ; if (tmp8) { tmp0 = 4 ; } else { tmp0 = atspre_isub (100, 4) ; } /* end of [if] */ break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp10 = atspre_gt_int_int (tmp9, 0) ; if (tmp10) { tmp0 = 5 ; } else { tmp0 = atspre_isub (100, 5) ; } /* end of [if] */ break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 8) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp12 = atspre_gt_int_int (tmp11, 0) ; if (tmp12) { tmp0 = 6 ; } else { tmp0 = atspre_isub (100, 6) ; } /* end of [if] */ break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp14 = atspre_gt_int_int (tmp13, 0) ; if (tmp14) { tmp0 = 7 ; } else { tmp0 = atspre_isub (100, 7) ; } /* end of [if] */ break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp16 = atspre_gt_int_int (tmp15, 0) ; if (tmp16) { tmp0 = 8 ; } else { tmp0 = atspre_isub (100, 8) ; } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 9) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp18 = atspre_gt_int_int (tmp17, 0) ; if (tmp18) { tmp0 = 20 ; } else { tmp0 = atspre_isub (100, 20) ; } /* end of [if] */ break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp20 = atspre_gt_int_int (tmp19, 0) ; if (tmp20) { tmp0 = 21 ; } else { tmp0 = atspre_isub (100, 21) ; } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (((ats_sum_ptr_type)arg0)->tag != 11) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp22 = atspre_gt_int_int (tmp21, 0) ; if (tmp22) { tmp0 = 22 ; } else { tmp0 = atspre_isub (100, 22) ; } /* end of [if] */ break ; } while (0) ; return (tmp0) ; } /* end of [int_of_posmark_0] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 4229(line=153, offs=4) -- 4341(line=155, offs=51) */ ATSstaticdec() ats_int_type compare_posmark_posmark_1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; __ats_lab_compare_posmark_posmark_1: tmp24 = int_of_posmark_0 (arg0) ; tmp25 = int_of_posmark_0 (arg1) ; tmp23 = atspre_compare_int_int (tmp24, tmp25) ; return (tmp23) ; } /* end of [compare_posmark_posmark_1] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01952_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_int_type, tmp28) ; __ats_lab_ref_make_elt_01952_ats_int_type: /* ats_int_type tmp28 ; */ tmp28 = arg0 ; tmp27 = atspre_ref_make_elt_tsz ((&tmp28), sizeof(ats_int_type)) ; return (tmp27) ; } /* end of [ref_make_elt_01952_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01952_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ref_make_elt_01952_ats_ptr_type: /* ats_ptr_type tmp31 ; */ tmp31 = arg0 ; tmp30 = atspre_ref_make_elt_tsz ((&tmp31), sizeof(ats_ptr_type)) ; return (tmp30) ; } /* end of [ref_make_elt_01952_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 4785(line=174, offs=26) -- 4813(line=174, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable () { /* local vardec */ // ATSlocal_void (tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable: ats_ptrget_mac(ats_int_type, statmp26) = 1 ; return /* (tmp35) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 4841(line=175, offs=27) -- 4869(line=175, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () { /* local vardec */ // ATSlocal_void (tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable: ats_ptrget_mac(ats_int_type, statmp26) = 0 ; return /* (tmp36) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 4900(line=177, offs=29) -- 4975(line=179, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get () { /* local vardec */ ATSlocal (ats_int_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get: tmp38 = ats_ptrget_mac(ats_int_type, statmp26) ; ats_ptrget_mac(ats_int_type, statmp26) = 0 ; tmp37 = tmp38 ; return (tmp37) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 5038(line=182, offs=3) -- 5072(line=182, offs=37) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set: ats_ptrget_mac(ats_int_type, statmp26) = arg0 ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 5108(line=185, offs=4) -- 5255(line=190, offs=4) */ ATSstaticdec() ats_ptr_type the_posmarklst_get_8 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_the_posmarklst_get_8: tmp41 = atspre_ref_get_view_ptr (statmp29) ; tmp42 = ats_selsin_mac(tmp41, atslab_1) ; tmp43 = ats_ptrget_mac(ats_ptr_type, tmp42) ; tmp44 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp42) = tmp44 ; tmp40 = tmp43 ; return (tmp40) ; } /* end of [the_posmarklst_get_8] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 5291(line=192, offs=4) -- 5499(line=198, offs=6) */ ATSstaticdec() ats_void_type the_posmarklst_insert_9 (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp45) ; ATSlocal (ats_bool_type, tmp46) ; ATSlocal (ats_int_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (anairiats_rec_2, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_the_posmarklst_insert_9: tmp47 = ats_ptrget_mac(ats_int_type, statmp26) ; tmp46 = atspre_gt_int_int (tmp47, 0) ; if (tmp46) { tmp48 = atspre_ref_get_view_ptr (statmp29) ; tmp49 = ats_selsin_mac(tmp48, atslab_1) ; tmp51.atslab_0 = arg0 ; tmp51.atslab_1 = arg1 ; tmp52 = ats_ptrget_mac(ats_ptr_type, tmp49) ; tmp50 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp50, atslab_0, tmp51) ; ats_selptrset_mac(anairiats_sum_3, tmp50, atslab_1, tmp52) ; ats_ptrget_mac(ats_ptr_type, tmp49) = tmp50 ; } else { /* empty */ } /* end of [if] */ return /* (tmp45) */ ; } /* end of [the_posmarklst_insert_9] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7914(line=306, offs=27) -- 8015(line=310, offs=4) */ ATSstaticdec() ats_void_type list_vt_free_01912_anairiats_rec_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_list_vt_free_01912_anairiats_rec_2: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp69 ; goto __ats_lab_list_vt_free_01912_anairiats_rec_2 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: break ; } while (0) ; return /* (tmp68) */ ; } /* end of [list_vt_free_01912_anairiats_rec_2] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 5571(line=201, offs=23) -- 6336(line=227, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop () { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop: tmp54 = atspre_ref_get_view_ptr (statmp33) ; tmp55 = ats_selsin_mac(tmp54, atslab_1) ; tmp57 = ats_ptrget_mac(ats_ptr_type, tmp55) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp57 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_4, tmp57, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_4, tmp57, atslab_1) ; ATS_FREE(tmp57) ; ats_ptrget_mac(ats_ptr_type, tmp55) = tmp59 ; tmp56 = tmp58 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp57 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp60 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_posmark)")) ; /* tmp61 = */ atspre_prerr_string (ATSstrcst(": posmark_pop: empty stack")) ; /* tmp62 = */ atspre_prerr_newline () ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp64 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp55) = tmp64 ; tmp56 = tmp63 ; break ; } while (0) ; tmp65 = atspre_ref_get_view_ptr (statmp29) ; tmp66 = ats_selsin_mac(tmp65, atslab_1) ; tmp67 = ats_ptrget_mac(ats_ptr_type, tmp66) ; ats_ptrget_mac(ats_ptr_type, tmp66) = tmp56 ; /* tmp53 = */ list_vt_free_01912_anairiats_rec_2 (tmp67) ; return /* (tmp53) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 6385(line=229, offs=24) -- 6691(line=243, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push () { /* local vardec */ // ATSlocal_void (tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push: tmp71 = atspre_ref_get_view_ptr (statmp29) ; tmp72 = ats_selsin_mac(tmp71, atslab_1) ; tmp73 = ats_ptrget_mac(ats_ptr_type, tmp72) ; tmp74 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp72) = tmp74 ; tmp75 = atspre_ref_get_view_ptr (statmp33) ; tmp76 = ats_selsin_mac(tmp75, atslab_1) ; tmp78 = ats_ptrget_mac(ats_ptr_type, tmp76) ; tmp77 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp77, atslab_0, tmp73) ; ats_selptrset_mac(anairiats_sum_4, tmp77, atslab_1, tmp78) ; ats_ptrget_mac(ats_ptr_type, tmp76) = tmp77 ; return /* (tmp70) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7198(line=282, offs=7) -- 7656(line=294, offs=6) */ ATSstaticdec() ats_void_type aux_15 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (anairiats_rec_2, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_aux_15: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp86 = &ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp87 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp87, atslab_0, tmp85) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp87 ; // if (ats_ptrget_mac(ats_ptr_type, arg1) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp88 = &ats_caselptrlab_mac(anairiats_sum_3, ats_ptrget_mac(ats_ptr_type, arg1), atslab_1) ; tmp89 = ats_ptrget_mac(ats_ptr_type, tmp86) ; arg0 = tmp89 ; arg1 = tmp88 ; goto __ats_lab_aux_15 ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp90 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp90 ; break ; } while (0) ; return /* (tmp84) */ ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7181(line=281, offs=14) -- 7741(line=298, offs=4) */ ATSstaticdec() ats_ptr_type list_vt_copy_01910_anairiats_rec_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; __ats_lab_list_vt_copy_01910_anairiats_rec_2: /* ats_ptr_type tmp91 ; */ /* tmp92 = */ aux_15 (arg0, (&tmp91)) ; tmp83 = tmp91 ; return (tmp83) ; } /* end of [list_vt_copy_01910_anairiats_rec_2] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 6745(line=245, offs=28) -- 7033(line=258, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push_dup () { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push_dup: tmp80 = atspre_ref_get_view_ptr (statmp29) ; tmp81 = ats_selsin_mac(tmp80, atslab_1) ; tmp93 = ats_ptrget_mac(ats_ptr_type, tmp81) ; tmp82 = list_vt_copy_01910_anairiats_rec_2 (tmp93) ; tmp94 = atspre_ref_get_view_ptr (statmp33) ; tmp95 = ats_selsin_mac(tmp94, atslab_1) ; tmp97 = ats_ptrget_mac(ats_ptr_type, tmp95) ; tmp96 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp96, atslab_0, tmp82) ; ats_selptrset_mac(anairiats_sum_4, tmp96, atslab_1, tmp97) ; ats_ptrget_mac(ats_ptr_type, tmp95) = tmp96 ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push_dup] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7141(line=265, offs=28) -- 7185(line=265, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg: tmp99 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp99)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp99, atslab_0, 0) ; /* tmp98 = */ the_posmarklst_insert_9 (arg0, tmp99) ; return /* (tmp98) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7223(line=267, offs=28) -- 7267(line=267, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end: tmp101 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp101)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp101, atslab_0, 1) ; /* tmp100 = */ the_posmarklst_insert_9 (arg0, tmp101) ; return /* (tmp100) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7305(line=270, offs=27) -- 7348(line=270, offs=70) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_beg: tmp103 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp103)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp103, atslab_0, 0) ; /* tmp102 = */ the_posmarklst_insert_9 (arg0, tmp103) ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7385(line=272, offs=27) -- 7428(line=272, offs=70) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_end: tmp105 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp105)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp105, atslab_0, 1) ; /* tmp104 = */ the_posmarklst_insert_9 (arg0, tmp105) ; return /* (tmp104) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7471(line=277, offs=28) -- 7630(line=285, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_beg: tmp107 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp107)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp107, atslab_0, 0) ; /* tmp106 = */ the_posmarklst_insert_9 (arg0, tmp107) ; return /* (tmp106) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7708(line=288, offs=28) -- 7867(line=296, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_end: tmp109 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp109)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp109, atslab_0, 1) ; /* tmp108 = */ the_posmarklst_insert_9 (arg0, tmp109) ; return /* (tmp108) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 7948(line=300, offs=37) -- 7993(line=301, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_beg: tmp111 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp111)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp111, atslab_0, 0) ; /* tmp110 = */ the_posmarklst_insert_9 (arg0, tmp111) ; return /* (tmp110) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8030(line=302, offs=37) -- 8075(line=303, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_end: tmp113 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp113)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp113, atslab_0, 1) ; /* tmp112 = */ the_posmarklst_insert_9 (arg0, tmp113) ; return /* (tmp112) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8113(line=305, offs=37) -- 8158(line=306, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg: tmp115 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp115)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp115, atslab_0, 0) ; /* tmp114 = */ the_posmarklst_insert_9 (arg0, tmp115) ; return /* (tmp114) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8195(line=307, offs=37) -- 8240(line=308, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end: tmp117 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp117)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp117, atslab_0, 1) ; /* tmp116 = */ the_posmarklst_insert_9 (arg0, tmp117) ; return /* (tmp116) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8278(line=310, offs=37) -- 8323(line=311, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_beg (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_beg: tmp119 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp119)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp119, atslab_0, 0) ; /* tmp118 = */ the_posmarklst_insert_9 (arg0, tmp119) ; return /* (tmp118) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8360(line=312, offs=37) -- 8405(line=313, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_end (ats_lint_type arg0) { /* local vardec */ // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_end: tmp121 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp121)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp121, atslab_0, 1) ; /* tmp120 = */ the_posmarklst_insert_9 (arg0, tmp121) ; return /* (tmp120) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8450(line=317, offs=40) -- 8510(line=318, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_beg (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_beg: tmp123 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp123)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp123, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_1, tmp123, atslab_1, arg1) ; /* tmp122 = */ the_posmarklst_insert_9 (arg0, tmp123) ; return /* (tmp122) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8550(line=319, offs=40) -- 8610(line=320, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_end (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_end: tmp125 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp125)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp125, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp125, atslab_1, arg1) ; /* tmp124 = */ the_posmarklst_insert_9 (arg0, tmp125) ; return /* (tmp124) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8651(line=322, offs=40) -- 8711(line=323, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_beg (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_beg: tmp127 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp127)->tag = 8 ; ats_selptrset_mac(anairiats_sum_1, tmp127, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_1, tmp127, atslab_1, arg1) ; /* tmp126 = */ the_posmarklst_insert_9 (arg0, tmp127) ; return /* (tmp126) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8751(line=324, offs=40) -- 8811(line=325, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_end (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_end: tmp129 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp129)->tag = 8 ; ats_selptrset_mac(anairiats_sum_1, tmp129, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp129, atslab_1, arg1) ; /* tmp128 = */ the_posmarklst_insert_9 (arg0, tmp129) ; return /* (tmp128) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8856(line=329, offs=40) -- 8916(line=330, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_beg (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_beg: tmp131 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp131)->tag = 9 ; ats_selptrset_mac(anairiats_sum_1, tmp131, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_1, tmp131, atslab_1, arg1) ; /* tmp130 = */ the_posmarklst_insert_9 (arg0, tmp131) ; return /* (tmp130) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 8956(line=331, offs=40) -- 9016(line=332, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_end (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_end: tmp133 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp133)->tag = 9 ; ats_selptrset_mac(anairiats_sum_1, tmp133, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp133, atslab_1, arg1) ; /* tmp132 = */ the_posmarklst_insert_9 (arg0, tmp133) ; return /* (tmp132) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 9057(line=334, offs=40) -- 9117(line=335, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_beg (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_beg: tmp135 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp135)->tag = 10 ; ats_selptrset_mac(anairiats_sum_1, tmp135, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_1, tmp135, atslab_1, arg1) ; /* tmp134 = */ the_posmarklst_insert_9 (arg0, tmp135) ; return /* (tmp134) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 9157(line=336, offs=40) -- 9217(line=337, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_end (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_end: tmp137 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp137)->tag = 10 ; ats_selptrset_mac(anairiats_sum_1, tmp137, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp137, atslab_1, arg1) ; /* tmp136 = */ the_posmarklst_insert_9 (arg0, tmp137) ; return /* (tmp136) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 9258(line=339, offs=40) -- 9318(line=340, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_beg (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_beg: tmp139 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp139)->tag = 11 ; ats_selptrset_mac(anairiats_sum_1, tmp139, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_1, tmp139, atslab_1, arg1) ; /* tmp138 = */ the_posmarklst_insert_9 (arg0, tmp139) ; return /* (tmp138) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 9358(line=341, offs=40) -- 9418(line=342, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_end (ats_lint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_end: tmp141 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp141)->tag = 11 ; ats_selptrset_mac(anairiats_sum_1, tmp141, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp141, atslab_1, arg1) ; /* tmp140 = */ the_posmarklst_insert_9 (arg0, tmp141) ; return /* (tmp140) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstuse_end] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 13034(line=462, offs=6) -- 13245(line=468, offs=6) */ ATSstaticdec() ats_int_type cmp_39 (ats_ref_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_lint_type, tmp144) ; ATSlocal (ats_lint_type, tmp145) ; ATSlocal (ats_bool_type, tmp146) ; ATSlocal (ats_bool_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_cmp_39: tmp144 = ats_select_mac(ats_ptrget_mac(anairiats_rec_2, arg0), atslab_0) ; tmp145 = ats_select_mac(ats_ptrget_mac(anairiats_rec_2, arg1), atslab_0) ; tmp146 = atspre_lt_lint_lint (tmp144, tmp145) ; if (tmp146) { tmp143 = -1 ; } else { tmp147 = atspre_gt_lint_lint (tmp144, tmp145) ; if (tmp147) { tmp143 = 1 ; } else { tmp148 = ats_select_mac(ats_ptrget_mac(anairiats_rec_2, arg0), atslab_1) ; tmp149 = ats_select_mac(ats_ptrget_mac(anairiats_rec_2, arg1), atslab_1) ; tmp143 = compare_posmark_posmark_1 (tmp148, tmp149) ; } /* end of [if] */ } /* end of [if] */ return (tmp143) ; } /* end of [cmp_39] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 13271(line=470, offs=7) -- 13523(line=478, offs=8) */ ATSstaticdec() ats_ptr_type loop_40 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_bool_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (anairiats_rec_2, tmp154) ; __ats_lab_loop_40: tmp151 = atspre_igte (arg1, 0) ; if (tmp151) { tmp152 = atspre_isub (arg1, 1) ; tmp154 = ats_caselptrind_mac(anairiats_rec_2, arg0, [arg1]) ; tmp153 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_0, tmp154) ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_1, arg2) ; arg0 = arg0 ; arg1 = tmp152 ; arg2 = tmp153 ; goto __ats_lab_loop_40 ; // tail call } else { tmp150 = arg2 ; } /* end of [if] */ return (tmp150) ; } /* end of [loop_40] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8171(line=319, offs=7) -- 8400(line=325, offs=38) */ ATSstaticdec() ats_int_type aux_42 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; __ats_lab_aux_42: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp158 = &ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp159 = ats_ptrget_mac(ats_ptr_type, tmp158) ; tmp160 = atspre_iadd (arg1, 1) ; arg0 = tmp159 ; arg1 = tmp160 ; goto __ats_lab_aux_42 ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp157 = arg1 ; break ; } while (0) ; return (tmp157) ; } /* end of [aux_42] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8154(line=318, offs=16) -- 8439(line=329, offs=4) */ ATSstaticdec() ats_int_type list_vt_length_01914_anairiats_rec_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp156) ; __ats_lab_list_vt_length_01914_anairiats_rec_2: tmp156 = aux_42 (arg0, 0) ; return (tmp156) ; } /* end of [list_vt_length_01914_anairiats_rec_2] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 3585(line=113, offs=7) -- 4120(line=127, offs=6) */ ATSstaticdec() ats_void_type aux_45 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp167) ; ATSlocal (anairiats_rec_2, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_aux_45: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; ATS_FREE(arg1) ; ats_ptrget_mac(anairiats_rec_2, arg0) = tmp168 ; tmp170 = atspre_padd_size (arg0, sizeof(anairiats_rec_2)) ; arg0 = tmp170 ; arg1 = tmp169 ; goto __ats_lab_aux_45 ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: break ; } while (0) ; return /* (tmp167) */ ; } /* end of [aux_45] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 3563(line=112, offs=29) -- 4208(line=131, offs=4) */ ATSstaticdec() ats_void_type array_ptr_initialize_lst_vt_01888_anairiats_rec_2 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp166) ; __ats_lab_array_ptr_initialize_lst_vt_01888_anairiats_rec_2: /* tmp166 = */ aux_45 (arg0, arg1) ; return /* (tmp166) */ ; } /* end of [array_ptr_initialize_lst_vt_01888_anairiats_rec_2] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 4285(line=134, offs=23) -- 4437(line=139, offs=4) */ ATSstaticdec() ats_ptr_type array_ptr_make_lst_vt_01889_anairiats_rec_2 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; // ATSlocal_void (tmp165) ; __ats_lab_array_ptr_make_lst_vt_01889_anairiats_rec_2: tmp163 = ats_array_ptr_alloc_tsz (arg0, sizeof(anairiats_rec_2)) ; tmp164 = ats_selsin_mac(tmp163, atslab_2) ; /* tmp165 = */ array_ptr_initialize_lst_vt_01888_anairiats_rec_2 (tmp164, arg1) ; tmp162 = tmp164 ; return (tmp162) ; } /* end of [array_ptr_make_lst_vt_01889_anairiats_rec_2] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 12929(line=456, offs=4) -- 13867(line=490, offs=4) */ ATSstaticdec() ats_ptr_type posmarklst_sort_38 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_int_type, tmp155) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; ATSlocal (ats_size_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_int_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; // ATSlocal_void (tmp177) ; __ats_lab_posmarklst_sort_38: tmp155 = list_vt_length_01914_anairiats_rec_2 (arg0) ; tmp161 = array_ptr_make_lst_vt_01889_anairiats_rec_2 (tmp155, arg0) ; tmp171 = ats_selsin_mac(tmp161, atslab_2) ; tmp173 = atspre_size1_of_int1 (tmp155) ; /* tmp172 = */ atslib_qsort (tmp171, tmp173, sizeof(anairiats_rec_2), &cmp_39) ; tmp175 = atspre_isub (tmp155, 1) ; tmp176 = (ats_sum_ptr_type)0 ; tmp174 = loop_40 (tmp171, tmp175, tmp176) ; /* tmp177 = */ atspre_array_ptr_free (tmp171) ; tmp142 = tmp174 ; return (tmp142) ; } /* end of [posmarklst_sort_38] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 14160(line=503, offs=7) -- 14454(line=515, offs=6) */ ATSstaticdec() ats_void_type lpfin1_47 (ats_ptr_type env0, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; ATSlocal (anairiats_rec_2, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_lint_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_lpfin1_47: /* tmp180 = */ ((ats_void_type(*)(ats_ref_type, ats_lint_type, ats_ptr_type))env0) (arg1, arg2, arg3) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_1) ; ATS_FREE(arg4) ; tmp183 = ats_select_mac(tmp181, atslab_0) ; tmp184 = ats_select_mac(tmp181, atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp183 ; arg3 = tmp184 ; arg4 = tmp182 ; goto __ats_lab_lpfin1_47 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: break ; } while (0) ; return /* (tmp179) */ ; } /* end of [lpfin1_47] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } lpfin1_47_closure_type ; ats_void_type lpfin1_47_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { lpfin1_47 (((lpfin1_47_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3, arg4) ; return ; } /* end of function */ ATSinline() ats_void_type lpfin1_47_closure_init (lpfin1_47_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&lpfin1_47_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type lpfin1_47_closure_make (ats_ptr_type env0) { lpfin1_47_closure_type *p_clo = ATS_MALLOC(sizeof(lpfin1_47_closure_type)) ; lpfin1_47_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 14483(line=517, offs=7) -- 14723(line=525, offs=6) */ ATSstaticdec() ats_void_type lpfin2_48 (ats_ptr_type env0, ats_ref_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp185) ; ATSlocal (ats_int_type, tmp186) ; ATSlocal (ats_bool_type, tmp187) ; // ATSlocal_void (tmp188) ; ATSlocal (ats_char_type, tmp189) ; __ats_lab_lpfin2_48: tmp186 = atslib_fgetc_err (arg0) ; tmp187 = atspre_gte_int_int (tmp186, 0) ; if (tmp187) { tmp189 = atspre_char_of_int (tmp186) ; /* tmp188 = */ ((ats_void_type(*)(ats_char_type, ats_ref_type))env0) (tmp189, arg1) ; arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_lpfin2_48 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp185) */ ; } /* end of [lpfin2_48] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } lpfin2_48_closure_type ; ats_void_type lpfin2_48_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1) { lpfin2_48 (((lpfin2_48_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type lpfin2_48_closure_init (lpfin2_48_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&lpfin2_48_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type lpfin2_48_closure_make (ats_ptr_type env0) { lpfin2_48_closure_type *p_clo = ATS_MALLOC(sizeof(lpfin2_48_closure_type)) ; lpfin2_48_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 14752(line=527, offs=7) -- 15092(line=538, offs=6) */ ATSstaticdec() ats_void_type loop1_49 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp219) ; /* tmp219 = */ loop1_49_0loop2_50 (env0, env1, 0, arg0, arg1, arg2, arg3, arg4, arg5) ; return /* (tmp219) */ ; } /* end of [loop1_49] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } loop1_49_closure_type ; ats_void_type loop1_49_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { loop1_49 (((loop1_49_closure_type*)cloptr)->closure_env_0, ((loop1_49_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3, arg4, arg5) ; return ; } /* end of function */ ATSinline() ats_void_type loop1_49_closure_init (loop1_49_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop1_49_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop1_49_closure_make (ats_ptr_type env0, ats_ptr_type env1) { loop1_49_closure_type *p_clo = ATS_MALLOC(sizeof(loop1_49_closure_type)) ; loop1_49_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 15123(line=540, offs=7) -- 15757(line=559, offs=6) */ ATSstaticdec() ats_void_type loop2_50 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6) { /* local vardec */ // ATSlocal_void (tmp220) ; /* tmp220 = */ loop1_49_0loop2_50 (env0, env1, 1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return /* (tmp220) */ ; } /* end of [loop2_50] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } loop2_50_closure_type ; ats_void_type loop2_50_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_lint_type arg2, ats_lint_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6) { loop2_50 (((loop2_50_closure_type*)cloptr)->closure_env_0, ((loop2_50_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return ; } /* end of function */ ATSinline() ats_void_type loop2_50_closure_init (loop2_50_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&loop2_50_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type loop2_50_closure_make (ats_ptr_type env0, ats_ptr_type env1) { loop2_50_closure_type *p_clo = ATS_MALLOC(sizeof(loop2_50_closure_type)) ; loop2_50_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 14752(line=527, offs=7) -- 15757(line=559, offs=6) */ ATSstaticdec() ats_void_type loop1_49_0loop2_50 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ref_type, tmp190) ; ATSlocal (ats_ref_type, tmp191) ; ATSlocal (ats_lint_type, tmp192) ; ATSlocal (ats_lint_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ref_type, tmp196) ; ATSlocal (ats_ref_type, tmp197) ; ATSlocal (ats_lint_type, tmp198) ; ATSlocal (ats_lint_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_int_type, tmp202) ; // ATSlocal_void (tmp203) ; ATSlocal (ats_int_type, tmp204) ; ATSlocal (ats_bool_type, tmp205) ; // ATSlocal_void (tmp206) ; ATSlocal (ats_bool_type, tmp207) ; // ATSlocal_void (tmp208) ; ATSlocal (ats_char_type, tmp209) ; ATSlocal (ats_lint_type, tmp210) ; // ATSlocal_void (tmp211) ; ATSlocal (anairiats_rec_2, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_lint_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; // ATSlocal_void (tmp216) ; ATSlocal (ats_char_type, tmp217) ; // ATSlocal_void (tmp218) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp190 = va_arg(funarg, ats_ref_type) ; tmp191 = va_arg(funarg, ats_ref_type) ; tmp192 = va_arg(funarg, ats_lint_type) ; tmp193 = va_arg(funarg, ats_lint_type) ; tmp194 = va_arg(funarg, ats_ptr_type) ; tmp195 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_loop1_49 ; case 1: va_start(funarg, arg0) ; tmp196 = va_arg(funarg, ats_ref_type) ; tmp197 = va_arg(funarg, ats_ref_type) ; tmp198 = va_arg(funarg, ats_lint_type) ; tmp199 = va_arg(funarg, ats_lint_type) ; tmp200 = va_arg(funarg, ats_ptr_type) ; tmp201 = va_arg(funarg, ats_ptr_type) ; tmp202 = va_arg(funarg, ats_int_type) ; va_end(funarg) ; goto __ats_lab_loop2_50 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_loop1_49: tmp204 = atslib_fgetc_err (tmp190) ; tmp205 = atspre_gte_int_int (tmp204, 0) ; if (tmp205) { tmp196 = tmp190 ; tmp197 = tmp191 ; tmp198 = tmp192 ; tmp199 = tmp193 ; tmp200 = tmp194 ; tmp201 = tmp195 ; tmp202 = tmp204 ; goto __ats_lab_loop2_50 ; // tail call } else { /* tmp203 = */ lpfin1_47 (env0, tmp190, tmp191, tmp193, tmp194, tmp195) ; } /* end of [if] */ return /* tmp203 */ ; __ats_lab_loop2_50: tmp207 = atspre_lt_lint_lint (tmp198, tmp199) ; if (tmp207) { tmp209 = atspre_char_of_int (tmp202) ; /* tmp208 = */ ((ats_void_type(*)(ats_char_type, ats_ref_type))env1) (tmp209, tmp197) ; tmp210 = atspre_succ_lint (tmp198) ; tmp190 = tmp196 ; tmp191 = tmp197 ; tmp192 = tmp210 ; tmp193 = tmp199 ; tmp194 = tmp200 ; tmp195 = tmp201 ; goto __ats_lab_loop1_49 ; // tail call } else { /* tmp211 = */ ((ats_void_type(*)(ats_ref_type, ats_lint_type, ats_ptr_type))env0) (tmp197, tmp199, tmp200) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp201 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_3, tmp201, atslab_0) ; tmp213 = ats_caselptrlab_mac(anairiats_sum_3, tmp201, atslab_1) ; ATS_FREE(tmp201) ; tmp214 = ats_select_mac(tmp212, atslab_0) ; tmp215 = ats_select_mac(tmp212, atslab_1) ; tmp196 = tmp196 ; tmp197 = tmp197 ; tmp198 = tmp198 ; tmp199 = tmp214 ; tmp200 = tmp215 ; tmp201 = tmp213 ; tmp202 = tmp202 ; goto __ats_lab_loop2_50 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (tmp201 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp217 = atspre_char_of_int (tmp202) ; /* tmp216 = */ ((ats_void_type(*)(ats_char_type, ats_ref_type))env1) (tmp217, tmp197) ; /* tmp206 = */ lpfin2_48 (env1, tmp196, tmp197) ; break ; } while (0) ; } /* end of [if] */ return /* tmp206 */ ; return /* (tmp218) */ ; } /* end of [loop1_49_0loop2_50] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 13923(line=494, offs=4) -- 16290(line=577, offs=4) */ ATSstaticdec() ats_void_type posmark_file_file_46 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp178) ; ATSlocal (ats_lint_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; // ATSlocal_void (tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; // ATSlocal_void (tmp228) ; __ats_lab_posmark_file_file_46: tmp221 = atspre_lint_of_int (0) ; tmp223 = the_posmarklst_get_8 () ; tmp222 = posmarklst_sort_38 (tmp223) ; if (arg0) { /* tmp224 = */ atspre_fprint_string (arg4, ATSstrcst("\n\n\n \n \n \n\n\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp225 = */ atspre_fprint_string (arg4, ATSstrcst("
\n")) ;
tmp227 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMnone_0) ;
/* tmp226 = */ loop1_49 (arg1, arg2, arg3, arg4, tmp221, tmp221, tmp227, tmp222) ;
/* tmp228 = */ atspre_fprint_string (arg4, ATSstrcst("
\n")) ; if (arg0) { /* tmp178 = */ atspre_fprint_string (arg4, ATSstrcst("\n\n")) ; } else { /* empty */ } /* end of [if] */ return /* (tmp178) */ ; } /* end of [posmark_file_file_46] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 16581(line=588, offs=9) -- 17205(line=604, offs=10) */ ATSstaticdec() ats_void_type loop_54 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2) { /* local vardec */ // ATSlocal_void (tmp231) ; ATSlocal (ats_bool_type, tmp232) ; ATSlocal (ats_char_type, tmp233) ; // ATSlocal_void (tmp234) ; ATSlocal (ats_bool_type, tmp235) ; // ATSlocal_void (tmp236) ; ATSlocal (ats_uint_type, tmp237) ; ATSlocal (ats_size_type, tmp238) ; __ats_lab_loop_54: tmp232 = atspre_string_isnot_atend (arg1, arg2) ; if (tmp232) { tmp233 = atspre_string_get_char_at (arg1, arg2) ; do { /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp235 = atspre_char_isalnum (tmp233) ; if (!tmp235) { goto __ats_lab_27_1 ; } /* tmp234 = */ atspre_fprint_char (arg0, tmp233) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: /* tmp236 = */ atspre_fprint_char (arg0, '_') ; tmp237 = atspre_uint_of_char (tmp233) ; /* tmp234 = */ atspre_fprintf_exn (arg0, ATSstrcst("%2x"), tmp237) ; break ; } while (0) ; tmp238 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp238 ; goto __ats_lab_loop_54 ; // tail call } else { /* tmp231 = */ atspre_fprint_string (arg0, ATSstrcst(".html")) ; } /* end of [if] */ return /* (tmp231) */ ; } /* end of [loop_54] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 16426(line=584, offs=6) -- 17657(line=617, offs=6) */ ATSstaticdec() ats_void_type fprint_stadyncstpos_53 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; ATSlocal (ats_bool_type, tmp241) ; __ats_lab_fprint_stadyncstpos_53: tmp239 = ats_posmark_xref_flag_get () ; tmp241 = atspre_stropt_is_some (tmp239) ; if (tmp241) { /* tmp240 = */ atspre_fprint_string (arg0, ats_castfn_mac(ats_ptr_type, tmp239)) ; } else { /* empty */ } /* end of [if] */ /* tmp230 = */ loop_54 (arg0, ats_castfn_mac(ats_ptr_type, arg1), 0) ; return /* (tmp230) */ ; } /* end of [fprint_stadyncstpos_53] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 16346(line=581, offs=4) -- 22445(line=730, offs=4) */ ATSstaticdec() ats_void_type posmark_process_htm_52 (ats_ref_type arg0, ats_lint_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp229) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_bool_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; ATSlocal (ats_bool_type, tmp245) ; ATSlocal (ats_int_type, tmp246) ; ATSlocal (ats_bool_type, tmp247) ; ATSlocal (ats_int_type, tmp248) ; ATSlocal (ats_bool_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; ATSlocal (ats_bool_type, tmp251) ; ATSlocal (ats_int_type, tmp252) ; ATSlocal (ats_bool_type, tmp253) ; ATSlocal (ats_int_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_bool_type, tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_lint_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; ATSlocal (ats_int_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_bool_type, tmp264) ; // ATSlocal_void (tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; // ATSlocal_void (tmp268) ; // ATSlocal_void (tmp269) ; ATSlocal (ats_lint_type, tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; ATSlocal (ats_int_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_bool_type, tmp276) ; // ATSlocal_void (tmp277) ; ATSlocal (ats_lint_type, tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_bool_type, tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; // ATSlocal_void (tmp288) ; // ATSlocal_void (tmp289) ; ATSlocal (ats_lint_type, tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; ATSlocal (ats_int_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_bool_type, tmp296) ; // ATSlocal_void (tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_lint_type, tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; __ats_lab_posmark_process_htm_52: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp243 = atspre_eq_int_int (tmp242, 0) ; if (tmp243) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp244 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp245 = atspre_eq_int_int (tmp244, 0) ; if (tmp245) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)arg2)->tag != 3) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp247 = atspre_eq_int_int (tmp246, 0) ; if (tmp247) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp249 = atspre_eq_int_int (tmp248, 0) ; if (tmp249) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)arg2)->tag != 5) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp250 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp251 = atspre_eq_int_int (tmp250, 0) ; if (tmp251) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg2)->tag != 6) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp253 = atspre_eq_int_int (tmp252, 0) ; if (tmp253) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg2)->tag != 7) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp254 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp255 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp256 = atspre_eq_int_int (tmp254, 0) ; if (tmp256) { /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp261 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)arg2)->tag != 8) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp263 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp264 = atspre_eq_int_int (tmp262, 0) ; if (tmp264) { /* tmp265 = */ atspre_fprint_string (arg0, ATSstrcst("
")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp273 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)arg2)->tag != 9) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp274 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp276 = atspre_eq_int_int (tmp274, 0) ; if (tmp276) { /* tmp277 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp281 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)arg2)->tag != 10) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp282 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp283 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp284 = atspre_eq_int_int (tmp282, 0) ; if (tmp284) { /* tmp285 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp293 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (((ats_sum_ptr_type)arg2)->tag != 11) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: tmp294 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp295 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp296 = atspre_eq_int_int (tmp294, 0) ; if (tmp296) { /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } else { /* tmp305 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; } /* end of [if] */ break ; } while (0) ; return /* (tmp229) */ ; } /* end of [posmark_process_htm_52] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 22482(line=732, offs=4) -- 22769(line=739, offs=4) */ ATSstaticdec() ats_void_type fputchr_htm_55 (ats_char_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp306) ; __ats_lab_fputchr_htm_55: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg0 != '<') { goto __ats_lab_41_0 ; } __ats_lab_40_1: /* tmp306 = */ atspre_fprint_string (arg1, ATSstrcst("<")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (arg0 != '>') { goto __ats_lab_42_0 ; } __ats_lab_41_1: /* tmp306 = */ atspre_fprint_string (arg1, ATSstrcst(">")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg0 != '&') { goto __ats_lab_43_0 ; } __ats_lab_42_1: /* tmp306 = */ atspre_fprint_string (arg1, ATSstrcst("&")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: /* tmp306 = */ atslib_fputc_exn (arg0, arg1) ; break ; } while (0) ; return /* (tmp306) */ ; } /* end of [fputchr_htm_55] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 22985(line=749, offs=3) -- 23770(line=772, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; ATSlocal (ats_bool_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; // ATSlocal_void (tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; // ATSlocal_void (tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm: tmp308 = atslib_fopen_exn (arg1, "r") ; tmp309 = ats_selsin_mac(tmp308, atslab_1) ; tmp311 = atspre_stropt_is_some (arg2) ; if (tmp311) { tmp312 = atslib_fopen_exn (ats_castfn_mac(ats_ptr_type, arg2), "w") ; tmp313 = ats_selsin_mac(tmp312, atslab_1) ; /* tmp314 = */ posmark_file_file_46 (arg0, &posmark_process_htm_52, &fputchr_htm_55, tmp309, tmp313) ; /* tmp310 = */ atslib_fclose_exn (tmp313) ; } else { tmp315 = atspre_stdout_get () ; tmp316 = ats_selsin_mac(tmp315, atslab_1) ; /* tmp317 = */ posmark_file_file_46 (arg0, &posmark_process_htm_52, &fputchr_htm_55, tmp309, tmp316) ; /* tmp310 = */ atspre_stdout_view_set () ; } /* end of [if] */ /* tmp307 = */ atslib_fclose_exn (tmp309) ; return /* (tmp307) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 23888(line=782, offs=4) -- 24105(line=790, offs=4) */ ATSstaticdec() ats_char_type char_of_xdigit_57 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp318) ; ATSlocal (ats_int_type, tmp319) ; ATSlocal (ats_bool_type, tmp320) ; ATSlocal (ats_int_type, tmp321) ; ATSlocal (ats_int_type, tmp322) ; ATSlocal (ats_int_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; __ats_lab_char_of_xdigit_57: tmp320 = atspre_gte_int_int (arg0, 10) ; if (tmp320) { tmp321 = atspre_int_of_char ('a') ; tmp323 = atspre_int_of_char ('a') ; tmp322 = atspre_add_int_int (tmp323, arg0) ; tmp319 = atspre_sub_int_int (tmp322, 10) ; } else { tmp324 = atspre_int_of_char ('0') ; tmp319 = atspre_add_int_int (tmp324, arg0) ; } /* end of [if] */ tmp318 = atspre_char_of_int (tmp319) ; return (tmp318) ; } /* end of [char_of_xdigit_57] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 24210(line=794, offs=7) -- 24893(line=813, offs=8) */ ATSstaticdec() ats_ptr_type loop_59 (ats_ptr_type arg0, ats_size_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_bool_type, tmp327) ; ATSlocal (ats_char_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_bool_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_int_type, tmp333) ; ATSlocal (ats_int_type, tmp334) ; ATSlocal (ats_char_type, tmp335) ; ATSlocal (ats_char_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_size_type, tmp338) ; __ats_lab_loop_59: tmp327 = atspre_string_isnot_atend (arg0, arg1) ; if (tmp327) { tmp328 = atspre_string_get_char_at (arg0, arg1) ; do { /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp330 = atspre_char_isalnum (tmp328) ; if (!tmp330) { goto __ats_lab_45_1 ; } tmp329 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_0, tmp328) ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_1, arg2) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp331 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp331, atslab_0, '_') ; ats_selptrset_mac(anairiats_sum_5, tmp331, atslab_1, arg2) ; tmp332 = atspre_int_of_char (tmp328) ; tmp333 = atspre_div_int_int (tmp332, 16) ; tmp334 = atspre_mod_int_int (tmp332, 16) ; tmp335 = char_of_xdigit_57 (tmp333) ; tmp336 = char_of_xdigit_57 (tmp334) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp337, atslab_0, tmp335) ; ats_selptrset_mac(anairiats_sum_5, tmp337, atslab_1, tmp331) ; tmp329 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_0, tmp336) ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_1, tmp337) ; break ; } while (0) ; tmp338 = atspre_add_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp338 ; arg2 = tmp329 ; goto __ats_lab_loop_59 ; // tail call } else { tmp326 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string (arg2, ATSstrcst(".html")) ; } /* end of [if] */ return (tmp326) ; } /* end of [loop_59] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 24138(line=792, offs=5) -- 25220(line=821, offs=4) */ ATSstaticdec() ats_ptr_type posmark_xref_testnot_58 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_bool_type, tmp343) ; __ats_lab_posmark_xref_testnot_58: tmp340 = (ats_sum_ptr_type)0 ; tmp339 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string (tmp340, ats_castfn_mac(ats_ptr_type, arg0)) ; tmp341 = loop_59 (ats_castfn_mac(ats_ptr_type, arg1), 0, tmp339) ; tmp342 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev (tmp341) ; tmp343 = atspre_test_file_exists (tmp342) ; if (tmp343) { tmp325 = atspre_stropt_none ; } else { tmp325 = ats_castfn_mac(ats_ptr_type, tmp342) ; } /* end of [if] */ return (tmp325) ; } /* end of [posmark_xref_testnot_58] */ /* // /home/hwxi/research/Anairiats/src/ats_posmark.dats: 25385(line=827, offs=35) -- 25572(line=833, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_bool_type, tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if: tmp345 = ats_posmark_xref_flag_get () ; tmp346 = atspre_stropt_is_some (tmp345) ; if (tmp346) { tmp344 = posmark_xref_testnot_58 (ats_castfn_mac(ats_ptr_type, tmp345), arg0) ; } else { tmp344 = atspre_stropt_none ; } /* end of [if] */ return (tmp344) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMcomment_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMextern_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMkeyword_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMneuexp_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstaexp_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMprfexp_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstdec_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMstacstuse_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstdec_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstimp_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__PMdyncstuse_11.tag = 11 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp26, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp32, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp34, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp26 = ref_make_elt_01952_ats_int_type (0) ; statmp32 = (ats_sum_ptr_type)0 ; statmp29 = ref_make_elt_01952_ats_ptr_type (statmp32) ; statmp34 = (ats_sum_ptr_type)0 ; statmp33 = ref_make_elt_01952_ats_ptr_type (statmp34) ; /* statmp347 = */ ats_posmark_initialize () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_ptr_type posmark_htmlfilename_make (ats_ptr_type basename) { int n ; char c, *s ; n = strlen((char *)basename) ; s = (char*)ATS_MALLOC (n+6) ; s[n+5] = '\000' ; s[n+4] = 'l'; s[n+3] = 'm' ; s[n+2] = 't' ; s[n+1] = 'h' ; s[n] = '.' ; --n ; while (n >= 0) { c = ((char *)basename)[n] ; if (c == '.') { s[n] = '_' ; --n ; break ; } s[n] = c ; --n ; } while (n >= 0) { s[n] = ((char *)basename)[n] ; --n ; } return s ; } /* posmark_htmlfilename_make */ /* ****** ****** */ static char* the_ats_posmark_xref_flag = 0 ; ats_ptr_type ats_posmark_xref_flag_get () { return the_ats_posmark_xref_flag ; } ats_void_type ats_posmark_xref_flag_set (ats_ptr_type flag) { the_ats_posmark_xref_flag = flag ; return ; } // end of [ats_posmark_xref_flag_set] ats_void_type ats_posmark_initialize () { ATS_GC_MARKROOT (&the_ats_posmark_xref_flag, sizeof(ats_ptr_type)) ; return ; } // end of [ats_posmark_initialize] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_posmark_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_filename_sats.c0000664000175000017500000000221412223166160021715 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_filename_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_lexer_sats.c0000664000175000017500000000176412223166160021265 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_lexer_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_constraint_print_dats.c0000664000175000017500000007302312223166160023524 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_4 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEintinf_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEineg_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEiadd_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEisub_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEimul_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEpdiff_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEvar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbadd_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbmul_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbneg_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEiexp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEvar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEpadd_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 1783(line=53, offs=15) -- 2470(line=76, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp2 = */ atspre_fprint_string (arg0, ATSstrcst("S3AEcst(")) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp1) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("S3AEexp(")) ; /* tmp6 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp4) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst("S3AEvar(")) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp7) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp11 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst("S3AEpadd(")) ; /* tmp13 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (arg0, tmp10) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp11) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("S3AEnull()")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 2521(line=78, offs=24) -- 2561(line=78, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3aexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3aexp: tmp17 = atspre_stdout_get () ; tmp18 = ats_selsin_mac(tmp17, atslab_1) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (tmp18, arg0) ; /* tmp16 = */ atspre_stdout_view_set () ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3aexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 2585(line=79, offs=24) -- 2625(line=79, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3aexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3aexp: tmp21 = atspre_stderr_get () ; tmp22 = ats_selsin_mac(tmp21, atslab_1) ; /* tmp23 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (tmp22, arg0) ; /* tmp20 = */ atspre_stderr_view_set () ; return /* (tmp20) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3aexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 2672(line=84, offs=15) -- 3881(line=125, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; ATSlocal (ats_bool_type, tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; // ATSlocal_void (tmp38) ; // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; ATSlocal (ats_int_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; // ATSlocal_void (tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp25 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp26 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEcst(")) ; /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp25) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp29 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEexp(")) ; /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp28) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp32 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEvar(")) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp31) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEbool(")) ; /* tmp36 = */ atspre_fprint_bool (arg0, tmp34) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp38 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEbneg(")) ; /* tmp39 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (arg0, tmp37) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp41 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEbadd(")) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (arg0, tmp40) ; /* tmp44 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (arg0, tmp41) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEbmul(")) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (arg0, tmp46) ; /* tmp50 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (arg0, tmp47) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (((ats_sum_ptr_type)arg1)->tag != 7) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp53 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp54 = */ atspre_fprint_string (arg0, ATSstrcst("S3BEiexp(")) ; /* tmp55 = */ atspre_fprint_string (arg0, ATSstrcst("knd=")) ; /* tmp56 = */ atspre_fprint_int (arg0, tmp52) ; /* tmp57 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp53) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp24) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 3932(line=127, offs=24) -- 3972(line=127, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; // ATSlocal_void (tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexp: tmp60 = atspre_stdout_get () ; tmp61 = ats_selsin_mac(tmp60, atslab_1) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (tmp61, arg0) ; /* tmp59 = */ atspre_stdout_view_set () ; return /* (tmp59) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 3996(line=128, offs=24) -- 4036(line=128, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; // ATSlocal_void (tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexp: tmp64 = atspre_stderr_get () ; tmp65 = ats_selsin_mac(tmp64, atslab_1) ; /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp (tmp65, arg0) ; /* tmp63 = */ atspre_stderr_view_set () ; return /* (tmp63) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 4086(line=133, offs=18) -- 4155(line=134, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst: /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexp) ; return /* (tmp67) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 4212(line=137, offs=27) -- 4257(line=137, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; // ATSlocal_void (tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexplst: tmp69 = atspre_stdout_get () ; tmp70 = ats_selsin_mac(tmp69, atslab_1) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst (tmp70, arg0) ; /* tmp68 = */ atspre_stdout_view_set () ; return /* (tmp68) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3bexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 4284(line=138, offs=27) -- 4329(line=138, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexplst: tmp73 = atspre_stderr_get () ; tmp74 = ats_selsin_mac(tmp73, atslab_1) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3bexplst (tmp74, arg0) ; /* tmp72 = */ atspre_stderr_view_set () ; return /* (tmp72) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 4376(line=143, offs=15) -- 5941(line=195, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; ATSlocal (ats_int_type, tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; // ATSlocal_void (tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp78 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEcst(")) ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp77) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp81 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEexp(")) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp80) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEvar(")) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp83) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; /* tmp87 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEint(")) ; /* tmp88 = */ atspre_fprint_int (arg0, tmp86) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp90 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEintinf(")) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp89) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp93 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEineg(")) ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp92) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp96 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp97 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEiadd(")) ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp95) ; /* tmp99 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp96) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp103 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEisub(")) ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp101) ; /* tmp105 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp102) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp109 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEimul(")) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp107) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (arg0, tmp108) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (((ats_sum_ptr_type)arg1)->tag != 9) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp115 = */ atspre_fprint_string (arg0, ATSstrcst("S3IEpdiff(")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (arg0, tmp113) ; /* tmp117 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3aexp (arg0, tmp114) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp76) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 5992(line=197, offs=24) -- 6032(line=197, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3iexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3iexp: tmp120 = atspre_stdout_get () ; tmp121 = ats_selsin_mac(tmp120, atslab_1) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (tmp121, arg0) ; /* tmp119 = */ atspre_stdout_view_set () ; return /* (tmp119) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__print_s3iexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint_print.dats: 6056(line=198, offs=24) -- 6096(line=198, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; // ATSlocal_void (tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp: tmp124 = atspre_stderr_get () ; tmp125 = ats_selsin_mac(tmp124, atslab_1) ; /* tmp126 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__fprint_s3iexp (tmp125, arg0) ; /* tmp123 = */ atspre_stderr_view_set () ; return /* (tmp123) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_constraint_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hiexp_print_dats.c0000664000175000017500000025706112223166160022463 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_11 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_hilab_loc ; ats_ptr_type atslab_hilab_node ; } anairiats_rec_18 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITs2var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrectemp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrecsin_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysumtemp_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrinit_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrpsz_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_ptr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcaseof_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcastfn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEdynload_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEextval_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloatsp_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfreeat_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEif_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEintsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_delay_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_ldelay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElet_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloop_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloopexn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_ptr_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_var_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEraise_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErefarg_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsif_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsizeof_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtrywith_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhipatlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhiexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_23 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 1947(line=62, offs=14) -- 3492(line=113, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_int_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; // ATSlocal_void (tmp38) ; ATSlocal (ats_bool_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_hityp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp1)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("HITextype(")) ; /* tmp5 = */ atspre_fprint_string (arg0, tmp2) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst (arg0, tmp3) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp1)->tag != 2) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; tmp9 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_1) ; tmp10 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_2) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst("HITfun(")) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp8) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp14 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst (arg0, tmp9) ; /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp10) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp1)->tag != 3) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_1) ; /* tmp19 = */ atspre_fprint_string (arg0, ATSstrcst("HITrefarg(")) ; /* tmp20 = */ atspre_fprint_int (arg0, tmp17) ; /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp18) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp1)->tag != 8) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_0) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst("HITtyrecsin(")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp23) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp1)->tag != 7) { goto __ats_lab_5_0 ; } __ats_lab_4_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("HITtyrectemp(...)")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp1)->tag != 10) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp28 = */ atspre_fprint_string (arg0, ATSstrcst("HITsumtemp(")) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp26) ; /* tmp30 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst (arg0, tmp27) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp1)->tag != 4) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_0) ; /* tmp33 = */ atspre_fprint_string (arg0, ATSstrcst("HITs2var(")) ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp32) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp35 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_hityp_name) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_5, tmp35, atslab_0) ; tmp37 = ats_caselptrlab_mac(anairiats_sum_5, tmp35, atslab_1) ; tmp39 = atspre_gt_int_int (tmp36, 0) ; if (tmp39) { /* tmp38 = */ atspre_fprint_string (arg0, ATSstrcst("*")) ; } else { /* empty */ } /* end of [if] */ /* tmp0 = */ atspre_fprint_string (arg0, tmp37) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3541(line=116, offs=13) -- 3578(line=116, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp: tmp41 = atspre_stdout_get () ; tmp42 = ats_selsin_mac(tmp41, atslab_1) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (tmp42, arg0) ; /* tmp40 = */ atspre_stdout_view_set () ; return /* (tmp40) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3601(line=118, offs=13) -- 3638(line=118, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp: tmp45 = atspre_stderr_get () ; tmp46 = ats_selsin_mac(tmp45, atslab_1) ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (tmp46, arg0) ; /* tmp44 = */ atspre_stderr_view_set () ; return /* (tmp44) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3687(line=123, offs=17) -- 3763(line=124, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst: /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp) ; return /* (tmp48) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3818(line=128, offs=16) -- 3860(line=128, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; // ATSlocal_void (tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityplst: tmp50 = atspre_stdout_get () ; tmp51 = ats_selsin_mac(tmp50, atslab_1) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst (tmp51, arg0) ; /* tmp49 = */ atspre_stdout_view_set () ; return /* (tmp49) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3886(line=130, offs=16) -- 3928(line=130, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityplst: tmp54 = atspre_stderr_get () ; tmp55 = ats_selsin_mac(tmp54, atslab_1) ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst (tmp55, arg0) ; /* tmp53 = */ atspre_stderr_view_set () ; return /* (tmp53) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 3980(line=135, offs=20) -- 4064(line=136, offs=67) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst: /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplst) ; return /* (tmp57) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 4141(line=142, offs=14) -- 6620(line=222, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; ATSlocal (ats_bool_type, tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_char_type, tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; ATSlocal (ats_int_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; // ATSlocal_void (tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat: tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp59)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_1, tmp59, atslab_0) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_1, tmp59, atslab_1) ; /* tmp62 = */ atspre_fprint_string (arg0, ATSstrcst("HIPann(")) ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (arg0, tmp60) ; /* tmp64 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp61) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp59)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst("HIPany()")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp59)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_0) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_1) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_2) ; /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst("HIPas(")) ; /* tmp70 = */ atspre_fprint_int (arg0, tmp66) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp72 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp67) ; /* tmp73 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp74 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (arg0, tmp68) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp59)->tag != 3) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_8, tmp59, atslab_0) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst("HIPbool(")) ; /* tmp77 = */ atspre_fprint_bool (arg0, tmp75) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp59)->tag != 4) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_9, tmp59, atslab_0) ; /* tmp79 = */ atspre_fprint_string (arg0, ATSstrcst("HIPchar(")) ; /* tmp80 = */ atspre_fprint_char (arg0, tmp78) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp59)->tag != 5) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_10, tmp59, atslab_0) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_10, tmp59, atslab_1) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_10, tmp59, atslab_2) ; tmp84 = ats_caselptrlab_mac(anairiats_sum_10, tmp59, atslab_3) ; /* tmp85 = */ atspre_fprint_string (arg0, ATSstrcst("HIPcon(")) ; /* tmp86 = */ atspre_fprint_int (arg0, tmp81) ; /* tmp87 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp82) ; /* tmp89 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (arg0, tmp83) ; /* tmp91 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp84) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp59)->tag != 6) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_3, tmp59, atslab_0) ; tmp94 = ats_caselptrlab_mac(anairiats_sum_3, tmp59, atslab_1) ; /* tmp95 = */ atspre_fprint_string (arg0, ATSstrcst("HIPcon_any(")) ; /* tmp96 = */ atspre_fprint_int (arg0, tmp93) ; /* tmp97 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp94) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp59)->tag != 7) { goto __ats_lab_16_0 ; } __ats_lab_15_1: /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst("HIPempty()")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp59)->tag != 8) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp99 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; /* tmp58 = */ atspre_fprintf_exn (arg0, ATSstrcst("HIPfloat(%s)"), tmp99) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp59)->tag != 9) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_1, tmp59, atslab_1) ; /* tmp101 = */ atspre_fprint_string (arg0, ATSstrcst("HIPint(")) ; /* tmp102 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp100) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp59)->tag != 10) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_1, tmp59, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_1, tmp59, atslab_1) ; /* tmp105 = */ atspre_fprint_string (arg0, ATSstrcst("HIPlst(")) ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp103) ; /* tmp107 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (arg0, tmp104) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp59)->tag != 11) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_1) ; tmp111 = ats_caselptrlab_mac(anairiats_sum_7, tmp59, atslab_2) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst("HIPrec(")) ; /* tmp113 = */ atspre_fprint_int (arg0, tmp109) ; /* tmp114 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhipatlst (arg0, tmp110) ; /* tmp116 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp117 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp111) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp59)->tag != 12) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; /* tmp119 = */ atspre_fprint_string (arg0, ATSstrcst("HIPstring(")) ; /* tmp120 = */ atspre_fprint_string (arg0, tmp118) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (((ats_sum_ptr_type)tmp59)->tag != 13) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_3, tmp59, atslab_1) ; /* tmp122 = */ atspre_fprint_string (arg0, ATSstrcst("HIPvar(")) ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp121) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp58) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 6669(line=225, offs=13) -- 6706(line=225, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipat (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipat: tmp125 = atspre_stdout_get () ; tmp126 = ats_selsin_mac(tmp125, atslab_1) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (tmp126, arg0) ; /* tmp124 = */ atspre_stdout_view_set () ; return /* (tmp124) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipat] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 6729(line=227, offs=13) -- 6766(line=227, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat: tmp129 = atspre_stderr_get () ; tmp130 = ats_selsin_mac(tmp129, atslab_1) ; /* tmp131 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (tmp130, arg0) ; /* tmp128 = */ atspre_stderr_view_set () ; return /* (tmp128) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipat] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 6815(line=232, offs=17) -- 6891(line=233, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst: /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat) ; return /* (tmp132) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 6946(line=237, offs=16) -- 6988(line=237, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipatlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; // ATSlocal_void (tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipatlst: tmp134 = atspre_stdout_get () ; tmp135 = ats_selsin_mac(tmp134, atslab_1) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (tmp135, arg0) ; /* tmp133 = */ atspre_stdout_view_set () ; return /* (tmp133) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hipatlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 7014(line=239, offs=16) -- 7056(line=239, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipatlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipatlst: tmp138 = atspre_stderr_get () ; tmp139 = ats_selsin_mac(tmp138, atslab_1) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (tmp139, arg0) ; /* tmp137 = */ atspre_stderr_view_set () ; return /* (tmp137) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hipatlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 7145(line=246, offs=7) -- 7703(line=260, offs=30) */ ATSstaticdec() ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_bool_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_int_type, tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_bool_type, tmp153) ; __ats_lab_aux_14: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_1) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_2) ; tmp147 = atspre_gt_int_int (arg1, 0) ; if (tmp147) { /* tmp146 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp143) ; /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipat (arg0, tmp144) ; tmp151 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp151 ; arg2 = tmp145 ; goto __ats_lab_aux_14 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp153 = atspre_gt_int_int (arg1, 0) ; if (tmp153) { /* tmp152 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp142 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: break ; } while (0) ; return /* (tmp142) */ ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 7114(line=245, offs=3) -- 7778(line=264, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhipatlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhipatlst: /* tmp141 = */ aux_14 (arg0, 0, arg1) ; return /* (tmp141) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhipatlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 7855(line=269, offs=14) -- 16955(line=555, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; // ATSlocal_void (tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; ATSlocal (ats_bool_type, tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; // ATSlocal_void (tmp209) ; ATSlocal (ats_char_type, tmp210) ; // ATSlocal_void (tmp211) ; // ATSlocal_void (tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; // ATSlocal_void (tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_int_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; // ATSlocal_void (tmp250) ; // ATSlocal_void (tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; // ATSlocal_void (tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; // ATSlocal_void (tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; // ATSlocal_void (tmp265) ; // ATSlocal_void (tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; // ATSlocal_void (tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; // ATSlocal_void (tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; // ATSlocal_void (tmp287) ; ATSlocal (ats_int_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; // ATSlocal_void (tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; // ATSlocal_void (tmp302) ; // ATSlocal_void (tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; // ATSlocal_void (tmp307) ; // ATSlocal_void (tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_int_type, tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; // ATSlocal_void (tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; // ATSlocal_void (tmp322) ; // ATSlocal_void (tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; // ATSlocal_void (tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; ATSlocal (ats_int_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; // ATSlocal_void (tmp347) ; ATSlocal (ats_int_type, tmp348) ; ATSlocal (ats_int_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; // ATSlocal_void (tmp371) ; // ATSlocal_void (tmp372) ; // ATSlocal_void (tmp373) ; // ATSlocal_void (tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; // ATSlocal_void (tmp385) ; // ATSlocal_void (tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp: tmp155 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_hiexp_node) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp155)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp157 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst("HIEapp(")) ; /* tmp160 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp156) ; /* tmp161 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp157) ; /* tmp163 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp164 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp158) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp155)->tag != 1) { goto __ats_lab_29_0 ; } __ats_lab_26_1: tmp165 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp166 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp167 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst("HIEarrinit(")) ; /* tmp169 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp165) ; /* tmp170 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp166 == (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_12, tmp166, atslab_0) ; /* tmp171 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp172) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp166 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: break ; } while (0) ; /* tmp173 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp174 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp167) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp155)->tag != 2) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp177 = */ atspre_fprint_string (arg0, ATSstrcst("HIEarrpsz(")) ; /* tmp178 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp175) ; /* tmp179 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp180 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp176) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp155)->tag != 3) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp184 = */ atspre_fprint_string (arg0, ATSstrcst("HIEassgn_ptr(")) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp181) ; /* tmp186 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp182) ; /* tmp188 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp183) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp155)->tag != 4) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp193 = */ atspre_fprint_string (arg0, ATSstrcst("HIEassgn_var(")) ; /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp190) ; /* tmp195 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp191) ; /* tmp197 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp198 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp192) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp155)->tag != 5) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_8, tmp155, atslab_0) ; /* tmp200 = */ atspre_fprint_string (arg0, ATSstrcst("HIEbool(")) ; /* tmp201 = */ atspre_fprint_bool (arg0, tmp199) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp155)->tag != 6) { goto __ats_lab_34_0 ; } __ats_lab_33_1: /* tmp202 = */ atspre_fprint_string (arg0, ATSstrcst("HIEcaseof(")) ; /* tmp203 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp155)->tag != 7) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp204 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp205 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("HIEcastfn(")) ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp204) ; /* tmp208 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp209 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp205) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp155)->tag != 8) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp210 = ats_caselptrlab_mac(anairiats_sum_9, tmp155, atslab_0) ; /* tmp211 = */ atspre_fprint_string (arg0, ATSstrcst("HIEchar(")) ; /* tmp212 = */ atspre_fprint_char (arg0, tmp210) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp155)->tag != 9) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp214 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp216 = */ atspre_fprint_string (arg0, ATSstrcst("HIEcon(")) ; /* tmp217 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp213) ; /* tmp218 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp219 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp214) ; /* tmp220 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp221 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp215) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp155)->tag != 10) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp223 = */ atspre_fprint_string (arg0, ATSstrcst("HIEcst(")) ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp222) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp155)->tag != 11) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp225 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp226 = */ atspre_fprint_string (arg0, ATSstrcst("HIEcstsp(")) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (arg0, tmp225) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp155)->tag != 12) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("HIEdynload(")) ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp228) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp155)->tag != 13) { goto __ats_lab_41_0 ; } __ats_lab_40_1: /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("HIEempty()")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp155)->tag != 14) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp231 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp232 = */ atspre_fprint_string (arg0, ATSstrcst("HIEextval(")) ; /* tmp233 = */ atspre_fprint_string (arg0, tmp231) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp155)->tag != 15) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp234 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_0) ; tmp235 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_1) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_2) ; /* tmp237 = */ atspre_fprint_string (arg0, ATSstrcst("HIEfix(")) ; /* tmp238 = */ atspre_fprint_int (arg0, tmp234) ; /* tmp239 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp240 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp235) ; /* tmp241 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp242 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp236) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp155)->tag != 16) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp243 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp244 = */ atspre_fprint_string (arg0, ATSstrcst("HIEfloat(")) ; /* tmp245 = */ atspre_fprint_string (arg0, tmp243) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp155)->tag != 17) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp247 = */ atspre_fprint_string (arg0, ATSstrcst("HIEfloatsp(")) ; /* tmp248 = */ atspre_fprint_string (arg0, tmp246) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp155)->tag != 18) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp250 = */ atspre_fprint_string (arg0, ATSstrcst("HIEfreeat(")) ; /* tmp251 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp249) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp155)->tag != 19) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp253 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_1) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_2) ; /* tmp255 = */ atspre_fprint_string (arg0, ATSstrcst("HIEif(")) ; /* tmp256 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp252) ; /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp258 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp253) ; /* tmp259 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp254) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp155)->tag != 20) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp261 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp262 = */ atspre_fprint_string (arg0, ATSstrcst("HIEint(")) ; /* tmp263 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp261) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp155)->tag != 21) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp264 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; /* tmp265 = */ atspre_fprint_string (arg0, ATSstrcst("HIEintsp(")) ; /* tmp266 = */ atspre_fprint_string (arg0, tmp264) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp155)->tag != 22) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp267 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp269 = */ atspre_fprint_string (arg0, ATSstrcst("HIElam(")) ; /* tmp270 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (arg0, tmp267) ; /* tmp271 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp272 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp268) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp155)->tag != 23) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp273 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp274 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp275 = */ atspre_fprint_string (arg0, ATSstrcst("HIElaminit(")) ; /* tmp276 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hipatlst (arg0, tmp273) ; /* tmp277 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp278 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp274) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp155)->tag != 24) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp279 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp280 = */ atspre_fprint_string (arg0, ATSstrcst("HIElazy_delay(")) ; /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp279) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp155)->tag != 25) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp282 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp283 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp284 = */ atspre_fprint_string (arg0, ATSstrcst("HIElazy_delay(")) ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp282) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp287 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp283) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp155)->tag != 26) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_3, tmp155, atslab_0) ; tmp289 = ats_caselptrlab_mac(anairiats_sum_3, tmp155, atslab_1) ; /* tmp290 = */ atspre_fprint_string (arg0, ATSstrcst("HIElazy_force(")) ; /* tmp291 = */ atspre_fprint_int (arg0, tmp288) ; /* tmp292 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp293 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp289) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp155)->tag != 27) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp294 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp295 = */ atspre_fprint_string (arg0, ATSstrcst("HIElet(")) ; /* tmp296 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp294) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp155)->tag != 28) { goto __ats_lab_60_0 ; } __ats_lab_55_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_13, tmp155, atslab_1) ; tmp300 = ats_caselptrlab_mac(anairiats_sum_13, tmp155, atslab_2) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_13, tmp155, atslab_3) ; /* tmp302 = */ atspre_fprint_string (arg0, ATSstrcst("HIEloop(")) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (tmp300 != (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (tmp300 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: tmp304 = ats_caselptrlab_mac(anairiats_sum_12, tmp300, atslab_0) ; /* tmp303 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp304) ; break ; } while (0) ; /* tmp305 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp306 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp299) ; /* tmp307 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp300 != (ats_sum_ptr_type)0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (tmp300 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: tmp309 = ats_caselptrlab_mac(anairiats_sum_12, tmp300, atslab_0) ; /* tmp308 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp309) ; break ; } while (0) ; /* tmp310 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp301) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp155)->tag != 29) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp312 = ats_caselptrlab_mac(anairiats_sum_14, tmp155, atslab_0) ; /* tmp313 = */ atspre_fprint_string (arg0, ATSstrcst("HIEloopexn(")) ; /* tmp314 = */ atspre_fprint_int (arg0, tmp312) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp155)->tag != 30) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_1) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_2) ; /* tmp318 = */ atspre_fprint_string (arg0, ATSstrcst("HIElst(")) ; /* tmp319 = */ atspre_fprint_int (arg0, tmp315) ; /* tmp320 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp321 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp316) ; /* tmp322 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp317) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp155)->tag != 31) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp325 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp326 = */ atspre_fprint_string (arg0, ATSstrcst("HIEptrof_ptr(")) ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp324) ; /* tmp328 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp325) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp155)->tag != 32) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp332 = */ atspre_fprint_string (arg0, ATSstrcst("HIEptrof_var(")) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp330) ; /* tmp334 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp335 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp331) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp155)->tag != 33) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp336 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp337 = */ atspre_fprint_string (arg0, ATSstrcst("HIEraise(")) ; /* tmp338 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp336) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp155)->tag != 34) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp339 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_0) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_1) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_7, tmp155, atslab_2) ; /* tmp342 = */ atspre_fprint_string (arg0, ATSstrcst("HIErec(")) ; /* tmp343 = */ atspre_fprint_int (arg0, tmp339) ; /* tmp344 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp340) ; /* tmp346 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp347 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhiexplst (arg0, tmp341) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp155)->tag != 35) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_15, tmp155, atslab_0) ; tmp349 = ats_caselptrlab_mac(anairiats_sum_15, tmp155, atslab_1) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_15, tmp155, atslab_2) ; /* tmp351 = */ atspre_fprint_string (arg0, ATSstrcst("HIErefarg(")) ; /* tmp352 = */ atspre_fprint_int (arg0, tmp348) ; /* tmp353 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp354 = */ atspre_fprint_int (arg0, tmp349) ; /* tmp355 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp350) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp155)->tag != 36) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp358 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp359 = */ atspre_fprint_string (arg0, ATSstrcst("HIEsel(")) ; /* tmp360 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp357) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp358) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp155)->tag != 37) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp363 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp364 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp365 = */ atspre_fprint_string (arg0, ATSstrcst("HIEsel_ptr(")) ; /* tmp366 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp363) ; /* tmp367 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp368 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp364) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp155)->tag != 38) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp369 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp370 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp371 = */ atspre_fprint_string (arg0, ATSstrcst("HIEsel_var(")) ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp369) ; /* tmp373 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp374 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (arg0, tmp370) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp155)->tag != 39) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp375 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp376 = */ atspre_fprint_string (arg0, ATSstrcst("HIEseq(")) ; /* tmp377 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (arg0, tmp375) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp155)->tag != 40) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp378 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp379 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp380 = */ atspre_fprint_string (arg0, ATSstrcst("HIEsif(")) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp378) ; /* tmp382 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp383 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp379) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp155)->tag != 41) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp384 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp385 = */ atspre_fprint_string (arg0, ATSstrcst("HIEsizeof(")) ; /* tmp386 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp384) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp155)->tag != 42) { goto __ats_lab_74_0 ; } __ats_lab_73_1: /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("HIEstring(...)")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp155)->tag != 43) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp389 = */ atspre_fprint_string (arg0, ATSstrcst("HIEtmpcst(")) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp387) ; /* tmp391 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst (arg0, tmp388) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp155)->tag != 44) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp393 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp394 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_1) ; /* tmp395 = */ atspre_fprint_string (arg0, ATSstrcst("HIEtmpvar(")) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp393) ; /* tmp397 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp398 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityplstlst (arg0, tmp394) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp155)->tag != 45) { goto __ats_lab_77_0 ; } __ats_lab_76_1: /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("HIEtop()")) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp155)->tag != 46) { goto __ats_lab_78_0 ; } __ats_lab_77_1: /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("HIEtrywith(...)")) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: // if (((ats_sum_ptr_type)tmp155)->tag != 47) { ats_deadcode_failure_handle () ; } __ats_lab_78_1: tmp399 = ats_caselptrlab_mac(anairiats_sum_4, tmp155, atslab_0) ; /* tmp400 = */ atspre_fprint_string (arg0, ATSstrcst("HIEvar(")) ; /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp399) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp154) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17004(line=557, offs=23) -- 17041(line=557, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; // ATSlocal_void (tmp405) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexp: tmp403 = atspre_stdout_get () ; tmp404 = ats_selsin_mac(tmp403, atslab_1) ; /* tmp405 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (tmp404, arg0) ; /* tmp402 = */ atspre_stdout_view_set () ; return /* (tmp402) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17064(line=558, offs=23) -- 17101(line=558, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; // ATSlocal_void (tmp409) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp: tmp407 = atspre_stderr_get () ; tmp408 = ats_selsin_mac(tmp407, atslab_1) ; /* tmp409 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (tmp408, arg0) ; /* tmp406 = */ atspre_stderr_view_set () ; return /* (tmp406) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17150(line=563, offs=17) -- 17226(line=564, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp410) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst: /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp) ; return /* (tmp410) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17281(line=568, offs=16) -- 17323(line=568, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; // ATSlocal_void (tmp414) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexplst: tmp412 = atspre_stdout_get () ; tmp413 = ats_selsin_mac(tmp412, atslab_1) ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (tmp413, arg0) ; /* tmp411 = */ atspre_stdout_view_set () ; return /* (tmp411) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hiexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17349(line=570, offs=16) -- 17391(line=570, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; // ATSlocal_void (tmp418) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexplst: tmp416 = atspre_stderr_get () ; tmp417 = ats_selsin_mac(tmp416, atslab_1) ; /* tmp418 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst (tmp417, arg0) ; /* tmp415 = */ atspre_stderr_view_set () ; return /* (tmp415) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hiexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17443(line=575, offs=20) -- 17527(line=576, offs=67) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp419) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplstlst: /* tmp419 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplst) ; return /* (tmp419) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17626(line=582, offs=7) -- 18023(line=593, offs=30) */ ATSstaticdec() ats_void_type aux_23 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; // ATSlocal_void (tmp425) ; ATSlocal (ats_bool_type, tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; ATSlocal (ats_int_type, tmp430) ; __ats_lab_aux_23: do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp422 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_0) ; tmp423 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_1) ; tmp424 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_2) ; tmp426 = atspre_gt_int_int (arg1, 0) ; if (tmp426) { /* tmp425 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp427 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp422) ; /* tmp428 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexp (arg0, tmp423) ; tmp430 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp430 ; arg2 = tmp424 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: break ; } while (0) ; return /* (tmp421) */ ; } /* end of [aux_23] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 17595(line=581, offs=3) -- 18098(line=597, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhiexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp420) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhiexplst: /* tmp420 = */ aux_23 (arg0, 0, arg1) ; return /* (tmp420) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_labhiexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 18175(line=602, offs=14) -- 18538(line=612, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; // ATSlocal_void (tmp434) ; // ATSlocal_void (tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilab: tmp432 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_hilab_node) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp432)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp433 = ats_caselptrlab_mac(anairiats_sum_1, tmp432, atslab_0) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst("HILlab(")) ; /* tmp435 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp433) ; /* tmp431 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (((ats_sum_ptr_type)tmp432)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: tmp436 = ats_caselptrlab_mac(anairiats_sum_1, tmp432, atslab_0) ; /* tmp437 = */ atspre_fprint_string (arg0, ATSstrcst("HILind(")) ; /* tmp438 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hiexplstlst (arg0, tmp436) ; /* tmp431 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp431) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilab] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 18591(line=615, offs=17) -- 18667(line=616, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp439) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst: /* tmp439 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilab) ; return /* (tmp439) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hilablst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 18742(line=622, offs=15) -- 18945(line=627, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp440) ; // ATSlocal_void (tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; // ATSlocal_void (tmp443) ; // ATSlocal_void (tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp: tmp442 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg1) ; /* tmp441 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp442) ; /* tmp443 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; tmp446 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (arg1) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp446) ; /* tmp444 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_hityp (arg0, tmp445) ; /* tmp440 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp440) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 18996(line=629, offs=24) -- 19034(line=629, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_vartyp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; // ATSlocal_void (tmp450) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_vartyp: tmp448 = atspre_stdout_get () ; tmp449 = ats_selsin_mac(tmp448, atslab_1) ; /* tmp450 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp (tmp449, arg0) ; /* tmp447 = */ atspre_stdout_view_set () ; return /* (tmp447) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_vartyp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_print.dats: 19058(line=630, offs=24) -- 19096(line=630, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_vartyp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; // ATSlocal_void (tmp454) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_vartyp: tmp452 = atspre_stderr_get () ; tmp453 = ats_selsin_mac(tmp452, atslab_1) ; /* tmp454 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__fprint_vartyp (tmp453, arg0) ; /* tmp451 = */ atspre_stderr_view_set () ; return /* (tmp451) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_vartyp] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hiexp_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libc_dats_unistd_dats.c0000664000175000017500000000717012223166160022567 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include #include ats_int_type atslib_fork_and_exec_and_wait (ats_clo_ptr_type f_child) { pid_t pid ; int status ; pid = fork () ; if (pid < 0) { ats_exit_errmsg (errno, "Exit: [fork] failed.\n") ; } if (pid > 0) { wait (&status) ; return status ; } /* this is the child */ ((ats_void_type (*)(ats_clo_ptr_type))f_child->closure_fun)(f_child) ; exit (0) ; } // end of [atslib_fork_and_exec_and_wait] #define __GETCWD_BUFSZ 64 ats_ptr_type atslib_getcwd0 () { char *buf, *res ; int sz = __GETCWD_BUFSZ ; // buf = (char*)ATS_MALLOC (__GETCWD_BUFSZ) ; while (1) { res = getcwd (buf, sz) ; if (!res) { ATS_FREE (buf) ; sz = sz + sz ; buf = (char*)ATS_MALLOC (sz) ; continue ; } break ; } // end of [while] // return buf ; } // end of [atslib_getcwd0] /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libc_dats_unistd_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libc_dats_unistd_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_dats.c0000664000175000017500000061151512223166160021521 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_d2sym_loc ; ats_ptr_type atslab_d2sym_qua ; ats_ptr_type atslab_d2sym_sym ; ats_ptr_type atslab_d2sym_itm ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_8 ; typedef struct { anairiats_rec_8 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_21 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_23 ; typedef struct { ats_ptr_type atslab_d2lab_loc ; ats_ptr_type atslab_d2lab_node ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_i2nvarg_var ; ats_ptr_type atslab_i2nvarg_typ ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_loopi2nv_loc ; ats_ptr_type atslab_loopi2nv_svs ; ats_ptr_type atslab_loopi2nv_gua ; ats_ptr_type atslab_loopi2nv_met ; ats_ptr_type atslab_loopi2nv_arg ; ats_ptr_type atslab_loopi2nv_res ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_28 ; typedef struct { ats_ptr_type atslab_m2atch_loc ; ats_ptr_type atslab_m2atch_exp ; ats_ptr_type atslab_m2atch_pat ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_c2lau_loc ; ats_ptr_type atslab_c2lau_pat ; ats_ptr_type atslab_c2lau_gua ; ats_int_type atslab_c2lau_seq ; ats_int_type atslab_c2lau_neg ; ats_ptr_type atslab_c2lau_exp ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_sc2lau_loc ; ats_ptr_type atslab_sc2lau_pat ; ats_ptr_type atslab_sc2lau_exp ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_s2tavar_loc ; ats_ptr_type atslab_s2tavar_var ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_s2aspdec_fil ; ats_ptr_type atslab_s2aspdec_loc ; ats_ptr_type atslab_s2aspdec_cst ; ats_ptr_type atslab_s2aspdec_def ; } anairiats_rec_33 ; typedef struct { ats_ptr_type atslab_v2aldec_loc ; ats_ptr_type atslab_v2aldec_pat ; ats_ptr_type atslab_v2aldec_def ; ats_ptr_type atslab_v2aldec_ann ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_f2undec_loc ; ats_ptr_type atslab_f2undec_var ; ats_ptr_type atslab_f2undec_def ; ats_ptr_type atslab_f2undec_ann ; } anairiats_rec_35 ; typedef struct { ats_ptr_type atslab_v2ardec_loc ; ats_int_type atslab_v2ardec_knd ; ats_ptr_type atslab_v2ardec_dvar ; ats_ptr_type atslab_v2ardec_svar ; ats_ptr_type atslab_v2ardec_typ ; ats_ptr_type atslab_v2ardec_wth ; ats_ptr_type atslab_v2ardec_ini ; } anairiats_rec_36 ; typedef struct { ats_ptr_type atslab_i2mpdec_loc ; ats_ptr_type atslab_i2mpdec_loc_id ; ats_ptr_type atslab_i2mpdec_cst ; ats_ptr_type atslab_i2mpdec_decarg ; ats_ptr_type atslab_i2mpdec_tmparg ; ats_ptr_type atslab_i2mpdec_tmpgua ; ats_ptr_type atslab_i2mpdec_def ; } anairiats_rec_37 ; typedef struct { ats_ptr_type atslab_d2ec_loc ; ats_ptr_type atslab_d2ec_node ; } anairiats_rec_38 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_39 ; /* external typedefs */ typedef anairiats_rec_14 *d2exp_t ; typedef anairiats_rec_2 *p2at_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Edynload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloatsp_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eintsp_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymelim_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstavars_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csaspdec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdcstdec_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdatdec_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cexndec_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Coverload_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextype_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextval_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextcode_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_par_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_rec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cfundecs_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvardecs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cimpdec_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clocal_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdynload_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstaload_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALarrsub_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_lin_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_mut_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALnone_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_svs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_dvs_union) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_sing) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__d2varlstord_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__s2varlstord_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_nil) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_bool_type s2var_sym_lt_2 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2var_sym_lte_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type d2var_sym_lt_4 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type d2var_sym_lte_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type s2var_errmsg_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type d2var_errmsg_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_int_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_ptr_type loop_22 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_24 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_45 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type ref_make_elt_03581_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type aux_115 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type i2nvarg_update_122 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp26) ; ATSstatic (ats_ptr_type, statmp27) ; ATSstatic (ats_ptr_type, statmp426) ; ATSstatic (ats_ptr_type, statmp427) ; ATSstatic (ats_ptr_type, statmp428) ; ATSstatic (ats_ptr_type, statmp429) ; ATSstatic (ats_ptr_type, statmp430) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 2155(line=68, offs=4) -- 2211(line=68, offs=60) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_dynexp2)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 2255(line=73, offs=12) -- 2343(line=75, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make: tmp1 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_d2sym_loc, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_d2sym_qua, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_d2sym_sym, arg2) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_d2sym_itm, arg3) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2sym_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3143(line=109, offs=4) -- 3238(line=111, offs=42) */ ATSstaticdec() ats_bool_type s2var_sym_lt_2 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_s2var_sym_lt_2: tmp3 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg0) ; tmp4 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg1) ; tmp2 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol (tmp3, tmp4) ; return (tmp2) ; } /* end of [s2var_sym_lt_2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3243(line=113, offs=4) -- 3340(line=115, offs=43) */ ATSstaticdec() ats_bool_type s2var_sym_lte_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_s2var_sym_lte_3: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg0) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg1) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol (tmp6, tmp7) ; return (tmp5) ; } /* end of [s2var_sym_lte_3] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3345(line=117, offs=4) -- 3440(line=119, offs=42) */ ATSstaticdec() ats_bool_type d2var_sym_lt_4 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_d2var_sym_lt_4: tmp9 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg1) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol (tmp9, tmp10) ; return (tmp8) ; } /* end of [d2var_sym_lt_4] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3445(line=121, offs=4) -- 3542(line=123, offs=43) */ ATSstaticdec() ats_bool_type d2var_sym_lte_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_d2var_sym_lte_5: tmp12 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg1) ; tmp11 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol (tmp12, tmp13) ; return (tmp11) ; } /* end of [d2var_sym_lte_5] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3568(line=127, offs=4) -- 3799(line=133, offs=4) */ ATSstaticdec() ats_void_type s2var_errmsg_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_s2var_errmsg_6: /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp16 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; /* tmp17 = */ atspre_prerr_string (ATSstrcst(": the pattern contains repeated occurrences of the static variable [")) ; /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg1) ; /* tmp19 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp14 = */ atspre_prerr_newline () ; return /* (tmp14) */ ; } /* end of [s2var_errmsg_6] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 3829(line=135, offs=4) -- 4061(line=141, offs=4) */ ATSstaticdec() ats_void_type d2var_errmsg_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; __ats_lab_d2var_errmsg_7: /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp22 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(": the pattern contains repeated occurrences of the dynamic variable [")) ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp25 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp20 = */ atspre_prerr_newline () ; return /* (tmp20) */ ; } /* end of [d2var_errmsg_7] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4207(line=148, offs=28) -- 4233(line=148, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_sing (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_sing: tmp29 = (ats_sum_ptr_type)0 ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_1, tmp29) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4261(line=149, offs=28) -- 4287(line=149, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing: tmp31 = (ats_sum_ptr_type)0 ; tmp30 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp30, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp30, atslab_1, tmp31) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4323(line=151, offs=35) -- 4336(line=151, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord: tmp32 = arg0 ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4371(line=152, offs=35) -- 4384(line=152, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord: tmp33 = arg0 ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4412(line=155, offs=17) -- 4715(line=165, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_bool_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp37 = s2var_sym_lte_3 (arg1, tmp35) ; if (tmp37) { tmp34 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_1, arg0) ; } else { tmp38 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add (tmp36, arg1) ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_0, tmp35) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_1, tmp38) ; } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp39 = (ats_sum_ptr_type)0 ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp34, atslab_1, tmp39) ; break ; } while (0) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 4777(line=168, offs=20) -- 4955(line=174, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp42 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp43 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_add (arg0, tmp41) ; arg0 = tmp43 ; arg1 = tmp42 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp40 = arg0 ; break ; } while (0) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 5017(line=177, offs=17) -- 5319(line=187, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_bool_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp46 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp47 = d2var_sym_lte_5 (arg1, tmp45) ; if (tmp47) { tmp44 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_1, arg0) ; } else { tmp48 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add (tmp46, arg1) ; tmp44 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_0, tmp45) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_1, tmp48) ; } /* end of [if] */ break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp49 = (ats_sum_ptr_type)0 ; tmp44 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp44, atslab_1, tmp49) ; break ; } while (0) ; return (tmp44) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 5380(line=190, offs=19) -- 5825(line=203, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_6_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp54 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp55 = s2var_sym_lte_3 (tmp51, tmp53) ; if (tmp55) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union (tmp52, arg1) ; tmp50 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_0, tmp51) ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_1, tmp56) ; } else { tmp57 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union (arg0, tmp54) ; tmp50 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_0, tmp53) ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_1, tmp57) ; } /* end of [if] */ break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp50 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp50 = arg1 ; break ; } while (0) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 5885(line=206, offs=19) -- 6330(line=219, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_bool_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_10_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp60 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp61 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp63 = d2var_sym_lte_5 (tmp59, tmp61) ; if (tmp63) { tmp64 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union (tmp60, arg1) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_0, tmp59) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_1, tmp64) ; } else { tmp65 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union (arg0, tmp62) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_0, tmp61) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_1, tmp65) ; } /* end of [if] */ break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp58 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp58 = arg1 ; break ; } while (0) ; return (tmp58) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 6444(line=225, offs=7) -- 6818(line=236, offs=20) */ ATSstaticdec() ats_int_type aux_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; // ATSlocal_void (tmp71) ; ATSlocal (ats_int_type, tmp72) ; __ats_lab_aux_18: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp69 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp70 = s2var_sym_lt_2 (arg1, tmp68) ; if (tmp70) { arg0 = arg0 ; arg1 = tmp68 ; arg2 = tmp69 ; arg3 = arg3 ; goto __ats_lab_aux_18 ; // tail call } else { /* tmp71 = */ s2var_errmsg_6 (arg0, arg1) ; tmp72 = atspre_add_int_int (arg3, 1) ; arg0 = arg0 ; arg1 = tmp68 ; arg2 = tmp69 ; arg3 = tmp72 ; goto __ats_lab_aux_18 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp67 = arg3 ; break ; } while (0) ; return (tmp67) ; } /* end of [aux_18] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 6420(line=224, offs=28) -- 7026(line=244, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlstord_linearity_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_bool_type, tmp75) ; ATSlocal (ats_int_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlstord_linearity_test: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp74 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp76 = aux_18 (arg0, tmp73, tmp74, 0) ; tmp75 = atspre_gt_int_int (tmp76, 0) ; if (tmp75) { /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: break ; } while (0) ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlstord_linearity_test] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 7131(line=248, offs=7) -- 7496(line=258, offs=20) */ ATSstaticdec() ats_int_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_bool_type, tmp81) ; // ATSlocal_void (tmp82) ; ATSlocal (ats_int_type, tmp83) ; __ats_lab_aux_20: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp81 = d2var_sym_lt_4 (arg1, tmp79) ; if (tmp81) { arg0 = arg0 ; arg1 = tmp79 ; arg2 = tmp80 ; arg3 = arg3 ; goto __ats_lab_aux_20 ; // tail call } else { /* tmp82 = */ d2var_errmsg_7 (arg0, arg1) ; tmp83 = atspre_add_int_int (arg3, 1) ; arg0 = arg0 ; arg1 = tmp79 ; arg2 = tmp80 ; arg3 = tmp83 ; goto __ats_lab_aux_20 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp78 = arg3 ; break ; } while (0) ; return (tmp78) ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 7107(line=247, offs=28) -- 7704(line=266, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlstord_linearity_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_bool_type, tmp86) ; ATSlocal (ats_int_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlstord_linearity_test: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp85 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp87 = aux_20 (arg0, tmp84, tmp85, 0) ; tmp86 = atspre_gt_int_int (tmp87, 0) ; if (tmp86) { /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: break ; } while (0) ; return /* (tmp77) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlstord_linearity_test] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 7839(line=274, offs=7) -- 8052(line=279, offs=20) */ ATSstaticdec() ats_ptr_type loop_22 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_loop_22: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp91 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp90), atslab_p2at_svs) ; tmp92 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union (arg1, tmp93) ; arg0 = tmp91 ; arg1 = tmp92 ; goto __ats_lab_loop_22 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp89 = arg1 ; break ; } while (0) ; return (tmp89) ; } /* end of [loop_22] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 7820(line=273, offs=19) -- 8109(line=283, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union: tmp88 = loop_22 (arg0, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; return (tmp88) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8188(line=287, offs=7) -- 8401(line=292, offs=20) */ ATSstaticdec() ats_ptr_type loop_24 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_loop_24: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp97 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp99 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp96), atslab_p2at_dvs) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union (arg1, tmp99) ; arg0 = tmp97 ; arg1 = tmp98 ; goto __ats_lab_loop_24 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp95 = arg1 ; break ; } while (0) ; return (tmp95) ; } /* end of [loop_24] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8169(line=286, offs=19) -- 8474(line=296, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union: tmp94 = loop_24 (arg0, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8578(line=302, offs=7) -- 8816(line=307, offs=15) */ ATSstaticdec() ats_ptr_type loop_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_loop_26: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp102), atslab_p2at_svs) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_union (arg1, tmp105) ; arg0 = tmp103 ; arg1 = tmp104 ; goto __ats_lab_loop_26 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp101 = arg1 ; break ; } while (0) ; return (tmp101) ; } /* end of [loop_26] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8558(line=301, offs=22) -- 8888(line=311, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_svs_union (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_svs_union: tmp100 = loop_26 (arg0, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; return (tmp100) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_svs_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8974(line=315, offs=7) -- 9212(line=320, offs=15) */ ATSstaticdec() ats_ptr_type loop_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_loop_28: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp111 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp108), atslab_p2at_dvs) ; tmp110 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_union (arg1, tmp111) ; arg0 = tmp109 ; arg1 = tmp110 ; goto __ats_lab_loop_28 ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp107 = arg1 ; break ; } while (0) ; return (tmp107) ; } /* end of [loop_28] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 8954(line=314, offs=22) -- 9284(line=324, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_dvs_union (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_dvs_union: tmp106 = loop_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; return (tmp106) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_dvs_union] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 9359(line=329, offs=10) -- 9496(line=333, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann: tmp113 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_p2at_svs) ; tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_p2at_dvs) ; tmp115 = (ats_sum_ptr_type)0 ; tmp116 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp116)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp116, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp116, atslab_1, arg2) ; tmp112 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp112, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp112, atslab_p2at_svs, tmp113) ; ats_selptrset_mac(anairiats_rec_2, tmp112, atslab_p2at_dvs, tmp114) ; ats_selptrset_mac(anairiats_rec_2, tmp112, atslab_p2at_typ, tmp115) ; ats_selptrset_mac(anairiats_rec_2, tmp112, atslab_p2at_node, tmp116) ; return (tmp112) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 9517(line=336, offs=10) -- 9644(line=342, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any: tmp118 = (ats_sum_ptr_type)0 ; tmp119 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; tmp117 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp117, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp117, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp117, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp117, atslab_p2at_typ, tmp118) ; ats_selptrset_mac(anairiats_rec_2, tmp117, atslab_p2at_node, tmp119) ; return (tmp117) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 9664(line=345, offs=9) -- 9868(line=353, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as: tmp122 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg3), atslab_p2at_dvs) ; tmp121 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_add (tmp122, arg2) ; tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg3), atslab_p2at_svs) ; tmp124 = (ats_sum_ptr_type)0 ; tmp125 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp125)->tag = 2 ; ats_selptrset_mac(anairiats_sum_5, tmp125, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp125, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp125, atslab_2, arg3) ; tmp120 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp120, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp120, atslab_p2at_svs, tmp123) ; ats_selptrset_mac(anairiats_rec_2, tmp120, atslab_p2at_dvs, tmp121) ; ats_selptrset_mac(anairiats_rec_2, tmp120, atslab_p2at_typ, tmp124) ; ats_selptrset_mac(anairiats_rec_2, tmp120, atslab_p2at_node, tmp125) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 9910(line=356, offs=11) -- 10042(line=362, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool: tmp127 = (ats_sum_ptr_type)0 ; tmp128 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp128)->tag = 3 ; ats_selptrset_mac(anairiats_sum_6, tmp128, atslab_0, arg1) ; tmp126 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp126, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp126, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp126, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp126, atslab_p2at_typ, tmp127) ; ats_selptrset_mac(anairiats_rec_2, tmp126, atslab_p2at_node, tmp128) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 10064(line=365, offs=11) -- 10200(line=371, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_char: tmp130 = (ats_sum_ptr_type)0 ; tmp131 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp131)->tag = 4 ; ats_selptrset_mac(anairiats_sum_7, tmp131, atslab_0, arg1) ; tmp129 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp129, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp129, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp129, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp129, atslab_p2at_typ, tmp130) ; ats_selptrset_mac(anairiats_rec_2, tmp129, atslab_p2at_node, tmp131) ; return (tmp129) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 10362(line=381, offs=9) -- 10598(line=387, offs=22) */ ATSstaticdec() ats_ptr_type loop_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (anairiats_rec_8, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_loop_35: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp135 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp138 = ats_select_mac(tmp135, atslab_0) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst (arg1, tmp138) ; arg0 = tmp136 ; arg1 = tmp137 ; goto __ats_lab_loop_35 ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp134 = arg1 ; break ; } while (0) ; return (tmp134) ; } /* end of [loop_35] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 10221(line=374, offs=10) -- 10816(line=396, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con: tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (arg6) ; tmp139 = loop_35 (arg3, tmp133) ; tmp140 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (arg6) ; tmp141 = (ats_sum_ptr_type)0 ; tmp142 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp142)->tag = 5 ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_4, arg5) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_5, arg6) ; tmp132 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp132, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp132, atslab_p2at_svs, tmp139) ; ats_selptrset_mac(anairiats_rec_2, tmp132, atslab_p2at_dvs, tmp140) ; ats_selptrset_mac(anairiats_rec_2, tmp132, atslab_p2at_typ, tmp141) ; ats_selptrset_mac(anairiats_rec_2, tmp132, atslab_p2at_node, tmp142) ; return (tmp132) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 10860(line=399, offs=12) -- 11030(line=405, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist: tmp145 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg2), atslab_p2at_svs) ; tmp144 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_addlst (tmp145, arg1) ; tmp146 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg2), atslab_p2at_dvs) ; tmp147 = (ats_sum_ptr_type)0 ; tmp148 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp148)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp148, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp148, atslab_1, arg2) ; tmp143 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp143, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp143, atslab_p2at_svs, tmp144) ; ats_selptrset_mac(anairiats_rec_2, tmp143, atslab_p2at_dvs, tmp146) ; ats_selptrset_mac(anairiats_rec_2, tmp143, atslab_p2at_typ, tmp147) ; ats_selptrset_mac(anairiats_rec_2, tmp143, atslab_p2at_node, tmp148) ; return (tmp143) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11053(line=408, offs=12) -- 11182(line=414, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty: tmp150 = (ats_sum_ptr_type)0 ; tmp151 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; tmp149 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp149, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp149, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp149, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp149, atslab_p2at_typ, tmp150) ; ats_selptrset_mac(anairiats_rec_2, tmp149, atslab_p2at_node, tmp151) ; return (tmp149) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11205(line=417, offs=12) -- 11342(line=423, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_float (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_float: tmp153 = (ats_sum_ptr_type)0 ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp154)->tag = 8 ; ats_selptrset_mac(anairiats_sum_11, tmp154, atslab_0, arg1) ; tmp152 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp152, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp152, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp152, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp152, atslab_p2at_typ, tmp153) ; ats_selptrset_mac(anairiats_rec_2, tmp152, atslab_p2at_node, tmp154) ; return (tmp152) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11363(line=426, offs=10) -- 11500(line=432, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_int: tmp156 = (ats_sum_ptr_type)0 ; tmp157 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp157)->tag = 9 ; ats_selptrset_mac(anairiats_sum_4, tmp157, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp157, atslab_1, arg2) ; tmp155 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp155, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp155, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp155, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp155, atslab_p2at_typ, tmp156) ; ats_selptrset_mac(anairiats_rec_2, tmp155, atslab_p2at_node, tmp157) ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11522(line=435, offs=11) -- 11731(line=444, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list: tmp159 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (arg2) ; tmp160 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (arg2) ; tmp161 = (ats_sum_ptr_type)0 ; tmp162 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp162)->tag = 10 ; ats_selptrset_mac(anairiats_sum_12, tmp162, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp162, atslab_1, arg2) ; tmp158 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp158, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp158, atslab_p2at_svs, tmp159) ; ats_selptrset_mac(anairiats_rec_2, tmp158, atslab_p2at_dvs, tmp160) ; ats_selptrset_mac(anairiats_rec_2, tmp158, atslab_p2at_typ, tmp161) ; ats_selptrset_mac(anairiats_rec_2, tmp158, atslab_p2at_node, tmp162) ; return (tmp158) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11774(line=447, offs=10) -- 11970(line=456, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst: tmp164 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (arg1) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (arg1) ; tmp166 = (ats_sum_ptr_type)0 ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp167)->tag = 11 ; ats_selptrset_mac(anairiats_sum_11, tmp167, atslab_0, arg1) ; tmp163 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp163, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp163, atslab_p2at_svs, tmp164) ; ats_selptrset_mac(anairiats_rec_2, tmp163, atslab_p2at_dvs, tmp165) ; ats_selptrset_mac(anairiats_rec_2, tmp163, atslab_p2at_typ, tmp166) ; ats_selptrset_mac(anairiats_rec_2, tmp163, atslab_p2at_node, tmp167) ; return (tmp163) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 11991(line=459, offs=10) -- 12225(line=468, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec: tmp169 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_svs_union (arg3) ; tmp170 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__labp2atlst_dvs_union (arg3) ; tmp171 = (ats_sum_ptr_type)0 ; tmp172 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp172)->tag = 12 ; ats_selptrset_mac(anairiats_sum_13, tmp172, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp172, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_13, tmp172, atslab_2, arg3) ; tmp168 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp168, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp168, atslab_p2at_svs, tmp169) ; ats_selptrset_mac(anairiats_rec_2, tmp168, atslab_p2at_dvs, tmp170) ; ats_selptrset_mac(anairiats_rec_2, tmp168, atslab_p2at_typ, tmp171) ; ats_selptrset_mac(anairiats_rec_2, tmp168, atslab_p2at_node, tmp172) ; return (tmp168) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 12270(line=471, offs=13) -- 12408(line=477, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_string (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_string: tmp174 = (ats_sum_ptr_type)0 ; tmp175 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp175)->tag = 13 ; ats_selptrset_mac(anairiats_sum_11, tmp175, atslab_0, arg1) ; tmp173 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp173, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp173, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp173, atslab_p2at_dvs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp173, atslab_p2at_typ, tmp174) ; ats_selptrset_mac(anairiats_rec_2, tmp173, atslab_p2at_node, tmp175) ; return (tmp173) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 12578(line=484, offs=9) -- 12830(line=491, offs=35) */ ATSstaticdec() ats_ptr_type aux_45 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; __ats_lab_aux_45: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp182 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (arg0) ; tmp184 = atspre_add_int_int (arg0, 1) ; tmp183 = aux_45 (tmp184, tmp181) ; tmp179 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp179)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp179, atslab_0, tmp182) ; ats_selptrset_mac(anairiats_sum_3, tmp179, atslab_1, tmp180) ; ats_selptrset_mac(anairiats_sum_3, tmp179, atslab_2, tmp183) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp179 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; break ; } while (0) ; return (tmp179) ; } /* end of [aux_45] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 12429(line=480, offs=10) -- 12977(line=499, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup: tmp177 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (arg3) ; tmp178 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (arg3) ; tmp185 = aux_45 (0, arg3) ; tmp186 = (ats_sum_ptr_type)0 ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp187)->tag = 12 ; ats_selptrset_mac(anairiats_sum_13, tmp187, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp187, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_13, tmp187, atslab_2, tmp185) ; tmp176 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp176, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp176, atslab_p2at_svs, tmp177) ; ats_selptrset_mac(anairiats_rec_2, tmp176, atslab_p2at_dvs, tmp178) ; ats_selptrset_mac(anairiats_rec_2, tmp176, atslab_p2at_typ, tmp186) ; ats_selptrset_mac(anairiats_rec_2, tmp176, atslab_p2at_node, tmp187) ; return (tmp176) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13019(line=502, offs=10) -- 13177(line=508, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var: tmp189 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing (arg2) ; tmp190 = (ats_sum_ptr_type)0 ; tmp191 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp191)->tag = 14 ; ats_selptrset_mac(anairiats_sum_12, tmp191, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp191, atslab_1, arg2) ; tmp188 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp188, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp188, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp188, atslab_p2at_dvs, tmp189) ; ats_selptrset_mac(anairiats_rec_2, tmp188, atslab_p2at_typ, tmp190) ; ats_selptrset_mac(anairiats_rec_2, tmp188, atslab_p2at_node, tmp191) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13199(line=511, offs=11) -- 13342(line=517, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_vbox (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_vbox: tmp193 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_sing (arg1) ; tmp194 = (ats_sum_ptr_type)0 ; tmp195 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp195)->tag = 15 ; ats_selptrset_mac(anairiats_sum_11, tmp195, atslab_0, arg1) ; tmp192 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp192, atslab_p2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp192, atslab_p2at_svs, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil) ; ats_selptrset_mac(anairiats_rec_2, tmp192, atslab_p2at_dvs, tmp193) ; ats_selptrset_mac(anairiats_rec_2, tmp192, atslab_p2at_typ, tmp194) ; ats_selptrset_mac(anairiats_rec_2, tmp192, atslab_p2at_node, tmp195) ; return (tmp192) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_vbox] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13392(line=523, offs=3) -- 13489(line=527, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type: tmp197 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp197)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp197, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp197, atslab_1, arg2) ; tmp198 = (ats_sum_ptr_type)0 ; tmp196 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp196, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp196, atslab_d2exp_node, tmp197) ; ats_selptrset_mac(anairiats_rec_14, tmp196, atslab_d2exp_typ, tmp198) ; return (tmp196) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13518(line=531, offs=3) -- 13617(line=535, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff: tmp200 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp200)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp200, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp200, atslab_1, arg2) ; tmp201 = (ats_sum_ptr_type)0 ; tmp199 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp199, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp199, atslab_d2exp_node, tmp200) ; ats_selptrset_mac(anairiats_rec_14, tmp199, atslab_d2exp_typ, tmp201) ; return (tmp199) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13648(line=539, offs=3) -- 13745(line=543, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo: tmp203 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp203)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp203, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp203, atslab_1, arg2) ; tmp204 = (ats_sum_ptr_type)0 ; tmp202 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp202, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp202, atslab_d2exp_node, tmp203) ; ats_selptrset_mac(anairiats_rec_14, tmp202, atslab_d2exp_typ, tmp204) ; return (tmp202) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13768(line=546, offs=12) -- 13883(line=552, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps: tmp206 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp206)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp206, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp206, atslab_1, arg2) ; tmp207 = (ats_sum_ptr_type)0 ; tmp205 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp205, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp205, atslab_d2exp_node, tmp206) ; ats_selptrset_mac(anairiats_rec_14, tmp205, atslab_d2exp_typ, tmp207) ; return (tmp205) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 13930(line=557, offs=15) -- 14437(line=574, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_34_1: tmp210 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_d2exp_node) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp210)->tag != 3) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_4, tmp210, atslab_0) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_4, tmp210, atslab_1) ; tmp214 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp214)->tag = 0 ; ats_selptrset_mac(anairiats_sum_11, tmp214, atslab_0, arg2) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp212, tmp214) ; tmp209 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp209)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp209, atslab_0, tmp211) ; ats_selptrset_mac(anairiats_sum_4, tmp209, atslab_1, tmp213) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: __ats_lab_36_1: tmp216 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp216)->tag = 0 ; ats_selptrset_mac(anairiats_sum_11, tmp216, atslab_0, arg2) ; tmp217 = (ats_sum_ptr_type)0 ; tmp215 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp215, atslab_0, tmp216) ; ats_selptrset_mac(anairiats_sum_1, tmp215, atslab_1, tmp217) ; tmp209 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp209)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp209, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp209, atslab_1, tmp215) ; break ; } while (0) ; tmp218 = (ats_sum_ptr_type)0 ; tmp208 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp208, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp208, atslab_d2exp_node, tmp209) ; ats_selptrset_mac(anairiats_rec_14, tmp208, atslab_d2exp_typ, tmp218) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp208 = arg1 ; break ; } while (0) ; return (tmp208) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 14492(line=577, offs=15) -- 14919(line=594, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn: tmp220 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp220)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp220, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp220, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp220, atslab_2, arg4) ; tmp222 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_d2exp_node) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp222)->tag != 3) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_4, tmp222, atslab_0) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_4, tmp222, atslab_1) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp224, tmp220) ; tmp221 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp221)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp221, atslab_0, tmp223) ; ats_selptrset_mac(anairiats_sum_4, tmp221, atslab_1, tmp225) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp227 = (ats_sum_ptr_type)0 ; tmp226 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp226, atslab_0, tmp220) ; ats_selptrset_mac(anairiats_sum_1, tmp226, atslab_1, tmp227) ; tmp221 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp221)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp221, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp221, atslab_1, tmp226) ; break ; } while (0) ; tmp228 = (ats_sum_ptr_type)0 ; tmp219 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp219, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp219, atslab_d2exp_node, tmp221) ; ats_selptrset_mac(anairiats_rec_14, tmp219, atslab_d2exp_typ, tmp228) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 14975(line=597, offs=19) -- 15144(line=604, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn: tmp230 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta (arg1, arg2, arg3) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_dyn (arg0, tmp230, arg4, arg5, arg6) ; return (tmp229) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_app_sta_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15223(line=610, offs=3) -- 15357(line=614, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit: tmp232 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp232)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp232, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp232, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp232, atslab_2, arg3) ; tmp233 = (ats_sum_ptr_type)0 ; tmp231 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp231, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp231, atslab_d2exp_node, tmp232) ; ats_selptrset_mac(anairiats_rec_14, tmp231, atslab_d2exp_typ, tmp233) ; return (tmp231) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15384(line=618, offs=3) -- 15499(line=622, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz: tmp235 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp235)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp235, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp235, atslab_1, arg2) ; tmp236 = (ats_sum_ptr_type)0 ; tmp234 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp234, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp234, atslab_d2exp_node, tmp235) ; ats_selptrset_mac(anairiats_rec_14, tmp234, atslab_d2exp_typ, tmp236) ; return (tmp234) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15526(line=626, offs=3) -- 15669(line=630, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub: tmp238 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp238)->tag = 6 ; ats_selptrset_mac(anairiats_sum_16, tmp238, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp238, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp238, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_16, tmp238, atslab_3, arg4) ; tmp239 = (ats_sum_ptr_type)0 ; tmp237 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp237, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp237, atslab_d2exp_node, tmp238) ; ats_selptrset_mac(anairiats_rec_14, tmp237, atslab_d2exp_typ, tmp239) ; return (tmp237) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15714(line=635, offs=13) -- 15826(line=639, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn: tmp241 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp241)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp241, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp241, atslab_1, arg2) ; tmp242 = (ats_sum_ptr_type)0 ; tmp240 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp240, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp240, atslab_d2exp_node, tmp241) ; ats_selptrset_mac(anairiats_rec_14, tmp240, atslab_d2exp_typ, tmp242) ; return (tmp240) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15849(line=642, offs=12) -- 15932(line=644, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool: tmp244 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp244)->tag = 8 ; ats_selptrset_mac(anairiats_sum_6, tmp244, atslab_0, arg1) ; tmp245 = (ats_sum_ptr_type)0 ; tmp243 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp243, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp243, atslab_d2exp_node, tmp244) ; ats_selptrset_mac(anairiats_rec_14, tmp243, atslab_d2exp_typ, tmp245) ; return (tmp243) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 15959(line=648, offs=3) -- 16090(line=652, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof: tmp247 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ((ats_sum_ptr_type)tmp247)->tag = 9 ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_4, arg5) ; tmp248 = (ats_sum_ptr_type)0 ; tmp246 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp246, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp246, atslab_d2exp_node, tmp247) ; ats_selptrset_mac(anairiats_rec_14, tmp246, atslab_d2exp_typ, tmp248) ; return (tmp246) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16138(line=655, offs=12) -- 16217(line=657, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char: tmp250 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp250)->tag = 10 ; ats_selptrset_mac(anairiats_sum_7, tmp250, atslab_0, arg1) ; tmp251 = (ats_sum_ptr_type)0 ; tmp249 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp249, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp249, atslab_d2exp_node, tmp250) ; ats_selptrset_mac(anairiats_rec_14, tmp249, atslab_d2exp_typ, tmp251) ; return (tmp249) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16239(line=660, offs=11) -- 16371(line=664, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con: tmp253 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp253)->tag = 11 ; ats_selptrset_mac(anairiats_sum_18, tmp253, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp253, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_18, tmp253, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_18, tmp253, atslab_3, arg4) ; tmp254 = (ats_sum_ptr_type)0 ; tmp252 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp252, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp252, atslab_d2exp_node, tmp253) ; ats_selptrset_mac(anairiats_rec_14, tmp252, atslab_d2exp_typ, tmp254) ; return (tmp252) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16393(line=667, offs=11) -- 16473(line=669, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst: tmp256 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp256)->tag = 12 ; ats_selptrset_mac(anairiats_sum_11, tmp256, atslab_0, arg1) ; tmp257 = (ats_sum_ptr_type)0 ; tmp255 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp255, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp255, atslab_d2exp_node, tmp256) ; ats_selptrset_mac(anairiats_rec_14, tmp255, atslab_d2exp_typ, tmp257) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16497(line=672, offs=13) -- 16577(line=674, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp: tmp259 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp259)->tag = 13 ; ats_selptrset_mac(anairiats_sum_11, tmp259, atslab_0, arg1) ; tmp260 = (ats_sum_ptr_type)0 ; tmp258 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp258, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp258, atslab_d2exp_node, tmp259) ; ats_selptrset_mac(anairiats_rec_14, tmp258, atslab_d2exp_typ, tmp260) ; return (tmp258) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16601(line=677, offs=13) -- 16693(line=679, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt: tmp262 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp262)->tag = 14 ; ats_selptrset_mac(anairiats_sum_12, tmp262, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp262, atslab_1, arg2) ; tmp263 = (ats_sum_ptr_type)0 ; tmp261 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp261, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp261, atslab_d2exp_node, tmp262) ; ats_selptrset_mac(anairiats_rec_14, tmp261, atslab_d2exp_typ, tmp263) ; return (tmp261) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16717(line=682, offs=13) -- 16799(line=684, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref: tmp265 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp265)->tag = 15 ; ats_selptrset_mac(anairiats_sum_11, tmp265, atslab_0, arg1) ; tmp266 = (ats_sum_ptr_type)0 ; tmp264 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp264, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp264, atslab_d2exp_node, tmp265) ; ats_selptrset_mac(anairiats_rec_14, tmp264, atslab_d2exp_typ, tmp266) ; return (tmp264) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16825(line=687, offs=15) -- 16909(line=689, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_dynload: tmp268 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp268)->tag = 16 ; ats_selptrset_mac(anairiats_sum_11, tmp268, atslab_0, arg1) ; tmp269 = (ats_sum_ptr_type)0 ; tmp267 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp267, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp267, atslab_d2exp_node, tmp268) ; ats_selptrset_mac(anairiats_rec_14, tmp267, atslab_d2exp_typ, tmp269) ; return (tmp267) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 16935(line=692, offs=15) -- 17033(line=696, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask: tmp271 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp271)->tag = 17 ; ats_selptrset_mac(anairiats_sum_4, tmp271, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp271, atslab_1, arg2) ; tmp272 = (ats_sum_ptr_type)0 ; tmp270 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp270, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp270, atslab_d2exp_node, tmp271) ; ats_selptrset_mac(anairiats_rec_14, tmp270, atslab_d2exp_typ, tmp272) ; return (tmp270) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17083(line=699, offs=13) -- 17157(line=701, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty: tmp274 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; tmp275 = (ats_sum_ptr_type)0 ; tmp273 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp273, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp273, atslab_d2exp_node, tmp274) ; ats_selptrset_mac(anairiats_rec_14, tmp273, atslab_d2exp_typ, tmp275) ; return (tmp273) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17181(line=704, offs=13) -- 17275(line=708, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist: tmp277 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp277)->tag = 19 ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_1, arg2) ; tmp278 = (ats_sum_ptr_type)0 ; tmp276 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp276, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp276, atslab_d2exp_node, tmp277) ; ats_selptrset_mac(anairiats_rec_14, tmp276, atslab_d2exp_typ, tmp278) ; return (tmp276) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17300(line=711, offs=14) -- 17397(line=715, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval: tmp280 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp280)->tag = 20 ; ats_selptrset_mac(anairiats_sum_4, tmp280, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp280, atslab_1, arg2) ; tmp281 = (ats_sum_ptr_type)0 ; tmp279 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp279, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp279, atslab_d2exp_node, tmp280) ; ats_selptrset_mac(anairiats_rec_14, tmp279, atslab_d2exp_typ, tmp281) ; return (tmp279) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17440(line=720, offs=11) -- 17562(line=726, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix: tmp283 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp283)->tag = 21 ; ats_selptrset_mac(anairiats_sum_5, tmp283, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp283, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp283, atslab_2, arg3) ; tmp284 = (ats_sum_ptr_type)0 ; tmp282 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp282, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp282, atslab_d2exp_node, tmp283) ; ats_selptrset_mac(anairiats_rec_14, tmp282, atslab_d2exp_typ, tmp284) ; return (tmp282) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17629(line=731, offs=13) -- 17717(line=733, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float: tmp286 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp286)->tag = 22 ; ats_selptrset_mac(anairiats_sum_11, tmp286, atslab_0, arg1) ; tmp287 = (ats_sum_ptr_type)0 ; tmp285 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp285, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp285, atslab_d2exp_node, tmp286) ; ats_selptrset_mac(anairiats_rec_14, tmp285, atslab_d2exp_typ, tmp287) ; return (tmp285) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17743(line=736, offs=15) -- 17833(line=738, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_floatsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_floatsp: tmp289 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp289)->tag = 23 ; ats_selptrset_mac(anairiats_sum_11, tmp289, atslab_0, arg1) ; tmp290 = (ats_sum_ptr_type)0 ; tmp288 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp288, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp288, atslab_d2exp_node, tmp289) ; ats_selptrset_mac(anairiats_rec_14, tmp288, atslab_d2exp_typ, tmp290) ; return (tmp288) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 17881(line=744, offs=3) -- 17979(line=748, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat: tmp292 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp292)->tag = 24 ; ats_selptrset_mac(anairiats_sum_4, tmp292, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp292, atslab_1, arg2) ; tmp293 = (ats_sum_ptr_type)0 ; tmp291 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp291, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp291, atslab_d2exp_node, tmp292) ; ats_selptrset_mac(anairiats_rec_14, tmp291, atslab_d2exp_typ, tmp293) ; return (tmp291) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18001(line=751, offs=11) -- 18133(line=757, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_for (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_for: tmp295 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ((ats_sum_ptr_type)tmp295)->tag = 25 ; ats_selptrset_mac(anairiats_sum_19, tmp295, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_19, tmp295, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_19, tmp295, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_19, tmp295, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_19, tmp295, atslab_4, arg5) ; tmp296 = (ats_sum_ptr_type)0 ; tmp294 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp294, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp294, atslab_d2exp_node, tmp295) ; ats_selptrset_mac(anairiats_rec_14, tmp294, atslab_d2exp_typ, tmp296) ; return (tmp294) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_for] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18160(line=761, offs=3) -- 18258(line=765, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat: tmp298 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp298)->tag = 26 ; ats_selptrset_mac(anairiats_sum_4, tmp298, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp298, atslab_1, arg2) ; tmp299 = (ats_sum_ptr_type)0 ; tmp297 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp297, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp297, atslab_d2exp_node, tmp298) ; ats_selptrset_mac(anairiats_rec_14, tmp297, atslab_d2exp_typ, tmp299) ; return (tmp297) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18300(line=770, offs=10) -- 18448(line=777, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if: tmp301 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp301)->tag = 27 ; ats_selptrset_mac(anairiats_sum_16, tmp301, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp301, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp301, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_16, tmp301, atslab_3, arg4) ; tmp302 = (ats_sum_ptr_type)0 ; tmp300 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp300, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp300, atslab_d2exp_node, tmp301) ; ats_selptrset_mac(anairiats_rec_14, tmp300, atslab_d2exp_typ, tmp302) ; return (tmp300) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18514(line=783, offs=3) -- 18606(line=787, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int: tmp304 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp304)->tag = 28 ; ats_selptrset_mac(anairiats_sum_4, tmp304, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp304, atslab_1, arg2) ; tmp305 = (ats_sum_ptr_type)0 ; tmp303 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp303, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp303, atslab_d2exp_node, tmp304) ; ats_selptrset_mac(anairiats_rec_14, tmp303, atslab_d2exp_typ, tmp305) ; return (tmp303) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18630(line=790, offs=13) -- 18724(line=794, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_intsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_intsp: tmp307 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp307)->tag = 29 ; ats_selptrset_mac(anairiats_sum_4, tmp307, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp307, atslab_1, arg2) ; tmp308 = (ats_sum_ptr_type)0 ; tmp306 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp306, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp306, atslab_d2exp_node, tmp307) ; ats_selptrset_mac(anairiats_rec_14, tmp306, atslab_d2exp_typ, tmp308) ; return (tmp306) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18771(line=799, offs=15) -- 18893(line=805, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn: tmp310 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp310)->tag = 30 ; ats_selptrset_mac(anairiats_sum_20, tmp310, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp310, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_20, tmp310, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_20, tmp310, atslab_3, arg4) ; tmp311 = (ats_sum_ptr_type)0 ; tmp309 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp309, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp309, atslab_d2exp_node, tmp310) ; ats_selptrset_mac(anairiats_rec_14, tmp309, atslab_d2exp_typ, tmp311) ; return (tmp309) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 18923(line=808, offs=19) -- 19049(line=814, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn: tmp313 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp313)->tag = 31 ; ats_selptrset_mac(anairiats_sum_20, tmp313, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp313, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_20, tmp313, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_20, tmp313, atslab_3, arg4) ; tmp314 = (ats_sum_ptr_type)0 ; tmp312 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp312, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp312, atslab_d2exp_node, tmp313) ; ats_selptrset_mac(anairiats_rec_14, tmp312, atslab_d2exp_typ, tmp314) ; return (tmp312) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19096(line=819, offs=15) -- 19204(line=825, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met: tmp316 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp316)->tag = 32 ; ats_selptrset_mac(anairiats_sum_3, tmp316, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp316, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp316, atslab_2, arg3) ; tmp317 = (ats_sum_ptr_type)0 ; tmp315 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp315, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp315, atslab_d2exp_node, tmp316) ; ats_selptrset_mac(anairiats_rec_14, tmp315, atslab_d2exp_typ, tmp317) ; return (tmp315) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03581_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; __ats_lab_ref_make_elt_03581_ats_ptr_type: /* ats_ptr_type tmp321 ; */ tmp321 = arg0 ; tmp320 = atspre_ref_make_elt_tsz ((&tmp321), sizeof(ats_ptr_type)) ; return (tmp320) ; } /* end of [ref_make_elt_03581_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19262(line=829, offs=3) -- 19399(line=835, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met_new (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp322) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met_new: tmp322 = (ats_sum_ptr_type)0 ; tmp319 = ref_make_elt_03581_ats_ptr_type (tmp322) ; tmp318 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met (arg0, tmp319, arg1, arg2) ; return (tmp318) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_met_new] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19476(line=840, offs=15) -- 19588(line=844, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta: tmp324 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp324)->tag = 33 ; ats_selptrset_mac(anairiats_sum_3, tmp324, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp324, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp324, atslab_2, arg3) ; tmp325 = (ats_sum_ptr_type)0 ; tmp323 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp323, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp323, atslab_d2exp_node, tmp324) ; ats_selptrset_mac(anairiats_rec_14, tmp323, atslab_d2exp_typ, tmp325) ; return (tmp323) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19640(line=850, offs=3) -- 19727(line=854, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay: tmp327 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp327)->tag = 34 ; ats_selptrset_mac(anairiats_sum_11, tmp327, atslab_0, arg1) ; tmp328 = (ats_sum_ptr_type)0 ; tmp326 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp326, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp326, atslab_d2exp_node, tmp327) ; ats_selptrset_mac(anairiats_rec_14, tmp326, atslab_d2exp_typ, tmp328) ; return (tmp326) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19788(line=858, offs=3) -- 19892(line=862, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay: tmp330 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp330)->tag = 35 ; ats_selptrset_mac(anairiats_sum_4, tmp330, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp330, atslab_1, arg2) ; tmp331 = (ats_sum_ptr_type)0 ; tmp329 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp329, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp329, atslab_d2exp_node, tmp330) ; ats_selptrset_mac(anairiats_rec_14, tmp329, atslab_d2exp_typ, tmp331) ; return (tmp329) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 19967(line=868, offs=3) -- 20060(line=871, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let: tmp333 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp333)->tag = 36 ; ats_selptrset_mac(anairiats_sum_4, tmp333, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp333, atslab_1, arg2) ; tmp334 = (ats_sum_ptr_type)0 ; tmp332 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp332, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp332, atslab_d2exp_node, tmp333) ; ats_selptrset_mac(anairiats_rec_14, tmp332, atslab_d2exp_typ, tmp334) ; return (tmp332) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20107(line=875, offs=3) -- 20201(line=878, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list: tmp336 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp336)->tag = 37 ; ats_selptrset_mac(anairiats_sum_12, tmp336, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp336, atslab_1, arg2) ; tmp337 = (ats_sum_ptr_type)0 ; tmp335 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp335, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp335, atslab_d2exp_node, tmp336) ; ats_selptrset_mac(anairiats_rec_14, tmp335, atslab_d2exp_typ, tmp337) ; return (tmp335) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20252(line=882, offs=3) -- 20339(line=885, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_loopexn (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_loopexn: tmp339 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp339)->tag = 38 ; ats_selptrset_mac(anairiats_sum_21, tmp339, atslab_0, arg1) ; tmp340 = (ats_sum_ptr_type)0 ; tmp338 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp338, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp338, atslab_d2exp_node, tmp339) ; ats_selptrset_mac(anairiats_rec_14, tmp338, atslab_d2exp_typ, tmp340) ; return (tmp338) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20387(line=888, offs=11) -- 20514(line=895, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst: tmp342 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp342)->tag = 39 ; ats_selptrset_mac(anairiats_sum_5, tmp342, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp342, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp342, atslab_2, arg3) ; tmp343 = (ats_sum_ptr_type)0 ; tmp341 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp341, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp341, atslab_d2exp_node, tmp342) ; ats_selptrset_mac(anairiats_rec_14, tmp341, atslab_d2exp_typ, tmp343) ; return (tmp341) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20579(line=900, offs=11) -- 20659(line=902, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac: tmp345 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp345)->tag = 40 ; ats_selptrset_mac(anairiats_sum_11, tmp345, atslab_0, arg1) ; tmp346 = (ats_sum_ptr_type)0 ; tmp344 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp344, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp344, atslab_d2exp_node, tmp345) ; ats_selptrset_mac(anairiats_rec_14, tmp344, atslab_d2exp_typ, tmp346) ; return (tmp344) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_mac] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20706(line=905, offs=14) -- 20801(line=909, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn: tmp348 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp348)->tag = 41 ; ats_selptrset_mac(anairiats_sum_4, tmp348, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp348, atslab_1, arg2) ; tmp349 = (ats_sum_ptr_type)0 ; tmp347 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp347, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp347, atslab_d2exp_node, tmp348) ; ats_selptrset_mac(anairiats_rec_14, tmp347, atslab_d2exp_typ, tmp349) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_macsyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 20871(line=914, offs=13) -- 20953(line=916, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof: tmp351 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp351)->tag = 42 ; ats_selptrset_mac(anairiats_sum_11, tmp351, atslab_0, arg1) ; tmp352 = (ats_sum_ptr_type)0 ; tmp350 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp350, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp350, atslab_d2exp_node, tmp351) ; ats_selptrset_mac(anairiats_rec_14, tmp350, atslab_d2exp_typ, tmp352) ; return (tmp350) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21001(line=919, offs=13) -- 21083(line=921, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise: tmp354 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp354)->tag = 43 ; ats_selptrset_mac(anairiats_sum_11, tmp354, atslab_0, arg1) ; tmp355 = (ats_sum_ptr_type)0 ; tmp353 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp353, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp353, atslab_d2exp_node, tmp354) ; ats_selptrset_mac(anairiats_rec_14, tmp353, atslab_d2exp_typ, tmp355) ; return (tmp353) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21129(line=924, offs=11) -- 21245(line=930, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec: tmp357 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp357)->tag = 44 ; ats_selptrset_mac(anairiats_sum_13, tmp357, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp357, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_13, tmp357, atslab_2, arg3) ; tmp358 = (ats_sum_ptr_type)0 ; tmp356 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp356, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp356, atslab_d2exp_node, tmp357) ; ats_selptrset_mac(anairiats_rec_14, tmp356, atslab_d2exp_typ, tmp358) ; return (tmp356) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21293(line=933, offs=15) -- 21407(line=939, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_scaseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_scaseof: tmp360 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp360)->tag = 45 ; ats_selptrset_mac(anairiats_sum_3, tmp360, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp360, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp360, atslab_2, arg3) ; tmp361 = (ats_sum_ptr_type)0 ; tmp359 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp359, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp359, atslab_d2exp_node, tmp360) ; ats_selptrset_mac(anairiats_rec_14, tmp359, atslab_d2exp_typ, tmp361) ; return (tmp359) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_scaseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21455(line=942, offs=11) -- 21574(line=948, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel: tmp363 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp363)->tag = 46 ; ats_selptrset_mac(anairiats_sum_4, tmp363, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp363, atslab_1, arg2) ; tmp364 = (ats_sum_ptr_type)0 ; tmp362 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp362, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp362, atslab_d2exp_node, tmp363) ; ats_selptrset_mac(anairiats_rec_14, tmp362, atslab_d2exp_typ, tmp364) ; return (tmp362) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21624(line=952, offs=3) -- 21797(line=958, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel_ptr: tmp367 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_d2exp_loc) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref (tmp367, arg1) ; tmp370 = (ats_sum_ptr_type)0 ; tmp369 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp369, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp369, atslab_1, tmp370) ; tmp368 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp368)->tag = 46 ; ats_selptrset_mac(anairiats_sum_4, tmp368, atslab_0, tmp366) ; ats_selptrset_mac(anairiats_sum_4, tmp368, atslab_1, tmp369) ; tmp371 = (ats_sum_ptr_type)0 ; tmp365 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp365, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp365, atslab_d2exp_node, tmp368) ; ats_selptrset_mac(anairiats_rec_14, tmp365, atslab_d2exp_typ, tmp371) ; return (tmp365) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sel_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21844(line=961, offs=11) -- 21926(line=963, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq: tmp373 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp373)->tag = 47 ; ats_selptrset_mac(anairiats_sum_11, tmp373, atslab_0, arg1) ; tmp374 = (ats_sum_ptr_type)0 ; tmp372 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp372, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp372, atslab_d2exp_node, tmp373) ; ats_selptrset_mac(anairiats_rec_14, tmp372, atslab_d2exp_typ, tmp374) ; return (tmp372) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 21975(line=966, offs=16) -- 22060(line=968, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_showtype (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_showtype: tmp376 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp376)->tag = 48 ; ats_selptrset_mac(anairiats_sum_11, tmp376, atslab_0, arg1) ; tmp377 = (ats_sum_ptr_type)0 ; tmp375 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp375, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp375, atslab_d2exp_node, tmp376) ; ats_selptrset_mac(anairiats_rec_14, tmp375, atslab_d2exp_typ, tmp377) ; return (tmp375) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_showtype] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22111(line=972, offs=3) -- 22253(line=976, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif: tmp379 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp379)->tag = 49 ; ats_selptrset_mac(anairiats_sum_16, tmp379, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp379, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp379, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_16, tmp379, atslab_3, arg4) ; tmp380 = (ats_sum_ptr_type)0 ; tmp378 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp378, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp378, atslab_d2exp_node, tmp379) ; ats_selptrset_mac(anairiats_rec_14, tmp378, atslab_d2exp_typ, tmp380) ; return (tmp378) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22300(line=979, offs=14) -- 22395(line=983, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string: tmp382 = ATS_MALLOC(sizeof(anairiats_sum_22)) ; ((ats_sum_ptr_type)tmp382)->tag = 51 ; ats_selptrset_mac(anairiats_sum_22, tmp382, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_22, tmp382, atslab_1, arg2) ; tmp383 = (ats_sum_ptr_type)0 ; tmp381 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp381, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp381, atslab_d2exp_node, tmp382) ; ats_selptrset_mac(anairiats_rec_14, tmp381, atslab_d2exp_typ, tmp383) ; return (tmp381) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22420(line=986, offs=14) -- 22509(line=990, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct: tmp385 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp385)->tag = 50 ; ats_selptrset_mac(anairiats_sum_11, tmp385, atslab_0, arg1) ; tmp386 = (ats_sum_ptr_type)0 ; tmp384 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp384, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp384, atslab_d2exp_node, tmp385) ; ats_selptrset_mac(anairiats_rec_14, tmp384, atslab_d2exp_typ, tmp386) ; return (tmp384) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22531(line=993, offs=11) -- 22611(line=995, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym: tmp388 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp388)->tag = 52 ; ats_selptrset_mac(anairiats_sum_11, tmp388, atslab_0, arg1) ; tmp389 = (ats_sum_ptr_type)0 ; tmp387 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp387, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp387, atslab_d2exp_node, tmp388) ; ats_selptrset_mac(anairiats_rec_14, tmp387, atslab_d2exp_typ, tmp389) ; return (tmp387) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22635(line=998, offs=13) -- 22735(line=1002, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid: tmp391 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp391)->tag = 53 ; ats_selptrset_mac(anairiats_sum_4, tmp391, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp391, atslab_1, arg2) ; tmp392 = (ats_sum_ptr_type)0 ; tmp390 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp390, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp390, atslab_d2exp_node, tmp391) ; ats_selptrset_mac(anairiats_rec_14, tmp390, atslab_d2exp_typ, tmp392) ; return (tmp390) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22757(line=1005, offs=11) -- 22828(line=1007, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_top (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_top: tmp394 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; tmp395 = (ats_sum_ptr_type)0 ; tmp393 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp393, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp393, atslab_d2exp_node, tmp394) ; ats_selptrset_mac(anairiats_rec_14, tmp393, atslab_d2exp_typ, tmp395) ; return (tmp393) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_top] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 22854(line=1010, offs=15) -- 22966(line=1016, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_trywith (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_trywith: tmp397 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp397)->tag = 55 ; ats_selptrset_mac(anairiats_sum_3, tmp397, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp397, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp397, atslab_2, arg3) ; tmp398 = (ats_sum_ptr_type)0 ; tmp396 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp396, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp396, atslab_d2exp_node, tmp397) ; ats_selptrset_mac(anairiats_rec_14, tmp396, atslab_d2exp_typ, tmp398) ; return (tmp396) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_trywith] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23014(line=1019, offs=11) -- 23094(line=1021, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var: tmp400 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp400)->tag = 56 ; ats_selptrset_mac(anairiats_sum_11, tmp400, atslab_0, arg1) ; tmp401 = (ats_sum_ptr_type)0 ; tmp399 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp399, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp399, atslab_d2exp_node, tmp400) ; ats_selptrset_mac(anairiats_rec_14, tmp399, atslab_d2exp_typ, tmp401) ; return (tmp399) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23121(line=1025, offs=3) -- 23205(line=1028, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat: tmp403 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp403)->tag = 57 ; ats_selptrset_mac(anairiats_sum_11, tmp403, atslab_0, arg1) ; tmp404 = (ats_sum_ptr_type)0 ; tmp402 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp402, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp402, atslab_d2exp_node, tmp403) ; ats_selptrset_mac(anairiats_rec_14, tmp402, atslab_d2exp_typ, tmp404) ; return (tmp402) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23256(line=1032, offs=3) -- 23351(line=1035, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where: tmp406 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp406)->tag = 58 ; ats_selptrset_mac(anairiats_sum_4, tmp406, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp406, atslab_1, arg2) ; tmp407 = (ats_sum_ptr_type)0 ; tmp405 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp405, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp405, atslab_d2exp_node, tmp406) ; ats_selptrset_mac(anairiats_rec_14, tmp405, atslab_d2exp_typ, tmp407) ; return (tmp405) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23399(line=1038, offs=13) -- 23527(line=1044, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_while (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_while: tmp409 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp409)->tag = 59 ; ats_selptrset_mac(anairiats_sum_3, tmp409, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp409, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp409, atslab_2, arg3) ; tmp410 = (ats_sum_ptr_type)0 ; tmp408 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp408, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp408, atslab_d2exp_node, tmp409) ; ats_selptrset_mac(anairiats_rec_14, tmp408, atslab_d2exp_typ, tmp410) ; return (tmp408) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_while] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23632(line=1052, offs=7) -- 23920(line=1063, offs=6) */ ATSstaticdec() ats_ptr_type aux_115 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; __ats_lab_aux_115: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp414 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp415 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (arg0) ; tmp417 = atspre_add_int_int (arg0, 1) ; tmp416 = aux_115 (tmp417, tmp414) ; tmp412 = ATS_MALLOC(sizeof(anairiats_sum_23)) ; ats_selptrset_mac(anairiats_sum_23, tmp412, atslab_0, tmp415) ; ats_selptrset_mac(anairiats_sum_23, tmp412, atslab_1, tmp413) ; ats_selptrset_mac(anairiats_sum_23, tmp412, atslab_2, tmp416) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: tmp412 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp412) ; } /* end of [aux_115] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 23594(line=1049, offs=11) -- 24053(line=1069, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup: tmp418 = aux_115 (0, arg3) ; tmp419 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp419)->tag = 44 ; ats_selptrset_mac(anairiats_sum_13, tmp419, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp419, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_13, tmp419, atslab_2, tmp418) ; tmp420 = (ats_sum_ptr_type)0 ; tmp411 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp411, atslab_d2exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp411, atslab_d2exp_node, tmp419) ; ats_selptrset_mac(anairiats_rec_14, tmp411, atslab_d2exp_typ, tmp420) ; return (tmp411) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24118(line=1074, offs=11) -- 24178(line=1076, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_lab: tmp422 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp422)->tag = 0 ; ats_selptrset_mac(anairiats_sum_11, tmp422, atslab_0, arg1) ; tmp421 = ATS_MALLOC(sizeof(anairiats_rec_24)) ; ats_selptrset_mac(anairiats_rec_24, tmp421, atslab_d2lab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_24, tmp421, atslab_d2lab_node, tmp422) ; return (tmp421) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24200(line=1079, offs=11) -- 24260(line=1081, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind: tmp424 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp424)->tag = 1 ; ats_selptrset_mac(anairiats_sum_11, tmp424, atslab_0, arg1) ; tmp423 = ATS_MALLOC(sizeof(anairiats_rec_24)) ; ats_selptrset_mac(anairiats_rec_24, tmp423, atslab_d2lab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_24, tmp423, atslab_d2lab_node, tmp424) ; return (tmp423) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24306(line=1086, offs=14) -- 24362(line=1087, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp425) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make: tmp425 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp425, atslab_i2nvarg_var, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp425, atslab_i2nvarg_typ, arg1) ; return (tmp425) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24563(line=1100, offs=3) -- 24689(line=1105, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make: tmp432 = (ats_sum_ptr_type)0 ; tmp431 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp431, atslab_i2nvresstate_svs, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp431, atslab_i2nvresstate_gua, arg1) ; ats_selptrset_mac(anairiats_rec_26, tmp431, atslab_i2nvresstate_arg, arg2) ; ats_selptrset_mac(anairiats_rec_26, tmp431, atslab_i2nvresstate_met, tmp432) ; return (tmp431) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24755(line=1109, offs=3) -- 24882(line=1114, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make_met (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make_met: tmp433 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp433, atslab_i2nvresstate_svs, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp433, atslab_i2nvresstate_gua, arg1) ; ats_selptrset_mac(anairiats_rec_26, tmp433, atslab_i2nvresstate_arg, arg2) ; ats_selptrset_mac(anairiats_rec_26, tmp433, atslab_i2nvresstate_met, arg3) ; return (tmp433) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make_met] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 24938(line=1117, offs=15) -- 25104(line=1127, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp434) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make: tmp434 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_loc, arg0) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_svs, arg1) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_gua, arg2) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_met, arg3) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_arg, arg4) ; ats_selptrset_mac(anairiats_rec_27, tmp434, atslab_loopi2nv_res, arg5) ; return (tmp434) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 25163(line=1133, offs=4) -- 25914(line=1156, offs=4) */ ATSstaticdec() ats_ptr_type i2nvarg_update_122 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; // ATSlocal_void (tmp442) ; // ATSlocal_void (tmp443) ; // ATSlocal_void (tmp444) ; // ATSlocal_void (tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; __ats_lab_i2nvarg_update_122: tmp436 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_i2nvarg_var) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (tmp436) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp437 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_42_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_28, tmp437, atslab_0) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr (tmp436) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp440 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp441 = ats_caselptrlab_mac(anairiats_sum_28, tmp440, atslab_0) ; tmp439 = tmp441 ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: /* tmp442 = */ prerr_interror_0 () ; /* tmp443 = */ atspre_prerr_string (ATSstrcst(": i2nvresstate_tr: d2v = ")) ; /* tmp444 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp436) ; /* tmp445 = */ atspre_prerr_newline () ; /* tmp439 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp447 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_i2nvarg_typ) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp447 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp448 = ats_caselptrlab_mac(anairiats_sum_28, tmp447, atslab_0) ; tmp449 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp448, tmp439) ; tmp446 = ATS_MALLOC(sizeof(anairiats_sum_28)) ; ats_selptrset_mac(anairiats_sum_28, tmp446, atslab_0, tmp449) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (tmp447 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: tmp446 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp435 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make (tmp438, tmp446) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (tmp437 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp435 = arg0 ; break ; } while (0) ; return (tmp435) ; } /* end of [i2nvarg_update_122] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 25997(line=1161, offs=21) -- 26156(line=1165, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update: tmp452 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_i2nvresstate_arg) ; tmp451 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp452, &i2nvarg_update_122) ; tmp453 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_i2nvresstate_svs) ; tmp454 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_i2nvresstate_gua) ; tmp450 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make (tmp453, tmp454, tmp451) ; return (tmp450) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 26216(line=1168, offs=17) -- 26525(line=1180, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_update (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_update: tmp457 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_arg) ; tmp456 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp457, &i2nvarg_update_122) ; tmp459 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_res) ; tmp458 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update (tmp459) ; tmp460 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_loc) ; tmp461 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_svs) ; tmp462 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_gua) ; tmp463 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_loopi2nv_met) ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_make (tmp460, tmp461, tmp462, tmp463, tmp456, tmp458) ; return (tmp455) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_update] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 26621(line=1187, offs=13) -- 26697(line=1189, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp464) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make: tmp464 = ATS_MALLOC(sizeof(anairiats_rec_29)) ; ats_selptrset_mac(anairiats_rec_29, tmp464, atslab_m2atch_loc, arg0) ; ats_selptrset_mac(anairiats_rec_29, tmp464, atslab_m2atch_exp, arg1) ; ats_selptrset_mac(anairiats_rec_29, tmp464, atslab_m2atch_pat, arg2) ; return (tmp464) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 26744(line=1192, offs=12) -- 26888(line=1202, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp465) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make: tmp465 = ATS_MALLOC(sizeof(anairiats_rec_30)) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_gua, arg2) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_seq, arg3) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_neg, arg4) ; ats_selptrset_mac(anairiats_rec_30, tmp465, atslab_c2lau_exp, arg5) ; return (tmp465) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 26935(line=1205, offs=13) -- 27011(line=1207, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sc2lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp466) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sc2lau_make: tmp466 = ATS_MALLOC(sizeof(anairiats_rec_31)) ; ats_selptrset_mac(anairiats_rec_31, tmp466, atslab_sc2lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_31, tmp466, atslab_sc2lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_31, tmp466, atslab_sc2lau_exp, arg2) ; return (tmp466) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sc2lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27057(line=1212, offs=14) -- 27112(line=1213, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2tavar_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp467) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2tavar_make: tmp467 = ATS_MALLOC(sizeof(anairiats_rec_32)) ; ats_selptrset_mac(anairiats_rec_32, tmp467, atslab_s2tavar_loc, arg0) ; ats_selptrset_mac(anairiats_rec_32, tmp467, atslab_s2tavar_var, arg1) ; return (tmp467) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2tavar_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27138(line=1216, offs=15) -- 27249(line=1223, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2aspdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp468) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2aspdec_make: tmp468 = ATS_MALLOC(sizeof(anairiats_rec_33)) ; ats_selptrset_mac(anairiats_rec_33, tmp468, atslab_s2aspdec_fil, arg0) ; ats_selptrset_mac(anairiats_rec_33, tmp468, atslab_s2aspdec_loc, arg1) ; ats_selptrset_mac(anairiats_rec_33, tmp468, atslab_s2aspdec_cst, arg2) ; ats_selptrset_mac(anairiats_rec_33, tmp468, atslab_s2aspdec_def, arg3) ; return (tmp468) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2aspdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27302(line=1227, offs=3) -- 27403(line=1230, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp469) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make: tmp469 = ATS_MALLOC(sizeof(anairiats_rec_34)) ; ats_selptrset_mac(anairiats_rec_34, tmp469, atslab_v2aldec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_34, tmp469, atslab_v2aldec_pat, arg1) ; ats_selptrset_mac(anairiats_rec_34, tmp469, atslab_v2aldec_def, arg2) ; ats_selptrset_mac(anairiats_rec_34, tmp469, atslab_v2aldec_ann, arg3) ; return (tmp469) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27455(line=1234, offs=3) -- 27556(line=1237, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__f2undec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp470) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__f2undec_make: tmp470 = ATS_MALLOC(sizeof(anairiats_rec_35)) ; ats_selptrset_mac(anairiats_rec_35, tmp470, atslab_f2undec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_35, tmp470, atslab_f2undec_var, arg1) ; ats_selptrset_mac(anairiats_rec_35, tmp470, atslab_f2undec_def, arg2) ; ats_selptrset_mac(anairiats_rec_35, tmp470, atslab_f2undec_ann, arg3) ; return (tmp470) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__f2undec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27606(line=1240, offs=14) -- 27788(line=1251, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2ardec_make (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp471) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2ardec_make: tmp471 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_knd, arg1) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_dvar, arg2) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_svar, arg3) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_typ, arg4) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_wth, arg5) ; ats_selptrset_mac(anairiats_rec_36, tmp471, atslab_v2ardec_ini, arg6) ; return (tmp471) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2ardec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 27838(line=1254, offs=14) -- 28049(line=1264, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2mpdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp472) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2mpdec_make: tmp472 = ATS_MALLOC(sizeof(anairiats_rec_37)) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_loc_id, arg1) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_cst, arg2) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_decarg, arg3) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_tmparg, arg4) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_tmpgua, arg5) ; ats_selptrset_mac(anairiats_rec_37, tmp472, atslab_i2mpdec_def, arg6) ; return (tmp472) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2mpdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28117(line=1269, offs=11) -- 28168(line=1271, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none: tmp474 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0) ; tmp473 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp473, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp473, atslab_d2ec_node, tmp474) ; return (tmp473) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28190(line=1274, offs=11) -- 28249(line=1276, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list: tmp476 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp476)->tag = 1 ; ats_selptrset_mac(anairiats_sum_11, tmp476, atslab_0, arg1) ; tmp475 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp475, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp475, atslab_d2ec_node, tmp476) ; return (tmp475) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28274(line=1279, offs=14) -- 28336(line=1281, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_include (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_include: tmp478 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp478)->tag = 2 ; ats_selptrset_mac(anairiats_sum_11, tmp478, atslab_0, arg1) ; tmp477 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp477, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp477, atslab_d2ec_node, tmp478) ; return (tmp477) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_include] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28361(line=1284, offs=14) -- 28423(line=1286, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symintr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symintr: tmp480 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp480)->tag = 3 ; ats_selptrset_mac(anairiats_sum_11, tmp480, atslab_0, arg1) ; tmp479 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp479, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp479, atslab_d2ec_node, tmp480) ; return (tmp479) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symintr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28448(line=1289, offs=14) -- 28510(line=1291, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symelim (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symelim: tmp482 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp482)->tag = 4 ; ats_selptrset_mac(anairiats_sum_11, tmp482, atslab_0, arg1) ; tmp481 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp481, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp481, atslab_d2ec_node, tmp482) ; return (tmp481) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symelim] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28535(line=1294, offs=14) -- 28597(line=1296, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_stavars (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_stavars: tmp484 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp484)->tag = 5 ; ats_selptrset_mac(anairiats_sum_11, tmp484, atslab_0, arg1) ; tmp483 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp483, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp483, atslab_d2ec_node, tmp484) ; return (tmp483) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_stavars] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28622(line=1299, offs=14) -- 28682(line=1301, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_saspdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_saspdec: tmp486 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp486)->tag = 6 ; ats_selptrset_mac(anairiats_sum_11, tmp486, atslab_0, arg1) ; tmp485 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp485, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp485, atslab_d2ec_node, tmp486) ; return (tmp485) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_saspdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28707(line=1304, offs=14) -- 28781(line=1306, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dcstdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dcstdec: tmp488 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp488)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp488, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp488, atslab_1, arg2) ; tmp487 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp487, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp487, atslab_d2ec_node, tmp488) ; return (tmp487) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dcstdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28805(line=1309, offs=13) -- 28878(line=1311, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_datdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_datdec: tmp490 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp490)->tag = 8 ; ats_selptrset_mac(anairiats_sum_4, tmp490, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp490, atslab_1, arg2) ; tmp489 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp489, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp489, atslab_d2ec_node, tmp490) ; return (tmp489) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_datdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28902(line=1314, offs=13) -- 28965(line=1316, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_exndec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_exndec: tmp492 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp492)->tag = 9 ; ats_selptrset_mac(anairiats_sum_11, tmp492, atslab_0, arg1) ; tmp491 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp491, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp491, atslab_d2ec_node, tmp492) ; return (tmp491) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_exndec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 28991(line=1319, offs=15) -- 29062(line=1321, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_overload (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_overload: tmp494 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp494)->tag = 10 ; ats_selptrset_mac(anairiats_sum_4, tmp494, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp494, atslab_1, arg2) ; tmp493 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp493, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp493, atslab_d2ec_node, tmp494) ; return (tmp493) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_overload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29086(line=1324, offs=13) -- 29167(line=1326, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extype (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extype: tmp496 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp496)->tag = 11 ; ats_selptrset_mac(anairiats_sum_4, tmp496, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp496, atslab_1, arg2) ; tmp495 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp495, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp495, atslab_d2ec_node, tmp496) ; return (tmp495) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29191(line=1329, offs=13) -- 29272(line=1331, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extval: tmp498 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp498)->tag = 12 ; ats_selptrset_mac(anairiats_sum_4, tmp498, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp498, atslab_1, arg2) ; tmp497 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp497, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp497, atslab_d2ec_node, tmp498) ; return (tmp497) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29297(line=1334, offs=14) -- 29381(line=1336, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extcode (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extcode: tmp500 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp500)->tag = 13 ; ats_selptrset_mac(anairiats_sum_12, tmp500, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp500, atslab_1, arg2) ; tmp499 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp499, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp499, atslab_d2ec_node, tmp500) ; return (tmp499) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extcode] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29406(line=1339, offs=14) -- 29486(line=1341, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs: tmp502 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp502)->tag = 14 ; ats_selptrset_mac(anairiats_sum_4, tmp502, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp502, atslab_1, arg2) ; tmp501 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp501, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp501, atslab_d2ec_node, tmp502) ; return (tmp501) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29515(line=1344, offs=18) -- 29583(line=1346, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_par (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_par: tmp504 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp504)->tag = 15 ; ats_selptrset_mac(anairiats_sum_11, tmp504, atslab_0, arg1) ; tmp503 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp503, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp503, atslab_d2ec_node, tmp504) ; return (tmp503) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_par] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29612(line=1349, offs=18) -- 29680(line=1351, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec: tmp506 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp506)->tag = 16 ; ats_selptrset_mac(anairiats_sum_11, tmp506, atslab_0, arg1) ; tmp505 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp505, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp505, atslab_d2ec_node, tmp506) ; return (tmp505) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29707(line=1355, offs=3) -- 29803(line=1357, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_fundecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_fundecs: tmp508 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp508)->tag = 17 ; ats_selptrset_mac(anairiats_sum_3, tmp508, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp508, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp508, atslab_2, arg3) ; tmp507 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp507, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp507, atslab_d2ec_node, tmp508) ; return (tmp507) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_fundecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29828(line=1360, offs=14) -- 29892(line=1362, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_vardecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_vardecs: tmp510 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp510)->tag = 18 ; ats_selptrset_mac(anairiats_sum_11, tmp510, atslab_0, arg1) ; tmp509 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp509, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp509, atslab_d2ec_node, tmp510) ; return (tmp509) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_vardecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 29916(line=1365, offs=13) -- 29977(line=1367, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_impdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_impdec: tmp512 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp512)->tag = 19 ; ats_selptrset_mac(anairiats_sum_11, tmp512, atslab_0, arg1) ; tmp511 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp511, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp511, atslab_d2ec_node, tmp512) ; return (tmp511) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_impdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 30000(line=1370, offs=12) -- 30078(line=1372, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_local (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_local: tmp514 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp514)->tag = 20 ; ats_selptrset_mac(anairiats_sum_4, tmp514, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp514, atslab_1, arg2) ; tmp513 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp513, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp513, atslab_d2ec_node, tmp514) ; return (tmp513) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 30103(line=1375, offs=14) -- 30165(line=1377, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dynload: tmp516 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp516)->tag = 21 ; ats_selptrset_mac(anairiats_sum_11, tmp516, atslab_0, arg1) ; tmp515 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp515, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp515, atslab_d2ec_node, tmp516) ; return (tmp515) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 30190(line=1380, offs=14) -- 30315(line=1385, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_staload (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_staload: tmp518 = ATS_MALLOC(sizeof(anairiats_sum_39)) ; ((ats_sum_ptr_type)tmp518)->tag = 22 ; ats_selptrset_mac(anairiats_sum_39, tmp518, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_39, tmp518, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_39, tmp518, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_39, tmp518, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_39, tmp518, atslab_4, arg5) ; tmp517 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp517, atslab_d2ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp517, atslab_d2ec_node, tmp518) ; return (tmp517) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_staload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2.dats: 30392(line=1391, offs=3) -- 31361(line=1416, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_bool_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_bool_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_bool_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_bool_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_bool_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp: tmp520 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp520)->tag != 6) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp521 = ats_caselptrlab_mac(anairiats_sum_16, tmp520, atslab_0) ; tmp522 = ats_caselptrlab_mac(anairiats_sum_16, tmp520, atslab_1) ; tmp523 = ats_caselptrlab_mac(anairiats_sum_16, tmp520, atslab_2) ; tmp524 = ats_caselptrlab_mac(anairiats_sum_16, tmp520, atslab_3) ; tmp525 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr (tmp522) ; if (tmp525) { tmp526 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind (tmp523, tmp524) ; tmp528 = (ats_sum_ptr_type)0 ; tmp527 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp527, atslab_0, tmp526) ; ats_selptrset_mac(anairiats_sum_1, tmp527, atslab_1, tmp528) ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp522) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp527) ; } else { tmp519 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp519)->tag = 0 ; ats_selptrset_mac(anairiats_sum_16, tmp519, atslab_0, tmp521) ; ats_selptrset_mac(anairiats_sum_16, tmp519, atslab_1, tmp522) ; ats_selptrset_mac(anairiats_sum_16, tmp519, atslab_2, tmp523) ; ats_selptrset_mac(anairiats_sum_16, tmp519, atslab_3, tmp524) ; } /* end of [if] */ break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp520)->tag != 15) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp529 = ats_caselptrlab_mac(anairiats_sum_11, tmp520, atslab_0) ; tmp530 = (ats_sum_ptr_type)0 ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp529) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp530) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp520)->tag != 46) { goto __ats_lab_55_0 ; } __ats_lab_50_1: tmp531 = ats_caselptrlab_mac(anairiats_sum_4, tmp520, atslab_0) ; tmp532 = ats_caselptrlab_mac(anairiats_sum_4, tmp520, atslab_1) ; tmp533 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp531), atslab_d2exp_node) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp533)->tag != 56) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp534 = ats_caselptrlab_mac(anairiats_sum_11, tmp533, atslab_0) ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (tmp534) ; if (!tmp535) { goto __ats_lab_52_1 ; } tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp534) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp532) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp533)->tag != 56) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp536 = ats_caselptrlab_mac(anairiats_sum_11, tmp533, atslab_0) ; tmp537 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp536) ; if (!tmp537) { goto __ats_lab_54_1 ; } tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp536) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp532) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp533)->tag != 15) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp538 = ats_caselptrlab_mac(anairiats_sum_11, tmp533, atslab_0) ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp538) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp532) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp519 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp519)->tag = 4 ; ats_selptrset_mac(anairiats_sum_11, tmp519, atslab_0, arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp520)->tag != 56) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp539 = ats_caselptrlab_mac(anairiats_sum_11, tmp520, atslab_0) ; tmp540 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (tmp539) ; if (!tmp540) { goto __ats_lab_56_1 ; } tmp541 = (ats_sum_ptr_type)0 ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp539) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp541) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp520)->tag != 56) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp542 = ats_caselptrlab_mac(anairiats_sum_11, tmp520, atslab_0) ; tmp543 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp542) ; if (!tmp543) { goto __ats_lab_57_1 ; } tmp544 = (ats_sum_ptr_type)0 ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp519)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_0, tmp542) ; ats_selptrset_mac(anairiats_sum_4, tmp519, atslab_1, tmp544) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: tmp519 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp519)->tag = 4 ; ats_selptrset_mac(anairiats_sum_11, tmp519, atslab_0, arg0) ; break ; } while (0) ; return (tmp519) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp26, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp426, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp427, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp428, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp429, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp430, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp26 = (ats_sum_ptr_type)0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__s2varlstord_nil = statmp26 ; statmp27 = (ats_sum_ptr_type)0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__d2varlstord_nil = statmp27 ; statmp427 = (ats_sum_ptr_type)0 ; statmp428 = (ats_sum_ptr_type)0 ; statmp429 = (ats_sum_ptr_type)0 ; statmp430 = (ats_sum_ptr_type)0 ; statmp426 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, statmp426, atslab_i2nvresstate_svs, statmp427) ; ats_selptrset_mac(anairiats_rec_26, statmp426, atslab_i2nvresstate_gua, statmp428) ; ats_selptrset_mac(anairiats_rec_26, statmp426, atslab_i2nvresstate_arg, statmp429) ; ats_selptrset_mac(anairiats_rec_26, statmp426, atslab_i2nvresstate_met, statmp430) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_nil = statmp426 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_p2at_set_typ ( ats_ptr_type p2t, ats_ptr_type os2e ) { ((p2at_t)p2t)->atslab_p2at_typ = os2e ; return ; } // end of [atsopt_p2at_set_typ] ats_void_type atsopt_d2exp_set_typ ( ats_ptr_type d2e, ats_ptr_type os2e ) { ((d2exp_t)d2e)->atslab_d2exp_typ = os2e ; return ; } // end of [atsopt_d2exp_set_typ] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hiexp_dats.c0000664000175000017500000037541312223166160021251 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_hilab_loc ; ats_ptr_type atslab_hilab_node ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_himat_loc ; ats_ptr_type atslab_himat_exp ; ats_ptr_type atslab_himat_pat ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_hiclau_loc ; ats_ptr_type atslab_hiclau_pat ; ats_ptr_type atslab_hiclau_gua ; ats_ptr_type atslab_hiclau_exp ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_hidec_loc ; ats_ptr_type atslab_hidec_node ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_hifundec_loc ; ats_ptr_type atslab_hifundec_var ; ats_ptr_type atslab_hifundec_def ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_hivaldec_loc ; ats_ptr_type atslab_hivaldec_pat ; ats_ptr_type atslab_hivaldec_def ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_hivardec_loc ; ats_int_type atslab_hivardec_knd ; ats_ptr_type atslab_hivardec_ptr ; ats_ptr_type atslab_hivardec_ini ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_hiimpdec_loc ; ats_ptr_type atslab_hiimpdec_cst ; ats_int_type atslab_hiimpdec_tmp ; ats_ptr_type atslab_hiimpdec_decarg ; ats_ptr_type atslab_hiimpdec_tmparg ; ats_ptr_type atslab_hiimpdec_def ; ats_ptr_type atslab_hiimpdec_cstset ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_hiimpdec_prf_loc ; ats_ptr_type atslab_hiimpdec_prf_cst ; ats_ptr_type atslab_hiimpdec_prf_cstset ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_vartyp_var ; ats_ptr_type atslab_vartyp_typ ; } anairiats_rec_26 ; /* external typedefs */ typedef anairiats_rec_7 *hipat_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITcltype_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITs2var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyarr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrectemp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrecsin_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysum_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysumtemp_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITunion_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrinit_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrpsz_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_ptr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcaseof_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcastfn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEdynload_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEextval_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloatsp_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfreeat_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEif_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEintsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_delay_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_ldelay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElet_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloop_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloopexn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_ptr_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_var_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEraise_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErefarg_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsif_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsizeof_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtrywith_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlist_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDsaspdec_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdcstdec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdatdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDexndec_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextval_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextern_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDfundecs_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_par_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_rec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvardecs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_prf_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlocal_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDstaload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdynload_17) ; /* external dynamic constant declarations */ ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stringlst_concat) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__vartyp_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_char) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ptr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ref) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_double) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_float) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_proof) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_string) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_ptr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg) ; /* internal function declarations */ static ats_ptr_type hityp_namstr_get_5 (ats_ptr_type arg0) ; static ats_ptr_type _vartyp_make_104 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp2) ; ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp5) ; ATSstatic (ats_ptr_type, statmp6) ; ATSstatic (ats_ptr_type, statmp7) ; ATSstatic (ats_ptr_type, statmp8) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp10) ; ATSstatic (ats_ptr_type, statmp11) ; ATSstatic (ats_ptr_type, statmp12) ; ATSstatic (ats_ptr_type, statmp13) ; ATSstatic (ats_ptr_type, statmp14) ; ATSstatic (ats_ptr_type, statmp15) ; ATSstatic (ats_ptr_type, statmp16) ; ATSstatic (ats_ptr_type, statmp17) ; ATSstatic (ats_ptr_type, statmp18) ; ATSstatic (ats_ptr_type, statmp19) ; ATSstatic (ats_ptr_type, statmp20) ; ATSstatic (ats_ptr_type, statmp21) ; ATSstatic (ats_ptr_type, statmp76) ; ATSstatic (ats_ptr_type, statmp77) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 4304(line=118, offs=14) -- 4391(line=121, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_cltype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_cltype: tmp23 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp23, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, tmp23, atslab_1, ATSstrcst("ats_clo_type")) ; tmp24 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp24)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp24, atslab_0, arg0) ; tmp22 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp22, atslab_hityp_name, tmp23) ; ats_selptrset_mac(anairiats_rec_1, tmp22, atslab_hityp_node, tmp24) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_cltype] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 4464(line=127, offs=3) -- 4562(line=130, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype: tmp26 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp26, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, tmp26, atslab_1, arg0) ; tmp27 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp27)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp27, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp27, atslab_1, arg1) ; tmp25 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp25, atslab_hityp_name, tmp26) ; ats_selptrset_mac(anairiats_rec_1, tmp25, atslab_hityp_node, tmp27) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 4616(line=133, offs=18) -- 4654(line=133, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil: tmp29 = (ats_sum_ptr_type)0 ; tmp28 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype (arg0, tmp29) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 4697(line=138, offs=11) -- 4800(line=140, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun: tmp31 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp31)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp31, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp31, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp31, atslab_2, arg2) ; tmp30 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp30, atslab_hityp_name, statmp14) ; ats_selptrset_mac(anairiats_rec_1, tmp30, atslab_hityp_node, tmp31) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 4847(line=143, offs=14) -- 5037(line=150, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg: tmp34 = atspre_gt_int_int (arg0, 0) ; if (tmp34) { tmp33 = statmp15 ; } else { tmp33 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_hityp_name) ; } /* end of [if] */ tmp35 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp35)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp35, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_5, tmp35, atslab_1, arg1) ; tmp32 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp32, atslab_hityp_name, tmp33) ; ats_selptrset_mac(anairiats_rec_1, tmp32, atslab_hityp_node, tmp35) ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 5088(line=154, offs=4) -- 5224(line=159, offs=4) */ ATSstaticdec() ats_ptr_type hityp_namstr_get_5 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_bool_type, tmp40) ; __ats_lab_hityp_namstr_get_5: tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_hityp_name) ; tmp38 = ats_caselptrlab_mac(anairiats_sum_0, tmp37, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_0, tmp37, atslab_1) ; tmp40 = atspre_gt_int_int (tmp38, 0) ; if (tmp40) { tmp36 = ATSstrcst("ats_ptr_type") ; } else { tmp36 = tmp39 ; } /* end of [if] */ return (tmp36) ; } /* end of [hityp_namstr_get_5] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 5279(line=162, offs=3) -- 5539(line=169, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyarr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyarr: tmp42 = hityp_namstr_get_5 (arg0) ; tmp44 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp44, atslab_0, ATSstrcst("[")) ; tmp45 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp44), atslab_1) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp46, atslab_0, tmp42) ; ats_ptrget_mac(ats_ptr_type, tmp45) = tmp46 ; tmp45 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp46), atslab_1) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp46, atslab_0, ATSstrcst("]")) ; ats_ptrget_mac(ats_ptr_type, tmp45) = tmp46 ; tmp45 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp46), atslab_1) ; tmp46 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp45) = tmp46 ; tmp43 = atspre_stringlst_concat (tmp44) ; tmp47 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp47, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, tmp47, atslab_1, ats_castfn_mac(ats_ptr_type, tmp43)) ; tmp48 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp48)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp48, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp48, atslab_1, arg1) ; tmp41 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp41, atslab_hityp_name, tmp47) ; ats_selptrset_mac(anairiats_rec_1, tmp41, atslab_hityp_node, tmp48) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 5608(line=174, offs=13) -- 5712(line=176, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec: tmp50 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp50, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp50, atslab_1, arg1) ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp51)->tag = 6 ; ats_selptrset_mac(anairiats_sum_5, tmp51, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_5, tmp51, atslab_1, arg2) ; tmp49 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp49, atslab_hityp_name, tmp50) ; ats_selptrset_mac(anairiats_rec_1, tmp49, atslab_hityp_node, tmp51) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 5767(line=179, offs=17) -- 5962(line=185, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp: tmp54 = atspre_gt_int_int (arg0, 0) ; if (tmp54) { tmp53 = statmp18 ; } else { tmp53 = statmp19 ; } /* end of [if] */ tmp55 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp55)->tag = 7 ; ats_selptrset_mac(anairiats_sum_5, tmp55, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_5, tmp55, atslab_1, arg1) ; tmp52 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp52, atslab_hityp_name, tmp53) ; ats_selptrset_mac(anairiats_rec_1, tmp52, atslab_hityp_node, tmp55) ; return (tmp52) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6020(line=188, offs=16) -- 6090(line=190, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin: tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_hityp_name) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp58)->tag = 8 ; ats_selptrset_mac(anairiats_sum_2, tmp58, atslab_0, arg0) ; tmp56 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp56, atslab_hityp_name, tmp57) ; ats_selptrset_mac(anairiats_rec_1, tmp56, atslab_hityp_node, tmp58) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6157(line=195, offs=13) -- 6253(line=197, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum: tmp60 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp60, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_0, tmp60, atslab_1, arg0) ; tmp61 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp61)->tag = 9 ; ats_selptrset_mac(anairiats_sum_3, tmp61, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp61, atslab_1, arg2) ; tmp59 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp59, atslab_hityp_name, tmp60) ; ats_selptrset_mac(anairiats_rec_1, tmp59, atslab_hityp_node, tmp61) ; return (tmp59) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6305(line=200, offs=17) -- 6396(line=202, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp: tmp63 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp63)->tag = 10 ; ats_selptrset_mac(anairiats_sum_3, tmp63, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp63, atslab_1, arg1) ; tmp62 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp62, atslab_hityp_name, statmp20) ; ats_selptrset_mac(anairiats_rec_1, tmp62, atslab_hityp_node, tmp63) ; return (tmp62) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6469(line=207, offs=13) -- 6548(line=209, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_union: tmp65 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp65, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, tmp65, atslab_1, arg0) ; tmp66 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp66)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp66, atslab_0, arg1) ; tmp64 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp64, atslab_hityp_name, tmp65) ; ats_selptrset_mac(anairiats_rec_1, tmp64, atslab_hityp_node, tmp66) ; return (tmp64) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_union] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6599(line=212, offs=16) -- 6767(line=218, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_varetize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_varetize: tmp68 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_hityp_name) ; tmp69 = ats_caselptrlab_mac(anairiats_sum_0, tmp68, atslab_1) ; tmp70 = atspre_eq_string_string (tmp69, ATSstrcst("ats_var_type")) ; if (tmp70) { tmp71 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_hityp_node) ; tmp67 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp67, atslab_hityp_name, statmp17) ; ats_selptrset_mac(anairiats_rec_1, tmp67, atslab_hityp_node, tmp71) ; } else { tmp67 = arg0 ; } /* end of [if] */ return (tmp67) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_varetize] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 6839(line=223, offs=13) -- 7053(line=229, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_bool_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var: tmp73 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed (arg0) ; if (tmp73) { tmp74 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp74)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp74, atslab_0, arg0) ; tmp72 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp72, atslab_hityp_name, statmp14) ; ats_selptrset_mac(anairiats_rec_1, tmp72, atslab_hityp_node, tmp74) ; } else { tmp75 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp75)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp75, atslab_0, arg0) ; tmp72 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp72, atslab_hityp_name, statmp16) ; ats_selptrset_mac(anairiats_rec_1, tmp72, atslab_hityp_node, tmp75) ; } /* end of [if] */ return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 7239(line=238, offs=3) -- 7371(line=243, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_ann (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_ann: tmp79 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp79)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp79, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp79, atslab_1, arg3) ; tmp80 = (ats_sum_ptr_type)0 ; tmp78 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp78, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp78, atslab_hipat_node, tmp79) ; ats_selptrset_mac(anairiats_rec_7, tmp78, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp78, atslab_hipat_asvar, tmp80) ; return (tmp78) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 7415(line=246, offs=11) -- 7521(line=251, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_any (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_any: tmp82 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; tmp83 = (ats_sum_ptr_type)0 ; tmp81 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp81, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp81, atslab_hipat_node, tmp82) ; ats_selptrset_mac(anairiats_rec_7, tmp81, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp81, atslab_hipat_asvar, tmp83) ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_any] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 7566(line=254, offs=3) -- 7705(line=259, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_as (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_as: tmp85 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp85)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp85, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp85, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp85, atslab_2, arg4) ; tmp86 = (ats_sum_ptr_type)0 ; tmp84 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp84, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp84, atslab_hipat_node, tmp85) ; ats_selptrset_mac(anairiats_rec_7, tmp84, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp84, atslab_hipat_asvar, tmp86) ; return (tmp84) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_as] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 7749(line=262, offs=12) -- 7858(line=267, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool: tmp88 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp88)->tag = 3 ; ats_selptrset_mac(anairiats_sum_9, tmp88, atslab_0, arg2) ; tmp89 = (ats_sum_ptr_type)0 ; tmp87 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp87, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp87, atslab_hipat_node, tmp88) ; ats_selptrset_mac(anairiats_rec_7, tmp87, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp87, atslab_hipat_asvar, tmp89) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 7904(line=270, offs=12) -- 8013(line=275, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_char (ats_ptr_type arg0, ats_ptr_type arg1, ats_char_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_char: tmp91 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp91)->tag = 4 ; ats_selptrset_mac(anairiats_sum_10, tmp91, atslab_0, arg2) ; tmp92 = (ats_sum_ptr_type)0 ; tmp90 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp90, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp90, atslab_hipat_node, tmp91) ; ats_selptrset_mac(anairiats_rec_7, tmp90, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp90, atslab_hipat_asvar, tmp92) ; return (tmp90) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_char] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8060(line=278, offs=3) -- 8222(line=283, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con: tmp94 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp94)->tag = 5 ; ats_selptrset_mac(anairiats_sum_11, tmp94, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_11, tmp94, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_11, tmp94, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_11, tmp94, atslab_3, arg5) ; tmp95 = (ats_sum_ptr_type)0 ; tmp93 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp93, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp93, atslab_hipat_node, tmp94) ; ats_selptrset_mac(anairiats_rec_7, tmp93, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp93, atslab_hipat_asvar, tmp95) ; return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8272(line=286, offs=3) -- 8408(line=291, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con_any (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con_any: tmp97 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp97)->tag = 6 ; ats_selptrset_mac(anairiats_sum_5, tmp97, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp97, atslab_1, arg3) ; tmp98 = (ats_sum_ptr_type)0 ; tmp96 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp96, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp96, atslab_hipat_node, tmp97) ; ats_selptrset_mac(anairiats_rec_7, tmp96, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp96, atslab_hipat_asvar, tmp98) ; return (tmp96) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con_any] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8458(line=293, offs=23) -- 8566(line=298, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_empty (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_empty: tmp100 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; tmp101 = (ats_sum_ptr_type)0 ; tmp99 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp99, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp99, atslab_hipat_node, tmp100) ; ats_selptrset_mac(anairiats_rec_7, tmp99, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp99, atslab_hipat_asvar, tmp101) ; return (tmp99) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8612(line=301, offs=11) -- 8736(line=306, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_int: tmp103 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp103)->tag = 9 ; ats_selptrset_mac(anairiats_sum_3, tmp103, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp103, atslab_1, arg3) ; tmp104 = (ats_sum_ptr_type)0 ; tmp102 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp102, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp102, atslab_hipat_node, tmp103) ; ats_selptrset_mac(anairiats_rec_7, tmp102, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp102, atslab_hipat_asvar, tmp104) ; return (tmp102) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_int] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8782(line=309, offs=3) -- 8924(line=314, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_lst: tmp106 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp106)->tag = 10 ; ats_selptrset_mac(anairiats_sum_3, tmp106, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp106, atslab_1, arg3) ; tmp107 = (ats_sum_ptr_type)0 ; tmp105 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp105, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp105, atslab_hipat_node, tmp106) ; ats_selptrset_mac(anairiats_rec_7, tmp105, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp105, atslab_hipat_asvar, tmp107) ; return (tmp105) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 8970(line=317, offs=3) -- 9116(line=322, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_rec (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_rec: tmp109 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp109)->tag = 11 ; ats_selptrset_mac(anairiats_sum_8, tmp109, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp109, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp109, atslab_2, arg4) ; tmp110 = (ats_sum_ptr_type)0 ; tmp108 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp108, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp108, atslab_hipat_node, tmp109) ; ats_selptrset_mac(anairiats_rec_7, tmp108, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp108, atslab_hipat_asvar, tmp110) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 9163(line=325, offs=14) -- 9278(line=330, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_string: tmp112 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp112)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp112, atslab_0, arg2) ; tmp113 = (ats_sum_ptr_type)0 ; tmp111 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp111, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp111, atslab_hipat_node, tmp112) ; ats_selptrset_mac(anairiats_rec_7, tmp111, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp111, atslab_hipat_asvar, tmp113) ; return (tmp111) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_string] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 9325(line=333, offs=11) -- 9455(line=338, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var: tmp115 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp115)->tag = 13 ; ats_selptrset_mac(anairiats_sum_5, tmp115, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp115, atslab_1, arg3) ; tmp116 = (ats_sum_ptr_type)0 ; tmp114 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp114, atslab_hipat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp114, atslab_hipat_node, tmp115) ; ats_selptrset_mac(anairiats_rec_7, tmp114, atslab_hipat_typ, arg1) ; ats_selptrset_mac(anairiats_rec_7, tmp114, atslab_hipat_asvar, tmp116) ; return (tmp114) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 9522(line=343, offs=3) -- 9659(line=347, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_app (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_app: tmp118 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp118)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp118, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp118, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp118, atslab_2, arg4) ; tmp117 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp117, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp117, atslab_hiexp_node, tmp118) ; ats_selptrset_mac(anairiats_rec_12, tmp117, atslab_hiexp_typ, arg1) ; return (tmp117) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_app] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 9709(line=350, offs=3) -- 9852(line=354, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrinit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrinit: tmp120 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp120)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp120, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp120, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp120, atslab_2, arg4) ; tmp119 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp119, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp119, atslab_hiexp_node, tmp120) ; ats_selptrset_mac(anairiats_rec_12, tmp119, atslab_hiexp_typ, arg1) ; return (tmp119) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrinit] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 9905(line=357, offs=3) -- 10027(line=361, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrpsz (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrpsz: tmp122 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp122)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp122, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp122, atslab_1, arg3) ; tmp121 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp121, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp121, atslab_hiexp_node, tmp122) ; ats_selptrset_mac(anairiats_rec_12, tmp121, atslab_hiexp_typ, arg1) ; return (tmp121) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrpsz] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10082(line=364, offs=3) -- 10209(line=368, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_ptr: tmp124 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp124)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp124, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp124, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp124, atslab_2, arg4) ; tmp123 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp123, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp123, atslab_hiexp_node, tmp124) ; ats_selptrset_mac(anairiats_rec_12, tmp123, atslab_hiexp_typ, arg1) ; return (tmp123) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10267(line=371, offs=3) -- 10394(line=375, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var: tmp126 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp126)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp126, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp126, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp126, atslab_2, arg4) ; tmp125 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp125, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp125, atslab_hiexp_node, tmp126) ; ats_selptrset_mac(anairiats_rec_12, tmp125, atslab_hiexp_typ, arg1) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10445(line=378, offs=12) -- 10521(line=380, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool: tmp128 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp128)->tag = 5 ; ats_selptrset_mac(anairiats_sum_9, tmp128, atslab_0, arg2) ; tmp127 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp127, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp127, atslab_hiexp_node, tmp128) ; ats_selptrset_mac(anairiats_rec_12, tmp127, atslab_hiexp_typ, arg1) ; return (tmp127) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10571(line=383, offs=3) -- 10683(line=387, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof: tmp130 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp130)->tag = 6 ; ats_selptrset_mac(anairiats_sum_8, tmp130, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp130, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp130, atslab_2, arg4) ; tmp129 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp129, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp129, atslab_hiexp_node, tmp130) ; ats_selptrset_mac(anairiats_rec_12, tmp129, atslab_hiexp_typ, arg1) ; return (tmp129) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10735(line=390, offs=3) -- 10831(line=394, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_castfn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_castfn: tmp132 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp132)->tag = 7 ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_1, arg3) ; tmp131 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp131, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp131, atslab_hiexp_node, tmp132) ; ats_selptrset_mac(anairiats_rec_12, tmp131, atslab_hiexp_typ, arg1) ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 10879(line=397, offs=12) -- 10955(line=399, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_char (ats_ptr_type arg0, ats_ptr_type arg1, ats_char_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_char: tmp134 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp134)->tag = 8 ; ats_selptrset_mac(anairiats_sum_10, tmp134, atslab_0, arg2) ; tmp133 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp133, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp133, atslab_hiexp_node, tmp134) ; ats_selptrset_mac(anairiats_rec_12, tmp133, atslab_hiexp_typ, arg1) ; return (tmp133) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11002(line=402, offs=3) -- 11123(line=406, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_con: tmp136 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp136)->tag = 9 ; ats_selptrset_mac(anairiats_sum_4, tmp136, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp136, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp136, atslab_2, arg4) ; tmp135 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp135, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp135, atslab_hiexp_node, tmp136) ; ats_selptrset_mac(anairiats_rec_12, tmp135, atslab_hiexp_typ, arg1) ; return (tmp135) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_con] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11167(line=409, offs=11) -- 11246(line=411, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cst: tmp138 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp138)->tag = 10 ; ats_selptrset_mac(anairiats_sum_2, tmp138, atslab_0, arg2) ; tmp137 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp137, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp137, atslab_hiexp_node, tmp138) ; ats_selptrset_mac(anairiats_rec_12, tmp137, atslab_hiexp_typ, arg1) ; return (tmp137) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11292(line=414, offs=13) -- 11373(line=416, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cstsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cstsp: tmp140 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp140)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp140, atslab_0, arg2) ; tmp139 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp139, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp139, atslab_hiexp_node, tmp140) ; ats_selptrset_mac(anairiats_rec_12, tmp139, atslab_hiexp_typ, arg1) ; return (tmp139) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11423(line=419, offs=15) -- 11506(line=421, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_dynload (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_dynload: tmp142 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp142)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp142, atslab_0, arg2) ; tmp141 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp141, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp141, atslab_hiexp_node, tmp142) ; ats_selptrset_mac(anairiats_rec_12, tmp141, atslab_hiexp_typ, arg1) ; return (tmp141) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11556(line=424, offs=13) -- 11631(line=426, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty: tmp144 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; tmp143 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp143, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp143, atslab_hiexp_node, tmp144) ; ats_selptrset_mac(anairiats_rec_12, tmp143, atslab_hiexp_typ, arg1) ; return (tmp143) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11680(line=429, offs=14) -- 11764(line=431, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_extval: tmp146 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp146)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp146, atslab_0, arg2) ; tmp145 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp145, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp145, atslab_hiexp_node, tmp146) ; ats_selptrset_mac(anairiats_rec_12, tmp145, atslab_hiexp_typ, arg1) ; return (tmp145) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11811(line=434, offs=11) -- 11912(line=436, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_fix (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_fix: tmp148 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp148)->tag = 15 ; ats_selptrset_mac(anairiats_sum_8, tmp148, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp148, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp148, atslab_2, arg4) ; tmp147 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp147, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp147, atslab_hiexp_node, tmp148) ; ats_selptrset_mac(anairiats_rec_12, tmp147, atslab_hiexp_typ, arg1) ; return (tmp147) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 11958(line=439, offs=13) -- 12039(line=441, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_float (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_float: tmp150 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp150)->tag = 16 ; ats_selptrset_mac(anairiats_sum_2, tmp150, atslab_0, arg2) ; tmp149 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp149, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp149, atslab_hiexp_node, tmp150) ; ats_selptrset_mac(anairiats_rec_12, tmp149, atslab_hiexp_typ, arg1) ; return (tmp149) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12089(line=444, offs=15) -- 12172(line=446, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_floatsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_floatsp: tmp152 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp152)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp152, atslab_0, arg2) ; tmp151 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp151, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp151, atslab_hiexp_node, tmp152) ; ats_selptrset_mac(anairiats_rec_12, tmp151, atslab_hiexp_typ, arg1) ; return (tmp151) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12223(line=449, offs=14) -- 12305(line=451, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_freeat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_freeat: tmp154 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp154)->tag = 18 ; ats_selptrset_mac(anairiats_sum_2, tmp154, atslab_0, arg2) ; tmp153 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp153, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp153, atslab_hiexp_node, tmp154) ; ats_selptrset_mac(anairiats_rec_12, tmp153, atslab_hiexp_typ, arg1) ; return (tmp153) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_freeat] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12353(line=454, offs=3) -- 12467(line=458, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if: tmp156 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp156)->tag = 19 ; ats_selptrset_mac(anairiats_sum_4, tmp156, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp156, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_4, tmp156, atslab_2, arg4) ; tmp155 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp155, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp155, atslab_hiexp_node, tmp156) ; ats_selptrset_mac(anairiats_rec_12, tmp155, atslab_hiexp_typ, arg1) ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12510(line=461, offs=11) -- 12601(line=463, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_int (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_int: tmp158 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp158)->tag = 20 ; ats_selptrset_mac(anairiats_sum_3, tmp158, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp158, atslab_1, arg3) ; tmp157 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp157, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp157, atslab_hiexp_node, tmp158) ; ats_selptrset_mac(anairiats_rec_12, tmp157, atslab_hiexp_typ, arg1) ; return (tmp157) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12647(line=466, offs=13) -- 12740(line=468, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_intsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_intsp: tmp160 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp160)->tag = 21 ; ats_selptrset_mac(anairiats_sum_3, tmp160, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp160, atslab_1, arg3) ; tmp159 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp159, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp159, atslab_hiexp_node, tmp160) ; ats_selptrset_mac(anairiats_rec_12, tmp159, atslab_hiexp_typ, arg1) ; return (tmp159) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12810(line=472, offs=24) -- 12875(line=473, offs=56) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_lam (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_lam: tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_hiexp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp162)->tag != 22) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp161 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp161 = ats_false_bool ; break ; } while (0) ; return (tmp161) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 12926(line=477, offs=3) -- 13039(line=481, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lam (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lam: tmp164 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp164)->tag = 22 ; ats_selptrset_mac(anairiats_sum_3, tmp164, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp164, atslab_1, arg3) ; tmp163 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp163, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp163, atslab_hiexp_node, tmp164) ; ats_selptrset_mac(anairiats_rec_12, tmp163, atslab_hiexp_typ, arg1) ; return (tmp163) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 13089(line=484, offs=3) -- 13206(line=488, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_laminit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_laminit: tmp166 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp166)->tag = 23 ; ats_selptrset_mac(anairiats_sum_3, tmp166, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp166, atslab_1, arg3) ; tmp165 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp165, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp165, atslab_hiexp_node, tmp166) ; ats_selptrset_mac(anairiats_rec_12, tmp165, atslab_hiexp_typ, arg1) ; return (tmp165) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_laminit] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 13284(line=494, offs=3) -- 13401(line=498, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_delay (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_delay: tmp168 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp168)->tag = 24 ; ats_selptrset_mac(anairiats_sum_2, tmp168, atslab_0, arg2) ; tmp167 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp167, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp167, atslab_hiexp_node, tmp168) ; ats_selptrset_mac(anairiats_rec_12, tmp167, atslab_hiexp_typ, arg1) ; return (tmp167) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 13462(line=502, offs=3) -- 13602(line=506, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_ldelay (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_ldelay: tmp170 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp170)->tag = 25 ; ats_selptrset_mac(anairiats_sum_3, tmp170, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp170, atslab_1, arg3) ; tmp169 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp169, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp169, atslab_hiexp_node, tmp170) ; ats_selptrset_mac(anairiats_rec_12, tmp169, atslab_hiexp_typ, arg1) ; return (tmp169) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_ldelay] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 13663(line=510, offs=3) -- 13793(line=514, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_force (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_force: tmp172 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp172)->tag = 26 ; ats_selptrset_mac(anairiats_sum_5, tmp172, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp172, atslab_1, arg3) ; tmp171 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp171, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp171, atslab_hiexp_node, tmp172) ; ats_selptrset_mac(anairiats_rec_12, tmp171, atslab_hiexp_typ, arg1) ; return (tmp171) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_force] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 13865(line=519, offs=11) -- 13958(line=521, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let: tmp174 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp174)->tag = 27 ; ats_selptrset_mac(anairiats_sum_3, tmp174, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp174, atslab_1, arg3) ; tmp173 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp173, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp173, atslab_hiexp_node, tmp174) ; ats_selptrset_mac(anairiats_rec_12, tmp173, atslab_hiexp_typ, arg1) ; return (tmp173) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14026(line=526, offs=3) -- 14156(line=530, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loop (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loop: tmp176 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp176)->tag = 28 ; ats_selptrset_mac(anairiats_sum_13, tmp176, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_13, tmp176, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_13, tmp176, atslab_2, arg4) ; ats_selptrset_mac(anairiats_sum_13, tmp176, atslab_3, arg5) ; tmp175 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp175, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp175, atslab_hiexp_node, tmp176) ; ats_selptrset_mac(anairiats_rec_12, tmp175, atslab_hiexp_typ, arg1) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loop] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14205(line=533, offs=15) -- 14284(line=535, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loopexn (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loopexn: tmp178 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp178)->tag = 29 ; ats_selptrset_mac(anairiats_sum_14, tmp178, atslab_0, arg2) ; tmp177 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp177, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp177, atslab_hiexp_node, tmp178) ; ats_selptrset_mac(anairiats_rec_12, tmp177, atslab_hiexp_typ, arg1) ; return (tmp177) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14355(line=540, offs=3) -- 14476(line=544, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lst: tmp180 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp180)->tag = 30 ; ats_selptrset_mac(anairiats_sum_8, tmp180, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp180, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp180, atslab_2, arg4) ; tmp179 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp179, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp179, atslab_hiexp_node, tmp180) ; ats_selptrset_mac(anairiats_rec_12, tmp179, atslab_hiexp_typ, arg1) ; return (tmp179) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14528(line=548, offs=3) -- 14637(line=552, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_ptr: tmp182 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp182)->tag = 31 ; ats_selptrset_mac(anairiats_sum_3, tmp182, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp182, atslab_1, arg3) ; tmp181 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp181, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp181, atslab_hiexp_node, tmp182) ; ats_selptrset_mac(anairiats_rec_12, tmp181, atslab_hiexp_typ, arg1) ; return (tmp181) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14695(line=556, offs=3) -- 14804(line=560, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_var: tmp184 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp184)->tag = 32 ; ats_selptrset_mac(anairiats_sum_3, tmp184, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp184, atslab_1, arg3) ; tmp183 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp183, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp183, atslab_hiexp_node, tmp184) ; ats_selptrset_mac(anairiats_rec_12, tmp183, atslab_hiexp_typ, arg1) ; return (tmp183) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14856(line=563, offs=13) -- 14937(line=565, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_raise (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_raise: tmp186 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp186)->tag = 33 ; ats_selptrset_mac(anairiats_sum_2, tmp186, atslab_0, arg2) ; tmp185 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp185, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp185, atslab_hiexp_node, tmp186) ; ats_selptrset_mac(anairiats_rec_12, tmp185, atslab_hiexp_typ, arg1) ; return (tmp185) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 14985(line=568, offs=3) -- 15100(line=572, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec: tmp188 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp188)->tag = 34 ; ats_selptrset_mac(anairiats_sum_8, tmp188, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp188, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_8, tmp188, atslab_2, arg4) ; tmp187 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp187, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp187, atslab_hiexp_node, tmp188) ; ats_selptrset_mac(anairiats_rec_12, tmp187, atslab_hiexp_typ, arg1) ; return (tmp187) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15149(line=575, offs=3) -- 15269(line=579, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg: tmp190 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp190)->tag = 35 ; ats_selptrset_mac(anairiats_sum_15, tmp190, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp190, atslab_1, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp190, atslab_2, arg4) ; tmp189 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp189, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp189, atslab_hiexp_node, tmp190) ; ats_selptrset_mac(anairiats_rec_12, tmp189, atslab_hiexp_typ, arg1) ; return (tmp189) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15339(line=584, offs=3) -- 15434(line=588, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel: tmp192 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp192)->tag = 36 ; ats_selptrset_mac(anairiats_sum_3, tmp192, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp192, atslab_1, arg3) ; tmp191 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp191, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp191, atslab_hiexp_node, tmp192) ; ats_selptrset_mac(anairiats_rec_12, tmp191, atslab_hiexp_typ, arg1) ; return (tmp191) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15484(line=591, offs=3) -- 15591(line=595, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_ptr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_ptr: tmp194 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp194)->tag = 37 ; ats_selptrset_mac(anairiats_sum_3, tmp194, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp194, atslab_1, arg3) ; tmp193 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp193, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp193, atslab_hiexp_node, tmp194) ; ats_selptrset_mac(anairiats_rec_12, tmp193, atslab_hiexp_typ, arg1) ; return (tmp193) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15645(line=598, offs=3) -- 15752(line=602, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_var: tmp196 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp196)->tag = 38 ; ats_selptrset_mac(anairiats_sum_3, tmp196, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp196, atslab_1, arg3) ; tmp195 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp195, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp195, atslab_hiexp_node, tmp196) ; ats_selptrset_mac(anairiats_rec_12, tmp195, atslab_hiexp_typ, arg1) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15821(line=607, offs=11) -- 15902(line=609, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq: tmp198 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp198)->tag = 39 ; ats_selptrset_mac(anairiats_sum_2, tmp198, atslab_0, arg2) ; tmp197 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp197, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp197, atslab_hiexp_node, tmp198) ; ats_selptrset_mac(anairiats_rec_12, tmp197, atslab_hiexp_typ, arg1) ; return (tmp197) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 15946(line=612, offs=11) -- 16057(line=614, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sif (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sif: tmp200 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp200)->tag = 40 ; ats_selptrset_mac(anairiats_sum_3, tmp200, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp200, atslab_1, arg3) ; tmp199 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp199, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp199, atslab_hiexp_node, tmp200) ; ats_selptrset_mac(anairiats_rec_12, tmp199, atslab_hiexp_typ, arg1) ; return (tmp199) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sif] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16104(line=617, offs=14) -- 16194(line=619, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sizeof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sizeof: tmp202 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp202)->tag = 41 ; ats_selptrset_mac(anairiats_sum_2, tmp202, atslab_0, arg2) ; tmp201 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp201, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp201, atslab_hiexp_node, tmp202) ; ats_selptrset_mac(anairiats_rec_12, tmp201, atslab_hiexp_typ, arg1) ; return (tmp201) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sizeof] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16244(line=622, offs=14) -- 16338(line=624, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_string: tmp204 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp204)->tag = 42 ; ats_selptrset_mac(anairiats_sum_16, tmp204, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp204, atslab_1, arg3) ; tmp203 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp203, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp203, atslab_hiexp_node, tmp204) ; ats_selptrset_mac(anairiats_rec_12, tmp203, atslab_hiexp_typ, arg1) ; return (tmp203) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16411(line=629, offs=3) -- 16519(line=633, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpcst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpcst: tmp206 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp206)->tag = 43 ; ats_selptrset_mac(anairiats_sum_3, tmp206, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp206, atslab_1, arg3) ; tmp205 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp205, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp205, atslab_hiexp_node, tmp206) ; ats_selptrset_mac(anairiats_rec_12, tmp205, atslab_hiexp_typ, arg1) ; return (tmp205) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpcst] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16571(line=636, offs=3) -- 16679(line=640, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpvar (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpvar: tmp208 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp208)->tag = 44 ; ats_selptrset_mac(anairiats_sum_3, tmp208, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp208, atslab_1, arg3) ; tmp207 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp207, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp207, atslab_hiexp_node, tmp208) ; ats_selptrset_mac(anairiats_rec_12, tmp207, atslab_hiexp_typ, arg1) ; return (tmp207) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16747(line=645, offs=11) -- 16820(line=647, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_top (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_top: tmp210 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45) ; tmp209 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp209, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp209, atslab_hiexp_node, tmp210) ; ats_selptrset_mac(anairiats_rec_12, tmp209, atslab_hiexp_typ, arg1) ; return (tmp209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_top] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 16870(line=650, offs=3) -- 16971(line=654, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_trywith (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_trywith: tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 46 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, arg3) ; tmp211 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp211, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp211, atslab_hiexp_node, tmp212) ; ats_selptrset_mac(anairiats_rec_12, tmp211, atslab_hiexp_typ, arg1) ; return (tmp211) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_trywith] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17019(line=657, offs=11) -- 17098(line=659, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var: tmp214 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp214)->tag = 47 ; ats_selptrset_mac(anairiats_sum_2, tmp214, atslab_0, arg2) ; tmp213 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp213, atslab_hiexp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp213, atslab_hiexp_node, tmp214) ; ats_selptrset_mac(anairiats_rec_12, tmp213, atslab_hiexp_typ, arg1) ; return (tmp213) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17163(line=664, offs=11) -- 17237(line=666, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_lab (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_lab: tmp216 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp216)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp216, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp216, atslab_1, arg2) ; tmp215 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp215, atslab_hilab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_17, tmp215, atslab_hilab_node, tmp216) ; return (tmp215) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17281(line=669, offs=11) -- 17371(line=671, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_ind (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_ind: tmp218 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp218)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp218, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp218, atslab_1, arg2) ; tmp217 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp217, atslab_hilab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_17, tmp217, atslab_hilab_node, tmp218) ; return (tmp217) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17437(line=676, offs=12) -- 17510(line=678, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__himat_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__himat_make: tmp219 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp219, atslab_himat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp219, atslab_himat_exp, arg1) ; ats_selptrset_mac(anairiats_rec_18, tmp219, atslab_himat_pat, arg2) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__himat_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17559(line=682, offs=3) -- 17662(line=687, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiclau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiclau_make: tmp220 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp220, atslab_hiclau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp220, atslab_hiclau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_19, tmp220, atslab_hiclau_gua, arg2) ; ats_selptrset_mac(anairiats_rec_19, tmp220, atslab_hiclau_exp, arg3) ; return (tmp220) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiclau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17730(line=692, offs=12) -- 17791(line=694, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_list: tmp222 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp222)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp222, atslab_0, arg1) ; tmp221 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp221, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp221, atslab_hidec_node, tmp222) ; return (tmp221) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_list] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17840(line=697, offs=15) -- 17910(line=699, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_saspdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_saspdec: tmp224 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp224)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp224, atslab_0, arg1) ; tmp223 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp223, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp223, atslab_hidec_node, tmp224) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_saspdec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 17962(line=702, offs=15) -- 18038(line=704, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dcstdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dcstdec: tmp226 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp226)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp226, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp226, atslab_1, arg2) ; tmp225 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp225, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp225, atslab_hidec_node, tmp226) ; return (tmp225) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dcstdec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18089(line=707, offs=14) -- 18164(line=709, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_datdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_datdec: tmp228 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp228)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp228, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp228, atslab_1, arg2) ; tmp227 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp227, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp227, atslab_hidec_node, tmp228) ; return (tmp227) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_datdec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18214(line=712, offs=14) -- 18279(line=714, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_exndec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_exndec: tmp230 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp230)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp230, atslab_0, arg1) ; tmp229 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp229, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp229, atslab_hidec_node, tmp230) ; return (tmp229) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_exndec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18329(line=717, offs=14) -- 18414(line=719, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extern (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extern: tmp232 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp232)->tag = 7 ; ats_selptrset_mac(anairiats_sum_5, tmp232, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp232, atslab_1, arg2) ; tmp231 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp231, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp231, atslab_hidec_node, tmp232) ; return (tmp231) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extern] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18464(line=722, offs=14) -- 18547(line=724, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extype (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extype: tmp234 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp234)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp234, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp234, atslab_1, arg2) ; tmp233 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp233, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp233, atslab_hidec_node, tmp234) ; return (tmp233) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18597(line=727, offs=14) -- 18688(line=729, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extval: tmp236 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp236)->tag = 6 ; ats_selptrset_mac(anairiats_sum_3, tmp236, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp236, atslab_1, arg2) ; tmp235 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp235, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp235, atslab_hidec_node, tmp236) ; return (tmp235) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18759(line=734, offs=14) -- 18828(line=736, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec: tmp238 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp238)->tag = 13 ; ats_selptrset_mac(anairiats_sum_2, tmp238, atslab_0, arg1) ; tmp237 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp237, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp237, atslab_hidec_node, tmp238) ; return (tmp237) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 18882(line=739, offs=18) -- 18963(line=741, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec_prf (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec_prf: tmp240 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp240)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp240, atslab_0, arg1) ; tmp239 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp239, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp239, atslab_hidec_node, tmp240) ; return (tmp239) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec_prf] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19039(line=746, offs=15) -- 19123(line=748, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hifundec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp241) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hifundec_make: tmp241 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp241, atslab_hifundec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp241, atslab_hifundec_var, arg1) ; ats_selptrset_mac(anairiats_rec_21, tmp241, atslab_hifundec_def, arg2) ; return (tmp241) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hifundec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19175(line=751, offs=15) -- 19261(line=753, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_fundecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_fundecs: tmp243 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp243)->tag = 8 ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_2, arg3) ; tmp242 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp242, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp242, atslab_hidec_node, tmp243) ; return (tmp242) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_fundecs] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19334(line=758, offs=15) -- 19418(line=760, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivaldec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivaldec_make: tmp244 = ATS_MALLOC(sizeof(anairiats_rec_22)) ; ats_selptrset_mac(anairiats_rec_22, tmp244, atslab_hivaldec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_22, tmp244, atslab_hivaldec_pat, arg1) ; ats_selptrset_mac(anairiats_rec_22, tmp244, atslab_hivaldec_def, arg2) ; return (tmp244) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivaldec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19444(line=763, offs=15) -- 19520(line=765, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs: tmp246 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp246)->tag = 9 ; ats_selptrset_mac(anairiats_sum_3, tmp246, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp246, atslab_1, arg2) ; tmp245 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp245, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp245, atslab_hidec_node, tmp246) ; return (tmp245) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19550(line=768, offs=19) -- 19620(line=770, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_par (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_par: tmp248 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp248)->tag = 10 ; ats_selptrset_mac(anairiats_sum_2, tmp248, atslab_0, arg1) ; tmp247 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp247, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp247, atslab_hidec_node, tmp248) ; return (tmp247) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_par] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19650(line=773, offs=19) -- 19720(line=775, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_rec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_rec: tmp250 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp250)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp250, atslab_0, arg1) ; tmp249 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp249, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp249, atslab_hidec_node, tmp250) ; return (tmp249) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19767(line=780, offs=15) -- 19871(line=782, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivardec_make (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp251) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivardec_make: tmp251 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp251, atslab_hivardec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_23, tmp251, atslab_hivardec_knd, arg1) ; ats_selptrset_mac(anairiats_rec_23, tmp251, atslab_hivardec_ptr, arg2) ; ats_selptrset_mac(anairiats_rec_23, tmp251, atslab_hivardec_ini, arg3) ; return (tmp251) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivardec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 19923(line=785, offs=15) -- 19989(line=787, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_vardecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_vardecs: tmp253 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp253)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp253, atslab_0, arg1) ; tmp252 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp252, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp252, atslab_hidec_node, tmp253) ; return (tmp252) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_vardecs] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 20038(line=792, offs=3) -- 20277(line=799, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_make: tmp254 = ATS_MALLOC(sizeof(anairiats_rec_24)) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_cst, arg1) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_tmp, arg2) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_decarg, arg3) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_tmparg, arg4) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_def, arg5) ; ats_selptrset_mac(anairiats_rec_24, tmp254, atslab_hiimpdec_cstset, arg6) ; return (tmp254) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 20333(line=801, offs=29) -- 20430(line=803, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_prf_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_prf_make: tmp255 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp255, atslab_hiimpdec_prf_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp255, atslab_hiimpdec_prf_cst, arg1) ; ats_selptrset_mac(anairiats_rec_25, tmp255, atslab_hiimpdec_prf_cstset, arg2) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_prf_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 20505(line=808, offs=13) -- 20585(line=810, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_local (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_local: tmp257 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp257)->tag = 15 ; ats_selptrset_mac(anairiats_sum_3, tmp257, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp257, atslab_1, arg2) ; tmp256 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp256, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp256, atslab_hidec_node, tmp257) ; return (tmp256) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 20637(line=814, offs=3) -- 20721(line=816, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_staload (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_staload: tmp259 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp259)->tag = 16 ; ats_selptrset_mac(anairiats_sum_16, tmp259, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp259, atslab_1, arg2) ; tmp258 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp258, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp258, atslab_hidec_node, tmp259) ; return (tmp258) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_staload] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 20773(line=819, offs=15) -- 20837(line=821, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dynload: tmp261 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp261)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp261, atslab_0, arg1) ; tmp260 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp260, atslab_hidec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp260, atslab_hidec_node, tmp261) ; return (tmp260) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21009(line=835, offs=4) -- 21105(line=839, offs=2) */ ATSstaticdec() ats_ptr_type _vartyp_make_104 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; __ats_lab__vartyp_make_104: tmp262 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp262, atslab_vartyp_var, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp262, atslab_vartyp_typ, arg1) ; return (tmp262) ; } /* end of [_vartyp_make_104] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21154(line=842, offs=13) -- 21190(line=842, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp263) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make: tmp263 = _vartyp_make_104 (arg0, arg1) ; return (tmp263) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21217(line=844, offs=26) -- 21239(line=844, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp264) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ: tmp264 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_vartyp_typ) ; return (tmp264) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21265(line=845, offs=26) -- 21287(line=845, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp265) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var: tmp265 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_vartyp_var) ; return (tmp265) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21316(line=848, offs=18) -- 21382(line=849, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__eq_vartyp_vartyp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__eq_vartyp_vartyp: tmp267 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_vartyp_var) ; tmp268 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg1), atslab_vartyp_var) ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var (tmp267, tmp268) ; return (tmp266) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__eq_vartyp_vartyp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp.dats: 21445(line=853, offs=23) -- 21516(line=854, offs=57) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp: tmp270 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_vartyp_var) ; tmp271 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg1), atslab_vartyp_var) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (tmp270, tmp271) ; return (tmp269) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp8, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp10, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp11, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp12, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp13, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp14, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp15, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp16, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp17, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp18, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp19, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp20, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp21, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp76, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp77, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_abs_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs = statmp0 ; statmp1 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_bool_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool = statmp1 ; statmp2 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_char_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_char, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_char = statmp2 ; statmp3 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_clo_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo = statmp3 ; statmp4 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_clo_ptr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ptr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ptr = statmp4 ; statmp5 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_clo_ref_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ref, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ref = statmp5 ; statmp6 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_double_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_double, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_double = statmp6 ; statmp7 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_float_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_float, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_float = statmp7 ; statmp8 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_int_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int = statmp8 ; statmp9 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_proof_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_proof, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_proof = statmp9 ; statmp10 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_ptr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr = statmp10 ; statmp11 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_ptr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_string, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_string = statmp11 ; statmp12 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_sum_ptr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_ptr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_ptr = statmp12 ; statmp13 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype_nil (ATSstrcst("ats_void_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void = statmp13 ; statmp14 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp14, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp14, atslab_1, ATSstrcst("ats_ptr_type")) ; statmp15 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp15, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp15, atslab_1, ATSstrcst("ats_ref_type")) ; statmp16 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp16, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp16, atslab_1, ATSstrcst("ats_var_type")) ; statmp17 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp17, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp17, atslab_1, ATSstrcst("ats_varet_type")) ; statmp18 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp18, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_0, statmp18, atslab_1, ATSstrcst("ats_rectemp_type")) ; statmp19 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp19, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp19, atslab_1, ATSstrcst("ats_rectemp_type")) ; statmp20 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp20, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_0, statmp20, atslab_1, ATSstrcst("ats_sumtemp_type")) ; statmp21 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp21, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_0, statmp21, atslab_1, ATSstrcst("...")) ; statmp77 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12) ; statmp76 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, statmp76, atslab_hityp_name, statmp21) ; ats_selptrset_mac(anairiats_rec_1, statmp76, atslab_hityp_node, statmp77) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg = statmp76 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_hipat_set_asvar ( ats_ptr_type hip, ats_ptr_type od2v ) { ((hipat_t)hip)->atslab_hipat_asvar = od2v; return ; } // end of [ats_hiexp_hipat_set_asvar] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hiexp_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libc_sats_gmp_sats.c0000664000175000017500000000201012223166160022066 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libc_sats_gmp_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_fixity_fxty_dats.c0000664000175000017500000021217512223166160022515 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_clo_ref_type atslab_2 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_clo_ref_type atslab_1 ; } anairiats_sum_6 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCrgt_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYnon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYinf_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpre_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYpos_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMatm_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMopr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERinf_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpre_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpos_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__backslash_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__infixtemp_prec) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_prec_dyn) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec) (ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_non) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__selptr_fixity_dyn) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_fixity_dyn) ; /* internal function declarations */ static ats_ptr_type f2_10 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f2_10_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) ; static ats_ptr_type f2_10_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type f1_9 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f1_9_closure_make (ats_ptr_type env0, ats_clo_ref_type env1) ; static ats_ptr_type f1_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_13 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_13_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) ; static ats_ptr_type f_13_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_inf_12 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_inf_12_closure_make (ats_ptr_type env0, ats_clo_ref_type env1) ; static ats_ptr_type aux_inf_12_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type f_15 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0) ; static ats_clo_ptr_type f_15_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) ; static ats_ptr_type f_15_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_pre_14 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_int_type arg1) ; static ats_clo_ptr_type aux_pre_14_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_pre_14_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type f_17 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0) ; static ats_clo_ptr_type f_17_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) ; static ats_ptr_type f_17_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_pos_16 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_int_type arg1) ; static ats_clo_ptr_type aux_pos_16_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_pos_16_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type err_21 (ats_ptr_type arg0) ; static ats_ptr_type resolve_22 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type resolve_22_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type resolve_22_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type resolve_app_23 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type resolve_app_23_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type resolve_app_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type reduce_24 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type reduce_24_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type reduce_24_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type pushup_25 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type pushup_25_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type pushup_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ...) ; static ats_clo_ptr_type resolve_22_0resolve_app_23_0reduce_24_0pushup_25_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type resolve_22_0resolve_app_23_0reduce_24_0pushup_25_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ...) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp25) ; ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp30) ; ATSstatic (ats_ptr_type, statmp31) ; ATSstatic (ats_ptr_type, statmp32) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 1792(line=52, offs=3) -- 2479(line=72, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_int_type, tmp1) ; // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; ATSlocal (ats_int_type, tmp4) ; ATSlocal (ats_int_type, tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_int_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; ATSlocal (ats_int_type, tmp12) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("FXTYnon()")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp2 = */ atspre_fprint_string (arg0, ATSstrcst("FXTYinf(")) ; tmp4 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec (tmp1) ; /* tmp3 = */ atspre_fprint_int (arg0, tmp4) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("FXTYpre(")) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec (tmp5) ; /* tmp7 = */ atspre_fprint_int (arg0, tmp8) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)arg1)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp10 = */ atspre_fprint_string (arg0, ATSstrcst("FXTYpos(")) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__int_of_prec (tmp9) ; /* tmp11 = */ atspre_fprint_int (arg0, tmp12) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2526(line=74, offs=22) -- 2564(line=74, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__print_fxty (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__print_fxty: tmp14 = atspre_stdout_get () ; tmp15 = ats_selsin_mac(tmp14, atslab_1) ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty (tmp15, arg0) ; /* tmp13 = */ atspre_stdout_view_set () ; return /* (tmp13) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__print_fxty] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2586(line=75, offs=22) -- 2624(line=75, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prerr_fxty (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; // ATSlocal_void (tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prerr_fxty: tmp18 = atspre_stderr_get () ; tmp19 = ats_selsin_mac(tmp18, atslab_1) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fprint_fxty (tmp19, arg0) ; /* tmp17 = */ atspre_stderr_view_set () ; return /* (tmp17) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prerr_fxty] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2675(line=81, offs=3) -- 2818(line=85, offs=29) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_get_prec (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_get_prec: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp21 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp21, atslab_0, tmp22) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp21, atslab_0, tmp23) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp21, atslab_0, tmp24) ; break ; } while (0) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_get_prec] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2899(line=89, offs=20) -- 2922(line=89, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_inf (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_inf: tmp26 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp26)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp26, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp26, atslab_1, arg1) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_inf] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2942(line=90, offs=20) -- 2957(line=90, offs=35) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pre (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pre: tmp27 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp27)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp27, atslab_0, arg0) ; return (tmp27) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pre] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 2977(line=91, offs=20) -- 2992(line=91, offs=35) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pos (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pos: tmp28 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp28)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_0, arg0) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pos] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3250(line=108, offs=20) -- 3295(line=108, offs=65) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (ats_clo_ref_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app: tmp34 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp34)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec) ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_1, statmp32) ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_2, arg0) ; tmp33 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp33)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp33, atslab_0, tmp34) ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3442(line=118, offs=8) -- 3600(line=122, offs=8) */ ATSstaticdec() ats_ptr_type f2_10 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_f2_10: tmp39 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg0) ; tmp40 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg1) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp39, tmp40) ; tmp42 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp42, atslab_0, arg0) ; tmp43 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp42), atslab_1) ; tmp44 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp44, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp43) = tmp44 ; tmp43 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp44), atslab_1) ; tmp44 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp43) = tmp44 ; tmp41 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type))(ats_closure_fun(env1))) (env1, tmp38, env2, tmp38, tmp42) ; tmp37 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp37)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp37, atslab_0, tmp41) ; return (tmp37) ; } /* end of [f2_10] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; } f2_10_closure_type ; ats_ptr_type f2_10_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f2_10 (((f2_10_closure_type*)cloptr)->closure_env_0, ((f2_10_closure_type*)cloptr)->closure_env_1, ((f2_10_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f2_10_closure_init (f2_10_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&f2_10_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type f2_10_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { f2_10_closure_type *p_clo = ATS_MALLOC(sizeof(f2_10_closure_type)) ; f2_10_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3402(line=117, offs=6) -- 3679(line=125, offs=6) */ ATSstaticdec() ats_ptr_type f1_9 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_f1_9: tmp46 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; tmp45 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp45)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp45, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__infixtemp_prec) ; ats_selptrset_mac(anairiats_sum_4, tmp45, atslab_1, tmp46) ; ats_selptrset_mac(anairiats_sum_4, tmp45, atslab_2, f2_10_closure_make (env0, env1, arg0)) ; tmp36 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp36)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp36, atslab_0, tmp45) ; return (tmp36) ; } /* end of [f1_9] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; } f1_9_closure_type ; ats_ptr_type f1_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f1_9 (((f1_9_closure_type*)cloptr)->closure_env_0, ((f1_9_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f1_9_closure_init (f1_9_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f1_9_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f1_9_closure_make (ats_ptr_type env0, ats_clo_ref_type env1) { f1_9_closure_type *p_clo = ATS_MALLOC(sizeof(f1_9_closure_type)) ; f1_9_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3378(line=116, offs=7) -- 3742(line=128, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (ats_ptr_type arg0, ats_clo_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash: tmp47 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp47)->tag = 1 ; ats_selptrset_mac(anairiats_sum_6, tmp47, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__backslash_prec) ; ats_selptrset_mac(anairiats_sum_6, tmp47, atslab_1, f1_9_closure_make (arg0, arg1)) ; tmp35 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp35)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp35, atslab_0, tmp47) ; return (tmp35) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3960(line=140, offs=8) -- 4119(line=144, offs=8) */ ATSstaticdec() ats_ptr_type f_13 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; __ats_lab_f_13: tmp53 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg0) ; tmp54 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg1) ; tmp52 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp53, tmp54) ; tmp56 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp56, atslab_0, arg0) ; tmp57 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp56), atslab_1) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp58, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp57) = tmp58 ; tmp57 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp58), atslab_1) ; tmp58 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp57) = tmp58 ; tmp55 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type))(ats_closure_fun(env1))) (env1, tmp52, env2, tmp52, tmp56) ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp51)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp51, atslab_0, tmp55) ; return (tmp51) ; } /* end of [f_13] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; } f_13_closure_type ; ats_ptr_type f_13_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_13 (((f_13_closure_type*)cloptr)->closure_env_0, ((f_13_closure_type*)cloptr)->closure_env_1, ((f_13_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_13_closure_init (f_13_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&f_13_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type f_13_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { f_13_closure_type *p_clo = ATS_MALLOC(sizeof(f_13_closure_type)) ; f_13_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3888(line=138, offs=6) -- 4176(line=147, offs=6) */ ATSstaticdec() ats_ptr_type aux_inf_12 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_aux_inf_12: tmp59 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp59)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp59, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp59, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp59, atslab_2, f_13_closure_make (env0, env1, arg0)) ; tmp50 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp50)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp50, atslab_0, tmp59) ; return (tmp50) ; } /* end of [aux_inf_12] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; } aux_inf_12_closure_type ; ats_ptr_type aux_inf_12_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { return aux_inf_12 (((aux_inf_12_closure_type*)cloptr)->closure_env_0, ((aux_inf_12_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux_inf_12_closure_init (aux_inf_12_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_inf_12_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_inf_12_closure_make (ats_ptr_type env0, ats_clo_ref_type env1) { aux_inf_12_closure_type *p_clo = ATS_MALLOC(sizeof(aux_inf_12_closure_type)) ; aux_inf_12_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 4263(line=150, offs=8) -- 4434(line=155, offs=8) */ ATSstaticdec() ats_ptr_type f_15 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_f_15: tmp62 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg0) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env2, tmp62) ; tmp65 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp65, atslab_0, arg0) ; tmp66 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp65), atslab_1) ; tmp67 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp66) = tmp67 ; tmp64 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type))(ats_closure_fun(env1))) (env1, tmp63, env3, tmp62, tmp65) ; tmp61 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp61)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp61, atslab_0, tmp64) ; return (tmp61) ; } /* end of [f_15] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; } f_15_closure_type ; ats_ptr_type f_15_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_15 (((f_15_closure_type*)cloptr)->closure_env_0, ((f_15_closure_type*)cloptr)->closure_env_1, ((f_15_closure_type*)cloptr)->closure_env_2, ((f_15_closure_type*)cloptr)->closure_env_3, arg0) ; } /* end of function */ ATSinline() ats_void_type f_15_closure_init (f_15_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) { p_clo->closure_fun = (ats_fun_ptr_type)&f_15_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; return ; } /* end of function */ ats_clo_ptr_type f_15_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) { f_15_closure_type *p_clo = ATS_MALLOC(sizeof(f_15_closure_type)) ; f_15_closure_init (p_clo, env0, env1, env2, env3) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 4205(line=149, offs=6) -- 4488(line=158, offs=6) */ ATSstaticdec() ats_ptr_type aux_pre_14 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_aux_pre_14: tmp68 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp68)->tag = 1 ; ats_selptrset_mac(anairiats_sum_6, tmp68, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp68, atslab_1, f_15_closure_make (env0, env1, env2, arg0)) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp60)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp60, atslab_0, tmp68) ; return (tmp60) ; } /* end of [aux_pre_14] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_pre_14_closure_type ; ats_ptr_type aux_pre_14_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1) { return aux_pre_14 (((aux_pre_14_closure_type*)cloptr)->closure_env_0, ((aux_pre_14_closure_type*)cloptr)->closure_env_1, ((aux_pre_14_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_pre_14_closure_init (aux_pre_14_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_pre_14_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_pre_14_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { aux_pre_14_closure_type *p_clo = ATS_MALLOC(sizeof(aux_pre_14_closure_type)) ; aux_pre_14_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 4575(line=161, offs=8) -- 4746(line=166, offs=8) */ ATSstaticdec() ats_ptr_type f_17 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_f_17: tmp71 = ((ats_ptr_type(*)(ats_ptr_type))env0) (arg0) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp71, env2) ; tmp74 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp74, atslab_0, arg0) ; tmp75 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp74), atslab_1) ; tmp76 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp75) = tmp76 ; tmp73 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type))(ats_closure_fun(env1))) (env1, tmp72, env3, tmp71, tmp74) ; tmp70 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp70)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp70, atslab_0, tmp73) ; return (tmp70) ; } /* end of [f_17] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; } f_17_closure_type ; ats_ptr_type f_17_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_17 (((f_17_closure_type*)cloptr)->closure_env_0, ((f_17_closure_type*)cloptr)->closure_env_1, ((f_17_closure_type*)cloptr)->closure_env_2, ((f_17_closure_type*)cloptr)->closure_env_3, arg0) ; } /* end of function */ ATSinline() ats_void_type f_17_closure_init (f_17_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) { p_clo->closure_fun = (ats_fun_ptr_type)&f_17_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; return ; } /* end of function */ ats_clo_ptr_type f_17_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type env3) { f_17_closure_type *p_clo = ATS_MALLOC(sizeof(f_17_closure_type)) ; f_17_closure_init (p_clo, env0, env1, env2, env3) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 4517(line=160, offs=6) -- 4800(line=169, offs=6) */ ATSstaticdec() ats_ptr_type aux_pos_16 (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_aux_pos_16: tmp77 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp77)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, tmp77, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp77, atslab_1, f_17_closure_make (env0, env1, env2, arg0)) ; tmp69 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp69)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp69, atslab_0, tmp77) ; return (tmp69) ; } /* end of [aux_pos_16] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_clo_ref_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_pos_16_closure_type ; ats_ptr_type aux_pos_16_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_int_type arg1) { return aux_pos_16 (((aux_pos_16_closure_type*)cloptr)->closure_env_0, ((aux_pos_16_closure_type*)cloptr)->closure_env_1, ((aux_pos_16_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_pos_16_closure_init (aux_pos_16_closure_type *p_clo, ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_pos_16_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_pos_16_closure_make (ats_ptr_type env0, ats_clo_ref_type env1, ats_ptr_type env2) { aux_pos_16_closure_type *p_clo = ATS_MALLOC(sizeof(aux_pos_16_closure_type)) ; aux_pos_16_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 3824(line=134, offs=3) -- 4993(line=179, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (ats_ptr_type arg0, ats_clo_ref_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_int_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make: tmp49 = ((ats_ptr_type(*)(ats_ptr_type))arg0) (arg2) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg3)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp48 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp48)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp48, atslab_0, arg2) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg3)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_0) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_1) ; tmp48 = aux_inf_12 (arg0, arg1, arg2, tmp78, tmp79) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg3)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp48 = aux_pre_14 (arg0, arg1, tmp49, arg2, tmp80) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (((ats_sum_ptr_type)arg3)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp48 = aux_pos_16 (arg0, arg1, tmp49, arg2, tmp81) ; break ; } while (0) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5067(line=184, offs=20) -- 5139(line=186, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp82 = tmp83 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp82 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; break ; } while (0) ; return (tmp82) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5206(line=189, offs=17) -- 5305(line=191, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; ATSlocal (ats_int_type, tmp86) ; ATSlocal (ats_int_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp84 = tmp85 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp84 = tmp86 ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp84 = tmp87 ; break ; } while (0) ; return (tmp84) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5555(line=207, offs=4) -- 5765(line=216, offs=4) */ ATSstaticdec() ats_ptr_type err_21 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; __ats_lab_err_21: /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp91 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; /* tmp92 = */ atspre_prerr_string (ATSstrcst(": fixity cannot be resolved.")) ; /* tmp93 = */ atspre_prerr_newline () ; /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp89) ; } /* end of [err_21] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5879(line=223, offs=5) -- 7298(line=258, offs=4) */ ATSstaticdec() ats_ptr_type resolve_22 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp186) ; tmp186 = resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (env0, env1, 0, arg0, arg1, arg2) ; return (tmp186) ; } /* end of [resolve_22] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } resolve_22_closure_type ; ats_ptr_type resolve_22_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return resolve_22 (((resolve_22_closure_type*)cloptr)->closure_env_0, ((resolve_22_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type resolve_22_closure_init (resolve_22_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&resolve_22_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type resolve_22_closure_make (ats_ptr_type env0, ats_ptr_type env1) { resolve_22_closure_type *p_clo = ATS_MALLOC(sizeof(resolve_22_closure_type)) ; resolve_22_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 7326(line=260, offs=5) -- 7890(line=274, offs=20) */ ATSstaticdec() ats_ptr_type resolve_app_23 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp187) ; tmp187 = resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (env0, env1, 1, arg0, arg1, arg2) ; return (tmp187) ; } /* end of [resolve_app_23] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } resolve_app_23_closure_type ; ats_ptr_type resolve_app_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return resolve_app_23 (((resolve_app_23_closure_type*)cloptr)->closure_env_0, ((resolve_app_23_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type resolve_app_23_closure_init (resolve_app_23_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&resolve_app_23_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type resolve_app_23_closure_make (ats_ptr_type env0, ats_ptr_type env1) { resolve_app_23_closure_type *p_clo = ATS_MALLOC(sizeof(resolve_app_23_closure_type)) ; resolve_app_23_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 7925(line=277, offs=5) -- 8255(line=285, offs=20) */ ATSstaticdec() ats_ptr_type reduce_24 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp188) ; tmp188 = resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (env0, env1, 2, arg0, arg1) ; return (tmp188) ; } /* end of [reduce_24] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } reduce_24_closure_type ; ats_ptr_type reduce_24_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return reduce_24 (((reduce_24_closure_type*)cloptr)->closure_env_0, ((reduce_24_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type reduce_24_closure_init (reduce_24_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&reduce_24_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type reduce_24_closure_make (ats_ptr_type env0, ats_ptr_type env1) { reduce_24_closure_type *p_clo = ATS_MALLOC(sizeof(reduce_24_closure_type)) ; reduce_24_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 8285(line=288, offs=5) -- 8460(line=291, offs=41) */ ATSstaticdec() ats_ptr_type pushup_25 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp189) ; tmp189 = resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (env0, env1, 3, arg0, arg1) ; return (tmp189) ; } /* end of [pushup_25] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } pushup_25_closure_type ; ats_ptr_type pushup_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return pushup_25 (((pushup_25_closure_type*)cloptr)->closure_env_0, ((pushup_25_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type pushup_25_closure_init (pushup_25_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&pushup_25_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type pushup_25_closure_make (ats_ptr_type env0, ats_ptr_type env1) { pushup_25_closure_type *p_clo = ATS_MALLOC(sizeof(pushup_25_closure_type)) ; pushup_25_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5879(line=223, offs=5) -- 8460(line=291, offs=41) */ ATSstaticdec() ats_ptr_type resolve_22_0resolve_app_23_0reduce_24_0pushup_25 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_int_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_int_type, tmp126) ; ATSlocal (ats_int_type, tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_int_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_clo_ref_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_clo_ref_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_clo_ref_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp94 = va_arg(funarg, ats_ptr_type) ; tmp95 = va_arg(funarg, ats_ptr_type) ; tmp96 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_resolve_22 ; case 1: va_start(funarg, arg0) ; tmp97 = va_arg(funarg, ats_ptr_type) ; tmp98 = va_arg(funarg, ats_ptr_type) ; tmp99 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_resolve_app_23 ; case 2: va_start(funarg, arg0) ; tmp100 = va_arg(funarg, ats_ptr_type) ; tmp101 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_reduce_24 ; case 3: va_start(funarg, arg0) ; tmp102 = va_arg(funarg, ats_ptr_type) ; tmp103 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_pushup_25 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_resolve_22: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: if (((ats_sum_ptr_type)tmp95)->tag != 0) { goto __ats_lab_20_1 ; } __ats_lab_17_2: __ats_lab_17_3: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } tmp105 = ats_caselptrlab_mac(anairiats_sum_5, tmp96, atslab_0) ; if (((ats_sum_ptr_type)tmp105)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp97 = tmp94 ; tmp98 = tmp95 ; tmp99 = tmp96 ; goto __ats_lab_resolve_app_23 ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp106 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp106, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp106, atslab_1, tmp96) ; tmp102 = tmp94 ; tmp103 = tmp106 ; goto __ats_lab_pushup_25 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: // if (((ats_sum_ptr_type)tmp95)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_20_2: __ats_lab_20_3: tmp107 = ats_caselptrlab_mac(anairiats_sum_3, tmp95, atslab_0) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp107)->tag != 1) { goto __ats_lab_22_0 ; } __ats_lab_21_1: __ats_lab_21_2: tmp108 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp108, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp108, atslab_1, tmp96) ; tmp102 = tmp94 ; tmp103 = tmp108 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp107)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_23_1 ; } tmp109 = ats_caselptrlab_mac(anairiats_sum_5, tmp96, atslab_1) ; if (tmp109 != (ats_sum_ptr_type)0) { goto __ats_lab_23_1 ; } __ats_lab_22_2: tmp110 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp110, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp110, atslab_1, tmp96) ; tmp102 = tmp94 ; tmp103 = tmp110 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp107)->tag != 0) { goto __ats_lab_30_0 ; } __ats_lab_23_1: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_35_1 ; } tmp111 = ats_caselptrlab_mac(anairiats_sum_5, tmp96, atslab_1) ; if (tmp111 == (ats_sum_ptr_type)0) { goto __ats_lab_35_1 ; } tmp112 = ats_caselptrlab_mac(anairiats_sum_5, tmp111, atslab_0) ; if (((ats_sum_ptr_type)tmp112)->tag != 1) { goto __ats_lab_35_1 ; } __ats_lab_23_2: tmp113 = ats_caselptrlab_mac(anairiats_sum_3, tmp112, atslab_0) ; tmp114 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (tmp107) ; tmp115 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (tmp113) ; tmp116 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec (tmp114, tmp115) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp116 != 1) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp117 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp117, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp117, atslab_1, tmp96) ; tmp102 = tmp94 ; tmp103 = tmp117 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp116 != -1) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp118 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp118, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp118, atslab_1, tmp94) ; tmp100 = tmp118 ; tmp101 = tmp96 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp119 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity (tmp107) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity (tmp113) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp119)->tag != 1) { goto __ats_lab_28_0 ; } __ats_lab_27_1: if (((ats_sum_ptr_type)tmp120)->tag != 1) { goto __ats_lab_29_1 ; } __ats_lab_27_2: tmp121 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp121, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp121, atslab_1, tmp94) ; tmp100 = tmp121 ; tmp101 = tmp96 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp119)->tag != 2) { goto __ats_lab_29_0 ; } __ats_lab_28_1: if (((ats_sum_ptr_type)tmp120)->tag != 2) { goto __ats_lab_29_1 ; } __ats_lab_28_2: tmp122 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp122, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp122, atslab_1, tmp96) ; tmp102 = tmp94 ; tmp103 = tmp122 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: __ats_lab_29_2: tmp104 = err_21 (env0) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp107)->tag != 2) { goto __ats_lab_34_0 ; } __ats_lab_30_1: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_34_1 ; } tmp123 = ats_caselptrlab_mac(anairiats_sum_5, tmp96, atslab_1) ; if (tmp123 == (ats_sum_ptr_type)0) { goto __ats_lab_34_1 ; } tmp124 = ats_caselptrlab_mac(anairiats_sum_5, tmp123, atslab_0) ; if (((ats_sum_ptr_type)tmp124)->tag != 1) { goto __ats_lab_34_1 ; } __ats_lab_30_2: tmp125 = ats_caselptrlab_mac(anairiats_sum_3, tmp124, atslab_0) ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (tmp107) ; tmp127 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (tmp125) ; tmp128 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec (tmp126, tmp127) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (tmp128 != 1) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp129 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp129, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp129, atslab_1, tmp96) ; tmp100 = tmp94 ; tmp101 = tmp129 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp128 != -1) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp130 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp130, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp130, atslab_1, tmp94) ; tmp100 = tmp130 ; tmp101 = tmp96 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp104 = err_21 (env0) ; break ; } while (0) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp107)->tag != 2) { goto __ats_lab_35_0 ; } __ats_lab_34_1: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_35_1 ; } tmp131 = ats_caselptrlab_mac(anairiats_sum_5, tmp96, atslab_1) ; if (tmp131 != (ats_sum_ptr_type)0) { goto __ats_lab_35_1 ; } __ats_lab_34_2: tmp132 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp132, atslab_0, tmp95) ; ats_selptrset_mac(anairiats_sum_5, tmp132, atslab_1, tmp96) ; tmp100 = tmp94 ; tmp101 = tmp132 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: __ats_lab_35_2: tmp104 = err_21 (env0) ; break ; } while (0) ; break ; } while (0) ; return tmp104 ; __ats_lab_resolve_app_23: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp99 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } tmp134 = ats_caselptrlab_mac(anairiats_sum_5, tmp99, atslab_1) ; if (tmp134 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } tmp135 = ats_caselptrlab_mac(anairiats_sum_5, tmp134, atslab_0) ; if (((ats_sum_ptr_type)tmp135)->tag != 1) { goto __ats_lab_42_0 ; } __ats_lab_36_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_3, tmp135, atslab_0) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_precedence (tmp136) ; tmp138 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__compare_prec_prec (ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__app_prec, tmp137) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp138 != 1) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp140 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp140, atslab_0, env1) ; ats_selptrset_mac(anairiats_sum_5, tmp140, atslab_1, tmp99) ; tmp139 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp139, atslab_0, tmp98) ; ats_selptrset_mac(anairiats_sum_5, tmp139, atslab_1, tmp140) ; tmp102 = tmp97 ; tmp103 = tmp139 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp138 != -1) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp141 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp141, atslab_0, tmp98) ; ats_selptrset_mac(anairiats_sum_5, tmp141, atslab_1, tmp97) ; tmp100 = tmp141 ; tmp101 = tmp99 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_associativity (tmp136) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp142)->tag != 1) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp143 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp143, atslab_0, tmp98) ; ats_selptrset_mac(anairiats_sum_5, tmp143, atslab_1, tmp97) ; tmp100 = tmp143 ; tmp101 = tmp99 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp133 = err_21 (env0) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp99 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } tmp144 = ats_caselptrlab_mac(anairiats_sum_5, tmp99, atslab_1) ; if (tmp144 != (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp146 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp146, atslab_0, env1) ; ats_selptrset_mac(anairiats_sum_5, tmp146, atslab_1, tmp99) ; tmp145 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp145, atslab_0, tmp98) ; ats_selptrset_mac(anairiats_sum_5, tmp145, atslab_1, tmp146) ; tmp102 = tmp97 ; tmp103 = tmp145 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp133 = err_21 (env0) ; break ; } while (0) ; return tmp133 ; __ats_lab_reduce_24: do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } tmp148 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_0) ; if (((ats_sum_ptr_type)tmp148)->tag != 0) { goto __ats_lab_45_0 ; } tmp149 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_1) ; if (tmp149 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } tmp150 = ats_caselptrlab_mac(anairiats_sum_5, tmp149, atslab_0) ; if (((ats_sum_ptr_type)tmp150)->tag != 1) { goto __ats_lab_45_0 ; } tmp151 = ats_caselptrlab_mac(anairiats_sum_3, tmp150, atslab_0) ; if (((ats_sum_ptr_type)tmp151)->tag != 1) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp152 = ats_caselptrlab_mac(anairiats_sum_3, tmp148, atslab_0) ; tmp153 = ats_caselptrlab_mac(anairiats_sum_6, tmp151, atslab_1) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_5, tmp149, atslab_1) ; tmp156 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(tmp153))) (tmp153, tmp152) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp155, atslab_0, tmp156) ; ats_selptrset_mac(anairiats_sum_5, tmp155, atslab_1, tmp100) ; tmp102 = tmp155 ; tmp103 = tmp154 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } tmp157 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_0) ; if (((ats_sum_ptr_type)tmp157)->tag != 0) { goto __ats_lab_46_0 ; } tmp158 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_1) ; if (tmp158 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } tmp159 = ats_caselptrlab_mac(anairiats_sum_5, tmp158, atslab_0) ; if (((ats_sum_ptr_type)tmp159)->tag != 1) { goto __ats_lab_46_0 ; } tmp160 = ats_caselptrlab_mac(anairiats_sum_3, tmp159, atslab_0) ; if (((ats_sum_ptr_type)tmp160)->tag != 0) { goto __ats_lab_46_0 ; } tmp161 = ats_caselptrlab_mac(anairiats_sum_5, tmp158, atslab_1) ; if (tmp161 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } tmp162 = ats_caselptrlab_mac(anairiats_sum_5, tmp161, atslab_0) ; if (((ats_sum_ptr_type)tmp162)->tag != 0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_3, tmp157, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_4, tmp160, atslab_2) ; tmp165 = ats_caselptrlab_mac(anairiats_sum_3, tmp162, atslab_0) ; tmp166 = ats_caselptrlab_mac(anairiats_sum_5, tmp161, atslab_1) ; tmp168 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type, ats_ptr_type))(ats_closure_fun(tmp164))) (tmp164, tmp165, tmp163) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp167, atslab_0, tmp168) ; ats_selptrset_mac(anairiats_sum_5, tmp167, atslab_1, tmp100) ; tmp102 = tmp167 ; tmp103 = tmp166 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } tmp169 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_0) ; if (((ats_sum_ptr_type)tmp169)->tag != 1) { goto __ats_lab_47_0 ; } tmp170 = ats_caselptrlab_mac(anairiats_sum_3, tmp169, atslab_0) ; if (((ats_sum_ptr_type)tmp170)->tag != 2) { goto __ats_lab_47_0 ; } tmp171 = ats_caselptrlab_mac(anairiats_sum_5, tmp101, atslab_1) ; if (tmp171 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } tmp172 = ats_caselptrlab_mac(anairiats_sum_5, tmp171, atslab_0) ; if (((ats_sum_ptr_type)tmp172)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_6, tmp170, atslab_1) ; tmp174 = ats_caselptrlab_mac(anairiats_sum_3, tmp172, atslab_0) ; tmp175 = ats_caselptrlab_mac(anairiats_sum_5, tmp171, atslab_1) ; tmp177 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(tmp173))) (tmp173, tmp174) ; tmp176 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp176, atslab_0, tmp177) ; ats_selptrset_mac(anairiats_sum_5, tmp176, atslab_1, tmp175) ; tmp102 = tmp100 ; tmp103 = tmp176 ; goto __ats_lab_pushup_25 ; // tail call break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp147 = err_21 (env0) ; break ; } while (0) ; return tmp147 ; __ats_lab_pushup_25: do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp102 != (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: if (tmp103 == (ats_sum_ptr_type)0) { goto __ats_lab_49_1 ; } tmp179 = ats_caselptrlab_mac(anairiats_sum_5, tmp103, atslab_0) ; if (((ats_sum_ptr_type)tmp179)->tag != 0) { goto __ats_lab_49_1 ; } tmp180 = ats_caselptrlab_mac(anairiats_sum_5, tmp103, atslab_1) ; if (tmp180 != (ats_sum_ptr_type)0) { goto __ats_lab_49_1 ; } __ats_lab_48_2: tmp181 = ats_caselptrlab_mac(anairiats_sum_3, tmp179, atslab_0) ; tmp178 = tmp181 ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp102 != (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: __ats_lab_49_2: tmp182 = (ats_sum_ptr_type)0 ; tmp100 = tmp182 ; tmp101 = tmp103 ; goto __ats_lab_reduce_24 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp102 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: __ats_lab_50_2: tmp183 = ats_caselptrlab_mac(anairiats_sum_5, tmp102, atslab_0) ; tmp184 = ats_caselptrlab_mac(anairiats_sum_5, tmp102, atslab_1) ; tmp94 = tmp184 ; tmp95 = tmp183 ; tmp96 = tmp103 ; goto __ats_lab_resolve_22 ; // tail call break ; } while (0) ; return tmp178 ; return (tmp185) ; } /* end of [resolve_22_0resolve_app_23_0reduce_24_0pushup_25] */ /* // /home/hwxi/research/Anairiats/src/ats_fixity_fxty.dats: 5459(line=201, offs=7) -- 8518(line=298, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve: tmp190 = (ats_sum_ptr_type)0 ; tmp88 = pushup_25 (arg0, arg1, arg2, tmp190) ; return (tmp88) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp25, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp30, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp31, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp32, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp25 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__FXTYnon_0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_non, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_non = statmp25 ; statmp30 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; statmp29 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)statmp29)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, statmp29, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__select_prec) ; ats_selptrset_mac(anairiats_sum_0, statmp29, atslab_1, statmp30) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__selptr_fixity_dyn, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__selptr_fixity_dyn = statmp29 ; statmp31 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp31)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, statmp31, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_prec_dyn) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_fixity_dyn, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__deref_fixity_dyn = statmp31 ; statmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_fixity_fxty_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_filebas_dats.c0000664000175000017500000000674312223166160023422 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include #include "libc/CATS/stdio.cats" ats_bool_type atspre_test_file_exists (ats_ptr_type path) { int ret ; struct stat buf ; ret = stat ((char*)path, &buf) ; if (!ret) { return ats_true_bool ; // ret == 0 } else { return ats_false_bool ; // ret == -1 } } /* test_file_exists */ ats_bool_type atspre_test_file_isdir (ats_ptr_type path) { int ret ; struct stat buf ; mode_t mode ; ret = stat ((char*)path, &buf) ; if (!ret) { // ret == 0 mode = buf.st_mode ; return S_ISDIR(mode) ? ats_true_bool : ats_false_bool ; } else { // ret == -1 return ats_false_bool ; } } /* atspre_test_file_dir */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_filebas_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_filebas_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_parser_sats.c0000664000175000017500000000645612223166160021445 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGi0de_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0rtid_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGsi0de_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGdi0de_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0exp_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0exp_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_sta_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_dyn_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESi0de_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESs0exp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0exp_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0eclst_3) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGnone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGi0de_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0rtid_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGsi0de_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGdi0de_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGs0exp_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0exp_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_sta_7.tag = 7 ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYBEGd0ecseq_dyn_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESi0de_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESs0exp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0exp_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__YYRESd0eclst_3.tag = 3 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_parser_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_emit_dats.c0000664000175000017500000101651512223166160022247 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ ats_void_type atsopt_emit_valprim_float (ats_ptr_type out, ats_ptr_type str) { char *s = str ; if (*s == '~') { fputc ('-', (FILE*)out) ; s += 1 ; } fputs (s, (FILE*)out) ; return ; } /* atsopt_emit_valprim_float */ ats_void_type atsopt_emit_valprim_intsp (ats_ptr_type out, ats_ptr_type str) { char *s = str ; if (*s == '~') { fputc ('-', (FILE*)out) ; s += 1 ; } fputs (s, (FILE*)out) ; return ; } /* atsopt_emit_valprim_intsp */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_12 ; typedef struct { anairiats_rec_12 atslab_0 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_branch_lab ; ats_ptr_type atslab_branch_inss ; } anairiats_rec_14 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_instr_loc ; ats_ptr_type atslab_instr_node ; } anairiats_rec_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; ats_ptr_type atslab_6 ; ats_ptr_type atslab_7 ; } anairiats_sum_21 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_23 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; } anairiats_sum_24 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITcltype_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargtmpref_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPchar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPenv_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPext_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloat_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloatsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPint_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPintsp_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_var_offs_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPsizeof_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPstring_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmpref_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKbool_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKcon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKexn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKfloat_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplab_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplabint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTcaseof_fail_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTfunarg_fail_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTraise_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTmatpnt_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_arr_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_tail_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_clo_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_fun_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_val_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_partval_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextval_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfreeptr_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunlab_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdynload_file_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloopexn_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_arg_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRpatck_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_offs_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_offs_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtmplabint_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_beg_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_end_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_tst_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon3_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isprint) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_char) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_int_type, atsopt_debug_flag_get) () ; ATSextern_fun(ats_int_type, atsopt_gline_flag_get) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_full) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_namespace_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse_list_vt) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_islst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_fil) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_fil) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__label_is_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_top) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprim) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_void) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__envmap_find) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_matpnt) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_identifier) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext) (ats_ref_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint) (ats_ref_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funentry_tmpvarmap_add) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tailjoinlst_tmpvarmap_add) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tailjoinlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_local) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_tailjoin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_reset) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_set) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_fun) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_clofun) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_emit_valprim_float) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_valprim_intsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_emit_valprim_string) (ats_ref_type, ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_patck) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branch) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_type) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_init) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_make) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_clofun) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon3_0) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type prerr_loc_errorccomp_1 (ats_ptr_type arg0) ; static ats_void_type emit_funlab_prefix_6 (ats_ref_type arg0) ; static ats_void_type _emit_hityp_11 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type _emit_hityp_ptr_12 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type _emit_hityplst_sep_13 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ref_make_elt_03903_ats_int_type (ats_int_type arg0) ; static ats_ptr_type ref_make_elt_03903_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type loop_23 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type funarglst_find_22 (ats_int_type arg0) ; static ats_void_type funarglst_pop_24 () ; static ats_void_type funarglst_push_25 (ats_ptr_type arg0) ; static ats_void_type emit_valprim_arg_26 (ats_ref_type arg0, ats_int_type arg1) ; static ats_void_type emit_valprim_argref_27 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type emit_valprim_bool_28 (ats_ref_type arg0, ats_bool_type arg1) ; static ats_void_type emit_valprim_char_29 (ats_ref_type arg0, ats_char_type arg1) ; static ats_void_type emit_tmpvar_cloptr_init_30 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type emit_valprim_clo_make_31 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type emit_valprim_int_32 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_valprim_ptrof_33 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_35 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_array_index_34 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_bool_type label_is_tyarr_36 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_38 (ats_ref_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) ; static ats_void_type emit_select_clo_37 (ats_ref_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) ; static ats_void_type __ats_fun_40 (ats_ptr_type env0, ats_ref_type arg0) ; static ats_clo_ptr_type __ats_fun_40_closure_make (ats_ptr_type env0) ; static ats_void_type __ats_fun_40_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) ; static ats_void_type emit_valprim_select_39 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_fst_42 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type __ats_fun_43 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0) ; static ats_clo_ptr_type __ats_fun_43_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type __ats_fun_43_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) ; static ats_void_type emit_valprim_select_varptr_41 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type emit_valprim_select_var_44 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type emit_valprim_select_ptr_45 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_49 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_54 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_envmap_56 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_main_57 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_clo_ptr_type aux_main_57_closure_make () ; static ats_int_type aux_main_57_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_void_type aux_arg_59 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_arg_59_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_arg_59_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type emit_move_con_58 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type emit_instr_assgn_arr_60 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type emit_instr_arr_heap_61 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type emit_instr_arr_stack_62 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_bool_type d2cst_fun_is_void_63 (ats_ptr_type arg0) ; static ats_bool_type funlab_fun_is_void_64 (ats_ptr_type arg0) ; static ats_void_type emit_instr_call_65 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_67 (ats_ptr_type env0, ats_bool_type env1, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_67_closure_make (ats_ptr_type env0, ats_bool_type env1) ; static ats_void_type aux_67_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_68 (ats_bool_type env0, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_68_closure_make (ats_bool_type env0) ; static ats_void_type aux_68_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_70 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type loop_72 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type f_arg_74 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type _emit_funenvarg_73 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_77 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type funentry_env_err_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_fld_79 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type _emit_closure_type_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_arg_81 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type f_body_82 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type _emit_closure_init_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_arg_84 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_85 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type _emit_closure_make_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_env_87 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_arglst_88 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type _emit_closure_clofun_86 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type loop_94 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type hityplst_get_nvararg_93 (ats_ptr_type arg0) ; static ats_void_type aux_function_97 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ref_type arg0) ; static ats_clo_ptr_type aux_function_97_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) ; static ats_void_type aux_function_97_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) ; static ats_void_type aux_closure_make_98 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0) ; static ats_clo_ptr_type aux_closure_make_98_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_closure_make_98_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) ; static ats_void_type aux_closure_clofun_99 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0) ; static ats_clo_ptr_type aux_closure_clofun_99_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type aux_closure_clofun_99_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp98) ; ATSstatic (ats_ptr_type, statmp101) ; ATSstatic (ats_ptr_type, statmp104) ; ATSstatic (ats_ptr_type, statmp105) ; ATSstatic (ats_ptr_type, statmp106) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 2375(line=80, offs=4) -- 2436(line=81, offs=42) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_emit)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 2468(line=84, offs=4) -- 2561(line=85, offs=52) */ ATSstaticdec() ats_void_type prerr_loc_errorccomp_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; __ats_lab_prerr_loc_errorccomp_1: /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; return /* (tmp1) */ ; } /* end of [prerr_loc_errorccomp_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 3486(line=131, offs=12) -- 3533(line=131, offs=59) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label: /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, arg1) ; return /* (tmp3) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 3561(line=135, offs=3) -- 3731(line=141, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext (ats_ref_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext: if (arg1) { /* empty */ } else { /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("atslab_")) ; } /* end of [if] */ /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, arg2) ; return /* (tmp4) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 4745(line=188, offs=3) -- 5191(line=204, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; ATSlocal (ats_int_type, tmp13) ; ATSlocal (ats_bool_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con: tmp7 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_fil (arg1) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (arg1) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp8) ; /* tmp10 = */ atsopt_emit_filename (arg0, tmp7) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst("__")) ; /* tmp12 = */ atsopt_emit_identifier (arg0, tmp9) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (arg1) ; tmp14 = atspre_gte_int_int (tmp13, 0) ; if (tmp14) { /* tmp6 = */ atspre_fprintf_exn (arg0, ATSstrcst("_%i"), tmp13) ; } else { /* empty */ } /* end of [if] */ return /* (tmp6) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 5237(line=207, offs=12) -- 6324(line=238, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_bool_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_bool_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst: tmp16 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef (arg1) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp16)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp17 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_fil (arg1) ; tmp18 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name (arg1) ; /* tmp19 = */ atsopt_emit_filename (arg0, tmp17) ; /* tmp20 = */ atspre_fprint_string (arg0, ATSstrcst("__")) ; /* tmp15 = */ atsopt_emit_identifier (arg0, tmp18) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp16)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_0) ; /* ats_ptr_type tmp22 ; */ tmp22 = tmp21 ; tmp24 = atspre_string_is_empty (tmp22) ; if (tmp24) { tmp25 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name (arg1) ; tmp22 = tmp25 ; } else { /* empty */ } /* end of [if] */ /* tmp15 = */ atsopt_emit_identifier (arg0, tmp22) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp16)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_0) ; /* ats_ptr_type tmp27 ; */ tmp27 = tmp26 ; tmp29 = atspre_string_is_empty (tmp27) ; if (tmp29) { tmp30 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name (arg1) ; tmp27 = tmp30 ; } else { /* empty */ } /* end of [if] */ /* tmp15 = */ atsopt_emit_identifier (arg0, tmp27) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)tmp16)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_0) ; /* ats_ptr_type tmp32 ; */ tmp32 = tmp31 ; tmp34 = atspre_string_is_empty (tmp32) ; if (tmp34) { tmp35 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_name (arg1) ; tmp32 = tmp35 ; } else { /* empty */ } /* end of [if] */ /* tmp15 = */ atsopt_emit_identifier (arg0, tmp32) ; break ; } while (0) ; return /* (tmp15) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 6373(line=242, offs=4) -- 6680(line=253, offs=4) */ ATSstaticdec() ats_void_type emit_funlab_prefix_6 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_bool_type, tmp38) ; __ats_lab_emit_funlab_prefix_6: tmp37 = atsopt_namespace_get () ; tmp38 = atspre_stropt_is_some (tmp37) ; if (tmp38) { /* tmp36 = */ atspre_fprint_string (arg0, ats_castfn_mac(ats_ptr_type, tmp37)) ; } else { /* empty */ } /* end of [if] */ return /* (tmp36) */ ; } /* end of [emit_funlab_prefix_6] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 6735(line=256, offs=13) -- 7258(line=270, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp39) ; // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_bool_type, tmp45) ; ATSlocal (ats_int_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab: tmp41 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua (arg1) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp41 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_2, tmp41, atslab_0) ; /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp42) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp41 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: /* tmp43 = */ emit_funlab_prefix_6 (arg0) ; tmp44 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name (arg1) ; /* tmp40 = */ atsopt_emit_identifier (arg0, tmp44) ; break ; } while (0) ; tmp46 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck (arg1) ; tmp45 = atspre_gt_int_int (tmp46, 0) ; if (tmp45) { /* tmp39 = */ atspre_fprint_string (arg0, ATSstrcst("_prfck")) ; } else { /* empty */ } /* end of [if] */ return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 7329(line=276, offs=3) -- 7461(line=280, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; ATSlocal (atsopt_count_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab: /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("__ats_lab_")) ; tmp49 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_get_stamp (arg1) ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp49) ; return /* (tmp47) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 7514(line=284, offs=3) -- 7632(line=287, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint: /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, arg1) ; /* tmp50 = */ atspre_fprintf_exn (arg0, ATSstrcst("_%i"), arg2) ; return /* (tmp50) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 7706(line=293, offs=3) -- 8384(line=312, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_int_type, tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (atsopt_count_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_top (arg1) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp55 = atspre_eq_int_int (tmp53, 1) ; if (!tmp55) { goto __ats_lab_7_1 ; } tmp56 = atsopt_namespace_get () ; tmp58 = atspre_stropt_is_some (tmp56) ; if (tmp58) { /* tmp57 = */ atspre_fprint_string (arg0, ats_castfn_mac(ats_ptr_type, tmp56)) ; } else { /* empty */ } /* end of [if] */ /* tmp54 = */ atspre_fprint_string (arg0, ATSstrcst("statmp")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: /* tmp54 = */ atspre_fprint_string (arg0, ATSstrcst("tmp")) ; break ; } while (0) ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_stamp (arg1) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp59) ; return /* (tmp52) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 8493(line=320, offs=4) -- 9017(line=340, offs=4) */ ATSstaticdec() ats_void_type _emit_hityp_11 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_bool_type, tmp64) ; __ats_lab__emit_hityp_11: tmp61 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_hityp_name) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_3, tmp61, atslab_0) ; tmp63 = ats_caselptrlab_mac(anairiats_sum_3, tmp61, atslab_1) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp64 = atspre_lte_int_int (tmp62, 0) ; if (!tmp64) { goto __ats_lab_9_1 ; } /* tmp60 = */ atspre_fprint_string (arg0, tmp63) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptr_type")) ; break ; } while (0) ; return /* (tmp60) */ ; } /* end of [_emit_hityp_11] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 9046(line=342, offs=4) -- 9304(line=351, offs=4) */ ATSstaticdec() ats_void_type _emit_hityp_ptr_12 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_int_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_bool_type, tmp70) ; __ats_lab__emit_hityp_ptr_12: tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_hityp_name) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_3, tmp66, atslab_0) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_3, tmp66, atslab_1) ; /* tmp69 = */ atspre_fprint_string (arg0, tmp68) ; tmp70 = atspre_eq_int_int (tmp67, 0) ; if (tmp70) { /* tmp65 = */ atspre_fprint_char (arg0, '&') ; } else { /* empty */ } /* end of [if] */ return /* (tmp65) */ ; } /* end of [_emit_hityp_ptr_12] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 9450(line=357, offs=7) -- 9813(line=367, offs=6) */ ATSstaticdec() ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; ATSlocal (ats_bool_type, tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_int_type, tmp78) ; __ats_lab_aux_14: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp74 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp76 = atspre_gt_int_int (arg1, 0) ; if (tmp76) { /* tmp75 = */ atspre_fprint_string (arg0, arg3) ; } else { /* empty */ } /* end of [if] */ /* tmp77 = */ _emit_hityp_11 (arg0, tmp73) ; tmp78 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp78 ; arg2 = tmp74 ; arg3 = arg3 ; goto __ats_lab_aux_14 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: break ; } while (0) ; return /* (tmp72) */ ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 9336(line=353, offs=4) -- 9862(line=370, offs=4) */ ATSstaticdec() ats_void_type _emit_hityplst_sep_13 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp71) ; __ats_lab__emit_hityplst_sep_13: /* tmp71 = */ aux_14 (arg0, 0, arg1, arg2) ; return /* (tmp71) */ ; } /* end of [_emit_hityplst_sep_13] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 9937(line=375, offs=12) -- 10226(line=386, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp: tmp80 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (arg1) ; tmp81 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp80), atslab_hityp_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp81)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_1, tmp81, atslab_0) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp82) ; /* tmp79 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_type")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: /* tmp79 = */ _emit_hityp_11 (arg0, tmp80) ; break ; } while (0) ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 10276(line=389, offs=16) -- 10342(line=390, offs=49) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr: tmp85 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (arg1) ; /* tmp84 = */ _emit_hityp_ptr_12 (arg0, tmp85) ; return /* (tmp84) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 10399(line=394, offs=19) -- 10485(line=396, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep: tmp87 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (arg1) ; /* tmp86 = */ _emit_hityplst_sep_13 (arg0, tmp87, arg2) ; return /* (tmp86) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 10703(line=407, offs=16) -- 10922(line=414, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_fun (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_fun: /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, arg2) ; /* tmp90 = */ atspre_fprint_string (arg0, ATSstrcst("(*)(")) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep (arg0, arg1, ATSstrcst(", ")) ; /* tmp88 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp88) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 11125(line=422, offs=19) -- 11559(line=437, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_clofun (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; // ATSlocal_void (tmp95) ; ATSlocal (ats_bool_type, tmp96) ; // ATSlocal_void (tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_clofun: /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, arg2) ; /* tmp94 = */ atspre_fprint_string (arg0, ATSstrcst("(*)(ats_clo_ptr_type")) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp96 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (arg1) ; if (!tmp96) { goto __ats_lab_15_1 ; } /* tmp97 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityplst_sep (arg0, arg1, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: break ; } while (0) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp92) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_clofun] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03903_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_int_type, tmp100) ; __ats_lab_ref_make_elt_03903_ats_int_type: /* ats_int_type tmp100 ; */ tmp100 = arg0 ; tmp99 = atspre_ref_make_elt_tsz ((&tmp100), sizeof(ats_int_type)) ; return (tmp99) ; } /* end of [ref_make_elt_03903_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03903_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ref_make_elt_03903_ats_ptr_type: /* ats_ptr_type tmp103 ; */ tmp103 = arg0 ; tmp102 = atspre_ref_make_elt_tsz ((&tmp103), sizeof(ats_ptr_type)) ; return (tmp102) ; } /* end of [ref_make_elt_03903_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 12102(line=460, offs=7) -- 12260(line=462, offs=37) */ ATSstaticdec() ats_ptr_type loop_23 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_bool_type, tmp111) ; ATSlocal (ats_int_type, tmp112) ; __ats_lab_loop_23: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp111 = atspre_gt_int_int (arg1, 0) ; if (tmp111) { tmp112 = atspre_sub_int_int (arg1, 1) ; arg0 = tmp110 ; arg1 = tmp112 ; goto __ats_lab_loop_23 ; // tail call } else { tmp108 = tmp109 ; } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp108 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () ; break ; } while (0) ; return (tmp108) ; } /* end of [loop_23] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 12045(line=459, offs=4) -- 12374(line=466, offs=4) */ ATSstaticdec() ats_ptr_type funarglst_find_22 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_bool_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_funarglst_find_22: tmp114 = ats_ptrget_mac(ats_int_type, statmp98) ; tmp113 = atspre_gt_int_int (tmp114, 0) ; if (tmp113) { tmp116 = ats_ptrget_mac(ats_ptr_type, statmp101) ; tmp115 = loop_23 (tmp116, arg0) ; tmp107 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp107, atslab_0, tmp115) ; } else { tmp107 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp107) ; } /* end of [funarglst_find_22] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 12406(line=468, offs=4) -- 13003(line=487, offs=4) */ ATSstaticdec() ats_void_type funarglst_pop_24 () { /* local vardec */ // ATSlocal_void (tmp117) ; ATSlocal (ats_int_type, tmp118) ; // ATSlocal_void (tmp119) ; ATSlocal (ats_bool_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_funarglst_pop_24: tmp118 = ats_ptrget_mac(ats_int_type, statmp98) ; tmp120 = atspre_gt_int_int (tmp118, 0) ; if (tmp120) { tmp121 = atspre_sub_int_int (tmp118, 1) ; ats_ptrget_mac(ats_int_type, statmp98) = tmp121 ; } else { /* tmp122 = */ prerr_interror_0 () ; /* tmp123 = */ atspre_prerr_string (ATSstrcst(": funarglst_pop: n = 0")) ; /* tmp124 = */ atspre_prerr_newline () ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ /* ats_ptr_type tmp125 ; */ tmp125 = (ats_sum_ptr_type)0 ; tmp126 = atspre_ref_get_view_ptr (statmp105) ; tmp127 = ats_selsin_mac(tmp126, atslab_1) ; tmp129 = ats_ptrget_mac(ats_ptr_type, tmp127) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp129 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp130 = ats_caselptrlab_mac(anairiats_sum_4, tmp129, atslab_0) ; tmp131 = ats_caselptrlab_mac(anairiats_sum_4, tmp129, atslab_1) ; ATS_FREE(tmp129) ; ats_ptrget_mac(ats_ptr_type, tmp127) = tmp131 ; tmp125 = tmp130 ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (tmp129 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: break ; } while (0) ; ats_ptrget_mac(ats_ptr_type, statmp101) = tmp125 ; return /* (tmp117) */ ; } /* end of [funarglst_pop_24] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 13034(line=489, offs=4) -- 13386(line=501, offs=4) */ ATSstaticdec() ats_void_type funarglst_push_25 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_int_type, tmp134) ; ATSlocal (ats_bool_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; __ats_lab_funarglst_push_25: tmp133 = ats_ptrget_mac(ats_int_type, statmp98) ; tmp134 = atspre_add_int_int (tmp133, 1) ; ats_ptrget_mac(ats_int_type, statmp98) = tmp134 ; tmp135 = atspre_gt_int_int (tmp133, 0) ; if (tmp135) { tmp136 = ats_ptrget_mac(ats_ptr_type, statmp101) ; ats_ptrget_mac(ats_ptr_type, statmp101) = arg0 ; tmp137 = atspre_ref_get_view_ptr (statmp105) ; tmp138 = ats_selsin_mac(tmp137, atslab_1) ; tmp140 = ats_ptrget_mac(ats_ptr_type, tmp138) ; tmp139 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp139, atslab_0, tmp136) ; ats_selptrset_mac(anairiats_sum_4, tmp139, atslab_1, tmp140) ; ats_ptrget_mac(ats_ptr_type, tmp138) = tmp139 ; } else { ats_ptrget_mac(ats_ptr_type, statmp101) = arg0 ; } /* end of [if] */ return /* (tmp132) */ ; } /* end of [funarglst_push_25] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 13462(line=507, offs=4) -- 13691(line=514, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_arg_26 (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_emit_valprim_arg_26: tmp142 = funarglst_find_22 (arg1) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp142 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_2, tmp142, atslab_0) ; ATS_FREE(tmp142) ; /* tmp141 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp143) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (tmp142 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: /* tmp141 = */ atspre_fprintf_exn (arg0, ATSstrcst("arg%i"), arg1) ; break ; } while (0) ; return /* (tmp141) */ ; } /* end of [emit_valprim_arg_26] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 13728(line=516, offs=4) -- 14076(line=528, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_argref_27 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; // ATSlocal_void (tmp147) ; // ATSlocal_void (tmp148) ; __ats_lab_emit_valprim_argref_27: /* tmp145 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptrget_mac(")) ; /* tmp146 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, arg2) ; /* tmp147 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp148 = */ emit_valprim_arg_26 (arg0, arg1) ; /* tmp144 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp144) */ ; } /* end of [emit_valprim_argref_27] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 14137(line=532, offs=4) -- 14380(line=541, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_bool_28 (ats_ref_type arg0, ats_bool_type arg1) { /* local vardec */ // ATSlocal_void (tmp149) ; __ats_lab_emit_valprim_bool_28: if (arg1) { /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("ats_true_bool")) ; } else { /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("ats_false_bool")) ; } /* end of [if] */ return /* (tmp149) */ ; } /* end of [emit_valprim_bool_28] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 14439(line=545, offs=4) -- 14857(line=559, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_char_29 (ats_ref_type arg0, ats_char_type arg1) { /* local vardec */ // ATSlocal_void (tmp150) ; ATSlocal (ats_bool_type, tmp151) ; ATSlocal (ats_uint_type, tmp152) ; __ats_lab_emit_valprim_char_29: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg1 != '\'') { goto __ats_lab_23_0 ; } __ats_lab_22_1: /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("'\\''")) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg1 != '\n') { goto __ats_lab_24_0 ; } __ats_lab_23_1: /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("'\\n'")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg1 != '\t') { goto __ats_lab_25_0 ; } __ats_lab_24_1: /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("'\\t'")) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg1 != '\\') { goto __ats_lab_26_0 ; } __ats_lab_25_1: /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("'\\\\'")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp151 = atspre_char_isprint (arg1) ; if (!tmp151) { goto __ats_lab_27_1 ; } /* tmp150 = */ atspre_fprintf_exn (arg0, ATSstrcst("'%c'"), arg1) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp152 = atspre_uint_of_char (arg1) ; /* tmp150 = */ atspre_fprintf_exn (arg0, ATSstrcst("'\\%.3o'"), tmp152) ; break ; } while (0) ; return /* (tmp150) */ ; } /* end of [emit_valprim_char_29] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 14916(line=563, offs=4) -- 15393(line=578, offs=4) */ ATSstaticdec() ats_void_type emit_tmpvar_cloptr_init_30 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; // ATSlocal_void (tmp158) ; ATSlocal (ats_int_type, tmp159) ; __ats_lab_emit_tmpvar_cloptr_init_30: tmp154 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (arg3) ; tmp155 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp154) ; /* tmp156 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg3) ; /* tmp157 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_init (")) ; /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, arg2) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv (arg0, arg4, tmp155, 1) ; /* tmp153 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp153) */ ; } /* end of [emit_tmpvar_cloptr_init_30] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 15432(line=580, offs=4) -- 16086(line=602, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_clo_make_31 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; ATSlocal (ats_bool_type, tmp164) ; // ATSlocal_void (tmp165) ; ATSlocal (ats_int_type, tmp166) ; __ats_lab_emit_valprim_clo_make_31: tmp161 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (arg2) ; tmp162 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp161) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg2) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp164 = atspre_neq_int_int (arg1, 0) ; if (!tmp164) { goto __ats_lab_29_1 ; } /* tmp165 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_make (")) ; tmp166 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv (arg0, arg3, tmp162, 0) ; /* tmp160 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: /* tmp160 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_error ()")) ; break ; } while (0) ; return /* (tmp160) */ ; } /* end of [emit_valprim_clo_make_31] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 16572(line=624, offs=4) -- 16710(line=630, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_int_32 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp167) ; __ats_lab_emit_valprim_int_32: /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, arg1) ; return /* (tmp167) */ ; } /* end of [emit_valprim_int_32] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 17191(line=652, offs=4) -- 18594(line=698, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_ptrof_33 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_int_type, tmp170) ; ATSlocal (ats_int_type, tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_int_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; // ATSlocal_void (tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; __ats_lab_emit_valprim_ptrof_33: tmp169 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_valprim_node) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp169)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_6, tmp169, atslab_0) ; /* tmp168 = */ emit_valprim_arg_26 (arg0, tmp170) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp169)->tag != 2) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_6, tmp169, atslab_0) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("(&")) ; /* tmp173 = */ emit_valprim_arg_26 (arg0, tmp171) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp169)->tag != 9) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_1, tmp169, atslab_0) ; tmp176 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (tmp174) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some (tmp176) ; /* tmp177 = */ atspre_fprint_string (arg0, ATSstrcst("env")) ; /* tmp168 = */ atspre_fprint_int (arg0, tmp175) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp169)->tag != 10) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp178 = ats_caselptrlab_mac(anairiats_sum_1, tmp169, atslab_0) ; /* tmp168 = */ atspre_fprintf_exn (arg0, ATSstrcst("(&%s)"), tmp178) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp169)->tag != 23) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_1, tmp169, atslab_0) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("(&")) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp179) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: /* tmp182 = */ atspre_fprint_string (arg0, ATSstrcst("ptrof_error(")) ; /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp168) */ ; } /* end of [emit_valprim_ptrof_33] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 18755(line=706, offs=7) -- 19131(line=717, offs=6) */ ATSstaticdec() ats_void_type aux_35 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; __ats_lab_aux_35: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp187 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp188 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, tmp186) ; /* tmp190 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; arg0 = arg0 ; arg1 = tmp187 ; goto __ats_lab_aux_35 ; // tail call break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; return /* (tmp185) */ ; } /* end of [aux_35] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 18651(line=702, offs=4) -- 19172(line=720, offs=4) */ ATSstaticdec() ats_void_type emit_array_index_34 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp184) ; __ats_lab_emit_array_index_34: /* tmp184 = */ aux_35 (arg0, arg1) ; return /* (tmp184) */ ; } /* end of [emit_array_index_34] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 19324(line=727, offs=4) -- 19460(line=730, offs=4) */ ATSstaticdec() ats_bool_type label_is_tyarr_36 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; __ats_lab_label_is_tyarr_36: tmp192 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (arg0) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__label_is_tyarr (tmp192, arg1) ; return (tmp191) ; } /* end of [label_is_tyarr_36] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 19647(line=739, offs=7) -- 22236(line=813, offs=37) */ ATSstaticdec() ats_void_type aux_38 (ats_ref_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; // ATSlocal_void (tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_bool_type, tmp207) ; ATSlocal (ats_bool_type, tmp208) ; // ATSlocal_void (tmp209) ; ATSlocal (ats_bool_type, tmp210) ; ATSlocal (ats_bool_type, tmp211) ; ATSlocal (ats_bool_type, tmp212) ; ATSlocal (ats_bool_type, tmp213) ; ATSlocal (ats_bool_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_int_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_int_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; // ATSlocal_void (tmp220) ; ATSlocal (ats_bool_type, tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; // ATSlocal_void (tmp225) ; ATSlocal (ats_bool_type, tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; __ats_lab_aux_38: do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_38_1: tmp195 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp196 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; ATS_FREE(arg1) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp195)->tag != 1) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_7, tmp195, atslab_0) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_7, tmp195, atslab_1) ; /* tmp199 = */ atspre_fprint_string (arg0, ATSstrcst("ats_caselind_mac(")) ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp198) ; /* tmp201 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp202 = */ aux_38 (arg0, tmp196, arg2) ; /* tmp203 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp204 = */ emit_array_index_34 (arg0, tmp197) ; /* tmp194 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (((ats_sum_ptr_type)tmp195)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_7, tmp195, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_7, tmp195, atslab_1) ; /* ats_bool_type tmp207 ; */ tmp207 = ats_false_bool ; /* ats_bool_type tmp208 ; */ tmp208 = ats_false_bool ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp210 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox (tmp206) ; if (!tmp210) { goto __ats_lab_42_1 ; } tmp211 = label_is_tyarr_36 (tmp206, tmp205) ; /* tmp209 = */ atspre_fprint_string (arg0, ATSstrcst("ats_selbox_mac(")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp212 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin (tmp206) ; if (!tmp212) { goto __ats_lab_43_1 ; } /* tmp209 = */ atspre_fprint_string (arg0, ATSstrcst("ats_selsin_mac(")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp213 = label_is_tyarr_36 (tmp206, tmp205) ; tmp214 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext (tmp206) ; tmp207 = tmp214 ; /* tmp209 = */ atspre_fprint_string (arg0, ATSstrcst("ats_select_mac(")) ; break ; } while (0) ; tmp215 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp206) ; /* ats_int_type tmp216 ; */ tmp216 = 0 ; tmp217 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp215), atslab_hityp_name) ; tmp218 = ats_caselptrlab_mac(anairiats_sum_3, tmp217, atslab_0) ; tmp219 = ats_caselptrlab_mac(anairiats_sum_3, tmp217, atslab_1) ; do { /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp221 = atspre_gt_int_int (tmp218, 0) ; if (!tmp221) { goto __ats_lab_45_1 ; } tmp216 = 1 ; /* tmp222 = */ atspre_fprint_string (arg0, ATSstrcst("ats_castptr_mac(")) ; /* tmp223 = */ atspre_fprint_string (arg0, tmp219) ; /* tmp220 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: break ; } while (0) ; /* tmp224 = */ aux_38 (arg0, tmp196, arg2) ; tmp226 = atspre_gt_int_int (tmp216, 0) ; if (tmp226) { /* tmp225 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; } else { /* empty */ } /* end of [if] */ /* tmp227 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext (arg0, tmp207, tmp205) ; if (tmp208) { /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst("[0]")) ; } else { /* empty */ } /* end of [if] */ /* tmp194 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: /* tmp194 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_ref_type))(ats_closure_fun(arg2))) (arg2, arg0) ; break ; } while (0) ; return /* (tmp194) */ ; } /* end of [aux_38] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 19513(line=734, offs=4) -- 22314(line=817, offs=4) */ ATSstaticdec() ats_void_type emit_select_clo_37 (ats_ref_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp193) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_emit_select_clo_37: tmp230 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse_list_vt (arg1) ; /* tmp193 = */ aux_38 (arg0, tmp230, arg2) ; return /* (tmp193) */ ; } /* end of [emit_select_clo_37] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 22513(line=826, offs=20) -- 22553(line=826, offs=60) */ ATSstaticdec() ats_void_type __ats_fun_40 (ats_ptr_type env0, ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp233) ; __ats_lab___ats_fun_40: /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, env0) ; return /* (tmp233) */ ; } /* end of [__ats_fun_40] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_40_closure_type ; ats_void_type __ats_fun_40_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) { __ats_fun_40 (((__ats_fun_40_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_40_closure_init (__ats_fun_40_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_40_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_40_closure_make (ats_ptr_type env0) { __ats_fun_40_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_40_closure_type)) ; __ats_fun_40_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 22368(line=821, offs=4) -- 22554(line=826, offs=61) */ ATSstaticdec() ats_void_type emit_valprim_select_39 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_emit_valprim_select_39: /* ats_ptr_type tmp232 ; */ tmp232 = __ats_fun_40_closure_make (arg1) ; /* tmp231 = */ emit_select_clo_37 (arg0, arg2, tmp232) ; ATS_FREE(tmp232) ; return /* (tmp231) */ ; } /* end of [emit_valprim_select_39] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 22773(line=838, offs=6) -- 25955(line=920, offs=6) */ ATSstaticdec() ats_void_type aux_fst_42 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; ATSlocal (ats_bool_type, tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_bool_type, tmp247) ; ATSlocal (ats_bool_type, tmp248) ; // ATSlocal_void (tmp249) ; // ATSlocal_void (tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; ATSlocal (ats_bool_type, tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_bool_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; ATSlocal (ats_bool_type, tmp262) ; ATSlocal (ats_bool_type, tmp263) ; // ATSlocal_void (tmp264) ; ATSlocal (ats_bool_type, tmp265) ; // ATSlocal_void (tmp266) ; ATSlocal (ats_bool_type, tmp267) ; // ATSlocal_void (tmp268) ; // ATSlocal_void (tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; __ats_lab_aux_fst_42: do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)arg3)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_0) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_1) ; /* tmp238 = */ atspre_fprint_string (arg0, ATSstrcst("ats_caselptrind_mac(")) ; /* tmp239 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp237) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; tmp242 = atspre_gt_int_int (arg1, 0) ; if (tmp242) { /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; } else { /* tmp241 = */ emit_valprim_ptrof_33 (arg0, arg2) ; } /* end of [if] */ /* tmp243 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp244 = */ emit_array_index_34 (arg0, tmp236) ; /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (((ats_sum_ptr_type)arg3)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp245 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_0) ; tmp246 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_1) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: tmp247 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox (tmp246) ; if (!tmp247) { goto __ats_lab_50_1 ; } tmp248 = label_is_tyarr_36 (tmp246, tmp245) ; /* tmp249 = */ atspre_fprint_string (arg0, ATSstrcst("ats_caselptrlab_mac(")) ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, tmp246) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; /* tmp253 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp254 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext (arg0, ats_false_bool, tmp245) ; if (tmp248) { /* tmp255 = */ atspre_fprint_string (arg0, ATSstrcst("[0]")) ; } else { /* empty */ } /* end of [if] */ /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: tmp256 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin (tmp246) ; if (!tmp256) { goto __ats_lab_51_1 ; } tmp258 = atspre_gt_int_int (arg1, 0) ; if (tmp258) { /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptrget_mac(")) ; } else { /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("ats_varget_mac(")) ; } /* end of [if] */ /* tmp259 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp246) ; /* tmp260 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp261 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp262 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext (tmp246) ; tmp263 = label_is_tyarr_36 (tmp246, tmp245) ; tmp265 = atspre_gt_int_int (arg1, 0) ; if (tmp265) { /* tmp264 = */ atspre_fprint_string (arg0, ATSstrcst("ats_selptr_mac(")) ; } else { /* tmp264 = */ atspre_fprint_string (arg0, ATSstrcst("ats_select_mac(")) ; } /* end of [if] */ tmp267 = atspre_gt_int_int (arg1, 0) ; if (tmp267) { /* tmp268 = */ atspre_fprint_string (arg0, ATSstrcst("ats_castptr_mac(")) ; /* tmp269 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp246) ; /* tmp270 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; /* tmp266 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; } else { /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; } /* end of [if] */ /* tmp272 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext (arg0, tmp262, tmp245) ; if (tmp263) { /* tmp274 = */ atspre_fprint_string (arg0, ATSstrcst("[0]")) ; } else { /* empty */ } /* end of [if] */ /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp235) */ ; } /* end of [aux_fst_42] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 26100(line=925, offs=30) -- 26149(line=925, offs=79) */ ATSstaticdec() ats_void_type __ats_fun_43 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp278) ; __ats_lab___ats_fun_43: /* tmp278 = */ aux_fst_42 (arg0, env0, env1, env2) ; return /* (tmp278) */ ; } /* end of [__ats_fun_43] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } __ats_fun_43_closure_type ; ats_void_type __ats_fun_43_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) { __ats_fun_43 (((__ats_fun_43_closure_type*)cloptr)->closure_env_0, ((__ats_fun_43_closure_type*)cloptr)->closure_env_1, ((__ats_fun_43_closure_type*)cloptr)->closure_env_2, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_43_closure_init (__ats_fun_43_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_43_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_43_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { __ats_fun_43_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_43_closure_type)) ; __ats_fun_43_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 22635(line=832, offs=4) -- 26478(line=938, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_select_varptr_41 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp234) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; __ats_lab_emit_valprim_select_varptr_41: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_0) ; tmp276 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_1) ; /* ats_ptr_type tmp277 ; */ tmp277 = __ats_fun_43_closure_make (arg1, arg2, tmp275) ; /* tmp234 = */ emit_select_clo_37 (arg0, tmp276, tmp277) ; ATS_FREE(tmp277) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: /* tmp279 = */ prerr_interror_0 () ; /* tmp280 = */ atspre_prerr_string (ATSstrcst(": emit_valprim_select_varptr: vp_root = ")) ; /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_valprim (arg2) ; /* tmp282 = */ atspre_prerr_newline () ; /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp234) */ ; } /* end of [emit_valprim_select_varptr_41] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 26543(line=942, offs=4) -- 26732(line=948, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_select_var_44 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp283) ; __ats_lab_emit_valprim_select_var_44: /* tmp283 = */ emit_valprim_select_varptr_41 (arg0, 0, arg1, arg2) ; return /* (tmp283) */ ; } /* end of [emit_valprim_select_var_44] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 26773(line=950, offs=4) -- 26962(line=955, offs=4) */ ATSstaticdec() ats_void_type emit_valprim_select_ptr_45 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp284) ; __ats_lab_emit_valprim_select_ptr_45: /* tmp284 = */ emit_valprim_select_varptr_41 (arg0, 1, arg1, arg2) ; return /* (tmp284) */ ; } /* end of [emit_valprim_select_ptr_45] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 28010(line=1002, offs=3) -- 28055(line=1002, offs=48) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp285) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar: /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, arg1) ; return /* (tmp285) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 28139(line=1009, offs=7) -- 32061(line=1112, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_int_type, tmp288) ; ATSlocal (ats_int_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_int_type, tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; ATSlocal (ats_char_type, tmp299) ; ATSlocal (ats_int_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_bool_type, tmp304) ; // ATSlocal_void (tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_size_type, tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_bool_type, tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; // ATSlocal_void (tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; // ATSlocal_void (tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_int_type, tmp342) ; // ATSlocal_void (tmp343) ; ATSlocal (ats_bool_type, tmp344) ; ATSlocal (ats_size_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim: tmp287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_valprim_node) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp287)->tag != 0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_6, tmp287, atslab_0) ; /* tmp286 = */ emit_valprim_arg_26 (arg0, tmp288) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp287)->tag != 1) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp289 = ats_caselptrlab_mac(anairiats_sum_6, tmp287, atslab_0) ; tmp290 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_valprim_typ) ; /* tmp286 = */ emit_valprim_argref_27 (arg0, tmp289, tmp290) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp287)->tag != 2) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp291 = ats_caselptrlab_mac(anairiats_sum_6, tmp287, atslab_0) ; /* tmp286 = */ emit_valprim_arg_26 (arg0, tmp291) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp287)->tag != 3) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp292 = ats_caselptrlab_mac(anairiats_sum_8, tmp287, atslab_0) ; /* tmp286 = */ emit_valprim_bool_28 (arg0, tmp292) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp287)->tag != 4) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_1) ; /* tmp294 = */ atspre_fprint_string (arg0, ATSstrcst("ats_castfn_mac(")) ; tmp296 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_valprim_typ) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp296) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp293) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp287)->tag != 5) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_9, tmp287, atslab_0) ; /* tmp286 = */ emit_valprim_char_29 (arg0, tmp299) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp287)->tag != 6) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_10, tmp287, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_10, tmp287, atslab_1) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_10, tmp287, atslab_2) ; /* tmp286 = */ emit_valprim_clo_make_31 (arg0, tmp300, tmp301, tmp302) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp287)->tag != 7) { goto __ats_lab_64_0 ; } __ats_lab_61_1: tmp303 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; do { /* branch: __ats_lab_62 */ __ats_lab_62_0: __ats_lab_62_1: tmp304 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (tmp303) ; if (!tmp304) { goto __ats_lab_63_1 ; } /* tmp305 = */ atspre_fprint_char (arg0, '&') ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp303) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp303) ; break ; } while (0) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp287)->tag != 8) { goto __ats_lab_67_0 ; } __ats_lab_64_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_0) ; tmp307 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_1) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp307)->tag != 0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp308 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename (tmp306) ; tmp309 = atsopt_filename_full (tmp308) ; tmp310 = atspre_string_length (tmp309) ; /* tmp286 = */ atsopt_emit_valprim_string (arg0, tmp309, tmp310) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (((ats_sum_ptr_type)tmp307)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: /* tmp311 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp312 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (arg0, tmp306) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; break ; } while (0) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp287)->tag != 9) { goto __ats_lab_70_0 ; } __ats_lab_67_1: tmp313 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (tmp313) ; tmp315 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some (tmp314) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: __ats_lab_68_1: tmp316 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp314) ; if (!tmp316) { goto __ats_lab_69_1 ; } /* tmp317 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptrget_mac(")) ; tmp319 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (tmp313) ; /* tmp318 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp319) ; /* tmp320 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp321 = */ atspre_fprintf_exn (arg0, ATSstrcst("env%i"), tmp315) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: /* tmp286 = */ atspre_fprintf_exn (arg0, ATSstrcst("env%i"), tmp315) ; break ; } while (0) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp287)->tag != 10) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ atspre_fprint_string (arg0, tmp322) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp287)->tag != 11) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp323 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; tmp324 = ats_ptrget_mac(ats_ptr_type, tmp323) ; arg0 = arg0 ; arg1 = tmp324 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim ; // tail call break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp287)->tag != 12) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ atsopt_emit_valprim_float (arg0, tmp325) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp287)->tag != 13) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ atsopt_emit_valprim_float (arg0, tmp326) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp287)->tag != 14) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp328 = */ atspre_fprint_string (arg0, ATSstrcst("&")) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp327) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp287)->tag != 15) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp329 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp329) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp287)->tag != 16) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_0) ; /* tmp286 = */ atsopt_emit_valprim_intsp (arg0, tmp330) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp287)->tag != 17) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ emit_valprim_ptrof_33 (arg0, tmp331) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp287)->tag != 18) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_0) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_1) ; /* tmp334 = */ atspre_fprint_char (arg0, '&') ; /* tmp286 = */ emit_valprim_select_ptr_45 (arg0, tmp332, tmp333) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp287)->tag != 19) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_0) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_7, tmp287, atslab_1) ; /* tmp337 = */ atspre_fprint_char (arg0, '&') ; /* tmp286 = */ emit_valprim_select_var_44 (arg0, tmp335, tmp336) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp287)->tag != 20) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp339 = */ atspre_fprint_string (arg0, ATSstrcst("sizeof(")) ; /* tmp340 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp338) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp287)->tag != 21) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp341 = ats_caselptrlab_mac(anairiats_sum_11, tmp287, atslab_0) ; tmp342 = ats_caselptrlab_mac(anairiats_sum_11, tmp287, atslab_1) ; tmp344 = atspre_igte (ats_castfn_mac(ats_int_type, tmp342), 0) ; /* tmp343 = */ atspre_assert (tmp344) ; tmp345 = atspre_size1_of_int1 (ats_castfn_mac(ats_int_type, tmp342)) ; /* tmp286 = */ atsopt_emit_valprim_string (arg0, tmp341, tmp345) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp287)->tag != 22) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp346) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp287)->tag != 23) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp347 = ats_caselptrlab_mac(anairiats_sum_1, tmp287, atslab_0) ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp347) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp287)->tag != 24) { goto __ats_lab_85_0 ; } __ats_lab_84_1: /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("?top")) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: // if (((ats_sum_ptr_type)tmp287)->tag != 25) { ats_deadcode_failure_handle () ; } __ats_lab_85_1: /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("?void")) ; break ; } while (0) ; return /* (tmp286) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 32146(line=1116, offs=7) -- 32433(line=1124, offs=6) */ ATSstaticdec() ats_void_type aux_49 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; // ATSlocal_void (tmp352) ; ATSlocal (ats_bool_type, tmp353) ; // ATSlocal_void (tmp354) ; ATSlocal (ats_int_type, tmp355) ; __ats_lab_aux_49: do { /* branch: __ats_lab_86 */ __ats_lab_86_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp353 = atspre_gt_int_int (arg1, 0) ; if (tmp353) { /* tmp352 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp354 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp350) ; tmp355 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp355 ; arg2 = tmp351 ; goto __ats_lab_aux_49 ; // tail call break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_87_1: break ; } while (0) ; return /* (tmp349) */ ; } /* end of [aux_49] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 32118(line=1115, offs=21) -- 32476(line=1127, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp348) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst: /* tmp348 = */ aux_49 (arg0, 0, arg1) ; return /* (tmp348) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 32553(line=1133, offs=3) -- 33721(line=1158, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; // ATSlocal_void (tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_int_type, tmp360) ; // ATSlocal_void (tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; // ATSlocal_void (tmp369) ; // ATSlocal_void (tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont: do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp358 = */ atspre_fprint_string (arg0, ATSstrcst("goto ")) ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp357) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp359 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("goto ")) ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint (arg0, tmp359, tmp360) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp362 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp363 = */ atspre_fprint_string (arg0, ATSstrcst("ats_caseof_failure_handle (\"")) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (arg0, tmp362) ; /* tmp356 = */ atspre_fprint_string (arg0, ATSstrcst("\")")) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp365 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; /* tmp366 = */ atspre_fprint_string (arg0, ATSstrcst("ats_funarg_failure_handle (\"")) ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (arg0, tmp365) ; /* tmp356 = */ atspre_fprint_string (arg0, ATSstrcst("\")")) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp369 = */ atspre_fprint_string (arg0, ATSstrcst("ats_raise_exn (")) ; /* tmp370 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp368) ; /* tmp356 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_matpnt (arg0, tmp371) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: /* tmp356 = */ atspre_fprint_string (arg0, ATSstrcst("ats_deadcode_failure_handle ()")) ; break ; } while (0) ; return /* (tmp356) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 33950(line=1170, offs=12) -- 37836(line=1279, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_patck (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp372) ; ATSlocal (ats_bool_type, tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; ATSlocal (ats_char_type, tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_bool_type, tmp388) ; ATSlocal (ats_bool_type, tmp389) ; ATSlocal (ats_bool_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (anairiats_rec_12, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_bool_type, tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; ATSlocal (ats_int_type, tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_int_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; // ATSlocal_void (tmp424) ; // ATSlocal_void (tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; // ATSlocal_void (tmp434) ; // ATSlocal_void (tmp435) ; // ATSlocal_void (tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; // ATSlocal_void (tmp441) ; ATSlocal (ats_size_type, tmp442) ; // ATSlocal_void (tmp443) ; // ATSlocal_void (tmp444) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_patck: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; /* tmp374 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; if (tmp373) { /* tmp375 = */ atspre_fprint_char (arg0, '!') ; } else { /* empty */ } /* end of [if] */ /* tmp376 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp377 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp378 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp379 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_0) ; /* tmp380 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp382 = */ atspre_fprint_string (arg0, ATSstrcst(" != ")) ; /* tmp383 = */ emit_valprim_char_29 (arg0, tmp379) ; /* tmp384 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp385 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_103_0 ; } __ats_lab_97_1: tmp386 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp387 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (tmp386) ; do { /* branch: __ats_lab_98 */ __ats_lab_98_0: __ats_lab_98_1: tmp388 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular (tmp387) ; if (!tmp388) { goto __ats_lab_99_1 ; } break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: tmp389 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike (tmp387) ; if (!tmp389) { goto __ats_lab_102_1 ; } tmp391 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_islst (tmp387) ; do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (tmp391 == (ats_sum_ptr_type)0) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_13, tmp391, atslab_0) ; tmp393 = ats_select_mac(tmp392, atslab_0) ; tmp390 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp386, tmp393) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: // if (tmp391 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_101_1: tmp390 = ats_false_bool ; break ; } while (0) ; tmp394 = atspre_neg_bool (tmp390) ; /* tmp395 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; if (tmp390) { /* tmp397 = */ atspre_fprint_string (arg0, ATSstrcst(" != ")) ; } else { /* empty */ } /* end of [if] */ if (tmp394) { /* tmp398 = */ atspre_fprint_string (arg0, ATSstrcst(" == ")) ; } else { /* empty */ } /* end of [if] */ /* tmp399 = */ atspre_fprint_string (arg0, ATSstrcst("(ats_sum_ptr_type)0) { ")) ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: __ats_lab_102_1: /* tmp401 = */ atspre_fprint_string (arg0, ATSstrcst("if (((ats_sum_ptr_type)")) ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp403 = */ atspre_fprint_string (arg0, ATSstrcst(")->tag != ")) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (tmp386) ; /* tmp404 = */ atspre_fprint_int (arg0, tmp405) ; /* tmp406 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; } while (0) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)arg2)->tag != 3) { goto __ats_lab_106_0 ; } __ats_lab_103_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (tmp408) ; do { /* branch: __ats_lab_104 */ __ats_lab_104_0: __ats_lab_104_1: tmp410 = atspre_eq_int_int (tmp409, 0) ; if (!tmp410) { goto __ats_lab_105_1 ; } /* tmp411 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp413 = */ atspre_fprint_string (arg0, ATSstrcst(" != &")) ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp408) ; /* tmp415 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp416 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: __ats_lab_105_1: /* tmp417 = */ atspre_fprint_string (arg0, ATSstrcst("if (((ats_exn_ptr_type)")) ; /* tmp418 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp419 = */ atspre_fprint_string (arg0, ATSstrcst(")->tag != ")) ; /* tmp420 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, tmp408) ; /* tmp421 = */ atspre_fprint_string (arg0, ATSstrcst(".tag) { ")) ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; } while (0) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; /* tmp424 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp426 = */ atspre_fprint_string (arg0, ATSstrcst(" != ")) ; /* tmp427 = */ atsopt_emit_valprim_float (arg0, tmp423) ; /* tmp428 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)arg2)->tag != 5) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; /* tmp431 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp432 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp433 = */ atspre_fprint_string (arg0, ATSstrcst(" != ")) ; /* tmp434 = */ emit_valprim_int_32 (arg0, tmp430) ; /* tmp435 = */ atspre_fprint_string (arg0, ATSstrcst(") { ")) ; /* tmp436 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: // if (((ats_sum_ptr_type)arg2)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_108_1: tmp437 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; /* tmp438 = */ atspre_fprint_string (arg0, ATSstrcst("if (__strcmpats(")) ; /* tmp439 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg1) ; /* tmp440 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; tmp442 = atspre_string_length (tmp437) ; /* tmp441 = */ atsopt_emit_valprim_string (arg0, tmp437, tmp442) ; /* tmp443 = */ atspre_fprint_string (arg0, ATSstrcst(")) { ")) ; /* tmp444 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, arg3) ; /* tmp372 = */ atspre_fprint_string (arg0, ATSstrcst(" ; }")) ; break ; } while (0) ; return /* (tmp372) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_patck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 38020(line=1290, offs=3) -- 38419(line=1300, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branch (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branch: tmp446 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_branch_inss) ; /* tmp447 = */ atspre_fprint_string (arg0, ATSstrcst("/* branch: ")) ; tmp449 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_branch_lab) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp449) ; /* tmp450 = */ atspre_fprint_string (arg0, ATSstrcst(" */")) ; do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (tmp446 == (ats_sum_ptr_type)0) { goto __ats_lab_110_0 ; } __ats_lab_109_1: /* tmp451 = */ atspre_fprint_char (arg0, '\n') ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: // if (tmp446 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_110_1: break ; } while (0) ; /* tmp452 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp446) ; /* tmp445 = */ atspre_fprint_string (arg0, ATSstrcst("\nbreak ;\n")) ; return /* (tmp445) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branch] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 38595(line=1307, offs=7) -- 38886(line=1316, offs=24) */ ATSstaticdec() ats_void_type aux_54 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; // ATSlocal_void (tmp457) ; ATSlocal (ats_bool_type, tmp458) ; // ATSlocal_void (tmp459) ; ATSlocal (ats_int_type, tmp460) ; __ats_lab_aux_54: do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp455 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp456 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp458 = atspre_gt_int_int (arg1, 0) ; if (tmp458) { /* tmp457 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp459 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branch (arg0, tmp455) ; tmp460 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp460 ; arg2 = tmp456 ; goto __ats_lab_aux_54 ; // tail call break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_112_1: break ; } while (0) ; return /* (tmp454) */ ; } /* end of [aux_54] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 38567(line=1306, offs=20) -- 38931(line=1320, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst: /* tmp453 = */ aux_54 (arg0, 0, arg1) ; return /* (tmp453) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 39057(line=1329, offs=6) -- 39602(line=1345, offs=6) */ ATSstaticdec() ats_void_type aux_envmap_56 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_bool_type, tmp465) ; // ATSlocal_void (tmp466) ; // ATSlocal_void (tmp467) ; // ATSlocal_void (tmp468) ; // ATSlocal_void (tmp469) ; __ats_lab_aux_envmap_56: tmp463 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__envmap_find (arg1, arg2) ; do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (tmp463 == (ats_sum_ptr_type)0) { goto __ats_lab_116_0 ; } __ats_lab_113_1: tmp464 = ats_caselptrlab_mac(anairiats_sum_2, tmp463, atslab_0) ; ATS_FREE(tmp463) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp465 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (arg2) ; if (!tmp465) { goto __ats_lab_115_1 ; } /* tmp462 = */ emit_valprim_ptrof_33 (arg0, tmp464) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: __ats_lab_115_1: /* tmp462 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp464) ; break ; } while (0) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (tmp463 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: /* tmp466 = */ prerr_interror_0 () ; /* tmp467 = */ atspre_prerr_string (ATSstrcst(": emit_cloenv: None_vt: d2v = ")) ; /* tmp468 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg2) ; /* tmp469 = */ atspre_prerr_newline () ; /* tmp462 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp462) */ ; } /* end of [aux_envmap_56] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 39631(line=1347, offs=7) -- 40197(line=1365, offs=6) */ ATSstaticdec() ats_int_type aux_main_57 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_int_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; // ATSlocal_void (tmp473) ; ATSlocal (ats_bool_type, tmp474) ; // ATSlocal_void (tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_int_type, tmp477) ; ATSlocal (ats_int_type, tmp478) ; __ats_lab_aux_main_57: do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_120_0 ; } __ats_lab_117_1: tmp471 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_0) ; tmp472 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_1) ; ATS_FREE(arg3) ; tmp474 = atspre_gt_int_int (arg2, 0) ; if (tmp474) { /* tmp473 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp476 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find (tmp471) ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (tmp476 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp477 = ats_caselptrlab_mac(anairiats_sum_15, tmp476, atslab_0) ; ATS_FREE(tmp476) ; /* tmp475 = */ atspre_fprintf_exn (arg0, ATSstrcst("env%i"), tmp477) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (tmp476 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: /* tmp475 = */ aux_envmap_56 (arg0, arg1, tmp471) ; break ; } while (0) ; tmp478 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp478 ; arg3 = tmp472 ; arg4 = arg4 ; goto __ats_lab_aux_main_57 ; // tail call break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_120_1: tmp470 = arg2 ; break ; } while (0) ; return (tmp470) ; } /* end of [aux_main_57] */ typedef struct { ats_fun_ptr_type closure_fun ; } aux_main_57_closure_type ; ats_int_type aux_main_57_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { return aux_main_57 (arg0, arg1, arg2, arg3, arg4) ; } /* end of function */ ATSinline() ats_void_type aux_main_57_closure_init (aux_main_57_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_main_57_clofun ; return ; } /* end of function */ ats_clo_ptr_type aux_main_57_closure_make () { aux_main_57_closure_type *p_clo = ATS_MALLOC(sizeof(aux_main_57_closure_type)) ; aux_main_57_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 39007(line=1325, offs=17) -- 40450(line=1374, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp461) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_int_type, tmp480) ; ATSlocal (ats_int_type, tmp481) ; // ATSlocal_void (tmp482) ; ATSlocal (ats_bool_type, tmp483) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv: tmp479 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make (arg2) ; /* ats_int_type tmp480 ; */ tmp480 = 0 ; tmp481 = aux_main_57 (arg0, arg1, arg3, tmp479, (&tmp480)) ; tmp483 = atspre_gt_int_int (tmp480, 0) ; if (tmp483) { /* tmp482 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp461 = atspre_sub_int_int (tmp481, arg3) ; return (tmp461) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 42180(line=1428, offs=11) -- 43286(line=1456, offs=10) */ ATSstaticdec() ats_void_type aux_arg_59 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; // ATSlocal_void (tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; // ATSlocal_void (tmp522) ; // ATSlocal_void (tmp523) ; ATSlocal (ats_int_type, tmp524) ; __ats_lab_aux_arg_59: do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_130_0 ; } __ats_lab_127_1: tmp511 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp512 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp514 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp511), atslab_valprim_node) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)tmp514)->tag != 24) { goto __ats_lab_129_0 ; } __ats_lab_128_1: break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: __ats_lab_129_1: /* tmp515 = */ atspre_fprint_char (arg0, '\n') ; /* tmp516 = */ atspre_fprint_string (arg0, ATSstrcst("ats_selptrset_mac(")) ; /* tmp517 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, env1) ; /* tmp518 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp519 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, env0) ; /* tmp520 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp521 = */ atspre_fprintf_exn (arg0, ATSstrcst("atslab_%i"), arg1) ; /* tmp522 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp523 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp511) ; /* tmp513 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; } while (0) ; tmp524 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp524 ; arg2 = tmp512 ; goto __ats_lab_aux_arg_59 ; // tail call break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_130_1: break ; } while (0) ; return /* (tmp510) */ ; } /* end of [aux_arg_59] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_arg_59_closure_type ; ats_void_type aux_arg_59_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { aux_arg_59 (((aux_arg_59_closure_type*)cloptr)->closure_env_0, ((aux_arg_59_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_arg_59_closure_init (aux_arg_59_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_arg_59_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_arg_59_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_arg_59_closure_type *p_clo = ATS_MALLOC(sizeof(aux_arg_59_closure_type)) ; aux_arg_59_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 40501(line=1379, offs=1) -- 43894(line=1476, offs=4) */ ATSstaticdec() ats_void_type emit_move_con_58 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; // ATSlocal_void (tmp489) ; ATSlocal (ats_bool_type, tmp490) ; // ATSlocal_void (tmp491) ; // ATSlocal_void (tmp492) ; // ATSlocal_void (tmp493) ; // ATSlocal_void (tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; // ATSlocal_void (tmp497) ; // ATSlocal_void (tmp498) ; // ATSlocal_void (tmp499) ; // ATSlocal_void (tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_bool_type, tmp502) ; ATSlocal (ats_bool_type, tmp503) ; // ATSlocal_void (tmp504) ; // ATSlocal_void (tmp505) ; // ATSlocal_void (tmp506) ; // ATSlocal_void (tmp507) ; // ATSlocal_void (tmp508) ; ATSlocal (ats_int_type, tmp509) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_bool_type, tmp526) ; // ATSlocal_void (tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; __ats_lab_emit_move_con_58: do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_121_1: /* tmp485 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp486 = */ atspre_fprint_string (arg0, ATSstrcst(" = ATS_MALLOC(sizeof(")) ; /* tmp487 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, arg2) ; /* tmp488 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;")) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: __ats_lab_122_1: tmp490 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (arg3) ; if (!tmp490) { goto __ats_lab_123_1 ; } /* tmp491 = */ atspre_fprint_char (arg0, '\n') ; /* tmp492 = */ atspre_fprint_string (arg0, ATSstrcst("((ats_exn_ptr_type)")) ; /* tmp493 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp494 = */ atspre_fprint_string (arg0, ATSstrcst(")->tag = ")) ; /* tmp495 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, arg3) ; /* tmp496 = */ atspre_fprint_string (arg0, ATSstrcst(".tag ;\n")) ; /* tmp497 = */ atspre_fprint_string (arg0, ATSstrcst("((ats_exn_ptr_type)")) ; /* tmp498 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp499 = */ atspre_fprint_string (arg0, ATSstrcst(")->name = ")) ; /* tmp500 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, arg3) ; /* tmp489 = */ atspre_fprint_string (arg0, ATSstrcst(".name ;")) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: __ats_lab_123_1: tmp501 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (arg3) ; do { /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: tmp502 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular (tmp501) ; if (!tmp502) { goto __ats_lab_125_1 ; } break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: __ats_lab_125_1: tmp503 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike (tmp501) ; if (!tmp503) { goto __ats_lab_126_1 ; } break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: /* tmp504 = */ atspre_fprint_char (arg0, '\n') ; /* tmp505 = */ atspre_fprint_string (arg0, ATSstrcst("((ats_sum_ptr_type)")) ; /* tmp506 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp507 = */ atspre_fprint_string (arg0, ATSstrcst(")->tag = ")) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (arg3) ; /* tmp508 = */ atspre_fprint_int (arg0, tmp509) ; /* tmp489 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; } while (0) ; break ; } while (0) ; /* tmp484 = */ aux_arg_59 (arg1, arg2, arg0, 0, arg4) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp525 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (arg3) ; do { /* branch: __ats_lab_132 */ __ats_lab_132_0: __ats_lab_132_1: tmp526 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike (tmp525) ; if (!tmp526) { goto __ats_lab_133_1 ; } /* tmp527 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp484 = */ atspre_fprint_string (arg0, ATSstrcst(" = (ats_sum_ptr_type)0 ;")) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: __ats_lab_133_1: /* tmp528 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp529 = */ atspre_fprint_string (arg0, ATSstrcst(" = (ats_sum_ptr_type)(&")) ; /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2con (arg0, arg3) ; /* tmp484 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp484) */ ; } /* end of [emit_move_con_58] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 43946(line=1480, offs=4) -- 44659(line=1501, offs=4) */ ATSstaticdec() ats_void_type emit_instr_assgn_arr_60 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; // ATSlocal_void (tmp535) ; // ATSlocal_void (tmp536) ; // ATSlocal_void (tmp537) ; // ATSlocal_void (tmp538) ; // ATSlocal_void (tmp539) ; // ATSlocal_void (tmp540) ; // ATSlocal_void (tmp541) ; __ats_lab_emit_instr_assgn_arr_60: /* tmp532 = */ atspre_fprint_string (arg0, ATSstrcst("/* array initialization */\n")) ; /* tmp533 = */ atspre_fprint_string (arg0, ATSstrcst("atspre_array_ptr_initialize_elt_tsz (")) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, arg1) ; /* tmp535 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp536 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg2) ; /* tmp537 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp538 = */ atspre_fprint_string (arg0, ATSstrcst("&")) ; /* tmp539 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, arg3) ; /* tmp540 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp541 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg4) ; /* tmp531 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; return /* (tmp531) */ ; } /* end of [emit_instr_assgn_arr_60] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 44974(line=1515, offs=4) -- 45685(line=1535, offs=4) */ ATSstaticdec() ats_void_type emit_instr_arr_heap_61 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp542) ; // ATSlocal_void (tmp543) ; // ATSlocal_void (tmp544) ; // ATSlocal_void (tmp545) ; // ATSlocal_void (tmp546) ; // ATSlocal_void (tmp547) ; // ATSlocal_void (tmp548) ; // ATSlocal_void (tmp549) ; // ATSlocal_void (tmp550) ; // ATSlocal_void (tmp551) ; // ATSlocal_void (tmp552) ; __ats_lab_emit_instr_arr_heap_61: /* tmp543 = */ atspre_fprint_string (arg0, ATSstrcst("/* array allocation on heap */\n")) ; /* tmp544 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp545 = */ atspre_fprint_string (arg0, ATSstrcst(".atslab_2 = atspre_array_ptr_alloc_tsz (")) ; /* tmp546 = */ atspre_fprint_int (arg0, arg2) ; /* tmp547 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(")) ; /* tmp548 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, arg3) ; /* tmp549 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;\n")) ; /* tmp550 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp551 = */ atspre_fprint_string (arg0, ATSstrcst(".atslab_3 = ")) ; /* tmp552 = */ atspre_fprint_int (arg0, arg2) ; /* tmp542 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n")) ; return /* (tmp542) */ ; } /* end of [emit_instr_arr_heap_61] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 45743(line=1539, offs=4) -- 46392(line=1558, offs=4) */ ATSstaticdec() ats_void_type emit_instr_arr_stack_62 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp553) ; // ATSlocal_void (tmp554) ; // ATSlocal_void (tmp555) ; // ATSlocal_void (tmp556) ; ATSlocal (ats_bool_type, tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; __ats_lab_emit_instr_arr_stack_62: /* tmp554 = */ atspre_fprint_string (arg0, ATSstrcst("/* array allocation on stack */\n")) ; /* tmp555 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: __ats_lab_134_1: tmp557 = atspre_gt_int_int (arg2, 0) ; if (!tmp557) { goto __ats_lab_135_1 ; } /* tmp556 = */ atspre_fprint_string (arg0, ATSstrcst(" = ATS_ALLOCA2(")) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: /* tmp556 = */ atspre_fprint_string (arg0, ATSstrcst(" = ATS_MALLOC2(")) ; break ; } while (0) ; /* tmp558 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg3) ; /* tmp559 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(")) ; /* tmp560 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, arg4) ; /* tmp553 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;")) ; return /* (tmp553) */ ; } /* end of [emit_instr_arr_stack_62] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 46451(line=1562, offs=4) -- 46552(line=1565, offs=4) */ ATSstaticdec() ats_bool_type d2cst_fun_is_void_63 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; __ats_lab_d2cst_fun_is_void_63: tmp562 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some (arg0) ; tmp561 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void (tmp562) ; return (tmp561) ; } /* end of [d2cst_fun_is_void_63] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 46587(line=1567, offs=4) -- 46682(line=1570, offs=4) */ ATSstaticdec() ats_bool_type funlab_fun_is_void_64 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; __ats_lab_funlab_fun_is_void_64: tmp564 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res (arg0) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void (tmp564) ; return (tmp563) ; } /* end of [funlab_fun_is_void_64] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 46719(line=1572, offs=5) -- 50411(line=1679, offs=4) */ ATSstaticdec() ats_void_type emit_instr_call_65 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp565) ; ATSlocal (ats_bool_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; // ATSlocal_void (tmp571) ; // ATSlocal_void (tmp572) ; // ATSlocal_void (tmp573) ; // ATSlocal_void (tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_bool_type, tmp577) ; // ATSlocal_void (tmp578) ; // ATSlocal_void (tmp579) ; // ATSlocal_void (tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; // ATSlocal_void (tmp585) ; // ATSlocal_void (tmp586) ; ATSlocal (ats_int_type, tmp587) ; // ATSlocal_void (tmp588) ; ATSlocal (ats_bool_type, tmp589) ; // ATSlocal_void (tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; // ATSlocal_void (tmp592) ; // ATSlocal_void (tmp593) ; // ATSlocal_void (tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; // ATSlocal_void (tmp604) ; // ATSlocal_void (tmp605) ; // ATSlocal_void (tmp606) ; // ATSlocal_void (tmp607) ; // ATSlocal_void (tmp608) ; // ATSlocal_void (tmp609) ; // ATSlocal_void (tmp610) ; ATSlocal (ats_bool_type, tmp611) ; // ATSlocal_void (tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; // ATSlocal_void (tmp615) ; // ATSlocal_void (tmp616) ; // ATSlocal_void (tmp617) ; // ATSlocal_void (tmp618) ; // ATSlocal_void (tmp619) ; // ATSlocal_void (tmp620) ; // ATSlocal_void (tmp621) ; // ATSlocal_void (tmp622) ; // ATSlocal_void (tmp623) ; // ATSlocal_void (tmp624) ; __ats_lab_emit_instr_call_65: tmp567 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg3), atslab_valprim_node) ; do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp567)->tag != 7) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp568 = ats_caselptrlab_mac(anairiats_sum_1, tmp567, atslab_0) ; tmp566 = d2cst_fun_is_void_63 (tmp568) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp567)->tag != 6) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp569 = ats_caselptrlab_mac(anairiats_sum_10, tmp567, atslab_1) ; tmp566 = funlab_fun_is_void_64 (tmp569) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp567)->tag != 14) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_1, tmp567, atslab_0) ; tmp566 = funlab_fun_is_void_64 (tmp570) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: __ats_lab_139_1: tmp566 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void (arg2) ; break ; } while (0) ; if (tmp566) { /* tmp571 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; } else { /* empty */ } /* end of [if] */ /* tmp572 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp573 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; if (tmp566) { /* tmp574 = */ atspre_fprint_string (arg0, ATSstrcst("*/ ")) ; } else { /* empty */ } /* end of [if] */ tmp575 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg3), atslab_valprim_node) ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp575)->tag != 7) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp576 = ats_caselptrlab_mac(anairiats_sum_1, tmp575, atslab_0) ; tmp577 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (tmp576) ; if (!tmp577) { goto __ats_lab_146_1 ; } /* tmp578 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp576) ; /* tmp579 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; /* tmp580 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, arg4) ; /* tmp565 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)tmp575)->tag != 6) { goto __ats_lab_144_0 ; } __ats_lab_141_1: tmp581 = ats_caselptrlab_mac(anairiats_sum_10, tmp575, atslab_1) ; tmp582 = ats_caselptrlab_mac(anairiats_sum_10, tmp575, atslab_2) ; tmp583 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (tmp581) ; tmp584 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp583) ; /* tmp585 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp581) ; /* tmp586 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; tmp587 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_cloenv (arg0, tmp582, tmp584, 0) ; tmp589 = atspre_gt_int_int (tmp587, 0) ; if (tmp589) { do { /* branch: __ats_lab_142 */ __ats_lab_142_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_143_0 ; } __ats_lab_142_1: /* tmp588 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: __ats_lab_143_1: break ; } while (0) ; } else { /* empty */ } /* end of [if] */ /* tmp590 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, arg4) ; /* tmp565 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp575)->tag != 14) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_1, tmp575, atslab_0) ; /* tmp592 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp591) ; /* tmp593 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; /* tmp594 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, arg4) ; /* tmp565 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp575)->tag != 11) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp595 = ats_caselptrlab_mac(anairiats_sum_1, tmp575, atslab_0) ; tmp596 = ats_ptrget_mac(ats_ptr_type, tmp595) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp596 ; arg4 = arg4 ; goto __ats_lab_emit_instr_call_65 ; // tail call break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: __ats_lab_146_1: tmp597 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (arg2) ; tmp598 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp597), atslab_hityp_node) ; do { /* branch: __ats_lab_147 */ __ats_lab_147_0: if (((ats_sum_ptr_type)tmp598)->tag != 2) { goto __ats_lab_150_0 ; } __ats_lab_147_1: tmp599 = ats_caselptrlab_mac(anairiats_sum_16, tmp598, atslab_0) ; tmp600 = ats_caselptrlab_mac(anairiats_sum_16, tmp598, atslab_1) ; tmp601 = ats_caselptrlab_mac(anairiats_sum_16, tmp598, atslab_2) ; do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (tmp599 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp602 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode (tmp600) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp601) ; /* tmp604 = */ atspre_fprint_string (arg0, ATSstrcst("((")) ; /* tmp605 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_clofun (arg0, tmp602, tmp603) ; /* tmp606 = */ atspre_fprint_string (arg0, ATSstrcst(")(ats_closure_fun(")) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg3) ; /* tmp608 = */ atspre_fprint_string (arg0, ATSstrcst("))) (")) ; /* tmp609 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg3) ; tmp611 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (arg4) ; if (tmp611) { /* tmp610 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp612 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, arg4) ; /* tmp565 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: // if (tmp599 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_149_1: tmp613 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode (tmp600) ; tmp614 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp601) ; /* tmp615 = */ atspre_fprint_string (arg0, ATSstrcst("((")) ; /* tmp616 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_hityp_fun (arg0, tmp613, tmp614) ; /* tmp617 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; /* tmp618 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, arg3) ; /* tmp619 = */ atspre_fprint_string (arg0, ATSstrcst(") (")) ; /* tmp620 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprimlst (arg0, arg4) ; /* tmp565 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; } while (0) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: __ats_lab_150_1: /* tmp621 = */ prerr_interror_0 () ; /* tmp622 = */ atspre_prerr_string (ATSstrcst(": emit_instr_call: hit_fun = ")) ; /* tmp623 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (tmp597) ; /* tmp624 = */ atspre_prerr_newline () ; /* tmp565 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return /* (tmp565) */ ; } /* end of [emit_instr_call_65] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 60769(line=1960, offs=11) -- 61560(line=1980, offs=8) */ ATSstaticdec() ats_void_type aux_67 (ats_ptr_type env0, ats_bool_type env1, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; // ATSlocal_void (tmp829) ; // ATSlocal_void (tmp830) ; // ATSlocal_void (tmp831) ; // ATSlocal_void (tmp832) ; // ATSlocal_void (tmp833) ; // ATSlocal_void (tmp834) ; // ATSlocal_void (tmp835) ; // ATSlocal_void (tmp836) ; // ATSlocal_void (tmp837) ; __ats_lab_aux_67: do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp826 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_0) ; tmp827 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_1) ; tmp828 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_2) ; /* tmp829 = */ atspre_fprint_string (arg0, ATSstrcst("ats_selptrset_mac(")) ; /* tmp830 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, env0) ; /* tmp831 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp832 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; /* tmp833 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp834 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_labelext (arg0, env1, tmp826) ; /* tmp835 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp836 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp827) ; /* tmp837 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp828 ; goto __ats_lab_aux_67 ; // tail call break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_180_1: break ; } while (0) ; return /* (tmp825) */ ; } /* end of [aux_67] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_bool_type closure_env_1 ; } aux_67_closure_type ; ats_void_type aux_67_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { aux_67 (((aux_67_closure_type*)cloptr)->closure_env_0, ((aux_67_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_67_closure_init (aux_67_closure_type *p_clo, ats_ptr_type env0, ats_bool_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_67_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_67_closure_make (ats_ptr_type env0, ats_bool_type env1) { aux_67_closure_type *p_clo = ATS_MALLOC(sizeof(aux_67_closure_type)) ; aux_67_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 61979(line=1991, offs=11) -- 62681(line=2009, offs=10) */ ATSstaticdec() ats_void_type aux_68 (ats_bool_type env0, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; // ATSlocal_void (tmp850) ; // ATSlocal_void (tmp851) ; // ATSlocal_void (tmp852) ; // ATSlocal_void (tmp853) ; // ATSlocal_void (tmp854) ; // ATSlocal_void (tmp855) ; __ats_lab_aux_68: do { /* branch: __ats_lab_182 */ __ats_lab_182_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp847 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_0) ; tmp848 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_1) ; tmp849 = ats_caselptrlab_mac(anairiats_sum_23, arg2, atslab_2) ; /* tmp850 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, arg1) ; if (env0) { /* tmp851 = */ atspre_fprint_string (arg0, ATSstrcst(".")) ; } else { /* tmp851 = */ atspre_fprint_string (arg0, ATSstrcst(".atslab_")) ; } /* end of [if] */ /* tmp852 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_label (arg0, tmp847) ; /* tmp853 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp854 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp848) ; /* tmp855 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n")) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp849 ; goto __ats_lab_aux_68 ; // tail call break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_183_1: break ; } while (0) ; return /* (tmp846) */ ; } /* end of [aux_68] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_bool_type closure_env_0 ; } aux_68_closure_type ; ats_void_type aux_68_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { aux_68 (((aux_68_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_68_closure_init (aux_68_closure_type *p_clo, ats_bool_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_68_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_68_closure_make (ats_bool_type env0) { aux_68_closure_type *p_clo = ATS_MALLOC(sizeof(aux_68_closure_type)) ; aux_68_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 50489(line=1685, offs=3) -- 69709(line=2202, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp625) ; ATSlocal (ats_int_type, tmp626) ; // ATSlocal_void (tmp627) ; ATSlocal (ats_bool_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_int_type, tmp630) ; // ATSlocal_void (tmp631) ; ATSlocal (ats_bool_type, tmp632) ; // ATSlocal_void (tmp633) ; // ATSlocal_void (tmp634) ; // ATSlocal_void (tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_int_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_int_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; // ATSlocal_void (tmp652) ; // ATSlocal_void (tmp653) ; // ATSlocal_void (tmp654) ; // ATSlocal_void (tmp655) ; // ATSlocal_void (tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; // ATSlocal_void (tmp662) ; // ATSlocal_void (tmp663) ; // ATSlocal_void (tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; // ATSlocal_void (tmp668) ; // ATSlocal_void (tmp669) ; // ATSlocal_void (tmp670) ; // ATSlocal_void (tmp671) ; // ATSlocal_void (tmp672) ; // ATSlocal_void (tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; // ATSlocal_void (tmp676) ; // ATSlocal_void (tmp677) ; // ATSlocal_void (tmp678) ; // ATSlocal_void (tmp679) ; // ATSlocal_void (tmp680) ; // ATSlocal_void (tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; // ATSlocal_void (tmp684) ; // ATSlocal_void (tmp685) ; // ATSlocal_void (tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; // ATSlocal_void (tmp689) ; // ATSlocal_void (tmp690) ; // ATSlocal_void (tmp691) ; // ATSlocal_void (tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; // ATSlocal_void (tmp694) ; // ATSlocal_void (tmp695) ; // ATSlocal_void (tmp696) ; // ATSlocal_void (tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; // ATSlocal_void (tmp700) ; // ATSlocal_void (tmp701) ; // ATSlocal_void (tmp702) ; // ATSlocal_void (tmp703) ; // ATSlocal_void (tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; // ATSlocal_void (tmp707) ; // ATSlocal_void (tmp708) ; // ATSlocal_void (tmp709) ; // ATSlocal_void (tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; // ATSlocal_void (tmp712) ; // ATSlocal_void (tmp713) ; // ATSlocal_void (tmp714) ; // ATSlocal_void (tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; // ATSlocal_void (tmp717) ; // ATSlocal_void (tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; // ATSlocal_void (tmp722) ; // ATSlocal_void (tmp723) ; // ATSlocal_void (tmp724) ; // ATSlocal_void (tmp725) ; ATSlocal (ats_bool_type, tmp726) ; // ATSlocal_void (tmp727) ; // ATSlocal_void (tmp728) ; // ATSlocal_void (tmp729) ; // ATSlocal_void (tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; // ATSlocal_void (tmp732) ; // ATSlocal_void (tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; // ATSlocal_void (tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; // ATSlocal_void (tmp738) ; // ATSlocal_void (tmp739) ; // ATSlocal_void (tmp740) ; // ATSlocal_void (tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; // ATSlocal_void (tmp743) ; // ATSlocal_void (tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; // ATSlocal_void (tmp748) ; // ATSlocal_void (tmp749) ; // ATSlocal_void (tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; // ATSlocal_void (tmp754) ; // ATSlocal_void (tmp755) ; // ATSlocal_void (tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; // ATSlocal_void (tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; ATSlocal (ats_bool_type, tmp768) ; // ATSlocal_void (tmp769) ; // ATSlocal_void (tmp770) ; // ATSlocal_void (tmp771) ; // ATSlocal_void (tmp772) ; // ATSlocal_void (tmp773) ; // ATSlocal_void (tmp774) ; // ATSlocal_void (tmp775) ; // ATSlocal_void (tmp776) ; // ATSlocal_void (tmp777) ; // ATSlocal_void (tmp778) ; // ATSlocal_void (tmp779) ; // ATSlocal_void (tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; // ATSlocal_void (tmp785) ; // ATSlocal_void (tmp786) ; // ATSlocal_void (tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; // ATSlocal_void (tmp789) ; // ATSlocal_void (tmp790) ; ATSlocal (ats_int_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; // ATSlocal_void (tmp793) ; // ATSlocal_void (tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_int_type, tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; // ATSlocal_void (tmp803) ; ATSlocal (ats_bool_type, tmp804) ; // ATSlocal_void (tmp805) ; // ATSlocal_void (tmp806) ; // ATSlocal_void (tmp807) ; // ATSlocal_void (tmp808) ; // ATSlocal_void (tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_int_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; // ATSlocal_void (tmp814) ; ATSlocal (ats_bool_type, tmp815) ; // ATSlocal_void (tmp816) ; // ATSlocal_void (tmp817) ; // ATSlocal_void (tmp818) ; // ATSlocal_void (tmp819) ; // ATSlocal_void (tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_bool_type, tmp824) ; // ATSlocal_void (tmp838) ; // ATSlocal_void (tmp839) ; // ATSlocal_void (tmp840) ; // ATSlocal_void (tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_bool_type, tmp845) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; // ATSlocal_void (tmp858) ; // ATSlocal_void (tmp859) ; // ATSlocal_void (tmp860) ; // ATSlocal_void (tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; // ATSlocal_void (tmp863) ; // ATSlocal_void (tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_bool_type, tmp867) ; // ATSlocal_void (tmp868) ; // ATSlocal_void (tmp869) ; // ATSlocal_void (tmp870) ; // ATSlocal_void (tmp871) ; // ATSlocal_void (tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; // ATSlocal_void (tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_ptr_type, tmp880) ; // ATSlocal_void (tmp881) ; // ATSlocal_void (tmp882) ; // ATSlocal_void (tmp883) ; // ATSlocal_void (tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; ATSlocal (ats_bool_type, tmp888) ; // ATSlocal_void (tmp889) ; // ATSlocal_void (tmp890) ; // ATSlocal_void (tmp891) ; // ATSlocal_void (tmp892) ; // ATSlocal_void (tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_int_type, tmp897) ; // ATSlocal_void (tmp898) ; // ATSlocal_void (tmp899) ; // ATSlocal_void (tmp900) ; // ATSlocal_void (tmp901) ; // ATSlocal_void (tmp902) ; // ATSlocal_void (tmp903) ; // ATSlocal_void (tmp904) ; // ATSlocal_void (tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_int_type, tmp909) ; // ATSlocal_void (tmp910) ; // ATSlocal_void (tmp911) ; // ATSlocal_void (tmp912) ; // ATSlocal_void (tmp913) ; // ATSlocal_void (tmp914) ; // ATSlocal_void (tmp915) ; // ATSlocal_void (tmp916) ; // ATSlocal_void (tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; // ATSlocal_void (tmp920) ; // ATSlocal_void (tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; // ATSlocal_void (tmp923) ; // ATSlocal_void (tmp924) ; // ATSlocal_void (tmp925) ; // ATSlocal_void (tmp926) ; // ATSlocal_void (tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; // ATSlocal_void (tmp931) ; // ATSlocal_void (tmp932) ; // ATSlocal_void (tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; // ATSlocal_void (tmp936) ; // ATSlocal_void (tmp937) ; // ATSlocal_void (tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; // ATSlocal_void (tmp942) ; // ATSlocal_void (tmp943) ; // ATSlocal_void (tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; // ATSlocal_void (tmp946) ; // ATSlocal_void (tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; ATSlocal (ats_int_type, tmp949) ; // ATSlocal_void (tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; // ATSlocal_void (tmp952) ; // ATSlocal_void (tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; // ATSlocal_void (tmp955) ; // ATSlocal_void (tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; // ATSlocal_void (tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; // ATSlocal_void (tmp962) ; // ATSlocal_void (tmp963) ; // ATSlocal_void (tmp964) ; // ATSlocal_void (tmp965) ; // ATSlocal_void (tmp966) ; // ATSlocal_void (tmp967) ; // ATSlocal_void (tmp968) ; // ATSlocal_void (tmp969) ; // ATSlocal_void (tmp970) ; // ATSlocal_void (tmp971) ; // ATSlocal_void (tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; // ATSlocal_void (tmp974) ; // ATSlocal_void (tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; // ATSlocal_void (tmp977) ; // ATSlocal_void (tmp978) ; // ATSlocal_void (tmp979) ; // ATSlocal_void (tmp980) ; // ATSlocal_void (tmp981) ; // ATSlocal_void (tmp982) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr: tmp626 = atsopt_gline_flag_get () ; tmp628 = atspre_gt_int_int (tmp626, 0) ; if (tmp628) { tmp629 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_instr_loc) ; /* tmp627 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma (arg0, tmp629) ; } else { /* empty */ } /* end of [if] */ tmp630 = atsopt_debug_flag_get () ; tmp632 = atspre_gt_int_int (tmp630, 0) ; if (tmp632) { /* tmp633 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; /* tmp634 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_instr (arg0, arg1) ; /* tmp635 = */ atspre_fprint_string (arg0, ATSstrcst(" */")) ; /* tmp631 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ tmp636 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_instr_node) ; do { /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp636)->tag != 0) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp637 = ats_caselptrlab_mac(anairiats_sum_18, tmp636, atslab_0) ; tmp638 = ats_caselptrlab_mac(anairiats_sum_18, tmp636, atslab_1) ; tmp639 = ats_caselptrlab_mac(anairiats_sum_18, tmp636, atslab_2) ; /* tmp625 = */ emit_instr_arr_heap_61 (arg0, tmp637, tmp638, tmp639) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp636)->tag != 1) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp640 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_0) ; tmp641 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_1) ; tmp642 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_2) ; tmp643 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_3) ; /* tmp625 = */ emit_instr_arr_stack_62 (arg0, tmp640, tmp641, tmp642, tmp643) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: if (((ats_sum_ptr_type)tmp636)->tag != 2) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_0) ; tmp645 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_1) ; tmp646 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_2) ; tmp647 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_3) ; /* tmp625 = */ emit_instr_assgn_arr_60 (arg0, tmp644, tmp645, tmp646, tmp647) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp636)->tag != 3) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp648 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_0) ; tmp649 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_1) ; tmp650 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_2) ; tmp651 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_3) ; /* tmp652 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp648) ; /* tmp653 = */ atspre_fprint_string (arg0, ATSstrcst(" = &(")) ; /* tmp654 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp649) ; /* tmp655 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; /* tmp656 = */ emit_tmpvar_cloptr_init_30 (arg0, 0, tmp648, tmp650, tmp651) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ; // closure initialization")) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp636)->tag != 4) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp657 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_0) ; tmp658 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_1) ; tmp659 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_2) ; tmp660 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_3) ; /* tmp625 = */ emit_instr_call_65 (arg0, tmp657, tmp658, tmp659, tmp660) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp636)->tag != 5) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp661 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp662 = */ atspre_fprint_string (arg0, ATSstrcst("goto ")) ; /* tmp663 = */ atspre_fprint_string (arg0, ATSstrcst("__ats_lab_")) ; /* tmp664 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp661) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ; // tail call")) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp636)->tag != 6) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp665 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp666 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp667 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp668 = */ atspre_fprint_string (arg0, ATSstrcst("if (")) ; /* tmp669 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp665) ; /* tmp670 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; /* tmp671 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp666) ; /* tmp672 = */ atspre_fprint_string (arg0, ATSstrcst("\n} else {\n")) ; /* tmp673 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp667) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("\n} /* end of [if] */")) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp636)->tag != 7) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp674 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp675 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp676 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_GC_MARKROOT(&")) ; /* tmp677 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp674) ; /* tmp678 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(ats_ptr_type)) ;\n")) ; /* tmp679 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp674) ; /* tmp680 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp681 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp675) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_make () ;")) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp636)->tag != 8) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp682 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp683 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp684 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp682) ; /* tmp685 = */ atspre_fprint_string (arg0, ATSstrcst(" = &")) ; /* tmp686 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp683) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp636)->tag != 9) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp687 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp688 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp689 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_GC_MARKROOT(&")) ; /* tmp690 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp687) ; /* tmp691 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(")) ; tmp693 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp688), atslab_valprim_typ) ; /* tmp692 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp693) ; /* tmp694 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;\n")) ; /* tmp695 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp687) ; /* tmp696 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp697 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp688) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp636)->tag != 10) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp698 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp699 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp700 = */ atspre_fprint_string (arg0, ATSstrcst("/*\n")) ; /* tmp701 = */ atspre_fprint_string (arg0, tmp698) ; /* tmp702 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp703 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp699) ; /* tmp704 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("\n*/")) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: if (((ats_sum_ptr_type)tmp636)->tag != 12) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp705 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp706 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp707 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_GC_MARKROOT(&")) ; /* tmp708 = */ atspre_fprint_string (arg0, tmp705) ; /* tmp709 = */ atspre_fprint_string (arg0, ATSstrcst(", sizeof(")) ; tmp711 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp706), atslab_valprim_typ) ; /* tmp710 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp711) ; /* tmp712 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;\n")) ; /* tmp713 = */ atspre_fprint_string (arg0, tmp705) ; /* tmp714 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp715 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp706) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp636)->tag != 13) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp716 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp717 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_FREE(")) ; /* tmp718 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp716) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: if (((ats_sum_ptr_type)tmp636)->tag != 14) { goto __ats_lab_167_0 ; } __ats_lab_164_1: tmp719 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_1) ; tmp720 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_2) ; tmp721 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_3) ; /* tmp722 = */ funarglst_push_25 (tmp719) ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp720) ; /* tmp724 = */ funarglst_pop_24 () ; /* tmp725 = */ atspre_fprint_char (arg0, '\n') ; do { /* branch: __ats_lab_165 */ __ats_lab_165_0: __ats_lab_165_1: tmp726 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (tmp721) ; if (!tmp726) { goto __ats_lab_166_1 ; } /* tmp727 = */ atspre_fprint_string (arg0, ATSstrcst("return /* ")) ; /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp721) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" */ ;\n")) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: __ats_lab_166_1: /* tmp729 = */ atspre_fprint_string (arg0, ATSstrcst("return ")) ; /* tmp730 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp721) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n")) ; break ; } while (0) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp636)->tag != 15) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp731 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp732 = */ atspre_fprint_string (arg0, ATSstrcst("__ats_lab_")) ; /* tmp733 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp731) ; /* tmp625 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp636)->tag != 16) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp734 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp735 = */ atsopt_emit_filename (arg0, tmp734) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload () ;")) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: if (((ats_sum_ptr_type)tmp636)->tag != 17) { goto __ats_lab_170_0 ; } __ats_lab_169_1: tmp736 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp737 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp738 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp736) ; /* tmp739 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp740 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptrget_mac(")) ; tmp742 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp736) ; /* tmp741 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp742) ; /* tmp743 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp744 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp737) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp636)->tag != 18) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp745 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp746 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp747 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp748 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp745) ; /* tmp749 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp750 = */ emit_valprim_select_ptr_45 (arg0, tmp746, tmp747) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)tmp636)->tag != 20) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp751 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp752 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp753 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp754 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp751) ; /* tmp755 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp756 = */ emit_valprim_select_var_44 (arg0, tmp752, tmp753) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp636)->tag != 21) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp757 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_0) ; tmp758 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_1) ; tmp759 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_2) ; tmp760 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_3) ; tmp761 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_4) ; tmp762 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_5) ; tmp763 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_6) ; tmp764 = ats_caselptrlab_mac(anairiats_sum_21, tmp636, atslab_7) ; /* tmp765 = */ atspre_fprint_string (arg0, ATSstrcst("/* loop initialization */\n")) ; /* tmp766 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp760) ; /* tmp767 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; tmp768 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (tmp763) ; /* tmp769 = */ atspre_fprint_string (arg0, ATSstrcst("ats_loop_beg_mac(")) ; /* tmp770 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp757) ; /* tmp771 = */ atspre_fprint_string (arg0, ATSstrcst(")\n")) ; /* tmp772 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp762) ; /* tmp773 = */ atspre_fprint_char (arg0, '\n') ; /* tmp774 = */ atspre_fprint_string (arg0, ATSstrcst("if (!")) ; /* tmp775 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp761) ; /* tmp776 = */ atspre_fprint_string (arg0, ATSstrcst(") break ;\n")) ; /* tmp777 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp764) ; /* tmp778 = */ atspre_fprint_char (arg0, '\n') ; if (tmp768) { /* tmp780 = */ atspre_fprint_string (arg0, ATSstrcst("/* post update before continue */\n")) ; /* tmp781 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp759) ; /* tmp782 = */ atspre_fprint_string (arg0, ATSstrcst(":\n")) ; /* tmp783 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp763) ; /* tmp779 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; } else { /* empty */ } /* end of [if] */ /* tmp784 = */ atspre_fprint_string (arg0, ATSstrcst("ats_loop_end_mac(")) ; /* tmp785 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp757) ; /* tmp786 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp787 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp758) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp636)->tag != 22) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp788 = ats_caselptrlab_mac(anairiats_sum_22, tmp636, atslab_1) ; /* tmp789 = */ atspre_fprint_string (arg0, ATSstrcst("goto ")) ; /* tmp790 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplab (arg0, tmp788) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp636)->tag != 23) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp791 = ats_caselptrlab_mac(anairiats_sum_22, tmp636, atslab_0) ; tmp792 = ats_caselptrlab_mac(anairiats_sum_22, tmp636, atslab_1) ; /* tmp793 = */ atspre_fprintf_exn (arg0, ATSstrcst("arg%i = "), tmp791) ; /* tmp794 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp792) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp636)->tag != 24) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp795 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_0) ; tmp796 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_1) ; tmp797 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_2) ; tmp798 = ats_caselptrlab_mac(anairiats_sum_20, tmp636, atslab_3) ; /* tmp625 = */ emit_move_con_58 (arg0, tmp795, tmp796, tmp797, tmp798) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp636)->tag != 25) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp799 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_0) ; tmp800 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_1) ; tmp801 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_2) ; tmp802 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_3) ; tmp804 = atspre_eq_int_int (tmp800, 0) ; if (tmp804) { /* tmp803 = */ atspre_fprint_string (arg0, ATSstrcst("ats_instr_move_lazy_delay_mac (")) ; } else { /* tmp803 = */ atspre_fprint_string (arg0, ATSstrcst("ats_instr_move_lazy_ldelay_mac (")) ; } /* end of [if] */ /* tmp805 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp799) ; /* tmp806 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp807 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp801) ; /* tmp808 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp809 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp802) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp636)->tag != 26) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp810 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_0) ; tmp811 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_1) ; tmp812 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_2) ; tmp813 = ats_caselptrlab_mac(anairiats_sum_19, tmp636, atslab_3) ; tmp815 = atspre_eq_int_int (tmp811, 0) ; if (tmp815) { /* tmp814 = */ atspre_fprint_string (arg0, ATSstrcst("ats_instr_move_lazy_force_mac (")) ; } else { /* tmp814 = */ atspre_fprint_string (arg0, ATSstrcst("ats_instr_move_lazy_lforce_mac (")) ; } /* end of [if] */ /* tmp816 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp810) ; /* tmp817 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp818 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp812) ; /* tmp819 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp820 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp813) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)tmp636)->tag != 27) { goto __ats_lab_181_0 ; } __ats_lab_178_1: tmp821 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp822 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp823 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; tmp824 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext (tmp822) ; /* tmp838 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp821) ; /* tmp839 = */ atspre_fprint_string (arg0, ATSstrcst(" = ATS_MALLOC(sizeof(")) ; /* tmp840 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, tmp822) ; /* tmp841 = */ atspre_fprint_string (arg0, ATSstrcst(")) ;\n")) ; /* tmp625 = */ aux_67 (tmp822, tmp824, arg0, tmp821, tmp823) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp636)->tag != 28) { goto __ats_lab_184_0 ; } __ats_lab_181_1: tmp842 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp843 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp844 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; tmp845 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext (tmp843) ; /* tmp625 = */ aux_68 (tmp845, arg0, tmp842, tmp844) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp636)->tag != 29) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp856 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp857 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp858 = */ atspre_fprint_string (arg0, ATSstrcst("ats_instr_move_ref_mac (")) ; /* tmp859 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp856) ; /* tmp860 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; tmp862 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp857), atslab_valprim_typ) ; /* tmp861 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp862) ; /* tmp863 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp864 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp857) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)tmp636)->tag != 30) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp865 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp866 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; tmp867 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_void (tmp866) ; if (tmp867) { /* tmp868 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; } else { /* empty */ } /* end of [if] */ /* tmp869 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp865) ; /* tmp870 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp871 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp866) ; if (tmp867) { /* tmp872 = */ atspre_fprint_string (arg0, ATSstrcst(" */")) ; } else { /* empty */ } /* end of [if] */ /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: if (((ats_sum_ptr_type)tmp636)->tag != 31) { goto __ats_lab_191_0 ; } __ats_lab_186_1: tmp873 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp874 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp875 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (((ats_sum_ptr_type)tmp875)->tag != 6) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp877 = ats_caselptrlab_mac(anairiats_sum_1, tmp875, atslab_0) ; tmp876 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont (tmp877) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: __ats_lab_188_1: tmp876 = tmp875 ; break ; } while (0) ; do { /* branch: __ats_lab_189 */ __ats_lab_189_0: if (((ats_sum_ptr_type)tmp876)->tag != 0) { goto __ats_lab_190_0 ; } __ats_lab_189_1: /* tmp878 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: __ats_lab_190_1: break ; } while (0) ; /* tmp625 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_patck (arg0, tmp873, tmp874, tmp875) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: if (((ats_sum_ptr_type)tmp636)->tag != 32) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp879 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp880 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp881 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp879) ; /* tmp883 = */ atspre_fprint_string (arg0, ATSstrcst(" = */ ats_raise_exn (")) ; /* tmp884 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp880) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: if (((ats_sum_ptr_type)tmp636)->tag != 33) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp885 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp886 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp887 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; tmp888 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (tmp885) ; if (tmp888) { /* tmp889 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; } else { /* empty */ } /* end of [if] */ /* tmp890 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp885) ; /* tmp891 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp892 = */ emit_valprim_select_39 (arg0, tmp886, tmp887) ; if (tmp888) { /* tmp893 = */ atspre_fprint_string (arg0, ATSstrcst(" */")) ; } else { /* empty */ } /* end of [if] */ /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: if (((ats_sum_ptr_type)tmp636)->tag != 34) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp894 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_0) ; tmp895 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_1) ; tmp896 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_2) ; tmp897 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_3) ; /* tmp898 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp894) ; /* tmp899 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp900 = */ atspre_fprint_string (arg0, ATSstrcst("ats_caselptrlab_mac(")) ; /* tmp901 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, tmp896) ; /* tmp902 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp903 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp895) ; /* tmp904 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp905 = */ atspre_fprintf_exn (arg0, ATSstrcst("atslab_%i"), tmp897) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp636)->tag != 35) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp906 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_0) ; tmp907 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_1) ; tmp908 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_2) ; tmp909 = ats_caselptrlab_mac(anairiats_sum_24, tmp636, atslab_3) ; /* tmp910 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp906) ; /* tmp911 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp912 = */ atspre_fprint_string (arg0, ATSstrcst("&ats_caselptrlab_mac(")) ; /* tmp913 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp_ptr (arg0, tmp908) ; /* tmp914 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp915 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp907) ; /* tmp916 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp917 = */ atspre_fprintf_exn (arg0, ATSstrcst("atslab_%i"), tmp909) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp636)->tag != 37) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp918 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp919 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp920 = */ atspre_fprint_string (arg0, ATSstrcst("ats_ptrget_mac(")) ; tmp922 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp919), atslab_valprim_typ) ; /* tmp921 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp922) ; /* tmp923 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp924 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp918) ; /* tmp925 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; /* tmp926 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp927 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp919) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp636)->tag != 38) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp928 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp929 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp930 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp931 = */ emit_valprim_select_ptr_45 (arg0, tmp928, tmp929) ; /* tmp932 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp933 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp930) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp636)->tag != 39) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp934 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_0) ; tmp935 = ats_caselptrlab_mac(anairiats_sum_7, tmp636, atslab_1) ; /* tmp936 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp934) ; /* tmp937 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp938 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp935) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: if (((ats_sum_ptr_type)tmp636)->tag != 40) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp939 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp940 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp941 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp942 = */ emit_valprim_select_var_44 (arg0, tmp939, tmp940) ; /* tmp943 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp944 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim (arg0, tmp941) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ;")) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp636)->tag != 36) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp945 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp946 = */ atspre_fprint_string (arg0, ATSstrcst("do {\n")) ; /* tmp947 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst (arg0, tmp945) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("} while (0) ;")) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp636)->tag != 41) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp948 = ats_caselptrlab_mac(anairiats_sum_11, tmp636, atslab_0) ; tmp949 = ats_caselptrlab_mac(anairiats_sum_11, tmp636, atslab_1) ; /* tmp950 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmplabint (arg0, tmp948, tmp949) ; /* tmp625 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: if (((ats_sum_ptr_type)tmp636)->tag != 42) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp951 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp952 = */ atspre_fprint_string (arg0, ATSstrcst("ats_proofcheck_beg_mac(")) ; /* tmp953 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp951) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)tmp636)->tag != 43) { goto __ats_lab_203_0 ; } __ats_lab_202_1: tmp954 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp955 = */ atspre_fprint_string (arg0, ATSstrcst("ats_proofcheck_end_mac(")) ; /* tmp956 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp954) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)tmp636)->tag != 44) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp957 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp958 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_d2cst (arg0, tmp957) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("_prfck () ;")) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp636)->tag != 45) { goto __ats_lab_205_0 ; } __ats_lab_204_1: tmp959 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_0) ; tmp960 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_1) ; tmp961 = ats_caselptrlab_mac(anairiats_sum_16, tmp636, atslab_2) ; /* tmp962 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_TRYWITH_TRY(")) ; /* tmp963 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp960) ; /* tmp964 = */ atspre_fprint_string (arg0, ATSstrcst(")\n")) ; /* tmp965 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp959) ; /* tmp966 = */ atspre_fprint_char (arg0, '\n') ; /* tmp967 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_TRYWITH_WITH(")) ; /* tmp968 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp960) ; /* tmp969 = */ atspre_fprint_string (arg0, ATSstrcst(")\n")) ; /* tmp970 = */ atspre_fprint_string (arg0, ATSstrcst("do {\n")) ; /* tmp971 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_branchlst (arg0, tmp961) ; /* tmp972 = */ atspre_fprint_string (arg0, ATSstrcst("} while (0) ;\n")) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_TRYWITH_END() ;\n")) ; break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: if (((ats_sum_ptr_type)tmp636)->tag != 46) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp973 = ats_caselptrlab_mac(anairiats_sum_1, tmp636, atslab_0) ; /* tmp974 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; tmp976 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp973) ; /* tmp975 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp976) ; /* tmp977 = */ atspre_fprint_char (arg0, ' ') ; /* tmp978 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp973) ; /* tmp625 = */ atspre_fprint_string (arg0, ATSstrcst(" ; */")) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: __ats_lab_206_1: /* tmp979 = */ prerr_interror_0 () ; /* tmp980 = */ atspre_prerr_string (ATSstrcst(": emit_instr: ins = ")) ; /* tmp981 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_instr (arg1) ; /* tmp982 = */ atspre_prerr_newline () ; /* tmp625 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp625) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 69791(line=2206, offs=7) -- 70137(line=2215, offs=6) */ ATSstaticdec() ats_void_type aux_70 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; // ATSlocal_void (tmp987) ; ATSlocal (ats_bool_type, tmp988) ; // ATSlocal_void (tmp989) ; ATSlocal (ats_int_type, tmp990) ; ATSlocal (ats_bool_type, tmp991) ; __ats_lab_aux_70: do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp985 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp986 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp988 = atspre_gt_int_int (arg1, 0) ; if (tmp988) { /* tmp987 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp989 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instr (arg0, tmp985) ; tmp990 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp990 ; arg2 = tmp986 ; goto __ats_lab_aux_70 ; // tail call break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_208_1: tmp991 = atspre_gt_int_int (arg1, 0) ; if (tmp991) { /* empty */ } else { /* tmp984 = */ atspre_fprint_string (arg0, ATSstrcst("/* empty */")) ; } /* end of [if] */ break ; } while (0) ; return /* (tmp984) */ ; } /* end of [aux_70] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 69762(line=2205, offs=19) -- 70181(line=2218, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp983) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst: /* tmp983 = */ aux_70 (arg0, 0, arg1) ; return /* (tmp983) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 70408(line=2230, offs=7) -- 70944(line=2244, offs=24) */ ATSstaticdec() ats_void_type loop_72 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; // ATSlocal_void (tmp996) ; ATSlocal (ats_bool_type, tmp997) ; // ATSlocal_void (tmp998) ; // ATSlocal_void (tmp999) ; ATSlocal (ats_bool_type, tmp1000) ; // ATSlocal_void (tmp1001) ; ATSlocal (ats_int_type, tmp1002) ; __ats_lab_loop_72: do { /* branch: __ats_lab_209 */ __ats_lab_209_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp994 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp995 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp997 = atspre_gt_int_int (arg1, 0) ; if (tmp997) { /* tmp996 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp998 = */ _emit_hityp_11 (arg0, tmp994) ; tmp1000 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg (tmp994) ; if (tmp1000) { /* empty */ } else { /* tmp1001 = */ atspre_fprint_string (arg0, ATSstrcst(" arg")) ; /* tmp999 = */ atspre_fprint_int (arg0, arg1) ; } /* end of [if] */ tmp1002 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp1002 ; arg2 = tmp995 ; goto __ats_lab_loop_72 ; // tail call break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_210_1: break ; } while (0) ; return /* (tmp993) */ ; } /* end of [loop_72] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 70379(line=2229, offs=3) -- 71008(line=2248, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp992) ; ATSlocal (ats_ptr_type, tmp1003) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg: tmp1003 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (arg1) ; /* tmp992 = */ loop_72 (arg0, 0, tmp1003) ; return /* (tmp992) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 71488(line=2273, offs=6) -- 72081(line=2290, offs=6) */ ATSstaticdec() ats_void_type f_arg_74 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1006) ; ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_int_type, tmp1009) ; ATSlocal (ats_int_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_bool_type, tmp1013) ; // ATSlocal_void (tmp1014) ; ATSlocal (ats_bool_type, tmp1015) ; // ATSlocal_void (tmp1016) ; __ats_lab_f_arg_74: // tmp1007 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1008 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp1009 = ats_ptrget_mac(ats_int_type, tmp1008) ; tmp1010 = atspre_add_int_int (tmp1009, 1) ; ats_ptrget_mac(ats_int_type, tmp1008) = tmp1010 ; tmp1011 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp1013 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp1011) ; if (tmp1013) { tmp1012 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; } else { tmp1012 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (arg0) ; } /* end of [if] */ tmp1015 = atspre_gt_int_int (tmp1009, 0) ; if (tmp1015) { /* tmp1014 = */ atspre_fprint_string (tmp1007, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1016 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp1007, tmp1012) ; /* tmp1006 = */ atspre_fprintf_exn (tmp1007, ATSstrcst(" env%i"), tmp1009) ; return /* (tmp1006) */ ; } /* end of [f_arg_74] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 71273(line=2263, offs=4) -- 72334(line=2298, offs=4) */ ATSstaticdec() ats_int_type _emit_funenvarg_73 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp1004) ; ATSlocal (ats_int_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1017) ; // ATSlocal_void (tmp1018) ; __ats_lab__emit_funenvarg_73: /* ats_int_type tmp1005 ; */ tmp1005 = 0 ; tmp1017 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1017, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp1017, atslab_1, (&tmp1005)) ; /* tmp1018 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg1, &f_arg_74, tmp1017) ; // ATS_FREE(tmp1017) ; tmp1004 = tmp1005 ; return (tmp1004) ; } /* end of [_emit_funenvarg_73] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 72410(line=2303, offs=16) -- 72475(line=2304, offs=47) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp1019) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg: tmp1019 = _emit_funenvarg_73 (arg0, arg1) ; return (tmp1019) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 72981(line=2326, offs=7) -- 73215(line=2332, offs=6) */ ATSstaticdec() ats_void_type aux_77 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp1028) ; ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; // ATSlocal_void (tmp1031) ; ATSlocal (ats_bool_type, tmp1032) ; // ATSlocal_void (tmp1033) ; ATSlocal (ats_int_type, tmp1034) ; __ats_lab_aux_77: do { /* branch: __ats_lab_211 */ __ats_lab_211_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp1029 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp1030 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp1032 = atspre_gt_int_int (arg1, 0) ; if (tmp1032) { /* tmp1031 = */ atspre_prerr_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1033 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp1029) ; tmp1034 = atspre_add_int_int (arg1, 1) ; arg0 = tmp1030 ; arg1 = tmp1034 ; goto __ats_lab_aux_77 ; // tail call break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_212_1: break ; } while (0) ; return /* (tmp1028) */ ; } /* end of [aux_77] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 72551(line=2311, offs=4) -- 73531(line=2344, offs=4) */ ATSstaticdec() ats_void_type funentry_env_err_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_int_type, tmp1022) ; // ATSlocal_void (tmp1023) ; ATSlocal (ats_bool_type, tmp1024) ; // ATSlocal_void (tmp1025) ; ATSlocal (ats_bool_type, tmp1026) ; ATSlocal (ats_bool_type, tmp1027) ; // ATSlocal_void (tmp1035) ; // ATSlocal_void (tmp1036) ; ATSlocal (ats_bool_type, tmp1037) ; ATSlocal (ats_bool_type, tmp1038) ; // ATSlocal_void (tmp1039) ; ATSlocal (ats_bool_type, tmp1040) ; ATSlocal (ats_bool_type, tmp1041) ; __ats_lab_funentry_env_err_76: tmp1021 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make (arg2) ; tmp1022 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed (tmp1021) ; tmp1024 = atspre_igt (tmp1022, 0) ; if (tmp1024) { /* tmp1023 = */ prerr_loc_errorccomp_1 (arg0) ; } else { /* empty */ } /* end of [if] */ tmp1026 = atspre_igt (tmp1022, 1) ; if (tmp1026) { /* tmp1025 = */ atspre_prerr_string (ATSstrcst(": the dynamic variables [")) ; } else { tmp1027 = atspre_igt (tmp1022, 0) ; if (tmp1027) { /* tmp1025 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; } else { /* empty */ } /* end of [if] */ } /* end of [if] */ /* tmp1035 = */ aux_77 (tmp1021, 0) ; tmp1037 = atspre_igt (tmp1022, 1) ; if (tmp1037) { /* tmp1036 = */ atspre_prerr_string (ATSstrcst("] are not function arguments.")) ; } else { tmp1038 = atspre_igt (tmp1022, 0) ; if (tmp1038) { /* tmp1036 = */ atspre_prerr_string (ATSstrcst("] is not a function argument.")) ; } else { /* empty */ } /* end of [if] */ } /* end of [if] */ tmp1040 = atspre_igt (tmp1022, 0) ; if (tmp1040) { /* tmp1039 = */ atspre_prerr_newline () ; } else { /* empty */ } /* end of [if] */ tmp1041 = atspre_igt (tmp1022, 0) ; if (tmp1041) { /* tmp1020 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp1020) */ ; } /* end of [funentry_env_err_76] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 74518(line=2385, offs=6) -- 75013(line=2400, offs=6) */ ATSstaticdec() ats_void_type f_fld_79 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_int_type, tmp1047) ; ATSlocal (ats_int_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_bool_type, tmp1051) ; // ATSlocal_void (tmp1052) ; __ats_lab_f_fld_79: // tmp1045 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1046 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp1047 = ats_ptrget_mac(ats_int_type, tmp1046) ; tmp1048 = atspre_add_int_int (tmp1047, 1) ; ats_ptrget_mac(ats_int_type, tmp1046) = tmp1048 ; tmp1049 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp1051 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp1049) ; if (tmp1051) { tmp1050 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; } else { tmp1050 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (arg0) ; } /* end of [if] */ /* tmp1052 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp1045, tmp1050) ; /* tmp1044 = */ atspre_fprintf_exn (tmp1045, ATSstrcst(" closure_env_%i ;\n"), tmp1047) ; return /* (tmp1044) */ ; } /* end of [f_fld_79] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 74218(line=2376, offs=4) -- 75533(line=2416, offs=4) */ ATSstaticdec() ats_void_type _emit_closure_type_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1042) ; ATSlocal (ats_int_type, tmp1043) ; // ATSlocal_void (tmp1053) ; // ATSlocal_void (tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; // ATSlocal_void (tmp1056) ; // ATSlocal_void (tmp1057) ; // ATSlocal_void (tmp1058) ; __ats_lab__emit_closure_type_78: /* ats_int_type tmp1043 ; */ tmp1043 = 0 ; /* tmp1053 = */ atspre_fprint_string (arg0, ATSstrcst("typedef struct {\n")) ; /* tmp1054 = */ atspre_fprint_string (arg0, ATSstrcst("ats_fun_ptr_type closure_fun ;\n")) ; tmp1055 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1055, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp1055, atslab_1, (&tmp1043)) ; /* tmp1056 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg2, &f_fld_79, tmp1055) ; // ATS_FREE(tmp1055) ; /* tmp1057 = */ atspre_fprint_string (arg0, ATSstrcst("} ")) ; /* tmp1058 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1042 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_type ;")) ; return /* (tmp1042) */ ; } /* end of [_emit_closure_type_78] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 75906(line=2430, offs=6) -- 76460(line=2446, offs=6) */ ATSstaticdec() ats_void_type f_arg_81 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; ATSlocal (ats_int_type, tmp1064) ; ATSlocal (ats_int_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; ATSlocal (ats_bool_type, tmp1068) ; // ATSlocal_void (tmp1069) ; // ATSlocal_void (tmp1070) ; __ats_lab_f_arg_81: // tmp1062 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1063 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp1064 = ats_ptrget_mac(ats_int_type, tmp1063) ; tmp1065 = atspre_add_int_int (tmp1064, 1) ; ats_ptrget_mac(ats_int_type, tmp1063) = tmp1065 ; tmp1066 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp1068 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp1066) ; if (tmp1068) { tmp1067 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; } else { tmp1067 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (arg0) ; } /* end of [if] */ /* tmp1069 = */ atspre_fprint_string (tmp1062, ATSstrcst(", ")) ; /* tmp1070 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp1062, tmp1067) ; /* tmp1061 = */ atspre_fprintf_exn (tmp1062, ATSstrcst(" env%i"), tmp1064) ; return /* (tmp1061) */ ; } /* end of [f_arg_81] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 76487(line=2448, offs=6) -- 76803(line=2458, offs=6) */ ATSstaticdec() ats_void_type f_body_82 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; ATSlocal (ats_int_type, tmp1074) ; ATSlocal (ats_int_type, tmp1075) ; __ats_lab_f_body_82: // tmp1072 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1073 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp1074 = ats_ptrget_mac(ats_int_type, tmp1073) ; tmp1075 = atspre_add_int_int (tmp1074, 1) ; ats_ptrget_mac(ats_int_type, tmp1073) = tmp1075 ; /* tmp1071 = */ atspre_fprintf_exn (tmp1072, ATSstrcst("p_clo->closure_env_%i = env%i ;\n"), tmp1074, tmp1074) ; return /* (tmp1071) */ ; } /* end of [f_body_82] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 75590(line=2420, offs=4) -- 77952(line=2492, offs=4) */ ATSstaticdec() ats_void_type _emit_closure_init_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1059) ; ATSlocal (ats_int_type, tmp1060) ; // ATSlocal_void (tmp1076) ; // ATSlocal_void (tmp1077) ; // ATSlocal_void (tmp1078) ; // ATSlocal_void (tmp1079) ; // ATSlocal_void (tmp1080) ; // ATSlocal_void (tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; // ATSlocal_void (tmp1083) ; // ATSlocal_void (tmp1084) ; // ATSlocal_void (tmp1085) ; // ATSlocal_void (tmp1086) ; // ATSlocal_void (tmp1087) ; // ATSlocal_void (tmp1088) ; // ATSlocal_void (tmp1089) ; __ats_lab__emit_closure_init_80: /* ats_int_type tmp1060 ; */ /* tmp1076 = */ atspre_fprint_string (arg0, ATSstrcst("ATSinline()\n")) ; /* tmp1077 = */ atspre_fprint_string (arg0, ATSstrcst("ats_void_type\n")) ; /* tmp1078 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1079 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_init (")) ; /* tmp1080 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1081 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_type *p_clo")) ; tmp1082 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1082, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp1082, atslab_1, (&tmp1060)) ; tmp1060 = 0 ; /* tmp1083 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg2, &f_arg_81, tmp1082) ; /* tmp1084 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; /* tmp1085 = */ atspre_fprint_string (arg0, ATSstrcst("p_clo->closure_fun = (ats_fun_ptr_type)&")) ; /* tmp1086 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1087 = */ atspre_fprint_string (arg0, ATSstrcst("_clofun ;\n")) ; tmp1060 = 0 ; /* tmp1088 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg2, &f_body_82, tmp1082) ; // ATS_FREE(tmp1082) ; /* tmp1089 = */ atspre_fprint_string (arg0, ATSstrcst("return ;\n")) ; /* tmp1059 = */ atspre_fprint_string (arg0, ATSstrcst("} /* end of function */")) ; return /* (tmp1059) */ ; } /* end of [_emit_closure_init_80] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 78328(line=2507, offs=6) -- 78922(line=2525, offs=6) */ ATSstaticdec() ats_void_type f_arg_84 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_int_type, tmp1095) ; ATSlocal (ats_int_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_bool_type, tmp1099) ; // ATSlocal_void (tmp1100) ; ATSlocal (ats_bool_type, tmp1101) ; // ATSlocal_void (tmp1102) ; __ats_lab_f_arg_84: // tmp1093 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1094 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp1095 = ats_ptrget_mac(ats_int_type, tmp1094) ; tmp1096 = atspre_add_int_int (tmp1095, 1) ; ats_ptrget_mac(ats_int_type, tmp1094) = tmp1096 ; tmp1097 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp1099 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp1097) ; if (tmp1099) { tmp1098 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; } else { tmp1098 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_typ (arg0) ; } /* end of [if] */ tmp1101 = atspre_gt_int_int (tmp1095, 0) ; if (tmp1101) { /* tmp1100 = */ atspre_fprint_string (tmp1093, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1102 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp1093, tmp1098) ; /* tmp1092 = */ atspre_fprintf_exn (tmp1093, ATSstrcst(" env%i"), tmp1095) ; return /* (tmp1092) */ ; } /* end of [f_arg_84] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 79811(line=2550, offs=9) -- 79963(line=2553, offs=10) */ ATSstaticdec() ats_void_type loop_85 (ats_ref_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp1116) ; ATSlocal (ats_bool_type, tmp1117) ; // ATSlocal_void (tmp1118) ; ATSlocal (ats_int_type, tmp1119) ; __ats_lab_loop_85: tmp1117 = atspre_lt_int_int (arg2, arg1) ; if (tmp1117) { /* tmp1118 = */ atspre_fprintf_exn (arg0, ATSstrcst(", env%i"), arg2) ; tmp1119 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp1119 ; goto __ats_lab_loop_85 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp1116) */ ; } /* end of [loop_85] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 78009(line=2496, offs=4) -- 80272(line=2564, offs=4) */ ATSstaticdec() ats_void_type _emit_closure_make_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1090) ; ATSlocal (ats_int_type, tmp1091) ; // ATSlocal_void (tmp1103) ; // ATSlocal_void (tmp1104) ; // ATSlocal_void (tmp1105) ; ATSlocal (ats_ptr_type, tmp1106) ; // ATSlocal_void (tmp1107) ; ATSlocal (ats_int_type, tmp1108) ; // ATSlocal_void (tmp1109) ; // ATSlocal_void (tmp1110) ; // ATSlocal_void (tmp1111) ; // ATSlocal_void (tmp1112) ; // ATSlocal_void (tmp1113) ; // ATSlocal_void (tmp1114) ; // ATSlocal_void (tmp1115) ; // ATSlocal_void (tmp1120) ; // ATSlocal_void (tmp1121) ; // ATSlocal_void (tmp1122) ; __ats_lab__emit_closure_make_83: /* ats_int_type tmp1091 ; */ /* tmp1103 = */ atspre_fprint_string (arg0, ATSstrcst("ats_clo_ptr_type\n")) ; /* tmp1104 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1105 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_make (")) ; tmp1106 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1106, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp1106, atslab_1, (&tmp1091)) ; tmp1091 = 0 ; /* tmp1107 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg2, &f_arg_84, tmp1106) ; tmp1108 = tmp1091 ; /* tmp1109 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; /* tmp1110 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1111 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_type *p_clo = ATS_MALLOC(sizeof(")) ; /* tmp1112 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1113 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_type)) ;\n")) ; /* tmp1114 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1115 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_init (p_clo")) ; /* tmp1120 = */ loop_85 (arg0, tmp1108, 0) ; /* tmp1121 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; // ATS_FREE(tmp1106) ; /* tmp1122 = */ atspre_fprint_string (arg0, ATSstrcst("return (ats_clo_ptr_type)p_clo ;\n")) ; /* tmp1090 = */ atspre_fprint_string (arg0, ATSstrcst("} /* end of function */")) ; return /* (tmp1090) */ ; } /* end of [_emit_closure_make_83] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 81188(line=2592, offs=6) -- 81668(line=2605, offs=6) */ ATSstaticdec() ats_void_type f_env_87 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1135) ; ATSlocal (ats_ptr_type, tmp1136) ; ATSlocal (ats_ptr_type, tmp1137) ; ATSlocal (ats_ptr_type, tmp1138) ; ATSlocal (ats_int_type, tmp1139) ; ATSlocal (ats_int_type, tmp1140) ; // ATSlocal_void (tmp1141) ; ATSlocal (ats_bool_type, tmp1142) ; // ATSlocal_void (tmp1143) ; // ATSlocal_void (tmp1144) ; __ats_lab_f_env_87: // tmp1136 = ats_caselptrlab_mac(anairiats_sum_23, arg1, atslab_0) ; tmp1137 = ats_caselptrlab_mac(anairiats_sum_23, arg1, atslab_1) ; tmp1138 = ats_caselptrlab_mac(anairiats_sum_23, arg1, atslab_2) ; tmp1139 = ats_ptrget_mac(ats_int_type, tmp1138) ; tmp1140 = atspre_add_int_int (tmp1139, 1) ; ats_ptrget_mac(ats_int_type, tmp1138) = tmp1140 ; tmp1142 = atspre_gt_int_int (tmp1139, 0) ; if (tmp1142) { /* tmp1141 = */ atspre_fprint_string (tmp1137, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1143 = */ atspre_fprint_string (tmp1137, ATSstrcst("((")) ; /* tmp1144 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (tmp1137, tmp1136) ; /* tmp1135 = */ atspre_fprintf_exn (tmp1137, ATSstrcst("_closure_type*)cloptr)->closure_env_%i"), tmp1139) ; return /* (tmp1135) */ ; } /* end of [f_env_87] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 82497(line=2630, offs=9) -- 82933(line=2642, offs=8) */ ATSstaticdec() ats_void_type emit_arglst_88 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1155) ; ATSlocal (ats_ptr_type, tmp1156) ; // ATSlocal_void (tmp1157) ; ATSlocal (ats_bool_type, tmp1158) ; // ATSlocal_void (tmp1159) ; ATSlocal (ats_int_type, tmp1160) ; __ats_lab_emit_arglst_88: do { /* branch: __ats_lab_217 */ __ats_lab_217_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp1156 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp1158 = atspre_gt_int_int (arg1, 0) ; if (tmp1158) { /* tmp1157 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1159 = */ atspre_fprintf_exn (arg0, ATSstrcst("arg%i"), arg1) ; tmp1160 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp1160 ; arg2 = tmp1156 ; goto __ats_lab_emit_arglst_88 ; // tail call break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_218_1: break ; } while (0) ; return /* (tmp1155) */ ; } /* end of [emit_arglst_88] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 80329(line=2568, offs=4) -- 83237(line=2654, offs=4) */ ATSstaticdec() ats_void_type _emit_closure_clofun_86 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1123) ; ATSlocal (ats_ptr_type, tmp1124) ; // ATSlocal_void (tmp1125) ; // ATSlocal_void (tmp1126) ; // ATSlocal_void (tmp1127) ; // ATSlocal_void (tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; // ATSlocal_void (tmp1130) ; ATSlocal (ats_bool_type, tmp1131) ; // ATSlocal_void (tmp1132) ; // ATSlocal_void (tmp1133) ; ATSlocal (ats_int_type, tmp1134) ; ATSlocal (ats_bool_type, tmp1145) ; // ATSlocal_void (tmp1146) ; // ATSlocal_void (tmp1147) ; // ATSlocal_void (tmp1148) ; ATSlocal (ats_ptr_type, tmp1149) ; // ATSlocal_void (tmp1150) ; // ATSlocal_void (tmp1151) ; ATSlocal (ats_bool_type, tmp1152) ; ATSlocal (ats_bool_type, tmp1153) ; ATSlocal (ats_ptr_type, tmp1154) ; // ATSlocal_void (tmp1161) ; // ATSlocal_void (tmp1162) ; // ATSlocal_void (tmp1163) ; __ats_lab__emit_closure_clofun_86: tmp1124 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res (arg1) ; /* tmp1125 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp1124) ; /* tmp1126 = */ atspre_fprint_char (arg0, '\n') ; /* tmp1127 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1128 = */ atspre_fprint_string (arg0, ATSstrcst("_clofun (ats_clo_ptr_type cloptr")) ; tmp1129 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (arg1) ; do { /* branch: __ats_lab_213 */ __ats_lab_213_0: __ats_lab_213_1: tmp1131 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (tmp1129) ; if (!tmp1131) { goto __ats_lab_214_1 ; } /* tmp1130 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: __ats_lab_214_1: break ; } while (0) ; /* tmp1132 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg (arg0, tmp1129) ; /* tmp1133 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; /* ats_int_type tmp1134 ; */ tmp1134 = 0 ; tmp1145 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void (tmp1124) ; if (tmp1145) { /* empty */ } else { /* tmp1146 = */ atspre_fprint_string (arg0, ATSstrcst("return ")) ; } /* end of [if] */ /* tmp1147 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg1) ; /* tmp1148 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; tmp1149 = ATS_MALLOC(sizeof(anairiats_sum_23)) ; ats_selptrset_mac(anairiats_sum_23, tmp1149, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_23, tmp1149, atslab_1, arg0) ; ats_selptrset_mac(anairiats_sum_23, tmp1149, atslab_2, (&tmp1134)) ; /* tmp1150 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg2, &f_env_87, tmp1149) ; // ATS_FREE(tmp1149) ; tmp1152 = atspre_gt_int_int (tmp1134, 0) ; if (tmp1152) { do { /* branch: __ats_lab_215 */ __ats_lab_215_0: __ats_lab_215_1: tmp1153 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (tmp1129) ; if (!tmp1153) { goto __ats_lab_216_1 ; } /* tmp1151 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: __ats_lab_216_1: break ; } while (0) ; } else { /* empty */ } /* end of [if] */ tmp1154 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (tmp1129) ; /* tmp1161 = */ emit_arglst_88 (arg0, 0, tmp1154) ; /* tmp1162 = */ atspre_fprint_string (arg0, ATSstrcst(") ;")) ; if (tmp1145) { /* tmp1163 = */ atspre_fprint_string (arg0, ATSstrcst(" return ;")) ; } else { /* empty */ } /* end of [if] */ /* tmp1123 = */ atspre_fprint_string (arg0, ATSstrcst("\n} /* end of function */")) ; return /* (tmp1123) */ ; } /* end of [_emit_closure_clofun_86] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 83334(line=2661, offs=19) -- 83410(line=2662, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_type: /* tmp1164 = */ _emit_closure_type_78 (arg0, arg1, arg2) ; return /* (tmp1164) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 83470(line=2666, offs=19) -- 83546(line=2667, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_init (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1165) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_init: /* tmp1165 = */ _emit_closure_init_80 (arg0, arg1, arg2) ; return /* (tmp1165) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_init] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 83606(line=2671, offs=19) -- 83682(line=2672, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_make (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1166) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_make: /* tmp1166 = */ _emit_closure_make_83 (arg0, arg1, arg2) ; return /* (tmp1166) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 83744(line=2676, offs=21) -- 83822(line=2677, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_clofun (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_clofun: /* tmp1167 = */ _emit_closure_clofun_86 (arg0, arg1, arg2) ; return /* (tmp1167) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_clofun] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 84076(line=2689, offs=11) -- 84266(line=2692, offs=63) */ ATSstaticdec() ats_int_type loop_94 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp1172) ; ATSlocal (ats_ptr_type, tmp1173) ; ATSlocal (ats_ptr_type, tmp1174) ; ATSlocal (ats_int_type, tmp1175) ; ATSlocal (ats_bool_type, tmp1176) ; __ats_lab_loop_94: do { /* branch: __ats_lab_220 */ __ats_lab_220_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp1173 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp1174 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp1175 = atspre_add_int_int (arg0, 1) ; arg0 = tmp1175 ; arg1 = tmp1173 ; arg2 = tmp1174 ; goto __ats_lab_loop_94 ; // tail call break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_221_1: tmp1176 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg (arg1) ; if (tmp1176) { tmp1172 = arg0 ; } else { tmp1172 = -1 ; } /* end of [if] */ break ; } while (0) ; return (tmp1172) ; } /* end of [loop_94] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 83903(line=2684, offs=4) -- 84343(line=2696, offs=4) */ ATSstaticdec() ats_int_type hityplst_get_nvararg_93 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp1168) ; ATSlocal (ats_ptr_type, tmp1169) ; ATSlocal (ats_ptr_type, tmp1170) ; ATSlocal (ats_ptr_type, tmp1171) ; __ats_lab_hityplst_get_nvararg_93: tmp1169 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (arg0) ; do { /* branch: __ats_lab_219 */ __ats_lab_219_0: if (tmp1169 == (ats_sum_ptr_type)0) { goto __ats_lab_222_0 ; } __ats_lab_219_1: tmp1170 = ats_caselptrlab_mac(anairiats_sum_4, tmp1169, atslab_0) ; tmp1171 = ats_caselptrlab_mac(anairiats_sum_4, tmp1169, atslab_1) ; tmp1168 = loop_94 (0, tmp1170, tmp1171) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: // if (tmp1169 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_222_1: tmp1168 = -1 ; break ; } while (0) ; return (tmp1168) ; } /* end of [hityplst_get_nvararg_93] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 84404(line=2700, offs=3) -- 89897(line=2878, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1177) ; ATSlocal (ats_ptr_type, tmp1178) ; ATSlocal (ats_ptr_type, tmp1179) ; ATSlocal (ats_ptr_type, tmp1180) ; ATSlocal (ats_int_type, tmp1181) ; ATSlocal (ats_ptr_type, tmp1182) ; ATSlocal (ats_ptr_type, tmp1183) ; ATSlocal (ats_ptr_type, tmp1184) ; // ATSlocal_void (tmp1185) ; ATSlocal (ats_ptr_type, tmp1186) ; // ATSlocal_void (tmp1187) ; // ATSlocal_void (tmp1188) ; // ATSlocal_void (tmp1189) ; // ATSlocal_void (tmp1190) ; // ATSlocal_void (tmp1191) ; ATSlocal (ats_int_type, tmp1192) ; // ATSlocal_void (tmp1193) ; ATSlocal (ats_bool_type, tmp1194) ; ATSlocal (ats_ptr_type, tmp1195) ; // ATSlocal_void (tmp1196) ; // ATSlocal_void (tmp1197) ; // ATSlocal_void (tmp1198) ; // ATSlocal_void (tmp1199) ; // ATSlocal_void (tmp1200) ; ATSlocal (ats_int_type, tmp1201) ; // ATSlocal_void (tmp1202) ; ATSlocal (ats_bool_type, tmp1203) ; ATSlocal (ats_bool_type, tmp1204) ; // ATSlocal_void (tmp1205) ; // ATSlocal_void (tmp1206) ; ATSlocal (ats_ptr_type, tmp1207) ; // ATSlocal_void (tmp1208) ; ATSlocal (ats_ptr_type, tmp1209) ; // ATSlocal_void (tmp1210) ; // ATSlocal_void (tmp1211) ; ATSlocal (ats_int_type, tmp1212) ; // ATSlocal_void (tmp1213) ; ATSlocal (ats_bool_type, tmp1214) ; // ATSlocal_void (tmp1215) ; ATSlocal (ats_bool_type, tmp1216) ; // ATSlocal_void (tmp1217) ; // ATSlocal_void (tmp1218) ; ATSlocal (ats_bool_type, tmp1219) ; // ATSlocal_void (tmp1220) ; ATSlocal (ats_bool_type, tmp1221) ; // ATSlocal_void (tmp1222) ; // ATSlocal_void (tmp1223) ; // ATSlocal_void (tmp1224) ; // ATSlocal_void (tmp1225) ; ATSlocal (ats_int_type, tmp1226) ; // ATSlocal_void (tmp1227) ; ATSlocal (ats_ptr_type, tmp1228) ; // ATSlocal_void (tmp1229) ; // ATSlocal_void (tmp1230) ; ATSlocal (ats_bool_type, tmp1231) ; // ATSlocal_void (tmp1232) ; // ATSlocal_void (tmp1233) ; // ATSlocal_void (tmp1234) ; // ATSlocal_void (tmp1235) ; // ATSlocal_void (tmp1236) ; // ATSlocal_void (tmp1237) ; // ATSlocal_void (tmp1238) ; // ATSlocal_void (tmp1239) ; ATSlocal (ats_int_type, tmp1240) ; // ATSlocal_void (tmp1241) ; // ATSlocal_void (tmp1242) ; // ATSlocal_void (tmp1243) ; // ATSlocal_void (tmp1244) ; // ATSlocal_void (tmp1245) ; // ATSlocal_void (tmp1246) ; ATSlocal (ats_bool_type, tmp1247) ; // ATSlocal_void (tmp1248) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry: tmp1178 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (arg1) ; tmp1179 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (tmp1178) ; tmp1180 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (tmp1178) ; tmp1181 = hityplst_get_nvararg_93 (tmp1180) ; tmp1182 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res (tmp1178) ; tmp1183 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (arg1) ; tmp1184 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc (arg1) ; do { /* branch: __ats_lab_223 */ __ats_lab_223_0: if (tmp1179 != (ats_sum_ptr_type)0) { goto __ats_lab_224_0 ; } __ats_lab_223_1: /* tmp1185 = */ funentry_env_err_76 (tmp1184, tmp1178, tmp1183) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: // if (tmp1179 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_224_1: break ; } while (0) ; tmp1186 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (arg1) ; /* tmp1187 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_set (tmp1183) ; /* tmp1188 = */ atspre_fprint_string (arg0, ATSstrcst("/*\n")) ; /* tmp1189 = */ atspre_fprint_string (arg0, ATSstrcst("// ")) ; /* tmp1190 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (arg0, tmp1184) ; /* tmp1191 = */ atspre_fprint_string (arg0, ATSstrcst("\n*/\n")) ; tmp1192 = atsopt_debug_flag_get () ; tmp1194 = atspre_gte_int_int (tmp1192, 1) ; if (tmp1194) { /* tmp1193 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma (arg0, tmp1184) ; } else { /* empty */ } /* end of [if] */ tmp1195 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua (tmp1178) ; do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (tmp1195 == (ats_sum_ptr_type)0) { goto __ats_lab_226_0 ; } __ats_lab_225_1: /* tmp1196 = */ atspre_fprint_string (arg0, ATSstrcst("ATSglobaldec()\n")) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: // if (tmp1195 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_226_1: /* tmp1196 = */ atspre_fprint_string (arg0, ATSstrcst("ATSstaticdec()\n")) ; break ; } while (0) ; /* tmp1197 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp1182) ; /* tmp1198 = */ atspre_fprint_char (arg0, '\n') ; /* tmp1199 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp1178) ; /* tmp1200 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; tmp1201 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg (arg0, tmp1183) ; tmp1203 = atspre_gt_int_int (tmp1201, 0) ; if (tmp1203) { do { /* branch: __ats_lab_227 */ __ats_lab_227_0: __ats_lab_227_1: tmp1204 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (tmp1180) ; if (!tmp1204) { goto __ats_lab_228_1 ; } /* tmp1202 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: __ats_lab_228_1: break ; } while (0) ; } else { /* empty */ } /* end of [if] */ /* tmp1205 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg (arg0, tmp1180) ; /* tmp1206 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; tmp1207 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_tailjoin (arg1) ; /* tmp1208 = */ atspre_fprint_string (arg0, ATSstrcst("/* local vardec */\n")) ; /* ats_ptr_type tmp1209 ; */ tmp1209 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil () ; /* tmp1210 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tailjoinlst_tmpvarmap_add ((&tmp1209), tmp1207) ; /* tmp1211 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funentry_tmpvarmap_add ((&tmp1209), arg1) ; tmp1212 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_local (arg0, tmp1209) ; tmp1214 = atspre_gt_int_int (tmp1212, 0) ; if (tmp1214) { /* tmp1213 = */ atspre_fprint_char (arg0, '\n') ; } else { /* empty */ } /* end of [if] */ /* tmp1215 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free (tmp1209) ; do { /* branch: __ats_lab_229 */ __ats_lab_229_0: if (tmp1207 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp1216 = ats_true_bool ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: // if (tmp1207 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_230_1: tmp1216 = ats_false_bool ; break ; } while (0) ; if (tmp1216) { /* tmp1217 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tailjoinlst (arg0, tmp1207) ; } else { /* empty */ } /* end of [if] */ tmp1219 = atspre_gte_int_int (tmp1181, 0) ; if (tmp1219) { tmp1221 = atspre_eq_int_int (tmp1181, 0) ; if (tmp1221) { /* tmp1222 = */ prerr_loc_errorccomp_1 (tmp1184) ; /* tmp1223 = */ atspre_prerr_string (ATSstrcst(": a variadic function must have at least one argument (in front of ...)")) ; /* tmp1224 = */ atspre_prerr_newline () ; /* tmp1220 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp1225 = */ atspre_fprintf_exn (arg0, ATSstrcst("ATSlocal (va_list, arg%i) ;\n"), tmp1181) ; tmp1226 = atspre_sub_int_int (tmp1181, 1) ; /* tmp1218 = */ atspre_fprintf_exn (arg0, ATSstrcst("va_start(arg%i, arg%i) ;\n\n"), tmp1181, tmp1226) ; } else { /* empty */ } /* end of [if] */ tmp1228 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body (arg1) ; /* tmp1227 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_instrlst (arg0, tmp1228) ; /* tmp1229 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_reset () ; /* tmp1230 = */ atspre_fprint_string (arg0, ATSstrcst("\nreturn ")) ; tmp1231 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (tmp1186) ; if (tmp1231) { /* tmp1232 = */ atspre_fprint_string (arg0, ATSstrcst("/* ")) ; } else { /* empty */ } /* end of [if] */ /* tmp1233 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp1234 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp1186) ; /* tmp1235 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; if (tmp1231) { /* tmp1236 = */ atspre_fprint_string (arg0, ATSstrcst(" */")) ; } else { /* empty */ } /* end of [if] */ /* tmp1237 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n} /* end of [")) ; /* tmp1238 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, tmp1178) ; /* tmp1239 = */ atspre_fprint_string (arg0, ATSstrcst("] */")) ; do { /* branch: __ats_lab_231 */ __ats_lab_231_0: __ats_lab_231_1: if (!tmp1216) { goto __ats_lab_232_1 ; } break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: __ats_lab_232_1: do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (tmp1179 == (ats_sum_ptr_type)0) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp1240 = ats_caselptrlab_mac(anairiats_sum_15, tmp1179, atslab_0) ; /* tmp1241 = */ atspre_fprint_string (arg0, ATSstrcst("\n\n")) ; /* tmp1242 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_type (arg0, tmp1178, tmp1183) ; /* tmp1243 = */ atspre_fprint_string (arg0, ATSstrcst("\n\n")) ; /* tmp1244 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_clofun (arg0, tmp1178, tmp1183) ; /* tmp1245 = */ atspre_fprint_string (arg0, ATSstrcst("\n\n")) ; /* tmp1246 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_init (arg0, tmp1178, tmp1183) ; tmp1247 = atspre_neq_int_int (tmp1240, 0) ; if (tmp1247) { /* tmp1248 = */ atspre_fprint_string (arg0, ATSstrcst("\n\n")) ; /* tmp1177 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_closure_make (arg0, tmp1178, tmp1183) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: // if (tmp1179 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_234_1: break ; } while (0) ; break ; } while (0) ; return /* (tmp1177) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 90216(line=2891, offs=6) -- 90846(line=2907, offs=6) */ ATSstaticdec() ats_void_type aux_function_97 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp1255) ; // ATSlocal_void (tmp1256) ; // ATSlocal_void (tmp1257) ; // ATSlocal_void (tmp1258) ; // ATSlocal_void (tmp1259) ; // ATSlocal_void (tmp1260) ; ATSlocal (ats_int_type, tmp1261) ; // ATSlocal_void (tmp1262) ; ATSlocal (ats_bool_type, tmp1263) ; ATSlocal (ats_bool_type, tmp1264) ; // ATSlocal_void (tmp1265) ; __ats_lab_aux_function_97: /* tmp1256 = */ atspre_fprint_string (arg0, ATSstrcst("static\n")) ; /* tmp1257 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, env2) ; /* tmp1258 = */ atspre_fprint_char (arg0, ' ') ; /* tmp1259 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, env0) ; /* tmp1260 = */ atspre_fprint_string (arg0, ATSstrcst(" (")) ; tmp1261 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg (arg0, env3) ; tmp1263 = atspre_gt_int_int (tmp1261, 0) ; if (tmp1263) { do { /* branch: __ats_lab_235 */ __ats_lab_235_0: __ats_lab_235_1: tmp1264 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (env1) ; if (!tmp1264) { goto __ats_lab_236_1 ; } /* tmp1262 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: __ats_lab_236_1: break ; } while (0) ; } else { /* empty */ } /* end of [if] */ /* tmp1265 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg (arg0, env1) ; /* tmp1255 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; return /* (tmp1255) */ ; } /* end of [aux_function_97] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; } aux_function_97_closure_type ; ats_void_type aux_function_97_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) { aux_function_97 (((aux_function_97_closure_type*)cloptr)->closure_env_0, ((aux_function_97_closure_type*)cloptr)->closure_env_1, ((aux_function_97_closure_type*)cloptr)->closure_env_2, ((aux_function_97_closure_type*)cloptr)->closure_env_3, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_function_97_closure_init (aux_function_97_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_function_97_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; return ; } /* end of function */ ats_clo_ptr_type aux_function_97_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) { aux_function_97_closure_type *p_clo = ATS_MALLOC(sizeof(aux_function_97_closure_type)) ; aux_function_97_closure_init (p_clo, env0, env1, env2, env3) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 90880(line=2909, offs=6) -- 91272(line=2919, offs=6) */ ATSstaticdec() ats_void_type aux_closure_make_98 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp1266) ; // ATSlocal_void (tmp1267) ; // ATSlocal_void (tmp1268) ; // ATSlocal_void (tmp1269) ; // ATSlocal_void (tmp1270) ; ATSlocal (ats_int_type, tmp1271) ; __ats_lab_aux_closure_make_98: /* tmp1267 = */ atspre_fprint_string (arg0, ATSstrcst("static\n")) ; /* tmp1268 = */ atspre_fprint_string (arg0, ATSstrcst("ats_clo_ptr_type ")) ; /* tmp1269 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, env0) ; /* tmp1270 = */ atspre_fprint_string (arg0, ATSstrcst("_closure_make (")) ; tmp1271 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funenvarg (arg0, env1) ; /* tmp1266 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; return /* (tmp1266) */ ; } /* end of [aux_closure_make_98] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_closure_make_98_closure_type ; ats_void_type aux_closure_make_98_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) { aux_closure_make_98 (((aux_closure_make_98_closure_type*)cloptr)->closure_env_0, ((aux_closure_make_98_closure_type*)cloptr)->closure_env_1, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_closure_make_98_closure_init (aux_closure_make_98_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_closure_make_98_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_closure_make_98_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_closure_make_98_closure_type *p_clo = ATS_MALLOC(sizeof(aux_closure_make_98_closure_type)) ; aux_closure_make_98_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 91310(line=2921, offs=6) -- 91868(line=2936, offs=6) */ ATSstaticdec() ats_void_type aux_closure_clofun_99 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp1272) ; // ATSlocal_void (tmp1273) ; // ATSlocal_void (tmp1274) ; // ATSlocal_void (tmp1275) ; // ATSlocal_void (tmp1276) ; // ATSlocal_void (tmp1277) ; // ATSlocal_void (tmp1278) ; ATSlocal (ats_bool_type, tmp1279) ; // ATSlocal_void (tmp1280) ; __ats_lab_aux_closure_clofun_99: /* tmp1273 = */ atspre_fprint_string (arg0, ATSstrcst("static\n")) ; /* tmp1274 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, env2) ; /* tmp1275 = */ atspre_fprint_char (arg0, ' ') ; /* tmp1276 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, env0) ; /* tmp1277 = */ atspre_fprint_string (arg0, ATSstrcst("_clofun (ats_clo_ptr_type cloptr")) ; do { /* branch: __ats_lab_237 */ __ats_lab_237_0: __ats_lab_237_1: tmp1279 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (env1) ; if (!tmp1279) { goto __ats_lab_238_1 ; } /* tmp1278 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: __ats_lab_238_1: break ; } while (0) ; /* tmp1280 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__emit_funarg (arg0, env1) ; /* tmp1272 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; return /* (tmp1272) */ ; } /* end of [aux_closure_clofun_99] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_closure_clofun_99_closure_type ; ats_void_type aux_closure_clofun_99_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0) { aux_closure_clofun_99 (((aux_closure_clofun_99_closure_type*)cloptr)->closure_env_0, ((aux_closure_clofun_99_closure_type*)cloptr)->closure_env_1, ((aux_closure_clofun_99_closure_type*)cloptr)->closure_env_2, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_closure_clofun_99_closure_init (aux_closure_clofun_99_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_closure_clofun_99_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_closure_clofun_99_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_closure_clofun_99_closure_type *p_clo = ATS_MALLOC(sizeof(aux_closure_clofun_99_closure_type)) ; aux_closure_clofun_99_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 89986(line=2884, offs=7) -- 92690(line=2965, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry_prototype (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1249) ; ATSlocal (ats_ptr_type, tmp1250) ; ATSlocal (ats_ptr_type, tmp1251) ; ATSlocal (ats_ptr_type, tmp1252) ; ATSlocal (ats_ptr_type, tmp1253) ; ATSlocal (ats_ptr_type, tmp1254) ; ATSlocal (ats_ptr_type, tmp1281) ; ATSlocal (ats_int_type, tmp1282) ; ATSlocal (ats_bool_type, tmp1283) ; // ATSlocal_void (tmp1284) ; // ATSlocal_void (tmp1285) ; // ATSlocal_void (tmp1286) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry_prototype: tmp1250 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (arg1) ; tmp1251 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (tmp1250) ; tmp1252 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (tmp1250) ; tmp1253 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res (tmp1250) ; tmp1254 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (arg1) ; tmp1281 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua (tmp1250) ; do { /* branch: __ats_lab_239 */ __ats_lab_239_0: if (tmp1281 == (ats_sum_ptr_type)0) { goto __ats_lab_242_0 ; } __ats_lab_239_1: do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (tmp1251 == (ats_sum_ptr_type)0) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp1282 = ats_caselptrlab_mac(anairiats_sum_15, tmp1251, atslab_0) ; tmp1283 = atspre_neq_int_int (tmp1282, 0) ; if (tmp1283) { /* tmp1284 = */ aux_closure_make_98 (tmp1250, tmp1254, arg0) ; /* tmp1249 = */ aux_closure_clofun_99 (tmp1250, tmp1252, tmp1253, arg0) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: // if (tmp1251 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_241_1: break ; } while (0) ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: // if (tmp1281 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_242_1: do { /* branch: __ats_lab_243 */ __ats_lab_243_0: if (tmp1251 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_243_1: /* tmp1285 = */ aux_function_97 (tmp1250, tmp1252, tmp1253, tmp1254, arg0) ; /* tmp1286 = */ aux_closure_make_98 (tmp1250, tmp1254, arg0) ; /* tmp1249 = */ aux_closure_clofun_99 (tmp1250, tmp1252, tmp1253, arg0) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: // if (tmp1251 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_244_1: /* tmp1249 = */ aux_function_97 (tmp1250, tmp1252, tmp1253, tmp1254, arg0) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp1249) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funentry_prototype] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_emit.dats: 92774(line=2971, offs=3) -- 93328(line=2986, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_mainfun (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1287) ; // ATSlocal_void (tmp1288) ; // ATSlocal_void (tmp1289) ; // ATSlocal_void (tmp1290) ; // ATSlocal_void (tmp1291) ; // ATSlocal_void (tmp1292) ; // ATSlocal_void (tmp1293) ; // ATSlocal_void (tmp1294) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_mainfun: /* tmp1288 = */ atspre_fprint_string (arg0, ATSstrcst("int main (int argc, char *argv[]) {\n")) ; /* tmp1289 = */ atspre_fprint_string (arg0, ATSstrcst("ATS_GC_INIT() ;\n")) ; /* tmp1290 = */ atspre_fprint_string (arg0, ATSstrcst("mainats_prelude() ;\n")) ; /* tmp1291 = */ atsopt_emit_filename (arg0, arg1) ; /* tmp1292 = */ atspre_fprint_string (arg0, ATSstrcst("__dynload() ;\n")) ; /* tmp1293 = */ atspre_fprint_string (arg0, ATSstrcst("mainats((ats_int_type)argc, (ats_ptr_type)argv) ;\n")) ; /* tmp1294 = */ atspre_fprint_string (arg0, ATSstrcst("return (0) ;\n")) ; /* tmp1287 = */ atspre_fprint_string (arg0, ATSstrcst("} /* end of main */\n")) ; return /* (tmp1287) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_mainfun] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon2_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__ENVcon3_0.tag = 0 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp98, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp101, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp104, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp105, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp106, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp98 = ref_make_elt_03903_ats_int_type (0) ; statmp104 = (ats_sum_ptr_type)0 ; statmp101 = ref_make_elt_03903_ats_ptr_type (statmp104) ; statmp106 = (ats_sum_ptr_type)0 ; statmp105 = ref_make_elt_03903_ats_ptr_type (statmp106) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_emit_identifier ( ats_ptr_type out, ats_ptr_type name ) { char c, *s ; s = name ; while (c = *s++) { if (isalnum (c)) { fputc (c, (FILE*)out) ; continue ; } if (c == '_') { /* fputs ("_0", (FILE*)out); continue ; */ fputc ('_', (FILE*)out); continue ; } if (c == '$') { fputs ("_0", (FILE*)out); continue ; } // end of [if] if (c == '\'') { fputs ("_1", (FILE*)out); continue ; } // end of [if] if (c == '/') { fputs ("_2", (FILE*)out); continue ; } // end of [if] if (c == '\\') { fputs ("_3", (FILE*)out); continue ; } // end of [if] fputc ('_', (FILE*)out); fprintf ((FILE*)out, "%.2x", (unsigned char)c); } /* end of [while] */ return ; } /* atsopt_emit_identifier */ extern char *atsopt_ATSHOME ; extern int atsopt_ATSHOME_length ; extern char *atsopt_ATSHOMERELOC ; extern ats_ptr_type atsopt_filename_full (ats_ptr_type) ; ats_void_type atsopt_emit_filename (ats_ptr_type out, ats_ptr_type fil) { int sgn ; char *name ; name = atsopt_filename_full (fil) ; // if (!atsopt_ATSHOMERELOC) { atsopt_emit_identifier (out, name) ; return ; } // sgn = strncmp (atsopt_ATSHOME, name, atsopt_ATSHOME_length) ; if (sgn) { atsopt_emit_identifier (out, name) ; } else { atsopt_emit_identifier (out, atsopt_ATSHOMERELOC) ; atsopt_emit_identifier (out, (char*)name + atsopt_ATSHOME_length) ; } // end of [if] // return ; } /* end of atsopt_emit_filename */ ats_void_type atsopt_emit_valprim_string ( ats_ptr_type out, ats_ptr_type str, ats_size_type len ) { char *s = str; int i; char c; // fputs ("ATSstrcst(\"", (FILE*)out); // for (i = 0; i < len; i += 1, s += 1) { c = *s; switch (c) { case '"': fprintf ((FILE*)out, "\\\""); break; case '\n': fprintf ((FILE*)out, "\\n"); break; case '\t': fprintf ((FILE*)out, "\\t"); break; case '\\': fprintf ((FILE*)out, "\\\\"); break; default: if (isprint(c)) { fputc (c, (FILE*)out) ; } else { fprintf ((FILE*)out, "\\%.3o", (unsigned char)c); } } // end of [switch] } // end of [for] // fputs ("\")", (FILE*)out); // return ; } // end of [atsopt_emit_valprim_string] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_emit_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_view_dats.c0000664000175000017500000015273312223166160022376 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_5 ; typedef struct { anairiats_rec_0 atslab_0 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_d3lab1_loc ; ats_ptr_type atslab_d3lab1_node ; } anairiats_rec_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_14 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_16 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lintry_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lindel_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_void_type aux_4 (ats_ptr_type arg0) ; static ats_void_type aux_6 (ats_ptr_type arg0) ; static anairiats_rec_0 d2var_view_viewat_set_slablst_main_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static anairiats_rec_0 d2var_view_viewat_set_slablst_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s2lab0lst_of_d3lab1lst_10 (ats_ptr_type arg0) ; static ats_void_type refval_check_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_bool_type s2exp_fun_is_freeptr_13 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 1936(line=62, offs=4) -- 2021(line=63, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 2055(line=66, offs=4) -- 2115(line=66, offs=64) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_view)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 2120(line=68, offs=4) -- 2233(line=70, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_view)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 2917(line=90, offs=11) -- 3061(line=92, offs=28) */ ATSstaticdec() ats_void_type aux_4 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; __ats_lab_aux_4: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(".")) ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (tmp21) ; arg0 = tmp22 ; goto __ats_lab_aux_4 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp20) */ ; } /* end of [aux_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 2329(line=76, offs=3) -- 3287(line=101, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (anairiats_rec_0, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (anairiats_rec_2, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (arg1) ; tmp7 = ats_select_mac(tmp6, atslab_0) ; tmp8 = ats_select_mac(tmp6, atslab_1) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp8, arg2) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (tmp7, tmp9) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp10 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, tmp10, atslab_0) ; ATS_FREE(tmp10) ; tmp12 = ats_select_mac(tmp11, atslab_0) ; tmp13 = ats_select_mac(tmp11, atslab_1) ; tmp14 = ats_select_mac(tmp11, atslab_2) ; tmp15 = ats_select_mac(tmp11, atslab_3) ; tmp16 = ats_select_mac(tmp11, atslab_4) ; /* ats_ptr_type tmp17 ; */ tmp17 = (ats_sum_ptr_type)0 ; tmp18 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lintry_slablst_cstr (arg0, tmp13, tmp16, (&tmp17)) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp17) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (tmp8, tmp15, tmp18) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp10 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: /* tmp25 = */ prerr_loc_error3_0 (arg0) ; /* tmp26 = */ atspre_prerr_string (ATSstrcst(": there is no view at [")) ; /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp7) ; /* tmp28 = */ aux_4 (tmp9) ; /* tmp29 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp30 = */ atspre_prerr_newline () ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 4337(line=130, offs=11) -- 4481(line=132, offs=28) */ ATSstaticdec() ats_void_type aux_6 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; __ats_lab_aux_6: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp55 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp56 = */ atspre_prerr_string (ATSstrcst(".")) ; /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (tmp54) ; arg0 = tmp55 ; goto __ats_lab_aux_6 ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: break ; } while (0) ; return /* (tmp53) */ ; } /* end of [aux_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 3394(line=107, offs=3) -- 4707(line=141, offs=4) */ ATSglobaldec() anairiats_rec_5 ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (anairiats_rec_5, tmp31) ; ATSlocal (anairiats_rec_0, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (anairiats_rec_2, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (anairiats_rec_1, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst: tmp32 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (arg1) ; tmp33 = ats_select_mac(tmp32, atslab_0) ; tmp34 = ats_select_mac(tmp32, atslab_1) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp34, arg2) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (tmp33, tmp35) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp36 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_3, tmp36, atslab_0) ; ATS_FREE(tmp36) ; tmp38 = ats_select_mac(tmp37, atslab_0) ; tmp39 = ats_select_mac(tmp37, atslab_1) ; tmp40 = ats_select_mac(tmp37, atslab_2) ; tmp41 = ats_select_mac(tmp37, atslab_3) ; tmp42 = ats_select_mac(tmp37, atslab_4) ; /* ats_ptr_type tmp43 ; */ tmp43 = (ats_sum_ptr_type)0 ; tmp44 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lindel_slablst_cstr (arg0, tmp39, tmp42, (&tmp43)) ; tmp45 = ats_select_mac(tmp44, atslab_0) ; tmp46 = ats_select_mac(tmp44, atslab_1) ; tmp47 = ats_select_mac(tmp44, atslab_2) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp43) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (tmp38, tmp46, tmp40) ; tmp50 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (tmp34, tmp41, tmp47) ; tmp52 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (tmp33, tmp50) ; tmp51 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp45, tmp52) ; tmp31.atslab_0 = tmp51 ; tmp31.atslab_1 = tmp50 ; tmp31.atslab_2 = tmp38 ; tmp31.atslab_3 = tmp42 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp36 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: /* tmp58 = */ prerr_loc_error3_0 (arg0) ; /* tmp59 = */ atspre_prerr_string (ATSstrcst(": there is no view at [")) ; /* tmp60 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp33) ; /* tmp61 = */ aux_6 (tmp35) ; /* tmp62 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp63 = */ atspre_prerr_newline () ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 4814(line=147, offs=3) -- 7095(line=213, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (anairiats_rec_0, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (anairiats_rec_0, tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (anairiats_rec_0, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (anairiats_rec_2, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_bool_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (anairiats_rec_1, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; // ATSlocal_void (tmp94) ; ATSlocal (ats_bool_type, tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst: tmp66 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (arg3) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp66 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_6, tmp66, atslab_0) ; ATS_FREE(tmp66) ; tmp65 = tmp67 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp66 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: /* tmp68 = */ prerr_loc_error3_0 (arg0) ; /* tmp69 = */ atspre_prerr_string (ATSstrcst(": the view [")) ; /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg3) ; /* tmp71 = */ atspre_prerr_string (ATSstrcst("] is expected to be an @-view")) ; /* tmp72 = */ atspre_prerr_newline () ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp73 = ats_select_mac(tmp65, atslab_0) ; tmp74 = ats_select_mac(tmp65, atslab_1) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (arg1) ; tmp76 = ats_select_mac(tmp75, atslab_0) ; tmp77 = ats_select_mac(tmp75, atslab_1) ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp77, arg2) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (tmp76, tmp78) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (tmp79 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_3, tmp79, atslab_0) ; ATS_FREE(tmp79) ; tmp81 = ats_select_mac(tmp80, atslab_0) ; tmp82 = ats_select_mac(tmp80, atslab_1) ; tmp83 = ats_select_mac(tmp80, atslab_2) ; tmp84 = ats_select_mac(tmp80, atslab_3) ; tmp85 = ats_select_mac(tmp80, atslab_4) ; tmp86 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local (tmp81) ; /* ats_ptr_type tmp87 ; */ tmp87 = (ats_sum_ptr_type)0 ; tmp88 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr (arg0, tmp82, tmp85, tmp73, (&tmp87)) ; tmp89 = ats_select_mac(tmp88, atslab_0) ; tmp90 = ats_select_mac(tmp88, atslab_1) ; tmp91 = ats_select_mac(tmp88, atslab_2) ; /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp87) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (tmp83, tmp91) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp93, tmp74) ; if (tmp95) { /* empty */ } else { /* tmp96 = */ prerr_loc_error3_0 (arg0) ; /* tmp97 = */ atspre_prerr_string (ATSstrcst(": address mismatch for @-view assignment: [")) ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp93) ; /* tmp99 = */ atspre_prerr_string (ATSstrcst("] <> [")) ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp74) ; /* tmp101 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp102 = */ atspre_prerr_newline () ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp103 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (tmp77, tmp84, tmp91) ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (tmp81, tmp90, tmp83) ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (arg0, tmp89) ; tmp64 = tmp103 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (tmp79 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: /* tmp106 = */ prerr_loc_error3_0 (arg0) ; /* tmp107 = */ atspre_prerr_string (ATSstrcst(": the @-view associated with the location [")) ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp76) ; /* tmp109 = */ atspre_prerr_string (ATSstrcst("] cannot be found.")) ; /* tmp110 = */ atspre_prerr_newline () ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp64) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 7163(line=217, offs=4) -- 8604(line=268, offs=4) */ ATSstaticdec() anairiats_rec_0 d2var_view_viewat_set_slablst_main_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (anairiats_rec_0, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (anairiats_rec_0, tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (anairiats_rec_1, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; ATSlocal (ats_bool_type, tmp131) ; // ATSlocal_void (tmp132) ; // ATSlocal_void (tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; // ATSlocal_void (tmp137) ; // ATSlocal_void (tmp138) ; // ATSlocal_void (tmp139) ; __ats_lab_d2var_view_viewat_set_slablst_main_8: tmp112 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg5) ; tmp114 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (tmp112) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp114 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_6, tmp114, atslab_0) ; ATS_FREE(tmp114) ; tmp113 = tmp115 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp114 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp116 = */ prerr_loc_error3_0 (arg0) ; /* tmp117 = */ atspre_prerr_string (ATSstrcst(": the view [")) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp112) ; /* tmp119 = */ atspre_prerr_string (ATSstrcst("] is expected to be an @-view")) ; /* tmp120 = */ atspre_prerr_newline () ; /* tmp113 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp121 = ats_select_mac(tmp113, atslab_0) ; tmp122 = ats_select_mac(tmp113, atslab_1) ; /* ats_ptr_type tmp123 ; */ tmp123 = (ats_sum_ptr_type)0 ; tmp124 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr (arg0, arg2, arg4, tmp121, (&tmp123)) ; tmp125 = ats_select_mac(tmp124, atslab_0) ; tmp126 = ats_select_mac(tmp124, atslab_1) ; tmp127 = ats_select_mac(tmp124, atslab_2) ; tmp128 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (arg3, tmp127) ; /* tmp129 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp123) ; tmp131 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp128, tmp122) ; if (tmp131) { /* empty */ } else { /* tmp132 = */ prerr_loc_error3_0 (arg0) ; /* tmp133 = */ atspre_prerr_string (ATSstrcst(": address mismatch for @-view restoration: [")) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp128) ; /* tmp135 = */ atspre_prerr_string (ATSstrcst("] <> [")) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp122) ; /* tmp137 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp138 = */ atspre_prerr_newline () ; /* tmp130 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ /* tmp139 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (arg1, tmp126, arg3) ; tmp111.atslab_0 = tmp125 ; tmp111.atslab_1 = tmp127 ; return (tmp111) ; } /* end of [d2var_view_viewat_set_slablst_main_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 8653(line=270, offs=4) -- 9690(line=301, offs=8) */ ATSstaticdec() anairiats_rec_0 d2var_view_viewat_set_slablst_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (anairiats_rec_0, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; // ATSlocal_void (tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_d2var_view_viewat_set_slablst_9: tmp141 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg1) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp141 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_14_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_7, tmp141, atslab_0) ; tmp143 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (tmp142) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp143 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_6, tmp143, atslab_0) ; ATS_FREE(tmp143) ; tmp145 = ats_select_mac(tmp144, atslab_0) ; tmp146 = ats_select_mac(tmp144, atslab_1) ; tmp140 = d2var_view_viewat_set_slablst_main_8 (arg0, arg1, tmp145, tmp146, arg2, arg3) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (tmp143 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: /* tmp147 = */ prerr_loc_error3_0 (arg0) ; /* tmp148 = */ atspre_prerr_string (ATSstrcst(": the view of [")) ; /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp150 = */ atspre_prerr_string (ATSstrcst("] is expected to be an @-view but it is [")) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp142) ; /* tmp152 = */ atspre_prerr_string (ATSstrcst("] instead.")) ; /* tmp153 = */ atspre_prerr_newline () ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (tmp141 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp154 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp155 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, arg1) ; tmp140 = d2var_view_viewat_set_slablst_main_8 (arg0, arg1, tmp154, tmp155, arg2, arg3) ; break ; } while (0) ; return (tmp140) ; } /* end of [d2var_view_viewat_set_slablst_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 9776(line=306, offs=5) -- 10217(line=318, offs=31) */ ATSstaticdec() ats_ptr_type s2lab0lst_of_d3lab1lst_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_s2lab0lst_of_d3lab1lst_10: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp160 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp157), atslab_d3lab1_node) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp160)->tag != 1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_9, tmp160, atslab_0) ; tmp162 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind (tmp161) ; tmp159 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp159)->tag = 1 ; ats_selptrset_mac(anairiats_sum_10, tmp159, atslab_0, tmp162) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (((ats_sum_ptr_type)tmp160)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_9, tmp160, atslab_0) ; tmp159 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp159)->tag = 0 ; ats_selptrset_mac(anairiats_sum_10, tmp159, atslab_0, tmp163) ; break ; } while (0) ; tmp164 = s2lab0lst_of_d3lab1lst_10 (tmp158) ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp156, atslab_0, tmp159) ; ats_selptrset_mac(anairiats_sum_4, tmp156, atslab_1, tmp164) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp156 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp156) ; } /* end of [s2lab0lst_of_d3lab1lst_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 10547(line=333, offs=6) -- 10928(line=344, offs=8) */ ATSstaticdec() ats_void_type refval_check_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp166) ; ATSlocal (ats_bool_type, tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; // ATSlocal_void (tmp172) ; __ats_lab_refval_check_12: tmp167 = atspre_gt_int_int (arg2, 0) ; if (tmp167) { /* tmp168 = */ prerr_loc_error3_0 (arg0) ; /* tmp169 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp171 = */ atspre_prerr_string (ATSstrcst("] is required to be mutable for supporting call-by-reference.")) ; /* tmp172 = */ atspre_prerr_newline () ; /* tmp166 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp166) */ ; } /* end of [refval_check_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 10304(line=324, offs=20) -- 13692(line=433, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_bool_type, tmp187) ; // ATSlocal_void (tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_bool_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_bool_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_bool_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_bool_type, tmp204) ; // ATSlocal_void (tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (anairiats_rec_0, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (anairiats_rec_0, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_int_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ: tmp173 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg2), atslab_d3exp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp173)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp174 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp173)->tag != 44) { goto __ats_lab_26_0 ; } __ats_lab_23_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_1) ; tmp178 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, tmp175), atslab_d3exp_typ) ; tmp177 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp178) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp177 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_7, tmp177, atslab_0) ; ATS_FREE(tmp177) ; tmp180 = s2lab0lst_of_d3lab1lst_10 (tmp176) ; tmp181 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst (arg0, tmp179, tmp180, arg3) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (tmp177 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: /* tmp182 = */ prerr_loc_interror_2 (arg0) ; /* tmp183 = */ atspre_prerr_string (ATSstrcst(": d3exp_lval_set_typ: D3Esel_ptr")) ; /* tmp184 = */ atspre_prerr_newline () ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp173)->tag != 45) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_0) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_1) ; tmp187 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (tmp185) ; if (!tmp187) { goto __ats_lab_27_1 ; } /* tmp188 = */ refval_check_12 (arg0, tmp185, arg1) ; tmp189 = s2lab0lst_of_d3lab1lst_10 (tmp186) ; tmp190 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst (arg0, tmp185, tmp189, arg3) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp173)->tag != 45) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_0) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_9, tmp173, atslab_1) ; tmp193 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp191) ; if (!tmp193) { goto __ats_lab_33_1 ; } tmp194 = s2lab0lst_of_d3lab1lst_10 (tmp192) ; tmp195 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst (arg0, tmp191, tmp194, arg3) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp173)->tag != 54) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp196 = ats_caselptrlab_mac(anairiats_sum_10, tmp173, atslab_0) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix (tmp196) ; if (!tmp197) { goto __ats_lab_29_1 ; } tmp198 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp198 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp173)->tag != 54) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_10, tmp173, atslab_0) ; tmp200 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp199) ; if (!tmp200) { goto __ats_lab_30_1 ; } tmp202 = (ats_sum_ptr_type)0 ; tmp201 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst (arg0, tmp199, tmp202, arg3) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp173)->tag != 54) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp203 = ats_caselptrlab_mac(anairiats_sum_10, tmp173, atslab_0) ; tmp204 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (tmp203) ; if (!tmp204) { goto __ats_lab_33_1 ; } /* tmp205 = */ refval_check_12 (arg0, tmp203, arg1) ; tmp207 = (ats_sum_ptr_type)0 ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst (arg0, tmp203, tmp207, arg3) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp173)->tag != 57) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_12, tmp173, atslab_2) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_12, tmp173, atslab_3) ; tmp210 = d2var_view_viewat_set_slablst_9 (arg0, tmp208, tmp209, arg3) ; tmp211 = ats_select_mac(tmp210, atslab_0) ; tmp212 = ats_select_mac(tmp210, atslab_1) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (arg0, tmp211) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp173)->tag != 58) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_12, tmp173, atslab_2) ; tmp214 = ats_caselptrlab_mac(anairiats_sum_12, tmp173, atslab_3) ; tmp215 = d2var_view_viewat_set_slablst_9 (arg0, tmp213, tmp214, arg3) ; tmp216 = ats_select_mac(tmp215, atslab_0) ; tmp217 = ats_select_mac(tmp215, atslab_1) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (arg0, tmp216) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp218 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp218 ; break ; } while (0) ; return /* (tmp165) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 13759(line=439, offs=4) -- 14055(line=447, offs=4) */ ATSstaticdec() ats_bool_type s2exp_fun_is_freeptr_13 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_int_type, tmp223) ; ATSlocal (ats_bool_type, tmp224) ; ATSlocal (ats_bool_type, tmp225) ; __ats_lab_s2exp_fun_is_freeptr_13: tmp220 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp220)->tag != 11) { goto __ats_lab_37_0 ; } __ats_lab_34_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_14, tmp220, atslab_0) ; tmp222 = ats_caselptrlab_mac(anairiats_sum_14, tmp220, atslab_1) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp221 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_15, tmp221, atslab_0) ; tmp224 = atspre_gt_int_int (tmp223, 0) ; if (!tmp224) { goto __ats_lab_36_1 ; } tmp225 = atspre_eq_int_int (tmp222, 0) ; if (tmp225) { tmp219 = ats_true_bool ; } else { tmp219 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: __ats_lab_36_1: tmp219 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: tmp219 = ats_false_bool ; break ; } while (0) ; return (tmp219) ; } /* end of [s2exp_fun_is_freeptr_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 14146(line=453, offs=3) -- 14882(line=470, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_int_type, tmp228) ; ATSlocal (ats_int_type, tmp229) ; // ATSlocal_void (tmp230) ; // ATSlocal_void (tmp231) ; ATSlocal (ats_bool_type, tmp232) ; ATSlocal (ats_bool_type, tmp233) ; ATSlocal (ats_bool_type, tmp234) ; // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; // ATSlocal_void (tmp237) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg: tmp227 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_d3exp_loc) ; /* ats_int_type tmp228 ; */ tmp228 = 0 ; /* ats_int_type tmp229 ; */ tmp229 = 0 ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ (tmp227, arg0, arg1, arg2, (&tmp228)) ; tmp232 = atspre_gt_int_int (tmp228, 0) ; if (tmp232) { do { /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp233 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin (arg2) ; if (!tmp233) { goto __ats_lab_39_1 ; } break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp234 = s2exp_fun_is_freeptr_13 (arg2) ; if (!tmp234) { goto __ats_lab_40_1 ; } tmp229 = 1 ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: /* tmp235 = */ prerr_loc_error3_0 (tmp227) ; /* tmp236 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression needs to be a left-value but it is not.")) ; /* tmp237 = */ atspre_prerr_newline () ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { /* empty */ } /* end of [if] */ tmp226 = tmp229 ; return (tmp226) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_view.dats: 15001(line=478, offs=3) -- 15477(line=492, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; // ATSlocal_void (tmp243) ; ATSlocal (ats_bool_type, tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; // ATSlocal_void (tmp247) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat: tmp239 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg1), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (tmp239 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp240 = ats_caselptrlab_mac(anairiats_sum_7, tmp239, atslab_0) ; tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_d3exp_loc) ; /* ats_int_type tmp242 ; */ tmp242 = 0 ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ (tmp241, 0, arg0, tmp240, (&tmp242)) ; tmp244 = atspre_gt_int_int (tmp242, 0) ; if (tmp244) { /* tmp245 = */ prerr_loc_error3_0 (tmp241) ; /* tmp246 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression needs to be a left-value but it is not.")) ; /* tmp247 = */ atspre_prerr_newline () ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (tmp239 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: break ; } while (0) ; return /* (tmp238) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_view_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp1_syndef_dats.c0000664000175000017500000024043012223166160023062 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_i1nvresstate_qua ; ats_ptr_type atslab_i1nvresstate_arg ; } anairiats_rec_1 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_tmpqi0de_loc ; ats_ptr_type atslab_tmpqi0de_qua ; ats_ptr_type atslab_tmpqi0de_sym ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_10 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_neg_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IF) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUPZ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0ynq_none) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_bool) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext_sym) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__atsyndef_search_all_default) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__atsyndef_search_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_IF) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_if_p3) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_DO) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_do_n1_p1_n1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_WHILE) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_while_n1_p1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINT) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINTLN) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_println_n1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERR) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERRLN) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerrln_n1) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINT) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprint_n2) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINTLN) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprintln_n2) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) ; static ats_void_type loop_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_ptr_type mapf_26 (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; static ats_ptr_type d1exp_applstseq_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) ; static ats_ptr_type d1exp_appseq_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) ; static ats_ptr_type __ats_fun_32 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_32_closure_make (ats_ptr_type env0) ; static ats_ptr_type __ats_fun_32_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_35 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_35_closure_make (ats_ptr_type env0) ; static ats_ptr_type __ats_fun_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_38 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_38_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type __ats_fun_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_40 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_40_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type __ats_fun_40_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp79) ; ATSstatic (ats_ptr_type, statmp80) ; ATSstatic (ats_ptr_type, statmp81) ; ATSstatic (ats_ptr_type, statmp82) ; ATSstatic (ats_ptr_type, statmp83) ; ATSstatic (ats_ptr_type, statmp84) ; ATSstatic (ats_ptr_type, statmp85) ; ATSstatic (ats_ptr_type, statmp86) ; ATSstatic (ats_ptr_type, statmp87) ; ATSstatic (ats_ptr_type, statmp88) ; ATSstatic (ats_ptr_type, statmp89) ; ATSstatic (ats_ptr_type, statmp90) ; ATSstatic (ats_ptr_type, statmp91) ; ATSstatic (ats_ptr_type, statmp110) ; ATSstatic (ats_ptr_type, statmp111) ; ATSstatic (ats_ptr_type, statmp112) ; ATSstatic (ats_ptr_type, statmp113) ; ATSstatic (ats_ptr_type, statmp114) ; ATSstatic (ats_ptr_type, statmp115) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 2089(line=67, offs=4) -- 2176(line=69, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error1_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error1_0] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 2276(line=77, offs=7) -- 2571(line=88, offs=24) */ ATSstaticdec() ats_void_type loop_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp3) ; ATSlocal (ats_int_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; // ATSlocal_void (tmp6) ; ATSlocal (ats_bool_type, tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_int_type, tmp9) ; __ats_lab_loop_2: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp5 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp7 = atspre_gt_int_int (arg2, 0) ; if (tmp7) { /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp8 = */ atspre_fprint_int (arg0, tmp4) ; tmp9 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp5 ; arg2 = tmp9 ; goto __ats_lab_loop_2 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp3) */ ; } /* end of [loop_2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 2254(line=76, offs=3) -- 2617(line=92, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__fprint_intlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__fprint_intlst: /* tmp2 = */ loop_2 (arg0, arg1, 0) ; return /* (tmp2) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__fprint_intlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 2765(line=104, offs=21) -- 3316(line=120, offs=6) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_int_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_bool_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_bool_type, tmp17) ; ATSlocal (ats_bool_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; do { /* branch: __ats_lab_3 */ __ats_lab_3_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp15 = atspre_gte_int_int (tmp13, 0) ; if (tmp15) { tmp16 = atspre_eq_int_int (tmp11, tmp13) ; if (tmp16) { arg0 = tmp12 ; arg1 = tmp14 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst ; // tail call } else { tmp10 = ats_false_bool ; } /* end of [if] */ } else { tmp17 = atspre_lte_int_int (tmp13, -2) ; if (tmp17) { tmp19 = atspre_add_int_int (tmp11, 1) ; tmp20 = atspre_neg_int (tmp13) ; tmp18 = atspre_gte_int_int (tmp19, tmp20) ; if (tmp18) { arg0 = tmp12 ; arg1 = tmp14 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst ; // tail call } else { tmp10 = ats_false_bool ; } /* end of [if] */ } else { arg0 = tmp12 ; arg1 = tmp14 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst ; // tail call } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: tmp10 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp10 = ats_false_bool ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp10 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 3422(line=127, offs=3) -- 3496(line=129, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__tmpqi0de_make_qid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__tmpqi0de_make_qid: tmp21 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp21, atslab_tmpqi0de_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp21, atslab_tmpqi0de_qua, arg1) ; ats_selptrset_mac(anairiats_rec_3, tmp21, atslab_tmpqi0de_sym, arg2) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__tmpqi0de_make_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 3579(line=135, offs=3) -- 3857(line=143, offs=8) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_ann_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_ann_type: tmp23 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp23)->tag != 2) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_5, tmp23, atslab_0) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_5, tmp23, atslab_1) ; tmp22.atslab_0 = tmp24 ; tmp22.atslab_1 = tmp25 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp26 = */ prerr_loc_error1_0 (tmp27) ; /* tmp28 = */ atspre_prerr_string (ATSstrcst(": the dynexp is expected be some annotated expression.")) ; /* tmp29 = */ atspre_prerr_newline () ; /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_ann_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 3949(line=149, offs=16) -- 4230(line=158, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext: tmp31 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp31)->tag != 25) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_6, tmp31, atslab_0) ; tmp30 = tmp32 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp34 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp33 = */ prerr_loc_error1_0 (tmp34) ; /* tmp35 = */ atspre_prerr_string (ATSstrcst(": the dynexp is expected to be some external identifer.")) ; /* tmp36 = */ atspre_prerr_newline () ; /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 4304(line=163, offs=3) -- 4672(line=176, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext_sym (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_bool_type, tmp39) ; // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext_sym: tmp38 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext (arg0) ; tmp39 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, tmp38) ; if (tmp39) { /* empty */ } else { tmp41 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp40 = */ prerr_loc_error1_0 (tmp41) ; /* tmp42 = */ atspre_prerr_string (ATSstrcst(": the external id [")) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp44 = */ atspre_prerr_string (ATSstrcst("] is expected.")) ; /* tmp45 = */ atspre_prerr_newline () ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 4749(line=181, offs=14) -- 5021(line=190, offs=8) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; // ATSlocal_void (tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp47)->tag != 41) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_0) ; tmp49 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_1) ; tmp46.atslab_0 = tmp48 ; tmp46.atslab_1 = tmp49 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp51 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp50 = */ prerr_loc_error1_0 (tmp51) ; /* tmp52 = */ atspre_prerr_string (ATSstrcst(": the dynexp is expected be some (qualified) identifier.")) ; /* tmp53 = */ atspre_prerr_newline () ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 5091(line=195, offs=3) -- 5457(line=208, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid_sym (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp54) ; ATSlocal (anairiats_rec_0, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_bool_type, tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid_sym: tmp55 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid (arg0) ; tmp56 = ats_select_mac(tmp55, atslab_0) ; tmp57 = ats_select_mac(tmp55, atslab_1) ; tmp58 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, tmp57) ; if (tmp58) { /* empty */ } else { tmp60 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp59 = */ prerr_loc_error1_0 (tmp60) ; /* tmp61 = */ atspre_prerr_string (ATSstrcst(": the symbol [")) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp63 = */ atspre_prerr_string (ATSstrcst("] is expected.")) ; /* tmp64 = */ atspre_prerr_newline () ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp54) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_qid_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 5536(line=213, offs=18) -- 5807(line=222, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_sexparg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_sexparg: tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp66)->tag != 47) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_7, tmp66, atslab_0) ; tmp65 = tmp67 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: tmp69 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp68 = */ prerr_loc_error1_0 (tmp69) ; /* tmp70 = */ atspre_prerr_string (ATSstrcst(": the dynexp is expected to be a static argument.")) ; /* tmp71 = */ atspre_prerr_newline () ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp65) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_sexparg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 5899(line=228, offs=17) -- 6177(line=237, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_decseq (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_decseq: tmp73 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp73)->tag != 13) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_7, tmp73, atslab_0) ; tmp72 = tmp74 ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp76 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; /* tmp75 = */ prerr_loc_error1_0 (tmp76) ; /* tmp77 = */ atspre_prerr_string (ATSstrcst(": the dynexp is expected to be a list of declarations.")) ; /* tmp78 = */ atspre_prerr_newline () ; /* tmp72 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_decseq] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 7121(line=282, offs=11) -- 7333(line=292, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_IF (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_bool_type, tmp93) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_IF: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp90) ; if (!tmp93) { goto __ats_lab_19_1 ; } tmp92 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp92, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_if_p3) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp92 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp92) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_IF] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 7542(line=304, offs=11) -- 7766(line=314, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_DO (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_bool_type, tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_DO: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp95 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp84) ; if (!tmp95) { goto __ats_lab_21_1 ; } tmp94 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp94, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_do_n1_p1_n1) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp94 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_DO] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 7983(line=327, offs=14) -- 8207(line=337, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_WHILE (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_bool_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_WHILE: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp97 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp81) ; if (!tmp97) { goto __ats_lab_23_1 ; } tmp96 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp96, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_while_n1_p1) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: tmp96 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp96) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_WHILE] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 8389(line=346, offs=14) -- 8607(line=356, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINT (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_bool_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINT: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp99 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp79) ; if (!tmp99) { goto __ats_lab_25_1 ; } tmp98 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp98, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp98 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp98) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINT] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 8775(line=363, offs=16) -- 8997(line=373, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINTLN (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_bool_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINTLN: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp101 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp79) ; if (!tmp101) { goto __ats_lab_27_1 ; } tmp100 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp100, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_println_n1) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp100 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp100) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINTLN] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 9160(line=380, offs=14) -- 9378(line=390, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERR (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_bool_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERR: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp103 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp79) ; if (!tmp103) { goto __ats_lab_29_1 ; } tmp102 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp102, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp102 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp102) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERR] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 9546(line=397, offs=16) -- 9768(line=407, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERRLN (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_bool_type, tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERRLN: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp105 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp79) ; if (!tmp105) { goto __ats_lab_31_1 ; } tmp104 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp104, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerrln_n1) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp104 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERRLN] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 9934(line=414, offs=15) -- 10154(line=424, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINT (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_bool_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINT: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp107 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp88) ; if (!tmp107) { goto __ats_lab_33_1 ; } tmp106 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp106, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprint_n2) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp106 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp106) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINT] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 10325(line=431, offs=17) -- 10549(line=441, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINTLN (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_bool_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINTLN: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: __ats_lab_34_1: tmp109 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__match_intlst_intlst (arg0, statmp88) ; if (!tmp109) { goto __ats_lab_35_1 ; } tmp108 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp108, atslab_0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprintln_n2) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: tmp108 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINTLN] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 11074(line=457, offs=3) -- 11937(line=486, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__atsyndef_search_all_default (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_bool_type, tmp117) ; ATSlocal (ats_bool_type, tmp118) ; ATSlocal (ats_bool_type, tmp119) ; ATSlocal (ats_bool_type, tmp120) ; ATSlocal (ats_bool_type, tmp121) ; ATSlocal (ats_bool_type, tmp122) ; ATSlocal (ats_bool_type, tmp123) ; ATSlocal (ats_bool_type, tmp124) ; ATSlocal (ats_bool_type, tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__atsyndef_search_all_default: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: __ats_lab_36_1: tmp117 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IF) ; if (!tmp117) { goto __ats_lab_37_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_IF (arg1) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: tmp118 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO) ; if (!tmp118) { goto __ats_lab_38_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_DO (arg1) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp119 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; if (!tmp119) { goto __ats_lab_39_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_WHILE (arg1) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp120 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp110) ; if (!tmp120) { goto __ats_lab_40_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINT (arg1) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp121 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp111) ; if (!tmp121) { goto __ats_lab_41_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRINTLN (arg1) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp122 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp112) ; if (!tmp122) { goto __ats_lab_42_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERR (arg1) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp123 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp113) ; if (!tmp123) { goto __ats_lab_43_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_PRERRLN (arg1) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp124 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp114) ; if (!tmp124) { goto __ats_lab_44_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINT (arg1) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp125 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, statmp115) ; if (!tmp125) { goto __ats_lab_45_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__search_FPRINTLN (arg1) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp116 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp116) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__atsyndef_search_all_default] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 14282(line=586, offs=3) -- 14329(line=586, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__atsyndef_search_all (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__atsyndef_search_all: tmp126 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__atsyndef_search_all_default (arg0, arg1) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__atsyndef_search_all] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 14450(line=595, offs=3) -- 14768(line=606, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_idextapp_resolve (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_bool_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_idextapp_resolve: tmp128 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp128)->tag != 25) { goto __ats_lab_49_0 ; } __ats_lab_46_1: tmp129 = ats_caselptrlab_mac(anairiats_sum_6, tmp128, atslab_0) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_6, tmp128, atslab_2) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp131 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp129, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUPZ) ; if (!tmp131) { goto __ats_lab_48_1 ; } tmp132 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp130) ; tmp127 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list (arg0, tmp132) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: __ats_lab_48_1: tmp127 = arg1 ; break ; } while (0) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: tmp127 = arg1 ; break ; } while (0) ; return (tmp127) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_idextapp_resolve] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 14853(line=611, offs=18) -- 16100(line=645, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_app_syndef (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_int_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_app_syndef: tmp134 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp134)->tag != 25) { goto __ats_lab_55_0 ; } __ats_lab_50_1: tmp135 = ats_caselptrlab_mac(anairiats_sum_6, tmp134, atslab_0) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_6, tmp134, atslab_1) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_6, tmp134, atslab_2) ; tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg2), atslab_d1exp_node) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp139)->tag != 36) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp140 = ats_caselptrlab_mac(anairiats_sum_9, tmp139, atslab_1) ; tmp138 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp140) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp138 = 1 ; break ; } while (0) ; tmp141 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp141, atslab_0, tmp138) ; ats_selptrset_mac(anairiats_sum_2, tmp141, atslab_1, tmp136) ; tmp142 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp142, atslab_1, tmp137) ; tmp143 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__atsyndef_search_all (tmp135, tmp141) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (tmp143 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_8, tmp143, atslab_0) ; ATS_FREE(tmp143) ; tmp133 = ((ats_ptr_type(*)(ats_ptr_type, ats_ptr_type))tmp144) (arg0, tmp142) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (tmp143 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp (arg0, tmp135, tmp141, tmp142) ; break ; } while (0) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp145 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg2), atslab_d1exp_node) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp145)->tag != 36) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_9, tmp145, atslab_0) ; tmp147 = ats_caselptrlab_mac(anairiats_sum_9, tmp145, atslab_1) ; tmp148 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg2), atslab_d1exp_loc) ; tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, arg1, tmp148, tmp146, tmp147) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp145)->tag != 47) { goto __ats_lab_60_0 ; } __ats_lab_57_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_7, tmp145, atslab_0) ; tmp150 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp150)->tag != 4) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp151 = ats_caselptrlab_mac(anairiats_sum_5, tmp150, atslab_0) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_5, tmp150, atslab_1) ; tmp153 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp152, tmp149) ; tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta (arg0, tmp151, tmp153) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp155 = (ats_sum_ptr_type)0 ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp154, atslab_0, tmp149) ; ats_selptrset_mac(anairiats_sum_10, tmp154, atslab_1, tmp155) ; tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta (arg0, arg1, tmp154) ; break ; } while (0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp157 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp156, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp156, atslab_1, tmp157) ; tmp158 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg2), atslab_d1exp_loc) ; tmp133 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, arg1, tmp158, 0, tmp156) ; break ; } while (0) ; break ; } while (0) ; return (tmp133) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__d1exp_app_syndef] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16272(line=655, offs=7) -- 16462(line=660, offs=33) */ ATSstaticdec() ats_ptr_type mapf_26 (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_mapf_26: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_10, arg0, atslab_0) ; tmp162 = ats_caselptrlab_mac(anairiats_sum_10, arg0, atslab_1) ; tmp163 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg1))) (arg1, tmp161) ; tmp164 = mapf_26 (tmp162, arg1) ; tmp160 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp160, atslab_0, tmp163) ; ats_selptrset_mac(anairiats_sum_10, tmp160, atslab_1, tmp164) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: tmp160 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp160) ; } /* end of [mapf_26] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16170(line=650, offs=5) -- 16523(line=664, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_applstseq_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp165) ; __ats_lab_d1exp_applstseq_25: tmp165 = mapf_26 (arg1, arg2) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (arg0, tmp165) ; return (tmp159) ; } /* end of [d1exp_applstseq_25] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16557(line=666, offs=5) -- 16758(line=674, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_appseq_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_clo_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_d1exp_appseq_27: tmp167 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp167)->tag != 36) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_9, tmp167, atslab_1) ; tmp166 = d1exp_applstseq_25 (arg0, tmp168, arg2) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: tmp166 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg2))) (arg2, arg1) ; break ; } while (0) ; return (tmp166) ; } /* end of [d1exp_appseq_27] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16830(line=680, offs=3) -- 17110(line=689, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_if_p3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_if_p3: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16855(line=681, offs=8) -- 16875(line=681, offs=28)") ; } tmp170 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp171 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp170), atslab_d1exp_node) ; if (((ats_sum_ptr_type)tmp171)->tag != 36) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16883(line=682, offs=8) -- 16918(line=682, offs=43)") ; } tmp172 = ats_caselptrlab_mac(anairiats_sum_9, tmp171, atslab_1) ; if (tmp172 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16926(line=683, offs=8) -- 16951(line=683, offs=33)") ; } tmp173 = ats_caselptrlab_mac(anairiats_sum_10, tmp172, atslab_0) ; tmp174 = ats_caselptrlab_mac(anairiats_sum_10, tmp172, atslab_1) ; if (tmp174 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16959(line=684, offs=8) -- 16984(line=684, offs=33)") ; } tmp175 = ats_caselptrlab_mac(anairiats_sum_10, tmp174, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_10, tmp174, atslab_1) ; if (tmp176 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 16992(line=685, offs=8) -- 17017(line=685, offs=33)") ; } tmp177 = ats_caselptrlab_mac(anairiats_sum_10, tmp176, atslab_0) ; tmp178 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp178, atslab_0, tmp177) ; tmp169 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if (arg0, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil, tmp173, tmp175, tmp178) ; return (tmp169) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_if_p3] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17187(line=695, offs=3) -- 17755(line=717, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_do_n1_p1_n1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_do_n1_p1_n1: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17216(line=697, offs=8) -- 17240(line=697, offs=32)") ; } tmp180 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_1) ; if (tmp181 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17251(line=699, offs=8) -- 17275(line=699, offs=32)") ; } tmp182 = ats_caselptrlab_mac(anairiats_sum_10, tmp181, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_10, tmp181, atslab_1) ; /* tmp184 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__un_d1exp_idext_sym (tmp182, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; if (tmp183 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17342(line=702, offs=8) -- 17366(line=702, offs=32)") ; } tmp185 = ats_caselptrlab_mac(anairiats_sum_10, tmp183, atslab_0) ; tmp186 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn (arg0, 1) ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn (arg0, 0) ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp187, atslab_0, tmp188) ; tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp180), atslab_d1exp_loc) ; tmp190 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if (tmp189, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil, tmp180, tmp186, tmp187) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil (arg0) ; tmp192 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_bool (arg0, ats_true_bool) ; tmp196 = (ats_sum_ptr_type)0 ; tmp195 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp195, atslab_0, tmp190) ; ats_selptrset_mac(anairiats_sum_10, tmp195, atslab_1, tmp196) ; tmp194 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp194, atslab_0, tmp185) ; ats_selptrset_mac(anairiats_sum_10, tmp194, atslab_1, tmp195) ; tmp193 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (arg0, tmp194) ; tmp179 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while (arg0, tmp191, tmp192, tmp193) ; return (tmp179) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_do_n1_p1_n1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17832(line=723, offs=3) -- 18045(line=735, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_while_n1_p1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_while_n1_p1: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17861(line=725, offs=8) -- 17885(line=725, offs=32)") ; } tmp198 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp199 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_1) ; if (tmp199 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 17915(line=728, offs=8) -- 17939(line=728, offs=32)") ; } tmp200 = ats_caselptrlab_mac(anairiats_sum_10, tmp199, atslab_0) ; tmp201 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil (arg0) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while (arg0, tmp201, tmp200, tmp198) ; return (tmp197) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_while_n1_p1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18259(line=745, offs=11) -- 18407(line=751, offs=6) */ ATSstaticdec() ats_ptr_type __ats_fun_32 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab___ats_fun_32: tmp207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; tmp209 = (ats_sum_ptr_type)0 ; tmp208 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp208, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_10, tmp208, atslab_1, tmp209) ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (tmp207, env0, tmp207, 0, tmp208) ; return (tmp206) ; } /* end of [__ats_fun_32] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_32_closure_type ; ats_ptr_type __ats_fun_32_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_32 (((__ats_fun_32_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_32_closure_init (__ats_fun_32_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_32_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_32_closure_make (ats_ptr_type env0) { __ats_fun_32_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_32_closure_type)) ; __ats_fun_32_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18125(line=741, offs=3) -- 18508(line=756, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; // ATSlocal_void (tmp212) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18151(line=742, offs=8) -- 18172(line=742, offs=29)") ; } tmp203 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp204 = d0ynq_none () ; tmp205 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp204, statmp110) ; tmp210 = __ats_fun_32_closure_make (tmp205) ; tmp211 = d1exp_appseq_27 (arg0, tmp203, tmp210) ; /* tmp212 = */ atspre_cloptr_free (tmp210) ; tmp202 = tmp211 ; return (tmp202) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18560(line=760, offs=3) -- 18901(line=771, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_println_n1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_println_n1: tmp214 = d0ynq_none () ; tmp215 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("print_newline")) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp214, tmp215) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_print_n1 (arg0, arg1) ; tmp219 = (ats_sum_ptr_type)0 ; tmp218 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, tmp216, arg0, 0, tmp219) ; tmp222 = (ats_sum_ptr_type)0 ; tmp221 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp221, atslab_0, tmp218) ; ats_selptrset_mac(anairiats_sum_10, tmp221, atslab_1, tmp222) ; tmp220 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp220, atslab_0, tmp217) ; ats_selptrset_mac(anairiats_sum_10, tmp220, atslab_1, tmp221) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (arg0, tmp220) ; return (tmp213) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_println_n1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 19087(line=779, offs=11) -- 19235(line=785, offs=6) */ ATSstaticdec() ats_ptr_type __ats_fun_35 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab___ats_fun_35: tmp228 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; tmp230 = (ats_sum_ptr_type)0 ; tmp229 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp229, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_10, tmp229, atslab_1, tmp230) ; tmp227 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (tmp228, env0, tmp228, 0, tmp229) ; return (tmp227) ; } /* end of [__ats_fun_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_35_closure_type ; ats_ptr_type __ats_fun_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_35 (((__ats_fun_35_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_35_closure_init (__ats_fun_35_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_35_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_35_closure_make (ats_ptr_type env0) { __ats_fun_35_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_35_closure_type)) ; __ats_fun_35_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18953(line=775, offs=3) -- 19336(line=790, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 18979(line=776, offs=8) -- 19000(line=776, offs=29)") ; } tmp224 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp225 = d0ynq_none () ; tmp226 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp225, statmp112) ; tmp231 = __ats_fun_35_closure_make (tmp226) ; tmp232 = d1exp_appseq_27 (arg0, tmp224, tmp231) ; /* tmp233 = */ atspre_cloptr_free (tmp231) ; tmp223 = tmp232 ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 19388(line=794, offs=3) -- 19729(line=805, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerrln_n1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerrln_n1: tmp235 = d0ynq_none () ; tmp236 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("prerr_newline")) ; tmp237 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp235, tmp236) ; tmp238 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerr_n1 (arg0, arg1) ; tmp240 = (ats_sum_ptr_type)0 ; tmp239 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, tmp237, arg0, 0, tmp240) ; tmp243 = (ats_sum_ptr_type)0 ; tmp242 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp242, atslab_0, tmp239) ; ats_selptrset_mac(anairiats_sum_10, tmp242, atslab_1, tmp243) ; tmp241 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp241, atslab_0, tmp238) ; ats_selptrset_mac(anairiats_sum_10, tmp241, atslab_1, tmp242) ; tmp234 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (arg0, tmp241) ; return (tmp234) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_prerrln_n1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 20093(line=818, offs=11) -- 20262(line=823, offs=6) */ ATSstaticdec() ats_ptr_type __ats_fun_38 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab___ats_fun_38: tmp257 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; tmp260 = (ats_sum_ptr_type)0 ; tmp259 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp259, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_10, tmp259, atslab_1, tmp260) ; tmp258 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp258, atslab_0, env1) ; ats_selptrset_mac(anairiats_sum_10, tmp258, atslab_1, tmp259) ; tmp256 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (tmp257, env0, tmp257, 0, tmp258) ; return (tmp256) ; } /* end of [__ats_fun_38] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } __ats_fun_38_closure_type ; ats_ptr_type __ats_fun_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_38 (((__ats_fun_38_closure_type*)cloptr)->closure_env_0, ((__ats_fun_38_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_38_closure_init (__ats_fun_38_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_38_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_38_closure_make (ats_ptr_type env0, ats_ptr_type env1) { __ats_fun_38_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_38_closure_type)) ; __ats_fun_38_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 19803(line=811, offs=3) -- 20370(line=828, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprint_n2 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (anairiats_rec_0, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; // ATSlocal_void (tmp263) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprint_n2: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 19829(line=812, offs=8) -- 19850(line=812, offs=29)") ; } tmp245 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp246 = d0ynq_none () ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp246, statmp114) ; tmp249 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp245), atslab_d1exp_node) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp249)->tag != 36) { goto __ats_lab_66_0 ; } tmp250 = ats_caselptrlab_mac(anairiats_sum_9, tmp249, atslab_1) ; if (tmp250 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp251 = ats_caselptrlab_mac(anairiats_sum_10, tmp250, atslab_0) ; tmp252 = ats_caselptrlab_mac(anairiats_sum_10, tmp250, atslab_1) ; tmp248.atslab_0 = tmp251 ; tmp248.atslab_1 = tmp252 ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp253 = (ats_sum_ptr_type)0 ; tmp248.atslab_0 = tmp245 ; tmp248.atslab_1 = tmp253 ; break ; } while (0) ; tmp254 = ats_select_mac(tmp248, atslab_0) ; tmp255 = ats_select_mac(tmp248, atslab_1) ; tmp261 = __ats_fun_38_closure_make (tmp247, tmp254) ; tmp262 = d1exp_applstseq_25 (arg0, tmp255, tmp261) ; /* tmp263 = */ atspre_cloptr_free (tmp261) ; tmp244 = tmp262 ; return (tmp244) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprint_n2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 20735(line=841, offs=11) -- 20904(line=846, offs=6) */ ATSstaticdec() ats_ptr_type __ats_fun_40 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; __ats_lab___ats_fun_40: tmp277 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d1exp_loc) ; tmp280 = (ats_sum_ptr_type)0 ; tmp279 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp279, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_10, tmp279, atslab_1, tmp280) ; tmp278 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp278, atslab_0, env1) ; ats_selptrset_mac(anairiats_sum_10, tmp278, atslab_1, tmp279) ; tmp276 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (tmp277, env0, tmp277, 0, tmp278) ; return (tmp276) ; } /* end of [__ats_fun_40] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } __ats_fun_40_closure_type ; ats_ptr_type __ats_fun_40_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_40 (((__ats_fun_40_closure_type*)cloptr)->closure_env_0, ((__ats_fun_40_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_40_closure_init (__ats_fun_40_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_40_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_40_closure_make (ats_ptr_type env0, ats_ptr_type env1) { __ats_fun_40_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_40_closure_type)) ; __ats_fun_40_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 20445(line=834, offs=3) -- 21260(line=856, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprintln_n2 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (anairiats_rec_0, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; // ATSlocal_void (tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprintln_n2: if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1_syndef.dats: 20471(line=835, offs=8) -- 20492(line=835, offs=29)") ; } tmp265 = ats_caselptrlab_mac(anairiats_sum_10, arg1, atslab_0) ; tmp266 = d0ynq_none () ; tmp267 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp266, statmp114) ; tmp269 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp265), atslab_d1exp_node) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp269)->tag != 36) { goto __ats_lab_68_0 ; } tmp270 = ats_caselptrlab_mac(anairiats_sum_9, tmp269, atslab_1) ; if (tmp270 == (ats_sum_ptr_type)0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp271 = ats_caselptrlab_mac(anairiats_sum_10, tmp270, atslab_0) ; tmp272 = ats_caselptrlab_mac(anairiats_sum_10, tmp270, atslab_1) ; tmp268.atslab_0 = tmp271 ; tmp268.atslab_1 = tmp272 ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: __ats_lab_68_1: tmp273 = (ats_sum_ptr_type)0 ; tmp268.atslab_0 = tmp265 ; tmp268.atslab_1 = tmp273 ; break ; } while (0) ; tmp274 = ats_select_mac(tmp268, atslab_0) ; tmp275 = ats_select_mac(tmp268, atslab_1) ; tmp281 = __ats_fun_40_closure_make (tmp267, tmp274) ; tmp282 = d1exp_applstseq_25 (arg0, tmp275, tmp281) ; /* tmp283 = */ atspre_cloptr_free (tmp281) ; tmp284 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("fprint_newline")) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (arg0, tmp266, tmp284) ; tmp288 = (ats_sum_ptr_type)0 ; tmp287 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp287, atslab_0, tmp274) ; ats_selptrset_mac(anairiats_sum_10, tmp287, atslab_1, tmp288) ; tmp286 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (arg0, tmp285, arg0, 0, tmp287) ; tmp291 = (ats_sum_ptr_type)0 ; tmp290 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp290, atslab_0, tmp286) ; ats_selptrset_mac(anairiats_sum_10, tmp290, atslab_1, tmp291) ; tmp289 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ats_selptrset_mac(anairiats_sum_10, tmp289, atslab_0, tmp282) ; ats_selptrset_mac(anairiats_sum_10, tmp289, atslab_1, tmp290) ; tmp264 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (arg0, tmp289) ; return (tmp264) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__d1exp_fprintln_n2] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp79, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp80, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp81, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp82, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp83, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp84, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp85, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp86, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp87, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp88, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp89, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp90, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp91, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp110, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp111, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp112, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp113, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp114, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp115, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp80 = (ats_sum_ptr_type)0 ; statmp79 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp79, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_2, statmp79, atslab_1, statmp80) ; statmp83 = (ats_sum_ptr_type)0 ; statmp82 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp82, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, statmp82, atslab_1, statmp83) ; statmp81 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp81, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_2, statmp81, atslab_1, statmp82) ; statmp87 = (ats_sum_ptr_type)0 ; statmp86 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp86, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_2, statmp86, atslab_1, statmp87) ; statmp85 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp85, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, statmp85, atslab_1, statmp86) ; statmp84 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp84, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_2, statmp84, atslab_1, statmp85) ; statmp89 = (ats_sum_ptr_type)0 ; statmp88 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp88, atslab_0, -2) ; ats_selptrset_mac(anairiats_sum_2, statmp88, atslab_1, statmp89) ; statmp91 = (ats_sum_ptr_type)0 ; statmp90 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, statmp90, atslab_0, 3) ; ats_selptrset_mac(anairiats_sum_2, statmp90, atslab_1, statmp91) ; statmp110 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("print")) ; statmp111 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("println")) ; statmp112 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("prerr")) ; statmp113 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("prerrln")) ; statmp114 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("fprint")) ; statmp115 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("fprintln")) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp1_syndef_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_syntax_posmark_dats.c0000664000175000017500000033073412223166160023213 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_e0xp_loc ; ats_ptr_type atslab_e0xp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_s0exp_loc ; ats_ptr_type atslab_s0exp_node ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_l0ab_loc ; ats_ptr_type atslab_l0ab_lab ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_s0arg_loc ; ats_ptr_type atslab_s0arg_sym ; ats_ptr_type atslab_s0arg_srt ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_s0qua_loc ; ats_ptr_type atslab_s0qua_node ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_e0fftag_loc ; ats_ptr_type atslab_e0fftag_node ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_p0at_loc ; ats_ptr_type atslab_p0at_node ; } anairiats_rec_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_p0arg_loc ; ats_ptr_type atslab_p0arg_sym ; ats_ptr_type atslab_p0arg_ann ; } anairiats_rec_14 ; typedef struct { ats_ptr_type atslab_d0arg_loc ; ats_ptr_type atslab_d0arg_node ; } anairiats_rec_15 ; typedef struct { ats_ptr_type atslab_f0arg_loc ; ats_ptr_type atslab_f0arg_node ; } anairiats_rec_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_i0nvarg_loc ; ats_ptr_type atslab_i0nvarg_sym ; ats_ptr_type atslab_i0nvarg_typ ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_i0nvresstate_qua ; ats_ptr_type atslab_i0nvresstate_arg ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_loopi0nv_qua ; ats_ptr_type atslab_loopi0nv_met ; ats_ptr_type atslab_loopi0nv_arg ; ats_ptr_type atslab_loopi0nv_res ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_d0exp_loc ; ats_ptr_type atslab_d0exp_node ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_m0atch_loc ; ats_ptr_type atslab_m0atch_exp ; ats_ptr_type atslab_m0atch_pat ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_guap0at_loc ; ats_ptr_type atslab_guap0at_pat ; ats_ptr_type atslab_guap0at_gua ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_c0lau_loc ; ats_ptr_type atslab_c0lau_pat ; ats_int_type atslab_c0lau_seq ; ats_int_type atslab_c0lau_neg ; ats_ptr_type atslab_c0lau_body ; } anairiats_rec_24 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_25 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_26 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_27 ; typedef struct { ats_ptr_type atslab_s0expdef_loc ; ats_ptr_type atslab_s0expdef_sym ; ats_ptr_type atslab_s0expdef_loc_id ; ats_ptr_type atslab_s0expdef_arg ; ats_ptr_type atslab_s0expdef_res ; ats_ptr_type atslab_s0expdef_def ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_d0atcon_loc ; ats_ptr_type atslab_d0atcon_sym ; ats_ptr_type atslab_d0atcon_qua ; ats_ptr_type atslab_d0atcon_arg ; ats_ptr_type atslab_d0atcon_ind ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_d0atdec_fil ; ats_ptr_type atslab_d0atdec_loc ; ats_ptr_type atslab_d0atdec_headloc ; ats_ptr_type atslab_d0atdec_sym ; ats_ptr_type atslab_d0atdec_arg ; ats_ptr_type atslab_d0atdec_con ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_e0xndec_fil ; ats_ptr_type atslab_e0xndec_loc ; ats_ptr_type atslab_e0xndec_sym ; ats_ptr_type atslab_e0xndec_qua ; ats_ptr_type atslab_e0xndec_arg ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_d0cstdec_fil ; ats_ptr_type atslab_d0cstdec_loc ; ats_ptr_type atslab_d0cstdec_sym ; ats_ptr_type atslab_d0cstdec_arg ; ats_ptr_type atslab_d0cstdec_eff ; ats_ptr_type atslab_d0cstdec_res ; ats_ptr_type atslab_d0cstdec_extdef ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_v0aldec_loc ; ats_ptr_type atslab_v0aldec_pat ; ats_ptr_type atslab_v0aldec_def ; ats_ptr_type atslab_v0aldec_ann ; } anairiats_rec_33 ; typedef struct { ats_ptr_type atslab_f0undec_loc ; ats_ptr_type atslab_f0undec_sym ; ats_ptr_type atslab_f0undec_sym_loc ; ats_ptr_type atslab_f0undec_arg ; ats_ptr_type atslab_f0undec_eff ; ats_ptr_type atslab_f0undec_res ; ats_ptr_type atslab_f0undec_def ; ats_ptr_type atslab_f0undec_ann ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_v0ardec_loc ; ats_int_type atslab_v0ardec_knd ; ats_ptr_type atslab_v0ardec_sym ; ats_ptr_type atslab_v0ardec_sym_loc ; ats_ptr_type atslab_v0ardec_typ ; ats_ptr_type atslab_v0ardec_wth ; ats_ptr_type atslab_v0ardec_ini ; } anairiats_rec_35 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_36 ; typedef struct { ats_ptr_type atslab_i0mpdec_loc ; ats_ptr_type atslab_i0mpdec_qid ; ats_ptr_type atslab_i0mpdec_arg ; ats_ptr_type atslab_i0mpdec_res ; ats_ptr_type atslab_i0mpdec_def ; } anairiats_rec_37 ; typedef struct { ats_ptr_type atslab_impqi0de_loc ; ats_ptr_type atslab_impqi0de_qua ; ats_ptr_type atslab_impqi0de_sym ; ats_ptr_type atslab_impqi0de_arg ; } anairiats_rec_38 ; typedef struct { ats_ptr_type atslab_d0ec_loc ; ats_ptr_type atslab_d0ec_node ; } anairiats_rec_39 ; typedef struct { ats_ptr_type atslab_guad0ec_loc ; ats_ptr_type atslab_guad0ec_node ; } anairiats_rec_40 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Texist_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfree_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist2_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trec_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tsvararg_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup2_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGdyn_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta1_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGmet_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfixity_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cnonfix_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpundef_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpact_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatsrts_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csrtdefs_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacons_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacsts_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstavars_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cclassdec_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextype_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextcode_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_par_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cmacdefs_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdynload_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eextval_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esexparg_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estruct_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etmpid_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55) ; /* external dynamic constant declarations */ ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_end) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_end) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_end) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_beg) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_end) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_beg) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_end) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0ec_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type externloc_posmark_0 (ats_ptr_type arg0) ; static ats_void_type neuexploc_posmark_1 (ats_ptr_type arg0) ; static ats_void_type staexploc_posmark_2 (ats_ptr_type arg0) ; static ats_void_type prfexploc_posmark_3 (ats_ptr_type arg0) ; static ats_void_type e0xp_posmark_4 (ats_ptr_type arg0) ; static ats_void_type s0exp_posmark_5 (ats_ptr_type arg0) ; static ats_void_type s0explst_posmark_6 (ats_ptr_type arg0) ; static ats_void_type s0expopt_posmark_7 (ats_ptr_type arg0) ; static ats_void_type s0explstlst_posmark_8 (ats_ptr_type arg0) ; static ats_void_type labs0explst_posmark_9 (ats_ptr_type arg0) ; static ats_void_type t1mps0explstlst_posmark_10 (ats_ptr_type arg0) ; static ats_void_type s0arg_posmark_11 (ats_ptr_type arg0) ; static ats_void_type s0arglst_posmark_12 (ats_ptr_type arg0) ; static ats_void_type s0arglstlst_posmark_13 (ats_ptr_type arg0) ; static ats_void_type s0qua_posmark_14 (ats_ptr_type arg0) ; static ats_void_type s0qualst_posmark_15 (ats_ptr_type arg0) ; static ats_void_type s0qualstlst_posmark_16 (ats_ptr_type arg0) ; static ats_void_type e0fftag_posmark_17 (ats_ptr_type arg0) ; static ats_void_type e0fftaglst_posmark_18 (ats_ptr_type arg0) ; static ats_void_type e0fftaglstopt_posmark_19 (ats_ptr_type arg0) ; static ats_void_type p0at_prf_posmark_20 (ats_ptr_type arg0) ; static ats_void_type p0atlst_prf_posmark_21 (ats_ptr_type arg0) ; static ats_void_type p0atopt_posmark_22 (ats_ptr_type arg0) ; static ats_void_type labp0atlst_posmark_23 (ats_ptr_type arg0) ; static ats_void_type p0arg_posmark_26 (ats_ptr_type arg0) ; static ats_void_type p0arglst_posmark_27 (ats_ptr_type arg0) ; static ats_void_type p0arg_prf_posmark_28 (ats_ptr_type arg0) ; static ats_void_type p0arglst_prf_posmark_29 (ats_ptr_type arg0) ; static ats_void_type d0arg_posmark_30 (ats_ptr_type arg0) ; static ats_void_type d0arglst_posmark_31 (ats_ptr_type arg0) ; static ats_void_type f0arg_posmark_32 (ats_ptr_type arg0) ; static ats_void_type f0arglst_posmark_33 (ats_ptr_type arg0) ; static ats_void_type i0nvarglst_posmark_34 (ats_ptr_type arg0) ; static ats_void_type i0nvresstate_posmark_35 (ats_ptr_type arg0) ; static ats_void_type loopi0nv_posmark_36 (ats_ptr_type arg0) ; static ats_void_type loopi0nvopt_posmark_37 (ats_ptr_type arg0) ; static ats_void_type d0exp_prf_posmark_38 (ats_ptr_type arg0) ; static ats_void_type d0explst_prf_posmark_39 (ats_ptr_type arg0) ; static ats_void_type d0explstlst_posmark_40 (ats_ptr_type arg0) ; static ats_void_type d0expopt_posmark_41 (ats_ptr_type arg0) ; static ats_void_type m0atch_posmark_42 (ats_ptr_type arg0) ; static ats_void_type m0atchlst_posmark_43 (ats_ptr_type arg0) ; static ats_void_type guap0at_posmark_44 (ats_ptr_type arg0) ; static ats_void_type c0lau_posmark_45 (ats_ptr_type arg0) ; static ats_void_type c0laulst_posmark_46 (ats_ptr_type arg0) ; static ats_void_type labd0explst_posmark_47 (ats_ptr_type arg0) ; static ats_void_type stacstdecloc_posmark_51 (ats_ptr_type arg0) ; static ats_void_type s0expdef_posmark_52 (ats_ptr_type arg0) ; static ats_void_type s0expdeflst_posmark_53 (ats_ptr_type arg0) ; static ats_void_type d0atcon_posmark_54 (ats_ptr_type arg0) ; static ats_void_type d0atconlst_posmark_55 (ats_ptr_type arg0) ; static ats_void_type d0atdec_posmark_56 (ats_ptr_type arg0) ; static ats_void_type d0atdeclst_posmark_57 (ats_ptr_type arg0) ; static ats_void_type e0xndec_posmark_58 (ats_ptr_type arg0) ; static ats_void_type e0xndeclst_posmark_59 (ats_ptr_type arg0) ; static ats_void_type dyncstdecloc_posmark_60 (ats_ptr_type arg0) ; static ats_void_type d0cstdec_posmark_61 (ats_ptr_type arg0) ; static ats_void_type d0cstdeclst_posmark_62 (ats_ptr_type arg0) ; static ats_void_type v0aldec_posmark_63 (ats_ptr_type arg0) ; static ats_void_type v0aldeclst_posmark_64 (ats_ptr_type arg0) ; static ats_void_type f0undec_posmark_65 (ats_ptr_type arg0) ; static ats_void_type f0undeclst_posmark_66 (ats_ptr_type arg0) ; static ats_void_type v0ardec_posmark_67 (ats_ptr_type arg0) ; static ats_void_type v0ardeclst_posmark_68 (ats_ptr_type arg0) ; static ats_void_type i0mpdec_posmark_69 (ats_ptr_type arg0) ; static ats_void_type guad0ec_node_posmark_70 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 1844(line=60, offs=4) -- 2081(line=67, offs=4) */ ATSstaticdec() ats_void_type externloc_posmark_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_lint_type, tmp1) ; ATSlocal (ats_lint_type, tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_externloc_posmark_0: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; tmp2 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_beg (tmp1) ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_extern_end (tmp2) ; return /* (tmp0) */ ; } /* end of [externloc_posmark_0] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 2116(line=69, offs=4) -- 2353(line=76, offs=4) */ ATSstaticdec() ats_void_type neuexploc_posmark_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_lint_type, tmp5) ; ATSlocal (ats_lint_type, tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_neuexploc_posmark_1: tmp5 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; tmp6 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_beg (tmp5) ; /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_neuexp_end (tmp6) ; return /* (tmp4) */ ; } /* end of [neuexploc_posmark_1] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 2388(line=78, offs=4) -- 2625(line=85, offs=4) */ ATSstaticdec() ats_void_type staexploc_posmark_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp8) ; ATSlocal (ats_lint_type, tmp9) ; ATSlocal (ats_lint_type, tmp10) ; // ATSlocal_void (tmp11) ; __ats_lab_staexploc_posmark_2: tmp9 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp11 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg (tmp9) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end (tmp10) ; return /* (tmp8) */ ; } /* end of [staexploc_posmark_2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 2660(line=87, offs=4) -- 2897(line=94, offs=4) */ ATSstaticdec() ats_void_type prfexploc_posmark_3 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_lint_type, tmp13) ; ATSlocal (ats_lint_type, tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_prfexploc_posmark_3: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_beg (tmp13) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_prfexp_end (tmp14) ; return /* (tmp12) */ ; } /* end of [prfexploc_posmark_3] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 2953(line=98, offs=4) -- 3016(line=99, offs=33) */ ATSstaticdec() ats_void_type e0xp_posmark_4 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_e0xp_posmark_4: tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_e0xp_loc) ; /* tmp16 = */ neuexploc_posmark_1 (tmp17) ; return /* (tmp16) */ ; } /* end of [e0xp_posmark_4] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3021(line=101, offs=4) -- 3091(line=102, offs=36) */ ATSstaticdec() ats_void_type s0exp_posmark_5 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_s0exp_posmark_5: tmp19 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s0exp_loc) ; /* tmp18 = */ staexploc_posmark_2 (tmp19) ; return /* (tmp18) */ ; } /* end of [s0exp_posmark_5] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3097(line=104, offs=5) -- 3184(line=105, offs=46) */ ATSstaticdec() ats_void_type s0explst_posmark_6 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp20) ; __ats_lab_s0explst_posmark_6: /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0exp_posmark_5) ; return /* (tmp20) */ ; } /* end of [s0explst_posmark_6] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3190(line=107, offs=4) -- 3293(line=108, offs=62) */ ATSstaticdec() ats_void_type s0expopt_posmark_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_s0expopt_posmark_7: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp21 = */ s0exp_posmark_5 (tmp22) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp21) */ ; } /* end of [s0expopt_posmark_7] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3327(line=111, offs=4) -- 3427(line=113, offs=50) */ ATSstaticdec() ats_void_type s0explstlst_posmark_8 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp23) ; __ats_lab_s0explstlst_posmark_8: /* tmp23 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0explst_posmark_6) ; return /* (tmp23) */ ; } /* end of [s0explstlst_posmark_8] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3434(line=115, offs=5) -- 3923(line=127, offs=28) */ ATSstaticdec() ats_void_type labs0explst_posmark_9 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_lint_type, tmp30) ; // ATSlocal_void (tmp31) ; ATSlocal (ats_lint_type, tmp32) ; // ATSlocal_void (tmp33) ; __ats_lab_labs0explst_posmark_9: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp25 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp26 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_l0ab_loc) ; tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp26), atslab_s0exp_loc) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (tmp28) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_beg (tmp30) ; tmp32 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (tmp29) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_staexp_end (tmp32) ; arg0 = tmp27 ; goto __ats_lab_labs0explst_posmark_9 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp24) */ ; } /* end of [labs0explst_posmark_9] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 3961(line=130, offs=5) -- 4228(line=136, offs=32) */ ATSstaticdec() ats_void_type t1mps0explstlst_posmark_10 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_t1mps0explstlst_posmark_10: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; /* tmp37 = */ s0explst_posmark_6 (tmp35) ; arg0 = tmp36 ; goto __ats_lab_t1mps0explstlst_posmark_10 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; return /* (tmp34) */ ; } /* end of [t1mps0explstlst_posmark_10] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4289(line=141, offs=4) -- 4359(line=142, offs=36) */ ATSstaticdec() ats_void_type s0arg_posmark_11 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_s0arg_posmark_11: tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_s0arg_loc) ; /* tmp38 = */ staexploc_posmark_2 (tmp39) ; return /* (tmp38) */ ; } /* end of [s0arg_posmark_11] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4364(line=144, offs=4) -- 4451(line=145, offs=46) */ ATSstaticdec() ats_void_type s0arglst_posmark_12 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp40) ; __ats_lab_s0arglst_posmark_12: /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0arg_posmark_11) ; return /* (tmp40) */ ; } /* end of [s0arglst_posmark_12] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4456(line=147, offs=4) -- 4554(line=148, offs=50) */ ATSstaticdec() ats_void_type s0arglstlst_posmark_13 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp41) ; __ats_lab_s0arglstlst_posmark_13: /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0arglst_posmark_12) ; return /* (tmp41) */ ; } /* end of [s0arglstlst_posmark_13] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4580(line=152, offs=4) -- 4650(line=153, offs=36) */ ATSstaticdec() ats_void_type s0qua_posmark_14 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_s0qua_posmark_14: tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_s0qua_loc) ; /* tmp42 = */ staexploc_posmark_2 (tmp43) ; return /* (tmp42) */ ; } /* end of [s0qua_posmark_14] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4655(line=155, offs=4) -- 4741(line=156, offs=45) */ ATSstaticdec() ats_void_type s0qualst_posmark_15 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp44) ; __ats_lab_s0qualst_posmark_15: /* tmp44 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0qua_posmark_14) ; return /* (tmp44) */ ; } /* end of [s0qualst_posmark_15] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4746(line=158, offs=4) -- 4843(line=159, offs=49) */ ATSstaticdec() ats_void_type s0qualstlst_posmark_16 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp45) ; __ats_lab_s0qualstlst_posmark_16: /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0qualst_posmark_15) ; return /* (tmp45) */ ; } /* end of [s0qualstlst_posmark_16] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4869(line=163, offs=4) -- 4945(line=164, offs=38) */ ATSstaticdec() ats_void_type e0fftag_posmark_17 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_e0fftag_posmark_17: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_e0fftag_loc) ; /* tmp46 = */ staexploc_posmark_2 (tmp47) ; return /* (tmp46) */ ; } /* end of [e0fftag_posmark_17] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 4950(line=166, offs=4) -- 5043(line=167, offs=48) */ ATSstaticdec() ats_void_type e0fftaglst_posmark_18 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp48) ; __ats_lab_e0fftaglst_posmark_18: /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &e0fftag_posmark_17) ; return /* (tmp48) */ ; } /* end of [e0fftaglst_posmark_18] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5049(line=169, offs=4) -- 5175(line=171, offs=57) */ ATSstaticdec() ats_void_type e0fftaglstopt_posmark_19 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_e0fftaglstopt_posmark_19: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp49 = */ e0fftaglst_posmark_18 (tmp50) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: break ; } while (0) ; return /* (tmp49) */ ; } /* end of [e0fftaglstopt_posmark_19] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5236(line=176, offs=4) -- 5334(line=178, offs=4) */ ATSstaticdec() ats_void_type p0at_prf_posmark_20 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_p0at_prf_posmark_20: tmp53 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p0at_loc) ; /* tmp52 = */ prfexploc_posmark_3 (tmp53) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (arg0) ; return /* (tmp51) */ ; } /* end of [p0at_prf_posmark_20] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5369(line=180, offs=5) -- 5461(line=181, offs=49) */ ATSstaticdec() ats_void_type p0atlst_prf_posmark_21 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp54) ; __ats_lab_p0atlst_prf_posmark_21: /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &p0at_prf_posmark_20) ; return /* (tmp54) */ ; } /* end of [p0atlst_prf_posmark_21] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5466(line=183, offs=4) -- 5566(line=184, offs=61) */ ATSstaticdec() ats_void_type p0atopt_posmark_22 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_p0atopt_posmark_22: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp55 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp56) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp55) */ ; } /* end of [p0atopt_posmark_22] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5600(line=187, offs=5) -- 5810(line=192, offs=12) */ ATSstaticdec() ats_void_type labp0atlst_posmark_23 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; __ats_lab_labp0atlst_posmark_23: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; /* tmp60 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp58) ; arg0 = tmp59 ; goto __ats_lab_labp0atlst_posmark_23 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: break ; } while (0) ; return /* (tmp57) */ ; } /* end of [labp0atlst_posmark_23] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 5866(line=196, offs=14) -- 6683(line=217, offs=12) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark: tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p0at_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp62)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_0) ; tmp64 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_1) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp63) ; tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp64), atslab_s0exp_loc) ; /* tmp61 = */ staexploc_posmark_2 (tmp66) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp62)->tag != 1) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_0) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_1) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp67) ; arg0 = tmp68 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp62)->tag != 2) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_1) ; arg0 = tmp70 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp62)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_11, tmp62, atslab_0) ; /* tmp61 = */ s0arglst_posmark_12 (tmp71) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp62)->tag != 6) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_11, tmp62, atslab_0) ; arg0 = tmp72 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp62)->tag != 9) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_11, tmp62, atslab_0) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (tmp73) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp62)->tag != 10) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_0) ; tmp75 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_1) ; /* tmp76 = */ p0atlst_prf_posmark_21 (tmp74) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (tmp75) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp62)->tag != 11) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_11, tmp62, atslab_0) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (tmp77) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp62)->tag != 14) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_12, tmp62, atslab_1) ; /* tmp61 = */ labp0atlst_posmark_23 (tmp78) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp62)->tag != 18) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp79 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_p0at_loc) ; /* tmp61 = */ staexploc_posmark_2 (tmp79) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp62)->tag != 19) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_12, tmp62, atslab_1) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (tmp80) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp62)->tag != 20) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_13, tmp62, atslab_1) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_13, tmp62, atslab_2) ; /* tmp83 = */ p0atlst_prf_posmark_21 (tmp81) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (tmp82) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: break ; } while (0) ; return /* (tmp61) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 6736(line=220, offs=27) -- 6789(line=221, offs=45) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark: /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark) ; return /* (tmp84) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0atlst_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 6815(line=225, offs=4) -- 6884(line=226, offs=35) */ ATSstaticdec() ats_void_type p0arg_posmark_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_p0arg_posmark_26: tmp86 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_p0arg_ann) ; /* tmp85 = */ s0expopt_posmark_7 (tmp86) ; return /* (tmp85) */ ; } /* end of [p0arg_posmark_26] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 6889(line=228, offs=4) -- 6970(line=229, offs=46) */ ATSstaticdec() ats_void_type p0arglst_posmark_27 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp87) ; __ats_lab_p0arglst_posmark_27: /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &p0arg_posmark_26) ; return /* (tmp87) */ ; } /* end of [p0arglst_posmark_27] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 6976(line=232, offs=4) -- 7094(line=234, offs=4) */ ATSstaticdec() ats_void_type p0arg_prf_posmark_28 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; __ats_lab_p0arg_prf_posmark_28: tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_p0arg_loc) ; /* tmp89 = */ prfexploc_posmark_3 (tmp90) ; tmp91 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_p0arg_ann) ; /* tmp88 = */ s0expopt_posmark_7 (tmp91) ; return /* (tmp88) */ ; } /* end of [p0arg_prf_posmark_28] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 7129(line=236, offs=4) -- 7218(line=237, offs=50) */ ATSstaticdec() ats_void_type p0arglst_prf_posmark_29 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp92) ; __ats_lab_p0arglst_prf_posmark_29: /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &p0arg_prf_posmark_28) ; return /* (tmp92) */ ; } /* end of [p0arglst_prf_posmark_29] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 7244(line=241, offs=4) -- 7502(line=247, offs=8) */ ATSstaticdec() ats_void_type d0arg_posmark_30 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; // ATSlocal_void (tmp99) ; __ats_lab_d0arg_posmark_30: tmp94 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_d0arg_node) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp94)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_d0arg_loc) ; /* tmp93 = */ staexploc_posmark_2 (tmp95) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp94)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_11, tmp94, atslab_0) ; /* tmp93 = */ p0arglst_posmark_27 (tmp96) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (((ats_sum_ptr_type)tmp94)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_10, tmp94, atslab_0) ; tmp98 = ats_caselptrlab_mac(anairiats_sum_10, tmp94, atslab_1) ; /* tmp99 = */ p0arglst_prf_posmark_29 (tmp97) ; /* tmp93 = */ p0arglst_posmark_27 (tmp98) ; break ; } while (0) ; return /* (tmp93) */ ; } /* end of [d0arg_posmark_30] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 7555(line=250, offs=4) -- 7636(line=251, offs=46) */ ATSstaticdec() ats_void_type d0arglst_posmark_31 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp100) ; __ats_lab_d0arglst_posmark_31: /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0arg_posmark_30) ; return /* (tmp100) */ ; } /* end of [d0arglst_posmark_31] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 7662(line=255, offs=4) -- 7917(line=260, offs=52) */ ATSstaticdec() ats_void_type f0arg_posmark_32 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; __ats_lab_f0arg_posmark_32: tmp102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_f0arg_node) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp102)->tag != 1) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_f0arg_loc) ; /* tmp101 = */ staexploc_posmark_2 (tmp103) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp102)->tag != 2) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp104 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_f0arg_loc) ; /* tmp101 = */ staexploc_posmark_2 (tmp104) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp102)->tag != 0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp105 = ats_caselptrlab_mac(anairiats_sum_11, tmp102, atslab_0) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp105) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (((ats_sum_ptr_type)tmp102)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_f0arg_loc) ; /* tmp101 = */ staexploc_posmark_2 (tmp106) ; break ; } while (0) ; return /* (tmp101) */ ; } /* end of [f0arg_posmark_32] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 7948(line=263, offs=4) -- 8035(line=264, offs=46) */ ATSstaticdec() ats_void_type f0arglst_posmark_33 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp107) ; __ats_lab_f0arglst_posmark_33: /* tmp107 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &f0arg_posmark_32) ; return /* (tmp107) */ ; } /* end of [f0arglst_posmark_33] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 8062(line=268, offs=5) -- 8252(line=273, offs=17) */ ATSstaticdec() ats_void_type i0nvarglst_posmark_34 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; // ATSlocal_void (tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_i0nvarglst_posmark_34: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; tmp112 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp109), atslab_i0nvarg_typ) ; /* tmp111 = */ s0expopt_posmark_7 (tmp112) ; arg0 = tmp110 ; goto __ats_lab_i0nvarglst_posmark_34 ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: break ; } while (0) ; return /* (tmp108) */ ; } /* end of [i0nvarglst_posmark_34] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 8288(line=276, offs=4) -- 8509(line=283, offs=4) */ ATSstaticdec() ats_void_type i0nvresstate_posmark_35 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_i0nvresstate_posmark_35: tmp115 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_i0nvresstate_qua) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp115 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_2, tmp115, atslab_0) ; /* tmp114 = */ s0qualst_posmark_15 (tmp116) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (tmp115 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: break ; } while (0) ; tmp117 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_i0nvresstate_arg) ; /* tmp113 = */ i0nvarglst_posmark_34 (tmp117) ; return /* (tmp113) */ ; } /* end of [i0nvresstate_posmark_35] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 8547(line=285, offs=4) -- 8929(line=296, offs=4) */ ATSstaticdec() ats_void_type loopi0nv_posmark_36 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; // ATSlocal_void (tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_loopi0nv_posmark_36: tmp120 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_loopi0nv_qua) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp120 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_2, tmp120, atslab_0) ; /* tmp119 = */ s0qualst_posmark_15 (tmp121) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp120 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_loopi0nv_met) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp123 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp124 = ats_caselptrlab_mac(anairiats_sum_2, tmp123, atslab_0) ; /* tmp122 = */ s0explst_posmark_6 (tmp124) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (tmp123 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: break ; } while (0) ; tmp126 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_loopi0nv_arg) ; /* tmp125 = */ i0nvarglst_posmark_34 (tmp126) ; tmp127 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_loopi0nv_res) ; /* tmp118 = */ i0nvresstate_posmark_35 (tmp127) ; return /* (tmp118) */ ; } /* end of [loopi0nv_posmark_36] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 8963(line=298, offs=4) -- 9075(line=299, offs=65) */ ATSstaticdec() ats_void_type loopi0nvopt_posmark_37 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_loopi0nvopt_posmark_37: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp129 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp128 = */ loopi0nv_posmark_36 (tmp129) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: break ; } while (0) ; return /* (tmp128) */ ; } /* end of [loopi0nvopt_posmark_37] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9133(line=304, offs=4) -- 9235(line=306, offs=4) */ ATSstaticdec() ats_void_type d0exp_prf_posmark_38 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp130) ; // ATSlocal_void (tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_d0exp_prf_posmark_38: tmp132 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0exp_loc) ; /* tmp131 = */ prfexploc_posmark_3 (tmp132) ; /* tmp130 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (arg0) ; return /* (tmp130) */ ; } /* end of [d0exp_prf_posmark_38] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9270(line=308, offs=4) -- 9365(line=309, offs=50) */ ATSstaticdec() ats_void_type d0explst_prf_posmark_39 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp133) ; __ats_lab_d0explst_prf_posmark_39: /* tmp133 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0exp_prf_posmark_38) ; return /* (tmp133) */ ; } /* end of [d0explst_prf_posmark_39] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9370(line=311, offs=4) -- 9472(line=312, offs=54) */ ATSstaticdec() ats_void_type d0explstlst_posmark_40 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp134) ; __ats_lab_d0explstlst_posmark_40: /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0explst_prf_posmark_39) ; return /* (tmp134) */ ; } /* end of [d0explstlst_posmark_40] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9477(line=314, offs=4) -- 9580(line=315, offs=62) */ ATSstaticdec() ats_void_type d0expopt_posmark_41 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_d0expopt_posmark_41: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp135 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp136) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: break ; } while (0) ; return /* (tmp135) */ ; } /* end of [d0expopt_posmark_41] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9585(line=317, offs=4) -- 9701(line=319, offs=4) */ ATSstaticdec() ats_void_type m0atch_posmark_42 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp137) ; // ATSlocal_void (tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; __ats_lab_m0atch_posmark_42: tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m0atch_exp) ; /* tmp138 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp139) ; tmp140 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m0atch_pat) ; /* tmp137 = */ p0atopt_posmark_22 (tmp140) ; return /* (tmp137) */ ; } /* end of [m0atch_posmark_42] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9733(line=321, offs=4) -- 9825(line=322, offs=48) */ ATSstaticdec() ats_void_type m0atchlst_posmark_43 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp141) ; __ats_lab_m0atchlst_posmark_43: /* tmp141 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &m0atch_posmark_42) ; return /* (tmp141) */ ; } /* end of [m0atchlst_posmark_43] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9830(line=324, offs=4) -- 9947(line=326, offs=4) */ ATSstaticdec() ats_void_type guap0at_posmark_44 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp142) ; // ATSlocal_void (tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_guap0at_posmark_44: tmp144 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_guap0at_pat) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp144) ; tmp145 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_guap0at_gua) ; /* tmp142 = */ m0atchlst_posmark_43 (tmp145) ; return /* (tmp142) */ ; } /* end of [guap0at_posmark_44] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 9980(line=328, offs=4) -- 10086(line=330, offs=4) */ ATSstaticdec() ats_void_type c0lau_posmark_45 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp146) ; // ATSlocal_void (tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_c0lau_posmark_45: tmp148 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_c0lau_pat) ; /* tmp147 = */ guap0at_posmark_44 (tmp148) ; tmp149 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_c0lau_body) ; /* tmp146 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp149) ; return /* (tmp146) */ ; } /* end of [c0lau_posmark_45] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 10118(line=332, offs=4) -- 10205(line=333, offs=46) */ ATSstaticdec() ats_void_type c0laulst_posmark_46 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp150) ; __ats_lab_c0laulst_posmark_46: /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &c0lau_posmark_45) ; return /* (tmp150) */ ; } /* end of [c0laulst_posmark_46] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 10211(line=335, offs=5) -- 10415(line=340, offs=28) */ ATSstaticdec() ats_void_type labd0explst_posmark_47 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; // ATSlocal_void (tmp154) ; __ats_lab_labd0explst_posmark_47: do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp152 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp153 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp152) ; arg0 = tmp153 ; goto __ats_lab_labd0explst_posmark_47 ; // tail call break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: break ; } while (0) ; return /* (tmp151) */ ; } /* end of [labd0explst_posmark_47] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 10473(line=343, offs=25) -- 13714(line=429, offs=12) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; // ATSlocal_void (tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; // ATSlocal_void (tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; // ATSlocal_void (tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; // ATSlocal_void (tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; // ATSlocal_void (tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark: tmp156 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0exp_node) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp156)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp157) ; /* tmp155 = */ s0exp_posmark_5 (tmp158) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp156)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp160) ; arg0 = tmp161 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp156)->tag != 2) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_1) ; tmp165 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_2) ; /* tmp166 = */ s0exp_posmark_5 (tmp163) ; /* tmp167 = */ d0expopt_posmark_41 (tmp164) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp165) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp156)->tag != 4) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_2) ; /* tmp155 = */ d0explstlst_posmark_40 (tmp168) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp156)->tag != 5) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_1) ; tmp170 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_2) ; /* tmp171 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp169) ; /* tmp155 = */ c0laulst_posmark_46 (tmp170) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp156)->tag != 14) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_0) ; tmp173 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_2) ; /* tmp174 = */ staexploc_posmark_2 (tmp172) ; arg0 = tmp173 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp156)->tag != 15) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; /* tmp155 = */ s0exp_posmark_5 (tmp175) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp156)->tag != 16) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_2) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_3) ; tmp178 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_4) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_5) ; /* tmp180 = */ f0arglst_posmark_33 (tmp176) ; /* tmp181 = */ s0expopt_posmark_7 (tmp177) ; /* tmp182 = */ e0fftaglstopt_posmark_19 (tmp178) ; arg0 = tmp179 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp156)->tag != 20) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp183 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_0) ; tmp184 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_2) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_3) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_4) ; tmp187 = ats_caselptrlab_mac(anairiats_sum_25, tmp156, atslab_5) ; /* tmp188 = */ loopi0nvopt_posmark_37 (tmp183) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp184) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp185) ; /* tmp191 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp186) ; arg0 = tmp187 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp156)->tag != 24) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp192 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_1) ; tmp193 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_2) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_3) ; /* tmp195 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp192) ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp193) ; /* tmp155 = */ d0expopt_posmark_41 (tmp194) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp156)->tag != 27) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_27, tmp156, atslab_1) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_27, tmp156, atslab_2) ; tmp199 = ats_caselptrlab_mac(anairiats_sum_27, tmp156, atslab_3) ; tmp200 = ats_caselptrlab_mac(anairiats_sum_27, tmp156, atslab_4) ; /* tmp201 = */ f0arglst_posmark_33 (tmp197) ; /* tmp202 = */ s0expopt_posmark_7 (tmp198) ; /* tmp203 = */ e0fftaglstopt_posmark_19 (tmp199) ; arg0 = tmp200 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp156)->tag != 28) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp204 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; tmp205 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp204) ; arg0 = tmp205 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp156)->tag != 29) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp207 = ats_caselptrlab_mac(anairiats_sum_11, tmp156, atslab_0) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp207) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp156)->tag != 30) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp210 = */ d0explst_prf_posmark_39 (tmp208) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp209) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp156)->tag != 32) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_13, tmp156, atslab_1) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_13, tmp156, atslab_2) ; /* tmp213 = */ s0expopt_posmark_7 (tmp211) ; arg0 = tmp212 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp156)->tag != 33) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; arg0 = tmp214 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp156)->tag != 37) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_11, tmp156, atslab_0) ; arg0 = tmp215 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp156)->tag != 38) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp216 = ats_caselptrlab_mac(anairiats_sum_12, tmp156, atslab_1) ; /* tmp155 = */ labd0explst_posmark_47 (tmp216) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp156)->tag != 41) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp217 = ats_caselptrlab_mac(anairiats_sum_12, tmp156, atslab_1) ; /* tmp155 = */ d0explstlst_posmark_40 (tmp217) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp156)->tag != 42) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_11, tmp156, atslab_0) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp218) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp156)->tag != 43) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp219 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0exp_loc) ; /* tmp155 = */ staexploc_posmark_2 (tmp219) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp156)->tag != 45) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_1) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_2) ; tmp222 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_3) ; /* tmp223 = */ s0exp_posmark_5 (tmp220) ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp221) ; arg0 = tmp222 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp156)->tag != 47) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp225 = ats_caselptrlab_mac(anairiats_sum_11, tmp156, atslab_0) ; /* tmp155 = */ labd0explst_posmark_47 (tmp225) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp156)->tag != 48) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp155 = */ t1mps0explstlst_posmark_10 (tmp226) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp156)->tag != 50) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_1) ; tmp228 = ats_caselptrlab_mac(anairiats_sum_9, tmp156, atslab_2) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp227) ; /* tmp155 = */ c0laulst_posmark_46 (tmp228) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp156)->tag != 51) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp230 = ats_caselptrlab_mac(anairiats_sum_12, tmp156, atslab_1) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp230) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp156)->tag != 52) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp231 = ats_caselptrlab_mac(anairiats_sum_13, tmp156, atslab_1) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_13, tmp156, atslab_2) ; /* tmp233 = */ d0explst_prf_posmark_39 (tmp231) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp232) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp156)->tag != 54) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp234 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_0) ; tmp235 = ats_caselptrlab_mac(anairiats_sum_10, tmp156, atslab_1) ; /* tmp236 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp235) ; arg0 = tmp234 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp156)->tag != 55) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp237 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_0) ; tmp238 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_2) ; tmp239 = ats_caselptrlab_mac(anairiats_sum_26, tmp156, atslab_3) ; /* tmp240 = */ loopi0nvopt_posmark_37 (tmp237) ; /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp238) ; arg0 = tmp239 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: break ; } while (0) ; return /* (tmp155) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 13769(line=432, offs=28) -- 13823(line=433, offs=46) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp242) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark: /* tmp242 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark) ; return /* (tmp242) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 13855(line=435, offs=31) -- 13942(line=437, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explstopt_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explstopt_posmark: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp244 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explst_posmark (tmp244) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: break ; } while (0) ; return /* (tmp243) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0explstopt_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14000(line=441, offs=4) -- 14300(line=448, offs=4) */ ATSstaticdec() ats_void_type stacstdecloc_posmark_51 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp245) ; ATSlocal (ats_lint_type, tmp246) ; // ATSlocal_void (tmp247) ; ATSlocal (ats_lint_type, tmp248) ; __ats_lab_stacstdecloc_posmark_51: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; /* tmp247 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_beg (tmp246, arg0) ; tmp248 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp245 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstdec_end (tmp248, arg0) ; return /* (tmp245) */ ; } /* end of [stacstdecloc_posmark_51] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14359(line=452, offs=4) -- 14502(line=456, offs=4) */ ATSstaticdec() ats_void_type s0expdef_posmark_52 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; __ats_lab_s0expdef_posmark_52: tmp250 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_s0expdef_loc) ; /* tmp251 = */ stacstdecloc_posmark_51 (tmp250) ; /* tmp249 = */ staexploc_posmark_2 (tmp250) ; return /* (tmp249) */ ; } /* end of [s0expdef_posmark_52] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14536(line=458, offs=4) -- 14632(line=459, offs=49) */ ATSstaticdec() ats_void_type s0expdeflst_posmark_53 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp252) ; __ats_lab_s0expdeflst_posmark_53: /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &s0expdef_posmark_52) ; return /* (tmp252) */ ; } /* end of [s0expdeflst_posmark_53] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14658(line=463, offs=4) -- 14817(line=467, offs=4) */ ATSstaticdec() ats_void_type d0atcon_posmark_54 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; // ATSlocal_void (tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; __ats_lab_d0atcon_posmark_54: tmp255 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d0atcon_qua) ; /* tmp254 = */ s0qualstlst_posmark_16 (tmp255) ; tmp257 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d0atcon_arg) ; /* tmp256 = */ s0expopt_posmark_7 (tmp257) ; tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d0atcon_ind) ; /* tmp253 = */ s0expopt_posmark_7 (tmp258) ; return /* (tmp253) */ ; } /* end of [d0atcon_posmark_54] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14850(line=469, offs=4) -- 14943(line=470, offs=48) */ ATSstaticdec() ats_void_type d0atconlst_posmark_55 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp259) ; __ats_lab_d0atconlst_posmark_55: /* tmp259 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0atcon_posmark_54) ; return /* (tmp259) */ ; } /* end of [d0atconlst_posmark_55] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 14948(line=472, offs=4) -- 15175(line=480, offs=4) */ ATSstaticdec() ats_void_type d0atdec_posmark_56 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; // ATSlocal_void (tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; __ats_lab_d0atdec_posmark_56: tmp261 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_d0atdec_headloc) ; /* tmp262 = */ stacstdecloc_posmark_51 (tmp261) ; /* tmp263 = */ staexploc_posmark_2 (tmp261) ; tmp264 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_d0atdec_con) ; /* tmp260 = */ d0atconlst_posmark_55 (tmp264) ; return /* (tmp260) */ ; } /* end of [d0atdec_posmark_56] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 15208(line=482, offs=4) -- 15301(line=483, offs=48) */ ATSstaticdec() ats_void_type d0atdeclst_posmark_57 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp265) ; __ats_lab_d0atdeclst_posmark_57: /* tmp265 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0atdec_posmark_56) ; return /* (tmp265) */ ; } /* end of [d0atdeclst_posmark_57] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 15327(line=487, offs=4) -- 15454(line=490, offs=4) */ ATSstaticdec() ats_void_type e0xndec_posmark_58 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; __ats_lab_e0xndec_posmark_58: tmp268 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_e0xndec_qua) ; /* tmp267 = */ s0qualstlst_posmark_16 (tmp268) ; tmp269 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_e0xndec_arg) ; /* tmp266 = */ s0expopt_posmark_7 (tmp269) ; return /* (tmp266) */ ; } /* end of [e0xndec_posmark_58] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 15487(line=492, offs=4) -- 15580(line=493, offs=48) */ ATSstaticdec() ats_void_type e0xndeclst_posmark_59 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp270) ; __ats_lab_e0xndeclst_posmark_59: /* tmp270 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &e0xndec_posmark_58) ; return /* (tmp270) */ ; } /* end of [e0xndeclst_posmark_59] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 15606(line=497, offs=4) -- 15906(line=504, offs=4) */ ATSstaticdec() ats_void_type dyncstdecloc_posmark_60 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp271) ; ATSlocal (ats_lint_type, tmp272) ; // ATSlocal_void (tmp273) ; ATSlocal (ats_lint_type, tmp274) ; __ats_lab_dyncstdecloc_posmark_60: tmp272 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_beg (tmp272, arg0) ; tmp274 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstdec_end (tmp274, arg0) ; return /* (tmp271) */ ; } /* end of [dyncstdecloc_posmark_60] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 15944(line=506, offs=4) -- 16216(line=514, offs=4) */ ATSstaticdec() ats_void_type d0cstdec_posmark_61 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; __ats_lab_d0cstdec_posmark_61: tmp276 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_d0cstdec_loc) ; /* tmp277 = */ dyncstdecloc_posmark_60 (tmp276) ; tmp279 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_d0cstdec_arg) ; /* tmp278 = */ d0arglst_posmark_31 (tmp279) ; tmp281 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_d0cstdec_eff) ; /* tmp280 = */ e0fftaglstopt_posmark_19 (tmp281) ; tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_d0cstdec_res) ; /* tmp275 = */ s0exp_posmark_5 (tmp282) ; return /* (tmp275) */ ; } /* end of [d0cstdec_posmark_61] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16250(line=516, offs=4) -- 16346(line=517, offs=49) */ ATSstaticdec() ats_void_type d0cstdeclst_posmark_62 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp283) ; __ats_lab_d0cstdeclst_posmark_62: /* tmp283 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &d0cstdec_posmark_61) ; return /* (tmp283) */ ; } /* end of [d0cstdeclst_posmark_62] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16372(line=521, offs=4) -- 16483(line=523, offs=4) */ ATSstaticdec() ats_void_type v0aldec_posmark_63 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_v0aldec_posmark_63: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, arg0), atslab_v0aldec_pat) ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__p0at_posmark (tmp286) ; tmp287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, arg0), atslab_v0aldec_def) ; /* tmp284 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp287) ; return /* (tmp284) */ ; } /* end of [v0aldec_posmark_63] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16516(line=525, offs=4) -- 16609(line=526, offs=48) */ ATSstaticdec() ats_void_type v0aldeclst_posmark_64 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp288) ; __ats_lab_v0aldeclst_posmark_64: /* tmp288 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &v0aldec_posmark_63) ; return /* (tmp288) */ ; } /* end of [v0aldeclst_posmark_64] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16635(line=530, offs=4) -- 16829(line=535, offs=4) */ ATSstaticdec() ats_void_type f0undec_posmark_65 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp289) ; // ATSlocal_void (tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; // ATSlocal_void (tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; // ATSlocal_void (tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; __ats_lab_f0undec_posmark_65: tmp291 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg0), atslab_f0undec_arg) ; /* tmp290 = */ f0arglst_posmark_33 (tmp291) ; tmp293 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg0), atslab_f0undec_eff) ; /* tmp292 = */ e0fftaglstopt_posmark_19 (tmp293) ; tmp295 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg0), atslab_f0undec_res) ; /* tmp294 = */ s0expopt_posmark_7 (tmp295) ; tmp296 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg0), atslab_f0undec_def) ; /* tmp289 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp296) ; return /* (tmp289) */ ; } /* end of [f0undec_posmark_65] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16862(line=537, offs=4) -- 16955(line=538, offs=48) */ ATSstaticdec() ats_void_type f0undeclst_posmark_66 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp297) ; __ats_lab_f0undeclst_posmark_66: /* tmp297 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &f0undec_posmark_65) ; return /* (tmp297) */ ; } /* end of [f0undeclst_posmark_66] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 16981(line=542, offs=4) -- 17254(line=552, offs=4) */ ATSstaticdec() ats_void_type v0ardec_posmark_67 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; __ats_lab_v0ardec_posmark_67: tmp300 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_v0ardec_typ) ; /* tmp299 = */ s0expopt_posmark_7 (tmp300) ; tmp302 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_v0ardec_wth) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (tmp302 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp303 = ats_caselptrlab_mac(anairiats_sum_2, tmp302, atslab_0) ; tmp304 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp303), atslab_i0de_loc) ; /* tmp301 = */ prfexploc_posmark_3 (tmp304) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (tmp302 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: break ; } while (0) ; tmp305 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_v0ardec_ini) ; /* tmp298 = */ d0expopt_posmark_41 (tmp305) ; return /* (tmp298) */ ; } /* end of [v0ardec_posmark_67] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 17287(line=554, offs=4) -- 17380(line=555, offs=48) */ ATSstaticdec() ats_void_type v0ardeclst_posmark_68 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp306) ; __ats_lab_v0ardeclst_posmark_68: /* tmp306 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &v0ardec_posmark_67) ; return /* (tmp306) */ ; } /* end of [v0ardeclst_posmark_68] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 17406(line=559, offs=4) -- 17685(line=568, offs=4) */ ATSstaticdec() ats_void_type i0mpdec_posmark_69 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; // ATSlocal_void (tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; __ats_lab_i0mpdec_posmark_69: tmp308 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_i0mpdec_qid) ; tmp310 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, tmp308), atslab_impqi0de_arg) ; /* tmp309 = */ t1mps0explstlst_posmark_10 (tmp310) ; tmp312 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_i0mpdec_arg) ; /* tmp311 = */ f0arglst_posmark_33 (tmp312) ; tmp314 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_i0mpdec_res) ; /* tmp313 = */ s0expopt_posmark_7 (tmp314) ; tmp315 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_i0mpdec_def) ; /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp315) ; return /* (tmp307) */ ; } /* end of [i0mpdec_posmark_69] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 17740(line=572, offs=5) -- 18222(line=585, offs=4) */ ATSstaticdec() ats_void_type guad0ec_node_posmark_70 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; // ATSlocal_void (tmp323) ; // ATSlocal_void (tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; __ats_lab_guad0ec_node_posmark_70: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp317 = ats_caselptrlab_mac(anairiats_sum_10, arg0, atslab_0) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_10, arg0, atslab_1) ; /* tmp319 = */ e0xp_posmark_4 (tmp317) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp318) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp320 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp321 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp322 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; /* tmp323 = */ e0xp_posmark_4 (tmp320) ; /* tmp324 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp321) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp322) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_26, arg0, atslab_0) ; tmp326 = ats_caselptrlab_mac(anairiats_sum_26, arg0, atslab_1) ; tmp327 = ats_caselptrlab_mac(anairiats_sum_26, arg0, atslab_3) ; /* tmp328 = */ e0xp_posmark_4 (tmp325) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp326) ; arg0 = tmp327 ; goto __ats_lab_guad0ec_node_posmark_70 ; // tail call break ; } while (0) ; return /* (tmp316) */ ; } /* end of [guad0ec_node_posmark_70] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 18301(line=589, offs=24) -- 21606(line=668, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0ec_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; // ATSlocal_void (tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; // ATSlocal_void (tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_bool_type, tmp353) ; // ATSlocal_void (tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; // ATSlocal_void (tmp356) ; // ATSlocal_void (tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_bool_type, tmp362) ; // ATSlocal_void (tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; // ATSlocal_void (tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; // ATSlocal_void (tmp378) ; ATSlocal (ats_bool_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; // ATSlocal_void (tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; // ATSlocal_void (tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_bool_type, tmp392) ; // ATSlocal_void (tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; // ATSlocal_void (tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; // ATSlocal_void (tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; // ATSlocal_void (tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0ec_posmark: tmp331 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_node) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp331)->tag != 0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp332 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp332) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp331)->tag != 1) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp333 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp333) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp331)->tag != 2) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp334 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp334) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp331)->tag != 3) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp335 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp335) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp331)->tag != 5) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp336 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp336) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp331)->tag != 4) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp337 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp337) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp331)->tag != 6) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp338 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp338) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp331)->tag != 7) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp339 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp339) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp331)->tag != 8) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp340 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp340) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp331)->tag != 9) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp341 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp342 = */ stacstdecloc_posmark_51 (tmp341) ; /* tmp330 = */ staexploc_posmark_2 (tmp341) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp331)->tag != 10) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp343 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp343) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp331)->tag != 11) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp344 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp344) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp331)->tag != 12) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp345 = ats_caselptrlab_mac(anairiats_sum_9, tmp331, atslab_1) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_9, tmp331, atslab_2) ; /* tmp347 = */ s0expdef_posmark_52 (tmp345) ; /* tmp330 = */ s0expdeflst_posmark_53 (tmp346) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp331)->tag != 13) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp348) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp331)->tag != 14) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_0) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_1) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_2) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_3) ; tmp353 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (tmp349) ; if (tmp353) { tmp355 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp354 = */ prfexploc_posmark_3 (tmp355) ; } else { /* empty */ } /* end of [if] */ /* tmp356 = */ s0qualstlst_posmark_16 (tmp350) ; /* tmp357 = */ d0cstdec_posmark_61 (tmp351) ; /* tmp330 = */ d0cstdeclst_posmark_62 (tmp352) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp331)->tag != 15) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_0) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_1) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_2) ; tmp361 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_3) ; tmp362 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof (tmp358) ; if (tmp362) { tmp364 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp363 = */ prfexploc_posmark_3 (tmp364) ; } else { /* empty */ } /* end of [if] */ /* tmp365 = */ d0atdec_posmark_56 (tmp359) ; /* tmp366 = */ d0atdeclst_posmark_57 (tmp360) ; /* tmp330 = */ s0expdeflst_posmark_53 (tmp361) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp331)->tag != 16) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp367 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp368 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp369 = */ e0xndec_posmark_58 (tmp367) ; /* tmp330 = */ e0xndeclst_posmark_59 (tmp368) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp331)->tag != 17) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp370 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp370) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp331)->tag != 18) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp371 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp371) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp331)->tag != 19) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp372 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp372) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp331)->tag != 20) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp330 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0exp_posmark (tmp373) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp331)->tag != 21) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp374 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ externloc_posmark_0 (tmp374) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp331)->tag != 22) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp375 = ats_caselptrlab_mac(anairiats_sum_9, tmp331, atslab_0) ; tmp376 = ats_caselptrlab_mac(anairiats_sum_9, tmp331, atslab_1) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_9, tmp331, atslab_2) ; tmp379 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof (tmp375) ; if (tmp379) { tmp380 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp378 = */ prfexploc_posmark_3 (tmp380) ; } else { /* empty */ } /* end of [if] */ /* tmp381 = */ v0aldec_posmark_63 (tmp376) ; /* tmp330 = */ v0aldeclst_posmark_64 (tmp377) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)tmp331)->tag != 23) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp382 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp383 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp384 = */ v0aldec_posmark_63 (tmp382) ; /* tmp330 = */ v0aldeclst_posmark_64 (tmp383) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)tmp331)->tag != 24) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp385 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp387 = */ v0aldec_posmark_63 (tmp385) ; /* tmp330 = */ v0aldeclst_posmark_64 (tmp386) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)tmp331)->tag != 25) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp388 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_0) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_1) ; tmp390 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_2) ; tmp391 = ats_caselptrlab_mac(anairiats_sum_26, tmp331, atslab_3) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof (tmp388) ; if (tmp392) { tmp394 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp393 = */ prfexploc_posmark_3 (tmp394) ; } else { /* empty */ } /* end of [if] */ /* tmp395 = */ s0qualstlst_posmark_16 (tmp389) ; /* tmp396 = */ f0undec_posmark_65 (tmp390) ; /* tmp330 = */ f0undeclst_posmark_66 (tmp391) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp331)->tag != 26) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp397 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp398 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp399 = */ v0ardec_posmark_67 (tmp397) ; /* tmp330 = */ v0ardeclst_posmark_68 (tmp398) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp331)->tag != 27) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp400 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ neuexploc_posmark_1 (tmp400) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp331)->tag != 28) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp401 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp402 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp403 = */ s0arglstlst_posmark_13 (tmp401) ; /* tmp330 = */ i0mpdec_posmark_69 (tmp402) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp331)->tag != 29) { goto __ats_lab_113_0 ; } __ats_lab_112_1: break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp331)->tag != 30) { goto __ats_lab_114_0 ; } __ats_lab_113_1: tmp404 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_d0ec_loc) ; /* tmp330 = */ staexploc_posmark_2 (tmp404) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)tmp331)->tag != 31) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp405) ; /* tmp330 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp406) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (((ats_sum_ptr_type)tmp331)->tag != 32) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_10, tmp331, atslab_1) ; tmp409 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp408), atslab_guad0ec_node) ; /* tmp330 = */ guad0ec_node_posmark_70 (tmp409) ; break ; } while (0) ; return /* (tmp330) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0ec_posmark] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_posmark.dats: 21681(line=671, offs=27) -- 21734(line=672, offs=45) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp410) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark: /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0ec_posmark) ; return /* (tmp410) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_syntax_posmark_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_stamp_dats.c0000664000175000017500000004204412223166160021247 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_int_type, atsopt_compare_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_count) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, atsopt_tostring_count) (atsopt_count_type) ; ATSextern_fun(ats_ptr_type, atsopt_counter_make) () ; ATSextern_fun(atsopt_count_type, atsopt_counter_getinc) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__sasp__stamp_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp15) ; ATSstatic (ats_ptr_type, statmp17) ; ATSstatic (ats_ptr_type, statmp19) ; ATSstatic (ats_ptr_type, statmp21) ; ATSstatic (ats_ptr_type, statmp23) ; ATSstatic (ats_ptr_type, statmp25) ; ATSstatic (ats_ptr_type, statmp27) ; ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp31) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp35) ; ATSstatic (ats_ptr_type, statmp37) ; ATSstatic (ats_ptr_type, statmp39) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 1801(line=56, offs=16) -- 1840(line=56, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lt_stamp_stamp (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lt_stamp_stamp: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count (arg0, arg1) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lt_stamp_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 1867(line=58, offs=17) -- 1907(line=58, offs=57) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lte_stamp_stamp (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lte_stamp_stamp: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count (arg0, arg1) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__lte_stamp_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 1934(line=61, offs=16) -- 1973(line=61, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp: tmp2 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count (arg0, arg1) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2000(line=63, offs=17) -- 2040(line=63, offs=57) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__neq_stamp_stamp (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__neq_stamp_stamp: tmp3 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count (arg0, arg1) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__neq_stamp_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2072(line=66, offs=21) -- 2116(line=66, offs=65) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp: tmp4 = atsopt_compare_count_count (arg0, arg1) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2162(line=70, offs=24) -- 2209(line=70, offs=71) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (ats_ref_type arg0, atsopt_count_type arg1) { /* local vardec */ // ATSlocal_void (tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp: /* tmp5 = */ atsopt_fprint_count (arg0, arg1) ; return /* (tmp5) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2232(line=71, offs=23) -- 2265(line=71, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__print_stamp (atsopt_count_type arg0) { /* local vardec */ // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__print_stamp: tmp7 = atspre_stdout_get () ; tmp8 = ats_selsin_mac(tmp7, atslab_1) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (tmp8, arg0) ; /* tmp6 = */ atspre_stdout_view_set () ; return /* (tmp6) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__print_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2288(line=72, offs=23) -- 2321(line=72, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__prerr_stamp (atsopt_count_type arg0) { /* local vardec */ // ATSlocal_void (tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; // ATSlocal_void (tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__prerr_stamp: tmp11 = atspre_stderr_get () ; tmp12 = ats_selsin_mac(tmp11, atslab_1) ; /* tmp13 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (tmp12, arg0) ; /* tmp10 = */ atspre_stderr_view_set () ; return /* (tmp10) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__prerr_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2369(line=76, offs=26) -- 2397(line=76, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp (atsopt_count_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp: tmp14 = atsopt_tostring_count (arg0) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2494(line=81, offs=30) -- 2526(line=81, offs=62) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2rtdat_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2rtdat_stamp_make: tmp16 = atsopt_counter_getinc (statmp15) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2rtdat_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2621(line=85, offs=28) -- 2653(line=85, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2cst_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2cst_stamp_make: tmp18 = atsopt_counter_getinc (statmp17) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2cst_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2748(line=89, offs=28) -- 2780(line=89, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2var_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2var_stamp_make: tmp20 = atsopt_counter_getinc (statmp19) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2var_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 2875(line=93, offs=28) -- 2907(line=93, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make: tmp22 = atsopt_counter_getinc (statmp21) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3009(line=97, offs=35) -- 3041(line=97, offs=67) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_struct_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_struct_stamp_make: tmp24 = atsopt_counter_getinc (statmp23) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_struct_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3142(line=101, offs=34) -- 3174(line=101, offs=66) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_union_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_union_stamp_make: tmp26 = atsopt_counter_getinc (statmp25) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_union_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3269(line=105, offs=28) -- 3301(line=105, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2con_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2con_stamp_make: tmp28 = atsopt_counter_getinc (statmp27) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2con_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3396(line=109, offs=28) -- 3428(line=109, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2cst_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2cst_stamp_make: tmp30 = atsopt_counter_getinc (statmp29) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2cst_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3523(line=113, offs=28) -- 3555(line=113, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2mac_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2mac_stamp_make: tmp32 = atsopt_counter_getinc (statmp31) ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2mac_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3650(line=117, offs=28) -- 3682(line=117, offs=60) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2var_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2var_stamp_make: tmp34 = atsopt_counter_getinc (statmp33) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2var_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3799(line=123, offs=29) -- 3831(line=123, offs=61) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make: tmp36 = atsopt_counter_getinc (statmp35) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 3927(line=127, offs=29) -- 3959(line=127, offs=61) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmplab_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmplab_stamp_make: tmp38 = atsopt_counter_getinc (statmp37) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmplab_stamp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stamp.dats: 4055(line=131, offs=29) -- 4087(line=131, offs=61) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmpvar_stamp_make () { /* local vardec */ ATSlocal (atsopt_count_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmpvar_stamp_make: tmp40 = atsopt_counter_getinc (statmp39) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmpvar_stamp_make] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp15, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp17, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp19, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp21, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp23, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp25, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp31, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp35, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp37, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp39, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp15 = atsopt_counter_make () ; statmp17 = atsopt_counter_make () ; statmp19 = atsopt_counter_make () ; statmp21 = atsopt_counter_make () ; statmp23 = atsopt_counter_make () ; statmp25 = atsopt_counter_make () ; statmp27 = atsopt_counter_make () ; statmp29 = atsopt_counter_make () ; statmp31 = atsopt_counter_make () ; statmp33 = atsopt_counter_make () ; statmp35 = atsopt_counter_make () ; statmp37 = atsopt_counter_make () ; statmp39 = atsopt_counter_make () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_stamp_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_met_dats.c0000664000175000017500000006046412223166160023060 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { atsopt_count_type atslab_0 ; } anairiats_sum_7 ; typedef struct { anairiats_rec_2 atslab_0 ; } anairiats_sum_8 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_nat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__metric_env_token = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_1 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) ; static ats_bool_type aux1_4 (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type aux2_5 (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type aux_10 (ats_ptr_type arg0) ; static ats_ptr_type aux_9 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_clo_ptr_type aux_9_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp8) ; ATSstatic (ats_ptr_type, statmp11) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 2097(line=69, offs=7) -- 2430(line=80, offs=24) */ ATSstaticdec() ats_void_type aux_1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; // ATSlocal_void (tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_aux_1: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp6 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp2), atslab_s2exp_srt) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp6, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; if (tmp5) { tmp7 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_nat (arg0, tmp2) ; /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr (tmp7) ; } else { /* empty */ } /* end of [if] */ arg0 = arg0 ; arg1 = tmp3 ; goto __ats_lab_aux_1 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp1) */ ; } /* end of [aux_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 2068(line=68, offs=3) -- 2499(line=84, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check: /* tmp0 = */ aux_1 (arg0, arg1) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_ref_make_elt_03657_ats_ptr_type: /* ats_ptr_type tmp10 ; */ tmp10 = arg0 ; tmp9 = atspre_ref_make_elt_tsz ((&tmp10), sizeof(ats_ptr_type)) ; return (tmp9) ; } /* end of [ref_make_elt_03657_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 2817(line=102, offs=7) -- 3066(line=108, offs=27) */ ATSstaticdec() ats_bool_type aux1_4 (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; ATSlocal (atsopt_count_type, tmp17) ; __ats_lab_aux1_4: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp15 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp17 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (tmp14) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp17, arg1) ; if (tmp16) { tmp13 = ats_true_bool ; } else { arg0 = tmp15 ; arg1 = arg1 ; goto __ats_lab_aux1_4 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp13 = ats_false_bool ; break ; } while (0) ; return (tmp13) ; } /* end of [aux1_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 3095(line=111, offs=7) -- 3480(line=121, offs=44) */ ATSstaticdec() ats_ptr_type aux2_5 (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (anairiats_rec_2, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_bool_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_aux2_5: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp20 = &ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp22 = ats_select_mac(tmp19, atslab_0) ; tmp21 = aux1_4 (tmp22, arg1) ; if (tmp21) { tmp23 = ats_select_mac(tmp19, atslab_1) ; tmp18 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp18, atslab_0, tmp23) ; } else { tmp24 = ats_ptrget_mac(ats_ptr_type, tmp20) ; arg0 = tmp24 ; arg1 = arg1 ; goto __ats_lab_aux2_5 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp18 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp18) ; } /* end of [aux2_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 2790(line=100, offs=16) -- 3606(line=128, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_get (atsopt_count_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_get: tmp25 = atspre_ref_get_view_ptr (statmp8) ; tmp26 = ats_selsin_mac(tmp25, atslab_1) ; tmp27 = ats_ptrget_mac(ats_ptr_type, tmp26) ; tmp12 = aux2_5 (tmp27, arg0) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 3681(line=133, offs=16) -- 4184(line=148, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_pop () { /* local vardec */ // ATSlocal_void (tmp28) ; ATSlocal (ats_int_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_bool_type, tmp35) ; // ATSlocal_void (tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_pop: /* ats_int_type tmp29 ; */ tmp29 = 0 ; tmp30 = atspre_ref_get_view_ptr (statmp8) ; tmp31 = ats_selsin_mac(tmp30, atslab_1) ; tmp33 = ats_ptrget_mac(ats_ptr_type, tmp31) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp33 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_3, tmp33, atslab_1) ; ATS_FREE(tmp33) ; ats_ptrget_mac(ats_ptr_type, tmp31) = tmp34 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp33 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp29 = 1 ; break ; } while (0) ; tmp35 = atspre_gt_int_int (tmp29, 0) ; if (tmp35) { /* tmp36 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env_met)")) ; /* tmp37 = */ atspre_prerr_string (ATSstrcst(": metric_env_pop: the_metbindlst is empty.")) ; /* tmp38 = */ atspre_prerr_newline () ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp28) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 4239(line=151, offs=17) -- 4391(line=154, offs=6) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_push (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (anairiats_rec_2, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_push: tmp40 = atspre_ref_get_view_ptr (statmp8) ; tmp41 = ats_selsin_mac(tmp40, atslab_1) ; tmp43.atslab_0 = arg0 ; tmp43.atslab_1 = arg1 ; tmp44 = ats_ptrget_mac(ats_ptr_type, tmp41) ; tmp42 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp42, atslab_0, tmp43) ; ats_selptrset_mac(anairiats_sum_3, tmp42, atslab_1, tmp44) ; ats_ptrget_mac(ats_ptr_type, tmp41) = tmp42 ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 5023(line=178, offs=15) -- 5184(line=180, offs=41) */ ATSstaticdec() ats_ptr_type aux_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; __ats_lab_aux_10: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp61 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp63 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp61), atslab_s2exp_srt) ; tmp64 = aux_10 (tmp62) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp60, atslab_0, tmp63) ; ats_selptrset_mac(anairiats_sum_0, tmp60, atslab_1, tmp64) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp60 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp60) ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 4538(line=165, offs=7) -- 5541(line=190, offs=6) */ ATSstaticdec() ats_ptr_type aux_9 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_int_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (atsopt_count_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_aux_9: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp47)->tag != 11) { goto __ats_lab_11_0 ; } __ats_lab_8_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_0) ; tmp49 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_1) ; tmp50 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_2) ; tmp51 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_3) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_4) ; tmp53 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_5) ; tmp54 = aux_9 (env0, tmp53, arg1) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (tmp54 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_4, tmp54, atslab_0) ; ATS_FREE(tmp54) ; tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_srt) ; tmp56 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp57, tmp48, tmp49, tmp50, tmp51, tmp52, tmp55) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp46, atslab_0, tmp56) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (tmp54 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp46 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp47)->tag != 15) { goto __ats_lab_14_0 ; } __ats_lab_11_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_6, tmp47, atslab_1) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_6, tmp47, atslab_2) ; tmp65 = aux_10 (tmp58) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp65 ; tmp68 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (env0) ; tmp67 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp67, atslab_0, tmp68) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn (tmp67, tmp58, tmp59) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp46, atslab_0, tmp66) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp47)->tag != 30) { goto __ats_lab_17_0 ; } __ats_lab_14_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_6, tmp47, atslab_0) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_6, tmp47, atslab_1) ; tmp71 = ats_caselptrlab_mac(anairiats_sum_6, tmp47, atslab_2) ; tmp72 = aux_9 (env0, tmp71, arg1) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp72 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_4, tmp72, atslab_0) ; ATS_FREE(tmp72) ; tmp74 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp69, tmp70, tmp73) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp46, atslab_0, tmp74) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (tmp72 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp46 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp46 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp46) ; } /* end of [aux_9] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_9_closure_type ; ats_ptr_type aux_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) { return aux_9 (((aux_9_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_9_closure_init (aux_9_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_9_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_9_closure_make (ats_ptr_type env0) { aux_9_closure_type *p_clo = ATS_MALLOC(sizeof(aux_9_closure_type)) ; aux_9_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_met.dats: 4510(line=163, offs=3) -- 5701(line=197, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metfn_load (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (anairiats_rec_2, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metfn_load: /* ats_ptr_type tmp75 ; */ tmp75 = (ats_sum_ptr_type)0 ; tmp76 = aux_9 (arg1, arg0, (&tmp75)) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp76 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_4, tmp76, atslab_0) ; ATS_FREE(tmp76) ; tmp78.atslab_0 = tmp77 ; tmp78.atslab_1 = tmp75 ; tmp45 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp45, atslab_0, tmp78) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (tmp76 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp45 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp45) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metfn_load] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp8, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp11, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp11 = (ats_sum_ptr_type)0 ; statmp8 = ref_make_elt_03657_ats_ptr_type (statmp11) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_met_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_global_dats.c0000664000175000017500000001546312223166160021370 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_global_initialize) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01686_ats_ptr_type (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp3) ; // ATSstatic_void (statmp8) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01686_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ref_make_elt_01686_ats_ptr_type: /* ats_ptr_type tmp2 ; */ tmp2 = arg0 ; tmp1 = atspre_ref_make_elt_tsz ((&tmp2), sizeof(ats_ptr_type)) ; return (tmp1) ; } /* end of [ref_make_elt_01686_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_global.dats: 1899(line=61, offs=20) -- 1919(line=61, offs=40) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_get: tmp4 = ats_ptrget_mac(ats_ptr_type, statmp0) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_global.dats: 1951(line=64, offs=21) -- 2012(line=65, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_push: tmp7 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp6 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp6, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp6, atslab_1, tmp7) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp6 ; return /* (tmp5) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_push] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_global_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_global_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_global_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_global_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)0 ; statmp0 = ref_make_elt_01686_ats_ptr_type (statmp3) ; /* statmp8 = */ atsopt_global_initialize () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ static ats_int_type the_dynloadflag = 0 ; ats_int_type atsopt_dynloadflag_get () { return the_dynloadflag ; } // end of [atsopt_dynloadflag_get] ats_void_type atsopt_dynloadflag_set (ats_int_type flag) { the_dynloadflag = flag ; return ; } // end of [atsopt_dynloadflag_set] /* ****** ****** */ static ats_ptr_type the_dynloadfun_name = (ats_ptr_type)0 ; ats_ptr_type atsopt_dynloadfun_name_get () { return the_dynloadfun_name ; } // end of ... ats_void_type atsopt_dynloadfun_name_set (ats_ptr_type name) { the_dynloadfun_name = name ; return ; } // end of [atsopt_dynloadfun_name_set] static ats_ptr_type the_atsopt_namespace = (ats_ptr_type)0 ; ats_ptr_type atsopt_namespace_get () { return the_atsopt_namespace ; } // end of [atsopt_namespace_get] ats_void_type atsopt_namespace_set (ats_ptr_type prfx) { the_atsopt_namespace = prfx ; return ; } // end of [atsopt_namespace_set] ats_void_type atsopt_global_initialize () { ATS_GC_MARKROOT (&the_dynloadfun_name, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&the_atsopt_namespace, sizeof(ats_ptr_type)) ; return ; } // end of [atsopt_global_initialize] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_global_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_effect_sats.c0000664000175000017500000000351212223166160021373 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTset_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTset_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_effect_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_keyword_sats.c0000664000175000017500000000220512223166160021621 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_keyword_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_keyword_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_comarg_sats.c0000664000175000017500000000221612223166160021407 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__COMARGkey_0) ; /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload_flag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__COMARGkey_0.tag = 0 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_comarg_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans4_sats.c0000664000175000017500000000422712223166160021356 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans4_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_string_parse_sats.c0000664000175000017500000000734712223166160022651 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_char_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_long_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_long_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_short_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_ptr_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_string_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_long_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_short_14) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_char_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_long_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_long_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_short_7.tag = 7 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_ptr_8.tag = 8 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_string_9.tag = 9 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_10.tag = 10 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_11.tag = 11 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_long_12.tag = 12 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_13.tag = 13 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_short_14.tag = 14 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_string_parse_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libats_lex_lexing_dats.c0000664000175000017500000013223212223166160022747 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "libc/CATS/stdio.cats" // for some IO functions static inline ats_int_type ats_int_of_lint (ats_lint_type i) { return i ; } /* type definitions */ typedef struct { ats_int_type atslab_line ; ats_int_type atslab_loff ; ats_lint_type atslab_toff ; } anairiats_rec_0 ; typedef struct { ats_clo_ref_type atslab_free ; ats_clo_ref_type atslab_getc ; } anairiats_rec_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_int_type, atspre_int_of_char) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_lint_type, atspre_add_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_lt_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_lte_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_eq_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_neq_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__accept_table_get) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__transition_table_get) (ats_ptr_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, lexbuf_fstpos_set) (ats_ref_type) ; ATSextern_fun(ats_void_type, lexbuf_lstpos_set) (ats_ref_type) ; ATSextern_fun(ats_void_type, lexbuf_curpos_set) (ats_ref_type) ; ATSextern_fun(ats_int_type, lexbuf_char_next) (ats_ref_type) ; ATSextern_fun(ats_bool_type, lexbuf_is_eof) (ats_ref_type) ; ATSextern_fun(ats_int_type, lexing_engine_lexbuf) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, lexing_lexbuf_get) () ; ATSextern_fun(ats_void_type, lexing_lexbuf_set) (ats_ptr_type) ; ATSextern_fun(ats_char_type, lexeme_get_lexbuf) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, lexeme_set_lexbuf) (ats_ref_type, ats_int_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, lexeme_string_lexbuf) (ats_ref_type) ; ATSextern_fun(ats_lint_type, lexeme_lint_lexbuf) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_lint_type, lexeme_lint) (ats_int_type) ; ATSextern_fun(ats_ptr_type, position_make_int_int_lint) (ats_int_type, ats_int_type, ats_lint_type) ; ATSextern_fun(ats_void_type, atslib_fclose_exn) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atslib_getchar) () ; ATSextern_fun(ats_int_type, ats_int_of_lint) (ats_lint_type) ; ATSextern_fun(ats_void_type, lexing_lexbuf_markroot) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__sasp__infile_t = 0 ; int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__sasp__position_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type _free_14 (ats_ptr_type env0) ; static ats_clo_ptr_type _free_14_closure_make (ats_ptr_type env0) ; static ats_void_type _free_14_clofun (ats_clo_ptr_type cloptr) ; static ats_int_type _getc_15 (ats_ptr_type env0, ats_size_type env1, ats_ptr_type env2) ; static ats_clo_ptr_type _getc_15_closure_make (ats_ptr_type env0, ats_size_type env1, ats_ptr_type env2) ; static ats_int_type _getc_15_clofun (ats_clo_ptr_type cloptr) ; static ats_void_type _free_17 (ats_ptr_type env0) ; static ats_clo_ptr_type _free_17_closure_make (ats_ptr_type env0) ; static ats_void_type _free_17_clofun (ats_clo_ptr_type cloptr) ; static ats_int_type _getc_18 (ats_ptr_type env0) ; static ats_clo_ptr_type _getc_18_closure_make (ats_ptr_type env0) ; static ats_int_type _getc_18_clofun (ats_clo_ptr_type cloptr) ; static ats_void_type _free_20 () ; static ats_clo_ptr_type _free_20_closure_make () ; static ats_void_type _free_20_clofun (ats_clo_ptr_type cloptr) ; static ats_int_type _getc_21 () ; static ats_clo_ptr_type _getc_21_closure_make () ; static ats_int_type _getc_21_clofun (ats_clo_ptr_type cloptr) ; static ats_int_type aux_23 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) ; static ats_clo_ptr_type aux_23_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_int_type aux_23_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ // ATSstatic_void (statmp98) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1747(line=49, offs=25) -- 1759(line=49, offs=37) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line: tmp0 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_line) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1784(line=50, offs=25) -- 1796(line=50, offs=37) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_loff) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1821(line=51, offs=25) -- 1833(line=51, offs=37) */ ATSglobaldec() ats_lint_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_lint_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff: tmp2 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_toff) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1866(line=53, offs=32) -- 1894(line=53, offs=60) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lt_position_position (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp3) ; ATSlocal (ats_lint_type, tmp4) ; ATSlocal (ats_lint_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lt_position_position: tmp4 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_toff) ; tmp5 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_toff) ; tmp3 = atspre_lt_lint_lint (tmp4, tmp5) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lt_position_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1927(line=54, offs=33) -- 1956(line=54, offs=62) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lte_position_position (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_lint_type, tmp7) ; ATSlocal (ats_lint_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lte_position_position: tmp7 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_toff) ; tmp8 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_toff) ; tmp6 = atspre_lte_lint_lint (tmp7, tmp8) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lte_position_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 1988(line=55, offs=32) -- 2016(line=55, offs=60) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__eq_position_position (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp9) ; ATSlocal (ats_lint_type, tmp10) ; ATSlocal (ats_lint_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__eq_position_position: tmp10 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_toff) ; tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_toff) ; tmp9 = atspre_eq_lint_lint (tmp10, tmp11) ; return (tmp9) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__eq_position_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2049(line=56, offs=33) -- 2078(line=56, offs=62) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__neq_position_position (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_lint_type, tmp13) ; ATSlocal (ats_lint_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__neq_position_position: tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_toff) ; tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_toff) ; tmp12 = atspre_neq_lint_lint (tmp13, tmp14) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__neq_position_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2238(line=62, offs=38) -- 2300(line=63, offs=42) */ ATSglobaldec() ats_ptr_type position_make_int_int_lint (ats_int_type arg0, ats_int_type arg1, ats_lint_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_position_make_int_int_lint: tmp15 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_line, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_loff, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_toff, arg2) ; return (tmp15) ; } /* end of [position_make_int_int_lint] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2328(line=65, offs=27) -- 2436(line=66, offs=78) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_lint_type, tmp17) ; ATSlocal (ats_lint_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; ATSlocal (ats_int_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position: tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_toff) ; tmp17 = atspre_add_lint_lint (tmp18, 1L) ; tmp20 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_line) ; tmp19 = atspre_add_int_int (tmp20, 1) ; tmp22 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_loff) ; tmp21 = atspre_add_int_int (tmp22, 1) ; /* tmp16 = */ atspre_fprintf_exn (arg0, ATSstrcst("%li(line=%i, offs=%i)"), tmp17, tmp19, tmp21) ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2463(line=68, offs=26) -- 2503(line=68, offs=66) */ ATSglobaldec() ats_void_type lexing_print_position (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; // ATSlocal_void (tmp26) ; __ats_lab_lexing_print_position: tmp24 = atspre_stdout_get () ; tmp25 = ats_selsin_mac(tmp24, atslab_1) ; /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position (tmp25, arg0) ; /* tmp23 = */ atspre_stdout_view_set () ; return /* (tmp23) */ ; } /* end of [lexing_print_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2529(line=69, offs=26) -- 2569(line=69, offs=66) */ ATSglobaldec() ats_void_type lexing_prerr_position (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; // ATSlocal_void (tmp30) ; __ats_lab_lexing_prerr_position: tmp28 = atspre_stderr_get () ; tmp29 = ats_selsin_mac(tmp28, atslab_1) ; /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__fprint_position (tmp29, arg0) ; /* tmp27 = */ atspre_stderr_view_set () ; return /* (tmp27) */ ; } /* end of [lexing_prerr_position] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2772(line=81, offs=23) -- 2813(line=81, offs=64) */ ATSglobaldec() ats_void_type lexing_infile_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_clo_ref_type, tmp32) ; __ats_lab_lexing_infile_free: tmp32 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_free) ; /* tmp31 = */ ((ats_void_type(*)(ats_clo_ptr_type))(ats_closure_fun(tmp32))) (tmp32) ; return /* (tmp31) */ ; } /* end of [lexing_infile_free] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2836(line=82, offs=23) -- 2877(line=82, offs=64) */ ATSglobaldec() ats_int_type lexing_infile_getc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp33) ; ATSlocal (ats_clo_ref_type, tmp34) ; __ats_lab_lexing_infile_getc: tmp34 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_getc) ; tmp33 = ((ats_int_type(*)(ats_clo_ptr_type))(ats_closure_fun(tmp34))) (tmp34) ; return (tmp33) ; } /* end of [lexing_infile_getc] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 3129(line=94, offs=6) -- 3218(line=96, offs=6) */ ATSstaticdec() ats_void_type _free_14 (ats_ptr_type env0) { /* local vardec */ // ATSlocal_void (tmp39) ; __ats_lab__free_14: /* tmp39 = */ atspre_ptr_free (env0) ; return /* (tmp39) */ ; } /* end of [_free_14] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } _free_14_closure_type ; ats_void_type _free_14_clofun (ats_clo_ptr_type cloptr) { _free_14 (((_free_14_closure_type*)cloptr)->closure_env_0) ; return ; } /* end of function */ ATSinline() ats_void_type _free_14_closure_init (_free_14_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&_free_14_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type _free_14_closure_make (ats_ptr_type env0) { _free_14_closure_type *p_clo = ATS_MALLOC(sizeof(_free_14_closure_type)) ; _free_14_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 3242(line=97, offs=6) -- 3472(line=104, offs=6) */ ATSstaticdec() ats_int_type _getc_15 (ats_ptr_type env0, ats_size_type env1, ats_ptr_type env2) { /* local vardec */ ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_size_type, tmp41) ; ATSlocal (ats_int_type, tmp42) ; ATSlocal (ats_bool_type, tmp43) ; ATSlocal (ats_size_type, tmp44) ; ATSlocal (ats_char_type, tmp45) ; __ats_lab__getc_15: tmp41 = ats_ptrget_mac(ats_size_type, env2) ; tmp43 = atspre_lt_size1_size1 (tmp41, env1) ; if (tmp43) { tmp44 = atspre_add_size1_int1 (tmp41, 1) ; ats_ptrget_mac(ats_size_type, env2) = tmp44 ; tmp45 = atspre_string_get_char_at (env0, tmp41) ; tmp42 = atspre_int_of_char (tmp45) ; } else { tmp42 = -1 ; } /* end of [if] */ tmp40 = tmp42 ; return (tmp40) ; } /* end of [_getc_15] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_size_type closure_env_1 ; ats_ptr_type closure_env_2 ; } _getc_15_closure_type ; ats_int_type _getc_15_clofun (ats_clo_ptr_type cloptr) { return _getc_15 (((_getc_15_closure_type*)cloptr)->closure_env_0, ((_getc_15_closure_type*)cloptr)->closure_env_1, ((_getc_15_closure_type*)cloptr)->closure_env_2) ; } /* end of function */ ATSinline() ats_void_type _getc_15_closure_init (_getc_15_closure_type *p_clo, ats_ptr_type env0, ats_size_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&_getc_15_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type _getc_15_closure_make (ats_ptr_type env0, ats_size_type env1, ats_ptr_type env2) { _getc_15_closure_type *p_clo = ATS_MALLOC(sizeof(_getc_15_closure_type)) ; _getc_15_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 2912(line=87, offs=20) -- 3595(line=108, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_size_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_size_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_string: tmp36 = atspre_string_length (ats_castfn_mac(ats_ptr_type, arg0)) ; tmp37 = atspre_ptr_alloc_tsz (sizeof(ats_size_type)) ; tmp38 = ats_selsin_mac(tmp37, atslab_2) ; tmp46 = atspre_size1_of_int1 (0) ; ats_ptrget_mac(ats_size_type, tmp38) = tmp46 ; tmp35 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp35, atslab_free, _free_14_closure_make (tmp38)) ; ats_selptrset_mac(anairiats_rec_1, tmp35, atslab_getc, _getc_15_closure_make (ats_castfn_mac(ats_ptr_type, arg0), tmp36, tmp38)) ; return (tmp35) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_string] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4041(line=128, offs=6) -- 4112(line=128, offs=77) */ ATSstaticdec() ats_void_type _free_17 (ats_ptr_type env0) { /* local vardec */ // ATSlocal_void (tmp48) ; __ats_lab__free_17: /* tmp48 = */ atslib_fclose_exn (env0) ; return /* (tmp48) */ ; } /* end of [_free_17] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } _free_17_closure_type ; ats_void_type _free_17_clofun (ats_clo_ptr_type cloptr) { _free_17 (((_free_17_closure_type*)cloptr)->closure_env_0) ; return ; } /* end of function */ ATSinline() ats_void_type _free_17_closure_init (_free_17_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&_free_17_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type _free_17_closure_make (ats_ptr_type env0) { _free_17_closure_type *p_clo = ATS_MALLOC(sizeof(_free_17_closure_type)) ; _free_17_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4118(line=129, offs=6) -- 4189(line=129, offs=77) */ ATSstaticdec() ats_int_type _getc_18 (ats_ptr_type env0) { /* local vardec */ ATSlocal (ats_int_type, tmp49) ; __ats_lab__getc_18: tmp49 = atslib_fgetc_err (env0) ; return (tmp49) ; } /* end of [_getc_18] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } _getc_18_closure_type ; ats_int_type _getc_18_clofun (ats_clo_ptr_type cloptr) { return _getc_18 (((_getc_18_closure_type*)cloptr)->closure_env_0) ; } /* end of function */ ATSinline() ats_void_type _getc_18_closure_init (_getc_18_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&_getc_18_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type _getc_18_closure_make (ats_ptr_type env0) { _getc_18_closure_type *p_clo = ATS_MALLOC(sizeof(_getc_18_closure_type)) ; _getc_18_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 3982(line=126, offs=11) -- 4248(line=132, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_file (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_file: tmp47 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp47, atslab_free, _free_17_closure_make (arg0)) ; ats_selptrset_mac(anairiats_rec_1, tmp47, atslab_getc, _getc_18_closure_make (arg0)) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_file] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4342(line=137, offs=6) -- 4432(line=139, offs=6) */ ATSstaticdec() ats_void_type _free_20 () { /* local vardec */ // ATSlocal_void (tmp51) ; __ats_lab__free_20: return /* (tmp51) */ ; } /* end of [_free_20] */ typedef struct { ats_fun_ptr_type closure_fun ; } _free_20_closure_type ; ats_void_type _free_20_clofun (ats_clo_ptr_type cloptr) { _free_20 () ; return ; } /* end of function */ ATSinline() ats_void_type _free_20_closure_init (_free_20_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&_free_20_clofun ; return ; } /* end of function */ ats_clo_ptr_type _free_20_closure_make () { _free_20_closure_type *p_clo = ATS_MALLOC(sizeof(_free_20_closure_type)) ; _free_20_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4438(line=140, offs=6) -- 4490(line=140, offs=58) */ ATSstaticdec() ats_int_type _getc_21 () { /* local vardec */ ATSlocal (ats_int_type, tmp52) ; __ats_lab__getc_21: tmp52 = atslib_getchar () ; return (tmp52) ; } /* end of [_getc_21] */ typedef struct { ats_fun_ptr_type closure_fun ; } _getc_21_closure_type ; ats_int_type _getc_21_clofun (ats_clo_ptr_type cloptr) { return _getc_21 () ; } /* end of function */ ATSinline() ats_void_type _getc_21_closure_init (_getc_21_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&_getc_21_clofun ; return ; } /* end of function */ ats_clo_ptr_type _getc_21_closure_make () { _getc_21_closure_type *p_clo = ATS_MALLOC(sizeof(_getc_21_closure_type)) ; _getc_21_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4307(line=135, offs=19) -- 4553(line=143, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_stdin () { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_stdin: tmp50 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp50, atslab_free, _free_20_closure_make ()) ; ats_selptrset_mac(anairiats_rec_1, tmp50, atslab_getc, _getc_21_closure_make ()) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_stdin] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4696(line=151, offs=5) -- 5540(line=177, offs=6) */ ATSstaticdec() ats_int_type aux_23 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_int_type, tmp56) ; ATSlocal (ats_bool_type, tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_int_type, tmp60) ; ATSlocal (ats_int_type, tmp61) ; // ATSlocal_void (tmp62) ; __ats_lab_aux_23: tmp55 = atspre_gt_int_int (arg2, 0) ; if (tmp55) { tmp56 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__accept_table_get (env1, arg2) ; tmp58 = atspre_gt_int_int (tmp56, 0) ; if (tmp58) { /* tmp59 = */ lexbuf_lstpos_set (arg0) ; ats_ptrget_mac(ats_int_type, arg1) = tmp56 ; } else { /* empty */ } /* end of [if] */ tmp60 = lexbuf_char_next (arg0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__transition_table_get (env0, arg2, tmp60) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp61 ; goto __ats_lab_aux_23 ; // tail call } else { /* tmp62 = */ lexbuf_curpos_set (arg0) ; tmp54 = ats_ptrget_mac(ats_int_type, arg1) ; } /* end of [if] */ return (tmp54) ; } /* end of [aux_23] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_23_closure_type ; ats_int_type aux_23_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ref_type arg1, ats_int_type arg2) { return aux_23 (((aux_23_closure_type*)cloptr)->closure_env_0, ((aux_23_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux_23_closure_init (aux_23_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_23_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_23_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_23_closure_type *p_clo = ATS_MALLOC(sizeof(aux_23_closure_type)) ; aux_23_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 4660(line=149, offs=32) -- 5635(line=183, offs=4) */ ATSglobaldec() ats_int_type lexing_engine_lexbuf (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp53) ; ATSlocal (ats_int_type, tmp63) ; // ATSlocal_void (tmp64) ; __ats_lab_lexing_engine_lexbuf: /* ats_int_type tmp63 ; */ tmp63 = 0 ; /* tmp64 = */ lexbuf_fstpos_set (arg0) ; tmp53 = aux_23 (arg1, arg2, arg0, (&tmp63), 1) ; return (tmp53) ; } /* end of [lexing_engine_lexbuf] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 5694(line=185, offs=25) -- 5886(line=190, offs=4) */ ATSglobaldec() ats_int_type lexing_engine (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_int_type, tmp68) ; // ATSlocal_void (tmp69) ; __ats_lab_lexing_engine: tmp66 = lexing_lexbuf_get () ; tmp67 = ats_selsin_mac(tmp66, atslab_1) ; tmp68 = lexing_engine_lexbuf (tmp67, arg0, arg1) ; /* tmp69 = */ lexing_lexbuf_set (tmp67) ; tmp65 = tmp68 ; return (tmp65) ; } /* end of [lexing_engine] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 5956(line=194, offs=22) -- 6107(line=199, offs=4) */ ATSglobaldec() ats_char_type lexeme_get (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_char_type, tmp73) ; // ATSlocal_void (tmp74) ; __ats_lab_lexeme_get: tmp71 = lexing_lexbuf_get () ; tmp72 = ats_selsin_mac(tmp71, atslab_1) ; tmp73 = lexeme_get_lexbuf (tmp72, arg0) ; /* tmp74 = */ lexing_lexbuf_set (tmp72) ; tmp70 = tmp73 ; return (tmp70) ; } /* end of [lexeme_get] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 6153(line=201, offs=22) -- 6308(line=206, offs=4) */ ATSglobaldec() ats_void_type lexeme_set (ats_int_type arg0, ats_char_type arg1) { /* local vardec */ // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; // ATSlocal_void (tmp78) ; __ats_lab_lexeme_set: tmp76 = lexing_lexbuf_get () ; tmp77 = ats_selsin_mac(tmp76, atslab_1) ; /* tmp78 = */ lexeme_set_lexbuf (tmp77, arg0, arg1) ; /* tmp75 = */ lexing_lexbuf_set (tmp77) ; return /* (tmp75) */ ; } /* end of [lexeme_set] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 6357(line=208, offs=25) -- 6507(line=213, offs=4) */ ATSglobaldec() ats_ptr_type lexeme_string () { /* local vardec */ ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_lexeme_string: tmp80 = lexing_lexbuf_get () ; tmp81 = ats_selsin_mac(tmp80, atslab_1) ; tmp82 = lexeme_string_lexbuf (tmp81) ; /* tmp83 = */ lexing_lexbuf_set (tmp81) ; tmp79 = tmp82 ; return (tmp79) ; } /* end of [lexeme_string] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 6557(line=215, offs=23) -- 6717(line=220, offs=4) */ ATSglobaldec() ats_lint_type lexeme_lint (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_lint_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_lint_type, tmp87) ; // ATSlocal_void (tmp88) ; __ats_lab_lexeme_lint: tmp85 = lexing_lexbuf_get () ; tmp86 = ats_selsin_mac(tmp85, atslab_1) ; tmp87 = lexeme_lint_lexbuf (tmp86, arg0) ; /* tmp88 = */ lexing_lexbuf_set (tmp86) ; tmp84 = tmp87 ; return (tmp84) ; } /* end of [lexeme_lint] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 6852(line=230, offs=22) -- 6964(line=234, offs=4) */ ATSglobaldec() ats_int_type lexeme_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp89) ; ATSlocal (ats_lint_type, tmp90) ; __ats_lab_lexeme_int: tmp90 = lexeme_lint (arg0) ; tmp89 = ats_int_of_lint (tmp90) ; return (tmp89) ; } /* end of [lexeme_int] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 7017(line=238, offs=25) -- 7160(line=243, offs=4) */ ATSglobaldec() ats_bool_type lexing_is_eof () { /* local vardec */ ATSlocal (ats_bool_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_bool_type, tmp94) ; // ATSlocal_void (tmp95) ; __ats_lab_lexing_is_eof: tmp92 = lexing_lexbuf_get () ; tmp93 = ats_selsin_mac(tmp92, atslab_1) ; tmp94 = lexbuf_is_eof (tmp93) ; /* tmp95 = */ lexing_lexbuf_set (tmp93) ; tmp91 = tmp94 ; return (tmp91) ; } /* end of [lexing_is_eof] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_lexing.dats: 7231(line=247, offs=24) -- 7263(line=247, offs=56) */ ATSglobaldec() ats_varet_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () { /* local vardec */ // ATSlocal_void (tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error: tmp97 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp96 = */ ats_raise_exn (tmp97) ; return /* (tmp96) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ /* statmp98 = */ lexing_lexbuf_markroot () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ typedef struct { unsigned char *buf_ptr ; int buf_size ; ats_ptr_type infile ; int fstpos ; int fstpos_line ; // line number int fstpos_loff ; // line offset long int fstpos_toff ; // total offset int lstpos ; int lstpos_line ; // line number int lstpos_loff ; // line offset long int lstpos_toff ; // total offset int curpos ; int curpos_line ; // line number int curpos_loff ; // line offset long int curpos_toff ; // total offset int endpos ; } lexbuf ; // ats_ptr_type lexbuf_fstpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; return position_make_int_int_lint (lxbf->fstpos_line, lxbf->fstpos_loff, lxbf->fstpos_toff) ; } ats_void_type lexbuf_fstpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; lxbf->fstpos = lxbf->curpos ; lxbf->fstpos_line = lxbf->curpos_line ; lxbf->fstpos_loff = lxbf->curpos_loff ; lxbf->fstpos_toff = lxbf->curpos_toff ; return ; } // ats_ptr_type lexbuf_lstpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; return position_make_int_int_lint (lxbf->lstpos_line, lxbf->lstpos_loff, lxbf->lstpos_toff) ; } ats_void_type lexbuf_lstpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; lxbf->lstpos = lxbf->curpos ; lxbf->lstpos_line = lxbf->curpos_line ; lxbf->lstpos_loff = lxbf->curpos_loff ; lxbf->lstpos_toff = lxbf->curpos_toff ; return ; } // ats_ptr_type lexbuf_curpos_get ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; return position_make_int_int_lint (lxbf->curpos_line, lxbf->curpos_loff, lxbf->curpos_toff) ; } ats_void_type lexbuf_curpos_set ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf *)lxbf0 ; lxbf->curpos = lxbf->lstpos ; lxbf->curpos_line = lxbf->lstpos_line ; lxbf->curpos_loff = lxbf->lstpos_loff ; lxbf->curpos_toff = lxbf->lstpos_toff ; return ; } // ats_int_type lexbuf_size_get (ats_ptr_type lxbf0) { int sz ; lexbuf *lxbf ; lxbf = (lexbuf *)lxbf0; sz = lxbf->lstpos - lxbf->fstpos ; if (sz < 0) { sz += lxbf->buf_size ; } return sz ; } /* ****** ****** */ #define BUF_SIZE 1024 #define BUF_RESIZE 256 /* ****** ****** */ ats_void_type lexbuf_resize (lexbuf *lxbf) { int fstpos, curpos, lstpos, endpos ; int buf_size, buf_size_new ; unsigned char *buf_ptr, *buf_ptr_new; /* fprintf (stdout, "lexbuf_resize: before: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize: before: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize: before: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize: before: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize: before: endpos = %i\n", lxbf->endpos) ; */ buf_ptr = lxbf->buf_ptr ; buf_size = lxbf->buf_size ; fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; buf_size_new = buf_size + buf_size ; buf_ptr_new = ATS_MALLOC (buf_size_new) ; lxbf->buf_ptr = buf_ptr_new ; lxbf->buf_size = buf_size_new ; lxbf->fstpos = 0 ; if (fstpos <= endpos) { memcpy(buf_ptr_new, buf_ptr+fstpos, endpos-fstpos) ; lxbf->endpos = endpos - fstpos ; } else { memcpy(buf_ptr_new, buf_ptr+fstpos, buf_size-fstpos) ; memcpy(buf_ptr_new+buf_size-fstpos, buf_ptr, endpos) ; lxbf->endpos = buf_size + endpos - fstpos ; } // end of [if] curpos = lxbf->curpos ; if (fstpos <= curpos) { lxbf->curpos = curpos - fstpos ; } else { lxbf->curpos = buf_size + curpos - fstpos ; } lstpos = lxbf->lstpos ; if (fstpos <= lstpos) { lxbf->lstpos = lstpos - fstpos ; } else { lxbf->lstpos = buf_size + lstpos - fstpos ; } // end of [if] /* fprintf (stdout, "lexbuf_resize: after: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize: after: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize: after: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize: after: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize: after: endpos = %i\n", lxbf->endpos) ; */ ATS_FREE (buf_ptr) ; } /* end of [lexbuf_resize] */ ats_void_type lexbuf_resize_if (lexbuf *lxbf) { int fstpos, endpos ; /* fprintf (stdout, "lexbuf_resize_if: buf_size = %i\n", lxbf->buf_size) ; fprintf (stdout, "lexbuf_resize_if: fstpos = %i\n", lxbf->fstpos) ; fprintf (stdout, "lexbuf_resize_if: curpos = %i\n", lxbf->curpos) ; fprintf (stdout, "lexbuf_resize_if: lstpos = %i\n", lxbf->lstpos) ; fprintf (stdout, "lexbuf_resize_if: endpos = %i\n", lxbf->endpos) ; */ fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; if (fstpos <= endpos) { if (endpos - fstpos + BUF_RESIZE > lxbf->buf_size) { lexbuf_resize(lxbf) ; } } else { if (endpos + BUF_RESIZE >= fstpos) { lexbuf_resize (lxbf) ; } } return ; } /* end of [lexbuf_resize_if] */ ats_void_type lexbuf_refill ( ats_ptr_type lxbf0 ) { lexbuf *lxbf ; unsigned char *buf_ptr ; int c, fstpos, curpos, endpos ; lxbf = (lexbuf*)lxbf0 ; lexbuf_resize_if (lxbf) ; buf_ptr = lxbf->buf_ptr ; fstpos = lxbf->fstpos ; endpos = lxbf->endpos ; /* fprintf (stdout, "lexbuf_refill: fstpos = %i\n", fstpos) ; fprintf (stdout, "lexbuf_refill: endpos = %i\n", endpos) ; */ if (fstpos <= endpos) { while (endpos+1 < lxbf->buf_size) { c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; ++endpos ; } if (fstpos == 0) { lxbf->endpos = endpos ; return ; } c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; endpos = 0; } /* end of [if] */ while (endpos+1 < fstpos) { c = lexing_infile_getc (lxbf->infile) ; if (c < 0) { lxbf->endpos = endpos ; return ; } buf_ptr[endpos] = c; ++endpos ; } /* end of [while] */ lxbf->endpos = endpos ; return ; } /* end of [lexbuf_refill] */ /* ****** ****** */ ats_void_type lexbuf_curpos_next ( lexbuf *lxbf, int c ) { int curpos1 = lxbf->curpos + 1 ; if (curpos1 < lxbf->buf_size) { lxbf->curpos = curpos1; } else { lxbf->curpos = 0; } if (c == '\n') { lxbf->curpos_line += 1; lxbf->curpos_loff = 0; lxbf->curpos_toff += 1 ; } else { lxbf->curpos_loff += 1 ; lxbf->curpos_toff += 1 ; } return ; } /* end of [lexbuf_curpos_next] */ /* ****** ****** */ ats_int_type lexbuf_char_next ( ats_ptr_type lxbf0 ) { lexbuf *lxbf ; unsigned char *buf_ptr ; int c, fstpos, curpos, endpos ; lxbf = (lexbuf*)lxbf0 ; buf_ptr = lxbf->buf_ptr ; curpos = lxbf->curpos ; endpos = lxbf->endpos ; if (curpos != endpos) { c = buf_ptr[curpos] ; lexbuf_curpos_next (lxbf, c); return c ; } lexbuf_refill (lxbf0) ; buf_ptr = lxbf->buf_ptr ; curpos = lxbf->curpos ; endpos = lxbf->endpos ; /* fprintf (stdout, "lexbuf_char_next: refill: curpos = %i\n", curpos); fprintf (stdout, "lexbuf_char_next: refill: endpos = %i\n", endpos); */ if (curpos != endpos) { c = buf_ptr[curpos] ; lexbuf_curpos_next (lxbf, c); return c ; } return -1 ; /* [-1] represents a special character */ } /* end of [lexbuf_char_next] */ /* ****** ****** */ ats_bool_type lexbuf_is_eof ( ats_ptr_type lxbf0 ) { lexbuf *lxbf = (lexbuf*)lxbf0 ; if (lxbf->curpos != lxbf->endpos) return ats_false_bool ; lexbuf_refill (lxbf0) ; if (lxbf->curpos != lxbf->endpos) { return ats_false_bool ; } else { return ats_true_bool ; } /* end of [if] */ } /* end of [lexbuf_is_eof] */ /* ****** ****** */ ats_ptr_type lexing_fstpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf *)(lexing_lexbuf_get()) ; pos = lexbuf_fstpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } ats_ptr_type lexing_lstpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf *)(lexing_lexbuf_get()) ; pos = lexbuf_lstpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } ats_ptr_type lexing_curpos_get () { ats_ptr_type pos ; lexbuf *lxbf ; lxbf = (lexbuf *)(lexing_lexbuf_get()) ; pos = lexbuf_curpos_get (lxbf) ; lexing_lexbuf_set(lxbf) ; return pos; } /* ****** ****** */ ats_void_type lexbuf_curpos_fprint ( ats_ptr_type fil, lexbuf *lxbf ) { fprintf ((FILE *)fil, "%li(line=%i, offset=%i)", lxbf->curpos_toff+1, lxbf->curpos_line+1, lxbf->curpos_loff+1 ) ; return ; } /* end of [lexbuf_curpos_fprint] */ ats_void_type lexing_curpos_prerr () { lexbuf *lxbf ; lxbf = (lexbuf *)(lexing_lexbuf_get()) ; lexbuf_curpos_fprint (stderr, lxbf) ; lexing_lexbuf_set(lxbf) ; return ; } /* ****** ****** */ ats_ptr_type lexbuf_make_infile ( ats_ptr_type infile ) { lexbuf *lxbf ; unsigned char *buf_ptr ; buf_ptr = ATS_MALLOC (BUF_SIZE) ; lxbf = ATS_MALLOC (sizeof(lexbuf)) ; lxbf->buf_ptr = buf_ptr ; lxbf->buf_size = BUF_SIZE ; lxbf->infile = infile ; lxbf->fstpos = 0 ; lxbf->fstpos_line = 0 ; lxbf->fstpos_loff = 0 ; lxbf->fstpos_toff = 0 ; lxbf->lstpos = 0 ; lxbf->lstpos_line = 0 ; lxbf->lstpos_loff = 0 ; lxbf->lstpos_toff = 0 ; lxbf->curpos = 0 ; lxbf->curpos_line = 0 ; lxbf->curpos_loff = 0 ; lxbf->curpos_toff = 0 ; lxbf->endpos = 0 ; /* printf ("lexbuf_make_infile: lxbf = %p\n", lxbf) ; */ return lxbf ; } /* end of [lexbuf_make_infile] */ ats_void_type lexbuf_free (ats_ptr_type lxbf0) { lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0 ; lexing_infile_free (lxbf->infile) ; ATS_FREE (lxbf->buf_ptr) ; return ; } /* ****** ****** */ ats_char_type lexeme_get_lexbuf (ats_ptr_type lxbf0, ats_int_type i) { int len, fstpos, lstpos, bufsz ; lexbuf *lxbf ; if (i < 0) { ats_exit_errmsg ( 1, "lexeme_get_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ lxbf = (lexbuf*)lxbf0 ; fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; bufsz = lxbf->buf_size ; if (len < 0) { len += bufsz ; } if (i > len) { ats_exit_errmsg ( 1, "lexeme_get_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ i = fstpos + i ; if (i >= bufsz) { i -= bufsz ; } return *((lxbf->buf_ptr) + i) ; } ats_void_type lexeme_set_lexbuf ( ats_ptr_type lxbf0 , ats_int_type i, ats_char_type c ) { int len, fstpos, lstpos, bufsz ; lexbuf *lxbf ; if (i < 0) { ats_exit_errmsg ( 1, (ats_ptr_type)"lexeme_set_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ lxbf = (lexbuf*)lxbf0 ; fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; bufsz = lxbf->buf_size ; if (len < 0) { len += bufsz ; } if (i > len) { ats_exit_errmsg ( 1, (ats_ptr_type)"lexeme_set_lexbuf: index is out_of_bounds.\n" ) ; } /* end of [if] */ i = fstpos + i ; if (i >= bufsz) { i -= bufsz ; } *((lxbf->buf_ptr) + i) = c ; return ; } /* end of [lexeme_set_lexbuf] */ /* ****** ****** */ ats_ptr_type lexeme_string_lexbuf (ats_ptr_type lxbf0) { int len, fstpos, lstpos ; char *src, *dst0, *dst ; lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0 ; fstpos = lxbf->fstpos ; lstpos = lxbf->lstpos ; len = lstpos - fstpos ; if (len < 0) { len += lxbf->buf_size ; } src = (lxbf->buf_ptr) + fstpos ; dst0 = ATS_MALLOC ((len + 1) * sizeof(char)) ; dst = dst0 ; if (lstpos < fstpos) { while (fstpos < lxbf->buf_size) { *dst = *src ; ++fstpos ; ++src ; ++dst ; } fstpos = 0 ; src = lxbf->buf_ptr ; } // end of [if] while (fstpos < lstpos) { *dst = *src ; ++fstpos ; ++src ; ++dst ; } // end of [while] *dst = '\000' ; return dst0 ; } /* end of [lexeme_string_lexbuf] */ /* ****** ****** */ ats_lint_type lexeme_lint_lexbuf ( ats_ptr_type lxbf0 , ats_int_type base ) { int fstpos ; lexbuf *lxbf ; lxbf = (lexbuf*)lxbf0 ; fstpos = lxbf->fstpos ; return strtol ((lxbf->buf_ptr) + fstpos, (char**)0, base) ; } /* end of [lexeme_lint_lexbuf] */ /* ****** ****** */ static ats_ptr_type the_lexbuf = (lexbuf*)0 ; ats_void_type lexing_lexbuf_markroot () { ATS_GC_MARKROOT (&the_lexbuf, sizeof(ats_ptr_type)) ; return ; } static ats_int_type the_lexbuf_flag = 0 ; ats_ptr_type lexing_lexbuf_get() { if (the_lexbuf_flag == 0) { ats_exit_errmsg ( 1, "[lexeme_get] failed: The default lexbuf is not set!\n" ); } the_lexbuf_flag = 0 ; return the_lexbuf ; } ats_void_type lexing_lexbuf_set(ats_ptr_type lxbf) { if (the_lexbuf_flag == 1) { ats_exit_errmsg ( 1, "[lexeme_set] failed: The default lexbuf is already set!\n" ); } the_lexbuf_flag = 1 ; the_lexbuf = lxbf ; /* printf ("lexing_lexbuf_set: lxbf = %p\n", lxbf) ; */ return ; } ats_void_type lexing_lexbuf_free () { lexbuf_free (lexing_lexbuf_get ()) ; return ; } /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libats_lex_lexing_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_pprint_sats.c0000664000175000017500000000240212223166160023116 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_pprint_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_deref_dats.c0000664000175000017500000003254312223166160022505 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_1 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_deref.dats: 3656(line=102, offs=11) -- 3853(line=109, offs=10) */ ATSstaticdec() ats_void_type aux_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; __ats_lab_aux_1: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp24 = */ atspre_prerr_string (ATSstrcst(".")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (tmp22) ; arg0 = tmp23 ; goto __ats_lab_aux_1 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp21) */ ; } /* end of [aux_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_deref.dats: 1946(line=62, offs=3) -- 4071(line=116, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp0) ; ATSlocal (anairiats_rec_0, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (anairiats_rec_2, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (anairiats_rec_1, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (arg1) ; tmp2 = ats_select_mac(tmp1, atslab_0) ; tmp3 = ats_select_mac(tmp1, atslab_1) ; tmp4 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp3, arg2) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (tmp2, tmp4) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp5 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp6 = ats_caselptrlab_mac(anairiats_sum_3, tmp5, atslab_0) ; ATS_FREE(tmp5) ; tmp7 = ats_select_mac(tmp6, atslab_0) ; tmp8 = ats_select_mac(tmp6, atslab_1) ; tmp9 = ats_select_mac(tmp6, atslab_2) ; tmp10 = ats_select_mac(tmp6, atslab_3) ; tmp11 = ats_select_mac(tmp6, atslab_4) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local (tmp7) ; /* ats_ptr_type tmp13 ; */ tmp13 = (ats_sum_ptr_type)0 ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr (arg0, tmp8, tmp11, (&tmp13)) ; tmp15 = ats_select_mac(tmp14, atslab_0) ; tmp16 = ats_select_mac(tmp14, atslab_1) ; tmp17 = ats_select_mac(tmp14, atslab_2) ; /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp13) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (tmp3, tmp10, tmp17) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (tmp7, tmp16, tmp9) ; tmp0.atslab_0 = tmp15 ; tmp0.atslab_1 = tmp19 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp27 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp28 = */ atspre_prerr_string (ATSstrcst(": there is no view at [")) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp2) ; /* tmp30 = */ aux_1 (tmp4) ; /* tmp31 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp32 = */ atspre_prerr_newline () ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_deref_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_dyn2_dats.c0000664000175000017500000053213612223166160022276 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_dqi0de_loc ; ats_ptr_type atslab_dqi0de_qua ; ats_ptr_type atslab_dqi0de_sym ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_v1aldec_loc ; ats_ptr_type atslab_v1aldec_pat ; ats_ptr_type atslab_v1aldec_def ; ats_ptr_type atslab_v1aldec_ann ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_f1undec_loc ; ats_ptr_type atslab_f1undec_sym ; ats_ptr_type atslab_f1undec_sym_loc ; ats_ptr_type atslab_f1undec_def ; ats_ptr_type atslab_f1undec_ann ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_v1ardec_loc ; ats_int_type atslab_v1ardec_knd ; ats_ptr_type atslab_v1ardec_sym ; ats_ptr_type atslab_v1ardec_sym_loc ; ats_ptr_type atslab_v1ardec_typ ; ats_ptr_type atslab_v1ardec_wth ; ats_ptr_type atslab_v1ardec_ini ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_v2ardec_loc ; ats_int_type atslab_v2ardec_knd ; ats_ptr_type atslab_v2ardec_dvar ; ats_ptr_type atslab_v2ardec_svar ; ats_ptr_type atslab_v2ardec_typ ; ats_ptr_type atslab_v2ardec_wth ; ats_ptr_type atslab_v2ardec_ini ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_s1arg_loc ; ats_ptr_type atslab_s1arg_sym ; ats_ptr_type atslab_s1arg_srt ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_11 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_p1at_loc ; ats_ptr_type atslab_p1at_node ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_20 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_m1acdef_loc ; ats_ptr_type atslab_m1acdef_sym ; ats_ptr_type atslab_m1acdef_arg ; ats_ptr_type atslab_m1acdef_def ; } anairiats_rec_22 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_23 ; typedef struct { ats_ptr_type atslab_i1mpdec_loc ; ats_ptr_type atslab_i1mpdec_qid ; ats_ptr_type atslab_i1mpdec_tmparg ; ats_ptr_type atslab_i1mpdec_def ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_impqi0de_loc ; ats_ptr_type atslab_impqi0de_qua ; ats_ptr_type atslab_impqi0de_sym ; ats_ptr_type atslab_impqi0de_arg ; } anairiats_rec_25 ; typedef struct { anairiats_rec_12 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_26 ; typedef struct { ats_ptr_type atslab_d2ec_loc ; ats_ptr_type atslab_d2ec_node ; } anairiats_rec_27 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_28 ; typedef struct { ats_ptr_type atslab_d1ec_loc ; ats_ptr_type atslab_d1ec_node ; } anairiats_rec_29 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_30 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEprop_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEtype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymelim_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ce1xpdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatsrts_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csrtdefs_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacons_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacsts_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstavars_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csexpdefs_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csaspdec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdcstdecs_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cexndecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cclassdec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Coverload_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextype_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextval_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextcode_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_par_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_rec_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cfundecs_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvardecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cmacdefs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cimpdec_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clocal_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdynload_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstaload_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMe1xp_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMfil_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMe1xp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Coverload_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGlst_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_beg) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_end) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1exp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_bool_type, ats_bool_type, ats_bool_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_supcls) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_arilst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_decarg) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_def) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_make) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_set_def) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__f2undec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2ardec_make) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2mpdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_include) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symintr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symelim) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_stavars) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_saspdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dcstdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_datdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_overload) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_exndec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extype) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extcode) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_par) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_fundecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_vardecs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_impdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_local) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_staload) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_dec) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_varlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_current_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_localjoin) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_restore) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_namespace_add_topenv) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1taconlst_tr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tavarlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atsrtdeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdeflst_tr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1aspdec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atdeclst_tr) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__e1xndeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1ec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_void_type dyncstimploc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_5 (ats_ptr_type arg0) ; static ats_void_type symintr_tr_4 (ats_ptr_type arg0) ; static ats_void_type aux_7 (ats_ptr_type arg0) ; static ats_void_type symelim_tr_6 (ats_ptr_type arg0) ; static ats_void_type c1lassdec_tr_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type overload_tr_10 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type witht1ype_tr_11 (ats_ptr_type arg0) ; static ats_ptr_type v1aldec_tr_12 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux1_14 (ats_ptr_type arg0) ; static ats_ptr_type aux2_15 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v1aldeclst_tr_13 (ats_bool_type arg0, ats_ptr_type arg1) ; static ats_ptr_type f1undec_tr_16 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux1_18 (ats_bool_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_19 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type f1undeclst_tr_17 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type v1ardec_tr_20 (ats_ptr_type arg0) ; static ats_ptr_type aux1_22 (ats_ptr_type arg0) ; static ats_void_type aux2_23 (ats_ptr_type arg0) ; static ats_ptr_type v1ardeclst_tr_21 (ats_ptr_type arg0) ; static ats_ptr_type aux_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s1arglst_bind_svarlst_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type aux_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s1explst_bind_svarlst_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type d1exp_tr_ann_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1) ; static anairiats_rec_12 d1exp_arg_body_tr_ann_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) ; static ats_void_type aux_32 (ats_ptr_type arg0) ; static ats_void_type m1acdef_tr_31 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type f_36 (ats_ptr_type arg0) ; static ats_ptr_type auxarg_35 (ats_ptr_type arg0) ; static ats_ptr_type auxarglst_37 (ats_ptr_type arg0) ; static ats_ptr_type aux1_34 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux1_34_closure_make (ats_int_type env0) ; static ats_ptr_type aux1_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type aux2_38 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type m1acdeflst_tr_33 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux1_40 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux2_41 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_bool_type aux1_40_0aux2_41 (ats_int_type arg0, ...) ; static ats_bool_type d1exp_arity_check_39 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_44 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_44_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_44_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type i1mpdec_tr_d2cst_select_43 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_imp_46 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_clo_ptr_type aux2_imp_46_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux2_imp_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_ptr_type aux2_tmp_47 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5) ; static ats_clo_ptr_type aux2_tmp_47_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux2_tmp_47_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5) ; static ats_ptr_type i1mpdec_tr_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1taload_tr_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ref_type arg5) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 2583(line=90, offs=4) -- 2668(line=91, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 2702(line=94, offs=4) -- 2762(line=94, offs=64) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans2_dyn2)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 2767(line=96, offs=4) -- 2880(line=98, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans2_dyn2)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 2937(line=102, offs=4) -- 3282(line=111, offs=4) */ ATSstaticdec() ats_void_type dyncstimploc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_lint_type, tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_lint_type, tmp9) ; __ats_lab_dyncstimploc_posmark_3: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc (arg1) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_beg (tmp7, tmp6) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_dyncstimp_end (tmp9, tmp6) ; return /* (tmp5) */ ; } /* end of [dyncstimploc_posmark_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 3385(line=116, offs=7) -- 3589(line=120, offs=24) */ ATSstaticdec() ats_void_type aux_5 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; // ATSlocal_void (tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_aux_5: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp12), atslab_i0de_sym) ; tmp17 = (ats_sum_ptr_type)0 ; tmp16 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp16)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp16, atslab_0, tmp17) ; /* tmp14 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp15, tmp16) ; arg0 = tmp13 ; goto __ats_lab_aux_5 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp11) */ ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 3341(line=115, offs=4) -- 3645(line=124, offs=4) */ ATSstaticdec() ats_void_type symintr_tr_4 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp10) ; __ats_lab_symintr_tr_4: /* tmp10 = */ aux_5 (arg0) ; return /* (tmp10) */ ; } /* end of [symintr_tr_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 3717(line=127, offs=7) -- 3921(line=131, offs=24) */ ATSstaticdec() ats_void_type aux_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_aux_7: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp23 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp20), atslab_i0de_sym) ; tmp25 = (ats_sum_ptr_type)0 ; tmp24 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp24)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp24, atslab_0, tmp25) ; /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp23, tmp24) ; arg0 = tmp21 ; goto __ats_lab_aux_7 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp19) */ ; } /* end of [aux_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 3673(line=126, offs=4) -- 3977(line=135, offs=4) */ ATSstaticdec() ats_void_type symelim_tr_6 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; __ats_lab_symelim_tr_6: /* tmp18 = */ aux_7 (arg0) ; return /* (tmp18) */ ; } /* end of [symelim_tr_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 4026(line=139, offs=4) -- 4631(line=163, offs=2) */ ATSstaticdec() ats_void_type c1lassdec_tr_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_c1lassdec_tr_8: tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_loc) ; tmp30 = (ats_sum_ptr_type)0 ; tmp31 = (ats_sum_ptr_type)0 ; tmp32 = (ats_sum_ptr_type)0 ; tmp33 = (ats_sum_ptr_type)0 ; tmp27 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (tmp28, tmp29, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls, tmp30, ats_false_bool, ats_false_bool, ats_false_bool, tmp31, tmp32, tmp33) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls (tmp35) ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_supcls (tmp27, tmp36) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp27) ; return /* (tmp26) */ ; } /* end of [c1lassdec_tr_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 4705(line=168, offs=17) -- 6108(line=208, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr: tmp38 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; tmp39 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_current_find (tmp38) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp39 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp40 = tmp39 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp39 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp40 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find (tmp38) ; break ; } while (0) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp40 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_8_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_3, tmp40, atslab_0) ; ATS_FREE(tmp40) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp42)->tag != 5) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_2, tmp42, atslab_0) ; tmp41 = tmp43 ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: tmp45 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_loc) ; /* tmp44 = */ prerr_loc_error2_0 (tmp45) ; /* tmp46 = */ atsopt_debug_prerrf (ATSstrcst(": %s: overload_def_tr"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp47 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp49) ; /* tmp50 = */ atspre_prerr_string (ATSstrcst("] should refer to a symbol but it does not.")) ; /* tmp51 = */ atspre_prerr_newline () ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (tmp40 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp53 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_loc) ; /* tmp52 = */ prerr_loc_error2_0 (tmp53) ; /* tmp54 = */ atsopt_debug_prerrf (ATSstrcst(": %s: overload_def_tr"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp55 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp57) ; /* tmp58 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp59 = */ atspre_prerr_newline () ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp61 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp61, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_0, tmp61, atslab_1, tmp41) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp60)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp60, atslab_0, tmp61) ; tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp62, tmp60) ; return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 6165(line=212, offs=4) -- 7041(line=240, offs=2) */ ATSstaticdec() ats_ptr_type overload_tr_10 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; __ats_lab_overload_tr_10: tmp65 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_dqi0de_qua) ; tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_dqi0de_sym) ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (tmp65, tmp66) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp64 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_3, tmp64, atslab_0) ; ATS_FREE(tmp64) ; tmp67 = tmp68 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp64 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp70 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_dqi0de_loc) ; /* tmp69 = */ prerr_loc_error2_0 (tmp70) ; /* tmp71 = */ atsopt_debug_prerrf (ATSstrcst(": %s: overload_tr"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp72 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; tmp74 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_dqi0de_qua) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (tmp74) ; tmp76 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_dqi0de_sym) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp76) ; /* tmp77 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp78 = */ atspre_prerr_newline () ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr (arg0, tmp67) ; tmp63 = tmp67 ; return (tmp63) ; } /* end of [overload_tr_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 7091(line=244, offs=4) -- 7433(line=250, offs=70) */ ATSstaticdec() ats_ptr_type witht1ype_tr_11 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_witht1ype_tr_11: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp80 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp81, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; tmp80 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp80, atslab_0, tmp82) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp84 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp83, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp80 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp80, atslab_0, tmp84) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp86 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp85, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; tmp80 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp80, atslab_0, tmp86) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp88 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp87, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; tmp80 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp80, atslab_0, tmp88) ; break ; } while (0) ; return (tmp80) ; } /* end of [witht1ype_tr_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 7484(line=255, offs=4) -- 7693(line=263, offs=4) */ ATSstaticdec() ats_ptr_type v1aldec_tr_12 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_v1aldec_tr_12: tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_v1aldec_loc) ; tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_v1aldec_def) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp92) ; tmp94 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_v1aldec_ann) ; tmp93 = witht1ype_tr_11 (tmp94) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make (tmp90, arg1, tmp91, tmp93) ; return (tmp89) ; } /* end of [v1aldec_tr_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 7808(line=267, offs=7) -- 7973(line=270, offs=23) */ ATSstaticdec() ats_ptr_type aux1_14 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_aux1_14: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp98 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp100 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp97), atslab_v1aldec_pat) ; tmp99 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_tr (tmp100) ; tmp101 = aux1_14 (tmp98) ; tmp96 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp96, atslab_0, tmp99) ; ats_selptrset_mac(anairiats_sum_0, tmp96, atslab_1, tmp101) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp96 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp96) ; } /* end of [aux1_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 7980(line=271, offs=7) -- 8241(line=279, offs=23) */ ATSstaticdec() ats_ptr_type aux2_15 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_aux2_15: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp105 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp106 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp107 = v1aldec_tr_12 (tmp103, tmp105) ; tmp108 = aux2_15 (tmp104, tmp106) ; tmp102 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp102, atslab_0, tmp107) ; ats_selptrset_mac(anairiats_sum_0, tmp102, atslab_1, tmp108) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp102 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp102) ; } /* end of [aux2_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 7721(line=265, offs=4) -- 8709(line=295, offs=4) */ ATSstaticdec() ats_ptr_type v1aldeclst_tr_13 (ats_bool_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; // ATSlocal_void (tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; __ats_lab_v1aldeclst_tr_13: tmp109 = aux1_14 (arg1) ; tmp111 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_svs_union (tmp109) ; tmp110 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (tmp111) ; tmp113 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_dvs_union (tmp109) ; tmp112 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp113) ; if (arg0) { /* tmp114 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp112) ; tmp115 = aux2_15 (arg1, tmp109) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp110) ; tmp95 = tmp115 ; } else { tmp117 = aux2_15 (arg1, tmp109) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp112) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp110) ; tmp95 = tmp117 ; } /* end of [if] */ return (tmp95) ; } /* end of [v1aldeclst_tr_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 8764(line=299, offs=4) -- 9248(line=317, offs=4) */ ATSstaticdec() ats_ptr_type f1undec_tr_16 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_f1undec_tr_16: /* tmp121 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (arg2, arg0) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_decarg (arg2, arg1) ; tmp124 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_f1undec_def) ; tmp123 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp124) ; tmp126 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_f1undec_ann) ; tmp125 = witht1ype_tr_11 (tmp126) ; tmp127 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg3), atslab_f1undec_loc) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__f2undec_make (tmp127, arg2, tmp123, tmp125) ; return (tmp120) ; } /* end of [f1undec_tr_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 9557(line=328, offs=9) -- 9956(line=339, offs=8) */ ATSstaticdec() ats_ptr_type aux1_18 (ats_bool_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; // ATSlocal_void (tmp137) ; // ATSlocal_void (tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_aux1_18: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp133 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp135 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp132), atslab_f1undec_sym_loc) ; tmp136 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp132), atslab_f1undec_sym) ; tmp134 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp135, tmp136) ; /* tmp137 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix (tmp134, ats_true_bool) ; /* tmp138 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf (tmp134, arg0) ; tmp139 = aux1_18 (arg0, tmp133) ; tmp131 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp131, atslab_0, tmp134) ; ats_selptrset_mac(anairiats_sum_0, tmp131, atslab_1, tmp139) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp131 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp131) ; } /* end of [aux1_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 10002(line=341, offs=7) -- 10403(line=355, offs=23) */ ATSstaticdec() ats_ptr_type aux2_19 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_aux2_19: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; // if (arg3 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp144 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_1) ; tmp146 = f1undec_tr_16 (arg0, arg1, tmp142, tmp144) ; tmp147 = aux2_19 (arg0, arg1, tmp143, tmp145) ; tmp141 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp141, atslab_0, tmp146) ; ats_selptrset_mac(anairiats_sum_0, tmp141, atslab_1, tmp147) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp141 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp141) ; } /* end of [aux2_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 9276(line=319, offs=4) -- 10593(line=361, offs=4) */ ATSstaticdec() ats_ptr_type f1undeclst_tr_17 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_bool_type, tmp129) ; ATSlocal (ats_bool_type, tmp130) ; ATSlocal (ats_ptr_type, tmp140) ; // ATSlocal_void (tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; __ats_lab_f1undeclst_tr_17: tmp129 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof (arg0) ; tmp130 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive (arg0) ; tmp140 = aux1_18 (tmp129, arg3) ; if (tmp130) { /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp140) ; } else { /* empty */ } /* end of [if] */ tmp149 = aux2_19 (arg1, arg2, tmp140, arg3) ; if (tmp130) { /* empty */ } else { /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp140) ; } /* end of [if] */ tmp128 = tmp149 ; return (tmp128) ; } /* end of [f1undeclst_tr_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 10645(line=365, offs=4) -- 11873(line=400, offs=4) */ ATSstaticdec() ats_ptr_type v1ardec_tr_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; // ATSlocal_void (tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; __ats_lab_v1ardec_tr_20: tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_knd) ; tmp153 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_sym) ; tmp154 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_sym_loc) ; tmp155 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp154, tmp153) ; tmp156 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp153, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; tmp158 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp156) ; tmp157 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp157, atslab_0, tmp158) ; /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp155, tmp157) ; tmp161 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_typ) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp161 == (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp162 = ats_caselptrlab_mac(anairiats_sum_3, tmp161, atslab_0) ; tmp163 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp162) ; tmp160 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp160, atslab_0, tmp163) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp161 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp160 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp165 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_wth) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (tmp165 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_3, tmp165, atslab_0) ; tmp168 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp166), atslab_i0de_loc) ; tmp169 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp166), atslab_i0de_sym) ; tmp167 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp168, tmp169) ; tmp164 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp164, atslab_0, tmp167) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (tmp165 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp164 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp171 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_ini) ; tmp170 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1expopt_tr (tmp171) ; tmp172 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_v1ardec_loc) ; tmp151 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2ardec_make (tmp172, tmp152, tmp155, tmp156, tmp160, tmp164, tmp170) ; return (tmp151) ; } /* end of [v1ardec_tr_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 11969(line=404, offs=7) -- 12115(line=408, offs=23) */ ATSstaticdec() ats_ptr_type aux1_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_aux1_22: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp177 = v1ardec_tr_20 (tmp175) ; tmp178 = aux1_22 (tmp176) ; tmp174 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp174, atslab_0, tmp177) ; ats_selptrset_mac(anairiats_sum_0, tmp174, atslab_1, tmp178) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp174 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp174) ; } /* end of [aux1_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 12164(line=411, offs=7) -- 12594(line=422, offs=19) */ ATSstaticdec() ats_void_type aux2_23 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; // ATSlocal_void (tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; // ATSlocal_void (tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_aux2_23: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp184 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp181), atslab_v2ardec_svar) ; /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp184) ; tmp186 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp181), atslab_v2ardec_dvar) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar (tmp186) ; tmp188 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp181), atslab_v2ardec_wth) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp188 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp189 = ats_caselptrlab_mac(anairiats_sum_3, tmp188, atslab_0) ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar (tmp189) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (tmp188 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: break ; } while (0) ; arg0 = tmp182 ; goto __ats_lab_aux2_23 ; // tail call break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: break ; } while (0) ; return /* (tmp180) */ ; } /* end of [aux2_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 11901(line=402, offs=4) -- 12636(line=425, offs=2) */ ATSstaticdec() ats_ptr_type v1ardeclst_tr_21 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp179) ; // ATSlocal_void (tmp190) ; __ats_lab_v1ardeclst_tr_21: tmp179 = aux1_22 (arg0) ; /* tmp190 = */ aux2_23 (tmp179) ; tmp173 = tmp179 ; return (tmp173) ; } /* end of [v1ardeclst_tr_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 12803(line=432, offs=7) -- 13718(line=456, offs=23) */ ATSstaticdec() ats_ptr_type aux_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; // ATSlocal_void (tmp199) ; ATSlocal (ats_bool_type, tmp200) ; ATSlocal (ats_bool_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_aux_25: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp193 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp195 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp196 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp198 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp195) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt (tmp193, tmp198) ; tmp202 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp195) ; tmp203 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp197) ; tmp201 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp202, tmp203) ; tmp200 = atspre_neg_bool (tmp201) ; if (tmp200) { tmp205 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp193), atslab_s1arg_loc) ; /* tmp204 = */ prerr_loc_error2_0 (tmp205) ; /* tmp206 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1arglst_bind_svarlst"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp207 = */ atspre_prerr_string (ATSstrcst(": the ascribed sort for the static variable [")) ; tmp209 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp193), atslab_s1arg_sym) ; /* tmp208 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp209) ; /* tmp210 = */ atspre_prerr_string (ATSstrcst("] is incorrect.")) ; /* tmp211 = */ atspre_prerr_newline () ; /* tmp199 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp212 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp197) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (ats_ptrget_mac(ats_ptr_type, arg2), tmp195, tmp212) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp213 ; tmp214 = aux_25 (tmp194, tmp196, arg2) ; tmp192 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp192, atslab_0, tmp197) ; ats_selptrset_mac(anairiats_sum_0, tmp192, atslab_1, tmp214) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp192 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp192) ; } /* end of [aux_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 12688(line=429, offs=4) -- 14139(line=469, offs=4) */ ATSstaticdec() ats_ptr_type s1arglst_bind_svarlst_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_int_type, tmp216) ; ATSlocal (ats_bool_type, tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; ATSlocal (ats_bool_type, tmp220) ; // ATSlocal_void (tmp221) ; ATSlocal (ats_bool_type, tmp222) ; // ATSlocal_void (tmp223) ; __ats_lab_s1arglst_bind_svarlst_24: tmp215 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp217 = atspre_ineq (tmp215, tmp216) ; if (tmp217) { /* tmp218 = */ prerr_loc_error2_0 (arg0) ; tmp220 = atspre_ilt (tmp215, tmp216) ; if (tmp220) { /* tmp219 = */ atspre_prerr_string (ATSstrcst(": more static arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ tmp222 = atspre_igt (tmp215, tmp216) ; if (tmp222) { /* tmp221 = */ atspre_prerr_string (ATSstrcst(": fewer static arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ /* tmp223 = */ atspre_prerr_newline () ; /* tmp191 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { tmp191 = aux_25 (arg1, arg2, arg3) ; } /* end of [if] */ return (tmp191) ; } /* end of [s1arglst_bind_svarlst_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 14323(line=476, offs=7) -- 15241(line=499, offs=6) */ ATSstaticdec() ats_ptr_type aux_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_bool_type, tmp234) ; ATSlocal (ats_bool_type, tmp235) ; // ATSlocal_void (tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_aux_27: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp227 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp228 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp230 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (tmp226) ; tmp231 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp228) ; tmp232 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp230), atslab_s2exp_srt) ; tmp235 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp232, tmp231) ; tmp234 = atspre_neg_bool (tmp235) ; if (tmp234) { tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, tmp226), atslab_s1exp_loc) ; /* tmp236 = */ prerr_loc_error2_0 (tmp237) ; /* tmp238 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1explst_bind_svarlst"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp239 = */ atspre_prerr_string (ATSstrcst(": the sort of the static expression [")) ; /* tmp240 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1exp (tmp226) ; /* tmp241 = */ atspre_prerr_string (ATSstrcst("] is expected to be [")) ; /* tmp242 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp231) ; /* tmp243 = */ atspre_prerr_string (ATSstrcst("], but it is [")) ; /* tmp244 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp232) ; /* tmp245 = */ atspre_prerr_string (ATSstrcst("] instead.")) ; /* tmp246 = */ atspre_prerr_newline () ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp247 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (ats_ptrget_mac(ats_ptr_type, arg2), tmp228, tmp230) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp247 ; tmp248 = aux_27 (tmp227, tmp229, arg2) ; tmp225 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp225, atslab_0, tmp230) ; ats_selptrset_mac(anairiats_sum_0, tmp225, atslab_1, tmp248) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: tmp225 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp225) ; } /* end of [aux_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 14208(line=473, offs=4) -- 15664(line=511, offs=4) */ ATSstaticdec() ats_ptr_type s1explst_bind_svarlst_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_int_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; ATSlocal (ats_bool_type, tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; ATSlocal (ats_bool_type, tmp254) ; // ATSlocal_void (tmp255) ; ATSlocal (ats_bool_type, tmp256) ; // ATSlocal_void (tmp257) ; __ats_lab_s1explst_bind_svarlst_26: tmp249 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp250 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp251 = atspre_ineq (tmp249, tmp250) ; if (tmp251) { /* tmp252 = */ prerr_loc_error2_0 (arg0) ; tmp254 = atspre_ilt (tmp249, tmp250) ; if (tmp254) { /* tmp253 = */ atspre_prerr_string (ATSstrcst(": more template arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ tmp256 = atspre_igt (tmp249, tmp250) ; if (tmp256) { /* tmp255 = */ atspre_prerr_string (ATSstrcst(": fewer template arguments should be given.")) ; } else { /* empty */ } /* end of [if] */ /* tmp257 = */ atspre_prerr_newline () ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { tmp224 = aux_27 (arg1, arg2, arg3) ; } /* end of [if] */ return (tmp224) ; } /* end of [s1explst_bind_svarlst_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 15772(line=517, offs=5) -- 17600(line=561, offs=4) */ ATSstaticdec() ats_ptr_type d1exp_tr_ann_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; // ATSlocal_void (tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; // ATSlocal_void (tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_int_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (anairiats_rec_12, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_int_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (anairiats_rec_12, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; __ats_lab_d1exp_tr_ann_28: tmp259 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp259)->tag != 30) { goto __ats_lab_44_0 ; } __ats_lab_41_1: tmp260 = ats_caselptrlab_mac(anairiats_sum_13, tmp259, atslab_0) ; tmp261 = ats_caselptrlab_mac(anairiats_sum_13, tmp259, atslab_1) ; tmp262 = ats_caselptrlab_mac(anairiats_sum_13, tmp259, atslab_2) ; tmp263 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp263)->tag != 32) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp264 = ats_caselptrlab_mac(anairiats_sum_13, tmp263, atslab_0) ; tmp265 = ats_caselptrlab_mac(anairiats_sum_13, tmp263, atslab_1) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_13, tmp263, atslab_2) ; /* ats_ptr_type tmp267 ; */ tmp267 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; tmp268 = s1arglst_bind_svarlst_24 (tmp264, tmp265, tmp260, (&tmp267)) ; /* tmp269 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp270 = ats_selsin_mac(tmp269, atslab_1) */ ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp268) ; tmp272 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp267, tmp261) ; tmp273 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp267, tmp262) ; tmp274 = d1exp_tr_ann_28 (tmp266, tmp273) ; /* tmp275 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp276 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta (tmp276, tmp268, tmp272, tmp274) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp277 = d1exp_tr_ann_28 (arg0, tmp262) ; tmp278 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_sta (tmp278, tmp260, tmp261, tmp277) ; break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp259)->tag != 11) { goto __ats_lab_48_0 ; } __ats_lab_44_1: tmp279 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_0) ; tmp280 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_1) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_2) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_3) ; tmp283 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_4) ; tmp284 = ats_caselptrlab_mac(anairiats_sum_15, tmp259, atslab_5) ; tmp285 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp285)->tag != 29) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp286 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_0) ; tmp287 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_1) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_2) ; tmp289 = d1exp_arg_body_tr_ann_29 (arg0, tmp279, tmp280, tmp281, tmp282, tmp283, tmp284, tmp286, tmp287, tmp288) ; tmp290 = ats_select_mac(tmp289, atslab_0) ; tmp291 = ats_select_mac(tmp289, atslab_1) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn (tmp292, tmp280, tmp282, tmp290, tmp291) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp285)->tag != 30) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_1) ; tmp295 = ats_caselptrlab_mac(anairiats_sum_16, tmp285, atslab_2) ; tmp296 = d1exp_arg_body_tr_ann_29 (arg0, tmp279, tmp280, tmp281, tmp282, tmp283, tmp284, tmp293, tmp294, tmp295) ; tmp297 = ats_select_mac(tmp296, atslab_0) ; tmp298 = ats_select_mac(tmp296, atslab_1) ; tmp299 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_laminit_dyn (tmp299, tmp280, tmp282, tmp297, tmp298) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp300 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp301 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (arg0) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (tmp300, tmp301, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: __ats_lab_48_1: tmp302 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; tmp303 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (arg0) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (tmp302, tmp303, arg1) ; break ; } while (0) ; return (tmp258) ; } /* end of [d1exp_tr_ann_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 19553(line=618, offs=9) -- 19842(line=626, offs=25) */ ATSstaticdec() ats_ptr_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; __ats_lab_aux_30: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp349 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp350 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp353 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp348), atslab_p2at_loc) ; tmp352 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (tmp353, tmp348, tmp350) ; tmp354 = aux_30 (tmp349, tmp351) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp347, atslab_0, tmp352) ; ats_selptrset_mac(anairiats_sum_0, tmp347, atslab_1, tmp354) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp347 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp347) ; } /* end of [aux_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 17634(line=563, offs=5) -- 21564(line=678, offs=4) */ ATSstaticdec() anairiats_rec_12 d1exp_arg_body_tr_ann_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) { /* local vardec */ ATSlocal (anairiats_rec_12, tmp304) ; // ATSlocal_void (tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_bool_type, tmp307) ; // ATSlocal_void (tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_bool_type, tmp312) ; // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; ATSlocal (ats_bool_type, tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_bool_type, tmp319) ; // ATSlocal_void (tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; // ATSlocal_void (tmp323) ; ATSlocal (ats_bool_type, tmp324) ; // ATSlocal_void (tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_bool_type, tmp336) ; // ATSlocal_void (tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; ATSlocal (ats_bool_type, tmp341) ; // ATSlocal_void (tmp342) ; ATSlocal (ats_bool_type, tmp343) ; // ATSlocal_void (tmp344) ; ATSlocal (ats_int_type, tmp345) ; ATSlocal (ats_int_type, tmp346) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_bool_type, tmp356) ; // ATSlocal_void (tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; ATSlocal (ats_bool_type, tmp361) ; // ATSlocal_void (tmp362) ; ATSlocal (ats_bool_type, tmp363) ; // ATSlocal_void (tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; // ATSlocal_void (tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; // ATSlocal_void (tmp372) ; // ATSlocal_void (tmp373) ; // ATSlocal_void (tmp374) ; ATSlocal (ats_int_type, tmp375) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_int_type, tmp378) ; ATSlocal (ats_int_type, tmp379) ; // ATSlocal_void (tmp380) ; ATSlocal (ats_bool_type, tmp381) ; // ATSlocal_void (tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; __ats_lab_d1exp_arg_body_tr_ann_29: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp307 = atspre_eq_int_int (tmp306, 0) ; if (!tmp307) { goto __ats_lab_50_1 ; } tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; /* tmp308 = */ prerr_loc_error2_0 (tmp309) ; /* tmp310 = */ atspre_prerr_string (ATSstrcst(": function is given an unboxed closure type.")) ; /* tmp305 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: break ; } while (0) ; tmp312 = atspre_neq_int_int (arg2, arg7) ; if (tmp312) { tmp314 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; /* tmp313 = */ prerr_loc_error2_0 (tmp314) ; /* tmp315 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_arg_body_tr_ann"), ATSstrcst("ats_trans2_dyn2.dats")) ; tmp317 = atspre_lt_int_int (arg2, arg7) ; if (tmp317) { /* tmp316 = */ atspre_prerr_string (ATSstrcst(": linear function is given a nonlinear type.")) ; } else { /* empty */ } /* end of [if] */ tmp319 = atspre_gt_int_int (arg2, arg7) ; if (tmp319) { /* tmp318 = */ atspre_prerr_string (ATSstrcst(": nonlinear function is given a linear type.")) ; } else { /* empty */ } /* end of [if] */ /* tmp320 = */ atspre_prerr_newline () ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* ats_ptr_type tmp321 ; */ tmp321 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; tmp322 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_arg_tr (arg8, (&tmp321)) ; tmp324 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none (tmp321) ; if (tmp324) { /* empty */ } else { tmp326 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg8), atslab_p1at_loc) ; /* tmp325 = */ prerr_loc_error2_0 (tmp326) ; /* tmp327 = */ atspre_prerr_string (ATSstrcst(": the function argument cannot be ascribed refval types.")) ; /* tmp328 = */ atspre_prerr_newline () ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ /* ats_int_type tmp329 ; */ tmp329 = 0 ; tmp331 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp322), atslab_p2at_node) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp331)->tag != 10) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_20, tmp331, atslab_0) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_20, tmp331, atslab_1) ; tmp329 = tmp332 ; tmp330 = tmp333 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp334 = (ats_sum_ptr_type)0 ; tmp330 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp330, atslab_0, tmp322) ; ats_selptrset_mac(anairiats_sum_0, tmp330, atslab_1, tmp334) ; break ; } while (0) ; tmp336 = atspre_neq_int_int (arg4, tmp329) ; if (tmp336) { tmp338 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; /* tmp337 = */ prerr_loc_error2_0 (tmp338) ; /* tmp339 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_arg_body_tr_ann"), ATSstrcst("ats_trans2_dyn2.dats")) ; tmp341 = atspre_lt_int_int (arg4, tmp329) ; if (tmp341) { /* tmp340 = */ atspre_prerr_string (ATSstrcst(": fewer proof arguments are expected.")) ; } else { /* empty */ } /* end of [if] */ tmp343 = atspre_gt_int_int (arg4, tmp329) ; if (tmp343) { /* tmp342 = */ atspre_prerr_string (ATSstrcst(": more proof arguments are expected.")) ; } else { /* empty */ } /* end of [if] */ /* tmp344 = */ atspre_prerr_newline () ; /* tmp335 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp345 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg5) ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp330) ; tmp356 = atspre_ineq (tmp345, tmp346) ; if (tmp356) { tmp358 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; /* tmp357 = */ prerr_loc_error2_0 (tmp358) ; /* tmp359 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d1exp_arg_body_tr_ann"), ATSstrcst("ats_trans2_dyn2.dats")) ; tmp361 = atspre_ilt (tmp345, tmp346) ; if (tmp361) { /* tmp360 = */ atspre_prerr_string (ATSstrcst(": fewer arguments are expected.")) ; } else { /* empty */ } /* end of [if] */ tmp363 = atspre_igt (tmp345, tmp346) ; if (tmp363) { /* tmp362 = */ atspre_prerr_string (ATSstrcst(": more arguments are expected.")) ; } else { /* empty */ } /* end of [if] */ /* tmp364 = */ atspre_prerr_newline () ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { tmp355 = aux_30 (tmp330, arg5) ; } /* end of [if] */ /* tmp365 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp366 = ats_selsin_mac(tmp365, atslab_1) */ ; tmp368 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp322), atslab_p2at_svs) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2varlst_of_s2varlstord (tmp368) ; /* tmp369 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp367) ; tmp371 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp322), atslab_p2at_dvs) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp371) ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (tmp370) ; /* tmp373 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc () ; /* tmp374 = ats_selsin_mac(tmp373, atslab_1) */ ; /* ats_int_type tmp375 ; */ tmp375 = 0 ; tmp377 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg9), atslab_d1exp_node) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp377)->tag != 1) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp378 = atspre_iadd (tmp375, 1) ; tmp375 = tmp378 ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp377)->tag != 0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp379 = atspre_iadd (tmp375, 1) ; tmp375 = tmp379 ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: break ; } while (0) ; tmp381 = atspre_gt_int_int (tmp375, 0) ; if (tmp381) { tmp383 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_d1exp_loc) ; /* tmp382 = */ prerr_loc_error2_0 (tmp383) ; /* tmp384 = */ atspre_prerr_string (ATSstrcst(": the [funclo/effect] annonation is redundant.")) ; /* tmp385 = */ atspre_prerr_newline () ; /* tmp380 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp386 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg6) ; tmp387 = d1exp_tr_ann_28 (arg9, tmp386) ; /* tmp388 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec () ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () ; tmp390 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp387), atslab_d2exp_loc) ; tmp391 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff (tmp390, tmp387, arg3) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo (tmp390, tmp391, arg1) ; tmp304.atslab_0 = tmp355 ; tmp304.atslab_1 = tmp392 ; return (tmp304) ; } /* end of [d1exp_arg_body_tr_ann_29] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 21845(line=687, offs=9) -- 22189(line=696, offs=8) */ ATSstaticdec() ats_void_type aux_32 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; // ATSlocal_void (tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; __ats_lab_aux_32: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_61_0 ; } __ats_lab_58_1: tmp399 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp400 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp399)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp402 = ats_caselptrlab_mac(anairiats_sum_2, tmp399, atslab_0) ; /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var (tmp402) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (((ats_sum_ptr_type)tmp399)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_20, tmp399, atslab_1) ; /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_varlst (tmp403) ; break ; } while (0) ; arg0 = tmp400 ; goto __ats_lab_aux_32 ; // tail call break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: break ; } while (0) ; return /* (tmp398) */ ; } /* end of [aux_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 21624(line=682, offs=4) -- 22521(line=707, offs=4) */ ATSstaticdec() ats_void_type m1acdef_tr_31 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; ATSlocal (ats_bool_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; // ATSlocal_void (tmp411) ; ATSlocal (ats_bool_type, tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; __ats_lab_m1acdef_tr_31: tmp394 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_m1acdef_loc) ; tmp395 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_m1acdef_sym) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push () ; /* tmp397 = ats_selsin_mac(tmp396, atslab_1) */ ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst (arg1) ; /* tmp404 = */ aux_32 (tmp405) ; /* tmp406 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_inc () ; tmp408 = atspre_gt_int_int (arg0, 0) ; if (tmp408) { /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec (tmp394) ; } else { /* empty */ } /* end of [if] */ tmp410 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_m1acdef_def) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp410) ; tmp412 = atspre_gt_int_int (arg0, 0) ; if (tmp412) { /* tmp411 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc (tmp394) ; } else { /* empty */ } /* end of [if] */ /* tmp413 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_dec () ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop () ; /* tmp393 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_set_def (arg1, tmp409) ; return /* (tmp393) */ ; } /* end of [m1acdef_tr_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 22804(line=714, offs=12) -- 22867(line=714, offs=75) */ ATSstaticdec() ats_ptr_type f_36 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; __ats_lab_f_36: tmp419 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_loc) ; tmp420 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; tmp418 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp419, tmp420) ; return (tmp418) ; } /* end of [f_36] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 22752(line=713, offs=11) -- 23133(line=723, offs=10) */ ATSstaticdec() ats_ptr_type auxarg_35 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_int_type, tmp425) ; __ats_lab_auxarg_35: do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp421 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp422 = f_36 (tmp421) ; tmp417 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp417)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp417, atslab_0, tmp422) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp424 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp423, &f_36) ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp424) ; tmp417 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp417)->tag = 1 ; ats_selptrset_mac(anairiats_sum_20, tmp417, atslab_0, tmp425) ; ats_selptrset_mac(anairiats_sum_20, tmp417, atslab_1, tmp424) ; break ; } while (0) ; return (tmp417) ; } /* end of [auxarg_35] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 23144(line=724, offs=11) -- 23303(line=726, offs=10) */ ATSstaticdec() ats_ptr_type auxarglst_37 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; __ats_lab_auxarglst_37: do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp427 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp428 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp429 = auxarg_35 (tmp427) ; tmp430 = auxarglst_37 (tmp428) ; tmp426 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp426, atslab_0, tmp429) ; ats_selptrset_mac(anairiats_sum_0, tmp426, atslab_1, tmp430) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_65_1: tmp426 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp426) ; } /* end of [auxarglst_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 22649(line=711, offs=6) -- 23605(line=735, offs=6) */ ATSstaticdec() ats_ptr_type aux1_34 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; ATSlocal (ats_bool_type, tmp438) ; __ats_lab_aux1_34: tmp432 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m1acdef_arg) ; tmp431 = auxarglst_37 (tmp432) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; tmp435 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m1acdef_loc) ; tmp436 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m1acdef_sym) ; tmp434 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_make (tmp435, tmp436, env0, tmp431, tmp433) ; tmp438 = atspre_gt_int_int (env0, 1) ; if (tmp438) { /* tmp437 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def (tmp434) ; } else { /* empty */ } /* end of [if] */ tmp416 = tmp434 ; return (tmp416) ; } /* end of [aux1_34] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux1_34_closure_type ; ats_ptr_type aux1_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux1_34 (((aux1_34_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux1_34_closure_init (aux1_34_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux1_34_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux1_34_closure_make (ats_int_type env0) { aux1_34_closure_type *p_clo = ATS_MALLOC(sizeof(aux1_34_closure_type)) ; aux1_34_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 23629(line=736, offs=7) -- 24037(line=749, offs=6) */ ATSstaticdec() ats_void_type aux2_38 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_int_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_bool_type, tmp447) ; __ats_lab_aux2_38: do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp441 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp442 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp443 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp444 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind (tmp440) ; /* tmp445 = */ m1acdef_tr_31 (tmp444, tmp440, tmp442) ; tmp447 = atspre_lte_int_int (tmp444, 1) ; if (tmp447) { /* tmp446 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def (tmp440) ; } else { /* empty */ } /* end of [if] */ arg0 = tmp441 ; arg1 = tmp443 ; goto __ats_lab_aux2_38 ; // tail call break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: break ; } while (0) ; return /* (tmp439) */ ; } /* end of [aux2_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 22550(line=709, offs=5) -- 24128(line=753, offs=4) */ ATSstaticdec() ats_void_type m1acdeflst_tr_33 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_clo_ptr_type, tmp449) ; __ats_lab_m1acdeflst_tr_33: /* ats_clo_ptr_type tmp449 ; */ tmp449 = aux1_34_closure_make (arg0) ; tmp448 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (arg1, tmp449) ; ATS_FREE(tmp449) ; /* tmp415 = */ aux2_38 (tmp448, arg1) ; return /* (tmp415) */ ; } /* end of [m1acdeflst_tr_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 24292(line=762, offs=7) -- 24420(line=764, offs=6) */ ATSstaticdec() ats_bool_type aux1_40 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp471) ; tmp471 = aux1_40_0aux2_41 (0, arg0, arg1) ; return (tmp471) ; } /* end of [aux1_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 24447(line=766, offs=7) -- 25185(line=783, offs=6) */ ATSstaticdec() ats_bool_type aux2_41 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp472) ; tmp472 = aux1_40_0aux2_41 (1, arg0, arg1, arg2) ; return (tmp472) ; } /* end of [aux2_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 24292(line=762, offs=7) -- 25185(line=783, offs=6) */ ATSstaticdec() ats_bool_type aux1_40_0aux2_41 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_int_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_bool_type, tmp456) ; ATSlocal (ats_int_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_bool_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_int_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_bool_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_bool_type, tmp470) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp451 = va_arg(funarg, ats_ptr_type) ; tmp452 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_aux1_40 ; case 1: va_start(funarg, arg0) ; tmp453 = va_arg(funarg, ats_ptr_type) ; tmp454 = va_arg(funarg, ats_int_type) ; tmp455 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_aux2_41 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_aux1_40: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (tmp452 == (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp457 = ats_caselptrlab_mac(anairiats_sum_23, tmp452, atslab_0) ; tmp458 = ats_caselptrlab_mac(anairiats_sum_23, tmp452, atslab_1) ; tmp453 = tmp451 ; tmp454 = tmp457 ; tmp455 = tmp458 ; goto __ats_lab_aux2_41 ; // tail call break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: // if (tmp452 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_69_1: tmp456 = ats_true_bool ; break ; } while (0) ; return tmp456 ; __ats_lab_aux2_41: tmp460 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp453), atslab_d1exp_node) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp460)->tag != 29) { goto __ats_lab_73_0 ; } __ats_lab_70_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_16, tmp460, atslab_1) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_16, tmp460, atslab_2) ; tmp464 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp461), atslab_p1at_node) ; do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp464)->tag != 12) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp465 = ats_caselptrlab_mac(anairiats_sum_20, tmp464, atslab_1) ; tmp463 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp465) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: tmp463 = 1 ; break ; } while (0) ; tmp466 = atspre_eq_int_int (tmp454, tmp463) ; if (tmp466) { tmp451 = tmp462 ; tmp452 = tmp455 ; goto __ats_lab_aux1_40 ; // tail call } else { tmp459 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp460)->tag != 31) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp467 = ats_caselptrlab_mac(anairiats_sum_13, tmp460, atslab_2) ; tmp453 = tmp467 ; tmp454 = tmp454 ; tmp455 = tmp455 ; goto __ats_lab_aux2_41 ; // tail call break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp460)->tag != 32) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp468 = ats_caselptrlab_mac(anairiats_sum_13, tmp460, atslab_2) ; tmp453 = tmp468 ; tmp454 = tmp454 ; tmp455 = tmp455 ; goto __ats_lab_aux2_41 ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp460)->tag != 33) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp469 = ats_caselptrlab_mac(anairiats_sum_13, tmp460, atslab_2) ; tmp453 = tmp469 ; tmp454 = tmp454 ; tmp455 = tmp455 ; goto __ats_lab_aux2_41 ; // tail call break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: __ats_lab_76_1: tmp459 = ats_false_bool ; break ; } while (0) ; return tmp459 ; return (tmp470) ; } /* end of [aux1_40_0aux2_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 24224(line=759, offs=5) -- 25229(line=787, offs=4) */ ATSstaticdec() ats_bool_type d1exp_arity_check_39 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp450) ; __ats_lab_d1exp_arity_check_39: tmp450 = aux1_40 (arg0, arg1) ; return (tmp450) ; } /* end of [d1exp_arity_check_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 25364(line=793, offs=7) -- 25806(line=805, offs=6) */ ATSstaticdec() ats_ptr_type aux_44 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_bool_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; __ats_lab_aux_44: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_77_1: tmp475 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp476 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp475)->tag != 1) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp477 = ats_caselptrlab_mac(anairiats_sum_2, tmp475, atslab_0) ; tmp478 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_arilst (tmp477) ; tmp480 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, env0), atslab_i1mpdec_def) ; tmp479 = d1exp_arity_check_39 (tmp480, tmp478) ; if (tmp479) { tmp481 = aux_44 (env0, tmp476) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp474, atslab_0, tmp477) ; ats_selptrset_mac(anairiats_sum_0, tmp474, atslab_1, tmp481) ; } else { arg0 = tmp476 ; goto __ats_lab_aux_44 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: arg0 = tmp476 ; goto __ats_lab_aux_44 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp474) ; } /* end of [aux_44] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_44_closure_type ; ats_ptr_type aux_44_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_44 (((aux_44_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_44_closure_init (aux_44_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_44_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_44_closure_make (ats_ptr_type env0) { aux_44_closure_type *p_clo = ATS_MALLOC(sizeof(aux_44_closure_type)) ; aux_44_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 25285(line=791, offs=4) -- 26867(line=835, offs=4) */ ATSstaticdec() ats_ptr_type i1mpdec_tr_d2cst_select_43 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; // ATSlocal_void (tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; // ATSlocal_void (tmp492) ; // ATSlocal_void (tmp493) ; // ATSlocal_void (tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; // ATSlocal_void (tmp497) ; // ATSlocal_void (tmp498) ; // ATSlocal_void (tmp499) ; // ATSlocal_void (tmp500) ; // ATSlocal_void (tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; // ATSlocal_void (tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; // ATSlocal_void (tmp507) ; // ATSlocal_void (tmp508) ; // ATSlocal_void (tmp509) ; // ATSlocal_void (tmp510) ; // ATSlocal_void (tmp511) ; __ats_lab_i1mpdec_tr_d2cst_select_43: tmp482 = aux_44 (arg0, arg1) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (tmp482 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_81_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_0, tmp482, atslab_0) ; tmp484 = ats_caselptrlab_mac(anairiats_sum_0, tmp482, atslab_1) ; ATS_FREE(tmp482) ; do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (tmp484 != (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp473 = tmp483 ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: // if (tmp484 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_83_1: tmp485 = ats_caselptrlab_mac(anairiats_sum_0, tmp484, atslab_0) ; tmp486 = ats_caselptrlab_mac(anairiats_sum_0, tmp484, atslab_1) ; ATS_FREE(tmp484) ; tmp487 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1mpdec_qid) ; tmp488 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp487), atslab_impqi0de_qua) ; tmp489 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp487), atslab_impqi0de_sym) ; tmp491 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1mpdec_loc) ; /* tmp490 = */ prerr_loc_error2_0 (tmp491) ; /* tmp492 = */ atspre_prerr_string (ATSstrcst(": the dynamic constants [")) ; /* tmp493 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (tmp483) ; /* tmp494 = */ atspre_prerr_string (ATSstrcst("] and [")) ; /* tmp495 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (tmp485) ; /* tmp496 = */ atspre_prerr_string (ATSstrcst("] cannot be resolved for [")) ; /* tmp497 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (tmp488) ; /* tmp498 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp489) ; /* tmp499 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp500 = */ atspre_prerr_newline () ; /* tmp501 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (tmp486) ; /* tmp473 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (tmp482 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: tmp502 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1mpdec_qid) ; tmp503 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp502), atslab_impqi0de_qua) ; tmp504 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp502), atslab_impqi0de_sym) ; tmp506 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg0), atslab_i1mpdec_loc) ; /* tmp505 = */ prerr_loc_error2_0 (tmp506) ; /* tmp507 = */ atspre_prerr_string (ATSstrcst(": no dynamic constant can be found for [")) ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (tmp503) ; /* tmp509 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp504) ; /* tmp510 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp511 = */ atspre_prerr_newline () ; /* tmp473 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp473) ; } /* end of [i1mpdec_tr_d2cst_select_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 29016(line=895, offs=7) -- 30617(line=938, offs=6) */ ATSstaticdec() ats_ptr_type aux2_imp_46 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (anairiats_rec_12, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; // ATSlocal_void (tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (anairiats_rec_12, tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; // ATSlocal_void (tmp561) ; // ATSlocal_void (tmp562) ; // ATSlocal_void (tmp563) ; // ATSlocal_void (tmp564) ; // ATSlocal_void (tmp565) ; // ATSlocal_void (tmp566) ; // ATSlocal_void (tmp567) ; // ATSlocal_void (tmp568) ; // ATSlocal_void (tmp569) ; // ATSlocal_void (tmp570) ; // ATSlocal_void (tmp571) ; // ATSlocal_void (tmp572) ; __ats_lab_aux2_imp_46: do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_92_1: tmp545 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp546 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp547 = ats_caselptrlab_mac(anairiats_sum_26, arg2, atslab_0) ; tmp548 = ats_caselptrlab_mac(anairiats_sum_26, arg2, atslab_1) ; /* ats_ptr_type tmp549 ; */ tmp549 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; tmp551 = ats_select_mac(tmp547, atslab_0) ; tmp550 = s1arglst_bind_svarlst_24 (arg0, tmp545, tmp551, (&tmp549)) ; /* tmp552 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp550) ; tmp554 = ats_select_mac(tmp547, atslab_1) ; tmp553 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp549, tmp554) ; tmp555 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp549, arg3) ; tmp557.atslab_0 = tmp550 ; tmp557.atslab_1 = tmp553 ; tmp556 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ats_selptrset_mac(anairiats_sum_26, tmp556, atslab_0, tmp557) ; ats_selptrset_mac(anairiats_sum_26, tmp556, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp556 ; arg0 = arg0 ; arg1 = tmp546 ; arg2 = tmp548 ; arg3 = tmp555 ; arg4 = arg4 ; goto __ats_lab_aux2_imp_46 ; // tail call break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: /* tmp558 = */ prerr_loc_error2_0 (arg0) ; /* tmp559 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr: aux2_imp"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp560 = */ atspre_prerr_string (ATSstrcst(": the implementation for [")) ; /* tmp561 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (env0) ; /* tmp562 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (env1) ; /* tmp563 = */ atspre_prerr_string (ATSstrcst("] should be applied to fewer template arguments.")) ; /* tmp564 = */ atspre_prerr_newline () ; /* tmp544 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_95_1: do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: /* tmp566 = */ prerr_loc_error2_0 (arg0) ; /* tmp567 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr: aux2_imp"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp568 = */ atspre_prerr_string (ATSstrcst(": the implementation for [")) ; /* tmp569 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (env0) ; /* tmp570 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (env1) ; /* tmp571 = */ atspre_prerr_string (ATSstrcst("] should be applied to more template arguments.")) ; /* tmp572 = */ atspre_prerr_newline () ; /* tmp565 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: break ; } while (0) ; tmp544 = arg3 ; break ; } while (0) ; return (tmp544) ; } /* end of [aux2_imp_46] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux2_imp_46_closure_type ; ats_ptr_type aux2_imp_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { return aux2_imp_46 (((aux2_imp_46_closure_type*)cloptr)->closure_env_0, ((aux2_imp_46_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3, arg4) ; } /* end of function */ ATSinline() ats_void_type aux2_imp_46_closure_init (aux2_imp_46_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux2_imp_46_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux2_imp_46_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux2_imp_46_closure_type *p_clo = ATS_MALLOC(sizeof(aux2_imp_46_closure_type)) ; aux2_imp_46_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 30645(line=939, offs=7) -- 32298(line=983, offs=6) */ ATSstaticdec() ats_ptr_type aux2_tmp_47 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (anairiats_rec_12, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; // ATSlocal_void (tmp586) ; // ATSlocal_void (tmp587) ; // ATSlocal_void (tmp588) ; // ATSlocal_void (tmp589) ; // ATSlocal_void (tmp590) ; // ATSlocal_void (tmp591) ; // ATSlocal_void (tmp592) ; // ATSlocal_void (tmp593) ; // ATSlocal_void (tmp594) ; // ATSlocal_void (tmp595) ; // ATSlocal_void (tmp596) ; // ATSlocal_void (tmp597) ; // ATSlocal_void (tmp598) ; // ATSlocal_void (tmp599) ; // ATSlocal_void (tmp600) ; __ats_lab_aux2_tmp_47: do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_101_0 ; } __ats_lab_98_1: tmp574 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp575 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp576 = ats_caselptrlab_mac(anairiats_sum_26, arg2, atslab_0) ; tmp577 = ats_caselptrlab_mac(anairiats_sum_26, arg2, atslab_1) ; /* ats_ptr_type tmp578 ; */ tmp578 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; tmp580 = ats_select_mac(tmp576, atslab_0) ; tmp579 = s1explst_bind_svarlst_26 (arg0, tmp574, tmp580, (&tmp578)) ; tmp582 = ats_select_mac(tmp576, atslab_1) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp578, tmp582) ; tmp583 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp578, arg3) ; tmp584 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp584, atslab_0, tmp579) ; ats_selptrset_mac(anairiats_sum_0, tmp584, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp584 ; tmp585 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp585, atslab_0, tmp581) ; ats_selptrset_mac(anairiats_sum_0, tmp585, atslab_1, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp585 ; arg0 = arg0 ; arg1 = tmp575 ; arg2 = tmp577 ; arg3 = tmp583 ; arg4 = arg4 ; arg5 = arg5 ; goto __ats_lab_aux2_tmp_47 ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: /* tmp586 = */ prerr_loc_error2_0 (arg0) ; /* tmp587 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr: aux2_tmp"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp588 = */ atspre_prerr_string (ATSstrcst(": the implementation for [")) ; /* tmp589 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (env0) ; /* tmp590 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (env1) ; /* tmp591 = */ atspre_prerr_string (ATSstrcst("] should be applied to fewer template arguments.")) ; /* tmp592 = */ atspre_prerr_newline () ; /* tmp573 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_101_1: do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: /* tmp594 = */ prerr_loc_error2_0 (arg0) ; /* tmp595 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr: aux2_tmp"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp596 = */ atspre_prerr_string (ATSstrcst(": the implementation for [")) ; /* tmp597 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (env0) ; /* tmp598 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (env1) ; /* tmp599 = */ atspre_prerr_string (ATSstrcst("] should be applied to more template arguments.")) ; /* tmp600 = */ atspre_prerr_newline () ; /* tmp593 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: break ; } while (0) ; tmp573 = arg3 ; break ; } while (0) ; return (tmp573) ; } /* end of [aux2_tmp_47] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux2_tmp_47_closure_type ; ats_ptr_type aux2_tmp_47_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5) { return aux2_tmp_47 (((aux2_tmp_47_closure_type*)cloptr)->closure_env_0, ((aux2_tmp_47_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2, arg3, arg4, arg5) ; } /* end of function */ ATSinline() ats_void_type aux2_tmp_47_closure_init (aux2_tmp_47_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux2_tmp_47_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux2_tmp_47_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux2_tmp_47_closure_type *p_clo = ATS_MALLOC(sizeof(aux2_tmp_47_closure_type)) ; aux2_tmp_47_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 26908(line=837, offs=4) -- 34133(line=1034, offs=4) */ ATSstaticdec() ats_ptr_type i1mpdec_tr_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; // ATSlocal_void (tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; // ATSlocal_void (tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; // ATSlocal_void (tmp536) ; // ATSlocal_void (tmp537) ; // ATSlocal_void (tmp538) ; // ATSlocal_void (tmp539) ; // ATSlocal_void (tmp540) ; // ATSlocal_void (tmp541) ; // ATSlocal_void (tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; // ATSlocal_void (tmp604) ; // ATSlocal_void (tmp605) ; // ATSlocal_void (tmp606) ; // ATSlocal_void (tmp607) ; // ATSlocal_void (tmp608) ; // ATSlocal_void (tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; // ATSlocal_void (tmp613) ; // ATSlocal_void (tmp614) ; // ATSlocal_void (tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; ATSlocal (ats_int_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; // ATSlocal_void (tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; __ats_lab_i1mpdec_tr_45: tmp513 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_tmparg) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: if (tmp513 == (ats_sum_ptr_type)0) { goto __ats_lab_86_1 ; } __ats_lab_85_2: /* tmp515 = */ prerr_loc_error2_0 (arg0) ; /* tmp516 = */ atspre_prerr_string (ATSstrcst(": template implementation and instantiation may not be combined.")) ; /* tmp517 = */ atspre_prerr_newline () ; /* tmp514 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: __ats_lab_86_2: break ; } while (0) ; tmp518 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_qid) ; tmp519 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp518), atslab_impqi0de_qua) ; tmp520 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp518), atslab_impqi0de_sym) ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (tmp519, tmp520) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp522 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_87_1: tmp523 = ats_caselptrlab_mac(anairiats_sum_3, tmp522, atslab_0) ; ATS_FREE(tmp522) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp523)->tag != 1) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp524 = ats_caselptrlab_mac(anairiats_sum_2, tmp523, atslab_0) ; tmp521 = tmp524 ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp523)->tag != 5) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp525 = ats_caselptrlab_mac(anairiats_sum_2, tmp523, atslab_0) ; tmp521 = i1mpdec_tr_d2cst_select_43 (arg2, tmp525) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: __ats_lab_90_1: tmp527 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_loc) ; /* tmp526 = */ prerr_loc_error2_0 (tmp527) ; /* tmp528 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp529 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (tmp519) ; /* tmp531 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp520) ; /* tmp532 = */ atspre_prerr_string (ATSstrcst("] should refer to a dynamic constant but it does not.")) ; /* tmp533 = */ atspre_prerr_newline () ; /* tmp521 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (tmp522 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: tmp535 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_loc) ; /* tmp534 = */ prerr_loc_error2_0 (tmp535) ; /* tmp536 = */ atsopt_debug_prerrf (ATSstrcst(": %s: i1mpdec_tr"), ATSstrcst("ats_trans2_dyn2.dats")) ; /* tmp537 = */ atspre_prerr_string (ATSstrcst(": the dynamic identifier [")) ; /* tmp538 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (tmp519) ; /* tmp539 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp520) ; /* tmp540 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp541 = */ atspre_prerr_newline () ; /* tmp521 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp543 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp518), atslab_impqi0de_loc) ; /* tmp542 = */ dyncstimploc_posmark_3 (tmp543, tmp521) ; tmp601 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp518), atslab_impqi0de_loc) ; tmp602 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg (tmp521) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (tmp521) ; do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (tmp602 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_104_1: do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: if (tmp513 != (ats_sum_ptr_type)0) { goto __ats_lab_106_1 ; } __ats_lab_105_2: /* tmp605 = */ prerr_loc_error2_0 (arg0) ; /* tmp606 = */ atspre_prerr_string (ATSstrcst(": the dynamic constant [")) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (tmp521) ; /* tmp608 = */ atspre_prerr_string (ATSstrcst("] requires a template implementation")) ; /* tmp609 = */ atspre_prerr_newline () ; /* tmp604 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: __ats_lab_106_2: break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: __ats_lab_107_1: break ; } while (0) ; /* ats_ptr_type tmp610 ; */ tmp610 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp611 ; */ tmp611 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp612 ; */ tmp612 = (ats_sum_ptr_type)0 ; /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp614 = ats_selsin_mac(tmp613, atslab_1) */ ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp602 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: /* tmp615 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc () ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (tmp602 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: break ; } while (0) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp616 = aux2_imp_46 (tmp519, tmp520, tmp601, arg1, tmp602, tmp603, (&tmp610)) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: tmp616 = tmp603 ; break ; } while (0) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (tmp513 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp617 = aux2_tmp_47 (tmp519, tmp520, tmp601, tmp513, tmp602, tmp616, (&tmp611), (&tmp612)) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (tmp513 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: tmp617 = tmp616 ; break ; } while (0) ; tmp618 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse (tmp610) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get () ; /* tmp619 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev (tmp618, tmp620) ; tmp621 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp611) ; tmp622 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp612) ; tmp623 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp617) ; tmp625 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_def) ; tmp624 = d1exp_tr_ann_28 (tmp625, tmp623) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp602 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: /* tmp626 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec () ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (tmp602 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: break ; } while (0) ; /* tmp627 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp629 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp629, atslab_0, tmp624) ; /* tmp628 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_set_def (tmp521, tmp629) ; tmp630 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_i1mpdec_loc) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2mpdec_make (tmp630, tmp601, tmp521, tmp618, tmp621, tmp622, tmp624) ; return (tmp512) ; } /* end of [i1mpdec_tr_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 34182(line=1038, offs=4) -- 35729(line=1090, offs=4) */ ATSstaticdec() ats_ptr_type s1taload_tr_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ref_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_int_type, tmp633) ; // ATSlocal_void (tmp634) ; // ATSlocal_void (tmp635) ; ATSlocal (ats_int_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; // ATSlocal_void (tmp640) ; ATSlocal (ats_int_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; // ATSlocal_void (tmp643) ; // ATSlocal_void (tmp644) ; // ATSlocal_void (tmp645) ; // ATSlocal_void (tmp646) ; // ATSlocal_void (tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; // ATSlocal_void (tmp650) ; __ats_lab_s1taload_tr_48: tmp632 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (arg2) ; /* ats_int_type tmp633 ; */ tmp633 = 0 ; /* tmp634 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_push () ; /* tmp635 = ats_selsin_mac(tmp634, atslab_1) */ ; do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp636 = 1 ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp636 = 0 ; break ; } while (0) ; tmp637 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find (tmp632) ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (tmp637 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_3, tmp637, atslab_0) ; ATS_FREE(tmp637) ; tmp633 = 1 ; tmp638 = tmp639 ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (tmp637 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: /* tmp640 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_save () ; tmp641 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get () ; tmp642 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (arg3) ; /* tmp643 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set (tmp641) ; /* tmp644 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_namespace_add_topenv (tmp632) ; /* tmp645 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_restore () ; /* tmp646 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_add (tmp632, tmp642) ; tmp638 = tmp642 ; break ; } while (0) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp638 ; do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp648 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp649 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp649)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp649, atslab_0, arg2) ; /* tmp647 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (tmp648, tmp649) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: /* tmp647 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_add (tmp632) ; break ; } while (0) ; /* tmp650 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_pop () ; tmp631 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_staload (arg0, tmp636, arg2, tmp633, arg4, tmp638) ; return (tmp631) ; } /* end of [s1taload_tr_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 35806(line=1095, offs=21) -- 36611(line=1119, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; // ATSlocal_void (tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr: do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_122_1: tmp652 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp653 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp655 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, tmp652), atslab_d2ec_node) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp655)->tag != 3) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp656 = ats_caselptrlab_mac(anairiats_sum_2, tmp655, atslab_0) ; /* tmp654 = */ symintr_tr_4 (tmp656) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp655)->tag != 10) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp657 = ats_caselptrlab_mac(anairiats_sum_28, tmp655, atslab_0) ; tmp658 = ats_caselptrlab_mac(anairiats_sum_28, tmp655, atslab_1) ; /* tmp654 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_def_tr (tmp657, tmp658) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp655)->tag != 2) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp659 = ats_caselptrlab_mac(anairiats_sum_2, tmp655, atslab_0) ; /* tmp654 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr (tmp659) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: break ; } while (0) ; arg0 = tmp653 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr ; // tail call break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: break ; } while (0) ; return /* (tmp651) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 36684(line=1125, offs=9) -- 42525(line=1284, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1ec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_int_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; // ATSlocal_void (tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; // ATSlocal_void (tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; // ATSlocal_void (tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; // ATSlocal_void (tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; // ATSlocal_void (tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; // ATSlocal_void (tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; // ATSlocal_void (tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; // ATSlocal_void (tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; // ATSlocal_void (tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; // ATSlocal_void (tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; // ATSlocal_void (tmp711) ; // ATSlocal_void (tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; // ATSlocal_void (tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; // ATSlocal_void (tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_int_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; // ATSlocal_void (tmp757) ; // ATSlocal_void (tmp758) ; // ATSlocal_void (tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; // ATSlocal_void (tmp761) ; ATSlocal (ats_int_type, tmp762) ; ATSlocal (ats_int_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; // ATSlocal_void (tmp765) ; // ATSlocal_void (tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_int_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; // ATSlocal_void (tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; ATSlocal (ats_ptr_type, tmp783) ; // ATSlocal_void (tmp784) ; // ATSlocal_void (tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; // ATSlocal_void (tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_int_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; // ATSlocal_void (tmp798) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1ec_tr: tmp661 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_node) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)tmp661)->tag != 0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp662 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp662) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp661)->tag != 1) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp663 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp664 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp665 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp663) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list (tmp664, tmp665) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp661)->tag != 2) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp666 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pause_get () ; tmp668 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp666) ; /* tmp669 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_resume_set (tmp667) ; tmp670 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_include (tmp670, tmp668) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp661)->tag != 3) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp671 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; /* tmp672 = */ symintr_tr_4 (tmp671) ; tmp673 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symintr (tmp673, tmp671) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp661)->tag != 4) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp674 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; /* tmp675 = */ symelim_tr_6 (tmp674) ; tmp676 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_symelim (tmp676, tmp674) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp661)->tag != 5) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp677 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp678 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp680 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp680)->tag = 3 ; ats_selptrset_mac(anairiats_sum_2, tmp680, atslab_0, tmp678) ; /* tmp679 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (tmp677, tmp680) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp682)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp682, atslab_0, tmp678) ; /* tmp681 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp677, tmp682) ; tmp683 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp683) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp661)->tag != 6) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp684 = ats_caselptrlab_mac(anairiats_sum_20, tmp661, atslab_1) ; /* tmp685 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atsrtdeclst_tr (tmp684) ; tmp686 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp686) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp661)->tag != 7) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp687 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; /* tmp688 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr (tmp687) ; tmp689 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp689) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp661)->tag != 8) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp690 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp691 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; /* tmp692 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1taconlst_tr (tmp690, tmp691) ; tmp693 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp693) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp661)->tag != 9) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp694 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; /* tmp695 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr (tmp694) ; tmp696 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp696) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp661)->tag != 10) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp697 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp698 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tavarlst_tr (tmp697) ; tmp699 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_stavars (tmp699, tmp698) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp661)->tag != 11) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp700 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp701 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp703 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr (tmp700) ; /* tmp702 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdeflst_tr (tmp703, tmp701) ; tmp704 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp704) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp661)->tag != 12) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp705 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp706 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp707 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1aspdec_tr (tmp705) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_saspdec (tmp706, tmp707) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)tmp661)->tag != 13) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp708 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_0) ; tmp709 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_1) ; tmp710 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_2) ; /* tmp711 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp712 = ats_selsin_mac(tmp711, atslab_1) */ ; tmp713 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (tmp709) ; tmp714 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1cstdeclst_tr (tmp708, tmp713, tmp710) ; /* tmp715 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp716 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dcstdec (tmp716, tmp708, tmp714) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp661)->tag != 14) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp717 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_0) ; tmp718 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_1) ; tmp719 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_2) ; tmp720 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atdeclst_tr (tmp717, tmp718, tmp719) ; tmp721 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_datdec (tmp721, tmp717, tmp720) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp661)->tag != 15) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp722 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__e1xndeclst_tr (tmp722) ; tmp724 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_exndec (tmp724, tmp723) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp661)->tag != 16) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp725 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp726 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; /* tmp727 = */ c1lassdec_tr_8 (tmp725, tmp726) ; tmp728 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp728) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp661)->tag != 17) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp729 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp730 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp731 = overload_tr_10 (tmp729, tmp730) ; tmp732 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_overload (tmp732, tmp729, tmp731) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp661)->tag != 18) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp733 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp734 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp735 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype (tmp734) ; tmp736 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extype (tmp736, tmp733, tmp735) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: if (((ats_sum_ptr_type)tmp661)->tag != 19) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp737 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp738 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp739 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp740 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1exp_tr (tmp738) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extval (tmp739, tmp737, tmp740) ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: if (((ats_sum_ptr_type)tmp661)->tag != 20) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp741 = ats_caselptrlab_mac(anairiats_sum_20, tmp661, atslab_0) ; tmp742 = ats_caselptrlab_mac(anairiats_sum_20, tmp661, atslab_1) ; tmp743 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_extcode (tmp743, tmp741, tmp742) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)tmp661)->tag != 21) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp744 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp745 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp746 = v1aldeclst_tr_13 (ats_false_bool, tmp745) ; tmp747 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs (tmp747, tmp744, tmp746) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)tmp661)->tag != 22) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp748 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp749 = v1aldeclst_tr_13 (ats_false_bool, tmp748) ; tmp750 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_par (tmp750, tmp749) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp661)->tag != 23) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp751 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp752 = v1aldeclst_tr_13 (ats_true_bool, tmp751) ; tmp753 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec (tmp753, tmp752) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp661)->tag != 24) { goto __ats_lab_157_0 ; } __ats_lab_152_1: tmp754 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_0) ; tmp755 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_1) ; tmp756 = ats_caselptrlab_mac(anairiats_sum_13, tmp661, atslab_2) ; /* tmp757 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp758 = ats_selsin_mac(tmp757, atslab_1) */ ; do { /* branch: __ats_lab_153 */ __ats_lab_153_0: if (tmp755 == (ats_sum_ptr_type)0) { goto __ats_lab_154_0 ; } __ats_lab_153_1: /* tmp759 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc () ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: // if (tmp755 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_154_1: break ; } while (0) ; tmp760 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (tmp755) ; tmp762 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get () ; /* tmp761 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev (tmp760, tmp762) ; tmp763 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp764 = f1undeclst_tr_17 (tmp754, tmp763, tmp760, tmp756) ; /* tmp765 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (tmp755 == (ats_sum_ptr_type)0) { goto __ats_lab_156_0 ; } __ats_lab_155_1: /* tmp766 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec () ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: // if (tmp755 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_156_1: break ; } while (0) ; tmp767 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_fundecs (tmp767, tmp760, tmp754, tmp764) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp661)->tag != 25) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp768 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp769 = v1ardeclst_tr_21 (tmp768) ; tmp770 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_vardecs (tmp770, tmp769) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp661)->tag != 26) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp771 = ats_caselptrlab_mac(anairiats_sum_20, tmp661, atslab_0) ; tmp772 = ats_caselptrlab_mac(anairiats_sum_20, tmp661, atslab_1) ; /* tmp773 = */ m1acdeflst_tr_33 (tmp771, tmp772) ; tmp774 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (tmp774) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp661)->tag != 27) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp775 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp776 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; tmp777 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp778 = i1mpdec_tr_45 (tmp777, tmp775, tmp776) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_impdec (tmp777, tmp778) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp661)->tag != 28) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp779 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_0) ; tmp780 = ats_caselptrlab_mac(anairiats_sum_28, tmp661, atslab_1) ; /* tmp781 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp782 = ats_selsin_mac(tmp781, atslab_1) */ ; tmp783 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp779) ; /* tmp784 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () ; /* tmp785 = ats_selsin_mac(tmp784, atslab_1) */ ; tmp786 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp780) ; /* tmp787 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_localjoin () ; tmp788 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_local (tmp788, tmp783, tmp786) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp661)->tag != 29) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp789 = ats_caselptrlab_mac(anairiats_sum_2, tmp661, atslab_0) ; tmp790 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_dynload (tmp790, tmp789) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: // if (((ats_sum_ptr_type)tmp661)->tag != 30) { ats_deadcode_failure_handle () ; } __ats_lab_162_1: tmp791 = ats_caselptrlab_mac(anairiats_sum_30, tmp661, atslab_0) ; tmp792 = ats_caselptrlab_mac(anairiats_sum_30, tmp661, atslab_1) ; tmp793 = ats_caselptrlab_mac(anairiats_sum_30, tmp661, atslab_2) ; tmp794 = ats_caselptrlab_mac(anairiats_sum_30, tmp661, atslab_3) ; /* ats_ptr_type tmp795 ; */ tmp795 = (ats_sum_ptr_type)0 ; tmp797 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_d1ec_loc) ; tmp796 = s1taload_tr_48 (tmp797, tmp791, tmp792, tmp794, tmp793, (&tmp795)) ; do { /* branch: __ats_lab_163 */ __ats_lab_163_0: if (tmp791 != (ats_sum_ptr_type)0) { goto __ats_lab_164_0 ; } __ats_lab_163_1: /* tmp798 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__overload_d2eclst_tr (tmp795) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: // if (tmp791 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_164_1: break ; } while (0) ; tmp660 = tmp796 ; break ; } while (0) ; return (tmp660) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1ec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_dyn2.dats: 42635(line=1291, offs=12) -- 42677(line=1291, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp799) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr: tmp799 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1ec_tr) ; return (tmp799) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_dyn2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_string_dats.c0000664000175000017500000002147212223166160023317 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ ATSinline() ats_ptr_type atsopt_stringlst_concat_string_alloc (const ats_size_type n) { char *p ; p = ATS_MALLOC(n+1); p[n] = '\000'; return p ; } // end of [atsopt_stringlst_string_alloc] /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_size_type, atspre_add_size_size) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, atspre_strbuf_set_char_at) (ats_ref_type, ats_size_type, ats_char_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atsopt_stringlst_concat_string_alloc) (ats_size_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_size_type aux_1 (ats_ptr_type arg0, ats_size_type arg1) ; static ats_size_type loop1_2 (ats_ref_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ptr_type arg3, ats_size_type arg4) ; static ats_void_type loop2_3 (ats_ref_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ptr_type arg3) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/prelude_dats_string.dats: 1991(line=61, offs=9) -- 2164(line=65, offs=25) */ ATSstaticdec() ats_size_type aux_1 (ats_ptr_type arg0, ats_size_type arg1) { /* local vardec */ ATSlocal (ats_size_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_size_type, tmp4) ; ATSlocal (ats_size_type, tmp5) ; __ats_lab_aux_1: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp5 = atspre_string_length (tmp2) ; tmp4 = atspre_add_size_size (arg1, tmp5) ; arg0 = tmp3 ; arg1 = tmp4 ; goto __ats_lab_aux_1 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp1 = arg1 ; break ; } while (0) ; return (tmp1) ; } /* end of [aux_1] */ /* // /home/hwxi/research/Anairiats/src/prelude_dats_string.dats: 2244(line=69, offs=7) -- 2621(line=78, offs=6) */ ATSstaticdec() ats_size_type loop1_2 (ats_ref_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ptr_type arg3, ats_size_type arg4) { /* local vardec */ ATSlocal (ats_size_type, tmp8) ; ATSlocal (ats_bool_type, tmp9) ; ATSlocal (ats_char_type, tmp10) ; ATSlocal (ats_bool_type, tmp11) ; // ATSlocal_void (tmp12) ; ATSlocal (ats_size_type, tmp13) ; ATSlocal (ats_size_type, tmp14) ; __ats_lab_loop1_2: tmp9 = atspre_string_is_atend (arg3, arg4) ; if (tmp9) { tmp8 = arg2 ; } else { tmp10 = atspre_string_get_char_at (arg3, arg4) ; tmp11 = atspre_lt_size1_size1 (arg2, arg1) ; if (tmp11) { /* tmp12 = */ atspre_strbuf_set_char_at (arg0, arg2, tmp10) ; tmp13 = atspre_add_size1_int1 (arg2, 1) ; tmp14 = atspre_add_size1_int1 (arg4, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp13 ; arg3 = arg3 ; arg4 = tmp14 ; goto __ats_lab_loop1_2 ; // tail call } else { tmp8 = arg2 ; } /* end of [if] */ } /* end of [if] */ return (tmp8) ; } /* end of [loop1_2] */ /* // /home/hwxi/research/Anairiats/src/prelude_dats_string.dats: 2646(line=79, offs=7) -- 3019(line=89, offs=6) */ ATSstaticdec() ats_void_type loop2_3 (ats_ref_type arg0, ats_size_type arg1, ats_size_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_size_type, tmp18) ; __ats_lab_loop2_3: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_0) ; tmp17 = ats_caselptrlab_mac(anairiats_sum_0, arg3, atslab_1) ; tmp18 = loop1_2 (arg0, arg1, arg2, ats_castfn_mac(ats_ptr_type, tmp16), 0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp18 ; arg3 = tmp17 ; goto __ats_lab_loop2_3 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp15) */ ; } /* end of [loop2_3] */ /* // /home/hwxi/research/Anairiats/src/prelude_dats_string.dats: 1927(line=59, offs=18) -- 3372(line=99, offs=4) */ ATSglobaldec() ats_ptr_type atspre_stringlst_concat (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_size_type, tmp6) ; ATSlocal (ats_size_type, tmp7) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_atspre_stringlst_concat: tmp7 = atspre_size1_of_int1 (0) ; tmp6 = aux_1 (arg0, tmp7) ; tmp19 = atsopt_stringlst_concat_string_alloc (ats_castfn_mac(ats_size_type, tmp6)) ; tmp20 = ats_selsin_mac(tmp19, atslab_2) ; /* tmp21 = */ loop2_3 (tmp20, ats_castfn_mac(ats_size_type, tmp6), 0, arg0) ; tmp22 = tmp20 ; tmp0 = ats_castfn_mac(ats_ptr_type, tmp22) ; return (tmp0) ; } /* end of [atspre_stringlst_concat] */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_string_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ // // a commonly used simple hash function // ats_ulint_type atspre_string_hash_33 (ats_ptr_type s0) { unsigned long int hash_val ; unsigned char *s; int c; hash_val = 31415926UL ; // randomly chosen s = (unsigned char*)s0 ; while (1) { c = *s ; if (!c) return hash_val ; hash_val = ((hash_val << 5) + hash_val) + c ; s += 1 ; } } /* end of [atspre_string_hash] */ ats_ptr_type atspre_string_make_substring ( ats_ptr_type src0 , ats_size_type st, ats_size_type ln ) { char *des, *src ; des = ATS_MALLOC(ln+1) ; src = ((char*)src0) + st ; memcpy(des, src, ln) ; des[ln] = '\000' ; return des ; } /* atspre_string_make_substring */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_string_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_lexer_lats_dats.c0000664000175000017500000123213112223166160022264 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* ** HX-2011-01-26: ** extern YYSTYPE yylval ; // generated by [bison] */ typedef void YYSTYPE ; #define YYSTYPE_IS_DECLARED 1 #include "ats_grammar_yats.h" /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTcons_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_char_type, atspre_char_of_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_prerr_char) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isdigit) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isupper) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_asl_int_int1) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_sub_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_make_substring) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_clo_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make) (ats_int_type) ; ATSextern_fun(ats_clo_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make) (ats_int_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, lexing_prerr_position) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, lexing_lexbuf_get) () ; ATSextern_fun(ats_void_type, lexing_lexbuf_set) (ats_ptr_type) ; ATSextern_fun(ats_int_type, lexing_engine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_char_type, lexeme_get_lexbuf) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_char_type, lexeme_get) (ats_int_type) ; ATSextern_fun(ats_ptr_type, lexeme_string) () ; ATSextern_fun(ats_ptr_type, lexing_fstpos_get) () ; ATSextern_fun(ats_ptr_type, lexing_lstpos_get) () ; ATSextern_fun(ats_void_type, lexing_curpos_prerr) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, string_make_charlst_rev_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get) () ; ATSextern_fun(ats_void_type, atsopt_filename_prerr) () ; ATSextern_fun(ats_ptr_type, ats_location_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_beg) (ats_lint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_end) (ats_lint_type) ; ATSextern_fun(ats_ptr_type, c0har_make) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, e0xtcode_make) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, f0loat_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, f0loatsp_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0nt_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0ntsp_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0tring_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, t0kn_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0de_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, atsopt_lexer_token_get) () ; ATSextern_fun(ats_bool_type, atsopt_token_is_valid) (ats_int_type) ; ATSextern_fun(ats_void_type, ats_lexer_lats_initialize) () ; ATSextern_fun(ats_int_type, atsopt_keyword_search) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__CHAR) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_LINE) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, yylval_char_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_extcode_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_float_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_floatsp_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_ide_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_int_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_intsp_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_string_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, yylval_string_set) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ats_lexer_literal_int_check) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, ats_lexer_literal_int_check) (ats_ptr_type, ats_ref_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTcons_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_none) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_i0de) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0rtid) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_si0de) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_di0de) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0exp) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0exp) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_sta) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_dyn) ; /* internal function declarations */ static ats_void_type poslst_free_0 (ats_ptr_type arg0) ; static ats_int_type MAIN_lexing_error_1 () ; static ats_int_type CHAR_lexing_error_2 (ats_ptr_type arg0) ; static ats_int_type CHAR0_3 () ; static ats_void_type COMMENT_lexing_error_4 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type COMMENT0_5 () ; static ats_void_type COMMENT_CLIKE_lexing_error_6 (ats_ptr_type arg0) ; static ats_void_type COMMENT0_CLIKE_7 () ; static ats_void_type COMMENT_LINE_lexing_error_8 () ; static ats_void_type COMMENT_REST_lexing_error_9 () ; static ats_int_type STRING_lexing_error_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING0_11 () ; static ats_int_type EXTCODE_lexing_error_12 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_int_type EXTCODE0_13 (ats_int_type arg0) ; static ats_void_type process_token_14 () ; static ats_void_type process_keyword_15 () ; static ats_void_type process_comment_open_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type process_comment_close_17 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type process_comment_clike_open_18 (ats_ptr_type arg0) ; static ats_void_type process_comment_clike_close_19 (ats_ptr_type arg0) ; static ats_void_type process_comment_line_open_20 () ; static ats_void_type process_comment_line_close_21 () ; static ats_void_type process_comment_rest_open_22 () ; static ats_void_type process_comment_rest_close_23 () ; static ats_ptr_type location_get_24 () ; static ats_ptr_type location_get_pos_25 (ats_ptr_type arg0) ; static ats_int_type tokenize_identifier_alp_26 () ; static ats_int_type tokenize_identifier_sym_27 () ; static ats_ptr_type prefix_identifier1_28 (ats_ptr_type arg0) ; static ats_int_type tokenize_identifier_arr_29 () ; static ats_int_type tokenize_identifier_tmp_30 () ; static ats_int_type tokenize_identifier_ext_31 () ; static ats_int_type tokenize_identifier_dlr_32 () ; static ats_int_type tokenize_identifier_srp_33 () ; static ats_void_type process_char_34 (ats_ptr_type arg0) ; static ats_char_type char_for_escaped_35 (ats_char_type arg0) ; static ats_void_type process_char_escaped_36 (ats_ptr_type arg0) ; static ats_char_type char_for_oct_code_1_37 (ats_int_type arg0) ; static ats_void_type process_char_oct_1_38 (ats_ptr_type arg0) ; static ats_char_type char_for_oct_code_2_39 (ats_int_type arg0) ; static ats_void_type process_char_oct_2_40 (ats_ptr_type arg0) ; static ats_char_type char_for_oct_code_3_41 (ats_int_type arg0) ; static ats_void_type process_char_oct_3_42 (ats_ptr_type arg0) ; static ats_int_type int_of_xdigit_43 (ats_char_type arg0) ; static ats_char_type char_for_hex_code_1_44 (ats_int_type arg0) ; static ats_void_type process_char_hex_1_45 (ats_ptr_type arg0) ; static ats_char_type char_for_hex_code_2_46 (ats_int_type arg0) ; static ats_void_type process_char_hex_2_47 (ats_ptr_type arg0) ; static ats_void_type process_literal_float_48 () ; static ats_void_type process_literal_floatsp_49 () ; static ats_void_type process_literal_int_50 () ; static ats_void_type process_literal_intsp_51 () ; static ats_int_type STRING_char_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_escaped_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_oct_1_54 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_oct_2_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_oct_3_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_hex_1_57 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type STRING_char_hex_2_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type process_literal_string_59 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type EXTCODE_char_60 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_void_type process_literal_extcode_61 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_varet_type process_illegal_token_62 () ; static ats_varet_type process_illegal_char_63 (ats_ptr_type arg0) ; static ats_varet_type process_unclosed_comment_64 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_varet_type process_unclosed_comment_clike_65 (ats_ptr_type arg0) ; static ats_varet_type process_unclosed_string_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_varet_type process_unclosed_extcode_67 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; /* partial value template declarations */ /* static temporary variable declarations */ // ATSstatic_void (statmp0) ; ATSstatic (ats_ptr_type, statmp351) ; ATSstatic (ats_clo_ptr_type, statmp352) ; ATSstatic (ats_ptr_type, statmp353) ; ATSstatic (ats_clo_ptr_type, statmp354) ; ATSstatic (ats_clo_ptr_type, statmp355) ; ATSstatic (ats_ptr_type, statmp424) ; ATSstatic (ats_clo_ptr_type, statmp425) ; ATSstatic (ats_ptr_type, statmp426) ; ATSstatic (ats_clo_ptr_type, statmp427) ; ATSstatic (ats_clo_ptr_type, statmp428) ; ATSstatic (ats_ptr_type, statmp431) ; ATSstatic (ats_clo_ptr_type, statmp432) ; ATSstatic (ats_ptr_type, statmp433) ; ATSstatic (ats_clo_ptr_type, statmp434) ; ATSstatic (ats_clo_ptr_type, statmp435) ; ATSstatic (ats_ptr_type, statmp438) ; ATSstatic (ats_clo_ptr_type, statmp439) ; ATSstatic (ats_ptr_type, statmp440) ; ATSstatic (ats_clo_ptr_type, statmp441) ; ATSstatic (ats_clo_ptr_type, statmp442) ; ATSstatic (ats_ptr_type, statmp445) ; ATSstatic (ats_clo_ptr_type, statmp446) ; ATSstatic (ats_ptr_type, statmp447) ; ATSstatic (ats_clo_ptr_type, statmp448) ; ATSstatic (ats_clo_ptr_type, statmp449) ; ATSstatic (ats_ptr_type, statmp452) ; ATSstatic (ats_clo_ptr_type, statmp453) ; ATSstatic (ats_ptr_type, statmp454) ; ATSstatic (ats_clo_ptr_type, statmp455) ; ATSstatic (ats_clo_ptr_type, statmp456) ; ATSstatic (ats_ptr_type, statmp466) ; ATSstatic (ats_clo_ptr_type, statmp467) ; ATSstatic (ats_ptr_type, statmp468) ; ATSstatic (ats_clo_ptr_type, statmp469) ; ATSstatic (ats_clo_ptr_type, statmp470) ; ATSstatic (ats_ptr_type, statmp474) ; ATSstatic (ats_clo_ptr_type, statmp475) ; ATSstatic (ats_ptr_type, statmp476) ; ATSstatic (ats_clo_ptr_type, statmp477) ; ATSstatic (ats_clo_ptr_type, statmp478) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1011(line=52, offs=5) -- 1119(line=53, offs=64) */ ATSstaticdec() ats_void_type poslst_free_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_poslst_free_0: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp2 ; goto __ats_lab_poslst_free_0 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp1) */ ; } /* end of [poslst_free_0] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1300(line=63, offs=4) -- 1347(line=63, offs=51) */ ATSstaticdec() ats_int_type MAIN_lexing_error_1 () { /* local vardec */ ATSlocal (ats_int_type, tmp3) ; __ats_lab_MAIN_lexing_error_1: /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp3) ; } /* end of [MAIN_lexing_error_1] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1403(line=69, offs=4) -- 1468(line=69, offs=69) */ ATSstaticdec() ats_int_type CHAR_lexing_error_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp4) ; __ats_lab_CHAR_lexing_error_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp4) ; } /* end of [CHAR_lexing_error_2] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1472(line=70, offs=4) -- 1519(line=70, offs=51) */ ATSstaticdec() ats_int_type CHAR0_3 () { /* local vardec */ ATSlocal (ats_int_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_CHAR0_3: tmp6 = lexing_fstpos_get () ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__CHAR (tmp6) ; return (tmp5) ; } /* end of [CHAR0_3] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1599(line=76, offs=4) -- 1712(line=78, offs=55) */ ATSstaticdec() ats_void_type COMMENT_lexing_error_4 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp8) ; __ats_lab_COMMENT_lexing_error_4: /* tmp8 = */ poslst_free_0 (arg1) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return /* (tmp7) */ ; } /* end of [COMMENT_lexing_error_4] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 1750(line=81, offs=4) -- 1939(line=87, offs=4) */ ATSstaticdec() ats_void_type COMMENT0_5 () { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_lint_type, tmp11) ; // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_COMMENT0_5: tmp10 = lexing_fstpos_get () ; tmp11 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp10) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg (tmp11) ; tmp13 = (ats_sum_ptr_type)0 ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT (tmp10, tmp13) ; return /* (tmp9) */ ; } /* end of [COMMENT0_5] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2034(line=93, offs=4) -- 2102(line=94, offs=42) */ ATSstaticdec() ats_void_type COMMENT_CLIKE_lexing_error_6 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp14) ; __ats_lab_COMMENT_CLIKE_lexing_error_6: /* tmp14 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return /* (tmp14) */ ; } /* end of [COMMENT_CLIKE_lexing_error_6] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2146(line=97, offs=4) -- 2333(line=103, offs=4) */ ATSstaticdec() ats_void_type COMMENT0_CLIKE_7 () { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_lint_type, tmp17) ; // ATSlocal_void (tmp18) ; __ats_lab_COMMENT0_CLIKE_7: tmp16 = lexing_fstpos_get () ; tmp17 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp16) ; /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg (tmp17) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE (tmp16) ; return /* (tmp15) */ ; } /* end of [COMMENT0_CLIKE_7] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2419(line=108, offs=4) -- 2471(line=108, offs=56) */ ATSstaticdec() ats_void_type COMMENT_LINE_lexing_error_8 () { /* local vardec */ // ATSlocal_void (tmp19) ; __ats_lab_COMMENT_LINE_lexing_error_8: /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return /* (tmp19) */ ; } /* end of [COMMENT_LINE_lexing_error_8] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2509(line=111, offs=4) -- 2561(line=111, offs=56) */ ATSstaticdec() ats_void_type COMMENT_REST_lexing_error_9 () { /* local vardec */ // ATSlocal_void (tmp20) ; __ats_lab_COMMENT_REST_lexing_error_9: /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return /* (tmp20) */ ; } /* end of [COMMENT_REST_lexing_error_9] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2678(line=118, offs=4) -- 2812(line=120, offs=41) */ ATSstaticdec() ats_int_type STRING_lexing_error_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp21) ; // ATSlocal_void (tmp22) ; __ats_lab_STRING_lexing_error_10: /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free (arg1) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp21) ; } /* end of [STRING_lexing_error_10] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 2849(line=123, offs=4) -- 2924(line=124, offs=54) */ ATSstaticdec() ats_int_type STRING0_11 () { /* local vardec */ ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_STRING0_11: tmp24 = lexing_fstpos_get () ; tmp25 = (ats_sum_ptr_type)0 ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (tmp24, tmp25, 0) ; return (tmp23) ; } /* end of [STRING0_11] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 3070(line=132, offs=4) -- 3213(line=134, offs=41) */ ATSstaticdec() ats_int_type EXTCODE_lexing_error_12 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_EXTCODE_lexing_error_12: /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free (arg2) ; /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp26) ; } /* end of [EXTCODE_lexing_error_12] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 3251(line=137, offs=4) -- 3337(line=138, offs=58) */ ATSstaticdec() ats_int_type EXTCODE0_13 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_EXTCODE0_13: tmp29 = lexing_fstpos_get () ; tmp30 = (ats_sum_ptr_type)0 ; tmp28 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE (tmp29, arg0, tmp30, 0) ; return (tmp28) ; } /* end of [EXTCODE0_13] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 14450(line=419, offs=4) -- 14776(line=429, offs=4) */ ATSstaticdec() ats_void_type process_token_14 () { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_lint_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_lint_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_process_token_14: tmp32 = lexing_fstpos_get () ; tmp33 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp32) ; tmp34 = lexing_lstpos_get () ; tmp35 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp34) ; tmp37 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp36 = ats_location_make (tmp37, tmp32, tmp34) ; tmp38 = t0kn_make (tmp36) ; /* tmp31 = */ yylval_string_set (tmp38) ; return /* (tmp31) */ ; } /* end of [process_token_14] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 14807(line=431, offs=4) -- 15414(line=450, offs=4) */ ATSstaticdec() ats_void_type process_keyword_15 () { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_lint_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_lint_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_process_keyword_15: tmp40 = lexing_fstpos_get () ; tmp41 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp40) ; tmp42 = lexing_lstpos_get () ; tmp43 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp42) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp44 = ats_location_make (tmp45, tmp40, tmp42) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_beg (tmp41) ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_keyword_end (tmp43) ; tmp48 = t0kn_make (tmp44) ; /* tmp39 = */ yylval_string_set (tmp48) ; return /* (tmp39) */ ; } /* end of [process_keyword_15] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 15468(line=454, offs=4) -- 15616(line=460, offs=4) */ ATSstaticdec() ats_void_type process_comment_open_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_process_comment_open_16: tmp50 = lexing_fstpos_get () ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp51, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp51, atslab_1, arg1) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT (tmp50, tmp51) ; return /* (tmp49) */ ; } /* end of [process_comment_open_16] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 15623(line=462, offs=4) -- 15978(line=474, offs=4) */ ATSstaticdec() ats_void_type process_comment_close_17 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_lint_type, tmp56) ; __ats_lab_process_comment_close_17: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp54 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; ATS_FREE(arg1) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT (tmp53, tmp54) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp55 = lexing_lstpos_get () ; tmp56 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp55) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end (tmp56) ; break ; } while (0) ; return /* (tmp52) */ ; } /* end of [process_comment_close_17] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 16038(line=478, offs=4) -- 16467(line=492, offs=4) */ ATSstaticdec() ats_void_type process_comment_clike_open_18 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; // ATSlocal_void (tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_process_comment_clike_open_18: tmp58 = lexing_fstpos_get () ; /* tmp59 = */ atsopt_filename_prerr () ; /* tmp60 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp61 = */ atspre_prerr_string (ATSstrcst(": the comment starting at [")) ; /* tmp62 = */ lexing_prerr_position (tmp58) ; /* tmp63 = */ atspre_prerr_string (ATSstrcst("] cannot be embedded in another C-like comment")) ; /* tmp64 = */ atspre_prerr_string (ATSstrcst(", which initiates from [")) ; /* tmp65 = */ lexing_prerr_position (arg0) ; /* tmp66 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp67 = */ atspre_prerr_newline () ; tmp68 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp57 = */ ats_raise_exn (tmp68) ; return /* (tmp57) */ ; } /* end of [process_comment_clike_open_18] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 16511(line=494, offs=4) -- 16697(line=500, offs=4) */ ATSstaticdec() ats_void_type process_comment_clike_close_19 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_lint_type, tmp71) ; __ats_lab_process_comment_clike_close_19: tmp70 = lexing_lstpos_get () ; tmp71 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp70) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end (tmp71) ; return /* (tmp69) */ ; } /* end of [process_comment_clike_close_19] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 16763(line=504, offs=4) -- 16927(line=509, offs=4) */ ATSstaticdec() ats_void_type process_comment_line_open_20 () { /* local vardec */ // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_lint_type, tmp74) ; __ats_lab_process_comment_line_open_20: tmp73 = lexing_fstpos_get () ; tmp74 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp73) ; /* tmp72 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg (tmp74) ; return /* (tmp72) */ ; } /* end of [process_comment_line_open_20] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 16970(line=511, offs=4) -- 17135(line=516, offs=4) */ ATSstaticdec() ats_void_type process_comment_line_close_21 () { /* local vardec */ // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_lint_type, tmp77) ; __ats_lab_process_comment_line_close_21: tmp76 = lexing_lstpos_get () ; tmp77 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp76) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end (tmp77) ; return /* (tmp75) */ ; } /* end of [process_comment_line_close_21] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 17200(line=520, offs=4) -- 17364(line=525, offs=4) */ ATSstaticdec() ats_void_type process_comment_rest_open_22 () { /* local vardec */ // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_lint_type, tmp80) ; __ats_lab_process_comment_rest_open_22: tmp79 = lexing_fstpos_get () ; tmp80 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp79) ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_beg (tmp80) ; return /* (tmp78) */ ; } /* end of [process_comment_rest_open_22] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 17407(line=527, offs=4) -- 17572(line=532, offs=4) */ ATSstaticdec() ats_void_type process_comment_rest_close_23 () { /* local vardec */ // ATSlocal_void (tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_lint_type, tmp83) ; __ats_lab_process_comment_rest_close_23: tmp82 = lexing_lstpos_get () ; tmp83 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (tmp82) ; /* tmp81 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_comment_end (tmp83) ; return /* (tmp81) */ ; } /* end of [process_comment_rest_close_23] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 17637(line=536, offs=4) -- 17763(line=537, offs=73) */ ATSstaticdec() ats_ptr_type location_get_24 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; __ats_lab_location_get_24: tmp85 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp86 = lexing_fstpos_get () ; tmp87 = lexing_lstpos_get () ; tmp84 = ats_location_make (tmp85, tmp86, tmp87) ; return (tmp84) ; } /* end of [location_get_24] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 17793(line=540, offs=4) -- 17927(line=541, offs=78) */ ATSstaticdec() ats_ptr_type location_get_pos_25 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_location_get_pos_25: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp90 = lexing_lstpos_get () ; tmp88 = ats_location_make (tmp89, arg0, tmp90) ; return (tmp88) ; } /* end of [location_get_pos_25] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 17961(line=544, offs=4) -- 18410(line=560, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_alp_26 () { /* local vardec */ ATSlocal (ats_int_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_int_type, tmp93) ; ATSlocal (ats_bool_type, tmp94) ; // ATSlocal_void (tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_tokenize_identifier_alp_26: tmp92 = lexeme_string () ; tmp93 = atsopt_keyword_search (tmp92) ; tmp94 = atsopt_token_is_valid (tmp93) ; if (tmp94) { /* tmp95 = */ process_keyword_15 () ; tmp91 = tmp93 ; } else { tmp96 = location_get_24 () ; tmp98 = i0de_make (tmp96, tmp92) ; /* tmp97 = */ yylval_ide_set (tmp98) ; tmp91 = IDENTIFIER_alp ; } /* end of [if] */ return (tmp91) ; } /* end of [tokenize_identifier_alp_26] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 18451(line=562, offs=4) -- 18900(line=578, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_sym_27 () { /* local vardec */ ATSlocal (ats_int_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_int_type, tmp101) ; ATSlocal (ats_bool_type, tmp102) ; // ATSlocal_void (tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; // ATSlocal_void (tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; __ats_lab_tokenize_identifier_sym_27: tmp100 = lexeme_string () ; tmp101 = atsopt_keyword_search (tmp100) ; tmp102 = atsopt_token_is_valid (tmp101) ; if (tmp102) { /* tmp103 = */ process_keyword_15 () ; tmp99 = tmp101 ; } else { tmp104 = location_get_24 () ; tmp106 = i0de_make (tmp104, tmp100) ; /* tmp105 = */ yylval_ide_set (tmp106) ; tmp99 = IDENTIFIER_sym ; } /* end of [if] */ return (tmp99) ; } /* end of [tokenize_identifier_sym_27] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 18962(line=582, offs=4) -- 19183(line=588, offs=4) */ ATSstaticdec() ats_ptr_type prefix_identifier1_28 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_size_type, tmp108) ; ATSlocal (ats_bool_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_size_type, tmp111) ; __ats_lab_prefix_identifier1_28: tmp108 = atspre_string_length (ats_castfn_mac(ats_ptr_type, arg0)) ; tmp109 = atspre_gt_size1_int1 (tmp108, 0) ; if (tmp109) { tmp111 = atspre_sub_size1_int1 (tmp108, 1) ; tmp110 = atspre_string_make_substring (ats_castfn_mac(ats_ptr_type, arg0), 0, tmp111) ; tmp107 = ats_castfn_mac(ats_ptr_type, tmp110) ; } else { tmp107 = ats_castfn_mac(ats_ptr_type, arg0) ; } /* end of [if] */ return (tmp107) ; } /* end of [prefix_identifier1_28] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 19243(line=592, offs=4) -- 19452(line=598, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_arr_29 () { /* local vardec */ ATSlocal (ats_int_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_tokenize_identifier_arr_29: tmp114 = lexeme_string () ; tmp113 = prefix_identifier1_28 (tmp114) ; tmp115 = location_get_24 () ; tmp117 = i0de_make (tmp115, tmp113) ; /* tmp116 = */ yylval_ide_set (tmp117) ; tmp112 = IDENTIFIER_arr ; return (tmp112) ; } /* end of [tokenize_identifier_arr_29] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 19493(line=600, offs=4) -- 19705(line=606, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_tmp_30 () { /* local vardec */ ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_tokenize_identifier_tmp_30: tmp120 = lexeme_string () ; tmp119 = prefix_identifier1_28 (tmp120) ; tmp121 = location_get_24 () ; tmp123 = i0de_make (tmp121, tmp119) ; /* tmp122 = */ yylval_ide_set (tmp123) ; tmp118 = IDENTIFIER_tmp ; return (tmp118) ; } /* end of [tokenize_identifier_tmp_30] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 19746(line=608, offs=4) -- 19958(line=614, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_ext_31 () { /* local vardec */ ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_tokenize_identifier_ext_31: tmp126 = lexeme_string () ; tmp125 = prefix_identifier1_28 (tmp126) ; tmp127 = location_get_24 () ; tmp129 = i0de_make (tmp127, tmp125) ; /* tmp128 = */ yylval_ide_set (tmp129) ; tmp124 = IDENTIFIER_ext ; return (tmp124) ; } /* end of [tokenize_identifier_ext_31] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 20020(line=618, offs=4) -- 20332(line=628, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_dlr_32 () { /* local vardec */ ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_int_type, tmp132) ; ATSlocal (ats_bool_type, tmp133) ; // ATSlocal_void (tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_tokenize_identifier_dlr_32: tmp131 = lexeme_string () ; tmp132 = atsopt_keyword_search (tmp131) ; tmp133 = atsopt_token_is_valid (tmp132) ; if (tmp133) { /* tmp134 = */ process_keyword_15 () ; tmp130 = tmp132 ; } else { tmp135 = location_get_24 () ; tmp137 = i0de_make (tmp135, tmp131) ; /* tmp136 = */ yylval_ide_set (tmp137) ; tmp130 = IDENTIFIER_dlr ; } /* end of [if] */ return (tmp130) ; } /* end of [tokenize_identifier_dlr_32] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 20373(line=630, offs=4) -- 20685(line=640, offs=4) */ ATSstaticdec() ats_int_type tokenize_identifier_srp_33 () { /* local vardec */ ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_bool_type, tmp141) ; // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; // ATSlocal_void (tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_tokenize_identifier_srp_33: tmp139 = lexeme_string () ; tmp140 = atsopt_keyword_search (tmp139) ; tmp141 = atsopt_token_is_valid (tmp140) ; if (tmp141) { /* tmp142 = */ process_keyword_15 () ; tmp138 = tmp140 ; } else { tmp143 = location_get_24 () ; tmp145 = i0de_make (tmp143, tmp139) ; /* tmp144 = */ yylval_ide_set (tmp145) ; tmp138 = IDENTIFIER_srp ; } /* end of [if] */ return (tmp138) ; } /* end of [tokenize_identifier_srp_33] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 20747(line=644, offs=4) -- 20908(line=648, offs=4) */ ATSstaticdec() ats_void_type process_char_34 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp146) ; ATSlocal (ats_char_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_process_char_34: tmp147 = lexeme_get (0) ; tmp148 = location_get_pos_25 (arg0) ; tmp149 = c0har_make (tmp148, tmp147) ; /* tmp146 = */ yylval_char_set (tmp149) ; return /* (tmp146) */ ; } /* end of [process_char_34] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 20938(line=650, offs=4) -- 21256(line=661, offs=4) */ ATSstaticdec() ats_char_type char_for_escaped_35 (ats_char_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp150) ; __ats_lab_char_for_escaped_35: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 != 'n') { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp150 = '\n' ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg0 != 't') { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp150 = '\t' ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 != 'v') { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp150 = '\013' ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 != 'b') { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp150 = '\010' ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 != 'r') { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp150 = '\015' ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg0 != 'f') { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp150 = '\014' ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 != 'a') { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp150 = '\007' ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp150 = arg0 ; break ; } while (0) ; return (tmp150) ; } /* end of [char_for_escaped_35] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 21290(line=663, offs=4) -- 21481(line=669, offs=4) */ ATSstaticdec() ats_void_type process_char_escaped_36 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp151) ; ATSlocal (ats_char_type, tmp152) ; ATSlocal (ats_char_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_process_char_escaped_36: tmp153 = lexeme_get (1) ; tmp152 = char_for_escaped_35 (tmp153) ; tmp154 = location_get_pos_25 (arg0) ; tmp155 = c0har_make (tmp154, tmp152) ; /* tmp151 = */ yylval_char_set (tmp155) ; return /* (tmp151) */ ; } /* end of [process_char_escaped_36] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 21519(line=671, offs=4) -- 21590(line=672, offs=35) */ ATSstaticdec() ats_char_type char_for_oct_code_1_37 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp156) ; ATSlocal (ats_int_type, tmp157) ; ATSlocal (ats_char_type, tmp158) ; __ats_lab_char_for_oct_code_1_37: tmp158 = lexeme_get (arg0) ; tmp157 = atspre_sub_char_char (tmp158, '0') ; tmp156 = atspre_char_of_int (tmp157) ; return (tmp156) ; } /* end of [char_for_oct_code_1_37] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 21595(line=674, offs=4) -- 21776(line=680, offs=4) */ ATSstaticdec() ats_void_type process_char_oct_1_38 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp159) ; ATSlocal (ats_char_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_process_char_oct_1_38: tmp160 = char_for_oct_code_1_37 (1) ; tmp161 = location_get_pos_25 (arg0) ; tmp162 = c0har_make (tmp161, tmp160) ; /* tmp159 = */ yylval_char_set (tmp162) ; return /* (tmp159) */ ; } /* end of [process_char_oct_1_38] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 21812(line=682, offs=4) -- 22092(line=689, offs=4) */ ATSstaticdec() ats_char_type char_for_oct_code_2_39 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_int_type, tmp166) ; ATSlocal (ats_char_type, tmp167) ; ATSlocal (ats_int_type, tmp168) ; ATSlocal (ats_char_type, tmp169) ; ATSlocal (ats_int_type, tmp170) ; // ATSlocal_void (tmp171) ; ATSlocal (ats_int_type, tmp172) ; ATSlocal (ats_int_type, tmp173) ; __ats_lab_char_for_oct_code_2_39: tmp164 = lexing_lexbuf_get () ; tmp165 = ats_selsin_mac(tmp164, atslab_1) ; tmp167 = lexeme_get_lexbuf (tmp165, arg0) ; tmp166 = atspre_sub_char_char (tmp167, '0') ; tmp170 = atspre_add_int_int (arg0, 1) ; tmp169 = lexeme_get_lexbuf (tmp165, tmp170) ; tmp168 = atspre_sub_char_char (tmp169, '0') ; /* tmp171 = */ lexing_lexbuf_set (tmp165) ; tmp173 = atspre_asl_int_int1 (tmp166, 3) ; tmp172 = atspre_add_int_int (tmp173, tmp168) ; tmp163 = atspre_char_of_int (tmp172) ; return (tmp163) ; } /* end of [char_for_oct_code_2_39] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 22129(line=691, offs=4) -- 22310(line=697, offs=4) */ ATSstaticdec() ats_void_type process_char_oct_2_40 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp174) ; ATSlocal (ats_char_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; __ats_lab_process_char_oct_2_40: tmp175 = char_for_oct_code_2_39 (1) ; tmp176 = location_get_pos_25 (arg0) ; tmp177 = c0har_make (tmp176, tmp175) ; /* tmp174 = */ yylval_char_set (tmp177) ; return /* (tmp174) */ ; } /* end of [process_char_oct_2_40] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 22346(line=699, offs=4) -- 22690(line=707, offs=4) */ ATSstaticdec() ats_char_type char_for_oct_code_3_41 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_int_type, tmp181) ; ATSlocal (ats_char_type, tmp182) ; ATSlocal (ats_int_type, tmp183) ; ATSlocal (ats_char_type, tmp184) ; ATSlocal (ats_int_type, tmp185) ; ATSlocal (ats_int_type, tmp186) ; ATSlocal (ats_char_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; // ATSlocal_void (tmp189) ; ATSlocal (ats_int_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; ATSlocal (ats_int_type, tmp192) ; ATSlocal (ats_int_type, tmp193) ; __ats_lab_char_for_oct_code_3_41: tmp179 = lexing_lexbuf_get () ; tmp180 = ats_selsin_mac(tmp179, atslab_1) ; tmp182 = lexeme_get_lexbuf (tmp180, arg0) ; tmp181 = atspre_sub_char_char (tmp182, '0') ; tmp185 = atspre_add_int_int (arg0, 1) ; tmp184 = lexeme_get_lexbuf (tmp180, tmp185) ; tmp183 = atspre_sub_char_char (tmp184, '0') ; tmp188 = atspre_add_int_int (arg0, 2) ; tmp187 = lexeme_get_lexbuf (tmp180, tmp188) ; tmp186 = atspre_sub_char_char (tmp187, '0') ; /* tmp189 = */ lexing_lexbuf_set (tmp180) ; tmp192 = atspre_asl_int_int1 (tmp181, 6) ; tmp193 = atspre_asl_int_int1 (tmp183, 3) ; tmp191 = atspre_add_int_int (tmp192, tmp193) ; tmp190 = atspre_add_int_int (tmp191, tmp186) ; tmp178 = atspre_char_of_int (tmp190) ; return (tmp178) ; } /* end of [char_for_oct_code_3_41] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 22727(line=709, offs=4) -- 22908(line=715, offs=4) */ ATSstaticdec() ats_void_type process_char_oct_3_42 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp194) ; ATSlocal (ats_char_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; __ats_lab_process_char_oct_3_42: tmp195 = char_for_oct_code_3_41 (1) ; tmp196 = location_get_pos_25 (arg0) ; tmp197 = c0har_make (tmp196, tmp195) ; /* tmp194 = */ yylval_char_set (tmp197) ; return /* (tmp194) */ ; } /* end of [process_char_oct_3_42] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 22966(line=719, offs=4) -- 23108(line=722, offs=6) */ ATSstaticdec() ats_int_type int_of_xdigit_43 (ats_char_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_bool_type, tmp199) ; ATSlocal (ats_bool_type, tmp200) ; ATSlocal (ats_int_type, tmp201) ; ATSlocal (ats_int_type, tmp202) ; __ats_lab_int_of_xdigit_43: tmp199 = atspre_char_isdigit (arg0) ; if (tmp199) { tmp198 = atspre_sub_char_char (arg0, '0') ; } else { tmp200 = atspre_char_isupper (arg0) ; if (tmp200) { tmp201 = atspre_sub_char_char (arg0, 'A') ; tmp198 = atspre_add_int_int (10, tmp201) ; } else { tmp202 = atspre_sub_char_char (arg0, 'a') ; tmp198 = atspre_add_int_int (10, tmp202) ; } /* end of [if] */ } /* end of [if] */ return (tmp198) ; } /* end of [int_of_xdigit_43] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 23164(line=725, offs=4) -- 23266(line=727, offs=4) */ ATSstaticdec() ats_char_type char_for_hex_code_1_44 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp203) ; ATSlocal (ats_int_type, tmp204) ; ATSlocal (ats_char_type, tmp205) ; __ats_lab_char_for_hex_code_1_44: tmp205 = lexeme_get (arg0) ; tmp204 = int_of_xdigit_43 (tmp205) ; tmp203 = atspre_char_of_int (tmp204) ; return (tmp203) ; } /* end of [char_for_hex_code_1_44] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 23303(line=729, offs=4) -- 23484(line=735, offs=4) */ ATSstaticdec() ats_void_type process_char_hex_1_45 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp206) ; ATSlocal (ats_char_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_process_char_hex_1_45: tmp207 = char_for_hex_code_1_44 (2) ; tmp208 = location_get_pos_25 (arg0) ; tmp209 = c0har_make (tmp208, tmp207) ; /* tmp206 = */ yylval_char_set (tmp209) ; return /* (tmp206) */ ; } /* end of [process_char_hex_1_45] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 23520(line=737, offs=4) -- 23820(line=744, offs=4) */ ATSstaticdec() ats_char_type char_for_hex_code_2_46 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_int_type, tmp213) ; ATSlocal (ats_char_type, tmp214) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_char_type, tmp216) ; ATSlocal (ats_int_type, tmp217) ; // ATSlocal_void (tmp218) ; ATSlocal (ats_int_type, tmp219) ; ATSlocal (ats_int_type, tmp220) ; __ats_lab_char_for_hex_code_2_46: tmp211 = lexing_lexbuf_get () ; tmp212 = ats_selsin_mac(tmp211, atslab_1) ; tmp214 = lexeme_get_lexbuf (tmp212, arg0) ; tmp213 = int_of_xdigit_43 (tmp214) ; tmp217 = atspre_add_int_int (arg0, 1) ; tmp216 = lexeme_get_lexbuf (tmp212, tmp217) ; tmp215 = int_of_xdigit_43 (tmp216) ; /* tmp218 = */ lexing_lexbuf_set (tmp212) ; tmp220 = atspre_asl_int_int1 (tmp213, 4) ; tmp219 = atspre_add_int_int (tmp220, tmp215) ; tmp210 = atspre_char_of_int (tmp219) ; return (tmp210) ; } /* end of [char_for_hex_code_2_46] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 23857(line=746, offs=4) -- 24038(line=752, offs=4) */ ATSstaticdec() ats_void_type process_char_hex_2_47 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp221) ; ATSlocal (ats_char_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_process_char_hex_2_47: tmp222 = char_for_hex_code_2_46 (2) ; tmp223 = location_get_pos_25 (arg0) ; tmp224 = c0har_make (tmp223, tmp222) ; /* tmp221 = */ yylval_char_set (tmp224) ; return /* (tmp221) */ ; } /* end of [process_char_hex_2_47] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 24095(line=756, offs=4) -- 24243(line=760, offs=4) */ ATSstaticdec() ats_void_type process_literal_float_48 () { /* local vardec */ // ATSlocal_void (tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_process_literal_float_48: tmp226 = location_get_24 () ; tmp227 = lexeme_string () ; tmp228 = f0loat_make (tmp226, tmp227) ; /* tmp225 = */ yylval_float_set (tmp228) ; return /* (tmp225) */ ; } /* end of [process_literal_float_48] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 24282(line=762, offs=4) -- 24436(line=766, offs=4) */ ATSstaticdec() ats_void_type process_literal_floatsp_49 () { /* local vardec */ // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_process_literal_floatsp_49: tmp230 = lexeme_string () ; tmp231 = location_get_24 () ; tmp232 = f0loatsp_make (tmp231, tmp230) ; /* tmp229 = */ yylval_floatsp_set (tmp232) ; return /* (tmp229) */ ; } /* end of [process_literal_floatsp_49] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 25177(line=799, offs=4) -- 25698(line=816, offs=4) */ ATSstaticdec() ats_void_type process_literal_int_50 () { /* local vardec */ // ATSlocal_void (tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_char_type, tmp236) ; // ATSlocal_void (tmp237) ; ATSlocal (ats_bool_type, tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; __ats_lab_process_literal_int_50: tmp234 = lexeme_string () ; tmp235 = location_get_24 () ; /* ats_char_type tmp236 ; */ tmp236 = '\000' ; tmp238 = ats_lexer_literal_int_check (tmp234, (&tmp236)) ; if (tmp238) { /* empty */ } else { /* tmp239 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp235) ; /* tmp240 = */ atspre_prerr_string (ATSstrcst(": the digit [")) ; /* tmp241 = */ atspre_prerr_char (tmp236) ; /* tmp242 = */ atspre_prerr_string (ATSstrcst("] is illegal in the octal constant [")) ; /* tmp243 = */ atspre_prerr_string (tmp234) ; /* tmp244 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp245 = */ atspre_prerr_newline () ; /* tmp237 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp246 = i0nt_make (tmp235, tmp234) ; /* tmp233 = */ yylval_int_set (tmp246) ; return /* (tmp233) */ ; } /* end of [process_literal_int_50] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 25909(line=823, offs=4) -- 26369(line=836, offs=4) */ ATSstaticdec() ats_void_type process_literal_intsp_51 () { /* local vardec */ // ATSlocal_void (tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_char_type, tmp250) ; // ATSlocal_void (tmp251) ; ATSlocal (ats_bool_type, tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; // ATSlocal_void (tmp258) ; // ATSlocal_void (tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_process_literal_intsp_51: tmp248 = lexeme_string () ; tmp249 = location_get_24 () ; /* ats_char_type tmp250 ; */ tmp250 = '\000' ; tmp252 = ats_lexer_literal_int_check (tmp248, (&tmp250)) ; if (tmp252) { /* empty */ } else { /* tmp253 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp249) ; /* tmp254 = */ atspre_prerr_string (ATSstrcst(": the digit [")) ; /* tmp255 = */ atspre_prerr_char (tmp250) ; /* tmp256 = */ atspre_prerr_string (ATSstrcst("] is illegal in the octal constant [")) ; /* tmp257 = */ atspre_prerr_string (tmp248) ; /* tmp258 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp259 = */ atspre_prerr_newline () ; /* tmp251 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp260 = i0ntsp_make (tmp249, tmp248) ; /* tmp247 = */ yylval_intsp_set (tmp260) ; return /* (tmp247) */ ; } /* end of [process_literal_intsp_51] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 26429(line=840, offs=4) -- 26600(line=844, offs=6) */ ATSstaticdec() ats_int_type STRING_char_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp261) ; ATSlocal (ats_char_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_int_type, tmp264) ; __ats_lab_STRING_char_52: tmp262 = lexeme_get (0) ; tmp263 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp263, atslab_0, tmp262) ; ats_selptrset_mac(anairiats_sum_1, tmp263, atslab_1, arg1) ; tmp264 = atspre_iadd (arg2, 1) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp263, tmp264) ; return (tmp261) ; } /* end of [STRING_char_52] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 26605(line=846, offs=4) -- 26803(line=850, offs=6) */ ATSstaticdec() ats_int_type STRING_char_escaped_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp265) ; ATSlocal (ats_char_type, tmp266) ; ATSlocal (ats_char_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_int_type, tmp269) ; __ats_lab_STRING_char_escaped_53: tmp267 = lexeme_get (1) ; tmp266 = char_for_escaped_35 (tmp267) ; tmp268 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp268, atslab_0, tmp266) ; ats_selptrset_mac(anairiats_sum_1, tmp268, atslab_1, arg1) ; tmp269 = atspre_iadd (arg2, 1) ; tmp265 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp268, tmp269) ; return (tmp265) ; } /* end of [STRING_char_escaped_53] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 26808(line=852, offs=4) -- 26996(line=856, offs=6) */ ATSstaticdec() ats_int_type STRING_char_oct_1_54 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp270) ; ATSlocal (ats_char_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_int_type, tmp273) ; __ats_lab_STRING_char_oct_1_54: tmp271 = char_for_oct_code_1_37 (1) ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp272, atslab_0, tmp271) ; ats_selptrset_mac(anairiats_sum_1, tmp272, atslab_1, arg1) ; tmp273 = atspre_iadd (arg2, 1) ; tmp270 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp272, tmp273) ; return (tmp270) ; } /* end of [STRING_char_oct_1_54] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 27001(line=858, offs=4) -- 27189(line=862, offs=6) */ ATSstaticdec() ats_int_type STRING_char_oct_2_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp274) ; ATSlocal (ats_char_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_int_type, tmp277) ; __ats_lab_STRING_char_oct_2_55: tmp275 = char_for_oct_code_2_39 (1) ; tmp276 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp276, atslab_0, tmp275) ; ats_selptrset_mac(anairiats_sum_1, tmp276, atslab_1, arg1) ; tmp277 = atspre_iadd (arg2, 1) ; tmp274 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp276, tmp277) ; return (tmp274) ; } /* end of [STRING_char_oct_2_55] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 27194(line=864, offs=4) -- 27382(line=868, offs=6) */ ATSstaticdec() ats_int_type STRING_char_oct_3_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp278) ; ATSlocal (ats_char_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_int_type, tmp281) ; __ats_lab_STRING_char_oct_3_56: tmp279 = char_for_oct_code_3_41 (1) ; tmp280 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp280, atslab_0, tmp279) ; ats_selptrset_mac(anairiats_sum_1, tmp280, atslab_1, arg1) ; tmp281 = atspre_iadd (arg2, 1) ; tmp278 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp280, tmp281) ; return (tmp278) ; } /* end of [STRING_char_oct_3_56] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 27387(line=870, offs=4) -- 27575(line=874, offs=6) */ ATSstaticdec() ats_int_type STRING_char_hex_1_57 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_char_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_int_type, tmp285) ; __ats_lab_STRING_char_hex_1_57: tmp283 = char_for_hex_code_1_44 (2) ; tmp284 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp284, atslab_0, tmp283) ; ats_selptrset_mac(anairiats_sum_1, tmp284, atslab_1, arg1) ; tmp285 = atspre_iadd (arg2, 1) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp284, tmp285) ; return (tmp282) ; } /* end of [STRING_char_hex_1_57] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 27580(line=876, offs=4) -- 27768(line=880, offs=6) */ ATSstaticdec() ats_int_type STRING_char_hex_2_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_char_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_int_type, tmp289) ; __ats_lab_STRING_char_hex_2_58: tmp287 = char_for_hex_code_2_46 (2) ; tmp288 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp288, atslab_0, tmp287) ; ats_selptrset_mac(anairiats_sum_1, tmp288, atslab_1, arg1) ; tmp289 = atspre_iadd (arg2, 1) ; tmp286 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (arg0, tmp288, tmp289) ; return (tmp286) ; } /* end of [STRING_char_hex_2_58] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 27773(line=882, offs=4) -- 28021(line=888, offs=4) */ ATSstaticdec() ats_void_type process_literal_string_59 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; __ats_lab_process_literal_string_59: tmp291 = string_make_charlst_rev_int (arg1, arg2) ; tmp292 = location_get_pos_25 (arg0) ; tmp293 = s0tring_make (tmp292, tmp291, arg2) ; /* tmp290 = */ yylval_string_set (tmp293) ; return /* (tmp290) */ ; } /* end of [process_literal_string_59] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 28082(line=892, offs=4) -- 28266(line=896, offs=6) */ ATSstaticdec() ats_int_type EXTCODE_char_60 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp294) ; ATSlocal (ats_char_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_int_type, tmp297) ; __ats_lab_EXTCODE_char_60: tmp295 = lexeme_get (0) ; tmp296 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp296, atslab_0, tmp295) ; ats_selptrset_mac(anairiats_sum_1, tmp296, atslab_1, arg2) ; tmp297 = atspre_iadd (arg3, 1) ; tmp294 = ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE (arg0, arg1, tmp296, tmp297) ; return (tmp294) ; } /* end of [EXTCODE_char_60] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 28271(line=898, offs=4) -- 28542(line=905, offs=6) */ ATSstaticdec() ats_void_type process_literal_extcode_61 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; __ats_lab_process_literal_extcode_61: tmp299 = string_make_charlst_rev_int (arg2, arg3) ; tmp300 = location_get_pos_25 (arg0) ; tmp301 = e0xtcode_make (tmp300, arg1, tmp299) ; /* tmp298 = */ yylval_extcode_set (tmp301) ; return /* (tmp298) */ ; } /* end of [process_literal_extcode_61] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 28637(line=916, offs=4) -- 28956(line=926, offs=4) */ ATSstaticdec() ats_varet_type process_illegal_token_62 () { /* local vardec */ // ATSlocal_void (tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; ATSlocal (ats_char_type, tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; __ats_lab_process_illegal_token_62: /* tmp303 = */ atsopt_filename_prerr () ; /* tmp304 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp305 = */ atspre_prerr_string (ATSstrcst(": illegal character [")) ; tmp307 = lexeme_get (0) ; /* tmp306 = */ atspre_prerr_char (tmp307) ; /* tmp308 = */ atspre_prerr_string (ATSstrcst("] at position [")) ; /* tmp309 = */ lexing_curpos_prerr () ; /* tmp310 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp311 = */ atspre_prerr_newline () ; tmp312 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp302 = */ ats_raise_exn (tmp312) ; return /* (tmp302) */ ; } /* end of [process_illegal_token_62] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 28995(line=928, offs=4) -- 29266(line=936, offs=4) */ ATSstaticdec() ats_varet_type process_illegal_char_63 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_process_illegal_char_63: /* tmp314 = */ atsopt_filename_prerr () ; /* tmp315 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp316 = */ atspre_prerr_string (ATSstrcst(": illegal character at [")) ; /* tmp317 = */ lexing_prerr_position (arg0) ; /* tmp318 = */ atspre_prerr_string (ATSstrcst("] is unclosed!\n")) ; tmp319 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp313 = */ ats_raise_exn (tmp319) ; return /* (tmp313) */ ; } /* end of [process_illegal_char_63] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 29308(line=940, offs=4) -- 29615(line=950, offs=4) */ ATSstaticdec() ats_varet_type process_unclosed_comment_64 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; // ATSlocal_void (tmp322) ; // ATSlocal_void (tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; __ats_lab_process_unclosed_comment_64: /* tmp321 = */ poslst_free_0 (arg1) ; /* tmp322 = */ atsopt_filename_prerr () ; /* tmp323 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp324 = */ atspre_prerr_string (ATSstrcst(": the comment starting at [")) ; /* tmp325 = */ lexing_prerr_position (arg0) ; /* tmp326 = */ atspre_prerr_string (ATSstrcst("] is unclosed!\n")) ; tmp327 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp320 = */ ats_raise_exn (tmp327) ; return /* (tmp320) */ ; } /* end of [process_unclosed_comment_64] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 29657(line=952, offs=4) -- 29931(line=960, offs=4) */ ATSstaticdec() ats_varet_type process_unclosed_comment_clike_65 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; // ATSlocal_void (tmp330) ; // ATSlocal_void (tmp331) ; // ATSlocal_void (tmp332) ; // ATSlocal_void (tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; __ats_lab_process_unclosed_comment_clike_65: /* tmp329 = */ atsopt_filename_prerr () ; /* tmp330 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp331 = */ atspre_prerr_string (ATSstrcst(": the comment starting at [")) ; /* tmp332 = */ lexing_prerr_position (arg0) ; /* tmp333 = */ atspre_prerr_string (ATSstrcst("] is unclosed!\n")) ; tmp334 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp328 = */ ats_raise_exn (tmp334) ; return /* (tmp328) */ ; } /* end of [process_unclosed_comment_clike_65] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 29983(line=964, offs=4) -- 30338(line=976, offs=4) */ ATSstaticdec() ats_varet_type process_unclosed_string_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp335) ; // ATSlocal_void (tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; __ats_lab_process_unclosed_string_66: /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free (arg1) ; /* tmp337 = */ atsopt_filename_prerr () ; /* tmp338 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp339 = */ atspre_prerr_string (ATSstrcst(": the string starting at [")) ; /* tmp340 = */ lexing_prerr_position (arg0) ; /* tmp341 = */ atspre_prerr_string (ATSstrcst("] is unclosed!\n")) ; tmp342 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp335 = */ ats_raise_exn (tmp342) ; return /* (tmp335) */ ; } /* end of [process_unclosed_string_66] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 30379(line=978, offs=4) -- 30741(line=990, offs=4) */ ATSstaticdec() ats_varet_type process_unclosed_extcode_67 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; __ats_lab_process_unclosed_extcode_67: /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free (arg2) ; /* tmp345 = */ atsopt_filename_prerr () ; /* tmp346 = */ atspre_prerr_string (ATSstrcst(": LEXING ERROR")) ; /* tmp347 = */ atspre_prerr_string (ATSstrcst(": the code starting at [")) ; /* tmp348 = */ lexing_prerr_position (arg0) ; /* tmp349 = */ atspre_prerr_string (ATSstrcst("] is unclosed!\n")) ; tmp350 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* tmp343 = */ ats_raise_exn (tmp350) ; return /* (tmp343) */ ; } /* end of [process_unclosed_extcode_67] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 220870(line=1333, offs=16) -- 224499(line=1415, offs=30) */ ATSglobaldec() ats_int_type atsopt_lexer_token_get () { /* local vardec */ ATSlocal (ats_int_type, tmp356) ; ATSlocal (ats_int_type, tmp357) ; // ATSlocal_void (tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; // ATSlocal_void (tmp369) ; // ATSlocal_void (tmp370) ; // ATSlocal_void (tmp371) ; // ATSlocal_void (tmp372) ; // ATSlocal_void (tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; // ATSlocal_void (tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; // ATSlocal_void (tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; // ATSlocal_void (tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; __ats_lab_atsopt_lexer_token_get: tmp357 = lexing_engine (statmp351, statmp353) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp357 != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: goto __ats_lab_atsopt_lexer_token_get ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (tmp357 != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: /* tmp358 = */ process_keyword_15 () ; tmp356 = CASEMINUS ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp357 != 3) { goto __ats_lab_15_0 ; } __ats_lab_14_1: /* tmp359 = */ process_keyword_15 () ; tmp356 = CASEPLUS ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp357 != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: /* tmp360 = */ process_keyword_15 () ; tmp356 = FNSTAR ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (tmp357 != 5) { goto __ats_lab_17_0 ; } __ats_lab_16_1: /* tmp361 = */ process_keyword_15 () ; tmp356 = FORSTAR ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (tmp357 != 6) { goto __ats_lab_18_0 ; } __ats_lab_17_1: /* tmp362 = */ process_keyword_15 () ; tmp356 = WHILESTAR ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp357 != 7) { goto __ats_lab_19_0 ; } __ats_lab_18_1: /* tmp363 = */ process_keyword_15 () ; tmp356 = ABST0YPE ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp357 != 8) { goto __ats_lab_20_0 ; } __ats_lab_19_1: /* tmp364 = */ process_keyword_15 () ; tmp356 = ABSVIEWT0YPE ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp357 != 9) { goto __ats_lab_21_0 ; } __ats_lab_20_1: /* tmp365 = */ process_token_14 () ; tmp356 = PROPPLUS ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (tmp357 != 10) { goto __ats_lab_22_0 ; } __ats_lab_21_1: /* tmp366 = */ process_token_14 () ; tmp356 = PROPMINUS ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (tmp357 != 11) { goto __ats_lab_23_0 ; } __ats_lab_22_1: /* tmp367 = */ process_token_14 () ; tmp356 = TYPEPLUS ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (tmp357 != 12) { goto __ats_lab_24_0 ; } __ats_lab_23_1: /* tmp368 = */ process_token_14 () ; tmp356 = TYPEMINUS ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp357 != 13) { goto __ats_lab_25_0 ; } __ats_lab_24_1: /* tmp369 = */ process_token_14 () ; tmp356 = T0YPE ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp357 != 14) { goto __ats_lab_26_0 ; } __ats_lab_25_1: /* tmp370 = */ process_token_14 () ; tmp356 = T0YPEPLUS ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (tmp357 != 15) { goto __ats_lab_27_0 ; } __ats_lab_26_1: /* tmp371 = */ process_token_14 () ; tmp356 = T0YPEMINUS ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp357 != 16) { goto __ats_lab_28_0 ; } __ats_lab_27_1: /* tmp372 = */ process_token_14 () ; tmp356 = VIEWPLUS ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp357 != 17) { goto __ats_lab_29_0 ; } __ats_lab_28_1: /* tmp373 = */ process_token_14 () ; tmp356 = VIEWMINUS ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (tmp357 != 18) { goto __ats_lab_30_0 ; } __ats_lab_29_1: /* tmp374 = */ process_token_14 () ; tmp356 = VIEWTYPEPLUS ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp357 != 19) { goto __ats_lab_31_0 ; } __ats_lab_30_1: /* tmp375 = */ process_token_14 () ; tmp356 = VIEWTYPEMINUS ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (tmp357 != 20) { goto __ats_lab_32_0 ; } __ats_lab_31_1: /* tmp376 = */ process_token_14 () ; tmp356 = VIEWTYPEPLUS ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp357 != 21) { goto __ats_lab_33_0 ; } __ats_lab_32_1: /* tmp377 = */ process_token_14 () ; tmp356 = VIEWTYPEMINUS ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (tmp357 != 22) { goto __ats_lab_34_0 ; } __ats_lab_33_1: /* tmp378 = */ process_token_14 () ; tmp356 = VIEWT0YPE ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp357 != 23) { goto __ats_lab_35_0 ; } __ats_lab_34_1: /* tmp379 = */ process_token_14 () ; tmp356 = VIEWT0YPEPLUS ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp357 != 24) { goto __ats_lab_36_0 ; } __ats_lab_35_1: /* tmp380 = */ process_token_14 () ; tmp356 = VIEWT0YPEMINUS ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp357 != 25) { goto __ats_lab_37_0 ; } __ats_lab_36_1: /* tmp381 = */ process_token_14 () ; tmp356 = VIEWT0YPE ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp357 != 26) { goto __ats_lab_38_0 ; } __ats_lab_37_1: /* tmp382 = */ process_token_14 () ; tmp356 = VIEWT0YPEPLUS ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp357 != 27) { goto __ats_lab_39_0 ; } __ats_lab_38_1: /* tmp383 = */ process_token_14 () ; tmp356 = VIEWT0YPEMINUS ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (tmp357 != 28) { goto __ats_lab_40_0 ; } __ats_lab_39_1: /* tmp384 = */ process_keyword_15 () ; tmp356 = VALPLUS ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (tmp357 != 29) { goto __ats_lab_41_0 ; } __ats_lab_40_1: /* tmp385 = */ process_keyword_15 () ; tmp356 = VALMINUS ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (tmp357 != 30) { goto __ats_lab_42_0 ; } __ats_lab_41_1: /* tmp386 = */ process_token_14 () ; tmp356 = FOLDAT ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp357 != 31) { goto __ats_lab_43_0 ; } __ats_lab_42_1: /* tmp387 = */ process_token_14 () ; tmp356 = FREEAT ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp357 != 32) { goto __ats_lab_44_0 ; } __ats_lab_43_1: /* tmp388 = */ process_token_14 () ; tmp356 = VIEWAT ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp357 != 33) { goto __ats_lab_45_0 ; } __ats_lab_44_1: /* tmp389 = */ process_token_14 () ; tmp356 = ATLAM ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp357 != 34) { goto __ats_lab_46_0 ; } __ats_lab_45_1: /* tmp390 = */ process_token_14 () ; tmp356 = ATLLAM ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (tmp357 != 35) { goto __ats_lab_47_0 ; } __ats_lab_46_1: /* tmp391 = */ process_token_14 () ; tmp356 = ATFIX ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp357 != 36) { goto __ats_lab_48_0 ; } __ats_lab_47_1: /* tmp392 = */ process_token_14 () ; tmp356 = R0EAD ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp357 != 37) { goto __ats_lab_49_0 ; } __ats_lab_48_1: /* tmp393 = */ COMMENT0_5 () ; goto __ats_lab_atsopt_lexer_token_get ; // tail call break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp357 != 38) { goto __ats_lab_50_0 ; } __ats_lab_49_1: /* tmp394 = */ COMMENT0_CLIKE_7 () ; goto __ats_lab_atsopt_lexer_token_get ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp357 != 39) { goto __ats_lab_51_0 ; } __ats_lab_50_1: /* tmp395 = */ process_comment_line_open_20 () ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_LINE () ; goto __ats_lab_atsopt_lexer_token_get ; // tail call break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (tmp357 != 40) { goto __ats_lab_52_0 ; } __ats_lab_51_1: /* tmp397 = */ process_comment_rest_open_22 () ; /* tmp398 = */ ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST () ; tmp356 = TOKEN_eof ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp357 != 41) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp356 = tokenize_identifier_alp_26 () ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (tmp357 != 42) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp356 = tokenize_identifier_arr_29 () ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (tmp357 != 43) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp356 = tokenize_identifier_tmp_30 () ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (tmp357 != 44) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp356 = tokenize_identifier_ext_31 () ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (tmp357 != 45) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp356 = tokenize_identifier_dlr_32 () ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp357 != 46) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp356 = tokenize_identifier_srp_33 () ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp357 != 47) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp356 = tokenize_identifier_sym_27 () ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (tmp357 != 48) { goto __ats_lab_60_0 ; } __ats_lab_59_1: /* tmp399 = */ process_literal_int_50 () ; tmp356 = LITERAL_int ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (tmp357 != 49) { goto __ats_lab_61_0 ; } __ats_lab_60_1: /* tmp400 = */ process_literal_intsp_51 () ; tmp356 = LITERAL_intsp ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (tmp357 != 50) { goto __ats_lab_62_0 ; } __ats_lab_61_1: /* tmp401 = */ process_literal_float_48 () ; tmp356 = LITERAL_float ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (tmp357 != 51) { goto __ats_lab_63_0 ; } __ats_lab_62_1: /* tmp402 = */ process_literal_floatsp_49 () ; tmp356 = LITERAL_floatsp ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (tmp357 != 52) { goto __ats_lab_64_0 ; } __ats_lab_63_1: /* tmp403 = */ process_keyword_15 () ; tmp356 = LPAREN ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (tmp357 != 53) { goto __ats_lab_65_0 ; } __ats_lab_64_1: /* tmp404 = */ process_keyword_15 () ; tmp356 = RPAREN ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (tmp357 != 54) { goto __ats_lab_66_0 ; } __ats_lab_65_1: /* tmp405 = */ process_keyword_15 () ; tmp356 = LBRACKET ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (tmp357 != 55) { goto __ats_lab_67_0 ; } __ats_lab_66_1: /* tmp406 = */ process_keyword_15 () ; tmp356 = RBRACKET ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (tmp357 != 56) { goto __ats_lab_68_0 ; } __ats_lab_67_1: /* tmp407 = */ process_keyword_15 () ; tmp356 = LBRACE ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (tmp357 != 57) { goto __ats_lab_69_0 ; } __ats_lab_68_1: /* tmp408 = */ process_keyword_15 () ; tmp356 = RBRACE ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp357 != 58) { goto __ats_lab_70_0 ; } __ats_lab_69_1: /* tmp409 = */ process_keyword_15 () ; tmp356 = QUOTELPAREN ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (tmp357 != 59) { goto __ats_lab_71_0 ; } __ats_lab_70_1: /* tmp410 = */ process_keyword_15 () ; tmp356 = QUOTELBRACKET ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (tmp357 != 60) { goto __ats_lab_72_0 ; } __ats_lab_71_1: /* tmp411 = */ process_keyword_15 () ; tmp356 = QUOTELBRACE ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (tmp357 != 61) { goto __ats_lab_73_0 ; } __ats_lab_72_1: /* tmp412 = */ process_keyword_15 () ; tmp356 = ATLPAREN ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (tmp357 != 62) { goto __ats_lab_74_0 ; } __ats_lab_73_1: /* tmp413 = */ process_keyword_15 () ; tmp356 = ATLBRACKET ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (tmp357 != 63) { goto __ats_lab_75_0 ; } __ats_lab_74_1: /* tmp414 = */ process_keyword_15 () ; tmp356 = ATLBRACE ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (tmp357 != 64) { goto __ats_lab_76_0 ; } __ats_lab_75_1: /* tmp415 = */ process_keyword_15 () ; tmp356 = HASHLPAREN ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (tmp357 != 65) { goto __ats_lab_77_0 ; } __ats_lab_76_1: /* tmp416 = */ process_keyword_15 () ; tmp356 = HASHLBRACKET ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (tmp357 != 66) { goto __ats_lab_78_0 ; } __ats_lab_77_1: /* tmp417 = */ process_keyword_15 () ; tmp356 = HASHLBRACE ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (tmp357 != 67) { goto __ats_lab_79_0 ; } __ats_lab_78_1: /* tmp418 = */ process_keyword_15 () ; tmp356 = COMMA ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp357 != 68) { goto __ats_lab_80_0 ; } __ats_lab_79_1: /* tmp419 = */ process_keyword_15 () ; tmp356 = SEMICOLON ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (tmp357 != 69) { goto __ats_lab_81_0 ; } __ats_lab_80_1: /* tmp420 = */ process_keyword_15 () ; tmp356 = BACKSLASH ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (tmp357 != 70) { goto __ats_lab_82_0 ; } __ats_lab_81_1: /* tmp421 = */ process_keyword_15 () ; tmp356 = BACKQUOTELPAREN ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (tmp357 != 71) { goto __ats_lab_83_0 ; } __ats_lab_82_1: /* tmp422 = */ process_keyword_15 () ; tmp356 = COMMALPAREN ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (tmp357 != 72) { goto __ats_lab_84_0 ; } __ats_lab_83_1: /* tmp423 = */ process_keyword_15 () ; tmp356 = PERCENTLPAREN ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (tmp357 != 73) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp356 = STRING0_11 () ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (tmp357 != 74) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp356 = CHAR0_3 () ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (tmp357 != 75) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp356 = EXTCODE0_13 (0) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp357 != 76) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp356 = EXTCODE0_13 (1) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (tmp357 != 77) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp356 = EXTCODE0_13 (2) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (tmp357 != 78) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp356 = EXTCODE0_13 (-1) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (tmp357 != 79) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp356 = TOKEN_eof ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (tmp357 != 80) { goto __ats_lab_92_0 ; } __ats_lab_91_1: /* tmp356 = */ process_illegal_token_62 () ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: __ats_lab_92_1: tmp356 = MAIN_lexing_error_1 () ; break ; } while (0) ; return (tmp356) ; } /* end of [atsopt_lexer_token_get] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 232042(line=1436, offs=19) -- 232395(line=1444, offs=38) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp429) ; ATSlocal (ats_int_type, tmp430) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT: tmp430 = lexing_engine (statmp424, statmp426) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (tmp430 != 1) { goto __ats_lab_94_0 ; } __ats_lab_93_1: /* tmp429 = */ process_comment_open_16 (arg0, arg1) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (tmp430 != 2) { goto __ats_lab_95_0 ; } __ats_lab_94_1: /* tmp429 = */ process_comment_close_17 (arg0, arg1) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (tmp430 != 3) { goto __ats_lab_96_0 ; } __ats_lab_95_1: arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT ; // tail call break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (tmp430 != 4) { goto __ats_lab_97_0 ; } __ats_lab_96_1: arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (tmp430 != 5) { goto __ats_lab_98_0 ; } __ats_lab_97_1: arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT ; // tail call break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (tmp430 != 6) { goto __ats_lab_99_0 ; } __ats_lab_98_1: /* tmp429 = */ process_unclosed_comment_64 (arg0, arg1) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: /* tmp429 = */ COMMENT_lexing_error_4 (arg0, arg1) ; break ; } while (0) ; return /* (tmp429) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 239956(line=1465, offs=25) -- 240331(line=1473, offs=40) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp436) ; ATSlocal (ats_int_type, tmp437) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE: tmp437 = lexing_engine (statmp431, statmp433) ; do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (tmp437 != 1) { goto __ats_lab_101_0 ; } __ats_lab_100_1: /* tmp436 = */ process_comment_clike_open_18 (arg0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (tmp437 != 2) { goto __ats_lab_102_0 ; } __ats_lab_101_1: /* tmp436 = */ process_comment_clike_close_19 (arg0) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (tmp437 != 3) { goto __ats_lab_103_0 ; } __ats_lab_102_1: arg0 = arg0 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE ; // tail call break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (tmp437 != 4) { goto __ats_lab_104_0 ; } __ats_lab_103_1: arg0 = arg0 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE ; // tail call break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (tmp437 != 5) { goto __ats_lab_105_0 ; } __ats_lab_104_1: arg0 = arg0 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE ; // tail call break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (tmp437 != 6) { goto __ats_lab_106_0 ; } __ats_lab_105_1: /* tmp436 = */ process_unclosed_comment_clike_65 (arg0) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: /* tmp436 = */ COMMENT_CLIKE_lexing_error_6 (arg0) ; break ; } while (0) ; return /* (tmp436) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_CLIKE] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 243663(line=1485, offs=24) -- 243881(line=1489, offs=38) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_LINE () { /* local vardec */ // ATSlocal_void (tmp443) ; ATSlocal (ats_int_type, tmp444) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_LINE: tmp444 = lexing_engine (statmp438, statmp440) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp444 != 1) { goto __ats_lab_108_0 ; } __ats_lab_107_1: /* tmp443 = */ process_comment_line_close_21 () ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp444 != 2) { goto __ats_lab_109_0 ; } __ats_lab_108_1: /* tmp443 = */ process_comment_line_close_21 () ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: /* tmp443 = */ COMMENT_LINE_lexing_error_8 () ; break ; } while (0) ; return /* (tmp443) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_LINE] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 247213(line=1501, offs=24) -- 247417(line=1505, offs=38) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST () { /* local vardec */ // ATSlocal_void (tmp450) ; ATSlocal (ats_int_type, tmp451) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST: tmp451 = lexing_engine (statmp445, statmp447) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (tmp451 != 1) { goto __ats_lab_111_0 ; } __ats_lab_110_1: goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST ; // tail call break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (tmp451 != 2) { goto __ats_lab_112_0 ; } __ats_lab_111_1: /* tmp450 = */ process_comment_rest_close_23 () ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: /* tmp450 = */ COMMENT_REST_lexing_error_9 () ; break ; } while (0) ; return /* (tmp450) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__COMMENT_REST] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 265329(line=1538, offs=16) -- 265855(line=1548, offs=33) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__CHAR (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp457) ; ATSlocal (ats_int_type, tmp458) ; // ATSlocal_void (tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp461) ; // ATSlocal_void (tmp462) ; // ATSlocal_void (tmp463) ; // ATSlocal_void (tmp464) ; // ATSlocal_void (tmp465) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__CHAR: tmp458 = lexing_engine (statmp452, statmp454) ; do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (tmp458 != 1) { goto __ats_lab_114_0 ; } __ats_lab_113_1: /* tmp459 = */ process_char_34 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp458 != 2) { goto __ats_lab_115_0 ; } __ats_lab_114_1: /* tmp460 = */ process_char_escaped_36 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (tmp458 != 3) { goto __ats_lab_116_0 ; } __ats_lab_115_1: /* tmp461 = */ process_char_oct_3_42 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: if (tmp458 != 4) { goto __ats_lab_117_0 ; } __ats_lab_116_1: /* tmp462 = */ process_char_oct_2_40 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: if (tmp458 != 5) { goto __ats_lab_118_0 ; } __ats_lab_117_1: /* tmp463 = */ process_char_oct_1_38 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: if (tmp458 != 6) { goto __ats_lab_119_0 ; } __ats_lab_118_1: /* tmp464 = */ process_char_hex_2_47 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: if (tmp458 != 7) { goto __ats_lab_120_0 ; } __ats_lab_119_1: /* tmp465 = */ process_char_hex_1_45 (arg0) ; tmp457 = LITERAL_char ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: if (tmp458 != 8) { goto __ats_lab_121_0 ; } __ats_lab_120_1: /* tmp457 = */ process_illegal_char_63 (arg0) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp457 = CHAR_lexing_error_2 (arg0) ; break ; } while (0) ; return (tmp457) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__CHAR] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 279674(line=1579, offs=18) -- 280277(line=1591, offs=42) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp471) ; ATSlocal (ats_int_type, tmp472) ; // ATSlocal_void (tmp473) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING: tmp472 = lexing_engine (statmp466, statmp468) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (tmp472 != 1) { goto __ats_lab_123_0 ; } __ats_lab_122_1: /* tmp473 = */ process_literal_string_59 (arg0, arg1, arg2) ; tmp471 = LITERAL_string ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: if (tmp472 != 2) { goto __ats_lab_124_0 ; } __ats_lab_123_1: arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING ; // tail call break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (tmp472 != 3) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp471 = STRING_char_escaped_53 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (tmp472 != 4) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp471 = STRING_char_oct_3_56 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: if (tmp472 != 5) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp471 = STRING_char_oct_2_55 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: if (tmp472 != 6) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp471 = STRING_char_oct_1_54 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: if (tmp472 != 7) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp471 = STRING_char_hex_2_58 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: if (tmp472 != 8) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp471 = STRING_char_hex_1_57 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: if (tmp472 != 9) { goto __ats_lab_131_0 ; } __ats_lab_130_1: /* tmp471 = */ process_unclosed_string_66 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (tmp472 != 10) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp471 = STRING_char_52 (arg0, arg1, arg2) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: __ats_lab_132_1: tmp471 = STRING_lexing_error_10 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp471) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__STRING] */ /* // /home/hwxi/research/Anairiats/src/ats_lexer_lats.dats: 285698(line=1607, offs=19) -- 286009(line=1612, offs=46) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp479) ; ATSlocal (ats_int_type, tmp480) ; // ATSlocal_void (tmp481) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE: tmp480 = lexing_engine (statmp474, statmp476) ; do { /* branch: __ats_lab_133 */ __ats_lab_133_0: if (tmp480 != 1) { goto __ats_lab_134_0 ; } __ats_lab_133_1: /* tmp481 = */ process_literal_extcode_61 (arg0, arg1, arg2, arg3) ; tmp479 = LITERAL_extcode ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (tmp480 != 2) { goto __ats_lab_135_0 ; } __ats_lab_134_1: /* tmp479 = */ process_unclosed_extcode_67 (arg0, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: if (tmp480 != 3) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp479 = EXTCODE_char_60 (arg0, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: __ats_lab_136_1: tmp479 = EXTCODE_lexing_error_12 (arg0, arg1, arg2, arg3) ; break ; } while (0) ; return (tmp479) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__EXTCODE] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__POSLSTcons_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp351, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp352, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp353, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp354, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp355, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp424, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp425, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp426, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp427, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp428, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp431, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp432, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp433, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp434, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp435, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp438, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp439, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp440, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp441, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp442, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp445, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp446, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp447, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp448, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp449, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp452, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp453, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp454, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp455, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp456, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp466, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp467, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp468, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp469, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp470, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp474, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp475, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp476, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp477, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp478, sizeof(ats_clo_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ /* statmp0 = */ ats_lexer_lats_initialize () ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_none, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_none = -1 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_i0de, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_i0de = YYBEG_i0de ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0rtid, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0rtid = YYBEG_s0rtid ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_si0de, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_si0de = YYBEG_si0de ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_di0de, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_di0de = YYBEG_di0de ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0exp, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_s0exp = YYBEG_s0exp ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0exp, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0exp = YYBEG_d0exp ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_sta, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_sta = YYBEG_d0ecseq_sta ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_dyn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__YYBEG_d0ecseq_dyn = YYBEG_d0ecseq_dyn ; statmp352 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (181) ; statmp351 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp352))) (statmp352, ATSstrcst("\000$\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000#\000#\000\002\000#\000#\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000#\000\025\000\"\000!\000 \000\037\000\005\000\036\000\035\000\034\000\005\000\005\000\033\000\005\000\005\000\032\000\031\000\030\000\030\000\030\000\030\000\030\000\030\000\030\000\030\000\030\000\005\000\027\000\026\000\005\000\026\000\025\000\024\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\023\000\022\000\021\000\005\000\007\000\020\000\017\000\007\000\016\000\007\000\007\000\015\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\014\000\007\000\013\000\007\000\n\000\007\000\t\000\010\000\007\000\007\000\007\000\006\000\005\000\004\000\003\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000,\000\265\000?\000?\000?\000?\000?\000?\000?\000?\000?\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000\260\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000\220\000U\000U\000U\000U\000U\000U\000U\000\217\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\216\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\204\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\203\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\177\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000z\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000p\000o\000U\000U\000n\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000i\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000V\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000T\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000L\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000K\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000J\000\000\000\000\000\000\000\000\000\000\000I\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000H\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000&\000&\000\000\000\000\000\000\000&\000&\000\000\000&\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000\000\000&\000\000\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000.\000\000\000\000\000\000\000.\000.\000\000\000.\000.\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000.\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000@\000\000\000?\000?\000?\000?\000?\000?\000?\000?\000?\000?\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000@\000\000\000?\000?\000?\000?\000?\000?\000?\000?\000?\000?\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000<\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000<\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\0009\000,\000\000\000,\000,\0008\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0003\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000/\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000-\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000&\000&\000\000\000\000\000\000\000&\000&\000\000\000&\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000\000\000&\000\000\000&\000&\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000\000\000\000\000\000\000&\000+\000&\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000\000\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000&\000&\000\000\000*\000\000\000&\000&\000\000\000&\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000\000\000&\000\000\000&\000&\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000)\000\000\000\000\000&\000(\000&\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000'\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000%\000%\000\000\000%\000%\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000%\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000%\000%\000\000\000%\000%\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000%\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000&\000&\000\000\000\000\000\000\000&\000&\000\000\000&\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000\000\000&\000\000\000&\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000(\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000\000\000\000\000\000\000\000\000(\000\000\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000(\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000+\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000\000\000\000\000\000\000\000\000+\000\000\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000+\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0002\0001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\0000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000.\000\000\000\000\000\000\000.\000.\000\000\000.\000.\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000.\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000.\000\000\000.\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000:\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000;\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000&\000\000\000&\000&\000,\000,\000\000\000\000\000\000\000,\000,\000\000\000,\000,\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000.\000,\000.\000&\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000,\000\000\000,\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000F\000\000\000F\000\000\000\000\000E\000E\000E\000E\000E\000E\000E\000E\000E\000E\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000@\000\000\000?\000?\000?\000?\000?\000?\000?\000?\000?\000?\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000@\000@\000@\000@\000@\000@\000@\000@\000@\000@\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000B\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000B\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000D\000\000\000D\000\000\000\000\000C\000C\000C\000C\000C\000C\000C\000C\000C\000C\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000C\000C\000C\000C\000C\000C\000C\000C\000C\000C\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000\000\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000\000\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000C\000C\000C\000C\000C\000C\000C\000C\000C\000C\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000E\000E\000E\000E\000E\000E\000E\000E\000E\000E\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000\000\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000A\000\000\000A\000\000\000\000\000\000\000\000\000\000\000A\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000E\000E\000E\000E\000E\000E\000E\000E\000E\000E\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000G\000G\000G\000G\000G\000G\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000P\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000O\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000M\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000N\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000R\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Q\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000S\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000Z\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\\\000U\000[\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000a\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000]\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000^\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000_\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000`\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000b\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000c\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000d\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000e\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000f\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000g\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000h\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000j\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000k\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000m\000\000\000l\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000w\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000s\000U\000U\000U\000U\000U\000r\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000q\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000v\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000t\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000u\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000x\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000y\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000{\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000|\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000~\000\000\000}\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\201\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\202\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\212\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\205\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\206\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\207\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\211\000\000\000\210\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000\213\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\215\000\000\000\214\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\246\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\245\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000\224\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\221\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\223\000\000\000\222\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\225\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\231\000\000\000\230\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\227\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\226\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\233\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\232\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\241\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\234\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\235\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\236\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\240\000\000\000\237\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000\242\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\244\000\000\000\243\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\254\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\247\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\250\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\251\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\253\000\000\000\252\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000\255\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\257\000\000\000\256\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000\261\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\262\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000\263\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000Y\000\000\000\000\000\000\000\000\000\000\000U\000\000\000\000\000\264\000\000\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000X\000\000\000\000\000\000\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000W\000\000\000\000\000\000\000U\000\000\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000U\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000@\000\000\000?\000?\000?\000?\000?\000?\000?\000?\000?\000?\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000<\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000>\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000=\000\000\000\000\000<\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp352) ; statmp355 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (181) ; statmp354 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp355))) (statmp355, 151) ; ATS_FREE(statmp355) ; statmp353 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp354))) (statmp354, ATSstrcst("\000$\000O\000\002\000P\000-\000L\0000\000K\000/\000H\000\"\000I\000\027\000D\000\022\000E\000T\000F\000\033\000C\0007\000G\0001\000M\000)\000A\000*\000@\000K\000>\0003\000<\0005\000:\000\004\0009\000\036\000J\0004\000;\000L\000=\000\021\0007\000\023\0006\000\006\0008\000\034\0005\000H\000?\000A\0003\000'\000B\0002\000N\000@\0002\000C\0002\000E\0002\000\030\0000\000?\0000\000\031\0000\000\265\0000\000G\0000\000&\000/\000\026\000/\000\037\000/\000,\000/\000\003\000/\000\020\000/\000\005\000/\000!\000/\000(\000.\000 \000/\000+\000-\000.\000/\000Y\000,\000\007\000)\000;\000(\000U\000)\000:\000/\000W\000*\000X\000+\000\025\000/\000=\0001\000\032\000/\0006\000%\000\202\000$\000\013\000)\000\035\0004\000N\000#\000S\000\"\000\227\000 \000\024\000/\000Q\000!\000x\000)\000w\000)\000n\000)\000t\000)\000s\000)\000u\000\036\000y\000\037\0009\000&\000\220\000)\000\237\000\033\000\221\000)\000\223\000\034\000\252\000\030\000\251\000\026\000\253\000\027\000\236\000\031\000\240\000\032\000\242\000)\000\241\000)\000\232\000)\000\244\000\024\000\257\000\022\000\256\000\023\000\226\000)\000\243\000\025\000\254\000)\000\216\000)\000\230\000\021\000\217\000)\000\210\000\017\000\t\000)\000\224\000)\000\211\000\016\000\225\000)\000\214\000\014\000\213\000)\000\215\000\013\000\207\000\015\000\n\000)\000{\000)\000|\000)\000~\000\t\000\014\000)\000h\000\010\000z\000)\000}\000\n\000\203\000)\000\212\000)\000d\000)\000c\000)\000\231\000\020\000a\000)\000`\000\007\000Z\000)\000\\\000)\000[\000)\000V\000)\000b\000)\000\245\000)\000\264\000\006\000\263\000)\000\262\000)\000\017\000)\000\255\000)\000\222\000\035\000\010\000)\000\260\000)\000v\000\005\000r\000)\000q\000\004\000o\000)\000m\000\003\000\015\000)\000k\000)\000i\000)\000j\000)\000l\000\002\000%\000\001\000#\000\001\000\016\000)\000p\000)\000\261\000)\0008\000'")) ; ATS_FREE(statmp354) ; statmp425 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (7) ; statmp424 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp425))) (statmp425, ATSstrcst("\000\005\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\004\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\002\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp425) ; statmp428 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (7) ; statmp427 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp428))) (statmp428, 7) ; ATS_FREE(statmp428) ; statmp426 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp427))) (statmp427, ATSstrcst("\000\002\000\003\000\005\000\006\000\006\000\001\000\001\000\003\000\004\000\004\000\003\000\005\000\007\000\002")) ; ATS_FREE(statmp427) ; statmp432 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (7) ; statmp431 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp432))) (statmp432, ATSstrcst("\000\005\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\004\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\002\000\002\000\002\000\002\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp432) ; statmp435 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (7) ; statmp434 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp435))) (statmp435, 7) ; ATS_FREE(statmp435) ; statmp433 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp434))) (statmp434, ATSstrcst("\000\002\000\003\000\006\000\002\000\005\000\006\000\003\000\004\000\001\000\003\000\007\000\001\000\004\000\005")) ; ATS_FREE(statmp434) ; statmp439 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (3) ; statmp438 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp439))) (statmp439, ATSstrcst("\000\003\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\002\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp439) ; statmp442 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (3) ; statmp441 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp442))) (statmp442, 2) ; ATS_FREE(statmp442) ; statmp440 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp441))) (statmp441, ATSstrcst("\000\003\000\002\000\002\000\001")) ; ATS_FREE(statmp441) ; statmp446 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (3) ; statmp445 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp446))) (statmp446, ATSstrcst("\000\003\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\002\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp446) ; statmp449 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (3) ; statmp448 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp449))) (statmp449, 2) ; ATS_FREE(statmp449) ; statmp447 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp448))) (statmp448, ATSstrcst("\000\003\000\002\000\002\000\001")) ; ATS_FREE(statmp448) ; statmp453 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (17) ; statmp452 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp453))) (statmp453, ATSstrcst("\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\021\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\004\000\000\000\000\000\000\000\000\000\004\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\006\000\006\000\006\000\006\000\006\000\006\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\005\000\000\000\000\000\004\000\004\000\000\000\000\000\000\000\000\000\004\000\004\000\000\000\000\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\004\000\000\000\000\000\000\000\004\000\000\000\004\000\000\000\004\000\000\000\005\000\000\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\020\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\n\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\t\000\t\000\t\000\t\000\t\000\t\000\t\000\t\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\013\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\016\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\017\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp453) ; statmp456 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (17) ; statmp455 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp456))) (statmp456, 9) ; ATS_FREE(statmp456) ; statmp454 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp455))) (statmp455, ATSstrcst("\000\016\000\007\000\017\000\006\000\n\000\004\000\013\000\003\000\010\000\005\000\003\000\010\000\020\000\002\000\002\000\010\000\021\000\001")) ; ATS_FREE(statmp455) ; statmp467 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (13) ; statmp466 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp467))) (statmp467, ATSstrcst("\000\005\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\004\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\t\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\006\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\010\000\010\000\010\000\010\000\010\000\010\000\010\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\007\000\000\000\000\000\006\000\006\000\000\000\000\000\000\000\000\000\006\000\006\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\006\000\000\000\006\000\000\000\006\000\000\000\007\000\000\000\000\000\006\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\014\000\014\000\014\000\014\000\014\000\014\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\n\000\n\000\n\000\n\000\n\000\n\000\n\000\n\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\013\000\013\000\013\000\013\000\013\000\013\000\013\000\013\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\015\000\015\000\015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp467) ; statmp470 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (13) ; statmp469 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp470))) (statmp470, 11) ; ATS_FREE(statmp470) ; statmp468 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp469))) (statmp469, ATSstrcst("\000\005\000\t\000\015\000\007\000\013\000\004\000\n\000\005\000\006\000\003\000\t\000\002\000\003\000\n\000\010\000\006\000\004\000\001\000\014\000\010\000\002\000\n")) ; ATS_FREE(statmp469) ; statmp475 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (5) ; statmp474 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp475))) (statmp475, ATSstrcst("\000\004\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp475) ; statmp478 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (5) ; statmp477 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp478))) (statmp478, 4) ; ATS_FREE(statmp478) ; statmp476 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp477))) (statmp477, ATSstrcst("\000\002\000\003\000\004\000\002\000\003\000\003\000\005\000\001")) ; ATS_FREE(statmp477) ; return ; } /* end of [dynload function] */ /* external codes at mid */ ats_void_type ats_lexer_lats_initialize () { return ; // HX: the function body is yet empty } // end of [ats_lexer_lats_initialize] /* ** HX: it declared in ats_lexer.sats */ ats_bool_type atsopt_token_is_valid (ats_int_type tok) { return (tok >= 0 ? ats_true_bool : ats_false_bool) ; } // end of [token_is_valid] /* external codes at bot */ ats_bool_type eq_token_token (ats_int_type tok1, ats_int_type tok2) { return (tok1 == tok2 ? ats_true_bool : ats_false_bool) ; } // end of [ats_bool_type eq_token_token] ats_bool_type ats_lexer_literal_int_check // HX: checking octal numbers (ats_ptr_type s0, ats_ptr_type err) { char c, *s = s0 ; // c = *s ; if (c != '0') return ats_true_bool ; ++s ; c = *s ; while (1) { if (isdigit (c)) { if (c >= '8') { *((char*)err) = c; return ats_false_bool ; } } else { return ats_true_bool ; } // end of [if] ++s ; c = *s ; } // end of [while] // return ats_true_bool ; } /* end of [ats_lexer_literal_int_check] */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_lexer_lats_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libats_lex_tables_dats.c0000664000175000017500000005315512223166160022741 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ // extern void free (void*) ; // ATSinline() ats_void_type table_ptr_free (ats_ptr_type p) { free (p) ; return ; } ATSinline() ats_int_type ats_int_of_int16 (ats_int16_type i) { return i ; } /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_some_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_none_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_mul_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_asl_int_int1) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, new_tbloptref_some) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, table_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, __accept_table_make_fun) (ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ats_int_of_int16) (ats_int16_type) ; ATSextern_fun(ats_ptr_type, __transition_table_make_fun) (ats_int_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__sasp__transition_table_t = 0 ; int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__sasp__accept_table_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_some_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_none_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01738_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type tbloptref_free_2 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_5 (ats_int_type env0, ats_int_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_5_closure_make (ats_int_type env0, ats_int_type env1) ; static ats_ptr_type __ats_fun_5_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_4 (ats_int_type env0, ats_int_type arg0) ; static ats_clo_ptr_type __ats_fun_4_closure_make (ats_int_type env0) ; static ats_clo_ptr_type __ats_fun_4_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0) ; static ats_ptr_type __ats_fun_9 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_9_closure_make (ats_int_type env0) ; static ats_ptr_type __ats_fun_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01738_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ref_make_elt_01738_ats_ptr_type: /* ats_ptr_type tmp3 ; */ tmp3 = arg0 ; tmp2 = atspre_ref_make_elt_tsz ((&tmp3), sizeof(ats_ptr_type)) ; return (tmp2) ; } /* end of [ref_make_elt_01738_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 2102(line=62, offs=30) -- 2195(line=64, offs=4) */ ATSglobaldec() ats_ptr_type new_tbloptref_some (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_new_tbloptref_some: tmp1 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_1, arg1) ; tmp0 = ref_make_elt_01738_ats_ptr_type (tmp1) ; return (tmp0) ; } /* end of [new_tbloptref_some] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 2545(line=84, offs=4) -- 2866(line=93, offs=4) */ ATSstaticdec() ats_void_type tbloptref_free_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_tbloptref_free_2: tmp5 = atspre_ref_get_view_ptr (arg0) ; tmp6 = ats_selsin_mac(tmp5, atslab_1) ; tmp7 = ats_ptrget_mac(ats_ptr_type, tmp6) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp7 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_0, tmp7, atslab_0) ; ATS_FREE(tmp7) ; /* tmp9 = */ table_ptr_free (tmp8) ; tmp10 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp6) = tmp10 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp7 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp4) */ ; } /* end of [tbloptref_free_2] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 3168(line=106, offs=50) -- 3218(line=107, offs=42) */ ATSstaticdec() ats_ptr_type __ats_fun_5 (ats_int_type env0, ats_int_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; __ats_lab___ats_fun_5: tmp13 = __accept_table_make_fun (env0, env1, arg0) ; return (tmp13) ; } /* end of [__ats_fun_5] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_int_type closure_env_1 ; } __ats_fun_5_closure_type ; ats_ptr_type __ats_fun_5_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_5 (((__ats_fun_5_closure_type*)cloptr)->closure_env_0, ((__ats_fun_5_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_5_closure_init (__ats_fun_5_closure_type *p_clo, ats_int_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_5_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_5_closure_make (ats_int_type env0, ats_int_type env1) { __ats_fun_5_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_5_closure_type)) ; __ats_fun_5_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 3156(line=106, offs=38) -- 3218(line=107, offs=42) */ ATSstaticdec() ats_clo_ptr_type __ats_fun_4 (ats_int_type env0, ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; __ats_lab___ats_fun_4: tmp12 = __ats_fun_5_closure_make (env0, arg0) ; return (tmp12) ; } /* end of [__ats_fun_4] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } __ats_fun_4_closure_type ; ats_clo_ptr_type __ats_fun_4_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0) { return __ats_fun_4 (((__ats_fun_4_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_4_closure_init (__ats_fun_4_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_4_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_4_closure_make (ats_int_type env0) { __ats_fun_4_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_4_closure_type)) ; __ats_fun_4_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 3149(line=106, offs=31) -- 3218(line=107, offs=42) */ ATSglobaldec() ats_clo_ptr_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make: tmp11 = __ats_fun_4_closure_make (arg0) ; return (tmp11) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 3250(line=109, offs=31) -- 3294(line=110, offs=26) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_free: /* tmp14 = */ tbloptref_free_2 (arg0) ; return /* (tmp14) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_free] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 3479(line=124, offs=28) -- 4511(line=153, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__accept_table_get (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp15) ; ATSlocal (ats_int_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_bool_type, tmp24) ; ATSlocal (ats_bool_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_int16_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__accept_table_get: /* ats_int_type tmp16 ; */ tmp16 = 0 ; /* ats_int_type tmp17 ; */ tmp17 = 0 ; tmp18 = atspre_ref_get_view_ptr (arg0) ; tmp19 = ats_selsin_mac(tmp18, atslab_1) ; tmp21 = ats_ptrget_mac(ats_ptr_type, tmp19) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp21 != (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp17 = 1 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp21 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_0, tmp21, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_0, tmp21, atslab_1) ; tmp24 = atspre_ilt (ats_castfn_mac(ats_int_type, arg1), 0) ; if (tmp24) { tmp17 = 2 ; } else { tmp25 = atspre_igte (ats_castfn_mac(ats_int_type, arg1), tmp23) ; if (tmp25) { tmp17 = 3 ; } else { tmp27 = ats_caselptrind_mac(ats_int16_type, tmp22, [ats_castfn_mac(ats_int_type, arg1)]) ; tmp26 = ats_int_of_int16 (tmp27) ; tmp16 = tmp26 ; } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp17 != 1) { goto __ats_lab_5_0 ; } __ats_lab_4_1: /* tmp15 = */ ats_exit_errmsg (1, ATSstrcst("lexing: accept_table_get: table is not available\n")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (tmp17 != 2) { goto __ats_lab_6_0 ; } __ats_lab_5_1: /* tmp15 = */ ats_exit_errmsg (1, ATSstrcst("lexing: accept_table_get: state number is illegal\n")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp17 != 3) { goto __ats_lab_7_0 ; } __ats_lab_6_1: /* tmp15 = */ ats_exit_errmsg (1, ATSstrcst("lexing: accept_table_get: state number is illegal\n")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp15 = tmp16 ; break ; } while (0) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__accept_table_get] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 4911(line=168, offs=39) -- 4956(line=169, offs=37) */ ATSstaticdec() ats_ptr_type __ats_fun_9 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; __ats_lab___ats_fun_9: tmp29 = __transition_table_make_fun (env0, arg0) ; return (tmp29) ; } /* end of [__ats_fun_9] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } __ats_fun_9_closure_type ; ats_ptr_type __ats_fun_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_9 (((__ats_fun_9_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_9_closure_init (__ats_fun_9_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_9_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_9_closure_make (ats_int_type env0) { __ats_fun_9_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_9_closure_type)) ; __ats_fun_9_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 4907(line=168, offs=35) -- 4956(line=169, offs=37) */ ATSglobaldec() ats_clo_ptr_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make: tmp28 = __ats_fun_9_closure_make (arg0) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 4992(line=171, offs=35) -- 5036(line=172, offs=26) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_free: /* tmp30 = */ tbloptref_free_2 (arg0) ; return /* (tmp30) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_free] */ /* // /home/hwxi/research/Anairiats/src/libats_lex_tables.dats: 5069(line=174, offs=32) -- 6958(line=228, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__transition_table_get (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_int_type, tmp32) ; ATSlocal (ats_int_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_bool_type, tmp41) ; ATSlocal (ats_int_type, tmp42) ; ATSlocal (ats_int_type, tmp43) ; ATSlocal (ats_int_type, tmp44) ; ATSlocal (ats_int_type, tmp45) ; ATSlocal (ats_int_type, tmp46) ; ATSlocal (ats_int_type, tmp47) ; ATSlocal (ats_int_type, tmp48) ; ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_int16_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__transition_table_get: /* ats_int_type tmp32 ; */ tmp32 = 0 ; /* ats_int_type tmp33 ; */ tmp33 = 0 ; tmp34 = atspre_ref_get_view_ptr (arg0) ; tmp35 = ats_selsin_mac(tmp34, atslab_1) ; tmp37 = ats_ptrget_mac(ats_ptr_type, tmp35) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp37 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_0, tmp37, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_0, tmp37, atslab_1) ; tmp42 = atspre_asl_int_int1 (1, 7) ; tmp41 = atspre_lt_int_int (arg2, tmp42) ; if (tmp41) { tmp40 = arg2 ; } else { tmp40 = 0 ; } /* end of [if] */ tmp43 = atspre_add_int_int (tmp40, 1) ; tmp46 = atspre_sub_int_int (arg1, 1) ; tmp48 = atspre_asl_int_int1 (1, 7) ; tmp47 = atspre_add_int_int (tmp48, 1) ; tmp45 = atspre_mul_int_int (tmp46, tmp47) ; tmp44 = atspre_add_int_int (tmp45, tmp43) ; tmp49 = atspre_ilt (ats_castfn_mac(ats_int_type, tmp44), 0) ; if (tmp49) { tmp33 = 2 ; } else { tmp50 = atspre_igte (ats_castfn_mac(ats_int_type, tmp44), tmp39) ; if (tmp50) { tmp33 = 3 ; } else { tmp52 = ats_caselptrind_mac(ats_int16_type, tmp38, [ats_castfn_mac(ats_int_type, tmp44)]) ; tmp51 = ats_int_of_int16 (tmp52) ; tmp32 = tmp51 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp37 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp33 = 1 ; break ; } while (0) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (tmp33 != 1) { goto __ats_lab_11_0 ; } __ats_lab_10_1: /* tmp31 = */ ats_exit_errmsg (1, ATSstrcst("lexing: transition_table_get: table is not available\n")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (tmp33 != 2) { goto __ats_lab_12_0 ; } __ats_lab_11_1: /* tmp31 = */ ats_exit_errmsg (1, ATSstrcst("lexing: transition_table_get: state number is illegal\n")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp33 != 3) { goto __ats_lab_13_0 ; } __ats_lab_12_1: /* tmp31 = */ ats_exit_errmsg (1, ATSstrcst("lexing: transition_table_get: state number is illegal\n")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp31 = tmp32 ; break ; } while (0) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__transition_table_get] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_some_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__tblopt_none_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_tables_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ #define NBITS_PER_BYTE 8 /* ** NUMBER_OF_CHARS = 128 + 1 */ #define NUMBER_OF_CHARS ((1 << (NBITS_PER_BYTE - 1)) + 1) ats_ptr_type __accept_table_make_fun (ats_int_type ntot, ats_int_type nfin, ats_ptr_type s0) { int i, nstate, irule, sz ; ats_int16_type *p0 ; ats_uchar_type *s ; ats_ptr_type res ; s = (ats_uchar_type*)s0; // [calloc] is used as only integers are to be stored; thus, // there is no need to scan the allocated memory during GC; // the allocated memory is freed by a call to [free] sz = ntot + 1 ; p0 = calloc (sz, sizeof(ats_int16_type)) ; for (i = 0 ; i < nfin ; ++i) { nstate = (s[0] << NBITS_PER_BYTE) + s[1] ; s += 2 ; p0[nstate] = (s[0] << NBITS_PER_BYTE) + s[1] ; s += 2 ; /* fprintf (stdout, "%i -> %i\n", nstate, p0[nstate]) ; */ } /* end of [for] */ res = new_tbloptref_some (p0, sz) ; /* fprintf (stdout, "__accept_table_make_fun: sz = %i\n", sz); fprintf (stdout, "__accept_table_make_fun: ptr = %p\n", p0); fprintf (stdout, "__accept_table_make_fun: res = %p\n", res); */ return res ; } /* end of [__accept_table_make_fun] */ ats_ptr_type __transition_table_make_fun (ats_int_type n, ats_ptr_type s0) { int i, j, sz; ats_int16_type *p0, *p ; ats_uchar_type *s ; ats_ptr_type res ; sz = n * NUMBER_OF_CHARS ; // [malloc] is used as only integers are to be stored; thus, // there is no need to scan the allocated memory during GC; // the allocated memory is freed by a call to [free] p0 = malloc (sz*sizeof(ats_int16_type)) ; p = p0 ; s = (ats_uchar_type*)s0; for (i = 0 ; i < n ; ++i) { for (j = 0 ; j < NUMBER_OF_CHARS ; ++j) { *p = (s[0] << NBITS_PER_BYTE) + s[1] ; /* fprintf (stdout, "__transition_table_make_fun: %i: *p = %i\n", j, *p); */ s += 2 ; ++p ; } /* end of [for] */ } /* end of [for] */ res = new_tbloptref_some (p0, sz) ; /* fprintf (stdout, "__transition_table_make_fun: sz = %i\n", sz); fprintf (stdout, "__transition_table_make_fun: ptr = %p\n", p0); fprintf (stdout, "__transition_table_make_fun: res = %p\n", res); */ return res ; } /* end of [__transition_table_make_fun] */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libats_lex_tables_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_reference_sats.c0000664000175000017500000000201012223166160022065 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_reference_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_charlst_dats.c0000664000175000017500000002366512223166160021573 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ ATSextfun() ats_char_type atsopt_charlst_uncons (ats_ref_type) ; ats_ptr_type string_make_charlst_rev_int ( ats_ptr_type cs, ats_int_type n ) { char *s; s = ATS_MALLOC (n+1) ; s += n ; *s = '\000' ; while (!atsopt_charlst_is_nil(cs)) { *--s = atsopt_charlst_uncons(&cs) ; } return s ; } // end of [string_make_charlst_rev_int] /* type definitions */ typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, string_make_charlst_rev_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_charlst_is_nil) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atsopt_charlst_uncons) (ats_ref_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_int_type aux_2 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type loop_4 (ats_ptr_type arg0, ats_size_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 1580(line=42, offs=14) -- 1675(line=44, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 1781(line=50, offs=7) -- 2037(line=57, offs=6) */ ATSstaticdec() ats_int_type aux_2 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; __ats_lab_aux_2: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp4 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp5 = ats_ptrget_mac(ats_ptr_type, tmp4) ; tmp6 = atspre_iadd (arg1, 1) ; arg0 = tmp5 ; arg1 = tmp6 ; goto __ats_lab_aux_2 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp3 = arg1 ; break ; } while (0) ; return (tmp3) ; } /* end of [aux_2] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 1748(line=49, offs=16) -- 2055(line=58, offs=2) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_length (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_length: tmp2 = aux_2 (arg0, 0) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_length] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 2186(line=65, offs=7) -- 2395(line=70, offs=12) */ ATSstaticdec() ats_ptr_type loop_4 (ats_ptr_type arg0, ats_size_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_bool_type, tmp9) ; ATSlocal (ats_size_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_char_type, tmp12) ; __ats_lab_loop_4: tmp9 = atspre_string_isnot_atend (arg0, arg1) ; if (tmp9) { tmp10 = atspre_add_size1_int1 (arg1, 1) ; tmp12 = atspre_string_get_char_at (arg0, arg1) ; tmp11 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp11, atslab_0, tmp12) ; ats_selptrset_mac(anairiats_sum_0, tmp11, atslab_1, arg2) ; arg0 = arg0 ; arg1 = tmp10 ; arg2 = tmp11 ; goto __ats_lab_loop_4 ; // tail call } else { tmp8 = arg2 ; } /* end of [if] */ return (tmp8) ; } /* end of [loop_4] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 2142(line=64, offs=3) -- 2416(line=72, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string: tmp7 = loop_4 (arg1, 0, arg0) ; return (tmp7) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_add_string] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 2504(line=77, offs=25) -- 2574(line=79, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_int_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev: tmp14 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__charlst_length (arg0) ; tmp13 = string_make_charlst_rev_int (arg0, tmp14) ; return (tmp13) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 2787(line=89, offs=16) -- 2879(line=90, offs=74) */ ATSglobaldec() ats_bool_type atsopt_charlst_is_nil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp15) ; __ats_lab_atsopt_charlst_is_nil: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp15 = ats_false_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp15 = ats_true_bool ; break ; } while (0) ; return (tmp15) ; } /* end of [atsopt_charlst_is_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_charlst.dats: 3094(line=101, offs=16) -- 3160(line=102, offs=60) */ ATSglobaldec() ats_char_type atsopt_charlst_uncons (ats_ref_type arg0) { /* local vardec */ ATSlocal (ats_char_type, tmp16) ; ATSlocal (ats_char_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_atsopt_charlst_uncons: // if (ats_ptrget_mac(ats_ptr_type, arg0) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp17 = ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg0), atslab_0) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg0), atslab_1) ; ATS_FREE(ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp18 ; tmp16 = tmp17 ; return (tmp16) ; } /* end of [atsopt_charlst_uncons] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_charlst_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_array_sats.c0000664000175000017500000000176412223166160021264 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_array_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp3_print_dats.c0000664000175000017500000024610112223166160022731 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_d3lab1_loc ; ats_ptr_type atslab_d3lab1_node ; } anairiats_rec_18 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvbox_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrinit_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrpsz_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_ptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_var_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ebool_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecaseof_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Echar_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Econ_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecstsp_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecrypt_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eextval_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efix_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloatsp_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efoldat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efreeat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eif_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eint_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eintsp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_dyn_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elaminit_dyn_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_met_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_sta_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_delay_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_ldelay_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_force_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elet_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloop_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloopexn_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elst_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eraise_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erec_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erefarg_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Escaseof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esif_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estring_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estruct_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etrywith_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_ptr_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_var_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ewhere_59) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 1905(line=60, offs=13) -- 4436(line=144, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; ATSlocal (ats_bool_type, tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; ATSlocal (ats_bool_type, tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; ATSlocal (ats_char_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_int_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_int_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; ATSlocal (ats_bool_type, tmp57) ; // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_p3at_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tann(")) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (arg0, tmp2) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp3) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; /* tmp9 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tany(")) ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp8) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_1) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_2) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tas(")) ; tmp16 = atspre_gt_int_int (tmp11, 0) ; if (tmp16) { /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst("!")) ; } else { /* empty */ } /* end of [if] */ /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp12) ; /* tmp18 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (arg0, tmp13) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp1)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_0) ; /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tbool(")) ; /* tmp22 = */ atspre_fprint_bool (arg0, tmp20) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp1)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tchar(")) ; /* tmp25 = */ atspre_fprint_char (arg0, tmp23) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp1)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_1) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_2) ; tmp29 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_3) ; /* tmp30 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tcon(")) ; /* tmp31 = */ atspre_fprint_int (arg0, tmp26) ; /* tmp32 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp27) ; /* tmp34 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp35 = */ atspre_fprint_int (arg0, tmp28) ; /* tmp36 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst (arg0, tmp29) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp1)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tempty()")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp1)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp40 = */ atspre_fprint_string (arg0, ATSstrcst("P3Texist(")) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp38) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (arg0, tmp39) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp1)->tag != 8) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; /* tmp0 = */ atspre_fprintf_exn (arg0, ATSstrcst("P3Tfloat(%s)"), tmp44) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp1)->tag != 9) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; /* tmp0 = */ atspre_fprintf_exn (arg0, ATSstrcst("P3Tint(%s)"), tmp45) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp1)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tlst(")) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp46) ; /* tmp50 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst (arg0, tmp47) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp1)->tag != 11) { goto __ats_lab_12_0 ; } __ats_lab_11_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("P3Trec(...)")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp1)->tag != 12) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; /* tmp0 = */ atspre_fprintf_exn (arg0, ATSstrcst("P3Tstring(\"%s\")"), tmp52) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp1)->tag != 13) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_8, tmp1, atslab_0) ; tmp54 = ats_caselptrlab_mac(anairiats_sum_8, tmp1, atslab_1) ; /* tmp55 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tvar(")) ; tmp57 = atspre_gt_int_int (tmp53, 0) ; if (tmp57) { /* tmp56 = */ atspre_fprint_string (arg0, ATSstrcst("!")) ; } else { /* empty */ } /* end of [if] */ /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp54) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (((ats_sum_ptr_type)tmp1)->tag != 14) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst("P3Tvbox(")) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp59) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 4483(line=146, offs=22) -- 4519(line=146, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_p3at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_p3at: tmp63 = atspre_stdout_get () ; tmp64 = ats_selsin_mac(tmp63, atslab_1) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (tmp64, arg0) ; /* tmp62 = */ atspre_stdout_view_set () ; return /* (tmp62) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_p3at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 4541(line=147, offs=22) -- 4577(line=147, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at: tmp67 = atspre_stderr_get () ; tmp68 = ats_selsin_mac(tmp67, atslab_1) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at (tmp68, arg0) ; /* tmp66 = */ atspre_stderr_view_set () ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 4625(line=152, offs=16) -- 4699(line=153, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp70) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst: /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3at) ; return /* (tmp70) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 4772(line=159, offs=14) -- 16572(line=531, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_int_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; // ATSlocal_void (tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; // ATSlocal_void (tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; ATSlocal (ats_bool_type, tmp125) ; ATSlocal (ats_char_type, tmp126) ; // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; // ATSlocal_void (tmp132) ; // ATSlocal_void (tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; // ATSlocal_void (tmp139) ; // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; // ATSlocal_void (tmp142) ; // ATSlocal_void (tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; // ATSlocal_void (tmp146) ; // ATSlocal_void (tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; // ATSlocal_void (tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; // ATSlocal_void (tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_int_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; // ATSlocal_void (tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; // ATSlocal_void (tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_int_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; // ATSlocal_void (tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; // ATSlocal_void (tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; ATSlocal (ats_int_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_int_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; // ATSlocal_void (tmp264) ; // ATSlocal_void (tmp265) ; // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; ATSlocal (ats_int_type, tmp283) ; ATSlocal (ats_int_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; // ATSlocal_void (tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; // ATSlocal_void (tmp289) ; // ATSlocal_void (tmp290) ; // ATSlocal_void (tmp291) ; ATSlocal (ats_int_type, tmp292) ; ATSlocal (ats_int_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; // ATSlocal_void (tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; // ATSlocal_void (tmp332) ; // ATSlocal_void (tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; // ATSlocal_void (tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; // ATSlocal_void (tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; // ATSlocal_void (tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; // ATSlocal_void (tmp368) ; // ATSlocal_void (tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; // ATSlocal_void (tmp371) ; // ATSlocal_void (tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp: tmp72 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_node) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp72)->tag != 0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp74 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp75 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eann_type(")) ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp73) ; /* tmp77 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp74) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp72)->tag != 1) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_1) ; tmp81 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_2) ; /* tmp82 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eapp_dyn(")) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp79) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp85 = */ atspre_fprint_int (arg0, tmp80) ; /* tmp86 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp81) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp72)->tag != 2) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp89 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eapp_sta(")) ; /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp88) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp72)->tag != 3) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp92 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp93 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp94 = */ atspre_fprint_string (arg0, ATSstrcst("D3Earrinit(")) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp91) ; /* tmp96 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp92 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_12, tmp92, atslab_0) ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp98) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (tmp92 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: break ; } while (0) ; /* tmp99 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp93) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp72)->tag != 4) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp103 = */ atspre_fprint_string (arg0, ATSstrcst("D3Earrpsz(")) ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp101) ; /* tmp105 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp102) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp72)->tag != 5) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp110 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eassgn_ptr(")) ; /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp107) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp113 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp108) ; /* tmp114 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp109) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp72)->tag != 6) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp117 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp118 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp119 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eassgn_val(")) ; /* tmp120 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp116) ; /* tmp121 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp117) ; /* tmp123 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp118) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp72)->tag != 7) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp125 = ats_caselptrlab_mac(anairiats_sum_4, tmp72, atslab_0) ; if (tmp125) { /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ebool(true)")) ; } else { /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ebool(false)")) ; } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp72)->tag != 8) { goto __ats_lab_26_0 ; } __ats_lab_25_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ecaseof(...)")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp72)->tag != 9) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_5, tmp72, atslab_0) ; /* tmp127 = */ atspre_fprint_string (arg0, ATSstrcst("D3Echar(")) ; /* tmp128 = */ atspre_fprint_char (arg0, tmp126) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp72)->tag != 10) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp129 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_0) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_1) ; tmp131 = ats_caselptrlab_mac(anairiats_sum_10, tmp72, atslab_2) ; /* tmp132 = */ atspre_fprint_string (arg0, ATSstrcst("D3Econ(")) ; /* tmp133 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp129) ; /* tmp134 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp135 = */ atspre_fprint_int (arg0, tmp130) ; /* tmp136 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp137 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp131) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp72)->tag != 11) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp138 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp139 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ecst(")) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp138) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp72)->tag != 12) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp142 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ecstsp(")) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (arg0, tmp141) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp72)->tag != 13) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_8, tmp72, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_8, tmp72, atslab_1) ; /* tmp146 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ecrypt(")) ; /* tmp147 = */ atspre_fprint_int (arg0, tmp144) ; /* tmp148 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp145) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp72)->tag != 14) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp150 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp151 = */ atspre_fprint_string (arg0, ATSstrcst("D3Edynload(")) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp150) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp72)->tag != 15) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp153 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp155 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eeffmask(")) ; /* tmp156 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst (arg0, tmp153) ; /* tmp157 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp154) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp72)->tag != 16) { goto __ats_lab_34_0 ; } __ats_lab_33_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eempty()")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp72)->tag != 17) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Eextval(\"%s\")"), tmp159) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp72)->tag != 18) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_0) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_1) ; tmp162 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_2) ; /* tmp163 = */ atspre_fprint_string (arg0, ATSstrcst("D3Efix(")) ; /* tmp164 = */ atspre_fprint_int (arg0, tmp160) ; /* tmp165 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp166 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp161) ; /* tmp167 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp162) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp72)->tag != 19) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Efloat(%s)"), tmp169) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp72)->tag != 20) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Efloatsp(%s)"), tmp170) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp72)->tag != 21) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("D3Efoldat(")) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp171) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp72)->tag != 22) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp175 = */ atspre_fprint_string (arg0, ATSstrcst("D3Efreeat(")) ; /* tmp176 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp174) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp72)->tag != 23) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp178 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eif(")) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp177) ; /* tmp182 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp178) ; /* tmp184 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp179) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp72)->tag != 24) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Eint(%s)"), tmp186) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp72)->tag != 25) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp187 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Eintsp(%s)"), tmp187) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp72)->tag != 26) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp188 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_0) ; tmp189 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_1) ; tmp190 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_2) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_3) ; /* tmp192 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elam_dyn(")) ; /* tmp193 = */ atspre_fprint_int (arg0, tmp188) ; /* tmp194 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp195 = */ atspre_fprint_int (arg0, tmp189) ; /* tmp196 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst (arg0, tmp190) ; /* tmp198 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp199 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp191) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp72)->tag != 27) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp200 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_0) ; tmp201 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_1) ; tmp202 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_2) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_13, tmp72, atslab_3) ; /* tmp204 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elaminit_dyn(")) ; /* tmp205 = */ atspre_fprint_int (arg0, tmp200) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp207 = */ atspre_fprint_int (arg0, tmp201) ; /* tmp208 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp209 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_p3atlst (arg0, tmp202) ; /* tmp210 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp211 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp203) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp72)->tag != 28) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp213 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp214 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elam_met(")) ; /* tmp215 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp212) ; /* tmp216 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp217 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp213) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp72)->tag != 29) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp219 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp221 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elam_sta(")) ; /* tmp222 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp218) ; /* tmp223 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp219) ; /* tmp225 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp226 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp220) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp72)->tag != 30) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp228 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elazy_delay(")) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp227) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp72)->tag != 31) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp230 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp232 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elazy_delay(")) ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp230) ; /* tmp234 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp235 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp231) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp72)->tag != 32) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_8, tmp72, atslab_0) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_8, tmp72, atslab_1) ; /* tmp238 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elazy_force(")) ; /* tmp239 = */ atspre_fprint_int (arg0, tmp236) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp237) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp72)->tag != 33) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp243 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elet(")) ; /* tmp244 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp245 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp246 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp242) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp72)->tag != 34) { goto __ats_lab_56_0 ; } __ats_lab_51_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_0) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_1) ; tmp249 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_2) ; tmp250 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_3) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eloop(")) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp247 != (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (tmp247 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_12, tmp247, atslab_0) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp253) ; break ; } while (0) ; /* tmp254 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp255 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp248) ; /* tmp256 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (tmp249 != (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (tmp249 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_12, tmp249, atslab_0) ; /* tmp257 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp258) ; break ; } while (0) ; /* tmp259 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp250) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp72)->tag != 35) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp261 = ats_caselptrlab_mac(anairiats_sum_15, tmp72, atslab_0) ; /* tmp71 = */ atspre_fprintf_exn (arg0, ATSstrcst("D3Eloopexn(%i)"), tmp261) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp72)->tag != 36) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_1) ; tmp263 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_2) ; /* tmp264 = */ atspre_fprint_string (arg0, ATSstrcst("D3Elst(")) ; /* tmp265 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp262) ; /* tmp266 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp267 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp263) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp72)->tag != 37) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp268 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp269 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp270 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eptrof_ptr(")) ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp268) ; /* tmp272 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp269) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp72)->tag != 38) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp274 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp276 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eptrof_var(")) ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp274) ; /* tmp278 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp279 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp275) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp72)->tag != 39) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp281 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eraise(")) ; /* tmp282 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp280) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp72)->tag != 40) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp283 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_0) ; tmp284 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_1) ; tmp285 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_2) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("D3Erec(")) ; /* tmp287 = */ atspre_fprint_int (arg0, tmp283) ; /* tmp288 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp289 = */ atspre_fprint_int (arg0, tmp284) ; /* tmp290 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst (arg0, tmp285) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp72)->tag != 41) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp292 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_0) ; tmp293 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_1) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_7, tmp72, atslab_2) ; /* tmp295 = */ atspre_fprint_string (arg0, ATSstrcst("D3Erefarg(")) ; /* tmp296 = */ atspre_fprint_int (arg0, tmp292) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp298 = */ atspre_fprint_int (arg0, tmp293) ; /* tmp299 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp300 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp294) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp72)->tag != 42) { goto __ats_lab_64_0 ; } __ats_lab_63_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Escaseof(...)")) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp72)->tag != 43) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp301 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp303 = */ atspre_fprint_string (arg0, ATSstrcst("D3Esel(")) ; /* tmp304 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp301) ; /* tmp305 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp306 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp302) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp72)->tag != 44) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp307 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp308 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp309 = */ atspre_fprint_string (arg0, ATSstrcst("D3Esel_ptr(")) ; /* tmp310 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp307) ; /* tmp311 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp312 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp308) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp72)->tag != 45) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp313 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp314 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp315 = */ atspre_fprint_string (arg0, ATSstrcst("D3Esel_var(")) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp313) ; /* tmp317 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp318 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp314) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp72)->tag != 46) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp319 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp320 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eseq(")) ; /* tmp321 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (arg0, tmp319) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp72)->tag != 47) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp323 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp324 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp325 = */ atspre_fprint_string (arg0, ATSstrcst("D3Esif(")) ; /* tmp326 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp322) ; /* tmp327 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp328 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp323) ; /* tmp329 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp330 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp324) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp72)->tag != 48) { goto __ats_lab_70_0 ; } __ats_lab_69_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Estring(...)")) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp72)->tag != 49) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp332 = */ atspre_fprint_string (arg0, ATSstrcst("D3Estruct(")) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst (arg0, tmp331) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp72)->tag != 50) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp334 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp335 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp336 = */ atspre_fprint_string (arg0, ATSstrcst("D3Etmpcst(")) ; /* tmp337 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp334) ; /* tmp338 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp339 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp335) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp72)->tag != 51) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_1) ; /* tmp342 = */ atspre_fprint_string (arg0, ATSstrcst("D3Etmpvar(")) ; /* tmp343 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp340) ; /* tmp344 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp341) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp72)->tag != 52) { goto __ats_lab_74_0 ; } __ats_lab_73_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Etop()")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp72)->tag != 53) { goto __ats_lab_75_0 ; } __ats_lab_74_1: /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst("D3Etrywith(...)")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp72)->tag != 54) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_2, tmp72, atslab_0) ; /* tmp347 = */ atspre_fprint_string (arg0, ATSstrcst("D3Evar(")) ; /* tmp348 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp346) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp72)->tag != 55) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp352 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eviewat_assgn_ptr(")) ; /* tmp353 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp349) ; /* tmp354 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp350) ; /* tmp356 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp357 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp351) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp72)->tag != 56) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_0) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_1) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_11, tmp72, atslab_2) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eviewat_assgn_var(")) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp358) ; /* tmp363 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (arg0, tmp359) ; /* tmp365 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp366 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp360) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp72)->tag != 57) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp367 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_0) ; /* tmp368 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eviewat_ptr(")) ; /* tmp369 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp367) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp72)->tag != 58) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_14, tmp72, atslab_0) ; /* tmp371 = */ atspre_fprint_string (arg0, ATSstrcst("D3Eviewat_var(")) ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp370) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (((ats_sum_ptr_type)tmp72)->tag != 59) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_1, tmp72, atslab_0) ; /* tmp374 = */ atspre_fprint_string (arg0, ATSstrcst("D3Ewhere(")) ; /* tmp375 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp373) ; /* tmp376 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp377 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp71 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp71) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 16621(line=533, offs=23) -- 16658(line=533, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; // ATSlocal_void (tmp381) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3exp: tmp379 = atspre_stdout_get () ; tmp380 = ats_selsin_mac(tmp379, atslab_1) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (tmp380, arg0) ; /* tmp378 = */ atspre_stdout_view_set () ; return /* (tmp378) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 16681(line=534, offs=23) -- 16718(line=534, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; // ATSlocal_void (tmp385) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3exp: tmp383 = atspre_stderr_get () ; tmp384 = ats_selsin_mac(tmp383, atslab_1) ; /* tmp385 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (tmp384, arg0) ; /* tmp382 = */ atspre_stderr_view_set () ; return /* (tmp382) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 16767(line=539, offs=17) -- 16843(line=540, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp386) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst: /* tmp386 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp) ; return /* (tmp386) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 16898(line=543, offs=26) -- 16940(line=543, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; // ATSlocal_void (tmp390) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explst: tmp388 = atspre_stdout_get () ; tmp389 = ats_selsin_mac(tmp388, atslab_1) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (tmp389, arg0) ; /* tmp387 = */ atspre_stdout_view_set () ; return /* (tmp387) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 16966(line=544, offs=26) -- 17008(line=544, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; // ATSlocal_void (tmp394) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explst: tmp392 = atspre_stderr_get () ; tmp393 = ats_selsin_mac(tmp392, atslab_1) ; /* tmp394 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst (tmp393, arg0) ; /* tmp391 = */ atspre_stderr_view_set () ; return /* (tmp391) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17060(line=549, offs=20) -- 17144(line=550, offs=67) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp395) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst: /* tmp395 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explst) ; return /* (tmp395) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17205(line=553, offs=29) -- 17252(line=553, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; // ATSlocal_void (tmp399) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explstlst: tmp397 = atspre_stdout_get () ; tmp398 = ats_selsin_mac(tmp397, atslab_1) ; /* tmp399 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst (tmp398, arg0) ; /* tmp396 = */ atspre_stdout_view_set () ; return /* (tmp396) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_d3explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17281(line=554, offs=29) -- 17328(line=554, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; // ATSlocal_void (tmp403) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explstlst: tmp401 = atspre_stderr_get () ; tmp402 = ats_selsin_mac(tmp401, atslab_1) ; /* tmp403 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst (tmp402, arg0) ; /* tmp400 = */ atspre_stderr_view_set () ; return /* (tmp400) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17417(line=561, offs=7) -- 17855(line=573, offs=8) */ ATSstaticdec() ats_void_type aux_14 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; // ATSlocal_void (tmp409) ; ATSlocal (ats_bool_type, tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; ATSlocal (ats_int_type, tmp414) ; __ats_lab_aux_14: do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp406 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_0) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_1) ; tmp408 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_2) ; tmp410 = atspre_gt_int_int (arg1, 0) ; if (tmp410) { /* tmp409 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp411 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp406) ; /* tmp412 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp413 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp407) ; tmp414 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp414 ; arg2 = tmp408 ; goto __ats_lab_aux_14 ; // tail call break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: break ; } while (0) ; return /* (tmp405) */ ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17386(line=560, offs=7) -- 17901(line=576, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp404) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst: /* tmp404 = */ aux_14 (arg0, 0, arg1) ; return /* (tmp404) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 17962(line=578, offs=29) -- 18009(line=578, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_labd3explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; // ATSlocal_void (tmp418) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_labd3explst: tmp416 = atspre_stdout_get () ; tmp417 = ats_selsin_mac(tmp416, atslab_1) ; /* tmp418 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst (tmp417, arg0) ; /* tmp415 = */ atspre_stdout_view_set () ; return /* (tmp415) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__print_labd3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 18038(line=579, offs=29) -- 18085(line=579, offs=76) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_labd3explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; // ATSlocal_void (tmp422) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_labd3explst: tmp420 = atspre_stderr_get () ; tmp421 = ats_selsin_mac(tmp420, atslab_1) ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_labd3explst (tmp421, arg0) ; /* tmp419 = */ atspre_stderr_view_set () ; return /* (tmp419) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_labd3explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 18132(line=584, offs=15) -- 18630(line=600, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; // ATSlocal_void (tmp434) ; // ATSlocal_void (tmp435) ; // ATSlocal_void (tmp436) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1: tmp424 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_d3lab1_node) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp424)->tag != 0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_1, tmp424, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_1, tmp424, atslab_1) ; /* tmp427 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp425) ; /* tmp428 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp426) ; /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (((ats_sum_ptr_type)tmp424)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_1, tmp424, atslab_0) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_1, tmp424, atslab_1) ; /* tmp432 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3explstlst (arg0, tmp430) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; /* tmp435 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp436 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp431) ; /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp423) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp3_print.dats: 18685(line=603, offs=18) -- 18763(line=604, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp437) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst: /* tmp437 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1) ; return /* (tmp437) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3lab1lst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp3_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_array_dats.c0000664000175000017500000001062312223166160023123 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "prelude/CATS/array.cats" /* type definitions */ typedef struct { ats_ptr_type atslab_2 ; ats_size_type atslab_3 ; } anairiats_rec_0 ; /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__sasp__array_viewt0ype_int_type = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/prelude_dats_array.dats: 2773(line=96, offs=10) -- 2922(line=101, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2prelude_2SATS_2array_2esats__array_make_arrpsz (anairiats_rec_0 arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; // ATSlocal_void (tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2prelude_2SATS_2array_2esats__array_make_arrpsz: tmp2 = ats_select_mac(arg0, atslab_2) ; /* tmp1 = */ atspre_vbox_make_view_ptr (tmp2) ; /* tmp3 = ats_selsin_mac(tmp1, atslab_1) */ ; tmp0 = ats_select_mac(arg0, atslab_2) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2prelude_2SATS_2array_2esats__array_make_arrpsz] */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_array_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ typedef unsigned char byte ; ats_void_type atspre_array_ptr_initialize_elt_tsz ( ats_ptr_type A , ats_size_type asz , ats_ptr_type ini , ats_size_type tsz ) { int i, itsz ; int left ; ats_ptr_type p ; if (asz == 0) return ; memcpy (A, ini, tsz) ; i = 1 ; itsz = tsz ; left = asz - i ; while (left > 0) { p = (ats_ptr_type)(((byte*)A) + itsz) ; if (left <= i) { memcpy (p, A, left * tsz) ; return ; } /* end of [if] */ memcpy (p, A, itsz); i = i + i ; itsz = itsz + itsz ; left = asz - i ; } /* end of [while] */ return ; } /* end of [atspre_array_ptr_initialize_elt_tsz] */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_array_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symbol_sats.c0000664000175000017500000000177112223166160021451 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symbol_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_env_dats.c0000664000175000017500000052131012223166160022202 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hash ; ats_ptr_type atslab_eq ; ats_int_type atslab_size ; ats_int_type atslab_nitm ; ats_ptr_type atslab_table[] ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_map ; ats_ptr_type atslab_maplst ; ats_ptr_type atslab_savedlst ; ats_ptr_type atslab_pervasive ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_s0rtq_loc ; ats_ptr_type atslab_s0rtq_node ; } anairiats_rec_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_8 ; typedef struct { anairiats_rec_8 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_s0taq_loc ; ats_ptr_type atslab_s0taq_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_d0ynq_loc ; ats_ptr_type atslab_d0ynq_node ; } anairiats_rec_11 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQstr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQsym_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymdot_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatconptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatcontyp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMfil_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMvar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacdef_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imul) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_uimod) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_ulint) (ats_ulint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ulint_type, atspre_string_hash_33) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_takeout_tsz) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search) (ats_clo_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_restore) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_localjoin) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_swap) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_tmplev) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_tmplev) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_localjoin) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_localjoin) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_localjoin) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_htp_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, __ats_htp_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__trans2_env_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__staload_level_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__d2expenv_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__d2var_current_level_v = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__s2expenv_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__sasp__s2rtenv_token = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_uint_type __ats_fun_2 (ats_ptr_type arg0) ; static ats_bool_type __ats_fun_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_uint_type __ats_fun_4 (ats_ptr_type arg0) ; static ats_bool_type __ats_fun_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_uint_type __ats_fun_6 (ats_ptr_type arg0) ; static ats_bool_type __ats_fun_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_uint_type __ats_fun_8 (ats_ptr_type arg0) ; static ats_bool_type __ats_fun_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type chain_insert_048_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type table_insert_074_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type ht_insert_0105_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_16 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_ptr_type htp_resize_0134_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type chain_search_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type table_search_064_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type ht_search_0100_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_join_random_0243_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type map_remove_03469_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_remove_fst_01863_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type bst_size_0195_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_03468_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type symenv_insert_fst_01862_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_0223_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_03470_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symmap_ref_search_01855_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type f_34 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_34_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type the_s2rtenv_namespace_find_33 (ats_ptr_type arg0) ; static ats_ptr_type symmaplst_search_0385_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_search_all_01864_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_pervasive_search_01865_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type prerr_interror_0363_ () ; static ats_ptr_type abort_45 () ; static ats_void_type bst_free_0191_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type map_free_03466_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symmap_free_01853_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symenv_pop_01867_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type abort_53 () ; static ats_ptr_type aux_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_join_03471_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type symenv_localjoin_01872_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type the_s2rtenv_pervasive_add_topenv_56 () ; static ats_ptr_type ref_make_elt_01877_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type the_s2rtenv_namespace_add_topenv_57 (ats_ptr_type arg0) ; static ats_void_type the_s2rtenv_save_59 () ; static anairiats_rec_8 abort_62 () ; static ats_void_type symmaplst_free_0381_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symenv_restore_01874_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type the_s2rtenv_restore_60 () ; static ats_ptr_type f_71 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_71_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_71_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type the_s2expenv_namespace_find_70 (ats_ptr_type arg0) ; static ats_void_type the_s2expenv_pervasive_add_topenv_78 () ; static ats_void_type the_s2expenv_namespace_add_topenv_79 (ats_ptr_type arg0) ; static ats_void_type the_s2expenv_save_80 () ; static ats_void_type the_s2expenv_restore_81 () ; static ats_ptr_type ref_make_elt_01877_ats_int_type (ats_int_type arg0) ; static ats_void_type aux_s2vs_94 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type aux_s2qualst_95 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type f_109 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_109_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_109_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type the_d2expenv_namespace_find_108 (ats_ptr_type arg0) ; static ats_void_type the_d2expenv_pervasive_add_topenv_118 () ; static ats_void_type the_d2expenv_namespace_add_topenv_119 (ats_ptr_type arg0) ; static ats_void_type the_d2expenv_save_120 () ; static ats_void_type the_d2expenv_restore_121 () ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp6) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp12) ; ATSstatic (ats_ptr_type, statmp98) ; ATSstatic (ats_ptr_type, statmp407) ; ATSstatic (ats_ptr_type, statmp491) ; ATSstatic (ats_ptr_type, statmp501) ; ATSstatic (ats_ptr_type, statmp514) ; ATSstatic (ats_ptr_type, statmp542) ; ATSstatic (ats_ptr_type, statmp551) ; ATSstatic (ats_ptr_type, statmp632) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 2249(line=74, offs=4) -- 2334(line=75, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 2368(line=78, offs=4) -- 2427(line=78, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans2_env)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 2695(line=89, offs=5) -- 2722(line=89, offs=32) */ ATSstaticdec() ats_uint_type __ats_fun_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp4) ; __ats_lab___ats_fun_2: tmp4 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash (arg0) ; return (tmp4) ; } /* end of [__ats_fun_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 2724(line=89, offs=34) -- 2747(line=89, offs=57) */ ATSstaticdec() ats_bool_type __ats_fun_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp5) ; __ats_lab___ats_fun_3: tmp5 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, arg1) ; return (tmp5) ; } /* end of [__ats_fun_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3045(line=101, offs=5) -- 3072(line=101, offs=32) */ ATSstaticdec() ats_uint_type __ats_fun_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp7) ; __ats_lab___ats_fun_4: tmp7 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash (arg0) ; return (tmp7) ; } /* end of [__ats_fun_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3074(line=101, offs=34) -- 3097(line=101, offs=57) */ ATSstaticdec() ats_bool_type __ats_fun_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp8) ; __ats_lab___ats_fun_5: tmp8 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, arg1) ; return (tmp8) ; } /* end of [__ats_fun_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3363(line=113, offs=3) -- 3390(line=113, offs=30) */ ATSstaticdec() ats_uint_type __ats_fun_6 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp10) ; __ats_lab___ats_fun_6: tmp10 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash (arg0) ; return (tmp10) ; } /* end of [__ats_fun_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3392(line=113, offs=32) -- 3415(line=113, offs=55) */ ATSstaticdec() ats_bool_type __ats_fun_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp11) ; __ats_lab___ats_fun_7: tmp11 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, arg1) ; return (tmp11) ; } /* end of [__ats_fun_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3605(line=122, offs=3) -- 3632(line=122, offs=30) */ ATSstaticdec() ats_uint_type __ats_fun_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp13) ; __ats_lab___ats_fun_8: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash (arg0) ; return (tmp13) ; } /* end of [__ats_fun_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3634(line=122, offs=32) -- 3657(line=122, offs=55) */ ATSstaticdec() ats_bool_type __ats_fun_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp14) ; __ats_lab___ats_fun_9: tmp14 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, arg1) ; return (tmp14) ; } /* end of [__ats_fun_9] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2766(line=87, offs=3) -- 2870(line=89, offs=24) */ ATSstaticdec() ats_void_type chain_insert_048_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_chain_insert_048_ats_ptr_type_2cats_ptr_type: tmp39 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_2, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp39 ; return /* (tmp38) */ ; } /* end of [chain_insert_048_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 4157(line=133, offs=3) -- 4487(line=143, offs=4) */ ATSstaticdec() ats_void_type table_insert_074_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_size_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_table_insert_074_ats_ptr_type_2cats_ptr_type: tmp35 = atspre_size1_of_int1 (arg1) ; tmp36 = atspre_array_ptr_takeout_tsz (arg0, tmp35, sizeof(ats_ptr_type)) ; tmp37 = ats_selsin_mac(tmp36, atslab_2) ; /* tmp34 = */ chain_insert_048_ats_ptr_type_2cats_ptr_type (tmp37, arg2, arg3) ; return /* (tmp34) */ ; } /* end of [table_insert_074_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5954(line=202, offs=20) -- 6152(line=209, offs=4) */ ATSstaticdec() ats_void_type ht_insert_0105_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp28) ; ATSlocal (ats_uint_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_int_type, tmp32) ; // ATSlocal_void (tmp33) ; ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_int_type, tmp41) ; __ats_lab_ht_insert_0105_ats_ptr_type_2cats_ptr_type: tmp30 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_hash) ; tmp29 = ((ats_uint_type(*)(ats_ptr_type))tmp30) (arg1) ; tmp32 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_size) ; tmp31 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp29), tmp32) ; /* tmp33 = */ table_insert_074_ats_ptr_type_2cats_ptr_type (&ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_table[0]), tmp31, arg1, arg2) ; tmp41 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_nitm) ; tmp40 = atspre_add_int_int (tmp41, 1) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_nitm) = tmp40 ; return /* (tmp28) */ ; } /* end of [ht_insert_0105_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 6239(line=213, offs=26) -- 6492(line=221, offs=4) */ ATSstaticdec() ats_void_type ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; __ats_lab_ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp56 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp57 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_2) ; ATS_FREE(arg1) ; /* tmp58 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (arg0, tmp55, tmp56) ; arg0 = arg0 ; arg1 = tmp57 ; goto __ats_lab_ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp54) */ ; } /* end of [ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8835(line=312, offs=7) -- 9180(line=321, offs=6) */ ATSstaticdec() ats_void_type loop_16 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; // ATSlocal_void (tmp53) ; ATSlocal (ats_int_type, tmp59) ; __ats_lab_loop_16: tmp51 = atspre_ilt (arg3, arg0) ; if (tmp51) { tmp52 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get (&ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_table[0]), arg3) ; /* tmp53 = */ ht_insert_chain_0111_ats_ptr_type_2cats_ptr_type (arg2, tmp52) ; tmp59 = atspre_iadd (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp59 ; goto __ats_lab_loop_16 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp50) */ ; } /* end of [loop_16] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8621(line=308, offs=5) -- 9290(line=326, offs=4) */ ATSstaticdec() ats_ptr_type htp_resize_0134_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_int_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; __ats_lab_htp_resize_0134_ats_ptr_type_2cats_ptr_type: tmp45 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_size) ; tmp47 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hash) ; tmp48 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_eq) ; tmp46 = ats_htp_make (tmp47, tmp48, arg1) ; tmp49 = ats_selsin_mac(tmp46, atslab_1) ; /* tmp60 = */ loop_16 (tmp45, arg0, tmp49, 0) ; /* tmp61 = */ __ats_htp_free (arg0) ; tmp44 = tmp49 ; return (tmp44) ; } /* end of [htp_resize_0134_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 11172(line=403, offs=16) -- 11905(line=428, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_bool_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; // ATSlocal_void (tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type: tmp18 = atspre_ref_get_view_ptr (arg0) ; tmp19 = ats_selsin_mac(tmp18, atslab_1) ; tmp20 = ats_ptrget_mac(ats_ptr_type, tmp19) ; tmp21 = ats_selsin_mac(tmp20, atslab_1) ; tmp22 = atspre_pneq (tmp21, atspre_null_ptr) ; if (tmp22) { tmp23 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp21), atslab_size) ; tmp24 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp21), atslab_nitm) ; tmp26 = atspre_imul (tmp23, 5) ; tmp25 = atspre_lt_int_int (tmp24, tmp26) ; if (tmp25) { /* tmp27 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (tmp21, arg1, arg2) ; tmp42 = tmp21 ; ats_ptrget_mac(ats_ptr_type, tmp19) = tmp42 ; tmp17 = (ats_sum_ptr_type)0 ; } else { tmp62 = atspre_iadd (tmp23, tmp23) ; tmp43 = htp_resize_0134_ats_ptr_type_2cats_ptr_type (tmp21, tmp62) ; tmp63 = ats_selsin_mac(tmp43, atslab_1) ; /* tmp64 = */ ht_insert_0105_ats_ptr_type_2cats_ptr_type (tmp63, arg1, arg2) ; tmp65 = tmp63 ; ats_ptrget_mac(ats_ptr_type, tmp19) = tmp65 ; tmp17 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } else { tmp66 = tmp21 ; ats_ptrget_mac(ats_ptr_type, tmp19) = tmp66 ; tmp17 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp17, atslab_0, arg2) ; } /* end of [if] */ return (tmp17) ; } /* end of [hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 3725(line=126, offs=23) -- 4038(line=137, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_add: tmp16 = hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (statmp12, arg0, arg1) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp16 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: ATS_FREE(tmp16) ; /* tmp67 = */ prerr_interror_1 () ; /* tmp68 = */ atspre_prerr_string (ATSstrcst(": d2eclst_namespace_add: id = ")) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp70 = */ atspre_prerr_newline () ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp16 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp15) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_add] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2269(line=73, offs=3) -- 2695(line=83, offs=4) */ ATSstaticdec() ats_ptr_type chain_search_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_bool_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_chain_search_039_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp91 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_2) ; tmp92 = ((ats_bool_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp89) ; if (tmp92) { tmp88 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp88, atslab_0, tmp90) ; } else { tmp93 = ats_ptrget_mac(ats_ptr_type, tmp91) ; arg0 = tmp93 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_chain_search_039_ats_ptr_type_2cats_ptr_type ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp88 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp88) ; } /* end of [chain_search_039_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 3727(line=119, offs=3) -- 4085(line=129, offs=4) */ ATSstaticdec() ats_ptr_type table_search_064_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_size_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_table_search_064_ats_ptr_type_2cats_ptr_type: tmp85 = atspre_size1_of_int1 (arg1) ; tmp86 = atspre_array_ptr_takeout_tsz (arg0, tmp85, sizeof(ats_ptr_type)) ; tmp87 = ats_selsin_mac(tmp86, atslab_2) ; tmp94 = ats_ptrget_mac(ats_ptr_type, tmp87) ; tmp84 = chain_search_039_ats_ptr_type_2cats_ptr_type (tmp94, arg2, arg3) ; return (tmp84) ; } /* end of [table_search_064_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5707(line=192, offs=20) -- 5890(line=199, offs=4) */ ATSstaticdec() ats_ptr_type ht_search_0100_ats_ptr_type_2cats_ptr_type (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_uint_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_ht_search_0100_ats_ptr_type_2cats_ptr_type: tmp81 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_hash) ; tmp80 = ((ats_uint_type(*)(ats_ptr_type))tmp81) (arg1) ; tmp83 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_size) ; tmp82 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp80), tmp83) ; tmp95 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_eq) ; tmp79 = table_search_064_ats_ptr_type_2cats_ptr_type (&ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg0), atslab_table[0]), tmp82, arg1, tmp95) ; return (tmp79) ; } /* end of [ht_search_0100_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 10666(line=380, offs=16) -- 11067(line=396, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_bool_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_hashtbl_search_01814_ats_ptr_type_2cats_ptr_type: tmp73 = atspre_ref_get_view_ptr (arg0) ; tmp74 = ats_selsin_mac(tmp73, atslab_1) ; tmp75 = ats_ptrget_mac(ats_ptr_type, tmp74) ; tmp76 = ats_selsin_mac(tmp75, atslab_1) ; tmp77 = atspre_pneq (tmp76, atspre_null_ptr) ; if (tmp77) { tmp78 = ht_search_0100_ats_ptr_type_2cats_ptr_type (tmp76, arg1) ; tmp96 = tmp76 ; ats_ptrget_mac(ats_ptr_type, tmp74) = tmp96 ; tmp72 = tmp78 ; } else { tmp97 = tmp76 ; ats_ptrget_mac(ats_ptr_type, tmp74) = tmp97 ; tmp72 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp72) ; } /* end of [hashtbl_search_01814_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 4107(line=140, offs=24) -- 4156(line=141, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find: tmp71 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp12, arg0) ; return (tmp71) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2eclst_namespace_find] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 5380(line=174, offs=25) -- 6039(line=193, offs=4) */ ATSstaticdec() ats_ptr_type bst_join_random_0243_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_int_type, tmp136) ; ATSlocal (ats_int_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_bool_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_int_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_bst_join_random_0243_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_10_1: tmp132 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp133 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp134 = &ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp135 = &ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_3) ; tmp137 = ats_ptrget_mac(ats_int_type, tmp132) ; tmp138 = ats_ptrget_mac(ats_int_type, tmp134) ; tmp136 = atspre_iadd (tmp137, tmp138) ; tmp140 = ats_ptrget_mac(ats_int_type, tmp132) ; tmp141 = ats_ptrget_mac(ats_int_type, tmp134) ; tmp139 = atsopt_map_lin_dice (tmp140, tmp141) ; if (tmp139) { tmp143 = ats_ptrget_mac(ats_ptr_type, tmp133) ; tmp142 = bst_join_random_0243_ats_ptr_type_2cats_ptr_type (tmp143, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp133) = tmp142 ; ats_ptrget_mac(ats_int_type, tmp132) = tmp136 ; tmp131 = arg0 ; } else { tmp145 = ats_ptrget_mac(ats_ptr_type, tmp135) ; tmp144 = bst_join_random_0243_ats_ptr_type_2cats_ptr_type (arg0, tmp145) ; ats_ptrget_mac(ats_ptr_type, tmp135) = tmp144 ; ats_ptrget_mac(ats_int_type, tmp134) = tmp136 ; tmp131 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp131 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp131 = arg1 ; break ; } while (0) ; return (tmp131) ; } /* end of [bst_join_random_0243_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 6466(line=208, offs=30) -- 7610(line=243, offs=4) */ ATSstaticdec() ats_ptr_type bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_int_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_int_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_int_type, tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_bst_remove_random_0257_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_6_1: tmp112 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_2) ; tmp115 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp116 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp117 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg4) (arg1, tmp113) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (tmp117 != -1) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp119 = ats_ptrget_mac(ats_ptr_type, tmp115) ; tmp118 = bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (tmp119, arg1, arg2, arg3, arg4) ; tmp120 = ats_selsin_mac(tmp118, atslab_2) ; tmp122 = ats_ptrget_mac(ats_int_type, tmp112) ; tmp123 = ats_ptrget_mac(ats_int_type, arg2) ; tmp121 = atspre_isub (tmp122, tmp123) ; ats_ptrget_mac(ats_int_type, tmp112) = tmp121 ; ats_ptrget_mac(ats_ptr_type, tmp115) = tmp120 ; tmp111 = arg0 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp117 != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp125 = ats_ptrget_mac(ats_ptr_type, tmp116) ; tmp124 = bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (tmp125, arg1, arg2, arg3, arg4) ; tmp126 = ats_selsin_mac(tmp124, atslab_2) ; tmp128 = ats_ptrget_mac(ats_int_type, tmp112) ; tmp129 = ats_ptrget_mac(ats_int_type, arg2) ; tmp127 = atspre_isub (tmp128, tmp129) ; ats_ptrget_mac(ats_int_type, tmp112) = tmp127 ; ats_ptrget_mac(ats_ptr_type, tmp116) = tmp126 ; tmp111 = arg0 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp117 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp146 = ats_ptrget_mac(ats_ptr_type, tmp115) ; tmp147 = ats_ptrget_mac(ats_ptr_type, tmp116) ; tmp130 = bst_join_random_0243_ats_ptr_type_2cats_ptr_type (tmp146, tmp147) ; ats_ptrget_mac(ats_int_type, arg2) = 1 ; tmp148 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp148, atslab_0, tmp114) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp148 ; ATS_FREE(arg0) ; tmp111 = tmp130 ; break ; } while (0) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: ats_ptrget_mac(ats_int_type, arg2) = 0 ; tmp149 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp149 ; tmp111 = arg0 ; break ; } while (0) ; return (tmp111) ; } /* end of [bst_remove_random_0257_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10217(line=356, offs=12) -- 10550(line=365, offs=4) */ ATSstaticdec() ats_ptr_type map_remove_03469_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_int_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_map_remove_03469_ats_ptr_type_2cats_ptr_type: // tmp106 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp107 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* ats_int_type tmp108 ; */ /* ats_ptr_type tmp109 ; */ tmp150 = ats_ptrget_mac(ats_ptr_type, tmp107) ; tmp110 = bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (tmp150, arg1, (&tmp108), (&tmp109), tmp106) ; tmp151 = ats_selsin_mac(tmp110, atslab_2) ; ats_ptrget_mac(ats_ptr_type, tmp107) = tmp151 ; tmp105 = tmp109 ; return (tmp105) ; } /* end of [map_remove_03469_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4740(line=179, offs=19) -- 4840(line=182, offs=4) */ ATSstaticdec() ats_ptr_type symenv_remove_fst_01863_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_symenv_remove_fst_01863_ats_ptr_type: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp102 = atspre_ref_get_view_ptr (tmp103) ; tmp104 = ats_selsin_mac(tmp102, atslab_1) ; tmp152 = ats_ptrget_mac(ats_ptr_type, tmp104) ; tmp101 = map_remove_03469_ats_ptr_type_2cats_ptr_type (tmp152, arg1) ; return (tmp101) ; } /* end of [symenv_remove_fst_01863_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_0195_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; __ats_lab_bst_size_0195_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp184 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp183 = tmp184 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp183 = 0 ; break ; } while (0) ; return (tmp183) ; } /* end of [bst_size_0195_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_bool_type, tmp174) ; ATSlocal (ats_int_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_int_type, tmp181) ; ATSlocal (ats_int_type, tmp182) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_int_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_int_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_int_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp170 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp171 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp172 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp173 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp175 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp171) ; tmp174 = atspre_ilte (tmp175, 0) ; if (tmp174) { tmp177 = ats_ptrget_mac(ats_ptr_type, tmp172) ; tmp176 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (tmp177, arg1, arg2, arg3) ; // if (tmp176 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp178 = &ats_caselptrlab_mac(anairiats_sum_5, tmp176, atslab_0) ; tmp179 = &ats_caselptrlab_mac(anairiats_sum_5, tmp176, atslab_3) ; tmp180 = &ats_caselptrlab_mac(anairiats_sum_5, tmp176, atslab_4) ; tmp181 = ats_ptrget_mac(ats_int_type, tmp170) ; tmp185 = ats_ptrget_mac(ats_ptr_type, tmp179) ; tmp182 = bst_size_0195_ats_ptr_type_2cats_ptr_type (tmp185) ; tmp186 = ats_ptrget_mac(ats_ptr_type, tmp180) ; ats_ptrget_mac(ats_ptr_type, tmp172) = tmp186 ; tmp187 = atspre_isub (tmp181, tmp182) ; ats_ptrget_mac(ats_int_type, tmp170) = tmp187 ; ats_ptrget_mac(ats_ptr_type, tmp180) = arg0 ; tmp188 = atspre_iadd (tmp181, 1) ; ats_ptrget_mac(ats_int_type, tmp178) = tmp188 ; tmp169 = tmp176 ; } else { tmp190 = ats_ptrget_mac(ats_ptr_type, tmp173) ; tmp189 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (tmp190, arg1, arg2, arg3) ; // if (tmp189 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp191 = &ats_caselptrlab_mac(anairiats_sum_5, tmp189, atslab_0) ; tmp192 = &ats_caselptrlab_mac(anairiats_sum_5, tmp189, atslab_3) ; tmp193 = &ats_caselptrlab_mac(anairiats_sum_5, tmp189, atslab_4) ; tmp194 = ats_ptrget_mac(ats_int_type, tmp170) ; tmp196 = ats_ptrget_mac(ats_ptr_type, tmp193) ; tmp195 = bst_size_0195_ats_ptr_type_2cats_ptr_type (tmp196) ; tmp197 = ats_ptrget_mac(ats_ptr_type, tmp192) ; ats_ptrget_mac(ats_ptr_type, tmp173) = tmp197 ; tmp198 = atspre_isub (tmp194, tmp195) ; ats_ptrget_mac(ats_int_type, tmp170) = tmp198 ; ats_ptrget_mac(ats_ptr_type, tmp192) = arg0 ; tmp199 = atspre_iadd (tmp194, 1) ; ats_ptrget_mac(ats_int_type, tmp191) = tmp199 ; tmp169 = tmp189 ; } /* end of [if] */ break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp200 = (ats_sum_ptr_type)0 ; tmp201 = (ats_sum_ptr_type)0 ; tmp169 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp169, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_5, tmp169, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp169, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp169, atslab_3, tmp200) ; ats_selptrset_mac(anairiats_sum_5, tmp169, atslab_4, tmp201) ; break ; } while (0) ; return (tmp169) ; } /* end of [bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_bool_type, tmp167) ; ATSlocal (ats_int_type, tmp168) ; ATSlocal (ats_bool_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_int_type, tmp206) ; ATSlocal (ats_int_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_int_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; __ats_lab_bst_insert_random_0234_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_17_1: tmp163 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp165 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp166 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp168 = ats_ptrget_mac(ats_int_type, tmp163) ; tmp167 = atsopt_map_lin_dice (1, tmp168) ; if (tmp167) { tmp162 = bst_insert_atroot_0200_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp203 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp164) ; tmp202 = atspre_ilte (tmp203, 0) ; if (tmp202) { tmp205 = ats_ptrget_mac(ats_ptr_type, tmp165) ; tmp204 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp205, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp165) = tmp204 ; tmp207 = ats_ptrget_mac(ats_int_type, tmp163) ; tmp206 = atspre_iadd (tmp207, 1) ; ats_ptrget_mac(ats_int_type, tmp163) = tmp206 ; tmp162 = arg0 ; } else { tmp209 = ats_ptrget_mac(ats_ptr_type, tmp166) ; tmp208 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp209, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp166) = tmp208 ; tmp211 = ats_ptrget_mac(ats_int_type, tmp163) ; tmp210 = atspre_iadd (tmp211, 1) ; ats_ptrget_mac(ats_int_type, tmp163) = tmp210 ; tmp162 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp212 = (ats_sum_ptr_type)0 ; tmp213 = (ats_sum_ptr_type)0 ; tmp162 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp162, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_5, tmp162, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp162, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp162, atslab_3, tmp212) ; ats_selptrset_mac(anairiats_sum_5, tmp162, atslab_4, tmp213) ; break ; } while (0) ; return (tmp162) ; } /* end of [bst_insert_random_0234_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_03468_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_map_insert_03468_ats_ptr_type_2cats_ptr_type: // tmp159 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp160 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp214 = ats_ptrget_mac(ats_ptr_type, tmp160) ; tmp161 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp214, arg1, arg2, tmp159) ; ats_ptrget_mac(ats_ptr_type, tmp160) = tmp161 ; return /* (tmp158) */ ; } /* end of [map_insert_03468_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4569(line=173, offs=19) -- 4675(line=176, offs=4) */ ATSstaticdec() ats_void_type symenv_insert_fst_01862_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_symenv_insert_fst_01862_ats_ptr_type: tmp156 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp155 = atspre_ref_get_view_ptr (tmp156) ; tmp157 = ats_selsin_mac(tmp155, atslab_1) ; tmp215 = ats_ptrget_mac(ats_ptr_type, tmp157) ; /* tmp154 = */ map_insert_03468_ats_ptr_type_2cats_ptr_type (tmp215, arg1, arg2) ; return /* (tmp154) */ ; } /* end of [symenv_insert_fst_01862_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 4395(line=155, offs=27) -- 4619(line=162, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add: tmp100 = symenv_remove_fst_01863_ats_ptr_type (statmp98, arg0) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: ATS_FREE(tmp100) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (tmp100 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: break ; } while (0) ; /* tmp99 = */ symenv_insert_fst_01862_ats_ptr_type (statmp98, arg0, arg1) ; return /* (tmp99) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_0223_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_int_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_25_1: tmp232 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_2) ; tmp234 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp235 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp236 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp232) ; do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (tmp236 != -1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp237 = ats_ptrget_mac(ats_ptr_type, tmp234) ; arg0 = tmp237 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp236 != 1) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp238 = ats_ptrget_mac(ats_ptr_type, tmp235) ; arg0 = tmp238 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0223_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp236 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp231 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp231, atslab_0, tmp233) ; break ; } while (0) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp231 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp231) ; } /* end of [bst_search_0223_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_03470_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_map_search_03470_ats_ptr_type_2cats_ptr_type: // tmp229 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp230 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp239 = ats_ptrget_mac(ats_ptr_type, tmp230) ; tmp228 = bst_search_0223_ats_ptr_type_2cats_ptr_type (tmp239, arg1, tmp229) ; return (tmp228) ; } /* end of [map_search_03470_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 2535(line=91, offs=19) -- 2642(line=95, offs=4) */ ATSstaticdec() ats_ptr_type symmap_ref_search_01855_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp240) ; __ats_lab_symmap_ref_search_01855_ats_ptr_type: tmp226 = atspre_ref_get_view_ptr (arg0) ; tmp227 = ats_selsin_mac(tmp226, atslab_1) ; tmp240 = ats_ptrget_mac(ats_ptr_type, tmp227) ; tmp225 = map_search_03470_ats_ptr_type_2cats_ptr_type (tmp240, arg1) ; return (tmp225) ; } /* end of [symmap_ref_search_01855_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 4719(line=166, offs=6) -- 5156(line=177, offs=6) */ ATSstaticdec() ats_ptr_type f_34 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; // ATSlocal_void (tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; __ats_lab_f_34: tmp219 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp3, arg0) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (tmp219 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_2, tmp219, atslab_0) ; ATS_FREE(tmp219) ; tmp218 = tmp220 ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (tmp219 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: /* tmp221 = */ prerr_interror_1 () ; /* tmp222 = */ atspre_prerr_string (ATSstrcst(": s2rtenv_namespace_find: name = ")) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp224 = */ atspre_prerr_newline () ; /* tmp218 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp217 = symmap_ref_search_01855_ats_ptr_type (tmp218, env0) ; return (tmp217) ; } /* end of [f_34] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_34_closure_type ; ats_ptr_type f_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_34 (((f_34_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_34_closure_init (f_34_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_34_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_34_closure_make (ats_ptr_type env0) { f_34_closure_type *p_clo = ATS_MALLOC(sizeof(f_34_closure_type)) ; f_34_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 4652(line=164, offs=4) -- 5279(line=183, offs=4) */ ATSstaticdec() ats_ptr_type the_s2rtenv_namespace_find_33 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_clo_ptr_type, tmp241) ; __ats_lab_the_s2rtenv_namespace_find_33: /* ats_clo_ptr_type tmp241 ; */ tmp241 = f_34_closure_make (arg0) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search (tmp241) ; ATS_FREE(tmp241) ; return (tmp216) ; } /* end of [the_s2rtenv_namespace_find_33] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3703(line=144, offs=32) -- 4232(line=158, offs=4) */ ATSstaticdec() ats_ptr_type symmaplst_search_0385_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; __ats_lab_symmaplst_search_0385_ats_ptr_type: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_32_1: tmp254 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp255 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp257 = ats_ptrget_mac(ats_ptr_type, tmp254) ; tmp256 = map_search_03470_ats_ptr_type_2cats_ptr_type (tmp257, arg1) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (tmp256 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp253 = tmp256 ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (tmp256 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp259 = ats_ptrget_mac(ats_ptr_type, tmp255) ; tmp258 = symmaplst_search_0385_ats_ptr_type (tmp259, arg1) ; tmp253 = tmp258 ; break ; } while (0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp253 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp253) ; } /* end of [symmaplst_search_0385_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4926(line=187, offs=19) -- 5334(line=202, offs=4) */ ATSstaticdec() ats_ptr_type symenv_search_all_01864_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_symenv_search_all_01864_ats_ptr_type: tmp246 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp245 = atspre_ref_get_view_ptr (tmp246) ; tmp247 = ats_selsin_mac(tmp245, atslab_1) ; tmp249 = ats_ptrget_mac(ats_ptr_type, tmp247) ; tmp248 = map_search_03470_ats_ptr_type_2cats_ptr_type (tmp249, arg1) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp248 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp244 = tmp248 ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (tmp248 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_maplst) ; tmp250 = atspre_ref_get_view_ptr (tmp251) ; tmp252 = ats_selsin_mac(tmp250, atslab_1) ; tmp260 = ats_ptrget_mac(ats_ptr_type, tmp252) ; tmp244 = symmaplst_search_0385_ats_ptr_type (tmp260, arg1) ; break ; } while (0) ; return (tmp244) ; } /* end of [symenv_search_all_01864_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 5404(line=205, offs=25) -- 5519(line=209, offs=4) */ ATSstaticdec() ats_ptr_type symenv_pervasive_search_01865_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; __ats_lab_symenv_pervasive_search_01865_ats_ptr_type: tmp264 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_pervasive) ; tmp263 = atspre_ref_get_view_ptr (tmp264) ; tmp265 = ats_selsin_mac(tmp263, atslab_1) ; tmp266 = ats_ptrget_mac(ats_ptr_type, tmp265) ; tmp262 = symmaplst_search_0385_ats_ptr_type (tmp266, arg1) ; return (tmp262) ; } /* end of [symenv_pervasive_search_01865_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 5347(line=186, offs=18) -- 5781(line=202, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp261) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find: tmp243 = symenv_search_all_01864_ats_ptr_type (statmp98, arg0) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp243 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp242 = tmp243 ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp243 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp261 = the_s2rtenv_namespace_find_33 (arg0) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp261 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp242 = tmp261 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (tmp261 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: tmp242 = symenv_pervasive_search_01865_ats_ptr_type (statmp98, arg0) ; break ; } while (0) ; break ; } while (0) ; return (tmp242) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 5843(line=205, offs=22) -- 7269(line=245, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; // ATSlocal_void (tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; // ATSlocal_void (tmp289) ; // ATSlocal_void (tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua: tmp268 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_s0rtq_node) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp268)->tag != 0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp267 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find (arg1) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp268)->tag != 2) { goto __ats_lab_47_0 ; } __ats_lab_41_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_7, tmp268, atslab_0) ; tmp271 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp269) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp271 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } tmp272 = ats_caselptrlab_mac(anairiats_sum_2, tmp271, atslab_0) ; if (((ats_sum_ptr_type)tmp272)->tag != 4) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp273 = ats_caselptrlab_mac(anairiats_sum_7, tmp272, atslab_0) ; ATS_FREE(tmp271) ; tmp270 = tmp273 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp271 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: ATS_FREE(tmp271) ; tmp275 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_s0rtq_loc) ; /* tmp274 = */ prerr_loc_error2_0 (tmp275) ; /* tmp276 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp269) ; /* tmp278 = */ atspre_prerr_string (ATSstrcst("] should refer to a filename but it does not.")) ; /* tmp279 = */ atspre_prerr_newline () ; /* tmp270 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (tmp271 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp281 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_s0rtq_loc) ; /* tmp280 = */ prerr_loc_error2_0 (tmp281) ; /* tmp282 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp283 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp269) ; /* tmp284 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp285 = */ atspre_prerr_newline () ; /* tmp270 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp286 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (tmp270) ; tmp287 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp3, tmp286) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp287 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_2, tmp287, atslab_0) ; ATS_FREE(tmp287) ; tmp267 = symmap_ref_search_01855_ats_ptr_type (tmp288, arg1) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (tmp287 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: /* tmp289 = */ prerr_interror_1 () ; /* tmp290 = */ atspre_prerr_string (ATSstrcst(": the loaded file [")) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp286) ; /* tmp292 = */ atspre_prerr_string (ATSstrcst("] cannot be located.")) ; /* tmp293 = */ atspre_prerr_newline () ; /* tmp267 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (((ats_sum_ptr_type)tmp268)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp267 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp267) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 2338(line=81, offs=21) -- 2378(line=81, offs=61) */ ATSstaticdec() ats_void_type prerr_interror_0363_ () { /* local vardec */ // ATSlocal_void (tmp298) ; __ats_lab_prerr_interror_0363_: /* tmp298 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_symenv)")) ; return /* (tmp298) */ ; } /* end of [prerr_interror_0363_] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 6500(line=243, offs=6) -- 6648(line=247, offs=6) */ ATSstaticdec() ats_ptr_type abort_45 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp300) ; __ats_lab_abort_45: /* tmp297 = */ prerr_interror_0363_ () ; /* tmp299 = */ atspre_prerr_string (ATSstrcst(": symenv_pop: env.maplst is empty")) ; /* tmp300 = */ atspre_prerr_newline () ; /* tmp296 = */ ats_exit (1) ; return (tmp296) ; } /* end of [abort_45] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_0191_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; // ATSlocal_void (tmp318) ; __ats_lab_bst_free_0191_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp316 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp318 = */ bst_free_0191_ats_ptr_type_2cats_ptr_type (tmp316) ; arg0 = tmp317 ; goto __ats_lab_bst_free_0191_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: break ; } while (0) ; return /* (tmp315) */ ; } /* end of [bst_free_0191_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_03466_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; __ats_lab_map_free_03466_ats_ptr_type_2cats_ptr_type: // tmp314 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp313 = */ bst_free_0191_ats_ptr_type_2cats_ptr_type (tmp314) ; return /* (tmp313) */ ; } /* end of [map_free_03466_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3321(line=127, offs=28) -- 3347(line=127, offs=54) */ ATSstaticdec() ats_void_type symmap_free_01853_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp312) ; __ats_lab_symmap_free_01853_ats_ptr_type: /* tmp312 = */ map_free_03466_ats_ptr_type_2cats_ptr_type (arg0) ; return /* (tmp312) */ ; } /* end of [symmap_free_01853_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 6480(line=241, offs=12) -- 7119(line=264, offs=4) */ ATSstaticdec() ats_void_type symenv_pop_01867_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_symenv_pop_01867_ats_ptr_type: tmp302 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_maplst) ; tmp301 = atspre_ref_get_view_ptr (tmp302) ; tmp303 = ats_selsin_mac(tmp301, atslab_1) ; tmp305 = ats_ptrget_mac(ats_ptr_type, tmp303) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp305 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_4, tmp305, atslab_0) ; tmp307 = ats_caselptrlab_mac(anairiats_sum_4, tmp305, atslab_1) ; ATS_FREE(tmp305) ; ats_ptrget_mac(ats_ptr_type, tmp303) = tmp307 ; tmp304 = tmp306 ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (tmp305 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: tmp304 = abort_45 () ; break ; } while (0) ; tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp308 = atspre_ref_get_view_ptr (tmp309) ; tmp310 = ats_selsin_mac(tmp308, atslab_1) ; tmp319 = ats_ptrget_mac(ats_ptr_type, tmp310) ; /* tmp311 = */ symmap_free_01853_ats_ptr_type (tmp319) ; ats_ptrget_mac(ats_ptr_type, tmp310) = tmp304 ; return /* (tmp295) */ ; } /* end of [symenv_pop_01867_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 7327(line=248, offs=17) -- 7421(line=250, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_pop () { /* local vardec */ // ATSlocal_void (tmp294) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_pop: /* tmp294 = */ symenv_pop_01867_ats_ptr_type (statmp98) ; return /* (tmp294) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 7478(line=253, offs=18) -- 7552(line=255, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_push () { /* local vardec */ // ATSlocal_void (tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_push: /* tmp320 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (statmp98) ; return /* (tmp320) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_push] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9491(line=371, offs=6) -- 9645(line=375, offs=6) */ ATSstaticdec() ats_ptr_type abort_53 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; __ats_lab_abort_53: /* tmp324 = */ prerr_interror_0363_ () ; /* tmp325 = */ atspre_prerr_string (ATSstrcst(": symenv_localjoin: env.maplst is empty")) ; /* tmp326 = */ atspre_prerr_newline () ; /* tmp323 = */ ats_exit (1) ; return (tmp323) ; } /* end of [abort_53] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10685(line=372, offs=7) -- 11400(line=386, offs=23) */ ATSstaticdec() ats_ptr_type aux_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_int_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp358) ; __ats_lab_aux_55: do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_59_0 ; } __ats_lab_56_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp349 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_2) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_3) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_4) ; ATS_FREE(arg1) ; tmp352 = aux_55 (arg0, tmp350, arg2) ; /* ats_int_type tmp353 ; */ /* ats_ptr_type tmp354 ; */ tmp355 = bst_remove_random_0257_ats_ptr_type_2cats_ptr_type (tmp352, tmp348, (&tmp353), (&tmp354), arg2) ; tmp356 = ats_selsin_mac(tmp355, atslab_2) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp354 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: ATS_FREE(tmp354) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (tmp354 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: break ; } while (0) ; tmp358 = bst_insert_random_0234_ats_ptr_type_2cats_ptr_type (tmp356, tmp348, tmp349, arg2) ; arg0 = tmp358 ; arg1 = tmp351 ; arg2 = arg2 ; goto __ats_lab_aux_55 ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: tmp347 = arg0 ; break ; } while (0) ; return (tmp347) ; } /* end of [aux_55] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10624(line=370, offs=10) -- 11531(line=391, offs=4) */ ATSstaticdec() ats_ptr_type map_join_03471_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; __ats_lab_map_join_03471_ats_ptr_type_2cats_ptr_type: // tmp359 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp360 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; // tmp361 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; ATS_FREE(arg1) ; tmp363 = ats_ptrget_mac(ats_ptr_type, tmp360) ; tmp362 = aux_55 (tmp363, tmp361, tmp359) ; ats_ptrget_mac(ats_ptr_type, tmp360) = tmp362 ; tmp346 = arg0 ; return (tmp346) ; } /* end of [map_join_03471_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9471(line=369, offs=18) -- 10587(line=406, offs=4) */ ATSstaticdec() ats_void_type symenv_localjoin_01872_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp322) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; // ATSlocal_void (tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp364) ; __ats_lab_symenv_localjoin_01872_ats_ptr_type: tmp328 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_maplst) ; tmp327 = atspre_ref_get_view_ptr (tmp328) ; tmp329 = ats_selsin_mac(tmp327, atslab_1) ; tmp331 = ats_ptrget_mac(ats_ptr_type, tmp329) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp331 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_4, tmp331, atslab_0) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_4, tmp331, atslab_1) ; ATS_FREE(tmp331) ; ats_ptrget_mac(ats_ptr_type, tmp329) = tmp333 ; tmp330 = tmp332 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (tmp331 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp330 = abort_53 () ; break ; } while (0) ; /* tmp334 = */ symmap_free_01853_ats_ptr_type (tmp330) ; tmp336 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_maplst) ; tmp335 = atspre_ref_get_view_ptr (tmp336) ; tmp337 = ats_selsin_mac(tmp335, atslab_1) ; tmp339 = ats_ptrget_mac(ats_ptr_type, tmp337) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (tmp339 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_4, tmp339, atslab_0) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_4, tmp339, atslab_1) ; ATS_FREE(tmp339) ; ats_ptrget_mac(ats_ptr_type, tmp337) = tmp341 ; tmp338 = tmp340 ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (tmp339 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: tmp338 = abort_53 () ; break ; } while (0) ; tmp343 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp342 = atspre_ref_get_view_ptr (tmp343) ; tmp344 = ats_selsin_mac(tmp342, atslab_1) ; tmp364 = ats_ptrget_mac(ats_ptr_type, tmp344) ; tmp345 = map_join_03471_ats_ptr_type_2cats_ptr_type (tmp338, tmp364) ; ats_ptrget_mac(ats_ptr_type, tmp344) = tmp345 ; return /* (tmp322) */ ; } /* end of [symenv_localjoin_01872_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 7617(line=259, offs=3) -- 7736(line=263, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_localjoin () { /* local vardec */ // ATSlocal_void (tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_localjoin: /* tmp321 = */ symenv_localjoin_01872_ats_ptr_type (statmp98) ; return /* (tmp321) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 7775(line=265, offs=4) -- 7924(line=269, offs=4) */ ATSstaticdec() ats_void_type the_s2rtenv_pervasive_add_topenv_56 () { /* local vardec */ // ATSlocal_void (tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; __ats_lab_the_s2rtenv_pervasive_add_topenv_56: tmp366 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp98) ; /* tmp365 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (statmp98, tmp366) ; return /* (tmp365) */ ; } /* end of [the_s2rtenv_pervasive_add_topenv_56] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01877_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ref_make_elt_01877_ats_ptr_type: /* ats_ptr_type tmp371 ; */ tmp371 = arg0 ; tmp370 = atspre_ref_make_elt_tsz ((&tmp371), sizeof(ats_ptr_type)) ; return (tmp370) ; } /* end of [ref_make_elt_01877_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 7974(line=271, offs=4) -- 8424(line=284, offs=4) */ ATSstaticdec() ats_void_type the_s2rtenv_namespace_add_topenv_57 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp372) ; // ATSlocal_void (tmp373) ; // ATSlocal_void (tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; __ats_lab_the_s2rtenv_namespace_add_topenv_57: tmp368 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp98) ; tmp369 = ref_make_elt_01877_ats_ptr_type (tmp368) ; tmp372 = hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (statmp3, arg0, tmp369) ; do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (tmp372 == (ats_sum_ptr_type)0) { goto __ats_lab_61_0 ; } __ats_lab_60_1: ATS_FREE(tmp372) ; /* tmp373 = */ prerr_interror_1 () ; /* tmp374 = */ atspre_prerr_string (ATSstrcst(": s2rtenv_namespace_add_topenv: id = ")) ; /* tmp375 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp376 = */ atspre_prerr_newline () ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (tmp372 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: break ; } while (0) ; return /* (tmp367) */ ; } /* end of [the_s2rtenv_namespace_add_topenv_57] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 8474(line=286, offs=4) -- 8529(line=286, offs=59) */ ATSstaticdec() ats_void_type the_s2rtenv_save_59 () { /* local vardec */ // ATSlocal_void (tmp377) ; __ats_lab_the_s2rtenv_save_59: /* tmp377 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (statmp98) ; return /* (tmp377) */ ; } /* end of [the_s2rtenv_save_59] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 8295(line=320, offs=6) -- 8435(line=324, offs=6) */ ATSstaticdec() anairiats_rec_8 abort_62 () { /* local vardec */ ATSlocal (anairiats_rec_8, tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; __ats_lab_abort_62: /* tmp381 = */ prerr_interror_0363_ () ; /* tmp382 = */ atspre_prerr_string (ATSstrcst(": symenv_restore: env.savedlst is empty")) ; /* tmp383 = */ atspre_prerr_newline () ; /* tmp380 = */ ats_exit (1) ; return (tmp380) ; } /* end of [abort_62] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3417(line=133, offs=3) -- 3607(line=138, offs=26) */ ATSstaticdec() ats_void_type symmaplst_free_0381_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; // ATSlocal_void (tmp405) ; __ats_lab_symmaplst_free_0381_ats_ptr_type: do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp405 = */ symmap_free_01853_ats_ptr_type (tmp403) ; arg0 = tmp404 ; goto __ats_lab_symmaplst_free_0381_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_65_1: break ; } while (0) ; return /* (tmp402) */ ; } /* end of [symmaplst_free_0381_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 8226(line=317, offs=16) -- 9145(line=351, offs=4) */ ATSstaticdec() ats_void_type symenv_restore_01874_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp379) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (anairiats_rec_8, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (anairiats_rec_8, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; // ATSlocal_void (tmp401) ; ATSlocal (ats_ptr_type, tmp406) ; __ats_lab_symenv_restore_01874_ats_ptr_type: tmp385 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_savedlst) ; tmp384 = atspre_ref_get_view_ptr (tmp385) ; tmp386 = ats_selsin_mac(tmp384, atslab_1) ; tmp388 = ats_ptrget_mac(ats_ptr_type, tmp386) ; do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (tmp388 == (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp389 = ats_caselptrlab_mac(anairiats_sum_9, tmp388, atslab_0) ; tmp390 = ats_caselptrlab_mac(anairiats_sum_9, tmp388, atslab_1) ; ATS_FREE(tmp388) ; ats_ptrget_mac(ats_ptr_type, tmp386) = tmp390 ; tmp387 = tmp389 ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (tmp388 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp387 = abort_62 () ; break ; } while (0) ; tmp391 = ats_select_mac(tmp387, atslab_0) ; tmp392 = ats_select_mac(tmp387, atslab_1) ; tmp394 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_map) ; tmp393 = atspre_ref_get_view_ptr (tmp394) ; tmp395 = ats_selsin_mac(tmp393, atslab_1) ; tmp397 = ats_ptrget_mac(ats_ptr_type, tmp395) ; /* tmp396 = */ symmap_free_01853_ats_ptr_type (tmp397) ; ats_ptrget_mac(ats_ptr_type, tmp395) = tmp391 ; tmp399 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_maplst) ; tmp398 = atspre_ref_get_view_ptr (tmp399) ; tmp400 = ats_selsin_mac(tmp398, atslab_1) ; tmp406 = ats_ptrget_mac(ats_ptr_type, tmp400) ; /* tmp401 = */ symmaplst_free_0381_ats_ptr_type (tmp406) ; ats_ptrget_mac(ats_ptr_type, tmp400) = tmp392 ; return /* (tmp379) */ ; } /* end of [symenv_restore_01874_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 8533(line=287, offs=4) -- 8594(line=287, offs=65) */ ATSstaticdec() ats_void_type the_s2rtenv_restore_60 () { /* local vardec */ // ATSlocal_void (tmp378) ; __ats_lab_the_s2rtenv_restore_60: /* tmp378 = */ symenv_restore_01874_ats_ptr_type (statmp98) ; return /* (tmp378) */ ; } /* end of [the_s2rtenv_restore_60] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 8825(line=303, offs=18) -- 9049(line=310, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add: tmp409 = symenv_remove_fst_01863_ats_ptr_type (statmp407, arg0) ; do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (tmp409 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: ATS_FREE(tmp409) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (tmp409 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: break ; } while (0) ; /* tmp408 = */ symenv_insert_fst_01862_ats_ptr_type (statmp407, arg0, arg1) ; return /* (tmp408) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 9112(line=313, offs=23) -- 9894(line=339, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst: tmp412 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sym (arg0) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp412) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (tmp414 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_68_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_2, tmp414, atslab_0) ; ATS_FREE(tmp414) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp415)->tag != 0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_7, tmp415, atslab_0) ; tmp413 = tmp416 ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: __ats_lab_70_1: tmp413 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (tmp414 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp413 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp417 = symenv_remove_fst_01863_ats_ptr_type (statmp407, tmp412) ; do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (tmp417 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: ATS_FREE(tmp417) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (tmp417 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: break ; } while (0) ; tmp420 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp420, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp420, atslab_1, tmp413) ; tmp419 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp419)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp419, atslab_0, tmp420) ; /* tmp411 = */ symenv_insert_fst_01862_ats_ptr_type (statmp407, tmp412, tmp419) ; return /* (tmp411) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 9962(line=342, offs=23) -- 10046(line=344, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar: tmp422 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg0) ; tmp423 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp423)->tag = 5 ; ats_selptrset_mac(anairiats_sum_7, tmp423, atslab_0, arg0) ; /* tmp421 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (tmp422, tmp423) ; return /* (tmp421) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 10117(line=347, offs=26) -- 10286(line=353, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; // ATSlocal_void (tmp427) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst: do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp427 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp425) ; arg0 = tmp426 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: break ; } while (0) ; return /* (tmp424) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 10383(line=358, offs=28) -- 10584(line=365, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datconptr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datconptr: tmp429 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (arg0) ; tmp430 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp429) ; tmp432 = atspre_string_append (tmp430, ATSstrcst("_unfold")) ; tmp431 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (tmp432) ; tmp433 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp433)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp433, atslab_0, arg0) ; /* tmp428 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (tmp431, tmp433) ; return /* (tmp428) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datconptr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 10662(line=368, offs=28) -- 10864(line=375, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datcontyp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datcontyp: tmp435 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (arg0) ; tmp436 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp435) ; tmp438 = atspre_string_append (tmp436, ATSstrcst("_pstruct")) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (tmp438) ; tmp439 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp439)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp439, atslab_0, arg0) ; /* tmp434 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add (tmp437, tmp439) ; return /* (tmp434) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datcontyp] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 10996(line=381, offs=6) -- 11464(line=393, offs=6) */ ATSstaticdec() ats_ptr_type f_71 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; __ats_lab_f_71: tmp443 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp6, arg0) ; do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (tmp443 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_2, tmp443, atslab_0) ; ATS_FREE(tmp443) ; tmp442 = tmp444 ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (tmp443 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: /* tmp445 = */ prerr_interror_1 () ; /* tmp446 = */ atspre_prerr_string (ATSstrcst(": the_s2expenv_namespace_find: name = ")) ; /* tmp447 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp448 = */ atspre_prerr_newline () ; /* tmp442 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp441 = symmap_ref_search_01855_ats_ptr_type (tmp442, env0) ; return (tmp441) ; } /* end of [f_71] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_71_closure_type ; ats_ptr_type f_71_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_71 (((f_71_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_71_closure_init (f_71_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_71_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_71_closure_make (ats_ptr_type env0) { f_71_closure_type *p_clo = ATS_MALLOC(sizeof(f_71_closure_type)) ; f_71_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 10929(line=379, offs=4) -- 11516(line=396, offs=4) */ ATSstaticdec() ats_ptr_type the_s2expenv_namespace_find_70 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_clo_ptr_type, tmp449) ; __ats_lab_the_s2expenv_namespace_find_70: /* ats_clo_ptr_type tmp449 ; */ tmp449 = f_71_closure_make (arg0) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search (tmp449) ; ATS_FREE(tmp449) ; return (tmp440) ; } /* end of [the_s2expenv_namespace_find_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 11586(line=399, offs=19) -- 12131(line=418, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find: tmp451 = symenv_search_all_01864_ats_ptr_type (statmp407, arg0) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (tmp451 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp450 = tmp451 ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (tmp451 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp452 = the_s2expenv_namespace_find_70 (arg0) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (tmp452 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp450 = tmp452 ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: // if (tmp452 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_81_1: tmp450 = symenv_pervasive_search_01865_ats_ptr_type (statmp407, arg0) ; break ; } while (0) ; break ; } while (0) ; return (tmp450) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 12201(line=421, offs=29) -- 12270(line=423, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pervasive_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pervasive_find: tmp453 = symenv_pervasive_search_01865_ats_ptr_type (statmp407, arg0) ; return (tmp453) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pervasive_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 12344(line=426, offs=23) -- 13484(line=458, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; // ATSlocal_void (tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; // ATSlocal_void (tmp463) ; // ATSlocal_void (tmp464) ; // ATSlocal_void (tmp465) ; // ATSlocal_void (tmp466) ; // ATSlocal_void (tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; // ATSlocal_void (tmp469) ; // ATSlocal_void (tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua: tmp455 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_s0taq_node) ; do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp455)->tag != 0) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp454 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (arg1) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp455)->tag != 3) { goto __ats_lab_89_0 ; } __ats_lab_83_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_7, tmp455, atslab_0) ; tmp457 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp456) ; do { /* branch: __ats_lab_84 */ __ats_lab_84_0: if (tmp457 == (ats_sum_ptr_type)0) { goto __ats_lab_85_0 ; } tmp459 = ats_caselptrlab_mac(anairiats_sum_2, tmp457, atslab_0) ; if (((ats_sum_ptr_type)tmp459)->tag != 4) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp460 = ats_caselptrlab_mac(anairiats_sum_7, tmp459, atslab_0) ; ATS_FREE(tmp457) ; tmp458 = tmp460 ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (tmp457 == (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: ATS_FREE(tmp457) ; tmp462 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_s0taq_loc) ; /* tmp461 = */ prerr_loc_error2_0 (tmp462) ; /* tmp463 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp464 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp456) ; /* tmp465 = */ atspre_prerr_string (ATSstrcst("] should refer to a filename but it does not.")) ; /* tmp466 = */ atspre_prerr_newline () ; /* tmp458 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: // if (tmp457 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_86_1: tmp468 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_s0taq_loc) ; /* tmp467 = */ prerr_loc_error2_0 (tmp468) ; /* tmp469 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp470 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp456) ; /* tmp471 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp472 = */ atspre_prerr_newline () ; /* tmp458 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp473 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (tmp458) ; tmp474 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp6, tmp473) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp474 == (ats_sum_ptr_type)0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp475 = ats_caselptrlab_mac(anairiats_sum_2, tmp474, atslab_0) ; ATS_FREE(tmp474) ; tmp454 = symmap_ref_search_01855_ats_ptr_type (tmp475, arg1) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: // if (tmp474 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_88_1: tmp454 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: tmp454 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp454) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 13547(line=461, offs=18) -- 13642(line=463, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () { /* local vardec */ // ATSlocal_void (tmp476) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop: /* tmp476 = */ symenv_pop_01867_ats_ptr_type (statmp407) ; return /* (tmp476) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 13701(line=466, offs=19) -- 13776(line=468, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () { /* local vardec */ // ATSlocal_void (tmp477) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push: /* tmp477 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (statmp407) ; return /* (tmp477) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 13841(line=471, offs=24) -- 13961(line=475, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_localjoin () { /* local vardec */ // ATSlocal_void (tmp478) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_localjoin: /* tmp478 = */ symenv_localjoin_01872_ats_ptr_type (statmp407) ; return /* (tmp478) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 14001(line=477, offs=4) -- 14153(line=481, offs=4) */ ATSstaticdec() ats_void_type the_s2expenv_pervasive_add_topenv_78 () { /* local vardec */ // ATSlocal_void (tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; __ats_lab_the_s2expenv_pervasive_add_topenv_78: tmp480 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp407) ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (statmp407, tmp480) ; return /* (tmp479) */ ; } /* end of [the_s2expenv_pervasive_add_topenv_78] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 14204(line=483, offs=4) -- 14659(line=496, offs=4) */ ATSstaticdec() ats_void_type the_s2expenv_namespace_add_topenv_79 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; __ats_lab_the_s2expenv_namespace_add_topenv_79: tmp482 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp407) ; tmp483 = ref_make_elt_01877_ats_ptr_type (tmp482) ; tmp484 = hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (statmp6, arg0, tmp483) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (tmp484 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: ATS_FREE(tmp484) ; /* tmp485 = */ prerr_interror_1 () ; /* tmp486 = */ atspre_prerr_string (ATSstrcst(": the_s2expenv_namespace_add_topenv: id = ")) ; /* tmp487 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp488 = */ atspre_prerr_newline () ; /* tmp481 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (tmp484 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: break ; } while (0) ; return /* (tmp481) */ ; } /* end of [the_s2expenv_namespace_add_topenv_79] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 14710(line=498, offs=4) -- 14767(line=498, offs=61) */ ATSstaticdec() ats_void_type the_s2expenv_save_80 () { /* local vardec */ // ATSlocal_void (tmp489) ; __ats_lab_the_s2expenv_save_80: /* tmp489 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (statmp407) ; return /* (tmp489) */ ; } /* end of [the_s2expenv_save_80] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 14771(line=499, offs=4) -- 14834(line=499, offs=67) */ ATSstaticdec() ats_void_type the_s2expenv_restore_81 () { /* local vardec */ // ATSlocal_void (tmp490) ; __ats_lab_the_s2expenv_restore_81: /* tmp490 = */ symenv_restore_01874_ats_ptr_type (statmp407) ; return /* (tmp490) */ ; } /* end of [the_s2expenv_restore_81] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01877_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_int_type, tmp493) ; __ats_lab_ref_make_elt_01877_ats_int_type: /* ats_int_type tmp493 ; */ tmp493 = arg0 ; tmp492 = atspre_ref_make_elt_tsz ((&tmp493), sizeof(ats_int_type)) ; return (tmp492) ; } /* end of [ref_make_elt_01877_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 14978(line=511, offs=22) -- 14994(line=511, offs=38) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_get () { /* local vardec */ ATSlocal (ats_int_type, tmp494) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_get: tmp494 = ats_ptrget_mac(ats_int_type, statmp491) ; return (tmp494) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 15016(line=512, offs=22) -- 15074(line=514, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_inc () { /* local vardec */ // ATSlocal_void (tmp495) ; ATSlocal (ats_int_type, tmp496) ; ATSlocal (ats_int_type, tmp497) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_inc: tmp496 = ats_ptrget_mac(ats_int_type, statmp491) ; tmp497 = atspre_add_int_int (tmp496, 1) ; ats_ptrget_mac(ats_int_type, statmp491) = tmp497 ; return /* (tmp495) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 15119(line=515, offs=22) -- 15177(line=517, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_dec () { /* local vardec */ // ATSlocal_void (tmp498) ; ATSlocal (ats_int_type, tmp499) ; ATSlocal (ats_int_type, tmp500) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_dec: tmp499 = ats_ptrget_mac(ats_int_type, statmp491) ; tmp500 = atspre_sub_int_int (tmp499, 1) ; ats_ptrget_mac(ats_int_type, statmp491) = tmp500 ; return /* (tmp498) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macdef_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 15354(line=530, offs=17) -- 15375(line=530, offs=38) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get () { /* local vardec */ ATSlocal (ats_int_type, tmp502) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get: tmp502 = ats_ptrget_mac(ats_int_type, statmp501) ; return (tmp502) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 15403(line=533, offs=17) -- 15691(line=545, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp503) ; ATSlocal (ats_int_type, tmp504) ; ATSlocal (ats_int_type, tmp505) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc: tmp504 = ats_ptrget_mac(ats_int_type, statmp501) ; tmp505 = atspre_add_int_int (tmp504, 1) ; ats_ptrget_mac(ats_int_type, statmp501) = tmp505 ; return /* (tmp503) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 15747(line=548, offs=17) -- 16039(line=558, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp506) ; ATSlocal (ats_int_type, tmp507) ; // ATSlocal_void (tmp508) ; ATSlocal (ats_bool_type, tmp509) ; // ATSlocal_void (tmp510) ; // ATSlocal_void (tmp511) ; // ATSlocal_void (tmp512) ; ATSlocal (ats_int_type, tmp513) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec: tmp507 = ats_ptrget_mac(ats_int_type, statmp501) ; tmp509 = atspre_eq_int_int (tmp507, 0) ; if (tmp509) { /* tmp510 = */ prerr_loc_error2_0 (arg0) ; /* tmp511 = */ atspre_prerr_string (ATSstrcst(": the syntax ,(...) or %(...) is used incorrectly at this location.")) ; /* tmp512 = */ atspre_prerr_newline () ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp513 = atspre_sub_int_int (tmp507, 1) ; ats_ptrget_mac(ats_int_type, statmp501) = tmp513 ; return /* (tmp506) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__macro_level_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 16201(line=571, offs=20) -- 16225(line=571, offs=44) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get () { /* local vardec */ ATSlocal (ats_int_type, tmp515) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get: tmp515 = ats_ptrget_mac(ats_int_type, statmp514) ; return (tmp515) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 16256(line=574, offs=20) -- 16309(line=575, offs=49) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc () { /* local vardec */ // ATSlocal_void (tmp516) ; ATSlocal (ats_int_type, tmp517) ; ATSlocal (ats_int_type, tmp518) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc: tmp518 = ats_ptrget_mac(ats_int_type, statmp514) ; tmp517 = atspre_add_int_int (tmp518, 1) ; ats_ptrget_mac(ats_int_type, statmp514) = tmp517 ; return /* (tmp516) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 16371(line=578, offs=30) -- 16424(line=579, offs=49) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec () { /* local vardec */ // ATSlocal_void (tmp519) ; ATSlocal (ats_int_type, tmp520) ; ATSlocal (ats_int_type, tmp521) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec: tmp521 = ats_ptrget_mac(ats_int_type, statmp514) ; tmp520 = atspre_sub_int_int (tmp521, 1) ; ats_ptrget_mac(ats_int_type, statmp514) = tmp520 ; return /* (tmp519) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 16509(line=585, offs=20) -- 16979(line=600, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp522) ; ATSlocal (ats_int_type, tmp523) ; ATSlocal (ats_bool_type, tmp524) ; ATSlocal (ats_int_type, tmp525) ; ATSlocal (ats_bool_type, tmp526) ; // ATSlocal_void (tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; // ATSlocal_void (tmp531) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev: tmp523 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_tmplev (arg1) ; do { /* branch: __ats_lab_92 */ __ats_lab_92_0: __ats_lab_92_1: tmp524 = atspre_gt_int_int (tmp523, 0) ; if (!tmp524) { goto __ats_lab_93_1 ; } tmp525 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__template_level_get () ; tmp526 = atspre_lt_int_int (tmp523, tmp525) ; if (tmp526) { /* tmp527 = */ prerr_loc_error2_0 (arg0) ; /* tmp528 = */ atspre_prerr_string (ATSstrcst(": the static variable [")) ; /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg1) ; /* tmp530 = */ atspre_prerr_string (ATSstrcst("] is out of scope.")) ; /* tmp531 = */ atspre_prerr_newline () ; /* tmp522 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: __ats_lab_93_1: break ; } while (0) ; return /* (tmp522) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17073(line=605, offs=7) -- 17284(line=611, offs=19) */ ATSstaticdec() ats_void_type aux_s2vs_94 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; // ATSlocal_void (tmp536) ; __ats_lab_aux_s2vs_94: do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp534 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp535 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp536 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_tmplev (tmp534, arg1) ; arg0 = tmp535 ; arg1 = arg1 ; goto __ats_lab_aux_s2vs_94 ; // tail call break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_95_1: break ; } while (0) ; return /* (tmp533) */ ; } /* end of [aux_s2vs_94] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17291(line=612, offs=7) -- 17511(line=617, offs=19) */ ATSstaticdec() ats_void_type aux_s2qualst_95 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp537) ; ATSlocal (anairiats_rec_8, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; // ATSlocal_void (tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; __ats_lab_aux_s2qualst_95: do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp538 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp539 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp541 = ats_select_mac(tmp538, atslab_0) ; /* tmp540 = */ aux_s2vs_94 (tmp541, arg1) ; arg0 = tmp539 ; arg1 = arg1 ; goto __ats_lab_aux_s2qualst_95 ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: break ; } while (0) ; return /* (tmp537) */ ; } /* end of [aux_s2qualst_95] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17044(line=604, offs=3) -- 17550(line=620, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp532) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev: /* tmp532 = */ aux_s2qualst_95 (arg0, arg1) ; return /* (tmp532) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2qualst_set_tmplev] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17757(line=632, offs=25) -- 17786(line=632, offs=54) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () { /* local vardec */ ATSlocal (ats_int_type, tmp543) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get: tmp543 = ats_ptrget_mac(ats_int_type, statmp542) ; return (tmp543) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17821(line=634, offs=25) -- 17857(line=634, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp544) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set: ats_ptrget_mac(ats_int_type, statmp542) = arg0 ; return /* (tmp544) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_set] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 17894(line=637, offs=25) -- 18008(line=642, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc () { /* local vardec */ // ATSlocal_void (tmp545) ; ATSlocal (ats_int_type, tmp546) ; ATSlocal (ats_int_type, tmp547) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc: tmp546 = ats_ptrget_mac(ats_int_type, statmp542) ; tmp547 = atspre_add_int_int (tmp546, 1) ; ats_ptrget_mac(ats_int_type, statmp542) = tmp547 ; return /* (tmp545) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 18080(line=645, offs=25) -- 18201(line=649, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec () { /* local vardec */ // ATSlocal_void (tmp548) ; ATSlocal (ats_int_type, tmp549) ; ATSlocal (ats_int_type, tmp550) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec: tmp549 = ats_ptrget_mac(ats_int_type, statmp542) ; tmp550 = atspre_sub_int_int (tmp549, 1) ; ats_ptrget_mac(ats_int_type, statmp542) = tmp550 ; return /* (tmp548) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 18489(line=667, offs=18) -- 18713(line=674, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add: tmp553 = symenv_remove_fst_01863_ats_ptr_type (statmp551, arg0) ; do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (tmp553 == (ats_sum_ptr_type)0) { goto __ats_lab_99_0 ; } __ats_lab_98_1: ATS_FREE(tmp553) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: // if (tmp553 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_99_1: break ; } while (0) ; /* tmp552 = */ symenv_insert_fst_01862_ats_ptr_type (statmp551, arg0, arg1) ; return /* (tmp552) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 18776(line=677, offs=23) -- 19330(line=694, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon: tmp556 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (arg0) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (tmp556) ; do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (tmp558 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_100_1: tmp559 = ats_caselptrlab_mac(anairiats_sum_2, tmp558, atslab_0) ; ATS_FREE(tmp558) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp559)->tag != 0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp560 = ats_caselptrlab_mac(anairiats_sum_7, tmp559, atslab_0) ; tmp557 = tmp560 ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: __ats_lab_102_1: tmp557 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (tmp558 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: tmp557 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp561 = symenv_remove_fst_01863_ats_ptr_type (statmp551, tmp556) ; do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (tmp561 == (ats_sum_ptr_type)0) { goto __ats_lab_105_0 ; } __ats_lab_104_1: ATS_FREE(tmp561) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (tmp561 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: break ; } while (0) ; tmp564 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp564, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp564, atslab_1, tmp557) ; tmp563 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp563)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp563, atslab_0, tmp564) ; /* tmp555 = */ symenv_insert_fst_01862_ats_ptr_type (statmp551, tmp556, tmp563) ; return /* (tmp555) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 19398(line=697, offs=23) -- 19492(line=699, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcst: tmp566 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg0) ; tmp567 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp567)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp567, atslab_0, arg0) ; /* tmp565 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp566, tmp567) ; return /* (tmp565) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 19564(line=702, offs=27) -- 19651(line=704, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def: tmp569 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym (arg0) ; tmp570 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp570)->tag = 3 ; ats_selptrset_mac(anairiats_sum_7, tmp570, atslab_0, arg0) ; /* tmp568 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp569, tmp570) ; return /* (tmp568) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_def] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 19727(line=707, offs=27) -- 19814(line=709, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var: tmp572 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp573 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp573)->tag = 4 ; ats_selptrset_mac(anairiats_sum_7, tmp573, atslab_0, arg0) ; /* tmp571 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp572, tmp573) ; return /* (tmp571) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 19893(line=712, offs=30) -- 19969(line=714, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp574) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_varlst: /* tmp574 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_var) ; return /* (tmp574) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dmac_varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 20044(line=717, offs=23) -- 20128(line=719, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar: tmp576 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp577 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp577)->tag = 6 ; ats_selptrset_mac(anairiats_sum_7, tmp577, atslab_0, arg0) ; /* tmp575 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (tmp576, tmp577) ; return /* (tmp575) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 20199(line=722, offs=26) -- 20271(line=724, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp578) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst: /* tmp578 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvar) ; return /* (tmp578) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dvarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 20401(line=730, offs=6) -- 20855(line=742, offs=6) */ ATSstaticdec() ats_ptr_type f_109 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; // ATSlocal_void (tmp584) ; // ATSlocal_void (tmp585) ; // ATSlocal_void (tmp586) ; // ATSlocal_void (tmp587) ; __ats_lab_f_109: tmp581 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp9, arg0) ; do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (tmp581 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp583 = ats_caselptrlab_mac(anairiats_sum_2, tmp581, atslab_0) ; ATS_FREE(tmp581) ; tmp582 = tmp583 ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (tmp581 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: /* tmp584 = */ prerr_interror_1 () ; /* tmp585 = */ atspre_prerr_string (ATSstrcst(": d2expenv_namespace_find: name = ")) ; /* tmp586 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp587 = */ atspre_prerr_newline () ; /* tmp582 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp580 = symmap_ref_search_01855_ats_ptr_type (tmp582, env0) ; return (tmp580) ; } /* end of [f_109] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_109_closure_type ; ats_ptr_type f_109_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_109 (((f_109_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_109_closure_init (f_109_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_109_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_109_closure_make (ats_ptr_type env0) { f_109_closure_type *p_clo = ATS_MALLOC(sizeof(f_109_closure_type)) ; f_109_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 20334(line=728, offs=4) -- 20907(line=745, offs=4) */ ATSstaticdec() ats_ptr_type the_d2expenv_namespace_find_108 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_clo_ptr_type, tmp588) ; __ats_lab_the_d2expenv_namespace_find_108: /* ats_clo_ptr_type tmp588 ; */ tmp588 = f_109_closure_make (arg0) ; tmp579 = ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search (tmp588) ; ATS_FREE(tmp588) ; return (tmp579) ; } /* end of [the_d2expenv_namespace_find_108] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 20977(line=748, offs=19) -- 21850(line=780, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find: tmp590 = symenv_search_all_01864_ats_ptr_type (statmp551, arg0) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp590 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp589 = tmp590 ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (tmp590 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: tmp591 = the_d2expenv_namespace_find_108 (arg0) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (tmp591 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp589 = tmp591 ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (tmp591 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: tmp589 = symenv_pervasive_search_01865_ats_ptr_type (statmp551, arg0) ; break ; } while (0) ; break ; } while (0) ; return (tmp589) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 21939(line=785, offs=27) -- 21992(line=786, offs=47) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_current_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp592) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_current_find: tmp592 = symenv_search_all_01864_ats_ptr_type (statmp551, arg0) ; return (tmp592) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_current_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 22070(line=790, offs=29) -- 22139(line=792, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp593) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find: tmp593 = symenv_pervasive_search_01865_ats_ptr_type (statmp551, arg0) ; return (tmp593) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 22234(line=797, offs=23) -- 23307(line=826, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; // ATSlocal_void (tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; // ATSlocal_void (tmp603) ; // ATSlocal_void (tmp604) ; // ATSlocal_void (tmp605) ; // ATSlocal_void (tmp606) ; // ATSlocal_void (tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; // ATSlocal_void (tmp609) ; // ATSlocal_void (tmp610) ; // ATSlocal_void (tmp611) ; // ATSlocal_void (tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua: tmp595 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_d0ynq_node) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp595)->tag != 0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp594 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find (arg1) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp595)->tag != 4) { goto __ats_lab_119_0 ; } __ats_lab_113_1: tmp596 = ats_caselptrlab_mac(anairiats_sum_7, tmp595, atslab_0) ; tmp598 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp596) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp598 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } tmp599 = ats_caselptrlab_mac(anairiats_sum_2, tmp598, atslab_0) ; if (((ats_sum_ptr_type)tmp599)->tag != 4) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp600 = ats_caselptrlab_mac(anairiats_sum_7, tmp599, atslab_0) ; ATS_FREE(tmp598) ; tmp597 = tmp600 ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (tmp598 == (ats_sum_ptr_type)0) { goto __ats_lab_116_0 ; } __ats_lab_115_1: ATS_FREE(tmp598) ; tmp602 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_d0ynq_loc) ; /* tmp601 = */ prerr_loc_error2_0 (tmp602) ; /* tmp603 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp604 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp596) ; /* tmp605 = */ atspre_prerr_string (ATSstrcst("] should refer to a filename but it does not.")) ; /* tmp606 = */ atspre_prerr_newline () ; /* tmp597 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (tmp598 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: tmp608 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_d0ynq_loc) ; /* tmp607 = */ prerr_loc_error2_0 (tmp608) ; /* tmp609 = */ atspre_prerr_string (ATSstrcst(": the qualifier [")) ; /* tmp610 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp596) ; /* tmp611 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp612 = */ atspre_prerr_newline () ; /* tmp597 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp613 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_full_sym (tmp597) ; tmp614 = hashtbl_search_01814_ats_ptr_type_2cats_ptr_type (statmp9, tmp613) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (tmp614 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp615 = ats_caselptrlab_mac(anairiats_sum_2, tmp614, atslab_0) ; ATS_FREE(tmp614) ; tmp594 = symmap_ref_search_01855_ats_ptr_type (tmp615, arg1) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (tmp614 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp594 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: __ats_lab_119_1: tmp594 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp594) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_find_qua] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 23391(line=831, offs=18) -- 23486(line=833, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop () { /* local vardec */ // ATSlocal_void (tmp616) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop: /* tmp616 = */ symenv_pop_01867_ats_ptr_type (statmp551) ; return /* (tmp616) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 23545(line=836, offs=19) -- 23620(line=838, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push () { /* local vardec */ // ATSlocal_void (tmp617) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push: /* tmp617 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (statmp551) ; return /* (tmp617) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 23680(line=841, offs=19) -- 23733(line=842, offs=44) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_swap (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp618) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_swap: /* tmp618 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_swap (statmp551, arg0) ; return /* (tmp618) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_swap] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 23821(line=849, offs=3) -- 23941(line=852, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_localjoin () { /* local vardec */ // ATSlocal_void (tmp619) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_localjoin: /* tmp619 = */ symenv_localjoin_01872_ats_ptr_type (statmp551) ; return /* (tmp619) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 24002(line=856, offs=4) -- 24154(line=859, offs=4) */ ATSstaticdec() ats_void_type the_d2expenv_pervasive_add_topenv_118 () { /* local vardec */ // ATSlocal_void (tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; __ats_lab_the_d2expenv_pervasive_add_topenv_118: tmp621 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp551) ; /* tmp620 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (statmp551, tmp621) ; return /* (tmp620) */ ; } /* end of [the_d2expenv_pervasive_add_topenv_118] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 24205(line=861, offs=4) -- 24656(line=874, offs=4) */ ATSstaticdec() ats_void_type the_d2expenv_namespace_add_topenv_119 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; // ATSlocal_void (tmp628) ; // ATSlocal_void (tmp629) ; __ats_lab_the_d2expenv_namespace_add_topenv_119: tmp623 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp551) ; tmp624 = ref_make_elt_01877_ats_ptr_type (tmp623) ; tmp625 = hashtbl_insert_01815_ats_ptr_type_2cats_ptr_type (statmp9, arg0, tmp624) ; do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (tmp625 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: ATS_FREE(tmp625) ; /* tmp626 = */ prerr_interror_1 () ; /* tmp627 = */ atspre_prerr_string (ATSstrcst(": d2expenv_namespace_add_topenv: id = ")) ; /* tmp628 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg0) ; /* tmp629 = */ atspre_prerr_newline () ; /* tmp622 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (tmp625 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: break ; } while (0) ; return /* (tmp622) */ ; } /* end of [the_d2expenv_namespace_add_topenv_119] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 24728(line=878, offs=4) -- 24785(line=878, offs=61) */ ATSstaticdec() ats_void_type the_d2expenv_save_120 () { /* local vardec */ // ATSlocal_void (tmp630) ; __ats_lab_the_d2expenv_save_120: /* tmp630 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (statmp551) ; return /* (tmp630) */ ; } /* end of [the_d2expenv_save_120] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 24789(line=879, offs=4) -- 24852(line=879, offs=67) */ ATSstaticdec() ats_void_type the_d2expenv_restore_121 () { /* local vardec */ // ATSlocal_void (tmp631) ; __ats_lab_the_d2expenv_restore_121: /* tmp631 = */ symenv_restore_01874_ats_ptr_type (statmp551) ; return /* (tmp631) */ ; } /* end of [the_d2expenv_restore_121] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 25043(line=893, offs=25) -- 25066(line=893, offs=48) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_get_level () { /* local vardec */ ATSlocal (ats_int_type, tmp633) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_get_level: tmp633 = ats_ptrget_mac(ats_int_type, statmp632) ; return (tmp633) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_get_level] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 25097(line=896, offs=20) -- 25214(line=901, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_push () { /* local vardec */ // ATSlocal_void (tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_int_type, tmp637) ; ATSlocal (ats_int_type, tmp638) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_push: tmp635 = atspre_ref_get_view_ptr (statmp632) ; tmp636 = ats_selsin_mac(tmp635, atslab_1) ; tmp638 = ats_ptrget_mac(ats_int_type, tmp636) ; tmp637 = atspre_add_int_int (tmp638, 1) ; ats_ptrget_mac(ats_int_type, tmp636) = tmp637 ; return /* (tmp634) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 25274(line=904, offs=19) -- 25399(line=909, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_pop () { /* local vardec */ // ATSlocal_void (tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_int_type, tmp642) ; ATSlocal (ats_int_type, tmp643) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_pop: tmp640 = atspre_ref_get_view_ptr (statmp632) ; tmp641 = ats_selsin_mac(tmp640, atslab_1) ; tmp643 = ats_ptrget_mac(ats_int_type, tmp641) ; tmp642 = atspre_sub_int_int (tmp643, 1) ; ats_ptrget_mac(ats_int_type, tmp641) = tmp642 ; return /* (tmp639) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_level_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 25637(line=924, offs=16) -- 25849(line=931, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop () { /* local vardec */ // ATSlocal_void (tmp644) ; // ATSlocal_void (tmp645) ; // ATSlocal_void (tmp646) ; // ATSlocal_void (tmp647) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop: /* tmp645 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_pop () ; /* tmp646 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_pop () ; /* tmp647 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; /* tmp644 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pop () ; return /* (tmp644) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 25904(line=934, offs=17) -- 26101(line=941, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push () { /* local vardec */ // ATSlocal_void (tmp648) ; // ATSlocal_void (tmp649) ; // ATSlocal_void (tmp650) ; // ATSlocal_void (tmp651) ; // ATSlocal_void (tmp652) ; // ATSlocal_void (tmp653) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push: /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_push () ; /* tmp650 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_push () ; /* tmp651 = ats_selsin_mac(tmp650, atslab_1) */ ; /* tmp652 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp653 = ats_selsin_mac(tmp652, atslab_1) */ ; /* tmp648 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_push () ; return /* (tmp648) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 26162(line=944, offs=22) -- 26428(line=951, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_localjoin () { /* local vardec */ // ATSlocal_void (tmp654) ; // ATSlocal_void (tmp655) ; // ATSlocal_void (tmp656) ; // ATSlocal_void (tmp657) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_localjoin: /* tmp655 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_localjoin () ; /* tmp656 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_localjoin () ; /* tmp657 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_localjoin () ; /* tmp654 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_localjoin () ; return /* (tmp654) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 26533(line=958, offs=17) -- 26682(line=963, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_save () { /* local vardec */ // ATSlocal_void (tmp658) ; // ATSlocal_void (tmp659) ; // ATSlocal_void (tmp660) ; // ATSlocal_void (tmp661) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_save: /* tmp659 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_save () ; /* tmp660 = */ the_s2rtenv_save_59 () ; /* tmp661 = */ the_s2expenv_save_80 () ; /* tmp658 = */ the_d2expenv_save_120 () ; return /* (tmp658) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_save] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 26741(line=966, offs=20) -- 26902(line=971, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_restore () { /* local vardec */ // ATSlocal_void (tmp662) ; // ATSlocal_void (tmp663) ; // ATSlocal_void (tmp664) ; // ATSlocal_void (tmp665) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_restore: /* tmp663 = */ ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_restore () ; /* tmp664 = */ the_s2rtenv_restore_60 () ; /* tmp665 = */ the_s2expenv_restore_81 () ; /* tmp662 = */ the_d2expenv_restore_121 () ; return /* (tmp662) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_restore] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 26977(line=974, offs=33) -- 27137(line=978, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv () { /* local vardec */ // ATSlocal_void (tmp666) ; // ATSlocal_void (tmp667) ; // ATSlocal_void (tmp668) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv: /* tmp667 = */ the_s2rtenv_pervasive_add_topenv_56 () ; /* tmp668 = */ the_s2expenv_pervasive_add_topenv_78 () ; /* tmp666 = */ the_d2expenv_pervasive_add_topenv_118 () ; return /* (tmp666) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 27225(line=981, offs=33) -- 27393(line=985, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_namespace_add_topenv (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp669) ; // ATSlocal_void (tmp670) ; // ATSlocal_void (tmp671) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_namespace_add_topenv: /* tmp670 = */ the_s2rtenv_namespace_add_topenv_57 (arg0) ; /* tmp671 = */ the_s2expenv_namespace_add_topenv_79 (arg0) ; /* tmp669 = */ the_d2expenv_namespace_add_topenv_119 (arg0) ; return /* (tmp669) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_namespace_add_topenv] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_env.dats: 27471(line=988, offs=23) -- 28430(line=1007, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_initialize () { /* local vardec */ // ATSlocal_void (tmp672) ; // ATSlocal_void (tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; // ATSlocal_void (tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; // ATSlocal_void (tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; // ATSlocal_void (tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; // ATSlocal_void (tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; // ATSlocal_void (tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; // ATSlocal_void (tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; // ATSlocal_void (tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; // ATSlocal_void (tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; // ATSlocal_void (tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; // ATSlocal_void (tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; // ATSlocal_void (tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; // ATSlocal_void (tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; // ATSlocal_void (tmp699) ; // ATSlocal_void (tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_initialize: tmp674 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp674)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp674, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; /* tmp673 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR, tmp674) ; tmp676 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp676)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp676, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; /* tmp675 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL, tmp676) ; tmp678 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp678)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp678, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; /* tmp677 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR, tmp678) ; tmp680 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp680)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp680, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; /* tmp679 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS, tmp680) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp682)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp682, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff) ; /* tmp681 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF, tmp682) ; tmp684 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp684)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp684, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; /* tmp683 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT, tmp684) ; tmp686 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp686)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp686, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; /* tmp685 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP, tmp686) ; tmp688 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp688)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp688, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; /* tmp687 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE, tmp688) ; tmp690 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp690)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp690, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; /* tmp689 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE, tmp690) ; tmp692 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp692)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp692, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; /* tmp691 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW, tmp692) ; tmp694 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp694)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp694, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; /* tmp693 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE, tmp694) ; tmp696 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp696)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp696, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; /* tmp695 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE, tmp696) ; tmp698 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp698)->tag = 0 ; ats_selptrset_mac(anairiats_sum_7, tmp698, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types) ; /* tmp697 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES, tmp698) ; /* tmp699 = */ the_s2rtenv_pervasive_add_topenv_56 () ; tmp702 = (ats_sum_ptr_type)0 ; tmp701 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp701)->tag = 5 ; ats_selptrset_mac(anairiats_sum_7, tmp701, atslab_0, tmp702) ; /* tmp700 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS, tmp701) ; /* tmp672 = */ the_d2expenv_pervasive_add_topenv_118 () ; return /* (tmp672) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_initialize] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp12, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp98, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp407, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp491, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp501, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp514, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp542, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp551, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp632, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (&__ats_fun_2, &__ats_fun_3, 256) ; statmp6 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (&__ats_fun_4, &__ats_fun_5, 256) ; statmp9 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (&__ats_fun_6, &__ats_fun_7, 256) ; statmp12 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (&__ats_fun_8, &__ats_fun_9, 256) ; statmp98 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () ; statmp407 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () ; statmp491 = ref_make_elt_01877_ats_int_type (0) ; statmp501 = ref_make_elt_01877_ats_int_type (1) ; statmp514 = ref_make_elt_01877_ats_int_type (0) ; statmp542 = ref_make_elt_01877_ats_int_type (0) ; statmp551 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () ; statmp632 = ref_make_elt_01877_ats_int_type (0) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_env_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hashtbl_dats.c0000664000175000017500000002226612223166160021554 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hash ; ats_ptr_type atslab_eq ; ats_int_type atslab_size ; ats_int_type atslab_nitm ; ats_ptr_type atslab_table[] ; } anairiats_rec_0 ; /* external typedefs */ typedef ats_ptr_type chain ; typedef anairiats_rec_0 hashtbl_struct ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imul) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_uimod) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_ulint) (ats_ulint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ulint_type, atspre_string_hash_33) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_takeout_tsz) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_htp_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, __ats_htp_free) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__sasp__hashtbl_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01692_ats_ptr_type (ats_ptr_type arg0) ; static ats_uint_type __ats_fun_4 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp6) ; /* external value variable declarations */ ats_ptr_type CHAINnil ; /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5116(line=164, offs=27) -- 5385(line=174, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_size_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get: tmp1 = atspre_size1_of_int1 (arg1) ; tmp2 = atspre_array_ptr_takeout_tsz (arg0, tmp1, sizeof(ats_ptr_type)) ; tmp3 = ats_selsin_mac(tmp2, atslab_2) ; tmp4 = ats_ptrget_mac(ats_ptr_type, tmp3) ; tmp5 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp3) = tmp5 ; tmp0 = tmp4 ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01692_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ref_make_elt_01692_ats_ptr_type: /* ats_ptr_type tmp11 ; */ tmp11 = arg0 ; tmp10 = atspre_ref_make_elt_tsz ((&tmp11), sizeof(ats_ptr_type)) ; return (tmp10) ; } /* end of [ref_make_elt_01692_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 9614(line=341, offs=18) -- 9883(line=349, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint: tmp8 = ats_htp_make (arg0, arg1, arg2) ; tmp9 = ats_selsin_mac(tmp8, atslab_1) ; tmp12 = tmp9 ; tmp7 = ref_make_elt_01692_ats_ptr_type (tmp12) ; return (tmp7) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 9975(line=353, offs=16) -- 10036(line=353, offs=77) */ ATSstaticdec() ats_uint_type __ats_fun_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp14) ; ATSlocal (ats_ulint_type, tmp15) ; __ats_lab___ats_fun_4: tmp15 = atspre_string_hash_33 (arg0) ; tmp14 = atspre_uint_of_ulint (tmp15) ; return (tmp14) ; } /* end of [__ats_fun_4] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 9947(line=352, offs=23) -- 10096(line=356, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint (&__ats_fun_4, &atspre_eq_string_string, arg0) ; return (tmp13) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; /* marking external values for GC */ ATS_GC_MARKROOT (&CHAINnil, sizeof(ats_ptr_type)) ; /* code for dynamic loading */ statmp6 = (ats_sum_ptr_type)0 ; ATS_GC_MARKROOT(&CHAINnil, sizeof(ats_ptr_type)) ; CHAINnil = statmp6 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_ptr_type ats_htp_make ( ats_ptr_type hash, ats_ptr_type eq, ats_int_type sz ) { int n ; hashtbl_struct *htp ; htp = ATS_MALLOC (sizeof(hashtbl_struct) + sz * sizeof(chain)) ; // htp->atslab_hash = hash ; htp->atslab_eq = eq ; htp->atslab_size = sz ; // for (n = 0 ; n < sz ; ++n) { htp->atslab_table[n] = CHAINnil ; } // return htp ; } // end of [ats_htp_make] ats_void_type __ats_htp_free ( ats_ptr_type htp ) { ATS_FREE (htp) ; return ; } // end of [__ats_htp_free] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hashtbl_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hiexp_util_dats.c0000664000175000017500000035517712223166160022313 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_hiclau_loc ; ats_ptr_type atslab_hiclau_pat ; ats_ptr_type atslab_hiclau_gua ; ats_ptr_type atslab_hiclau_exp ; } anairiats_rec_10 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_11 ; typedef struct { ats_bool_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_12 ; typedef struct { anairiats_rec_12 atslab_0 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_14 ; typedef struct { ats_ptr_type atslab_hidec_loc ; ats_ptr_type atslab_hidec_node ; } anairiats_rec_15 ; typedef struct { ats_ptr_type atslab_hivaldec_loc ; ats_ptr_type atslab_hivaldec_pat ; ats_ptr_type atslab_hivaldec_def ; } anairiats_rec_16 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_tmpdef_arg ; ats_ptr_type atslab_tmpdef_exp ; } anairiats_rec_18 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_19 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITs2var_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyarr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrectemp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrecsin_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysumtemp_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYrec_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYsum_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_any_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_emp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_var_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_emp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_var_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_unboxed) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_void) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyarr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecbox) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecext) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecsin) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec_make) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__tmpdef_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__hityplstlst_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__hityplst_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__hityp_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_any_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_emp_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_var_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_emp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_var_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_ptr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_bool_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type istyarr_11 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_15 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_bool_type hiexplst_is_value_16 (ats_ptr_type arg0) ; static ats_bool_type labhiexplst_is_value_17 (ats_ptr_type arg0) ; static ats_ptr_type hiclau_is_bool_fst_19 (ats_ptr_type arg0) ; static ats_ptr_type hiclau_is_bool_snd_20 (ats_ptr_type arg0) ; static ats_ptr_type aux_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type hidec_valdecs_is_singular_22 (ats_ptr_type arg0) ; static ats_ptr_type hiexp_is_empvar_24 (ats_ptr_type arg0) ; static ats_void_type aux_init_main_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux_init_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_last_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_simplify_26 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_simplify_26_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) ; static ats_ptr_type aux_simplify_26_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type hityp_name_get_49 (ats_ptr_type arg0) ; static ats_ptr_type aux_51 (ats_ptr_type arg0) ; static ats_ptr_type hityp_normalize_flag_53 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type hityplst_normalize_flag_54 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type labhityplst_normalize_flag_55 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type _tmpdef_make_60 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type tmpcstmap_nil_64 () ; static ats_ptr_type ref_make_elt_03597_ats_ptr_type (ats_ptr_type arg0) ; static ats_int_type bst_size_040_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_079_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01723_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_068_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01725_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type tmpvarmap_nil_74 () ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp288) ; ATSstatic (ats_ptr_type, statmp291) ; ATSstatic (ats_ptr_type, statmp371) ; ATSstatic (ats_ptr_type, statmp372) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 2312(line=80, offs=4) -- 2371(line=80, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_hiexp_util)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 2418(line=85, offs=15) -- 2821(line=97, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_bool_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void: tmp2 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp2)->tag != 1) { goto __ats_lab_5_0 ; } __ats_lab_0_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_1, tmp2, atslab_0) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp4 = atspre_eq_string_string (tmp3, ATSstrcst("ats_abs_type")) ; if (!tmp4) { goto __ats_lab_2_1 ; } tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp5 = atspre_eq_string_string (tmp3, ATSstrcst("ats_var_type")) ; if (!tmp5) { goto __ats_lab_3_1 ; } tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp6 = atspre_eq_string_string (tmp3, ATSstrcst("ats_void_type")) ; if (!tmp6) { goto __ats_lab_4_1 ; } tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: tmp1 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp2)->tag != 4) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_2, tmp2, atslab_0) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_unboxed (tmp7) ; if (!tmp8) { goto __ats_lab_7_1 ; } tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp2)->tag != 8) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_2, tmp2, atslab_0) ; arg0 = tmp9 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp1 = ats_false_bool ; break ; } while (0) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 2877(line=100, offs=19) -- 3291(line=114, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_void: tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp11)->tag != 2) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_3, tmp11, atslab_2) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (tmp12) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: /* tmp13 = */ prerr_interror_0 () ; /* tmp14 = */ atspre_prerr_string (ATSstrcst(": hityp_fun_is_void: hit_fun = ")) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (arg0) ; /* tmp16 = */ atspre_prerr_newline () ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 3349(line=117, offs=17) -- 3425(line=119, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg: tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp18)->tag != 12) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp17 = ats_true_bool ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp17 = ats_false_bool ; break ; } while (0) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 3507(line=123, offs=7) -- 3635(line=124, offs=74) */ ATSstaticdec() ats_bool_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_aux_5: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; arg0 = tmp21 ; arg1 = tmp22 ; goto __ats_lab_aux_5 ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp20 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_vararg (arg0) ; break ; } while (0) ; return (tmp20) ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 3485(line=122, offs=21) -- 4082(line=140, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_vararg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp19) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_vararg: tmp23 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp23)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_14_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_3, tmp23, atslab_1) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (tmp24 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp25 = ats_caselptrlab_mac(anairiats_sum_4, tmp24, atslab_0) ; tmp26 = ats_caselptrlab_mac(anairiats_sum_4, tmp24, atslab_1) ; tmp19 = aux_5 (tmp25, tmp26) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (tmp24 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp19 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: /* tmp27 = */ prerr_interror_0 () ; /* tmp28 = */ atspre_prerr_string (ATSstrcst(": hityp_fun_is_vararg: hit_fun = ")) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (arg0) ; /* tmp30 = */ atspre_print_newline () ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_vararg] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4162(line=145, offs=16) -- 4245(line=147, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyarr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyarr: tmp32 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp32)->tag != 5) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp31 = ats_true_bool ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp31 = ats_false_bool ; break ; } while (0) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4302(line=150, offs=19) -- 4395(line=152, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecbox (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecbox: tmp34 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp34)->tag != 6) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_5, tmp34, atslab_0) ; tmp33 = atspre_gt_int_int (tmp35, 0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp33 = ats_false_bool ; break ; } while (0) ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecbox] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4455(line=155, offs=19) -- 4548(line=157, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecext (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecext: tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp37)->tag != 6) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_5, tmp37, atslab_0) ; tmp36 = atspre_lt_int_int (tmp38, 0) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: tmp36 = ats_false_bool ; break ; } while (0) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecext] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4608(line=160, offs=19) -- 4694(line=162, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecsin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecsin: tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp40)->tag != 8) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp39 = ats_true_bool ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp39 = ats_false_bool ; break ; } while (0) ; return (tmp39) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecsin] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4801(line=169, offs=7) -- 5073(line=177, offs=33) */ ATSstaticdec() ats_bool_type istyarr_11 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_bool_type, tmp46) ; __ats_lab_istyarr_11: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp44 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp45 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp46 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (arg1, tmp43) ; if (tmp46) { tmp42 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyarr (tmp44) ; } else { arg0 = tmp45 ; arg1 = arg1 ; goto __ats_lab_istyarr_11 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp42 = ats_false_bool ; break ; } while (0) ; return (tmp42) ; } /* end of [istyarr_11] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 4774(line=168, offs=3) -- 5202(line=183, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__label_is_tyarr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp41) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__label_is_tyarr: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp47)->tag != 6) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_5, tmp47, atslab_1) ; tmp41 = istyarr_11 (tmp48, arg1) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp41 = ats_false_bool ; break ; } while (0) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__label_is_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 5285(line=189, offs=3) -- 5490(line=195, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_30_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp51 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp50), atslab_hipat_node) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp52)->tag != 1) { goto __ats_lab_32_0 ; } __ats_lab_31_1: arg0 = tmp51 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp49 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp49 = ats_true_bool ; break ; } while (0) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 5610(line=202, offs=16) -- 5891(line=212, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_int_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_bool_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty: tmp54 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_hiexp_node) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp54)->tag != 13) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp53 = ats_true_bool ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp54)->tag != 34) { goto __ats_lab_38_0 ; } __ats_lab_35_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_0) ; tmp56 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_2) ; tmp57 = atspre_eq_int_int (tmp55, 0) ; if (!tmp57) { goto __ats_lab_38_1 ; } do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp56 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } tmp58 = ats_caselptrlab_mac(anairiats_sum_6, tmp56, atslab_2) ; if (tmp58 != (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_6, tmp56, atslab_1) ; arg0 = tmp59 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty ; // tail call break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: tmp53 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp53 = ats_false_bool ; break ; } while (0) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 6016(line=219, offs=7) -- 6339(line=231, offs=6) */ ATSstaticdec() ats_void_type aux_15 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_bool_type, tmp65) ; ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_aux_15: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp63 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_empty (tmp62) ; tmp65 = atspre_neg_bool (tmp66) ; if (tmp65) { tmp67 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp67, atslab_0, tmp62) ; ats_selptrset_mac(anairiats_sum_4, tmp67, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp67 ; } else { /* empty */ } /* end of [if] */ arg0 = arg0 ; arg1 = tmp63 ; goto __ats_lab_aux_15 ; // tail call break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: break ; } while (0) ; return /* (tmp61) */ ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 5949(line=216, offs=20) -- 6716(line=243, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq_simplify (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq_simplify: /* ats_ptr_type tmp68 ; */ tmp68 = (ats_sum_ptr_type)0 ; /* tmp69 = */ aux_15 ((&tmp68), arg2) ; tmp70 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp68) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (tmp70 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_41_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_4, tmp70, atslab_0) ; tmp72 = ats_caselptrlab_mac(anairiats_sum_4, tmp70, atslab_1) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp72 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp60 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq (arg0, arg1, tmp70) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (tmp72 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: tmp60 = tmp71 ; break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (tmp70 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp60 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (arg0, arg1) ; break ; } while (0) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq_simplify] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 6774(line=247, offs=5) -- 6988(line=254, offs=4) */ ATSstaticdec() ats_bool_type hiexplst_is_value_16 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_bool_type, tmp76) ; __ats_lab_hiexplst_is_value_16: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp75 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp76 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value (tmp74) ; if (tmp76) { arg0 = tmp75 ; goto __ats_lab_hiexplst_is_value_16 ; // tail call } else { tmp73 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: tmp73 = ats_true_bool ; break ; } while (0) ; return (tmp73) ; } /* end of [hiexplst_is_value_16] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 7024(line=256, offs=5) -- 7287(line=263, offs=4) */ ATSstaticdec() ats_bool_type labhiexplst_is_value_17 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_bool_type, tmp80) ; __ats_lab_labhiexplst_is_value_17: do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp80 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value (tmp78) ; if (tmp80) { arg0 = tmp79 ; goto __ats_lab_labhiexplst_is_value_17 ; // tail call } else { tmp77 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp77 = ats_true_bool ; break ; } while (0) ; return (tmp77) ; } /* end of [labhiexplst_is_value_17] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 7349(line=267, offs=3) -- 7990(line=287, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_bool_type, tmp89) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value: tmp82 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_hiexp_node) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp82)->tag != 5) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp82)->tag != 8) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp82)->tag != 9) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_3, tmp82, atslab_2) ; tmp81 = hiexplst_is_value_16 (tmp83) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp82)->tag != 10) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp82)->tag != 13) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp82)->tag != 15) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_9, tmp82, atslab_2) ; arg0 = tmp84 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp82)->tag != 16) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp82)->tag != 22) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp82)->tag != 23) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp82)->tag != 30) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_9, tmp82, atslab_2) ; tmp81 = hiexplst_is_value_16 (tmp85) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp82)->tag != 20) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp82)->tag != 34) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_9, tmp82, atslab_2) ; tmp81 = labhiexplst_is_value_17 (tmp86) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp82)->tag != 39) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_2, tmp82, atslab_0) ; tmp81 = hiexplst_is_value_16 (tmp87) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp82)->tag != 42) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp82)->tag != 43) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp82)->tag != 44) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp81 = ats_true_bool ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp82)->tag != 47) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_2, tmp82, atslab_0) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix (tmp88) ; if (tmp89) { tmp81 = ats_false_bool ; } else { tmp81 = ats_true_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp81 = ats_false_bool ; break ; } while (0) ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 8043(line=292, offs=4) -- 8445(line=302, offs=4) */ ATSstaticdec() ats_ptr_type hiclau_is_bool_fst_19 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_bool_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (anairiats_rec_12, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_hiclau_is_bool_fst_19: tmp91 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_pat) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (tmp91 == (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } tmp92 = ats_caselptrlab_mac(anairiats_sum_4, tmp91, atslab_1) ; if (tmp92 != (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } __ats_lab_67_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_4, tmp91, atslab_0) ; tmp94 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp93), atslab_hipat_node) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp94)->tag != 3) { goto __ats_lab_71_0 ; } __ats_lab_68_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_11, tmp94, atslab_0) ; tmp96 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_gua) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp90 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: // if (tmp96 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_70_1: tmp98 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_exp) ; tmp97.atslab_0 = tmp95 ; tmp97.atslab_1 = tmp98 ; tmp90 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp90, atslab_0, tmp97) ; break ; } while (0) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp90 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: tmp90 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp90) ; } /* end of [hiclau_is_bool_fst_19] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 8481(line=304, offs=4) -- 8741(line=311, offs=4) */ ATSstaticdec() ats_ptr_type hiclau_is_bool_snd_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_hiclau_is_bool_snd_20: tmp100 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_pat) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_76_0 ; } tmp101 = ats_caselptrlab_mac(anairiats_sum_4, tmp100, atslab_1) ; if (tmp101 != (ats_sum_ptr_type)0) { goto __ats_lab_76_0 ; } __ats_lab_73_1: tmp102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_gua) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (tmp102 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp99 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (tmp102 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_hiclau_exp) ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_0, tmp103) ; break ; } while (0) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: __ats_lab_76_1: tmp99 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp99) ; } /* end of [hiclau_is_bool_snd_20] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 8802(line=315, offs=3) -- 9631(line=339, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof_if (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (anairiats_rec_12, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_bool_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof_if: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } tmp105 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_1) ; if (tmp105 != (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_77_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_0) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } tmp107 = ats_caselptrlab_mac(anairiats_sum_4, arg4, atslab_1) ; if (tmp107 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } tmp108 = ats_caselptrlab_mac(anairiats_sum_4, tmp107, atslab_1) ; if (tmp108 != (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_78_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_4, arg4, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_4, tmp107, atslab_0) ; tmp111 = hiclau_is_bool_fst_19 (tmp109) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp111 == (ats_sum_ptr_type)0) { goto __ats_lab_82_0 ; } __ats_lab_79_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_13, tmp111, atslab_0) ; ATS_FREE(tmp111) ; tmp113 = hiclau_is_bool_snd_20 (tmp110) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (tmp113 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp114 = ats_caselptrlab_mac(anairiats_sum_14, tmp113, atslab_0) ; ATS_FREE(tmp113) ; tmp115 = ats_select_mac(tmp112, atslab_0) ; if (tmp115) { tmp116 = ats_select_mac(tmp112, atslab_1) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if (arg0, arg1, tmp106, tmp116, tmp114) ; } else { tmp117 = ats_select_mac(tmp112, atslab_1) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if (arg0, arg1, tmp106, tmp114, tmp117) ; } /* end of [if] */ break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: // if (tmp113 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_81_1: tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof (arg0, arg1, arg2, arg3, arg4) ; break ; } while (0) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (tmp111 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof (arg0, arg1, arg2, arg3, arg4) ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof (arg0, arg1, arg2, arg3, arg4) ; break ; } while (0) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof (arg0, arg1, arg2, arg3, arg4) ; break ; } while (0) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof_if] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 9962(line=355, offs=7) -- 10571(line=373, offs=6) */ ATSstaticdec() ats_ptr_type aux_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_bool_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; __ats_lab_aux_23: tmp120 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp120)->tag != 1) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp119 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp119)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp119, atslab_0, arg0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp120)->tag != 7) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp119 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp119)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp119, atslab_0, arg0) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp120)->tag != 13) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_5, tmp120, atslab_1) ; tmp119 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp119)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp119, atslab_0, tmp121) ; ats_selptrset_mac(anairiats_sum_1, tmp119, atslab_1, arg0) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp120)->tag != 11) { goto __ats_lab_91_0 ; } __ats_lab_88_1: tmp122 = ats_caselptrlab_mac(anairiats_sum_9, tmp120, atslab_0) ; tmp123 = ats_caselptrlab_mac(anairiats_sum_9, tmp120, atslab_1) ; tmp124 = atspre_eq_int_int (tmp122, 0) ; if (!tmp124) { goto __ats_lab_91_1 ; } do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp123)->tag != 0) { goto __ats_lab_90_0 ; } tmp125 = ats_caselptrlab_mac(anairiats_sum_3, tmp123, atslab_2) ; if (((ats_sum_ptr_type)tmp125)->tag != 2) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_3, tmp123, atslab_1) ; arg0 = arg0 ; arg1 = tmp126 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: __ats_lab_90_1: tmp119 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; break ; } while (0) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp119 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; break ; } while (0) ; return (tmp119) ; } /* end of [aux_23] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 9812(line=349, offs=4) -- 10808(line=381, offs=4) */ ATSstaticdec() ats_ptr_type hidec_valdecs_is_singular_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_hidec_valdecs_is_singular_22: tmp127 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_hidec_node) ; do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp127)->tag != 9) { goto __ats_lab_95_0 ; } __ats_lab_92_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_1, tmp127, atslab_1) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (tmp128 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } tmp129 = ats_caselptrlab_mac(anairiats_sum_4, tmp128, atslab_1) ; if (tmp129 != (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp130 = ats_caselptrlab_mac(anairiats_sum_4, tmp128, atslab_0) ; tmp131 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, tmp130), atslab_hivaldec_def) ; tmp132 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, tmp130), atslab_hivaldec_pat) ; tmp118 = aux_23 (tmp131, tmp132) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: __ats_lab_94_1: tmp118 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; break ; } while (0) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp118 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0) ; break ; } while (0) ; return (tmp118) ; } /* end of [hidec_valdecs_is_singular_22] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 10981(line=389, offs=5) -- 11361(line=399, offs=25) */ ATSstaticdec() ats_ptr_type hiexp_is_empvar_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_int_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_bool_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; __ats_lab_hiexp_is_empvar_24: tmp134 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_hiexp_node) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp134)->tag != 13) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp133 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_emp_1) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp134)->tag != 47) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp135 = ats_caselptrlab_mac(anairiats_sum_2, tmp134, atslab_0) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp133)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_0, tmp135) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp134)->tag != 34) { goto __ats_lab_101_0 ; } __ats_lab_98_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_9, tmp134, atslab_0) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_9, tmp134, atslab_2) ; tmp138 = atspre_eq_int_int (tmp136, 0) ; if (!tmp138) { goto __ats_lab_101_1 ; } do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (tmp137 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } tmp139 = ats_caselptrlab_mac(anairiats_sum_6, tmp137, atslab_2) ; if (tmp139 != (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp140 = ats_caselptrlab_mac(anairiats_sum_6, tmp137, atslab_1) ; arg0 = tmp140 ; goto __ats_lab_hiexp_is_empvar_24 ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: tmp133 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARnone_0) ; break ; } while (0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: __ats_lab_101_1: tmp133 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARnone_0) ; break ; } while (0) ; return (tmp133) ; } /* end of [hiexp_is_empvar_24] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 11617(line=410, offs=9) -- 11979(line=420, offs=8) */ ATSstaticdec() ats_void_type aux_init_main_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_aux_init_main_27: do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp146 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp146, atslab_0, arg0) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp146 ; // if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp147 = &ats_caselptrlab_mac(anairiats_sum_4, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; arg0 = tmp144 ; arg1 = tmp145 ; arg2 = tmp147 ; goto __ats_lab_aux_init_main_27 ; // tail call break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: tmp148 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp148 ; break ; } while (0) ; return /* (tmp143) */ ; } /* end of [aux_init_main_27] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 12017(line=422, offs=9) -- 12186(line=427, offs=6) */ ATSstaticdec() ats_ptr_type aux_init_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; // ATSlocal_void (tmp151) ; __ats_lab_aux_init_28: /* ats_ptr_type tmp150 ; */ /* tmp151 = */ aux_init_main_27 (arg0, arg1, (&tmp150)) ; tmp149 = tmp150 ; return (tmp149) ; } /* end of [aux_init_28] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 12219(line=429, offs=9) -- 12366(line=432, offs=8) */ ATSstaticdec() ats_ptr_type aux_last_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_aux_last_29: do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp153 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; arg0 = tmp153 ; arg1 = tmp154 ; goto __ats_lab_aux_last_29 ; // tail call break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: tmp152 = arg0 ; break ; } while (0) ; return (tmp152) ; } /* end of [aux_last_29] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 11519(line=406, offs=7) -- 13948(line=478, offs=6) */ ATSstaticdec() ats_ptr_type aux_simplify_26 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_bool_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_bool_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_aux_simplify_26: tmp155 = hiexp_is_empvar_24 (arg2) ; do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)tmp155)->tag != 1) { goto __ats_lab_115_0 ; } __ats_lab_106_1: tmp156 = aux_last_29 (arg0, arg1) ; tmp157 = hidec_valdecs_is_singular_22 (tmp156) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)tmp157)->tag != 1) { goto __ats_lab_110_0 ; } __ats_lab_107_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_2, tmp157, atslab_0) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: __ats_lab_108_1: tmp160 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp158), atslab_hiexp_typ) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (tmp160) ; if (!tmp159) { goto __ats_lab_109_1 ; } tmp161 = aux_init_28 (arg0, arg1) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, tmp161, tmp158) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, env2, env3) ; break ; } while (0) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp157)->tag != 2) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp162 = ats_caselptrlab_mac(anairiats_sum_2, tmp157, atslab_0) ; tmp163 = aux_init_28 (arg0, arg1) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, tmp163, tmp162) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp157)->tag != 3) { goto __ats_lab_114_0 ; } __ats_lab_111_1: tmp164 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_1) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp166 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp164), atslab_hiexp_typ) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (tmp166) ; if (!tmp165) { goto __ats_lab_113_1 ; } tmp167 = aux_init_28 (arg0, arg1) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, tmp167, tmp164) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, env2, env3) ; break ; } while (0) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, env2, env3) ; break ; } while (0) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp155)->tag != 2) { goto __ats_lab_118_0 ; } __ats_lab_115_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp169 = aux_last_29 (arg0, arg1) ; tmp170 = hidec_valdecs_is_singular_22 (tmp169) ; do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp170)->tag != 3) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_1, tmp170, atslab_0) ; tmp172 = ats_caselptrlab_mac(anairiats_sum_1, tmp170, atslab_1) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var (tmp171, tmp168) ; if (!tmp173) { goto __ats_lab_117_1 ; } tmp174 = aux_init_28 (arg0, arg1) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, tmp174, tmp172) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: __ats_lab_117_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, env2, env3) ; break ; } while (0) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (((ats_sum_ptr_type)tmp155)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let (env0, env1, env2, env3) ; break ; } while (0) ; return (tmp142) ; } /* end of [aux_simplify_26] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; } aux_simplify_26_closure_type ; ats_ptr_type aux_simplify_26_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return aux_simplify_26 (((aux_simplify_26_closure_type*)cloptr)->closure_env_0, ((aux_simplify_26_closure_type*)cloptr)->closure_env_1, ((aux_simplify_26_closure_type*)cloptr)->closure_env_2, ((aux_simplify_26_closure_type*)cloptr)->closure_env_3, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux_simplify_26_closure_init (aux_simplify_26_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_simplify_26_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; return ; } /* end of function */ ats_clo_ptr_type aux_simplify_26_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3) { aux_simplify_26_closure_type *p_clo = ATS_MALLOC(sizeof(aux_simplify_26_closure_type)) ; aux_simplify_26_closure_init (p_clo, env0, env1, env2, env3) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 11422(line=404, offs=3) -- 14073(line=483, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp141 = aux_simplify_26 (arg0, arg1, arg2, arg3, tmp175, tmp176, arg3) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_120_1: tmp141 = arg3 ; break ; } while (0) ; return (tmp141) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14266(line=495, offs=24) -- 14277(line=495, offs=35) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode: tmp177 = arg0 ; return (tmp177) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14301(line=496, offs=24) -- 14312(line=496, offs=35) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode: tmp178 = arg0 ; return (tmp178) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14340(line=498, offs=27) -- 14353(line=498, offs=40) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode: tmp179 = arg0 ; return (tmp179) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14380(line=499, offs=27) -- 14393(line=499, offs=40) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp180) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode: tmp180 = arg0 ; return (tmp180) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14424(line=501, offs=30) -- 14439(line=501, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_encode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_encode: tmp181 = arg0 ; return (tmp181) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_encode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14469(line=502, offs=30) -- 14484(line=502, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp182) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode: tmp182 = arg0 ; return (tmp182) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_decode] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14531(line=506, offs=25) -- 14555(line=506, offs=49) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp_t (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp183) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp_t: /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp (arg0) ; return /* (tmp183) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_hityp_t] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14581(line=507, offs=25) -- 14605(line=507, offs=49) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp_t (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp184) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp_t: /* tmp184 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (arg0) ; return /* (tmp184) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp_t] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14655(line=512, offs=17) -- 14732(line=514, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_nil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp185) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_nil: do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp185 = ats_false_bool ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_122_1: tmp185 = ats_true_bool ; break ; } while (0) ; return (tmp185) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14789(line=517, offs=18) -- 14866(line=519, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp186) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons: do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp186 = ats_true_bool ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_124_1: tmp186 = ats_false_bool ; break ; } while (0) ; return (tmp186) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_is_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 14926(line=522, offs=20) -- 15005(line=524, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_nil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_nil: do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp187 = ats_false_bool ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: tmp187 = ats_true_bool ; break ; } while (0) ; return (tmp187) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15068(line=527, offs=21) -- 15147(line=529, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_cons (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_cons: do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp188 = ats_true_bool ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_128_1: tmp188 = ats_false_bool ; break ; } while (0) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_is_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15398(line=539, offs=25) -- 15422(line=539, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_s2var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_s2var: tmp189 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var (arg0) ; return (tmp189) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15451(line=540, offs=28) -- 15473(line=540, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name: tmp190 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_name) ; return (tmp190) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15503(line=542, offs=27) -- 15529(line=542, offs=53) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp191) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void: tmp191 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (arg0) ; return (tmp191) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15561(line=543, offs=31) -- 15599(line=543, offs=69) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void: tmp192 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_void (arg0) ; return (tmp192) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_fun_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15632(line=544, offs=31) -- 15670(line=544, offs=69) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp193) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox: tmp193 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecbox (arg0) ; return (tmp193) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecbox] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15702(line=545, offs=31) -- 15740(line=545, offs=69) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext: tmp194 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecext (arg0) ; return (tmp194) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecext] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15772(line=546, offs=31) -- 15810(line=546, offs=69) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp195) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin: tmp195 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_tyrecsin (arg0) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_tyrecsin] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 15837(line=550, offs=4) -- 16101(line=559, offs=4) */ ATSstaticdec() ats_ptr_type hityp_name_get_49 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_bool_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_hityp_name_get_49: tmp197 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_name) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_17, tmp197, atslab_0) ; tmp199 = ats_caselptrlab_mac(anairiats_sum_17, tmp197, atslab_1) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: __ats_lab_129_1: tmp200 = atspre_lte_int_int (tmp198, 0) ; if (!tmp200) { goto __ats_lab_130_1 ; } tmp196 = tmp199 ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: __ats_lab_130_1: tmp201 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr), atslab_hityp_name) ; tmp202 = ats_caselptrlab_mac(anairiats_sum_17, tmp201, atslab_1) ; tmp196 = tmp202 ; break ; } while (0) ; return (tmp196) ; } /* end of [hityp_name_get_49] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 16222(line=565, offs=9) -- 16467(line=569, offs=45) */ ATSstaticdec() ats_ptr_type aux_51 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_aux_51: do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp207 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp208 = hityp_name_get_49 (tmp206) ; tmp209 = aux_51 (tmp207) ; tmp204 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp204, atslab_0, tmp205) ; ats_selptrset_mac(anairiats_sum_6, tmp204, atslab_1, tmp208) ; ats_selptrset_mac(anairiats_sum_6, tmp204, atslab_2, tmp209) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_132_1: tmp204 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp204) ; } /* end of [aux_51] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 16159(line=563, offs=3) -- 16682(line=576, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec_make (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_int_type, tmp213) ; ATSlocal (ats_bool_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec_make: tmp210 = aux_51 (arg1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp212)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp212, atslab_0, tmp210) ; tmp211 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find (tmp212) ; tmp214 = atspre_gt_int_int (arg0, 0) ; if (tmp214) { tmp213 = 1 ; } else { tmp213 = 0 ; } /* end of [if] */ tmp215 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec (tmp213, tmp211, arg1) ; tmp203 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp215) ; return (tmp203) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 16742(line=580, offs=3) -- 17605(line=605, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_int_type, tmp219) ; ATSlocal (ats_bool_type, tmp220) ; ATSlocal (ats_bool_type, tmp221) ; ATSlocal (ats_bool_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make: do { /* branch: __ats_lab_133 */ __ats_lab_133_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_133_1: tmp217 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg1, &hityp_name_get_49) ; tmp218 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (arg0) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: __ats_lab_134_1: tmp220 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_singular (tmp218) ; if (!tmp220) { goto __ats_lab_135_1 ; } tmp219 = 0 ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_listlike (tmp218) ; if (!tmp221) { goto __ats_lab_136_1 ; } tmp219 = 0 ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: __ats_lab_136_1: tmp222 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (arg0) ; if (!tmp222) { goto __ats_lab_137_1 ; } tmp219 = -1 ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: __ats_lab_137_1: tmp219 = 1 ; break ; } while (0) ; tmp224 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp224)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp224, atslab_0, tmp219) ; ats_selptrset_mac(anairiats_sum_5, tmp224, atslab_1, tmp217) ; tmp223 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find (tmp224) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum (tmp223, arg0, arg1) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp225) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_1: tmp216 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_ptr) ; break ; } while (0) ; return (tmp216) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 17661(line=609, offs=5) -- 19448(line=662, offs=4) */ ATSstaticdec() ats_ptr_type hityp_normalize_flag_53 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_int_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_bool_type, tmp234) ; ATSlocal (ats_int_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_int_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_bool_type, tmp246) ; ATSlocal (ats_int_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_bool_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_bool_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_int_type, tmp256) ; __ats_lab_hityp_normalize_flag_53: tmp227 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_hityp_node) ; do { /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp227)->tag != 2) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_3, tmp227, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_3, tmp227, atslab_1) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_3, tmp227, atslab_2) ; tmp231 = ats_ptrget_mac(ats_int_type, arg1) ; tmp232 = hityplst_normalize_flag_54 (tmp229, arg1) ; tmp233 = hityp_normalize_flag_53 (tmp230, arg1) ; tmp234 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp231) ; if (tmp234) { tmp226 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp228, tmp232, tmp233) ; } else { tmp226 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp227)->tag != 7) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp235 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_0) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_1) ; tmp237 = labhityplst_normalize_flag_55 (tmp236, arg1) ; tmp238 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp238 ; tmp226 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec_make (tmp235, tmp237) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)tmp227)->tag != 10) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp240 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; tmp241 = hityplst_normalize_flag_54 (tmp240, arg1) ; tmp242 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp242 ; tmp226 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysum_make (tmp239, tmp241) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp227)->tag != 8) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp243 = ats_caselptrlab_mac(anairiats_sum_2, tmp227, atslab_0) ; tmp244 = ats_ptrget_mac(ats_int_type, arg1) ; tmp245 = hityp_normalize_flag_53 (tmp243, arg1) ; tmp246 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp244) ; if (tmp246) { tmp226 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin (tmp245) ; } else { tmp226 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp227)->tag != 3) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_0) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_1) ; tmp249 = atspre_eq_int_int (tmp247, 0) ; if (tmp249) { tmp250 = ats_ptrget_mac(ats_int_type, arg1) ; tmp251 = hityp_normalize_flag_53 (tmp248, arg1) ; tmp252 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp250) ; if (tmp252) { tmp226 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg (0, tmp251) ; } else { tmp226 = arg0 ; } /* end of [if] */ } else { tmp226 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp227)->tag != 4) { goto __ats_lab_147_0 ; } __ats_lab_144_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_2, tmp227, atslab_0) ; tmp254 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var_normalize (tmp253) ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (tmp254 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_14, tmp254, atslab_0) ; ATS_FREE(tmp254) ; tmp256 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp256 ; tmp226 = tmp255 ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: // if (tmp254 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_146_1: tmp226 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: __ats_lab_147_1: tmp226 = arg0 ; break ; } while (0) ; return (tmp226) ; } /* end of [hityp_normalize_flag_53] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 19487(line=664, offs=5) -- 19847(line=675, offs=4) */ ATSstaticdec() ats_ptr_type hityplst_normalize_flag_54 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_int_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_bool_type, tmp263) ; __ats_lab_hityplst_normalize_flag_54: do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp259 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp260 = ats_ptrget_mac(ats_int_type, arg1) ; tmp261 = hityp_normalize_flag_53 (tmp258, arg1) ; tmp262 = hityplst_normalize_flag_54 (tmp259, arg1) ; tmp263 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp260) ; if (tmp263) { tmp257 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp257, atslab_0, tmp261) ; ats_selptrset_mac(anairiats_sum_4, tmp257, atslab_1, tmp262) ; } else { tmp257 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_149_1: tmp257 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp257) ; } /* end of [hityplst_normalize_flag_54] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 19891(line=677, offs=5) -- 20328(line=688, offs=4) */ ATSstaticdec() ats_ptr_type labhityplst_normalize_flag_55 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_bool_type, tmp271) ; __ats_lab_labhityplst_normalize_flag_55: do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp267 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp268 = ats_ptrget_mac(ats_int_type, arg1) ; tmp269 = hityp_normalize_flag_53 (tmp266, arg1) ; tmp270 = labhityplst_normalize_flag_55 (tmp267, arg1) ; tmp271 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp268) ; if (tmp271) { tmp264 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp264, atslab_0, tmp265) ; ats_selptrset_mac(anairiats_sum_6, tmp264, atslab_1, tmp269) ; ats_selptrset_mac(anairiats_sum_6, tmp264, atslab_2, tmp270) ; } else { tmp264 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_151_1: tmp264 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp264) ; } /* end of [labhityplst_normalize_flag_55] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 20416(line=693, offs=17) -- 20487(line=695, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_int_type, tmp273) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize: /* ats_int_type tmp273 ; */ tmp273 = 0 ; tmp272 = hityp_normalize_flag_53 (arg0, (&tmp273)) ; return (tmp272) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 20546(line=698, offs=20) -- 20598(line=699, offs=44) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp274) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_normalize: tmp274 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize) ; return (tmp274) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 20663(line=703, offs=23) -- 20720(line=704, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp275) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize: tmp275 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_normalize) ; return (tmp275) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 20833(line=713, offs=3) -- 21159(line=726, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some: tmp277 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp (arg0) ; do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (tmp277 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_14, tmp277, atslab_0) ; tmp276 = tmp278 ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (tmp277 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: /* tmp279 = */ prerr_interror_0 () ; /* tmp280 = */ atspre_prerr_string (ATSstrcst(": d2cst_hityp_get_some: d2c = ")) ; /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (arg0) ; /* tmp282 = */ atspre_prerr_newline () ; /* tmp276 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp276) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__d2cst_get_hityp_some] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21335(line=738, offs=4) -- 21428(line=742, offs=2) */ ATSstaticdec() ats_ptr_type _tmpdef_make_60 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp283) ; __ats_lab__tmpdef_make_60: tmp283 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp283, atslab_tmpdef_arg, arg0) ; ats_selptrset_mac(anairiats_rec_18, tmp283, atslab_tmpdef_exp, arg1) ; return (tmp283) ; } /* end of [_tmpdef_make_60] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21499(line=747, offs=3) -- 21535(line=747, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make: tmp284 = _tmpdef_make_60 (arg0, arg1) ; return (tmp284) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21586(line=750, offs=26) -- 21608(line=750, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_arg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_arg: tmp285 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_tmpdef_arg) ; return (tmp285) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21634(line=751, offs=26) -- 21656(line=751, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp286) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_exp: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_tmpdef_exp) ; return (tmp286) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_get_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21769(line=762, offs=4) -- 21837(line=763, offs=52) */ ATSstaticdec() ats_ptr_type tmpcstmap_nil_64 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_tmpcstmap_nil_64: tmp287 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) ; return (tmp287) ; } /* end of [tmpcstmap_nil_64] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03597_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; __ats_lab_ref_make_elt_03597_ats_ptr_type: /* ats_ptr_type tmp290 ; */ tmp290 = arg0 ; tmp289 = atspre_ref_make_elt_tsz ((&tmp290), sizeof(ats_ptr_type)) ; return (tmp289) ; } /* end of [ref_make_elt_03597_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_040_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp321) ; ATSlocal (ats_int_type, tmp322) ; __ats_lab_bst_size_040_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_0) ; tmp321 = tmp322 ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_157_1: tmp321 = 0 ; break ; } while (0) ; return (tmp321) ; } /* end of [bst_size_040_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_bool_type, tmp312) ; ATSlocal (ats_int_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_int_type, tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_int_type, tmp325) ; ATSlocal (ats_int_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_int_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_int_type, tmp336) ; ATSlocal (ats_int_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; __ats_lab_bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_158_0 ; } __ats_lab_155_1: tmp308 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_0) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_1) ; tmp310 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_3) ; tmp311 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_4) ; tmp313 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp309) ; tmp312 = atspre_ilte (tmp313, 0) ; if (tmp312) { tmp315 = ats_ptrget_mac(ats_ptr_type, tmp310) ; tmp314 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (tmp315, arg1, arg2, arg3) ; // if (tmp314 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp316 = &ats_caselptrlab_mac(anairiats_sum_19, tmp314, atslab_0) ; tmp317 = &ats_caselptrlab_mac(anairiats_sum_19, tmp314, atslab_3) ; tmp318 = &ats_caselptrlab_mac(anairiats_sum_19, tmp314, atslab_4) ; tmp319 = ats_ptrget_mac(ats_int_type, tmp308) ; tmp323 = ats_ptrget_mac(ats_ptr_type, tmp317) ; tmp320 = bst_size_040_ats_ptr_type_2cats_ptr_type (tmp323) ; tmp324 = ats_ptrget_mac(ats_ptr_type, tmp318) ; ats_ptrget_mac(ats_ptr_type, tmp310) = tmp324 ; tmp325 = atspre_isub (tmp319, tmp320) ; ats_ptrget_mac(ats_int_type, tmp308) = tmp325 ; ats_ptrget_mac(ats_ptr_type, tmp318) = arg0 ; tmp326 = atspre_iadd (tmp319, 1) ; ats_ptrget_mac(ats_int_type, tmp316) = tmp326 ; tmp307 = tmp314 ; } else { tmp328 = ats_ptrget_mac(ats_ptr_type, tmp311) ; tmp327 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (tmp328, arg1, arg2, arg3) ; // if (tmp327 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp329 = &ats_caselptrlab_mac(anairiats_sum_19, tmp327, atslab_0) ; tmp330 = &ats_caselptrlab_mac(anairiats_sum_19, tmp327, atslab_3) ; tmp331 = &ats_caselptrlab_mac(anairiats_sum_19, tmp327, atslab_4) ; tmp332 = ats_ptrget_mac(ats_int_type, tmp308) ; tmp334 = ats_ptrget_mac(ats_ptr_type, tmp331) ; tmp333 = bst_size_040_ats_ptr_type_2cats_ptr_type (tmp334) ; tmp335 = ats_ptrget_mac(ats_ptr_type, tmp330) ; ats_ptrget_mac(ats_ptr_type, tmp311) = tmp335 ; tmp336 = atspre_isub (tmp332, tmp333) ; ats_ptrget_mac(ats_int_type, tmp308) = tmp336 ; ats_ptrget_mac(ats_ptr_type, tmp330) = arg0 ; tmp337 = atspre_iadd (tmp332, 1) ; ats_ptrget_mac(ats_int_type, tmp329) = tmp337 ; tmp307 = tmp327 ; } /* end of [if] */ break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_158_1: tmp338 = (ats_sum_ptr_type)0 ; tmp339 = (ats_sum_ptr_type)0 ; tmp307 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ats_selptrset_mac(anairiats_sum_19, tmp307, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_19, tmp307, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_19, tmp307, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_19, tmp307, atslab_3, tmp338) ; ats_selptrset_mac(anairiats_sum_19, tmp307, atslab_4, tmp339) ; break ; } while (0) ; return (tmp307) ; } /* end of [bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_079_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_bool_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_bool_type, tmp340) ; ATSlocal (ats_int_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_int_type, tmp344) ; ATSlocal (ats_int_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_int_type, tmp348) ; ATSlocal (ats_int_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; __ats_lab_bst_insert_random_079_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_154_1: tmp301 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_0) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_1) ; tmp303 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_3) ; tmp304 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_4) ; tmp306 = ats_ptrget_mac(ats_int_type, tmp301) ; tmp305 = atsopt_map_lin_dice (1, tmp306) ; if (tmp305) { tmp300 = bst_insert_atroot_045_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp341 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp302) ; tmp340 = atspre_ilte (tmp341, 0) ; if (tmp340) { tmp343 = ats_ptrget_mac(ats_ptr_type, tmp303) ; tmp342 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp343, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp303) = tmp342 ; tmp345 = ats_ptrget_mac(ats_int_type, tmp301) ; tmp344 = atspre_iadd (tmp345, 1) ; ats_ptrget_mac(ats_int_type, tmp301) = tmp344 ; tmp300 = arg0 ; } else { tmp347 = ats_ptrget_mac(ats_ptr_type, tmp304) ; tmp346 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp347, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp304) = tmp346 ; tmp349 = ats_ptrget_mac(ats_int_type, tmp301) ; tmp348 = atspre_iadd (tmp349, 1) ; ats_ptrget_mac(ats_int_type, tmp301) = tmp348 ; tmp300 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp350 = (ats_sum_ptr_type)0 ; tmp351 = (ats_sum_ptr_type)0 ; tmp300 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ats_selptrset_mac(anairiats_sum_19, tmp300, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_19, tmp300, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_19, tmp300, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_19, tmp300, atslab_3, tmp350) ; ats_selptrset_mac(anairiats_sum_19, tmp300, atslab_4, tmp351) ; break ; } while (0) ; return (tmp300) ; } /* end of [bst_insert_random_079_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01723_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp352) ; __ats_lab_map_insert_01723_ats_ptr_type_2cats_ptr_type: // tmp297 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp298 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp352 = ats_ptrget_mac(ats_ptr_type, tmp298) ; tmp299 = bst_insert_random_079_ats_ptr_type_2cats_ptr_type (tmp352, arg1, arg2, tmp297) ; ats_ptrget_mac(ats_ptr_type, tmp298) = tmp299 ; return /* (tmp296) */ ; } /* end of [map_insert_01723_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 21994(line=774, offs=3) -- 22165(line=779, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp353) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_add: tmp293 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make (arg1, arg2) ; tmp294 = atspre_ref_get_view_ptr (statmp288) ; tmp295 = ats_selsin_mac(tmp294, atslab_1) ; tmp353 = ats_ptrget_mac(ats_ptr_type, tmp295) ; /* tmp292 = */ map_insert_01723_ats_ptr_type_2cats_ptr_type (tmp353, arg0, tmp293) ; return /* (tmp292) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_068_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_int_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_164_0 ; } __ats_lab_160_1: tmp361 = ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_1) ; tmp362 = ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_2) ; tmp363 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_3) ; tmp364 = &ats_caselptrlab_mac(anairiats_sum_19, arg0, atslab_4) ; tmp365 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp361) ; do { /* branch: __ats_lab_161 */ __ats_lab_161_0: if (tmp365 != -1) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp366 = ats_ptrget_mac(ats_ptr_type, tmp363) ; arg0 = tmp366 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: if (tmp365 != 1) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp367 = ats_ptrget_mac(ats_ptr_type, tmp364) ; arg0 = tmp367 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: // if (tmp365 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_163_1: tmp360 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp360, atslab_0, tmp362) ; break ; } while (0) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_164_1: tmp360 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp360) ; } /* end of [bst_search_068_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01725_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp368) ; __ats_lab_map_search_01725_ats_ptr_type_2cats_ptr_type: // tmp358 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp359 = &ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp368 = ats_ptrget_mac(ats_ptr_type, tmp359) ; tmp357 = bst_search_068_ats_ptr_type_2cats_ptr_type (tmp368, arg1, tmp358) ; return (tmp357) ; } /* end of [map_search_01725_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 22218(line=782, offs=16) -- 22319(line=786, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_find: tmp355 = atspre_ref_get_view_ptr (statmp288) ; tmp356 = ats_selsin_mac(tmp355, atslab_1) ; tmp369 = ats_ptrget_mac(ats_ptr_type, tmp356) ; tmp354 = map_search_01725_ats_ptr_type_2cats_ptr_type (tmp369, arg0) ; return (tmp354) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_find] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 22459(line=797, offs=4) -- 22527(line=798, offs=52) */ ATSstaticdec() ats_ptr_type tmpvarmap_nil_74 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp370) ; __ats_lab_tmpvarmap_nil_74: tmp370 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) ; return (tmp370) ; } /* end of [tmpvarmap_nil_74] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 22682(line=808, offs=15) -- 22857(line=815, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_add: tmp374 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpdef_make (arg1, arg2) ; tmp375 = atspre_ref_get_view_ptr (statmp371) ; tmp376 = ats_selsin_mac(tmp375, atslab_1) ; tmp377 = ats_ptrget_mac(ats_ptr_type, tmp376) ; /* tmp373 = */ map_insert_01723_ats_ptr_type_2cats_ptr_type (tmp377, arg0, tmp374) ; return /* (tmp373) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_hiexp_util.dats: 22910(line=818, offs=16) -- 23011(line=822, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_find: tmp379 = atspre_ref_get_view_ptr (statmp371) ; tmp380 = ats_selsin_mac(tmp379, atslab_1) ; tmp381 = ats_ptrget_mac(ats_ptr_type, tmp380) ; tmp378 = map_search_01725_ats_ptr_type_2cats_ptr_type (tmp381, arg0) ; return (tmp378) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_find] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_any_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_emp_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIBINDsome_var_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARnone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_emp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__HIEMPVARsome_var_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp288, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp291, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp371, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp372, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_ptr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_ptr = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_void = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void ; statmp291 = tmpcstmap_nil_64 () ; statmp288 = ref_make_elt_03597_ats_ptr_type (statmp291) ; statmp372 = tmpvarmap_nil_74 () ; statmp371 = ref_make_elt_03597_ats_ptr_type (statmp372) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hiexp_util_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans1_env_sats.c0000664000175000017500000000305712223166160022223 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans1_env_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_location_sats.c0000664000175000017500000000244512223166160021753 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_location_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_dec_dats.c0000664000175000017500000031566312223166160022162 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_v2aldec_loc ; ats_ptr_type atslab_v2aldec_pat ; ats_ptr_type atslab_v2aldec_def ; ats_ptr_type atslab_v2aldec_ann ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_f2undec_loc ; ats_ptr_type atslab_f2undec_var ; ats_ptr_type atslab_f2undec_def ; ats_ptr_type atslab_f2undec_ann ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_11 ; typedef struct { anairiats_rec_11 atslab_0 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_v2ardec_loc ; ats_int_type atslab_v2ardec_knd ; ats_ptr_type atslab_v2ardec_dvar ; ats_ptr_type atslab_v2ardec_svar ; ats_ptr_type atslab_v2ardec_typ ; ats_ptr_type atslab_v2ardec_wth ; ats_ptr_type atslab_v2ardec_ini ; } anairiats_rec_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_d2ec_loc ; ats_ptr_type atslab_d2ec_node ; } anairiats_rec_16 ; typedef struct { ats_ptr_type atslab_s2tavar_loc ; ats_ptr_type atslab_s2tavar_var ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_s2aspdec_fil ; ats_ptr_type atslab_s2aspdec_loc ; ats_ptr_type atslab_s2aspdec_cst ; ats_ptr_type atslab_s2aspdec_def ; } anairiats_rec_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_20 ; typedef struct { ats_ptr_type atslab_i2mpdec_loc ; ats_ptr_type atslab_i2mpdec_loc_id ; ats_ptr_type atslab_i2mpdec_cst ; ats_ptr_type atslab_i2mpdec_decarg ; ats_ptr_type atslab_i2mpdec_tmparg ; ats_ptr_type atslab_i2mpdec_tmpgua ; ats_ptr_type atslab_i2mpdec_def ; } anairiats_rec_21 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_22 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalminus_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINsome_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymelim_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstavars_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csaspdec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdcstdec_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdatdec_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cexndec_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Coverload_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextype_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextval_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextcode_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_par_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_rec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cfundecs_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvardecs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cimpdec_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clocal_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdynload_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstaload_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_sVarset) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__f3undec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__i3mpdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_saspdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dcstdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_datdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_exndec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extype) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extcode) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_par) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_rec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_fundecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_vardecs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_impdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_local) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_staload) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_addlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_bind_and_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metfn_load) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_eff) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2ec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_int_type caskind_of_valkind_3 (ats_ptr_type arg0) ; static ats_ptr_type v2aldec_tr_4 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_6 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_6_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_6_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type v2aldeclst_tr_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux1_8 (ats_ptr_type arg0) ; static ats_ptr_type aux2_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v2aldeclst_rec_tr_7 (ats_ptr_type arg0) ; static ats_ptr_type f2undec_tr_10 (ats_ptr_type arg0) ; static ats_void_type aux_12 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type d2exp_metfn_load_11 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_ini_14 (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_15 (ats_ptr_type arg0) ; static ats_ptr_type aux_fin_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_fin_16_closure_make () ; static ats_ptr_type aux_fin_16_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_17 (ats_ptr_type arg0) ; static ats_ptr_type f2undeclst_tr_13 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v2ardec_tr_sta_18 (ats_ptr_type arg0) ; static ats_bool_type d2exp_is_laminit_19 (ats_ptr_type arg0) ; static ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type v2ardec_tr_dyn_20 (ats_ptr_type arg0) ; static ats_ptr_type v2ardec_tr_22 (ats_ptr_type arg0) ; static ats_void_type aux_24 (ats_ptr_type arg0) ; static ats_ptr_type v2ardeclst_tr_23 (ats_ptr_type arg0) ; static ats_void_type f_26 (ats_ptr_type arg0) ; static ats_void_type aux_27 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 2230(line=76, offs=4) -- 2315(line=77, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 2349(line=80, offs=4) -- 2409(line=81, offs=46) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_dec)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 2441(line=84, offs=4) -- 2553(line=86, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_dec)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 2610(line=90, offs=4) -- 2810(line=96, offs=4) */ ATSstaticdec() ats_int_type caskind_of_valkind_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp5) ; __ats_lab_caskind_of_valkind_3: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = 0 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp5 = -1 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp5 = 1 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp5 = 1 ; break ; } while (0) ; return (tmp5) ; } /* end of [caskind_of_valkind_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 2867(line=100, offs=4) -- 5069(line=181, offs=4) */ ATSstaticdec() ats_ptr_type v2aldec_tr_4 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_bool_type, tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_int_type, tmp23) ; // ATSlocal_void (tmp24) ; ATSlocal (ats_bool_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; __ats_lab_v2aldec_tr_4: tmp7 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_v2aldec_loc) ; tmp8 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_v2aldec_pat) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp9 = ats_true_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp9 = ats_false_bool ; break ; } while (0) ; if (tmp9) { /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_eff (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; } else { /* empty */ } /* end of [if] */ /* tmp11 = ats_selsin_mac(tmp10, atslab_1) */ ; tmp12 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_v2aldec_def) ; tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_v2aldec_ann) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp14 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_2, tmp14, atslab_0) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp12, tmp15) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp14 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp12) ; break ; } while (0) ; if (tmp9) { /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; } else { /* empty */ } /* end of [if] */ tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp13), atslab_d3exp_typ) ; tmp18 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp18, atslab_0, tmp8) ; tmp19 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_4, tmp18), atslab_1) ; tmp20 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp19) = tmp20 ; tmp22 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp18) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (tmp22) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp21 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp23 = 0 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp21 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp23 = 1 ; break ; } while (0) ; tmp25 = atspre_eq_int_int (tmp23, 0) ; if (tmp25) { tmp26 = caskind_of_valkind_3 (arg0) ; tmp27 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp27, atslab_0, tmp17) ; tmp28 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_4, tmp27), atslab_1) ; tmp29 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp28) = tmp29 ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (tmp7, tmp26, tmp21, tmp27) ; } else { /* empty */ } /* end of [if] */ tmp30 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp8, tmp17) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat (tmp13, tmp30) ; /* tmp32 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at (tmp8) ; tmp6 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make (tmp7, tmp30, tmp13) ; return (tmp6) ; } /* end of [v2aldec_tr_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 5200(line=187, offs=7) -- 5350(line=189, offs=23) */ ATSstaticdec() ats_ptr_type aux_6 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_aux_6: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp37 = v2aldec_tr_4 (env0, tmp35) ; tmp38 = aux_6 (env0, tmp36) ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_0, tmp37) ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_1, tmp38) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp34 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp34) ; } /* end of [aux_6] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_6_closure_type ; ats_ptr_type aux_6_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_6 (((aux_6_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_6_closure_init (aux_6_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_6_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_6_closure_make (ats_ptr_type env0) { aux_6_closure_type *p_clo = ATS_MALLOC(sizeof(aux_6_closure_type)) ; aux_6_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 5119(line=185, offs=5) -- 5388(line=193, offs=4) */ ATSstaticdec() ats_ptr_type v2aldeclst_tr_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_v2aldeclst_tr_5: tmp33 = aux_6 (arg0, arg1) ; return (tmp33) ; } /* end of [v2aldeclst_tr_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 5527(line=198, offs=9) -- 6284(line=216, offs=35) */ ATSstaticdec() ats_ptr_type aux1_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; ATSlocal (ats_bool_type, tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_aux1_8: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_12_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp42 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp41), atslab_v2aldec_pat) ; tmp45 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp41), atslab_v2aldec_ann) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (tmp45 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_2, tmp45, atslab_0) ; tmp44 = tmp46 ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (tmp45 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp44 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn (tmp43) ; break ; } while (0) ; tmp48 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp44) ; if (tmp48) { tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp43), atslab_p2at_loc) ; /* tmp49 = */ prerr_loc_error3_0 (tmp50) ; /* tmp51 = */ atspre_prerr_string (ATSstrcst(": this pattern can only be assigned a nonlinear type.")) ; /* tmp52 = */ atspre_prerr_newline () ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp53 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp43, tmp44) ; tmp54 = aux1_8 (tmp42) ; tmp40 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp40, atslab_0, tmp53) ; ats_selptrset_mac(anairiats_sum_4, tmp40, atslab_1, tmp54) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp40 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp40) ; } /* end of [aux1_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 6373(line=220, offs=9) -- 7091(line=239, offs=35) */ ATSstaticdec() ats_ptr_type aux2_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_aux2_9: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp58 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp59 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp60 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp61 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp57), atslab_v2aldec_def) ; tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp59), atslab_p3at_typ) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp61, tmp62) ; tmp65 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp57), atslab_v2aldec_loc) ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3aldec_make (tmp65, tmp59, tmp63) ; tmp66 = aux2_9 (tmp58, tmp60) ; tmp56 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp56, atslab_0, tmp64) ; ats_selptrset_mac(anairiats_sum_4, tmp56, atslab_1, tmp66) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp56 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp56) ; } /* end of [aux2_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 5420(line=195, offs=5) -- 7134(line=242, offs=2) */ ATSstaticdec() ats_ptr_type v2aldeclst_rec_tr_7 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_v2aldeclst_rec_tr_7: tmp55 = aux1_8 (arg0) ; tmp39 = aux2_9 (arg0, tmp55) ; return (tmp39) ; } /* end of [v2aldeclst_rec_tr_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 7190(line=246, offs=4) -- 8737(line=301, offs=4) */ ATSstaticdec() ats_ptr_type f2undec_tr_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_f2undec_tr_10: tmp68 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_f2undec_var) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc (tmp68) ; tmp70 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg (tmp68) ; tmp71 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_f2undec_def) ; /* tmp72 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst (tmp69, tmp70) ; tmp75 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_f2undec_ann) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp75 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp76 = ats_caselptrlab_mac(anairiats_sum_2, tmp75, atslab_0) ; tmp74 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp71, tmp76) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (tmp75 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp74 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp71) ; break ; } while (0) ; tmp78 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_f2undec_loc) ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp78) ; tmp79 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp74), atslab_d3exp_typ) ; tmp67 = tmp74 ; return (tmp67) ; } /* end of [f2undec_tr_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 8857(line=307, offs=7) -- 9097(line=312, offs=14) */ ATSstaticdec() ats_void_type aux_12 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; __ats_lab_aux_12: tmp82 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp82)->tag != 30) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_9, tmp82, atslab_3) ; arg0 = tmp83 ; arg1 = arg1 ; goto __ats_lab_aux_12 ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp82)->tag != 32) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_10, tmp82, atslab_0) ; ats_ptrget_mac(ats_ptr_type, tmp84) = arg1 ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp82)->tag != 33) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_10, tmp82, atslab_2) ; arg0 = tmp85 ; arg1 = arg1 ; goto __ats_lab_aux_12 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: break ; } while (0) ; return /* (tmp81) */ ; } /* end of [aux_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 8786(line=305, offs=4) -- 9145(line=316, offs=4) */ ATSstaticdec() ats_void_type d2exp_metfn_load_11 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp80) ; __ats_lab_d2exp_metfn_load_11: /* tmp80 = */ aux_12 (arg0, arg1) ; return /* (tmp80) */ ; } /* end of [d2exp_metfn_load_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 9299(line=321, offs=7) -- 10889(line=364, offs=8) */ ATSstaticdec() ats_void_type aux_ini_14 (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (anairiats_rec_11, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; // ATSlocal_void (tmp103) ; ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_bool_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_bool_type, tmp108) ; // ATSlocal_void (tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; ATSlocal (ats_int_type, tmp116) ; __ats_lab_aux_ini_14: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_32_0 ; } __ats_lab_24_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp91 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp89), atslab_f2undec_var) ; tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp89), atslab_f2undec_def) ; /* tmp93 = */ d2exp_metfn_load_11 (tmp92, arg3) ; /* ats_ptr_type tmp94 ; */ tmp94 = (ats_sum_ptr_type)0 ; tmp96 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp89), atslab_f2undec_ann) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp96 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_2, tmp96, atslab_0) ; tmp95 = tmp97 ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp96 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp95 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (tmp92) ; break ; } while (0) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metfn_load (tmp95, tmp91) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp98 == (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_12, tmp98, atslab_0) ; ATS_FREE(tmp98) ; tmp102 = ats_select_mac(tmp100, atslab_1) ; tmp101 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp101, atslab_0, tmp102) ; tmp94 = tmp101 ; tmp99 = ats_select_mac(tmp100, atslab_0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp98 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp99 = tmp95 ; break ; } while (0) ; tmp104 = atspre_gt_int_int (arg0, 0) ; if (tmp104) { do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (ats_ptrget_mac(ats_ptr_type, arg1) == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: if (tmp94 == (ats_sum_ptr_type)0) { goto __ats_lab_31_1 ; } __ats_lab_29_2: tmp106 = ats_caselptrlab_mac(anairiats_sum_2, ats_ptrget_mac(ats_ptr_type, arg1), atslab_0) ; tmp107 = ats_caselptrlab_mac(anairiats_sum_2, tmp94, atslab_0) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst (tmp106, tmp107) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (ats_ptrget_mac(ats_ptr_type, arg1) != (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: if (tmp94 != (ats_sum_ptr_type)0) { goto __ats_lab_31_1 ; } __ats_lab_30_2: tmp105 = ats_true_bool ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: __ats_lab_31_2: tmp105 = ats_false_bool ; break ; } while (0) ; tmp108 = atspre_neg_bool (tmp105) ; if (tmp108) { tmp110 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp89), atslab_f2undec_loc) ; /* tmp109 = */ prerr_loc_error3_0 (tmp110) ; /* tmp111 = */ atspre_prerr_string (ATSstrcst(": incompatible termination metric for this function.")) ; /* tmp112 = */ atspre_prerr_newline () ; /* tmp103 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ } else { ats_ptrget_mac(ats_ptr_type, arg1) = tmp94 ; } /* end of [if] */ tmp113 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp113, atslab_0, tmp99) ; /* tmp114 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp91, tmp113) ; /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp91, tmp113) ; tmp116 = atspre_add_int_int (arg0, 1) ; arg0 = tmp116 ; arg1 = arg1 ; arg2 = tmp90 ; arg3 = arg3 ; goto __ats_lab_aux_ini_14 ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: break ; } while (0) ; return /* (tmp88) */ ; } /* end of [aux_ini_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 11074(line=369, offs=13) -- 11216(line=371, offs=29) */ ATSstaticdec() ats_ptr_type aux_15 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_aux_15: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp120 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp121 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp122 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp120), atslab_f2undec_var) ; tmp123 = aux_15 (tmp121) ; tmp119 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp119, atslab_0, tmp122) ; ats_selptrset_mac(anairiats_sum_4, tmp119, atslab_1, tmp123) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp119 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp119) ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 11306(line=376, offs=7) -- 12016(line=396, offs=10) */ ATSstaticdec() ats_ptr_type aux_fin_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; // ATSlocal_void (tmp133) ; // ATSlocal_void (tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_aux_fin_16: do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp127 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp128 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; ATS_FREE(arg1) ; tmp130 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp126), atslab_f2undec_var) ; tmp131 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp128), atslab_d3exp_typ) ; tmp132 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp132, atslab_0, tmp131) ; /* tmp133 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp130, tmp132) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp130, tmp132) ; tmp136 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp126), atslab_f2undec_loc) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__f3undec_make (tmp136, tmp130, tmp128) ; tmp137 = aux_fin_16 (tmp127, tmp129) ; tmp125 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp125, atslab_0, tmp135) ; ats_selptrset_mac(anairiats_sum_4, tmp125, atslab_1, tmp137) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp125 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp125) ; } /* end of [aux_fin_16] */ typedef struct { ats_fun_ptr_type closure_fun ; } aux_fin_16_closure_type ; ats_ptr_type aux_fin_16_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_fin_16 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_fin_16_closure_init (aux_fin_16_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_fin_16_clofun ; return ; } /* end of function */ ats_clo_ptr_type aux_fin_16_closure_make () { aux_fin_16_closure_type *p_clo = ATS_MALLOC(sizeof(aux_fin_16_closure_type)) ; aux_fin_16_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 12075(line=398, offs=9) -- 12255(line=401, offs=33) */ ATSstaticdec() ats_ptr_type aux_17 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_aux_17: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp141 = f2undec_tr_10 (tmp139) ; tmp142 = aux_17 (tmp140) ; tmp138 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp138, atslab_0, tmp141) ; ats_selptrset_mac(anairiats_sum_4, tmp138, atslab_1, tmp142) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp138 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp138) ; } /* end of [aux_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 9179(line=318, offs=4) -- 12331(line=406, offs=4) */ ATSstaticdec() ats_ptr_type f2undeclst_tr_13 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_bool_type, tmp87) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_f2undeclst_tr_13: tmp87 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive (arg0) ; if (tmp87) { /* ats_ptr_type tmp118 ; */ tmp118 = (ats_sum_ptr_type)0 ; tmp124 = aux_15 (arg1) ; /* tmp117 = */ aux_ini_14 (0, (&tmp118), arg1, tmp124) ; } else { /* empty */ } /* end of [if] */ tmp143 = aux_17 (arg1) ; tmp86 = aux_fin_16 (arg1, tmp143) ; return (tmp86) ; } /* end of [f2undeclst_tr_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 12434(line=412, offs=4) -- 16015(line=499, offs=4) */ ATSstaticdec() ats_ptr_type v2ardec_tr_sta_18 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; // ATSlocal_void (tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; // ATSlocal_void (tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; // ATSlocal_void (tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; // ATSlocal_void (tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; // ATSlocal_void (tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; // ATSlocal_void (tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; // ATSlocal_void (tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; // ATSlocal_void (tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; // ATSlocal_void (tmp209) ; // ATSlocal_void (tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_v2ardec_tr_sta_18: tmp145 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_loc) ; tmp146 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_dvar) ; tmp147 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_svar) ; tmp148 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp147) ; tmp150 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr () ; tmp149 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool (tmp148, tmp150) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (tmp145, tmp149) ; tmp152 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp148) ; tmp153 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp153, atslab_0, tmp152) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp155, atslab_0, tmp148) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp146, tmp155) ; /* tmp156 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp146, tmp153) ; /* tmp157 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp146, tmp153) ; tmp158 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_wth) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make (tmp146, tmp158) ; tmp161 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp161, atslab_0, tmp159) ; /* tmp160 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (tmp146, tmp161) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp159) ; /* ats_ptr_type tmp163 ; */ tmp165 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_typ) ; tmp166 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_ini) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (tmp165 != (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: if (tmp166 == (ats_sum_ptr_type)0) { goto __ats_lab_42_1 ; } __ats_lab_39_2: tmp167 = ats_caselptrlab_mac(anairiats_sum_2, tmp166, atslab_0) ; tmp168 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp167) ; /* tmp169 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp168) ; tmp170 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp168), atslab_d3exp_typ) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp170) ; tmp172 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp170, tmp148) ; tmp174 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp174, atslab_0, tmp172) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp159, tmp174) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp171, tmp148) ; tmp177 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp177, atslab_0, tmp175) ; /* tmp176 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp159, tmp177) ; tmp179 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp179)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp179, atslab_0, tmp175) ; /* tmp178 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp159, tmp179) ; tmp163 = tmp171 ; tmp164 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp164, atslab_0, tmp168) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (tmp165 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: if (tmp166 != (ats_sum_ptr_type)0) { goto __ats_lab_41_1 ; } __ats_lab_40_2: tmp180 = ats_caselptrlab_mac(anairiats_sum_2, tmp165, atslab_0) ; tmp181 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp180, tmp148) ; tmp183 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp183, atslab_0, tmp181) ; /* tmp182 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp159, tmp183) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp180) ; tmp184 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp185, tmp148) ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp187, atslab_0, tmp184) ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp159, tmp187) ; tmp189 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp189)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp189, atslab_0, tmp184) ; /* tmp188 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp159, tmp189) ; tmp163 = tmp180 ; tmp164 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (tmp165 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: // if (tmp166 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_2: tmp190 = ats_caselptrlab_mac(anairiats_sum_2, tmp165, atslab_0) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_2, tmp166, atslab_0) ; tmp192 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp191) ; /* tmp193 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp192) ; tmp194 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp192), atslab_d3exp_typ) ; /* tmp195 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp145, tmp194, tmp190) ; tmp196 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp190, tmp148) ; tmp198 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp198, atslab_0, tmp196) ; /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp159, tmp198) ; tmp199 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp194, tmp148) ; tmp201 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp201, atslab_0, tmp199) ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp159, tmp201) ; tmp202 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp190) ; tmp203 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp202, tmp148) ; tmp205 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp205)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp205, atslab_0, tmp203) ; /* tmp204 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp159, tmp205) ; tmp163 = tmp190 ; tmp164 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp164, atslab_0, tmp192) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (tmp165 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: // if (tmp166 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_2: /* tmp206 = */ prerr_loc_error3_0 (tmp145) ; /* tmp207 = */ atspre_prerr_string (ATSstrcst(": the uninitialized dynamic variable [")) ; /* tmp208 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp146) ; /* tmp209 = */ atspre_prerr_string (ATSstrcst("] needs to be ascribed a type.")) ; /* tmp210 = */ atspre_prerr_newline () ; /* tmp211 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp163 = tmp211 ; tmp164 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp144 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make (tmp145, 0, tmp146, tmp159, tmp163, tmp164) ; return (tmp144) ; } /* end of [v2ardec_tr_sta_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 16069(line=503, offs=5) -- 16387(line=510, offs=15) */ ATSstaticdec() ats_bool_type d2exp_is_laminit_19 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; __ats_lab_d2exp_is_laminit_19: tmp213 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp213)->tag != 31) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp212 = ats_true_bool ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp213)->tag != 33) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_10, tmp213, atslab_2) ; arg0 = tmp214 ; goto __ats_lab_d2exp_is_laminit_19 ; // tail call break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp213)->tag != 32) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_10, tmp213, atslab_2) ; arg0 = tmp215 ; goto __ats_lab_d2exp_is_laminit_19 ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp213)->tag != 21) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp216 = ats_caselptrlab_mac(anairiats_sum_15, tmp213, atslab_2) ; arg0 = tmp216 ; goto __ats_lab_d2exp_is_laminit_19 ; // tail call break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp212 = ats_false_bool ; break ; } while (0) ; return (tmp212) ; } /* end of [d2exp_is_laminit_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 19435(line=589, offs=13) -- 19694(line=593, offs=39) */ ATSstaticdec() ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; __ats_lab_aux_21: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp267 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp267, arg1) ; tmp270 = aux_21 (tmp268, arg1) ; tmp266 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp266, atslab_0, tmp269) ; ats_selptrset_mac(anairiats_sum_4, tmp266, atslab_1, tmp270) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: tmp266 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp266) ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 16469(line=516, offs=4) -- 21767(line=634, offs=4) */ ATSstaticdec() ats_ptr_type v2ardec_tr_dyn_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; // ATSlocal_void (tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_int_type, tmp265) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; // ATSlocal_void (tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_bool_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; // ATSlocal_void (tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; __ats_lab_v2ardec_tr_dyn_20: tmp218 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_loc) ; tmp219 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_dvar) ; tmp220 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_svar) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp220) ; tmp223 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr () ; tmp222 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool (tmp221, tmp223) ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (tmp218, tmp222) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp221) ; tmp226 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp226, atslab_0, tmp225) ; tmp228 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp228, atslab_0, tmp221) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp219, tmp228) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp219, tmp226) ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp219, tmp226) ; tmp231 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_wth) ; tmp232 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make (tmp219, tmp231) ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp232) ; tmp235 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_ini) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp235 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_2, tmp235, atslab_0) ; tmp234 = tmp236 ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (tmp235 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: /* tmp237 = */ prerr_loc_error3_0 (tmp218) ; /* tmp238 = */ atspre_prerr_string (ATSstrcst(": the syntax for allocating memory on stack (alloca) is incorrect.")) ; /* tmp239 = */ atspre_prerr_newline () ; /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp240 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp234), atslab_d2exp_loc) ; tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp234), atslab_d2exp_node) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp241)->tag != 4) { goto __ats_lab_61_0 ; } __ats_lab_50_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_10, tmp241, atslab_0) ; tmp243 = ats_caselptrlab_mac(anairiats_sum_10, tmp241, atslab_1) ; tmp244 = ats_caselptrlab_mac(anairiats_sum_10, tmp241, atslab_2) ; /* ats_ptr_type tmp245 ; */ tmp245 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (tmp243 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_51_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_2, tmp243, atslab_0) ; tmp248 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp247), atslab_d2exp_loc) ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp247) ; tmp251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp249), atslab_d3exp_typ) ; tmp250 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp251) ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype (tmp250) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (tmp252 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp253 = tmp252 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (tmp252 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp253 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype (tmp250) ; break ; } while (0) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (tmp253 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_2, tmp253, atslab_0) ; ATS_FREE(tmp253) ; tmp254 = tmp255 ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (tmp253 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: /* tmp256 = */ prerr_loc_error3_0 (tmp248) ; /* tmp257 = */ atsopt_debug_prerrf (ATSstrcst(": %s: v2ardec_tr_dyn"), ATSstrcst("ats_trans3_dec.dats")) ; /* tmp258 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is assgined the type [")) ; /* tmp259 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp250) ; /* tmp260 = */ atspre_prerr_string (ATSstrcst("], but it is expected to be a nonnegative integer.")) ; /* tmp261 = */ atspre_prerr_newline () ; /* tmp254 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp262 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool (tmp254, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; /* tmp263 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop (tmp248, tmp262) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp264, atslab_0, tmp249) ; tmp245 = tmp264 ; tmp246 = tmp254 ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (tmp243 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: tmp265 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp244) ; tmp246 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp265) ; break ; } while (0) ; tmp271 = aux_21 (tmp244, tmp242) ; tmp273 = (ats_sum_ptr_type)0 ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_1, tmp273) ; tmp275 = (ats_sum_ptr_type)0 ; tmp274 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_0, tmp272) ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_1, tmp275) ; tmp276 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp242, tmp274) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp242) ; tmp278 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp277, tmp274) ; tmp279 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp276, tmp221) ; tmp281 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp281, atslab_0, tmp279) ; /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp232, tmp281) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (tmp271 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp282 = tmp276 ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp282 = tmp278 ; break ; } while (0) ; tmp283 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrinit (tmp240, tmp282, tmp242, tmp245, tmp271) ; tmp284 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp282, tmp221) ; tmp286 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp286, atslab_0, tmp284) ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp232, tmp286) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp278, tmp221) ; tmp289 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp289)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp289, atslab_0, tmp287) ; /* tmp288 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp232, tmp289) ; tmp290 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp290, atslab_0, tmp283) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make (tmp218, 1, tmp219, tmp232, tmp276, tmp290) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: tmp291 = d2exp_is_laminit_19 (tmp234) ; if (!tmp291) { goto __ats_lab_62_1 ; } tmp292 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp234) ; tmp293 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp292), atslab_d3exp_typ) ; tmp294 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp293, tmp221) ; tmp296 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp296, atslab_0, tmp294) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp232, tmp296) ; tmp297 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp293) ; tmp298 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp297, tmp221) ; tmp300 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp300, atslab_0, tmp294) ; /* tmp299 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp232, tmp300) ; tmp302 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp302)->tag = 2 ; ats_selptrset_mac(anairiats_sum_14, tmp302, atslab_0, tmp298) ; /* tmp301 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp232, tmp302) ; tmp303 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp303, atslab_0, tmp292) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__v3ardec_make (tmp218, 1, tmp219, tmp232, tmp293, tmp303) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: __ats_lab_62_1: /* tmp304 = */ prerr_loc_error3_0 (tmp218) ; /* tmp305 = */ atsopt_debug_prerrf (ATSstrcst(": %s: v2ardec_tr_dyn"), ATSstrcst("ats_trans3_dec.dats")) ; /* tmp306 = */ atspre_prerr_string (ATSstrcst(": the syntax for allocating memory on stack (alloca) is incorrect.")) ; /* tmp307 = */ atspre_prerr_newline () ; /* tmp308 = */ atspre_prerr_string (ATSstrcst("d2e_ini = ")) ; /* tmp309 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (tmp234) ; /* tmp310 = */ atspre_prerr_newline () ; /* tmp217 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp217) ; } /* end of [v2ardec_tr_dyn_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 21820(line=638, offs=4) -- 22069(line=648, offs=4) */ ATSstaticdec() ats_ptr_type v2ardec_tr_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_int_type, tmp312) ; ATSlocal (ats_bool_type, tmp313) ; __ats_lab_v2ardec_tr_22: tmp312 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_v2ardec_knd) ; tmp313 = atspre_eq_int_int (tmp312, 0) ; if (tmp313) { tmp311 = v2ardec_tr_sta_18 (arg0) ; } else { tmp311 = v2ardec_tr_dyn_20 (arg0) ; } /* end of [if] */ return (tmp311) ; } /* end of [v2ardec_tr_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 22189(line=654, offs=9) -- 22435(line=659, offs=21) */ ATSstaticdec() ats_void_type aux_24 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; // ATSlocal_void (tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_aux_24: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp316 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp319 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp316), atslab_v2ardec_svar) ; /* tmp318 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp319) ; arg0 = tmp317 ; goto __ats_lab_aux_24 ; // tail call break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: break ; } while (0) ; return /* (tmp315) */ ; } /* end of [aux_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 22097(line=650, offs=4) -- 22539(line=664, offs=4) */ ATSstaticdec() ats_ptr_type v2ardeclst_tr_23 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp314) ; // ATSlocal_void (tmp320) ; __ats_lab_v2ardeclst_tr_23: /* tmp320 = */ aux_24 (arg0) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &v2ardec_tr_22) ; return (tmp314) ; } /* end of [v2ardeclst_tr_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 23129(line=686, offs=10) -- 23401(line=693, offs=10) */ ATSstaticdec() ats_void_type f_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; // ATSlocal_void (tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_f_26: tmp334 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s2tavar_loc) ; tmp335 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s2tavar_var) ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp335) ; tmp337 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var (tmp334, tmp335) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (tmp334, tmp335, tmp337) ; return /* (tmp333) */ ; } /* end of [f_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 23940(line=710, offs=11) -- 24196(line=716, offs=31) */ ATSstaticdec() ats_void_type aux_27 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; // ATSlocal_void (tmp354) ; __ats_lab_aux_27: do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp352 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp353 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp354 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_sVarset (tmp352, arg0) ; arg0 = arg0 ; arg1 = tmp353 ; goto __ats_lab_aux_27 ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: break ; } while (0) ; return /* (tmp351) */ ; } /* end of [aux_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 22606(line=668, offs=19) -- 27829(line=820, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2ec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; // ATSlocal_void (tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; // ATSlocal_void (tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; // ATSlocal_void (tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_int_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; // ATSlocal_void (tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; // ATSlocal_void (tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; // ATSlocal_void (tmp414) ; // ATSlocal_void (tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_int_type, tmp418) ; ATSlocal (ats_int_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_bool_type, tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; // ATSlocal_void (tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2ec_tr: tmp322 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_node) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp322)->tag != 0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp323 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (tmp323) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp322)->tag != 1) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp325 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp326 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp324) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list (tmp325, tmp326) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp322)->tag != 2) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp328 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp329 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp327) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_list (tmp328, tmp329) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp322)->tag != 3) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (tmp330) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp322)->tag != 4) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp331 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (tmp331) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp322)->tag != 5) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; /* tmp338 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp332, &f_26) ; tmp339 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (tmp339) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp322)->tag != 6) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp341 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp340), atslab_s2aspdec_loc) ; tmp342 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp340), atslab_s2aspdec_cst) ; tmp343 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp340), atslab_s2aspdec_def) ; /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_bind_and_add (tmp341, tmp342, tmp343) ; tmp345 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_saspdec (tmp345, tmp340) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp322)->tag != 7) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp347 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dcstdec (tmp348, tmp346, tmp347) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp322)->tag != 8) { goto __ats_lab_76_0 ; } __ats_lab_73_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; tmp356 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get () ; /* tmp355 = */ aux_27 (tmp356, tmp350) ; tmp357 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_datdec (tmp357, tmp349, tmp350) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp322)->tag != 9) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp359 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_exndec (tmp359, tmp358) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp322)->tag != 10) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp360 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_none (tmp360) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp322)->tag != 11) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp361 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp362 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; tmp363 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extype (tmp363, tmp361, tmp362) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp322)->tag != 12) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; tmp366 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp365) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extval (tmp366, tmp364, tmp367) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp322)->tag != 13) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_20, tmp322, atslab_0) ; tmp369 = ats_caselptrlab_mac(anairiats_sum_20, tmp322, atslab_1) ; tmp370 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_extcode (tmp370, tmp368, tmp369) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp322)->tag != 14) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; tmp373 = v2aldeclst_tr_5 (tmp371, tmp372) ; tmp374 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs (tmp374, tmp371, tmp373) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp322)->tag != 15) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp375 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp377 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0) ; tmp376 = v2aldeclst_tr_5 (tmp377, tmp375) ; tmp378 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_par (tmp378, tmp376) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp322)->tag != 16) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp379 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp380 = v2aldeclst_rec_tr_7 (tmp379) ; tmp381 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_valdecs_rec (tmp381, tmp380) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp322)->tag != 17) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp382 = ats_caselptrlab_mac(anairiats_sum_10, tmp322, atslab_0) ; tmp383 = ats_caselptrlab_mac(anairiats_sum_10, tmp322, atslab_1) ; tmp384 = ats_caselptrlab_mac(anairiats_sum_10, tmp322, atslab_2) ; tmp385 = f2undeclst_tr_13 (tmp383, tmp384) ; tmp386 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_fundecs (tmp386, tmp382, tmp383, tmp385) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp322)->tag != 18) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp388 = v2ardeclst_tr_23 (tmp387) ; tmp389 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_vardecs (tmp389, tmp388) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp322)->tag != 19) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp390 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp391 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_loc) ; tmp392 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_loc_id) ; tmp393 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_cst) ; tmp394 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_decarg) ; tmp395 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_tmparg) ; tmp396 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_tmpgua) ; /* tmp397 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp398 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst (tmp392, tmp396) ; /* tmp399 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst (tmp391, tmp394) ; tmp401 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, tmp390), atslab_i2mpdec_def) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp401) ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp391) ; tmp403 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__i3mpdec_make (tmp391, tmp393, tmp394, tmp395, tmp400) ; tmp404 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_impdec (tmp404, tmp403) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp322)->tag != 20) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_19, tmp322, atslab_1) ; /* tmp407 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp408 = ats_selsin_mac(tmp407, atslab_1) */ ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp405) ; /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp411 = ats_selsin_mac(tmp410, atslab_1) */ ; tmp412 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp406) ; tmp413 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop () ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_addlst (tmp413) ; tmp416 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_local (tmp416, tmp409, tmp412) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp322)->tag != 22) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp417 = ats_caselptrlab_mac(anairiats_sum_22, tmp322, atslab_1) ; tmp418 = ats_caselptrlab_mac(anairiats_sum_22, tmp322, atslab_2) ; tmp419 = ats_caselptrlab_mac(anairiats_sum_22, tmp322, atslab_3) ; tmp420 = ats_caselptrlab_mac(anairiats_sum_22, tmp322, atslab_4) ; tmp422 = atspre_gt_int_int (tmp418, 0) ; if (tmp422) { tmp421 = (ats_sum_ptr_type)0 ; } else { /* tmp423 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp424 = ats_selsin_mac(tmp423, atslab_1) */ ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp420) ; /* tmp426 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () ; tmp421 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp421, atslab_0, tmp425) ; } /* end of [if] */ tmp427 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_staload (tmp427, tmp417, tmp419, tmp421) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (((ats_sum_ptr_type)tmp322)->tag != 21) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp428 = ats_caselptrlab_mac(anairiats_sum_14, tmp322, atslab_0) ; tmp429 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d2ec_loc) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3ec_dynload (tmp429, tmp428) ; break ; } while (0) ; return (tmp321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2ec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 27933(line=825, offs=22) -- 27975(line=825, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp430) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr: tmp430 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2ec_tr) ; return (tmp430) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_dec.dats: 28024(line=830, offs=17) -- 28317(line=841, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c3str_get_final () { /* local vardec */ ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c3str_get_final: tmp432 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_get () ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp432) ; tmp434 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; tmp431 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy, tmp434, tmp433) ; return (tmp431) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c3str_get_final] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_dec_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_grammar_yats.c0000664000175000017500000114101412223166160021574 0ustar hwxihwxi/* A Bison parser, made by GNU Bison 2.5. */ /* Bison implementation for Yacc-like parsers in C Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work under terms of your choice, so long as that work isn't itself a parser generator using the skeleton or a modified version thereof as a parser skeleton. Alternatively, if you modify or redistribute the parser skeleton itself, you may (at your option) remove this special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ /* C LALR(1) parser skeleton written by Richard Stallman, by simplifying the original so-called "semantic" parser. */ /* All symbols defined below should begin with yy or YY, to avoid infringing on user name space. This should be done even for local variables, as they might otherwise be expanded by user macros. There are some unavoidable exceptions within include files to define necessary library symbols; they are noted "INFRINGES ON USER NAME SPACE" below. */ /* Identify Bison output. */ #define YYBISON 1 /* Bison version. */ #define YYBISON_VERSION "2.5" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" /* Pure parsers. */ #define YYPURE 0 /* Push parsers. */ #define YYPUSH 0 /* Pull parsers. */ #define YYPULL 1 /* Using locations. */ #define YYLSP_NEEDED 0 /* Copy the first part of user declarations. */ /* Line 268 of yacc.c */ #line 17 "ats_grammar.yats" // #include // for [fprintf] #include "ats_memory.h" // HX: loading [ats_types.h] as well /* // HX: this is okay #define malloc ats_malloc_gc #define realloc ats_realloc_gc #define free ats_free_gc */ // // HX-2011-09-06: // #define malloc ats_malloc_ngc #define realloc ats_realloc_ngc #define free ats_free_ngc extern void yyerror (char *s) ; /* ****** ****** */ typedef ats_ptr_type c0har_t ; typedef ats_ptr_type e0xtcode_t ; typedef ats_ptr_type f0loat_t ; typedef ats_ptr_type f0loatsp_t ; typedef ats_ptr_type i0nt_t ; typedef ats_ptr_type i0ntsp_t ; typedef ats_ptr_type s0tring_t ; typedef ats_ptr_type t0kn_t ; typedef ats_ptr_type abskind_t ; typedef ats_ptr_type dcstkind_t ; typedef ats_ptr_type datakind_t ; typedef ats_ptr_type stadefkind_t ; typedef ats_ptr_type valkind_t ; typedef ats_ptr_type funkind_t ; typedef ats_ptr_type lamkind_t ; typedef lamkind_t fixkind_t ; typedef ats_ptr_type srpifkindtok_t ; typedef ats_ptr_type i0de_t ; typedef ats_ptr_type i0delst_t ; typedef ats_ptr_type i0delstlst_t ; typedef ats_ptr_type i0dext_t ; typedef ats_ptr_type l0ab_t ; typedef ats_ptr_type p0rec_t ; typedef ats_ptr_type e0xp_t ; typedef ats_ptr_type e0xplst_t ; typedef ats_ptr_type e0xpopt_t ; typedef ats_ptr_type e0fftag_t ; typedef ats_ptr_type e0fftaglst_t ; typedef ats_ptr_type e0fftaglstopt_t ; typedef ats_ptr_type s0rtq_t ; typedef ats_ptr_type s0rt_t ; typedef ats_ptr_type s0rtlst_t ; typedef ats_ptr_type s0rtopt_t ; typedef ats_ptr_type s0rtpol_t ; typedef ats_ptr_type d0atsrtcon_t ; typedef ats_ptr_type d0atsrtconlst_t ; typedef ats_ptr_type d0atsrtdec_t ; typedef ats_ptr_type d0atsrtdeclst_t ; typedef ats_ptr_type s0taq_t ; typedef ats_ptr_type d0ynq_t ; typedef ats_ptr_type sqi0de_t ; typedef ats_ptr_type dqi0de_t ; typedef ats_ptr_type arrqi0de_t ; typedef ats_ptr_type tmpqi0de_t ; typedef ats_ptr_type s0arg_t ; typedef ats_ptr_type s0arglst_t ; typedef ats_ptr_type s0arglstlst_t ; typedef ats_ptr_type s0exp_t ; typedef ats_ptr_type s0expext_t ; // for external types typedef ats_ptr_type s0explst_t ; typedef ats_ptr_type s0expopt_t ; typedef ats_ptr_type s0explstlst_t ; typedef ats_ptr_type s0explstopt_t ; typedef ats_ptr_type labs0explst_t ; typedef ats_ptr_type s0arrind_t ; typedef ats_ptr_type t1mps0explstlst_t ; // with location information typedef ats_ptr_type s0rtext_t ; typedef ats_ptr_type s0qua_t ; typedef ats_ptr_type s0qualst_t ; typedef ats_ptr_type s0qualstlst_t ; typedef ats_ptr_type s0qualstopt_t ; typedef ats_ptr_type impqi0de_t ; typedef ats_ptr_type sp0at_t ; typedef ats_ptr_type d0atarg_t ; typedef ats_ptr_type d0atarglst_t ; typedef ats_ptr_type s0rtdef_t ; typedef ats_ptr_type s0rtdeflst_t ; typedef ats_ptr_type s0tacon_t ; typedef ats_ptr_type s0taconlst_t ; typedef ats_ptr_type s0tacst_t ; typedef ats_ptr_type s0tacstlst_t ; typedef ats_ptr_type s0tavar_t ; typedef ats_ptr_type s0tavarlst_t ; typedef ats_ptr_type s0expdef_t ; typedef ats_ptr_type s0expdeflst_t ; typedef ats_ptr_type s0aspdec_t ; typedef ats_ptr_type d0atcon_t ; typedef ats_ptr_type d0atconlst_t ; typedef ats_ptr_type d0atdec_t ; typedef ats_ptr_type d0atdeclst_t ; typedef ats_ptr_type e0xndec_t ; typedef ats_ptr_type e0xndeclst_t ; typedef ats_ptr_type p0arg_t ; typedef ats_ptr_type p0arglst_t ; typedef ats_ptr_type d0arg_t ; typedef ats_ptr_type d0arglst_t ; typedef ats_ptr_type m0acarg_t ; typedef ats_ptr_type m0acarglst_t ; typedef ats_ptr_type extnamopt_t ; typedef ats_ptr_type d0cstdec_t ; typedef ats_ptr_type d0cstdeclst_t ; typedef ats_ptr_type p0at_t ; typedef ats_ptr_type p0atlst_t ; typedef ats_ptr_type labp0atlst_t ; typedef ats_ptr_type s0vararg_t ; typedef ats_ptr_type s0exparg_t ; typedef ats_ptr_type f0arg_t ; typedef ats_ptr_type f0arglst_t ; typedef ats_ptr_type s0elop_t ; typedef ats_ptr_type witht0ype_t ; typedef ats_ptr_type d0exp_t ; typedef ats_ptr_type d0explst_t ; typedef ats_ptr_type d0expopt_t ; typedef ats_ptr_type labd0explst_t ; typedef ats_ptr_type d0arrind_t ; typedef ats_ptr_type ifhead_t ; typedef ats_ptr_type casehead_t ; typedef ats_ptr_type loophead_t ; typedef ats_ptr_type tryhead_t ; typedef ats_ptr_type m0atch_t ; typedef ats_ptr_type m0atchlst_t ; typedef ats_ptr_type guap0at_t ; typedef ats_ptr_type c0lau_t ; typedef ats_ptr_type c0laulst_t ; typedef ats_ptr_type sc0lau_t ; typedef ats_ptr_type sc0laulst_t ; typedef ats_ptr_type i0nvarg_t ; typedef ats_ptr_type i0nvarglst_t ; typedef ats_ptr_type i0nvresstate_t ; typedef ats_ptr_type loopi0nv_t ; typedef ats_ptr_type initestpost_t ; typedef ats_ptr_type v0aldec_t ; typedef ats_ptr_type v0aldeclst_t ; typedef ats_ptr_type f0undec_t ; typedef ats_ptr_type f0undeclst_t ; typedef ats_ptr_type v0arwth_t ; typedef ats_ptr_type v0ardec_t ; typedef ats_ptr_type v0ardeclst_t ; typedef ats_ptr_type m0acdef_t ; typedef ats_ptr_type m0acdeflst_t ; typedef ats_ptr_type i0mpdec_t ; typedef ats_ptr_type d0ec_t ; typedef ats_ptr_type d0eclst_t ; typedef ats_ptr_type d0ecllst_t ; typedef ats_ptr_type guad0ec_t ; /* ****** ****** */ typedef ats_ptr_type yyres_t ; /* ****** ****** */ yyres_t theYYVALyyres ; /* the result of parsing */ /* ****** ****** */ extern abskind_t abskind_prop (void) ; extern abskind_t abskind_type (void) ; extern abskind_t abskind_t0ype (void) ; extern abskind_t abskind_view (void) ; extern abskind_t abskind_viewtype (void) ; extern abskind_t abskind_viewt0ype (void) ; extern dcstkind_t dcstkind_fun (void) ; extern dcstkind_t dcstkind_val (void) ; extern dcstkind_t dcstkind_castfn (void) ; extern dcstkind_t dcstkind_praxi (void) ; extern dcstkind_t dcstkind_prfun (void) ; extern dcstkind_t dcstkind_prval (void) ; extern datakind_t datakind_prop (void) ; extern datakind_t datakind_type (void) ; extern datakind_t datakind_view (void) ; extern datakind_t datakind_viewtype (void) ; extern stadefkind_t stadefkind_generic (void) ; extern stadefkind_t stadefkind_prop (t0kn_t) ; extern stadefkind_t stadefkind_type (t0kn_t) ; extern stadefkind_t stadefkind_view (t0kn_t) ; extern stadefkind_t stadefkind_viewtype (t0kn_t) ; extern valkind_t valkind_val (void) ; extern valkind_t valkind_valminus (void) ; extern valkind_t valkind_valplus (void) ; extern valkind_t valkind_prval (void) ; extern funkind_t funkind_fn (void) ; extern funkind_t funkind_fnstar (void) ; extern funkind_t funkind_fun (void) ; extern funkind_t funkind_castfn (void) ; extern funkind_t funkind_prfn (void) ; extern funkind_t funkind_prfun (void) ; extern lamkind_t lamkind_lam (t0kn_t) ; extern lamkind_t lamkind_atlam (t0kn_t) ; extern lamkind_t lamkind_llam (t0kn_t) ; extern lamkind_t lamkind_atllam (t0kn_t) ; extern fixkind_t fixkind_fix (t0kn_t) ; extern fixkind_t fixkind_atfix (t0kn_t) ; extern srpifkindtok_t srpifkindtok_if (t0kn_t) ; extern srpifkindtok_t srpifkindtok_ifdef (t0kn_t) ; extern srpifkindtok_t srpifkindtok_ifndef (t0kn_t) ; /* ****** ****** */ extern i0de_t i0de_make_ampersand (t0kn_t) ; extern i0de_t i0de_make_backslash (t0kn_t) ; extern i0de_t i0de_make_bang (t0kn_t) ; extern i0de_t i0de_make_eq (t0kn_t) ; extern i0de_t i0de_make_gt (t0kn_t) ; extern i0de_t i0de_make_gtlt (t0kn_t) ; extern i0de_t i0de_make_lt (t0kn_t) ; extern i0de_t i0de_make_minusgt (t0kn_t) ; extern i0de_t i0de_make_minuslt (t0kn_t) ; extern i0de_t i0de_make_minusltgt (t0kn_t) ; extern i0de_t i0de_make_module (t0kn_t) ; extern i0de_t i0de_make_r0ead (t0kn_t) ; extern i0de_t i0de_make_tilde (t0kn_t) ; extern i0de_t i0de_make_t0ype (t0kn_t) ; extern i0de_t i0de_make_viewt0ype (t0kn_t) ; extern i0de_t i0de_make_DO (t0kn_t) ; extern i0de_t i0de_make_IN (t0kn_t) ; extern i0de_t i0de_make_WHILE (t0kn_t) ; extern i0delst_t i0delst_nil (void) ; extern i0delst_t i0delst_sing (i0de_t) ; extern i0delst_t i0delst_cons (i0de_t, i0delst_t) ; extern i0delstlst_t i0delstlst_nil (void) ; extern i0delstlst_t i0delstlst_cons (i0delst_t, i0delstlst_t) ; extern l0ab_t l0ab_ide (i0de_t) ; extern l0ab_t l0ab_int (i0nt_t) ; extern i0de_t stai0de_make (i0de_t) ; /* ****** ****** */ extern p0rec_t p0rec_emp (void) ; extern p0rec_t p0rec_ide (i0de_t) ; extern p0rec_t p0rec_int (i0nt_t) ; extern p0rec_t p0rec_opr (i0de_t, i0de_t/*opr*/, i0nt_t) ; /* ****** ****** */ extern e0xp_t e0xp_app (e0xp_t, e0xp_t) ; extern e0xp_t e0xp_char (c0har_t) ; extern e0xp_t e0xp_eval (t0kn_t, e0xp_t, t0kn_t) ; extern e0xp_t e0xp_float (f0loat_t) ; extern e0xp_t e0xp_ide (i0de_t) ; extern e0xp_t e0xp_int (i0nt_t) ; extern e0xp_t e0xp_list (t0kn_t, e0xplst_t, t0kn_t) ; extern e0xp_t e0xp_string (s0tring_t) ; extern e0xp_t e0xp_FILENAME (t0kn_t) ; // a special string constant extern e0xp_t e0xp_LOCATION (t0kn_t) ; // a special string constant extern e0xplst_t e0xplst_nil (void) ; extern e0xplst_t e0xplst_cons (e0xp_t, e0xplst_t) ; extern e0xpopt_t e0xpopt_none (void) ; extern e0xpopt_t e0xpopt_some (e0xp_t) ; /* ****** ****** */ extern e0fftag_t e0fftag_cst (int, i0de_t) ; extern e0fftag_t e0fftag_var (i0de_t) ; extern e0fftag_t e0fftag_var_fun (t0kn_t) ; extern e0fftag_t e0fftag_int (i0nt_t) ; extern e0fftaglst_t e0fftaglst_nil (void) ; extern e0fftaglst_t e0fftaglst_cons (e0fftag_t, e0fftaglst_t) ; extern e0fftaglstopt_t e0fftaglstopt_none (void) ; extern e0fftaglstopt_t e0fftaglstopt_some (e0fftaglst_t) ; /* ****** ****** */ extern s0rtq_t s0rtq_str (s0tring_t) ; extern s0rtq_t s0rtq_sym (i0de_t) ; extern s0rt_t s0rt_prop (t0kn_t) ; extern s0rt_t s0rt_type (t0kn_t) ; extern s0rt_t s0rt_t0ype (t0kn_t) ; extern s0rt_t s0rt_view (t0kn_t) ; extern s0rt_t s0rt_viewtype (t0kn_t) ; extern s0rt_t s0rt_viewt0ype (t0kn_t) ; extern s0rt_t s0rt_app (s0rt_t, s0rt_t) ; extern s0rt_t s0rt_ide (i0de_t) ; extern s0rt_t s0rt_qid (s0rtq_t, i0de_t) ; extern s0rt_t s0rt_list (t0kn_t, s0rtlst_t, t0kn_t) ; extern s0rt_t s0rt_tup (t0kn_t, s0rtlst_t, t0kn_t) ; extern s0rtlst_t s0rtlst_nil (void) ; extern s0rtlst_t s0rtlst_cons (s0rt_t, s0rtlst_t) ; extern s0rtopt_t s0rtopt_none (void) ; extern s0rtopt_t s0rtopt_some (s0rt_t) ; extern s0rtpol_t s0rtpol_make (s0rt_t, int) ; /* ****** ****** */ /* ** datasort declaration */ extern d0atsrtcon_t d0atsrtcon_make_none (i0de_t) ; extern d0atsrtcon_t d0atsrtcon_make_some (i0de_t, s0rt_t) ; extern d0atsrtconlst_t d0atsrtconlst_nil (void) ; extern d0atsrtconlst_t d0atsrtconlst_cons (d0atsrtcon_t, d0atsrtconlst_t) ; extern d0atsrtdec_t d0atsrtdec_make (i0de_t, d0atsrtconlst_t) ; extern d0atsrtdeclst_t d0atsrtdeclst_nil (void) ; extern d0atsrtdeclst_t d0atsrtdeclst_cons (d0atsrtdec_t, d0atsrtdeclst_t) ; /* ****** ****** */ /* ** static qualifiers */ extern s0taq_t s0taq_symdot (i0de_t) ; extern s0taq_t s0taq_symcolon (i0de_t) ; extern s0taq_t s0taq_fildot (s0tring_t) ; /* ** dynamic qualifiers */ extern d0ynq_t d0ynq_symcolon(i0de_t) ; extern d0ynq_t d0ynq_symdot(i0de_t) ; extern d0ynq_t d0ynq_symdot_symcolon(i0de_t, i0de_t) ; extern d0ynq_t d0ynq_fildot(s0tring_t) ; extern d0ynq_t d0ynq_fildot_symcolon(s0tring_t, i0de_t) ; /* ****** ****** */ /* ** (qualified) static identifiers */ extern sqi0de_t sqi0de_make_none (i0de_t) ; extern sqi0de_t sqi0de_make_some (s0taq_t, i0de_t) ; /* ** (qualified) dynamic identifiers */ extern dqi0de_t dqi0de_make_none (i0de_t) ; extern dqi0de_t dqi0de_make_some (d0ynq_t, i0de_t) ; /* ** (qualified) array identifiers */ extern arrqi0de_t arrqi0de_make_none (i0de_t) ; extern arrqi0de_t arrqi0de_make_some (d0ynq_t, i0de_t) ; /* ** (qualified) template identifiers */ extern tmpqi0de_t tmpqi0de_make_none (i0de_t) ; extern tmpqi0de_t tmpqi0de_make_some (d0ynq_t, i0de_t) ; /* ****** ****** */ /* ** static arguments */ extern s0arg_t s0arg_make (i0de_t, s0rtopt_t) ; extern s0arg_t s0arg_make_none (i0de_t) ; extern s0arglst_t s0arglst_nil (void) ; extern s0arglst_t s0arglst_cons (s0arg_t, s0arglst_t) ; extern s0arglstlst_t s0arglstlst_nil (void) ; extern s0arglstlst_t s0arglstlst_cons (s0arglst_t, s0arglstlst_t) ; extern s0arglstlst_t s0arglstlst_cons_ide (i0de_t, s0arglstlst_t) ; /* ****** ****** */ extern impqi0de_t impqi0de_make_none (dqi0de_t) ; extern impqi0de_t impqi0de_make_some (tmpqi0de_t, s0explst_t, t1mps0explstlst_t, t0kn_t) ; /* ****** ****** */ extern sp0at_t sp0at_con (sqi0de_t, s0arglst_t, t0kn_t) ; /* ****** ****** */ /* ** static expressions */ extern s0exp_t s0exp_ann (s0exp_t, s0rt_t) ; extern s0exp_t s0exp_app (s0exp_t, s0exp_t) ; extern s0exp_t s0exp_char (c0har_t) ; extern s0exp_t s0exp_exi (t0kn_t, int/*funres*/, s0qualst_t, t0kn_t) ; extern s0expext_t s0expext_nam (t0kn_t, s0tring_t/*name*/) ; extern s0expext_t s0expext_app (s0expext_t/*fun*/, s0exp_t/*arg*/) ; extern s0exp_t s0exp_extern (s0expext_t) ; extern s0exp_t s0exp_ide (i0de_t) ; extern s0exp_t s0exp_imp (t0kn_t, e0fftaglst_t, t0kn_t) ; extern s0exp_t s0exp_imp_emp (t0kn_t) ; extern s0exp_t s0exp_int (i0nt_t) ; extern s0exp_t s0exp_intsp_err (i0nt_t) ; /* error handling */ extern s0exp_t s0exp_lams (t0kn_t, s0arglstlst_t, s0rtopt_t, s0exp_t) ; extern s0exp_t s0exp_list (t0kn_t, s0explst_t, t0kn_t) ; extern s0exp_t s0exp_list2 (t0kn_t, s0explst_t, s0explst_t, t0kn_t) ; /* // HX-2010-12-04: inadequate design extern s0exp_t s0exp_named (i0de_t, s0exp_t) ; */ extern s0exp_t s0exp_opide (t0kn_t, i0de_t) ; extern s0exp_t s0exp_qid (s0taq_t, i0de_t) ; extern s0exp_t s0exp_struct (t0kn_t, labs0explst_t, t0kn_t) ; extern s0exp_t s0exp_tyarr (t0kn_t, s0exp_t, s0arrind_t) ; extern s0exp_t s0exp_tyrec (int, t0kn_t, labs0explst_t, t0kn_t) ; extern s0exp_t s0exp_tyrec_ext (t0kn_t, s0tring_t, labs0explst_t, t0kn_t) ; extern s0exp_t s0exp_tytup (int, t0kn_t, s0explst_t, t0kn_t) ; extern s0exp_t s0exp_tytup2 (int, t0kn_t, s0explst_t, s0explst_t, t0kn_t) ; extern s0exp_t s0exp_uni (t0kn_t, s0qualst_t, t0kn_t) ; extern s0exp_t s0exp_union (t0kn_t, s0exp_t, labs0explst_t, t0kn_t) ; extern s0explst_t s0explst_nil (void) ; extern s0explst_t s0explst_cons (s0exp_t, s0explst_t) ; extern s0expopt_t s0expopt_none (void) ; extern s0expopt_t s0expopt_some (s0exp_t) ; extern s0explstlst_t s0explstlst_nil (void) ; extern s0explstlst_t s0explstlst_cons (s0explst_t, s0explstlst_t) ; extern s0explstopt_t s0explstopt_none (void) ; extern s0explstopt_t s0explstopt_some (s0explst_t) ; extern labs0explst_t labs0explst_nil (void) ; extern labs0explst_t labs0explst_cons (l0ab_t, s0exp_t, labs0explst_t) ; extern s0arrind_t s0arrind_make_sing (s0explst_t, t0kn_t) ; extern s0arrind_t s0arrind_make_cons (s0explst_t, s0arrind_t) ; extern t1mps0explstlst_t gtlt_t1mps0expseqseq_nil (void) ; extern t1mps0explstlst_t gtlt_t1mps0expseqseq_cons_tok (t0kn_t, s0explst_t, t1mps0explstlst_t) ; // end of [extern] /* ****** ****** */ extern s0rtext_t s0rtext_srt (s0rt_t) ; extern s0rtext_t s0rtext_sub (t0kn_t, i0de_t, s0rtext_t, s0exp_t, s0explst_t, t0kn_t) ; extern s0qua_t s0qua_prop(s0exp_t) ; extern s0qua_t s0qua_vars(i0de_t, i0delst_t, s0rtext_t) ; extern s0qualst_t s0qualst_nil (void) ; extern s0qualst_t s0qualst_cons (s0qua_t, s0qualst_t) ; extern s0qualstlst_t s0qualstlst_nil (void) ; extern s0qualstlst_t s0qualstlst_cons (s0qualst_t, s0qualstlst_t) ; extern s0qualstopt_t s0qualstopt_none (void) ; extern s0qualstopt_t s0qualstopt_some (s0qualst_t) ; /* ****** ****** */ extern d0atarg_t d0atarg_srt (s0rtpol_t) ; extern d0atarg_t d0atarg_id_srt (i0de_t, s0rtpol_t) ; extern d0atarglst_t d0atarglst_nil (void) ; extern d0atarglst_t d0atarglst_cons (d0atarg_t, d0atarglst_t) ; /* ****** ****** */ extern s0rtdef_t s0rtdef_make (i0de_t, s0rtext_t) ; extern s0rtdeflst_t s0rtdeflst_nil (void) ; extern s0rtdeflst_t s0rtdeflst_cons (s0rtdef_t, s0rtdeflst_t) ; /* ****** ****** */ extern s0tacon_t s0tacon_make_none_none (i0de_t) ; extern s0tacon_t s0tacon_make_some_none (i0de_t, d0atarglst_t, t0kn_t) ; extern s0tacon_t s0tacon_make_none_some (i0de_t, s0exp_t) ; extern s0tacon_t s0tacon_make_some_some (i0de_t, d0atarglst_t, s0exp_t) ; extern s0taconlst_t s0taconlst_nil (void) ; extern s0taconlst_t s0taconlst_cons (s0tacon_t, s0taconlst_t) ; extern s0tacst_t s0tacst_make_none (i0de_t, s0rt_t) ; extern s0tacst_t s0tacst_make_some (i0de_t, d0atarglst_t, s0rt_t) ; extern s0tacstlst_t s0tacstlst_nil (void) ; extern s0tacstlst_t s0tacstlst_cons (s0tacst_t, s0tacstlst_t) ; extern s0tavar_t s0tavar_make (i0de_t, s0rt_t) ; extern s0tavarlst_t s0tavarlst_nil (void) ; extern s0tavarlst_t s0tavarlst_cons (s0tavar_t, s0tavarlst_t) ; /* ****** ****** */ extern s0expdef_t s0expdef_make (i0de_t, s0arglstlst_t, s0rtopt_t, s0exp_t) ; extern s0expdeflst_t s0expdeflst_nil (void) ; extern s0expdeflst_t s0expdeflst_cons (s0expdef_t, s0expdeflst_t) ; // extern s0aspdec_t s0aspdec_make (i0de_t, s0arglstlst_t, s0rtopt_t, s0exp_t) ; // extern d0atcon_t d0atcon_make (s0qualstlst_t, i0de_t, s0explstopt_t, s0expopt_t) ; extern d0atconlst_t d0atconlst_nil (void) ; extern d0atconlst_t d0atconlst_cons (d0atcon_t, d0atconlst_t) ; // extern d0atdec_t d0atdec_make_none (i0de_t, d0atconlst_t) ; extern d0atdec_t d0atdec_make_some (i0de_t, d0atarglst_t, t0kn_t, d0atconlst_t) ; extern d0atdeclst_t d0atdeclst_nil (void) ; extern d0atdeclst_t d0atdeclst_cons (d0atdec_t, d0atdeclst_t) ; // extern e0xndec_t e0xndec_make (s0qualstlst_t, i0de_t, s0expopt_t) ; extern e0xndeclst_t e0xndeclst_nil (void) ; extern e0xndeclst_t e0xndeclst_cons (e0xndec_t, e0xndeclst_t) ; /* ****** ****** */ extern p0arg_t p0arg_make_none (i0de_t) ; extern p0arg_t p0arg_make_some (i0de_t, s0exp_t) ; extern p0arglst_t p0arglst_nil (void) ; extern p0arglst_t p0arglst_cons (p0arg_t, p0arglst_t) ; // extern d0arg_t d0arg_var (i0de_t) ; extern d0arg_t d0arg_dyn (t0kn_t, p0arglst_t, t0kn_t) ; extern d0arg_t d0arg_dyn2 (t0kn_t, p0arglst_t, p0arglst_t, t0kn_t) ; extern d0arg_t d0arg_sta (t0kn_t, s0qualst_t, t0kn_t) ; extern d0arglst_t d0arglst_nil (void) ; extern d0arglst_t d0arglst_cons (d0arg_t, d0arglst_t) ; // extern m0acarg_t m0acarg_one (i0de_t) ; extern m0acarg_t m0acarg_lst (t0kn_t, i0delst_t, t0kn_t) ; extern m0acarglst_t m0acarglst_nil () ; extern m0acarglst_t m0acarglst_cons (m0acarg_t, m0acarglst_t) ; /* ****** ****** */ extern extnamopt_t extnamopt_none (void) ; extern extnamopt_t extnamopt_some (s0tring_t) ; extern d0cstdec_t d0cstdec_make (i0de_t, d0arglst_t, e0fftaglstopt_t, s0exp_t, extnamopt_t) ; extern d0cstdeclst_t d0cstdeclst_nil (void) ; extern d0cstdeclst_t d0cstdeclst_cons (d0cstdec_t, d0cstdeclst_t) ; /* ****** ****** */ extern p0at_t p0at_ann (p0at_t, s0exp_t) ; extern p0at_t p0at_apps (p0at_t, p0atlst_t) ; extern p0at_t p0at_as (i0de_t, p0at_t) ; extern p0at_t p0at_char (c0har_t) ; extern p0at_t p0at_exist (t0kn_t, s0arglst_t, t0kn_t) ; extern p0at_t p0at_float (f0loat_t); extern p0at_t p0at_free (t0kn_t, p0at_t); extern p0at_t p0at_ide (i0de_t) ; extern p0at_t p0at_int (i0nt_t) ; extern p0at_t p0at_list (t0kn_t, p0atlst_t, t0kn_t) ; extern p0at_t p0at_list2 (t0kn_t, p0atlst_t, p0atlst_t, t0kn_t) ; extern p0at_t p0at_lst (t0kn_t, p0atlst_t, t0kn_t) ; extern p0at_t p0at_qid (d0ynq_t, i0de_t) ; extern p0at_t p0at_opide (t0kn_t, i0de_t) ; extern p0at_t p0at_rec (int, t0kn_t, labp0atlst_t, t0kn_t) ; extern p0at_t p0at_ref (t0kn_t, i0de_t); extern p0at_t p0at_refas (t0kn_t, i0de_t, p0at_t); extern p0at_t p0at_svararg (t0kn_t, s0vararg_t, t0kn_t) ; extern p0at_t p0at_string (s0tring_t) ; extern p0at_t p0at_tup (int, t0kn_t, p0atlst_t, t0kn_t) ; extern p0at_t p0at_tup2 (int, t0kn_t, p0atlst_t, p0atlst_t, t0kn_t) ; // extern p0atlst_t p0atlst_nil (void) ; extern p0atlst_t p0atlst_cons (p0at_t, p0atlst_t) ; // extern labp0atlst_t labp0atlst_nil (void) ; extern labp0atlst_t labp0atlst_dot (void) ; extern labp0atlst_t labp0atlst_cons (l0ab_t, p0at_t, labp0atlst_t) ; // extern s0vararg_t s0vararg_one (void) ; extern s0vararg_t s0vararg_all (void) ; extern s0vararg_t s0vararg_seq (s0arglst_t) ; /* ****** ****** */ extern s0exparg_t s0exparg_one (void) ; extern s0exparg_t s0exparg_all (void) ; extern s0exparg_t s0exparg_seq (s0explst_t) ; extern f0arg_t f0arg_sta1 (t0kn_t, s0qualst_t, t0kn_t) ; extern f0arg_t f0arg_sta2 (t0kn_t, s0arglst_t, t0kn_t) ; extern f0arg_t f0arg_dyn (p0at_t) ; extern f0arg_t f0arg_met_none (t0kn_t) ; extern f0arg_t f0arg_met_some (t0kn_t, s0explst_t, t0kn_t) ; extern f0arglst_t f0arglst_nil (void) ; extern f0arglst_t f0arglst_cons (f0arg_t, f0arglst_t) ; extern s0elop_t s0elop_make (int, t0kn_t) ; extern witht0ype_t witht0ype_none (void) ; extern witht0ype_t witht0ype_prop (s0exp_t) ; extern witht0ype_t witht0ype_type (s0exp_t) ; extern witht0ype_t witht0ype_view (s0exp_t) ; extern witht0ype_t witht0ype_viewtype (s0exp_t) ; /* ****** ****** */ /* ** dynamic expressions */ extern d0exp_t d0exp_ann (d0exp_t, s0exp_t) ; // extern d0exp_t d0exp_apps (d0exp_t, d0explst_t) ; // extern d0exp_t d0exp_arrinit_none (t0kn_t, s0exp_t, d0explst_t /*elt*/, t0kn_t) ; extern d0exp_t d0exp_arrinit_some (t0kn_t, s0exp_t, d0exp_t /*asz*/, d0explst_t /*elt*/, t0kn_t) ; // extern d0exp_t d0exp_arrpsz (t0kn_t, s0exp_t, t0kn_t/*lparen*/, d0explst_t, t0kn_t/*rparen*/) ; // extern d0exp_t d0exp_arrsub (arrqi0de_t, d0arrind_t) ; // extern d0exp_t d0exp_char (t0kn_t) ; // extern d0exp_t d0exp_caseof (casehead_t, d0exp_t, t0kn_t, c0laulst_t) ; // extern d0exp_t d0exp_crypt (int, t0kn_t) ; // extern d0exp_t d0exp_decseq (t0kn_t, d0eclst_t, t0kn_t) ; // extern d0exp_t d0exp_delay (int/*lin*/, t0kn_t) ; // extern d0exp_t d0exp_dynload (t0kn_t) ; // // HX: [d0exp_effmask_*] are implemented in [ats_effect.dats] // extern d0exp_t d0exp_effmask_all (t0kn_t) ; extern d0exp_t d0exp_effmask_exn (t0kn_t) ; extern d0exp_t d0exp_effmask_ntm (t0kn_t) ; extern d0exp_t d0exp_effmask_ref (t0kn_t) ; // extern d0exp_t d0exp_exist (t0kn_t, s0exparg_t, t0kn_t, d0exp_t, t0kn_t) ; // extern d0exp_t d0exp_extval (t0kn_t, s0exp_t, s0tring_t, t0kn_t) ; // extern d0exp_t d0exp_fix (fixkind_t, i0de_t, f0arglst_t, s0expopt_t, e0fftaglstopt_t, d0exp_t) ; // extern d0exp_t d0exp_float (f0loat_t) ; extern d0exp_t d0exp_floatsp (f0loatsp_t) ; // extern d0exp_t d0exp_foldat (t0kn_t, d0explst_t) ; // extern d0exp_t d0exp_for_itp (loophead_t, initestpost_t, d0exp_t) ; // extern d0exp_t d0exp_freeat (t0kn_t, d0explst_t) ; // extern d0exp_t d0exp_ide (i0de_t) ; extern d0exp_t d0exp_idext (i0de_t) ; // extern d0exp_t d0exp_if_none (ifhead_t, d0exp_t, d0exp_t) ; extern d0exp_t d0exp_if_some (ifhead_t, d0exp_t, d0exp_t, d0exp_t) ; // extern d0exp_t d0exp_int (i0nt_t) ; extern d0exp_t d0exp_intsp (i0ntsp_t) ; // extern d0exp_t d0exp_lam (lamkind_t, f0arglst_t, s0expopt_t, e0fftaglstopt_t, d0exp_t) ; // extern d0exp_t d0exp_let_seq (t0kn_t, d0eclst_t, t0kn_t, d0explst_t, t0kn_t) ; // extern d0exp_t d0exp_list (t0kn_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_list2 (t0kn_t, d0explst_t, d0explst_t, t0kn_t) ; // extern d0exp_t d0exp_lst ( int, t0kn_t, s0expopt_t, t0kn_t/*lparen*/, d0explst_t, t0kn_t/*rparen*/ ) ; // end of [d0exp_lst] extern d0exp_t d0exp_lst_quote (t0kn_t, d0explst_t, t0kn_t) ; // extern d0exp_t d0exp_loopexn (int, t0kn_t) ; // extern d0exp_t d0exp_macsyn_cross (t0kn_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_macsyn_decode (t0kn_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_macsyn_encode_seq (t0kn_t, d0explst_t, t0kn_t) ; // extern d0exp_t d0exp_opide (t0kn_t, i0de_t) ; extern d0exp_t d0exp_ptrof (t0kn_t) ; extern d0exp_t d0exp_qid (d0ynq_t, i0de_t) ; extern d0exp_t d0exp_raise (t0kn_t, d0exp_t) ; extern d0exp_t d0exp_rec (int, t0kn_t, labd0explst_t, t0kn_t) ; extern d0exp_t d0exp_scaseof (casehead_t, s0exp_t, t0kn_t, sc0laulst_t) ; extern d0exp_t d0exp_sel_lab (t0kn_t, l0ab_t) ; extern d0exp_t d0exp_sel_ind (t0kn_t, d0arrind_t) ; extern d0exp_t d0exp_seq (t0kn_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_sexparg (t0kn_t, s0exparg_t, t0kn_t) ; extern d0exp_t d0exp_showtype (t0kn_t, d0exp_t) ; extern d0exp_t d0exp_sif (ifhead_t, s0exp_t, d0exp_t, d0exp_t) ; extern d0exp_t d0exp_string (s0tring_t) ; extern d0exp_t d0exp_tmpid (tmpqi0de_t, s0explst_t, t1mps0explstlst_t, t0kn_t) ; extern d0exp_t d0exp_trywith_seq (tryhead_t, d0explst_t, t0kn_t, c0laulst_t) ; extern d0exp_t d0exp_tup (int, t0kn_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_tup2 (int, t0kn_t, d0explst_t, d0explst_t, t0kn_t) ; extern d0exp_t d0exp_viewat (t0kn_t) ; extern d0exp_t d0exp_where (d0exp_t, d0eclst_t, t0kn_t) ; extern d0exp_t d0exp_while (loophead_t, d0exp_t, d0exp_t) ; // extern d0exp_t d0exp_FILENAME (t0kn_t) ; // a special string constant extern d0exp_t d0exp_LOCATION (t0kn_t) ; // a special string constant // extern d0explst_t d0explst_nil (void) ; extern d0explst_t d0explst_cons (d0exp_t, d0explst_t) ; extern d0explst_t d0explst_sing (d0exp_t) ; // extern d0expopt_t d0expopt_none (void) ; extern d0expopt_t d0expopt_some (d0exp_t) ; // extern labd0explst_t labd0explst_nil (void) ; extern labd0explst_t labd0explst_cons (l0ab_t, d0exp_t, labd0explst_t) ; // extern d0arrind_t d0arrind_make_sing (d0explst_t, t0kn_t) ; extern d0arrind_t d0arrind_make_cons (d0explst_t, d0arrind_t) ; /* ****** ****** */ extern ifhead_t ifhead_make (t0kn_t, i0nvresstate_t) ; extern casehead_t casehead_make (int, t0kn_t, i0nvresstate_t) ; extern loophead_t loophead_make_none (t0kn_t) ; extern loophead_t loophead_make_some (t0kn_t, loopi0nv_t, t0kn_t) ; extern tryhead_t tryhead_make (t0kn_t) ; /* ****** ****** */ /* ** pattern matching */ extern m0atch_t m0atch_make_none (d0exp_t) ; extern m0atch_t m0atch_make_some (d0exp_t, p0at_t) ; extern m0atchlst_t m0atchlst_nil (void) ; extern m0atchlst_t m0atchlst_cons (m0atch_t, m0atchlst_t) ; extern guap0at_t guap0at_make_none (p0at_t) ; extern guap0at_t guap0at_make_some (p0at_t, d0exp_t) ; extern c0lau_t c0lau_make (guap0at_t, int, int, d0exp_t) ; extern c0laulst_t c0laulst_nil (void) ; extern c0laulst_t c0laulst_cons (c0lau_t, c0laulst_t) ; extern sc0lau_t sc0lau_make (sp0at_t, d0exp_t) ; extern sc0laulst_t sc0laulst_nil (void) ; extern sc0laulst_t sc0laulst_cons (sc0lau_t, sc0laulst_t) ; /* ****** ****** */ extern i0nvarg_t i0nvarg_make_none (i0de_t) ; extern i0nvarg_t i0nvarg_make_some (i0de_t, s0exp_t) ; extern i0nvarglst_t i0nvarglst_nil (void) ; extern i0nvarglst_t i0nvarglst_cons (i0nvarg_t, i0nvarglst_t) ; extern i0nvresstate_t i0nvresstate_none (void) ; extern i0nvresstate_t i0nvresstate_some (s0qualstopt_t, i0nvarglst_t) ; extern loopi0nv_t loopi0nv_make (s0qualstopt_t, s0explstopt_t, i0nvarglst_t, i0nvresstate_t) ; extern initestpost_t initestpost_make (t0kn_t, d0explst_t, t0kn_t, d0explst_t, t0kn_t, d0explst_t, t0kn_t) ; // end of [extern] /* ****** ****** */ extern v0aldec_t v0aldec_make (p0at_t, d0exp_t, witht0ype_t) ; extern v0aldeclst_t v0aldeclst_nil (void) ; extern v0aldeclst_t v0aldeclst_cons (v0aldec_t, v0aldeclst_t) ; extern f0undec_t f0undec_make_none (i0de_t, f0arglst_t, d0exp_t, witht0ype_t) ; extern f0undec_t f0undec_make_some (i0de_t, f0arglst_t, e0fftaglstopt_t, s0exp_t, d0exp_t, witht0ype_t) ; extern f0undeclst_t f0undeclst_nil (void) ; extern f0undeclst_t f0undeclst_cons (f0undec_t, f0undeclst_t) ; extern v0arwth_t v0arwth_none () ; extern v0arwth_t v0arwth_some (i0de_t) ; extern v0ardec_t v0ardec_make_some_none (int /*stadyn*/, i0de_t, v0arwth_t, s0exp_t) ; extern v0ardec_t v0ardec_make_none_some (int /*stadyn*/, i0de_t, v0arwth_t, d0exp_t) ; extern v0ardec_t v0ardec_make_some_some (int /*stadyn*/, i0de_t, s0exp_t, v0arwth_t, d0exp_t) ; extern v0ardeclst_t v0ardeclst_nil (void) ; extern v0ardeclst_t v0ardeclst_cons (v0ardec_t, v0ardeclst_t) ; /* ****** ****** */ extern m0acdef_t m0acdef_make (i0de_t, m0acarglst_t, d0exp_t) ; extern m0acdeflst_t m0acdeflst_nil (void) ; extern m0acdeflst_t m0acdeflst_cons (m0acdef_t, m0acdeflst_t) ; /* ****** ****** */ extern i0mpdec_t i0mpdec_make (impqi0de_t, f0arglst_t, s0expopt_t, d0exp_t) ; // end of [i0mpdec_make] /* ****** ****** */ /* ** static and dynamic declarations */ extern d0ec_t d0ec_infix (t0kn_t, p0rec_t, int, i0delst_t) ; extern d0ec_t d0ec_prefix (t0kn_t, p0rec_t, i0delst_t) ; extern d0ec_t d0ec_postfix (t0kn_t, p0rec_t, i0delst_t) ; extern d0ec_t d0ec_nonfix (t0kn_t, i0delst_t) ; extern d0ec_t d0ec_symintr (t0kn_t, i0delst_t) ; extern d0ec_t d0ec_include (int/*0:sta/1:dyn*/, s0tring_t) ; extern d0ec_t d0ec_e0xpundef (i0de_t) ; extern d0ec_t d0ec_e0xpdef (i0de_t, e0xpopt_t) ; extern d0ec_t d0ec_e0xpact_assert (e0xp_t) ; extern d0ec_t d0ec_e0xpact_error (e0xp_t) ; extern d0ec_t d0ec_e0xpact_print (e0xp_t) ; extern d0ec_t d0ec_srtdefs (s0rtdef_t, s0rtdeflst_t) ; extern d0ec_t d0ec_datsrts (int/*para*/, d0atsrtdec_t, d0atsrtdeclst_t) ; extern d0ec_t d0ec_stacons (abskind_t, s0tacon_t, s0taconlst_t) ; extern d0ec_t d0ec_stacsts (s0tacst_t, s0tacstlst_t) ; extern d0ec_t d0ec_stavars (s0tavar_t, s0tavarlst_t) ; extern d0ec_t d0ec_sexpdefs (stadefkind_t, s0expdef_t, s0expdeflst_t) ; extern d0ec_t d0ec_propdefs (t0kn_t, s0expdef_t, s0expdeflst_t) ; extern d0ec_t d0ec_typedefs (t0kn_t, s0expdef_t, s0expdeflst_t) ; extern d0ec_t d0ec_viewdefs (t0kn_t, s0expdef_t, s0expdeflst_t) ; extern d0ec_t d0ec_viewtypedefs (t0kn_t, s0expdef_t, s0expdeflst_t) ; extern d0ec_t d0ec_saspdec (s0aspdec_t) ; extern d0ec_t d0ec_dcstdecs (dcstkind_t, s0qualstlst_t, d0cstdec_t, d0cstdeclst_t) ; extern d0ec_t d0ec_datdecs (datakind_t, d0atdec_t, d0atdeclst_t, s0explstopt_t) ; extern d0ec_t d0ec_exndecs (t0kn_t, e0xndec_t, e0xndeclst_t) ; // extern d0ec_t d0ec_classdec_none (t0kn_t, i0de_t) ; extern d0ec_t d0ec_classdec_some (t0kn_t, i0de_t, s0exp_t) ; // extern d0ec_t d0ec_overload (t0kn_t, i0de_t, dqi0de_t) ; extern d0ec_t d0ec_overload_lrbrackets (t0kn_t, t0kn_t, t0kn_t, dqi0de_t) ; // extern d0ec_t d0ec_dynload (s0tring_t) ; extern d0ec_t d0ec_staload_none (s0tring_t) ; extern d0ec_t d0ec_staload_some (i0de_t, s0tring_t) ; extern d0ec_t d0ec_extype (s0tring_t, s0exp_t) ; extern d0ec_t d0ec_extval (s0tring_t, d0exp_t) ; extern d0ec_t d0ec_extcode_dyn (e0xtcode_t) ; extern d0ec_t d0ec_extcode_sta (e0xtcode_t) ; extern d0ec_t d0ec_valdecs (valkind_t, v0aldec_t, v0aldeclst_t) ; extern d0ec_t d0ec_valdecs_par (v0aldec_t, v0aldeclst_t) ; extern d0ec_t d0ec_valdecs_rec (v0aldec_t, v0aldeclst_t) ; extern d0ec_t d0ec_fundecs (funkind_t, s0qualstlst_t, f0undec_t, f0undeclst_t) ; extern d0ec_t d0ec_vardecs (v0ardec_t, v0ardeclst_t) ; extern d0ec_t d0ec_macdefs (int, m0acdef_t, m0acdeflst_t) ; extern d0ec_t d0ec_impdec (t0kn_t, s0arglstlst_t, i0mpdec_t) ; extern d0ec_t d0ec_local (t0kn_t, d0eclst_t, d0eclst_t, t0kn_t) ; extern d0ec_t d0ec_guadec (srpifkindtok_t, guad0ec_t) ; extern guad0ec_t guad0ec_one (e0xp_t, d0eclst_t, t0kn_t) ; extern guad0ec_t guad0ec_two (e0xp_t, d0eclst_t, d0eclst_t, t0kn_t) ; extern guad0ec_t guad0ec_cons (e0xp_t, d0eclst_t, srpifkindtok_t, guad0ec_t) ; extern d0eclst_t d0eclst_nil (void) ; extern d0eclst_t d0eclst_cons (d0ec_t, d0eclst_t) ; extern d0ecllst_t d0ecllst_nil (void) ; extern d0ecllst_t d0ecllst_cons (d0ecllst_t, d0ec_t) ; extern d0eclst_t d0ecllst_reverse (d0ecllst_t) ; /* ****** ****** */ /* ** HX: implemented in [ats_parser.dats] */ extern yyres_t atsopt_yyres_i0de (i0de_t) ; extern yyres_t atsopt_yyres_s0exp (s0exp_t) ; extern yyres_t atsopt_yyres_d0exp (d0exp_t) ; extern yyres_t atsopt_yyres_d0eclst (d0eclst_t) ; /* ****** ****** */ typedef union { t0kn_t t0kn ; c0har_t c0har ; e0xtcode_t e0xtcode ; f0loat_t f0loat ; f0loatsp_t f0loatsp ; i0nt_t i0nt ; i0ntsp_t i0ntsp ; s0tring_t s0tring ; i0de_t i0de ; i0delst_t i0delst ; l0ab_t l0ab ; p0rec_t p0rec ; abskind_t abskind ; dcstkind_t dcstkind ; datakind_t datakind ; stadefkind_t stadefkind ; valkind_t valkind ; funkind_t funkind ; lamkind_t lamkind ; fixkind_t fixkind ; srpifkindtok_t srpifkindtok ; e0xp_t e0xp ; e0xplst_t e0xplst ; e0xpopt_t e0xpopt ; e0fftag_t e0fftag ; e0fftaglst_t e0fftaglst ; e0fftaglstopt_t e0fftaglstopt ; s0rt_t s0rt ; s0rtq_t s0rtq ; s0rtlst_t s0rtlst ; s0rtopt_t s0rtopt ; s0rtpol_t s0rtpol ; d0atsrtcon_t d0atsrtcon ; d0atsrtconlst_t d0atsrtconlst ; d0atsrtdec_t d0atsrtdec ; d0atsrtdeclst_t d0atsrtdeclst ; s0taq_t s0taq ; d0ynq_t d0ynq ; sqi0de_t sqi0de ; dqi0de_t dqi0de ; arrqi0de_t arrqi0de ; tmpqi0de_t tmpqi0de ; s0arg_t s0arg ; s0arglst_t s0arglst ; s0arglstlst_t s0arglstlst ; sp0at_t sp0at ; s0exp_t s0exp ; s0expext_t s0expext ; s0explst_t s0explst ; s0expopt_t s0expopt ; s0explstlst_t s0explstlst ; s0explstopt_t s0explstopt ; labs0explst_t labs0explst ; s0arrind_t s0arrind ; t1mps0explstlst_t t1mps0explstlst ; s0qua_t s0qua ; s0qualst_t s0qualst ; s0qualstlst_t s0qualstlst ; s0qualstopt_t s0qualstopt ; s0rtext_t s0rtext ; impqi0de_t impqi0de ; s0rtdef_t s0rtdef ; s0rtdeflst_t s0rtdeflst ; d0atarg_t d0atarg ; d0atarglst_t d0atarglst ; s0tacon_t s0tacon ; s0taconlst_t s0taconlst ; s0tacst_t s0tacst ; s0tacstlst_t s0tacstlst ; s0tavar_t s0tavar ; s0tavarlst_t s0tavarlst ; s0expdef_t s0expdef ; s0expdeflst_t s0expdeflst ; s0aspdec_t s0aspdec ; d0atcon_t d0atcon ; d0atconlst_t d0atconlst ; d0atdec_t d0atdec ; d0atdeclst_t d0atdeclst ; e0xndec_t e0xndec ; e0xndeclst_t e0xndeclst ; p0arg_t p0arg ; p0arglst_t p0arglst ; d0arg_t d0arg ; d0arglst_t d0arglst ; extnamopt_t extnamopt ; d0cstdec_t d0cstdec ; d0cstdeclst_t d0cstdeclst ; s0vararg_t s0vararg ; s0exparg_t s0exparg ; s0elop_t s0elop ; witht0ype_t witht0ype ; p0at_t p0at ; p0atlst_t p0atlst ; labp0atlst_t labp0atlst ; f0arg_t f0arg ; f0arglst_t f0arglst ; d0exp_t d0exp ; d0explst_t d0explst ; d0expopt_t d0expopt ; labd0explst_t labd0explst ; d0arrind_t d0arrind ; ifhead_t ifhead ; casehead_t casehead ; loophead_t loophead ; tryhead_t tryhead ; m0atch_t m0atch ; m0atchlst_t m0atchlst ; guap0at_t guap0at ; c0lau_t c0lau ; c0laulst_t c0laulst ; sc0lau_t sc0lau ; sc0laulst_t sc0laulst ; i0nvarg_t i0nvarg ; i0nvarglst_t i0nvarglst ; i0nvresstate_t i0nvresstate ; loopi0nv_t loopi0nv ; initestpost_t initestpost ; m0acarg_t m0acarg ; m0acarglst_t m0acarglst ; m0acdef_t m0acdef ; m0acdeflst_t m0acdeflst ; v0aldec_t v0aldec ; v0aldeclst_t v0aldeclst ; f0undec_t f0undec ; f0undeclst_t f0undeclst ; v0arwth_t v0arwth ; v0ardec_t v0ardec ; v0ardeclst_t v0ardeclst ; i0mpdec_t i0mpdec ; d0ec_t d0ec ; d0eclst_t d0eclst ; } YYSTYPE_union ; #define YYSTYPE YYSTYPE_union /* Line 268 of yacc.c */ #line 1113 "ats_grammar_yats.c" /* Enabling traces. */ #ifndef YYDEBUG # define YYDEBUG 0 #endif /* Enabling verbose error messages. */ #ifdef YYERROR_VERBOSE # undef YYERROR_VERBOSE # define YYERROR_VERBOSE 1 #else # define YYERROR_VERBOSE 0 #endif /* Enabling the token table. */ #ifndef YYTOKEN_TABLE # define YYTOKEN_TABLE 0 #endif /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE /* Put the tokens into the symbol table, so that GDB and other debuggers know about them. */ enum yytokentype { YYBEG_i0de = 258, YYBEG_s0rtid = 259, YYBEG_si0de = 260, YYBEG_di0de = 261, YYBEG_s0exp = 262, YYBEG_d0exp = 263, YYBEG_d0ecseq_sta = 264, YYBEG_d0ecseq_dyn = 265, TOKEN_eof = 266, LITERAL_char = 267, LITERAL_extcode = 268, LITERAL_float = 269, LITERAL_floatsp = 270, LITERAL_int = 271, LITERAL_intsp = 272, LITERAL_string = 273, IDENTIFIER_alp = 274, IDENTIFIER_sym = 275, IDENTIFIER_arr = 276, IDENTIFIER_tmp = 277, IDENTIFIER_ext = 278, IDENTIFIER_dlr = 279, IDENTIFIER_srp = 280, ABSPROP = 281, ABSTYPE = 282, ABST0YPE = 283, ABSVIEW = 284, ABSVIEWTYPE = 285, ABSVIEWT0YPE = 286, AND = 287, AS = 288, ASSUME = 289, ATLAM = 290, ATLLAM = 291, ATFIX = 292, BEGIN = 293, BREAK = 294, CASE = 295, CASEMINUS = 296, CASEPLUS = 297, CASTFN = 298, CLASSDEC = 299, CONTINUE = 300, DATASORT = 301, DATAPARASORT = 302, DATAPROP = 303, DATATYPE = 304, DATAVIEW = 305, DATAVIEWTYPE = 306, DO = 307, DYN = 308, DYNLOAD = 309, ELSE = 310, END = 311, EXCEPTION = 312, EXTERN = 313, FIX = 314, FN = 315, FNSTAR = 316, FOR = 317, FORSTAR = 318, FUN = 319, IF = 320, IMPLEMENT = 321, IN = 322, INFIX = 323, INFIXL = 324, INFIXR = 325, LAM = 326, LET = 327, LLAM = 328, LOCAL = 329, MACDEF = 330, MACRODEF = 331, NONFIX = 332, OF = 333, OP = 334, OVERLOAD = 335, PAR = 336, POSTFIX = 337, PRAXI = 338, PREFIX = 339, PRFN = 340, PRFUN = 341, PROPDEF = 342, PROPMINUS = 343, PROPPLUS = 344, PRVAL = 345, REC = 346, R0EAD = 347, SCASE = 348, SIF = 349, SORTDEF = 350, STACST = 351, STADEF = 352, STAIF = 353, STALOAD = 354, STAVAR = 355, SYMELIM = 356, SYMINTR = 357, THEN = 358, TRY = 359, TYPEDEF = 360, TYPEMINUS = 361, TYPEPLUS = 362, T0YPE = 363, T0YPEMINUS = 364, T0YPEPLUS = 365, VAL = 366, VALMINUS = 367, VALPLUS = 368, VAR = 369, VIEWDEF = 370, VIEWMINUS = 371, VIEWPLUS = 372, VIEWTYPEDEF = 373, VIEWTYPEMINUS = 374, VIEWTYPEPLUS = 375, VIEWT0YPE = 376, VIEWT0YPEMINUS = 377, VIEWT0YPEPLUS = 378, WHEN = 379, WHERE = 380, WHILE = 381, WHILESTAR = 382, WITH = 383, WITHPROP = 384, WITHTYPE = 385, WITHVIEW = 386, WITHVIEWTYPE = 387, AMPERSAND = 388, BACKQUOTE = 389, BACKSLASH = 390, BANG = 391, BAR = 392, COMMA = 393, COLON = 394, SEMICOLON = 395, DOT = 396, EQ = 397, LT = 398, GT = 399, DOLLAR = 400, HASH = 401, TILDE = 402, DOTDOT = 403, DOTDOTDOT = 404, EQLT = 405, EQGT = 406, EQLTGT = 407, EQGTGT = 408, EQSLASHEQGT = 409, EQSLASHEQGTGT = 410, GTLT = 411, DOTLT = 412, GTDOT = 413, DOTLTGTDOT = 414, MINUSLT = 415, MINUSGT = 416, MINUSLTGT = 417, COLONLT = 418, COLONLTGT = 419, BACKQUOTELPAREN = 420, COMMALPAREN = 421, PERCENTLPAREN = 422, DLRARRPSZ = 423, DLRLST_T = 424, DLRLST_VT = 425, DLRREC_T = 426, DLRREC_VT = 427, DLRTUP_T = 428, DLRTUP_VT = 429, DLRDELAY = 430, DLRLDELAY = 431, DLRDYNLOAD = 432, DLREFFMASK_ALL = 433, DLREFFMASK_EXN = 434, DLREFFMASK_NTM = 435, DLREFFMASK_REF = 436, DLRDECRYPT = 437, DLRENCRYPT = 438, DLREXTERN = 439, DLREXTVAL = 440, DLREXTYPE = 441, DLREXTYPE_STRUCT = 442, DLRFOLD = 443, DLRUNFOLD = 444, DLRRAISE = 445, DLRSHOWTYPE = 446, SRPFILENAME = 447, SRPLOCATION = 448, SRPCHARCOUNT = 449, SRPLINECOUNT = 450, SRPASSERT = 451, SRPDEFINE = 452, SRPELSE = 453, SRPELIF = 454, SRPELIFDEF = 455, SRPELIFNDEF = 456, SRPENDIF = 457, SRPERROR = 458, SRPIF = 459, SRPIFDEF = 460, SRPIFNDEF = 461, SRPINCLUDE = 462, SRPPRINT = 463, SRPTHEN = 464, SRPUNDEF = 465, FOLDAT = 466, FREEAT = 467, VIEWAT = 468, LPAREN = 469, RPAREN = 470, LBRACKET = 471, RBRACKET = 472, LBRACE = 473, RBRACE = 474, ATLPAREN = 475, ATLBRACKET = 476, ATLBRACE = 477, QUOTELPAREN = 478, QUOTELBRACKET = 479, QUOTELBRACE = 480, HASHLPAREN = 481, HASHLBRACKET = 482, HASHLBRACE = 483, PATAS = 484, PATFREE = 485, SEXPLAM = 486, DEXPLAM = 487, DEXPFIX = 488, CLAUS = 489, DEXPCASE = 490, DEXPIF = 491, DEXPRAISE = 492, DEXPSHOWTYPE = 493, DEXPTRY = 494, DEXPFOR = 495, DEXPWHILE = 496, BARCLAUSSEQNONE = 497, TMPSEXP = 498, TMPSARG = 499, SARRIND = 500, SEXPDARGSEQEMPTY = 501 }; #endif #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif /* Copy the second part of user declarations. */ /* Line 343 of yacc.c */ #line 1400 "ats_grammar_yats.c" #ifdef short # undef short #endif #ifdef YYTYPE_UINT8 typedef YYTYPE_UINT8 yytype_uint8; #else typedef unsigned char yytype_uint8; #endif #ifdef YYTYPE_INT8 typedef YYTYPE_INT8 yytype_int8; #elif (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) typedef signed char yytype_int8; #else typedef short int yytype_int8; #endif #ifdef YYTYPE_UINT16 typedef YYTYPE_UINT16 yytype_uint16; #else typedef unsigned short int yytype_uint16; #endif #ifdef YYTYPE_INT16 typedef YYTYPE_INT16 yytype_int16; #else typedef short int yytype_int16; #endif #ifndef YYSIZE_T # ifdef __SIZE_TYPE__ # define YYSIZE_T __SIZE_TYPE__ # elif defined size_t # define YYSIZE_T size_t # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include /* INFRINGES ON USER NAME SPACE */ # define YYSIZE_T size_t # else # define YYSIZE_T unsigned int # endif #endif #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ # if defined YYENABLE_NLS && YYENABLE_NLS # if ENABLE_NLS # include /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) # endif # endif # ifndef YY_ # define YY_(msgid) msgid # endif #endif /* Suppress unused-variable warnings by "using" E. */ #if ! defined lint || defined __GNUC__ # define YYUSE(e) ((void) (e)) #else # define YYUSE(e) /* empty */ #endif /* Identity function, used to suppress warnings about constant conditions. */ #ifndef lint # define YYID(n) (n) #else #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static int YYID (int yyi) #else static int YYID (yyi) int yyi; #endif { return yyi; } #endif #if ! defined yyoverflow || YYERROR_VERBOSE /* The parser invokes alloca or malloc; define the necessary symbols. */ # ifdef YYSTACK_USE_ALLOCA # if YYSTACK_USE_ALLOCA # ifdef __GNUC__ # define YYSTACK_ALLOC __builtin_alloca # elif defined __BUILTIN_VA_ARG_INCR # include /* INFRINGES ON USER NAME SPACE */ # elif defined _AIX # define YYSTACK_ALLOC __alloca # elif defined _MSC_VER # include /* INFRINGES ON USER NAME SPACE */ # define alloca _alloca # else # define YYSTACK_ALLOC alloca # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include /* INFRINGES ON USER NAME SPACE */ # ifndef EXIT_SUCCESS # define EXIT_SUCCESS 0 # endif # endif # endif # endif # endif # ifdef YYSTACK_ALLOC /* Pacify GCC's `empty if-body' warning. */ # define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) # ifndef YYSTACK_ALLOC_MAXIMUM /* The OS might guarantee only one guard page at the bottom of the stack, and a page size can be as small as 4096 bytes. So we cannot safely invoke alloca (N) if N exceeds 4096. Use a slightly smaller number to allow for a few compiler-allocated temporary stack slots. */ # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ # endif # else # define YYSTACK_ALLOC YYMALLOC # define YYSTACK_FREE YYFREE # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif # if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ # ifndef EXIT_SUCCESS # define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc # if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free # if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif # endif # endif #endif /* ! defined yyoverflow || YYERROR_VERBOSE */ #if (! defined yyoverflow \ && (! defined __cplusplus \ || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) /* A type that is properly aligned for any stack member. */ union yyalloc { yytype_int16 yyss_alloc; YYSTYPE yyvs_alloc; }; /* The size of the maximum gap between one aligned stack and the next. */ # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) /* The size of an array large to enough to hold all stacks, each with N elements. */ # define YYSTACK_BYTES(N) \ ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) # define YYCOPY_NEEDED 1 /* Relocate STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of elements in the stack, and YYPTR gives the new location of the stack. Advance YYPTR to a properly aligned location for the next stack. */ # define YYSTACK_RELOCATE(Stack_alloc, Stack) \ do \ { \ YYSIZE_T yynewbytes; \ YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ Stack = &yyptr->Stack_alloc; \ yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ yyptr += yynewbytes / sizeof (*yyptr); \ } \ while (YYID (0)) #endif #if defined YYCOPY_NEEDED && YYCOPY_NEEDED /* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */ # ifndef YYCOPY # if defined __GNUC__ && 1 < __GNUC__ # define YYCOPY(To, From, Count) \ __builtin_memcpy (To, From, (Count) * sizeof (*(From))) # else # define YYCOPY(To, From, Count) \ do \ { \ YYSIZE_T yyi; \ for (yyi = 0; yyi < (Count); yyi++) \ (To)[yyi] = (From)[yyi]; \ } \ while (YYID (0)) # endif # endif #endif /* !YYCOPY_NEEDED */ /* YYFINAL -- State number of the termination state. */ #define YYFINAL 179 /* YYLAST -- Last index in YYTABLE. */ #define YYLAST 3051 /* YYNTOKENS -- Number of terminals. */ #define YYNTOKENS 247 /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 205 /* YYNRULES -- Number of rules. */ #define YYNRULES 652 /* YYNRULES -- Number of states. */ #define YYNSTATES 1254 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 #define YYMAXUTOK 501 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ static const yytype_uint8 yytranslate[] = { 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, 246 }; #if YYDEBUG /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in YYRHS. */ static const yytype_uint16 yyprhs[] = { 0, 0, 3, 7, 11, 15, 19, 23, 27, 31, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, 99, 101, 103, 105, 107, 109, 111, 113, 115, 117, 119, 121, 122, 124, 126, 128, 130, 132, 134, 136, 138, 140, 142, 144, 146, 148, 150, 151, 154, 156, 158, 160, 162, 164, 168, 170, 171, 173, 177, 183, 186, 188, 190, 192, 194, 196, 198, 200, 202, 206, 210, 211, 214, 215, 219, 220, 222, 224, 227, 230, 232, 234, 236, 237, 240, 241, 245, 247, 249, 253, 256, 258, 261, 265, 267, 269, 271, 273, 275, 277, 279, 281, 284, 288, 292, 293, 296, 297, 301, 303, 305, 307, 309, 311, 313, 315, 317, 319, 321, 323, 325, 327, 329, 333, 335, 338, 339, 343, 347, 348, 352, 355, 358, 362, 365, 368, 372, 376, 381, 383, 385, 387, 389, 391, 393, 395, 397, 399, 401, 403, 406, 407, 411, 413, 415, 417, 419, 421, 423, 425, 427, 429, 431, 434, 436, 438, 440, 443, 445, 447, 450, 452, 454, 457, 458, 461, 464, 465, 468, 469, 473, 474, 477, 482, 483, 486, 487, 491, 492, 497, 502, 504, 506, 510, 516, 518, 520, 522, 524, 527, 530, 534, 540, 544, 548, 553, 558, 564, 570, 577, 584, 588, 592, 597, 602, 609, 615, 619, 621, 625, 629, 633, 636, 638, 641, 644, 645, 649, 653, 656, 661, 663, 668, 669, 672, 673, 677, 681, 683, 692, 693, 695, 696, 700, 704, 705, 709, 712, 713, 718, 719, 725, 727, 730, 732, 733, 736, 737, 741, 742, 746, 748, 753, 757, 758, 762, 764, 768, 769, 772, 773, 777, 779, 784, 788, 795, 796, 800, 804, 811, 812, 816, 820, 821, 825, 831, 832, 836, 842, 843, 848, 849, 853, 854, 857, 862, 864, 867, 868, 872, 876, 883, 884, 888, 889, 893, 897, 898, 902, 904, 908, 909, 912, 913, 917, 919, 923, 929, 933, 934, 937, 938, 941, 947, 948, 952, 954, 956, 958, 960, 962, 964, 966, 968, 969, 972, 975, 978, 981, 984, 988, 992, 997, 1000, 1002, 1004, 1006, 1008, 1010, 1013, 1016, 1019, 1023, 1029, 1033, 1037, 1041, 1047, 1053, 1057, 1061, 1065, 1067, 1071, 1072, 1075, 1076, 1079, 1080, 1084, 1086, 1091, 1092, 1095, 1101, 1105, 1107, 1111, 1113, 1114, 1117, 1121, 1123, 1124, 1127, 1130, 1134, 1139, 1146, 1153, 1158, 1163, 1169, 1176, 1180, 1184, 1187, 1190, 1195, 1201, 1203, 1205, 1207, 1209, 1211, 1213, 1215, 1217, 1219, 1222, 1225, 1227, 1229, 1231, 1233, 1236, 1239, 1241, 1243, 1245, 1247, 1249, 1251, 1253, 1255, 1257, 1259, 1266, 1276, 1282, 1285, 1288, 1292, 1297, 1303, 1307, 1313, 1319, 1325, 1329, 1333, 1337, 1341, 1345, 1350, 1355, 1361, 1367, 1371, 1375, 1380, 1385, 1392, 1396, 1400, 1404, 1410, 1414, 1418, 1419, 1422, 1424, 1426, 1427, 1430, 1433, 1438, 1439, 1442, 1444, 1446, 1450, 1451, 1454, 1457, 1460, 1463, 1466, 1469, 1472, 1474, 1478, 1482, 1484, 1485, 1488, 1489, 1493, 1494, 1496, 1500, 1504, 1505, 1510, 1511, 1517, 1519, 1523, 1526, 1527, 1531, 1533, 1537, 1541, 1545, 1549, 1553, 1555, 1558, 1559, 1563, 1567, 1569, 1572, 1573, 1577, 1578, 1582, 1583, 1587, 1589, 1592, 1596, 1597, 1600, 1601, 1605, 1609, 1610, 1614, 1615, 1621, 1626, 1634, 1636, 1637, 1640, 1641, 1645, 1647, 1651, 1652, 1655, 1660, 1661, 1665, 1670, 1671, 1675, 1681, 1689, 1690, 1694, 1695, 1698, 1703, 1709, 1714, 1721, 1722, 1726, 1732, 1736, 1740, 1744, 1748, 1752, 1755, 1758, 1761, 1765, 1768, 1771, 1774, 1778, 1782, 1786, 1790, 1794, 1798, 1802, 1805, 1810, 1814, 1817, 1822, 1827, 1833, 1837, 1842, 1846, 1851, 1854, 1859, 1863, 1864, 1867, 1868, 1871, 1873, 1878, 1880, 1883, 1886, 1892, 1897, 1904, 1910, 1912, 1913, 1917, 1919, 1925, 1931, 1937, 1941, 1946, 1951, 1956, 1960, 1964, 1970, 1972, 1975, 1978, 1981, 1986, 1993, 1999, 2001, 2002 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int16 yyrhs[] = { 248, 0, -1, 9, 446, 11, -1, 10, 450, 11, -1, 3, 260, 11, -1, 4, 279, 11, -1, 5, 291, 11, -1, 6, 294, 11, -1, 7, 311, 11, -1, 8, 382, 11, -1, 26, -1, 27, -1, 28, -1, 29, -1, 30, -1, 31, -1, 64, -1, 111, -1, 43, -1, 83, -1, 86, -1, 90, -1, 48, -1, 49, -1, 50, -1, 51, -1, 97, -1, 87, -1, 105, -1, 115, -1, 118, -1, 111, -1, 112, -1, 113, -1, 90, -1, 60, -1, 61, -1, 64, -1, 43, -1, 85, -1, 86, -1, 71, -1, 35, -1, 73, -1, 36, -1, 59, -1, 37, -1, 204, -1, 205, -1, 206, -1, 199, -1, 200, -1, 201, -1, -1, 209, -1, 19, -1, 20, -1, 133, -1, 135, -1, 136, -1, 142, -1, 144, -1, 156, -1, 143, -1, 161, -1, 162, -1, 147, -1, 24, -1, -1, 260, 262, -1, 23, -1, 52, -1, 126, -1, 260, -1, 16, -1, 214, 264, 215, -1, 19, -1, -1, 16, -1, 214, 260, 215, -1, 214, 260, 20, 16, 215, -1, 267, 268, -1, 268, -1, 12, -1, 14, -1, 16, -1, 18, -1, 192, -1, 193, -1, 260, -1, 214, 269, 215, -1, 167, 267, 215, -1, -1, 267, 270, -1, -1, 138, 267, 270, -1, -1, 267, -1, 19, -1, 136, 272, -1, 147, 272, -1, 272, -1, 64, -1, 16, -1, -1, 273, 275, -1, -1, 138, 273, 275, -1, 139, -1, 164, -1, 163, 274, 144, -1, 277, 280, -1, 280, -1, 261, 141, -1, 145, 18, 141, -1, 19, -1, 20, -1, 108, -1, 121, -1, 135, -1, 161, -1, 162, -1, 279, -1, 278, 279, -1, 214, 281, 215, -1, 220, 281, 215, -1, -1, 277, 282, -1, -1, 138, 277, 282, -1, 277, -1, 88, -1, 89, -1, 106, -1, 107, -1, 109, -1, 110, -1, 116, -1, 117, -1, 119, -1, 120, -1, 122, -1, 123, -1, 260, -1, 260, 78, 277, -1, 286, -1, 284, 286, -1, -1, 137, 284, 286, -1, 260, 142, 285, -1, -1, 32, 287, 288, -1, 261, 141, -1, 261, 139, -1, 145, 18, 141, -1, 261, 141, -1, 261, 139, -1, 261, 261, 139, -1, 145, 18, 141, -1, 145, 18, 261, 139, -1, 19, -1, 20, -1, 92, -1, 133, -1, 135, -1, 136, -1, 144, -1, 143, -1, 161, -1, 147, -1, 291, -1, 289, 291, -1, -1, 138, 291, 293, -1, 19, -1, 20, -1, 135, -1, 136, -1, 142, -1, 144, -1, 156, -1, 143, -1, 147, -1, 294, -1, 290, 294, -1, 19, -1, 20, -1, 294, -1, 79, 294, -1, 21, -1, 298, -1, 290, 298, -1, 22, -1, 300, -1, 290, 300, -1, -1, 139, 277, -1, 291, 302, -1, -1, 303, 305, -1, -1, 138, 303, 305, -1, -1, 291, 306, -1, 214, 304, 215, 306, -1, -1, 303, 308, -1, -1, 138, 303, 308, -1, -1, 218, 307, 219, 309, -1, 292, 214, 304, 215, -1, 313, -1, 314, -1, 311, 139, 277, -1, 71, 306, 302, 151, 311, -1, 12, -1, 16, -1, 17, -1, 291, -1, 79, 291, -1, 289, 291, -1, 214, 321, 215, -1, 214, 321, 137, 321, 215, -1, 220, 321, 215, -1, 223, 321, 215, -1, 173, 214, 321, 215, -1, 174, 214, 321, 215, -1, 220, 321, 137, 321, 215, -1, 223, 321, 137, 321, 215, -1, 173, 214, 321, 137, 321, 215, -1, 174, 214, 321, 137, 321, 215, -1, 222, 325, 219, -1, 225, 325, 219, -1, 171, 218, 325, 219, -1, 172, 218, 325, 219, -1, 187, 18, 78, 218, 325, 219, -1, 221, 311, 217, 216, 316, -1, 160, 274, 144, -1, 162, -1, 218, 318, 219, -1, 216, 318, 217, -1, 227, 318, 217, -1, 313, 312, -1, 312, -1, 186, 18, -1, 314, 312, -1, -1, 218, 311, 219, -1, 216, 311, 217, -1, 321, 217, -1, 321, 217, 216, 316, -1, 313, -1, 291, 293, 139, 320, -1, -1, 317, 319, -1, -1, 137, 317, 319, -1, 140, 317, 319, -1, 277, -1, 218, 291, 139, 320, 137, 311, 322, 219, -1, -1, 324, -1, -1, 137, 311, 322, -1, 140, 311, 322, -1, -1, 138, 311, 323, -1, 311, 323, -1, -1, 264, 142, 311, 326, -1, -1, 138, 264, 142, 311, 326, -1, 312, -1, 327, 312, -1, 327, -1, -1, 328, 330, -1, -1, 138, 328, 330, -1, -1, 156, 329, 331, -1, 295, -1, 301, 329, 331, 144, -1, 279, 142, 320, -1, -1, 32, 333, 334, -1, 283, -1, 260, 139, 283, -1, -1, 335, 337, -1, -1, 138, 335, 337, -1, 291, -1, 291, 214, 336, 215, -1, 291, 142, 311, -1, 291, 214, 336, 215, 142, 311, -1, -1, 32, 338, 339, -1, 291, 139, 277, -1, 291, 214, 336, 215, 139, 277, -1, -1, 32, 340, 341, -1, 291, 139, 277, -1, -1, 32, 342, 343, -1, 291, 306, 302, 142, 311, -1, -1, 32, 344, 345, -1, 292, 306, 302, 142, 311, -1, -1, 218, 318, 219, 347, -1, -1, 214, 321, 215, -1, -1, 78, 311, -1, 347, 294, 348, 349, -1, 352, -1, 350, 352, -1, -1, 137, 350, 352, -1, 291, 142, 351, -1, 291, 214, 336, 215, 142, 351, -1, -1, 32, 353, 354, -1, -1, 125, 344, 345, -1, 347, 294, 349, -1, -1, 32, 356, 357, -1, 296, -1, 296, 139, 311, -1, -1, 358, 360, -1, -1, 138, 358, 360, -1, 296, -1, 214, 359, 215, -1, 214, 359, 137, 359, 215, -1, 218, 318, 219, -1, -1, 361, 362, -1, -1, 142, 18, -1, 294, 362, 276, 311, 363, -1, -1, 32, 364, 365, -1, 148, -1, 149, -1, 304, -1, 148, -1, 149, -1, 324, -1, 141, -1, 161, -1, -1, 129, 311, -1, 130, 311, -1, 131, 311, -1, 132, 311, -1, 371, 373, -1, 370, 139, 311, -1, 296, 33, 370, -1, 136, 296, 33, 370, -1, 147, 370, -1, 12, -1, 16, -1, 14, -1, 18, -1, 296, -1, 136, 296, -1, 79, 296, -1, 290, 296, -1, 214, 374, 215, -1, 214, 374, 137, 374, 215, -1, 224, 374, 217, -1, 220, 374, 215, -1, 223, 374, 215, -1, 220, 374, 137, 374, 215, -1, 223, 374, 137, 374, 215, -1, 222, 376, 219, -1, 225, 376, 219, -1, 216, 304, 217, -1, 371, -1, 218, 366, 219, -1, -1, 372, 373, -1, -1, 370, 375, -1, -1, 138, 370, 375, -1, 149, -1, 264, 142, 370, 377, -1, -1, 138, 149, -1, 138, 264, 142, 370, 377, -1, 218, 318, 219, -1, 371, -1, 157, 321, 158, -1, 159, -1, -1, 378, 379, -1, 218, 304, 219, -1, 371, -1, -1, 380, 381, -1, 383, 387, -1, 382, 139, 311, -1, 392, 382, 103, 382, -1, 392, 382, 103, 382, 55, 382, -1, 393, 311, 103, 382, 55, 382, -1, 394, 382, 78, 410, -1, 395, 311, 78, 413, -1, 255, 379, 389, 390, 382, -1, 256, 294, 379, 389, 390, 382, -1, 396, 424, 382, -1, 397, 383, 382, -1, 190, 382, -1, 191, 382, -1, 398, 401, 128, 410, -1, 382, 125, 218, 450, 219, -1, 12, -1, 14, -1, 15, -1, 16, -1, 17, -1, 18, -1, 192, -1, 193, -1, 294, -1, 79, 294, -1, 290, 260, -1, 263, -1, 133, -1, 39, -1, 45, -1, 211, 385, -1, 212, 385, -1, 213, -1, 182, -1, 183, -1, 175, -1, 176, -1, 177, -1, 178, -1, 179, -1, 180, -1, 181, -1, 221, 311, 217, 214, 399, 215, -1, 221, 311, 217, 216, 382, 217, 214, 399, 215, -1, 168, 315, 214, 399, 215, -1, 299, 388, -1, 368, 264, -1, 368, 216, 388, -1, 301, 329, 331, 144, -1, 227, 367, 137, 382, 217, -1, 214, 399, 215, -1, 214, 399, 137, 399, 215, -1, 169, 315, 214, 399, 215, -1, 170, 315, 214, 399, 215, -1, 224, 399, 217, -1, 38, 401, 56, -1, 214, 402, 215, -1, 220, 399, 215, -1, 223, 399, 215, -1, 173, 214, 399, 215, -1, 174, 214, 399, 215, -1, 220, 399, 137, 399, 215, -1, 223, 399, 137, 399, 215, -1, 222, 403, 219, -1, 225, 403, 219, -1, 171, 218, 403, 219, -1, 172, 218, 403, 219, -1, 185, 214, 311, 138, 18, 215, -1, 167, 382, 215, -1, 166, 382, 215, -1, 165, 401, 215, -1, 72, 450, 67, 401, 56, -1, 218, 450, 219, -1, 218, 367, 219, -1, -1, 384, 385, -1, 383, -1, 384, -1, -1, 386, 387, -1, 399, 217, -1, 399, 217, 216, 388, -1, -1, 139, 311, -1, 151, -1, 152, -1, 150, 274, 144, -1, -1, 422, 151, -1, 65, 391, -1, 94, 391, -1, 40, 391, -1, 41, 391, -1, 42, 391, -1, 93, 391, -1, 62, -1, 63, 423, 151, -1, 127, 423, 151, -1, 104, -1, -1, 382, 400, -1, -1, 138, 382, 400, -1, -1, 382, -1, 382, 140, 401, -1, 382, 140, 401, -1, -1, 264, 142, 382, 404, -1, -1, 138, 264, 142, 382, 404, -1, 382, -1, 382, 33, 370, -1, 405, 407, -1, -1, 32, 405, 407, -1, 370, -1, 370, 124, 406, -1, 408, 151, 382, -1, 408, 153, 382, -1, 408, 154, 382, -1, 408, 155, 382, -1, 411, -1, 409, 411, -1, -1, 137, 409, 411, -1, 310, 151, 382, -1, 414, -1, 412, 414, -1, -1, 137, 412, 414, -1, -1, 218, 318, 219, -1, -1, 157, 321, 158, -1, 159, -1, 294, 139, -1, 294, 139, 311, -1, -1, 417, 419, -1, -1, 138, 417, 419, -1, 214, 418, 215, -1, -1, 216, 318, 217, -1, -1, 139, 421, 214, 418, 215, -1, 415, 416, 420, 422, -1, 214, 399, 140, 399, 140, 399, 215, -1, 296, -1, -1, 425, 427, -1, -1, 138, 425, 427, -1, 425, -1, 214, 426, 215, -1, -1, 428, 429, -1, 294, 429, 142, 382, -1, -1, 32, 430, 431, -1, 370, 142, 382, 369, -1, -1, 32, 432, 433, -1, 297, 379, 142, 382, 369, -1, 297, 379, 276, 311, 142, 382, 369, -1, -1, 32, 434, 435, -1, -1, 128, 296, -1, 296, 436, 142, 382, -1, 136, 296, 436, 142, 382, -1, 296, 139, 311, 436, -1, 296, 139, 311, 436, 142, 382, -1, -1, 32, 437, 438, -1, 332, 381, 389, 142, 382, -1, 68, 266, 262, -1, 69, 266, 262, -1, 70, 266, 262, -1, 84, 266, 262, -1, 82, 266, 262, -1, 77, 262, -1, 102, 262, -1, 210, 260, -1, 197, 260, 271, -1, 196, 267, -1, 203, 267, -1, 208, 267, -1, 95, 333, 334, -1, 46, 287, 288, -1, 47, 287, 288, -1, 249, 338, 339, -1, 96, 340, 341, -1, 100, 342, 343, -1, 252, 344, 345, -1, 34, 346, -1, 251, 353, 354, 355, -1, 57, 356, 357, -1, 44, 291, -1, 44, 291, 139, 311, -1, 80, 294, 128, 295, -1, 80, 216, 217, 128, 295, -1, 75, 430, 431, -1, 75, 91, 430, 431, -1, 76, 430, 431, -1, 76, 91, 430, 431, -1, 99, 18, -1, 99, 265, 142, 18, -1, 218, 318, 219, -1, -1, 441, 442, -1, -1, 443, 140, -1, 440, -1, 250, 442, 364, 365, -1, 13, -1, 257, 445, -1, 207, 18, -1, 74, 446, 67, 446, 56, -1, 267, 259, 446, 202, -1, 267, 259, 446, 198, 446, 202, -1, 267, 259, 446, 258, 445, -1, 447, -1, -1, 447, 444, 443, -1, 440, -1, 58, 250, 442, 364, 365, -1, 58, 105, 18, 142, 311, -1, 58, 111, 18, 142, 382, -1, 253, 432, 433, -1, 111, 81, 432, 433, -1, 111, 91, 432, 433, -1, 254, 442, 434, 435, -1, 114, 437, 438, -1, 66, 309, 439, -1, 74, 450, 67, 450, 56, -1, 13, -1, 257, 449, -1, 207, 18, -1, 54, 18, -1, 267, 259, 450, 202, -1, 267, 259, 450, 198, 450, 202, -1, 267, 259, 450, 258, 449, -1, 451, -1, -1, 451, 448, 443, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { 0, 1560, 1560, 1561, 1562, 1563, 1564, 1565, 1566, 1567, 1571, 1572, 1573, 1574, 1575, 1576, 1580, 1581, 1582, 1583, 1584, 1585, 1589, 1590, 1591, 1592, 1596, 1597, 1598, 1599, 1600, 1604, 1605, 1606, 1607, 1611, 1612, 1613, 1614, 1615, 1616, 1620, 1621, 1622, 1623, 1627, 1628, 1632, 1633, 1634, 1638, 1639, 1640, 1644, 1645, 1649, 1650, 1651, 1652, 1653, 1654, 1655, 1656, 1657, 1658, 1659, 1660, 1664, 1668, 1669, 1673, 1674, 1675, 1679, 1680, 1681, 1685, 1689, 1690, 1691, 1692, 1696, 1697, 1701, 1702, 1703, 1704, 1705, 1706, 1707, 1708, 1709, 1713, 1714, 1718, 1719, 1723, 1724, 1728, 1732, 1733, 1734, 1735, 1736, 1740, 1741, 1745, 1746, 1750, 1751, 1752, 1756, 1757, 1761, 1762, 1766, 1767, 1768, 1769, 1770, 1771, 1772, 1776, 1777, 1778, 1779, 1783, 1784, 1788, 1789, 1793, 1794, 1795, 1796, 1797, 1798, 1799, 1800, 1801, 1802, 1803, 1804, 1805, 1809, 1810, 1814, 1815, 1819, 1820, 1824, 1828, 1829, 1833, 1834, 1835, 1839, 1840, 1841, 1842, 1843, 1847, 1848, 1849, 1850, 1851, 1852, 1853, 1854, 1855, 1856, 1860, 1861, 1865, 1866, 1870, 1871, 1872, 1873, 1874, 1875, 1876, 1877, 1878, 1882, 1883, 1887, 1888, 1892, 1893, 1897, 1901, 1902, 1906, 1910, 1911, 1915, 1916, 1920, 1924, 1925, 1929, 1930, 1934, 1935, 1936, 1940, 1941, 1945, 1946, 1950, 1951, 1955, 1959, 1960, 1961, 1962, 1966, 1967, 1968, 1969, 1970, 1971, 1972, 1973, 1974, 1975, 1976, 1977, 1978, 1979, 1980, 1981, 1982, 1983, 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1996, 1997, 2001, 2002, 2006, 2007, 2008, 2012, 2013, 2017, 2018, 2022, 2023, 2027, 2028, 2029, 2033, 2034, 2038, 2039, 2043, 2044, 2045, 2049, 2050, 2054, 2058, 2059, 2063, 2064, 2068, 2069, 2073, 2077, 2078, 2082, 2083, 2087, 2088, 2092, 2093, 2097, 2101, 2102, 2106, 2107, 2111, 2112, 2116, 2117, 2121, 2122, 2123, 2124, 2128, 2129, 2133, 2134, 2138, 2139, 2143, 2147, 2148, 2152, 2156, 2157, 2161, 2165, 2166, 2170, 2171, 2175, 2176, 2180, 2184, 2185, 2189, 2190, 2194, 2195, 2199, 2200, 2204, 2205, 2209, 2213, 2214, 2218, 2219, 2223, 2224, 2228, 2229, 2233, 2234, 2235, 2236, 2240, 2241, 2245, 2246, 2250, 2254, 2255, 2259, 2260, 2261, 2265, 2266, 2267, 2271, 2272, 2276, 2277, 2278, 2279, 2280, 2284, 2285, 2286, 2287, 2288, 2292, 2293, 2294, 2295, 2296, 2297, 2298, 2299, 2300, 2301, 2302, 2303, 2304, 2305, 2306, 2307, 2308, 2309, 2313, 2314, 2318, 2319, 2323, 2324, 2328, 2329, 2333, 2334, 2338, 2339, 2340, 2344, 2345, 2346, 2347, 2351, 2352, 2356, 2357, 2361, 2362, 2366, 2367, 2368, 2369, 2370, 2371, 2372, 2373, 2374, 2375, 2376, 2377, 2378, 2379, 2380, 2384, 2385, 2386, 2387, 2388, 2389, 2390, 2391, 2392, 2393, 2394, 2395, 2396, 2397, 2398, 2399, 2400, 2401, 2402, 2403, 2404, 2405, 2406, 2407, 2408, 2409, 2410, 2411, 2412, 2413, 2414, 2415, 2416, 2417, 2418, 2419, 2420, 2421, 2422, 2423, 2424, 2425, 2426, 2427, 2428, 2429, 2430, 2431, 2432, 2433, 2434, 2435, 2436, 2437, 2438, 2439, 2440, 2441, 2445, 2449, 2450, 2454, 2455, 2459, 2460, 2464, 2465, 2469, 2470, 2474, 2475, 2476, 2480, 2481, 2485, 2489, 2493, 2494, 2495, 2499, 2503, 2504, 2508, 2512, 2516, 2517, 2521, 2522, 2526, 2527, 2528, 2532, 2536, 2537, 2541, 2542, 2546, 2547, 2551, 2555, 2556, 2560, 2561, 2565, 2566, 2567, 2568, 2572, 2573, 2577, 2578, 2582, 2586, 2587, 2591, 2592, 2596, 2597, 2601, 2602, 2603, 2607, 2608, 2612, 2613, 2617, 2618, 2622, 2626, 2627, 2631, 2632, 2636, 2640, 2644, 2648, 2649, 2653, 2654, 2658, 2659, 2663, 2664, 2668, 2672, 2673, 2677, 2681, 2682, 2686, 2687, 2691, 2692, 2696, 2697, 2701, 2702, 2703, 2704, 2708, 2709, 2713, 2717, 2718, 2719, 2720, 2721, 2722, 2723, 2724, 2725, 2726, 2727, 2728, 2729, 2730, 2731, 2732, 2733, 2734, 2735, 2736, 2737, 2738, 2739, 2740, 2741, 2742, 2743, 2744, 2745, 2746, 2747, 2748, 2752, 2756, 2757, 2761, 2762, 2766, 2767, 2768, 2769, 2770, 2771, 2775, 2776, 2777, 2781, 2785, 2786, 2790, 2791, 2792, 2793, 2794, 2795, 2796, 2797, 2798, 2799, 2800, 2801, 2802, 2803, 2804, 2808, 2809, 2810, 2814, 2818, 2819 }; #endif #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. First, the terminals, then, starting at YYNTOKENS, nonterminals. */ static const char *const yytname[] = { "$end", "error", "$undefined", "YYBEG_i0de", "YYBEG_s0rtid", "YYBEG_si0de", "YYBEG_di0de", "YYBEG_s0exp", "YYBEG_d0exp", "YYBEG_d0ecseq_sta", "YYBEG_d0ecseq_dyn", "TOKEN_eof", "LITERAL_char", "LITERAL_extcode", "LITERAL_float", "LITERAL_floatsp", "LITERAL_int", "LITERAL_intsp", "LITERAL_string", "IDENTIFIER_alp", "IDENTIFIER_sym", "IDENTIFIER_arr", "IDENTIFIER_tmp", "IDENTIFIER_ext", "IDENTIFIER_dlr", "IDENTIFIER_srp", "ABSPROP", "ABSTYPE", "ABST0YPE", "ABSVIEW", "ABSVIEWTYPE", "ABSVIEWT0YPE", "AND", "AS", "ASSUME", "ATLAM", "ATLLAM", "ATFIX", "BEGIN", "BREAK", "CASE", "CASEMINUS", "CASEPLUS", "CASTFN", "CLASSDEC", "CONTINUE", "DATASORT", "DATAPARASORT", "DATAPROP", "DATATYPE", "DATAVIEW", "DATAVIEWTYPE", "DO", "DYN", "DYNLOAD", "ELSE", "END", "EXCEPTION", "EXTERN", "FIX", "FN", "FNSTAR", "FOR", "FORSTAR", "FUN", "IF", "IMPLEMENT", "IN", "INFIX", "INFIXL", "INFIXR", "LAM", "LET", "LLAM", "LOCAL", "MACDEF", "MACRODEF", "NONFIX", "OF", "OP", "OVERLOAD", "PAR", "POSTFIX", "PRAXI", "PREFIX", "PRFN", "PRFUN", "PROPDEF", "PROPMINUS", "PROPPLUS", "PRVAL", "REC", "R0EAD", "SCASE", "SIF", "SORTDEF", "STACST", "STADEF", "STAIF", "STALOAD", "STAVAR", "SYMELIM", "SYMINTR", "THEN", "TRY", "TYPEDEF", "TYPEMINUS", "TYPEPLUS", "T0YPE", "T0YPEMINUS", "T0YPEPLUS", "VAL", "VALMINUS", "VALPLUS", "VAR", "VIEWDEF", "VIEWMINUS", "VIEWPLUS", "VIEWTYPEDEF", "VIEWTYPEMINUS", "VIEWTYPEPLUS", "VIEWT0YPE", "VIEWT0YPEMINUS", "VIEWT0YPEPLUS", "WHEN", "WHERE", "WHILE", "WHILESTAR", "WITH", "WITHPROP", "WITHTYPE", "WITHVIEW", "WITHVIEWTYPE", "AMPERSAND", "BACKQUOTE", "BACKSLASH", "BANG", "BAR", "COMMA", "COLON", "SEMICOLON", "DOT", "EQ", "LT", "GT", "DOLLAR", "HASH", "TILDE", "DOTDOT", "DOTDOTDOT", "EQLT", "EQGT", "EQLTGT", "EQGTGT", "EQSLASHEQGT", "EQSLASHEQGTGT", "GTLT", "DOTLT", "GTDOT", "DOTLTGTDOT", "MINUSLT", "MINUSGT", "MINUSLTGT", "COLONLT", "COLONLTGT", "BACKQUOTELPAREN", "COMMALPAREN", "PERCENTLPAREN", "DLRARRPSZ", "DLRLST_T", "DLRLST_VT", "DLRREC_T", "DLRREC_VT", "DLRTUP_T", "DLRTUP_VT", "DLRDELAY", "DLRLDELAY", "DLRDYNLOAD", "DLREFFMASK_ALL", "DLREFFMASK_EXN", "DLREFFMASK_NTM", "DLREFFMASK_REF", "DLRDECRYPT", "DLRENCRYPT", "DLREXTERN", "DLREXTVAL", "DLREXTYPE", "DLREXTYPE_STRUCT", "DLRFOLD", "DLRUNFOLD", "DLRRAISE", "DLRSHOWTYPE", "SRPFILENAME", "SRPLOCATION", "SRPCHARCOUNT", "SRPLINECOUNT", "SRPASSERT", "SRPDEFINE", "SRPELSE", "SRPELIF", "SRPELIFDEF", "SRPELIFNDEF", "SRPENDIF", "SRPERROR", "SRPIF", "SRPIFDEF", "SRPIFNDEF", "SRPINCLUDE", "SRPPRINT", "SRPTHEN", "SRPUNDEF", "FOLDAT", "FREEAT", "VIEWAT", "LPAREN", "RPAREN", "LBRACKET", "RBRACKET", "LBRACE", "RBRACE", "ATLPAREN", "ATLBRACKET", "ATLBRACE", "QUOTELPAREN", "QUOTELBRACKET", "QUOTELBRACE", "HASHLPAREN", "HASHLBRACKET", "HASHLBRACE", "PATAS", "PATFREE", "SEXPLAM", "DEXPLAM", "DEXPFIX", "CLAUS", "DEXPCASE", "DEXPIF", "DEXPRAISE", "DEXPSHOWTYPE", "DEXPTRY", "DEXPFOR", "DEXPWHILE", "BARCLAUSSEQNONE", "TMPSEXP", "TMPSARG", "SARRIND", "SEXPDARGSEQEMPTY", "$accept", "theStartEntry", "abskind", "dcstkind", "datakind", "stadefkind", "valkind", "funkind", "lamkind", "fixkind", "srpifkind", "srpelifkind", "srpthenopt", "i0de", "i0de_dlr", "i0deseq", "i0dext", "l0ab", "stai0de", "p0rec", "e0xp", "atme0xp", "e0xpseq", "commae0xpseq", "e0xpopt", "e0ffid", "e0fftag", "e0fftagseq", "commae0fftagseq", "colonwith", "s0rt", "s0rtq", "s0rtid", "atms0rt", "s0rtseq", "commas0rtseq", "s0rtpol", "d0atsrtcon", "d0atsrtconseq", "bard0atsrtconseq", "d0atsrtdec", "andd0atsrtdecseq", "s0taq", "d0ynq", "si0de", "sqi0de", "commasi0deseq", "di0de", "dqi0de", "pi0de", "fi0de", "arri0de", "arrqi0de", "tmpi0de", "tmpqi0de", "colons0rtopt", "s0arg", "s0argseq", "commas0argseq", "s0argseqseq", "decs0argseq", "commadecs0argseq", "decs0argseqseq", "sp0at", "s0exp", "atms0exp", "apps0exp", "exts0exp", "s0expelt", "s0arrind", "s0qua", "s0quaseq", "barsemis0quaseq", "s0rtext", "s0expseq", "barsemis0expseq", "commas0expseq", "s0expseq1", "labs0expseq", "commalabs0expseq", "t0mps0exp", "t1mps0exp", "t1mps0expseq", "commat1mps0expseq", "gtlt_t1mps0expseqseq", "impqi0de", "s0rtdef", "ands0rtdefseq", "d0atarg", "d0atargseq", "commad0atargseq", "s0tacon", "ands0taconseq", "s0tacst", "ands0tacstseq", "s0tavar", "ands0tavarseq", "s0expdef", "ands0expdefseq", "s0aspdec", "conq0uaseq", "coni0ndopt", "cona0rgopt", "d0atcon", "d0atconseq", "bard0atconseq", "d0atdec", "andd0atdecseq", "s0expdefseqopt", "e0xndec", "ande0xndecseq", "p0arg", "p0argseq", "commap0argseq", "d0arg", "d0argseq", "extnamopt", "d0cstdec", "andd0cstdecseq", "s0vararg", "s0exparg", "s0elop", "witht0ype", "p0at", "atmp0at", "argp0at", "argp0atseq", "p0atseq", "commap0atseq", "labp0atseq", "commalabp0atseq", "f0arg1", "f0arg1seq", "f0arg2", "f0arg2seq", "d0exp", "atmd0exp", "s0expdarg", "s0expdargseq", "argd0exp", "argd0expseq", "d0arrind", "colons0expopt", "funarrow", "caseinv", "ifhead", "sifhead", "casehead", "scasehead", "forhead", "whilehead", "tryhead", "d0expcommaseq", "commad0expseq", "d0expsemiseq0", "d0expsemiseq1", "labd0expseq", "commalabd0expseq", "m0atch", "m0atchseq", "andm0atchseq", "guap0at", "c0lau", "c0lauseq", "barc0lauseq", "sc0lau", "sc0lauseq", "barsc0lauseq", "i0nvqua", "i0nvmet", "i0nvarg", "i0nvargseq", "commai0nvargseq", "i0nvargstate", "i0nvresqua", "i0nvresstate", "loopi0nv", "initestpost", "m0arg", "m0argseq", "commam0argseq", "m0acarg", "m0acargseq", "m0acdef", "andm0acdefseq", "v0aldec", "andv0aldecseq", "f0undec", "andf0undecseq", "v0arwth", "v0ardec", "andv0ardecseq", "i0mpdec", "d0ec", "d0ecarg", "d0ecargseq", "semicolonseq", "d0ec_sta", "guad0ec_sta", "d0ecseq_sta", "d0ecseq_sta_rev", "d0ec_dyn", "guad0ec_dyn", "d0ecseq_dyn", "d0ecseq_dyn_rev", 0 }; #endif # ifdef YYPRINT /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to token YYLEX-NUM. */ static const yytype_uint16 yytoknum[] = { 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, 498, 499, 500, 501 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint16 yyr1[] = { 0, 247, 248, 248, 248, 248, 248, 248, 248, 248, 249, 249, 249, 249, 249, 249, 250, 250, 250, 250, 250, 250, 251, 251, 251, 251, 252, 252, 252, 252, 252, 253, 253, 253, 253, 254, 254, 254, 254, 254, 254, 255, 255, 255, 255, 256, 256, 257, 257, 257, 258, 258, 258, 259, 259, 260, 260, 260, 260, 260, 260, 260, 260, 260, 260, 260, 260, 261, 262, 262, 263, 263, 263, 264, 264, 264, 265, 266, 266, 266, 266, 267, 267, 268, 268, 268, 268, 268, 268, 268, 268, 268, 269, 269, 270, 270, 271, 271, 272, 273, 273, 273, 273, 273, 274, 274, 275, 275, 276, 276, 276, 277, 277, 278, 278, 279, 279, 279, 279, 279, 279, 279, 280, 280, 280, 280, 281, 281, 282, 282, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 284, 284, 285, 285, 286, 286, 287, 288, 288, 289, 289, 289, 290, 290, 290, 290, 290, 291, 291, 291, 291, 291, 291, 291, 291, 291, 291, 292, 292, 293, 293, 294, 294, 294, 294, 294, 294, 294, 294, 294, 295, 295, 296, 296, 297, 297, 298, 299, 299, 300, 301, 301, 302, 302, 303, 304, 304, 305, 305, 306, 306, 306, 307, 307, 308, 308, 309, 309, 310, 311, 311, 311, 311, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 312, 313, 313, 314, 314, 315, 315, 315, 316, 316, 317, 317, 318, 318, 319, 319, 319, 320, 320, 321, 321, 322, 322, 322, 323, 323, 324, 325, 325, 326, 326, 327, 327, 328, 329, 329, 330, 330, 331, 331, 332, 332, 333, 334, 334, 335, 335, 336, 336, 337, 337, 338, 338, 338, 338, 339, 339, 340, 340, 341, 341, 342, 343, 343, 344, 345, 345, 346, 347, 347, 348, 348, 349, 349, 350, 351, 351, 352, 352, 353, 353, 354, 354, 355, 355, 356, 357, 357, 358, 358, 359, 359, 360, 360, 361, 361, 361, 361, 362, 362, 363, 363, 364, 365, 365, 366, 366, 366, 367, 367, 367, 368, 368, 369, 369, 369, 369, 369, 370, 370, 370, 370, 370, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 371, 372, 372, 373, 373, 374, 374, 375, 375, 376, 376, 377, 377, 377, 378, 378, 378, 378, 379, 379, 380, 380, 381, 381, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 384, 385, 385, 386, 386, 387, 387, 388, 388, 389, 389, 390, 390, 390, 391, 391, 392, 393, 394, 394, 394, 395, 396, 396, 397, 398, 399, 399, 400, 400, 401, 401, 401, 402, 403, 403, 404, 404, 405, 405, 406, 407, 407, 408, 408, 409, 409, 409, 409, 410, 410, 411, 411, 412, 413, 413, 414, 414, 415, 415, 416, 416, 416, 417, 417, 418, 418, 419, 419, 420, 421, 421, 422, 422, 423, 424, 425, 426, 426, 427, 427, 428, 428, 429, 429, 430, 431, 431, 432, 433, 433, 434, 434, 435, 435, 436, 436, 437, 437, 437, 437, 438, 438, 439, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 440, 441, 442, 442, 443, 443, 444, 444, 444, 444, 444, 444, 445, 445, 445, 446, 447, 447, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, 449, 449, 449, 450, 451, 451 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ static const yytype_uint8 yyr2[] = { 0, 2, 3, 3, 3, 3, 3, 3, 3, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 2, 1, 1, 1, 1, 1, 3, 1, 0, 1, 3, 5, 2, 1, 1, 1, 1, 1, 1, 1, 1, 3, 3, 0, 2, 0, 3, 0, 1, 1, 2, 2, 1, 1, 1, 0, 2, 0, 3, 1, 1, 3, 2, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 3, 0, 2, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 2, 0, 3, 3, 0, 3, 2, 2, 3, 2, 2, 3, 3, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 2, 1, 1, 2, 0, 2, 2, 0, 2, 0, 3, 0, 2, 4, 0, 2, 0, 3, 0, 4, 4, 1, 1, 3, 5, 1, 1, 1, 1, 2, 2, 3, 5, 3, 3, 4, 4, 5, 5, 6, 6, 3, 3, 4, 4, 6, 5, 3, 1, 3, 3, 3, 2, 1, 2, 2, 0, 3, 3, 2, 4, 1, 4, 0, 2, 0, 3, 3, 1, 8, 0, 1, 0, 3, 3, 0, 3, 2, 0, 4, 0, 5, 1, 2, 1, 0, 2, 0, 3, 0, 3, 1, 4, 3, 0, 3, 1, 3, 0, 2, 0, 3, 1, 4, 3, 6, 0, 3, 3, 6, 0, 3, 3, 0, 3, 5, 0, 3, 5, 0, 4, 0, 3, 0, 2, 4, 1, 2, 0, 3, 3, 6, 0, 3, 0, 3, 3, 0, 3, 1, 3, 0, 2, 0, 3, 1, 3, 5, 3, 0, 2, 0, 2, 5, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2, 2, 3, 3, 4, 2, 1, 1, 1, 1, 1, 2, 2, 2, 3, 5, 3, 3, 3, 5, 5, 3, 3, 3, 1, 3, 0, 2, 0, 2, 0, 3, 1, 4, 0, 2, 5, 3, 1, 3, 1, 0, 2, 3, 1, 0, 2, 2, 3, 4, 6, 6, 4, 4, 5, 6, 3, 3, 2, 2, 4, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 9, 5, 2, 2, 3, 4, 5, 3, 5, 5, 5, 3, 3, 3, 3, 3, 4, 4, 5, 5, 3, 3, 4, 4, 6, 3, 3, 3, 5, 3, 3, 0, 2, 1, 1, 0, 2, 2, 4, 0, 2, 1, 1, 3, 0, 2, 2, 2, 2, 2, 2, 2, 1, 3, 3, 1, 0, 2, 0, 3, 0, 1, 3, 3, 0, 4, 0, 5, 1, 3, 2, 0, 3, 1, 3, 3, 3, 3, 3, 1, 2, 0, 3, 3, 1, 2, 0, 3, 0, 3, 0, 3, 1, 2, 3, 0, 2, 0, 3, 3, 0, 3, 0, 5, 4, 7, 1, 0, 2, 0, 3, 1, 3, 0, 2, 4, 0, 3, 4, 0, 3, 5, 7, 0, 3, 0, 2, 4, 5, 4, 6, 0, 3, 5, 3, 3, 3, 3, 3, 2, 2, 2, 3, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 2, 4, 3, 2, 4, 4, 5, 3, 4, 3, 4, 2, 4, 3, 0, 2, 0, 2, 1, 4, 1, 2, 2, 5, 4, 6, 5, 1, 0, 3, 1, 5, 5, 5, 3, 4, 4, 4, 3, 3, 5, 1, 2, 2, 2, 4, 6, 5, 1, 0, 3 }; /* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. Performed when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint16 yydefact[] = { 0, 0, 0, 0, 0, 0, 0, 630, 651, 0, 55, 56, 57, 58, 59, 60, 63, 61, 66, 62, 64, 65, 0, 115, 116, 117, 118, 119, 120, 121, 0, 160, 161, 162, 163, 164, 165, 167, 166, 169, 168, 0, 174, 175, 176, 177, 178, 181, 179, 182, 180, 0, 216, 217, 218, 67, 202, 0, 0, 104, 239, 0, 0, 0, 0, 0, 0, 261, 254, 254, 261, 0, 269, 261, 269, 254, 0, 0, 219, 0, 244, 212, 213, 421, 422, 423, 424, 425, 426, 189, 192, 70, 42, 44, 46, 509, 434, 493, 493, 493, 435, 71, 45, 501, 537, 493, 41, 651, 43, 0, 493, 493, 504, 72, 537, 433, 353, 0, 354, 509, 0, 0, 247, 247, 247, 0, 0, 0, 0, 441, 442, 443, 444, 445, 446, 447, 439, 440, 0, 0, 0, 427, 428, 480, 480, 438, 505, 651, 505, 0, 513, 505, 505, 513, 0, 400, 0, 0, 432, 0, 429, 190, 505, 193, 276, 0, 0, 484, 0, 0, 0, 0, 0, 0, 509, 0, 629, 0, 650, 1, 4, 5, 6, 7, 198, 202, 195, 220, 0, 103, 98, 102, 0, 0, 101, 106, 0, 269, 269, 261, 261, 245, 0, 266, 0, 262, 219, 252, 256, 0, 0, 0, 0, 74, 0, 73, 0, 0, 0, 0, 0, 153, 152, 221, 8, 0, 243, 246, 510, 0, 549, 497, 0, 498, 499, 254, 539, 0, 495, 0, 430, 500, 496, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 513, 513, 505, 505, 0, 417, 418, 0, 480, 436, 437, 507, 0, 0, 0, 507, 0, 0, 0, 0, 0, 0, 0, 350, 351, 352, 0, 365, 367, 366, 368, 185, 186, 0, 0, 261, 399, 387, 198, 254, 387, 0, 387, 387, 0, 0, 369, 397, 400, 488, 400, 156, 155, 0, 431, 191, 194, 451, 0, 273, 275, 278, 280, 505, 452, 9, 0, 0, 651, 482, 483, 484, 406, 0, 0, 0, 0, 505, 0, 0, 0, 2, 622, 10, 11, 12, 13, 14, 15, 0, 18, 0, 0, 0, 22, 23, 24, 25, 310, 16, 77, 77, 77, 630, 0, 0, 68, 0, 77, 19, 77, 20, 27, 21, 0, 0, 26, 0, 0, 68, 28, 17, 29, 30, 0, 0, 0, 47, 48, 49, 0, 0, 0, 0, 616, 0, 0, 0, 620, 618, 3, 643, 38, 0, 0, 35, 36, 37, 209, 651, 39, 40, 34, 31, 32, 33, 0, 0, 0, 616, 0, 632, 618, 195, 200, 0, 203, 0, 0, 154, 99, 100, 0, 105, 238, 0, 0, 0, 0, 0, 0, 268, 261, 222, 0, 0, 0, 0, 255, 241, 240, 261, 224, 0, 0, 0, 232, 261, 225, 233, 242, 0, 126, 126, 0, 214, 0, 122, 112, 509, 461, 254, 0, 494, 0, 261, 541, 0, 502, 509, 503, 158, 0, 476, 475, 474, 0, 0, 505, 505, 505, 0, 0, 0, 0, 0, 0, 481, 0, 509, 506, 505, 456, 462, 478, 505, 463, 0, 0, 469, 505, 464, 460, 470, 0, 371, 370, 0, 0, 0, 369, 389, 385, 0, 0, 0, 0, 391, 0, 0, 0, 0, 0, 372, 401, 0, 0, 488, 157, 486, 274, 0, 277, 276, 0, 453, 651, 407, 485, 0, 0, 530, 535, 0, 415, 416, 530, 0, 170, 202, 602, 605, 0, 150, 150, 254, 0, 328, 78, 0, 68, 68, 68, 0, 0, 562, 565, 0, 565, 68, 588, 0, 0, 68, 68, 0, 285, 0, 301, 613, 76, 0, 0, 304, 589, 83, 84, 85, 86, 0, 87, 88, 92, 89, 592, 82, 96, 593, 624, 594, 590, 293, 297, 254, 616, 0, 0, 323, 202, 307, 53, 623, 631, 646, 0, 17, 616, 205, 0, 0, 0, 0, 0, 574, 580, 645, 0, 568, 0, 53, 644, 652, 197, 0, 199, 202, 196, 0, 106, 234, 235, 261, 226, 261, 227, 269, 266, 0, 172, 0, 256, 256, 0, 261, 75, 271, 0, 0, 128, 0, 0, 113, 111, 123, 511, 0, 544, 538, 0, 544, 551, 0, 159, 249, 248, 0, 0, 0, 471, 472, 465, 466, 0, 479, 507, 512, 0, 0, 505, 0, 515, 0, 0, 398, 370, 364, 0, 0, 0, 388, 198, 383, 385, 360, 387, 373, 382, 396, 387, 376, 0, 380, 387, 377, 375, 381, 489, 104, 490, 491, 0, 0, 505, 278, 280, 454, 0, 408, 0, 0, 522, 0, 530, 411, 528, 0, 0, 0, 535, 412, 533, 505, 419, 171, 195, 0, 147, 0, 596, 597, 0, 314, 310, 604, 0, 583, 584, 585, 630, 565, 556, 555, 560, 562, 0, 0, 609, 565, 611, 69, 0, 0, 587, 586, 0, 0, 595, 0, 289, 0, 599, 0, 0, 0, 600, 0, 94, 0, 81, 97, 591, 0, 289, 0, 598, 0, 617, 340, 345, 319, 289, 0, 325, 195, 0, 601, 54, 630, 619, 0, 0, 0, 207, 0, 0, 183, 282, 276, 404, 641, 651, 568, 568, 574, 0, 0, 0, 0, 640, 0, 0, 636, 0, 187, 400, 572, 651, 200, 204, 215, 107, 0, 0, 0, 267, 223, 173, 0, 259, 253, 257, 258, 228, 237, 0, 0, 270, 229, 114, 0, 127, 124, 125, 550, 0, 546, 0, 540, 0, 553, 477, 450, 458, 459, 0, 508, 457, 467, 0, 0, 0, 514, 468, 455, 0, 362, 389, 361, 347, 348, 349, 0, 386, 0, 0, 393, 0, 0, 413, 0, 487, 279, 281, 420, 0, 0, 530, 0, 0, 0, 0, 0, 529, 535, 198, 0, 534, 0, 0, 606, 0, 143, 147, 149, 145, 150, 310, 0, 327, 328, 0, 79, 0, 610, 558, 0, 563, 0, 565, 612, 0, 0, 607, 284, 285, 299, 115, 116, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 119, 120, 121, 0, 130, 287, 291, 0, 301, 614, 303, 304, 91, 0, 93, 90, 295, 0, 297, 615, 332, 254, 336, 340, 0, 0, 621, 310, 0, 319, 321, 317, 0, 323, 0, 603, 0, 307, 0, 0, 0, 345, 0, 206, 209, 184, 280, 198, 403, 404, 488, 0, 637, 638, 0, 575, 574, 0, 580, 355, 568, 188, 0, 0, 639, 0, 201, 230, 231, 236, 0, 250, 0, 128, 542, 0, 545, 552, 548, 473, 448, 0, 0, 363, 390, 384, 374, 378, 0, 392, 379, 492, 414, 409, 410, 531, 517, 520, 523, 524, 525, 526, 527, 536, 0, 532, 505, 0, 147, 0, 146, 151, 311, 315, 329, 0, 625, 0, 557, 561, 564, 566, 608, 286, 0, 0, 290, 0, 302, 305, 94, 294, 298, 330, 334, 0, 0, 341, 108, 104, 109, 0, 345, 319, 312, 318, 0, 324, 307, 0, 308, 630, 50, 51, 52, 626, 0, 634, 635, 633, 207, 210, 0, 0, 405, 0, 642, 0, 578, 576, 581, 0, 0, 0, 0, 567, 569, 0, 0, 572, 651, 647, 0, 0, 261, 0, 129, 543, 546, 505, 0, 394, 0, 0, 0, 519, 211, 0, 309, 148, 144, 80, 558, 288, 291, 0, 95, 0, 0, 0, 333, 332, 337, 339, 0, 342, 346, 320, 261, 314, 319, 326, 306, 0, 628, 208, 283, 402, 0, 577, 0, 356, 357, 358, 359, 355, 0, 573, 0, 649, 0, 251, 271, 547, 0, 515, 0, 518, 520, 554, 559, 292, 300, 296, 331, 334, 0, 110, 0, 344, 0, 316, 322, 627, 582, 579, 570, 0, 648, 0, 272, 449, 516, 393, 521, 335, 338, 343, 313, 355, 263, 395, 571, 0, 0, 0, 263, 263, 260, 264, 265 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { -1, 9, 386, 387, 388, 389, 411, 412, 155, 156, 390, 1119, 810, 596, 157, 573, 158, 216, 584, 563, 613, 598, 790, 977, 793, 194, 195, 196, 426, 1104, 967, 459, 460, 461, 662, 863, 968, 925, 926, 927, 556, 751, 77, 159, 78, 739, 438, 160, 819, 513, 837, 161, 162, 163, 164, 421, 417, 418, 637, 186, 816, 1006, 621, 740, 203, 80, 81, 82, 250, 856, 208, 209, 441, 852, 857, 1248, 434, 205, 217, 859, 313, 314, 315, 535, 537, 821, 579, 779, 969, 970, 1089, 605, 797, 581, 783, 586, 787, 612, 808, 553, 991, 1182, 931, 992, 993, 994, 610, 805, 998, 560, 756, 1097, 1098, 1173, 986, 987, 1222, 801, 989, 894, 489, 165, 1138, 514, 515, 705, 706, 516, 702, 522, 1052, 301, 302, 1012, 1013, 268, 167, 261, 262, 324, 325, 310, 529, 723, 231, 168, 169, 170, 171, 172, 173, 174, 311, 493, 229, 266, 272, 884, 1060, 1061, 1158, 734, 735, 736, 737, 741, 742, 743, 236, 470, 868, 869, 1039, 673, 465, 232, 237, 331, 765, 938, 1081, 766, 767, 569, 769, 630, 834, 838, 1027, 829, 627, 831, 822, 391, 607, 608, 615, 392, 614, 175, 176, 415, 633, 267, 178 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ #define YYPACT_NINF -1078 static const yytype_int16 yypact[] = { 1244, 2431, 188, 1365, 1312, 2187, 1585, -1078, -1078, 127, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 149, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 185, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 301, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 308, -1078, -1078, -1078, -1078, 588, 1365, 154, 329, -1078, 115, 121, 132, 137, 357, 369, 2187, 694, 694, 2187, 2187, 1257, 2187, 1257, 694, 82, 1365, -1078, 86, -1078, 694, 694, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 1585, -1078, -16, -16, -16, -1078, -1078, -1078, -1078, 206, -16, -1078, -1078, -1078, 1312, -16, -16, -1078, -1078, 206, -1078, -1078, 377, -1078, 1585, 1585, 1585, 122, 122, 122, 224, 226, 217, 232, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 234, 1585, 1585, -1078, -1078, 239, 239, -1078, 1585, -1078, 1585, 2187, 1257, 1585, 1585, 1257, 1317, 1214, 1312, 65, -1078, 1761, -1078, -1078, 1585, -1078, 2283, 1973, 80, 1835, 1585, 2187, 1585, 2187, 238, 2049, 1585, 450, 2841, 464, 2656, -1078, -1078, -1078, -1078, -1078, 1365, 588, 339, -1078, 340, -1078, -1078, -1078, 470, 470, -1078, 353, 351, 1257, 1257, 2187, 2187, -1078, 420, -7, -17, -1078, 16, 694, 181, 295, 300, 20, 19, -1078, 1257, -1078, 380, 307, 89, 309, 313, -1078, -1078, -1078, -1078, 882, -1078, -1078, 37, 476, 325, -1078, 393, -1078, -1078, 694, 200, 395, -1078, 481, -1078, -1078, -1078, 403, 51, 343, -1, 102, 2187, 2187, 346, 350, 352, 1257, 1257, 1585, 1585, 2187, 0, 0, 1317, 239, -1078, -1078, 396, 105, 364, 387, 316, 151, 150, 454, 397, 156, 382, 402, -1078, -1078, -1078, 500, -1078, -1078, -1078, -1078, -1078, -1078, 388, 388, 2187, -1078, 1348, 1365, 694, 1348, 816, 1348, 1348, 816, 388, -1078, -1078, 1214, 490, 1214, -1078, -1078, 499, -1078, -1078, -1078, -1078, 423, -1078, 2283, 505, 486, 1585, -1078, -1078, 426, 2187, 1317, -1078, -1078, 1835, -1078, 222, 11, 50, 48, 1585, 1585, 1585, 517, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 2015, -1078, 1365, 2431, 2431, -1078, -1078, -1078, -1078, 431, -1078, 45, 45, 45, -1078, 2646, 2669, 2431, 1058, 45, -1078, 45, -1078, -1078, -1078, 188, 1365, -1078, 491, 1365, 2431, -1078, -1078, -1078, -1078, 2453, 2431, 2453, -1078, -1078, -1078, 632, 2453, 2431, 1365, 437, 1365, 1365, 2453, -1078, -1078, -1078, -1078, -1078, 639, 394, -1078, -1078, -1078, 440, -1078, -1078, -1078, -1078, 93, -1078, -1078, 88, 642, 1348, 437, 2453, -1078, -1078, 339, 523, 452, -1078, 882, 518, -1078, -1078, -1078, 329, -1078, -1078, 451, 458, 157, 158, 460, 2187, -1078, 2187, -1078, 1365, 542, 694, 694, -1078, -1078, -1078, 2187, -1078, 468, 471, 2187, -1078, 2187, -1078, -1078, -1078, 670, 882, 882, 556, 882, 188, -1078, -1078, 1585, -1078, 694, 484, -1078, 482, 2187, -1078, 488, -1078, 1585, -1078, -1078, 561, -1078, -1078, -1078, 164, -39, 1585, 1585, 1585, 493, 498, 507, 512, 378, 501, -1078, 1585, 1585, -1078, 1585, -1078, -1078, -1078, 1585, -1078, 187, 1585, -1078, 1585, -1078, -1078, -1078, 1585, -1078, -1078, 549, 388, 1348, 675, 386, 1570, 177, 511, 510, 189, -1078, 596, 521, 190, 513, 522, -1078, -1078, 2187, 335, 490, -1078, 526, -1078, 694, -1078, 2283, 600, -1078, -1078, 608, -1078, 1585, 1585, 1042, 2346, 611, 0, 0, 1042, 1365, -1078, 588, -1078, 614, 612, 723, 723, 694, 1312, 724, -1078, 2431, 2431, 2431, 2431, 690, 1312, 76, 728, 1312, 728, 2431, -1078, 541, 633, 2431, 2431, 621, 732, -36, 733, -1078, -1078, 624, 630, 738, -1078, -1078, -1078, -1078, -1078, 2453, -1078, -1078, 2453, -1078, 2453, -1078, 2453, 2453, -1078, 2453, -1078, -23, 745, 694, 437, 1312, 202, 747, 588, 751, 2376, -1078, 647, -1078, 770, 773, 437, 1365, 1680, 725, 1348, 1348, 388, 90, 763, -1078, 214, 764, 1496, 2376, -1078, 647, -1078, 1365, -1078, 588, 882, 2187, 353, -1078, -1078, 2187, -1078, 2187, -1078, 1257, -7, 582, 665, 564, 181, 181, 590, 2187, -1078, 438, 591, 668, 726, 595, 597, -1078, -1078, -1078, -1078, 594, 1312, -1078, 655, 1312, 679, 758, -1078, -1078, -1078, 604, 605, 606, -1078, -1078, -1078, -1078, 804, -1078, 316, -1078, 609, 610, 1585, 1585, 344, 613, 17, -1078, 793, 692, 1348, 1348, 2187, -1078, 875, -1078, 1570, -1078, 1348, -1078, -1078, -1078, 1348, -1078, 1348, -1078, 1348, -1078, -1078, -1078, 608, 329, -1078, -1078, 1585, 335, 1585, 505, 486, -1078, 625, 43, 54, 1348, -2, 416, 703, -1078, -1078, 2015, 629, 697, 708, -1078, -1078, 1585, -1078, -1078, 339, 2187, 2010, 2431, -1078, -1078, 631, 771, 431, -1078, 64, -1078, -1078, -1078, -1078, 728, 388, -1078, -1078, 76, 709, 1312, -1078, 728, -1078, -1078, 730, 1378, -1078, -1078, 564, 188, -1078, 882, 2515, 1365, -1078, 834, 882, 1365, -1078, 2149, 2415, 644, -1078, 2453, -1078, 2187, 2515, 1365, -1078, 641, -1078, 40, 831, 371, 2515, 1365, 744, 339, 1365, -1078, -1078, -1078, -1078, 731, 734, 1312, 737, 651, 2305, -1078, -1078, 2283, 1668, -1078, -1078, 764, 764, 750, 388, 2187, 740, 88, -1078, 1585, 1348, -1078, 1312, -1078, 1214, 840, -1078, 523, -1078, 608, -1078, 664, 671, 666, -1078, -1078, -1078, 1365, 882, -1078, -1078, -1078, -1078, -1078, 672, 1257, -1078, -1078, -1078, 882, -1078, -1078, -1078, -1078, 752, 755, 683, -1078, 685, -1078, -1078, -1078, -1078, -1078, 688, -1078, -1078, -1078, 689, 61, 1257, -1078, -1078, -1078, 1348, 692, 386, 608, -1078, -1078, -1078, 686, -1078, 698, 705, 447, 707, 739, 0, 1585, -1078, -1078, -1078, -1078, 1585, 1585, 703, 1585, 1585, 1585, 1585, 1585, -1078, 708, 1365, 1585, -1078, 767, 748, 608, 2431, 845, 772, -1078, -1078, 723, 431, 2187, -1078, 724, 902, -1078, 868, -1078, 788, 713, -1078, 1585, 728, -1078, 1378, 1312, -1078, -1078, 732, 882, 792, 794, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -1078, 795, 796, 797, 800, 882, -1078, 807, 727, 733, -1078, 882, 738, -1078, 2453, -1078, -1078, 608, 735, 745, -1078, 388, 694, -1078, 40, 225, 1312, -1078, 431, 1312, 810, -1078, -1078, 741, 747, 1365, -1078, 811, 751, 392, 2187, 1585, 831, 1365, -1078, 440, -1078, 486, 1365, -1078, 1668, 490, 898, -1078, -1078, 813, -1078, 174, 1585, 763, 534, 764, -1078, 213, 1496, -1078, 492, -1078, -1078, -1078, -1078, 818, 753, 819, 726, 2187, 1312, -1078, -1078, -1078, -1078, -1078, 756, 822, 692, -1078, -1078, -1078, -1078, 2103, -1078, -1078, -1078, 0, 0, 0, -1078, 72, 939, -1078, 0, 0, 0, 0, -1078, 759, 0, 1585, 2187, 772, 882, -1078, -1078, -1078, 608, -1078, 760, -1078, 388, -1078, -1078, 0, -1078, -1078, -1078, 1824, 2515, -1078, 837, -1078, -1078, 2415, 838, -1078, 842, 835, 191, 776, -1078, -1078, 329, -1078, 2187, 831, 810, 768, -1078, 841, -1078, 751, 2187, -1078, -1078, -1078, -1078, -1078, -1078, 2453, 608, 0, -1078, 737, -1078, 847, 777, -1078, 850, -1078, 1585, 858, 0, -1078, 2187, 2187, 2187, 2187, -1078, -1078, 1585, 2187, 840, -1078, -1078, 2453, 564, 2187, 2187, -1078, 608, 755, 1585, 1585, -1078, 859, 1348, 1585, -1078, -1078, 774, 608, -1078, 882, -1078, 788, -1078, 807, 882, -1078, 2187, 2187, 388, -1078, 388, -1078, -1078, 860, 240, -1078, -1078, 2187, 771, 371, -1078, 608, 803, -1078, -1078, -1078, -1078, 1585, 0, 1585, 608, 608, 608, 608, 534, 294, -1078, 805, -1078, 865, -1078, 438, -1078, 798, 344, 1348, 692, 939, -1078, -1078, -1078, 882, 608, 608, 835, 799, -1078, 991, -1078, 806, -1078, -1078, -1078, 0, 0, -1078, 1585, -1078, 2187, -1078, -1078, -1078, 447, -1078, -1078, -1078, -1078, -1078, 534, 363, -1078, -1078, 2187, 2187, 801, 363, 363, -1078, -1078, -1078 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { -1078, -1078, -1078, 618, -1078, -1078, -1078, -1078, -1078, -1078, 848, -3, 401, 422, -5, -266, -1078, -124, -1078, 184, -346, -519, -1078, -65, -1078, 418, 615, -680, 398, 4, -180, -1078, 7, -411, 578, 1, -45, 112, -1078, -854, -321, -515, -312, -150, 1035, 699, 399, 539, -686, 111, -1078, 886, -1078, -143, 425, -379, -567, -271, 207, -141, -1078, -75, 42, -1078, 14, -46, -54, -1078, 489, -95, 178, -47, -26, -726, -66, -618, 404, -61, -50, -148, -1078, 530, -484, 354, -677, -1078, 277, 129, 2, -473, -86, 289, 106, 304, 117, 303, 119, -750, -901, -1078, -334, -1078, -82, 118, -88, -905, 310, 109, -1078, 356, 192, -59, -58, -101, -1078, 133, -1078, -756, -902, -1078, 966, -1078, -1077, -408, -132, -1078, 417, -247, 236, 830, -108, -1078, -269, -1078, 123, 161, -56, -87, -52, -1078, 809, -306, -512, 410, 504, -1078, -1078, -1078, -1078, -1078, -1078, -1078, -140, 453, -92, -1078, -41, -70, -18, -1078, -67, -1078, 413, 603, -625, 408, -1078, -685, -1078, -1078, 116, 485, 5, -1078, -1078, 480, 1045, -1078, -720, -1078, -4, -1078, 407, -319, -485, -569, -751, 141, 26, -754, 345, 148, -1078, 996, -1078, -333, 762, -1078, 63, -343, -1078, -1078, 35, -6, -1078 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which number is the opposite. If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -552 static const yytype_int16 yytable[] = { 76, 204, 177, 629, 211, 298, 265, 218, 269, 30, 538, 273, 274, 566, 207, 207, 309, 559, 724, 79, 517, 207, 210, 300, 219, 557, 271, 245, 220, 271, 550, 597, 527, 600, 530, 226, 227, 635, 602, 571, 900, 317, 752, 937, 419, 458, 519, 665, 523, 524, 905, 946, 727, 815, 824, 825, 919, 1000, 1004, 284, 285, 561, 76, 76, 76, 76, 76, 632, 76, 840, 76, 1073, 1017, 1015, 1016, 55, 76, 76, 791, 631, 323, 791, 333, 791, 933, 212, 771, 1108, 945, 55, 447, 318, 263, 278, 791, 284, 285, 224, 907, 1113, 225, 239, 1122, 780, 698, 1156, 587, 284, 285, 908, 915, 322, 275, 791, 543, 486, 487, 332, 312, 794, 435, 1229, 910, 230, 319, 319, 545, 179, 544, 271, 271, 433, 225, 430, 431, -551, 733, 701, 320, 320, 298, 733, 319, 298, 76, 298, 298, 428, 429, 76, 225, 298, 306, 298, 437, -172, 320, 444, 225, 76, 180, 226, 319, 270, 76, 1245, 76, 166, 319, 300, 521, 300, 188, 521, 623, 319, 320, 462, 781, 319, 677, 207, 320, 327, 624, 329, 319, 225, 467, 320, 546, 795, 474, 320, 76, 76, 181, 319, 436, 278, 320, 1180, 76, 1179, 304, 319, 305, 23, 24, 490, 1184, 320, 484, 485, 477, 629, 629, 1162, 827, 320, 457, 221, 510, 222, 625, 225, 450, 319, 665, 828, 76, 1066, 1105, 550, 886, 445, 446, 323, 207, 475, 639, 320, 494, 76, 76, 518, 788, 1111, 762, 789, 665, 770, 76, 792, 983, 76, 228, 1085, 984, 562, 278, 298, 479, 480, 1023, 1131, 299, 533, 322, 791, 791, 488, 1139, 791, 799, 661, 661, 936, 1044, 934, 228, 246, 247, 76, 1058, 942, 814, 76, 498, 225, 763, 888, 889, 503, 644, 646, 25, 758, 759, 760, 258, 259, 827, 225, 451, 898, 772, 264, 76, 26, 775, 776, 182, 225, 707, 76, 76, 478, 439, 183, 495, 440, 980, 27, 733, 542, 711, 715, 1174, 326, 995, 328, 1125, 197, 540, 228, 1009, 76, 248, 198, 249, 678, 679, 680, 802, 189, 199, 319, 190, 28, 29, 200, 1101, 701, 689, 1140, 832, 468, 690, 469, 1165, 320, 298, 694, 1101, 298, 499, 500, 921, 650, 667, 504, 645, 647, 578, 201, 1102, 1103, 655, 225, 674, 676, 1221, 704, 659, 207, 207, 202, 1102, 1103, -310, -310, 708, 191, 298, 244, 622, 508, 509, 298, 688, 691, 671, 692, 712, 716, 1175, 284, 285, 526, 207, 747, 299, 1074, 299, 457, 803, 668, 935, 903, 1203, 559, 1177, 22, 235, 629, 550, 999, 76, 928, 76, 255, 893, 225, 76, 76, 1230, 343, 1123, 76, 665, 319, 253, 76, 254, 76, 256, 649, 257, 941, 457, 457, 330, 457, 491, 320, 1084, 260, 352, 76, 896, 334, 658, 76, 897, 192, 666, 1001, 899, 319, 806, 817, 851, 298, 298, 393, 193, 362, 420, 1046, 364, 422, 883, 320, 366, 720, 721, 722, 312, 190, 312, 425, 547, 548, 215, 427, 215, 841, 432, 617, 1246, 1128, 225, 1247, 207, 618, -310, -310, 990, 582, 583, 753, 442, -310, -310, -310, 685, 225, -310, 443, 626, 319, 448, 76, 700, 701, 449, -310, 452, 76, 453, 76, 463, 729, 491, 320, 492, 665, 564, 565, 76, 464, 719, 51, 466, 576, 471, 577, 472, 298, 298, 881, 207, 76, 473, 298, 665, 298, 476, 798, 481, 298, 665, 298, 482, 298, 483, 911, 1025, 912, 913, 914, 215, 704, 791, 215, 858, 225, 844, 496, 845, 307, 298, 23, 24, 1051, 701, 215, 55, 558, 1114, 1115, 1116, 1117, 1118, 1075, 501, 851, 846, 505, 948, 76, 233, 234, 920, 973, 497, 31, 32, 238, 423, 424, 251, 252, 241, 242, 502, 653, 654, 215, 215, 506, 697, 228, 944, 665, 299, 853, 854, 528, 1093, 1252, 1253, 228, 457, 76, 215, 507, 531, 76, 532, 76, 536, 534, 539, 549, 1067, 457, 240, 558, 601, 76, 687, 228, 842, 606, 457, 616, 620, 319, 628, 636, 693, 1134, 1135, 1136, 1137, 638, 695, 640, 642, 298, 25, 320, 309, 215, 215, 643, 648, 764, 33, 652, 1036, 298, 656, 26, 657, 298, 660, 1011, 1143, 1115, 1116, 1117, 1144, 303, 76, 664, 669, 27, 675, 670, 672, 730, 731, 300, 52, 696, 699, 454, 53, 54, 681, 31, 32, 890, 215, 682, 55, 215, 686, 34, 683, 35, 36, 28, 29, 684, 709, 710, 717, 37, 38, 76, 1035, 39, 826, 298, 713, 1126, 714, 718, 725, 76, 728, 23, 24, 225, 1210, 40, 55, 744, 665, 748, 749, 750, 755, 761, 773, 1045, 768, 774, 922, 777, 778, 782, 784, 555, 555, 785, 786, 1186, 457, 57, 312, 457, 457, 796, 455, 804, 457, 572, 850, 807, 456, 578, 33, 811, 812, 76, 457, 813, 823, 944, 572, 830, 833, 848, 457, 632, 599, 1236, 184, 437, 665, 855, 860, 603, 979, 861, 864, 866, 865, 870, 873, 76, 299, 1014, 230, 874, 875, 876, 877, 76, 879, 880, 887, 34, 885, 35, 36, 701, 213, 1028, 25, 10, 11, 37, 38, 58, 732, 39, 1019, 917, 906, 738, 457, 26, 918, 930, 929, 940, 972, 882, 59, 40, 60, 457, 943, 978, 982, 27, 298, 988, 862, 61, 62, 63, 64, 997, 1007, 454, 1026, 1002, 764, 1005, 1003, 764, 827, 1030, 1011, 66, 1020, 1054, 901, 1032, 1031, 28, 29, 1034, 1070, 1037, 1163, 1038, 31, 32, 568, 568, 1040, 575, 1041, 23, 24, 1042, 1043, 1048, 55, 1069, 67, 923, 68, 985, 69, 1049, 70, 71, 72, 73, 1078, 74, 1050, 75, 1053, 1072, 1079, 76, 1080, 1155, 1082, 1160, 207, -55, 299, -56, -58, -64, -65, 1099, 1018, 1087, 455, 626, 1090, 457, 1076, 1088, 456, 990, 299, 12, 1094, 13, 14, 1112, 1129, 1130, 1109, 1146, 15, 16, 17, 1148, 457, 18, 1153, 520, 851, 33, 457, 1147, 1152, 1157, 19, 1172, 1159, 1164, 1168, 20, 21, 76, 1170, 1171, 1181, 1183, 757, 572, 572, 572, 1215, 1212, 25, 1189, 1191, 1022, 572, 1176, 1190, 76, 572, 572, 1193, 1209, 1232, 26, 1220, 1226, 298, 1231, 34, 1240, 35, 36, 1207, 1234, 1239, 619, 1120, 27, 37, 38, 1251, 1241, 39, 891, 892, 1145, 413, 454, 1169, 1141, 214, 457, 76, 839, 663, 1071, 40, 1149, 41, 843, 641, 552, 1166, 28, 29, 308, 820, 1029, 1188, 1124, 849, 1150, 1204, 847, 280, 947, 281, 1233, 282, 298, 283, 284, 285, 1055, 726, 76, 55, 457, 1056, 1057, 215, 1059, 1062, 1063, 1064, 1065, 1086, 42, 43, 1068, 904, 1214, 457, 457, 1161, 981, 971, 1095, 1091, 974, 1167, 185, 187, 1092, 1096, 1225, 455, 985, 754, 76, 1224, 1083, 456, 206, 206, 1110, 568, 76, 1106, 568, 206, 932, 223, 1218, 996, 1223, 1219, 1238, 1178, 1100, 279, 286, 895, 299, 1077, 1047, 1185, 525, 1244, 76, 76, 76, 76, 541, 902, 1127, 76, 1201, 1235, 1211, 878, 457, 76, 76, 1237, 909, 916, 800, 1194, 1195, 1196, 1197, 745, 872, 1151, 1199, 1206, 871, 457, 243, 818, 1213, 1205, 457, 1121, 76, 76, 1142, 1200, 1133, 836, 924, 555, 939, 414, 1021, 76, 634, 511, 732, 1202, 1132, 1187, 0, 1216, 1217, 0, 117, 0, 512, 0, 764, 0, 44, 45, 0, 0, 0, 0, 0, 46, 47, 48, 966, 0, 49, 0, 0, 867, 0, 457, 867, 0, 0, 50, 0, 0, 966, 0, 416, 185, 0, 0, 0, 0, 966, 280, 76, 281, 0, 282, 0, 283, 284, 285, 0, 0, 0, 55, 0, 0, 76, 76, 0, 0, 0, 1243, 1, 2, 3, 4, 5, 6, 7, 8, 0, 290, 0, 291, 0, 1249, 1250, 293, 0, 294, 295, 296, 297, 0, 0, 206, 0, 0, 213, 574, 0, 10, 11, 0, 0, 215, 0, 0, 1096, 0, 1096, 0, 0, 0, 0, 0, 1192, 0, 286, 0, 0, 0, 0, 0, 0, 0, 1198, 0, 0, 0, 215, 0, 568, 0, 0, 0, 0, 0, 818, 1208, 0, 0, 0, 1059, 0, 0, 0, 0, 0, 0, 0, 416, 206, 0, 52, 0, 42, 43, 53, 54, 0, 31, 32, 0, 0, 0, 55, 0, 0, 0, 924, 0, 0, 0, 0, 287, 0, 1227, 800, 1228, 0, 1008, 0, 0, 117, 280, 0, 281, 0, 282, 0, 283, 284, 285, 0, 0, 288, 55, 289, 1024, 0, 0, 551, 0, 554, 0, 0, 0, 0, 31, 32, 0, 0, 56, 0, 12, 1242, 13, 14, 0, 0, 57, 42, 43, 15, 16, 17, 55, 580, 18, 0, 585, 0, 0, 33, 0, 0, 0, 19, 0, 0, 0, 0, 20, 21, 0, 604, 0, 609, 611, 0, 0, 286, 290, 0, 291, 0, 292, 0, 293, 0, 294, 295, 296, 297, 0, 0, 0, 0, 0, 0, 0, 44, 45, 0, 34, 0, 35, 36, 46, 47, 48, 33, 0, 49, 37, 38, 58, 0, 39, 276, 277, 0, 50, 0, 0, 214, 651, 215, 206, 206, 0, 59, 40, 60, 0, 0, 818, 1008, 511, 0, 0, 0, 61, 62, 63, 64, 0, 117, 0, 512, 0, 0, 34, 206, 35, 36, 0, 65, 66, 0, 0, 0, 37, 38, 966, 0, 39, 44, 45, 42, 43, 0, 0, 0, 46, 47, 48, 117, 0, 49, 40, 800, 0, 0, 1107, 67, 0, 68, 50, 69, 0, 70, 71, 72, 73, 0, 74, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 290, 0, 291, 836, 0, 0, 293, 0, 294, 295, 296, 297, 0, 835, 0, 867, 0, 0, 551, 0, 280, 0, 281, 746, 282, 185, 283, 284, 285, 0, 0, 206, 55, 0, 0, 83, 0, 84, 85, 86, 87, 88, 42, 43, 89, 90, 91, 55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 93, 94, 95, 96, 97, 98, 99, 0, 0, 100, 44, 45, 0, 0, 0, 0, 101, 46, 47, 48, 206, 0, 49, 102, 0, 185, 103, 104, 286, 105, 0, 50, 0, 0, 416, 106, 107, 108, 0, 0, 0, 0, 0, 109, 0, 0, 0, 0, 0, 0, 416, 0, 185, 0, 0, 0, 0, 110, 111, 280, 0, 281, 0, 282, 0, 283, 284, 285, 112, 0, 0, 55, 0, 0, 0, 0, 0, 0, 42, 43, 0, 90, 0, 55, 0, 287, 0, 0, 0, 0, 113, 114, 0, 0, 117, 0, 0, 115, 0, 44, 45, 0, 0, 0, 0, 116, 46, 47, 48, 117, 0, 49, 0, 0, 0, 0, 0, 416, 0, 0, 50, 0, 0, 0, 0, 118, 286, 0, 0, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 0, 138, 0, 0, 551, 0, 139, 140, 141, 142, 0, 10, 11, 89, 90, 290, 0, 291, 0, 703, 0, 293, 0, 294, 295, 296, 297, 143, 144, 145, 146, 0, 0, 0, 147, 287, 148, 149, 150, 151, 152, 153, 0, 154, 117, 0, 44, 45, 580, 0, 0, 0, 585, 46, 47, 48, 117, 0, 49, 0, 0, 0, 604, 0, 0, 0, 0, 50, 0, 0, 609, 0, 0, 611, 23, 24, 0, 0, 83, 55, 84, 85, 86, 87, 88, 42, 43, 89, 90, 91, 55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 95, 96, 0, 0, 0, 0, 0, 100, 0, 290, 0, 291, 1033, 1010, 101, 293, 0, 294, 295, 296, 297, 12, 0, 13, 14, 0, 0, 0, 0, 0, 15, 16, 17, 0, 107, 18, 0, 0, 0, 951, 952, 109, 0, 0, 19, 0, 0, 0, 0, 20, 21, 0, 0, 0, 0, 0, 0, 953, 954, 25, 955, 956, 0, 0, 0, 0, 0, 957, 958, 0, 959, 960, 26, 961, 962, 0, 0, 0, 0, 416, 0, 0, 0, 0, 0, 0, 27, 0, 113, 0, 0, 0, 0, 0, 0, 115, 454, 44, 45, 0, 0, 0, 0, 116, 46, 47, 48, 117, 0, 49, 0, 0, 28, 29, 0, 0, 213, 0, 50, 10, 11, 0, 0, 118, 0, 0, 0, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 206, 138, 0, 0, 0, 0, 0, 0, 141, 142, 10, 11, 0, 611, 0, 31, 32, 0, 0, 455, 55, 416, 0, 0, 0, 456, 416, 143, 144, 145, 146, 0, 0, 0, 321, 0, 148, 149, 150, 151, 152, 153, 83, 154, 84, 85, 86, 87, 88, 42, 43, 89, 90, 91, 55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 95, 96, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 12, 33, 13, 14, 0, 0, 0, 0, 0, 15, 16, 17, 0, 213, 18, 107, 10, 11, 0, 0, 0, 0, 109, 19, 0, 0, 0, 0, 20, 21, 0, 0, 0, 0, 0, 0, 0, 12, 0, 13, 14, 923, 34, 0, 35, 36, 15, 16, 17, 0, 0, 18, 37, 38, 58, 588, 39, 589, 0, 590, 19, 591, 10, 11, 0, 20, 21, 0, 0, 113, 40, 0, 0, 0, 0, 0, 115, 0, 44, 45, 0, 214, 0, 316, 116, 46, 47, 48, 117, 0, 49, 0, 0, 52, 0, 0, 0, 53, 54, 50, 31, 32, 0, 0, 118, 55, 0, 0, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 0, 138, 0, 12, 0, 13, 14, 0, 141, 142, 0, 0, 15, 16, 17, 0, 0, 18, 0, 1154, 0, 0, 0, 0, 0, 56, 19, 143, 144, 145, 146, 20, 21, 57, 147, 0, 148, 149, 150, 151, 152, 153, 0, 154, 0, 0, 33, 0, 0, 12, 0, 13, 14, 0, 0, 0, 0, 0, 15, 16, 17, 0, 52, 18, 0, 0, 53, 54, 0, 31, 32, 0, 19, 0, 55, 0, 0, 20, 21, 0, 0, 0, 0, 592, 214, 0, 0, 34, 0, 35, 36, 42, 43, 0, 90, 0, 0, 37, 38, 58, 0, 39, 0, 0, 0, 0, 0, 0, 593, 594, 0, 0, 0, 0, 59, 40, 60, 0, 0, 0, 0, 0, 0, 0, 0, 61, 62, 63, 64, 57, 595, 975, 31, 32, 0, 0, 0, 55, 0, 0, 65, 66, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 588, 0, 589, 0, 590, 0, 591, 10, 11, 0, 0, 0, 0, 67, 0, 68, 0, 69, 0, 70, 71, 72, 73, 0, 74, 0, 75, 0, 34, 0, 35, 36, 0, 0, 0, 0, 0, 0, 37, 588, 58, 589, 39, 590, 0, 591, 10, 11, 0, 0, 33, 0, 44, 45, 0, 59, 40, 60, 0, 46, 47, 48, 10, 11, 49, 0, 61, 62, 63, 64, 0, 0, 0, 50, 0, 0, 0, 588, 0, 589, 0, 590, 66, 591, 10, 11, 0, 0, 0, 0, 0, 34, 0, 35, 36, 738, 0, 0, 0, 0, 0, 37, 38, 58, 0, 39, 0, 0, 0, 67, 0, 68, 0, 69, 0, 70, 71, 72, 73, 40, 74, 12, 75, 13, 14, 0, 0, 0, 0, 0, 15, 16, 17, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 949, 950, 0, 20, 21, 55, 0, 0, 0, 592, 0, 0, 0, 0, 12, 0, 13, 14, 0, 976, 0, 0, 0, 15, 16, 17, 0, 0, 18, 0, 12, 0, 13, 14, 593, 594, 0, 19, 0, 15, 16, 17, 20, 21, 18, 0, 0, 0, 592, 0, 0, 809, 12, 19, 13, 14, 595, 0, 20, 21, 0, 15, 16, 17, 0, 0, 18, 0, 0, 951, 952, 0, 0, 593, 594, 19, 0, 0, 0, 0, 20, 21, 0, 0, 0, 0, 592, 953, 954, 25, 955, 956, 0, 0, 0, 595, 0, 957, 958, 0, 959, 960, 26, 961, 962, 0, 0, 0, 0, 0, 0, 593, 594, 0, 12, 0, 963, 14, 0, 0, 0, 0, 0, 15, 16, 17, 454, 0, 18, 0, 0, 42, 43, 595, 0, 394, 0, 19, 0, 0, 0, 0, 964, 965, 0, 0, 0, 0, 336, 337, 338, 339, 340, 341, 42, 43, 342, 0, 0, 0, 0, 0, 0, 0, 0, 395, 344, 0, 345, 346, 347, 348, 349, 350, 0, 0, 396, 0, 0, 351, 397, 0, 398, 399, 0, 0, 400, 0, 401, 0, 353, 354, 355, 0, 0, 455, 402, 357, 358, 359, 0, 456, 360, 567, 361, 0, 363, 403, 404, 365, 0, 0, 405, 0, 0, 0, 0, 367, 368, 369, 0, 370, 371, 0, 372, 0, 570, 373, 0, 0, 0, 0, 0, 406, 407, 408, 409, 375, 0, 0, 376, 0, 0, 0, 0, 0, 0, 44, 45, 0, 0, 0, 0, 0, 46, 47, 48, 0, 0, 49, 0, 0, 0, 0, 0, 0, 0, 0, 50, 0, 44, 45, 0, 0, 0, 0, 0, 46, 47, 48, 0, 0, 49, 0, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 377, 378, 335, 0, 0, 0, 0, 379, 380, 381, 382, 410, 384, 0, 385, 336, 337, 338, 339, 340, 341, 0, 0, 342, 0, 0, 0, 0, 0, 0, 0, 0, 343, 344, 0, 345, 346, 347, 348, 349, 350, 0, 0, 0, 0, 0, 351, 0, 0, 0, 0, 0, 0, 352, 0, 0, 0, 353, 354, 355, 0, 0, 0, 356, 357, 358, 359, 0, 0, 360, 0, 361, 362, 363, 0, 364, 365, 0, 0, 366, 0, 0, 0, 0, 367, 368, 369, 0, 370, 371, 0, 372, 0, 0, 373, 0, 0, 0, 0, 0, 374, 0, 0, 0, 375, 0, 0, 376, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 377, 378, 0, 0, 0, 0, 0, 379, 380, 381, 382, 383, 384, 0, 385 }; #define yypact_value_is_default(yystate) \ ((yystate) == (-1078)) #define yytable_value_is_error(yytable_value) \ YYID (0) static const yytype_int16 yycheck[] = { 5, 67, 8, 411, 70, 155, 146, 73, 148, 2, 316, 151, 152, 356, 68, 69, 159, 351, 530, 5, 291, 75, 69, 155, 74, 346, 150, 119, 75, 153, 342, 377, 301, 379, 303, 81, 82, 416, 384, 358, 720, 165, 557, 763, 185, 225, 293, 458, 295, 296, 727, 777, 536, 620, 623, 624, 741, 807, 814, 19, 20, 16, 67, 68, 69, 70, 71, 413, 73, 636, 75, 925, 826, 824, 825, 24, 81, 82, 597, 412, 167, 600, 174, 602, 20, 71, 571, 992, 774, 24, 214, 11, 144, 154, 613, 19, 20, 11, 55, 1000, 139, 107, 1004, 139, 512, 33, 372, 19, 20, 55, 735, 167, 153, 632, 103, 255, 256, 173, 164, 142, 137, 1198, 124, 139, 125, 125, 78, 0, 78, 253, 254, 138, 139, 199, 200, 151, 544, 139, 139, 139, 290, 549, 125, 293, 149, 295, 296, 197, 198, 154, 139, 301, 157, 303, 138, 139, 139, 137, 139, 164, 11, 207, 125, 149, 169, 1242, 171, 6, 125, 301, 294, 303, 18, 297, 81, 125, 139, 140, 214, 125, 219, 235, 139, 169, 91, 171, 125, 139, 235, 139, 330, 214, 141, 139, 199, 200, 11, 125, 215, 260, 139, 1106, 207, 1105, 139, 125, 141, 19, 20, 261, 1111, 139, 253, 254, 215, 623, 624, 1071, 128, 139, 225, 139, 288, 141, 136, 139, 137, 125, 639, 139, 235, 916, 988, 545, 217, 215, 217, 324, 292, 244, 420, 139, 137, 248, 249, 292, 592, 997, 567, 595, 661, 570, 257, 599, 214, 260, 95, 943, 218, 214, 321, 411, 248, 249, 833, 1019, 155, 313, 324, 788, 789, 257, 1023, 792, 607, 455, 456, 762, 217, 215, 119, 120, 121, 288, 909, 770, 619, 292, 137, 139, 214, 699, 700, 137, 137, 137, 108, 563, 564, 565, 139, 140, 128, 139, 215, 713, 572, 146, 313, 121, 576, 577, 11, 139, 137, 320, 321, 215, 137, 11, 215, 140, 795, 135, 732, 103, 137, 137, 137, 168, 803, 170, 1009, 218, 320, 174, 820, 342, 216, 218, 218, 481, 482, 483, 142, 16, 214, 125, 19, 161, 162, 214, 139, 139, 494, 142, 142, 157, 498, 159, 1080, 139, 512, 503, 139, 515, 215, 217, 747, 435, 462, 215, 215, 215, 367, 18, 163, 164, 444, 139, 472, 217, 142, 515, 450, 439, 440, 18, 163, 164, 19, 20, 215, 64, 544, 18, 402, 286, 287, 549, 492, 214, 468, 216, 215, 215, 215, 19, 20, 298, 464, 552, 301, 928, 303, 420, 214, 464, 761, 725, 1146, 755, 1102, 1, 218, 833, 738, 806, 433, 750, 435, 214, 703, 139, 439, 440, 142, 43, 1005, 444, 851, 125, 218, 448, 218, 450, 214, 433, 214, 768, 455, 456, 214, 458, 138, 139, 941, 218, 64, 464, 707, 11, 448, 468, 711, 136, 459, 810, 715, 125, 611, 621, 652, 623, 624, 11, 147, 83, 139, 887, 86, 141, 138, 139, 90, 150, 151, 152, 534, 19, 536, 138, 331, 332, 72, 144, 74, 638, 78, 105, 137, 1013, 139, 140, 558, 111, 135, 136, 137, 18, 19, 558, 217, 142, 143, 144, 138, 139, 147, 219, 409, 125, 142, 528, 138, 139, 219, 156, 219, 534, 217, 536, 56, 539, 138, 139, 140, 948, 354, 355, 545, 216, 528, 4, 151, 361, 151, 363, 67, 699, 700, 691, 606, 558, 151, 705, 967, 707, 215, 606, 214, 711, 973, 713, 214, 715, 214, 151, 837, 153, 154, 155, 150, 705, 1093, 153, 138, 139, 644, 215, 646, 159, 732, 19, 20, 138, 139, 165, 24, 218, 198, 199, 200, 201, 202, 929, 142, 777, 648, 217, 780, 606, 98, 99, 744, 785, 219, 19, 20, 105, 192, 193, 123, 124, 110, 111, 219, 439, 440, 197, 198, 219, 511, 462, 774, 1036, 515, 653, 654, 139, 976, 1249, 1250, 472, 639, 640, 214, 137, 139, 644, 217, 646, 156, 138, 218, 128, 917, 652, 109, 218, 18, 656, 491, 492, 640, 218, 661, 18, 218, 125, 18, 138, 501, 129, 130, 131, 132, 215, 507, 151, 219, 821, 108, 139, 817, 253, 254, 219, 218, 568, 92, 139, 862, 833, 216, 121, 215, 837, 18, 821, 198, 199, 200, 201, 202, 156, 701, 141, 214, 135, 139, 219, 214, 542, 543, 837, 12, 158, 33, 145, 16, 17, 219, 19, 20, 701, 294, 219, 24, 297, 219, 133, 215, 135, 136, 161, 162, 215, 217, 219, 217, 143, 144, 738, 858, 147, 625, 887, 142, 1010, 219, 219, 216, 748, 144, 19, 20, 139, 1156, 161, 24, 140, 1163, 139, 142, 32, 32, 67, 217, 883, 32, 128, 748, 142, 32, 32, 142, 345, 346, 139, 32, 1114, 777, 79, 820, 780, 781, 32, 214, 32, 785, 359, 218, 32, 220, 778, 92, 140, 18, 794, 795, 18, 67, 943, 372, 32, 32, 215, 803, 1145, 378, 1209, 214, 138, 1215, 215, 215, 385, 794, 141, 215, 217, 215, 158, 56, 820, 705, 823, 139, 215, 215, 215, 18, 828, 215, 215, 33, 133, 215, 135, 136, 139, 16, 839, 108, 19, 20, 143, 144, 145, 137, 147, 828, 214, 219, 137, 851, 121, 151, 78, 219, 142, 18, 692, 160, 161, 162, 862, 128, 215, 219, 135, 1012, 32, 138, 171, 172, 173, 174, 125, 219, 145, 32, 142, 763, 138, 142, 766, 128, 215, 1012, 187, 142, 144, 723, 219, 215, 161, 162, 217, 142, 139, 1072, 138, 19, 20, 357, 358, 215, 360, 215, 19, 20, 215, 215, 219, 24, 140, 214, 137, 216, 800, 218, 215, 220, 221, 222, 223, 16, 225, 215, 227, 215, 78, 56, 930, 138, 1051, 215, 1069, 984, 139, 821, 139, 139, 139, 139, 984, 827, 139, 214, 830, 215, 948, 930, 138, 220, 137, 837, 133, 215, 135, 136, 142, 56, 142, 215, 139, 142, 143, 144, 142, 967, 147, 142, 149, 1146, 92, 973, 216, 214, 32, 156, 138, 215, 215, 139, 161, 162, 984, 142, 139, 214, 142, 562, 563, 564, 565, 1168, 215, 108, 144, 142, 832, 572, 219, 219, 1002, 576, 577, 142, 142, 137, 121, 144, 202, 1156, 202, 133, 18, 135, 136, 1152, 215, 215, 397, 1002, 135, 143, 144, 219, 215, 147, 148, 149, 1028, 178, 145, 1093, 1025, 214, 1036, 1037, 632, 456, 923, 161, 1036, 3, 641, 425, 342, 1087, 161, 162, 159, 621, 840, 1123, 1007, 651, 1037, 1147, 649, 12, 778, 14, 1205, 16, 1209, 18, 19, 20, 902, 534, 1070, 24, 1072, 907, 908, 648, 910, 911, 912, 913, 914, 947, 19, 20, 918, 726, 1167, 1087, 1088, 1070, 796, 782, 981, 971, 786, 1088, 56, 57, 974, 983, 1183, 214, 986, 559, 1104, 1182, 940, 220, 68, 69, 996, 567, 1112, 990, 570, 75, 755, 77, 1172, 804, 1181, 1174, 1218, 1104, 986, 154, 79, 705, 1012, 932, 889, 1112, 297, 1236, 1134, 1135, 1136, 1137, 324, 724, 1012, 1141, 1143, 1208, 1157, 687, 1146, 1147, 1148, 1211, 732, 738, 608, 1134, 1135, 1136, 1137, 549, 673, 1038, 1141, 1151, 672, 1163, 114, 621, 1165, 1148, 1168, 1003, 1170, 1171, 1026, 1142, 1021, 631, 749, 750, 766, 178, 830, 1181, 415, 136, 137, 1145, 1020, 1119, -1, 1170, 1171, -1, 145, -1, 147, -1, 1080, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, 781, -1, 147, -1, -1, 669, -1, 1215, 672, -1, -1, 156, -1, -1, 795, -1, 184, 185, -1, -1, -1, -1, 803, 12, 1232, 14, -1, 16, -1, 18, 19, 20, -1, -1, -1, 24, -1, -1, 1246, 1247, -1, -1, -1, 1232, 3, 4, 5, 6, 7, 8, 9, 10, -1, 214, -1, 216, -1, 1246, 1247, 220, -1, 222, 223, 224, 225, -1, -1, 235, -1, -1, 16, 216, -1, 19, 20, -1, -1, 858, -1, -1, 1172, -1, 1174, -1, -1, -1, -1, -1, 1130, -1, 79, -1, -1, -1, -1, -1, -1, -1, 1140, -1, -1, -1, 883, -1, 768, -1, -1, -1, -1, -1, 774, 1153, -1, -1, -1, 1157, -1, -1, -1, -1, -1, -1, -1, 291, 292, -1, 12, -1, 19, 20, 16, 17, -1, 19, 20, -1, -1, -1, 24, -1, -1, -1, 923, -1, -1, -1, -1, 136, -1, 1191, 814, 1193, -1, 817, -1, -1, 145, 12, -1, 14, -1, 16, -1, 18, 19, 20, -1, -1, 157, 24, 159, 835, -1, -1, 342, -1, 344, -1, -1, -1, -1, 19, 20, -1, -1, 71, -1, 133, 1230, 135, 136, -1, -1, 79, 19, 20, 142, 143, 144, 24, 368, 147, -1, 371, -1, -1, 92, -1, -1, -1, 156, -1, -1, -1, -1, 161, 162, -1, 386, -1, 388, 389, -1, -1, 79, 214, -1, 216, -1, 218, -1, 220, -1, 222, 223, 224, 225, -1, -1, -1, -1, -1, -1, -1, 135, 136, -1, 133, -1, 135, 136, 142, 143, 144, 92, -1, 147, 143, 144, 145, -1, 147, 148, 149, -1, 156, -1, -1, 214, 437, 1051, 439, 440, -1, 160, 161, 162, -1, -1, 943, 944, 136, -1, -1, -1, 171, 172, 173, 174, -1, 145, -1, 147, -1, -1, 133, 464, 135, 136, -1, 186, 187, -1, -1, -1, 143, 144, 1088, -1, 147, 135, 136, 19, 20, -1, -1, -1, 142, 143, 144, 145, -1, 147, 161, 988, -1, -1, 991, 214, -1, 216, 156, 218, -1, 220, 221, 222, 223, -1, 225, -1, 227, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 214, -1, 216, 1026, -1, -1, 220, -1, 222, 223, 224, 225, -1, 79, -1, 1038, -1, -1, 545, -1, 12, -1, 14, 550, 16, 552, 18, 19, 20, -1, -1, 558, 24, -1, -1, 12, -1, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 35, 36, 37, 38, 39, 40, 41, 42, -1, -1, 45, 135, 136, -1, -1, -1, -1, 52, 142, 143, 144, 606, -1, 147, 59, -1, 611, 62, 63, 79, 65, -1, 156, -1, -1, 620, 71, 72, 73, -1, -1, -1, -1, -1, 79, -1, -1, -1, -1, -1, -1, 636, -1, 638, -1, -1, -1, -1, 93, 94, 12, -1, 14, -1, 16, -1, 18, 19, 20, 104, -1, -1, 24, -1, -1, -1, -1, -1, -1, 19, 20, -1, 22, -1, 24, -1, 136, -1, -1, -1, -1, 126, 127, -1, -1, 145, -1, -1, 133, -1, 135, 136, -1, -1, -1, -1, 141, 142, 143, 144, 145, -1, 147, -1, -1, -1, -1, -1, 703, -1, -1, 156, -1, -1, -1, -1, 161, 79, -1, -1, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, -1, 185, -1, -1, 738, -1, 190, 191, 192, 193, -1, 19, 20, 21, 22, 214, -1, 216, -1, 218, -1, 220, -1, 222, 223, 224, 225, 211, 212, 213, 214, -1, -1, -1, 218, 136, 220, 221, 222, 223, 224, 225, -1, 227, 145, -1, 135, 136, 782, -1, -1, -1, 786, 142, 143, 144, 145, -1, 147, -1, -1, -1, 796, -1, -1, -1, -1, 156, -1, -1, 804, -1, -1, 807, 19, 20, -1, -1, 12, 24, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 38, 39, -1, -1, -1, -1, -1, 45, -1, 214, -1, 216, 850, 218, 52, 220, -1, 222, 223, 224, 225, 133, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, 72, 147, -1, -1, -1, 88, 89, 79, -1, -1, 156, -1, -1, -1, -1, 161, 162, -1, -1, -1, -1, -1, -1, 106, 107, 108, 109, 110, -1, -1, -1, -1, -1, 116, 117, -1, 119, 120, 121, 122, 123, -1, -1, -1, -1, 917, -1, -1, -1, -1, -1, -1, 135, -1, 126, -1, -1, -1, -1, -1, -1, 133, 145, 135, 136, -1, -1, -1, -1, 141, 142, 143, 144, 145, -1, 147, -1, -1, 161, 162, -1, -1, 16, -1, 156, 19, 20, -1, -1, 161, -1, -1, -1, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 984, 185, -1, -1, -1, -1, -1, -1, 192, 193, 19, 20, -1, 997, -1, 19, 20, -1, -1, 214, 24, 1005, -1, -1, -1, 220, 1010, 211, 212, 213, 214, -1, -1, -1, 218, -1, 220, 221, 222, 223, 224, 225, 12, 227, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 38, 39, -1, -1, -1, -1, -1, 45, -1, -1, -1, -1, -1, -1, 52, -1, -1, -1, -1, 133, 92, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, 16, 147, 72, 19, 20, -1, -1, -1, -1, 79, 156, -1, -1, -1, -1, 161, 162, -1, -1, -1, -1, -1, -1, -1, 133, -1, 135, 136, 137, 133, -1, 135, 136, 142, 143, 144, -1, -1, 147, 143, 144, 145, 12, 147, 14, -1, 16, 156, 18, 19, 20, -1, 161, 162, -1, -1, 126, 161, -1, -1, -1, -1, -1, 133, -1, 135, 136, -1, 214, -1, 216, 141, 142, 143, 144, 145, -1, 147, -1, -1, 12, -1, -1, -1, 16, 17, 156, 19, 20, -1, -1, 161, 24, -1, -1, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, -1, 185, -1, 133, -1, 135, 136, -1, 192, 193, -1, -1, 142, 143, 144, -1, -1, 147, -1, 149, -1, -1, -1, -1, -1, 71, 156, 211, 212, 213, 214, 161, 162, 79, 218, -1, 220, 221, 222, 223, 224, 225, -1, 227, -1, -1, 92, -1, -1, 133, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, 12, 147, -1, -1, 16, 17, -1, 19, 20, -1, 156, -1, 24, -1, -1, 161, 162, -1, -1, -1, -1, 167, 214, -1, -1, 133, -1, 135, 136, 19, 20, -1, 22, -1, -1, 143, 144, 145, -1, 147, -1, -1, -1, -1, -1, -1, 192, 193, -1, -1, -1, -1, 160, 161, 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, 79, 214, 215, 19, 20, -1, -1, -1, 24, -1, -1, 186, 187, 92, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 12, -1, 14, -1, 16, -1, 18, 19, 20, -1, -1, -1, -1, 214, -1, 216, -1, 218, -1, 220, 221, 222, 223, -1, 225, -1, 227, -1, 133, -1, 135, 136, -1, -1, -1, -1, -1, -1, 143, 12, 145, 14, 147, 16, -1, 18, 19, 20, -1, -1, 92, -1, 135, 136, -1, 160, 161, 162, -1, 142, 143, 144, 19, 20, 147, -1, 171, 172, 173, 174, -1, -1, -1, 156, -1, -1, -1, 12, -1, 14, -1, 16, 187, 18, 19, 20, -1, -1, -1, -1, -1, 133, -1, 135, 136, 137, -1, -1, -1, -1, -1, 143, 144, 145, -1, 147, -1, -1, -1, 214, -1, 216, -1, 218, -1, 220, 221, 222, 223, 161, 225, 133, 227, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, -1, 147, -1, -1, -1, -1, -1, -1, -1, -1, 156, -1, 19, 20, -1, 161, 162, 24, -1, -1, -1, 167, -1, -1, -1, -1, 133, -1, 135, 136, -1, 138, -1, -1, -1, 142, 143, 144, -1, -1, 147, -1, 133, -1, 135, 136, 192, 193, -1, 156, -1, 142, 143, 144, 161, 162, 147, -1, -1, -1, 167, -1, -1, 209, 133, 156, 135, 136, 214, -1, 161, 162, -1, 142, 143, 144, -1, -1, 147, -1, -1, 88, 89, -1, -1, 192, 193, 156, -1, -1, -1, -1, 161, 162, -1, -1, -1, -1, 167, 106, 107, 108, 109, 110, -1, -1, -1, 214, -1, 116, 117, -1, 119, 120, 121, 122, 123, -1, -1, -1, -1, -1, -1, 192, 193, -1, 133, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, 145, -1, 147, -1, -1, 19, 20, 214, -1, 13, -1, 156, -1, -1, -1, -1, 161, 162, -1, -1, -1, -1, 26, 27, 28, 29, 30, 31, 19, 20, 34, -1, -1, -1, -1, -1, -1, -1, -1, 43, 44, -1, 46, 47, 48, 49, 50, 51, -1, -1, 54, -1, -1, 57, 58, -1, 60, 61, -1, -1, 64, -1, 66, -1, 68, 69, 70, -1, -1, 214, 74, 75, 76, 77, -1, 220, 80, 91, 82, -1, 84, 85, 86, 87, -1, -1, 90, -1, -1, -1, -1, 95, 96, 97, -1, 99, 100, -1, 102, -1, 91, 105, -1, -1, -1, -1, -1, 111, 112, 113, 114, 115, -1, -1, 118, -1, -1, -1, -1, -1, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, -1, 147, -1, -1, -1, -1, -1, -1, -1, -1, 156, -1, 135, 136, -1, -1, -1, -1, -1, 142, 143, 144, -1, -1, 147, -1, -1, -1, -1, -1, -1, -1, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 196, 197, 13, -1, -1, -1, -1, 203, 204, 205, 206, 207, 208, -1, 210, 26, 27, 28, 29, 30, 31, -1, -1, 34, -1, -1, -1, -1, -1, -1, -1, -1, 43, 44, -1, 46, 47, 48, 49, 50, 51, -1, -1, -1, -1, -1, 57, -1, -1, -1, -1, -1, -1, 64, -1, -1, -1, 68, 69, 70, -1, -1, -1, 74, 75, 76, 77, -1, -1, 80, -1, 82, 83, 84, -1, 86, 87, -1, -1, 90, -1, -1, -1, -1, 95, 96, 97, -1, 99, 100, -1, 102, -1, -1, 105, -1, -1, -1, -1, -1, 111, -1, -1, -1, 115, -1, -1, 118, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 196, 197, -1, -1, -1, -1, -1, 203, 204, 205, 206, 207, 208, -1, 210 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing symbol of state STATE-NUM. */ static const yytype_uint16 yystos[] = { 0, 3, 4, 5, 6, 7, 8, 9, 10, 248, 19, 20, 133, 135, 136, 142, 143, 144, 147, 156, 161, 162, 260, 19, 20, 108, 121, 135, 161, 162, 279, 19, 20, 92, 133, 135, 136, 143, 144, 147, 161, 291, 19, 20, 135, 136, 142, 143, 144, 147, 156, 294, 12, 16, 17, 24, 71, 79, 145, 160, 162, 171, 172, 173, 174, 186, 187, 214, 216, 218, 220, 221, 222, 223, 225, 227, 261, 289, 291, 311, 312, 313, 314, 12, 14, 15, 16, 17, 18, 21, 22, 23, 35, 36, 37, 38, 39, 40, 41, 42, 45, 52, 59, 62, 63, 65, 71, 72, 73, 79, 93, 94, 104, 126, 127, 133, 141, 145, 161, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 185, 190, 191, 192, 193, 211, 212, 213, 214, 218, 220, 221, 222, 223, 224, 225, 227, 255, 256, 261, 263, 290, 294, 298, 299, 300, 301, 368, 382, 383, 392, 393, 394, 395, 396, 397, 398, 446, 447, 450, 451, 0, 11, 11, 11, 11, 214, 291, 306, 291, 18, 16, 19, 64, 136, 147, 272, 273, 274, 218, 218, 214, 214, 18, 18, 311, 321, 324, 291, 313, 317, 318, 318, 321, 311, 16, 214, 260, 264, 325, 321, 325, 318, 139, 141, 291, 11, 139, 312, 312, 382, 401, 139, 391, 422, 391, 391, 218, 415, 423, 391, 450, 294, 391, 391, 423, 18, 401, 382, 382, 216, 218, 315, 315, 315, 218, 218, 214, 214, 214, 382, 382, 218, 384, 385, 385, 382, 399, 402, 450, 382, 399, 311, 264, 403, 399, 399, 403, 148, 149, 324, 367, 12, 14, 16, 18, 19, 20, 79, 136, 157, 159, 214, 216, 218, 220, 222, 223, 224, 225, 290, 296, 371, 378, 379, 294, 139, 141, 261, 260, 298, 300, 388, 399, 312, 327, 328, 329, 216, 264, 11, 125, 139, 218, 383, 384, 386, 387, 382, 311, 382, 311, 214, 424, 383, 401, 11, 13, 26, 27, 28, 29, 30, 31, 34, 43, 44, 46, 47, 48, 49, 50, 51, 57, 64, 68, 69, 70, 74, 75, 76, 77, 80, 82, 83, 84, 86, 87, 90, 95, 96, 97, 99, 100, 102, 105, 111, 115, 118, 196, 197, 203, 204, 205, 206, 207, 208, 210, 249, 250, 251, 252, 257, 440, 444, 11, 13, 43, 54, 58, 60, 61, 64, 66, 74, 85, 86, 90, 111, 112, 113, 114, 207, 253, 254, 257, 440, 448, 291, 303, 304, 306, 139, 302, 141, 272, 272, 138, 275, 144, 325, 325, 321, 321, 78, 138, 323, 137, 215, 138, 293, 137, 140, 319, 217, 219, 137, 215, 217, 264, 142, 219, 137, 215, 219, 217, 145, 214, 220, 261, 277, 278, 279, 280, 140, 56, 216, 421, 151, 318, 157, 159, 416, 151, 67, 151, 141, 261, 215, 215, 215, 311, 311, 214, 214, 214, 403, 403, 399, 399, 311, 367, 385, 138, 140, 400, 137, 215, 215, 219, 137, 215, 217, 142, 219, 137, 215, 217, 219, 137, 296, 296, 321, 136, 147, 296, 370, 371, 374, 304, 318, 374, 149, 264, 376, 374, 374, 376, 296, 379, 139, 389, 379, 139, 217, 312, 138, 330, 156, 331, 388, 218, 311, 387, 103, 103, 78, 78, 399, 382, 382, 128, 289, 291, 292, 346, 291, 260, 287, 287, 218, 347, 356, 16, 214, 266, 266, 266, 446, 91, 294, 430, 91, 430, 260, 262, 216, 294, 266, 266, 279, 333, 291, 340, 18, 19, 265, 291, 342, 262, 12, 14, 16, 18, 167, 192, 193, 214, 260, 267, 268, 260, 267, 18, 267, 260, 291, 338, 218, 441, 442, 291, 353, 291, 344, 267, 445, 443, 18, 105, 111, 250, 218, 309, 450, 81, 91, 136, 296, 437, 18, 370, 432, 442, 267, 449, 443, 302, 138, 305, 215, 277, 151, 273, 219, 219, 137, 215, 137, 215, 218, 311, 321, 291, 139, 317, 317, 321, 216, 215, 311, 321, 18, 277, 281, 281, 141, 280, 279, 401, 318, 214, 219, 321, 214, 420, 401, 139, 217, 219, 399, 399, 399, 219, 219, 215, 215, 138, 219, 382, 401, 399, 399, 214, 216, 382, 399, 382, 158, 296, 370, 33, 138, 139, 375, 218, 371, 372, 373, 137, 215, 217, 219, 137, 215, 142, 219, 137, 215, 217, 219, 311, 150, 151, 152, 390, 389, 216, 328, 329, 144, 450, 382, 382, 137, 370, 408, 409, 410, 411, 137, 292, 310, 412, 413, 414, 140, 410, 291, 306, 139, 142, 32, 288, 288, 318, 294, 32, 357, 260, 262, 262, 262, 67, 430, 214, 296, 425, 428, 429, 32, 431, 430, 431, 262, 217, 128, 262, 262, 142, 32, 334, 139, 214, 32, 341, 142, 139, 32, 343, 267, 267, 269, 268, 267, 271, 142, 214, 32, 339, 318, 442, 294, 364, 142, 214, 32, 354, 306, 32, 345, 209, 259, 140, 18, 18, 442, 303, 307, 290, 294, 295, 301, 332, 439, 67, 432, 432, 296, 128, 139, 436, 32, 438, 142, 32, 433, 79, 294, 297, 434, 259, 303, 306, 311, 275, 321, 321, 325, 323, 215, 293, 218, 277, 320, 319, 319, 215, 316, 321, 138, 326, 215, 141, 138, 282, 215, 215, 217, 294, 417, 418, 158, 418, 422, 56, 215, 215, 215, 18, 400, 215, 215, 399, 382, 138, 404, 215, 217, 33, 370, 370, 311, 148, 149, 304, 366, 373, 374, 374, 370, 374, 274, 382, 390, 388, 330, 331, 219, 55, 55, 409, 124, 151, 153, 154, 155, 411, 412, 214, 151, 414, 399, 302, 311, 137, 260, 284, 285, 286, 287, 219, 78, 349, 356, 20, 215, 446, 431, 425, 426, 429, 142, 430, 431, 128, 290, 295, 320, 333, 277, 19, 20, 88, 89, 106, 107, 109, 110, 116, 117, 119, 120, 122, 123, 135, 161, 162, 260, 277, 283, 335, 336, 340, 18, 277, 342, 215, 138, 270, 215, 311, 336, 338, 219, 214, 218, 296, 361, 362, 32, 365, 137, 347, 350, 351, 352, 336, 353, 125, 355, 302, 344, 446, 142, 142, 364, 138, 308, 219, 294, 329, 218, 371, 380, 381, 450, 433, 433, 436, 296, 311, 142, 437, 382, 432, 294, 379, 32, 435, 450, 305, 215, 215, 219, 291, 217, 264, 277, 139, 138, 419, 215, 215, 215, 215, 217, 264, 370, 375, 219, 215, 215, 138, 377, 215, 144, 382, 382, 382, 411, 382, 405, 406, 382, 382, 382, 382, 414, 304, 382, 140, 142, 284, 78, 286, 288, 347, 311, 357, 16, 56, 138, 427, 215, 382, 431, 295, 334, 139, 138, 337, 215, 341, 343, 267, 215, 339, 296, 358, 359, 318, 362, 139, 163, 164, 276, 364, 350, 294, 352, 215, 354, 344, 142, 345, 198, 199, 200, 201, 202, 258, 311, 382, 365, 303, 309, 331, 304, 381, 389, 56, 142, 436, 382, 438, 129, 130, 131, 132, 369, 433, 142, 276, 434, 198, 202, 258, 139, 216, 142, 282, 311, 417, 214, 142, 149, 264, 33, 32, 407, 215, 399, 311, 286, 277, 215, 425, 283, 335, 139, 270, 142, 139, 138, 360, 137, 215, 219, 274, 311, 365, 352, 214, 348, 142, 345, 311, 446, 445, 308, 144, 219, 142, 382, 142, 311, 311, 311, 311, 382, 311, 435, 450, 449, 320, 316, 311, 419, 399, 382, 142, 370, 405, 215, 427, 337, 277, 311, 311, 358, 359, 144, 142, 363, 321, 349, 351, 202, 382, 382, 369, 142, 202, 137, 326, 215, 404, 370, 407, 360, 215, 18, 215, 382, 311, 377, 369, 137, 140, 322, 311, 311, 219, 322, 322 }; #define yyerrok (yyerrstatus = 0) #define yyclearin (yychar = YYEMPTY) #define YYEMPTY (-2) #define YYEOF 0 #define YYACCEPT goto yyacceptlab #define YYABORT goto yyabortlab #define YYERROR goto yyerrorlab /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. Once GCC version 2 has supplanted version 1, this can go. However, YYFAIL appears to be in use. Nevertheless, it is formally deprecated in Bison 2.4.2's NEWS entry, where a plan to phase it out is discussed. */ #define YYFAIL goto yyerrlab #if defined YYFAIL /* This is here to suppress warnings from the GCC cpp's -Wunused-macros. Normally we don't worry about that warning, but some users do, and we want to make it easy for users to remove YYFAIL uses, which will produce warnings from Bison 2.5. */ #endif #define YYRECOVERING() (!!yyerrstatus) #define YYBACKUP(Token, Value) \ do \ if (yychar == YYEMPTY && yylen == 1) \ { \ yychar = (Token); \ yylval = (Value); \ YYPOPSTACK (1); \ goto yybackup; \ } \ else \ { \ yyerror (YY_("syntax error: cannot back up")); \ YYERROR; \ } \ while (YYID (0)) #define YYTERROR 1 #define YYERRCODE 256 /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. If N is 0, then set CURRENT to the empty location which ends the previous symbol: RHS[0] (always defined). */ #define YYRHSLOC(Rhs, K) ((Rhs)[K]) #ifndef YYLLOC_DEFAULT # define YYLLOC_DEFAULT(Current, Rhs, N) \ do \ if (YYID (N)) \ { \ (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ } \ else \ { \ (Current).first_line = (Current).last_line = \ YYRHSLOC (Rhs, 0).last_line; \ (Current).first_column = (Current).last_column = \ YYRHSLOC (Rhs, 0).last_column; \ } \ while (YYID (0)) #endif /* This macro is provided for backward compatibility. */ #ifndef YY_LOCATION_PRINT # define YY_LOCATION_PRINT(File, Loc) ((void) 0) #endif /* YYLEX -- calling `yylex' with the right arguments. */ #ifdef YYLEX_PARAM # define YYLEX yylex (YYLEX_PARAM) #else # define YYLEX yylex () #endif /* Enable debugging if requested. */ #if YYDEBUG # ifndef YYFPRINTF # include /* INFRINGES ON USER NAME SPACE */ # define YYFPRINTF fprintf # endif # define YYDPRINTF(Args) \ do { \ if (yydebug) \ YYFPRINTF Args; \ } while (YYID (0)) # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ do { \ if (yydebug) \ { \ YYFPRINTF (stderr, "%s ", Title); \ yy_symbol_print (stderr, \ Type, Value); \ YYFPRINTF (stderr, "\n"); \ } \ } while (YYID (0)) /*--------------------------------. | Print this symbol on YYOUTPUT. | `--------------------------------*/ /*ARGSUSED*/ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) #else static void yy_symbol_value_print (yyoutput, yytype, yyvaluep) FILE *yyoutput; int yytype; YYSTYPE const * const yyvaluep; #endif { if (!yyvaluep) return; # ifdef YYPRINT if (yytype < YYNTOKENS) YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); # else YYUSE (yyoutput); # endif switch (yytype) { default: break; } } /*--------------------------------. | Print this symbol on YYOUTPUT. | `--------------------------------*/ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) #else static void yy_symbol_print (yyoutput, yytype, yyvaluep) FILE *yyoutput; int yytype; YYSTYPE const * const yyvaluep; #endif { if (yytype < YYNTOKENS) YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); else YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); yy_symbol_value_print (yyoutput, yytype, yyvaluep); YYFPRINTF (yyoutput, ")"); } /*------------------------------------------------------------------. | yy_stack_print -- Print the state stack from its BOTTOM up to its | | TOP (included). | `------------------------------------------------------------------*/ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) #else static void yy_stack_print (yybottom, yytop) yytype_int16 *yybottom; yytype_int16 *yytop; #endif { YYFPRINTF (stderr, "Stack now"); for (; yybottom <= yytop; yybottom++) { int yybot = *yybottom; YYFPRINTF (stderr, " %d", yybot); } YYFPRINTF (stderr, "\n"); } # define YY_STACK_PRINT(Bottom, Top) \ do { \ if (yydebug) \ yy_stack_print ((Bottom), (Top)); \ } while (YYID (0)) /*------------------------------------------------. | Report that the YYRULE is going to be reduced. | `------------------------------------------------*/ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void yy_reduce_print (YYSTYPE *yyvsp, int yyrule) #else static void yy_reduce_print (yyvsp, yyrule) YYSTYPE *yyvsp; int yyrule; #endif { int yynrhs = yyr2[yyrule]; int yyi; unsigned long int yylno = yyrline[yyrule]; YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", yyrule - 1, yylno); /* The symbols being reduced. */ for (yyi = 0; yyi < yynrhs; yyi++) { YYFPRINTF (stderr, " $%d = ", yyi + 1); yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], &(yyvsp[(yyi + 1) - (yynrhs)]) ); YYFPRINTF (stderr, "\n"); } } # define YY_REDUCE_PRINT(Rule) \ do { \ if (yydebug) \ yy_reduce_print (yyvsp, Rule); \ } while (YYID (0)) /* Nonzero means print parse trace. It is left uninitialized so that multiple parsers can coexist. */ int yydebug; #else /* !YYDEBUG */ # define YYDPRINTF(Args) # define YY_SYMBOL_PRINT(Title, Type, Value, Location) # define YY_STACK_PRINT(Bottom, Top) # define YY_REDUCE_PRINT(Rule) #endif /* !YYDEBUG */ /* YYINITDEPTH -- initial size of the parser's stacks. */ #ifndef YYINITDEPTH # define YYINITDEPTH 200 #endif /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only if the built-in stack extension method is used). Do not make this value too large; the results are undefined if YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) evaluated with infinite-precision integer arithmetic. */ #ifndef YYMAXDEPTH # define YYMAXDEPTH 10000 #endif #if YYERROR_VERBOSE # ifndef yystrlen # if defined __GLIBC__ && defined _STRING_H # define yystrlen strlen # else /* Return the length of YYSTR. */ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static YYSIZE_T yystrlen (const char *yystr) #else static YYSIZE_T yystrlen (yystr) const char *yystr; #endif { YYSIZE_T yylen; for (yylen = 0; yystr[yylen]; yylen++) continue; return yylen; } # endif # endif # ifndef yystpcpy # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE # define yystpcpy stpcpy # else /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in YYDEST. */ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static char * yystpcpy (char *yydest, const char *yysrc) #else static char * yystpcpy (yydest, yysrc) char *yydest; const char *yysrc; #endif { char *yyd = yydest; const char *yys = yysrc; while ((*yyd++ = *yys++) != '\0') continue; return yyd - 1; } # endif # endif # ifndef yytnamerr /* Copy to YYRES the contents of YYSTR after stripping away unnecessary quotes and backslashes, so that it's suitable for yyerror. The heuristic is that double-quoting is unnecessary unless the string contains an apostrophe, a comma, or backslash (other than backslash-backslash). YYSTR is taken from yytname. If YYRES is null, do not copy; instead, return the length of what the result would have been. */ static YYSIZE_T yytnamerr (char *yyres, const char *yystr) { if (*yystr == '"') { YYSIZE_T yyn = 0; char const *yyp = yystr; for (;;) switch (*++yyp) { case '\'': case ',': goto do_not_strip_quotes; case '\\': if (*++yyp != '\\') goto do_not_strip_quotes; /* Fall through. */ default: if (yyres) yyres[yyn] = *yyp; yyn++; break; case '"': if (yyres) yyres[yyn] = '\0'; return yyn; } do_not_strip_quotes: ; } if (! yyres) return yystrlen (yystr); return yystpcpy (yyres, yystr) - yyres; } # endif /* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message about the unexpected token YYTOKEN for the state stack whose top is YYSSP. Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is not large enough to hold the message. In that case, also set *YYMSG_ALLOC to the required number of bytes. Return 2 if the required number of bytes is too large to store. */ static int yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, yytype_int16 *yyssp, int yytoken) { YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); YYSIZE_T yysize = yysize0; YYSIZE_T yysize1; enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; /* Internationalized format string. */ const char *yyformat = 0; /* Arguments of yyformat. */ char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; /* Number of reported tokens (one for the "unexpected", one per "expected"). */ int yycount = 0; /* There are many possibilities here to consider: - Assume YYFAIL is not used. It's too flawed to consider. See for details. YYERROR is fine as it does not invoke this function. - If this state is a consistent state with a default action, then the only way this function was invoked is if the default action is an error action. In that case, don't check for expected tokens because there are none. - The only way there can be no lookahead present (in yychar) is if this state is a consistent state with a default action. Thus, detecting the absence of a lookahead is sufficient to determine that there is no unexpected or expected token to report. In that case, just report a simple "syntax error". - Don't assume there isn't a lookahead just because this state is a consistent state with a default action. There might have been a previous inconsistent state, consistent state with a non-default action, or user semantic action that manipulated yychar. - Of course, the expected token list depends on states to have correct lookahead information, and it depends on the parser not to perform extra reductions after fetching a lookahead from the scanner and before detecting a syntax error. Thus, state merging (from LALR or IELR) and default reductions corrupt the expected token list. However, the list is correct for canonical LR with one exception: it will still contain any token that will not be accepted due to an error action in a later state. */ if (yytoken != YYEMPTY) { int yyn = yypact[*yyssp]; yyarg[yycount++] = yytname[yytoken]; if (!yypact_value_is_default (yyn)) { /* Start YYX at -YYN if negative to avoid negative indexes in YYCHECK. In other words, skip the first -YYN actions for this state because they are default actions. */ int yyxbegin = yyn < 0 ? -yyn : 0; /* Stay within bounds of both yycheck and yytname. */ int yychecklim = YYLAST - yyn + 1; int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; int yyx; for (yyx = yyxbegin; yyx < yyxend; ++yyx) if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR && !yytable_value_is_error (yytable[yyx + yyn])) { if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) { yycount = 1; yysize = yysize0; break; } yyarg[yycount++] = yytname[yyx]; yysize1 = yysize + yytnamerr (0, yytname[yyx]); if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) return 2; yysize = yysize1; } } } switch (yycount) { # define YYCASE_(N, S) \ case N: \ yyformat = S; \ break YYCASE_(0, YY_("syntax error")); YYCASE_(1, YY_("syntax error, unexpected %s")); YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); # undef YYCASE_ } yysize1 = yysize + yystrlen (yyformat); if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) return 2; yysize = yysize1; if (*yymsg_alloc < yysize) { *yymsg_alloc = 2 * yysize; if (! (yysize <= *yymsg_alloc && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; return 1; } /* Avoid sprintf, as that infringes on the user's name space. Don't have undefined behavior even if the translation produced a string with the wrong number of "%s"s. */ { char *yyp = *yymsg; int yyi = 0; while ((*yyp = *yyformat) != '\0') if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) { yyp += yytnamerr (yyp, yyarg[yyi++]); yyformat += 2; } else { yyp++; yyformat++; } } return 0; } #endif /* YYERROR_VERBOSE */ /*-----------------------------------------------. | Release the memory associated to this symbol. | `-----------------------------------------------*/ /*ARGSUSED*/ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) #else static void yydestruct (yymsg, yytype, yyvaluep) const char *yymsg; int yytype; YYSTYPE *yyvaluep; #endif { YYUSE (yyvaluep); if (!yymsg) yymsg = "Deleting"; YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); switch (yytype) { default: break; } } /* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM #if defined __STDC__ || defined __cplusplus int yyparse (void *YYPARSE_PARAM); #else int yyparse (); #endif #else /* ! YYPARSE_PARAM */ #if defined __STDC__ || defined __cplusplus int yyparse (void); #else int yyparse (); #endif #endif /* ! YYPARSE_PARAM */ /* The lookahead symbol. */ int yychar; /* The semantic value of the lookahead symbol. */ YYSTYPE yylval; /* Number of syntax errors so far. */ int yynerrs; /*----------. | yyparse. | `----------*/ #ifdef YYPARSE_PARAM #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) int yyparse (void *YYPARSE_PARAM) #else int yyparse (YYPARSE_PARAM) void *YYPARSE_PARAM; #endif #else /* ! YYPARSE_PARAM */ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) int yyparse (void) #else int yyparse () #endif #endif { int yystate; /* Number of tokens to shift before error messages enabled. */ int yyerrstatus; /* The stacks and their tools: `yyss': related to states. `yyvs': related to semantic values. Refer to the stacks thru separate pointers, to allow yyoverflow to reallocate them elsewhere. */ /* The state stack. */ yytype_int16 yyssa[YYINITDEPTH]; yytype_int16 *yyss; yytype_int16 *yyssp; /* The semantic value stack. */ YYSTYPE yyvsa[YYINITDEPTH]; YYSTYPE *yyvs; YYSTYPE *yyvsp; YYSIZE_T yystacksize; int yyn; int yyresult; /* Lookahead token as an internal (translated) token number. */ int yytoken; /* The variables used to return semantic value and location from the action routines. */ YYSTYPE yyval; #if YYERROR_VERBOSE /* Buffer for error messages, and its allocated size. */ char yymsgbuf[128]; char *yymsg = yymsgbuf; YYSIZE_T yymsg_alloc = sizeof yymsgbuf; #endif #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) /* The number of symbols on the RHS of the reduced rule. Keep to zero when no symbol should be popped. */ int yylen = 0; yytoken = 0; yyss = yyssa; yyvs = yyvsa; yystacksize = YYINITDEPTH; YYDPRINTF ((stderr, "Starting parse\n")); yystate = 0; yyerrstatus = 0; yynerrs = 0; yychar = YYEMPTY; /* Cause a token to be read. */ /* Initialize stack pointers. Waste one element of value and location stack so that they stay on the same level as the state stack. The wasted elements are never initialized. */ yyssp = yyss; yyvsp = yyvs; goto yysetstate; /*------------------------------------------------------------. | yynewstate -- Push a new state, which is found in yystate. | `------------------------------------------------------------*/ yynewstate: /* In all cases, when you get here, the value and location stacks have just been pushed. So pushing a state here evens the stacks. */ yyssp++; yysetstate: *yyssp = yystate; if (yyss + yystacksize - 1 <= yyssp) { /* Get the current used size of the three stacks, in elements. */ YYSIZE_T yysize = yyssp - yyss + 1; #ifdef yyoverflow { /* Give user a chance to reallocate the stack. Use copies of these so that the &'s don't force the real ones into memory. */ YYSTYPE *yyvs1 = yyvs; yytype_int16 *yyss1 = yyss; /* Each stack pointer address is followed by the size of the data in use in that stack, in bytes. This used to be a conditional around just the two extra args, but that might be undefined if yyoverflow is a macro. */ yyoverflow (YY_("memory exhausted"), &yyss1, yysize * sizeof (*yyssp), &yyvs1, yysize * sizeof (*yyvsp), &yystacksize); yyss = yyss1; yyvs = yyvs1; } #else /* no yyoverflow */ # ifndef YYSTACK_RELOCATE goto yyexhaustedlab; # else /* Extend the stack our own way. */ if (YYMAXDEPTH <= yystacksize) goto yyexhaustedlab; yystacksize *= 2; if (YYMAXDEPTH < yystacksize) yystacksize = YYMAXDEPTH; { yytype_int16 *yyss1 = yyss; union yyalloc *yyptr = (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); if (! yyptr) goto yyexhaustedlab; YYSTACK_RELOCATE (yyss_alloc, yyss); YYSTACK_RELOCATE (yyvs_alloc, yyvs); # undef YYSTACK_RELOCATE if (yyss1 != yyssa) YYSTACK_FREE (yyss1); } # endif #endif /* no yyoverflow */ yyssp = yyss + yysize - 1; yyvsp = yyvs + yysize - 1; YYDPRINTF ((stderr, "Stack size increased to %lu\n", (unsigned long int) yystacksize)); if (yyss + yystacksize - 1 <= yyssp) YYABORT; } YYDPRINTF ((stderr, "Entering state %d\n", yystate)); if (yystate == YYFINAL) YYACCEPT; goto yybackup; /*-----------. | yybackup. | `-----------*/ yybackup: /* Do appropriate processing given the current state. Read a lookahead token if we need one and don't already have one. */ /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; if (yypact_value_is_default (yyn)) goto yydefault; /* Not known => get a lookahead token if don't already have one. */ /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ if (yychar == YYEMPTY) { YYDPRINTF ((stderr, "Reading a token: ")); yychar = YYLEX; } if (yychar <= YYEOF) { yychar = yytoken = YYEOF; YYDPRINTF ((stderr, "Now at end of input.\n")); } else { yytoken = YYTRANSLATE (yychar); YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); } /* If the proper action on seeing token YYTOKEN is to reduce or to detect an error, take that action. */ yyn += yytoken; if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) goto yydefault; yyn = yytable[yyn]; if (yyn <= 0) { if (yytable_value_is_error (yyn)) goto yyerrlab; yyn = -yyn; goto yyreduce; } /* Count tokens shifted since error; after three, turn off error status. */ if (yyerrstatus) yyerrstatus--; /* Shift the lookahead token. */ YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); /* Discard the shifted token. */ yychar = YYEMPTY; yystate = yyn; *++yyvsp = yylval; goto yynewstate; /*-----------------------------------------------------------. | yydefault -- do the default action for the current state. | `-----------------------------------------------------------*/ yydefault: yyn = yydefact[yystate]; if (yyn == 0) goto yyerrlab; goto yyreduce; /*-----------------------------. | yyreduce -- Do a reduction. | `-----------------------------*/ yyreduce: /* yyn is the number of a rule to reduce with. */ yylen = yyr2[yyn]; /* If YYLEN is nonzero, implement the default value of the action: `$$ = $1'. Otherwise, the following line sets YYVAL to garbage. This behavior is undocumented and Bison users should not rely upon it. Assigning to YYVAL unconditionally makes the parser a bit smaller, and it avoids a GCC warning that YYVAL may be used uninitialized. */ yyval = yyvsp[1-yylen]; YY_REDUCE_PRINT (yyn); switch (yyn) { case 2: /* Line 1806 of yacc.c */ #line 1560 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_d0eclst((yyvsp[(2) - (3)].d0eclst)) ; return 0 ; } break; case 3: /* Line 1806 of yacc.c */ #line 1561 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_d0eclst((yyvsp[(2) - (3)].d0eclst)) ; return 0 ; } break; case 4: /* Line 1806 of yacc.c */ #line 1562 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_i0de((yyvsp[(2) - (3)].i0de)) ; return 0 ; } break; case 5: /* Line 1806 of yacc.c */ #line 1563 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_i0de((yyvsp[(2) - (3)].i0de)) ; return 0 ; } break; case 6: /* Line 1806 of yacc.c */ #line 1564 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_i0de((yyvsp[(2) - (3)].i0de)) ; return 0 ; } break; case 7: /* Line 1806 of yacc.c */ #line 1565 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_i0de((yyvsp[(2) - (3)].i0de)) ; return 0 ; } break; case 8: /* Line 1806 of yacc.c */ #line 1566 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_s0exp((yyvsp[(2) - (3)].s0exp)) ; return 0 ; } break; case 9: /* Line 1806 of yacc.c */ #line 1567 "ats_grammar.yats" { theYYVALyyres = atsopt_yyres_d0exp((yyvsp[(2) - (3)].d0exp)) ; return 0 ; } break; case 10: /* Line 1806 of yacc.c */ #line 1571 "ats_grammar.yats" { (yyval.abskind) = abskind_prop () ; } break; case 11: /* Line 1806 of yacc.c */ #line 1572 "ats_grammar.yats" { (yyval.abskind) = abskind_type () ; } break; case 12: /* Line 1806 of yacc.c */ #line 1573 "ats_grammar.yats" { (yyval.abskind) = abskind_t0ype () ; } break; case 13: /* Line 1806 of yacc.c */ #line 1574 "ats_grammar.yats" { (yyval.abskind) = abskind_view () ; } break; case 14: /* Line 1806 of yacc.c */ #line 1575 "ats_grammar.yats" { (yyval.abskind) = abskind_viewtype () ; } break; case 15: /* Line 1806 of yacc.c */ #line 1576 "ats_grammar.yats" { (yyval.abskind) = abskind_viewt0ype () ; } break; case 16: /* Line 1806 of yacc.c */ #line 1580 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_fun () ; } break; case 17: /* Line 1806 of yacc.c */ #line 1581 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_val () ; } break; case 18: /* Line 1806 of yacc.c */ #line 1582 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_castfn () ; } break; case 19: /* Line 1806 of yacc.c */ #line 1583 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_praxi () ; } break; case 20: /* Line 1806 of yacc.c */ #line 1584 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_prfun () ; } break; case 21: /* Line 1806 of yacc.c */ #line 1585 "ats_grammar.yats" { (yyval.dcstkind) = dcstkind_prval () ; } break; case 22: /* Line 1806 of yacc.c */ #line 1589 "ats_grammar.yats" { (yyval.datakind) = datakind_prop () ; } break; case 23: /* Line 1806 of yacc.c */ #line 1590 "ats_grammar.yats" { (yyval.datakind) = datakind_type () ; } break; case 24: /* Line 1806 of yacc.c */ #line 1591 "ats_grammar.yats" { (yyval.datakind) = datakind_view () ; } break; case 25: /* Line 1806 of yacc.c */ #line 1592 "ats_grammar.yats" { (yyval.datakind) = datakind_viewtype () ; } break; case 26: /* Line 1806 of yacc.c */ #line 1596 "ats_grammar.yats" { (yyval.stadefkind) = stadefkind_generic () ; } break; case 27: /* Line 1806 of yacc.c */ #line 1597 "ats_grammar.yats" { (yyval.stadefkind) = stadefkind_prop ((yyvsp[(1) - (1)].t0kn)) ; } break; case 28: /* Line 1806 of yacc.c */ #line 1598 "ats_grammar.yats" { (yyval.stadefkind) = stadefkind_type ((yyvsp[(1) - (1)].t0kn)) ; } break; case 29: /* Line 1806 of yacc.c */ #line 1599 "ats_grammar.yats" { (yyval.stadefkind) = stadefkind_view ((yyvsp[(1) - (1)].t0kn)) ; } break; case 30: /* Line 1806 of yacc.c */ #line 1600 "ats_grammar.yats" { (yyval.stadefkind) = stadefkind_viewtype ((yyvsp[(1) - (1)].t0kn)) ; } break; case 31: /* Line 1806 of yacc.c */ #line 1604 "ats_grammar.yats" { (yyval.valkind) = valkind_val () ; } break; case 32: /* Line 1806 of yacc.c */ #line 1605 "ats_grammar.yats" { (yyval.valkind) = valkind_valminus () ; } break; case 33: /* Line 1806 of yacc.c */ #line 1606 "ats_grammar.yats" { (yyval.valkind) = valkind_valplus () ; } break; case 34: /* Line 1806 of yacc.c */ #line 1607 "ats_grammar.yats" { (yyval.valkind) = valkind_prval () ; } break; case 35: /* Line 1806 of yacc.c */ #line 1611 "ats_grammar.yats" { (yyval.funkind) = funkind_fn () ; } break; case 36: /* Line 1806 of yacc.c */ #line 1612 "ats_grammar.yats" { (yyval.funkind) = funkind_fnstar () ; } break; case 37: /* Line 1806 of yacc.c */ #line 1613 "ats_grammar.yats" { (yyval.funkind) = funkind_fun () ; } break; case 38: /* Line 1806 of yacc.c */ #line 1614 "ats_grammar.yats" { (yyval.funkind) = funkind_castfn () ; } break; case 39: /* Line 1806 of yacc.c */ #line 1615 "ats_grammar.yats" { (yyval.funkind) = funkind_prfn () ; } break; case 40: /* Line 1806 of yacc.c */ #line 1616 "ats_grammar.yats" { (yyval.funkind) = funkind_prfun () ; } break; case 41: /* Line 1806 of yacc.c */ #line 1620 "ats_grammar.yats" { (yyval.lamkind) = lamkind_lam ((yyvsp[(1) - (1)].t0kn)) ; } break; case 42: /* Line 1806 of yacc.c */ #line 1621 "ats_grammar.yats" { (yyval.lamkind) = lamkind_atlam ((yyvsp[(1) - (1)].t0kn)) ; } break; case 43: /* Line 1806 of yacc.c */ #line 1622 "ats_grammar.yats" { (yyval.lamkind) = lamkind_llam ((yyvsp[(1) - (1)].t0kn)) ; } break; case 44: /* Line 1806 of yacc.c */ #line 1623 "ats_grammar.yats" { (yyval.lamkind) = lamkind_atllam ((yyvsp[(1) - (1)].t0kn)) ; } break; case 45: /* Line 1806 of yacc.c */ #line 1627 "ats_grammar.yats" { (yyval.fixkind) = fixkind_fix ((yyvsp[(1) - (1)].t0kn)) ; } break; case 46: /* Line 1806 of yacc.c */ #line 1628 "ats_grammar.yats" { (yyval.fixkind) = fixkind_atfix ((yyvsp[(1) - (1)].t0kn)) ; } break; case 47: /* Line 1806 of yacc.c */ #line 1632 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_if ((yyvsp[(1) - (1)].t0kn)) ; } break; case 48: /* Line 1806 of yacc.c */ #line 1633 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_ifdef ((yyvsp[(1) - (1)].t0kn)) ; } break; case 49: /* Line 1806 of yacc.c */ #line 1634 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_ifndef ((yyvsp[(1) - (1)].t0kn)) ; } break; case 50: /* Line 1806 of yacc.c */ #line 1638 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_if ((yyvsp[(1) - (1)].t0kn)) ; } break; case 51: /* Line 1806 of yacc.c */ #line 1639 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_ifdef ((yyvsp[(1) - (1)].t0kn)) ; } break; case 52: /* Line 1806 of yacc.c */ #line 1640 "ats_grammar.yats" { (yyval.srpifkindtok) = srpifkindtok_ifndef ((yyvsp[(1) - (1)].t0kn)) ; } break; case 53: /* Line 1806 of yacc.c */ #line 1644 "ats_grammar.yats" { ; } break; case 54: /* Line 1806 of yacc.c */ #line 1645 "ats_grammar.yats" { ; } break; case 55: /* Line 1806 of yacc.c */ #line 1649 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 56: /* Line 1806 of yacc.c */ #line 1650 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 57: /* Line 1806 of yacc.c */ #line 1651 "ats_grammar.yats" { (yyval.i0de) = i0de_make_ampersand((yyvsp[(1) - (1)].t0kn)) ; } break; case 58: /* Line 1806 of yacc.c */ #line 1652 "ats_grammar.yats" { (yyval.i0de) = i0de_make_backslash((yyvsp[(1) - (1)].t0kn)) ; } break; case 59: /* Line 1806 of yacc.c */ #line 1653 "ats_grammar.yats" { (yyval.i0de) = i0de_make_bang((yyvsp[(1) - (1)].t0kn)) ; } break; case 60: /* Line 1806 of yacc.c */ #line 1654 "ats_grammar.yats" { (yyval.i0de) = i0de_make_eq((yyvsp[(1) - (1)].t0kn)) ; } break; case 61: /* Line 1806 of yacc.c */ #line 1655 "ats_grammar.yats" { (yyval.i0de) = i0de_make_gt((yyvsp[(1) - (1)].t0kn)) ; } break; case 62: /* Line 1806 of yacc.c */ #line 1656 "ats_grammar.yats" { (yyval.i0de) = i0de_make_gtlt((yyvsp[(1) - (1)].t0kn)) ; } break; case 63: /* Line 1806 of yacc.c */ #line 1657 "ats_grammar.yats" { (yyval.i0de) = i0de_make_lt((yyvsp[(1) - (1)].t0kn)) ; } break; case 64: /* Line 1806 of yacc.c */ #line 1658 "ats_grammar.yats" { (yyval.i0de) = i0de_make_minusgt((yyvsp[(1) - (1)].t0kn)) ; } break; case 65: /* Line 1806 of yacc.c */ #line 1659 "ats_grammar.yats" { (yyval.i0de) = i0de_make_minusltgt((yyvsp[(1) - (1)].t0kn)) ; } break; case 66: /* Line 1806 of yacc.c */ #line 1660 "ats_grammar.yats" { (yyval.i0de) = i0de_make_tilde((yyvsp[(1) - (1)].t0kn)) ; } break; case 67: /* Line 1806 of yacc.c */ #line 1664 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 68: /* Line 1806 of yacc.c */ #line 1668 "ats_grammar.yats" { (yyval.i0delst) = i0delst_nil() ; } break; case 69: /* Line 1806 of yacc.c */ #line 1669 "ats_grammar.yats" { (yyval.i0delst) = i0delst_cons((yyvsp[(1) - (2)].i0de), (yyvsp[(2) - (2)].i0delst)) ; } break; case 70: /* Line 1806 of yacc.c */ #line 1673 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 71: /* Line 1806 of yacc.c */ #line 1674 "ats_grammar.yats" { (yyval.i0de) = i0de_make_DO((yyvsp[(1) - (1)].t0kn)) ; } break; case 72: /* Line 1806 of yacc.c */ #line 1675 "ats_grammar.yats" { (yyval.i0de) = i0de_make_WHILE((yyvsp[(1) - (1)].t0kn)) ; } break; case 73: /* Line 1806 of yacc.c */ #line 1679 "ats_grammar.yats" { (yyval.l0ab) = l0ab_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 74: /* Line 1806 of yacc.c */ #line 1680 "ats_grammar.yats" { (yyval.l0ab) = l0ab_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 75: /* Line 1806 of yacc.c */ #line 1681 "ats_grammar.yats" { (yyval.l0ab) = (yyvsp[(2) - (3)].l0ab) ; } break; case 76: /* Line 1806 of yacc.c */ #line 1685 "ats_grammar.yats" { (yyval.i0de) = stai0de_make((yyvsp[(1) - (1)].i0de)) ; } break; case 77: /* Line 1806 of yacc.c */ #line 1689 "ats_grammar.yats" { (yyval.p0rec) = p0rec_emp() ; } break; case 78: /* Line 1806 of yacc.c */ #line 1690 "ats_grammar.yats" { (yyval.p0rec) = p0rec_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 79: /* Line 1806 of yacc.c */ #line 1691 "ats_grammar.yats" { (yyval.p0rec) = p0rec_ide((yyvsp[(2) - (3)].i0de)) ; } break; case 80: /* Line 1806 of yacc.c */ #line 1692 "ats_grammar.yats" { (yyval.p0rec) = p0rec_opr((yyvsp[(2) - (5)].i0de), (yyvsp[(3) - (5)].i0de), (yyvsp[(4) - (5)].i0nt)) ; } break; case 81: /* Line 1806 of yacc.c */ #line 1696 "ats_grammar.yats" { (yyval.e0xp) = e0xp_app((yyvsp[(1) - (2)].e0xp), (yyvsp[(2) - (2)].e0xp)) ; } break; case 82: /* Line 1806 of yacc.c */ #line 1697 "ats_grammar.yats" { (yyval.e0xp) = (yyvsp[(1) - (1)].e0xp) ; } break; case 83: /* Line 1806 of yacc.c */ #line 1701 "ats_grammar.yats" { (yyval.e0xp) = e0xp_char((yyvsp[(1) - (1)].c0har)) ; } break; case 84: /* Line 1806 of yacc.c */ #line 1702 "ats_grammar.yats" { (yyval.e0xp) = e0xp_float((yyvsp[(1) - (1)].f0loat)) ; } break; case 85: /* Line 1806 of yacc.c */ #line 1703 "ats_grammar.yats" { (yyval.e0xp) = e0xp_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 86: /* Line 1806 of yacc.c */ #line 1704 "ats_grammar.yats" { (yyval.e0xp) = e0xp_string((yyvsp[(1) - (1)].s0tring)) ; } break; case 87: /* Line 1806 of yacc.c */ #line 1705 "ats_grammar.yats" { (yyval.e0xp) = e0xp_FILENAME((yyvsp[(1) - (1)].t0kn)) ; } break; case 88: /* Line 1806 of yacc.c */ #line 1706 "ats_grammar.yats" { (yyval.e0xp) = e0xp_LOCATION((yyvsp[(1) - (1)].t0kn)) ; } break; case 89: /* Line 1806 of yacc.c */ #line 1707 "ats_grammar.yats" { (yyval.e0xp) = e0xp_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 90: /* Line 1806 of yacc.c */ #line 1708 "ats_grammar.yats" { (yyval.e0xp) = e0xp_list((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].e0xplst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 91: /* Line 1806 of yacc.c */ #line 1709 "ats_grammar.yats" { (yyval.e0xp) = e0xp_eval((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].e0xp), (yyvsp[(3) - (3)].t0kn)) ; } break; case 92: /* Line 1806 of yacc.c */ #line 1713 "ats_grammar.yats" { (yyval.e0xplst) = e0xplst_nil() ; } break; case 93: /* Line 1806 of yacc.c */ #line 1714 "ats_grammar.yats" { (yyval.e0xplst) = e0xplst_cons((yyvsp[(1) - (2)].e0xp), (yyvsp[(2) - (2)].e0xplst)) ; } break; case 94: /* Line 1806 of yacc.c */ #line 1718 "ats_grammar.yats" { (yyval.e0xplst) = e0xplst_nil() ; } break; case 95: /* Line 1806 of yacc.c */ #line 1719 "ats_grammar.yats" { (yyval.e0xplst) = e0xplst_cons((yyvsp[(2) - (3)].e0xp), (yyvsp[(3) - (3)].e0xplst)) ; } break; case 96: /* Line 1806 of yacc.c */ #line 1723 "ats_grammar.yats" { (yyval.e0xpopt) = e0xpopt_none() ; } break; case 97: /* Line 1806 of yacc.c */ #line 1724 "ats_grammar.yats" { (yyval.e0xpopt) = e0xpopt_some((yyvsp[(1) - (1)].e0xp)) ; } break; case 98: /* Line 1806 of yacc.c */ #line 1728 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 99: /* Line 1806 of yacc.c */ #line 1732 "ats_grammar.yats" { (yyval.e0fftag) = e0fftag_cst (0, (yyvsp[(2) - (2)].i0de)) ; } break; case 100: /* Line 1806 of yacc.c */ #line 1733 "ats_grammar.yats" { (yyval.e0fftag) = e0fftag_cst (1, (yyvsp[(2) - (2)].i0de)) ; } break; case 101: /* Line 1806 of yacc.c */ #line 1734 "ats_grammar.yats" { (yyval.e0fftag) = e0fftag_var((yyvsp[(1) - (1)].i0de)) ; } break; case 102: /* Line 1806 of yacc.c */ #line 1735 "ats_grammar.yats" { (yyval.e0fftag) = e0fftag_var_fun((yyvsp[(1) - (1)].t0kn)) ; } break; case 103: /* Line 1806 of yacc.c */ #line 1736 "ats_grammar.yats" { (yyval.e0fftag) = e0fftag_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 104: /* Line 1806 of yacc.c */ #line 1740 "ats_grammar.yats" { (yyval.e0fftaglst) = e0fftaglst_nil() ; } break; case 105: /* Line 1806 of yacc.c */ #line 1741 "ats_grammar.yats" { (yyval.e0fftaglst) = e0fftaglst_cons((yyvsp[(1) - (2)].e0fftag), (yyvsp[(2) - (2)].e0fftaglst)) ; } break; case 106: /* Line 1806 of yacc.c */ #line 1745 "ats_grammar.yats" { (yyval.e0fftaglst) = e0fftaglst_nil() ; } break; case 107: /* Line 1806 of yacc.c */ #line 1746 "ats_grammar.yats" { (yyval.e0fftaglst) = e0fftaglst_cons((yyvsp[(2) - (3)].e0fftag), (yyvsp[(3) - (3)].e0fftaglst)) ; } break; case 108: /* Line 1806 of yacc.c */ #line 1750 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_none() ; } break; case 109: /* Line 1806 of yacc.c */ #line 1751 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_some(e0fftaglst_nil()) ; } break; case 110: /* Line 1806 of yacc.c */ #line 1752 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_some((yyvsp[(2) - (3)].e0fftaglst)) ; } break; case 111: /* Line 1806 of yacc.c */ #line 1756 "ats_grammar.yats" { (yyval.s0rt) = s0rt_app((yyvsp[(1) - (2)].s0rt), (yyvsp[(2) - (2)].s0rt)) ; } break; case 112: /* Line 1806 of yacc.c */ #line 1757 "ats_grammar.yats" { (yyval.s0rt) = (yyvsp[(1) - (1)].s0rt) ; } break; case 113: /* Line 1806 of yacc.c */ #line 1761 "ats_grammar.yats" { (yyval.s0rtq) = s0rtq_sym((yyvsp[(1) - (2)].i0de)) ; } break; case 114: /* Line 1806 of yacc.c */ #line 1762 "ats_grammar.yats" { (yyval.s0rtq) = s0rtq_str((yyvsp[(2) - (3)].s0tring)) ; } break; case 115: /* Line 1806 of yacc.c */ #line 1766 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 116: /* Line 1806 of yacc.c */ #line 1767 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 117: /* Line 1806 of yacc.c */ #line 1768 "ats_grammar.yats" { (yyval.i0de) = i0de_make_t0ype((yyvsp[(1) - (1)].t0kn)) ; } break; case 118: /* Line 1806 of yacc.c */ #line 1769 "ats_grammar.yats" { (yyval.i0de) = i0de_make_viewt0ype((yyvsp[(1) - (1)].t0kn)) ; } break; case 119: /* Line 1806 of yacc.c */ #line 1770 "ats_grammar.yats" { (yyval.i0de) = i0de_make_backslash((yyvsp[(1) - (1)].t0kn)) ; } break; case 120: /* Line 1806 of yacc.c */ #line 1771 "ats_grammar.yats" { (yyval.i0de) = i0de_make_minusgt((yyvsp[(1) - (1)].t0kn)) ; } break; case 121: /* Line 1806 of yacc.c */ #line 1772 "ats_grammar.yats" { (yyval.i0de) = i0de_make_minusltgt((yyvsp[(1) - (1)].t0kn)) ; } break; case 122: /* Line 1806 of yacc.c */ #line 1776 "ats_grammar.yats" { (yyval.s0rt) = s0rt_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 123: /* Line 1806 of yacc.c */ #line 1777 "ats_grammar.yats" { (yyval.s0rt) = s0rt_qid((yyvsp[(1) - (2)].s0rtq), (yyvsp[(2) - (2)].i0de)) ; } break; case 124: /* Line 1806 of yacc.c */ #line 1778 "ats_grammar.yats" { (yyval.s0rt) = s0rt_list((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0rtlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 125: /* Line 1806 of yacc.c */ #line 1779 "ats_grammar.yats" { (yyval.s0rt) = s0rt_tup((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0rtlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 126: /* Line 1806 of yacc.c */ #line 1783 "ats_grammar.yats" { (yyval.s0rtlst) = s0rtlst_nil() ; } break; case 127: /* Line 1806 of yacc.c */ #line 1784 "ats_grammar.yats" { (yyval.s0rtlst) = s0rtlst_cons((yyvsp[(1) - (2)].s0rt), (yyvsp[(2) - (2)].s0rtlst)) ; } break; case 128: /* Line 1806 of yacc.c */ #line 1788 "ats_grammar.yats" { (yyval.s0rtlst) = s0rtlst_nil() ; } break; case 129: /* Line 1806 of yacc.c */ #line 1789 "ats_grammar.yats" { (yyval.s0rtlst) = s0rtlst_cons((yyvsp[(2) - (3)].s0rt), (yyvsp[(3) - (3)].s0rtlst)) ; } break; case 130: /* Line 1806 of yacc.c */ #line 1793 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make((yyvsp[(1) - (1)].s0rt), 0) ; } break; case 131: /* Line 1806 of yacc.c */ #line 1794 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_prop((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 132: /* Line 1806 of yacc.c */ #line 1795 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_prop((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 133: /* Line 1806 of yacc.c */ #line 1796 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_type((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 134: /* Line 1806 of yacc.c */ #line 1797 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_type((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 135: /* Line 1806 of yacc.c */ #line 1798 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_t0ype((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 136: /* Line 1806 of yacc.c */ #line 1799 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_t0ype((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 137: /* Line 1806 of yacc.c */ #line 1800 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_view((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 138: /* Line 1806 of yacc.c */ #line 1801 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_view((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 139: /* Line 1806 of yacc.c */ #line 1802 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_viewtype((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 140: /* Line 1806 of yacc.c */ #line 1803 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_viewtype((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 141: /* Line 1806 of yacc.c */ #line 1804 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_viewt0ype((yyvsp[(1) - (1)].t0kn)), -1) ; } break; case 142: /* Line 1806 of yacc.c */ #line 1805 "ats_grammar.yats" { (yyval.s0rtpol) = s0rtpol_make(s0rt_viewt0ype((yyvsp[(1) - (1)].t0kn)), 1) ; } break; case 143: /* Line 1806 of yacc.c */ #line 1809 "ats_grammar.yats" { (yyval.d0atsrtcon) = d0atsrtcon_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 144: /* Line 1806 of yacc.c */ #line 1810 "ats_grammar.yats" { (yyval.d0atsrtcon) = d0atsrtcon_make_some((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0rt)) ; } break; case 145: /* Line 1806 of yacc.c */ #line 1814 "ats_grammar.yats" { (yyval.d0atsrtconlst) = (yyvsp[(1) - (1)].d0atsrtconlst) ; } break; case 146: /* Line 1806 of yacc.c */ #line 1815 "ats_grammar.yats" { (yyval.d0atsrtconlst) = d0atsrtconlst_cons((yyvsp[(1) - (2)].d0atsrtcon), (yyvsp[(2) - (2)].d0atsrtconlst)) ; } break; case 147: /* Line 1806 of yacc.c */ #line 1819 "ats_grammar.yats" { (yyval.d0atsrtconlst) = d0atsrtconlst_nil() ; } break; case 148: /* Line 1806 of yacc.c */ #line 1820 "ats_grammar.yats" { (yyval.d0atsrtconlst) = d0atsrtconlst_cons((yyvsp[(2) - (3)].d0atsrtcon), (yyvsp[(3) - (3)].d0atsrtconlst)) ; } break; case 149: /* Line 1806 of yacc.c */ #line 1824 "ats_grammar.yats" { (yyval.d0atsrtdec) = d0atsrtdec_make((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].d0atsrtconlst)) ; } break; case 150: /* Line 1806 of yacc.c */ #line 1828 "ats_grammar.yats" { (yyval.d0atsrtdeclst) = d0atsrtdeclst_nil() ; } break; case 151: /* Line 1806 of yacc.c */ #line 1829 "ats_grammar.yats" { (yyval.d0atsrtdeclst) = d0atsrtdeclst_cons((yyvsp[(2) - (3)].d0atsrtdec), (yyvsp[(3) - (3)].d0atsrtdeclst)) ; } break; case 152: /* Line 1806 of yacc.c */ #line 1833 "ats_grammar.yats" { (yyval.s0taq) = s0taq_symdot((yyvsp[(1) - (2)].i0de)) ; } break; case 153: /* Line 1806 of yacc.c */ #line 1834 "ats_grammar.yats" { (yyval.s0taq) = s0taq_symcolon((yyvsp[(1) - (2)].i0de)) ; } break; case 154: /* Line 1806 of yacc.c */ #line 1835 "ats_grammar.yats" { (yyval.s0taq) = s0taq_fildot((yyvsp[(2) - (3)].s0tring)) ; } break; case 155: /* Line 1806 of yacc.c */ #line 1839 "ats_grammar.yats" { (yyval.d0ynq) = d0ynq_symdot((yyvsp[(1) - (2)].i0de)) ; } break; case 156: /* Line 1806 of yacc.c */ #line 1840 "ats_grammar.yats" { (yyval.d0ynq) = d0ynq_symcolon((yyvsp[(1) - (2)].i0de)) ; } break; case 157: /* Line 1806 of yacc.c */ #line 1841 "ats_grammar.yats" { (yyval.d0ynq) = d0ynq_symdot_symcolon ((yyvsp[(1) - (3)].i0de), (yyvsp[(2) - (3)].i0de)) ; } break; case 158: /* Line 1806 of yacc.c */ #line 1842 "ats_grammar.yats" { (yyval.d0ynq) = d0ynq_fildot((yyvsp[(2) - (3)].s0tring)) ; } break; case 159: /* Line 1806 of yacc.c */ #line 1843 "ats_grammar.yats" { (yyval.d0ynq) = d0ynq_fildot_symcolon((yyvsp[(2) - (4)].s0tring), (yyvsp[(3) - (4)].i0de)) ; } break; case 160: /* Line 1806 of yacc.c */ #line 1847 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 161: /* Line 1806 of yacc.c */ #line 1848 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 162: /* Line 1806 of yacc.c */ #line 1849 "ats_grammar.yats" { (yyval.i0de) = i0de_make_r0ead((yyvsp[(1) - (1)].t0kn)) ; } break; case 163: /* Line 1806 of yacc.c */ #line 1850 "ats_grammar.yats" { (yyval.i0de) = i0de_make_ampersand((yyvsp[(1) - (1)].t0kn)) ; } break; case 164: /* Line 1806 of yacc.c */ #line 1851 "ats_grammar.yats" { (yyval.i0de) = i0de_make_backslash((yyvsp[(1) - (1)].t0kn)) ; } break; case 165: /* Line 1806 of yacc.c */ #line 1852 "ats_grammar.yats" { (yyval.i0de) = i0de_make_bang((yyvsp[(1) - (1)].t0kn)) ; } break; case 166: /* Line 1806 of yacc.c */ #line 1853 "ats_grammar.yats" { (yyval.i0de) = i0de_make_gt((yyvsp[(1) - (1)].t0kn)) ; } break; case 167: /* Line 1806 of yacc.c */ #line 1854 "ats_grammar.yats" { (yyval.i0de) = i0de_make_lt((yyvsp[(1) - (1)].t0kn)) ; } break; case 168: /* Line 1806 of yacc.c */ #line 1855 "ats_grammar.yats" { (yyval.i0de) = i0de_make_minusgt((yyvsp[(1) - (1)].t0kn)) ; } break; case 169: /* Line 1806 of yacc.c */ #line 1856 "ats_grammar.yats" { (yyval.i0de) = i0de_make_tilde((yyvsp[(1) - (1)].t0kn)) ; } break; case 170: /* Line 1806 of yacc.c */ #line 1860 "ats_grammar.yats" { (yyval.sqi0de) = sqi0de_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 171: /* Line 1806 of yacc.c */ #line 1861 "ats_grammar.yats" { (yyval.sqi0de) = sqi0de_make_some((yyvsp[(1) - (2)].s0taq), (yyvsp[(2) - (2)].i0de)) ; } break; case 172: /* Line 1806 of yacc.c */ #line 1865 "ats_grammar.yats" { (yyval.i0delst) = i0delst_nil() ; } break; case 173: /* Line 1806 of yacc.c */ #line 1866 "ats_grammar.yats" { (yyval.i0delst) = i0delst_cons((yyvsp[(2) - (3)].i0de), (yyvsp[(3) - (3)].i0delst)) ; } break; case 174: /* Line 1806 of yacc.c */ #line 1870 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 175: /* Line 1806 of yacc.c */ #line 1871 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 176: /* Line 1806 of yacc.c */ #line 1872 "ats_grammar.yats" { (yyval.i0de) = i0de_make_backslash((yyvsp[(1) - (1)].t0kn)) ; } break; case 177: /* Line 1806 of yacc.c */ #line 1873 "ats_grammar.yats" { (yyval.i0de) = i0de_make_bang((yyvsp[(1) - (1)].t0kn)) ; } break; case 178: /* Line 1806 of yacc.c */ #line 1874 "ats_grammar.yats" { (yyval.i0de) = i0de_make_eq((yyvsp[(1) - (1)].t0kn)) ; } break; case 179: /* Line 1806 of yacc.c */ #line 1875 "ats_grammar.yats" { (yyval.i0de) = i0de_make_gt((yyvsp[(1) - (1)].t0kn)) ; } break; case 180: /* Line 1806 of yacc.c */ #line 1876 "ats_grammar.yats" { (yyval.i0de) = i0de_make_gtlt((yyvsp[(1) - (1)].t0kn)) ; } break; case 181: /* Line 1806 of yacc.c */ #line 1877 "ats_grammar.yats" { (yyval.i0de) = i0de_make_lt((yyvsp[(1) - (1)].t0kn)) ; } break; case 182: /* Line 1806 of yacc.c */ #line 1878 "ats_grammar.yats" { (yyval.i0de) = i0de_make_tilde((yyvsp[(1) - (1)].t0kn)) ; } break; case 183: /* Line 1806 of yacc.c */ #line 1882 "ats_grammar.yats" { (yyval.dqi0de) = dqi0de_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 184: /* Line 1806 of yacc.c */ #line 1883 "ats_grammar.yats" { (yyval.dqi0de) = dqi0de_make_some((yyvsp[(1) - (2)].d0ynq), (yyvsp[(2) - (2)].i0de)) ; } break; case 185: /* Line 1806 of yacc.c */ #line 1887 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 186: /* Line 1806 of yacc.c */ #line 1888 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 187: /* Line 1806 of yacc.c */ #line 1892 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 188: /* Line 1806 of yacc.c */ #line 1893 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(2) - (2)].i0de) ; } break; case 189: /* Line 1806 of yacc.c */ #line 1897 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 190: /* Line 1806 of yacc.c */ #line 1901 "ats_grammar.yats" { (yyval.arrqi0de) = arrqi0de_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 191: /* Line 1806 of yacc.c */ #line 1902 "ats_grammar.yats" { (yyval.arrqi0de) = arrqi0de_make_some((yyvsp[(1) - (2)].d0ynq), (yyvsp[(2) - (2)].i0de)) ; } break; case 192: /* Line 1806 of yacc.c */ #line 1906 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 193: /* Line 1806 of yacc.c */ #line 1910 "ats_grammar.yats" { (yyval.tmpqi0de) = tmpqi0de_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 194: /* Line 1806 of yacc.c */ #line 1911 "ats_grammar.yats" { (yyval.tmpqi0de) = tmpqi0de_make_some((yyvsp[(1) - (2)].d0ynq), (yyvsp[(2) - (2)].i0de)) ; } break; case 195: /* Line 1806 of yacc.c */ #line 1915 "ats_grammar.yats" { (yyval.s0rtopt) = s0rtopt_none() ; } break; case 196: /* Line 1806 of yacc.c */ #line 1916 "ats_grammar.yats" { (yyval.s0rtopt) = s0rtopt_some((yyvsp[(2) - (2)].s0rt)) ; } break; case 197: /* Line 1806 of yacc.c */ #line 1920 "ats_grammar.yats" { (yyval.s0arg) = s0arg_make((yyvsp[(1) - (2)].i0de), (yyvsp[(2) - (2)].s0rtopt)) ; } break; case 198: /* Line 1806 of yacc.c */ #line 1924 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_nil() ; } break; case 199: /* Line 1806 of yacc.c */ #line 1925 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_cons((yyvsp[(1) - (2)].s0arg), (yyvsp[(2) - (2)].s0arglst)) ; } break; case 200: /* Line 1806 of yacc.c */ #line 1929 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_nil() ; } break; case 201: /* Line 1806 of yacc.c */ #line 1930 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_cons((yyvsp[(2) - (3)].s0arg), (yyvsp[(3) - (3)].s0arglst)) ; } break; case 202: /* Line 1806 of yacc.c */ #line 1934 "ats_grammar.yats" { (yyval.s0arglstlst) = s0arglstlst_nil() ; } break; case 203: /* Line 1806 of yacc.c */ #line 1935 "ats_grammar.yats" { (yyval.s0arglstlst) = s0arglstlst_cons_ide((yyvsp[(1) - (2)].i0de), (yyvsp[(2) - (2)].s0arglstlst)) ; } break; case 204: /* Line 1806 of yacc.c */ #line 1936 "ats_grammar.yats" { (yyval.s0arglstlst) = s0arglstlst_cons((yyvsp[(2) - (4)].s0arglst), (yyvsp[(4) - (4)].s0arglstlst)); } break; case 205: /* Line 1806 of yacc.c */ #line 1940 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_nil() ; } break; case 206: /* Line 1806 of yacc.c */ #line 1941 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_cons((yyvsp[(1) - (2)].s0arg), (yyvsp[(2) - (2)].s0arglst)) ; } break; case 207: /* Line 1806 of yacc.c */ #line 1945 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_nil() ; } break; case 208: /* Line 1806 of yacc.c */ #line 1946 "ats_grammar.yats" { (yyval.s0arglst) = s0arglst_cons((yyvsp[(2) - (3)].s0arg), (yyvsp[(3) - (3)].s0arglst)) ; } break; case 209: /* Line 1806 of yacc.c */ #line 1950 "ats_grammar.yats" { (yyval.s0arglstlst) = s0arglstlst_nil() ; } break; case 210: /* Line 1806 of yacc.c */ #line 1951 "ats_grammar.yats" { (yyval.s0arglstlst) = s0arglstlst_cons((yyvsp[(2) - (4)].s0arglst), (yyvsp[(4) - (4)].s0arglstlst)) ; } break; case 211: /* Line 1806 of yacc.c */ #line 1955 "ats_grammar.yats" { (yyval.sp0at) = sp0at_con((yyvsp[(1) - (4)].sqi0de), (yyvsp[(3) - (4)].s0arglst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 212: /* Line 1806 of yacc.c */ #line 1959 "ats_grammar.yats" { (yyval.s0exp) = (yyvsp[(1) - (1)].s0exp) ; } break; case 213: /* Line 1806 of yacc.c */ #line 1960 "ats_grammar.yats" { (yyval.s0exp) = s0exp_extern((yyvsp[(1) - (1)].s0expext)) ; } break; case 214: /* Line 1806 of yacc.c */ #line 1961 "ats_grammar.yats" { (yyval.s0exp) = s0exp_ann((yyvsp[(1) - (3)].s0exp), (yyvsp[(3) - (3)].s0rt)) ; } break; case 215: /* Line 1806 of yacc.c */ #line 1962 "ats_grammar.yats" { (yyval.s0exp) = s0exp_lams((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0arglstlst), (yyvsp[(3) - (5)].s0rtopt), (yyvsp[(5) - (5)].s0exp)) ; } break; case 216: /* Line 1806 of yacc.c */ #line 1966 "ats_grammar.yats" { (yyval.s0exp) = s0exp_char((yyvsp[(1) - (1)].c0har)) ; } break; case 217: /* Line 1806 of yacc.c */ #line 1967 "ats_grammar.yats" { (yyval.s0exp) = s0exp_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 218: /* Line 1806 of yacc.c */ #line 1968 "ats_grammar.yats" { (yyval.s0exp) = s0exp_intsp_err((yyvsp[(1) - (1)].i0ntsp)) ; } break; case 219: /* Line 1806 of yacc.c */ #line 1969 "ats_grammar.yats" { (yyval.s0exp) = s0exp_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 220: /* Line 1806 of yacc.c */ #line 1970 "ats_grammar.yats" { (yyval.s0exp) = s0exp_opide((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0de)) ; } break; case 221: /* Line 1806 of yacc.c */ #line 1971 "ats_grammar.yats" { (yyval.s0exp) = s0exp_qid((yyvsp[(1) - (2)].s0taq), (yyvsp[(2) - (2)].i0de)) ; } break; case 222: /* Line 1806 of yacc.c */ #line 1972 "ats_grammar.yats" { (yyval.s0exp) = s0exp_list((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 223: /* Line 1806 of yacc.c */ #line 1973 "ats_grammar.yats" { (yyval.s0exp) = s0exp_list2((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0explst), (yyvsp[(4) - (5)].s0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 224: /* Line 1806 of yacc.c */ #line 1974 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup(0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 225: /* Line 1806 of yacc.c */ #line 1975 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup(1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 226: /* Line 1806 of yacc.c */ #line 1976 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup(2, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].s0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 227: /* Line 1806 of yacc.c */ #line 1977 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup(3, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].s0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 228: /* Line 1806 of yacc.c */ #line 1978 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup2(0, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0explst), (yyvsp[(4) - (5)].s0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 229: /* Line 1806 of yacc.c */ #line 1979 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup2(1, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0explst), (yyvsp[(4) - (5)].s0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 230: /* Line 1806 of yacc.c */ #line 1980 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup2(2, (yyvsp[(1) - (6)].t0kn), (yyvsp[(3) - (6)].s0explst), (yyvsp[(5) - (6)].s0explst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 231: /* Line 1806 of yacc.c */ #line 1981 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tytup2(3, (yyvsp[(1) - (6)].t0kn), (yyvsp[(3) - (6)].s0explst), (yyvsp[(5) - (6)].s0explst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 232: /* Line 1806 of yacc.c */ #line 1982 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyrec(0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labs0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 233: /* Line 1806 of yacc.c */ #line 1983 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyrec(1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labs0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 234: /* Line 1806 of yacc.c */ #line 1984 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyrec(2, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].labs0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 235: /* Line 1806 of yacc.c */ #line 1985 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyrec(3, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].labs0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 236: /* Line 1806 of yacc.c */ #line 1986 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyrec_ext((yyvsp[(1) - (6)].t0kn), (yyvsp[(2) - (6)].s0tring), (yyvsp[(5) - (6)].labs0explst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 237: /* Line 1806 of yacc.c */ #line 1987 "ats_grammar.yats" { (yyval.s0exp) = s0exp_tyarr((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0exp), (yyvsp[(5) - (5)].s0arrind)) ; } break; case 238: /* Line 1806 of yacc.c */ #line 1988 "ats_grammar.yats" { (yyval.s0exp) = s0exp_imp((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].e0fftaglst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 239: /* Line 1806 of yacc.c */ #line 1989 "ats_grammar.yats" { (yyval.s0exp) = s0exp_imp_emp((yyvsp[(1) - (1)].t0kn)) ; } break; case 240: /* Line 1806 of yacc.c */ #line 1990 "ats_grammar.yats" { (yyval.s0exp) = s0exp_uni((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0qualst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 241: /* Line 1806 of yacc.c */ #line 1991 "ats_grammar.yats" { (yyval.s0exp) = s0exp_exi((yyvsp[(1) - (3)].t0kn), 0/*funres*/, (yyvsp[(2) - (3)].s0qualst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 242: /* Line 1806 of yacc.c */ #line 1992 "ats_grammar.yats" { (yyval.s0exp) = s0exp_exi((yyvsp[(1) - (3)].t0kn), 1/*funres*/, (yyvsp[(2) - (3)].s0qualst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 243: /* Line 1806 of yacc.c */ #line 1996 "ats_grammar.yats" { (yyval.s0exp) = s0exp_app((yyvsp[(1) - (2)].s0exp), (yyvsp[(2) - (2)].s0exp)) ; } break; case 244: /* Line 1806 of yacc.c */ #line 1997 "ats_grammar.yats" { (yyval.s0exp) = (yyvsp[(1) - (1)].s0exp) ; } break; case 245: /* Line 1806 of yacc.c */ #line 2001 "ats_grammar.yats" { (yyval.s0expext) = s0expext_nam((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].s0tring)) ; } break; case 246: /* Line 1806 of yacc.c */ #line 2002 "ats_grammar.yats" { (yyval.s0expext) = s0expext_app((yyvsp[(1) - (2)].s0expext), (yyvsp[(2) - (2)].s0exp)) ; } break; case 247: /* Line 1806 of yacc.c */ #line 2006 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_none () ; } break; case 248: /* Line 1806 of yacc.c */ #line 2007 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_some ((yyvsp[(2) - (3)].s0exp)) ; } break; case 249: /* Line 1806 of yacc.c */ #line 2008 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_some ((yyvsp[(2) - (3)].s0exp)) ; } break; case 250: /* Line 1806 of yacc.c */ #line 2012 "ats_grammar.yats" { (yyval.s0arrind) = s0arrind_make_sing((yyvsp[(1) - (2)].s0explst), (yyvsp[(2) - (2)].t0kn)) ; } break; case 251: /* Line 1806 of yacc.c */ #line 2013 "ats_grammar.yats" { (yyval.s0arrind) = s0arrind_make_cons((yyvsp[(1) - (4)].s0explst), (yyvsp[(4) - (4)].s0arrind)) ; } break; case 252: /* Line 1806 of yacc.c */ #line 2017 "ats_grammar.yats" { (yyval.s0qua) = s0qua_prop((yyvsp[(1) - (1)].s0exp)) ; } break; case 253: /* Line 1806 of yacc.c */ #line 2018 "ats_grammar.yats" { (yyval.s0qua) = s0qua_vars((yyvsp[(1) - (4)].i0de), (yyvsp[(2) - (4)].i0delst), (yyvsp[(4) - (4)].s0rtext)) ; } break; case 254: /* Line 1806 of yacc.c */ #line 2022 "ats_grammar.yats" { (yyval.s0qualst) = s0qualst_nil() ; } break; case 255: /* Line 1806 of yacc.c */ #line 2023 "ats_grammar.yats" { (yyval.s0qualst) = s0qualst_cons((yyvsp[(1) - (2)].s0qua), (yyvsp[(2) - (2)].s0qualst)) ; } break; case 256: /* Line 1806 of yacc.c */ #line 2027 "ats_grammar.yats" { (yyval.s0qualst) = s0qualst_nil() ; } break; case 257: /* Line 1806 of yacc.c */ #line 2028 "ats_grammar.yats" { (yyval.s0qualst) = s0qualst_cons((yyvsp[(2) - (3)].s0qua), (yyvsp[(3) - (3)].s0qualst)) ; } break; case 258: /* Line 1806 of yacc.c */ #line 2029 "ats_grammar.yats" { (yyval.s0qualst) = s0qualst_cons((yyvsp[(2) - (3)].s0qua), (yyvsp[(3) - (3)].s0qualst)) ; } break; case 259: /* Line 1806 of yacc.c */ #line 2033 "ats_grammar.yats" { (yyval.s0rtext) = s0rtext_srt((yyvsp[(1) - (1)].s0rt)) ; } break; case 260: /* Line 1806 of yacc.c */ #line 2034 "ats_grammar.yats" { (yyval.s0rtext) = s0rtext_sub((yyvsp[(1) - (8)].t0kn), (yyvsp[(2) - (8)].i0de), (yyvsp[(4) - (8)].s0rtext), (yyvsp[(6) - (8)].s0exp), (yyvsp[(7) - (8)].s0explst), (yyvsp[(8) - (8)].t0kn)) ; } break; case 261: /* Line 1806 of yacc.c */ #line 2038 "ats_grammar.yats" { (yyval.s0explst) = s0explst_nil() ; } break; case 262: /* Line 1806 of yacc.c */ #line 2039 "ats_grammar.yats" { (yyval.s0explst) = (yyvsp[(1) - (1)].s0explst) ; } break; case 263: /* Line 1806 of yacc.c */ #line 2043 "ats_grammar.yats" { (yyval.s0explst) = s0explst_nil() ; } break; case 264: /* Line 1806 of yacc.c */ #line 2044 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(2) - (3)].s0exp), (yyvsp[(3) - (3)].s0explst)) ; } break; case 265: /* Line 1806 of yacc.c */ #line 2045 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(2) - (3)].s0exp), (yyvsp[(3) - (3)].s0explst)) ; } break; case 266: /* Line 1806 of yacc.c */ #line 2049 "ats_grammar.yats" { (yyval.s0explst) = s0explst_nil() ; } break; case 267: /* Line 1806 of yacc.c */ #line 2050 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(2) - (3)].s0exp), (yyvsp[(3) - (3)].s0explst)) ; } break; case 268: /* Line 1806 of yacc.c */ #line 2054 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(1) - (2)].s0exp), (yyvsp[(2) - (2)].s0explst)) ; } break; case 269: /* Line 1806 of yacc.c */ #line 2058 "ats_grammar.yats" { (yyval.labs0explst) = labs0explst_nil() ; } break; case 270: /* Line 1806 of yacc.c */ #line 2059 "ats_grammar.yats" { (yyval.labs0explst) = labs0explst_cons((yyvsp[(1) - (4)].l0ab), (yyvsp[(3) - (4)].s0exp), (yyvsp[(4) - (4)].labs0explst)) ; } break; case 271: /* Line 1806 of yacc.c */ #line 2063 "ats_grammar.yats" { (yyval.labs0explst) = labs0explst_nil() ; } break; case 272: /* Line 1806 of yacc.c */ #line 2064 "ats_grammar.yats" { (yyval.labs0explst) = labs0explst_cons((yyvsp[(2) - (5)].l0ab), (yyvsp[(4) - (5)].s0exp), (yyvsp[(5) - (5)].labs0explst)) ; } break; case 273: /* Line 1806 of yacc.c */ #line 2068 "ats_grammar.yats" { (yyval.s0exp) = (yyvsp[(1) - (1)].s0exp) ; } break; case 274: /* Line 1806 of yacc.c */ #line 2069 "ats_grammar.yats" { (yyval.s0exp) = s0exp_app((yyvsp[(1) - (2)].s0exp), (yyvsp[(2) - (2)].s0exp)) ; } break; case 275: /* Line 1806 of yacc.c */ #line 2073 "ats_grammar.yats" { (yyval.s0exp) = (yyvsp[(1) - (1)].s0exp) ; } break; case 276: /* Line 1806 of yacc.c */ #line 2077 "ats_grammar.yats" { (yyval.s0explst) = s0explst_nil() ; } break; case 277: /* Line 1806 of yacc.c */ #line 2078 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(1) - (2)].s0exp), (yyvsp[(2) - (2)].s0explst)) ; } break; case 278: /* Line 1806 of yacc.c */ #line 2082 "ats_grammar.yats" { (yyval.s0explst) = s0explst_nil() ; } break; case 279: /* Line 1806 of yacc.c */ #line 2083 "ats_grammar.yats" { (yyval.s0explst) = s0explst_cons((yyvsp[(2) - (3)].s0exp), (yyvsp[(3) - (3)].s0explst)) ; } break; case 280: /* Line 1806 of yacc.c */ #line 2087 "ats_grammar.yats" { (yyval.t1mps0explstlst) = gtlt_t1mps0expseqseq_nil() ; } break; case 281: /* Line 1806 of yacc.c */ #line 2088 "ats_grammar.yats" { (yyval.t1mps0explstlst) = gtlt_t1mps0expseqseq_cons_tok((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t1mps0explstlst)) ; } break; case 282: /* Line 1806 of yacc.c */ #line 2092 "ats_grammar.yats" { (yyval.impqi0de) = impqi0de_make_none((yyvsp[(1) - (1)].dqi0de)) ; } break; case 283: /* Line 1806 of yacc.c */ #line 2093 "ats_grammar.yats" { (yyval.impqi0de) = impqi0de_make_some((yyvsp[(1) - (4)].tmpqi0de), (yyvsp[(2) - (4)].s0explst), (yyvsp[(3) - (4)].t1mps0explstlst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 284: /* Line 1806 of yacc.c */ #line 2097 "ats_grammar.yats" { (yyval.s0rtdef) = s0rtdef_make((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0rtext)) ; } break; case 285: /* Line 1806 of yacc.c */ #line 2101 "ats_grammar.yats" { (yyval.s0rtdeflst) = s0rtdeflst_nil() ; } break; case 286: /* Line 1806 of yacc.c */ #line 2102 "ats_grammar.yats" { (yyval.s0rtdeflst) = s0rtdeflst_cons((yyvsp[(2) - (3)].s0rtdef), (yyvsp[(3) - (3)].s0rtdeflst)) ; } break; case 287: /* Line 1806 of yacc.c */ #line 2106 "ats_grammar.yats" { (yyval.d0atarg) = d0atarg_srt((yyvsp[(1) - (1)].s0rtpol)) ; } break; case 288: /* Line 1806 of yacc.c */ #line 2107 "ats_grammar.yats" { (yyval.d0atarg) = d0atarg_id_srt((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0rtpol)) ; } break; case 289: /* Line 1806 of yacc.c */ #line 2111 "ats_grammar.yats" { (yyval.d0atarglst) = d0atarglst_nil() ; } break; case 290: /* Line 1806 of yacc.c */ #line 2112 "ats_grammar.yats" { (yyval.d0atarglst) = d0atarglst_cons((yyvsp[(1) - (2)].d0atarg), (yyvsp[(2) - (2)].d0atarglst)) ; } break; case 291: /* Line 1806 of yacc.c */ #line 2116 "ats_grammar.yats" { (yyval.d0atarglst) = d0atarglst_nil() ; } break; case 292: /* Line 1806 of yacc.c */ #line 2117 "ats_grammar.yats" { (yyval.d0atarglst) = d0atarglst_cons((yyvsp[(2) - (3)].d0atarg), (yyvsp[(3) - (3)].d0atarglst)) ; } break; case 293: /* Line 1806 of yacc.c */ #line 2121 "ats_grammar.yats" { (yyval.s0tacon) = s0tacon_make_none_none((yyvsp[(1) - (1)].i0de)) ; } break; case 294: /* Line 1806 of yacc.c */ #line 2122 "ats_grammar.yats" { (yyval.s0tacon) = s0tacon_make_some_none((yyvsp[(1) - (4)].i0de), (yyvsp[(3) - (4)].d0atarglst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 295: /* Line 1806 of yacc.c */ #line 2123 "ats_grammar.yats" { (yyval.s0tacon) = s0tacon_make_none_some((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0exp)) ; } break; case 296: /* Line 1806 of yacc.c */ #line 2124 "ats_grammar.yats" { (yyval.s0tacon) = s0tacon_make_some_some((yyvsp[(1) - (6)].i0de), (yyvsp[(3) - (6)].d0atarglst), (yyvsp[(6) - (6)].s0exp)) ; } break; case 297: /* Line 1806 of yacc.c */ #line 2128 "ats_grammar.yats" { (yyval.s0taconlst) = s0taconlst_nil() ; } break; case 298: /* Line 1806 of yacc.c */ #line 2129 "ats_grammar.yats" { (yyval.s0taconlst) = s0taconlst_cons((yyvsp[(2) - (3)].s0tacon), (yyvsp[(3) - (3)].s0taconlst)) ; } break; case 299: /* Line 1806 of yacc.c */ #line 2133 "ats_grammar.yats" { (yyval.s0tacst) = s0tacst_make_none((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0rt)) ; } break; case 300: /* Line 1806 of yacc.c */ #line 2134 "ats_grammar.yats" { (yyval.s0tacst) = s0tacst_make_some((yyvsp[(1) - (6)].i0de), (yyvsp[(3) - (6)].d0atarglst), (yyvsp[(6) - (6)].s0rt)) ; } break; case 301: /* Line 1806 of yacc.c */ #line 2138 "ats_grammar.yats" { (yyval.s0tacstlst) = s0tacstlst_nil() ; } break; case 302: /* Line 1806 of yacc.c */ #line 2139 "ats_grammar.yats" { (yyval.s0tacstlst) = s0tacstlst_cons((yyvsp[(2) - (3)].s0tacst), (yyvsp[(3) - (3)].s0tacstlst)) ; } break; case 303: /* Line 1806 of yacc.c */ #line 2143 "ats_grammar.yats" { (yyval.s0tavar) = s0tavar_make((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0rt)) ; } break; case 304: /* Line 1806 of yacc.c */ #line 2147 "ats_grammar.yats" { (yyval.s0tavarlst) = s0tavarlst_nil() ; } break; case 305: /* Line 1806 of yacc.c */ #line 2148 "ats_grammar.yats" { (yyval.s0tavarlst) = s0tavarlst_cons((yyvsp[(2) - (3)].s0tavar), (yyvsp[(3) - (3)].s0tavarlst)) ; } break; case 306: /* Line 1806 of yacc.c */ #line 2152 "ats_grammar.yats" { (yyval.s0expdef) = s0expdef_make ((yyvsp[(1) - (5)].i0de), (yyvsp[(2) - (5)].s0arglstlst), (yyvsp[(3) - (5)].s0rtopt), (yyvsp[(5) - (5)].s0exp)) ; } break; case 307: /* Line 1806 of yacc.c */ #line 2156 "ats_grammar.yats" { (yyval.s0expdeflst) = s0expdeflst_nil() ; } break; case 308: /* Line 1806 of yacc.c */ #line 2157 "ats_grammar.yats" { (yyval.s0expdeflst) = s0expdeflst_cons((yyvsp[(2) - (3)].s0expdef), (yyvsp[(3) - (3)].s0expdeflst)) ; } break; case 309: /* Line 1806 of yacc.c */ #line 2161 "ats_grammar.yats" { (yyval.s0aspdec) = s0aspdec_make((yyvsp[(1) - (5)].sqi0de), (yyvsp[(2) - (5)].s0arglstlst), (yyvsp[(3) - (5)].s0rtopt), (yyvsp[(5) - (5)].s0exp)) ; } break; case 310: /* Line 1806 of yacc.c */ #line 2165 "ats_grammar.yats" { (yyval.s0qualstlst) = s0qualstlst_nil() ; } break; case 311: /* Line 1806 of yacc.c */ #line 2166 "ats_grammar.yats" { (yyval.s0qualstlst) = s0qualstlst_cons((yyvsp[(2) - (4)].s0qualst), (yyvsp[(4) - (4)].s0qualstlst)) ; } break; case 312: /* Line 1806 of yacc.c */ #line 2170 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_none() ; } break; case 313: /* Line 1806 of yacc.c */ #line 2171 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_some(s0exp_list((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t0kn))) ; } break; case 314: /* Line 1806 of yacc.c */ #line 2175 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_none() ; } break; case 315: /* Line 1806 of yacc.c */ #line 2176 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_some((yyvsp[(2) - (2)].s0exp)) ; } break; case 316: /* Line 1806 of yacc.c */ #line 2180 "ats_grammar.yats" { (yyval.d0atcon) = d0atcon_make((yyvsp[(1) - (4)].s0qualstlst), (yyvsp[(2) - (4)].i0de), (yyvsp[(3) - (4)].s0expopt), (yyvsp[(4) - (4)].s0expopt)) ; } break; case 317: /* Line 1806 of yacc.c */ #line 2184 "ats_grammar.yats" { (yyval.d0atconlst) = (yyvsp[(1) - (1)].d0atconlst) ; } break; case 318: /* Line 1806 of yacc.c */ #line 2185 "ats_grammar.yats" { (yyval.d0atconlst) = d0atconlst_cons((yyvsp[(1) - (2)].d0atcon), (yyvsp[(2) - (2)].d0atconlst)) ; } break; case 319: /* Line 1806 of yacc.c */ #line 2189 "ats_grammar.yats" { (yyval.d0atconlst) = d0atconlst_nil() ; } break; case 320: /* Line 1806 of yacc.c */ #line 2190 "ats_grammar.yats" { (yyval.d0atconlst) = d0atconlst_cons((yyvsp[(2) - (3)].d0atcon), (yyvsp[(3) - (3)].d0atconlst)) ; } break; case 321: /* Line 1806 of yacc.c */ #line 2194 "ats_grammar.yats" { (yyval.d0atdec) = d0atdec_make_none((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].d0atconlst)) ; } break; case 322: /* Line 1806 of yacc.c */ #line 2195 "ats_grammar.yats" { (yyval.d0atdec) = d0atdec_make_some((yyvsp[(1) - (6)].i0de), (yyvsp[(3) - (6)].d0atarglst), (yyvsp[(4) - (6)].t0kn), (yyvsp[(6) - (6)].d0atconlst)) ; } break; case 323: /* Line 1806 of yacc.c */ #line 2199 "ats_grammar.yats" { (yyval.d0atdeclst) = d0atdeclst_nil() ; } break; case 324: /* Line 1806 of yacc.c */ #line 2200 "ats_grammar.yats" { (yyval.d0atdeclst) = d0atdeclst_cons((yyvsp[(2) - (3)].d0atdec), (yyvsp[(3) - (3)].d0atdeclst)) ; } break; case 325: /* Line 1806 of yacc.c */ #line 2204 "ats_grammar.yats" { (yyval.s0expdeflst) = s0expdeflst_nil() ; } break; case 326: /* Line 1806 of yacc.c */ #line 2205 "ats_grammar.yats" { (yyval.s0expdeflst) = s0expdeflst_cons((yyvsp[(2) - (3)].s0expdef), (yyvsp[(3) - (3)].s0expdeflst)) ; } break; case 327: /* Line 1806 of yacc.c */ #line 2209 "ats_grammar.yats" { (yyval.e0xndec) = e0xndec_make((yyvsp[(1) - (3)].s0qualstlst), (yyvsp[(2) - (3)].i0de), (yyvsp[(3) - (3)].s0expopt)) ; } break; case 328: /* Line 1806 of yacc.c */ #line 2213 "ats_grammar.yats" { (yyval.e0xndeclst) = e0xndeclst_nil() ; } break; case 329: /* Line 1806 of yacc.c */ #line 2214 "ats_grammar.yats" { (yyval.e0xndeclst) = e0xndeclst_cons((yyvsp[(2) - (3)].e0xndec), (yyvsp[(3) - (3)].e0xndeclst)) ; } break; case 330: /* Line 1806 of yacc.c */ #line 2218 "ats_grammar.yats" { (yyval.p0arg) = p0arg_make_none((yyvsp[(1) - (1)].i0de)) ; } break; case 331: /* Line 1806 of yacc.c */ #line 2219 "ats_grammar.yats" { (yyval.p0arg) = p0arg_make_some((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0exp)) ; } break; case 332: /* Line 1806 of yacc.c */ #line 2223 "ats_grammar.yats" { (yyval.p0arglst) = p0arglst_nil() ; } break; case 333: /* Line 1806 of yacc.c */ #line 2224 "ats_grammar.yats" { (yyval.p0arglst) = p0arglst_cons((yyvsp[(1) - (2)].p0arg), (yyvsp[(2) - (2)].p0arglst)) ; } break; case 334: /* Line 1806 of yacc.c */ #line 2228 "ats_grammar.yats" { (yyval.p0arglst) = p0arglst_nil() ; } break; case 335: /* Line 1806 of yacc.c */ #line 2229 "ats_grammar.yats" { (yyval.p0arglst) = p0arglst_cons((yyvsp[(2) - (3)].p0arg), (yyvsp[(3) - (3)].p0arglst)) ; } break; case 336: /* Line 1806 of yacc.c */ #line 2233 "ats_grammar.yats" { (yyval.d0arg) = d0arg_var((yyvsp[(1) - (1)].i0de)) ; } break; case 337: /* Line 1806 of yacc.c */ #line 2234 "ats_grammar.yats" { (yyval.d0arg) = d0arg_dyn((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0arglst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 338: /* Line 1806 of yacc.c */ #line 2235 "ats_grammar.yats" { (yyval.d0arg) = d0arg_dyn2((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].p0arglst), (yyvsp[(4) - (5)].p0arglst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 339: /* Line 1806 of yacc.c */ #line 2236 "ats_grammar.yats" { (yyval.d0arg) = d0arg_sta((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0qualst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 340: /* Line 1806 of yacc.c */ #line 2240 "ats_grammar.yats" { (yyval.d0arglst) = d0arglst_nil() ; } break; case 341: /* Line 1806 of yacc.c */ #line 2241 "ats_grammar.yats" { (yyval.d0arglst) = d0arglst_cons((yyvsp[(1) - (2)].d0arg), (yyvsp[(2) - (2)].d0arglst)) ; } break; case 342: /* Line 1806 of yacc.c */ #line 2245 "ats_grammar.yats" { (yyval.extnamopt) = extnamopt_none() ; } break; case 343: /* Line 1806 of yacc.c */ #line 2246 "ats_grammar.yats" { (yyval.extnamopt) = extnamopt_some((yyvsp[(2) - (2)].s0tring)) ; } break; case 344: /* Line 1806 of yacc.c */ #line 2250 "ats_grammar.yats" { (yyval.d0cstdec) = d0cstdec_make((yyvsp[(1) - (5)].i0de), (yyvsp[(2) - (5)].d0arglst), (yyvsp[(3) - (5)].e0fftaglstopt), (yyvsp[(4) - (5)].s0exp), (yyvsp[(5) - (5)].extnamopt)) ; } break; case 345: /* Line 1806 of yacc.c */ #line 2254 "ats_grammar.yats" { (yyval.d0cstdeclst) = d0cstdeclst_nil() ; } break; case 346: /* Line 1806 of yacc.c */ #line 2255 "ats_grammar.yats" { (yyval.d0cstdeclst) = d0cstdeclst_cons((yyvsp[(2) - (3)].d0cstdec), (yyvsp[(3) - (3)].d0cstdeclst)) ; } break; case 347: /* Line 1806 of yacc.c */ #line 2259 "ats_grammar.yats" { (yyval.s0vararg) = s0vararg_one() ; } break; case 348: /* Line 1806 of yacc.c */ #line 2260 "ats_grammar.yats" { (yyval.s0vararg) = s0vararg_all() ; } break; case 349: /* Line 1806 of yacc.c */ #line 2261 "ats_grammar.yats" { (yyval.s0vararg) = s0vararg_seq((yyvsp[(1) - (1)].s0arglst)) ; } break; case 350: /* Line 1806 of yacc.c */ #line 2265 "ats_grammar.yats" { (yyval.s0exparg) = s0exparg_one() ; } break; case 351: /* Line 1806 of yacc.c */ #line 2266 "ats_grammar.yats" { (yyval.s0exparg) = s0exparg_all() ; } break; case 352: /* Line 1806 of yacc.c */ #line 2267 "ats_grammar.yats" { (yyval.s0exparg) = s0exparg_seq((yyvsp[(1) - (1)].s0explst)) ; } break; case 353: /* Line 1806 of yacc.c */ #line 2271 "ats_grammar.yats" { (yyval.s0elop) = s0elop_make (0, (yyvsp[(1) - (1)].t0kn)) ; } break; case 354: /* Line 1806 of yacc.c */ #line 2272 "ats_grammar.yats" { (yyval.s0elop) = s0elop_make (1, (yyvsp[(1) - (1)].t0kn)) ; } break; case 355: /* Line 1806 of yacc.c */ #line 2276 "ats_grammar.yats" { (yyval.witht0ype) = witht0ype_none() ; } break; case 356: /* Line 1806 of yacc.c */ #line 2277 "ats_grammar.yats" { (yyval.witht0ype) = witht0ype_prop((yyvsp[(2) - (2)].s0exp)) ; } break; case 357: /* Line 1806 of yacc.c */ #line 2278 "ats_grammar.yats" { (yyval.witht0ype) = witht0ype_type((yyvsp[(2) - (2)].s0exp)) ; } break; case 358: /* Line 1806 of yacc.c */ #line 2279 "ats_grammar.yats" { (yyval.witht0ype) = witht0ype_view((yyvsp[(2) - (2)].s0exp)) ; } break; case 359: /* Line 1806 of yacc.c */ #line 2280 "ats_grammar.yats" { (yyval.witht0ype) = witht0ype_viewtype((yyvsp[(2) - (2)].s0exp)) ; } break; case 360: /* Line 1806 of yacc.c */ #line 2284 "ats_grammar.yats" { (yyval.p0at) = p0at_apps((yyvsp[(1) - (2)].p0at), (yyvsp[(2) - (2)].p0atlst)) ; } break; case 361: /* Line 1806 of yacc.c */ #line 2285 "ats_grammar.yats" { (yyval.p0at) = p0at_ann((yyvsp[(1) - (3)].p0at), (yyvsp[(3) - (3)].s0exp)) ; } break; case 362: /* Line 1806 of yacc.c */ #line 2286 "ats_grammar.yats" { (yyval.p0at) = p0at_as((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].p0at)) ; } break; case 363: /* Line 1806 of yacc.c */ #line 2287 "ats_grammar.yats" { (yyval.p0at) = p0at_refas((yyvsp[(1) - (4)].t0kn), (yyvsp[(2) - (4)].i0de), (yyvsp[(4) - (4)].p0at)) ; } break; case 364: /* Line 1806 of yacc.c */ #line 2288 "ats_grammar.yats" { (yyval.p0at) = p0at_free((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].p0at)) ; } break; case 365: /* Line 1806 of yacc.c */ #line 2292 "ats_grammar.yats" { (yyval.p0at) = p0at_char((yyvsp[(1) - (1)].c0har)) ; } break; case 366: /* Line 1806 of yacc.c */ #line 2293 "ats_grammar.yats" { (yyval.p0at) = p0at_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 367: /* Line 1806 of yacc.c */ #line 2294 "ats_grammar.yats" { (yyval.p0at) = p0at_float((yyvsp[(1) - (1)].f0loat)) ; } break; case 368: /* Line 1806 of yacc.c */ #line 2295 "ats_grammar.yats" { (yyval.p0at) = p0at_string((yyvsp[(1) - (1)].s0tring)) ; } break; case 369: /* Line 1806 of yacc.c */ #line 2296 "ats_grammar.yats" { (yyval.p0at) = p0at_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 370: /* Line 1806 of yacc.c */ #line 2297 "ats_grammar.yats" { (yyval.p0at) = p0at_ref((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0de)) ; } break; case 371: /* Line 1806 of yacc.c */ #line 2298 "ats_grammar.yats" { (yyval.p0at) = p0at_opide((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0de)) ; } break; case 372: /* Line 1806 of yacc.c */ #line 2299 "ats_grammar.yats" { (yyval.p0at) = p0at_qid((yyvsp[(1) - (2)].d0ynq), (yyvsp[(2) - (2)].i0de)) ; } break; case 373: /* Line 1806 of yacc.c */ #line 2300 "ats_grammar.yats" { (yyval.p0at) = p0at_list((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 374: /* Line 1806 of yacc.c */ #line 2301 "ats_grammar.yats" { (yyval.p0at) = p0at_list2((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].p0atlst), (yyvsp[(4) - (5)].p0atlst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 375: /* Line 1806 of yacc.c */ #line 2302 "ats_grammar.yats" { (yyval.p0at) = p0at_lst((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 376: /* Line 1806 of yacc.c */ #line 2303 "ats_grammar.yats" { (yyval.p0at) = p0at_tup(0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 377: /* Line 1806 of yacc.c */ #line 2304 "ats_grammar.yats" { (yyval.p0at) = p0at_tup(1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 378: /* Line 1806 of yacc.c */ #line 2305 "ats_grammar.yats" { (yyval.p0at) = p0at_tup2(0, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].p0atlst), (yyvsp[(4) - (5)].p0atlst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 379: /* Line 1806 of yacc.c */ #line 2306 "ats_grammar.yats" { (yyval.p0at) = p0at_tup2(1, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].p0atlst), (yyvsp[(4) - (5)].p0atlst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 380: /* Line 1806 of yacc.c */ #line 2307 "ats_grammar.yats" { (yyval.p0at) = p0at_rec(0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labp0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 381: /* Line 1806 of yacc.c */ #line 2308 "ats_grammar.yats" { (yyval.p0at) = p0at_rec(1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labp0atlst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 382: /* Line 1806 of yacc.c */ #line 2309 "ats_grammar.yats" { (yyval.p0at) = p0at_exist((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0arglst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 383: /* Line 1806 of yacc.c */ #line 2313 "ats_grammar.yats" { (yyval.p0at) = (yyvsp[(1) - (1)].p0at) ; } break; case 384: /* Line 1806 of yacc.c */ #line 2314 "ats_grammar.yats" { (yyval.p0at) = p0at_svararg((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0vararg), (yyvsp[(3) - (3)].t0kn)) ; } break; case 385: /* Line 1806 of yacc.c */ #line 2318 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_nil() ; } break; case 386: /* Line 1806 of yacc.c */ #line 2319 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_cons((yyvsp[(1) - (2)].p0at), (yyvsp[(2) - (2)].p0atlst)) ; } break; case 387: /* Line 1806 of yacc.c */ #line 2323 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_nil() ; } break; case 388: /* Line 1806 of yacc.c */ #line 2324 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_cons((yyvsp[(1) - (2)].p0at), (yyvsp[(2) - (2)].p0atlst)) ; } break; case 389: /* Line 1806 of yacc.c */ #line 2328 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_nil() ; } break; case 390: /* Line 1806 of yacc.c */ #line 2329 "ats_grammar.yats" { (yyval.p0atlst) = p0atlst_cons((yyvsp[(2) - (3)].p0at), (yyvsp[(3) - (3)].p0atlst)) ; } break; case 391: /* Line 1806 of yacc.c */ #line 2333 "ats_grammar.yats" { (yyval.labp0atlst) = labp0atlst_dot() ; } break; case 392: /* Line 1806 of yacc.c */ #line 2334 "ats_grammar.yats" { (yyval.labp0atlst) = labp0atlst_cons((yyvsp[(1) - (4)].l0ab), (yyvsp[(3) - (4)].p0at), (yyvsp[(4) - (4)].labp0atlst)) ; } break; case 393: /* Line 1806 of yacc.c */ #line 2338 "ats_grammar.yats" { (yyval.labp0atlst) = labp0atlst_nil() ; } break; case 394: /* Line 1806 of yacc.c */ #line 2339 "ats_grammar.yats" { (yyval.labp0atlst) = labp0atlst_dot() ; } break; case 395: /* Line 1806 of yacc.c */ #line 2340 "ats_grammar.yats" { (yyval.labp0atlst) = labp0atlst_cons((yyvsp[(2) - (5)].l0ab), (yyvsp[(4) - (5)].p0at), (yyvsp[(5) - (5)].labp0atlst)) ; } break; case 396: /* Line 1806 of yacc.c */ #line 2344 "ats_grammar.yats" { (yyval.f0arg) = f0arg_sta1((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0qualst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 397: /* Line 1806 of yacc.c */ #line 2345 "ats_grammar.yats" { (yyval.f0arg) = f0arg_dyn((yyvsp[(1) - (1)].p0at)) ; } break; case 398: /* Line 1806 of yacc.c */ #line 2346 "ats_grammar.yats" { (yyval.f0arg) = f0arg_met_some((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 399: /* Line 1806 of yacc.c */ #line 2347 "ats_grammar.yats" { (yyval.f0arg) = f0arg_met_none((yyvsp[(1) - (1)].t0kn)) ; } break; case 400: /* Line 1806 of yacc.c */ #line 2351 "ats_grammar.yats" { (yyval.f0arglst) = f0arglst_nil() ; } break; case 401: /* Line 1806 of yacc.c */ #line 2352 "ats_grammar.yats" { (yyval.f0arglst) = f0arglst_cons((yyvsp[(1) - (2)].f0arg), (yyvsp[(2) - (2)].f0arglst)) ; } break; case 402: /* Line 1806 of yacc.c */ #line 2356 "ats_grammar.yats" { (yyval.f0arg) = f0arg_sta2((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0arglst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 403: /* Line 1806 of yacc.c */ #line 2357 "ats_grammar.yats" { (yyval.f0arg) = f0arg_dyn((yyvsp[(1) - (1)].p0at)) ; } break; case 404: /* Line 1806 of yacc.c */ #line 2361 "ats_grammar.yats" { (yyval.f0arglst) = f0arglst_nil() ; } break; case 405: /* Line 1806 of yacc.c */ #line 2362 "ats_grammar.yats" { (yyval.f0arglst) = f0arglst_cons((yyvsp[(1) - (2)].f0arg), (yyvsp[(2) - (2)].f0arglst)) ; } break; case 406: /* Line 1806 of yacc.c */ #line 2366 "ats_grammar.yats" { (yyval.d0exp) = d0exp_apps((yyvsp[(1) - (2)].d0exp), (yyvsp[(2) - (2)].d0explst)) ; } break; case 407: /* Line 1806 of yacc.c */ #line 2367 "ats_grammar.yats" { (yyval.d0exp) = d0exp_ann((yyvsp[(1) - (3)].d0exp), (yyvsp[(3) - (3)].s0exp)) ; } break; case 408: /* Line 1806 of yacc.c */ #line 2368 "ats_grammar.yats" { (yyval.d0exp) = d0exp_if_none((yyvsp[(1) - (4)].ifhead), (yyvsp[(2) - (4)].d0exp), (yyvsp[(4) - (4)].d0exp)) ; } break; case 409: /* Line 1806 of yacc.c */ #line 2369 "ats_grammar.yats" { (yyval.d0exp) = d0exp_if_some((yyvsp[(1) - (6)].ifhead), (yyvsp[(2) - (6)].d0exp), (yyvsp[(4) - (6)].d0exp), (yyvsp[(6) - (6)].d0exp)) ; } break; case 410: /* Line 1806 of yacc.c */ #line 2370 "ats_grammar.yats" { (yyval.d0exp) = d0exp_sif((yyvsp[(1) - (6)].ifhead), (yyvsp[(2) - (6)].s0exp), (yyvsp[(4) - (6)].d0exp), (yyvsp[(6) - (6)].d0exp)) ; } break; case 411: /* Line 1806 of yacc.c */ #line 2371 "ats_grammar.yats" { (yyval.d0exp) = d0exp_caseof((yyvsp[(1) - (4)].casehead), (yyvsp[(2) - (4)].d0exp), (yyvsp[(3) - (4)].t0kn), (yyvsp[(4) - (4)].c0laulst)) ; } break; case 412: /* Line 1806 of yacc.c */ #line 2372 "ats_grammar.yats" { (yyval.d0exp) = d0exp_scaseof((yyvsp[(1) - (4)].casehead), (yyvsp[(2) - (4)].s0exp), (yyvsp[(3) - (4)].t0kn), (yyvsp[(4) - (4)].sc0laulst)) ; } break; case 413: /* Line 1806 of yacc.c */ #line 2373 "ats_grammar.yats" { (yyval.d0exp) = d0exp_lam((yyvsp[(1) - (5)].lamkind), (yyvsp[(2) - (5)].f0arglst), (yyvsp[(3) - (5)].s0expopt), (yyvsp[(4) - (5)].e0fftaglstopt), (yyvsp[(5) - (5)].d0exp) ) ; } break; case 414: /* Line 1806 of yacc.c */ #line 2374 "ats_grammar.yats" { (yyval.d0exp) = d0exp_fix((yyvsp[(1) - (6)].fixkind), (yyvsp[(2) - (6)].i0de), (yyvsp[(3) - (6)].f0arglst), (yyvsp[(4) - (6)].s0expopt), (yyvsp[(5) - (6)].e0fftaglstopt), (yyvsp[(6) - (6)].d0exp)) ; } break; case 415: /* Line 1806 of yacc.c */ #line 2375 "ats_grammar.yats" { (yyval.d0exp) = d0exp_for_itp ((yyvsp[(1) - (3)].loophead), (yyvsp[(2) - (3)].initestpost), (yyvsp[(3) - (3)].d0exp)) ; } break; case 416: /* Line 1806 of yacc.c */ #line 2376 "ats_grammar.yats" { (yyval.d0exp) = d0exp_while ((yyvsp[(1) - (3)].loophead), (yyvsp[(2) - (3)].d0exp), (yyvsp[(3) - (3)].d0exp)) ; } break; case 417: /* Line 1806 of yacc.c */ #line 2377 "ats_grammar.yats" { (yyval.d0exp) = d0exp_raise((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].d0exp)) ; } break; case 418: /* Line 1806 of yacc.c */ #line 2378 "ats_grammar.yats" { (yyval.d0exp) = d0exp_showtype((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].d0exp)) ; } break; case 419: /* Line 1806 of yacc.c */ #line 2379 "ats_grammar.yats" { (yyval.d0exp) = d0exp_trywith_seq((yyvsp[(1) - (4)].tryhead), (yyvsp[(2) - (4)].d0explst), (yyvsp[(3) - (4)].t0kn), (yyvsp[(4) - (4)].c0laulst)) ; } break; case 420: /* Line 1806 of yacc.c */ #line 2380 "ats_grammar.yats" { (yyval.d0exp) = d0exp_where ((yyvsp[(1) - (5)].d0exp), (yyvsp[(4) - (5)].d0eclst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 421: /* Line 1806 of yacc.c */ #line 2384 "ats_grammar.yats" { (yyval.d0exp) = d0exp_char((yyvsp[(1) - (1)].c0har)) ; } break; case 422: /* Line 1806 of yacc.c */ #line 2385 "ats_grammar.yats" { (yyval.d0exp) = d0exp_float((yyvsp[(1) - (1)].f0loat)) ; } break; case 423: /* Line 1806 of yacc.c */ #line 2386 "ats_grammar.yats" { (yyval.d0exp) = d0exp_floatsp((yyvsp[(1) - (1)].f0loatsp)) ; } break; case 424: /* Line 1806 of yacc.c */ #line 2387 "ats_grammar.yats" { (yyval.d0exp) = d0exp_int((yyvsp[(1) - (1)].i0nt)) ; } break; case 425: /* Line 1806 of yacc.c */ #line 2388 "ats_grammar.yats" { (yyval.d0exp) = d0exp_intsp((yyvsp[(1) - (1)].i0ntsp)) ; } break; case 426: /* Line 1806 of yacc.c */ #line 2389 "ats_grammar.yats" { (yyval.d0exp) = d0exp_string((yyvsp[(1) - (1)].s0tring)) ; } break; case 427: /* Line 1806 of yacc.c */ #line 2390 "ats_grammar.yats" { (yyval.d0exp) = d0exp_FILENAME((yyvsp[(1) - (1)].t0kn)) ; } break; case 428: /* Line 1806 of yacc.c */ #line 2391 "ats_grammar.yats" { (yyval.d0exp) = d0exp_LOCATION((yyvsp[(1) - (1)].t0kn)) ; } break; case 429: /* Line 1806 of yacc.c */ #line 2392 "ats_grammar.yats" { (yyval.d0exp) = d0exp_ide((yyvsp[(1) - (1)].i0de)) ; } break; case 430: /* Line 1806 of yacc.c */ #line 2393 "ats_grammar.yats" { (yyval.d0exp) = d0exp_opide((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0de)) ; } break; case 431: /* Line 1806 of yacc.c */ #line 2394 "ats_grammar.yats" { (yyval.d0exp) = d0exp_qid((yyvsp[(1) - (2)].d0ynq), (yyvsp[(2) - (2)].i0de)) ; } break; case 432: /* Line 1806 of yacc.c */ #line 2395 "ats_grammar.yats" { (yyval.d0exp) = d0exp_idext((yyvsp[(1) - (1)].i0de)) ; } break; case 433: /* Line 1806 of yacc.c */ #line 2396 "ats_grammar.yats" { (yyval.d0exp) = d0exp_ptrof((yyvsp[(1) - (1)].t0kn)) ; } break; case 434: /* Line 1806 of yacc.c */ #line 2397 "ats_grammar.yats" { (yyval.d0exp) = d0exp_loopexn(0, (yyvsp[(1) - (1)].t0kn)) ; } break; case 435: /* Line 1806 of yacc.c */ #line 2398 "ats_grammar.yats" { (yyval.d0exp) = d0exp_loopexn(1, (yyvsp[(1) - (1)].t0kn)) ; } break; case 436: /* Line 1806 of yacc.c */ #line 2399 "ats_grammar.yats" { (yyval.d0exp) = d0exp_foldat((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].d0explst)) ; } break; case 437: /* Line 1806 of yacc.c */ #line 2400 "ats_grammar.yats" { (yyval.d0exp) = d0exp_freeat((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].d0explst)) ; } break; case 438: /* Line 1806 of yacc.c */ #line 2401 "ats_grammar.yats" { (yyval.d0exp) = d0exp_viewat((yyvsp[(1) - (1)].t0kn)) ; } break; case 439: /* Line 1806 of yacc.c */ #line 2402 "ats_grammar.yats" { (yyval.d0exp) = d0exp_crypt (-1, (yyvsp[(1) - (1)].t0kn)) ; } break; case 440: /* Line 1806 of yacc.c */ #line 2403 "ats_grammar.yats" { (yyval.d0exp) = d0exp_crypt ( 1, (yyvsp[(1) - (1)].t0kn)) ; } break; case 441: /* Line 1806 of yacc.c */ #line 2404 "ats_grammar.yats" { (yyval.d0exp) = d0exp_delay(0, (yyvsp[(1) - (1)].t0kn)) ; } break; case 442: /* Line 1806 of yacc.c */ #line 2405 "ats_grammar.yats" { (yyval.d0exp) = d0exp_delay(1, (yyvsp[(1) - (1)].t0kn)) ; } break; case 443: /* Line 1806 of yacc.c */ #line 2406 "ats_grammar.yats" { (yyval.d0exp) = d0exp_dynload((yyvsp[(1) - (1)].t0kn)) ; } break; case 444: /* Line 1806 of yacc.c */ #line 2407 "ats_grammar.yats" { (yyval.d0exp) = d0exp_effmask_all((yyvsp[(1) - (1)].t0kn)) ; } break; case 445: /* Line 1806 of yacc.c */ #line 2408 "ats_grammar.yats" { (yyval.d0exp) = d0exp_effmask_exn((yyvsp[(1) - (1)].t0kn)) ; } break; case 446: /* Line 1806 of yacc.c */ #line 2409 "ats_grammar.yats" { (yyval.d0exp) = d0exp_effmask_ntm((yyvsp[(1) - (1)].t0kn)) ; } break; case 447: /* Line 1806 of yacc.c */ #line 2410 "ats_grammar.yats" { (yyval.d0exp) = d0exp_effmask_ref((yyvsp[(1) - (1)].t0kn)) ; } break; case 448: /* Line 1806 of yacc.c */ #line 2411 "ats_grammar.yats" { (yyval.d0exp) = d0exp_arrinit_none ((yyvsp[(1) - (6)].t0kn), (yyvsp[(2) - (6)].s0exp), (yyvsp[(5) - (6)].d0explst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 449: /* Line 1806 of yacc.c */ #line 2412 "ats_grammar.yats" { (yyval.d0exp) = d0exp_arrinit_some ((yyvsp[(1) - (9)].t0kn), (yyvsp[(2) - (9)].s0exp), (yyvsp[(5) - (9)].d0exp), (yyvsp[(8) - (9)].d0explst), (yyvsp[(9) - (9)].t0kn)) ; } break; case 450: /* Line 1806 of yacc.c */ #line 2413 "ats_grammar.yats" { (yyval.d0exp) = d0exp_arrpsz ((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0expopt), (yyvsp[(3) - (5)].t0kn), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 451: /* Line 1806 of yacc.c */ #line 2414 "ats_grammar.yats" { (yyval.d0exp) = d0exp_arrsub ((yyvsp[(1) - (2)].arrqi0de), (yyvsp[(2) - (2)].d0arrind)) ; } break; case 452: /* Line 1806 of yacc.c */ #line 2415 "ats_grammar.yats" { (yyval.d0exp) = d0exp_sel_lab ((yyvsp[(1) - (2)].s0elop), (yyvsp[(2) - (2)].l0ab)) ; } break; case 453: /* Line 1806 of yacc.c */ #line 2416 "ats_grammar.yats" { (yyval.d0exp) = d0exp_sel_ind ((yyvsp[(1) - (3)].s0elop), (yyvsp[(3) - (3)].d0arrind)) ; } break; case 454: /* Line 1806 of yacc.c */ #line 2417 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tmpid ((yyvsp[(1) - (4)].tmpqi0de), (yyvsp[(2) - (4)].s0explst), (yyvsp[(3) - (4)].t1mps0explstlst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 455: /* Line 1806 of yacc.c */ #line 2418 "ats_grammar.yats" { (yyval.d0exp) = d0exp_exist ((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0exparg), (yyvsp[(3) - (5)].t0kn), (yyvsp[(4) - (5)].d0exp), (yyvsp[(5) - (5)].t0kn)) ; } break; case 456: /* Line 1806 of yacc.c */ #line 2419 "ats_grammar.yats" { (yyval.d0exp) = d0exp_list ((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 457: /* Line 1806 of yacc.c */ #line 2420 "ats_grammar.yats" { (yyval.d0exp) = d0exp_list2 ((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0explst), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 458: /* Line 1806 of yacc.c */ #line 2421 "ats_grammar.yats" { (yyval.d0exp) = d0exp_lst (0, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0expopt), (yyvsp[(3) - (5)].t0kn), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 459: /* Line 1806 of yacc.c */ #line 2422 "ats_grammar.yats" { (yyval.d0exp) = d0exp_lst (1, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].s0expopt), (yyvsp[(3) - (5)].t0kn), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 460: /* Line 1806 of yacc.c */ #line 2423 "ats_grammar.yats" { (yyval.d0exp) = d0exp_lst_quote ((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 461: /* Line 1806 of yacc.c */ #line 2424 "ats_grammar.yats" { (yyval.d0exp) = d0exp_seq ((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 462: /* Line 1806 of yacc.c */ #line 2425 "ats_grammar.yats" { (yyval.d0exp) = d0exp_seq ((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 463: /* Line 1806 of yacc.c */ #line 2426 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup (0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 464: /* Line 1806 of yacc.c */ #line 2427 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup (1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 465: /* Line 1806 of yacc.c */ #line 2428 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup (2, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].d0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 466: /* Line 1806 of yacc.c */ #line 2429 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup (3, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].d0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 467: /* Line 1806 of yacc.c */ #line 2430 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup2 (0, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0explst), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 468: /* Line 1806 of yacc.c */ #line 2431 "ats_grammar.yats" { (yyval.d0exp) = d0exp_tup2 (1, (yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0explst), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 469: /* Line 1806 of yacc.c */ #line 2432 "ats_grammar.yats" { (yyval.d0exp) = d0exp_rec (0, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labd0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 470: /* Line 1806 of yacc.c */ #line 2433 "ats_grammar.yats" { (yyval.d0exp) = d0exp_rec (1, (yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].labd0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 471: /* Line 1806 of yacc.c */ #line 2434 "ats_grammar.yats" { (yyval.d0exp) = d0exp_rec (2, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].labd0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 472: /* Line 1806 of yacc.c */ #line 2435 "ats_grammar.yats" { (yyval.d0exp) = d0exp_rec (3, (yyvsp[(1) - (4)].t0kn), (yyvsp[(3) - (4)].labd0explst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 473: /* Line 1806 of yacc.c */ #line 2436 "ats_grammar.yats" { (yyval.d0exp) = d0exp_extval((yyvsp[(1) - (6)].t0kn), (yyvsp[(3) - (6)].s0exp), (yyvsp[(5) - (6)].s0tring), (yyvsp[(6) - (6)].t0kn)) ; } break; case 474: /* Line 1806 of yacc.c */ #line 2437 "ats_grammar.yats" { (yyval.d0exp) = d0exp_macsyn_cross((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0exp), (yyvsp[(3) - (3)].t0kn)) ; } break; case 475: /* Line 1806 of yacc.c */ #line 2438 "ats_grammar.yats" { (yyval.d0exp) = d0exp_macsyn_decode((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0exp), (yyvsp[(3) - (3)].t0kn)) ; } break; case 476: /* Line 1806 of yacc.c */ #line 2439 "ats_grammar.yats" { (yyval.d0exp) = d0exp_macsyn_encode_seq((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0explst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 477: /* Line 1806 of yacc.c */ #line 2440 "ats_grammar.yats" { (yyval.d0exp) = d0exp_let_seq((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0eclst), (yyvsp[(3) - (5)].t0kn), (yyvsp[(4) - (5)].d0explst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 478: /* Line 1806 of yacc.c */ #line 2441 "ats_grammar.yats" { (yyval.d0exp) = d0exp_decseq((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].d0eclst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 479: /* Line 1806 of yacc.c */ #line 2445 "ats_grammar.yats" { (yyval.d0exp) = d0exp_sexparg((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0exparg), (yyvsp[(3) - (3)].t0kn)) ; } break; case 480: /* Line 1806 of yacc.c */ #line 2449 "ats_grammar.yats" { (yyval.d0explst) = d0explst_nil() ; } break; case 481: /* Line 1806 of yacc.c */ #line 2450 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(1) - (2)].d0exp), (yyvsp[(2) - (2)].d0explst)) ; } break; case 482: /* Line 1806 of yacc.c */ #line 2454 "ats_grammar.yats" { (yyval.d0exp) = (yyvsp[(1) - (1)].d0exp) ; } break; case 483: /* Line 1806 of yacc.c */ #line 2455 "ats_grammar.yats" { (yyval.d0exp) = (yyvsp[(1) - (1)].d0exp) ; } break; case 484: /* Line 1806 of yacc.c */ #line 2459 "ats_grammar.yats" { (yyval.d0explst) = d0explst_nil() ; } break; case 485: /* Line 1806 of yacc.c */ #line 2460 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(1) - (2)].d0exp), (yyvsp[(2) - (2)].d0explst)) ; } break; case 486: /* Line 1806 of yacc.c */ #line 2464 "ats_grammar.yats" { (yyval.d0arrind) = d0arrind_make_sing((yyvsp[(1) - (2)].d0explst), (yyvsp[(2) - (2)].t0kn)) ; } break; case 487: /* Line 1806 of yacc.c */ #line 2465 "ats_grammar.yats" { (yyval.d0arrind) = d0arrind_make_cons((yyvsp[(1) - (4)].d0explst), (yyvsp[(4) - (4)].d0arrind)) ; } break; case 488: /* Line 1806 of yacc.c */ #line 2469 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_none() ; } break; case 489: /* Line 1806 of yacc.c */ #line 2470 "ats_grammar.yats" { (yyval.s0expopt) = s0expopt_some((yyvsp[(2) - (2)].s0exp)) ; } break; case 490: /* Line 1806 of yacc.c */ #line 2474 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_none() ; } break; case 491: /* Line 1806 of yacc.c */ #line 2475 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_some(e0fftaglst_nil()) ; } break; case 492: /* Line 1806 of yacc.c */ #line 2476 "ats_grammar.yats" { (yyval.e0fftaglstopt) = e0fftaglstopt_some((yyvsp[(2) - (3)].e0fftaglst)) ; } break; case 493: /* Line 1806 of yacc.c */ #line 2480 "ats_grammar.yats" { (yyval.i0nvresstate) = i0nvresstate_none() ; } break; case 494: /* Line 1806 of yacc.c */ #line 2481 "ats_grammar.yats" { (yyval.i0nvresstate) = (yyvsp[(1) - (2)].i0nvresstate) ; } break; case 495: /* Line 1806 of yacc.c */ #line 2485 "ats_grammar.yats" { (yyval.ifhead) = ifhead_make((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 496: /* Line 1806 of yacc.c */ #line 2489 "ats_grammar.yats" { (yyval.ifhead) = ifhead_make((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 497: /* Line 1806 of yacc.c */ #line 2493 "ats_grammar.yats" { (yyval.casehead) = casehead_make(0, (yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 498: /* Line 1806 of yacc.c */ #line 2494 "ats_grammar.yats" { (yyval.casehead) = casehead_make(-1, (yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 499: /* Line 1806 of yacc.c */ #line 2495 "ats_grammar.yats" { (yyval.casehead) = casehead_make(1, (yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 500: /* Line 1806 of yacc.c */ #line 2499 "ats_grammar.yats" { (yyval.casehead) = casehead_make(0, (yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0nvresstate)) ; } break; case 501: /* Line 1806 of yacc.c */ #line 2503 "ats_grammar.yats" { (yyval.loophead) = loophead_make_none((yyvsp[(1) - (1)].t0kn)) ; } break; case 502: /* Line 1806 of yacc.c */ #line 2504 "ats_grammar.yats" { (yyval.loophead) = loophead_make_some((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].loopi0nv), (yyvsp[(3) - (3)].t0kn)) ; } break; case 503: /* Line 1806 of yacc.c */ #line 2508 "ats_grammar.yats" { (yyval.loophead) = loophead_make_some((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].loopi0nv), (yyvsp[(3) - (3)].t0kn)) ; } break; case 504: /* Line 1806 of yacc.c */ #line 2512 "ats_grammar.yats" { (yyval.tryhead) = tryhead_make((yyvsp[(1) - (1)].t0kn)) ; } break; case 505: /* Line 1806 of yacc.c */ #line 2516 "ats_grammar.yats" { (yyval.d0explst) = d0explst_nil() ; } break; case 506: /* Line 1806 of yacc.c */ #line 2517 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(1) - (2)].d0exp), (yyvsp[(2) - (2)].d0explst)) ; } break; case 507: /* Line 1806 of yacc.c */ #line 2521 "ats_grammar.yats" { (yyval.d0explst) = d0explst_nil() ; } break; case 508: /* Line 1806 of yacc.c */ #line 2522 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(2) - (3)].d0exp), (yyvsp[(3) - (3)].d0explst)) ; } break; case 509: /* Line 1806 of yacc.c */ #line 2526 "ats_grammar.yats" { (yyval.d0explst) = d0explst_nil() ; } break; case 510: /* Line 1806 of yacc.c */ #line 2527 "ats_grammar.yats" { (yyval.d0explst) = d0explst_sing((yyvsp[(1) - (1)].d0exp)) ; } break; case 511: /* Line 1806 of yacc.c */ #line 2528 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(1) - (3)].d0exp), (yyvsp[(3) - (3)].d0explst)) ; } break; case 512: /* Line 1806 of yacc.c */ #line 2532 "ats_grammar.yats" { (yyval.d0explst) = d0explst_cons((yyvsp[(1) - (3)].d0exp), (yyvsp[(3) - (3)].d0explst)) ; } break; case 513: /* Line 1806 of yacc.c */ #line 2536 "ats_grammar.yats" { (yyval.labd0explst) = labd0explst_nil() ; } break; case 514: /* Line 1806 of yacc.c */ #line 2537 "ats_grammar.yats" { (yyval.labd0explst) = labd0explst_cons((yyvsp[(1) - (4)].l0ab), (yyvsp[(3) - (4)].d0exp), (yyvsp[(4) - (4)].labd0explst)) ; } break; case 515: /* Line 1806 of yacc.c */ #line 2541 "ats_grammar.yats" { (yyval.labd0explst) = labd0explst_nil() ; } break; case 516: /* Line 1806 of yacc.c */ #line 2542 "ats_grammar.yats" { (yyval.labd0explst) = labd0explst_cons((yyvsp[(2) - (5)].l0ab), (yyvsp[(4) - (5)].d0exp), (yyvsp[(5) - (5)].labd0explst)) ; } break; case 517: /* Line 1806 of yacc.c */ #line 2546 "ats_grammar.yats" { (yyval.m0atch) = m0atch_make_none ((yyvsp[(1) - (1)].d0exp)) ; } break; case 518: /* Line 1806 of yacc.c */ #line 2547 "ats_grammar.yats" { (yyval.m0atch) = m0atch_make_some ((yyvsp[(1) - (3)].d0exp), (yyvsp[(3) - (3)].p0at)) ; } break; case 519: /* Line 1806 of yacc.c */ #line 2551 "ats_grammar.yats" { (yyval.m0atchlst) = m0atchlst_cons ((yyvsp[(1) - (2)].m0atch), (yyvsp[(2) - (2)].m0atchlst) ) ; } break; case 520: /* Line 1806 of yacc.c */ #line 2555 "ats_grammar.yats" { (yyval.m0atchlst) = m0atchlst_nil () ; } break; case 521: /* Line 1806 of yacc.c */ #line 2556 "ats_grammar.yats" { (yyval.m0atchlst) = m0atchlst_cons ((yyvsp[(2) - (3)].m0atch), (yyvsp[(3) - (3)].m0atchlst) ) ; } break; case 522: /* Line 1806 of yacc.c */ #line 2560 "ats_grammar.yats" { (yyval.guap0at) = guap0at_make_none((yyvsp[(1) - (1)].p0at)) ; } break; case 523: /* Line 1806 of yacc.c */ #line 2561 "ats_grammar.yats" { (yyval.guap0at) = guap0at_make_some((yyvsp[(1) - (3)].p0at), (yyvsp[(3) - (3)].m0atchlst)) ; } break; case 524: /* Line 1806 of yacc.c */ #line 2565 "ats_grammar.yats" { (yyval.c0lau) = c0lau_make ((yyvsp[(1) - (3)].guap0at), 0, 0, (yyvsp[(3) - (3)].d0exp)) ; } break; case 525: /* Line 1806 of yacc.c */ #line 2566 "ats_grammar.yats" { (yyval.c0lau) = c0lau_make ((yyvsp[(1) - (3)].guap0at), 1, 0, (yyvsp[(3) - (3)].d0exp)) ; } break; case 526: /* Line 1806 of yacc.c */ #line 2567 "ats_grammar.yats" { (yyval.c0lau) = c0lau_make ((yyvsp[(1) - (3)].guap0at), 0, 1, (yyvsp[(3) - (3)].d0exp)) ; } break; case 527: /* Line 1806 of yacc.c */ #line 2568 "ats_grammar.yats" { (yyval.c0lau) = c0lau_make ((yyvsp[(1) - (3)].guap0at), 1, 1, (yyvsp[(3) - (3)].d0exp)) ; } break; case 528: /* Line 1806 of yacc.c */ #line 2572 "ats_grammar.yats" { (yyval.c0laulst) = (yyvsp[(1) - (1)].c0laulst) ; } break; case 529: /* Line 1806 of yacc.c */ #line 2573 "ats_grammar.yats" { (yyval.c0laulst) = c0laulst_cons((yyvsp[(1) - (2)].c0lau), (yyvsp[(2) - (2)].c0laulst)) ; } break; case 530: /* Line 1806 of yacc.c */ #line 2577 "ats_grammar.yats" { (yyval.c0laulst) = c0laulst_nil() ; } break; case 531: /* Line 1806 of yacc.c */ #line 2578 "ats_grammar.yats" { (yyval.c0laulst) = c0laulst_cons((yyvsp[(2) - (3)].c0lau), (yyvsp[(3) - (3)].c0laulst)) ; } break; case 532: /* Line 1806 of yacc.c */ #line 2582 "ats_grammar.yats" { (yyval.sc0lau) = sc0lau_make((yyvsp[(1) - (3)].sp0at), (yyvsp[(3) - (3)].d0exp)) ; } break; case 533: /* Line 1806 of yacc.c */ #line 2586 "ats_grammar.yats" { (yyval.sc0laulst) = (yyvsp[(1) - (1)].sc0laulst) ; } break; case 534: /* Line 1806 of yacc.c */ #line 2587 "ats_grammar.yats" { (yyval.sc0laulst) = sc0laulst_cons((yyvsp[(1) - (2)].sc0lau), (yyvsp[(2) - (2)].sc0laulst)) ; } break; case 535: /* Line 1806 of yacc.c */ #line 2591 "ats_grammar.yats" { (yyval.sc0laulst) = sc0laulst_nil() ; } break; case 536: /* Line 1806 of yacc.c */ #line 2592 "ats_grammar.yats" { (yyval.sc0laulst) = sc0laulst_cons((yyvsp[(2) - (3)].sc0lau), (yyvsp[(3) - (3)].sc0laulst)) ; } break; case 537: /* Line 1806 of yacc.c */ #line 2596 "ats_grammar.yats" { (yyval.s0qualstopt) = s0qualstopt_none() ; } break; case 538: /* Line 1806 of yacc.c */ #line 2597 "ats_grammar.yats" { (yyval.s0qualstopt) = s0qualstopt_some((yyvsp[(2) - (3)].s0qualst)) ; } break; case 539: /* Line 1806 of yacc.c */ #line 2601 "ats_grammar.yats" { (yyval.s0qualstopt) = s0explstopt_none() ; } break; case 540: /* Line 1806 of yacc.c */ #line 2602 "ats_grammar.yats" { (yyval.s0qualstopt) = s0explstopt_some((yyvsp[(2) - (3)].s0explst)) ; } break; case 541: /* Line 1806 of yacc.c */ #line 2603 "ats_grammar.yats" { (yyval.s0qualstopt) = s0explstopt_some(s0explst_nil()) ; } break; case 542: /* Line 1806 of yacc.c */ #line 2607 "ats_grammar.yats" { (yyval.i0nvarg) = i0nvarg_make_none((yyvsp[(1) - (2)].i0de)) ; } break; case 543: /* Line 1806 of yacc.c */ #line 2608 "ats_grammar.yats" { (yyval.i0nvarg) = i0nvarg_make_some((yyvsp[(1) - (3)].i0de), (yyvsp[(3) - (3)].s0exp)) ; } break; case 544: /* Line 1806 of yacc.c */ #line 2612 "ats_grammar.yats" { (yyval.i0nvarglst) = i0nvarglst_nil() ; } break; case 545: /* Line 1806 of yacc.c */ #line 2613 "ats_grammar.yats" { (yyval.i0nvarglst) = i0nvarglst_cons((yyvsp[(1) - (2)].i0nvarg), (yyvsp[(2) - (2)].i0nvarglst)) ; } break; case 546: /* Line 1806 of yacc.c */ #line 2617 "ats_grammar.yats" { (yyval.i0nvarglst) = i0nvarglst_nil() ; } break; case 547: /* Line 1806 of yacc.c */ #line 2618 "ats_grammar.yats" { (yyval.i0nvarglst) = i0nvarglst_cons((yyvsp[(2) - (3)].i0nvarg), (yyvsp[(3) - (3)].i0nvarglst)) ; } break; case 548: /* Line 1806 of yacc.c */ #line 2622 "ats_grammar.yats" { (yyval.i0nvarglst) = (yyvsp[(2) - (3)].i0nvarglst) ; } break; case 549: /* Line 1806 of yacc.c */ #line 2626 "ats_grammar.yats" { (yyval.s0qualstopt) = s0qualstopt_none() ; } break; case 550: /* Line 1806 of yacc.c */ #line 2627 "ats_grammar.yats" { (yyval.s0qualstopt) = s0qualstopt_some((yyvsp[(2) - (3)].s0qualst)) ; } break; case 551: /* Line 1806 of yacc.c */ #line 2631 "ats_grammar.yats" { (yyval.i0nvresstate) = i0nvresstate_none() ; } break; case 552: /* Line 1806 of yacc.c */ #line 2632 "ats_grammar.yats" { (yyval.i0nvresstate) = i0nvresstate_some((yyvsp[(2) - (5)].s0qualstopt), (yyvsp[(4) - (5)].i0nvarglst)) ; } break; case 553: /* Line 1806 of yacc.c */ #line 2636 "ats_grammar.yats" { (yyval.loopi0nv) = loopi0nv_make((yyvsp[(1) - (4)].s0qualstopt), (yyvsp[(2) - (4)].s0qualstopt), (yyvsp[(3) - (4)].i0nvarglst), (yyvsp[(4) - (4)].i0nvresstate)) ; } break; case 554: /* Line 1806 of yacc.c */ #line 2640 "ats_grammar.yats" { (yyval.initestpost) = initestpost_make ((yyvsp[(1) - (7)].t0kn),(yyvsp[(2) - (7)].d0explst),(yyvsp[(3) - (7)].t0kn),(yyvsp[(4) - (7)].d0explst),(yyvsp[(5) - (7)].t0kn),(yyvsp[(6) - (7)].d0explst),(yyvsp[(7) - (7)].t0kn)) ; } break; case 555: /* Line 1806 of yacc.c */ #line 2644 "ats_grammar.yats" { (yyval.i0de) = (yyvsp[(1) - (1)].i0de) ; } break; case 556: /* Line 1806 of yacc.c */ #line 2648 "ats_grammar.yats" { (yyval.i0delst) = i0delst_nil() ; } break; case 557: /* Line 1806 of yacc.c */ #line 2649 "ats_grammar.yats" { (yyval.i0delst) = i0delst_cons((yyvsp[(1) - (2)].i0de), (yyvsp[(2) - (2)].i0delst)) ; } break; case 558: /* Line 1806 of yacc.c */ #line 2653 "ats_grammar.yats" { (yyval.i0delst) = i0delst_nil() ; } break; case 559: /* Line 1806 of yacc.c */ #line 2654 "ats_grammar.yats" { (yyval.i0delst) = i0delst_cons((yyvsp[(2) - (3)].i0de), (yyvsp[(3) - (3)].i0delst)) ; } break; case 560: /* Line 1806 of yacc.c */ #line 2658 "ats_grammar.yats" { (yyval.m0acarg) = m0acarg_one ((yyvsp[(1) - (1)].i0de)) ; } break; case 561: /* Line 1806 of yacc.c */ #line 2659 "ats_grammar.yats" { (yyval.m0acarg) = m0acarg_lst ((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].i0delst), (yyvsp[(3) - (3)].t0kn)) ; } break; case 562: /* Line 1806 of yacc.c */ #line 2663 "ats_grammar.yats" { (yyval.m0acarglst) = m0acarglst_nil () ; } break; case 563: /* Line 1806 of yacc.c */ #line 2664 "ats_grammar.yats" { (yyval.m0acarglst) = m0acarglst_cons ((yyvsp[(1) - (2)].m0acarg), (yyvsp[(2) - (2)].m0acarglst)) ; } break; case 564: /* Line 1806 of yacc.c */ #line 2668 "ats_grammar.yats" { (yyval.m0acdef) = m0acdef_make((yyvsp[(1) - (4)].i0de), (yyvsp[(2) - (4)].m0acarglst), (yyvsp[(4) - (4)].d0exp)) ; } break; case 565: /* Line 1806 of yacc.c */ #line 2672 "ats_grammar.yats" { (yyval.m0acdeflst) = m0acdeflst_nil() ; } break; case 566: /* Line 1806 of yacc.c */ #line 2673 "ats_grammar.yats" { (yyval.m0acdeflst) = m0acdeflst_cons((yyvsp[(2) - (3)].m0acdef), (yyvsp[(3) - (3)].m0acdeflst)) ; } break; case 567: /* Line 1806 of yacc.c */ #line 2677 "ats_grammar.yats" { (yyval.v0aldec) = v0aldec_make ((yyvsp[(1) - (4)].p0at), (yyvsp[(3) - (4)].d0exp), (yyvsp[(4) - (4)].witht0ype)) ; } break; case 568: /* Line 1806 of yacc.c */ #line 2681 "ats_grammar.yats" { (yyval.v0aldeclst) = v0aldeclst_nil() ; } break; case 569: /* Line 1806 of yacc.c */ #line 2682 "ats_grammar.yats" { (yyval.v0aldeclst) = v0aldeclst_cons((yyvsp[(2) - (3)].v0aldec), (yyvsp[(3) - (3)].v0aldeclst)) ; } break; case 570: /* Line 1806 of yacc.c */ #line 2686 "ats_grammar.yats" { (yyval.f0undec) = f0undec_make_none((yyvsp[(1) - (5)].i0de), (yyvsp[(2) - (5)].f0arglst), (yyvsp[(4) - (5)].d0exp), (yyvsp[(5) - (5)].witht0ype)) ; } break; case 571: /* Line 1806 of yacc.c */ #line 2687 "ats_grammar.yats" { (yyval.f0undec) = f0undec_make_some((yyvsp[(1) - (7)].i0de), (yyvsp[(2) - (7)].f0arglst), (yyvsp[(3) - (7)].e0fftaglstopt), (yyvsp[(4) - (7)].s0exp), (yyvsp[(6) - (7)].d0exp), (yyvsp[(7) - (7)].witht0ype)) ; } break; case 572: /* Line 1806 of yacc.c */ #line 2691 "ats_grammar.yats" { (yyval.f0undeclst) = f0undeclst_nil() ; } break; case 573: /* Line 1806 of yacc.c */ #line 2692 "ats_grammar.yats" { (yyval.f0undeclst) = f0undeclst_cons((yyvsp[(2) - (3)].f0undec), (yyvsp[(3) - (3)].f0undeclst)) ; } break; case 574: /* Line 1806 of yacc.c */ #line 2696 "ats_grammar.yats" { (yyval.v0arwth) = v0arwth_none () ; } break; case 575: /* Line 1806 of yacc.c */ #line 2697 "ats_grammar.yats" { (yyval.v0arwth) = v0arwth_some ((yyvsp[(2) - (2)].i0de)) ; } break; case 576: /* Line 1806 of yacc.c */ #line 2701 "ats_grammar.yats" { (yyval.v0ardec) = v0ardec_make_none_some(0, (yyvsp[(1) - (4)].i0de), (yyvsp[(2) - (4)].v0arwth), (yyvsp[(4) - (4)].d0exp)) ; } break; case 577: /* Line 1806 of yacc.c */ #line 2702 "ats_grammar.yats" { (yyval.v0ardec) = v0ardec_make_none_some(1, (yyvsp[(2) - (5)].i0de), (yyvsp[(3) - (5)].v0arwth), (yyvsp[(5) - (5)].d0exp)) ; } break; case 578: /* Line 1806 of yacc.c */ #line 2703 "ats_grammar.yats" { (yyval.v0ardec) = v0ardec_make_some_none(0, (yyvsp[(1) - (4)].i0de), (yyvsp[(3) - (4)].s0exp), (yyvsp[(4) - (4)].v0arwth)) ; } break; case 579: /* Line 1806 of yacc.c */ #line 2704 "ats_grammar.yats" { (yyval.v0ardec) = v0ardec_make_some_some(0, (yyvsp[(1) - (6)].i0de), (yyvsp[(3) - (6)].s0exp), (yyvsp[(4) - (6)].v0arwth), (yyvsp[(6) - (6)].d0exp)) ; } break; case 580: /* Line 1806 of yacc.c */ #line 2708 "ats_grammar.yats" { (yyval.v0ardeclst) = v0ardeclst_nil() ; } break; case 581: /* Line 1806 of yacc.c */ #line 2709 "ats_grammar.yats" { (yyval.v0ardeclst) = v0ardeclst_cons((yyvsp[(2) - (3)].v0ardec), (yyvsp[(3) - (3)].v0ardeclst)) ; } break; case 582: /* Line 1806 of yacc.c */ #line 2713 "ats_grammar.yats" { (yyval.i0mpdec) = i0mpdec_make((yyvsp[(1) - (5)].impqi0de), (yyvsp[(2) - (5)].f0arglst), (yyvsp[(3) - (5)].s0expopt), (yyvsp[(5) - (5)].d0exp)) ; } break; case 583: /* Line 1806 of yacc.c */ #line 2717 "ats_grammar.yats" { (yyval.d0ec) = d0ec_infix((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0rec), 0, (yyvsp[(3) - (3)].i0delst)) ; } break; case 584: /* Line 1806 of yacc.c */ #line 2718 "ats_grammar.yats" { (yyval.d0ec) = d0ec_infix((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0rec), -1, (yyvsp[(3) - (3)].i0delst)) ; } break; case 585: /* Line 1806 of yacc.c */ #line 2719 "ats_grammar.yats" { (yyval.d0ec) = d0ec_infix((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0rec), 1, (yyvsp[(3) - (3)].i0delst)) ; } break; case 586: /* Line 1806 of yacc.c */ #line 2720 "ats_grammar.yats" { (yyval.d0ec) = d0ec_prefix((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0rec), (yyvsp[(3) - (3)].i0delst)) ; } break; case 587: /* Line 1806 of yacc.c */ #line 2721 "ats_grammar.yats" { (yyval.d0ec) = d0ec_postfix((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].p0rec), (yyvsp[(3) - (3)].i0delst)) ; } break; case 588: /* Line 1806 of yacc.c */ #line 2722 "ats_grammar.yats" { (yyval.d0ec) = d0ec_nonfix((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0delst)) ; } break; case 589: /* Line 1806 of yacc.c */ #line 2723 "ats_grammar.yats" { (yyval.d0ec) = d0ec_symintr((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0delst)) ; } break; case 590: /* Line 1806 of yacc.c */ #line 2724 "ats_grammar.yats" { (yyval.d0ec) = d0ec_e0xpundef((yyvsp[(2) - (2)].i0de)) ; } break; case 591: /* Line 1806 of yacc.c */ #line 2725 "ats_grammar.yats" { (yyval.d0ec) = d0ec_e0xpdef((yyvsp[(2) - (3)].i0de), (yyvsp[(3) - (3)].e0xpopt)) ; } break; case 592: /* Line 1806 of yacc.c */ #line 2726 "ats_grammar.yats" { (yyval.d0ec) = d0ec_e0xpact_assert((yyvsp[(2) - (2)].e0xp)) ; } break; case 593: /* Line 1806 of yacc.c */ #line 2727 "ats_grammar.yats" { (yyval.d0ec) = d0ec_e0xpact_error((yyvsp[(2) - (2)].e0xp)) ; } break; case 594: /* Line 1806 of yacc.c */ #line 2728 "ats_grammar.yats" { (yyval.d0ec) = d0ec_e0xpact_print((yyvsp[(2) - (2)].e0xp)) ; } break; case 595: /* Line 1806 of yacc.c */ #line 2729 "ats_grammar.yats" { (yyval.d0ec) = d0ec_srtdefs((yyvsp[(2) - (3)].s0rtdef), (yyvsp[(3) - (3)].s0rtdeflst)) ; } break; case 596: /* Line 1806 of yacc.c */ #line 2730 "ats_grammar.yats" { (yyval.d0ec) = d0ec_datsrts(0, (yyvsp[(2) - (3)].d0atsrtdec), (yyvsp[(3) - (3)].d0atsrtdeclst)) ; } break; case 597: /* Line 1806 of yacc.c */ #line 2731 "ats_grammar.yats" { (yyval.d0ec) = d0ec_datsrts(1, (yyvsp[(2) - (3)].d0atsrtdec), (yyvsp[(3) - (3)].d0atsrtdeclst)) ; } break; case 598: /* Line 1806 of yacc.c */ #line 2732 "ats_grammar.yats" { (yyval.d0ec) = d0ec_stacons((yyvsp[(1) - (3)].abskind), (yyvsp[(2) - (3)].s0tacon), (yyvsp[(3) - (3)].s0taconlst)) ; } break; case 599: /* Line 1806 of yacc.c */ #line 2733 "ats_grammar.yats" { (yyval.d0ec) = d0ec_stacsts((yyvsp[(2) - (3)].s0tacst), (yyvsp[(3) - (3)].s0tacstlst)) ; } break; case 600: /* Line 1806 of yacc.c */ #line 2734 "ats_grammar.yats" { (yyval.d0ec) = d0ec_stavars((yyvsp[(2) - (3)].s0tavar), (yyvsp[(3) - (3)].s0tavarlst)) ; } break; case 601: /* Line 1806 of yacc.c */ #line 2735 "ats_grammar.yats" { (yyval.d0ec) = d0ec_sexpdefs((yyvsp[(1) - (3)].stadefkind), (yyvsp[(2) - (3)].s0expdef), (yyvsp[(3) - (3)].s0expdeflst)) ; } break; case 602: /* Line 1806 of yacc.c */ #line 2736 "ats_grammar.yats" { (yyval.d0ec) = d0ec_saspdec((yyvsp[(2) - (2)].s0aspdec)) ; } break; case 603: /* Line 1806 of yacc.c */ #line 2737 "ats_grammar.yats" { (yyval.d0ec) = d0ec_datdecs((yyvsp[(1) - (4)].datakind), (yyvsp[(2) - (4)].d0atdec), (yyvsp[(3) - (4)].d0atdeclst), (yyvsp[(4) - (4)].s0expdeflst)) ; } break; case 604: /* Line 1806 of yacc.c */ #line 2738 "ats_grammar.yats" { (yyval.d0ec) = d0ec_exndecs((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].e0xndec), (yyvsp[(3) - (3)].e0xndeclst)) ; } break; case 605: /* Line 1806 of yacc.c */ #line 2739 "ats_grammar.yats" { (yyval.d0ec) = d0ec_classdec_none ((yyvsp[(1) - (2)].t0kn), (yyvsp[(2) - (2)].i0de)) ; } break; case 606: /* Line 1806 of yacc.c */ #line 2740 "ats_grammar.yats" { (yyval.d0ec) = d0ec_classdec_some ((yyvsp[(1) - (4)].t0kn), (yyvsp[(2) - (4)].i0de), (yyvsp[(4) - (4)].s0exp)) ; } break; case 607: /* Line 1806 of yacc.c */ #line 2741 "ats_grammar.yats" { (yyval.d0ec) = d0ec_overload((yyvsp[(1) - (4)].t0kn), (yyvsp[(2) - (4)].i0de), (yyvsp[(4) - (4)].dqi0de)) ; } break; case 608: /* Line 1806 of yacc.c */ #line 2742 "ats_grammar.yats" { (yyval.d0ec) = d0ec_overload_lrbrackets((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].t0kn), (yyvsp[(3) - (5)].t0kn), (yyvsp[(5) - (5)].dqi0de)) ; } break; case 609: /* Line 1806 of yacc.c */ #line 2743 "ats_grammar.yats" { (yyval.d0ec) = d0ec_macdefs(0, (yyvsp[(2) - (3)].m0acdef), (yyvsp[(3) - (3)].m0acdeflst)) ; } break; case 610: /* Line 1806 of yacc.c */ #line 2744 "ats_grammar.yats" { (yyval.d0ec) = d0ec_macdefs(-1/*error*/, (yyvsp[(3) - (4)].m0acdef), (yyvsp[(4) - (4)].m0acdeflst)) ; } break; case 611: /* Line 1806 of yacc.c */ #line 2745 "ats_grammar.yats" { (yyval.d0ec) = d0ec_macdefs(1, (yyvsp[(2) - (3)].m0acdef), (yyvsp[(3) - (3)].m0acdeflst)) ; } break; case 612: /* Line 1806 of yacc.c */ #line 2746 "ats_grammar.yats" { (yyval.d0ec) = d0ec_macdefs(2, (yyvsp[(3) - (4)].m0acdef), (yyvsp[(4) - (4)].m0acdeflst)) ; } break; case 613: /* Line 1806 of yacc.c */ #line 2747 "ats_grammar.yats" { (yyval.d0ec) = d0ec_staload_none((yyvsp[(2) - (2)].s0tring)) ; } break; case 614: /* Line 1806 of yacc.c */ #line 2748 "ats_grammar.yats" { (yyval.d0ec) = d0ec_staload_some((yyvsp[(2) - (4)].i0de), (yyvsp[(4) - (4)].s0tring)) ; } break; case 615: /* Line 1806 of yacc.c */ #line 2752 "ats_grammar.yats" { (yyval.s0qualst) = (yyvsp[(2) - (3)].s0qualst) ; } break; case 616: /* Line 1806 of yacc.c */ #line 2756 "ats_grammar.yats" { (yyval.s0qualstlst) = s0qualstlst_nil() ; } break; case 617: /* Line 1806 of yacc.c */ #line 2757 "ats_grammar.yats" { (yyval.s0qualstlst) = s0qualstlst_cons((yyvsp[(1) - (2)].s0qualst), (yyvsp[(2) - (2)].s0qualstlst)) ; } break; case 618: /* Line 1806 of yacc.c */ #line 2761 "ats_grammar.yats" { ; } break; case 619: /* Line 1806 of yacc.c */ #line 2762 "ats_grammar.yats" { ; } break; case 620: /* Line 1806 of yacc.c */ #line 2766 "ats_grammar.yats" { (yyval.d0ec) = (yyvsp[(1) - (1)].d0ec) ; } break; case 621: /* Line 1806 of yacc.c */ #line 2767 "ats_grammar.yats" { (yyval.d0ec) = d0ec_dcstdecs((yyvsp[(1) - (4)].dcstkind), (yyvsp[(2) - (4)].s0qualstlst), (yyvsp[(3) - (4)].d0cstdec), (yyvsp[(4) - (4)].d0cstdeclst)) ; } break; case 622: /* Line 1806 of yacc.c */ #line 2768 "ats_grammar.yats" { (yyval.d0ec) = d0ec_extcode_sta((yyvsp[(1) - (1)].e0xtcode)) ; } break; case 623: /* Line 1806 of yacc.c */ #line 2769 "ats_grammar.yats" { (yyval.d0ec) = d0ec_guadec((yyvsp[(1) - (2)].srpifkindtok), (yyvsp[(2) - (2)].d0eclst)) ; } break; case 624: /* Line 1806 of yacc.c */ #line 2770 "ats_grammar.yats" { (yyval.d0ec) = d0ec_include(0/*sta*/, (yyvsp[(2) - (2)].s0tring)) ; } break; case 625: /* Line 1806 of yacc.c */ #line 2771 "ats_grammar.yats" { (yyval.d0ec) = d0ec_local((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0eclst), (yyvsp[(4) - (5)].d0eclst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 626: /* Line 1806 of yacc.c */ #line 2775 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_one((yyvsp[(1) - (4)].e0xp), (yyvsp[(3) - (4)].d0eclst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 627: /* Line 1806 of yacc.c */ #line 2776 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_two((yyvsp[(1) - (6)].e0xp), (yyvsp[(3) - (6)].d0eclst), (yyvsp[(5) - (6)].d0eclst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 628: /* Line 1806 of yacc.c */ #line 2777 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_cons((yyvsp[(1) - (5)].e0xp), (yyvsp[(3) - (5)].d0eclst), (yyvsp[(4) - (5)].srpifkindtok), (yyvsp[(5) - (5)].d0eclst)) ; } break; case 629: /* Line 1806 of yacc.c */ #line 2781 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_reverse((yyvsp[(1) - (1)].d0eclst)) ; } break; case 630: /* Line 1806 of yacc.c */ #line 2785 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_nil() ; } break; case 631: /* Line 1806 of yacc.c */ #line 2786 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_cons((yyvsp[(1) - (3)].d0eclst), (yyvsp[(2) - (3)].d0ec)) ; } break; case 632: /* Line 1806 of yacc.c */ #line 2790 "ats_grammar.yats" { (yyval.d0ec) = (yyvsp[(1) - (1)].d0ec) ; } break; case 633: /* Line 1806 of yacc.c */ #line 2791 "ats_grammar.yats" { (yyval.d0ec) = d0ec_dcstdecs((yyvsp[(2) - (5)].dcstkind), (yyvsp[(3) - (5)].s0qualstlst), (yyvsp[(4) - (5)].d0cstdec), (yyvsp[(5) - (5)].d0cstdeclst)) ; } break; case 634: /* Line 1806 of yacc.c */ #line 2792 "ats_grammar.yats" { (yyval.d0ec) = d0ec_extype((yyvsp[(3) - (5)].s0tring), (yyvsp[(5) - (5)].s0exp)) ; } break; case 635: /* Line 1806 of yacc.c */ #line 2793 "ats_grammar.yats" { (yyval.d0ec) = d0ec_extval((yyvsp[(3) - (5)].s0tring), (yyvsp[(5) - (5)].d0exp)) ; } break; case 636: /* Line 1806 of yacc.c */ #line 2794 "ats_grammar.yats" { (yyval.d0ec) = d0ec_valdecs((yyvsp[(1) - (3)].valkind), (yyvsp[(2) - (3)].v0aldec), (yyvsp[(3) - (3)].v0aldeclst)) ; } break; case 637: /* Line 1806 of yacc.c */ #line 2795 "ats_grammar.yats" { (yyval.d0ec) = d0ec_valdecs_par((yyvsp[(3) - (4)].v0aldec), (yyvsp[(4) - (4)].v0aldeclst)) ; } break; case 638: /* Line 1806 of yacc.c */ #line 2796 "ats_grammar.yats" { (yyval.d0ec) = d0ec_valdecs_rec((yyvsp[(3) - (4)].v0aldec), (yyvsp[(4) - (4)].v0aldeclst)) ; } break; case 639: /* Line 1806 of yacc.c */ #line 2797 "ats_grammar.yats" { (yyval.d0ec) = d0ec_fundecs((yyvsp[(1) - (4)].funkind), (yyvsp[(2) - (4)].s0qualstlst), (yyvsp[(3) - (4)].f0undec), (yyvsp[(4) - (4)].f0undeclst)) ; } break; case 640: /* Line 1806 of yacc.c */ #line 2798 "ats_grammar.yats" { (yyval.d0ec) = d0ec_vardecs((yyvsp[(2) - (3)].v0ardec), (yyvsp[(3) - (3)].v0ardeclst)) ; } break; case 641: /* Line 1806 of yacc.c */ #line 2799 "ats_grammar.yats" { (yyval.d0ec) = d0ec_impdec((yyvsp[(1) - (3)].t0kn), (yyvsp[(2) - (3)].s0arglstlst), (yyvsp[(3) - (3)].i0mpdec)) ; } break; case 642: /* Line 1806 of yacc.c */ #line 2800 "ats_grammar.yats" { (yyval.d0ec) = d0ec_local((yyvsp[(1) - (5)].t0kn), (yyvsp[(2) - (5)].d0eclst), (yyvsp[(4) - (5)].d0eclst), (yyvsp[(5) - (5)].t0kn)) ; } break; case 643: /* Line 1806 of yacc.c */ #line 2801 "ats_grammar.yats" { (yyval.d0ec) = d0ec_extcode_dyn((yyvsp[(1) - (1)].e0xtcode)) ; } break; case 644: /* Line 1806 of yacc.c */ #line 2802 "ats_grammar.yats" { (yyval.d0ec) = d0ec_guadec((yyvsp[(1) - (2)].srpifkindtok), (yyvsp[(2) - (2)].d0eclst)) ; } break; case 645: /* Line 1806 of yacc.c */ #line 2803 "ats_grammar.yats" { (yyval.d0ec) = d0ec_include(1/*dyn*/, (yyvsp[(2) - (2)].s0tring)) ; } break; case 646: /* Line 1806 of yacc.c */ #line 2804 "ats_grammar.yats" { (yyval.d0ec) = d0ec_dynload((yyvsp[(2) - (2)].s0tring)) ; } break; case 647: /* Line 1806 of yacc.c */ #line 2808 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_one((yyvsp[(1) - (4)].e0xp), (yyvsp[(3) - (4)].d0eclst), (yyvsp[(4) - (4)].t0kn)) ; } break; case 648: /* Line 1806 of yacc.c */ #line 2809 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_two((yyvsp[(1) - (6)].e0xp), (yyvsp[(3) - (6)].d0eclst), (yyvsp[(5) - (6)].d0eclst), (yyvsp[(6) - (6)].t0kn)) ; } break; case 649: /* Line 1806 of yacc.c */ #line 2810 "ats_grammar.yats" { (yyval.d0eclst) = guad0ec_cons((yyvsp[(1) - (5)].e0xp), (yyvsp[(3) - (5)].d0eclst), (yyvsp[(4) - (5)].srpifkindtok), (yyvsp[(5) - (5)].d0eclst)) ; } break; case 650: /* Line 1806 of yacc.c */ #line 2814 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_reverse((yyvsp[(1) - (1)].d0eclst)) ; } break; case 651: /* Line 1806 of yacc.c */ #line 2818 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_nil() ; } break; case 652: /* Line 1806 of yacc.c */ #line 2819 "ats_grammar.yats" { (yyval.d0eclst) = d0ecllst_cons((yyvsp[(1) - (3)].d0eclst), (yyvsp[(2) - (3)].d0ec)) ; } break; /* Line 1806 of yacc.c */ #line 8782 "ats_grammar_yats.c" default: break; } /* User semantic actions sometimes alter yychar, and that requires that yytoken be updated with the new translation. We take the approach of translating immediately before every use of yytoken. One alternative is translating here after every semantic action, but that translation would be missed if the semantic action invokes YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an incorrect destructor might then be invoked immediately. In the case of YYERROR or YYBACKUP, subsequent parser actions might lead to an incorrect destructor call or verbose syntax error message before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); yylen = 0; YY_STACK_PRINT (yyss, yyssp); *++yyvsp = yyval; /* Now `shift' the result of the reduction. Determine what state that goes to, based on the state we popped back to and the rule number reduced by. */ yyn = yyr1[yyn]; yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) yystate = yytable[yystate]; else yystate = yydefgoto[yyn - YYNTOKENS]; goto yynewstate; /*------------------------------------. | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: /* Make sure we have latest lookahead translation. See comments at user semantic actions for why this is necessary. */ yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { ++yynerrs; #if ! YYERROR_VERBOSE yyerror (YY_("syntax error")); #else # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ yyssp, yytoken) { char const *yymsgp = YY_("syntax error"); int yysyntax_error_status; yysyntax_error_status = YYSYNTAX_ERROR; if (yysyntax_error_status == 0) yymsgp = yymsg; else if (yysyntax_error_status == 1) { if (yymsg != yymsgbuf) YYSTACK_FREE (yymsg); yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); if (!yymsg) { yymsg = yymsgbuf; yymsg_alloc = sizeof yymsgbuf; yysyntax_error_status = 2; } else { yysyntax_error_status = YYSYNTAX_ERROR; yymsgp = yymsg; } } yyerror (yymsgp); if (yysyntax_error_status == 2) goto yyexhaustedlab; } # undef YYSYNTAX_ERROR #endif } if (yyerrstatus == 3) { /* If just tried and failed to reuse lookahead token after an error, discard it. */ if (yychar <= YYEOF) { /* Return failure if at end of input. */ if (yychar == YYEOF) YYABORT; } else { yydestruct ("Error: discarding", yytoken, &yylval); yychar = YYEMPTY; } } /* Else will try to reuse lookahead token after shifting the error token. */ goto yyerrlab1; /*---------------------------------------------------. | yyerrorlab -- error raised explicitly by YYERROR. | `---------------------------------------------------*/ yyerrorlab: /* Pacify compilers like GCC when the user code never invokes YYERROR and the label yyerrorlab therefore never appears in user code. */ if (/*CONSTCOND*/ 0) goto yyerrorlab; /* Do not reclaim the symbols of the rule which action triggered this YYERROR. */ YYPOPSTACK (yylen); yylen = 0; YY_STACK_PRINT (yyss, yyssp); yystate = *yyssp; goto yyerrlab1; /*-------------------------------------------------------------. | yyerrlab1 -- common code for both syntax error and YYERROR. | `-------------------------------------------------------------*/ yyerrlab1: yyerrstatus = 3; /* Each real token shifted decrements this. */ for (;;) { yyn = yypact[yystate]; if (!yypact_value_is_default (yyn)) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) { yyn = yytable[yyn]; if (0 < yyn) break; } } /* Pop the current state because it cannot handle the error token. */ if (yyssp == yyss) YYABORT; yydestruct ("Error: popping", yystos[yystate], yyvsp); YYPOPSTACK (1); yystate = *yyssp; YY_STACK_PRINT (yyss, yyssp); } *++yyvsp = yylval; /* Shift the error token. */ YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); yystate = yyn; goto yynewstate; /*-------------------------------------. | yyacceptlab -- YYACCEPT comes here. | `-------------------------------------*/ yyacceptlab: yyresult = 0; goto yyreturn; /*-----------------------------------. | yyabortlab -- YYABORT comes here. | `-----------------------------------*/ yyabortlab: yyresult = 1; goto yyreturn; #if !defined(yyoverflow) || YYERROR_VERBOSE /*-------------------------------------------------. | yyexhaustedlab -- memory exhaustion comes here. | `-------------------------------------------------*/ yyexhaustedlab: yyerror (YY_("memory exhausted")); yyresult = 2; /* Fall through. */ #endif yyreturn: if (yychar != YYEMPTY) { /* Make sure we have latest lookahead translation. See comments at user semantic actions for why this is necessary. */ yytoken = YYTRANSLATE (yychar); yydestruct ("Cleanup: discarding lookahead", yytoken, &yylval); } /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); YY_STACK_PRINT (yyss, yyssp); while (yyssp != yyss) { yydestruct ("Cleanup: popping", yystos[*yyssp], yyvsp); YYPOPSTACK (1); } #ifndef yyoverflow if (yyss != yyssa) YYSTACK_FREE (yyss); #endif #if YYERROR_VERBOSE if (yymsg != yymsgbuf) YYSTACK_FREE (yymsg); #endif /* Make sure YYID is used. */ return YYID (yyresult); } /* Line 2067 of yacc.c */ #line 2825 "ats_grammar.yats" /* ****** ****** */ int yylex_tok0 = -1 ; int yylex() { // int tok ; // if (yylex_tok0 >= 0) { tok = yylex_tok0 ; yylex_tok0 = -1 ; } else { tok = atsopt_lexer_token_get () ; } // end of [if] /* ** fprintf (stdout, "tok = %i\n", tok) ; */ return tok ; // } /* end of [yylex_tok0] */ // // HX: needed in [ats_lexer.lats] // ats_void_type yylval_char_set(c0har_t val) { yylval.c0har = val ; return ; } ats_void_type yylval_extcode_set(e0xtcode_t val) { yylval.e0xtcode = val ; return ; } ats_void_type yylval_float_set(f0loat_t val) { yylval.f0loat = val ; return ; } ats_void_type yylval_floatsp_set(f0loatsp_t val) { yylval.f0loatsp = val ; return ; } ats_void_type yylval_ide_set(i0de_t val) { yylval.i0de = val ; return ; } ats_void_type yylval_int_set(i0nt_t val) { yylval.i0nt = val ; return ; } ats_void_type yylval_intsp_set(i0ntsp_t val) { yylval.i0ntsp = val ; return ; } ats_void_type yylval_string_set(s0tring_t val) { yylval.s0tring = val ; return ; } ats_void_type yylval_token_set(t0kn_t val) { yylval.t0kn = val ; return ; } // HX: see [stdlib.h] extern void exit (int) ; // // HX: implemented in [ats_filename.dats] extern ats_void_type atsopt_filename_prerr () ; // extern ats_ptr_type lexing_fstpos_get () ; extern ats_void_type lexing_prerr_position (ats_ptr_type) ; // void yyerror (char *s) { fprintf (stderr, "%s: ", s) ; atsopt_filename_prerr () ; fprintf (stderr, ": [") ; lexing_prerr_position (lexing_fstpos_get ()) ; fprintf (stderr, "]\n") ; exit (1) ; // HX: no error recovery yet; maybe in future return ; } /* end of [yyerror] */ yyres_t yyparse_main ( ats_int_type tok0 ) { /* ** HX: we must take care of garbage collection! */ // fprintf (stderr, "yyparse_main: &yyss = %p\n", &yyss) ; // ATS_GC_MARKROOT (&yyss, sizeof(short*)) ; // [ats_malloc_ngc] is used // fprintf (stderr, "yyparse_main: &yyvs = %p\n", &yyvs) ; // ATS_GC_MARKROOT (&yyvs, sizeof(YYSTYPE*)) ; // [ats_malloc_ngc] is used /* ** HX-2010-02-25: ** if BISON is used then [yyval] is a stack variable and ** thus there is no need to treat it as a GC root explicitly */ // #ifndef _ATS_YYVALISLOCAL extern YYSTYPE yyval; // fprintf (stderr, "yyparse_main: &yyval = %p\n", &yyval) ; ATS_GC_MARKROOT (&yyval, sizeof(YYSTYPE)) ; #endif // end of [_ATS_YYVALISLOCAL] // extern YYSTYPE yylval; // fprintf (stderr, "yyparse_main: &yylval = %p\n", &yylval) ; ATS_GC_MARKROOT (&yylval, sizeof(YYSTYPE)) ; // #ifdef YYPATCH #if (YYPATCH >= 20101229) // fprintf (stderr, "yyparse_main: &yystack = %p\n", &yystack) ; ATS_GC_MARKROOT (&yystack, sizeof(YYSTACKDATA)) ; #endif #endif // yylex_tok0 = tok0 ; // yyparse () ; // return theYYVALyyres ; } /* end of [yyparse_main] */ /* ****** ****** */ // end of [ats_grammar.yats] ats-lang-anairiats-0.2.11/bootstrap1/ats_error_dats.c0000664000175000017500000001116112223166160021250 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_error.dats: 1715(line=52, offs=7) -- 1873(line=60, offs=4) */ ATSglobaldec() ats_varet_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort: tmp1 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException) ; /* tmp0 = */ ats_raise_exn (tmp1) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort] */ /* // /home/hwxi/research/Anairiats/src/ats_error.dats: 2258(line=80, offs=10) -- 2404(line=86, offs=4) */ ATSglobaldec() ats_varet_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__deadcode (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_error_2esats__deadcode: /* tmp3 = */ atspre_prerr_string (ATSstrcst("error(deadcode)")) ; /* tmp4 = */ atspre_prerr_string (arg0) ; /* tmp5 = */ atspre_prerr_newline () ; tmp6 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException) ; /* tmp2 = */ ats_raise_exn (tmp6) ; return /* (tmp2) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_error_2esats__deadcode] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_error_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_error_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_error_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_int_type ats_error_segfault () { fprintf (stderr, "ats_error_segfault: this is for debugging.\n") ; return *(ats_int_type*)0 ; } /* end of [ats_error_segfault] */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_error_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_char_dats.c0000664000175000017500000000546312223166160022730 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_char_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_char_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_loop_dats.c0000664000175000017500000003527112223166160023242 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPlam_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop1_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPnone_3) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__lamloop_env_token = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type the_lamloop_env_push_3 (ats_ptr_type arg0) ; static ats_ptr_type aux_8 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp5) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ref_make_elt_03657_ats_ptr_type: /* ats_ptr_type tmp2 ; */ tmp2 = arg0 ; tmp1 = atspre_ref_make_elt_tsz ((&tmp2), sizeof(ats_ptr_type)) ; return (tmp1) ; } /* end of [ref_make_elt_03657_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 1973(line=60, offs=31) -- 1990(line=60, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_top () { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_top: tmp6 = ats_ptrget_mac(ats_ptr_type, statmp0) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_top] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 2043(line=64, offs=31) -- 2423(line=74, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () { /* local vardec */ // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop: tmp8 = ats_ptrget_mac(ats_ptr_type, statmp4) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp8 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_0, tmp8, atslab_0) ; tmp10 = ats_caselptrlab_mac(anairiats_sum_0, tmp8, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp9 ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp10 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp8 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: /* tmp11 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env_loop)")) ; /* tmp12 = */ atspre_prerr_string (ATSstrcst(": the_lamloop_env_pop")) ; /* tmp13 = */ atspre_prerr_newline () ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp7) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 2481(line=78, offs=4) -- 2663(line=83, offs=4) */ ATSstaticdec() ats_void_type the_lamloop_env_push_3 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_the_lamloop_env_push_3: tmp16 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp17 = ats_ptrget_mac(ats_ptr_type, statmp4) ; tmp15 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp15, atslab_0, tmp16) ; ats_selptrset_mac(anairiats_sum_0, tmp15, atslab_1, tmp17) ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp15 ; ats_ptrget_mac(ats_ptr_type, statmp0) = arg0 ; return /* (tmp14) */ ; } /* end of [the_lamloop_env_push_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 2733(line=85, offs=36) -- 2789(line=87, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam: tmp19 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp19)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp19, atslab_0, arg0) ; /* tmp18 = */ the_lamloop_env_push_3 (tmp19) ; return /* (tmp18) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 2865(line=89, offs=38) -- 2917(line=91, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop0 () { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop0: tmp21 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop0_1) ; /* tmp20 = */ the_lamloop_env_push_3 (tmp21) ; return /* (tmp20) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 2997(line=94, offs=3) -- 3109(line=96, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop1 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop1: tmp23 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp23)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp23, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp23, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp23, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp23, atslab_3, arg3) ; /* tmp22 = */ the_lamloop_env_push_3 (tmp23) ; return /* (tmp22) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 3221(line=103, offs=5) -- 3432(line=112, offs=2) */ ATSstaticdec() ats_ptr_type aux_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_aux_8: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_2_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; do { /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp26)->tag != 0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_1, tmp26, atslab_0) ; tmp25 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp25, atslab_0, tmp28) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: arg0 = tmp27 ; goto __ats_lab_aux_8 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp25 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp25) ; } /* end of [aux_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_loop.dats: 3205(line=101, offs=25) -- 3542(line=117, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get: tmp29 = ats_ptrget_mac(ats_ptr_type, statmp0) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp29)->tag != 0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_1, tmp29, atslab_0) ; tmp24 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp24, atslab_0, tmp30) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp31 = ats_ptrget_mac(ats_ptr_type, statmp4) ; tmp24 = aux_8 (tmp31) ; break ; } while (0) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPnone_3) ; statmp0 = ref_make_elt_03657_ats_ptr_type (statmp3) ; statmp5 = (ats_sum_ptr_type)0 ; statmp4 = ref_make_elt_03657_ats_ptr_type (statmp5) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_loop_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_list_sats.c0000664000175000017500000000175712223166160021123 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_list_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_dats.c0000664000175000017500000025416712223166160021524 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { int tag ; atsopt_count_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_s2rtdat_sym ; ats_ptr_type atslab_s2rtdat_conlst ; atsopt_count_type atslab_s2rtdat_stamp ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_5 ; typedef struct { anairiats_rec_5 atslab_0 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_s2arg_loc ; ats_ptr_type atslab_s2arg_sym ; ats_ptr_type atslab_s2arg_srt ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_sp2at_loc ; ats_ptr_type atslab_sp2at_exp ; ats_ptr_type atslab_sp2at_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_11 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_19 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_20 ; typedef struct { ats_ptr_type atslab_s2exparg_loc ; ats_ptr_type atslab_s2exparg_node ; } anairiats_rec_21 ; /* external typedefs */ typedef anairiats_rec_11 *s2exp_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt1_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__SP2Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASpre_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGseq_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2rtdat_stamp_make) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2rtdat_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_1) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_ptr_type loop_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp6) ; ATSstatic (ats_ptr_type, statmp7) ; ATSstatic (ats_ptr_type, statmp8) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp10) ; ATSstatic (ats_ptr_type, statmp11) ; ATSstatic (ats_ptr_type, statmp12) ; ATSstatic (ats_ptr_type, statmp13) ; ATSstatic (ats_ptr_type, statmp14) ; ATSstatic (ats_ptr_type, statmp15) ; ATSstatic (ats_ptr_type, statmp16) ; ATSstatic (ats_ptr_type, statmp17) ; ATSstatic (ats_ptr_type, statmp18) ; ATSstatic (ats_ptr_type, statmp19) ; ATSstatic (ats_ptr_type, statmp20) ; ATSstatic (ats_ptr_type, statmp21) ; ATSstatic (ats_ptr_type, statmp22) ; ATSstatic (ats_ptr_type, statmp23) ; ATSstatic (ats_ptr_type, statmp24) ; ATSstatic (ats_ptr_type, statmp25) ; ATSstatic (ats_ptr_type, statmp26) ; ATSstatic (ats_ptr_type, statmp27) ; ATSstatic (ats_ptr_type, statmp28) ; ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp30) ; ATSstatic (ats_ptr_type, statmp31) ; ATSstatic (ats_ptr_type, statmp140) ; ATSstatic (ats_ptr_type, statmp141) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 1988(line=65, offs=4) -- 2044(line=65, offs=60) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_staexp2)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 2100(line=69, offs=34) -- 2370(line=76, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp1) ; ATSlocal (atsopt_count_type, tmp2) ; ATSlocal (atsopt_count_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_4_1 ; } __ats_lab_0_2: tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_4_1 ; } __ats_lab_1_2: tmp1 = ats_true_bool ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_4_1 ; } __ats_lab_2_2: tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp1 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp2, tmp3) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_4_1 ; } __ats_lab_3_2: tmp4 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1 = atspre_eq_string_string (tmp4, tmp5) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: __ats_lab_4_2: tmp1 = ats_false_bool ; break ; } while (0) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 3892(line=124, offs=3) -- 4409(line=141, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_linearize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_int_type, tmp34) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; ATSlocal (ats_bool_type, tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_linearize: /* ats_ptr_type tmp33 ; */ tmp33 = arg0 ; /* ats_int_type tmp34 ; */ tmp34 = 0 ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp33)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_5_1: tmp36 = ats_caselptrlab_mac(anairiats_sum_1, tmp33, atslab_0) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp36)->tag != 1) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_2, tmp36, atslab_0) ; tmp38 = ats_caselptrlab_mac(anairiats_sum_2, tmp36, atslab_1) ; tmp40 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp40)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_0, tmp37) ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_1, tmp38) ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_2, 1) ; tmp39 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp39)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_0, tmp40) ; tmp33 = tmp39 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp34 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp34 = 1 ; break ; } while (0) ; tmp42 = atspre_gt_int_int (tmp34, 0) ; if (tmp42) { /* tmp43 = */ prerr_interror_0 () ; /* tmp44 = */ atspre_prerr_string (ATSstrcst(": s2rt_linearize: s2t = ")) ; /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp33) ; /* tmp46 = */ atspre_prerr_newline () ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp32 = tmp33 ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_linearize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 4730(line=157, offs=24) -- 5138(line=169, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (atsopt_count_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_make: tmp48 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2rtdat_stamp_make () ; tmp49 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_3)) ; tmp50 = ats_selsin_mac(tmp49, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp50), atslab_s2rtdat_sym) = arg0 ; tmp51 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp50), atslab_s2rtdat_conlst) = tmp51 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp50), atslab_s2rtdat_stamp) = tmp48 ; /* tmp52 = */ atspre_vbox_make_view_ptr (tmp50) ; /* tmp53 = ats_selsin_mac(tmp52, atslab_1) */ ; tmp47 = tmp50 ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 5191(line=171, offs=27) -- 5252(line=172, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_sym: tmp55 = ats_selsin_mac(arg0, atslab_1) ; tmp54 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp55), atslab_s2rtdat_sym) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 5311(line=175, offs=30) -- 5375(line=176, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_conlst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_conlst: tmp57 = ats_selsin_mac(arg0, atslab_1) ; tmp56 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp57), atslab_s2rtdat_conlst) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 5433(line=179, offs=30) -- 5511(line=180, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_set_conlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_set_conlst: tmp59 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp59), atslab_s2rtdat_conlst) = arg1 ; return /* (tmp58) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_set_conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 5568(line=183, offs=29) -- 5631(line=184, offs=55) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_stamp: tmp61 = ats_selsin_mac(arg0, atslab_1) ; tmp60 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp61), atslab_s2rtdat_stamp) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 5692(line=187, offs=30) -- 5925(line=196, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2rtdat_s2rtdat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (atsopt_count_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (atsopt_count_type, tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2rtdat_s2rtdat: tmp63 = ats_selsin_mac(arg0, atslab_1) ; tmp64 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp63), atslab_s2rtdat_stamp) ; tmp65 = ats_selsin_mac(arg1, atslab_1) ; tmp66 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, tmp65), atslab_s2rtdat_stamp) ; tmp62 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp64, tmp66) ; return (tmp62) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2rtdat_s2rtdat] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6023(line=203, offs=3) -- 6073(line=203, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun: tmp67 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp67)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp67, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp67, atslab_1, arg1) ; return (tmp67) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6115(line=206, offs=20) -- 6144(line=206, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_tup (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_tup: tmp68 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp68)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp68, atslab_0, arg0) ; return (tmp68) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6168(line=208, offs=23) -- 6254(line=209, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (anairiats_rec_5, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp71 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp72.atslab_0 = tmp70 ; tmp72.atslab_1 = tmp71 ; tmp69 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp69, atslab_0, tmp72) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: tmp69 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp69) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6302(line=212, offs=23) -- 6375(line=213, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_tup (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_tup: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp73 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp73, atslab_0, tmp74) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp73 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6443(line=218, offs=22) -- 6514(line=220, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2arg_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2arg_make: tmp75 = ATS_MALLOC(sizeof(anairiats_rec_8)) ; ats_selptrset_mac(anairiats_rec_8, tmp75, atslab_s2arg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_8, tmp75, atslab_s2arg_sym, arg1) ; ats_selptrset_mac(anairiats_rec_8, tmp75, atslab_s2arg_srt, arg2) ; return (tmp75) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2arg_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6580(line=224, offs=21) -- 6843(line=231, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sp2at_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sp2at_con: tmp77 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg2, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (arg1, tmp77) ; tmp79 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp79, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp79, atslab_1, arg2) ; tmp76 = ATS_MALLOC(sizeof(anairiats_rec_10)) ; ats_selptrset_mac(anairiats_rec_10, tmp76, atslab_sp2at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_10, tmp76, atslab_sp2at_exp, tmp78) ; ats_selptrset_mac(anairiats_rec_10, tmp76, atslab_sp2at_node, tmp79) ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sp2at_con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 6914(line=236, offs=3) -- 7002(line=238, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt: tmp81 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp81)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp81, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp81, atslab_1, arg2) ; tmp80 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp80, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp80, atslab_s2exp_node, tmp81) ; return (tmp80) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 7110(line=243, offs=5) -- 7609(line=257, offs=18) */ ATSstaticdec() ats_ptr_type loop_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (anairiats_rec_5, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; __ats_lab_loop_17: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_13_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_0) ; tmp85 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_1) ; tmp86 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (arg0) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp86 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_6, tmp86, atslab_0) ; ATS_FREE(tmp86) ; tmp88 = ats_select_mac(tmp87, atslab_1) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp88, arg1, tmp84) ; arg0 = tmp88 ; arg1 = tmp89 ; arg2 = tmp85 ; goto __ats_lab_loop_17 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp86 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: /* tmp90 = */ prerr_interror_0 () ; /* tmp91 = */ atspre_prerr_string (ATSstrcst(": s2exp_app_wind")) ; /* tmp92 = */ atspre_prerr_newline () ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp83 = arg1 ; break ; } while (0) ; return (tmp83) ; } /* end of [loop_17] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 7079(line=242, offs=26) -- 7663(line=260, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_wind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_wind: tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_s2exp_srt) ; tmp82 = loop_17 (tmp93, arg0, arg1) ; return (tmp82) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_wind] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 7734(line=264, offs=22) -- 7794(line=266, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char (ats_char_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char: tmp95 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp95)->tag = 1 ; ats_selptrset_mac(anairiats_sum_12, tmp95, atslab_0, arg0) ; tmp94 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp94, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; ats_selptrset_mac(anairiats_rec_11, tmp94, atslab_s2exp_node, tmp95) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 7843(line=268, offs=25) -- 7913(line=270, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt: tmp97 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp97)->tag = 2 ; ats_selptrset_mac(anairiats_sum_13, tmp97, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp97, atslab_1, arg2) ; tmp96 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp96, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp96, atslab_s2exp_node, tmp97) ; return (tmp96) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 7964(line=272, offs=24) -- 8133(line=277, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun: tmp100 = (ats_sum_ptr_type)0 ; tmp101 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp99)->tag = 11 ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_0, tmp100) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_2, tmp101) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_3, arg0) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_4, arg1) ; ats_selptrset_mac(anairiats_sum_14, tmp99, atslab_5, arg2) ; tmp98 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp98, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ats_selptrset_mac(anairiats_rec_11, tmp98, atslab_s2exp_node, tmp99) ; return (tmp98) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 8185(line=279, offs=23) -- 8252(line=281, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_s2exp_srt) ; tmp104 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp104)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp104, atslab_0, arg0) ; tmp102 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp102, atslab_s2exp_srt, tmp103) ; ats_selptrset_mac(anairiats_rec_11, tmp102, atslab_s2exp_node, tmp104) ; return (tmp102) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 8298(line=283, offs=21) -- 8365(line=285, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst: tmp106 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (arg0) ; tmp107 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp107)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp107, atslab_0, arg0) ; tmp105 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp105, atslab_s2exp_srt, tmp106) ; ats_selptrset_mac(anairiats_rec_11, tmp105, atslab_s2exp_node, tmp107) ; return (tmp105) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 8435(line=291, offs=3) -- 8961(line=308, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (anairiats_rec_5, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp: tmp109 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (arg0) ; tmp110 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (arg0) ; tmp111 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (tmp109) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (tmp111 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_6, tmp111, atslab_0) ; ATS_FREE(tmp111) ; tmp113 = ats_select_mac(tmp112, atslab_1) ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp113, tmp110, arg1) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (tmp111 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: /* tmp114 = */ prerr_interror_0 () ; /* tmp115 = */ atspre_prerr_string (ATSstrcst("s2exp_cstapp: the sort of the static constant [")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg0) ; /* tmp117 = */ atspre_prerr_string (ATSstrcst("] is not functional: ")) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp109) ; /* tmp119 = */ atspre_prerr_newline () ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 9035(line=313, offs=17) -- 9246(line=318, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_bool_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr: tmp121 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (arg0) ; tmp123 = atspre_gt_int_int (tmp121, 0) ; if (tmp123) { tmp122 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } else { tmp122 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } /* end of [if] */ tmp124 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp124)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp124, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp124, atslab_1, arg1) ; tmp120 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp120, atslab_s2exp_srt, tmp122) ; ats_selptrset_mac(anairiats_rec_11, tmp120, atslab_s2exp_node, tmp124) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 9343(line=324, offs=17) -- 9434(line=326, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp: tmp126 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp126)->tag = 6 ; ats_selptrset_mac(anairiats_sum_4, tmp126, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp126, atslab_1, arg1) ; tmp125 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp125, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ats_selptrset_mac(anairiats_rec_11, tmp125, atslab_s2exp_node, tmp126) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 9505(line=330, offs=21) -- 9572(line=332, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff: tmp128 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp128)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp128, atslab_0, arg0) ; tmp127 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp127, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff) ; ats_selptrset_mac(anairiats_rec_11, tmp127, atslab_s2exp_node, tmp128) ; return (tmp127) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 9617(line=335, offs=12) -- 9693(line=337, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq: tmp130 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp130)->tag = 8 ; ats_selptrset_mac(anairiats_sum_4, tmp130, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp130, atslab_1, arg1) ; tmp129 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp129, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ats_selptrset_mac(anairiats_rec_11, tmp129, atslab_s2exp_node, tmp130) ; return (tmp129) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 9740(line=341, offs=3) -- 9964(line=348, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_20_1 ; } __ats_lab_19_2: tmp131 = arg2 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: __ats_lab_20_2: tmp132 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg2), atslab_s2exp_srt) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp133)->tag = 9 ; ats_selptrset_mac(anairiats_sum_15, tmp133, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp133, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp133, atslab_2, arg2) ; tmp131 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp131, atslab_s2exp_srt, tmp132) ; ats_selptrset_mac(anairiats_rec_11, tmp131, atslab_s2exp_node, tmp133) ; break ; } while (0) ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10015(line=351, offs=18) -- 10096(line=353, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt: tmp135 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp135)->tag = 10 ; ats_selptrset_mac(anairiats_sum_4, tmp135, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp135, atslab_1, arg2) ; tmp134 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp134, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp134, atslab_s2exp_node, tmp135) ; return (tmp134) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10153(line=356, offs=3) -- 10267(line=358, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt: tmp137 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp137)->tag = 11 ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_4, arg5) ; ats_selptrset_mac(anairiats_sum_14, tmp137, atslab_5, arg6) ; tmp136 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp136, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp136, atslab_s2exp_node, tmp137) ; return (tmp136) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10315(line=360, offs=21) -- 10376(line=362, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int: tmp139 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp139)->tag = 12 ; ats_selptrset_mac(anairiats_sum_16, tmp139, atslab_0, arg0) ; tmp138 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp138, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ats_selptrset_mac(anairiats_rec_11, tmp138, atslab_s2exp_node, tmp139) ; return (tmp138) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10496(line=367, offs=24) -- 10563(line=369, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf: tmp143 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp143)->tag = 13 ; ats_selptrset_mac(anairiats_sum_1, tmp143, atslab_0, arg0) ; tmp142 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp142, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ats_selptrset_mac(anairiats_rec_11, tmp142, atslab_s2exp_node, tmp143) ; return (tmp142) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10616(line=372, offs=3) -- 10714(line=374, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt: tmp145 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp145)->tag = 14 ; ats_selptrset_mac(anairiats_sum_4, tmp145, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp145, atslab_1, arg2) ; tmp144 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp144, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp144, atslab_s2exp_node, tmp145) ; return (tmp144) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10766(line=377, offs=3) -- 10881(line=380, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn: tmp147 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg2), atslab_s2exp_srt) ; tmp148 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp148)->tag = 15 ; ats_selptrset_mac(anairiats_sum_15, tmp148, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp148, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp148, atslab_2, arg2) ; tmp146 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp146, atslab_s2exp_srt, tmp147) ; ats_selptrset_mac(anairiats_rec_11, tmp146, atslab_s2exp_node, tmp148) ; return (tmp146) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 10929(line=382, offs=23) -- 11010(line=384, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt: tmp150 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp150)->tag = 16 ; ats_selptrset_mac(anairiats_sum_4, tmp150, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp150, atslab_1, arg1) ; tmp149 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp149, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ats_selptrset_mac(anairiats_rec_11, tmp149, atslab_s2exp_node, tmp150) ; return (tmp149) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11220(line=393, offs=21) -- 11280(line=395, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out: tmp152 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp152)->tag = 17 ; ats_selptrset_mac(anairiats_sum_1, tmp152, atslab_0, arg0) ; tmp151 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp151, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ats_selptrset_mac(anairiats_rec_11, tmp151, atslab_s2exp_node, tmp152) ; return (tmp151) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11325(line=397, offs=22) -- 11397(line=399, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj: tmp154 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp154)->tag = 18 ; ats_selptrset_mac(anairiats_sum_4, tmp154, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp154, atslab_1, arg1) ; tmp153 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp153, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ats_selptrset_mac(anairiats_rec_11, tmp153, atslab_s2exp_node, tmp154) ; return (tmp153) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11443(line=401, offs=22) -- 11571(line=405, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read: tmp157 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_s2exp_srt) ; tmp156 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize (tmp157) ; tmp158 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp158)->tag = 19 ; ats_selptrset_mac(anairiats_sum_4, tmp158, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp158, atslab_1, arg1) ; tmp155 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp155, atslab_s2exp_srt, tmp156) ; ats_selptrset_mac(anairiats_rec_11, tmp155, atslab_s2exp_node, tmp158) ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11621(line=408, offs=16) -- 11696(line=410, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt: tmp160 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp160)->tag = 19 ; ats_selptrset_mac(anairiats_sum_4, tmp160, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp160, atslab_1, arg2) ; tmp159 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp159, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp159, atslab_s2exp_node, tmp160) ; return (tmp159) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11749(line=413, offs=15) -- 11868(line=417, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_read (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (anairiats_rec_5, tmp165) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_read: tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp162)->tag != 19) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_4, tmp162, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_4, tmp162, atslab_1) ; tmp165.atslab_0 = tmp163 ; tmp165.atslab_1 = tmp164 ; tmp161 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp161, atslab_0, tmp165) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp161 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp161) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_read] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 11940(line=422, offs=14) -- 12024(line=424, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg: tmp167 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_s2exp_srt) ; tmp168 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp168)->tag = 20 ; ats_selptrset_mac(anairiats_sum_13, tmp168, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_13, tmp168, atslab_1, arg1) ; tmp166 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp166, atslab_s2exp_srt, tmp167) ; ats_selptrset_mac(anairiats_rec_11, tmp166, atslab_s2exp_node, tmp168) ; return (tmp166) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12081(line=427, offs=21) -- 12159(line=428, offs=71) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg: tmp170 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp170)->tag != 20) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_13, tmp170, atslab_1) ; tmp169 = tmp171 ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp169 = arg0 ; break ; } while (0) ; return (tmp169) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12217(line=432, offs=15) -- 12283(line=434, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt: tmp173 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ((ats_sum_ptr_type)tmp173)->tag = 21 ; ats_selptrset_mac(anairiats_sum_17, tmp173, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_17, tmp173, atslab_1, arg2) ; tmp172 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp172, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp172, atslab_s2exp_node, tmp173) ; return (tmp172) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12332(line=437, offs=12) -- 12393(line=439, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size: tmp175 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp175)->tag = 22 ; ats_selptrset_mac(anairiats_sum_1, tmp175, atslab_0, arg0) ; tmp174 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp174, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ats_selptrset_mac(anairiats_rec_11, tmp174, atslab_s2exp_node, tmp175) ; return (tmp174) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12441(line=442, offs=14) -- 12502(line=444, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof: tmp177 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp177)->tag = 23 ; ats_selptrset_mac(anairiats_sum_1, tmp177, atslab_0, arg0) ; tmp176 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp176, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ats_selptrset_mac(anairiats_rec_11, tmp176, atslab_s2exp_node, tmp177) ; return (tmp176) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12553(line=447, offs=15) -- 12623(line=449, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt: tmp179 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp179)->tag = 24 ; ats_selptrset_mac(anairiats_sum_13, tmp179, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp179, atslab_1, arg2) ; tmp178 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp178, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp178, atslab_s2exp_node, tmp179) ; return (tmp178) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12675(line=452, offs=15) -- 12735(line=454, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tup_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tup_srt: tmp181 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp181)->tag = 25 ; ats_selptrset_mac(anairiats_sum_1, tmp181, atslab_0, arg1) ; tmp180 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp180, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp180, atslab_s2exp_node, tmp181) ; return (tmp180) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tup_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 12785(line=457, offs=13) -- 12968(line=462, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_bool_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr: tmp184 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (arg0) ; if (tmp184) { tmp183 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } else { tmp183 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ tmp185 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp185)->tag = 26 ; ats_selptrset_mac(anairiats_sum_4, tmp185, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp185, atslab_1, arg1) ; tmp182 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp182, atslab_s2exp_srt, tmp183) ; ats_selptrset_mac(anairiats_rec_11, tmp182, atslab_s2exp_node, tmp185) ; return (tmp182) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13016(line=465, offs=13) -- 13103(line=467, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq: tmp187 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp187)->tag = 27 ; ats_selptrset_mac(anairiats_sum_18, tmp187, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_18, tmp187, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp187, atslab_2, arg2) ; tmp186 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp186, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ats_selptrset_mac(anairiats_rec_11, tmp186, atslab_s2exp_node, tmp187) ; return (tmp186) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13210(line=471, offs=13) -- 13274(line=473, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst: tmp189 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp189)->tag = 28 ; ats_selptrset_mac(anairiats_sum_1, tmp189, atslab_0, arg0) ; tmp188 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp188, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types) ; ats_selptrset_mac(anairiats_rec_11, tmp188, atslab_s2exp_node, tmp189) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13328(line=477, offs=3) -- 13410(line=479, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt: tmp191 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ((ats_sum_ptr_type)tmp191)->tag = 29 ; ats_selptrset_mac(anairiats_sum_19, tmp191, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_19, tmp191, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_19, tmp191, atslab_2, arg3) ; tmp190 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp190, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp190, atslab_s2exp_node, tmp191) ; return (tmp190) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13462(line=483, offs=3) -- 13686(line=490, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_26_1 ; } __ats_lab_25_2: tmp192 = arg2 ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: __ats_lab_26_2: tmp193 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg2), atslab_s2exp_srt) ; tmp194 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp194)->tag = 30 ; ats_selptrset_mac(anairiats_sum_15, tmp194, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp194, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp194, atslab_2, arg2) ; tmp192 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp192, atslab_s2exp_srt, tmp193) ; ats_selptrset_mac(anairiats_rec_11, tmp192, atslab_s2exp_node, tmp194) ; break ; } while (0) ; return (tmp192) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13736(line=493, offs=17) -- 13826(line=495, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt: tmp196 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp196)->tag = 31 ; ats_selptrset_mac(anairiats_sum_20, tmp196, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp196, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_20, tmp196, atslab_2, arg3) ; tmp195 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp195, atslab_s2exp_srt, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp195, atslab_s2exp_node, tmp196) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13876(line=498, offs=11) -- 13943(line=500, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var: tmp198 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt (arg0) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp199)->tag = 33 ; ats_selptrset_mac(anairiats_sum_1, tmp199, atslab_0, arg0) ; tmp197 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp197, atslab_s2exp_srt, tmp198) ; ats_selptrset_mac(anairiats_rec_11, tmp197, atslab_s2exp_node, tmp199) ; return (tmp197) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 13987(line=503, offs=11) -- 14054(line=505, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var: tmp201 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (arg0) ; tmp202 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp202)->tag = 32 ; ats_selptrset_mac(anairiats_sum_1, tmp202, atslab_0, arg0) ; tmp200 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp200, atslab_s2exp_srt, tmp201) ; ats_selptrset_mac(anairiats_rec_11, tmp200, atslab_s2exp_node, tmp202) ; return (tmp200) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 14101(line=508, offs=14) -- 14172(line=510, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg: tmp204 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp204)->tag = 34 ; ats_selptrset_mac(anairiats_sum_1, tmp204, atslab_0, arg0) ; tmp203 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp203, atslab_s2exp_srt, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ats_selptrset_mac(anairiats_rec_11, tmp203, atslab_s2exp_node, tmp204) ; return (tmp203) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 14219(line=513, offs=11) -- 14302(line=515, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth: tmp206 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg0), atslab_s2exp_srt) ; tmp207 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp207)->tag = 35 ; ats_selptrset_mac(anairiats_sum_4, tmp207, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp207, atslab_1, arg1) ; tmp205 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp205, atslab_s2exp_srt, tmp206) ; ats_selptrset_mac(anairiats_rec_11, tmp205, atslab_s2exp_node, tmp207) ; return (tmp205) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 14370(line=520, offs=14) -- 14433(line=522, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_one (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_one: tmp209 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0) ; tmp208 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp208, atslab_s2exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp208, atslab_s2exparg_node, tmp209) ; return (tmp208) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_one] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 14483(line=525, offs=14) -- 14546(line=527, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_all (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_all: tmp211 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1) ; tmp210 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp210, atslab_s2exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp210, atslab_s2exparg_node, tmp211) ; return (tmp210) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_all] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2.dats: 14596(line=530, offs=14) -- 14669(line=532, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_seq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_seq: tmp213 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp213)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp213, atslab_0, arg1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp212, atslab_s2exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp212, atslab_s2exparg_node, tmp213) ; return (tmp212) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_seq] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp8, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp10, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp11, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp12, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp13, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp14, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp15, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp16, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp17, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp18, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp19, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp20, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp21, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp22, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp23, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp24, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp25, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp26, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp28, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp30, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp31, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp140, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp141, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp6 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp6)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp6, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR) ; statmp7 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp7)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp7, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL) ; statmp8 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp8)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp8, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR) ; statmp9 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp9)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp9, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; statmp10 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp10)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp10, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF) ; statmp11 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp11)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp11, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; statmp12 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp12)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp12, atslab_0, statmp6) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr = statmp12 ; statmp13 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp13)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp13, atslab_0, statmp7) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool = statmp13 ; statmp14 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp14)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp14, atslab_0, statmp8) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char = statmp14 ; statmp15 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp15)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp15, atslab_0, statmp9) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls = statmp15 ; statmp16 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp16)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp16, atslab_0, statmp10) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_eff = statmp16 ; statmp17 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp17)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp17, atslab_0, statmp11) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int = statmp17 ; statmp18 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp18)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp18, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ats_selptrset_mac(anairiats_sum_2, statmp18, atslab_1, 2) ; ats_selptrset_mac(anairiats_sum_2, statmp18, atslab_2, 0) ; statmp19 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp19)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp19, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ats_selptrset_mac(anairiats_sum_2, statmp19, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_2, statmp19, atslab_2, 0) ; statmp20 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp20)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp20, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ats_selptrset_mac(anairiats_sum_2, statmp20, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_2, statmp20, atslab_2, 0) ; statmp21 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp21)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp21, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ats_selptrset_mac(anairiats_sum_2, statmp21, atslab_1, 2) ; ats_selptrset_mac(anairiats_sum_2, statmp21, atslab_2, 1) ; statmp22 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp22)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp22, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ats_selptrset_mac(anairiats_sum_2, statmp22, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_2, statmp22, atslab_2, 1) ; statmp23 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp23)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp23, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ats_selptrset_mac(anairiats_sum_2, statmp23, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_2, statmp23, atslab_2, 1) ; statmp24 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp24)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, statmp24, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ats_selptrset_mac(anairiats_sum_2, statmp24, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_2, statmp24, atslab_2, 0) ; statmp25 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp25)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp25, atslab_0, statmp18) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop = statmp25 ; statmp26 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp26)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp26, atslab_0, statmp19) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type = statmp26 ; statmp27 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp27)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp27, atslab_0, statmp20) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype = statmp27 ; statmp28 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp28)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp28, atslab_0, statmp24) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_types = statmp28 ; statmp29 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp29)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp29, atslab_0, statmp21) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view = statmp29 ; statmp30 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp30)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp30, atslab_0, statmp22) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype = statmp30 ; statmp31 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp31)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp31, atslab_0, statmp23) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype = statmp31 ; statmp140 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0 = statmp140 ; statmp141 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_1, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_1 = statmp141 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ // ats_void_type atsopt_s2exp_set_srt (ats_ptr_type s2e, ats_ptr_type s2t) { ((s2exp_t)s2e)->atslab_s2exp_srt = s2t ; return ; } /* end of [atsopt_s2exp_set_srt] */ // ats_bool_type atsopt_eqref_s2exp_s2exp (ats_ptr_type s2e1, ats_ptr_type s2e2) { return (s2e1 == s2e2 ? ats_true_bool : ats_false_bool) ; } /* end of [atsopt_eqref_s2exp_s2exp] */ // /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symenv_sats.c0000664000175000017500000000220212223166160021453 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symenv_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_comarg_dats.c0000664000175000017500000002147312223166160021376 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__COMARGkey_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_bool_type, atspre_neq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int1_of_size1) (ats_size_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at__intsz) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarg_parse) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type loop_1 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type loop_3 (ats_int_type env0, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type loop_3_closure_make (ats_int_type env0) ; static ats_void_type loop_3_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_comarg.dats: 1675(line=46, offs=7) -- 1914(line=52, offs=8) */ ATSstaticdec() ats_ptr_type loop_1 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_bool_type, tmp3) ; ATSlocal (ats_char_type, tmp4) ; ATSlocal (ats_int_type, tmp5) ; __ats_lab_loop_1: tmp2 = atspre_ilt (arg2, arg1) ; if (tmp2) { tmp4 = atspre_string_get_char_at__intsz (arg0, arg2) ; tmp3 = atspre_neq_char_char (tmp4, '-') ; if (tmp3) { tmp1 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_1, arg0) ; } else { tmp5 = atspre_iadd (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp5 ; goto __ats_lab_loop_1 ; // tail call } /* end of [if] */ } else { tmp1 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_0, tmp1, atslab_1, arg0) ; } /* end of [if] */ return (tmp1) ; } /* end of [loop_1] */ /* // /home/hwxi/research/Anairiats/src/ats_comarg.dats: 1659(line=45, offs=24) -- 2053(line=58, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarg_parse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_size_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarg_parse: tmp6 = atspre_string_length (ats_castfn_mac(ats_ptr_type, arg0)) ; tmp7 = atspre_int1_of_size1 (tmp6) ; tmp0 = loop_1 (ats_castfn_mac(ats_ptr_type, arg0), tmp7, 0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarg_parse] */ /* // /home/hwxi/research/Anairiats/src/ats_comarg.dats: 2187(line=62, offs=7) -- 2655(line=73, offs=24) */ ATSstaticdec() ats_void_type loop_3 (ats_int_type env0, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_int_type, tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_loop_3: tmp10 = atspre_ilt (arg1, env0) ; if (tmp10) { tmp11 = ats_ptrget_mac(ats_ptr_type, arg2) ; // if (tmp11 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp13 = ats_caselptrind_mac(ats_ptr_type, arg0, [arg1]) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarg_parse (tmp13) ; tmp15 = (ats_sum_ptr_type)0 ; tmp14 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp14, atslab_0, tmp12) ; ats_selptrset_mac(anairiats_sum_1, tmp14, atslab_1, tmp15) ; // if (tmp14 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp16 = &ats_caselptrlab_mac(anairiats_sum_1, tmp14, atslab_1) ; tmp18 = atspre_iadd (arg1, 1) ; /* tmp17 = */ loop_3 (env0, arg0, tmp18, tmp16) ; /* tmp19 = ats_selsin_mac(tmp17, atslab_1) */ ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp14 ; } else { /* empty */ } /* end of [if] */ return /* (tmp9) */ ; } /* end of [loop_3] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } loop_3_closure_type ; ats_void_type loop_3_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { loop_3 (((loop_3_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type loop_3_closure_init (loop_3_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&loop_3_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type loop_3_closure_make (ats_int_type env0) { loop_3_closure_type *p_clo = ATS_MALLOC(sizeof(loop_3_closure_type)) ; loop_3_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_comarg.dats: 2110(line=60, offs=31) -- 2777(line=78, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarglst_parse (ats_int_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarglst_parse: /* ats_ptr_type tmp20 ; */ tmp20 = (ats_sum_ptr_type)0 ; /* tmp21 = */ loop_3 (arg0, arg1, 0, (&tmp20)) ; /* tmp22 = ats_selsin_mac(tmp21, atslab_1) */ ; tmp8 = tmp20 ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarglst_parse] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_comarg_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_pat_dats.c0000664000175000017500000052475012223166160022212 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_13 ; typedef struct { anairiats_rec_13 atslab_0 ; } anairiats_sum_14 ; typedef struct { anairiats_rec_13 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_20 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINsome_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINvbox_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__P2ATCONTRUPcon_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int1_of_size1) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerrf_exn) (ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label) (ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_vwtp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_read) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec) (ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_head) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_nfapp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_p2at_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_list_t0ype_int_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_viewt0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_types_viewt0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_vbox_view_prop) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_any) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool) (ats_ptr_type, ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char) (ats_ptr_type, ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_float) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_lst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_rec) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_vbox) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_p3at_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_p3at_set_typ_lft) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_eff) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_view) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__P2ATCONTRUPcon_0) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_void_type p3at_readize_2 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type p3atlst_readize_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type labp3atlst_readize_4 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labp2atlst_typ_syn_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pfarity_check_8 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_ptr_type labp3atlst_typ_get_9 (ats_ptr_type arg0) ; static ats_ptr_type p2at_any_tr_dn_10 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2at_bool_tr_dn_11 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type p2at_char_tr_dn_12 (ats_ptr_type arg0, ats_char_type arg1, ats_ptr_type arg2) ; static ats_void_type loop_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_ptr_type s2cst_closure_make_predicative_13 (ats_ptr_type arg0, ats_ptr_type arg1) ; static anairiats_rec_13 aux_var_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_pat_17 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_pat_17_closure_make (ats_ptr_type env0, ats_int_type env1) ; static ats_ptr_type aux_pat_17_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_patlst_18 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_patlst_18_closure_make (ats_ptr_type env0, ats_int_type env1) ; static ats_ptr_type aux_patlst_18_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type p3at_con_free_update_15 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_20 (ats_ptr_type arg0) ; static ats_void_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2at_con_tr_up_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) ; static ats_void_type aux_23 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_clo_ptr_type aux_23_closure_make () ; static ats_void_type aux_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type p2at_con_tr_dn_22 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) ; static ats_ptr_type aux_25 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_25_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2at_exist_tr_dn_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type p2atlst_elt_tr_dn_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2at_lst_tr_dn_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type labs2explst_revapp_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type auxcheck_31 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type labp2atlst_tr_dn_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_33 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2at_rec_tr_dn_32 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type p2at_var_tr_dn_34 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type p2at_vbox_tr_dn_35 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type refknd_check_40 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type loop_42 (ats_ptr_type arg0) ; static ats_void_type p2at_proofize_41 (ats_ptr_type arg0) ; static ats_ptr_type aux_44 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_46 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 2477(line=88, offs=4) -- 2536(line=88, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_pat)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 2541(line=90, offs=4) -- 2653(line=92, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; __ats_lab_prerr_loc_interror_1: /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_pat)")) ; return /* (tmp1) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 2711(line=96, offs=5) -- 3296(line=110, offs=4) */ ATSstaticdec() ats_void_type p3at_readize_2 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_p3at_readize_2: tmp4 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_p3at_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp4)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, tmp4, atslab_0) ; arg0 = arg0 ; arg1 = tmp5 ; goto __ats_lab_p3at_readize_2 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp4)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp6 = ats_caselptrlab_mac(anairiats_sum_2, tmp4, atslab_0) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize (arg0, tmp6) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp4)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_3, tmp4, atslab_1) ; tmp8 = ats_caselptrlab_mac(anairiats_sum_3, tmp4, atslab_2) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize (arg0, tmp7) ; arg0 = arg0 ; arg1 = tmp8 ; goto __ats_lab_p3at_readize_2 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp4)->tag != 5) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_4, tmp4, atslab_3) ; /* tmp3 = */ p3atlst_readize_3 (arg0, tmp10) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp4)->tag != 7) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_1, tmp4, atslab_1) ; arg0 = arg0 ; arg1 = tmp11 ; goto __ats_lab_p3at_readize_2 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp4)->tag != 10) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_1, tmp4, atslab_1) ; /* tmp3 = */ p3atlst_readize_3 (arg0, tmp12) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp4)->tag != 11) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_5, tmp4, atslab_2) ; /* tmp3 = */ labp3atlst_readize_4 (arg0, tmp13) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp4)->tag != 13) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_6, tmp4, atslab_1) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize (arg0, tmp14) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: break ; } while (0) ; return /* (tmp3) */ ; } /* end of [p3at_readize_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 3327(line=112, offs=5) -- 3558(line=118, offs=4) */ ATSstaticdec() ats_void_type p3atlst_readize_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; __ats_lab_p3atlst_readize_3: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp17 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; /* tmp18 = */ p3at_readize_2 (arg0, tmp16) ; arg0 = arg0 ; arg1 = tmp17 ; goto __ats_lab_p3atlst_readize_3 ; // tail call break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: break ; } while (0) ; return /* (tmp15) */ ; } /* end of [p3atlst_readize_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 3592(line=120, offs=5) -- 3842(line=127, offs=4) */ ATSstaticdec() ats_void_type labp3atlst_readize_4 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; __ats_lab_labp3atlst_readize_4: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; /* tmp22 = */ p3at_readize_2 (arg0, tmp20) ; arg0 = arg0 ; arg1 = tmp21 ; goto __ats_lab_labp3atlst_readize_4 ; // tail call break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: break ; } while (0) ; return /* (tmp19) */ ; } /* end of [labp3atlst_readize_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 3900(line=131, offs=5) -- 4396(line=143, offs=8) */ ATSstaticdec() ats_ptr_type labp2atlst_typ_syn_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; __ats_lab_labp2atlst_typ_syn_5: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp26 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; tmp27 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn (tmp25) ; tmp28 = labp2atlst_typ_syn_5 (arg0, tmp26) ; tmp23 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp23, atslab_0, tmp24) ; ats_selptrset_mac(anairiats_sum_9, tmp23, atslab_1, tmp27) ; ats_selptrset_mac(anairiats_sum_9, tmp23, atslab_2, tmp28) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp23 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp30 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp31 = */ atspre_prerr_string (ATSstrcst(": type synthesis cannot be done for a partial record pattern.")) ; /* tmp32 = */ atspre_prerr_newline () ; /* tmp23 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp23) ; } /* end of [labp2atlst_typ_syn_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 4481(line=147, offs=14) -- 6150(line=193, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn: tmp35 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp35)->tag != 0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp36 = ats_caselptrlab_mac(anairiats_sum_1, tmp35, atslab_1) ; tmp34 = tmp36 ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp35)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp37, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp35)->tag != 2) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_3, tmp35, atslab_2) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn (tmp38) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp35)->tag != 3) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype () ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp35)->tag != 4) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype () ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp35)->tag != 5) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp39, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp35)->tag != 6) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp35)->tag != 7) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp41 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp41) ; /* tmp42 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp43 = */ atspre_prerr_string (ATSstrcst(": type synthesis is not supported for an existentially quantified pattern.")) ; /* tmp44 = */ atspre_prerr_newline () ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp35)->tag != 8) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp35)->tag != 9) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype () ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp35)->tag != 10) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp45 = */ prerr_loc_interror_1 (tmp46) ; /* tmp47 = */ atspre_prerr_string (ATSstrcst(": p2at_typ_syn: P2Tlist")) ; /* tmp48 = */ atspre_prerr_newline () ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp35)->tag != 11) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp49, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp35)->tag != 12) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_5, tmp35, atslab_0) ; tmp51 = ats_caselptrlab_mac(anairiats_sum_5, tmp35, atslab_1) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_5, tmp35, atslab_2) ; tmp54 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp53 = labp2atlst_typ_syn_5 (tmp54, tmp52) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec (tmp50, tmp51, tmp53) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp35)->tag != 13) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp35)->tag != 14) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp55 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp55, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (((ats_sum_ptr_type)tmp35)->tag != 15) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp56 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp57, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop (tmp56) ; break ; } while (0) ; tmp59 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp59, atslab_0, tmp34) ; /* tmp58 = */ atsopt_p2at_set_typ (arg0, tmp59) ; tmp33 = tmp34 ; return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 6203(line=196, offs=17) -- 6378(line=200, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp61 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_typ_syn (tmp61) ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn (tmp62) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp60, atslab_0, tmp63) ; ats_selptrset_mac(anairiats_sum_7, tmp60, atslab_1, tmp64) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp60 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 6432(line=205, offs=4) -- 6844(line=215, offs=6) */ ATSstaticdec() ats_void_type pfarity_check_8 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp65) ; ATSlocal (ats_bool_type, tmp66) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; ATSlocal (ats_bool_type, tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_bool_type, tmp74) ; // ATSlocal_void (tmp75) ; __ats_lab_pfarity_check_8: tmp66 = atspre_neq_int_int (arg1, arg2) ; if (tmp66) { /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp68 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp69 = */ atsopt_debug_prerrf (ATSstrcst(": %s"), ATSstrcst("ats_trans3_pat.dats")) ; /* tmp70 = */ atspre_prerr_string (ATSstrcst(": pfarity_check: pfarity mismatch")) ; tmp72 = atspre_lt_int_int (arg1, arg2) ; if (tmp72) { /* tmp71 = */ atspre_prerr_string (ATSstrcst(": more proof components are needed.")) ; } else { /* empty */ } /* end of [if] */ tmp74 = atspre_gt_int_int (arg1, arg2) ; if (tmp74) { /* tmp73 = */ atspre_prerr_string (ATSstrcst(": fewer proof components are needed.")) ; } else { /* empty */ } /* end of [if] */ /* tmp75 = */ atspre_prerr_newline () ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp65) */ ; } /* end of [pfarity_check_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 6912(line=220, offs=5) -- 7346(line=232, offs=4) */ ATSstaticdec() ats_ptr_type labp3atlst_typ_get_9 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; __ats_lab_labp3atlst_typ_get_9: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp78 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_2) ; tmp80 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp78), atslab_p3at_typ) ; tmp81 = labp3atlst_typ_get_9 (tmp79) ; tmp76 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp76, atslab_0, tmp77) ; ats_selptrset_mac(anairiats_sum_9, tmp76, atslab_1, tmp80) ; ats_selptrset_mac(anairiats_sum_9, tmp76, atslab_2, tmp81) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp76 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: /* tmp82 = */ prerr_interror_0 () ; /* tmp83 = */ atspre_prerr_string (ATSstrcst(": labp2atlst_typ_get: LABP3ATLSTdot")) ; /* tmp84 = */ atspre_prerr_newline () ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp76) ; } /* end of [labp3atlst_typ_get_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 7403(line=236, offs=4) -- 7822(line=251, offs=4) */ ATSstaticdec() ats_ptr_type p2at_any_tr_dn_10 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; ATSlocal (ats_bool_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_p2at_any_tr_dn_10: tmp86 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (arg0) ; /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp86) ; tmp88 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_any (arg0, arg1, tmp86) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg1) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp89) ; if (tmp91) { tmp92 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp92, atslab_0, tmp89) ; /* tmp90 = */ atsopt_p3at_set_typ_lft (tmp88, tmp92) ; } else { /* empty */ } /* end of [if] */ tmp85 = tmp88 ; return (tmp85) ; } /* end of [p2at_any_tr_dn_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 7875(line=255, offs=4) -- 8736(line=280, offs=4) */ ATSstaticdec() ats_ptr_type p2at_bool_tr_dn_11 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_bool_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; // ATSlocal_void (tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; // ATSlocal_void (tmp108) ; __ats_lab_p2at_bool_tr_dn_11: tmp94 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg2) ; tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp94), atslab_s2exp_node) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp95)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_37_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_1, tmp95, atslab_0) ; tmp97 = ats_caselptrlab_mac(anairiats_sum_1, tmp95, atslab_1) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype, tmp96) ; if (!tmp98) { goto __ats_lab_40_1 ; } do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp97 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_7, tmp97, atslab_0) ; tmp99 = tmp100 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (tmp97 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: /* tmp101 = */ prerr_loc_interror_1 (arg0) ; /* tmp102 = */ atspre_prerr_string (ATSstrcst(": p2at_bool_tr_dn")) ; /* tmp103 = */ atspre_prerr_newline () ; /* tmp99 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (arg1) ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp105, tmp99) ; tmp106 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype (arg1) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool (arg0, tmp106, arg1) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp107 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype () ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp94, tmp107) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_bool (arg0, tmp107, arg1) ; break ; } while (0) ; return (tmp93) ; } /* end of [p2at_bool_tr_dn_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 8790(line=284, offs=4) -- 9644(line=308, offs=4) */ ATSstaticdec() ats_ptr_type p2at_char_tr_dn_12 (ats_ptr_type arg0, ats_char_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_bool_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; // ATSlocal_void (tmp124) ; __ats_lab_p2at_char_tr_dn_12: tmp110 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg2) ; tmp111 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp110), atslab_s2exp_node) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp111)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_41_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_1, tmp111, atslab_0) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_1, tmp111, atslab_1) ; tmp114 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype, tmp112) ; if (!tmp114) { goto __ats_lab_44_1 ; } do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp113 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_7, tmp113, atslab_0) ; tmp115 = tmp116 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (tmp113 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: /* tmp117 = */ prerr_loc_interror_1 (arg0) ; /* tmp118 = */ atspre_prerr_string (ATSstrcst(": p2at_char_tr_dn")) ; /* tmp119 = */ atspre_prerr_newline () ; /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp121 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char (arg1) ; /* tmp120 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp121, tmp115) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype (arg1) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char (arg0, tmp122, arg1) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp123 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype () ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp110, tmp123) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_char (arg0, tmp123, arg1) ; break ; } while (0) ; return (tmp109) ; } /* end of [p2at_char_tr_dn_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 10098(line=320, offs=13) -- 10846(line=338, offs=14) */ ATSstaticdec() ats_void_type loop_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_bool_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_loop_14: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp133 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun (tmp132) ; if (tmp135) { tmp136 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (arg0, tmp132) ; tmp137 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp137, atslab_0, tmp136) ; ats_selptrset_mac(anairiats_sum_7, tmp137, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp137 ; } else { tmp138 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (tmp132) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp138) ; tmp140 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp140, atslab_0, tmp138) ; ats_selptrset_mac(anairiats_sum_7, tmp140, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp140 ; tmp141 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp141, atslab_0, tmp139) ; ats_selptrset_mac(anairiats_sum_7, tmp141, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp141 ; } /* end of [if] */ arg0 = arg0 ; arg1 = tmp133 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_loop_14 ; // tail call break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: break ; } while (0) ; return /* (tmp131) */ ; } /* end of [loop_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 9765(line=314, offs=4) -- 11146(line=347, offs=4) */ ATSstaticdec() ats_ptr_type s2cst_closure_make_predicative_13 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (anairiats_rec_13, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_s2cst_closure_make_predicative_13: tmp126 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (arg1) ; tmp127 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (tmp126) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp127 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_45_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_14, tmp127, atslab_0) ; ATS_FREE(tmp127) ; /* ats_ptr_type tmp129 ; */ tmp129 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp130 ; */ tmp130 = (ats_sum_ptr_type)0 ; tmp143 = ats_select_mac(tmp128, atslab_0) ; /* tmp142 = */ loop_14 (arg0, tmp143, (&tmp129), (&tmp130)) ; tmp144 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp129) ; tmp129 = tmp144 ; tmp145 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp130) ; tmp130 = tmp145 ; tmp146 = (ats_sum_ptr_type)0 ; tmp147 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (arg1, tmp130) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (tmp129, tmp146, tmp147) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp127 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp125 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (arg1) ; break ; } while (0) ; return (tmp125) ; } /* end of [s2cst_closure_make_predicative_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 11630(line=361, offs=7) -- 12533(line=384, offs=6) */ ATSstaticdec() anairiats_rec_13 aux_var_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_13, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_aux_var_16: tmp150 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp151 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp150, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp151) ; tmp153 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp151) ; tmp154 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp153) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp155, atslab_0, tmp154) ; /* tmp156 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (arg0, -1) ; tmp158 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp158, atslab_0, tmp153) ; /* tmp157 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (arg0, tmp158) ; /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (arg0, tmp155) ; /* tmp160 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg0, tmp155) ; tmp161 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none (arg0) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp161) ; tmp163 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (arg1, tmp153) ; tmp164 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp164, atslab_0, tmp163) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp161, tmp164) ; /* tmp166 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp161, tmp164) ; tmp168 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp161, tmp168) ; tmp149.atslab_0 = tmp161 ; tmp149.atslab_1 = tmp153 ; return (tmp149) ; } /* end of [aux_var_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 12559(line=385, offs=6) -- 14251(line=434, offs=6) */ ATSstaticdec() ats_ptr_type aux_pat_17 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; // ATSlocal_void (tmp177) ; ATSlocal (ats_int_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_bool_type, tmp180) ; ATSlocal (ats_int_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_bool_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; // ATSlocal_void (tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (anairiats_rec_13, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; // ATSlocal_void (tmp196) ; ATSlocal (ats_bool_type, tmp197) ; // ATSlocal_void (tmp198) ; ATSlocal (ats_bool_type, tmp199) ; // ATSlocal_void (tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; __ats_lab_aux_pat_17: tmp171 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_node) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp171)->tag != 1) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_2, tmp171, atslab_0) ; tmp174 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp174 != (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp176 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_typ) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (tmp176) ; tmp173 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp173, atslab_0, tmp175) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp173 = tmp174 ; break ; } while (0) ; /* tmp177 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp172, tmp173) ; tmp170 = tmp172 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp171)->tag != 13) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp178 = ats_caselptrlab_mac(anairiats_sum_6, tmp171, atslab_0) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_6, tmp171, atslab_1) ; tmp180 = atspre_gt_int_int (tmp178, 0) ; if (!tmp180) { goto __ats_lab_54_1 ; } tmp170 = tmp179 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp171)->tag != 2) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_3, tmp171, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_3, tmp171, atslab_1) ; tmp183 = atspre_gt_int_int (tmp181, 0) ; if (!tmp183) { goto __ats_lab_54_1 ; } tmp170 = tmp182 ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp185 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_loc) ; tmp184 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (tmp185) ; tmp187 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (tmp187 != (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_typ) ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (tmp189) ; tmp186 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp186, atslab_0, tmp188) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp186 = tmp187 ; break ; } while (0) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp184, tmp186) ; tmp170 = tmp184 ; break ; } while (0) ; tmp192 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_p3at_loc) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (tmp192, tmp170) ; tmp193 = aux_var_16 (tmp170, tmp191) ; tmp194 = ats_select_mac(tmp193, atslab_0) ; tmp195 = ats_select_mac(tmp193, atslab_1) ; tmp197 = atspre_lt_int_int (env1, 0) ; if (tmp197) { tmp199 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp191) ; if (tmp199) { tmp201 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, env0), atslab_p3at_loc) ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp201) ; /* tmp202 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp203 = */ atspre_prerr_string (ATSstrcst(": a value matching this pattern may not be freed")) ; /* tmp204 = */ atspre_prerr_string (ATSstrcst(", as it contains a linear component of the type [")) ; /* tmp205 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp191) ; /* tmp206 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp207 = */ atspre_prerr_newline () ; /* tmp198 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp208 = (ats_sum_ptr_type)0 ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp194, tmp208) ; } else { /* empty */ } /* end of [if] */ tmp169 = tmp195 ; return (tmp169) ; } /* end of [aux_pat_17] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; } aux_pat_17_closure_type ; ats_ptr_type aux_pat_17_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_pat_17 (((aux_pat_17_closure_type*)cloptr)->closure_env_0, ((aux_pat_17_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_pat_17_closure_init (aux_pat_17_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_pat_17_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_pat_17_closure_make (ats_ptr_type env0, ats_int_type env1) { aux_pat_17_closure_type *p_clo = ATS_MALLOC(sizeof(aux_pat_17_closure_type)) ; aux_pat_17_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 14324(line=436, offs=9) -- 14500(line=439, offs=35) */ ATSstaticdec() ats_ptr_type aux_patlst_18 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; __ats_lab_aux_patlst_18: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp210 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp211 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp212 = aux_pat_17 (env0, env1, tmp210) ; tmp213 = aux_patlst_18 (env0, env1, tmp211) ; tmp209 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp209, atslab_0, tmp212) ; ats_selptrset_mac(anairiats_sum_7, tmp209, atslab_1, tmp213) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: tmp209 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp209) ; } /* end of [aux_patlst_18] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; } aux_patlst_18_closure_type ; ats_ptr_type aux_patlst_18_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_patlst_18 (((aux_patlst_18_closure_type*)cloptr)->closure_env_0, ((aux_patlst_18_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_patlst_18_closure_init (aux_patlst_18_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_patlst_18_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_patlst_18_closure_make (ats_ptr_type env0, ats_int_type env1) { aux_patlst_18_closure_type *p_clo = ATS_MALLOC(sizeof(aux_patlst_18_closure_type)) ; aux_patlst_18_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 11265(line=352, offs=4) -- 14647(line=445, offs=4) */ ATSstaticdec() ats_void_type p3at_con_free_update_15 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp148) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_bool_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; __ats_lab_p3at_con_free_update_15: tmp214 = aux_patlst_18 (arg0, arg1, arg3) ; tmp215 = atspre_gt_int_int (arg1, 0) ; if (tmp215) { tmp217 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr (arg2, tmp214) ; tmp216 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp216, atslab_0, tmp217) ; /* tmp148 = */ atsopt_p3at_set_typ_lft (arg0, tmp216) ; } else { /* empty */ } /* end of [if] */ return /* (tmp148) */ ; } /* end of [p3at_con_free_update_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 14989(line=459, offs=7) -- 15377(line=472, offs=24) */ ATSstaticdec() ats_void_type aux_20 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp219) ; ATSlocal (anairiats_rec_13, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; __ats_lab_aux_20: do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_15, arg0, atslab_0) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_15, arg0, atslab_1) ; tmp222 = ats_select_mac(tmp220, atslab_0) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp222) ; arg0 = tmp221 ; goto __ats_lab_aux_20 ; // tail call break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: break ; } while (0) ; return /* (tmp219) */ ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 15458(line=477, offs=7) -- 15693(line=482, offs=24) */ ATSstaticdec() ats_void_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp225) ; ATSlocal (anairiats_rec_13, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; __ats_lab_aux_21: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_15, arg1, atslab_0) ; tmp227 = ats_caselptrlab_mac(anairiats_sum_15, arg1, atslab_1) ; tmp229 = ats_select_mac(tmp226, atslab_1) ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp229) ; arg0 = arg0 ; arg1 = tmp227 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: break ; } while (0) ; return /* (tmp225) */ ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 14823(line=453, offs=4) -- 16778(line=515, offs=4) */ ATSstaticdec() ats_ptr_type p2at_con_tr_up_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp218) ; // ATSlocal_void (tmp224) ; // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_int_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; // ATSlocal_void (tmp235) ; ATSlocal (ats_int_type, tmp236) ; ATSlocal (ats_int_type, tmp237) ; // ATSlocal_void (tmp238) ; ATSlocal (ats_bool_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_bool_type, tmp246) ; // ATSlocal_void (tmp247) ; ATSlocal (ats_bool_type, tmp248) ; // ATSlocal_void (tmp249) ; ATSlocal (ats_bool_type, tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; __ats_lab_p2at_con_tr_up_19: /* tmp224 = */ aux_20 (arg2) ; /* tmp230 = */ aux_21 (arg0, arg2) ; tmp231 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg3), atslab_s2exp_node) ; do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp231)->tag != 11) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp232 = ats_caselptrlab_mac(anairiats_sum_16, tmp231, atslab_3) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_16, tmp231, atslab_4) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_16, tmp231, atslab_5) ; /* tmp235 = */ pfarity_check_8 (arg0, arg4, tmp232) ; tmp236 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg5) ; tmp237 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp233) ; tmp239 = atspre_ineq (tmp236, tmp237) ; if (tmp239) { /* tmp240 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp241 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp242 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp244 = */ atspre_prerr_string (ATSstrcst("] needs")) ; tmp246 = atspre_ilt (tmp236, tmp237) ; if (tmp246) { /* tmp245 = */ atspre_prerr_string (ATSstrcst(" more arguments.")) ; } else { /* empty */ } /* end of [if] */ tmp248 = atspre_igt (tmp236, tmp237) ; if (tmp248) { /* tmp247 = */ atspre_prerr_string (ATSstrcst(" fewer arguments.")) ; } else { /* empty */ } /* end of [if] */ /* tmp249 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp250 = atspre_ieq (tmp236, tmp237) ; /* tmp238 = */ atspre_assert (tmp250) ; } else { /* empty */ } /* end of [if] */ tmp218 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp218, atslab_0, arg5) ; ats_selptrset_mac(anairiats_sum_9, tmp218, atslab_1, tmp233) ; ats_selptrset_mac(anairiats_sum_9, tmp218, atslab_2, tmp234) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: /* tmp251 = */ prerr_loc_interror_1 (arg0) ; /* tmp252 = */ atspre_prerr_string (ATSstrcst(": p2at_con_tr_up")) ; /* tmp253 = */ atspre_prerr_newline () ; /* tmp218 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp218) ; } /* end of [p2at_con_tr_up_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 20456(line=620, offs=17) -- 20975(line=630, offs=16) */ ATSstaticdec() ats_void_type aux_23 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_int_type, tmp330) ; ATSlocal (ats_bool_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_int_type, tmp333) ; ATSlocal (ats_bool_type, tmp334) ; ATSlocal (ats_int_type, tmp335) ; __ats_lab_aux_23: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_80_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp327 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp329 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp326), atslab_p3at_node) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp329)->tag != 13) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_6, tmp329, atslab_0) ; tmp331 = atspre_gt_int_int (tmp330, 0) ; if (tmp331) { tmp332 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp332 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp329)->tag != 2) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp333 = ats_caselptrlab_mac(anairiats_sum_3, tmp329, atslab_0) ; tmp334 = atspre_gt_int_int (tmp333, 0) ; if (tmp334) { tmp335 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp335 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: break ; } while (0) ; arg0 = tmp327 ; arg1 = arg1 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: break ; } while (0) ; return /* (tmp325) */ ; } /* end of [aux_23] */ typedef struct { ats_fun_ptr_type closure_fun ; } aux_23_closure_type ; ats_void_type aux_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) { aux_23 (arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_23_closure_init (aux_23_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_23_clofun ; return ; } /* end of function */ ats_clo_ptr_type aux_23_closure_make () { aux_23_closure_type *p_clo = ATS_MALLOC(sizeof(aux_23_closure_type)) ; aux_23_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 16810(line=517, offs=4) -- 22745(line=676, offs=4) */ ATSstaticdec() ats_ptr_type p2at_con_tr_dn_22 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_bool_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (anairiats_rec_13, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; // ATSlocal_void (tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_bool_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_bool_type, tmp290) ; // ATSlocal_void (tmp291) ; ATSlocal (ats_bool_type, tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_int_type, tmp300) ; ATSlocal (ats_bool_type, tmp301) ; // ATSlocal_void (tmp302) ; ATSlocal (ats_bool_type, tmp303) ; ATSlocal (ats_bool_type, tmp304) ; ATSlocal (ats_bool_type, tmp305) ; // ATSlocal_void (tmp306) ; // ATSlocal_void (tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_bool_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; // ATSlocal_void (tmp323) ; ATSlocal (ats_bool_type, tmp324) ; ATSlocal (ats_int_type, tmp336) ; // ATSlocal_void (tmp337) ; ATSlocal (ats_bool_type, tmp338) ; // ATSlocal_void (tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_int_type, tmp347) ; // ATSlocal_void (tmp348) ; ATSlocal (ats_bool_type, tmp349) ; // ATSlocal_void (tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; ATSlocal (ats_bool_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; // ATSlocal_void (tmp357) ; // ATSlocal_void (tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; __ats_lab_p2at_con_tr_dn_22: tmp255 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg7) ; tmp256 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (arg2) ; tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp255), atslab_s2exp_node) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp258)->tag != 33) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp259 = s2cst_closure_make_predicative_13 (arg0, tmp256) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (arg0, tmp255, tmp259) ; tmp257 = tmp259 ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp257 = tmp255 ; break ; } while (0) ; /* ats_ptr_type tmp261 ; */ tmp261 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp257) ; tmp262 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_read (tmp261) ; /* ats_bool_type tmp263 ; */ tmp263 = ats_false_bool ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (tmp262 == (ats_sum_ptr_type)0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_14, tmp262, atslab_0) ; ATS_FREE(tmp262) ; tmp263 = ats_true_bool ; tmp266 = ats_select_mac(tmp265, atslab_1) ; tmp261 = tmp266 ; tmp267 = ats_select_mac(tmp265, atslab_0) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp264, atslab_0, tmp267) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (tmp262 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: tmp264 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp264 == (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } __ats_lab_69_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_0) ; tmp270 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_view (tmp269) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (tmp270 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: ATS_FREE(tmp270) ; tmp268 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (tmp270 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp268 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp268, atslab_0, tmp269) ; break ; } while (0) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (tmp264 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: tmp268 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (tmp268 == (ats_sum_ptr_type)0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_11, tmp268, atslab_0) ; ATS_FREE(tmp268) ; /* tmp273 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp274 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp275 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p2at_con_tr_dn"), ATSstrcst("ats_trans3_pat.dats")) ; /* tmp276 = */ atspre_prerr_string (ATSstrcst(": a proof of the view [")) ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp272) ; /* tmp278 = */ atspre_prerr_string (ATSstrcst("] is not avaible for reading.")) ; /* tmp279 = */ atspre_prerr_newline () ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (tmp268 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: break ; } while (0) ; tmp280 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_head (tmp261) ; /* ats_int_type tmp281 ; */ tmp281 = -1 ; /* ats_int_type tmp282 ; */ tmp282 = arg1 ; /* ats_ptr_type tmp283 ; */ tmp283 = (ats_sum_ptr_type)0 ; tmp285 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp280), atslab_s2exp_node) ; do { /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp285)->tag != 4) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp286 = ats_caselptrlab_mac(anairiats_sum_2, tmp285, atslab_0) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp256, tmp286) ; if (tmp287) { tmp281 = 0 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp285)->tag != 6) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_1, tmp285, atslab_0) ; tmp289 = ats_caselptrlab_mac(anairiats_sum_1, tmp285, atslab_1) ; tmp290 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (arg2, tmp288) ; if (tmp290) { tmp281 = 1 ; tmp283 = tmp289 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: __ats_lab_77_1: break ; } while (0) ; tmp292 = atspre_lt_int_int (tmp281, 0) ; if (tmp292) { /* tmp293 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp294 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp295 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p2at_con_tr_dn"), ATSstrcst("ats_trans3_pat.dats")) ; /* tmp296 = */ atspre_prerr_string (ATSstrcst(": the constructor pattern is assigned the type [")) ; /* tmp297 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp261) ; /* tmp298 = */ atspre_prerr_string (ATSstrcst("] but it should not be.")) ; /* tmp299 = */ atspre_prerr_newline () ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ if (tmp263) { tmp300 = 0 ; } else { tmp301 = atspre_gt_int_int (tmp281, 0) ; if (tmp301) { tmp300 = 1 ; } else { tmp300 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_vwtp (arg2) ; } /* end of [if] */ } /* end of [if] */ tmp303 = atspre_gt_int_int (tmp282, 0) ; if (tmp303) { tmp304 = atspre_gt_int_int (tmp300, 0) ; if (tmp304) { /* empty */ } else { tmp282 = 0 ; } /* end of [if] */ } else { tmp305 = atspre_gt_int_int (tmp300, 0) ; if (tmp305) { /* empty */ } else { /* tmp306 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp307 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp308 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p2at_con_tr_dn"), ATSstrcst("ats_trans3_pat.dats")) ; /* tmp309 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp310 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg2) ; /* tmp311 = */ atspre_prerr_string (ATSstrcst("] is not allowed to be freed.")) ; /* tmp312 = */ atspre_prerr_newline () ; /* tmp302 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ } /* end of [if] */ do { /* branch: __ats_lab_78 */ __ats_lab_78_0: __ats_lab_78_1: tmp314 = atspre_eq_int_int (tmp281, 0) ; if (!tmp314) { goto __ats_lab_86_1 ; } tmp315 = p2at_con_tr_up_19 (arg0, arg2, arg3, arg4, arg5, arg6) ; // tmp316 = ats_caselptrlab_mac(anairiats_sum_9, tmp315, atslab_0) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_9, tmp315, atslab_1) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_9, tmp315, atslab_2) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp318, tmp261) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_nfapp (tmp317) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn (tmp316, tmp320) ; tmp322 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con (arg0, tmp261, tmp282, arg2, arg5, tmp321) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp324 = atspre_eq_int_int (tmp282, 0) ; if (!tmp324) { goto __ats_lab_85_1 ; } /* ats_int_type tmp336 ; */ tmp336 = 0 ; /* tmp337 = */ aux_23 (tmp321, (&tmp336)) ; tmp338 = atspre_gt_int_int (tmp336, 0) ; if (tmp338) { /* tmp339 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp340 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp341 = */ atsopt_debug_prerrf (ATSstrcst(": %s: p2at_con_tr_dn"), ATSstrcst("ats_trans3_pat.dats")) ; /* tmp342 = */ atspre_prerr_string (ATSstrcst(": the constructor [")) ; /* tmp343 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg2) ; /* tmp344 = */ atspre_prerr_string (ATSstrcst("] is not allowed to have a reference argument.")) ; /* tmp345 = */ atspre_prerr_newline () ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: /* tmp323 = */ p3at_con_free_update_15 (tmp322, tmp282, arg2, tmp321) ; break ; } while (0) ; tmp313 = tmp322 ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp346 = tmp283 ; tmp347 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (arg6, tmp346) ; tmp349 = atspre_ineq (tmp347, 0) ; if (tmp349) { /* tmp350 = */ prerr_loc_interror_1 (arg0) ; /* tmp351 = */ atspre_prerrf_exn (ATSstrcst(": p2at_con_tr_dn: sgn = %i"), tmp347) ; /* tmp352 = */ atspre_prerr_newline () ; /* tmp353 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp354 = atspre_ieq (tmp347, 0) ; /* tmp348 = */ atspre_assert (tmp354) ; } else { /* empty */ } /* end of [if] */ tmp355 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn (arg6, tmp346) ; tmp356 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_con (arg0, tmp261, tmp282, arg2, arg5, tmp355) ; /* tmp357 = */ p3at_con_free_update_15 (tmp356, tmp282, arg2, tmp355) ; tmp313 = tmp356 ; break ; } while (0) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp264 == (ats_sum_ptr_type)0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp359 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_0) ; ATS_FREE(tmp264) ; /* tmp358 = */ p3at_readize_2 (tmp359, tmp313) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: // if (tmp264 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_88_1: break ; } while (0) ; tmp254 = tmp313 ; return (tmp254) ; } /* end of [p2at_con_tr_dn_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 23059(line=688, offs=13) -- 24534(line=720, offs=16) */ ATSstaticdec() ats_ptr_type aux_25 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_bool_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; // ATSlocal_void (tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; // ATSlocal_void (tmp393) ; // ATSlocal_void (tmp394) ; __ats_lab_aux_25: do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_92_1 ; } __ats_lab_90_2: tmp368 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp369 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp370 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp368) ; tmp373 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp370) ; tmp374 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp373, tmp372) ; if (tmp374) { tmp375 = aux_25 (env0, tmp369, tmp371) ; tmp376 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp370) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (tmp375, tmp368, tmp376) ; } else { /* tmp377 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp378 = */ atspre_prerr_string (ATSstrcst("error(3)")) ; /* tmp379 = */ atspre_prerr_string (ATSstrcst(": the bound variable [")) ; /* tmp380 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (tmp368) ; /* tmp381 = */ atspre_prerr_string (ATSstrcst("] is given the sort [")) ; /* tmp382 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp372) ; /* tmp383 = */ atspre_prerr_string (ATSstrcst("] but it is expected to be of the sort [")) ; /* tmp384 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp373) ; /* tmp385 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp386 = */ atspre_prerr_newline () ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_93_1 ; } __ats_lab_91_2: tmp367 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_92_2: /* tmp387 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp388 = */ atspre_prerr_string (ATSstrcst("error(3)")) ; /* tmp389 = */ atspre_prerr_string (ATSstrcst(": the existentially quantified pattern needs fewer bound variables.")) ; /* tmp390 = */ atspre_prerr_newline () ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_93_2: /* tmp391 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp392 = */ atspre_prerr_string (ATSstrcst("error(3)")) ; /* tmp393 = */ atspre_prerr_string (ATSstrcst(": the existentially quantified pattern needs more bound variables.")) ; /* tmp394 = */ atspre_prerr_newline () ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp367) ; } /* end of [aux_25] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_25_closure_type ; ats_ptr_type aux_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_25 (((aux_25_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_25_closure_init (aux_25_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_25_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_25_closure_make (ats_ptr_type env0) { aux_25_closure_type *p_clo = ATS_MALLOC(sizeof(aux_25_closure_type)) ; aux_25_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 22798(line=680, offs=4) -- 25116(line=735, offs=4) */ ATSstaticdec() ats_ptr_type p2at_exist_tr_dn_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; // ATSlocal_void (tmp405) ; // ATSlocal_void (tmp406) ; __ats_lab_p2at_exist_tr_dn_24: tmp361 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp362 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg3) ; tmp363 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp362), atslab_s2exp_node) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp363)->tag != 9) { goto __ats_lab_94_0 ; } __ats_lab_89_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_8, tmp363, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_8, tmp363, atslab_1) ; tmp366 = ats_caselptrlab_mac(anairiats_sum_8, tmp363, atslab_2) ; tmp395 = aux_25 (tmp361, tmp364, arg1) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (arg1) ; tmp398 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp395, tmp365) ; /* tmp397 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (tmp361, tmp398) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp395, tmp366) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (arg2, tmp400) ; tmp360 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_exist (tmp361, tmp362, arg1, tmp399) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: __ats_lab_94_1: /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp361) ; /* tmp402 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp403 = */ atspre_prerr_string (ATSstrcst(": the pattern is given the type [")) ; /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp362) ; /* tmp405 = */ atspre_prerr_string (ATSstrcst("] but an existentially quantified type is expected.")) ; /* tmp406 = */ atspre_prerr_newline () ; /* tmp360 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp360) ; } /* end of [p2at_exist_tr_dn_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 25172(line=739, offs=5) -- 25413(line=745, offs=31) */ ATSstaticdec() ats_ptr_type p2atlst_elt_tr_dn_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; __ats_lab_p2atlst_elt_tr_dn_26: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp409 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp410 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp408, arg1) ; tmp411 = p2atlst_elt_tr_dn_26 (tmp409, arg1) ; tmp407 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp407, atslab_0, tmp410) ; ats_selptrset_mac(anairiats_sum_7, tmp407, atslab_1, tmp411) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: tmp407 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp407) ; } /* end of [p2atlst_elt_tr_dn_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 25448(line=748, offs=4) -- 26202(line=769, offs=4) */ ATSstaticdec() ats_ptr_type p2at_lst_tr_dn_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (anairiats_rec_13, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; // ATSlocal_void (tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; // ATSlocal_void (tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; __ats_lab_p2at_lst_tr_dn_27: tmp413 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg2) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_list_t0ype_int_type (tmp413) ; do { /* branch: __ats_lab_97 */ __ats_lab_97_0: if (tmp414 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_14, tmp414, atslab_0) ; ATS_FREE(tmp414) ; tmp416 = ats_select_mac(tmp415, atslab_0) ; tmp417 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp419 = ats_select_mac(tmp415, atslab_1) ; tmp420 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp417) ; /* tmp418 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp419, tmp420) ; tmp421 = p2atlst_elt_tr_dn_26 (arg1, tmp416) ; tmp412 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_lst (arg0, tmp416, arg2, tmp421) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (tmp414 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp423 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp424 = */ atspre_prerr_string (ATSstrcst(": the pattern is given the type [")) ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp413) ; /* tmp426 = */ atspre_prerr_string (ATSstrcst("] but a type of the form [list (_, _)] is expected.")) ; /* tmp427 = */ atspre_prerr_newline () ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp412) ; } /* end of [p2at_lst_tr_dn_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 26256(line=773, offs=5) -- 26520(line=780, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_revapp_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; __ats_lab_labs2explst_revapp_28: do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp429 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp430 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp432 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp432, atslab_0, tmp429) ; ats_selptrset_mac(anairiats_sum_9, tmp432, atslab_1, tmp430) ; ats_selptrset_mac(anairiats_sum_9, tmp432, atslab_2, arg1) ; arg0 = tmp431 ; arg1 = tmp432 ; goto __ats_lab_labs2explst_revapp_28 ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: tmp428 = arg1 ; break ; } while (0) ; return (tmp428) ; } /* end of [labs2explst_revapp_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 28222(line=825, offs=13) -- 28994(line=843, offs=12) */ ATSstaticdec() ats_void_type auxcheck_31 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; // ATSlocal_void (tmp464) ; ATSlocal (ats_bool_type, tmp465) ; // ATSlocal_void (tmp466) ; // ATSlocal_void (tmp467) ; // ATSlocal_void (tmp468) ; // ATSlocal_void (tmp469) ; // ATSlocal_void (tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; __ats_lab_auxcheck_31: do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; tmp463 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_2) ; tmp465 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp462) ; if (tmp465) { /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp467 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp468 = */ atspre_prerr_string (ATSstrcst(": the component with the label [")) ; /* tmp469 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp461) ; /* tmp470 = */ atspre_prerr_string (ATSstrcst("] is omitted but it is linear")) ; /* tmp471 = */ atspre_prerr_string (ATSstrcst(": only a nonlinear component can be omitted.")) ; /* tmp472 = */ atspre_prerr_newline () ; /* tmp464 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ arg0 = arg0 ; arg1 = tmp463 ; goto __ats_lab_auxcheck_31 ; // tail call break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: break ; } while (0) ; return /* (tmp460) */ ; } /* end of [auxcheck_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 26654(line=784, offs=7) -- 29186(line=849, offs=6) */ ATSstaticdec() ats_ptr_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_bool_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; // ATSlocal_void (tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; // ATSlocal_void (tmp456) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; // ATSlocal_void (tmp459) ; ATSlocal (ats_ptr_type, tmp473) ; // ATSlocal_void (tmp474) ; __ats_lab_aux_30: do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_104_0 ; } __ats_lab_101_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp437 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_0) ; tmp439 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_1) ; tmp440 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_2) ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp435, tmp438) ; if (tmp441) { tmp442 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp436, tmp439) ; tmp443 = aux_30 (arg0, tmp437, tmp440, arg3) ; tmp434 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp434)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp434, atslab_0, tmp435) ; ats_selptrset_mac(anairiats_sum_8, tmp434, atslab_1, tmp442) ; ats_selptrset_mac(anairiats_sum_8, tmp434, atslab_2, tmp443) ; } else { tmp444 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp444, atslab_0, tmp438) ; ats_selptrset_mac(anairiats_sum_9, tmp444, atslab_1, tmp439) ; ats_selptrset_mac(anairiats_sum_9, tmp444, atslab_2, arg3) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp440 ; arg3 = tmp444 ; goto __ats_lab_aux_30 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: /* tmp445 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp446 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp447 = */ atspre_prerr_string (ATSstrcst(": the pattern contains a component with the label [")) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp435) ; /* tmp449 = */ atspre_prerr_string (ATSstrcst("] but it should not according to its assigned type.")) ; /* tmp450 = */ atspre_prerr_newline () ; /* tmp434 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp451 = labs2explst_revapp_28 (arg3, arg2) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (tmp451 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp453 = ats_caselptrlab_mac(anairiats_sum_9, tmp451, atslab_0) ; /* tmp454 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp455 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp456 = */ atspre_prerr_string (ATSstrcst(": the pattern does not contain a component with the label [")) ; /* tmp457 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp453) ; /* tmp458 = */ atspre_prerr_string (ATSstrcst("] but it should according to its assigned type.")) ; /* tmp459 = */ atspre_prerr_newline () ; /* tmp452 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: break ; } while (0) ; tmp434 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTnil_0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: tmp473 = labs2explst_revapp_28 (arg3, arg2) ; /* tmp474 = */ auxcheck_31 (arg0, tmp473) ; tmp434 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTdot_1) ; break ; } while (0) ; return (tmp434) ; } /* end of [aux_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 26556(line=782, offs=4) -- 29257(line=852, offs=4) */ ATSstaticdec() ats_ptr_type labp2atlst_tr_dn_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp475) ; __ats_lab_labp2atlst_tr_dn_29: tmp475 = (ats_sum_ptr_type)0 ; tmp433 = aux_30 (arg0, arg1, arg2, tmp475) ; return (tmp433) ; } /* end of [labp2atlst_tr_dn_29] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 29690(line=865, offs=15) -- 30339(line=878, offs=18) */ ATSstaticdec() ats_ptr_type aux_33 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; // ATSlocal_void (tmp490) ; // ATSlocal_void (tmp491) ; // ATSlocal_void (tmp492) ; // ATSlocal_void (tmp493) ; __ats_lab_aux_33: do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_114_0 ; } __ats_lab_113_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp486 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; tmp488 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp485), atslab_p2at_loc) ; tmp487 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp488, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp489 = aux_33 (arg0, tmp486) ; tmp483 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp483, atslab_0, tmp484) ; ats_selptrset_mac(anairiats_sum_9, tmp483, atslab_1, tmp487) ; ats_selptrset_mac(anairiats_sum_9, tmp483, atslab_2, tmp489) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp483 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: /* tmp490 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp491 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp492 = */ atspre_prerr_string (ATSstrcst(": type synthesis for a partial record pattern is not supported.")) ; /* tmp493 = */ atspre_prerr_newline () ; /* tmp483 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp483) ; } /* end of [aux_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 29291(line=854, offs=4) -- 32287(line=927, offs=4) */ ATSstaticdec() ats_ptr_type p2at_rec_tr_dn_32 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; // ATSlocal_void (tmp498) ; ATSlocal (ats_bool_type, tmp499) ; // ATSlocal_void (tmp500) ; // ATSlocal_void (tmp501) ; // ATSlocal_void (tmp502) ; // ATSlocal_void (tmp503) ; // ATSlocal_void (tmp504) ; // ATSlocal_void (tmp505) ; // ATSlocal_void (tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_int_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; // ATSlocal_void (tmp512) ; // ATSlocal_void (tmp513) ; // ATSlocal_void (tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; // ATSlocal_void (tmp523) ; // ATSlocal_void (tmp524) ; // ATSlocal_void (tmp525) ; // ATSlocal_void (tmp526) ; __ats_lab_p2at_rec_tr_dn_32: tmp477 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp478 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg4) ; tmp480 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp478), atslab_s2exp_node) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp480)->tag != 33) { goto __ats_lab_116_0 ; } __ats_lab_110_1: tmp481 = ats_caselptrlab_mac(anairiats_sum_2, tmp480, atslab_0) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (arg1 != 0) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp482 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp482 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; break ; } while (0) ; tmp494 = aux_33 (tmp477, arg3) ; tmp495 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec (arg1, arg2, tmp494) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt (tmp481) ; tmp497 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp495), atslab_s2exp_srt) ; tmp499 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp497, tmp496) ; if (tmp499) { /* empty */ } else { /* tmp500 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp477) ; /* tmp501 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp502 = */ atspre_prerr_string (ATSstrcst(": the pattern cannot be assigned a type of the sort [")) ; /* tmp503 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp496) ; /* tmp504 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp505 = */ atspre_prerr_newline () ; /* tmp498 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ /* tmp506 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (tmp477, tmp478, tmp495) ; tmp479 = tmp495 ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: __ats_lab_116_1: tmp479 = tmp478 ; break ; } while (0) ; tmp507 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp477, tmp479) ; tmp508 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp507), atslab_s2exp_node) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)tmp508)->tag != 29) { goto __ats_lab_122_0 ; } __ats_lab_117_1: tmp509 = ats_caselptrlab_mac(anairiats_sum_17, tmp508, atslab_0) ; tmp510 = ats_caselptrlab_mac(anairiats_sum_17, tmp508, atslab_1) ; tmp511 = ats_caselptrlab_mac(anairiats_sum_17, tmp508, atslab_2) ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (arg1 != 0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: if (((ats_sum_ptr_type)tmp509)->tag != 0) { goto __ats_lab_119_1 ; } __ats_lab_118_2: /* tmp513 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp477) ; /* tmp514 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp515 = */ atspre_prerr_string (ATSstrcst(": the flat record pattern cannot be assigned a boxed type.")) ; /* tmp516 = */ atspre_prerr_newline () ; /* tmp512 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg1 != 0) { goto __ats_lab_120_0 ; } __ats_lab_119_1: __ats_lab_119_2: break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: __ats_lab_120_1: if (((ats_sum_ptr_type)tmp509)->tag != 0) { goto __ats_lab_121_1 ; } __ats_lab_120_2: break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: __ats_lab_121_2: /* tmp517 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp477) ; /* tmp518 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp519 = */ atspre_prerr_string (ATSstrcst(": the boxed record pattern cannot be assigned a flat type.")) ; /* tmp520 = */ atspre_prerr_newline () ; /* tmp512 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp521 = */ pfarity_check_8 (tmp477, arg2, tmp510) ; tmp522 = labp2atlst_tr_dn_29 (tmp477, arg3, tmp511) ; tmp476 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_rec (tmp477, tmp507, arg1, arg2, tmp522) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: __ats_lab_122_1: /* tmp523 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp477) ; /* tmp524 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp525 = */ atspre_prerr_string (ATSstrcst(": the record pattern is given a type that is not for records.")) ; /* tmp526 = */ atspre_prerr_newline () ; /* tmp476 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp476) ; } /* end of [p2at_rec_tr_dn_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 32340(line=931, offs=4) -- 33447(line=969, offs=4) */ ATSstaticdec() ats_ptr_type p2at_var_tr_dn_34 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_bool_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; // ATSlocal_void (tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; // ATSlocal_void (tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; __ats_lab_p2at_var_tr_dn_34: tmp528 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp529 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (arg3) ; tmp530 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg3) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp532, atslab_0, tmp530) ; /* tmp531 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (arg2, tmp532) ; if (tmp529) { /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (arg2, 0) ; tmp535 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (arg2, tmp535) ; } else { /* empty */ } /* end of [if] */ tmp536 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp528, tmp530) ; tmp538 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp538, atslab_0, tmp536) ; /* tmp537 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg2, tmp538) ; tmp527 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var (tmp528, tmp530, arg1, arg2) ; return (tmp527) ; } /* end of [p2at_var_tr_dn_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 33500(line=973, offs=4) -- 34683(line=1007, offs=4) */ ATSstaticdec() ats_ptr_type p2at_vbox_tr_dn_35 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; // ATSlocal_void (tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; // ATSlocal_void (tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; // ATSlocal_void (tmp550) ; ATSlocal (ats_bool_type, tmp551) ; // ATSlocal_void (tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; // ATSlocal_void (tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; // ATSlocal_void (tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; // ATSlocal_void (tmp561) ; // ATSlocal_void (tmp562) ; __ats_lab_p2at_vbox_tr_dn_35: tmp540 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp542 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp540), atslab_s2exp_node) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp542)->tag != 33) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp543 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; tmp544 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop (tmp543) ; /* tmp545 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (arg0, tmp540, tmp544) ; tmp541 = tmp544 ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: tmp541 = tmp540 ; break ; } while (0) ; tmp546 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_vbox_view_prop (tmp541) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (tmp546 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp547 = ats_caselptrlab_mac(anairiats_sum_11, tmp546, atslab_0) ; ATS_FREE(tmp546) ; tmp549 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp549, atslab_0, tmp547) ; /* tmp548 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (arg1, tmp549) ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp547) ; if (tmp551) { /* tmp552 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (arg1, 0) ; tmp553 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp553)->tag = 3 ; ats_selptrset_mac(anairiats_sum_2, tmp553, atslab_0, tmp547) ; /* tmp550 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (arg1, tmp553) ; } else { /* empty */ } /* end of [if] */ tmp554 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp547) ; tmp556 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp556, atslab_0, tmp554) ; /* tmp555 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp556) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_vbox (arg0, tmp541, arg1) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (tmp546 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: /* tmp557 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp558 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp559 = */ atspre_prerr_string (ATSstrcst(": a [vbox] pattern is assgined the type [")) ; /* tmp560 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp541) ; /* tmp561 = */ atspre_prerr_string (ATSstrcst("] that is not a [vbox] prop.")) ; /* tmp562 = */ atspre_prerr_newline () ; /* tmp539 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp539) ; } /* end of [p2at_vbox_tr_dn_35] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 34757(line=1013, offs=3) -- 39270(line=1133, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; // ATSlocal_void (tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_int_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; // ATSlocal_void (tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; // ATSlocal_void (tmp581) ; ATSlocal (ats_bool_type, tmp582) ; // ATSlocal_void (tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; // ATSlocal_void (tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_bool_type, tmp587) ; ATSlocal (ats_char_type, tmp588) ; ATSlocal (ats_int_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_int_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; // ATSlocal_void (tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; // ATSlocal_void (tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_bool_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; // ATSlocal_void (tmp612) ; // ATSlocal_void (tmp613) ; // ATSlocal_void (tmp614) ; // ATSlocal_void (tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_int_type, tmp621) ; ATSlocal (ats_int_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_bool_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; // ATSlocal_void (tmp632) ; // ATSlocal_void (tmp633) ; // ATSlocal_void (tmp634) ; ATSlocal (ats_size_type, tmp635) ; ATSlocal (ats_int_type, tmp636) ; // ATSlocal_void (tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; // ATSlocal_void (tmp641) ; ATSlocal (ats_int_type, tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; // ATSlocal_void (tmp645) ; // ATSlocal_void (tmp646) ; // ATSlocal_void (tmp647) ; // ATSlocal_void (tmp648) ; // ATSlocal_void (tmp649) ; // ATSlocal_void (tmp650) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn: tmp564 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp565 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (((ats_sum_ptr_type)tmp565)->tag != 0) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp566 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_0) ; tmp567 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_1) ; /* tmp568 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp564, arg1, tmp567) ; tmp569 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp566, arg1) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_ann (tmp564, arg1, tmp569, tmp567) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)tmp565)->tag != 1) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp563 = p2at_any_tr_dn_10 (tmp564, arg1) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp565)->tag != 2) { goto __ats_lab_132_0 ; } __ats_lab_129_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_3, tmp565, atslab_0) ; tmp571 = ats_caselptrlab_mac(anairiats_sum_3, tmp565, atslab_1) ; tmp572 = ats_caselptrlab_mac(anairiats_sum_3, tmp565, atslab_2) ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp574 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp572, tmp573) ; tmp576 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp576, atslab_0, tmp573) ; /* tmp575 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp571, tmp576) ; tmp578 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp574), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (tmp578 != (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp579 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp574), atslab_p3at_typ) ; tmp577 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (tmp579) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (tmp578 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp580 = ats_caselptrlab_mac(anairiats_sum_11, tmp578, atslab_0) ; tmp577 = tmp580 ; break ; } while (0) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp577) ; if (tmp582) { /* tmp583 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (tmp571, 0) ; tmp584 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; /* tmp581 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp571, tmp584) ; } else { /* empty */ } /* end of [if] */ tmp586 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp586, atslab_0, tmp577) ; /* tmp585 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp571, tmp586) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as (tmp564, tmp573, tmp570, tmp571, tmp574) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp565)->tag != 3) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp587 = ats_caselptrlab_mac(anairiats_sum_18, tmp565, atslab_0) ; tmp563 = p2at_bool_tr_dn_11 (tmp564, tmp587, arg1) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp565)->tag != 4) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp588 = ats_caselptrlab_mac(anairiats_sum_19, tmp565, atslab_0) ; tmp563 = p2at_char_tr_dn_12 (tmp564, tmp588, arg1) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp565)->tag != 5) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp589 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_0) ; tmp590 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_1) ; tmp591 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_2) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_3) ; tmp593 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_4) ; tmp594 = ats_caselptrlab_mac(anairiats_sum_20, tmp565, atslab_5) ; tmp563 = p2at_con_tr_dn_22 (tmp564, tmp589, tmp590, tmp591, tmp592, tmp593, tmp594, arg1) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp565)->tag != 6) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp595 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp564, arg1) ; tmp597 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; /* tmp596 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp564, tmp595, tmp597) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_empty (tmp564, tmp595) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp565)->tag != 7) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp598 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_0) ; tmp599 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_1) ; tmp563 = p2at_exist_tr_dn_24 (arg0, tmp598, tmp599, arg1) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp565)->tag != 8) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp600 = ats_caselptrlab_mac(anairiats_sum_2, tmp565, atslab_0) ; tmp601 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; /* tmp602 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp564, arg1, tmp601) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_float (tmp564, tmp601, tmp600) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp565)->tag != 9) { goto __ats_lab_143_0 ; } __ats_lab_138_1: tmp603 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_0) ; tmp604 = ats_caselptrlab_mac(anairiats_sum_1, tmp565, atslab_1) ; tmp605 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp564, arg1) ; tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp605), atslab_s2exp_node) ; do { /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp606)->tag != 0) { goto __ats_lab_142_0 ; } __ats_lab_139_1: tmp607 = ats_caselptrlab_mac(anairiats_sum_1, tmp606, atslab_0) ; tmp608 = ats_caselptrlab_mac(anairiats_sum_1, tmp606, atslab_1) ; tmp609 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype, tmp607) ; if (!tmp609) { goto __ats_lab_142_1 ; } do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (tmp608 == (ats_sum_ptr_type)0) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp611 = ats_caselptrlab_mac(anairiats_sum_7, tmp608, atslab_0) ; tmp610 = tmp611 ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: // if (tmp608 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_141_1: /* tmp612 = */ prerr_loc_interror_1 (tmp564) ; /* tmp613 = */ atspre_prerr_string (ATSstrcst(": p2at_tr_dn: P2Tint")) ; /* tmp614 = */ atspre_prerr_newline () ; /* tmp610 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (tmp604) ; /* tmp615 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (tmp564, tmp616, tmp610) ; tmp617 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype (tmp604) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int (tmp564, tmp617, tmp603, tmp604) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: __ats_lab_142_1: tmp618 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype () ; /* tmp619 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp564, tmp605, tmp618) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_int (tmp564, tmp618, tmp603, tmp604) ; break ; } while (0) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp565)->tag != 11) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp620 = ats_caselptrlab_mac(anairiats_sum_2, tmp565, atslab_0) ; tmp563 = p2at_lst_tr_dn_27 (tmp564, tmp620, arg1) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp565)->tag != 12) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp621 = ats_caselptrlab_mac(anairiats_sum_5, tmp565, atslab_0) ; tmp622 = ats_caselptrlab_mac(anairiats_sum_5, tmp565, atslab_1) ; tmp623 = ats_caselptrlab_mac(anairiats_sum_5, tmp565, atslab_2) ; tmp563 = p2at_rec_tr_dn_32 (arg0, tmp621, tmp622, tmp623, arg1) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp565)->tag != 13) { goto __ats_lab_150_0 ; } __ats_lab_145_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_2, tmp565, atslab_0) ; tmp625 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp564, arg1) ; tmp626 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp625), atslab_s2exp_node) ; do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp626)->tag != 0) { goto __ats_lab_149_0 ; } __ats_lab_146_1: tmp627 = ats_caselptrlab_mac(anairiats_sum_1, tmp626, atslab_0) ; tmp628 = ats_caselptrlab_mac(anairiats_sum_1, tmp626, atslab_1) ; tmp629 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type, tmp627) ; if (!tmp629) { goto __ats_lab_149_1 ; } do { /* branch: __ats_lab_147 */ __ats_lab_147_0: if (tmp628 == (ats_sum_ptr_type)0) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp631 = ats_caselptrlab_mac(anairiats_sum_7, tmp628, atslab_0) ; tmp630 = tmp631 ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: // if (tmp628 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_148_1: /* tmp632 = */ prerr_loc_interror_1 (tmp564) ; /* tmp633 = */ atspre_prerr_string (ATSstrcst(": p2at_tr_dn: P2Tstring")) ; /* tmp634 = */ atspre_prerr_newline () ; /* tmp630 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp635 = atspre_string_length (tmp624) ; tmp636 = atspre_int1_of_size1 (ats_castfn_mac(ats_size_type, tmp635)) ; tmp638 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp636) ; /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (tmp564, tmp630, tmp638) ; tmp639 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type (tmp636) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string (tmp564, tmp639, tmp624) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: __ats_lab_149_1: tmp640 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; /* tmp641 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp564, tmp625, tmp640) ; tmp563 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_string (tmp564, tmp640, tmp624) ; break ; } while (0) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)tmp565)->tag != 14) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp642 = ats_caselptrlab_mac(anairiats_sum_6, tmp565, atslab_0) ; tmp643 = ats_caselptrlab_mac(anairiats_sum_6, tmp565, atslab_1) ; tmp563 = p2at_var_tr_dn_34 (arg0, tmp642, tmp643, arg1) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp565)->tag != 15) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_2, tmp565, atslab_0) ; /* tmp645 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref (tmp564) ; /* tmp646 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_eff (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; tmp563 = p2at_vbox_tr_dn_35 (tmp564, tmp644, arg1) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: __ats_lab_152_1: /* tmp647 = */ prerr_loc_interror_1 (tmp564) ; /* tmp648 = */ atspre_prerr_string (ATSstrcst(": p2at_tr_dn: not implemented yet: p2t0 = ")) ; /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at (arg0) ; /* tmp650 = */ atspre_prerr_newline () ; /* tmp563 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp563) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 39340(line=1137, offs=25) -- 39576(line=1142, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn: do { /* branch: __ats_lab_153 */ __ats_lab_153_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp652 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp653 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp654 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp655 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp656 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp652, tmp654) ; tmp657 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn (tmp653, tmp655) ; tmp651 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp651, atslab_0, tmp656) ; ats_selptrset_mac(anairiats_sum_7, tmp651, atslab_1, tmp657) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_154_1: tmp651 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp651) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 39650(line=1148, offs=16) -- 40157(line=1165, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; // ATSlocal_void (tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; // ATSlocal_void (tmp666) ; // ATSlocal_void (tmp667) ; // ATSlocal_void (tmp668) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_up: tmp659 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp659)->tag != 0) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp660 = ats_caselptrlab_mac(anairiats_sum_1, tmp659, atslab_0) ; tmp661 = ats_caselptrlab_mac(anairiats_sum_1, tmp659, atslab_1) ; tmp658 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn (tmp660, tmp661) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: __ats_lab_156_1: tmp662 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_typ) ; do { /* branch: __ats_lab_157 */ __ats_lab_157_0: if (tmp662 == (ats_sum_ptr_type)0) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp663 = ats_caselptrlab_mac(anairiats_sum_11, tmp662, atslab_0) ; tmp658 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (arg0, tmp663) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: // if (tmp662 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_158_1: tmp665 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp664 = */ prerr_loc_interror_1 (tmp665) ; /* tmp666 = */ atspre_prerr_string (ATSstrcst(": p2at_arg_tr_up: p2t0 = ")) ; /* tmp667 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at (arg0) ; /* tmp668 = */ atspre_prerr_newline () ; /* tmp658 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp658) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 40724(line=1185, offs=10) -- 40962(line=1190, offs=12) */ ATSstaticdec() ats_void_type refknd_check_40 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp674) ; ATSlocal (ats_bool_type, tmp675) ; // ATSlocal_void (tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; // ATSlocal_void (tmp678) ; // ATSlocal_void (tmp679) ; // ATSlocal_void (tmp680) ; __ats_lab_refknd_check_40: tmp675 = atspre_gt_int_int (arg1, 0) ; if (tmp675) { tmp677 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp676 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp677) ; /* tmp678 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp679 = */ atspre_prerr_string (ATSstrcst(": misuse of refvar pattern.")) ; /* tmp680 = */ atspre_prerr_newline () ; /* tmp674 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp674) */ ; } /* end of [refknd_check_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 40214(line=1168, offs=16) -- 47012(line=1317, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; ATSlocal (ats_int_type, tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_int_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_bool_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; // ATSlocal_void (tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; // ATSlocal_void (tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; // ATSlocal_void (tmp694) ; // ATSlocal_void (tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; // ATSlocal_void (tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; // ATSlocal_void (tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; // ATSlocal_void (tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; // ATSlocal_void (tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; // ATSlocal_void (tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_int_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_bool_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; // ATSlocal_void (tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; // ATSlocal_void (tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; // ATSlocal_void (tmp728) ; // ATSlocal_void (tmp729) ; ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; // ATSlocal_void (tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; // ATSlocal_void (tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; // ATSlocal_void (tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; // ATSlocal_void (tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; // ATSlocal_void (tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; // ATSlocal_void (tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; // ATSlocal_void (tmp750) ; // ATSlocal_void (tmp751) ; // ATSlocal_void (tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_int_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; // ATSlocal_void (tmp763) ; // ATSlocal_void (tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; // ATSlocal_void (tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; // ATSlocal_void (tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; // ATSlocal_void (tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; // ATSlocal_void (tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; // ATSlocal_void (tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; // ATSlocal_void (tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; // ATSlocal_void (tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn: tmp670 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp671 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp670), atslab_s2exp_node) ; do { /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp671)->tag != 20) { goto __ats_lab_171_0 ; } __ats_lab_159_1: tmp672 = ats_caselptrlab_mac(anairiats_sum_6, tmp671, atslab_0) ; tmp673 = ats_caselptrlab_mac(anairiats_sum_6, tmp671, atslab_1) ; tmp681 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp681)->tag != 14) { goto __ats_lab_163_0 ; } __ats_lab_160_1: tmp682 = ats_caselptrlab_mac(anairiats_sum_6, tmp681, atslab_0) ; tmp683 = ats_caselptrlab_mac(anairiats_sum_6, tmp681, atslab_1) ; do { /* branch: __ats_lab_161 */ __ats_lab_161_0: __ats_lab_161_1: tmp684 = atspre_eq_int_int (tmp672, 0) ; if (!tmp684) { goto __ats_lab_162_1 ; } tmp685 = p2at_var_tr_dn_34 (arg0, tmp682, tmp683, tmp673) ; tmp687 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp687, atslab_0, tmp673) ; /* tmp686 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp683, tmp687) ; /* tmp688 = */ atsopt_p3at_set_typ (tmp685, tmp670) ; tmp669 = tmp685 ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: __ats_lab_162_1: tmp689 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp689, tmp673) ; tmp692 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (tmp683) ; tmp691 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp692, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; tmp693 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp691) ; /* tmp694 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp691) ; tmp696 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp696, atslab_0, tmp693) ; /* tmp695 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp683, tmp696) ; tmp698 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr () ; tmp697 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool (tmp693, tmp698) ; /* tmp699 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (tmp689, tmp697) ; tmp700 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none (tmp683) ; tmp702 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp702, atslab_0, tmp700) ; /* tmp701 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (tmp683, tmp702) ; /* tmp703 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp700) ; tmp704 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp673, tmp693) ; tmp706 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp706, atslab_0, tmp704) ; /* tmp705 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp700, tmp706) ; tmp707 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp690, tmp693) ; tmp709 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp709, atslab_0, tmp707) ; /* tmp708 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp700, tmp709) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var (tmp689, tmp670, tmp682, tmp683) ; break ; } while (0) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp681)->tag != 2) { goto __ats_lab_170_0 ; } __ats_lab_163_1: tmp710 = ats_caselptrlab_mac(anairiats_sum_3, tmp681, atslab_0) ; tmp711 = ats_caselptrlab_mac(anairiats_sum_3, tmp681, atslab_1) ; tmp712 = ats_caselptrlab_mac(anairiats_sum_3, tmp681, atslab_2) ; do { /* branch: __ats_lab_164 */ __ats_lab_164_0: __ats_lab_164_1: tmp713 = atspre_eq_int_int (tmp672, 0) ; if (!tmp713) { goto __ats_lab_167_1 ; } tmp714 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp715 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp712, tmp673) ; tmp717 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp717, atslab_0, tmp673) ; /* tmp716 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp711, tmp717) ; tmp719 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp715), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_165 */ __ats_lab_165_0: if (tmp719 != (ats_sum_ptr_type)0) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp721 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp715), atslab_p3at_typ) ; tmp720 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (tmp721) ; tmp718 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp718, atslab_0, tmp720) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: __ats_lab_166_1: tmp718 = tmp719 ; break ; } while (0) ; /* tmp722 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp711, tmp718) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as (tmp714, tmp670, tmp710, tmp711, tmp715) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: __ats_lab_167_1: tmp723 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp724 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp712, tmp673) ; tmp726 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (tmp711) ; tmp725 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp726, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; tmp727 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp725) ; /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp725) ; tmp730 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp730, atslab_0, tmp727) ; /* tmp729 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp711, tmp730) ; tmp732 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr () ; tmp731 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool (tmp727, tmp732) ; /* tmp733 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (tmp723, tmp731) ; tmp734 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none (tmp711) ; tmp736 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp736, atslab_0, tmp734) ; /* tmp735 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (tmp711, tmp736) ; /* tmp737 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp734) ; tmp738 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp673, tmp727) ; tmp740 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp740, atslab_0, tmp738) ; /* tmp739 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp734, tmp740) ; tmp742 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp724), atslab_p3at_typ_lft) ; do { /* branch: __ats_lab_168 */ __ats_lab_168_0: if (tmp742 == (ats_sum_ptr_type)0) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp743 = ats_caselptrlab_mac(anairiats_sum_11, tmp742, atslab_0) ; tmp741 = tmp743 ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: // if (tmp742 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_169_1: tmp744 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp724), atslab_p3at_typ) ; tmp741 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (tmp744) ; break ; } while (0) ; tmp745 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp741, tmp727) ; tmp747 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp747, atslab_0, tmp745) ; /* tmp746 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp734, tmp747) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_as (tmp723, tmp670, tmp710, tmp711, tmp724) ; break ; } while (0) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: __ats_lab_170_1: tmp749 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp748 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp749) ; /* tmp750 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp751 = */ atspre_prerr_string (ATSstrcst(": the pattern is expected to be a variable but it is not.")) ; /* tmp752 = */ atspre_prerr_newline () ; /* tmp669 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)tmp671)->tag != 34) { goto __ats_lab_174_0 ; } __ats_lab_171_1: tmp753 = ats_caselptrlab_mac(anairiats_sum_2, tmp671, atslab_0) ; tmp754 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp754)->tag != 14) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp755 = ats_caselptrlab_mac(anairiats_sum_6, tmp754, atslab_0) ; tmp756 = ats_caselptrlab_mac(anairiats_sum_6, tmp754, atslab_1) ; tmp757 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; tmp758 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_viewt0ype () ; tmp759 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_types_viewt0ype (tmp753) ; tmp761 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (tmp756) ; tmp760 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp761, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; tmp762 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp760) ; /* tmp763 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (tmp760) ; tmp765 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp765, atslab_0, tmp762) ; /* tmp764 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp756, tmp765) ; tmp766 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none (tmp756) ; tmp768 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_0, tmp766) ; /* tmp767 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (tmp756, tmp768) ; /* tmp769 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (tmp766) ; tmp770 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp758, tmp762) ; tmp772 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp772, atslab_0, tmp770) ; /* tmp771 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp766, tmp772) ; tmp773 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp759, tmp762) ; tmp775 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp775, atslab_0, tmp773) ; /* tmp774 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp766, tmp775) ; tmp776 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (tmp758) ; tmp777 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp776, tmp762) ; tmp779 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp779)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp779, atslab_0, tmp777) ; /* tmp778 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp766, tmp779) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__p3at_var (tmp757, tmp670, tmp755, tmp756) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: __ats_lab_173_1: tmp781 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_loc) ; /* tmp780 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp781) ; /* tmp782 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp783 = */ atspre_prerr_string (ATSstrcst(": the pattern is expected to be a variable but it is not.")) ; /* tmp784 = */ atspre_prerr_newline () ; /* tmp669 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: __ats_lab_174_1: tmp669 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (arg0, tmp670) ; break ; } while (0) ; return (tmp669) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47085(line=1320, offs=7) -- 47224(line=1322, offs=24) */ ATSstaticdec() ats_void_type loop_42 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; // ATSlocal_void (tmp789) ; __ats_lab_loop_42: do { /* branch: __ats_lab_175 */ __ats_lab_175_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp787 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp788 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; /* tmp789 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf (tmp787, ats_true_bool) ; arg0 = tmp788 ; goto __ats_lab_loop_42 ; // tail call break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_176_1: break ; } while (0) ; return /* (tmp786) */ ; } /* end of [loop_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47047(line=1319, offs=4) -- 47298(line=1326, offs=4) */ ATSstaticdec() ats_void_type p2at_proofize_41 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp785) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; __ats_lab_p2at_proofize_41: tmp791 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_p2at_dvs) ; tmp790 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp791) ; /* tmp785 = */ loop_42 (tmp790) ; return /* (tmp785) */ ; } /* end of [p2at_proofize_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47381(line=1330, offs=7) -- 47681(line=1336, offs=33) */ ATSstaticdec() ats_ptr_type aux_44 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; // ATSlocal_void (tmp796) ; ATSlocal (ats_bool_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_int_type, tmp800) ; __ats_lab_aux_44: do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp794 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp795 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp797 = atspre_gt_int_int (arg0, 0) ; if (tmp797) { /* tmp796 = */ p2at_proofize_41 (tmp794) ; } else { /* empty */ } /* end of [if] */ tmp798 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_up (tmp794) ; tmp800 = atspre_sub_int_int (arg0, 1) ; tmp799 = aux_44 (tmp800, tmp795) ; tmp793 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp793, atslab_0, tmp798) ; ats_selptrset_mac(anairiats_sum_7, tmp793, atslab_1, tmp799) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_178_1: tmp793 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp793) ; } /* end of [aux_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47357(line=1329, offs=19) -- 47724(line=1340, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_up (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp792) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_up: tmp792 = aux_44 (arg0, arg1) ; return (tmp792) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47817(line=1344, offs=7) -- 48205(line=1354, offs=33) */ ATSstaticdec() ats_ptr_type aux_46 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; // ATSlocal_void (tmp807) ; ATSlocal (ats_bool_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_int_type, tmp811) ; __ats_lab_aux_46: do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp803 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp804 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp805 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp806 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_1) ; tmp808 = atspre_gt_int_int (arg0, 0) ; if (tmp808) { /* tmp807 = */ p2at_proofize_41 (tmp803) ; } else { /* empty */ } /* end of [if] */ tmp809 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_arg_tr_dn (tmp803, tmp805) ; tmp811 = atspre_sub_int_int (arg0, 1) ; tmp810 = aux_46 (tmp811, tmp804, tmp806) ; tmp802 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp802, atslab_0, tmp809) ; ats_selptrset_mac(anairiats_sum_7, tmp802, atslab_1, tmp810) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_180_1: tmp802 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp802) ; } /* end of [aux_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_pat.dats: 47787(line=1343, offs=19) -- 48256(line=1358, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_dn (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp801) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_dn: tmp801 = aux_46 (arg0, arg1, arg2) ; return (tmp801) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_dn] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__P2ATCONTRUPcon_0.tag = 0 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_pat_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_counter_dats.c0000664000175000017500000002125112223166160021577 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_compare_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_count) (ats_ref_type, atsopt_count_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 1757(line=51, offs=26) -- 1796(line=51, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp0) ; ATSlocal (ats_int_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count: tmp1 = atsopt_compare_count_count (arg0, arg1) ; tmp0 = atspre_ilt (tmp1, 0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 1823(line=52, offs=27) -- 1863(line=52, offs=67) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count: tmp3 = atsopt_compare_count_count (arg0, arg1) ; tmp2 = atspre_ilte (tmp3, 0) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 1889(line=53, offs=26) -- 1928(line=53, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gt_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp4) ; ATSlocal (ats_int_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gt_count_count: tmp5 = atsopt_compare_count_count (arg0, arg1) ; tmp4 = atspre_igt (tmp5, 0) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gt_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 1955(line=54, offs=27) -- 1995(line=54, offs=67) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gte_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gte_count_count: tmp7 = atsopt_compare_count_count (arg0, arg1) ; tmp6 = atspre_igte (tmp7, 0) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gte_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 2021(line=55, offs=26) -- 2060(line=55, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count: tmp9 = atsopt_compare_count_count (arg0, arg1) ; tmp8 = atspre_ieq (tmp9, 0) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 2087(line=56, offs=27) -- 2127(line=56, offs=67) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count: tmp11 = atsopt_compare_count_count (arg0, arg1) ; tmp10 = atspre_ineq (tmp11, 0) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 2172(line=60, offs=23) -- 2209(line=60, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__print_count (atsopt_count_type arg0) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__print_count: tmp13 = atspre_stdout_get () ; tmp14 = ats_selsin_mac(tmp13, atslab_1) ; /* tmp15 = */ atsopt_fprint_count (tmp14, arg0) ; /* tmp12 = */ atspre_stdout_view_set () ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__print_count] */ /* // /home/hwxi/research/Anairiats/src/ats_counter.dats: 2232(line=61, offs=23) -- 2269(line=61, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__prerr_count (atsopt_count_type arg0) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__prerr_count: tmp17 = atspre_stderr_get () ; tmp18 = ats_selsin_mac(tmp17, atslab_1) ; /* tmp19 = */ atsopt_fprint_count (tmp18, arg0) ; /* tmp16 = */ atspre_stderr_view_set () ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__prerr_count] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_counter_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_sta_dats.c0000664000175000017500000116747312223166160022222 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_s1rt_loc ; ats_ptr_type atslab_s1rt_node ; } anairiats_rec_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_s0taq_loc ; ats_ptr_type atslab_s0taq_node ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_7 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_s1arg_loc ; ats_ptr_type atslab_s1arg_sym ; ats_ptr_type atslab_s1arg_srt ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_sp1at_loc ; ats_ptr_type atslab_sp1at_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_13 ; typedef struct { anairiats_rec_0 atslab_0 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_s1rtext_loc ; ats_ptr_type atslab_s1rtext_node ; } anairiats_rec_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_19 ; typedef struct { ats_ptr_type atslab_s1qua_loc ; ats_ptr_type atslab_s1qua_node ; } anairiats_rec_20 ; typedef struct { anairiats_rec_0 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_d0ynq_loc ; ats_ptr_type atslab_d0ynq_node ; } anairiats_rec_22 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_23 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_24 ; typedef struct { ats_ptr_type atslab_s1exparg_loc ; ats_ptr_type atslab_s1exparg_node ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_s1rtdef_loc ; ats_ptr_type atslab_s1rtdef_sym ; ats_ptr_type atslab_s1rtdef_def ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_d1atarg_loc ; ats_ptr_type atslab_d1atarg_node ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_s1rtpol_loc ; ats_ptr_type atslab_s1rtpol_srt ; ats_int_type atslab_s1rtpol_pol ; } anairiats_rec_29 ; typedef struct { anairiats_rec_27 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_30 ; typedef struct { ats_ptr_type atslab_s1tacon_fil ; ats_ptr_type atslab_s1tacon_loc ; ats_ptr_type atslab_s1tacon_sym ; ats_ptr_type atslab_s1tacon_arg ; ats_ptr_type atslab_s1tacon_def ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_s1tacst_fil ; ats_ptr_type atslab_s1tacst_loc ; ats_ptr_type atslab_s1tacst_sym ; ats_ptr_type atslab_s1tacst_arg ; ats_ptr_type atslab_s1tacst_res ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_s1tavar_loc ; ats_ptr_type atslab_s1tavar_sym ; ats_ptr_type atslab_s1tavar_srt ; } anairiats_rec_33 ; typedef struct { ats_ptr_type atslab_d1atsrtcon_loc ; ats_ptr_type atslab_d1atsrtcon_sym ; ats_ptr_type atslab_d1atsrtcon_arg ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_d1atsrtdec_loc ; ats_ptr_type atslab_d1atsrtdec_sym ; ats_ptr_type atslab_d1atsrtdec_con ; } anairiats_rec_35 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_36 ; typedef struct { anairiats_rec_36 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_37 ; typedef struct { ats_ptr_type atslab_s1expdef_loc ; ats_ptr_type atslab_s1expdef_sym ; ats_ptr_type atslab_s1expdef_arg ; ats_ptr_type atslab_s1expdef_res ; ats_ptr_type atslab_s1expdef_def ; } anairiats_rec_38 ; typedef struct { ats_ptr_type atslab_s1aspdec_fil ; ats_ptr_type atslab_s1aspdec_loc ; ats_ptr_type atslab_s1aspdec_qid ; ats_ptr_type atslab_s1aspdec_arg ; ats_ptr_type atslab_s1aspdec_res ; ats_ptr_type atslab_s1aspdec_def ; } anairiats_rec_39 ; typedef struct { ats_ptr_type atslab_sqi0de_loc ; ats_ptr_type atslab_sqi0de_qua ; ats_ptr_type atslab_sqi0de_sym ; } anairiats_rec_40 ; typedef struct { ats_ptr_type atslab_d1atcon_loc ; ats_ptr_type atslab_d1atcon_sym ; ats_ptr_type atslab_d1atcon_qua ; ats_int_type atslab_d1atcon_npf ; ats_ptr_type atslab_d1atcon_arg ; ats_ptr_type atslab_d1atcon_ind ; } anairiats_rec_41 ; typedef struct { ats_ptr_type atslab_d1atdec_fil ; ats_ptr_type atslab_d1atdec_loc ; ats_ptr_type atslab_d1atdec_sym ; ats_ptr_type atslab_d1atdec_arg ; ats_ptr_type atslab_d1atdec_con ; } anairiats_rec_42 ; typedef struct { ats_ptr_type atslab_e1xndec_fil ; ats_ptr_type atslab_e1xndec_loc ; ats_ptr_type atslab_e1xndec_sym ; ats_ptr_type atslab_e1xndec_qua ; ats_int_type atslab_e1xndec_npf ; ats_ptr_type atslab_e1xndec_arg ; } anairiats_rec_43 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDtype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDt0ype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewt0ype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQfildot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymcolon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymdot_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymcolon_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTqid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTtup_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGidsrt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__SP1Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qvars_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eapp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Echar_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eexi_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eextype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eimp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eint_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Einvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elam_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eqid_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eread_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etop_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etrans_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyarr_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_ext_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup2_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Euni_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eunion_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatconptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatcontyp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMe1xp_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMvar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDarrow_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDnone_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int) (ats_int_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_beg) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_end) (ats_lint_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_union_stamp_make) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__s0taq_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_is_arrow) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1explst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_datakind) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc) (ats_ptr_type, ats_bool_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_make) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_set_conlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_bool_type, ats_bool_type, ats_bool_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_dat) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_fil) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_islst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_tag) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_s2exp_set_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sp2at_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_wind) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt) (ats_ptr_type, atsopt_count_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_one) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_all) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_select_s2explstlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed) (ats_int_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst) (ats_int_type, ats_int_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_alpha) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_alpha) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2tavar_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2aspdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datconptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datcontyp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglstlst_var_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explstlst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_view) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_bool) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDarrow_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDnone_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_void_type stacstuseloc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1rt_app_tr_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type staspecid_of_qid_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type effvar_tr_9 (ats_ptr_type arg0) ; static ats_ptr_type effvarlst_tr_10 (ats_ptr_type arg0) ; static ats_ptr_type s1rtopt_search_13 (ats_ptr_type arg0) ; static ats_ptr_type sp1at_arg_tr_dn_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type check_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type sp1at_argcheck_17 (ats_ptr_type arg0) ; static ats_ptr_type err1_20 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type err1_20_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type err1_20_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err2_21 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type err2_21_closure_make (ats_ptr_type env0) ; static ats_ptr_type err2_21_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err3_22 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type err3_22_closure_make (ats_ptr_type env0) ; static ats_ptr_type err3_22_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type argcheck_err_23 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type argcheck_err_23_closure_make (ats_ptr_type env0) ; static ats_void_type argcheck_err_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type sel_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s1explst_tr_dn_t0ype_34 (ats_ptr_type arg0) ; static ats_ptr_type s1explst_tr_dn_viewt0ype_38 (ats_ptr_type arg0) ; static ats_ptr_type s1explstlst_tr_dn_viewt0ype_39 (ats_ptr_type arg0) ; static ats_ptr_type s1exp_any_tr_up_42 (ats_ptr_type arg0) ; static ats_ptr_type loop_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s1exp_app_tr_up_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_46 (ats_ptr_type arg0) ; static ats_ptr_type s1exp_app_datconptr_tr_up_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_48 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1exp_app_datcontyp_tr_up_47 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_qid_app_tr_up_49 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type loop_51 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1exp_qid_tr_up_50 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_invar_tr_up_52 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1exp_read_tr_up_53 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1exp_top_tr_up_54 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxwth_58 (ats_ptr_type arg0) ; static ats_ptr_type auxres_59 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_61 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type s1exp_arrow_tr_up_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2, ats_bool_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type s1rtext_tr_62 (ats_ptr_type arg0) ; static ats_void_type aux_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux1_66 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux1_66_closure_make (ats_ptr_type env0) ; static ats_void_type aux1_66_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux2_67 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux2_67_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_void_type aux2_67_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_void_type loop_64 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_ptr_type s1exp_app_unwind_69 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type s2rtlst_of_s2varlst_70 (ats_ptr_type arg0) ; static ats_ptr_type aux01_71 (ats_int_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4, ats_ptr_type arg5) ; static ats_ptr_type aux23_72 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s1exp_list_tr_up_73 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_tytup_tr_up_74 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_tytup2_tr_up_75 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux01_76 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux23_77 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err1_79 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err2_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_tmpid_tr_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_tyrec_tr_up_81 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_tyrec_ext_tr_up_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type s1exp_union_tr_up_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type s1rtdef_tr_92 (ats_ptr_type arg0) ; static anairiats_rec_27 d1atarg_tr_94 (ats_ptr_type arg0) ; static ats_ptr_type aux_97 (ats_ptr_type arg0) ; static ats_ptr_type aux_98 (ats_ptr_type arg0) ; static ats_void_type s1tacon_tr_96 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_100 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type s1tacst_tr_101 (ats_ptr_type arg0) ; static ats_ptr_type s1tavar_tr_103 (ats_ptr_type arg0) ; static ats_ptr_type aux_106 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type auxlst_107 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d1atsrtdec_tr_105 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop1_109 (ats_ptr_type arg0) ; static ats_void_type loop2_110 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_112 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s1expdef_s1aspdec_tr_main_111 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type err_114 (ats_ptr_type arg0) ; static ats_ptr_type aux_116 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_117 (ats_ptr_type arg0) ; static ats_ptr_type err1_119 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type err3_120 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err4_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err5_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type filter_123 (ats_ptr_type arg0) ; static ats_ptr_type err1_125 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err2_126 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err3_127 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err4_128 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_129 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_129_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_129_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d1atcon_tr_124 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type d1atconlst_tr_130 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_void_type aux_132 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type d1atdec_tr_131 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_135 (ats_ptr_type arg0) ; static ats_ptr_type aux_136 (ats_ptr_type arg0) ; static ats_void_type aux_134 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_clo_ptr_type aux_134_closure_make (ats_ptr_type env0) ; static ats_void_type aux_134_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type auxlst_137 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_clo_ptr_type auxlst_137_closure_make (ats_ptr_type env0) ; static ats_void_type auxlst_137_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_138 (ats_ptr_type arg0) ; static ats_ptr_type aux_139 (ats_ptr_type arg0) ; static ats_ptr_type e1xndec_tr_140 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2conlst_revapp_141 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_143 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 2657(line=93, offs=4) -- 2742(line=94, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 2776(line=97, offs=4) -- 2835(line=97, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans2_sta)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 2840(line=99, offs=4) -- 2952(line=101, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans2_sta)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 3009(line=105, offs=4) -- 3354(line=114, offs=4) */ ATSstaticdec() ats_void_type stacstuseloc_posmark_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_lint_type, tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_lint_type, tmp9) ; __ats_lab_stacstuseloc_posmark_3: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_loc (arg1) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg0) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_beg (tmp7, tmp6) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (arg0) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_insert_stacstuse_end (tmp9, tmp6) ; return /* (tmp5) */ ; } /* end of [stacstuseloc_posmark_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 3414(line=118, offs=5) -- 4329(line=148, offs=4) */ ATSstaticdec() ats_ptr_type s1rt_app_tr_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_bool_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_s1rt_app_tr_4: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: __ats_lab_0_1: tmp11 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_is_arrow (arg1) ; if (!tmp11) { goto __ats_lab_5_1 ; } do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } tmp12 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; if (tmp12 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } tmp13 = ats_caselptrlab_mac(anairiats_sum_1, tmp12, atslab_1) ; if (tmp13 != (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_1_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp15 = ats_caselptrlab_mac(anairiats_sum_1, tmp12, atslab_0) ; tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp14), atslab_s1rt_node) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp17)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_3, tmp17, atslab_0) ; tmp16 = tmp18 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp19 = (ats_sum_ptr_type)0 ; tmp16 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp16, atslab_0, tmp14) ; ats_selptrset_mac(anairiats_sum_1, tmp16, atslab_1, tmp19) ; break ; } while (0) ; tmp20 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp16) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp15) ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp10)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp10, atslab_0, tmp20) ; ats_selptrset_mac(anairiats_sum_4, tmp10, atslab_1, tmp21) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: /* tmp22 = */ prerr_interror_1 () ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(": [s1rt_app_tr]: [->] is not an infix operator!")) ; /* tmp24 = */ atspre_prerr_newline () ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: /* tmp25 = */ prerr_loc_error2_0 (arg0) ; /* tmp26 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1rt_app_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp27 = */ atspre_prerr_string (ATSstrcst(": sort application is not supported.")) ; /* tmp28 = */ atspre_prerr_newline () ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp10) ; } /* end of [s1rt_app_tr_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 4373(line=151, offs=9) -- 5750(line=191, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr: tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_s1rt_node) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp30)->tag != 0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_4, tmp30, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_4, tmp30, atslab_1) ; tmp33 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_s1rt_loc) ; tmp29 = s1rt_app_tr_4 (tmp33, tmp31, tmp32) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp30)->tag != 1) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_3, tmp30, atslab_0) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp34) ; tmp29 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp29)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp29, atslab_0, tmp35) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp30)->tag != 2) { goto __ats_lab_13_0 ; } __ats_lab_8_1: tmp36 = ats_caselptrlab_mac(anairiats_sum_4, tmp30, atslab_0) ; tmp37 = ats_caselptrlab_mac(anairiats_sum_4, tmp30, atslab_1) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua (tmp36, tmp37) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (tmp38 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_9_1: tmp39 = ats_caselptrlab_mac(anairiats_sum_5, tmp38, atslab_0) ; ATS_FREE(tmp38) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp39)->tag != 0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_3, tmp39, atslab_0) ; tmp29 = tmp40 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp42 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_s1rt_loc) ; /* tmp41 = */ prerr_loc_error2_0 (tmp42) ; /* tmp43 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1rt_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp44 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp37) ; /* tmp46 = */ atspre_prerr_string (ATSstrcst("] refers to an extended sort but not a sort.")) ; /* tmp47 = */ atspre_prerr_newline () ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (tmp38 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_s1rt_loc) ; /* tmp48 = */ prerr_loc_error2_0 (tmp49) ; /* tmp50 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1rt_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp51 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq (tmp36) ; /* tmp53 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp37) ; /* tmp54 = */ atspre_prerr_string (ATSstrcst("] refers to an unrecognized sort.")) ; /* tmp55 = */ atspre_prerr_newline () ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)tmp30)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_3, tmp30, atslab_0) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp56) ; tmp29 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp29)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp29, atslab_0, tmp57) ; break ; } while (0) ; return (tmp29) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 5793(line=194, offs=12) -- 5906(line=197, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp60 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp59) ; tmp62 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp60) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_0, tmp61) ; ats_selptrset_mac(anairiats_sum_1, tmp58, atslab_1, tmp62) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp58 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp58) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 5952(line=200, offs=12) -- 6041(line=202, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp65 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp64) ; tmp63 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp63, atslab_0, tmp65) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp63 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 6167(line=209, offs=4) -- 6384(line=215, offs=4) */ ATSstaticdec() ats_ptr_type staspecid_of_qid_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_bool_type, tmp68) ; __ats_lab_staspecid_of_qid_8: tmp67 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_s0taq_node) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp67)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp68 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; if (tmp68) { tmp66 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDarrow_0) ; } else { tmp66 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDnone_1) ; } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp66 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDnone_1) ; break ; } while (0) ; return (tmp66) ; } /* end of [staspecid_of_qid_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 6439(line=219, offs=4) -- 7400(line=247, offs=4) */ ATSstaticdec() ats_ptr_type effvar_tr_9 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; // ATSlocal_void (tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; __ats_lab_effvar_tr_9: tmp71 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_sym) ; tmp70 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp71) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp70 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_20_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_5, tmp70, atslab_0) ; ATS_FREE(tmp70) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp72)->tag != 5) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_3, tmp72, atslab_0) ; tmp75 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_loc) ; /* tmp74 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev (tmp75, tmp73) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp73) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp77 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_loc) ; /* tmp76 = */ prerr_loc_error2_0 (tmp77) ; /* tmp78 = */ atsopt_debug_prerrf (ATSstrcst(": %s: effvar_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp79 = */ atspre_prerr_string (ATSstrcst(": the static identifer [")) ; tmp81 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_sym) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp81) ; /* tmp82 = */ atspre_prerr_string (ATSstrcst("] should refer to a variable but it does not.")) ; /* tmp83 = */ atspre_prerr_newline () ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (tmp70 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp85 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_loc) ; /* tmp84 = */ prerr_loc_error2_0 (tmp85) ; /* tmp86 = */ atsopt_debug_prerrf (ATSstrcst(": %s: effvar_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp87 = */ atspre_prerr_string (ATSstrcst(": unrecognized static identifer [")) ; tmp89 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0de_sym) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp89) ; /* tmp90 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp91 = */ atspre_prerr_newline () ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp69) ; } /* end of [effvar_tr_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 7427(line=249, offs=4) -- 7512(line=250, offs=38) */ ATSstaticdec() ats_ptr_type effvarlst_tr_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_effvarlst_tr_10: tmp92 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &effvar_tr_9) ; return (tmp92) ; } /* end of [effvarlst_tr_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 7534(line=253, offs=11) -- 7715(line=258, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_uint_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp93 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp93 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp95 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp96 = effvarlst_tr_10 (tmp95) ; tmp93 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp93)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp93, atslab_0, tmp94) ; ats_selptrset_mac(anairiats_sum_8, tmp93, atslab_1, tmp96) ; break ; } while (0) ; return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 7805(line=264, offs=7) -- 8063(line=269, offs=29) */ ATSstaticdec() ats_ptr_type s1rtopt_search_13 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_s1rtopt_search_13: do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_27_1: tmp99 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp100 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp99), atslab_s1arg_srt) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp98 = tmp101 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp101 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: arg0 = tmp100 ; goto __ats_lab_s1rtopt_search_13 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp98 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp98) ; } /* end of [s1rtopt_search_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 7786(line=263, offs=17) -- 8908(line=292, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; // ATSlocal_void (tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_31_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp104 = s1rtopt_search_13 (arg0) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp104 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_5, tmp104, atslab_0) ; tmp105 = tmp106 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (tmp104 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp108 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp102), atslab_s1arg_loc) ; /* tmp107 = */ prerr_loc_error2_0 (tmp108) ; /* tmp109 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1arglst_var_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp110 = */ atspre_prerr_string (ATSstrcst(": the static variable [")) ; tmp112 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp102), atslab_s1arg_sym) ; /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp112) ; /* tmp113 = */ atspre_prerr_string (ATSstrcst("] must be ascribed a sort.")) ; /* tmp114 = */ atspre_prerr_newline () ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp115 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp105) ; tmp117 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp102), atslab_s1arg_sym) ; tmp116 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp117, tmp115) ; tmp118 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr (tmp103) ; tmp119 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp119, atslab_0, tmp116) ; ats_selptrset_mac(anairiats_sum_1, tmp119, atslab_1, tmp118) ; /* tmp120 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (tmp119) ; tmp97 = tmp119 ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp97 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp97) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 8967(line=295, offs=20) -- 9021(line=296, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglstlst_var_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglstlst_var_tr: tmp121 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr) ; return (tmp121) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglstlst_var_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 9083(line=301, offs=3) -- 9796(line=324, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_bool_type, tmp127) ; // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; // ATSlocal_void (tmp130) ; // ATSlocal_void (tmp131) ; // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt: tmp124 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_s1arg_srt) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp124 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp125 = ats_caselptrlab_mac(anairiats_sum_5, tmp124, atslab_0) ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp125) ; tmp127 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (arg1, tmp126) ; if (tmp127) { tmp123 = tmp126 ; } else { tmp129 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_s1arg_loc) ; /* tmp128 = */ prerr_loc_error2_0 (tmp129) ; /* tmp130 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1arg_var_tr_srt"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp131 = */ atspre_prerr_string (ATSstrcst(": the static variable [")) ; tmp133 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_s1arg_sym) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp133) ; /* tmp134 = */ atspre_prerr_string (ATSstrcst("] is expected to be of the sort [")) ; /* tmp135 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg1) ; /* tmp136 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp137 = */ atspre_prerr_newline () ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (tmp124 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp123 = arg1 ; break ; } while (0) ; tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_s1arg_sym) ; tmp138 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp139, tmp123) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp138) ; tmp122 = tmp138 ; return (tmp122) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 9852(line=328, offs=5) -- 10620(line=349, offs=4) */ ATSstaticdec() ats_ptr_type sp1at_arg_tr_dn_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; __ats_lab_sp1at_arg_tr_dn_16: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_39_1 ; } __ats_lab_37_2: tmp142 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arg_var_tr_srt (tmp142, tmp144) ; tmp147 = sp1at_arg_tr_dn_16 (arg0, arg1, arg2, tmp143, tmp145) ; tmp141 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp141, atslab_0, tmp146) ; ats_selptrset_mac(anairiats_sum_1, tmp141, atslab_1, tmp147) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg3 != (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: if (arg4 != (ats_sum_ptr_type)0) { goto __ats_lab_39_1 ; } __ats_lab_38_2: tmp141 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: __ats_lab_39_2: /* tmp148 = */ prerr_loc_error2_0 (arg0) ; /* tmp149 = */ atspre_prerr_string (ATSstrcst(": the static constructor [")) ; /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp152 = */ atspre_prerr_string (ATSstrcst("] requires ")) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: /* tmp153 = */ atspre_prerr_string (ATSstrcst("fewer")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: /* tmp153 = */ atspre_prerr_string (ATSstrcst("more")) ; break ; } while (0) ; /* tmp154 = */ atspre_prerr_string (ATSstrcst(" arguments.")) ; /* tmp155 = */ atspre_prerr_newline () ; /* tmp141 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp141) ; } /* end of [sp1at_arg_tr_dn_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 10719(line=353, offs=7) -- 10982(line=360, offs=32) */ ATSstaticdec() ats_ptr_type check_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_bool_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; __ats_lab_check_18: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp159 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp161 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (tmp158) ; tmp160 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, tmp161) ; if (tmp160) { tmp157 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp157, atslab_0, tmp158) ; } else { arg0 = arg0 ; arg1 = tmp159 ; goto __ats_lab_check_18 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: tmp157 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp157) ; } /* end of [check_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 10654(line=351, offs=5) -- 11257(line=369, offs=4) */ ATSstaticdec() ats_ptr_type sp1at_argcheck_17 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; __ats_lab_sp1at_argcheck_17: do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_44_1: tmp162 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp163 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (tmp162) ; tmp164 = check_18 (tmp165, tmp163) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp164 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp156 = tmp164 ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (tmp164 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: arg0 = tmp163 ; goto __ats_lab_sp1at_argcheck_17 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp156 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp156) ; } /* end of [sp1at_argcheck_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 11365(line=376, offs=4) -- 11718(line=385, offs=4) */ ATSstaticdec() ats_ptr_type err1_20 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; __ats_lab_err1_20: /* tmp169 = */ prerr_loc_error2_0 (env1) ; /* tmp170 = */ atsopt_debug_prerrf (ATSstrcst(": %s: sp1at_tr_dn"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp171 = */ atspre_prerr_string (ATSstrcst(": the static identifier [")) ; /* tmp172 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg0) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp174 = */ atspre_prerr_string (ATSstrcst("] does not refer to a constructor associated with the sort [")) ; /* tmp175 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (env0) ; /* tmp176 = */ atspre_prerr_newline () ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp168) ; } /* end of [err1_20] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } err1_20_closure_type ; ats_ptr_type err1_20_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return err1_20 (((err1_20_closure_type*)cloptr)->closure_env_0, ((err1_20_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type err1_20_closure_init (err1_20_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&err1_20_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type err1_20_closure_make (ats_ptr_type env0, ats_ptr_type env1) { err1_20_closure_type *p_clo = ATS_MALLOC(sizeof(err1_20_closure_type)) ; err1_20_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 11742(line=387, offs=4) -- 12062(line=396, offs=4) */ ATSstaticdec() ats_ptr_type err2_21 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; __ats_lab_err2_21: /* tmp178 = */ prerr_loc_error2_0 (env0) ; /* tmp179 = */ atsopt_debug_prerrf (ATSstrcst(": %s: sp1at_tr_dn"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp180 = */ atspre_prerr_string (ATSstrcst(": the static identifier [")) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg0) ; /* tmp182 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp183 = */ atspre_prerr_string (ATSstrcst("] does not refer to a static constructor.")) ; /* tmp184 = */ atspre_prerr_newline () ; /* tmp177 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp177) ; } /* end of [err2_21] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } err2_21_closure_type ; ats_ptr_type err2_21_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return err2_21 (((err2_21_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type err2_21_closure_init (err2_21_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&err2_21_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type err2_21_closure_make (ats_ptr_type env0) { err2_21_closure_type *p_clo = ATS_MALLOC(sizeof(err2_21_closure_type)) ; err2_21_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 12086(line=398, offs=4) -- 12380(line=406, offs=4) */ ATSstaticdec() ats_ptr_type err3_22 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; // ATSlocal_void (tmp192) ; __ats_lab_err3_22: /* tmp186 = */ prerr_loc_error2_0 (env0) ; /* tmp187 = */ atsopt_debug_prerrf (ATSstrcst(": %s: sp1at_tr_dn"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp188 = */ atspre_prerr_string (ATSstrcst(": the static identifier [")) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg0) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp191 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp192 = */ atspre_prerr_newline () ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp185) ; } /* end of [err3_22] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } err3_22_closure_type ; ats_ptr_type err3_22_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return err3_22 (((err3_22_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type err3_22_closure_init (err3_22_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&err3_22_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type err3_22_closure_make (ats_ptr_type env0) { err3_22_closure_type *p_clo = ATS_MALLOC(sizeof(err3_22_closure_type)) ; err3_22_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 12404(line=408, offs=4) -- 12607(line=412, offs=4) */ ATSstaticdec() ats_void_type argcheck_err_23 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; __ats_lab_argcheck_err_23: /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp195 = */ atspre_prerr_string (ATSstrcst(": warning(2)")) ; /* tmp196 = */ atspre_prerr_string (ATSstrcst(": the static variable [")) ; /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg0) ; /* tmp198 = */ atspre_prerr_string (ATSstrcst("] occurs repeatedly.")) ; /* tmp193 = */ atspre_prerr_newline () ; return /* (tmp193) */ ; } /* end of [argcheck_err_23] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } argcheck_err_23_closure_type ; ats_void_type argcheck_err_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { argcheck_err_23 (((argcheck_err_23_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type argcheck_err_23_closure_init (argcheck_err_23_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&argcheck_err_23_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type argcheck_err_23_closure_make (ats_ptr_type env0) { argcheck_err_23_closure_type *p_clo = ATS_MALLOC(sizeof(argcheck_err_23_closure_type)) ; argcheck_err_23_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 12961(line=424, offs=17) -- 13578(line=435, offs=49) */ ATSstaticdec() ats_ptr_type sel_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_bool_type, tmp213) ; __ats_lab_sel_24: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_51_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp208) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp210)->tag != 1) { goto __ats_lab_55_0 ; } __ats_lab_52_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_4, tmp210, atslab_0) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_4, tmp210, atslab_1) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: tmp213 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (arg1, tmp212) ; if (!tmp213) { goto __ats_lab_54_1 ; } ats_ptrget_mac(ats_ptr_type, arg2) = tmp211 ; tmp207 = arg0 ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: arg0 = tmp209 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_sel_24 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: arg0 = tmp209 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_sel_24 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: tmp207 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp207) ; } /* end of [sel_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 11308(line=372, offs=13) -- 14215(line=453, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__sp1at_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; // ATSlocal_void (tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__sp1at_tr_dn: tmp167 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_sp1at_loc) ; tmp199 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_sp1at_node) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: // __ats_lab_48_1: tmp200 = ats_caselptrlab_mac(anairiats_sum_11, tmp199, atslab_0) ; tmp201 = ats_caselptrlab_mac(anairiats_sum_11, tmp199, atslab_1) ; tmp202 = ats_caselptrlab_mac(anairiats_sum_11, tmp199, atslab_2) ; tmp203 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (tmp200, tmp201) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp203 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_49_1: tmp204 = ats_caselptrlab_mac(anairiats_sum_5, tmp203, atslab_0) ; ATS_FREE(tmp203) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp204)->tag != 0) { goto __ats_lab_61_0 ; } __ats_lab_50_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_3, tmp204, atslab_0) ; /* ats_ptr_type tmp206 ; */ tmp206 = (ats_sum_ptr_type)0 ; tmp214 = sel_24 (tmp205, arg1, (&tmp206)) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp214 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_57_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_1, tmp214, atslab_0) ; tmp216 = sp1at_arg_tr_dn_16 (tmp167, tmp200, tmp201, tmp202, tmp206) ; tmp218 = sp1at_argcheck_17 (tmp216) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp218 == (ats_sum_ptr_type)0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp219 = ats_caselptrlab_mac(anairiats_sum_5, tmp218, atslab_0) ; ATS_FREE(tmp218) ; /* tmp217 = */ argcheck_err_23 (tmp167, tmp219) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (tmp218 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: break ; } while (0) ; tmp166 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sp2at_con (tmp167, tmp215, tmp216) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (tmp214 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp166 = err1_20 (arg1, tmp167, tmp200, tmp201) ; break ; } while (0) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: tmp166 = err2_21 (tmp167, tmp200, tmp201) ; break ; } while (0) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (tmp203 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: tmp166 = err3_22 (tmp167, tmp200, tmp201) ; break ; } while (0) ; break ; } while (0) ; return (tmp166) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__sp1at_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14291(line=459, offs=3) -- 14327(line=459, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool: tmp220 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; return (tmp220) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14388(line=462, offs=31) -- 14441(line=463, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_bool (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_bool: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool) ; return (tmp221) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14469(line=466, offs=17) -- 14504(line=466, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls: tmp222 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_cls) ; return (tmp222) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14535(line=468, offs=30) -- 14587(line=469, offs=44) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_cls (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_cls: tmp223 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_cls) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_cls] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14615(line=472, offs=17) -- 14650(line=472, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int: tmp224 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; return (tmp224) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14681(line=475, offs=20) -- 14731(line=475, offs=70) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int: tmp225 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int) ; return (tmp225) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14812(line=480, offs=28) -- 14848(line=480, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp226) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_prop: tmp226 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; return (tmp226) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14876(line=481, offs=28) -- 14912(line=481, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_type: tmp227 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; return (tmp227) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14941(line=482, offs=29) -- 14978(line=482, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype: tmp228 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; return (tmp228) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 14984(line=484, offs=5) -- 15079(line=485, offs=75) */ ATSstaticdec() ats_ptr_type s1explst_tr_dn_t0ype_34 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp229) ; __ats_lab_s1explst_tr_dn_t0ype_34: tmp229 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_t0ype) ; return (tmp229) ; } /* end of [s1explst_tr_dn_t0ype_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15141(line=488, offs=28) -- 15177(line=488, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_view: tmp230 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; return (tmp230) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_view] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15209(line=489, offs=32) -- 15249(line=489, offs=72) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewtype: tmp231 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; return (tmp231) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15282(line=490, offs=33) -- 15323(line=490, offs=74) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype: tmp232 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; return (tmp232) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15329(line=492, offs=5) -- 15432(line=493, offs=79) */ ATSstaticdec() ats_ptr_type s1explst_tr_dn_viewt0ype_38 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; __ats_lab_s1explst_tr_dn_viewt0ype_38: tmp233 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype) ; return (tmp233) ; } /* end of [s1explst_tr_dn_viewt0ype_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15474(line=495, offs=5) -- 15591(line=496, offs=90) */ ATSstaticdec() ats_ptr_type s1explstlst_tr_dn_viewt0ype_39 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_s1explstlst_tr_dn_viewt0ype_39: tmp234 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &s1explst_tr_dn_viewt0ype_38) ; return (tmp234) ; } /* end of [s1explstlst_tr_dn_viewt0ype_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 15669(line=500, offs=27) -- 16099(line=513, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_bool_type, tmp238) ; // ATSlocal_void (tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative: tmp236 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg0) ; tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp236), atslab_s2exp_srt) ; tmp238 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (tmp237) ; if (tmp238) { tmp235 = tmp236 ; } else { tmp240 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp239 = */ prerr_loc_error2_0 (tmp240) ; /* tmp241 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tr_dn_impredicative"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp242 = */ atspre_prerr_string (ATSstrcst(": the static expression needs to be impredicative")) ; /* tmp243 = */ atspre_prerr_string (ATSstrcst(" but is assigned the sort [")) ; /* tmp244 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp237) ; /* tmp245 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp246 = */ atspre_prerr_newline () ; /* tmp235 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return (tmp235) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 16178(line=516, offs=30) -- 16274(line=517, offs=74) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expopt_tr_dn_impredicative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expopt_tr_dn_impredicative: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp248) ; tmp247 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp247, atslab_0, tmp249) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: tmp247 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp247) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expopt_tr_dn_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 16341(line=522, offs=4) -- 16584(line=528, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_any_tr_up_42 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; __ats_lab_s1exp_any_tr_up_42: /* tmp251 = */ prerr_loc_error2_0 (arg0) ; /* tmp252 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_any_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp253 = */ atspre_prerr_string (ATSstrcst("the static expression needs to be ascribed a sort.")) ; /* tmp254 = */ atspre_prerr_newline () ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp250) ; } /* end of [s1exp_any_tr_up_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 16783(line=535, offs=7) -- 18452(line=576, offs=6) */ ATSstaticdec() ats_ptr_type loop_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (anairiats_rec_0, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (anairiats_rec_0, tmp262) ; // ATSlocal_void (tmp263) ; // ATSlocal_void (tmp264) ; // ATSlocal_void (tmp265) ; // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; // ATSlocal_void (tmp268) ; // ATSlocal_void (tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_int_type, tmp275) ; ATSlocal (ats_int_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_int_type, tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_loop_44: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_65_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp261 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg2), atslab_s2exp_srt) ; tmp260 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (tmp261) ; do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (tmp260 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_14, tmp260, atslab_0) ; ATS_FREE(tmp260) ; tmp259 = tmp262 ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (tmp260 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: /* tmp263 = */ prerr_loc_error2_0 (arg1) ; /* tmp264 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp265 = */ atspre_prerr_string (ATSstrcst(": the static expresstion [")) ; /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg2) ; /* tmp267 = */ atspre_prerr_string (ATSstrcst("] is expected to be of a functional sort")) ; /* tmp268 = */ atspre_prerr_string (ATSstrcst(", but is assigned the sort [")) ; tmp270 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg2), atslab_s2exp_srt) ; /* tmp269 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp270) ; /* tmp271 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp272 = */ atspre_prerr_newline () ; /* tmp259 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp273 = ats_select_mac(tmp259, atslab_0) ; tmp274 = ats_select_mac(tmp259, atslab_1) ; tmp275 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp257) ; tmp276 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp273) ; tmp278 = atspre_icompare (tmp275, tmp276) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (tmp278 != 0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp277 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn (tmp257, tmp273) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp278 != 1) { goto __ats_lab_70_0 ; } __ats_lab_69_1: /* tmp279 = */ prerr_loc_error2_0 (arg0) ; /* tmp280 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp281 = */ atspre_prerr_string (ATSstrcst(": the static application needs fewer arguments.")) ; /* tmp282 = */ atspre_prerr_newline () ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: __ats_lab_70_1: /* tmp283 = */ prerr_loc_error2_0 (arg0) ; /* tmp284 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp285 = */ atspre_prerr_string (ATSstrcst(": the static application needs more arguments.")) ; /* tmp286 = */ atspre_prerr_newline () ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp274, arg2, tmp277) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp287 ; arg3 = tmp258 ; goto __ats_lab_loop_44 ; // tail call break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp256 = arg2 ; break ; } while (0) ; return (tmp256) ; } /* end of [loop_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 16638(line=532, offs=4) -- 18471(line=577, offs=2) */ ATSstaticdec() ats_ptr_type s1exp_app_tr_up_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_s1exp_app_tr_up_43: tmp255 = loop_44 (arg0, arg1, arg2, arg3) ; return (tmp255) ; } /* end of [s1exp_app_tr_up_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 19167(line=601, offs=9) -- 19340(line=605, offs=25) */ ATSstaticdec() ats_ptr_type aux_46 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_aux_46: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp300 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp301 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp299, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; tmp302 = aux_46 (tmp300) ; tmp298 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp298, atslab_0, tmp301) ; ats_selptrset_mac(anairiats_sum_1, tmp298, atslab_1, tmp302) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: tmp298 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp298) ; } /* end of [aux_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 18525(line=581, offs=4) -- 20123(line=631, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_app_datconptr_tr_up_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_int_type, tmp304) ; ATSlocal (ats_int_type, tmp305) ; // ATSlocal_void (tmp306) ; ATSlocal (ats_bool_type, tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; ATSlocal (ats_bool_type, tmp315) ; // ATSlocal_void (tmp316) ; // ATSlocal_void (tmp317) ; // ATSlocal_void (tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; __ats_lab_s1exp_app_datconptr_tr_up_45: do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_72_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (tmp291 != (ats_sum_ptr_type)0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp289 = tmp290 ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (tmp291 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: /* tmp292 = */ prerr_loc_error2_0 (arg0) ; /* tmp293 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_datconptr_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp294 = */ atspre_prerr_string (ATSstrcst(": the type constructor [")) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp296 = */ atspre_prerr_string (ATSstrcst("] is overly applied.")) ; /* tmp297 = */ atspre_prerr_newline () ; /* tmp289 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp289 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp303 = aux_46 (tmp289) ; tmp304 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp303) ; tmp305 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full (arg1) ; tmp307 = atspre_gt_int_int (tmp304, tmp305) ; if (tmp307) { /* tmp308 = */ prerr_loc_error2_0 (arg0) ; /* tmp309 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_datcon_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp310 = */ atspre_prerr_string (ATSstrcst(": the type constructor [")) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp312 = */ atspre_prerr_string (ATSstrcst("] expects fewer arguments.")) ; /* tmp313 = */ atspre_prerr_newline () ; /* tmp306 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp315 = atspre_lt_int_int (tmp304, tmp305) ; if (tmp315) { /* tmp316 = */ prerr_loc_error2_0 (arg0) ; /* tmp317 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_datcon_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp318 = */ atspre_prerr_string (ATSstrcst(": the type constructor [")) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp320 = */ atspre_prerr_string (ATSstrcst("] expects more arguments.")) ; /* tmp321 = */ atspre_prerr_newline () ; /* tmp314 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp288 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr (arg1, tmp303) ; return (tmp288) ; } /* end of [s1exp_app_datconptr_tr_up_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 20284(line=638, offs=6) -- 20596(line=646, offs=6) */ ATSstaticdec() ats_ptr_type err_48 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; __ats_lab_err_48: /* tmp324 = */ prerr_loc_error2_0 (arg0) ; /* tmp325 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_app_datcon_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp326 = */ atspre_prerr_string (ATSstrcst(": the type constructor [")) ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp328 = */ atspre_prerr_string (ATSstrcst("_t0ype] is overly applied.")) ; /* tmp329 = */ atspre_prerr_newline () ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp323) ; } /* end of [err_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 20184(line=635, offs=4) -- 20909(line=656, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_app_datcontyp_tr_up_47 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; __ats_lab_s1exp_app_datcontyp_tr_up_47: do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_78_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp332 != (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp330 = tmp331 ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: __ats_lab_80_1: tmp330 = err_48 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_81_1: tmp330 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp333 = s1explst_tr_dn_viewt0ype_38 (tmp330) ; tmp322 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp (arg1, tmp333) ; return (tmp322) ; } /* end of [s1exp_app_datcontyp_tr_up_47] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 20974(line=660, offs=5) -- 22426(line=703, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_qid_app_tr_up_49 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; // ATSlocal_void (tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; // ATSlocal_void (tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; __ats_lab_s1exp_qid_app_tr_up_49: do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)arg4)->tag != 0) { goto __ats_lab_85_0 ; } __ats_lab_82_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explstlst_tr_up (arg5) ; tmp337 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_select_s2explstlst (tmp335, tmp336) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (tmp337 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_1, tmp337, atslab_0) ; /* tmp339 = */ stacstuseloc_posmark_3 (arg1, tmp338) ; tmp340 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp338) ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_wind (tmp340, tmp336) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: /* tmp341 = */ prerr_loc_error2_0 (arg0) ; /* tmp342 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_qid_app_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp343 = */ atspre_prerr_string (ATSstrcst(": none of the static constants referred to by [")) ; /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg2) ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg3) ; /* tmp346 = */ atspre_prerr_string (ATSstrcst("] is applicable.")) ; /* tmp347 = */ atspre_prerr_newline () ; /* tmp334 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)arg4)->tag != 5) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev (arg1, tmp348) ; tmp350 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp348) ; tmp334 = s1exp_app_tr_up_43 (arg0, arg1, tmp350, arg5) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)arg4)->tag != 1) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp334 = s1exp_app_datconptr_tr_up_45 (arg0, tmp351, arg5) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)arg4)->tag != 2) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp352 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp334 = s1exp_app_datcontyp_tr_up_47 (arg0, tmp352, arg5) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: __ats_lab_88_1: /* tmp353 = */ prerr_loc_interror_2 (arg1) ; /* tmp354 = */ atspre_prerr_string (ATSstrcst(": s1exp_qid_app_tr_up: not implemented yet: s2i = ")) ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item (arg4) ; /* tmp356 = */ atspre_prerr_newline () ; /* tmp334 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp334) ; } /* end of [s1exp_qid_app_tr_up_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 22748(line=718, offs=13) -- 23121(line=726, offs=35) */ ATSstaticdec() ats_ptr_type loop_51 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_bool_type, tmp366) ; __ats_lab_loop_51: do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp363 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp364 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp365 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp363) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_fun (tmp365) ; if (tmp366) { arg0 = tmp364 ; arg1 = arg1 ; goto __ats_lab_loop_51 ; // tail call } else { tmp362 = tmp363 ; } /* end of [if] */ break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp362 = arg1 ; break ; } while (0) ; return (tmp362) ; } /* end of [loop_51] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 22484(line=707, offs=4) -- 24540(line=766, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_qid_tr_up_50 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp367) ; // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_bool_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; // ATSlocal_void (tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; // ATSlocal_void (tmp384) ; // ATSlocal_void (tmp385) ; // ATSlocal_void (tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; __ats_lab_s1exp_qid_tr_up_50: tmp358 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (arg1, arg2) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (tmp358 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_89_1: tmp359 = ats_caselptrlab_mac(anairiats_sum_5, tmp358, atslab_0) ; ATS_FREE(tmp358) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp359)->tag != 0) { goto __ats_lab_97_0 ; } __ats_lab_90_1: tmp360 = ats_caselptrlab_mac(anairiats_sum_3, tmp359, atslab_0) ; do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (tmp360 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_91_1: tmp361 = ats_caselptrlab_mac(anairiats_sum_1, tmp360, atslab_0) ; tmp367 = loop_51 (tmp360, tmp361) ; /* tmp368 = */ stacstuseloc_posmark_3 (arg0, tmp367) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp367) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp367) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp369)->tag != 1) { goto __ats_lab_95_0 ; } tmp371 = ats_caselptrlab_mac(anairiats_sum_4, tmp369, atslab_0) ; if (tmp371 != (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp372 = ats_caselptrlab_mac(anairiats_sum_4, tmp369, atslab_1) ; tmp373 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat (tmp372) ; if (!tmp373) { goto __ats_lab_95_1 ; } tmp374 = (ats_sum_ptr_type)0 ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp372, tmp370, tmp374) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp357 = tmp370 ; break ; } while (0) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (tmp360 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: /* tmp375 = */ prerr_interror_1 () ; /* tmp376 = */ atspre_prerr_string (ATSstrcst(": s1exp_qid_tr_up: Some: S2ITEMcst: S2CSTLSTnil")) ; /* tmp377 = */ atspre_prerr_newline () ; /* tmp357 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp359)->tag != 3) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp378 = ats_caselptrlab_mac(anairiats_sum_3, tmp359, atslab_0) ; tmp379 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp (arg0, tmp378) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (tmp379) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp359)->tag != 5) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp380 = ats_caselptrlab_mac(anairiats_sum_3, tmp359, atslab_0) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__s2var_check_tmplev (arg0, tmp380) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp380) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: /* tmp382 = */ prerr_loc_interror_2 (arg0) ; /* tmp383 = */ atspre_prerr_string (ATSstrcst(": s1exp_qid_tr_up: s2i = ")) ; /* tmp384 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item (tmp359) ; /* tmp385 = */ atspre_prerr_newline () ; /* tmp357 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (tmp358 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: /* tmp386 = */ prerr_loc_error2_0 (arg0) ; /* tmp387 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_qid_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp388 = */ atspre_prerr_string (ATSstrcst(": the static identifier [")) ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp391 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp392 = */ atspre_prerr_newline () ; /* tmp357 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp357) ; } /* end of [s1exp_qid_tr_up_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 24594(line=770, offs=4) -- 24817(line=777, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_invar_tr_up_52 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_bool_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; __ats_lab_s1exp_invar_tr_up_52: tmp395 = atspre_eq_int_int (arg0, 0) ; if (tmp395) { tmp394 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } else { tmp394 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ tmp396 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg1, tmp394) ; tmp393 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg (arg0, tmp396) ; return (tmp393) ; } /* end of [s1exp_invar_tr_up_52] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 24873(line=781, offs=4) -- 25437(line=797, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_read_tr_up_53 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; // ATSlocal_void (tmp401) ; ATSlocal (ats_bool_type, tmp402) ; // ATSlocal_void (tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; // ATSlocal_void (tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; // ATSlocal_void (tmp410) ; __ats_lab_s1exp_read_tr_up_53: tmp398 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_view (arg0) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg1) ; tmp400 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp399), atslab_s2exp_srt) ; tmp402 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (tmp400) ; if (tmp402) { /* empty */ } else { tmp404 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_s1exp_loc) ; /* tmp403 = */ prerr_loc_error2_0 (tmp404) ; /* tmp405 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_read_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp406 = */ atspre_prerr_string (ATSstrcst(": the static expression needs to be impredicative")) ; /* tmp407 = */ atspre_prerr_string (ATSstrcst(" but is assigned the sort [")) ; /* tmp408 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp400) ; /* tmp409 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp410 = */ atspre_prerr_newline () ; /* tmp401 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp397 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize (tmp398, tmp399) ; return (tmp397) ; } /* end of [s1exp_read_tr_up_53] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 25492(line=801, offs=4) -- 26064(line=820, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_top_tr_up_54 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; // ATSlocal_void (tmp415) ; ATSlocal (ats_bool_type, tmp416) ; // ATSlocal_void (tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; __ats_lab_s1exp_top_tr_up_54: tmp412 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg1) ; tmp413 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp412), atslab_s2exp_srt) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun (tmp413) ; tmp416 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (tmp414) ; if (tmp416) { /* empty */ } else { tmp418 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_s1exp_loc) ; /* tmp417 = */ prerr_loc_error2_0 (tmp418) ; /* tmp419 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_top_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp420 = */ atspre_prerr_string (ATSstrcst(": the static expression needs to be impredicative")) ; /* tmp421 = */ atspre_prerr_string (ATSstrcst(" but is assigned the sort [")) ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp413) ; /* tmp423 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp424 = */ atspre_prerr_newline () ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp411 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (arg0, tmp412) ; return (tmp411) ; } /* end of [s1exp_top_tr_up_54] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 26143(line=826, offs=3) -- 27163(line=856, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_int_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_int_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; // ATSlocal_void (tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up: tmp426 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_node) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp426)->tag != 8) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp427 = ats_caselptrlab_mac(anairiats_sum_15, tmp426, atslab_0) ; tmp428 = ats_caselptrlab_mac(anairiats_sum_15, tmp426, atslab_1) ; tmp429 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp429)->tag = 1 ; ats_selptrset_mac(anairiats_sum_16, tmp429, atslab_0, tmp427) ; ats_selptrset_mac(anairiats_sum_16, tmp429, atslab_1, tmp428) ; ats_selptrset_mac(anairiats_sum_16, tmp429, atslab_2, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp429 ; tmp425 = s1exp_invar_tr_up_52 (tmp427, tmp428) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp426)->tag != 14) { goto __ats_lab_105_0 ; } __ats_lab_102_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_4, tmp426, atslab_0) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_4, tmp426, atslab_1) ; tmp432 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp430), atslab_s1exp_node) ; do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp432)->tag != 8) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp433 = ats_caselptrlab_mac(anairiats_sum_15, tmp432, atslab_0) ; tmp434 = ats_caselptrlab_mac(anairiats_sum_15, tmp432, atslab_1) ; tmp435 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp435)->tag = 1 ; ats_selptrset_mac(anairiats_sum_16, tmp435, atslab_0, tmp433) ; ats_selptrset_mac(anairiats_sum_16, tmp435, atslab_1, tmp431) ; ats_selptrset_mac(anairiats_sum_16, tmp435, atslab_2, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp435 ; tmp425 = s1exp_invar_tr_up_52 (tmp433, tmp434) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: __ats_lab_104_1: tmp437 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp430), atslab_s1exp_loc) ; /* tmp436 = */ prerr_loc_error2_0 (tmp437) ; /* tmp438 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_arg_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp439 = */ atspre_prerr_string (ATSstrcst(": a refval type must begin with !(call-by-value) or &(call-by-reference)")) ; /* tmp440 = */ atspre_prerr_newline () ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: __ats_lab_105_1: tmp441 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp441)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp441, atslab_0, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp441 ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg0) ; break ; } while (0) ; return (tmp425) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 27235(line=860, offs=3) -- 27701(line=873, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_dn_impredicative (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_bool_type, tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_dn_impredicative: tmp443 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up (arg0, arg1) ; tmp444 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp443), atslab_s2exp_srt) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (tmp444) ; if (tmp445) { tmp442 = tmp443 ; } else { tmp447 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp446 = */ prerr_loc_error2_0 (tmp447) ; /* tmp448 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_arg_tr_dn_impredicative"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp449 = */ atspre_prerr_string (ATSstrcst(": the static expression needs to be impredicative")) ; /* tmp450 = */ atspre_prerr_string (ATSstrcst(" but is assigned the sort [")) ; /* tmp451 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp444) ; /* tmp452 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp453 = */ atspre_prerr_newline () ; /* tmp442 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return (tmp442) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_dn_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 27839(line=881, offs=7) -- 28374(line=897, offs=6) */ ATSstaticdec() ats_ptr_type auxwth_58 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_int_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_bool_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; __ats_lab_auxwth_58: do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_0) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_1) ; tmp458 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; tmp460 = atspre_eq_int_int (tmp456, 0) ; if (tmp460) { tmp459 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } else { tmp459 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ tmp461 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp457, tmp459) ; tmp462 = auxwth_58 (tmp458) ; tmp455 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp455)->tag = 1 ; ats_selptrset_mac(anairiats_sum_16, tmp455, atslab_0, tmp456) ; ats_selptrset_mac(anairiats_sum_16, tmp455, atslab_1, tmp461) ; ats_selptrset_mac(anairiats_sum_16, tmp455, atslab_2, tmp462) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp463 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp464 = auxwth_58 (tmp463) ; tmp455 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp455)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp455, atslab_0, tmp464) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_108_1: tmp455 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; break ; } while (0) ; return (tmp455) ; } /* end of [auxwth_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 28402(line=899, offs=7) -- 28986(line=916, offs=10) */ ATSstaticdec() ats_ptr_type auxres_59 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_int_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; // ATSlocal_void (tmp470) ; // ATSlocal_void (tmp471) ; ATSlocal (anairiats_rec_0, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; // ATSlocal_void (tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; __ats_lab_auxres_59: tmp466 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_node) ; do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp466)->tag != 4) { goto __ats_lab_110_0 ; } tmp467 = ats_caselptrlab_mac(anairiats_sum_16, tmp466, atslab_0) ; if (tmp467 != 1) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp468 = ats_caselptrlab_mac(anairiats_sum_16, tmp466, atslab_1) ; tmp469 = ats_caselptrlab_mac(anairiats_sum_16, tmp466, atslab_2) ; /* tmp470 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp471 = ats_selsin_mac(tmp470, atslab_1) */ ; tmp472 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp468) ; tmp473 = ats_select_mac(tmp472, atslab_0) ; tmp474 = ats_select_mac(tmp472, atslab_1) ; tmp475 = auxres_59 (tmp469, arg1) ; /* tmp476 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp465 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (tmp473, tmp474, tmp475) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: __ats_lab_110_1: tmp477 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (arg0) ; tmp478 = auxwth_58 (arg1) ; tmp465 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth (tmp477, tmp478) ; break ; } while (0) ; return (tmp465) ; } /* end of [auxres_59] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 27808(line=879, offs=3) -- 29156(line=923, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_bool_type, tmp479) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative: tmp479 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none (arg1) ; if (tmp479) { tmp454 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (arg0) ; } else { tmp454 = auxres_59 (arg0, arg1) ; } /* end of [if] */ return (tmp454) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 30362(line=957, offs=9) -- 31969(line=995, offs=25) */ ATSstaticdec() ats_ptr_type aux_61 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_int_type, tmp513) ; ATSlocal (ats_int_type, tmp514) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_bool_type, tmp518) ; ATSlocal (ats_bool_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; // ATSlocal_void (tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; // ATSlocal_void (tmp524) ; // ATSlocal_void (tmp525) ; // ATSlocal_void (tmp526) ; ATSlocal (ats_bool_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; // ATSlocal_void (tmp535) ; // ATSlocal_void (tmp536) ; __ats_lab_aux_61: do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_117_1: tmp509 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp510 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp511 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_arg_tr_up (tmp509, arg1) ; tmp512 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp511), atslab_s2exp_srt) ; /* ats_int_type tmp513 ; */ tmp513 = 0 ; /* ats_int_type tmp514 ; */ tmp514 = 0 ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (((ats_sum_ptr_type)tmp512)->tag != 0) { goto __ats_lab_121_0 ; } __ats_lab_118_1: tmp516 = ats_caselptrlab_mac(anairiats_sum_3, tmp512, atslab_0) ; do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)tmp516)->tag != 1) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp517 = ats_caselptrlab_mac(anairiats_sum_17, tmp516, atslab_0) ; tmp513 = 1 ; tmp518 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp517, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; if (tmp518) { tmp514 = 1 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: __ats_lab_120_1: break ; } while (0) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: break ; } while (0) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: __ats_lab_122_1: tmp519 = atspre_gt_int_int (tmp514, 0) ; if (!tmp519) { goto __ats_lab_125_1 ; } do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (tmp510 != (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp520 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg (tmp511) ; tmp521 = (ats_sum_ptr_type)0 ; tmp508 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp508, atslab_0, tmp520) ; ats_selptrset_mac(anairiats_sum_1, tmp508, atslab_1, tmp521) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: // if (tmp510 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_124_1: tmp523 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp509), atslab_s1exp_loc) ; /* tmp522 = */ prerr_loc_error2_0 (tmp523) ; /* tmp524 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_arrow_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp525 = */ atspre_prerr_string (ATSstrcst(": this static expression must be the last argument.")) ; /* tmp526 = */ atspre_prerr_newline () ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: __ats_lab_125_1: tmp527 = atspre_gt_int_int (tmp513, 0) ; if (!tmp527) { goto __ats_lab_126_1 ; } tmp528 = aux_61 (tmp510, arg1) ; tmp508 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp508, atslab_0, tmp511) ; ats_selptrset_mac(anairiats_sum_1, tmp508, atslab_1, tmp528) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: tmp530 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp509), atslab_s1exp_loc) ; /* tmp529 = */ prerr_loc_error2_0 (tmp530) ; /* tmp531 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_arrow_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp532 = */ atspre_prerr_string (ATSstrcst(": the static expression needs to be impredicative")) ; /* tmp533 = */ atspre_prerr_string (ATSstrcst(" but is assigned the sort [")) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp512) ; /* tmp535 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp536 = */ atspre_prerr_newline () ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: tmp508 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp508) ; } /* end of [aux_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 29224(line=927, offs=4) -- 32675(line=1015, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_arrow_tr_up_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2, ats_bool_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; // ATSlocal_void (tmp487) ; ATSlocal (anairiats_rec_0, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; // ATSlocal_void (tmp493) ; // ATSlocal_void (tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_int_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_int_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_bool_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_int_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; __ats_lab_s1exp_arrow_tr_up_60: do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_112_0 ; } tmp482 = ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_1) ; if (tmp482 != (ats_sum_ptr_type)0) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_0) ; tmp481 = tmp483 ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: /* tmp484 = */ prerr_loc_error2_0 (arg0) ; /* tmp485 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_arrow_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp486 = */ atspre_prerr_string (ATSstrcst(": illegal static application.")) ; /* tmp487 = */ atspre_prerr_newline () ; /* tmp481 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (tmp481 == (ats_sum_ptr_type)0) { goto __ats_lab_114_0 ; } tmp489 = ats_caselptrlab_mac(anairiats_sum_1, tmp481, atslab_1) ; if (tmp489 == (ats_sum_ptr_type)0) { goto __ats_lab_114_0 ; } tmp490 = ats_caselptrlab_mac(anairiats_sum_1, tmp489, atslab_1) ; if (tmp490 != (ats_sum_ptr_type)0) { goto __ats_lab_114_0 ; } __ats_lab_113_1: tmp491 = ats_caselptrlab_mac(anairiats_sum_1, tmp481, atslab_0) ; tmp492 = ats_caselptrlab_mac(anairiats_sum_1, tmp489, atslab_0) ; tmp488.atslab_0 = tmp491 ; tmp488.atslab_1 = tmp492 ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: /* tmp493 = */ prerr_loc_interror_2 (arg0) ; /* tmp494 = */ atspre_prerr_string (ATSstrcst(": s1exp_arrow_tr_up: s1es = ")) ; /* tmp495 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1explst (tmp481) ; /* tmp496 = */ atspre_prerr_newline () ; /* tmp488 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp497 = ats_select_mac(tmp488, atslab_0) ; tmp498 = ats_select_mac(tmp488, atslab_1) ; /* ats_int_type tmp499 ; */ tmp499 = 0 ; /* ats_ptr_type tmp500 ; */ tmp500 = (ats_sum_ptr_type)0 ; tmp502 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp497), atslab_s1exp_node) ; do { /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp502)->tag != 10) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_15, tmp502, atslab_0) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_15, tmp502, atslab_1) ; tmp499 = tmp503 ; tmp500 = tmp504 ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: __ats_lab_116_1: tmp506 = (ats_sum_ptr_type)0 ; tmp505 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp505, atslab_0, tmp497) ; ats_selptrset_mac(anairiats_sum_1, tmp505, atslab_1, tmp506) ; tmp500 = tmp505 ; break ; } while (0) ; /* ats_ptr_type tmp507 ; */ tmp507 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; tmp537 = aux_61 (tmp500, (&tmp507)) ; tmp538 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse (tmp507) ; tmp507 = tmp538 ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_res_tr_dn_impredicative (tmp498, tmp507) ; tmp540 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp539), atslab_s2exp_srt) ; if (arg3) { tmp541 = arg3 ; } else { tmp541 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp540) ; } /* end of [if] */ do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp543 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp542 = tmp543 ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp542 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp544 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc (arg0, tmp541, arg2, tmp542) ; if (arg2) { tmp545 = 1 ; } else { tmp545 = 0 ; } /* end of [if] */ do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (arg4 != (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_130_1: if (tmp541) { tmp546 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; } else { tmp546 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; } /* end of [if] */ break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (arg4 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp547 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_0) ; tmp546 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__effcst_tr (tmp547) ; break ; } while (0) ; tmp480 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp544, tmp542, tmp545, tmp546, tmp499, tmp537, tmp539) ; return (tmp480) ; } /* end of [s1exp_arrow_tr_up_60] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 32732(line=1019, offs=5) -- 34138(line=1057, offs=4) */ ATSstaticdec() ats_ptr_type s1rtext_tr_62 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; // ATSlocal_void (tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; // ATSlocal_void (tmp561) ; // ATSlocal_void (tmp562) ; // ATSlocal_void (tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; // ATSlocal_void (tmp573) ; // ATSlocal_void (tmp574) ; // ATSlocal_void (tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; // ATSlocal_void (tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; __ats_lab_s1rtext_tr_62: tmp549 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s1rtext_node) ; do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp549)->tag != 0) { goto __ats_lab_137_0 ; } __ats_lab_132_1: tmp550 = ats_caselptrlab_mac(anairiats_sum_3, tmp549, atslab_0) ; tmp551 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp550), atslab_s1rt_node) ; do { /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp551)->tag != 2) { goto __ats_lab_136_0 ; } __ats_lab_133_1: tmp552 = ats_caselptrlab_mac(anairiats_sum_4, tmp551, atslab_0) ; tmp553 = ats_caselptrlab_mac(anairiats_sum_4, tmp551, atslab_1) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_find_qua (tmp552, tmp553) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (tmp554 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp555 = ats_caselptrlab_mac(anairiats_sum_5, tmp554, atslab_0) ; ATS_FREE(tmp554) ; tmp548 = tmp555 ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (tmp554 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: tmp557 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp550), atslab_s1rt_loc) ; /* tmp556 = */ prerr_loc_error2_0 (tmp557) ; /* tmp558 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1rtext_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp559 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp560 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq (tmp552) ; /* tmp561 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp553) ; /* tmp562 = */ atspre_prerr_string (ATSstrcst("] refers to an unrecognized sort.")) ; /* tmp563 = */ atspre_prerr_newline () ; /* tmp548 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: __ats_lab_136_1: tmp564 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp550) ; tmp548 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp548)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp548, atslab_0, tmp564) ; break ; } while (0) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (((ats_sum_ptr_type)tmp549)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp565 = ats_caselptrlab_mac(anairiats_sum_19, tmp549, atslab_0) ; tmp566 = ats_caselptrlab_mac(anairiats_sum_19, tmp549, atslab_1) ; tmp567 = ats_caselptrlab_mac(anairiats_sum_19, tmp549, atslab_2) ; tmp568 = s1rtext_tr_62 (tmp566) ; do { /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp568)->tag != 0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_3, tmp568, atslab_0) ; tmp569 = tmp570 ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (((ats_sum_ptr_type)tmp568)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: tmp571 = ats_caselptrlab_mac(anairiats_sum_19, tmp568, atslab_1) ; tmp569 = tmp571 ; break ; } while (0) ; tmp572 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp565, tmp569) ; /* tmp573 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp574 = ats_selsin_mac(tmp573, atslab_1) */ ; /* tmp575 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp572) ; tmp576 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_bool (tmp567) ; /* tmp577 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp568)->tag != 0) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp578 = tmp576 ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: // if (((ats_sum_ptr_type)tmp568)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_141_1: tmp579 = ats_caselptrlab_mac(anairiats_sum_19, tmp568, atslab_0) ; tmp580 = ats_caselptrlab_mac(anairiats_sum_19, tmp568, atslab_2) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_alpha (tmp579, tmp572, tmp580) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp576, tmp581) ; break ; } while (0) ; tmp548 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ((ats_sum_ptr_type)tmp548)->tag = 1 ; ats_selptrset_mac(anairiats_sum_19, tmp548, atslab_0, tmp572) ; ats_selptrset_mac(anairiats_sum_19, tmp548, atslab_1, tmp569) ; ats_selptrset_mac(anairiats_sum_19, tmp548, atslab_2, tmp578) ; break ; } while (0) ; return (tmp548) ; } /* end of [s1rtext_tr_62] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 34614(line=1075, offs=15) -- 34963(line=1083, offs=27) */ ATSstaticdec() ats_void_type aux_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; // ATSlocal_void (tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; __ats_lab_aux_65: do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp595 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp596 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp598 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp595), atslab_i0de_sym) ; tmp597 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp598, arg0) ; /* tmp599 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp597) ; tmp600 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp600, atslab_0, tmp597) ; ats_selptrset_mac(anairiats_sum_1, tmp600, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp600 ; arg0 = arg0 ; arg1 = tmp596 ; arg2 = arg2 ; goto __ats_lab_aux_65 ; // tail call break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_147_1: break ; } while (0) ; return /* (tmp594) */ ; } /* end of [aux_65] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 35134(line=1089, offs=15) -- 35485(line=1097, offs=27) */ ATSstaticdec() ats_void_type aux1_66 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; __ats_lab_aux1_66: do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp606 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp607 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp608 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_alpha (env0, arg1, tmp606) ; tmp609 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp609, atslab_0, tmp608) ; ats_selptrset_mac(anairiats_sum_1, tmp609, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp609 ; arg0 = tmp607 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_aux1_66 ; // tail call break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_150_1: break ; } while (0) ; return /* (tmp605) */ ; } /* end of [aux1_66] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux1_66_closure_type ; ats_void_type aux1_66_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux1_66 (((aux1_66_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux1_66_closure_init (aux1_66_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux1_66_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux1_66_closure_make (ats_ptr_type env0) { aux1_66_closure_type *p_clo = ATS_MALLOC(sizeof(aux1_66_closure_type)) ; aux1_66_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 35530(line=1100, offs=15) -- 35966(line=1110, offs=27) */ ATSstaticdec() ats_void_type aux2_67 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; // ATSlocal_void (tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; // ATSlocal_void (tmp617) ; __ats_lab_aux2_67: do { /* branch: __ats_lab_151 */ __ats_lab_151_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp611 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp612 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp614 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp611), atslab_i0de_sym) ; tmp613 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp614, env1) ; /* tmp615 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp613) ; tmp616 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp616, atslab_0, tmp613) ; ats_selptrset_mac(anairiats_sum_1, tmp616, atslab_1, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp616 ; /* tmp617 = */ aux1_66 (env0, env2, tmp613, arg2) ; arg0 = tmp612 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_aux2_67 ; // tail call break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_152_1: break ; } while (0) ; return /* (tmp610) */ ; } /* end of [aux2_67] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux2_67_closure_type ; ats_void_type aux2_67_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { aux2_67 (((aux2_67_closure_type*)cloptr)->closure_env_0, ((aux2_67_closure_type*)cloptr)->closure_env_1, ((aux2_67_closure_type*)cloptr)->closure_env_2, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux2_67_closure_init (aux2_67_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux2_67_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux2_67_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux2_67_closure_type *p_clo = ATS_MALLOC(sizeof(aux2_67_closure_type)) ; aux2_67_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 34226(line=1063, offs=5) -- 36173(line=1119, offs=4) */ ATSstaticdec() ats_void_type loop_64 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; // ATSlocal_void (tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; // ATSlocal_void (tmp618) ; __ats_lab_loop_64: do { /* branch: __ats_lab_142 */ __ats_lab_142_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_142_1: tmp584 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp585 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp586 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp584), atslab_s1qua_node) ; do { /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp586)->tag != 0) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp587 = ats_caselptrlab_mac(anairiats_sum_3, tmp586, atslab_0) ; tmp588 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_bool (tmp587) ; tmp589 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp589, atslab_0, tmp588) ; ats_selptrset_mac(anairiats_sum_1, tmp589, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp589 ; arg0 = tmp585 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_loop_64 ; // tail call break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: // if (((ats_sum_ptr_type)tmp586)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_144_1: tmp590 = ats_caselptrlab_mac(anairiats_sum_4, tmp586, atslab_0) ; tmp591 = ats_caselptrlab_mac(anairiats_sum_4, tmp586, atslab_1) ; tmp592 = s1rtext_tr_62 (tmp591) ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp592)->tag != 0) { goto __ats_lab_148_0 ; } __ats_lab_145_1: tmp593 = ats_caselptrlab_mac(anairiats_sum_3, tmp592, atslab_0) ; /* tmp601 = */ aux_65 (tmp593, tmp590, arg1) ; arg0 = tmp585 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_loop_64 ; // tail call break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: // if (((ats_sum_ptr_type)tmp592)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_148_1: tmp602 = ats_caselptrlab_mac(anairiats_sum_19, tmp592, atslab_0) ; tmp603 = ats_caselptrlab_mac(anairiats_sum_19, tmp592, atslab_1) ; tmp604 = ats_caselptrlab_mac(anairiats_sum_19, tmp592, atslab_2) ; /* tmp618 = */ aux2_67 (tmp602, tmp603, tmp604, tmp590, arg1, arg2) ; arg0 = tmp585 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_loop_64 ; // tail call break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: break ; } while (0) ; return /* (tmp583) */ ; } /* end of [loop_64] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 34206(line=1061, offs=23) -- 36372(line=1128, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp582) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; // ATSlocal_void (tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr: /* ats_ptr_type tmp619 ; */ tmp619 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp620 ; */ tmp620 = (ats_sum_ptr_type)0 ; /* tmp621 = */ loop_64 (arg0, (&tmp619), (&tmp620)) ; tmp622 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp619) ; tmp623 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp620) ; tmp582.atslab_0 = tmp622 ; tmp582.atslab_1 = tmp623 ; return (tmp582) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 36425(line=1132, offs=3) -- 36614(line=1137, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; ATSlocal (anairiats_rec_0, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr: do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp625 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp626 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp627 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp625) ; tmp628 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (tmp626) ; tmp624 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp624, atslab_0, tmp627) ; ats_selptrset_mac(anairiats_sum_21, tmp624, atslab_1, tmp628) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_155_1: tmp624 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp624) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 36668(line=1141, offs=5) -- 37461(line=1164, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_app_unwind_69 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; __ats_lab_s1exp_app_unwind_69: tmp630 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_node) ; do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp630)->tag != 2) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp631 = ats_caselptrlab_mac(anairiats_sum_19, tmp630, atslab_0) ; tmp632 = ats_caselptrlab_mac(anairiats_sum_19, tmp630, atslab_2) ; tmp633 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp633, atslab_0, tmp632) ; ats_selptrset_mac(anairiats_sum_1, tmp633, atslab_1, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp633 ; arg0 = tmp631 ; arg1 = arg1 ; goto __ats_lab_s1exp_app_unwind_69 ; // tail call break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp630)->tag != 11) { goto __ats_lab_164_0 ; } __ats_lab_157_1: tmp634 = ats_caselptrlab_mac(anairiats_sum_4, tmp630, atslab_0) ; tmp635 = ats_caselptrlab_mac(anairiats_sum_4, tmp630, atslab_1) ; tmp636 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, tmp634), atslab_s0taq_node) ; do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp636)->tag != 0) { goto __ats_lab_163_0 ; } __ats_lab_158_1: tmp637 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find (tmp635) ; do { /* branch: __ats_lab_159 */ __ats_lab_159_0: if (tmp637 == (ats_sum_ptr_type)0) { goto __ats_lab_162_0 ; } __ats_lab_159_1: tmp638 = ats_caselptrlab_mac(anairiats_sum_5, tmp637, atslab_0) ; ATS_FREE(tmp637) ; do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp638)->tag != 3) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_3, tmp638, atslab_0) ; tmp641 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp640 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp (tmp641, tmp639) ; arg0 = tmp640 ; arg1 = arg1 ; goto __ats_lab_s1exp_app_unwind_69 ; // tail call break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: __ats_lab_161_1: tmp629 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: // if (tmp637 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_162_1: tmp629 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: __ats_lab_163_1: tmp629 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: __ats_lab_164_1: tmp629 = arg0 ; break ; } while (0) ; return (tmp629) ; } /* end of [s1exp_app_unwind_69] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 37516(line=1168, offs=4) -- 37605(line=1169, offs=70) */ ATSstaticdec() ats_ptr_type s2rtlst_of_s2varlst_70 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp642) ; __ats_lab_s2rtlst_of_s2varlst_70: tmp642 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) ; return (tmp642) ; } /* end of [s2rtlst_of_s2varlst_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 37671(line=1176, offs=5) -- 38271(line=1196, offs=4) */ ATSstaticdec() ats_ptr_type aux01_71 (ats_int_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_bool_type, tmp650) ; ATSlocal (ats_int_type, tmp651) ; ATSlocal (ats_bool_type, tmp653) ; ATSlocal (ats_bool_type, tmp654) ; ATSlocal (ats_bool_type, tmp655) ; ATSlocal (ats_int_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_int_type, tmp658) ; __ats_lab_aux01_71: do { /* branch: __ats_lab_165 */ __ats_lab_165_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp645 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp646 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (arg0) ; tmp647 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp644) ; tmp648 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp647), atslab_s2exp_srt) ; tmp650 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp648) ; if (tmp650) { tmp651 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp651 ; } else { /* empty */ } /* end of [if] */ tmp653 = atspre_gte_int_int (arg0, arg1) ; if (tmp653) { tmp655 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp648) ; tmp654 = atspre_neg_bool (tmp655) ; if (tmp654) { tmp656 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp656 ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp658 = atspre_add_int_int (arg0, 1) ; tmp657 = aux01_71 (tmp658, arg1, tmp645, arg3, arg4, arg5) ; tmp643 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp643, atslab_0, tmp646) ; ats_selptrset_mac(anairiats_sum_11, tmp643, atslab_1, tmp647) ; ats_selptrset_mac(anairiats_sum_11, tmp643, atslab_2, tmp657) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_166_1: tmp643 = arg5 ; break ; } while (0) ; return (tmp643) ; } /* end of [aux01_71] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 38295(line=1198, offs=5) -- 38637(line=1208, offs=4) */ ATSstaticdec() ats_ptr_type aux23_72 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_int_type, tmp665) ; __ats_lab_aux23_72: do { /* branch: __ats_lab_167 */ __ats_lab_167_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp660 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp661 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp662 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (arg1) ; tmp663 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp660, arg0) ; tmp665 = atspre_add_int_int (arg1, 1) ; tmp664 = aux23_72 (arg0, tmp665, tmp661, arg3) ; tmp659 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp659, atslab_0, tmp662) ; ats_selptrset_mac(anairiats_sum_11, tmp659, atslab_1, tmp663) ; ats_selptrset_mac(anairiats_sum_11, tmp659, atslab_2, tmp664) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_168_1: tmp659 = arg3 ; break ; } while (0) ; return (tmp659) ; } /* end of [aux23_72] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 38681(line=1212, offs=4) -- 39010(line=1221, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_list_tr_up_73 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_int_type, tmp667) ; ATSlocal (ats_int_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; ATSlocal (ats_ptr_type, tmp672) ; __ats_lab_s1exp_list_tr_up_73: /* ats_int_type tmp667 ; */ tmp667 = 0 ; /* ats_int_type tmp668 ; */ tmp668 = 0 ; tmp670 = (ats_sum_ptr_type)0 ; tmp669 = aux01_71 (0, arg1, arg2, (&tmp667), (&tmp668), tmp670) ; tmp671 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp667, tmp668, 0, arg1, tmp669) ; tmp672 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; tmp666 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp671, tmp672, arg1, tmp669) ; return (tmp666) ; } /* end of [s1exp_list_tr_up_73] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 39044(line=1223, offs=4) -- 40226(line=1253, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_tytup_tr_up_74 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_bool_type, tmp674) ; ATSlocal (ats_bool_type, tmp675) ; ATSlocal (ats_int_type, tmp676) ; ATSlocal (ats_int_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_int_type, tmp680) ; ATSlocal (ats_bool_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_bool_type, tmp684) ; ATSlocal (ats_bool_type, tmp685) ; ATSlocal (ats_bool_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_bool_type, tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_bool_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; // ATSlocal_void (tmp694) ; // ATSlocal_void (tmp695) ; // ATSlocal_void (tmp696) ; __ats_lab_s1exp_tytup_tr_up_74: do { /* branch: __ats_lab_169 */ __ats_lab_169_0: __ats_lab_169_1: tmp675 = atspre_lte_int_int (0, arg1) ; if (tmp675) { tmp674 = atspre_lte_int_int (arg1, 1) ; } else { tmp674 = ats_false_bool ; } /* end of [if] */ if (!tmp674) { goto __ats_lab_170_1 ; } /* ats_int_type tmp676 ; */ tmp676 = 0 ; /* ats_int_type tmp677 ; */ tmp677 = 0 ; tmp679 = (ats_sum_ptr_type)0 ; tmp678 = aux01_71 (0, 0, arg2, (&tmp676), (&tmp677), tmp679) ; tmp681 = atspre_gt_int_int (arg1, 0) ; if (tmp681) { tmp680 = 1 ; } else { tmp680 = 0 ; } /* end of [if] */ tmp682 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp676, tmp677, tmp680, 0, tmp678) ; tmp684 = atspre_gt_int_int (tmp680, 0) ; if (tmp684) { tmp683 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; } else { tmp683 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; } /* end of [if] */ tmp673 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp682, tmp683, 0, tmp678) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: __ats_lab_170_1: tmp686 = atspre_lte_int_int (2, arg1) ; if (tmp686) { tmp685 = atspre_lte_int_int (arg1, 3) ; } else { tmp685 = ats_false_bool ; } /* end of [if] */ if (!tmp685) { goto __ats_lab_171_1 ; } tmp688 = atspre_eq_int_int (arg1, 2) ; if (tmp688) { tmp687 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } else { tmp687 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ tmp690 = (ats_sum_ptr_type)0 ; tmp689 = aux23_72 (tmp687, 0, arg2, tmp690) ; tmp692 = atspre_eq_int_int (arg1, 2) ; if (tmp692) { tmp691 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp691 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } /* end of [if] */ tmp693 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; tmp673 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp691, tmp693, 0, tmp689) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: __ats_lab_171_1: /* tmp694 = */ prerr_loc_interror_2 (arg0) ; /* tmp695 = */ atspre_prerr_string (ATSstrcst(": s1exp_tytup_tr_up")) ; /* tmp696 = */ atspre_prerr_newline () ; /* tmp673 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp673) ; } /* end of [s1exp_tytup_tr_up_74] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 40261(line=1255, offs=4) -- 41691(line=1292, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_tytup2_tr_up_75 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_bool_type, tmp698) ; ATSlocal (ats_bool_type, tmp699) ; ATSlocal (ats_int_type, tmp700) ; ATSlocal (ats_int_type, tmp701) ; ATSlocal (ats_int_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_int_type, tmp706) ; ATSlocal (ats_bool_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_bool_type, tmp710) ; ATSlocal (ats_bool_type, tmp711) ; ATSlocal (ats_bool_type, tmp712) ; ATSlocal (ats_int_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_bool_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_bool_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_bool_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; // ATSlocal_void (tmp724) ; // ATSlocal_void (tmp725) ; // ATSlocal_void (tmp726) ; __ats_lab_s1exp_tytup2_tr_up_75: do { /* branch: __ats_lab_172 */ __ats_lab_172_0: __ats_lab_172_1: tmp699 = atspre_lte_int_int (0, arg1) ; if (tmp699) { tmp698 = atspre_lte_int_int (arg1, 1) ; } else { tmp698 = ats_false_bool ; } /* end of [if] */ if (!tmp698) { goto __ats_lab_173_1 ; } /* ats_int_type tmp700 ; */ tmp700 = 0 ; /* ats_int_type tmp701 ; */ tmp701 = 0 ; tmp702 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp703 = (ats_sum_ptr_type)0 ; tmp704 = aux01_71 (tmp702, tmp702, arg3, (&tmp700), (&tmp701), tmp703) ; tmp705 = aux01_71 (0, tmp702, arg2, (&tmp700), (&tmp701), tmp704) ; tmp707 = atspre_gt_int_int (arg1, 0) ; if (tmp707) { tmp706 = 1 ; } else { tmp706 = 0 ; } /* end of [if] */ tmp708 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp700, tmp701, tmp706, 0, tmp704) ; tmp710 = atspre_gt_int_int (tmp706, 0) ; if (tmp710) { tmp709 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; } else { tmp709 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; } /* end of [if] */ tmp697 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp708, tmp709, tmp702, tmp705) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: __ats_lab_173_1: tmp712 = atspre_lte_int_int (2, arg1) ; if (tmp712) { tmp711 = atspre_lte_int_int (arg1, 3) ; } else { tmp711 = ats_false_bool ; } /* end of [if] */ if (!tmp711) { goto __ats_lab_174_1 ; } tmp713 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp715 = atspre_eq_int_int (arg1, 2) ; if (tmp715) { tmp714 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } else { tmp714 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } /* end of [if] */ tmp717 = atspre_eq_int_int (arg1, 2) ; if (tmp717) { tmp716 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } else { tmp716 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ tmp719 = (ats_sum_ptr_type)0 ; tmp718 = aux23_72 (tmp716, tmp713, arg3, tmp719) ; tmp720 = aux23_72 (tmp714, 0, arg2, tmp718) ; tmp722 = atspre_eq_int_int (arg1, 2) ; if (tmp722) { tmp721 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp721 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } /* end of [if] */ tmp723 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; tmp697 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp721, tmp723, tmp713, tmp720) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: __ats_lab_174_1: /* tmp724 = */ prerr_loc_interror_2 (arg0) ; /* tmp725 = */ atspre_prerr_string (ATSstrcst(": s1exp_tytup2_tr_up")) ; /* tmp726 = */ atspre_prerr_newline () ; /* tmp697 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp697) ; } /* end of [s1exp_tytup2_tr_up_75] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 41779(line=1300, offs=5) -- 42268(line=1314, offs=4) */ ATSstaticdec() ats_ptr_type aux01_76 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; ATSlocal (ats_bool_type, tmp734) ; ATSlocal (ats_int_type, tmp735) ; ATSlocal (ats_bool_type, tmp737) ; ATSlocal (ats_bool_type, tmp738) ; ATSlocal (ats_int_type, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; __ats_lab_aux01_76: do { /* branch: __ats_lab_175 */ __ats_lab_175_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp728 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp729 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp730 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp731 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp729) ; tmp732 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp731), atslab_s2exp_srt) ; tmp734 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp732) ; if (tmp734) { tmp735 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp735 ; } else { /* empty */ } /* end of [if] */ tmp738 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp732) ; tmp737 = atspre_neg_bool (tmp738) ; if (tmp737) { tmp739 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp739 ; } else { /* empty */ } /* end of [if] */ tmp740 = aux01_76 (tmp730, arg1, arg2) ; tmp727 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp727, atslab_0, tmp728) ; ats_selptrset_mac(anairiats_sum_11, tmp727, atslab_1, tmp731) ; ats_selptrset_mac(anairiats_sum_11, tmp727, atslab_2, tmp740) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_176_1: tmp727 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp727) ; } /* end of [aux01_76] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 42292(line=1316, offs=5) -- 42605(line=1327, offs=4) */ ATSstaticdec() ats_ptr_type aux23_77 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; __ats_lab_aux23_77: do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp742 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp743 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp744 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp745 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp743, arg0) ; tmp746 = aux23_77 (arg0, tmp744) ; tmp741 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp741, atslab_0, tmp742) ; ats_selptrset_mac(anairiats_sum_11, tmp741, atslab_1, tmp745) ; ats_selptrset_mac(anairiats_sum_11, tmp741, atslab_2, tmp746) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_178_1: tmp741 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp741) ; } /* end of [aux23_77] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 43398(line=1360, offs=6) -- 43746(line=1369, offs=6) */ ATSstaticdec() ats_ptr_type err1_79 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp748) ; // ATSlocal_void (tmp749) ; // ATSlocal_void (tmp750) ; // ATSlocal_void (tmp751) ; // ATSlocal_void (tmp752) ; // ATSlocal_void (tmp753) ; // ATSlocal_void (tmp754) ; // ATSlocal_void (tmp755) ; __ats_lab_err1_79: /* tmp749 = */ prerr_loc_error2_0 (arg0) ; /* tmp750 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tmpid_tr: err1"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp751 = */ atspre_prerr_string (ATSstrcst(": the static identifier [")) ; /* tmp752 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp753 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp754 = */ atspre_prerr_string (ATSstrcst("] does not refer to a static constant")) ; /* tmp755 = */ atspre_prerr_newline () ; /* tmp748 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp748) ; } /* end of [err1_79] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 43772(line=1371, offs=6) -- 44095(line=1379, offs=6) */ ATSstaticdec() ats_ptr_type err2_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp756) ; // ATSlocal_void (tmp757) ; // ATSlocal_void (tmp758) ; // ATSlocal_void (tmp759) ; // ATSlocal_void (tmp760) ; // ATSlocal_void (tmp761) ; // ATSlocal_void (tmp762) ; // ATSlocal_void (tmp763) ; __ats_lab_err2_80: /* tmp757 = */ prerr_loc_error2_0 (arg0) ; /* tmp758 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tmpid_tr: err2"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp759 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp760 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp761 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp762 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp763 = */ atspre_prerr_newline () ; /* tmp756 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp756) ; } /* end of [err2_80] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 43141(line=1349, offs=4) -- 45263(line=1411, offs=2) */ ATSstaticdec() ats_ptr_type s1exp_tmpid_tr_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; // ATSlocal_void (tmp770) ; // ATSlocal_void (tmp771) ; // ATSlocal_void (tmp772) ; // ATSlocal_void (tmp773) ; // ATSlocal_void (tmp774) ; // ATSlocal_void (tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; // ATSlocal_void (tmp781) ; __ats_lab_s1exp_tmpid_tr_78: tmp764 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg1), atslab_d0ynq_loc) ; tmp766 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg1), atslab_d0ynq_node) ; do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp766)->tag != 0) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp765 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)tmp766)->tag != 1) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp767 = ats_caselptrlab_mac(anairiats_sum_3, tmp766, atslab_0) ; tmp765 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp765)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp765, atslab_0, tmp767) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp766)->tag != 3) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp768 = ats_caselptrlab_mac(anairiats_sum_3, tmp766, atslab_0) ; tmp765 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp765)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp765, atslab_0, tmp768) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp766)->tag != 4) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp769 = ats_caselptrlab_mac(anairiats_sum_3, tmp766, atslab_0) ; tmp765 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp765)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp765, atslab_0, tmp769) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: __ats_lab_183_1: /* tmp770 = */ prerr_loc_error2_0 (tmp764) ; /* tmp771 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tmpid_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp772 = */ atspre_prerr_string (ATSstrcst(": the static qualifier [")) ; /* tmp773 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (arg1) ; /* tmp774 = */ atspre_prerr_string (ATSstrcst("] is not supported.")) ; /* tmp775 = */ atspre_prerr_newline () ; /* tmp765 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp776 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__s0taq_make (tmp764, tmp765) ; tmp777 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (tmp776, arg2) ; do { /* branch: __ats_lab_184 */ __ats_lab_184_0: if (tmp777 == (ats_sum_ptr_type)0) { goto __ats_lab_189_0 ; } __ats_lab_184_1: tmp778 = ats_caselptrlab_mac(anairiats_sum_5, tmp777, atslab_0) ; ATS_FREE(tmp777) ; do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)tmp778)->tag != 0) { goto __ats_lab_188_0 ; } __ats_lab_185_1: tmp779 = ats_caselptrlab_mac(anairiats_sum_3, tmp778, atslab_0) ; do { /* branch: __ats_lab_186 */ __ats_lab_186_0: if (tmp779 == (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_186_1: tmp780 = ats_caselptrlab_mac(anairiats_sum_1, tmp779, atslab_0) ; /* tmp781 = */ stacstuseloc_posmark_3 (arg0, tmp780) ; tmp747 = tmp780 ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: // if (tmp779 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_187_1: tmp747 = err1_79 (arg0, tmp776, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: __ats_lab_188_1: tmp747 = err1_79 (arg0, tmp776, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: // if (tmp777 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_189_1: tmp747 = err2_80 (arg0, tmp776, arg2) ; break ; } while (0) ; return (tmp747) ; } /* end of [s1exp_tmpid_tr_78] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 45316(line=1415, offs=4) -- 46388(line=1446, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_tyrec_tr_up_81 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (ats_bool_type, tmp783) ; ATSlocal (ats_bool_type, tmp784) ; ATSlocal (ats_int_type, tmp785) ; ATSlocal (ats_int_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_int_type, tmp788) ; ATSlocal (ats_bool_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_bool_type, tmp792) ; ATSlocal (ats_bool_type, tmp793) ; ATSlocal (ats_bool_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_bool_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_bool_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; // ATSlocal_void (tmp801) ; // ATSlocal_void (tmp802) ; // ATSlocal_void (tmp803) ; __ats_lab_s1exp_tyrec_tr_up_81: do { /* branch: __ats_lab_190 */ __ats_lab_190_0: __ats_lab_190_1: tmp784 = atspre_lte_int_int (0, arg1) ; if (tmp784) { tmp783 = atspre_lte_int_int (arg1, 1) ; } else { tmp783 = ats_false_bool ; } /* end of [if] */ if (!tmp783) { goto __ats_lab_191_1 ; } /* ats_int_type tmp785 ; */ tmp785 = 0 ; /* ats_int_type tmp786 ; */ tmp786 = 0 ; tmp787 = aux01_76 (arg2, (&tmp785), (&tmp786)) ; tmp789 = atspre_gt_int_int (arg1, 0) ; if (tmp789) { tmp788 = 1 ; } else { tmp788 = 0 ; } /* end of [if] */ tmp790 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp785, tmp786, tmp788, 0, tmp787) ; tmp792 = atspre_gt_int_int (tmp788, 0) ; if (tmp792) { tmp791 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; } else { tmp791 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; } /* end of [if] */ tmp782 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp790, tmp791, 0, tmp787) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: __ats_lab_191_1: tmp794 = atspre_lte_int_int (2, arg1) ; if (tmp794) { tmp793 = atspre_lte_int_int (arg1, 3) ; } else { tmp793 = ats_false_bool ; } /* end of [if] */ if (!tmp793) { goto __ats_lab_192_1 ; } tmp796 = atspre_eq_int_int (arg1, 2) ; if (tmp796) { tmp795 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp795 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } /* end of [if] */ tmp798 = atspre_eq_int_int (arg1, 2) ; if (tmp798) { tmp797 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } else { tmp797 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ tmp799 = aux23_77 (tmp797, arg2) ; tmp800 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; tmp782 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp795, tmp800, 0, tmp799) ; break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: __ats_lab_192_1: /* tmp801 = */ prerr_loc_interror_2 (arg0) ; /* tmp802 = */ atspre_prerr_string (ATSstrcst(": s1exp_tyrec_tr_up")) ; /* tmp803 = */ atspre_prerr_newline () ; /* tmp782 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp782) ; } /* end of [s1exp_tyrec_tr_up_81] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 46423(line=1448, offs=4) -- 46784(line=1457, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_tyrec_ext_tr_up_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_int_type, tmp805) ; ATSlocal (ats_int_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; __ats_lab_s1exp_tyrec_ext_tr_up_82: /* ats_int_type tmp805 ; */ tmp805 = 0 ; /* ats_int_type tmp806 ; */ tmp806 = 0 ; tmp807 = aux01_76 (arg2, (&tmp805), (&tmp806)) ; tmp808 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp805, tmp806, 0, 0, tmp807) ; tmp809 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp809)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp809, atslab_0, arg1) ; tmp804 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp808, tmp809, 0, tmp807) ; return (tmp804) ; } /* end of [s1exp_tyrec_ext_tr_up_82] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 46823(line=1459, offs=4) -- 47183(line=1468, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_union_tr_up_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_int_type, tmp812) ; ATSlocal (ats_int_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (atsopt_count_type, tmp816) ; __ats_lab_s1exp_union_tr_up_83: tmp811 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_int (arg1) ; /* ats_int_type tmp812 ; */ tmp812 = 0 ; /* ats_int_type tmp813 ; */ tmp813 = 0 ; tmp814 = aux01_76 (arg2, (&tmp812), (&tmp813)) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed (tmp812, tmp813, 0) ; tmp816 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2exp_union_stamp_make () ; tmp810 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp815, tmp816, tmp811, tmp814) ; return (tmp810) ; } /* end of [s1exp_union_tr_up_83] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 47281(line=1475, offs=13) -- 53822(line=1657, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; // ATSlocal_void (tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; // ATSlocal_void (tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; // ATSlocal_void (tmp844) ; // ATSlocal_void (tmp845) ; // ATSlocal_void (tmp846) ; // ATSlocal_void (tmp847) ; // ATSlocal_void (tmp848) ; // ATSlocal_void (tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_int_type, tmp851) ; ATSlocal (ats_int_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_bool_type, tmp856) ; ATSlocal (ats_bool_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_char_type, tmp864) ; ATSlocal (ats_int_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_ptr_type, tmp867) ; // ATSlocal_void (tmp868) ; ATSlocal (ats_bool_type, tmp869) ; // ATSlocal_void (tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; // ATSlocal_void (tmp872) ; // ATSlocal_void (tmp873) ; // ATSlocal_void (tmp874) ; // ATSlocal_void (tmp875) ; ATSlocal (anairiats_rec_0, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; ATSlocal (ats_ptr_type, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; // ATSlocal_void (tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; // ATSlocal_void (tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; // ATSlocal_void (tmp886) ; // ATSlocal_void (tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; // ATSlocal_void (tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; // ATSlocal_void (tmp892) ; // ATSlocal_void (tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; // ATSlocal_void (tmp897) ; // ATSlocal_void (tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; ATSlocal (ats_ptr_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; // ATSlocal_void (tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_int_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_int_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; // ATSlocal_void (tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; // ATSlocal_void (tmp919) ; // ATSlocal_void (tmp920) ; ATSlocal (ats_ptr_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; ATSlocal (ats_int_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; ATSlocal (ats_int_type, tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; ATSlocal (ats_int_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; // ATSlocal_void (tmp942) ; // ATSlocal_void (tmp943) ; ATSlocal (anairiats_rec_0, tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_ptr_type, tmp947) ; // ATSlocal_void (tmp948) ; ATSlocal (ats_ptr_type, tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up: tmp818 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_node) ; do { /* branch: __ats_lab_193 */ __ats_lab_193_0: if (((ats_sum_ptr_type)tmp818)->tag != 0) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp819 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp820 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp821 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp820) ; tmp822 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp819, tmp821) ; /* tmp823 = */ atsopt_s2exp_set_srt (tmp822, tmp821) ; tmp817 = tmp822 ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp818)->tag != 1) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp824 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_any_tr_up_42 (tmp824) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp818)->tag != 2) { goto __ats_lab_203_0 ; } __ats_lab_195_1: tmp825 = ats_caselptrlab_mac(anairiats_sum_19, tmp818, atslab_0) ; tmp826 = ats_caselptrlab_mac(anairiats_sum_19, tmp818, atslab_2) ; /* ats_ptr_type tmp827 ; */ tmp827 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp827, atslab_0, tmp826) ; tmp828 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp827), atslab_1) ; tmp829 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp828) = tmp829 ; tmp830 = s1exp_app_unwind_69 (tmp825, (&tmp827)) ; tmp831 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp830), atslab_s1exp_node) ; do { /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp831)->tag != 11) { goto __ats_lab_201_0 ; } __ats_lab_196_1: tmp832 = ats_caselptrlab_mac(anairiats_sum_4, tmp831, atslab_0) ; tmp833 = ats_caselptrlab_mac(anairiats_sum_4, tmp831, atslab_1) ; tmp834 = staspecid_of_qid_8 (tmp832, tmp833) ; do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp834)->tag != 0) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp835 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp836 = (ats_sum_ptr_type)0 ; tmp837 = (ats_sum_ptr_type)0 ; tmp817 = s1exp_arrow_tr_up_60 (tmp835, tmp836, ats_false_bool, ats_false_bool, tmp837, tmp827) ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: // if (((ats_sum_ptr_type)tmp834)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_198_1: tmp838 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (tmp832, tmp833) ; do { /* branch: __ats_lab_199 */ __ats_lab_199_0: if (tmp838 == (ats_sum_ptr_type)0) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp839 = ats_caselptrlab_mac(anairiats_sum_5, tmp838, atslab_0) ; ATS_FREE(tmp838) ; tmp840 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp841 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp830), atslab_s1exp_loc) ; tmp817 = s1exp_qid_app_tr_up_49 (tmp840, tmp841, tmp832, tmp833, tmp839, tmp827) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: // if (tmp838 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_200_1: tmp843 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp825), atslab_s1exp_loc) ; /* tmp842 = */ prerr_loc_error2_0 (tmp843) ; /* tmp844 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tr_up"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp845 = */ atspre_prerr_string (ATSstrcst(": unrecognized static identifier [")) ; /* tmp846 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (tmp832) ; /* tmp847 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp833) ; /* tmp848 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp849 = */ atspre_prerr_newline () ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: if (((ats_sum_ptr_type)tmp831)->tag != 6) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp850 = ats_caselptrlab_mac(anairiats_sum_23, tmp831, atslab_0) ; tmp851 = ats_caselptrlab_mac(anairiats_sum_23, tmp831, atslab_1) ; tmp852 = ats_caselptrlab_mac(anairiats_sum_23, tmp831, atslab_2) ; tmp853 = ats_caselptrlab_mac(anairiats_sum_23, tmp831, atslab_3) ; tmp854 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp855 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp855, atslab_0, tmp850) ; tmp856 = atspre_gt_int_int (tmp851, 0) ; tmp857 = atspre_gt_int_int (tmp852, 0) ; tmp858 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp858, atslab_0, tmp826) ; tmp859 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp858), atslab_1) ; tmp860 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp859) = tmp860 ; tmp817 = s1exp_arrow_tr_up_60 (tmp854, tmp855, tmp856, tmp857, tmp853, tmp858) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: __ats_lab_202_1: tmp861 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (tmp830) ; tmp862 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp863 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, tmp830), atslab_s1exp_loc) ; tmp817 = s1exp_app_tr_up_43 (tmp862, tmp863, tmp861, tmp827) ; break ; } while (0) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)tmp818)->tag != 3) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp864 = ats_caselptrlab_mac(anairiats_sum_24, tmp818, atslab_0) ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char (tmp864) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp818)->tag != 4) { goto __ats_lab_205_0 ; } __ats_lab_204_1: tmp865 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_0) ; tmp866 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_1) ; tmp867 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_2) ; tmp869 = atspre_gt_int_int (tmp865, 0) ; if (tmp869) { tmp871 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp870 = */ prerr_loc_error2_0 (tmp871) ; /* tmp872 = */ atspre_prerr_string (ATSstrcst(": The existential quantifier #[...] is used incorrectly.")) ; /* tmp873 = */ atspre_prerr_newline () ; /* tmp868 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp874 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp875 = ats_selsin_mac(tmp874, atslab_1) */ ; tmp876 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp866) ; tmp877 = ats_select_mac(tmp876, atslab_0) ; tmp878 = ats_select_mac(tmp876, atslab_1) ; tmp879 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp867) ; /* tmp880 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (tmp877, tmp878, tmp879) ; break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: if (((ats_sum_ptr_type)tmp818)->tag != 5) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp881 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp882 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp883 = s1explstlst_tr_dn_viewt0ype_39 (tmp882) ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype, tmp881, tmp883) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp818)->tag != 6) { goto __ats_lab_207_0 ; } __ats_lab_206_1: tmp885 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp884 = */ prerr_loc_interror_2 (tmp885) ; /* tmp886 = */ atspre_prerr_string (ATSstrcst(": s1exp_tr_up: S1Eimp")) ; /* tmp887 = */ atspre_prerr_newline () ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: if (((ats_sum_ptr_type)tmp818)->tag != 7) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp888 = ats_caselptrlab_mac(anairiats_sum_3, tmp818, atslab_0) ; tmp889 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string (tmp888) ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (tmp889) ; break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: if (((ats_sum_ptr_type)tmp818)->tag != 8) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp891 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp890 = */ prerr_loc_error2_0 (tmp891) ; /* tmp892 = */ atspre_prerr_string (ATSstrcst(": an invariant type can only be assigned to the argument of a function.")) ; /* tmp893 = */ atspre_prerr_newline () ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)tmp818)->tag != 9) { goto __ats_lab_212_0 ; } __ats_lab_209_1: tmp894 = ats_caselptrlab_mac(anairiats_sum_19, tmp818, atslab_0) ; tmp895 = ats_caselptrlab_mac(anairiats_sum_19, tmp818, atslab_1) ; tmp896 = ats_caselptrlab_mac(anairiats_sum_19, tmp818, atslab_2) ; /* tmp897 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp898 = ats_selsin_mac(tmp897, atslab_1) */ ; tmp899 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglst_var_tr (tmp894) ; do { /* branch: __ats_lab_210 */ __ats_lab_210_0: if (tmp895 == (ats_sum_ptr_type)0) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp901 = ats_caselptrlab_mac(anairiats_sum_5, tmp895, atslab_0) ; tmp902 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp901) ; tmp900 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp896, tmp902) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: // if (tmp895 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_211_1: tmp900 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (tmp896) ; break ; } while (0) ; /* tmp903 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp904 = s2rtlst_of_s2varlst_70 (tmp899) ; tmp905 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp900), atslab_s2exp_srt) ; tmp906 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp904, tmp905) ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp906, tmp899, tmp900) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp818)->tag != 10) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp907 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_0) ; tmp908 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_1) ; tmp909 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_list_tr_up_73 (tmp909, tmp907, tmp908) ; break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: if (((ats_sum_ptr_type)tmp818)->tag != 11) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp910 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp911 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp912 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_qid_tr_up_50 (tmp912, tmp910, tmp911) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp818)->tag != 12) { goto __ats_lab_215_0 ; } __ats_lab_214_1: tmp913 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp914 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp817 = s1exp_read_tr_up_53 (tmp913, tmp914) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp818)->tag != 13) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp915 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_0) ; tmp916 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_1) ; tmp817 = s1exp_top_tr_up_54 (tmp915, tmp916) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp818)->tag != 14) { goto __ats_lab_217_0 ; } __ats_lab_216_1: tmp918 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp917 = */ prerr_loc_error2_0 (tmp918) ; /* tmp919 = */ atspre_prerr_string (ATSstrcst(": a transitional type can only be assigned to the argument of a function.")) ; /* tmp920 = */ atspre_prerr_newline () ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp818)->tag != 15) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp921 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp922 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp923 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_viewt0ype (tmp921) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp922, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn_int) ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp923, tmp924) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp818)->tag != 16) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp925 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_0) ; tmp926 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_1) ; tmp927 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_tyrec_tr_up_81 (tmp927, tmp925, tmp926) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp818)->tag != 17) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp928 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp929 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp930 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_tyrec_ext_tr_up_82 (tmp930, tmp928, tmp929) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp818)->tag != 18) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp931 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_0) ; tmp932 = ats_caselptrlab_mac(anairiats_sum_15, tmp818, atslab_1) ; tmp933 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_tytup_tr_up_74 (tmp933, tmp931, tmp932) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp818)->tag != 19) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp934 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_0) ; tmp935 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_1) ; tmp936 = ats_caselptrlab_mac(anairiats_sum_16, tmp818, atslab_2) ; tmp937 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_tytup2_tr_up_75 (tmp937, tmp934, tmp935, tmp936) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp818)->tag != 20) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp938 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp939 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; /* ats_ptr_type tmp940 ; */ tmp940 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp941 ; */ tmp941 = (ats_sum_ptr_type)0 ; /* tmp942 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp943 = ats_selsin_mac(tmp942, atslab_1) */ ; tmp944 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualst_tr (tmp938) ; tmp945 = ats_select_mac(tmp944, atslab_0) ; tmp946 = ats_select_mac(tmp944, atslab_1) ; tmp947 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn_impredicative (tmp939) ; /* tmp948 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp817 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp945, tmp946, tmp947) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: // if (((ats_sum_ptr_type)tmp818)->tag != 21) { ats_deadcode_failure_handle () ; } __ats_lab_223_1: tmp949 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_0) ; tmp950 = ats_caselptrlab_mac(anairiats_sum_4, tmp818, atslab_1) ; tmp951 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; tmp817 = s1exp_union_tr_up_83 (tmp951, tmp949, tmp950) ; break ; } while (0) ; return (tmp817) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 53873(line=1660, offs=16) -- 53919(line=1660, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp952) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up: tmp952 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up) ; return (tmp952) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 53948(line=1662, offs=19) -- 53999(line=1662, offs=70) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explstlst_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp953) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explstlst_tr_up: tmp953 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up) ; return (tmp953) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explstlst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 54055(line=1668, offs=3) -- 54369(line=1677, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up: do { /* branch: __ats_lab_224 */ __ats_lab_224_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp955 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp956 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp957 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp958 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up (tmp956) ; tmp959 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up (tmp957) ; tmp954 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp954, atslab_0, tmp955) ; ats_selptrset_mac(anairiats_sum_11, tmp954, atslab_1, tmp958) ; ats_selptrset_mac(anairiats_sum_11, tmp954, atslab_2, tmp959) ; break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_225_1: tmp954 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp954) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__tmps1explstlst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 54444(line=1682, offs=13) -- 55696(line=1717, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_bool_type, tmp965) ; // ATSlocal_void (tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; // ATSlocal_void (tmp968) ; // ATSlocal_void (tmp969) ; // ATSlocal_void (tmp970) ; // ATSlocal_void (tmp971) ; // ATSlocal_void (tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; ATSlocal (ats_bool_type, tmp975) ; // ATSlocal_void (tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; // ATSlocal_void (tmp978) ; // ATSlocal_void (tmp979) ; // ATSlocal_void (tmp980) ; // ATSlocal_void (tmp981) ; // ATSlocal_void (tmp982) ; // ATSlocal_void (tmp983) ; // ATSlocal_void (tmp984) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn: tmp961 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_node) ; do { /* branch: __ats_lab_226 */ __ats_lab_226_0: if (((ats_sum_ptr_type)tmp961)->tag != 5) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp962 = ats_caselptrlab_mac(anairiats_sum_4, tmp961, atslab_0) ; tmp963 = ats_caselptrlab_mac(anairiats_sum_4, tmp961, atslab_1) ; tmp964 = s1explstlst_tr_dn_viewt0ype_39 (tmp963) ; tmp965 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (arg1) ; if (tmp965) { tmp960 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt (arg1, tmp962, tmp964) ; } else { tmp967 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp966 = */ prerr_loc_error2_0 (tmp967) ; /* tmp968 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tr_dn"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp969 = */ atspre_prerr_string (ATSstrcst(": the external type cannot be assigned the sort [")) ; /* tmp970 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg1) ; /* tmp971 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp972 = */ atspre_prerr_newline () ; /* tmp960 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: __ats_lab_227_1: tmp973 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg0) ; tmp974 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp973), atslab_s2exp_srt) ; tmp975 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp974, arg1) ; if (tmp975) { tmp960 = tmp973 ; } else { tmp977 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s1exp_loc) ; /* tmp976 = */ prerr_loc_error2_0 (tmp977) ; /* tmp978 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1exp_tr_dn"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp979 = */ atspre_prerr_string (ATSstrcst(": the static expression is of sort [")) ; /* tmp980 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp974) ; /* tmp981 = */ atspre_prerr_string (ATSstrcst("] but it is expected to be of sort [")) ; /* tmp982 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg1) ; /* tmp983 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp984 = */ atspre_prerr_newline () ; /* tmp960 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; } while (0) ; return (tmp960) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 55750(line=1720, offs=16) -- 55954(line=1728, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn: do { /* branch: __ats_lab_228 */ __ats_lab_228_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp986 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp987 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp988 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp989 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp990 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp986, tmp988) ; tmp991 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn (tmp987, tmp989) ; tmp985 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp985, atslab_0, tmp990) ; ats_selptrset_mac(anairiats_sum_1, tmp985, atslab_1, tmp991) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp985 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp985) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 56026(line=1733, offs=13) -- 56303(line=1740, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp992) ; ATSlocal (ats_ptr_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr: tmp993 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exparg_node) ; do { /* branch: __ats_lab_230 */ __ats_lab_230_0: if (((ats_sum_ptr_type)tmp993)->tag != 0) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp994 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exparg_loc) ; tmp992 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_one (tmp994) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: if (((ats_sum_ptr_type)tmp993)->tag != 1) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp995 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exparg_loc) ; tmp992 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_all (tmp995) ; break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: // if (((ats_sum_ptr_type)tmp993)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_232_1: tmp996 = ats_caselptrlab_mac(anairiats_sum_3, tmp993, atslab_0) ; tmp997 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exparg_loc) ; tmp998 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_up (tmp996) ; tmp992 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exparg_seq (tmp997, tmp998) ; break ; } while (0) ; return (tmp992) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 56354(line=1743, offs=16) -- 56400(line=1743, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp999) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr: tmp999 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparg_tr) ; return (tmp999) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exparglst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 56426(line=1747, offs=4) -- 56562(line=1752, offs=4) */ ATSstaticdec() ats_void_type s1rtdef_tr_92 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; __ats_lab_s1rtdef_tr_92: tmp1001 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_s1rtdef_sym) ; tmp1003 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_26, arg0), atslab_s1rtdef_def) ; tmp1002 = s1rtext_tr_62 (tmp1003) ; /* tmp1000 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (tmp1001, tmp1002) ; return /* (tmp1000) */ ; } /* end of [s1rtdef_tr_92] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 56611(line=1755, offs=15) -- 56713(line=1757, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; // ATSlocal_void (tmp1007) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr: do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp1005 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1006 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp1007 = */ s1rtdef_tr_92 (tmp1005) ; arg0 = tmp1006 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr ; // tail call break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_234_1: break ; } while (0) ; return /* (tmp1004) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtdeflst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 56765(line=1761, offs=4) -- 57165(line=1775, offs=4) */ ATSstaticdec() anairiats_rec_27 d1atarg_tr_94 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_27, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_int_type, tmp1014) ; ATSlocal (ats_ptr_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; ATSlocal (ats_ptr_type, tmp1019) ; ATSlocal (ats_int_type, tmp1020) ; __ats_lab_d1atarg_tr_94: tmp1009 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_d1atarg_node) ; do { /* branch: __ats_lab_235 */ __ats_lab_235_0: if (((ats_sum_ptr_type)tmp1009)->tag != 0) { goto __ats_lab_236_0 ; } __ats_lab_235_1: tmp1010 = ats_caselptrlab_mac(anairiats_sum_3, tmp1009, atslab_0) ; tmp1012 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp1010), atslab_s1rtpol_srt) ; tmp1011 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp1012) ; tmp1013 = (ats_sum_ptr_type)0 ; tmp1014 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp1010), atslab_s1rtpol_pol) ; tmp1008.atslab_0 = tmp1013 ; tmp1008.atslab_1 = tmp1011 ; tmp1008.atslab_2 = tmp1014 ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: // if (((ats_sum_ptr_type)tmp1009)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_236_1: tmp1015 = ats_caselptrlab_mac(anairiats_sum_4, tmp1009, atslab_0) ; tmp1016 = ats_caselptrlab_mac(anairiats_sum_4, tmp1009, atslab_1) ; tmp1018 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp1016), atslab_s1rtpol_srt) ; tmp1017 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp1018) ; tmp1019 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1019, atslab_0, tmp1015) ; tmp1020 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp1016), atslab_s1rtpol_pol) ; tmp1008.atslab_0 = tmp1019 ; tmp1008.atslab_1 = tmp1017 ; tmp1008.atslab_2 = tmp1020 ; break ; } while (0) ; return (tmp1008) ; } /* end of [d1atarg_tr_94] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 57214(line=1778, offs=15) -- 57333(line=1781, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; ATSlocal (ats_ptr_type, tmp1023) ; ATSlocal (anairiats_rec_27, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr: do { /* branch: __ats_lab_237 */ __ats_lab_237_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_238_0 ; } __ats_lab_237_1: tmp1022 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1023 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1024 = d1atarg_tr_94 (tmp1022) ; tmp1025 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr (tmp1023) ; tmp1021 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ats_selptrset_mac(anairiats_sum_30, tmp1021, atslab_0, tmp1024) ; ats_selptrset_mac(anairiats_sum_30, tmp1021, atslab_1, tmp1025) ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_238_1: tmp1021 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1021) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 57716(line=1795, offs=13) -- 57854(line=1797, offs=68) */ ATSstaticdec() ats_ptr_type aux_97 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (anairiats_rec_27, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; ATSlocal (ats_ptr_type, tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; __ats_lab_aux_97: do { /* branch: __ats_lab_242 */ __ats_lab_242_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp1037 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_0) ; tmp1038 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_1) ; tmp1039 = ats_select_mac(tmp1037, atslab_1) ; tmp1040 = aux_97 (tmp1038) ; tmp1036 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1036, atslab_0, tmp1039) ; ats_selptrset_mac(anairiats_sum_1, tmp1036, atslab_1, tmp1040) ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_243_1: tmp1036 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1036) ; } /* end of [aux_97] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 58067(line=1806, offs=9) -- 58411(line=1817, offs=25) */ ATSstaticdec() ats_ptr_type aux_98 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1044) ; ATSlocal (anairiats_rec_27, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; // ATSlocal_void (tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; __ats_lab_aux_98: do { /* branch: __ats_lab_245 */ __ats_lab_245_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_248_0 ; } __ats_lab_245_1: tmp1045 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_0) ; tmp1046 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_1) ; tmp1048 = ats_select_mac(tmp1045, atslab_0) ; do { /* branch: __ats_lab_246 */ __ats_lab_246_0: if (tmp1048 == (ats_sum_ptr_type)0) { goto __ats_lab_247_0 ; } __ats_lab_246_1: tmp1049 = ats_caselptrlab_mac(anairiats_sum_5, tmp1048, atslab_0) ; tmp1050 = ats_select_mac(tmp1045, atslab_1) ; tmp1047 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp1049, tmp1050) ; break ; /* branch: __ats_lab_247 */ __ats_lab_247_0: // if (tmp1048 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_247_1: tmp1051 = ats_select_mac(tmp1045, atslab_1) ; tmp1047 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (tmp1051) ; break ; } while (0) ; /* tmp1052 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp1047) ; tmp1053 = aux_98 (tmp1046) ; tmp1044 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1044, atslab_0, tmp1047) ; ats_selptrset_mac(anairiats_sum_1, tmp1044, atslab_1, tmp1053) ; break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_248_1: tmp1044 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1044) ; } /* end of [aux_98] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 57364(line=1783, offs=4) -- 59324(line=1851, offs=4) */ ATSstaticdec() ats_void_type s1tacon_tr_96 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; ATSlocal (ats_ptr_type, tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; ATSlocal (ats_ptr_type, tmp1041) ; // ATSlocal_void (tmp1042) ; // ATSlocal_void (tmp1043) ; ATSlocal (ats_ptr_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_ptr_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_ptr_type, tmp1060) ; ATSlocal (ats_ptr_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; // ATSlocal_void (tmp1063) ; ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; // ATSlocal_void (tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; __ats_lab_s1tacon_tr_96: tmp1027 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg1), atslab_s1tacon_sym) ; tmp1028 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg1), atslab_s1tacon_fil) ; tmp1029 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg1), atslab_s1tacon_loc) ; tmp1031 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg1), atslab_s1tacon_arg) ; do { /* branch: __ats_lab_239 */ __ats_lab_239_0: if (tmp1031 == (ats_sum_ptr_type)0) { goto __ats_lab_240_0 ; } __ats_lab_239_1: tmp1032 = ats_caselptrlab_mac(anairiats_sum_5, tmp1031, atslab_0) ; tmp1033 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr (tmp1032) ; tmp1030 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1030, atslab_0, tmp1033) ; break ; /* branch: __ats_lab_240 */ __ats_lab_240_0: // if (tmp1031 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_240_1: tmp1030 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_241 */ __ats_lab_241_0: if (tmp1030 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_241_1: tmp1035 = ats_caselptrlab_mac(anairiats_sum_5, tmp1030, atslab_0) ; tmp1041 = aux_97 (tmp1035) ; tmp1034 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp1041, arg0) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: __ats_lab_244_1: tmp1034 = arg0 ; break ; } while (0) ; /* tmp1042 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp1043 = ats_selsin_mac(tmp1042, atslab_1) */ ; do { /* branch: __ats_lab_249 */ __ats_lab_249_0: if (tmp1030 == (ats_sum_ptr_type)0) { goto __ats_lab_250_0 ; } __ats_lab_249_1: tmp1055 = ats_caselptrlab_mac(anairiats_sum_5, tmp1030, atslab_0) ; tmp1056 = aux_98 (tmp1055) ; tmp1054 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1054, atslab_0, tmp1056) ; break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: // if (tmp1030 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_250_1: tmp1054 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp1058 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg1), atslab_s1tacon_def) ; do { /* branch: __ats_lab_251 */ __ats_lab_251_0: if (tmp1058 == (ats_sum_ptr_type)0) { goto __ats_lab_254_0 ; } __ats_lab_251_1: tmp1059 = ats_caselptrlab_mac(anairiats_sum_5, tmp1058, atslab_0) ; tmp1060 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp1059, arg0) ; do { /* branch: __ats_lab_252 */ __ats_lab_252_0: if (tmp1054 == (ats_sum_ptr_type)0) { goto __ats_lab_253_0 ; } __ats_lab_252_1: tmp1062 = ats_caselptrlab_mac(anairiats_sum_5, tmp1054, atslab_0) ; tmp1061 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp1034, tmp1062, tmp1060) ; break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: __ats_lab_253_1: tmp1061 = tmp1060 ; break ; } while (0) ; tmp1057 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1057, atslab_0, tmp1061) ; break ; /* branch: __ats_lab_254 */ __ats_lab_254_0: // if (tmp1058 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_254_1: tmp1057 = (ats_sum_ptr_type)0 ; break ; } while (0) ; /* tmp1063 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp1065 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1065, atslab_0, tmp1057) ; tmp1066 = (ats_sum_ptr_type)0 ; tmp1067 = (ats_sum_ptr_type)0 ; tmp1064 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (tmp1027, tmp1029, tmp1034, tmp1065, ats_true_bool, ats_false_bool, ats_false_bool, tmp1066, tmp1030, tmp1067) ; tmp1069 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1069, atslab_0, tmp1028) ; /* tmp1068 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_fil (tmp1064, tmp1069) ; /* tmp1026 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1064) ; return /* (tmp1026) */ ; } /* end of [s1tacon_tr_96] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 59398(line=1855, offs=7) -- 59532(line=1858, offs=74) */ ATSstaticdec() ats_void_type aux_100 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; // ATSlocal_void (tmp1074) ; __ats_lab_aux_100: do { /* branch: __ats_lab_255 */ __ats_lab_255_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp1072 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1073 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp1074 = */ s1tacon_tr_96 (arg0, tmp1072) ; arg0 = arg0 ; arg1 = tmp1073 ; goto __ats_lab_aux_100 ; // tail call break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_256_1: break ; } while (0) ; return /* (tmp1071) */ ; } /* end of [aux_100] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 59373(line=1854, offs=15) -- 59883(line=1870, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1taconlst_tr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1070) ; ATSlocal (ats_ptr_type, tmp1075) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1taconlst_tr: do { /* branch: __ats_lab_257 */ __ats_lab_257_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_259_0 ; } __ats_lab_258_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; break ; /* branch: __ats_lab_259 */ __ats_lab_259_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_260_0 ; } __ats_lab_259_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_261_0 ; } __ats_lab_260_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_262_0 ; } __ats_lab_261_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: // if (((ats_sum_ptr_type)arg0)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_262_1: tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; break ; } while (0) ; /* tmp1070 = */ aux_100 (tmp1075, arg1) ; return /* (tmp1070) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1taconlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 59935(line=1874, offs=4) -- 60502(line=1897, offs=4) */ ATSstaticdec() ats_void_type s1tacst_tr_101 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; ATSlocal (ats_ptr_type, tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; __ats_lab_s1tacst_tr_101: tmp1077 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_s1tacst_sym) ; tmp1078 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_s1tacst_loc) ; tmp1080 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_s1tacst_res) ; tmp1079 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp1080) ; tmp1082 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_s1tacst_arg) ; do { /* branch: __ats_lab_263 */ __ats_lab_263_0: if (tmp1082 == (ats_sum_ptr_type)0) { goto __ats_lab_264_0 ; } __ats_lab_263_1: tmp1083 = ats_caselptrlab_mac(anairiats_sum_5, tmp1082, atslab_0) ; tmp1084 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp1083) ; tmp1081 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp1084, tmp1079) ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: // if (tmp1082 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_264_1: tmp1081 = tmp1079 ; break ; } while (0) ; tmp1086 = (ats_sum_ptr_type)0 ; tmp1087 = (ats_sum_ptr_type)0 ; tmp1088 = (ats_sum_ptr_type)0 ; tmp1089 = (ats_sum_ptr_type)0 ; tmp1085 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (tmp1077, tmp1078, tmp1081, tmp1086, ats_false_bool, ats_false_bool, ats_false_bool, tmp1087, tmp1088, tmp1089) ; /* tmp1076 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1085) ; return /* (tmp1076) */ ; } /* end of [s1tacst_tr_101] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 60551(line=1900, offs=15) -- 60647(line=1902, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1090) ; ATSlocal (ats_ptr_type, tmp1091) ; ATSlocal (ats_ptr_type, tmp1092) ; // ATSlocal_void (tmp1093) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr: do { /* branch: __ats_lab_265 */ __ats_lab_265_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_266_0 ; } __ats_lab_265_1: tmp1091 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1092 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp1093 = */ s1tacst_tr_101 (tmp1091) ; arg0 = tmp1092 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr ; // tail call break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_266_1: break ; } while (0) ; return /* (tmp1090) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tacstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 60700(line=1906, offs=5) -- 60907(line=1913, offs=4) */ ATSstaticdec() ats_ptr_type s1tavar_tr_103 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_ptr_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; // ATSlocal_void (tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; __ats_lab_s1tavar_tr_103: tmp1096 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, arg0), atslab_s1tavar_srt) ; tmp1095 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp1096) ; tmp1098 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, arg0), atslab_s1tavar_sym) ; tmp1097 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp1098, tmp1095) ; /* tmp1099 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svar (tmp1097) ; tmp1100 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, arg0), atslab_s1tavar_loc) ; tmp1094 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2tavar_make (tmp1100, tmp1097) ; return (tmp1094) ; } /* end of [s1tavar_tr_103] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 60956(line=1916, offs=15) -- 60997(line=1916, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tavarlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tavarlst_tr: tmp1101 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &s1tavar_tr_103) ; return (tmp1101) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1tavarlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 61095(line=1924, offs=6) -- 61648(line=1946, offs=6) */ ATSstaticdec() ats_ptr_type aux_106 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1103) ; ATSlocal (ats_ptr_type, tmp1104) ; ATSlocal (ats_ptr_type, tmp1105) ; ATSlocal (ats_ptr_type, tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; ATSlocal (ats_ptr_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; ATSlocal (ats_ptr_type, tmp1110) ; ATSlocal (ats_ptr_type, tmp1111) ; ATSlocal (ats_ptr_type, tmp1112) ; ATSlocal (ats_ptr_type, tmp1113) ; // ATSlocal_void (tmp1114) ; // ATSlocal_void (tmp1115) ; __ats_lab_aux_106: tmp1104 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg2), atslab_d1atsrtcon_sym) ; tmp1105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg2), atslab_d1atsrtcon_loc) ; tmp1107 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, arg2), atslab_d1atsrtcon_arg) ; tmp1106 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtlst_tr (tmp1107) ; tmp1108 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp1106, arg1) ; tmp1110 = (ats_sum_ptr_type)0 ; tmp1111 = (ats_sum_ptr_type)0 ; tmp1112 = (ats_sum_ptr_type)0 ; tmp1113 = (ats_sum_ptr_type)0 ; tmp1109 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (tmp1104, tmp1105, tmp1108, tmp1110, ats_true_bool, ats_false_bool, ats_false_bool, tmp1111, tmp1112, tmp1113) ; /* tmp1114 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_tag (tmp1109, arg0) ; /* tmp1115 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1109) ; tmp1103 = tmp1109 ; return (tmp1103) ; } /* end of [aux_106] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 61674(line=1948, offs=7) -- 61907(line=1953, offs=31) */ ATSstaticdec() ats_ptr_type auxlst_107 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1116) ; ATSlocal (ats_ptr_type, tmp1117) ; ATSlocal (ats_ptr_type, tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; ATSlocal (ats_ptr_type, tmp1120) ; ATSlocal (ats_int_type, tmp1121) ; __ats_lab_auxlst_107: do { /* branch: __ats_lab_267 */ __ats_lab_267_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_268_0 ; } __ats_lab_267_1: tmp1117 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1118 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1119 = aux_106 (arg0, arg1, tmp1117) ; tmp1121 = atspre_add_int_int (arg0, 1) ; tmp1120 = auxlst_107 (tmp1121, arg1, tmp1118) ; tmp1116 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1116, atslab_0, tmp1119) ; ats_selptrset_mac(anairiats_sum_1, tmp1116, atslab_1, tmp1120) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_268_1: tmp1116 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1116) ; } /* end of [auxlst_107] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 61023(line=1920, offs=4) -- 61976(line=1958, offs=4) */ ATSstaticdec() ats_ptr_type d1atsrtdec_tr_105 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1102) ; ATSlocal (ats_ptr_type, tmp1122) ; __ats_lab_d1atsrtdec_tr_105: tmp1122 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg1), atslab_d1atsrtdec_con) ; tmp1102 = auxlst_107 (0, arg0, tmp1122) ; return (tmp1102) ; } /* end of [d1atsrtdec_tr_105] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 62114(line=1965, offs=7) -- 62370(line=1973, offs=28) */ ATSstaticdec() ats_void_type loop1_109 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1124) ; ATSlocal (anairiats_rec_36, tmp1125) ; ATSlocal (ats_ptr_type, tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; ATSlocal (ats_ptr_type, tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; // ATSlocal_void (tmp1130) ; ATSlocal (ats_ptr_type, tmp1131) ; __ats_lab_loop1_109: do { /* branch: __ats_lab_269 */ __ats_lab_269_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_270_0 ; } __ats_lab_269_1: tmp1125 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_0) ; tmp1126 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp1128 = ats_select_mac(tmp1125, atslab_2) ; tmp1129 = ats_select_mac(tmp1125, atslab_0) ; tmp1127 = d1atsrtdec_tr_105 (tmp1128, tmp1129) ; tmp1131 = ats_select_mac(tmp1125, atslab_1) ; /* tmp1130 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_set_conlst (tmp1131, tmp1127) ; arg0 = tmp1126 ; goto __ats_lab_loop1_109 ; // tail call break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_270_1: break ; } while (0) ; return /* (tmp1124) */ ; } /* end of [loop1_109] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 62400(line=1976, offs=7) -- 63269(line=2003, offs=31) */ ATSstaticdec() ats_void_type loop2_110 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1132) ; ATSlocal (ats_ptr_type, tmp1133) ; ATSlocal (ats_ptr_type, tmp1134) ; ATSlocal (ats_ptr_type, tmp1135) ; ATSlocal (ats_ptr_type, tmp1136) ; ATSlocal (ats_ptr_type, tmp1137) ; ATSlocal (ats_ptr_type, tmp1138) ; ATSlocal (ats_ptr_type, tmp1139) ; ATSlocal (ats_ptr_type, tmp1140) ; ATSlocal (ats_ptr_type, tmp1141) ; ATSlocal (ats_ptr_type, tmp1142) ; ATSlocal (ats_ptr_type, tmp1143) ; ATSlocal (ats_ptr_type, tmp1144) ; ATSlocal (ats_ptr_type, tmp1145) ; ATSlocal (ats_ptr_type, tmp1146) ; ATSlocal (ats_ptr_type, tmp1147) ; ATSlocal (ats_ptr_type, tmp1148) ; // ATSlocal_void (tmp1149) ; // ATSlocal_void (tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; ATSlocal (ats_ptr_type, tmp1152) ; ATSlocal (anairiats_rec_36, tmp1153) ; __ats_lab_loop2_110: do { /* branch: __ats_lab_271 */ __ats_lab_271_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_272_0 ; } __ats_lab_271_1: tmp1133 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1134 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1135 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, tmp1133), atslab_d1atsrtdec_sym) ; tmp1136 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, tmp1133), atslab_d1atsrtdec_loc) ; tmp1137 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_make (tmp1135) ; tmp1139 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp1139)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp1139, atslab_0, tmp1137) ; tmp1138 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp1138)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp1138, atslab_0, tmp1139) ; tmp1141 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1141, atslab_0, tmp1138) ; tmp1142 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1141), atslab_1) ; tmp1143 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1143, atslab_0, tmp1138) ; ats_ptrget_mac(ats_ptr_type, tmp1142) = tmp1143 ; tmp1142 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_1, tmp1143), atslab_1) ; tmp1143 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1142) = tmp1143 ; tmp1140 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp1141, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; tmp1145 = (ats_sum_ptr_type)0 ; tmp1146 = (ats_sum_ptr_type)0 ; tmp1147 = (ats_sum_ptr_type)0 ; tmp1148 = (ats_sum_ptr_type)0 ; tmp1144 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ, tmp1136, tmp1140, tmp1145, ats_false_bool, ats_false_bool, ats_false_bool, tmp1146, tmp1147, tmp1148) ; /* tmp1149 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1144) ; tmp1151 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp1151)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp1151, atslab_0, tmp1138) ; /* tmp1150 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2rtenv_add (tmp1135, tmp1151) ; tmp1153.atslab_0 = tmp1133 ; tmp1153.atslab_1 = tmp1137 ; tmp1153.atslab_2 = tmp1138 ; tmp1152 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp1152, atslab_0, tmp1153) ; ats_selptrset_mac(anairiats_sum_37, tmp1152, atslab_1, arg1) ; arg0 = tmp1134 ; arg1 = tmp1152 ; goto __ats_lab_loop2_110 ; // tail call break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_272_1: /* tmp1132 = */ loop1_109 (arg1) ; break ; } while (0) ; return /* (tmp1132) */ ; } /* end of [loop2_110] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 62031(line=1961, offs=18) -- 63330(line=2008, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atsrtdeclst_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1123) ; ATSlocal (ats_ptr_type, tmp1154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atsrtdeclst_tr: tmp1154 = (ats_sum_ptr_type)0 ; /* tmp1123 = */ loop2_110 (arg0, tmp1154) ; return /* (tmp1123) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atsrtdeclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 63751(line=2023, offs=7) -- 64106(line=2035, offs=6) */ ATSstaticdec() ats_ptr_type aux_112 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1162) ; ATSlocal (ats_ptr_type, tmp1163) ; ATSlocal (ats_ptr_type, tmp1164) ; ATSlocal (ats_ptr_type, tmp1165) ; ATSlocal (ats_ptr_type, tmp1166) ; ATSlocal (ats_ptr_type, tmp1167) ; ATSlocal (ats_ptr_type, tmp1168) ; __ats_lab_aux_112: do { /* branch: __ats_lab_275 */ __ats_lab_275_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp1163 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1164 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1165 = aux_112 (arg0, tmp1164) ; tmp1166 = s2rtlst_of_s2varlst_70 (tmp1163) ; tmp1168 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp1165), atslab_s2exp_srt) ; tmp1167 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_fun (tmp1166, tmp1168) ; tmp1162 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp1167, tmp1163, tmp1165) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_276_1: tmp1162 = arg0 ; break ; } while (0) ; return (tmp1162) ; } /* end of [aux_112] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 63385(line=2012, offs=4) -- 64152(line=2039, offs=4) */ ATSstaticdec() ats_ptr_type s1expdef_s1aspdec_tr_main_111 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1155) ; // ATSlocal_void (tmp1156) ; // ATSlocal_void (tmp1157) ; ATSlocal (ats_ptr_type, tmp1158) ; ATSlocal (ats_ptr_type, tmp1159) ; ATSlocal (ats_ptr_type, tmp1160) ; // ATSlocal_void (tmp1161) ; __ats_lab_s1expdef_s1aspdec_tr_main_111: /* tmp1156 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp1157 = ats_selsin_mac(tmp1156, atslab_1) */ ; tmp1158 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1arglstlst_var_tr (arg1) ; do { /* branch: __ats_lab_273 */ __ats_lab_273_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp1160 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp1159 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (arg3, tmp1160) ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: __ats_lab_274_1: tmp1159 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_up (arg3) ; break ; } while (0) ; /* tmp1161 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp1155 = aux_112 (tmp1159, tmp1158) ; return (tmp1155) ; } /* end of [s1expdef_s1aspdec_tr_main_111] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 64257(line=2045, offs=6) -- 64615(line=2054, offs=6) */ ATSstaticdec() ats_void_type err_114 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1170) ; // ATSlocal_void (tmp1171) ; ATSlocal (ats_ptr_type, tmp1172) ; // ATSlocal_void (tmp1173) ; // ATSlocal_void (tmp1174) ; // ATSlocal_void (tmp1175) ; // ATSlocal_void (tmp1176) ; ATSlocal (ats_ptr_type, tmp1177) ; // ATSlocal_void (tmp1178) ; // ATSlocal_void (tmp1179) ; __ats_lab_err_114: tmp1172 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s1expdef_loc) ; /* tmp1171 = */ prerr_loc_error2_0 (tmp1172) ; /* tmp1173 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1expdef_tr"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp1174 = */ atspre_prerr_string (ATSstrcst(": the sort for the definition does not match")) ; /* tmp1175 = */ atspre_prerr_string (ATSstrcst(" the sort assigned to the static constant [")) ; tmp1177 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s1expdef_sym) ; /* tmp1176 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp1177) ; /* tmp1178 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp1179 = */ atspre_prerr_newline () ; /* tmp1170 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp1170) */ ; } /* end of [err_114] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 64235(line=2044, offs=13) -- 65348(line=2082, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1169) ; ATSlocal (ats_ptr_type, tmp1180) ; ATSlocal (ats_ptr_type, tmp1181) ; ATSlocal (ats_ptr_type, tmp1182) ; ATSlocal (ats_ptr_type, tmp1183) ; // ATSlocal_void (tmp1184) ; ATSlocal (ats_ptr_type, tmp1185) ; ATSlocal (ats_bool_type, tmp1186) ; ATSlocal (ats_ptr_type, tmp1187) ; ATSlocal (ats_ptr_type, tmp1188) ; ATSlocal (ats_ptr_type, tmp1189) ; ATSlocal (ats_ptr_type, tmp1190) ; ATSlocal (ats_ptr_type, tmp1191) ; ATSlocal (ats_ptr_type, tmp1192) ; ATSlocal (ats_ptr_type, tmp1193) ; ATSlocal (ats_ptr_type, tmp1194) ; ATSlocal (ats_ptr_type, tmp1195) ; ATSlocal (ats_ptr_type, tmp1196) ; ATSlocal (ats_ptr_type, tmp1197) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr: tmp1181 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_res) ; do { /* branch: __ats_lab_277 */ __ats_lab_277_0: if (tmp1181 == (ats_sum_ptr_type)0) { goto __ats_lab_280_0 ; } __ats_lab_277_1: tmp1182 = ats_caselptrlab_mac(anairiats_sum_5, tmp1181, atslab_0) ; tmp1183 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rt_tr (tmp1182) ; do { /* branch: __ats_lab_278 */ __ats_lab_278_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp1185 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp1186 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp1183, tmp1185) ; if (tmp1186) { /* empty */ } else { /* tmp1184 = */ err_114 (arg1) ; } /* end of [if] */ break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_279_1: break ; } while (0) ; tmp1180 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1180, atslab_0, tmp1183) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: // if (tmp1181 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_280_1: tmp1180 = arg0 ; break ; } while (0) ; tmp1188 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_loc) ; tmp1189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_arg) ; tmp1190 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_def) ; tmp1187 = s1expdef_s1aspdec_tr_main_111 (tmp1188, tmp1189, tmp1180, tmp1190) ; tmp1191 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_sym) ; tmp1192 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg1), atslab_s1expdef_loc) ; tmp1193 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp1187), atslab_s2exp_srt) ; tmp1194 = (ats_sum_ptr_type)0 ; tmp1195 = (ats_sum_ptr_type)0 ; tmp1196 = (ats_sum_ptr_type)0 ; tmp1197 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1197, atslab_0, tmp1187) ; tmp1169 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make (tmp1191, tmp1192, tmp1193, tmp1194, ats_false_bool, ats_false_bool, ats_false_bool, tmp1195, tmp1196, tmp1197) ; return (tmp1169) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 65462(line=2087, offs=9) -- 65756(line=2095, offs=38) */ ATSstaticdec() ats_ptr_type aux_116 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1199) ; ATSlocal (ats_ptr_type, tmp1200) ; ATSlocal (ats_ptr_type, tmp1201) ; ATSlocal (ats_ptr_type, tmp1202) ; ATSlocal (ats_ptr_type, tmp1203) ; __ats_lab_aux_116: do { /* branch: __ats_lab_281 */ __ats_lab_281_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp1200 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1201 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1202 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr (arg0, tmp1200) ; tmp1203 = aux_116 (arg0, tmp1201) ; tmp1199 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1199, atslab_0, tmp1202) ; ats_selptrset_mac(anairiats_sum_1, tmp1199, atslab_1, tmp1203) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_282_1: tmp1199 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1199) ; } /* end of [aux_116] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 65833(line=2099, offs=9) -- 66053(line=2104, offs=30) */ ATSstaticdec() ats_void_type aux_117 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1205) ; ATSlocal (ats_ptr_type, tmp1206) ; ATSlocal (ats_ptr_type, tmp1207) ; // ATSlocal_void (tmp1208) ; __ats_lab_aux_117: do { /* branch: __ats_lab_283 */ __ats_lab_283_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp1206 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1207 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp1208 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1206) ; arg0 = tmp1207 ; goto __ats_lab_aux_117 ; // tail call break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_284_1: break ; } while (0) ; return /* (tmp1205) */ ; } /* end of [aux_117] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 65399(line=2085, offs=16) -- 66111(line=2109, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdeflst_tr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1198) ; ATSlocal (ats_ptr_type, tmp1204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdeflst_tr: tmp1204 = aux_116 (arg0, arg1) ; /* tmp1198 = */ aux_117 (tmp1204) ; return /* (tmp1198) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdeflst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 66201(line=2116, offs=4) -- 66676(line=2133, offs=4) */ ATSstaticdec() ats_ptr_type err1_119 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1210) ; // ATSlocal_void (tmp1211) ; // ATSlocal_void (tmp1212) ; // ATSlocal_void (tmp1213) ; // ATSlocal_void (tmp1214) ; // ATSlocal_void (tmp1215) ; // ATSlocal_void (tmp1216) ; // ATSlocal_void (tmp1217) ; // ATSlocal_void (tmp1218) ; // ATSlocal_void (tmp1219) ; // ATSlocal_void (tmp1220) ; // ATSlocal_void (tmp1221) ; // ATSlocal_void (tmp1222) ; __ats_lab_err1_119: /* tmp1211 = */ prerr_loc_error2_0 (arg0) ; /* tmp1212 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1aspdec_tr: err1"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp1213 = */ atspre_prerr_string (ATSstrcst(": sort mismatch")) ; /* tmp1214 = */ atspre_prerr_string (ATSstrcst(": the sort of the static constant [")) ; /* tmp1215 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp1216 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp1217 = */ atspre_prerr_string (ATSstrcst("] is [")) ; /* tmp1218 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg3) ; /* tmp1219 = */ atspre_prerr_string (ATSstrcst("] while the sort of its definition is [")) ; /* tmp1220 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg4) ; /* tmp1221 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp1222 = */ atspre_prerr_newline () ; /* tmp1210 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1210) ; } /* end of [err1_119] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 67074(line=2150, offs=4) -- 67391(line=2161, offs=4) */ ATSstaticdec() ats_ptr_type err3_120 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1223) ; // ATSlocal_void (tmp1224) ; // ATSlocal_void (tmp1225) ; // ATSlocal_void (tmp1226) ; // ATSlocal_void (tmp1227) ; // ATSlocal_void (tmp1228) ; // ATSlocal_void (tmp1229) ; // ATSlocal_void (tmp1230) ; __ats_lab_err3_120: /* tmp1224 = */ prerr_loc_error2_0 (arg0) ; /* tmp1225 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1aspdec_tr: err3"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp1226 = */ atspre_prerr_string (ATSstrcst(": the static constant [")) ; /* tmp1227 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp1228 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp1229 = */ atspre_prerr_string (ATSstrcst("] is not abstract.")) ; /* tmp1230 = */ atspre_prerr_newline () ; /* tmp1223 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1223) ; } /* end of [err3_120] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 67415(line=2163, offs=4) -- 67747(line=2174, offs=4) */ ATSstaticdec() ats_ptr_type err4_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1231) ; // ATSlocal_void (tmp1232) ; // ATSlocal_void (tmp1233) ; // ATSlocal_void (tmp1234) ; // ATSlocal_void (tmp1235) ; // ATSlocal_void (tmp1236) ; // ATSlocal_void (tmp1237) ; // ATSlocal_void (tmp1238) ; __ats_lab_err4_121: /* tmp1232 = */ prerr_loc_error2_0 (arg0) ; /* tmp1233 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1aspdec_tr: err4"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp1234 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp1235 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp1236 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp1237 = */ atspre_prerr_string (ATSstrcst("] does not refer to a static constant.")) ; /* tmp1238 = */ atspre_prerr_newline () ; /* tmp1231 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1231) ; } /* end of [err4_121] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 67771(line=2176, offs=4) -- 68083(line=2187, offs=4) */ ATSstaticdec() ats_ptr_type err5_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1239) ; // ATSlocal_void (tmp1240) ; // ATSlocal_void (tmp1241) ; // ATSlocal_void (tmp1242) ; // ATSlocal_void (tmp1243) ; // ATSlocal_void (tmp1244) ; // ATSlocal_void (tmp1245) ; // ATSlocal_void (tmp1246) ; __ats_lab_err5_122: /* tmp1240 = */ prerr_loc_error2_0 (arg0) ; /* tmp1241 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s1aspdec_tr: err5"), ATSstrcst("ats_trans2_sta.dats")) ; /* tmp1242 = */ atspre_prerr_string (ATSstrcst(": the identifier [")) ; /* tmp1243 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (arg1) ; /* tmp1244 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg2) ; /* tmp1245 = */ atspre_prerr_string (ATSstrcst("] is unrecognized.")) ; /* tmp1246 = */ atspre_prerr_newline () ; /* tmp1239 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1239) ; } /* end of [err5_122] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 68422(line=2199, offs=15) -- 68777(line=2207, offs=47) */ ATSstaticdec() ats_ptr_type filter_123 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1255) ; ATSlocal (ats_ptr_type, tmp1256) ; ATSlocal (ats_ptr_type, tmp1257) ; ATSlocal (ats_bool_type, tmp1258) ; ATSlocal (ats_ptr_type, tmp1259) ; __ats_lab_filter_123: do { /* branch: __ats_lab_287 */ __ats_lab_287_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_290_0 ; } __ats_lab_287_1: tmp1256 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1257 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; do { /* branch: __ats_lab_288 */ __ats_lab_288_0: __ats_lab_288_1: tmp1258 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract (tmp1256) ; if (!tmp1258) { goto __ats_lab_289_1 ; } tmp1259 = filter_123 (tmp1257) ; tmp1255 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1255, atslab_0, tmp1256) ; ats_selptrset_mac(anairiats_sum_1, tmp1255, atslab_1, tmp1259) ; break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: __ats_lab_289_1: arg0 = tmp1257 ; goto __ats_lab_filter_123 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_290 */ __ats_lab_290_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_290_1: tmp1255 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1255) ; } /* end of [filter_123] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 66183(line=2114, offs=13) -- 69700(line=2234, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1aspdec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1209) ; ATSlocal (ats_ptr_type, tmp1247) ; ATSlocal (ats_ptr_type, tmp1248) ; ATSlocal (ats_ptr_type, tmp1249) ; ATSlocal (ats_ptr_type, tmp1250) ; ATSlocal (ats_ptr_type, tmp1251) ; ATSlocal (ats_ptr_type, tmp1252) ; ATSlocal (ats_ptr_type, tmp1253) ; ATSlocal (ats_ptr_type, tmp1254) ; ATSlocal (ats_ptr_type, tmp1260) ; ATSlocal (ats_ptr_type, tmp1261) ; ATSlocal (ats_ptr_type, tmp1262) ; ATSlocal (ats_ptr_type, tmp1263) ; ATSlocal (ats_ptr_type, tmp1264) ; ATSlocal (ats_ptr_type, tmp1265) ; ATSlocal (ats_ptr_type, tmp1266) ; ATSlocal (ats_ptr_type, tmp1267) ; ATSlocal (ats_ptr_type, tmp1268) ; ATSlocal (ats_bool_type, tmp1269) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1aspdec_tr: tmp1247 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_fil) ; tmp1248 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_loc) ; tmp1249 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_qid) ; tmp1250 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp1249), atslab_sqi0de_qua) ; tmp1251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, tmp1249), atslab_sqi0de_sym) ; tmp1252 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_find_qua (tmp1250, tmp1251) ; do { /* branch: __ats_lab_285 */ __ats_lab_285_0: if (tmp1252 == (ats_sum_ptr_type)0) { goto __ats_lab_294_0 ; } __ats_lab_285_1: tmp1253 = ats_caselptrlab_mac(anairiats_sum_5, tmp1252, atslab_0) ; ATS_FREE(tmp1252) ; do { /* branch: __ats_lab_286 */ __ats_lab_286_0: if (((ats_sum_ptr_type)tmp1253)->tag != 0) { goto __ats_lab_293_0 ; } __ats_lab_286_1: tmp1254 = ats_caselptrlab_mac(anairiats_sum_3, tmp1253, atslab_0) ; tmp1260 = filter_123 (tmp1254) ; do { /* branch: __ats_lab_291 */ __ats_lab_291_0: if (tmp1260 == (ats_sum_ptr_type)0) { goto __ats_lab_292_0 ; } __ats_lab_291_1: tmp1261 = ats_caselptrlab_mac(anairiats_sum_1, tmp1260, atslab_0) ; tmp1263 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_res) ; tmp1262 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1rtopt_tr (tmp1263) ; tmp1265 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_arg) ; tmp1266 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s1aspdec_def) ; tmp1264 = s1expdef_s1aspdec_tr_main_111 (tmp1248, tmp1265, tmp1262, tmp1266) ; tmp1267 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp1264), atslab_s2exp_srt) ; tmp1268 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp1261) ; tmp1269 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp1267, tmp1268) ; if (tmp1269) { tmp1209 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__s2aspdec_make (tmp1247, tmp1248, tmp1261, tmp1264) ; } else { tmp1209 = err1_119 (tmp1248, tmp1250, tmp1251, tmp1268, tmp1267) ; } /* end of [if] */ break ; /* branch: __ats_lab_292 */ __ats_lab_292_0: // if (tmp1260 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_292_1: tmp1209 = err3_120 (tmp1248, tmp1250, tmp1251) ; break ; } while (0) ; break ; /* branch: __ats_lab_293 */ __ats_lab_293_0: __ats_lab_293_1: tmp1209 = err4_121 (tmp1248, tmp1250, tmp1251) ; break ; } while (0) ; break ; /* branch: __ats_lab_294 */ __ats_lab_294_0: // if (tmp1252 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_294_1: tmp1209 = err5_122 (tmp1248, tmp1250, tmp1251) ; break ; } while (0) ; return (tmp1209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1aspdec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 69890(line=2247, offs=6) -- 70120(line=2252, offs=6) */ ATSstaticdec() ats_ptr_type err1_125 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1271) ; // ATSlocal_void (tmp1272) ; // ATSlocal_void (tmp1273) ; // ATSlocal_void (tmp1274) ; // ATSlocal_void (tmp1275) ; // ATSlocal_void (tmp1276) ; __ats_lab_err1_125: /* tmp1272 = */ prerr_loc_error2_0 (arg0) ; /* tmp1273 = */ atspre_prerr_string (ATSstrcst(": fewer indexes are needed for the constructor [")) ; /* tmp1274 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp1275 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp1276 = */ atspre_prerr_newline () ; /* tmp1271 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1271) ; } /* end of [err1_125] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 70144(line=2254, offs=6) -- 70373(line=2259, offs=6) */ ATSstaticdec() ats_ptr_type err2_126 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1277) ; // ATSlocal_void (tmp1278) ; // ATSlocal_void (tmp1279) ; // ATSlocal_void (tmp1280) ; // ATSlocal_void (tmp1281) ; // ATSlocal_void (tmp1282) ; __ats_lab_err2_126: /* tmp1278 = */ prerr_loc_error2_0 (arg0) ; /* tmp1279 = */ atspre_prerr_string (ATSstrcst(": more indexes are needed for the constructor [")) ; /* tmp1280 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp1281 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp1282 = */ atspre_prerr_newline () ; /* tmp1277 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1277) ; } /* end of [err2_126] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 70397(line=2261, offs=6) -- 70624(line=2266, offs=6) */ ATSstaticdec() ats_ptr_type err3_127 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1283) ; // ATSlocal_void (tmp1284) ; // ATSlocal_void (tmp1285) ; // ATSlocal_void (tmp1286) ; // ATSlocal_void (tmp1287) ; // ATSlocal_void (tmp1288) ; __ats_lab_err3_127: /* tmp1284 = */ prerr_loc_error2_0 (arg0) ; /* tmp1285 = */ atspre_prerr_string (ATSstrcst(": no indexes are needed for the constructor [")) ; /* tmp1286 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp1287 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp1288 = */ atspre_prerr_newline () ; /* tmp1283 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1283) ; } /* end of [err3_127] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 70648(line=2268, offs=6) -- 70877(line=2273, offs=6) */ ATSstaticdec() ats_ptr_type err4_128 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1289) ; // ATSlocal_void (tmp1290) ; // ATSlocal_void (tmp1291) ; // ATSlocal_void (tmp1292) ; // ATSlocal_void (tmp1293) ; // ATSlocal_void (tmp1294) ; __ats_lab_err4_128: /* tmp1290 = */ prerr_loc_error2_0 (arg0) ; /* tmp1291 = */ atspre_prerr_string (ATSstrcst(": some indexes are needed for the constructor [")) ; /* tmp1292 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp1293 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp1294 = */ atspre_prerr_newline () ; /* tmp1289 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp1289) ; } /* end of [err4_128] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 71676(line=2295, offs=9) -- 71996(line=2303, offs=8) */ ATSstaticdec() ats_ptr_type aux_129 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1315) ; ATSlocal (ats_ptr_type, tmp1316) ; ATSlocal (ats_ptr_type, tmp1317) ; ATSlocal (ats_ptr_type, tmp1318) ; ATSlocal (ats_bool_type, tmp1319) ; ATSlocal (ats_ptr_type, tmp1320) ; ATSlocal (ats_ptr_type, tmp1321) ; ATSlocal (ats_int_type, tmp1322) ; __ats_lab_aux_129: do { /* branch: __ats_lab_299 */ __ats_lab_299_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_300_0 ; } __ats_lab_299_1: tmp1316 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1317 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1319 = atspre_lt_int_int (arg0, env0) ; if (tmp1319) { tmp1318 = env1 ; } else { tmp1318 = env2 ; } /* end of [if] */ tmp1320 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1exp_tr_dn (tmp1316, tmp1318) ; tmp1322 = atspre_add_int_int (arg0, 1) ; tmp1321 = aux_129 (env0, env1, env2, tmp1322, tmp1317) ; tmp1315 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1315, atslab_0, tmp1320) ; ats_selptrset_mac(anairiats_sum_1, tmp1315, atslab_1, tmp1321) ; break ; /* branch: __ats_lab_300 */ __ats_lab_300_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_300_1: tmp1315 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1315) ; } /* end of [aux_129] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_129_closure_type ; ats_ptr_type aux_129_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { return aux_129 (((aux_129_closure_type*)cloptr)->closure_env_0, ((aux_129_closure_type*)cloptr)->closure_env_1, ((aux_129_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_129_closure_init (aux_129_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_129_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_129_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_129_closure_type *p_clo = ATS_MALLOC(sizeof(aux_129_closure_type)) ; aux_129_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 69750(line=2238, offs=4) -- 73062(line=2336, offs=4) */ ATSstaticdec() ats_ptr_type d1atcon_tr_124 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1270) ; ATSlocal (ats_ptr_type, tmp1295) ; ATSlocal (ats_ptr_type, tmp1296) ; // ATSlocal_void (tmp1297) ; // ATSlocal_void (tmp1298) ; // ATSlocal_void (tmp1299) ; ATSlocal (ats_ptr_type, tmp1300) ; ATSlocal (ats_ptr_type, tmp1301) ; ATSlocal (ats_ptr_type, tmp1303) ; ATSlocal (anairiats_rec_0, tmp1304) ; ATSlocal (ats_ptr_type, tmp1305) ; ATSlocal (ats_ptr_type, tmp1306) ; ATSlocal (ats_ptr_type, tmp1308) ; ATSlocal (ats_ptr_type, tmp1309) ; ATSlocal (ats_ptr_type, tmp1310) ; ATSlocal (ats_int_type, tmp1311) ; ATSlocal (ats_ptr_type, tmp1312) ; ATSlocal (ats_ptr_type, tmp1313) ; ATSlocal (ats_ptr_type, tmp1314) ; ATSlocal (ats_ptr_type, tmp1323) ; ATSlocal (ats_ptr_type, tmp1324) ; ATSlocal (ats_ptr_type, tmp1325) ; ATSlocal (ats_ptr_type, tmp1326) ; ATSlocal (ats_ptr_type, tmp1327) ; ATSlocal (ats_ptr_type, tmp1328) ; ATSlocal (ats_int_type, tmp1329) ; ATSlocal (ats_int_type, tmp1330) ; ATSlocal (ats_int_type, tmp1331) ; ATSlocal (ats_ptr_type, tmp1332) ; // ATSlocal_void (tmp1333) ; ATSlocal (ats_int_type, tmp1334) ; ATSlocal (ats_ptr_type, tmp1335) ; // ATSlocal_void (tmp1336) ; // ATSlocal_void (tmp1337) ; // ATSlocal_void (tmp1338) ; __ats_lab_d1atcon_tr_124: tmp1295 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_loc) ; tmp1296 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_sym) ; /* tmp1297 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp1298 = ats_selsin_mac(tmp1297, atslab_1) */ ; /* tmp1299 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_svarlst (arg3) ; /* ats_ptr_type tmp1300 ; */ tmp1301 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_qua) ; tmp1300 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (tmp1301) ; do { /* branch: __ats_lab_295 */ __ats_lab_295_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_296_0 ; } __ats_lab_295_1: tmp1305 = (ats_sum_ptr_type)0 ; tmp1304.atslab_0 = arg3 ; tmp1304.atslab_1 = tmp1305 ; tmp1303 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp1303, atslab_0, tmp1304) ; ats_selptrset_mac(anairiats_sum_21, tmp1303, atslab_1, tmp1300) ; tmp1300 = tmp1303 ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_296_1: break ; } while (0) ; /* ats_ptr_type tmp1306 ; */ tmp1306 = (ats_sum_ptr_type)0 ; tmp1308 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (arg0) ; do { /* branch: __ats_lab_297 */ __ats_lab_297_0: if (((ats_sum_ptr_type)tmp1308)->tag != 1) { goto __ats_lab_298_0 ; } __ats_lab_297_1: tmp1309 = ats_caselptrlab_mac(anairiats_sum_4, tmp1308, atslab_0) ; tmp1310 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1310, atslab_0, tmp1309) ; tmp1306 = tmp1310 ; break ; /* branch: __ats_lab_298 */ __ats_lab_298_0: __ats_lab_298_1: break ; } while (0) ; tmp1311 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_npf) ; tmp1312 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_arg) ; if (arg1) { tmp1313 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } else { tmp1313 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } /* end of [if] */ if (arg2) { tmp1314 = tmp1313 ; } else { if (arg1) { tmp1314 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } else { tmp1314 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } /* end of [if] */ tmp1323 = aux_129 (tmp1311, tmp1313, tmp1314, 0, tmp1312) ; tmp1324 = tmp1306 ; tmp1326 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg5), atslab_d1atcon_ind) ; do { /* branch: __ats_lab_301 */ __ats_lab_301_0: if (tmp1326 == (ats_sum_ptr_type)0) { goto __ats_lab_305_0 ; } __ats_lab_301_1: if (tmp1324 == (ats_sum_ptr_type)0) { goto __ats_lab_306_1 ; } __ats_lab_301_2: tmp1327 = ats_caselptrlab_mac(anairiats_sum_5, tmp1326, atslab_0) ; tmp1328 = ats_caselptrlab_mac(anairiats_sum_5, tmp1324, atslab_0) ; tmp1329 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp1327) ; tmp1330 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp1328) ; tmp1331 = atspre_icompare (tmp1329, tmp1330) ; do { /* branch: __ats_lab_302 */ __ats_lab_302_0: if (tmp1331 != 0) { goto __ats_lab_303_0 ; } __ats_lab_302_1: tmp1332 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1explst_tr_dn (tmp1327, tmp1328) ; tmp1325 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1325, atslab_0, tmp1332) ; break ; /* branch: __ats_lab_303 */ __ats_lab_303_0: if (tmp1331 != 1) { goto __ats_lab_304_0 ; } __ats_lab_303_1: tmp1325 = err1_125 (tmp1295, tmp1296) ; break ; /* branch: __ats_lab_304 */ __ats_lab_304_0: __ats_lab_304_1: tmp1325 = err2_126 (tmp1295, tmp1296) ; break ; } while (0) ; break ; /* branch: __ats_lab_305 */ __ats_lab_305_0: if (tmp1326 != (ats_sum_ptr_type)0) { goto __ats_lab_306_0 ; } __ats_lab_305_1: if (tmp1324 != (ats_sum_ptr_type)0) { goto __ats_lab_307_1 ; } __ats_lab_305_2: tmp1325 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_306 */ __ats_lab_306_0: if (tmp1326 == (ats_sum_ptr_type)0) { goto __ats_lab_307_0 ; } __ats_lab_306_1: // if (tmp1324 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_306_2: tmp1325 = err3_127 (tmp1295, tmp1296) ; break ; /* branch: __ats_lab_307 */ __ats_lab_307_0: // if (tmp1326 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_307_1: // if (tmp1324 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_307_2: tmp1325 = err4_128 (tmp1295, tmp1296) ; break ; } while (0) ; /* tmp1333 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; if (arg2) { tmp1334 = 0 ; } else { if (arg1) { tmp1334 = 1 ; } else { tmp1334 = 0 ; } /* end of [if] */ } /* end of [if] */ tmp1335 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make (tmp1295, arg4, tmp1296, arg0, tmp1334, tmp1300, tmp1311, tmp1323, tmp1325) ; /* tmp1336 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon (tmp1335) ; if (arg2) { /* empty */ } else { /* tmp1338 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datcontyp (tmp1335) ; if (arg1) { /* tmp1337 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_datconptr (tmp1335) ; } else { /* empty */ } /* end of [if] */ } /* end of [if] */ tmp1270 = tmp1335 ; return (tmp1270) ; } /* end of [d1atcon_tr_124] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 73091(line=2338, offs=5) -- 73499(line=2352, offs=4) */ ATSstaticdec() ats_ptr_type d1atconlst_tr_130 (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1339) ; ATSlocal (ats_ptr_type, tmp1340) ; ATSlocal (ats_ptr_type, tmp1341) ; ATSlocal (ats_ptr_type, tmp1342) ; ATSlocal (ats_ptr_type, tmp1343) ; __ats_lab_d1atconlst_tr_130: do { /* branch: __ats_lab_308 */ __ats_lab_308_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_309_0 ; } __ats_lab_308_1: tmp1340 = ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_0) ; tmp1341 = ats_caselptrlab_mac(anairiats_sum_1, arg5, atslab_1) ; tmp1342 = d1atcon_tr_124 (arg0, arg1, arg2, arg3, arg4, tmp1340) ; tmp1343 = d1atconlst_tr_130 (arg0, arg1, arg2, arg3, arg4, tmp1341) ; tmp1339 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1339, atslab_0, tmp1342) ; ats_selptrset_mac(anairiats_sum_1, tmp1339, atslab_1, tmp1343) ; break ; /* branch: __ats_lab_309 */ __ats_lab_309_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_309_1: tmp1339 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1339) ; } /* end of [d1atconlst_tr_130] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 73988(line=2367, offs=9) -- 74178(line=2370, offs=29) */ ATSstaticdec() ats_void_type aux_132 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1353) ; ATSlocal (ats_ptr_type, tmp1354) ; ATSlocal (ats_ptr_type, tmp1355) ; // ATSlocal_void (tmp1356) ; ATSlocal (ats_int_type, tmp1357) ; __ats_lab_aux_132: do { /* branch: __ats_lab_312 */ __ats_lab_312_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_313_0 ; } __ats_lab_312_1: tmp1354 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1355 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp1356 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag (tmp1354, arg0) ; tmp1357 = atspre_add_int_int (arg0, 1) ; arg0 = tmp1357 ; arg1 = tmp1355 ; goto __ats_lab_aux_132 ; // tail call break ; /* branch: __ats_lab_313 */ __ats_lab_313_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_313_1: break ; } while (0) ; return /* (tmp1353) */ ; } /* end of [aux_132] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 73551(line=2356, offs=4) -- 74834(line=2391, offs=4) */ ATSstaticdec() ats_void_type d1atdec_tr_131 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1344) ; ATSlocal (ats_ptr_type, tmp1345) ; ATSlocal (ats_ptr_type, tmp1346) ; ATSlocal (ats_ptr_type, tmp1347) ; ATSlocal (ats_bool_type, tmp1348) ; ATSlocal (ats_bool_type, tmp1349) ; ATSlocal (ats_ptr_type, tmp1350) ; ATSlocal (ats_ptr_type, tmp1351) ; ATSlocal (ats_ptr_type, tmp1352) ; // ATSlocal_void (tmp1358) ; ATSlocal (ats_ptr_type, tmp1359) ; ATSlocal (ats_ptr_type, tmp1360) ; ATSlocal (ats_ptr_type, tmp1361) ; ATSlocal (ats_ptr_type, tmp1362) ; ATSlocal (ats_ptr_type, tmp1363) ; ATSlocal (ats_bool_type, tmp1364) ; ATSlocal (ats_int_type, tmp1365) ; ATSlocal (ats_bool_type, tmp1366) ; ATSlocal (ats_int_type, tmp1367) ; ATSlocal (anairiats_rec_0, tmp1368) ; ATSlocal (ats_bool_type, tmp1369) ; ATSlocal (ats_int_type, tmp1370) ; ATSlocal (anairiats_rec_0, tmp1371) ; // ATSlocal_void (tmp1372) ; ATSlocal (ats_ptr_type, tmp1373) ; __ats_lab_d1atdec_tr_131: tmp1346 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (arg0) ; do { /* branch: __ats_lab_310 */ __ats_lab_310_0: if (((ats_sum_ptr_type)tmp1346)->tag != 1) { goto __ats_lab_311_0 ; } __ats_lab_310_1: tmp1347 = ats_caselptrlab_mac(anairiats_sum_4, tmp1346, atslab_1) ; tmp1345 = tmp1347 ; break ; /* branch: __ats_lab_311 */ __ats_lab_311_0: __ats_lab_311_1: tmp1345 = tmp1346 ; break ; } while (0) ; tmp1348 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp1345) ; tmp1349 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp1345) ; tmp1351 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg2), atslab_d1atdec_fil) ; tmp1352 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg2), atslab_d1atdec_con) ; tmp1350 = d1atconlst_tr_130 (arg0, tmp1348, tmp1349, arg1, tmp1351, tmp1352) ; /* tmp1358 = */ aux_132 (0, tmp1350) ; do { /* branch: __ats_lab_314 */ __ats_lab_314_0: if (tmp1350 == (ats_sum_ptr_type)0) { goto __ats_lab_315_0 ; } tmp1360 = ats_caselptrlab_mac(anairiats_sum_1, tmp1350, atslab_1) ; if (tmp1360 == (ats_sum_ptr_type)0) { goto __ats_lab_315_0 ; } tmp1361 = ats_caselptrlab_mac(anairiats_sum_1, tmp1360, atslab_1) ; if (tmp1361 != (ats_sum_ptr_type)0) { goto __ats_lab_315_0 ; } __ats_lab_314_1: tmp1362 = ats_caselptrlab_mac(anairiats_sum_1, tmp1350, atslab_0) ; tmp1363 = ats_caselptrlab_mac(anairiats_sum_1, tmp1360, atslab_0) ; tmp1365 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (tmp1362) ; tmp1364 = atspre_eq_int_int (tmp1365, 0) ; if (tmp1364) { tmp1367 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (tmp1363) ; tmp1366 = atspre_gt_int_int (tmp1367, 0) ; if (tmp1366) { tmp1368.atslab_0 = tmp1362 ; tmp1368.atslab_1 = tmp1363 ; tmp1359 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp1359, atslab_0, tmp1368) ; } else { tmp1359 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } else { tmp1370 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (tmp1363) ; tmp1369 = atspre_eq_int_int (tmp1370, 0) ; if (tmp1369) { tmp1371.atslab_0 = tmp1363 ; tmp1371.atslab_1 = tmp1362 ; tmp1359 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp1359, atslab_0, tmp1371) ; } else { tmp1359 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_315 */ __ats_lab_315_0: __ats_lab_315_1: tmp1359 = (ats_sum_ptr_type)0 ; break ; } while (0) ; /* tmp1372 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_islst (arg0, tmp1359) ; tmp1373 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1373, atslab_0, tmp1350) ; /* tmp1344 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst (arg0, tmp1373) ; return /* (tmp1344) */ ; } /* end of [d1atdec_tr_131] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 75363(line=2414, offs=13) -- 75735(line=2423, offs=39) */ ATSstaticdec() ats_ptr_type aux_135 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1382) ; ATSlocal (anairiats_rec_27, tmp1383) ; ATSlocal (ats_ptr_type, tmp1384) ; ATSlocal (ats_ptr_type, tmp1385) ; ATSlocal (ats_ptr_type, tmp1386) ; ATSlocal (ats_ptr_type, tmp1387) ; ATSlocal (ats_ptr_type, tmp1388) ; ATSlocal (ats_ptr_type, tmp1389) ; __ats_lab_aux_135: do { /* branch: __ats_lab_318 */ __ats_lab_318_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_321_0 ; } __ats_lab_318_1: tmp1383 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_0) ; tmp1384 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_1) ; tmp1385 = ats_select_mac(tmp1383, atslab_0) ; do { /* branch: __ats_lab_319 */ __ats_lab_319_0: if (tmp1385 == (ats_sum_ptr_type)0) { goto __ats_lab_320_0 ; } __ats_lab_319_1: tmp1386 = ats_caselptrlab_mac(anairiats_sum_5, tmp1385, atslab_0) ; tmp1388 = ats_select_mac(tmp1383, atslab_1) ; tmp1387 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp1386, tmp1388) ; tmp1389 = aux_135 (tmp1384) ; tmp1382 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1382, atslab_0, tmp1387) ; ats_selptrset_mac(anairiats_sum_1, tmp1382, atslab_1, tmp1389) ; break ; /* branch: __ats_lab_320 */ __ats_lab_320_0: // if (tmp1385 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_320_1: arg0 = tmp1384 ; goto __ats_lab_aux_135 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_321 */ __ats_lab_321_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_321_1: tmp1382 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1382) ; } /* end of [aux_135] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 75893(line=2430, offs=13) -- 76069(line=2434, offs=39) */ ATSstaticdec() ats_ptr_type aux_136 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1392) ; ATSlocal (anairiats_rec_27, tmp1393) ; ATSlocal (ats_ptr_type, tmp1394) ; ATSlocal (ats_ptr_type, tmp1395) ; ATSlocal (ats_ptr_type, tmp1396) ; __ats_lab_aux_136: do { /* branch: __ats_lab_324 */ __ats_lab_324_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_325_0 ; } __ats_lab_324_1: tmp1393 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_0) ; tmp1394 = ats_caselptrlab_mac(anairiats_sum_30, arg0, atslab_1) ; tmp1395 = ats_select_mac(tmp1393, atslab_1) ; tmp1396 = aux_136 (tmp1394) ; tmp1392 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1392, atslab_0, tmp1395) ; ats_selptrset_mac(anairiats_sum_1, tmp1392, atslab_1, tmp1396) ; break ; /* branch: __ats_lab_325 */ __ats_lab_325_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_325_1: tmp1392 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1392) ; } /* end of [aux_136] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 75083(line=2405, offs=9) -- 76426(line=2447, offs=8) */ ATSstaticdec() ats_void_type aux_134 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1377) ; ATSlocal (ats_ptr_type, tmp1378) ; ATSlocal (ats_ptr_type, tmp1379) ; ATSlocal (ats_ptr_type, tmp1380) ; ATSlocal (ats_ptr_type, tmp1381) ; ATSlocal (ats_ptr_type, tmp1390) ; ATSlocal (ats_ptr_type, tmp1391) ; ATSlocal (ats_ptr_type, tmp1397) ; ATSlocal (ats_ptr_type, tmp1398) ; ATSlocal (ats_ptr_type, tmp1399) ; ATSlocal (ats_ptr_type, tmp1400) ; ATSlocal (ats_ptr_type, tmp1401) ; ATSlocal (ats_ptr_type, tmp1402) ; // ATSlocal_void (tmp1403) ; ATSlocal (ats_ptr_type, tmp1404) ; ATSlocal (anairiats_rec_36, tmp1405) ; __ats_lab_aux_134: tmp1379 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1atdec_arg) ; do { /* branch: __ats_lab_316 */ __ats_lab_316_0: if (tmp1379 == (ats_sum_ptr_type)0) { goto __ats_lab_317_0 ; } __ats_lab_316_1: tmp1380 = ats_caselptrlab_mac(anairiats_sum_5, tmp1379, atslab_0) ; tmp1381 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atarglst_tr (tmp1380) ; tmp1378 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1378, atslab_0, tmp1381) ; break ; /* branch: __ats_lab_317 */ __ats_lab_317_0: // if (tmp1379 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_317_1: tmp1378 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_322 */ __ats_lab_322_0: if (tmp1378 == (ats_sum_ptr_type)0) { goto __ats_lab_323_0 ; } __ats_lab_322_1: tmp1391 = ats_caselptrlab_mac(anairiats_sum_5, tmp1378, atslab_0) ; tmp1390 = aux_135 (tmp1391) ; break ; /* branch: __ats_lab_323 */ __ats_lab_323_0: // if (tmp1378 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_323_1: tmp1390 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_326 */ __ats_lab_326_0: if (tmp1378 == (ats_sum_ptr_type)0) { goto __ats_lab_327_0 ; } __ats_lab_326_1: tmp1398 = ats_caselptrlab_mac(anairiats_sum_5, tmp1378, atslab_0) ; tmp1399 = aux_136 (tmp1398) ; tmp1397 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1397, atslab_0, tmp1399) ; break ; /* branch: __ats_lab_327 */ __ats_lab_327_0: // if (tmp1378 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_327_1: tmp1397 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp1401 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1atdec_sym) ; tmp1402 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_d1atdec_loc) ; tmp1400 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_make_dat (tmp1401, tmp1402, tmp1397, env0, tmp1378) ; /* tmp1403 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1400) ; tmp1405.atslab_0 = arg0 ; tmp1405.atslab_1 = tmp1400 ; tmp1405.atslab_2 = tmp1390 ; tmp1404 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp1404, atslab_0, tmp1405) ; ats_selptrset_mac(anairiats_sum_37, tmp1404, atslab_1, ats_ptrget_mac(ats_ptr_type, arg1)) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1404 ; return /* (tmp1377) */ ; } /* end of [aux_134] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_134_closure_type ; ats_void_type aux_134_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) { aux_134 (((aux_134_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type aux_134_closure_init (aux_134_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_134_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_134_closure_make (ats_ptr_type env0) { aux_134_closure_type *p_clo = ATS_MALLOC(sizeof(aux_134_closure_type)) ; aux_134_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 76454(line=2449, offs=9) -- 76628(line=2453, offs=26) */ ATSstaticdec() ats_void_type auxlst_137 (ats_ptr_type env0, ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1406) ; ATSlocal (ats_ptr_type, tmp1407) ; ATSlocal (ats_ptr_type, tmp1408) ; // ATSlocal_void (tmp1409) ; __ats_lab_auxlst_137: do { /* branch: __ats_lab_328 */ __ats_lab_328_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_329_0 ; } __ats_lab_328_1: tmp1407 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1408 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp1409 = */ aux_134 (env0, tmp1407, arg1) ; arg0 = tmp1408 ; arg1 = arg1 ; goto __ats_lab_auxlst_137 ; // tail call break ; /* branch: __ats_lab_329 */ __ats_lab_329_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_329_1: break ; } while (0) ; return /* (tmp1406) */ ; } /* end of [auxlst_137] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } auxlst_137_closure_type ; ats_void_type auxlst_137_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1) { auxlst_137 (((auxlst_137_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_137_closure_init (auxlst_137_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_137_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_137_closure_make (ats_ptr_type env0) { auxlst_137_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_137_closure_type)) ; auxlst_137_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 76773(line=2461, offs=9) -- 77081(line=2471, offs=8) */ ATSstaticdec() ats_void_type aux_138 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1412) ; ATSlocal (ats_ptr_type, tmp1413) ; ATSlocal (ats_ptr_type, tmp1414) ; ATSlocal (ats_ptr_type, tmp1415) ; ATSlocal (ats_ptr_type, tmp1416) ; // ATSlocal_void (tmp1417) ; __ats_lab_aux_138: do { /* branch: __ats_lab_330 */ __ats_lab_330_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_331_0 ; } __ats_lab_330_1: tmp1413 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1414 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1416 = (ats_sum_ptr_type)0 ; tmp1415 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1expdef_tr (tmp1416, tmp1413) ; /* tmp1417 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_add_scst (tmp1415) ; arg0 = tmp1414 ; goto __ats_lab_aux_138 ; // tail call break ; /* branch: __ats_lab_331 */ __ats_lab_331_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_331_1: break ; } while (0) ; return /* (tmp1412) */ ; } /* end of [aux_138] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 77130(line=2474, offs=7) -- 77324(line=2478, offs=36) */ ATSstaticdec() ats_ptr_type aux_139 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1419) ; ATSlocal (anairiats_rec_36, tmp1420) ; ATSlocal (ats_ptr_type, tmp1421) ; // ATSlocal_void (tmp1422) ; ATSlocal (ats_ptr_type, tmp1423) ; ATSlocal (ats_ptr_type, tmp1424) ; ATSlocal (ats_ptr_type, tmp1425) ; ATSlocal (ats_ptr_type, tmp1426) ; ATSlocal (ats_ptr_type, tmp1427) ; __ats_lab_aux_139: do { /* branch: __ats_lab_332 */ __ats_lab_332_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_333_0 ; } __ats_lab_332_1: tmp1420 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_0) ; tmp1421 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_1) ; tmp1423 = ats_select_mac(tmp1420, atslab_1) ; tmp1424 = ats_select_mac(tmp1420, atslab_2) ; tmp1425 = ats_select_mac(tmp1420, atslab_0) ; /* tmp1422 = */ d1atdec_tr_131 (tmp1423, tmp1424, tmp1425) ; tmp1426 = ats_select_mac(tmp1420, atslab_1) ; tmp1427 = aux_139 (tmp1421) ; tmp1419 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1419, atslab_0, tmp1426) ; ats_selptrset_mac(anairiats_sum_1, tmp1419, atslab_1, tmp1427) ; break ; /* branch: __ats_lab_333 */ __ats_lab_333_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_333_1: tmp1419 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1419) ; } /* end of [aux_139] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 74883(line=2394, offs=15) -- 77371(line=2482, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atdeclst_tr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1374) ; ATSlocal (ats_ptr_type, tmp1375) ; ATSlocal (ats_ptr_type, tmp1376) ; // ATSlocal_void (tmp1410) ; ATSlocal (ats_ptr_type, tmp1411) ; // ATSlocal_void (tmp1418) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atdeclst_tr: tmp1375 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_datakind (arg0) ; /* ats_ptr_type tmp1376 ; */ tmp1376 = (ats_sum_ptr_type)0 ; /* tmp1410 = */ auxlst_137 (tmp1375, arg1, (&tmp1376)) ; tmp1411 = tmp1376 ; /* tmp1418 = */ aux_138 (arg2) ; tmp1374 = aux_139 (tmp1411) ; return (tmp1374) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1atdeclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 77472(line=2487, offs=4) -- 78043(line=2502, offs=4) */ ATSstaticdec() ats_ptr_type e1xndec_tr_140 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1428) ; ATSlocal (ats_ptr_type, tmp1429) ; ATSlocal (ats_ptr_type, tmp1430) ; ATSlocal (ats_ptr_type, tmp1431) ; // ATSlocal_void (tmp1432) ; // ATSlocal_void (tmp1433) ; ATSlocal (ats_ptr_type, tmp1434) ; ATSlocal (ats_ptr_type, tmp1435) ; ATSlocal (ats_int_type, tmp1436) ; ATSlocal (ats_ptr_type, tmp1437) ; ATSlocal (ats_ptr_type, tmp1438) ; // ATSlocal_void (tmp1439) ; ATSlocal (ats_ptr_type, tmp1440) ; ATSlocal (ats_ptr_type, tmp1441) ; // ATSlocal_void (tmp1442) ; // ATSlocal_void (tmp1443) ; __ats_lab_e1xndec_tr_140: tmp1429 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_loc) ; tmp1430 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_fil) ; tmp1431 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_sym) ; /* tmp1432 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_push () ; /* tmp1433 = ats_selsin_mac(tmp1432, atslab_1) */ ; tmp1435 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_qua) ; tmp1434 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__s1qualstlst_tr (tmp1435) ; tmp1436 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_npf) ; tmp1437 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_43, arg1), atslab_e1xndec_arg) ; tmp1438 = s1explst_tr_dn_viewt0ype_38 (tmp1437) ; /* tmp1439 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pop () ; tmp1441 = (ats_sum_ptr_type)0 ; tmp1440 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make (tmp1429, tmp1430, tmp1431, arg0, 1, tmp1434, tmp1436, tmp1438, tmp1441) ; /* tmp1442 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag (tmp1440, -1) ; /* tmp1443 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_add_dcon (tmp1440) ; tmp1428 = tmp1440 ; return (tmp1428) ; } /* end of [e1xndec_tr_140] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 78072(line=2504, offs=5) -- 78325(line=2511, offs=4) */ ATSstaticdec() ats_ptr_type d2conlst_revapp_141 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1444) ; ATSlocal (ats_ptr_type, tmp1445) ; ATSlocal (ats_ptr_type, tmp1446) ; ATSlocal (ats_ptr_type, tmp1447) ; __ats_lab_d2conlst_revapp_141: do { /* branch: __ats_lab_334 */ __ats_lab_334_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_335_0 ; } __ats_lab_334_1: tmp1445 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1446 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1447 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1447, atslab_0, tmp1445) ; ats_selptrset_mac(anairiats_sum_1, tmp1447, atslab_1, arg1) ; arg0 = tmp1446 ; arg1 = tmp1447 ; goto __ats_lab_d2conlst_revapp_141 ; // tail call break ; /* branch: __ats_lab_335 */ __ats_lab_335_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_335_1: tmp1444 = arg1 ; break ; } while (0) ; return (tmp1444) ; } /* end of [d2conlst_revapp_141] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 78407(line=2515, offs=7) -- 78637(line=2522, offs=31) */ ATSstaticdec() ats_ptr_type aux_143 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1449) ; ATSlocal (ats_ptr_type, tmp1450) ; ATSlocal (ats_ptr_type, tmp1451) ; ATSlocal (ats_ptr_type, tmp1452) ; ATSlocal (ats_ptr_type, tmp1453) ; __ats_lab_aux_143: do { /* branch: __ats_lab_336 */ __ats_lab_336_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_337_0 ; } __ats_lab_336_1: tmp1450 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1451 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1452 = e1xndec_tr_140 (arg0, tmp1450) ; tmp1453 = aux_143 (arg0, tmp1451) ; tmp1449 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1449, atslab_0, tmp1452) ; ats_selptrset_mac(anairiats_sum_1, tmp1449, atslab_1, tmp1453) ; break ; /* branch: __ats_lab_337 */ __ats_lab_337_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_337_1: tmp1449 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1449) ; } /* end of [aux_143] */ /* // /home/hwxi/research/Anairiats/src/ats_trans2_sta.dats: 78379(line=2514, offs=15) -- 78914(line=2530, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__e1xndeclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1448) ; ATSlocal (ats_ptr_type, tmp1454) ; ATSlocal (ats_ptr_type, tmp1455) ; ATSlocal (ats_ptr_type, tmp1456) ; ATSlocal (ats_ptr_type, tmp1457) ; ATSlocal (ats_ptr_type, tmp1458) ; // ATSlocal_void (tmp1459) ; ATSlocal (ats_ptr_type, tmp1460) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__e1xndeclst_tr: tmp1454 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype) ; tmp1455 = aux_143 (tmp1454, arg0) ; tmp1457 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst (tmp1454) ; do { /* branch: __ats_lab_338 */ __ats_lab_338_0: if (tmp1457 == (ats_sum_ptr_type)0) { goto __ats_lab_339_0 ; } __ats_lab_338_1: tmp1458 = ats_caselptrlab_mac(anairiats_sum_5, tmp1457, atslab_0) ; tmp1456 = d2conlst_revapp_141 (tmp1455, tmp1458) ; break ; /* branch: __ats_lab_339 */ __ats_lab_339_0: // if (tmp1457 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_339_1: tmp1456 = tmp1455 ; break ; } while (0) ; tmp1460 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp1460, atslab_0, tmp1456) ; /* tmp1459 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_conlst (tmp1454, tmp1460) ; tmp1448 = tmp1455 ; return (tmp1448) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__e1xndeclst_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDarrow_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__SPSIDnone_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_sta_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_set_fun_sats.c0000664000175000017500000000177612223166160021614 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_set_fun_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_map_lin_dats.c0000664000175000017500000001145312223166160021542 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include ats_bool_type atsopt_map_lin_dice ( ats_int_type m, ats_int_type n ) { double r = drand48 (); return ((m+n)*r < m) ? ats_true_bool : ats_false_bool ; } // end of [atsopt_map_lin_dice] /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__sasp__map_vt = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9534(line=326, offs=10) -- 9562(line=326, offs=38) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make: tmp1 = (ats_sum_ptr_type)0 ; tmp0 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp0, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp0, atslab_1, tmp1) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0.tag = 0 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_map_lin_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_solve_sats.c0000664000175000017500000000301112223166160022727 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_solve_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_e1xp_eval_sats.c0000664000175000017500000000264512223166160022031 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_e1xp_eval_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_sats.c0000664000175000017500000001073512223166160021356 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_1 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISnone_1) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISsome_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISnone_1.tag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_debug_sats.c0000664000175000017500000000176412223166160021234 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_debug_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_scst_dats.c0000664000175000017500000003727512223166160023253 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isasp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_isasp) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__s2cstlst_env_token = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type aux_6 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp5) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03657_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ref_make_elt_03657_ats_ptr_type: /* ats_ptr_type tmp2 ; */ tmp2 = arg0 ; tmp1 = atspre_ref_make_elt_tsz ((&tmp2), sizeof(ats_ptr_type)) ; return (tmp1) ; } /* end of [ref_make_elt_03657_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 2096(line=66, offs=22) -- 2282(line=74, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_add: tmp8 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp7 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp7, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp7, atslab_1, tmp8) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp7 ; return /* (tmp6) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 2351(line=77, offs=25) -- 2547(line=85, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_addlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_addlst: tmp11 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append (arg0, tmp11) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp10 ; return /* (tmp9) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_addlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 2648(line=91, offs=3) -- 3366(line=115, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_bind_and_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_bool_type, tmp13) ; ATSlocal (ats_bool_type, tmp14) ; // ATSlocal_void (tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_bind_and_add: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isasp (arg1) ; tmp14 = atspre_neg_bool (tmp13) ; if (tmp14) { tmp16 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp16, atslab_0, arg2) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (arg1, tmp16) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_isasp (arg1, ats_true_bool) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_add (arg1) ; } else { /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp19 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp20 = */ atspre_prerr_string (ATSstrcst(": the static constant [")) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg1) ; /* tmp22 = */ atspre_prerr_string (ATSstrcst("] has already been assumed elsewhere.")) ; /* tmp23 = */ atspre_prerr_newline () ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_bind_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 3464(line=121, offs=3) -- 4187(line=142, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; // ATSlocal_void (tmp34) ; ATSlocal (ats_bool_type, tmp35) ; // ATSlocal_void (tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop: /* ats_int_type tmp25 ; */ tmp25 = 0 ; tmp26 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp27 = atspre_ref_get_view_ptr (statmp4) ; tmp28 = ats_selsin_mac(tmp27, atslab_1) ; tmp30 = ats_ptrget_mac(ats_ptr_type, tmp28) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp30 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_0, tmp30, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_0, tmp30, atslab_1) ; ATS_FREE(tmp30) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp31 ; ats_ptrget_mac(ats_ptr_type, tmp28) = tmp32 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp30 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp25 = 1 ; tmp33 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp28) = tmp33 ; break ; } while (0) ; tmp35 = atspre_gt_int_int (tmp25, 0) ; if (tmp35) { /* tmp36 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env_scst)")) ; /* tmp37 = */ atspre_prerr_string (ATSstrcst(": the_s2cstlst_env_pop: [the_s2cstlstlst] is empty.")) ; /* tmp38 = */ atspre_prerr_newline () ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp24 = tmp26 ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 4294(line=147, offs=7) -- 4683(line=161, offs=6) */ ATSstaticdec() ats_void_type aux_6 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_aux_6: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp42 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp44 = (ats_sum_ptr_type)0 ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp41, tmp44) ; arg0 = tmp42 ; goto __ats_lab_aux_6 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp40) */ ; } /* end of [aux_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 4266(line=146, offs=3) -- 4751(line=164, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind: tmp45 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop () ; /* tmp39 = */ aux_6 (tmp45) ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_scst.dats: 4850(line=169, offs=23) -- 5072(line=175, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () { /* local vardec */ // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push: tmp47 = atspre_ref_get_view_ptr (statmp4) ; tmp48 = ats_selsin_mac(tmp47, atslab_1) ; tmp49 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp50 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp50 ; tmp52 = ats_ptrget_mac(ats_ptr_type, tmp48) ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp51, atslab_0, tmp49) ; ats_selptrset_mac(anairiats_sum_0, tmp51, atslab_1, tmp52) ; ats_ptrget_mac(ats_ptr_type, tmp48) = tmp51 ; return /* (tmp46) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)0 ; statmp0 = ref_make_elt_03657_ats_ptr_type (statmp3) ; statmp5 = (ats_sum_ptr_type)0 ; statmp4 = ref_make_elt_03657_ats_ptr_type (statmp5) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_scst_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_stadyncst2_sats.c0000664000175000017500000000300612223166160022233 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_stadyncst2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp1_dats.c0000664000175000017500000022404712223166160021515 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_s0rtq_loc ; ats_ptr_type atslab_s0rtq_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_s1rt_loc ; ats_ptr_type atslab_s1rt_node ; } anairiats_rec_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_s1rtpol_loc ; ats_ptr_type atslab_s1rtpol_srt ; ats_int_type atslab_s1rtpol_pol ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_d1atarg_loc ; ats_ptr_type atslab_d1atarg_node ; } anairiats_rec_11 ; typedef struct { ats_ptr_type atslab_s1arg_loc ; ats_ptr_type atslab_s1arg_sym ; ats_ptr_type atslab_s1arg_srt ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_sp1at_loc ; ats_ptr_type atslab_sp1at_node ; } anairiats_rec_13 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_s1exparg_loc ; ats_ptr_type atslab_s1exparg_node ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_s1rtext_loc ; ats_ptr_type atslab_s1rtext_node ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_s1qua_loc ; ats_ptr_type atslab_s1qua_node ; } anairiats_rec_21 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTqid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTtup_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGidsrt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__SP1Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qvars_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eapp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Echar_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eexi_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eextype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eimp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eint_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Einvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elam_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eqid_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eread_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etop_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etrans_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyarr_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_ext_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup2_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Euni_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eunion_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGseq_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0rtq_none) () ; ATSextern_fun(ats_ptr_type, s0taq_none) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_arrow) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_true) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_false) ; /* internal function declarations */ static ats_bool_type s0rtq_is_none_0 (ats_ptr_type arg0) ; static ats_ptr_type err_41 (ats_ptr_type arg0) ; static ats_ptr_type aux_59 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_59_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_59_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_list_60 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_list_60_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_list_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_63 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp26) ; ATSstatic (ats_ptr_type, statmp27) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2069(line=66, offs=4) -- 2169(line=67, offs=63) */ ATSstaticdec() ats_bool_type s0rtq_is_none_0 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_s0rtq_is_none_0: tmp3 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_s0rtq_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp3)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp2 = ats_false_bool ; break ; } while (0) ; return (tmp2) ; } /* end of [s0rtq_is_none_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2211(line=72, offs=10) -- 2313(line=77, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app: tmp5 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp5)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp5, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp5, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp5, atslab_2, arg3) ; tmp4 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp4, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp4, atslab_e1xp_node, tmp5) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2358(line=81, offs=3) -- 2414(line=83, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char: tmp7 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp7)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp7, atslab_0, arg1) ; tmp6 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp6, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp6, atslab_e1xp_node, tmp7) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2459(line=86, offs=12) -- 2524(line=88, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float: tmp9 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp9)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp9, atslab_0, arg1) ; tmp8 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp8, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp8, atslab_e1xp_node, tmp9) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2568(line=91, offs=10) -- 2632(line=93, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide: tmp11 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp11)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp11, atslab_0, arg1) ; tmp10 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp10, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp10, atslab_e1xp_node, tmp11) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2653(line=96, offs=10) -- 2720(line=98, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int: tmp13 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp13)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp13, atslab_0, arg1) ; tmp12 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp12, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp12, atslab_e1xp_node, tmp13) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2742(line=101, offs=11) -- 2809(line=103, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_list: tmp15 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp15)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp15, atslab_0, arg1) ; tmp14 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp14, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp14, atslab_e1xp_node, tmp15) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2833(line=106, offs=13) -- 2905(line=108, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string: tmp17 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp17)->tag = 6 ; ats_selptrset_mac(anairiats_sum_5, tmp17, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp17, atslab_1, arg2) ; tmp16 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp16, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp16, atslab_e1xp_node, tmp17) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 2928(line=111, offs=12) -- 2981(line=113, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_undef (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_undef: tmp19 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; tmp18 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp18, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp18, atslab_e1xp_node, tmp19) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_undef] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3027(line=116, offs=12) -- 3088(line=118, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp: tmp21 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp21)->tag = 8 ; ats_selptrset_mac(anairiats_sum_4, tmp21, atslab_0, arg1) ; tmp20 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp20, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp20, atslab_e1xp_node, tmp21) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3133(line=121, offs=11) -- 3185(line=123, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none: tmp23 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; tmp22 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp22, atslab_e1xp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp22, atslab_e1xp_node, tmp23) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3252(line=128, offs=3) -- 3298(line=128, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_true () { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_true: tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy, ATSstrcst("1")) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_true] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3322(line=130, offs=3) -- 3368(line=130, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_false () { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_false: tmp25 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy, ATSstrcst("0")) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_false] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3539(line=141, offs=22) -- 3609(line=143, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_arrow (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_arrow: tmp29 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp29)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp29, atslab_0, statmp0) ; ats_selptrset_mac(anairiats_sum_8, tmp29, atslab_1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; tmp28 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp28, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp28, atslab_s1rt_node, tmp29) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_arrow] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3676(line=147, offs=15) -- 3820(line=152, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_is_arrow (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_bool_type, tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_is_arrow: tmp31 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s1rt_node) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp31)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_8, tmp31, atslab_0) ; tmp33 = ats_caselptrlab_mac(anairiats_sum_8, tmp31, atslab_1) ; tmp34 = s0rtq_is_none_0 (tmp32) ; if (tmp34) { tmp30 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp33, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; } else { tmp30 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp30 = ats_false_bool ; break ; } while (0) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_is_arrow] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3867(line=155, offs=20) -- 3954(line=156, offs=61) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app: tmp36 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp36)->tag = 0 ; ats_selptrset_mac(anairiats_sum_8, tmp36, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp36, atslab_1, arg2) ; tmp35 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp35, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp35, atslab_s1rt_node, tmp36) ; return (tmp35) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 3975(line=158, offs=20) -- 4122(line=161, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_fun (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_fun: tmp40 = (ats_sum_ptr_type)0 ; tmp39 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp39, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_9, tmp39, atslab_1, tmp40) ; tmp38 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp38, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp38, atslab_1, tmp39) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_arrow (arg0) ; tmp41 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp41)->tag = 0 ; ats_selptrset_mac(anairiats_sum_8, tmp41, atslab_0, tmp42) ; ats_selptrset_mac(anairiats_sum_8, tmp41, atslab_1, tmp38) ; tmp37 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp37, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp37, atslab_s1rt_node, tmp41) ; return (tmp37) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4143(line=163, offs=20) -- 4212(line=165, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide: tmp44 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp44)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp44, atslab_0, statmp0) ; ats_selptrset_mac(anairiats_sum_8, tmp44, atslab_1, arg1) ; tmp43 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp43, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp43, atslab_s1rt_node, tmp44) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4234(line=167, offs=21) -- 4373(line=169, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_list: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } tmp46 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; if (tmp46 != (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp45 = tmp47 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp48 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp48)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp48, atslab_0, arg1) ; tmp45 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp45, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp45, atslab_s1rt_node, tmp48) ; break ; } while (0) ; return (tmp45) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_list] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4394(line=171, offs=20) -- 4459(line=172, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_qid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_qid: tmp50 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp50)->tag = 2 ; ats_selptrset_mac(anairiats_sum_8, tmp50, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp50, atslab_1, arg2) ; tmp49 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp49, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp49, atslab_s1rt_node, tmp50) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4480(line=174, offs=20) -- 4540(line=175, offs=47) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_tup (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_tup: tmp52 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp52)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp52, atslab_0, arg1) ; tmp51 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp51, atslab_s1rt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp51, atslab_s1rt_node, tmp52) ; return (tmp51) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4586(line=179, offs=24) -- 4663(line=181, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtpol_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtpol_make: tmp53 = ATS_MALLOC(sizeof(anairiats_rec_10)) ; ats_selptrset_mac(anairiats_rec_10, tmp53, atslab_s1rtpol_loc, arg0) ; ats_selptrset_mac(anairiats_rec_10, tmp53, atslab_s1rtpol_srt, arg1) ; ats_selptrset_mac(anairiats_rec_10, tmp53, atslab_s1rtpol_pol, arg2) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtpol_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4708(line=185, offs=23) -- 4776(line=187, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_srt: tmp55 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp55)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp55, atslab_0, arg1) ; tmp54 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp54, atslab_d1atarg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp54, atslab_d1atarg_node, tmp55) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4802(line=189, offs=25) -- 4882(line=191, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_idsrt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_idsrt: tmp57 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp57)->tag = 1 ; ats_selptrset_mac(anairiats_sum_8, tmp57, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp57, atslab_1, arg2) ; tmp56 = ATS_MALLOC(sizeof(anairiats_rec_11)) ; ats_selptrset_mac(anairiats_rec_11, tmp56, atslab_d1atarg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_11, tmp56, atslab_d1atarg_node, tmp57) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_idsrt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 4926(line=195, offs=22) -- 4996(line=197, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1arg_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1arg_make: tmp58 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp58, atslab_s1arg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp58, atslab_s1arg_sym, arg1) ; ats_selptrset_mac(anairiats_rec_12, tmp58, atslab_s1arg_srt, arg2) ; return (tmp58) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1arg_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5018(line=199, offs=21) -- 5095(line=201, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__sp1at_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__sp1at_con: tmp60 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp60, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_14, tmp60, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_14, tmp60, atslab_2, arg3) ; tmp59 = ATS_MALLOC(sizeof(anairiats_rec_13)) ; ats_selptrset_mac(anairiats_rec_13, tmp59, atslab_sp1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_13, tmp59, atslab_sp1at_node, tmp60) ; return (tmp59) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__sp1at_con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5139(line=205, offs=21) -- 5209(line=207, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ann (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ann: tmp62 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp62)->tag = 0 ; ats_selptrset_mac(anairiats_sum_8, tmp62, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp62, atslab_1, arg2) ; tmp61 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp61, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp61, atslab_s1exp_node, tmp62) ; return (tmp61) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5232(line=209, offs=21) -- 5284(line=210, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_any (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_any: tmp64 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1) ; tmp63 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp63, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp63, atslab_s1exp_node, tmp64) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_any] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5307(line=212, offs=21) -- 5397(line=214, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app: tmp66 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp66)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp66, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp66, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp66, atslab_2, arg3) ; tmp65 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp65, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp65, atslab_s1exp_node, tmp66) ; return (tmp65) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5420(line=216, offs=22) -- 5475(line=217, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char: tmp68 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp68)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp68, atslab_0, arg1) ; tmp67 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp67, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp67, atslab_s1exp_node, tmp68) ; return (tmp67) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5497(line=219, offs=21) -- 5589(line=221, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_exi (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_exi: tmp70 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp70)->tag = 4 ; ats_selptrset_mac(anairiats_sum_16, tmp70, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp70, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp70, atslab_2, arg3) ; tmp69 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp69, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp69, atslab_s1exp_node, tmp70) ; return (tmp69) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_exi] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5614(line=224, offs=14) -- 5695(line=226, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_extype (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_extype: tmp72 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp72)->tag = 5 ; ats_selptrset_mac(anairiats_sum_8, tmp72, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp72, atslab_1, arg2) ; tmp71 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp71, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp71, atslab_s1exp_node, tmp72) ; return (tmp71) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5742(line=228, offs=21) -- 5819(line=230, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide: tmp74 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp74)->tag = 11 ; ats_selptrset_mac(anairiats_sum_8, tmp74, atslab_0, statmp1) ; ats_selptrset_mac(anairiats_sum_8, tmp74, atslab_1, arg1) ; tmp73 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp73, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp73, atslab_s1exp_node, tmp74) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5841(line=232, offs=21) -- 5943(line=234, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp: tmp76 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ((ats_sum_ptr_type)tmp76)->tag = 6 ; ats_selptrset_mac(anairiats_sum_17, tmp76, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_17, tmp76, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_17, tmp76, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_17, tmp76, atslab_3, arg4) ; tmp75 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp75, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp75, atslab_s1exp_node, tmp76) ; return (tmp75) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 5965(line=236, offs=21) -- 6031(line=237, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int: tmp78 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp78)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp78, atslab_0, arg1) ; tmp77 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp77, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp77, atslab_s1exp_node, tmp78) ; return (tmp77) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 6055(line=239, offs=23) -- 6133(line=241, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar: tmp80 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp80)->tag = 8 ; ats_selptrset_mac(anairiats_sum_18, tmp80, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp80, atslab_1, arg2) ; tmp79 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp79, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp79, atslab_s1exp_node, tmp80) ; return (tmp79) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 6155(line=243, offs=21) -- 6237(line=245, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_lam (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_lam: tmp82 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp82)->tag = 9 ; ats_selptrset_mac(anairiats_sum_2, tmp82, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp82, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp82, atslab_2, arg3) ; tmp81 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp81, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp81, atslab_s1exp_node, tmp82) ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 6260(line=247, offs=22) -- 6569(line=257, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } tmp84 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; if (tmp84 != (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp83 = tmp85 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp86 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp86)->tag = 10 ; ats_selptrset_mac(anairiats_sum_18, tmp86, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_18, tmp86, atslab_1, arg1) ; tmp83 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp83, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp83, atslab_s1exp_node, tmp86) ; break ; } while (0) ; return (tmp83) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 6632(line=261, offs=3) -- 6799(line=266, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_int_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2: tmp88 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg1, arg2) ; tmp90 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp90)->tag = 10 ; ats_selptrset_mac(anairiats_sum_18, tmp90, atslab_0, tmp88) ; ats_selptrset_mac(anairiats_sum_18, tmp90, atslab_1, tmp89) ; tmp87 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp87, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp87, atslab_s1exp_node, tmp90) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 7124(line=282, offs=21) -- 7195(line=283, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_qid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_qid: tmp92 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp92)->tag = 11 ; ats_selptrset_mac(anairiats_sum_8, tmp92, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp92, atslab_1, arg2) ; tmp91 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp91, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp91, atslab_s1exp_node, tmp92) ; return (tmp91) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 7241(line=286, offs=6) -- 7428(line=290, offs=6) */ ATSstaticdec() ats_ptr_type err_41 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; __ats_lab_err_41: /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp96 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; /* tmp97 = */ atspre_prerr_string (ATSstrcst(": [read@] requires exactly two arguments.")) ; /* tmp98 = */ atspre_prerr_newline () ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp94) ; } /* end of [err_41] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 7219(line=285, offs=22) -- 7724(line=300, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_read (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_read: tmp99 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg1), atslab_s1exp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp99)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_8_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_18, tmp99, atslab_1) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } tmp101 = ats_caselptrlab_mac(anairiats_sum_9, tmp100, atslab_1) ; if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } tmp102 = ats_caselptrlab_mac(anairiats_sum_9, tmp101, atslab_1) ; if (tmp102 != (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_9, tmp100, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_9, tmp101, atslab_0) ; tmp105 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp105)->tag = 12 ; ats_selptrset_mac(anairiats_sum_8, tmp105, atslab_0, tmp103) ; ats_selptrset_mac(anairiats_sum_8, tmp105, atslab_1, tmp104) ; tmp93 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp93, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp93, atslab_s1exp_node, tmp105) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: tmp93 = err_41 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp93 = err_41 (arg0) ; break ; } while (0) ; return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_read] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 7925(line=310, offs=21) -- 7995(line=312, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top: tmp107 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp107)->tag = 13 ; ats_selptrset_mac(anairiats_sum_18, tmp107, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp107, atslab_1, arg2) ; tmp106 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp106, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp106, atslab_s1exp_node, tmp107) ; return (tmp106) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8019(line=314, offs=23) -- 8095(line=316, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_trans (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_trans: tmp109 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp109)->tag = 14 ; ats_selptrset_mac(anairiats_sum_8, tmp109, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp109, atslab_1, arg2) ; tmp108 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp108, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp108, atslab_s1exp_node, tmp109) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_trans] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8119(line=318, offs=23) -- 8211(line=320, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyarr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyarr: tmp111 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp111)->tag = 15 ; ats_selptrset_mac(anairiats_sum_8, tmp111, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp111, atslab_1, arg2) ; tmp110 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp110, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp110, atslab_s1exp_node, tmp111) ; return (tmp110) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8235(line=322, offs=23) -- 8313(line=324, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec: tmp113 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp113)->tag = 16 ; ats_selptrset_mac(anairiats_sum_18, tmp113, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp113, atslab_1, arg2) ; tmp112 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp112, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp112, atslab_s1exp_node, tmp113) ; return (tmp112) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8341(line=326, offs=27) -- 8423(line=328, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec_ext (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec_ext: tmp115 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp115)->tag = 17 ; ats_selptrset_mac(anairiats_sum_8, tmp115, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp115, atslab_1, arg2) ; tmp114 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp114, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp114, atslab_s1exp_node, tmp115) ; return (tmp114) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec_ext] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8447(line=330, offs=23) -- 8523(line=332, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup: tmp117 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp117)->tag = 18 ; ats_selptrset_mac(anairiats_sum_18, tmp117, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp117, atslab_1, arg2) ; tmp116 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp116, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp116, atslab_s1exp_node, tmp117) ; return (tmp116) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8548(line=334, offs=24) -- 8641(line=336, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup2 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup2: tmp119 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp119)->tag = 19 ; ats_selptrset_mac(anairiats_sum_16, tmp119, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp119, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp119, atslab_2, arg3) ; tmp118 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp118, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp118, atslab_s1exp_node, tmp119) ; return (tmp118) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8663(line=338, offs=21) -- 8735(line=340, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni: tmp121 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp121)->tag = 20 ; ats_selptrset_mac(anairiats_sum_8, tmp121, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp121, atslab_1, arg2) ; tmp120 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp120, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp120, atslab_s1exp_node, tmp121) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8759(line=342, offs=23) -- 8835(line=344, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_union (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_union: tmp123 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp123)->tag = 21 ; ats_selptrset_mac(anairiats_sum_8, tmp123, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp123, atslab_1, arg2) ; tmp122 = ATS_MALLOC(sizeof(anairiats_rec_15)) ; ats_selptrset_mac(anairiats_rec_15, tmp122, atslab_s1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_15, tmp122, atslab_s1exp_node, tmp123) ; return (tmp122) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_union] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8881(line=348, offs=24) -- 8944(line=350, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_one (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_one: tmp125 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGone_0) ; tmp124 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp124, atslab_s1exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp124, atslab_s1exparg_node, tmp125) ; return (tmp124) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_one] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 8969(line=352, offs=24) -- 9032(line=354, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_all (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_all: tmp127 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGall_1) ; tmp126 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp126, atslab_s1exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp126, atslab_s1exparg_node, tmp127) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_all] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9057(line=356, offs=24) -- 9128(line=358, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_seq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_seq: tmp129 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp129)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp129, atslab_0, arg1) ; tmp128 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp128, atslab_s1exparg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp128, atslab_s1exparg_node, tmp129) ; return (tmp128) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exparg_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9173(line=362, offs=23) -- 9236(line=364, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_srt: tmp131 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp131)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp131, atslab_0, arg1) ; tmp130 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp130, atslab_s1rtext_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp130, atslab_s1rtext_node, tmp131) ; return (tmp130) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9260(line=366, offs=23) -- 9347(line=368, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_sub (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_sub: tmp133 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp133)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_2, arg3) ; tmp132 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp132, atslab_s1rtext_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp132, atslab_s1rtext_node, tmp133) ; return (tmp132) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_sub] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9633(line=386, offs=22) -- 9692(line=387, offs=47) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_prop (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_prop: tmp135 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp135)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp135, atslab_0, arg1) ; tmp134 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp134, atslab_s1qua_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp134, atslab_s1qua_node, tmp135) ; return (tmp134) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9715(line=389, offs=22) -- 9788(line=390, offs=55) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_vars (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_vars: tmp137 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp137)->tag = 1 ; ats_selptrset_mac(anairiats_sum_8, tmp137, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp137, atslab_1, arg2) ; tmp136 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp136, atslab_s1qua_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp136, atslab_s1qua_node, tmp137) ; return (tmp136) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_vars] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9859(line=396, offs=5) -- 10357(line=409, offs=8) */ ATSstaticdec() ats_ptr_type aux_59 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_char_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; __ats_lab_aux_59: tmp140 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_e1xp_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp140)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_2, tmp140, atslab_0) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_2, tmp140, atslab_1) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_2, tmp140, atslab_2) ; tmp144 = aux_59 (env0, tmp141) ; tmp145 = aux_list_60 (env0, tmp143) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (env0, tmp144, tmp142, tmp145) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp140)->tag != 3) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_4, tmp140, atslab_0) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide (env0, tmp146) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp140)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp147 = ats_caselptrlab_mac(anairiats_sum_3, tmp140, atslab_0) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char (env0, tmp147) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp140)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_4, tmp140, atslab_0) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int (env0, tmp148) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp140)->tag != 5) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_4, tmp140, atslab_0) ; tmp150 = aux_list_60 (env0, tmp149) ; tmp139 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list (env0, tmp150) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (env0) ; /* tmp152 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_staexp1)")) ; /* tmp153 = */ atspre_prerr_string (ATSstrcst(": illegal static expression.")) ; /* tmp154 = */ atspre_prerr_newline () ; /* tmp139 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp139) ; } /* end of [aux_59] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_59_closure_type ; ats_ptr_type aux_59_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_59 (((aux_59_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_59_closure_init (aux_59_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_59_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_59_closure_make (ats_ptr_type env0) { aux_59_closure_type *p_clo = ATS_MALLOC(sizeof(aux_59_closure_type)) ; aux_59_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 10393(line=412, offs=5) -- 10515(line=413, offs=65) */ ATSstaticdec() ats_ptr_type aux_list_60 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_aux_list_60: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp157 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp158 = aux_59 (env0, tmp156) ; tmp159 = aux_list_60 (env0, tmp157) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp155, atslab_0, tmp158) ; ats_selptrset_mac(anairiats_sum_9, tmp155, atslab_1, tmp159) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp155 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp155) ; } /* end of [aux_list_60] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_list_60_closure_type ; ats_ptr_type aux_list_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_list_60 (((aux_list_60_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_list_60_closure_init (aux_list_60_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_list_60_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_list_60_closure_make (ats_ptr_type env0) { aux_list_60_closure_type *p_clo = ATS_MALLOC(sizeof(aux_list_60_closure_type)) ; aux_list_60_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 9837(line=394, offs=27) -- 10553(line=418, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp: tmp138 = aux_59 (arg0, arg1) ; return (tmp138) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_make_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 10634(line=422, offs=31) -- 10806(line=426, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp160 = ats_false_bool ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; arg0 = tmp161 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp160 = ats_true_bool ; break ; } while (0) ; return (tmp160) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_is_none] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 10892(line=429, offs=7) -- 11253(line=439, offs=31) */ ATSstaticdec() ats_ptr_type aux_63 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_int_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; __ats_lab_aux_63: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp164 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_0) ; tmp165 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_1) ; tmp166 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp167)->tag = 1 ; ats_selptrset_mac(anairiats_sum_16, tmp167, atslab_0, tmp164) ; ats_selptrset_mac(anairiats_sum_16, tmp167, atslab_1, tmp165) ; ats_selptrset_mac(anairiats_sum_16, tmp167, atslab_2, arg1) ; arg0 = tmp166 ; arg1 = tmp167 ; goto __ats_lab_aux_63 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp169 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp169)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp169, atslab_0, arg1) ; arg0 = tmp168 ; arg1 = tmp169 ; goto __ats_lab_aux_63 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp163 = arg1 ; break ; } while (0) ; return (tmp163) ; } /* end of [aux_63] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1.dats: 10870(line=428, offs=31) -- 11340(line=443, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse: tmp170 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; tmp162 = aux_63 (arg0, tmp170) ; return (tmp162) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__wths1explst_reverse] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp26, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = s0rtq_none () ; statmp1 = s0taq_none () ; statmp26 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)statmp26)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, statmp26, atslab_0, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_true, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_true = statmp26 ; statmp27 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)statmp27)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, statmp27, atslab_0, 0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_false, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__v1al_false = statmp27 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp1_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_printf_c_lats_dats.c0000664000175000017500000020457512223166160022763 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ static inline ats_bool_type atsopt_printf_c_string_find_char ( ats_ptr_type s, ats_char_type c ) { void *ans = strchr (s, c) ; return (ans ? ats_true_bool : ats_false_bool) ; } // end of [ats_printf_c_string_find_char] /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_char_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_long_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_long_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_short_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_ptr_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_string_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_long_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_short_14) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_prerr_char) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_clo_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make) (ats_int_type) ; ATSextern_fun(ats_clo_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, lexbuf_make_infile) (ats_ptr_type) ; ATSextern_fun(ats_void_type, lexing_lexbuf_set) (ats_ptr_type) ; ATSextern_fun(ats_void_type, lexing_lexbuf_free) () ; ATSextern_fun(ats_int_type, lexing_engine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_char_type, lexeme_get) (ats_int_type) ; ATSextern_fun(ats_ptr_type, lexeme_string) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_printf_c_string_find_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__FLAGSTR) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__WIDTHSTR) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__PRECSTR) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__LENSTR) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__SPECHR) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string) ; /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type printf_c_argtypes_free_0 (ats_ptr_type arg0) ; static ats_ptr_type spec2type_translate_1 (ats_char_type arg0, ats_int_type arg1) ; static ats_bool_type flagstr_verify_2 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2) ; static ats_bool_type precstr_verify_3 (ats_char_type arg0, ats_ptr_type arg1) ; static ats_int_type lenstr_translate_4 (ats_ptr_type arg0) ; static ats_bool_type lenint_verify_5 (ats_char_type arg0, ats_int_type arg1) ; static ats_ptr_type printf_c_output_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_char_type arg4) ; static ats_ptr_type MAIN_lexing_error_7 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type MAIN__8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type FLAGSTR_lexing_error_9 () ; static ats_ptr_type WIDTHSTR_lexing_error_10 (ats_ptr_type arg0) ; static ats_ptr_type PRECSTR_lexing_error_11 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type LENSTR_lexing_error_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type SPECHR_lexing_error_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp96) ; ATSstatic (ats_clo_ptr_type, statmp97) ; ATSstatic (ats_ptr_type, statmp98) ; ATSstatic (ats_clo_ptr_type, statmp99) ; ATSstatic (ats_clo_ptr_type, statmp100) ; ATSstatic (ats_ptr_type, statmp105) ; ATSstatic (ats_clo_ptr_type, statmp106) ; ATSstatic (ats_ptr_type, statmp107) ; ATSstatic (ats_clo_ptr_type, statmp108) ; ATSstatic (ats_clo_ptr_type, statmp109) ; ATSstatic (ats_ptr_type, statmp113) ; ATSstatic (ats_clo_ptr_type, statmp114) ; ATSstatic (ats_ptr_type, statmp115) ; ATSstatic (ats_clo_ptr_type, statmp116) ; ATSstatic (ats_clo_ptr_type, statmp117) ; ATSstatic (ats_ptr_type, statmp121) ; ATSstatic (ats_clo_ptr_type, statmp122) ; ATSstatic (ats_ptr_type, statmp123) ; ATSstatic (ats_clo_ptr_type, statmp124) ; ATSstatic (ats_clo_ptr_type, statmp125) ; ATSstatic (ats_ptr_type, statmp129) ; ATSstatic (ats_clo_ptr_type, statmp130) ; ATSstatic (ats_ptr_type, statmp131) ; ATSstatic (ats_clo_ptr_type, statmp132) ; ATSstatic (ats_clo_ptr_type, statmp133) ; ATSstatic (ats_ptr_type, statmp137) ; ATSstatic (ats_clo_ptr_type, statmp138) ; ATSstatic (ats_ptr_type, statmp139) ; ATSstatic (ats_clo_ptr_type, statmp140) ; ATSstatic (ats_clo_ptr_type, statmp141) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 232(line=18, offs=5) -- 377(line=19, offs=79) */ ATSstaticdec() ats_void_type printf_c_argtypes_free_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_printf_c_argtypes_free_0: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp1 ; goto __ats_lab_printf_c_argtypes_free_0 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp0) */ ; } /* end of [printf_c_argtypes_free_0] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 1033(line=54, offs=4) -- 2324(line=88, offs=8) */ ATSstaticdec() ats_ptr_type spec2type_translate_1 (ats_char_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_bool_type, tmp3) ; ATSlocal (ats_bool_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_bool_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_bool_type, tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_bool_type, tmp11) ; ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_bool_type, tmp13) ; ATSlocal (ats_bool_type, tmp14) ; ATSlocal (ats_bool_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_bool_type, tmp17) ; ATSlocal (ats_bool_type, tmp18) ; ATSlocal (ats_bool_type, tmp19) ; ATSlocal (ats_bool_type, tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_spec2type_translate_1: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp3 = atspre_eq_char_char (arg0, 'a') ; if (!tmp3) { goto __ats_lab_3_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp4 = atspre_eq_char_char (arg0, 'A') ; if (!tmp4) { goto __ats_lab_4_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: tmp5 = atspre_eq_char_char (arg0, 'c') ; if (!tmp5) { goto __ats_lab_5_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_char_0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp7 = atspre_eq_char_char (arg0, 'd') ; if (tmp7) { tmp6 = ats_true_bool ; } else { tmp6 = atspre_eq_char_char (arg0, 'i') ; } /* end of [if] */ if (!tmp6) { goto __ats_lab_11_1 ; } do { /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp8 = atspre_eq_int_int (arg1, 1) ; if (!tmp8) { goto __ats_lab_7_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_6) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp9 = atspre_eq_int_int (arg1, 2) ; if (!tmp9) { goto __ats_lab_8_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_short_7) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp10 = atspre_eq_int_int (arg1, 4) ; if (!tmp10) { goto __ats_lab_9_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_4) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp11 = atspre_eq_int_int (arg1, 5) ; if (!tmp11) { goto __ats_lab_10_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_long_5) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_3) ; break ; } while (0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp12 = atsopt_printf_c_string_find_char (ATSstrcst("eEfFgG"), arg0) ; if (!tmp12) { goto __ats_lab_12_1 ; } tmp13 = atspre_eq_int_int (arg1, 6) ; if (tmp13) { tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_long_2) ; } else { tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; } /* end of [if] */ break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp14 = atsopt_printf_c_string_find_char (ATSstrcst("ouxX"), arg0) ; if (!tmp14) { goto __ats_lab_18_1 ; } do { /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp15 = atspre_eq_int_int (arg1, 1) ; if (!tmp15) { goto __ats_lab_14_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_13) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp16 = atspre_eq_int_int (arg1, 2) ; if (!tmp16) { goto __ats_lab_15_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_short_14) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: tmp17 = atspre_eq_int_int (arg1, 4) ; if (!tmp17) { goto __ats_lab_16_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_11) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp18 = atspre_eq_int_int (arg1, 5) ; if (!tmp18) { goto __ats_lab_17_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_long_12) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_10) ; break ; } while (0) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp19 = atspre_eq_char_char (arg0, 'p') ; if (!tmp19) { goto __ats_lab_19_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_ptr_8) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp20 = atspre_eq_char_char (arg0, 's') ; if (!tmp20) { goto __ats_lab_20_1 ; } tmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_string_9) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: /* tmp21 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_printf_c)")) ; /* tmp22 = */ atspre_prerr_string (ATSstrcst(": spec2type_translats: illegal arguments: sp = ")) ; /* tmp23 = */ atspre_prerr_char (arg0) ; /* tmp24 = */ atspre_prerr_newline () ; /* tmp25 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_printf_c)")) ; /* tmp26 = */ atspre_prerr_string (ATSstrcst(": spec2type_translats: illegal arguments: ls = ")) ; /* tmp27 = */ atspre_prerr_int (arg1) ; /* tmp28 = */ atspre_prerr_newline () ; /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp2) ; } /* end of [spec2type_translate_1] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 2581(line=96, offs=5) -- 3468(line=121, offs=4) */ ATSstaticdec() ats_bool_type flagstr_verify_2 (ats_char_type arg0, ats_ptr_type arg1, ats_size_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp29) ; ATSlocal (ats_bool_type, tmp30) ; ATSlocal (ats_char_type, tmp31) ; ATSlocal (ats_bool_type, tmp32) ; ATSlocal (ats_bool_type, tmp33) ; ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_size_type, tmp35) ; ATSlocal (ats_bool_type, tmp36) ; ATSlocal (ats_bool_type, tmp37) ; ATSlocal (ats_size_type, tmp38) ; ATSlocal (ats_bool_type, tmp39) ; ATSlocal (ats_bool_type, tmp40) ; ATSlocal (ats_size_type, tmp41) ; ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_bool_type, tmp43) ; ATSlocal (ats_size_type, tmp44) ; __ats_lab_flagstr_verify_2: tmp30 = atspre_string_is_atend (arg1, arg2) ; if (tmp30) { tmp29 = ats_true_bool ; } else { tmp31 = atspre_string_get_char_at (arg1, arg2) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp34 = atspre_eq_char_char (tmp31, '+') ; if (tmp34) { tmp33 = ats_true_bool ; } else { tmp33 = atspre_eq_char_char (tmp31, '-') ; } /* end of [if] */ if (tmp33) { tmp32 = ats_true_bool ; } else { tmp32 = atspre_eq_char_char (tmp31, ' ') ; } /* end of [if] */ if (!tmp32) { goto __ats_lab_22_1 ; } tmp35 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp35 ; goto __ats_lab_flagstr_verify_2 ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp36 = atspre_eq_char_char (tmp31, '\'') ; if (!tmp36) { goto __ats_lab_23_1 ; } tmp37 = atsopt_printf_c_string_find_char (ATSstrcst("dfFgGiu"), arg0) ; if (tmp37) { tmp38 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp38 ; goto __ats_lab_flagstr_verify_2 ; // tail call } else { tmp29 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: tmp39 = atspre_eq_char_char (tmp31, '#') ; if (!tmp39) { goto __ats_lab_24_1 ; } tmp40 = atsopt_printf_c_string_find_char (ATSstrcst("aAfFeEgGxX"), arg0) ; if (tmp40) { tmp41 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp41 ; goto __ats_lab_flagstr_verify_2 ; // tail call } else { tmp29 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp42 = atspre_eq_char_char (tmp31, '0') ; if (!tmp42) { goto __ats_lab_25_1 ; } tmp43 = atsopt_printf_c_string_find_char (ATSstrcst("aAdeEfFgGiouxX"), arg0) ; if (tmp43) { tmp44 = atspre_add_size1_int1 (arg2, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp44 ; goto __ats_lab_flagstr_verify_2 ; // tail call } else { tmp29 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp29 = ats_false_bool ; break ; } while (0) ; } /* end of [if] */ return (tmp29) ; } /* end of [flagstr_verify_2] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 3500(line=123, offs=4) -- 3732(line=130, offs=4) */ ATSstaticdec() ats_bool_type precstr_verify_3 (ats_char_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp45) ; ATSlocal (ats_bool_type, tmp46) ; __ats_lab_precstr_verify_3: tmp46 = atspre_string_is_empty (ats_castfn_mac(ats_ptr_type, arg1)) ; if (tmp46) { tmp45 = ats_true_bool ; } else { tmp45 = atsopt_printf_c_string_find_char (ATSstrcst("aAdeEfFgGiosuxX"), arg0) ; } /* end of [if] */ return (tmp45) ; } /* end of [precstr_verify_3] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 3764(line=132, offs=4) -- 4154(line=144, offs=4) */ ATSstaticdec() ats_int_type lenstr_translate_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp47) ; ATSlocal (ats_bool_type, tmp48) ; ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_bool_type, tmp52) ; ATSlocal (ats_bool_type, tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_bool_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_lenstr_translate_4: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp48 = atspre_eq_string_string (arg0, ATSstrcst("")) ; if (!tmp48) { goto __ats_lab_27_1 ; } tmp47 = 0 ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp49 = atspre_eq_string_string (arg0, ATSstrcst("h")) ; if (!tmp49) { goto __ats_lab_28_1 ; } tmp47 = 1 ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp50 = atspre_eq_string_string (arg0, ATSstrcst("hh")) ; if (!tmp50) { goto __ats_lab_29_1 ; } tmp47 = 2 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp51 = atspre_eq_string_string (arg0, ATSstrcst("j")) ; if (!tmp51) { goto __ats_lab_30_1 ; } tmp47 = 3 ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp52 = atspre_eq_string_string (arg0, ATSstrcst("l")) ; if (!tmp52) { goto __ats_lab_31_1 ; } tmp47 = 4 ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp53 = atspre_eq_string_string (arg0, ATSstrcst("ll")) ; if (!tmp53) { goto __ats_lab_32_1 ; } tmp47 = 5 ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp54 = atspre_eq_string_string (arg0, ATSstrcst("L")) ; if (!tmp54) { goto __ats_lab_33_1 ; } tmp47 = 6 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp55 = atspre_eq_string_string (arg0, ATSstrcst("t")) ; if (!tmp55) { goto __ats_lab_34_1 ; } tmp47 = 7 ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: __ats_lab_34_1: tmp56 = atspre_eq_string_string (arg0, ATSstrcst("z")) ; if (!tmp56) { goto __ats_lab_35_1 ; } tmp47 = 8 ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: tmp57 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string) ; /* tmp47 = */ ats_raise_exn (tmp57) ; break ; } while (0) ; return (tmp47) ; } /* end of [lenstr_translate_4] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 4188(line=146, offs=4) -- 4934(line=162, offs=4) */ ATSstaticdec() ats_bool_type lenint_verify_5 (ats_char_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_bool_type, tmp59) ; ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_bool_type, tmp61) ; ATSlocal (ats_bool_type, tmp62) ; ATSlocal (ats_bool_type, tmp63) ; ATSlocal (ats_bool_type, tmp64) ; ATSlocal (ats_bool_type, tmp65) ; ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_bool_type, tmp67) ; __ats_lab_lenint_verify_5: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: __ats_lab_36_1: tmp59 = atspre_eq_int_int (arg1, 0) ; if (!tmp59) { goto __ats_lab_37_1 ; } tmp58 = ats_true_bool ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: tmp60 = atspre_eq_int_int (arg1, 1) ; if (!tmp60) { goto __ats_lab_38_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp61 = atspre_eq_int_int (arg1, 2) ; if (!tmp61) { goto __ats_lab_39_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp62 = atspre_eq_int_int (arg1, 4) ; if (!tmp62) { goto __ats_lab_40_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("aAcdeEfFgGiosuxX"), arg0) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp63 = atspre_eq_int_int (arg1, 5) ; if (!tmp63) { goto __ats_lab_41_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp64 = atspre_eq_int_int (arg1, 6) ; if (!tmp64) { goto __ats_lab_42_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("aAeEfFgG"), arg0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp65 = atspre_eq_int_int (arg1, 3) ; if (!tmp65) { goto __ats_lab_43_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp66 = atspre_eq_int_int (arg1, 7) ; if (!tmp66) { goto __ats_lab_44_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp67 = atspre_eq_int_int (arg1, 8) ; if (!tmp67) { goto __ats_lab_45_1 ; } tmp58 = atsopt_printf_c_string_find_char (ATSstrcst("diouxX"), arg0) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp58 = ats_false_bool ; break ; } while (0) ; return (tmp58) ; } /* end of [lenint_verify_5] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 4965(line=164, offs=4) -- 5670(line=184, offs=4) */ ATSstaticdec() ats_ptr_type printf_c_output_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_char_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_int_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_bool_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; ATSlocal (ats_bool_type, tmp74) ; ATSlocal (ats_bool_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_bool_type, tmp79) ; ATSlocal (ats_bool_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_bool_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; __ats_lab_printf_c_output_6: /* ats_int_type tmp69 ; */ tmp69 = 0 ; tmp70 = flagstr_verify_2 (arg4, ats_castfn_mac(ats_ptr_type, arg0), 0) ; tmp72 = atspre_neg_bool (tmp70) ; if (tmp72) { tmp73 = atspre_iadd (tmp69, 1) ; tmp69 = tmp73 ; } else { /* empty */ } /* end of [if] */ tmp74 = precstr_verify_3 (arg4, arg2) ; tmp76 = atspre_neg_bool (tmp74) ; if (tmp76) { tmp77 = atspre_add_int_int (tmp69, 1) ; tmp69 = tmp77 ; } else { /* empty */ } /* end of [if] */ tmp78 = lenstr_translate_4 (arg3) ; tmp79 = lenint_verify_5 (arg4, tmp78) ; tmp81 = atspre_neg_bool (tmp79) ; if (tmp81) { tmp82 = atspre_add_int_int (tmp69, 1) ; tmp69 = tmp82 ; } else { /* empty */ } /* end of [if] */ tmp83 = atspre_gt_int_int (tmp69, 0) ; if (tmp83) { tmp68 = (ats_sum_ptr_type)0 ; } else { tmp84 = spec2type_translate_1 (arg4, tmp78) ; tmp68 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp68, atslab_0, tmp84) ; } /* end of [if] */ return (tmp68) ; } /* end of [printf_c_output_6] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 5797(line=191, offs=4) -- 5918(line=192, offs=69) */ ATSstaticdec() ats_ptr_type MAIN_lexing_error_7 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; __ats_lab_MAIN_lexing_error_7: /* tmp86 = */ printf_c_argtypes_free_0 (arg0) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp85) ; } /* end of [MAIN_lexing_error_7] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 5923(line=194, offs=4) -- 6143(line=201, offs=4) */ ATSstaticdec() ats_ptr_type MAIN__8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_int_type, tmp90) ; __ats_lab_MAIN__8: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp89 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp89, atslab_0, tmp88) ; ats_selptrset_mac(anairiats_sum_0, tmp89, atslab_1, arg1) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN (tmp89, arg2) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp90 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp90 ; tmp87 = arg1 ; break ; } while (0) ; return (tmp87) ; } /* end of [MAIN__8] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 6243(line=208, offs=4) -- 6319(line=210, offs=18) */ ATSstaticdec() ats_ptr_type FLAGSTR_lexing_error_9 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp91) ; __ats_lab_FLAGSTR_lexing_error_9: /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp91) ; } /* end of [FLAGSTR_lexing_error_9] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 6389(line=214, offs=4) -- 6475(line=216, offs=18) */ ATSstaticdec() ats_ptr_type WIDTHSTR_lexing_error_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_WIDTHSTR_lexing_error_10: /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp92) ; } /* end of [WIDTHSTR_lexing_error_10] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 6555(line=220, offs=4) -- 6651(line=222, offs=18) */ ATSstaticdec() ats_ptr_type PRECSTR_lexing_error_11 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_PRECSTR_lexing_error_11: /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp93) ; } /* end of [PRECSTR_lexing_error_11] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 6741(line=227, offs=4) -- 6849(line=230, offs=18) */ ATSstaticdec() ats_ptr_type LENSTR_lexing_error_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_LENSTR_lexing_error_12: /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp94) ; } /* end of [LENSTR_lexing_error_12] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 6950(line=235, offs=4) -- 7069(line=238, offs=18) */ ATSstaticdec() ats_ptr_type SPECHR_lexing_error_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_SPECHR_lexing_error_13: /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__lexing_error () ; return (tmp95) ; } /* end of [SPECHR_lexing_error_13] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 13586(line=259, offs=16) -- 13831(line=265, offs=37) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_int_type, tmp104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN: tmp102 = lexing_engine (statmp96, statmp98) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp102 != 1) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp103 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__FLAGSTR () ; tmp101 = MAIN__8 (tmp103, arg0, arg1) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp102 != 2) { goto __ats_lab_50_0 ; } __ats_lab_49_1: arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp102 != 3) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp101 = arg0 ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (tmp102 != 4) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp104 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp104 ; tmp101 = arg0 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp101 = MAIN_lexing_error_7 (arg0, arg1) ; break ; } while (0) ; return (tmp101) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 15062(line=274, offs=19) -- 15218(line=277, offs=33) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__FLAGSTR () { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_int_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__FLAGSTR: tmp111 = lexing_engine (statmp105, statmp107) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (tmp111 != 1) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp112 = lexeme_string () ; tmp110 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__WIDTHSTR (tmp112) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp110 = FLAGSTR_lexing_error_9 () ; break ; } while (0) ; return (tmp110) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__FLAGSTR] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 18556(line=290, offs=20) -- 18719(line=293, offs=35) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__WIDTHSTR (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_int_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__WIDTHSTR: tmp119 = lexing_engine (statmp113, statmp115) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (tmp119 != 1) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp120 = lexeme_string () ; tmp118 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__PRECSTR (arg0, tmp120) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp118 = WIDTHSTR_lexing_error_10 (arg0) ; break ; } while (0) ; return (tmp118) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__WIDTHSTR] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 23106(line=308, offs=19) -- 23274(line=311, offs=37) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__PRECSTR (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_int_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__PRECSTR: tmp127 = lexing_engine (statmp121, statmp123) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp127 != 1) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp128 = lexeme_string () ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__LENSTR (arg0, arg1, tmp128) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: __ats_lab_58_1: tmp126 = PRECSTR_lexing_error_11 (arg0, arg1) ; break ; } while (0) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__PRECSTR] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 27658(line=326, offs=18) -- 27832(line=329, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__LENSTR (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_int_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__LENSTR: tmp135 = lexing_engine (statmp129, statmp131) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (tmp135 != 1) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp136 = lexeme_string () ; tmp134 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__SPECHR (arg0, arg1, arg2, tmp136) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp134 = LENSTR_lexing_error_12 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp134) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__LENSTR] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 31146(line=341, offs=18) -- 31360(line=345, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__SPECHR (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_char_type, tmp144) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__SPECHR: tmp143 = lexing_engine (statmp137, statmp139) ; do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (tmp143 != 1) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp144 = lexeme_get (0) ; tmp142 = printf_c_output_6 (arg0, arg1, arg2, arg3, tmp144) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (tmp143 != 2) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp142 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp142 = SPECHR_lexing_error_13 (arg0, arg1, arg2, arg3) ; break ; } while (0) ; return (tmp142) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__SPECHR] */ /* // /home/hwxi/research/Anairiats/src/ats_printf_c_lats.dats: 31410(line=352, offs=23) -- 31835(line=365, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__printf_c_string_parse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_int_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; // ATSlocal_void (tmp154) ; ATSlocal (ats_bool_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__printf_c_string_parse: tmp146 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__infile_make_string (arg0) ; tmp147 = ats_selsin_mac(tmp146, atslab_1) ; tmp148 = lexbuf_make_infile (tmp147) ; tmp149 = ats_selsin_mac(tmp148, atslab_1) ; /* tmp150 = */ lexing_lexbuf_set (tmp149) ; /* ats_int_type tmp151 ; */ tmp151 = 0 ; tmp153 = (ats_sum_ptr_type)0 ; tmp152 = ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__MAIN (tmp153, (&tmp151)) ; /* tmp154 = */ lexing_lexbuf_free () ; tmp155 = atspre_eq_int_int (tmp151, 0) ; if (tmp155) { tmp156 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp152) ; tmp145 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp145, atslab_0, tmp156) ; } else { /* tmp157 = */ printf_c_argtypes_free_0 (tmp152) ; tmp145 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp145) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__printf_c_string_parse] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string.name = "ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__Illegal_printf_c_string" ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp96, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp97, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp98, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp99, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp100, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp105, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp106, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp107, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp108, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp109, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp113, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp114, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp115, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp116, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp117, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp121, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp122, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp123, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp124, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp125, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp129, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp130, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp131, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp132, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp133, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp137, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp138, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp139, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp140, sizeof(ats_clo_ptr_type)) ; ATS_GC_MARKROOT(&statmp141, sizeof(ats_clo_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp97 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (6) ; statmp96 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp97))) (statmp97, ATSstrcst("\000\004\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\006\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\006\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\005\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp97) ; statmp100 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (6) ; statmp99 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp100))) (statmp100, 5) ; ATS_FREE(statmp100) ; statmp98 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp99))) (statmp99, ATSstrcst("\000\004\000\003\000\002\000\002\000\001\000\002\000\003\000\001\000\005\000\002")) ; ATS_FREE(statmp99) ; statmp106 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (1) ; statmp105 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp106))) (statmp106, ATSstrcst("\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\001\000\000\000\000\000\001\000\000\000\000\000\000\000\001\000\000\000\000\000\000\000\001\000\000\000\001\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp106) ; statmp109 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (1) ; statmp108 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp109))) (statmp109, 1) ; ATS_FREE(statmp109) ; statmp107 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp108))) (statmp108, ATSstrcst("\000\001\000\001")) ; ATS_FREE(statmp108) ; statmp114 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (3) ; statmp113 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp114))) (statmp114, ATSstrcst("\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp114) ; statmp117 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (3) ; statmp116 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp117))) (statmp117, 3) ; ATS_FREE(statmp117) ; statmp115 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp116))) (statmp116, ATSstrcst("\000\003\000\001\000\001\000\001\000\002\000\001")) ; ATS_FREE(statmp116) ; statmp122 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (4) ; statmp121 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp122))) (statmp122, ATSstrcst("\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\004\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\003\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp122) ; statmp125 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (4) ; statmp124 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp125))) (statmp125, 4) ; ATS_FREE(statmp125) ; statmp123 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp124))) (statmp124, ATSstrcst("\000\004\000\001\000\001\000\001\000\002\000\001\000\003\000\001")) ; ATS_FREE(statmp124) ; statmp130 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (4) ; statmp129 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp130))) (statmp130, ATSstrcst("\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\004\000\000\000\002\000\000\000\003\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp130) ; statmp133 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (4) ; statmp132 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp133))) (statmp133, 4) ; ATS_FREE(statmp133) ; statmp131 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp132))) (statmp132, ATSstrcst("\000\002\000\001\000\003\000\001\000\004\000\001\000\001\000\001")) ; ATS_FREE(statmp132) ; statmp138 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____transition_table_make (3) ; statmp137 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp138))) (statmp138, ATSstrcst("\000\000\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\003\000\003\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\002\000\003\000\002\000\003\000\003\000\003\000\003\000\003\000\002\000\003\000\002\000\002\000\002\000\002\000\002\000\003\000\003\000\002\000\002\000\003\000\002\000\003\000\002\000\002\000\003\000\003\000\002\000\002\000\002\000\002\000\002\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000")) ; ATS_FREE(statmp138) ; statmp141 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats____accept_table_make (3) ; statmp140 = ((ats_clo_ptr_type(*)(ats_clo_ptr_type, ats_int_type))(ats_closure_fun(statmp141))) (statmp141, 2) ; ATS_FREE(statmp141) ; statmp139 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(statmp140))) (statmp140, ATSstrcst("\000\003\000\001\000\002\000\002")) ; ATS_FREE(statmp140) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_printf_c_lats_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_main_dats.c0000664000175000017500000032523012223166160021050 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ // #include "libc/CATS/stdio.cats" #include "libc/CATS/stdlib.cats" // #include "ats_main.cats" // /* type definitions */ typedef struct { ats_ptr_type atslab_comkind ; ats_int_type atslab_wait ; ats_int_type atslab_prelude ; ats_int_type atslab_depgen ; ats_ptr_type atslab_depgenout ; ats_int_type atslab_taggen ; ats_ptr_type atslab_taggenout ; ats_int_type atslab_posmark ; ats_int_type atslab_posmarknd ; ats_int_type atslab_typecheck_only ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_4 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__COMARGkey_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDinput_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDpervasive_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDoutput_3) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int_of_size) (ats_size_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_sub_size1_size1) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_gte_ssize1_int1) (ats_ssize_type, ats_int_type) ; ATSextern_fun(ats_void_type, ats_gc_chunk_count_limit_max_set) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_make_substring) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, atspre_stropt_none) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, atspre_printf_exn) (ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, atslib_fopen_exn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_fclose_exn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atsopt_debug_flag_get) () ; ATSextern_fun(ats_void_type, atsopt_debug_flag_set) (ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_gline_flag_set) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_push) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin) ; ATSextern_fun(ats_ptr_type, atsopt_filename_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_full) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_push) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_prepathlst_push) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_d0eclst) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push_dup) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm) (ats_bool_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarglst_parse) (ats_int_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__initialize) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__finalize) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_pervasive_add_topenv) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_pervasive_add_topenv) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_initialize) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_initialize) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c3str_get_final) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__c3str_solve) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main) (ats_int_type, ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atslib_getcwd0) () ; ATSextern_fun(ats_void_type, atsopt_free_the_s3itemlst) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__is_posmark_html) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_is_posmark_xref_prefix) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_DATS_wait_set) () ; ATSextern_fun(ats_bool_type, atsopt_DATS_wait_is_set) () ; ATSextern_fun(ats_void_type, atsopt_DATS_wait_clear) () ; ATSextern_fun(ats_bool_type, atsopt_is_DATS_flag) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_DATS_extract) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_IATS_wait_set) () ; ATSextern_fun(ats_bool_type, atsopt_IATS_wait_is_set) () ; ATSextern_fun(ats_void_type, atsopt_IATS_wait_clear) () ; ATSextern_fun(ats_bool_type, atsopt_is_IATS_flag) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_IATS_extract) (ats_ptr_type) ; ATSextern_fun(ats_ssize_type, atspre_string_index_of_char_from_left) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_void_type, atsopt_ATSHOMERELOC_set) () ; ATSextern_fun(ats_ptr_type, atsopt_ATSHOME_getenv_exn) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDinput_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDpervasive_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDoutput_3) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type atsopt_usage_0 (ats_ptr_type arg0) ; static ats_void_type atsopt_version_1 () ; static ats_ptr_type parse_from_filename_d0eclst_sta_2 (ats_ptr_type arg0) ; static ats_void_type e1xpenv_load_3 () ; static ats_void_type fixity_load_4 (ats_ptr_type arg0) ; static ats_ptr_type ref_make_elt_01688_ats_int_type (ats_int_type arg0) ; static ats_void_type pervasive_load_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type prelude_load_7 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_bool_type comkind_is_input_8 (ats_ptr_type arg0) ; static ats_bool_type comkind_is_pervasive_9 (ats_ptr_type arg0) ; static ats_bool_type comkind_is_output_10 (ats_ptr_type arg0) ; static ats_bool_type is_htmlbodyfile_11 (ats_int_type arg0) ; static ats_bool_type is_htmlxref_12 (ats_int_type arg0) ; static ats_bool_type posmarknd_isall_13 (ats_int_type arg0) ; static ats_ptr_type ref_make_elt_01688_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type input_filename_get_15 () ; static ats_void_type input_filename_set_16 (ats_ptr_type arg0) ; static ats_ptr_type output_filename_get_17 () ; static ats_void_type output_filename_set_18 (ats_ptr_type arg0) ; static ats_ptr_type do_parse_filename_19 (ats_int_type arg0, anairiats_rec_0 arg1, ats_ptr_type arg2) ; static ats_ptr_type do_parse_stdin_20 (ats_int_type arg0) ; static ats_ptr_type do_trans12_21 (anairiats_rec_0 arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type do_trans123_22 (anairiats_rec_0 arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type do_trans1234_23 (anairiats_rec_0 arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type process_DATS_def_25 (ats_ptr_type arg0) ; static ats_void_type process_IATS_dir_26 (ats_ptr_type arg0) ; static ats_void_type warning_28 (ats_ptr_type arg0) ; static ats_void_type loop_29 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_void_type loop_final_30 (ats_ptr_type arg0, ats_ref_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp38) ; ATSstatic (ats_ptr_type, statmp103) ; ATSstatic (ats_ptr_type, statmp109) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 6078(line=224, offs=4) -- 7996(line=253, offs=4) */ ATSstaticdec() ats_void_type atsopt_usage_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_atsopt_usage_0: /* tmp1 = */ atspre_printf_exn (ATSstrcst("usage: %s ... \n\n"), arg0) ; /* tmp2 = */ atspre_print_string (ATSstrcst("where a is of one of the following forms:\n\n")) ; /* tmp3 = */ atspre_print_string (ATSstrcst(" -s filenames (for statically loading (many) )\n")) ; /* tmp4 = */ atspre_print_string (ATSstrcst(" --static filenames (for statically loading (many) )\n")) ; /* tmp5 = */ atspre_print_string (ATSstrcst(" -d filenames (for dynamically loading (many) )\n")) ; /* tmp6 = */ atspre_print_string (ATSstrcst(" --dynamic filenames (for dynamically loading (many) )\n")) ; /* tmp7 = */ atspre_print_string (ATSstrcst(" --pervasive filenames (for pervasively loading (many) )\n")) ; /* tmp8 = */ atspre_print_string (ATSstrcst(" -o filename (output into )\n")) ; /* tmp9 = */ atspre_print_string (ATSstrcst(" --output filename (output into )\n")) ; /* tmp10 = */ atspre_print_string (ATSstrcst(" -dep (for generating dependencies only)\n")) ; /* tmp11 = */ atspre_print_string (ATSstrcst(" --depgen (for generating dependencices only)\n")) ; /* tmp12 = */ atspre_print_string (ATSstrcst(" -dep2 (for generating dependencies and then compiling)\n")) ; /* tmp13 = */ atspre_print_string (ATSstrcst(" --depgen2 (for generating dependencies and then compiling)\n")) ; /* tmp14 = */ atspre_print_string (ATSstrcst(" --taggen (for generating tagging information)\n")) ; /* tmp15 = */ atspre_print_string (ATSstrcst(" -tc (for typechecking only)\n")) ; /* tmp16 = */ atspre_print_string (ATSstrcst(" --typecheck (for typechecking only)\n")) ; /* tmp17 = */ atspre_print_string (ATSstrcst(" --posmark_html (for generating html file depicting colored concrete syntax)\n")) ; /* tmp18 = */ atspre_print_string (ATSstrcst(" --posmark_html_body (for generating html body depicting colored concrete syntax)\n")) ; /* tmp19 = */ atspre_print_string (ATSstrcst(" --posmark_xref (for generating html file depicting some syntactic cross references)\n")) ; /* tmp20 = */ atspre_print_string (ATSstrcst(" --xrefprelude (for generating cross-referencing prelude files)\n")) ; /* tmp21 = */ atspre_print_string (ATSstrcst(" --gline (for generating line pragma information on source code)\n")) ; /* tmp22 = */ atspre_print_string (ATSstrcst(" --debug=0 (for disabling the generation of debugging information)\n")) ; /* tmp23 = */ atspre_print_string (ATSstrcst(" --debug=1 (for enabling the generation of debugging information)\n")) ; /* tmp24 = */ atspre_print_string (ATSstrcst(" -h (for printing out this help usage)\n")) ; /* tmp25 = */ atspre_print_string (ATSstrcst(" --help (for printing out this help usage)\n")) ; /* tmp26 = */ atspre_print_string (ATSstrcst(" -v (for printing out the version)\n")) ; /* tmp27 = */ atspre_print_string (ATSstrcst(" --version (for printing out the version)\n")) ; /* tmp0 = */ atspre_print_newline () ; return /* (tmp0) */ ; } /* end of [atsopt_usage_0] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 8147(line=260, offs=4) -- 8358(line=265, offs=4) */ ATSstaticdec() ats_void_type atsopt_version_1 () { /* local vardec */ // ATSlocal_void (tmp28) ; __ats_lab_atsopt_version_1: /* tmp28 = */ atspre_printf_exn (ATSstrcst("ATS/Anairiats version %i.%i.%i with Copyright (c) 2002-2013 Hongwei Xi\n"), 0, 2, 11) ; return /* (tmp28) */ ; } /* end of [atsopt_version_1] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 8411(line=269, offs=4) -- 8537(line=271, offs=54) */ ATSstaticdec() ats_ptr_type parse_from_filename_d0eclst_sta_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_parse_from_filename_d0eclst_sta_2: tmp29 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst (0, arg0) ; return (tmp29) ; } /* end of [parse_from_filename_d0eclst_sta_2] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 8607(line=276, offs=4) -- 8695(line=278, offs=2) */ ATSstaticdec() ats_void_type e1xpenv_load_3 () { /* local vardec */ // ATSlocal_void (tmp30) ; __ats_lab_e1xpenv_load_3: /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_pervasive_add_topenv () ; return /* (tmp30) */ ; } /* end of [e1xpenv_load_3] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 8795(line=284, offs=4) -- 9349(line=302, offs=4) */ ATSstaticdec() ats_void_type fixity_load_4 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_fixity_load_4: tmp32 = atsopt_filename_append (arg0, ATSstrcst("prelude/fixity.ats")) ; tmp33 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full (tmp32) ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push (tmp33) ; tmp35 = parse_from_filename_d0eclst_sta_2 (tmp33) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop () ; tmp37 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp35) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_pervasive_add_topenv () ; return /* (tmp31) */ ; } /* end of [fixity_load_4] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01688_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; __ats_lab_ref_make_elt_01688_ats_int_type: /* ats_int_type tmp40 ; */ tmp40 = arg0 ; tmp39 = atspre_ref_make_elt_tsz ((&tmp40), sizeof(ats_int_type)) ; return (tmp39) ; } /* end of [ref_make_elt_01688_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 9475(line=312, offs=4) -- 10288(line=338, offs=4) */ ATSstaticdec() ats_void_type pervasive_load_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_pervasive_load_6: tmp42 = atsopt_filename_append (arg0, arg1) ; tmp43 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_make_full (tmp42) ; /* tmp44 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push (tmp43) ; tmp45 = parse_from_filename_d0eclst_sta_2 (tmp43) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_pop () ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp45) ; tmp50 = ats_ptrget_mac(ats_int_type, statmp38) ; tmp49 = atspre_eq_int_int (tmp50, 0) ; if (tmp49) { tmp51 = (ats_sum_ptr_type)0 ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert (tmp42, 0, tmp51) ; } else { /* empty */ } /* end of [if] */ tmp52 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp47) ; return /* (tmp41) */ ; } /* end of [pervasive_load_6] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 10321(line=340, offs=5) -- 13449(line=427, offs=4) */ ATSstaticdec() ats_void_type prelude_load_7 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; ATSlocal (ats_bool_type, tmp57) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; ATSlocal (ats_bool_type, tmp94) ; // ATSlocal_void (tmp95) ; __ats_lab_prelude_load_7: /* tmp54 = */ e1xpenv_load_3 () ; /* tmp55 = */ fixity_load_4 (arg1) ; tmp57 = atspre_eq_int_int (arg0, -1) ; if (tmp57) { ats_ptrget_mac(ats_int_type, statmp38) = 1 ; } else { /* empty */ } /* end of [if] */ /* tmp58 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/basics_sta.sats")) ; /* tmp59 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/sortdef.sats")) ; /* tmp60 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/basics_dyn.sats")) ; /* tmp61 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/macrodef.sats")) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv () ; /* tmp63 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/arith.sats")) ; /* tmp64 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/vsubrw.sats")) ; /* tmp65 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/bool.sats")) ; /* tmp66 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/char.sats")) ; /* tmp67 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/byte.sats")) ; /* tmp68 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/float.sats")) ; /* tmp69 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/integer.sats")) ; /* tmp70 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/integer_ptr.sats")) ; /* tmp71 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/integer_fixed.sats")) ; /* tmp72 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/sizetype.sats")) ; /* tmp73 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/memory.sats")) ; /* tmp74 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/pointer.sats")) ; /* tmp75 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/reference.sats")) ; /* tmp76 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/string.sats")) ; /* tmp77 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/lazy.sats")) ; /* tmp78 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/lazy_vt.sats")) ; /* tmp79 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/printf.sats")) ; /* tmp80 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/filebas.sats")) ; /* tmp81 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/extern.sats")) ; /* tmp82 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/list.sats")) ; /* tmp83 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/list0.sats")) ; /* tmp84 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/list_vt.sats")) ; /* tmp85 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/option.sats")) ; /* tmp86 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/option0.sats")) ; /* tmp87 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/option_vt.sats")) ; /* tmp88 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/array.sats")) ; /* tmp89 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/array0.sats")) ; /* tmp90 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/matrix.sats")) ; /* tmp91 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/matrix0.sats")) ; /* tmp92 = */ pervasive_load_6 (arg1, ATSstrcst("prelude/SATS/ptrarr.sats")) ; tmp94 = atspre_eq_int_int (arg0, -1) ; if (tmp94) { ats_ptrget_mac(ats_int_type, statmp38) = 0 ; } else { /* empty */ } /* end of [if] */ /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_pervasive_add_topenv () ; /* tmp53 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_initialize () ; return /* (tmp53) */ ; } /* end of [prelude_load_7] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 13728(line=440, offs=4) -- 13818(line=441, offs=51) */ ATSstaticdec() ats_bool_type comkind_is_input_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp96) ; __ats_lab_comkind_is_input_8: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp96 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp96 = ats_false_bool ; break ; } while (0) ; return (tmp96) ; } /* end of [comkind_is_input_8] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 13852(line=444, offs=4) -- 13950(line=445, offs=55) */ ATSstaticdec() ats_bool_type comkind_is_pervasive_9 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp97) ; __ats_lab_comkind_is_pervasive_9: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp97 = ats_true_bool ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp97 = ats_false_bool ; break ; } while (0) ; return (tmp97) ; } /* end of [comkind_is_pervasive_9] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 13988(line=448, offs=4) -- 14080(line=449, offs=52) */ ATSstaticdec() ats_bool_type comkind_is_output_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp98) ; __ats_lab_comkind_is_output_10: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp98 = ats_true_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp98 = ats_false_bool ; break ; } while (0) ; return (tmp98) ; } /* end of [comkind_is_output_10] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 14403(line=469, offs=4) -- 14494(line=470, offs=59) */ ATSstaticdec() ats_bool_type is_htmlbodyfile_11 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp99) ; ATSlocal (ats_bool_type, tmp100) ; __ats_lab_is_htmlbodyfile_11: tmp100 = atspre_eq_int_int (arg0, 1) ; if (tmp100) { tmp99 = ats_true_bool ; } else { tmp99 = atspre_eq_int_int (arg0, 2) ; } /* end of [if] */ return (tmp99) ; } /* end of [is_htmlbodyfile_11] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 14527(line=473, offs=4) -- 14581(line=473, offs=58) */ ATSstaticdec() ats_bool_type is_htmlxref_12 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp101) ; __ats_lab_is_htmlxref_12: tmp101 = atspre_eq_int_int (arg0, 3) ; return (tmp101) ; } /* end of [is_htmlxref_12] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 14607(line=477, offs=4) -- 14765(line=481, offs=15) */ ATSstaticdec() ats_bool_type posmarknd_isall_13 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp102) ; __ats_lab_posmarknd_isall_13: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp102 = ats_true_bool ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 != 3) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp102 = ats_true_bool ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp102 = ats_false_bool ; break ; } while (0) ; return (tmp102) ; } /* end of [posmarknd_isall_13] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01688_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_ref_make_elt_01688_ats_ptr_type: /* ats_ptr_type tmp105 ; */ tmp105 = arg0 ; tmp104 = atspre_ref_make_elt_tsz ((&tmp105), sizeof(ats_ptr_type)) ; return (tmp104) ; } /* end of [ref_make_elt_01688_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 15434(line=530, offs=4) -- 15559(line=534, offs=4) */ ATSstaticdec() ats_ptr_type input_filename_get_15 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_input_filename_get_15: tmp107 = ats_ptrget_mac(ats_ptr_type, statmp103) ; ats_ptrget_mac(ats_ptr_type, statmp103) = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy ; tmp106 = tmp107 ; return (tmp106) ; } /* end of [input_filename_get_15] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 15595(line=536, offs=4) -- 15657(line=536, offs=66) */ ATSstaticdec() ats_void_type input_filename_set_16 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; __ats_lab_input_filename_set_16: ats_ptrget_mac(ats_ptr_type, statmp103) = arg0 ; return /* (tmp108) */ ; } /* end of [input_filename_set_16] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 15799(line=548, offs=4) -- 15920(line=552, offs=4) */ ATSstaticdec() ats_ptr_type output_filename_get_17 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_output_filename_get_17: tmp111 = ats_ptrget_mac(ats_ptr_type, statmp109) ; ats_ptrget_mac(ats_ptr_type, statmp109) = atspre_stropt_none ; tmp110 = tmp111 ; return (tmp110) ; } /* end of [output_filename_get_17] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 15957(line=554, offs=4) -- 16024(line=554, offs=71) */ ATSstaticdec() ats_void_type output_filename_set_18 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp112) ; __ats_lab_output_filename_set_18: ats_ptrget_mac(ats_ptr_type, statmp109) = arg0 ; return /* (tmp112) */ ; } /* end of [output_filename_set_18] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 16073(line=560, offs=4) -- 17868(line=618, offs=4) */ ATSstaticdec() ats_ptr_type do_parse_filename_19 (ats_int_type arg0, anairiats_rec_0 arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; // ATSlocal_void (tmp115) ; ATSlocal (ats_bool_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; ATSlocal (ats_bool_type, tmp130) ; ATSlocal (ats_int_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; // ATSlocal_void (tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; // ATSlocal_void (tmp135) ; ATSlocal (ats_bool_type, tmp136) ; // ATSlocal_void (tmp137) ; ATSlocal (ats_bool_type, tmp138) ; ATSlocal (ats_int_type, tmp139) ; // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_bool_type, tmp143) ; // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; __ats_lab_do_parse_filename_19: tmp114 = atsopt_debug_flag_get () ; tmp116 = atspre_gt_int_int (tmp114, 0) ; if (tmp116) { tmp117 = atslib_getcwd0 () ; /* tmp118 = */ atspre_print_string (ATSstrcst("cwd = ")) ; /* tmp119 = */ atspre_print_string (tmp117) ; /* tmp115 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp121 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filenameopt_make_relative (arg2) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (tmp121 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp122 = ats_caselptrlab_mac(anairiats_sum_1, tmp121, atslab_0) ; ATS_FREE(tmp121) ; tmp120 = tmp122 ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (tmp121 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: /* tmp123 = */ atspre_prerr_string (ATSstrcst("error(ATS)")) ; /* tmp124 = */ atspre_prerr_string (ATSstrcst(": the filename [")) ; /* tmp125 = */ atspre_prerr_string (arg2) ; /* tmp126 = */ atspre_prerr_string (ATSstrcst("] is not available.")) ; /* tmp127 = */ atspre_prerr_newline () ; /* tmp120 = */ ats_exit (1) ; break ; } while (0) ; /* tmp128 = */ input_filename_set_16 (tmp120) ; tmp131 = ats_select_mac(arg1, atslab_posmark) ; tmp130 = atspre_gt_int_int (tmp131, 0) ; if (tmp130) { /* tmp129 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable () ; } else { /* empty */ } /* end of [if] */ /* ats_ptr_type tmp132 ; */ tmp132 = (ats_sum_ptr_type)0 ; /* tmp133 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push (tmp120) ; tmp134 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_filename_d0eclst (arg0, tmp120) ; tmp132 = tmp134 ; tmp136 = atspre_gt_int_int (tmp114, 0) ; if (tmp136) { /* tmp135 = */ atspre_printf_exn (ATSstrcst("The file [%s] is successfully parsed!\n"), arg2) ; } else { /* empty */ } /* end of [if] */ tmp139 = ats_select_mac(arg1, atslab_posmark) ; tmp138 = atspre_gt_int_int (tmp139, 0) ; if (tmp138) { /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__d0eclst_posmark (tmp132) ; /* tmp137 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; } else { /* empty */ } /* end of [if] */ tmp141 = atsopt_filename_full (tmp120) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_xref_testnot_if (tmp141) ; tmp143 = atspre_stropt_is_some (tmp142) ; if (tmp143) { /* tmp145 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_push_dup () ; /* tmp146 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (ats_true_bool, tmp141, tmp142) ; /* tmp144 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_pop () ; } else { /* empty */ } /* end of [if] */ tmp113 = tmp132 ; return (tmp113) ; } /* end of [do_parse_filename_19] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 17924(line=622, offs=4) -- 18218(line=634, offs=4) */ ATSstaticdec() ats_ptr_type do_parse_stdin_20 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; __ats_lab_do_parse_stdin_20: /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filenamelst_push (ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin) ; tmp147 = ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__parse_from_stdin_d0eclst (arg0) ; return (tmp147) ; } /* end of [do_parse_stdin_20] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 18271(line=638, offs=4) -- 19120(line=667, offs=4) */ ATSstaticdec() ats_ptr_type do_trans12_21 (anairiats_rec_0 arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_int_type, tmp150) ; // ATSlocal_void (tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; ATSlocal (ats_bool_type, tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; // ATSlocal_void (tmp158) ; // ATSlocal_void (tmp159) ; ATSlocal (ats_bool_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; ATSlocal (ats_bool_type, tmp164) ; ATSlocal (ats_int_type, tmp165) ; // ATSlocal_void (tmp166) ; ATSlocal (ats_bool_type, tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; __ats_lab_do_trans12_21: tmp150 = atsopt_debug_flag_get () ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__initialize () ; tmp152 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (arg2) ; /* tmp153 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__finalize () ; tmp155 = atspre_gt_int_int (tmp150, 0) ; if (tmp155) { /* tmp156 = */ atspre_print_string (ATSstrcst("The 1st translation (fixity) of [")) ; /* tmp157 = */ atspre_print_string (arg1) ; /* tmp158 = */ atspre_print_string (ATSstrcst("] is successfully completed!")) ; /* tmp154 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp161 = ats_select_mac(arg0, atslab_posmarknd) ; tmp160 = atspre_eq_int_int (tmp161, 3) ; if (tmp160) { /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_enable () ; } else { /* empty */ } /* end of [if] */ tmp162 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp152) ; tmp165 = ats_select_mac(arg0, atslab_posmarknd) ; tmp164 = atspre_eq_int_int (tmp165, 3) ; if (tmp164) { /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; } else { /* empty */ } /* end of [if] */ tmp167 = atspre_gt_int_int (tmp150, 0) ; if (tmp167) { /* tmp168 = */ atspre_print_string (ATSstrcst("The 2nd translation (binding) of [")) ; /* tmp169 = */ atspre_print_string (arg1) ; /* tmp170 = */ atspre_print_string (ATSstrcst("] is successfully completed!")) ; /* tmp166 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp149 = tmp162 ; return (tmp149) ; } /* end of [do_trans12_21] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 19148(line=669, offs=4) -- 20023(line=702, offs=4) */ ATSstaticdec() ats_ptr_type do_trans123_22 (anairiats_rec_0 arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; ATSlocal (ats_int_type, tmp177) ; // ATSlocal_void (tmp178) ; ATSlocal (ats_bool_type, tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; __ats_lab_do_trans123_22: tmp172 = do_trans12_21 (arg0, arg1, arg2) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp172) ; tmp174 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c3str_get_final () ; /* tmp175 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__c3str_solve (tmp174) ; /* tmp176 = */ atsopt_free_the_s3itemlst () ; tmp177 = atsopt_debug_flag_get () ; tmp179 = atspre_gt_int_int (tmp177, 0) ; if (tmp179) { /* tmp180 = */ atspre_print_string (ATSstrcst("The 3rd translation (typechecking) of [")) ; /* tmp181 = */ atspre_print_string (arg1) ; /* tmp182 = */ atspre_print_string (ATSstrcst("] is successfully completed!")) ; /* tmp178 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp171 = tmp173 ; return (tmp171) ; } /* end of [do_trans123_22] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 20052(line=704, offs=4) -- 21676(line=754, offs=4) */ ATSstaticdec() ats_void_type do_trans1234_23 (anairiats_rec_0 arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_int_type, tmp186) ; // ATSlocal_void (tmp187) ; ATSlocal (ats_bool_type, tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_bool_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; // ATSlocal_void (tmp197) ; // ATSlocal_void (tmp198) ; // ATSlocal_void (tmp199) ; ATSlocal (ats_bool_type, tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; __ats_lab_do_trans1234_23: tmp184 = do_trans123_22 (arg0, arg2, arg3) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp184) ; tmp186 = atsopt_debug_flag_get () ; tmp188 = atspre_gt_int_int (tmp186, 0) ; if (tmp188) { /* tmp189 = */ atspre_print_string (ATSstrcst("The 4th translation (proof erasure) of [")) ; /* tmp190 = */ atspre_print_string (arg2) ; /* tmp191 = */ atspre_print_string (ATSstrcst("] is successfully completed!")) ; /* tmp187 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ tmp192 = input_filename_get_15 () ; tmp193 = output_filename_get_17 () ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp194 = atspre_stropt_is_some (tmp193) ; if (!tmp194) { goto __ats_lab_12_1 ; } tmp195 = atslib_fopen_exn (ats_castfn_mac(ats_ptr_type, tmp193), "w") ; tmp196 = ats_selsin_mac(tmp195, atslab_1) ; /* tmp197 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main (arg1, tmp196, tmp192, tmp185) ; /* tmp198 = */ atspre_fprintf_exn (tmp196, ATSstrcst("\n/* ****** ****** */\n\n/* end of [%s] */\n"), ats_castfn_mac(ats_ptr_type, tmp193)) ; tmp200 = atspre_gt_int_int (tmp186, 0) ; if (tmp200) { /* tmp201 = */ atspre_print_string (ATSstrcst("The 5th translation (code emission) of [")) ; /* tmp202 = */ atspre_print_string (arg2) ; /* tmp203 = */ atspre_print_string (ATSstrcst("] is successfully completed!")) ; /* tmp199 = */ atspre_print_newline () ; } else { /* empty */ } /* end of [if] */ /* tmp183 = */ atslib_fclose_exn (tmp196) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp204 = atspre_stdout_get () ; tmp205 = ats_selsin_mac(tmp204, atslab_1) ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_main (arg1, tmp205, tmp192, tmp185) ; /* tmp207 = */ atspre_fprint_string (tmp205, ATSstrcst("\n/* ****** ****** */\n")) ; /* tmp183 = */ atspre_stdout_view_set () ; break ; } while (0) ; return /* (tmp183) */ ; } /* end of [do_trans1234_23] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 21800(line=762, offs=3) -- 21904(line=767, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_main_2edats__is_posmark_html (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_main_2edats__is_posmark_html: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (__strcmpats(arg0, ATSstrcst("--posmark_html"))) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp208 = ats_true_bool ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp208 = ats_false_bool ; break ; } while (0) ; return (tmp208) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_main_2edats__is_posmark_html] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 22832(line=792, offs=5) -- 23894(line=826, offs=4) */ ATSstaticdec() ats_void_type process_DATS_def_25 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp209) ; ATSlocal (ats_ssize_type, tmp210) ; ATSlocal (ats_bool_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_size_type, tmp213) ; ATSlocal (ats_size_type, tmp214) ; ATSlocal (ats_size_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_size_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_int_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_process_DATS_def_25: tmp210 = atspre_string_index_of_char_from_left (ats_castfn_mac(ats_ptr_type, arg0), '=') ; tmp211 = atspre_gte_ssize1_int1 (tmp210, 0) ; if (tmp211) { tmp212 = atspre_string_make_substring (ats_castfn_mac(ats_ptr_type, arg0), 0, ats_castfn_mac(ats_size_type, tmp210)) ; tmp213 = atspre_string_length (ats_castfn_mac(ats_ptr_type, arg0)) ; tmp215 = atspre_add_size1_int1 (ats_castfn_mac(ats_size_type, tmp210), 1) ; tmp214 = atspre_sub_size1_size1 (tmp213, tmp215) ; tmp217 = atspre_add_size1_int1 (ats_castfn_mac(ats_size_type, tmp210), 1) ; tmp216 = atspre_string_make_substring (ats_castfn_mac(ats_ptr_type, arg0), tmp217, tmp214) ; tmp218 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ats_castfn_mac(ats_ptr_type, tmp212)) ; tmp220 = atspre_int_of_size (tmp214) ; tmp219 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy, ats_castfn_mac(ats_ptr_type, tmp216), tmp220) ; /* tmp209 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add (tmp218, tmp219) ; } else { tmp221 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ats_castfn_mac(ats_ptr_type, arg0)) ; tmp222 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_none (ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; /* tmp209 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add (tmp221, tmp222) ; } /* end of [if] */ return /* (tmp209) */ ; } /* end of [process_DATS_def_25] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 23950(line=830, offs=5) -- 24095(line=836, offs=4) */ ATSstaticdec() ats_void_type process_IATS_dir_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp223) ; // ATSlocal_void (tmp224) ; __ats_lab_process_IATS_dir_26: /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_pathlst_push (arg0) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_push (arg0) ; return /* (tmp223) */ ; } /* end of [process_IATS_dir_26] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 24677(line=861, offs=4) -- 24836(line=865, offs=4) */ ATSstaticdec() ats_void_type warning_28 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; __ats_lab_warning_28: /* tmp232 = */ atspre_prerr_string (ATSstrcst("waring(ATS)")) ; /* tmp233 = */ atspre_prerr_string (ATSstrcst(": unrecognized command line argument [")) ; /* tmp234 = */ atspre_prerr_string (arg0) ; /* tmp235 = */ atspre_prerr_string (ATSstrcst("] is ignored.")) ; /* tmp231 = */ atspre_prerr_newline () ; return /* (tmp231) */ ; } /* end of [warning_28] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 24862(line=867, offs=5) -- 36672(line=1169, offs=4) */ ATSstaticdec() ats_void_type loop_29 (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_bool_type, tmp239) ; // ATSlocal_void (tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; // ATSlocal_void (tmp242) ; ATSlocal (ats_bool_type, tmp243) ; // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; // ATSlocal_void (tmp246) ; ATSlocal (ats_int_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; // ATSlocal_void (tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_bool_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_bool_type, tmp261) ; ATSlocal (ats_bool_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_bool_type, tmp264) ; ATSlocal (ats_int_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; // ATSlocal_void (tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_bool_type, tmp276) ; ATSlocal (ats_bool_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_bool_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_int_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; // ATSlocal_void (tmp287) ; ATSlocal (ats_bool_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; // ATSlocal_void (tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_int_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_bool_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; // ATSlocal_void (tmp302) ; ATSlocal (ats_bool_type, tmp303) ; ATSlocal (ats_int_type, tmp304) ; ATSlocal (ats_bool_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_bool_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; ATSlocal (ats_bool_type, tmp317) ; ATSlocal (ats_int_type, tmp318) ; ATSlocal (ats_bool_type, tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; // ATSlocal_void (tmp322) ; ATSlocal (ats_bool_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; // ATSlocal_void (tmp327) ; ATSlocal (ats_bool_type, tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_bool_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_int_type, tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_bool_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_bool_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; // ATSlocal_void (tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; // ATSlocal_void (tmp348) ; ATSlocal (ats_bool_type, tmp349) ; ATSlocal (ats_int_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_int_type, tmp352) ; ATSlocal (ats_int_type, tmp353) ; // ATSlocal_void (tmp354) ; ATSlocal (ats_bool_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_bool_type, tmp357) ; ATSlocal (ats_int_type, tmp358) ; ATSlocal (ats_bool_type, tmp359) ; ATSlocal (ats_int_type, tmp360) ; ATSlocal (ats_bool_type, tmp361) ; ATSlocal (ats_int_type, tmp362) ; ATSlocal (ats_bool_type, tmp363) ; ATSlocal (ats_int_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; // ATSlocal_void (tmp366) ; __ats_lab_loop_29: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_15_1: tmp237 = ats_caselptrlab_mac(anairiats_sum_2, arg3, atslab_0) ; tmp238 = ats_caselptrlab_mac(anairiats_sum_2, arg3, atslab_1) ; ATS_FREE(arg3) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp239 = atsopt_DATS_wait_is_set () ; if (!tmp239) { goto __ats_lab_17_1 ; } /* tmp240 = */ atsopt_DATS_wait_clear () ; tmp241 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; /* tmp242 = */ process_DATS_def_25 (tmp241) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp243 = atsopt_IATS_wait_is_set () ; if (!tmp243) { goto __ats_lab_18_0 ; } /* tmp244 = */ atsopt_IATS_wait_clear () ; tmp245 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; /* tmp246 = */ process_IATS_dir_26 (tmp245) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: tmp247 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_0) ; if (tmp247 != 1) { goto __ats_lab_31_0 ; } __ats_lab_18_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; tmp249 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp249 ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (__strcmpats(tmp248, ATSstrcst("-s"))) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp251 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp251)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp251, atslab_0, 0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp251 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) = 1 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (__strcmpats(tmp248, ATSstrcst("-d"))) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp252 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp252)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp252, atslab_0, 1) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp252 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) = 1 ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (__strcmpats(tmp248, ATSstrcst("-o"))) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp253 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDoutput_3) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp253 ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (__strcmpats(tmp248, ATSstrcst("-tc"))) { goto __ats_lab_23_0 ; } __ats_lab_22_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_typecheck_only) = 1 ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (__strcmpats(tmp248, ATSstrcst("-h"))) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp254 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp254 ; tmp255 = ats_caselptrind_mac(ats_ptr_type, arg1, [0]) ; /* tmp250 = */ atsopt_usage_0 (tmp255) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (__strcmpats(tmp248, ATSstrcst("-v"))) { goto __ats_lab_25_0 ; } __ats_lab_24_1: /* tmp250 = */ atsopt_version_1 () ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (__strcmpats(tmp248, ATSstrcst("-dep"))) { goto __ats_lab_26_0 ; } __ats_lab_25_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) = 1 ; tmp256 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgenout) = tmp256 ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (__strcmpats(tmp248, ATSstrcst("-dep2"))) { goto __ats_lab_27_0 ; } __ats_lab_26_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) = 2 ; tmp257 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgenout) = tmp257 ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (__strcmpats(tmp248, ATSstrcst("-tag"))) { goto __ats_lab_28_0 ; } __ats_lab_27_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggen) = 1 ; tmp258 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggenout) = tmp258 ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp259 = atsopt_is_DATS_flag (tmp248) ; if (!tmp259) { goto __ats_lab_29_1 ; } tmp260 = atsopt_DATS_extract (tmp248) ; tmp261 = atspre_stropt_is_some (tmp260) ; if (tmp261) { /* tmp250 = */ process_DATS_def_25 (ats_castfn_mac(ats_ptr_type, tmp260)) ; } else { /* tmp250 = */ atsopt_DATS_wait_set () ; } /* end of [if] */ break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp262 = atsopt_is_IATS_flag (tmp248) ; if (!tmp262) { goto __ats_lab_30_1 ; } tmp263 = atsopt_IATS_extract (tmp248) ; tmp264 = atspre_stropt_is_some (tmp263) ; if (tmp264) { /* tmp250 = */ process_IATS_dir_26 (ats_castfn_mac(ats_ptr_type, tmp263)) ; } else { /* tmp250 = */ atsopt_IATS_wait_set () ; } /* end of [if] */ break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: /* tmp250 = */ warning_28 (tmp248) ; break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: tmp265 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_0) ; if (tmp265 != 2) { goto __ats_lab_50_0 ; } __ats_lab_31_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; tmp267 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp267 ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (__strcmpats(tmp266, ATSstrcst("--static"))) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp269 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp269)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp269, atslab_0, 0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp269 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) = 1 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (__strcmpats(tmp266, ATSstrcst("--dynamic"))) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp270 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp270)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp270, atslab_0, 1) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp270 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) = 1 ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (__strcmpats(tmp266, ATSstrcst("--pervasive"))) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp271 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDpervasive_2) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp271 ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (__strcmpats(tmp266, ATSstrcst("--output"))) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp272 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDoutput_3) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp272 ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (__strcmpats(tmp266, ATSstrcst("--depgen"))) { goto __ats_lab_37_0 ; } __ats_lab_36_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) = 1 ; tmp273 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgenout) = tmp273 ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (__strcmpats(tmp266, ATSstrcst("--depgen2"))) { goto __ats_lab_38_0 ; } __ats_lab_37_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) = 2 ; tmp274 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgenout) = tmp274 ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (__strcmpats(tmp266, ATSstrcst("--taggen"))) { goto __ats_lab_39_0 ; } __ats_lab_38_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggen) = 1 ; tmp275 = output_filename_get_17 () ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggenout) = tmp275 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (__strcmpats(tmp266, ATSstrcst("--typecheck"))) { goto __ats_lab_40_0 ; } __ats_lab_39_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_typecheck_only) = 1 ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (__strcmpats(tmp266, ATSstrcst("--xrefprelude"))) { goto __ats_lab_41_0 ; } __ats_lab_40_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) = -1 ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp276 = ATS_2d0_2e2_2e11_2src_2ats_main_2edats__is_posmark_html (tmp266) ; if (!tmp276) { goto __ats_lab_42_0 ; } ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmark) = 1 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) = 2 ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (__strcmpats(tmp266, ATSstrcst("--posmark_html_body"))) { goto __ats_lab_43_0 ; } __ats_lab_42_1: ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmark) = 1 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) = 1 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp277 = atsopt_is_posmark_xref_prefix (tmp266) ; if (!tmp277) { goto __ats_lab_44_0 ; } ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmark) = 1 ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) = 3 ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (__strcmpats(tmp266, ATSstrcst("--gline"))) { goto __ats_lab_45_0 ; } __ats_lab_44_1: /* tmp268 = */ atsopt_gline_flag_set (1) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (__strcmpats(tmp266, ATSstrcst("--debug=0"))) { goto __ats_lab_46_0 ; } __ats_lab_45_1: /* tmp268 = */ atsopt_debug_flag_set (0) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (__strcmpats(tmp266, ATSstrcst("--debug=1"))) { goto __ats_lab_47_0 ; } __ats_lab_46_1: /* tmp268 = */ atsopt_debug_flag_set (1) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (__strcmpats(tmp266, ATSstrcst("--help"))) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp278 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp278 ; tmp279 = ats_caselptrind_mac(ats_ptr_type, arg1, [0]) ; /* tmp268 = */ atsopt_usage_0 (tmp279) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (__strcmpats(tmp266, ATSstrcst("--version"))) { goto __ats_lab_49_0 ; } __ats_lab_48_1: /* tmp268 = */ atsopt_version_1 () ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: /* tmp268 = */ warning_28 (tmp266) ; break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: tmp281 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) ; tmp280 = comkind_is_input_8 (tmp281) ; if (!tmp280) { goto __ats_lab_63_1 ; } /* ats_int_type tmp282 ; */ tmp282 = 0 ; tmp284 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp284)->tag != 1) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp285 = ats_caselptrlab_mac(anairiats_sum_4, tmp284, atslab_0) ; tmp282 = tmp285 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: break ; } while (0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) = 0 ; tmp286 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) ; tmp288 = atspre_lte_int_int (tmp286, 0) ; if (tmp288) { ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) = 1 ; /* tmp287 = */ prelude_load_7 (tmp286, arg0) ; } else { /* empty */ } /* end of [if] */ tmp289 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; tmp290 = do_parse_filename_19 (tmp282, ats_ptrget_mac(anairiats_rec_0, arg2), tmp289) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: tmp293 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) ; tmp292 = atspre_gte_int_int (tmp293, 1) ; if (!tmp292) { goto __ats_lab_56_1 ; } tmp294 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgenout) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp296 = atspre_stropt_is_some (tmp294) ; if (!tmp296) { goto __ats_lab_55_1 ; } tmp297 = atslib_fopen_exn (ats_castfn_mac(ats_ptr_type, tmp294), "a") ; tmp298 = ats_selsin_mac(tmp297, atslab_1) ; /* tmp299 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen (tmp298, tmp289, tmp290) ; /* tmp295 = */ atslib_fclose_exn (tmp298) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp300 = atspre_stdout_get () ; tmp301 = ats_selsin_mac(tmp300, atslab_1) ; /* tmp302 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen (tmp301, tmp289, tmp290) ; /* tmp295 = */ atspre_stdout_view_set () ; break ; } while (0) ; tmp304 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) ; tmp303 = atspre_gte_int_int (tmp304, 2) ; if (tmp303) { /* tmp291 = */ do_trans1234_23 (ats_ptrget_mac(anairiats_rec_0, arg2), tmp282, tmp289, tmp290) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp306 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggen) ; tmp305 = atspre_gte_int_int (tmp306, 1) ; if (!tmp305) { goto __ats_lab_59_1 ; } tmp307 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggenout) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: tmp308 = atspre_stropt_is_some (tmp307) ; if (!tmp308) { goto __ats_lab_58_1 ; } tmp309 = atslib_fopen_exn (ats_castfn_mac(ats_ptr_type, tmp307), "a") ; tmp310 = ats_selsin_mac(tmp309, atslab_1) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen (tmp310, tmp289, tmp290) ; /* tmp312 = */ atspre_fprint_newline (tmp310) ; /* tmp291 = */ atslib_fclose_exn (tmp310) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: __ats_lab_58_1: tmp313 = atspre_stdout_get () ; tmp314 = ats_selsin_mac(tmp313, atslab_1) ; /* tmp315 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen (tmp314, tmp289, tmp290) ; /* tmp316 = */ atspre_fprint_newline (tmp314) ; /* tmp291 = */ atspre_stdout_view_set () ; break ; } while (0) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp318 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) ; tmp317 = is_htmlbodyfile_11 (tmp318) ; if (!tmp317) { goto __ats_lab_60_1 ; } tmp320 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) ; tmp319 = posmarknd_isall_13 (tmp320) ; tmp321 = output_filename_get_17 () ; /* tmp322 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (tmp319, tmp289, tmp321) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp324 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmarknd) ; tmp323 = is_htmlxref_12 (tmp324) ; if (!tmp323) { goto __ats_lab_61_1 ; } tmp325 = do_trans12_21 (ats_ptrget_mac(anairiats_rec_0, arg2), tmp289, tmp290) ; tmp326 = output_filename_get_17 () ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_file_make_htm (ats_true_bool, tmp289, tmp326) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__posmark_disable () ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: tmp329 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_typecheck_only) ; tmp328 = atspre_gt_int_int (tmp329, 0) ; if (!tmp328) { goto __ats_lab_62_1 ; } tmp330 = do_trans123_22 (ats_ptrget_mac(anairiats_rec_0, arg2), tmp289, tmp290) ; /* tmp331 = */ atspre_printf_exn (ATSstrcst("The file [%s] is successfully typechecked!"), tmp289) ; /* tmp291 = */ atspre_print_newline () ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: __ats_lab_62_1: /* tmp291 = */ do_trans1234_23 (ats_ptrget_mac(anairiats_rec_0, arg2), tmp282, tmp289, tmp290) ; break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp333 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) ; tmp332 = comkind_is_pervasive_9 (tmp333) ; if (!tmp332) { goto __ats_lab_64_1 ; } tmp334 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) ; tmp336 = atspre_lte_int_int (tmp334, 0) ; if (tmp336) { ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) = 1 ; /* tmp335 = */ prelude_load_7 (tmp334, arg0) ; } else { /* empty */ } /* end of [if] */ tmp337 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; tmp338 = do_parse_filename_19 (0, ats_ptrget_mac(anairiats_rec_0, arg2), tmp337) ; tmp339 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0eclst_tr (tmp338) ; tmp340 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__d1eclst_tr (tmp339) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: tmp342 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) ; tmp341 = comkind_is_output_10 (tmp342) ; if (!tmp341) { goto __ats_lab_65_0 ; } tmp343 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp343 ; tmp344 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; /* tmp345 = */ output_filename_set_18 (ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp344))) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // __ats_lab_65_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_3, tmp237, atslab_1) ; tmp347 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) = tmp347 ; /* tmp348 = */ warning_28 (tmp346) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp238 ; goto __ats_lab_loop_29 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (arg3 != (ats_sum_ptr_type)0) { goto __ats_lab_74_0 ; } __ats_lab_66_1: tmp350 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_wait) ; tmp349 = atspre_gt_int_int (tmp350, 0) ; if (!tmp349) { goto __ats_lab_74_1 ; } tmp351 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_comkind) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp351)->tag != 1) { goto __ats_lab_73_0 ; } __ats_lab_67_1: tmp352 = ats_caselptrlab_mac(anairiats_sum_4, tmp351, atslab_0) ; tmp353 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) ; tmp355 = atspre_lte_int_int (tmp353, 0) ; if (tmp355) { ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_prelude) = 1 ; /* tmp354 = */ prelude_load_7 (tmp353, arg0) ; } else { /* empty */ } /* end of [if] */ tmp356 = do_parse_stdin_20 (tmp352) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: __ats_lab_68_1: tmp358 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_depgen) ; tmp357 = atspre_gt_int_int (tmp358, 0) ; if (!tmp357) { goto __ats_lab_69_1 ; } break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: tmp360 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_taggen) ; tmp359 = atspre_gt_int_int (tmp360, 0) ; if (!tmp359) { goto __ats_lab_70_1 ; } break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: __ats_lab_70_1: tmp362 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_posmark) ; tmp361 = atspre_gt_int_int (tmp362, 0) ; if (!tmp361) { goto __ats_lab_71_1 ; } break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp364 = ats_select_mac(ats_ptrget_mac(anairiats_rec_0, arg2), atslab_typecheck_only) ; tmp363 = atspre_gt_int_int (tmp364, 0) ; if (!tmp363) { goto __ats_lab_72_1 ; } tmp365 = do_trans123_22 (ats_ptrget_mac(anairiats_rec_0, arg2), ATSstrcst("stdin"), tmp356) ; /* tmp366 = */ atspre_print_string (ATSstrcst("The typechecking is successfully completed!")) ; /* tmp236 = */ atspre_print_newline () ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: /* tmp236 = */ do_trans1234_23 (ats_ptrget_mac(anairiats_rec_0, arg2), tmp352, ATSstrcst("stdin"), tmp356) ; break ; } while (0) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: __ats_lab_73_1: break ; } while (0) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: /* tmp236 = */ loop_final_30 (arg0, arg2) ; break ; } while (0) ; return /* (tmp236) */ ; } /* end of [loop_29] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 36695(line=1172, offs=1) -- 36784(line=1178, offs=2) */ ATSstaticdec() ats_void_type loop_final_30 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp367) ; __ats_lab_loop_final_30: return /* (tmp367) */ ; } /* end of [loop_final_30] */ /* // /home/hwxi/research/Anairiats/src/ats_main.dats: 24166(line=841, offs=10) -- 37252(line=1203, offs=4) */ ATSglobaldec() ats_void_type mainats (ats_int_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (anairiats_rec_0, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_mainats: /* tmp226 = */ ats_gc_chunk_count_limit_max_set (-1) ; /* tmp227 = */ atsopt_ATSHOMERELOC_set () ; tmp228 = atsopt_ATSHOME_getenv_exn () ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_prepathlst_push (tmp228) ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__trans2_env_initialize () ; tmp368 = ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__comarglst_parse (arg0, arg1) ; // if (tmp368 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp369 = ats_caselptrlab_mac(anairiats_sum_2, tmp368, atslab_1) ; ATS_FREE(tmp368) ; /* anairiats_rec_0 tmp370 ; */ tmp371 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0) ; tmp370.atslab_comkind = tmp371 ; tmp370.atslab_wait = 0 ; tmp370.atslab_prelude = 0 ; tmp370.atslab_depgen = 0 ; tmp370.atslab_depgenout = atspre_stropt_none ; tmp370.atslab_taggen = 0 ; tmp370.atslab_taggenout = atspre_stropt_none ; tmp370.atslab_posmark = 0 ; tmp370.atslab_posmarknd = 0 ; tmp370.atslab_typecheck_only = 0 ; /* tmp225 = */ loop_29 (tmp228, arg1, (&tmp370), tmp369) ; return /* (tmp225) */ ; } /* end of [mainats] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_main_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_main_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_main_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDinput_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDpervasive_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__COMKINDoutput_3.tag = 3 ; return ; } /* staload function */ /* dynamic load function */ ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload (void) ; ats_int_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload_flag = 0 ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload (void) ; // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_main_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_main_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2ats_main_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp38, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp103, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp109, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_counter_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_prec_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_fxty_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_keyword_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_posmark_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_posmark_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_lexer_lats_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_dyn_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_scst_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dcst_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_sta_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn1_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_dyn2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_printf_c_lats_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_loop_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_met_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_scst_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_pat_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_deref_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_view_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_dec_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_constraint_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_util_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_print_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_temp_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_emit_2edats__dynload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_main_2edats__dynload () ; statmp38 = ref_make_elt_01688_ats_int_type (0) ; statmp103 = ref_make_elt_01688_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_stdin) ; statmp109 = ref_make_elt_01688_ats_ptr_type (atspre_stropt_none) ; return ; } /* end of [dynload function] */ int main (int argc, char *argv[]) { ATS_GC_INIT() ; mainats_prelude() ; ATS_2d0_2e2_2e11_2src_2ats_main_2edats__dynload() ; mainats((ats_int_type)argc, (ats_ptr_type)argv) ; return (0) ; } /* end of main */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_main_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_syntax_sats.c0000664000175000017500000013031612223166160021470 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDtype_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDt0ype_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDview_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewtype_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewt0ype_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDfun_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDval_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDcastfn_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDpraxi_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprfun_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprval_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDtype_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDview_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDviewtype_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDgeneric_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDprop_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDtype_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDview_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDviewtype_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalminus_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfn_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfnstar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfun_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfn_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfun_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDcastfn_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDlam_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatlam_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDllam_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatllam_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDfix_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatfix_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDifix_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDif_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifdef_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifndef_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDTOK_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECint_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECide_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECinc_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECdec_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPchar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPeval_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPfloat_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPide_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPint_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPlist_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPstring_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPcstsp_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQstr_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQsym_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTide_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTqid_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTlist_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTtup_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGvar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGprf_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGlin_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGfun_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGclo_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQfildot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymcolon_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymdot_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_symcolon_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymcolon_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_symcolon_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGsrt_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGidsrt_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SP0Tcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAvars_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsrt_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsub_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXT_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eapp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Echar_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eexi_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eextype_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eide_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eimp_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eint_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elam_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist2_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Emod_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eopide_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eqid_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyarr_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_ext_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup2_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Euni_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eunion_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYinf_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpre_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpos_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTassert_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTerror_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTprint_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGsta_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn2_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGlst_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDfloat_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_long_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDnone_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDlint_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDulint_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDllint_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDullint_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDsint_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDusint_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint8_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint8_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint16_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint16_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint32_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint32_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint64_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint64_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDnone_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGall_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGseq_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGall_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGseq_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEprop_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEtype_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEview_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEviewtype_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTdot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTcons_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tapp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tas_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tchar_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Texist_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfloat_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfree_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tide_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tint_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist2_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlst_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Topide_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tqid_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trec_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tref_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trefas_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tstring_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tsvararg_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup2_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGdyn_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta1_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta2_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGmet_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfixity_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cnonfix_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csymintr_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpundef_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpdef_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpact_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatsrts_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csrtdefs_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacons_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacsts_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstavars_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cclassdec_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextype_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextval_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextcode_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_par_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cmacdefs_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdynload_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrpsz_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Echar_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecstsp_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecrypt_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edecseq_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edelay_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edynload_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eeffmask_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eempty_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eextval_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloat_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloatsp_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efoldat_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efreeat_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eide_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eidext_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eint_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eintsp_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eloopexn_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eopide_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eptrof_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eqid_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Escaseof_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_lab_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esexparg_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eshowtype_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estring_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estruct_47) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etmpid_48) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etop_49) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTcons_1) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDprop_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDtype_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDt0ype_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDview_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewtype_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewt0ype_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDfun_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDval_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDcastfn_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDpraxi_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprfun_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprval_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDprop_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDtype_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDview_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDviewtype_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDgeneric_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDprop_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDtype_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDview_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDviewtype_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalminus_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfn_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfnstar_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfun_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfn_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfun_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDcastfn_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDlam_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatlam_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDllam_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatllam_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDfix_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatfix_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDifix_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDif_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifdef_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifndef_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDTOK_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECint_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECide_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECinc_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECdec_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPchar_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPeval_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPfloat_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPide_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPint_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPlist_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPstring_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPcstsp_8.tag = 8 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQstr_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQsym_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTide_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTqid_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTlist_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTtup_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGvar_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGprf_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGlin_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGfun_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGclo_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQfildot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymcolon_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymdot_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_symcolon_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymcolon_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_symcolon_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGsrt_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGidsrt_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SP0Tcon_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTcons_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAprop_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAvars_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsrt_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsub_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXT_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eann_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eapp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Echar_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eexi_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eextype_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eide_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eimp_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eint_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elam_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist2_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Emod_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eopide_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eqid_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyarr_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_ext_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup2_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Euni_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eunion_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYinf_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpre_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpos_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTassert_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTerror_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTprint_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGsta_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn2_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGlst_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDfloat_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_long_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDnone_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDlint_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDulint_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDllint_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDullint_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDsint_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDusint_7.tag = 7 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint8_8.tag = 8 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint8_9.tag = 9 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint16_10.tag = 10 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint16_11.tag = 11 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint32_12.tag = 12 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint32_13.tag = 13 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint64_14.tag = 14 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint64_15.tag = 15 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDnone_16.tag = 16 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGall_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGseq_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGall_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGseq_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEprop_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEtype_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEview_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEviewtype_4.tag = 4 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTnil_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTdot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTcons_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tann_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tapp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tas_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tchar_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Texist_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfloat_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfree_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tide_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tint_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist2_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlst_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Topide_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tqid_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trec_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tref_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trefas_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tstring_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tsvararg_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup2_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGdyn_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta1_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta2_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGmet_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfixity_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cnonfix_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csymintr_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpundef_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpdef_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpact_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatsrts_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csrtdefs_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacons_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacsts_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstavars_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cclassdec_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextype_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextval_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextcode_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_par_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cmacdefs_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdynload_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32.tag = 32 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrpsz_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Echar_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecstsp_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecrypt_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edecseq_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edelay_10.tag = 10 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edynload_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eeffmask_12.tag = 12 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eempty_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eextval_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloat_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloatsp_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efoldat_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efreeat_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eide_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eidext_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eint_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eintsp_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eloopexn_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eopide_34.tag = 34 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eptrof_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eqid_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Escaseof_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_lab_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esexparg_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eshowtype_44.tag = 44 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estring_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estruct_47.tag = 47 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etmpid_48.tag = 48 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etop_49.tag = 49 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50.tag = 50 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51.tag = 51 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52.tag = 52 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53.tag = 53 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54.tag = 54 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55.tag = 55 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTcons_1.tag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_syntax_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_printf_dats.c0000664000175000017500000001125012223166160023304 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ ats_void_type atspre_exit_prerrf (const ats_int_type n, const ats_ptr_type fmt, ...) { va_list ap ; va_start(ap, fmt) ; vfprintf(stderr, (char*)fmt, ap) ; va_end(ap) ; exit(n) ; } ats_void_type atspre_assert_prerrf (ats_bool_type assertion, ats_ptr_type fmt, ...) { int n ; va_list ap ; if (!assertion) { va_start(ap, fmt) ; n = vfprintf(stderr, (char*)fmt, ap) ; va_end(ap) ; if (n < 0) { ats_exit_errmsg ( n, "[atspre_assert_prerrf: prerrf] failed\n" ) ; } else { ats_exit_errmsg ( 1, "[atspre_assert_prerrf: assert] failed\n" ) ; } } return ; } /* end of [atspre_assert_prerrf] */ // functions for sprintf static ats_ptr_type __tostringf_size (const ats_int_type guess, const ats_ptr_type fmt, va_list ap0) { int n, sz ; char *res ; va_list ap ; sz = guess ; res = ATS_MALLOC (sz) ; while (1) { va_copy (ap, ap0) ; // [vsnprintf] may modify [ap] n = vsnprintf (res, sz, (char*)fmt, ap) ; if (n >= 0) { if (n < sz) return res ; sz = n+1 ; /* exact size */ ATS_FREE (res) ; res = ATS_MALLOC (sz) ; continue ; } // end of [if] return ((ats_ptr_type)0) ; } } // end of [__tostringf_size] ats_ptr_type atspre_tostringf_size (const ats_int_type guess, const ats_ptr_type fmt, ...) { char *res ; va_list ap ; va_start(ap, fmt); res = (char*)__tostringf_size (guess, fmt, ap); va_end(ap); if (!res) { ats_exit_errmsg (1, "Exit: [ats_tostringf_size] failed.\n") ; } return res ; } #define __TOSTRINGF_GUESS 16 ats_ptr_type atspre_tostringf (ats_ptr_type fmt, ...) { char *res ; va_list ap ; va_start(ap, fmt); res = (char*)__tostringf_size (__TOSTRINGF_GUESS, fmt, ap); va_end(ap); if (!res) { ats_exit_errmsg (1, "Exit: [ats_tostringf] failed.\n") ; } return res ; } /* end of [atspre_tostringf] */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_printf_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_printf_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_exp_dn_dats.c0000664000175000017500000045656512223166160022713 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_intinf.cats" // this for the ATS/Geizeilla compiler /* type definitions */ typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_m2atch_loc ; ats_ptr_type atslab_m2atch_exp ; ats_ptr_type atslab_m2atch_pat ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_c2lau_loc ; ats_ptr_type atslab_c2lau_pat ; ats_ptr_type atslab_c2lau_gua ; ats_int_type atslab_c2lau_seq ; ats_int_type atslab_c2lau_neg ; ats_ptr_type atslab_c2lau_exp ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_sc2lau_loc ; ats_ptr_type atslab_sc2lau_pat ; ats_ptr_type atslab_sc2lau_exp ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_sp2at_loc ; ats_ptr_type atslab_sp2at_exp ; ats_ptr_type atslab_sp2at_node ; } anairiats_rec_20 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt1_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__SP2Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__SACSBISnone_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int1_of_size1) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, atsopt_gte_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__prerr_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool) (ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_exi) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neg_bool_bool) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__printf_c_string_parse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtypes) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ats_dynexp3_d3exp_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_caseof) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_scaseof) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sif) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_struct) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__m3atch_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__c3lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__sc3lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlstlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_dn) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn) (ats_ptr_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn) (ats_ptr_type, ats_ref_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_loc_warning3_1 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_2 () ; static ats_void_type prerr_loc_interror_3 (ats_ptr_type arg0) ; static ats_void_type pfarity_check_rec_4 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_void_type reckind_check_5 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_funclo_opt_of_d2exp_6 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type d2exp_s2eff_opt_of_d2exp_7 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type err_10 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_float_tr_dn_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type c2lau_make_if_d2exp_11 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) ; static ats_ptr_type c2lau_make_if_d2expopt_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2, ats_ptr_type arg3) ; static ats_ptr_type err_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type szcheck_17 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_int_tr_dn_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type labd2explst_tr_dn_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d2exp_seq_tr_dn_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_22 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_string_tr_dn_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type m2atch_tr_up_26 (ats_ptr_type arg0) ; static ats_ptr_type m2atchlst_tr_up_27 (ats_ptr_type arg0) ; static ats_void_type aux_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pattern_match_is_redundant_errmsg_30 (ats_ptr_type arg0) ; static ats_void_type c2laulst0_tr_dn_31 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type c2laulst1_tr_dn_32 (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) ; static ats_ptr_type c2laulst2_tr_dn_33 (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) ; static ats_ptr_type aux_36 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_37 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_37_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_37_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_main_35 (ats_int_type env0, ats_ptr_type env1, ats_int_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type env5, ats_ptr_type env6, ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_main_35_closure_make (ats_int_type env0, ats_ptr_type env1, ats_int_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type env5, ats_ptr_type env6) ; static ats_ptr_type aux_main_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_ptr_type c2laulst2_rest_tr_dn_34 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9, ats_ptr_type arg10) ; static ats_ptr_type aux_one_41 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_one_41_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) ; static ats_ptr_type aux_one_41_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_rest_42 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_rest_42_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) ; static ats_ptr_type aux_rest_42_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 2620(line=92, offs=4) -- 2705(line=93, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 2738(line=95, offs=4) -- 2827(line=96, offs=50) */ ATSstaticdec() ats_void_type prerr_loc_warning3_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_prerr_loc_warning3_1: /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp2 = */ atspre_prerr_string (ATSstrcst(": warning(3)")) ; return /* (tmp2) */ ; } /* end of [prerr_loc_warning3_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 2863(line=99, offs=4) -- 2925(line=99, offs=66) */ ATSstaticdec() ats_void_type prerr_interror_2 () { /* local vardec */ // ATSlocal_void (tmp4) ; __ats_lab_prerr_interror_2: /* tmp4 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_exp_dn)")) ; return /* (tmp4) */ ; } /* end of [prerr_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 2930(line=101, offs=4) -- 3045(line=103, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_3 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; __ats_lab_prerr_loc_interror_3: /* tmp6 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp5 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_exp_dn)")) ; return /* (tmp5) */ ; } /* end of [prerr_loc_interror_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 3102(line=107, offs=4) -- 3430(line=119, offs=6) */ ATSstaticdec() ats_void_type pfarity_check_rec_4 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp7) ; ATSlocal (ats_bool_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_pfarity_check_rec_4: tmp8 = atspre_eq_int_int (arg1, arg2) ; if (tmp8) { /* empty */ } else { /* tmp9 = */ prerr_loc_error3_0 (arg0) ; /* tmp10 = */ atspre_prerr_string (ATSstrcst(": the proof arity of the record is [")) ; /* tmp11 = */ atspre_prerr_int (arg1) ; /* tmp12 = */ atspre_prerr_string (ATSstrcst("] but it is expected to be [")) ; /* tmp13 = */ atspre_prerr_int (arg2) ; /* tmp14 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp15 = */ atspre_prerr_newline () ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp7) */ ; } /* end of [pfarity_check_rec_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 3501(line=124, offs=4) -- 4184(line=145, offs=4) */ ATSstaticdec() ats_void_type reckind_check_5 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_bool_type, tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_reckind_check_5: tmp17 = atspre_gt_int_int (arg1, 0) ; if (tmp17) { do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: /* tmp18 = */ prerr_loc_error3_0 (arg0) ; /* tmp19 = */ atspre_prerr_string (ATSstrcst(": the record is boxed but it is expected to be flat.")) ; /* tmp20 = */ atspre_prerr_newline () ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_4_0 ; } __ats_lab_3_1: break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg2)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: /* tmp21 = */ prerr_loc_error3_0 (arg0) ; /* tmp22 = */ atspre_prerr_string (ATSstrcst(": the record is flat but it is expected to be boxed.")) ; /* tmp23 = */ atspre_prerr_newline () ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } /* end of [if] */ return /* (tmp16) */ ; } /* end of [reckind_check_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 4310(line=152, offs=4) -- 4549(line=156, offs=36) */ ATSstaticdec() ats_ptr_type d2exp_funclo_opt_of_d2exp_6 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_d2exp_funclo_opt_of_d2exp_6: tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp25)->tag != 0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_1, tmp25, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_1, tmp25, atslab_1) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp28, atslab_0, tmp27) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp28 ; tmp24 = tmp26 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp29 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp29 ; tmp24 = arg0 ; break ; } while (0) ; return (tmp24) ; } /* end of [d2exp_funclo_opt_of_d2exp_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 4634(line=160, offs=4) -- 4875(line=164, offs=38) */ ATSstaticdec() ats_ptr_type d2exp_s2eff_opt_of_d2exp_7 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_d2exp_s2eff_opt_of_d2exp_7: tmp31 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp31)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_1, tmp31, atslab_0) ; tmp33 = ats_caselptrlab_mac(anairiats_sum_1, tmp31, atslab_1) ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp34, atslab_0, tmp33) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp34 ; tmp30 = tmp32 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp35 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp35 ; tmp30 = arg0 ; break ; } while (0) ; return (tmp30) ; } /* end of [d2exp_s2eff_opt_of_d2exp_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 4957(line=170, offs=13) -- 5267(line=181, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn: tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_d3exp_loc) ; tmp38 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_d3exp_typ) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp37, tmp38, arg1) ; return /* (tmp36) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 5396(line=187, offs=6) -- 5615(line=193, offs=6) */ ATSstaticdec() ats_ptr_type err_10 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; __ats_lab_err_10: /* tmp41 = */ prerr_loc_error3_0 (arg0) ; /* tmp42 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp44 = */ atspre_prerr_string (ATSstrcst("] cannot be assigned to a float constant.")) ; /* tmp45 = */ atspre_prerr_newline () ; /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp40) ; } /* end of [err_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 5317(line=185, offs=4) -- 6165(line=211, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_float_tr_dn_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_bool_type, tmp52) ; __ats_lab_d2exp_float_tr_dn_9: tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_loc) ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp48 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp47), atslab_s2exp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp48)->tag != 4) { goto __ats_lab_15_0 ; } __ats_lab_10_1: tmp49 = ats_caselptrlab_mac(anairiats_sum_5, tmp48, atslab_0) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp50 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype, tmp49) ; if (!tmp50) { goto __ats_lab_12_1 ; } tmp39 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float (tmp46, tmp47, arg1) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp51 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype, tmp49) ; if (!tmp51) { goto __ats_lab_13_1 ; } tmp39 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float (tmp46, tmp47, arg1) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp52 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype, tmp49) ; if (!tmp52) { goto __ats_lab_14_1 ; } tmp39 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float (tmp46, tmp47, arg1) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp39 = err_10 (tmp46, tmp47) ; break ; } while (0) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: tmp39 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, tmp47) ; break ; } while (0) ; return (tmp39) ; } /* end of [d2exp_float_tr_dn_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 6221(line=215, offs=4) -- 6415(line=220, offs=4) */ ATSstaticdec() ats_ptr_type c2lau_make_if_d2exp_11 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_c2lau_make_if_d2exp_11: tmp54 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_bool (arg0, arg1) ; tmp55 = (ats_sum_ptr_type)0 ; tmp56 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg2), atslab_d2exp_loc) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp57, atslab_0, tmp54) ; tmp58 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp57), atslab_1) ; tmp59 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp58) = tmp59 ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make (tmp56, tmp57, tmp55, 0, 0, arg2) ; return (tmp53) ; } /* end of [c2lau_make_if_d2exp_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 6506(line=223, offs=4) -- 6745(line=231, offs=4) */ ATSstaticdec() ats_ptr_type c2lau_make_if_d2expopt_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_bool_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_c2lau_make_if_d2expopt_12: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_2, arg3, atslab_0) ; tmp61 = tmp62 ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (arg0) ; break ; } while (0) ; tmp60 = c2lau_make_if_d2exp_11 (arg1, arg2, tmp61) ; return (tmp60) ; } /* end of [c2lau_make_if_d2expopt_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 6830(line=237, offs=3) -- 7193(line=245, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn: tmp64 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg2), atslab_d2exp_loc) ; tmp65 = c2lau_make_if_d2exp_11 (tmp64, ats_true_bool, arg3) ; tmp66 = c2lau_make_if_d2expopt_12 (arg0, tmp64, ats_false_bool, arg4) ; tmp67 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp67, atslab_0, arg2) ; tmp68 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp67), atslab_1) ; tmp69 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp68) = tmp69 ; tmp70 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp70, atslab_0, tmp65) ; tmp71 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp70), atslab_1) ; tmp72 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp72, atslab_0, tmp66) ; ats_ptrget_mac(ats_ptr_type, tmp71) = tmp72 ; tmp71 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp72), atslab_1) ; tmp72 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp71) = tmp72 ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn (arg0, 1, arg1, 1, tmp67, tmp70, arg5) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 7269(line=250, offs=17) -- 8378(line=284, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; // ATSlocal_void (tmp80) ; // ATSlocal_void (tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn: tmp74 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update (arg1) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () ; tmp76 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (tmp74, tmp75) ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, arg2) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg3, arg5) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp76, tmp75) ; tmp82 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg3), atslab_d2exp_loc) ; /* tmp81 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp82) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ (tmp75) ; /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp86 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neg_bool_bool (arg2) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, tmp86) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg4, arg5) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp76, tmp75) ; tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg4), atslab_d2exp_loc) ; /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp90) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp76, tmp75) ; /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp76, tmp75) ; tmp73 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sif (arg0, arg5, arg2, tmp79, tmp87) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 8538(line=293, offs=6) -- 8760(line=299, offs=6) */ ATSstaticdec() ats_ptr_type err_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; __ats_lab_err_16: /* tmp95 = */ prerr_loc_error3_0 (arg0) ; /* tmp96 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp98 = */ atspre_prerr_string (ATSstrcst("] cannot be assigned to an integer constant.")) ; /* tmp99 = */ atspre_prerr_newline () ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp94) ; } /* end of [err_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 8766(line=300, offs=6) -- 9154(line=309, offs=6) */ ATSstaticdec() ats_void_type szcheck_17 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp100) ; ATSlocal (ats_bool_type, tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; // ATSlocal_void (tmp107) ; __ats_lab_szcheck_17: tmp101 = atsopt_gte_intinf_int (arg1, 0) ; if (tmp101) { /* empty */ } else { /* tmp102 = */ prerr_loc_error3_0 (arg0) ; /* tmp103 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_int_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp104 = */ atspre_prerr_string (ATSstrcst(": the negative number [")) ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__prerr_intinf (arg1) ; /* tmp106 = */ atspre_prerr_string (ATSstrcst("] cannot be a size.")) ; /* tmp107 = */ atspre_prerr_newline () ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp100) */ ; } /* end of [szcheck_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 8432(line=288, offs=4) -- 11033(line=360, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_int_tr_dn_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_bool_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_bool_type, tmp123) ; // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_bool_type, tmp133) ; ATSlocal (ats_bool_type, tmp134) ; // ATSlocal_void (tmp135) ; __ats_lab_d2exp_int_tr_dn_15: tmp108 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_loc) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg3) ; tmp110 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp109), atslab_s2exp_node) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp110)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_18_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_1, tmp110, atslab_0) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_1, tmp110, atslab_1) ; tmp113 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp111), atslab_s2exp_node) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp113)->tag != 4) { goto __ats_lab_27_0 ; } __ats_lab_19_1: tmp114 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp115 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype, tmp114) ; if (!tmp115) { goto __ats_lab_23_1 ; } do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (tmp112 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp116 = tmp117 ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: /* tmp118 = */ prerr_interror_2 () ; /* tmp119 = */ atspre_prerr_string (ATSstrcst(": d2exp_int_tr_dn: Int_int_t0ype")) ; /* tmp120 = */ atspre_prerr_newline () ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg2) ; /* tmp121 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (tmp108, tmp122, tmp116) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (tmp108, tmp109, arg1, arg2) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: tmp123 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype, tmp114) ; if (!tmp123) { goto __ats_lab_26_1 ; } /* tmp124 = */ szcheck_17 (tmp108, arg2) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp112 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp125 = tmp126 ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: /* tmp127 = */ prerr_interror_2 () ; /* tmp128 = */ atspre_prerr_string (ATSstrcst(": d2exp_int_tr_dn: Int_int_t0ype")) ; /* tmp129 = */ atspre_prerr_newline () ; /* tmp125 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp131 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg2) ; /* tmp130 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (tmp108, tmp131, tmp125) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (tmp108, tmp109, arg1, arg2) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp93 = err_16 (tmp108, tmp109) ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, tmp109) ; break ; } while (0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp110)->tag != 4) { goto __ats_lab_32_0 ; } __ats_lab_28_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_5, tmp110, atslab_0) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: tmp133 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype, tmp132) ; if (!tmp133) { goto __ats_lab_30_1 ; } tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (tmp108, tmp109, arg1, arg2) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp134 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype, tmp132) ; if (!tmp134) { goto __ats_lab_31_1 ; } /* tmp135 = */ szcheck_17 (tmp108, arg2) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (tmp108, tmp109, arg1, arg2) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp93 = err_16 (tmp108, tmp109) ; break ; } while (0) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, tmp109) ; break ; } while (0) ; return (tmp93) ; } /* end of [d2exp_int_tr_dn_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 11088(line=364, offs=5) -- 12756(line=401, offs=8) */ ATSstaticdec() ats_ptr_type labd2explst_tr_dn_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_bool_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; // ATSlocal_void (tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; __ats_lab_labd2explst_tr_dn_18: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_35_1 ; } __ats_lab_33_2: tmp137 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp139 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp141 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_1) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_2) ; tmp143 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp137, tmp140) ; if (tmp143) { tmp144 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp138, tmp141) ; tmp145 = labd2explst_tr_dn_18 (arg0, tmp139, tmp142) ; tmp136 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp136, atslab_0, tmp137) ; ats_selptrset_mac(anairiats_sum_7, tmp136, atslab_1, tmp144) ; ats_selptrset_mac(anairiats_sum_7, tmp136, atslab_2, tmp145) ; } else { tmp147 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp138), atslab_d2exp_loc) ; /* tmp146 = */ prerr_loc_error3_0 (tmp147) ; /* tmp148 = */ atsopt_debug_prerrf (ATSstrcst(": %s: labd2explst_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp149 = */ atspre_prerr_string (ATSstrcst(": label mismatch")) ; /* tmp150 = */ atspre_prerr_string (ATSstrcst(": the label for the dynamic expression is [")) ; /* tmp151 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp137) ; /* tmp152 = */ atspre_prerr_string (ATSstrcst("] but it is expected to be [")) ; /* tmp153 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp140) ; /* tmp154 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp155 = */ atspre_prerr_newline () ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: if (arg2 != (ats_sum_ptr_type)0) { goto __ats_lab_36_1 ; } __ats_lab_34_2: tmp136 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_2: tmp156 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; /* tmp157 = */ prerr_loc_error3_0 (arg0) ; /* tmp158 = */ atsopt_debug_prerrf (ATSstrcst(": %s: labd2explst_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp159 = */ atspre_prerr_string (ATSstrcst(": the tuple/record needs fewer components")) ; /* tmp160 = */ atspre_prerr_string (ATSstrcst(": a component with the label [")) ; /* tmp161 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp156) ; /* tmp162 = */ atspre_prerr_string (ATSstrcst("] should be removed.")) ; /* tmp163 = */ atspre_prerr_newline () ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_2: tmp164 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; /* tmp165 = */ prerr_loc_error3_0 (arg0) ; /* tmp166 = */ atsopt_debug_prerrf (ATSstrcst(": %s: labd2explst_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp167 = */ atspre_prerr_string (ATSstrcst(": the tuple/record needs more components")) ; /* tmp168 = */ atspre_prerr_string (ATSstrcst(": a component with the label [")) ; /* tmp169 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (tmp164) ; /* tmp170 = */ atspre_prerr_string (ATSstrcst("] should be inserted.")) ; /* tmp171 = */ atspre_prerr_newline () ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp136) ; } /* end of [labd2explst_tr_dn_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 12939(line=408, offs=7) -- 13297(line=420, offs=10) */ ATSstaticdec() ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_aux_20: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp175 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp176 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg0, arg3) ; tmp177 = aux_20 (tmp174, tmp175, arg2, arg3) ; tmp173 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp173, atslab_0, tmp176) ; ats_selptrset_mac(anairiats_sum_6, tmp173, atslab_1, tmp177) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp178 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg0, arg2) ; tmp179 = (ats_sum_ptr_type)0 ; tmp173 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp173, atslab_0, tmp178) ; ats_selptrset_mac(anairiats_sum_6, tmp173, atslab_1, tmp179) ; break ; } while (0) ; return (tmp173) ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 12859(line=406, offs=4) -- 13649(line=433, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_seq_tr_dn_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; __ats_lab_d2exp_seq_tr_dn_19: tmp180 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp183 = aux_20 (tmp181, tmp182, arg2, tmp180) ; tmp172 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq (arg0, arg2, tmp183) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: /* tmp184 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp180, arg2) ; tmp172 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty (arg0, arg2) ; break ; } while (0) ; return (tmp172) ; } /* end of [d2exp_seq_tr_dn_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 13792(line=439, offs=6) -- 14012(line=445, offs=6) */ ATSstaticdec() ats_ptr_type err_22 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; __ats_lab_err_22: /* tmp187 = */ prerr_loc_error3_0 (arg0) ; /* tmp188 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp190 = */ atspre_prerr_string (ATSstrcst("] cannot be assigned to a string constant.")) ; /* tmp191 = */ atspre_prerr_newline () ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp186) ; } /* end of [err_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 13703(line=437, offs=4) -- 16498(line=507, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_string_tr_dn_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_bool_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; // ATSlocal_void (tmp204) ; ATSlocal (ats_size_type, tmp205) ; ATSlocal (ats_int_type, tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_bool_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; // ATSlocal_void (tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_bool_type, tmp224) ; __ats_lab_d2exp_string_tr_dn_21: tmp192 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_loc) ; tmp193 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg3) ; tmp194 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp193), atslab_s2exp_node) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp194)->tag != 0) { goto __ats_lab_53_0 ; } __ats_lab_41_1: tmp195 = ats_caselptrlab_mac(anairiats_sum_1, tmp194, atslab_0) ; tmp196 = ats_caselptrlab_mac(anairiats_sum_1, tmp194, atslab_1) ; tmp197 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp195), atslab_s2exp_node) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp197)->tag != 4) { goto __ats_lab_52_0 ; } __ats_lab_42_1: tmp198 = ats_caselptrlab_mac(anairiats_sum_5, tmp197, atslab_0) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp199 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type, tmp198) ; if (!tmp199) { goto __ats_lab_46_1 ; } do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp196 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp201 = ats_caselptrlab_mac(anairiats_sum_6, tmp196, atslab_0) ; tmp200 = tmp201 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: /* tmp202 = */ prerr_interror_2 () ; /* tmp203 = */ atspre_prerr_string (ATSstrcst(": d2exp_string_tr_dn: String_int_type")) ; /* tmp204 = */ atspre_prerr_newline () ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp205 = atspre_string_length (arg1) ; tmp206 = atspre_int1_of_size1 (ats_castfn_mac(ats_size_type, tmp205)) ; tmp208 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp206) ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (tmp192, tmp208, tmp200) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string (tmp192, tmp193, arg1, arg2) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp209 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type, tmp198) ; if (!tmp209) { goto __ats_lab_51_1 ; } do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp196 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_6, tmp196, atslab_0) ; tmp210 = tmp211 ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp196 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: /* tmp212 = */ prerr_interror_2 () ; /* tmp213 = */ atspre_prerr_string (ATSstrcst(": d2exp_string_tr_dn: Printf_c_types_type")) ; /* tmp214 = */ atspre_prerr_newline () ; /* tmp210 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__printf_c_string_parse (arg1) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp216 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp217 = ats_caselptrlab_mac(anairiats_sum_2, tmp216, atslab_0) ; ATS_FREE(tmp216) ; tmp215 = tmp217 ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp216 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: /* tmp218 = */ prerr_loc_error3_0 (tmp192) ; /* tmp219 = */ atspre_prerr_string (ATSstrcst(": the c-format string is invalid.")) ; /* tmp220 = */ atspre_prerr_newline () ; /* tmp215 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtypes (tmp215) ; /* tmp222 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp192, tmp210, tmp221) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string (tmp192, tmp193, arg1, arg2) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp185 = err_22 (tmp192, tmp193) ; break ; } while (0) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp185 = err_22 (tmp192, tmp193) ; break ; } while (0) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp194)->tag != 4) { goto __ats_lab_56_0 ; } __ats_lab_53_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_5, tmp194, atslab_0) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp224 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type, tmp223) ; if (!tmp224) { goto __ats_lab_55_1 ; } tmp185 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string (tmp192, tmp193, arg1, arg2) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp185 = err_22 (tmp192, tmp193) ; break ; } while (0) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp185 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, tmp193) ; break ; } while (0) ; return (tmp185) ; } /* end of [d2exp_string_tr_dn_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 16574(line=512, offs=13) -- 28762(line=822, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_int_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_int_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; // ATSlocal_void (tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; ATSlocal (ats_int_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_int_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_bool_type, tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; ATSlocal (ats_bool_type, tmp275) ; // ATSlocal_void (tmp276) ; ATSlocal (ats_bool_type, tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; ATSlocal (ats_bool_type, tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; ATSlocal (ats_bool_type, tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_bool_type, tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; // ATSlocal_void (tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_int_type, tmp302) ; // ATSlocal_void (tmp303) ; ATSlocal (ats_bool_type, tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; // ATSlocal_void (tmp307) ; ATSlocal (ats_bool_type, tmp308) ; // ATSlocal_void (tmp309) ; ATSlocal (ats_bool_type, tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_bool_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_int_type, tmp316) ; // ATSlocal_void (tmp317) ; ATSlocal (ats_bool_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; // ATSlocal_void (tmp320) ; // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; // ATSlocal_void (tmp323) ; // ATSlocal_void (tmp324) ; ATSlocal (ats_bool_type, tmp325) ; // ATSlocal_void (tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; ATSlocal (ats_bool_type, tmp339) ; // ATSlocal_void (tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; // ATSlocal_void (tmp346) ; ATSlocal (ats_int_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; // ATSlocal_void (tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; // ATSlocal_void (tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; ATSlocal (ats_int_type, tmp364) ; ATSlocal (ats_int_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_int_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_bool_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; // ATSlocal_void (tmp383) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_bool_type, tmp385) ; // ATSlocal_void (tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; // ATSlocal_void (tmp389) ; // ATSlocal_void (tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; // ATSlocal_void (tmp394) ; ATSlocal (ats_bool_type, tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_int_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_int_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_int_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; // ATSlocal_void (tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; ATSlocal (ats_bool_type, tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; // ATSlocal_void (tmp430) ; // ATSlocal_void (tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; // ATSlocal_void (tmp434) ; ATSlocal (ats_bool_type, tmp435) ; ATSlocal (ats_bool_type, tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; // ATSlocal_void (tmp441) ; // ATSlocal_void (tmp442) ; // ATSlocal_void (tmp443) ; // ATSlocal_void (tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_int_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; // ATSlocal_void (tmp466) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn: tmp226 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_loc) ; tmp227 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp227)->tag != 3) { goto __ats_lab_60_0 ; } __ats_lab_57_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; tmp230 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp228), atslab_d2exp_node) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp230)->tag != 40) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp231 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp232 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short (tmp226, tmp231, tmp229) ; arg0 = tmp232 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp227)->tag != 9) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp233 = ats_caselptrlab_mac(anairiats_sum_8, tmp227, atslab_0) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_8, tmp227, atslab_1) ; tmp235 = ats_caselptrlab_mac(anairiats_sum_8, tmp227, atslab_2) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_8, tmp227, atslab_3) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_8, tmp227, atslab_4) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn (tmp226, tmp233, tmp234, tmp235, tmp236, tmp237, arg1) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp227)->tag != 17) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp238 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp239 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; /* tmp240 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask (tmp238) ; /* tmp241 = ats_selsin_mac(tmp240, atslab_1) */ ; tmp242 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp239, arg1) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask (tmp226, tmp238, tmp242) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp227)->tag != 19) { goto __ats_lab_65_0 ; } __ats_lab_62_1: tmp244 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp245 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; tmp246 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp248 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp246), atslab_s2exp_node) ; do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp248)->tag != 35) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_1, tmp248, atslab_0) ; tmp250 = ats_caselptrlab_mac(anairiats_sum_1, tmp248, atslab_1) ; tmp251 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg (tmp226, tmp249, tmp244) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth (tmp251, tmp250) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: tmp247 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg (tmp226, tmp246, tmp244) ; break ; } while (0) ; arg0 = tmp245 ; arg1 = tmp247 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn ; // tail call break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp227)->tag != 22) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_0) ; tmp225 = d2exp_float_tr_dn_9 (arg0, tmp252, arg1) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp227)->tag != 27) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_0) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_1) ; tmp255 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_2) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_3) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn (tmp226, tmp253, tmp254, tmp255, tmp256, arg1) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp227)->tag != 28) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; tmp225 = d2exp_int_tr_dn_15 (arg0, tmp257, tmp258, arg1) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp227)->tag != 30) { goto __ats_lab_79_0 ; } __ats_lab_68_1: tmp259 = ats_caselptrlab_mac(anairiats_sum_10, tmp227, atslab_0) ; tmp260 = ats_caselptrlab_mac(anairiats_sum_10, tmp227, atslab_1) ; tmp261 = ats_caselptrlab_mac(anairiats_sum_10, tmp227, atslab_2) ; tmp262 = ats_caselptrlab_mac(anairiats_sum_10, tmp227, atslab_3) ; tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp264 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp263), atslab_s2exp_node) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp264)->tag != 11) { goto __ats_lab_76_0 ; } __ats_lab_69_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_0) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_1) ; tmp267 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_2) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_3) ; tmp269 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_4) ; tmp270 = ats_caselptrlab_mac(anairiats_sum_11, tmp264, atslab_5) ; tmp272 = atspre_neq_int_int (tmp259, tmp266) ; if (tmp272) { /* tmp273 = */ prerr_loc_error3_0 (tmp226) ; tmp275 = atspre_gt_int_int (tmp259, tmp266) ; if (tmp275) { /* tmp274 = */ atspre_prerr_string (ATSstrcst(" linear function is given a nonlinear type .")) ; } else { /* empty */ } /* end of [if] */ tmp277 = atspre_lt_int_int (tmp259, tmp266) ; if (tmp277) { /* tmp276 = */ atspre_prerr_string (ATSstrcst(" nonlinear function is given a linear type .")) ; } else { /* empty */ } /* end of [if] */ /* tmp278 = */ atspre_prerr_newline () ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp280 = atspre_neq_int_int (tmp260, tmp268) ; if (tmp280) { /* tmp281 = */ prerr_loc_error3_0 (tmp226) ; /* tmp282 = */ atspre_prerr_string (ATSstrcst(": this function is expected to have")) ; tmp284 = atspre_gt_int_int (tmp260, tmp268) ; if (tmp284) { /* tmp283 = */ atspre_prerr_string (ATSstrcst(" fewer proof arguments.")) ; } else { /* empty */ } /* end of [if] */ tmp286 = atspre_lt_int_int (tmp260, tmp268) ; if (tmp286) { /* tmp285 = */ atspre_prerr_string (ATSstrcst(" more proof arguments.")) ; } else { /* empty */ } /* end of [if] */ /* tmp287 = */ atspre_prerr_newline () ; /* tmp279 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp288 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* ats_ptr_type tmp289 ; */ tmp290 = d2exp_funclo_opt_of_d2exp_6 (tmp262, (&tmp289)) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (tmp289 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp292 = ats_caselptrlab_mac(anairiats_sum_2, tmp289, atslab_0) ; ATS_FREE(tmp289) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve (tmp226, tmp292, tmp265) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (tmp289 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: break ; } while (0) ; /* ats_ptr_type tmp293 ; */ tmp294 = d2exp_s2eff_opt_of_d2exp_7 (tmp290, (&tmp293)) ; do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (tmp293 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp296 = ats_caselptrlab_mac(anairiats_sum_2, tmp293, atslab_0) ; ATS_FREE(tmp293) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve (tmp226, tmp296, tmp267) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (tmp293 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: break ; } while (0) ; /* tmp297 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam (tmp267) ; /* tmp298 = ats_selsin_mac(tmp297, atslab_1) */ ; /* tmp299 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (tmp259) ; /* tmp300 = ats_selsin_mac(tmp299, atslab_1) */ ; /* tmp301 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst (tmp261) ; tmp302 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (tmp261, tmp269) ; tmp304 = atspre_ineq (tmp302, 0) ; if (tmp304) { /* tmp305 = */ prerr_loc_error3_0 (tmp226) ; /* tmp306 = */ atspre_prerr_string (ATSstrcst(": the funcion is expected to have")) ; tmp308 = atspre_igt (tmp302, 0) ; if (tmp308) { /* tmp307 = */ atspre_prerr_string (ATSstrcst(" fewer arguments.")) ; } else { /* empty */ } /* end of [if] */ tmp310 = atspre_ilt (tmp302, 0) ; if (tmp310) { /* tmp309 = */ atspre_prerr_string (ATSstrcst(" more arguments.")) ; } else { /* empty */ } /* end of [if] */ /* tmp311 = */ atspre_prerr_newline () ; /* tmp312 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp313 = atspre_ieq (tmp302, 0) ; /* tmp303 = */ atspre_assert (tmp313) ; } else { /* empty */ } /* end of [if] */ tmp315 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp261) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (tmp315) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (tmp314 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp316 = 0 ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (tmp314 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp316 = 1 ; break ; } while (0) ; tmp318 = atspre_eq_int_int (tmp316, 0) ; if (tmp318) { /* tmp317 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (tmp226, 1, tmp314, tmp269) ; } else { /* empty */ } /* end of [if] */ tmp319 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_dn (tmp260, tmp261, tmp269) ; /* tmp320 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam (tmp319) ; /* tmp321 = ats_selsin_mac(tmp320, atslab_1) */ ; tmp322 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp294, tmp270) ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp226) ; tmp325 = atspre_gt_int_int (tmp259, 0) ; if (tmp325) { /* tmp324 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam (tmp226) ; } else { /* empty */ } /* end of [if] */ /* tmp326 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; /* tmp327 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () ; /* tmp328 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp226) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn (tmp226, tmp263, tmp259, tmp260, tmp319, tmp322) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp264)->tag != 30) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_12, tmp264, atslab_0) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_12, tmp264, atslab_1) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_12, tmp264, atslab_2) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp334 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp330) ; /* tmp335 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (tmp226, tmp331) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg0, tmp332) ; /* tmp337 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp226) ; /* tmp338 = */ ats_dynexp3_d3exp_set_typ (tmp336, tmp263) ; tmp225 = tmp336 ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: __ats_lab_77_1: tmp339 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun (tmp263) ; if (!tmp339) { goto __ats_lab_78_1 ; } /* tmp340 = */ prerr_loc_error3_0 (tmp226) ; /* tmp341 = */ atspre_prerr_string (ATSstrcst(": the function is assigned a non-function type [")) ; /* tmp342 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp263) ; /* tmp343 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp344 = */ atspre_prerr_newline () ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: __ats_lab_78_1: tmp345 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg0) ; /* tmp346 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn (tmp345, tmp263) ; tmp225 = tmp345 ; break ; } while (0) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp227)->tag != 37) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp347 = ats_caselptrlab_mac(anairiats_sum_13, tmp227, atslab_0) ; tmp348 = ats_caselptrlab_mac(anairiats_sum_13, tmp227, atslab_1) ; tmp349 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup (tmp226, 0, tmp347, tmp348) ; arg0 = tmp349 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn ; // tail call break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp227)->tag != 36) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_1, tmp227, atslab_1) ; /* tmp352 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push () ; /* tmp353 = ats_selsin_mac(tmp352, atslab_1) */ ; /* tmp354 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp355 = ats_selsin_mac(tmp354, atslab_1) */ ; /* tmp356 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let () ; /* tmp357 = ats_selsin_mac(tmp356, atslab_1) */ ; tmp358 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp350) ; tmp359 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp351, arg1) ; /* tmp360 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp226) ; /* tmp361 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let () ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () ; /* tmp363 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let (tmp226, tmp358, tmp359) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp227)->tag != 44) { goto __ats_lab_85_0 ; } __ats_lab_81_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_14, tmp227, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_14, tmp227, atslab_1) ; tmp366 = ats_caselptrlab_mac(anairiats_sum_14, tmp227, atslab_2) ; /* ats_int_type tmp367 ; */ tmp367 = 0 ; tmp368 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; /* ats_ptr_type tmp369 ; */ tmp369 = tmp368 ; tmp371 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (tmp369) ; if (tmp371) { tmp367 = 1 ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate (tmp226, tmp369) ; tmp369 = tmp372 ; tmp373 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp369) ; tmp369 = tmp373 ; } else { /* empty */ } /* end of [if] */ tmp374 = tmp369 ; tmp375 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp374), atslab_s2exp_node) ; do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp375)->tag != 29) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_15, tmp375, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_15, tmp375, atslab_1) ; tmp378 = ats_caselptrlab_mac(anairiats_sum_15, tmp375, atslab_2) ; /* tmp379 = */ reckind_check_5 (tmp226, tmp364, tmp376) ; /* tmp380 = */ pfarity_check_rec_4 (tmp226, tmp365, tmp377) ; tmp381 = labd2explst_tr_dn_18 (tmp226, tmp366, tmp378) ; tmp382 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec (tmp226, tmp374, tmp364, tmp365, tmp381) ; tmp384 = atspre_gt_int_int (tmp367, 0) ; if (tmp384) { /* tmp383 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check (tmp226) ; } else { /* empty */ } /* end of [if] */ tmp225 = tmp382 ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp385 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec (tmp374) ; if (!tmp385) { goto __ats_lab_84_1 ; } /* tmp386 = */ prerr_loc_error3_0 (tmp226) ; /* tmp387 = */ atspre_prerr_string (ATSstrcst(": the record is assigned a non-record type [")) ; /* tmp388 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp374) ; /* tmp389 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp390 = */ atspre_prerr_newline () ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp391 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg0) ; tmp393 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp391), atslab_d3exp_typ) ; /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp226, tmp393, tmp374) ; tmp395 = atspre_gt_int_int (tmp367, 0) ; if (tmp395) { /* tmp394 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check (tmp226) ; } else { /* empty */ } /* end of [if] */ /* tmp396 = */ ats_dynexp3_d3exp_set_typ (tmp391, tmp374) ; tmp225 = tmp391 ; break ; } while (0) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp227)->tag != 45) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp397 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_0) ; tmp398 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_1) ; tmp399 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_2) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn (tmp226, tmp397, tmp398, tmp399, arg1) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp227)->tag != 47) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_0) ; tmp225 = d2exp_seq_tr_dn_19 (tmp226, tmp400, arg1) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp227)->tag != 49) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp401 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_0) ; tmp402 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_1) ; tmp403 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_2) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_9, tmp227, atslab_3) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn (tmp226, tmp401, tmp402, tmp403, tmp404, arg1) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp227)->tag != 51) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_16, tmp227, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_16, tmp227, atslab_1) ; tmp225 = d2exp_string_tr_dn_21 (arg0, tmp405, tmp406, arg1) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp227)->tag != 50) { goto __ats_lab_97_0 ; } __ats_lab_89_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_5, tmp227, atslab_0) ; /* ats_int_type tmp408 ; */ tmp408 = 0 ; tmp410 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (arg1) ; if (tmp410) { tmp408 = 1 ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate (tmp226, arg1) ; } else { tmp409 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; } /* end of [if] */ tmp411 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp409), atslab_s2exp_node) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp411)->tag != 29) { goto __ats_lab_95_0 ; } __ats_lab_90_1: tmp412 = ats_caselptrlab_mac(anairiats_sum_15, tmp411, atslab_0) ; tmp413 = ats_caselptrlab_mac(anairiats_sum_15, tmp411, atslab_1) ; tmp414 = ats_caselptrlab_mac(anairiats_sum_15, tmp411, atslab_2) ; do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp412)->tag != 0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: /* tmp416 = */ prerr_loc_error3_0 (tmp226) ; /* tmp417 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp418 = */ atspre_prerr_string (ATSstrcst(": the type for a struct cannot be boxed.")) ; /* tmp419 = */ atspre_prerr_newline () ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp412)->tag != 1) { goto __ats_lab_93_0 ; } __ats_lab_92_1: /* tmp420 = */ prerr_loc_error3_0 (tmp226) ; /* tmp421 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp422 = */ atspre_prerr_string (ATSstrcst(": the type for a struct cannot be a record type.")) ; /* tmp423 = */ atspre_prerr_newline () ; /* tmp415 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp412)->tag != 2) { goto __ats_lab_94_0 ; } __ats_lab_93_1: break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (((ats_sum_ptr_type)tmp412)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: break ; } while (0) ; tmp425 = atspre_gt_int_int (tmp413, 0) ; if (tmp425) { /* tmp426 = */ prerr_loc_error3_0 (tmp226) ; /* tmp427 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp428 = */ atspre_prerr_string (ATSstrcst(": the proof arity of a struct cannot be [")) ; /* tmp429 = */ atspre_prerr_int (tmp413) ; /* tmp430 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp431 = */ atspre_prerr_newline () ; /* tmp424 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp432 = labd2explst_tr_dn_18 (tmp226, tmp407, tmp414) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_struct (tmp226, tmp409, tmp432) ; tmp435 = atspre_gt_int_int (tmp408, 0) ; if (tmp435) { /* tmp434 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check (tmp226) ; } else { /* empty */ } /* end of [if] */ tmp225 = tmp433 ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp436 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun (tmp409) ; if (!tmp436) { goto __ats_lab_96_1 ; } /* tmp437 = */ prerr_loc_error3_0 (tmp226) ; /* tmp438 = */ atspre_prerr_string (ATSstrcst(": the struct is assigned a non-record type [")) ; /* tmp439 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp409) ; /* tmp440 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp441 = */ atspre_prerr_newline () ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: __ats_lab_96_1: /* tmp442 = */ prerr_loc_error3_0 (tmp226) ; /* tmp443 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_tr_dn"), ATSstrcst("ats_trans3_exp_dn.dats")) ; /* tmp444 = */ atspre_prerr_string (ATSstrcst(": the struct is given a type of an incorrect form [")) ; /* tmp445 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp409) ; /* tmp446 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp447 = */ atspre_prerr_newline () ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp227)->tag != 54) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp448 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (arg1) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top (tmp226, tmp448) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp227)->tag != 55) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp449 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_0) ; tmp450 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_1) ; tmp451 = ats_caselptrlab_mac(anairiats_sum_12, tmp227, atslab_2) ; /* tmp452 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try () ; /* tmp453 = ats_selsin_mac(tmp452, atslab_1) */ ; tmp454 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp450, arg1) ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype () ; tmp457 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp454), atslab_d3exp_loc) ; tmp456 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top (tmp457, tmp455) ; /* ats_int_type tmp458 ; */ tmp458 = 0 ; tmp460 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp460, atslab_0, tmp456) ; tmp461 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp460), atslab_1) ; tmp462 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp461) = tmp462 ; tmp463 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp463, atslab_0, tmp455) ; tmp464 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp463), atslab_1) ; tmp465 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp464) = tmp465 ; tmp459 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn (tmp226, (&tmp458), -1, tmp449, tmp451, tmp460, 1, tmp463, arg1) ; /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try () ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith (tmp226, tmp454, tmp459) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: tmp225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (arg0, arg1) ; break ; } while (0) ; return (tmp225) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 28836(line=827, offs=18) -- 29344(line=844, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_int_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_bool_type, tmp472) ; // ATSlocal_void (tmp473) ; // ATSlocal_void (tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; // ATSlocal_void (tmp476) ; ATSlocal (ats_bool_type, tmp477) ; // ATSlocal_void (tmp478) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest: tmp468 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d2exp_loc) ; /* ats_int_type tmp469 ; */ tmp469 = 0 ; tmp470 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg0) ; tmp472 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (arg1) ; if (tmp472) { tmp469 = 1 ; /* tmp473 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp470) ; tmp471 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate (tmp468, arg1) ; } else { tmp471 = arg1 ; } /* end of [if] */ tmp475 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp470), atslab_d3exp_typ) ; /* tmp474 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp468, tmp475, tmp471) ; tmp477 = atspre_gt_int_int (tmp469, 0) ; if (tmp477) { /* tmp476 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check (tmp468) ; } else { /* empty */ } /* end of [if] */ /* tmp478 = */ ats_dynexp3_d3exp_set_typ (tmp470, tmp471) ; tmp467 = tmp470 ; return (tmp467) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn_rest] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 29424(line=849, offs=19) -- 30082(line=869, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_bool_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; // ATSlocal_void (tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn: tmp480 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg2) ; tmp481 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp480), atslab_s2exp_node) ; do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp481)->tag != 0) { goto __ats_lab_103_0 ; } __ats_lab_100_1: tmp482 = ats_caselptrlab_mac(anairiats_sum_1, tmp481, atslab_0) ; tmp483 = ats_caselptrlab_mac(anairiats_sum_1, tmp481, atslab_1) ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype, tmp482) ; if (!tmp484) { goto __ats_lab_103_1 ; } do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (tmp483 == (ats_sum_ptr_type)0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp486 = ats_caselptrlab_mac(anairiats_sum_6, tmp483, atslab_0) ; tmp485 = tmp486 ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: // if (tmp483 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_102_1: /* tmp487 = */ prerr_loc_interror_3 (arg0) ; /* tmp488 = */ atspre_prerr_string (ATSstrcst(": assert_bool_tr_dn")) ; /* tmp489 = */ atspre_prerr_newline () ; /* tmp485 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp490 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (arg1) ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp490, tmp485) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: __ats_lab_103_1: tmp491 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype () ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp480, tmp491) ; break ; } while (0) ; return /* (tmp479) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 30138(line=873, offs=4) -- 30599(line=890, offs=4) */ ATSstaticdec() ats_ptr_type m2atch_tr_up_26 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; // ATSlocal_void (tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; __ats_lab_m2atch_tr_up_26: tmp493 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_m2atch_loc) ; tmp495 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_m2atch_exp) ; tmp494 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp495) ; tmp497 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_m2atch_pat) ; do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (tmp497 == (ats_sum_ptr_type)0) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp498 = ats_caselptrlab_mac(anairiats_sum_2, tmp497, atslab_0) ; tmp500 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp494), atslab_d3exp_typ) ; tmp499 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2at_tr_dn (tmp498, tmp500) ; tmp496 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp496, atslab_0, tmp499) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (tmp497 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: tmp502 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp494), atslab_d3exp_typ) ; /* tmp501 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn (tmp493, ats_true_bool, tmp502) ; tmp496 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp492 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__m3atch_make (tmp493, tmp494, tmp496) ; return (tmp492) ; } /* end of [m2atch_tr_up_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 30629(line=892, offs=4) -- 30718(line=893, offs=42) */ ATSstaticdec() ats_ptr_type m2atchlst_tr_up_27 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp503) ; __ats_lab_m2atchlst_tr_up_27: tmp503 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &m2atch_tr_up_26) ; return (tmp503) ; } /* end of [m2atchlst_tr_up_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 31532(line=919, offs=9) -- 31801(line=926, offs=21) */ ATSstaticdec() ats_void_type aux_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; // ATSlocal_void (tmp519) ; __ats_lab_aux_29: do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp515 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp516 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp517 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp518 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; /* tmp519 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_pat (tmp515, tmp517) ; arg0 = tmp516 ; arg1 = tmp518 ; goto __ats_lab_aux_29 ; // tail call break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: break ; } while (0) ; return /* (tmp514) */ ; } /* end of [aux_29] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 30742(line=896, offs=13) -- 32563(line=948, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; // ATSlocal_void (tmp507) ; // ATSlocal_void (tmp508) ; // ATSlocal_void (tmp509) ; // ATSlocal_void (tmp510) ; // ATSlocal_void (tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; // ATSlocal_void (tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_int_type, tmp523) ; ATSlocal (ats_int_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_bool_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_bool_type, tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; // ATSlocal_void (tmp535) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn: tmp505 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_loc) ; tmp506 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_pat) ; /* tmp507 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp508 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let () ; /* tmp509 = ats_selsin_mac(tmp508, atslab_1) */ ; /* tmp510 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst (tmp506) ; do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp512 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; ATS_FREE(arg1) ; /* tmp511 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlstlst (tmp505, tmp512, arg4) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: break ; } while (0) ; tmp513 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_tr_dn (tmp506, arg4) ; /* tmp520 = */ aux_29 (arg2, tmp513) ; tmp522 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_gua) ; tmp521 = m2atchlst_tr_up_27 (tmp522) ; tmp523 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_seq) ; tmp524 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_neg) ; tmp526 = atspre_gt_int_int (tmp524, 0) ; if (tmp526) { tmp525 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_exi () ; } else { tmp525 = arg5 ; } /* end of [if] */ tmp528 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_c2lau_exp) ; tmp527 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp528, tmp525) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (arg6 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp530 = ats_caselptrlab_mac(anairiats_sum_6, arg6, atslab_0) ; tmp531 = ats_caselptrlab_mac(anairiats_sum_6, arg6, atslab_1) ; ATS_FREE(arg6) ; tmp532 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised (arg0) ; if (tmp532) { /* empty */ } else { /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (tmp505, tmp530, tmp531) ; } /* end of [if] */ break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (arg6 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: break ; } while (0) ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp505) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let () ; /* tmp535 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp505) ; tmp504 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__c3lau_make (tmp505, tmp513, tmp521, tmp523, tmp524, tmp527) ; return (tmp504) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 32613(line=952, offs=4) -- 32799(line=957, offs=4) */ ATSstaticdec() ats_void_type pattern_match_is_redundant_errmsg_30 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp536) ; // ATSlocal_void (tmp537) ; // ATSlocal_void (tmp538) ; // ATSlocal_void (tmp539) ; __ats_lab_pattern_match_is_redundant_errmsg_30: /* tmp537 = */ prerr_loc_error3_0 (arg0) ; /* tmp538 = */ atspre_prerr_string (ATSstrcst(": this pattern match clause is redundant.")) ; /* tmp539 = */ atspre_prerr_newline () ; /* tmp536 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp536) */ ; } /* end of [pattern_match_is_redundant_errmsg_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 32871(line=962, offs=1) -- 33530(line=989, offs=4) */ ATSstaticdec() ats_void_type c2laulst0_tr_dn_31 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp540) ; ATSlocal (ats_bool_type, tmp541) ; // ATSlocal_void (tmp542) ; // ATSlocal_void (tmp543) ; ATSlocal (ats_bool_type, tmp544) ; // ATSlocal_void (tmp545) ; // ATSlocal_void (tmp546) ; // ATSlocal_void (tmp547) ; __ats_lab_c2laulst0_tr_dn_31: do { /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp541 = atspre_eq_int_int (arg1, 0) ; if (!tmp541) { goto __ats_lab_113_1 ; } /* tmp542 = */ prerr_loc_warning3_1 (arg0) ; /* tmp543 = */ atspre_prerr_string (ATSstrcst(": a case-expression is expected to have at least one match clause.")) ; /* tmp540 = */ atspre_prerr_newline () ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: tmp544 = atspre_gt_int_int (arg1, 0) ; if (!tmp544) { goto __ats_lab_114_1 ; } /* tmp545 = */ prerr_loc_error3_0 (arg0) ; /* tmp546 = */ atspre_prerr_string (ATSstrcst(": a case+-expression is required to have at least one match clause.")) ; /* tmp547 = */ atspre_prerr_newline () ; /* tmp540 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: break ; } while (0) ; return /* (tmp540) */ ; } /* end of [c2laulst0_tr_dn_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 33563(line=992, offs=1) -- 34132(line=1013, offs=4) */ ATSstaticdec() ats_ptr_type c2laulst1_tr_dn_32 (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) { /* local vardec */ ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; // ATSlocal_void (tmp554) ; ATSlocal (ats_bool_type, tmp555) ; __ats_lab_c2laulst1_tr_dn_32: tmp549 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement (arg4) ; do { /* branch: __ats_lab_115 */ __ats_lab_115_0: if (tmp549 == (ats_sum_ptr_type)0) { goto __ats_lab_116_0 ; } __ats_lab_115_1: break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (tmp549 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: ats_ptrget_mac(ats_int_type, arg1) = 1 ; break ; } while (0) ; tmp552 = (ats_sum_ptr_type)0 ; tmp553 = (ats_sum_ptr_type)0 ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn (arg4, tmp552, arg5, arg6, arg7, arg8, tmp553) ; tmp555 = atspre_eq_int_int (ats_ptrget_mac(ats_int_type, arg1), 0) ; if (tmp555) { /* tmp554 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (arg0, arg2, tmp549, arg7) ; } else { /* empty */ } /* end of [if] */ tmp548 = tmp551 ; return (tmp548) ; } /* end of [c2laulst1_tr_dn_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 34166(line=1016, offs=1) -- 35228(line=1048, offs=4) */ ATSstaticdec() ats_ptr_type c2laulst2_tr_dn_33 (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_int_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) { /* local vardec */ ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; // ATSlocal_void (tmp565) ; ATSlocal (ats_bool_type, tmp566) ; // ATSlocal_void (tmp567) ; // ATSlocal_void (tmp568) ; __ats_lab_c2laulst2_tr_dn_33: /* ats_ptr_type tmp557 ; */ tmp557 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement (arg4) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (arg3, tmp558) ; tmp561 = (ats_sum_ptr_type)0 ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp559) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_1, tmp558) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn (arg4, tmp561, arg6, arg7, arg8, arg9, tmp562) ; tmp563 = c2laulst2_rest_tr_dn_34 (arg0, arg2, tmp560, arg5, (&tmp557), arg6, arg7, arg8, arg9, tmp559, tmp558) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (tmp557 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (tmp557 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: ats_ptrget_mac(ats_int_type, arg1) = 1 ; break ; } while (0) ; tmp566 = atspre_eq_int_int (ats_ptrget_mac(ats_int_type, arg1), 0) ; if (tmp566) { /* tmp565 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (arg0, arg2, tmp557, arg8) ; } else { /* empty */ } /* end of [if] */ /* tmp567 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp559, tmp558) ; /* tmp568 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp559, tmp558) ; tmp556 = tmp563 ; return (tmp556) ; } /* end of [c2laulst2_tr_dn_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 36075(line=1079, offs=13) -- 36513(line=1089, offs=57) */ ATSstaticdec() ats_ptr_type aux_36 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_bool_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; __ats_lab_aux_36: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp576 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp577 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test (tmp576, env0) ; if (tmp578) { tmp579 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp579, atslab_0, tmp576) ; ats_selptrset_mac(anairiats_sum_6, tmp579, atslab_1, arg1) ; arg0 = tmp577 ; arg1 = tmp579 ; goto __ats_lab_aux_36 ; // tail call } else { arg0 = tmp577 ; arg1 = arg1 ; goto __ats_lab_aux_36 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: tmp575 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg1) ; break ; } while (0) ; return (tmp575) ; } /* end of [aux_36] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_36_closure_type ; ats_ptr_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_36 (((aux_36_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_36_closure_init (aux_36_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_36_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0) { aux_36_closure_type *p_clo = ATS_MALLOC(sizeof(aux_36_closure_type)) ; aux_36_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 37190(line=1108, offs=17) -- 37588(line=1116, offs=30) */ ATSstaticdec() ats_ptr_type aux_37 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; __ats_lab_aux_37: do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp593 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference (tmp591, env0) ; tmp594 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp593, arg1) ; arg0 = tmp592 ; arg1 = tmp594 ; goto __ats_lab_aux_37 ; // tail call break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp590 = arg1 ; break ; } while (0) ; return (tmp590) ; } /* end of [aux_37] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_37_closure_type ; ats_ptr_type aux_37_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_37 (((aux_37_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_37_closure_init (aux_37_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_37_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_37_closure_make (ats_ptr_type env0) { aux_37_closure_type *p_clo = ATS_MALLOC(sizeof(aux_37_closure_type)) ; aux_37_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 35542(line=1064, offs=7) -- 38117(line=1133, offs=6) */ ATSstaticdec() ats_ptr_type aux_main_35 (ats_int_type env0, ats_ptr_type env1, ats_int_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type env5, ats_ptr_type env6, ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; // ATSlocal_void (tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_bool_type, tmp586) ; ATSlocal (ats_int_type, tmp587) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; // ATSlocal_void (tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; __ats_lab_aux_main_35: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_119_1: tmp571 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp572 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp573 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp571), atslab_c2lau_pat) ; tmp574 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp573) ; tmp581 = (ats_sum_ptr_type)0 ; tmp580 = aux_36 (tmp574, ats_ptrget_mac(ats_ptr_type, arg1), tmp581) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (tmp580 == (ats_sum_ptr_type)0) { goto __ats_lab_123_0 ; } __ats_lab_122_1: break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: // if (tmp580 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_123_1: do { /* branch: __ats_lab_124 */ __ats_lab_124_0: if (env0 != 0) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp583 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp571), atslab_c2lau_loc) ; /* tmp582 = */ pattern_match_is_redundant_errmsg_30 (tmp583) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (env0 != 1) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp584 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp571), atslab_c2lau_loc) ; /* tmp582 = */ pattern_match_is_redundant_errmsg_30 (tmp584) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: break ; } while (0) ; break ; } while (0) ; tmp587 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp571), atslab_c2lau_seq) ; tmp586 = atspre_gt_int_int (tmp587, 0) ; if (tmp586) { tmp585 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp585, atslab_0, tmp580) ; } else { tmp585 = (ats_sum_ptr_type)0 ; } /* end of [if] */ tmp589 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp571), atslab_c2lau_gua) ; do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (tmp589 != (ats_sum_ptr_type)0) { goto __ats_lab_130_0 ; } __ats_lab_127_1: tmp596 = (ats_sum_ptr_type)0 ; tmp595 = aux_37 (tmp574, ats_ptrget_mac(ats_ptr_type, arg1), tmp596) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp595 ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: // if (tmp589 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_130_1: break ; } while (0) ; /* tmp597 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ (env6) ; tmp599 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp599, atslab_0, env5) ; ats_selptrset_mac(anairiats_sum_6, tmp599, atslab_1, env6) ; tmp598 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2lau_tr_dn (tmp571, tmp585, env1, env2, env3, env4, tmp599) ; tmp600 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp600, atslab_0, tmp598) ; ats_selptrset_mac(anairiats_sum_6, tmp600, atslab_1, arg0) ; arg0 = tmp600 ; arg1 = arg1 ; arg2 = tmp572 ; goto __ats_lab_aux_main_35 ; // tail call break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp570 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg0) ; break ; } while (0) ; return (tmp570) ; } /* end of [aux_main_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_int_type closure_env_2 ; ats_ptr_type closure_env_3 ; ats_ptr_type closure_env_4 ; ats_ptr_type closure_env_5 ; ats_ptr_type closure_env_6 ; } aux_main_35_closure_type ; ats_ptr_type aux_main_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { return aux_main_35 (((aux_main_35_closure_type*)cloptr)->closure_env_0, ((aux_main_35_closure_type*)cloptr)->closure_env_1, ((aux_main_35_closure_type*)cloptr)->closure_env_2, ((aux_main_35_closure_type*)cloptr)->closure_env_3, ((aux_main_35_closure_type*)cloptr)->closure_env_4, ((aux_main_35_closure_type*)cloptr)->closure_env_5, ((aux_main_35_closure_type*)cloptr)->closure_env_6, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux_main_35_closure_init (aux_main_35_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1, ats_int_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type env5, ats_ptr_type env6) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_main_35_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; p_clo->closure_env_5 = env5 ; p_clo->closure_env_6 = env6 ; return ; } /* end of function */ ats_clo_ptr_type aux_main_35_closure_make (ats_int_type env0, ats_ptr_type env1, ats_int_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type env5, ats_ptr_type env6) { aux_main_35_closure_type *p_clo = ATS_MALLOC(sizeof(aux_main_35_closure_type)) ; aux_main_35_closure_init (p_clo, env0, env1, env2, env3, env4, env5, env6) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 35265(line=1050, offs=5) -- 38357(line=1142, offs=4) */ ATSstaticdec() ats_ptr_type c2laulst2_rest_tr_dn_34 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9, ats_ptr_type arg10) { /* local vardec */ ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; __ats_lab_c2laulst2_rest_tr_dn_34: tmp602 = (ats_sum_ptr_type)0 ; tmp601 = aux_main_35 (arg1, arg5, arg6, arg7, arg8, arg9, arg10, tmp602, arg4, arg3) ; tmp569 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp569, atslab_0, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp569, atslab_1, tmp601) ; return (tmp569) ; } /* end of [c2laulst2_rest_tr_dn_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 38422(line=1145, offs=3) -- 39023(line=1163, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn (ats_ptr_type arg0, ats_ref_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) { /* local vardec */ ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; // ATSlocal_void (tmp608) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn: do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_132_1: tmp604 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_0) ; tmp605 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_1) ; do { /* branch: __ats_lab_133 */ __ats_lab_133_0: if (tmp605 == (ats_sum_ptr_type)0) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp603 = c2laulst2_tr_dn_33 (arg0, arg1, arg2, arg3, tmp604, tmp605, arg5, arg6, arg7, arg8) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: // if (tmp605 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_134_1: tmp606 = c2laulst1_tr_dn_32 (arg0, arg1, arg2, arg3, tmp604, arg5, arg6, arg7, arg8) ; tmp607 = (ats_sum_ptr_type)0 ; tmp603 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp603, atslab_0, tmp606) ; ats_selptrset_mac(anairiats_sum_6, tmp603, atslab_1, tmp607) ; break ; } while (0) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: /* tmp608 = */ c2laulst0_tr_dn_31 (arg0, arg2, arg3, arg6, arg7, arg8) ; tmp603 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp603) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 39107(line=1169, offs=3) -- 39744(line=1187, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; // ATSlocal_void (tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_int_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; // ATSlocal_void (tmp616) ; ATSlocal (ats_bool_type, tmp617) ; ATSlocal (ats_bool_type, tmp618) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn: tmp610 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up (arg4) ; /* tmp611 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add (tmp610) ; tmp612 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ (tmp610) ; tmp613 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update (arg2) ; /* ats_int_type tmp614 ; */ tmp614 = 0 ; tmp615 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn (arg0, (&tmp614), arg1, tmp613, arg5, tmp610, arg3, tmp612, arg6) ; tmp617 = atspre_eq_int_int (tmp614, 0) ; if (tmp617) { tmp618 = atspre_lt_int_int (arg1, 1) ; if (tmp618) { /* tmp616 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn (arg0) ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp609 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_caseof (arg0, arg6, arg1, tmp610, tmp615) ; return (tmp609) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 40023(line=1198, offs=6) -- 40608(line=1211, offs=6) */ ATSstaticdec() ats_ptr_type aux_one_41 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; // ATSlocal_void (tmp629) ; // ATSlocal_void (tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; // ATSlocal_void (tmp634) ; // ATSlocal_void (tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; __ats_lab_aux_one_41: tmp624 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_sc2lau_pat) ; tmp625 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_sc2lau_exp) ; /* tmp626 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp627 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp624), atslab_sp2at_node) ; // tmp628 = ats_caselptrlab_mac(anairiats_sum_6, tmp627, atslab_1) ; /* tmp629 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp628) ; tmp631 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp624), atslab_sp2at_loc) ; tmp632 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp624), atslab_sp2at_exp) ; /* tmp630 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (tmp631, env1, tmp632) ; tmp633 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp625, env2) ; /* tmp634 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (env0, env4, env3) ; tmp636 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp625), atslab_d2exp_loc) ; /* tmp635 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp636) ; tmp637 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_sc2lau_loc) ; tmp623 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__sc3lau_make (tmp637, tmp624, tmp633) ; return (tmp623) ; } /* end of [aux_one_41] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; ats_ptr_type closure_env_4 ; } aux_one_41_closure_type ; ats_ptr_type aux_one_41_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_one_41 (((aux_one_41_closure_type*)cloptr)->closure_env_0, ((aux_one_41_closure_type*)cloptr)->closure_env_1, ((aux_one_41_closure_type*)cloptr)->closure_env_2, ((aux_one_41_closure_type*)cloptr)->closure_env_3, ((aux_one_41_closure_type*)cloptr)->closure_env_4, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_one_41_closure_init (aux_one_41_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_one_41_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type aux_one_41_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) { aux_one_41_closure_type *p_clo = ATS_MALLOC(sizeof(aux_one_41_closure_type)) ; aux_one_41_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 40636(line=1213, offs=7) -- 40921(line=1221, offs=33) */ ATSstaticdec() ats_ptr_type aux_rest_42 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; // ATSlocal_void (tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; __ats_lab_aux_rest_42: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp640 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; /* tmp641 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ (env3) ; tmp642 = aux_one_41 (env0, env1, env2, env3, env4, tmp639) ; tmp643 = aux_rest_42 (env0, env1, env2, env3, env4, tmp640) ; tmp638 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp638, atslab_0, tmp642) ; ats_selptrset_mac(anairiats_sum_6, tmp638, atslab_1, tmp643) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp638 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp638) ; } /* end of [aux_rest_42] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; ats_ptr_type closure_env_3 ; ats_ptr_type closure_env_4 ; } aux_rest_42_closure_type ; ats_ptr_type aux_rest_42_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_rest_42 (((aux_rest_42_closure_type*)cloptr)->closure_env_0, ((aux_rest_42_closure_type*)cloptr)->closure_env_1, ((aux_rest_42_closure_type*)cloptr)->closure_env_2, ((aux_rest_42_closure_type*)cloptr)->closure_env_3, ((aux_rest_42_closure_type*)cloptr)->closure_env_4, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_rest_42_closure_init (aux_rest_42_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_rest_42_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; p_clo->closure_env_3 = env3 ; p_clo->closure_env_4 = env4 ; return ; } /* end of function */ ats_clo_ptr_type aux_rest_42_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type env3, ats_ptr_type env4) { aux_rest_42_closure_type *p_clo = ATS_MALLOC(sizeof(aux_rest_42_closure_type)) ; aux_rest_42_closure_init (p_clo, env0, env1, env2, env3, env4) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_dn.dats: 39833(line=1192, offs=3) -- 41386(line=1237, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; // ATSlocal_void (tmp649) ; // ATSlocal_void (tmp650) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn: tmp620 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_update (arg1) ; tmp621 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () ; tmp622 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (tmp620, tmp621) ; do { /* branch: __ats_lab_138 */ __ats_lab_138_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp645 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_0) ; tmp646 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_1) ; tmp647 = aux_one_41 (arg0, arg2, arg4, tmp621, tmp622, tmp645) ; tmp648 = aux_rest_42 (arg0, arg2, arg4, tmp621, tmp622, tmp646) ; tmp644 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp644, atslab_0, tmp647) ; ats_selptrset_mac(anairiats_sum_6, tmp644, atslab_1, tmp648) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: tmp644 = (ats_sum_ptr_type)0 ; break ; } while (0) ; /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp622, tmp621) ; /* tmp650 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp622, tmp621) ; tmp619 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_scaseof (arg0, arg4, arg2, tmp644) ; return (tmp619) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_dn_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_exp_dn_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_list_dats.c0000664000175000017500000011105012223166160021070 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isucc) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_fun_coerce) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_int_type loop_8 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type aux_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type app_13 (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; static ats_void_type loop_19 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_21 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) ; static ats_void_type aux_28 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type list_vt_copy_01706_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type list_vt_free_01708_ats_ptr_type (ats_ptr_type arg0) ; static ats_int_type aux_33 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_int_type list_vt_length_01710_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type aux_35 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_clo_ptr_type aux_35_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_35_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 1867(line=55, offs=14) -- 1929(line=56, offs=56) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp0 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp0 = ats_false_bool ; break ; } while (0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 2069(line=67, offs=7) -- 2427(line=78, offs=6) */ ATSstaticdec() ats_void_type aux_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_aux_2: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp5 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp5, atslab_0, tmp3) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp5 ; // if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp6 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; arg0 = tmp4 ; arg1 = arg1 ; arg2 = tmp6 ; goto __ats_lab_aux_2 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: ats_ptrget_mac(ats_ptr_type, arg2) = arg1 ; break ; } while (0) ; return /* (tmp2) */ ; } /* end of [aux_2] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 2048(line=66, offs=7) -- 2510(line=82, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append: /* ats_ptr_type tmp7 ; */ /* tmp8 = */ aux_2 (arg0, arg1, (&tmp7)) ; tmp1 = tmp7 ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 2579(line=87, offs=13) -- 2645(line=89, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend: tmp11 = (ats_sum_ptr_type)0 ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp10, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_0, tmp10, atslab_1, tmp11) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg0, tmp10) ; return (tmp9) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 2720(line=94, offs=19) -- 2853(line=97, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; /* tmp15 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp13, arg2) ; arg0 = tmp14 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 2912(line=100, offs=18) -- 3010(line=102, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; /* tmp19 = */ ((ats_void_type(*)(ats_ptr_type))arg1) (tmp17) ; arg0 = tmp18 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: break ; } while (0) ; return /* (tmp16) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 3071(line=105, offs=21) -- 3172(line=107, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; /* tmp23 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg1))) (arg1, tmp21) ; arg0 = tmp22 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp20) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 3270(line=113, offs=7) -- 3397(line=115, offs=60) */ ATSstaticdec() ats_int_type loop_8 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_int_type, tmp27) ; __ats_lab_loop_8: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp27 = atspre_isucc (arg1) ; arg0 = tmp26 ; arg1 = tmp27 ; goto __ats_lab_loop_8 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp25 = arg1 ; break ; } while (0) ; return (tmp25) ; } /* end of [loop_8] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 3253(line=112, offs=17) -- 3438(line=119, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length: tmp24 = loop_8 (arg0, 0) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 3611(line=129, offs=7) -- 4039(line=143, offs=6) */ ATSstaticdec() ats_void_type aux_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_aux_10: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp31 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp32 = ((ats_ptr_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp30, arg3) ; tmp33 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp33, atslab_0, tmp32) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp33 ; // if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp34 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; arg0 = tmp31 ; arg1 = arg1 ; arg2 = tmp34 ; arg3 = arg3 ; goto __ats_lab_aux_10 ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp35 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp35 ; break ; } while (0) ; return /* (tmp29) */ ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 3581(line=128, offs=30) -- 4131(line=147, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main: /* ats_ptr_type tmp36 ; */ /* tmp37 = */ aux_10 (arg0, arg1, (&tmp36), arg2) ; tmp28 = tmp36 ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 4200(line=150, offs=32) -- 4421(line=158, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun: tmp39 = atspre_fun_coerce (arg1) ; /* ats_ptr_type tmp40 ; */ tmp40 = atspre_null_ptr ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main (arg0, tmp39, tmp40) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 4554(line=164, offs=6) -- 4606(line=164, offs=58) */ ATSstaticdec() ats_ptr_type app_13 (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_app_13: tmp42 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg1))) (arg1, arg0) ; return (tmp42) ; } /* end of [app_13] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 4494(line=162, offs=21) -- 4735(line=170, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr: tmp41 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main (arg0, &app_13, arg1) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 4808(line=175, offs=13) -- 4886(line=176, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp45 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp46, atslab_0, tmp44) ; ats_selptrset_mac(anairiats_sum_0, tmp46, atslab_1, arg1) ; arg0 = tmp45 ; arg1 = tmp46 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp43 = arg1 ; break ; } while (0) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 4935(line=179, offs=24) -- 4966(line=179, offs=55) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse: tmp48 = (ats_sum_ptr_type)0 ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp (arg0, tmp48) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 5007(line=182, offs=30) -- 5148(line=186, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse_list_vt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse_list_vt: tmp50 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg0) ; tmp49 = ats_castfn_mac(ats_ptr_type, tmp50) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse_list_vt] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 5236(line=192, offs=3) -- 5456(line=198, offs=8) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_16_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; arg0 = tmp52 ; arg1 = tmp53 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp51 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp51 = -1 ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp51 = 0 ; break ; } while (0) ; break ; } while (0) ; return (tmp51) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 5623(line=209, offs=5) -- 5845(line=214, offs=4) */ ATSstaticdec() ats_void_type loop_19 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_loop_19: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (ats_ptrget_mac(ats_ptr_type, arg0) == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp56 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg0), atslab_1) ; arg0 = tmp56 ; arg1 = arg1 ; goto __ats_lab_loop_19 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (ats_ptrget_mac(ats_ptr_type, arg0) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: ats_ptrget_mac(ats_ptr_type, arg0) = arg1 ; break ; } while (0) ; return /* (tmp55) */ ; } /* end of [loop_19] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 5599(line=207, offs=20) -- 5912(line=220, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_append (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_append: /* ats_ptr_type tmp57 ; */ tmp57 = arg0 ; /* tmp58 = */ loop_19 ((&tmp57), arg1) ; tmp54 = tmp57 ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_append] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 6055(line=230, offs=5) -- 6420(line=243, offs=4) */ ATSstaticdec() ats_void_type loop_21 (ats_ref_type arg0, ats_int_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_bool_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_int_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_loop_21: tmp61 = atspre_igt (arg1, 0) ; if (tmp61) { ats_ptrget_mac(ats_ptr_type, arg2) = ats_ptrget_mac(ats_ptr_type, arg0) ; // if (ats_ptrget_mac(ats_ptr_type, arg2) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp62 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg2), atslab_1) ; tmp63 = ats_ptrget_mac(ats_ptr_type, tmp62) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp63 ; tmp64 = atspre_isub (arg1, 1) ; arg0 = arg0 ; arg1 = tmp64 ; arg2 = tmp62 ; goto __ats_lab_loop_21 ; // tail call } else { tmp65 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp65 ; } /* end of [if] */ return /* (tmp60) */ ; } /* end of [loop_21] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 6034(line=228, offs=20) -- 6511(line=249, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_prefix (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp66) ; // ATSlocal_void (tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_prefix: /* ats_ptr_type tmp66 ; */ /* tmp67 = */ loop_21 (arg0, arg1, (&tmp66)) ; tmp59 = tmp66 ; return (tmp59) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_prefix] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 6588(line=255, offs=3) -- 6707(line=257, offs=26) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp71 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp71, atslab_0, tmp69) ; ats_selptrset_mac(anairiats_sum_0, tmp71, atslab_1, arg1) ; arg0 = tmp70 ; arg1 = tmp71 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp68 = arg1 ; break ; } while (0) ; return (tmp68) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 6762(line=261, offs=17) -- 6804(line=261, offs=59) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse: tmp73 = (ats_sum_ptr_type)0 ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp (arg0, tmp73) ; return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 6859(line=267, offs=3) -- 6980(line=269, offs=26) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp76 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp77 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp77, atslab_0, tmp75) ; ats_selptrset_mac(anairiats_sum_0, tmp77, atslab_1, arg1) ; arg0 = tmp76 ; arg1 = tmp77 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp74 = arg1 ; break ; } while (0) ; return (tmp74) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7045(line=273, offs=22) -- 7089(line=273, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list: tmp79 = (ats_sum_ptr_type)0 ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list (arg0, tmp79) ; return (tmp78) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7198(line=282, offs=7) -- 7656(line=294, offs=6) */ ATSstaticdec() ats_void_type aux_28 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_aux_28: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp84 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp85 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp85, atslab_0, tmp83) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp85 ; // if (ats_ptrget_mac(ats_ptr_type, arg1) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp86 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg1), atslab_1) ; tmp87 = ats_ptrget_mac(ats_ptr_type, tmp84) ; arg0 = tmp87 ; arg1 = tmp86 ; goto __ats_lab_aux_28 ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp88 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp88 ; break ; } while (0) ; return /* (tmp82) */ ; } /* end of [aux_28] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7181(line=281, offs=14) -- 7741(line=298, offs=4) */ ATSstaticdec() ats_ptr_type list_vt_copy_01706_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; __ats_lab_list_vt_copy_01706_ats_ptr_type: /* ats_ptr_type tmp89 ; */ /* tmp90 = */ aux_28 (arg0, (&tmp89)) ; tmp81 = tmp89 ; return (tmp81) ; } /* end of [list_vt_copy_01706_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7802(line=301, offs=25) -- 7828(line=301, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_copy__boxed (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_copy__boxed: tmp80 = list_vt_copy_01706_ats_ptr_type (arg0) ; return (tmp80) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_copy__boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7914(line=306, offs=27) -- 8015(line=310, offs=4) */ ATSstaticdec() ats_void_type list_vt_free_01708_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_list_vt_free_01708_ats_ptr_type: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp93 ; goto __ats_lab_list_vt_free_01708_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: break ; } while (0) ; return /* (tmp92) */ ; } /* end of [list_vt_free_01708_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8076(line=313, offs=25) -- 8102(line=313, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed: /* tmp91 = */ list_vt_free_01708_ats_ptr_type (arg0) ; return /* (tmp91) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8171(line=319, offs=7) -- 8400(line=325, offs=38) */ ATSstaticdec() ats_int_type aux_33 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_int_type, tmp99) ; __ats_lab_aux_33: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp97 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp98 = ats_ptrget_mac(ats_ptr_type, tmp97) ; tmp99 = atspre_iadd (arg1, 1) ; arg0 = tmp98 ; arg1 = tmp99 ; goto __ats_lab_aux_33 ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp96 = arg1 ; break ; } while (0) ; return (tmp96) ; } /* end of [aux_33] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8154(line=318, offs=16) -- 8439(line=329, offs=4) */ ATSstaticdec() ats_int_type list_vt_length_01710_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp95) ; __ats_lab_list_vt_length_01710_ats_ptr_type: tmp95 = aux_33 (arg0, 0) ; return (tmp95) ; } /* end of [list_vt_length_01710_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8504(line=332, offs=27) -- 8532(line=332, offs=55) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp94) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed: tmp94 = list_vt_length_01710_ats_ptr_type (arg0) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_length__boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8628(line=340, offs=7) -- 8966(line=352, offs=24) */ ATSstaticdec() ats_void_type aux_35 (ats_ptr_type env0, ats_ptr_type env1, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; // ATSlocal_void (tmp104) ; ATSlocal (ats_bool_type, tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_int_type, tmp107) ; __ats_lab_aux_35: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp105 = atspre_gt_int_int (arg2, 0) ; if (tmp105) { /* tmp104 = */ atspre_fprint_string (arg0, env0) ; } else { /* empty */ } /* end of [if] */ /* tmp106 = */ ((ats_void_type(*)(ats_ref_type, ats_ptr_type))env1) (arg0, tmp102) ; tmp107 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp103 ; arg2 = tmp107 ; goto __ats_lab_aux_35 ; // tail call break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: break ; } while (0) ; return /* (tmp101) */ ; } /* end of [aux_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_35_closure_type ; ats_void_type aux_35_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { aux_35 (((aux_35_closure_type*)cloptr)->closure_env_0, ((aux_35_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_35_closure_init (aux_35_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_35_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_35_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_35_closure_type *p_clo = ATS_MALLOC(sizeof(aux_35_closure_type)) ; aux_35_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 8584(line=337, offs=19) -- 9031(line=356, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp100) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst: /* tmp100 = */ aux_35 (arg2, arg3, arg0, arg1, 0) ; return /* (tmp100) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_list_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_list_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_util_dats.c0000664000175000017500000006303112223166160022550 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_c2lau_loc ; ats_ptr_type atslab_c2lau_pat ; ats_ptr_type atslab_c2lau_gua ; ats_int_type atslab_c2lau_seq ; ats_int_type atslab_c2lau_neg ; ats_ptr_type atslab_c2lau_exp ; } anairiats_rec_8 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_bool_type loop_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type d2exp_seq_is_raised_6 (ats_ptr_type arg0) ; static ats_bool_type c2laulst_is_raised_8 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 1897(line=56, offs=4) -- 1982(line=57, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 2016(line=60, offs=4) -- 2081(line=61, offs=46) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_dynexp2_util)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 2155(line=67, offs=15) -- 2454(line=77, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (arg1, -1) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (arg1) ; tmp6 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize (arg0, tmp7) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (arg1, tmp6) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg1) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize (arg0, tmp9) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp8) ; return /* (tmp3) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 2511(line=81, offs=3) -- 2707(line=87, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_readize (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; // ATSlocal_void (tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_readize: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp13 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_readize (arg0, tmp11) ; arg0 = arg0 ; arg1 = tmp12 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_readize ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp10) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_readize] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 2790(line=93, offs=3) -- 3007(line=103, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_varlamcst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_varlamcst: tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp15)->tag != 56) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp15)->tag != 30) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp15)->tag != 10) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp15)->tag != 28) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp15)->tag != 22) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp15)->tag != 51) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp15)->tag != 54) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp14 = ats_true_bool ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp14 = ats_false_bool ; break ; } while (0) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_varlamcst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 3092(line=108, offs=22) -- 3721(line=127, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr: tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp17)->tag != 56) { goto __ats_lab_13_0 ; } __ats_lab_10_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_2, tmp17, atslab_0) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (tmp18) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (tmp19 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_3, tmp19, atslab_0) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp20) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type, tmp21) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (tmp19 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp16 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp17)->tag != 12) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_2, tmp17, atslab_0) ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (tmp22) ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp23) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type, tmp24) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp26 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_loc) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp26) ; /* tmp27 = */ prerr_interror_1 () ; /* tmp28 = */ atspre_prerr_string (ATSstrcst(": d2exp_var_cst_is_ptr: d2e = ")) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (arg0) ; /* tmp30 = */ atspre_prerr_newline () ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 3837(line=133, offs=7) -- 3990(line=137, offs=41) */ ATSstaticdec() ats_bool_type loop_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_loop_7: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp34 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; arg0 = tmp33 ; arg1 = tmp34 ; goto __ats_lab_loop_7 ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp32 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised (arg0) ; break ; } while (0) ; return (tmp32) ; } /* end of [loop_7] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 3780(line=131, offs=4) -- 4103(line=143, offs=4) */ ATSstaticdec() ats_bool_type d2exp_seq_is_raised_6 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp31) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_d2exp_seq_is_raised_6: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp31 = loop_7 (tmp35, tmp36) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp31 = ats_false_bool ; break ; } while (0) ; return (tmp31) ; } /* end of [d2exp_seq_is_raised_6] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 4141(line=145, offs=5) -- 4391(line=152, offs=4) */ ATSstaticdec() ats_bool_type c2laulst_is_raised_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_bool_type, tmp40) ; __ats_lab_c2laulst_is_raised_8: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised (tmp38) ; if (tmp40) { arg0 = tmp39 ; goto __ats_lab_c2laulst_is_raised_8 ; // tail call } else { tmp37 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp37 = ats_true_bool ; break ; } while (0) ; return (tmp37) ; } /* end of [c2laulst_is_raised_8] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 4450(line=155, offs=17) -- 5105(line=172, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised: tmp42 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp42)->tag != 2) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_4, tmp42, atslab_0) ; arg0 = tmp43 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp42)->tag != 1) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_4, tmp42, atslab_0) ; arg0 = tmp44 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp42)->tag != 9) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_5, tmp42, atslab_4) ; tmp41 = c2laulst_is_raised_8 (tmp45) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp42)->tag != 27) { goto __ats_lab_27_0 ; } __ats_lab_24_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_6, tmp42, atslab_2) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_6, tmp42, atslab_3) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp47 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_3, tmp47, atslab_0) ; tmp49 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised (tmp46) ; if (tmp49) { arg0 = tmp48 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised ; // tail call } else { tmp41 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp47 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp41 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp42)->tag != 36) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_4, tmp42, atslab_1) ; arg0 = tmp50 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised ; // tail call break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp42)->tag != 38) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp41 = ats_true_bool ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp42)->tag != 43) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp41 = ats_true_bool ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp42)->tag != 47) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_2, tmp42, atslab_0) ; tmp41 = d2exp_seq_is_raised_6 (tmp51) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp42)->tag != 58) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_4, tmp42, atslab_0) ; arg0 = tmp52 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp41 = ats_false_bool ; break ; } while (0) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_util.dats: 5160(line=174, offs=27) -- 5245(line=176, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_int_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised: tmp55 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_c2lau_neg) ; tmp54 = atspre_gt_int_int (tmp55, 0) ; if (tmp54) { tmp53 = ats_true_bool ; } else { tmp56 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_c2lau_exp) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised (tmp56) ; } /* end of [if] */ return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_is_raised] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_util_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_util_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_grammar_yats.h0000664000175000017500000001554512223166160021611 0ustar hwxihwxi/* A Bison parser, made by GNU Bison 2.5. */ /* Bison interface for Yacc-like parsers in C Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work under terms of your choice, so long as that work isn't itself a parser generator using the skeleton or a modified version thereof as a parser skeleton. Alternatively, if you modify or redistribute the parser skeleton itself, you may (at your option) remove this special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE /* Put the tokens into the symbol table, so that GDB and other debuggers know about them. */ enum yytokentype { YYBEG_i0de = 258, YYBEG_s0rtid = 259, YYBEG_si0de = 260, YYBEG_di0de = 261, YYBEG_s0exp = 262, YYBEG_d0exp = 263, YYBEG_d0ecseq_sta = 264, YYBEG_d0ecseq_dyn = 265, TOKEN_eof = 266, LITERAL_char = 267, LITERAL_extcode = 268, LITERAL_float = 269, LITERAL_floatsp = 270, LITERAL_int = 271, LITERAL_intsp = 272, LITERAL_string = 273, IDENTIFIER_alp = 274, IDENTIFIER_sym = 275, IDENTIFIER_arr = 276, IDENTIFIER_tmp = 277, IDENTIFIER_ext = 278, IDENTIFIER_dlr = 279, IDENTIFIER_srp = 280, ABSPROP = 281, ABSTYPE = 282, ABST0YPE = 283, ABSVIEW = 284, ABSVIEWTYPE = 285, ABSVIEWT0YPE = 286, AND = 287, AS = 288, ASSUME = 289, ATLAM = 290, ATLLAM = 291, ATFIX = 292, BEGIN = 293, BREAK = 294, CASE = 295, CASEMINUS = 296, CASEPLUS = 297, CASTFN = 298, CLASSDEC = 299, CONTINUE = 300, DATASORT = 301, DATAPARASORT = 302, DATAPROP = 303, DATATYPE = 304, DATAVIEW = 305, DATAVIEWTYPE = 306, DO = 307, DYN = 308, DYNLOAD = 309, ELSE = 310, END = 311, EXCEPTION = 312, EXTERN = 313, FIX = 314, FN = 315, FNSTAR = 316, FOR = 317, FORSTAR = 318, FUN = 319, IF = 320, IMPLEMENT = 321, IN = 322, INFIX = 323, INFIXL = 324, INFIXR = 325, LAM = 326, LET = 327, LLAM = 328, LOCAL = 329, MACDEF = 330, MACRODEF = 331, NONFIX = 332, OF = 333, OP = 334, OVERLOAD = 335, PAR = 336, POSTFIX = 337, PRAXI = 338, PREFIX = 339, PRFN = 340, PRFUN = 341, PROPDEF = 342, PROPMINUS = 343, PROPPLUS = 344, PRVAL = 345, REC = 346, R0EAD = 347, SCASE = 348, SIF = 349, SORTDEF = 350, STACST = 351, STADEF = 352, STAIF = 353, STALOAD = 354, STAVAR = 355, SYMELIM = 356, SYMINTR = 357, THEN = 358, TRY = 359, TYPEDEF = 360, TYPEMINUS = 361, TYPEPLUS = 362, T0YPE = 363, T0YPEMINUS = 364, T0YPEPLUS = 365, VAL = 366, VALMINUS = 367, VALPLUS = 368, VAR = 369, VIEWDEF = 370, VIEWMINUS = 371, VIEWPLUS = 372, VIEWTYPEDEF = 373, VIEWTYPEMINUS = 374, VIEWTYPEPLUS = 375, VIEWT0YPE = 376, VIEWT0YPEMINUS = 377, VIEWT0YPEPLUS = 378, WHEN = 379, WHERE = 380, WHILE = 381, WHILESTAR = 382, WITH = 383, WITHPROP = 384, WITHTYPE = 385, WITHVIEW = 386, WITHVIEWTYPE = 387, AMPERSAND = 388, BACKQUOTE = 389, BACKSLASH = 390, BANG = 391, BAR = 392, COMMA = 393, COLON = 394, SEMICOLON = 395, DOT = 396, EQ = 397, LT = 398, GT = 399, DOLLAR = 400, HASH = 401, TILDE = 402, DOTDOT = 403, DOTDOTDOT = 404, EQLT = 405, EQGT = 406, EQLTGT = 407, EQGTGT = 408, EQSLASHEQGT = 409, EQSLASHEQGTGT = 410, GTLT = 411, DOTLT = 412, GTDOT = 413, DOTLTGTDOT = 414, MINUSLT = 415, MINUSGT = 416, MINUSLTGT = 417, COLONLT = 418, COLONLTGT = 419, BACKQUOTELPAREN = 420, COMMALPAREN = 421, PERCENTLPAREN = 422, DLRARRPSZ = 423, DLRLST_T = 424, DLRLST_VT = 425, DLRREC_T = 426, DLRREC_VT = 427, DLRTUP_T = 428, DLRTUP_VT = 429, DLRDELAY = 430, DLRLDELAY = 431, DLRDYNLOAD = 432, DLREFFMASK_ALL = 433, DLREFFMASK_EXN = 434, DLREFFMASK_NTM = 435, DLREFFMASK_REF = 436, DLRDECRYPT = 437, DLRENCRYPT = 438, DLREXTERN = 439, DLREXTVAL = 440, DLREXTYPE = 441, DLREXTYPE_STRUCT = 442, DLRFOLD = 443, DLRUNFOLD = 444, DLRRAISE = 445, DLRSHOWTYPE = 446, SRPFILENAME = 447, SRPLOCATION = 448, SRPCHARCOUNT = 449, SRPLINECOUNT = 450, SRPASSERT = 451, SRPDEFINE = 452, SRPELSE = 453, SRPELIF = 454, SRPELIFDEF = 455, SRPELIFNDEF = 456, SRPENDIF = 457, SRPERROR = 458, SRPIF = 459, SRPIFDEF = 460, SRPIFNDEF = 461, SRPINCLUDE = 462, SRPPRINT = 463, SRPTHEN = 464, SRPUNDEF = 465, FOLDAT = 466, FREEAT = 467, VIEWAT = 468, LPAREN = 469, RPAREN = 470, LBRACKET = 471, RBRACKET = 472, LBRACE = 473, RBRACE = 474, ATLPAREN = 475, ATLBRACKET = 476, ATLBRACE = 477, QUOTELPAREN = 478, QUOTELBRACKET = 479, QUOTELBRACE = 480, HASHLPAREN = 481, HASHLBRACKET = 482, HASHLBRACE = 483, PATAS = 484, PATFREE = 485, SEXPLAM = 486, DEXPLAM = 487, DEXPFIX = 488, CLAUS = 489, DEXPCASE = 490, DEXPIF = 491, DEXPRAISE = 492, DEXPSHOWTYPE = 493, DEXPTRY = 494, DEXPFOR = 495, DEXPWHILE = 496, BARCLAUSSEQNONE = 497, TMPSEXP = 498, TMPSARG = 499, SARRIND = 500, SEXPDARGSEQEMPTY = 501 }; #endif #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif extern YYSTYPE yylval; ats-lang-anairiats-0.2.11/bootstrap1/ats_constraint_dats.c0000664000175000017500000111106512223166160022310 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ #include "ats_solver_fm.cats" /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_h3ypo_loc ; ats_ptr_type atslab_h3ypo_node ; } anairiats_rec_9 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_10 ; typedef struct { ats_int_type atslab_0 ; atsopt_count_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_11 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_c3str_loc ; ats_ptr_type atslab_c3str_kind ; ats_ptr_type atslab_c3str_node ; } anairiats_rec_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDpattern_match_exhaustiveness_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDloop_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPObind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOeqeq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRitmlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_ref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMdisj_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMhypo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsVar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICvec_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICveclst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEintinf_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEineg_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEiadd_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEisub_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEimul_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEpdiff_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEvar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbadd_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbmul_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbneg_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEiexp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEexp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEvar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEnull_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEpadd_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTmark_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_int_of_char) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_neg_int) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_add_uint_uint) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, atspre_lte_uint_uint) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, atspre_gt_uint_uint) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, atspre_gte_uint_uint) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, atsopt_lt_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_gte_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_eq_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_neq_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atsopt_neg_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_add_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_sub_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_mul_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_int) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_char_char_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_char_char_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_addr_int_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_int_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_addr_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_cls_cls_bool) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_add_bool_bool_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_mul_bool_bool_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_int_int_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_int_int_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_c3str) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_i0nt_of_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_i0nt_of_intinf) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_neg_i0nt) (ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_add_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atsopt_solver_fm_mul_i0nt_i0nt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atsopt_solver_fm_intvec_ptr_make) (ats_int_type) ; ATSextern_fun(ats_ptr_type, atsopt_solver_fm_intvecptr_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_solve) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3aexp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_null) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_badd) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bmul) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgte) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plte) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_imul) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp) (ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp) (ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_h3ypo) (ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp) (ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_make_s2cst_s2explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_make_s2cst_s2explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_make_s2cst_s2explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_intvec_update_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexplst_s2exp_solve_fm) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_prop) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type, ats_ref_type, ats_ref_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_null) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_0) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_neg_1) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_bool_type s3iexp_is_const_28 (ats_ptr_type arg0) ; static ats_void_type s2cfdeflst_free_40 (ats_ptr_type arg0) ; static ats_ptr_type aux_42 (ats_ptr_type arg0) ; static ats_void_type s2cfdeflst_pop_41 (ats_ref_type arg0) ; static ats_void_type s2cfdeflst_push_43 (ats_ref_type arg0) ; static ats_ptr_type s2cfdeflst_find_44 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type s2cfdeflst_add_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type s2cfdeflst_add_none_46 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type s2cfdeflst_replace_47 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type s2cfdeflst_replace_none_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type errmsg_50 (ats_ptr_type arg0) ; static ats_ptr_type errmsg_52 (ats_ptr_type arg0) ; static ats_ptr_type errmsg_54 (ats_ptr_type arg0) ; static ats_ptr_type aux_equal_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_ptr_type aux_bind_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_bool_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2cstlst_add_57 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2exp_synlt_60 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2exp_synlte_61 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2explst_synlte_62 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxlt_64 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type auxlte_65 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type auxlst_66 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2exp_metlt_reduce_63 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type __ats_fun_71 (atsopt_count_type arg0, atsopt_count_type arg1) ; static ats_ptr_type s2cst_index_map_make_70 () ; static ats_int_type __ats_fun_73 (atsopt_count_type arg0, atsopt_count_type arg1) ; static ats_ptr_type s2var_index_map_make_72 () ; static ats_ptr_type bst_search_0510_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_04000_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_int_type s2cst_index_find_74 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_int_type s2var_index_find_77 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_int_type bst_size_0482_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_0487_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_0521_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_03998_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2) ; static ats_void_type s2cst_index_insert_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type s2var_index_insert_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_88 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_89 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_90 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_91 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_92 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ref_type arg5, ats_ref_type arg6) ; static ats_void_type bst_free_0478_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) ; static ats_void_type map_free_03996_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) ; static ats_void_type aux_96 (ats_ptr_type arg0) ; static ats_void_type pattern_match_exhaustiveness_msg_95 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type prerr_c3str_if_98 (ats_uint_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp17) ; ATSstatic (ats_ptr_type, statmp18) ; ATSstatic (ats_ptr_type, statmp100) ; ATSstatic (ats_ptr_type, statmp101) ; ATSstatic (ats_ptr_type, statmp102) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 2547(line=82, offs=4) -- 2606(line=82, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_constraint)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 2610(line=83, offs=4) -- 2722(line=85, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; __ats_lab_prerr_loc_interror_1: /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_constraint)")) ; return /* (tmp1) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 2834(line=91, offs=22) -- 2854(line=91, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_cst: tmp4 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp4)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp4, atslab_0, arg0) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 2877(line=92, offs=22) -- 2897(line=92, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var: tmp5 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp5)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp5, atslab_0, arg0) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 2922(line=95, offs=13) -- 3122(line=101, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp8 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp9 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd (tmp8, arg1) ; arg0 = tmp7 ; arg1 = tmp9 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp6 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp6)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp6, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp6, atslab_1, arg1) ; break ; } while (0) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3170(line=104, offs=13) -- 3382(line=110, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (tmp12, arg1) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd (tmp11, tmp13) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp14 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg (arg1) ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp10)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp10, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp10, atslab_1, tmp14) ; break ; } while (0) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3431(line=112, offs=24) -- 3468(line=112, offs=61) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psucc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psucc: tmp15 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd (arg0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psucc] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3492(line=113, offs=24) -- 3529(line=113, offs=61) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_ppred (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_ppred: tmp16 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub (arg0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_ppred] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3656(line=120, offs=22) -- 3676(line=120, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_cst: tmp19 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp19)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp19, atslab_0, arg0) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3699(line=121, offs=22) -- 3719(line=121, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var: tmp20 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp20)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp20, atslab_0, arg0) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 3744(line=124, offs=13) -- 4049(line=130, offs=24) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_bool_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_int_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp23 = atspre_neg_bool (tmp22) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp21)->tag = 3 ; ats_selptrset_mac(anairiats_sum_2, tmp21, atslab_0, tmp23) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp26 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp26)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp26, atslab_0, tmp24) ; tmp27 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp27)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp27, atslab_0, tmp25) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp21)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_0, tmp26) ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_1, tmp27) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp29 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp30 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp30)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp30, atslab_0, tmp28) ; tmp31 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp31)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp31, atslab_0, tmp29) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp21)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_0, tmp30) ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_1, tmp31) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp21 = tmp32 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp34 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp35 = atspre_neg_int (tmp33) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp21)->tag = 7 ; ats_selptrset_mac(anairiats_sum_3, tmp21, atslab_0, tmp35) ; ats_selptrset_mac(anairiats_sum_3, tmp21, atslab_1, tmp34) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp21 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp21)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp21, atslab_0, arg0) ; break ; } while (0) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 4096(line=134, offs=12) -- 4497(line=144, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_bool_type, tmp37) ; ATSlocal (ats_bool_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; if (tmp37) { tmp36 = arg1 ; } else { tmp36 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg1) ; } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; if (tmp38) { tmp36 = arg0 ; } else { tmp36 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg0) ; } /* end of [if] */ break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp39 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg0) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg1) ; tmp41 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp41)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp41, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp41, atslab_1, arg1) ; tmp42 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp42)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp42, atslab_0, tmp39) ; ats_selptrset_mac(anairiats_sum_1, tmp42, atslab_1, tmp40) ; tmp36 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp36)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp36, atslab_0, tmp41) ; ats_selptrset_mac(anairiats_sum_1, tmp36, atslab_1, tmp42) ; break ; } while (0) ; break ; } while (0) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 4544(line=147, offs=13) -- 4945(line=157, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_bool_type, tmp44) ; ATSlocal (ats_bool_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneq: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; if (tmp44) { tmp43 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg1) ; } else { tmp43 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; if (tmp45) { tmp43 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg0) ; } else { tmp43 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp46 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg0) ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (arg1) ; tmp48 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp48)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp48, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp48, atslab_1, tmp47) ; tmp49 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp49)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp49, atslab_0, tmp46) ; ats_selptrset_mac(anairiats_sum_1, tmp49, atslab_1, arg1) ; tmp43 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp43)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp43, atslab_0, tmp48) ; ats_selptrset_mac(anairiats_sum_1, tmp43, atslab_1, tmp49) ; break ; } while (0) ; break ; } while (0) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 5014(line=162, offs=13) -- 5252(line=169, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_badd (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_bool_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_badd: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; if (tmp51) { tmp50 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp50 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; if (tmp52) { tmp50 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp50 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp50 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp50)->tag = 4 ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp50, atslab_1, arg1) ; break ; } while (0) ; break ; } while (0) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_badd] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 5300(line=172, offs=13) -- 5540(line=179, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bmul (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bmul: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; if (tmp54) { tmp53 = arg1 ; } else { tmp53 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; if (tmp55) { tmp53 = arg0 ; } else { tmp53 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp53 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp53)->tag = 5 ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp53, atslab_1, arg1) ; break ; } while (0) ; break ; } while (0) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bmul] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 5609(line=184, offs=13) -- 6644(line=208, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_int_type, tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_bool_type, tmp59) ; ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_bool_type, tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_bool_type, tmp67) ; ATSlocal (ats_bool_type, tmp68) ; ATSlocal (ats_bool_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_32_0 ; } __ats_lab_26_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (arg0 != 2) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp58 = atspre_gte_int_int (tmp57, 0) ; if (tmp58) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (arg0 != 1) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp59 = atspre_eq_int_int (tmp57, 0) ; if (tmp59) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg0 != -1) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp60 = atspre_neq_int_int (tmp57, 0) ; if (tmp60) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (arg0 != -2) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp61 = atspre_lt_int_int (tmp57, 0) ; if (tmp61) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: /* tmp62 = */ prerr_interror_0 () ; /* tmp63 = */ atspre_prerr_string (ATSstrcst(": s3bexp_iexp: knd = ")) ; /* tmp64 = */ atspre_prerr_int (arg0) ; /* tmp65 = */ atspre_prerr_newline () ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_38_0 ; } __ats_lab_32_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 != 2) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp67 = atsopt_gte_intinf_int (tmp66, 0) ; if (tmp67) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg0 != 1) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp68 = atsopt_eq_intinf_int (tmp66, 0) ; if (tmp68) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg0 != -1) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp69 = atsopt_neq_intinf_int (tmp66, 0) ; if (tmp69) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg0 != -2) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp70 = atsopt_lt_intinf_int (tmp66, 0) ; if (tmp70) { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true ; } else { tmp56 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: /* tmp71 = */ prerr_interror_0 () ; /* tmp72 = */ atspre_prerr_string (ATSstrcst(": s3bexp_iexp: knd = ")) ; /* tmp73 = */ atspre_prerr_int (arg0) ; /* tmp74 = */ atspre_prerr_newline () ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp56 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp56)->tag = 7 ; ats_selptrset_mac(anairiats_sum_3, tmp56, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp56, atslab_1, arg1) ; break ; } while (0) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 6712(line=212, offs=22) -- 6781(line=213, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg1, arg0) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-2, tmp76) ; return (tmp75) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 6828(line=216, offs=23) -- 6897(line=217, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte: tmp78 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg0, arg1) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (2, tmp78) ; return (tmp77) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 6944(line=220, offs=22) -- 7013(line=221, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt: tmp80 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg0, arg1) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-2, tmp80) ; return (tmp79) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7060(line=224, offs=23) -- 7129(line=225, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg1, arg0) ; tmp81 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (2, tmp82) ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7197(line=230, offs=22) -- 7265(line=231, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq: tmp84 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg0, arg1) ; tmp83 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (1, tmp84) ; return (tmp83) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7312(line=234, offs=23) -- 7382(line=235, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq: tmp86 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg0, arg1) ; tmp85 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-1, tmp86) ; return (tmp85) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7450(line=240, offs=22) -- 7520(line=241, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgt: tmp88 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg1, arg0) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-2, tmp88) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgt] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7567(line=244, offs=23) -- 7637(line=245, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgte (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgte: tmp90 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg0, arg1) ; tmp89 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (2, tmp90) ; return (tmp89) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgte] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7684(line=248, offs=22) -- 7754(line=249, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plt: tmp92 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg0, arg1) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-2, tmp92) ; return (tmp91) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plt] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7801(line=252, offs=23) -- 7871(line=253, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plte (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plte: tmp94 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg1, arg0) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (2, tmp94) ; return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plte] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 7918(line=256, offs=22) -- 7987(line=257, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq: tmp96 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg0, arg1) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (1, tmp96) ; return (tmp95) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8034(line=260, offs=23) -- 8105(line=261, offs=55) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pneq: tmp98 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (arg0, arg1) ; tmp97 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_iexp (-1, tmp98) ; return (tmp97) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pneq] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8155(line=266, offs=4) -- 8273(line=268, offs=4) */ ATSstaticdec() ats_bool_type s3iexp_is_const_28 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp99) ; __ats_lab_s3iexp_is_const_28: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp99 = ats_true_bool ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp99 = ats_true_bool ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp99 = ats_false_bool ; break ; } while (0) ; return (tmp99) ; } /* end of [s3iexp_is_const_28] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8446(line=276, offs=22) -- 8465(line=276, offs=41) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_cst: tmp103 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp103)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp103, atslab_0, arg0) ; return (tmp103) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8487(line=277, offs=22) -- 8502(line=277, offs=37) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int: tmp104 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp104)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp104, atslab_0, arg0) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8527(line=278, offs=25) -- 8545(line=278, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_intinf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_intinf: tmp105 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp105)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp105, atslab_0, arg0) ; return (tmp105) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_intinf] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8567(line=279, offs=22) -- 8586(line=279, offs=41) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var: tmp106 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp106)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp106, atslab_0, arg0) ; return (tmp106) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8610(line=282, offs=13) -- 8773(line=288, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_int_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp109 = atspre_neg_int (tmp108) ; tmp107 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp107)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp107, atslab_0, tmp109) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp111 = atsopt_neg_intinf (tmp110) ; tmp107 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp107)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp107, atslab_0, tmp111) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp107 = tmp112 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: tmp107 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp107)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp107, atslab_0, arg0) ; break ; } while (0) ; return (tmp107) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 8821(line=291, offs=13) -- 9243(line=303, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_bool_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_bool_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_bool_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_bool_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_47_0 ; } __ats_lab_46_1: __ats_lab_46_2: tmp114 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp115 = atspre_eq_int_int (tmp114, 0) ; if (!tmp115) { goto __ats_lab_47_1 ; } tmp113 = arg1 ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_48_0 ; } __ats_lab_47_2: tmp116 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp117 = atspre_eq_int_int (tmp116, 0) ; if (!tmp117) { goto __ats_lab_48_0 ; } tmp113 = arg0 ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_49_0 ; } __ats_lab_48_1: __ats_lab_48_2: tmp118 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp119 = atsopt_eq_intinf_int (tmp118, 0) ; if (!tmp119) { goto __ats_lab_49_1 ; } tmp113 = arg1 ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_50_0 ; } __ats_lab_49_2: tmp120 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp121 = atsopt_eq_intinf_int (tmp120, 0) ; if (!tmp121) { goto __ats_lab_50_0 ; } tmp113 = arg0 ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_51_0 ; } __ats_lab_50_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_51_1 ; } __ats_lab_50_2: tmp122 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp123 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp124 = atsopt_add_intinf_intinf (tmp122, tmp123) ; tmp113 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp113)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp113, atslab_0, tmp124) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: __ats_lab_51_2: tmp113 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp113)->tag = 6 ; ats_selptrset_mac(anairiats_sum_1, tmp113, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp113, atslab_1, arg1) ; break ; } while (0) ; return (tmp113) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 9291(line=306, offs=13) -- 9738(line=318, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_int_type, tmp126) ; ATSlocal (ats_bool_type, tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_bool_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_bool_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_bool_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_53_0 ; } __ats_lab_52_1: __ats_lab_52_2: tmp126 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp127 = atspre_eq_int_int (tmp126, 0) ; if (!tmp127) { goto __ats_lab_53_1 ; } tmp125 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg (arg1) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_54_0 ; } __ats_lab_53_2: tmp128 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp129 = atspre_eq_int_int (tmp128, 0) ; if (!tmp129) { goto __ats_lab_54_0 ; } tmp125 = arg0 ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_55_0 ; } __ats_lab_54_1: __ats_lab_54_2: tmp130 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp131 = atsopt_eq_intinf_int (tmp130, 0) ; if (!tmp131) { goto __ats_lab_55_1 ; } tmp125 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg (arg1) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_56_0 ; } __ats_lab_55_2: tmp132 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp133 = atsopt_eq_intinf_int (tmp132, 0) ; if (!tmp133) { goto __ats_lab_56_0 ; } tmp125 = arg0 ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_57_0 ; } __ats_lab_56_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_57_1 ; } __ats_lab_56_2: tmp134 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp135 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp136 = atsopt_sub_intinf_intinf (tmp134, tmp135) ; tmp125 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp125)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp125, atslab_0, tmp136) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: __ats_lab_57_2: tmp125 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp125)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp125, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp125, atslab_1, arg1) ; break ; } while (0) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 9786(line=321, offs=13) -- 10279(line=333, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_imul (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_bool_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_bool_type, tmp141) ; ATSlocal (ats_int_type, tmp142) ; ATSlocal (ats_bool_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_bool_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_bool_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_bool_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_bool_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_bool_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_imul: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: __ats_lab_58_2: tmp138 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp139 = atspre_eq_int_int (tmp138, 0) ; if (!tmp139) { goto __ats_lab_59_2 ; } tmp137 = arg0 ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_60_0 ; } __ats_lab_59_1: __ats_lab_59_2: tmp140 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp141 = atspre_eq_int_int (tmp140, 1) ; if (!tmp141) { goto __ats_lab_60_1 ; } tmp137 = arg1 ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_61_1 ; } __ats_lab_60_2: tmp142 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp143 = atspre_eq_int_int (tmp142, 0) ; if (!tmp143) { goto __ats_lab_61_2 ; } tmp137 = arg1 ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_62_0 ; } __ats_lab_61_2: tmp144 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp145 = atspre_eq_int_int (tmp144, 1) ; if (!tmp145) { goto __ats_lab_62_0 ; } tmp137 = arg0 ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_63_0 ; } __ats_lab_62_1: __ats_lab_62_2: tmp146 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp147 = atsopt_eq_intinf_int (tmp146, 0) ; if (!tmp147) { goto __ats_lab_63_2 ; } tmp137 = arg0 ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_64_0 ; } __ats_lab_63_1: __ats_lab_63_2: tmp148 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp149 = atsopt_eq_intinf_int (tmp148, 1) ; if (!tmp149) { goto __ats_lab_64_1 ; } tmp137 = arg1 ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_65_1 ; } __ats_lab_64_2: tmp150 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp151 = atsopt_eq_intinf_int (tmp150, 0) ; if (!tmp151) { goto __ats_lab_65_2 ; } tmp137 = arg1 ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: __ats_lab_65_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_66_0 ; } __ats_lab_65_2: tmp152 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp153 = atsopt_eq_intinf_int (tmp152, 1) ; if (!tmp153) { goto __ats_lab_66_0 ; } tmp137 = arg0 ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_67_0 ; } __ats_lab_66_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_67_1 ; } __ats_lab_66_2: tmp154 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp155 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp156 = atsopt_mul_intinf_intinf (tmp154, tmp155) ; tmp137 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp137)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp137, atslab_0, tmp156) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: __ats_lab_67_1: __ats_lab_67_2: tmp137 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp137)->tag = 8 ; ats_selptrset_mac(anairiats_sum_1, tmp137, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp137, atslab_1, arg1) ; break ; } while (0) ; return (tmp137) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_imul] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10328(line=335, offs=24) -- 10369(line=335, offs=65) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff: tmp157 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp157)->tag = 9 ; ats_selptrset_mac(anairiats_sum_1, tmp157, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp157, atslab_1, arg1) ; return (tmp157) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10394(line=337, offs=24) -- 10447(line=337, offs=77) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isucc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isucc: tmp158 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd (arg0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; return (tmp158) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isucc] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10471(line=338, offs=24) -- 10524(line=338, offs=77) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ipred (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ipred: tmp159 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (arg0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1) ; return (tmp159) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ipred] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10551(line=342, offs=5) -- 10887(line=352, offs=4) */ ATSstaticdec() ats_void_type s2cfdeflst_free_40 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_s2cfdeflst_free_40: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_71_0 ; } __ats_lab_68_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp162 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; ATS_FREE(arg0) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp161 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: ATS_FREE(tmp161) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: // if (tmp161 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_70_1: break ; } while (0) ; arg0 = tmp162 ; goto __ats_lab_s2cfdeflst_free_40 ; // tail call break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp164 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; ATS_FREE(arg0) ; arg0 = tmp164 ; goto __ats_lab_s2cfdeflst_free_40 ; // tail call break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: break ; } while (0) ; return /* (tmp160) */ ; } /* end of [s2cfdeflst_free_40] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10999(line=358, offs=7) -- 11326(line=365, offs=44) */ ATSstaticdec() ats_ptr_type aux_42 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_aux_42: do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_76_0 ; } __ats_lab_73_1: tmp167 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp168 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; ATS_FREE(arg0) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (tmp167 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: ATS_FREE(tmp167) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (tmp167 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: break ; } while (0) ; arg0 = tmp168 ; goto __ats_lab_aux_42 ; // tail call break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp166 = tmp170 ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: tmp166 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTnil_2) ; break ; } while (0) ; return (tmp166) ; } /* end of [aux_42] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 10941(line=356, offs=4) -- 11374(line=369, offs=4) */ ATSstaticdec() ats_void_type s2cfdeflst_pop_41 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp171) ; __ats_lab_s2cfdeflst_pop_41: tmp171 = aux_42 (ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp171 ; return /* (tmp165) */ ; } /* end of [s2cfdeflst_pop_41] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 11409(line=371, offs=4) -- 11497(line=373, offs=4) */ ATSstaticdec() ats_void_type s2cfdeflst_push_43 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; __ats_lab_s2cfdeflst_push_43: tmp173 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp173)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp173, atslab_0, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp173 ; return /* (tmp172) */ ; } /* end of [s2cfdeflst_push_43] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 11531(line=375, offs=5) -- 12283(line=406, offs=4) */ ATSstaticdec() ats_ptr_type s2cfdeflst_find_44 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_bool_type, tmp179) ; ATSlocal (ats_bool_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; __ats_lab_s2cfdeflst_find_44: do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)ats_ptrget_mac(ats_ptr_type, arg0))->tag != 0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg0), atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg0), atslab_1) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg0), atslab_2) ; tmp178 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg0), atslab_4) ; tmp180 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (arg1, tmp175) ; if (tmp180) { tmp179 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (arg2, tmp176) ; } else { tmp179 = ats_false_bool ; } /* end of [if] */ if (tmp179) { tmp174 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp174, atslab_0, tmp177) ; } else { arg0 = tmp178 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_s2cfdeflst_find_44 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)ats_ptrget_mac(ats_ptr_type, arg0))->tag != 1) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp181 = &ats_caselptrlab_mac(anairiats_sum_0, ats_ptrget_mac(ats_ptr_type, arg0), atslab_0) ; arg0 = tmp181 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_s2cfdeflst_find_44 ; // tail call break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (((ats_sum_ptr_type)ats_ptrget_mac(ats_ptr_type, arg0))->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: tmp174 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp174) ; } /* end of [s2cfdeflst_find_44] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 12388(line=412, offs=4) -- 13028(line=429, offs=4) */ ATSstaticdec() ats_void_type s2cfdeflst_add_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_s2cfdeflst_add_45: tmp183 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (arg0) ; tmp184 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (arg2) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (arg1, tmp184) ; tmp186 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp183, tmp185) ; tmp187 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp186, arg3, arg4) ; tmp188 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp188)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp188, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_5, tmp188, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp188, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp188, atslab_3, tmp187) ; ats_selptrset_mac(anairiats_sum_5, tmp188, atslab_4, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp188 ; return /* (tmp182) */ ; } /* end of [s2cfdeflst_add_45] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 13112(line=434, offs=4) -- 13538(line=446, offs=4) */ ATSstaticdec() ats_void_type s2cfdeflst_add_none_46 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; __ats_lab_s2cfdeflst_add_none_46: tmp191 = (ats_sum_ptr_type)0 ; tmp190 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp190)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp190, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_5, tmp190, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp190, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp190, atslab_3, tmp191) ; ats_selptrset_mac(anairiats_sum_5, tmp190, atslab_4, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp190 ; return /* (tmp189) */ ; } /* end of [s2cfdeflst_add_none_46] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 13647(line=452, offs=4) -- 14002(line=464, offs=24) */ ATSstaticdec() ats_ptr_type s2cfdeflst_replace_47 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_s2cfdeflst_replace_47: tmp193 = s2cfdeflst_find_44 (arg4, arg1, arg2) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (tmp193 != (ats_sum_ptr_type)0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp194 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (arg0) ; /* tmp195 = */ s2cfdeflst_add_45 (arg1, arg2, tmp194, arg3, arg4) ; tmp192 = tmp194 ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (tmp193 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: tmp196 = ats_caselptrlab_mac(anairiats_sum_6, tmp193, atslab_0) ; ATS_FREE(tmp193) ; tmp192 = tmp196 ; break ; } while (0) ; return (tmp192) ; } /* end of [s2cfdeflst_replace_47] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 14110(line=470, offs=4) -- 14475(line=482, offs=24) */ ATSstaticdec() ats_ptr_type s2cfdeflst_replace_none_48 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; // ATSlocal_void (tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_s2cfdeflst_replace_none_48: tmp198 = s2cfdeflst_find_44 (arg4, arg1, arg2) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (tmp198 != (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp199 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (arg0) ; /* tmp200 = */ s2cfdeflst_add_none_46 (arg1, arg2, tmp199, arg3, arg4) ; tmp197 = tmp199 ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (tmp198 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: tmp201 = ats_caselptrlab_mac(anairiats_sum_6, tmp198, atslab_0) ; ATS_FREE(tmp198) ; tmp197 = tmp201 ; break ; } while (0) ; return (tmp197) ; } /* end of [s2cfdeflst_replace_none_48] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 14797(line=496, offs=6) -- 14981(line=500, offs=6) */ ATSstaticdec() ats_ptr_type errmsg_50 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; __ats_lab_errmsg_50: /* tmp204 = */ prerr_interror_0 () ; /* tmp205 = */ atspre_prerr_string (ATSstrcst(": s3aexp_make_s2cst_s2explst: s2c = ")) ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg0) ; /* tmp207 = */ atspre_prerr_newline () ; /* tmp203 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp203) ; } /* end of [errmsg_50] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 14763(line=495, offs=3) -- 16605(line=545, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_make_s2cst_s2explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_bool_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_bool_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_make_s2cst_s2explst: do { /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp208 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_addr_int_addr, arg0) ; if (!tmp208) { goto __ats_lab_92_1 ; } do { /* branch: __ats_lab_86 */ __ats_lab_86_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } tmp209 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp209 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } tmp210 = ats_caselptrlab_mac(anairiats_sum_7, tmp209, atslab_1) ; if (tmp210 != (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_86_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_7, tmp209, atslab_0) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp211, arg2, arg3) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp213 == (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_87_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_6, tmp213, atslab_0) ; ATS_FREE(tmp213) ; tmp215 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp212, arg2, arg3) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (tmp215 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp216 = ats_caselptrlab_mac(anairiats_sum_6, tmp215, atslab_0) ; ATS_FREE(tmp215) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_padd (tmp214, tmp216) ; tmp202 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp202, atslab_0, tmp217) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (tmp215 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp202 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (tmp213 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp202 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp202 = errmsg_50 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: __ats_lab_92_1: tmp218 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_int_addr, arg0) ; if (!tmp218) { goto __ats_lab_99_1 ; } do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } tmp219 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp219 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } tmp220 = ats_caselptrlab_mac(anairiats_sum_7, tmp219, atslab_1) ; if (tmp220 != (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_93_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp222 = ats_caselptrlab_mac(anairiats_sum_7, tmp219, atslab_0) ; tmp223 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp221, arg2, arg3) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (tmp223 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_94_1: tmp224 = ats_caselptrlab_mac(anairiats_sum_6, tmp223, atslab_0) ; ATS_FREE(tmp223) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp222, arg2, arg3) ; do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (tmp225 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_6, tmp225, atslab_0) ; ATS_FREE(tmp225) ; tmp227 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_psub (tmp224, tmp226) ; tmp202 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp202, atslab_0, tmp227) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (tmp225 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: tmp202 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (tmp223 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp202 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: __ats_lab_98_1: tmp202 = errmsg_50 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: tmp228 = s2cfdeflst_replace_none_48 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr, arg0, arg1, arg2, arg3) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var (tmp228) ; tmp202 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp202, atslab_0, tmp229) ; break ; } while (0) ; return (tmp202) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_make_s2cst_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 16955(line=561, offs=6) -- 17139(line=565, offs=6) */ ATSstaticdec() ats_ptr_type errmsg_52 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; __ats_lab_errmsg_52: /* tmp232 = */ prerr_interror_0 () ; /* tmp233 = */ atspre_prerr_string (ATSstrcst(": s3bexp_make_s2cst_s2explst: s2c = ")) ; /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg0) ; /* tmp235 = */ atspre_prerr_newline () ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp231) ; } /* end of [errmsg_52] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 16921(line=560, offs=3) -- 31042(line=920, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_make_s2cst_s2explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_bool_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_bool_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_bool_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_bool_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_bool_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_bool_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_bool_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_bool_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_bool_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_bool_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_bool_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_bool_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_bool_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_bool_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_bool_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_bool_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_bool_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_bool_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_bool_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_bool_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_bool_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_bool_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_bool_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_int_type, tmp467) ; ATSlocal (ats_bool_type, tmp468) ; ATSlocal (ats_bool_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_make_s2cst_s2explst: do { /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: tmp236 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool, arg0) ; if (!tmp236) { goto __ats_lab_105_1 ; } do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_104_0 ; } tmp237 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp237 != (ats_sum_ptr_type)0) { goto __ats_lab_104_0 ; } __ats_lab_101_1: tmp238 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp239 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp238, arg2, arg3) ; do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (tmp239 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp240 = ats_caselptrlab_mac(anairiats_sum_6, tmp239, atslab_0) ; ATS_FREE(tmp239) ; tmp241 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneg (tmp240) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp241) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (tmp239 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: __ats_lab_104_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: __ats_lab_105_1: tmp242 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool, arg0) ; if (!tmp242) { goto __ats_lab_112_1 ; } do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } tmp243 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp243 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } tmp244 = ats_caselptrlab_mac(anairiats_sum_7, tmp243, atslab_1) ; if (tmp244 != (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_106_1: tmp245 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp246 = ats_caselptrlab_mac(anairiats_sum_7, tmp243, atslab_0) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp245, arg2, arg3) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp247 == (ats_sum_ptr_type)0) { goto __ats_lab_110_0 ; } __ats_lab_107_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_6, tmp247, atslab_0) ; ATS_FREE(tmp247) ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp246, arg2, arg3) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp249 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp250 = ats_caselptrlab_mac(anairiats_sum_6, tmp249, atslab_0) ; ATS_FREE(tmp249) ; tmp251 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_badd (tmp248, tmp250) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp251) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (tmp249 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: // if (tmp247 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_110_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: __ats_lab_111_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp252 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool, arg0) ; if (!tmp252) { goto __ats_lab_119_1 ; } do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } tmp253 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp253 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } tmp254 = ats_caselptrlab_mac(anairiats_sum_7, tmp253, atslab_1) ; if (tmp254 != (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_113_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_7, tmp253, atslab_0) ; tmp257 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp255, arg2, arg3) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp257 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_114_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_6, tmp257, atslab_0) ; ATS_FREE(tmp257) ; tmp259 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp256, arg2, arg3) ; do { /* branch: __ats_lab_115 */ __ats_lab_115_0: if (tmp259 == (ats_sum_ptr_type)0) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp260 = ats_caselptrlab_mac(anairiats_sum_6, tmp259, atslab_0) ; ATS_FREE(tmp259) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bmul (tmp258, tmp260) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp261) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (tmp259 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (tmp257 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: __ats_lab_118_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: __ats_lab_119_1: tmp262 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_bool_bool_bool, arg0) ; if (!tmp262) { goto __ats_lab_126_1 ; } do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_125_0 ; } tmp263 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp263 == (ats_sum_ptr_type)0) { goto __ats_lab_125_0 ; } tmp264 = ats_caselptrlab_mac(anairiats_sum_7, tmp263, atslab_1) ; if (tmp264 != (ats_sum_ptr_type)0) { goto __ats_lab_125_0 ; } __ats_lab_120_1: tmp265 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_7, tmp263, atslab_0) ; tmp267 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp265, arg2, arg3) ; do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (tmp267 == (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_121_1: tmp268 = ats_caselptrlab_mac(anairiats_sum_6, tmp267, atslab_0) ; ATS_FREE(tmp267) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp266, arg2, arg3) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (tmp269 == (ats_sum_ptr_type)0) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp270 = ats_caselptrlab_mac(anairiats_sum_6, tmp269, atslab_0) ; ATS_FREE(tmp269) ; tmp271 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq (tmp268, tmp270) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp271) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: // if (tmp269 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_123_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: // if (tmp267 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_124_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: __ats_lab_125_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: tmp272 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_bool_bool_bool, arg0) ; if (!tmp272) { goto __ats_lab_133_1 ; } do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } tmp273 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp273 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } tmp274 = ats_caselptrlab_mac(anairiats_sum_7, tmp273, atslab_1) ; if (tmp274 != (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } __ats_lab_127_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp276 = ats_caselptrlab_mac(anairiats_sum_7, tmp273, atslab_0) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp275, arg2, arg3) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (tmp277 == (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_128_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_6, tmp277, atslab_0) ; ATS_FREE(tmp277) ; tmp279 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp276, arg2, arg3) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: if (tmp279 == (ats_sum_ptr_type)0) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_6, tmp279, atslab_0) ; ATS_FREE(tmp279) ; tmp281 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_bneq (tmp278, tmp280) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp281) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: // if (tmp279 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_130_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (tmp277 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: __ats_lab_132_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: __ats_lab_133_1: tmp282 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_char_char_bool, arg0) ; if (!tmp282) { goto __ats_lab_140_1 ; } do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } tmp283 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp283 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } tmp284 = ats_caselptrlab_mac(anairiats_sum_7, tmp283, atslab_1) ; if (tmp284 != (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_134_1: tmp285 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp286 = ats_caselptrlab_mac(anairiats_sum_7, tmp283, atslab_0) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp285, arg2, arg3) ; do { /* branch: __ats_lab_135 */ __ats_lab_135_0: if (tmp287 == (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_135_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_6, tmp287, atslab_0) ; ATS_FREE(tmp287) ; tmp289 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp286, arg2, arg3) ; do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (tmp289 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_6, tmp289, atslab_0) ; ATS_FREE(tmp289) ; tmp291 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt (tmp288, tmp290) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp291) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (tmp289 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: // if (tmp287 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: __ats_lab_139_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: __ats_lab_140_1: tmp292 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_char_char_bool, arg0) ; if (!tmp292) { goto __ats_lab_147_1 ; } do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } tmp293 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp293 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } tmp294 = ats_caselptrlab_mac(anairiats_sum_7, tmp293, atslab_1) ; if (tmp294 != (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_141_1: tmp295 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp296 = ats_caselptrlab_mac(anairiats_sum_7, tmp293, atslab_0) ; tmp297 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp295, arg2, arg3) ; do { /* branch: __ats_lab_142 */ __ats_lab_142_0: if (tmp297 == (ats_sum_ptr_type)0) { goto __ats_lab_145_0 ; } __ats_lab_142_1: tmp298 = ats_caselptrlab_mac(anairiats_sum_6, tmp297, atslab_0) ; ATS_FREE(tmp297) ; tmp299 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp296, arg2, arg3) ; do { /* branch: __ats_lab_143 */ __ats_lab_143_0: if (tmp299 == (ats_sum_ptr_type)0) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_6, tmp299, atslab_0) ; ATS_FREE(tmp299) ; tmp301 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte (tmp298, tmp300) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp301) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: // if (tmp299 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_144_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: // if (tmp297 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_145_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: __ats_lab_146_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: __ats_lab_147_1: tmp302 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_char_char_bool, arg0) ; if (!tmp302) { goto __ats_lab_154_1 ; } do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } tmp303 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp303 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } tmp304 = ats_caselptrlab_mac(anairiats_sum_7, tmp303, atslab_1) ; if (tmp304 != (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_148_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp306 = ats_caselptrlab_mac(anairiats_sum_7, tmp303, atslab_0) ; tmp307 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp305, arg2, arg3) ; do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (tmp307 == (ats_sum_ptr_type)0) { goto __ats_lab_152_0 ; } __ats_lab_149_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_6, tmp307, atslab_0) ; ATS_FREE(tmp307) ; tmp309 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp306, arg2, arg3) ; do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (tmp309 == (ats_sum_ptr_type)0) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_6, tmp309, atslab_0) ; ATS_FREE(tmp309) ; tmp311 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt (tmp308, tmp310) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp311) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: // if (tmp309 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_151_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: // if (tmp307 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_152_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: __ats_lab_153_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: __ats_lab_154_1: tmp312 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_char_char_bool, arg0) ; if (!tmp312) { goto __ats_lab_161_1 ; } do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_160_0 ; } tmp313 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp313 == (ats_sum_ptr_type)0) { goto __ats_lab_160_0 ; } tmp314 = ats_caselptrlab_mac(anairiats_sum_7, tmp313, atslab_1) ; if (tmp314 != (ats_sum_ptr_type)0) { goto __ats_lab_160_0 ; } __ats_lab_155_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_7, tmp313, atslab_0) ; tmp317 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp315, arg2, arg3) ; do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (tmp317 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_156_1: tmp318 = ats_caselptrlab_mac(anairiats_sum_6, tmp317, atslab_0) ; ATS_FREE(tmp317) ; tmp319 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp316, arg2, arg3) ; do { /* branch: __ats_lab_157 */ __ats_lab_157_0: if (tmp319 == (ats_sum_ptr_type)0) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp320 = ats_caselptrlab_mac(anairiats_sum_6, tmp319, atslab_0) ; ATS_FREE(tmp319) ; tmp321 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte (tmp318, tmp320) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp321) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: // if (tmp319 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_158_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (tmp317 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: __ats_lab_160_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: __ats_lab_161_1: tmp322 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_char_char_bool, arg0) ; if (!tmp322) { goto __ats_lab_168_1 ; } do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_167_0 ; } tmp323 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp323 == (ats_sum_ptr_type)0) { goto __ats_lab_167_0 ; } tmp324 = ats_caselptrlab_mac(anairiats_sum_7, tmp323, atslab_1) ; if (tmp324 != (ats_sum_ptr_type)0) { goto __ats_lab_167_0 ; } __ats_lab_162_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp326 = ats_caselptrlab_mac(anairiats_sum_7, tmp323, atslab_0) ; tmp327 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp325, arg2, arg3) ; do { /* branch: __ats_lab_163 */ __ats_lab_163_0: if (tmp327 == (ats_sum_ptr_type)0) { goto __ats_lab_166_0 ; } __ats_lab_163_1: tmp328 = ats_caselptrlab_mac(anairiats_sum_6, tmp327, atslab_0) ; ATS_FREE(tmp327) ; tmp329 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp326, arg2, arg3) ; do { /* branch: __ats_lab_164 */ __ats_lab_164_0: if (tmp329 == (ats_sum_ptr_type)0) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_6, tmp329, atslab_0) ; ATS_FREE(tmp329) ; tmp331 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (tmp328, tmp330) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp331) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: // if (tmp329 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_165_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: // if (tmp327 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_166_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: __ats_lab_167_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: __ats_lab_168_1: tmp332 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_char_char_bool, arg0) ; if (!tmp332) { goto __ats_lab_175_1 ; } do { /* branch: __ats_lab_169 */ __ats_lab_169_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_174_0 ; } tmp333 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp333 == (ats_sum_ptr_type)0) { goto __ats_lab_174_0 ; } tmp334 = ats_caselptrlab_mac(anairiats_sum_7, tmp333, atslab_1) ; if (tmp334 != (ats_sum_ptr_type)0) { goto __ats_lab_174_0 ; } __ats_lab_169_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_7, tmp333, atslab_0) ; tmp337 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp335, arg2, arg3) ; do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (tmp337 == (ats_sum_ptr_type)0) { goto __ats_lab_173_0 ; } __ats_lab_170_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_6, tmp337, atslab_0) ; ATS_FREE(tmp337) ; tmp339 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp336, arg2, arg3) ; do { /* branch: __ats_lab_171 */ __ats_lab_171_0: if (tmp339 == (ats_sum_ptr_type)0) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_6, tmp339, atslab_0) ; ATS_FREE(tmp339) ; tmp341 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq (tmp338, tmp340) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp341) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: // if (tmp339 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_172_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: // if (tmp337 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_173_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: __ats_lab_174_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: __ats_lab_175_1: tmp342 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool, arg0) ; if (!tmp342) { goto __ats_lab_182_1 ; } do { /* branch: __ats_lab_176 */ __ats_lab_176_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_181_0 ; } tmp343 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp343 == (ats_sum_ptr_type)0) { goto __ats_lab_181_0 ; } tmp344 = ats_caselptrlab_mac(anairiats_sum_7, tmp343, atslab_1) ; if (tmp344 != (ats_sum_ptr_type)0) { goto __ats_lab_181_0 ; } __ats_lab_176_1: tmp345 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_7, tmp343, atslab_0) ; tmp347 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp345, arg2, arg3) ; do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (tmp347 == (ats_sum_ptr_type)0) { goto __ats_lab_180_0 ; } __ats_lab_177_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_6, tmp347, atslab_0) ; ATS_FREE(tmp347) ; tmp349 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp346, arg2, arg3) ; do { /* branch: __ats_lab_178 */ __ats_lab_178_0: if (tmp349 == (ats_sum_ptr_type)0) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_6, tmp349, atslab_0) ; ATS_FREE(tmp349) ; tmp351 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igt (tmp348, tmp350) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp351) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: // if (tmp349 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_179_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: // if (tmp347 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_180_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: __ats_lab_181_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: __ats_lab_182_1: tmp352 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool, arg0) ; if (!tmp352) { goto __ats_lab_189_1 ; } do { /* branch: __ats_lab_183 */ __ats_lab_183_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } tmp353 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp353 == (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } tmp354 = ats_caselptrlab_mac(anairiats_sum_7, tmp353, atslab_1) ; if (tmp354 != (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } __ats_lab_183_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp356 = ats_caselptrlab_mac(anairiats_sum_7, tmp353, atslab_0) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp355, arg2, arg3) ; do { /* branch: __ats_lab_184 */ __ats_lab_184_0: if (tmp357 == (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_184_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_6, tmp357, atslab_0) ; ATS_FREE(tmp357) ; tmp359 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp356, arg2, arg3) ; do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (tmp359 == (ats_sum_ptr_type)0) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp360 = ats_caselptrlab_mac(anairiats_sum_6, tmp359, atslab_0) ; ATS_FREE(tmp359) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_igte (tmp358, tmp360) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp361) ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: // if (tmp359 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_186_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: // if (tmp357 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_187_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: __ats_lab_188_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: __ats_lab_189_1: tmp362 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool, arg0) ; if (!tmp362) { goto __ats_lab_196_1 ; } do { /* branch: __ats_lab_190 */ __ats_lab_190_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_195_0 ; } tmp363 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp363 == (ats_sum_ptr_type)0) { goto __ats_lab_195_0 ; } tmp364 = ats_caselptrlab_mac(anairiats_sum_7, tmp363, atslab_1) ; if (tmp364 != (ats_sum_ptr_type)0) { goto __ats_lab_195_0 ; } __ats_lab_190_1: tmp365 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp366 = ats_caselptrlab_mac(anairiats_sum_7, tmp363, atslab_0) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp365, arg2, arg3) ; do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (tmp367 == (ats_sum_ptr_type)0) { goto __ats_lab_194_0 ; } __ats_lab_191_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_6, tmp367, atslab_0) ; ATS_FREE(tmp367) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp366, arg2, arg3) ; do { /* branch: __ats_lab_192 */ __ats_lab_192_0: if (tmp369 == (ats_sum_ptr_type)0) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_6, tmp369, atslab_0) ; ATS_FREE(tmp369) ; tmp371 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilt (tmp368, tmp370) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp371) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: // if (tmp369 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_193_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: // if (tmp367 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_194_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: __ats_lab_195_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: __ats_lab_196_1: tmp372 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool, arg0) ; if (!tmp372) { goto __ats_lab_203_1 ; } do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } tmp373 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp373 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } tmp374 = ats_caselptrlab_mac(anairiats_sum_7, tmp373, atslab_1) ; if (tmp374 != (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } __ats_lab_197_1: tmp375 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp376 = ats_caselptrlab_mac(anairiats_sum_7, tmp373, atslab_0) ; tmp377 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp375, arg2, arg3) ; do { /* branch: __ats_lab_198 */ __ats_lab_198_0: if (tmp377 == (ats_sum_ptr_type)0) { goto __ats_lab_201_0 ; } __ats_lab_198_1: tmp378 = ats_caselptrlab_mac(anairiats_sum_6, tmp377, atslab_0) ; ATS_FREE(tmp377) ; tmp379 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp376, arg2, arg3) ; do { /* branch: __ats_lab_199 */ __ats_lab_199_0: if (tmp379 == (ats_sum_ptr_type)0) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp380 = ats_caselptrlab_mac(anairiats_sum_6, tmp379, atslab_0) ; ATS_FREE(tmp379) ; tmp381 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ilte (tmp378, tmp380) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp381) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: // if (tmp379 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_200_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: // if (tmp377 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_201_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: __ats_lab_202_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: __ats_lab_203_1: tmp382 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_int_int_bool, arg0) ; if (!tmp382) { goto __ats_lab_210_1 ; } do { /* branch: __ats_lab_204 */ __ats_lab_204_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } tmp383 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp383 == (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } tmp384 = ats_caselptrlab_mac(anairiats_sum_7, tmp383, atslab_1) ; if (tmp384 != (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } __ats_lab_204_1: tmp385 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_7, tmp383, atslab_0) ; tmp387 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp385, arg2, arg3) ; do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (tmp387 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } __ats_lab_205_1: tmp388 = ats_caselptrlab_mac(anairiats_sum_6, tmp387, atslab_0) ; ATS_FREE(tmp387) ; tmp389 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp386, arg2, arg3) ; do { /* branch: __ats_lab_206 */ __ats_lab_206_0: if (tmp389 == (ats_sum_ptr_type)0) { goto __ats_lab_207_0 ; } __ats_lab_206_1: tmp390 = ats_caselptrlab_mac(anairiats_sum_6, tmp389, atslab_0) ; ATS_FREE(tmp389) ; tmp391 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (tmp388, tmp390) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp391) ; break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: // if (tmp389 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_207_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: // if (tmp387 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_208_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: __ats_lab_209_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: __ats_lab_210_1: tmp392 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool, arg0) ; if (!tmp392) { goto __ats_lab_217_1 ; } do { /* branch: __ats_lab_211 */ __ats_lab_211_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_216_0 ; } tmp393 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp393 == (ats_sum_ptr_type)0) { goto __ats_lab_216_0 ; } tmp394 = ats_caselptrlab_mac(anairiats_sum_7, tmp393, atslab_1) ; if (tmp394 != (ats_sum_ptr_type)0) { goto __ats_lab_216_0 ; } __ats_lab_211_1: tmp395 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp396 = ats_caselptrlab_mac(anairiats_sum_7, tmp393, atslab_0) ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp395, arg2, arg3) ; do { /* branch: __ats_lab_212 */ __ats_lab_212_0: if (tmp397 == (ats_sum_ptr_type)0) { goto __ats_lab_215_0 ; } __ats_lab_212_1: tmp398 = ats_caselptrlab_mac(anairiats_sum_6, tmp397, atslab_0) ; ATS_FREE(tmp397) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp396, arg2, arg3) ; do { /* branch: __ats_lab_213 */ __ats_lab_213_0: if (tmp399 == (ats_sum_ptr_type)0) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_6, tmp399, atslab_0) ; ATS_FREE(tmp399) ; tmp401 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ineq (tmp398, tmp400) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp401) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: // if (tmp399 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_214_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: // if (tmp397 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_215_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: __ats_lab_216_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: __ats_lab_217_1: tmp402 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool, arg0) ; if (!tmp402) { goto __ats_lab_224_1 ; } do { /* branch: __ats_lab_218 */ __ats_lab_218_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_223_0 ; } tmp403 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp403 == (ats_sum_ptr_type)0) { goto __ats_lab_223_0 ; } tmp404 = ats_caselptrlab_mac(anairiats_sum_7, tmp403, atslab_1) ; if (tmp404 != (ats_sum_ptr_type)0) { goto __ats_lab_223_0 ; } __ats_lab_218_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_7, tmp403, atslab_0) ; tmp407 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp405, arg2, arg3) ; do { /* branch: __ats_lab_219 */ __ats_lab_219_0: if (tmp407 == (ats_sum_ptr_type)0) { goto __ats_lab_222_0 ; } __ats_lab_219_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_6, tmp407, atslab_0) ; ATS_FREE(tmp407) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp406, arg2, arg3) ; do { /* branch: __ats_lab_220 */ __ats_lab_220_0: if (tmp409 == (ats_sum_ptr_type)0) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp410 = ats_caselptrlab_mac(anairiats_sum_6, tmp409, atslab_0) ; ATS_FREE(tmp409) ; tmp411 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgt (tmp408, tmp410) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp411) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: // if (tmp409 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_221_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: // if (tmp407 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_222_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: __ats_lab_223_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: __ats_lab_224_1: tmp412 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool, arg0) ; if (!tmp412) { goto __ats_lab_231_1 ; } do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } tmp413 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp413 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } tmp414 = ats_caselptrlab_mac(anairiats_sum_7, tmp413, atslab_1) ; if (tmp414 != (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } __ats_lab_225_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp416 = ats_caselptrlab_mac(anairiats_sum_7, tmp413, atslab_0) ; tmp417 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp415, arg2, arg3) ; do { /* branch: __ats_lab_226 */ __ats_lab_226_0: if (tmp417 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_226_1: tmp418 = ats_caselptrlab_mac(anairiats_sum_6, tmp417, atslab_0) ; ATS_FREE(tmp417) ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp416, arg2, arg3) ; do { /* branch: __ats_lab_227 */ __ats_lab_227_0: if (tmp419 == (ats_sum_ptr_type)0) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp420 = ats_caselptrlab_mac(anairiats_sum_6, tmp419, atslab_0) ; ATS_FREE(tmp419) ; tmp421 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pgte (tmp418, tmp420) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp421) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: // if (tmp419 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_228_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (tmp417 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: __ats_lab_230_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: __ats_lab_231_1: tmp422 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool, arg0) ; if (!tmp422) { goto __ats_lab_238_1 ; } do { /* branch: __ats_lab_232 */ __ats_lab_232_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } tmp423 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp423 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } tmp424 = ats_caselptrlab_mac(anairiats_sum_7, tmp423, atslab_1) ; if (tmp424 != (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } __ats_lab_232_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_7, tmp423, atslab_0) ; tmp427 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp425, arg2, arg3) ; do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (tmp427 == (ats_sum_ptr_type)0) { goto __ats_lab_236_0 ; } __ats_lab_233_1: tmp428 = ats_caselptrlab_mac(anairiats_sum_6, tmp427, atslab_0) ; ATS_FREE(tmp427) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp426, arg2, arg3) ; do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (tmp429 == (ats_sum_ptr_type)0) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_6, tmp429, atslab_0) ; ATS_FREE(tmp429) ; tmp431 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plt (tmp428, tmp430) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp431) ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (tmp429 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: // if (tmp427 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_236_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: __ats_lab_237_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: __ats_lab_238_1: tmp432 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool, arg0) ; if (!tmp432) { goto __ats_lab_245_1 ; } do { /* branch: __ats_lab_239 */ __ats_lab_239_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } tmp433 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp433 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } tmp434 = ats_caselptrlab_mac(anairiats_sum_7, tmp433, atslab_1) ; if (tmp434 != (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_239_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_7, tmp433, atslab_0) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp435, arg2, arg3) ; do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (tmp437 == (ats_sum_ptr_type)0) { goto __ats_lab_243_0 ; } __ats_lab_240_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_6, tmp437, atslab_0) ; ATS_FREE(tmp437) ; tmp439 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp436, arg2, arg3) ; do { /* branch: __ats_lab_241 */ __ats_lab_241_0: if (tmp439 == (ats_sum_ptr_type)0) { goto __ats_lab_242_0 ; } __ats_lab_241_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_6, tmp439, atslab_0) ; ATS_FREE(tmp439) ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_plte (tmp438, tmp440) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp441) ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: // if (tmp439 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_242_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: // if (tmp437 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_243_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: __ats_lab_244_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: __ats_lab_245_1: tmp442 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_addr_addr_bool, arg0) ; if (!tmp442) { goto __ats_lab_252_1 ; } do { /* branch: __ats_lab_246 */ __ats_lab_246_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } tmp443 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp443 == (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } tmp444 = ats_caselptrlab_mac(anairiats_sum_7, tmp443, atslab_1) ; if (tmp444 != (ats_sum_ptr_type)0) { goto __ats_lab_251_0 ; } __ats_lab_246_1: tmp445 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp446 = ats_caselptrlab_mac(anairiats_sum_7, tmp443, atslab_0) ; tmp447 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp445, arg2, arg3) ; do { /* branch: __ats_lab_247 */ __ats_lab_247_0: if (tmp447 == (ats_sum_ptr_type)0) { goto __ats_lab_250_0 ; } __ats_lab_247_1: tmp448 = ats_caselptrlab_mac(anairiats_sum_6, tmp447, atslab_0) ; ATS_FREE(tmp447) ; tmp449 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp446, arg2, arg3) ; do { /* branch: __ats_lab_248 */ __ats_lab_248_0: if (tmp449 == (ats_sum_ptr_type)0) { goto __ats_lab_249_0 ; } __ats_lab_248_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_6, tmp449, atslab_0) ; ATS_FREE(tmp449) ; tmp451 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq (tmp448, tmp450) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp451) ; break ; /* branch: __ats_lab_249 */ __ats_lab_249_0: // if (tmp449 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_249_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: // if (tmp447 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_250_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: __ats_lab_251_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: __ats_lab_252_1: tmp452 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_addr_addr_bool, arg0) ; if (!tmp452) { goto __ats_lab_259_1 ; } do { /* branch: __ats_lab_253 */ __ats_lab_253_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_258_0 ; } tmp453 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp453 == (ats_sum_ptr_type)0) { goto __ats_lab_258_0 ; } tmp454 = ats_caselptrlab_mac(anairiats_sum_7, tmp453, atslab_1) ; if (tmp454 != (ats_sum_ptr_type)0) { goto __ats_lab_258_0 ; } __ats_lab_253_1: tmp455 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp456 = ats_caselptrlab_mac(anairiats_sum_7, tmp453, atslab_0) ; tmp457 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp455, arg2, arg3) ; do { /* branch: __ats_lab_254 */ __ats_lab_254_0: if (tmp457 == (ats_sum_ptr_type)0) { goto __ats_lab_257_0 ; } __ats_lab_254_1: tmp458 = ats_caselptrlab_mac(anairiats_sum_6, tmp457, atslab_0) ; ATS_FREE(tmp457) ; tmp459 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp456, arg2, arg3) ; do { /* branch: __ats_lab_255 */ __ats_lab_255_0: if (tmp459 == (ats_sum_ptr_type)0) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp460 = ats_caselptrlab_mac(anairiats_sum_6, tmp459, atslab_0) ; ATS_FREE(tmp459) ; tmp461 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_pneq (tmp458, tmp460) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp461) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: // if (tmp459 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_256_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: // if (tmp457 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_257_1: tmp230 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: __ats_lab_258_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_259 */ __ats_lab_259_0: __ats_lab_259_1: tmp462 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_cls_cls_bool, arg0) ; if (!tmp462) { goto __ats_lab_265_1 ; } do { /* branch: __ats_lab_260 */ __ats_lab_260_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_264_0 ; } tmp463 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp463 == (ats_sum_ptr_type)0) { goto __ats_lab_264_0 ; } tmp464 = ats_caselptrlab_mac(anairiats_sum_7, tmp463, atslab_1) ; if (tmp464 != (ats_sum_ptr_type)0) { goto __ats_lab_264_0 ; } __ats_lab_260_1: tmp465 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp466 = ats_caselptrlab_mac(anairiats_sum_7, tmp463, atslab_0) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test (tmp465, tmp466) ; do { /* branch: __ats_lab_261 */ __ats_lab_261_0: __ats_lab_261_1: tmp468 = atspre_igt (tmp467, 0) ; if (!tmp468) { goto __ats_lab_262_1 ; } tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true) ; break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: __ats_lab_262_1: tmp469 = atspre_ilt (tmp467, 0) ; if (!tmp469) { goto __ats_lab_263_1 ; } tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false) ; break ; /* branch: __ats_lab_263 */ __ats_lab_263_0: __ats_lab_263_1: tmp470 = s2cfdeflst_replace_none_48 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, arg0, arg1, arg2, arg3) ; tmp471 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var (tmp470) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp471) ; break ; } while (0) ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: __ats_lab_264_1: tmp230 = errmsg_52 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: __ats_lab_265_1: tmp472 = s2cfdeflst_replace_none_48 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, arg0, arg1, arg2, arg3) ; tmp473 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var (tmp472) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp230, atslab_0, tmp473) ; break ; } while (0) ; return (tmp230) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_make_s2cst_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 31347(line=933, offs=6) -- 31531(line=937, offs=6) */ ATSstaticdec() ats_ptr_type errmsg_54 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp475) ; // ATSlocal_void (tmp476) ; // ATSlocal_void (tmp477) ; // ATSlocal_void (tmp478) ; // ATSlocal_void (tmp479) ; __ats_lab_errmsg_54: /* tmp476 = */ prerr_interror_0 () ; /* tmp477 = */ atspre_prerr_string (ATSstrcst(": s3iexp_make_s2cst_s2explst: s2c = ")) ; /* tmp478 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg0) ; /* tmp479 = */ atspre_prerr_newline () ; /* tmp475 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp475) ; } /* end of [errmsg_54] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 31313(line=932, offs=3) -- 36938(line=1081, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_make_s2cst_s2explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_bool_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_bool_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_bool_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_bool_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_bool_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_bool_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_bool_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_bool_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_bool_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_bool_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_bool_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_bool_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; ATSlocal (ats_bool_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_make_s2cst_s2explst: do { /* branch: __ats_lab_266 */ __ats_lab_266_0: __ats_lab_266_1: tmp480 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_int_int, arg0) ; if (!tmp480) { goto __ats_lab_271_1 ; } do { /* branch: __ats_lab_267 */ __ats_lab_267_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_270_0 ; } tmp481 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp481 != (ats_sum_ptr_type)0) { goto __ats_lab_270_0 ; } __ats_lab_267_1: tmp482 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp483 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp482, arg2, arg3) ; do { /* branch: __ats_lab_268 */ __ats_lab_268_0: if (tmp483 == (ats_sum_ptr_type)0) { goto __ats_lab_269_0 ; } __ats_lab_268_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_6, tmp483, atslab_0) ; ATS_FREE(tmp483) ; tmp485 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_ineg (tmp484) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp485) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: // if (tmp483 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_269_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: __ats_lab_270_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_271 */ __ats_lab_271_0: __ats_lab_271_1: tmp486 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_int_int_int, arg0) ; if (!tmp486) { goto __ats_lab_278_1 ; } do { /* branch: __ats_lab_272 */ __ats_lab_272_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_277_0 ; } tmp487 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp487 == (ats_sum_ptr_type)0) { goto __ats_lab_277_0 ; } tmp488 = ats_caselptrlab_mac(anairiats_sum_7, tmp487, atslab_1) ; if (tmp488 != (ats_sum_ptr_type)0) { goto __ats_lab_277_0 ; } __ats_lab_272_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp490 = ats_caselptrlab_mac(anairiats_sum_7, tmp487, atslab_0) ; tmp491 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp489, arg2, arg3) ; do { /* branch: __ats_lab_273 */ __ats_lab_273_0: if (tmp491 == (ats_sum_ptr_type)0) { goto __ats_lab_276_0 ; } __ats_lab_273_1: tmp492 = ats_caselptrlab_mac(anairiats_sum_6, tmp491, atslab_0) ; ATS_FREE(tmp491) ; tmp493 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp490, arg2, arg3) ; do { /* branch: __ats_lab_274 */ __ats_lab_274_0: if (tmp493 == (ats_sum_ptr_type)0) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp494 = ats_caselptrlab_mac(anairiats_sum_6, tmp493, atslab_0) ; ATS_FREE(tmp493) ; tmp495 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_iadd (tmp492, tmp494) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp495) ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: // if (tmp493 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_275_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: // if (tmp491 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_276_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_277 */ __ats_lab_277_0: __ats_lab_277_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_278 */ __ats_lab_278_0: __ats_lab_278_1: tmp496 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_int_int_int, arg0) ; if (!tmp496) { goto __ats_lab_285_1 ; } do { /* branch: __ats_lab_279 */ __ats_lab_279_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } tmp497 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp497 == (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } tmp498 = ats_caselptrlab_mac(anairiats_sum_7, tmp497, atslab_1) ; if (tmp498 != (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } __ats_lab_279_1: tmp499 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp500 = ats_caselptrlab_mac(anairiats_sum_7, tmp497, atslab_0) ; tmp501 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp499, arg2, arg3) ; do { /* branch: __ats_lab_280 */ __ats_lab_280_0: if (tmp501 == (ats_sum_ptr_type)0) { goto __ats_lab_283_0 ; } __ats_lab_280_1: tmp502 = ats_caselptrlab_mac(anairiats_sum_6, tmp501, atslab_0) ; ATS_FREE(tmp501) ; tmp503 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp500, arg2, arg3) ; do { /* branch: __ats_lab_281 */ __ats_lab_281_0: if (tmp503 == (ats_sum_ptr_type)0) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp504 = ats_caselptrlab_mac(anairiats_sum_6, tmp503, atslab_0) ; ATS_FREE(tmp503) ; tmp505 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (tmp502, tmp504) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp505) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: // if (tmp503 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_282_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_283 */ __ats_lab_283_0: // if (tmp501 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_283_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: __ats_lab_284_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_285 */ __ats_lab_285_0: __ats_lab_285_1: tmp506 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_int_int_int, arg0) ; if (!tmp506) { goto __ats_lab_292_1 ; } do { /* branch: __ats_lab_286 */ __ats_lab_286_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_291_0 ; } tmp507 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp507 == (ats_sum_ptr_type)0) { goto __ats_lab_291_0 ; } tmp508 = ats_caselptrlab_mac(anairiats_sum_7, tmp507, atslab_1) ; if (tmp508 != (ats_sum_ptr_type)0) { goto __ats_lab_291_0 ; } __ats_lab_286_1: tmp509 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp510 = ats_caselptrlab_mac(anairiats_sum_7, tmp507, atslab_0) ; tmp511 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp509, arg2, arg3) ; do { /* branch: __ats_lab_287 */ __ats_lab_287_0: if (tmp511 == (ats_sum_ptr_type)0) { goto __ats_lab_290_0 ; } __ats_lab_287_1: tmp512 = ats_caselptrlab_mac(anairiats_sum_6, tmp511, atslab_0) ; ATS_FREE(tmp511) ; tmp513 = s3iexp_is_const_28 (tmp512) ; tmp514 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp510, arg2, arg3) ; do { /* branch: __ats_lab_288 */ __ats_lab_288_0: if (tmp514 == (ats_sum_ptr_type)0) { goto __ats_lab_289_0 ; } __ats_lab_288_1: tmp515 = ats_caselptrlab_mac(anairiats_sum_6, tmp514, atslab_0) ; ATS_FREE(tmp514) ; if (tmp513) { tmp516 = ats_true_bool ; } else { tmp516 = s3iexp_is_const_28 (tmp515) ; } /* end of [if] */ if (tmp516) { tmp517 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_imul (tmp512, tmp515) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp517) ; } else { tmp518 = s2cfdeflst_replace_none_48 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, arg0, arg1, arg2, arg3) ; tmp519 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp518) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp519) ; } /* end of [if] */ break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: // if (tmp514 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_289_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_290 */ __ats_lab_290_0: // if (tmp511 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_290_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_291 */ __ats_lab_291_0: __ats_lab_291_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_292 */ __ats_lab_292_0: __ats_lab_292_1: tmp520 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_addr_int, arg0) ; if (!tmp520) { goto __ats_lab_299_1 ; } do { /* branch: __ats_lab_293 */ __ats_lab_293_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_298_0 ; } tmp521 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp521 == (ats_sum_ptr_type)0) { goto __ats_lab_298_0 ; } tmp522 = ats_caselptrlab_mac(anairiats_sum_7, tmp521, atslab_1) ; if (tmp522 != (ats_sum_ptr_type)0) { goto __ats_lab_298_0 ; } __ats_lab_293_1: tmp523 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp524 = ats_caselptrlab_mac(anairiats_sum_7, tmp521, atslab_0) ; tmp525 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp523, arg2, arg3) ; do { /* branch: __ats_lab_294 */ __ats_lab_294_0: if (tmp525 == (ats_sum_ptr_type)0) { goto __ats_lab_297_0 ; } __ats_lab_294_1: tmp526 = ats_caselptrlab_mac(anairiats_sum_6, tmp525, atslab_0) ; ATS_FREE(tmp525) ; tmp527 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (tmp524, arg2, arg3) ; do { /* branch: __ats_lab_295 */ __ats_lab_295_0: if (tmp527 == (ats_sum_ptr_type)0) { goto __ats_lab_296_0 ; } __ats_lab_295_1: tmp528 = ats_caselptrlab_mac(anairiats_sum_6, tmp527, atslab_0) ; ATS_FREE(tmp527) ; tmp529 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_pdiff (tmp526, tmp528) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp529) ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: // if (tmp527 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_296_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_297 */ __ats_lab_297_0: // if (tmp525 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_297_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_298 */ __ats_lab_298_0: __ats_lab_298_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_299 */ __ats_lab_299_0: __ats_lab_299_1: tmp530 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_char_char_int, arg0) ; if (!tmp530) { goto __ats_lab_306_1 ; } do { /* branch: __ats_lab_300 */ __ats_lab_300_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_305_0 ; } tmp531 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; if (tmp531 == (ats_sum_ptr_type)0) { goto __ats_lab_305_0 ; } tmp532 = ats_caselptrlab_mac(anairiats_sum_7, tmp531, atslab_1) ; if (tmp532 != (ats_sum_ptr_type)0) { goto __ats_lab_305_0 ; } __ats_lab_300_1: tmp533 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp534 = ats_caselptrlab_mac(anairiats_sum_7, tmp531, atslab_0) ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp533, arg2, arg3) ; do { /* branch: __ats_lab_301 */ __ats_lab_301_0: if (tmp535 == (ats_sum_ptr_type)0) { goto __ats_lab_304_0 ; } __ats_lab_301_1: tmp536 = ats_caselptrlab_mac(anairiats_sum_6, tmp535, atslab_0) ; ATS_FREE(tmp535) ; tmp537 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (tmp534, arg2, arg3) ; do { /* branch: __ats_lab_302 */ __ats_lab_302_0: if (tmp537 == (ats_sum_ptr_type)0) { goto __ats_lab_303_0 ; } __ats_lab_302_1: tmp538 = ats_caselptrlab_mac(anairiats_sum_6, tmp537, atslab_0) ; ATS_FREE(tmp537) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_isub (tmp536, tmp538) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp539) ; break ; /* branch: __ats_lab_303 */ __ats_lab_303_0: // if (tmp537 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_303_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_304 */ __ats_lab_304_0: // if (tmp535 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_304_1: tmp474 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_305 */ __ats_lab_305_0: __ats_lab_305_1: tmp474 = errmsg_54 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_306 */ __ats_lab_306_0: __ats_lab_306_1: tmp540 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int, arg0) ; if (!tmp540) { goto __ats_lab_307_1 ; } tmp541 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int_bool) ; tmp542 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp541, arg1, arg2, arg3) ; tmp543 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp542) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp543) ; break ; /* branch: __ats_lab_307 */ __ats_lab_307_0: __ats_lab_307_1: tmp544 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int, arg0) ; if (!tmp544) { goto __ats_lab_308_1 ; } tmp545 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int_bool) ; tmp546 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp545, arg1, arg2, arg3) ; tmp547 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp546) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp547) ; break ; /* branch: __ats_lab_308 */ __ats_lab_308_0: __ats_lab_308_1: tmp548 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int, arg0) ; if (!tmp548) { goto __ats_lab_309_1 ; } tmp549 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int_bool) ; tmp550 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp549, arg1, arg2, arg3) ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp550) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp551) ; break ; /* branch: __ats_lab_309 */ __ats_lab_309_0: __ats_lab_309_1: tmp552 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int, arg0) ; if (!tmp552) { goto __ats_lab_310_1 ; } tmp553 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int_bool) ; tmp554 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp553, arg1, arg2, arg3) ; tmp555 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp554) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp555) ; break ; /* branch: __ats_lab_310 */ __ats_lab_310_0: __ats_lab_310_1: tmp556 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int, arg0) ; if (!tmp556) { goto __ats_lab_311_1 ; } tmp557 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int_bool) ; tmp558 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp557, arg1, arg2, arg3) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp558) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp559) ; break ; /* branch: __ats_lab_311 */ __ats_lab_311_0: __ats_lab_311_1: tmp560 = s2cfdeflst_replace_none_48 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, arg0, arg1, arg2, arg3) ; tmp561 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp560) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp474, atslab_0, tmp561) ; break ; } while (0) ; return (tmp474) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_make_s2cst_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 37010(line=1087, offs=4) -- 39257(line=1144, offs=4) */ ATSstaticdec() ats_ptr_type aux_equal_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_bool_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_bool_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_bool_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_bool_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_bool_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_bool_type, tmp594) ; __ats_lab_aux_equal_55: tmp563 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s2exp_srt) ; do { /* branch: __ats_lab_312 */ __ats_lab_312_0: __ats_lab_312_1: tmp564 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp563, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int) ; if (!tmp564) { goto __ats_lab_317_1 ; } tmp565 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg0, arg2, arg3) ; do { /* branch: __ats_lab_313 */ __ats_lab_313_0: if (tmp565 == (ats_sum_ptr_type)0) { goto __ats_lab_316_0 ; } __ats_lab_313_1: tmp566 = ats_caselptrlab_mac(anairiats_sum_6, tmp565, atslab_0) ; ATS_FREE(tmp565) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg1, arg2, arg3) ; do { /* branch: __ats_lab_314 */ __ats_lab_314_0: if (tmp567 == (ats_sum_ptr_type)0) { goto __ats_lab_315_0 ; } __ats_lab_314_1: tmp568 = ats_caselptrlab_mac(anairiats_sum_6, tmp567, atslab_0) ; ATS_FREE(tmp567) ; tmp569 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (tmp566, tmp568) ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp569) ; break ; /* branch: __ats_lab_315 */ __ats_lab_315_0: // if (tmp567 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_315_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_316 */ __ats_lab_316_0: // if (tmp565 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_316_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_317 */ __ats_lab_317_0: __ats_lab_317_1: tmp570 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp563, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_addr) ; if (!tmp570) { goto __ats_lab_322_1 ; } tmp571 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (arg0, arg2, arg3) ; do { /* branch: __ats_lab_318 */ __ats_lab_318_0: if (tmp571 == (ats_sum_ptr_type)0) { goto __ats_lab_321_0 ; } __ats_lab_318_1: tmp572 = ats_caselptrlab_mac(anairiats_sum_6, tmp571, atslab_0) ; ATS_FREE(tmp571) ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (arg1, arg2, arg3) ; do { /* branch: __ats_lab_319 */ __ats_lab_319_0: if (tmp573 == (ats_sum_ptr_type)0) { goto __ats_lab_320_0 ; } __ats_lab_319_1: tmp574 = ats_caselptrlab_mac(anairiats_sum_6, tmp573, atslab_0) ; ATS_FREE(tmp573) ; tmp575 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_peq (tmp572, tmp574) ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp575) ; break ; /* branch: __ats_lab_320 */ __ats_lab_320_0: // if (tmp573 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_320_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_321 */ __ats_lab_321_0: // if (tmp571 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_321_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_322 */ __ats_lab_322_0: __ats_lab_322_1: tmp576 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp563, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; if (!tmp576) { goto __ats_lab_327_1 ; } tmp577 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (arg0, arg2, arg3) ; do { /* branch: __ats_lab_323 */ __ats_lab_323_0: if (tmp577 == (ats_sum_ptr_type)0) { goto __ats_lab_326_0 ; } __ats_lab_323_1: tmp578 = ats_caselptrlab_mac(anairiats_sum_6, tmp577, atslab_0) ; ATS_FREE(tmp577) ; tmp579 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (arg1, arg2, arg3) ; do { /* branch: __ats_lab_324 */ __ats_lab_324_0: if (tmp579 == (ats_sum_ptr_type)0) { goto __ats_lab_325_0 ; } __ats_lab_324_1: tmp580 = ats_caselptrlab_mac(anairiats_sum_6, tmp579, atslab_0) ; ATS_FREE(tmp579) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_beq (tmp578, tmp580) ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp581) ; break ; /* branch: __ats_lab_325 */ __ats_lab_325_0: // if (tmp579 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_325_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_326 */ __ats_lab_326_0: // if (tmp577 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_326_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_327 */ __ats_lab_327_0: __ats_lab_327_1: tmp582 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp563, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_char) ; if (!tmp582) { goto __ats_lab_332_1 ; } tmp583 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg0, arg2, arg3) ; do { /* branch: __ats_lab_328 */ __ats_lab_328_0: if (tmp583 == (ats_sum_ptr_type)0) { goto __ats_lab_331_0 ; } __ats_lab_328_1: tmp584 = ats_caselptrlab_mac(anairiats_sum_6, tmp583, atslab_0) ; ATS_FREE(tmp583) ; tmp585 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg1, arg2, arg3) ; do { /* branch: __ats_lab_329 */ __ats_lab_329_0: if (tmp585 == (ats_sum_ptr_type)0) { goto __ats_lab_330_0 ; } __ats_lab_329_1: tmp586 = ats_caselptrlab_mac(anairiats_sum_6, tmp585, atslab_0) ; ATS_FREE(tmp585) ; tmp587 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (tmp584, tmp586) ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp587) ; break ; /* branch: __ats_lab_330 */ __ats_lab_330_0: // if (tmp585 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_330_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_331 */ __ats_lab_331_0: // if (tmp583 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_331_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_332 */ __ats_lab_332_0: __ats_lab_332_1: tmp588 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat (tmp563) ; if (!tmp588) { goto __ats_lab_337_1 ; } tmp589 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg0, arg2, arg3) ; do { /* branch: __ats_lab_333 */ __ats_lab_333_0: if (tmp589 == (ats_sum_ptr_type)0) { goto __ats_lab_336_0 ; } __ats_lab_333_1: tmp590 = ats_caselptrlab_mac(anairiats_sum_6, tmp589, atslab_0) ; ATS_FREE(tmp589) ; tmp591 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (arg1, arg2, arg3) ; do { /* branch: __ats_lab_334 */ __ats_lab_334_0: if (tmp591 == (ats_sum_ptr_type)0) { goto __ats_lab_335_0 ; } __ats_lab_334_1: tmp592 = ats_caselptrlab_mac(anairiats_sum_6, tmp591, atslab_0) ; ATS_FREE(tmp591) ; tmp593 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_ieq (tmp590, tmp592) ; tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, tmp593) ; break ; /* branch: __ats_lab_335 */ __ats_lab_335_0: // if (tmp591 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_335_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_336 */ __ats_lab_336_0: // if (tmp589 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_336_1: tmp562 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_337 */ __ats_lab_337_0: __ats_lab_337_1: tmp594 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (arg0, arg1) ; if (tmp594) { tmp562 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp562, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true) ; } else { tmp562 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; } while (0) ; return (tmp562) ; } /* end of [aux_equal_55] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 39284(line=1146, offs=4) -- 39690(line=1159, offs=4) */ ATSstaticdec() ats_ptr_type aux_bind_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; // ATSlocal_void (tmp598) ; __ats_lab_aux_bind_56: tmp597 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (arg1) ; tmp596 = aux_equal_55 (tmp597, arg2, arg3, arg4) ; /* tmp598 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (arg0, arg1, arg2) ; tmp595 = tmp596 ; return (tmp595) ; } /* end of [aux_bind_56] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 39805(line=1164, offs=7) -- 40012(line=1169, offs=6) */ ATSstaticdec() ats_bool_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_bool_type, tmp603) ; __ats_lab_aux_58: do { /* branch: __ats_lab_338 */ __ats_lab_338_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_339_0 ; } __ats_lab_338_1: tmp601 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp602 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (arg1, tmp601) ; if (tmp603) { tmp600 = ats_true_bool ; } else { arg0 = tmp602 ; arg1 = arg1 ; goto __ats_lab_aux_58 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_339 */ __ats_lab_339_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_339_1: tmp600 = ats_false_bool ; break ; } while (0) ; return (tmp600) ; } /* end of [aux_58] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 39738(line=1163, offs=5) -- 40098(line=1172, offs=4) */ ATSstaticdec() ats_ptr_type s2cstlst_add_57 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_bool_type, tmp604) ; __ats_lab_s2cstlst_add_57: tmp604 = aux_58 (arg0, arg1) ; if (tmp604) { tmp599 = arg0 ; } else { tmp599 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp599, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp599, atslab_1, arg0) ; } /* end of [if] */ return (tmp599) ; } /* end of [s2cstlst_add_57] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 40155(line=1176, offs=3) -- 41025(line=1201, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_bool_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; // ATSlocal_void (tmp618) ; // ATSlocal_void (tmp619) ; // ATSlocal_void (tmp620) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp: tmp606 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp607 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp606), atslab_s2exp_node) ; do { /* branch: __ats_lab_340 */ __ats_lab_340_0: if (((ats_sum_ptr_type)tmp607)->tag != 0) { goto __ats_lab_343_0 ; } __ats_lab_340_1: tmp608 = ats_caselptrlab_mac(anairiats_sum_1, tmp607, atslab_0) ; tmp609 = ats_caselptrlab_mac(anairiats_sum_1, tmp607, atslab_1) ; tmp610 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp608), atslab_s2exp_node) ; do { /* branch: __ats_lab_341 */ __ats_lab_341_0: if (((ats_sum_ptr_type)tmp610)->tag != 4) { goto __ats_lab_342_0 ; } __ats_lab_341_1: tmp611 = ats_caselptrlab_mac(anairiats_sum_0, tmp610, atslab_0) ; tmp605 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_make_s2cst_s2explst (tmp611, tmp609, arg1, arg2) ; break ; /* branch: __ats_lab_342 */ __ats_lab_342_0: __ats_lab_342_1: tmp605 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_343 */ __ats_lab_343_0: if (((ats_sum_ptr_type)tmp607)->tag != 4) { goto __ats_lab_346_0 ; } __ats_lab_343_1: tmp612 = ats_caselptrlab_mac(anairiats_sum_0, tmp607, atslab_0) ; do { /* branch: __ats_lab_344 */ __ats_lab_344_0: __ats_lab_344_1: tmp613 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr, tmp612) ; if (!tmp613) { goto __ats_lab_345_1 ; } tmp605 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp605, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_null) ; break ; /* branch: __ats_lab_345 */ __ats_lab_345_0: __ats_lab_345_1: tmp614 = s2cstlst_add_57 (ats_ptrget_mac(ats_ptr_type, arg1), tmp612) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp614 ; tmp615 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_cst (tmp612) ; tmp605 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp605, atslab_0, tmp615) ; break ; } while (0) ; break ; /* branch: __ats_lab_346 */ __ats_lab_346_0: if (((ats_sum_ptr_type)tmp607)->tag != 32) { goto __ats_lab_347_0 ; } __ats_lab_346_1: tmp616 = ats_caselptrlab_mac(anairiats_sum_0, tmp607, atslab_0) ; tmp617 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_var (tmp616) ; tmp605 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp605, atslab_0, tmp617) ; break ; /* branch: __ats_lab_347 */ __ats_lab_347_0: __ats_lab_347_1: /* tmp618 = */ atspre_prerr_string (ATSstrcst("warning(3): s3aexp_make_s2exp: s2e0 = ")) ; /* tmp619 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp606) ; /* tmp620 = */ atspre_prerr_newline () ; tmp605 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp605) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_make_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 41082(line=1205, offs=5) -- 41438(line=1217, offs=4) */ ATSstaticdec() ats_bool_type s2exp_synlt_60 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; __ats_lab_s2exp_synlt_60: tmp622 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp623 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp622), atslab_s2exp_node) ; do { /* branch: __ats_lab_348 */ __ats_lab_348_0: if (((ats_sum_ptr_type)tmp623)->tag != 0) { goto __ats_lab_349_0 ; } __ats_lab_348_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_1, tmp623, atslab_1) ; tmp621 = s2explst_synlte_62 (arg0, tmp624) ; break ; /* branch: __ats_lab_349 */ __ats_lab_349_0: __ats_lab_349_1: tmp621 = ats_false_bool ; break ; } while (0) ; return (tmp621) ; } /* end of [s2exp_synlt_60] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 41468(line=1219, offs=5) -- 41574(line=1220, offs=59) */ ATSstaticdec() ats_bool_type s2exp_synlte_61 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp625) ; ATSlocal (ats_bool_type, tmp626) ; __ats_lab_s2exp_synlte_61: tmp626 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (arg0, arg1) ; if (tmp626) { tmp625 = ats_true_bool ; } else { tmp625 = s2exp_synlt_60 (arg0, arg1) ; } /* end of [if] */ return (tmp625) ; } /* end of [s2exp_synlte_61] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 41580(line=1222, offs=5) -- 41802(line=1229, offs=4) */ ATSstaticdec() ats_bool_type s2explst_synlte_62 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_bool_type, tmp630) ; __ats_lab_s2explst_synlte_62: do { /* branch: __ats_lab_350 */ __ats_lab_350_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_351_0 ; } __ats_lab_350_1: tmp628 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp629 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp630 = s2exp_synlte_61 (arg0, tmp628) ; if (tmp630) { tmp627 = ats_true_bool ; } else { arg0 = arg0 ; arg1 = tmp629 ; goto __ats_lab_s2explst_synlte_62 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_351 */ __ats_lab_351_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_351_1: tmp627 = ats_false_bool ; break ; } while (0) ; return (tmp627) ; } /* end of [s2explst_synlte_62] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 41923(line=1233, offs=6) -- 42203(line=1242, offs=6) */ ATSstaticdec() ats_ptr_type auxlt_64 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_bool_type, tmp633) ; __ats_lab_auxlt_64: if (arg0) { tmp632 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_int_int_bool (arg1, arg2) ; } else { tmp633 = s2exp_synlt_60 (arg1, arg2) ; if (tmp633) { ats_ptrget_mac(ats_int_type, arg3) = 1 ; tmp632 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_true_bool) ; } else { ats_ptrget_mac(ats_int_type, arg3) = -1 ; tmp632 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; } /* end of [if] */ } /* end of [if] */ return (tmp632) ; } /* end of [auxlt_64] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 42228(line=1244, offs=6) -- 42514(line=1253, offs=6) */ ATSstaticdec() ats_ptr_type auxlte_65 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_bool_type, tmp635) ; __ats_lab_auxlte_65: if (arg0) { tmp634 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_int_int_bool (arg1, arg2) ; } else { tmp635 = s2exp_synlte_61 (arg1, arg2) ; if (tmp635) { ats_ptrget_mac(ats_int_type, arg3) = 1 ; tmp634 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_true_bool) ; } else { ats_ptrget_mac(ats_int_type, arg3) = -1 ; tmp634 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; } /* end of [if] */ } /* end of [if] */ return (tmp634) ; } /* end of [auxlte_65] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 42541(line=1255, offs=7) -- 43439(line=1278, offs=6) */ ATSstaticdec() ats_ptr_type auxlst_66 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_int_type, tmp639) ; ATSlocal (ats_int_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_bool_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_bool_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_bool_type, tmp650) ; ATSlocal (ats_bool_type, tmp651) ; __ats_lab_auxlst_66: do { /* branch: __ats_lab_352 */ __ats_lab_352_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_356_0 ; } __ats_lab_352_1: tmp637 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp638 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; /* ats_int_type tmp639 ; */ tmp639 = 0 ; /* ats_int_type tmp640 ; */ tmp640 = 0 ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp641 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp642 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp644 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp637), atslab_s2exp_srt) ; tmp643 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_int (tmp644) ; tmp645 = auxlt_64 (tmp643, tmp637, tmp641, (&tmp639)) ; tmp646 = auxlte_65 (tmp643, tmp637, tmp641, (&tmp640)) ; do { /* branch: __ats_lab_353 */ __ats_lab_353_0: __ats_lab_353_1: tmp647 = atspre_eq_int_int (tmp639, 0) ; if (!tmp647) { goto __ats_lab_354_1 ; } tmp649 = auxlst_66 (tmp638, tmp642) ; tmp648 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_mul_bool_bool_bool (tmp646, tmp649) ; tmp636 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_add_bool_bool_bool (tmp645, tmp648) ; break ; /* branch: __ats_lab_354 */ __ats_lab_354_0: __ats_lab_354_1: tmp650 = atspre_gt_int_int (tmp639, 0) ; if (!tmp650) { goto __ats_lab_355_1 ; } tmp636 = tmp645 ; break ; /* branch: __ats_lab_355 */ __ats_lab_355_0: __ats_lab_355_1: tmp651 = atspre_gte_int_int (tmp640, 0) ; if (tmp651) { arg0 = tmp638 ; arg1 = tmp642 ; goto __ats_lab_auxlst_66 ; // tail call } else { tmp636 = tmp646 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_356 */ __ats_lab_356_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_356_1: tmp636 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; break ; } while (0) ; return (tmp636) ; } /* end of [auxlst_66] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 41835(line=1231, offs=4) -- 43491(line=1281, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_metlt_reduce_63 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp631) ; __ats_lab_s2exp_metlt_reduce_63: tmp631 = auxlst_66 (arg0, arg1) ; return (tmp631) ; } /* end of [s2exp_metlt_reduce_63] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 43554(line=1285, offs=3) -- 44728(line=1317, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_bool_type, tmp660) ; ATSlocal (ats_bool_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; // ATSlocal_void (tmp671) ; // ATSlocal_void (tmp672) ; // ATSlocal_void (tmp673) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp: tmp653 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp654 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp653), atslab_s2exp_node) ; do { /* branch: __ats_lab_357 */ __ats_lab_357_0: if (((ats_sum_ptr_type)tmp654)->tag != 0) { goto __ats_lab_360_0 ; } __ats_lab_357_1: tmp655 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_0) ; tmp656 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_1) ; tmp657 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp655), atslab_s2exp_node) ; do { /* branch: __ats_lab_358 */ __ats_lab_358_0: if (((ats_sum_ptr_type)tmp657)->tag != 4) { goto __ats_lab_359_0 ; } __ats_lab_358_1: tmp658 = ats_caselptrlab_mac(anairiats_sum_0, tmp657, atslab_0) ; tmp652 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_make_s2cst_s2explst (tmp658, tmp656, arg1, arg2) ; break ; /* branch: __ats_lab_359 */ __ats_lab_359_0: __ats_lab_359_1: tmp652 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_360 */ __ats_lab_360_0: if (((ats_sum_ptr_type)tmp654)->tag != 4) { goto __ats_lab_364_0 ; } __ats_lab_360_1: tmp659 = ats_caselptrlab_mac(anairiats_sum_0, tmp654, atslab_0) ; do { /* branch: __ats_lab_361 */ __ats_lab_361_0: __ats_lab_361_1: tmp660 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool, tmp659) ; if (!tmp660) { goto __ats_lab_362_1 ; } tmp652 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp652, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true) ; break ; /* branch: __ats_lab_362 */ __ats_lab_362_0: __ats_lab_362_1: tmp661 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool, tmp659) ; if (!tmp661) { goto __ats_lab_363_1 ; } tmp652 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp652, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false) ; break ; /* branch: __ats_lab_363 */ __ats_lab_363_0: __ats_lab_363_1: tmp662 = s2cstlst_add_57 (ats_ptrget_mac(ats_ptr_type, arg1), tmp659) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp662 ; tmp663 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_cst (tmp659) ; tmp652 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp652, atslab_0, tmp663) ; break ; } while (0) ; break ; /* branch: __ats_lab_364 */ __ats_lab_364_0: if (((ats_sum_ptr_type)tmp654)->tag != 32) { goto __ats_lab_365_0 ; } __ats_lab_364_1: tmp664 = ats_caselptrlab_mac(anairiats_sum_0, tmp654, atslab_0) ; tmp665 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_var (tmp664) ; tmp652 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp652, atslab_0, tmp665) ; break ; /* branch: __ats_lab_365 */ __ats_lab_365_0: if (((ats_sum_ptr_type)tmp654)->tag != 8) { goto __ats_lab_366_0 ; } __ats_lab_365_1: tmp666 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_0) ; tmp667 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_1) ; tmp652 = aux_equal_55 (tmp666, tmp667, arg1, arg2) ; break ; /* branch: __ats_lab_366 */ __ats_lab_366_0: if (((ats_sum_ptr_type)tmp654)->tag != 16) { goto __ats_lab_367_0 ; } __ats_lab_366_1: tmp668 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_0) ; tmp669 = ats_caselptrlab_mac(anairiats_sum_1, tmp654, atslab_1) ; tmp670 = s2exp_metlt_reduce_63 (tmp668, tmp669) ; arg0 = tmp670 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp ; // tail call break ; /* branch: __ats_lab_367 */ __ats_lab_367_0: __ats_lab_367_1: /* tmp671 = */ atspre_prerr_string (ATSstrcst("warning(3): s3bexp_make_s2exp: s2e0 = ")) ; /* tmp672 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp653) ; /* tmp673 = */ atspre_prerr_newline () ; tmp652 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp652) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 44790(line=1321, offs=3) -- 45042(line=1326, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_h3ypo (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_h3ypo: tmp675 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_h3ypo_node) ; do { /* branch: __ats_lab_368 */ __ats_lab_368_0: if (((ats_sum_ptr_type)tmp675)->tag != 0) { goto __ats_lab_369_0 ; } __ats_lab_368_1: tmp676 = ats_caselptrlab_mac(anairiats_sum_0, tmp675, atslab_0) ; tmp674 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (tmp676, arg1, arg2) ; break ; /* branch: __ats_lab_369 */ __ats_lab_369_0: if (((ats_sum_ptr_type)tmp675)->tag != 1) { goto __ats_lab_370_0 ; } __ats_lab_369_1: tmp677 = ats_caselptrlab_mac(anairiats_sum_1, tmp675, atslab_0) ; tmp678 = ats_caselptrlab_mac(anairiats_sum_1, tmp675, atslab_1) ; tmp679 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_h3ypo_loc) ; tmp674 = aux_bind_56 (tmp679, tmp677, tmp678, arg1, arg2) ; break ; /* branch: __ats_lab_370 */ __ats_lab_370_0: // if (((ats_sum_ptr_type)tmp675)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_370_1: tmp680 = ats_caselptrlab_mac(anairiats_sum_1, tmp675, atslab_0) ; tmp681 = ats_caselptrlab_mac(anairiats_sum_1, tmp675, atslab_1) ; tmp674 = aux_equal_55 (tmp680, tmp681, arg1, arg2) ; break ; } while (0) ; return (tmp674) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_h3ypo] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 45148(line=1334, offs=3) -- 46329(line=1369, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp (ats_ptr_type arg0, ats_ref_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; ATSlocal (ats_char_type, tmp689) ; ATSlocal (ats_int_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; ATSlocal (ats_int_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; // ATSlocal_void (tmp707) ; // ATSlocal_void (tmp708) ; // ATSlocal_void (tmp709) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp: tmp683 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp684 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp683), atslab_s2exp_node) ; do { /* branch: __ats_lab_371 */ __ats_lab_371_0: if (((ats_sum_ptr_type)tmp684)->tag != 0) { goto __ats_lab_374_0 ; } __ats_lab_371_1: tmp685 = ats_caselptrlab_mac(anairiats_sum_1, tmp684, atslab_0) ; tmp686 = ats_caselptrlab_mac(anairiats_sum_1, tmp684, atslab_1) ; tmp687 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp685), atslab_s2exp_node) ; do { /* branch: __ats_lab_372 */ __ats_lab_372_0: if (((ats_sum_ptr_type)tmp687)->tag != 4) { goto __ats_lab_373_0 ; } __ats_lab_372_1: tmp688 = ats_caselptrlab_mac(anairiats_sum_0, tmp687, atslab_0) ; tmp682 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_make_s2cst_s2explst (tmp688, tmp686, arg1, arg2) ; break ; /* branch: __ats_lab_373 */ __ats_lab_373_0: __ats_lab_373_1: tmp682 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_374 */ __ats_lab_374_0: if (((ats_sum_ptr_type)tmp684)->tag != 1) { goto __ats_lab_375_0 ; } __ats_lab_374_1: tmp689 = ats_caselptrlab_mac(anairiats_sum_10, tmp684, atslab_0) ; tmp690 = atspre_int_of_char (tmp689) ; tmp691 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int (tmp690) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp691) ; break ; /* branch: __ats_lab_375 */ __ats_lab_375_0: if (((ats_sum_ptr_type)tmp684)->tag != 4) { goto __ats_lab_376_0 ; } __ats_lab_375_1: tmp692 = ats_caselptrlab_mac(anairiats_sum_0, tmp684, atslab_0) ; tmp693 = s2cstlst_add_57 (ats_ptrget_mac(ats_ptr_type, arg1), tmp692) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp693 ; tmp694 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_cst (tmp692) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp694) ; break ; /* branch: __ats_lab_376 */ __ats_lab_376_0: if (((ats_sum_ptr_type)tmp684)->tag != 12) { goto __ats_lab_377_0 ; } __ats_lab_376_1: tmp695 = ats_caselptrlab_mac(anairiats_sum_4, tmp684, atslab_0) ; tmp696 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_int (tmp695) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp696) ; break ; /* branch: __ats_lab_377 */ __ats_lab_377_0: if (((ats_sum_ptr_type)tmp684)->tag != 13) { goto __ats_lab_378_0 ; } __ats_lab_377_1: tmp697 = ats_caselptrlab_mac(anairiats_sum_0, tmp684, atslab_0) ; tmp698 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_intinf (tmp697) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp698) ; break ; /* branch: __ats_lab_378 */ __ats_lab_378_0: if (((ats_sum_ptr_type)tmp684)->tag != 22) { goto __ats_lab_379_0 ; } __ats_lab_378_1: tmp699 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_int_bool) ; tmp701 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp701, atslab_0, tmp683) ; tmp702 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_7, tmp701), atslab_1) ; tmp703 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp702) = tmp703 ; tmp700 = s2cfdeflst_replace_47 (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_int, tmp699, tmp701, arg1, arg2) ; tmp704 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp700) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp704) ; break ; /* branch: __ats_lab_379 */ __ats_lab_379_0: if (((ats_sum_ptr_type)tmp684)->tag != 32) { goto __ats_lab_380_0 ; } __ats_lab_379_1: tmp705 = ats_caselptrlab_mac(anairiats_sum_0, tmp684, atslab_0) ; tmp706 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_var (tmp705) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp682, atslab_0, tmp706) ; break ; /* branch: __ats_lab_380 */ __ats_lab_380_0: __ats_lab_380_1: /* tmp707 = */ atspre_prerr_string (ATSstrcst("warning(3): s3iexp_make_s2exp: s2e0 = ")) ; /* tmp708 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp683) ; /* tmp709 = */ atspre_prerr_newline () ; tmp682 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp682) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_make_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 46734(line=1384, offs=33) -- 46766(line=1384, offs=65) */ ATSstaticdec() ats_int_type __ats_fun_71 (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp711) ; __ats_lab___ats_fun_71: tmp711 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (arg0, arg1) ; return (tmp711) ; } /* end of [__ats_fun_71] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 46659(line=1383, offs=4) -- 46767(line=1384, offs=66) */ ATSstaticdec() ats_ptr_type s2cst_index_map_make_70 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp710) ; __ats_lab_s2cst_index_map_make_70: tmp710 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&__ats_fun_71) ; return (tmp710) ; } /* end of [s2cst_index_map_make_70] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 46880(line=1388, offs=33) -- 46912(line=1388, offs=65) */ ATSstaticdec() ats_int_type __ats_fun_73 (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp713) ; __ats_lab___ats_fun_73: tmp713 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (arg0, arg1) ; return (tmp713) ; } /* end of [__ats_fun_73] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 46805(line=1387, offs=4) -- 46913(line=1388, offs=66) */ ATSstaticdec() ats_ptr_type s2var_index_map_make_72 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp712) ; __ats_lab_s2var_index_map_make_72: tmp712 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&__ats_fun_73) ; return (tmp712) ; } /* end of [s2var_index_map_make_72] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_0510_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (atsopt_count_type, tmp721) ; ATSlocal (ats_int_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_int_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; __ats_lab_bst_search_0510_atsopt_count_type_2cats_int_type: do { /* branch: __ats_lab_381 */ __ats_lab_381_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_385_0 ; } __ats_lab_381_1: tmp721 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp722 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp723 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_3) ; tmp724 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_4) ; tmp725 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg2) (arg1, tmp721) ; do { /* branch: __ats_lab_382 */ __ats_lab_382_0: if (tmp725 != -1) { goto __ats_lab_383_0 ; } __ats_lab_382_1: tmp726 = ats_ptrget_mac(ats_ptr_type, tmp723) ; arg0 = tmp726 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0510_atsopt_count_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_383 */ __ats_lab_383_0: if (tmp725 != 1) { goto __ats_lab_384_0 ; } __ats_lab_383_1: tmp727 = ats_ptrget_mac(ats_ptr_type, tmp724) ; arg0 = tmp727 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0510_atsopt_count_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_384 */ __ats_lab_384_0: // if (tmp725 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_384_1: tmp720 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp720, atslab_0, tmp722) ; break ; } while (0) ; break ; /* branch: __ats_lab_385 */ __ats_lab_385_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_385_1: tmp720 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp720) ; } /* end of [bst_search_0510_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_04000_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp728) ; __ats_lab_map_search_04000_atsopt_count_type_2cats_int_type: // tmp718 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp719 = &ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp728 = ats_ptrget_mac(ats_ptr_type, tmp719) ; tmp717 = bst_search_0510_atsopt_count_type_2cats_int_type (tmp728, arg1, tmp718) ; return (tmp717) ; } /* end of [map_search_04000_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 46955(line=1393, offs=4) -- 47814(line=1418, offs=4) */ ATSstaticdec() ats_int_type s2cst_index_find_74 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp714) ; ATSlocal (atsopt_count_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_int_type, tmp729) ; ATSlocal (ats_bool_type, tmp730) ; // ATSlocal_void (tmp731) ; // ATSlocal_void (tmp732) ; // ATSlocal_void (tmp733) ; // ATSlocal_void (tmp734) ; // ATSlocal_void (tmp735) ; // ATSlocal_void (tmp736) ; // ATSlocal_void (tmp737) ; // ATSlocal_void (tmp738) ; // ATSlocal_void (tmp739) ; // ATSlocal_void (tmp740) ; __ats_lab_s2cst_index_find_74: tmp715 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp (arg2) ; tmp716 = map_search_04000_atsopt_count_type_2cats_int_type (arg1, tmp715) ; do { /* branch: __ats_lab_386 */ __ats_lab_386_0: if (tmp716 == (ats_sum_ptr_type)0) { goto __ats_lab_387_0 ; } __ats_lab_386_1: tmp729 = ats_caselptrlab_mac(anairiats_sum_12, tmp716, atslab_0) ; ATS_FREE(tmp716) ; tmp730 = atspre_ilt (tmp729, arg3) ; if (tmp730) { tmp714 = tmp729 ; } else { /* tmp731 = */ prerr_loc_interror_1 (arg0) ; /* tmp732 = */ atspre_prerr_string (ATSstrcst(": s2cst_index_find: the static constant [")) ; /* tmp733 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg2) ; /* tmp734 = */ atspre_prerr_string (ATSstrcst("] is associated with an index that is out-of-range.")) ; /* tmp735 = */ atspre_prerr_newline () ; /* tmp714 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_387 */ __ats_lab_387_0: // if (tmp716 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_387_1: /* tmp736 = */ prerr_loc_interror_1 (arg0) ; /* tmp737 = */ atspre_prerr_string (ATSstrcst(": s2cst_index_find: the static constant [")) ; /* tmp738 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (arg2) ; /* tmp739 = */ atspre_prerr_string (ATSstrcst("] is not associated with any index.")) ; /* tmp740 = */ atspre_prerr_newline () ; /* tmp714 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp714) ; } /* end of [s2cst_index_find_74] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 47848(line=1420, offs=4) -- 48707(line=1445, offs=4) */ ATSstaticdec() ats_int_type s2var_index_find_77 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp741) ; ATSlocal (atsopt_count_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_int_type, tmp744) ; ATSlocal (ats_bool_type, tmp745) ; // ATSlocal_void (tmp746) ; // ATSlocal_void (tmp747) ; // ATSlocal_void (tmp748) ; // ATSlocal_void (tmp749) ; // ATSlocal_void (tmp750) ; // ATSlocal_void (tmp751) ; // ATSlocal_void (tmp752) ; // ATSlocal_void (tmp753) ; // ATSlocal_void (tmp754) ; // ATSlocal_void (tmp755) ; __ats_lab_s2var_index_find_77: tmp742 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (arg2) ; tmp743 = map_search_04000_atsopt_count_type_2cats_int_type (arg1, tmp742) ; do { /* branch: __ats_lab_388 */ __ats_lab_388_0: if (tmp743 == (ats_sum_ptr_type)0) { goto __ats_lab_389_0 ; } __ats_lab_388_1: tmp744 = ats_caselptrlab_mac(anairiats_sum_12, tmp743, atslab_0) ; ATS_FREE(tmp743) ; tmp745 = atspre_ilt (tmp744, arg3) ; if (tmp745) { tmp741 = tmp744 ; } else { /* tmp746 = */ prerr_loc_interror_1 (arg0) ; /* tmp747 = */ atspre_prerr_string (ATSstrcst(": s2var_index_find: the static variable [")) ; /* tmp748 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg2) ; /* tmp749 = */ atspre_prerr_string (ATSstrcst("] is associated with an index that is out-of-range.")) ; /* tmp750 = */ atspre_prerr_newline () ; /* tmp741 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_389 */ __ats_lab_389_0: // if (tmp743 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_389_1: /* tmp751 = */ prerr_loc_interror_1 (arg0) ; /* tmp752 = */ atspre_prerr_string (ATSstrcst(": s2var_index_find: the static variable [")) ; /* tmp753 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg2) ; /* tmp754 = */ atspre_prerr_string (ATSstrcst("] is not associated with any index.")) ; /* tmp755 = */ atspre_prerr_newline () ; /* tmp741 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp741) ; } /* end of [s2var_index_find_77] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_0482_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp782) ; ATSlocal (ats_int_type, tmp783) ; __ats_lab_bst_size_0482_atsopt_count_type_2cats_int_type: do { /* branch: __ats_lab_392 */ __ats_lab_392_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_393_0 ; } __ats_lab_392_1: tmp783 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp782 = tmp783 ; break ; /* branch: __ats_lab_393 */ __ats_lab_393_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_393_1: tmp782 = 0 ; break ; } while (0) ; return (tmp782) ; } /* end of [bst_size_0482_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_0487_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (atsopt_count_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_bool_type, tmp773) ; ATSlocal (ats_int_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_int_type, tmp780) ; ATSlocal (ats_int_type, tmp781) ; ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_int_type, tmp786) ; ATSlocal (ats_int_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_int_type, tmp793) ; ATSlocal (ats_int_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_int_type, tmp797) ; ATSlocal (ats_int_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; __ats_lab_bst_insert_atroot_0487_atsopt_count_type_2cats_int_type: do { /* branch: __ats_lab_391 */ __ats_lab_391_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_394_0 ; } __ats_lab_391_1: tmp769 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp770 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp771 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_3) ; tmp772 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_4) ; tmp774 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg3) (arg1, tmp770) ; tmp773 = atspre_ilte (tmp774, 0) ; if (tmp773) { tmp776 = ats_ptrget_mac(ats_ptr_type, tmp771) ; tmp775 = bst_insert_atroot_0487_atsopt_count_type_2cats_int_type (tmp776, arg1, arg2, arg3) ; // if (tmp775 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp777 = &ats_caselptrlab_mac(anairiats_sum_11, tmp775, atslab_0) ; tmp778 = &ats_caselptrlab_mac(anairiats_sum_11, tmp775, atslab_3) ; tmp779 = &ats_caselptrlab_mac(anairiats_sum_11, tmp775, atslab_4) ; tmp780 = ats_ptrget_mac(ats_int_type, tmp769) ; tmp784 = ats_ptrget_mac(ats_ptr_type, tmp778) ; tmp781 = bst_size_0482_atsopt_count_type_2cats_int_type (tmp784) ; tmp785 = ats_ptrget_mac(ats_ptr_type, tmp779) ; ats_ptrget_mac(ats_ptr_type, tmp771) = tmp785 ; tmp786 = atspre_isub (tmp780, tmp781) ; ats_ptrget_mac(ats_int_type, tmp769) = tmp786 ; ats_ptrget_mac(ats_ptr_type, tmp779) = arg0 ; tmp787 = atspre_iadd (tmp780, 1) ; ats_ptrget_mac(ats_int_type, tmp777) = tmp787 ; tmp768 = tmp775 ; } else { tmp789 = ats_ptrget_mac(ats_ptr_type, tmp772) ; tmp788 = bst_insert_atroot_0487_atsopt_count_type_2cats_int_type (tmp789, arg1, arg2, arg3) ; // if (tmp788 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp790 = &ats_caselptrlab_mac(anairiats_sum_11, tmp788, atslab_0) ; tmp791 = &ats_caselptrlab_mac(anairiats_sum_11, tmp788, atslab_3) ; tmp792 = &ats_caselptrlab_mac(anairiats_sum_11, tmp788, atslab_4) ; tmp793 = ats_ptrget_mac(ats_int_type, tmp769) ; tmp795 = ats_ptrget_mac(ats_ptr_type, tmp792) ; tmp794 = bst_size_0482_atsopt_count_type_2cats_int_type (tmp795) ; tmp796 = ats_ptrget_mac(ats_ptr_type, tmp791) ; ats_ptrget_mac(ats_ptr_type, tmp772) = tmp796 ; tmp797 = atspre_isub (tmp793, tmp794) ; ats_ptrget_mac(ats_int_type, tmp769) = tmp797 ; ats_ptrget_mac(ats_ptr_type, tmp791) = arg0 ; tmp798 = atspre_iadd (tmp793, 1) ; ats_ptrget_mac(ats_int_type, tmp790) = tmp798 ; tmp768 = tmp788 ; } /* end of [if] */ break ; /* branch: __ats_lab_394 */ __ats_lab_394_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_394_1: tmp799 = (ats_sum_ptr_type)0 ; tmp800 = (ats_sum_ptr_type)0 ; tmp768 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_3, tmp799) ; ats_selptrset_mac(anairiats_sum_11, tmp768, atslab_4, tmp800) ; break ; } while (0) ; return (tmp768) ; } /* end of [bst_insert_atroot_0487_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_0521_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (atsopt_count_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_bool_type, tmp766) ; ATSlocal (ats_int_type, tmp767) ; ATSlocal (ats_bool_type, tmp801) ; ATSlocal (ats_int_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_int_type, tmp805) ; ATSlocal (ats_int_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_int_type, tmp809) ; ATSlocal (ats_int_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; __ats_lab_bst_insert_random_0521_atsopt_count_type_2cats_int_type: do { /* branch: __ats_lab_390 */ __ats_lab_390_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_395_0 ; } __ats_lab_390_1: tmp762 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp763 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp764 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_3) ; tmp765 = &ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_4) ; tmp767 = ats_ptrget_mac(ats_int_type, tmp762) ; tmp766 = atsopt_map_lin_dice (1, tmp767) ; if (tmp766) { tmp761 = bst_insert_atroot_0487_atsopt_count_type_2cats_int_type (arg0, arg1, arg2, arg3) ; } else { tmp802 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg3) (arg1, tmp763) ; tmp801 = atspre_ilte (tmp802, 0) ; if (tmp801) { tmp804 = ats_ptrget_mac(ats_ptr_type, tmp764) ; tmp803 = bst_insert_random_0521_atsopt_count_type_2cats_int_type (tmp804, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp764) = tmp803 ; tmp806 = ats_ptrget_mac(ats_int_type, tmp762) ; tmp805 = atspre_iadd (tmp806, 1) ; ats_ptrget_mac(ats_int_type, tmp762) = tmp805 ; tmp761 = arg0 ; } else { tmp808 = ats_ptrget_mac(ats_ptr_type, tmp765) ; tmp807 = bst_insert_random_0521_atsopt_count_type_2cats_int_type (tmp808, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp765) = tmp807 ; tmp810 = ats_ptrget_mac(ats_int_type, tmp762) ; tmp809 = atspre_iadd (tmp810, 1) ; ats_ptrget_mac(ats_int_type, tmp762) = tmp809 ; tmp761 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_395 */ __ats_lab_395_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_395_1: tmp811 = (ats_sum_ptr_type)0 ; tmp812 = (ats_sum_ptr_type)0 ; tmp761 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp761, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_11, tmp761, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_11, tmp761, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_11, tmp761, atslab_3, tmp811) ; ats_selptrset_mac(anairiats_sum_11, tmp761, atslab_4, tmp812) ; break ; } while (0) ; return (tmp761) ; } /* end of [bst_insert_random_0521_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_03998_atsopt_count_type_2cats_int_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp813) ; __ats_lab_map_insert_03998_atsopt_count_type_2cats_int_type: // tmp758 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp759 = &ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp813 = ats_ptrget_mac(ats_ptr_type, tmp759) ; tmp760 = bst_insert_random_0521_atsopt_count_type_2cats_int_type (tmp813, arg1, arg2, tmp758) ; ats_ptrget_mac(ats_ptr_type, tmp759) = tmp760 ; return /* (tmp757) */ ; } /* end of [map_insert_03998_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 48745(line=1449, offs=4) -- 48867(line=1451, offs=48) */ ATSstaticdec() ats_void_type s2cst_index_insert_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp756) ; ATSlocal (atsopt_count_type, tmp814) ; __ats_lab_s2cst_index_insert_78: tmp814 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_stamp (arg1) ; /* tmp756 = */ map_insert_03998_atsopt_count_type_2cats_int_type (arg0, tmp814, arg2) ; return /* (tmp756) */ ; } /* end of [s2cst_index_insert_78] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 48872(line=1453, offs=4) -- 48994(line=1455, offs=48) */ ATSstaticdec() ats_void_type s2var_index_insert_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp815) ; ATSlocal (atsopt_count_type, tmp816) ; __ats_lab_s2var_index_insert_83: tmp816 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (arg1) ; /* tmp815 = */ map_insert_03998_atsopt_count_type_2cats_int_type (arg0, tmp816, arg2) ; return /* (tmp815) */ ; } /* end of [s2var_index_insert_83] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 49989(line=1506, offs=3) -- 51041(line=1536, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ptr_type arg6, ats_ref_type arg7) { /* local vardec */ // ATSlocal_void (tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_int_type, tmp819) ; ATSlocal (ats_int_type, tmp820) ; ATSlocal (ats_int_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_int_type, tmp823) ; ATSlocal (ats_int_type, tmp824) ; ATSlocal (ats_int_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; // ATSlocal_void (tmp828) ; // ATSlocal_void (tmp829) ; // ATSlocal_void (tmp830) ; // ATSlocal_void (tmp831) ; // ATSlocal_void (tmp832) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err: do { /* branch: __ats_lab_396 */ __ats_lab_396_0: if (((ats_sum_ptr_type)arg6)->tag != 0) { goto __ats_lab_397_0 ; } __ats_lab_396_1: tmp818 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp819 = s2cst_index_find_74 (arg0, arg1, tmp818, arg4) ; tmp821 = ats_caselptrind_mac(ats_int_type, arg3, [tmp819]) ; tmp820 = atsopt_solver_fm_add_i0nt_i0nt (tmp821, arg5) ; ats_caselptrind_mac(ats_int_type, arg3, [tmp819]) = tmp820 ; break ; /* branch: __ats_lab_397 */ __ats_lab_397_0: if (((ats_sum_ptr_type)arg6)->tag != 2) { goto __ats_lab_398_0 ; } __ats_lab_397_1: tmp822 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp823 = s2var_index_find_77 (arg0, arg2, tmp822, arg4) ; tmp825 = ats_caselptrind_mac(ats_int_type, arg3, [tmp823]) ; tmp824 = atsopt_solver_fm_add_i0nt_i0nt (tmp825, arg5) ; ats_caselptrind_mac(ats_int_type, arg3, [tmp823]) = tmp824 ; break ; /* branch: __ats_lab_398 */ __ats_lab_398_0: if (((ats_sum_ptr_type)arg6)->tag != 3) { goto __ats_lab_399_0 ; } __ats_lab_398_1: break ; /* branch: __ats_lab_399 */ __ats_lab_399_0: if (((ats_sum_ptr_type)arg6)->tag != 4) { goto __ats_lab_400_0 ; } __ats_lab_399_1: tmp826 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp827 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; /* tmp828 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, arg5, tmp826, arg7) ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, arg5, tmp827, arg7) ; break ; /* branch: __ats_lab_400 */ __ats_lab_400_0: // if (((ats_sum_ptr_type)arg6)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_400_1: /* tmp829 = */ prerr_interror_0 () ; /* tmp830 = */ atspre_prerr_string (ATSstrcst(": s3aexp_intvec_update_err: unsupported term: s3ae0 = ")) ; /* tmp831 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3aexp (arg6) ; /* tmp832 = */ atspre_prerr_newline () ; /* tmp817 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp817) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 51121(line=1542, offs=3) -- 54270(line=1616, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_int_type arg5, ats_ptr_type arg6, ats_ref_type arg7) { /* local vardec */ // ATSlocal_void (tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_int_type, tmp835) ; ATSlocal (ats_int_type, tmp836) ; ATSlocal (ats_int_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_int_type, tmp839) ; ATSlocal (ats_int_type, tmp840) ; ATSlocal (ats_int_type, tmp841) ; ATSlocal (ats_int_type, tmp842) ; ATSlocal (ats_int_type, tmp843) ; ATSlocal (ats_int_type, tmp844) ; ATSlocal (ats_int_type, tmp845) ; ATSlocal (ats_int_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_int_type, tmp848) ; ATSlocal (ats_int_type, tmp849) ; ATSlocal (ats_int_type, tmp850) ; ATSlocal (ats_int_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_int_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; // ATSlocal_void (tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; // ATSlocal_void (tmp859) ; ATSlocal (ats_int_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_int_type, tmp863) ; ATSlocal (ats_int_type, tmp864) ; ATSlocal (ats_int_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_int_type, tmp867) ; ATSlocal (ats_int_type, tmp868) ; ATSlocal (ats_int_type, tmp869) ; ATSlocal (ats_int_type, tmp870) ; ATSlocal (ats_int_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_int_type, tmp873) ; ATSlocal (ats_int_type, tmp874) ; // ATSlocal_void (tmp875) ; // ATSlocal_void (tmp876) ; // ATSlocal_void (tmp877) ; // ATSlocal_void (tmp878) ; // ATSlocal_void (tmp879) ; // ATSlocal_void (tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; // ATSlocal_void (tmp883) ; ATSlocal (ats_int_type, tmp884) ; // ATSlocal_void (tmp885) ; // ATSlocal_void (tmp886) ; // ATSlocal_void (tmp887) ; // ATSlocal_void (tmp888) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err: do { /* branch: __ats_lab_401 */ __ats_lab_401_0: if (((ats_sum_ptr_type)arg6)->tag != 0) { goto __ats_lab_402_0 ; } __ats_lab_401_1: tmp834 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp835 = s2cst_index_find_74 (arg0, arg1, tmp834, arg4) ; tmp837 = ats_caselptrind_mac(ats_int_type, arg3, [tmp835]) ; tmp836 = atsopt_solver_fm_add_i0nt_i0nt (tmp837, arg5) ; ats_caselptrind_mac(ats_int_type, arg3, [tmp835]) = tmp836 ; break ; /* branch: __ats_lab_402 */ __ats_lab_402_0: if (((ats_sum_ptr_type)arg6)->tag != 4) { goto __ats_lab_403_0 ; } __ats_lab_402_1: tmp838 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp839 = s2var_index_find_77 (arg0, arg2, tmp838, arg4) ; tmp841 = ats_caselptrind_mac(ats_int_type, arg3, [tmp839]) ; tmp840 = atsopt_solver_fm_add_i0nt_i0nt (tmp841, arg5) ; ats_caselptrind_mac(ats_int_type, arg3, [tmp839]) = tmp840 ; break ; /* branch: __ats_lab_403 */ __ats_lab_403_0: if (((ats_sum_ptr_type)arg6)->tag != 2) { goto __ats_lab_404_0 ; } __ats_lab_403_1: tmp842 = ats_caselptrlab_mac(anairiats_sum_4, arg6, atslab_0) ; tmp843 = atsopt_solver_fm_i0nt_of_int (tmp842) ; tmp845 = ats_caselptrind_mac(ats_int_type, arg3, [0]) ; tmp846 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp843) ; tmp844 = atsopt_solver_fm_add_i0nt_i0nt (tmp845, tmp846) ; ats_caselptrind_mac(ats_int_type, arg3, [0]) = tmp844 ; break ; /* branch: __ats_lab_404 */ __ats_lab_404_0: if (((ats_sum_ptr_type)arg6)->tag != 3) { goto __ats_lab_405_0 ; } __ats_lab_404_1: tmp847 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp848 = atsopt_solver_fm_i0nt_of_intinf (tmp847) ; tmp850 = ats_caselptrind_mac(ats_int_type, arg3, [0]) ; tmp851 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp848) ; tmp849 = atsopt_solver_fm_add_i0nt_i0nt (tmp850, tmp851) ; ats_caselptrind_mac(ats_int_type, arg3, [0]) = tmp849 ; break ; /* branch: __ats_lab_405 */ __ats_lab_405_0: if (((ats_sum_ptr_type)arg6)->tag != 5) { goto __ats_lab_406_0 ; } __ats_lab_405_1: tmp852 = ats_caselptrlab_mac(anairiats_sum_0, arg6, atslab_0) ; tmp853 = atsopt_solver_fm_neg_i0nt (arg5) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp853 ; arg6 = tmp852 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_406 */ __ats_lab_406_0: if (((ats_sum_ptr_type)arg6)->tag != 6) { goto __ats_lab_407_0 ; } __ats_lab_406_1: tmp854 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp855 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; /* tmp856 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, arg5, tmp854, arg7) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = arg5 ; arg6 = tmp855 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_407 */ __ats_lab_407_0: if (((ats_sum_ptr_type)arg6)->tag != 7) { goto __ats_lab_408_0 ; } __ats_lab_407_1: tmp857 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp858 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; /* tmp859 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, arg5, tmp857, arg7) ; tmp860 = atsopt_solver_fm_neg_i0nt (arg5) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp860 ; arg6 = tmp858 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_408 */ __ats_lab_408_0: if (((ats_sum_ptr_type)arg6)->tag != 8) { goto __ats_lab_415_0 ; } __ats_lab_408_1: tmp861 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp862 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; do { /* branch: __ats_lab_409 */ __ats_lab_409_0: if (((ats_sum_ptr_type)tmp861)->tag != 2) { goto __ats_lab_410_0 ; } __ats_lab_409_1: tmp863 = ats_caselptrlab_mac(anairiats_sum_4, tmp861, atslab_0) ; tmp865 = atsopt_solver_fm_i0nt_of_int (tmp863) ; tmp864 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp865) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp864 ; arg6 = tmp862 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_410 */ __ats_lab_410_0: if (((ats_sum_ptr_type)tmp861)->tag != 3) { goto __ats_lab_411_0 ; } __ats_lab_410_1: tmp866 = ats_caselptrlab_mac(anairiats_sum_0, tmp861, atslab_0) ; tmp868 = atsopt_solver_fm_i0nt_of_intinf (tmp866) ; tmp867 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp868) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp867 ; arg6 = tmp862 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_411 */ __ats_lab_411_0: __ats_lab_411_1: do { /* branch: __ats_lab_412 */ __ats_lab_412_0: if (((ats_sum_ptr_type)tmp862)->tag != 2) { goto __ats_lab_413_0 ; } __ats_lab_412_1: tmp869 = ats_caselptrlab_mac(anairiats_sum_4, tmp862, atslab_0) ; tmp871 = atsopt_solver_fm_i0nt_of_int (tmp869) ; tmp870 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp871) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp870 ; arg6 = tmp861 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_413 */ __ats_lab_413_0: if (((ats_sum_ptr_type)tmp862)->tag != 3) { goto __ats_lab_414_0 ; } __ats_lab_413_1: tmp872 = ats_caselptrlab_mac(anairiats_sum_0, tmp862, atslab_0) ; tmp874 = atsopt_solver_fm_i0nt_of_intinf (tmp872) ; tmp873 = atsopt_solver_fm_mul_i0nt_i0nt (arg5, tmp874) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp873 ; arg6 = tmp861 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err ; // tail call break ; /* branch: __ats_lab_414 */ __ats_lab_414_0: __ats_lab_414_1: /* tmp875 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp876 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp877 = */ atspre_prerr_string (ATSstrcst(": it is not allowed to have a nonlinear term appear in a constraint: [")) ; /* tmp878 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp (arg6) ; /* tmp879 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp880 = */ atspre_prerr_newline () ; /* tmp833 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_415 */ __ats_lab_415_0: if (((ats_sum_ptr_type)arg6)->tag != 9) { goto __ats_lab_416_0 ; } __ats_lab_415_1: tmp881 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_0) ; tmp882 = ats_caselptrlab_mac(anairiats_sum_1, arg6, atslab_1) ; /* tmp883 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, arg5, tmp881, arg7) ; tmp884 = atsopt_solver_fm_neg_i0nt (arg5) ; /* tmp833 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3aexp_intvec_update_err (arg0, arg1, arg2, arg3, arg4, tmp884, tmp882, arg7) ; break ; /* branch: __ats_lab_416 */ __ats_lab_416_0: // if (((ats_sum_ptr_type)arg6)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_416_1: /* tmp885 = */ prerr_interror_0 () ; /* tmp886 = */ atspre_prerr_string (ATSstrcst(": s3iexp_intvec_update_err: unsupported term: s3ie0 = ")) ; /* tmp887 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3iexp (arg6) ; /* tmp888 = */ atspre_prerr_newline () ; /* tmp833 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp833) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 54605(line=1633, offs=3) -- 56804(line=1690, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ref_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_bool_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; ATSlocal (ats_int_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_int_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; ATSlocal (ats_ptr_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_int_type, tmp919) ; ATSlocal (ats_ptr_type, tmp920) ; ATSlocal (ats_ptr_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; // ATSlocal_void (tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; // ATSlocal_void (tmp925) ; // ATSlocal_void (tmp926) ; // ATSlocal_void (tmp927) ; // ATSlocal_void (tmp928) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err: do { /* branch: __ats_lab_417 */ __ats_lab_417_0: if (((ats_sum_ptr_type)arg4)->tag != 3) { goto __ats_lab_418_0 ; } __ats_lab_417_1: tmp890 = ats_caselptrlab_mac(anairiats_sum_2, arg4, atslab_0) ; if (tmp890) { tmp891 = (ats_sum_ptr_type)0 ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp891) ; } else { tmp892 = (ats_sum_ptr_type)0 ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp892) ; } /* end of [if] */ break ; /* branch: __ats_lab_418 */ __ats_lab_418_0: if (((ats_sum_ptr_type)arg4)->tag != 0) { goto __ats_lab_419_0 ; } __ats_lab_418_1: tmp893 = ats_caselptrlab_mac(anairiats_sum_0, arg4, atslab_0) ; tmp894 = s2cst_index_find_74 (arg0, arg1, tmp893, arg3) ; tmp895 = atsopt_solver_fm_intvec_ptr_make (arg3) ; tmp896 = ats_selsin_mac(tmp895, atslab_2) ; ats_caselptrind_mac(ats_int_type, tmp896, [tmp894]) = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1 ; ats_caselptrind_mac(ats_int_type, tmp896, [0]) = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1 ; tmp897 = atsopt_solver_fm_intvecptr_make_view_ptr (tmp896) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 2) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp897) ; break ; /* branch: __ats_lab_419 */ __ats_lab_419_0: if (((ats_sum_ptr_type)arg4)->tag != 2) { goto __ats_lab_420_0 ; } __ats_lab_419_1: tmp898 = ats_caselptrlab_mac(anairiats_sum_0, arg4, atslab_0) ; tmp899 = s2var_index_find_77 (arg0, arg2, tmp898, arg3) ; tmp900 = atsopt_solver_fm_intvec_ptr_make (arg3) ; tmp901 = ats_selsin_mac(tmp900, atslab_2) ; ats_caselptrind_mac(ats_int_type, tmp901, [tmp899]) = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1 ; ats_caselptrind_mac(ats_int_type, tmp901, [0]) = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_neg_1 ; tmp902 = atsopt_solver_fm_intvecptr_make_view_ptr (tmp901) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 2) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp902) ; break ; /* branch: __ats_lab_420 */ __ats_lab_420_0: if (((ats_sum_ptr_type)arg4)->tag != 6) { goto __ats_lab_421_0 ; } __ats_lab_420_1: tmp903 = ats_caselptrlab_mac(anairiats_sum_0, arg4, atslab_0) ; tmp904 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp903, arg5) ; tmp889 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate (tmp904) ; break ; /* branch: __ats_lab_421 */ __ats_lab_421_0: if (((ats_sum_ptr_type)arg4)->tag != 4) { goto __ats_lab_422_0 ; } __ats_lab_421_1: tmp905 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp906 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; tmp907 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp905, arg5) ; tmp908 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp906, arg5) ; tmp911 = (ats_sum_ptr_type)0 ; tmp910 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp910, atslab_0, tmp908) ; ats_selptrset_mac(anairiats_sum_7, tmp910, atslab_1, tmp911) ; tmp909 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp909, atslab_0, tmp907) ; ats_selptrset_mac(anairiats_sum_7, tmp909, atslab_1, tmp910) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp909) ; break ; /* branch: __ats_lab_422 */ __ats_lab_422_0: if (((ats_sum_ptr_type)arg4)->tag != 5) { goto __ats_lab_423_0 ; } __ats_lab_422_1: tmp912 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp913 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; tmp914 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp912, arg5) ; tmp915 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp913, arg5) ; tmp918 = (ats_sum_ptr_type)0 ; tmp917 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp917, atslab_0, tmp915) ; ats_selptrset_mac(anairiats_sum_7, tmp917, atslab_1, tmp918) ; tmp916 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp916, atslab_0, tmp914) ; ats_selptrset_mac(anairiats_sum_7, tmp916, atslab_1, tmp917) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp916) ; break ; /* branch: __ats_lab_423 */ __ats_lab_423_0: if (((ats_sum_ptr_type)arg4)->tag != 7) { goto __ats_lab_424_0 ; } __ats_lab_423_1: tmp919 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp920 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_1) ; tmp921 = atsopt_solver_fm_intvec_ptr_make (arg3) ; tmp922 = ats_selsin_mac(tmp921, atslab_2) ; /* tmp923 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3iexp_intvec_update_err (arg0, arg1, arg2, tmp922, arg3, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__i0nt_1, tmp920, arg5) ; tmp924 = atsopt_solver_fm_intvecptr_make_view_ptr (tmp922) ; tmp889 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp889)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_0, tmp919) ; ats_selptrset_mac(anairiats_sum_3, tmp889, atslab_1, tmp924) ; break ; /* branch: __ats_lab_424 */ __ats_lab_424_0: // if (((ats_sum_ptr_type)arg4)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_424_1: /* tmp925 = */ prerr_interror_0 () ; /* tmp926 = */ atspre_prerr_string (ATSstrcst(": s3bexp_intvec_make_err: unsupported term: s3be0 = ")) ; /* tmp927 = */ ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__prerr_s3bexp (arg4) ; /* tmp928 = */ atspre_prerr_newline () ; /* tmp889 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp889) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 57652(line=1720, offs=9) -- 58232(line=1734, offs=40) */ ATSstaticdec() ats_void_type aux_88 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; __ats_lab_aux_88: do { /* branch: __ats_lab_425 */ __ats_lab_425_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_428_0 ; } __ats_lab_425_1: tmp933 = &ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_3) ; tmp934 = &ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_4) ; tmp936 = ats_ptrget_mac(ats_ptr_type, tmp933) ; do { /* branch: __ats_lab_426 */ __ats_lab_426_0: if (tmp936 == (ats_sum_ptr_type)0) { goto __ats_lab_427_0 ; } __ats_lab_426_1: tmp937 = ats_caselptrlab_mac(anairiats_sum_6, tmp936, atslab_0) ; tmp938 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp938, atslab_0, tmp937) ; ats_selptrset_mac(anairiats_sum_7, tmp938, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp938 ; break ; /* branch: __ats_lab_427 */ __ats_lab_427_0: // if (tmp936 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_427_1: break ; } while (0) ; tmp939 = ats_ptrget_mac(ats_ptr_type, tmp934) ; arg0 = arg0 ; arg1 = tmp939 ; goto __ats_lab_aux_88 ; // tail call break ; /* branch: __ats_lab_428 */ __ats_lab_428_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_429_0 ; } __ats_lab_428_1: tmp940 = &ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp941 = ats_ptrget_mac(ats_ptr_type, tmp940) ; arg0 = arg0 ; arg1 = tmp941 ; goto __ats_lab_aux_88 ; // tail call break ; /* branch: __ats_lab_429 */ __ats_lab_429_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_429_1: break ; } while (0) ; return /* (tmp932) */ ; } /* end of [aux_88] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 58836(line=1753, offs=9) -- 59102(line=1760, offs=29) */ ATSstaticdec() ats_void_type aux_89 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; // ATSlocal_void (tmp956) ; ATSlocal (ats_int_type, tmp957) ; __ats_lab_aux_89: do { /* branch: __ats_lab_432 */ __ats_lab_432_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_433_0 ; } __ats_lab_432_1: tmp954 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp955 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_1) ; /* tmp956 = */ s2cst_index_insert_78 (arg0, tmp954, ats_ptrget_mac(ats_int_type, arg1)) ; tmp957 = atspre_iadd (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp957 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp955 ; goto __ats_lab_aux_89 ; // tail call break ; /* branch: __ats_lab_433 */ __ats_lab_433_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_433_1: break ; } while (0) ; return /* (tmp953) */ ; } /* end of [aux_89] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 59212(line=1765, offs=9) -- 59472(line=1772, offs=26) */ ATSstaticdec() ats_void_type aux_90 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; // ATSlocal_void (tmp963) ; ATSlocal (ats_int_type, tmp964) ; __ats_lab_aux_90: do { /* branch: __ats_lab_434 */ __ats_lab_434_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_435_0 ; } __ats_lab_434_1: tmp961 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp962 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_1) ; /* tmp963 = */ s2var_index_insert_83 (arg0, tmp961, ats_ptrget_mac(ats_int_type, arg1)) ; tmp964 = atspre_iadd (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp964 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp962 ; goto __ats_lab_aux_90 ; // tail call break ; /* branch: __ats_lab_435 */ __ats_lab_435_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_435_1: break ; } while (0) ; return /* (tmp960) */ ; } /* end of [aux_90] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 59545(line=1776, offs=9) -- 59967(line=1786, offs=40) */ ATSstaticdec() ats_void_type aux_91 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; // ATSlocal_void (tmp969) ; ATSlocal (ats_int_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; __ats_lab_aux_91: do { /* branch: __ats_lab_436 */ __ats_lab_436_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_437_0 ; } __ats_lab_436_1: tmp967 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_2) ; tmp968 = &ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_4) ; /* tmp969 = */ s2var_index_insert_83 (arg0, tmp967, ats_ptrget_mac(ats_int_type, arg1)) ; tmp970 = atspre_iadd (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp970 ; tmp971 = ats_ptrget_mac(ats_ptr_type, tmp968) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp971 ; goto __ats_lab_aux_91 ; // tail call break ; /* branch: __ats_lab_437 */ __ats_lab_437_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_438_0 ; } __ats_lab_437_1: tmp972 = &ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp973 = ats_ptrget_mac(ats_ptr_type, tmp972) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp973 ; goto __ats_lab_aux_91 ; // tail call break ; /* branch: __ats_lab_438 */ __ats_lab_438_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_438_1: break ; } while (0) ; return /* (tmp966) */ ; } /* end of [aux_91] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 60145(line=1792, offs=9) -- 60729(line=1809, offs=8) */ ATSstaticdec() ats_void_type aux_92 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ref_type arg5, ats_ref_type arg6) { /* local vardec */ // ATSlocal_void (tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; __ats_lab_aux_92: do { /* branch: __ats_lab_439 */ __ats_lab_439_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_440_0 ; } __ats_lab_439_1: tmp977 = ats_caselptrlab_mac(anairiats_sum_7, arg4, atslab_0) ; tmp978 = ats_caselptrlab_mac(anairiats_sum_7, arg4, atslab_1) ; tmp979 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, arg1, arg2, arg3, tmp977, arg6) ; tmp980 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp980, atslab_0, tmp979) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp980 ; // if (ats_ptrget_mac(ats_ptr_type, arg5) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp981 = &ats_caselptrlab_mac(anairiats_sum_7, ats_ptrget_mac(ats_ptr_type, arg5), atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp978 ; arg5 = tmp981 ; arg6 = arg6 ; goto __ats_lab_aux_92 ; // tail call break ; /* branch: __ats_lab_440 */ __ats_lab_440_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_440_1: tmp982 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp982 ; break ; } while (0) ; return /* (tmp976) */ ; } /* end of [aux_92] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_0478_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; ATSlocal (ats_ptr_type, tmp992) ; // ATSlocal_void (tmp993) ; __ats_lab_bst_free_0478_atsopt_count_type_2cats_int_type: do { /* branch: __ats_lab_441 */ __ats_lab_441_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_442_0 ; } __ats_lab_441_1: tmp991 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_3) ; tmp992 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp993 = */ bst_free_0478_atsopt_count_type_2cats_int_type (tmp991) ; arg0 = tmp992 ; goto __ats_lab_bst_free_0478_atsopt_count_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_442 */ __ats_lab_442_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_442_1: break ; } while (0) ; return /* (tmp990) */ ; } /* end of [bst_free_0478_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_03996_atsopt_count_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; __ats_lab_map_free_03996_atsopt_count_type_2cats_int_type: // tmp989 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp988 = */ bst_free_0478_atsopt_count_type_2cats_int_type (tmp989) ; return /* (tmp988) */ ; } /* end of [map_free_03996_atsopt_count_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 57126(line=1708, offs=3) -- 61533(line=1836, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexplst_s2exp_solve_fm (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; // ATSlocal_void (tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; ATSlocal (ats_ptr_type, tmp944) ; // ATSlocal_void (tmp945) ; // ATSlocal_void (tmp946) ; // ATSlocal_void (tmp947) ; // ATSlocal_void (tmp948) ; // ATSlocal_void (tmp949) ; // ATSlocal_void (tmp950) ; ATSlocal (ats_int_type, tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; // ATSlocal_void (tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; // ATSlocal_void (tmp965) ; // ATSlocal_void (tmp974) ; ATSlocal (ats_int_type, tmp975) ; ATSlocal (ats_ptr_type, tmp983) ; // ATSlocal_void (tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; // ATSlocal_void (tmp987) ; // ATSlocal_void (tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_int_type, tmp997) ; // ATSlocal_void (tmp998) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexplst_s2exp_solve_fm: tmp930 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_s2exp (arg3, arg4, arg5) ; /* ats_ptr_type tmp931 ; */ tmp931 = arg2 ; /* tmp942 = */ aux_88 ((&tmp931), ats_ptrget_mac(ats_ptr_type, arg5)) ; do { /* branch: __ats_lab_430 */ __ats_lab_430_0: if (tmp930 == (ats_sum_ptr_type)0) { goto __ats_lab_431_0 ; } __ats_lab_430_1: tmp944 = ats_caselptrlab_mac(anairiats_sum_6, tmp930, atslab_0) ; ATS_FREE(tmp930) ; tmp943 = tmp944 ; break ; /* branch: __ats_lab_431 */ __ats_lab_431_0: // if (tmp930 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_431_1: /* tmp945 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp946 = */ atspre_prerr_string (ATSstrcst(": warning(3)")) ; /* tmp947 = */ atspre_prerr_string (ATSstrcst(": the constraint [")) ; /* tmp948 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg3) ; /* tmp949 = */ atspre_prerr_string (ATSstrcst("] cannot be translated into a form accepted by the constraint solver.")) ; /* tmp950 = */ atspre_prerr_newline () ; tmp943 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false ; break ; } while (0) ; /* ats_int_type tmp951 ; */ tmp951 = 1 ; /* ats_ptr_type tmp952 ; */ tmp952 = s2cst_index_map_make_70 () ; /* tmp958 = */ aux_89 (tmp952, (&tmp951), ats_ptrget_mac(ats_ptr_type, arg4)) ; /* ats_ptr_type tmp959 ; */ tmp959 = s2var_index_map_make_72 () ; /* tmp965 = */ aux_90 (tmp959, (&tmp951), arg1) ; /* tmp974 = */ aux_91 (tmp959, (&tmp951), ats_ptrget_mac(ats_ptr_type, arg5)) ; tmp975 = tmp951 ; /* ats_ptr_type tmp983 ; */ /* tmp984 = */ aux_92 (arg0, tmp952, tmp959, tmp975, tmp931, (&tmp983), arg6) ; tmp985 = tmp983 ; tmp986 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexp_icstr_make_err (arg0, tmp952, tmp959, tmp975, tmp943, arg6) ; /* tmp987 = */ map_free_03996_atsopt_count_type_2cats_int_type (tmp952) ; /* tmp994 = */ map_free_03996_atsopt_count_type_2cats_int_type (tmp959) ; /* ats_ptr_type tmp995 ; */ tmp996 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstr_negate (tmp986) ; tmp995 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp995, atslab_0, tmp996) ; ats_selptrset_mac(anairiats_sum_7, tmp995, atslab_1, tmp985) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_solve ((&tmp995), tmp975) ; /* tmp998 = */ ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__icstrlst_free (tmp995) ; tmp929 = tmp997 ; return (tmp929) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexplst_s2exp_solve_fm] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 62651(line=1895, offs=7) -- 62840(line=1899, offs=24) */ ATSstaticdec() ats_void_type aux_96 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; // ATSlocal_void (tmp1003) ; // ATSlocal_void (tmp1004) ; __ats_lab_aux_96: do { /* branch: __ats_lab_443 */ __ats_lab_443_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_444_0 ; } __ats_lab_443_1: tmp1001 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp1002 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; /* tmp1003 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcst (tmp1001) ; /* tmp1004 = */ atspre_prerr_newline () ; arg0 = tmp1002 ; goto __ats_lab_aux_96 ; // tail call break ; /* branch: __ats_lab_444 */ __ats_lab_444_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_444_1: break ; } while (0) ; return /* (tmp1000) */ ; } /* end of [aux_96] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 62561(line=1893, offs=4) -- 63202(line=1916, offs=4) */ ATSstaticdec() ats_void_type pattern_match_exhaustiveness_msg_95 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp999) ; // ATSlocal_void (tmp1005) ; // ATSlocal_void (tmp1006) ; // ATSlocal_void (tmp1007) ; // ATSlocal_void (tmp1008) ; // ATSlocal_void (tmp1009) ; // ATSlocal_void (tmp1010) ; __ats_lab_pattern_match_exhaustiveness_msg_95: do { /* branch: __ats_lab_445 */ __ats_lab_445_0: if (arg1 != 0) { goto __ats_lab_446_0 ; } __ats_lab_445_1: /* tmp1005 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1006 = */ atspre_prerr_string (ATSstrcst(": warning(3)")) ; /* tmp1007 = */ atspre_prerr_string (ATSstrcst(": pattern match is nonexhaustive:\n")) ; /* tmp999 = */ aux_96 (arg2) ; break ; /* branch: __ats_lab_446 */ __ats_lab_446_0: if (arg1 != 1) { goto __ats_lab_447_0 ; } __ats_lab_446_1: /* tmp1008 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1009 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp1010 = */ atspre_prerr_string (ATSstrcst(": pattern match is nonexhaustive:\n")) ; /* tmp999 = */ aux_96 (arg2) ; break ; /* branch: __ats_lab_447 */ __ats_lab_447_0: __ats_lab_447_1: break ; } while (0) ; return /* (tmp999) */ ; } /* end of [pattern_match_exhaustiveness_msg_95] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 64108(line=1943, offs=6) -- 64237(line=1945, offs=6) */ ATSstaticdec() ats_void_type prerr_c3str_if_98 (ats_uint_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp1020) ; ATSlocal (ats_bool_type, tmp1021) ; // ATSlocal_void (tmp1022) ; __ats_lab_prerr_c3str_if_98: tmp1021 = atspre_gt_uint_uint (arg0, 0U) ; if (tmp1021) { /* empty */ } else { /* tmp1022 = */ atspre_prerr_string (ATSstrcst(": ")) ; /* tmp1020 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_c3str (arg1) ; } /* end of [if] */ return /* (tmp1020) */ ; } /* end of [prerr_c3str_if_98] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 63278(line=1920, offs=3) -- 66696(line=2003, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; // ATSlocal_void (tmp1014) ; ATSlocal (ats_int_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; // ATSlocal_void (tmp1019) ; ATSlocal (ats_int_type, tmp1023) ; // ATSlocal_void (tmp1024) ; ATSlocal (ats_bool_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_bool_type, tmp1027) ; // ATSlocal_void (tmp1028) ; // ATSlocal_void (tmp1029) ; // ATSlocal_void (tmp1030) ; // ATSlocal_void (tmp1031) ; // ATSlocal_void (tmp1032) ; // ATSlocal_void (tmp1033) ; // ATSlocal_void (tmp1034) ; // ATSlocal_void (tmp1035) ; // ATSlocal_void (tmp1036) ; // ATSlocal_void (tmp1037) ; // ATSlocal_void (tmp1038) ; // ATSlocal_void (tmp1039) ; ATSlocal (ats_int_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; // ATSlocal_void (tmp1042) ; ATSlocal (ats_bool_type, tmp1043) ; ATSlocal (ats_ptr_type, tmp1044) ; // ATSlocal_void (tmp1045) ; // ATSlocal_void (tmp1046) ; // ATSlocal_void (tmp1047) ; // ATSlocal_void (tmp1048) ; // ATSlocal_void (tmp1049) ; // ATSlocal_void (tmp1050) ; ATSlocal (ats_int_type, tmp1051) ; // ATSlocal_void (tmp1052) ; // ATSlocal_void (tmp1053) ; // ATSlocal_void (tmp1054) ; ATSlocal (ats_bool_type, tmp1055) ; // ATSlocal_void (tmp1056) ; ATSlocal (ats_bool_type, tmp1057) ; // ATSlocal_void (tmp1058) ; ATSlocal (ats_bool_type, tmp1059) ; // ATSlocal_void (tmp1060) ; ATSlocal (ats_bool_type, tmp1062) ; ATSlocal (ats_uint_type, tmp1063) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main: tmp1012 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg2), atslab_c3str_loc) ; tmp1013 = ats_ptrget_mac(ats_ptr_type, arg3) ; /* tmp1014 = */ s2cfdeflst_push_43 (arg4) ; tmp1016 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg2), atslab_c3str_node) ; do { /* branch: __ats_lab_448 */ __ats_lab_448_0: if (((ats_sum_ptr_type)tmp1016)->tag != 0) { goto __ats_lab_449_0 ; } __ats_lab_448_1: tmp1017 = ats_caselptrlab_mac(anairiats_sum_0, tmp1016, atslab_0) ; tmp1015 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_prop (tmp1012, arg0, arg1, tmp1017, arg3, arg4, arg6) ; break ; /* branch: __ats_lab_449 */ __ats_lab_449_0: // if (((ats_sum_ptr_type)tmp1016)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_449_1: tmp1018 = ats_caselptrlab_mac(anairiats_sum_0, tmp1016, atslab_0) ; tmp1015 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (tmp1012, arg0, arg1, tmp1018, arg3, arg4, arg5, arg6) ; break ; } while (0) ; /* tmp1019 = */ s2cfdeflst_pop_41 (arg4) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp1013 ; /* ats_int_type tmp1023 ; */ tmp1023 = tmp1015 ; do { /* branch: __ats_lab_450 */ __ats_lab_450_0: __ats_lab_450_1: tmp1025 = atspre_igte (tmp1023, 0) ; if (!tmp1025) { goto __ats_lab_457_1 ; } tmp1026 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg2), atslab_c3str_kind) ; do { /* branch: __ats_lab_451 */ __ats_lab_451_0: if (((ats_sum_ptr_type)tmp1026)->tag != 0) { goto __ats_lab_452_0 ; } __ats_lab_451_1: tmp1027 = atspre_gt_uint_uint (ats_ptrget_mac(ats_uint_type, arg5), 0U) ; if (tmp1027) { /* empty */ } else { /* tmp1028 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp1012) ; /* tmp1029 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp1030 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint")) ; /* tmp1031 = */ prerr_c3str_if_98 (ats_ptrget_mac(ats_uint_type, arg5), arg2) ; /* tmp1024 = */ atspre_prerr_newline () ; } /* end of [if] */ break ; /* branch: __ats_lab_452 */ __ats_lab_452_0: if (((ats_sum_ptr_type)tmp1026)->tag != 1) { goto __ats_lab_453_0 ; } __ats_lab_452_1: /* tmp1032 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp1012) ; /* tmp1033 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp1034 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for termination metric being welfounded")) ; /* tmp1035 = */ prerr_c3str_if_98 (ats_ptrget_mac(ats_uint_type, arg5), arg2) ; /* tmp1024 = */ atspre_prerr_newline () ; break ; /* branch: __ats_lab_453 */ __ats_lab_453_0: if (((ats_sum_ptr_type)tmp1026)->tag != 2) { goto __ats_lab_454_0 ; } __ats_lab_453_1: /* tmp1036 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp1012) ; /* tmp1037 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp1038 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for termination metric being decreasing")) ; /* tmp1039 = */ prerr_c3str_if_98 (ats_ptrget_mac(ats_uint_type, arg5), arg2) ; /* tmp1024 = */ atspre_prerr_newline () ; break ; /* branch: __ats_lab_454 */ __ats_lab_454_0: if (((ats_sum_ptr_type)tmp1026)->tag != 3) { goto __ats_lab_455_0 ; } __ats_lab_454_1: tmp1040 = ats_caselptrlab_mac(anairiats_sum_3, tmp1026, atslab_0) ; tmp1041 = ats_caselptrlab_mac(anairiats_sum_3, tmp1026, atslab_1) ; /* tmp1042 = */ pattern_match_exhaustiveness_msg_95 (tmp1012, tmp1040, tmp1041) ; tmp1043 = atspre_lte_int_int (tmp1040, 0) ; if (tmp1043) { tmp1023 = -1 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_455 */ __ats_lab_455_0: if (((ats_sum_ptr_type)tmp1026)->tag != 4) { goto __ats_lab_456_0 ; } __ats_lab_455_1: tmp1044 = ats_caselptrlab_mac(anairiats_sum_14, tmp1026, atslab_0) ; /* tmp1045 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp1012) ; /* tmp1046 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp1047 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for the dynamic variable [")) ; /* tmp1048 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp1044) ; /* tmp1049 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp1050 = */ prerr_c3str_if_98 (ats_ptrget_mac(ats_uint_type, arg5), arg2) ; /* tmp1024 = */ atspre_prerr_newline () ; break ; /* branch: __ats_lab_456 */ __ats_lab_456_0: // if (((ats_sum_ptr_type)tmp1026)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_456_1: tmp1051 = ats_caselptrlab_mac(anairiats_sum_4, tmp1026, atslab_0) ; /* tmp1052 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp1012) ; /* tmp1053 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; tmp1055 = atspre_eq_int_int (tmp1051, 0) ; if (tmp1055) { /* tmp1054 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for loop enter")) ; } else { /* empty */ } /* end of [if] */ tmp1057 = atspre_eq_int_int (tmp1051, 1) ; if (tmp1057) { /* tmp1056 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for loop exit")) ; } else { /* empty */ } /* end of [if] */ tmp1059 = atspre_eq_int_int (tmp1051, 2) ; if (tmp1059) { /* tmp1058 = */ atspre_prerr_string (ATSstrcst(": unsolved constraint for loop repeat")) ; } else { /* empty */ } /* end of [if] */ /* tmp1060 = */ prerr_c3str_if_98 (ats_ptrget_mac(ats_uint_type, arg5), arg2) ; /* tmp1024 = */ atspre_prerr_newline () ; break ; } while (0) ; break ; /* branch: __ats_lab_457 */ __ats_lab_457_0: __ats_lab_457_1: break ; } while (0) ; tmp1062 = atspre_igte (tmp1023, 0) ; if (tmp1062) { tmp1063 = atspre_add_uint_uint (ats_ptrget_mac(ats_uint_type, arg5), 1U) ; ats_ptrget_mac(ats_uint_type, arg5) = tmp1063 ; } else { /* empty */ } /* end of [if] */ tmp1011 = tmp1023 ; return (tmp1011) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 66777(line=2009, offs=3) -- 67154(line=2019, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_prop (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp1064) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_prop: tmp1064 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__s3bexplst_s2exp_solve_fm (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return (tmp1064) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 67237(line=2025, offs=3) -- 69907(line=2101, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_ref_type arg7) { /* local vardec */ ATSlocal (ats_int_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_int_type, tmp1069) ; ATSlocal (ats_int_type, tmp1070) ; ATSlocal (ats_bool_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_int_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_int_type, tmp1076) ; ATSlocal (ats_bool_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; // ATSlocal_void (tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_int_type, tmp1084) ; // ATSlocal_void (tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst: do { /* branch: __ats_lab_458 */ __ats_lab_458_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_469_0 ; } __ats_lab_458_1: tmp1066 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_0) ; tmp1067 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_1) ; do { /* branch: __ats_lab_459 */ __ats_lab_459_0: if (((ats_sum_ptr_type)tmp1066)->tag != 0) { goto __ats_lab_460_0 ; } __ats_lab_459_1: tmp1068 = ats_caselptrlab_mac(anairiats_sum_0, tmp1066, atslab_0) ; tmp1069 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main (arg1, arg2, tmp1068, arg4, arg5, arg6, arg7) ; tmp1070 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (arg0, arg1, arg2, tmp1067, arg4, arg5, arg6, arg7) ; tmp1071 = atspre_igte (tmp1069, 0) ; if (tmp1071) { tmp1065 = 0 ; } else { tmp1065 = tmp1070 ; } /* end of [if] */ break ; /* branch: __ats_lab_460 */ __ats_lab_460_0: if (((ats_sum_ptr_type)tmp1066)->tag != 1) { goto __ats_lab_463_0 ; } __ats_lab_460_1: tmp1072 = ats_caselptrlab_mac(anairiats_sum_0, tmp1066, atslab_0) ; tmp1074 = ats_ptrget_mac(ats_ptr_type, tmp1072) ; do { /* branch: __ats_lab_461 */ __ats_lab_461_0: if (tmp1074 == (ats_sum_ptr_type)0) { goto __ats_lab_462_0 ; } __ats_lab_461_1: tmp1075 = ats_caselptrlab_mac(anairiats_sum_6, tmp1074, atslab_0) ; tmp1073 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main (arg1, arg2, tmp1075, arg4, arg5, arg6, arg7) ; break ; /* branch: __ats_lab_462 */ __ats_lab_462_0: // if (tmp1074 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_462_1: tmp1073 = -1 ; break ; } while (0) ; tmp1076 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (arg0, arg1, arg2, tmp1067, arg4, arg5, arg6, arg7) ; tmp1077 = atspre_igte (tmp1073, 0) ; if (tmp1077) { tmp1065 = 0 ; } else { tmp1065 = tmp1076 ; } /* end of [if] */ break ; /* branch: __ats_lab_463 */ __ats_lab_463_0: if (((ats_sum_ptr_type)tmp1066)->tag != 2) { goto __ats_lab_464_0 ; } __ats_lab_463_1: tmp1078 = ats_caselptrlab_mac(anairiats_sum_0, tmp1066, atslab_0) ; tmp1065 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj (arg0, arg1, arg2, tmp1067, tmp1078, arg4, arg5, arg6, arg7) ; break ; /* branch: __ats_lab_464 */ __ats_lab_464_0: if (((ats_sum_ptr_type)tmp1066)->tag != 3) { goto __ats_lab_467_0 ; } __ats_lab_464_1: tmp1079 = ats_caselptrlab_mac(anairiats_sum_0, tmp1066, atslab_0) ; /* tmp1080 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push () ; tmp1082 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_make_h3ypo (tmp1079, arg4, arg5) ; do { /* branch: __ats_lab_465 */ __ats_lab_465_0: if (tmp1082 == (ats_sum_ptr_type)0) { goto __ats_lab_466_0 ; } __ats_lab_465_1: tmp1083 = ats_caselptrlab_mac(anairiats_sum_6, tmp1082, atslab_0) ; ATS_FREE(tmp1082) ; tmp1081 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp1081, atslab_0, tmp1083) ; ats_selptrset_mac(anairiats_sum_7, tmp1081, atslab_1, arg2) ; break ; /* branch: __ats_lab_466 */ __ats_lab_466_0: // if (tmp1082 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_466_1: tmp1081 = arg2 ; break ; } while (0) ; tmp1084 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (arg0, arg1, tmp1081, tmp1067, arg4, arg5, arg6, arg7) ; /* tmp1085 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop () ; tmp1065 = tmp1084 ; break ; /* branch: __ats_lab_467 */ __ats_lab_467_0: if (((ats_sum_ptr_type)tmp1066)->tag != 4) { goto __ats_lab_468_0 ; } __ats_lab_467_1: tmp1086 = ats_caselptrlab_mac(anairiats_sum_0, tmp1066, atslab_0) ; tmp1087 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp1087, atslab_0, tmp1086) ; ats_selptrset_mac(anairiats_sum_7, tmp1087, atslab_1, arg1) ; arg0 = arg0 ; arg1 = tmp1087 ; arg2 = arg2 ; arg3 = tmp1067 ; arg4 = arg4 ; arg5 = arg5 ; arg6 = arg6 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst ; // tail call break ; /* branch: __ats_lab_468 */ __ats_lab_468_0: // if (((ats_sum_ptr_type)tmp1066)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_468_1: arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp1067 ; arg4 = arg4 ; arg5 = arg5 ; arg6 = arg6 ; arg7 = arg7 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_469 */ __ats_lab_469_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_469_1: tmp1065 = -1 ; break ; } while (0) ; return (tmp1065) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 69997(line=2107, offs=3) -- 70628(line=2122, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ref_type arg5, ats_ref_type arg6, ats_ref_type arg7, ats_ref_type arg8) { /* local vardec */ ATSlocal (ats_int_type, tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; ATSlocal (ats_ptr_type, tmp1091) ; // ATSlocal_void (tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_int_type, tmp1094) ; // ATSlocal_void (tmp1095) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj: do { /* branch: __ats_lab_470 */ __ats_lab_470_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_471_0 ; } __ats_lab_470_1: tmp1089 = ats_caselptrlab_mac(anairiats_sum_7, arg4, atslab_0) ; tmp1090 = ats_caselptrlab_mac(anairiats_sum_7, arg4, atslab_1) ; tmp1091 = ats_ptrget_mac(ats_ptr_type, arg5) ; /* tmp1092 = */ s2cfdeflst_push_43 (arg6) ; tmp1093 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp1089, arg3) ; tmp1094 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst (arg0, arg1, arg2, tmp1093, arg5, arg6, arg7, arg8) ; /* tmp1095 = */ s2cfdeflst_pop_41 (arg6) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp1091 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp1090 ; arg5 = arg5 ; arg6 = arg6 ; arg7 = arg7 ; arg8 = arg8 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj ; // tail call break ; /* branch: __ats_lab_471 */ __ats_lab_471_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_471_1: tmp1088 = -1 ; break ; } while (0) ; return (tmp1088) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_itmlst_disj] */ /* // /home/hwxi/research/Anairiats/src/ats_constraint.dats: 70709(line=2127, offs=13) -- 71706(line=2156, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__c3str_solve (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1096) ; // ATSlocal_void (tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; ATSlocal (ats_uint_type, tmp1102) ; ATSlocal (ats_int_type, tmp1103) ; ATSlocal (ats_int_type, tmp1104) ; // ATSlocal_void (tmp1105) ; ATSlocal (ats_bool_type, tmp1106) ; // ATSlocal_void (tmp1107) ; // ATSlocal_void (tmp1108) ; ATSlocal (ats_bool_type, tmp1109) ; // ATSlocal_void (tmp1110) ; ATSlocal (ats_bool_type, tmp1111) ; // ATSlocal_void (tmp1112) ; // ATSlocal_void (tmp1113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__c3str_solve: /* tmp1097 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize () ; tmp1098 = (ats_sum_ptr_type)0 ; tmp1099 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp1100 ; */ tmp1100 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp1101 ; */ tmp1101 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTnil_2) ; /* ats_uint_type tmp1102 ; */ tmp1102 = 0U ; /* ats_int_type tmp1103 ; */ tmp1103 = 0 ; tmp1104 = ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__c3str_solve_main (tmp1098, tmp1099, arg0, (&tmp1100), (&tmp1101), (&tmp1102), (&tmp1103)) ; /* tmp1105 = */ s2cfdeflst_free_40 (tmp1101) ; tmp1106 = atspre_gt_uint_uint (tmp1102, 0U) ; if (tmp1106) { /* tmp1107 = */ atspre_prerr_string (ATSstrcst("type-checking has failed")) ; tmp1109 = atspre_lte_uint_uint (tmp1102, 1U) ; if (tmp1109) { /* tmp1108 = */ atspre_prerr_string (ATSstrcst(": there is one unsolved constraint")) ; } else { /* empty */ } /* end of [if] */ tmp1111 = atspre_gte_uint_uint (tmp1102, 2U) ; if (tmp1111) { /* tmp1110 = */ atspre_prerr_string (ATSstrcst(": there are some unsolved constraints")) ; } else { /* empty */ } /* end of [if] */ /* tmp1112 = */ atspre_prerr_string (ATSstrcst(": please inspect the above reported error message(s) for information.")) ; /* tmp1113 = */ atspre_prerr_newline () ; /* tmp1096 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp1096) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__c3str_solve] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp17, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp18, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp100, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp101, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp102, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEnull_3) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_null, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3aexp_null = statmp3 ; statmp17 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp17)->tag = 3 ; ats_selptrset_mac(anairiats_sum_2, statmp17, atslab_0, ats_true_bool) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_true = statmp17 ; statmp18 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)statmp18)->tag = 3 ; ats_selptrset_mac(anairiats_sum_2, statmp18, atslab_0, ats_false_bool) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3bexp_false = statmp18 ; statmp100 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)statmp100)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, statmp100, atslab_0, 0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_0, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_0 = statmp100 ; statmp101 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)statmp101)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, statmp101, atslab_0, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_1 = statmp101 ; statmp102 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)statmp102)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, statmp102, atslab_0, -1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_neg_1, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__s3iexp_neg_1 = statmp102 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_constraint_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_macro2_dats.c0000664000175000017500000064461612223166160021323 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ #include "ats_intinf.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_11 ; typedef struct { anairiats_rec_0 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_d2sym_loc ; ats_ptr_type atslab_d2sym_qua ; ats_ptr_type atslab_d2sym_sym ; ats_ptr_type atslab_d2sym_itm ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_d0ynq_loc ; ats_ptr_type atslab_d0ynq_node ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_19 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_i2nvarg_var ; ats_ptr_type atslab_i2nvarg_typ ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_m2atch_loc ; ats_ptr_type atslab_m2atch_exp ; ats_ptr_type atslab_m2atch_pat ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_c2lau_loc ; ats_ptr_type atslab_c2lau_pat ; ats_ptr_type atslab_c2lau_gua ; ats_int_type atslab_c2lau_seq ; ats_int_type atslab_c2lau_neg ; ats_ptr_type atslab_c2lau_exp ; } anairiats_rec_25 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_26 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_27 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_28 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_29 ; typedef struct { ats_ptr_type atslab_v2aldec_loc ; ats_ptr_type atslab_v2aldec_pat ; ats_ptr_type atslab_v2aldec_def ; ats_ptr_type atslab_v2aldec_ann ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_d2ec_loc ; ats_ptr_type atslab_d2ec_node ; } anairiats_rec_31 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_32 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_rec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALbool_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALcode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALfloat_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALlst_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALunit_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVmark_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_int_type, atsopt_compare_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_neg_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_add_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_sub_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_mul_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_tostring_intinf) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac) (ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2at) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at) (ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst) (ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labp2atlst) (ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_sym) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2ec) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALbool_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALchar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALcode_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALfloat_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALint_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALlst_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALstring_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALunit_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVmark_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXnil_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_errmac_0 (ats_ptr_type arg0) ; static ats_void_type fprint_v2alue_1 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_3 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type fprint_v2aluelst_2 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type print_v2alue_4 (ats_ptr_type arg0) ; static ats_void_type prerr_v2alue_5 (ats_ptr_type arg0) ; static ats_ptr_type lift_val_exp_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type alphaenv_free_7 (ats_ptr_type arg0) ; static ats_ptr_type alphaenv_add_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_10 (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type alphaenv_find_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type alphaenv_insert_11 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_13 (ats_ptr_type arg0) ; static ats_void_type alphaenv_pop_12 (ats_ref_type arg0) ; static ats_void_type alphaenv_push_14 (ats_ref_type arg0) ; static ats_ptr_type aux_17 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_19 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type aux_21 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type eval0ctx_free_22 (ats_ptr_type arg0) ; static ats_ptr_type eval0ctx_add_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_eval0ctx_24 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type print_eval0ctx_25 (ats_ptr_type arg0) ; static ats_void_type prerr_eval0ctx_26 (ats_ptr_type arg0) ; static ats_bool_type d2sym_is_nonqua_27 (ats_ptr_type arg0) ; static ats_int_type err_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type eval0_exp_app_compare_sgn_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_gt_30 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_gte_31 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_lt_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_lte_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_eq_34 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_neq_35 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_37 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_neg_36 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_39 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_add_38 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_sub_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval0_exp_app_mul_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_45 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_is_nil_44 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_47 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_is_cons_46 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_49 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_tup_head_48 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_51 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_tup_tail_50 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_53 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_eval_52 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval0_exp_app_lift_54 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_56 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxfind_57 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_clo_ptr_type auxfind_57_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type auxfind_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type eval0_var_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exparg_dyn_get_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) ; static ats_bool_type symbol_is_unary_61 (ats_ptr_type arg0) ; static ats_bool_type symbol_is_binary_62 (ats_ptr_type arg0) ; static ats_ptr_type err_64 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type eval1_d2var_65 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval1_d2expopt_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type eval1_d2exparg_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type eval1_d2exparglst_68 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_70 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval1_i2nvresstate_69 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_ptr_type eval1_m2atch_71 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type eval1_m2atchlst_72 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type eval1_c2lau_73 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_75 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_ptr_type eval1_c2laulst_74 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_void_type aux_81 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_ptr_type aux_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_84 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type eval1_v2aldeclst_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_87 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static ats_ptr_type aux_89 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type auxlst_90 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type eval0ctx_extend_arg_88 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_ptr_type eval0ctx_extend_arglst_91 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) ; static ats_ptr_type aux_94 (ats_int_type arg0, ats_ref_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp2) ; ATSstatic (ats_ptr_type, statmp3) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 2234(line=71, offs=4) -- 2323(line=72, offs=52) */ ATSstaticdec() ats_void_type prerr_loc_errmac_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_errmac_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(macro)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_errmac_0] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 2766(line=95, offs=5) -- 3917(line=126, offs=4) */ ATSstaticdec() ats_void_type fprint_v2alue_1 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_bool_type, tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_char_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; __ats_lab_fprint_v2alue_1: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALbool(")) ; /* tmp7 = */ atspre_fprint_bool (arg0, tmp5) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp9 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALchar(")) ; /* tmp10 = */ atspre_fprint_char (arg0, tmp8) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALcode(")) ; /* tmp13 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2exp (arg0, tmp11) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALfloat(")) ; /* tmp16 = */ atspre_fprint_string (arg0, tmp14) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp18 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALint(")) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp17) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALlst(")) ; /* tmp22 = */ fprint_v2aluelst_2 (arg0, tmp20) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp4 = */ atspre_fprintf_exn (arg0, ATSstrcst("V2ALstring(\"%s\", %i)"), tmp23, tmp24) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (((ats_sum_ptr_type)arg1)->tag != 7) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("V2ALunit()")) ; break ; } while (0) ; return /* (tmp4) */ ; } /* end of [fprint_v2alue_1] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 4060(line=131, offs=7) -- 4351(line=138, offs=24) */ ATSstaticdec() ats_void_type loop_3 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; ATSlocal (ats_bool_type, tmp30) ; // ATSlocal_void (tmp31) ; ATSlocal (ats_int_type, tmp32) ; __ats_lab_loop_3: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp27 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp30 = atspre_gt_int_int (arg2, 0) ; if (tmp30) { /* tmp29 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp31 = */ fprint_v2alue_1 (arg0, tmp27) ; tmp32 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp28 ; arg2 = tmp32 ; goto __ats_lab_loop_3 ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp26) */ ; } /* end of [loop_3] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 3949(line=128, offs=5) -- 4420(line=142, offs=4) */ ATSstaticdec() ats_void_type fprint_v2aluelst_2 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp25) ; __ats_lab_fprint_v2aluelst_2: /* tmp25 = */ loop_3 (arg0, arg1, 0) ; return /* (tmp25) */ ; } /* end of [fprint_v2aluelst_2] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 4454(line=144, offs=4) -- 4521(line=144, offs=71) */ ATSstaticdec() ats_void_type print_v2alue_4 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; // ATSlocal_void (tmp36) ; __ats_lab_print_v2alue_4: tmp34 = atspre_stdout_get () ; tmp35 = ats_selsin_mac(tmp34, atslab_1) ; /* tmp36 = */ fprint_v2alue_1 (tmp35, arg0) ; /* tmp33 = */ atspre_stdout_view_set () ; return /* (tmp33) */ ; } /* end of [print_v2alue_4] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 4559(line=147, offs=4) -- 4626(line=147, offs=71) */ ATSstaticdec() ats_void_type prerr_v2alue_5 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; // ATSlocal_void (tmp40) ; __ats_lab_prerr_v2alue_5: tmp38 = atspre_stderr_get () ; tmp39 = ats_selsin_mac(tmp38, atslab_1) ; /* tmp40 = */ fprint_v2alue_1 (tmp39, arg0) ; /* tmp37 = */ atspre_stderr_view_set () ; return /* (tmp37) */ ; } /* end of [prerr_v2alue_5] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 4685(line=152, offs=4) -- 5241(line=168, offs=4) */ ATSstaticdec() ats_ptr_type lift_val_exp_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_char_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_int_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; __ats_lab_lift_val_exp_6: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_char (arg0, tmp42) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp44 = atsopt_tostring_intinf (tmp43) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_int (arg0, tmp44, tmp43) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_float (arg0, tmp45) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_string (arg0, tmp46, tmp47) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp41 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_empty (arg0) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: /* tmp48 = */ prerr_loc_errmac_0 (arg0) ; /* tmp49 = */ atspre_prerr_string (ATSstrcst(": a value representing code (abstract syntax tree) cannot be lifted.")) ; /* tmp50 = */ atspre_prerr_newline () ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp41) ; } /* end of [lift_val_exp_6] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 5434(line=178, offs=5) -- 5616(line=183, offs=4) */ ATSstaticdec() ats_void_type alphaenv_free_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_alphaenv_free_7: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp52 ; goto __ats_lab_alphaenv_free_7 ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; ATS_FREE(arg0) ; arg0 = tmp53 ; goto __ats_lab_alphaenv_free_7 ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; return /* (tmp51) */ ; } /* end of [alphaenv_free_7] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 5647(line=185, offs=4) -- 5775(line=188, offs=51) */ ATSstaticdec() ats_ptr_type alphaenv_add_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (atsopt_count_type, tmp55) ; __ats_lab_alphaenv_add_8: tmp55 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg1) ; tmp54 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp54)->tag = 0 ; ats_selptrset_mac(anairiats_sum_6, tmp54, atslab_0, tmp55) ; ats_selptrset_mac(anairiats_sum_6, tmp54, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp54, atslab_2, arg0) ; return (tmp54) ; } /* end of [alphaenv_add_8] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 5886(line=193, offs=7) -- 6363(line=208, offs=46) */ ATSstaticdec() ats_ptr_type aux_10 (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (atsopt_count_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_bool_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; __ats_lab_aux_10: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp60 = &ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp58, arg1) ; if (tmp61) { tmp57 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp57, atslab_0, tmp59) ; } else { tmp62 = ats_ptrget_mac(ats_ptr_type, tmp60) ; arg0 = tmp62 ; arg1 = arg1 ; goto __ats_lab_aux_10 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp63 = &ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp64 = ats_ptrget_mac(ats_ptr_type, tmp63) ; arg0 = tmp64 ; arg1 = arg1 ; goto __ats_lab_aux_10 ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp57 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp57) ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 5805(line=191, offs=4) -- 6404(line=211, offs=4) */ ATSstaticdec() ats_ptr_type alphaenv_find_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (atsopt_count_type, tmp65) ; __ats_lab_alphaenv_find_9: tmp65 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg1) ; tmp56 = aux_10 (arg0, tmp65) ; return (tmp56) ; } /* end of [alphaenv_find_9] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 6435(line=213, offs=4) -- 6574(line=217, offs=2) */ ATSstaticdec() ats_void_type alphaenv_insert_11 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (atsopt_count_type, tmp68) ; __ats_lab_alphaenv_insert_11: tmp68 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg1) ; tmp67 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp67)->tag = 0 ; ats_selptrset_mac(anairiats_sum_6, tmp67, atslab_0, tmp68) ; ats_selptrset_mac(anairiats_sum_6, tmp67, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp67, atslab_2, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp67 ; return /* (tmp66) */ ; } /* end of [alphaenv_insert_11] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 6656(line=220, offs=7) -- 6818(line=224, offs=40) */ ATSstaticdec() ats_ptr_type aux_13 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_aux_13: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp71 ; goto __ats_lab_aux_13 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp70 = tmp72 ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp70 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; break ; } while (0) ; return (tmp70) ; } /* end of [aux_13] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 6608(line=219, offs=5) -- 6844(line=227, offs=4) */ ATSstaticdec() ats_void_type alphaenv_pop_12 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp73) ; __ats_lab_alphaenv_pop_12: tmp73 = aux_13 (ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp73 ; return /* (tmp69) */ ; } /* end of [alphaenv_pop_12] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 6874(line=229, offs=4) -- 6938(line=229, offs=68) */ ATSstaticdec() ats_void_type alphaenv_push_14 (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_alphaenv_push_14: tmp75 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp75)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp75, atslab_0, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp75 ; return /* (tmp74) */ ; } /* end of [alphaenv_push_14] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 7042(line=235, offs=22) -- 7058(line=235, offs=38) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy: tmp76 = arg1 ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 8237(line=285, offs=13) -- 8717(line=296, offs=39) */ ATSstaticdec() ats_ptr_type aux_17 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (anairiats_rec_0, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (anairiats_rec_0, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (anairiats_rec_0, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_aux_17: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp97 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_1) ; tmp99 = ats_select_mac(tmp96, atslab_0) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (ats_ptrget_mac(ats_ptr_type, arg1), tmp99) ; tmp100 = ats_select_mac(tmp98, atslab_0) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp100 ; tmp101 = ats_select_mac(tmp98, atslab_1) ; tmp103 = ats_select_mac(tmp96, atslab_1) ; tmp102 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (ats_ptrget_mac(ats_ptr_type, arg1), tmp103) ; tmp104.atslab_0 = tmp101 ; tmp104.atslab_1 = tmp102 ; tmp105 = aux_17 (tmp97, arg1) ; tmp95 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp95, atslab_0, tmp104) ; ats_selptrset_mac(anairiats_sum_12, tmp95, atslab_1, tmp105) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp95 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp95) ; } /* end of [aux_17] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 7456(line=257, offs=3) -- 9925(line=336, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_int_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_int_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_int_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_int_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at: tmp78 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg2), atslab_p2at_node) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp78)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_9, tmp78, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_9, tmp78, atslab_1) ; tmp81 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg1, tmp79) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_ann (arg0, tmp81, tmp80) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp78)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_any (arg0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp78)->tag != 2) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_10, tmp78, atslab_0) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_10, tmp78, atslab_1) ; tmp84 = ats_caselptrlab_mac(anairiats_sum_10, tmp78, atslab_2) ; tmp85 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy (arg0, tmp83) ; /* tmp86 = */ alphaenv_insert_11 (arg1, tmp83, tmp85) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg1, tmp84) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_as (arg0, tmp82, tmp85, tmp87) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp78)->tag != 5) { goto __ats_lab_31_0 ; } __ats_lab_28_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_0) ; tmp89 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_1) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_2) ; tmp91 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_3) ; tmp92 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_4) ; tmp93 = ats_caselptrlab_mac(anairiats_sum_11, tmp78, atslab_5) ; /* ats_ptr_type tmp94 ; */ tmp94 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; tmp106 = aux_17 (tmp90, (&tmp94)) ; tmp107 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp94, tmp91) ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (arg0, arg1, tmp93) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_con (arg0, tmp88, tmp89, tmp106, tmp107, tmp92, tmp108) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp78)->tag != 6) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_empty (arg0) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp78)->tag != 7) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp109 = ats_caselptrlab_mac(anairiats_sum_9, tmp78, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_9, tmp78, atslab_1) ; tmp111 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg1, tmp110) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_exist (arg0, tmp109, tmp111) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp78)->tag != 10) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_13, tmp78, atslab_0) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_13, tmp78, atslab_1) ; tmp114 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (arg0, arg1, tmp113) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_list (arg0, tmp112, tmp114) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp78)->tag != 11) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_3, tmp78, atslab_0) ; tmp116 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (arg0, arg1, tmp115) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_lst (arg0, tmp116) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp78)->tag != 12) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_14, tmp78, atslab_0) ; tmp118 = ats_caselptrlab_mac(anairiats_sum_14, tmp78, atslab_1) ; tmp119 = ats_caselptrlab_mac(anairiats_sum_14, tmp78, atslab_2) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labp2atlst (arg0, arg1, tmp119) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_rec (arg0, tmp117, tmp118, tmp120) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp78)->tag != 14) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_13, tmp78, atslab_0) ; tmp122 = ats_caselptrlab_mac(anairiats_sum_13, tmp78, atslab_1) ; tmp123 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__d2var_copy (arg0, tmp122) ; /* tmp124 = */ alphaenv_insert_11 (arg1, tmp122, tmp123) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2at_var (arg0, tmp121, tmp123) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: /* tmp125 = */ atspre_print_string (ATSstrcst("eval1_p2at: p2t0 = ")) ; /* tmp126 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_p2at (arg2) ; /* tmp127 = */ atspre_print_newline () ; tmp77 = arg2 ; break ; } while (0) ; return (tmp77) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 10004(line=340, offs=7) -- 10449(line=355, offs=6) */ ATSstaticdec() ats_void_type aux_19 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_aux_19: do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp130 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp131 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; tmp132 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg1, tmp130) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp133, atslab_0, tmp132) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp133 ; // if (ats_ptrget_mac(ats_ptr_type, arg3) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp134 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg3), atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp131 ; arg3 = tmp134 ; goto __ats_lab_aux_19 ; // tail call break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: tmp135 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp135 ; break ; } while (0) ; return /* (tmp129) */ ; } /* end of [aux_19] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 9974(line=339, offs=15) -- 10543(line=359, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp136) ; // ATSlocal_void (tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst: /* ats_ptr_type tmp136 ; */ /* tmp137 = */ aux_19 (arg0, arg1, arg2, (&tmp136)) ; tmp128 = tmp136 ; return (tmp128) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 10629(line=363, offs=7) -- 11150(line=379, offs=6) */ ATSstaticdec() ats_void_type aux_21 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_aux_21: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp140 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_0) ; tmp141 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_1) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_2) ; tmp143 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg1, tmp141) ; tmp144 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp144)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp144, atslab_0, tmp140) ; ats_selptrset_mac(anairiats_sum_15, tmp144, atslab_1, tmp143) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp144 ; // if (((ats_sum_ptr_type)ats_ptrget_mac(ats_ptr_type, arg3))->tag != 2) { ats_deadcode_failure_handle () ; } tmp145 = &ats_caselptrlab_mac(anairiats_sum_15, ats_ptrget_mac(ats_ptr_type, arg3), atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp142 ; arg3 = tmp145 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp146 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp146 ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (((ats_sum_ptr_type)arg2)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: tmp147 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp147 ; break ; } while (0) ; return /* (tmp139) */ ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 10598(line=362, offs=18) -- 11248(line=383, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labp2atlst (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp148) ; // ATSlocal_void (tmp149) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labp2atlst: /* ats_ptr_type tmp148 ; */ /* tmp149 = */ aux_21 (arg0, arg1, arg2, (&tmp148)) ; tmp138 = tmp148 ; return (tmp138) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labp2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 11414(line=392, offs=5) -- 11553(line=396, offs=4) */ ATSstaticdec() ats_void_type eval0ctx_free_22 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_eval0ctx_free_22: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp151 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp151 ; goto __ats_lab_eval0ctx_free_22 ; // tail call break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: break ; } while (0) ; return /* (tmp150) */ ; } /* end of [eval0ctx_free_22] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 11584(line=398, offs=4) -- 11705(line=401, offs=48) */ ATSstaticdec() ats_ptr_type eval0ctx_add_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (atsopt_count_type, tmp153) ; __ats_lab_eval0ctx_add_23: tmp153 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg1) ; tmp152 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ats_selptrset_mac(anairiats_sum_16, tmp152, atslab_0, tmp153) ; ats_selptrset_mac(anairiats_sum_16, tmp152, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp152, atslab_2, arg0) ; return (tmp152) ; } /* end of [eval0ctx_add_23] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 11757(line=406, offs=5) -- 12214(line=418, offs=4) */ ATSstaticdec() ats_void_type fprint_eval0ctx_24 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp154) ; ATSlocal (atsopt_count_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; // ATSlocal_void (tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_fprint_eval0ctx_24: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_0) ; tmp156 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_1) ; tmp157 = &ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_2) ; /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp155) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst(" -> ")) ; /* tmp160 = */ fprint_v2alue_1 (arg0, tmp156) ; /* tmp161 = */ atspre_fprint_newline (arg0) ; tmp162 = ats_ptrget_mac(ats_ptr_type, tmp157) ; arg0 = arg0 ; arg1 = tmp162 ; goto __ats_lab_fprint_eval0ctx_24 ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: break ; } while (0) ; return /* (tmp154) */ ; } /* end of [fprint_eval0ctx_24] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 12247(line=420, offs=4) -- 12319(line=420, offs=76) */ ATSstaticdec() ats_void_type print_eval0ctx_25 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; // ATSlocal_void (tmp166) ; __ats_lab_print_eval0ctx_25: tmp164 = atspre_stdout_get () ; tmp165 = ats_selsin_mac(tmp164, atslab_1) ; /* tmp166 = */ fprint_eval0ctx_24 (tmp165, arg0) ; /* tmp163 = */ atspre_stdout_view_set () ; return /* (tmp163) */ ; } /* end of [print_eval0ctx_25] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 12359(line=423, offs=4) -- 12431(line=423, offs=76) */ ATSstaticdec() ats_void_type prerr_eval0ctx_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; // ATSlocal_void (tmp170) ; __ats_lab_prerr_eval0ctx_26: tmp168 = atspre_stderr_get () ; tmp169 = ats_selsin_mac(tmp168, atslab_1) ; /* tmp170 = */ fprint_eval0ctx_24 (tmp169, arg0) ; /* tmp167 = */ atspre_stderr_view_set () ; return /* (tmp167) */ ; } /* end of [prerr_eval0ctx_26] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 13074(line=455, offs=4) -- 13208(line=459, offs=4) */ ATSstaticdec() ats_bool_type d2sym_is_nonqua_27 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; __ats_lab_d2sym_is_nonqua_27: tmp172 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_d2sym_qua) ; tmp173 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp172), atslab_d0ynq_node) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp173)->tag != 0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp171 = ats_true_bool ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: __ats_lab_48_1: tmp171 = ats_false_bool ; break ; } while (0) ; return (tmp171) ; } /* end of [d2sym_is_nonqua_27] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 13507(line=475, offs=6) -- 13713(line=480, offs=6) */ ATSstaticdec() ats_int_type err_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp175) ; // ATSlocal_void (tmp176) ; // ATSlocal_void (tmp177) ; // ATSlocal_void (tmp178) ; __ats_lab_err_29: /* tmp176 = */ prerr_loc_errmac_0 (arg0) ; /* tmp177 = */ atspre_prerr_string (ATSstrcst(": values that do not support comparison are compared.")) ; /* tmp178 = */ atspre_prerr_newline () ; /* tmp175 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp175) ; } /* end of [err_29] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 13419(line=473, offs=4) -- 13949(line=488, offs=4) */ ATSstaticdec() ats_int_type eval0_exp_app_compare_sgn_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp174) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; __ats_lab_eval0_exp_app_compare_sgn_28: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp174 = atsopt_compare_intinf_intinf (tmp179, tmp180) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp174 = err_29 (arg0, arg1, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp174 = err_29 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp174) ; } /* end of [eval0_exp_app_compare_sgn_28] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 13988(line=490, offs=4) -- 14188(line=495, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_gt_30 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_int_type, tmp182) ; ATSlocal (ats_bool_type, tmp183) ; __ats_lab_eval0_exp_app_gt_30: tmp182 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp183 = atspre_igt (tmp182, 0) ; if (tmp183) { tmp181 = statmp2 ; } else { tmp181 = statmp3 ; } /* end of [if] */ return (tmp181) ; } /* end of [eval0_exp_app_gt_30] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 14222(line=497, offs=4) -- 14424(line=502, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_gte_31 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_int_type, tmp185) ; ATSlocal (ats_bool_type, tmp186) ; __ats_lab_eval0_exp_app_gte_31: tmp185 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp186 = atspre_igte (tmp185, 0) ; if (tmp186) { tmp184 = statmp2 ; } else { tmp184 = statmp3 ; } /* end of [if] */ return (tmp184) ; } /* end of [eval0_exp_app_gte_31] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 14459(line=504, offs=4) -- 14659(line=509, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_lt_32 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_bool_type, tmp189) ; __ats_lab_eval0_exp_app_lt_32: tmp188 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp189 = atspre_ilt (tmp188, 0) ; if (tmp189) { tmp187 = statmp2 ; } else { tmp187 = statmp3 ; } /* end of [if] */ return (tmp187) ; } /* end of [eval0_exp_app_lt_32] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 14693(line=511, offs=4) -- 14895(line=516, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_lte_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; ATSlocal (ats_bool_type, tmp192) ; __ats_lab_eval0_exp_app_lte_33: tmp191 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp192 = atspre_ilte (tmp191, 0) ; if (tmp192) { tmp190 = statmp2 ; } else { tmp190 = statmp3 ; } /* end of [if] */ return (tmp190) ; } /* end of [eval0_exp_app_lte_33] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 14930(line=518, offs=4) -- 15130(line=523, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_eq_34 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_bool_type, tmp195) ; __ats_lab_eval0_exp_app_eq_34: tmp194 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp195 = atspre_ieq (tmp194, 0) ; if (tmp195) { tmp193 = statmp2 ; } else { tmp193 = statmp3 ; } /* end of [if] */ return (tmp193) ; } /* end of [eval0_exp_app_eq_34] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 15164(line=525, offs=4) -- 15366(line=530, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_neq_35 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_int_type, tmp197) ; ATSlocal (ats_bool_type, tmp198) ; __ats_lab_eval0_exp_app_neq_35: tmp197 = eval0_exp_app_compare_sgn_28 (arg0, arg1, arg2) ; tmp198 = atspre_ineq (tmp197, 0) ; if (tmp198) { tmp196 = statmp2 ; } else { tmp196 = statmp3 ; } /* end of [if] */ return (tmp196) ; } /* end of [eval0_exp_app_neq_35] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 15489(line=536, offs=6) -- 15692(line=541, offs=6) */ ATSstaticdec() ats_ptr_type err_37 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; // ATSlocal_void (tmp203) ; __ats_lab_err_37: /* tmp201 = */ prerr_loc_errmac_0 (arg0) ; /* tmp202 = */ atspre_prerr_string (ATSstrcst(": negation is performed on a value that does not support it.")) ; /* tmp203 = */ atspre_prerr_newline () ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp200) ; } /* end of [err_37] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 15422(line=534, offs=4) -- 15873(line=547, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_neg_36 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_bool_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; __ats_lab_eval0_exp_app_neg_36: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp204 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; if (tmp204) { tmp199 = statmp3 ; } else { tmp199 = statmp2 ; } /* end of [if] */ break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp206 = atsopt_neg_intinf (tmp205) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp199)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp199, atslab_0, tmp206) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp199 = err_37 (arg0, arg1) ; break ; } while (0) ; return (tmp199) ; } /* end of [eval0_exp_app_neg_36] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 15991(line=551, offs=6) -- 16207(line=556, offs=6) */ ATSstaticdec() ats_ptr_type err_39 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; // ATSlocal_void (tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; __ats_lab_err_39: /* tmp209 = */ prerr_loc_errmac_0 (arg0) ; /* tmp210 = */ atspre_prerr_string (ATSstrcst(": addition is performed on values that do not support it.")) ; /* tmp211 = */ atspre_prerr_newline () ; /* tmp208 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp208) ; } /* end of [err_39] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 15908(line=549, offs=4) -- 16449(line=564, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_add_38 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_eval0_exp_app_add_38: do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_59_0 ; } __ats_lab_56_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp214 = atsopt_add_intinf_intinf (tmp212, tmp213) ; tmp207 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp207)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp207, atslab_0, tmp214) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: __ats_lab_58_1: tmp207 = err_39 (arg0, arg1, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp207 = err_39 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp207) ; } /* end of [eval0_exp_app_add_38] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 16567(line=568, offs=6) -- 16786(line=573, offs=6) */ ATSstaticdec() ats_ptr_type err_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; __ats_lab_err_41: /* tmp217 = */ prerr_loc_errmac_0 (arg0) ; /* tmp218 = */ atspre_prerr_string (ATSstrcst(": subtraction is performed on values that do not support it.")) ; /* tmp219 = */ atspre_prerr_newline () ; /* tmp216 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp216) ; } /* end of [err_41] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 16484(line=566, offs=4) -- 17028(line=581, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_sub_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_eval0_exp_app_sub_40: do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_63_0 ; } __ats_lab_60_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp222 = atsopt_sub_intinf_intinf (tmp220, tmp221) ; tmp215 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp215)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp215, atslab_0, tmp222) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: __ats_lab_62_1: tmp215 = err_41 (arg0, arg1, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp215 = err_41 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp215) ; } /* end of [eval0_exp_app_sub_40] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 17146(line=585, offs=6) -- 17368(line=590, offs=6) */ ATSstaticdec() ats_ptr_type err_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; __ats_lab_err_43: /* tmp225 = */ prerr_loc_errmac_0 (arg0) ; /* tmp226 = */ atspre_prerr_string (ATSstrcst(": multiplication is performed on values that do not support it.")) ; /* tmp227 = */ atspre_prerr_newline () ; /* tmp224 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp224) ; } /* end of [err_43] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 17063(line=583, offs=4) -- 17610(line=598, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_mul_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_eval0_exp_app_mul_42: do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_67_0 ; } __ats_lab_64_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp229 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp230 = atsopt_mul_intinf_intinf (tmp228, tmp229) ; tmp223 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp223)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp223, atslab_0, tmp230) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp223 = err_43 (arg0, arg1, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: __ats_lab_67_1: tmp223 = err_43 (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp223) ; } /* end of [eval0_exp_app_mul_42] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 18267(line=622, offs=6) -- 18468(line=627, offs=6) */ ATSstaticdec() ats_ptr_type err_45 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; __ats_lab_err_45: /* tmp233 = */ prerr_loc_errmac_0 (arg0) ; /* tmp234 = */ atspre_prerr_string (ATSstrcst(": [is_nil] is performed on a value that do not support it.")) ; /* tmp235 = */ atspre_prerr_newline () ; /* tmp232 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp232) ; } /* end of [err_45] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 18197(line=620, offs=4) -- 18678(line=634, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_is_nil_44 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp236) ; __ats_lab_eval0_exp_app_is_nil_44: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_71_0 ; } __ats_lab_68_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (tmp236 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp231 = statmp3 ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: // if (tmp236 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_70_1: tmp231 = statmp2 ; break ; } while (0) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp231 = err_45 (arg0, arg1) ; break ; } while (0) ; return (tmp231) ; } /* end of [eval0_exp_app_is_nil_44] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 18787(line=638, offs=6) -- 18989(line=643, offs=6) */ ATSstaticdec() ats_ptr_type err_47 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; __ats_lab_err_47: /* tmp239 = */ prerr_loc_errmac_0 (arg0) ; /* tmp240 = */ atspre_prerr_string (ATSstrcst(": [is_cons] is performed on a value that do not support it.")) ; /* tmp241 = */ atspre_prerr_newline () ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp238) ; } /* end of [err_47] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 18716(line=636, offs=4) -- 19199(line=650, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_is_cons_46 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp242) ; __ats_lab_eval0_exp_app_is_cons_46: do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_75_0 ; } __ats_lab_72_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (tmp242 == (ats_sum_ptr_type)0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp237 = statmp3 ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (tmp242 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: tmp237 = statmp2 ; break ; } while (0) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: tmp237 = err_47 (arg0, arg1) ; break ; } while (0) ; return (tmp237) ; } /* end of [eval0_exp_app_is_cons_46] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 19450(line=661, offs=6) -- 19653(line=666, offs=6) */ ATSstaticdec() ats_ptr_type err_49 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; // ATSlocal_void (tmp247) ; __ats_lab_err_49: /* tmp245 = */ prerr_loc_errmac_0 (arg0) ; /* tmp246 = */ atspre_prerr_string (ATSstrcst(": [tup_head] is performed on a value that do not support it.")) ; /* tmp247 = */ atspre_prerr_newline () ; /* tmp244 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp244) ; } /* end of [err_49] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 19259(line=654, offs=4) -- 20012(line=679, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_tup_head_48 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; __ats_lab_eval0_exp_app_tup_head_48: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_79_0 ; } __ats_lab_76_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (tmp248 == (ats_sum_ptr_type)0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_5, tmp248, atslab_0) ; tmp243 = tmp249 ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: // if (tmp248 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_78_1: tmp243 = err_49 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp243 = err_49 (arg0, arg1) ; break ; } while (0) ; return (tmp243) ; } /* end of [eval0_exp_app_tup_head_48] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 20244(line=687, offs=6) -- 20447(line=692, offs=6) */ ATSstaticdec() ats_ptr_type err_51 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; __ats_lab_err_51: /* tmp252 = */ prerr_loc_errmac_0 (arg0) ; /* tmp253 = */ atspre_prerr_string (ATSstrcst(": [tup_tail] is performed on a value that do not support it.")) ; /* tmp254 = */ atspre_prerr_newline () ; /* tmp251 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp251) ; } /* end of [err_51] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 20055(line=681, offs=4) -- 20845(line=706, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_tup_tail_50 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; __ats_lab_eval0_exp_app_tup_tail_50: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_83_0 ; } __ats_lab_80_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (tmp255 == (ats_sum_ptr_type)0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp256 = ats_caselptrlab_mac(anairiats_sum_5, tmp255, atslab_1) ; tmp250 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp250)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp250, atslab_0, tmp256) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (tmp255 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: tmp250 = err_51 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp250 = err_51 (arg0, arg1) ; break ; } while (0) ; return (tmp250) ; } /* end of [eval0_exp_app_tup_tail_50] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 20977(line=712, offs=6) -- 21179(line=717, offs=6) */ ATSstaticdec() ats_ptr_type err_53 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; __ats_lab_err_53: /* tmp259 = */ prerr_loc_errmac_0 (arg0) ; /* tmp260 = */ atspre_prerr_string (ATSstrcst(": evaluation is performed on a value not representing code.")) ; /* tmp261 = */ atspre_prerr_newline () ; /* tmp258 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp258) ; } /* end of [err_53] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 20909(line=710, offs=4) -- 21503(line=730, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_eval_52 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; __ats_lab_eval0_exp_app_eval_52: do { /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* ats_ptr_type tmp263 ; */ tmp263 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp264 ; */ tmp264 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; tmp265 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, tmp263, (&tmp264), tmp262) ; /* tmp266 = */ alphaenv_free_7 (tmp264) ; /* tmp267 = */ eval0ctx_free_22 (tmp263) ; tmp257 = tmp265 ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp257 = err_53 (arg0, arg1) ; break ; } while (0) ; return (tmp257) ; } /* end of [eval0_exp_app_eval_52] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 21542(line=732, offs=4) -- 21649(line=735, offs=4) */ ATSstaticdec() ats_ptr_type eval0_exp_app_lift_54 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; __ats_lab_eval0_exp_app_lift_54: tmp269 = lift_val_exp_6 (arg0, arg1) ; tmp268 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp268)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp268, atslab_0, tmp269) ; return (tmp268) ; } /* end of [eval0_exp_app_lift_54] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 22593(line=769, offs=6) -- 22786(line=774, offs=6) */ ATSstaticdec() ats_ptr_type err_56 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; // ATSlocal_void (tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; // ATSlocal_void (tmp275) ; // ATSlocal_void (tmp276) ; __ats_lab_err_56: /* tmp272 = */ prerr_loc_errmac_0 (arg0) ; /* tmp273 = */ atspre_prerr_string (ATSstrcst(": the variable [")) ; /* tmp274 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp275 = */ atspre_prerr_string (ATSstrcst("] is unbound.")) ; /* tmp276 = */ atspre_prerr_newline () ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp271) ; } /* end of [err_56] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 22815(line=776, offs=7) -- 23188(line=787, offs=53) */ ATSstaticdec() ats_ptr_type auxfind_57 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (atsopt_count_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_bool_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; __ats_lab_auxfind_57: do { /* branch: __ats_lab_86 */ __ats_lab_86_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_0) ; tmp279 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_1) ; tmp280 = &ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp278, arg1) ; if (tmp282) { tmp281 = tmp279 ; } else { tmp283 = ats_ptrget_mac(ats_ptr_type, tmp280) ; tmp281 = auxfind_57 (env0, env1, tmp283, arg1) ; } /* end of [if] */ tmp277 = tmp281 ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_87_1: tmp277 = err_56 (env0, env1) ; break ; } while (0) ; return (tmp277) ; } /* end of [auxfind_57] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxfind_57_closure_type ; ats_ptr_type auxfind_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, atsopt_count_type arg1) { return auxfind_57 (((auxfind_57_closure_type*)cloptr)->closure_env_0, ((auxfind_57_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type auxfind_57_closure_init (auxfind_57_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxfind_57_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxfind_57_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxfind_57_closure_type *p_clo = ATS_MALLOC(sizeof(auxfind_57_closure_type)) ; auxfind_57_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 22508(line=765, offs=5) -- 23260(line=792, offs=4) */ ATSstaticdec() ats_ptr_type eval0_var_55 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (atsopt_count_type, tmp284) ; __ats_lab_eval0_var_55: tmp284 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (arg2) ; tmp270 = auxfind_57 (arg0, arg2, arg1, tmp284) ; return (tmp270) ; } /* end of [eval0_var_55] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 23328(line=797, offs=11) -- 26272(line=881, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; ATSlocal (ats_char_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_bool_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; // ATSlocal_void (tmp312) ; // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_int_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; // ATSlocal_void (tmp329) ; // ATSlocal_void (tmp330) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg3), atslab_d2exp_node) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp286)->tag != 3) { goto __ats_lab_92_0 ; } __ats_lab_88_1: tmp287 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_0) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_1) ; tmp289 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp287), atslab_d2exp_node) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp289)->tag != 40) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_3, tmp289, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long (arg0, tmp290, arg1, arg2, tmp288) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp289)->tag != 52) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp291 = ats_caselptrlab_mac(anairiats_sum_3, tmp289, atslab_0) ; tmp292 = d2sym_is_nonqua_27 (tmp291) ; if (!tmp292) { goto __ats_lab_91_1 ; } tmp293 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp291), atslab_d2sym_sym) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_sym (arg0, tmp293, arg1, arg2, tmp288) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: /* tmp294 = */ prerr_loc_errmac_0 (arg0) ; /* tmp295 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression (")) ; tmp297 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp287), atslab_d2exp_loc) ; /* tmp296 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp297) ; /* tmp298 = */ atspre_prerr_string (ATSstrcst(") should be a macro but it is not.")) ; /* tmp299 = */ atspre_prerr_newline () ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp286)->tag != 10) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_2, tmp286, atslab_0) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp285)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp285, atslab_0, tmp300) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp286)->tag != 22) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp301 = ats_caselptrlab_mac(anairiats_sum_3, tmp286, atslab_0) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp285)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp285, atslab_0, tmp301) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp286)->tag != 27) { goto __ats_lab_99_0 ; } __ats_lab_94_1: tmp302 = ats_caselptrlab_mac(anairiats_sum_20, tmp286, atslab_1) ; tmp303 = ats_caselptrlab_mac(anairiats_sum_20, tmp286, atslab_2) ; tmp304 = ats_caselptrlab_mac(anairiats_sum_20, tmp286, atslab_3) ; tmp305 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp302) ; do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp305)->tag != 0) { goto __ats_lab_98_0 ; } __ats_lab_95_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_1, tmp305, atslab_0) ; if (tmp306) { arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp303 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp ; // tail call } else { do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (tmp304 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp307 = ats_caselptrlab_mac(anairiats_sum_7, tmp304, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp307 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (tmp304 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp285 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALunit_7) ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: __ats_lab_98_1: /* tmp308 = */ prerr_loc_errmac_0 (arg0) ; /* tmp309 = */ atspre_prerr_string (ATSstrcst(": the expansion of the dynamic expression (")) ; tmp311 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp302), atslab_d2exp_loc) ; /* tmp310 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp311) ; /* tmp312 = */ atspre_prerr_string (ATSstrcst(") should return a boolean value but it did not.")) ; /* tmp313 = */ atspre_prerr_newline () ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp286)->tag != 28) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp314 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_1) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp285)->tag = 4 ; ats_selptrset_mac(anairiats_sum_3, tmp285, atslab_0, tmp314) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp286)->tag != 40) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_3, tmp286, atslab_0) ; tmp316 = (ats_sum_ptr_type)0 ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long (arg0, tmp315, arg1, arg2, tmp316) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp286)->tag != 41) { goto __ats_lab_105_0 ; } __ats_lab_101_1: tmp317 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_0) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_1) ; do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp317)->tag != 0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp319 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp318) ; tmp320 = eval0_exp_app_eval_52 (arg0, tmp319) ; tmp321 = lift_val_exp_6 (arg0, tmp320) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp285, atslab_0, tmp321) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp317)->tag != 1) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp322 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp318) ; tmp285 = eval0_exp_app_eval_52 (arg0, tmp322) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: // if (((ats_sum_ptr_type)tmp317)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_104_1: tmp323 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp318) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp285, atslab_0, tmp323) ; break ; } while (0) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp286)->tag != 51) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_4, tmp286, atslab_0) ; tmp325 = ats_caselptrlab_mac(anairiats_sum_4, tmp286, atslab_1) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp285)->tag = 6 ; ats_selptrset_mac(anairiats_sum_4, tmp285, atslab_0, tmp324) ; ats_selptrset_mac(anairiats_sum_4, tmp285, atslab_1, tmp325) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)tmp286)->tag != 56) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_3, tmp286, atslab_0) ; tmp285 = eval0_var_55 (arg0, arg1, tmp326) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: __ats_lab_107_1: /* tmp327 = */ prerr_loc_errmac_0 (arg0) ; /* tmp328 = */ atspre_prerr_string (ATSstrcst(": unsupported form for macro expansion: ")) ; /* tmp329 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (arg3) ; /* tmp330 = */ atspre_prerr_newline () ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp285) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 26321(line=884, offs=3) -- 26602(line=894, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_explst: do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp332) ; tmp335 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_explst (arg0, arg1, arg2, tmp333) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp331, atslab_0, tmp334) ; ats_selptrset_mac(anairiats_sum_5, tmp331, atslab_1, tmp335) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: tmp331 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp331) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_explst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 26653(line=898, offs=4) -- 27804(line=932, offs=4) */ ATSstaticdec() ats_ptr_type d2exparg_dyn_get_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; // ATSlocal_void (tmp339) ; ATSlocal (ats_bool_type, tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; ATSlocal (ats_bool_type, tmp345) ; // ATSlocal_void (tmp346) ; ATSlocal (ats_bool_type, tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_bool_type, tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; // ATSlocal_void (tmp357) ; __ats_lab_d2exparg_dyn_get_60: do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp337 = ats_caselptrlab_mac(anairiats_sum_21, arg2, atslab_2) ; tmp338 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp337) ; tmp340 = atspre_ineq (tmp338, arg3) ; if (tmp340) { /* tmp341 = */ prerr_loc_errmac_0 (arg0) ; /* tmp342 = */ atspre_prerr_string (ATSstrcst(": the dynamic symbol [")) ; /* tmp343 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; tmp345 = atspre_igt (tmp338, 2) ; if (tmp345) { /* tmp344 = */ atspre_prerr_string (ATSstrcst("] expects two arguments but is given more.")) ; } else { /* empty */ } /* end of [if] */ tmp347 = atspre_ilt (tmp338, 2) ; if (tmp347) { /* tmp346 = */ atspre_prerr_string (ATSstrcst("] expects two arguments but is given fewer.")) ; } else { /* empty */ } /* end of [if] */ /* tmp348 = */ atspre_prerr_newline () ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp350 = atspre_ieq (tmp338, arg3) ; /* tmp339 = */ atspre_assert (tmp350) ; } else { /* empty */ } /* end of [if] */ tmp336 = tmp337 ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (((ats_sum_ptr_type)arg2)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: /* tmp351 = */ prerr_loc_errmac_0 (arg0) ; /* tmp352 = */ atspre_prerr_string (ATSstrcst(": the dynamic symbol [")) ; /* tmp353 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp354 = */ atspre_prerr_string (ATSstrcst("] is applied to static argument(s): {")) ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exparg (arg2) ; /* tmp356 = */ atspre_prerr_string (ATSstrcst("}")) ; /* tmp357 = */ atspre_prerr_newline () ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp336) ; } /* end of [d2exparg_dyn_get_60] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 27838(line=934, offs=4) -- 28222(line=944, offs=4) */ ATSstaticdec() ats_bool_type symbol_is_unary_61 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp358) ; ATSlocal (ats_bool_type, tmp359) ; ATSlocal (ats_bool_type, tmp360) ; ATSlocal (ats_bool_type, tmp361) ; ATSlocal (ats_bool_type, tmp362) ; ATSlocal (ats_bool_type, tmp363) ; ATSlocal (ats_bool_type, tmp364) ; ATSlocal (ats_bool_type, tmp365) ; __ats_lab_symbol_is_unary_61: do { /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp359 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC) ; if (!tmp359) { goto __ats_lab_113_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: tmp360 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC) ; if (!tmp360) { goto __ats_lab_114_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp361 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; if (!tmp361) { goto __ats_lab_115_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: __ats_lab_115_1: tmp362 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL) ; if (!tmp362) { goto __ats_lab_116_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: __ats_lab_116_1: tmp363 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS) ; if (!tmp363) { goto __ats_lab_117_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: __ats_lab_117_1: tmp364 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD) ; if (!tmp364) { goto __ats_lab_118_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: __ats_lab_118_1: tmp365 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL) ; if (!tmp365) { goto __ats_lab_119_1 ; } tmp358 = ats_true_bool ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: __ats_lab_119_1: tmp358 = ats_false_bool ; break ; } while (0) ; return (tmp358) ; } /* end of [symbol_is_unary_61] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 28255(line=946, offs=4) -- 28735(line=959, offs=4) */ ATSstaticdec() ats_bool_type symbol_is_binary_62 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp366) ; ATSlocal (ats_bool_type, tmp367) ; ATSlocal (ats_bool_type, tmp368) ; ATSlocal (ats_bool_type, tmp369) ; ATSlocal (ats_bool_type, tmp370) ; ATSlocal (ats_bool_type, tmp371) ; ATSlocal (ats_bool_type, tmp372) ; ATSlocal (ats_bool_type, tmp373) ; ATSlocal (ats_bool_type, tmp374) ; ATSlocal (ats_bool_type, tmp375) ; ATSlocal (ats_bool_type, tmp376) ; __ats_lab_symbol_is_binary_62: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: __ats_lab_120_1: tmp367 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; if (!tmp367) { goto __ats_lab_121_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp368 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; if (!tmp368) { goto __ats_lab_122_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: __ats_lab_122_1: tmp369 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; if (!tmp369) { goto __ats_lab_123_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: __ats_lab_123_1: tmp370 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; if (!tmp370) { goto __ats_lab_124_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: tmp371 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; if (!tmp371) { goto __ats_lab_125_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: __ats_lab_125_1: tmp372 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; if (!tmp372) { goto __ats_lab_126_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: tmp373 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; if (!tmp373) { goto __ats_lab_127_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: __ats_lab_127_1: tmp374 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; if (!tmp374) { goto __ats_lab_128_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: __ats_lab_128_1: tmp375 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; if (!tmp375) { goto __ats_lab_129_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: __ats_lab_129_1: tmp376 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; if (!tmp376) { goto __ats_lab_130_1 ; } tmp366 = ats_true_bool ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: __ats_lab_130_1: tmp366 = ats_false_bool ; break ; } while (0) ; return (tmp366) ; } /* end of [symbol_is_binary_62] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 28957(line=968, offs=6) -- 29205(line=975, offs=6) */ ATSstaticdec() ats_ptr_type err_64 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; __ats_lab_err_64: /* tmp379 = */ prerr_loc_errmac_0 (arg0) ; /* tmp380 = */ atspre_prerr_string (ATSstrcst(": an unrecognized symbol [")) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp382 = */ atspre_prerr_string (ATSstrcst("] is encountered during macro expansion.")) ; /* tmp383 = */ atspre_prerr_newline () ; /* tmp378 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp378) ; } /* end of [err_64] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 28794(line=962, offs=19) -- 32894(line=1081, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_sym (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; // ATSlocal_void (tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_bool_type, tmp403) ; ATSlocal (ats_bool_type, tmp404) ; ATSlocal (ats_bool_type, tmp405) ; ATSlocal (ats_bool_type, tmp406) ; ATSlocal (ats_bool_type, tmp407) ; ATSlocal (ats_bool_type, tmp408) ; ATSlocal (ats_bool_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; ATSlocal (ats_bool_type, tmp411) ; ATSlocal (ats_bool_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; // ATSlocal_void (tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; // ATSlocal_void (tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_bool_type, tmp426) ; ATSlocal (ats_bool_type, tmp427) ; ATSlocal (ats_bool_type, tmp428) ; ATSlocal (ats_bool_type, tmp429) ; ATSlocal (ats_bool_type, tmp430) ; ATSlocal (ats_bool_type, tmp431) ; ATSlocal (ats_bool_type, tmp432) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_sym: do { /* branch: __ats_lab_131 */ __ats_lab_131_0: __ats_lab_131_1: tmp384 = symbol_is_binary_62 (arg1) ; if (!tmp384) { goto __ats_lab_144_1 ; } /* ats_ptr_type tmp385 ; */ /* ats_ptr_type tmp386 ; */ do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_133_0 ; } tmp388 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_1) ; if (tmp388 != (ats_sum_ptr_type)0) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp389 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_0) ; tmp390 = d2exparg_dyn_get_60 (arg0, arg1, tmp389, 2) ; // if (tmp390 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp391 = ats_caselptrlab_mac(anairiats_sum_5, tmp390, atslab_0) ; tmp392 = ats_caselptrlab_mac(anairiats_sum_5, tmp390, atslab_1) ; // if (tmp392 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp393 = ats_caselptrlab_mac(anairiats_sum_5, tmp392, atslab_0) ; tmp385 = tmp391 ; tmp386 = tmp393 ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: __ats_lab_133_1: /* tmp394 = */ prerr_loc_errmac_0 (arg0) ; /* tmp395 = */ atspre_prerr_string (ATSstrcst(": the dynamic symbol [")) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp397 = */ atspre_prerr_string (ATSstrcst("] should be applied to exactly two arguments but it is not.")) ; /* tmp398 = */ atspre_prerr_newline () ; /* tmp399 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp385 = tmp399 ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp386 = tmp400 ; /* tmp387 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp401 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg2, arg3, tmp385) ; tmp402 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg2, arg3, tmp386) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: __ats_lab_134_1: tmp403 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; if (!tmp403) { goto __ats_lab_135_1 ; } tmp377 = eval0_exp_app_gt_30 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: tmp404 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; if (!tmp404) { goto __ats_lab_136_1 ; } tmp377 = eval0_exp_app_gte_31 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: __ats_lab_136_1: tmp405 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; if (!tmp405) { goto __ats_lab_137_1 ; } tmp377 = eval0_exp_app_lt_32 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: __ats_lab_137_1: tmp406 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; if (!tmp406) { goto __ats_lab_138_1 ; } tmp377 = eval0_exp_app_lte_33 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: __ats_lab_138_1: tmp407 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; if (!tmp407) { goto __ats_lab_139_1 ; } tmp377 = eval0_exp_app_eq_34 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: __ats_lab_139_1: tmp408 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; if (!tmp408) { goto __ats_lab_140_1 ; } tmp377 = eval0_exp_app_neq_35 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: __ats_lab_140_1: tmp409 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; if (!tmp409) { goto __ats_lab_141_1 ; } tmp377 = eval0_exp_app_add_38 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: __ats_lab_141_1: tmp410 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; if (!tmp410) { goto __ats_lab_142_1 ; } tmp377 = eval0_exp_app_sub_40 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: __ats_lab_142_1: tmp411 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; if (!tmp411) { goto __ats_lab_143_1 ; } tmp377 = eval0_exp_app_mul_42 (arg0, tmp401, tmp402) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: __ats_lab_143_1: tmp377 = err_64 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: __ats_lab_144_1: tmp412 = symbol_is_unary_61 (arg1) ; if (!tmp412) { goto __ats_lab_155_1 ; } /* ats_ptr_type tmp413 ; */ do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } tmp415 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_1) ; if (tmp415 != (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_0) ; tmp417 = d2exparg_dyn_get_60 (arg0, arg1, tmp416, 1) ; // if (tmp417 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp418 = ats_caselptrlab_mac(anairiats_sum_5, tmp417, atslab_0) ; tmp413 = tmp418 ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: __ats_lab_146_1: /* tmp419 = */ prerr_loc_errmac_0 (arg0) ; /* tmp420 = */ atspre_prerr_string (ATSstrcst(": the dynamic symbol [")) ; /* tmp421 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp422 = */ atspre_prerr_string (ATSstrcst("] should be applied to exactly one argument but it is not.")) ; /* tmp423 = */ atspre_prerr_newline () ; /* tmp424 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp413 = tmp424 ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg2, arg3, tmp413) ; do { /* branch: __ats_lab_147 */ __ats_lab_147_0: __ats_lab_147_1: tmp426 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC) ; if (!tmp426) { goto __ats_lab_148_1 ; } tmp377 = eval0_exp_app_eval_52 (arg0, tmp425) ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: __ats_lab_148_1: tmp427 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC) ; if (!tmp427) { goto __ats_lab_149_1 ; } tmp377 = eval0_exp_app_lift_54 (arg0, tmp425) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: __ats_lab_149_1: tmp428 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; if (!tmp428) { goto __ats_lab_150_1 ; } tmp377 = eval0_exp_app_neg_36 (arg0, tmp425) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: __ats_lab_150_1: tmp429 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL) ; if (!tmp429) { goto __ats_lab_151_1 ; } tmp377 = eval0_exp_app_is_nil_44 (arg0, tmp425) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: __ats_lab_151_1: tmp430 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS) ; if (!tmp430) { goto __ats_lab_152_1 ; } tmp377 = eval0_exp_app_is_cons_46 (arg0, tmp425) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: __ats_lab_152_1: tmp431 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD) ; if (!tmp431) { goto __ats_lab_153_1 ; } tmp377 = eval0_exp_app_tup_head_48 (arg0, tmp425) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: __ats_lab_153_1: tmp432 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL) ; if (!tmp432) { goto __ats_lab_154_1 ; } tmp377 = eval0_exp_app_tup_tail_50 (arg0, tmp425) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: __ats_lab_154_1: tmp377 = err_64 (arg0, arg1) ; break ; } while (0) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: __ats_lab_155_1: tmp377 = err_64 (arg0, arg1) ; break ; } while (0) ; return (tmp377) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 32947(line=1085, offs=4) -- 33117(line=1090, offs=4) */ ATSstaticdec() ats_ptr_type eval1_d2var_65 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; __ats_lab_eval1_d2var_65: tmp434 = alphaenv_find_9 (ats_ptrget_mac(ats_ptr_type, arg1), arg2) ; do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (tmp434 == (ats_sum_ptr_type)0) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_7, tmp434, atslab_0) ; ATS_FREE(tmp434) ; tmp433 = tmp435 ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: // if (tmp434 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_157_1: tmp433 = arg2 ; break ; } while (0) ; return (tmp433) ; } /* end of [eval1_d2var_65] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 33146(line=1092, offs=4) -- 33343(line=1097, offs=4) */ ATSstaticdec() ats_ptr_type eval1_d2expopt_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; __ats_lab_eval1_d2expopt_66: do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp437 = ats_caselptrlab_mac(anairiats_sum_7, arg3, atslab_0) ; tmp438 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp437) ; tmp436 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp436, atslab_0, tmp438) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp436 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp436) ; } /* end of [eval1_d2expopt_66] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 33375(line=1099, offs=4) -- 33670(line=1108, offs=4) */ ATSstaticdec() ats_ptr_type eval1_d2exparg_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_int_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; __ats_lab_eval1_d2exparg_67: do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)arg3)->tag != 1) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_21, arg3, atslab_1) ; tmp441 = ats_caselptrlab_mac(anairiats_sum_21, arg3, atslab_2) ; tmp442 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp441) ; tmp439 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp439)->tag = 1 ; ats_selptrset_mac(anairiats_sum_21, tmp439, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_21, tmp439, atslab_1, tmp440) ; ats_selptrset_mac(anairiats_sum_21, tmp439, atslab_2, tmp442) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (((ats_sum_ptr_type)arg3)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: tmp439 = arg3 ; break ; } while (0) ; return (tmp439) ; } /* end of [eval1_d2exparg_67] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 33703(line=1110, offs=5) -- 34025(line=1119, offs=4) */ ATSstaticdec() ats_ptr_type eval1_d2exparglst_68 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; __ats_lab_eval1_d2exparglst_68: do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp445 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp446 = eval1_d2exparg_67 (arg0, arg1, arg2, tmp444) ; tmp447 = eval1_d2exparglst_68 (arg0, arg1, arg2, tmp445) ; tmp443 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp443, atslab_0, tmp446) ; ats_selptrset_mac(anairiats_sum_5, tmp443, atslab_1, tmp447) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_163_1: tmp443 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp443) ; } /* end of [eval1_d2exparglst_68] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 34286(line=1127, offs=9) -- 34647(line=1136, offs=8) */ ATSstaticdec() ats_ptr_type aux_70 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; __ats_lab_aux_70: do { /* branch: __ats_lab_164 */ __ats_lab_164_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp452 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp453 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; tmp455 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp452), atslab_i2nvarg_var) ; tmp454 = eval1_d2var_65 (arg0, arg1, tmp455) ; tmp457 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp452), atslab_i2nvarg_typ) ; tmp456 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make (tmp454, tmp457) ; tmp458 = aux_70 (arg0, arg1, tmp453) ; tmp451 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp451, atslab_0, tmp456) ; ats_selptrset_mac(anairiats_sum_5, tmp451, atslab_1, tmp458) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_165_1: tmp451 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp451) ; } /* end of [aux_70] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 34060(line=1121, offs=4) -- 34729(line=1140, offs=4) */ ATSstaticdec() ats_ptr_type eval1_i2nvresstate_69 (ats_ptr_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; __ats_lab_eval1_i2nvresstate_69: tmp449 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_i2nvresstate_svs) ; tmp450 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_i2nvresstate_gua) ; tmp460 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_i2nvresstate_arg) ; tmp459 = aux_70 (arg0, arg1, tmp460) ; tmp448 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make (tmp449, tmp450, tmp459) ; return (tmp448) ; } /* end of [eval1_i2nvresstate_69] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 34769(line=1144, offs=4) -- 35103(line=1155, offs=4) */ ATSstaticdec() ats_ptr_type eval1_m2atch_71 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; __ats_lab_eval1_m2atch_71: tmp463 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg3), atslab_m2atch_exp) ; tmp462 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp463) ; tmp465 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg3), atslab_m2atch_pat) ; do { /* branch: __ats_lab_166 */ __ats_lab_166_0: if (tmp465 == (ats_sum_ptr_type)0) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp466 = ats_caselptrlab_mac(anairiats_sum_7, tmp465, atslab_0) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg2, tmp466) ; tmp464 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp464, atslab_0, tmp467) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: // if (tmp465 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_167_1: tmp464 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp468 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg3), atslab_m2atch_loc) ; tmp461 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__m2atch_make (tmp468, tmp462, tmp464) ; return (tmp461) ; } /* end of [eval1_m2atch_71] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 35134(line=1157, offs=5) -- 35454(line=1166, offs=4) */ ATSstaticdec() ats_ptr_type eval1_m2atchlst_72 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; __ats_lab_eval1_m2atchlst_72: do { /* branch: __ats_lab_168 */ __ats_lab_168_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp470 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp471 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp472 = eval1_m2atch_71 (arg0, arg1, arg2, tmp470) ; tmp473 = eval1_m2atchlst_72 (arg0, arg1, arg2, tmp471) ; tmp469 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp469, atslab_0, tmp472) ; ats_selptrset_mac(anairiats_sum_5, tmp469, atslab_1, tmp473) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_169_1: tmp469 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp469) ; } /* end of [eval1_m2atchlst_72] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 35487(line=1168, offs=4) -- 35899(line=1178, offs=4) */ ATSstaticdec() ats_ptr_type eval1_c2lau_73 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp474) ; // ATSlocal_void (tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; // ATSlocal_void (tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_int_type, tmp484) ; ATSlocal (ats_int_type, tmp485) ; __ats_lab_eval1_c2lau_73: /* tmp475 = */ alphaenv_push_14 (arg2) ; tmp477 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_pat) ; tmp476 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (arg0, arg2, tmp477) ; tmp479 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_gua) ; tmp478 = eval1_m2atchlst_72 (arg0, arg1, arg2, tmp479) ; tmp481 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_exp) ; tmp480 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp481) ; /* tmp482 = */ alphaenv_pop_12 (arg2) ; tmp483 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_loc) ; tmp484 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_seq) ; tmp485 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg3), atslab_c2lau_neg) ; tmp474 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__c2lau_make (tmp483, tmp476, tmp478, tmp484, tmp485, tmp480) ; return (tmp474) ; } /* end of [eval1_c2lau_73] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 36044(line=1183, offs=7) -- 36527(line=1199, offs=6) */ ATSstaticdec() ats_void_type aux_75 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; __ats_lab_aux_75: do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp488 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp489 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp490 = eval1_c2lau_73 (arg0, arg1, arg2, tmp488) ; tmp491 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp491, atslab_0, tmp490) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp491 ; // if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp492 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg4), atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp489 ; arg4 = tmp492 ; goto __ats_lab_aux_75 ; // tail call break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_171_1: tmp493 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp493 ; break ; } while (0) ; return /* (tmp487) */ ; } /* end of [aux_75] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 35928(line=1180, offs=4) -- 36627(line=1203, offs=4) */ ATSstaticdec() ats_ptr_type eval1_c2laulst_74 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp494) ; // ATSlocal_void (tmp495) ; __ats_lab_eval1_c2laulst_74: /* ats_ptr_type tmp494 ; */ /* tmp495 = */ aux_75 (arg0, arg1, arg2, arg3, (&tmp494)) ; tmp486 = tmp494 ; return (tmp486) ; } /* end of [eval1_c2laulst_74] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 36699(line=1208, offs=13) -- 47320(line=1519, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_bool_type, tmp512) ; ATSlocal (ats_int_type, tmp513) ; // ATSlocal_void (tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; // ATSlocal_void (tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; // ATSlocal_void (tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_int_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_int_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_int_type, tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_int_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_int_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; // ATSlocal_void (tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; // ATSlocal_void (tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_int_type, tmp594) ; ATSlocal (ats_int_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; // ATSlocal_void (tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; // ATSlocal_void (tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; // ATSlocal_void (tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; // ATSlocal_void (tmp613) ; ATSlocal (ats_int_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_int_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; // ATSlocal_void (tmp628) ; // ATSlocal_void (tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; // ATSlocal_void (tmp631) ; // ATSlocal_void (tmp632) ; // ATSlocal_void (tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; // ATSlocal_void (tmp635) ; // ATSlocal_void (tmp636) ; // ATSlocal_void (tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_int_type, tmp642) ; ATSlocal (ats_int_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; // ATSlocal_void (tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; // ATSlocal_void (tmp669) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp: tmp497 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg3), atslab_d2exp_node) ; do { /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp497)->tag != 0) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp498 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp499 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp500 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp498) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_funclo (arg0, tmp500, tmp499) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp497)->tag != 1) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp501 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp502 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp503 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp501) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_seff (arg0, tmp503, tmp502) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp497)->tag != 2) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp504 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp505 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp506 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp504) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ann_type (arg0, tmp506, tmp505) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp497)->tag != 3) { goto __ats_lab_180_0 ; } __ats_lab_175_1: tmp507 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp508 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp507) ; tmp510 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp509), atslab_d2exp_node) ; do { /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp510)->tag != 40) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp511 = ats_caselptrlab_mac(anairiats_sum_3, tmp510, atslab_0) ; tmp513 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind (tmp511) ; tmp512 = atspre_eq_int_int (tmp513, 0) ; if (tmp512) { tmp496 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short (arg0, tmp511, arg1, arg2, tmp508) ; } else { /* tmp514 = */ prerr_loc_errmac_0 (arg0) ; /* tmp515 = */ atspre_prerr_string (ATSstrcst(": the dynamic symbol [")) ; /* tmp516 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (tmp511) ; /* tmp517 = */ atspre_prerr_string (ATSstrcst("] (")) ; tmp519 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg3), atslab_d2exp_loc) ; /* tmp518 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp519) ; /* tmp520 = */ atspre_prerr_string (ATSstrcst(") refers to a macro definition in long form")) ; /* tmp521 = */ atspre_prerr_string (ATSstrcst("; it should be called inside the syntax ,(...)")) ; /* tmp522 = */ atspre_prerr_newline () ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: __ats_lab_177_1: tmp523 = eval1_d2exparglst_68 (arg0, arg1, arg2, tmp508) ; tmp524 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp509), atslab_d2exp_node) ; do { /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)tmp524)->tag != 3) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp525 = ats_caselptrlab_mac(anairiats_sum_9, tmp524, atslab_0) ; tmp526 = ats_caselptrlab_mac(anairiats_sum_9, tmp524, atslab_1) ; tmp527 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp526, tmp523) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps (arg0, tmp525, tmp527) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: __ats_lab_179_1: tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps (arg0, tmp509, tmp523) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)tmp497)->tag != 4) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp528 = ats_caselptrlab_mac(anairiats_sum_15, tmp497, atslab_0) ; tmp529 = ats_caselptrlab_mac(anairiats_sum_15, tmp497, atslab_1) ; tmp530 = ats_caselptrlab_mac(anairiats_sum_15, tmp497, atslab_2) ; tmp531 = eval1_d2expopt_66 (arg0, arg1, arg2, tmp529) ; tmp532 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp530) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrinit (arg0, tmp528, tmp531, tmp532) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp497)->tag != 5) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp533 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp534 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp535 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp534) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrpsz (arg0, tmp533, tmp535) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp497)->tag != 6) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp536 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_0) ; tmp537 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_1) ; tmp538 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_3) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp537) ; tmp540 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst (arg0, arg1, arg2, tmp538) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_arrsub (arg0, tmp536, tmp539, arg0, tmp540) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: if (((ats_sum_ptr_type)tmp497)->tag != 7) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp541 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp542 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp543 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp541) ; tmp544 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp542) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_assgn (arg0, tmp543, tmp544) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp497)->tag != 9) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp545 = ats_caselptrlab_mac(anairiats_sum_26, tmp497, atslab_0) ; tmp546 = ats_caselptrlab_mac(anairiats_sum_26, tmp497, atslab_1) ; tmp547 = ats_caselptrlab_mac(anairiats_sum_26, tmp497, atslab_2) ; tmp548 = ats_caselptrlab_mac(anairiats_sum_26, tmp497, atslab_3) ; tmp549 = ats_caselptrlab_mac(anairiats_sum_26, tmp497, atslab_4) ; tmp550 = eval1_i2nvresstate_69 (arg0, arg2, tmp546) ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp548) ; tmp552 = eval1_c2laulst_74 (arg0, arg1, arg2, tmp549) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_caseof (arg0, tmp545, tmp550, tmp547, tmp551, tmp552) ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)tmp497)->tag != 11) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp553 = ats_caselptrlab_mac(anairiats_sum_27, tmp497, atslab_0) ; tmp554 = ats_caselptrlab_mac(anairiats_sum_27, tmp497, atslab_1) ; tmp555 = ats_caselptrlab_mac(anairiats_sum_27, tmp497, atslab_2) ; tmp556 = ats_caselptrlab_mac(anairiats_sum_27, tmp497, atslab_3) ; tmp557 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp556) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_con (arg0, tmp553, tmp554, tmp555, tmp557) ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: if (((ats_sum_ptr_type)tmp497)->tag != 14) { goto __ats_lab_187_0 ; } __ats_lab_186_1: tmp558 = ats_caselptrlab_mac(anairiats_sum_13, tmp497, atslab_0) ; tmp559 = ats_caselptrlab_mac(anairiats_sum_13, tmp497, atslab_1) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp559) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_crypt (arg0, tmp558, tmp560) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: if (((ats_sum_ptr_type)tmp497)->tag != 12) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp561 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cst (arg0, tmp561) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: if (((ats_sum_ptr_type)tmp497)->tag != 13) { goto __ats_lab_189_0 ; } __ats_lab_188_1: tmp562 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_cstsp (arg0, tmp562) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: if (((ats_sum_ptr_type)tmp497)->tag != 15) { goto __ats_lab_190_0 ; } __ats_lab_189_1: tmp563 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp564 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp563) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_deref (arg0, tmp564) ; break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: if (((ats_sum_ptr_type)tmp497)->tag != 17) { goto __ats_lab_191_0 ; } __ats_lab_190_1: tmp565 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp566 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp566) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_effmask (arg0, tmp565, tmp567) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: if (((ats_sum_ptr_type)tmp497)->tag != 20) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp568 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp569 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_extval (arg0, tmp568, tmp569) ; break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: if (((ats_sum_ptr_type)tmp497)->tag != 19) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp571 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp572 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp571) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_exist (arg0, tmp570, tmp572) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: if (((ats_sum_ptr_type)tmp497)->tag != 21) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp573 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_0) ; tmp574 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_1) ; tmp575 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_2) ; /* tmp576 = */ alphaenv_push_14 (arg2) ; tmp577 = eval1_d2var_65 (arg0, arg2, tmp574) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp575) ; /* tmp579 = */ alphaenv_pop_12 (arg2) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_fix (arg0, tmp573, tmp577, tmp578) ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp497)->tag != 24) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp580 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp581 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp581) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_foldat (arg0, tmp580, tmp582) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp497)->tag != 26) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp583 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp584 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp585 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp584) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_freeat (arg0, tmp583, tmp585) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp497)->tag != 27) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp586 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_0) ; tmp587 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_1) ; tmp588 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_2) ; tmp589 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_3) ; tmp590 = eval1_i2nvresstate_69 (arg0, arg2, tmp586) ; tmp591 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp587) ; tmp592 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp588) ; tmp593 = eval1_d2expopt_66 (arg0, arg1, arg2, tmp589) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_if (arg0, tmp590, tmp591, tmp592, tmp593) ; break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp497)->tag != 28) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp496 = arg3 ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: if (((ats_sum_ptr_type)tmp497)->tag != 30) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp594 = ats_caselptrlab_mac(anairiats_sum_28, tmp497, atslab_0) ; tmp595 = ats_caselptrlab_mac(anairiats_sum_28, tmp497, atslab_1) ; tmp596 = ats_caselptrlab_mac(anairiats_sum_28, tmp497, atslab_2) ; tmp597 = ats_caselptrlab_mac(anairiats_sum_28, tmp497, atslab_3) ; /* tmp598 = */ alphaenv_push_14 (arg2) ; tmp599 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2atlst (arg0, arg2, tmp596) ; tmp600 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp597) ; /* tmp601 = */ alphaenv_pop_12 (arg2) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lam_dyn (arg0, tmp594, tmp595, tmp599, tmp600) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp497)->tag != 34) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp602 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp602) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_delay (arg0, tmp603) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp497)->tag != 35) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp604 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp605 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp606 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp604) ; tmp607 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp605) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lazy_ldelay (arg0, tmp606, tmp607) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: if (((ats_sum_ptr_type)tmp497)->tag != 36) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp608 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp609 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; /* tmp610 = */ alphaenv_push_14 (arg2) ; tmp611 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst (arg0, arg1, arg2, tmp608) ; tmp612 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp609) ; /* tmp613 = */ alphaenv_pop_12 (arg2) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_let (arg0, tmp611, tmp612) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)tmp497)->tag != 37) { goto __ats_lab_203_0 ; } __ats_lab_202_1: tmp614 = ats_caselptrlab_mac(anairiats_sum_13, tmp497, atslab_0) ; tmp615 = ats_caselptrlab_mac(anairiats_sum_13, tmp497, atslab_1) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp615) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_list (arg0, tmp614, tmp616) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)tmp497)->tag != 39) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp617 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_0) ; tmp618 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_1) ; tmp619 = ats_caselptrlab_mac(anairiats_sum_10, tmp497, atslab_2) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp619) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_lst (arg0, tmp617, tmp618, tmp620) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp497)->tag != 41) { goto __ats_lab_210_0 ; } __ats_lab_204_1: tmp621 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp622 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (((ats_sum_ptr_type)tmp621)->tag != 0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp624 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp622) ; tmp625 = lift_val_exp_6 (arg0, tmp624) ; tmp623 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp623)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp623, atslab_0, tmp625) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp621)->tag != 1) { goto __ats_lab_207_0 ; } __ats_lab_206_1: tmp623 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg1, arg2, tmp622) ; break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: __ats_lab_207_1: /* tmp626 = */ prerr_loc_errmac_0 (arg0) ; /* tmp627 = */ atspre_prerr_string (ATSstrcst(": invalid use of macro syntax: ")) ; /* tmp628 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (arg3) ; /* tmp629 = */ atspre_prerr_newline () ; /* tmp623 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_208 */ __ats_lab_208_0: if (((ats_sum_ptr_type)tmp623)->tag != 2) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp630 = ats_caselptrlab_mac(anairiats_sum_3, tmp623, atslab_0) ; tmp496 = tmp630 ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: __ats_lab_209_1: /* tmp631 = */ prerr_loc_errmac_0 (arg0) ; /* tmp632 = */ atspre_prerr_string (ATSstrcst(": the expansion of this dynamic expression (")) ; tmp634 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp622), atslab_d2exp_loc) ; /* tmp633 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp634) ; /* tmp635 = */ atspre_prerr_string (ATSstrcst(") should return a value representing code (abstract syntax tree)")) ; /* tmp636 = */ atspre_prerr_string (ATSstrcst(", but it did not do so.")) ; /* tmp637 = */ atspre_prerr_newline () ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)tmp497)->tag != 42) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp638 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp639 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp638) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_ptrof (arg0, tmp639) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp497)->tag != 43) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp640 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp641 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp640) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_raise (arg0, tmp641) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp497)->tag != 44) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp642 = ats_caselptrlab_mac(anairiats_sum_14, tmp497, atslab_0) ; tmp643 = ats_caselptrlab_mac(anairiats_sum_14, tmp497, atslab_1) ; tmp644 = ats_caselptrlab_mac(anairiats_sum_14, tmp497, atslab_2) ; tmp645 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst (arg0, arg1, arg2, tmp644) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_rec (arg0, tmp642, tmp643, tmp645) ; break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: if (((ats_sum_ptr_type)tmp497)->tag != 47) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp646 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp647 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp646) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_seq (arg0, tmp647) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp497)->tag != 49) { goto __ats_lab_215_0 ; } __ats_lab_214_1: tmp648 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_0) ; tmp649 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_1) ; tmp650 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_2) ; tmp651 = ats_caselptrlab_mac(anairiats_sum_20, tmp497, atslab_3) ; tmp652 = eval1_i2nvresstate_69 (arg0, arg2, tmp648) ; tmp653 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp650) ; tmp654 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp651) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_sif (arg0, tmp652, tmp649, tmp653, tmp654) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp497)->tag != 51) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp496 = arg3 ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp497)->tag != 50) { goto __ats_lab_217_0 ; } __ats_lab_216_1: tmp655 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp656 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst (arg0, arg1, arg2, tmp655) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_struct (arg0, tmp656) ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp497)->tag != 52) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp496 = arg3 ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp497)->tag != 53) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp657 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp658 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; tmp659 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp657) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tmpid (arg0, tmp659, tmp658) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp497)->tag != 56) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp660 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp661 = eval1_d2var_65 (arg0, arg2, tmp660) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var (arg0, tmp661) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp497)->tag != 57) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp662 = ats_caselptrlab_mac(anairiats_sum_3, tmp497, atslab_0) ; tmp663 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp662) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_viewat (arg0, tmp663) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp497)->tag != 58) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp664 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_0) ; tmp665 = ats_caselptrlab_mac(anairiats_sum_9, tmp497, atslab_1) ; /* tmp666 = */ alphaenv_push_14 (arg2) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst (arg0, arg1, arg2, tmp665) ; tmp668 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp664) ; /* tmp669 = */ alphaenv_pop_12 (arg2) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_where (arg0, tmp668, tmp667) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: __ats_lab_222_1: tmp496 = arg3 ; break ; } while (0) ; return (tmp496) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 47427(line=1525, offs=7) -- 47908(line=1541, offs=6) */ ATSstaticdec() ats_void_type aux_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp671) ; ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; __ats_lab_aux_78: do { /* branch: __ats_lab_223 */ __ats_lab_223_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp672 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp673 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp674 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp672) ; tmp675 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp675, atslab_0, tmp674) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp675 ; // if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp676 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg4), atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp673 ; arg4 = tmp676 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_224_1: tmp677 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp677 ; break ; } while (0) ; return /* (tmp671) */ ; } /* end of [aux_78] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 47392(line=1524, offs=16) -- 48008(line=1545, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp678) ; // ATSlocal_void (tmp679) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst: /* ats_ptr_type tmp678 ; */ /* tmp679 = */ aux_78 (arg0, arg1, arg2, arg3, (&tmp678)) ; tmp670 = tmp678 ; return (tmp670) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 48065(line=1548, offs=19) -- 48319(line=1556, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst: do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp681 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp682 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp683 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explst (arg0, arg1, arg2, tmp681) ; tmp684 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst (arg0, arg1, arg2, tmp682) ; tmp680 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp680, atslab_0, tmp683) ; ats_selptrset_mac(anairiats_sum_5, tmp680, atslab_1, tmp684) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_226_1: tmp680 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp680) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 48436(line=1562, offs=7) -- 48945(line=1578, offs=6) */ ATSstaticdec() ats_void_type aux_81 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; __ats_lab_aux_81: do { /* branch: __ats_lab_227 */ __ats_lab_227_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp687 = ats_caselptrlab_mac(anairiats_sum_29, arg3, atslab_0) ; tmp688 = ats_caselptrlab_mac(anairiats_sum_29, arg3, atslab_1) ; tmp689 = ats_caselptrlab_mac(anairiats_sum_29, arg3, atslab_2) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp688) ; tmp691 = ATS_MALLOC(sizeof(anairiats_sum_29)) ; ats_selptrset_mac(anairiats_sum_29, tmp691, atslab_0, tmp687) ; ats_selptrset_mac(anairiats_sum_29, tmp691, atslab_1, tmp690) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp691 ; // if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp692 = &ats_caselptrlab_mac(anairiats_sum_29, ats_ptrget_mac(ats_ptr_type, arg4), atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp689 ; arg4 = tmp692 ; goto __ats_lab_aux_81 ; // tail call break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_228_1: tmp693 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp693 ; break ; } while (0) ; return /* (tmp686) */ ; } /* end of [aux_81] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 48400(line=1561, offs=19) -- 49049(line=1582, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp694) ; // ATSlocal_void (tmp695) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst: /* ats_ptr_type tmp694 ; */ /* tmp695 = */ aux_81 (arg0, arg1, arg2, arg3, (&tmp694)) ; tmp685 = tmp694 ; return (tmp685) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_labd2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 49316(line=1593, offs=9) -- 49665(line=1601, offs=38) */ ATSstaticdec() ats_ptr_type aux_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; __ats_lab_aux_83: do { /* branch: __ats_lab_229 */ __ats_lab_229_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp698 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp699 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp701 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp698), atslab_v2aldec_pat) ; tmp700 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_p2at (arg0, arg2, tmp701) ; tmp702 = aux_83 (arg0, arg1, arg2, tmp699) ; tmp697 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp697, atslab_0, tmp700) ; ats_selptrset_mac(anairiats_sum_5, tmp697, atslab_1, tmp702) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_230_1: tmp697 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp697) ; } /* end of [aux_83] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 49750(line=1604, offs=9) -- 50257(line=1615, offs=39) */ ATSstaticdec() ats_ptr_type aux_84 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; __ats_lab_aux_84: do { /* branch: __ats_lab_231 */ __ats_lab_231_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp705 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp706 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; ATS_FREE(arg3) ; // if (arg4 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp707 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_0) ; tmp708 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_1) ; tmp710 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp707), atslab_v2aldec_def) ; tmp709 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, tmp710) ; tmp712 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp707), atslab_v2aldec_ann) ; tmp711 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__v2aldec_make (arg0, tmp705, tmp709, tmp712) ; tmp713 = aux_84 (arg0, arg1, arg2, tmp706, tmp708) ; tmp704 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp704, atslab_0, tmp711) ; ats_selptrset_mac(anairiats_sum_5, tmp704, atslab_1, tmp713) ; break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_232_1: tmp704 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp704) ; } /* end of [aux_84] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 49156(line=1589, offs=5) -- 50293(line=1619, offs=4) */ ATSstaticdec() ats_ptr_type eval1_v2aldeclst_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp703) ; __ats_lab_eval1_v2aldeclst_82: tmp703 = aux_83 (arg0, arg1, arg2, arg3) ; tmp696 = aux_84 (arg0, arg1, arg2, tmp703, arg3) ; return (tmp696) ; } /* end of [eval1_v2aldeclst_82] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 50366(line=1624, offs=12) -- 51120(line=1645, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2ec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; // ATSlocal_void (tmp723) ; // ATSlocal_void (tmp724) ; // ATSlocal_void (tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; // ATSlocal_void (tmp727) ; // ATSlocal_void (tmp728) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2ec: tmp715 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg3), atslab_d2ec_node) ; do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)tmp715)->tag != 0) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp714 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_none (arg0) ; break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: if (((ats_sum_ptr_type)tmp715)->tag != 1) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp716 = ats_caselptrlab_mac(anairiats_sum_3, tmp715, atslab_0) ; tmp717 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst (arg0, arg1, arg2, tmp716) ; tmp714 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_list (arg0, tmp717) ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: if (((ats_sum_ptr_type)tmp715)->tag != 14) { goto __ats_lab_236_0 ; } __ats_lab_235_1: tmp718 = ats_caselptrlab_mac(anairiats_sum_9, tmp715, atslab_0) ; tmp719 = ats_caselptrlab_mac(anairiats_sum_9, tmp715, atslab_1) ; tmp720 = eval1_v2aldeclst_82 (arg0, arg1, arg2, tmp719) ; tmp714 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs (arg0, tmp718, tmp720) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)tmp715)->tag != 16) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp721 = ats_caselptrlab_mac(anairiats_sum_3, tmp715, atslab_0) ; tmp722 = eval1_v2aldeclst_82 (arg0, arg1, arg2, tmp721) ; tmp714 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2ec_valdecs_rec (arg0, tmp722) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: __ats_lab_237_1: /* tmp723 = */ prerr_loc_errmac_0 (arg0) ; /* tmp724 = */ atspre_prerr_string (ATSstrcst(": this form of declaration (")) ; tmp726 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg3), atslab_d2ec_loc) ; /* tmp725 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp726) ; /* tmp727 = */ atspre_prerr_string (ATSstrcst(") is not supported in macro expansion.")) ; /* tmp728 = */ atspre_prerr_newline () ; /* tmp714 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp714) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2ec] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 51204(line=1649, offs=7) -- 51668(line=1665, offs=6) */ ATSstaticdec() ats_void_type aux_87 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; __ats_lab_aux_87: do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp731 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp732 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp733 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2ec (arg0, arg1, arg2, tmp731) ; tmp734 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp734, atslab_0, tmp733) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp734 ; // if (ats_ptrget_mac(ats_ptr_type, arg4) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp735 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg4), atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp732 ; arg4 = tmp735 ; goto __ats_lab_aux_87 ; // tail call break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_239_1: tmp736 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp736 ; break ; } while (0) ; return /* (tmp730) */ ; } /* end of [aux_87] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 51169(line=1648, offs=15) -- 51767(line=1669, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp737) ; // ATSlocal_void (tmp738) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst: /* ats_ptr_type tmp737 ; */ /* tmp738 = */ aux_87 (arg0, arg1, arg2, arg3, (&tmp737)) ; tmp729 = tmp737 ; return (tmp729) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2eclst] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 52017(line=1680, offs=6) -- 52191(line=1688, offs=6) */ ATSstaticdec() ats_ptr_type aux_89 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; __ats_lab_aux_89: tmp741 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, arg1, arg2, arg3) ; tmp740 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp740)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp740, atslab_0, tmp741) ; return (tmp740) ; } /* end of [aux_89] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 52214(line=1689, offs=7) -- 52553(line=1702, offs=6) */ ATSstaticdec() ats_ptr_type auxlst_90 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; __ats_lab_auxlst_90: do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp743 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; tmp744 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; tmp745 = aux_89 (arg0, arg1, arg2, tmp743) ; tmp746 = auxlst_90 (arg0, arg1, arg2, tmp744) ; tmp742 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp742, atslab_0, tmp745) ; ats_selptrset_mac(anairiats_sum_5, tmp742, atslab_1, tmp746) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_241_1: tmp742 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp742) ; } /* end of [auxlst_90] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 51820(line=1673, offs=5) -- 53273(line=1725, offs=4) */ ATSstaticdec() ats_ptr_type eval0ctx_extend_arg_88 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; __ats_lab_eval0ctx_extend_arg_88: do { /* branch: __ats_lab_242 */ __ats_lab_242_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_247_0 ; } __ats_lab_242_1: tmp747 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_0) ; tmp748 = ats_caselptrlab_mac(anairiats_sum_5, arg4, atslab_1) ; // if (arg5 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp749 = ats_caselptrlab_mac(anairiats_sum_5, arg5, atslab_0) ; tmp750 = ats_caselptrlab_mac(anairiats_sum_5, arg5, atslab_1) ; do { /* branch: __ats_lab_243 */ __ats_lab_243_0: if (arg1 != 0) { goto __ats_lab_246_0 ; } __ats_lab_243_1: tmp752 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp749), atslab_d2exp_node) ; do { /* branch: __ats_lab_244 */ __ats_lab_244_0: if (((ats_sum_ptr_type)tmp752)->tag != 37) { goto __ats_lab_245_0 ; } __ats_lab_244_1: tmp753 = ats_caselptrlab_mac(anairiats_sum_13, tmp752, atslab_1) ; tmp754 = auxlst_90 (arg0, arg2, arg3, tmp753) ; tmp751 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp751)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp751, atslab_0, tmp754) ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: __ats_lab_245_1: tmp751 = aux_89 (arg0, arg2, arg3, tmp749) ; break ; } while (0) ; break ; /* branch: __ats_lab_246 */ __ats_lab_246_0: __ats_lab_246_1: tmp751 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, arg2, arg3, tmp749) ; break ; } while (0) ; tmp755 = eval0ctx_add_23 (arg6, tmp747, tmp751) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp748 ; arg5 = tmp750 ; arg6 = tmp755 ; goto __ats_lab_eval0ctx_extend_arg_88 ; // tail call break ; /* branch: __ats_lab_247 */ __ats_lab_247_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_247_1: tmp739 = arg6 ; break ; } while (0) ; return (tmp739) ; } /* end of [eval0ctx_extend_arg_88] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 53352(line=1729, offs=5) -- 55104(line=1775, offs=4) */ ATSstaticdec() ats_ptr_type eval0ctx_extend_arglst_91 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7) { /* local vardec */ ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; // ATSlocal_void (tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; // ATSlocal_void (tmp764) ; // ATSlocal_void (tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; // ATSlocal_void (tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (anairiats_rec_32, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_int_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_int_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_int_type, tmp779) ; // ATSlocal_void (tmp780) ; ATSlocal (ats_bool_type, tmp781) ; // ATSlocal_void (tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; // ATSlocal_void (tmp785) ; // ATSlocal_void (tmp786) ; // ATSlocal_void (tmp787) ; ATSlocal (ats_bool_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; __ats_lab_eval0ctx_extend_arglst_91: do { /* branch: __ats_lab_248 */ __ats_lab_248_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_253_0 ; } __ats_lab_248_1: tmp757 = ats_caselptrlab_mac(anairiats_sum_5, arg5, atslab_0) ; tmp758 = ats_caselptrlab_mac(anairiats_sum_5, arg5, atslab_1) ; // if (arg6 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp759 = ats_caselptrlab_mac(anairiats_sum_5, arg6, atslab_0) ; tmp760 = ats_caselptrlab_mac(anairiats_sum_5, arg6, atslab_1) ; /* ats_ptr_type tmp761 ; */ tmp761 = (ats_sum_ptr_type)0 ; do { /* branch: __ats_lab_249 */ __ats_lab_249_0: if (((ats_sum_ptr_type)tmp759)->tag != 1) { goto __ats_lab_250_0 ; } __ats_lab_249_1: tmp763 = ats_caselptrlab_mac(anairiats_sum_21, tmp759, atslab_2) ; tmp761 = tmp763 ; break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: // if (((ats_sum_ptr_type)tmp759)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_250_1: /* tmp764 = */ prerr_loc_errmac_0 (arg0) ; /* tmp765 = */ atspre_prerr_string (ATSstrcst(": the macro function [")) ; /* tmp766 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (arg1) ; /* tmp767 = */ atspre_prerr_string (ATSstrcst("] should not be applied to static arguments.")) ; /* tmp768 = */ atspre_prerr_newline () ; /* tmp762 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp769 = tmp761 ; do { /* branch: __ats_lab_251 */ __ats_lab_251_0: if (((ats_sum_ptr_type)tmp757)->tag != 0) { goto __ats_lab_252_0 ; } __ats_lab_251_1: tmp771 = ats_caselptrlab_mac(anairiats_sum_3, tmp757, atslab_0) ; tmp772 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp772, atslab_0, tmp771) ; tmp773 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_5, tmp772), atslab_1) ; tmp774 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp773) = tmp774 ; tmp770.atslab_0 = 1 ; tmp770.atslab_1 = tmp772 ; break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: // if (((ats_sum_ptr_type)tmp757)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_252_1: tmp775 = ats_caselptrlab_mac(anairiats_sum_13, tmp757, atslab_0) ; tmp776 = ats_caselptrlab_mac(anairiats_sum_13, tmp757, atslab_1) ; tmp770.atslab_0 = tmp775 ; tmp770.atslab_1 = tmp776 ; break ; } while (0) ; tmp777 = ats_select_mac(tmp770, atslab_0) ; tmp778 = ats_select_mac(tmp770, atslab_1) ; tmp779 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp769) ; tmp781 = atspre_ineq (tmp777, tmp779) ; if (tmp781) { /* tmp782 = */ prerr_loc_errmac_0 (arg0) ; /* tmp783 = */ atspre_prerr_string (ATSstrcst(": expansion of the macro [")) ; /* tmp784 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (arg1) ; /* tmp785 = */ atspre_prerr_string (ATSstrcst("] encounters an arity error.")) ; /* tmp786 = */ atspre_prerr_newline () ; /* tmp787 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp788 = atspre_ieq (tmp777, tmp779) ; /* tmp780 = */ atspre_assert (tmp788) ; } else { /* empty */ } /* end of [if] */ tmp789 = eval0ctx_extend_arg_88 (arg0, arg2, arg3, arg4, tmp778, tmp769, arg7) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp758 ; arg6 = tmp760 ; arg7 = tmp789 ; goto __ats_lab_eval0ctx_extend_arglst_91 ; // tail call break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_253_1: tmp756 = arg7 ; break ; } while (0) ; return (tmp756) ; } /* end of [eval0ctx_extend_arglst_91] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 55237(line=1781, offs=10) -- 56573(line=1821, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_int_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_int_type, tmp793) ; // ATSlocal_void (tmp794) ; ATSlocal (ats_bool_type, tmp795) ; // ATSlocal_void (tmp796) ; // ATSlocal_void (tmp797) ; // ATSlocal_void (tmp798) ; // ATSlocal_void (tmp799) ; ATSlocal (ats_bool_type, tmp800) ; // ATSlocal_void (tmp801) ; ATSlocal (ats_bool_type, tmp802) ; // ATSlocal_void (tmp803) ; // ATSlocal_void (tmp804) ; ATSlocal (ats_bool_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; // ATSlocal_void (tmp810) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long: tmp791 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg (arg1) ; tmp792 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst (arg1) ; tmp793 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg4) ; tmp795 = atspre_ineq (tmp791, tmp793) ; if (tmp795) { /* tmp796 = */ prerr_loc_errmac_0 (arg0) ; /* tmp797 = */ atspre_prerr_string (ATSstrcst(": the macro function [")) ; /* tmp798 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (arg1) ; tmp800 = atspre_igt (tmp791, tmp793) ; if (tmp800) { /* tmp799 = */ atspre_prerr_string (ATSstrcst("] is applied insufficiently.")) ; } else { /* empty */ } /* end of [if] */ tmp802 = atspre_ilt (tmp793, tmp791) ; if (tmp802) { /* tmp801 = */ atspre_prerr_string (ATSstrcst("] is overly applied.")) ; } else { /* empty */ } /* end of [if] */ /* tmp803 = */ atspre_prerr_newline () ; /* tmp804 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp805 = atspre_ieq (tmp791, tmp793) ; /* tmp794 = */ atspre_assert (tmp805) ; } else { /* empty */ } /* end of [if] */ tmp807 = (ats_sum_ptr_type)0 ; tmp806 = eval0ctx_extend_arglst_91 (arg0, arg1, 1, arg2, arg3, tmp792, arg4, tmp807) ; tmp809 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def (arg1) ; tmp808 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (arg0, tmp806, arg3, tmp809) ; /* tmp810 = */ eval0ctx_free_22 (tmp806) ; tmp790 = tmp808 ; return (tmp790) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_long] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 57632(line=1854, offs=9) -- 57959(line=1863, offs=10) */ ATSstaticdec() ats_ptr_type aux_94 (ats_int_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_bool_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_int_type, tmp830) ; __ats_lab_aux_94: tmp826 = atspre_igt (arg0, 0) ; if (tmp826) { // if (ats_ptrget_mac(ats_ptr_type, arg1) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp827 = ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg1), atslab_0) ; tmp828 = ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg1), atslab_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp828 ; tmp830 = atspre_isub (arg0, 1) ; tmp829 = aux_94 (tmp830, arg1) ; tmp825 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp825, atslab_0, tmp827) ; ats_selptrset_mac(anairiats_sum_5, tmp825, atslab_1, tmp829) ; } else { tmp825 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp825) ; } /* end of [aux_94] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 56706(line=1826, offs=32) -- 58695(line=1887, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_int_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_int_type, tmp814) ; // ATSlocal_void (tmp815) ; ATSlocal (ats_bool_type, tmp816) ; // ATSlocal_void (tmp817) ; // ATSlocal_void (tmp818) ; // ATSlocal_void (tmp819) ; // ATSlocal_void (tmp820) ; // ATSlocal_void (tmp821) ; // ATSlocal_void (tmp822) ; ATSlocal (ats_bool_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; // ATSlocal_void (tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short: tmp812 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg (arg1) ; tmp813 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst (arg1) ; tmp814 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg4) ; tmp816 = atspre_igt (tmp812, tmp814) ; if (tmp816) { /* tmp817 = */ prerr_loc_errmac_0 (arg0) ; /* tmp818 = */ atspre_prerr_string (ATSstrcst(": the macro function [")) ; /* tmp819 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (arg1) ; /* tmp820 = */ atspre_prerr_string (ATSstrcst("] is applied insufficiently.")) ; /* tmp821 = */ atspre_prerr_newline () ; /* tmp822 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp823 = atspre_ilte (tmp812, tmp814) ; /* tmp815 = */ atspre_assert (tmp823) ; } else { /* empty */ } /* end of [if] */ /* ats_ptr_type tmp824 ; */ tmp824 = arg4 ; tmp831 = aux_94 (tmp812, (&tmp824)) ; tmp833 = (ats_sum_ptr_type)0 ; tmp832 = eval0ctx_extend_arglst_91 (arg0, arg1, 0, arg2, arg3, tmp813, tmp831, tmp833) ; tmp835 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def (arg1) ; tmp834 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval1_d2exp (arg0, tmp832, arg3, tmp835) ; /* tmp836 = */ eval0ctx_free_22 (tmp832) ; do { /* branch: __ats_lab_254 */ __ats_lab_254_0: if (tmp824 == (ats_sum_ptr_type)0) { goto __ats_lab_257_0 ; } __ats_lab_254_1: tmp837 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp834), atslab_d2exp_node) ; do { /* branch: __ats_lab_255 */ __ats_lab_255_0: if (((ats_sum_ptr_type)tmp837)->tag != 3) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp838 = ats_caselptrlab_mac(anairiats_sum_9, tmp837, atslab_0) ; tmp839 = ats_caselptrlab_mac(anairiats_sum_9, tmp837, atslab_1) ; tmp840 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp839, tmp824) ; tmp811 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps (arg0, tmp838, tmp840) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: __ats_lab_256_1: tmp811 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_apps (arg0, tmp834, tmp824) ; break ; } while (0) ; break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: // if (tmp824 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_257_1: tmp811 = tmp834 ; break ; } while (0) ; return (tmp811) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 58781(line=1892, offs=18) -- 59015(line=1901, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_cross (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; // ATSlocal_void (tmp846) ; // ATSlocal_void (tmp847) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_cross: tmp842 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_d2exp_loc) ; /* ats_ptr_type tmp843 ; */ tmp843 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp844 ; */ tmp844 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; tmp845 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (tmp842, tmp843, (&tmp844), arg0) ; /* tmp846 = */ alphaenv_free_7 (tmp844) ; /* tmp847 = */ eval0ctx_free_22 (tmp843) ; tmp841 = lift_val_exp_6 (tmp842, tmp845) ; return (tmp841) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_cross] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 59074(line=1904, offs=19) -- 59611(line=1921, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_decode (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; // ATSlocal_void (tmp853) ; // ATSlocal_void (tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; // ATSlocal_void (tmp856) ; // ATSlocal_void (tmp857) ; // ATSlocal_void (tmp858) ; // ATSlocal_void (tmp859) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_decode: tmp849 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_d2exp_loc) ; /* ats_ptr_type tmp850 ; */ tmp850 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp851 ; */ tmp851 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; tmp852 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp (tmp849, tmp850, (&tmp851), arg0) ; /* tmp853 = */ alphaenv_free_7 (tmp851) ; /* tmp854 = */ eval0ctx_free_22 (tmp850) ; do { /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp852)->tag != 2) { goto __ats_lab_259_0 ; } __ats_lab_258_1: tmp855 = ats_caselptrlab_mac(anairiats_sum_3, tmp852, atslab_0) ; tmp848 = tmp855 ; break ; /* branch: __ats_lab_259 */ __ats_lab_259_0: __ats_lab_259_1: /* tmp856 = */ prerr_loc_errmac_0 (tmp849) ; /* tmp857 = */ atspre_prerr_string (ATSstrcst(": the expansion of this macro should yield code (abstract syntax tree)")) ; /* tmp858 = */ atspre_prerr_string (ATSstrcst(", but a value that does not represent code is returned instead.")) ; /* tmp859 = */ atspre_prerr_newline () ; /* tmp848 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp848) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_decode] */ /* // /home/hwxi/research/Anairiats/src/ats_macro2.dats: 59695(line=1926, offs=22) -- 59911(line=1934, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; // ATSlocal_void (tmp864) ; // ATSlocal_void (tmp865) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short: /* ats_ptr_type tmp861 ; */ tmp861 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp862 ; */ tmp862 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2) ; tmp863 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__eval0_exp_app_mac_short (arg0, arg1, tmp861, (&tmp862), arg2) ; /* tmp864 = */ alphaenv_free_7 (tmp862) ; /* tmp865 = */ eval0ctx_free_22 (tmp861) ; tmp860 = tmp863 ; return (tmp860) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALbool_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALchar_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALcode_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALfloat_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALint_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALlst_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALstring_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__V2ALunit_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVcons_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVmark_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__ALPHAENVnil_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__EVAL0CTXnil_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp2, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp2 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp2)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp2, atslab_0, ats_true_bool) ; statmp3 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)statmp3)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, statmp3, atslab_0, ats_false_bool) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_macro2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_util2_dats.c0000664000175000017500000066571512223166160022650 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ #include "ats_intinf.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_10 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_19 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEcst_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEextype_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyarr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyrec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEunion_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, atsopt_eq_int_intinf) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_eq_intinf_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_eq_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isrec) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_def) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_supcls) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lab_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec) (ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt) (ats_ptr_type, atsopt_count_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_eqref_s2exp_s2exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_get_lab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_set_lab) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_lab_restlin_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_ind_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_btw_int_int_int_bool) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_ptr_type s2exp_link_remove_flag_3 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type labs2explst_readize_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labs2explst_topize_8 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_14 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_15 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type s2exp_whnf_flag_12 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type s2explst_whnf_flag_13 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type s2exp_nfapp_flag_18 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type s2explst_nfapp_flag_19 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type labs2explst_nfapp_flag_20 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type __ats_fun_24 (ats_ptr_type arg0) ; static anairiats_rec_0 etaexpand_s2exp_s2exp_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type islam_s2exp_25 (ats_ptr_type arg0) ; static ats_bool_type islam_s2exp_s2exp_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2eff_syneq_27 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type labs2explst_syneq_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type labs2zexplst_syneq_32 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2zexplst_syneq_33 (ats_ptr_type arg0, ats_ptr_type arg1) ; static anairiats_rec_0 aux_37 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2exp_prenexing_38 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type s2exp_prenexing_main_39 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6) ; static ats_ptr_type s2explst_prenexing_40 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type labs2explst_prenexing_41 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_ptr_type aux_get_46 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_get_46_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_get_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_set_48 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_set_48_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_set_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_get_50 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_get_50_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_get_50_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_get_52 (ats_ptr_type env0, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_get_52_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_get_52_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labs2explst_get_lab_ind_51 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux_set_54 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_set_54_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_set_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type labs2explst_lab_set_ind_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type err1_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_varet_type err2_57 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_restlin_58 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static anairiats_rec_0 aux_60 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ptr_type arg4) ; static ats_clo_ptr_type aux_60_closure_make (ats_ptr_type env0) ; static anairiats_rec_0 aux_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ptr_type arg4) ; static ats_bool_type s2exp_is_int_0_61 (ats_ptr_type arg0) ; static ats_ptr_type un_s2exp_int_62 (ats_ptr_type arg0) ; static anairiats_rec_0 labs2explst_get_nth_63 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type labs2explst_nth_set_64 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type auxlst_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type auxlstlst_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type array_ind_dim_check_err_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) ; static ats_void_type linear_abandonment_errmsg_69 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type label_notfound_errmsg_70 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err_74 (ats_ptr_type arg0) ; static ats_ptr_type aux_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static anairiats_rec_19 aux_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static anairiats_rec_19 aux_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) ; static anairiats_rec_19 aux_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_int_type s2explst_subclass_test_83 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 2291(line=75, offs=4) -- 2376(line=76, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 2410(line=79, offs=4) -- 2472(line=79, offs=66) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_staexp2_util2)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 2476(line=80, offs=4) -- 2591(line=82, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_staexp2_util2)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 2649(line=86, offs=5) -- 3454(line=112, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_link_remove_flag_3 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; __ats_lab_s2exp_link_remove_flag_3: tmp6 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp6)->tag != 4) { goto __ats_lab_3_0 ; } __ats_lab_0_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_2, tmp6, atslab_0) ; tmp8 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isrec (tmp7) ; if (tmp8) { tmp5 = arg0 ; } else { tmp9 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_def (tmp7) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp9 == (ats_sum_ptr_type)0) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_3, tmp9, atslab_0) ; tmp11 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp11 ; arg0 = tmp10 ; arg1 = arg1 ; goto __ats_lab_s2exp_link_remove_flag_3 ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: // if (tmp9 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_2_1: tmp5 = arg0 ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp6)->tag != 33) { goto __ats_lab_6_0 ; } __ats_lab_3_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_2, tmp6, atslab_0) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (tmp12) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp13 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_3, tmp13, atslab_0) ; tmp15 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp15 ; arg0 = tmp14 ; arg1 = arg1 ; goto __ats_lab_s2exp_link_remove_flag_3 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp13 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp5 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp5 = arg0 ; break ; } while (0) ; return (tmp5) ; } /* end of [s2exp_link_remove_flag_3] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 3522(line=115, offs=19) -- 3597(line=117, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_link_remove (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_link_remove: /* ats_int_type tmp17 ; */ tmp17 = 0 ; tmp16 = s2exp_link_remove_flag_3 (arg0, (&tmp17)) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_link_remove] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 3654(line=121, offs=5) -- 4007(line=131, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_readize_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_labs2explst_readize_5: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp20 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp22 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize (arg0, tmp20) ; tmp23 = labs2explst_readize_5 (arg0, tmp21) ; tmp18 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp18, atslab_0, tmp19) ; ats_selptrset_mac(anairiats_sum_4, tmp18, atslab_1, tmp22) ; ats_selptrset_mac(anairiats_sum_4, tmp18, atslab_2, tmp23) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp18 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp18) ; } /* end of [labs2explst_readize_5] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 4065(line=134, offs=15) -- 4714(line=154, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_bool_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_int_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (atsopt_count_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize: tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_srt) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp25) ; if (tmp26) { tmp27 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize (tmp25) ; tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp28)->tag != 29) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp29 = ats_caselptrlab_mac(anairiats_sum_5, tmp28, atslab_0) ; tmp30 = ats_caselptrlab_mac(anairiats_sum_5, tmp28, atslab_1) ; tmp31 = ats_caselptrlab_mac(anairiats_sum_5, tmp28, atslab_2) ; tmp32 = labs2explst_readize_5 (arg0, tmp31) ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp27, tmp29, tmp30, tmp32) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp28)->tag != 31) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_6, tmp28, atslab_0) ; tmp34 = ats_caselptrlab_mac(anairiats_sum_6, tmp28, atslab_1) ; tmp35 = ats_caselptrlab_mac(anairiats_sum_6, tmp28, atslab_2) ; tmp36 = labs2explst_readize_5 (arg0, tmp35) ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp27, tmp33, tmp34, tmp36) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp24 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt (tmp27, arg0, arg1) ; break ; } while (0) ; } else { tmp24 = arg1 ; } /* end of [if] */ return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 4772(line=157, offs=18) -- 4942(line=163, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_bool_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp39 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp38) ; if (tmp39) { tmp40 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_readize (arg0, tmp38) ; tmp37 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp37, atslab_0, tmp40) ; } else { tmp37 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp37 = arg1 ; break ; } while (0) ; return (tmp37) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_readize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 5001(line=167, offs=5) -- 5327(line=176, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_topize_8 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_labs2explst_topize_8: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp43 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp44 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (arg0, tmp43) ; tmp46 = labs2explst_topize_8 (arg0, tmp44) ; tmp41 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp41, atslab_0, tmp42) ; ats_selptrset_mac(anairiats_sum_4, tmp41, atslab_1, tmp45) ; ats_selptrset_mac(anairiats_sum_4, tmp41, atslab_2, tmp46) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp41 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp41) ; } /* end of [labs2explst_topize_8] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 5386(line=179, offs=14) -- 6618(line=218, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_int_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (atsopt_count_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize: tmp48 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_srt) ; tmp50 = atspre_gt_int_int (arg0, 0) ; if (tmp50) { tmp51 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp48) ; if (tmp51) { tmp49 = ats_false_bool ; } else { tmp49 = ats_true_bool ; } /* end of [if] */ } else { tmp49 = ats_false_bool ; } /* end of [if] */ tmp52 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; if (tmp49) { tmp47 = tmp52 ; } else { tmp54 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp48) ; if (tmp54) { tmp53 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } else { tmp55 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (tmp48) ; if (tmp55) { tmp53 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp53 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } /* end of [if] */ tmp56 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp52), atslab_s2exp_node) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp56)->tag != 26) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_7, tmp56, atslab_0) ; tmp58 = ats_caselptrlab_mac(anairiats_sum_7, tmp56, atslab_1) ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (arg0, tmp57) ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp59, tmp58) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp56)->tag != 29) { goto __ats_lab_20_0 ; } __ats_lab_17_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_5, tmp56, atslab_0) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_5, tmp56, atslab_1) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_5, tmp56, atslab_2) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp60)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (tmp53, arg0, tmp52) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp63 = labs2explst_topize_8 (arg0, tmp62) ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp53, tmp60, tmp61, tmp63) ; break ; } while (0) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp56)->tag != 31) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_6, tmp56, atslab_0) ; tmp65 = ats_caselptrlab_mac(anairiats_sum_6, tmp56, atslab_2) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (-1) ; tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp53, tmp64, tmp66, tmp65) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (tmp53, arg0, tmp52) ; break ; } while (0) ; } /* end of [if] */ return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 6673(line=220, offs=26) -- 6709(line=220, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0: tmp67 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (0, arg0) ; return (tmp67) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 6735(line=221, offs=26) -- 6771(line=221, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1: tmp68 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (1, arg0) ; return (tmp68) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 7370(line=245, offs=15) -- 7813(line=255, offs=18) */ ATSstaticdec() ats_ptr_type aux_14 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; __ats_lab_aux_14: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_26_1 ; } __ats_lab_24_2: tmp80 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp81 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp84 = aux_14 (tmp81, tmp83) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (tmp84, tmp80, tmp82) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_26_1 ; } __ats_lab_25_2: tmp79 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: __ats_lab_26_2: /* tmp85 = */ prerr_interror_1 () ; /* tmp86 = */ atspre_prerr_string (ATSstrcst(": s2exp_whnf_flag: S2Eapp: arity error")) ; /* tmp87 = */ atspre_prerr_newline () ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp79) ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 10403(line=326, offs=15) -- 10765(line=333, offs=18) */ ATSstaticdec() ats_ptr_type aux_15 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_bool_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; __ats_lab_aux_15: do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp150 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp151 = atspre_gt_int_int (arg1, 0) ; if (tmp151) { tmp152 = atspre_sub_int_int (arg1, 1) ; arg0 = tmp150 ; arg1 = tmp152 ; goto __ats_lab_aux_15 ; // tail call } else { tmp148 = tmp149 ; } /* end of [if] */ break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: /* tmp153 = */ prerr_interror_1 () ; /* tmp154 = */ atspre_prerr_string (ATSstrcst(": s2exp_whnf: S2Etup: subscript error")) ; /* tmp155 = */ atspre_prerr_newline () ; /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp148) ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 6798(line=225, offs=5) -- 13289(line=405, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_whnf_flag_12 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_int_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_bool_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_int_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_int_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_int_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_int_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_int_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_bool_type, tmp106) ; ATSlocal (ats_bool_type, tmp107) ; ATSlocal (ats_bool_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_int_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_int_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (atsopt_count_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_bool_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_int_type, tmp157) ; ATSlocal (ats_bool_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_int_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_int_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_int_type, tmp170) ; ATSlocal (ats_int_type, tmp171) ; ATSlocal (ats_bool_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_int_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_int_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_bool_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_int_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (atsopt_count_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_bool_type, tmp190) ; ATSlocal (ats_bool_type, tmp191) ; ATSlocal (ats_bool_type, tmp192) ; ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_bool_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_int_type, tmp199) ; __ats_lab_s2exp_whnf_flag_12: tmp70 = s2exp_link_remove_flag_3 (arg0, arg1) ; tmp71 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp71)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_22_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_7, tmp71, atslab_0) ; tmp73 = ats_caselptrlab_mac(anairiats_sum_7, tmp71, atslab_1) ; tmp74 = ats_ptrget_mac(ats_int_type, arg1) ; tmp75 = s2exp_whnf_flag_12 (tmp72, arg1) ; tmp76 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp75), atslab_s2exp_node) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp76)->tag != 14) { goto __ats_lab_27_0 ; } __ats_lab_23_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_7, tmp76, atslab_0) ; tmp78 = ats_caselptrlab_mac(anairiats_sum_7, tmp76, atslab_1) ; tmp88 = aux_14 (tmp77, tmp73) ; tmp89 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp89 ; tmp90 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp88, tmp78) ; arg0 = tmp90 ; arg1 = arg1 ; goto __ats_lab_s2exp_whnf_flag_12 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp91 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp74) ; if (tmp91) { tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp92, tmp75, tmp73) ; } else { tmp69 = tmp70 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp71)->tag != 2) { goto __ats_lab_31_0 ; } __ats_lab_28_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_9, tmp71, atslab_0) ; tmp94 = ats_caselptrlab_mac(anairiats_sum_9, tmp71, atslab_1) ; tmp95 = ats_ptrget_mac(ats_int_type, arg1) ; tmp96 = s2exp_whnf_flag_12 (tmp94, arg1) ; tmp97 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp96), atslab_s2exp_node) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp97)->tag != 11) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_10, tmp97, atslab_1) ; tmp99 = ats_caselptrlab_mac(anairiats_sum_10, tmp97, atslab_2) ; tmp100 = ats_caselptrlab_mac(anairiats_sum_10, tmp97, atslab_3) ; tmp101 = ats_caselptrlab_mac(anairiats_sum_10, tmp97, atslab_4) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_10, tmp97, atslab_5) ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp103, atslab_0, tmp93) ; tmp104 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp104 ; tmp106 = atspre_eq_int_int (tmp93, 0) ; if (tmp106) { tmp107 = atspre_gt_int_int (tmp98, 0) ; if (tmp107) { tmp105 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } else { tmp105 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } else { tmp105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; } /* end of [if] */ tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp105, tmp103, tmp98, tmp99, tmp100, tmp101, tmp102) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp108 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp95) ; if (tmp108) { tmp109 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp96), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (tmp109, tmp93, tmp96) ; } else { tmp69 = tmp70 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp71)->tag != 3) { goto __ats_lab_35_0 ; } __ats_lab_31_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_2, tmp71, atslab_0) ; tmp111 = s2exp_whnf_flag_12 (tmp110, arg1) ; tmp112 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp111), atslab_s2exp_node) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp112)->tag != 9) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_1) ; tmp115 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_2) ; tmp116 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp116 ; tmp117 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (tmp115) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (tmp113, tmp114, tmp117) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp112)->tag != 30) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_0) ; tmp119 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_1) ; tmp120 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_2) ; tmp121 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp121 ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (tmp120) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp118, tmp119, tmp122) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: __ats_lab_34_1: tmp69 = tmp70 ; break ; } while (0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp71)->tag != 19) { goto __ats_lab_39_0 ; } __ats_lab_35_1: tmp123 = ats_caselptrlab_mac(anairiats_sum_7, tmp71, atslab_0) ; tmp124 = ats_caselptrlab_mac(anairiats_sum_7, tmp71, atslab_1) ; tmp125 = ats_ptrget_mac(ats_int_type, arg1) ; tmp126 = s2exp_whnf_flag_12 (tmp124, arg1) ; tmp127 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp126), atslab_s2exp_node) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp127)->tag != 29) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_5, tmp127, atslab_0) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_5, tmp127, atslab_1) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_5, tmp127, atslab_2) ; tmp131 = labs2explst_readize_5 (tmp123, tmp130) ; tmp132 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp132 ; tmp133 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp133, tmp128, tmp129, tmp131) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp127)->tag != 31) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp134 = ats_caselptrlab_mac(anairiats_sum_6, tmp127, atslab_0) ; tmp135 = ats_caselptrlab_mac(anairiats_sum_6, tmp127, atslab_1) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_6, tmp127, atslab_2) ; tmp137 = labs2explst_readize_5 (tmp123, tmp136) ; tmp138 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp138 ; tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp139, tmp134, tmp135, tmp137) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp140 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp125) ; if (tmp140) { tmp141 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt (tmp141, tmp123, tmp126) ; } else { tmp69 = tmp70 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp71)->tag != 21) { goto __ats_lab_44_0 ; } __ats_lab_39_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_13, tmp71, atslab_0) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_13, tmp71, atslab_1) ; tmp144 = ats_ptrget_mac(ats_int_type, arg1) ; tmp145 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp142) ; tmp146 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp145), atslab_s2exp_node) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp146)->tag != 25) { goto __ats_lab_43_0 ; } __ats_lab_40_1: tmp147 = ats_caselptrlab_mac(anairiats_sum_2, tmp146, atslab_0) ; tmp156 = aux_15 (tmp147, tmp143) ; tmp157 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp157 ; arg0 = tmp156 ; arg1 = arg1 ; goto __ats_lab_s2exp_whnf_flag_12 ; // tail call break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp158 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp144) ; if (tmp158) { tmp159 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt (tmp159, tmp145, tmp143) ; } else { tmp69 = tmp70 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp71)->tag != 23) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_2, tmp71, atslab_0) ; tmp161 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp161 ; tmp162 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (tmp160) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size (tmp162) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp71)->tag != 24) { goto __ats_lab_53_0 ; } __ats_lab_45_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_9, tmp71, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_9, tmp71, atslab_1) ; tmp165 = ats_ptrget_mac(ats_int_type, arg1) ; tmp166 = s2exp_whnf_flag_12 (tmp164, arg1) ; tmp167 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp166), atslab_s2exp_node) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp167)->tag != 24) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_9, tmp167, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_9, tmp167, atslab_1) ; tmp170 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp170 ; tmp172 = atspre_gt_int_int (tmp163, 0) ; if (tmp172) { tmp171 = tmp168 ; } else { tmp171 = 0 ; } /* end of [if] */ tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (tmp171, tmp169) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp167)->tag != 26) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_7, tmp167, atslab_0) ; tmp174 = ats_caselptrlab_mac(anairiats_sum_7, tmp167, atslab_1) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (tmp163, tmp173) ; tmp176 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp176 ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp175, tmp174) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp167)->tag != 29) { goto __ats_lab_51_0 ; } __ats_lab_48_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_5, tmp167, atslab_0) ; tmp178 = ats_caselptrlab_mac(anairiats_sum_5, tmp167, atslab_1) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_5, tmp167, atslab_2) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp177)->tag != 0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp180 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp165) ; if (tmp180) { tmp181 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (tmp181, tmp163, tmp166) ; } else { tmp69 = tmp70 ; } /* end of [if] */ break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: tmp182 = labs2explst_topize_8 (tmp163, tmp179) ; tmp183 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp183 ; tmp184 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp184, tmp177, tmp178, tmp182) ; break ; } while (0) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp167)->tag != 31) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_6, tmp167, atslab_0) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_6, tmp167, atslab_2) ; tmp187 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (-1) ; tmp188 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp188 ; tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp189, tmp185, tmp187, tmp186) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp191 = atspre_gt_int_int (tmp163, 0) ; if (tmp191) { tmp192 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp166) ; if (tmp192) { tmp190 = ats_false_bool ; } else { tmp190 = ats_true_bool ; } /* end of [if] */ } else { tmp190 = ats_false_bool ; } /* end of [if] */ if (tmp190) { tmp193 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp193 ; arg0 = tmp166 ; arg1 = arg1 ; goto __ats_lab_s2exp_whnf_flag_12 ; // tail call } else { tmp194 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp165) ; if (tmp194) { tmp195 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp70), atslab_s2exp_srt) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (tmp195, tmp163, tmp166) ; } else { tmp69 = tmp70 ; } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp71)->tag != 32) { goto __ats_lab_56_0 ; } __ats_lab_53_1: tmp196 = ats_caselptrlab_mac(anairiats_sum_2, tmp71, atslab_0) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find (tmp196) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (tmp197 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp198 = ats_caselptrlab_mac(anairiats_sum_3, tmp197, atslab_0) ; ATS_FREE(tmp197) ; tmp199 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg1), 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp199 ; arg0 = tmp198 ; arg1 = arg1 ; goto __ats_lab_s2exp_whnf_flag_12 ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (tmp197 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: tmp69 = tmp70 ; break ; } while (0) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp69 = tmp70 ; break ; } while (0) ; return (tmp69) ; } /* end of [s2exp_whnf_flag_12] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 13323(line=407, offs=5) -- 13664(line=418, offs=4) */ ATSstaticdec() ats_ptr_type s2explst_whnf_flag_13 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_bool_type, tmp206) ; __ats_lab_s2explst_whnf_flag_13: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp201 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp202 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp203 = ats_ptrget_mac(ats_int_type, arg1) ; tmp204 = s2exp_whnf_flag_12 (tmp201, arg1) ; tmp205 = s2explst_whnf_flag_13 (tmp202, arg1) ; tmp206 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp203) ; if (tmp206) { tmp200 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp200, atslab_0, tmp204) ; ats_selptrset_mac(anairiats_sum_8, tmp200, atslab_1, tmp205) ; } else { tmp200 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: tmp200 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp200) ; } /* end of [s2explst_whnf_flag_13] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 13718(line=421, offs=12) -- 13794(line=423, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_int_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf: /* ats_int_type tmp208 ; */ tmp208 = 0 ; tmp207 = s2exp_whnf_flag_12 (arg0, (&tmp208)) ; return (tmp207) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 13843(line=426, offs=15) -- 13888(line=426, offs=60) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_whnf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_whnf: tmp209 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) ; return (tmp209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_whnf] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 13979(line=433, offs=5) -- 15127(line=470, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_nfapp_flag_18 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_bool_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_int_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_bool_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_int_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_int_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_bool_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (atsopt_count_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_int_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_bool_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; __ats_lab_s2exp_nfapp_flag_18: tmp211 = s2exp_whnf_flag_12 (arg0, arg1) ; tmp212 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp211), atslab_s2exp_node) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp212)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_7, tmp212, atslab_0) ; tmp214 = ats_caselptrlab_mac(anairiats_sum_7, tmp212, atslab_1) ; tmp215 = ats_ptrget_mac(ats_int_type, arg1) ; tmp216 = s2explst_nfapp_flag_19 (tmp214, arg1) ; tmp217 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp215) ; if (tmp217) { tmp218 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp211), atslab_s2exp_srt) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp218, tmp213, tmp216) ; } else { tmp210 = tmp211 ; } /* end of [if] */ break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp212)->tag != 26) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp219 = ats_caselptrlab_mac(anairiats_sum_7, tmp212, atslab_0) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_7, tmp212, atslab_1) ; tmp221 = ats_ptrget_mac(ats_int_type, arg1) ; tmp222 = s2exp_nfapp_flag_18 (tmp219, arg1) ; tmp223 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp221) ; if (tmp223) { tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp222, tmp220) ; } else { tmp210 = tmp211 ; } /* end of [if] */ break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp212)->tag != 29) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp224 = ats_caselptrlab_mac(anairiats_sum_5, tmp212, atslab_0) ; tmp225 = ats_caselptrlab_mac(anairiats_sum_5, tmp212, atslab_1) ; tmp226 = ats_caselptrlab_mac(anairiats_sum_5, tmp212, atslab_2) ; tmp227 = ats_ptrget_mac(ats_int_type, arg1) ; tmp228 = labs2explst_nfapp_flag_20 (tmp226, arg1) ; tmp229 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp227) ; if (tmp229) { tmp230 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp211), atslab_s2exp_srt) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp230, tmp224, tmp225, tmp228) ; } else { tmp210 = tmp211 ; } /* end of [if] */ break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp212)->tag != 31) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp231 = ats_caselptrlab_mac(anairiats_sum_6, tmp212, atslab_0) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_6, tmp212, atslab_1) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_6, tmp212, atslab_2) ; tmp234 = ats_ptrget_mac(ats_int_type, arg1) ; tmp235 = labs2explst_nfapp_flag_20 (tmp233, arg1) ; tmp236 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp234) ; if (tmp236) { tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp211), atslab_s2exp_srt) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp237, tmp231, tmp232, tmp235) ; } else { tmp210 = tmp211 ; } /* end of [if] */ break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp210 = tmp211 ; break ; } while (0) ; return (tmp210) ; } /* end of [s2exp_nfapp_flag_18] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 15162(line=472, offs=5) -- 15508(line=482, offs=21) */ ATSstaticdec() ats_ptr_type s2explst_nfapp_flag_19 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_int_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_bool_type, tmp244) ; __ats_lab_s2explst_nfapp_flag_19: do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp240 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp241 = ats_ptrget_mac(ats_int_type, arg1) ; tmp242 = s2exp_nfapp_flag_18 (tmp239, arg1) ; tmp243 = s2explst_nfapp_flag_19 (tmp240, arg1) ; tmp244 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp241) ; if (tmp244) { tmp238 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp238, atslab_0, tmp242) ; ats_selptrset_mac(anairiats_sum_8, tmp238, atslab_1, tmp243) ; } else { tmp238 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_65_1: tmp238 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp238) ; } /* end of [s2explst_nfapp_flag_19] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 15546(line=485, offs=5) -- 15966(line=496, offs=43) */ ATSstaticdec() ats_ptr_type labs2explst_nfapp_flag_20 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_int_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_bool_type, tmp252) ; __ats_lab_labs2explst_nfapp_flag_20: do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp247 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp249 = ats_ptrget_mac(ats_int_type, arg1) ; tmp250 = s2exp_nfapp_flag_18 (tmp247, arg1) ; tmp251 = labs2explst_nfapp_flag_20 (tmp248, arg1) ; tmp252 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg1), tmp249) ; if (tmp252) { tmp245 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp245, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_4, tmp245, atslab_1, tmp250) ; ats_selptrset_mac(anairiats_sum_4, tmp245, atslab_2, tmp251) ; } else { tmp245 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: tmp245 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp245) ; } /* end of [labs2explst_nfapp_flag_20] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16025(line=500, offs=13) -- 16094(line=502, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_nfapp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_int_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_nfapp: /* ats_int_type tmp254 ; */ tmp254 = 0 ; tmp253 = s2exp_nfapp_flag_18 (arg0, (&tmp254)) ; return (tmp253) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_nfapp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16145(line=505, offs=16) -- 16219(line=507, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_nfapp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_int_type, tmp256) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_nfapp: /* ats_int_type tmp256 ; */ tmp256 = 0 ; tmp255 = s2explst_nfapp_flag_19 (arg0, (&tmp256)) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_nfapp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16491(line=519, offs=20) -- 16536(line=519, offs=65) */ ATSstaticdec() ats_ptr_type __ats_fun_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; __ats_lab___ats_fun_24: tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (arg0) ; tmp262 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp263) ; return (tmp262) ; } /* end of [__ats_fun_24] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16272(line=511, offs=4) -- 16748(line=527, offs=4) */ ATSstaticdec() anairiats_rec_0 etaexpand_s2exp_s2exp_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; __ats_lab_etaexpand_s2exp_s2exp_23: tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_srt) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp258)->tag != 1) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp259 = ats_caselptrlab_mac(anairiats_sum_7, tmp258, atslab_0) ; tmp260 = ats_caselptrlab_mac(anairiats_sum_7, tmp258, atslab_1) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp259, &__ats_fun_24) ; tmp264 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp260, arg0, tmp261) ; tmp265 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp260, arg1, tmp261) ; tmp257.atslab_0 = tmp264 ; tmp257.atslab_1 = tmp265 ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: tmp257.atslab_0 = arg0 ; tmp257.atslab_1 = arg1 ; break ; } while (0) ; return (tmp257) ; } /* end of [etaexpand_s2exp_s2exp_23] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16776(line=529, offs=4) -- 16864(line=530, offs=56) */ ATSstaticdec() ats_bool_type islam_s2exp_25 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; __ats_lab_islam_s2exp_25: tmp267 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp267)->tag != 14) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp266 = ats_true_bool ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp266 = ats_false_bool ; break ; } while (0) ; return (tmp266) ; } /* end of [islam_s2exp_25] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 16893(line=533, offs=4) -- 17005(line=535, offs=58) */ ATSstaticdec() ats_bool_type islam_s2exp_s2exp_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp268) ; ATSlocal (ats_bool_type, tmp269) ; __ats_lab_islam_s2exp_s2exp_26: tmp269 = islam_s2exp_25 (arg0) ; if (tmp269) { tmp268 = ats_true_bool ; } else { tmp268 = islam_s2exp_25 (arg1) ; } /* end of [if] */ return (tmp268) ; } /* end of [islam_s2exp_s2exp_26] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 17062(line=540, offs=5) -- 17424(line=548, offs=4) */ ATSstaticdec() ats_bool_type s2eff_syneq_27 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp270) ; ATSlocal (ats_uint_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_uint_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_bool_type, tmp275) ; __ats_lab_s2eff_syneq_27: do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_75_1 ; } __ats_lab_72_2: tmp270 = ats_true_bool ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_74_0 ; } __ats_lab_73_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_75_1 ; } __ats_lab_73_2: tmp270 = ats_true_bool ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_75_0 ; } __ats_lab_74_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_75_1 ; } __ats_lab_74_2: tmp271 = ats_caselptrlab_mac(anairiats_sum_14, arg0, atslab_0) ; tmp272 = ats_caselptrlab_mac(anairiats_sum_14, arg0, atslab_1) ; tmp273 = ats_caselptrlab_mac(anairiats_sum_14, arg1, atslab_0) ; tmp274 = ats_caselptrlab_mac(anairiats_sum_14, arg1, atslab_1) ; tmp275 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset (tmp271, tmp273) ; if (tmp275) { tmp270 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp272, tmp274) ; } else { tmp270 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: __ats_lab_75_2: tmp270 = ats_false_bool ; break ; } while (0) ; return (tmp270) ; } /* end of [s2eff_syneq_27] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 17448(line=550, offs=5) -- 17828(line=561, offs=4) */ ATSstaticdec() ats_bool_type labs2explst_syneq_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_bool_type, tmp283) ; ATSlocal (ats_bool_type, tmp284) ; __ats_lab_labs2explst_syneq_28: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_78_1 ; } __ats_lab_76_2: tmp277 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp278 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp279 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp280 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp284 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp277, tmp280) ; if (tmp284) { tmp283 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp278, tmp281) ; } else { tmp283 = ats_false_bool ; } /* end of [if] */ if (tmp283) { arg0 = tmp279 ; arg1 = tmp282 ; goto __ats_lab_labs2explst_syneq_28 ; // tail call } else { tmp276 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_78_1 ; } __ats_lab_77_2: tmp276 = ats_true_bool ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: __ats_lab_78_1: __ats_lab_78_2: tmp276 = ats_false_bool ; break ; } while (0) ; return (tmp276) ; } /* end of [labs2explst_syneq_28] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 17882(line=564, offs=13) -- 24560(line=732, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_bool_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_bool_type, tmp295) ; ATSlocal (ats_char_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_char_type, tmp298) ; ATSlocal (ats_int_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_int_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_bool_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_bool_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_bool_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_bool_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_int_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_int_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_int_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_bool_type, tmp342) ; ATSlocal (ats_bool_type, tmp343) ; ATSlocal (ats_bool_type, tmp344) ; ATSlocal (ats_bool_type, tmp345) ; ATSlocal (ats_bool_type, tmp346) ; ATSlocal (ats_int_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_int_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_int_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_bool_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_bool_type, tmp369) ; ATSlocal (ats_int_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_int_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_bool_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_int_type, tmp380) ; ATSlocal (ats_bool_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_int_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_int_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_bool_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_bool_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_bool_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_int_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_bool_type, tmp419) ; ATSlocal (ats_bool_type, tmp420) ; ATSlocal (atsopt_count_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (atsopt_count_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_bool_type, tmp428) ; ATSlocal (ats_bool_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_bool_type, tmp436) ; ATSlocal (anairiats_rec_0, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq: tmp286 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp288 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp286), atslab_s2exp_node) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp289 = atsopt_eqref_s2exp_s2exp (tmp286, tmp287) ; if (!tmp289) { goto __ats_lab_80_0 ; } tmp285 = ats_true_bool ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp288)->tag != 0) { goto __ats_lab_83_0 ; } __ats_lab_80_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp292)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_7, tmp292, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_7, tmp292, atslab_1) ; tmp295 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp290, tmp293) ; if (tmp295) { tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp291, tmp294) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp288)->tag != 1) { goto __ats_lab_86_0 ; } __ats_lab_83_1: tmp296 = ats_caselptrlab_mac(anairiats_sum_15, tmp288, atslab_0) ; tmp297 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp297)->tag != 1) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp298 = ats_caselptrlab_mac(anairiats_sum_15, tmp297, atslab_0) ; tmp285 = atspre_eq_char_char (tmp296, tmp298) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp288)->tag != 2) { goto __ats_lab_89_0 ; } __ats_lab_86_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_0) ; tmp300 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_1) ; tmp301 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp301)->tag != 2) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp302 = ats_caselptrlab_mac(anairiats_sum_9, tmp301, atslab_0) ; tmp303 = ats_caselptrlab_mac(anairiats_sum_9, tmp301, atslab_1) ; tmp304 = atspre_eq_int_int (tmp299, tmp302) ; if (tmp304) { arg0 = tmp300 ; arg1 = tmp303 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: __ats_lab_88_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp288)->tag != 4) { goto __ats_lab_92_0 ; } __ats_lab_89_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp306 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp306)->tag != 4) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp307 = ats_caselptrlab_mac(anairiats_sum_2, tmp306, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp305, tmp307) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp288)->tag != 5) { goto __ats_lab_95_0 ; } __ats_lab_92_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp310 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp310)->tag != 5) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp311 = ats_caselptrlab_mac(anairiats_sum_7, tmp310, atslab_0) ; tmp312 = ats_caselptrlab_mac(anairiats_sum_7, tmp310, atslab_1) ; tmp313 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp308, tmp311) ; if (tmp313) { tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp309, tmp312) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: __ats_lab_94_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp288)->tag != 6) { goto __ats_lab_98_0 ; } __ats_lab_95_1: tmp314 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp315 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp316 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp316)->tag != 6) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp317 = ats_caselptrlab_mac(anairiats_sum_7, tmp316, atslab_0) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_7, tmp316, atslab_1) ; tmp319 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp314, tmp317) ; if (tmp319) { tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp315, tmp318) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp288)->tag != 7) { goto __ats_lab_101_0 ; } __ats_lab_98_1: tmp320 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp321 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp321)->tag != 7) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_2, tmp321, atslab_0) ; tmp285 = s2eff_syneq_27 (tmp320, tmp322) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp288)->tag != 8) { goto __ats_lab_104_0 ; } __ats_lab_101_1: tmp323 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp324 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp325 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp325)->tag != 8) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_7, tmp325, atslab_0) ; tmp327 = ats_caselptrlab_mac(anairiats_sum_7, tmp325, atslab_1) ; tmp328 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp323, tmp326) ; if (tmp328) { arg0 = tmp324 ; arg1 = tmp327 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: __ats_lab_103_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp288)->tag != 11) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp329 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_0) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_1) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_2) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_3) ; tmp333 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_4) ; tmp334 = ats_caselptrlab_mac(anairiats_sum_10, tmp288, atslab_5) ; tmp335 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp335)->tag != 11) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp336 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_0) ; tmp337 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_1) ; tmp338 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_2) ; tmp339 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_3) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_4) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_10, tmp335, atslab_5) ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo (tmp329, tmp336) ; if (tmp346) { tmp345 = atspre_eq_int_int (tmp330, tmp337) ; } else { tmp345 = ats_false_bool ; } /* end of [if] */ if (tmp345) { tmp344 = s2eff_syneq_27 (tmp331, tmp338) ; } else { tmp344 = ats_false_bool ; } /* end of [if] */ if (tmp344) { tmp343 = atspre_eq_int_int (tmp332, tmp339) ; } else { tmp343 = ats_false_bool ; } /* end of [if] */ if (tmp343) { tmp342 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp333, tmp340) ; } else { tmp342 = ats_false_bool ; } /* end of [if] */ if (tmp342) { arg0 = tmp334 ; arg1 = tmp341 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)tmp288)->tag != 12) { goto __ats_lab_111_0 ; } __ats_lab_107_1: tmp347 = ats_caselptrlab_mac(anairiats_sum_16, tmp288, atslab_0) ; tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)tmp348)->tag != 12) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_16, tmp348, atslab_0) ; tmp285 = atspre_eq_int_int (tmp347, tmp349) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp348)->tag != 13) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp285 = atsopt_eq_int_intinf (tmp347, tmp350) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: __ats_lab_110_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp288)->tag != 13) { goto __ats_lab_115_0 ; } __ats_lab_111_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp352 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp352)->tag != 12) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_16, tmp352, atslab_0) ; tmp285 = atsopt_eq_intinf_int (tmp351, tmp353) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp352)->tag != 13) { goto __ats_lab_114_0 ; } __ats_lab_113_1: tmp354 = ats_caselptrlab_mac(anairiats_sum_2, tmp352, atslab_0) ; tmp285 = atsopt_eq_intinf_intinf (tmp351, tmp354) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp288)->tag != 17) { goto __ats_lab_118_0 ; } __ats_lab_115_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp356 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp356)->tag != 17) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_2, tmp356, atslab_0) ; arg0 = tmp355 ; arg1 = tmp357 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: __ats_lab_117_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: if (((ats_sum_ptr_type)tmp288)->tag != 18) { goto __ats_lab_121_0 ; } __ats_lab_118_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp360 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)tmp360)->tag != 18) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp361 = ats_caselptrlab_mac(anairiats_sum_7, tmp360, atslab_0) ; tmp362 = ats_caselptrlab_mac(anairiats_sum_7, tmp360, atslab_1) ; tmp363 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp358, tmp361) ; if (tmp363) { tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lab_syneq (tmp359, tmp362) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: __ats_lab_120_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: if (((ats_sum_ptr_type)tmp288)->tag != 19) { goto __ats_lab_124_0 ; } __ats_lab_121_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp366 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp366)->tag != 19) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp367 = ats_caselptrlab_mac(anairiats_sum_7, tmp366, atslab_0) ; tmp368 = ats_caselptrlab_mac(anairiats_sum_7, tmp366, atslab_1) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp364, tmp367) ; if (tmp369) { arg0 = tmp365 ; arg1 = tmp368 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: __ats_lab_123_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp288)->tag != 20) { goto __ats_lab_127_0 ; } __ats_lab_124_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_0) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_1) ; tmp372 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp372)->tag != 20) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_9, tmp372, atslab_0) ; tmp374 = ats_caselptrlab_mac(anairiats_sum_9, tmp372, atslab_1) ; tmp375 = atspre_eq_int_int (tmp370, tmp373) ; if (tmp375) { arg0 = tmp371 ; arg1 = tmp374 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: if (((ats_sum_ptr_type)tmp288)->tag != 21) { goto __ats_lab_130_0 ; } __ats_lab_127_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_13, tmp288, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_13, tmp288, atslab_1) ; tmp378 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)tmp378)->tag != 21) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp379 = ats_caselptrlab_mac(anairiats_sum_13, tmp378, atslab_0) ; tmp380 = ats_caselptrlab_mac(anairiats_sum_13, tmp378, atslab_1) ; tmp381 = atspre_eq_int_int (tmp377, tmp380) ; if (tmp381) { arg0 = tmp376 ; arg1 = tmp379 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: __ats_lab_129_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp288)->tag != 22) { goto __ats_lab_133_0 ; } __ats_lab_130_1: tmp382 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp383 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp383)->tag != 22) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp384 = ats_caselptrlab_mac(anairiats_sum_2, tmp383, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp382, tmp384) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: __ats_lab_132_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp288)->tag != 23) { goto __ats_lab_136_0 ; } __ats_lab_133_1: tmp385 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp386 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp386)->tag != 23) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_2, tmp386, atslab_0) ; arg0 = tmp385 ; arg1 = tmp387 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp288)->tag != 24) { goto __ats_lab_139_0 ; } __ats_lab_136_1: tmp388 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_0) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_9, tmp288, atslab_1) ; tmp390 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp390)->tag != 24) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp391 = ats_caselptrlab_mac(anairiats_sum_9, tmp390, atslab_0) ; tmp392 = ats_caselptrlab_mac(anairiats_sum_9, tmp390, atslab_1) ; tmp393 = atspre_eq_int_int (tmp388, tmp391) ; if (tmp393) { arg0 = tmp389 ; arg1 = tmp392 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: __ats_lab_138_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp288)->tag != 25) { goto __ats_lab_142_0 ; } __ats_lab_139_1: tmp394 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp395 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp395)->tag != 25) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp396 = ats_caselptrlab_mac(anairiats_sum_2, tmp395, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp394, tmp396) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: __ats_lab_141_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp288)->tag != 28) { goto __ats_lab_145_0 ; } __ats_lab_142_1: tmp397 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp398 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp398)->tag != 28) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp399 = ats_caselptrlab_mac(anairiats_sum_2, tmp398, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp397, tmp399) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: __ats_lab_144_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp288)->tag != 26) { goto __ats_lab_148_0 ; } __ats_lab_145_1: tmp400 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_0) ; tmp401 = ats_caselptrlab_mac(anairiats_sum_7, tmp288, atslab_1) ; tmp402 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp402)->tag != 26) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_7, tmp402, atslab_0) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_7, tmp402, atslab_1) ; tmp405 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp400, tmp403) ; if (tmp405) { tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq (tmp401, tmp404) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: __ats_lab_147_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: if (((ats_sum_ptr_type)tmp288)->tag != 27) { goto __ats_lab_151_0 ; } __ats_lab_148_1: tmp406 = ats_caselptrlab_mac(anairiats_sum_17, tmp288, atslab_1) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_17, tmp288, atslab_2) ; tmp408 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)tmp408)->tag != 27) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp409 = ats_caselptrlab_mac(anairiats_sum_17, tmp408, atslab_1) ; tmp410 = ats_caselptrlab_mac(anairiats_sum_17, tmp408, atslab_2) ; tmp411 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp406, tmp409) ; if (tmp411) { arg0 = tmp407 ; arg1 = tmp410 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: __ats_lab_150_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp288)->tag != 29) { goto __ats_lab_154_0 ; } __ats_lab_151_1: tmp412 = ats_caselptrlab_mac(anairiats_sum_5, tmp288, atslab_0) ; tmp413 = ats_caselptrlab_mac(anairiats_sum_5, tmp288, atslab_1) ; tmp414 = ats_caselptrlab_mac(anairiats_sum_5, tmp288, atslab_2) ; tmp415 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp415)->tag != 29) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp416 = ats_caselptrlab_mac(anairiats_sum_5, tmp415, atslab_0) ; tmp417 = ats_caselptrlab_mac(anairiats_sum_5, tmp415, atslab_1) ; tmp418 = ats_caselptrlab_mac(anairiats_sum_5, tmp415, atslab_2) ; tmp420 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind (tmp412, tmp416) ; if (tmp420) { tmp419 = atspre_eq_int_int (tmp413, tmp417) ; } else { tmp419 = ats_false_bool ; } /* end of [if] */ if (tmp419) { tmp285 = labs2explst_syneq_28 (tmp414, tmp418) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: __ats_lab_153_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp288)->tag != 31) { goto __ats_lab_157_0 ; } __ats_lab_154_1: tmp421 = ats_caselptrlab_mac(anairiats_sum_6, tmp288, atslab_0) ; tmp422 = ats_caselptrlab_mac(anairiats_sum_6, tmp288, atslab_1) ; tmp423 = ats_caselptrlab_mac(anairiats_sum_6, tmp288, atslab_2) ; tmp424 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp424)->tag != 31) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_6, tmp424, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_6, tmp424, atslab_1) ; tmp427 = ats_caselptrlab_mac(anairiats_sum_6, tmp424, atslab_2) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp421, tmp425) ; if (tmp429) { tmp428 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp422, tmp426) ; } else { tmp428 = ats_false_bool ; } /* end of [if] */ if (tmp428) { tmp285 = labs2explst_syneq_28 (tmp423, tmp427) ; } else { tmp285 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: __ats_lab_156_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp288)->tag != 32) { goto __ats_lab_160_0 ; } __ats_lab_157_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp431 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp431)->tag != 32) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp432 = ats_caselptrlab_mac(anairiats_sum_2, tmp431, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (tmp430, tmp432) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: __ats_lab_159_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp288)->tag != 33) { goto __ats_lab_163_0 ; } __ats_lab_160_1: tmp433 = ats_caselptrlab_mac(anairiats_sum_2, tmp288, atslab_0) ; tmp434 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp287), atslab_s2exp_node) ; do { /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp434)->tag != 33) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_2, tmp434, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var (tmp433, tmp435) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: __ats_lab_162_1: tmp285 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: __ats_lab_163_1: tmp436 = islam_s2exp_s2exp_26 (tmp286, tmp287) ; if (!tmp436) { goto __ats_lab_164_1 ; } tmp437 = etaexpand_s2exp_s2exp_23 (tmp286, tmp287) ; tmp438 = ats_select_mac(tmp437, atslab_0) ; tmp439 = ats_select_mac(tmp437, atslab_1) ; arg0 = tmp438 ; arg1 = tmp439 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq ; // tail call break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: __ats_lab_164_1: tmp285 = ats_false_bool ; break ; } while (0) ; return (tmp285) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 24611(line=735, offs=16) -- 24872(line=742, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_bool_type, tmp445) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq: do { /* branch: __ats_lab_165 */ __ats_lab_165_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_166_0 ; } __ats_lab_165_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_167_1 ; } __ats_lab_165_2: tmp441 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp442 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp443 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp444 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp441, tmp443) ; if (tmp445) { arg0 = tmp442 ; arg1 = tmp444 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq ; // tail call } else { tmp440 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_167_0 ; } __ats_lab_166_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_167_1 ; } __ats_lab_166_2: tmp440 = ats_true_bool ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: __ats_lab_167_1: __ats_lab_167_2: tmp440 = ats_false_bool ; break ; } while (0) ; return (tmp440) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 24929(line=745, offs=19) -- 25208(line=752, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_bool_type, tmp451) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq: do { /* branch: __ats_lab_168 */ __ats_lab_168_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_169_0 ; } __ats_lab_168_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_170_1 ; } __ats_lab_168_2: tmp447 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp448 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp449 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp450 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp451 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_syneq (tmp447, tmp449) ; if (tmp451) { arg0 = tmp448 ; arg1 = tmp450 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq ; // tail call } else { tmp446 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_170_0 ; } __ats_lab_169_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_170_1 ; } __ats_lab_169_2: tmp446 = ats_true_bool ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: __ats_lab_170_1: __ats_lab_170_2: tmp446 = ats_false_bool ; break ; } while (0) ; return (tmp446) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 25265(line=756, offs=5) -- 25714(line=768, offs=4) */ ATSstaticdec() ats_bool_type labs2zexplst_syneq_32 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_bool_type, tmp459) ; ATSlocal (ats_bool_type, tmp460) ; __ats_lab_labs2zexplst_syneq_32: do { /* branch: __ats_lab_171 */ __ats_lab_171_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_172_0 ; } __ats_lab_171_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_173_1 ; } __ats_lab_171_2: tmp453 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp454 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp455 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp456 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp458 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp453, tmp456) ; if (tmp460) { tmp459 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp454, tmp457) ; } else { tmp459 = ats_false_bool ; } /* end of [if] */ if (tmp459) { arg0 = tmp455 ; arg1 = tmp458 ; goto __ats_lab_labs2zexplst_syneq_32 ; // tail call } else { tmp452 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_173_0 ; } __ats_lab_172_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_173_1 ; } __ats_lab_172_2: tmp452 = ats_true_bool ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: __ats_lab_173_1: __ats_lab_173_2: tmp452 = ats_false_bool ; break ; } while (0) ; return (tmp452) ; } /* end of [labs2zexplst_syneq_32] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 25751(line=770, offs=5) -- 26073(line=778, offs=20) */ ATSstaticdec() ats_bool_type s2zexplst_syneq_33 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_bool_type, tmp466) ; __ats_lab_s2zexplst_syneq_33: do { /* branch: __ats_lab_174 */ __ats_lab_174_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_175_0 ; } __ats_lab_174_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_176_1 ; } __ats_lab_174_2: tmp462 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp463 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp464 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp465 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp466 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp462, tmp464) ; if (tmp466) { arg0 = tmp463 ; arg1 = tmp465 ; goto __ats_lab_s2zexplst_syneq_33 ; // tail call } else { tmp461 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_176_0 ; } __ats_lab_175_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_176_1 ; } __ats_lab_175_2: tmp461 = ats_true_bool ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: __ats_lab_176_1: __ats_lab_176_2: tmp461 = ats_false_bool ; break ; } while (0) ; return (tmp461) ; } /* end of [s2zexplst_syneq_33] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 26142(line=782, offs=14) -- 27943(line=831, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_bool_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_bool_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_bool_type, tmp486) ; ATSlocal (atsopt_count_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (atsopt_count_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_bool_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq: do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_180_0 ; } __ats_lab_177_1: tmp468 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp469 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; do { /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp470 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp471 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp472 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp468, tmp470) ; if (tmp472) { tmp467 = s2zexplst_syneq_33 (tmp469, tmp471) ; } else { tmp467 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: __ats_lab_179_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp467 = ats_false_bool ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_184_0 ; } __ats_lab_181_1: tmp473 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; do { /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp474 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp473, tmp474) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: __ats_lab_183_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_187_0 ; } __ats_lab_184_1: tmp475 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp476 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp467 = atspre_eq_string_string (tmp475, tmp476) ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: __ats_lab_186_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_190_0 ; } __ats_lab_187_1: do { /* branch: __ats_lab_188 */ __ats_lab_188_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_189_0 ; } __ats_lab_188_1: tmp467 = ats_true_bool ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: __ats_lab_189_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_193_0 ; } __ats_lab_190_1: tmp477 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp478 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp479 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp480 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp481 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp477, tmp479) ; if (tmp481) { tmp467 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq (tmp478, tmp480) ; } else { tmp467 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: __ats_lab_192_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_196_0 ; } __ats_lab_193_1: tmp482 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp483 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; do { /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp486 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind (tmp482, tmp484) ; if (tmp486) { tmp467 = labs2zexplst_syneq_32 (tmp483, tmp485) ; } else { tmp467 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: __ats_lab_195_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_199_0 ; } __ats_lab_196_1: tmp487 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_0) ; tmp488 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_1) ; do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_18, arg1, atslab_0) ; tmp490 = ats_caselptrlab_mac(anairiats_sum_18, arg1, atslab_1) ; tmp491 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp487, tmp489) ; if (tmp491) { tmp467 = labs2zexplst_syneq_32 (tmp488, tmp490) ; } else { tmp467 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: __ats_lab_198_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: // if (((ats_sum_ptr_type)arg0)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_199_1: tmp492 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; do { /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp493 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp467 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (tmp492, tmp493) ; break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: __ats_lab_201_1: tmp467 = ats_false_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp467) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 28015(line=836, offs=15) -- 28138(line=839, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst: do { /* branch: __ats_lab_202 */ __ats_lab_202_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_203_0 ; } __ats_lab_202_1: tmp495 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp496 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp497 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj (arg0, tmp495) ; arg0 = tmp497 ; arg1 = tmp496 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst ; // tail call break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_203_1: tmp494 = arg0 ; break ; } while (0) ; return (tmp494) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 28216(line=843, offs=7) -- 28391(line=848, offs=24) */ ATSstaticdec() anairiats_rec_0 aux_37 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; __ats_lab_aux_37: tmp500 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp500)->tag != 18) { goto __ats_lab_205_0 ; } __ats_lab_204_1: tmp501 = ats_caselptrlab_mac(anairiats_sum_7, tmp500, atslab_0) ; tmp502 = ats_caselptrlab_mac(anairiats_sum_7, tmp500, atslab_1) ; tmp503 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp503, atslab_0, tmp502) ; ats_selptrset_mac(anairiats_sum_8, tmp503, atslab_1, arg1) ; arg0 = tmp501 ; arg1 = tmp503 ; goto __ats_lab_aux_37 ; // tail call break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: __ats_lab_205_1: tmp499.atslab_0 = arg0 ; tmp499.atslab_1 = arg1 ; break ; } while (0) ; return (tmp499) ; } /* end of [aux_37] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 28197(line=842, offs=22) -- 28451(line=852, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp498) ; ATSlocal (ats_ptr_type, tmp504) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize: tmp504 = (ats_sum_ptr_type)0 ; tmp498 = aux_37 (arg0, tmp504) ; return (tmp498) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 28511(line=856, offs=5) -- 30191(line=899, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_prenexing_38 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_bool_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_int_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_bool_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; // ATSlocal_void (tmp521) ; // ATSlocal_void (tmp522) ; // ATSlocal_void (tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_int_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_int_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_bool_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; __ats_lab_s2exp_prenexing_38: tmp506 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp507 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp506), atslab_s2exp_node) ; do { /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp507)->tag != 0) { goto __ats_lab_209_0 ; } __ats_lab_206_1: tmp508 = ats_caselptrlab_mac(anairiats_sum_7, tmp507, atslab_0) ; tmp509 = ats_caselptrlab_mac(anairiats_sum_7, tmp507, atslab_1) ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view, tmp508) ; if (tmp510) { do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (tmp509 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } tmp511 = ats_caselptrlab_mac(anairiats_sum_8, tmp509, atslab_1) ; if (tmp511 == (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } tmp512 = ats_caselptrlab_mac(anairiats_sum_8, tmp511, atslab_1) ; if (tmp512 != (ats_sum_ptr_type)0) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp513 = ats_caselptrlab_mac(anairiats_sum_8, tmp509, atslab_0) ; tmp514 = ats_caselptrlab_mac(anairiats_sum_8, tmp511, atslab_0) ; tmp515 = ats_ptrget_mac(ats_int_type, arg4) ; tmp516 = s2exp_prenexing_38 (arg0, tmp513, arg2, arg3, arg4) ; tmp517 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg4), tmp515) ; if (tmp517) { tmp520 = (ats_sum_ptr_type)0 ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp519, atslab_0, tmp514) ; ats_selptrset_mac(anairiats_sum_8, tmp519, atslab_1, tmp520) ; tmp518 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp518, atslab_0, tmp516) ; ats_selptrset_mac(anairiats_sum_8, tmp518, atslab_1, tmp519) ; tmp505 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view, tmp508, tmp518) ; } else { tmp505 = tmp506 ; } /* end of [if] */ break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: __ats_lab_208_1: /* tmp521 = */ prerr_interror_1 () ; /* tmp522 = */ atspre_prerr_string (ATSstrcst(": s2exp_prenexing: At_viewt0ype_addr_view")) ; /* tmp523 = */ atspre_prerr_newline () ; /* tmp505 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { tmp505 = tmp506 ; } /* end of [if] */ break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)tmp507)->tag != 9) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp524 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_0) ; tmp525 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_1) ; tmp526 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_2) ; if (arg0) { tmp505 = s2exp_prenexing_main_39 (arg0, tmp524, tmp525, tmp526, arg2, arg3, arg4) ; } else { tmp505 = tmp506 ; } /* end of [if] */ break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)tmp507)->tag != 29) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp527 = ats_caselptrlab_mac(anairiats_sum_5, tmp507, atslab_0) ; tmp528 = ats_caselptrlab_mac(anairiats_sum_5, tmp507, atslab_1) ; tmp529 = ats_caselptrlab_mac(anairiats_sum_5, tmp507, atslab_2) ; tmp530 = ats_ptrget_mac(ats_int_type, arg4) ; tmp531 = labs2explst_prenexing_41 (arg0, tmp529, arg2, arg3, arg4) ; tmp532 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg4), tmp530) ; if (tmp532) { tmp533 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp506), atslab_s2exp_srt) ; tmp505 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp533, tmp527, tmp528, tmp531) ; } else { tmp505 = tmp506 ; } /* end of [if] */ break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp507)->tag != 30) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp534 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_0) ; tmp535 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_1) ; tmp536 = ats_caselptrlab_mac(anairiats_sum_12, tmp507, atslab_2) ; if (arg0) { tmp505 = tmp506 ; } else { tmp505 = s2exp_prenexing_main_39 (arg0, tmp534, tmp535, tmp536, arg2, arg3, arg4) ; } /* end of [if] */ break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: __ats_lab_212_1: tmp505 = tmp506 ; break ; } while (0) ; return (tmp505) ; } /* end of [s2exp_prenexing_38] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 30225(line=901, offs=5) -- 30760(line=915, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_prenexing_main_39 (ats_bool_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ref_type arg5, ats_ref_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (anairiats_rec_0, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_int_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; __ats_lab_s2exp_prenexing_main_39: tmp538 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil, arg1) ; tmp539 = ats_select_mac(tmp538, atslab_0) ; tmp540 = ats_select_mac(tmp538, atslab_1) ; tmp541 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp539, arg2) ; tmp542 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp539, arg3) ; tmp543 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg6), 1) ; ats_ptrget_mac(ats_int_type, arg6) = tmp543 ; tmp544 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp (tmp540, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp544 ; tmp545 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp (tmp541, ats_ptrget_mac(ats_ptr_type, arg5)) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp545 ; tmp537 = s2exp_prenexing_38 (arg0, tmp542, arg4, arg5, arg6) ; return (tmp537) ; } /* end of [s2exp_prenexing_main_39] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 30799(line=917, offs=5) -- 31250(line=931, offs=4) */ ATSstaticdec() ats_ptr_type s2explst_prenexing_40 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_int_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_bool_type, tmp552) ; __ats_lab_s2explst_prenexing_40: do { /* branch: __ats_lab_213 */ __ats_lab_213_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp547 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp548 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp549 = ats_ptrget_mac(ats_int_type, arg4) ; tmp550 = s2exp_prenexing_38 (arg0, tmp547, arg2, arg3, arg4) ; tmp551 = s2explst_prenexing_40 (arg0, tmp548, arg2, arg3, arg4) ; tmp552 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg4), tmp549) ; if (tmp552) { tmp546 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp546, atslab_0, tmp550) ; ats_selptrset_mac(anairiats_sum_8, tmp546, atslab_1, tmp551) ; } else { tmp546 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_214_1: tmp546 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp546) ; } /* end of [s2explst_prenexing_40] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 31287(line=933, offs=5) -- 31818(line=947, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_prenexing_41 (ats_bool_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_int_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_bool_type, tmp560) ; __ats_lab_labs2explst_prenexing_41: do { /* branch: __ats_lab_215 */ __ats_lab_215_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp554 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp555 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp556 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp557 = ats_ptrget_mac(ats_int_type, arg4) ; tmp558 = s2exp_prenexing_38 (arg0, tmp555, arg2, arg3, arg4) ; tmp559 = labs2explst_prenexing_41 (arg0, tmp556, arg2, arg3, arg4) ; tmp560 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg4), tmp557) ; if (tmp560) { tmp553 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp553, atslab_0, tmp554) ; ats_selptrset_mac(anairiats_sum_4, tmp553, atslab_1, tmp558) ; ats_selptrset_mac(anairiats_sum_4, tmp553, atslab_2, tmp559) ; } else { tmp553 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_216_1: tmp553 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp553) ; } /* end of [labs2explst_prenexing_41] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 31898(line=952, offs=14) -- 32130(line=958, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_absuni (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp561) ; ATSlocal (ats_int_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_absuni: /* ats_int_type tmp562 ; */ tmp562 = 0 ; /* ats_ptr_type tmp563 ; */ tmp563 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp564 ; */ tmp564 = (ats_sum_ptr_type)0 ; tmp565 = s2exp_prenexing_38 (ats_false_bool, arg0, (&tmp563), (&tmp564), (&tmp562)) ; tmp566 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp563) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp564) ; tmp561.atslab_0 = tmp566 ; tmp561.atslab_1 = tmp567 ; tmp561.atslab_2 = tmp565 ; return (tmp561) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_absuni] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 32180(line=961, offs=14) -- 32411(line=967, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_opnexi (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp568) ; ATSlocal (ats_int_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_opnexi: /* ats_int_type tmp569 ; */ tmp569 = 0 ; /* ats_ptr_type tmp570 ; */ tmp570 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp571 ; */ tmp571 = (ats_sum_ptr_type)0 ; tmp572 = s2exp_prenexing_38 (ats_true_bool, arg0, (&tmp570), (&tmp571), (&tmp569)) ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp570) ; tmp574 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp571) ; tmp568.atslab_0 = tmp573 ; tmp568.atslab_1 = tmp574 ; tmp568.atslab_2 = tmp572 ; return (tmp568) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_opnexi] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 32464(line=970, offs=17) -- 32702(line=976, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_opnexi (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp575) ; ATSlocal (ats_int_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_opnexi: /* ats_int_type tmp576 ; */ tmp576 = 0 ; /* ats_ptr_type tmp577 ; */ tmp577 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp578 ; */ tmp578 = (ats_sum_ptr_type)0 ; tmp579 = s2explst_prenexing_40 (ats_true_bool, arg0, (&tmp577), (&tmp578), (&tmp576)) ; tmp580 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp577) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (tmp578) ; tmp575.atslab_0 = tmp580 ; tmp575.atslab_1 = tmp581 ; tmp575.atslab_2 = tmp579 ; return (tmp575) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_opnexi] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 32809(line=983, offs=7) -- 33057(line=988, offs=38) */ ATSstaticdec() ats_ptr_type aux_get_46 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_bool_type, tmp587) ; __ats_lab_aux_get_46: do { /* branch: __ats_lab_217 */ __ats_lab_217_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp584 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp585 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp586 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp587 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (env0, tmp584) ; if (tmp587) { tmp583 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp583, atslab_0, tmp585) ; } else { arg0 = tmp586 ; goto __ats_lab_aux_get_46 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_218_1: tmp583 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp583) ; } /* end of [aux_get_46] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_get_46_closure_type ; ats_ptr_type aux_get_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_get_46 (((aux_get_46_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_get_46_closure_init (aux_get_46_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_get_46_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_get_46_closure_make (ats_ptr_type env0) { aux_get_46_closure_type *p_clo = ATS_MALLOC(sizeof(aux_get_46_closure_type)) ; aux_get_46_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 32785(line=982, offs=3) -- 33102(line=992, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_get_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp582) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_get_lab: tmp582 = aux_get_46 (arg1, arg0) ; return (tmp582) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_get_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 33196(line=996, offs=7) -- 33707(line=1009, offs=6) */ ATSstaticdec() ats_ptr_type aux_set_48 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_bool_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; __ats_lab_aux_set_48: do { /* branch: __ats_lab_219 */ __ats_lab_219_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_222_0 ; } __ats_lab_219_1: tmp590 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp591 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp593 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (env0, tmp590) ; if (tmp593) { tmp594 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp594, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_4, tmp594, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp594, atslab_2, tmp592) ; tmp589 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp589, atslab_0, tmp594) ; } else { tmp595 = aux_set_48 (env0, tmp592, arg1) ; do { /* branch: __ats_lab_220 */ __ats_lab_220_0: if (tmp595 == (ats_sum_ptr_type)0) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp596 = ats_caselptrlab_mac(anairiats_sum_3, tmp595, atslab_0) ; ATS_FREE(tmp595) ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp597, atslab_0, tmp590) ; ats_selptrset_mac(anairiats_sum_4, tmp597, atslab_1, tmp591) ; ats_selptrset_mac(anairiats_sum_4, tmp597, atslab_2, tmp596) ; tmp589 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp589, atslab_0, tmp597) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: // if (tmp595 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_221_1: tmp589 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_222_1: tmp589 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp589) ; } /* end of [aux_set_48] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_set_48_closure_type ; ats_ptr_type aux_set_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_set_48 (((aux_set_48_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_set_48_closure_init (aux_set_48_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_set_48_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_set_48_closure_make (ats_ptr_type env0) { aux_set_48_closure_type *p_clo = ATS_MALLOC(sizeof(aux_set_48_closure_type)) ; aux_set_48_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 33166(line=995, offs=21) -- 33758(line=1012, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_set_lab (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp588) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_set_lab: tmp588 = aux_set_48 (arg1, arg0, arg2) ; return (tmp588) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_set_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 33869(line=1018, offs=7) -- 34132(line=1024, offs=39) */ ATSstaticdec() ats_ptr_type aux_get_50 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_bool_type, tmp603) ; __ats_lab_aux_get_50: do { /* branch: __ats_lab_223 */ __ats_lab_223_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp600 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp601 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp602 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp603 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (env0, tmp600) ; if (tmp603) { tmp599 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp599, atslab_0, tmp601) ; } else { arg0 = tmp602 ; goto __ats_lab_aux_get_50 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_224_1: tmp599 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp599) ; } /* end of [aux_get_50] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_get_50_closure_type ; ats_ptr_type aux_get_50_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_get_50 (((aux_get_50_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_get_50_closure_init (aux_get_50_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_get_50_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_get_50_closure_make (ats_ptr_type env0) { aux_get_50_closure_type *p_clo = ATS_MALLOC(sizeof(aux_get_50_closure_type)) ; aux_get_50_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 33844(line=1017, offs=22) -- 34178(line=1028, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2zexplst_get_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp598) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2zexplst_get_lab: tmp598 = aux_get_50 (arg1, arg0) ; return (tmp598) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2zexplst_get_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 34342(line=1035, offs=7) -- 34620(line=1043, offs=6) */ ATSstaticdec() ats_ptr_type aux_get_52 (ats_ptr_type env0, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_bool_type, tmp609) ; ATSlocal (ats_int_type, tmp610) ; __ats_lab_aux_get_52: do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp606 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp607 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp608 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp609 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (env0, tmp606) ; if (tmp609) { tmp605 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp605, atslab_0, tmp607) ; } else { tmp610 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg0), 1) ; ats_ptrget_mac(ats_int_type, arg0) = tmp610 ; arg0 = arg0 ; arg1 = tmp608 ; goto __ats_lab_aux_get_52 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_226_1: ats_ptrget_mac(ats_int_type, arg0) = -1 ; tmp605 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp605) ; } /* end of [aux_get_52] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_get_52_closure_type ; ats_ptr_type aux_get_52_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { return aux_get_52 (((aux_get_52_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_get_52_closure_init (aux_get_52_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_get_52_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_get_52_closure_make (ats_ptr_type env0) { aux_get_52_closure_type *p_clo = ATS_MALLOC(sizeof(aux_get_52_closure_type)) ; aux_get_52_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 34237(line=1032, offs=4) -- 34706(line=1048, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_get_lab_ind_51 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp604) ; __ats_lab_labs2explst_get_lab_ind_51: ats_ptrget_mac(ats_int_type, arg2) = 0 ; tmp604 = aux_get_52 (arg1, arg2, arg0) ; return (tmp604) ; } /* end of [labs2explst_get_lab_ind_51] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 34877(line=1053, offs=7) -- 35459(line=1067, offs=6) */ ATSstaticdec() ats_ptr_type aux_set_54 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_bool_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_int_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; __ats_lab_aux_set_54: do { /* branch: __ats_lab_227 */ __ats_lab_227_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } __ats_lab_227_1: tmp613 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp614 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp615 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (env0, tmp613) ; if (tmp616) { tmp617 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp617, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_4, tmp617, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp617, atslab_2, tmp615) ; tmp612 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp612, atslab_0, tmp617) ; } else { tmp618 = aux_set_54 (env0, tmp615, arg1, arg2) ; do { /* branch: __ats_lab_228 */ __ats_lab_228_0: if (tmp618 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp619 = ats_caselptrlab_mac(anairiats_sum_3, tmp618, atslab_0) ; ATS_FREE(tmp618) ; tmp620 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp620 ; tmp621 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp621, atslab_0, tmp613) ; ats_selptrset_mac(anairiats_sum_4, tmp621, atslab_1, tmp614) ; ats_selptrset_mac(anairiats_sum_4, tmp621, atslab_2, tmp619) ; tmp612 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp612, atslab_0, tmp621) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (tmp618 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp612 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_230_1: ats_ptrget_mac(ats_int_type, arg2) = -1 ; tmp612 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp612) ; } /* end of [aux_set_54] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_set_54_closure_type ; ats_ptr_type aux_set_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { return aux_set_54 (((aux_set_54_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux_set_54_closure_init (aux_set_54_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_set_54_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_set_54_closure_make (ats_ptr_type env0) { aux_set_54_closure_type *p_clo = ATS_MALLOC(sizeof(aux_set_54_closure_type)) ; aux_set_54_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 34747(line=1050, offs=4) -- 35533(line=1071, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_lab_set_ind_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp611) ; __ats_lab_labs2explst_lab_set_ind_53: ats_ptrget_mac(ats_int_type, arg3) = 0 ; tmp611 = aux_set_54 (arg1, arg0, arg2, arg3) ; return (tmp611) ; } /* end of [labs2explst_lab_set_ind_53] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 35703(line=1079, offs=6) -- 35947(line=1088, offs=6) */ ATSstaticdec() ats_ptr_type err1_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp624) ; // ATSlocal_void (tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; // ATSlocal_void (tmp628) ; // ATSlocal_void (tmp629) ; // ATSlocal_void (tmp630) ; // ATSlocal_void (tmp631) ; __ats_lab_err1_56: /* tmp625 = */ prerr_loc_error3_0 (arg0) ; /* tmp626 = */ atspre_prerr_string (ATSstrcst(": the label [")) ; /* tmp627 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (arg2) ; /* tmp628 = */ atspre_prerr_string (ATSstrcst("] is not found in [")) ; /* tmp629 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp630 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp631 = */ atspre_prerr_newline () ; /* tmp624 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp624) ; } /* end of [err1_56] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 35969(line=1089, offs=6) -- 36285(line=1097, offs=6) */ ATSstaticdec() ats_varet_type err2_57 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp632) ; // ATSlocal_void (tmp633) ; // ATSlocal_void (tmp634) ; // ATSlocal_void (tmp635) ; // ATSlocal_void (tmp636) ; // ATSlocal_void (tmp637) ; // ATSlocal_void (tmp638) ; __ats_lab_err2_57: /* tmp633 = */ prerr_loc_error3_0 (arg0) ; /* tmp634 = */ atsopt_debug_prerrf (ATSstrcst(": [%s]: s2exp_get_lab_restlin_cstr"), ATSstrcst("ats_staexp2_util2.dats")) ; /* tmp635 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp636 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp637 = */ atspre_prerr_string (ATSstrcst("] is expected to be a record or union but it is not.")) ; /* tmp638 = */ atspre_prerr_newline () ; /* tmp632 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp632) */ ; } /* end of [err2_57] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 36309(line=1098, offs=7) -- 36688(line=1108, offs=30) */ ATSstaticdec() ats_void_type aux_restlin_58 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_bool_type, tmp643) ; ATSlocal (ats_bool_type, tmp644) ; ATSlocal (ats_int_type, tmp645) ; ATSlocal (ats_int_type, tmp646) ; __ats_lab_aux_restlin_58: do { /* branch: __ats_lab_231 */ __ats_lab_231_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp640 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp641 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp643 = atspre_neq_int_int (arg0, 0) ; if (tmp643) { tmp644 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp640) ; if (tmp644) { tmp645 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp645 ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp646 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp646 ; arg1 = tmp641 ; arg2 = arg2 ; goto __ats_lab_aux_restlin_58 ; // tail call break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_232_1: break ; } while (0) ; return /* (tmp639) */ ; } /* end of [aux_restlin_58] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 35631(line=1077, offs=3) -- 37490(line=1131, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_lab_restlin_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_int_type, tmp649) ; ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; // ATSlocal_void (tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_int_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; // ATSlocal_void (tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_lab_restlin_cstr: tmp623 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp647 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp623), atslab_s2exp_node) ; do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)tmp647)->tag != 29) { goto __ats_lab_236_0 ; } __ats_lab_233_1: tmp648 = ats_caselptrlab_mac(anairiats_sum_5, tmp647, atslab_2) ; /* ats_int_type tmp649 ; */ tmp650 = labs2explst_get_lab_ind_51 (tmp648, arg2, (&tmp649)) ; do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (tmp650 == (ats_sum_ptr_type)0) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp651 = ats_caselptrlab_mac(anairiats_sum_3, tmp650, atslab_0) ; ATS_FREE(tmp650) ; /* tmp652 = */ aux_restlin_58 (tmp649, tmp648, arg3) ; tmp622 = tmp651 ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (tmp650 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: tmp622 = err1_56 (arg0, tmp623, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)tmp647)->tag != 31) { goto __ats_lab_239_0 ; } __ats_lab_236_1: tmp653 = ats_caselptrlab_mac(anairiats_sum_6, tmp647, atslab_1) ; tmp654 = ats_caselptrlab_mac(anairiats_sum_6, tmp647, atslab_2) ; /* ats_int_type tmp655 ; */ tmp656 = labs2explst_get_lab_ind_51 (tmp654, arg2, (&tmp655)) ; do { /* branch: __ats_lab_237 */ __ats_lab_237_0: if (tmp656 == (ats_sum_ptr_type)0) { goto __ats_lab_238_0 ; } __ats_lab_237_1: tmp658 = ats_caselptrlab_mac(anairiats_sum_3, tmp656, atslab_0) ; ATS_FREE(tmp656) ; tmp657 = tmp658 ; break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: // if (tmp656 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_238_1: tmp657 = err1_56 (arg0, tmp623, arg2) ; break ; } while (0) ; /* tmp659 = */ aux_restlin_58 (tmp655, tmp654, arg3) ; tmp661 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp655) ; tmp660 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq (tmp653, tmp661) ; tmp662 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp662, atslab_0, tmp660) ; ats_selptrset_mac(anairiats_sum_8, tmp662, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp662 ; tmp622 = tmp657 ; break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: __ats_lab_239_1: /* tmp622 = */ err2_57 (arg0, tmp623) ; break ; } while (0) ; return (tmp622) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_lab_restlin_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 37644(line=1138, offs=7) -- 38571(line=1164, offs=8) */ ATSstaticdec() anairiats_rec_0 aux_60 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; // ATSlocal_void (tmp670) ; // ATSlocal_void (tmp671) ; // ATSlocal_void (tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; __ats_lab_aux_60: do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_244_0 ; } __ats_lab_240_1: tmp665 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp666 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; do { /* branch: __ats_lab_241 */ __ats_lab_241_0: if (((ats_sum_ptr_type)tmp665)->tag != 0) { goto __ats_lab_242_0 ; } __ats_lab_241_1: tmp668 = ats_caselptrlab_mac(anairiats_sum_2, tmp665, atslab_0) ; tmp667 = tmp668 ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: if (((ats_sum_ptr_type)tmp665)->tag != 2) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp669 = ats_caselptrlab_mac(anairiats_sum_7, tmp665, atslab_0) ; tmp667 = tmp669 ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: __ats_lab_243_1: /* tmp670 = */ prerr_loc_error3_0 (env0) ; /* tmp671 = */ atspre_prerr_string (ATSstrcst(": the use of array subscription is not supported.")) ; /* tmp672 = */ atspre_prerr_newline () ; /* tmp667 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp673 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_lab_restlin_cstr (env0, arg0, tmp667, arg2, arg3) ; tmp675 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp675)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp675, atslab_0, tmp667) ; ats_selptrset_mac(anairiats_sum_7, tmp675, atslab_1, arg0) ; tmp674 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp674, atslab_0, tmp675) ; ats_selptrset_mac(anairiats_sum_8, tmp674, atslab_1, arg4) ; arg0 = tmp673 ; arg1 = tmp666 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp674 ; goto __ats_lab_aux_60 ; // tail call break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_244_1: tmp676 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg4) ; tmp664.atslab_0 = arg0 ; tmp664.atslab_1 = tmp676 ; break ; } while (0) ; return (tmp664) ; } /* end of [aux_60] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_60_closure_type ; anairiats_rec_0 aux_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ptr_type arg4) { return aux_60 (((aux_60_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2, arg3, arg4) ; } /* end of function */ ATSinline() ats_void_type aux_60_closure_init (aux_60_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_60_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_60_closure_make (ats_ptr_type env0) { aux_60_closure_type *p_clo = ATS_MALLOC(sizeof(aux_60_closure_type)) ; aux_60_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 37598(line=1137, offs=3) -- 38641(line=1167, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_slablst_restlin_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp663) ; ATSlocal (ats_ptr_type, tmp677) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_slablst_restlin_cstr: tmp677 = (ats_sum_ptr_type)0 ; tmp663 = aux_60 (arg0, arg1, arg2, arg3, arg4, tmp677) ; return (tmp663) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_slablst_restlin_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 38713(line=1171, offs=4) -- 38805(line=1172, offs=57) */ ATSstaticdec() ats_bool_type s2exp_is_int_0_61 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_int_type, tmp680) ; __ats_lab_s2exp_is_int_0_61: tmp679 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_245 */ __ats_lab_245_0: if (((ats_sum_ptr_type)tmp679)->tag != 12) { goto __ats_lab_246_0 ; } __ats_lab_245_1: tmp680 = ats_caselptrlab_mac(anairiats_sum_16, tmp679, atslab_0) ; tmp678 = atspre_eq_int_int (tmp680, 0) ; break ; /* branch: __ats_lab_246 */ __ats_lab_246_0: __ats_lab_246_1: tmp678 = ats_false_bool ; break ; } while (0) ; return (tmp678) ; } /* end of [s2exp_is_int_0_61] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 38835(line=1175, offs=4) -- 38943(line=1176, offs=66) */ ATSstaticdec() ats_ptr_type un_s2exp_int_62 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_int_type, tmp683) ; __ats_lab_un_s2exp_int_62: tmp682 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_247 */ __ats_lab_247_0: if (((ats_sum_ptr_type)tmp682)->tag != 12) { goto __ats_lab_248_0 ; } __ats_lab_247_1: tmp683 = ats_caselptrlab_mac(anairiats_sum_16, tmp682, atslab_0) ; tmp681 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp681, atslab_0, tmp683) ; break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: __ats_lab_248_1: tmp681 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp681) ; } /* end of [un_s2exp_int_62] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 38974(line=1179, offs=5) -- 39400(line=1190, offs=4) */ ATSstaticdec() anairiats_rec_0 labs2explst_get_nth_63 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_bool_type, tmp688) ; ATSlocal (ats_int_type, tmp689) ; // ATSlocal_void (tmp690) ; // ATSlocal_void (tmp691) ; // ATSlocal_void (tmp692) ; // ATSlocal_void (tmp693) ; __ats_lab_labs2explst_get_nth_63: do { /* branch: __ats_lab_249 */ __ats_lab_249_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_250_0 ; } __ats_lab_249_1: tmp685 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp686 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp687 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp688 = atspre_gt_int_int (arg1, 0) ; if (tmp688) { tmp689 = atspre_sub_int_int (arg1, 1) ; arg0 = tmp687 ; arg1 = tmp689 ; goto __ats_lab_labs2explst_get_nth_63 ; // tail call } else { tmp684.atslab_0 = tmp685 ; tmp684.atslab_1 = tmp686 ; } /* end of [if] */ break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_250_1: /* tmp690 = */ prerr_interror_1 () ; /* tmp691 = */ atspre_prerr_string (ATSstrcst(": labs2explst_get_nth: i = ")) ; /* tmp692 = */ atspre_prerr_int (arg1) ; /* tmp693 = */ atspre_prerr_newline () ; /* tmp684 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp684) ; } /* end of [labs2explst_get_nth_63] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 39441(line=1192, offs=5) -- 40000(line=1207, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_nth_set_64 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_bool_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_int_type, tmp700) ; // ATSlocal_void (tmp701) ; // ATSlocal_void (tmp702) ; // ATSlocal_void (tmp703) ; // ATSlocal_void (tmp704) ; __ats_lab_labs2explst_nth_set_64: do { /* branch: __ats_lab_251 */ __ats_lab_251_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_252_0 ; } __ats_lab_251_1: tmp695 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp696 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp697 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp698 = atspre_gt_int_int (arg1, 0) ; if (tmp698) { tmp700 = atspre_sub_int_int (arg1, 1) ; tmp699 = labs2explst_nth_set_64 (tmp697, tmp700, arg2) ; tmp694 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_0, tmp695) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_1, tmp696) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_2, tmp699) ; } else { tmp694 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_0, tmp695) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp694, atslab_2, tmp697) ; } /* end of [if] */ break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_252_1: /* tmp701 = */ prerr_interror_1 () ; /* tmp702 = */ atspre_prerr_string (ATSstrcst(": labs2explst_nth_set: i = ")) ; /* tmp703 = */ atspre_prerr_int (arg1) ; /* tmp704 = */ atspre_prerr_newline () ; /* tmp694 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp694) ; } /* end of [labs2explst_nth_set_64] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 40245(line=1217, offs=7) -- 40818(line=1235, offs=8) */ ATSstaticdec() ats_void_type auxlst_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp706) ; ATSlocal (ats_bool_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; __ats_lab_auxlst_66: tmp707 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg3), 0) ; if (tmp707) { /* empty */ } else { do { /* branch: __ats_lab_253 */ __ats_lab_253_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_254_0 ; } __ats_lab_253_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_255_1 ; } __ats_lab_253_2: tmp708 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp709 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp710 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp711 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp712 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_btw_int_int_int_bool (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0, tmp708, tmp710) ; tmp713 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp713, atslab_0, tmp712) ; ats_selptrset_mac(anairiats_sum_8, tmp713, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp713 ; arg0 = tmp709 ; arg1 = tmp711 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_auxlst_66 ; // tail call break ; /* branch: __ats_lab_254 */ __ats_lab_254_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_255_0 ; } __ats_lab_254_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_255_1 ; } __ats_lab_254_2: break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: __ats_lab_255_1: __ats_lab_255_2: ats_ptrget_mac(ats_int_type, arg3) = 1 ; break ; } while (0) ; } /* end of [if] */ return /* (tmp706) */ ; } /* end of [auxlst_66] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 40861(line=1237, offs=7) -- 41353(line=1252, offs=8) */ ATSstaticdec() ats_void_type auxlstlst_67 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp714) ; ATSlocal (ats_bool_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; // ATSlocal_void (tmp720) ; __ats_lab_auxlstlst_67: tmp715 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg3), 0) ; if (tmp715) { /* empty */ } else { do { /* branch: __ats_lab_256 */ __ats_lab_256_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_257_0 ; } __ats_lab_256_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_258_1 ; } __ats_lab_256_2: tmp716 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp717 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp718 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp719 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp720 = */ auxlst_66 (tmp716, tmp718, arg2, arg3) ; arg0 = tmp717 ; arg1 = tmp719 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_auxlstlst_67 ; // tail call break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_258_0 ; } __ats_lab_257_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_258_1 ; } __ats_lab_257_2: break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: __ats_lab_258_1: __ats_lab_258_2: ats_ptrget_mac(ats_int_type, arg3) = 1 ; break ; } while (0) ; } /* end of [if] */ return /* (tmp714) */ ; } /* end of [auxlstlst_67] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 40061(line=1211, offs=4) -- 41394(line=1254, offs=2) */ ATSstaticdec() ats_void_type array_ind_dim_check_err_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp705) ; __ats_lab_array_ind_dim_check_err_65: /* tmp705 = */ auxlstlst_67 (arg0, arg1, arg2, arg3) ; return /* (tmp705) */ ; } /* end of [array_ind_dim_check_err_65] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 41584(line=1263, offs=6) -- 41833(line=1271, offs=6) */ ATSstaticdec() ats_void_type linear_abandonment_errmsg_69 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp723) ; // ATSlocal_void (tmp724) ; // ATSlocal_void (tmp725) ; // ATSlocal_void (tmp726) ; // ATSlocal_void (tmp727) ; // ATSlocal_void (tmp728) ; __ats_lab_linear_abandonment_errmsg_69: /* tmp724 = */ prerr_loc_error3_0 (arg0) ; /* tmp725 = */ atspre_prerr_string (ATSstrcst(": the linear union component with the label [")) ; /* tmp726 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (arg1) ; /* tmp727 = */ atspre_prerr_string (ATSstrcst("] is abandoned")) ; /* tmp728 = */ atspre_prerr_newline () ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp723) */ ; } /* end of [linear_abandonment_errmsg_69] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 41880(line=1273, offs=6) -- 42129(line=1282, offs=6) */ ATSstaticdec() ats_ptr_type label_notfound_errmsg_70 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp729) ; // ATSlocal_void (tmp730) ; // ATSlocal_void (tmp731) ; // ATSlocal_void (tmp732) ; // ATSlocal_void (tmp733) ; // ATSlocal_void (tmp734) ; // ATSlocal_void (tmp735) ; __ats_lab_label_notfound_errmsg_70: /* tmp730 = */ prerr_loc_error3_0 (arg0) ; /* tmp731 = */ atspre_prerr_string (ATSstrcst(": the label [")) ; /* tmp732 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (arg2) ; /* tmp733 = */ atspre_prerr_string (ATSstrcst("] is not found in [")) ; /* tmp734 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp735 = */ atspre_prerr_newline () ; /* tmp729 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp729) ; } /* end of [label_notfound_errmsg_70] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 41515(line=1259, offs=23) -- 44110(line=1333, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_int_type, tmp742) ; ATSlocal (ats_int_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_int_type, tmp749) ; ATSlocal (ats_bool_type, tmp750) ; ATSlocal (ats_bool_type, tmp751) ; ATSlocal (anairiats_rec_0, tmp752) ; // ATSlocal_void (tmp753) ; ATSlocal (ats_bool_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_bool_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; // ATSlocal_void (tmp764) ; // ATSlocal_void (tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; // ATSlocal_void (tmp768) ; // ATSlocal_void (tmp769) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr: tmp722 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp736 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp722), atslab_s2exp_node) ; do { /* branch: __ats_lab_259 */ __ats_lab_259_0: if (((ats_sum_ptr_type)tmp736)->tag != 29) { goto __ats_lab_262_0 ; } __ats_lab_259_1: tmp737 = ats_caselptrlab_mac(anairiats_sum_5, tmp736, atslab_2) ; tmp738 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_get_lab (tmp737, arg2) ; do { /* branch: __ats_lab_260 */ __ats_lab_260_0: if (tmp738 != (ats_sum_ptr_type)0) { goto __ats_lab_261_0 ; } __ats_lab_260_1: tmp721 = label_notfound_errmsg_70 (arg0, tmp722, arg2) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: // if (tmp738 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_261_1: tmp739 = ats_caselptrlab_mac(anairiats_sum_3, tmp738, atslab_0) ; ATS_FREE(tmp738) ; tmp721 = tmp739 ; break ; } while (0) ; break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp736)->tag != 31) { goto __ats_lab_270_0 ; } __ats_lab_262_1: tmp740 = ats_caselptrlab_mac(anairiats_sum_6, tmp736, atslab_1) ; tmp741 = ats_caselptrlab_mac(anairiats_sum_6, tmp736, atslab_2) ; /* ats_int_type tmp742 ; */ /* ats_int_type tmp743 ; */ tmp743 = 0 ; /* ats_ptr_type tmp744 ; */ tmp745 = labs2explst_get_lab_ind_51 (tmp741, arg2, (&tmp742)) ; do { /* branch: __ats_lab_263 */ __ats_lab_263_0: if (tmp745 == (ats_sum_ptr_type)0) { goto __ats_lab_269_0 ; } __ats_lab_263_1: tmp747 = ats_caselptrlab_mac(anairiats_sum_3, tmp745, atslab_0) ; ATS_FREE(tmp745) ; tmp748 = un_s2exp_int_62 (tmp740) ; do { /* branch: __ats_lab_264 */ __ats_lab_264_0: if (tmp748 == (ats_sum_ptr_type)0) { goto __ats_lab_268_0 ; } __ats_lab_264_1: tmp749 = ats_caselptrlab_mac(anairiats_sum_11, tmp748, atslab_0) ; ATS_FREE(tmp748) ; do { /* branch: __ats_lab_265 */ __ats_lab_265_0: __ats_lab_265_1: tmp750 = atspre_eq_int_int (tmp749, tmp742) ; if (!tmp750) { goto __ats_lab_266_1 ; } tmp743 = 1 ; tmp744 = tmp747 ; break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: __ats_lab_266_1: tmp751 = atspre_gte_int_int (tmp749, 0) ; if (!tmp751) { goto __ats_lab_267_1 ; } tmp752 = labs2explst_get_nth_63 (tmp741, tmp749) ; tmp755 = ats_select_mac(tmp752, atslab_1) ; tmp754 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp755) ; if (tmp754) { /* tmp753 = */ linear_abandonment_errmsg_69 (arg0, arg2) ; } else { /* empty */ } /* end of [if] */ tmp743 = 1 ; tmp756 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (0, tmp747) ; tmp744 = tmp756 ; break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: __ats_lab_267_1: tmp743 = 1 ; tmp757 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (0, tmp747) ; tmp744 = tmp757 ; break ; } while (0) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: // if (tmp748 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_268_1: tmp744 = tmp747 ; break ; } while (0) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: // if (tmp745 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_269_1: tmp758 = label_notfound_errmsg_70 (arg0, tmp722, arg2) ; tmp744 = tmp758 ; break ; } while (0) ; tmp760 = atspre_eq_int_int (tmp743, 0) ; if (tmp760) { tmp761 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp742) ; tmp762 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq (tmp740, tmp761) ; tmp763 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp763, atslab_0, tmp762) ; ats_selptrset_mac(anairiats_sum_8, tmp763, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp763 ; } else { /* empty */ } /* end of [if] */ tmp721 = tmp744 ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: __ats_lab_270_1: /* tmp764 = */ prerr_loc_error3_0 (arg0) ; /* tmp765 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s2exp_linget_lab_cstr"), ATSstrcst("ats_staexp2_util2.dats")) ; /* tmp766 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp767 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp722) ; /* tmp768 = */ atspre_prerr_string (ATSstrcst("] is expected to be a record or union but it is not.")) ; /* tmp769 = */ atspre_prerr_newline () ; /* tmp721 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp721) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 44213(line=1338, offs=3) -- 44863(line=1357, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_ind_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_int_type, tmp774) ; // ATSlocal_void (tmp775) ; // ATSlocal_void (tmp776) ; ATSlocal (ats_bool_type, tmp777) ; // ATSlocal_void (tmp778) ; // ATSlocal_void (tmp779) ; // ATSlocal_void (tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; // ATSlocal_void (tmp785) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_ind_cstr: tmp771 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_271 */ __ats_lab_271_0: if (((ats_sum_ptr_type)tmp771)->tag != 26) { goto __ats_lab_272_0 ; } __ats_lab_271_1: tmp772 = ats_caselptrlab_mac(anairiats_sum_7, tmp771, atslab_0) ; tmp773 = ats_caselptrlab_mac(anairiats_sum_7, tmp771, atslab_1) ; /* ats_int_type tmp774 ; */ tmp774 = 0 ; /* tmp775 = */ array_ind_dim_check_err_65 (arg2, tmp773, arg3, (&tmp774)) ; tmp777 = atspre_gt_int_int (tmp774, 0) ; if (tmp777) { /* tmp778 = */ prerr_loc_error3_0 (arg0) ; /* tmp779 = */ atspre_prerr_string (ATSstrcst(": array index/dimension mismatch.")) ; /* tmp780 = */ atspre_prerr_newline () ; /* tmp776 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp770 = tmp772 ; break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: __ats_lab_272_1: /* tmp781 = */ prerr_loc_error3_0 (arg0) ; /* tmp782 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp783 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp784 = */ atspre_prerr_string (ATSstrcst("] is expected to be an array but it is not.")) ; /* tmp785 = */ atspre_prerr_newline () ; /* tmp770 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp770) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_ind_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 45003(line=1364, offs=3) -- 45727(line=1385, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; // ATSlocal_void (tmp796) ; // ATSlocal_void (tmp797) ; // ATSlocal_void (tmp798) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr: do { /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp787 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp788 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr (arg0, arg1, tmp787, arg3) ; tmp789 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp789)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp789, atslab_0, tmp787) ; ats_selptrset_mac(anairiats_sum_7, tmp789, atslab_1, arg1) ; tmp786.atslab_0 = tmp788 ; tmp786.atslab_1 = tmp789 ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp790 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp791 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_lab_cstr (arg0, arg1, tmp790, arg3) ; tmp792 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp792)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp792, atslab_0, tmp790) ; ats_selptrset_mac(anairiats_sum_7, tmp792, atslab_1, arg1) ; tmp786.atslab_0 = tmp791 ; tmp786.atslab_1 = tmp792 ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp793 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp794 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_ind_cstr (arg0, arg1, tmp793, arg3) ; tmp795 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp795)->tag = 3 ; ats_selptrset_mac(anairiats_sum_7, tmp795, atslab_0, tmp793) ; ats_selptrset_mac(anairiats_sum_7, tmp795, atslab_1, tmp794) ; tmp786.atslab_0 = tmp794 ; tmp786.atslab_1 = tmp795 ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: __ats_lab_276_1: /* tmp796 = */ prerr_loc_interror_2 (arg0) ; /* tmp797 = */ atspre_prerr_string (ATSstrcst(": s2exp_linget_slab_get: S2LAB1ind")) ; /* tmp798 = */ atspre_prerr_newline () ; /* tmp786 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp786) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 45899(line=1393, offs=6) -- 46037(line=1396, offs=6) */ ATSstaticdec() ats_ptr_type err_74 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp800) ; // ATSlocal_void (tmp801) ; // ATSlocal_void (tmp802) ; // ATSlocal_void (tmp803) ; __ats_lab_err_74: /* tmp801 = */ prerr_loc_interror_2 (arg0) ; /* tmp802 = */ atspre_prerr_string (ATSstrcst(": s2exp_slab_set")) ; /* tmp803 = */ atspre_prerr_newline () ; /* tmp800 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp800) ; } /* end of [err_74] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 45862(line=1392, offs=3) -- 47566(line=1439, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_int_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (atsopt_count_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_bool_type, tmp815) ; ATSlocal (ats_bool_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_int_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_bool_type, tmp827) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab: tmp804 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp804)->tag != 29) { goto __ats_lab_282_0 ; } __ats_lab_277_1: tmp805 = ats_caselptrlab_mac(anairiats_sum_5, tmp804, atslab_0) ; tmp806 = ats_caselptrlab_mac(anairiats_sum_5, tmp804, atslab_1) ; tmp807 = ats_caselptrlab_mac(anairiats_sum_5, tmp804, atslab_2) ; tmp808 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2explst_set_lab (tmp807, arg2, arg3) ; do { /* branch: __ats_lab_278 */ __ats_lab_278_0: if (tmp808 == (ats_sum_ptr_type)0) { goto __ats_lab_281_0 ; } __ats_lab_278_1: tmp809 = ats_caselptrlab_mac(anairiats_sum_3, tmp808, atslab_0) ; ATS_FREE(tmp808) ; do { /* branch: __ats_lab_279 */ __ats_lab_279_0: if (((ats_sum_ptr_type)tmp805)->tag != 1) { goto __ats_lab_280_0 ; } __ats_lab_279_1: tmp799 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec (0, tmp806, tmp809) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: __ats_lab_280_1: tmp810 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_srt) ; tmp799 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp810, tmp805, tmp806, tmp809) ; break ; } while (0) ; break ; /* branch: __ats_lab_281 */ __ats_lab_281_0: // if (tmp808 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_281_1: tmp799 = err_74 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: if (((ats_sum_ptr_type)tmp804)->tag != 31) { goto __ats_lab_289_0 ; } __ats_lab_282_1: tmp811 = ats_caselptrlab_mac(anairiats_sum_6, tmp804, atslab_0) ; tmp812 = ats_caselptrlab_mac(anairiats_sum_6, tmp804, atslab_1) ; tmp813 = ats_caselptrlab_mac(anairiats_sum_6, tmp804, atslab_2) ; tmp814 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_s2exp_srt) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (tmp814) ; tmp817 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg3), atslab_s2exp_node) ; do { /* branch: __ats_lab_283 */ __ats_lab_283_0: if (((ats_sum_ptr_type)tmp817)->tag != 24) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp816 = ats_true_bool ; break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: __ats_lab_284_1: tmp816 = ats_false_bool ; break ; } while (0) ; if (tmp816) { tmp818 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (-1) ; if (tmp815) { tmp819 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp819 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ tmp799 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp819, tmp811, tmp818, tmp813) ; } else { /* ats_int_type tmp820 ; */ tmp822 = labs2explst_lab_set_ind_53 (tmp813, arg2, arg3, (&tmp820)) ; do { /* branch: __ats_lab_285 */ __ats_lab_285_0: if (tmp822 == (ats_sum_ptr_type)0) { goto __ats_lab_286_0 ; } __ats_lab_285_1: tmp823 = ats_caselptrlab_mac(anairiats_sum_3, tmp822, atslab_0) ; ATS_FREE(tmp822) ; tmp821 = tmp823 ; break ; /* branch: __ats_lab_286 */ __ats_lab_286_0: // if (tmp822 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_286_1: tmp821 = err_74 (arg0) ; break ; } while (0) ; tmp825 = un_s2exp_int_62 (tmp812) ; do { /* branch: __ats_lab_287 */ __ats_lab_287_0: if (tmp825 == (ats_sum_ptr_type)0) { goto __ats_lab_288_0 ; } __ats_lab_287_1: ATS_FREE(tmp825) ; tmp824 = tmp812 ; break ; /* branch: __ats_lab_288 */ __ats_lab_288_0: // if (tmp825 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_288_1: tmp824 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (tmp820) ; break ; } while (0) ; tmp827 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (arg3) ; if (tmp827) { if (tmp815) { tmp826 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } else { tmp826 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ } else { if (tmp815) { tmp826 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp826 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } /* end of [if] */ tmp799 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp826, tmp811, tmp824, tmp821) ; } /* end of [if] */ break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: __ats_lab_289_1: tmp799 = err_74 (arg0) ; break ; } while (0) ; return (tmp799) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 47696(line=1446, offs=7) -- 48102(line=1457, offs=6) */ ATSstaticdec() ats_ptr_type aux_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (anairiats_rec_0, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; __ats_lab_aux_76: do { /* branch: __ats_lab_290 */ __ats_lab_290_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_291_0 ; } __ats_lab_290_1: tmp830 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp831 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp832 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp833 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr (arg0, tmp832, tmp830, arg3) ; tmp834 = ats_select_mac(tmp833, atslab_0) ; tmp835 = ats_select_mac(tmp833, atslab_1) ; tmp836 = aux_76 (arg0, tmp834, tmp831, arg3) ; tmp829 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp829, atslab_0, tmp835) ; ats_selptrset_mac(anairiats_sum_8, tmp829, atslab_1, tmp836) ; break ; /* branch: __ats_lab_291 */ __ats_lab_291_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_291_1: tmp829 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp829) ; } /* end of [aux_76] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 47659(line=1445, offs=3) -- 48159(line=1460, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lintry_slablst_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp828) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lintry_slablst_cstr: tmp828 = aux_76 (arg0, arg1, arg2, arg3) ; return (tmp828) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lintry_slablst_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 48298(line=1467, offs=7) -- 49646(line=1501, offs=6) */ ATSstaticdec() anairiats_rec_19 aux_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (anairiats_rec_0, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (anairiats_rec_19, tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; // ATSlocal_void (tmp856) ; // ATSlocal_void (tmp857) ; // ATSlocal_void (tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_bool_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; __ats_lab_aux_78: do { /* branch: __ats_lab_292 */ __ats_lab_292_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_298_0 ; } __ats_lab_292_1: tmp839 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp840 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp841 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp842 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr (arg0, tmp841, tmp839, arg3) ; tmp843 = ats_select_mac(tmp842, atslab_0) ; tmp844 = ats_select_mac(tmp842, atslab_1) ; tmp845 = aux_78 (arg0, tmp843, tmp840, arg3) ; tmp846 = ats_select_mac(tmp845, atslab_0) ; tmp847 = ats_select_mac(tmp845, atslab_1) ; tmp848 = ats_select_mac(tmp845, atslab_2) ; do { /* branch: __ats_lab_293 */ __ats_lab_293_0: if (tmp847 == (ats_sum_ptr_type)0) { goto __ats_lab_297_0 ; } __ats_lab_293_1: tmp850 = ats_caselptrlab_mac(anairiats_sum_3, tmp847, atslab_0) ; ATS_FREE(tmp847) ; do { /* branch: __ats_lab_294 */ __ats_lab_294_0: if (((ats_sum_ptr_type)tmp844)->tag != 2) { goto __ats_lab_295_0 ; } __ats_lab_294_1: tmp851 = ats_caselptrlab_mac(anairiats_sum_7, tmp844, atslab_0) ; tmp852 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab (arg0, tmp841, tmp851, tmp850) ; tmp849 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp849, atslab_0, tmp852) ; break ; /* branch: __ats_lab_295 */ __ats_lab_295_0: if (((ats_sum_ptr_type)tmp844)->tag != 3) { goto __ats_lab_296_0 ; } __ats_lab_295_1: tmp853 = ats_caselptrlab_mac(anairiats_sum_7, tmp844, atslab_1) ; tmp855 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq (1, tmp850, tmp853) ; tmp854 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp854, atslab_0, tmp855) ; ats_selptrset_mac(anairiats_sum_8, tmp854, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp854 ; tmp849 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: __ats_lab_296_1: /* tmp856 = */ prerr_loc_interror_2 (arg0) ; /* tmp857 = */ atspre_prerr_string (ATSstrcst(": s2exp_linget_slablst_cstr: aux")) ; /* tmp858 = */ atspre_prerr_newline () ; /* tmp849 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_297 */ __ats_lab_297_0: // if (tmp847 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_297_1: tmp849 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp859 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp859, atslab_0, tmp844) ; ats_selptrset_mac(anairiats_sum_8, tmp859, atslab_1, tmp848) ; tmp838.atslab_0 = tmp846 ; tmp838.atslab_1 = tmp849 ; tmp838.atslab_2 = tmp859 ; break ; /* branch: __ats_lab_298 */ __ats_lab_298_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_298_1: tmp861 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (arg1) ; if (tmp861) { tmp862 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize (1, arg1) ; tmp860 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp860, atslab_0, tmp862) ; } else { tmp860 = (ats_sum_ptr_type)0 ; } /* end of [if] */ tmp863 = (ats_sum_ptr_type)0 ; tmp838.atslab_0 = arg1 ; tmp838.atslab_1 = tmp860 ; tmp838.atslab_2 = tmp863 ; break ; } while (0) ; return (tmp838) ; } /* end of [aux_78] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 48261(line=1466, offs=3) -- 49834(line=1506, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp837) ; ATSlocal (anairiats_rec_19, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_ptr_type, tmp867) ; ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_ptr_type, tmp869) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr: tmp864 = aux_78 (arg0, arg1, arg2, arg3) ; tmp865 = ats_select_mac(tmp864, atslab_0) ; tmp866 = ats_select_mac(tmp864, atslab_1) ; tmp867 = ats_select_mac(tmp864, atslab_2) ; do { /* branch: __ats_lab_299 */ __ats_lab_299_0: if (tmp866 == (ats_sum_ptr_type)0) { goto __ats_lab_300_0 ; } __ats_lab_299_1: tmp869 = ats_caselptrlab_mac(anairiats_sum_3, tmp866, atslab_0) ; ATS_FREE(tmp866) ; tmp868 = tmp869 ; break ; /* branch: __ats_lab_300 */ __ats_lab_300_0: // if (tmp866 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_300_1: tmp868 = arg1 ; break ; } while (0) ; tmp837.atslab_0 = tmp865 ; tmp837.atslab_1 = tmp868 ; tmp837.atslab_2 = tmp867 ; return (tmp837) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 49979(line=1513, offs=7) -- 51192(line=1543, offs=6) */ ATSstaticdec() anairiats_rec_19 aux_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (anairiats_rec_0, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; ATSlocal (anairiats_rec_19, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_ptr_type, tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; // ATSlocal_void (tmp889) ; // ATSlocal_void (tmp890) ; // ATSlocal_void (tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; __ats_lab_aux_80: do { /* branch: __ats_lab_301 */ __ats_lab_301_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_307_0 ; } __ats_lab_301_1: tmp872 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp873 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp874 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp875 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr (arg0, tmp874, tmp872, arg4) ; tmp876 = ats_select_mac(tmp875, atslab_0) ; tmp877 = ats_select_mac(tmp875, atslab_1) ; tmp878 = aux_80 (arg0, tmp876, tmp873, arg3, arg4) ; tmp879 = ats_select_mac(tmp878, atslab_0) ; tmp880 = ats_select_mac(tmp878, atslab_1) ; tmp881 = ats_select_mac(tmp878, atslab_2) ; do { /* branch: __ats_lab_302 */ __ats_lab_302_0: if (tmp880 == (ats_sum_ptr_type)0) { goto __ats_lab_306_0 ; } __ats_lab_302_1: tmp883 = ats_caselptrlab_mac(anairiats_sum_3, tmp880, atslab_0) ; ATS_FREE(tmp880) ; do { /* branch: __ats_lab_303 */ __ats_lab_303_0: if (((ats_sum_ptr_type)tmp877)->tag != 2) { goto __ats_lab_304_0 ; } __ats_lab_303_1: tmp884 = ats_caselptrlab_mac(anairiats_sum_7, tmp877, atslab_0) ; tmp885 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab (arg0, tmp874, tmp884, tmp883) ; tmp882 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp882, atslab_0, tmp885) ; break ; /* branch: __ats_lab_304 */ __ats_lab_304_0: if (((ats_sum_ptr_type)tmp877)->tag != 3) { goto __ats_lab_305_0 ; } __ats_lab_304_1: tmp886 = ats_caselptrlab_mac(anairiats_sum_7, tmp877, atslab_1) ; tmp888 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq (1, tmp883, tmp886) ; tmp887 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp887, atslab_0, tmp888) ; ats_selptrset_mac(anairiats_sum_8, tmp887, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp887 ; tmp882 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_305 */ __ats_lab_305_0: __ats_lab_305_1: /* tmp889 = */ prerr_loc_interror_2 (arg0) ; /* tmp890 = */ atspre_prerr_string (ATSstrcst(": s2exp_linset_slablst_cstr: aux")) ; /* tmp891 = */ atspre_prerr_newline () ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_306 */ __ats_lab_306_0: // if (tmp880 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_306_1: tmp882 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp892 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp892, atslab_0, tmp877) ; ats_selptrset_mac(anairiats_sum_8, tmp892, atslab_1, tmp881) ; tmp871.atslab_0 = tmp879 ; tmp871.atslab_1 = tmp882 ; tmp871.atslab_2 = tmp892 ; break ; /* branch: __ats_lab_307 */ __ats_lab_307_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_307_1: tmp893 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp893, atslab_0, arg3) ; tmp894 = (ats_sum_ptr_type)0 ; tmp871.atslab_0 = arg1 ; tmp871.atslab_1 = tmp893 ; tmp871.atslab_2 = tmp894 ; break ; } while (0) ; return (tmp871) ; } /* end of [aux_80] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 49933(line=1512, offs=3) -- 51392(line=1548, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp870) ; ATSlocal (anairiats_rec_19, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr: tmp895 = aux_80 (arg0, arg1, arg2, arg3, arg4) ; tmp896 = ats_select_mac(tmp895, atslab_0) ; tmp897 = ats_select_mac(tmp895, atslab_1) ; tmp898 = ats_select_mac(tmp895, atslab_2) ; do { /* branch: __ats_lab_308 */ __ats_lab_308_0: if (tmp897 == (ats_sum_ptr_type)0) { goto __ats_lab_309_0 ; } __ats_lab_308_1: tmp900 = ats_caselptrlab_mac(anairiats_sum_3, tmp897, atslab_0) ; ATS_FREE(tmp897) ; tmp899 = tmp900 ; break ; /* branch: __ats_lab_309 */ __ats_lab_309_0: // if (tmp897 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_309_1: tmp899 = arg1 ; break ; } while (0) ; tmp870.atslab_0 = tmp896 ; tmp870.atslab_1 = tmp899 ; tmp870.atslab_2 = tmp898 ; return (tmp870) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 51528(line=1555, offs=7) -- 52800(line=1590, offs=6) */ ATSstaticdec() anairiats_rec_19 aux_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; // ATSlocal_void (tmp905) ; // ATSlocal_void (tmp906) ; // ATSlocal_void (tmp907) ; // ATSlocal_void (tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (anairiats_rec_0, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (anairiats_rec_19, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; // ATSlocal_void (tmp919) ; // ATSlocal_void (tmp920) ; // ATSlocal_void (tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; __ats_lab_aux_82: do { /* branch: __ats_lab_310 */ __ats_lab_310_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_315_0 ; } __ats_lab_310_1: tmp903 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp904 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; do { /* branch: __ats_lab_311 */ __ats_lab_311_0: if (((ats_sum_ptr_type)tmp903)->tag != 1) { goto __ats_lab_312_0 ; } __ats_lab_311_1: /* tmp906 = */ prerr_loc_error3_0 (arg0) ; /* tmp907 = */ atspre_prerr_string (ATSstrcst(": array subscription is not supported (for view extraction).")) ; /* tmp908 = */ atspre_prerr_newline () ; /* tmp905 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_312 */ __ats_lab_312_0: __ats_lab_312_1: break ; } while (0) ; tmp909 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp910 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slab_cstr (arg0, tmp909, tmp903, arg3) ; tmp911 = ats_select_mac(tmp910, atslab_0) ; tmp912 = ats_select_mac(tmp910, atslab_1) ; tmp913 = aux_82 (arg0, tmp911, tmp904, arg3) ; tmp914 = ats_select_mac(tmp913, atslab_0) ; tmp915 = ats_select_mac(tmp913, atslab_1) ; tmp916 = ats_select_mac(tmp913, atslab_2) ; do { /* branch: __ats_lab_313 */ __ats_lab_313_0: if (((ats_sum_ptr_type)tmp912)->tag != 2) { goto __ats_lab_314_0 ; } __ats_lab_313_1: tmp918 = ats_caselptrlab_mac(anairiats_sum_7, tmp912, atslab_0) ; tmp917 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_lab (arg0, tmp909, tmp918, tmp915) ; break ; /* branch: __ats_lab_314 */ __ats_lab_314_0: __ats_lab_314_1: /* tmp919 = */ prerr_loc_interror_2 (arg0) ; /* tmp920 = */ atspre_prerr_string (ATSstrcst(": s2exp_linset_slablst_cstr: aux")) ; /* tmp921 = */ atspre_prerr_newline () ; /* tmp917 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp922 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp922, atslab_0, tmp912) ; ats_selptrset_mac(anairiats_sum_8, tmp922, atslab_1, tmp916) ; tmp902.atslab_0 = tmp914 ; tmp902.atslab_1 = tmp917 ; tmp902.atslab_2 = tmp922 ; break ; /* branch: __ats_lab_315 */ __ats_lab_315_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_315_1: tmp923 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out (arg1) ; tmp924 = (ats_sum_ptr_type)0 ; tmp902.atslab_0 = arg1 ; tmp902.atslab_1 = tmp923 ; tmp902.atslab_2 = tmp924 ; break ; } while (0) ; return (tmp902) ; } /* end of [aux_82] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 51491(line=1554, offs=3) -- 52857(line=1593, offs=4) */ ATSglobaldec() anairiats_rec_19 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lindel_slablst_cstr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_19, tmp901) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lindel_slablst_cstr: tmp901 = aux_82 (arg0, arg1, arg2, arg3) ; return (tmp901) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lindel_slablst_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 52925(line=1597, offs=5) -- 53214(line=1605, offs=21) */ ATSstaticdec() ats_int_type s2explst_subclass_test_83 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_int_type, tmp928) ; ATSlocal (ats_bool_type, tmp929) ; __ats_lab_s2explst_subclass_test_83: do { /* branch: __ats_lab_316 */ __ats_lab_316_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_317_0 ; } __ats_lab_316_1: tmp926 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp927 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp928 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test (tmp926, arg1) ; tmp929 = atspre_igt (tmp928, 0) ; if (tmp929) { tmp925 = 1 ; } else { arg0 = tmp927 ; arg1 = arg1 ; goto __ats_lab_s2explst_subclass_test_83 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_317 */ __ats_lab_317_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_317_1: tmp925 = 0 ; break ; } while (0) ; return (tmp925) ; } /* end of [s2explst_subclass_test_83] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util2.dats: 53281(line=1609, offs=21) -- 53819(line=1626, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; ATSlocal (ats_bool_type, tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test: tmp931 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp932 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp933 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp931, tmp932) ; if (tmp933) { tmp930 = 1 ; } else { tmp934 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp931), atslab_s2exp_node) ; do { /* branch: __ats_lab_318 */ __ats_lab_318_0: if (((ats_sum_ptr_type)tmp934)->tag != 4) { goto __ats_lab_319_0 ; } __ats_lab_318_1: tmp935 = ats_caselptrlab_mac(anairiats_sum_2, tmp934, atslab_0) ; tmp936 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_supcls (tmp935) ; tmp930 = s2explst_subclass_test_83 (tmp936, tmp932) ; break ; /* branch: __ats_lab_319 */ __ats_lab_319_0: __ats_lab_319_1: tmp930 = 0 ; break ; } while (0) ; } /* end of [if] */ return (tmp930) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subclass_test] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util2_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_util2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_print_dats.c0000664000175000017500000033666612223166160022745 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_7 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_s2exparg_loc ; ats_ptr_type atslab_s2exparg_node ; } anairiats_rec_19 ; typedef struct { anairiats_rec_0 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_20 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatconptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatcontyp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMe1xp_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMfil_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMvar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt1_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEcst_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEextype_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyarr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyrec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEunion_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEcst_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEfun_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyarr_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyrec_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEunion_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEvar_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASpre_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGseq_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_effset) (ats_ref_type, ats_uint_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qua) (ats_ref_type, anairiats_rec_0) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2kexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparg) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type fprint_tyreckind_0 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type fprint_s2rtdat_1 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type fprint_s2rtbas_2 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_24 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_28 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_32 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_46 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_52 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type aux_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 2083(line=67, offs=5) -- 2646(line=81, offs=8) */ ATSstaticdec() ats_void_type fprint_tyreckind_0 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (atsopt_count_type, tmp1) ; // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; __ats_lab_fprint_tyreckind_0: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("box")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("flt")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp2 = */ atspre_fprint_string (arg0, ATSstrcst("flt(")) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp1) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)arg1)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("flt(")) ; /* tmp6 = */ atspre_fprint_string (arg0, tmp4) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [fprint_tyreckind_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 2730(line=86, offs=4) -- 2876(line=88, offs=49) */ ATSstaticdec() ats_void_type fprint_s2rtdat_1 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_fprint_s2rtdat_1: tmp8 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rtdat_get_sym (arg1) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp8) ; return /* (tmp7) */ ; } /* end of [fprint_s2rtdat_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 2908(line=91, offs=4) -- 3172(line=96, offs=49) */ ATSstaticdec() ats_void_type fprint_s2rtbas_2 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_fprint_s2rtbas_2: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp10) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp11) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp9 = */ fprint_s2rtdat_1 (arg0, tmp12) ; break ; } while (0) ; return /* (tmp9) */ ; } /* end of [fprint_s2rtbas_2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 3246(line=102, offs=15) -- 4122(line=126, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMcst(...)")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMdatconptr(")) ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp14) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp18 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMdatcontyp(")) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp17) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMe1xp(")) ; /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (arg0, tmp20) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMfil(")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp23) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (((ats_sum_ptr_type)arg1)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp27 = */ atspre_fprint_string (arg0, ATSstrcst("S2ITEMvar(")) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp26) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp13) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4176(line=129, offs=14) -- 4214(line=129, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2item (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; // ATSlocal_void (tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2item: tmp30 = atspre_stdout_get () ; tmp31 = ats_selsin_mac(tmp30, atslab_1) ; /* tmp32 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item (tmp31, arg0) ; /* tmp29 = */ atspre_stdout_view_set () ; return /* (tmp29) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2item] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4238(line=131, offs=14) -- 4276(line=131, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; // ATSlocal_void (tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item: tmp34 = atspre_stderr_get () ; tmp35 = ats_selsin_mac(tmp34, atslab_1) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2item (tmp35, arg0) ; /* tmp33 = */ atspre_stderr_view_set () ; return /* (tmp33) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2item] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4321(line=136, offs=13) -- 4783(line=151, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp37 = */ fprint_s2rtbas_2 (arg0, tmp38) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp39 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp40 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp41 = */ atspre_fprint_string (arg0, ATSstrcst("S2RTfun(")) ; /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst (arg0, tmp39) ; /* tmp43 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp44 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (arg0, tmp40) ; /* tmp37 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp46 = */ atspre_fprint_string (arg0, ATSstrcst("S2RTtup(")) ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst (arg0, tmp45) ; /* tmp37 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4833(line=154, offs=12) -- 4869(line=154, offs=48) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2rt (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; // ATSlocal_void (tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2rt: tmp49 = atspre_stdout_get () ; tmp50 = ats_selsin_mac(tmp49, atslab_1) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (tmp50, arg0) ; /* tmp48 = */ atspre_stdout_view_set () ; return /* (tmp48) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4891(line=156, offs=12) -- 4927(line=156, offs=48) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; // ATSlocal_void (tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt: tmp53 = atspre_stderr_get () ; tmp54 = ats_selsin_mac(tmp53, atslab_1) ; /* tmp55 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (tmp54, arg0) ; /* tmp52 = */ atspre_stderr_view_set () ; return /* (tmp52) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 4975(line=161, offs=16) -- 5042(line=162, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst: /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt) ; return /* (tmp56) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 5099(line=166, offs=19) -- 5171(line=167, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlstlst: /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlst) ; return /* (tmp57) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 5249(line=173, offs=16) -- 6201(line=201, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtext (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtext: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (arg0, tmp59) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_2) ; /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("{")) ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp60) ; /* tmp65 = */ atspre_fprint_string (arg0, ATSstrcst(": ")) ; /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rt (arg0, tmp61) ; /* tmp67 = */ atspre_fprint_string (arg0, ATSstrcst(" | ")) ; /* tmp68 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp62) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; break ; } while (0) ; return /* (tmp58) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2rtext] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 6277(line=206, offs=14) -- 6708(line=221, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp69) ; ATSlocal (ats_uint_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst("")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp71 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; /* tmp72 = */ atspre_fprint_string (arg0, ATSstrcst("<")) ; /* tmp73 = */ atsopt_fprint_effset (arg0, tmp70) ; /* tmp74 = */ atspre_fprint_string (arg0, ATSstrcst(";")) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp71) ; /* tmp69 = */ atspre_fprint_string (arg0, ATSstrcst(">")) ; break ; } while (0) ; return /* (tmp69) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 6760(line=224, offs=13) -- 6799(line=224, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2eff (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; // ATSlocal_void (tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2eff: tmp77 = atspre_stdout_get () ; tmp78 = ats_selsin_mac(tmp77, atslab_1) ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (tmp78, arg0) ; /* tmp76 = */ atspre_stdout_view_set () ; return /* (tmp76) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 6822(line=226, offs=13) -- 6861(line=226, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff: tmp81 = atspre_stderr_get () ; tmp82 = ats_selsin_mac(tmp81, atslab_1) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (tmp82, arg0) ; /* tmp80 = */ atspre_stderr_view_set () ; return /* (tmp80) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 6907(line=231, offs=14) -- 14392(line=481, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_char_type, tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; ATSlocal (ats_int_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp131) ; // ATSlocal_void (tmp132) ; // ATSlocal_void (tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; // ATSlocal_void (tmp139) ; // ATSlocal_void (tmp140) ; // ATSlocal_void (tmp141) ; // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; // ATSlocal_void (tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_int_type, tmp158) ; // ATSlocal_void (tmp159) ; // ATSlocal_void (tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; // ATSlocal_void (tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; ATSlocal (ats_int_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; // ATSlocal_void (tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_int_type, tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; ATSlocal (ats_int_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; // ATSlocal_void (tmp229) ; ATSlocal (ats_int_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_int_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; // ATSlocal_void (tmp249) ; // ATSlocal_void (tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; // ATSlocal_void (tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; // ATSlocal_void (tmp258) ; // ATSlocal_void (tmp259) ; ATSlocal (atsopt_count_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; // ATSlocal_void (tmp263) ; // ATSlocal_void (tmp264) ; // ATSlocal_void (tmp265) ; // ATSlocal_void (tmp266) ; // ATSlocal_void (tmp267) ; // ATSlocal_void (tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; // ATSlocal_void (tmp273) ; // ATSlocal_void (tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp: tmp85 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp85)->tag != 0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp87 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp88 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eapp(")) ; /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp86) ; /* tmp90 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp87) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp85)->tag != 1) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_8, tmp85, atslab_0) ; /* tmp93 = */ atspre_fprint_string (arg0, ATSstrcst("S2Echar(")) ; /* tmp94 = */ atspre_fprint_char (arg0, tmp92) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp85)->tag != 2) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_0) ; tmp96 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_1) ; /* tmp97 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eclo(")) ; /* tmp98 = */ atspre_fprint_int (arg0, tmp95) ; /* tmp99 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp96) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp85)->tag != 3) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp102 = */ atspre_fprint_string (arg0, ATSstrcst("S2Ecrypt(")) ; /* tmp103 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp101) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp85)->tag != 4) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp104 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp105 = */ atspre_fprint_string (arg0, ATSstrcst("S2Ecst(")) ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp104) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp85)->tag != 5) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp109 = */ atspre_fprint_string (arg0, ATSstrcst("S2Edatconptr(")) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp107) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp108) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp85)->tag != 6) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp115 = */ atspre_fprint_string (arg0, ATSstrcst("S2Edatcontyp(")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp113) ; /* tmp117 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp114) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp85)->tag != 7) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp119 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp120 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eeff(")) ; /* tmp121 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (arg0, tmp119) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp85)->tag != 8) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp122 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp123 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp124 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eeqeq(")) ; /* tmp125 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp122) ; /* tmp126 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp123) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp85)->tag != 9) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_0) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_1) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_2) ; /* tmp131 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eexi(")) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp128) ; /* tmp133 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp129) ; /* tmp135 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp130) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp85)->tag != 10) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp137 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp139 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eextype(")) ; /* tmp140 = */ atspre_fprint_string (arg0, tmp137) ; /* tmp141 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp142 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp138) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp85)->tag != 11) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_10, tmp85, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_10, tmp85, atslab_1) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_10, tmp85, atslab_3) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_10, tmp85, atslab_4) ; tmp147 = ats_caselptrlab_mac(anairiats_sum_10, tmp85, atslab_5) ; /* tmp148 = */ atspre_fprint_string (arg0, ATSstrcst("S2Efun(")) ; /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp143) ; /* tmp150 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp151 = */ atspre_fprint_int (arg0, tmp144) ; /* tmp152 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp153 = */ atspre_fprint_int (arg0, tmp145) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp146) ; /* tmp156 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp157 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp147) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp85)->tag != 12) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_11, tmp85, atslab_0) ; /* tmp159 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eint(")) ; /* tmp160 = */ atspre_fprint_int (arg0, tmp158) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp85)->tag != 13) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp161 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp162 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eint(")) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp161) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp85)->tag != 14) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp164 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp165 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp166 = */ atspre_fprint_string (arg0, ATSstrcst("S2Elam(")) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp164) ; /* tmp168 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp169 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp165) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp85)->tag != 15) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_1) ; tmp171 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_2) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("S2Emetfn(")) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp170) ; /* tmp174 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp175 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp171) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp85)->tag != 16) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp178 = */ atspre_fprint_string (arg0, ATSstrcst("S2Emetlt(")) ; /* tmp179 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp176) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp177) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp85)->tag != 17) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp183 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eout(")) ; /* tmp184 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp182) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp85)->tag != 18) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp187 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eproj(")) ; /* tmp188 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp185) ; /* tmp189 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab (arg0, tmp186) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp85)->tag != 19) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp193 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eread(")) ; /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp191) ; /* tmp195 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp192) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp85)->tag != 20) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_0) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_1) ; /* tmp199 = */ atspre_fprint_string (arg0, ATSstrcst("S2Erefarg(")) ; /* tmp200 = */ atspre_fprint_int (arg0, tmp197) ; /* tmp201 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp202 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp198) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp85)->tag != 21) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp203 = ats_caselptrlab_mac(anairiats_sum_12, tmp85, atslab_0) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_12, tmp85, atslab_1) ; /* tmp205 = */ atspre_fprint_string (arg0, ATSstrcst("S2Esel(")) ; /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp203) ; /* tmp207 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp208 = */ atspre_fprint_int (arg0, tmp204) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp85)->tag != 22) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp210 = */ atspre_fprint_string (arg0, ATSstrcst("S2Esize(")) ; /* tmp211 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (arg0, tmp209) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp85)->tag != 23) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp213 = */ atspre_fprint_string (arg0, ATSstrcst("S2Esizeof(")) ; /* tmp214 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp212) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp85)->tag != 24) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_0) ; tmp216 = ats_caselptrlab_mac(anairiats_sum_9, tmp85, atslab_1) ; /* tmp217 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etop(")) ; /* tmp218 = */ atspre_fprint_int (arg0, tmp215) ; /* tmp219 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp220 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp216) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp85)->tag != 25) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp222 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etup(")) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp221) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp85)->tag != 26) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp224 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp225 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp226 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etyarr(")) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp224) ; /* tmp228 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp225) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp85)->tag != 27) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp230 = ats_caselptrlab_mac(anairiats_sum_13, tmp85, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_13, tmp85, atslab_1) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_13, tmp85, atslab_2) ; /* tmp233 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etyleq(")) ; /* tmp234 = */ atspre_fprint_int (arg0, tmp230) ; /* tmp235 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp236 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp231) ; /* tmp237 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp232) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp85)->tag != 28) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etylst(")) ; /* tmp241 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp239) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp85)->tag != 29) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_14, tmp85, atslab_0) ; tmp243 = ats_caselptrlab_mac(anairiats_sum_14, tmp85, atslab_1) ; tmp244 = ats_caselptrlab_mac(anairiats_sum_14, tmp85, atslab_2) ; /* tmp245 = */ atspre_fprint_string (arg0, ATSstrcst("S2Etyrec(")) ; /* tmp246 = */ fprint_tyreckind_0 (arg0, tmp242) ; /* tmp247 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp248 = */ atspre_fprint_int (arg0, tmp243) ; /* tmp249 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst (arg0, tmp244) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp85)->tag != 30) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp251 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_0) ; tmp252 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_1) ; tmp253 = ats_caselptrlab_mac(anairiats_sum_5, tmp85, atslab_2) ; /* tmp254 = */ atspre_fprint_string (arg0, ATSstrcst("S2Euni(")) ; /* tmp255 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp251) ; /* tmp256 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp257 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp252) ; /* tmp258 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp259 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp253) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp85)->tag != 31) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp260 = ats_caselptrlab_mac(anairiats_sum_15, tmp85, atslab_0) ; tmp261 = ats_caselptrlab_mac(anairiats_sum_15, tmp85, atslab_1) ; tmp262 = ats_caselptrlab_mac(anairiats_sum_15, tmp85, atslab_2) ; /* tmp263 = */ atspre_fprint_string (arg0, ATSstrcst("S2Eunion(")) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp260) ; /* tmp265 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp261) ; /* tmp267 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp268 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst (arg0, tmp262) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp85)->tag != 32) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp270 = */ atspre_fprint_string (arg0, ATSstrcst("S2Evar(")) ; /* tmp271 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp269) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp85)->tag != 33) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp273 = */ atspre_fprint_string (arg0, ATSstrcst("S2EVar(")) ; /* tmp274 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (arg0, tmp272) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp85)->tag != 34) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_2, tmp85, atslab_0) ; /* tmp276 = */ atspre_fprint_string (arg0, ATSstrcst("S2Evararg(")) ; /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp275) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (((ats_sum_ptr_type)tmp85)->tag != 35) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_0) ; tmp279 = ats_caselptrlab_mac(anairiats_sum_4, tmp85, atslab_1) ; /* tmp280 = */ atspre_fprint_string (arg0, ATSstrcst("S2Ewth(")) ; /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp278) ; /* tmp282 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp283 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst (arg0, tmp279) ; /* tmp84 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp84) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14444(line=484, offs=13) -- 14481(line=484, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; // ATSlocal_void (tmp287) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exp: tmp285 = atspre_stdout_get () ; tmp286 = ats_selsin_mac(tmp285, atslab_1) ; /* tmp287 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (tmp286, arg0) ; /* tmp284 = */ atspre_stdout_view_set () ; return /* (tmp284) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14504(line=486, offs=13) -- 14541(line=486, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; // ATSlocal_void (tmp291) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp: tmp289 = atspre_stderr_get () ; tmp290 = ats_selsin_mac(tmp289, atslab_1) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (tmp290, arg0) ; /* tmp288 = */ atspre_stderr_view_set () ; return /* (tmp288) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14590(line=491, offs=17) -- 14658(line=492, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp292) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst: /* tmp292 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) ; return /* (tmp292) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14716(line=496, offs=16) -- 14758(line=496, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; // ATSlocal_void (tmp296) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2explst: tmp294 = atspre_stdout_get () ; tmp295 = ats_selsin_mac(tmp294, atslab_1) ; /* tmp296 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (tmp295, arg0) ; /* tmp293 = */ atspre_stdout_view_set () ; return /* (tmp293) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14784(line=498, offs=16) -- 14826(line=498, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; // ATSlocal_void (tmp300) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2explst: tmp298 = atspre_stderr_get () ; tmp299 = ats_selsin_mac(tmp298, atslab_1) ; /* tmp300 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (tmp299, arg0) ; /* tmp297 = */ atspre_stderr_view_set () ; return /* (tmp297) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 14878(line=503, offs=20) -- 14951(line=504, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp301) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst: /* tmp301 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst) ; return /* (tmp301) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 15040(line=511, offs=7) -- 15307(line=520, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2expopt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2expopt: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp303 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_0) ; /* tmp304 = */ atspre_fprint_string (arg0, ATSstrcst("Some(")) ; /* tmp305 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp303) ; /* tmp302 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: /* tmp302 = */ atspre_fprint_string (arg0, ATSstrcst("None()")) ; break ; } while (0) ; return /* (tmp302) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2expopt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 15443(line=528, offs=7) -- 15878(line=540, offs=30) */ ATSstaticdec() ats_void_type aux_24 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_bool_type, tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; // ATSlocal_void (tmp315) ; ATSlocal (ats_int_type, tmp316) ; __ats_lab_aux_24: do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; tmp310 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_2) ; tmp312 = atspre_gt_int_int (arg2, 0) ; if (tmp312) { /* tmp311 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp313 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp308) ; /* tmp314 = */ atspre_fprint_string (arg0, ATSstrcst("=")) ; /* tmp315 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp309) ; tmp316 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp310 ; arg2 = tmp316 ; goto __ats_lab_aux_24 ; // tail call break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: break ; } while (0) ; return /* (tmp307) */ ; } /* end of [aux_24] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 15413(line=527, offs=7) -- 15925(line=544, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp306) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst: /* tmp306 = */ aux_24 (arg0, arg1, 0) ; return /* (tmp306) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 15989(line=547, offs=19) -- 16036(line=547, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_labs2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; // ATSlocal_void (tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_labs2explst: tmp318 = atspre_stdout_get () ; tmp319 = ats_selsin_mac(tmp318, atslab_1) ; /* tmp320 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst (tmp319, arg0) ; /* tmp317 = */ atspre_stdout_view_set () ; return /* (tmp317) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_labs2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16065(line=549, offs=19) -- 16112(line=549, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_labs2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_labs2explst: tmp322 = atspre_stderr_get () ; tmp323 = ats_selsin_mac(tmp322, atslab_1) ; /* tmp324 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2explst (tmp323, arg0) ; /* tmp321 = */ atspre_stderr_view_set () ; return /* (tmp321) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_labs2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16231(line=557, offs=7) -- 16630(line=571, offs=33) */ ATSstaticdec() ats_void_type aux_28 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; // ATSlocal_void (tmp329) ; ATSlocal (ats_bool_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_int_type, tmp332) ; __ats_lab_aux_28: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; tmp328 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_2) ; tmp330 = atspre_gt_int_int (arg2, 0) ; if (tmp330) { /* tmp329 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; } else { /* empty */ } /* end of [if] */ /* tmp331 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp327) ; tmp332 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp328 ; arg2 = tmp332 ; goto __ats_lab_aux_28 ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: break ; } while (0) ; return /* (tmp326) */ ; } /* end of [aux_28] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16173(line=555, offs=7) -- 16650(line=573, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp325) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst: /* tmp325 = */ aux_28 (arg0, arg1, 0) ; return /* (tmp325) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16716(line=576, offs=3) -- 16768(line=576, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_tmps2explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; // ATSlocal_void (tmp336) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_tmps2explstlst: tmp334 = atspre_stdout_get () ; tmp335 = ats_selsin_mac(tmp334, atslab_1) ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst (tmp335, arg0) ; /* tmp333 = */ atspre_stdout_view_set () ; return /* (tmp333) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_tmps2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16802(line=578, offs=3) -- 16854(line=578, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_tmps2explstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; // ATSlocal_void (tmp340) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_tmps2explstlst: tmp338 = atspre_stderr_get () ; tmp339 = ats_selsin_mac(tmp338, atslab_1) ; /* tmp340 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_tmps2explstlst (tmp339, arg0) ; /* tmp337 = */ atspre_stderr_view_set () ; return /* (tmp337) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_tmps2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16970(line=585, offs=7) -- 17676(line=605, offs=6) */ ATSstaticdec() ats_void_type aux_32 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; // ATSlocal_void (tmp345) ; ATSlocal (ats_bool_type, tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_int_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; // ATSlocal_void (tmp352) ; ATSlocal (ats_bool_type, tmp353) ; // ATSlocal_void (tmp354) ; ATSlocal (ats_int_type, tmp355) ; __ats_lab_aux_32: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp343 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_1) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_2) ; tmp346 = atspre_gt_int_int (arg2, 0) ; if (tmp346) { /* tmp345 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; } else { /* empty */ } /* end of [if] */ /* tmp347 = */ atspre_fprint_string (arg0, ATSstrcst("Some(")) ; /* tmp348 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp343) ; /* tmp349 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; tmp350 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp344 ; arg2 = tmp350 ; goto __ats_lab_aux_32 ; // tail call break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp353 = atspre_gt_int_int (arg2, 0) ; if (tmp353) { /* tmp352 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; } else { /* empty */ } /* end of [if] */ /* tmp354 = */ atspre_fprint_string (arg0, ATSstrcst("None()")) ; tmp355 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp351 ; arg2 = tmp355 ; goto __ats_lab_aux_32 ; // tail call break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_65_1: break ; } while (0) ; return /* (tmp342) */ ; } /* end of [aux_32] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 16912(line=584, offs=3) -- 17694(line=606, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp341) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst: /* tmp341 = */ aux_32 (arg0, arg1, 0) ; return /* (tmp341) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 17760(line=610, offs=3) -- 17811(line=610, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_wths2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; // ATSlocal_void (tmp359) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_wths2explst: tmp357 = atspre_stdout_get () ; tmp358 = ats_selsin_mac(tmp357, atslab_1) ; /* tmp359 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst (tmp358, arg0) ; /* tmp356 = */ atspre_stdout_view_set () ; return /* (tmp356) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_wths2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 17873(line=615, offs=3) -- 17924(line=615, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_wths2explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; // ATSlocal_void (tmp363) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_wths2explst: tmp361 = atspre_stderr_get () ; tmp362 = ats_selsin_mac(tmp361, atslab_1) ; /* tmp363 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_wths2explst (tmp362, arg0) ; /* tmp360 = */ atspre_stderr_view_set () ; return /* (tmp360) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_wths2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18000(line=621, offs=14) -- 18446(line=633, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; // ATSlocal_void (tmp371) ; // ATSlocal_void (tmp372) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab: do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp365 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp365) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp366 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp367 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp368 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp366) ; /* tmp364 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp369 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp369) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: // if (((ats_sum_ptr_type)arg1)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_69_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; /* tmp371 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp370) ; /* tmp364 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; break ; } while (0) ; return /* (tmp364) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18498(line=636, offs=13) -- 18535(line=636, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; // ATSlocal_void (tmp376) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lab: tmp374 = atspre_stdout_get () ; tmp375 = ats_selsin_mac(tmp374, atslab_1) ; /* tmp376 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab (tmp375, arg0) ; /* tmp373 = */ atspre_stdout_view_set () ; return /* (tmp373) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18558(line=638, offs=13) -- 18595(line=638, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; // ATSlocal_void (tmp380) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab: tmp378 = atspre_stderr_get () ; tmp379 = ats_selsin_mac(tmp378, atslab_1) ; /* tmp380 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab (tmp379, arg0) ; /* tmp377 = */ atspre_stderr_view_set () ; return /* (tmp377) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18644(line=643, offs=17) -- 18712(line=644, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp381) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst: /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lab) ; return /* (tmp381) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18770(line=648, offs=16) -- 18812(line=648, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; // ATSlocal_void (tmp385) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lablst: tmp383 = atspre_stdout_get () ; tmp384 = ats_selsin_mac(tmp383, atslab_1) ; /* tmp385 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst (tmp384, arg0) ; /* tmp382 = */ atspre_stdout_view_set () ; return /* (tmp382) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18838(line=650, offs=16) -- 18880(line=650, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; // ATSlocal_void (tmp389) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lablst: tmp387 = atspre_stderr_get () ; tmp388 = ats_selsin_mac(tmp387, atslab_1) ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2lablst (tmp388, arg0) ; /* tmp386 = */ atspre_stderr_view_set () ; return /* (tmp386) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 18927(line=655, offs=15) -- 20156(line=695, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; // ATSlocal_void (tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; // ATSlocal_void (tmp405) ; // ATSlocal_void (tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp: do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEany()")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp391 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp392 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp393 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEapp(")) ; /* tmp394 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (arg0, tmp391) ; /* tmp395 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst (arg0, tmp392) ; /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp397 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp397) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp398 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp399 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp400 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_2) ; /* tmp401 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEfun(")) ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp398) ; /* tmp403 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp404 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst (arg0, tmp399) ; /* tmp405 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp406 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (arg0, tmp400) ; /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_75_0 ; } __ats_lab_74_1: /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEtyarr()")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp408 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEtyrec(")) ; /* tmp409 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2kexplst (arg0, tmp407) ; /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp410 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp411 = */ atspre_fprint_string (arg0, ATSstrcst("S2KEunion(")) ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst (arg0, tmp410) ; /* tmp390 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (((ats_sum_ptr_type)arg1)->tag != 7) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp413) ; break ; } while (0) ; return /* (tmp390) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 20207(line=698, offs=14) -- 20247(line=698, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2kexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; // ATSlocal_void (tmp417) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2kexp: tmp415 = atspre_stdout_get () ; tmp416 = ats_selsin_mac(tmp415, atslab_1) ; /* tmp417 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (tmp416, arg0) ; /* tmp414 = */ atspre_stdout_view_set () ; return /* (tmp414) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2kexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 20271(line=700, offs=14) -- 20311(line=700, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2kexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; // ATSlocal_void (tmp421) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2kexp: tmp419 = atspre_stderr_get () ; tmp420 = ats_selsin_mac(tmp419, atslab_1) ; /* tmp421 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (tmp420, arg0) ; /* tmp418 = */ atspre_stderr_view_set () ; return /* (tmp418) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2kexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 20361(line=705, offs=18) -- 20430(line=706, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp422) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst: /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp) ; return /* (tmp422) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 20549(line=714, offs=7) -- 21053(line=730, offs=6) */ ATSstaticdec() ats_void_type aux_46 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; // ATSlocal_void (tmp428) ; ATSlocal (ats_bool_type, tmp429) ; // ATSlocal_void (tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; ATSlocal (ats_int_type, tmp433) ; __ats_lab_aux_46: do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp425 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; tmp427 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_2) ; tmp429 = atspre_gt_int_int (arg2, 0) ; if (tmp429) { /* tmp428 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp430 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp425) ; /* tmp431 = */ atspre_fprint_string (arg0, ATSstrcst("=")) ; /* tmp432 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (arg0, tmp426) ; tmp433 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp427 ; arg2 = tmp433 ; goto __ats_lab_aux_46 ; // tail call break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: break ; } while (0) ; return /* (tmp424) */ ; } /* end of [aux_46] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 20518(line=713, offs=7) -- 21099(line=733, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2kexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp423) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2kexplst: /* tmp423 = */ aux_46 (arg0, arg1, 0) ; return /* (tmp423) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2kexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 21181(line=738, offs=15) -- 22611(line=784, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; // ATSlocal_void (tmp438) ; // ATSlocal_void (tmp439) ; // ATSlocal_void (tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; // ATSlocal_void (tmp442) ; // ATSlocal_void (tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; // ATSlocal_void (tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; // ATSlocal_void (tmp454) ; // ATSlocal_void (tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; // ATSlocal_void (tmp457) ; // ATSlocal_void (tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; // ATSlocal_void (tmp460) ; // ATSlocal_void (tmp461) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp437 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEapp(")) ; /* tmp438 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (arg0, tmp435) ; /* tmp439 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp440 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexplst (arg0, tmp436) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_82_0 ; } __ats_lab_81_1: /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEbot()")) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp441 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp442 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEcst(")) ; /* tmp443 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2cst (arg0, tmp441) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp445 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEextype(")) ; /* tmp446 = */ atspre_fprint_string (arg0, tmp444) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_85_0 ; } __ats_lab_84_1: /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEptr()")) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp447 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp448 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp449 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEtyarr(")) ; /* tmp450 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (arg0, tmp447) ; /* tmp451 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp452 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explstlst (arg0, tmp448) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp453 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp454 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEtyrec(")) ; /* tmp455 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst (arg0, tmp453) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_18, arg1, atslab_1) ; /* tmp457 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEunion(")) ; /* tmp458 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst (arg0, tmp456) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: // if (((ats_sum_ptr_type)arg1)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_88_1: tmp459 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp460 = */ atspre_fprint_string (arg0, ATSstrcst("S2ZEvar(")) ; /* tmp461 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp459) ; /* tmp434 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp434) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 22665(line=787, offs=14) -- 22705(line=787, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2zexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; // ATSlocal_void (tmp465) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2zexp: tmp463 = atspre_stdout_get () ; tmp464 = ats_selsin_mac(tmp463, atslab_1) ; /* tmp465 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (tmp464, arg0) ; /* tmp462 = */ atspre_stdout_view_set () ; return /* (tmp462) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2zexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 22730(line=790, offs=14) -- 22770(line=790, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2zexp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; // ATSlocal_void (tmp469) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2zexp: tmp467 = atspre_stderr_get () ; tmp468 = ats_selsin_mac(tmp467, atslab_1) ; /* tmp469 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (tmp468, arg0) ; /* tmp466 = */ atspre_stderr_view_set () ; return /* (tmp466) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2zexp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 22820(line=795, offs=18) -- 22889(line=796, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp470) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexplst: /* tmp470 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp) ; return /* (tmp470) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 23011(line=804, offs=7) -- 23436(line=814, offs=31) */ ATSstaticdec() ats_void_type aux_52 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; // ATSlocal_void (tmp476) ; ATSlocal (ats_bool_type, tmp477) ; // ATSlocal_void (tmp478) ; // ATSlocal_void (tmp479) ; // ATSlocal_void (tmp480) ; ATSlocal (ats_int_type, tmp481) ; __ats_lab_aux_52: do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp473 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp474 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; tmp475 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_2) ; tmp477 = atspre_gt_int_int (arg2, 0) ; if (tmp477) { /* tmp476 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp478 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp473) ; /* tmp479 = */ atspre_fprint_string (arg0, ATSstrcst("=")) ; /* tmp480 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2zexp (arg0, tmp474) ; tmp481 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp475 ; arg2 = tmp481 ; goto __ats_lab_aux_52 ; // tail call break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: break ; } while (0) ; return /* (tmp472) */ ; } /* end of [aux_52] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 22980(line=803, offs=7) -- 23512(line=818, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp471) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst: /* tmp471 = */ aux_52 (arg0, arg1, 0) ; return /* (tmp471) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_labs2zexplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 23596(line=823, offs=17) -- 23806(line=827, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparg (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparg: tmp483 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg1), atslab_s2exparg_node) ; do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp483)->tag != 0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: /* tmp482 = */ atspre_fprint_string (arg0, ATSstrcst("..")) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp483)->tag != 1) { goto __ats_lab_93_0 ; } __ats_lab_92_1: /* tmp482 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (((ats_sum_ptr_type)tmp483)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp484 = ats_caselptrlab_mac(anairiats_sum_2, tmp483, atslab_0) ; /* tmp482 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp484) ; break ; } while (0) ; return /* (tmp482) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 23886(line=833, offs=20) -- 23957(line=834, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp485) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst: /* tmp485 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparg) ; return /* (tmp485) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24021(line=838, offs=19) -- 24066(line=838, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exparglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; // ATSlocal_void (tmp489) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exparglst: tmp487 = atspre_stdout_get () ; tmp488 = ats_selsin_mac(tmp487, atslab_1) ; /* tmp489 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst (tmp488, arg0) ; /* tmp486 = */ atspre_stdout_view_set () ; return /* (tmp486) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24095(line=840, offs=19) -- 24140(line=840, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exparglst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; // ATSlocal_void (tmp493) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exparglst: tmp491 = atspre_stderr_get () ; tmp492 = ats_selsin_mac(tmp491, atslab_1) ; /* tmp493 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exparglst (tmp492, arg0) ; /* tmp490 = */ atspre_stderr_view_set () ; return /* (tmp490) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24188(line=846, offs=3) -- 24390(line=852, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qua (ats_ref_type arg0, anairiats_rec_0 arg1) { /* local vardec */ // ATSlocal_void (tmp494) ; // ATSlocal_void (tmp495) ; // ATSlocal_void (tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; // ATSlocal_void (tmp498) ; // ATSlocal_void (tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qua: /* tmp495 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; tmp497 = ats_select_mac(arg1, atslab_0) ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (arg0, tmp497) ; /* tmp498 = */ atspre_fprint_string (arg0, ATSstrcst(" | ")) ; tmp500 = ats_select_mac(arg1, atslab_1) ; /* tmp499 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2explst (arg0, tmp500) ; /* tmp494 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp494) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qua] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24499(line=859, offs=7) -- 24809(line=870, offs=19) */ ATSstaticdec() ats_void_type aux_59 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp502) ; ATSlocal (anairiats_rec_0, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; // ATSlocal_void (tmp505) ; ATSlocal (ats_bool_type, tmp506) ; // ATSlocal_void (tmp507) ; ATSlocal (ats_int_type, tmp508) ; __ats_lab_aux_59: do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_20, arg2, atslab_0) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_20, arg2, atslab_1) ; tmp506 = atspre_gt_int_int (arg1, 0) ; if (tmp506) { /* tmp505 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp507 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qua (arg0, tmp503) ; tmp508 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp508 ; arg2 = tmp504 ; goto __ats_lab_aux_59 ; // tail call break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_95_1: break ; } while (0) ; return /* (tmp502) */ ; } /* end of [aux_59] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24470(line=858, offs=7) -- 24871(line=874, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp501) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst: /* tmp501 = */ aux_59 (arg0, 0, arg1) ; return /* (tmp501) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24926(line=877, offs=16) -- 24968(line=877, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2qualst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; // ATSlocal_void (tmp512) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2qualst: tmp510 = atspre_stdout_get () ; tmp511 = ats_selsin_mac(tmp510, atslab_1) ; /* tmp512 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst (tmp511, arg0) ; /* tmp509 = */ atspre_stdout_view_set () ; return /* (tmp509) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2qualst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_print.dats: 24994(line=879, offs=16) -- 25036(line=879, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2qualst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; // ATSlocal_void (tmp516) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2qualst: tmp514 = atspre_stderr_get () ; tmp515 = ats_selsin_mac(tmp514, atslab_1) ; /* tmp516 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2qualst (tmp515, arg0) ; /* tmp513 = */ atspre_stderr_view_set () ; return /* (tmp513) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2qualst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_reference_dats.c0000664000175000017500000000605612223166160022064 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_reference_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_macro2_sats.c0000664000175000017500000000263612223166160021330 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_macro2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_env_dats.c0000664000175000017500000070664412223166160022111 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_funentry_loc ; ats_ptr_type atslab_funentry_lab ; ats_int_type atslab_funentry_lev ; ats_ptr_type atslab_funentry_vtps ; ats_int_type atslab_funentry_vtps_flag ; ats_ptr_type atslab_funentry_labset ; ats_ptr_type atslab_funentry_ret ; ats_ptr_type atslab_funentry_body ; ats_ptr_type atslab_funentry_tailjoin ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_12 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; /* external typedefs */ typedef anairiats_rec_10 *funentry_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYrec_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYsum_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYuni_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_clo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_fun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_val_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Bl_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Br_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_compare_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isucc) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_compare_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_stropt_is_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_tostringf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, atsopt_namespace_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_revapp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_fun_coerce) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_proof) ; ATSextern_fun(ats_void_type, atsopt_d2cst_set_hityp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_vartyp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlab) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funlab_set_entry) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_mem) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funentry_set_vtps) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_flag) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funentry_set_vtps_flag) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_typkey_typkey) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_set) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdeflst_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_rec) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_sum) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_uni) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__sasp__funentry_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__sasp__funlab_token = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__dyncstset_type = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__dynconset_type = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTnil_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_ptr_type ref_make_elt_04079_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type ref_make_elt_04079_ats_int_type (ats_int_type arg0) ; static ats_ptr_type aux_10 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type typdeflst_reverse_9 (ats_ptr_type arg0) ; static ats_ptr_type typdefmap_nil_13 () ; static ats_int_type bst_size_0166_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_0205_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01733_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_0194_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01735_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type list_vt_free_01723_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type aux_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type datcstlst_reverse_28 (ats_ptr_type arg0) ; static ats_ptr_type aux_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type exnconlst_reverse_34 (ats_ptr_type arg0) ; static ats_int_type avl_height_04089_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type avl_rotate_l_04093_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_rotate_r_04094_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_insert_br_04096_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_insert_04095_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_insert_01741_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_50 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type __ats_fun_55 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_55_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_int_type __ats_fun_55_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type avl_join_r_04099_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_join_l_04098_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type avl_split_br_04102_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_int_type avl_split_04101_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type avl_union_br_04108_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_union_04107_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_union_01744_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type avl_foreach_04092_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type set_foreach_main_01745_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type app_65 (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; static ats_void_type set_foreach_cloptr_01746_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; static ats_void_type f_67 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type avl_member_04090_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type set_member_01740_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type f_77 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type dyncstset_add_81 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type dyncstset_add_if_82 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_91 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type extvalist_reverse_90 (ats_ptr_type arg0) ; static ats_ptr_type aux_96 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type extcodelst_reverse_95 (ats_ptr_type arg0) ; static ats_ptr_type aux_101 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type stafilelst_reverse_100 (ats_ptr_type arg0) ; static ats_ptr_type err_111 () ; static ats_ptr_type _funentry_make_112 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_void_type aux_125 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_125_closure_make (ats_int_type env0) ; static ats_void_type aux_125_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type funentry_get_labset_all_124 (ats_ptr_type arg0) ; static ats_void_type aux_127 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type varindmap_nil_128 () ; static ats_ptr_type bst_search_0194_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01735_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type bst_free_0162_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_void_type map_free_01731_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_int_type bst_size_0166_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_0171_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_0205_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01733_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type f_137 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type tmplab_gen_147 () ; static ats_ptr_type aux_149 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type glocstlst_reverse_148 (ats_ptr_type arg0) ; static ats_ptr_type aux_155 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type partvalst_reverse_154 (ats_ptr_type arg0) ; static ats_ptr_type cstctx_nil_158 () ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp30) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp41) ; ATSstatic (ats_ptr_type, statmp42) ; ATSstatic (ats_ptr_type, statmp60) ; ATSstatic (ats_ptr_type, statmp61) ; ATSstatic (ats_ptr_type, statmp175) ; ATSstatic (ats_ptr_type, statmp176) ; ATSstatic (ats_ptr_type, statmp190) ; ATSstatic (ats_ptr_type, statmp191) ; ATSstatic (ats_ptr_type, statmp214) ; ATSstatic (ats_ptr_type, statmp215) ; ATSstatic (ats_ptr_type, statmp238) ; ATSstatic (ats_ptr_type, statmp239) ; ATSstatic (ats_ptr_type, statmp240) ; ATSstatic (ats_ptr_type, statmp501) ; ATSstatic (ats_ptr_type, statmp502) ; ATSstatic (ats_ptr_type, statmp503) ; ATSstatic (ats_ptr_type, statmp548) ; ATSstatic (ats_ptr_type, statmp554) ; ATSstatic (ats_ptr_type, statmp555) ; ATSstatic (ats_ptr_type, statmp556) ; ATSstatic (ats_ptr_type, statmp598) ; ATSstatic (ats_ptr_type, statmp599) ; ATSstatic (ats_ptr_type, statmp610) ; ATSstatic (ats_ptr_type, statmp611) ; ATSstatic (ats_ptr_type, statmp630) ; ATSstatic (ats_ptr_type, statmp631) ; ATSstatic (ats_ptr_type, statmp650) ; ATSstatic (ats_ptr_type, statmp651) ; ATSstatic (ats_ptr_type, statmp670) ; ATSstatic (ats_ptr_type, statmp671) ; ATSstatic (ats_ptr_type, statmp684) ; ATSstatic (ats_ptr_type, statmp685) ; ATSstatic (ats_ptr_type, statmp760) ; ATSstatic (ats_ptr_type, statmp761) ; ATSstatic (ats_ptr_type, statmp867) ; ATSstatic (ats_ptr_type, statmp868) ; ATSstatic (ats_ptr_type, statmp879) ; ATSstatic (ats_ptr_type, statmp880) ; ATSstatic (ats_ptr_type, statmp908) ; ATSstatic (ats_ptr_type, statmp909) ; ATSstatic (ats_ptr_type, statmp942) ; ATSstatic (ats_ptr_type, statmp943) ; ATSstatic (ats_ptr_type, statmp961) ; ATSstatic (ats_ptr_type, statmp962) ; ATSstatic (ats_ptr_type, statmp971) ; ATSstatic (ats_ptr_type, statmp972) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 2175(line=69, offs=4) -- 2233(line=69, offs=62) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_env)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 2402(line=79, offs=23) -- 2743(line=89, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; ATSlocal (ats_bool_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_1 ; } __ats_lab_0_2: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp4 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp6 = atspre_compare_string_string (tmp2, tmp4) ; tmp7 = atspre_ineq (tmp6, 0) ; if (tmp7) { tmp1 = tmp6 ; } else { arg0 = tmp3 ; arg1 = tmp5 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_2_0 ; } __ats_lab_1_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_2: tmp1 = 1 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_1 ; } __ats_lab_2_2: tmp1 = -1 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_2: tmp1 = 0 ; break ; } while (0) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 2950(line=98, offs=3) -- 3432(line=112, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_bool_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_1 ; } __ats_lab_4_2: tmp9 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp10 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp11 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp12 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_2) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (tmp9, tmp12) ; tmp16 = atspre_ineq (tmp15, 0) ; if (tmp16) { tmp8 = tmp15 ; } else { tmp17 = atspre_compare_string_string (tmp10, tmp13) ; tmp18 = atspre_ineq (tmp17, 0) ; if (tmp18) { tmp8 = tmp17 ; } else { arg0 = tmp11 ; arg1 = tmp14 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst ; // tail call } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_2: tmp8 = 1 ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_7_1 ; } __ats_lab_6_2: tmp8 = 0 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_2: tmp8 = -1 ; break ; } while (0) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 3617(line=120, offs=23) -- 4064(line=132, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_typkey_typkey (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_bool_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_typkey_typkey: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_9_1 ; } __ats_lab_8_2: tmp20 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst (tmp20, tmp21) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: __ats_lab_9_2: tmp19 = -1 ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_11_0 ; } __ats_lab_10_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_11_1 ; } __ats_lab_10_2: tmp22 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp26 = atspre_compare_int_int (tmp22, tmp24) ; tmp27 = atspre_ineq (tmp26, 0) ; if (tmp27) { tmp19 = tmp26 ; } else { tmp19 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_strlst_strlst (tmp23, tmp25) ; } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_12_0 ; } __ats_lab_11_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_12_1 ; } __ats_lab_11_2: tmp19 = 1 ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_12_2: tmp19 = -1 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_14_1 ; } __ats_lab_13_2: tmp28 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp29 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_labstrlst_labstrlst (tmp28, tmp29) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: __ats_lab_14_2: tmp19 = 1 ; break ; } while (0) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_typkey_typkey] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_04079_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ref_make_elt_04079_ats_ptr_type: /* ats_ptr_type tmp32 ; */ tmp32 = arg0 ; tmp31 = atspre_ref_make_elt_tsz ((&tmp32), sizeof(ats_ptr_type)) ; return (tmp31) ; } /* end of [ref_make_elt_04079_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_04079_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; __ats_lab_ref_make_elt_04079_ats_int_type: /* ats_int_type tmp35 ; */ tmp35 = arg0 ; tmp34 = atspre_ref_make_elt_tsz ((&tmp35), sizeof(ats_int_type)) ; return (tmp34) ; } /* end of [ref_make_elt_04079_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 4365(line=146, offs=27) -- 4386(line=146, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get: tmp36 = ats_ptrget_mac(ats_ptr_type, statmp30) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 4413(line=147, offs=27) -- 4446(line=147, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_set (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_set: ats_ptrget_mac(ats_ptr_type, statmp30) = arg0 ; return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_set] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 4528(line=152, offs=26) -- 4610(line=154, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc () { /* local vardec */ ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc: tmp39 = ats_ptrget_mac(ats_int_type, statmp33) ; tmp40 = atspre_add_int_int (tmp39, 1) ; ats_ptrget_mac(ats_int_type, statmp33) = tmp40 ; tmp38 = tmp39 ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 4817(line=166, offs=7) -- 5107(line=174, offs=6) */ ATSstaticdec() ats_ptr_type aux_10 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_aux_10: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp45 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp46 = ats_ptrget_mac(ats_ptr_type, tmp45) ; ats_ptrget_mac(ats_ptr_type, tmp45) = arg1 ; tmp47 = arg0 ; arg0 = tmp46 ; arg1 = tmp47 ; goto __ats_lab_aux_10 ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp44 = arg1 ; break ; } while (0) ; return (tmp44) ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 4758(line=164, offs=4) -- 5158(line=177, offs=4) */ ATSstaticdec() ats_ptr_type typdeflst_reverse_9 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_typdeflst_reverse_9: tmp48 = (ats_sum_ptr_type)0 ; tmp43 = aux_10 (arg0, tmp48) ; return (tmp43) ; } /* end of [typdeflst_reverse_9] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 5277(line=185, offs=15) -- 5414(line=190, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdeflst_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdeflst_add: tmp50 = atspre_ref_get_view_ptr (statmp41) ; tmp51 = ats_selsin_mac(tmp50, atslab_1) ; tmp53 = ats_ptrget_mac(ats_ptr_type, tmp51) ; tmp52 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp52, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp52, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp52, atslab_2, tmp53) ; ats_ptrget_mac(ats_ptr_type, tmp51) = tmp52 ; return /* (tmp49) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdeflst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 5458(line=192, offs=25) -- 5671(line=202, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__typdeflst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__typdeflst_get: tmp55 = atspre_ref_get_view_ptr (statmp41) ; tmp56 = ats_selsin_mac(tmp55, atslab_1) ; tmp57 = ats_ptrget_mac(ats_ptr_type, tmp56) ; tmp58 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp56) = tmp58 ; tmp54 = typdeflst_reverse_9 (tmp57) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__typdeflst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 5807(line=213, offs=4) -- 5865(line=214, offs=40) */ ATSstaticdec() ats_ptr_type typdefmap_nil_13 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_typdefmap_nil_13: tmp59 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__compare_typkey_typkey) ; return (tmp59) ; } /* end of [typdefmap_nil_13] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_0166_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp98) ; ATSlocal (ats_int_type, tmp99) ; __ats_lab_bst_size_0166_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp99 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp98 = tmp99 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp98 = 0 ; break ; } while (0) ; return (tmp98) ; } /* end of [bst_size_0166_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_bool_type, tmp89) ; ATSlocal (ats_int_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_int_type, tmp96) ; ATSlocal (ats_int_type, tmp97) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_int_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_int_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_int_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp85 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp86 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp87 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp88 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp90 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp86) ; tmp89 = atspre_ilte (tmp90, 0) ; if (tmp89) { tmp92 = ats_ptrget_mac(ats_ptr_type, tmp87) ; tmp91 = bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type (tmp92, arg1, arg2, arg3) ; // if (tmp91 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp93 = &ats_caselptrlab_mac(anairiats_sum_5, tmp91, atslab_0) ; tmp94 = &ats_caselptrlab_mac(anairiats_sum_5, tmp91, atslab_3) ; tmp95 = &ats_caselptrlab_mac(anairiats_sum_5, tmp91, atslab_4) ; tmp96 = ats_ptrget_mac(ats_int_type, tmp85) ; tmp100 = ats_ptrget_mac(ats_ptr_type, tmp94) ; tmp97 = bst_size_0166_ats_ptr_type_2cats_ptr_type (tmp100) ; tmp101 = ats_ptrget_mac(ats_ptr_type, tmp95) ; ats_ptrget_mac(ats_ptr_type, tmp87) = tmp101 ; tmp102 = atspre_isub (tmp96, tmp97) ; ats_ptrget_mac(ats_int_type, tmp85) = tmp102 ; ats_ptrget_mac(ats_ptr_type, tmp95) = arg0 ; tmp103 = atspre_iadd (tmp96, 1) ; ats_ptrget_mac(ats_int_type, tmp93) = tmp103 ; tmp84 = tmp91 ; } else { tmp105 = ats_ptrget_mac(ats_ptr_type, tmp88) ; tmp104 = bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type (tmp105, arg1, arg2, arg3) ; // if (tmp104 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp106 = &ats_caselptrlab_mac(anairiats_sum_5, tmp104, atslab_0) ; tmp107 = &ats_caselptrlab_mac(anairiats_sum_5, tmp104, atslab_3) ; tmp108 = &ats_caselptrlab_mac(anairiats_sum_5, tmp104, atslab_4) ; tmp109 = ats_ptrget_mac(ats_int_type, tmp85) ; tmp111 = ats_ptrget_mac(ats_ptr_type, tmp108) ; tmp110 = bst_size_0166_ats_ptr_type_2cats_ptr_type (tmp111) ; tmp112 = ats_ptrget_mac(ats_ptr_type, tmp107) ; ats_ptrget_mac(ats_ptr_type, tmp88) = tmp112 ; tmp113 = atspre_isub (tmp109, tmp110) ; ats_ptrget_mac(ats_int_type, tmp85) = tmp113 ; ats_ptrget_mac(ats_ptr_type, tmp107) = arg0 ; tmp114 = atspre_iadd (tmp109, 1) ; ats_ptrget_mac(ats_int_type, tmp106) = tmp114 ; tmp84 = tmp104 ; } /* end of [if] */ break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp115 = (ats_sum_ptr_type)0 ; tmp116 = (ats_sum_ptr_type)0 ; tmp84 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp84, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_5, tmp84, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp84, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp84, atslab_3, tmp115) ; ats_selptrset_mac(anairiats_sum_5, tmp84, atslab_4, tmp116) ; break ; } while (0) ; return (tmp84) ; } /* end of [bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_0205_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; ATSlocal (ats_bool_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_int_type, tmp125) ; ATSlocal (ats_int_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_bst_insert_random_0205_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_17_1: tmp78 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp80 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp81 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp83 = ats_ptrget_mac(ats_int_type, tmp78) ; tmp82 = atsopt_map_lin_dice (1, tmp83) ; if (tmp82) { tmp77 = bst_insert_atroot_0171_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp118 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp79) ; tmp117 = atspre_ilte (tmp118, 0) ; if (tmp117) { tmp120 = ats_ptrget_mac(ats_ptr_type, tmp80) ; tmp119 = bst_insert_random_0205_ats_ptr_type_2cats_ptr_type (tmp120, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp80) = tmp119 ; tmp122 = ats_ptrget_mac(ats_int_type, tmp78) ; tmp121 = atspre_iadd (tmp122, 1) ; ats_ptrget_mac(ats_int_type, tmp78) = tmp121 ; tmp77 = arg0 ; } else { tmp124 = ats_ptrget_mac(ats_ptr_type, tmp81) ; tmp123 = bst_insert_random_0205_ats_ptr_type_2cats_ptr_type (tmp124, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp81) = tmp123 ; tmp126 = ats_ptrget_mac(ats_int_type, tmp78) ; tmp125 = atspre_iadd (tmp126, 1) ; ats_ptrget_mac(ats_int_type, tmp78) = tmp125 ; tmp77 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp127 = (ats_sum_ptr_type)0 ; tmp128 = (ats_sum_ptr_type)0 ; tmp77 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_3, tmp127) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_4, tmp128) ; break ; } while (0) ; return (tmp77) ; } /* end of [bst_insert_random_0205_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01733_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_map_insert_01733_ats_ptr_type_2cats_ptr_type: // tmp74 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp75 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp129 = ats_ptrget_mac(ats_ptr_type, tmp75) ; tmp76 = bst_insert_random_0205_ats_ptr_type_2cats_ptr_type (tmp129, arg1, arg2, tmp74) ; ats_ptrget_mac(ats_ptr_type, tmp75) = tmp76 ; return /* (tmp73) */ ; } /* end of [map_insert_01733_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 6227(line=232, offs=19) -- 6871(line=255, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_rec (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_int_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_bool_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_rec: tmp63 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get () ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc () ; tmp65 = atsopt_namespace_get () ; tmp67 = atspre_stropt_is_some (tmp65) ; if (tmp67) { tmp68 = atspre_tostringf (ATSstrcst("%s%s_rec_%i"), ats_castfn_mac(ats_ptr_type, tmp65), tmp63, tmp64) ; tmp66 = ats_castfn_mac(ats_ptr_type, tmp68) ; } else { tmp69 = atspre_tostringf (ATSstrcst("%s_rec_%i"), tmp63, tmp64) ; tmp66 = ats_castfn_mac(ats_ptr_type, tmp69) ; } /* end of [if] */ tmp70 = atspre_ref_get_view_ptr (statmp60) ; tmp71 = ats_selsin_mac(tmp70, atslab_1) ; tmp130 = ats_ptrget_mac(ats_ptr_type, tmp71) ; /* tmp72 = */ map_insert_01733_ats_ptr_type_2cats_ptr_type (tmp130, arg0, tmp66) ; tmp62 = tmp66 ; return (tmp62) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 6931(line=258, offs=19) -- 7575(line=281, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_sum (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_bool_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; // ATSlocal_void (tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_sum: tmp132 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get () ; tmp133 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc () ; tmp134 = atsopt_namespace_get () ; tmp136 = atspre_stropt_is_some (tmp134) ; if (tmp136) { tmp137 = atspre_tostringf (ATSstrcst("%s%s_sum_%i"), ats_castfn_mac(ats_ptr_type, tmp134), tmp132, tmp133) ; tmp135 = ats_castfn_mac(ats_ptr_type, tmp137) ; } else { tmp138 = atspre_tostringf (ATSstrcst("%s_sum_%i"), tmp132, tmp133) ; tmp135 = ats_castfn_mac(ats_ptr_type, tmp138) ; } /* end of [if] */ tmp139 = atspre_ref_get_view_ptr (statmp60) ; tmp140 = ats_selsin_mac(tmp139, atslab_1) ; tmp142 = ats_ptrget_mac(ats_ptr_type, tmp140) ; /* tmp141 = */ map_insert_01733_ats_ptr_type_2cats_ptr_type (tmp142, arg0, tmp135) ; tmp131 = tmp135 ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_sum] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 7635(line=284, offs=19) -- 8288(line=307, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_uni (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_bool_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; // ATSlocal_void (tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_uni: tmp144 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_base_get () ; tmp145 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdef_count_get_and_inc () ; tmp146 = atsopt_namespace_get () ; tmp148 = atspre_stropt_is_some (tmp146) ; if (tmp148) { tmp149 = atspre_tostringf (ATSstrcst("%s%s_uni_%i"), ats_castfn_mac(ats_ptr_type, tmp146), tmp144, tmp145) ; tmp147 = ats_castfn_mac(ats_ptr_type, tmp149) ; } else { tmp150 = atspre_tostringf (ATSstrcst("%s_uni_%i"), tmp144, tmp145) ; tmp147 = ats_castfn_mac(ats_ptr_type, tmp150) ; } /* end of [if] */ tmp151 = atspre_ref_get_view_ptr (statmp60) ; tmp152 = ats_selsin_mac(tmp151, atslab_1) ; tmp154 = ats_ptrget_mac(ats_ptr_type, tmp152) ; /* tmp153 = */ map_insert_01733_ats_ptr_type_2cats_ptr_type (tmp154, arg0, tmp147) ; tmp143 = tmp147 ; return (tmp143) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_0194_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_int_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; __ats_lab_bst_search_0194_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_23_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_2) ; tmp165 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_3) ; tmp166 = &ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_4) ; tmp167 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp163) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp167 != -1) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp168 = ats_ptrget_mac(ats_ptr_type, tmp165) ; arg0 = tmp168 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0194_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp167 != 1) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp169 = ats_ptrget_mac(ats_ptr_type, tmp166) ; arg0 = tmp169 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0194_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp167 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp162 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp162, atslab_0, tmp164) ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp162 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp162) ; } /* end of [bst_search_0194_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01735_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_map_search_01735_ats_ptr_type_2cats_ptr_type: // tmp160 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp161 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp170 = ats_ptrget_mac(ats_ptr_type, tmp161) ; tmp159 = bst_search_0194_ats_ptr_type_2cats_ptr_type (tmp170, arg1, tmp160) ; return (tmp159) ; } /* end of [map_search_01735_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 8345(line=310, offs=16) -- 8857(line=330, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; // ATSlocal_void (tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find: tmp156 = atspre_ref_get_view_ptr (statmp60) ; tmp157 = ats_selsin_mac(tmp156, atslab_1) ; tmp171 = ats_ptrget_mac(ats_ptr_type, tmp157) ; tmp158 = map_search_01735_ats_ptr_type_2cats_ptr_type (tmp171, arg0) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp158 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_6, tmp158, atslab_0) ; ATS_FREE(tmp158) ; tmp155 = tmp172 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp158 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp173 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_rec (arg0) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp173 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_sum (arg0) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp173 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdefmap_add_uni (arg0) ; break ; } while (0) ; /* tmp174 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__typdeflst_add (arg0, tmp173) ; tmp155 = tmp173 ; break ; } while (0) ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__typdefmap_find] */ /* // /home/hwxi/research/Anairiats/src/ats_list.dats: 7914(line=306, offs=27) -- 8015(line=310, offs=4) */ ATSstaticdec() ats_void_type list_vt_free_01723_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_list_vt_free_01723_ats_ptr_type: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp179 ; goto __ats_lab_list_vt_free_01723_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: break ; } while (0) ; return /* (tmp178) */ ; } /* end of [list_vt_free_01723_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 9028(line=343, offs=17) -- 9056(line=343, offs=45) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__saspcstlst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp177) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__saspcstlst_free: /* tmp177 = */ list_vt_free_01723_ats_ptr_type (arg0) ; return /* (tmp177) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__saspcstlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 9088(line=346, offs=20) -- 9214(line=351, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_add: tmp181 = atspre_ref_get_view_ptr (statmp175) ; tmp182 = ats_selsin_mac(tmp181, atslab_1) ; tmp184 = ats_ptrget_mac(ats_ptr_type, tmp182) ; tmp183 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp183, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp183, atslab_1, tmp184) ; ats_ptrget_mac(ats_ptr_type, tmp182) = tmp183 ; return /* (tmp180) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 9276(line=354, offs=20) -- 9421(line=359, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_get: tmp186 = atspre_ref_get_view_ptr (statmp175) ; tmp187 = ats_selsin_mac(tmp186, atslab_1) ; tmp188 = ats_ptrget_mac(ats_ptr_type, tmp187) ; tmp189 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp187) = tmp189 ; tmp185 = tmp188 ; return (tmp185) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_saspcstlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 9648(line=373, offs=7) -- 9895(line=381, offs=6) */ ATSstaticdec() ats_ptr_type aux_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_aux_29: do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp194 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp195 = ats_ptrget_mac(ats_ptr_type, tmp194) ; ats_ptrget_mac(ats_ptr_type, tmp194) = arg1 ; tmp196 = arg0 ; arg0 = tmp195 ; arg1 = tmp196 ; goto __ats_lab_aux_29 ; // tail call break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp193 = arg1 ; break ; } while (0) ; return (tmp193) ; } /* end of [aux_29] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 9589(line=371, offs=4) -- 9946(line=384, offs=4) */ ATSstaticdec() ats_ptr_type datcstlst_reverse_28 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp197) ; __ats_lab_datcstlst_reverse_28: tmp197 = (ats_sum_ptr_type)0 ; tmp192 = aux_29 (arg0, tmp197) ; return (tmp192) ; } /* end of [datcstlst_reverse_28] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 10007(line=389, offs=16) -- 10120(line=393, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp199 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free ; // tail call break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: break ; } while (0) ; return /* (tmp198) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__datcstlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 10177(line=396, offs=19) -- 10303(line=401, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_add: tmp201 = atspre_ref_get_view_ptr (statmp190) ; tmp202 = ats_selsin_mac(tmp201, atslab_1) ; tmp204 = ats_ptrget_mac(ats_ptr_type, tmp202) ; tmp203 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp203, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp203, atslab_1, tmp204) ; ats_ptrget_mac(ats_ptr_type, tmp202) = tmp203 ; return /* (tmp200) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 10364(line=404, offs=20) -- 10522(line=410, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; // ATSlocal_void (tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp206 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp207 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp208 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_add (tmp206) ; arg0 = tmp207 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds ; // tail call break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_40_1: break ; } while (0) ; return /* (tmp205) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_adds] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 10583(line=413, offs=19) -- 10784(line=423, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_get: tmp210 = atspre_ref_get_view_ptr (statmp190) ; tmp211 = ats_selsin_mac(tmp210, atslab_1) ; tmp212 = ats_ptrget_mac(ats_ptr_type, tmp211) ; tmp213 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp211) = tmp213 ; tmp209 = datcstlst_reverse_28 (tmp212) ; return (tmp209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_datcstlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 11010(line=437, offs=7) -- 11257(line=445, offs=6) */ ATSstaticdec() ats_ptr_type aux_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_aux_35: do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp218 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp219 = ats_ptrget_mac(ats_ptr_type, tmp218) ; ats_ptrget_mac(ats_ptr_type, tmp218) = arg1 ; tmp220 = arg0 ; arg0 = tmp219 ; arg1 = tmp220 ; goto __ats_lab_aux_35 ; // tail call break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: tmp217 = arg1 ; break ; } while (0) ; return (tmp217) ; } /* end of [aux_35] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 10951(line=435, offs=4) -- 11308(line=448, offs=4) */ ATSstaticdec() ats_ptr_type exnconlst_reverse_34 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_exnconlst_reverse_34: tmp221 = (ats_sum_ptr_type)0 ; tmp216 = aux_35 (arg0, tmp221) ; return (tmp216) ; } /* end of [exnconlst_reverse_34] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 11386(line=453, offs=16) -- 11499(line=457, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp223 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free ; // tail call break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: break ; } while (0) ; return /* (tmp222) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__exnconlst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 11556(line=460, offs=19) -- 11682(line=465, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_add: tmp225 = atspre_ref_get_view_ptr (statmp214) ; tmp226 = ats_selsin_mac(tmp225, atslab_1) ; tmp228 = ats_ptrget_mac(ats_ptr_type, tmp226) ; tmp227 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp227, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp227, atslab_1, tmp228) ; ats_ptrget_mac(ats_ptr_type, tmp226) = tmp227 ; return /* (tmp224) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 11743(line=468, offs=20) -- 11901(line=474, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; // ATSlocal_void (tmp232) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp230 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp232 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_add (tmp230) ; arg0 = tmp231 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: break ; } while (0) ; return /* (tmp229) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_adds] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 11962(line=477, offs=19) -- 12179(line=487, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_get: tmp234 = atspre_ref_get_view_ptr (statmp214) ; tmp235 = ats_selsin_mac(tmp234, atslab_1) ; tmp236 = ats_ptrget_mac(ats_ptr_type, tmp235) ; tmp237 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp235) = tmp237 ; tmp233 = exnconlst_reverse_34 (tmp236) ; return (tmp233) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_exnconlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 12523(line=508, offs=19) -- 13086(line=527, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; // ATSlocal_void (tmp250) ; ATSlocal (ats_bool_type, tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; // ATSlocal_void (tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop: /* ats_int_type tmp242 ; */ tmp242 = 0 ; tmp243 = ats_ptrget_mac(ats_ptr_type, statmp238) ; tmp244 = atspre_ref_get_view_ptr (statmp239) ; tmp245 = ats_selsin_mac(tmp244, atslab_1) ; tmp247 = ats_ptrget_mac(ats_ptr_type, tmp245) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp247 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp248 = ats_caselptrlab_mac(anairiats_sum_1, tmp247, atslab_0) ; tmp249 = ats_caselptrlab_mac(anairiats_sum_1, tmp247, atslab_1) ; ATS_FREE(tmp247) ; ats_ptrget_mac(ats_ptr_type, statmp238) = tmp248 ; ats_ptrget_mac(ats_ptr_type, tmp245) = tmp249 ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp247 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp242 = 1 ; break ; } while (0) ; tmp251 = atspre_gt_int_int (tmp242, 0) ; if (tmp251) { /* tmp252 = */ prerr_interror_0 () ; /* tmp253 = */ atspre_prerr_string (ATSstrcst(": the_vartypset_pop")) ; /* tmp254 = */ atspre_prerr_newline () ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp241 = tmp243 ; return (tmp241) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 13147(line=530, offs=20) -- 13382(line=540, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push () { /* local vardec */ // ATSlocal_void (tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push: tmp256 = ats_ptrget_mac(ats_ptr_type, statmp238) ; tmp257 = atspre_ref_get_view_ptr (statmp239) ; tmp258 = ats_selsin_mac(tmp257, atslab_1) ; tmp260 = ats_ptrget_mac(ats_ptr_type, tmp258) ; tmp259 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp259, atslab_0, tmp256) ; ats_selptrset_mac(anairiats_sum_1, tmp259, atslab_1, tmp260) ; ats_ptrget_mac(ats_ptr_type, tmp258) = tmp259 ; ats_ptrget_mac(ats_ptr_type, statmp238) = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; return /* (tmp255) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2500(line=68, offs=25) -- 2576(line=69, offs=60) */ ATSstaticdec() ats_int_type avl_height_04089_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp276) ; ATSlocal (ats_int_type, tmp277) ; ATSlocal (ats_int_type, tmp278) ; __ats_lab_avl_height_04089_ats_ptr_type: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp276 = 0 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp277 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp276 = tmp277 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp276 = tmp278 ; break ; } while (0) ; return (tmp276) ; } /* end of [avl_height_04089_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 4346(line=128, offs=27) -- 5013(line=147, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_l_04093_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_int_type, tmp289) ; ATSlocal (ats_int_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_int_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_int_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_int_type, tmp297) ; ATSlocal (ats_int_type, tmp298) ; ATSlocal (ats_bool_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_int_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_int_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_int_type, tmp313) ; ATSlocal (ats_int_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_int_type, tmp316) ; __ats_lab_avl_rotate_l_04093_ats_ptr_type: do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp286 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp287 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_3) ; tmp289 = avl_height_04089_ats_ptr_type (tmp288) ; tmp290 = atspre_iadd (tmp289, 2) ; tmp292 = atspre_iadd (tmp289, 1) ; tmp291 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp291)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp291, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp291, atslab_1, tmp292) ; ats_selptrset_mac(anairiats_sum_7, tmp291, atslab_2, tmp288) ; ats_selptrset_mac(anairiats_sum_7, tmp291, atslab_3, arg2) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_0, tmp286) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_1, tmp290) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_2, tmp287) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_3, tmp291) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp295 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp296 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_3) ; tmp297 = avl_height_04089_ats_ptr_type (tmp295) ; tmp298 = avl_height_04089_ats_ptr_type (tmp296) ; tmp299 = atspre_ilt (tmp297, tmp298) ; if (tmp299) { do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp296)->tag != 1) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_2) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_3) ; tmp304 = atspre_iadd (tmp297, 1) ; tmp303 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp303)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp303, atslab_0, tmp293) ; ats_selptrset_mac(anairiats_sum_7, tmp303, atslab_1, tmp304) ; ats_selptrset_mac(anairiats_sum_7, tmp303, atslab_2, tmp295) ; ats_selptrset_mac(anairiats_sum_7, tmp303, atslab_3, tmp301) ; tmp306 = atspre_isub (tmp294, 1) ; tmp305 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp305)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp305, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp305, atslab_1, tmp306) ; ats_selptrset_mac(anairiats_sum_7, tmp305, atslab_2, tmp302) ; ats_selptrset_mac(anairiats_sum_7, tmp305, atslab_3, arg2) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_0, tmp300) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_1, tmp294) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_2, tmp303) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_3, tmp305) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (((ats_sum_ptr_type)tmp296)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: tmp307 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_0) ; tmp308 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_2) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_7, tmp296, atslab_3) ; tmp311 = atspre_iadd (tmp297, 1) ; tmp310 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp310)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp310, atslab_0, tmp293) ; ats_selptrset_mac(anairiats_sum_7, tmp310, atslab_1, tmp311) ; ats_selptrset_mac(anairiats_sum_7, tmp310, atslab_2, tmp295) ; ats_selptrset_mac(anairiats_sum_7, tmp310, atslab_3, tmp308) ; tmp313 = atspre_isub (tmp294, 1) ; tmp312 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp312)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp312, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp312, atslab_1, tmp313) ; ats_selptrset_mac(anairiats_sum_7, tmp312, atslab_2, tmp309) ; ats_selptrset_mac(anairiats_sum_7, tmp312, atslab_3, arg2) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_0, tmp307) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_1, tmp294) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_2, tmp310) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_3, tmp312) ; break ; } while (0) ; } else { tmp314 = atspre_iadd (tmp298, 2) ; tmp316 = atspre_iadd (tmp298, 1) ; tmp315 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp315)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp315, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp315, atslab_1, tmp316) ; ats_selptrset_mac(anairiats_sum_7, tmp315, atslab_2, tmp296) ; ats_selptrset_mac(anairiats_sum_7, tmp315, atslab_3, arg2) ; tmp285 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp285)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_0, tmp293) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_1, tmp314) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_2, tmp295) ; ats_selptrset_mac(anairiats_sum_7, tmp285, atslab_3, tmp315) ; } /* end of [if] */ break ; } while (0) ; return (tmp285) ; } /* end of [avl_rotate_l_04093_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 5194(line=152, offs=27) -- 5846(line=171, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_r_04094_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_int_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_int_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_bool_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_int_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_int_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_int_type, tmp347) ; ATSlocal (ats_int_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_int_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_int_type, tmp354) ; ATSlocal (ats_int_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_int_type, tmp357) ; __ats_lab_avl_rotate_r_04094_ats_ptr_type: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_61_0 ; } __ats_lab_58_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp328 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_1) ; tmp329 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_2) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_3) ; tmp331 = avl_height_04089_ats_ptr_type (tmp329) ; tmp332 = avl_height_04089_ats_ptr_type (tmp330) ; tmp333 = atspre_igt (tmp331, tmp332) ; if (tmp333) { do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp329)->tag != 1) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp334 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_0) ; tmp335 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_2) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_3) ; tmp338 = atspre_isub (tmp328, 1) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp337)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp337, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp337, atslab_1, tmp338) ; ats_selptrset_mac(anairiats_sum_7, tmp337, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp337, atslab_3, tmp335) ; tmp340 = atspre_iadd (tmp332, 1) ; tmp339 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp339)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp339, atslab_0, tmp327) ; ats_selptrset_mac(anairiats_sum_7, tmp339, atslab_1, tmp340) ; ats_selptrset_mac(anairiats_sum_7, tmp339, atslab_2, tmp336) ; ats_selptrset_mac(anairiats_sum_7, tmp339, atslab_3, tmp330) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp326)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_0, tmp334) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_1, tmp328) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_2, tmp337) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_3, tmp339) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: // if (((ats_sum_ptr_type)tmp329)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_60_1: tmp341 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_0) ; tmp342 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_2) ; tmp343 = ats_caselptrlab_mac(anairiats_sum_7, tmp329, atslab_3) ; tmp345 = atspre_isub (tmp328, 1) ; tmp344 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp344)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp344, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp344, atslab_1, tmp345) ; ats_selptrset_mac(anairiats_sum_7, tmp344, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp344, atslab_3, tmp342) ; tmp347 = atspre_iadd (tmp332, 1) ; tmp346 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp346)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp346, atslab_0, tmp327) ; ats_selptrset_mac(anairiats_sum_7, tmp346, atslab_1, tmp347) ; ats_selptrset_mac(anairiats_sum_7, tmp346, atslab_2, tmp343) ; ats_selptrset_mac(anairiats_sum_7, tmp346, atslab_3, tmp330) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp326)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_0, tmp341) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_1, tmp328) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_2, tmp344) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_3, tmp346) ; break ; } while (0) ; } else { tmp348 = atspre_iadd (tmp331, 2) ; tmp350 = atspre_iadd (tmp331, 1) ; tmp349 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp349)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp349, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp349, atslab_1, tmp350) ; ats_selptrset_mac(anairiats_sum_7, tmp349, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp349, atslab_3, tmp329) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp326)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_0, tmp327) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_1, tmp348) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_2, tmp349) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_3, tmp330) ; } /* end of [if] */ break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_2) ; tmp353 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_3) ; tmp354 = avl_height_04089_ats_ptr_type (tmp352) ; tmp355 = atspre_iadd (tmp354, 2) ; tmp357 = atspre_iadd (tmp354, 1) ; tmp356 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp356)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp356, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp356, atslab_1, tmp357) ; ats_selptrset_mac(anairiats_sum_7, tmp356, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp356, atslab_3, tmp352) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp326)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_0, tmp351) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_1, tmp355) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_2, tmp356) ; ats_selptrset_mac(anairiats_sum_7, tmp326, atslab_3, tmp353) ; break ; } while (0) ; return (tmp326) ; } /* end of [avl_rotate_r_04094_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6555(line=191, offs=3) -- 7255(line=213, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_br_04096_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_int_type, tmp272) ; ATSlocal (ats_bool_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_int_type, tmp275) ; ATSlocal (ats_int_type, tmp279) ; ATSlocal (ats_bool_type, tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_bool_type, tmp282) ; ATSlocal (ats_int_type, tmp283) ; ATSlocal (ats_int_type, tmp284) ; ATSlocal (ats_bool_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_int_type, tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_bool_type, tmp321) ; ATSlocal (ats_int_type, tmp322) ; ATSlocal (ats_bool_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; ATSlocal (ats_int_type, tmp325) ; ATSlocal (ats_int_type, tmp358) ; ATSlocal (ats_int_type, tmp359) ; ATSlocal (ats_bool_type, tmp360) ; __ats_lab_avl_insert_br_04096_ats_ptr_type: tmp272 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg5) (arg4, arg0) ; tmp273 = atspre_ilt (tmp272, 0) ; if (tmp273) { tmp274 = avl_insert_04095_ats_ptr_type (arg2, arg4, arg5) ; tmp275 = avl_height_04089_ats_ptr_type (tmp274) ; tmp279 = avl_height_04089_ats_ptr_type (arg3) ; tmp280 = atspre_ilte (tmp275, tmp279) ; if (tmp280) { tmp281 = atspre_iadd (tmp279, 1) ; tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, tmp281) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, tmp274) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, arg3) ; } else { tmp283 = atspre_iadd (tmp279, 1) ; tmp282 = atspre_ilte (tmp275, tmp283) ; if (tmp282) { tmp284 = atspre_iadd (tmp275, 1) ; tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, tmp284) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, tmp274) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, arg3) ; } else { tmp271 = avl_rotate_l_04093_ats_ptr_type (arg0, tmp274, arg3) ; } /* end of [if] */ } /* end of [if] */ } else { tmp317 = atspre_igt (tmp272, 0) ; if (tmp317) { tmp318 = avl_insert_04095_ats_ptr_type (arg3, arg4, arg5) ; tmp319 = avl_height_04089_ats_ptr_type (arg2) ; tmp320 = avl_height_04089_ats_ptr_type (tmp318) ; tmp321 = atspre_ilte (tmp320, tmp319) ; if (tmp321) { tmp322 = atspre_iadd (tmp319, 1) ; tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, tmp322) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, tmp318) ; } else { tmp324 = atspre_iadd (tmp319, 1) ; tmp323 = atspre_ilte (tmp320, tmp324) ; if (tmp323) { tmp325 = atspre_iadd (tmp320, 1) ; tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, tmp325) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, tmp318) ; } else { tmp271 = avl_rotate_r_04094_ats_ptr_type (arg0, arg2, tmp318) ; } /* end of [if] */ } /* end of [if] */ } else { tmp358 = avl_height_04089_ats_ptr_type (arg2) ; tmp359 = avl_height_04089_ats_ptr_type (arg3) ; tmp360 = atspre_igte (tmp358, tmp359) ; if (tmp360) { tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, arg3) ; } else { tmp271 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp271)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_7, tmp271, atslab_3, arg3) ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return (tmp271) ; } /* end of [avl_insert_br_04096_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6313(line=184, offs=25) -- 6501(line=188, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_04095_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_int_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; __ats_lab_avl_insert_04095_ats_ptr_type: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp265 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp266 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp264)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp264, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp264, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_7, tmp264, atslab_2, tmp265) ; ats_selptrset_mac(anairiats_sum_7, tmp264, atslab_3, tmp266) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_62_0 ; } __ats_lab_50_1: tmp267 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp269 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp270 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp264 = avl_insert_br_04096_ats_ptr_type (tmp267, tmp268, tmp269, tmp270, arg1, arg2) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: tmp361 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp362 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp363 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp364 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp264 = avl_insert_br_04096_ats_ptr_type (tmp361, tmp362, tmp363, tmp364, arg1, arg2) ; break ; } while (0) ; return (tmp264) ; } /* end of [avl_insert_04095_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18425(line=545, offs=25) -- 18463(line=545, offs=63) */ ATSstaticdec() ats_ptr_type set_insert_01741_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp263) ; __ats_lab_set_insert_01741_ats_ptr_type: tmp263 = avl_insert_04095_ats_ptr_type (arg0, arg1, arg2) ; return (tmp263) ; } /* end of [set_insert_01741_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 13443(line=543, offs=19) -- 13574(line=548, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp365) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add: tmp365 = ats_ptrget_mac(ats_ptr_type, statmp238) ; tmp262 = set_insert_01741_ats_ptr_type (tmp365, arg0, &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp) ; ats_ptrget_mac(ats_ptr_type, statmp238) = tmp262 ; return /* (tmp261) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 13826(line=557, offs=6) -- 13941(line=560, offs=6) */ ATSstaticdec() ats_void_type f_50 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_f_50: tmp370 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; tmp371 = ats_ptrget_mac(ats_ptr_type, arg1) ; tmp369 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp369, atslab_0, tmp370) ; ats_selptrset_mac(anairiats_sum_1, tmp369, atslab_1, tmp371) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp369 ; return /* (tmp368) */ ; } /* end of [f_50] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 13663(line=553, offs=25) -- 14066(line=564, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; // ATSlocal_void (tmp372) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make: /* ats_ptr_type tmp367 ; */ tmp367 = (ats_sum_ptr_type)0 ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg0, &f_50, (&tmp367)) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp367) ; return (tmp366) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_d2varlst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15899(line=469, offs=14) -- 15939(line=469, offs=54) */ ATSstaticdec() ats_int_type __ats_fun_55 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp383) ; __ats_lab___ats_fun_55: tmp383 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))env1) (env0, arg0) ; return (tmp383) ; } /* end of [__ats_fun_55] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } __ats_fun_55_closure_type ; ats_int_type __ats_fun_55_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_55 (((__ats_fun_55_closure_type*)cloptr)->closure_env_0, ((__ats_fun_55_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_55_closure_init (__ats_fun_55_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_55_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_55_closure_make (ats_ptr_type env0, ats_ptr_type env1) { __ats_fun_55_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_55_closure_type)) ; __ats_fun_55_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 9272(line=275, offs=25) -- 9961(line=296, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_r_04099_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_int_type, tmp401) ; ATSlocal (ats_int_type, tmp402) ; ATSlocal (ats_bool_type, tmp403) ; ATSlocal (ats_int_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_int_type, tmp409) ; ATSlocal (ats_int_type, tmp410) ; ATSlocal (ats_bool_type, tmp411) ; ATSlocal (ats_int_type, tmp412) ; ATSlocal (ats_int_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_int_type, tmp418) ; ATSlocal (ats_int_type, tmp419) ; ATSlocal (ats_bool_type, tmp420) ; ATSlocal (ats_int_type, tmp421) ; ATSlocal (ats_int_type, tmp422) ; ATSlocal (ats_int_type, tmp423) ; __ats_lab_avl_join_r_04099_ats_ptr_type: tmp401 = avl_height_04089_ats_ptr_type (arg1) ; tmp402 = avl_height_04089_ats_ptr_type (arg2) ; tmp404 = atspre_iadd (tmp401, 1) ; tmp403 = atspre_ilt (tmp404, tmp402) ; if (tmp403) { do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_2) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_3) ; tmp408 = avl_join_r_04099_ats_ptr_type (arg0, arg1, tmp406) ; tmp409 = avl_height_04089_ats_ptr_type (tmp408) ; tmp410 = avl_height_04089_ats_ptr_type (tmp407) ; tmp412 = atspre_iadd (tmp410, 1) ; tmp411 = atspre_ilte (tmp409, tmp412) ; if (tmp411) { tmp413 = atspre_iadd (tmp409, 1) ; tmp400 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp400)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_0, tmp405) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_1, tmp413) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_2, tmp408) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_3, tmp407) ; } else { tmp400 = avl_rotate_l_04093_ats_ptr_type (tmp405, tmp408, tmp407) ; } /* end of [if] */ break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_69_1: tmp414 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_0) ; tmp415 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_2) ; tmp416 = ats_caselptrlab_mac(anairiats_sum_7, arg2, atslab_3) ; tmp417 = avl_join_r_04099_ats_ptr_type (arg0, arg1, tmp415) ; tmp418 = avl_height_04089_ats_ptr_type (tmp417) ; tmp419 = avl_height_04089_ats_ptr_type (tmp416) ; tmp420 = atspre_ilte (tmp418, tmp419) ; if (tmp420) { tmp421 = atspre_iadd (tmp419, 1) ; tmp400 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp400)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_0, tmp414) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_1, tmp421) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_2, tmp417) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_3, tmp416) ; } else { tmp422 = atspre_iadd (tmp418, 1) ; tmp400 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp400)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_0, tmp414) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_1, tmp422) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_2, tmp417) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_3, tmp416) ; } /* end of [if] */ break ; } while (0) ; } else { tmp423 = atspre_iadd (tmp402, 1) ; tmp400 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp400)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_1, tmp423) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp400, atslab_3, arg2) ; } /* end of [if] */ return (tmp400) ; } /* end of [avl_join_r_04099_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 8402(line=249, offs=25) -- 9087(line=270, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_l_04098_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_int_type, tmp427) ; ATSlocal (ats_int_type, tmp428) ; ATSlocal (ats_bool_type, tmp429) ; ATSlocal (ats_int_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_int_type, tmp435) ; ATSlocal (ats_int_type, tmp436) ; ATSlocal (ats_bool_type, tmp437) ; ATSlocal (ats_int_type, tmp438) ; ATSlocal (ats_int_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_int_type, tmp444) ; ATSlocal (ats_int_type, tmp445) ; ATSlocal (ats_bool_type, tmp446) ; ATSlocal (ats_int_type, tmp447) ; ATSlocal (ats_int_type, tmp448) ; ATSlocal (ats_int_type, tmp449) ; __ats_lab_avl_join_l_04098_ats_ptr_type: tmp427 = avl_height_04089_ats_ptr_type (arg1) ; tmp428 = avl_height_04089_ats_ptr_type (arg2) ; tmp430 = atspre_iadd (tmp428, 1) ; tmp429 = atspre_igt (tmp427, tmp430) ; if (tmp429) { do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp431 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp432 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp433 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_3) ; tmp434 = avl_join_l_04098_ats_ptr_type (arg0, tmp433, arg2) ; tmp435 = avl_height_04089_ats_ptr_type (tmp432) ; tmp436 = avl_height_04089_ats_ptr_type (tmp434) ; tmp437 = atspre_ilte (tmp436, tmp435) ; if (tmp437) { tmp438 = atspre_iadd (tmp435, 1) ; tmp426 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp426)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_0, tmp431) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_1, tmp438) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_2, tmp432) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_3, tmp434) ; } else { tmp439 = atspre_iadd (tmp436, 1) ; tmp426 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp426)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_0, tmp431) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_1, tmp439) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_2, tmp432) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_3, tmp434) ; } /* end of [if] */ break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp440 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp441 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp442 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_3) ; tmp443 = avl_join_l_04098_ats_ptr_type (arg0, tmp442, arg2) ; tmp444 = avl_height_04089_ats_ptr_type (tmp441) ; tmp445 = avl_height_04089_ats_ptr_type (tmp443) ; tmp447 = atspre_iadd (tmp444, 1) ; tmp446 = atspre_ilte (tmp445, tmp447) ; if (tmp446) { tmp448 = atspre_iadd (tmp445, 1) ; tmp426 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp426)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_0, tmp440) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_1, tmp448) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_2, tmp441) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_3, tmp443) ; } else { tmp426 = avl_rotate_r_04094_ats_ptr_type (tmp440, tmp441, tmp443) ; } /* end of [if] */ break ; } while (0) ; } else { tmp449 = atspre_iadd (tmp427, 1) ; tmp426 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp426)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_1, tmp449) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp426, atslab_3, arg2) ; } /* end of [if] */ return (tmp426) ; } /* end of [avl_join_l_04098_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11552(line=345, offs=3) -- 12417(line=370, offs=4) */ ATSstaticdec() ats_int_type avl_split_br_04102_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp391) ; ATSlocal (ats_int_type, tmp392) ; ATSlocal (ats_int_type, tmp393) ; ATSlocal (ats_int_type, tmp394) ; ATSlocal (ats_int_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_int_type, tmp397) ; ATSlocal (ats_bool_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_int_type, tmp451) ; ATSlocal (ats_int_type, tmp452) ; ATSlocal (ats_int_type, tmp453) ; ATSlocal (ats_int_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_bool_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; __ats_lab_avl_split_br_04102_ats_ptr_type: tmp392 = ((ats_int_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg4))) (arg4, arg0) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (tmp392 != -1) { goto __ats_lab_72_0 ; } __ats_lab_67_1: tmp393 = avl_split_04101_ats_ptr_type (arg2, arg4, arg5, arg6) ; tmp394 = ats_selsin_mac(tmp393, atslab_2) ; tmp396 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp395 = avl_height_04089_ats_ptr_type (tmp396) ; tmp397 = avl_height_04089_ats_ptr_type (arg3) ; tmp398 = atspre_ilte (tmp395, tmp397) ; if (tmp398) { tmp424 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp399 = avl_join_r_04099_ats_ptr_type (arg0, tmp424, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp399 ; tmp391 = tmp394 ; } else { tmp450 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp425 = avl_join_l_04098_ats_ptr_type (arg0, tmp450, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp425 ; tmp391 = tmp394 ; } /* end of [if] */ break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (tmp392 != 1) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp451 = avl_split_04101_ats_ptr_type (arg3, arg4, arg5, arg6) ; tmp452 = ats_selsin_mac(tmp451, atslab_2) ; tmp453 = avl_height_04089_ats_ptr_type (arg2) ; tmp455 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp454 = avl_height_04089_ats_ptr_type (tmp455) ; tmp456 = atspre_ilte (tmp453, tmp454) ; if (tmp456) { tmp458 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp457 = avl_join_r_04099_ats_ptr_type (arg0, arg2, tmp458) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp457 ; tmp391 = tmp452 ; } else { tmp460 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp459 = avl_join_l_04098_ats_ptr_type (arg0, arg2, tmp460) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp459 ; tmp391 = tmp452 ; } /* end of [if] */ break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (tmp392 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: ats_ptrget_mac(ats_ptr_type, arg5) = arg2 ; ats_ptrget_mac(ats_ptr_type, arg6) = arg3 ; tmp391 = 1 ; break ; } while (0) ; return (tmp391) ; } /* end of [avl_split_br_04102_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11224(line=336, offs=24) -- 11486(line=341, offs=8) */ ATSstaticdec() ats_int_type avl_split_04101_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_int_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_int_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; __ats_lab_avl_split_04101_ats_ptr_type: do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_74_0 ; } __ats_lab_66_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp390 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp386 = avl_split_br_04102_ats_ptr_type (tmp387, tmp388, tmp389, tmp390, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp463 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp464 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp386 = avl_split_br_04102_ats_ptr_type (tmp461, tmp462, tmp463, tmp464, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp465 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp465 ; tmp466 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp466 ; tmp386 = 0 ; break ; } while (0) ; return (tmp386) ; } /* end of [avl_split_04101_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15826(line=467, offs=27) -- 16289(line=478, offs=4) */ ATSstaticdec() ats_ptr_type avl_union_br_04108_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_int_type, tmp385) ; ATSlocal (ats_int_type, tmp467) ; // ATSlocal_void (tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_int_type, tmp471) ; ATSlocal (ats_int_type, tmp472) ; ATSlocal (ats_bool_type, tmp473) ; __ats_lab_avl_union_br_04108_ats_ptr_type: /* ats_ptr_type tmp381 ; */ /* ats_ptr_type tmp382 ; */ tmp384 = __ats_fun_55_closure_make (arg0, arg5) ; tmp385 = avl_split_04101_ats_ptr_type (arg4, tmp384, (&tmp381), (&tmp382)) ; tmp467 = ats_selsin_mac(tmp385, atslab_2) ; /* tmp468 = */ atspre_cloptr_free (tmp384) ; tmp469 = avl_union_04107_ats_ptr_type (arg2, tmp381, arg5) ; tmp470 = avl_union_04107_ats_ptr_type (arg3, tmp382, arg5) ; tmp471 = avl_height_04089_ats_ptr_type (tmp469) ; tmp472 = avl_height_04089_ats_ptr_type (tmp470) ; tmp473 = atspre_ilte (tmp471, tmp472) ; if (tmp473) { tmp380 = avl_join_r_04099_ats_ptr_type (arg0, tmp469, tmp470) ; } else { tmp380 = avl_join_l_04098_ats_ptr_type (arg0, tmp469, tmp470) ; } /* end of [if] */ return (tmp380) ; } /* end of [avl_union_br_04108_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15583(line=461, offs=24) -- 15798(line=465, offs=71) */ ATSstaticdec() ats_ptr_type avl_union_04107_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_int_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_avl_union_04107_ats_ptr_type: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_64_0 ; } __ats_lab_63_1: __ats_lab_63_2: tmp375 = arg1 ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_65_0 ; } __ats_lab_64_2: tmp375 = arg0 ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_76_0 ; } __ats_lab_65_1: __ats_lab_65_2: tmp376 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp378 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp379 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp375 = avl_union_br_04108_ats_ptr_type (tmp376, tmp377, tmp378, tmp379, arg1, arg2) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_76_1: __ats_lab_76_2: tmp474 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp475 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp476 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp477 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp375 = avl_union_br_04108_ats_ptr_type (tmp474, tmp475, tmp476, tmp477, arg1, arg2) ; break ; } while (0) ; return (tmp375) ; } /* end of [avl_union_04107_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18617(line=548, offs=24) -- 18660(line=548, offs=67) */ ATSstaticdec() ats_ptr_type set_union_01744_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp374) ; __ats_lab_set_union_01744_ats_ptr_type: tmp374 = avl_union_04107_ats_ptr_type (arg0, arg1, arg2) ; return (tmp374) ; } /* end of [set_union_01744_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 14134(line=569, offs=17) -- 14205(line=570, offs=55) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp373) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_union: tmp373 = set_union_01744_ats_ptr_type (arg0, arg1, &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp) ; return (tmp373) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_union] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 3823(line=113, offs=26) -- 4145(line=121, offs=4) */ ATSstaticdec() ats_void_type avl_foreach_04092_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; // ATSlocal_void (tmp489) ; // ATSlocal_void (tmp490) ; __ats_lab_avl_foreach_04092_ats_ptr_type: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp481 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp482 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp483 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; /* tmp484 = */ avl_foreach_04092_ats_ptr_type (tmp482, arg1, arg2) ; /* tmp485 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp481, arg2) ; arg0 = tmp483 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_04092_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp486 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp487 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp488 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; /* tmp489 = */ avl_foreach_04092_ats_ptr_type (tmp487, arg1, arg2) ; /* tmp490 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp486, arg2) ; arg0 = tmp488 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_04092_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: break ; } while (0) ; return /* (tmp480) */ ; } /* end of [avl_foreach_04092_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18713(line=552, offs=31) -- 18767(line=553, offs=35) */ ATSstaticdec() ats_void_type set_foreach_main_01745_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp479) ; __ats_lab_set_foreach_main_01745_ats_ptr_type: /* tmp479 = */ avl_foreach_04092_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp479) */ ; } /* end of [set_foreach_main_01745_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 14270(line=575, offs=3) -- 14333(line=575, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp478) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main: /* tmp478 = */ set_foreach_main_01745_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp478) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18872(line=557, offs=6) -- 18927(line=557, offs=61) */ ATSstaticdec() ats_void_type app_65 (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp493) ; __ats_lab_app_65: /* tmp493 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg1))) (arg1, arg0) ; return /* (tmp493) */ ; } /* end of [app_65] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18809(line=555, offs=41) -- 19055(line=563, offs=4) */ ATSstaticdec() ats_void_type set_foreach_cloptr_01746_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp492) ; __ats_lab_set_foreach_cloptr_01746_ats_ptr_type: /* tmp492 = */ avl_foreach_04092_ats_ptr_type (arg0, &app_65, arg1) ; return /* (tmp492) */ ; } /* end of [set_foreach_cloptr_01746_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 14407(line=580, offs=3) -- 14452(line=580, offs=48) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_cloptr (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp491) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_cloptr: /* tmp491 = */ set_foreach_cloptr_01746_ats_ptr_type (arg0, arg1) ; return /* (tmp491) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_cloptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 14556(line=588, offs=6) -- 14727(line=594, offs=8) */ ATSstaticdec() ats_void_type f_67 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp496) ; ATSlocal (ats_int_type, tmp497) ; ATSlocal (ats_int_type, tmp498) ; // ATSlocal_void (tmp499) ; ATSlocal (ats_bool_type, tmp500) ; __ats_lab_f_67: tmp497 = ats_ptrget_mac(ats_int_type, arg1) ; tmp498 = atspre_add_int_int (tmp497, 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp498 ; tmp500 = atspre_gt_int_int (tmp497, 0) ; if (tmp500) { /* tmp499 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__print_vartyp (arg0) ; return /* (tmp496) */ ; } /* end of [f_67] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 14521(line=586, offs=17) -- 14872(line=601, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_vartypset (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp494) ; ATSlocal (ats_int_type, tmp495) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_vartypset: /* ats_int_type tmp495 ; */ tmp495 = 0 ; /* tmp494 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg0, &f_67, (&tmp495)) ; return /* (tmp494) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_vartypset] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 15565(line=634, offs=19) -- 16129(line=653, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_int_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; // ATSlocal_void (tmp513) ; ATSlocal (ats_bool_type, tmp514) ; // ATSlocal_void (tmp515) ; // ATSlocal_void (tmp516) ; // ATSlocal_void (tmp517) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop: /* ats_int_type tmp505 ; */ tmp505 = 0 ; tmp506 = ats_ptrget_mac(ats_ptr_type, statmp501) ; tmp507 = atspre_ref_get_view_ptr (statmp502) ; tmp508 = ats_selsin_mac(tmp507, atslab_1) ; tmp510 = ats_ptrget_mac(ats_ptr_type, tmp508) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (tmp510 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp511 = ats_caselptrlab_mac(anairiats_sum_1, tmp510, atslab_0) ; tmp512 = ats_caselptrlab_mac(anairiats_sum_1, tmp510, atslab_1) ; ATS_FREE(tmp510) ; ats_ptrget_mac(ats_ptr_type, statmp501) = tmp511 ; ats_ptrget_mac(ats_ptr_type, tmp508) = tmp512 ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: // if (tmp510 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_81_1: tmp505 = 1 ; break ; } while (0) ; tmp514 = atspre_gt_int_int (tmp505, 0) ; if (tmp514) { /* tmp515 = */ prerr_interror_0 () ; /* tmp516 = */ atspre_prerr_string (ATSstrcst(": the_funlabset_pop")) ; /* tmp517 = */ atspre_prerr_newline () ; /* tmp513 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp504 = tmp506 ; return (tmp504) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 16190(line=656, offs=20) -- 16425(line=666, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push () { /* local vardec */ // ATSlocal_void (tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push: tmp519 = ats_ptrget_mac(ats_ptr_type, statmp501) ; tmp520 = atspre_ref_get_view_ptr (statmp502) ; tmp521 = ats_selsin_mac(tmp520, atslab_1) ; tmp523 = ats_ptrget_mac(ats_ptr_type, tmp521) ; tmp522 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp522, atslab_0, tmp519) ; ats_selptrset_mac(anairiats_sum_1, tmp522, atslab_1, tmp523) ; ats_ptrget_mac(ats_ptr_type, tmp521) = tmp522 ; ats_ptrget_mac(ats_ptr_type, statmp501) = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; return /* (tmp518) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 16486(line=669, offs=19) -- 16643(line=675, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add: tmp526 = ats_ptrget_mac(ats_ptr_type, statmp501) ; tmp525 = set_insert_01741_ats_ptr_type (tmp526, arg0, &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab) ; ats_ptrget_mac(ats_ptr_type, statmp501) = tmp525 ; return /* (tmp524) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2736(line=77, offs=25) -- 3115(line=90, offs=4) */ ATSstaticdec() ats_bool_type avl_member_04090_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_int_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_int_type, tmp537) ; __ats_lab_avl_member_04090_ats_ptr_type: do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_86_0 ; } __ats_lab_82_1: tmp530 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp531 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp532 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp533 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp530) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (tmp533 != -1) { goto __ats_lab_84_0 ; } __ats_lab_83_1: arg0 = tmp531 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_04090_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (tmp533 != 1) { goto __ats_lab_85_0 ; } __ats_lab_84_1: arg0 = tmp532 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_04090_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: // if (tmp533 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_85_1: tmp529 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_90_0 ; } __ats_lab_86_1: tmp534 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp535 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; tmp536 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_3) ; tmp537 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp534) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (tmp537 != -1) { goto __ats_lab_88_0 ; } __ats_lab_87_1: arg0 = tmp535 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_04090_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (tmp537 != 1) { goto __ats_lab_89_0 ; } __ats_lab_88_1: arg0 = tmp536 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_04090_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (tmp537 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp529 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp529 = ats_false_bool ; break ; } while (0) ; return (tmp529) ; } /* end of [avl_member_04090_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18362(line=544, offs=25) -- 18400(line=544, offs=63) */ ATSstaticdec() ats_bool_type set_member_01740_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp528) ; __ats_lab_set_member_01740_ats_ptr_type: tmp528 = avl_member_04090_ats_ptr_type (arg0, arg1, arg2) ; return (tmp528) ; } /* end of [set_member_01740_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 16703(line=678, offs=19) -- 16791(line=680, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_mem (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp527) ; ATSlocal (ats_ptr_type, tmp538) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_mem: tmp538 = ats_ptrget_mac(ats_ptr_type, statmp501) ; tmp527 = set_member_01740_ats_ptr_type (tmp538, arg0, &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab) ; return (tmp527) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_mem] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 16858(line=684, offs=3) -- 16919(line=684, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp539) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main: /* tmp539 = */ set_foreach_main_01745_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp539) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 16991(line=688, offs=26) -- 17034(line=688, offs=69) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp540) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr: /* tmp540 = */ set_foreach_cloptr_01746_ats_ptr_type (arg0, arg1) ; return /* (tmp540) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 17119(line=695, offs=6) -- 17271(line=698, offs=8) */ ATSstaticdec() ats_void_type f_77 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp543) ; ATSlocal (ats_int_type, tmp544) ; ATSlocal (ats_int_type, tmp545) ; // ATSlocal_void (tmp546) ; ATSlocal (ats_bool_type, tmp547) ; __ats_lab_f_77: tmp544 = ats_ptrget_mac(ats_int_type, arg1) ; tmp545 = atspre_add_int_int (tmp544, 1) ; ats_ptrget_mac(ats_int_type, arg1) = tmp545 ; tmp547 = atspre_gt_int_int (tmp544, 0) ; if (tmp547) { /* tmp546 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp543 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__print_funlab (arg0) ; return /* (tmp543) */ ; } /* end of [f_77] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 17085(line=693, offs=17) -- 17396(line=704, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_funlabset (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp541) ; ATSlocal (ats_int_type, tmp542) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_funlabset: /* ats_int_type tmp542 ; */ tmp542 = 0 ; /* tmp541 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main (arg0, &f_77, (&tmp542)) ; return /* (tmp541) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__print_funlabset] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 18042(line=738, offs=3) -- 18105(line=738, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynconset_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp549) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynconset_foreach_main: /* tmp549 = */ set_foreach_main_01745_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp549) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynconset_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 18170(line=742, offs=19) -- 18294(line=746, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add: tmp552 = ats_ptrget_mac(ats_ptr_type, statmp548) ; tmp551 = set_insert_01741_ats_ptr_type (tmp552, arg0, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con) ; ats_ptrget_mac(ats_ptr_type, statmp548) = tmp551 ; return /* (tmp550) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 18354(line=748, offs=29) -- 18373(line=748, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp553) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_get: tmp553 = ats_ptrget_mac(ats_ptr_type, statmp548) ; return (tmp553) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynconset_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 18650(line=763, offs=4) -- 19064(line=775, offs=4) */ ATSstaticdec() ats_void_type dyncstset_add_81 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_bool_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; // ATSlocal_void (tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; __ats_lab_dyncstset_add_81: tmp558 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_loc (arg1) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof (arg1) ; if (tmp560) { tmp559 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_proof ; } else { tmp561 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (arg1) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp558, 1, tmp561) ; } /* end of [if] */ tmp562 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_normalize (tmp559) ; tmp564 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp564, atslab_0, tmp562) ; /* tmp563 = */ atsopt_d2cst_set_hityp (arg1, tmp564) ; tmp565 = ats_ptrget_mac(ats_ptr_type, arg0) ; tmp566 = set_insert_01741_ats_ptr_type (tmp565, arg1, &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp566 ; return /* (tmp557) */ ; } /* end of [dyncstset_add_81] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 19099(line=777, offs=4) -- 19488(line=787, offs=6) */ ATSstaticdec() ats_void_type dyncstset_add_if_82 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp567) ; ATSlocal (ats_bool_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_bool_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; __ats_lab_dyncstset_add_if_82: tmp568 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp (arg1) ; if (tmp568) { /* empty */ } else { tmp569 = ats_ptrget_mac(ats_ptr_type, arg0) ; tmp571 = ats_ptrget_mac(ats_ptr_type, arg0) ; tmp570 = set_member_01740_ats_ptr_type (tmp571, arg1, &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) ; if (tmp570) { /* empty */ } else { /* tmp567 = */ dyncstset_add_81 (arg0, arg1) ; } /* end of [if] */ } /* end of [if] */ return /* (tmp567) */ ; } /* end of [dyncstset_add_if_82] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 19590(line=794, offs=3) -- 19653(line=794, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp572) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main: /* tmp572 = */ set_foreach_main_01745_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp572) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dyncstset_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 19718(line=797, offs=29) -- 19737(line=797, offs=48) */ ATSglobaldec() ats_ptr_type atsopt_the_dyncstset_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp573) ; __ats_lab_atsopt_the_dyncstset_get: tmp573 = ats_ptrget_mac(ats_ptr_type, statmp554) ; return (tmp573) ; } /* end of [atsopt_the_dyncstset_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 19770(line=800, offs=22) -- 20073(line=808, offs=6) */ ATSglobaldec() ats_void_type atsopt_the_dyncstset_add_if (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp574) ; ATSlocal (ats_bool_type, tmp575) ; ATSlocal (ats_bool_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; __ats_lab_atsopt_the_dyncstset_add_if: tmp575 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_temp (arg0) ; if (tmp575) { /* empty */ } else { tmp577 = ats_ptrget_mac(ats_ptr_type, statmp554) ; tmp576 = set_member_01740_ats_ptr_type (tmp577, arg0, &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) ; if (tmp576) { /* empty */ } else { /* tmp574 = */ dyncstset_add_81 (statmp554, arg0) ; } /* end of [if] */ } /* end of [if] */ return /* (tmp574) */ ; } /* end of [atsopt_the_dyncstset_add_if] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 20155(line=812, offs=23) -- 20411(line=823, offs=4) */ ATSglobaldec() ats_void_type atsopt_the_dyncstsetlst_push () { /* local vardec */ // ATSlocal_void (tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; __ats_lab_atsopt_the_dyncstsetlst_push: tmp579 = ats_ptrget_mac(ats_ptr_type, statmp554) ; tmp580 = atspre_ref_get_view_ptr (statmp555) ; tmp581 = ats_selsin_mac(tmp580, atslab_1) ; tmp583 = ats_ptrget_mac(ats_ptr_type, tmp581) ; tmp582 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp582, atslab_0, tmp579) ; ats_selptrset_mac(anairiats_sum_1, tmp582, atslab_1, tmp583) ; ats_ptrget_mac(ats_ptr_type, tmp581) = tmp582 ; ats_ptrget_mac(ats_ptr_type, statmp554) = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; return /* (tmp578) */ ; } /* end of [atsopt_the_dyncstsetlst_push] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 20478(line=826, offs=22) -- 21069(line=846, offs=4) */ ATSglobaldec() ats_ptr_type atsopt_the_dyncstsetlst_pop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_int_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; // ATSlocal_void (tmp593) ; ATSlocal (ats_bool_type, tmp594) ; // ATSlocal_void (tmp595) ; // ATSlocal_void (tmp596) ; // ATSlocal_void (tmp597) ; __ats_lab_atsopt_the_dyncstsetlst_pop: /* ats_int_type tmp585 ; */ tmp585 = 0 ; tmp586 = ats_ptrget_mac(ats_ptr_type, statmp554) ; tmp587 = atspre_ref_get_view_ptr (statmp555) ; tmp588 = ats_selsin_mac(tmp587, atslab_1) ; tmp590 = ats_ptrget_mac(ats_ptr_type, tmp588) ; do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (tmp590 == (ats_sum_ptr_type)0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_1, tmp590, atslab_0) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_1, tmp590, atslab_1) ; ATS_FREE(tmp590) ; ats_ptrget_mac(ats_ptr_type, statmp554) = tmp591 ; ats_ptrget_mac(ats_ptr_type, tmp588) = tmp592 ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: // if (tmp590 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_92_1: tmp585 = 1 ; break ; } while (0) ; tmp594 = atspre_gt_int_int (tmp585, 0) ; if (tmp594) { /* tmp595 = */ prerr_interror_0 () ; /* tmp596 = */ atspre_prerr_string (ATSstrcst(": the_dyncstsetlst_pop")) ; /* tmp597 = */ atspre_prerr_newline () ; /* tmp593 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp584 = tmp586 ; return (tmp584) ; } /* end of [atsopt_the_dyncstsetlst_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 21267(line=859, offs=19) -- 21406(line=864, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_add: tmp601 = atspre_ref_get_view_ptr (statmp598) ; tmp602 = ats_selsin_mac(tmp601, atslab_1) ; tmp604 = ats_ptrget_mac(ats_ptr_type, tmp602) ; tmp603 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp603, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp603, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp603, atslab_2, tmp604) ; ats_ptrget_mac(ats_ptr_type, tmp602) = tmp603 ; return /* (tmp600) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 21466(line=867, offs=19) -- 21611(line=873, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_get: tmp606 = atspre_ref_get_view_ptr (statmp598) ; tmp607 = ats_selsin_mac(tmp606, atslab_1) ; tmp608 = ats_ptrget_mac(ats_ptr_type, tmp607) ; tmp609 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp607) = tmp609 ; tmp605 = tmp608 ; return (tmp605) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extypelst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 21819(line=885, offs=7) -- 22083(line=893, offs=6) */ ATSstaticdec() ats_ptr_type aux_91 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; __ats_lab_aux_91: do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp614 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp615 = ats_ptrget_mac(ats_ptr_type, tmp614) ; ats_ptrget_mac(ats_ptr_type, tmp614) = arg1 ; tmp616 = arg0 ; arg0 = tmp615 ; arg1 = tmp616 ; goto __ats_lab_aux_91 ; // tail call break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: tmp613 = arg1 ; break ; } while (0) ; return (tmp613) ; } /* end of [aux_91] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 21760(line=883, offs=4) -- 22134(line=896, offs=4) */ ATSstaticdec() ats_ptr_type extvalist_reverse_90 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp617) ; __ats_lab_extvalist_reverse_90: tmp617 = (ats_sum_ptr_type)0 ; tmp612 = aux_91 (arg0, tmp617) ; return (tmp612) ; } /* end of [extvalist_reverse_90] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 22215(line=901, offs=19) -- 22354(line=906, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_add: tmp619 = atspre_ref_get_view_ptr (statmp610) ; tmp620 = ats_selsin_mac(tmp619, atslab_1) ; tmp622 = ats_ptrget_mac(ats_ptr_type, tmp620) ; tmp621 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp621, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp621, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp621, atslab_2, tmp622) ; ats_ptrget_mac(ats_ptr_type, tmp620) = tmp621 ; return /* (tmp618) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 22414(line=909, offs=19) -- 22627(line=919, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_get: tmp624 = atspre_ref_get_view_ptr (statmp610) ; tmp625 = ats_selsin_mac(tmp624, atslab_1) ; tmp626 = ats_ptrget_mac(ats_ptr_type, tmp625) ; tmp627 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp625) = tmp627 ; tmp623 = extvalist_reverse_90 (tmp626) ; return (tmp623) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extvalist_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 22684(line=922, offs=16) -- 22812(line=925, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp629 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp629 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free ; // tail call break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: break ; } while (0) ; return /* (tmp628) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extvalist_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 23023(line=937, offs=7) -- 23323(line=947, offs=6) */ ATSstaticdec() ats_ptr_type aux_96 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; __ats_lab_aux_96: do { /* branch: __ats_lab_97 */ __ats_lab_97_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp634 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_3) ; tmp635 = ats_ptrget_mac(ats_ptr_type, tmp634) ; ats_ptrget_mac(ats_ptr_type, tmp634) = arg1 ; tmp636 = arg0 ; arg0 = tmp635 ; arg1 = tmp636 ; goto __ats_lab_aux_96 ; // tail call break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: tmp633 = arg1 ; break ; } while (0) ; return (tmp633) ; } /* end of [aux_96] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 22961(line=935, offs=4) -- 23375(line=950, offs=4) */ ATSstaticdec() ats_ptr_type extcodelst_reverse_95 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp637) ; __ats_lab_extcodelst_reverse_95: tmp637 = (ats_sum_ptr_type)0 ; tmp632 = aux_96 (arg0, tmp637) ; return (tmp632) ; } /* end of [extcodelst_reverse_95] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 23458(line=955, offs=20) -- 23609(line=960, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_add (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_add: tmp639 = atspre_ref_get_view_ptr (statmp630) ; tmp640 = ats_selsin_mac(tmp639, atslab_1) ; tmp642 = ats_ptrget_mac(ats_ptr_type, tmp640) ; tmp641 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp641, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp641, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp641, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp641, atslab_3, tmp642) ; ats_ptrget_mac(ats_ptr_type, tmp640) = tmp641 ; return /* (tmp638) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 23671(line=963, offs=20) -- 23887(line=973, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_get: tmp644 = atspre_ref_get_view_ptr (statmp630) ; tmp645 = ats_selsin_mac(tmp644, atslab_1) ; tmp646 = ats_ptrget_mac(ats_ptr_type, tmp645) ; tmp647 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp645) = tmp647 ; tmp643 = extcodelst_reverse_95 (tmp646) ; return (tmp643) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_extcodelst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 23946(line=976, offs=17) -- 24072(line=979, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free: do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp649 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_3) ; ATS_FREE(arg0) ; arg0 = tmp649 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: break ; } while (0) ; return /* (tmp648) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__extcodelst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 24302(line=993, offs=7) -- 24595(line=1001, offs=6) */ ATSstaticdec() ats_ptr_type aux_101 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; __ats_lab_aux_101: do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp654 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp655 = ats_ptrget_mac(ats_ptr_type, tmp654) ; ats_ptrget_mac(ats_ptr_type, tmp654) = arg1 ; tmp656 = arg0 ; arg0 = tmp655 ; arg1 = tmp656 ; goto __ats_lab_aux_101 ; // tail call break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_102_1: tmp653 = arg1 ; break ; } while (0) ; return (tmp653) ; } /* end of [aux_101] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 24240(line=991, offs=4) -- 24647(line=1004, offs=4) */ ATSstaticdec() ats_ptr_type stafilelst_reverse_100 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp657) ; __ats_lab_stafilelst_reverse_100: tmp657 = (ats_sum_ptr_type)0 ; tmp652 = aux_101 (arg0, tmp657) ; return (tmp652) ; } /* end of [stafilelst_reverse_100] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 24730(line=1009, offs=20) -- 24879(line=1014, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_add (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_add: tmp659 = atspre_ref_get_view_ptr (statmp650) ; tmp660 = ats_selsin_mac(tmp659, atslab_1) ; tmp662 = ats_ptrget_mac(ats_ptr_type, tmp660) ; tmp661 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp661, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_9, tmp661, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp661, atslab_2, tmp662) ; ats_ptrget_mac(ats_ptr_type, tmp660) = tmp661 ; return /* (tmp658) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 24941(line=1017, offs=20) -- 25135(line=1024, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_get: tmp664 = atspre_ref_get_view_ptr (statmp650) ; tmp665 = ats_selsin_mac(tmp664, atslab_1) ; tmp666 = ats_ptrget_mac(ats_ptr_type, tmp665) ; tmp667 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp665) = tmp667 ; tmp663 = stafilelst_reverse_100 (tmp666) ; return (tmp663) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_stafilelst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 25194(line=1027, offs=17) -- 25324(line=1031, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free: do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp669 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp669 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free ; // tail call break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_104_1: break ; } while (0) ; return /* (tmp668) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__stafilelst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 25523(line=1045, offs=20) -- 25652(line=1050, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_add: tmp673 = atspre_ref_get_view_ptr (statmp670) ; tmp674 = ats_selsin_mac(tmp673, atslab_1) ; tmp676 = ats_ptrget_mac(ats_ptr_type, tmp674) ; tmp675 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp675, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp675, atslab_1, tmp676) ; ats_ptrget_mac(ats_ptr_type, tmp674) = tmp675 ; return /* (tmp672) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 25714(line=1053, offs=20) -- 25861(line=1059, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_get: tmp678 = atspre_ref_get_view_ptr (statmp670) ; tmp679 = ats_selsin_mac(tmp678, atslab_1) ; tmp680 = ats_ptrget_mac(ats_ptr_type, tmp679) ; tmp681 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp679) = tmp681 ; tmp677 = tmp680 ; return (tmp677) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynfilelst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 25920(line=1062, offs=17) -- 26038(line=1066, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free: do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp683 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; arg0 = tmp683 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free ; // tail call break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_106_1: break ; } while (0) ; return /* (tmp682) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__dynfilelst_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 26255(line=1080, offs=12) -- 26677(line=1094, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop () { /* local vardec */ // ATSlocal_void (tmp686) ; ATSlocal (ats_int_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_bool_type, tmp693) ; // ATSlocal_void (tmp694) ; // ATSlocal_void (tmp695) ; // ATSlocal_void (tmp696) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop: /* ats_int_type tmp687 ; */ tmp687 = 0 ; tmp688 = atspre_ref_get_view_ptr (statmp684) ; tmp689 = ats_selsin_mac(tmp688, atslab_1) ; tmp691 = ats_ptrget_mac(ats_ptr_type, tmp689) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp691 == (ats_sum_ptr_type)0) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp692 = ats_caselptrlab_mac(anairiats_sum_1, tmp691, atslab_1) ; ATS_FREE(tmp691) ; ats_ptrget_mac(ats_ptr_type, tmp689) = tmp692 ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: // if (tmp691 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_108_1: tmp687 = 1 ; break ; } while (0) ; tmp693 = atspre_gt_int_int (tmp687, 0) ; if (tmp693) { /* tmp694 = */ prerr_interror_0 () ; /* tmp695 = */ atspre_prerr_string (ATSstrcst(": funlab_pop")) ; /* tmp696 = */ atspre_prerr_newline () ; /* tmp686 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp686) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 26724(line=1097, offs=13) -- 26854(line=1102, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push: tmp698 = atspre_ref_get_view_ptr (statmp684) ; tmp699 = ats_selsin_mac(tmp698, atslab_1) ; tmp701 = ats_ptrget_mac(ats_ptr_type, tmp699) ; tmp700 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp700, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp700, atslab_1, tmp701) ; ats_ptrget_mac(ats_ptr_type, tmp699) = tmp700 ; return /* (tmp697) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_push] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 26915(line=1106, offs=6) -- 27037(line=1109, offs=6) */ ATSstaticdec() ats_ptr_type err_111 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp703) ; // ATSlocal_void (tmp704) ; // ATSlocal_void (tmp705) ; // ATSlocal_void (tmp706) ; __ats_lab_err_111: /* tmp704 = */ prerr_interror_0 () ; /* tmp705 = */ atspre_prerr_string (ATSstrcst(": funlab_top")) ; /* tmp706 = */ atspre_prerr_newline () ; /* tmp703 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp703) ; } /* end of [err_111] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 26901(line=1105, offs=12) -- 27317(line=1119, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_top () { /* local vardec */ ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp710) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_top: tmp707 = atspre_ref_get_view_ptr (statmp684) ; tmp708 = ats_selsin_mac(tmp707, atslab_1) ; tmp709 = ats_ptrget_mac(ats_ptr_type, tmp708) ; do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (tmp709 == (ats_sum_ptr_type)0) { goto __ats_lab_110_0 ; } __ats_lab_109_1: tmp710 = ats_caselptrlab_mac(anairiats_sum_1, tmp709, atslab_0) ; tmp702 = tmp710 ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: // if (tmp709 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_110_1: tmp702 = err_111 () ; break ; } while (0) ; return (tmp702) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlab_top] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 27982(line=1145, offs=4) -- 28390(line=1163, offs=2) */ ATSstaticdec() ats_ptr_type _funentry_make_112 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; __ats_lab__funentry_make_112: tmp712 = (ats_sum_ptr_type)0 ; tmp711 = ATS_MALLOC(sizeof(anairiats_rec_10)) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_loc, arg0) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_lab, arg1) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_lev, arg2) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_vtps, arg4) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_vtps_flag, 0) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_labset, arg3) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_ret, arg5) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_body, arg6) ; ats_selptrset_mac(anairiats_rec_10, tmp711, atslab_funentry_tailjoin, tmp712) ; return (tmp711) ; } /* end of [_funentry_make_112] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28446(line=1166, offs=4) -- 28560(line=1168, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp713) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make: tmp713 = _funentry_make_112 (arg0, arg1, arg2, arg3, arg4, arg5, arg6) ; return (tmp713) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28615(line=1170, offs=28) -- 28643(line=1170, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp714) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc: tmp714 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_loc) ; return (tmp714) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28671(line=1171, offs=28) -- 28699(line=1171, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp715) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab: tmp715 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_lab) ; return (tmp715) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28727(line=1172, offs=28) -- 28755(line=1172, offs=56) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp716) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev: tmp716 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_lev) ; return (tmp716) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28784(line=1173, offs=29) -- 28813(line=1173, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp717) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps: tmp717 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_vtps) ; return (tmp717) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28847(line=1174, offs=34) -- 28881(line=1174, offs=68) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_flag (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp718) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_flag: tmp718 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_vtps_flag) ; return (tmp718) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_flag] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28912(line=1175, offs=31) -- 28943(line=1175, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp719) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset: tmp719 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_labset) ; return (tmp719) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 28971(line=1176, offs=28) -- 28999(line=1176, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp720) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret: tmp720 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_ret) ; return (tmp720) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 29028(line=1177, offs=29) -- 29057(line=1177, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp721) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body: tmp721 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_body) ; return (tmp721) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 29090(line=1178, offs=33) -- 29123(line=1178, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_tailjoin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp722) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_tailjoin: tmp722 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_funentry_tailjoin) ; return (tmp722) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_tailjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 29177(line=1183, offs=20) -- 29269(line=1187, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate: tmp724 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (arg0) ; tmp725 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp725, atslab_0, arg0) ; /* tmp723 = */ atsopt_funlab_set_entry (tmp724, tmp725) ; return /* (tmp723) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 29454(line=1196, offs=7) -- 30146(line=1215, offs=6) */ ATSstaticdec() ats_void_type aux_125 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_int_type, tmp730) ; ATSlocal (ats_bool_type, tmp731) ; ATSlocal (ats_bool_type, tmp732) ; // ATSlocal_void (tmp733) ; ATSlocal (ats_clo_ptr_type, tmp734) ; ATSlocal (ats_ptr_type, tmp735) ; __ats_lab_aux_125: tmp729 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (arg0) ; tmp730 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (tmp729) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: __ats_lab_111_1: tmp731 = atspre_gte_int_int (tmp730, env0) ; if (!tmp731) { goto __ats_lab_112_1 ; } tmp732 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_mem (arg0) ; if (tmp732) { /* empty */ } else { /* tmp733 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (arg0) ; /* ats_clo_ptr_type tmp734 ; */ tmp735 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset (tmp729) ; tmp734 = aux_125_closure_make (env0) ; /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr (tmp735, tmp734) ; ATS_FREE(tmp734) ; } /* end of [if] */ break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (arg0) ; break ; } while (0) ; return /* (tmp728) */ ; } /* end of [aux_125] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } aux_125_closure_type ; ats_void_type aux_125_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_125 (((aux_125_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_125_closure_init (aux_125_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_125_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_125_closure_make (ats_int_type env0) { aux_125_closure_type *p_clo = ATS_MALLOC(sizeof(aux_125_closure_type)) ; aux_125_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 29343(line=1193, offs=4) -- 30445(line=1226, offs=4) */ ATSstaticdec() ats_ptr_type funentry_get_labset_all_124 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_int_type, tmp727) ; // ATSlocal_void (tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; // ATSlocal_void (tmp738) ; ATSlocal (ats_clo_ptr_type, tmp739) ; __ats_lab_funentry_get_labset_all_124: tmp727 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (arg0) ; /* tmp736 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push () ; tmp737 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_labset (arg0) ; /* ats_clo_ptr_type tmp739 ; */ tmp739 = aux_125_closure_make (tmp727) ; /* tmp738 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_cloptr (tmp737, tmp739) ; ATS_FREE(tmp739) ; tmp726 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop () ; return (tmp726) ; } /* end of [funentry_get_labset_all_124] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 30945(line=1244, offs=7) -- 31492(line=1263, offs=6) */ ATSstaticdec() ats_void_type aux_127 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_int_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_int_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_bool_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; __ats_lab_aux_127: // tmp744 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp745 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp746 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (arg0) ; tmp747 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (tmp746) ; tmp749 = atspre_lt_int_int (tmp747, tmp745) ; if (tmp749) { tmp748 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp746) ; } else { tmp748 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps (tmp746) ; } /* end of [if] */ tmp751 = ats_ptrget_mac(ats_ptr_type, tmp744) ; tmp750 = set_union_01744_ats_ptr_type (tmp748, tmp751, &ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__compare_vartyp_vartyp) ; ats_ptrget_mac(ats_ptr_type, tmp744) = tmp750 ; return /* (tmp743) */ ; } /* end of [aux_127] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 30595(line=1233, offs=23) -- 32251(line=1290, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_int_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; // ATSlocal_void (tmp752) ; ATSlocal (ats_bool_type, tmp753) ; ATSlocal (ats_int_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; // ATSlocal_void (tmp757) ; // ATSlocal_void (tmp758) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all: tmp741 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_flag (arg0) ; /* ats_ptr_type tmp742 ; */ tmp742 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps (arg0) ; tmp753 = atspre_eq_int_int (tmp741, 0) ; if (tmp753) { tmp754 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (arg0) ; tmp755 = funentry_get_labset_all_124 (arg0) ; tmp756 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp756, atslab_0, (&tmp742)) ; ats_selptrset_mac(anairiats_sum_11, tmp756, atslab_1, tmp754) ; /* tmp757 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funlabset_foreach_main (tmp755, &aux_127, tmp756) ; // ATS_FREE(tmp756) ; /* tmp758 = */ atsopt_funentry_set_vtps (arg0, tmp742) ; /* tmp752 = */ atsopt_funentry_set_vtps_flag (arg0) ; } else { /* empty */ } /* end of [if] */ tmp740 = tmp742 ; return (tmp740) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 32462(line=1302, offs=4) -- 32556(line=1304, offs=4) */ ATSstaticdec() ats_ptr_type varindmap_nil_128 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp759) ; __ats_lab_varindmap_nil_128: tmp759 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) ; return (tmp759) ; } /* end of [varindmap_nil_128] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_0194_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_int_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; ATSlocal (ats_int_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; __ats_lab_bst_search_0194_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_113_1: tmp769 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_1) ; tmp770 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_2) ; tmp771 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_3) ; tmp772 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_4) ; tmp773 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp769) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp773 != -1) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp774 = ats_ptrget_mac(ats_ptr_type, tmp771) ; arg0 = tmp774 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0194_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (tmp773 != 1) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp775 = ats_ptrget_mac(ats_ptr_type, tmp772) ; arg0 = tmp775 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_0194_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (tmp773 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: tmp768 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp768, atslab_0, tmp770) ; break ; } while (0) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp768 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp768) ; } /* end of [bst_search_0194_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01735_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp776) ; __ats_lab_map_search_01735_ats_ptr_type_2cats_int_type: // tmp766 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp767 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp776 = ats_ptrget_mac(ats_ptr_type, tmp767) ; tmp765 = bst_search_0194_ats_ptr_type_2cats_int_type (tmp776, arg1, tmp766) ; return (tmp765) ; } /* end of [map_search_01735_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 32673(line=1311, offs=16) -- 32796(line=1316, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp777) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find: tmp763 = atspre_ref_get_view_ptr (statmp760) ; tmp764 = ats_selsin_mac(tmp763, atslab_1) ; tmp777 = ats_ptrget_mac(ats_ptr_type, tmp764) ; tmp762 = map_search_01735_ats_ptr_type_2cats_int_type (tmp777, arg0) ; return (tmp762) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 32855(line=1319, offs=21) -- 33103(line=1326, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_int_type, tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some: tmp779 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find (arg0) ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (tmp779 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp780 = ats_caselptrlab_mac(anairiats_sum_13, tmp779, atslab_0) ; ATS_FREE(tmp779) ; tmp778 = tmp780 ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (tmp779 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: /* tmp781 = */ prerr_interror_0 () ; /* tmp782 = */ atspre_prerr_string (ATSstrcst(": varindmap_find: d2v = ")) ; /* tmp783 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg0) ; /* tmp784 = */ atspre_prerr_newline () ; /* tmp778 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp778) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__varindmap_find_some] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_0162_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; // ATSlocal_void (tmp794) ; __ats_lab_bst_free_0162_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp792 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_3) ; tmp793 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp794 = */ bst_free_0162_ats_ptr_type_2cats_int_type (tmp792) ; arg0 = tmp793 ; goto __ats_lab_bst_free_0162_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: break ; } while (0) ; return /* (tmp791) */ ; } /* end of [bst_free_0162_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_01731_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; __ats_lab_map_free_01731_ats_ptr_type_2cats_int_type: // tmp790 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp789 = */ bst_free_0162_ats_ptr_type_2cats_int_type (tmp790) ; return /* (tmp789) */ ; } /* end of [map_free_01731_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 33172(line=1329, offs=26) -- 33332(line=1335, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_reset () { /* local vardec */ // ATSlocal_void (tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; // ATSlocal_void (tmp788) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_reset: tmp786 = atspre_ref_get_view_ptr (statmp760) ; tmp787 = ats_selsin_mac(tmp786, atslab_1) ; tmp795 = ats_ptrget_mac(ats_ptr_type, tmp787) ; /* tmp788 = */ map_free_01731_ats_ptr_type_2cats_int_type (tmp795) ; tmp796 = varindmap_nil_128 () ; ats_ptrget_mac(ats_ptr_type, tmp787) = tmp796 ; return /* (tmp785) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_reset] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_0166_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp831) ; ATSlocal (ats_int_type, tmp832) ; __ats_lab_bst_size_0166_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_124 */ __ats_lab_124_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp832 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp831 = tmp832 ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_125_1: tmp831 = 0 ; break ; } while (0) ; return (tmp831) ; } /* end of [bst_size_0166_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_0171_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_bool_type, tmp822) ; ATSlocal (ats_int_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_int_type, tmp829) ; ATSlocal (ats_int_type, tmp830) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_int_type, tmp835) ; ATSlocal (ats_int_type, tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_int_type, tmp842) ; ATSlocal (ats_int_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_int_type, tmp846) ; ATSlocal (ats_int_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; __ats_lab_bst_insert_atroot_0171_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_123_1: tmp818 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp819 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_1) ; tmp820 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_3) ; tmp821 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_4) ; tmp823 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp819) ; tmp822 = atspre_ilte (tmp823, 0) ; if (tmp822) { tmp825 = ats_ptrget_mac(ats_ptr_type, tmp820) ; tmp824 = bst_insert_atroot_0171_ats_ptr_type_2cats_int_type (tmp825, arg1, arg2, arg3) ; // if (tmp824 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp826 = &ats_caselptrlab_mac(anairiats_sum_12, tmp824, atslab_0) ; tmp827 = &ats_caselptrlab_mac(anairiats_sum_12, tmp824, atslab_3) ; tmp828 = &ats_caselptrlab_mac(anairiats_sum_12, tmp824, atslab_4) ; tmp829 = ats_ptrget_mac(ats_int_type, tmp818) ; tmp833 = ats_ptrget_mac(ats_ptr_type, tmp827) ; tmp830 = bst_size_0166_ats_ptr_type_2cats_int_type (tmp833) ; tmp834 = ats_ptrget_mac(ats_ptr_type, tmp828) ; ats_ptrget_mac(ats_ptr_type, tmp820) = tmp834 ; tmp835 = atspre_isub (tmp829, tmp830) ; ats_ptrget_mac(ats_int_type, tmp818) = tmp835 ; ats_ptrget_mac(ats_ptr_type, tmp828) = arg0 ; tmp836 = atspre_iadd (tmp829, 1) ; ats_ptrget_mac(ats_int_type, tmp826) = tmp836 ; tmp817 = tmp824 ; } else { tmp838 = ats_ptrget_mac(ats_ptr_type, tmp821) ; tmp837 = bst_insert_atroot_0171_ats_ptr_type_2cats_int_type (tmp838, arg1, arg2, arg3) ; // if (tmp837 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp839 = &ats_caselptrlab_mac(anairiats_sum_12, tmp837, atslab_0) ; tmp840 = &ats_caselptrlab_mac(anairiats_sum_12, tmp837, atslab_3) ; tmp841 = &ats_caselptrlab_mac(anairiats_sum_12, tmp837, atslab_4) ; tmp842 = ats_ptrget_mac(ats_int_type, tmp818) ; tmp844 = ats_ptrget_mac(ats_ptr_type, tmp841) ; tmp843 = bst_size_0166_ats_ptr_type_2cats_int_type (tmp844) ; tmp845 = ats_ptrget_mac(ats_ptr_type, tmp840) ; ats_ptrget_mac(ats_ptr_type, tmp821) = tmp845 ; tmp846 = atspre_isub (tmp842, tmp843) ; ats_ptrget_mac(ats_int_type, tmp818) = tmp846 ; ats_ptrget_mac(ats_ptr_type, tmp840) = arg0 ; tmp847 = atspre_iadd (tmp842, 1) ; ats_ptrget_mac(ats_int_type, tmp839) = tmp847 ; tmp817 = tmp837 ; } /* end of [if] */ break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: tmp848 = (ats_sum_ptr_type)0 ; tmp849 = (ats_sum_ptr_type)0 ; tmp817 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp817, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_12, tmp817, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp817, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_12, tmp817, atslab_3, tmp848) ; ats_selptrset_mac(anairiats_sum_12, tmp817, atslab_4, tmp849) ; break ; } while (0) ; return (tmp817) ; } /* end of [bst_insert_atroot_0171_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_0205_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_bool_type, tmp815) ; ATSlocal (ats_int_type, tmp816) ; ATSlocal (ats_bool_type, tmp850) ; ATSlocal (ats_int_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_int_type, tmp854) ; ATSlocal (ats_int_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_int_type, tmp858) ; ATSlocal (ats_int_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; __ats_lab_bst_insert_random_0205_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_122_1: tmp811 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp812 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_1) ; tmp813 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_3) ; tmp814 = &ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_4) ; tmp816 = ats_ptrget_mac(ats_int_type, tmp811) ; tmp815 = atsopt_map_lin_dice (1, tmp816) ; if (tmp815) { tmp810 = bst_insert_atroot_0171_ats_ptr_type_2cats_int_type (arg0, arg1, arg2, arg3) ; } else { tmp851 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp812) ; tmp850 = atspre_ilte (tmp851, 0) ; if (tmp850) { tmp853 = ats_ptrget_mac(ats_ptr_type, tmp813) ; tmp852 = bst_insert_random_0205_ats_ptr_type_2cats_int_type (tmp853, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp813) = tmp852 ; tmp855 = ats_ptrget_mac(ats_int_type, tmp811) ; tmp854 = atspre_iadd (tmp855, 1) ; ats_ptrget_mac(ats_int_type, tmp811) = tmp854 ; tmp810 = arg0 ; } else { tmp857 = ats_ptrget_mac(ats_ptr_type, tmp814) ; tmp856 = bst_insert_random_0205_ats_ptr_type_2cats_int_type (tmp857, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp814) = tmp856 ; tmp859 = ats_ptrget_mac(ats_int_type, tmp811) ; tmp858 = atspre_iadd (tmp859, 1) ; ats_ptrget_mac(ats_int_type, tmp811) = tmp858 ; tmp810 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: tmp860 = (ats_sum_ptr_type)0 ; tmp861 = (ats_sum_ptr_type)0 ; tmp810 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp810, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_12, tmp810, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp810, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_12, tmp810, atslab_3, tmp860) ; ats_selptrset_mac(anairiats_sum_12, tmp810, atslab_4, tmp861) ; break ; } while (0) ; return (tmp810) ; } /* end of [bst_insert_random_0205_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01733_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp862) ; __ats_lab_map_insert_01733_ats_ptr_type_2cats_int_type: // tmp807 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp808 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp862 = ats_ptrget_mac(ats_ptr_type, tmp808) ; tmp809 = bst_insert_random_0205_ats_ptr_type_2cats_int_type (tmp862, arg1, arg2, tmp807) ; ats_ptrget_mac(ats_ptr_type, tmp808) = tmp809 ; return /* (tmp806) */ ; } /* end of [map_insert_01733_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 33566(line=1343, offs=6) -- 33833(line=1350, offs=6) */ ATSstaticdec() ats_void_type f_137 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_int_type, tmp804) ; ATSlocal (ats_int_type, tmp805) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; __ats_lab_f_137: // tmp802 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp803 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp804 = ats_ptrget_mac(ats_int_type, tmp803) ; tmp805 = atspre_add_int_int (tmp804, 1) ; ats_ptrget_mac(ats_int_type, tmp803) = tmp805 ; tmp863 = ats_ptrget_mac(ats_ptr_type, tmp802) ; tmp864 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__vartyp_get_var (arg0) ; /* tmp801 = */ map_insert_01733_ats_ptr_type_2cats_int_type (tmp863, tmp864, tmp804) ; return /* (tmp801) */ ; } /* end of [f_137] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 33404(line=1338, offs=24) -- 34052(line=1358, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_set (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp797) ; ATSlocal (ats_int_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_ptr_type, tmp865) ; // ATSlocal_void (tmp866) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_set: /* ats_int_type tmp798 ; */ tmp798 = 0 ; tmp799 = atspre_ref_get_view_ptr (statmp760) ; tmp800 = ats_selsin_mac(tmp799, atslab_1) ; tmp865 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp865, atslab_0, tmp800) ; ats_selptrset_mac(anairiats_sum_1, tmp865, atslab_1, (&tmp798)) ; /* tmp866 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_foreach_main (arg0, &f_137, tmp865) ; // ATS_FREE(tmp865) ; return /* (tmp797) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_varindmap_set] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 34294(line=1373, offs=21) -- 34530(line=1383, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp869) ; ATSlocal (ats_ptr_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst: tmp870 = atspre_ref_get_view_ptr (statmp867) ; tmp871 = ats_selsin_mac(tmp870, atslab_1) ; tmp873 = ats_ptrget_mac(ats_ptr_type, tmp871) ; tmp872 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp872, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp872, atslab_1, tmp873) ; ats_ptrget_mac(ats_ptr_type, tmp871) = tmp872 ; return /* (tmp869) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 34594(line=1386, offs=21) -- 34809(line=1396, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lablst () { /* local vardec */ ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; ATSlocal (ats_ptr_type, tmp878) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lablst: tmp875 = atspre_ref_get_view_ptr (statmp867) ; tmp876 = ats_selsin_mac(tmp875, atslab_1) ; tmp877 = ats_ptrget_mac(ats_ptr_type, tmp876) ; tmp878 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp876) = tmp878 ; tmp874 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp877) ; return (tmp874) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 35226(line=1419, offs=3) -- 35405(line=1424, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_push (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_push: tmp882 = atspre_ref_get_view_ptr (statmp879) ; tmp883 = ats_selsin_mac(tmp882, atslab_1) ; tmp885 = ats_ptrget_mac(ats_ptr_type, tmp883) ; tmp884 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ats_selptrset_mac(anairiats_sum_14, tmp884, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_14, tmp884, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_14, tmp884, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_14, tmp884, atslab_3, tmp885) ; ats_ptrget_mac(ats_ptr_type, tmp883) = tmp884 ; return /* (tmp881) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_push] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 35466(line=1427, offs=19) -- 35890(line=1442, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_pop () { /* local vardec */ // ATSlocal_void (tmp886) ; ATSlocal (ats_int_type, tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_bool_type, tmp893) ; // ATSlocal_void (tmp894) ; // ATSlocal_void (tmp895) ; // ATSlocal_void (tmp896) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_pop: /* ats_int_type tmp887 ; */ tmp887 = 0 ; tmp888 = atspre_ref_get_view_ptr (statmp879) ; tmp889 = ats_selsin_mac(tmp888, atslab_1) ; tmp891 = ats_ptrget_mac(ats_ptr_type, tmp889) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (tmp891 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp892 = ats_caselptrlab_mac(anairiats_sum_14, tmp891, atslab_3) ; ATS_FREE(tmp891) ; ats_ptrget_mac(ats_ptr_type, tmp889) = tmp892 ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (tmp891 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp887 = 1 ; break ; } while (0) ; tmp893 = atspre_gt_int_int (tmp887, 0) ; if (tmp893) { /* tmp894 = */ prerr_interror_0 () ; /* tmp895 = */ atspre_prerr_string (ATSstrcst(": loopexnlablst_pop")) ; /* tmp896 = */ atspre_prerr_newline () ; /* tmp886 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp886) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 35965(line=1446, offs=6) -- 36101(line=1449, offs=6) */ ATSstaticdec() ats_ptr_type tmplab_gen_147 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp898) ; // ATSlocal_void (tmp899) ; // ATSlocal_void (tmp900) ; // ATSlocal_void (tmp901) ; __ats_lab_tmplab_gen_147: /* tmp899 = */ prerr_interror_0 () ; /* tmp900 = */ atspre_prerr_string (ATSstrcst(": loopexnlablst_get")) ; /* tmp901 = */ atspre_prerr_newline () ; /* tmp898 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp898) ; } /* end of [tmplab_gen_147] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 35950(line=1445, offs=19) -- 36463(line=1460, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_bool_type, tmp907) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get: tmp902 = atspre_ref_get_view_ptr (statmp879) ; tmp903 = ats_selsin_mac(tmp902, atslab_1) ; tmp904 = ats_ptrget_mac(ats_ptr_type, tmp903) ; do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (tmp904 == (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp905 = ats_caselptrlab_mac(anairiats_sum_14, tmp904, atslab_1) ; tmp906 = ats_caselptrlab_mac(anairiats_sum_14, tmp904, atslab_2) ; tmp907 = atspre_eq_int_int (arg0, 0) ; if (tmp907) { tmp897 = tmp905 ; } else { tmp897 = tmp906 ; } /* end of [if] */ break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (tmp904 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: tmp897 = tmplab_gen_147 () ; break ; } while (0) ; return (tmp897) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__loopexnlablst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 36689(line=1474, offs=7) -- 37352(line=1492, offs=6) */ ATSstaticdec() ats_ptr_type aux_149 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; ATSlocal (ats_ptr_type, tmp920) ; __ats_lab_aux_149: do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp912 = &ats_caselptrlab_mac(anairiats_sum_15, arg0, atslab_1) ; tmp913 = ats_ptrget_mac(ats_ptr_type, tmp912) ; ats_ptrget_mac(ats_ptr_type, tmp912) = arg1 ; tmp914 = arg0 ; arg0 = tmp913 ; arg1 = tmp914 ; goto __ats_lab_aux_149 ; // tail call break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp915 = &ats_caselptrlab_mac(anairiats_sum_15, arg0, atslab_1) ; tmp916 = ats_ptrget_mac(ats_ptr_type, tmp915) ; ats_ptrget_mac(ats_ptr_type, tmp915) = arg1 ; tmp917 = arg0 ; arg0 = tmp916 ; arg1 = tmp917 ; goto __ats_lab_aux_149 ; // tail call break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp918 = &ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_2) ; tmp919 = ats_ptrget_mac(ats_ptr_type, tmp918) ; ats_ptrget_mac(ats_ptr_type, tmp918) = arg1 ; tmp920 = arg0 ; arg0 = tmp919 ; arg1 = tmp920 ; goto __ats_lab_aux_149 ; // tail call break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: tmp911 = arg1 ; break ; } while (0) ; return (tmp911) ; } /* end of [aux_149] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 36630(line=1472, offs=4) -- 37403(line=1495, offs=4) */ ATSstaticdec() ats_ptr_type glocstlst_reverse_148 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp921) ; __ats_lab_glocstlst_reverse_148: tmp921 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; tmp910 = aux_149 (arg0, tmp921) ; return (tmp910) ; } /* end of [glocstlst_reverse_148] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 37487(line=1500, offs=19) -- 37672(line=1509, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; ATSlocal (ats_ptr_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_get: tmp923 = atspre_ref_get_view_ptr (statmp908) ; tmp924 = ats_selsin_mac(tmp923, atslab_1) ; tmp925 = ats_ptrget_mac(ats_ptr_type, tmp924) ; tmp926 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; ats_ptrget_mac(ats_ptr_type, tmp924) = tmp926 ; tmp922 = glocstlst_reverse_148 (tmp925) ; return (tmp922) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 37757(line=1514, offs=23) -- 37866(line=1518, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_clo (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_clo: tmp928 = atspre_ref_get_view_ptr (statmp908) ; tmp929 = ats_selsin_mac(tmp928, atslab_1) ; tmp931 = ats_ptrget_mac(ats_ptr_type, tmp929) ; tmp930 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp930)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp930, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp930, atslab_1, tmp931) ; ats_ptrget_mac(ats_ptr_type, tmp929) = tmp930 ; return /* (tmp927) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_clo] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 37934(line=1521, offs=23) -- 38043(line=1525, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_fun (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; ATSlocal (ats_ptr_type, tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_fun: tmp933 = atspre_ref_get_view_ptr (statmp908) ; tmp934 = ats_selsin_mac(tmp933, atslab_1) ; tmp936 = ats_ptrget_mac(ats_ptr_type, tmp934) ; tmp935 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp935)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp935, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp935, atslab_1, tmp936) ; ats_ptrget_mac(ats_ptr_type, tmp934) = tmp935 ; return /* (tmp932) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 38111(line=1528, offs=23) -- 38228(line=1532, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_val (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp937) ; ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_val: tmp938 = atspre_ref_get_view_ptr (statmp908) ; tmp939 = ats_selsin_mac(tmp938, atslab_1) ; tmp941 = ats_ptrget_mac(ats_ptr_type, tmp939) ; tmp940 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp940)->tag = 2 ; ats_selptrset_mac(anairiats_sum_16, tmp940, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_16, tmp940, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp940, atslab_2, tmp941) ; ats_ptrget_mac(ats_ptr_type, tmp939) = tmp940 ; return /* (tmp937) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_glocstlst_add_val] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 38458(line=1546, offs=7) -- 38748(line=1554, offs=6) */ ATSstaticdec() ats_ptr_type aux_155 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_ptr_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; __ats_lab_aux_155: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp946 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp947 = ats_ptrget_mac(ats_ptr_type, tmp946) ; ats_ptrget_mac(ats_ptr_type, tmp946) = arg1 ; tmp948 = arg0 ; arg0 = tmp947 ; arg1 = tmp948 ; goto __ats_lab_aux_155 ; // tail call break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp945 = arg1 ; break ; } while (0) ; return (tmp945) ; } /* end of [aux_155] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 38399(line=1544, offs=4) -- 38799(line=1557, offs=4) */ ATSstaticdec() ats_ptr_type partvalst_reverse_154 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp944) ; ATSlocal (ats_ptr_type, tmp949) ; __ats_lab_partvalst_reverse_154: tmp949 = (ats_sum_ptr_type)0 ; tmp944 = aux_155 (arg0, tmp949) ; return (tmp944) ; } /* end of [partvalst_reverse_154] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 38883(line=1562, offs=19) -- 39068(line=1571, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp950) ; ATSlocal (ats_ptr_type, tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_get: tmp951 = atspre_ref_get_view_ptr (statmp942) ; tmp952 = ats_selsin_mac(tmp951, atslab_1) ; tmp953 = ats_ptrget_mac(ats_ptr_type, tmp952) ; tmp954 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp952) = tmp954 ; tmp950 = partvalst_reverse_154 (tmp953) ; return (tmp950) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 39128(line=1574, offs=19) -- 39243(line=1578, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_add: tmp956 = atspre_ref_get_view_ptr (statmp942) ; tmp957 = ats_selsin_mac(tmp956, atslab_1) ; tmp959 = ats_ptrget_mac(ats_ptr_type, tmp957) ; tmp958 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp958, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp958, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp958, atslab_2, tmp959) ; ats_ptrget_mac(ats_ptr_type, tmp957) = tmp958 ; return /* (tmp955) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_partvalst_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 39382(line=1589, offs=4) -- 39444(line=1590, offs=49) */ ATSstaticdec() ats_ptr_type cstctx_nil_158 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp960) ; __ats_lab_cstctx_nil_158: tmp960 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2cst_d2cst) ; return (tmp960) ; } /* end of [cstctx_nil_158] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 39572(line=1598, offs=19) -- 39703(line=1603, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add: tmp964 = atspre_ref_get_view_ptr (statmp961) ; tmp965 = ats_selsin_mac(tmp964, atslab_1) ; tmp966 = ats_ptrget_mac(ats_ptr_type, tmp965) ; /* tmp963 = */ map_insert_01733_ats_ptr_type_2cats_ptr_type (tmp966, arg0, arg1) ; return /* (tmp963) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 39764(line=1606, offs=20) -- 39887(line=1611, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_ptr_type, tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find: tmp968 = atspre_ref_get_view_ptr (statmp961) ; tmp969 = ats_selsin_mac(tmp968, atslab_1) ; tmp970 = ats_ptrget_mac(ats_ptr_type, tmp969) ; tmp967 = map_search_01735_ats_ptr_type_2cats_ptr_type (tmp970, arg0) ; return (tmp967) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_topcstctx_find] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 40132(line=1626, offs=25) -- 40283(line=1631, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_get_free () { /* local vardec */ ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; ATSlocal (ats_ptr_type, tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_get_free: tmp974 = atspre_ref_get_view_ptr (statmp971) ; tmp975 = ats_selsin_mac(tmp974, atslab_1) ; tmp976 = ats_ptrget_mac(ats_ptr_type, tmp975) ; tmp977 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp975) = tmp977 ; tmp973 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp976) ; return (tmp973) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_get_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_env.dats: 40355(line=1634, offs=25) -- 40463(line=1638, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free: tmp979 = atspre_ref_get_view_ptr (statmp971) ; tmp980 = ats_selsin_mac(tmp979, atslab_1) ; tmp982 = ats_ptrget_mac(ats_ptr_type, tmp980) ; tmp981 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp981, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp981, atslab_1, tmp982) ; ats_ptrget_mac(ats_ptr_type, tmp980) = tmp981 ; return /* (tmp978) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_valprimlst_add_free] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__ENVcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__LOOPEXNLABLSTnil_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp30, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp41, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp42, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp60, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp61, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp175, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp176, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp190, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp191, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp214, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp215, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp238, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp239, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp240, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp501, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp502, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp503, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp548, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp554, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp555, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp556, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp598, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp599, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp610, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp611, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp630, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp631, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp650, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp651, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp670, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp671, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp684, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp685, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp760, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp761, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp867, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp868, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp879, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp880, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp908, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp909, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp942, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp943, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp961, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp962, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp971, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp972, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp30 = ref_make_elt_04079_ats_ptr_type (ATSstrcst("anairiats")) ; statmp33 = ref_make_elt_04079_ats_int_type (0) ; statmp42 = (ats_sum_ptr_type)0 ; statmp41 = ref_make_elt_04079_ats_ptr_type (statmp42) ; statmp61 = typdefmap_nil_13 () ; statmp60 = ref_make_elt_04079_ats_ptr_type (statmp61) ; statmp176 = (ats_sum_ptr_type)0 ; statmp175 = ref_make_elt_04079_ats_ptr_type (statmp176) ; statmp191 = (ats_sum_ptr_type)0 ; statmp190 = ref_make_elt_04079_ats_ptr_type (statmp191) ; statmp215 = (ats_sum_ptr_type)0 ; statmp214 = ref_make_elt_04079_ats_ptr_type (statmp215) ; statmp238 = ref_make_elt_04079_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; statmp240 = (ats_sum_ptr_type)0 ; statmp239 = ref_make_elt_04079_ats_ptr_type (statmp240) ; statmp501 = ref_make_elt_04079_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; statmp503 = (ats_sum_ptr_type)0 ; statmp502 = ref_make_elt_04079_ats_ptr_type (statmp503) ; statmp548 = ref_make_elt_04079_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; statmp554 = ref_make_elt_04079_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; statmp556 = (ats_sum_ptr_type)0 ; statmp555 = ref_make_elt_04079_ats_ptr_type (statmp556) ; statmp599 = (ats_sum_ptr_type)0 ; statmp598 = ref_make_elt_04079_ats_ptr_type (statmp599) ; statmp611 = (ats_sum_ptr_type)0 ; statmp610 = ref_make_elt_04079_ats_ptr_type (statmp611) ; statmp631 = (ats_sum_ptr_type)0 ; statmp630 = ref_make_elt_04079_ats_ptr_type (statmp631) ; statmp651 = (ats_sum_ptr_type)0 ; statmp650 = ref_make_elt_04079_ats_ptr_type (statmp651) ; statmp671 = (ats_sum_ptr_type)0 ; statmp670 = ref_make_elt_04079_ats_ptr_type (statmp671) ; statmp685 = (ats_sum_ptr_type)0 ; statmp684 = ref_make_elt_04079_ats_ptr_type (statmp685) ; statmp761 = varindmap_nil_128 () ; statmp760 = ref_make_elt_04079_ats_ptr_type (statmp761) ; statmp868 = (ats_sum_ptr_type)0 ; statmp867 = ref_make_elt_04079_ats_ptr_type (statmp868) ; statmp880 = (ats_sum_ptr_type)0 ; statmp879 = ref_make_elt_04079_ats_ptr_type (statmp880) ; statmp909 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; statmp908 = ref_make_elt_04079_ats_ptr_type (statmp909) ; statmp943 = (ats_sum_ptr_type)0 ; statmp942 = ref_make_elt_04079_ats_ptr_type (statmp943) ; statmp962 = cstctx_nil_158 () ; statmp961 = ref_make_elt_04079_ats_ptr_type (statmp962) ; statmp972 = (ats_sum_ptr_type)0 ; statmp971 = ref_make_elt_04079_ats_ptr_type (statmp972) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_funentry_set_vtps (ats_ptr_type entry, ats_ptr_type vtps) { ((funentry_t)entry)->atslab_funentry_vtps = vtps ; return ; } // end of [atsopt_funentry_set_vtps] ats_void_type atsopt_funentry_set_vtps_flag (ats_ptr_type entry) { ((funentry_t)entry)->atslab_funentry_vtps_flag = 1 ; return ; } // end of [atsopt_funentry_set_vtps_flag] ats_void_type atsopt_funentry_set_tailjoin (ats_ptr_type entry, ats_ptr_type tjs) { ((funentry_t)entry)->atslab_funentry_tailjoin = tjs ; return ; } // end of [atsopt_funentry_set_tailjoin] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_env_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp1_syndef_sats.c0000664000175000017500000000344412223166160023103 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_syndef_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp1_syndef_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_array_dats.c0000664000175000017500000000654612223166160021250 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_array_ptr_alloc_tsz) (ats_int_type, ats_size_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_array_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_ptr_type ats_array_ptr_alloc_tsz ( ats_int_type n, ats_size_type tsz ) { return ATS_MALLOC(n * tsz) ; // uninitialized } /* end of [ats_array_ptr_alloc_tsz] */ ats_void_type ats_array_ptr_free (ats_ptr_type base) { ATS_FREE(base); return ; } // end of [ats_array_ptr_free] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_array_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_trans_clau_dats.c0000664000175000017500000026551712223166160023453 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_intinf.cats" /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_branch_lab ; ats_ptr_type atslab_branch_inss ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_matpnt_kont ; ats_ptr_type atslab_matpnt_tmpmovlst ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_himat_loc ; ats_ptr_type atslab_himat_exp ; ats_ptr_type atslab_himat_pat ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_hiclau_loc ; ats_ptr_type atslab_hiclau_pat ; ats_ptr_type atslab_hiclau_gua ; ats_ptr_type atslab_hiclau_exp ; } anairiats_rec_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_18 ; typedef struct { anairiats_rec_1 atslab_0 ; } anairiats_sum_19 ; typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_21 ; /* external typedefs */ typedef anairiats_rec_3 *matpnt_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplabint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTmatpnt_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_bool_type, atspre_eq_bool_bool) (ats_bool_type, ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_eq_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool) (ats_ptr_type, ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_matpnt_set_kont) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match) (ats_ref_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar) (ats_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_get_tmpmovlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_matpnt_set_tmpmovlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__ccomp_hiclau) (ats_ptr_type, ats_int_type, ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__sasp__matpnt_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STnil_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type branch_make_0 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type _matpnt_make_1 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_7 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_pat_9 (ats_ref_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_mat_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_gua_11 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_bool_type hipat_is_any_15 (ats_ptr_type arg0) ; static ats_bool_type hipatlst_is_any_16 (ats_ptr_type arg0) ; static ats_bool_type hipatlst_prefix_test_int_20 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_major_21 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type f_23 (ats_int_type env0, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type f_23_closure_make (ats_int_type env0) ; static ats_int_type f_23_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_minor_22 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type auxpat_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type auxpatlst_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type auxlabpatlst_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type auxpatlst_prefix_28 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type auxrev_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_tmpmov_24 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_31 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux_31_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_31_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type auxlst_32 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type auxlst_32_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_int_type auxlst_32_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type auxopt_33 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type auxopt_33_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type auxopt_33_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type matpnt_set_kont_all_30 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxlst_35 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type auxlst_35_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_ptr_type auxlst_35_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 1925(line=63, offs=4) -- 2023(line=68, offs=2) */ ATSstaticdec() ats_ptr_type branch_make_0 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; __ats_lab_branch_make_0: tmp0 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp0, atslab_branch_lab, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp0, atslab_branch_inss, arg1) ; return (tmp0) ; } /* end of [branch_make_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 2626(line=97, offs=4) -- 2722(line=101, offs=2) */ ATSstaticdec() ats_ptr_type _matpnt_make_1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; __ats_lab__matpnt_make_1: tmp1 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp1, atslab_matpnt_kont, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp1, atslab_matpnt_tmpmovlst, arg1) ; return (tmp1) ; } /* end of [_matpnt_make_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 2853(line=109, offs=23) -- 2876(line=109, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt: tmp2 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp2)->tag = 6 ; ats_selptrset_mac(anairiats_sum_4, tmp2, atslab_0, arg0) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 2901(line=111, offs=23) -- 2931(line=111, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make: tmp3 = _matpnt_make_1 (arg0, arg1) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 2958(line=112, offs=27) -- 2981(line=112, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont: tmp4 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_matpnt_kont) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 3013(line=113, offs=32) -- 3041(line=113, offs=60) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_get_tmpmovlst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_get_tmpmovlst: tmp5 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_matpnt_tmpmovlst) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_get_tmpmovlst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 3208(line=122, offs=9) -- 3656(line=134, offs=8) */ ATSstaticdec() ats_void_type aux_7 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; __ats_lab_aux_7: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp10 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp11 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_2) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp10) ; /* tmp13 = */ atspre_fprint_string (arg0, ATSstrcst(" = ")) ; /* tmp14 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (arg0, tmp9) ; /* tmp15 = */ atspre_fprint_string (arg0, ATSstrcst(" ; ")) ; arg0 = arg0 ; arg1 = tmp11 ; goto __ats_lab_aux_7 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp8) */ ; } /* end of [aux_7] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 3071(line=117, offs=3) -- 3765(line=139, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_matpnt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_matpnt: tmp7 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_get_tmpmovlst (arg1) ; /* tmp16 = */ aux_7 (arg0, tmp7) ; tmp17 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__matpnt_get_kont (arg1) ; /* tmp6 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_kont (arg0, tmp17) ; return /* (tmp6) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_matpnt] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 4103(line=163, offs=7) -- 4708(line=183, offs=4) */ ATSstaticdec() ats_ptr_type aux_pat_9 (ats_ref_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_aux_pat_9: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_3_1 ; } __ats_lab_2_2: tmp20 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_0) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_1) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_1) ; tmp24 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp22), atslab_hipat_loc) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint (arg0, tmp24, arg1, ats_ptrget_mac(ats_int_type, arg2)) ; tmp27 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; tmp28 = (ats_sum_ptr_type)0 ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make (tmp27, tmp28) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt (tmp26) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp20, tmp22, tmp30) ; tmp31 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp31 ; tmp32 = aux_pat_9 (arg0, arg1, arg2, tmp21, tmp23) ; tmp19 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp19, atslab_0, tmp26) ; ats_selptrset_mac(anairiats_sum_6, tmp19, atslab_1, tmp32) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: __ats_lab_3_2: tmp19 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp19) ; } /* end of [aux_pat_9] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 4741(line=185, offs=7) -- 5099(line=199, offs=4) */ ATSstaticdec() ats_void_type aux_mat_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_aux_mat_10: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_5_1 ; } __ats_lab_4_2: tmp34 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp35 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_0) ; tmp37 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_1) ; /* tmp38 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, arg1, tmp34, tmp36) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp35 ; arg3 = tmp37 ; goto __ats_lab_aux_mat_10 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: __ats_lab_5_2: break ; } while (0) ; return /* (tmp33) */ ; } /* end of [aux_mat_10] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 5132(line=201, offs=7) -- 5734(line=220, offs=6) */ ATSstaticdec() ats_void_type aux_gua_11 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_aux_gua_11: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_6_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp41 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp40), atslab_himat_pat) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (tmp43 != (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp44 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp40), atslab_himat_loc) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool (tmp44, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool, ats_true_bool) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (tmp43 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_9, tmp43, atslab_0) ; tmp42 = tmp45 ; break ; } while (0) ; tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp40), atslab_himat_exp) ; tmp46 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp (arg0, tmp47) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_patck (arg0, tmp46, tmp42, arg3) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_match (arg0, arg1, tmp46, tmp42) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp41 ; arg3 = arg3 ; goto __ats_lab_aux_gua_11 ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp39) */ ; } /* end of [aux_gua_11] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 4035(line=159, offs=1) -- 6681(line=253, offs=4) */ ATSglobaldec() anairiats_rec_1 ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__ccomp_hiclau (ats_ptr_type arg0, ats_int_type arg1, ats_ref_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp18) ; ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; // ATSlocal_void (tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__ccomp_hiclau: /* ats_int_type tmp50 ; */ tmp50 = 0 ; /* ats_ptr_type tmp51 ; */ tmp51 = (ats_sum_ptr_type)0 ; tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg5), atslab_hiclau_pat) ; tmp53 = aux_pat_9 ((&tmp51), arg3, (&tmp50), arg4, tmp52) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint ((&tmp51), arg0, arg3, tmp50) ; /* tmp55 = */ aux_mat_10 ((&tmp51), arg1, arg4, tmp52) ; /* ats_ptr_type tmp56 ; */ tmp56 = (ats_sum_ptr_type)0 ; tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg5), atslab_hiclau_gua) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (tmp57 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp60 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; tmp61 = (ats_sum_ptr_type)0 ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__matpnt_make (tmp60, tmp61) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__kont_matpnt (tmp59) ; /* tmp62 = */ aux_gua_11 ((&tmp51), arg1, tmp57, tmp63) ; tmp64 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp64, atslab_0, tmp59) ; tmp56 = tmp64 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (tmp57 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: break ; } while (0) ; tmp66 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg5), atslab_hiclau_loc) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_valprimlst_free ((&tmp51), tmp66) ; tmp68 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg5), atslab_hiclau_exp) ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_exp_tmpvar ((&tmp51), tmp68, arg6) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp51) ; tmp71 = branch_make_0 (arg3, tmp69) ; tmp70 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp70, atslab_0, tmp71) ; ats_selptrset_mac(anairiats_sum_6, tmp70, atslab_1, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp70 ; tmp18.atslab_0 = tmp53 ; tmp18.atslab_1 = tmp56 ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__ccomp_hiclau] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 7022(line=267, offs=16) -- 8460(line=301, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_bool_type, tmp79) ; ATSlocal (ats_bool_type, tmp80) ; ATSlocal (ats_char_type, tmp81) ; ATSlocal (ats_char_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_bool_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int: tmp73 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hipat_node) ; tmp74 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp73)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: __ats_lab_12_2: tmp75 = ats_caselptrlab_mac(anairiats_sum_11, tmp73, atslab_0) ; arg0 = tmp75 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: if (((ats_sum_ptr_type)tmp74)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_13_2: tmp76 = ats_caselptrlab_mac(anairiats_sum_11, tmp74, atslab_0) ; arg0 = arg0 ; arg1 = tmp76 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp73)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: __ats_lab_14_2: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: if (((ats_sum_ptr_type)tmp74)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_2: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp73)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: __ats_lab_16_2: tmp77 = ats_caselptrlab_mac(anairiats_sum_12, tmp73, atslab_2) ; arg0 = tmp77 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: if (((ats_sum_ptr_type)tmp74)->tag != 2) { goto __ats_lab_18_0 ; } __ats_lab_17_2: tmp78 = ats_caselptrlab_mac(anairiats_sum_12, tmp74, atslab_2) ; arg0 = arg0 ; arg1 = tmp78 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp73)->tag != 13) { goto __ats_lab_19_0 ; } __ats_lab_18_1: __ats_lab_18_2: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: if (((ats_sum_ptr_type)tmp74)->tag != 13) { goto __ats_lab_20_0 ; } __ats_lab_19_2: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp73)->tag != 3) { goto __ats_lab_21_0 ; } __ats_lab_20_1: if (((ats_sum_ptr_type)tmp74)->tag != 3) { goto __ats_lab_32_1 ; } __ats_lab_20_2: tmp79 = ats_caselptrlab_mac(anairiats_sum_13, tmp73, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_13, tmp74, atslab_0) ; tmp72 = atspre_eq_bool_bool (tmp79, tmp80) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp73)->tag != 4) { goto __ats_lab_22_0 ; } __ats_lab_21_1: if (((ats_sum_ptr_type)tmp74)->tag != 4) { goto __ats_lab_32_1 ; } __ats_lab_21_2: tmp81 = ats_caselptrlab_mac(anairiats_sum_14, tmp73, atslab_0) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_14, tmp74, atslab_0) ; tmp72 = atspre_eq_char_char (tmp81, tmp82) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp73)->tag != 5) { goto __ats_lab_23_0 ; } __ats_lab_22_1: if (((ats_sum_ptr_type)tmp74)->tag != 5) { goto __ats_lab_23_1 ; } __ats_lab_22_2: tmp83 = ats_caselptrlab_mac(anairiats_sum_15, tmp73, atslab_1) ; tmp84 = ats_caselptrlab_mac(anairiats_sum_15, tmp73, atslab_2) ; tmp85 = ats_caselptrlab_mac(anairiats_sum_15, tmp74, atslab_1) ; tmp86 = ats_caselptrlab_mac(anairiats_sum_15, tmp74, atslab_2) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp83, tmp85) ; if (tmp87) { tmp72 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int (tmp84, tmp86) ; } else { tmp72 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp73)->tag != 5) { goto __ats_lab_24_0 ; } __ats_lab_23_1: if (((ats_sum_ptr_type)tmp74)->tag != 6) { goto __ats_lab_32_1 ; } __ats_lab_23_2: tmp88 = ats_caselptrlab_mac(anairiats_sum_15, tmp73, atslab_1) ; tmp89 = ats_caselptrlab_mac(anairiats_sum_16, tmp74, atslab_1) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp88, tmp89) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp73)->tag != 6) { goto __ats_lab_25_0 ; } __ats_lab_24_1: if (((ats_sum_ptr_type)tmp74)->tag != 5) { goto __ats_lab_25_1 ; } __ats_lab_24_2: tmp90 = ats_caselptrlab_mac(anairiats_sum_16, tmp73, atslab_1) ; tmp91 = ats_caselptrlab_mac(anairiats_sum_15, tmp74, atslab_1) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp90, tmp91) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp73)->tag != 6) { goto __ats_lab_26_0 ; } __ats_lab_25_1: if (((ats_sum_ptr_type)tmp74)->tag != 6) { goto __ats_lab_32_1 ; } __ats_lab_25_2: tmp92 = ats_caselptrlab_mac(anairiats_sum_16, tmp73, atslab_1) ; tmp93 = ats_caselptrlab_mac(anairiats_sum_16, tmp74, atslab_1) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp92, tmp93) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp73)->tag != 7) { goto __ats_lab_27_0 ; } __ats_lab_26_1: if (((ats_sum_ptr_type)tmp74)->tag != 7) { goto __ats_lab_32_1 ; } __ats_lab_26_2: tmp72 = ats_true_bool ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp73)->tag != 8) { goto __ats_lab_28_0 ; } __ats_lab_27_1: if (((ats_sum_ptr_type)tmp74)->tag != 8) { goto __ats_lab_32_1 ; } __ats_lab_27_2: tmp94 = ats_caselptrlab_mac(anairiats_sum_4, tmp73, atslab_0) ; tmp95 = ats_caselptrlab_mac(anairiats_sum_4, tmp74, atslab_0) ; tmp72 = atspre_eq_string_string (tmp94, tmp95) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp73)->tag != 9) { goto __ats_lab_29_0 ; } __ats_lab_28_1: if (((ats_sum_ptr_type)tmp74)->tag != 9) { goto __ats_lab_32_1 ; } __ats_lab_28_2: tmp96 = ats_caselptrlab_mac(anairiats_sum_11, tmp73, atslab_1) ; tmp97 = ats_caselptrlab_mac(anairiats_sum_11, tmp74, atslab_1) ; tmp72 = atsopt_eq_intinf_intinf (tmp96, tmp97) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp73)->tag != 10) { goto __ats_lab_30_0 ; } __ats_lab_29_1: if (((ats_sum_ptr_type)tmp74)->tag != 10) { goto __ats_lab_32_1 ; } __ats_lab_29_2: tmp98 = ats_caselptrlab_mac(anairiats_sum_11, tmp73, atslab_1) ; tmp99 = ats_caselptrlab_mac(anairiats_sum_11, tmp74, atslab_1) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int (tmp98, tmp99) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp73)->tag != 11) { goto __ats_lab_31_0 ; } __ats_lab_30_1: if (((ats_sum_ptr_type)tmp74)->tag != 11) { goto __ats_lab_32_1 ; } __ats_lab_30_2: tmp100 = ats_caselptrlab_mac(anairiats_sum_12, tmp73, atslab_1) ; tmp101 = ats_caselptrlab_mac(anairiats_sum_12, tmp74, atslab_1) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int (tmp100, tmp101) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp73)->tag != 12) { goto __ats_lab_32_0 ; } __ats_lab_31_1: if (((ats_sum_ptr_type)tmp74)->tag != 12) { goto __ats_lab_32_1 ; } __ats_lab_31_2: tmp102 = ats_caselptrlab_mac(anairiats_sum_4, tmp73, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_4, tmp74, atslab_0) ; tmp72 = atspre_eq_string_string (tmp102, tmp103) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: __ats_lab_32_2: tmp72 = ats_false_bool ; break ; } while (0) ; return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 8566(line=305, offs=19) -- 8980(line=317, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_bool_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp105 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp106 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int (tmp105, tmp107) ; if (tmp109) { arg0 = tmp106 ; arg1 = tmp108 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int ; // tail call } else { tmp104 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp104 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp104 = ats_false_bool ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp104 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_int] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 9048(line=321, offs=3) -- 9618(line=338, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_bool_type, tmp115) ; ATSlocal (ats_bool_type, tmp116) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_39_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_0) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_43_0 ; } __ats_lab_40_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp115 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp111, tmp113) ; if (!tmp115) { goto __ats_lab_42_1 ; } tmp116 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int (tmp112, tmp114) ; if (tmp116) { arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int ; // tail call } else { tmp110 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: __ats_lab_42_1: tmp110 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp110 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp110 = ats_false_bool ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp110 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp110) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_int] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 9945(line=350, offs=5) -- 10147(line=357, offs=15) */ ATSstaticdec() ats_bool_type hipat_is_any_15 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_hipat_is_any_15: tmp118 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hipat_node) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp118)->tag != 0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp119 = ats_caselptrlab_mac(anairiats_sum_11, tmp118, atslab_0) ; arg0 = tmp119 ; goto __ats_lab_hipat_is_any_15 ; // tail call break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp118)->tag != 1) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp117 = ats_true_bool ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp118)->tag != 2) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp120 = ats_caselptrlab_mac(anairiats_sum_12, tmp118, atslab_2) ; arg0 = tmp120 ; goto __ats_lab_hipat_is_any_15 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp118)->tag != 13) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp117 = ats_true_bool ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: tmp117 = ats_false_bool ; break ; } while (0) ; return (tmp117) ; } /* end of [hipat_is_any_15] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 10178(line=360, offs=5) -- 10367(line=366, offs=25) */ ATSstaticdec() ats_bool_type hipatlst_is_any_16 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_bool_type, tmp124) ; __ats_lab_hipatlst_is_any_16: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp122 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp123 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp124 = hipat_is_any_15 (tmp122) ; if (tmp124) { arg0 = tmp123 ; goto __ats_lab_hipatlst_is_any_16 ; // tail call } else { tmp121 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp121 = ats_false_bool ; break ; } while (0) ; return (tmp121) ; } /* end of [hipatlst_is_any_16] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 10422(line=370, offs=16) -- 11863(line=403, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_bool_type, tmp132) ; ATSlocal (ats_bool_type, tmp133) ; ATSlocal (ats_char_type, tmp134) ; ATSlocal (ats_char_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_bool_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_bool_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub: tmp126 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hipat_node) ; tmp127 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: if (((ats_sum_ptr_type)tmp127)->tag != 1) { goto __ats_lab_55_1 ; } __ats_lab_54_2: tmp125 = ats_true_bool ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: if (((ats_sum_ptr_type)tmp127)->tag != 13) { goto __ats_lab_56_1 ; } __ats_lab_55_2: tmp125 = ats_true_bool ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: if (((ats_sum_ptr_type)tmp127)->tag != 0) { goto __ats_lab_57_1 ; } __ats_lab_56_2: tmp128 = ats_caselptrlab_mac(anairiats_sum_11, tmp127, atslab_0) ; arg0 = arg0 ; arg1 = tmp128 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub ; // tail call break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: if (((ats_sum_ptr_type)tmp127)->tag != 2) { goto __ats_lab_58_0 ; } __ats_lab_57_2: tmp129 = ats_caselptrlab_mac(anairiats_sum_12, tmp127, atslab_2) ; arg0 = arg0 ; arg1 = tmp129 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp126)->tag != 0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: __ats_lab_58_2: tmp130 = ats_caselptrlab_mac(anairiats_sum_11, tmp126, atslab_0) ; arg0 = tmp130 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp126)->tag != 2) { goto __ats_lab_60_0 ; } __ats_lab_59_1: __ats_lab_59_2: tmp131 = ats_caselptrlab_mac(anairiats_sum_12, tmp126, atslab_2) ; arg0 = tmp131 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub ; // tail call break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp126)->tag != 3) { goto __ats_lab_61_0 ; } __ats_lab_60_1: if (((ats_sum_ptr_type)tmp127)->tag != 3) { goto __ats_lab_72_1 ; } __ats_lab_60_2: tmp132 = ats_caselptrlab_mac(anairiats_sum_13, tmp126, atslab_0) ; tmp133 = ats_caselptrlab_mac(anairiats_sum_13, tmp127, atslab_0) ; tmp125 = atspre_eq_bool_bool (tmp132, tmp133) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp126)->tag != 4) { goto __ats_lab_62_0 ; } __ats_lab_61_1: if (((ats_sum_ptr_type)tmp127)->tag != 4) { goto __ats_lab_72_1 ; } __ats_lab_61_2: tmp134 = ats_caselptrlab_mac(anairiats_sum_14, tmp126, atslab_0) ; tmp135 = ats_caselptrlab_mac(anairiats_sum_14, tmp127, atslab_0) ; tmp125 = atspre_eq_char_char (tmp134, tmp135) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp126)->tag != 5) { goto __ats_lab_63_0 ; } __ats_lab_62_1: if (((ats_sum_ptr_type)tmp127)->tag != 5) { goto __ats_lab_63_1 ; } __ats_lab_62_2: tmp136 = ats_caselptrlab_mac(anairiats_sum_15, tmp126, atslab_1) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_15, tmp126, atslab_2) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_15, tmp127, atslab_1) ; tmp139 = ats_caselptrlab_mac(anairiats_sum_15, tmp127, atslab_2) ; tmp140 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp136, tmp138) ; if (tmp140) { tmp125 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub (tmp137, tmp139) ; } else { tmp125 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp126)->tag != 5) { goto __ats_lab_64_0 ; } __ats_lab_63_1: if (((ats_sum_ptr_type)tmp127)->tag != 6) { goto __ats_lab_72_1 ; } __ats_lab_63_2: tmp141 = ats_caselptrlab_mac(anairiats_sum_15, tmp126, atslab_1) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_16, tmp127, atslab_1) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp141, tmp142) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp126)->tag != 6) { goto __ats_lab_65_0 ; } __ats_lab_64_1: if (((ats_sum_ptr_type)tmp127)->tag != 5) { goto __ats_lab_65_1 ; } __ats_lab_64_2: tmp143 = ats_caselptrlab_mac(anairiats_sum_16, tmp126, atslab_1) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_15, tmp127, atslab_1) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_15, tmp127, atslab_2) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp143, tmp144) ; if (tmp146) { tmp125 = hipatlst_is_any_16 (tmp145) ; } else { tmp125 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp126)->tag != 6) { goto __ats_lab_66_0 ; } __ats_lab_65_1: if (((ats_sum_ptr_type)tmp127)->tag != 6) { goto __ats_lab_72_1 ; } __ats_lab_65_2: tmp147 = ats_caselptrlab_mac(anairiats_sum_16, tmp126, atslab_1) ; tmp148 = ats_caselptrlab_mac(anairiats_sum_16, tmp127, atslab_1) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp147, tmp148) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp126)->tag != 7) { goto __ats_lab_67_0 ; } __ats_lab_66_1: if (((ats_sum_ptr_type)tmp127)->tag != 7) { goto __ats_lab_72_1 ; } __ats_lab_66_2: tmp125 = ats_true_bool ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp126)->tag != 8) { goto __ats_lab_68_0 ; } __ats_lab_67_1: if (((ats_sum_ptr_type)tmp127)->tag != 8) { goto __ats_lab_72_1 ; } __ats_lab_67_2: tmp149 = ats_caselptrlab_mac(anairiats_sum_4, tmp126, atslab_0) ; tmp150 = ats_caselptrlab_mac(anairiats_sum_4, tmp127, atslab_0) ; tmp125 = atspre_eq_string_string (tmp149, tmp150) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp126)->tag != 9) { goto __ats_lab_69_0 ; } __ats_lab_68_1: if (((ats_sum_ptr_type)tmp127)->tag != 9) { goto __ats_lab_72_1 ; } __ats_lab_68_2: tmp151 = ats_caselptrlab_mac(anairiats_sum_11, tmp126, atslab_1) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_11, tmp127, atslab_1) ; tmp125 = atsopt_eq_intinf_intinf (tmp151, tmp152) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp126)->tag != 10) { goto __ats_lab_70_0 ; } __ats_lab_69_1: if (((ats_sum_ptr_type)tmp127)->tag != 10) { goto __ats_lab_72_1 ; } __ats_lab_69_2: tmp153 = ats_caselptrlab_mac(anairiats_sum_11, tmp126, atslab_1) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_11, tmp127, atslab_1) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub (tmp153, tmp154) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp126)->tag != 11) { goto __ats_lab_71_0 ; } __ats_lab_70_1: if (((ats_sum_ptr_type)tmp127)->tag != 11) { goto __ats_lab_72_1 ; } __ats_lab_70_2: tmp155 = ats_caselptrlab_mac(anairiats_sum_12, tmp126, atslab_1) ; tmp156 = ats_caselptrlab_mac(anairiats_sum_12, tmp127, atslab_1) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub (tmp155, tmp156) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)tmp126)->tag != 12) { goto __ats_lab_72_0 ; } __ats_lab_71_1: if (((ats_sum_ptr_type)tmp127)->tag != 12) { goto __ats_lab_72_1 ; } __ats_lab_71_2: tmp157 = ats_caselptrlab_mac(anairiats_sum_4, tmp126, atslab_0) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_4, tmp127, atslab_0) ; tmp125 = atspre_eq_string_string (tmp157, tmp158) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: __ats_lab_72_2: tmp125 = ats_false_bool ; break ; } while (0) ; return (tmp125) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 11978(line=410, offs=3) -- 12359(line=420, offs=8) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_bool_type, tmp164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub: do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_76_0 ; } __ats_lab_73_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp162 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp163 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp164 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub (tmp160, tmp162) ; if (tmp164) { arg0 = tmp161 ; arg1 = tmp163 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub ; // tail call } else { tmp159 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp159 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_76_1: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp159 = ats_false_bool ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_78_1: tmp159 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp159) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipatlst_test_sub] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 12448(line=425, offs=3) -- 12972(line=440, offs=8) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_bool_type, tmp170) ; ATSlocal (ats_bool_type, tmp171) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub: do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_84_0 ; } __ats_lab_79_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_0) ; tmp167 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_83_0 ; } __ats_lab_80_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp170 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp166, tmp168) ; if (!tmp170) { goto __ats_lab_82_1 ; } tmp171 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub (tmp167, tmp169) ; if (tmp171) { arg0 = arg0 ; arg1 = arg1 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub ; // tail call } else { tmp165 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp165 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp165 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp165 = ats_false_bool ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp165 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; return (tmp165) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__labhipatlst_test_sub] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 13165(line=452, offs=5) -- 13834(line=471, offs=4) */ ATSstaticdec() ats_bool_type hipatlst_prefix_test_int_20 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp172) ; ATSlocal (ats_bool_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_bool_type, tmp178) ; ATSlocal (ats_int_type, tmp179) ; __ats_lab_hipatlst_prefix_test_int_20: tmp173 = atspre_gt_int_int (arg0, 0) ; if (tmp173) { do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_87_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp175 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp178 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_int (tmp174, tmp176) ; if (tmp178) { tmp179 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp179 ; arg1 = tmp175 ; arg2 = tmp177 ; goto __ats_lab_hipatlst_prefix_test_int_20 ; // tail call } else { tmp172 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp172 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp172 = ats_false_bool ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_92_1: tmp172 = ats_true_bool ; break ; } while (0) ; break ; } while (0) ; } else { tmp172 = ats_true_bool ; } /* end of [if] */ return (tmp172) ; } /* end of [hipatlst_prefix_test_int_20] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 13873(line=473, offs=5) -- 14227(line=483, offs=4) */ ATSstaticdec() ats_ptr_type aux_major_21 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_bool_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (anairiats_rec_1, tmp186) ; __ats_lab_aux_major_21: do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_18, arg2, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_18, arg2, atslab_1) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_18, arg2, atslab_4) ; tmp185 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp182), atslab_hiclau_pat) ; tmp184 = hipatlst_prefix_test_int_20 (arg0, arg1, tmp185) ; if (tmp184) { tmp186.atslab_0 = tmp181 ; tmp186.atslab_1 = tmp182 ; tmp180 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ats_selptrset_mac(anairiats_sum_19, tmp180, atslab_0, tmp186) ; } else { arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp183 ; goto __ats_lab_aux_major_21 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: tmp180 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp180) ; } /* end of [aux_major_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 14328(line=488, offs=7) -- 14709(line=496, offs=6) */ ATSstaticdec() ats_int_type f_23 (ats_int_type env0, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_bool_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_bool_type, tmp194) ; ATSlocal (ats_int_type, tmp195) ; __ats_lab_f_23: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp189 = atspre_lt_int_int (arg0, env0) ; if (!tmp189) { goto __ats_lab_98_1 ; } do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_97_1 ; } __ats_lab_96_2: tmp190 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp193 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; tmp194 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__hipat_test_sub (tmp190, tmp192) ; if (tmp194) { tmp195 = atspre_add_int_int (arg0, 1) ; arg0 = tmp195 ; arg1 = tmp191 ; arg2 = tmp193 ; goto __ats_lab_f_23 ; // tail call } else { tmp188 = arg0 ; } /* end of [if] */ break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: __ats_lab_97_2: tmp188 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: __ats_lab_98_1: tmp188 = arg0 ; break ; } while (0) ; return (tmp188) ; } /* end of [f_23] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } f_23_closure_type ; ats_int_type f_23_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return f_23 (((f_23_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type f_23_closure_init (f_23_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_23_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_23_closure_make (ats_int_type env0) { f_23_closure_type *p_clo = ATS_MALLOC(sizeof(f_23_closure_type)) ; f_23_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 14255(line=485, offs=5) -- 14765(line=499, offs=4) */ ATSstaticdec() ats_int_type aux_minor_22 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp187) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_aux_minor_22: tmp196 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg2), atslab_hiclau_pat) ; tmp187 = f_23 (arg0, 0, arg1, tmp196) ; return (tmp187) ; } /* end of [aux_minor_22] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 14875(line=505, offs=7) -- 16125(line=535, offs=6) */ ATSstaticdec() ats_void_type auxpat_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_bool_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_auxpat_25: tmp199 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hipat_node) ; tmp200 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_hipat_node) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp199)->tag != 0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: __ats_lab_99_2: tmp201 = ats_caselptrlab_mac(anairiats_sum_11, tmp199, atslab_0) ; arg0 = tmp201 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_auxpat_25 ; // tail call break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: if (((ats_sum_ptr_type)tmp200)->tag != 0) { goto __ats_lab_101_0 ; } __ats_lab_100_2: tmp202 = ats_caselptrlab_mac(anairiats_sum_11, tmp200, atslab_0) ; arg0 = arg0 ; arg1 = tmp202 ; arg2 = arg2 ; goto __ats_lab_auxpat_25 ; // tail call break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp199)->tag != 5) { goto __ats_lab_108_0 ; } __ats_lab_101_1: if (((ats_sum_ptr_type)tmp200)->tag != 5) { goto __ats_lab_109_1 ; } __ats_lab_101_2: tmp203 = ats_caselptrlab_mac(anairiats_sum_15, tmp199, atslab_1) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_15, tmp199, atslab_2) ; tmp205 = ats_caselptrlab_mac(anairiats_sum_15, tmp200, atslab_1) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_15, tmp200, atslab_2) ; tmp207 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp203, tmp205) ; if (tmp207) { tmp208 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hipat_asvar) ; tmp209 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_hipat_asvar) ; do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (tmp208 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_102_1: if (tmp209 == (ats_sum_ptr_type)0) { goto __ats_lab_107_1 ; } __ats_lab_102_2: tmp211 = ats_caselptrlab_mac(anairiats_sum_9, tmp208, atslab_0) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_9, tmp209, atslab_0) ; tmp213 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (tmp211) ; tmp214 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp213), atslab_valprim_node) ; do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp214)->tag != 22) { goto __ats_lab_106_0 ; } __ats_lab_103_1: tmp215 = ats_caselptrlab_mac(anairiats_sum_4, tmp214, atslab_0) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_dynctx_find (tmp212) ; tmp217 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp216), atslab_valprim_node) ; do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp217)->tag != 22) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_4, tmp217, atslab_0) ; tmp219 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp219, atslab_0, tmp215) ; ats_selptrset_mac(anairiats_sum_5, tmp219, atslab_1, tmp218) ; ats_selptrset_mac(anairiats_sum_5, tmp219, atslab_2, ats_ptrget_mac(ats_ptr_type, arg2)) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp219 ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: __ats_lab_105_1: break ; } while (0) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: __ats_lab_107_1: __ats_lab_107_2: break ; } while (0) ; /* tmp198 = */ auxpatlst_26 (tmp204, tmp206, arg2) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)tmp199)->tag != 11) { goto __ats_lab_109_0 ; } __ats_lab_108_1: if (((ats_sum_ptr_type)tmp200)->tag != 11) { goto __ats_lab_109_1 ; } __ats_lab_108_2: tmp220 = ats_caselptrlab_mac(anairiats_sum_12, tmp199, atslab_1) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_12, tmp200, atslab_1) ; /* tmp198 = */ auxlabpatlst_27 (tmp220, tmp221, arg2) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: __ats_lab_109_2: break ; } while (0) ; return /* (tmp198) */ ; } /* end of [auxpat_25] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 16154(line=537, offs=7) -- 16427(line=545, offs=6) */ ATSstaticdec() ats_void_type auxpatlst_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; // ATSlocal_void (tmp227) ; __ats_lab_auxpatlst_26: do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_111_1 ; } __ats_lab_110_2: tmp223 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp225 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp226 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; /* tmp227 = */ auxpat_25 (tmp223, tmp225, arg2) ; arg0 = tmp224 ; arg1 = tmp226 ; arg2 = arg2 ; goto __ats_lab_auxpatlst_26 ; // tail call break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: __ats_lab_111_1: __ats_lab_111_2: break ; } while (0) ; return /* (tmp222) */ ; } /* end of [auxpatlst_26] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 16459(line=547, offs=7) -- 16855(line=557, offs=6) */ ATSstaticdec() ats_void_type auxlabpatlst_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; __ats_lab_auxlabpatlst_27: do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_113_1 ; } __ats_lab_112_2: tmp229 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_2) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_1) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_17, arg1, atslab_2) ; /* tmp233 = */ auxpat_25 (tmp229, tmp231, arg2) ; arg0 = tmp230 ; arg1 = tmp232 ; arg2 = arg2 ; goto __ats_lab_auxlabpatlst_27 ; // tail call break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: __ats_lab_113_2: break ; } while (0) ; return /* (tmp228) */ ; } /* end of [auxlabpatlst_27] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 16890(line=559, offs=7) -- 17374(line=575, offs=6) */ ATSstaticdec() ats_void_type auxpatlst_prefix_28 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp234) ; ATSlocal (ats_bool_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; // ATSlocal_void (tmp240) ; ATSlocal (ats_int_type, tmp241) ; __ats_lab_auxpatlst_prefix_28: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp235 = atspre_gt_int_int (arg0, 0) ; if (!tmp235) { goto __ats_lab_117_1 ; } do { /* branch: __ats_lab_115 */ __ats_lab_115_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_116_0 ; } __ats_lab_115_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_116_1 ; } __ats_lab_115_2: tmp236 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp238 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp239 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; /* tmp240 = */ auxpat_25 (tmp236, tmp238, arg3) ; tmp241 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp241 ; arg1 = tmp237 ; arg2 = tmp239 ; arg3 = arg3 ; goto __ats_lab_auxpatlst_prefix_28 ; // tail call break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: __ats_lab_116_1: __ats_lab_116_2: break ; } while (0) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: __ats_lab_117_1: break ; } while (0) ; return /* (tmp234) */ ; } /* end of [auxpatlst_prefix_28] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 17568(line=580, offs=9) -- 17813(line=586, offs=30) */ ATSstaticdec() ats_ptr_type auxrev_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; __ats_lab_auxrev_29: do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp247 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_2) ; tmp249 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp249, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_5, tmp249, atslab_1, tmp247) ; ats_selptrset_mac(anairiats_sum_5, tmp249, atslab_2, arg1) ; arg0 = tmp248 ; arg1 = tmp249 ; goto __ats_lab_auxrev_29 ; // tail call break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: tmp245 = arg1 ; break ; } while (0) ; return (tmp245) ; } /* end of [auxrev_29] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 14793(line=501, offs=5) -- 17896(line=592, offs=4) */ ATSstaticdec() ats_ptr_type aux_tmpmov_24 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp242) ; // ATSlocal_void (tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_aux_tmpmov_24: /* ats_ptr_type tmp242 ; */ tmp242 = (ats_sum_ptr_type)0 ; tmp244 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg2), atslab_hiclau_pat) ; /* tmp243 = */ auxpatlst_prefix_28 (arg0, arg1, tmp244, (&tmp242)) ; tmp250 = (ats_sum_ptr_type)0 ; tmp197 = auxrev_29 (tmp242, tmp250) ; return (tmp197) ; } /* end of [aux_tmpmov_24] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 18063(line=598, offs=10) -- 18778(line=617, offs=10) */ ATSstaticdec() ats_void_type aux_31 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (anairiats_rec_1, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_int_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; __ats_lab_aux_31: tmp257 = aux_major_21 (arg0, arg1, env1) ; do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (tmp257 == (ats_sum_ptr_type)0) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_19, tmp257, atslab_0) ; ATS_FREE(tmp257) ; tmp259 = ats_select_mac(tmp258, atslab_0) ; tmp260 = ats_select_mac(tmp258, atslab_1) ; tmp261 = aux_minor_22 (arg0, arg1, tmp260) ; tmp262 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp262)->tag = 2 ; ats_selptrset_mac(anairiats_sum_21, tmp262, atslab_0, tmp259) ; ats_selptrset_mac(anairiats_sum_21, tmp262, atslab_1, tmp261) ; /* tmp263 = */ atsopt_matpnt_set_kont (arg2, tmp262) ; tmp264 = aux_tmpmov_24 (tmp261, arg1, tmp260) ; /* tmp256 = */ atsopt_matpnt_set_tmpmovlst (arg2, tmp264) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: // if (tmp257 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_122_1: /* tmp256 = */ atsopt_matpnt_set_kont (arg2, env0) ; break ; } while (0) ; return /* (tmp256) */ ; } /* end of [aux_31] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_31_closure_type ; ats_void_type aux_31_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { aux_31 (((aux_31_closure_type*)cloptr)->closure_env_0, ((aux_31_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_31_closure_init (aux_31_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_31_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_31_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_31_closure_type *p_clo = ATS_MALLOC(sizeof(aux_31_closure_type)) ; aux_31_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 18808(line=619, offs=11) -- 19105(line=628, offs=10) */ ATSstaticdec() ats_int_type auxlst_32 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; // ATSlocal_void (tmp268) ; ATSlocal (ats_int_type, tmp269) ; __ats_lab_auxlst_32: do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp267 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; /* tmp268 = */ aux_31 (env0, env1, arg0, arg1, tmp266) ; tmp269 = atspre_add_int_int (arg0, 1) ; arg0 = tmp269 ; arg1 = arg1 ; arg2 = tmp267 ; goto __ats_lab_auxlst_32 ; // tail call break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_124_1: tmp265 = arg0 ; break ; } while (0) ; return (tmp265) ; } /* end of [auxlst_32] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxlst_32_closure_type ; ats_int_type auxlst_32_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return auxlst_32 (((auxlst_32_closure_type*)cloptr)->closure_env_0, ((auxlst_32_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type auxlst_32_closure_init (auxlst_32_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_32_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_32_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxlst_32_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_32_closure_type)) ; auxlst_32_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 19137(line=630, offs=10) -- 19330(line=636, offs=10) */ ATSstaticdec() ats_void_type auxopt_33 (ats_ptr_type env0, ats_ptr_type env1, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; __ats_lab_auxopt_33: do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp271 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_0) ; /* tmp270 = */ aux_31 (env0, env1, arg0, arg1, tmp271) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: break ; } while (0) ; return /* (tmp270) */ ; } /* end of [auxopt_33] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } auxopt_33_closure_type ; ats_void_type auxopt_33_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { auxopt_33 (((auxopt_33_closure_type*)cloptr)->closure_env_0, ((auxopt_33_closure_type*)cloptr)->closure_env_1, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type auxopt_33_closure_init (auxopt_33_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&auxopt_33_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type auxopt_33_closure_make (ats_ptr_type env0, ats_ptr_type env1) { auxopt_33_closure_type *p_clo = ATS_MALLOC(sizeof(auxopt_33_closure_type)) ; auxopt_33_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 17925(line=594, offs=5) -- 19623(line=646, offs=4) */ ATSstaticdec() ats_void_type matpnt_set_kont_all_30 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_int_type, tmp273) ; // ATSlocal_void (tmp274) ; __ats_lab_matpnt_set_kont_all_30: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_120_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_1) ; tmp253 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_2) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_3) ; tmp255 = ats_caselptrlab_mac(anairiats_sum_18, arg0, atslab_4) ; tmp272 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp252), atslab_hiclau_pat) ; tmp273 = auxlst_32 (arg1, tmp255, 0, tmp272, tmp253) ; /* tmp274 = */ auxopt_33 (arg1, tmp255, tmp273, tmp272, tmp254) ; arg0 = tmp255 ; arg1 = arg1 ; goto __ats_lab_matpnt_set_kont_all_30 ; // tail call break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: break ; } while (0) ; return /* (tmp251) */ ; } /* end of [matpnt_set_kont_all_30] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 19766(line=655, offs=7) -- 20219(line=671, offs=6) */ ATSstaticdec() ats_ptr_type auxlst_35 (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (anairiats_rec_1, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_auxlst_35: do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp277 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp278 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp279 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make () ; tmp281 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp277), atslab_hiclau_loc) ; tmp280 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__ccomp_hiclau (tmp281, env0, arg0, tmp279, env1, tmp277, env2) ; tmp282 = auxlst_35 (env0, env1, env2, arg0, tmp278) ; tmp283 = ats_select_mac(tmp280, atslab_0) ; tmp284 = ats_select_mac(tmp280, atslab_1) ; tmp276 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ats_selptrset_mac(anairiats_sum_18, tmp276, atslab_0, tmp279) ; ats_selptrset_mac(anairiats_sum_18, tmp276, atslab_1, tmp277) ; ats_selptrset_mac(anairiats_sum_18, tmp276, atslab_2, tmp283) ; ats_selptrset_mac(anairiats_sum_18, tmp276, atslab_3, tmp284) ; ats_selptrset_mac(anairiats_sum_18, tmp276, atslab_4, tmp282) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp276 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp276) ; } /* end of [auxlst_35] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } auxlst_35_closure_type ; ats_ptr_type auxlst_35_clofun (ats_clo_ptr_type cloptr, ats_ref_type arg0, ats_ptr_type arg1) { return auxlst_35 (((auxlst_35_closure_type*)cloptr)->closure_env_0, ((auxlst_35_closure_type*)cloptr)->closure_env_1, ((auxlst_35_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type auxlst_35_closure_init (auxlst_35_closure_type *p_clo, ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_35_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_35_closure_make (ats_int_type env0, ats_ptr_type env1, ats_ptr_type env2) { auxlst_35_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_35_closure_type)) ; auxlst_35_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_clau.dats: 19704(line=651, offs=17) -- 20433(line=679, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; // ATSlocal_void (tmp287) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst: /* ats_ptr_type tmp285 ; */ tmp285 = (ats_sum_ptr_type)0 ; tmp286 = auxlst_35 (arg0, arg1, arg3, (&tmp285), arg2) ; /* tmp287 = */ matpnt_set_kont_all_30 (tmp286, arg4) ; tmp275 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp285) ; return (tmp275) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_hiclaulst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__TMPMOVLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__L0STnil_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_clau_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_matpnt_set_kont (ats_ptr_type mpt, ats_ptr_type kont) { ((matpnt_t)mpt)->atslab_matpnt_kont = kont ; return ; } // end of [atsopt_matpnt_set_kont] ats_void_type atsopt_matpnt_set_tmpmovlst (ats_ptr_type mpt, ats_ptr_type tmpmovlst) { ((matpnt_t)mpt)->atslab_matpnt_tmpmovlst = tmpmovlst ; return ; } // end of [atsopt_matpnt_set_tmpmovlst] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_trans_clau_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_dvar_dats.c0000664000175000017500000037417412223166160022544 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_d2var_loc ; ats_ptr_type atslab_d2var_sym ; ats_int_type atslab_d2var_lev ; ats_int_type atslab_d2var_lin ; ats_bool_type atslab_d2var_isfix ; ats_bool_type atslab_d2var_isprf ; ats_ptr_type atslab_d2var_decarg ; ats_ptr_type atslab_d2var_addr ; ats_ptr_type atslab_d2var_view ; ats_ptr_type atslab_d2var_fin ; ats_ptr_type atslab_d2var_typ ; ats_ptr_type atslab_d2var_mastyp ; ats_int_type atslab_d2var_count ; atsopt_count_type atslab_d2var_stamp ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Bl_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Br_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2var_stamp_make) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_del) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_dels) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__d2varset_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__d2var_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil) ; /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_int_type _compare_d2var_d2var_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type cmp_53 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pr_55 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type avl_foreach_03592_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type set_foreach_main_03586_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_d2varset_ptr_54 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type avl_height_03589_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type avl_rotate_l_03593_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_rotate_r_03594_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_insert_br_03596_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_insert_03595_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_insert_03582_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_takeout_min_03597_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type avl_remove_03609_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_remove_03583_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type __ats_fun_76 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_76_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_int_type __ats_fun_76_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type avl_join_r_03599_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_join_l_03598_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type avl_split_br_03602_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_int_type avl_split_03601_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type avl_union_br_03608_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_union_03607_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_union_03585_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type avl_member_03590_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type set_member_03581_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type app_87 (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; static ats_void_type set_foreach_cloptr_03587_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 2003(line=63, offs=4) -- 2088(line=64, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 2143(line=69, offs=4) -- 2212(line=70, offs=44) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_dynexp2_dvar)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 2216(line=71, offs=4) -- 2336(line=73, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_dynexp2_dvar)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 3034(line=102, offs=22) -- 3673(line=131, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (atsopt_count_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2var_stamp_make () ; tmp7 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp8 = ats_selsin_mac(tmp7, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_sym) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_lev) = -1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_lin) = -1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_isfix) = ats_false_bool ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_isprf) = ats_false_bool ; tmp9 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_decarg) = tmp9 ; tmp10 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_addr) = tmp10 ; tmp11 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_view) = tmp11 ; tmp12 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_fin) = tmp12 ; tmp13 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_typ) = tmp13 ; tmp14 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_mastyp) = tmp14 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_count) = 0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp8), atslab_d2var_stamp) = tmp6 ; /* tmp15 = */ atspre_vbox_make_view_ptr (tmp8) ; /* tmp16 = ats_selsin_mac(tmp15, atslab_1) */ ; tmp5 = tmp8 ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 3723(line=134, offs=16) -- 3783(line=136, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any: tmp17 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make_any] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 3857(line=140, offs=25) -- 3914(line=141, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc: tmp19 = ats_selsin_mac(arg0, atslab_1) ; tmp18 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp19), atslab_d2var_loc) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 3940(line=143, offs=25) -- 3997(line=144, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym: tmp21 = ats_selsin_mac(arg0, atslab_1) ; tmp20 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp21), atslab_d2var_sym) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4025(line=146, offs=27) -- 4084(line=147, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix: tmp23 = ats_selsin_mac(arg0, atslab_1) ; tmp22 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp23), atslab_d2var_isfix) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isfix] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4112(line=149, offs=27) -- 4187(line=150, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ // ATSlocal_void (tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix: tmp25 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp25), atslab_d2var_isfix) = arg1 ; return /* (tmp24) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isfix] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4215(line=152, offs=27) -- 4274(line=153, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf: tmp27 = ats_selsin_mac(arg0, atslab_1) ; tmp26 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp27), atslab_d2var_isprf) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4302(line=155, offs=27) -- 4377(line=156, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ // ATSlocal_void (tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf: tmp29 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp29), atslab_d2var_isprf) = arg1 ; return /* (tmp28) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_isprf] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4403(line=158, offs=25) -- 4460(line=159, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev: tmp31 = ats_selsin_mac(arg0, atslab_1) ; tmp30 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp31), atslab_d2var_lev) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lev] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4486(line=161, offs=25) -- 4555(line=162, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev: tmp33 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp33), atslab_d2var_lev) = arg1 ; return /* (tmp32) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lev] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4581(line=164, offs=25) -- 4638(line=165, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin: tmp35 = ats_selsin_mac(arg0, atslab_1) ; tmp34 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp35), atslab_d2var_lin) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4664(line=167, offs=25) -- 4741(line=168, offs=70) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin: tmp37 = ats_selsin_mac(arg0, atslab_1) ; tmp39 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp37), atslab_d2var_lin) ; tmp38 = atspre_add_int_int (1, tmp39) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp37), atslab_d2var_lin) = tmp38 ; return /* (tmp36) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4767(line=170, offs=25) -- 4836(line=171, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin: tmp41 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp41), atslab_d2var_lin) = arg1 ; return /* (tmp40) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4865(line=173, offs=28) -- 4925(line=174, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg: tmp43 = ats_selsin_mac(arg0, atslab_1) ; tmp42 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp43), atslab_d2var_decarg) ; return (tmp42) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 4954(line=176, offs=28) -- 5032(line=177, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_decarg (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_decarg: tmp45 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp45), atslab_d2var_decarg) = arg1 ; return /* (tmp44) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_decarg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5059(line=179, offs=26) -- 5117(line=180, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr: tmp47 = ats_selsin_mac(arg0, atslab_1) ; tmp46 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp47), atslab_d2var_addr) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5144(line=182, offs=26) -- 5226(line=183, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr: tmp49 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_d2var_addr) = arg1 ; return /* (tmp48) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5253(line=185, offs=26) -- 5311(line=186, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view: tmp51 = ats_selsin_mac(arg0, atslab_1) ; tmp50 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp51), atslab_d2var_view) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5338(line=188, offs=26) -- 5420(line=189, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view: tmp53 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp53), atslab_d2var_view) = arg1 ; return /* (tmp52) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_view] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5446(line=191, offs=25) -- 5503(line=192, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin: tmp55 = ats_selsin_mac(arg0, atslab_1) ; tmp54 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp55), atslab_d2var_fin) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5529(line=194, offs=25) -- 5598(line=195, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin: tmp57 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp57), atslab_d2var_fin) = arg1 ; return /* (tmp56) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5624(line=197, offs=25) -- 5681(line=198, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ: tmp59 = ats_selsin_mac(arg0, atslab_1) ; tmp58 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp59), atslab_d2var_typ) ; return (tmp58) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5707(line=200, offs=25) -- 5778(line=201, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ: tmp61 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp61), atslab_d2var_typ) = arg1 ; return /* (tmp60) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5807(line=203, offs=28) -- 5867(line=204, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp: tmp63 = ats_selsin_mac(arg0, atslab_1) ; tmp62 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp63), atslab_d2var_mastyp) ; return (tmp62) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5896(line=206, offs=28) -- 5970(line=207, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp: tmp65 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp65), atslab_d2var_mastyp) = arg1 ; return /* (tmp64) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 5998(line=209, offs=27) -- 6057(line=210, offs=52) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count: tmp67 = ats_selsin_mac(arg0, atslab_1) ; tmp66 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp67), atslab_d2var_count) ; return (tmp66) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_count] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6113(line=213, offs=27) -- 6207(line=216, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_int_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count: tmp69 = ats_selsin_mac(arg0, atslab_1) ; tmp70 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp69), atslab_d2var_count) ; tmp71 = atspre_add_int_int (tmp70, 1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp69), atslab_d2var_count) = tmp71 ; return /* (tmp68) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6266(line=218, offs=27) -- 6325(line=219, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp: tmp73 = ats_selsin_mac(arg0, atslab_1) ; tmp72 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp73), atslab_d2var_stamp) ; return (tmp72) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6403(line=225, offs=3) -- 6454(line=225, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2var_d2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2var_d2var: tmp75 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (arg0, arg1) ; tmp74 = atspre_ilt (tmp75, 0) ; return (tmp74) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lt_d2var_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6483(line=227, offs=3) -- 6535(line=227, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2var_d2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2var_d2var: tmp77 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (arg0, arg1) ; tmp76 = atspre_ilte (tmp77, 0) ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__lte_d2var_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6564(line=230, offs=3) -- 6615(line=230, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp78) ; ATSlocal (ats_int_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var: tmp79 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (arg0, arg1) ; tmp78 = atspre_ieq (tmp79, 0) ; return (tmp78) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6644(line=232, offs=3) -- 6696(line=232, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2var_d2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2var_d2var: tmp81 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (arg0, arg1) ; tmp80 = atspre_ineq (tmp81, 0) ; return (tmp80) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__neq_d2var_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 6701(line=234, offs=4) -- 7003(line=245, offs=4) */ ATSstaticdec() ats_int_type _compare_d2var_d2var_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (atsopt_count_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (atsopt_count_type, tmp86) ; __ats_lab__compare_d2var_d2var_35: tmp83 = ats_selsin_mac(arg0, atslab_1) ; tmp84 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp83), atslab_d2var_stamp) ; tmp85 = ats_selsin_mac(arg1, atslab_1) ; tmp86 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp85), atslab_d2var_stamp) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp84, tmp86) ; return (tmp82) ; } /* end of [_compare_d2var_d2var_35] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 7068(line=247, offs=31) -- 7133(line=248, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var: tmp87 = _compare_d2var_d2var_35 (arg0, arg1) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 7256(line=258, offs=3) -- 7606(line=269, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; // ATSlocal_void (tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg1) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp89 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_1, tmp89, atslab_0) ; tmp88 = tmp90 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp89 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: /* tmp91 = */ prerr_loc_error3_0 (arg0) ; /* tmp92 = */ atspre_prerr_string (ATSstrcst(": there is no type for the dynamic variable [")) ; /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp94 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp95 = */ atspre_prerr_newline () ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp88) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 7673(line=273, offs=3) -- 8033(line=284, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp_some: tmp97 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (arg1) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp97 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_1, tmp97, atslab_0) ; tmp96 = tmp98 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp97 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: /* tmp99 = */ prerr_loc_error3_0 (arg0) ; /* tmp100 = */ atspre_prerr_string (ATSstrcst(": there is no master type for the dynamic variable [")) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp102 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp103 = */ atspre_prerr_newline () ; /* tmp96 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp96) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp_some] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 8122(line=290, offs=3) -- 8523(line=302, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some: tmp105 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr (arg1) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp105 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_1, tmp105, atslab_0) ; tmp104 = tmp106 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp105 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: /* tmp107 = */ prerr_loc_interror_2 (arg0) ; /* tmp108 = */ atspre_prerr_string (ATSstrcst(": d2var_get_addr_some: ")) ; /* tmp109 = */ atspre_prerr_string (ATSstrcst(": there is no address for the dynamic variable [")) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp111 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp112 = */ atspre_prerr_newline () ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 8589(line=306, offs=3) -- 9033(line=319, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some: tmp114 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (arg1) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp114 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_1, tmp114, atslab_0) ; tmp113 = tmp115 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp114 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp116 = */ prerr_loc_interror_2 (arg0) ; /* tmp117 = */ atspre_prerr_string (ATSstrcst(": d2var_view_get_some: ")) ; /* tmp118 = */ atspre_prerr_string (ATSstrcst(": there is no view attached to the dynamic variable [")) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp120 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp121 = */ atspre_prerr_newline () ; /* tmp113 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp113) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9111(line=324, offs=14) -- 9383(line=333, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var: tmp123 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg1) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp123) ; return /* (tmp122) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9432(line=335, offs=23) -- 9469(line=335, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2var: tmp125 = atspre_stdout_get () ; tmp126 = ats_selsin_mac(tmp125, atslab_1) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (tmp126, arg0) ; /* tmp124 = */ atspre_stdout_view_set () ; return /* (tmp124) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9492(line=336, offs=23) -- 9529(line=336, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var: tmp129 = atspre_stderr_get () ; tmp130 = ats_selsin_mac(tmp129, atslab_1) ; /* tmp131 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (tmp130, arg0) ; /* tmp128 = */ atspre_stderr_view_set () ; return /* (tmp128) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9578(line=341, offs=17) -- 9646(line=342, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst: /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) ; return /* (tmp132) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9701(line=346, offs=16) -- 9743(line=346, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; // ATSlocal_void (tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varlst: tmp134 = atspre_stdout_get () ; tmp135 = ats_selsin_mac(tmp134, atslab_1) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst (tmp135, arg0) ; /* tmp133 = */ atspre_stdout_view_set () ; return /* (tmp133) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9769(line=348, offs=16) -- 9811(line=348, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varlst: tmp138 = atspre_stderr_get () ; tmp139 = ats_selsin_mac(tmp138, atslab_1) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varlst (tmp139, arg0) ; /* tmp137 = */ atspre_stderr_view_set () ; return /* (tmp137) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9860(line=352, offs=27) -- 9891(line=352, offs=58) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp141) ; ATSlocal (ats_int_type, tmp142) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear: tmp142 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (arg0) ; tmp141 = atspre_gte_int_int (tmp142, 0) ; return (tmp141) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 9920(line=353, offs=28) -- 10007(line=354, offs=80) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable: tmp144 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (arg0) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp144 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp143 = ats_true_bool ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp144 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp143 = ats_false_bool ; break ; } while (0) ; return (tmp143) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 10085(line=360, offs=17) -- 10169(line=362, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ: /* tmp146 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin (arg0) ; tmp147 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp147, atslab_0, arg1) ; /* tmp145 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg0, tmp147) ; return /* (tmp145) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 10228(line=365, offs=20) -- 10565(line=376, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_bool_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; // ATSlocal_void (tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at: tmp149 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp151 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, tmp149), atslab_s2exp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp151)->tag != 17) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp150 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp152 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype, tmp149) ; if (!tmp152) { goto __ats_lab_12_1 ; } tmp150 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp153 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (tmp149, arg2) ; tmp150 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp150, atslab_0, tmp153) ; break ; } while (0) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin (arg0) ; /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg0, tmp150) ; return /* (tmp148) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 10629(line=380, offs=3) -- 11110(line=393, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make: tmp156 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_loc (arg0) ; tmp157 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp158 = tmp159 ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp162 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp157) ; tmp161 = atspre_string_append (tmp162, ATSstrcst(".view")) ; tmp160 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (tmp161) ; tmp158 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_make (tmp156, tmp160) ; break ; } while (0) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (tmp158, 0) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr (arg0) ; /* tmp164 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_addr (tmp158, tmp165) ; tmp155 = tmp158 ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 11183(line=396, offs=28) -- 11245(line=397, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none: tmp167 = (ats_sum_ptr_type)0 ; tmp166 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make (arg0, tmp167) ; return (tmp166) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_ptr_viewat_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 11476(line=412, offs=4) -- 11565(line=415, offs=38) */ ATSstaticdec() ats_int_type cmp_53 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp168) ; __ats_lab_cmp_53: tmp168 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__compare_d2var_d2var (arg0, arg1) ; return (tmp168) ; } /* end of [cmp_53] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 11887(line=432, offs=6) -- 12172(line=440, offs=6) */ ATSstaticdec() ats_void_type pr_55 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_int_type, tmp173) ; // ATSlocal_void (tmp174) ; ATSlocal (ats_bool_type, tmp175) ; ATSlocal (ats_int_type, tmp176) ; __ats_lab_pr_55: tmp172 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_0) ; tmp173 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_1) ; tmp175 = atspre_gt_int_int (tmp173, 0) ; if (tmp175) { /* tmp174 = */ atspre_fprint_string (tmp172, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp176 = atspre_add_int_int (tmp173, 1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_1) = tmp176 ; /* tmp171 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (tmp172, arg0) ; return /* (tmp171) */ ; } /* end of [pr_55] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 3823(line=113, offs=26) -- 4145(line=121, offs=4) */ ATSstaticdec() ats_void_type avl_foreach_03592_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; __ats_lab_avl_foreach_03592_ats_ptr_type: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp180 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; /* tmp182 = */ avl_foreach_03592_ats_ptr_type (tmp180, arg1, arg2) ; /* tmp183 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp179, arg2) ; arg0 = tmp181 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_03592_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp184 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; /* tmp187 = */ avl_foreach_03592_ats_ptr_type (tmp185, arg1, arg2) ; /* tmp188 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp184, arg2) ; arg0 = tmp186 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_03592_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: break ; } while (0) ; return /* (tmp178) */ ; } /* end of [avl_foreach_03592_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18713(line=552, offs=31) -- 18767(line=553, offs=35) */ ATSstaticdec() ats_void_type set_foreach_main_03586_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp177) ; __ats_lab_set_foreach_main_03586_ats_ptr_type: /* tmp177 = */ avl_foreach_03592_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp177) */ ; } /* end of [set_foreach_main_03586_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 11586(line=418, offs=4) -- 12351(line=448, offs=4) */ ATSstaticdec() ats_void_type fprint_d2varset_ptr_54 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp169) ; ATSlocal (anairiats_rec_3, tmp170) ; __ats_lab_fprint_d2varset_ptr_54: /* anairiats_rec_3 tmp170 ; */ ats_select_mac(tmp170, atslab_0) = arg0 ; ats_select_mac(tmp170, atslab_1) = 0 ; /* tmp169 = */ set_foreach_main_03586_ats_ptr_type (arg1, &pr_55, (&tmp170)) ; return /* (tmp169) */ ; } /* end of [fprint_d2varset_ptr_54] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 12432(line=453, offs=17) -- 12500(line=454, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset: /* tmp189 = */ fprint_d2varset_ptr_54 (arg0, arg1) ; return /* (tmp189) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2500(line=68, offs=25) -- 2576(line=69, offs=60) */ ATSstaticdec() ats_int_type avl_height_03589_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp204) ; ATSlocal (ats_int_type, tmp205) ; ATSlocal (ats_int_type, tmp206) ; __ats_lab_avl_height_03589_ats_ptr_type: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp204 = 0 ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp204 = tmp205 ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp206 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp204 = tmp206 ; break ; } while (0) ; return (tmp204) ; } /* end of [avl_height_03589_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 4346(line=128, offs=27) -- 5013(line=147, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_l_03593_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_int_type, tmp217) ; ATSlocal (ats_int_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_int_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_int_type, tmp225) ; ATSlocal (ats_int_type, tmp226) ; ATSlocal (ats_bool_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_int_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_int_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_int_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_int_type, tmp241) ; ATSlocal (ats_int_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; __ats_lab_avl_rotate_l_03593_ats_ptr_type: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp216 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_3) ; tmp217 = avl_height_03589_ats_ptr_type (tmp216) ; tmp218 = atspre_iadd (tmp217, 2) ; tmp220 = atspre_iadd (tmp217, 1) ; tmp219 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp219)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp219, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp219, atslab_1, tmp220) ; ats_selptrset_mac(anairiats_sum_4, tmp219, atslab_2, tmp216) ; ats_selptrset_mac(anairiats_sum_4, tmp219, atslab_3, arg2) ; tmp213 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp213)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_0, tmp214) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_1, tmp218) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_2, tmp215) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_3, tmp219) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp222 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp223 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_3) ; tmp225 = avl_height_03589_ats_ptr_type (tmp223) ; tmp226 = avl_height_03589_ats_ptr_type (tmp224) ; tmp227 = atspre_ilt (tmp225, tmp226) ; if (tmp227) { do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp224)->tag != 1) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_2) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_3) ; tmp232 = atspre_iadd (tmp225, 1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp231)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp231, atslab_0, tmp221) ; ats_selptrset_mac(anairiats_sum_4, tmp231, atslab_1, tmp232) ; ats_selptrset_mac(anairiats_sum_4, tmp231, atslab_2, tmp223) ; ats_selptrset_mac(anairiats_sum_4, tmp231, atslab_3, tmp229) ; tmp234 = atspre_isub (tmp222, 1) ; tmp233 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp233)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp233, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp233, atslab_1, tmp234) ; ats_selptrset_mac(anairiats_sum_4, tmp233, atslab_2, tmp230) ; ats_selptrset_mac(anairiats_sum_4, tmp233, atslab_3, arg2) ; tmp213 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp213)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_0, tmp228) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_1, tmp222) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_2, tmp231) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_3, tmp233) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (((ats_sum_ptr_type)tmp224)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp235 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_0) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_2) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_4, tmp224, atslab_3) ; tmp239 = atspre_iadd (tmp225, 1) ; tmp238 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp238)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp238, atslab_0, tmp221) ; ats_selptrset_mac(anairiats_sum_4, tmp238, atslab_1, tmp239) ; ats_selptrset_mac(anairiats_sum_4, tmp238, atslab_2, tmp223) ; ats_selptrset_mac(anairiats_sum_4, tmp238, atslab_3, tmp236) ; tmp241 = atspre_isub (tmp222, 1) ; tmp240 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp240)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp240, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp240, atslab_1, tmp241) ; ats_selptrset_mac(anairiats_sum_4, tmp240, atslab_2, tmp237) ; ats_selptrset_mac(anairiats_sum_4, tmp240, atslab_3, arg2) ; tmp213 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp213)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_0, tmp235) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_1, tmp222) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_2, tmp238) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_3, tmp240) ; break ; } while (0) ; } else { tmp242 = atspre_iadd (tmp226, 2) ; tmp244 = atspre_iadd (tmp226, 1) ; tmp243 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp243)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_1, tmp244) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_2, tmp224) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_3, arg2) ; tmp213 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp213)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_0, tmp221) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_1, tmp242) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_2, tmp223) ; ats_selptrset_mac(anairiats_sum_4, tmp213, atslab_3, tmp243) ; } /* end of [if] */ break ; } while (0) ; return (tmp213) ; } /* end of [avl_rotate_l_03593_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 5194(line=152, offs=27) -- 5846(line=171, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_r_03594_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_int_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; ATSlocal (ats_int_type, tmp260) ; ATSlocal (ats_bool_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_int_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_int_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_int_type, tmp275) ; ATSlocal (ats_int_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_int_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_int_type, tmp282) ; ATSlocal (ats_int_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_int_type, tmp285) ; __ats_lab_avl_rotate_r_03594_ats_ptr_type: do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_30_0 ; } __ats_lab_27_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp257 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_2) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_3) ; tmp259 = avl_height_03589_ats_ptr_type (tmp257) ; tmp260 = avl_height_03589_ats_ptr_type (tmp258) ; tmp261 = atspre_igt (tmp259, tmp260) ; if (tmp261) { do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp257)->tag != 1) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp262 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_0) ; tmp263 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_2) ; tmp264 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_3) ; tmp266 = atspre_isub (tmp256, 1) ; tmp265 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp265)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp265, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp265, atslab_1, tmp266) ; ats_selptrset_mac(anairiats_sum_4, tmp265, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp265, atslab_3, tmp263) ; tmp268 = atspre_iadd (tmp260, 1) ; tmp267 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp267)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp267, atslab_0, tmp255) ; ats_selptrset_mac(anairiats_sum_4, tmp267, atslab_1, tmp268) ; ats_selptrset_mac(anairiats_sum_4, tmp267, atslab_2, tmp264) ; ats_selptrset_mac(anairiats_sum_4, tmp267, atslab_3, tmp258) ; tmp254 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp254)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_0, tmp262) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_1, tmp256) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_2, tmp265) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_3, tmp267) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (((ats_sum_ptr_type)tmp257)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_0) ; tmp270 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_2) ; tmp271 = ats_caselptrlab_mac(anairiats_sum_4, tmp257, atslab_3) ; tmp273 = atspre_isub (tmp256, 1) ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp272)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_1, tmp273) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp272, atslab_3, tmp270) ; tmp275 = atspre_iadd (tmp260, 1) ; tmp274 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp274)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_0, tmp255) ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_1, tmp275) ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_2, tmp271) ; ats_selptrset_mac(anairiats_sum_4, tmp274, atslab_3, tmp258) ; tmp254 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp254)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_0, tmp269) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_1, tmp256) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_2, tmp272) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_3, tmp274) ; break ; } while (0) ; } else { tmp276 = atspre_iadd (tmp259, 2) ; tmp278 = atspre_iadd (tmp259, 1) ; tmp277 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp277)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_1, tmp278) ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_3, tmp257) ; tmp254 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp254)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_0, tmp255) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_1, tmp276) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_2, tmp277) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_3, tmp258) ; } /* end of [if] */ break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp279 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp280 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_2) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_3) ; tmp282 = avl_height_03589_ats_ptr_type (tmp280) ; tmp283 = atspre_iadd (tmp282, 2) ; tmp285 = atspre_iadd (tmp282, 1) ; tmp284 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp284)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp284, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp284, atslab_1, tmp285) ; ats_selptrset_mac(anairiats_sum_4, tmp284, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp284, atslab_3, tmp280) ; tmp254 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp254)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_0, tmp279) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_1, tmp283) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_2, tmp284) ; ats_selptrset_mac(anairiats_sum_4, tmp254, atslab_3, tmp281) ; break ; } while (0) ; return (tmp254) ; } /* end of [avl_rotate_r_03594_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6555(line=191, offs=3) -- 7255(line=213, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_br_03596_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_bool_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_int_type, tmp207) ; ATSlocal (ats_bool_type, tmp208) ; ATSlocal (ats_int_type, tmp209) ; ATSlocal (ats_bool_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; ATSlocal (ats_int_type, tmp212) ; ATSlocal (ats_bool_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_int_type, tmp247) ; ATSlocal (ats_int_type, tmp248) ; ATSlocal (ats_bool_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; ATSlocal (ats_bool_type, tmp251) ; ATSlocal (ats_int_type, tmp252) ; ATSlocal (ats_int_type, tmp253) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_int_type, tmp287) ; ATSlocal (ats_bool_type, tmp288) ; __ats_lab_avl_insert_br_03596_ats_ptr_type: tmp200 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg5) (arg4, arg0) ; tmp201 = atspre_ilt (tmp200, 0) ; if (tmp201) { tmp202 = avl_insert_03595_ats_ptr_type (arg2, arg4, arg5) ; tmp203 = avl_height_03589_ats_ptr_type (tmp202) ; tmp207 = avl_height_03589_ats_ptr_type (arg3) ; tmp208 = atspre_ilte (tmp203, tmp207) ; if (tmp208) { tmp209 = atspre_iadd (tmp207, 1) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, tmp209) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, tmp202) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, arg3) ; } else { tmp211 = atspre_iadd (tmp207, 1) ; tmp210 = atspre_ilte (tmp203, tmp211) ; if (tmp210) { tmp212 = atspre_iadd (tmp203, 1) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, tmp212) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, tmp202) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, arg3) ; } else { tmp199 = avl_rotate_l_03593_ats_ptr_type (arg0, tmp202, arg3) ; } /* end of [if] */ } /* end of [if] */ } else { tmp245 = atspre_igt (tmp200, 0) ; if (tmp245) { tmp246 = avl_insert_03595_ats_ptr_type (arg3, arg4, arg5) ; tmp247 = avl_height_03589_ats_ptr_type (arg2) ; tmp248 = avl_height_03589_ats_ptr_type (tmp246) ; tmp249 = atspre_ilte (tmp248, tmp247) ; if (tmp249) { tmp250 = atspre_iadd (tmp247, 1) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, tmp250) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, tmp246) ; } else { tmp252 = atspre_iadd (tmp247, 1) ; tmp251 = atspre_ilte (tmp248, tmp252) ; if (tmp251) { tmp253 = atspre_iadd (tmp248, 1) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, tmp253) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, tmp246) ; } else { tmp199 = avl_rotate_r_03594_ats_ptr_type (arg0, arg2, tmp246) ; } /* end of [if] */ } /* end of [if] */ } else { tmp286 = avl_height_03589_ats_ptr_type (arg2) ; tmp287 = avl_height_03589_ats_ptr_type (arg3) ; tmp288 = atspre_igte (tmp286, tmp287) ; if (tmp288) { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, arg3) ; } else { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_3, arg3) ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return (tmp199) ; } /* end of [avl_insert_br_03596_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6313(line=184, offs=25) -- 6501(line=188, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_03595_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_int_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_int_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; __ats_lab_avl_insert_03595_ats_ptr_type: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp193 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp194 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp192 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp192)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp192, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp192, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_4, tmp192, atslab_2, tmp193) ; ats_selptrset_mac(anairiats_sum_4, tmp192, atslab_3, tmp194) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_19_1: tmp195 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp196 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp197 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp192 = avl_insert_br_03596_ats_ptr_type (tmp195, tmp196, tmp197, tmp198, arg1, arg2) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp289 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp290 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp292 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp192 = avl_insert_br_03596_ats_ptr_type (tmp289, tmp290, tmp291, tmp292, arg1, arg2) ; break ; } while (0) ; return (tmp192) ; } /* end of [avl_insert_03595_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18425(line=545, offs=25) -- 18463(line=545, offs=63) */ ATSstaticdec() ats_ptr_type set_insert_03582_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp191) ; __ats_lab_set_insert_03582_ats_ptr_type: tmp191 = avl_insert_03595_ats_ptr_type (arg0, arg1, arg2) ; return (tmp191) ; } /* end of [set_insert_03582_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 12613(line=462, offs=14) -- 12657(line=462, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add: tmp190 = set_insert_03582_ats_ptr_type (arg0, arg1, &cmp_53) ; return (tmp190) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 12682(line=464, offs=15) -- 12807(line=466, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp294 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp295 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp296 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add (arg0, tmp294) ; arg0 = tmp296 ; arg1 = tmp295 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp293 = arg0 ; break ; } while (0) ; return (tmp293) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 7445(line=220, offs=30) -- 8191(line=242, offs=4) */ ATSstaticdec() ats_ptr_type avl_takeout_min_03597_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_int_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; ATSlocal (ats_bool_type, tmp325) ; ATSlocal (ats_int_type, tmp326) ; ATSlocal (ats_int_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_int_type, tmp333) ; ATSlocal (ats_bool_type, tmp334) ; ATSlocal (ats_int_type, tmp335) ; ATSlocal (ats_bool_type, tmp336) ; ATSlocal (ats_int_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; __ats_lab_avl_takeout_min_03597_ats_ptr_type: do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_44_0 ; } __ats_lab_41_1: tmp319 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp320 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp321 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp320)->tag != 0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: ats_ptrget_mac(ats_ptr_type, arg1) = tmp319 ; tmp318 = tmp321 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp322 = avl_takeout_min_03597_ats_ptr_type (tmp320, arg1) ; tmp323 = avl_height_03589_ats_ptr_type (tmp322) ; tmp324 = avl_height_03589_ats_ptr_type (tmp321) ; tmp325 = atspre_ilte (tmp324, tmp323) ; if (tmp325) { tmp326 = atspre_iadd (tmp323, 1) ; tmp318 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp318)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_0, tmp319) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_1, tmp326) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_2, tmp322) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_3, tmp321) ; } else { tmp327 = atspre_iadd (tmp324, 1) ; tmp318 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp318)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_0, tmp319) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_1, tmp327) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_2, tmp322) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_3, tmp321) ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp328 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp329 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp329)->tag != 0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: ats_ptrget_mac(ats_ptr_type, arg1) = tmp328 ; tmp318 = tmp330 ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp331 = avl_takeout_min_03597_ats_ptr_type (tmp329, arg1) ; tmp332 = avl_height_03589_ats_ptr_type (tmp331) ; tmp333 = avl_height_03589_ats_ptr_type (tmp330) ; tmp334 = atspre_ilte (tmp333, tmp332) ; if (tmp334) { tmp335 = atspre_iadd (tmp332, 1) ; tmp318 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp318)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_0, tmp328) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_1, tmp335) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_2, tmp331) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_3, tmp330) ; } else { tmp337 = atspre_iadd (tmp332, 1) ; tmp336 = atspre_ilte (tmp333, tmp337) ; if (tmp336) { tmp338 = atspre_iadd (tmp333, 1) ; tmp318 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp318)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_0, tmp328) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_1, tmp338) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_2, tmp331) ; ats_selptrset_mac(anairiats_sum_4, tmp318, atslab_3, tmp330) ; } else { tmp318 = avl_rotate_r_03594_ats_ptr_type (tmp328, tmp331, tmp330) ; } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; return (tmp318) ; } /* end of [avl_takeout_min_03597_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 16506(line=487, offs=25) -- 18188(line=535, offs=4) */ ATSstaticdec() ats_ptr_type avl_remove_03609_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_int_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_int_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_bool_type, tmp307) ; ATSlocal (ats_int_type, tmp308) ; ATSlocal (ats_int_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_int_type, tmp311) ; ATSlocal (ats_int_type, tmp312) ; ATSlocal (ats_bool_type, tmp313) ; ATSlocal (ats_int_type, tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_int_type, tmp339) ; ATSlocal (ats_int_type, tmp340) ; ATSlocal (ats_bool_type, tmp341) ; ATSlocal (ats_int_type, tmp342) ; ATSlocal (ats_int_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_int_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_int_type, tmp349) ; ATSlocal (ats_int_type, tmp350) ; ATSlocal (ats_bool_type, tmp351) ; ATSlocal (ats_int_type, tmp352) ; ATSlocal (ats_int_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_int_type, tmp355) ; ATSlocal (ats_int_type, tmp356) ; ATSlocal (ats_bool_type, tmp357) ; ATSlocal (ats_int_type, tmp358) ; ATSlocal (ats_int_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_int_type, tmp362) ; ATSlocal (ats_int_type, tmp363) ; ATSlocal (ats_bool_type, tmp364) ; ATSlocal (ats_int_type, tmp365) ; ATSlocal (ats_int_type, tmp366) ; __ats_lab_avl_remove_03609_ats_ptr_type: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp299 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_47_0 ; } __ats_lab_35_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp303 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp300) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp303 != -1) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp304 = avl_remove_03609_ats_ptr_type (tmp301, arg1, arg2) ; tmp305 = avl_height_03589_ats_ptr_type (tmp304) ; tmp306 = avl_height_03589_ats_ptr_type (tmp302) ; tmp307 = atspre_ilte (tmp306, tmp305) ; if (tmp307) { tmp308 = atspre_iadd (tmp305, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp300) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp308) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp304) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp302) ; } else { tmp309 = atspre_iadd (tmp306, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp300) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp309) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp304) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp302) ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp303 != 1) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp310 = avl_remove_03609_ats_ptr_type (tmp302, arg1, arg2) ; tmp311 = avl_height_03589_ats_ptr_type (tmp301) ; tmp312 = avl_height_03589_ats_ptr_type (tmp310) ; tmp314 = atspre_iadd (tmp312, 1) ; tmp313 = atspre_ilte (tmp311, tmp314) ; if (tmp313) { tmp315 = atspre_iadd (tmp311, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp300) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp315) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp301) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp310) ; } else { tmp299 = avl_rotate_l_03593_ats_ptr_type (tmp300, tmp301, tmp310) ; } /* end of [if] */ break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (tmp303 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp302)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp299 = tmp301 ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: /* ats_ptr_type tmp316 ; */ tmp317 = avl_takeout_min_03597_ats_ptr_type (tmp302, (&tmp316)) ; tmp339 = avl_height_03589_ats_ptr_type (tmp301) ; tmp340 = avl_height_03589_ats_ptr_type (tmp317) ; tmp342 = atspre_iadd (tmp340, 1) ; tmp341 = atspre_ilte (tmp339, tmp342) ; if (tmp341) { tmp343 = atspre_iadd (tmp339, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp316) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp343) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp301) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp317) ; } else { tmp299 = avl_rotate_l_03593_ats_ptr_type (tmp316, tmp301, tmp317) ; } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp344 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp345 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp347 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp344) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (tmp347 != -1) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp348 = avl_remove_03609_ats_ptr_type (tmp345, arg1, arg2) ; tmp349 = avl_height_03589_ats_ptr_type (tmp348) ; tmp350 = avl_height_03589_ats_ptr_type (tmp346) ; tmp352 = atspre_iadd (tmp349, 1) ; tmp351 = atspre_ilte (tmp350, tmp352) ; if (tmp351) { tmp353 = atspre_iadd (tmp350, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp344) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp353) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp348) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp346) ; } else { tmp299 = avl_rotate_r_03594_ats_ptr_type (tmp344, tmp348, tmp346) ; } /* end of [if] */ break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp347 != 1) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp354 = avl_remove_03609_ats_ptr_type (tmp346, arg1, arg2) ; tmp355 = avl_height_03589_ats_ptr_type (tmp345) ; tmp356 = avl_height_03589_ats_ptr_type (tmp354) ; tmp357 = atspre_ilte (tmp356, tmp355) ; if (tmp357) { tmp358 = atspre_iadd (tmp355, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp344) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp358) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp345) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp354) ; } else { tmp359 = atspre_iadd (tmp356, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp344) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp359) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp345) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp354) ; } /* end of [if] */ break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp347 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp346)->tag != 0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp299 = tmp345 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: /* ats_ptr_type tmp360 ; */ tmp361 = avl_takeout_min_03597_ats_ptr_type (tmp346, (&tmp360)) ; tmp362 = avl_height_03589_ats_ptr_type (tmp345) ; tmp363 = avl_height_03589_ats_ptr_type (tmp361) ; tmp364 = atspre_ilte (tmp363, tmp362) ; if (tmp364) { tmp365 = atspre_iadd (tmp362, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp360) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp365) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp345) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp361) ; } else { tmp366 = atspre_iadd (tmp363, 1) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp299)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_0, tmp360) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_1, tmp366) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_2, tmp345) ; ats_selptrset_mac(anairiats_sum_4, tmp299, atslab_3, tmp361) ; } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; break ; } while (0) ; return (tmp299) ; } /* end of [avl_remove_03609_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18488(line=546, offs=25) -- 18526(line=546, offs=63) */ ATSstaticdec() ats_ptr_type set_remove_03583_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp298) ; __ats_lab_set_remove_03583_ats_ptr_type: tmp298 = avl_remove_03609_ats_ptr_type (arg0, arg1, arg2) ; return (tmp298) ; } /* end of [set_remove_03583_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 12858(line=470, offs=14) -- 12902(line=470, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_del (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp297) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_del: tmp297 = set_remove_03583_ats_ptr_type (arg0, arg1, &cmp_53) ; return (tmp297) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_del] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 12927(line=472, offs=15) -- 13052(line=474, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_dels (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_dels: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp369 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_del (arg0, tmp368) ; arg0 = tmp370 ; arg1 = tmp369 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_dels ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp367 = arg0 ; break ; } while (0) ; return (tmp367) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_dels] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15899(line=469, offs=14) -- 15939(line=469, offs=54) */ ATSstaticdec() ats_int_type __ats_fun_76 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp381) ; __ats_lab___ats_fun_76: tmp381 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))env1) (env0, arg0) ; return (tmp381) ; } /* end of [__ats_fun_76] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } __ats_fun_76_closure_type ; ats_int_type __ats_fun_76_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_76 (((__ats_fun_76_closure_type*)cloptr)->closure_env_0, ((__ats_fun_76_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_76_closure_init (__ats_fun_76_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_76_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_76_closure_make (ats_ptr_type env0, ats_ptr_type env1) { __ats_fun_76_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_76_closure_type)) ; __ats_fun_76_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 9272(line=275, offs=25) -- 9961(line=296, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_r_03599_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_int_type, tmp399) ; ATSlocal (ats_int_type, tmp400) ; ATSlocal (ats_bool_type, tmp401) ; ATSlocal (ats_int_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_int_type, tmp407) ; ATSlocal (ats_int_type, tmp408) ; ATSlocal (ats_bool_type, tmp409) ; ATSlocal (ats_int_type, tmp410) ; ATSlocal (ats_int_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_int_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; ATSlocal (ats_bool_type, tmp418) ; ATSlocal (ats_int_type, tmp419) ; ATSlocal (ats_int_type, tmp420) ; ATSlocal (ats_int_type, tmp421) ; __ats_lab_avl_join_r_03599_ats_ptr_type: tmp399 = avl_height_03589_ats_ptr_type (arg1) ; tmp400 = avl_height_03589_ats_ptr_type (arg2) ; tmp402 = atspre_iadd (tmp399, 1) ; tmp401 = atspre_ilt (tmp402, tmp400) ; if (tmp401) { do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_2) ; tmp405 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_3) ; tmp406 = avl_join_r_03599_ats_ptr_type (arg0, arg1, tmp404) ; tmp407 = avl_height_03589_ats_ptr_type (tmp406) ; tmp408 = avl_height_03589_ats_ptr_type (tmp405) ; tmp410 = atspre_iadd (tmp408, 1) ; tmp409 = atspre_ilte (tmp407, tmp410) ; if (tmp409) { tmp411 = atspre_iadd (tmp407, 1) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp398)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_0, tmp403) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_1, tmp411) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_2, tmp406) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_3, tmp405) ; } else { tmp398 = avl_rotate_l_03593_ats_ptr_type (tmp403, tmp406, tmp405) ; } /* end of [if] */ break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: tmp412 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp413 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_2) ; tmp414 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_3) ; tmp415 = avl_join_r_03599_ats_ptr_type (arg0, arg1, tmp413) ; tmp416 = avl_height_03589_ats_ptr_type (tmp415) ; tmp417 = avl_height_03589_ats_ptr_type (tmp414) ; tmp418 = atspre_ilte (tmp416, tmp417) ; if (tmp418) { tmp419 = atspre_iadd (tmp417, 1) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp398)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_0, tmp412) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_1, tmp419) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_2, tmp415) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_3, tmp414) ; } else { tmp420 = atspre_iadd (tmp416, 1) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp398)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_0, tmp412) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_1, tmp420) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_2, tmp415) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_3, tmp414) ; } /* end of [if] */ break ; } while (0) ; } else { tmp421 = atspre_iadd (tmp400, 1) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp398)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_1, tmp421) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp398, atslab_3, arg2) ; } /* end of [if] */ return (tmp398) ; } /* end of [avl_join_r_03599_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 8402(line=249, offs=25) -- 9087(line=270, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_l_03598_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_int_type, tmp425) ; ATSlocal (ats_int_type, tmp426) ; ATSlocal (ats_bool_type, tmp427) ; ATSlocal (ats_int_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_int_type, tmp433) ; ATSlocal (ats_int_type, tmp434) ; ATSlocal (ats_bool_type, tmp435) ; ATSlocal (ats_int_type, tmp436) ; ATSlocal (ats_int_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_int_type, tmp442) ; ATSlocal (ats_int_type, tmp443) ; ATSlocal (ats_bool_type, tmp444) ; ATSlocal (ats_int_type, tmp445) ; ATSlocal (ats_int_type, tmp446) ; ATSlocal (ats_int_type, tmp447) ; __ats_lab_avl_join_l_03598_ats_ptr_type: tmp425 = avl_height_03589_ats_ptr_type (arg1) ; tmp426 = avl_height_03589_ats_ptr_type (arg2) ; tmp428 = atspre_iadd (tmp426, 1) ; tmp427 = atspre_igt (tmp425, tmp428) ; if (tmp427) { do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp429 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp430 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_3) ; tmp432 = avl_join_l_03598_ats_ptr_type (arg0, tmp431, arg2) ; tmp433 = avl_height_03589_ats_ptr_type (tmp430) ; tmp434 = avl_height_03589_ats_ptr_type (tmp432) ; tmp435 = atspre_ilte (tmp434, tmp433) ; if (tmp435) { tmp436 = atspre_iadd (tmp433, 1) ; tmp424 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp424)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_0, tmp429) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_1, tmp436) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_2, tmp430) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_3, tmp432) ; } else { tmp437 = atspre_iadd (tmp434, 1) ; tmp424 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp424)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_0, tmp429) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_1, tmp437) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_2, tmp430) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_3, tmp432) ; } /* end of [if] */ break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp439 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_2) ; tmp440 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_3) ; tmp441 = avl_join_l_03598_ats_ptr_type (arg0, tmp440, arg2) ; tmp442 = avl_height_03589_ats_ptr_type (tmp439) ; tmp443 = avl_height_03589_ats_ptr_type (tmp441) ; tmp445 = atspre_iadd (tmp442, 1) ; tmp444 = atspre_ilte (tmp443, tmp445) ; if (tmp444) { tmp446 = atspre_iadd (tmp443, 1) ; tmp424 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp424)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_0, tmp438) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_1, tmp446) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_2, tmp439) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_3, tmp441) ; } else { tmp424 = avl_rotate_r_03594_ats_ptr_type (tmp438, tmp439, tmp441) ; } /* end of [if] */ break ; } while (0) ; } else { tmp447 = atspre_iadd (tmp425, 1) ; tmp424 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp424)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_1, tmp447) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp424, atslab_3, arg2) ; } /* end of [if] */ return (tmp424) ; } /* end of [avl_join_l_03598_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11552(line=345, offs=3) -- 12417(line=370, offs=4) */ ATSstaticdec() ats_int_type avl_split_br_03602_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp389) ; ATSlocal (ats_int_type, tmp390) ; ATSlocal (ats_int_type, tmp391) ; ATSlocal (ats_int_type, tmp392) ; ATSlocal (ats_int_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_int_type, tmp395) ; ATSlocal (ats_bool_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_int_type, tmp449) ; ATSlocal (ats_int_type, tmp450) ; ATSlocal (ats_int_type, tmp451) ; ATSlocal (ats_int_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_bool_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; __ats_lab_avl_split_br_03602_ats_ptr_type: tmp390 = ((ats_int_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg4))) (arg4, arg0) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (tmp390 != -1) { goto __ats_lab_64_0 ; } __ats_lab_59_1: tmp391 = avl_split_03601_ats_ptr_type (arg2, arg4, arg5, arg6) ; tmp392 = ats_selsin_mac(tmp391, atslab_2) ; tmp394 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp393 = avl_height_03589_ats_ptr_type (tmp394) ; tmp395 = avl_height_03589_ats_ptr_type (arg3) ; tmp396 = atspre_ilte (tmp393, tmp395) ; if (tmp396) { tmp422 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp397 = avl_join_r_03599_ats_ptr_type (arg0, tmp422, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp397 ; tmp389 = tmp392 ; } else { tmp448 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp423 = avl_join_l_03598_ats_ptr_type (arg0, tmp448, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp423 ; tmp389 = tmp392 ; } /* end of [if] */ break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (tmp390 != 1) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp449 = avl_split_03601_ats_ptr_type (arg3, arg4, arg5, arg6) ; tmp450 = ats_selsin_mac(tmp449, atslab_2) ; tmp451 = avl_height_03589_ats_ptr_type (arg2) ; tmp453 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp452 = avl_height_03589_ats_ptr_type (tmp453) ; tmp454 = atspre_ilte (tmp451, tmp452) ; if (tmp454) { tmp456 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp455 = avl_join_r_03599_ats_ptr_type (arg0, arg2, tmp456) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp455 ; tmp389 = tmp450 ; } else { tmp458 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp457 = avl_join_l_03598_ats_ptr_type (arg0, arg2, tmp458) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp457 ; tmp389 = tmp450 ; } /* end of [if] */ break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: // if (tmp390 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_65_1: ats_ptrget_mac(ats_ptr_type, arg5) = arg2 ; ats_ptrget_mac(ats_ptr_type, arg6) = arg3 ; tmp389 = 1 ; break ; } while (0) ; return (tmp389) ; } /* end of [avl_split_br_03602_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11224(line=336, offs=24) -- 11486(line=341, offs=8) */ ATSstaticdec() ats_int_type avl_split_03601_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_int_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_int_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; __ats_lab_avl_split_03601_ats_ptr_type: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_66_0 ; } __ats_lab_58_1: tmp385 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp387 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp384 = avl_split_br_03602_ats_ptr_type (tmp385, tmp386, tmp387, tmp388, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp459 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp460 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp461 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp384 = avl_split_br_03602_ats_ptr_type (tmp459, tmp460, tmp461, tmp462, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: tmp463 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp463 ; tmp464 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp464 ; tmp384 = 0 ; break ; } while (0) ; return (tmp384) ; } /* end of [avl_split_03601_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15826(line=467, offs=27) -- 16289(line=478, offs=4) */ ATSstaticdec() ats_ptr_type avl_union_br_03608_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_int_type, tmp383) ; ATSlocal (ats_int_type, tmp465) ; // ATSlocal_void (tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_int_type, tmp469) ; ATSlocal (ats_int_type, tmp470) ; ATSlocal (ats_bool_type, tmp471) ; __ats_lab_avl_union_br_03608_ats_ptr_type: /* ats_ptr_type tmp379 ; */ /* ats_ptr_type tmp380 ; */ tmp382 = __ats_fun_76_closure_make (arg0, arg5) ; tmp383 = avl_split_03601_ats_ptr_type (arg4, tmp382, (&tmp379), (&tmp380)) ; tmp465 = ats_selsin_mac(tmp383, atslab_2) ; /* tmp466 = */ atspre_cloptr_free (tmp382) ; tmp467 = avl_union_03607_ats_ptr_type (arg2, tmp379, arg5) ; tmp468 = avl_union_03607_ats_ptr_type (arg3, tmp380, arg5) ; tmp469 = avl_height_03589_ats_ptr_type (tmp467) ; tmp470 = avl_height_03589_ats_ptr_type (tmp468) ; tmp471 = atspre_ilte (tmp469, tmp470) ; if (tmp471) { tmp378 = avl_join_r_03599_ats_ptr_type (arg0, tmp467, tmp468) ; } else { tmp378 = avl_join_l_03598_ats_ptr_type (arg0, tmp467, tmp468) ; } /* end of [if] */ return (tmp378) ; } /* end of [avl_union_br_03608_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15583(line=461, offs=24) -- 15798(line=465, offs=71) */ ATSstaticdec() ats_ptr_type avl_union_03607_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_int_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_int_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; __ats_lab_avl_union_03607_ats_ptr_type: do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: __ats_lab_55_2: tmp373 = arg1 ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_57_0 ; } __ats_lab_56_2: tmp373 = arg0 ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_68_0 ; } __ats_lab_57_1: __ats_lab_57_2: tmp374 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp375 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp376 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp373 = avl_union_br_03608_ats_ptr_type (tmp374, tmp375, tmp376, tmp377, arg1, arg2) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: __ats_lab_68_2: tmp472 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp473 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp474 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp475 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp373 = avl_union_br_03608_ats_ptr_type (tmp472, tmp473, tmp474, tmp475, arg1, arg2) ; break ; } while (0) ; return (tmp373) ; } /* end of [avl_union_03607_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18617(line=548, offs=24) -- 18660(line=548, offs=67) */ ATSstaticdec() ats_ptr_type set_union_03585_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp372) ; __ats_lab_set_union_03585_ats_ptr_type: tmp372 = avl_union_03607_ats_ptr_type (arg0, arg1, arg2) ; return (tmp372) ; } /* end of [set_union_03585_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13105(line=478, offs=16) -- 13152(line=478, offs=63) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_union: tmp371 = set_union_03585_ats_ptr_type (arg0, arg1, &cmp_53) ; return (tmp371) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_union] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2736(line=77, offs=25) -- 3115(line=90, offs=4) */ ATSstaticdec() ats_bool_type avl_member_03590_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_int_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_int_type, tmp486) ; __ats_lab_avl_member_03590_ats_ptr_type: do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_73_0 ; } __ats_lab_69_1: tmp479 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp480 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp481 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp482 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp479) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (tmp482 != -1) { goto __ats_lab_71_0 ; } __ats_lab_70_1: arg0 = tmp480 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03590_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (tmp482 != 1) { goto __ats_lab_72_0 ; } __ats_lab_71_1: arg0 = tmp481 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03590_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (tmp482 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: tmp478 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_77_0 ; } __ats_lab_73_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp484 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_2) ; tmp485 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_3) ; tmp486 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp483) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (tmp486 != -1) { goto __ats_lab_75_0 ; } __ats_lab_74_1: arg0 = tmp484 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03590_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (tmp486 != 1) { goto __ats_lab_76_0 ; } __ats_lab_75_1: arg0 = tmp485 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03590_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: // if (tmp486 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_76_1: tmp478 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: tmp478 = ats_false_bool ; break ; } while (0) ; return (tmp478) ; } /* end of [avl_member_03590_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18362(line=544, offs=25) -- 18400(line=544, offs=63) */ ATSstaticdec() ats_bool_type set_member_03581_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp477) ; __ats_lab_set_member_03581_ats_ptr_type: tmp477 = avl_member_03590_ats_ptr_type (arg0, arg1, arg2) ; return (tmp477) ; } /* end of [set_member_03581_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13179(line=480, offs=26) -- 13223(line=480, offs=70) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp476) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem: tmp476 = set_member_03581_ats_ptr_type (arg0, arg1, &cmp_53) ; return (tmp476) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13259(line=484, offs=3) -- 13320(line=484, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp487) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main: /* tmp487 = */ set_foreach_main_03586_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp487) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18872(line=557, offs=6) -- 18927(line=557, offs=61) */ ATSstaticdec() ats_void_type app_87 (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp490) ; __ats_lab_app_87: /* tmp490 = */ ((ats_void_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg1))) (arg1, arg0) ; return /* (tmp490) */ ; } /* end of [app_87] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18809(line=555, offs=41) -- 19055(line=563, offs=4) */ ATSstaticdec() ats_void_type set_foreach_cloptr_03587_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp489) ; __ats_lab_set_foreach_cloptr_03587_ats_ptr_type: /* tmp489 = */ avl_foreach_03592_ats_ptr_type (arg0, &app_87, arg1) ; return /* (tmp489) */ ; } /* end of [set_foreach_cloptr_03587_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13392(line=489, offs=3) -- 13435(line=489, offs=46) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_cloptr (ats_ptr_type arg0, ats_clo_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp488) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_cloptr: /* tmp488 = */ set_foreach_cloptr_03587_ats_ptr_type (arg0, arg1) ; return /* (tmp488) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_cloptr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13542(line=496, offs=26) -- 13582(line=496, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varset (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; // ATSlocal_void (tmp494) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varset: tmp492 = atspre_stdout_get () ; tmp493 = ats_selsin_mac(tmp492, atslab_1) ; /* tmp494 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset (tmp493, arg0) ; /* tmp491 = */ atspre_stdout_view_set () ; return /* (tmp491) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varset] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dvar.dats: 13608(line=497, offs=26) -- 13648(line=497, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varset (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; // ATSlocal_void (tmp498) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varset: tmp496 = atspre_stderr_get () ; tmp497 = ats_selsin_mac(tmp496, atslab_1) ; /* tmp498 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2varset (tmp497, arg0) ; /* tmp495 = */ atspre_stderr_view_set () ; return /* (tmp495) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varset] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dvar_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_dvar_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_solve_dats.c0000664000175000017500000051103212223166160022717 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_7 ; typedef struct { anairiats_rec_7 atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_12 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_13 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_rec_15 ; typedef struct { anairiats_rec_15 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_tyleq_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_equal_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_funclo_equal_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2eff_leq_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_linearity_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_argvar) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_link) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_lbs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_ubs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_s2exp_set_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs) (ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__stamp_equal_solve_err) (ats_ptr_type, atsopt_count_type, atsopt_count_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err) (ats_ptr_type, ats_int_type, ats_int_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__linearity_equal_solve_err) (ats_ptr_type, ats_int_type, ats_int_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err) (ats_ptr_type, ats_int_type, ats_int_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__refval_equal_solve_err) (ats_ptr_type, ats_int_type, ats_int_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_tyleq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_l_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_r_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_tyleq_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_equal_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_funclo_equal_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2eff_leq_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_linearity_4) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_void_type the_staerrlst_add_2 (ats_ptr_type arg0) ; static ats_ptr_type the_staerrlst_get_3 () ; static ats_void_type prerr_staerr_funclo_equal_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type prerr_staerr_s2exp_tyleq_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type prerr_staerr_s2exp_equal_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type prerr_staerr_s2eff_leq_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type prerr_staerr_s2exp_linearity_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_10 (ats_ptr_type arg0) ; static ats_void_type prerr_the_staerrlst_9 () ; static ats_void_type loop_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type s2exp_nonlin_test_err_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_solve_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_bool_type aux_check_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type s2exp_equal_solve_abscon_err_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type aux_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type s2exp_equal_solve_appvar_err_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type aux_32 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_32_closure_make (ats_ptr_type env0) ; static ats_void_type aux_32_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_34 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_34_closure_make (ats_ptr_type env0) ; static ats_void_type aux_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_36 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0) ; static ats_void_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_38 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0) ; static ats_void_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_43 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_43_closure_make (ats_ptr_type env0) ; static ats_void_type aux_43_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_46 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_46_closure_make (ats_ptr_type env0) ; static ats_void_type aux_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_48 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_clo_ptr_type aux_48_closure_make (ats_ptr_type env0) ; static ats_void_type aux_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type s2exp_tyleq_solve_lbs_err_51 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type s2exp_tyleq_solve_ubs_err_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_solve_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type aux_check_61 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type s2exp_hypo_equal_solve_con_59 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp4) ; // ATSstatic_void (statmp5) ; // ATSstatic_void (statmp6) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 2408(line=85, offs=4) -- 2493(line=86, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 2527(line=89, offs=4) -- 2642(line=91, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_prerr_loc_interror_1: /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp2 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_staexp2_solve)")) ; return /* (tmp2) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 3304(line=119, offs=4) -- 3449(line=124, offs=4) */ ATSstaticdec() ats_void_type the_staerrlst_add_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_the_staerrlst_add_2: tmp9 = ats_ptrget_mac(ats_ptr_type, (&statmp4)) ; tmp8 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp8, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp8, atslab_1, tmp9) ; ats_ptrget_mac(ats_ptr_type, (&statmp4)) = tmp8 ; return /* (tmp7) */ ; } /* end of [the_staerrlst_add_2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 3484(line=126, offs=4) -- 3650(line=133, offs=4) */ ATSstaticdec() ats_ptr_type the_staerrlst_get_3 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_the_staerrlst_get_3: tmp11 = ats_ptrget_mac(ats_ptr_type, (&statmp4)) ; tmp12 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, (&statmp4)) = tmp12 ; tmp10 = tmp11 ; return (tmp10) ; } /* end of [the_staerrlst_get_3] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 3708(line=137, offs=4) -- 4020(line=143, offs=4) */ ATSstaticdec() ats_void_type prerr_staerr_funclo_equal_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; __ats_lab_prerr_staerr_funclo_equal_4: /* tmp14 = */ prerr_loc_error3_0 (arg0) ; /* tmp15 = */ atspre_prerr_string (ATSstrcst(": function/closure mismatch:\n")) ; /* tmp16 = */ atspre_prerr_string (ATSstrcst("The needed funclo kind is: ")) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo (arg2) ; /* tmp18 = */ atspre_prerr_newline () ; /* tmp19 = */ atspre_prerr_string (ATSstrcst("The actual funclo kind is: ")) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo (arg1) ; /* tmp13 = */ atspre_prerr_newline () ; return /* (tmp13) */ ; } /* end of [prerr_staerr_funclo_equal_4] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 4063(line=145, offs=4) -- 4359(line=151, offs=4) */ ATSstaticdec() ats_void_type prerr_staerr_s2exp_tyleq_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_prerr_staerr_s2exp_tyleq_5: /* tmp22 = */ prerr_loc_error3_0 (arg0) ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(": mismatch of static terms (tyleq):\n")) ; /* tmp24 = */ atspre_prerr_string (ATSstrcst("The needed term is: ")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (arg2) ; /* tmp26 = */ atspre_prerr_newline () ; /* tmp27 = */ atspre_prerr_string (ATSstrcst("The actual term is: ")) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (arg1) ; /* tmp21 = */ atspre_prerr_newline () ; return /* (tmp21) */ ; } /* end of [prerr_staerr_s2exp_tyleq_5] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 4401(line=153, offs=4) -- 4697(line=159, offs=4) */ ATSstaticdec() ats_void_type prerr_staerr_s2exp_equal_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; __ats_lab_prerr_staerr_s2exp_equal_6: /* tmp30 = */ prerr_loc_error3_0 (arg0) ; /* tmp31 = */ atspre_prerr_string (ATSstrcst(": mismatch of static terms (equal):\n")) ; /* tmp32 = */ atspre_prerr_string (ATSstrcst("The needed term is: ")) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (arg2) ; /* tmp34 = */ atspre_prerr_newline () ; /* tmp35 = */ atspre_prerr_string (ATSstrcst("The actual term is: ")) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (arg1) ; /* tmp29 = */ atspre_prerr_newline () ; return /* (tmp29) */ ; } /* end of [prerr_staerr_s2exp_equal_6] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 4739(line=161, offs=4) -- 5024(line=167, offs=4) */ ATSstaticdec() ats_void_type prerr_staerr_s2eff_leq_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; // ATSlocal_void (tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp44) ; __ats_lab_prerr_staerr_s2eff_leq_7: /* tmp38 = */ prerr_loc_error3_0 (arg0) ; /* tmp39 = */ atspre_prerr_string (ATSstrcst(": mismatch of effects:\n")) ; /* tmp40 = */ atspre_prerr_string (ATSstrcst("The needed term is: ")) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff (arg2) ; /* tmp42 = */ atspre_prerr_newline () ; /* tmp43 = */ atspre_prerr_string (ATSstrcst("The actual term is: ")) ; /* tmp44 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff (arg1) ; /* tmp37 = */ atspre_prerr_newline () ; return /* (tmp37) */ ; } /* end of [prerr_staerr_s2eff_leq_7] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 5064(line=169, offs=4) -- 5277(line=174, offs=4) */ ATSstaticdec() ats_void_type prerr_staerr_s2exp_linearity_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_prerr_staerr_s2exp_linearity_8: /* tmp46 = */ prerr_loc_error3_0 (arg0) ; /* tmp47 = */ atspre_prerr_string (ATSstrcst(": mismatch of linearity:\n")) ; /* tmp48 = */ atspre_prerr_string (ATSstrcst("A nonlinear term is needed: ")) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__pprerr_s2exp (arg1) ; /* tmp45 = */ atspre_prerr_newline () ; return /* (tmp45) */ ; } /* end of [prerr_staerr_s2exp_linearity_8] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 5359(line=178, offs=5) -- 6044(line=192, offs=26) */ ATSstaticdec() ats_void_type loop_10 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_loop_10: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_0_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp53 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp52)->tag != 2) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; tmp56 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_1) ; tmp57 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_2) ; /* tmp54 = */ prerr_staerr_funclo_equal_4 (tmp55, tmp56, tmp57) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp52)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_1) ; tmp60 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_2) ; /* tmp54 = */ prerr_staerr_s2exp_equal_6 (tmp58, tmp59, tmp60) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp52)->tag != 0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp61 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; tmp62 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_1) ; tmp63 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_2) ; /* tmp54 = */ prerr_staerr_s2exp_tyleq_5 (tmp61, tmp62, tmp63) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp52)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_0) ; tmp65 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_1) ; tmp66 = ats_caselptrlab_mac(anairiats_sum_1, tmp52, atslab_2) ; /* tmp54 = */ prerr_staerr_s2eff_leq_7 (tmp64, tmp65, tmp66) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (((ats_sum_ptr_type)tmp52)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_2, tmp52, atslab_0) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_2, tmp52, atslab_1) ; /* tmp54 = */ prerr_staerr_s2exp_linearity_8 (tmp67, tmp68) ; break ; } while (0) ; arg0 = tmp53 ; goto __ats_lab_loop_10 ; // tail call break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: break ; } while (0) ; return /* (tmp51) */ ; } /* end of [loop_10] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 5323(line=176, offs=4) -- 6102(line=198, offs=4) */ ATSstaticdec() ats_void_type prerr_the_staerrlst_9 () { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_prerr_the_staerrlst_9: tmp69 = the_staerrlst_get_3 () ; /* tmp50 = */ loop_10 (tmp69) ; return /* (tmp50) */ ; } /* end of [prerr_the_staerrlst_9] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 6191(line=204, offs=3) -- 6254(line=205, offs=43) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp70) ; ATSlocal (ats_bool_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err: tmp71 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (arg1, arg2) ; if (tmp71) { /* empty */ } else { tmp72 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp72 ; } /* end of [if] */ return /* (tmp70) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 6324(line=210, offs=3) -- 6387(line=211, offs=43) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__stamp_equal_solve_err (ats_ptr_type arg0, atsopt_count_type arg1, atsopt_count_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp73) ; ATSlocal (ats_bool_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__stamp_equal_solve_err: tmp74 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (arg1, arg2) ; if (tmp74) { /* empty */ } else { tmp75 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp75 ; } /* end of [if] */ return /* (tmp73) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__stamp_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 6475(line=218, offs=3) -- 6617(line=223, offs=6) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp76) ; ATSlocal (ats_bool_type, tmp77) ; // ATSlocal_void (tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve: tmp77 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo (arg1, arg2) ; if (tmp77) { /* empty */ } else { /* tmp78 = */ prerr_staerr_funclo_equal_4 (arg0, arg1, arg2) ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp76) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 6700(line=228, offs=3) -- 6879(line=234, offs=6) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_bool_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve_err: tmp80 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo (arg1, arg2) ; if (tmp80) { /* empty */ } else { tmp81 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp81 ; tmp82 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp82)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp82, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp82, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp82, atslab_2, arg2) ; /* tmp79 = */ the_staerrlst_add_2 (tmp82) ; } /* end of [if] */ return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 6988(line=241, offs=3) -- 7059(line=242, offs=47) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp83) ; ATSlocal (ats_bool_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err: tmp84 = atspre_eq_int_int (arg1, arg2) ; if (tmp84) { /* empty */ } else { tmp85 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp85 ; } /* end of [if] */ return /* (tmp83) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 7135(line=247, offs=3) -- 7206(line=248, offs=47) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__linearity_equal_solve_err (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp86) ; ATSlocal (ats_bool_type, tmp87) ; ATSlocal (ats_int_type, tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__linearity_equal_solve_err: tmp87 = atspre_eq_int_int (arg1, arg2) ; if (tmp87) { /* empty */ } else { tmp88 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp88 ; } /* end of [if] */ return /* (tmp86) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__linearity_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 7282(line=253, offs=3) -- 7353(line=254, offs=47) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp89) ; ATSlocal (ats_bool_type, tmp90) ; ATSlocal (ats_int_type, tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err: tmp90 = atspre_eq_int_int (arg1, arg2) ; if (tmp90) { /* empty */ } else { tmp91 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp91 ; } /* end of [if] */ return /* (tmp89) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 7450(line=261, offs=3) -- 7521(line=262, offs=47) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_bool_type, tmp93) ; ATSlocal (ats_int_type, tmp94) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind (arg1, arg2) ; if (tmp93) { /* empty */ } else { tmp94 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp94 ; } /* end of [if] */ return /* (tmp92) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 7596(line=267, offs=3) -- 7680(line=268, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__refval_equal_solve_err (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp95) ; ATSlocal (ats_bool_type, tmp96) ; ATSlocal (ats_int_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__refval_equal_solve_err: tmp96 = atspre_eq_int_int (arg1, arg2) ; if (tmp96) { /* empty */ } else { tmp97 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp97 ; } /* end of [if] */ return /* (tmp95) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__refval_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 8085(line=283, offs=13) -- 8365(line=288, offs=36) */ ATSstaticdec() ats_void_type loop_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; // ATSlocal_void (tmp110) ; __ats_lab_loop_21: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (arg0, tmp108) ; arg0 = arg0 ; arg1 = tmp109 ; goto __ats_lab_loop_21 ; // tail call break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: break ; } while (0) ; return /* (tmp107) */ ; } /* end of [loop_21] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 7769(line=274, offs=22) -- 8659(line=299, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_int_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_int_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_int_type, tmp111) ; ATSlocal (ats_bool_type, tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve: /* ats_int_type tmp99 ; */ tmp99 = 0 ; tmp100 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp100), atslab_s2exp_node) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp102)->tag != 4) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_4, tmp102, atslab_0) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype, tmp103) ; if (tmp104) { /* empty */ } else { tmp105 = atspre_iadd (tmp99, 1) ; tmp99 = tmp105 ; } /* end of [if] */ break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp102)->tag != 17) { goto __ats_lab_9_0 ; } __ats_lab_8_1: break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp102)->tag != 29) { goto __ats_lab_12_0 ; } __ats_lab_9_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_5, tmp102, atslab_2) ; /* tmp101 = */ loop_21 (arg0, tmp106) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp111 = atspre_iadd (tmp99, 1) ; tmp99 = tmp111 ; break ; } while (0) ; tmp112 = atspre_gt_int_int (tmp99, 0) ; if (tmp112) { /* tmp113 = */ prerr_loc_error3_0 (arg0) ; /* tmp114 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp100) ; /* tmp116 = */ atspre_prerr_string (ATSstrcst("] is expected to be empty.")) ; /* tmp117 = */ atspre_prerr_newline () ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp98) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 8731(line=302, offs=25) -- 9085(line=311, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve_at (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (anairiats_rec_7, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve_at: tmp119 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (arg1) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (tmp119 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp120 = ats_caselptrlab_mac(anairiats_sum_8, tmp119, atslab_0) ; ATS_FREE(tmp119) ; tmp121 = ats_select_mac(tmp120, atslab_0) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve (arg0, tmp121) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (tmp119 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: /* tmp122 = */ prerr_loc_error3_0 (arg0) ; /* tmp123 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp125 = */ atspre_prerr_string (ATSstrcst("] is expected to be an @-view.")) ; /* tmp126 = */ atspre_prerr_newline () ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp118) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve_at] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 9147(line=315, offs=4) -- 9372(line=323, offs=6) */ ATSstaticdec() ats_void_type s2exp_nonlin_test_err_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp127) ; ATSlocal (ats_bool_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_s2exp_nonlin_test_err_23: tmp128 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (arg1) ; if (tmp128) { tmp129 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp129 ; tmp130 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp130)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp130, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp130, atslab_1, arg1) ; /* tmp127 = */ the_staerrlst_add_2 (tmp130) ; } else { /* empty */ } /* end of [if] */ return /* (tmp127) */ ; } /* end of [s2exp_nonlin_test_err_23] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 9532(line=330, offs=7) -- 9955(line=342, offs=6) */ ATSstaticdec() ats_void_type aux_solve_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; // ATSlocal_void (tmp139) ; __ats_lab_aux_solve_25: tmp133 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_node) ; tmp134 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg2), atslab_s2exp_node) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp133)->tag != 0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: if (((ats_sum_ptr_type)tmp134)->tag != 0) { goto __ats_lab_16_1 ; } __ats_lab_15_2: tmp135 = ats_caselptrlab_mac(anairiats_sum_2, tmp133, atslab_0) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_2, tmp133, atslab_1) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_2, tmp134, atslab_0) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_2, tmp134, atslab_1) ; /* tmp139 = */ aux_solve_25 (arg0, tmp135, tmp137, arg3) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (arg0, tmp136, tmp138, arg3) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: __ats_lab_16_2: break ; } while (0) ; return /* (tmp132) */ ; } /* end of [aux_solve_25] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 9987(line=344, offs=7) -- 10267(line=351, offs=6) */ ATSstaticdec() ats_bool_type aux_check_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_aux_check_26: tmp141 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_s2exp_node) ; tmp142 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp141)->tag != 4) { goto __ats_lab_18_0 ; } __ats_lab_17_1: if (((ats_sum_ptr_type)tmp142)->tag != 4) { goto __ats_lab_19_1 ; } __ats_lab_17_2: tmp143 = ats_caselptrlab_mac(anairiats_sum_4, tmp141, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_4, tmp142, atslab_0) ; tmp140 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp143, tmp144) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp141)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: if (((ats_sum_ptr_type)tmp142)->tag != 0) { goto __ats_lab_19_1 ; } __ats_lab_18_2: tmp145 = ats_caselptrlab_mac(anairiats_sum_2, tmp141, atslab_0) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_2, tmp142, atslab_0) ; arg0 = tmp145 ; arg1 = tmp146 ; goto __ats_lab_aux_check_26 ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: __ats_lab_19_2: tmp140 = ats_false_bool ; break ; } while (0) ; return (tmp140) ; } /* end of [aux_check_26] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 9426(line=326, offs=4) -- 10411(line=357, offs=4) */ ATSstaticdec() ats_void_type s2exp_equal_solve_abscon_err_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp131) ; ATSlocal (ats_bool_type, tmp147) ; ATSlocal (ats_int_type, tmp148) ; __ats_lab_s2exp_equal_solve_abscon_err_24: tmp147 = aux_check_26 (arg1, arg2) ; if (tmp147) { /* tmp131 = */ aux_solve_25 (arg0, arg1, arg2, arg3) ; } else { tmp148 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp148 ; } /* end of [if] */ return /* (tmp131) */ ; } /* end of [s2exp_equal_solve_abscon_err_24] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 10561(line=363, offs=7) -- 10912(line=372, offs=6) */ ATSstaticdec() ats_void_type aux_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; __ats_lab_aux_28: tmp151 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_node) ; tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg2), atslab_s2exp_node) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp151)->tag != 0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: if (((ats_sum_ptr_type)tmp152)->tag != 0) { goto __ats_lab_21_1 ; } __ats_lab_20_2: tmp153 = ats_caselptrlab_mac(anairiats_sum_2, tmp151, atslab_0) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_2, tmp151, atslab_1) ; tmp155 = ats_caselptrlab_mac(anairiats_sum_2, tmp152, atslab_0) ; tmp156 = ats_caselptrlab_mac(anairiats_sum_2, tmp152, atslab_1) ; /* tmp157 = */ aux_28 (arg0, tmp153, tmp155, arg3) ; /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (arg0, tmp154, tmp156, arg3) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: __ats_lab_21_2: break ; } while (0) ; return /* (tmp150) */ ; } /* end of [aux_28] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 10457(line=359, offs=4) -- 10965(line=375, offs=4) */ ATSstaticdec() ats_void_type s2exp_equal_solve_appvar_err_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp149) ; __ats_lab_s2exp_equal_solve_appvar_err_27: /* tmp149 = */ aux_28 (arg0, arg1, arg2, arg3) ; return /* (tmp149) */ ; } /* end of [s2exp_equal_solve_appvar_err_27] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 11057(line=380, offs=19) -- 11271(line=387, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp158) ; ATSlocal (ats_int_type, tmp159) ; // ATSlocal_void (tmp160) ; ATSlocal (ats_bool_type, tmp161) ; // ATSlocal_void (tmp162) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve: /* ats_int_type tmp159 ; */ tmp159 = 0 ; /* tmp160 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, arg1, arg2, (&tmp159)) ; tmp161 = atspre_gt_int_int (tmp159, 0) ; if (tmp161) { /* tmp162 = */ prerr_the_staerrlst_9 () ; /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp158) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 11338(line=390, offs=23) -- 15074(line=486, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp163) ; ATSlocal (ats_int_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_int_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_bool_type, tmp177) ; ATSlocal (ats_int_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; // ATSlocal_void (tmp183) ; ATSlocal (ats_int_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_int_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; // ATSlocal_void (tmp192) ; ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_int_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; ATSlocal (ats_int_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_int_type, tmp208) ; ATSlocal (ats_bool_type, tmp209) ; ATSlocal (ats_bool_type, tmp210) ; ATSlocal (ats_bool_type, tmp211) ; // ATSlocal_void (tmp212) ; ATSlocal (ats_bool_type, tmp213) ; ATSlocal (ats_bool_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err: tmp164 = ats_ptrget_mac(ats_int_type, arg3) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp166 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp168 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp165), atslab_s2exp_node) ; tmp169 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp166), atslab_s2exp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp168)->tag != 33) { goto __ats_lab_23_0 ; } __ats_lab_22_1: __ats_lab_22_2: tmp170 = ats_caselptrlab_mac(anairiats_sum_4, tmp168, atslab_0) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err (arg0, tmp170, tmp165, tmp166, arg3) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: if (((ats_sum_ptr_type)tmp169)->tag != 33) { goto __ats_lab_24_0 ; } __ats_lab_23_2: tmp171 = ats_caselptrlab_mac(anairiats_sum_4, tmp169, atslab_0) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err (arg0, tmp171, tmp166, tmp165, arg3) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp168)->tag != 3) { goto __ats_lab_27_0 ; } __ats_lab_24_1: __ats_lab_24_2: tmp172 = ats_caselptrlab_mac(anairiats_sum_4, tmp168, atslab_0) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp169)->tag != 3) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_4, tmp169, atslab_0) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp172, tmp173, arg3) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp174 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp174 ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp168)->tag != 4) { goto __ats_lab_30_0 ; } __ats_lab_27_1: __ats_lab_27_2: tmp175 = ats_caselptrlab_mac(anairiats_sum_4, tmp168, atslab_0) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp169)->tag != 4) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_4, tmp169, atslab_0) ; tmp177 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp175, tmp176) ; if (tmp177) { /* empty */ } else { tmp178 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp178 ; } /* end of [if] */ break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq (arg0, tmp165, tmp166) ; break ; } while (0) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp168)->tag != 19) { goto __ats_lab_33_0 ; } __ats_lab_30_1: __ats_lab_30_2: tmp179 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_0) ; tmp180 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_1) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp169)->tag != 19) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_1) ; /* tmp183 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp181, tmp179, arg3) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp180, tmp182, arg3) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp184 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp184 ; break ; } while (0) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp168)->tag != 23) { goto __ats_lab_36_0 ; } __ats_lab_33_1: __ats_lab_33_2: tmp185 = ats_caselptrlab_mac(anairiats_sum_4, tmp168, atslab_0) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp169)->tag != 23) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_4, tmp169, atslab_0) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err (arg0, tmp185, tmp186, arg3) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: tmp187 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp187 ; break ; } while (0) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp168)->tag != 26) { goto __ats_lab_39_0 ; } __ats_lab_36_1: __ats_lab_36_2: tmp188 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_0) ; tmp189 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_1) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp169)->tag != 26) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_0) ; tmp191 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_1) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp188, tmp190, arg3) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err (arg0, tmp189, tmp191, arg3) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp193 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp193 ; break ; } while (0) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp168)->tag != 29) { goto __ats_lab_42_0 ; } __ats_lab_39_1: __ats_lab_39_2: tmp194 = ats_caselptrlab_mac(anairiats_sum_5, tmp168, atslab_0) ; tmp195 = ats_caselptrlab_mac(anairiats_sum_5, tmp168, atslab_1) ; tmp196 = ats_caselptrlab_mac(anairiats_sum_5, tmp168, atslab_2) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp169)->tag != 29) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_5, tmp169, atslab_0) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_5, tmp169, atslab_1) ; tmp199 = ats_caselptrlab_mac(anairiats_sum_5, tmp169, atslab_2) ; /* tmp200 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err (arg0, tmp194, tmp197, arg3) ; /* tmp201 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err (arg0, tmp195, tmp198, arg3) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_equal_solve_err (arg0, tmp196, tmp199, arg3) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp202 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp202 ; break ; } while (0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp168)->tag != 35) { goto __ats_lab_45_0 ; } __ats_lab_42_1: __ats_lab_42_2: tmp203 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_0) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_1) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp169)->tag != 35) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_2, tmp169, atslab_1) ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp203, tmp205, arg3) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_equal_solve_err (arg0, tmp204, tmp206, arg3) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp208 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp208 ; break ; } while (0) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: __ats_lab_45_2: tmp210 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon (tmp165) ; if (tmp210) { tmp209 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon (tmp166) ; } else { tmp209 = ats_false_bool ; } /* end of [if] */ if (!tmp209) { goto __ats_lab_46_2 ; } /* tmp167 = */ s2exp_equal_solve_abscon_err_24 (arg0, tmp165, tmp166, arg3) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: __ats_lab_46_2: tmp211 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative (tmp165) ; if (!tmp211) { goto __ats_lab_47_2 ; } /* tmp212 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp165, tmp166, arg3) ; /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp166, tmp165, arg3) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: __ats_lab_47_2: tmp213 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp165, tmp166) ; if (!tmp213) { goto __ats_lab_48_2 ; } break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: __ats_lab_48_1: __ats_lab_48_2: /* tmp167 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq (arg0, tmp165, tmp166) ; break ; } while (0) ; tmp214 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg3), tmp164) ; if (tmp214) { tmp215 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp215)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp215, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp215, atslab_1, tmp165) ; ats_selptrset_mac(anairiats_sum_1, tmp215, atslab_2, tmp166) ; /* tmp163 = */ the_staerrlst_add_2 (tmp215) ; } else { /* empty */ } /* end of [if] */ return /* (tmp163) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 15187(line=491, offs=7) -- 15585(line=501, offs=42) */ ATSstaticdec() ats_void_type aux_32 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; // ATSlocal_void (tmp222) ; ATSlocal (ats_int_type, tmp223) ; ATSlocal (ats_int_type, tmp224) ; __ats_lab_aux_32: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_51_1 ; } __ats_lab_49_2: tmp218 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp219 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp221 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp222 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (env0, tmp218, tmp220, arg2) ; arg0 = tmp219 ; arg1 = tmp221 ; arg2 = arg2 ; goto __ats_lab_aux_32 ; // tail call break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_52_1 ; } __ats_lab_50_2: break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_2: tmp223 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp223 ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_2: tmp224 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp224 ; break ; } while (0) ; return /* (tmp217) */ ; } /* end of [aux_32] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_32_closure_type ; ats_void_type aux_32_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_32 (((aux_32_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_32_closure_init (aux_32_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_32_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_32_closure_make (ats_ptr_type env0) { aux_32_closure_type *p_clo = ATS_MALLOC(sizeof(aux_32_closure_type)) ; aux_32_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 15147(line=490, offs=3) -- 15638(line=505, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp216) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err: /* tmp216 = */ aux_32 (arg0, arg1, arg2, arg3) ; return /* (tmp216) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 15759(line=510, offs=7) -- 16365(line=525, offs=6) */ ATSstaticdec() ats_void_type aux_34 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; ATSlocal (ats_int_type, tmp235) ; ATSlocal (ats_int_type, tmp236) ; __ats_lab_aux_34: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_55_1 ; } __ats_lab_53_2: tmp227 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp228 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err (env0, tmp227, tmp230, arg2) ; /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (env0, tmp228, tmp231, arg2) ; arg0 = tmp229 ; arg1 = tmp232 ; arg2 = arg2 ; goto __ats_lab_aux_34 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_56_1 ; } __ats_lab_54_2: break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_2: tmp235 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp235 ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_2: tmp236 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp236 ; break ; } while (0) ; return /* (tmp226) */ ; } /* end of [aux_34] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_34_closure_type ; ats_void_type aux_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_34 (((aux_34_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_34_closure_init (aux_34_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_34_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_34_closure_make (ats_ptr_type env0) { aux_34_closure_type *p_clo = ATS_MALLOC(sizeof(aux_34_closure_type)) ; aux_34_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 15717(line=509, offs=3) -- 16418(line=528, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp225) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_equal_solve_err: /* tmp225 = */ aux_34 (arg0, arg1, arg2, arg3) ; return /* (tmp225) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 16546(line=533, offs=7) -- 17319(line=553, offs=6) */ ATSstaticdec() ats_void_type aux_36 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; // ATSlocal_void (tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_int_type, tmp246) ; __ats_lab_aux_36: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_58_0 ; } __ats_lab_57_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_60_1 ; } __ats_lab_57_2: tmp239 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp240 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp241 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; tmp242 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_2) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (env0, tmp239, tmp241, arg2) ; arg0 = tmp240 ; arg1 = tmp242 ; arg2 = arg2 ; goto __ats_lab_aux_36 ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_60_1 ; } __ats_lab_58_2: tmp244 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp245 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; arg0 = tmp244 ; arg1 = tmp245 ; arg2 = arg2 ; goto __ats_lab_aux_36 ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_60_1 ; } __ats_lab_59_2: break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: __ats_lab_60_2: tmp246 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp246 ; break ; } while (0) ; return /* (tmp238) */ ; } /* end of [aux_36] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_36_closure_type ; ats_void_type aux_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_36 (((aux_36_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_36_closure_init (aux_36_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_36_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_36_closure_make (ats_ptr_type env0) { aux_36_closure_type *p_clo = ATS_MALLOC(sizeof(aux_36_closure_type)) ; aux_36_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 16500(line=532, offs=3) -- 17376(line=556, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp237) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_equal_solve_err: /* tmp237 = */ aux_36 (arg0, arg1, arg2, arg3) ; return /* (tmp237) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 17500(line=561, offs=7) -- 17889(line=571, offs=6) */ ATSstaticdec() ats_void_type aux_38 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; // ATSlocal_void (tmp253) ; ATSlocal (ats_int_type, tmp254) ; __ats_lab_aux_38: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_63_1 ; } __ats_lab_61_2: tmp249 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp250 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp251 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp252 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp253 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (env0, tmp249, tmp251, arg2) ; arg0 = tmp250 ; arg1 = tmp252 ; arg2 = arg2 ; goto __ats_lab_aux_38 ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_63_1 ; } __ats_lab_62_2: break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: __ats_lab_63_2: tmp254 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp254 ; break ; } while (0) ; return /* (tmp248) */ ; } /* end of [aux_38] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_38_closure_type ; ats_void_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_38 (((aux_38_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_38_closure_init (aux_38_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_38_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0) { aux_38_closure_type *p_clo = ATS_MALLOC(sizeof(aux_38_closure_type)) ; aux_38_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 17458(line=560, offs=3) -- 17942(line=574, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp247) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err: /* tmp247 = */ aux_38 (arg0, arg1, arg2, arg3) ; return /* (tmp247) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 18044(line=580, offs=3) -- 18532(line=593, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_bool_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err: tmp256 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (arg1) ; tmp257 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (arg2) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_syneq (tmp256, tmp257) ; if (tmp258) { /* empty */ } else { tmp259 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp259 ; } /* end of [if] */ return /* (tmp255) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 27502(line=819, offs=15) -- 27921(line=828, offs=47) */ ATSstaticdec() ats_ptr_type aux_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; __ats_lab_aux_41: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp394 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp395 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; /* tmp396 = */ s2exp_nonlin_test_err_23 (arg0, tmp394, arg2) ; tmp397 = aux_41 (arg0, tmp395, arg2) ; tmp393 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp393, atslab_0, tmp394) ; ats_selptrset_mac(anairiats_sum_0, tmp393, atslab_1, tmp397) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_120_1: tmp393 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp393) ; } /* end of [aux_41] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 18629(line=598, offs=23) -- 29743(line=877, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp260) ; ATSlocal (ats_int_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; // ATSlocal_void (tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_bool_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_int_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_bool_type, tmp274) ; ATSlocal (ats_int_type, tmp275) ; ATSlocal (ats_int_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_bool_type, tmp278) ; ATSlocal (ats_int_type, tmp279) ; ATSlocal (ats_int_type, tmp280) ; // ATSlocal_void (tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; // ATSlocal_void (tmp288) ; // ATSlocal_void (tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; // ATSlocal_void (tmp291) ; // ATSlocal_void (tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; // ATSlocal_void (tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_bool_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_bool_type, tmp311) ; ATSlocal (ats_int_type, tmp312) ; ATSlocal (ats_int_type, tmp313) ; ATSlocal (ats_int_type, tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_int_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_int_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_bool_type, tmp326) ; ATSlocal (ats_int_type, tmp327) ; ATSlocal (ats_int_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_bool_type, tmp333) ; ATSlocal (ats_int_type, tmp334) ; ATSlocal (ats_int_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_int_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_int_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_int_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_int_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; // ATSlocal_void (tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; ATSlocal (ats_int_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; // ATSlocal_void (tmp355) ; ATSlocal (ats_int_type, tmp356) ; ATSlocal (ats_int_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_bool_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_int_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; // ATSlocal_void (tmp367) ; ATSlocal (ats_int_type, tmp368) ; ATSlocal (ats_int_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_int_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; // ATSlocal_void (tmp373) ; ATSlocal (ats_int_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; // ATSlocal_void (tmp379) ; ATSlocal (ats_int_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_int_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_int_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_int_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; // ATSlocal_void (tmp390) ; // ATSlocal_void (tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; // ATSlocal_void (tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; // ATSlocal_void (tmp402) ; ATSlocal (ats_int_type, tmp403) ; ATSlocal (atsopt_count_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (atsopt_count_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; ATSlocal (ats_int_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_bool_type, tmp415) ; ATSlocal (ats_int_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_int_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; // ATSlocal_void (tmp425) ; ATSlocal (ats_int_type, tmp426) ; ATSlocal (ats_bool_type, tmp427) ; ATSlocal (ats_int_type, tmp428) ; ATSlocal (ats_bool_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err: tmp261 = ats_ptrget_mac(ats_int_type, arg3) ; tmp262 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp265 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp262), atslab_s2exp_node) ; tmp266 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp263), atslab_s2exp_node) ; do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp265)->tag != 33) { goto __ats_lab_65_0 ; } __ats_lab_64_1: if (((ats_sum_ptr_type)tmp266)->tag != 33) { goto __ats_lab_65_1 ; } __ats_lab_64_2: tmp267 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var (tmp267, tmp268) ; if (!tmp269) { goto __ats_lab_65_2 ; } break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp265)->tag != 33) { goto __ats_lab_66_0 ; } __ats_lab_65_1: __ats_lab_65_2: tmp270 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_l_err (arg0, tmp270, tmp262, tmp263, arg3) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: if (((ats_sum_ptr_type)tmp266)->tag != 33) { goto __ats_lab_67_1 ; } __ats_lab_66_2: tmp271 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_r_err (arg0, tmp262, tmp271, tmp263, arg3) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: __ats_lab_67_1: if (((ats_sum_ptr_type)tmp266)->tag != 24) { goto __ats_lab_72_0 ; } __ats_lab_67_2: tmp272 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_0) ; tmp273 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_1) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (tmp272 != 0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp274 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin (tmp262) ; if (tmp274) { /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err (arg0, tmp262, tmp263, arg3) ; } else { tmp275 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp275 ; } /* end of [if] */ break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)tmp265)->tag != 24) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp276 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_0) ; tmp277 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_1) ; tmp278 = atspre_eq_int_int (tmp276, 1) ; if (tmp278) { /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp277, tmp273, arg3) ; } else { tmp279 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp279 ; } /* end of [if] */ break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp280 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp280 ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp265)->tag != 30) { goto __ats_lab_73_0 ; } __ats_lab_72_1: __ats_lab_72_2: /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add (arg0, tmp263) ; tmp283 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (arg0, tmp262) ; /* tmp284 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp283, tmp282, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: __ats_lab_73_1: if (((ats_sum_ptr_type)tmp266)->tag != 9) { goto __ats_lab_74_1 ; } __ats_lab_73_2: /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp286 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp262) ; tmp287 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all (arg0, tmp263) ; /* tmp288 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp286, tmp287, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: __ats_lab_74_1: if (((ats_sum_ptr_type)tmp266)->tag != 30) { goto __ats_lab_75_0 ; } __ats_lab_74_2: /* tmp289 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp290 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add (arg0, tmp263) ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp262, tmp290, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp265)->tag != 9) { goto __ats_lab_76_0 ; } __ats_lab_75_1: __ats_lab_75_2: /* tmp292 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp293 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp262) ; /* tmp294 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp293, tmp263, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp265)->tag != 0) { goto __ats_lab_86_0 ; } __ats_lab_76_1: __ats_lab_76_2: tmp295 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp296 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_1) ; do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp266)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_77_1: tmp297 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_0) ; tmp298 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_1) ; tmp299 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp295), atslab_s2exp_node) ; tmp300 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp297), atslab_s2exp_node) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp299)->tag != 4) { goto __ats_lab_81_0 ; } __ats_lab_78_1: if (((ats_sum_ptr_type)tmp300)->tag != 4) { goto __ats_lab_81_1 ; } __ats_lab_78_2: tmp301 = ats_caselptrlab_mac(anairiats_sum_4, tmp299, atslab_0) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_4, tmp300, atslab_0) ; tmp303 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup (tmp301, tmp302) ; if (tmp303) { tmp304 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_argvar (tmp301) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (tmp304 == (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_79_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_11, tmp304, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err (arg0, tmp296, tmp298, tmp305, arg3) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (tmp304 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (arg0, tmp296, tmp298, arg3) ; break ; } while (0) ; } else { tmp306 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp306 ; } /* end of [if] */ break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: __ats_lab_81_2: /* tmp307 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp295, tmp297, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (arg0, tmp296, tmp298, arg3) ; break ; } while (0) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp266)->tag != 4) { goto __ats_lab_85_0 ; } __ats_lab_82_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp295), atslab_s2exp_node) ; do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp309)->tag != 4) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_4, tmp309, atslab_0) ; tmp311 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup (tmp310, tmp308) ; if (tmp311) { /* empty */ } else { tmp312 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp312 ; } /* end of [if] */ break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp313 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp313 ; break ; } while (0) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp314 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp314 ; break ; } while (0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp265)->tag != 2) { goto __ats_lab_89_0 ; } __ats_lab_86_1: __ats_lab_86_2: tmp315 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_1) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp266)->tag != 2) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp317 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_0) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_1) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err (arg0, tmp315, tmp317, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp316, tmp318, arg3) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: __ats_lab_88_1: tmp320 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp320 ; break ; } while (0) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp265)->tag != 3) { goto __ats_lab_92_0 ; } __ats_lab_89_1: __ats_lab_89_2: tmp321 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp266)->tag != 3) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp322 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp321, tmp322, arg3) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp323 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp323 ; break ; } while (0) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp265)->tag != 4) { goto __ats_lab_95_0 ; } __ats_lab_92_1: __ats_lab_92_2: tmp324 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp266)->tag != 4) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; tmp326 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup (tmp324, tmp325) ; if (tmp326) { /* empty */ } else { tmp327 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp327 ; } /* end of [if] */ break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: __ats_lab_94_1: tmp328 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp328 ; break ; } while (0) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp265)->tag != 5) { goto __ats_lab_98_0 ; } __ats_lab_95_1: __ats_lab_95_2: tmp329 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_1) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp266)->tag != 5) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_0) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_1) ; tmp333 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp329, tmp331) ; if (tmp333) { /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_equal_solve_err (arg0, tmp330, tmp332, arg3) ; } else { tmp334 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp334 ; } /* end of [if] */ break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: tmp335 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp335 ; break ; } while (0) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp265)->tag != 11) { goto __ats_lab_104_0 ; } __ats_lab_98_1: __ats_lab_98_2: tmp336 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_0) ; tmp337 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_1) ; tmp338 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_2) ; tmp339 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_3) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_4) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_12, tmp265, atslab_5) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp266)->tag != 11) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp342 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_0) ; tmp343 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_1) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_2) ; tmp345 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_3) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_4) ; tmp347 = ats_caselptrlab_mac(anairiats_sum_12, tmp266, atslab_5) ; /* tmp348 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__funclo_equal_solve_err (arg0, tmp336, tmp342, arg3) ; /* tmp349 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__linearity_equal_solve_err (arg0, tmp337, tmp343, arg3) ; /* tmp350 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err (arg0, tmp339, tmp345, arg3) ; /* tmp351 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err (arg0, tmp338, tmp344, arg3) ; /* tmp352 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err (arg0, tmp346, tmp340, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp341, tmp347, arg3) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp266)->tag != 2) { goto __ats_lab_103_0 ; } __ats_lab_100_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_0) ; tmp354 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_1) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: if (tmp336 == (ats_sum_ptr_type)0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_13, tmp336, atslab_0) ; /* tmp355 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__clokind_equal_solve_err (arg0, tmp356, tmp353, arg3) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: __ats_lab_102_1: tmp357 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp357 ; break ; } while (0) ; tmp359 = atspre_gt_int_int (tmp337, 0) ; if (tmp359) { tmp358 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } else { tmp358 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } /* end of [if] */ tmp361 = (ats_sum_ptr_type)0 ; tmp360 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp358, tmp361, tmp337, tmp338, tmp339, tmp340, tmp341) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp360, tmp354, arg3) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: __ats_lab_103_1: tmp362 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp362 ; break ; } while (0) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp265)->tag != 19) { goto __ats_lab_107_0 ; } __ats_lab_104_1: __ats_lab_104_2: tmp363 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp364 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_1) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp266)->tag != 19) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp365 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_0) ; tmp366 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_1) ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp365, tmp363, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp364, tmp366, arg3) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: tmp368 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp368 ; break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)tmp265)->tag != 20) { goto __ats_lab_110_0 ; } __ats_lab_107_1: __ats_lab_107_2: tmp369 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_0) ; tmp370 = ats_caselptrlab_mac(anairiats_sum_10, tmp265, atslab_1) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)tmp266)->tag != 20) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_0) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_10, tmp266, atslab_1) ; /* tmp373 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__refval_equal_solve_err (arg0, tmp369, tmp371, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp370, tmp372, arg3) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: tmp374 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp374 ; break ; } while (0) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp265)->tag != 26) { goto __ats_lab_113_0 ; } __ats_lab_110_1: __ats_lab_110_2: tmp375 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp376 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_1) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp266)->tag != 26) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp377 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_0) ; tmp378 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_1) ; /* tmp379 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp375, tmp377, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explstlst_equal_solve_err (arg0, tmp376, tmp378, arg3) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: tmp380 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp380 ; break ; } while (0) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp265)->tag != 28) { goto __ats_lab_116_0 ; } __ats_lab_113_1: __ats_lab_113_2: tmp381 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)tmp266)->tag != 28) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp382 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err (arg0, tmp381, tmp382, arg3) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: __ats_lab_115_1: tmp383 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp383 ; break ; } while (0) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp265)->tag != 29) { goto __ats_lab_122_0 ; } __ats_lab_116_1: __ats_lab_116_2: tmp384 = ats_caselptrlab_mac(anairiats_sum_5, tmp265, atslab_0) ; tmp385 = ats_caselptrlab_mac(anairiats_sum_5, tmp265, atslab_1) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_5, tmp265, atslab_2) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)tmp266)->tag != 29) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_5, tmp266, atslab_0) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_5, tmp266, atslab_1) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_5, tmp266, atslab_2) ; /* tmp390 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err (arg0, tmp384, tmp387, arg3) ; /* tmp391 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err (arg0, tmp385, tmp388, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err (arg0, tmp386, tmp389, arg3) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: if (((ats_sum_ptr_type)tmp266)->tag != 34) { goto __ats_lab_121_0 ; } __ats_lab_118_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; tmp398 = aux_41 (arg0, tmp386, arg3) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst (tmp398) ; tmp401 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__tyreckind_equal_solve_err (arg0, tmp384, tmp401, arg3) ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__pfarity_equal_solve_err (arg0, tmp385, 0, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp399, tmp392, arg3) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp403 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp403 ; break ; } while (0) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp265)->tag != 31) { goto __ats_lab_125_0 ; } __ats_lab_122_1: __ats_lab_122_2: tmp404 = ats_caselptrlab_mac(anairiats_sum_14, tmp265, atslab_0) ; tmp405 = ats_caselptrlab_mac(anairiats_sum_14, tmp265, atslab_1) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_14, tmp265, atslab_2) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp266)->tag != 31) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_14, tmp266, atslab_0) ; tmp408 = ats_caselptrlab_mac(anairiats_sum_14, tmp266, atslab_1) ; tmp409 = ats_caselptrlab_mac(anairiats_sum_14, tmp266, atslab_2) ; /* tmp410 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__stamp_equal_solve_err (arg0, tmp404, tmp407, arg3) ; /* tmp411 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp405, tmp408, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err (arg0, tmp406, tmp409, arg3) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: tmp412 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp412 ; break ; } while (0) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp265)->tag != 32) { goto __ats_lab_128_0 ; } __ats_lab_125_1: __ats_lab_125_2: tmp413 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; do { /* branch: __ats_lab_126 */ __ats_lab_126_0: if (((ats_sum_ptr_type)tmp266)->tag != 32) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp414 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; tmp415 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (tmp413, tmp414) ; if (tmp415) { /* empty */ } else { tmp416 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp416 ; } /* end of [if] */ break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: __ats_lab_127_1: tmp417 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp417 ; break ; } while (0) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)tmp265)->tag != 34) { goto __ats_lab_131_0 ; } __ats_lab_128_1: __ats_lab_128_2: tmp418 = ats_caselptrlab_mac(anairiats_sum_4, tmp265, atslab_0) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp266)->tag != 34) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp419 = ats_caselptrlab_mac(anairiats_sum_4, tmp266, atslab_0) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp418, tmp419, arg3) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: __ats_lab_130_1: tmp420 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp420 ; break ; } while (0) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp265)->tag != 35) { goto __ats_lab_134_0 ; } __ats_lab_131_1: __ats_lab_131_2: tmp421 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp422 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_1) ; do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp266)->tag != 35) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_0) ; tmp424 = ats_caselptrlab_mac(anairiats_sum_2, tmp266, atslab_1) ; /* tmp425 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp421, tmp423, arg3) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_tyleq_solve_err (arg0, tmp422, tmp424, arg3) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: __ats_lab_133_1: tmp426 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp426 ; break ; } while (0) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: __ats_lab_134_1: __ats_lab_134_2: tmp427 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp262, tmp263) ; if (!tmp427) { goto __ats_lab_135_2 ; } break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: __ats_lab_135_2: tmp428 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp428 ; break ; } while (0) ; tmp429 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg3), tmp261) ; if (tmp429) { tmp430 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp430)->tag = 0 ; ats_selptrset_mac(anairiats_sum_1, tmp430, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp430, atslab_1, tmp262) ; ats_selptrset_mac(anairiats_sum_1, tmp430, atslab_2, tmp263) ; /* tmp260 = */ the_staerrlst_add_2 (tmp430) ; } else { /* empty */ } /* end of [if] */ return /* (tmp260) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 29856(line=882, offs=7) -- 30236(line=891, offs=6) */ ATSstaticdec() ats_void_type aux_43 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; ATSlocal (ats_int_type, tmp438) ; ATSlocal (ats_int_type, tmp439) ; __ats_lab_aux_43: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_138_1 ; } __ats_lab_136_2: tmp433 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp434 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp435 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp437 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (env0, tmp433, tmp435, arg2) ; arg0 = tmp434 ; arg1 = tmp436 ; arg2 = arg2 ; goto __ats_lab_aux_43 ; // tail call break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_137_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_139_1 ; } __ats_lab_137_2: break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_2: tmp438 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp438 ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_2: tmp439 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp439 ; break ; } while (0) ; return /* (tmp432) */ ; } /* end of [aux_43] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_43_closure_type ; ats_void_type aux_43_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_43 (((aux_43_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_43_closure_init (aux_43_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_43_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_43_closure_make (ats_ptr_type env0) { aux_43_closure_type *p_clo = ATS_MALLOC(sizeof(aux_43_closure_type)) ; aux_43_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 29816(line=881, offs=3) -- 30287(line=894, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp431) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err: /* tmp431 = */ aux_43 (arg0, arg1, arg2, arg3) ; return /* (tmp431) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 30373(line=898, offs=3) -- 31278(line=922, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp440) ; ATSlocal (anairiats_rec_15, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_int_type, tmp447) ; // ATSlocal_void (tmp448) ; ATSlocal (ats_bool_type, tmp449) ; ATSlocal (ats_bool_type, tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err: do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_143_0 ; } __ats_lab_140_1: tmp441 = ats_caselptrlab_mac(anairiats_sum_16, arg3, atslab_0) ; tmp442 = ats_caselptrlab_mac(anairiats_sum_16, arg3, atslab_1) ; do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_142_0 ; } __ats_lab_141_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_142_1 ; } __ats_lab_141_2: tmp443 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp444 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp445 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp446 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp447 = ats_select_mac(tmp441, atslab_2) ; tmp449 = atspre_gt_int_int (tmp447, 0) ; if (tmp449) { /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp443, tmp445, arg4) ; } else { tmp450 = atspre_lt_int_int (tmp447, 0) ; if (tmp450) { /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp445, tmp443, arg4) ; } else { /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_err (arg0, tmp443, tmp445, arg4) ; } /* end of [if] */ } /* end of [if] */ arg0 = arg0 ; arg1 = tmp444 ; arg2 = tmp446 ; arg3 = tmp442 ; arg4 = arg4 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err ; // tail call break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: __ats_lab_142_1: __ats_lab_142_2: /* tmp451 = */ prerr_loc_interror_1 (arg0) ; /* tmp452 = */ atspre_prerr_string (ATSstrcst(": s2explst_tyleq_solve_argvarlst_err")) ; /* tmp453 = */ atspre_prerr_newline () ; /* tmp440 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_143_1: break ; } while (0) ; return /* (tmp440) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_argvarlst_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 31409(line=927, offs=7) -- 31948(line=938, offs=6) */ ATSstaticdec() ats_void_type aux_46 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; // ATSlocal_void (tmp462) ; // ATSlocal_void (tmp463) ; ATSlocal (ats_int_type, tmp464) ; ATSlocal (ats_int_type, tmp465) ; __ats_lab_aux_46: do { /* branch: __ats_lab_144 */ __ats_lab_144_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_145_0 ; } __ats_lab_144_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_146_1 ; } __ats_lab_144_2: tmp456 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp458 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; tmp459 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp460 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp461 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; /* tmp462 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__label_equal_solve_err (env0, tmp456, tmp459, arg2) ; /* tmp463 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (env0, tmp457, tmp460, arg2) ; arg0 = tmp458 ; arg1 = tmp461 ; arg2 = arg2 ; goto __ats_lab_aux_46 ; // tail call break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_146_0 ; } __ats_lab_145_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_147_1 ; } __ats_lab_145_2: break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_147_0 ; } __ats_lab_146_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_146_2: tmp464 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp464 ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_147_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_147_2: tmp465 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp465 ; break ; } while (0) ; return /* (tmp455) */ ; } /* end of [aux_46] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_46_closure_type ; ats_void_type aux_46_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_46 (((aux_46_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_46_closure_init (aux_46_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_46_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_46_closure_make (ats_ptr_type env0) { aux_46_closure_type *p_clo = ATS_MALLOC(sizeof(aux_46_closure_type)) ; aux_46_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 31367(line=926, offs=3) -- 32001(line=941, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp454) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err: /* tmp454 = */ aux_46 (arg0, arg1, arg2, arg3) ; return /* (tmp454) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__labs2explst_tyleq_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 32129(line=946, offs=7) -- 32880(line=962, offs=6) */ ATSstaticdec() ats_void_type aux_48 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; // ATSlocal_void (tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_int_type, tmp475) ; __ats_lab_aux_48: do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_149_0 ; } __ats_lab_148_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_151_1 ; } __ats_lab_148_2: tmp468 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp469 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp470 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; tmp471 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_2) ; /* tmp472 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (env0, tmp468, tmp470, arg2) ; arg0 = tmp469 ; arg1 = tmp471 ; arg2 = arg2 ; goto __ats_lab_aux_48 ; // tail call break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_150_0 ; } __ats_lab_149_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_151_1 ; } __ats_lab_149_2: tmp473 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp474 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; arg0 = tmp473 ; arg1 = tmp474 ; arg2 = arg2 ; goto __ats_lab_aux_48 ; // tail call break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_151_0 ; } __ats_lab_150_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_151_1 ; } __ats_lab_150_2: break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: __ats_lab_151_1: __ats_lab_151_2: tmp475 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp475 ; break ; } while (0) ; return /* (tmp467) */ ; } /* end of [aux_48] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_48_closure_type ; ats_void_type aux_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { aux_48 (((aux_48_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; return ; } /* end of function */ ATSinline() ats_void_type aux_48_closure_init (aux_48_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_48_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_48_closure_make (ats_ptr_type env0) { aux_48_closure_type *p_clo = ATS_MALLOC(sizeof(aux_48_closure_type)) ; aux_48_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 32083(line=945, offs=3) -- 32937(line=965, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_tyleq_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp466) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_tyleq_solve_err: /* tmp466 = */ aux_48 (arg0, arg1, arg2, arg3) ; return /* (tmp466) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__wths2explst_tyleq_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 33009(line=970, offs=17) -- 33380(line=984, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp476) ; ATSlocal (ats_int_type, tmp477) ; // ATSlocal_void (tmp478) ; ATSlocal (ats_bool_type, tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; // ATSlocal_void (tmp482) ; // ATSlocal_void (tmp483) ; // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve: /* ats_int_type tmp477 ; */ tmp477 = 0 ; /* tmp478 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err (arg0, arg1, arg2, (&tmp477)) ; tmp479 = atspre_gt_int_int (tmp477, 0) ; if (tmp479) { /* tmp480 = */ prerr_loc_error3_0 (arg0) ; /* tmp481 = */ atspre_prerr_string (ATSstrcst(": the computed effects [")) ; /* tmp482 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff (arg1) ; /* tmp483 = */ atspre_prerr_string (ATSstrcst("] does not match the expected effects [")) ; /* tmp484 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2eff (arg2) ; /* tmp485 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp486 = */ atspre_prerr_newline () ; /* tmp476 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp476) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 33440(line=987, offs=21) -- 34409(line=1019, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp487) ; ATSlocal (ats_int_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; // ATSlocal_void (tmp496) ; ATSlocal (ats_bool_type, tmp497) ; ATSlocal (ats_bool_type, tmp498) ; // ATSlocal_void (tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_int_type, tmp501) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err: do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_157_0 ; } __ats_lab_152_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_17, arg2, atslab_1) ; do { /* branch: __ats_lab_153 */ __ats_lab_153_0: if (tmp489 == (ats_sum_ptr_type)0) { goto __ats_lab_156_0 ; } tmp490 = ats_caselptrlab_mac(anairiats_sum_0, tmp489, atslab_1) ; if (tmp490 != (ats_sum_ptr_type)0) { goto __ats_lab_156_0 ; } __ats_lab_153_1: tmp491 = ats_caselptrlab_mac(anairiats_sum_0, tmp489, atslab_0) ; tmp492 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp491) ; tmp493 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp492), atslab_s2exp_node) ; do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp493)->tag != 33) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp494 = ats_caselptrlab_mac(anairiats_sum_4, tmp493, atslab_0) ; tmp495 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff (arg1) ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err (arg0, tmp494, tmp491, tmp495, arg3) ; tmp488 = 0 ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: __ats_lab_155_1: tmp488 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: __ats_lab_156_1: tmp488 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: __ats_lab_157_1: tmp488 = 1 ; break ; } while (0) ; tmp497 = atspre_gt_int_int (tmp488, 0) ; if (tmp497) { tmp498 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff (arg2, arg1) ; if (tmp498) { /* empty */ } else { tmp500 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp500)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp500, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp500, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp500, atslab_2, arg2) ; /* tmp499 = */ the_staerrlst_add_2 (tmp500) ; tmp501 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp501 ; } /* end of [if] */ } else { /* empty */ } /* end of [if] */ return /* (tmp487) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2eff_leq_solve_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 34468(line=1023, offs=5) -- 34812(line=1033, offs=17) */ ATSstaticdec() ats_void_type s2exp_tyleq_solve_lbs_err_51 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; // ATSlocal_void (tmp506) ; __ats_lab_s2exp_tyleq_solve_lbs_err_51: do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp505 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp503) ; /* tmp506 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, tmp505, arg2, arg3) ; arg0 = arg0 ; arg1 = tmp504 ; arg2 = arg2 ; arg3 = arg3 ; goto __ats_lab_s2exp_tyleq_solve_lbs_err_51 ; // tail call break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: break ; } while (0) ; return /* (tmp502) */ ; } /* end of [s2exp_tyleq_solve_lbs_err_51] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 34856(line=1036, offs=5) -- 35200(line=1046, offs=17) */ ATSstaticdec() ats_void_type s2exp_tyleq_solve_ubs_err_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ // ATSlocal_void (tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; // ATSlocal_void (tmp511) ; __ats_lab_s2exp_tyleq_solve_ubs_err_52: do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp508 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp509 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp508) ; /* tmp511 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, arg1, tmp510, arg3) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp509 ; arg3 = arg3 ; goto __ats_lab_s2exp_tyleq_solve_ubs_err_52 ; // tail call break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: break ; } while (0) ; return /* (tmp507) */ ; } /* end of [s2exp_tyleq_solve_ubs_err_52] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 35299(line=1053, offs=3) -- 37653(line=1118, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_int_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_bool_type, tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; // ATSlocal_void (tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; // ATSlocal_void (tmp526) ; // ATSlocal_void (tmp527) ; // ATSlocal_void (tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; // ATSlocal_void (tmp535) ; ATSlocal (ats_int_type, tmp536) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err: /* ats_ptr_type tmp513 ; */ tmp513 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp514 ; */ tmp514 = (ats_sum_ptr_type)0 ; tmp515 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs (arg1, arg3, (&tmp513), (&tmp514)) ; do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (tmp515 != 0) { goto __ats_lab_163_0 ; } __ats_lab_162_1: if (tmp513 != (ats_sum_ptr_type)0) { goto __ats_lab_163_1 ; } __ats_lab_162_2: if (tmp514 != (ats_sum_ptr_type)0) { goto __ats_lab_163_2 ; } __ats_lab_162_3: tmp516 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt (arg1) ; tmp517 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg3), atslab_s2exp_srt) ; tmp518 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp517, tmp516) ; if (tmp518) { /* tmp519 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_srt (arg1, tmp517) ; /* tmp520 = */ atsopt_s2exp_set_srt (arg2, tmp517) ; tmp522 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp522, atslab_0, arg3) ; /* tmp521 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_link (arg1, tmp522) ; tmp524 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg1) ; /* tmp523 = */ s2exp_tyleq_solve_lbs_err_51 (arg0, tmp524, arg3, arg4) ; tmp525 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (arg1) ; /* tmp512 = */ s2exp_tyleq_solve_ubs_err_52 (arg0, arg3, tmp525, arg4) ; } else { /* tmp526 = */ prerr_loc_error3_0 (arg0) ; /* tmp527 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s2exp_equal_solve_Var_err"), ATSstrcst("ats_staexp2_solve.dats")) ; /* tmp528 = */ atspre_prerr_string (ATSstrcst(": sort mismatch: the sort of [")) ; /* tmp529 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var (arg1) ; /* tmp530 = */ atspre_prerr_string (ATSstrcst("] is [")) ; /* tmp531 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp516) ; /* tmp532 = */ atspre_prerr_string (ATSstrcst("], but the sort of its solution is [")) ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp517) ; /* tmp534 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp535 = */ atspre_prerr_newline () ; tmp536 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp536 ; } /* end of [if] */ break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: __ats_lab_163_1: __ats_lab_163_2: __ats_lab_163_3: /* tmp512 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq (arg0, arg2, arg3) ; break ; } while (0) ; return /* (tmp512) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve_Var_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 37733(line=1122, offs=3) -- 39094(line=1161, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_l_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_int_type, tmp542) ; // ATSlocal_void (tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_l_err: tmp538 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg1) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (arg1) ; /* ats_ptr_type tmp540 ; */ tmp540 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp541 ; */ tmp541 = (ats_sum_ptr_type)0 ; tmp542 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs (arg1, arg3, (&tmp540), (&tmp541)) ; do { /* branch: __ats_lab_164 */ __ats_lab_164_0: if (tmp542 != 0) { goto __ats_lab_165_0 ; } __ats_lab_164_1: if (tmp540 != (ats_sum_ptr_type)0) { goto __ats_lab_165_1 ; } __ats_lab_164_2: if (tmp541 != (ats_sum_ptr_type)0) { goto __ats_lab_165_2 ; } __ats_lab_164_3: /* tmp543 = */ s2exp_tyleq_solve_lbs_err_51 (arg0, tmp538, arg3, arg4) ; tmp544 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make (arg0, arg3) ; tmp545 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp545, atslab_0, tmp544) ; ats_selptrset_mac(anairiats_sum_0, tmp545, atslab_1, tmp539) ; /* tmp537 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_ubs (arg1, tmp545) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: __ats_lab_165_1: __ats_lab_165_2: __ats_lab_165_3: /* tmp537 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq (arg0, arg2, arg3) ; break ; } while (0) ; return /* (tmp537) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_l_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 39176(line=1165, offs=3) -- 40506(line=1202, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_r_err (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_int_type, tmp551) ; // ATSlocal_void (tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_bool_type, tmp556) ; // ATSlocal_void (tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; // ATSlocal_void (tmp561) ; // ATSlocal_void (tmp562) ; // ATSlocal_void (tmp563) ; // ATSlocal_void (tmp564) ; // ATSlocal_void (tmp565) ; // ATSlocal_void (tmp566) ; ATSlocal (ats_int_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_r_err: tmp547 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg2) ; tmp548 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (arg2) ; /* ats_ptr_type tmp549 ; */ tmp549 = (ats_sum_ptr_type)0 ; /* ats_ptr_type tmp550 ; */ tmp550 = (ats_sum_ptr_type)0 ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs (arg2, arg1, (&tmp549), (&tmp550)) ; do { /* branch: __ats_lab_166 */ __ats_lab_166_0: if (tmp551 != 0) { goto __ats_lab_167_0 ; } __ats_lab_166_1: if (tmp549 != (ats_sum_ptr_type)0) { goto __ats_lab_167_1 ; } __ats_lab_166_2: if (tmp550 != (ats_sum_ptr_type)0) { goto __ats_lab_167_2 ; } __ats_lab_166_3: /* tmp552 = */ s2exp_tyleq_solve_ubs_err_52 (arg0, arg1, tmp548, arg4) ; tmp553 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_srt) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt (arg2) ; tmp556 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp553, tmp554) ; if (tmp556) { /* empty */ } else { /* tmp557 = */ prerr_loc_error3_0 (arg0) ; /* tmp558 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s2exp_equal_solve_Var_err"), ATSstrcst("ats_staexp2_solve.dats")) ; /* tmp559 = */ atspre_prerr_string (ATSstrcst(": sort mismatch: the sort of [s2V(")) ; /* tmp560 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var (arg2) ; /* tmp561 = */ atspre_prerr_string (ATSstrcst(")] is [")) ; /* tmp562 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp554) ; /* tmp563 = */ atspre_prerr_string (ATSstrcst("], but the sort of its lower bound is [")) ; /* tmp564 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp553) ; /* tmp565 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp566 = */ atspre_prerr_newline () ; tmp567 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp567 ; } /* end of [if] */ tmp568 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make (arg0, arg1) ; tmp569 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp569, atslab_0, tmp568) ; ats_selptrset_mac(anairiats_sum_0, tmp569, atslab_1, tmp547) ; /* tmp546 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_lbs (arg2, tmp569) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: __ats_lab_167_1: __ats_lab_167_2: __ats_lab_167_3: /* tmp546 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq (arg0, arg1, arg3) ; break ; } while (0) ; return /* (tmp546) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_Var_r_err] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 40599(line=1208, offs=3) -- 40813(line=1215, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp570) ; ATSlocal (ats_int_type, tmp571) ; // ATSlocal_void (tmp572) ; ATSlocal (ats_bool_type, tmp573) ; // ATSlocal_void (tmp574) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve: /* ats_int_type tmp571 ; */ tmp571 = 0 ; /* tmp572 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve_err (arg0, arg1, arg2, (&tmp571)) ; tmp573 = atspre_gt_int_int (tmp571, 0) ; if (tmp573) { /* tmp574 = */ prerr_the_staerrlst_9 () ; /* tmp570 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp570) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 40918(line=1219, offs=7) -- 41250(line=1228, offs=19) */ ATSstaticdec() ats_void_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; // ATSlocal_void (tmp582) ; __ats_lab_aux_58: do { /* branch: __ats_lab_168 */ __ats_lab_168_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp577 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp578 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp579 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp580 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg (tmp579) ; /* tmp582 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp577, tmp581) ; arg0 = arg0 ; arg1 = tmp578 ; arg2 = tmp580 ; goto __ats_lab_aux_58 ; // tail call break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_169_1: break ; } while (0) ; return /* (tmp576) */ ; } /* end of [aux_58] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 40883(line=1218, offs=26) -- 41815(line=1245, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_arg_tyleq_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp575) ; ATSlocal (ats_int_type, tmp583) ; // ATSlocal_void (tmp584) ; ATSlocal (ats_bool_type, tmp585) ; // ATSlocal_void (tmp586) ; // ATSlocal_void (tmp587) ; // ATSlocal_void (tmp588) ; ATSlocal (ats_bool_type, tmp589) ; // ATSlocal_void (tmp590) ; ATSlocal (ats_bool_type, tmp591) ; // ATSlocal_void (tmp592) ; // ATSlocal_void (tmp593) ; ATSlocal (ats_bool_type, tmp594) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_arg_tyleq_solve: tmp583 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (arg1, arg2) ; tmp585 = atspre_ineq (tmp583, 0) ; if (tmp585) { /* tmp586 = */ prerr_loc_error3_0 (arg0) ; /* tmp587 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s2exp_arg_tyleq_solve"), ATSstrcst("ats_staexp2_solve.dats")) ; tmp589 = atspre_igt (tmp583, 0) ; if (tmp589) { /* tmp588 = */ atspre_prerr_string (ATSstrcst(": this function call needs more arguments.")) ; } else { /* empty */ } /* end of [if] */ tmp591 = atspre_ilt (tmp583, 0) ; if (tmp591) { /* tmp590 = */ atspre_prerr_string (ATSstrcst(": this function call needs fewer arguments.")) ; } else { /* empty */ } /* end of [if] */ /* tmp592 = */ atspre_prerr_newline () ; /* tmp593 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp594 = atspre_ieq (tmp583, 0) ; /* tmp584 = */ atspre_assert (tmp594) ; } else { /* empty */ } /* end of [if] */ /* tmp575 = */ aux_58 (arg0, arg1, arg2) ; return /* (tmp575) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_arg_tyleq_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 42171(line=1258, offs=7) -- 42490(line=1264, offs=19) */ ATSstaticdec() ats_void_type aux_solve_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; // ATSlocal_void (tmp603) ; __ats_lab_aux_solve_60: tmp597 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_node) ; tmp598 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg2), atslab_s2exp_node) ; do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp597)->tag != 0) { goto __ats_lab_171_0 ; } __ats_lab_170_1: if (((ats_sum_ptr_type)tmp598)->tag != 0) { goto __ats_lab_171_1 ; } __ats_lab_170_2: tmp599 = ats_caselptrlab_mac(anairiats_sum_2, tmp597, atslab_0) ; tmp600 = ats_caselptrlab_mac(anairiats_sum_2, tmp597, atslab_1) ; tmp601 = ats_caselptrlab_mac(anairiats_sum_2, tmp598, atslab_0) ; tmp602 = ats_caselptrlab_mac(anairiats_sum_2, tmp598, atslab_1) ; /* tmp603 = */ aux_solve_60 (arg0, tmp599, tmp601) ; /* tmp596 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve (arg0, tmp600, tmp602) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: __ats_lab_171_1: __ats_lab_171_2: break ; } while (0) ; return /* (tmp596) */ ; } /* end of [aux_solve_60] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 42497(line=1265, offs=7) -- 42744(line=1269, offs=22) */ ATSstaticdec() ats_bool_type aux_check_61 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; __ats_lab_aux_check_61: tmp605 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_s2exp_node) ; tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp605)->tag != 4) { goto __ats_lab_173_0 ; } __ats_lab_172_1: if (((ats_sum_ptr_type)tmp606)->tag != 4) { goto __ats_lab_174_1 ; } __ats_lab_172_2: tmp607 = ats_caselptrlab_mac(anairiats_sum_4, tmp605, atslab_0) ; tmp608 = ats_caselptrlab_mac(anairiats_sum_4, tmp606, atslab_0) ; tmp604 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp607, tmp608) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp605)->tag != 0) { goto __ats_lab_174_0 ; } __ats_lab_173_1: if (((ats_sum_ptr_type)tmp606)->tag != 0) { goto __ats_lab_174_1 ; } __ats_lab_173_2: tmp609 = ats_caselptrlab_mac(anairiats_sum_2, tmp605, atslab_0) ; tmp610 = ats_caselptrlab_mac(anairiats_sum_2, tmp606, atslab_0) ; arg0 = tmp609 ; arg1 = tmp610 ; goto __ats_lab_aux_check_61 ; // tail call break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: __ats_lab_174_1: __ats_lab_174_2: tmp604 = ats_false_bool ; break ; } while (0) ; return (tmp604) ; } /* end of [aux_check_61] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 41878(line=1249, offs=4) -- 42947(line=1276, offs=4) */ ATSstaticdec() ats_void_type s2exp_hypo_equal_solve_con_59 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp595) ; ATSlocal (ats_bool_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; __ats_lab_s2exp_hypo_equal_solve_con_59: tmp611 = aux_check_61 (arg1, arg2) ; if (tmp611) { /* tmp595 = */ aux_solve_60 (arg0, arg1, arg2) ; } else { tmp612 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; /* tmp595 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, tmp612) ; } /* end of [if] */ return /* (tmp595) */ ; } /* end of [s2exp_hypo_equal_solve_con_59] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 43023(line=1280, offs=3) -- 45224(line=1345, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_bool_type, tmp618) ; ATSlocal (ats_bool_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_bool_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_int_type, tmp625) ; ATSlocal (ats_bool_type, tmp626) ; ATSlocal (ats_bool_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; // ATSlocal_void (tmp634) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve: tmp614 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp615 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp616 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp614), atslab_s2exp_node) ; tmp617 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp615), atslab_s2exp_node) ; do { /* branch: __ats_lab_175 */ __ats_lab_175_0: __ats_lab_175_1: __ats_lab_175_2: tmp619 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon (tmp614) ; if (tmp619) { tmp618 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon (tmp615) ; } else { tmp618 = ats_false_bool ; } /* end of [if] */ if (!tmp618) { goto __ats_lab_176_0 ; } /* tmp613 = */ s2exp_hypo_equal_solve_con_59 (arg0, tmp614, tmp615) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp616)->tag != 4) { goto __ats_lab_177_0 ; } __ats_lab_176_1: if (((ats_sum_ptr_type)tmp617)->tag != 4) { goto __ats_lab_182_1 ; } __ats_lab_176_2: tmp620 = ats_caselptrlab_mac(anairiats_sum_4, tmp616, atslab_0) ; tmp621 = ats_caselptrlab_mac(anairiats_sum_4, tmp617, atslab_0) ; tmp622 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp620, tmp621) ; if (!tmp622) { goto __ats_lab_184_2 ; } break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp616)->tag != 32) { goto __ats_lab_181_0 ; } __ats_lab_177_1: if (((ats_sum_ptr_type)tmp617)->tag != 32) { goto __ats_lab_181_1 ; } __ats_lab_177_2: tmp623 = ats_caselptrlab_mac(anairiats_sum_4, tmp616, atslab_0) ; tmp624 = ats_caselptrlab_mac(anairiats_sum_4, tmp617, atslab_0) ; tmp625 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (tmp623, tmp624) ; do { /* branch: __ats_lab_178 */ __ats_lab_178_0: __ats_lab_178_1: tmp626 = atspre_igt (tmp625, 0) ; if (!tmp626) { goto __ats_lab_179_1 ; } /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (arg0, tmp623, tmp615) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: __ats_lab_179_1: tmp627 = atspre_ilt (tmp625, 0) ; if (!tmp627) { goto __ats_lab_180_1 ; } /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (arg0, tmp624, tmp614) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: __ats_lab_180_1: break ; } while (0) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp616)->tag != 32) { goto __ats_lab_182_0 ; } __ats_lab_181_1: __ats_lab_181_2: tmp628 = ats_caselptrlab_mac(anairiats_sum_4, tmp616, atslab_0) ; /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (arg0, tmp628, tmp615) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: __ats_lab_182_1: if (((ats_sum_ptr_type)tmp617)->tag != 32) { goto __ats_lab_183_0 ; } __ats_lab_182_2: tmp629 = ats_caselptrlab_mac(anairiats_sum_4, tmp617, atslab_0) ; /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (arg0, tmp629, tmp614) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: if (((ats_sum_ptr_type)tmp616)->tag != 11) { goto __ats_lab_184_0 ; } __ats_lab_183_1: if (((ats_sum_ptr_type)tmp617)->tag != 11) { goto __ats_lab_184_1 ; } __ats_lab_183_2: tmp630 = ats_caselptrlab_mac(anairiats_sum_12, tmp616, atslab_4) ; tmp631 = ats_caselptrlab_mac(anairiats_sum_12, tmp616, atslab_5) ; tmp632 = ats_caselptrlab_mac(anairiats_sum_12, tmp617, atslab_4) ; tmp633 = ats_caselptrlab_mac(anairiats_sum_12, tmp617, atslab_5) ; /* tmp634 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve (arg0, tmp632, tmp630) ; arg0 = arg0 ; arg1 = tmp631 ; arg2 = tmp633 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve ; // tail call break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: __ats_lab_184_1: __ats_lab_184_2: /* tmp613 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp614, tmp615) ; break ; } while (0) ; return /* (tmp613) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_solve.dats: 45299(line=1349, offs=3) -- 45672(line=1359, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; // ATSlocal_void (tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve: do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_186_0 ; } __ats_lab_185_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_187_1 ; } __ats_lab_185_2: tmp636 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp637 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp638 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp639 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; /* tmp640 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp636, tmp638) ; arg0 = arg0 ; arg1 = tmp637 ; arg2 = tmp639 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve ; // tail call break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_186_1: if (arg2 != (ats_sum_ptr_type)0) { goto __ats_lab_187_1 ; } __ats_lab_186_2: break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: __ats_lab_187_1: __ats_lab_187_2: tmp641 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; /* tmp635 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, tmp641) ; break ; } while (0) ; return /* (tmp635) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_hypo_equal_solve] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_tyleq_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_equal_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_funclo_equal_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2eff_leq_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__STAERR_s2exp_linearity_4.tag = 4 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ /* ats_ptr_type statmp4 ; */ statmp4 = (ats_sum_ptr_type)0 ; /* statmp5 = */ atspre_vbox_make_view_ptr ((&statmp4)) ; /* statmp6 = ats_selsin_mac(statmp5, atslab_1) */ ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_solve_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans1_sta_dats.c0000664000175000017500000055662112223166160022215 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_e0xp_loc ; ats_ptr_type atslab_e0xp_node ; } anairiats_rec_10 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_s1rt_loc ; ats_ptr_type atslab_s1rt_node ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_s0rt_loc ; ats_ptr_type atslab_s0rt_node ; } anairiats_rec_13 ; typedef struct { ats_ptr_type atslab_s0rtpol_loc ; ats_ptr_type atslab_s0rtpol_srt ; ats_int_type atslab_s0rtpol_pol ; } anairiats_rec_14 ; typedef struct { ats_ptr_type atslab_d0atarg_loc ; ats_ptr_type atslab_d0atarg_node ; } anairiats_rec_15 ; typedef struct { int tag ; ats_double_type atslab_0 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_s0tacon_fil ; ats_ptr_type atslab_s0tacon_loc ; ats_ptr_type atslab_s0tacon_sym ; ats_ptr_type atslab_s0tacon_arg ; ats_ptr_type atslab_s0tacon_def ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_s0tacst_fil ; ats_ptr_type atslab_s0tacst_loc ; ats_ptr_type atslab_s0tacst_sym ; ats_ptr_type atslab_s0tacst_arg ; ats_ptr_type atslab_s0tacst_res ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_s0tavar_loc ; ats_ptr_type atslab_s0tavar_sym ; ats_ptr_type atslab_s0tavar_srt ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_d0atsrtcon_loc ; ats_ptr_type atslab_d0atsrtcon_sym ; ats_ptr_type atslab_d0atsrtcon_arg ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_d0atsrtdec_loc ; ats_ptr_type atslab_d0atsrtdec_sym ; ats_ptr_type atslab_d0atsrtdec_con ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_s0arg_loc ; ats_ptr_type atslab_s0arg_sym ; ats_ptr_type atslab_s0arg_srt ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_sp0at_loc ; ats_ptr_type atslab_sp0at_node ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_sqi0de_loc ; ats_ptr_type atslab_sqi0de_qua ; ats_ptr_type atslab_sqi0de_sym ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_25 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_26 ; typedef struct { ats_ptr_type atslab_s0qua_loc ; ats_ptr_type atslab_s0qua_node ; } anairiats_rec_27 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_28 ; typedef struct { ats_ptr_type atslab_s0exp_loc ; ats_ptr_type atslab_s0exp_node ; } anairiats_rec_29 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_clo_ref_type atslab_1 ; } anairiats_sum_30 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_clo_ref_type atslab_2 ; } anairiats_sum_31 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_32 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_33 ; typedef struct { ats_ptr_type atslab_l0ab_loc ; ats_ptr_type atslab_l0ab_lab ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_s0rtext_loc ; ats_ptr_type atslab_s0rtext_node ; } anairiats_rec_35 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_36 ; typedef struct { ats_ptr_type atslab_s0rtdef_loc ; ats_ptr_type atslab_s0rtdef_sym ; ats_ptr_type atslab_s0rtdef_def ; } anairiats_rec_37 ; typedef struct { ats_ptr_type atslab_s0expdef_loc ; ats_ptr_type atslab_s0expdef_sym ; ats_ptr_type atslab_s0expdef_loc_id ; ats_ptr_type atslab_s0expdef_arg ; ats_ptr_type atslab_s0expdef_res ; ats_ptr_type atslab_s0expdef_def ; } anairiats_rec_38 ; typedef struct { ats_ptr_type atslab_s0aspdec_fil ; ats_ptr_type atslab_s0aspdec_loc ; ats_ptr_type atslab_s0aspdec_qid ; ats_ptr_type atslab_s0aspdec_arg ; ats_ptr_type atslab_s0aspdec_res ; ats_ptr_type atslab_s0aspdec_def ; } anairiats_rec_39 ; typedef struct { ats_ptr_type atslab_d0atcon_loc ; ats_ptr_type atslab_d0atcon_sym ; ats_ptr_type atslab_d0atcon_qua ; ats_ptr_type atslab_d0atcon_arg ; ats_ptr_type atslab_d0atcon_ind ; } anairiats_rec_40 ; typedef struct { ats_ptr_type atslab_d0atdec_fil ; ats_ptr_type atslab_d0atdec_loc ; ats_ptr_type atslab_d0atdec_headloc ; ats_ptr_type atslab_d0atdec_sym ; ats_ptr_type atslab_d0atdec_arg ; ats_ptr_type atslab_d0atdec_con ; } anairiats_rec_41 ; typedef struct { ats_ptr_type atslab_e0xndec_fil ; ats_ptr_type atslab_e0xndec_loc ; ats_ptr_type atslab_e0xndec_sym ; ats_ptr_type atslab_e0xndec_qua ; ats_ptr_type atslab_e0xndec_arg ; } anairiats_rec_42 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMatm_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ITEMopr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERinf_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpre_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__OPERpos_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECint_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECide_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECinc_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPeval_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPfloat_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPide_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPlist_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPstring_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTide_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTqid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTlist_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTtup_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGidsrt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SP0Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAvars_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Echar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eexi_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eextype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eide_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eimp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eint_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elam_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist2_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eopide_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eqid_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyarr_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_ext_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup2_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Euni_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eunion_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYinf_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpre_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpos_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEprop_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEtype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALchar_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALfloat_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALstring_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALcstsp_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEprop_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEtype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEviewtype_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_prerr_char) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_eq_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_void_type, atspre_prerr_double) (ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_empty) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARKBANG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exi_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__uni_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmark_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmarkbang_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__r0ead_prec_sta) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__trans_prec_sta) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int) (ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_inc) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_dec) (ats_int_type, ats_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_non) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_inf) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pre) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pos) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_get_prec) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app) (ats_clo_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash) (ats_ptr_type, ats_clo_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make) (ats_ptr_type, ats_clo_ref_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_tup) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtpol_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_idsrt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1arg_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__sp1at_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_exi) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_extype) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_lam) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_read) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_trans) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyarr) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec_ext) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup2) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_union) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_sub) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_vars) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtcon_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1rtdef_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacon_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacst_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tavar_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1expdef_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1aspdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atcon_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atdec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__e1xndec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_make_v1al) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xplst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_int_type prec_tr_errmsg_2 (ats_ptr_type arg0) ; static ats_int_type precfnd_4 (ats_ptr_type arg0) ; static ats_int_type p0rec_tr_3 (ats_ptr_type arg0) ; static ats_ptr_type f0xty_tr_5 (ats_ptr_type arg0) ; static ats_ptr_type f_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_6_closure_make () ; static ats_ptr_type f_6_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_8 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_9_closure_make () ; static ats_ptr_type __ats_fun_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type e1xp_make_opr_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_10 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_11_closure_make () ; static ats_ptr_type __ats_fun_11_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type e0xp_tr_errmsg_opr_12 (ats_ptr_type arg0) ; static ats_ptr_type aux_item_14 (ats_ptr_type arg0) ; static ats_ptr_type loop_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_itemlst_15 (ats_ptr_type arg0) ; static ats_ptr_type f_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_18_closure_make () ; static ats_ptr_type f_18_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_20 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_21_closure_make () ; static ats_ptr_type __ats_fun_21_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s1rt_make_opr_19 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_22 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_23_closure_make () ; static ats_ptr_type __ats_fun_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s0rt_tr_errmsg_opr_24 (ats_ptr_type arg0) ; static ats_ptr_type aux_item_26 (ats_ptr_type arg0) ; static ats_ptr_type loop_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_itemlst_27 (ats_ptr_type arg0) ; static ats_ptr_type s0rtpol_tr_31 (ats_ptr_type arg0) ; static ats_ptr_type s0rtpol_srt_tr_32 (ats_ptr_type arg0) ; static ats_ptr_type d0atarg_tr_33 (ats_ptr_type arg0) ; static ats_ptr_type d0atarglst_tr_34 (ats_ptr_type arg0) ; static ats_ptr_type d0atarglst_srtlst_tr_35 (ats_ptr_type arg0) ; static ats_void_type loop_37 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_39 (ats_ptr_type arg0) ; static ats_ptr_type d0atsrtcon_tr_49 (ats_ptr_type arg0) ; static ats_ptr_type d0atsrtconlst_tr_50 (ats_ptr_type arg0) ; static ats_ptr_type s0arg_tr_53 (ats_ptr_type arg0) ; static ats_ptr_type f_57 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_57_closure_make () ; static ats_ptr_type f_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_59 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_60_closure_make () ; static ats_ptr_type __ats_fun_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s1exp_make_opr_58 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_61 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_62 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_clo_ptr_type __ats_fun_62_closure_make () ; static ats_ptr_type __ats_fun_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type s0qua_tr_63 (ats_ptr_type arg0) ; static ats_ptr_type s0exp_tr_errmsg_opr_66 (ats_ptr_type arg0) ; static ats_ptr_type f_70 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type f_70_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) ; static ats_ptr_type f_70_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type loop_71 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type f_72 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_72_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_72_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_73 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_73_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_73_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_74 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_74_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_74_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_75 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_75_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_75_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_76 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type f_76_closure_make () ; static ats_ptr_type f_76_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type f_77 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type f_77_closure_make (ats_ptr_type env0) ; static ats_ptr_type f_77_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f_78 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type f_78_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type f_78_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_item_68 (ats_ptr_type arg0) ; static ats_ptr_type loop_79 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_itemlst_69 (ats_ptr_type arg0) ; static ats_ptr_type d0atcon_tr_92 (ats_ptr_type arg0) ; static ats_ptr_type d0atconlst_tr_93 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp45) ; ATSstatic (ats_ptr_type, statmp49) ; ATSstatic (ats_ptr_type, statmp109) ; ATSstatic (ats_ptr_type, statmp113) ; ATSstatic (ats_ptr_type, statmp303) ; ATSstatic (ats_ptr_type, statmp307) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 2498(line=88, offs=4) -- 2583(line=89, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error1_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error1_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error1_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 2617(line=92, offs=4) -- 2682(line=92, offs=69) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans1_sta)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 2715(line=98, offs=4) -- 2914(line=106, offs=4) */ ATSstaticdec() ats_int_type prec_tr_errmsg_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp3) ; // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; __ats_lab_prec_tr_errmsg_2: tmp5 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_loc) ; /* tmp4 = */ prerr_loc_error1_0 (tmp5) ; /* tmp6 = */ atspre_prerr_string (ATSstrcst(": the operator [")) ; tmp8 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp8) ; /* tmp9 = */ atspre_prerr_string (ATSstrcst("] is given no fixity")) ; /* tmp10 = */ atspre_prerr_newline () ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp3) ; } /* end of [prec_tr_errmsg_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 3008(line=111, offs=7) -- 3527(line=128, offs=6) */ ATSstaticdec() ats_int_type precfnd_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; __ats_lab_precfnd_4: tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_i0de_sym) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp14) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp13 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_0_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_2, tmp13, atslab_0) ; ATS_FREE(tmp13) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_get_prec (tmp15) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp16 == (ats_sum_ptr_type)0) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_0) ; ATS_FREE(tmp16) ; tmp12 = tmp17 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: // if (tmp16 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_2_1: tmp12 = prec_tr_errmsg_2 (arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp13 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp12 = prec_tr_errmsg_2 (arg0) ; break ; } while (0) ; return (tmp12) ; } /* end of [precfnd_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 2967(line=110, offs=4) -- 3769(line=135, offs=4) */ ATSstaticdec() ats_int_type p0rec_tr_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_int_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; __ats_lab_p0rec_tr_3: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp11 = precfnd_4 (tmp18) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp11 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__prec_make_int (tmp19) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp22 = precfnd_4 (tmp20) ; tmp11 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_inc (tmp22, tmp21) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp25 = precfnd_4 (tmp23) ; tmp11 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__precedence_dec (tmp25, tmp24) ; break ; } while (0) ; return (tmp11) ; } /* end of [p0rec_tr_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 3839(line=141, offs=4) -- 4101(line=146, offs=66) */ ATSstaticdec() ats_ptr_type f0xty_tr_5 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_int_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_int_type, tmp33) ; __ats_lab_f0xty_tr_5: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp27 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; tmp29 = p0rec_tr_3 (tmp27) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_inf (tmp29, tmp28) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp31 = p0rec_tr_3 (tmp30) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pre (tmp31) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp33 = p0rec_tr_3 (tmp32) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_pos (tmp33) ; break ; } while (0) ; return (tmp26) ; } /* end of [f0xty_tr_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 4253(line=156, offs=4) -- 4639(line=169, offs=4) */ ATSstaticdec() ats_ptr_type f_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_f_6: tmp36 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_e1xp_loc) ; tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_e1xp_loc) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp36, tmp37) ; tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_e1xp_node) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp39)->tag != 5) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_4, tmp39, atslab_0) ; tmp38 = tmp40 ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: __ats_lab_12_1: tmp38 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp38, atslab_0, arg1) ; tmp41 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_9, tmp38), atslab_1) ; tmp42 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp41) = tmp42 ; break ; } while (0) ; tmp44 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_e1xp_loc) ; tmp43 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app (tmp35, arg0, tmp44, tmp38) ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp34)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp34, atslab_0, tmp43) ; return (tmp34) ; } /* end of [f_6] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_6_closure_type ; ats_ptr_type f_6_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_6 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_6_closure_init (f_6_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_6_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_6_closure_make () { f_6_closure_type *p_clo = ATS_MALLOC(sizeof(f_6_closure_type)) ; f_6_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 4809(line=178, offs=5) -- 4828(line=178, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; __ats_lab___ats_fun_8: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_e1xp_loc) ; return (tmp47) ; } /* end of [__ats_fun_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 4834(line=179, offs=5) -- 4893(line=179, offs=64) */ ATSstaticdec() ats_ptr_type __ats_fun_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; __ats_lab___ats_fun_9: tmp48 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app (arg0, arg1, arg2, arg3) ; return (tmp48) ; } /* end of [__ats_fun_9] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_9_closure_type ; ats_ptr_type __ats_fun_9_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_9 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_9_closure_init (__ats_fun_9_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_9_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_9_closure_make () { __ats_fun_9_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_9_closure_type)) ; __ats_fun_9_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 4727(line=175, offs=4) -- 4929(line=181, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_make_opr_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_e1xp_make_opr_7: tmp46 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (&__ats_fun_8, __ats_fun_9_closure_make (), arg0, arg1) ; return (tmp46) ; } /* end of [e1xp_make_opr_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 5035(line=185, offs=5) -- 5054(line=185, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; __ats_lab___ats_fun_10: tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_e1xp_loc) ; return (tmp50) ; } /* end of [__ats_fun_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 5060(line=186, offs=5) -- 5119(line=186, offs=64) */ ATSstaticdec() ats_ptr_type __ats_fun_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; __ats_lab___ats_fun_11: tmp51 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_app (arg0, arg1, arg2, arg3) ; return (tmp51) ; } /* end of [__ats_fun_11] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_11_closure_type ; ats_ptr_type __ats_fun_11_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_11 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_11_closure_init (__ats_fun_11_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_11_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_11_closure_make () { __ats_fun_11_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_11_closure_type)) ; __ats_fun_11_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 5222(line=194, offs=4) -- 5414(line=201, offs=4) */ ATSstaticdec() ats_ptr_type e0xp_tr_errmsg_opr_12 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; __ats_lab_e0xp_tr_errmsg_opr_12: /* tmp53 = */ prerr_loc_error1_0 (arg0) ; /* tmp54 = */ atspre_prerr_string (ATSstrcst(": the operator needs to be applied.")) ; /* tmp55 = */ atspre_prerr_newline () ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp52) ; } /* end of [e0xp_tr_errmsg_opr_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 5508(line=207, offs=7) -- 6693(line=235, offs=6) */ ATSstaticdec() ats_ptr_type aux_item_14 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_char_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_bool_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_aux_item_14: tmp58 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_e0xp_loc) ; tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_e0xp_node) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp59)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp60 = aux_itemlst_15 (arg0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (tmp58, statmp45, tmp60) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp61) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp59)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_11, tmp59, atslab_0) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char (tmp58, tmp62) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp63) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp59)->tag != 2) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp65 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (tmp64) ; tmp66 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (tmp65) ; tmp67 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_make_v1al (tmp58, tmp66) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp67) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp59)->tag != 3) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float (tmp58, tmp68) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp69) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp59)->tag != 4) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp71 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp70, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; if (!tmp71) { goto __ats_lab_18_1 ; } tmp57 = statmp49 ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp59)->tag != 4) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp73 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp72) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp73 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_2, tmp73, atslab_0) ; ATS_FREE(tmp73) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide (tmp58, tmp72) ; tmp57 = e1xp_make_opr_7 (tmp75, tmp74) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (tmp73 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_ide (tmp58, tmp72) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp76) ; break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp59)->tag != 5) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int (tmp58, tmp77) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp78) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp59)->tag != 6) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp81 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xplst_tr (tmp79) ; tmp80 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_list (tmp58, tmp81) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp80) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp59)->tag != 7) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_6, tmp59, atslab_0) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_6, tmp59, atslab_1) ; tmp84 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string (tmp58, tmp82, tmp83) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp84) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (((ats_sum_ptr_type)tmp59)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_4, tmp59, atslab_0) ; tmp86 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp (tmp58, tmp85) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp57)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp57, atslab_0, tmp86) ; break ; } while (0) ; return (tmp57) ; } /* end of [aux_item_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 6773(line=238, offs=9) -- 7010(line=243, offs=32) */ ATSstaticdec() ats_ptr_type loop_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_loop_16: tmp89 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_e0xp_node) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp89)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_7, tmp89, atslab_0) ; tmp91 = ats_caselptrlab_mac(anairiats_sum_7, tmp89, atslab_1) ; tmp93 = aux_item_14 (tmp91) ; tmp92 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp92, atslab_0, tmp93) ; ats_selptrset_mac(anairiats_sum_9, tmp92, atslab_1, arg0) ; arg0 = tmp92 ; arg1 = tmp90 ; goto __ats_lab_loop_16 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp94 = aux_item_14 (arg1) ; tmp88 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp88, atslab_0, tmp94) ; ats_selptrset_mac(anairiats_sum_9, tmp88, atslab_1, arg0) ; break ; } while (0) ; return (tmp88) ; } /* end of [loop_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 6724(line=237, offs=7) -- 7064(line=247, offs=6) */ ATSstaticdec() ats_ptr_type aux_itemlst_15 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_aux_itemlst_15: tmp95 = (ats_sum_ptr_type)0 ; tmp87 = loop_16 (tmp95, arg0) ; return (tmp87) ; } /* end of [aux_itemlst_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 5488(line=205, offs=19) -- 7219(line=254, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr: tmp96 = aux_item_14 (arg0) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp96)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_4, tmp96, atslab_0) ; tmp56 = tmp97 ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (((ats_sum_ptr_type)tmp96)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp98 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_e0xp_loc) ; tmp56 = e0xp_tr_errmsg_opr_12 (tmp98) ; break ; } while (0) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 7285(line=258, offs=22) -- 7323(line=258, offs=60) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xplst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xplst_tr: tmp99 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xp_tr) ; return (tmp99) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xplst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 7484(line=268, offs=6) -- 7806(line=277, offs=6) */ ATSstaticdec() ats_ptr_type f_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_f_18: tmp102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_s1rt_loc) ; tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_s1rt_loc) ; tmp101 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp102, tmp103) ; tmp105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_s1rt_node) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp105)->tag != 1) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_4, tmp105, atslab_0) ; tmp104 = tmp106 ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp107 = (ats_sum_ptr_type)0 ; tmp104 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp104, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp104, atslab_1, tmp107) ; break ; } while (0) ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app (tmp101, arg0, tmp104) ; tmp100 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp100)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp100, atslab_0, tmp108) ; return (tmp100) ; } /* end of [f_18] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_18_closure_type ; ats_ptr_type f_18_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_18 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_18_closure_init (f_18_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_18_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_18_closure_make () { f_18_closure_type *p_clo = ATS_MALLOC(sizeof(f_18_closure_type)) ; f_18_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 7963(line=285, offs=5) -- 7982(line=285, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; __ats_lab___ats_fun_20: tmp111 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_s1rt_loc) ; return (tmp111) ; } /* end of [__ats_fun_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 7988(line=286, offs=5) -- 8043(line=286, offs=60) */ ATSstaticdec() ats_ptr_type __ats_fun_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; __ats_lab___ats_fun_21: tmp112 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app (arg0, arg1, arg3) ; return (tmp112) ; } /* end of [__ats_fun_21] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_21_closure_type ; ats_ptr_type __ats_fun_21_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_21 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_21_closure_init (__ats_fun_21_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_21_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_21_closure_make () { __ats_fun_21_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_21_closure_type)) ; __ats_fun_21_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 7879(line=282, offs=5) -- 8081(line=288, offs=4) */ ATSstaticdec() ats_ptr_type s1rt_make_opr_19 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_s1rt_make_opr_19: tmp110 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (&__ats_fun_20, __ats_fun_21_closure_make (), arg0, arg1) ; return (tmp110) ; } /* end of [s1rt_make_opr_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 8189(line=292, offs=5) -- 8208(line=292, offs=24) */ ATSstaticdec() ats_ptr_type __ats_fun_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp114) ; __ats_lab___ats_fun_22: tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_s1rt_loc) ; return (tmp114) ; } /* end of [__ats_fun_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 8214(line=293, offs=5) -- 8269(line=293, offs=60) */ ATSstaticdec() ats_ptr_type __ats_fun_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp115) ; __ats_lab___ats_fun_23: tmp115 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_app (arg0, arg1, arg3) ; return (tmp115) ; } /* end of [__ats_fun_23] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_23_closure_type ; ats_ptr_type __ats_fun_23_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_23 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_23_closure_init (__ats_fun_23_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_23_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_23_closure_make () { __ats_fun_23_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_23_closure_type)) ; __ats_fun_23_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 8372(line=301, offs=4) -- 8564(line=308, offs=4) */ ATSstaticdec() ats_ptr_type s0rt_tr_errmsg_opr_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; __ats_lab_s0rt_tr_errmsg_opr_24: /* tmp117 = */ prerr_loc_error1_0 (arg0) ; /* tmp118 = */ atspre_prerr_string (ATSstrcst(": the operator needs to be applied.")) ; /* tmp119 = */ atspre_prerr_newline () ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp116) ; } /* end of [s0rt_tr_errmsg_opr_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 8658(line=314, offs=5) -- 9437(line=331, offs=4) */ ATSstaticdec() ats_ptr_type aux_item_26 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_bool_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_aux_item_26: tmp122 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s0rt_loc) ; tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s0rt_node) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp123)->tag != 0) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp125 = aux_itemlst_27 (arg0) ; tmp124 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (tmp122, statmp109, tmp125) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp121)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp121, atslab_0, tmp124) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp123)->tag != 1) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_4, tmp123, atslab_0) ; tmp127 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp126, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; if (!tmp127) { goto __ats_lab_33_1 ; } tmp121 = statmp113 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp123)->tag != 1) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_4, tmp123, atslab_0) ; tmp129 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp128) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp129 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp130 = ats_caselptrlab_mac(anairiats_sum_2, tmp129, atslab_0) ; ATS_FREE(tmp129) ; tmp131 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide (tmp122, tmp128) ; tmp121 = s1rt_make_opr_19 (tmp131, tmp130) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (tmp129 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp132 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_ide (tmp122, tmp128) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp121)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp121, atslab_0, tmp132) ; break ; } while (0) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp123)->tag != 3) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_4, tmp123, atslab_0) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr (tmp133) ; tmp134 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_list (tmp122, tmp135) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp121)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp121, atslab_0, tmp134) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp123)->tag != 2) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_7, tmp123, atslab_0) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_7, tmp123, atslab_1) ; tmp138 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_qid (tmp122, tmp136, tmp137) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp121)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp121, atslab_0, tmp138) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (((ats_sum_ptr_type)tmp123)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_4, tmp123, atslab_0) ; tmp141 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr (tmp139) ; tmp140 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rt_tup (tmp122, tmp141) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp121)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp121, atslab_0, tmp140) ; break ; } while (0) ; return (tmp121) ; } /* end of [aux_item_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 9517(line=335, offs=7) -- 9748(line=340, offs=32) */ ATSstaticdec() ats_ptr_type loop_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_loop_28: tmp144 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_s0rt_node) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp144)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp145 = ats_caselptrlab_mac(anairiats_sum_7, tmp144, atslab_0) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_7, tmp144, atslab_1) ; tmp148 = aux_item_26 (tmp146) ; tmp147 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp147, atslab_0, tmp148) ; ats_selptrset_mac(anairiats_sum_9, tmp147, atslab_1, arg0) ; arg0 = tmp147 ; arg1 = tmp145 ; goto __ats_lab_loop_28 ; // tail call break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp149 = aux_item_26 (arg1) ; tmp143 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp143, atslab_0, tmp149) ; ats_selptrset_mac(anairiats_sum_9, tmp143, atslab_1, arg0) ; break ; } while (0) ; return (tmp143) ; } /* end of [loop_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 9466(line=333, offs=5) -- 9810(line=344, offs=4) */ ATSstaticdec() ats_ptr_type aux_itemlst_27 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp150) ; __ats_lab_aux_itemlst_27: tmp150 = (ats_sum_ptr_type)0 ; tmp142 = loop_28 (tmp150, arg0) ; return (tmp142) ; } /* end of [aux_itemlst_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 8638(line=312, offs=19) -- 9973(line=351, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr: tmp151 = aux_item_26 (arg0) ; do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp151)->tag != 0) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp152 = ats_caselptrlab_mac(anairiats_sum_4, tmp151, atslab_0) ; tmp120 = tmp152 ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (((ats_sum_ptr_type)tmp151)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: tmp153 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_s0rt_loc) ; tmp120 = s0rt_tr_errmsg_opr_24 (tmp153) ; break ; } while (0) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10039(line=356, offs=12) -- 10081(line=356, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr: tmp154 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr) ; return (tmp154) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10104(line=358, offs=22) -- 10180(line=359, offs=68) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp157 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp156) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp155, atslab_0, tmp157) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp155 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp155) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10229(line=364, offs=4) -- 10344(line=365, offs=78) */ ATSstaticdec() ats_ptr_type s0rtpol_tr_31 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_int_type, tmp162) ; __ats_lab_s0rtpol_tr_31: tmp159 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_loc) ; tmp161 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_srt) ; tmp160 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp161) ; tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_pol) ; tmp158 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtpol_make (tmp159, tmp160, tmp162) ; return (tmp158) ; } /* end of [s0rtpol_tr_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10372(line=368, offs=4) -- 10620(line=375, offs=6) */ ATSstaticdec() ats_ptr_type s0rtpol_srt_tr_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_bool_type, tmp164) ; ATSlocal (ats_int_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; __ats_lab_s0rtpol_srt_tr_32: tmp165 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_pol) ; tmp164 = atspre_eq_int_int (tmp165, 0) ; if (tmp164) { tmp166 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_srt) ; tmp163 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp166) ; } else { tmp168 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_s0rtpol_loc) ; /* tmp167 = */ prerr_loc_error1_0 (tmp168) ; /* tmp169 = */ atspre_prerr_string (ATSstrcst(": only a nonpolarized sort is allowed here")) ; /* tmp170 = */ atspre_prerr_newline () ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return (tmp163) ; } /* end of [s0rtpol_srt_tr_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10688(line=380, offs=4) -- 10958(line=389, offs=4) */ ATSstaticdec() ats_ptr_type d0atarg_tr_33 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_d0atarg_tr_33: tmp172 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_d0atarg_node) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp172)->tag != 0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_4, tmp172, atslab_0) ; tmp174 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_d0atarg_loc) ; tmp175 = s0rtpol_tr_31 (tmp173) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_srt (tmp174, tmp175) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (((ats_sum_ptr_type)tmp172)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_7, tmp172, atslab_0) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_7, tmp172, atslab_1) ; tmp178 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, arg0), atslab_d0atarg_loc) ; tmp179 = s0rtpol_tr_31 (tmp177) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__d1atarg_idsrt (tmp178, tmp176, tmp179) ; break ; } while (0) ; return (tmp171) ; } /* end of [d0atarg_tr_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 10987(line=391, offs=5) -- 11138(line=395, offs=21) */ ATSstaticdec() ats_ptr_type d0atarglst_tr_34 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_d0atarglst_tr_34: do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp181 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp183 = d0atarg_tr_33 (tmp181) ; tmp184 = d0atarglst_tr_34 (tmp182) ; tmp180 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp180, atslab_0, tmp183) ; ats_selptrset_mac(anairiats_sum_9, tmp180, atslab_1, tmp184) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp180 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp180) ; } /* end of [d0atarglst_tr_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 11170(line=398, offs=5) -- 11537(line=409, offs=4) */ ATSstaticdec() ats_ptr_type d0atarglst_srtlst_tr_35 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; __ats_lab_d0atarglst_srtlst_tr_35: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp187 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, tmp186), atslab_d0atarg_node) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp189)->tag != 0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_4, tmp189, atslab_0) ; tmp188 = tmp190 ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (((ats_sum_ptr_type)tmp189)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_7, tmp189, atslab_1) ; tmp188 = tmp191 ; break ; } while (0) ; tmp192 = s0rtpol_srt_tr_32 (tmp188) ; tmp193 = d0atarglst_srtlst_tr_35 (tmp187) ; tmp185 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp185, atslab_0, tmp192) ; ats_selptrset_mac(anairiats_sum_9, tmp185, atslab_1, tmp193) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: tmp185 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp185) ; } /* end of [d0atarglst_srtlst_tr_35] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 11643(line=415, offs=7) -- 12253(line=436, offs=19) */ ATSstaticdec() ats_void_type loop_37 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; // ATSlocal_void (tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; __ats_lab_loop_37: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp196 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp197 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; tmp199 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp196), atslab_i0de_sym) ; /* tmp198 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add (tmp199, arg0) ; arg0 = arg0 ; arg1 = tmp197 ; goto __ats_lab_loop_37 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: break ; } while (0) ; return /* (tmp195) */ ; } /* end of [loop_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 11618(line=414, offs=16) -- 12289(line=439, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_fixity_tr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp194) ; ATSlocal (ats_ptr_type, tmp200) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_fixity_tr: tmp200 = f0xty_tr_5 (arg0) ; /* tmp194 = */ loop_37 (tmp200, arg1) ; return /* (tmp194) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_fixity_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 12361(line=443, offs=7) -- 12540(line=447, offs=19) */ ATSstaticdec() ats_void_type loop_39 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; // ATSlocal_void (tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; __ats_lab_loop_39: do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp203 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp206 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp203), atslab_i0de_sym) ; /* tmp205 = */ ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add (tmp206, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fxty_non) ; arg0 = tmp204 ; goto __ats_lab_loop_39 ; // tail call break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: break ; } while (0) ; return /* (tmp202) */ ; } /* end of [loop_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 12343(line=442, offs=16) -- 12593(line=451, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_nonfix_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_nonfix_tr: /* tmp201 = */ loop_39 (arg0) ; return /* (tmp201) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0ec_nonfix_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 12671(line=456, offs=19) -- 13114(line=471, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_assert (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp207) ; ATSlocal (ats_bool_type, tmp208) ; ATSlocal (ats_char_type, tmp209) ; ATSlocal (ats_double_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_assert: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp208 = atspre_eq_char_char (tmp209, '\000') ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp210 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_0) ; tmp208 = atspre_eq_double_double (tmp210, 0.0) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp211 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp208 = atspre_eq_int_int (tmp211, 0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp208 = atspre_string_is_empty (ats_castfn_mac(ats_ptr_type, tmp212)) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: // if (((ats_sum_ptr_type)arg1)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_61_1: tmp208 = ats_true_bool ; break ; } while (0) ; if (tmp208) { /* tmp213 = */ prerr_loc_error1_0 (arg0) ; /* tmp214 = */ atspre_prerr_string (ATSstrcst(": [#assert] failed")) ; /* tmp215 = */ atspre_prerr_newline () ; /* tmp207 = */ ats_exit (1) ; } else { /* empty */ } /* end of [if] */ return /* (tmp207) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_assert] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 13173(line=474, offs=18) -- 13648(line=491, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_error (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; ATSlocal (ats_char_type, tmp220) ; ATSlocal (ats_double_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_error: /* tmp217 = */ prerr_loc_error1_0 (arg0) ; /* tmp218 = */ atspre_prerr_string (ATSstrcst(": [#error] directive encountered: ")) ; do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp220 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; /* tmp219 = */ atspre_prerr_char (tmp220) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_16, arg1, atslab_0) ; /* tmp219 = */ atspre_prerr_double (tmp221) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; /* tmp219 = */ atspre_prerr_int (tmp222) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; /* tmp219 = */ atspre_prerr_string (tmp223) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (((ats_sum_ptr_type)arg1)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: tmp224 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp224)->tag != 0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: /* tmp219 = */ atspre_prerr_string (ATSstrcst("#FILENAME")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (((ats_sum_ptr_type)tmp224)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: /* tmp219 = */ atspre_prerr_string (ATSstrcst("#LOCATION")) ; break ; } while (0) ; break ; } while (0) ; /* tmp216 = */ ats_exit (1) ; return /* (tmp216) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_error] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 13708(line=495, offs=3) -- 14069(line=508, offs=6) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_prerr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp225) ; ATSlocal (ats_char_type, tmp226) ; ATSlocal (ats_double_type, tmp227) ; ATSlocal (ats_int_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_prerr: do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; /* tmp225 = */ atspre_prerr_char (tmp226) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_16, arg0, atslab_0) ; /* tmp225 = */ atspre_prerr_double (tmp227) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; /* tmp225 = */ atspre_prerr_int (tmp228) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp229 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; /* tmp225 = */ atspre_prerr_string (tmp229) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: tmp230 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp231)->tag != 0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp232 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename (tmp230) ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__prerr_filename (tmp232) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (((ats_sum_ptr_type)tmp231)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp230) ; break ; } while (0) ; break ; } while (0) ; return /* (tmp225) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__do_e0xpact_prerr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 14164(line=514, offs=12) -- 14448(line=523, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr: tmp234 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0tacon_fil) ; tmp235 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0tacon_loc) ; tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0tacon_arg) ; do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (tmp237 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp238 = ats_caselptrlab_mac(anairiats_sum_2, tmp237, atslab_0) ; tmp239 = d0atarglst_tr_34 (tmp238) ; tmp236 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp236, atslab_0, tmp239) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: // if (tmp237 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_77_1: tmp236 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0tacon_def) ; tmp240 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (tmp241) ; tmp242 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0tacon_sym) ; tmp233 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacon_make (tmp234, tmp235, tmp242, tmp236, tmp240) ; return (tmp233) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 14497(line=526, offs=15) -- 14538(line=526, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0taconlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp243) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0taconlst_tr: tmp243 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacon_tr) ; return (tmp243) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0taconlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 14582(line=531, offs=12) -- 14890(line=541, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr: tmp245 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0tacst_fil) ; tmp246 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0tacst_loc) ; tmp248 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0tacst_arg) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (tmp248 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_2, tmp248, atslab_0) ; tmp250 = d0atarglst_srtlst_tr_35 (tmp249) ; tmp247 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp247, atslab_0, tmp250) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (tmp248 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp247 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp252 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0tacst_res) ; tmp251 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp252) ; tmp253 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0tacst_sym) ; tmp244 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacst_make (tmp245, tmp246, tmp253, tmp247, tmp251) ; return (tmp244) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 14939(line=544, offs=15) -- 14980(line=544, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacstlst_tr: tmp254 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacst_tr) ; return (tmp254) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tacstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 15024(line=549, offs=12) -- 15131(line=553, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr: tmp257 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_s0tavar_srt) ; tmp256 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp257) ; tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_s0tavar_loc) ; tmp259 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_s0tavar_sym) ; tmp255 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tavar_make (tmp258, tmp259, tmp256) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 15180(line=556, offs=15) -- 15221(line=556, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavarlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavarlst_tr: tmp260 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavar_tr) ; return (tmp260) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0tavarlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 15254(line=562, offs=4) -- 15698(line=577, offs=4) */ ATSstaticdec() ats_ptr_type d0atsrtcon_tr_49 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; __ats_lab_d0atsrtcon_tr_49: tmp262 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d0atsrtcon_loc) ; tmp263 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d0atsrtcon_sym) ; tmp265 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d0atsrtcon_arg) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (tmp265 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_80_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_2, tmp265, atslab_0) ; tmp267 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp266) ; tmp268 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp267), atslab_s1rt_node) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp268)->tag != 1) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_4, tmp268, atslab_0) ; tmp264 = tmp269 ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp270 = (ats_sum_ptr_type)0 ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp264, atslab_0, tmp267) ; ats_selptrset_mac(anairiats_sum_9, tmp264, atslab_1, tmp270) ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: // if (tmp265 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_83_1: tmp264 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtcon_make (tmp262, tmp263, tmp264) ; return (tmp261) ; } /* end of [d0atsrtcon_tr_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 15729(line=579, offs=4) -- 15824(line=581, offs=40) */ ATSstaticdec() ats_ptr_type d0atsrtconlst_tr_50 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; __ats_lab_d0atsrtconlst_tr_50: tmp271 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &d0atsrtcon_tr_49) ; return (tmp271) ; } /* end of [d0atsrtconlst_tr_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 15871(line=586, offs=15) -- 16007(line=590, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr: tmp273 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0atsrtdec_loc) ; tmp274 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0atsrtdec_sym) ; tmp276 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0atsrtdec_con) ; tmp275 = d0atsrtconlst_tr_50 (tmp276) ; tmp272 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtdec_make (tmp273, tmp274, tmp275) ; return (tmp272) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16062(line=593, offs=18) -- 16106(line=593, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdeclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp277) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdeclst_tr: tmp277 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdec_tr) ; return (tmp277) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atsrtdeclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16162(line=601, offs=4) -- 16291(line=606, offs=4) */ ATSstaticdec() ats_ptr_type s0arg_tr_53 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; __ats_lab_s0arg_tr_53: tmp280 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_s0arg_srt) ; tmp279 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (tmp280) ; tmp281 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_s0arg_loc) ; tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_s0arg_sym) ; tmp278 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1arg_make (tmp281, tmp282, tmp279) ; return (tmp278) ; } /* end of [s0arg_tr_53] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16357(line=611, offs=13) -- 16400(line=611, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr: tmp283 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &s0arg_tr_53) ; return (tmp283) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16450(line=616, offs=16) -- 16498(line=616, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr: tmp284 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr) ; return (tmp284) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16540(line=621, offs=10) -- 16752(line=627, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__sp0at_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__sp0at_tr: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_sp0at_node) ; do { /* branch: __ats_lab_84 */ __ats_lab_84_0: // __ats_lab_84_1: tmp287 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_0) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_9, tmp286, atslab_1) ; tmp289 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (tmp288) ; tmp290 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_sp0at_loc) ; tmp291 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, tmp287), atslab_sqi0de_qua) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, tmp287), atslab_sqi0de_sym) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__sp1at_con (tmp290, tmp291, tmp292, tmp289) ; break ; } while (0) ; return (tmp285) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__sp0at_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 16954(line=638, offs=4) -- 17443(line=653, offs=4) */ ATSstaticdec() ats_ptr_type f_57 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_f_57: tmp295 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp296 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg1), atslab_s1exp_loc) ; tmp294 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp295, tmp296) ; tmp298 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg1), atslab_s1exp_node) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp298)->tag != 10) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_26, tmp298, atslab_1) ; tmp297 = tmp299 ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp300 = (ats_sum_ptr_type)0 ; tmp297 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp297, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp297, atslab_1, tmp300) ; break ; } while (0) ; tmp302 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg1), atslab_s1exp_loc) ; tmp301 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (tmp294, arg0, tmp302, tmp297) ; tmp293 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp293)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp293, atslab_0, tmp301) ; return (tmp293) ; } /* end of [f_57] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_57_closure_type ; ats_ptr_type f_57_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_57 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_57_closure_init (f_57_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_57_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_57_closure_make () { f_57_closure_type *p_clo = ATS_MALLOC(sizeof(f_57_closure_type)) ; f_57_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 17608(line=662, offs=5) -- 17628(line=662, offs=25) */ ATSstaticdec() ats_ptr_type __ats_fun_59 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp305) ; __ats_lab___ats_fun_59: tmp305 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; return (tmp305) ; } /* end of [__ats_fun_59] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 17634(line=663, offs=5) -- 17694(line=663, offs=65) */ ATSstaticdec() ats_ptr_type __ats_fun_60 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp306) ; __ats_lab___ats_fun_60: tmp306 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (arg0, arg1, arg2, arg3) ; return (tmp306) ; } /* end of [__ats_fun_60] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_60_closure_type ; ats_ptr_type __ats_fun_60_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_60 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_60_closure_init (__ats_fun_60_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_60_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_60_closure_make () { __ats_fun_60_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_60_closure_type)) ; __ats_fun_60_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 17519(line=659, offs=4) -- 17732(line=665, offs=4) */ ATSstaticdec() ats_ptr_type s1exp_make_opr_58 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp304) ; __ats_lab_s1exp_make_opr_58: tmp304 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make (&__ats_fun_59, __ats_fun_60_closure_make (), arg0, arg1) ; return (tmp304) ; } /* end of [s1exp_make_opr_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 17844(line=669, offs=5) -- 17864(line=669, offs=25) */ ATSstaticdec() ats_ptr_type __ats_fun_61 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp308) ; __ats_lab___ats_fun_61: tmp308 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; return (tmp308) ; } /* end of [__ats_fun_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 17870(line=670, offs=5) -- 17932(line=670, offs=67) */ ATSstaticdec() ats_ptr_type __ats_fun_62 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp309) ; __ats_lab___ats_fun_62: tmp309 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_app (arg0, arg1, arg2, arg3) ; return (tmp309) ; } /* end of [__ats_fun_62] */ typedef struct { ats_fun_ptr_type closure_fun ; } __ats_fun_62_closure_type ; ats_ptr_type __ats_fun_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { return __ats_fun_62 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_62_closure_init (__ats_fun_62_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_62_clofun ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_62_closure_make () { __ats_fun_62_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_62_closure_type)) ; __ats_fun_62_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18029(line=676, offs=4) -- 18287(line=682, offs=4) */ ATSstaticdec() ats_ptr_type s0qua_tr_63 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_s0qua_tr_63: tmp311 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_s0qua_node) ; do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp311)->tag != 0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp312 = ats_caselptrlab_mac(anairiats_sum_4, tmp311, atslab_0) ; tmp313 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_s0qua_loc) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp312) ; tmp310 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_prop (tmp313, tmp314) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: // if (((ats_sum_ptr_type)tmp311)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_88_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_28, tmp311, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_28, tmp311, atslab_1) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_28, tmp311, atslab_2) ; tmp318 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_s0qua_loc) ; tmp319 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp319, atslab_0, tmp315) ; ats_selptrset_mac(anairiats_sum_9, tmp319, atslab_1, tmp316) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr (tmp317) ; tmp310 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1qua_vars (tmp318, tmp319, tmp320) ; break ; } while (0) ; return (tmp310) ; } /* end of [s0qua_tr_63] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18332(line=685, offs=13) -- 18375(line=685, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr: tmp321 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &s0qua_tr_63) ; return (tmp321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18401(line=687, offs=16) -- 18449(line=687, offs=64) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp322) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr: tmp322 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr) ; return (tmp322) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18482(line=693, offs=4) -- 18677(line=700, offs=4) */ ATSstaticdec() ats_ptr_type s0exp_tr_errmsg_opr_66 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; // ATSlocal_void (tmp326) ; __ats_lab_s0exp_tr_errmsg_opr_66: /* tmp324 = */ prerr_loc_error1_0 (arg0) ; /* tmp325 = */ atspre_prerr_string (ATSstrcst(": the operator needs to be applied.")) ; /* tmp326 = */ atspre_prerr_newline () ; /* tmp323 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp323) ; } /* end of [s0exp_tr_errmsg_opr_66] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 19421(line=725, offs=12) -- 19605(line=728, offs=14) */ ATSstaticdec() ats_ptr_type f_70 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_f_70: tmp345 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp344 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp345) ; tmp346 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_exi (tmp344, env1, env2, arg0) ; tmp343 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp343)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp343, atslab_0, tmp346) ; return (tmp343) ; } /* end of [f_70] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; ats_ptr_type closure_env_2 ; } f_70_closure_type ; ats_ptr_type f_70_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_70 (((f_70_closure_type*)cloptr)->closure_env_0, ((f_70_closure_type*)cloptr)->closure_env_1, ((f_70_closure_type*)cloptr)->closure_env_2, arg0) ; } /* end of function */ ATSinline() ats_void_type f_70_closure_init (f_70_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&f_70_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type f_70_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { f_70_closure_type *p_clo = ATS_MALLOC(sizeof(f_70_closure_type)) ; f_70_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 19839(line=736, offs=15) -- 20282(line=746, offs=28) */ ATSstaticdec() ats_ptr_type loop_71 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; __ats_lab_loop_71: do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_94_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp353 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp351) ; tmp355 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp353), atslab_s1exp_node) ; do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp355)->tag != 10) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_26, tmp355, atslab_1) ; tmp354 = tmp356 ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: __ats_lab_96_1: tmp357 = (ats_sum_ptr_type)0 ; tmp354 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp354, atslab_0, tmp353) ; ats_selptrset_mac(anairiats_sum_9, tmp354, atslab_1, tmp357) ; break ; } while (0) ; tmp358 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp358, atslab_0, tmp354) ; ats_selptrset_mac(anairiats_sum_9, tmp358, atslab_1, arg1) ; arg0 = tmp352 ; arg1 = tmp358 ; goto __ats_lab_loop_71 ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp350 = arg1 ; break ; } while (0) ; return (tmp350) ; } /* end of [loop_71] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 20570(line=755, offs=12) -- 20752(line=758, offs=14) */ ATSstaticdec() ats_ptr_type f_72 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_f_72: tmp368 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp368) ; tmp369 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar (tmp367, 1, arg0) ; tmp366 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp366)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp366, atslab_0, tmp369) ; return (tmp366) ; } /* end of [f_72] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_72_closure_type ; ats_ptr_type f_72_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_72 (((f_72_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_72_closure_init (f_72_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_72_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_72_closure_make (ats_ptr_type env0) { f_72_closure_type *p_clo = ATS_MALLOC(sizeof(f_72_closure_type)) ; f_72_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 21030(line=765, offs=12) -- 21212(line=768, offs=14) */ ATSstaticdec() ats_ptr_type f_73 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; __ats_lab_f_73: tmp377 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp376 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp377) ; tmp378 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_invar (tmp376, 0, arg0) ; tmp375 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp375)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp375, atslab_0, tmp378) ; return (tmp375) ; } /* end of [f_73] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_73_closure_type ; ats_ptr_type f_73_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_73 (((f_73_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_73_closure_init (f_73_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_73_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_73_closure_make (ats_ptr_type env0) { f_73_closure_type *p_clo = ATS_MALLOC(sizeof(f_73_closure_type)) ; f_73_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 21383(line=773, offs=12) -- 21563(line=776, offs=14) */ ATSstaticdec() ats_ptr_type f_74 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; __ats_lab_f_74: tmp384 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp383 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp384, env0) ; tmp385 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top (tmp383, 0, arg0) ; tmp382 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp382)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp382, atslab_0, tmp385) ; return (tmp382) ; } /* end of [f_74] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_74_closure_type ; ats_ptr_type f_74_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_74 (((f_74_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_74_closure_init (f_74_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_74_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_74_closure_make (ats_ptr_type env0) { f_74_closure_type *p_clo = ATS_MALLOC(sizeof(f_74_closure_type)) ; f_74_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 21776(line=782, offs=12) -- 21956(line=785, offs=14) */ ATSstaticdec() ats_ptr_type f_75 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; __ats_lab_f_75: tmp391 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp390 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp391, env0) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_top (tmp390, 1, arg0) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp389)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp389, atslab_0, tmp392) ; return (tmp389) ; } /* end of [f_75] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_75_closure_type ; ats_ptr_type f_75_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_75 (((f_75_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_75_closure_init (f_75_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_75_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_75_closure_make (ats_ptr_type env0) { f_75_closure_type *p_clo = ATS_MALLOC(sizeof(f_75_closure_type)) ; f_75_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 22168(line=791, offs=12) -- 22372(line=794, offs=14) */ ATSstaticdec() ats_ptr_type f_76 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; __ats_lab_f_76: tmp398 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp399 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg1), atslab_s1exp_loc) ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp398, tmp399) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_trans (tmp397, arg0, arg1) ; tmp396 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp396)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp396, atslab_0, tmp400) ; return (tmp396) ; } /* end of [f_76] */ typedef struct { ats_fun_ptr_type closure_fun ; } f_76_closure_type ; ats_ptr_type f_76_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return f_76 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type f_76_closure_init (f_76_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&f_76_clofun ; return ; } /* end of function */ ats_clo_ptr_type f_76_closure_make () { f_76_closure_type *p_clo = ATS_MALLOC(sizeof(f_76_closure_type)) ; f_76_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 22596(line=800, offs=12) -- 22767(line=803, offs=14) */ ATSstaticdec() ats_ptr_type f_77 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; __ats_lab_f_77: tmp407 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp406 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp407) ; tmp408 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_read (tmp406, arg0) ; tmp405 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp405)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp405, atslab_0, tmp408) ; return (tmp405) ; } /* end of [f_77] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } f_77_closure_type ; ats_ptr_type f_77_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_77 (((f_77_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type f_77_closure_init (f_77_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&f_77_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type f_77_closure_make (ats_ptr_type env0) { f_77_closure_type *p_clo = ATS_MALLOC(sizeof(f_77_closure_type)) ; f_77_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 26486(line=909, offs=12) -- 26665(line=912, offs=14) */ ATSstaticdec() ats_ptr_type f_78 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_f_78: tmp476 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, arg0), atslab_s1exp_loc) ; tmp475 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (env0, tmp476) ; tmp477 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_uni (tmp475, env1, arg0) ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp474)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp474, atslab_0, tmp477) ; return (tmp474) ; } /* end of [f_78] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } f_78_closure_type ; ats_ptr_type f_78_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return f_78 (((f_78_closure_type*)cloptr)->closure_env_0, ((f_78_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type f_78_closure_init (f_78_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&f_78_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type f_78_closure_make (ats_ptr_type env0, ats_ptr_type env1) { f_78_closure_type *p_clo = ATS_MALLOC(sizeof(f_78_closure_type)) ; f_78_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18768(line=706, offs=7) -- 27228(line=929, offs=6) */ ATSstaticdec() ats_ptr_type aux_item_68 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_char_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_int_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_bool_type, tmp365) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_bool_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_bool_type, tmp374) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_bool_type, tmp381) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_bool_type, tmp388) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_bool_type, tmp395) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_bool_type, tmp404) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (anairiats_rec_0, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_int_type, tmp417) ; ATSlocal (ats_int_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; // ATSlocal_void (tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_int_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_int_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_int_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; // ATSlocal_void (tmp487) ; __ats_lab_aux_item_68: tmp329 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_s0exp_loc) ; tmp330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_s0exp_node) ; do { /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp330)->tag != 0) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp333 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp331) ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp332) ; tmp335 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ann (tmp329, tmp333, tmp334) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp335) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp330)->tag != 1) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp337 = aux_itemlst_69 (arg0) ; tmp336 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__fixity_resolve (tmp329, statmp303, tmp337) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp336) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp330)->tag != 2) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_11, tmp330, atslab_0) ; tmp339 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_char (tmp329, tmp338) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp339) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp330)->tag != 3) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_0) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_1) ; tmp342 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp341) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp347)->tag = 1 ; ats_selptrset_mac(anairiats_sum_30, tmp347, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__exi_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp347, atslab_1, f_70_closure_make (tmp329, tmp340, tmp342)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp347) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)tmp330)->tag != 4) { goto __ats_lab_98_0 ; } __ats_lab_93_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp349 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp360 = (ats_sum_ptr_type)0 ; tmp359 = loop_71 (tmp349, tmp360) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_extype (tmp329, tmp348, tmp359) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp361) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp330)->tag != 7) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp362 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp363 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_int (tmp329, tmp362) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp363) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp365 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp364, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND) ; if (!tmp365) { goto __ats_lab_100_1 ; } tmp370 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp370)->tag = 1 ; ats_selptrset_mac(anairiats_sum_30, tmp370, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp370, atslab_1, f_72_closure_make (tmp329)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp370) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp371, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; if (!tmp372) { goto __ats_lab_101_1 ; } tmp328 = statmp307 ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp374 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp373, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; if (!tmp374) { goto __ats_lab_102_1 ; } tmp379 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp379)->tag = 1 ; ats_selptrset_mac(anairiats_sum_30, tmp379, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__invar_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp379, atslab_1, f_73_closure_make (tmp329)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp379) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp380 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp381 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp380, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK) ; if (!tmp381) { goto __ats_lab_103_1 ; } tmp386 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp386)->tag = 2 ; ats_selptrset_mac(anairiats_sum_30, tmp386, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmark_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp386, atslab_1, f_74_closure_make (tmp329)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp386) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp388 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp387, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARKBANG) ; if (!tmp388) { goto __ats_lab_104_1 ; } tmp393 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp393)->tag = 2 ; ats_selptrset_mac(anairiats_sum_30, tmp393, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__qmarkbang_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp393, atslab_1, f_75_closure_make (tmp329)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp393) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp394 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp395 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp394, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; if (!tmp395) { goto __ats_lab_105_1 ; } tmp402 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; tmp401 = ATS_MALLOC(sizeof(anairiats_sum_31)) ; ((ats_sum_ptr_type)tmp401)->tag = 0 ; ats_selptrset_mac(anairiats_sum_31, tmp401, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__trans_prec_sta) ; ats_selptrset_mac(anairiats_sum_31, tmp401, atslab_1, tmp402) ; ats_selptrset_mac(anairiats_sum_31, tmp401, atslab_2, f_76_closure_make ()) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp401) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp404 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp403, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD) ; if (!tmp404) { goto __ats_lab_106_1 ; } tmp409 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp409)->tag = 1 ; ats_selptrset_mac(anairiats_sum_30, tmp409, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__r0ead_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp409, atslab_1, f_77_closure_make (tmp329)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp409) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)tmp330)->tag != 5) { goto __ats_lab_109_0 ; } __ats_lab_106_1: tmp410 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp411 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide (tmp329, tmp410) ; tmp412 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (tmp410) ; do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp412 == (ats_sum_ptr_type)0) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_2, tmp412, atslab_0) ; ATS_FREE(tmp412) ; tmp328 = s1exp_make_opr_58 (tmp411, tmp413) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: // if (tmp412 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_108_1: tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp411) ; break ; } while (0) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)tmp330)->tag != 6) { goto __ats_lab_114_0 ; } __ats_lab_109_1: tmp414 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp415 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (tmp414) ; tmp416 = ats_select_mac(tmp415, atslab_0) ; tmp417 = ats_select_mac(tmp415, atslab_1) ; tmp418 = ats_select_mac(tmp415, atslab_2) ; tmp419 = ats_select_mac(tmp415, atslab_3) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (tmp416 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp421 = ats_caselptrlab_mac(anairiats_sum_2, tmp416, atslab_0) ; tmp420 = tmp421 ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: __ats_lab_111_1: tmp420 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp422 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (tmp422 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_2, tmp422, atslab_0) ; ATS_FREE(tmp422) ; tmp425 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp425, atslab_0, tmp419) ; tmp424 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_imp (tmp329, tmp420, tmp417, tmp418, tmp425) ; tmp328 = s1exp_make_opr_58 (tmp424, tmp423) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (tmp422 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: /* tmp426 = */ prerr_interror_1 () ; /* tmp427 = */ atspre_prerr_string (ATSstrcst(": s0exp_tr: the fixity of -> is unavailable.")) ; /* tmp428 = */ atspre_prerr_newline () ; /* tmp328 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)tmp330)->tag != 8) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp429 = ats_caselptrlab_mac(anairiats_sum_28, tmp330, atslab_0) ; tmp430 = ats_caselptrlab_mac(anairiats_sum_28, tmp330, atslab_1) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_28, tmp330, atslab_2) ; tmp432 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglst_tr (tmp429) ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (tmp430) ; tmp434 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp431) ; tmp435 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_lam (tmp329, tmp432, tmp433, tmp434) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp435) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp330)->tag != 9) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp436 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp436) ; tmp438 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list (tmp329, tmp437) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp438) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)tmp330)->tag != 10) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp439 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp440 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp439) ; tmp442 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp440) ; tmp443 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_list2 (tmp329, tmp441, tmp442) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp443) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)tmp330)->tag != 12) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp444 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_ide (tmp329, tmp444) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp445) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: if (((ats_sum_ptr_type)tmp330)->tag != 13) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp446 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp447 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp448 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_qid (tmp329, tmp446, tmp447) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp448) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)tmp330)->tag != 14) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp449 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp450 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp451 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp449) ; tmp452 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explstlst_tr (tmp450) ; tmp453 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyarr (tmp329, tmp451, tmp452) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp453) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: if (((ats_sum_ptr_type)tmp330)->tag != 15) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp454 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_0) ; tmp455 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_1) ; tmp456 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr (tmp455) ; tmp457 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec (tmp329, tmp454, tmp456) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp457) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: if (((ats_sum_ptr_type)tmp330)->tag != 16) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp458 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp459 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr (tmp459) ; tmp461 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tyrec_ext (tmp329, tmp458, tmp460) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp461) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp330)->tag != 17) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp462 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_0) ; tmp463 = ats_caselptrlab_mac(anairiats_sum_26, tmp330, atslab_1) ; tmp464 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp463) ; tmp465 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup (tmp329, tmp462, tmp464) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp465) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp330)->tag != 18) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp466 = ats_caselptrlab_mac(anairiats_sum_32, tmp330, atslab_0) ; tmp467 = ats_caselptrlab_mac(anairiats_sum_32, tmp330, atslab_1) ; tmp468 = ats_caselptrlab_mac(anairiats_sum_32, tmp330, atslab_2) ; tmp469 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp467) ; tmp470 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp468) ; tmp471 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_tytup2 (tmp329, tmp466, tmp469, tmp470) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp471) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp330)->tag != 19) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp472 = ats_caselptrlab_mac(anairiats_sum_4, tmp330, atslab_0) ; tmp473 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualst_tr (tmp472) ; tmp478 = ATS_MALLOC(sizeof(anairiats_sum_30)) ; ((ats_sum_ptr_type)tmp478)->tag = 1 ; ats_selptrset_mac(anairiats_sum_30, tmp478, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__uni_prec_sta) ; ats_selptrset_mac(anairiats_sum_30, tmp478, atslab_1, f_78_closure_make (tmp329, tmp473)) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp478) ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp330)->tag != 20) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp479 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_0) ; tmp480 = ats_caselptrlab_mac(anairiats_sum_7, tmp330, atslab_1) ; tmp481 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp479) ; tmp482 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr (tmp480) ; tmp483 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1exp_union (tmp329, tmp481, tmp482) ; tmp328 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp328)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp328, atslab_0, tmp483) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: __ats_lab_126_1: /* tmp484 = */ prerr_loc_error1_0 (tmp329) ; /* tmp485 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s0exp_tr"), ATSstrcst("ats_trans1_sta.dats")) ; /* tmp486 = */ atspre_prerr_string (ATSstrcst(": not available yet")) ; /* tmp487 = */ atspre_prerr_newline () ; /* tmp328 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp328) ; } /* end of [aux_item_68] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 27316(line=933, offs=9) -- 27559(line=938, offs=34) */ ATSstaticdec() ats_ptr_type loop_79 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; __ats_lab_loop_79: tmp490 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_s0exp_node) ; do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (((ats_sum_ptr_type)tmp490)->tag != 1) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp491 = ats_caselptrlab_mac(anairiats_sum_7, tmp490, atslab_0) ; tmp492 = ats_caselptrlab_mac(anairiats_sum_7, tmp490, atslab_1) ; tmp494 = aux_item_68 (tmp492) ; tmp493 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp493, atslab_0, tmp494) ; ats_selptrset_mac(anairiats_sum_9, tmp493, atslab_1, arg0) ; arg0 = tmp493 ; arg1 = tmp491 ; goto __ats_lab_loop_79 ; // tail call break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: __ats_lab_128_1: tmp495 = aux_item_68 (arg1) ; tmp489 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp489, atslab_0, tmp495) ; ats_selptrset_mac(anairiats_sum_9, tmp489, atslab_1, arg0) ; break ; } while (0) ; return (tmp489) ; } /* end of [loop_79] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 27259(line=931, offs=7) -- 27615(line=942, offs=6) */ ATSstaticdec() ats_ptr_type aux_itemlst_69 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp496) ; __ats_lab_aux_itemlst_69: tmp496 = (ats_sum_ptr_type)0 ; tmp488 = loop_79 (tmp496, arg0) ; return (tmp488) ; } /* end of [aux_itemlst_69] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 18751(line=705, offs=10) -- 27762(line=948, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr: tmp497 = aux_item_68 (arg0) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp497)->tag != 0) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp498 = ats_caselptrlab_mac(anairiats_sum_4, tmp497, atslab_0) ; tmp327 = tmp498 ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: // if (((ats_sum_ptr_type)tmp497)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_130_1: tmp499 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_s0exp_loc) ; tmp327 = s0exp_tr_errmsg_opr_66 (tmp499) ; break ; } while (0) ; return (tmp327) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 27830(line=953, offs=13) -- 27873(line=953, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp500) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr: tmp500 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr) ; return (tmp500) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 27921(line=957, offs=13) -- 28000(line=958, offs=57) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr: do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp502 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp503 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp502) ; tmp501 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp501, atslab_0, tmp503) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_132_1: tmp501 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp501) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 28051(line=962, offs=16) -- 28097(line=962, offs=62) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp504) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explstlst_tr: tmp504 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr) ; return (tmp504) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 28151(line=966, offs=16) -- 28324(line=969, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr: do { /* branch: __ats_lab_133 */ __ats_lab_133_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp506 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_0) ; tmp507 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_1) ; tmp508 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_2) ; tmp509 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_34, tmp506), atslab_l0ab_lab) ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp507) ; tmp511 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr (tmp508) ; tmp505 = ATS_MALLOC(sizeof(anairiats_sum_33)) ; ats_selptrset_mac(anairiats_sum_33, tmp505, atslab_0, tmp509) ; ats_selptrset_mac(anairiats_sum_33, tmp505, atslab_1, tmp510) ; ats_selptrset_mac(anairiats_sum_33, tmp505, atslab_2, tmp511) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_134_1: tmp505 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp505) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__labs0explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 28374(line=973, offs=12) -- 28701(line=984, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr: tmp513 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_s0rtext_loc) ; tmp514 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_s0rtext_node) ; do { /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp514)->tag != 0) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp515 = ats_caselptrlab_mac(anairiats_sum_4, tmp514, atslab_0) ; tmp516 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rt_tr (tmp515) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_srt (tmp513, tmp516) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: // if (((ats_sum_ptr_type)tmp514)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_136_1: tmp517 = ats_caselptrlab_mac(anairiats_sum_36, tmp514, atslab_0) ; tmp518 = ats_caselptrlab_mac(anairiats_sum_36, tmp514, atslab_1) ; tmp519 = ats_caselptrlab_mac(anairiats_sum_36, tmp514, atslab_2) ; tmp520 = ats_caselptrlab_mac(anairiats_sum_36, tmp514, atslab_3) ; tmp521 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr (tmp518) ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp519) ; tmp523 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp520) ; tmp524 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp517), atslab_i0de_sym) ; tmp525 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp525, atslab_0, tmp522) ; ats_selptrset_mac(anairiats_sum_9, tmp525, atslab_1, tmp523) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__s1rtext_sub (tmp513, tmp524, tmp521, tmp525) ; break ; } while (0) ; return (tmp512) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 28776(line=989, offs=20) -- 29088(line=998, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr: do { /* branch: __ats_lab_137 */ __ats_lab_137_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp526 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: // if (arg0 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_1: tmp527 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_0) ; tmp528 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_1) ; tmp529 = ats_caselptrlab_mac(anairiats_sum_33, arg0, atslab_2) ; tmp530 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp528) ; tmp531 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr (tmp529) ; tmp526 = ATS_MALLOC(sizeof(anairiats_sum_33)) ; ats_selptrset_mac(anairiats_sum_33, tmp526, atslab_0, tmp527) ; ats_selptrset_mac(anairiats_sum_33, tmp526, atslab_1, tmp530) ; ats_selptrset_mac(anairiats_sum_33, tmp526, atslab_2, tmp531) ; break ; } while (0) ; return (tmp526) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__t1mps0explstlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 29165(line=1003, offs=14) -- 29460(line=1009, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr: do { /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp532 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEnone_0) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp533 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp534 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp533) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp532)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp532, atslab_0, tmp534) ; break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp535 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp536 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp535) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp532)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp532, atslab_0, tmp536) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp537 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp538 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp537) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp532)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp532, atslab_0, tmp538) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_143_1: tmp539 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp540 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp539) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp532)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp532, atslab_0, tmp540) ; break ; } while (0) ; return (tmp532) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__witht0ype_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 29529(line=1014, offs=12) -- 29863(line=1025, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr: tmp543 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_s0rtdef_def) ; tmp542 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtext_tr (tmp543) ; tmp544 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_s0rtdef_loc) ; tmp545 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_37, arg0), atslab_s0rtdef_sym) ; tmp541 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1rtdef_make (tmp544, tmp545, tmp542) ; return (tmp541) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 29912(line=1028, offs=15) -- 29953(line=1028, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdeflst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp546) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdeflst_tr: tmp546 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdef_tr) ; return (tmp546) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtdeflst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 29998(line=1033, offs=13) -- 30330(line=1046, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr: tmp548 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s0expdef_loc) ; tmp550 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s0expdef_arg) ; tmp549 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr (tmp550) ; tmp551 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s0expdef_sym) ; tmp553 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s0expdef_res) ; tmp552 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (tmp553) ; tmp555 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_38, arg0), atslab_s0expdef_def) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp555) ; tmp547 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1expdef_make (tmp548, tmp551, tmp549, tmp552, tmp554) ; return (tmp547) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 30381(line=1049, offs=16) -- 30423(line=1049, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp556) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr: tmp556 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdef_tr) ; return (tmp556) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0expdeflst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 30468(line=1054, offs=13) -- 30711(line=1063, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0aspdec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0aspdec_tr: tmp559 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_arg) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0arglstlst_tr (tmp559) ; tmp561 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_res) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0rtopt_tr (tmp561) ; tmp563 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_def) ; tmp562 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp563) ; tmp564 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_fil) ; tmp565 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_loc) ; tmp566 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg0), atslab_s0aspdec_qid) ; tmp557 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1aspdec_make (tmp564, tmp565, tmp566, tmp558, tmp560, tmp562) ; return (tmp557) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0aspdec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 30761(line=1067, offs=4) -- 31612(line=1098, offs=4) */ ATSstaticdec() ats_ptr_type d0atcon_tr_92 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_int_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_int_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; // ATSlocal_void (tmp585) ; // ATSlocal_void (tmp586) ; // ATSlocal_void (tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; __ats_lab_d0atcon_tr_92: tmp569 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg0), atslab_d0atcon_qua) ; tmp568 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr (tmp569) ; /* ats_int_type tmp570 ; */ tmp570 = 0 ; tmp572 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg0), atslab_d0atcon_arg) ; do { /* branch: __ats_lab_144 */ __ats_lab_144_0: if (tmp572 == (ats_sum_ptr_type)0) { goto __ats_lab_147_0 ; } __ats_lab_144_1: tmp573 = ats_caselptrlab_mac(anairiats_sum_2, tmp572, atslab_0) ; tmp574 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp573) ; tmp575 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp574), atslab_s1exp_node) ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp575)->tag != 10) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp576 = ats_caselptrlab_mac(anairiats_sum_26, tmp575, atslab_0) ; tmp577 = ats_caselptrlab_mac(anairiats_sum_26, tmp575, atslab_1) ; tmp570 = tmp576 ; tmp571 = tmp577 ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: __ats_lab_146_1: tmp578 = (ats_sum_ptr_type)0 ; tmp571 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp571, atslab_0, tmp574) ; ats_selptrset_mac(anairiats_sum_9, tmp571, atslab_1, tmp578) ; break ; } while (0) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: // if (tmp572 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_147_1: tmp571 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp580 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg0), atslab_d0atcon_ind) ; do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (tmp580 == (ats_sum_ptr_type)0) { goto __ats_lab_151_0 ; } __ats_lab_148_1: tmp581 = ats_caselptrlab_mac(anairiats_sum_2, tmp580, atslab_0) ; tmp583 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp581), atslab_s0exp_node) ; do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)tmp583)->tag != 9) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp584 = ats_caselptrlab_mac(anairiats_sum_4, tmp583, atslab_0) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0explst_tr (tmp584) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: __ats_lab_150_1: /* tmp585 = */ prerr_interror_1 () ; /* tmp586 = */ atspre_prerr_string (ATSstrcst(": d0atcon_tr: index is not a list.")) ; /* tmp587 = */ atspre_prerr_newline () ; /* tmp582 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp579 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp579, atslab_0, tmp582) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: // if (tmp580 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_151_1: tmp579 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp588 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg0), atslab_d0atcon_loc) ; tmp589 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_40, arg0), atslab_d0atcon_sym) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atcon_make (tmp588, tmp589, tmp568, tmp570, tmp571, tmp579) ; return (tmp567) ; } /* end of [d0atcon_tr_92] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 31641(line=1100, offs=5) -- 31788(line=1104, offs=4) */ ATSstaticdec() ats_ptr_type d0atconlst_tr_93 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; __ats_lab_d0atconlst_tr_93: do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp593 = d0atcon_tr_92 (tmp591) ; tmp594 = d0atconlst_tr_93 (tmp592) ; tmp590 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp590, atslab_0, tmp593) ; ats_selptrset_mac(anairiats_sum_9, tmp590, atslab_1, tmp594) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: tmp590 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp590) ; } /* end of [d0atconlst_tr_93] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 31837(line=1107, offs=12) -- 32137(line=1118, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr: tmp597 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg0), atslab_d0atdec_arg) ; do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (tmp597 == (ats_sum_ptr_type)0) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp598 = ats_caselptrlab_mac(anairiats_sum_2, tmp597, atslab_0) ; tmp599 = d0atarglst_tr_34 (tmp598) ; tmp596 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp596, atslab_0, tmp599) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: // if (tmp597 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_155_1: tmp596 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp601 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg0), atslab_d0atdec_con) ; tmp600 = d0atconlst_tr_93 (tmp601) ; tmp602 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg0), atslab_d0atdec_fil) ; tmp603 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg0), atslab_d0atdec_loc) ; tmp604 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg0), atslab_d0atdec_sym) ; tmp595 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atdec_make (tmp602, tmp603, tmp604, tmp596, tmp600) ; return (tmp595) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 32186(line=1121, offs=15) -- 32295(line=1125, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr: do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp606 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp607 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp608 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdec_tr (tmp606) ; tmp609 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr (tmp607) ; tmp605 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp605, atslab_0, tmp608) ; ats_selptrset_mac(anairiats_sum_9, tmp605, atslab_1, tmp609) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_157_1: tmp605 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp605) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__d0atdeclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 32365(line=1130, offs=12) -- 32847(line=1146, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_int_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_int_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr: tmp612 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_e0xndec_qua) ; tmp611 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0qualstlst_tr (tmp612) ; /* ats_int_type tmp613 ; */ tmp613 = 0 ; tmp615 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_e0xndec_arg) ; do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (tmp615 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_158_1: tmp616 = ats_caselptrlab_mac(anairiats_sum_2, tmp615, atslab_0) ; tmp617 = ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__s0exp_tr (tmp616) ; tmp618 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_25, tmp617), atslab_s1exp_node) ; do { /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp618)->tag != 10) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp619 = ats_caselptrlab_mac(anairiats_sum_26, tmp618, atslab_0) ; tmp620 = ats_caselptrlab_mac(anairiats_sum_26, tmp618, atslab_1) ; tmp613 = tmp619 ; tmp614 = tmp620 ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: __ats_lab_160_1: tmp621 = (ats_sum_ptr_type)0 ; tmp614 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp614, atslab_0, tmp617) ; ats_selptrset_mac(anairiats_sum_9, tmp614, atslab_1, tmp621) ; break ; } while (0) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (tmp615 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: tmp614 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp622 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_e0xndec_fil) ; tmp623 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_e0xndec_loc) ; tmp624 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_42, arg0), atslab_e0xndec_sym) ; tmp610 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__e1xndec_make (tmp622, tmp623, tmp624, tmp611, tmp613, tmp614) ; return (tmp610) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_sta.dats: 32896(line=1149, offs=15) -- 32937(line=1149, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndeclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp625) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndeclst_tr: tmp625 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndec_tr) ; return (tmp625) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__e0xndeclst_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans1_sta_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp45, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp49, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp109, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp113, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp303, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp307, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp45 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (f_6_closure_make ()) ; statmp49 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (&__ats_fun_10, __ats_fun_11_closure_make ()) ; statmp109 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (f_18_closure_make ()) ; statmp113 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (&__ats_fun_22, __ats_fun_23_closure_make ()) ; statmp303 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__item_app (f_57_closure_make ()) ; statmp307 = ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__oper_make_backslash (&__ats_fun_61, __ats_fun_62_closure_make ()) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans1_sta_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans1_env_dats.c0000664000175000017500000025024012223166160022202 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_map ; ats_ptr_type atslab_maplst ; ats_ptr_type atslab_savedlst ; ats_ptr_type atslab_pervasive ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_4 ; typedef struct { anairiats_rec_4 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_hash ; ats_ptr_type atslab_eq ; ats_int_type atslab_size ; ats_int_type atslab_nitm ; ats_ptr_type atslab_table[] ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_0 ; anairiats_rec_6 atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { anairiats_rec_6 atslab_0 ; } anairiats_sum_9 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__CHAINnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imul) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_uimod) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_ulint) (ats_ulint_type) ; ATSextern_fun(ats_size_type, atspre_size1_of_int1) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ulint_type, atspre_string_hash_33) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_array_ptr_takeout_tsz) (ats_ptr_type, ats_size_type, ats_size_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol_code) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__print_fxty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_reftop_get) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_make_hint) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ats_htp_make) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, __ats_htp_free) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__sasp__trans1_level_v = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_ptr_type bst_join_random_087_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type map_remove_02778_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_remove_fst_01928_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type bst_size_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_078_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_02777_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type symenv_insert_fst_01927_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_067_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_02779_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symmaplst_search_0229_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_search_all_01929_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type symenv_pervasive_search_01930_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_25 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_list_inf_0131_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type map_list_inf_02781_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type symmap_reflist_get_01922_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type loop_26 (ats_ptr_type arg0) ; static ats_ptr_type ref_make_elt_02766_ats_int_type (ats_int_type arg0) ; static ats_void_type prerr_interror_0207_ () ; static ats_ptr_type abort_33 () ; static ats_void_type bst_free_035_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type map_free_02775_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symmap_free_01918_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symenv_pop_01932_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type abort_41 () ; static ats_ptr_type aux_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_join_02780_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type symenv_localjoin_01937_ats_ptr_type (ats_ptr_type arg0) ; static anairiats_rec_4 abort_47 () ; static ats_void_type symmaplst_free_0225_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type symenv_restore_01939_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type chain_insert_0377_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) ; static ats_void_type table_insert_0403_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, anairiats_rec_6 arg3) ; static ats_void_type ht_insert_0434_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) ; static ats_void_type ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_55 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) ; static ats_ptr_type htp_resize_0463_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type hashtbl_insert_02788_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) ; static ats_ptr_type chain_search_0368_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type table_search_0393_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type ht_search_0429_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type hashtbl_search_02787_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp157) ; ATSstatic (ats_ptr_type, statmp196) ; ATSstatic (ats_ptr_type, statmp312) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 2062(line=64, offs=4) -- 2121(line=64, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans1_env)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 5380(line=174, offs=25) -- 6039(line=193, offs=4) */ ATSstaticdec() ats_ptr_type bst_join_random_087_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_int_type, tmp41) ; ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_int_type, tmp43) ; ATSlocal (ats_int_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_bst_join_random_087_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_4_1: tmp35 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp36 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp37 = &ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp38 = &ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_3) ; tmp40 = ats_ptrget_mac(ats_int_type, tmp35) ; tmp41 = ats_ptrget_mac(ats_int_type, tmp37) ; tmp39 = atspre_iadd (tmp40, tmp41) ; tmp43 = ats_ptrget_mac(ats_int_type, tmp35) ; tmp44 = ats_ptrget_mac(ats_int_type, tmp37) ; tmp42 = atsopt_map_lin_dice (tmp43, tmp44) ; if (tmp42) { tmp46 = ats_ptrget_mac(ats_ptr_type, tmp36) ; tmp45 = bst_join_random_087_ats_ptr_type_2cats_ptr_type (tmp46, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp36) = tmp45 ; ats_ptrget_mac(ats_int_type, tmp35) = tmp39 ; tmp34 = arg0 ; } else { tmp48 = ats_ptrget_mac(ats_ptr_type, tmp38) ; tmp47 = bst_join_random_087_ats_ptr_type_2cats_ptr_type (arg0, tmp48) ; ats_ptrget_mac(ats_ptr_type, tmp38) = tmp47 ; ats_ptrget_mac(ats_int_type, tmp37) = tmp39 ; tmp34 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp34 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp34 = arg1 ; break ; } while (0) ; return (tmp34) ; } /* end of [bst_join_random_087_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 6466(line=208, offs=30) -- 7610(line=243, offs=4) */ ATSstaticdec() ats_ptr_type bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_int_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_int_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_bst_remove_random_0101_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_0_1: tmp15 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp16 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp17 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp18 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp19 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp20 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg4) (arg1, tmp16) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp20 != -1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp22 = ats_ptrget_mac(ats_ptr_type, tmp18) ; tmp21 = bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (tmp22, arg1, arg2, arg3, arg4) ; tmp23 = ats_selsin_mac(tmp21, atslab_2) ; tmp25 = ats_ptrget_mac(ats_int_type, tmp15) ; tmp26 = ats_ptrget_mac(ats_int_type, arg2) ; tmp24 = atspre_isub (tmp25, tmp26) ; ats_ptrget_mac(ats_int_type, tmp15) = tmp24 ; ats_ptrget_mac(ats_ptr_type, tmp18) = tmp23 ; tmp14 = arg0 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp20 != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp28 = ats_ptrget_mac(ats_ptr_type, tmp19) ; tmp27 = bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (tmp28, arg1, arg2, arg3, arg4) ; tmp29 = ats_selsin_mac(tmp27, atslab_2) ; tmp31 = ats_ptrget_mac(ats_int_type, tmp15) ; tmp32 = ats_ptrget_mac(ats_int_type, arg2) ; tmp30 = atspre_isub (tmp31, tmp32) ; ats_ptrget_mac(ats_int_type, tmp15) = tmp30 ; ats_ptrget_mac(ats_ptr_type, tmp19) = tmp29 ; tmp14 = arg0 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp20 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp49 = ats_ptrget_mac(ats_ptr_type, tmp18) ; tmp50 = ats_ptrget_mac(ats_ptr_type, tmp19) ; tmp33 = bst_join_random_087_ats_ptr_type_2cats_ptr_type (tmp49, tmp50) ; ats_ptrget_mac(ats_int_type, arg2) = 1 ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp51, atslab_0, tmp17) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp51 ; ATS_FREE(arg0) ; tmp14 = tmp33 ; break ; } while (0) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: ats_ptrget_mac(ats_int_type, arg2) = 0 ; tmp52 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp52 ; tmp14 = arg0 ; break ; } while (0) ; return (tmp14) ; } /* end of [bst_remove_random_0101_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10217(line=356, offs=12) -- 10550(line=365, offs=4) */ ATSstaticdec() ats_ptr_type map_remove_02778_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_map_remove_02778_ats_ptr_type_2cats_ptr_type: // tmp9 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp10 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* ats_int_type tmp11 ; */ /* ats_ptr_type tmp12 ; */ tmp53 = ats_ptrget_mac(ats_ptr_type, tmp10) ; tmp13 = bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (tmp53, arg1, (&tmp11), (&tmp12), tmp9) ; tmp54 = ats_selsin_mac(tmp13, atslab_2) ; ats_ptrget_mac(ats_ptr_type, tmp10) = tmp54 ; tmp8 = tmp12 ; return (tmp8) ; } /* end of [map_remove_02778_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4740(line=179, offs=19) -- 4840(line=182, offs=4) */ ATSstaticdec() ats_ptr_type symenv_remove_fst_01928_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_symenv_remove_fst_01928_ats_ptr_type: tmp6 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp5 = atspre_ref_get_view_ptr (tmp6) ; tmp7 = ats_selsin_mac(tmp5, atslab_1) ; tmp55 = ats_ptrget_mac(ats_ptr_type, tmp7) ; tmp4 = map_remove_02778_ats_ptr_type_2cats_ptr_type (tmp55, arg1) ; return (tmp4) ; } /* end of [symenv_remove_fst_01928_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_039_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp86) ; ATSlocal (ats_int_type, tmp87) ; __ats_lab_bst_size_039_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp86 = tmp87 ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp86 = 0 ; break ; } while (0) ; return (tmp86) ; } /* end of [bst_size_039_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_bool_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_int_type, tmp90) ; ATSlocal (ats_int_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_int_type, tmp97) ; ATSlocal (ats_int_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_int_type, tmp101) ; ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_12_1: tmp73 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp74 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp75 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp76 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp78 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp74) ; tmp77 = atspre_ilte (tmp78, 0) ; if (tmp77) { tmp80 = ats_ptrget_mac(ats_ptr_type, tmp75) ; tmp79 = bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type (tmp80, arg1, arg2, arg3) ; // if (tmp79 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp81 = &ats_caselptrlab_mac(anairiats_sum_2, tmp79, atslab_0) ; tmp82 = &ats_caselptrlab_mac(anairiats_sum_2, tmp79, atslab_3) ; tmp83 = &ats_caselptrlab_mac(anairiats_sum_2, tmp79, atslab_4) ; tmp84 = ats_ptrget_mac(ats_int_type, tmp73) ; tmp88 = ats_ptrget_mac(ats_ptr_type, tmp82) ; tmp85 = bst_size_039_ats_ptr_type_2cats_ptr_type (tmp88) ; tmp89 = ats_ptrget_mac(ats_ptr_type, tmp83) ; ats_ptrget_mac(ats_ptr_type, tmp75) = tmp89 ; tmp90 = atspre_isub (tmp84, tmp85) ; ats_ptrget_mac(ats_int_type, tmp73) = tmp90 ; ats_ptrget_mac(ats_ptr_type, tmp83) = arg0 ; tmp91 = atspre_iadd (tmp84, 1) ; ats_ptrget_mac(ats_int_type, tmp81) = tmp91 ; tmp72 = tmp79 ; } else { tmp93 = ats_ptrget_mac(ats_ptr_type, tmp76) ; tmp92 = bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type (tmp93, arg1, arg2, arg3) ; // if (tmp92 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp94 = &ats_caselptrlab_mac(anairiats_sum_2, tmp92, atslab_0) ; tmp95 = &ats_caselptrlab_mac(anairiats_sum_2, tmp92, atslab_3) ; tmp96 = &ats_caselptrlab_mac(anairiats_sum_2, tmp92, atslab_4) ; tmp97 = ats_ptrget_mac(ats_int_type, tmp73) ; tmp99 = ats_ptrget_mac(ats_ptr_type, tmp96) ; tmp98 = bst_size_039_ats_ptr_type_2cats_ptr_type (tmp99) ; tmp100 = ats_ptrget_mac(ats_ptr_type, tmp95) ; ats_ptrget_mac(ats_ptr_type, tmp76) = tmp100 ; tmp101 = atspre_isub (tmp97, tmp98) ; ats_ptrget_mac(ats_int_type, tmp73) = tmp101 ; ats_ptrget_mac(ats_ptr_type, tmp95) = arg0 ; tmp102 = atspre_iadd (tmp97, 1) ; ats_ptrget_mac(ats_int_type, tmp94) = tmp102 ; tmp72 = tmp92 ; } /* end of [if] */ break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp103 = (ats_sum_ptr_type)0 ; tmp104 = (ats_sum_ptr_type)0 ; tmp72 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp72, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, tmp72, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp72, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp72, atslab_3, tmp103) ; ats_selptrset_mac(anairiats_sum_2, tmp72, atslab_4, tmp104) ; break ; } while (0) ; return (tmp72) ; } /* end of [bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_078_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_bool_type, tmp105) ; ATSlocal (ats_int_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_int_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_int_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_bst_insert_random_078_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_11_1: tmp66 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp68 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp69 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp71 = ats_ptrget_mac(ats_int_type, tmp66) ; tmp70 = atsopt_map_lin_dice (1, tmp71) ; if (tmp70) { tmp65 = bst_insert_atroot_044_ats_ptr_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp106 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp67) ; tmp105 = atspre_ilte (tmp106, 0) ; if (tmp105) { tmp108 = ats_ptrget_mac(ats_ptr_type, tmp68) ; tmp107 = bst_insert_random_078_ats_ptr_type_2cats_ptr_type (tmp108, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp68) = tmp107 ; tmp110 = ats_ptrget_mac(ats_int_type, tmp66) ; tmp109 = atspre_iadd (tmp110, 1) ; ats_ptrget_mac(ats_int_type, tmp66) = tmp109 ; tmp65 = arg0 ; } else { tmp112 = ats_ptrget_mac(ats_ptr_type, tmp69) ; tmp111 = bst_insert_random_078_ats_ptr_type_2cats_ptr_type (tmp112, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp69) = tmp111 ; tmp114 = ats_ptrget_mac(ats_int_type, tmp66) ; tmp113 = atspre_iadd (tmp114, 1) ; ats_ptrget_mac(ats_int_type, tmp66) = tmp113 ; tmp65 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp115 = (ats_sum_ptr_type)0 ; tmp116 = (ats_sum_ptr_type)0 ; tmp65 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_3, tmp115) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_4, tmp116) ; break ; } while (0) ; return (tmp65) ; } /* end of [bst_insert_random_078_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_02777_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_map_insert_02777_ats_ptr_type_2cats_ptr_type: // tmp62 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp63 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp117 = ats_ptrget_mac(ats_ptr_type, tmp63) ; tmp64 = bst_insert_random_078_ats_ptr_type_2cats_ptr_type (tmp117, arg1, arg2, tmp62) ; ats_ptrget_mac(ats_ptr_type, tmp63) = tmp64 ; return /* (tmp61) */ ; } /* end of [map_insert_02777_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4569(line=173, offs=19) -- 4675(line=176, offs=4) */ ATSstaticdec() ats_void_type symenv_insert_fst_01927_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp118) ; __ats_lab_symenv_insert_fst_01927_ats_ptr_type: tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp58 = atspre_ref_get_view_ptr (tmp59) ; tmp60 = ats_selsin_mac(tmp58, atslab_1) ; tmp118 = ats_ptrget_mac(ats_ptr_type, tmp60) ; /* tmp57 = */ map_insert_02777_ats_ptr_type_2cats_ptr_type (tmp118, arg1, arg2) ; return /* (tmp57) */ ; } /* end of [symenv_insert_fst_01927_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 2255(line=73, offs=17) -- 2585(line=85, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add: tmp3 = symenv_remove_fst_01928_ats_ptr_type (statmp1, arg0) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (tmp3 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: ATS_FREE(tmp3) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (tmp3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: break ; } while (0) ; /* tmp2 = */ symenv_insert_fst_01927_ats_ptr_type (statmp1, arg0, arg1) ; return /* (tmp2) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_add] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_067_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_int_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_bst_search_067_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_17_1: tmp130 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp131 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp132 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp133 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp134 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp130) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (tmp134 != -1) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp135 = ats_ptrget_mac(ats_ptr_type, tmp132) ; arg0 = tmp135 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_067_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp134 != 1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp136 = ats_ptrget_mac(ats_ptr_type, tmp133) ; arg0 = tmp136 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_067_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (tmp134 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp129 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp129, atslab_0, tmp131) ; break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp129 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp129) ; } /* end of [bst_search_067_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_02779_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_map_search_02779_ats_ptr_type_2cats_ptr_type: // tmp127 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp128 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp137 = ats_ptrget_mac(ats_ptr_type, tmp128) ; tmp126 = bst_search_067_ats_ptr_type_2cats_ptr_type (tmp137, arg1, tmp127) ; return (tmp126) ; } /* end of [map_search_02779_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3703(line=144, offs=32) -- 4232(line=158, offs=4) */ ATSstaticdec() ats_ptr_type symmaplst_search_0229_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_symmaplst_search_0229_ats_ptr_type: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_24_1: tmp143 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp144 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp146 = ats_ptrget_mac(ats_ptr_type, tmp143) ; tmp145 = map_search_02779_ats_ptr_type_2cats_ptr_type (tmp146, arg1) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (tmp145 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp142 = tmp145 ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp145 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp148 = ats_ptrget_mac(ats_ptr_type, tmp144) ; tmp147 = symmaplst_search_0229_ats_ptr_type (tmp148, arg1) ; tmp142 = tmp147 ; break ; } while (0) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp142 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp142) ; } /* end of [symmaplst_search_0229_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4926(line=187, offs=19) -- 5334(line=202, offs=4) */ ATSstaticdec() ats_ptr_type symenv_search_all_01929_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_symenv_search_all_01929_ats_ptr_type: tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp122 = atspre_ref_get_view_ptr (tmp123) ; tmp124 = ats_selsin_mac(tmp122, atslab_1) ; tmp138 = ats_ptrget_mac(ats_ptr_type, tmp124) ; tmp125 = map_search_02779_ats_ptr_type_2cats_ptr_type (tmp138, arg1) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (tmp125 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp121 = tmp125 ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (tmp125 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp140 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp139 = atspre_ref_get_view_ptr (tmp140) ; tmp141 = ats_selsin_mac(tmp139, atslab_1) ; tmp149 = ats_ptrget_mac(ats_ptr_type, tmp141) ; tmp121 = symmaplst_search_0229_ats_ptr_type (tmp149, arg1) ; break ; } while (0) ; return (tmp121) ; } /* end of [symenv_search_all_01929_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 5404(line=205, offs=25) -- 5519(line=209, offs=4) */ ATSstaticdec() ats_ptr_type symenv_pervasive_search_01930_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_symenv_pervasive_search_01930_ats_ptr_type: tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_pervasive) ; tmp151 = atspre_ref_get_view_ptr (tmp152) ; tmp153 = ats_selsin_mac(tmp151, atslab_1) ; tmp154 = ats_ptrget_mac(ats_ptr_type, tmp153) ; tmp150 = symmaplst_search_0229_ats_ptr_type (tmp154, arg1) ; return (tmp150) ; } /* end of [symenv_pervasive_search_01930_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 2642(line=88, offs=18) -- 2975(line=101, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find: tmp120 = symenv_search_all_01929_ats_ptr_type (statmp1, arg0) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp120 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp119 = tmp120 ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp120 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp119 = symenv_pervasive_search_01930_ats_ptr_type (statmp1, arg0) ; break ; } while (0) ; return (tmp119) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 3049(line=104, offs=34) -- 3159(line=108, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_pervasive_add_topenv () { /* local vardec */ // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_pervasive_add_topenv: tmp156 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp1) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (statmp1, tmp156) ; return /* (tmp155) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_pervasive_add_topenv] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 3333(line=117, offs=17) -- 3550(line=124, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add: tmp159 = symenv_remove_fst_01928_ats_ptr_type (statmp157, arg0) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp159 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: ATS_FREE(tmp159) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (tmp159 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: break ; } while (0) ; /* tmp158 = */ symenv_insert_fst_01927_ats_ptr_type (statmp157, arg0, arg1) ; return /* (tmp158) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 3607(line=127, offs=18) -- 3840(line=135, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find: tmp162 = symenv_search_all_01929_ats_ptr_type (statmp157, arg0) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp162 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp161 = tmp162 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (tmp162 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp161 = symenv_pervasive_search_01930_ats_ptr_type (statmp157, arg0) ; break ; } while (0) ; return (tmp161) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_find] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 3914(line=138, offs=34) -- 4024(line=142, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_pervasive_add_topenv () { /* local vardec */ // ATSlocal_void (tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_pervasive_add_topenv: tmp164 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (statmp157) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (statmp157, tmp164) ; return /* (tmp163) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_fxtyenv_pervasive_add_topenv] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8374(line=278, offs=7) -- 8728(line=288, offs=6) */ ATSstaticdec() ats_ptr_type aux_25 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (anairiats_rec_4, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; __ats_lab_aux_25: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp177 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp178 = &ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; tmp179.atslab_0 = tmp175 ; tmp179.atslab_1 = tmp176 ; tmp180 = ats_ptrget_mac(ats_ptr_type, tmp177) ; tmp183 = ats_ptrget_mac(ats_ptr_type, tmp178) ; tmp182 = aux_25 (tmp183, arg1) ; tmp181 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp181, atslab_0, tmp179) ; ats_selptrset_mac(anairiats_sum_5, tmp181, atslab_1, tmp182) ; arg0 = tmp180 ; arg1 = tmp181 ; goto __ats_lab_aux_25 ; // tail call break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp174 = arg1 ; break ; } while (0) ; return (tmp174) ; } /* end of [aux_25] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8278(line=274, offs=22) -- 8777(line=291, offs=4) */ ATSstaticdec() ats_ptr_type bst_list_inf_0131_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_bst_list_inf_0131_ats_ptr_type_2cats_ptr_type: tmp184 = (ats_sum_ptr_type)0 ; tmp173 = aux_25 (arg0, tmp184) ; return (tmp173) ; } /* end of [bst_list_inf_0131_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 11607(line=396, offs=14) -- 11717(line=401, offs=4) */ ATSstaticdec() ats_ptr_type map_list_inf_02781_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp185) ; __ats_lab_map_list_inf_02781_ats_ptr_type_2cats_ptr_type: // tmp172 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp185 = ats_ptrget_mac(ats_ptr_type, tmp172) ; tmp171 = bst_list_inf_0131_ats_ptr_type_2cats_ptr_type (tmp185) ; return (tmp171) ; } /* end of [map_list_inf_02781_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 2766(line=101, offs=20) -- 2858(line=105, offs=4) */ ATSstaticdec() ats_ptr_type symmap_reflist_get_01922_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp186) ; __ats_lab_symmap_reflist_get_01922_ats_ptr_type: tmp169 = atspre_ref_get_view_ptr (arg0) ; tmp170 = ats_selsin_mac(tmp169, atslab_1) ; tmp186 = ats_ptrget_mac(ats_ptr_type, tmp170) ; tmp168 = map_list_inf_02781_ats_ptr_type_2cats_ptr_type (tmp186) ; return (tmp168) ; } /* end of [symmap_reflist_get_01922_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 4259(line=151, offs=7) -- 4628(line=162, offs=6) */ ATSstaticdec() ats_void_type loop_26 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp187) ; ATSlocal (anairiats_rec_4, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; // ATSlocal_void (tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; __ats_lab_loop_26: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp188 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp189 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp190 = ats_select_mac(tmp188, atslab_0) ; tmp191 = ats_select_mac(tmp188, atslab_1) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol_code (tmp190) ; /* tmp193 = */ atspre_print_string (ATSstrcst(" = ")) ; /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__print_fxty (tmp191) ; /* tmp195 = */ atspre_print_newline () ; arg0 = tmp189 ; goto __ats_lab_loop_26 ; // tail call break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; return /* (tmp187) */ ; } /* end of [loop_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 4119(line=147, offs=22) -- 4666(line=165, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__atsopt_fxtyenv_print () { /* local vardec */ // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__atsopt_fxtyenv_print: tmp166 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_reftop_get (statmp157) ; tmp167 = symmap_reflist_get_01922_ats_ptr_type (tmp166) ; /* tmp165 = */ loop_26 (tmp167) ; return /* (tmp165) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__atsopt_fxtyenv_print] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_02766_ats_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; __ats_lab_ref_make_elt_02766_ats_int_type: /* ats_int_type tmp198 ; */ tmp198 = arg0 ; tmp197 = atspre_ref_make_elt_tsz ((&tmp198), sizeof(ats_int_type)) ; return (tmp197) ; } /* end of [ref_make_elt_02766_ats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 4859(line=176, offs=28) -- 4881(line=176, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_get () { /* local vardec */ ATSlocal (ats_int_type, tmp199) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_get: tmp199 = ats_ptrget_mac(ats_int_type, statmp196) ; return (tmp199) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 4910(line=179, offs=18) -- 5006(line=182, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec () { /* local vardec */ // ATSlocal_void (tmp200) ; ATSlocal (ats_int_type, tmp201) ; ATSlocal (ats_int_type, tmp202) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec: tmp202 = ats_ptrget_mac(ats_int_type, statmp196) ; tmp201 = atspre_sub_int_int (tmp202, 1) ; ats_ptrget_mac(ats_int_type, statmp196) = tmp201 ; return /* (tmp200) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5064(line=185, offs=18) -- 5152(line=188, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc () { /* local vardec */ // ATSlocal_void (tmp203) ; ATSlocal (ats_int_type, tmp204) ; ATSlocal (ats_int_type, tmp205) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc: tmp205 = ats_ptrget_mac(ats_int_type, statmp196) ; tmp204 = atspre_add_int_int (tmp205, 1) ; ats_ptrget_mac(ats_int_type, statmp196) = tmp204 ; return /* (tmp203) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_level_inc] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 2338(line=81, offs=21) -- 2378(line=81, offs=61) */ ATSstaticdec() ats_void_type prerr_interror_0207_ () { /* local vardec */ // ATSlocal_void (tmp211) ; __ats_lab_prerr_interror_0207_: /* tmp211 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_symenv)")) ; return /* (tmp211) */ ; } /* end of [prerr_interror_0207_] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 6500(line=243, offs=6) -- 6648(line=247, offs=6) */ ATSstaticdec() ats_ptr_type abort_33 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; __ats_lab_abort_33: /* tmp210 = */ prerr_interror_0207_ () ; /* tmp212 = */ atspre_prerr_string (ATSstrcst(": symenv_pop: env.maplst is empty")) ; /* tmp213 = */ atspre_prerr_newline () ; /* tmp209 = */ ats_exit (1) ; return (tmp209) ; } /* end of [abort_33] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_035_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; // ATSlocal_void (tmp231) ; __ats_lab_bst_free_035_ats_ptr_type_2cats_ptr_type: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp229 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_3) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp231 = */ bst_free_035_ats_ptr_type_2cats_ptr_type (tmp229) ; arg0 = tmp230 ; goto __ats_lab_bst_free_035_ats_ptr_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: break ; } while (0) ; return /* (tmp228) */ ; } /* end of [bst_free_035_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_02775_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; __ats_lab_map_free_02775_ats_ptr_type_2cats_ptr_type: // tmp227 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp226 = */ bst_free_035_ats_ptr_type_2cats_ptr_type (tmp227) ; return /* (tmp226) */ ; } /* end of [map_free_02775_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3321(line=127, offs=28) -- 3347(line=127, offs=54) */ ATSstaticdec() ats_void_type symmap_free_01918_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp225) ; __ats_lab_symmap_free_01918_ats_ptr_type: /* tmp225 = */ map_free_02775_ats_ptr_type_2cats_ptr_type (arg0) ; return /* (tmp225) */ ; } /* end of [symmap_free_01918_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 6480(line=241, offs=12) -- 7119(line=264, offs=4) */ ATSstaticdec() ats_void_type symenv_pop_01932_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp208) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_symenv_pop_01932_ats_ptr_type: tmp215 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp214 = atspre_ref_get_view_ptr (tmp215) ; tmp216 = ats_selsin_mac(tmp214, atslab_1) ; tmp218 = ats_ptrget_mac(ats_ptr_type, tmp216) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (tmp218 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp219 = ats_caselptrlab_mac(anairiats_sum_1, tmp218, atslab_0) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_1, tmp218, atslab_1) ; ATS_FREE(tmp218) ; ats_ptrget_mac(ats_ptr_type, tmp216) = tmp220 ; tmp217 = tmp219 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (tmp218 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: tmp217 = abort_33 () ; break ; } while (0) ; tmp222 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp221 = atspre_ref_get_view_ptr (tmp222) ; tmp223 = ats_selsin_mac(tmp221, atslab_1) ; tmp232 = ats_ptrget_mac(ats_ptr_type, tmp223) ; /* tmp224 = */ symmap_free_01918_ats_ptr_type (tmp232) ; ats_ptrget_mac(ats_ptr_type, tmp223) = tmp217 ; return /* (tmp208) */ ; } /* end of [symenv_pop_01932_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5253(line=195, offs=16) -- 5339(line=198, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop () { /* local vardec */ // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop: /* tmp207 = */ symenv_pop_01932_ats_ptr_type (statmp1) ; /* tmp206 = */ symenv_pop_01932_ats_ptr_type (statmp157) ; return /* (tmp206) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5394(line=201, offs=17) -- 5481(line=204, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push () { /* local vardec */ // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push: /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (statmp1) ; /* tmp233 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (statmp157) ; return /* (tmp233) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_push] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9491(line=371, offs=6) -- 9645(line=375, offs=6) */ ATSstaticdec() ats_ptr_type abort_41 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; __ats_lab_abort_41: /* tmp239 = */ prerr_interror_0207_ () ; /* tmp240 = */ atspre_prerr_string (ATSstrcst(": symenv_localjoin: env.maplst is empty")) ; /* tmp241 = */ atspre_prerr_newline () ; /* tmp238 = */ ats_exit (1) ; return (tmp238) ; } /* end of [abort_41] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10685(line=372, offs=7) -- 11400(line=386, offs=23) */ ATSstaticdec() ats_ptr_type aux_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp273) ; __ats_lab_aux_43: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_46_1: tmp263 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp264 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_2) ; tmp265 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_3) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_4) ; ATS_FREE(arg1) ; tmp267 = aux_43 (arg0, tmp265, arg2) ; /* ats_int_type tmp268 ; */ /* ats_ptr_type tmp269 ; */ tmp270 = bst_remove_random_0101_ats_ptr_type_2cats_ptr_type (tmp267, tmp263, (&tmp268), (&tmp269), arg2) ; tmp271 = ats_selsin_mac(tmp270, atslab_2) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp269 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: ATS_FREE(tmp269) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp269 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: break ; } while (0) ; tmp273 = bst_insert_random_078_ats_ptr_type_2cats_ptr_type (tmp271, tmp263, tmp264, arg2) ; arg0 = tmp273 ; arg1 = tmp266 ; arg2 = arg2 ; goto __ats_lab_aux_43 ; // tail call break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: tmp262 = arg0 ; break ; } while (0) ; return (tmp262) ; } /* end of [aux_43] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10624(line=370, offs=10) -- 11531(line=391, offs=4) */ ATSstaticdec() ats_ptr_type map_join_02780_ats_ptr_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; __ats_lab_map_join_02780_ats_ptr_type_2cats_ptr_type: // tmp274 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp275 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; // tmp276 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; ATS_FREE(arg1) ; tmp278 = ats_ptrget_mac(ats_ptr_type, tmp275) ; tmp277 = aux_43 (tmp278, tmp276, tmp274) ; ats_ptrget_mac(ats_ptr_type, tmp275) = tmp277 ; tmp261 = arg0 ; return (tmp261) ; } /* end of [map_join_02780_ats_ptr_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9471(line=369, offs=18) -- 10587(line=406, offs=4) */ ATSstaticdec() ats_void_type symenv_localjoin_01937_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp237) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; // ATSlocal_void (tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp279) ; __ats_lab_symenv_localjoin_01937_ats_ptr_type: tmp243 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp242 = atspre_ref_get_view_ptr (tmp243) ; tmp244 = ats_selsin_mac(tmp242, atslab_1) ; tmp246 = ats_ptrget_mac(ats_ptr_type, tmp244) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (tmp246 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_1, tmp246, atslab_0) ; tmp248 = ats_caselptrlab_mac(anairiats_sum_1, tmp246, atslab_1) ; ATS_FREE(tmp246) ; ats_ptrget_mac(ats_ptr_type, tmp244) = tmp248 ; tmp245 = tmp247 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (tmp246 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: tmp245 = abort_41 () ; break ; } while (0) ; /* tmp249 = */ symmap_free_01918_ats_ptr_type (tmp245) ; tmp251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp250 = atspre_ref_get_view_ptr (tmp251) ; tmp252 = ats_selsin_mac(tmp250, atslab_1) ; tmp254 = ats_ptrget_mac(ats_ptr_type, tmp252) ; do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp254 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp255 = ats_caselptrlab_mac(anairiats_sum_1, tmp254, atslab_0) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_1, tmp254, atslab_1) ; ATS_FREE(tmp254) ; ats_ptrget_mac(ats_ptr_type, tmp252) = tmp256 ; tmp253 = tmp255 ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (tmp254 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp253 = abort_41 () ; break ; } while (0) ; tmp258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp257 = atspre_ref_get_view_ptr (tmp258) ; tmp259 = ats_selsin_mac(tmp257, atslab_1) ; tmp279 = ats_ptrget_mac(ats_ptr_type, tmp259) ; tmp260 = map_join_02780_ats_ptr_type_2cats_ptr_type (tmp253, tmp279) ; ats_ptrget_mac(ats_ptr_type, tmp259) = tmp260 ; return /* (tmp237) */ ; } /* end of [symenv_localjoin_01937_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5542(line=207, offs=22) -- 5639(line=210, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_localjoin () { /* local vardec */ // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_localjoin: /* tmp236 = */ symenv_localjoin_01937_ats_ptr_type (statmp1) ; /* tmp235 = */ symenv_localjoin_01937_ats_ptr_type (statmp157) ; return /* (tmp235) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5700(line=213, offs=17) -- 5787(line=216, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_save () { /* local vardec */ // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_save: /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (statmp1) ; /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (statmp157) ; return /* (tmp280) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_save] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 8295(line=320, offs=6) -- 8435(line=324, offs=6) */ ATSstaticdec() anairiats_rec_4 abort_47 () { /* local vardec */ ATSlocal (anairiats_rec_4, tmp285) ; // ATSlocal_void (tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; __ats_lab_abort_47: /* tmp286 = */ prerr_interror_0207_ () ; /* tmp287 = */ atspre_prerr_string (ATSstrcst(": symenv_restore: env.savedlst is empty")) ; /* tmp288 = */ atspre_prerr_newline () ; /* tmp285 = */ ats_exit (1) ; return (tmp285) ; } /* end of [abort_47] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3417(line=133, offs=3) -- 3607(line=138, offs=26) */ ATSstaticdec() ats_void_type symmaplst_free_0225_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; // ATSlocal_void (tmp310) ; __ats_lab_symmaplst_free_0225_ats_ptr_type: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp310 = */ symmap_free_01918_ats_ptr_type (tmp308) ; arg0 = tmp309 ; goto __ats_lab_symmaplst_free_0225_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: break ; } while (0) ; return /* (tmp307) */ ; } /* end of [symmaplst_free_0225_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 8226(line=317, offs=16) -- 9145(line=351, offs=4) */ ATSstaticdec() ats_void_type symenv_restore_01939_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp284) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (anairiats_rec_4, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (anairiats_rec_4, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; // ATSlocal_void (tmp306) ; ATSlocal (ats_ptr_type, tmp311) ; __ats_lab_symenv_restore_01939_ats_ptr_type: tmp290 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_savedlst) ; tmp289 = atspre_ref_get_view_ptr (tmp290) ; tmp291 = ats_selsin_mac(tmp289, atslab_1) ; tmp293 = ats_ptrget_mac(ats_ptr_type, tmp291) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp293 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp294 = ats_caselptrlab_mac(anairiats_sum_5, tmp293, atslab_0) ; tmp295 = ats_caselptrlab_mac(anairiats_sum_5, tmp293, atslab_1) ; ATS_FREE(tmp293) ; ats_ptrget_mac(ats_ptr_type, tmp291) = tmp295 ; tmp292 = tmp294 ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (tmp293 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: tmp292 = abort_47 () ; break ; } while (0) ; tmp296 = ats_select_mac(tmp292, atslab_0) ; tmp297 = ats_select_mac(tmp292, atslab_1) ; tmp299 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp298 = atspre_ref_get_view_ptr (tmp299) ; tmp300 = ats_selsin_mac(tmp298, atslab_1) ; tmp302 = ats_ptrget_mac(ats_ptr_type, tmp300) ; /* tmp301 = */ symmap_free_01918_ats_ptr_type (tmp302) ; ats_ptrget_mac(ats_ptr_type, tmp300) = tmp296 ; tmp304 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp303 = atspre_ref_get_view_ptr (tmp304) ; tmp305 = ats_selsin_mac(tmp303, atslab_1) ; tmp311 = ats_ptrget_mac(ats_ptr_type, tmp305) ; /* tmp306 = */ symmaplst_free_0225_ats_ptr_type (tmp311) ; ats_ptrget_mac(ats_ptr_type, tmp305) = tmp297 ; return /* (tmp284) */ ; } /* end of [symenv_restore_01939_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 5846(line=219, offs=20) -- 5939(line=222, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_restore () { /* local vardec */ // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_restore: /* tmp283 = */ symenv_restore_01939_ats_ptr_type (statmp1) ; /* tmp282 = */ symenv_restore_01939_ats_ptr_type (statmp157) ; return /* (tmp282) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__trans1_env_restore] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2766(line=87, offs=3) -- 2870(line=89, offs=24) */ ATSstaticdec() ats_void_type chain_insert_0377_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) { /* local vardec */ // ATSlocal_void (tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_chain_insert_0377_ats_ptr_type_2canairiats_rec_6: tmp337 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp337, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp337, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp337, atslab_2, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp337 ; return /* (tmp336) */ ; } /* end of [chain_insert_0377_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 4157(line=133, offs=3) -- 4487(line=143, offs=4) */ ATSstaticdec() ats_void_type table_insert_0403_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, anairiats_rec_6 arg3) { /* local vardec */ // ATSlocal_void (tmp332) ; ATSlocal (ats_size_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; __ats_lab_table_insert_0403_ats_ptr_type_2canairiats_rec_6: tmp333 = atspre_size1_of_int1 (arg1) ; tmp334 = atspre_array_ptr_takeout_tsz (arg0, tmp333, sizeof(ats_ptr_type)) ; tmp335 = ats_selsin_mac(tmp334, atslab_2) ; /* tmp332 = */ chain_insert_0377_ats_ptr_type_2canairiats_rec_6 (tmp335, arg2, arg3) ; return /* (tmp332) */ ; } /* end of [table_insert_0403_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5954(line=202, offs=20) -- 6152(line=209, offs=4) */ ATSstaticdec() ats_void_type ht_insert_0434_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) { /* local vardec */ // ATSlocal_void (tmp326) ; ATSlocal (ats_uint_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_int_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_int_type, tmp338) ; ATSlocal (ats_int_type, tmp339) ; __ats_lab_ht_insert_0434_ats_ptr_type_2canairiats_rec_6: tmp328 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_hash) ; tmp327 = ((ats_uint_type(*)(ats_ptr_type))tmp328) (arg1) ; tmp330 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_size) ; tmp329 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp327), tmp330) ; /* tmp331 = */ table_insert_0403_ats_ptr_type_2canairiats_rec_6 (&ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_table[0]), tmp329, arg1, arg2) ; tmp339 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_nitm) ; tmp338 = atspre_add_int_int (tmp339, 1) ; ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_nitm) = tmp338 ; return /* (tmp326) */ ; } /* end of [ht_insert_0434_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 6239(line=213, offs=26) -- 6492(line=221, offs=4) */ ATSstaticdec() ats_void_type ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (anairiats_rec_6, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; // ATSlocal_void (tmp356) ; __ats_lab_ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6: do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp354 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp355 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; ATS_FREE(arg1) ; /* tmp356 = */ ht_insert_0434_ats_ptr_type_2canairiats_rec_6 (arg0, tmp353, tmp354) ; arg0 = arg0 ; arg1 = tmp355 ; goto __ats_lab_ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6 ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: break ; } while (0) ; return /* (tmp352) */ ; } /* end of [ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8835(line=312, offs=7) -- 9180(line=321, offs=6) */ ATSstaticdec() ats_void_type loop_55 (ats_int_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp348) ; ATSlocal (ats_bool_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; // ATSlocal_void (tmp351) ; ATSlocal (ats_int_type, tmp357) ; __ats_lab_loop_55: tmp349 = atspre_ilt (arg3, arg0) ; if (tmp349) { tmp350 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__table_chain_get (&ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_table[0]), arg3) ; /* tmp351 = */ ht_insert_chain_0440_ats_ptr_type_2canairiats_rec_6 (arg2, tmp350) ; tmp357 = atspre_iadd (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp357 ; goto __ats_lab_loop_55 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp348) */ ; } /* end of [loop_55] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 8621(line=308, offs=5) -- 9290(line=326, offs=4) */ ATSstaticdec() ats_ptr_type htp_resize_0463_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_int_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; // ATSlocal_void (tmp358) ; // ATSlocal_void (tmp359) ; __ats_lab_htp_resize_0463_ats_ptr_type_2canairiats_rec_6: tmp343 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_size) ; tmp345 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_hash) ; tmp346 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_eq) ; tmp344 = ats_htp_make (tmp345, tmp346, arg1) ; tmp347 = ats_selsin_mac(tmp344, atslab_1) ; /* tmp358 = */ loop_55 (tmp343, arg0, tmp347, 0) ; /* tmp359 = */ __ats_htp_free (arg0) ; tmp342 = tmp347 ; return (tmp342) ; } /* end of [htp_resize_0463_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 11172(line=403, offs=16) -- 11905(line=428, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_insert_02788_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_6 arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_bool_type, tmp320) ; ATSlocal (ats_int_type, tmp321) ; ATSlocal (ats_int_type, tmp322) ; ATSlocal (ats_bool_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; // ATSlocal_void (tmp325) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_int_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; // ATSlocal_void (tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; __ats_lab_hashtbl_insert_02788_ats_ptr_type_2canairiats_rec_6: tmp316 = atspre_ref_get_view_ptr (arg0) ; tmp317 = ats_selsin_mac(tmp316, atslab_1) ; tmp318 = ats_ptrget_mac(ats_ptr_type, tmp317) ; tmp319 = ats_selsin_mac(tmp318, atslab_1) ; tmp320 = atspre_pneq (tmp319, atspre_null_ptr) ; if (tmp320) { tmp321 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, tmp319), atslab_size) ; tmp322 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_7, tmp319), atslab_nitm) ; tmp324 = atspre_imul (tmp321, 5) ; tmp323 = atspre_lt_int_int (tmp322, tmp324) ; if (tmp323) { /* tmp325 = */ ht_insert_0434_ats_ptr_type_2canairiats_rec_6 (tmp319, arg1, arg2) ; tmp340 = tmp319 ; ats_ptrget_mac(ats_ptr_type, tmp317) = tmp340 ; tmp315 = (ats_sum_ptr_type)0 ; } else { tmp360 = atspre_iadd (tmp321, tmp321) ; tmp341 = htp_resize_0463_ats_ptr_type_2canairiats_rec_6 (tmp319, tmp360) ; tmp361 = ats_selsin_mac(tmp341, atslab_1) ; /* tmp362 = */ ht_insert_0434_ats_ptr_type_2canairiats_rec_6 (tmp361, arg1, arg2) ; tmp363 = tmp361 ; ats_ptrget_mac(ats_ptr_type, tmp317) = tmp363 ; tmp315 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } else { tmp364 = tmp319 ; ats_ptrget_mac(ats_ptr_type, tmp317) = tmp364 ; tmp315 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp315, atslab_0, arg2) ; } /* end of [if] */ return (tmp315) ; } /* end of [hashtbl_insert_02788_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 6298(line=240, offs=21) -- 6604(line=250, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (anairiats_rec_6, tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert: tmp365.atslab_0 = arg1 ; tmp365.atslab_1 = arg2 ; tmp314 = hashtbl_insert_02788_ats_ptr_type_2canairiats_rec_6 (statmp312, arg0, tmp365) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (tmp314 == (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: ATS_FREE(tmp314) ; /* tmp366 = */ prerr_interror_0 () ; /* tmp367 = */ atspre_prerr_string (ATSstrcst(": [staload_file_insert] failed.")) ; /* tmp368 = */ atspre_prerr_newline () ; /* tmp313 = */ ats_exit (1) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (tmp314 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: break ; } while (0) ; return /* (tmp313) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_insert] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 2269(line=73, offs=3) -- 2695(line=83, offs=4) */ ATSstaticdec() ats_ptr_type chain_search_0368_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (anairiats_rec_6, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_bool_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; __ats_lab_chain_search_0368_ats_ptr_type_2canairiats_rec_6: do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp389 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_2) ; tmp390 = ((ats_bool_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp387) ; if (tmp390) { tmp386 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp386, atslab_0, tmp388) ; } else { tmp391 = ats_ptrget_mac(ats_ptr_type, tmp389) ; arg0 = tmp391 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_chain_search_0368_ats_ptr_type_2canairiats_rec_6 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: tmp386 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp386) ; } /* end of [chain_search_0368_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 3727(line=119, offs=3) -- 4085(line=129, offs=4) */ ATSstaticdec() ats_ptr_type table_search_0393_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_size_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp392) ; __ats_lab_table_search_0393_ats_ptr_type_2canairiats_rec_6: tmp383 = atspre_size1_of_int1 (arg1) ; tmp384 = atspre_array_ptr_takeout_tsz (arg0, tmp383, sizeof(ats_ptr_type)) ; tmp385 = ats_selsin_mac(tmp384, atslab_2) ; tmp392 = ats_ptrget_mac(ats_ptr_type, tmp385) ; tmp382 = chain_search_0368_ats_ptr_type_2canairiats_rec_6 (tmp392, arg2, arg3) ; return (tmp382) ; } /* end of [table_search_0393_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 5707(line=192, offs=20) -- 5890(line=199, offs=4) */ ATSstaticdec() ats_ptr_type ht_search_0429_ats_ptr_type_2canairiats_rec_6 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_uint_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_int_type, tmp380) ; ATSlocal (ats_int_type, tmp381) ; ATSlocal (ats_ptr_type, tmp393) ; __ats_lab_ht_search_0429_ats_ptr_type_2canairiats_rec_6: tmp379 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_hash) ; tmp378 = ((ats_uint_type(*)(ats_ptr_type))tmp379) (arg1) ; tmp381 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_size) ; tmp380 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp378), tmp381) ; tmp393 = ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_eq) ; tmp377 = table_search_0393_ats_ptr_type_2canairiats_rec_6 (&ats_select_mac(ats_ptrget_mac(anairiats_rec_7, arg0), atslab_table[0]), tmp380, arg1, tmp393) ; return (tmp377) ; } /* end of [ht_search_0429_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_hashtbl.dats: 10666(line=380, offs=16) -- 11067(line=396, offs=4) */ ATSstaticdec() ats_ptr_type hashtbl_search_02787_ats_ptr_type_2canairiats_rec_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_bool_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; __ats_lab_hashtbl_search_02787_ats_ptr_type_2canairiats_rec_6: tmp371 = atspre_ref_get_view_ptr (arg0) ; tmp372 = ats_selsin_mac(tmp371, atslab_1) ; tmp373 = ats_ptrget_mac(ats_ptr_type, tmp372) ; tmp374 = ats_selsin_mac(tmp373, atslab_1) ; tmp375 = atspre_pneq (tmp374, atspre_null_ptr) ; if (tmp375) { tmp376 = ht_search_0429_ats_ptr_type_2canairiats_rec_6 (tmp374, arg1) ; tmp394 = tmp374 ; ats_ptrget_mac(ats_ptr_type, tmp372) = tmp394 ; tmp370 = tmp376 ; } else { tmp395 = tmp374 ; ats_ptrget_mac(ats_ptr_type, tmp372) = tmp395 ; tmp370 = (ats_sum_ptr_type)0 ; } /* end of [if] */ return (tmp370) ; } /* end of [hashtbl_search_02787_ats_ptr_type_2canairiats_rec_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans1_env.dats: 6668(line=253, offs=21) -- 6726(line=254, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_search (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_search: tmp369 = hashtbl_search_02787_ats_ptr_type_2canairiats_rec_6 (statmp312, arg0) ; return (tmp369) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload_file_search] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp157, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp196, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp312, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp1 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () ; statmp157 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () ; statmp196 = ref_make_elt_02766_ats_int_type (0) ; statmp312 = ATS_2d0_2e2_2e11_2src_2ats_hashtbl_2esats__hashtbl_str_make_hint (7) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans1_env_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans4_dats.c0000664000175000017500000066477512223166160021363 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_9 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_hipat_loc ; ats_ptr_type atslab_hipat_node ; ats_ptr_type atslab_hipat_typ ; ats_ptr_type atslab_hipat_asvar ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_hiexp_loc ; ats_ptr_type atslab_hiexp_node ; ats_ptr_type atslab_hiexp_typ ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_d3lab1_loc ; ats_ptr_type atslab_d3lab1_node ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_m3atch_loc ; ats_ptr_type atslab_m3atch_exp ; ats_ptr_type atslab_m3atch_pat ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_c3lau_loc ; ats_ptr_type atslab_c3lau_pat ; ats_ptr_type atslab_c3lau_gua ; ats_int_type atslab_c3lau_seq ; ats_int_type atslab_c3lau_neg ; ats_ptr_type atslab_c3lau_exp ; } anairiats_rec_23 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_24 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_25 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_26 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_27 ; typedef struct { ats_ptr_type atslab_sc3lau_loc ; ats_ptr_type atslab_sc3lau_pat ; ats_ptr_type atslab_sc3lau_exp ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_f3undec_loc ; ats_ptr_type atslab_f3undec_var ; ats_ptr_type atslab_f3undec_def ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_v3aldec_loc ; ats_ptr_type atslab_v3aldec_pat ; ats_ptr_type atslab_v3aldec_def ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_v3ardec_loc ; ats_int_type atslab_v3ardec_knd ; ats_ptr_type atslab_v3ardec_dvar_ptr ; ats_ptr_type atslab_v3ardec_dvar_viw ; ats_ptr_type atslab_v3ardec_typ ; ats_ptr_type atslab_v3ardec_ini ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_i3mpdec_loc ; ats_ptr_type atslab_i3mpdec_cst ; ats_ptr_type atslab_i3mpdec_decarg ; ats_ptr_type atslab_i3mpdec_tmparg ; ats_ptr_type atslab_i3mpdec_def ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_d3ec_loc ; ats_ptr_type atslab_d3ec_node ; } anairiats_rec_33 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tstring_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrinit_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrpsz_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_ptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_var_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ebool_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecaseof_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Echar_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Econ_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecstsp_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecrypt_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eextval_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efix_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloatsp_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efoldat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efreeat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eif_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eint_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eintsp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_dyn_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elaminit_dyn_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_met_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_sta_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_delay_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_ldelay_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_force_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elet_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloop_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloopexn_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elst_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_var_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eraise_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erec_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erefarg_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Escaseof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esif_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estring_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estruct_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etrywith_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_ptr_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_var_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ewhere_59) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Csaspdec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdcstdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdatdec_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cexndec_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextype_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextval_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextcode_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_par_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_rec_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cfundecs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvardecs_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cimpdec_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clocal_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cstaload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdynload_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SIZEOF) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3exp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ref) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_varetize) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_vararg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_ann) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_any) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_as) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool) (ats_ptr_type, ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_char) (ats_ptr_type, ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con_any) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_lst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_rec) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_string) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq_simplify) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_app) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrpsz) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool) (ats_ptr_type, ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof_if) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_castfn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_char) (ats_ptr_type, ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cstsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_dynload) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_fix) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_float) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_floatsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_freeat) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_intsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lam) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_laminit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_delay) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_ldelay) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_force) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loop) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loopexn) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lst) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_raise) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sif) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sizeof) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_string) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpcst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpvar) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_top) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_trywith) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_lab) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_ind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__himat_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiclau_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_saspdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dcstdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_datdec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_exndec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extern) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extype) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hifundec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_fundecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivaldec_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_par) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_rec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivardec_make) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_vardecs) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_make) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_prf_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec_prf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_local) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_staload) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__d3explst_funarg_tr) (ats_bool_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_the_dyncstset_get) () ; ATSextern_fun(ats_void_type, atsopt_the_dyncstsetlst_push) () ; ATSextern_fun(ats_ptr_type, atsopt_the_dyncstsetlst_pop) () ; ATSextern_fun(ats_void_type, atsopt_the_dyncstset_add_if) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error4_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_ptr_type hityp_ptr_abs_3 (ats_ptr_type arg0) ; static ats_ptr_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2exp_app_tr_named_4 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ref_type arg5) ; static ats_ptr_type s2Var_tr_named_6 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_void_type update_ifnot_named_7 (ats_ref_type arg0, ats_ptr_type arg1, ats_bool_type arg2) ; static ats_ptr_type s2explst_tr_named_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2explst_tr_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2explstlst_tr_named_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2explstlst_tr_11 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux1_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux2_14 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type s2explst_npf_tr_named_12 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type s2explst_npf_tr_15 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux1_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type aux2_18 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type labs2explst_npf_tr_named_16 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) ; static ats_ptr_type err_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type __ats_fun_23 (ats_ptr_type arg0) ; static ats_ptr_type hipatlst_get_type_22 (ats_ptr_type arg0) ; static ats_bool_type p3at_is_proof_24 (ats_ptr_type arg0) ; static ats_ptr_type aux_26 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p3atlst_arg_tr_25 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_28 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labp3atlst_arg_tr_27 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_32 (ats_ptr_type arg0) ; static ats_ptr_type hiexplst_get_type_31 (ats_ptr_type arg0) ; static ats_bool_type d3exp_is_proof_33 (ats_ptr_type arg0) ; static ats_ptr_type aux0_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_37 (ats_ptr_type arg0) ; static ats_ptr_type aux1_36 (ats_bool_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_clo_ptr_type aux1_36_closure_make (ats_bool_type env0) ; static ats_ptr_type aux1_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux2_38 (ats_bool_type env0, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux2_38_closure_make (ats_bool_type env0) ; static ats_ptr_type aux2_38_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_40 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3explst_arg_tr_39 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_42 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labd3explst_arg_tr_41 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3exp_cst_tr_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d3exp_seq_tr_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d3exp_tmpcst_tr_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d3exp_tmpvar_tr_46 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d3lab1_tr_47 (ats_ptr_type arg0) ; static ats_ptr_type d3lab1lst_tr_48 (ats_ptr_type arg0) ; static ats_ptr_type m3atch_tr_49 (ats_ptr_type arg0) ; static ats_ptr_type m3atchlst_tr_50 (ats_ptr_type arg0) ; static ats_ptr_type c3lau_tr_51 (ats_ptr_type arg0) ; static ats_void_type aux_53 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type c3laulst_tr_52 (ats_ptr_type arg0) ; static ats_void_type labd3explst_prf_tr_57 (ats_ptr_type arg0) ; static ats_void_type f_59 (ats_ptr_type arg0) ; static ats_void_type c3laulst_prf_tr_58 (ats_ptr_type arg0) ; static ats_void_type f_61 (ats_ptr_type arg0) ; static ats_ptr_type f3undec_tr_63 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_65 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_65_closure_make (ats_ptr_type env0) ; static ats_ptr_type __ats_fun_65_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type f3undeclst_tr_64 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type f3undeclst_prf_tr_66 (ats_ptr_type arg0) ; static ats_ptr_type v3aldec_tr_67 (ats_ptr_type arg0) ; static ats_ptr_type v3aldeclst_tr_68 (ats_ptr_type arg0) ; static ats_ptr_type v3ardec_tr_69 (ats_ptr_type arg0) ; static ats_ptr_type v3ardeclst_tr_70 (ats_ptr_type arg0) ; static ats_void_type v3aldeclst_prf_tr_71 (ats_ptr_type arg0) ; static ats_ptr_type i3mpdec_tr_72 (ats_ptr_type arg0) ; static ats_void_type aux0_74 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux1_75 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux0_74_0aux1_75 (ats_int_type arg0, ...) ; static ats_void_type aux_78 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 2212(line=75, offs=4) -- 2299(line=77, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_error4_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error4_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(4)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error4_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 2333(line=79, offs=4) -- 2388(line=79, offs=59) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans4)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 2392(line=80, offs=4) -- 2500(line=82, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans4)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 2557(line=86, offs=4) -- 2646(line=87, offs=55) */ ATSstaticdec() ats_ptr_type hityp_ptr_abs_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; __ats_lab_hityp_ptr_abs_3: tmp6 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (arg0) ; if (tmp6) { tmp5 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; } else { tmp5 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs ; } /* end of [if] */ return (tmp5) ; } /* end of [hityp_ptr_abs_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 3851(line=130, offs=19) -- 4491(line=144, offs=22) */ ATSstaticdec() ats_ptr_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; __ats_lab_aux_5: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_1 ; } __ats_lab_5_2: tmp17 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp19 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp20 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp21 = aux_5 (tmp18, tmp20) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (tmp21, tmp17, tmp19) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_7_1 ; } __ats_lab_6_2: tmp16 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: __ats_lab_7_2: /* tmp22 = */ prerr_interror_1 () ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(": s2exp_app_tr: S2Eapp: arity error")) ; /* tmp24 = */ atspre_prerr_newline () ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp16) ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 3103(line=104, offs=5) -- 5050(line=161, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_app_tr_named_4 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ref_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_s2exp_app_tr_named_4: tmp8 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg3), atslab_s2exp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp8)->tag != 4) { goto __ats_lab_11_0 ; } __ats_lab_0_1: tmp9 = ats_caselptrlab_mac(anairiats_sum_2, tmp8, atslab_0) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp10 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs (tmp9) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp10 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, tmp10, atslab_0) ; do { /* branch: __ats_lab_3 */ __ats_lab_3_0: if (tmp11 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_3_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_3, tmp11, atslab_0) ; tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp12), atslab_s2exp_node) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp13)->tag != 14) { goto __ats_lab_8_0 ; } __ats_lab_4_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_4, tmp13, atslab_0) ; tmp15 = ats_caselptrlab_mac(anairiats_sum_4, tmp13, atslab_1) ; tmp25 = aux_5 (tmp14, arg4) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp25, tmp15) ; tmp7 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, arg1, tmp26, arg5) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp7 = hityp_ptr_abs_3 (arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp11 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp7 = hityp_ptr_abs_3 (arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (tmp10 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp7 = hityp_ptr_abs_3 (arg2) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp7 = hityp_ptr_abs_3 (arg2) ; break ; } while (0) ; return (tmp7) ; } /* end of [s2exp_app_tr_named_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 5102(line=165, offs=5) -- 5695(line=184, offs=4) */ ATSstaticdec() ats_ptr_type s2Var_tr_named_6 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_s2Var_tr_named_6: tmp28 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg2) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp28 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp29 = ats_caselptrlab_mac(anairiats_sum_5, tmp28, atslab_0) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp29) ; tmp27 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, arg1, tmp30, arg3) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp28 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp31 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (arg2) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp31 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_5, tmp31, atslab_0) ; tmp33 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp32) ; tmp27 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, arg1, tmp33, arg3) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp31 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp27 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs ; break ; } while (0) ; break ; } while (0) ; return (tmp27) ; } /* end of [s2Var_tr_named_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 5748(line=188, offs=4) -- 5903(line=191, offs=67) */ ATSstaticdec() ats_void_type update_ifnot_named_7 (ats_ref_type arg0, ats_ptr_type arg1, ats_bool_type arg2) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_bool_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_update_ifnot_named_7: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (ats_ptrget_mac(ats_ptr_type, arg0) == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (ats_ptrget_mac(ats_ptr_type, arg0) != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp35 = atspre_neg_bool (arg2) ; if (tmp35) { tmp36 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp36, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp36 ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; return /* (tmp34) */ ; } /* end of [update_ifnot_named_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 5961(line=196, offs=5) -- 6360(line=207, offs=31) */ ATSstaticdec() ats_ptr_type s2explst_tr_named_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_bool_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_s2explst_tr_named_8: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; /* ats_bool_type tmp40 ; */ tmp40 = ats_false_bool ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, 0, tmp38, (&tmp40)) ; /* tmp42 = */ update_ifnot_named_7 (arg2, tmp38, tmp40) ; tmp43 = s2explst_tr_named_8 (arg0, tmp39, arg2) ; tmp37 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp37, atslab_0, tmp41) ; ats_selptrset_mac(anairiats_sum_5, tmp37, atslab_1, tmp43) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp37 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp37) ; } /* end of [s2explst_tr_named_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 6396(line=210, offs=5) -- 6531(line=214, offs=4) */ ATSstaticdec() ats_ptr_type s2explst_tr_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_s2explst_tr_9: /* ats_ptr_type tmp45 ; */ tmp45 = (ats_sum_ptr_type)0 ; tmp44 = s2explst_tr_named_8 (arg0, arg1, (&tmp45)) ; return (tmp44) ; } /* end of [s2explst_tr_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 6582(line=218, offs=5) -- 6905(line=226, offs=31) */ ATSstaticdec() ats_ptr_type s2explstlst_tr_named_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_s2explstlst_tr_named_10: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp48 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp49 = s2explst_tr_named_8 (arg0, tmp47, arg2) ; tmp50 = s2explstlst_tr_named_10 (arg0, tmp48, arg2) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp46, atslab_0, tmp49) ; ats_selptrset_mac(anairiats_sum_5, tmp46, atslab_1, tmp50) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp46 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp46) ; } /* end of [s2explstlst_tr_named_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 6944(line=229, offs=5) -- 7093(line=233, offs=4) */ ATSstaticdec() ats_ptr_type s2explstlst_tr_11 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_s2explstlst_tr_11: /* ats_ptr_type tmp52 ; */ tmp52 = (ats_sum_ptr_type)0 ; tmp51 = s2explstlst_tr_named_10 (arg0, arg1, (&tmp52)) ; return (tmp51) ; } /* end of [s2explstlst_tr_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 7250(line=241, offs=7) -- 7749(line=255, offs=33) */ ATSstaticdec() ats_ptr_type aux1_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_bool_type, tmp57) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; __ats_lab_aux1_13: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp56 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp55) ; if (tmp57) { arg0 = arg0 ; arg1 = tmp56 ; arg2 = arg2 ; goto __ats_lab_aux1_13 ; // tail call } else { /* ats_bool_type tmp58 ; */ tmp58 = ats_false_bool ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, 0, tmp55, (&tmp58)) ; /* tmp60 = */ update_ifnot_named_7 (arg2, tmp55, tmp58) ; tmp61 = aux1_13 (arg0, tmp56, arg2) ; tmp54 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp54, atslab_0, tmp59) ; ats_selptrset_mac(anairiats_sum_5, tmp54, atslab_1, tmp61) ; } /* end of [if] */ break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp54 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp54) ; } /* end of [aux1_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 7796(line=257, offs=7) -- 8115(line=266, offs=8) */ ATSstaticdec() ats_ptr_type aux2_14 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_bool_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_int_type, tmp65) ; __ats_lab_aux2_14: tmp63 = atspre_gt_int_int (arg1, 0) ; if (tmp63) { do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; tmp65 = atspre_sub_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp65 ; arg2 = tmp64 ; arg3 = arg3 ; goto __ats_lab_aux2_14 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp62 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } else { tmp62 = aux1_13 (arg0, arg2, arg3) ; } /* end of [if] */ return (tmp62) ; } /* end of [aux2_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 7144(line=237, offs=5) -- 8186(line=270, offs=4) */ ATSstaticdec() ats_ptr_type s2explst_npf_tr_named_12 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_s2explst_npf_tr_named_12: tmp53 = aux2_14 (arg0, arg1, arg2, arg3) ; return (tmp53) ; } /* end of [s2explst_npf_tr_named_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 8226(line=272, offs=5) -- 8384(line=276, offs=4) */ ATSstaticdec() ats_ptr_type s2explst_npf_tr_15 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_s2explst_npf_tr_15: /* ats_ptr_type tmp67 ; */ tmp67 = (ats_sum_ptr_type)0 ; tmp66 = s2explst_npf_tr_named_12 (arg0, arg1, arg2, (&tmp67)) ; return (tmp66) ; } /* end of [s2explst_npf_tr_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 8555(line=284, offs=7) -- 9199(line=302, offs=45) */ ATSstaticdec() ats_ptr_type aux1_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_bool_type, tmp73) ; ATSlocal (ats_bool_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_aux1_17: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp71 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp72 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; tmp73 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp71) ; if (tmp73) { arg0 = arg0 ; arg1 = tmp72 ; arg2 = arg2 ; goto __ats_lab_aux1_17 ; // tail call } else { /* ats_bool_type tmp74 ; */ tmp74 = ats_false_bool ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, 0, tmp71, (&tmp74)) ; /* tmp76 = */ update_ifnot_named_7 (arg2, tmp71, tmp74) ; tmp77 = aux1_17 (arg0, tmp72, arg2) ; tmp69 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp69, atslab_0, tmp70) ; ats_selptrset_mac(anairiats_sum_6, tmp69, atslab_1, tmp75) ; ats_selptrset_mac(anairiats_sum_6, tmp69, atslab_2, tmp77) ; } /* end of [if] */ break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp69 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp69) ; } /* end of [aux1_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 9225(line=304, offs=7) -- 9582(line=313, offs=8) */ ATSstaticdec() ats_ptr_type aux2_18 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_bool_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; __ats_lab_aux2_18: tmp79 = atspre_gt_int_int (arg1, 0) ; if (tmp79) { do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_2) ; tmp81 = atspre_sub_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp81 ; arg2 = tmp80 ; arg3 = arg3 ; goto __ats_lab_aux2_18 ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp78 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } else { tmp78 = aux1_17 (arg0, arg2, arg3) ; } /* end of [if] */ return (tmp78) ; } /* end of [aux2_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 8439(line=280, offs=5) -- 9654(line=317, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_npf_tr_named_16 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_labs2explst_npf_tr_named_16: tmp68 = aux2_18 (arg0, arg1, arg2, arg3) ; return (tmp68) ; } /* end of [labs2explst_npf_tr_named_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 10096(line=333, offs=6) -- 10433(line=342, offs=6) */ ATSstaticdec() ats_ptr_type err_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; __ats_lab_err_20: /* tmp86 = */ prerr_loc_error4_0 (arg0) ; /* tmp87 = */ atsopt_debug_prerrf (ATSstrcst(": [%s]: s2exp_tr"), ATSstrcst("ats_trans4.dats")) ; /* tmp88 = */ atspre_prerr_string (ATSstrcst(": a template argument is not a type")) ; /* tmp89 = */ atspre_prerr_string (ATSstrcst(": s2t0 = ")) ; /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg1) ; /* tmp91 = */ atspre_prerr_string (ATSstrcst("; s2e0 = ")) ; /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg2) ; /* tmp93 = */ atspre_prerr_newline () ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp85) ; } /* end of [err_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 9739(line=322, offs=16) -- 15415(line=475, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_int_type, tmp103) ; ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_bool_type, tmp107) ; ATSlocal (ats_int_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_int_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_bool_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_bool_type, tmp125) ; ATSlocal (ats_bool_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_int_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_bool_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named: tmp83 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp84 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp83), atslab_s2exp_srt) ; tmp94 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp83), atslab_s2exp_node) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp94)->tag != 0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_0) ; tmp96 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_1) ; tmp97 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, tmp83), atslab_s2exp_srt) ; tmp82 = s2exp_app_tr_named_4 (arg0, arg1, tmp97, tmp95, tmp96, arg3) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp94)->tag != 3) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_2, tmp94, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp98 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp94)->tag != 4) { goto __ats_lab_38_0 ; } __ats_lab_32_1: tmp99 = ats_caselptrlab_mac(anairiats_sum_2, tmp94, atslab_0) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp100 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs (tmp99) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_34_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_3, tmp100, atslab_0) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp101 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_3, tmp101, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp102 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (tmp101 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp82 = hityp_ptr_abs_3 (tmp84) ; break ; } while (0) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp100 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp82 = hityp_ptr_abs_3 (tmp84) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp94)->tag != 2) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_7, tmp94, atslab_0) ; tmp104 = atspre_neq_int_int (tmp103, 0) ; if (tmp104) { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; } else { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_abs ; } /* end of [if] */ break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp94)->tag != 5) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp94)->tag != 6) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp105 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_0) ; tmp106 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_1) ; tmp107 = atspre_gt_int_int (arg1, 0) ; if (tmp107) { tmp108 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf (tmp105) ; tmp109 = s2explst_npf_tr_15 (arg0, tmp108, tmp106) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp (tmp105, tmp109) ; } else { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; } /* end of [if] */ break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp94)->tag != 9) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_8, tmp94, atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp110 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp94)->tag != 10) { goto __ats_lab_45_0 ; } __ats_lab_42_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_0) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_1) ; /* ats_ptr_type tmp113 ; */ tmp113 = (ats_sum_ptr_type)0 ; tmp114 = s2explstlst_tr_named_10 (arg0, tmp112, (&tmp113)) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp113 != (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: ats_ptrget_mac(ats_bool_type, arg3) = ats_true_bool ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (tmp113 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: break ; } while (0) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_extype (tmp111, tmp114) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp94)->tag != 11) { goto __ats_lab_48_0 ; } __ats_lab_45_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_9, tmp94, atslab_0) ; tmp117 = ats_caselptrlab_mac(anairiats_sum_9, tmp94, atslab_3) ; tmp118 = ats_caselptrlab_mac(anairiats_sum_9, tmp94, atslab_4) ; tmp119 = ats_caselptrlab_mac(anairiats_sum_9, tmp94, atslab_5) ; tmp120 = atspre_gt_int_int (arg1, 0) ; if (tmp120) { tmp121 = s2explst_npf_tr_15 (arg0, tmp117, tmp118) ; tmp122 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, 0, tmp119) ; tmp123 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_varetize (tmp122) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp116, tmp121, tmp123) ; } else { do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (tmp116 != (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (tmp116 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: tmp124 = ats_caselptrlab_mac(anairiats_sum_10, tmp116, atslab_0) ; tmp125 = atspre_eq_int_int (tmp124, 0) ; if (tmp125) { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo ; } else { tmp126 = atspre_gt_int_int (tmp124, 0) ; if (tmp126) { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ptr ; } else { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo_ref ; } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp94)->tag != 14) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp127 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp127 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp94)->tag != 15) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_8, tmp94, atslab_2) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, arg1, tmp128) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp94)->tag != 20) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp129 = ats_caselptrlab_mac(anairiats_sum_7, tmp94, atslab_0) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_7, tmp94, atslab_1) ; tmp131 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, 0, tmp130) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_refarg (tmp129, tmp131) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp94)->tag != 24) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_7, tmp94, atslab_1) ; arg0 = arg0 ; arg1 = 0 ; arg2 = tmp132 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp94)->tag != 26) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_0) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_1) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, 0, tmp133) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyarr (tmp135, tmp134) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp94)->tag != 29) { goto __ats_lab_61_0 ; } __ats_lab_53_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_11, tmp94, atslab_0) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_11, tmp94, atslab_1) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_11, tmp94, atslab_2) ; /* ats_ptr_type tmp139 ; */ tmp139 = (ats_sum_ptr_type)0 ; tmp140 = labs2explst_npf_tr_named_16 (arg0, tmp137, tmp138, (&tmp139)) ; do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp136)->tag != 0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp141 = atspre_gt_int_int (arg1, 0) ; if (tmp141) { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp (1, tmp140) ; } else { tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; } /* end of [if] */ break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp136)->tag != 3) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_2, tmp136, atslab_0) ; ats_ptrget_mac(ats_bool_type, arg3) = ats_true_bool ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrec (-1, tmp142, tmp140) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp139 != (ats_sum_ptr_type)0) { goto __ats_lab_58_0 ; } __ats_lab_57_1: ats_ptrget_mac(ats_bool_type, arg3) = ats_true_bool ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: // if (tmp139 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_58_1: break ; } while (0) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (tmp140 == (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } tmp144 = ats_caselptrlab_mac(anairiats_sum_6, tmp140, atslab_2) ; if (tmp144 != (ats_sum_ptr_type)0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp145 = ats_caselptrlab_mac(anairiats_sum_6, tmp140, atslab_1) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrecsin (tmp145) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tyrectemp (0, tmp140) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp94)->tag != 30) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_8, tmp94, atslab_2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp146 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp94)->tag != 33) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp147 = ats_caselptrlab_mac(anairiats_sum_2, tmp94, atslab_0) ; tmp82 = s2Var_tr_named_6 (arg0, arg1, tmp147, arg3) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp94)->tag != 32) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_2, tmp94, atslab_0) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_s2var (tmp148) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp94)->tag != 34) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp82 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp94)->tag != 35) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_4, tmp94, atslab_0) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, arg1, tmp149) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp82 = err_20 (arg0, tmp84, tmp83) ; break ; } while (0) ; return (tmp82) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 15484(line=480, offs=10) -- 15649(line=485, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_bool_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr: /* ats_bool_type tmp151 ; */ tmp151 = ats_false_bool ; tmp150 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__s2exp_tr_named (arg0, arg1, arg2, (&tmp151)) ; return (tmp150) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 15785(line=490, offs=43) -- 15810(line=490, offs=68) */ ATSstaticdec() ats_ptr_type __ats_fun_23 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp153) ; __ats_lab___ats_fun_23: tmp153 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_hipat_typ) ; return (tmp153) ; } /* end of [__ats_fun_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 15696(line=489, offs=4) -- 15811(line=490, offs=69) */ ATSstaticdec() ats_ptr_type hipatlst_get_type_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_hipatlst_get_type_22: tmp152 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &__ats_fun_23) ; return (tmp152) ; } /* end of [hipatlst_get_type_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 15846(line=493, offs=4) -- 15909(line=493, offs=67) */ ATSstaticdec() ats_bool_type p3at_is_proof_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_p3at_is_proof_24: tmp155 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_p3at_typ) ; tmp154 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp155) ; return (tmp154) ; } /* end of [p3at_is_proof_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 16002(line=498, offs=7) -- 16337(line=507, offs=33) */ ATSstaticdec() ats_ptr_type aux_26 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_bool_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_bool_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_aux_26: do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp159 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp160 = atspre_gt_int_int (arg0, 0) ; if (tmp160) { tmp161 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp161 ; arg1 = tmp159 ; goto __ats_lab_aux_26 ; // tail call } else { tmp162 = p3at_is_proof_24 (tmp158) ; if (tmp162) { arg0 = 0 ; arg1 = tmp159 ; goto __ats_lab_aux_26 ; // tail call } else { tmp163 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp158) ; tmp164 = aux_26 (0, tmp159) ; tmp157 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp157, atslab_0, tmp163) ; ats_selptrset_mac(anairiats_sum_5, tmp157, atslab_1, tmp164) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: tmp157 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp157) ; } /* end of [aux_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 15914(line=495, offs=4) -- 16357(line=509, offs=2) */ ATSstaticdec() ats_ptr_type p3atlst_arg_tr_25 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_p3atlst_arg_tr_25: tmp156 = aux_26 (arg0, arg1) ; return (tmp156) ; } /* end of [p3atlst_arg_tr_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 16488(line=514, offs=7) -- 16923(line=524, offs=44) */ ATSstaticdec() ats_ptr_type aux_28 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_bool_type, tmp170) ; ATSlocal (ats_int_type, tmp171) ; ATSlocal (ats_bool_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_aux_28: do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp167 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp168 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_2) ; tmp170 = atspre_gt_int_int (arg0, 0) ; if (tmp170) { tmp171 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp171 ; arg1 = tmp169 ; goto __ats_lab_aux_28 ; // tail call } else { tmp172 = p3at_is_proof_24 (tmp168) ; if (tmp172) { arg0 = 0 ; arg1 = tmp169 ; goto __ats_lab_aux_28 ; // tail call } else { tmp173 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp168) ; tmp174 = aux_28 (0, tmp169) ; tmp166 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp166)->tag = 0 ; ats_selptrset_mac(anairiats_sum_8, tmp166, atslab_0, tmp167) ; ats_selptrset_mac(anairiats_sum_8, tmp166, atslab_1, tmp173) ; ats_selptrset_mac(anairiats_sum_8, tmp166, atslab_2, tmp174) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp166 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: tmp166 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; break ; } while (0) ; return (tmp166) ; } /* end of [aux_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 16389(line=511, offs=4) -- 16943(line=526, offs=2) */ ATSstaticdec() ats_ptr_type labp3atlst_arg_tr_27 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp165) ; __ats_lab_labp3atlst_arg_tr_27: tmp165 = aux_28 (arg0, arg1) ; return (tmp165) ; } /* end of [labp3atlst_arg_tr_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 17014(line=531, offs=9) -- 19798(line=610, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_bool_type, tmp189) ; ATSlocal (ats_char_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_int_type, tmp196) ; ATSlocal (ats_bool_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_int_type, tmp207) ; ATSlocal (ats_int_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_int_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr: tmp176 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_p3at_loc) ; tmp178 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_p3at_typ) ; tmp177 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp176, 0, tmp178) ; tmp179 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_p3at_node) ; do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp179)->tag != 0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_1) ; tmp182 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp180) ; tmp183 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp176, 0, tmp181) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_ann (tmp176, tmp177, tmp182, tmp183) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp179)->tag != 1) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_any (tmp176, tmp177) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp179)->tag != 2) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp184 = ats_caselptrlab_mac(anairiats_sum_14, tmp179, atslab_0) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_14, tmp179, atslab_1) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_14, tmp179, atslab_2) ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp185) ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp186) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_as (tmp176, tmp177, tmp184, tmp185, tmp188) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: if (((ats_sum_ptr_type)tmp179)->tag != 3) { goto __ats_lab_76_0 ; } __ats_lab_75_1: tmp189 = ats_caselptrlab_mac(anairiats_sum_15, tmp179, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_bool (tmp176, tmp177, tmp189) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp179)->tag != 4) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp190 = ats_caselptrlab_mac(anairiats_sum_16, tmp179, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_char (tmp176, tmp177, tmp190) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp179)->tag != 5) { goto __ats_lab_82_0 ; } __ats_lab_77_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_17, tmp179, atslab_0) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_17, tmp179, atslab_1) ; tmp193 = ats_caselptrlab_mac(anairiats_sum_17, tmp179, atslab_2) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_17, tmp179, atslab_3) ; tmp195 = p3atlst_arg_tr_25 (tmp193, tmp194) ; do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (tmp194 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp196 = tmp191 ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (tmp194 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp196 = 1 ; break ; } while (0) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: __ats_lab_80_1: tmp197 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipatlst_is_unused (tmp195) ; if (!tmp197) { goto __ats_lab_81_1 ; } tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con_any (tmp176, tmp177, tmp196, tmp192) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp198 = hipatlst_get_type_22 (tmp195) ; tmp199 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp (tmp192, tmp198) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_con (tmp176, tmp177, tmp196, tmp192, tmp195, tmp199) ; break ; } while (0) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp179)->tag != 6) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_empty (tmp176, tmp177) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp179)->tag != 7) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp200 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_1) ; arg0 = tmp200 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr ; // tail call break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp179)->tag != 9) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp201 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_0) ; tmp202 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_1) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_int (tmp176, tmp177, tmp201, tmp202) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp179)->tag != 10) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp203 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_0) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_4, tmp179, atslab_1) ; tmp205 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp176, 0, tmp203) ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr (tmp204) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_lst (tmp176, tmp177, tmp205, tmp206) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp179)->tag != 11) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp207 = ats_caselptrlab_mac(anairiats_sum_18, tmp179, atslab_0) ; tmp208 = ats_caselptrlab_mac(anairiats_sum_18, tmp179, atslab_1) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_18, tmp179, atslab_2) ; tmp211 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_p3at_typ) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp176, 1, tmp211) ; tmp212 = labp3atlst_arg_tr_27 (tmp208, tmp209) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_rec (tmp176, tmp177, tmp207, tmp212, tmp210) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp179)->tag != 12) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_2, tmp179, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_string (tmp176, tmp177, tmp213) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp179)->tag != 13) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_7, tmp179, atslab_0) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_7, tmp179, atslab_1) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hipat_var (tmp176, tmp177, tmp214, tmp215) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: /* tmp216 = */ prerr_interror_1 () ; /* tmp217 = */ atspre_prerr_string (ATSstrcst(": p3at_tr: p3t0 = ")) ; /* tmp218 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at (arg0) ; /* tmp219 = */ atspre_prerr_newline () ; /* tmp175 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 19841(line=613, offs=12) -- 19883(line=613, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr: tmp220 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr) ; return (tmp220) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 19998(line=618, offs=43) -- 20023(line=618, offs=68) */ ATSstaticdec() ats_ptr_type __ats_fun_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp222) ; __ats_lab___ats_fun_32: tmp222 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_hiexp_typ) ; return (tmp222) ; } /* end of [__ats_fun_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 19909(line=617, offs=4) -- 20024(line=618, offs=69) */ ATSstaticdec() ats_ptr_type hiexplst_get_type_31 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_hiexplst_get_type_31: tmp221 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &__ats_fun_32) ; return (tmp221) ; } /* end of [hiexplst_get_type_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 20059(line=621, offs=4) -- 20125(line=621, offs=70) */ ATSstaticdec() ats_bool_type d3exp_is_proof_33 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_d3exp_is_proof_33: tmp224 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_typ) ; tmp223 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp224) ; return (tmp223) ; } /* end of [d3exp_is_proof_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 20394(line=637, offs=7) -- 20737(line=646, offs=60) */ ATSstaticdec() ats_ptr_type aux0_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; __ats_lab_aux0_35: do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp228 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp227) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp230, atslab_0, tmp229) ; ats_selptrset_mac(anairiats_sum_5, tmp230, atslab_1, arg0) ; arg0 = tmp230 ; arg1 = tmp228 ; goto __ats_lab_aux0_35 ; // tail call break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: tmp226 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg0) ; break ; } while (0) ; return (tmp226) ; } /* end of [aux0_35] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 21136(line=662, offs=15) -- 21306(line=664, offs=74) */ ATSstaticdec() ats_ptr_type loop_37 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_loop_37: tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_node) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp237)->tag != 46) { goto __ats_lab_95_0 ; } tmp238 = ats_caselptrlab_mac(anairiats_sum_2, tmp237, atslab_0) ; if (tmp238 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_5, tmp238, atslab_0) ; arg0 = tmp239 ; goto __ats_lab_loop_37 ; // tail call break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp236 = arg0 ; break ; } while (0) ; return (tmp236) ; } /* end of [loop_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 20766(line=649, offs=7) -- 22132(line=687, offs=10) */ ATSstaticdec() ats_ptr_type aux1_36 (ats_bool_type env0, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; // ATSlocal_void (tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_aux1_36: do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp232 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_0) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_5, arg2, atslab_1) ; tmp234 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (arg1) ; tmp235 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp235, atslab_0, tmp234) ; ats_selptrset_mac(anairiats_sum_5, tmp235, atslab_1, arg0) ; arg0 = tmp235 ; arg1 = tmp232 ; arg2 = tmp233 ; goto __ats_lab_aux1_36 ; // tail call break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp240 = loop_37 (arg1) ; if (env0) { tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp240), atslab_d3exp_node) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp241)->tag != 40) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_18, tmp241, atslab_2) ; tmp231 = aux0_35 (arg0, tmp242) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (arg0) ; tmp245 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp240), atslab_d3exp_loc) ; /* tmp244 = */ prerr_loc_error4_0 (tmp245) ; /* tmp246 = */ atsopt_debug_prerrf (ATSstrcst(": [%s]: d3explst_funarg_tr"), ATSstrcst("ats_trans4.dats")) ; /* tmp247 = */ atspre_prerr_string (ATSstrcst(": the expression is expected to be a record of the form @(...) but it is not.")) ; /* tmp248 = */ atspre_prerr_newline () ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp240) ; tmp250 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp250, atslab_0, tmp249) ; ats_selptrset_mac(anairiats_sum_5, tmp250, atslab_1, arg0) ; tmp231 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp250) ; } /* end of [if] */ break ; } while (0) ; return (tmp231) ; } /* end of [aux1_36] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_bool_type closure_env_0 ; } aux1_36_closure_type ; ats_ptr_type aux1_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { return aux1_36 (((aux1_36_closure_type*)cloptr)->closure_env_0, arg0, arg1, arg2) ; } /* end of function */ ATSinline() ats_void_type aux1_36_closure_init (aux1_36_closure_type *p_clo, ats_bool_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux1_36_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux1_36_closure_make (ats_bool_type env0) { aux1_36_closure_type *p_clo = ATS_MALLOC(sizeof(aux1_36_closure_type)) ; aux1_36_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 22185(line=690, offs=7) -- 22568(line=701, offs=23) */ ATSstaticdec() ats_ptr_type aux2_38 (ats_bool_type env0, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_bool_type, tmp254) ; // ATSlocal_void (tmp255) ; ATSlocal (ats_int_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_aux2_38: do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp253 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp254 = atspre_gt_int_int (arg0, 0) ; if (tmp254) { /* tmp255 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp252) ; tmp256 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp256 ; arg1 = tmp253 ; goto __ats_lab_aux2_38 ; // tail call } else { tmp257 = (ats_sum_ptr_type)0 ; tmp251 = aux1_36 (env0, tmp257, tmp252, tmp253) ; } /* end of [if] */ break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_99_1: tmp251 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp251) ; } /* end of [aux2_38] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_bool_type closure_env_0 ; } aux2_38_closure_type ; ats_ptr_type aux2_38_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { return aux2_38 (((aux2_38_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux2_38_closure_init (aux2_38_closure_type *p_clo, ats_bool_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux2_38_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux2_38_closure_make (ats_bool_type env0) { aux2_38_closure_type *p_clo = ATS_MALLOC(sizeof(aux2_38_closure_type)) ; aux2_38_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 20357(line=635, offs=3) -- 22632(line=706, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__d3explst_funarg_tr (ats_bool_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__d3explst_funarg_tr: tmp225 = aux2_38 (arg0, arg1, arg2) ; return (tmp225) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__d3explst_funarg_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 22759(line=713, offs=7) -- 23297(line=730, offs=6) */ ATSstaticdec() ats_ptr_type aux_40 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_bool_type, tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_int_type, tmp264) ; ATSlocal (ats_bool_type, tmp265) ; // ATSlocal_void (tmp266) ; ATSlocal (ats_int_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_int_type, tmp270) ; __ats_lab_aux_40: do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_100_1: tmp260 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp261 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; do { /* branch: __ats_lab_101 */ __ats_lab_101_0: __ats_lab_101_1: tmp262 = atspre_gt_int_int (arg0, 0) ; if (!tmp262) { goto __ats_lab_102_1 ; } /* tmp263 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp260) ; tmp264 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp264 ; arg1 = tmp261 ; goto __ats_lab_aux_40 ; // tail call break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: __ats_lab_102_1: tmp265 = d3exp_is_proof_33 (tmp260) ; if (tmp265) { /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp260) ; tmp267 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp267 ; arg1 = tmp261 ; goto __ats_lab_aux_40 ; // tail call } else { tmp268 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp260) ; tmp270 = atspre_sub_int_int (arg0, 1) ; tmp269 = aux_40 (tmp270, tmp261) ; tmp259 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp259, atslab_0, tmp268) ; ats_selptrset_mac(anairiats_sum_5, tmp259, atslab_1, tmp269) ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: tmp259 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp259) ; } /* end of [aux_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 22689(line=710, offs=4) -- 23338(line=733, offs=4) */ ATSstaticdec() ats_ptr_type d3explst_arg_tr_39 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; __ats_lab_d3explst_arg_tr_39: tmp258 = aux_40 (arg0, arg1) ; return (tmp258) ; } /* end of [d3explst_arg_tr_39] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 23455(line=738, offs=7) -- 24053(line=755, offs=6) */ ATSstaticdec() ats_ptr_type aux_42 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_bool_type, tmp276) ; // ATSlocal_void (tmp277) ; ATSlocal (ats_int_type, tmp278) ; ATSlocal (ats_bool_type, tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_int_type, tmp284) ; __ats_lab_aux_42: do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp273 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp274 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_2) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: __ats_lab_105_1: tmp276 = atspre_gt_int_int (arg0, 0) ; if (!tmp276) { goto __ats_lab_106_1 ; } /* tmp277 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp274) ; tmp278 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp278 ; arg1 = tmp275 ; goto __ats_lab_aux_42 ; // tail call break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: tmp279 = d3exp_is_proof_33 (tmp274) ; if (tmp279) { /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp274) ; tmp281 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp281 ; arg1 = tmp275 ; goto __ats_lab_aux_42 ; // tail call } else { tmp282 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp274) ; tmp284 = atspre_sub_int_int (arg0, 1) ; tmp283 = aux_42 (tmp284, tmp275) ; tmp272 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp272, atslab_0, tmp273) ; ats_selptrset_mac(anairiats_sum_6, tmp272, atslab_1, tmp282) ; ats_selptrset_mac(anairiats_sum_6, tmp272, atslab_2, tmp283) ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: tmp272 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp272) ; } /* end of [aux_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 23371(line=735, offs=4) -- 24095(line=758, offs=4) */ ATSstaticdec() ats_ptr_type labd3explst_arg_tr_41 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; __ats_lab_labd3explst_arg_tr_41: tmp271 = aux_42 (arg0, arg1) ; return (tmp271) ; } /* end of [labd3explst_arg_tr_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 24152(line=762, offs=4) -- 24448(line=770, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_cst_tr_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_bool_type, tmp287) ; ATSlocal (ats_bool_type, tmp288) ; __ats_lab_d3exp_cst_tr_43: tmp286 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg2) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: __ats_lab_108_1: tmp287 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp286, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE) ; if (!tmp287) { goto __ats_lab_109_1 ; } tmp285 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool (arg0, arg1, ats_true_bool) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: tmp288 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp286, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE) ; if (!tmp288) { goto __ats_lab_110_1 ; } tmp285 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool (arg0, arg1, ats_false_bool) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: __ats_lab_110_1: tmp285 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cst (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp285) ; } /* end of [d3exp_cst_tr_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 24499(line=774, offs=4) -- 24647(line=778, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_seq_tr_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; __ats_lab_d3exp_seq_tr_44: tmp290 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (arg2) ; tmp289 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_seq_simplify (arg0, arg1, tmp290) ; return (tmp289) ; } /* end of [d3exp_seq_tr_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 24698(line=782, offs=4) -- 25481(line=807, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_tmpcst_tr_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_bool_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; __ats_lab_d3exp_tmpcst_tr_45: tmp292 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg2) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: __ats_lab_111_1: tmp293 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp292, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SIZEOF) ; if (!tmp293) { goto __ats_lab_114_1 ; } do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } tmp294 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; if (tmp294 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } tmp295 = ats_caselptrlab_mac(anairiats_sum_5, tmp294, atslab_1) ; if (tmp295 != (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } tmp296 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_1) ; if (tmp296 != (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp297 = ats_caselptrlab_mac(anairiats_sum_5, tmp294, atslab_0) ; tmp298 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (arg0, 0, tmp297) ; tmp291 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sizeof (arg0, arg1, tmp298) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: /* tmp299 = */ prerr_interror_1 () ; /* tmp300 = */ atspre_prerr_string (ATSstrcst(": d3exp_tmpcst_tr: sizeof")) ; /* tmp301 = */ atspre_prerr_newline () ; /* tmp291 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_114 */ __ats_lab_114_0: __ats_lab_114_1: tmp302 = s2explstlst_tr_11 (arg0, arg3) ; tmp291 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpcst (arg0, arg1, arg2, tmp302) ; break ; } while (0) ; return (tmp291) ; } /* end of [d3exp_tmpcst_tr_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 25517(line=809, offs=4) -- 25703(line=817, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_tmpvar_tr_46 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; __ats_lab_d3exp_tmpvar_tr_46: tmp304 = s2explstlst_tr_11 (arg0, arg3) ; tmp303 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_tmpvar (arg0, arg1, arg2, tmp304) ; return (tmp303) ; } /* end of [d3exp_tmpvar_tr_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 25757(line=821, offs=4) -- 26294(line=839, offs=4) */ ATSstaticdec() ats_ptr_type d3lab1_tr_47 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; __ats_lab_d3lab1_tr_47: tmp306 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d3lab1_loc) ; tmp307 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d3lab1_node) ; do { /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)tmp307)->tag != 0) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_4, tmp307, atslab_0) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_4, tmp307, atslab_1) ; tmp310 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp306, 1, tmp309) ; tmp305 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_lab (tmp306, tmp308, tmp310) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (((ats_sum_ptr_type)tmp307)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: tmp311 = ats_caselptrlab_mac(anairiats_sum_4, tmp307, atslab_0) ; tmp312 = ats_caselptrlab_mac(anairiats_sum_4, tmp307, atslab_1) ; tmp313 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp311, &ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr) ; tmp314 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp306, 0, tmp312) ; tmp305 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hilab_ind (tmp306, tmp313, tmp314) ; break ; } while (0) ; return (tmp305) ; } /* end of [d3lab1_tr_47] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 26321(line=841, offs=4) -- 26401(line=842, offs=68) */ ATSstaticdec() ats_ptr_type d3lab1lst_tr_48 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp315) ; __ats_lab_d3lab1lst_tr_48: tmp315 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &d3lab1_tr_47) ; return (tmp315) ; } /* end of [d3lab1lst_tr_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 26452(line=847, offs=4) -- 26705(line=855, offs=4) */ ATSstaticdec() ats_ptr_type m3atch_tr_49 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; __ats_lab_m3atch_tr_49: tmp318 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m3atch_exp) ; tmp317 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp318) ; tmp320 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m3atch_pat) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (tmp320 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp321 = ats_caselptrlab_mac(anairiats_sum_3, tmp320, atslab_0) ; tmp322 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp321) ; tmp319 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp319, atslab_0, tmp322) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (tmp320 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp319 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp323 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg0), atslab_m3atch_loc) ; tmp316 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__himat_make (tmp323, tmp317, tmp319) ; return (tmp316) ; } /* end of [m3atch_tr_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 26732(line=857, offs=4) -- 26816(line=859, offs=39) */ ATSstaticdec() ats_ptr_type m3atchlst_tr_50 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp324) ; __ats_lab_m3atchlst_tr_50: tmp324 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &m3atch_tr_49) ; return (tmp324) ; } /* end of [m3atchlst_tr_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 26867(line=864, offs=4) -- 27295(line=882, offs=4) */ ATSstaticdec() ats_ptr_type c3lau_tr_51 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; __ats_lab_c3lau_tr_51: tmp326 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_c3lau_loc) ; tmp328 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_c3lau_pat) ; tmp327 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3atlst_tr (tmp328) ; tmp330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_c3lau_gua) ; tmp329 = m3atchlst_tr_50 (tmp330) ; tmp332 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_c3lau_exp) ; tmp331 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp332) ; tmp325 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiclau_make (tmp326, tmp327, tmp329, tmp331) ; return (tmp325) ; } /* end of [c3lau_tr_51] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 27378(line=887, offs=7) -- 27914(line=903, offs=39) */ ATSstaticdec() ats_void_type aux_53 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_bool_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; __ats_lab_aux_53: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_122_0 ; } __ats_lab_119_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; do { /* branch: __ats_lab_120 */ __ats_lab_120_0: __ats_lab_120_1: tmp338 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp335), atslab_c3lau_neg) ; tmp337 = atspre_gt_int_int (tmp338, 0) ; if (!tmp337) { goto __ats_lab_121_1 ; } arg0 = tmp336 ; arg1 = arg1 ; goto __ats_lab_aux_53 ; // tail call break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp339 = c3lau_tr_51 (tmp335) ; tmp340 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp340, atslab_0, tmp339) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp340 ; // if (ats_ptrget_mac(ats_ptr_type, arg1) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp341 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, arg1), atslab_1) ; arg0 = tmp336 ; arg1 = tmp341 ; goto __ats_lab_aux_53 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_122_1: tmp342 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp342 ; break ; } while (0) ; return /* (tmp334) */ ; } /* end of [aux_53] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 27321(line=884, offs=4) -- 28018(line=911, offs=4) */ ATSstaticdec() ats_ptr_type c3laulst_tr_52 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp343) ; // ATSlocal_void (tmp344) ; __ats_lab_c3laulst_tr_52: /* ats_ptr_type tmp343 ; */ /* tmp344 = */ aux_53 (arg0, (&tmp343)) ; tmp333 = tmp343 ; return (tmp333) ; } /* end of [c3laulst_tr_52] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 28663(line=941, offs=10) -- 43287(line=1357, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_int_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_bool_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_bool_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; // ATSlocal_void (tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_bool_type, tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_bool_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_int_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_char_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_int_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; // ATSlocal_void (tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_int_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_bool_type, tmp429) ; // ATSlocal_void (tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_int_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_int_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_bool_type, tmp469) ; // ATSlocal_void (tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; // ATSlocal_void (tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_int_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_int_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_int_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; // ATSlocal_void (tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_int_type, tmp521) ; ATSlocal (ats_int_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_int_type, tmp527) ; ATSlocal (ats_int_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; // ATSlocal_void (tmp532) ; // ATSlocal_void (tmp533) ; // ATSlocal_void (tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; // ATSlocal_void (tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_int_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; // ATSlocal_void (tmp576) ; ATSlocal (ats_bool_type, tmp577) ; // ATSlocal_void (tmp578) ; // ATSlocal_void (tmp579) ; // ATSlocal_void (tmp580) ; // ATSlocal_void (tmp581) ; // ATSlocal_void (tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; // ATSlocal_void (tmp584) ; // ATSlocal_void (tmp585) ; // ATSlocal_void (tmp586) ; // ATSlocal_void (tmp587) ; // ATSlocal_void (tmp588) ; // ATSlocal_void (tmp589) ; // ATSlocal_void (tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr: tmp346 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_loc) ; tmp347 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_typ) ; tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_node) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp348)->tag != 0) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; arg0 = tmp349 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr ; // tail call break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)tmp348)->tag != 1) { goto __ats_lab_129_0 ; } __ats_lab_124_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_1) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_2) ; tmp353 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp355 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, tmp350), atslab_d3exp_typ) ; tmp354 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp355) ; tmp356 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp350) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun_is_vararg (tmp354) ; tmp358 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__d3explst_funarg_tr (tmp357, tmp351, tmp352) ; tmp359 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp356), atslab_hiexp_node) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (((ats_sum_ptr_type)tmp359)->tag != 10) { goto __ats_lab_128_0 ; } __ats_lab_125_1: tmp360 = ats_caselptrlab_mac(anairiats_sum_2, tmp359, atslab_0) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_castfn (tmp360) ; if (!tmp361) { goto __ats_lab_128_1 ; } do { /* branch: __ats_lab_126 */ __ats_lab_126_0: if (tmp358 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } tmp363 = ats_caselptrlab_mac(anairiats_sum_5, tmp358, atslab_1) ; if (tmp363 != (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_5, tmp358, atslab_0) ; tmp362 = tmp364 ; break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: __ats_lab_127_1: /* tmp365 = */ prerr_loc_interror_2 (tmp346) ; /* tmp366 = */ atspre_prerr_string (ATSstrcst(": d3exp_tr: a casting function must be applied to exactly one argument.")) ; /* tmp367 = */ atspre_prerr_newline () ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_castfn (tmp346, tmp353, tmp360, tmp362) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: __ats_lab_128_1: tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_app (tmp346, tmp353, tmp354, tmp356, tmp358) ; break ; } while (0) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: if (((ats_sum_ptr_type)tmp348)->tag != 2) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; arg0 = tmp368 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr ; // tail call break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp348)->tag != 3) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp369 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_0) ; tmp370 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_1) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp373 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp369) ; tmp374 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr (tmp370) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (tmp371) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrinit (tmp346, tmp372, tmp373, tmp374, tmp375) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp348)->tag != 4) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp378 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp379 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp376) ; tmp380 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (tmp377) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_arrpsz (tmp346, tmp378, tmp379, tmp380) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp348)->tag != 5) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp381 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_0) ; tmp382 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_1) ; tmp383 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp384 = d3exp_is_proof_33 (tmp383) ; if (tmp384) { tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; } else { tmp385 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp381) ; tmp386 = d3lab1lst_tr_48 (tmp382) ; tmp387 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp383) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_ptr (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, tmp385, tmp386, tmp387) ; } /* end of [if] */ break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: if (((ats_sum_ptr_type)tmp348)->tag != 6) { goto __ats_lab_134_0 ; } __ats_lab_133_1: tmp388 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_0) ; tmp389 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_1) ; tmp390 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp391 = d3exp_is_proof_33 (tmp390) ; if (tmp391) { tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; } else { /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp388) ; tmp393 = d3lab1lst_tr_48 (tmp389) ; tmp394 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp390) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_assgn_var (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, tmp388, tmp393, tmp394) ; } /* end of [if] */ break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: if (((ats_sum_ptr_type)tmp348)->tag != 7) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp395 = ats_caselptrlab_mac(anairiats_sum_15, tmp348, atslab_0) ; tmp396 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_bool (tmp346, tmp396, tmp395) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp348)->tag != 8) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp397 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_0) ; tmp398 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_1) ; tmp399 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_2) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp401 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (tmp398) ; tmp402 = c3laulst_tr_52 (tmp399) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_caseof_if (tmp346, tmp400, tmp397, tmp401, tmp402) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)tmp348)->tag != 9) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_16, tmp348, atslab_0) ; tmp404 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_char (tmp346, tmp404, tmp403) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp348)->tag != 10) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_0) ; tmp406 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_1) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_11, tmp348, atslab_2) ; tmp408 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp409 = d3explst_arg_tr_39 (tmp406, tmp407) ; tmp410 = hiexplst_get_type_31 (tmp409) ; tmp411 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_tysumtemp (tmp405, tmp410) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_con (tmp346, tmp408, tmp411, tmp405, tmp409) ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)tmp348)->tag != 11) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp412 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; /* tmp413 = */ atsopt_the_dyncstset_add_if (tmp412) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = d3exp_cst_tr_43 (tmp346, tmp414, tmp412) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)tmp348)->tag != 12) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp416 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_cstsp (tmp346, tmp416, tmp415) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: if (((ats_sum_ptr_type)tmp348)->tag != 13) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp417 = ats_caselptrlab_mac(anairiats_sum_7, tmp348, atslab_1) ; arg0 = tmp417 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr ; // tail call break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)tmp348)->tag != 14) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp418 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_dynload (tmp346, tmp419, tmp418) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)tmp348)->tag != 15) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp420 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; arg0 = tmp420 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr ; // tail call break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp348)->tag != 16) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp421 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, tmp421) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp348)->tag != 17) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp422 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp423 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_extval (tmp346, tmp423, tmp422) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp348)->tag != 18) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp424 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_0) ; tmp425 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_1) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_2) ; tmp427 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp428 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp426) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value (tmp428) ; if (tmp429) { /* empty */ } else { /* tmp431 = */ prerr_loc_error4_0 (tmp346) ; /* tmp432 = */ atspre_prerr_string (ATSstrcst(": a non-value fixed-point dynamic expression is not supported.")) ; /* tmp433 = */ atspre_prerr_newline () ; /* tmp430 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_fix (tmp346, tmp427, tmp424, tmp425, tmp428) ; break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp348)->tag != 19) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp434 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp435 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_float (tmp346, tmp435, tmp434) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: if (((ats_sum_ptr_type)tmp348)->tag != 20) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp436 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp437 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_floatsp (tmp346, tmp437, tmp436) ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: if (((ats_sum_ptr_type)tmp348)->tag != 21) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp438 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, tmp438) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)tmp348)->tag != 22) { goto __ats_lab_150_0 ; } __ats_lab_149_1: tmp439 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp439) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_freeat (tmp346, tmp440, tmp441) ; break ; /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)tmp348)->tag != 23) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp442 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_0) ; tmp443 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_1) ; tmp444 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp445 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp446 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp442) ; tmp447 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp443) ; tmp448 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp444) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_if (tmp346, tmp445, tmp446, tmp447, tmp448) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp348)->tag != 24) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp449 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp450 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp451 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_int (tmp346, tmp451, tmp449, tmp450) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: if (((ats_sum_ptr_type)tmp348)->tag != 25) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp452 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp453 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp454 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_intsp (tmp346, tmp454, tmp452, tmp453) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: if (((ats_sum_ptr_type)tmp348)->tag != 26) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp455 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_1) ; tmp456 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_2) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_3) ; tmp458 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp459 = p3atlst_arg_tr_25 (tmp455, tmp456) ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp457) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lam (tmp346, tmp458, tmp459, tmp460) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp348)->tag != 27) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_1) ; tmp462 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_2) ; tmp463 = ats_caselptrlab_mac(anairiats_sum_24, tmp348, atslab_3) ; tmp464 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp465 = p3atlst_arg_tr_25 (tmp461, tmp462) ; tmp466 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp463) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_laminit (tmp346, tmp464, tmp465, tmp466) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp348)->tag != 29) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp467 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp468 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp467) ; tmp469 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_is_value (tmp468) ; if (tmp469) { /* empty */ } else { /* tmp471 = */ prerr_loc_error4_0 (tmp346) ; /* tmp472 = */ atspre_prerr_string (ATSstrcst(": a non-value body for static lambda-abstraction is not supported.")) ; /* tmp473 = */ atspre_prerr_newline () ; /* tmp470 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp345 = tmp468 ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp348)->tag != 28) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp474 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; arg0 = tmp474 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr ; // tail call break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp348)->tag != 30) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp475 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp476 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp477 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp475) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_delay (tmp346, tmp476, tmp477) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp348)->tag != 31) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp478 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp479 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp480 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp481 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp478) ; tmp482 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp479) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_ldelay (tmp346, tmp480, tmp481, tmp482) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp348)->tag != 32) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_7, tmp348, atslab_0) ; tmp484 = ats_caselptrlab_mac(anairiats_sum_7, tmp348, atslab_1) ; tmp485 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp486 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp484) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lazy_force (tmp346, tmp485, tmp483, tmp486) ; break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: if (((ats_sum_ptr_type)tmp348)->tag != 33) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp487 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp488 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp489 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp490 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp487) ; tmp491 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp488) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify (tmp346, tmp489, tmp490, tmp491) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp348)->tag != 34) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp492 = ats_caselptrlab_mac(anairiats_sum_25, tmp348, atslab_0) ; tmp493 = ats_caselptrlab_mac(anairiats_sum_25, tmp348, atslab_1) ; tmp494 = ats_caselptrlab_mac(anairiats_sum_25, tmp348, atslab_2) ; tmp495 = ats_caselptrlab_mac(anairiats_sum_25, tmp348, atslab_3) ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr (tmp492) ; tmp497 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp493) ; tmp498 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr (tmp494) ; tmp499 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp495) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loop (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, tmp496, tmp497, tmp498, tmp499) ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: if (((ats_sum_ptr_type)tmp348)->tag != 35) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp500 = ats_caselptrlab_mac(anairiats_sum_26, tmp348, atslab_0) ; tmp501 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_loopexn (tmp346, tmp501, tmp500) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp348)->tag != 36) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp502 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_0) ; tmp503 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_1) ; tmp504 = ats_caselptrlab_mac(anairiats_sum_14, tmp348, atslab_2) ; tmp505 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp506 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp503) ; tmp507 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (tmp504) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_lst (tmp346, tmp505, tmp502, tmp506, tmp507) ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: if (((ats_sum_ptr_type)tmp348)->tag != 37) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp508 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp509 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp511 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp508) ; tmp512 = d3lab1lst_tr_48 (tmp509) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_ptr (tmp346, tmp510, tmp511, tmp512) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: if (((ats_sum_ptr_type)tmp348)->tag != 38) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp513 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp514 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp515 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; /* tmp516 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp513) ; tmp517 = d3lab1lst_tr_48 (tmp514) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_ptrof_var (tmp346, tmp515, tmp513, tmp517) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)tmp348)->tag != 39) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp518 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp519 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp520 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp518) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_raise (tmp346, tmp519, tmp520) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp348)->tag != 40) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp521 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_0) ; tmp522 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_1) ; tmp523 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_2) ; tmp524 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp525 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp526 = labd3explst_arg_tr_41 (tmp522, tmp523) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec (tmp346, tmp524, tmp521, tmp525, tmp526) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp348)->tag != 41) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp527 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_0) ; tmp528 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_1) ; tmp529 = ats_caselptrlab_mac(anairiats_sum_18, tmp348, atslab_2) ; tmp530 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp531 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp529) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_refarg (tmp346, tmp530, tmp527, tmp528, tmp531) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: if (((ats_sum_ptr_type)tmp348)->tag != 42) { goto __ats_lab_170_0 ; } __ats_lab_169_1: /* tmp532 = */ prerr_loc_interror_2 (tmp346) ; /* tmp533 = */ atspre_prerr_string (ATSstrcst(": the static caseof-expression should have already been erased.")) ; /* tmp534 = */ atspre_prerr_newline () ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp348)->tag != 43) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp535 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp536 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp537 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp538 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp535) ; tmp539 = d3lab1lst_tr_48 (tmp536) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel (tmp346, tmp537, tmp538, tmp539) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)tmp348)->tag != 44) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp540 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp541 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp542 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp543 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp540) ; tmp544 = d3lab1lst_tr_48 (tmp541) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_ptr (tmp346, tmp542, tmp543, tmp544) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)tmp348)->tag != 45) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp545 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp546 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp547 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; /* tmp548 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp545) ; tmp549 = d3lab1lst_tr_48 (tmp546) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sel_var (tmp346, tmp547, tmp545, tmp549) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: if (((ats_sum_ptr_type)tmp348)->tag != 46) { goto __ats_lab_174_0 ; } __ats_lab_173_1: tmp550 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = d3exp_seq_tr_44 (tmp346, tmp551, tmp550) ; break ; /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp348)->tag != 47) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp552 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_1) ; tmp553 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_2) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp552) ; tmp555 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp553) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_sif (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void, tmp554, tmp555) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp348)->tag != 48) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp556 = ats_caselptrlab_mac(anairiats_sum_27, tmp348, atslab_0) ; tmp557 = ats_caselptrlab_mac(anairiats_sum_27, tmp348, atslab_1) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_string (tmp346, tmp558, tmp556, tmp557) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp348)->tag != 49) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp559 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp561 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp562 = labd3explst_arg_tr_41 (0, tmp559) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_rec (tmp346, tmp560, 0, tmp561, tmp562) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp348)->tag != 50) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp563 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp564 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp565 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp345 = d3exp_tmpcst_tr_45 (tmp346, tmp565, tmp563, tmp564) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: if (((ats_sum_ptr_type)tmp348)->tag != 51) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp566 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp567 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp568 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 1, tmp347) ; tmp345 = d3exp_tmpvar_tr_46 (tmp346, tmp568, tmp566, tmp567) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp348)->tag != 52) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp569 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_top (tmp346, tmp569) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: if (((ats_sum_ptr_type)tmp348)->tag != 53) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp570 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp571 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp572 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp570) ; tmp574 = c3laulst_tr_52 (tmp571) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_trywith (tmp346, tmp572, tmp573, tmp574) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp348)->tag != 54) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp575 = ats_caselptrlab_mac(anairiats_sum_2, tmp348, atslab_0) ; tmp577 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_isprf (tmp575) ; if (tmp577) { /* tmp578 = */ prerr_loc_error4_0 (tmp346) ; /* tmp579 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp580 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp575) ; /* tmp581 = */ atspre_prerr_string (ATSstrcst("] refers to a proof and thus should have been erased.")) ; /* tmp582 = */ atspre_prerr_newline () ; /* tmp576 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp583 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; /* tmp584 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_count (tmp575) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_var (tmp346, tmp583, tmp575) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp348)->tag != 55) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: if (((ats_sum_ptr_type)tmp348)->tag != 56) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_empty (tmp346, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp348)->tag != 57) { goto __ats_lab_185_0 ; } __ats_lab_184_1: /* tmp585 = */ prerr_loc_interror_2 (tmp346) ; /* tmp586 = */ atspre_prerr_string (ATSstrcst(": this proof expression should have already been erased.")) ; /* tmp587 = */ atspre_prerr_newline () ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: if (((ats_sum_ptr_type)tmp348)->tag != 58) { goto __ats_lab_186_0 ; } __ats_lab_185_1: /* tmp588 = */ prerr_loc_interror_2 (tmp346) ; /* tmp589 = */ atspre_prerr_string (ATSstrcst(": this proof expression should have already been erased.")) ; /* tmp590 = */ atspre_prerr_newline () ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: // if (((ats_sum_ptr_type)tmp348)->tag != 59) { ats_deadcode_failure_handle () ; } __ats_lab_186_1: tmp591 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_0) ; tmp592 = ats_caselptrlab_mac(anairiats_sum_4, tmp348, atslab_1) ; tmp593 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp346, 0, tmp347) ; tmp594 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp592) ; tmp595 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp591) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiexp_let_simplify (tmp346, tmp593, tmp594, tmp595) ; break ; } while (0) ; return (tmp345) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43332(line=1360, offs=13) -- 43375(line=1360, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp596) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr: tmp596 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr) ; return (tmp596) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43399(line=1363, offs=13) -- 43488(line=1365, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr: do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp598 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp599 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp598) ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp597, atslab_0, tmp599) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_188_1: tmp597 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp597) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3expopt_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43539(line=1369, offs=5) -- 43763(line=1375, offs=28) */ ATSstaticdec() ats_void_type labd3explst_prf_tr_57 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; // ATSlocal_void (tmp603) ; __ats_lab_labd3explst_prf_tr_57: do { /* branch: __ats_lab_189 */ __ats_lab_189_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_190_0 ; } __ats_lab_189_1: tmp601 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp602 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_2) ; /* tmp603 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp601) ; arg0 = tmp602 ; goto __ats_lab_labd3explst_prf_tr_57 ; // tail call break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_190_1: break ; } while (0) ; return /* (tmp600) */ ; } /* end of [labd3explst_prf_tr_57] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43849(line=1379, offs=6) -- 43900(line=1379, offs=57) */ ATSstaticdec() ats_void_type f_59 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; __ats_lab_f_59: tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_c3lau_exp) ; /* tmp605 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp606) ; return /* (tmp605) */ ; } /* end of [f_59] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43799(line=1378, offs=4) -- 43942(line=1382, offs=4) */ ATSstaticdec() ats_void_type c3laulst_prf_tr_58 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp604) ; __ats_lab_c3laulst_prf_tr_58: /* tmp604 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &f_59) ; return /* (tmp604) */ ; } /* end of [c3laulst_prf_tr_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 46652(line=1475, offs=10) -- 46707(line=1475, offs=65) */ ATSstaticdec() ats_void_type f_61 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; __ats_lab_f_61: tmp643 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_sc3lau_exp) ; /* tmp642 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp643) ; return /* (tmp642) */ ; } /* end of [f_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 43995(line=1385, offs=14) -- 48368(line=1526, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; // ATSlocal_void (tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; // ATSlocal_void (tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; // ATSlocal_void (tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; // ATSlocal_void (tmp630) ; // ATSlocal_void (tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; // ATSlocal_void (tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_ptr_type, tmp648) ; // ATSlocal_void (tmp649) ; // ATSlocal_void (tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; // ATSlocal_void (tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; // ATSlocal_void (tmp659) ; // ATSlocal_void (tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; // ATSlocal_void (tmp662) ; // ATSlocal_void (tmp663) ; // ATSlocal_void (tmp664) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr: tmp608 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_node) ; do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (((ats_sum_ptr_type)tmp608)->tag != 0) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp609 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; arg0 = tmp609 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: if (((ats_sum_ptr_type)tmp608)->tag != 1) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp610 = ats_caselptrlab_mac(anairiats_sum_11, tmp608, atslab_0) ; tmp611 = ats_caselptrlab_mac(anairiats_sum_11, tmp608, atslab_2) ; /* tmp612 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp610) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (tmp611) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: if (((ats_sum_ptr_type)tmp608)->tag != 2) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp613 = ats_caselptrlab_mac(anairiats_sum_2, tmp608, atslab_0) ; arg0 = tmp613 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp608)->tag != 5) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp614 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_0) ; tmp615 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; /* tmp616 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp614) ; arg0 = tmp615 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp608)->tag != 6) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp617 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; arg0 = tmp617 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)tmp608)->tag != 8) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp618 = ats_caselptrlab_mac(anairiats_sum_14, tmp608, atslab_1) ; tmp619 = ats_caselptrlab_mac(anairiats_sum_14, tmp608, atslab_2) ; /* tmp620 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (tmp618) ; /* tmp607 = */ c3laulst_prf_tr_58 (tmp619) ; break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)tmp608)->tag != 9) { goto __ats_lab_198_0 ; } __ats_lab_197_1: break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: if (((ats_sum_ptr_type)tmp608)->tag != 10) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp621 = ats_caselptrlab_mac(anairiats_sum_11, tmp608, atslab_2) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (tmp621) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp608)->tag != 11) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp622 = ats_caselptrlab_mac(anairiats_sum_2, tmp608, atslab_0) ; /* tmp607 = */ atsopt_the_dyncstset_add_if (tmp622) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp608)->tag != 13) { goto __ats_lab_201_0 ; } __ats_lab_200_1: tmp623 = ats_caselptrlab_mac(anairiats_sum_7, tmp608, atslab_1) ; arg0 = tmp623 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_201 */ __ats_lab_201_0: if (((ats_sum_ptr_type)tmp608)->tag != 15) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_1) ; arg0 = tmp624 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)tmp608)->tag != 16) { goto __ats_lab_203_0 ; } __ats_lab_202_1: break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)tmp608)->tag != 17) { goto __ats_lab_204_0 ; } __ats_lab_203_1: break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp608)->tag != 18) { goto __ats_lab_205_0 ; } __ats_lab_204_1: tmp625 = ats_caselptrlab_mac(anairiats_sum_14, tmp608, atslab_2) ; arg0 = tmp625 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: if (((ats_sum_ptr_type)tmp608)->tag != 21) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp626 = ats_caselptrlab_mac(anairiats_sum_2, tmp608, atslab_0) ; arg0 = tmp626 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp608)->tag != 23) { goto __ats_lab_207_0 ; } __ats_lab_206_1: tmp627 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_0) ; tmp628 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_1) ; tmp629 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; /* tmp630 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp627) ; /* tmp631 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp628) ; arg0 = tmp629 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: if (((ats_sum_ptr_type)tmp608)->tag != 24) { goto __ats_lab_208_0 ; } __ats_lab_207_1: break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: if (((ats_sum_ptr_type)tmp608)->tag != 26) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp632 = ats_caselptrlab_mac(anairiats_sum_24, tmp608, atslab_3) ; arg0 = tmp632 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)tmp608)->tag != 29) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp633 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; arg0 = tmp633 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)tmp608)->tag != 28) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp634 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_1) ; arg0 = tmp634 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp608)->tag != 33) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp635 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; tmp636 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_1) ; /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (tmp635) ; arg0 = tmp636 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp608)->tag != 36) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp638 = ats_caselptrlab_mac(anairiats_sum_14, tmp608, atslab_2) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (tmp638) ; break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: if (((ats_sum_ptr_type)tmp608)->tag != 37) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; arg0 = tmp639 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp608)->tag != 38) { goto __ats_lab_215_0 ; } __ats_lab_214_1: break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp608)->tag != 40) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp640 = ats_caselptrlab_mac(anairiats_sum_18, tmp608, atslab_2) ; /* tmp607 = */ labd3explst_prf_tr_57 (tmp640) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp608)->tag != 41) { goto __ats_lab_217_0 ; } __ats_lab_216_1: break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp608)->tag != 42) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp641 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_1) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp641, &f_61) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp608)->tag != 43) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; arg0 = tmp644 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp608)->tag != 44) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp645 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; arg0 = tmp645 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp608)->tag != 45) { goto __ats_lab_221_0 ; } __ats_lab_220_1: break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp608)->tag != 46) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp646 = ats_caselptrlab_mac(anairiats_sum_2, tmp608, atslab_0) ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (tmp646) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp608)->tag != 47) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp647 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_1) ; tmp648 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp647) ; /* tmp650 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp648) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: if (((ats_sum_ptr_type)tmp608)->tag != 48) { goto __ats_lab_224_0 ; } __ats_lab_223_1: break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: if (((ats_sum_ptr_type)tmp608)->tag != 49) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp651 = ats_caselptrlab_mac(anairiats_sum_2, tmp608, atslab_0) ; /* tmp607 = */ labd3explst_prf_tr_57 (tmp651) ; break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: if (((ats_sum_ptr_type)tmp608)->tag != 54) { goto __ats_lab_226_0 ; } __ats_lab_225_1: break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: if (((ats_sum_ptr_type)tmp608)->tag != 55) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp652 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_0) ; tmp653 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; /* tmp654 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp652) ; arg0 = tmp653 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: if (((ats_sum_ptr_type)tmp608)->tag != 56) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp655 = ats_caselptrlab_mac(anairiats_sum_8, tmp608, atslab_2) ; arg0 = tmp655 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: if (((ats_sum_ptr_type)tmp608)->tag != 57) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp656 = ats_caselptrlab_mac(anairiats_sum_25, tmp608, atslab_0) ; arg0 = tmp656 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: if (((ats_sum_ptr_type)tmp608)->tag != 58) { goto __ats_lab_230_0 ; } __ats_lab_229_1: break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: if (((ats_sum_ptr_type)tmp608)->tag != 59) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp657 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_0) ; tmp658 = ats_caselptrlab_mac(anairiats_sum_4, tmp608, atslab_1) ; /* tmp659 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (tmp658) ; arg0 = tmp657 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr ; // tail call break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: __ats_lab_231_1: tmp661 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg0), atslab_d3exp_loc) ; /* tmp660 = */ prerr_loc_interror_2 (tmp661) ; /* tmp662 = */ atspre_prerr_string (ATSstrcst(": d3exp_prf_tr: d3e0 = ")) ; /* tmp663 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_d3exp (arg0) ; /* tmp664 = */ atspre_prerr_newline () ; /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp607) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 48424(line=1529, offs=17) -- 48475(line=1529, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp665) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr: /* tmp665 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr) ; return /* (tmp665) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3explst_prf_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 48529(line=1534, offs=4) -- 49157(line=1554, offs=4) */ ATSstaticdec() ats_ptr_type f3undec_tr_63 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; // ATSlocal_void (tmp671) ; __ats_lab_f3undec_tr_63: tmp667 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_f3undec_loc) ; tmp668 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_f3undec_var) ; tmp670 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg1), atslab_f3undec_def) ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp670) ; do { /* branch: __ats_lab_232 */ __ats_lab_232_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_233_0 ; } __ats_lab_232_1: /* tmp671 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpvarmap_add (tmp668, arg0, tmp669) ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_233_1: break ; } while (0) ; tmp666 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hifundec_make (tmp667, tmp668, tmp669) ; return (tmp666) ; } /* end of [f3undec_tr_63] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 49283(line=1558, offs=31) -- 49326(line=1558, offs=74) */ ATSstaticdec() ats_ptr_type __ats_fun_65 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp674) ; __ats_lab___ats_fun_65: tmp674 = f3undec_tr_63 (env0, arg0) ; return (tmp674) ; } /* end of [__ats_fun_65] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_65_closure_type ; ats_ptr_type __ats_fun_65_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_65 (((__ats_fun_65_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_65_closure_init (__ats_fun_65_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_65_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_65_closure_make (ats_ptr_type env0) { __ats_fun_65_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_65_closure_type)) ; __ats_fun_65_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 49185(line=1556, offs=4) -- 49327(line=1558, offs=75) */ ATSstaticdec() ats_ptr_type f3undeclst_tr_64 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; __ats_lab_f3undeclst_tr_64: /* ats_ptr_type tmp673 ; */ tmp673 = __ats_fun_65_closure_make (arg0) ; tmp672 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (arg1, tmp673) ; ATS_FREE(tmp673) ; return (tmp672) ; } /* end of [f3undeclst_tr_64] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 49359(line=1561, offs=5) -- 49585(line=1566, offs=22) */ ATSstaticdec() ats_void_type f3undeclst_prf_tr_66 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; // ATSlocal_void (tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; __ats_lab_f3undeclst_prf_tr_66: do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp676 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp677 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp679 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, tmp676), atslab_f3undec_def) ; /* tmp678 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp679) ; arg0 = tmp677 ; goto __ats_lab_f3undeclst_prf_tr_66 ; // tail call break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: break ; } while (0) ; return /* (tmp675) */ ; } /* end of [f3undeclst_prf_tr_66] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 49662(line=1571, offs=4) -- 50147(line=1588, offs=4) */ ATSstaticdec() ats_ptr_type v3aldec_tr_67 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_bool_type, tmp685) ; // ATSlocal_void (tmp686) ; // ATSlocal_void (tmp687) ; // ATSlocal_void (tmp688) ; // ATSlocal_void (tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; __ats_lab_v3aldec_tr_67: tmp681 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_v3aldec_loc) ; tmp683 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_v3aldec_pat) ; tmp682 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__p3at_tr (tmp683) ; tmp684 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_v3aldec_def) ; tmp685 = d3exp_is_proof_33 (tmp684) ; if (tmp685) { /* tmp687 = */ prerr_loc_error4_0 (tmp681) ; /* tmp688 = */ atspre_prerr_string (ATSstrcst(": [val] should be replaced with [prval] as this is a proof binding.")) ; /* tmp689 = */ atspre_prerr_newline () ; /* tmp686 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp690 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp684) ; tmp680 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivaldec_make (tmp681, tmp682, tmp690) ; return (tmp680) ; } /* end of [v3aldec_tr_67] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 50175(line=1590, offs=4) -- 50261(line=1591, offs=73) */ ATSstaticdec() ats_ptr_type v3aldeclst_tr_68 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp691) ; __ats_lab_v3aldeclst_tr_68: tmp691 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &v3aldec_tr_67) ; return (tmp691) ; } /* end of [v3aldeclst_tr_68] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 50292(line=1594, offs=4) -- 50604(line=1604, offs=4) */ ATSstaticdec() ats_ptr_type v3ardec_tr_69 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_int_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_ptr_type, tmp699) ; __ats_lab_v3ardec_tr_69: tmp693 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_v3ardec_loc) ; tmp694 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_v3ardec_knd) ; tmp695 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_v3ardec_dvar_ptr) ; tmp697 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_v3ardec_ini) ; do { /* branch: __ats_lab_236 */ __ats_lab_236_0: if (tmp697 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp698 = ats_caselptrlab_mac(anairiats_sum_3, tmp697, atslab_0) ; tmp699 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp698) ; tmp696 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp696, atslab_0, tmp699) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: // if (tmp697 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_237_1: tmp696 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp692 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hivardec_make (tmp693, tmp694, tmp695, tmp696) ; return (tmp692) ; } /* end of [v3ardec_tr_69] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 50632(line=1606, offs=4) -- 50718(line=1607, offs=73) */ ATSstaticdec() ats_ptr_type v3ardeclst_tr_70 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp700) ; __ats_lab_v3ardeclst_tr_70: tmp700 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &v3ardec_tr_69) ; return (tmp700) ; } /* end of [v3ardeclst_tr_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 50750(line=1610, offs=5) -- 50976(line=1615, offs=22) */ ATSstaticdec() ats_void_type v3aldeclst_prf_tr_71 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; // ATSlocal_void (tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; __ats_lab_v3aldeclst_prf_tr_71: do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp702 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp703 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp705 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, tmp702), atslab_v3aldec_def) ; /* tmp704 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp705) ; arg0 = tmp703 ; goto __ats_lab_v3aldeclst_prf_tr_71 ; // tail call break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_239_1: break ; } while (0) ; return /* (tmp701) */ ; } /* end of [v3aldeclst_prf_tr_71] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 51053(line=1620, offs=4) -- 52634(line=1676, offs=4) */ ATSstaticdec() ats_ptr_type i3mpdec_tr_72 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_int_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; // ATSlocal_void (tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; // ATSlocal_void (tmp716) ; // ATSlocal_void (tmp717) ; // ATSlocal_void (tmp718) ; // ATSlocal_void (tmp719) ; // ATSlocal_void (tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; // ATSlocal_void (tmp723) ; ATSlocal (ats_bool_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; // ATSlocal_void (tmp726) ; // ATSlocal_void (tmp727) ; // ATSlocal_void (tmp728) ; // ATSlocal_void (tmp729) ; // ATSlocal_void (tmp730) ; // ATSlocal_void (tmp731) ; ATSlocal (ats_bool_type, tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; __ats_lab_i3mpdec_tr_72: tmp707 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_i3mpdec_loc) ; tmp708 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_i3mpdec_cst) ; tmp709 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_i3mpdec_decarg) ; do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (tmp709 == (ats_sum_ptr_type)0) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp710 = 1 ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: // if (tmp709 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_241_1: tmp710 = 0 ; break ; } while (0) ; /* ats_ptr_type tmp711 ; */ tmp711 = (ats_sum_ptr_type)0 ; tmp712 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_i3mpdec_tmparg) ; tmp713 = s2explstlst_tr_named_10 (tmp707, tmp712, (&tmp711)) ; do { /* branch: __ats_lab_242 */ __ats_lab_242_0: if (tmp711 == (ats_sum_ptr_type)0) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp715 = ats_caselptrlab_mac(anairiats_sum_3, tmp711, atslab_0) ; /* tmp716 = */ prerr_loc_error4_0 (tmp707) ; /* tmp717 = */ atspre_prerr_string (ATSstrcst(": the template parameter [")) ; /* tmp718 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp715) ; /* tmp719 = */ atspre_prerr_string (ATSstrcst("] is required to be named but it is not.")) ; /* tmp720 = */ atspre_prerr_newline () ; /* tmp714 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: // if (tmp711 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_243_1: break ; } while (0) ; tmp722 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_i3mpdec_def) ; tmp721 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp722) ; do { /* branch: __ats_lab_244 */ __ats_lab_244_0: __ats_lab_244_1: tmp724 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_fun (tmp708) ; if (!tmp724) { goto __ats_lab_247_1 ; } tmp725 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, tmp721), atslab_hiexp_node) ; do { /* branch: __ats_lab_245 */ __ats_lab_245_0: if (((ats_sum_ptr_type)tmp725)->tag != 22) { goto __ats_lab_246_0 ; } __ats_lab_245_1: break ; /* branch: __ats_lab_246 */ __ats_lab_246_0: __ats_lab_246_1: /* tmp726 = */ prerr_loc_error4_0 (tmp707) ; /* tmp727 = */ atspre_prerr_string (ATSstrcst(": the dynamic constant [")) ; /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (tmp708) ; /* tmp729 = */ atspre_prerr_string (ATSstrcst("] is required to be implemented as a function but it is not.")) ; /* tmp730 = */ atspre_prerr_newline () ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_247 */ __ats_lab_247_0: __ats_lab_247_1: break ; } while (0) ; tmp732 = atspre_gt_int_int (tmp710, 0) ; if (tmp732) { /* tmp731 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__tmpcstmap_add (tmp708, tmp709, tmp721) ; } else { /* empty */ } /* end of [if] */ tmp733 = atsopt_the_dyncstset_get () ; tmp706 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_make (tmp707, tmp708, tmp710, tmp709, tmp713, tmp721, tmp733) ; return (tmp706) ; } /* end of [i3mpdec_tr_72] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 52784(line=1685, offs=7) -- 58136(line=1827, offs=6) */ ATSstaticdec() ats_void_type aux0_74 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp840) ; /* tmp840 = */ aux0_74_0aux1_75 (0, arg0, arg1) ; return /* (tmp840) */ ; } /* end of [aux0_74] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 58163(line=1829, offs=7) -- 58389(line=1838, offs=6) */ ATSstaticdec() ats_void_type aux1_75 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ // ATSlocal_void (tmp841) ; /* tmp841 = */ aux0_74_0aux1_75 (1, arg0, arg1, arg2) ; return /* (tmp841) */ ; } /* end of [aux1_75] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 52784(line=1685, offs=7) -- 58389(line=1838, offs=6) */ ATSstaticdec() ats_void_type aux0_74_0aux1_75 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ref_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_ref_type, tmp739) ; // ATSlocal_void (tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_int_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_bool_type, tmp779) ; // ATSlocal_void (tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; ATSlocal (ats_ptr_type, tmp783) ; ATSlocal (ats_ptr_type, tmp784) ; // ATSlocal_void (tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; ATSlocal (ats_bool_type, tmp794) ; // ATSlocal_void (tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_bool_type, tmp801) ; // ATSlocal_void (tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_int_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; // ATSlocal_void (tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; // ATSlocal_void (tmp839) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp735 = va_arg(funarg, ats_ptr_type) ; tmp736 = va_arg(funarg, ats_ref_type) ; va_end(funarg) ; goto __ats_lab_aux0_74 ; case 1: va_start(funarg, arg0) ; tmp737 = va_arg(funarg, ats_ptr_type) ; tmp738 = va_arg(funarg, ats_ptr_type) ; tmp739 = va_arg(funarg, ats_ref_type) ; va_end(funarg) ; goto __ats_lab_aux1_75 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_aux0_74: do { /* branch: __ats_lab_248 */ __ats_lab_248_0: if (tmp735 == (ats_sum_ptr_type)0) { goto __ats_lab_271_0 ; } __ats_lab_248_1: tmp741 = ats_caselptrlab_mac(anairiats_sum_5, tmp735, atslab_0) ; tmp742 = ats_caselptrlab_mac(anairiats_sum_5, tmp735, atslab_1) ; tmp743 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_node) ; do { /* branch: __ats_lab_249 */ __ats_lab_249_0: if (((ats_sum_ptr_type)tmp743)->tag != 0) { goto __ats_lab_250_0 ; } __ats_lab_249_1: tmp735 = tmp742 ; tmp736 = tmp736 ; goto __ats_lab_aux0_74 ; // tail call break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: if (((ats_sum_ptr_type)tmp743)->tag != 1) { goto __ats_lab_251_0 ; } __ats_lab_250_1: tmp744 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp746 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp747 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp744) ; tmp745 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_list (tmp746, tmp747) ; tmp737 = tmp742 ; tmp738 = tmp745 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: if (((ats_sum_ptr_type)tmp743)->tag != 2) { goto __ats_lab_252_0 ; } __ats_lab_251_1: tmp748 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp750 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp749 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_saspdec (tmp750, tmp748) ; tmp737 = tmp742 ; tmp738 = tmp749 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: if (((ats_sum_ptr_type)tmp743)->tag != 3) { goto __ats_lab_253_0 ; } __ats_lab_252_1: tmp751 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp752 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp754 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp753 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dcstdec (tmp754, tmp751, tmp752) ; tmp737 = tmp742 ; tmp738 = tmp753 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: if (((ats_sum_ptr_type)tmp743)->tag != 4) { goto __ats_lab_254_0 ; } __ats_lab_253_1: tmp755 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp756 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp758 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp757 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_datdec (tmp758, tmp755, tmp756) ; tmp737 = tmp742 ; tmp738 = tmp757 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp743)->tag != 5) { goto __ats_lab_255_0 ; } __ats_lab_254_1: tmp759 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp761 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp760 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_exndec (tmp761, tmp759) ; tmp737 = tmp742 ; tmp738 = tmp760 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: if (((ats_sum_ptr_type)tmp743)->tag != 6) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp762 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp763 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp764 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp765 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__s2exp_tr (tmp764, 1, tmp763) ; tmp766 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extype (tmp764, tmp762, tmp765) ; tmp737 = tmp742 ; tmp738 = tmp766 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: if (((ats_sum_ptr_type)tmp743)->tag != 7) { goto __ats_lab_257_0 ; } __ats_lab_256_1: tmp767 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp768 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp769 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_tr (tmp768) ; tmp771 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp770 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extval (tmp771, tmp767, tmp769) ; tmp737 = tmp742 ; tmp738 = tmp770 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: if (((ats_sum_ptr_type)tmp743)->tag != 8) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp772 = ats_caselptrlab_mac(anairiats_sum_7, tmp743, atslab_0) ; tmp773 = ats_caselptrlab_mac(anairiats_sum_7, tmp743, atslab_1) ; tmp775 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp774 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_extern (tmp775, tmp772, tmp773) ; tmp737 = tmp742 ; tmp738 = tmp774 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp743)->tag != 14) { goto __ats_lab_261_0 ; } __ats_lab_258_1: tmp776 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp777 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, tmp776), atslab_i3mpdec_cst) ; do { /* branch: __ats_lab_259 */ __ats_lab_259_0: __ats_lab_259_1: tmp779 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_is_proof (tmp777) ; if (!tmp779) { goto __ats_lab_260_1 ; } /* tmp780 = */ atsopt_the_dyncstsetlst_push () ; /* tmp781 = ats_selsin_mac(tmp780, atslab_1) */ ; tmp783 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, tmp776), atslab_i3mpdec_def) ; /* tmp782 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3exp_prf_tr (tmp783) ; tmp784 = atsopt_the_dyncstsetlst_pop () ; /* tmp785 = */ atsopt_the_dyncstset_add_if (tmp777) ; tmp787 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, tmp776), atslab_i3mpdec_loc) ; tmp786 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hiimpdec_prf_make (tmp787, tmp777, tmp784) ; tmp788 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp778 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec_prf (tmp788, tmp786) ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: __ats_lab_260_1: tmp789 = i3mpdec_tr_72 (tmp776) ; tmp790 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp778 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_impdec (tmp790, tmp789) ; break ; } while (0) ; tmp737 = tmp742 ; tmp738 = tmp778 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)tmp743)->tag != 12) { goto __ats_lab_262_0 ; } __ats_lab_261_1: tmp791 = ats_caselptrlab_mac(anairiats_sum_8, tmp743, atslab_0) ; tmp792 = ats_caselptrlab_mac(anairiats_sum_8, tmp743, atslab_1) ; tmp793 = ats_caselptrlab_mac(anairiats_sum_8, tmp743, atslab_2) ; tmp794 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof (tmp792) ; if (tmp794) { /* tmp795 = */ f3undeclst_prf_tr_66 (tmp793) ; tmp735 = tmp742 ; tmp736 = tmp736 ; goto __ats_lab_aux0_74 ; // tail call } else { tmp796 = f3undeclst_tr_64 (tmp791, tmp793) ; tmp798 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp797 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_fundecs (tmp798, tmp791, tmp792, tmp796) ; tmp737 = tmp742 ; tmp738 = tmp797 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp743)->tag != 9) { goto __ats_lab_263_0 ; } __ats_lab_262_1: tmp799 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp800 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp801 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof (tmp799) ; if (tmp801) { /* tmp802 = */ v3aldeclst_prf_tr_71 (tmp800) ; tmp735 = tmp742 ; tmp736 = tmp736 ; goto __ats_lab_aux0_74 ; // tail call } else { tmp804 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp805 = v3aldeclst_tr_68 (tmp800) ; tmp803 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs (tmp804, tmp799, tmp805) ; tmp737 = tmp742 ; tmp738 = tmp803 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_263 */ __ats_lab_263_0: if (((ats_sum_ptr_type)tmp743)->tag != 10) { goto __ats_lab_264_0 ; } __ats_lab_263_1: tmp806 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp808 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp809 = v3aldeclst_tr_68 (tmp806) ; tmp807 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_par (tmp808, tmp809) ; tmp737 = tmp742 ; tmp738 = tmp807 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: if (((ats_sum_ptr_type)tmp743)->tag != 11) { goto __ats_lab_265_0 ; } __ats_lab_264_1: tmp810 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp812 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp813 = v3aldeclst_tr_68 (tmp810) ; tmp811 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_valdecs_rec (tmp812, tmp813) ; tmp737 = tmp742 ; tmp738 = tmp811 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: if (((ats_sum_ptr_type)tmp743)->tag != 13) { goto __ats_lab_266_0 ; } __ats_lab_265_1: tmp814 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp816 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp817 = v3ardeclst_tr_70 (tmp814) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_vardecs (tmp816, tmp817) ; tmp737 = tmp742 ; tmp738 = tmp815 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: if (((ats_sum_ptr_type)tmp743)->tag != 15) { goto __ats_lab_267_0 ; } __ats_lab_266_1: tmp818 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_0) ; tmp819 = ats_caselptrlab_mac(anairiats_sum_4, tmp743, atslab_1) ; tmp820 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp818) ; tmp821 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp819) ; tmp823 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp822 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_local (tmp823, tmp820, tmp821) ; tmp737 = tmp742 ; tmp738 = tmp822 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: if (((ats_sum_ptr_type)tmp743)->tag != 16) { goto __ats_lab_270_0 ; } __ats_lab_267_1: tmp824 = ats_caselptrlab_mac(anairiats_sum_11, tmp743, atslab_0) ; tmp825 = ats_caselptrlab_mac(anairiats_sum_11, tmp743, atslab_1) ; tmp826 = ats_caselptrlab_mac(anairiats_sum_11, tmp743, atslab_2) ; do { /* branch: __ats_lab_268 */ __ats_lab_268_0: if (tmp826 == (ats_sum_ptr_type)0) { goto __ats_lab_269_0 ; } __ats_lab_268_1: tmp828 = ats_caselptrlab_mac(anairiats_sum_3, tmp826, atslab_0) ; tmp829 = ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (tmp828) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: // if (tmp826 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_269_1: break ; } while (0) ; tmp831 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp830 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_staload (tmp831, tmp824, tmp825) ; tmp737 = tmp742 ; tmp738 = tmp830 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: // if (((ats_sum_ptr_type)tmp743)->tag != 17) { ats_deadcode_failure_handle () ; } __ats_lab_270_1: tmp832 = ats_caselptrlab_mac(anairiats_sum_2, tmp743, atslab_0) ; tmp834 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp741), atslab_d3ec_loc) ; tmp833 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hidec_dynload (tmp834, tmp832) ; tmp737 = tmp742 ; tmp738 = tmp833 ; tmp739 = tmp736 ; goto __ats_lab_aux1_75 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_271 */ __ats_lab_271_0: // if (tmp735 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_271_1: tmp835 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp736) = tmp835 ; break ; } while (0) ; return /* tmp740 */ ; __ats_lab_aux1_75: tmp837 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp837, atslab_0, tmp738) ; ats_ptrget_mac(ats_ptr_type, tmp739) = tmp837 ; // if (ats_ptrget_mac(ats_ptr_type, tmp739) == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp838 = &ats_caselptrlab_mac(anairiats_sum_5, ats_ptrget_mac(ats_ptr_type, tmp739), atslab_1) ; tmp735 = tmp737 ; tmp736 = tmp838 ; goto __ats_lab_aux0_74 ; // tail call return /* tmp836 */ ; return /* (tmp839) */ ; } /* end of [aux0_74_0aux1_75] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 52701(line=1681, offs=12) -- 58476(line=1842, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp734) ; ATSlocal (ats_ptr_type, tmp842) ; // ATSlocal_void (tmp843) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr: /* ats_ptr_type tmp842 ; */ /* tmp843 = */ aux0_74 (arg0, (&tmp842)) ; tmp734 = tmp842 ; return (tmp734) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_tr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 58585(line=1849, offs=7) -- 59964(line=1886, offs=6) */ ATSstaticdec() ats_void_type aux_78 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; // ATSlocal_void (tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; // ATSlocal_void (tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; // ATSlocal_void (tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; // ATSlocal_void (tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; // ATSlocal_void (tmp859) ; // ATSlocal_void (tmp860) ; // ATSlocal_void (tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; // ATSlocal_void (tmp863) ; // ATSlocal_void (tmp864) ; __ats_lab_aux_78: do { /* branch: __ats_lab_272 */ __ats_lab_272_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_285_0 ; } __ats_lab_272_1: tmp846 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_0) ; tmp847 = ats_caselptrlab_mac(anairiats_sum_5, arg0, atslab_1) ; tmp848 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp846), atslab_d3ec_node) ; do { /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)tmp848)->tag != 0) { goto __ats_lab_274_0 ; } __ats_lab_273_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)tmp848)->tag != 1) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp849 = ats_caselptrlab_mac(anairiats_sum_2, tmp848, atslab_0) ; /* tmp850 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (tmp849) ; arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)tmp848)->tag != 4) { goto __ats_lab_276_0 ; } __ats_lab_275_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: if (((ats_sum_ptr_type)tmp848)->tag != 5) { goto __ats_lab_277_0 ; } __ats_lab_276_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp848)->tag != 3) { goto __ats_lab_278_0 ; } __ats_lab_277_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_278 */ __ats_lab_278_0: if (((ats_sum_ptr_type)tmp848)->tag != 12) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp851 = ats_caselptrlab_mac(anairiats_sum_8, tmp848, atslab_2) ; /* tmp852 = */ f3undeclst_prf_tr_66 (tmp851) ; arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: if (((ats_sum_ptr_type)tmp848)->tag != 9) { goto __ats_lab_280_0 ; } __ats_lab_279_1: tmp853 = ats_caselptrlab_mac(anairiats_sum_4, tmp848, atslab_1) ; /* tmp854 = */ v3aldeclst_prf_tr_71 (tmp853) ; arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: if (((ats_sum_ptr_type)tmp848)->tag != 11) { goto __ats_lab_281_0 ; } __ats_lab_280_1: tmp855 = ats_caselptrlab_mac(anairiats_sum_2, tmp848, atslab_0) ; /* tmp856 = */ v3aldeclst_prf_tr_71 (tmp855) ; arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_281 */ __ats_lab_281_0: if (((ats_sum_ptr_type)tmp848)->tag != 15) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp857 = ats_caselptrlab_mac(anairiats_sum_4, tmp848, atslab_0) ; tmp858 = ats_caselptrlab_mac(anairiats_sum_4, tmp848, atslab_1) ; /* tmp859 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (tmp857) ; /* tmp860 = */ ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (tmp858) ; arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: if (((ats_sum_ptr_type)tmp848)->tag != 16) { goto __ats_lab_283_0 ; } __ats_lab_282_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_283 */ __ats_lab_283_0: if (((ats_sum_ptr_type)tmp848)->tag != 17) { goto __ats_lab_284_0 ; } __ats_lab_283_1: arg0 = tmp847 ; goto __ats_lab_aux_78 ; // tail call break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: __ats_lab_284_1: tmp862 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_33, tmp846), atslab_d3ec_loc) ; /* tmp861 = */ prerr_loc_interror_2 (tmp862) ; /* tmp863 = */ atspre_prerr_string (ATSstrcst(": d3eclst_prf_tr: illegal proof declaration.")) ; /* tmp864 = */ atspre_prerr_newline () ; /* tmp845 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_285 */ __ats_lab_285_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_285_1: break ; } while (0) ; return /* (tmp845) */ ; } /* end of [aux_78] */ /* // /home/hwxi/research/Anairiats/src/ats_trans4.dats: 58549(line=1848, offs=3) -- 59982(line=1887, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp844) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr: /* tmp844 = */ aux_78 (arg0) ; return /* (tmp844) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__d3eclst_prf_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans4_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans4_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_sats.c0000664000175000017500000003770412223166160021252 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETlab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargtmpref_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPbool_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPchar_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcstsp_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPenv_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPext_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloat_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloatsp_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPint_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPintsp_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_ptr_offs_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_var_offs_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPsizeof_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPstring_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmpref_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKbool_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKchar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKcon_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKexn_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKfloat_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKint_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKstring_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplab_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplabint_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTcaseof_fail_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTfunarg_fail_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTraise_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTmatpnt_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_arr_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_tail_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_clo_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_fun_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_val_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_partval_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextern_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextval_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfreeptr_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunlab_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdynload_file_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloopexn_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_arg_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRpatck_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_offs_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_offs_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtmplabint_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_beg_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_end_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_tst_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETlab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__OFFSETind_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargtmpref_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPbool_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPchar_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcstsp_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPenv_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPext_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloat_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloatsp_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPint_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPintsp_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_ptr_offs_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_var_offs_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPsizeof_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPstring_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmpref_23.tag = 23 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24.tag = 24 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__LABVALPRIMLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKbool_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKchar_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKcon_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKexn_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKfloat_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKint_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__PATCKstring_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplab_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTtmplabint_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTcaseof_fail_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTfunarg_fail_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTraise_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__KONTmatpnt_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_arr_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_tail_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_clo_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_fun_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_val_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_partval_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextern_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextval_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfreeptr_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunlab_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdynload_file_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloopexn_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_arg_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRpatck_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_offs_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_offs_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtmplabint_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_beg_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_end_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_tst_44.tag = 44 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1.tag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_sats.c0000664000175000017500000000353212223166160021352 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_dcon_dats.c0000664000175000017500000010244312223166160022514 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_1 ; typedef struct { anairiats_rec_1 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_d2con_loc ; ats_ptr_type atslab_d2con_fil ; ats_ptr_type atslab_d2con_sym ; ats_ptr_type atslab_d2con_scst ; ats_int_type atslab_d2con_vwtp ; ats_ptr_type atslab_d2con_qua ; ats_int_type atslab_d2con_npf ; ats_ptr_type atslab_d2con_arg ; ats_int_type atslab_d2con_arity_full ; ats_int_type atslab_d2con_arity_real ; ats_ptr_type atslab_d2con_ind ; ats_ptr_type atslab_d2con_typ ; ats_int_type atslab_d2con_tag ; atsopt_count_type atslab_d2con_stamp ; } anairiats_rec_4 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2con_stamp_make) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__d2con_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type aux1_1 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_int_type aux2_2 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type _compare_d2con_d2con_22 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_31 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 2624(line=84, offs=7) -- 2784(line=86, offs=33) */ ATSstaticdec() ats_ptr_type aux1_1 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; __ats_lab_aux1_1: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp5 = atspre_gt_int_int (arg0, 0) ; if (tmp5) { tmp6 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp6 ; arg1 = tmp4 ; goto __ats_lab_aux1_1 ; // tail call } else { tmp3 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp3 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp3) ; } /* end of [aux1_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 2810(line=88, offs=7) -- 3027(line=92, offs=23) */ ATSstaticdec() ats_int_type aux2_2 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; __ats_lab_aux2_2: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp9 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp8) ; if (tmp10) { arg0 = arg0 ; arg1 = tmp9 ; goto __ats_lab_aux2_2 ; // tail call } else { tmp11 = atspre_add_int_int (arg0, 1) ; arg0 = tmp11 ; arg1 = tmp9 ; goto __ats_lab_aux2_2 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp7 = arg0 ; break ; } while (0) ; return (tmp7) ; } /* end of [aux2_2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 3146(line=99, offs=7) -- 3381(line=104, offs=25) */ ATSstaticdec() ats_ptr_type aux_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (anairiats_rec_1, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_aux_3: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp16 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp17 = ats_select_mac(tmp15, atslab_0) ; tmp18 = ats_select_mac(tmp15, atslab_1) ; tmp19 = aux_3 (arg0, tmp16) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp17, tmp18, tmp19) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp14 = arg0 ; break ; } while (0) ; return (tmp14) ; } /* end of [aux_3] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 2459(line=77, offs=22) -- 4161(line=139, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5, ats_int_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (atsopt_count_type, tmp1) ; ATSlocal (ats_int_type, tmp2) ; ATSlocal (ats_int_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2con_stamp_make () ; tmp2 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg7) ; tmp13 = aux1_1 (arg6, arg7) ; tmp12 = aux2_2 (0, tmp13) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg8 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_3, arg8, atslab_0) ; tmp20 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (arg3, tmp21) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg8 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp20 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (arg3) ; break ; } while (0) ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_confun (arg6, arg7, tmp20) ; tmp22 = aux_3 (tmp23, arg5) ; tmp24 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_4)) ; tmp25 = ats_selsin_mac(tmp24, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_fil) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_sym) = arg2 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_scst) = arg3 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_vwtp) = arg4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_qua) = arg5 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_npf) = arg6 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_arg) = arg7 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_arity_full) = tmp2 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_arity_real) = tmp12 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_ind) = arg8 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_typ) = tmp22 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_tag) = -1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp25), atslab_d2con_stamp) = tmp1 ; /* tmp26 = */ atspre_vbox_make_view_ptr (tmp25) ; /* tmp27 = ats_selsin_mac(tmp26, atslab_1) */ ; tmp0 = tmp25 ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4231(line=143, offs=25) -- 4288(line=144, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_fil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_fil: tmp29 = ats_selsin_mac(arg0, atslab_1) ; tmp28 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp29), atslab_d2con_fil) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_fil] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4314(line=146, offs=25) -- 4371(line=147, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym: tmp31 = ats_selsin_mac(arg0, atslab_1) ; tmp30 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp31), atslab_d2con_sym) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4398(line=149, offs=26) -- 4456(line=150, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst: tmp33 = ats_selsin_mac(arg0, atslab_1) ; tmp32 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp33), atslab_d2con_scst) ; return (tmp32) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4483(line=152, offs=26) -- 4541(line=153, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_vwtp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_vwtp: tmp35 = ats_selsin_mac(arg0, atslab_1) ; tmp34 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp35), atslab_d2con_vwtp) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_vwtp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4567(line=155, offs=25) -- 4624(line=156, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua: tmp37 = ats_selsin_mac(arg0, atslab_1) ; tmp36 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp37), atslab_d2con_qua) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_qua] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4650(line=158, offs=25) -- 4707(line=159, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf: tmp39 = ats_selsin_mac(arg0, atslab_1) ; tmp38 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp39), atslab_d2con_npf) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_npf] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4733(line=161, offs=25) -- 4790(line=162, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg: tmp41 = ats_selsin_mac(arg0, atslab_1) ; tmp40 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp41), atslab_d2con_arg) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4823(line=164, offs=32) -- 4887(line=165, offs=57) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full: tmp43 = ats_selsin_mac(arg0, atslab_1) ; tmp42 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp43), atslab_d2con_arity_full) ; return (tmp42) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 4920(line=167, offs=32) -- 4984(line=168, offs=57) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real: tmp45 = ats_selsin_mac(arg0, atslab_1) ; tmp44 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp45), atslab_d2con_arity_real) ; return (tmp44) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_real] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5010(line=170, offs=25) -- 5067(line=171, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ: tmp47 = ats_selsin_mac(arg0, atslab_1) ; tmp46 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp47), atslab_d2con_typ) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5093(line=173, offs=25) -- 5150(line=174, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_ind (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_ind: tmp49 = ats_selsin_mac(arg0, atslab_1) ; tmp48 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp49), atslab_d2con_ind) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5176(line=176, offs=25) -- 5233(line=177, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag: tmp51 = ats_selsin_mac(arg0, atslab_1) ; tmp50 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp51), atslab_d2con_tag) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5259(line=179, offs=25) -- 5328(line=180, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag: tmp53 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp53), atslab_d2con_tag) = arg1 ; return /* (tmp52) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_set_tag] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5356(line=182, offs=27) -- 5415(line=183, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_stamp: tmp55 = ats_selsin_mac(arg0, atslab_1) ; tmp54 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp55), atslab_d2con_stamp) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5465(line=188, offs=3) -- 5516(line=188, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_d2con_d2con (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp56) ; ATSlocal (ats_int_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_d2con_d2con: tmp57 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con (arg0, arg1) ; tmp56 = atspre_ilt (tmp57, 0) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_d2con_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5545(line=190, offs=3) -- 5597(line=190, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_d2con_d2con (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_int_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_d2con_d2con: tmp59 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con (arg0, arg1) ; tmp58 = atspre_ilte (tmp59, 0) ; return (tmp58) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_d2con_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5626(line=193, offs=3) -- 5677(line=193, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_int_type, tmp61) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con: tmp61 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con (arg0, arg1) ; tmp60 = atspre_ieq (tmp61, 0) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5706(line=195, offs=3) -- 5758(line=195, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_d2con_d2con (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_d2con_d2con: tmp63 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con (arg0, arg1) ; tmp62 = atspre_ineq (tmp63, 0) ; return (tmp62) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_d2con_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 5763(line=197, offs=4) -- 6057(line=207, offs=4) */ ATSstaticdec() ats_int_type _compare_d2con_d2con_22 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (atsopt_count_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (atsopt_count_type, tmp68) ; __ats_lab__compare_d2con_d2con_22: tmp65 = ats_selsin_mac(arg0, atslab_1) ; tmp66 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp65), atslab_d2con_stamp) ; tmp67 = ats_selsin_mac(arg1, atslab_1) ; tmp68 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp67), atslab_d2con_stamp) ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp66, tmp68) ; return (tmp64) ; } /* end of [_compare_d2con_d2con_22] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6121(line=210, offs=21) -- 6186(line=211, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp69) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con: tmp69 = _compare_d2con_d2con_22 (arg0, arg1) ; return (tmp69) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_d2con_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6292(line=219, offs=14) -- 6365(line=221, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn: tmp71 = ats_selsin_mac(arg0, atslab_1) ; tmp72 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp71), atslab_d2con_tag) ; tmp70 = atspre_eq_int_int (tmp72, -1) ; return (tmp70) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_exn] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6440(line=224, offs=24) -- 6513(line=226, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_msg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_msg: tmp74 = ats_selsin_mac(arg0, atslab_1) ; tmp75 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp74), atslab_d2con_tag) ; tmp73 = atspre_eq_int_int (tmp75, -2) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_msg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6565(line=229, offs=16) -- 6684(line=233, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_proof: tmp77 = ats_selsin_mac(arg0, atslab_1) ; tmp78 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp77), atslab_d2con_scst) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp78) ; tmp76 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun (tmp79) ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6803(line=240, offs=14) -- 6879(line=241, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con: tmp81 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_sym (arg1) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp81) ; return /* (tmp80) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6928(line=244, offs=23) -- 6965(line=244, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2con (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; // ATSlocal_void (tmp85) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2con: tmp83 = atspre_stdout_get () ; tmp84 = ats_selsin_mac(tmp83, atslab_1) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (tmp84, arg0) ; /* tmp82 = */ atspre_stdout_view_set () ; return /* (tmp82) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 6988(line=245, offs=23) -- 7025(line=245, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con: tmp87 = atspre_stderr_get () ; tmp88 = ats_selsin_mac(tmp87, atslab_1) ; /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (tmp88, arg0) ; /* tmp86 = */ atspre_stderr_view_set () ; return /* (tmp86) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 7109(line=252, offs=7) -- 7466(line=263, offs=6) */ ATSstaticdec() ats_void_type aux_31 (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; // ATSlocal_void (tmp94) ; ATSlocal (ats_bool_type, tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_int_type, tmp97) ; __ats_lab_aux_31: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp93 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp95 = atspre_gt_int_int (arg2, 0) ; if (tmp95) { /* tmp94 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp96 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp92) ; tmp97 = atspre_add_int_int (arg2, 1) ; arg0 = arg0 ; arg1 = tmp93 ; arg2 = tmp97 ; goto __ats_lab_aux_31 ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp91) */ ; } /* end of [aux_31] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 7080(line=251, offs=7) -- 7510(line=266, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst: /* tmp90 = */ aux_31 (arg0, arg1, 0) ; return /* (tmp90) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 7565(line=268, offs=26) -- 7607(line=268, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2conlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; // ATSlocal_void (tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2conlst: tmp99 = atspre_stdout_get () ; tmp100 = ats_selsin_mac(tmp99, atslab_1) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst (tmp100, arg0) ; /* tmp98 = */ atspre_stdout_view_set () ; return /* (tmp98) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_d2conlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_dcon.dats: 7633(line=269, offs=26) -- 7675(line=269, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2conlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; // ATSlocal_void (tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2conlst: tmp103 = atspre_stderr_get () ; tmp104 = ats_selsin_mac(tmp103, atslab_1) ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2conlst (tmp104, arg0) ; /* tmp102 = */ atspre_stderr_view_set () ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2conlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_dcon_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_dcon_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symtbl_dats.c0000664000175000017500000004255512223166160021444 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_ptr ; ats_int_type atslab_size ; ats_int_type atslab_nitm ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imul) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_imax) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_uimod) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atspre_uint_of_ulint) (ats_ulint_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ulint_type, atspre_string_hash_33) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ats_array_ptr_alloc_tsz) (ats_int_type, ats_size_type) ; ATSextern_fun(ats_void_type, ats_array_ptr_free) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__sasp__symtbl_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_2 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type array_ptr_initialize_elt_01688_ats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type symtbl_search_probe_3 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type symtbl_insert_probe_5 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type symtbl_resize_move_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3) ; static ats_void_type symtbl_resize_7 (ats_ptr_type arg0) ; static ats_void_type symtbl_resize_if_8 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 1730(line=49, offs=7) -- 2141(line=60, offs=8) */ ATSstaticdec() ats_void_type aux_2 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_int_type, tmp12) ; __ats_lab_aux_2: tmp10 = atspre_igt (arg1, 0) ; if (tmp10) { ats_ptrget_mac(ats_ptr_type, arg0) = arg2 ; tmp11 = atspre_padd_size (arg0, sizeof(ats_ptr_type)) ; tmp12 = atspre_isub (arg1, 1) ; arg0 = tmp11 ; arg1 = tmp12 ; arg2 = arg2 ; goto __ats_lab_aux_2 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp9) */ ; } /* end of [aux_2] */ /* // /home/hwxi/research/Anairiats/src/ats_array.dats: 1705(line=48, offs=26) -- 2267(line=66, offs=4) */ ATSstaticdec() ats_void_type array_ptr_initialize_elt_01688_ats_ptr_type (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp8) ; __ats_lab_array_ptr_initialize_elt_01688_ats_ptr_type: /* tmp8 = */ aux_2 (arg0, arg1, arg2) ; return /* (tmp8) */ ; } /* end of [array_ptr_initialize_elt_01688_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 2160(line=73, offs=13) -- 3004(line=104, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_make (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_make: tmp1 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp2 = ats_selsin_mac(tmp1, atslab_2) ; tmp3 = atspre_imax (arg0, 1) ; tmp4 = ats_array_ptr_alloc_tsz (tmp3, sizeof(ats_ptr_type)) ; tmp5 = ats_selsin_mac(tmp4, atslab_2) ; /* ats_ptr_type tmp6 ; */ tmp6 = (ats_sum_ptr_type)0 ; /* tmp7 = */ array_ptr_initialize_elt_01688_ats_ptr_type (tmp5, tmp3, tmp6) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp2), atslab_ptr) = tmp5 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp2), atslab_size) = tmp3 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp2), atslab_nitm) = 0 ; /* tmp13 = */ atspre_vbox_make_view_ptr (tmp2) ; /* tmp14 = ats_selsin_mac(tmp13, atslab_1) */ ; tmp0 = tmp2 ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_make] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 3052(line=107, offs=5) -- 3648(line=126, offs=4) */ ATSstaticdec() ats_ptr_type symtbl_search_probe_3 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_bool_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; ATSlocal (ats_int_type, tmp21) ; ATSlocal (ats_bool_type, tmp22) ; __ats_lab_symtbl_search_probe_3: tmp16 = ats_caselptrind_mac(ats_ptr_type, arg0, [arg2]) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp16 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_0) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp17) ; tmp18 = atspre_eq_string_string (tmp19, arg3) ; if (tmp18) { tmp15 = tmp16 ; } else { tmp20 = atspre_iadd (arg2, 1) ; tmp22 = atspre_ilt (tmp20, arg1) ; if (tmp22) { tmp21 = tmp20 ; } else { tmp21 = 0 ; } /* end of [if] */ arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp21 ; arg3 = arg3 ; goto __ats_lab_symtbl_search_probe_3 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp16 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp15 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp15) ; } /* end of [symtbl_search_probe_3] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 3706(line=128, offs=25) -- 4125(line=140, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_search (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ulint_type, tmp24) ; ATSlocal (ats_uint_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_int_type, tmp27) ; ATSlocal (ats_int_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_int_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_search: tmp24 = atspre_string_hash_33 (arg1) ; tmp25 = atspre_uint_of_ulint (tmp24) ; tmp26 = ats_selsin_mac(arg0, atslab_1) ; tmp28 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp26), atslab_size) ; tmp27 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp25), tmp28) ; tmp29 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp26), atslab_ptr) ; tmp30 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp26), atslab_size) ; tmp23 = symtbl_search_probe_3 (tmp29, tmp30, tmp27, arg1) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_search] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 4178(line=144, offs=5) -- 4619(line=158, offs=4) */ ATSstaticdec() ats_void_type symtbl_insert_probe_5 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_int_type, tmp33) ; ATSlocal (ats_int_type, tmp34) ; ATSlocal (ats_bool_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_symtbl_insert_probe_5: tmp32 = ats_caselptrind_mac(ats_ptr_type, arg0, [arg2]) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp32 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp33 = atspre_iadd (arg2, 1) ; tmp35 = atspre_ilt (tmp33, arg1) ; if (tmp35) { tmp34 = tmp33 ; } else { tmp34 = 0 ; } /* end of [if] */ arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp34 ; arg3 = arg3 ; goto __ats_lab_symtbl_insert_probe_5 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp32 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp36 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp36, atslab_0, arg3) ; ats_caselptrind_mac(ats_ptr_type, arg0, [arg2]) = tmp36 ; break ; } while (0) ; return /* (tmp31) */ ; } /* end of [symtbl_insert_probe_5] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 4678(line=162, offs=5) -- 5423(line=184, offs=4) */ ATSstaticdec() ats_void_type symtbl_resize_move_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_bool_type, tmp38) ; // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_int_type, tmp42) ; ATSlocal (ats_ulint_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_uint_type, tmp45) ; ATSlocal (ats_int_type, tmp46) ; ATSlocal (ats_int_type, tmp47) ; __ats_lab_symtbl_resize_move_6: tmp38 = atspre_ilt (arg3, arg2) ; if (tmp38) { tmp40 = ats_caselptrind_mac(ats_ptr_type, arg0, [arg3]) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp40 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_1, tmp40, atslab_0) ; tmp42 = atspre_iadd (arg2, arg2) ; tmp44 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp41) ; tmp43 = atspre_string_hash_33 (tmp44) ; tmp45 = atspre_uint_of_ulint (tmp43) ; tmp46 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp45), tmp42) ; /* tmp39 = */ symtbl_insert_probe_5 (arg1, tmp42, tmp46, tmp41) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp40 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; tmp47 = atspre_iadd (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp47 ; goto __ats_lab_symtbl_resize_move_6 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp37) */ ; } /* end of [symtbl_resize_move_6] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 5463(line=186, offs=5) -- 6140(line=206, offs=4) */ ATSstaticdec() ats_void_type symtbl_resize_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_int_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; // ATSlocal_void (tmp58) ; ATSlocal (ats_int_type, tmp59) ; __ats_lab_symtbl_resize_7: tmp49 = ats_selsin_mac(arg0, atslab_1) ; tmp50 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_ptr) ; tmp51 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_size) ; tmp52 = atspre_iadd (tmp51, tmp51) ; tmp53 = ats_array_ptr_alloc_tsz (tmp52, sizeof(ats_ptr_type)) ; tmp54 = ats_selsin_mac(tmp53, atslab_2) ; /* ats_ptr_type tmp55 ; */ tmp55 = (ats_sum_ptr_type)0 ; /* tmp56 = */ array_ptr_initialize_elt_01688_ats_ptr_type (tmp54, tmp52, tmp55) ; /* tmp57 = */ symtbl_resize_move_6 (tmp50, tmp54, tmp51, 0) ; /* tmp58 = */ ats_array_ptr_free (tmp50) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_ptr) = tmp54 ; tmp59 = atspre_iadd (tmp51, tmp51) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_size) = tmp59 ; return /* (tmp48) */ ; } /* end of [symtbl_resize_7] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 6172(line=208, offs=5) -- 6429(line=216, offs=4) */ ATSstaticdec() ats_void_type symtbl_resize_if_8 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_int_type, tmp64) ; ATSlocal (ats_bool_type, tmp65) ; ATSlocal (ats_int_type, tmp66) ; __ats_lab_symtbl_resize_if_8: tmp61 = ats_selsin_mac(arg0, atslab_1) ; tmp62 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp61), atslab_nitm) ; tmp63 = ats_selsin_mac(arg0, atslab_1) ; tmp64 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp63), atslab_size) ; tmp66 = atspre_imul (2, tmp62) ; tmp65 = atspre_igt (tmp66, tmp64) ; if (tmp65) { /* tmp60 = */ symtbl_resize_7 (arg0) ; } else { /* empty */ } /* end of [if] */ return /* (tmp60) */ ; } /* end of [symtbl_resize_if_8] */ /* // /home/hwxi/research/Anairiats/src/ats_symtbl.dats: 6505(line=221, offs=15) -- 6980(line=239, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_insert (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; ATSlocal (ats_ulint_type, tmp69) ; ATSlocal (ats_uint_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; // ATSlocal_void (tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_int_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_int_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_insert: /* tmp68 = */ symtbl_resize_if_8 (arg0) ; tmp69 = atspre_string_hash_33 (arg1) ; tmp70 = atspre_uint_of_ulint (tmp69) ; tmp71 = ats_selsin_mac(arg0, atslab_1) ; tmp73 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp71), atslab_size) ; tmp72 = atspre_uimod (ats_castfn_mac(ats_uint_type, tmp70), tmp73) ; tmp75 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp71), atslab_ptr) ; tmp76 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp71), atslab_size) ; /* tmp74 = */ symtbl_insert_probe_5 (tmp75, tmp76, tmp72, arg2) ; tmp78 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp71), atslab_nitm) ; tmp77 = atspre_iadd (1, tmp78) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp71), atslab_nitm) = tmp77 ; return /* (tmp67) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_insert] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_array_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_array_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symtbl_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_label_dats.c0000664000175000017500000004556712223166160021217 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_3 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABint_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABsym_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_compare_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_label_2esats__sasp__label_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABint_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABsym_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 1785(line=54, offs=26) -- 1797(line=54, offs=38) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int: tmp0 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp0)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp0, atslab_0, arg0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 1826(line=55, offs=29) -- 1858(line=55, offs=61) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_string: tmp2 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg0) ; tmp1 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp1)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp1, atslab_0, tmp2) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_string] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 1885(line=56, offs=26) -- 1897(line=56, offs=38) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_sym: tmp3 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp3)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp3, atslab_0, arg0) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 1944(line=60, offs=25) -- 2011(line=61, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_sym: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp4 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp4, atslab_0, tmp5) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp4 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2064(line=64, offs=25) -- 2131(line=65, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_int: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp6 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp6, atslab_0, tmp7) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp6 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp6) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_get_int] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2205(line=70, offs=26) -- 2244(line=70, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lt_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lt_label_label: tmp9 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (arg0, arg1) ; tmp8 = atspre_ilt (tmp9, 0) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lt_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2271(line=71, offs=27) -- 2311(line=71, offs=67) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lte_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lte_label_label: tmp11 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (arg0, arg1) ; tmp10 = atspre_ilte (tmp11, 0) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__lte_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2337(line=72, offs=26) -- 2376(line=72, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gt_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_int_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gt_label_label: tmp13 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (arg0, arg1) ; tmp12 = atspre_igt (tmp13, 0) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gt_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2403(line=73, offs=27) -- 2443(line=73, offs=67) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gte_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp14) ; ATSlocal (ats_int_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gte_label_label: tmp15 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (arg0, arg1) ; tmp14 = atspre_igte (tmp15, 0) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__gte_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2491(line=78, offs=16) -- 2625(line=82, offs=20) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_int_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_6_1 ; } __ats_lab_4_2: tmp17 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp16 = atspre_eq_int_int (tmp17, tmp18) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_6_1 ; } __ats_lab_5_2: tmp19 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp20 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp19, tmp20) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: __ats_lab_6_2: tmp16 = ats_false_bool ; break ; } while (0) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2680(line=86, offs=17) -- 2815(line=90, offs=19) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__neq_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; ATSlocal (ats_int_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__neq_label_label: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_9_1 ; } __ats_lab_7_2: tmp22 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp21 = atspre_neq_int_int (tmp22, tmp23) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_9_1 ; } __ats_lab_8_2: tmp24 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol (tmp24, tmp25) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: __ats_lab_9_2: tmp21 = ats_true_bool ; break ; } while (0) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__neq_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 2896(line=96, offs=21) -- 3090(line=101, offs=31) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_int_type, tmp27) ; ATSlocal (ats_int_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_12_1 ; } __ats_lab_10_2: tmp27 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp26 = atspre_compare_int_int (tmp27, tmp28) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_12_0 ; } __ats_lab_11_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_13_1 ; } __ats_lab_11_2: tmp29 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp30 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol (tmp29, tmp30) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_12_2: tmp26 = -1 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_13_2: tmp26 = 1 ; break ; } while (0) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__compare_label_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 3168(line=107, offs=14) -- 3296(line=111, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_int_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp31 = */ atspre_fprint_int (arg0, tmp32) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp33) ; break ; } while (0) ; return /* (tmp31) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 3345(line=113, offs=23) -- 3382(line=113, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__print_label (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__print_label: tmp35 = atspre_stdout_get () ; tmp36 = ats_selsin_mac(tmp35, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (tmp36, arg0) ; /* tmp34 = */ atspre_stdout_view_set () ; return /* (tmp34) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__print_label] */ /* // /home/hwxi/research/Anairiats/src/ats_label.dats: 3405(line=114, offs=23) -- 3442(line=114, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label: tmp39 = atspre_stderr_get () ; tmp40 = ats_selsin_mac(tmp39, atslab_1) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (tmp40, arg0) ; /* tmp38 = */ atspre_stderr_view_set () ; return /* (tmp38) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_label_2esats__prerr_label] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_label_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_label_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_label_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABint_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_label_2edats__LABsym_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_label_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_label_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_label_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_error_sats.c0000664000175000017500000000315312223166160021271 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException) ; ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException) ; /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException.name = "ATS_2d0_2e2_2e11_2src_2ats_error_2esats__FatalErrorException" ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException.name = "ATS_2d0_2e2_2e11_2src_2ats_error_2esats__DeadCodeException" ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_error_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_print_dats.c0000664000175000017500000006233012223166160023421 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_c3str_loc ; ats_ptr_type atslab_c3str_kind ; ats_ptr_type atslab_c3str_node ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_h3ypo_loc ; ats_ptr_type atslab_h3ypo_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDpattern_match_exhaustiveness_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDloop_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPObind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOeqeq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRitmlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_ref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMdisj_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMhypo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsVar_5) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3item) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 1677(line=47, offs=15) -- 2805(line=80, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3item (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3item: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp1 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp2 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMcstr(")) ; /* tmp3 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str (arg0, tmp1) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMcstr_ref(...)")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMdisj(...)")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMhypo(")) ; /* tmp6 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo (arg0, tmp4) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMsvar(")) ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp7) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (((ats_sum_ptr_type)arg1)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst("S3ITEMsVar(")) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (arg0, tmp10) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (tmp10) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp14 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_1, tmp14, atslab_0) ; /* tmp16 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp13 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp15) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp14 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: break ; } while (0) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3item] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 2881(line=85, offs=18) -- 2950(line=86, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst: /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3item) ; return /* (tmp17) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3007(line=89, offs=27) -- 3050(line=89, offs=70) */ ATSglobaldec() ats_void_type atsopt_print_s3itemlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; __ats_lab_atsopt_print_s3itemlst: tmp19 = atspre_stdout_get () ; tmp20 = ats_selsin_mac(tmp19, atslab_1) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst (tmp20, arg0) ; /* tmp18 = */ atspre_stdout_view_set () ; return /* (tmp18) */ ; } /* end of [atsopt_print_s3itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3077(line=90, offs=27) -- 3120(line=90, offs=70) */ ATSglobaldec() ats_void_type atsopt_prerr_s3itemlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; // ATSlocal_void (tmp25) ; __ats_lab_atsopt_prerr_s3itemlst: tmp23 = atspre_stderr_get () ; tmp24 = ats_selsin_mac(tmp23, atslab_1) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst (tmp24, arg0) ; /* tmp22 = */ atspre_stderr_view_set () ; return /* (tmp22) */ ; } /* end of [atsopt_prerr_s3itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3173(line=95, offs=21) -- 3247(line=96, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst: /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst) ; return /* (tmp26) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3310(line=99, offs=30) -- 3358(line=99, offs=78) */ ATSglobaldec() ats_void_type atsopt_print_s3itemlstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; // ATSlocal_void (tmp30) ; __ats_lab_atsopt_print_s3itemlstlst: tmp28 = atspre_stdout_get () ; tmp29 = ats_selsin_mac(tmp28, atslab_1) ; /* tmp30 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst (tmp29, arg0) ; /* tmp27 = */ atspre_stdout_view_set () ; return /* (tmp27) */ ; } /* end of [atsopt_print_s3itemlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3388(line=100, offs=30) -- 3436(line=100, offs=78) */ ATSglobaldec() ats_void_type atsopt_prerr_s3itemlstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; // ATSlocal_void (tmp34) ; __ats_lab_atsopt_prerr_s3itemlstlst: tmp32 = atspre_stderr_get () ; tmp33 = ats_selsin_mac(tmp32, atslab_1) ; /* tmp34 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlstlst (tmp33, arg0) ; /* tmp31 = */ atspre_stderr_view_set () ; return /* (tmp31) */ ; } /* end of [atsopt_prerr_s3itemlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 3486(line=105, offs=18) -- 3950(line=117, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp35) ; ATSlocal (ats_int_type, tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("main")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("metric_nat")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("metric_dec")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_12_0 ; } __ats_lab_11_1: /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("pattern")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_13_0 ; } __ats_lab_12_1: /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("varfin")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)arg1)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp36 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; /* tmp37 = */ atspre_fprint_string (arg0, ATSstrcst("loop(")) ; /* tmp38 = */ atspre_fprint_int (arg0, tmp36) ; /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp35) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 4025(line=121, offs=24) -- 4552(line=139, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str: tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_c3str_node) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp40)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_0, tmp40, atslab_0) ; /* tmp42 = */ atspre_fprint_string (arg0, ATSstrcst("C3STRprop(")) ; tmp44 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_c3str_kind) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind (arg0, tmp44) ; /* tmp45 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp41) ; /* tmp39 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (((ats_sum_ptr_type)tmp40)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_0, tmp40, atslab_0) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("C3STRitmlst(")) ; tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_c3str_kind) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3strkind (arg0, tmp50) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_s3itemlst (arg0, tmp47) ; /* tmp39 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 4601(line=141, offs=23) -- 4638(line=141, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_c3str (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_c3str: tmp54 = atspre_stdout_get () ; tmp55 = ats_selsin_mac(tmp54, atslab_1) ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str (tmp55, arg0) ; /* tmp53 = */ atspre_stdout_view_set () ; return /* (tmp53) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_c3str] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 4661(line=142, offs=23) -- 4698(line=142, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_c3str (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_c3str: tmp58 = atspre_stderr_get () ; tmp59 = ats_selsin_mac(tmp58, atslab_1) ; /* tmp60 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_c3str (tmp59, arg0) ; /* tmp57 = */ atspre_stderr_view_set () ; return /* (tmp57) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_c3str] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 4744(line=146, offs=24) -- 5370(line=167, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo: tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_h3ypo_node) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp62)->tag != 0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_0, tmp62, atslab_0) ; /* tmp64 = */ atspre_fprint_string (arg0, ATSstrcst("H2YPOprop(")) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp63) ; /* tmp61 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp62)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_1) ; /* tmp68 = */ atspre_fprint_string (arg0, ATSstrcst("H2YPObind(")) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (arg0, tmp66) ; /* tmp70 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp67) ; /* tmp61 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (((ats_sum_ptr_type)tmp62)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp73 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_1) ; /* tmp74 = */ atspre_fprint_string (arg0, ATSstrcst("H2YPOeqeq(")) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp72) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp73) ; /* tmp61 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp61) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 5419(line=169, offs=23) -- 5456(line=169, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_h3ypo (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; // ATSlocal_void (tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_h3ypo: tmp79 = atspre_stdout_get () ; tmp80 = ats_selsin_mac(tmp79, atslab_1) ; /* tmp81 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo (tmp80, arg0) ; /* tmp78 = */ atspre_stdout_view_set () ; return /* (tmp78) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_h3ypo] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_print.dats: 5479(line=170, offs=23) -- 5516(line=170, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_h3ypo (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; // ATSlocal_void (tmp85) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_h3ypo: tmp83 = atspre_stderr_get () ; tmp84 = ats_selsin_mac(tmp83, atslab_1) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_h3ypo (tmp84, arg0) ; /* tmp82 = */ atspre_stderr_view_set () ; return /* (tmp82) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_h3ypo] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_intinf_sats.c0000664000175000017500000000202612223166160021425 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "ats_intinf.cats" /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_intinf_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symenv_dats.c0000664000175000017500000003473512223166160021454 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_map ; ats_ptr_type atslab_maplst ; ats_ptr_type atslab_savedlst ; ats_ptr_type atslab_pervasive ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make) () ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__sasp__symenv_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__sasp__symmap_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01805_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type ref_swap_01812_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 3207(line=123, offs=29) -- 3267(line=124, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make () { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01805_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_ref_make_elt_01805_ats_ptr_type: /* ats_ptr_type tmp4 ; */ tmp4 = arg0 ; tmp3 = atspre_ref_make_elt_tsz ((&tmp4), sizeof(ats_ptr_type)) ; return (tmp3) ; } /* end of [ref_make_elt_01805_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 4312(line=163, offs=19) -- 4489(line=168, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make: tmp5 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make () ; tmp2 = ref_make_elt_01805_ats_ptr_type (tmp5) ; tmp7 = (ats_sum_ptr_type)0 ; tmp6 = ref_make_elt_01805_ats_ptr_type (tmp7) ; tmp9 = (ats_sum_ptr_type)0 ; tmp8 = ref_make_elt_01805_ats_ptr_type (tmp9) ; tmp11 = (ats_sum_ptr_type)0 ; tmp10 = ref_make_elt_01805_ats_ptr_type (tmp11) ; tmp1 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_map, tmp2) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_maplst, tmp6) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_savedlst, tmp8) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_pervasive, tmp10) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_make] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 7176(line=269, offs=19) -- 7423(line=279, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push: tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp13 = atspre_ref_get_view_ptr (tmp14) ; tmp15 = ats_selsin_mac(tmp13, atslab_1) ; tmp16 = ats_ptrget_mac(ats_ptr_type, tmp15) ; tmp17 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make () ; ats_ptrget_mac(ats_ptr_type, tmp15) = tmp17 ; tmp19 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp18 = atspre_ref_get_view_ptr (tmp19) ; tmp20 = ats_selsin_mac(tmp18, atslab_1) ; tmp22 = ats_ptrget_mac(ats_ptr_type, tmp20) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_0, tmp16) ; ats_selptrset_mac(anairiats_sum_1, tmp21, atslab_1, tmp22) ; ats_ptrget_mac(ats_ptr_type, tmp20) = tmp21 ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_push] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 2132(line=68, offs=23) -- 2227(line=73, offs=4) */ ATSstaticdec() ats_void_type ref_swap_01812_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ref_swap_01812_ats_ptr_type: tmp28 = atspre_ref_get_view_ptr (arg0) ; tmp29 = ats_selsin_mac(tmp28, atslab_1) ; tmp30 = ats_ptrget_mac(ats_ptr_type, tmp29) ; ats_ptrget_mac(ats_ptr_type, tmp29) = ats_ptrget_mac(ats_ptr_type, arg1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp30 ; return /* (tmp27) */ ; } /* end of [ref_swap_01812_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 7483(line=285, offs=9) -- 7647(line=289, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_swap (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_swap: tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp24 = atspre_ref_get_view_ptr (tmp25) ; tmp26 = ats_selsin_mac(tmp24, atslab_1) ; /* tmp23 = */ ref_swap_01812_ats_ptr_type (arg1, tmp26) ; return /* (tmp23) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_swap] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 7722(line=294, offs=19) -- 8149(line=312, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (anairiats_rec_2, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save: tmp33 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp32 = atspre_ref_get_view_ptr (tmp33) ; tmp34 = ats_selsin_mac(tmp32, atslab_1) ; tmp35 = ats_ptrget_mac(ats_ptr_type, tmp34) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make () ; ats_ptrget_mac(ats_ptr_type, tmp34) = tmp36 ; tmp38 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_maplst) ; tmp37 = atspre_ref_get_view_ptr (tmp38) ; tmp39 = ats_selsin_mac(tmp37, atslab_1) ; tmp40 = ats_ptrget_mac(ats_ptr_type, tmp39) ; tmp41 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp39) = tmp41 ; tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_savedlst) ; tmp42 = atspre_ref_get_view_ptr (tmp43) ; tmp44 = ats_selsin_mac(tmp42, atslab_1) ; tmp46.atslab_0 = tmp35 ; tmp46.atslab_1 = tmp40 ; tmp47 = ats_ptrget_mac(ats_ptr_type, tmp44) ; tmp45 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp45, atslab_0, tmp46) ; ats_selptrset_mac(anairiats_sum_3, tmp45, atslab_1, tmp47) ; ats_ptrget_mac(ats_ptr_type, tmp44) = tmp45 ; return /* (tmp31) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_save] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9220(line=356, offs=16) -- 9348(line=362, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; tmp50 = atspre_ref_get_view_ptr (tmp49) ; tmp51 = ats_selsin_mac(tmp50, atslab_1) ; tmp52 = ats_ptrget_mac(ats_ptr_type, tmp51) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symmap_make () ; ats_ptrget_mac(ats_ptr_type, tmp51) = tmp53 ; tmp48 = tmp52 ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_top_get] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 9401(line=364, offs=29) -- 9416(line=364, offs=44) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_reftop_get (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_reftop_get: tmp54 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_map) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_reftop_get] */ /* // /home/hwxi/research/Anairiats/src/ats_symenv.dats: 10670(line=411, offs=22) -- 10807(line=416, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add: tmp57 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_pervasive) ; tmp56 = atspre_ref_get_view_ptr (tmp57) ; tmp58 = ats_selsin_mac(tmp56, atslab_1) ; tmp60 = ats_ptrget_mac(ats_ptr_type, tmp58) ; tmp59 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp59, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp59, atslab_1, tmp60) ; ats_ptrget_mac(ats_ptr_type, tmp58) = tmp59 ; return /* (tmp55) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__symenv_pervasive_add] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symenv_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_syntax_depgen_dats.c0000664000175000017500000014000412223166160022766 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_c0lau_loc ; ats_ptr_type atslab_c0lau_pat ; ats_int_type atslab_c0lau_seq ; ats_int_type atslab_c0lau_neg ; ats_ptr_type atslab_c0lau_body ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_v0aldec_loc ; ats_ptr_type atslab_v0aldec_pat ; ats_ptr_type atslab_v0aldec_def ; ats_ptr_type atslab_v0aldec_ann ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_f0undec_loc ; ats_ptr_type atslab_f0undec_sym ; ats_ptr_type atslab_f0undec_sym_loc ; ats_ptr_type atslab_f0undec_arg ; ats_ptr_type atslab_f0undec_eff ; ats_ptr_type atslab_f0undec_res ; ats_ptr_type atslab_f0undec_def ; ats_ptr_type atslab_f0undec_ann ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_v0ardec_loc ; ats_int_type atslab_v0ardec_knd ; ats_ptr_type atslab_v0ardec_sym ; ats_ptr_type atslab_v0ardec_sym_loc ; ats_ptr_type atslab_v0ardec_typ ; ats_ptr_type atslab_v0ardec_wth ; ats_ptr_type atslab_v0ardec_ini ; } anairiats_rec_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_9 ; typedef struct { ats_ptr_type atslab_d0exp_loc ; ats_ptr_type atslab_d0exp_node ; } anairiats_rec_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_d0ec_loc ; ats_ptr_type atslab_d0ec_node ; } anairiats_rec_16 ; typedef struct { ats_ptr_type atslab_i0mpdec_loc ; ats_ptr_type atslab_i0mpdec_qid ; ats_ptr_type atslab_i0mpdec_arg ; ats_ptr_type atslab_i0mpdec_res ; ats_ptr_type atslab_i0mpdec_def ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_guad0ec_loc ; ats_ptr_type atslab_guad0ec_node ; } anairiats_rec_18 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrpsz_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efoldat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efreeat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estruct_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_eq_size_size) (ats_size_type, ats_size_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_ssize1_int1) (ats_ssize_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_bool_type, atspre_test_file_exists) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_get) () ; ATSextern_fun(ats_ptr_type, atsopt_filename_merge) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_filename_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__fprint_target) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0ec) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp) (ats_ptr_type) ; ATSextern_fun(ats_ssize_type, atspre_string_index_of_char_from_right) (ats_ptr_type, ats_char_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01713_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type the_deplst_get_1 () ; static ats_void_type the_deplst_push_2 (ats_ptr_type arg0) ; static ats_void_type pr_4 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) ; static ats_void_type loop_6 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type depgen_d0explst_7 (ats_ptr_type arg0) ; static ats_void_type depgen_d0explstlst_8 (ats_ptr_type arg0) ; static ats_void_type depgen_d0expopt_9 (ats_ptr_type arg0) ; static ats_void_type depgen_labd0explst_10 (ats_ptr_type arg0) ; static ats_void_type depgen_c0lau_11 (ats_ptr_type arg0) ; static ats_void_type depgen_c0laulst_12 (ats_ptr_type arg0) ; static ats_void_type depgen_v0aldec_13 (ats_ptr_type arg0) ; static ats_void_type depgen_f0undec_14 (ats_ptr_type arg0) ; static ats_void_type depgen_v0ardec_15 (ats_ptr_type arg0) ; static ats_void_type depgen_guad0ec_node_16 (ats_ptr_type arg0) ; static ats_ptr_type loop_19 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type try_path_basename_18 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp3) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01713_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ref_make_elt_01713_ats_ptr_type: /* ats_ptr_type tmp2 ; */ tmp2 = arg0 ; tmp1 = atspre_ref_make_elt_tsz ((&tmp2), sizeof(ats_ptr_type)) ; return (tmp1) ; } /* end of [ref_make_elt_01713_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 2403(line=87, offs=5) -- 2557(line=100, offs=2) */ ATSstaticdec() ats_ptr_type the_deplst_get_1 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_the_deplst_get_1: tmp5 = atspre_ref_get_view_ptr (statmp0) ; tmp6 = ats_selsin_mac(tmp5, atslab_1) ; tmp7 = ats_ptrget_mac(ats_ptr_type, tmp6) ; tmp8 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp6) = tmp8 ; tmp4 = tmp7 ; return (tmp4) ; } /* end of [the_deplst_get_1] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 2590(line=102, offs=5) -- 2744(line=114, offs=2) */ ATSstaticdec() ats_void_type the_deplst_push_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_the_deplst_push_2: tmp10 = atspre_ref_get_view_ptr (statmp0) ; tmp11 = ats_selsin_mac(tmp10, atslab_1) ; tmp13 = ats_ptrget_mac(ats_ptr_type, tmp11) ; tmp12 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp12, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp12, atslab_1, tmp13) ; ats_ptrget_mac(ats_ptr_type, tmp11) = tmp12 ; return /* (tmp9) */ ; } /* end of [the_deplst_push_2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 3312(line=142, offs=11) -- 3648(line=151, offs=12) */ ATSstaticdec() ats_void_type pr_4 (ats_ref_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_size_type arg3) { /* local vardec */ // ATSlocal_void (tmp17) ; ATSlocal (ats_bool_type, tmp18) ; ATSlocal (ats_char_type, tmp19) ; ATSlocal (ats_bool_type, tmp20) ; // ATSlocal_void (tmp21) ; ATSlocal (ats_size_type, tmp22) ; __ats_lab_pr_4: tmp18 = atspre_string_isnot_atend (arg1, arg3) ; if (tmp18) { tmp20 = atspre_eq_size_size (arg3, arg2) ; if (tmp20) { tmp19 = '_' ; } else { tmp19 = atspre_string_get_char_at (arg1, arg3) ; } /* end of [if] */ /* tmp21 = */ atspre_fprint_char (arg0, tmp19) ; tmp22 = atspre_add_size1_int1 (arg3, 1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = tmp22 ; goto __ats_lab_pr_4 ; // tail call } else { /* empty */ } /* end of [if] */ return /* (tmp17) */ ; } /* end of [pr_4] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 3076(line=130, offs=1) -- 3892(line=162, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__fprint_target (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp14) ; ATSlocal (ats_ssize_type, tmp15) ; ATSlocal (ats_bool_type, tmp16) ; // ATSlocal_void (tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__fprint_target: tmp15 = atspre_string_index_of_char_from_right (ats_castfn_mac(ats_ptr_type, arg1), '.') ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: __ats_lab_0_1: tmp16 = atspre_gte_ssize1_int1 (tmp15, 0) ; if (!tmp16) { goto __ats_lab_1_1 ; } /* tmp23 = */ pr_4 (arg0, ats_castfn_mac(ats_ptr_type, arg1), ats_castfn_mac(ats_size_type, tmp15), 0) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst(".c")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: /* tmp14 = */ atspre_fprint_string (arg0, ats_castfn_mac(ats_ptr_type, arg1)) ; break ; } while (0) ; return /* (tmp14) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__fprint_target] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 4220(line=179, offs=7) -- 4472(line=190, offs=4) */ ATSstaticdec() ats_void_type loop_6 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; __ats_lab_loop_6: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp32 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; ATS_FREE(arg1) ; /* tmp33 = */ atspre_fprintf_exn (arg0, ATSstrcst(" %s"), tmp31) ; arg0 = arg0 ; arg1 = tmp32 ; goto __ats_lab_loop_6 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp30) */ ; } /* end of [loop_6] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 3969(line=168, offs=1) -- 4577(line=199, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp34) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen: /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (arg2) ; tmp26 = the_deplst_get_1 () ; tmp27 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse (tmp26) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__fprint_target (arg0, arg1) ; /* tmp29 = */ atspre_fprint_string (arg0, ATSstrcst(" :")) ; /* tmp34 = */ loop_6 (arg0, tmp27) ; /* tmp24 = */ atspre_fprint_newline (arg0) ; return /* (tmp24) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_depgen] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 4653(line=205, offs=5) -- 4740(line=207, offs=45) */ ATSstaticdec() ats_void_type depgen_d0explst_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp35) ; __ats_lab_depgen_d0explst_7: /* tmp35 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp) ; return /* (tmp35) */ ; } /* end of [depgen_d0explst_7] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 4774(line=210, offs=5) -- 4872(line=212, offs=49) */ ATSstaticdec() ats_void_type depgen_d0explstlst_8 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp36) ; __ats_lab_depgen_d0explstlst_8: /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &depgen_d0explst_7) ; return /* (tmp36) */ ; } /* end of [depgen_d0explstlst_8] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 4909(line=215, offs=5) -- 5010(line=217, offs=51) */ ATSstaticdec() ats_void_type depgen_d0expopt_9 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_depgen_d0expopt_9: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp38) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; return /* (tmp37) */ ; } /* end of [depgen_d0expopt_9] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5044(line=220, offs=5) -- 5236(line=225, offs=6) */ ATSstaticdec() ats_void_type depgen_labd0explst_10 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; __ats_lab_depgen_labd0explst_10: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp41 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp40) ; arg0 = tmp41 ; goto __ats_lab_depgen_labd0explst_10 ; // tail call break ; } while (0) ; return /* (tmp39) */ ; } /* end of [depgen_labd0explst_10] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5322(line=230, offs=5) -- 5388(line=231, offs=41) */ ATSstaticdec() ats_void_type depgen_c0lau_11 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_depgen_c0lau_11: tmp44 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_c0lau_body) ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp44) ; return /* (tmp43) */ ; } /* end of [depgen_c0lau_11] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5393(line=232, offs=5) -- 5479(line=233, offs=54) */ ATSstaticdec() ats_void_type depgen_c0laulst_12 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp45) ; __ats_lab_depgen_c0laulst_12: /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &depgen_c0lau_11) ; return /* (tmp45) */ ; } /* end of [depgen_c0laulst_12] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5534(line=238, offs=5) -- 5598(line=239, offs=50) */ ATSstaticdec() ats_void_type depgen_v0aldec_13 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_depgen_v0aldec_13: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_v0aldec_def) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp47) ; return /* (tmp46) */ ; } /* end of [depgen_v0aldec_13] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5631(line=242, offs=5) -- 5695(line=243, offs=50) */ ATSstaticdec() ats_void_type depgen_f0undec_14 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_depgen_f0undec_14: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_f0undec_def) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp49) ; return /* (tmp48) */ ; } /* end of [depgen_f0undec_14] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5728(line=246, offs=5) -- 5795(line=247, offs=53) */ ATSstaticdec() ats_void_type depgen_v0ardec_15 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_depgen_v0ardec_15: tmp51 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_v0ardec_ini) ; /* tmp50 = */ depgen_d0expopt_9 (tmp51) ; return /* (tmp50) */ ; } /* end of [depgen_v0ardec_15] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 5828(line=250, offs=5) -- 6160(line=259, offs=6) */ ATSstaticdec() ats_void_type depgen_guad0ec_node_16 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; // ATSlocal_void (tmp59) ; __ats_lab_depgen_guad0ec_node_16: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_1) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp53) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp55 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_2) ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp54) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp55) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp58 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; /* tmp59 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp57) ; arg0 = tmp58 ; goto __ats_lab_depgen_guad0ec_node_16 ; // tail call break ; } while (0) ; return /* (tmp52) */ ; } /* end of [depgen_guad0ec_node_16] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 6259(line=265, offs=14) -- 9302(line=375, offs=12) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; // ATSlocal_void (tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; // ATSlocal_void (tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; // ATSlocal_void (tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; // ATSlocal_void (tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp: tmp61 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg0), atslab_d0exp_node) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp61)->tag != 0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_0) ; arg0 = tmp62 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp61)->tag != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_0) ; tmp64 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp63) ; arg0 = tmp64 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp61)->tag != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_1) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_2) ; /* tmp68 = */ depgen_d0expopt_9 (tmp66) ; /* tmp60 = */ depgen_d0explst_7 (tmp67) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp61)->tag != 3) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; arg0 = tmp69 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp61)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_2) ; /* tmp60 = */ depgen_d0explstlst_8 (tmp70) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp61)->tag != 5) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_1) ; tmp72 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_2) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp71) ; /* tmp60 = */ depgen_c0laulst_12 (tmp72) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp61)->tag != 14) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_2) ; arg0 = tmp74 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp61)->tag != 16) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_11, tmp61, atslab_5) ; arg0 = tmp75 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp61)->tag != 19) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp76 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; /* tmp60 = */ depgen_d0explst_7 (tmp76) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp61)->tag != 20) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_11, tmp61, atslab_2) ; tmp78 = ats_caselptrlab_mac(anairiats_sum_11, tmp61, atslab_3) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_11, tmp61, atslab_4) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_11, tmp61, atslab_5) ; /* tmp81 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp77) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp78) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp79) ; arg0 = tmp80 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp61)->tag != 21) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; /* tmp60 = */ depgen_d0explst_7 (tmp84) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp61)->tag != 24) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_1) ; tmp86 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_2) ; tmp87 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_3) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp85) ; /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp86) ; /* tmp60 = */ depgen_d0expopt_9 (tmp87) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp61)->tag != 27) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_13, tmp61, atslab_4) ; arg0 = tmp90 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp61)->tag != 28) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_0) ; tmp92 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp91) ; arg0 = tmp92 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp61)->tag != 29) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; /* tmp60 = */ depgen_d0explst_7 (tmp94) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp61)->tag != 30) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_0) ; tmp96 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; /* tmp97 = */ depgen_d0explst_7 (tmp95) ; /* tmp60 = */ depgen_d0explst_7 (tmp96) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp61)->tag != 32) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_14, tmp61, atslab_2) ; arg0 = tmp98 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp61)->tag != 33) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp99 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; arg0 = tmp99 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp61)->tag != 37) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; arg0 = tmp100 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp61)->tag != 38) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_15, tmp61, atslab_1) ; /* tmp60 = */ depgen_labd0explst_10 (tmp101) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp61)->tag != 41) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_15, tmp61, atslab_1) ; /* tmp60 = */ depgen_d0explstlst_8 (tmp102) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp61)->tag != 42) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; /* tmp60 = */ depgen_d0explst_7 (tmp103) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp61)->tag != 45) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp104 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_2) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_3) ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp104) ; arg0 = tmp105 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp61)->tag != 47) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_12, tmp61, atslab_0) ; /* tmp60 = */ depgen_labd0explst_10 (tmp107) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp61)->tag != 50) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_1) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_8, tmp61, atslab_2) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp108) ; /* tmp60 = */ depgen_c0laulst_12 (tmp109) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp61)->tag != 51) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_15, tmp61, atslab_1) ; /* tmp60 = */ depgen_d0explst_7 (tmp111) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp61)->tag != 52) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_14, tmp61, atslab_1) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_14, tmp61, atslab_2) ; /* tmp114 = */ depgen_d0explst_7 (tmp112) ; /* tmp60 = */ depgen_d0explst_7 (tmp113) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp61)->tag != 53) { goto __ats_lab_39_0 ; } __ats_lab_38_1: break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp61)->tag != 54) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_0) ; tmp116 = ats_caselptrlab_mac(anairiats_sum_7, tmp61, atslab_1) ; /* tmp117 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp115) ; /* tmp60 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp116) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp61)->tag != 55) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_2) ; tmp119 = ats_caselptrlab_mac(anairiats_sum_9, tmp61, atslab_3) ; /* tmp120 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp118) ; arg0 = tmp119 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: break ; } while (0) ; return /* (tmp60) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 9488(line=386, offs=5) -- 9925(line=403, offs=30) */ ATSstaticdec() ats_ptr_type loop_19 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_bool_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_loop_19: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp123 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp124 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp125 = atsopt_filename_append (tmp123, arg1) ; tmp126 = atspre_test_file_exists (tmp125) ; if (tmp126) { tmp127 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize (tmp125) ; tmp122 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp122, atslab_0, tmp127) ; } else { arg0 = tmp124 ; arg1 = arg1 ; goto __ats_lab_loop_19 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: tmp122 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp122) ; } /* end of [loop_19] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 9354(line=380, offs=5) -- 10333(line=421, offs=4) */ ATSstaticdec() ats_ptr_type try_path_basename_18 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_bool_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_try_path_basename_18: tmp128 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp129 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_part (tmp128) ; tmp130 = atsopt_filename_merge (tmp129, arg0) ; tmp131 = atspre_test_file_exists (tmp130) ; if (tmp131) { tmp132 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__path_normalize (tmp130) ; tmp121 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp121, atslab_0, tmp132) ; } else { tmp133 = ATS_2d0_2e2_2e11_2src_2ats_global_2esats__the_IATSdirlst_get () ; tmp121 = loop_19 (tmp133, arg0) ; } /* end of [if] */ return (tmp121) ; } /* end of [try_path_basename_18] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 10408(line=426, offs=13) -- 12311(line=506, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0ec (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; // ATSlocal_void (tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; // ATSlocal_void (tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; // ATSlocal_void (tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; // ATSlocal_void (tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0ec: tmp135 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg0), atslab_d0ec_node) ; do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp135)->tag != 2) { goto __ats_lab_47_0 ; } __ats_lab_44_1: tmp136 = ats_caselptrlab_mac(anairiats_sum_15, tmp135, atslab_1) ; tmp137 = try_path_basename_18 (tmp136) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp137 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp138 = ats_caselptrlab_mac(anairiats_sum_1, tmp137, atslab_0) ; ATS_FREE(tmp137) ; /* tmp134 = */ the_deplst_push_2 (tmp138) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (tmp137 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: break ; } while (0) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp135)->tag != 22) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_8, tmp135, atslab_1) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_8, tmp135, atslab_2) ; /* tmp141 = */ depgen_v0aldec_13 (tmp139) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp140, &depgen_v0aldec_13) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp135)->tag != 24) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_0) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; /* tmp144 = */ depgen_v0aldec_13 (tmp142) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp143, &depgen_v0aldec_13) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp135)->tag != 25) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp145 = ats_caselptrlab_mac(anairiats_sum_9, tmp135, atslab_2) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_9, tmp135, atslab_3) ; /* tmp147 = */ depgen_f0undec_14 (tmp145) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp146, &depgen_f0undec_14) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp135)->tag != 26) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_0) ; tmp149 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; /* tmp150 = */ depgen_v0ardec_15 (tmp148) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (tmp149, &depgen_v0ardec_15) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp135)->tag != 28) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp151 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, tmp151), atslab_i0mpdec_def) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0exp (tmp152) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp135)->tag != 30) { goto __ats_lab_55_0 ; } __ats_lab_52_1: tmp153 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; tmp154 = try_path_basename_18 (tmp153) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (tmp154 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_1, tmp154, atslab_0) ; ATS_FREE(tmp154) ; /* tmp134 = */ the_deplst_push_2 (tmp155) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (tmp154 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: break ; } while (0) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp135)->tag != 31) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_0) ; tmp157 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; /* tmp158 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp156) ; /* tmp134 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (tmp157) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp135)->tag != 32) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_7, tmp135, atslab_1) ; tmp160 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp159), atslab_guad0ec_node) ; /* tmp134 = */ depgen_guad0ec_node_16 (tmp160) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: break ; } while (0) ; return /* (tmp134) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0ec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_depgen.dats: 12383(line=511, offs=16) -- 12429(line=511, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst: /* tmp161 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_fun (arg0, &ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0ec) ; return /* (tmp161) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__depgen_d0eclst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_parser_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_comarg_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_depgen_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)0 ; statmp0 = ref_make_elt_01713_ats_ptr_type (statmp3) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_syntax_depgen_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_intinf_dats.c0000664000175000017500000002607312223166160021416 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" /* external codes at top */ #include "ats_intinf.cats" /* only needed for [ATS/Geizella] */ ats_void_type atslib_mpz_out_str_exn ( ats_ptr_type file , ats_int_type base // 2 <= base <= 36 , const ats_mpz_ptr_type x ) { #ifdef HAVE_GMP_H size_t n ; n = mpz_out_str((FILE*)file, base, (mpz_ptr)x) ; if (n == 0) { ats_exit_errmsg (1, "exit(ATS): [mpz_out_str] failed.\n") ; } // end of [if] #else // HAVE_GMP_H ats_llint_type i ; int r ; char c ; i = *(mpz_ptr)x ; if (i == 0) fputc ('0', (FILE*)file) ; if (i < 0) { fputc ('-', (FILE*)file) ; i = -i ; } while (i > 0) { r = i % base ; i = i / base ; c = (r < 10 ? '0' + r : 'a' + (r - 10)) ; fputc (c, (FILE*)file) ; } // end of [while] #endif // HAVE_GMP_H return ; } // end of [atslib_mpz_out_str_exn] /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atslib_fprint_mpz) (ats_ref_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_intinf_set_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_intinf_set_stringsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_intinf_initialize) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__sasp__intinf_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ // ATSstatic_void (statmp22) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 2543(line=87, offs=17) -- 2744(line=93, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; // ATSlocal_void (tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int: tmp1 = atspre_ptr_alloc_tsz (sizeof(ats_mpz_viewt0ype)) ; tmp2 = ats_selsin_mac(tmp1, atslab_2) ; /* tmp3 = */ atslib_mpz_init_set_int (tmp2, arg0) ; tmp0 = atspre_ref_make_view_ptr (tmp2) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int] */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 2907(line=100, offs=20) -- 3111(line=106, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string: tmp5 = atspre_ptr_alloc_tsz (sizeof(ats_mpz_viewt0ype)) ; tmp6 = ats_selsin_mac(tmp5, atslab_2) ; /* tmp7 = */ atsopt_intinf_set_string (tmp6, arg0) ; tmp4 = atspre_ref_make_view_ptr (tmp6) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_string] */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 3283(line=113, offs=22) -- 3489(line=119, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_stringsp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_stringsp: tmp9 = atspre_ptr_alloc_tsz (sizeof(ats_mpz_viewt0ype)) ; tmp10 = ats_selsin_mac(tmp9, atslab_2) ; /* tmp11 = */ atsopt_intinf_set_stringsp (tmp10, arg0) ; tmp8 = atspre_ref_make_view_ptr (tmp10) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_stringsp] */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 3569(line=124, offs=15) -- 3683(line=128, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf: tmp13 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, arg1), atslab_1) ; /* tmp12 = */ atslib_fprint_mpz (arg0, tmp13) ; return /* (tmp12) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf] */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 3734(line=130, offs=24) -- 3768(line=130, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__print_intinf (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__print_intinf: tmp15 = atspre_stdout_get () ; tmp16 = ats_selsin_mac(tmp15, atslab_1) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (tmp16, arg0) ; /* tmp14 = */ atspre_stdout_view_set () ; return /* (tmp14) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__print_intinf] */ /* // /home/hwxi/research/Anairiats/src/ats_intinf.dats: 3792(line=131, offs=24) -- 3826(line=131, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__prerr_intinf (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__prerr_intinf: tmp19 = atspre_stderr_get () ; tmp20 = ats_selsin_mac(tmp19, atslab_1) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (tmp20, arg0) ; /* tmp18 = */ atspre_stderr_view_set () ; return /* (tmp18) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__prerr_intinf] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libc_sats_gmp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ /* statmp22 = */ atsopt_intinf_initialize () ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_intinf_set_string ( ats_mpz_ptr_type x, ats_ptr_type s0 ) { char *s, *si, c0, c1 ; int i, base, err ; s = s0 ; c0 = s[0] ; if (c0 == '\000') { atspre_exit_prerrf(1, "exit(ATS): atsopt_intinf_set_str(%s)\n", s) ; } // end of [if] i = 0 ; base = 10 ; if (c0 == '~') { i = 1 ; c1 = s[1] ; } else { c1 = c0 ; } if (c1 == '0') { base = 8 ; i += 1 ; c1 = s[i] ; if (c1 == '\000') { mpz_init_set_si ((mpz_ptr)x, 0); return ; } if (c1 == 'x' || c1 == 'X') { base = 16 ; i += 1 ; } } if (c0 == '~') { i -= 1 ; si = s + i ; c1 = *si ; *si = '-' ; err = mpz_init_set_str((mpz_ptr)x, si, base) ; *si = c1 ; } else { si = s + i ; err = mpz_init_set_str((mpz_ptr)x, si, base) ; } // end of [if] if (err < 0) { atspre_exit_prerrf(1, "exit(ATS): mpz_init_set_str(%s)\n", s) ; } // end of [if] // mpz_out_str(stdout, 10, (mpz_ptr)x) ; fprintf (stdout, "\n") ; return ; } /* end of [atsopt_intinf_set_string] */ /* ****** ****** */ ats_void_type atsopt_intinf_set_stringsp ( ats_mpz_ptr_type x, ats_ptr_type s0 ) { char c, *s ; s = s0 ; while (c = *s) { if (strchr ("lLuU", c)) break ; else ++s ; } // end of [while] if (c) { *s = '\000' ; atsopt_intinf_set_string (x, s0) ; *s = c ; } else { atsopt_intinf_set_string (x, s0) ; } // end of [if] return ; } /* end of [atsopt_intinf_set_stringsp] */ /* ****** ****** */ // // This is necessary to prevent memory leak // static void* atsopt_intinf_malloc (size_t sz) { return ATS_MALLOC (sz) ; } // end of [atsopt_intinf_malloc] static void atsopt_intinf_free (void* ptr, size_t sz) { ATS_FREE (ptr) ; return ; } // end of [atsopt_intinf_free] static void* atsopt_intinf_realloc ( void* ptr, size_t sz_old, size_t sz_new ) { return ATS_REALLOC (ptr, sz_new) ; } // end of [atsopt_intinf_realloc] ats_void_type atsopt_intinf_initialize (/*argumentless*/) { mp_set_memory_functions ( &atsopt_intinf_malloc, &atsopt_intinf_realloc, &atsopt_intinf_free ) ; // end of [mp_set_memory_functions] return ; } // end of [atsopt_intinf_initialize] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_intinf_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_namespace_dats.c0000664000175000017500000004521312223166160022060 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_1 ; typedef struct { anairiats_rec_1 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type ref_make_elt_01807_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_ptr_type auxlst_4 (ats_clo_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxlstlst_5 (ats_clo_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pop_err_7 () ; static ats_void_type err_11 () ; static ats_void_type err_13 () ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp5) ; ATSstatic (ats_ptr_type, statmp6) ; ATSstatic (ats_ptr_type, statmp7) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_01807_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ref_make_elt_01807_ats_ptr_type: /* ats_ptr_type tmp2 ; */ tmp2 = arg0 ; tmp1 = atspre_ref_make_elt_tsz ((&tmp2), sizeof(ats_ptr_type)) ; return (tmp1) ; } /* end of [ref_make_elt_01807_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 2244(line=71, offs=4) -- 2302(line=71, offs=62) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp8) ; __ats_lab_prerr_interror_1: /* tmp8 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_namespace)")) ; return /* (tmp8) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 2353(line=76, offs=19) -- 2418(line=78, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_add: tmp11 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp10 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp10, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp10, atslab_1, tmp11) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp10 ; return /* (tmp9) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_add] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 2525(line=85, offs=7) -- 2773(line=90, offs=32) */ ATSstaticdec() ats_ptr_type auxlst_4 (ats_clo_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; __ats_lab_auxlst_4: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_0_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp15 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp16 = ((ats_ptr_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg0))) (arg0, tmp14) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp16 != (ats_sum_ptr_type)0) { goto __ats_lab_2_0 ; } __ats_lab_1_1: arg0 = arg0 ; arg1 = tmp15 ; goto __ats_lab_auxlst_4 ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp13 = tmp16 ; break ; } while (0) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp13 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp13) ; } /* end of [auxlst_4] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 2825(line=93, offs=7) -- 3095(line=98, offs=32) */ ATSstaticdec() ats_ptr_type auxlstlst_5 (ats_clo_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_auxlstlst_5: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_4_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp19 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp20 = auxlst_4 (arg0, tmp18) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (tmp20 != (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: arg0 = arg0 ; arg1 = tmp19 ; goto __ats_lab_auxlstlst_5 ; // tail call break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp17 = tmp20 ; break ; } while (0) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp17 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp17) ; } /* end of [auxlstlst_5] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 2506(line=83, offs=26) -- 3255(line=106, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search (ats_clo_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search: tmp22 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp21 = auxlst_4 (arg0, tmp22) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp21 != (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp23 = ats_ptrget_mac(ats_ptr_type, statmp4) ; tmp12 = auxlstlst_5 (arg0, tmp23) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp12 = tmp21 ; break ; } while (0) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_search] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 3354(line=113, offs=4) -- 3477(line=117, offs=4) */ ATSstaticdec() ats_void_type pop_err_7 () { /* local vardec */ // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; __ats_lab_pop_err_7: /* tmp26 = */ prerr_interror_1 () ; /* tmp27 = */ atspre_prerr_string (ATSstrcst(": pop_err: the_namlstlst is empty")) ; /* tmp28 = */ atspre_prerr_newline () ; /* tmp25 = */ ats_exit (1) ; return /* (tmp25) */ ; } /* end of [pop_err_7] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 3339(line=111, offs=19) -- 3669(line=126, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_pop () { /* local vardec */ // ATSlocal_void (tmp24) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_pop: tmp29 = ats_ptrget_mac(ats_ptr_type, statmp4) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (tmp29 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_0, tmp29, atslab_0) ; tmp31 = ats_caselptrlab_mac(anairiats_sum_0, tmp29, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp30 ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp31 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (tmp29 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: /* tmp24 = */ pop_err_7 () ; break ; } while (0) ; return /* (tmp24) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 3730(line=129, offs=20) -- 3840(line=132, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_push () { /* local vardec */ // ATSlocal_void (tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_push: tmp34 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp35 = ats_ptrget_mac(ats_ptr_type, statmp4) ; tmp33 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp33, atslab_0, tmp34) ; ats_selptrset_mac(anairiats_sum_0, tmp33, atslab_1, tmp35) ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp33 ; tmp36 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp36 ; return /* (tmp32) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_push] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 3923(line=137, offs=20) -- 4151(line=148, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_save () { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (anairiats_rec_1, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_save: tmp38 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp39 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp39 ; tmp40 = ats_ptrget_mac(ats_ptr_type, statmp4) ; tmp41 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp41 ; tmp43.atslab_0 = tmp38 ; tmp43.atslab_1 = tmp40 ; tmp44 = ats_ptrget_mac(ats_ptr_type, statmp6) ; tmp42 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp42, atslab_0, tmp43) ; ats_selptrset_mac(anairiats_sum_2, tmp42, atslab_1, tmp44) ; ats_ptrget_mac(ats_ptr_type, statmp6) = tmp42 ; return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_save] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 4252(line=155, offs=4) -- 4384(line=159, offs=4) */ ATSstaticdec() ats_void_type err_11 () { /* local vardec */ // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_err_11: /* tmp47 = */ prerr_interror_1 () ; /* tmp48 = */ atspre_prerr_string (ATSstrcst(": the_namespace_restore: the_savedlst is empty")) ; /* tmp49 = */ atspre_prerr_newline () ; /* tmp46 = */ ats_exit (1) ; return /* (tmp46) */ ; } /* end of [err_11] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 4237(line=153, offs=23) -- 4620(line=169, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_restore () { /* local vardec */ // ATSlocal_void (tmp45) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (anairiats_rec_1, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_restore: tmp50 = ats_ptrget_mac(ats_ptr_type, statmp6) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp50 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_2, tmp50, atslab_0) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_2, tmp50, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp6) = tmp52 ; tmp53 = ats_select_mac(tmp51, atslab_0) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp53 ; tmp54 = ats_select_mac(tmp51, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp54 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp50 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp45 = */ err_11 () ; break ; } while (0) ; return /* (tmp45) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_restore] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 4726(line=176, offs=4) -- 4868(line=181, offs=4) */ ATSstaticdec() ats_void_type err_13 () { /* local vardec */ // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; __ats_lab_err_13: /* tmp57 = */ prerr_interror_1 () ; /* tmp58 = */ atspre_prerr_string (ATSstrcst(": the_namespace_localjoin: the_namelstlst is too short")) ; /* tmp59 = */ atspre_prerr_newline () ; /* tmp56 = */ ats_exit (1) ; return /* (tmp56) */ ; } /* end of [err_13] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 4711(line=174, offs=25) -- 5129(line=192, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_localjoin () { /* local vardec */ // ATSlocal_void (tmp55) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_localjoin: tmp60 = ats_ptrget_mac(ats_ptr_type, statmp4) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp60 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } tmp61 = ats_caselptrlab_mac(anairiats_sum_0, tmp60, atslab_1) ; if (tmp61 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_0, tmp61, atslab_0) ; tmp63 = ats_caselptrlab_mac(anairiats_sum_0, tmp61, atslab_1) ; tmp65 = ats_ptrget_mac(ats_ptr_type, statmp0) ; tmp64 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp65, tmp62) ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp64 ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp63 ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: /* tmp55 = */ err_13 () ; break ; } while (0) ; return /* (tmp55) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_localjoin] */ /* // /home/hwxi/research/Anairiats/src/ats_namespace.dats: 5223(line=197, offs=26) -- 5370(line=203, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_initialize () { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_initialize: tmp67 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp0) = tmp67 ; tmp68 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp4) = tmp68 ; tmp69 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp6) = tmp69 ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__the_namespace_initialize] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_namespace_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp3 = (ats_sum_ptr_type)0 ; statmp0 = ref_make_elt_01807_ats_ptr_type (statmp3) ; statmp5 = (ats_sum_ptr_type)0 ; statmp4 = ref_make_elt_01807_ats_ptr_type (statmp5) ; statmp7 = (ats_sum_ptr_type)0 ; statmp6 = ref_make_elt_01807_ats_ptr_type (statmp7) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_namespace_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_assgn_dats.c0000664000175000017500000005524012223166160022532 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_2 ; typedef struct { anairiats_rec_2 atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_5 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_1 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_assgn.dats: 4057(line=119, offs=11) -- 4201(line=121, offs=28) */ ATSstaticdec() ats_void_type aux_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; __ats_lab_aux_1: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp46 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp47 = */ atspre_prerr_string (ATSstrcst(".")) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (tmp45) ; arg0 = tmp46 ; goto __ats_lab_aux_1 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp44) */ ; } /* end of [aux_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_assgn.dats: 2024(line=67, offs=3) -- 4440(line=131, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (anairiats_rec_0, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (anairiats_rec_2, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (anairiats_rec_1, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; // ATSlocal_void (tmp21) ; ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_bool_type, tmp23) ; // ATSlocal_void (tmp24) ; ATSlocal (ats_bool_type, tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; ATSlocal (ats_bool_type, tmp37) ; // ATSlocal_void (tmp38) ; // ATSlocal_void (tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst: tmp1 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (arg1) ; tmp2 = ats_select_mac(tmp1, atslab_0) ; tmp3 = ats_select_mac(tmp1, atslab_1) ; tmp4 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp3, arg2) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (tmp2, tmp4) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp5 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp6 = ats_caselptrlab_mac(anairiats_sum_3, tmp5, atslab_0) ; ATS_FREE(tmp5) ; tmp7 = ats_select_mac(tmp6, atslab_0) ; tmp8 = ats_select_mac(tmp6, atslab_1) ; tmp9 = ats_select_mac(tmp6, atslab_2) ; tmp10 = ats_select_mac(tmp6, atslab_3) ; tmp11 = ats_select_mac(tmp6, atslab_4) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local (tmp7) ; /* ats_ptr_type tmp13 ; */ tmp13 = (ats_sum_ptr_type)0 ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr (arg0, tmp8, tmp11, arg3, (&tmp13)) ; tmp15 = ats_select_mac(tmp14, atslab_0) ; tmp16 = ats_select_mac(tmp14, atslab_1) ; tmp17 = ats_select_mac(tmp14, atslab_2) ; /* tmp18 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp13) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (tmp3, tmp10, tmp17) ; /* ats_int_type tmp20 ; */ tmp20 = 0 ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (arg3) ; tmp22 = atspre_neg_bool (tmp23) ; if (tmp22) { /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_size_equal_solve_err (arg0, arg3, tmp15, (&tmp20)) ; } else { /* empty */ } /* end of [if] */ tmp25 = atspre_gt_int_int (tmp20, 0) ; if (tmp25) { /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp27 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp28 = */ atspre_prerr_string (ATSstrcst(": size mismatch for assignment")) ; /* tmp29 = */ atspre_prerr_string (ATSstrcst(": the following two types are expected to be size-equal but they may not be:")) ; /* tmp30 = */ atspre_prerr_newline () ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg3) ; /* tmp32 = */ atspre_prerr_newline () ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp15) ; /* tmp34 = */ atspre_prerr_newline () ; /* tmp24 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp35 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_reset_typ_at (tmp7, tmp16, tmp9) ; tmp37 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp15) ; if (tmp37) { /* tmp38 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp39 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp40 = */ atspre_prerr_string (ATSstrcst(": a linear value of the type [")) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp15) ; /* tmp42 = */ atspre_prerr_string (ATSstrcst("] is abandoned.")) ; /* tmp43 = */ atspre_prerr_newline () ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp0 = tmp19 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp50 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp51 = */ atspre_prerr_string (ATSstrcst(": there is no view at [")) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp2) ; /* tmp53 = */ aux_1 (tmp4) ; /* tmp54 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp55 = */ atspre_prerr_newline () ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_assgn.dats: 4536(line=137, offs=3) -- 5897(line=185, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (anairiats_rec_1, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; ATSlocal (ats_bool_type, tmp67) ; // ATSlocal_void (tmp68) ; ATSlocal (ats_bool_type, tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst: tmp58 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg1) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp58 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_5, tmp58, atslab_0) ; tmp57 = tmp59 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp58 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp57 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; } while (0) ; /* ats_ptr_type tmp60 ; */ tmp60 = (ats_sum_ptr_type)0 ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linset_slablst_cstr (arg0, tmp57, arg2, arg3, (&tmp60)) ; tmp62 = ats_select_mac(tmp61, atslab_0) ; tmp63 = ats_select_mac(tmp61, atslab_1) ; tmp64 = ats_select_mac(tmp61, atslab_2) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp60) ; tmp67 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (arg1) ; if (tmp67) { tmp69 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp62) ; if (tmp69) { /* tmp70 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp71 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp72 = */ atspre_prerr_string (ATSstrcst(": a linear value of the type [")) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp62) ; /* tmp74 = */ atspre_prerr_string (ATSstrcst("] is abandoned.")) ; /* tmp75 = */ atspre_prerr_newline () ; /* tmp68 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_inc_lin (arg1) ; } else { /* empty */ } /* end of [if] */ tmp77 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp77, atslab_0, tmp63) ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp77) ; tmp56 = tmp64 ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_assgn.dats: 5992(line=191, offs=3) -- 6453(line=205, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst: tmp80 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr (arg1) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp80 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_5, tmp80, atslab_0) ; tmp79 = tmp81 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp80 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp83 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp84 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp86 = */ atspre_prerr_string (ATSstrcst("] is expected to be mutable but it is not.")) ; /* tmp87 = */ atspre_prerr_newline () ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst (arg0, tmp79, arg2, arg3) ; return (tmp78) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_assgn_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_assgn_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp1_sats.c0000664000175000017500000004706012223166160021535 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_i1nvresstate_qua ; ats_ptr_type atslab_i1nvresstate_arg ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTcons_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_dyn_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tas_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tchar_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Texist_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfloat_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfree_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tint_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlst_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tqid_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trec_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tref_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trefas_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tstring_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Ttup_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABlab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_dyn_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrinit_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrpsz_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrsub_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ebool_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecaseof_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Echar_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecstsp_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecrypt_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edynload_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eeffmask_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eexist_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eextval_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efix_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloat_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloatsp_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efoldat_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efor_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efreeat_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eif_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eint_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eintsp_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elazy_delay_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elet_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eloopexn_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elst_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Emacsyn_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eptrof_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eraise_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Erec_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Escaseof_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esel_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eseq_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eshowtype_48) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esif_49) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estruct_51) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etmpid_52) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etrywith_54) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etup_55) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eviewat_56) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhere_57) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhile_58) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clist_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cinclude_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymintr_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymelim_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ce1xpdef_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatsrts_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csrtdefs_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacons_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacsts_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstavars_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csexpdefs_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csaspdec_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdcstdecs_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatdecs_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cexndecs_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cclassdec_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Coverload_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextype_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextval_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextcode_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_par_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_rec_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cfundecs_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvardecs_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cmacdefs_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cimpdec_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clocal_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdynload_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstaload_30) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTcons_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tann_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_dyn_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tas_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tchar_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Texist_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfloat_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfree_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tint_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlst_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tqid_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trec_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tref_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trefas_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tstring_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Ttup_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABlab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABind_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_dyn_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrinit_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrpsz_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrsub_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ebool_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecaseof_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Echar_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecstsp_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecrypt_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edynload_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eeffmask_15.tag = 15 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eexist_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eextval_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efix_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloat_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloatsp_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efoldat_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efor_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efreeat_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eif_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eint_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eintsp_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elazy_delay_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elet_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eloopexn_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elst_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Emacsyn_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eptrof_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eraise_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Erec_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Escaseof_44.tag = 44 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esel_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eseq_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47.tag = 47 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eshowtype_48.tag = 48 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esif_49.tag = 49 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50.tag = 50 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estruct_51.tag = 51 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etmpid_52.tag = 52 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53.tag = 53 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etrywith_54.tag = 54 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etup_55.tag = 55 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eviewat_56.tag = 56 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhere_57.tag = 57 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhile_58.tag = 58 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clist_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cinclude_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymintr_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymelim_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ce1xpdef_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatsrts_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csrtdefs_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacons_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacsts_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstavars_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csexpdefs_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csaspdec_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdcstdecs_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatdecs_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cexndecs_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cclassdec_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Coverload_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextype_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextval_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextcode_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_par_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_rec_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cfundecs_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvardecs_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cmacdefs_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cimpdec_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clocal_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdynload_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstaload_30.tag = 30 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp1_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_integer_dats.c0000664000175000017500000000733112223166160023444 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_integer_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ // stringization ats_ptr_type atspre_tostrptr_llint (ats_llint_type i0) { ats_llint_type i, i1 ; int n ; char *res ; i1 = (i0 >= 0 ? i0 : -i0) ; for (i = i1, n = 0; i > 0; i = i / 10) n += 1 ; if (i0 < 0) n += 1 ; if (i0 == 0) n = 1; res = ATS_MALLOC(n+1) ; res = res + n ; *res = '\000' ; for (i = i1, n = 0; i > 0; i = i / 10) { *--res = ('0' + i % 10) ; } if (i0 < 0) *--res = '-' ; if (i0 == 0) *--res = '0' ; return res ; } // end of [atspre_tostrptr_llint] /* ****** ****** */ ats_ptr_type atspre_tostrptr_ullint (ats_ullint_type i0) { ats_ullint_type i; int n ; char *res ; for (i = i0, n = 0; i > 0; i = i / 10) n += 1 ; if (i0 == 0) n = 1 ; res = ATS_MALLOC(n+1) ; res = res + n; *res = '\000' ; for (i = i0, n = 0; i > 0; i = i / 10) { *--res = ('0' + i % 10) ; } if (i0 == 0) *--res = '0' ; return res ; } // end of [atspre_tostrptr_ullint] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_integer_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_svVar_dats.c0000664000175000017500000040450612223166160022677 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_s2var_sym ; ats_ptr_type atslab_s2var_srt ; ats_int_type atslab_s2var_tmplev ; ats_ptr_type atslab_s2var_sVarset ; atsopt_count_type atslab_s2var_stamp ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_rec_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_s2Varbound_loc ; ats_ptr_type atslab_s2Varbound_val ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_s2Var_loc ; atsopt_count_type atslab_s2Var_cnt ; ats_ptr_type atslab_s2Var_srt ; ats_ptr_type atslab_s2Var_svar ; ats_bool_type atslab_s2Var_equal ; ats_ptr_type atslab_s2Var_link ; ats_ptr_type atslab_s2Var_lbs ; ats_ptr_type atslab_s2Var_ubs ; ats_ptr_type atslab_s2Var_sVarset ; atsopt_count_type atslab_s2Var_stamp ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_6 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Bl_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Br_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_count) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, atsopt_tostring_prefix_count) (ats_ptr_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, atsopt_counter_make) () ; ATSextern_fun(atsopt_count_type, atsopt_counter_getinc) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2var_stamp_make) () ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_adds) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_del) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_cnt) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst) (ats_ref_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_adds) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_del) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_dels) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2Varset_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2Var_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2Varbound_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2varset_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__s2var_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil) ; /* internal function declarations */ static ats_ptr_type s2var_name_make_0 () ; static ats_ptr_type s2var_name_make_prefix_1 (ats_ptr_type arg0) ; static ats_void_type loop_12 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type _compare_s2var_s2var_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type cmp_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pr_30 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type avl_foreach_03060_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type set_foreach_main_03054_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_s2varset_ptr_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type avl_height_03057_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type avl_rotate_l_03061_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_rotate_r_03062_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_insert_br_03064_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_insert_03063_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_insert_03050_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_takeout_min_03065_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type avl_remove_03077_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_remove_03051_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type __ats_fun_51 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_51_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_int_type __ats_fun_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type avl_join_r_03067_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type avl_join_l_03066_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type avl_split_br_03070_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) ; static ats_int_type avl_split_03069_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type avl_union_br_03076_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type avl_union_03075_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type set_union_03053_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type avl_member_03058_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type set_member_03049_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type cmp_89 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type pr_91 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type fprint_s2Varset_ptr_90 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp409) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 2251(line=72, offs=4) -- 2402(line=76, offs=4) */ ATSstaticdec() ats_ptr_type s2var_name_make_0 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (atsopt_count_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_s2var_name_make_0: tmp2 = atsopt_counter_getinc (statmp0) ; tmp3 = atsopt_tostring_prefix_count (ATSstrcst("$"), tmp2) ; tmp1 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (tmp3) ; return (tmp1) ; } /* end of [s2var_name_make_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 2435(line=78, offs=4) -- 2610(line=82, offs=4) */ ATSstaticdec() ats_ptr_type s2var_name_make_prefix_1 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (atsopt_count_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_s2var_name_make_prefix_1: tmp5 = atsopt_counter_getinc (statmp0) ; tmp7 = atsopt_tostring_prefix_count (ATSstrcst("$"), tmp5) ; tmp6 = atspre_string_append (arg0, tmp7) ; tmp4 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (tmp6) ; return (tmp4) ; } /* end of [s2var_name_make_prefix_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 2696(line=86, offs=29) -- 3103(line=106, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (atsopt_count_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt: tmp9 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2var_stamp_make () ; tmp10 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp11 = ats_selsin_mac(tmp10, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_s2var_sym) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_s2var_srt) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_s2var_tmplev) = 0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_s2var_sVarset) = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp11), atslab_s2var_stamp) = tmp9 ; /* tmp12 = */ atspre_vbox_make_view_ptr (tmp11) ; /* tmp13 = ats_selsin_mac(tmp12, atslab_1) */ ; tmp8 = tmp11 ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3160(line=109, offs=16) -- 3238(line=113, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt: tmp15 = s2var_name_make_0 () ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp15, arg0) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3288(line=116, offs=12) -- 3466(line=122, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_copy (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_copy: tmp17 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg0) ; tmp18 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (arg0) ; tmp20 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp17) ; tmp19 = s2var_name_make_prefix_1 (tmp20) ; tmp16 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp19, tmp18) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_copy] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3536(line=126, offs=25) -- 3593(line=127, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym: tmp22 = ats_selsin_mac(arg0, atslab_1) ; tmp21 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp22), atslab_s2var_sym) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3645(line=130, offs=25) -- 3702(line=131, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt: tmp24 = ats_selsin_mac(arg0, atslab_1) ; tmp23 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp24), atslab_s2var_srt) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3757(line=134, offs=28) -- 3817(line=135, offs=53) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_tmplev (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_tmplev: tmp26 = ats_selsin_mac(arg0, atslab_1) ; tmp25 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp26), atslab_s2var_tmplev) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_tmplev] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 3875(line=138, offs=28) -- 3947(line=139, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_tmplev (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_tmplev: tmp28 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp28), atslab_s2var_tmplev) = arg1 ; return /* (tmp27) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_tmplev] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4006(line=142, offs=29) -- 4067(line=143, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset: tmp30 = ats_selsin_mac(arg0, atslab_1) ; tmp29 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp30), atslab_s2var_sVarset) ; return (tmp29) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4127(line=146, offs=29) -- 4200(line=147, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset: tmp32 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp32), atslab_s2var_sVarset) = arg1 ; return /* (tmp31) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4287(line=152, offs=7) -- 4493(line=157, offs=24) */ ATSstaticdec() ats_void_type loop_12 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_loop_12: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp36 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset (tmp35, arg1) ; arg0 = tmp36 ; arg1 = arg1 ; goto __ats_lab_loop_12 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp34) */ ; } /* end of [loop_12] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4263(line=151, offs=22) -- 4538(line=161, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset: /* tmp33 = */ loop_12 (arg0, arg1) ; return /* (tmp33) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4599(line=163, offs=27) -- 4658(line=164, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp: tmp39 = ats_selsin_mac(arg0, atslab_1) ; tmp38 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp39), atslab_s2var_stamp) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4736(line=170, offs=3) -- 4787(line=170, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2var_s2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp40) ; ATSlocal (ats_int_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2var_s2var: tmp41 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (arg0, arg1) ; tmp40 = atspre_ilt (tmp41, 0) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2var_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4816(line=172, offs=3) -- 4868(line=172, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2var_s2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_int_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2var_s2var: tmp43 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (arg0, arg1) ; tmp42 = atspre_ilte (tmp43, 0) ; return (tmp42) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2var_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4897(line=175, offs=3) -- 4948(line=175, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp44) ; ATSlocal (ats_int_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var: tmp45 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (arg0, arg1) ; tmp44 = atspre_ieq (tmp45, 0) ; return (tmp44) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 4977(line=177, offs=3) -- 5029(line=177, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2var_s2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp46) ; ATSlocal (ats_int_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2var_s2var: tmp47 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (arg0, arg1) ; tmp46 = atspre_ineq (tmp47, 0) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2var_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 5034(line=179, offs=4) -- 5333(line=189, offs=4) */ ATSstaticdec() ats_int_type _compare_s2var_s2var_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (atsopt_count_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (atsopt_count_type, tmp52) ; __ats_lab__compare_s2var_s2var_18: tmp49 = ats_selsin_mac(arg0, atslab_1) ; tmp50 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp49), atslab_s2var_stamp) ; tmp51 = ats_selsin_mac(arg1, atslab_1) ; tmp52 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp51), atslab_s2var_stamp) ; tmp48 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp50, tmp52) ; return (tmp48) ; } /* end of [_compare_s2var_s2var_18] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 5398(line=192, offs=21) -- 5463(line=193, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var: tmp53 = _compare_s2var_s2var_18 (arg0, arg1) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 5594(line=200, offs=26) -- 5636(line=201, offs=35) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed: tmp55 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (arg0) ; tmp54 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (tmp55) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 5693(line=204, offs=28) -- 5721(line=204, offs=56) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_unboxed (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp56) ; ATSlocal (ats_bool_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_unboxed: tmp57 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_boxed (arg0) ; tmp56 = atspre_neg_bool (tmp57) ; return (tmp56) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_is_unboxed] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 5768(line=209, offs=14) -- 6024(line=218, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; ATSlocal (atsopt_count_type, tmp63) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var: tmp60 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sym (arg1) ; /* tmp59 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp60) ; /* tmp61 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (arg1) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp63) ; /* tmp58 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp58) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6073(line=220, offs=23) -- 6110(line=220, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; // ATSlocal_void (tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2var: tmp65 = atspre_stdout_get () ; tmp66 = ats_selsin_mac(tmp65, atslab_1) ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (tmp66, arg0) ; /* tmp64 = */ atspre_stdout_view_set () ; return /* (tmp64) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6133(line=221, offs=23) -- 6170(line=221, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; // ATSlocal_void (tmp71) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var: tmp69 = atspre_stderr_get () ; tmp70 = ats_selsin_mac(tmp69, atslab_1) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (tmp70, arg0) ; /* tmp68 = */ atspre_stderr_view_set () ; return /* (tmp68) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6219(line=226, offs=17) -- 6287(line=227, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst: /* tmp72 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var) ; return /* (tmp72) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6342(line=231, offs=16) -- 6384(line=231, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2varlst: tmp74 = atspre_stdout_get () ; tmp75 = ats_selsin_mac(tmp74, atslab_1) ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (tmp75, arg0) ; /* tmp73 = */ atspre_stdout_view_set () ; return /* (tmp73) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6410(line=233, offs=16) -- 6452(line=233, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; // ATSlocal_void (tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2varlst: tmp78 = atspre_stderr_get () ; tmp79 = ats_selsin_mac(tmp78, atslab_1) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varlst (tmp79, arg0) ; /* tmp77 = */ atspre_stderr_view_set () ; return /* (tmp77) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6644(line=247, offs=4) -- 6742(line=250, offs=50) */ ATSstaticdec() ats_int_type cmp_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp81) ; __ats_lab_cmp_28: tmp81 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2var_s2var (arg0, arg1) ; return (tmp81) ; } /* end of [cmp_28] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 7031(line=263, offs=4) -- 7304(line=273, offs=4) */ ATSstaticdec() ats_void_type pr_30 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_int_type, tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_bool_type, tmp88) ; ATSlocal (ats_int_type, tmp89) ; __ats_lab_pr_30: tmp85 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_0) ; tmp86 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_1) ; tmp88 = atspre_gt_int_int (tmp86, 0) ; if (tmp88) { /* tmp87 = */ atspre_fprint_string (tmp85, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp89 = atspre_add_int_int (tmp86, 1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_1) = tmp89 ; /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2var (tmp85, arg0) ; return /* (tmp84) */ ; } /* end of [pr_30] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 3823(line=113, offs=26) -- 4145(line=121, offs=4) */ ATSstaticdec() ats_void_type avl_foreach_03060_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; __ats_lab_avl_foreach_03060_ats_ptr_type: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp93 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp94 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; /* tmp95 = */ avl_foreach_03060_ats_ptr_type (tmp93, arg1, arg2) ; /* tmp96 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp92, arg2) ; arg0 = tmp94 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_03060_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp98 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp99 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; /* tmp100 = */ avl_foreach_03060_ats_ptr_type (tmp98, arg1, arg2) ; /* tmp101 = */ ((ats_void_type(*)(ats_ptr_type, ats_ptr_type))arg1) (tmp97, arg2) ; arg0 = tmp99 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_foreach_03060_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: break ; } while (0) ; return /* (tmp91) */ ; } /* end of [avl_foreach_03060_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18713(line=552, offs=31) -- 18767(line=553, offs=35) */ ATSstaticdec() ats_void_type set_foreach_main_03054_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp90) ; __ats_lab_set_foreach_main_03054_ats_ptr_type: /* tmp90 = */ avl_foreach_03060_ats_ptr_type (arg0, arg1, arg2) ; return /* (tmp90) */ ; } /* end of [set_foreach_main_03054_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 6747(line=252, offs=4) -- 7481(line=282, offs=4) */ ATSstaticdec() ats_void_type fprint_s2varset_ptr_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp82) ; ATSlocal (anairiats_rec_2, tmp83) ; __ats_lab_fprint_s2varset_ptr_29: /* anairiats_rec_2 tmp83 ; */ ats_select_mac(tmp83, atslab_0) = arg0 ; ats_select_mac(tmp83, atslab_1) = 0 ; /* tmp82 = */ set_foreach_main_03054_ats_ptr_type (arg1, &pr_30, (&tmp83)) ; return /* (tmp82) */ ; } /* end of [fprint_s2varset_ptr_29] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 7562(line=286, offs=27) -- 7630(line=287, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varset (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp102) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varset: /* tmp102 = */ fprint_s2varset_ptr_29 (arg0, arg1) ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2varset] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2500(line=68, offs=25) -- 2576(line=69, offs=60) */ ATSstaticdec() ats_int_type avl_height_03057_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_int_type, tmp119) ; __ats_lab_avl_height_03057_ats_ptr_type: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp117 = 0 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp117 = tmp118 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp119 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp117 = tmp119 ; break ; } while (0) ; return (tmp117) ; } /* end of [avl_height_03057_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 4346(line=128, offs=27) -- 5013(line=147, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_l_03061_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_int_type, tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_int_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_int_type, tmp138) ; ATSlocal (ats_int_type, tmp139) ; ATSlocal (ats_bool_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_int_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_int_type, tmp154) ; ATSlocal (ats_int_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_int_type, tmp157) ; __ats_lab_avl_rotate_l_03061_ats_ptr_type: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp127 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp128 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_3) ; tmp130 = avl_height_03057_ats_ptr_type (tmp129) ; tmp131 = atspre_iadd (tmp130, 2) ; tmp133 = atspre_iadd (tmp130, 1) ; tmp132 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp132)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_1, tmp133) ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_2, tmp129) ; ats_selptrset_mac(anairiats_sum_3, tmp132, atslab_3, arg2) ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp126)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_0, tmp127) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_1, tmp131) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_2, tmp128) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_3, tmp132) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp134 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp135 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_3) ; tmp138 = avl_height_03057_ats_ptr_type (tmp136) ; tmp139 = avl_height_03057_ats_ptr_type (tmp137) ; tmp140 = atspre_ilt (tmp138, tmp139) ; if (tmp140) { do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp137)->tag != 1) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_0) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_2) ; tmp143 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_3) ; tmp145 = atspre_iadd (tmp138, 1) ; tmp144 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp144)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_0, tmp134) ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_1, tmp145) ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_2, tmp136) ; ats_selptrset_mac(anairiats_sum_3, tmp144, atslab_3, tmp142) ; tmp147 = atspre_isub (tmp135, 1) ; tmp146 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp146)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp146, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp146, atslab_1, tmp147) ; ats_selptrset_mac(anairiats_sum_3, tmp146, atslab_2, tmp143) ; ats_selptrset_mac(anairiats_sum_3, tmp146, atslab_3, arg2) ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp126)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_0, tmp141) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_1, tmp135) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_2, tmp144) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_3, tmp146) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)tmp137)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp148 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_0) ; tmp149 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_2) ; tmp150 = ats_caselptrlab_mac(anairiats_sum_3, tmp137, atslab_3) ; tmp152 = atspre_iadd (tmp138, 1) ; tmp151 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp151)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp151, atslab_0, tmp134) ; ats_selptrset_mac(anairiats_sum_3, tmp151, atslab_1, tmp152) ; ats_selptrset_mac(anairiats_sum_3, tmp151, atslab_2, tmp136) ; ats_selptrset_mac(anairiats_sum_3, tmp151, atslab_3, tmp149) ; tmp154 = atspre_isub (tmp135, 1) ; tmp153 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp153)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_1, tmp154) ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_2, tmp150) ; ats_selptrset_mac(anairiats_sum_3, tmp153, atslab_3, arg2) ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp126)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_0, tmp148) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_1, tmp135) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_2, tmp151) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_3, tmp153) ; break ; } while (0) ; } else { tmp155 = atspre_iadd (tmp139, 2) ; tmp157 = atspre_iadd (tmp139, 1) ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp156)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp156, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp156, atslab_1, tmp157) ; ats_selptrset_mac(anairiats_sum_3, tmp156, atslab_2, tmp137) ; ats_selptrset_mac(anairiats_sum_3, tmp156, atslab_3, arg2) ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp126)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_0, tmp134) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_1, tmp155) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_2, tmp136) ; ats_selptrset_mac(anairiats_sum_3, tmp126, atslab_3, tmp156) ; } /* end of [if] */ break ; } while (0) ; return (tmp126) ; } /* end of [avl_rotate_l_03061_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 5194(line=152, offs=27) -- 5846(line=171, offs=4) */ ATSstaticdec() ats_ptr_type avl_rotate_r_03062_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_int_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_int_type, tmp172) ; ATSlocal (ats_int_type, tmp173) ; ATSlocal (ats_bool_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_int_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_int_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_int_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_int_type, tmp188) ; ATSlocal (ats_int_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_int_type, tmp195) ; ATSlocal (ats_int_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; __ats_lab_avl_rotate_r_03062_ats_ptr_type: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_17_0 ; } __ats_lab_14_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp170 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp171 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_3) ; tmp172 = avl_height_03057_ats_ptr_type (tmp170) ; tmp173 = avl_height_03057_ats_ptr_type (tmp171) ; tmp174 = atspre_igt (tmp172, tmp173) ; if (tmp174) { do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp170)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_2) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_3) ; tmp179 = atspre_isub (tmp169, 1) ; tmp178 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp178)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp178, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp178, atslab_1, tmp179) ; ats_selptrset_mac(anairiats_sum_3, tmp178, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp178, atslab_3, tmp176) ; tmp181 = atspre_iadd (tmp173, 1) ; tmp180 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp180)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp180, atslab_0, tmp168) ; ats_selptrset_mac(anairiats_sum_3, tmp180, atslab_1, tmp181) ; ats_selptrset_mac(anairiats_sum_3, tmp180, atslab_2, tmp177) ; ats_selptrset_mac(anairiats_sum_3, tmp180, atslab_3, tmp171) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp167)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_0, tmp175) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_1, tmp169) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_2, tmp178) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_3, tmp180) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (((ats_sum_ptr_type)tmp170)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_2) ; tmp184 = ats_caselptrlab_mac(anairiats_sum_3, tmp170, atslab_3) ; tmp186 = atspre_isub (tmp169, 1) ; tmp185 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp185)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp185, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp185, atslab_1, tmp186) ; ats_selptrset_mac(anairiats_sum_3, tmp185, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp185, atslab_3, tmp183) ; tmp188 = atspre_iadd (tmp173, 1) ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp187)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_0, tmp168) ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_1, tmp188) ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_2, tmp184) ; ats_selptrset_mac(anairiats_sum_3, tmp187, atslab_3, tmp171) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp167)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_0, tmp182) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_1, tmp169) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_2, tmp185) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_3, tmp187) ; break ; } while (0) ; } else { tmp189 = atspre_iadd (tmp172, 2) ; tmp191 = atspre_iadd (tmp172, 1) ; tmp190 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp190)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp190, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp190, atslab_1, tmp191) ; ats_selptrset_mac(anairiats_sum_3, tmp190, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp190, atslab_3, tmp170) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp167)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_0, tmp168) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_1, tmp189) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_2, tmp190) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_3, tmp171) ; } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp192 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp193 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_3) ; tmp195 = avl_height_03057_ats_ptr_type (tmp193) ; tmp196 = atspre_iadd (tmp195, 2) ; tmp198 = atspre_iadd (tmp195, 1) ; tmp197 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp197)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp197, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp197, atslab_1, tmp198) ; ats_selptrset_mac(anairiats_sum_3, tmp197, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp197, atslab_3, tmp193) ; tmp167 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp167)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_0, tmp192) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_1, tmp196) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_2, tmp197) ; ats_selptrset_mac(anairiats_sum_3, tmp167, atslab_3, tmp194) ; break ; } while (0) ; return (tmp167) ; } /* end of [avl_rotate_r_03062_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6555(line=191, offs=3) -- 7255(line=213, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_br_03064_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_int_type, tmp113) ; ATSlocal (ats_bool_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_int_type, tmp120) ; ATSlocal (ats_bool_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_bool_type, tmp123) ; ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_int_type, tmp125) ; ATSlocal (ats_bool_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_bool_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_bool_type, tmp164) ; ATSlocal (ats_int_type, tmp165) ; ATSlocal (ats_int_type, tmp166) ; ATSlocal (ats_int_type, tmp199) ; ATSlocal (ats_int_type, tmp200) ; ATSlocal (ats_bool_type, tmp201) ; __ats_lab_avl_insert_br_03064_ats_ptr_type: tmp113 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg5) (arg4, arg0) ; tmp114 = atspre_ilt (tmp113, 0) ; if (tmp114) { tmp115 = avl_insert_03063_ats_ptr_type (arg2, arg4, arg5) ; tmp116 = avl_height_03057_ats_ptr_type (tmp115) ; tmp120 = avl_height_03057_ats_ptr_type (arg3) ; tmp121 = atspre_ilte (tmp116, tmp120) ; if (tmp121) { tmp122 = atspre_iadd (tmp120, 1) ; tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, tmp122) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, tmp115) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, arg3) ; } else { tmp124 = atspre_iadd (tmp120, 1) ; tmp123 = atspre_ilte (tmp116, tmp124) ; if (tmp123) { tmp125 = atspre_iadd (tmp116, 1) ; tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, tmp125) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, tmp115) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, arg3) ; } else { tmp112 = avl_rotate_l_03061_ats_ptr_type (arg0, tmp115, arg3) ; } /* end of [if] */ } /* end of [if] */ } else { tmp158 = atspre_igt (tmp113, 0) ; if (tmp158) { tmp159 = avl_insert_03063_ats_ptr_type (arg3, arg4, arg5) ; tmp160 = avl_height_03057_ats_ptr_type (arg2) ; tmp161 = avl_height_03057_ats_ptr_type (tmp159) ; tmp162 = atspre_ilte (tmp161, tmp160) ; if (tmp162) { tmp163 = atspre_iadd (tmp160, 1) ; tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, tmp163) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, tmp159) ; } else { tmp165 = atspre_iadd (tmp160, 1) ; tmp164 = atspre_ilte (tmp161, tmp165) ; if (tmp164) { tmp166 = atspre_iadd (tmp161, 1) ; tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, tmp166) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, tmp159) ; } else { tmp112 = avl_rotate_r_03062_ats_ptr_type (arg0, arg2, tmp159) ; } /* end of [if] */ } /* end of [if] */ } else { tmp199 = avl_height_03057_ats_ptr_type (arg2) ; tmp200 = avl_height_03057_ats_ptr_type (arg3) ; tmp201 = atspre_igte (tmp199, tmp200) ; if (tmp201) { tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, arg3) ; } else { tmp112 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp112)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp112, atslab_3, arg3) ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return (tmp112) ; } /* end of [avl_insert_br_03064_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 6313(line=184, offs=25) -- 6501(line=188, offs=4) */ ATSstaticdec() ats_ptr_type avl_insert_03063_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; __ats_lab_avl_insert_03063_ats_ptr_type: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp106 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp107 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; tmp105 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp105)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp105, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp105, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_3, tmp105, atslab_2, tmp106) ; ats_selptrset_mac(anairiats_sum_3, tmp105, atslab_3, tmp107) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_6_1: tmp108 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp111 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp105 = avl_insert_br_03064_ats_ptr_type (tmp108, tmp109, tmp110, tmp111, arg1, arg2) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp205 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp105 = avl_insert_br_03064_ats_ptr_type (tmp202, tmp203, tmp204, tmp205, arg1, arg2) ; break ; } while (0) ; return (tmp105) ; } /* end of [avl_insert_03063_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18425(line=545, offs=25) -- 18463(line=545, offs=63) */ ATSstaticdec() ats_ptr_type set_insert_03050_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_set_insert_03050_ats_ptr_type: tmp104 = avl_insert_03063_ats_ptr_type (arg0, arg1, arg2) ; return (tmp104) ; } /* end of [set_insert_03050_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 7694(line=291, offs=24) -- 7738(line=291, offs=68) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add: tmp103 = set_insert_03050_ats_ptr_type (arg0, arg1, &cmp_28) ; return (tmp103) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 7763(line=292, offs=25) -- 7888(line=294, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_adds (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_adds: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp207 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp208 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp209 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add (arg0, tmp207) ; arg0 = tmp209 ; arg1 = tmp208 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_adds ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp206 = arg0 ; break ; } while (0) ; return (tmp206) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_adds] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 7445(line=220, offs=30) -- 8191(line=242, offs=4) */ ATSstaticdec() ats_ptr_type avl_takeout_min_03065_ats_ptr_type (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_int_type, tmp236) ; ATSlocal (ats_int_type, tmp237) ; ATSlocal (ats_bool_type, tmp238) ; ATSlocal (ats_int_type, tmp239) ; ATSlocal (ats_int_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_int_type, tmp245) ; ATSlocal (ats_int_type, tmp246) ; ATSlocal (ats_bool_type, tmp247) ; ATSlocal (ats_int_type, tmp248) ; ATSlocal (ats_bool_type, tmp249) ; ATSlocal (ats_int_type, tmp250) ; ATSlocal (ats_int_type, tmp251) ; __ats_lab_avl_takeout_min_03065_ats_ptr_type: do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_28_1: tmp232 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp233)->tag != 0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: ats_ptrget_mac(ats_ptr_type, arg1) = tmp232 ; tmp231 = tmp234 ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp235 = avl_takeout_min_03065_ats_ptr_type (tmp233, arg1) ; tmp236 = avl_height_03057_ats_ptr_type (tmp235) ; tmp237 = avl_height_03057_ats_ptr_type (tmp234) ; tmp238 = atspre_ilte (tmp237, tmp236) ; if (tmp238) { tmp239 = atspre_iadd (tmp236, 1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp231)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_0, tmp232) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_1, tmp239) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_2, tmp235) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_3, tmp234) ; } else { tmp240 = atspre_iadd (tmp237, 1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp231)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_0, tmp232) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_1, tmp240) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_2, tmp235) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_3, tmp234) ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp241 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp242 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp243 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp242)->tag != 0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: ats_ptrget_mac(ats_ptr_type, arg1) = tmp241 ; tmp231 = tmp243 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp244 = avl_takeout_min_03065_ats_ptr_type (tmp242, arg1) ; tmp245 = avl_height_03057_ats_ptr_type (tmp244) ; tmp246 = avl_height_03057_ats_ptr_type (tmp243) ; tmp247 = atspre_ilte (tmp246, tmp245) ; if (tmp247) { tmp248 = atspre_iadd (tmp245, 1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp231)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_0, tmp241) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_1, tmp248) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_2, tmp244) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_3, tmp243) ; } else { tmp250 = atspre_iadd (tmp245, 1) ; tmp249 = atspre_ilte (tmp246, tmp250) ; if (tmp249) { tmp251 = atspre_iadd (tmp246, 1) ; tmp231 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp231)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_0, tmp241) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_1, tmp251) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_2, tmp244) ; ats_selptrset_mac(anairiats_sum_3, tmp231, atslab_3, tmp243) ; } else { tmp231 = avl_rotate_r_03062_ats_ptr_type (tmp241, tmp244, tmp243) ; } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; return (tmp231) ; } /* end of [avl_takeout_min_03065_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 16506(line=487, offs=25) -- 18188(line=535, offs=4) */ ATSstaticdec() ats_ptr_type avl_remove_03077_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_int_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_int_type, tmp218) ; ATSlocal (ats_int_type, tmp219) ; ATSlocal (ats_bool_type, tmp220) ; ATSlocal (ats_int_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_int_type, tmp224) ; ATSlocal (ats_int_type, tmp225) ; ATSlocal (ats_bool_type, tmp226) ; ATSlocal (ats_int_type, tmp227) ; ATSlocal (ats_int_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_int_type, tmp252) ; ATSlocal (ats_int_type, tmp253) ; ATSlocal (ats_bool_type, tmp254) ; ATSlocal (ats_int_type, tmp255) ; ATSlocal (ats_int_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_int_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_int_type, tmp262) ; ATSlocal (ats_int_type, tmp263) ; ATSlocal (ats_bool_type, tmp264) ; ATSlocal (ats_int_type, tmp265) ; ATSlocal (ats_int_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_int_type, tmp268) ; ATSlocal (ats_int_type, tmp269) ; ATSlocal (ats_bool_type, tmp270) ; ATSlocal (ats_int_type, tmp271) ; ATSlocal (ats_int_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_int_type, tmp275) ; ATSlocal (ats_int_type, tmp276) ; ATSlocal (ats_bool_type, tmp277) ; ATSlocal (ats_int_type, tmp278) ; ATSlocal (ats_int_type, tmp279) ; __ats_lab_avl_remove_03077_ats_ptr_type: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp212 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_34_0 ; } __ats_lab_22_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp214 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp216 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp213) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (tmp216 != -1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp217 = avl_remove_03077_ats_ptr_type (tmp214, arg1, arg2) ; tmp218 = avl_height_03057_ats_ptr_type (tmp217) ; tmp219 = avl_height_03057_ats_ptr_type (tmp215) ; tmp220 = atspre_ilte (tmp219, tmp218) ; if (tmp220) { tmp221 = atspre_iadd (tmp218, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp213) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp221) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp217) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp215) ; } else { tmp222 = atspre_iadd (tmp219, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp213) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp222) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp217) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp215) ; } /* end of [if] */ break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (tmp216 != 1) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp223 = avl_remove_03077_ats_ptr_type (tmp215, arg1, arg2) ; tmp224 = avl_height_03057_ats_ptr_type (tmp214) ; tmp225 = avl_height_03057_ats_ptr_type (tmp223) ; tmp227 = atspre_iadd (tmp225, 1) ; tmp226 = atspre_ilte (tmp224, tmp227) ; if (tmp226) { tmp228 = atspre_iadd (tmp224, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp213) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp228) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp214) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp223) ; } else { tmp212 = avl_rotate_l_03061_ats_ptr_type (tmp213, tmp214, tmp223) ; } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (tmp216 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp215)->tag != 0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp212 = tmp214 ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: /* ats_ptr_type tmp229 ; */ tmp230 = avl_takeout_min_03065_ats_ptr_type (tmp215, (&tmp229)) ; tmp252 = avl_height_03057_ats_ptr_type (tmp214) ; tmp253 = avl_height_03057_ats_ptr_type (tmp230) ; tmp255 = atspre_iadd (tmp253, 1) ; tmp254 = atspre_ilte (tmp252, tmp255) ; if (tmp254) { tmp256 = atspre_iadd (tmp252, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp229) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp256) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp214) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp230) ; } else { tmp212 = avl_rotate_l_03061_ats_ptr_type (tmp229, tmp214, tmp230) ; } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp259 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp260 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp257) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp260 != -1) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp261 = avl_remove_03077_ats_ptr_type (tmp258, arg1, arg2) ; tmp262 = avl_height_03057_ats_ptr_type (tmp261) ; tmp263 = avl_height_03057_ats_ptr_type (tmp259) ; tmp265 = atspre_iadd (tmp262, 1) ; tmp264 = atspre_ilte (tmp263, tmp265) ; if (tmp264) { tmp266 = atspre_iadd (tmp263, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp257) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp266) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp261) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp259) ; } else { tmp212 = avl_rotate_r_03062_ats_ptr_type (tmp257, tmp261, tmp259) ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp260 != 1) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp267 = avl_remove_03077_ats_ptr_type (tmp259, arg1, arg2) ; tmp268 = avl_height_03057_ats_ptr_type (tmp258) ; tmp269 = avl_height_03057_ats_ptr_type (tmp267) ; tmp270 = atspre_ilte (tmp269, tmp268) ; if (tmp270) { tmp271 = atspre_iadd (tmp268, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp257) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp271) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp258) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp267) ; } else { tmp272 = atspre_iadd (tmp269, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp257) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp272) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp258) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp267) ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp260 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp259)->tag != 0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp212 = tmp258 ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: /* ats_ptr_type tmp273 ; */ tmp274 = avl_takeout_min_03065_ats_ptr_type (tmp259, (&tmp273)) ; tmp275 = avl_height_03057_ats_ptr_type (tmp258) ; tmp276 = avl_height_03057_ats_ptr_type (tmp274) ; tmp277 = atspre_ilte (tmp276, tmp275) ; if (tmp277) { tmp278 = atspre_iadd (tmp275, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp273) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp278) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp258) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp274) ; } else { tmp279 = atspre_iadd (tmp276, 1) ; tmp212 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp212)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_0, tmp273) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_1, tmp279) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_2, tmp258) ; ats_selptrset_mac(anairiats_sum_3, tmp212, atslab_3, tmp274) ; } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; break ; } while (0) ; return (tmp212) ; } /* end of [avl_remove_03077_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18488(line=546, offs=25) -- 18526(line=546, offs=63) */ ATSstaticdec() ats_ptr_type set_remove_03051_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_set_remove_03051_ats_ptr_type: tmp211 = avl_remove_03077_ats_ptr_type (arg0, arg1, arg2) ; return (tmp211) ; } /* end of [set_remove_03051_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 7939(line=297, offs=24) -- 7983(line=297, offs=68) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_del (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp210) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_del: tmp210 = set_remove_03051_ats_ptr_type (arg0, arg1, &cmp_28) ; return (tmp210) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_del] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 8008(line=298, offs=25) -- 8133(line=300, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp283 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_del (arg0, tmp281) ; arg0 = tmp283 ; arg1 = tmp282 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: tmp280 = arg0 ; break ; } while (0) ; return (tmp280) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15899(line=469, offs=14) -- 15939(line=469, offs=54) */ ATSstaticdec() ats_int_type __ats_fun_51 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp294) ; __ats_lab___ats_fun_51: tmp294 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))env1) (env0, arg0) ; return (tmp294) ; } /* end of [__ats_fun_51] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } __ats_fun_51_closure_type ; ats_int_type __ats_fun_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_51 (((__ats_fun_51_closure_type*)cloptr)->closure_env_0, ((__ats_fun_51_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_51_closure_init (__ats_fun_51_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_51_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_51_closure_make (ats_ptr_type env0, ats_ptr_type env1) { __ats_fun_51_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_51_closure_type)) ; __ats_fun_51_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 9272(line=275, offs=25) -- 9961(line=296, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_r_03067_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_int_type, tmp312) ; ATSlocal (ats_int_type, tmp313) ; ATSlocal (ats_bool_type, tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_int_type, tmp321) ; ATSlocal (ats_bool_type, tmp322) ; ATSlocal (ats_int_type, tmp323) ; ATSlocal (ats_int_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_int_type, tmp330) ; ATSlocal (ats_bool_type, tmp331) ; ATSlocal (ats_int_type, tmp332) ; ATSlocal (ats_int_type, tmp333) ; ATSlocal (ats_int_type, tmp334) ; __ats_lab_avl_join_r_03067_ats_ptr_type: tmp312 = avl_height_03057_ats_ptr_type (arg1) ; tmp313 = avl_height_03057_ats_ptr_type (arg2) ; tmp315 = atspre_iadd (tmp312, 1) ; tmp314 = atspre_ilt (tmp315, tmp313) ; if (tmp314) { do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp316 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_3) ; tmp319 = avl_join_r_03067_ats_ptr_type (arg0, arg1, tmp317) ; tmp320 = avl_height_03057_ats_ptr_type (tmp319) ; tmp321 = avl_height_03057_ats_ptr_type (tmp318) ; tmp323 = atspre_iadd (tmp321, 1) ; tmp322 = atspre_ilte (tmp320, tmp323) ; if (tmp322) { tmp324 = atspre_iadd (tmp320, 1) ; tmp311 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp311)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_0, tmp316) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_1, tmp324) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_2, tmp319) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_3, tmp318) ; } else { tmp311 = avl_rotate_l_03061_ats_ptr_type (tmp316, tmp319, tmp318) ; } /* end of [if] */ break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (((ats_sum_ptr_type)arg2)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp326 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp327 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_3) ; tmp328 = avl_join_r_03067_ats_ptr_type (arg0, arg1, tmp326) ; tmp329 = avl_height_03057_ats_ptr_type (tmp328) ; tmp330 = avl_height_03057_ats_ptr_type (tmp327) ; tmp331 = atspre_ilte (tmp329, tmp330) ; if (tmp331) { tmp332 = atspre_iadd (tmp330, 1) ; tmp311 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp311)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_0, tmp325) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_1, tmp332) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_2, tmp328) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_3, tmp327) ; } else { tmp333 = atspre_iadd (tmp329, 1) ; tmp311 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp311)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_0, tmp325) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_1, tmp333) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_2, tmp328) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_3, tmp327) ; } /* end of [if] */ break ; } while (0) ; } else { tmp334 = atspre_iadd (tmp313, 1) ; tmp311 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp311)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_1, tmp334) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp311, atslab_3, arg2) ; } /* end of [if] */ return (tmp311) ; } /* end of [avl_join_r_03067_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 8402(line=249, offs=25) -- 9087(line=270, offs=4) */ ATSstaticdec() ats_ptr_type avl_join_l_03066_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_int_type, tmp338) ; ATSlocal (ats_int_type, tmp339) ; ATSlocal (ats_bool_type, tmp340) ; ATSlocal (ats_int_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_int_type, tmp346) ; ATSlocal (ats_int_type, tmp347) ; ATSlocal (ats_bool_type, tmp348) ; ATSlocal (ats_int_type, tmp349) ; ATSlocal (ats_int_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_int_type, tmp355) ; ATSlocal (ats_int_type, tmp356) ; ATSlocal (ats_bool_type, tmp357) ; ATSlocal (ats_int_type, tmp358) ; ATSlocal (ats_int_type, tmp359) ; ATSlocal (ats_int_type, tmp360) ; __ats_lab_avl_join_l_03066_ats_ptr_type: tmp338 = avl_height_03057_ats_ptr_type (arg1) ; tmp339 = avl_height_03057_ats_ptr_type (arg2) ; tmp341 = atspre_iadd (tmp339, 1) ; tmp340 = atspre_igt (tmp338, tmp341) ; if (tmp340) { do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp342 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp343 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_3) ; tmp345 = avl_join_l_03066_ats_ptr_type (arg0, tmp344, arg2) ; tmp346 = avl_height_03057_ats_ptr_type (tmp343) ; tmp347 = avl_height_03057_ats_ptr_type (tmp345) ; tmp348 = atspre_ilte (tmp347, tmp346) ; if (tmp348) { tmp349 = atspre_iadd (tmp346, 1) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp337)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_0, tmp342) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_1, tmp349) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_2, tmp343) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_3, tmp345) ; } else { tmp350 = atspre_iadd (tmp347, 1) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp337)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_0, tmp342) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_1, tmp350) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_2, tmp343) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_3, tmp345) ; } /* end of [if] */ break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp351 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp352 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp353 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_3) ; tmp354 = avl_join_l_03066_ats_ptr_type (arg0, tmp353, arg2) ; tmp355 = avl_height_03057_ats_ptr_type (tmp352) ; tmp356 = avl_height_03057_ats_ptr_type (tmp354) ; tmp358 = atspre_iadd (tmp355, 1) ; tmp357 = atspre_ilte (tmp356, tmp358) ; if (tmp357) { tmp359 = atspre_iadd (tmp356, 1) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp337)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_0, tmp351) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_1, tmp359) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_2, tmp352) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_3, tmp354) ; } else { tmp337 = avl_rotate_r_03062_ats_ptr_type (tmp351, tmp352, tmp354) ; } /* end of [if] */ break ; } while (0) ; } else { tmp360 = atspre_iadd (tmp338, 1) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp337)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_1, tmp360) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp337, atslab_3, arg2) ; } /* end of [if] */ return (tmp337) ; } /* end of [avl_join_l_03066_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11552(line=345, offs=3) -- 12417(line=370, offs=4) */ ATSstaticdec() ats_int_type avl_split_br_03070_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_clo_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_int_type, tmp302) ; ATSlocal (ats_int_type, tmp303) ; ATSlocal (ats_int_type, tmp304) ; ATSlocal (ats_int_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_int_type, tmp308) ; ATSlocal (ats_bool_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_int_type, tmp362) ; ATSlocal (ats_int_type, tmp363) ; ATSlocal (ats_int_type, tmp364) ; ATSlocal (ats_int_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_bool_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_avl_split_br_03070_ats_ptr_type: tmp303 = ((ats_int_type(*)(ats_clo_ptr_type, ats_ptr_type))(ats_closure_fun(arg4))) (arg4, arg0) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (tmp303 != -1) { goto __ats_lab_51_0 ; } __ats_lab_46_1: tmp304 = avl_split_03069_ats_ptr_type (arg2, arg4, arg5, arg6) ; tmp305 = ats_selsin_mac(tmp304, atslab_2) ; tmp307 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp306 = avl_height_03057_ats_ptr_type (tmp307) ; tmp308 = avl_height_03057_ats_ptr_type (arg3) ; tmp309 = atspre_ilte (tmp306, tmp308) ; if (tmp309) { tmp335 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp310 = avl_join_r_03067_ats_ptr_type (arg0, tmp335, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp310 ; tmp302 = tmp305 ; } else { tmp361 = ats_ptrget_mac(ats_ptr_type, arg6) ; tmp336 = avl_join_l_03066_ats_ptr_type (arg0, tmp361, arg3) ; ats_ptrget_mac(ats_ptr_type, arg6) = tmp336 ; tmp302 = tmp305 ; } /* end of [if] */ break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (tmp303 != 1) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp362 = avl_split_03069_ats_ptr_type (arg3, arg4, arg5, arg6) ; tmp363 = ats_selsin_mac(tmp362, atslab_2) ; tmp364 = avl_height_03057_ats_ptr_type (arg2) ; tmp366 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp365 = avl_height_03057_ats_ptr_type (tmp366) ; tmp367 = atspre_ilte (tmp364, tmp365) ; if (tmp367) { tmp369 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp368 = avl_join_r_03067_ats_ptr_type (arg0, arg2, tmp369) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp368 ; tmp302 = tmp363 ; } else { tmp371 = ats_ptrget_mac(ats_ptr_type, arg5) ; tmp370 = avl_join_l_03066_ats_ptr_type (arg0, arg2, tmp371) ; ats_ptrget_mac(ats_ptr_type, arg5) = tmp370 ; tmp302 = tmp363 ; } /* end of [if] */ break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (tmp303 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: ats_ptrget_mac(ats_ptr_type, arg5) = arg2 ; ats_ptrget_mac(ats_ptr_type, arg6) = arg3 ; tmp302 = 1 ; break ; } while (0) ; return (tmp302) ; } /* end of [avl_split_br_03070_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 11224(line=336, offs=24) -- 11486(line=341, offs=8) */ ATSstaticdec() ats_int_type avl_split_03069_ats_ptr_type (ats_ptr_type arg0, ats_clo_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_int_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_int_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; __ats_lab_avl_split_03069_ats_ptr_type: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_53_0 ; } __ats_lab_45_1: tmp298 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp299 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp300 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp297 = avl_split_br_03070_ats_ptr_type (tmp298, tmp299, tmp300, tmp301, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp372 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp373 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp374 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp375 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp297 = avl_split_br_03070_ats_ptr_type (tmp372, tmp373, tmp374, tmp375, arg1, arg2, arg3) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: tmp376 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp376 ; tmp377 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp377 ; tmp297 = 0 ; break ; } while (0) ; return (tmp297) ; } /* end of [avl_split_03069_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15826(line=467, offs=27) -- 16289(line=478, offs=4) */ ATSstaticdec() ats_ptr_type avl_union_br_03076_ats_ptr_type (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_int_type, tmp296) ; ATSlocal (ats_int_type, tmp378) ; // ATSlocal_void (tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_int_type, tmp382) ; ATSlocal (ats_int_type, tmp383) ; ATSlocal (ats_bool_type, tmp384) ; __ats_lab_avl_union_br_03076_ats_ptr_type: /* ats_ptr_type tmp292 ; */ /* ats_ptr_type tmp293 ; */ tmp295 = __ats_fun_51_closure_make (arg0, arg5) ; tmp296 = avl_split_03069_ats_ptr_type (arg4, tmp295, (&tmp292), (&tmp293)) ; tmp378 = ats_selsin_mac(tmp296, atslab_2) ; /* tmp379 = */ atspre_cloptr_free (tmp295) ; tmp380 = avl_union_03075_ats_ptr_type (arg2, tmp292, arg5) ; tmp381 = avl_union_03075_ats_ptr_type (arg3, tmp293, arg5) ; tmp382 = avl_height_03057_ats_ptr_type (tmp380) ; tmp383 = avl_height_03057_ats_ptr_type (tmp381) ; tmp384 = atspre_ilte (tmp382, tmp383) ; if (tmp384) { tmp291 = avl_join_r_03067_ats_ptr_type (arg0, tmp380, tmp381) ; } else { tmp291 = avl_join_l_03066_ats_ptr_type (arg0, tmp380, tmp381) ; } /* end of [if] */ return (tmp291) ; } /* end of [avl_union_br_03076_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 15583(line=461, offs=24) -- 15798(line=465, offs=71) */ ATSstaticdec() ats_ptr_type avl_union_03075_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_int_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_int_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; __ats_lab_avl_union_03075_ats_ptr_type: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: __ats_lab_42_2: tmp286 = arg1 ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_43_2: tmp286 = arg0 ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_55_0 ; } __ats_lab_44_1: __ats_lab_44_2: tmp287 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp288 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp289 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp290 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp286 = avl_union_br_03076_ats_ptr_type (tmp287, tmp288, tmp289, tmp290, arg1, arg2) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: __ats_lab_55_2: tmp385 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp386 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp387 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp286 = avl_union_br_03076_ats_ptr_type (tmp385, tmp386, tmp387, tmp388, arg1, arg2) ; break ; } while (0) ; return (tmp286) ; } /* end of [avl_union_03075_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18617(line=548, offs=24) -- 18660(line=548, offs=67) */ ATSstaticdec() ats_ptr_type set_union_03053_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; __ats_lab_set_union_03053_ats_ptr_type: tmp285 = avl_union_03075_ats_ptr_type (arg0, arg1, arg2) ; return (tmp285) ; } /* end of [set_union_03053_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 8186(line=303, offs=26) -- 8233(line=303, offs=73) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union: tmp284 = set_union_03053_ats_ptr_type (arg0, arg1, &cmp_28) ; return (tmp284) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 2736(line=77, offs=25) -- 3115(line=90, offs=4) */ ATSstaticdec() ats_bool_type avl_member_03058_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_int_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_int_type, tmp399) ; __ats_lab_avl_member_03058_ats_ptr_type: do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_60_0 ; } __ats_lab_56_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp393 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp394 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp395 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp392) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (tmp395 != -1) { goto __ats_lab_58_0 ; } __ats_lab_57_1: arg0 = tmp393 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03058_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp395 != 1) { goto __ats_lab_59_0 ; } __ats_lab_58_1: arg0 = tmp394 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03058_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (tmp395 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: tmp391 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_64_0 ; } __ats_lab_60_1: tmp396 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp397 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp398 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_3) ; tmp399 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp396) ; do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (tmp399 != -1) { goto __ats_lab_62_0 ; } __ats_lab_61_1: arg0 = tmp397 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03058_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (tmp399 != 1) { goto __ats_lab_63_0 ; } __ats_lab_62_1: arg0 = tmp398 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_avl_member_03058_ats_ptr_type ; // tail call break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: // if (tmp399 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_63_1: tmp391 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: tmp391 = ats_false_bool ; break ; } while (0) ; return (tmp391) ; } /* end of [avl_member_03058_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_set_fun.dats: 18362(line=544, offs=25) -- 18400(line=544, offs=63) */ ATSstaticdec() ats_bool_type set_member_03049_ats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp390) ; __ats_lab_set_member_03049_ats_ptr_type: tmp390 = avl_member_03058_ats_ptr_type (arg0, arg1, arg2) ; return (tmp390) ; } /* end of [set_member_03049_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 8260(line=305, offs=26) -- 8304(line=305, offs=70) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_ismem (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp389) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_ismem: tmp389 = set_member_03049_ats_ptr_type (arg0, arg1, &cmp_28) ; return (tmp389) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_ismem] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 8614(line=326, offs=3) -- 8939(line=335, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; // ATSlocal_void (tmp403) ; // ATSlocal_void (tmp404) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make: tmp401 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_4)) ; tmp402 = ats_selsin_mac(tmp401, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp402), atslab_s2Varbound_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp402), atslab_s2Varbound_val) = arg1 ; /* tmp403 = */ atspre_vbox_make_view_ptr (tmp402) ; /* tmp404 = ats_selsin_mac(tmp403, atslab_1) */ ; tmp400 = tmp402 ; return (tmp400) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_make] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 8998(line=337, offs=30) -- 9062(line=338, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_loc: tmp406 = ats_selsin_mac(arg0, atslab_1) ; tmp405 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp406), atslab_s2Varbound_loc) ; return (tmp405) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 9124(line=341, offs=30) -- 9188(line=342, offs=56) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val: tmp408 = ats_selsin_mac(arg0, atslab_1) ; tmp407 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_4, tmp408), atslab_s2Varbound_val) ; return (tmp407) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 9965(line=376, offs=16) -- 10571(line=402, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (atsopt_count_type, tmp411) ; ATSlocal (atsopt_count_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; // ATSlocal_void (tmp419) ; // ATSlocal_void (tmp420) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_srt: tmp411 = atsopt_counter_getinc (statmp409) ; tmp412 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make () ; tmp413 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_5)) ; tmp414 = ats_selsin_mac(tmp413, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_cnt) = tmp411 ; tmp415 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_svar) = tmp415 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_srt) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_equal) = ats_false_bool ; tmp416 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_link) = tmp416 ; tmp417 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_lbs) = tmp417 ; tmp418 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_ubs) = tmp418 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_sVarset) = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp414), atslab_s2Var_stamp) = tmp412 ; /* tmp419 = */ atspre_vbox_make_view_ptr (tmp414) ; /* tmp420 = ats_selsin_mac(tmp419, atslab_1) */ ; tmp410 = tmp414 ; return (tmp410) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 10625(line=404, offs=26) -- 11259(line=431, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (atsopt_count_type, tmp422) ; ATSlocal (atsopt_count_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_var: tmp422 = atsopt_counter_getinc (statmp409) ; tmp423 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__s2Var_stamp_make () ; tmp424 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (arg1) ; tmp425 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_5)) ; tmp426 = ats_selsin_mac(tmp425, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_cnt) = tmp422 ; tmp427 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp427, atslab_0, arg1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_svar) = tmp427 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_srt) = tmp424 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_equal) = ats_false_bool ; tmp428 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_link) = tmp428 ; tmp429 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_lbs) = tmp429 ; tmp430 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_ubs) = tmp430 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_sVarset) = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp426), atslab_s2Var_stamp) = tmp423 ; /* tmp431 = */ atspre_vbox_make_view_ptr (tmp426) ; /* tmp432 = ats_selsin_mac(tmp431, atslab_1) */ ; tmp421 = tmp426 ; return (tmp421) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11333(line=435, offs=25) -- 11390(line=436, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc: tmp434 = ats_selsin_mac(arg0, atslab_1) ; tmp433 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp434), atslab_s2Var_loc) ; return (tmp433) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11442(line=439, offs=25) -- 11499(line=440, offs=50) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_cnt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_cnt: tmp436 = ats_selsin_mac(arg0, atslab_1) ; tmp435 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp436), atslab_s2Var_cnt) ; return (tmp435) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_cnt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11551(line=443, offs=25) -- 11608(line=444, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt: tmp438 = ats_selsin_mac(arg0, atslab_1) ; tmp437 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp438), atslab_s2Var_srt) ; return (tmp437) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11660(line=447, offs=25) -- 11729(line=448, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_srt: tmp440 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp440), atslab_s2Var_srt) = arg1 ; return /* (tmp439) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11782(line=451, offs=26) -- 11840(line=452, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_svar (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_svar: tmp442 = ats_selsin_mac(arg0, atslab_1) ; tmp441 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp442), atslab_s2Var_svar) ; return (tmp441) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_svar] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 11894(line=455, offs=26) -- 11952(line=456, offs=51) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link: tmp444 = ats_selsin_mac(arg0, atslab_1) ; tmp443 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp444), atslab_s2Var_link) ; return (tmp443) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12006(line=459, offs=26) -- 12078(line=460, offs=59) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_link (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_link: tmp446 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp446), atslab_s2Var_link) = arg1 ; return /* (tmp445) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_link] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12131(line=463, offs=25) -- 12188(line=464, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs: tmp448 = ats_selsin_mac(arg0, atslab_1) ; tmp447 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp448), atslab_s2Var_lbs) ; return (tmp447) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12240(line=467, offs=25) -- 12309(line=468, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_lbs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_lbs: tmp450 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp450), atslab_s2Var_lbs) = arg1 ; return /* (tmp449) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_lbs] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12361(line=471, offs=25) -- 12418(line=472, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs: tmp452 = ats_selsin_mac(arg0, atslab_1) ; tmp451 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp452), atslab_s2Var_ubs) ; return (tmp451) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12470(line=475, offs=25) -- 12539(line=476, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_ubs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_ubs: tmp454 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp454), atslab_s2Var_ubs) = arg1 ; return /* (tmp453) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_ubs] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12595(line=479, offs=29) -- 12656(line=480, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_sVarset (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_sVarset: tmp456 = ats_selsin_mac(arg0, atslab_1) ; tmp455 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp456), atslab_s2Var_sVarset) ; return (tmp455) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12716(line=483, offs=29) -- 12789(line=484, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset: tmp458 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp458), atslab_s2Var_sVarset) = arg1 ; return /* (tmp457) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12847(line=487, offs=27) -- 12906(line=488, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_stamp: tmp460 = ats_selsin_mac(arg0, atslab_1) ; tmp459 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp460), atslab_s2Var_stamp) ; return (tmp459) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 12984(line=494, offs=3) -- 13035(line=494, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2Var_s2Var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp461) ; ATSlocal (ats_int_type, tmp462) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2Var_s2Var: tmp462 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (arg0, arg1) ; tmp461 = atspre_ilt (tmp462, 0) ; return (tmp461) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lt_s2Var_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13064(line=496, offs=3) -- 13116(line=496, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2Var_s2Var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp463) ; ATSlocal (ats_int_type, tmp464) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2Var_s2Var: tmp464 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (arg0, arg1) ; tmp463 = atspre_ilte (tmp464, 0) ; return (tmp463) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2Var_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13145(line=499, offs=3) -- 13196(line=499, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp465) ; ATSlocal (ats_int_type, tmp466) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var: tmp466 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (arg0, arg1) ; tmp465 = atspre_ieq (tmp466, 0) ; return (tmp465) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13225(line=501, offs=3) -- 13277(line=501, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2Var_s2Var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp467) ; ATSlocal (ats_int_type, tmp468) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2Var_s2Var: tmp468 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (arg0, arg1) ; tmp467 = atspre_ineq (tmp468, 0) ; return (tmp467) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_s2Var_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13309(line=504, offs=21) -- 13562(line=513, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (atsopt_count_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (atsopt_count_type, tmp473) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var: tmp470 = ats_selsin_mac(arg0, atslab_1) ; tmp471 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp470), atslab_s2Var_stamp) ; tmp472 = ats_selsin_mac(arg1, atslab_1) ; tmp473 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_5, tmp472), atslab_s2Var_stamp) ; tmp469 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp471, tmp473) ; return (tmp469) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13710(line=522, offs=14) -- 13777(line=523, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp474) ; ATSlocal (atsopt_count_type, tmp475) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var: tmp475 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_cnt (arg1) ; /* tmp474 = */ atsopt_fprint_count (arg0, tmp475) ; return /* (tmp474) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13826(line=526, offs=23) -- 13863(line=526, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; // ATSlocal_void (tmp479) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Var: tmp477 = atspre_stdout_get () ; tmp478 = ats_selsin_mac(tmp477, atslab_1) ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (tmp478, arg0) ; /* tmp476 = */ atspre_stdout_view_set () ; return /* (tmp476) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13886(line=527, offs=23) -- 13923(line=527, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; // ATSlocal_void (tmp483) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var: tmp481 = atspre_stderr_get () ; tmp482 = ats_selsin_mac(tmp481, atslab_1) ; /* tmp483 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (tmp482, arg0) ; /* tmp480 = */ atspre_stderr_view_set () ; return /* (tmp480) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 13972(line=532, offs=17) -- 14040(line=533, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp484) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst: /* tmp484 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var) ; return /* (tmp484) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 14095(line=536, offs=26) -- 14137(line=536, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; // ATSlocal_void (tmp488) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Varlst: tmp486 = atspre_stdout_get () ; tmp487 = ats_selsin_mac(tmp486, atslab_1) ; /* tmp488 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst (tmp487, arg0) ; /* tmp485 = */ atspre_stdout_view_set () ; return /* (tmp485) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2Varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 14163(line=537, offs=26) -- 14205(line=537, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Varlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; // ATSlocal_void (tmp492) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Varlst: tmp490 = atspre_stderr_get () ; tmp491 = ats_selsin_mac(tmp490, atslab_1) ; /* tmp492 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varlst (tmp491, arg0) ; /* tmp489 = */ atspre_stderr_view_set () ; return /* (tmp489) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Varlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 14396(line=550, offs=4) -- 14489(line=551, offs=50) */ ATSstaticdec() ats_int_type cmp_89 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp493) ; __ats_lab_cmp_89: tmp493 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__compare_s2Var_s2Var (arg0, arg1) ; return (tmp493) ; } /* end of [cmp_89] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 14826(line=568, offs=6) -- 15119(line=578, offs=6) */ ATSstaticdec() ats_void_type pr_91 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_int_type, tmp498) ; // ATSlocal_void (tmp499) ; ATSlocal (ats_bool_type, tmp500) ; ATSlocal (ats_int_type, tmp501) ; __ats_lab_pr_91: tmp497 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_0) ; tmp498 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_1) ; tmp500 = atspre_gt_int_int (tmp498, 0) ; if (tmp500) { /* tmp499 = */ atspre_fprint_string (tmp497, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp501 = atspre_add_int_int (tmp498, 1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_1) = tmp501 ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Var (tmp497, arg0) ; return /* (tmp496) */ ; } /* end of [pr_91] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 14531(line=556, offs=4) -- 15300(line=587, offs=4) */ ATSstaticdec() ats_void_type fprint_s2Varset_ptr_90 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp494) ; ATSlocal (anairiats_rec_2, tmp495) ; __ats_lab_fprint_s2Varset_ptr_90: /* anairiats_rec_2 tmp495 ; */ ats_select_mac(tmp495, atslab_0) = arg0 ; ats_select_mac(tmp495, atslab_1) = 0 ; /* tmp494 = */ set_foreach_main_03054_ats_ptr_type (arg1, &pr_91, (&tmp495)) ; return /* (tmp494) */ ; } /* end of [fprint_s2Varset_ptr_90] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 15360(line=590, offs=17) -- 15428(line=591, offs=50) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varset (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp502) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varset: /* tmp502 = */ fprint_s2Varset_ptr_90 (arg0, arg1) ; return /* (tmp502) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2Varset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 15520(line=597, offs=14) -- 15564(line=597, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp503) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add: tmp503 = set_insert_03050_ats_ptr_type (arg0, arg1, &cmp_89) ; return (tmp503) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 15589(line=598, offs=25) -- 15714(line=600, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_adds (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_adds: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp505 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp506 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp507 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add (arg0, tmp505) ; arg0 = tmp507 ; arg1 = tmp506 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_adds ; // tail call break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: tmp504 = arg0 ; break ; } while (0) ; return (tmp504) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_adds] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 15765(line=604, offs=14) -- 15809(line=604, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_del (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp508) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_del: tmp508 = set_remove_03051_ats_ptr_type (arg0, arg1, &cmp_89) ; return (tmp508) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_del] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 15834(line=605, offs=25) -- 15959(line=607, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_dels (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_dels: do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp510 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp511 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_del (arg0, tmp510) ; arg0 = tmp512 ; arg1 = tmp511 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_dels ; // tail call break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: tmp509 = arg0 ; break ; } while (0) ; return (tmp509) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_dels] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 16012(line=610, offs=26) -- 16059(line=610, offs=73) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_union (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp513) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_union: tmp513 = set_union_03053_ats_ptr_type (arg0, arg1, &cmp_89) ; return (tmp513) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_union] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_svVar.dats: 16086(line=612, offs=26) -- 16130(line=612, offs=70) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp514) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem: tmp514 = set_member_03049_ats_ptr_type (arg0, arg1, &cmp_89) ; return (tmp514) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_svVar_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp409, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = atsopt_counter_make () ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; statmp409 = atsopt_counter_make () ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil = ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_svVar_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_string_parse_dats.c0000664000175000017500000003064512223166160022627 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_char_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_double_long_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_long_long_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_int_short_short_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_ptr_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_string_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_long_long_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__FAT_c_uint_short_short_14) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_type) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_sint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_usint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ssint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ussint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtype) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type aux_2 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_string_parse.dats: 1679(line=47, offs=29) -- 2412(line=64, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtype: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype () ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype () ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype () ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_t0ype () ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype () ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_sint_t0ype () ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ssint_t0ype () ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 8) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_type () ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)arg0)->tag != 9) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_t0ype () ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 11) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_t0ype () ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 12) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype () ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)arg0)->tag != 13) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_usint_t0ype () ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (((ats_sum_ptr_type)arg0)->tag != 14) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp0 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ussint_t0ype () ; break ; } while (0) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtype] */ /* // /home/hwxi/research/Anairiats/src/ats_string_parse.dats: 2512(line=68, offs=7) -- 2782(line=74, offs=6) */ ATSstaticdec() ats_ptr_type aux_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_aux_2: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtype (tmp3) ; tmp6 = aux_2 (tmp4) ; tmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_0, tmp5) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_1, tmp6) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp2 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp2) ; } /* end of [aux_2] */ /* // /home/hwxi/research/Anairiats/src/ats_string_parse.dats: 2493(line=67, offs=30) -- 2830(line=77, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtypes (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtypes: tmp7 = aux_2 (arg0) ; tmp1 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst (tmp7) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__s2exp_make_printf_c_argtypes] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_string_parse_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_string_parse_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_eff_dats.c0000664000175000017500000014235112223166160023027 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeff_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeffmask_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMlam_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_effect) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect) (ats_int_type) ; ATSextern_val(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; ATSextern_fun(ats_bool_type, atsopt_effset_contain) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_all) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_effvar) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitm) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlstlst) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__effect_env_token = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeff_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeffmask_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMlam_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) ; static ats_void_type aux_4 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ref_make_elt_03684_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type aux_15 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_17 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type aux_19 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_int_type the_effect_env_check_eff_err_18 (ats_int_type arg0) ; static ats_void_type the_effect_env_check_eff_20 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type auxCK_25 (ats_uint_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type auxCK_25_closure_make (ats_uint_type env0) ; static ats_ptr_type auxCK_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_int_type aux_26 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type auxPR_27 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type the_effect_env_check_effset_24 (ats_ptr_type arg0, ats_uint_type arg1) ; static ats_bool_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type the_effect_env_check_sexp_31 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type the_effect_env_check_sexplst_32 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp32) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp34) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 1950(line=59, offs=4) -- 2013(line=59, offs=67) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env_eff)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 2018(line=61, offs=4) -- 2134(line=63, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_1 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1) ; // ATSlocal_void (tmp2) ; __ats_lab_prerr_loc_interror_1: /* tmp2 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp1 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_env_eff)")) ; return /* (tmp1) */ ; } /* end of [prerr_loc_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 2842(line=90, offs=28) -- 3357(line=103, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitm (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp3) ; ATSlocal (ats_int_type, tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; ATSlocal (ats_int_type, tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitm: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("EFFENVeff(")) ; /* tmp6 = */ atsopt_fprint_effect (arg0, tmp4) ; /* tmp3 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp7 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst("EFFENVeffmask(")) ; /* tmp9 = */ atsopt_fprint_effect (arg0, tmp7) ; /* tmp3 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_2_1: tmp10 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst("EFFENVeff(")) ; /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2eff (arg0, tmp10) ; /* tmp3 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp3) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitm] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 3451(line=106, offs=7) -- 3736(line=112, offs=24) */ ATSstaticdec() ats_void_type aux_4 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_bool_type, tmp18) ; // ATSlocal_void (tmp19) ; ATSlocal (ats_int_type, tmp20) ; __ats_lab_aux_4: do { /* branch: __ats_lab_3 */ __ats_lab_3_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp16 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_1) ; tmp18 = atspre_gt_int_int (arg1, 0) ; if (tmp18) { /* tmp17 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitm (arg0, tmp15) ; tmp20 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp20 ; arg2 = tmp16 ; goto __ats_lab_aux_4 ; // tail call break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: break ; } while (0) ; return /* (tmp14) */ ; } /* end of [aux_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 3422(line=105, offs=35) -- 3803(line=116, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlst: /* tmp13 = */ aux_4 (arg0, 0, arg1) ; return /* (tmp13) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 3904(line=119, offs=7) -- 4201(line=125, offs=24) */ ATSstaticdec() ats_void_type aux_6 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_bool_type, tmp26) ; // ATSlocal_void (tmp27) ; ATSlocal (ats_int_type, tmp28) ; __ats_lab_aux_6: do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_0) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_2, arg2, atslab_1) ; tmp26 = atspre_gt_int_int (arg1, 0) ; if (tmp26) { /* tmp25 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; } else { /* empty */ } /* end of [if] */ /* tmp27 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlst (arg0, tmp23) ; tmp28 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp28 ; arg2 = tmp24 ; goto __ats_lab_aux_6 ; // tail call break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: break ; } while (0) ; return /* (tmp22) */ ; } /* end of [aux_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 3874(line=118, offs=38) -- 4269(line=129, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlstlst: /* tmp21 = */ aux_6 (arg0, 0, arg1) ; return /* (tmp21) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__fprint_effenvitmlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03684_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ref_make_elt_03684_ats_ptr_type: /* ats_ptr_type tmp31 ; */ tmp31 = arg0 ; tmp30 = atspre_ref_make_elt_tsz ((&tmp31), sizeof(ats_ptr_type)) ; return (tmp30) ; } /* end of [ref_make_elt_03684_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 4595(line=145, offs=34) -- 4670(line=147, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_lam (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_lam: tmp37 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp37)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp37, atslab_0, arg0) ; tmp38 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp36 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp36, atslab_0, tmp37) ; ats_selptrset_mac(anairiats_sum_2, tmp36, atslab_1, tmp38) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp36 ; return /* (tmp35) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 4740(line=149, offs=34) -- 4813(line=151, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_eff (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_eff: tmp41 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp41)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp41, atslab_0, arg0) ; tmp42 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp40 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_0, tmp41) ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_1, tmp42) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp40 ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_add_eff] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 4879(line=153, offs=30) -- 5222(line=163, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop: tmp44 = ats_ptrget_mac(ats_ptr_type, statmp33) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (tmp44 == (ats_sum_ptr_type)0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_0) ; tmp46 = ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_1) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp45 ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp46 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: // if (tmp44 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_8_1: /* tmp47 = */ prerr_interror_0 () ; /* tmp48 = */ atspre_prerr_string (ATSstrcst(": the_effect_env_pop")) ; /* tmp49 = */ atspre_prerr_newline () ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp43) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 5285(line=165, offs=31) -- 5369(line=168, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push () { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push: tmp52 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp53 = ats_ptrget_mac(ats_ptr_type, statmp33) ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp51, atslab_0, tmp52) ; ats_selptrset_mac(anairiats_sum_2, tmp51, atslab_1, tmp53) ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp51 ; return /* (tmp50) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 5437(line=170, offs=35) -- 5583(line=174, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam: tmp56 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp57 = ats_ptrget_mac(ats_ptr_type, statmp33) ; tmp55 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp55, atslab_0, tmp56) ; ats_selptrset_mac(anairiats_sum_2, tmp55, atslab_1, tmp57) ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp55 ; tmp59 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp59)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp59, atslab_0, arg0) ; tmp60 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp58 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp58, atslab_0, tmp59) ; ats_selptrset_mac(anairiats_sum_2, tmp58, atslab_1, tmp60) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp58 ; return /* (tmp54) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 5657(line=176, offs=37) -- 5848(line=182, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay () { /* local vardec */ // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay: tmp62 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp64 = ats_ptrget_mac(ats_ptr_type, statmp33) ; tmp63 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp63, atslab_0, tmp62) ; ats_selptrset_mac(anairiats_sum_2, tmp63, atslab_1, tmp64) ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp63 ; tmp66 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp66)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp66, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; tmp65 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_0, tmp66) ; ats_selptrset_mac(anairiats_sum_2, tmp65, atslab_1, tmp62) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp65 ; return /* (tmp61) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 6090(line=190, offs=9) -- 6332(line=195, offs=28) */ ATSstaticdec() ats_ptr_type aux_15 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_int_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_aux_15: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp73 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp75 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp75)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp75, atslab_0, tmp72) ; tmp74 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp74, atslab_0, tmp75) ; ats_selptrset_mac(anairiats_sum_2, tmp74, atslab_1, arg1) ; arg0 = tmp73 ; arg1 = tmp74 ; goto __ats_lab_aux_15 ; // tail call break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp71 = arg1 ; break ; } while (0) ; return (tmp71) ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 5943(line=186, offs=35) -- 6421(line=200, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_eff (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_eff: tmp68 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp70 = ats_ptrget_mac(ats_ptr_type, statmp33) ; tmp69 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp69, atslab_0, tmp68) ; ats_selptrset_mac(anairiats_sum_2, tmp69, atslab_1, tmp70) ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp69 ; tmp76 = aux_15 (arg0, tmp68) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp76 ; return /* (tmp67) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_eff] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 6644(line=206, offs=9) -- 6890(line=211, offs=28) */ ATSstaticdec() ats_ptr_type aux_17 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; __ats_lab_aux_17: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp85 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp85)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp85, atslab_0, tmp82) ; tmp84 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp84, atslab_0, tmp85) ; ats_selptrset_mac(anairiats_sum_2, tmp84, atslab_1, arg1) ; arg0 = tmp83 ; arg1 = tmp84 ; goto __ats_lab_aux_17 ; // tail call break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp81 = arg1 ; break ; } while (0) ; return (tmp81) ; } /* end of [aux_17] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 6497(line=202, offs=39) -- 6979(line=216, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask: tmp78 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp80 = ats_ptrget_mac(ats_ptr_type, statmp33) ; tmp79 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp79, atslab_0, tmp78) ; ats_selptrset_mac(anairiats_sum_2, tmp79, atslab_1, tmp80) ; ats_ptrget_mac(ats_ptr_type, statmp33) = tmp79 ; tmp86 = aux_17 (arg0, tmp78) ; ats_ptrget_mac(ats_ptr_type, statmp29) = tmp86 ; return /* (tmp77) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 7269(line=228, offs=7) -- 7832(line=242, offs=23) */ ATSstaticdec() ats_int_type aux_19 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_int_type, tmp91) ; ATSlocal (ats_bool_type, tmp92) ; ATSlocal (ats_int_type, tmp93) ; ATSlocal (ats_bool_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_bool_type, tmp96) ; __ats_lab_aux_19: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_13_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp89)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_0, tmp89, atslab_0) ; tmp92 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect (arg0, tmp91) ; if (tmp92) { tmp88 = 1 ; } else { arg0 = arg0 ; arg1 = tmp90 ; goto __ats_lab_aux_19 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp89)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_0, tmp89, atslab_0) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect (arg0, tmp93) ; if (tmp94) { tmp88 = 0 ; } else { arg0 = arg0 ; arg1 = tmp90 ; goto __ats_lab_aux_19 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (((ats_sum_ptr_type)tmp89)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp95 = ats_caselptrlab_mac(anairiats_sum_1, tmp89, atslab_0) ; tmp96 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff (tmp95, arg0) ; if (tmp96) { tmp88 = 0 ; } else { tmp88 = 1 ; } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp88 = 0 ; break ; } while (0) ; return (tmp88) ; } /* end of [aux_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 7084(line=222, offs=4) -- 7881(line=246, offs=4) */ ATSstaticdec() ats_int_type the_effect_env_check_eff_err_18 (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp87) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_the_effect_env_check_eff_err_18: tmp97 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp87 = aux_19 (arg0, tmp97) ; return (tmp87) ; } /* end of [the_effect_env_check_eff_err_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 7923(line=248, offs=4) -- 8258(line=259, offs=4) */ ATSstaticdec() ats_void_type the_effect_env_check_eff_20 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_bool_type, tmp99) ; ATSlocal (ats_int_type, tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; // ATSlocal_void (tmp103) ; // ATSlocal_void (tmp104) ; // ATSlocal_void (tmp105) ; // ATSlocal_void (tmp106) ; __ats_lab_the_effect_env_check_eff_20: tmp100 = the_effect_env_check_eff_err_18 (arg1) ; tmp99 = atspre_gt_int_int (tmp100, 0) ; if (tmp99) { /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp102 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp103 = */ atspre_prerr_string (ATSstrcst(": the effect [")) ; /* tmp104 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect (arg1) ; /* tmp105 = */ atspre_prerr_string (ATSstrcst("] is disallowed.")) ; /* tmp106 = */ atspre_prerr_newline () ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp98) */ ; } /* end of [the_effect_env_check_eff_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 8332(line=261, offs=36) -- 8391(line=262, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn: /* tmp107 = */ the_effect_env_check_eff_20 (arg0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; return /* (tmp107) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 8428(line=264, offs=36) -- 8487(line=265, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ntm (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ntm: /* tmp108 = */ the_effect_env_check_eff_20 (arg0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm) ; return /* (tmp108) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ntm] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 8524(line=267, offs=36) -- 8583(line=268, offs=51) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref: /* tmp109 = */ the_effect_env_check_eff_20 (arg0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; return /* (tmp109) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 8667(line=274, offs=7) -- 9105(line=286, offs=6) */ ATSstaticdec() ats_ptr_type auxCK_25 (ats_uint_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_int_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_bool_type, tmp114) ; ATSlocal (ats_int_type, tmp115) ; ATSlocal (ats_bool_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_auxCK_25: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp112 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp114 = atsopt_effset_contain (env0, tmp112) ; if (tmp114) { tmp115 = the_effect_env_check_eff_err_18 (tmp112) ; tmp116 = atspre_gt_int_int (tmp115, 0) ; if (tmp116) { tmp117 = auxCK_25 (env0, tmp113) ; tmp111 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp111, atslab_0, tmp112) ; ats_selptrset_mac(anairiats_sum_3, tmp111, atslab_1, tmp117) ; } else { arg0 = tmp113 ; goto __ats_lab_auxCK_25 ; // tail call } /* end of [if] */ } else { arg0 = tmp113 ; goto __ats_lab_auxCK_25 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp111 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp111) ; } /* end of [auxCK_25] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_uint_type closure_env_0 ; } auxCK_25_closure_type ; ats_ptr_type auxCK_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return auxCK_25 (((auxCK_25_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type auxCK_25_closure_init (auxCK_25_closure_type *p_clo, ats_uint_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxCK_25_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxCK_25_closure_make (ats_uint_type env0) { auxCK_25_closure_type *p_clo = ATS_MALLOC(sizeof(auxCK_25_closure_type)) ; auxCK_25_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 9238(line=289, offs=9) -- 9347(line=290, offs=62) */ ATSstaticdec() ats_int_type aux_26 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; __ats_lab_aux_26: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp120 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp121 = atspre_add_int_int (arg1, 1) ; arg0 = tmp120 ; arg1 = tmp121 ; goto __ats_lab_aux_26 ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp119 = arg1 ; break ; } while (0) ; return (tmp119) ; } /* end of [aux_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 9376(line=292, offs=7) -- 9580(line=297, offs=24) */ ATSstaticdec() ats_void_type auxPR_27 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp123) ; ATSlocal (ats_int_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; // ATSlocal_void (tmp126) ; ATSlocal (ats_bool_type, tmp127) ; // ATSlocal_void (tmp128) ; ATSlocal (ats_int_type, tmp129) ; __ats_lab_auxPR_27: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp124 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp125 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp127 = atspre_gt_int_int (arg0, 0) ; if (tmp127) { /* tmp126 = */ atspre_prerr_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp128 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect (tmp124) ; tmp129 = atspre_add_int_int (arg0, 1) ; arg0 = tmp129 ; arg1 = tmp125 ; goto __ats_lab_auxPR_27 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: break ; } while (0) ; return /* (tmp123) */ ; } /* end of [auxPR_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 8592(line=272, offs=4) -- 9972(line=310, offs=4) */ ATSstaticdec() ats_void_type the_effect_env_check_effset_24 (ats_ptr_type arg0, ats_uint_type arg1) { /* local vardec */ // ATSlocal_void (tmp110) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_int_type, tmp122) ; // ATSlocal_void (tmp130) ; ATSlocal (ats_bool_type, tmp131) ; // ATSlocal_void (tmp132) ; // ATSlocal_void (tmp133) ; ATSlocal (ats_bool_type, tmp134) ; // ATSlocal_void (tmp135) ; ATSlocal (ats_bool_type, tmp136) ; ATSlocal (ats_bool_type, tmp137) ; // ATSlocal_void (tmp138) ; ATSlocal (ats_bool_type, tmp139) ; // ATSlocal_void (tmp140) ; __ats_lab_the_effect_env_check_effset_24: tmp118 = auxCK_25 (arg1, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; tmp122 = aux_26 (tmp118, 0) ; tmp131 = atspre_gt_int_int (tmp122, 0) ; if (tmp131) { /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp133 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; tmp134 = atspre_lte_int_int (tmp122, 1) ; if (tmp134) { /* tmp130 = */ atspre_prerr_string (ATSstrcst(": the effect [")) ; } else { /* tmp130 = */ atspre_prerr_string (ATSstrcst(": the effects [")) ; } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp136 = atspre_gt_int_int (tmp122, 0) ; if (tmp136) { /* tmp135 = */ auxPR_27 (0, tmp118) ; } else { /* empty */ } /* end of [if] */ tmp137 = atspre_gt_int_int (tmp122, 0) ; if (tmp137) { tmp139 = atspre_lte_int_int (tmp122, 1) ; if (tmp139) { /* tmp138 = */ atspre_prerr_string (ATSstrcst("] is disallowed.")) ; } else { /* tmp138 = */ atspre_prerr_string (ATSstrcst("] are disallowed.")) ; } /* end of [if] */ /* tmp140 = */ atspre_prerr_newline () ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp110) */ ; } /* end of [the_effect_env_check_effset_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 10049(line=312, offs=36) -- 10111(line=313, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_all (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_all: /* tmp141 = */ the_effect_env_check_effset_24 (arg0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; return /* (tmp141) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_all] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 10297(line=323, offs=7) -- 10619(line=330, offs=26) */ ATSstaticdec() ats_bool_type aux_30 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_aux_30: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_24_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp144)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp143 = ats_false_bool ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp144)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: arg0 = arg0 ; arg1 = tmp145 ; goto __ats_lab_aux_30 ; // tail call break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: // if (((ats_sum_ptr_type)tmp144)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_27_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_1, tmp144, atslab_0) ; tmp143 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar (tmp146, arg0) ; break ; } while (0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp143 = ats_true_bool ; break ; } while (0) ; return (tmp143) ; } /* end of [aux_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 10155(line=317, offs=39) -- 10845(line=339, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_effvar (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp142) ; ATSlocal (ats_bool_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_effvar: tmp148 = ats_ptrget_mac(ats_ptr_type, statmp29) ; tmp147 = aux_30 (arg1, tmp148) ; if (tmp147) { /* empty */ } else { /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp150 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp151 = */ atspre_prerr_string (ATSstrcst(": the effect [")) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2var (arg1) ; /* tmp153 = */ atspre_prerr_string (ATSstrcst("] is disallowed")) ; /* tmp154 = */ atspre_prerr_newline () ; /* tmp142 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp142) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_effvar] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 10891(line=341, offs=5) -- 11320(line=352, offs=4) */ ATSstaticdec() ats_void_type the_effect_env_check_sexp_31 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; __ats_lab_the_effect_env_check_sexp_31: tmp156 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp157 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp156), atslab_s2exp_node) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp157)->tag != 7) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_0) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff (arg0, tmp158) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp157)->tag != 32) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_0) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_effvar (arg0, tmp159) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: /* tmp160 = */ prerr_loc_interror_1 (arg0) ; /* tmp161 = */ atspre_prerr_string (ATSstrcst(": the_effect_env_check_s2exp: s2e0 = ")) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp156) ; /* tmp163 = */ atspre_prerr_newline () ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp155) */ ; } /* end of [the_effect_env_check_sexp_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 11364(line=354, offs=5) -- 11638(line=362, offs=4) */ ATSstaticdec() ats_void_type the_effect_env_check_sexplst_32 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; __ats_lab_the_effect_env_check_sexplst_32: do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp165 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp166 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; /* tmp167 = */ the_effect_env_check_sexp_31 (arg0, tmp165) ; arg0 = arg0 ; arg1 = tmp166 ; goto __ats_lab_the_effect_env_check_sexplst_32 ; // tail call break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: break ; } while (0) ; return /* (tmp164) */ ; } /* end of [the_effect_env_check_sexplst_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_eff.dats: 11717(line=364, offs=37) -- 12097(line=378, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp168) ; ATSlocal (ats_uint_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; // ATSlocal_void (tmp171) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff: do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_all (arg0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_36_0 ; } __ats_lab_35_1: break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp170 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; /* tmp171 = */ the_effect_env_check_effset_24 (arg0, tmp169) ; /* tmp168 = */ the_effect_env_check_sexplst_32 (arg0, tmp170) ; break ; } while (0) ; return /* (tmp168) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeff_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMeffmask_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__EFFENVITEMlam_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_eff_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp32, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp34, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp32 = (ats_sum_ptr_type)0 ; statmp29 = ref_make_elt_03684_ats_ptr_type (statmp32) ; statmp34 = (ats_sum_ptr_type)0 ; statmp33 = ref_make_elt_03684_ats_ptr_type (statmp34) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_eff_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_solver_fm.cats0000664000175000017500000001352212223166160021613 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // February 2008 /* ****** ****** */ // // HX: ats_solver_fm: // A solver based on the FM approach for linear constraints // /* ****** ****** */ #ifndef ATS_SRC_SOLVER_FM_CATS #define ATS_SRC_SOLVER_FM_CATS /* ****** ****** */ #include "ats_intinf.cats" /* ****** ****** */ ATSinline() ats_int_type atsopt_solver_fm_i0nt_of_int (ats_int_type i) { return (i) ; } // end of [atsopt_solver_fm_i0nt_of_int] ATSinline() ats_int_type atsopt_solver_fm_i0nt_of_intinf (ats_mpz_ptr_type i) { return atsopt_get_int (i) ; } // end of [atsopt_solver_fm_i0nt_of_intinf] /* ****** ****** */ ATSinline() ats_bool_type atsopt_solver_fm_gt_i0nt_int (ats_int_type i0, ats_int_type i) { return (i0 > i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_gt_i0nt_int] ATSinline() ats_bool_type atsopt_solver_fm_gte_i0nt_int ( ats_int_type i0, ats_int_type i ) { return (i0 >= i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_gte_i0nt_int] ATSinline() ats_bool_type atsopt_solver_fm_lt_i0nt_int ( ats_int_type i0, ats_int_type i ) { return (i0 < i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_lt_i0nt_int] ATSinline() ats_bool_type atsopt_solver_fm_lte_i0nt_int ( ats_int_type i0, ats_int_type i ) { return (i0 <= i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_lte_i0nt_int] ATSinline() ats_bool_type atsopt_solver_fm_eq_i0nt_int ( ats_int_type i0, ats_int_type i ) { return (i0 == i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_eq_i0nt_int] ATSinline() ats_bool_type atsopt_solver_fm_neq_i0nt_int ( ats_int_type i0, ats_int_type i ) { return (i0 != i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_neq_i0nt_int] // ATSinline() ats_bool_type atsopt_solver_fm_gt_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 > i2 ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_gt_i0nt_i0nt] ATSinline() ats_bool_type atsopt_solver_fm_lt_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 < i2 ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_solver_fm_lt_i0nt_i0nt] // ATSinline() ats_int_type atsopt_solver_fm_neg_i0nt (ats_int_type i) { return (-i) ; } // end of [atsopt_solver_fm_neg_i0nt] ATSinline() ats_int_type atsopt_solver_fm_add_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 + i2) ; } // end of [atsopt_solver_fm_add_i0nt_i0nt] ATSinline() ats_int_type atsopt_solver_fm_sub_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 - i2) ; } // end of [atsopt_solver_fm_sub_i0nt_i0nt] ATSinline() ats_int_type atsopt_solver_fm_mul_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 * i2) ; } // end of [atsopt_solver_fm_mul_i0nt_i0nt] ATSinline() ats_int_type atsopt_solver_fm_div_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { return (i1 / i2) ; } // end of [atsopt_solver_fm_div_i0nt_i0nt] // ATSinline() ats_int_type atsopt_solver_fm_succ_i0nt (ats_int_type i) { return (i + 1) ; } // end of [atsopt_solver_fm_succ_i0nt] ATSinline() ats_int_type atsopt_solver_fm_pred_i0nt (ats_int_type i) { return (i - 1) ; } // end of [atsopt_solver_fm_pred_i0nt] // ATSinline() ats_int_type atsopt_solver_fm_mod_i0nt_i0nt (ats_int_type i1, ats_int_type i2) { return (i1 % i2) ; } // end of [atsopt_solver_fm_mod_i0nt_i0nt] ATSinline() ats_int_type atsopt_solver_fm_gcd_i0nt_i0nt ( ats_int_type i1, ats_int_type i2 ) { int tmp ; if (i1 < 0) i1 = -i1 ; if (i2 < 0) i2 = -i2 ; while (1) { if (i2 == 0) return i1; tmp = i1 % i2 ; i1 = i2 ; i2 = tmp ; } return 0 ; /* deadcode */ } // end of [atsopt_solver_fm_gcd_i0nt_i0nt] // ATSinline() ats_void_type atsopt_solver_fm_fprint_i0nt (ats_ptr_type out, ats_int_type i) { fprintf ((FILE *)out, "%i", i) ; return ; } // end of [atsopt_solver_fm_fprint_i0nt] /* ****** ****** */ ATSinline() ats_ptr_type atsopt_solver_fm_intvecptr_make_view_ptr (ats_ptr_type p) { return p ; } // end of [atsopt_solver_fm_intvecptr_make_view_ptr] ATSinline() ats_void_type atsopt_solver_fm_intvecptr_free (ats_ptr_type p) { ATS_FREE (p) ; return ; } /* ****** ****** */ ATSinline() ats_ptr_type atsopt_solver_fm_intvec_ptr_make (ats_int_type n) { int *p ; int nbytes = n * sizeof(ats_int_type) ; p = ATS_MALLOC (nbytes) ; return memset (p, 0, nbytes) ; } // end of [atsopt_solver_fm_intvec_ptr_make] /* ****** ****** */ #endif // ATS_SRC_SOLVER_FM_CATS /* end of [ats_solver_fm.cats] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_exp_up_dats.c0000664000175000017500000110206612223166160022717 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_d2lab_loc ; ats_ptr_type atslab_d2lab_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_d3lab0_loc ; ats_ptr_type atslab_d3lab0_node ; } anairiats_rec_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_11 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_14 ; typedef struct { ats_ptr_type atslab_s2exparg_loc ; ats_ptr_type atslab_s2exparg_node ; } anairiats_rec_15 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_rec_16 ; typedef struct { anairiats_rec_16 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_rec_18 ; typedef struct { anairiats_rec_18 atslab_0 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_20 ; typedef struct { ats_ptr_type atslab_d2sym_loc ; ats_ptr_type atslab_d2sym_qua ; ats_ptr_type atslab_d2sym_sym ; ats_ptr_type atslab_d2sym_itm ; } anairiats_rec_21 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_24 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_25 ; typedef struct { anairiats_rec_25 atslab_0 ; } anairiats_sum_26 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_27 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_28 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_29 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_30 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_31 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_32 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_33 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_34 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_35 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_36 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_37 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDfloat_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_long_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDnone_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDlint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDulint_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDllint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDullint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Edynload_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloatsp_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eintsp_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALarrsub_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALptr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_lin_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_mut_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALnone_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed2exp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed3exp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGdyn_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int1_of_size1) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__deadcode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc) (ats_ptr_type, ats_bool_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec) (ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_fun_arg) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_slablst_restlin_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type, ats_ref_type) ; ATSextern_fun(anairiats_rec_2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve_at) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_arg_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_varlamcst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_cross) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_decode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_float_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_intinf_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_intinf_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_intinf_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_uni) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_t0ype_int_type) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_viewt0ype_int_viewtype) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_t0ype_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_viewt0ype_viewtype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_t0ype_type) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_viewt0ype_viewtype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ats_dynexp3_d3exp_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ann_type) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrpsz) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_bool) (ats_ptr_type, ats_ptr_type, ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_char) (ats_ptr_type, ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_con) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cstsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_dynload) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_fix) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_floatsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_foldat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_freeat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_extval) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_intsp) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_laminit_dyn) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_met) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_sta) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_delay) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_ldelay) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lst) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_raise) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_ptr) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_where) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_lab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_ind) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_lab) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_ind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_push) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try) () ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_s2eff_of_d2exp) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__fshowtype_d3exp) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_up) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_3, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loopexn_tr_up) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn) (ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn) (ats_ptr_type, ats_ref_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_assgn_tr_up) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_tr_up) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_intkind_eval) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atsopt_floatkind_eval) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed2exp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed3exp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGsta_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGdyn_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_void_type pfarity_check_fun_3 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) ; static ats_ptr_type d2lab_tr_up_4 (ats_ptr_type arg0) ; static ats_ptr_type d2lablst_tr_up_5 (ats_ptr_type arg0) ; static ats_ptr_type s2lab0lst_of_d3lab0lst_6 (ats_ptr_type arg0) ; static ats_ptr_type d3lab1lst_of_d3lab0lst_s2lablst_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3exp_clo_restore_8 (ats_ptr_type arg0) ; static ats_ptr_type d3exp_funclo_restore_9 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3explst_arg_restore_10 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d23explst_tr_up_11 (ats_ptr_type arg0) ; static ats_ptr_type aux_13 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d23explst_tr_dn_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2explst_arg_tr_up_14 (ats_ptr_type arg0) ; static ats_void_type d23explst_open_and_add_15 (ats_ptr_type arg0) ; static ats_ptr_type aux_17 (ats_ptr_type env0, ats_int_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_17_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_17_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d23exp_app_tr_up_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d2exp_apps_tr_up_18 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_apps_sta_tr_up_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_apps_dyn_tr_up_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type fprint_xyz_22 (ats_ref_type arg0, anairiats_rec_16 arg1) ; static ats_void_type print_xyz_23 (anairiats_rec_16 arg0) ; static ats_void_type prerr_xyz_24 (anairiats_rec_16 arg0) ; static ats_ptr_type aux_26 (ats_ptr_type arg0) ; static ats_void_type fprint_xyz_root_25 (ats_ref_type arg0, anairiats_rec_16 arg1) ; static ats_void_type print_xyz_root_27 (anairiats_rec_16 arg0) ; static ats_void_type prerr_xyz_root_28 (anairiats_rec_16 arg0) ; static ats_ptr_type d2exp_item_tr_up_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2kexplst_make_d3explst_30 (ats_ptr_type arg0) ; static ats_ptr_type aux_filter_31 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_select0_32 (ats_ptr_type arg0) ; static ats_ptr_type aux1_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type err_nil_35 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type err_nil_35_closure_make () ; static ats_ptr_type err_nil_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type err_cons_cons_36 (ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_16 arg2, anairiats_rec_16 arg3) ; static ats_clo_ptr_type err_cons_cons_36_closure_make () ; static ats_ptr_type err_cons_cons_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_16 arg2, anairiats_rec_16 arg3) ; static ats_ptr_type aux2_34 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_bool_type aux3_37 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux3_app_38 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_bool_type aux3_37_0aux3_app_38 (ats_int_type arg0, ...) ; static ats_ptr_type aux_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d2exp_apps_sym_tr_up_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_assgn_tr_up_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d3exp_s2exp_lazy_force_tr_up_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_deref_tr_up_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_con_tr_up_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) ; static ats_ptr_type d2exp_decrypt_tr_up_46 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_encrypt_tr_up_47 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_crypt_tr_up_48 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_50 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type auxlst_51 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_foldat_freeat_tr_up_49 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d2exp_foldat_tr_up_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_freeat_tr_up_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static anairiats_rec_2 d2exp_arg_body_tr_up_54 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type d2exp_lazy_delay_tr_up_55 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d2exp_lazy_ldelay_tr_up_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_ptrof_tr_up_57 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type d3exp_nonlin_check_58 (ats_ptr_type arg0) ; static ats_void_type labd3explst_nonlin_check_59 (ats_ptr_type arg0) ; static ats_ptr_type aux_61 (ats_ptr_type arg0) ; static ats_ptr_type d2exp_rec_tr_up_60 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d3exp_sel_tr_up_62 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2exp_sel_tr_up_63 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) ; static ats_ptr_type d2exp_seq_tr_up_64 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_67 (ats_ptr_type arg0) ; static ats_ptr_type d2exp_tmpid_tr_up_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d2explst_elt_tr_dn_70 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_75 (ats_ptr_type arg0) ; static ats_ptr_type d2exp_var_mut_tr_up_76 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_78 (ats_ptr_type arg0) ; static ats_ptr_type d2exp_var_nonmut_tr_up_77 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 2369(line=82, offs=4) -- 2454(line=83, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 2488(line=86, offs=4) -- 2550(line=86, offs=66) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_exp_up)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 2555(line=88, offs=4) -- 2670(line=90, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_exp_up)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 2819(line=98, offs=4) -- 3146(line=109, offs=6) */ ATSstaticdec() ats_void_type pfarity_check_fun_3 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp5) ; ATSlocal (ats_bool_type, tmp6) ; // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; __ats_lab_pfarity_check_fun_3: tmp6 = atspre_eq_int_int (arg1, arg2) ; if (tmp6) { /* empty */ } else { /* tmp7 = */ prerr_loc_error3_0 (arg0) ; /* tmp8 = */ atspre_prerr_string (ATSstrcst(": the proof arity of the function is [")) ; /* tmp9 = */ atspre_prerr_int (arg1) ; /* tmp10 = */ atspre_prerr_string (ATSstrcst("] but it is expected to be [")) ; /* tmp11 = */ atspre_prerr_int (arg2) ; /* tmp12 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp13 = */ atspre_prerr_newline () ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ return /* (tmp5) */ ; } /* end of [pfarity_check_fun_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 3217(line=114, offs=4) -- 3399(line=117, offs=48) */ ATSstaticdec() ats_ptr_type d2lab_tr_up_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_d2lab_tr_up_4: tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d2lab_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp15)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_5, tmp15, atslab_0) ; tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d2lab_loc) ; tmp18 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up (tmp16) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_ind (tmp17, tmp18) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (((ats_sum_ptr_type)tmp15)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp19 = ats_caselptrlab_mac(anairiats_sum_5, tmp15, atslab_0) ; tmp20 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_d2lab_loc) ; tmp14 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab0_lab (tmp20, tmp19) ; break ; } while (0) ; return (tmp14) ; } /* end of [d2lab_tr_up_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 3429(line=120, offs=5) -- 3630(line=125, offs=31) */ ATSstaticdec() ats_ptr_type d2lablst_tr_up_5 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_d2lablst_tr_up_5: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp24 = d2lab_tr_up_4 (tmp22) ; tmp25 = d2lablst_tr_up_5 (tmp23) ; tmp21 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp21, atslab_0, tmp24) ; ats_selptrset_mac(anairiats_sum_6, tmp21, atslab_1, tmp25) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp21 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp21) ; } /* end of [d2lablst_tr_up_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 3663(line=128, offs=5) -- 4104(line=143, offs=4) */ ATSstaticdec() ats_ptr_type s2lab0lst_of_d3lab0lst_6 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_s2lab0lst_of_d3lab0lst_6: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_4_1: tmp27 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp27), atslab_d3lab0_node) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp30)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_5, tmp30, atslab_0) ; tmp32 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind (tmp31) ; tmp29 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp29)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp29, atslab_0, tmp32) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (((ats_sum_ptr_type)tmp30)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_5, tmp30, atslab_0) ; tmp29 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp29)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp29, atslab_0, tmp33) ; break ; } while (0) ; tmp34 = s2lab0lst_of_d3lab0lst_6 (tmp28) ; tmp26 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp26, atslab_0, tmp29) ; ats_selptrset_mac(anairiats_sum_6, tmp26, atslab_1, tmp34) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp26 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp26) ; } /* end of [s2lab0lst_of_d3lab0lst_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 4720(line=168, offs=5) -- 6256(line=208, offs=4) */ ATSstaticdec() ats_ptr_type d3lab1lst_of_d3lab0lst_s2lablst_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; // ATSlocal_void (tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; // ATSlocal_void (tmp58) ; __ats_lab_d3lab1lst_of_d3lab0lst_s2lablst_7: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_8_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_16_1 ; } __ats_lab_8_2: tmp36 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp37 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp38 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp41 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp36), atslab_d3lab0_node) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp41)->tag != 1) { goto __ats_lab_12_0 ; } __ats_lab_9_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_5, tmp41, atslab_0) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp38)->tag != 3) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_8, tmp38, atslab_1) ; tmp44 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp36), atslab_d3lab0_loc) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_ind (tmp44, tmp42, tmp43) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: /* tmp45 = */ prerr_interror_1 () ; /* tmp46 = */ atspre_prerr_string (ATSstrcst(": d3lab1lst_of_d3lab0lst_s2lablst: D3LAB0ind")) ; /* tmp47 = */ atspre_prerr_newline () ; /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (((ats_sum_ptr_type)tmp41)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp38)->tag != 2) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_8, tmp38, atslab_0) ; tmp49 = ats_caselptrlab_mac(anairiats_sum_8, tmp38, atslab_1) ; tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp36), atslab_d3lab0_loc) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3lab1_lab (tmp50, tmp48, tmp49) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: /* tmp51 = */ prerr_interror_1 () ; /* tmp52 = */ atspre_prerr_string (ATSstrcst(": d3lab1lst_of_d3lab0lst_s2lablst: D3LAB0lab: s2l = ")) ; /* tmp53 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2lab (tmp38) ; /* tmp54 = */ atspre_prerr_newline () ; /* tmp40 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; tmp55 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp37, tmp39) ; tmp35 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp35, atslab_0, tmp40) ; ats_selptrset_mac(anairiats_sum_6, tmp35, atslab_1, tmp55) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_16_1 ; } __ats_lab_15_2: tmp35 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: __ats_lab_16_2: /* tmp56 = */ prerr_interror_1 () ; /* tmp57 = */ atspre_prerr_string (ATSstrcst(": d3lab1lst_of_d3lab0lst_s2lablst: length mismatch")) ; /* tmp58 = */ atspre_prerr_newline () ; /* tmp35 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp35) ; } /* end of [d3lab1lst_of_d3lab0lst_s2lablst_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 6326(line=212, offs=4) -- 7629(line=246, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_clo_restore_8 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_int_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_bool_type, tmp71) ; ATSlocal (ats_bool_type, tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; ATSlocal (ats_int_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; __ats_lab_d3exp_clo_restore_8: tmp60 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_loc) ; tmp61 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_typ) ; /* ats_ptr_type tmp62 ; */ tmp62 = (ats_sum_ptr_type)0 ; tmp64 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp61), atslab_s2exp_node) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp64)->tag != 11) { goto __ats_lab_21_0 ; } __ats_lab_17_1: tmp65 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_0) ; tmp66 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_1) ; tmp67 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_2) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_3) ; tmp69 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_4) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_11, tmp64, atslab_5) ; tmp62 = tmp65 ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp71 = atspre_eq_int_int (tmp66, 1) ; if (!tmp71) { goto __ats_lab_19_1 ; } tmp63 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, tmp65, -1, tmp67, tmp68, tmp69, tmp70) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp72 = atspre_eq_int_int (tmp66, 0) ; if (!tmp72) { goto __ats_lab_20_1 ; } tmp63 = tmp61 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: /* tmp73 = */ prerr_loc_error3_0 (tmp60) ; /* tmp74 = */ atspre_prerr_string (ATSstrcst(": a linear function cannot be applied repeatedly.")) ; /* tmp75 = */ atspre_prerr_newline () ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: /* tmp76 = */ prerr_loc_interror_2 (tmp60) ; /* tmp77 = */ atspre_prerr_string (ATSstrcst(": d3exp_clo_restore: s2e_fun = ")) ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp61) ; /* tmp79 = */ atspre_prerr_newline () ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (tmp62 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_12, tmp62, atslab_0) ; tmp82 = atspre_eq_int_int (tmp81, 0) ; if (tmp82) { tmp80 = 1 ; } else { tmp80 = 0 ; } /* end of [if] */ break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (tmp62 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp80 = 0 ; break ; } while (0) ; tmp83 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg (tmp80, arg0, tmp63) ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg (tmp60, tmp63, tmp80, tmp83, arg0) ; return (tmp59) ; } /* end of [d3exp_clo_restore_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 7724(line=254, offs=4) -- 8000(line=261, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_funclo_restore_9 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; ATSlocal (ats_bool_type, tmp86) ; __ats_lab_d3exp_funclo_restore_9: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp85 = ats_caselptrlab_mac(anairiats_sum_12, arg0, atslab_0) ; tmp86 = atspre_gte_int_int (tmp85, 0) ; if (tmp86) { tmp84 = d3exp_clo_restore_8 (arg1) ; } else { tmp84 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp84 = arg1 ; break ; } while (0) ; return (tmp84) ; } /* end of [d3exp_funclo_restore_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 8046(line=265, offs=5) -- 9415(line=300, offs=4) */ ATSstaticdec() ats_ptr_type d3explst_arg_restore_10 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_int_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_int_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_d3explst_arg_restore_10: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_0) ; tmp89 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_1) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_2) ; if (arg0 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 8376(line=274, offs=12) -- 8404(line=274, offs=40)") ; } tmp91 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp92 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp91), atslab_d3exp_loc) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp93, tmp89) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ_arg (tmp88, tmp91, tmp94) ; tmp96 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_refarg (tmp93, tmp94, tmp88, tmp95, tmp91) ; tmp97 = d3explst_arg_restore_10 (tmp92, tmp90) ; tmp87 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp87, atslab_0, tmp96) ; ats_selptrset_mac(anairiats_sum_6, tmp87, atslab_1, tmp97) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; if (arg0 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 9243(line=295, offs=12) -- 9271(line=295, offs=40)") ; } tmp99 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp100 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp101 = d3explst_arg_restore_10 (tmp100, tmp98) ; tmp87 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp87, atslab_0, tmp99) ; ats_selptrset_mac(anairiats_sum_6, tmp87, atslab_1, tmp101) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: tmp87 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp87) ; } /* end of [d3explst_arg_restore_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 9568(line=308, offs=5) -- 9885(line=318, offs=21) */ ATSstaticdec() ats_ptr_type d23explst_tr_up_11 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_d23explst_tr_up_11: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_32_0 ; } __ats_lab_29_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp103)->tag != 0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_5, tmp103, atslab_0) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp106) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (((ats_sum_ptr_type)tmp103)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_5, tmp103, atslab_0) ; tmp105 = tmp107 ; break ; } while (0) ; tmp108 = d23explst_tr_up_11 (tmp104) ; tmp102 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp102, atslab_0, tmp105) ; ats_selptrset_mac(anairiats_sum_6, tmp102, atslab_1, tmp108) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp102 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp102) ; } /* end of [d23explst_tr_up_11] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 10037(line=324, offs=7) -- 10530(line=338, offs=8) */ ATSstaticdec() ats_ptr_type aux_13 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; // ATSlocal_void (tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_aux_13: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp113 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp115 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2exp_refarg_arg (tmp113) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp111)->tag != 0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp117 = ats_caselptrlab_mac(anairiats_sum_5, tmp111, atslab_0) ; tmp116 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp117, tmp115) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (((ats_sum_ptr_type)tmp111)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_5, tmp111, atslab_0) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_tr_dn (tmp118, tmp115) ; tmp116 = tmp118 ; break ; } while (0) ; tmp120 = aux_13 (tmp112, tmp114) ; tmp110 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp110, atslab_0, tmp116) ; ats_selptrset_mac(anairiats_sum_6, tmp110, atslab_1, tmp120) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp110 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp110) ; } /* end of [aux_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 9934(line=321, offs=4) -- 11165(line=357, offs=4) */ ATSstaticdec() ats_ptr_type d23explst_tr_dn_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_int_type, tmp121) ; // ATSlocal_void (tmp122) ; ATSlocal (ats_bool_type, tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; ATSlocal (ats_bool_type, tmp127) ; // ATSlocal_void (tmp128) ; ATSlocal (ats_bool_type, tmp129) ; // ATSlocal_void (tmp130) ; // ATSlocal_void (tmp131) ; ATSlocal (ats_bool_type, tmp132) ; __ats_lab_d23explst_tr_dn_12: tmp121 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (arg1, arg2) ; tmp123 = atspre_ineq (tmp121, 0) ; if (tmp123) { /* tmp124 = */ prerr_loc_error3_0 (arg0) ; /* tmp125 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d23explst_tr_dn"), ATSstrcst("ats_trans3_exp_up.dats")) ; tmp127 = atspre_igt (tmp121, 0) ; if (tmp127) { /* tmp126 = */ atspre_prerr_string (ATSstrcst(": arity mismatch: fewer arguments are needed.")) ; } else { /* empty */ } /* end of [if] */ tmp129 = atspre_ilt (tmp121, 0) ; if (tmp129) { /* tmp128 = */ atspre_prerr_string (ATSstrcst(": arity mismatch: more arguments are needed.")) ; } else { /* empty */ } /* end of [if] */ /* tmp130 = */ atspre_prerr_newline () ; /* tmp131 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp132 = atspre_ieq (tmp121, 0) ; /* tmp122 = */ atspre_assert (tmp132) ; } else { /* empty */ } /* end of [if] */ tmp109 = aux_13 (arg1, arg2) ; return (tmp109) ; } /* end of [d23explst_tr_dn_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 11199(line=359, offs=5) -- 11553(line=370, offs=4) */ ATSstaticdec() ats_ptr_type d2explst_arg_tr_up_14 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_bool_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_d2explst_arg_tr_up_14: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp134 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp135 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_varlamcst (tmp134) ; if (tmp137) { tmp136 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp136)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp136, atslab_0, tmp134) ; } else { tmp138 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp134) ; tmp136 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp136)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp136, atslab_0, tmp138) ; } /* end of [if] */ tmp139 = d2explst_arg_tr_up_14 (tmp135) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp133, atslab_0, tmp136) ; ats_selptrset_mac(anairiats_sum_6, tmp133, atslab_1, tmp139) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp133 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp133) ; } /* end of [d2explst_arg_tr_up_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 11590(line=372, offs=5) -- 11931(line=383, offs=4) */ ATSstaticdec() ats_void_type d23explst_open_and_add_15 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; // ATSlocal_void (tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; __ats_lab_d23explst_open_and_add_15: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_39_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp142 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp141)->tag != 0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (((ats_sum_ptr_type)tmp141)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_5, tmp141, atslab_0) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp144) ; break ; } while (0) ; arg0 = tmp142 ; goto __ats_lab_d23explst_open_and_add_15 ; // tail call break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: break ; } while (0) ; return /* (tmp140) */ ; } /* end of [d23explst_open_and_add_15] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 14059(line=444, offs=13) -- 14723(line=459, offs=12) */ ATSstaticdec() ats_ptr_type aux_17 (ats_ptr_type env0, ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_bool_type, tmp178) ; ATSlocal (ats_bool_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; // ATSlocal_void (tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; __ats_lab_aux_17: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp174 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp175 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp173), atslab_d3exp_typ) ; tmp176 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp175), atslab_s2exp_srt) ; tmp178 = atspre_gt_int_int (arg0, 0) ; if (tmp178) { tmp179 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp176) ; if (tmp179) { tmp177 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } else { tmp177 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } /* end of [if] */ } else { tmp177 = tmp176 ; } /* end of [if] */ tmp180 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (env0, tmp177) ; tmp182 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp173), atslab_d3exp_loc) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp182, tmp175, tmp180) ; tmp184 = atspre_sub_int_int (arg0, 1) ; tmp183 = aux_17 (env0, tmp184, tmp174) ; tmp172 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp172, atslab_0, tmp180) ; ats_selptrset_mac(anairiats_sum_6, tmp172, atslab_1, tmp183) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: tmp172 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp172) ; } /* end of [aux_17] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_17_closure_type ; ats_ptr_type aux_17_clofun (ats_clo_ptr_type cloptr, ats_int_type arg0, ats_ptr_type arg1) { return aux_17 (((aux_17_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_17_closure_init (aux_17_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_17_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_17_closure_make (ats_ptr_type env0) { aux_17_closure_type *p_clo = ATS_MALLOC(sizeof(aux_17_closure_type)) ; aux_17_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 11995(line=387, offs=4) -- 15589(line=481, offs=4) */ ATSstaticdec() ats_ptr_type d23exp_app_tr_up_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; // ATSlocal_void (tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_int_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_bool_type, tmp162) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; // ATSlocal_void (tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; // ATSlocal_void (tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; // ATSlocal_void (tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; // ATSlocal_void (tmp197) ; __ats_lab_d23exp_app_tr_up_16: tmp146 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_loc) ; tmp148 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_typ) ; tmp147 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (tmp146, tmp148) ; /* tmp149 = */ ats_dynexp3_d3exp_set_typ (arg0, tmp147) ; tmp150 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp147), atslab_s2exp_node) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp150)->tag != 11) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp151 = ats_caselptrlab_mac(anairiats_sum_11, tmp150, atslab_0) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_11, tmp150, atslab_2) ; tmp153 = ats_caselptrlab_mac(anairiats_sum_11, tmp150, atslab_3) ; tmp154 = ats_caselptrlab_mac(anairiats_sum_11, tmp150, atslab_4) ; tmp155 = ats_caselptrlab_mac(anairiats_sum_11, tmp150, atslab_5) ; tmp156 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp146, arg1) ; /* tmp157 = */ pfarity_check_fun_3 (tmp146, tmp153, arg2) ; tmp158 = d23explst_tr_dn_12 (arg1, arg3, tmp154) ; tmp159 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp155) ; /* ats_ptr_type tmp160 ; */ tmp160 = tmp159 ; /* ats_ptr_type tmp161 ; */ tmp161 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; tmp162 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (tmp159) ; if (tmp162) { tmp164 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp156, tmp159) ; tmp165 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp164), atslab_s2exp_node) ; if (((ats_sum_ptr_type)tmp165)->tag != 35) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 13449(line=429, offs=14) -- 13496(line=429, offs=61)") ; } tmp166 = ats_caselptrlab_mac(anairiats_sum_8, tmp165, atslab_0) ; tmp167 = ats_caselptrlab_mac(anairiats_sum_8, tmp165, atslab_1) ; tmp160 = tmp166 ; tmp161 = tmp167 ; } else { /* empty */ } /* end of [if] */ tmp168 = d3exp_funclo_restore_9 (tmp151, arg0) ; if (tmp162) { tmp169 = d3explst_arg_restore_10 (tmp158, tmp161) ; } else { tmp169 = tmp158 ; } /* end of [if] */ /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff (tmp156, tmp152) ; tmp145 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn (tmp156, tmp160, tmp152, tmp168, arg2, tmp169) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp150)->tag != 33) { goto __ats_lab_47_0 ; } __ats_lab_44_1: tmp171 = d23explst_tr_up_11 (arg3) ; tmp185 = aux_17 (tmp146, arg2, tmp171) ; tmp186 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp146, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp187 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; tmp189 = (ats_sum_ptr_type)0 ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp189, 0, tmp187, arg2, tmp185, tmp186) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_equal_solve (tmp146, tmp147, tmp188) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp146, arg1) ; tmp145 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn (tmp191, tmp186, tmp187, arg0, arg2, tmp171) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: /* tmp192 = */ prerr_loc_error3_0 (tmp146) ; /* tmp193 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d23exp_app_tr_dn"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp194 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is applied but its type is [")) ; /* tmp195 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp147) ; /* tmp196 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp197 = */ atspre_prerr_newline () ; /* tmp145 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp145) ; } /* end of [d23exp_app_tr_up_16] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 15645(line=485, offs=5) -- 16091(line=497, offs=22) */ ATSstaticdec() ats_ptr_type d2exp_apps_tr_up_18 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_d2exp_apps_tr_up_18: do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_48_1: tmp199 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp200 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp199)->tag != 0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp201 = ats_caselptrlab_mac(anairiats_sum_5, tmp199, atslab_0) ; tmp198 = d2exp_apps_sta_tr_up_19 (arg0, tmp201, tmp200) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (((ats_sum_ptr_type)tmp199)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_14, tmp199, atslab_0) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_14, tmp199, atslab_1) ; tmp204 = ats_caselptrlab_mac(anairiats_sum_14, tmp199, atslab_2) ; tmp198 = d2exp_apps_dyn_tr_up_20 (arg0, tmp202, tmp203, tmp204, tmp200) ; break ; } while (0) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: tmp198 = arg0 ; break ; } while (0) ; return (tmp198) ; } /* end of [d2exp_apps_tr_up_18] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 16354(line=506, offs=9) -- 16590(line=511, offs=17) */ ATSstaticdec() ats_ptr_type aux_21 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_aux_21: do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_52_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp210 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (tmp210 != (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp211 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, tmp209), atslab_s2exparg_loc) ; tmp208 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (arg0, tmp211) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (tmp210 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: arg0 = arg0 ; arg1 = tmp210 ; goto __ats_lab_aux_21 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: __ats_lab_55_1: tmp208 = arg0 ; break ; } while (0) ; return (tmp208) ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 16126(line=500, offs=5) -- 16784(line=517, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_apps_sta_tr_up_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp205) ; // ATSlocal_void (tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_d2exp_apps_sta_tr_up_19: /* tmp206 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (arg0) ; tmp207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_typ) ; tmp213 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_loc) ; tmp212 = aux_21 (tmp213, arg1) ; tmp214 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst (tmp212, tmp207, arg1) ; tmp215 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta (tmp212, tmp214, arg0) ; tmp205 = d2exp_apps_tr_up_18 (tmp215, arg2) ; return (tmp205) ; } /* end of [d2exp_apps_sta_tr_up_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 16823(line=519, offs=5) -- 17987(line=551, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_apps_dyn_tr_up_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; // ATSlocal_void (tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_d2exp_apps_dyn_tr_up_20: tmp218 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_loc) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp218, arg1) ; /* tmp219 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (arg0) ; tmp220 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_typ) ; tmp221 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp220), atslab_s2exp_node) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: __ats_lab_56_1: tmp222 = d2explst_arg_tr_up_14 (arg3) ; /* tmp223 = */ d23explst_open_and_add_15 (tmp222) ; tmp224 = d23exp_app_tr_up_16 (arg0, arg1, arg2, tmp222) ; tmp216 = d2exp_apps_tr_up_18 (tmp224, arg4) ; break ; } while (0) ; return (tmp216) ; } /* end of [d2exp_apps_dyn_tr_up_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 18271(line=567, offs=4) -- 18611(line=577, offs=4) */ ATSstaticdec() ats_void_type fprint_xyz_22 (ats_ref_type arg0, anairiats_rec_16 arg1) { /* local vardec */ // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; // ATSlocal_void (tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; ATSlocal (ats_int_type, tmp234) ; __ats_lab_fprint_xyz_22: /* tmp226 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; tmp228 = ats_select_mac(arg1, atslab_0) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp228) ; /* tmp229 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; tmp231 = ats_select_mac(arg1, atslab_1) ; /* tmp230 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2kexp (arg0, tmp231) ; /* tmp232 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; tmp234 = ats_select_mac(arg1, atslab_2) ; /* tmp233 = */ atspre_fprint_int (arg0, tmp234) ; /* tmp225 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp225) */ ; } /* end of [fprint_xyz_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 18639(line=579, offs=4) -- 18697(line=579, offs=62) */ ATSstaticdec() ats_void_type print_xyz_23 (anairiats_rec_16 arg0) { /* local vardec */ // ATSlocal_void (tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; // ATSlocal_void (tmp238) ; __ats_lab_print_xyz_23: tmp236 = atspre_stdout_get () ; tmp237 = ats_selsin_mac(tmp236, atslab_1) ; /* tmp238 = */ fprint_xyz_22 (tmp237, arg0) ; /* tmp235 = */ atspre_stdout_view_set () ; return /* (tmp235) */ ; } /* end of [print_xyz_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 18701(line=580, offs=4) -- 18759(line=580, offs=62) */ ATSstaticdec() ats_void_type prerr_xyz_24 (anairiats_rec_16 arg0) { /* local vardec */ // ATSlocal_void (tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; // ATSlocal_void (tmp242) ; __ats_lab_prerr_xyz_24: tmp240 = atspre_stderr_get () ; tmp241 = ats_selsin_mac(tmp240, atslab_1) ; /* tmp242 = */ fprint_xyz_22 (tmp241, arg0) ; /* tmp239 = */ atspre_stderr_view_set () ; return /* (tmp239) */ ; } /* end of [prerr_xyz_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 18875(line=587, offs=7) -- 19044(line=590, offs=15) */ ATSstaticdec() ats_ptr_type aux_26 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; __ats_lab_aux_26: tmp245 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_node) ; do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp245)->tag != 1) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_14, tmp245, atslab_0) ; arg0 = tmp246 ; goto __ats_lab_aux_26 ; // tail call break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp245)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_5, tmp245, atslab_0) ; arg0 = tmp247 ; goto __ats_lab_aux_26 ; // tail call break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: tmp244 = arg0 ; break ; } while (0) ; return (tmp244) ; } /* end of [aux_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 18768(line=584, offs=4) -- 19787(line=617, offs=4) */ ATSstaticdec() ats_void_type fprint_xyz_root_25 (ats_ref_type arg0, anairiats_rec_16 arg1) { /* local vardec */ // ATSlocal_void (tmp243) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; __ats_lab_fprint_xyz_root_25: tmp249 = ats_select_mac(arg1, atslab_0) ; tmp248 = aux_26 (tmp249) ; tmp250 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp248), atslab_d3exp_node) ; do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp250)->tag != 11) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp251 = ats_caselptrlab_mac(anairiats_sum_5, tmp250, atslab_0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp251) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp250)->tag != 54) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp252 = ats_caselptrlab_mac(anairiats_sum_5, tmp250, atslab_0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp252) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp250)->tag != 50) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_8, tmp250, atslab_0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2cst (arg0, tmp253) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp250)->tag != 51) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp254 = ats_caselptrlab_mac(anairiats_sum_8, tmp250, atslab_0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2var (arg0, tmp254) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: /* tmp255 = */ atspre_fprint_string (arg0, ATSstrcst("INTERNAL ERROR (ats_trans3_exp_up): fprint_xyz_root: d3e = ")) ; /* tmp256 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__fprint_d3exp (arg0, tmp248) ; /* tmp257 = */ atspre_fprint_newline (arg0) ; /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp243) */ ; } /* end of [fprint_xyz_root_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 19820(line=619, offs=4) -- 19888(line=619, offs=72) */ ATSstaticdec() ats_void_type print_xyz_root_27 (anairiats_rec_16 arg0) { /* local vardec */ // ATSlocal_void (tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; // ATSlocal_void (tmp261) ; __ats_lab_print_xyz_root_27: tmp259 = atspre_stdout_get () ; tmp260 = ats_selsin_mac(tmp259, atslab_1) ; /* tmp261 = */ fprint_xyz_root_25 (tmp260, arg0) ; /* tmp258 = */ atspre_stdout_view_set () ; return /* (tmp258) */ ; } /* end of [print_xyz_root_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 19892(line=620, offs=4) -- 19960(line=620, offs=72) */ ATSstaticdec() ats_void_type prerr_xyz_root_28 (anairiats_rec_16 arg0) { /* local vardec */ // ATSlocal_void (tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; // ATSlocal_void (tmp265) ; __ats_lab_prerr_xyz_root_28: tmp263 = atspre_stderr_get () ; tmp264 = ats_selsin_mac(tmp263, atslab_1) ; /* tmp265 = */ fprint_xyz_root_25 (tmp264, arg0) ; /* tmp262 = */ atspre_stderr_view_set () ; return /* (tmp262) */ ; } /* end of [prerr_xyz_root_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 19986(line=624, offs=4) -- 20428(line=636, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_item_tr_up_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; // ATSlocal_void (tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; // ATSlocal_void (tmp272) ; __ats_lab_d2exp_item_tr_up_29: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp267 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up (arg0, tmp267) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp268 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up (arg0, tmp268) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: __ats_lab_67_1: /* tmp269 = */ prerr_loc_error3_0 (arg0) ; /* tmp270 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_item_tr_up"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp271 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression needs to be a constant or a variable.")) ; /* tmp272 = */ atspre_prerr_newline () ; /* tmp266 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp266) ; } /* end of [d2exp_item_tr_up_29] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 20463(line=638, offs=5) -- 20708(line=644, offs=4) */ ATSstaticdec() ats_ptr_type s2kexplst_make_d3explst_30 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; __ats_lab_s2kexplst_make_d3explst_30: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp274 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp277 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp274), atslab_d3exp_typ) ; tmp276 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp (tmp277) ; tmp278 = s2kexplst_make_d3explst_30 (tmp275) ; tmp273 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp273, atslab_0, tmp276) ; ats_selptrset_mac(anairiats_sum_6, tmp273, atslab_1, tmp278) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_69_1: tmp273 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp273) ; } /* end of [s2kexplst_make_d3explst_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 20750(line=646, offs=5) -- 21521(line=672, offs=4) */ ATSstaticdec() ats_ptr_type aux_filter_31 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (anairiats_rec_16, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (anairiats_rec_18, tmp284) ; ATSlocal (ats_int_type, tmp285) ; ATSlocal (ats_int_type, tmp286) ; ATSlocal (ats_int_type, tmp287) ; ATSlocal (anairiats_rec_16, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; __ats_lab_aux_filter_31: do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } __ats_lab_70_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_0) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; tmp283 = ats_select_mac(tmp280, atslab_1) ; tmp282 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_fun_arg (tmp283, arg1) ; do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (tmp282 == (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp284 = ats_caselptrlab_mac(anairiats_sum_19, tmp282, atslab_0) ; ATS_FREE(tmp282) ; tmp286 = ats_select_mac(tmp280, atslab_2) ; tmp287 = ats_select_mac(tmp284, atslab_1) ; tmp285 = atspre_add_int_int (tmp286, tmp287) ; tmp289 = ats_select_mac(tmp280, atslab_0) ; tmp290 = ats_select_mac(tmp284, atslab_0) ; tmp288.atslab_0 = tmp289 ; tmp288.atslab_1 = tmp290 ; tmp288.atslab_2 = tmp285 ; tmp291 = aux_filter_31 (tmp281, arg1) ; tmp279 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp279, atslab_0, tmp288) ; ats_selptrset_mac(anairiats_sum_17, tmp279, atslab_1, tmp291) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (tmp282 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: arg0 = tmp281 ; arg1 = arg1 ; goto __ats_lab_aux_filter_31 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_73_1: tmp279 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp279) ; } /* end of [aux_filter_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 21550(line=674, offs=5) -- 21781(line=679, offs=4) */ ATSstaticdec() ats_ptr_type aux_select0_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (anairiats_rec_16, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_bool_type, tmp295) ; ATSlocal (ats_int_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; __ats_lab_aux_select0_32: do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp293 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_0) ; tmp294 = ats_caselptrlab_mac(anairiats_sum_17, arg0, atslab_1) ; tmp296 = ats_select_mac(tmp293, atslab_2) ; tmp295 = atspre_gt_int_int (tmp296, 0) ; if (tmp295) { arg0 = tmp294 ; goto __ats_lab_aux_select0_32 ; // tail call } else { tmp297 = aux_select0_32 (tmp294) ; tmp292 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp292, atslab_0, tmp293) ; ats_selptrset_mac(anairiats_sum_17, tmp292, atslab_1, tmp297) ; } /* end of [if] */ break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp292 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp292) ; } /* end of [aux_select0_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 21811(line=681, offs=5) -- 24773(line=755, offs=4) */ ATSstaticdec() ats_ptr_type aux1_33 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; // ATSlocal_void (tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; // ATSlocal_void (tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_int_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; // ATSlocal_void (tmp319) ; // ATSlocal_void (tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_bool_type, tmp323) ; // ATSlocal_void (tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; // ATSlocal_void (tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; // ATSlocal_void (tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; __ats_lab_aux1_33: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_76_1: tmp299 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp300 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp299)->tag != 0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp301 = ats_caselptrlab_mac(anairiats_sum_5, tmp299, atslab_0) ; tmp303 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_typ) ; tmp302 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst (arg0, tmp303, tmp301) ; tmp304 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_sta (arg0, tmp302, arg1) ; arg0 = arg0 ; arg1 = tmp304 ; arg2 = tmp300 ; arg3 = arg3 ; goto __ats_lab_aux1_33 ; // tail call break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: // if (((ats_sum_ptr_type)tmp299)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_78_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_14, tmp299, atslab_0) ; tmp306 = ats_caselptrlab_mac(anairiats_sum_14, tmp299, atslab_1) ; tmp307 = ats_caselptrlab_mac(anairiats_sum_14, tmp299, atslab_2) ; /* tmp308 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add (tmp307) ; tmp309 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3explst_get_typ (tmp307) ; tmp311 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_typ) ; tmp310 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (arg0, tmp311) ; /* tmp312 = */ ats_dynexp3_d3exp_set_typ (arg1, tmp310) ; tmp313 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp310), atslab_s2exp_node) ; do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp313)->tag != 11) { goto __ats_lab_82_0 ; } __ats_lab_79_1: tmp314 = ats_caselptrlab_mac(anairiats_sum_11, tmp313, atslab_0) ; tmp315 = ats_caselptrlab_mac(anairiats_sum_11, tmp313, atslab_2) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_11, tmp313, atslab_3) ; tmp317 = ats_caselptrlab_mac(anairiats_sum_11, tmp313, atslab_4) ; tmp318 = ats_caselptrlab_mac(anairiats_sum_11, tmp313, atslab_5) ; /* tmp319 = */ pfarity_check_fun_3 (arg0, tmp316, tmp306) ; /* tmp320 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_arg_tyleq_solve (tmp305, tmp309, tmp317) ; /* ats_ptr_type tmp321 ; */ tmp321 = tmp318 ; /* ats_ptr_type tmp322 ; */ tmp322 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; tmp323 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (tmp318) ; if (tmp323) { tmp325 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp318) ; tmp326 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp325), atslab_s2exp_node) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp326)->tag != 35) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_8, tmp326, atslab_0) ; tmp328 = ats_caselptrlab_mac(anairiats_sum_8, tmp326, atslab_1) ; tmp321 = tmp327 ; tmp322 = tmp328 ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: /* tmp324 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__deadcode (ATSstrcst(": [ats_trans3_exp_up]: d2exp_apps_sym_tr_up: aux1: iswth")) ; break ; } while (0) ; } else { /* empty */ } /* end of [if] */ tmp329 = d3exp_funclo_restore_9 (tmp314, arg1) ; if (tmp323) { tmp330 = d3explst_arg_restore_10 (tmp307, tmp322) ; } else { tmp330 = tmp307 ; } /* end of [if] */ /* tmp331 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_seff (arg0, tmp315) ; tmp332 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_app_dyn (arg0, tmp321, tmp315, tmp329, tmp306, tmp330) ; arg0 = arg0 ; arg1 = tmp332 ; arg2 = tmp300 ; arg3 = arg3 ; goto __ats_lab_aux1_33 ; // tail call break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: /* tmp333 = */ prerr_loc_error3_0 (arg0) ; /* tmp334 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_apps_sym_tr_up: aux1"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp335 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is applied but its type is [")) ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp310) ; /* tmp337 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp338 = */ atspre_prerr_newline () ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_83_1: tmp298 = d2exp_apps_tr_up_18 (arg1, arg3) ; break ; } while (0) ; return (tmp298) ; } /* end of [aux1_33] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 24908(line=764, offs=6) -- 25227(line=772, offs=6) */ ATSstaticdec() ats_ptr_type err_nil_35 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; // ATSlocal_void (tmp345) ; // ATSlocal_void (tmp346) ; __ats_lab_err_nil_35: /* tmp341 = */ prerr_loc_error3_0 (arg0) ; /* tmp342 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_apps_sym_tr_up: aux2"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp343 = */ atspre_prerr_string (ATSstrcst(": the symbol [")) ; /* tmp344 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym (arg1) ; /* tmp345 = */ atspre_prerr_string (ATSstrcst("] cannot be resolved: there is no match.")) ; /* tmp346 = */ atspre_prerr_newline () ; /* tmp340 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp340) ; } /* end of [err_nil_35] */ typedef struct { ats_fun_ptr_type closure_fun ; } err_nil_35_closure_type ; ats_ptr_type err_nil_35_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return err_nil_35 (arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type err_nil_35_closure_init (err_nil_35_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&err_nil_35_clofun ; return ; } /* end of function */ ats_clo_ptr_type err_nil_35_closure_make () { err_nil_35_closure_type *p_clo = ATS_MALLOC(sizeof(err_nil_35_closure_type)) ; err_nil_35_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 25253(line=773, offs=6) -- 25714(line=787, offs=6) */ ATSstaticdec() ats_ptr_type err_cons_cons_36 (ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_16 arg2, anairiats_rec_16 arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; // ATSlocal_void (tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; // ATSlocal_void (tmp356) ; // ATSlocal_void (tmp357) ; __ats_lab_err_cons_cons_36: /* tmp348 = */ prerr_loc_error3_0 (arg0) ; /* tmp349 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_apps_sym_tr_up: aux2"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp350 = */ atspre_prerr_string (ATSstrcst(": the symbol [")) ; /* tmp351 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2sym (arg1) ; /* tmp352 = */ atspre_prerr_string (ATSstrcst("] cannot be resolved: there are too many matches: ")) ; /* tmp353 = */ prerr_xyz_root_28 (arg2) ; /* tmp354 = */ atspre_prerr_string (ATSstrcst(", ")) ; /* tmp355 = */ prerr_xyz_root_28 (arg3) ; /* tmp356 = */ atspre_prerr_string (ATSstrcst(", ...")) ; /* tmp357 = */ atspre_prerr_newline () ; /* tmp347 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp347) ; } /* end of [err_cons_cons_36] */ typedef struct { ats_fun_ptr_type closure_fun ; } err_cons_cons_36_closure_type ; ats_ptr_type err_cons_cons_36_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1, anairiats_rec_16 arg2, anairiats_rec_16 arg3) { return err_cons_cons_36 (arg0, arg1, arg2, arg3) ; } /* end of function */ ATSinline() ats_void_type err_cons_cons_36_closure_init (err_cons_cons_36_closure_type *p_clo) { p_clo->closure_fun = (ats_fun_ptr_type)&err_cons_cons_36_clofun ; return ; } /* end of function */ ats_clo_ptr_type err_cons_cons_36_closure_make () { err_cons_cons_36_closure_type *p_clo = ATS_MALLOC(sizeof(err_cons_cons_36_closure_type)) ; err_cons_cons_36_closure_init (p_clo) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 24796(line=757, offs=5) -- 27326(line=828, offs=4) */ ATSstaticdec() ats_ptr_type aux2_34 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (anairiats_rec_16, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (anairiats_rec_16, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (anairiats_rec_16, tmp369) ; ATSlocal (anairiats_rec_16, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_int_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; __ats_lab_aux2_34: do { /* branch: __ats_lab_84 */ __ats_lab_84_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_94_0 ; } __ats_lab_84_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_17, arg3, atslab_0) ; tmp359 = ats_caselptrlab_mac(anairiats_sum_17, arg3, atslab_1) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (tmp359 != (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp360 = ats_select_mac(tmp358, atslab_0) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg2) ; tmp339 = aux1_33 (arg0, tmp360, tmp361, arg4) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: // if (tmp359 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_86_1: do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (arg4 != (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_87_1: tmp362 = aux_select0_32 (arg3) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (tmp362 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } tmp363 = ats_caselptrlab_mac(anairiats_sum_17, tmp362, atslab_1) ; if (tmp363 != (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_17, tmp362, atslab_0) ; tmp365 = ats_select_mac(tmp364, atslab_0) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg2) ; tmp367 = (ats_sum_ptr_type)0 ; tmp339 = aux1_33 (arg0, tmp365, tmp366, tmp367) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (tmp362 != (ats_sum_ptr_type)0) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp339 = err_nil_35 (arg0, arg1) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (tmp362 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp368 = ats_caselptrlab_mac(anairiats_sum_17, tmp362, atslab_1) ; // if (tmp368 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp369 = ats_caselptrlab_mac(anairiats_sum_17, tmp362, atslab_0) ; tmp370 = ats_caselptrlab_mac(anairiats_sum_17, tmp368, atslab_0) ; tmp339 = err_cons_cons_36 (arg0, arg1, tmp369, tmp370) ; break ; } while (0) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (arg4 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: tmp371 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_0) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_6, arg4, atslab_1) ; do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp371)->tag != 0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_5, tmp371, atslab_0) ; tmp374 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp374)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp374, atslab_0, tmp373) ; tmp375 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp375, atslab_0, tmp374) ; ats_selptrset_mac(anairiats_sum_6, tmp375, atslab_1, arg2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp375 ; arg3 = arg3 ; arg4 = tmp372 ; goto __ats_lab_aux2_34 ; // tail call break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (((ats_sum_ptr_type)tmp371)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_14, tmp371, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_14, tmp371, atslab_1) ; tmp378 = ats_caselptrlab_mac(anairiats_sum_14, tmp371, atslab_2) ; tmp380 = d2explst_arg_tr_up_14 (tmp378) ; tmp379 = d23explst_tr_up_11 (tmp380) ; tmp381 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp381)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp381, atslab_0, tmp376) ; ats_selptrset_mac(anairiats_sum_14, tmp381, atslab_1, tmp377) ; ats_selptrset_mac(anairiats_sum_14, tmp381, atslab_2, tmp379) ; tmp383 = s2kexplst_make_d3explst_30 (tmp379) ; tmp382 = aux_filter_31 (arg3, tmp383) ; tmp384 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp384, atslab_0, tmp381) ; ats_selptrset_mac(anairiats_sum_6, tmp384, atslab_1, arg2) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp384 ; arg3 = tmp382 ; arg4 = tmp372 ; goto __ats_lab_aux2_34 ; // tail call break ; } while (0) ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_94_1: tmp339 = err_nil_35 (arg0, arg1) ; break ; } while (0) ; return (tmp339) ; } /* end of [aux2_34] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 27349(line=830, offs=5) -- 27655(line=841, offs=4) */ ATSstaticdec() ats_bool_type aux3_37 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp409) ; tmp409 = aux3_37_0aux3_app_38 (0, arg0, arg1) ; return (tmp409) ; } /* end of [aux3_37] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 27678(line=843, offs=5) -- 28321(line=858, offs=4) */ ATSstaticdec() ats_bool_type aux3_app_38 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_bool_type, tmp410) ; tmp410 = aux3_37_0aux3_app_38 (1, arg0, arg1, arg2, arg3) ; return (tmp410) ; } /* end of [aux3_app_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 27349(line=830, offs=5) -- 28321(line=858, offs=4) */ ATSstaticdec() ats_bool_type aux3_37_0aux3_app_38 (ats_int_type arg0, ...) { /* local vardec */ ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_int_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_bool_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_int_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_bool_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_int_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_bool_type, tmp402) ; ATSlocal (ats_bool_type, tmp403) ; ATSlocal (ats_int_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_bool_type, tmp408) ; va_list funarg ; switch (arg0) { case 0: va_start(funarg, arg0) ; tmp385 = va_arg(funarg, ats_ptr_type) ; tmp386 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_aux3_37 ; case 1: va_start(funarg, arg0) ; tmp387 = va_arg(funarg, ats_int_type) ; tmp388 = va_arg(funarg, ats_ptr_type) ; tmp389 = va_arg(funarg, ats_ptr_type) ; tmp390 = va_arg(funarg, ats_ptr_type) ; va_end(funarg) ; goto __ats_lab_aux3_app_38 ; default: exit(1) ; /* deadcode */ } /* end of switch */ ATSlocal (va_list, arg1) ; va_start(arg1, arg0) ; __ats_lab_aux3_37: do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (tmp385 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_95_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_6, tmp385, atslab_0) ; tmp393 = ats_caselptrlab_mac(anairiats_sum_6, tmp385, atslab_1) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp392)->tag != 1) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp394 = ats_caselptrlab_mac(anairiats_sum_14, tmp392, atslab_1) ; tmp395 = ats_caselptrlab_mac(anairiats_sum_14, tmp392, atslab_2) ; tmp387 = tmp394 ; tmp388 = tmp395 ; tmp389 = tmp393 ; tmp390 = tmp386 ; goto __ats_lab_aux3_app_38 ; // tail call break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (((ats_sum_ptr_type)tmp392)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp385 = tmp393 ; tmp386 = tmp386 ; goto __ats_lab_aux3_37 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (tmp385 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: tmp391 = ats_true_bool ; break ; } while (0) ; return tmp391 ; __ats_lab_aux3_app_38: tmp397 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp390) ; tmp398 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp397), atslab_s2exp_node) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp398)->tag != 11) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp399 = ats_caselptrlab_mac(anairiats_sum_11, tmp398, atslab_3) ; tmp400 = ats_caselptrlab_mac(anairiats_sum_11, tmp398, atslab_4) ; tmp401 = ats_caselptrlab_mac(anairiats_sum_11, tmp398, atslab_5) ; tmp402 = atspre_eq_int_int (tmp387, tmp399) ; if (tmp402) { tmp404 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (tmp388, tmp400) ; tmp403 = atspre_ieq (tmp404, 0) ; if (tmp403) { tmp385 = tmp389 ; tmp386 = tmp401 ; goto __ats_lab_aux3_37 ; // tail call } else { tmp396 = ats_false_bool ; } /* end of [if] */ } else { tmp396 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (((ats_sum_ptr_type)tmp398)->tag != 9) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_20, tmp398, atslab_2) ; tmp387 = tmp387 ; tmp388 = tmp388 ; tmp389 = tmp389 ; tmp390 = tmp405 ; goto __ats_lab_aux3_app_38 ; // tail call break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp398)->tag != 30) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp406 = ats_caselptrlab_mac(anairiats_sum_20, tmp398, atslab_2) ; tmp387 = tmp387 ; tmp388 = tmp388 ; tmp389 = tmp389 ; tmp390 = tmp406 ; goto __ats_lab_aux3_app_38 ; // tail call break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp398)->tag != 15) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp407 = ats_caselptrlab_mac(anairiats_sum_20, tmp398, atslab_2) ; tmp387 = tmp387 ; tmp388 = tmp388 ; tmp389 = tmp389 ; tmp390 = tmp407 ; goto __ats_lab_aux3_app_38 ; // tail call break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: __ats_lab_103_1: tmp396 = ats_false_bool ; break ; } while (0) ; return tmp396 ; return (tmp408) ; } /* end of [aux3_37_0aux3_app_38] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 28847(line=879, offs=9) -- 29813(line=903, offs=10) */ ATSstaticdec() ats_ptr_type aux_41 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_bool_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (anairiats_rec_16, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; __ats_lab_aux_41: do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp413 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp414 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (((ats_sum_ptr_type)tmp413)->tag != 5) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_5, tmp413, atslab_0) ; tmp416 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp416, atslab_0, tmp414) ; ats_selptrset_mac(anairiats_sum_6, tmp416, atslab_1, arg3) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp415 ; arg3 = tmp416 ; goto __ats_lab_aux_41 ; // tail call break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: __ats_lab_106_1: tmp417 = d2exp_item_tr_up_29 (arg0, tmp413) ; tmp418 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp417), atslab_d3exp_typ) ; tmp419 = aux3_37 (arg1, tmp418) ; if (tmp419) { tmp420 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp (tmp418) ; tmp421.atslab_0 = tmp417 ; tmp421.atslab_1 = tmp420 ; tmp421.atslab_2 = 0 ; tmp422 = aux_41 (arg0, arg1, tmp414, arg3) ; tmp412 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp412, atslab_0, tmp421) ; ats_selptrset_mac(anairiats_sum_17, tmp412, atslab_1, tmp422) ; } else { arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp414 ; arg3 = arg3 ; goto __ats_lab_aux_41 ; // tail call } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp423 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_0) ; tmp424 = ats_caselptrlab_mac(anairiats_sum_6, arg3, atslab_1) ; ATS_FREE(arg3) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp423 ; arg3 = tmp424 ; goto __ats_lab_aux_41 ; // tail call break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: tmp412 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; } while (0) ; return (tmp412) ; } /* end of [aux_41] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 28368(line=862, offs=4) -- 29897(line=907, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_apps_sym_tr_up_40 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; __ats_lab_d2exp_apps_sym_tr_up_40: tmp426 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg1), atslab_d2sym_itm) ; tmp427 = (ats_sum_ptr_type)0 ; tmp425 = aux_41 (arg0, arg2, tmp426, tmp427) ; tmp428 = (ats_sum_ptr_type)0 ; tmp411 = aux2_34 (arg0, arg1, tmp428, tmp425, arg2) ; return (tmp411) ; } /* end of [d2exp_apps_sym_tr_up_40] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 30104(line=917, offs=4) -- 35892(line=1066, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_assgn_tr_up_42 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; // ATSlocal_void (tmp448) ; // ATSlocal_void (tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; // ATSlocal_void (tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; // ATSlocal_void (tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; // ATSlocal_void (tmp466) ; // ATSlocal_void (tmp467) ; ATSlocal (ats_bool_type, tmp468) ; // ATSlocal_void (tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; // ATSlocal_void (tmp471) ; // ATSlocal_void (tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; // ATSlocal_void (tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; // ATSlocal_void (tmp477) ; // ATSlocal_void (tmp478) ; // ATSlocal_void (tmp479) ; // ATSlocal_void (tmp480) ; // ATSlocal_void (tmp481) ; // ATSlocal_void (tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; // ATSlocal_void (tmp484) ; // ATSlocal_void (tmp485) ; // ATSlocal_void (tmp486) ; // ATSlocal_void (tmp487) ; // ATSlocal_void (tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; // ATSlocal_void (tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; // ATSlocal_void (tmp496) ; ATSlocal (ats_bool_type, tmp497) ; // ATSlocal_void (tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; // ATSlocal_void (tmp500) ; // ATSlocal_void (tmp501) ; // ATSlocal_void (tmp502) ; // ATSlocal_void (tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; // ATSlocal_void (tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; // ATSlocal_void (tmp518) ; // ATSlocal_void (tmp519) ; // ATSlocal_void (tmp520) ; // ATSlocal_void (tmp521) ; __ats_lab_d2exp_assgn_tr_up_42: tmp430 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp (arg1) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp430)->tag != 0) { goto __ats_lab_113_0 ; } __ats_lab_110_1: tmp431 = ats_caselptrlab_mac(anairiats_sum_22, tmp430, atslab_0) ; tmp432 = ats_caselptrlab_mac(anairiats_sum_22, tmp430, atslab_1) ; tmp433 = ats_caselptrlab_mac(anairiats_sum_22, tmp430, atslab_3) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (tmp433 == (ats_sum_ptr_type)0) { goto __ats_lab_112_0 ; } tmp434 = ats_caselptrlab_mac(anairiats_sum_6, tmp433, atslab_1) ; if (tmp434 != (ats_sum_ptr_type)0) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_6, tmp433, atslab_0) ; tmp437 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp432), atslab_d2exp_loc) ; tmp438 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_d2exp_loc) ; tmp436 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp437, tmp438) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_extend (tmp435, arg2) ; tmp439 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp439, atslab_0, tmp432) ; ats_selptrset_mac(anairiats_sum_6, tmp439, atslab_1, tmp440) ; tmp441 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp441)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp441, atslab_0, tmp436) ; ats_selptrset_mac(anairiats_sum_14, tmp441, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_14, tmp441, atslab_2, tmp439) ; tmp442 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp442, atslab_0, tmp441) ; tmp443 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp442), atslab_1) ; tmp444 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp443) = tmp444 ; tmp429 = d2exp_apps_sym_tr_up_40 (tmp436, tmp431, tmp442) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: /* tmp445 = */ prerr_loc_error3_0 (arg0) ; /* tmp446 = */ atspre_prerr_string (ATSstrcst(": the format for array subscripts [")) ; /* tmp447 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst (tmp433) ; /* tmp448 = */ atspre_prerr_string (ATSstrcst("] is not supported.")) ; /* tmp449 = */ atspre_prerr_newline () ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: if (((ats_sum_ptr_type)tmp430)->tag != 1) { goto __ats_lab_120_0 ; } __ats_lab_113_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_0) ; tmp451 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_1) ; tmp452 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp450) ; /* tmp453 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp452) ; tmp454 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp452), atslab_d3exp_typ) ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp454) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp455 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_24, tmp455, atslab_0) ; ATS_FREE(tmp455) ; tmp457 = d2lablst_tr_up_5 (tmp451) ; tmp458 = s2lab0lst_of_d3lab0lst_6 (tmp457) ; tmp459 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg2) ; /* tmp460 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp459) ; tmp461 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp459), atslab_d3exp_typ) ; tmp462 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_assgn_slablst (arg0, tmp456, tmp458, tmp461) ; tmp463 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp457, tmp462) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr (arg0, tmp452, tmp463, tmp459) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (tmp455 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (tmp451 != (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_116_1: tmp464 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type (tmp454) ; do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (tmp464 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp465 = ats_caselptrlab_mac(anairiats_sum_24, tmp464, atslab_0) ; ATS_FREE(tmp464) ; /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref (arg0) ; tmp468 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp465) ; if (tmp468) { tmp470 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp450), atslab_d2exp_loc) ; /* tmp469 = */ prerr_loc_error3_0 (tmp470) ; /* tmp471 = */ atspre_prerr_string (ATSstrcst(": a reference to a linear value cannot be updated directly.")) ; /* tmp472 = */ atspre_prerr_newline () ; /* tmp467 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp473 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg2, tmp465) ; tmp474 = (ats_sum_ptr_type)0 ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_ptr (arg0, tmp452, tmp474, tmp473) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (tmp464 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp476 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp450), atslab_d2exp_loc) ; /* tmp475 = */ prerr_loc_error3_0 (tmp476) ; /* tmp477 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer or reference")) ; /* tmp478 = */ atspre_prerr_string (ATSstrcst(", but it is assigned the type [")) ; /* tmp479 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp454) ; /* tmp480 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp481 = */ atspre_prerr_newline () ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (tmp451 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: tmp483 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp450), atslab_d2exp_loc) ; /* tmp482 = */ prerr_loc_error3_0 (tmp483) ; /* tmp484 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer")) ; /* tmp485 = */ atspre_prerr_string (ATSstrcst(", but it is assigned the type [")) ; /* tmp486 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp454) ; /* tmp487 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp488 = */ atspre_prerr_newline () ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: if (((ats_sum_ptr_type)tmp430)->tag != 2) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp489 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_0) ; tmp490 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_1) ; tmp491 = d2lablst_tr_up_5 (tmp490) ; tmp492 = s2lab0lst_of_d3lab0lst_6 (tmp491) ; tmp493 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg2) ; /* tmp494 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp493) ; tmp495 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp493), atslab_d3exp_typ) ; tmp497 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp495) ; if (tmp497) { /* empty */ } else { tmp499 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp498 = */ prerr_loc_error3_0 (tmp499) ; /* tmp500 = */ atspre_prerr_string (ATSstrcst(": the linear dynamic variable [")) ; /* tmp501 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp489) ; /* tmp502 = */ atspre_prerr_string (ATSstrcst("] can support proof assignment but not value assignment.")) ; /* tmp503 = */ atspre_prerr_newline () ; /* tmp496 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp504 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_lin_assgn_slablst (arg0, tmp489, tmp492, tmp495) ; tmp505 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp491, tmp504) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var (arg0, tmp489, tmp505, tmp493) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: if (((ats_sum_ptr_type)tmp430)->tag != 3) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp506 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_0) ; tmp507 = ats_caselptrlab_mac(anairiats_sum_8, tmp430, atslab_1) ; tmp508 = d2lablst_tr_up_5 (tmp507) ; tmp509 = s2lab0lst_of_d3lab0lst_6 (tmp508) ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg2) ; /* tmp511 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp510) ; tmp513 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp510), atslab_d3exp_typ) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2var_mut_assgn_slablst (arg0, tmp506, tmp509, tmp513) ; tmp514 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp508, tmp512) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_assgn_var (arg0, tmp506, tmp514, tmp510) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: // if (((ats_sum_ptr_type)tmp430)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_122_1: tmp515 = ats_caselptrlab_mac(anairiats_sum_5, tmp430, atslab_0) ; tmp516 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp515), atslab_d2exp_node) ; do { /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp516)->tag != 57) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp517 = ats_caselptrlab_mac(anairiats_sum_5, tmp516, atslab_0) ; tmp429 = ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_assgn_tr_up (arg0, tmp517, arg2) ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: /* tmp518 = */ prerr_loc_error3_0 (arg0) ; /* tmp519 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp520 = */ atspre_prerr_string (ATSstrcst(", but it is not.")) ; /* tmp521 = */ atspre_prerr_newline () ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp429) ; } /* end of [d2exp_assgn_tr_up_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 35948(line=1070, offs=4) -- 36678(line=1085, offs=8) */ ATSstaticdec() ats_ptr_type d3exp_s2exp_lazy_force_tr_up_43 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; // ATSlocal_void (tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; // ATSlocal_void (tmp529) ; // ATSlocal_void (tmp530) ; // ATSlocal_void (tmp531) ; // ATSlocal_void (tmp532) ; __ats_lab_d3exp_s2exp_lazy_force_tr_up_43: tmp523 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_t0ype_type (arg2) ; do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (tmp523 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp524 = ats_caselptrlab_mac(anairiats_sum_24, tmp523, atslab_0) ; ATS_FREE(tmp523) ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force (arg0, tmp524, 0, arg1) ; break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (tmp523 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: tmp525 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_viewt0ype_viewtype (arg2) ; do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (tmp525 == (ats_sum_ptr_type)0) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp526 = ats_caselptrlab_mac(anairiats_sum_24, tmp525, atslab_0) ; ATS_FREE(tmp525) ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_force (arg0, tmp526, 1, arg1) ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: // if (tmp525 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_128_1: tmp528 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_loc) ; /* tmp527 = */ prerr_loc_error3_0 (tmp528) ; /* tmp529 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is assigned the type [")) ; /* tmp530 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg2) ; /* tmp531 = */ atspre_prerr_string (ATSstrcst("], but a pointer, reference, or delayed computation is expected.")) ; /* tmp532 = */ atspre_prerr_newline () ; /* tmp522 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp522) ; } /* end of [d3exp_s2exp_lazy_force_tr_up_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 36765(line=1090, offs=4) -- 39421(line=1163, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_deref_tr_up_44 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; // ATSlocal_void (tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (anairiats_rec_0, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; // ATSlocal_void (tmp547) ; // ATSlocal_void (tmp548) ; ATSlocal (ats_bool_type, tmp549) ; // ATSlocal_void (tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; // ATSlocal_void (tmp552) ; // ATSlocal_void (tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; // ATSlocal_void (tmp555) ; ATSlocal (ats_ptr_type, tmp556) ; // ATSlocal_void (tmp557) ; // ATSlocal_void (tmp558) ; // ATSlocal_void (tmp559) ; // ATSlocal_void (tmp560) ; // ATSlocal_void (tmp561) ; __ats_lab_d2exp_deref_tr_up_44: tmp534 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; /* tmp535 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp534) ; tmp536 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp534), atslab_d3exp_typ) ; tmp537 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp536) ; do { /* branch: __ats_lab_129 */ __ats_lab_129_0: if (tmp537 == (ats_sum_ptr_type)0) { goto __ats_lab_130_0 ; } __ats_lab_129_1: tmp538 = ats_caselptrlab_mac(anairiats_sum_24, tmp537, atslab_0) ; ATS_FREE(tmp537) ; tmp539 = d2lablst_tr_up_5 (arg2) ; tmp540 = s2lab0lst_of_d3lab0lst_6 (tmp539) ; tmp541 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst (arg0, tmp538, tmp540) ; tmp542 = ats_select_mac(tmp541, atslab_0) ; tmp543 = ats_select_mac(tmp541, atslab_1) ; tmp544 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp539, tmp543) ; tmp533 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr (arg0, tmp542, tmp534, tmp544) ; break ; /* branch: __ats_lab_130 */ __ats_lab_130_0: // if (tmp537 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_130_1: do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (arg2 != (ats_sum_ptr_type)0) { goto __ats_lab_134_0 ; } __ats_lab_131_1: tmp545 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type (tmp536) ; do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (tmp545 == (ats_sum_ptr_type)0) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp546 = ats_caselptrlab_mac(anairiats_sum_24, tmp545, atslab_0) ; ATS_FREE(tmp545) ; /* tmp547 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ref (arg0) ; tmp549 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp546) ; if (tmp549) { tmp551 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp550 = */ prerr_loc_error3_0 (tmp551) ; /* tmp552 = */ atspre_prerr_string (ATSstrcst(": a reference to a linear value cannot be accessed directly.")) ; /* tmp553 = */ atspre_prerr_newline () ; /* tmp548 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp554 = (ats_sum_ptr_type)0 ; tmp533 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_ptr (arg0, tmp546, tmp534, tmp554) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: // if (tmp545 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_133_1: tmp533 = d3exp_s2exp_lazy_force_tr_up_43 (arg0, tmp534, tmp536) ; break ; } while (0) ; break ; /* branch: __ats_lab_134 */ __ats_lab_134_0: // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_134_1: tmp556 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp555 = */ prerr_loc_error3_0 (tmp556) ; /* tmp557 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer")) ; /* tmp558 = */ atspre_prerr_string (ATSstrcst(", but it is assigned the type [")) ; /* tmp559 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp536) ; /* tmp560 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp561 = */ atspre_prerr_newline () ; /* tmp533 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp533) ; } /* end of [d2exp_deref_tr_up_44] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 39477(line=1167, offs=4) -- 40590(line=1197, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_con_tr_up_45 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; // ATSlocal_void (tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_int_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; // ATSlocal_void (tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; // ATSlocal_void (tmp574) ; // ATSlocal_void (tmp575) ; // ATSlocal_void (tmp576) ; // ATSlocal_void (tmp577) ; // ATSlocal_void (tmp578) ; // ATSlocal_void (tmp579) ; // ATSlocal_void (tmp580) ; // ATSlocal_void (tmp581) ; __ats_lab_d2exp_con_tr_up_45: tmp563 = d2explst_arg_tr_up_14 (arg4) ; /* tmp564 = */ d23explst_open_and_add_15 (tmp563) ; tmp565 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ (arg1) ; tmp566 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst (arg0, tmp565, arg2) ; tmp567 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (arg0, tmp566) ; tmp568 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp567), atslab_s2exp_node) ; do { /* branch: __ats_lab_135 */ __ats_lab_135_0: if (((ats_sum_ptr_type)tmp568)->tag != 11) { goto __ats_lab_136_0 ; } __ats_lab_135_1: tmp569 = ats_caselptrlab_mac(anairiats_sum_11, tmp568, atslab_3) ; tmp570 = ats_caselptrlab_mac(anairiats_sum_11, tmp568, atslab_4) ; tmp571 = ats_caselptrlab_mac(anairiats_sum_11, tmp568, atslab_5) ; /* tmp572 = */ pfarity_check_fun_3 (arg0, tmp569, arg3) ; tmp573 = d23explst_tr_dn_12 (arg0, tmp563, tmp570) ; tmp562 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_con (arg0, tmp571, arg1, arg3, tmp573) ; break ; /* branch: __ats_lab_136 */ __ats_lab_136_0: __ats_lab_136_1: /* tmp574 = */ prerr_loc_error3_0 (arg0) ; /* tmp575 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_con_tr_up"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp576 = */ atspre_prerr_string (ATSstrcst(": the dynamic constructor [")) ; /* tmp577 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_d2con (arg1) ; /* tmp578 = */ atspre_prerr_string (ATSstrcst("] is applied but its type [")) ; /* tmp579 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp565) ; /* tmp580 = */ atspre_prerr_string (ATSstrcst("] indicates that it should not be.")) ; /* tmp581 = */ atspre_prerr_newline () ; /* tmp562 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp562) ; } /* end of [d2exp_con_tr_up_45] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 40641(line=1201, offs=4) -- 41265(line=1221, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_decrypt_tr_up_46 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; // ATSlocal_void (tmp588) ; // ATSlocal_void (tmp589) ; // ATSlocal_void (tmp590) ; // ATSlocal_void (tmp591) ; // ATSlocal_void (tmp592) ; // ATSlocal_void (tmp593) ; __ats_lab_d2exp_decrypt_tr_up_46: tmp583 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; tmp584 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp583), atslab_d3exp_typ) ; tmp586 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp584), atslab_s2exp_node) ; do { /* branch: __ats_lab_137 */ __ats_lab_137_0: if (((ats_sum_ptr_type)tmp586)->tag != 3) { goto __ats_lab_138_0 ; } __ats_lab_137_1: tmp587 = ats_caselptrlab_mac(anairiats_sum_5, tmp586, atslab_0) ; tmp585 = tmp587 ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: __ats_lab_138_1: /* tmp588 = */ prerr_loc_error3_0 (arg0) ; /* tmp589 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be crypted")) ; /* tmp590 = */ atspre_prerr_string (ATSstrcst(", but it is assigned the type [")) ; /* tmp591 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp584) ; /* tmp592 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp593 = */ atspre_prerr_newline () ; /* tmp585 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt (arg0, tmp585, -1, tmp583) ; return (tmp582) ; } /* end of [d2exp_decrypt_tr_up_46] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 41302(line=1223, offs=4) -- 41481(line=1229, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_encrypt_tr_up_47 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; __ats_lab_d2exp_encrypt_tr_up_47: tmp595 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; tmp597 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp595), atslab_d3exp_typ) ; tmp596 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (tmp597) ; tmp594 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_crypt (arg0, tmp596, 1, tmp595) ; return (tmp594) ; } /* end of [d2exp_encrypt_tr_up_47] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 41518(line=1231, offs=4) -- 41726(line=1238, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_crypt_tr_up_48 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_bool_type, tmp599) ; __ats_lab_d2exp_crypt_tr_up_48: tmp599 = atspre_gt_int_int (arg1, 0) ; if (tmp599) { tmp598 = d2exp_encrypt_tr_up_47 (arg0, arg2) ; } else { tmp598 = d2exp_decrypt_tr_up_46 (arg0, arg2) ; } /* end of [if] */ return (tmp598) ; } /* end of [d2exp_crypt_tr_up_48] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 41896(line=1249, offs=6) -- 42424(line=1264, offs=10) */ ATSstaticdec() ats_ptr_type aux_50 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (anairiats_rec_25, tmp604) ; // ATSlocal_void (tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; // ATSlocal_void (tmp608) ; // ATSlocal_void (tmp609) ; // ATSlocal_void (tmp610) ; // ATSlocal_void (tmp611) ; // ATSlocal_void (tmp612) ; __ats_lab_aux_50: tmp603 = (ats_sum_ptr_type)0 ; tmp602 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (arg1, tmp603) ; do { /* branch: __ats_lab_139 */ __ats_lab_139_0: if (tmp602 == (ats_sum_ptr_type)0) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp604 = ats_caselptrlab_mac(anairiats_sum_26, tmp602, atslab_0) ; ATS_FREE(tmp602) ; tmp606 = ats_select_mac(tmp604, atslab_0) ; tmp607 = (ats_sum_ptr_type)0 ; /* tmp605 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp606, tmp607) ; tmp601 = ats_select_mac(tmp604, atslab_1) ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: // if (tmp602 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_140_1: /* tmp608 = */ prerr_loc_interror_2 (arg0) ; /* tmp609 = */ atspre_prerr_string (ATSstrcst(": Internal Error: d2exp_foldat_freeat_tr_up: no view at [")) ; /* tmp610 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (arg1) ; /* tmp611 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp612 = */ atspre_prerr_newline () ; /* tmp601 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp601) ; } /* end of [aux_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 42475(line=1267, offs=7) -- 42681(line=1273, offs=23) */ ATSstaticdec() ats_ptr_type auxlst_51 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; __ats_lab_auxlst_51: do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp614 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp615 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp616 = aux_50 (arg0, tmp614) ; tmp617 = auxlst_51 (arg0, tmp615) ; tmp613 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp613, atslab_0, tmp616) ; ats_selptrset_mac(anairiats_sum_6, tmp613, atslab_1, tmp617) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_142_1: tmp613 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp613) ; } /* end of [auxlst_51] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 41782(line=1242, offs=4) -- 45955(line=1373, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_foldat_freeat_tr_up_49 (ats_ptr_type arg0, ats_bool_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp618) ; // ATSlocal_void (tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_ptr_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; // ATSlocal_void (tmp628) ; // ATSlocal_void (tmp629) ; // ATSlocal_void (tmp630) ; // ATSlocal_void (tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_int_type, tmp636) ; // ATSlocal_void (tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; // ATSlocal_void (tmp642) ; // ATSlocal_void (tmp643) ; ATSlocal (ats_bool_type, tmp644) ; // ATSlocal_void (tmp645) ; // ATSlocal_void (tmp646) ; // ATSlocal_void (tmp647) ; ATSlocal (ats_int_type, tmp648) ; // ATSlocal_void (tmp649) ; ATSlocal (ats_bool_type, tmp650) ; // ATSlocal_void (tmp651) ; // ATSlocal_void (tmp652) ; // ATSlocal_void (tmp653) ; // ATSlocal_void (tmp654) ; // ATSlocal_void (tmp655) ; // ATSlocal_void (tmp656) ; // ATSlocal_void (tmp657) ; // ATSlocal_void (tmp658) ; // ATSlocal_void (tmp659) ; __ats_lab_d2exp_foldat_freeat_tr_up_49: tmp618 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg3) ; /* tmp619 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp618) ; tmp620 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp618), atslab_d3exp_typ) ; /* ats_ptr_type tmp621 ; */ tmp621 = (ats_sum_ptr_type)0 ; tmp623 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp620), atslab_s2exp_node) ; do { /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)tmp623)->tag != 5) { goto __ats_lab_144_0 ; } __ats_lab_143_1: tmp624 = ats_caselptrlab_mac(anairiats_sum_8, tmp623, atslab_0) ; tmp625 = ats_caselptrlab_mac(anairiats_sum_8, tmp623, atslab_1) ; tmp621 = tmp625 ; tmp622 = tmp624 ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: __ats_lab_144_1: tmp627 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg3), atslab_d2exp_loc) ; /* tmp626 = */ prerr_loc_error3_0 (tmp627) ; if (arg1) { /* tmp628 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression cannot be folded as its type is [")) ; } else { /* tmp628 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression cannot be freed as its type is [")) ; } /* end of [if] */ /* tmp629 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp620) ; /* tmp630 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp631 = */ atspre_prerr_newline () ; /* tmp622 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp632 = auxlst_51 (arg0, tmp621) ; tmp633 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_typ (tmp622) ; tmp634 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst (arg0, tmp633, arg2) ; tmp635 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (arg0, tmp634) ; /* ats_int_type tmp636 ; */ tmp636 = 0 ; tmp638 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp635), atslab_s2exp_node) ; do { /* branch: __ats_lab_145 */ __ats_lab_145_0: if (((ats_sum_ptr_type)tmp638)->tag != 11) { goto __ats_lab_146_0 ; } __ats_lab_145_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_11, tmp638, atslab_4) ; tmp640 = ats_caselptrlab_mac(anairiats_sum_11, tmp638, atslab_5) ; if (arg1) { tmp641 = tmp639 ; } else { tmp641 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp639, &ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_topize_0) ; } /* end of [if] */ /* tmp642 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2explst_tyleq_solve_err (arg0, tmp632, tmp641, (&tmp636)) ; tmp644 = atspre_gt_int_int (tmp636, 0) ; if (tmp644) { /* tmp645 = */ prerr_loc_error3_0 (arg0) ; if (arg1) { /* tmp646 = */ atspre_prerr_string (ATSstrcst(": argument type mismatch for folding")) ; } else { /* tmp646 = */ atspre_prerr_string (ATSstrcst(": argument type mismatch for freeing")) ; } /* end of [if] */ /* tmp647 = */ atspre_prerr_newline () ; /* tmp643 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ if (arg1) { /* ats_int_type tmp648 ; */ tmp648 = 0 ; /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_lval_set_typ (arg0, 0, tmp618, tmp640, (&tmp648)) ; tmp650 = atspre_gt_int_int (tmp648, 0) ; if (tmp650) { /* tmp651 = */ prerr_loc_error3_0 (arg0) ; /* tmp652 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression needs to be a left-value for folding")) ; /* tmp653 = */ atspre_prerr_string (ATSstrcst(", but it is not.")) ; /* tmp654 = */ atspre_prerr_newline () ; /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_146 */ __ats_lab_146_0: __ats_lab_146_1: /* tmp655 = */ prerr_loc_interror_2 (arg0) ; /* tmp656 = */ atspre_prerr_string (ATSstrcst(": d2exp_foldat_freeat_tr_up")) ; /* tmp657 = */ atspre_prerr_string (ATSstrcst(": s2e_d2c = ")) ; /* tmp658 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp635) ; /* tmp659 = */ atspre_prerr_newline () ; /* tmp637 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; if (arg1) { tmp600 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_foldat (arg0, tmp618) ; } else { tmp600 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_freeat (arg0, tmp618) ; } /* end of [if] */ return (tmp600) ; } /* end of [d2exp_foldat_freeat_tr_up_49] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 45998(line=1375, offs=4) -- 46134(line=1377, offs=62) */ ATSstaticdec() ats_ptr_type d2exp_foldat_tr_up_52 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp660) ; __ats_lab_d2exp_foldat_tr_up_52: tmp660 = d2exp_foldat_freeat_tr_up_49 (arg0, ats_true_bool, arg1, arg2) ; return (tmp660) ; } /* end of [d2exp_foldat_tr_up_52] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 46170(line=1380, offs=4) -- 46307(line=1382, offs=63) */ ATSstaticdec() ats_ptr_type d2exp_freeat_tr_up_53 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp661) ; __ats_lab_d2exp_freeat_tr_up_53: tmp661 = d2exp_foldat_freeat_tr_up_49 (arg0, ats_false_bool, arg1, arg2) ; return (tmp661) ; } /* end of [d2exp_freeat_tr_up_53] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 46364(line=1387, offs=4) -- 48758(line=1458, offs=4) */ ATSstaticdec() anairiats_rec_2 d2exp_arg_body_tr_up_54 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp662) ; // ATSlocal_void (tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; // ATSlocal_void (tmp668) ; // ATSlocal_void (tmp669) ; // ATSlocal_void (tmp670) ; // ATSlocal_void (tmp671) ; // ATSlocal_void (tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_int_type, tmp676) ; // ATSlocal_void (tmp677) ; ATSlocal (ats_bool_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; // ATSlocal_void (tmp680) ; // ATSlocal_void (tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; // ATSlocal_void (tmp683) ; // ATSlocal_void (tmp684) ; ATSlocal (ats_bool_type, tmp685) ; // ATSlocal_void (tmp686) ; // ATSlocal_void (tmp687) ; // ATSlocal_void (tmp688) ; // ATSlocal_void (tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_bool_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_bool_type, tmp693) ; ATSlocal (ats_ptr_type, tmp694) ; __ats_lab_d2exp_arg_body_tr_up_54: /* tmp663 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* ats_ptr_type tmp664 ; */ tmp664 = arg1 ; tmp665 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp (arg5, (&tmp664)) ; /* ats_ptr_type tmp666 ; */ tmp667 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_s2eff_of_d2exp (tmp665, (&tmp666)) ; /* tmp668 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_lam (tmp666) ; /* tmp669 = ats_selsin_mac(tmp668, atslab_1) */ ; /* tmp670 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (arg2) ; /* tmp671 = ats_selsin_mac(tmp670, atslab_1) */ ; /* tmp672 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst (arg4) ; tmp673 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn (arg4) ; tmp675 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (arg4) ; tmp674 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (tmp675) ; do { /* branch: __ats_lab_147 */ __ats_lab_147_0: if (tmp674 == (ats_sum_ptr_type)0) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp676 = 0 ; break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: // if (tmp674 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_148_1: tmp676 = 1 ; break ; } while (0) ; tmp678 = atspre_eq_int_int (tmp676, 0) ; if (tmp678) { /* tmp677 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (arg0, 1, tmp674, tmp673) ; } else { /* empty */ } /* end of [if] */ tmp679 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__p2atlst_arg_tr_up (arg3, arg4) ; /* tmp680 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam (tmp679) ; /* tmp681 = ats_selsin_mac(tmp680, atslab_1) */ ; tmp682 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp667) ; /* tmp683 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (arg0) ; tmp685 = atspre_gt_int_int (arg2, 0) ; if (tmp685) { /* tmp684 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam (arg0) ; } else { /* empty */ } /* end of [if] */ /* tmp686 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; /* tmp687 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () ; /* tmp688 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp689 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; tmp690 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp682), atslab_d3exp_typ) ; tmp691 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp690) ; tmp693 = atspre_gt_int_int (arg2, 0) ; tmp692 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc (arg0, tmp691, tmp693, tmp664) ; tmp694 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp692, tmp664, arg2, tmp666, arg3, tmp673, tmp690) ; tmp662.atslab_0 = tmp694 ; tmp662.atslab_1 = tmp679 ; tmp662.atslab_2 = tmp682 ; return (tmp662) ; } /* end of [d2exp_arg_body_tr_up_54] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 48817(line=1462, offs=4) -- 49336(line=1477, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_lazy_delay_tr_up_55 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; // ATSlocal_void (tmp698) ; ATSlocal (ats_bool_type, tmp699) ; // ATSlocal_void (tmp700) ; // ATSlocal_void (tmp701) ; // ATSlocal_void (tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; __ats_lab_d2exp_lazy_delay_tr_up_55: tmp696 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; tmp697 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp696), atslab_d3exp_typ) ; tmp699 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp697) ; if (tmp699) { /* tmp700 = */ prerr_loc_error3_0 (arg0) ; /* tmp701 = */ atspre_prerr_string (ATSstrcst(": the keyword [$ldelay] is needed to form a linear lazy value.")) ; /* tmp702 = */ atspre_prerr_newline () ; /* tmp698 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp703 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_t0ype_type (tmp697) ; tmp695 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_delay (arg0, tmp703, tmp696) ; return (tmp695) ; } /* end of [d2exp_lazy_delay_tr_up_55] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 49397(line=1481, offs=4) -- 50466(line=1513, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_lazy_ldelay_tr_up_56 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; // ATSlocal_void (tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; // ATSlocal_void (tmp709) ; // ATSlocal_void (tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; // ATSlocal_void (tmp712) ; // ATSlocal_void (tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; // ATSlocal_void (tmp716) ; // ATSlocal_void (tmp717) ; ATSlocal (ats_ptr_type, tmp718) ; // ATSlocal_void (tmp719) ; // ATSlocal_void (tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; __ats_lab_d2exp_lazy_ldelay_tr_up_56: tmp705 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () ; tmp706 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_nil, tmp705) ; /* tmp707 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp708 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; /* tmp709 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp706, tmp705) ; tmp711 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp710 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp711) ; /* tmp712 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ (tmp705) ; /* tmp713 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp715 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp714 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg2, tmp715) ; /* tmp716 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp706, tmp705) ; tmp718 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_d2exp_loc) ; /* tmp717 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp718) ; /* tmp719 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp706, tmp705) ; /* tmp720 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp706, tmp705) ; tmp722 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp708), atslab_d3exp_typ) ; tmp721 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_viewt0ype_viewtype (tmp722) ; tmp704 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lazy_ldelay (arg0, tmp721, tmp708, tmp714) ; return (tmp704) ; } /* end of [d2exp_lazy_ldelay_tr_up_56] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 50528(line=1517, offs=4) -- 53857(line=1606, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_ptrof_tr_up_57 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; // ATSlocal_void (tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; // ATSlocal_void (tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; // ATSlocal_void (tmp735) ; // ATSlocal_void (tmp736) ; // ATSlocal_void (tmp737) ; // ATSlocal_void (tmp738) ; // ATSlocal_void (tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_ptr_type, tmp744) ; ATSlocal (ats_ptr_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; // ATSlocal_void (tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; // ATSlocal_void (tmp761) ; // ATSlocal_void (tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; // ATSlocal_void (tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; // ATSlocal_void (tmp766) ; // ATSlocal_void (tmp767) ; // ATSlocal_void (tmp768) ; // ATSlocal_void (tmp769) ; // ATSlocal_void (tmp770) ; // ATSlocal_void (tmp771) ; ATSlocal (ats_ptr_type, tmp772) ; // ATSlocal_void (tmp773) ; // ATSlocal_void (tmp774) ; // ATSlocal_void (tmp775) ; __ats_lab_d2exp_ptrof_tr_up_57: tmp724 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp (arg1) ; do { /* branch: __ats_lab_149 */ __ats_lab_149_0: if (((ats_sum_ptr_type)tmp724)->tag != 1) { goto __ats_lab_154_0 ; } __ats_lab_149_1: tmp725 = ats_caselptrlab_mac(anairiats_sum_8, tmp724, atslab_0) ; tmp726 = ats_caselptrlab_mac(anairiats_sum_8, tmp724, atslab_1) ; tmp727 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp725) ; /* tmp728 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp727) ; tmp729 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp727), atslab_d3exp_typ) ; tmp731 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp729) ; do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (tmp731 == (ats_sum_ptr_type)0) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp732 = ats_caselptrlab_mac(anairiats_sum_24, tmp731, atslab_0) ; ATS_FREE(tmp731) ; tmp730 = tmp732 ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: // if (tmp731 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_151_1: tmp734 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp725), atslab_d2exp_loc) ; /* tmp733 = */ prerr_loc_error3_0 (tmp734) ; /* tmp735 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer")) ; /* tmp736 = */ atspre_prerr_string (ATSstrcst(", but it is assigned the type [")) ; /* tmp737 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp729) ; /* tmp738 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp739 = */ atspre_prerr_newline () ; /* tmp730 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (tmp726 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp740 = d2lablst_tr_up_5 (tmp726) ; tmp741 = s2lab0lst_of_d3lab0lst_6 (tmp740) ; tmp742 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst (arg0, tmp730, tmp741) ; tmp743 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp740, tmp742) ; tmp744 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (tmp730, tmp742) ; tmp745 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp744) ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr (arg0, tmp745, tmp727, tmp743) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (tmp726 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: tmp746 = (ats_sum_ptr_type)0 ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_ptr (arg0, tmp729, tmp727, tmp746) ; break ; } while (0) ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp724)->tag != 3) { goto __ats_lab_157_0 ; } __ats_lab_154_1: tmp747 = ats_caselptrlab_mac(anairiats_sum_8, tmp724, atslab_0) ; tmp748 = ats_caselptrlab_mac(anairiats_sum_8, tmp724, atslab_1) ; tmp749 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp747) ; do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (tmp748 == (ats_sum_ptr_type)0) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp750 = d2lablst_tr_up_5 (tmp748) ; tmp751 = s2lab0lst_of_d3lab0lst_6 (tmp750) ; tmp752 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_try_slablst (arg0, tmp749, tmp751) ; tmp753 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp750, tmp752) ; tmp754 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_projlst (tmp749, tmp752) ; tmp755 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp754) ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var (arg0, tmp755, tmp747, tmp753) ; break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: // if (tmp748 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_156_1: tmp756 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp747) ; tmp757 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (tmp756) ; tmp758 = (ats_sum_ptr_type)0 ; tmp723 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ptrof_var (arg0, tmp757, tmp747, tmp758) ; break ; } while (0) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp724)->tag != 0) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp760 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp759 = */ prerr_loc_error3_0 (tmp760) ; /* tmp761 = */ atspre_prerr_string (ATSstrcst(": array subscription is not supported for address-of operation.")) ; /* tmp762 = */ atspre_prerr_newline () ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp724)->tag != 2) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp763 = ats_caselptrlab_mac(anairiats_sum_8, tmp724, atslab_0) ; tmp765 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp764 = */ prerr_loc_error3_0 (tmp765) ; /* tmp766 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp767 = */ atspre_prerr_string (ATSstrcst(", but it is not as [")) ; /* tmp768 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp763) ; /* tmp769 = */ atspre_prerr_string (ATSstrcst("] is not mutable.")) ; /* tmp770 = */ atspre_prerr_newline () ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (((ats_sum_ptr_type)tmp724)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp772 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp771 = */ prerr_loc_error3_0 (tmp772) ; /* tmp773 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp774 = */ atspre_prerr_string (ATSstrcst(", but it is not.")) ; /* tmp775 = */ atspre_prerr_newline () ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp723) ; } /* end of [d2exp_ptrof_tr_up_57] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 53913(line=1610, offs=4) -- 54190(line=1618, offs=6) */ ATSstaticdec() ats_void_type d3exp_nonlin_check_58 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp776) ; ATSlocal (ats_bool_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; // ATSlocal_void (tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; // ATSlocal_void (tmp781) ; // ATSlocal_void (tmp782) ; __ats_lab_d3exp_nonlin_check_58: tmp778 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_typ) ; tmp777 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp778) ; if (tmp777) { tmp780 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_d3exp_loc) ; /* tmp779 = */ prerr_loc_error3_0 (tmp780) ; /* tmp781 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is linear but it should not be.")) ; /* tmp782 = */ atspre_prerr_newline () ; /* tmp776 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp776) */ ; } /* end of [d3exp_nonlin_check_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 54243(line=1621, offs=5) -- 54506(line=1628, offs=4) */ ATSstaticdec() ats_void_type labd3explst_nonlin_check_59 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp783) ; ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; // ATSlocal_void (tmp786) ; __ats_lab_labd3explst_nonlin_check_59: do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp784 = ats_caselptrlab_mac(anairiats_sum_27, arg0, atslab_1) ; tmp785 = ats_caselptrlab_mac(anairiats_sum_27, arg0, atslab_2) ; /* tmp786 = */ d3exp_nonlin_check_58 (tmp784) ; arg0 = tmp785 ; goto __ats_lab_labd3explst_nonlin_check_59 ; // tail call break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: break ; } while (0) ; return /* (tmp783) */ ; } /* end of [labd3explst_nonlin_check_59] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 54761(line=1640, offs=7) -- 55014(line=1647, offs=45) */ ATSstaticdec() ats_ptr_type aux_61 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; __ats_lab_aux_61: do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp789 = ats_caselptrlab_mac(anairiats_sum_27, arg0, atslab_0) ; tmp790 = ats_caselptrlab_mac(anairiats_sum_27, arg0, atslab_1) ; tmp791 = ats_caselptrlab_mac(anairiats_sum_27, arg0, atslab_2) ; tmp792 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp790) ; tmp793 = aux_61 (tmp791) ; tmp788 = ATS_MALLOC(sizeof(anairiats_sum_27)) ; ats_selptrset_mac(anairiats_sum_27, tmp788, atslab_0, tmp789) ; ats_selptrset_mac(anairiats_sum_27, tmp788, atslab_1, tmp792) ; ats_selptrset_mac(anairiats_sum_27, tmp788, atslab_2, tmp793) ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_163_1: tmp788 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp788) ; } /* end of [aux_61] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 54548(line=1630, offs=4) -- 55370(line=1662, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_rec_tr_up_60 (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp794) ; // ATSlocal_void (tmp795) ; ATSlocal (ats_bool_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; __ats_lab_d2exp_rec_tr_up_60: tmp794 = aux_61 (arg3) ; tmp796 = atspre_eq_int_int (arg1, 2) ; if (tmp796) { /* tmp795 = */ labd3explst_nonlin_check_59 (tmp794) ; } else { /* empty */ } /* end of [if] */ tmp797 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__labd3explst_get_typ (tmp794) ; tmp798 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec (arg1, arg2, tmp797) ; tmp787 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_rec (arg0, tmp798, arg1, arg2, tmp794) ; return (tmp787) ; } /* end of [d2exp_rec_tr_up_60] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 55426(line=1666, offs=4) -- 56334(line=1695, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_sel_tr_up_62 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp799) ; // ATSlocal_void (tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; ATSlocal (ats_int_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (anairiats_rec_0, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; // ATSlocal_void (tmp808) ; ATSlocal (ats_bool_type, tmp809) ; // ATSlocal_void (tmp810) ; // ATSlocal_void (tmp811) ; // ATSlocal_void (tmp812) ; // ATSlocal_void (tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; __ats_lab_d3exp_sel_tr_up_62: do { /* branch: __ats_lab_164 */ __ats_lab_164_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_165_0 ; } __ats_lab_164_1: /* tmp800 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (arg1) ; tmp801 = s2lab0lst_of_d3lab0lst_6 (arg2) ; /* ats_int_type tmp802 ; */ tmp802 = 0 ; /* ats_ptr_type tmp803 ; */ tmp803 = (ats_sum_ptr_type)0 ; tmp805 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_d3exp_typ) ; tmp804 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_slablst_restlin_cstr (arg0, tmp805, tmp801, (&tmp802), (&tmp803)) ; tmp806 = ats_select_mac(tmp804, atslab_0) ; tmp807 = ats_select_mac(tmp804, atslab_1) ; tmp809 = atspre_gt_int_int (tmp802, 0) ; if (tmp809) { /* tmp810 = */ prerr_loc_error3_0 (arg0) ; /* tmp811 = */ atspre_prerr_string (ATSstrcst(": a linear component is abandoned by label selection.")) ; /* tmp812 = */ atspre_prerr_newline () ; /* tmp808 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ /* tmp813 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp803) ; tmp814 = d3lab1lst_of_d3lab0lst_s2lablst_7 (arg2, tmp807) ; tmp799 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel (arg0, tmp806, arg1, tmp814) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_165_1: tmp799 = arg1 ; break ; } while (0) ; return (tmp799) ; } /* end of [d3exp_sel_tr_up_62] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 56370(line=1697, offs=4) -- 58643(line=1760, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_sel_tr_up_63 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_bool_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (anairiats_rec_0, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_bool_type, tmp827) ; ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (anairiats_rec_2, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; // ATSlocal_void (tmp836) ; // ATSlocal_void (tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; __ats_lab_d2exp_sel_tr_up_63: tmp816 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_node) ; do { /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)tmp816)->tag != 56) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp817 = ats_caselptrlab_mac(anairiats_sum_5, tmp816, atslab_0) ; tmp818 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (tmp817) ; if (!tmp818) { goto __ats_lab_167_1 ; } tmp819 = d2lablst_tr_up_5 (arg2) ; tmp820 = s2lab0lst_of_d3lab0lst_6 (tmp819) ; tmp821 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp817) ; tmp822 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst (arg0, tmp821, tmp820) ; tmp823 = ats_select_mac(tmp822, atslab_0) ; tmp824 = ats_select_mac(tmp822, atslab_1) ; tmp825 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp819, tmp824) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var (arg0, tmp823, tmp817, tmp825) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)tmp816)->tag != 56) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp826 = ats_caselptrlab_mac(anairiats_sum_5, tmp816, atslab_0) ; tmp827 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_linear (tmp826) ; if (!tmp827) { goto __ats_lab_169_1 ; } tmp828 = d2lablst_tr_up_5 (arg2) ; tmp829 = s2lab0lst_of_d3lab0lst_6 (tmp828) ; tmp830 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (arg0, tmp826) ; /* ats_ptr_type tmp831 ; */ tmp831 = (ats_sum_ptr_type)0 ; tmp832 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_linget_slablst_cstr (arg0, tmp830, tmp829, (&tmp831)) ; tmp833 = ats_select_mac(tmp832, atslab_0) ; tmp834 = ats_select_mac(tmp832, atslab_1) ; tmp835 = ats_select_mac(tmp832, atslab_2) ; /* tmp836 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp831) ; tmp838 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ats_selptrset_mac(anairiats_sum_24, tmp838, atslab_0, tmp834) ; /* tmp837 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp826, tmp838) ; tmp839 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp828, tmp835) ; tmp815 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_sel_var (arg0, tmp833, tmp826, tmp839) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp816)->tag != 15) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp840 = ats_caselptrlab_mac(anairiats_sum_5, tmp816, atslab_0) ; tmp815 = d2exp_deref_tr_up_44 (arg0, tmp840, arg2) ; break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: __ats_lab_169_1: tmp841 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg1) ; tmp842 = d2lablst_tr_up_5 (arg2) ; tmp815 = d3exp_sel_tr_up_62 (arg0, tmp841, tmp842) ; break ; } while (0) ; return (tmp815) ; } /* end of [d2exp_sel_tr_up_63] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 58766(line=1766, offs=8) -- 59234(line=1783, offs=6) */ ATSstaticdec() ats_ptr_type aux_65 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; __ats_lab_aux_65: do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp845 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp846 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp847 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg0, arg3) ; tmp848 = aux_65 (tmp845, tmp846, arg2, arg3) ; tmp844 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp844, atslab_0, tmp847) ; ats_selptrset_mac(anairiats_sum_6, tmp844, atslab_1, tmp848) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_171_1: tmp849 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg0) ; tmp850 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp849), atslab_d3exp_typ) ; ats_ptrget_mac(ats_ptr_type, arg2) = tmp850 ; tmp851 = (ats_sum_ptr_type)0 ; tmp844 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp844, atslab_0, tmp849) ; ats_selptrset_mac(anairiats_sum_6, tmp844, atslab_1, tmp851) ; break ; } while (0) ; return (tmp844) ; } /* end of [aux_65] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 58697(line=1764, offs=4) -- 59533(line=1794, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_seq_tr_up_64 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; __ats_lab_d2exp_seq_tr_up_64: tmp852 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; do { /* branch: __ats_lab_172 */ __ats_lab_172_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp853 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp854 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; /* ats_ptr_type tmp855 ; */ tmp856 = aux_65 (tmp853, tmp854, (&tmp855), tmp852) ; tmp843 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_seq (arg0, tmp855, tmp856) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_173_1: tmp843 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty (arg0, tmp852) ; break ; } while (0) ; return (tmp843) ; } /* end of [d2exp_seq_tr_up_64] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 59683(line=1801, offs=7) -- 59872(line=1807, offs=23) */ ATSstaticdec() ats_ptr_type aux_67 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; __ats_lab_aux_67: do { /* branch: __ats_lab_174 */ __ats_lab_174_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp859 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp860 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp861 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf (tmp859) ; tmp862 = aux_67 (tmp860) ; tmp858 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp858, atslab_0, tmp861) ; ats_selptrset_mac(anairiats_sum_6, tmp858, atslab_1, tmp862) ; break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_175_1: tmp858 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp858) ; } /* end of [aux_67] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 59587(line=1798, offs=4) -- 60957(line=1841, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_tmpid_tr_up_66 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (anairiats_rec_0, tmp867) ; ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_ptr_type, tmp869) ; ATSlocal (ats_ptr_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (anairiats_rec_0, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; // ATSlocal_void (tmp878) ; // ATSlocal_void (tmp879) ; // ATSlocal_void (tmp880) ; // ATSlocal_void (tmp881) ; __ats_lab_d2exp_tmpid_tr_up_66: tmp863 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_node) ; do { /* branch: __ats_lab_176 */ __ats_lab_176_0: if (((ats_sum_ptr_type)tmp863)->tag != 12) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp864 = ats_caselptrlab_mac(anairiats_sum_5, tmp863, atslab_0) ; tmp865 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (tmp864) ; tmp866 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg (tmp864) ; tmp867 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate (arg0, tmp866, arg2, tmp865) ; tmp868 = ats_select_mac(tmp867, atslab_0) ; tmp869 = ats_select_mac(tmp867, atslab_1) ; tmp870 = aux_67 (tmp868) ; tmp857 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst (arg0, tmp869, tmp864, tmp870) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp863)->tag != 56) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp871 = ats_caselptrlab_mac(anairiats_sum_5, tmp863, atslab_0) ; tmp872 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (arg0, tmp871) ; tmp873 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg (tmp871) ; tmp874 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate (arg0, tmp873, arg2, tmp872) ; tmp875 = ats_select_mac(tmp874, atslab_0) ; tmp876 = ats_select_mac(tmp874, atslab_1) ; tmp877 = aux_67 (tmp875) ; tmp857 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar (arg0, tmp876, tmp871, tmp877) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: __ats_lab_178_1: /* tmp878 = */ prerr_loc_error3_0 (arg0) ; /* tmp879 = */ atsopt_debug_prerrf (ATSstrcst(": %s: d2exp_tmpid_tr_up"), ATSstrcst("ats_trans3_exp_up.dats")) ; /* tmp880 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a constant or a variable.")) ; /* tmp881 = */ atspre_prerr_newline () ; /* tmp857 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp857) ; } /* end of [d2exp_tmpid_tr_up_66] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 61111(line=1850, offs=3) -- 63539(line=1914, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_tr_up (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; // ATSlocal_void (tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (anairiats_rec_3, tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; // ATSlocal_void (tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; // ATSlocal_void (tmp901) ; // ATSlocal_void (tmp902) ; // ATSlocal_void (tmp903) ; // ATSlocal_void (tmp904) ; // ATSlocal_void (tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (anairiats_rec_3, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; // ATSlocal_void (tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; // ATSlocal_void (tmp919) ; // ATSlocal_void (tmp920) ; // ATSlocal_void (tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; // ATSlocal_void (tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; // ATSlocal_void (tmp925) ; // ATSlocal_void (tmp926) ; // ATSlocal_void (tmp927) ; // ATSlocal_void (tmp928) ; // ATSlocal_void (tmp929) ; // ATSlocal_void (tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; // ATSlocal_void (tmp932) ; // ATSlocal_void (tmp933) ; // ATSlocal_void (tmp934) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_tr_up: tmp883 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp (arg1) ; do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp883)->tag != 1) { goto __ats_lab_182_0 ; } __ats_lab_179_1: tmp884 = ats_caselptrlab_mac(anairiats_sum_8, tmp883, atslab_0) ; tmp885 = ats_caselptrlab_mac(anairiats_sum_8, tmp883, atslab_1) ; tmp886 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp884) ; /* tmp887 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp886) ; tmp888 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp886), atslab_d3exp_typ) ; tmp889 = d2lablst_tr_up_5 (tmp885) ; tmp890 = s2lab0lst_of_d3lab0lst_6 (tmp889) ; tmp891 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp888) ; do { /* branch: __ats_lab_180 */ __ats_lab_180_0: if (tmp891 == (ats_sum_ptr_type)0) { goto __ats_lab_181_0 ; } __ats_lab_180_1: tmp892 = ats_caselptrlab_mac(anairiats_sum_24, tmp891, atslab_0) ; ATS_FREE(tmp891) ; tmp893 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst (arg0, tmp892, tmp890) ; tmp894 = ats_select_mac(tmp893, atslab_0) ; tmp895 = ats_select_mac(tmp893, atslab_1) ; tmp896 = ats_select_mac(tmp893, atslab_2) ; tmp897 = ats_select_mac(tmp893, atslab_3) ; tmp898 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp889, tmp895) ; tmp882 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_ptr (arg0, tmp894, tmp886, tmp898, tmp896, tmp897) ; break ; /* branch: __ats_lab_181 */ __ats_lab_181_0: // if (tmp891 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_181_1: tmp900 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp884), atslab_d2exp_loc) ; /* tmp899 = */ prerr_loc_error3_0 (tmp900) ; /* tmp901 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer")) ; /* tmp902 = */ atspre_prerr_string (ATSstrcst(", but it is given the type [")) ; /* tmp903 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp888) ; /* tmp904 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp905 = */ atspre_prerr_newline () ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp883)->tag != 3) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp906 = ats_caselptrlab_mac(anairiats_sum_8, tmp883, atslab_0) ; tmp907 = ats_caselptrlab_mac(anairiats_sum_8, tmp883, atslab_1) ; tmp908 = d2lablst_tr_up_5 (tmp907) ; tmp909 = s2lab0lst_of_d3lab0lst_6 (tmp908) ; tmp910 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp906) ; tmp911 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_get_slablst (arg0, tmp910, tmp909) ; tmp912 = ats_select_mac(tmp911, atslab_0) ; tmp913 = ats_select_mac(tmp911, atslab_1) ; tmp914 = ats_select_mac(tmp911, atslab_2) ; tmp915 = ats_select_mac(tmp911, atslab_3) ; tmp916 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp908, tmp913) ; tmp882 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_var (arg0, tmp912, tmp906, tmp916, tmp914, tmp915) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: if (((ats_sum_ptr_type)tmp883)->tag != 0) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp918 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp917 = */ prerr_loc_error3_0 (tmp918) ; /* tmp919 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp920 = */ atspre_prerr_string (ATSstrcst(": array subscription is not supported for view extraction.")) ; /* tmp921 = */ atspre_prerr_newline () ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: if (((ats_sum_ptr_type)tmp883)->tag != 2) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp922 = ats_caselptrlab_mac(anairiats_sum_8, tmp883, atslab_0) ; tmp924 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp923 = */ prerr_loc_error3_0 (tmp924) ; /* tmp925 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp926 = */ atspre_prerr_string (ATSstrcst(", but it is not as [")) ; /* tmp927 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp922) ; /* tmp928 = */ atspre_prerr_string (ATSstrcst("] is not mutable.")) ; /* tmp929 = */ atspre_prerr_newline () ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: // if (((ats_sum_ptr_type)tmp883)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_185_1: tmp931 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp930 = */ prerr_loc_error3_0 (tmp931) ; /* tmp932 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp933 = */ atspre_prerr_string (ATSstrcst(", but it is not.")) ; /* tmp934 = */ atspre_prerr_newline () ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp882) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 63676(line=1922, offs=3) -- 66708(line=2000, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_assgn_tr_up (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; // ATSlocal_void (tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; ATSlocal (ats_ptr_type, tmp944) ; // ATSlocal_void (tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (ats_ptr_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; ATSlocal (ats_ptr_type, tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; // ATSlocal_void (tmp951) ; ATSlocal (ats_ptr_type, tmp952) ; // ATSlocal_void (tmp953) ; // ATSlocal_void (tmp954) ; // ATSlocal_void (tmp955) ; // ATSlocal_void (tmp956) ; // ATSlocal_void (tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; // ATSlocal_void (tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; // ATSlocal_void (tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; // ATSlocal_void (tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; // ATSlocal_void (tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; // ATSlocal_void (tmp977) ; // ATSlocal_void (tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; // ATSlocal_void (tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; // ATSlocal_void (tmp982) ; // ATSlocal_void (tmp983) ; // ATSlocal_void (tmp984) ; // ATSlocal_void (tmp985) ; // ATSlocal_void (tmp986) ; // ATSlocal_void (tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; // ATSlocal_void (tmp989) ; // ATSlocal_void (tmp990) ; // ATSlocal_void (tmp991) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_assgn_tr_up: tmp936 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__l2val_make_d2exp (arg1) ; do { /* branch: __ats_lab_186 */ __ats_lab_186_0: if (((ats_sum_ptr_type)tmp936)->tag != 1) { goto __ats_lab_189_0 ; } __ats_lab_186_1: tmp937 = ats_caselptrlab_mac(anairiats_sum_8, tmp936, atslab_0) ; tmp938 = ats_caselptrlab_mac(anairiats_sum_8, tmp936, atslab_1) ; tmp939 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp937) ; /* tmp940 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp939) ; tmp941 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp939), atslab_d3exp_typ) ; tmp942 = d2lablst_tr_up_5 (tmp938) ; tmp943 = s2lab0lst_of_d3lab0lst_6 (tmp942) ; tmp944 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg2) ; /* tmp945 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp944) ; tmp946 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp944), atslab_d3exp_typ) ; tmp947 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (tmp941) ; do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (tmp947 == (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp948 = ats_caselptrlab_mac(anairiats_sum_24, tmp947, atslab_0) ; ATS_FREE(tmp947) ; tmp949 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst (arg0, tmp948, tmp943, tmp946) ; tmp950 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp942, tmp949) ; tmp935 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_ptr (arg0, tmp939, tmp950, tmp944) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: // if (tmp947 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_188_1: tmp952 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp937), atslab_d2exp_loc) ; /* tmp951 = */ prerr_loc_error3_0 (tmp952) ; /* tmp953 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a pointer")) ; /* tmp954 = */ atspre_prerr_string (ATSstrcst(", but it is given the type [")) ; /* tmp955 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp941) ; /* tmp956 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp957 = */ atspre_prerr_newline () ; /* tmp935 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: if (((ats_sum_ptr_type)tmp936)->tag != 3) { goto __ats_lab_194_0 ; } __ats_lab_189_1: tmp958 = ats_caselptrlab_mac(anairiats_sum_8, tmp936, atslab_0) ; tmp959 = ats_caselptrlab_mac(anairiats_sum_8, tmp936, atslab_1) ; tmp960 = d2lablst_tr_up_5 (tmp959) ; tmp961 = s2lab0lst_of_d3lab0lst_6 (tmp960) ; tmp962 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg2) ; /* tmp963 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp962) ; tmp964 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp962), atslab_d3exp_typ) ; do { /* branch: __ats_lab_190 */ __ats_lab_190_0: if (tmp959 == (ats_sum_ptr_type)0) { goto __ats_lab_191_0 ; } __ats_lab_190_1: tmp965 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp958) ; tmp966 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_viewat_set_slablst (arg0, tmp965, tmp961, tmp964) ; tmp967 = d3lab1lst_of_d3lab0lst_s2lablst_7 (tmp960, tmp966) ; tmp935 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var (arg0, tmp958, tmp967, tmp962) ; break ; /* branch: __ats_lab_191 */ __ats_lab_191_0: // if (tmp959 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_191_1: tmp968 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some (arg0, tmp958) ; tmp970 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (tmp968) ; do { /* branch: __ats_lab_192 */ __ats_lab_192_0: if (tmp970 == (ats_sum_ptr_type)0) { goto __ats_lab_193_0 ; } __ats_lab_192_1: tmp971 = ats_caselptrlab_mac(anairiats_sum_24, tmp970, atslab_0) ; /* tmp969 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_out_void_solve_at (arg0, tmp971) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: // if (tmp970 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_193_1: break ; } while (0) ; tmp973 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ats_selptrset_mac(anairiats_sum_24, tmp973, atslab_0, tmp964) ; /* tmp972 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp968, tmp973) ; tmp974 = (ats_sum_ptr_type)0 ; tmp935 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_viewat_assgn_var (arg0, tmp958, tmp974, tmp962) ; break ; } while (0) ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (((ats_sum_ptr_type)tmp936)->tag != 0) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp976 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp975 = */ prerr_loc_error3_0 (tmp976) ; /* tmp977 = */ atspre_prerr_string (ATSstrcst(": array subscription is not supported for view assignment.")) ; /* tmp978 = */ atspre_prerr_newline () ; /* tmp935 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: if (((ats_sum_ptr_type)tmp936)->tag != 2) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp979 = ats_caselptrlab_mac(anairiats_sum_8, tmp936, atslab_0) ; tmp981 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp980 = */ prerr_loc_error3_0 (tmp981) ; /* tmp982 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp983 = */ atspre_prerr_string (ATSstrcst(", but it is not as [")) ; /* tmp984 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp979) ; /* tmp985 = */ atspre_prerr_string (ATSstrcst("] is not mutable.")) ; /* tmp986 = */ atspre_prerr_newline () ; /* tmp935 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: // if (((ats_sum_ptr_type)tmp936)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_196_1: tmp988 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg1), atslab_d2exp_loc) ; /* tmp987 = */ prerr_loc_error3_0 (tmp988) ; /* tmp989 = */ atspre_prerr_string (ATSstrcst(": the dynamic expression is expected to be a left-value")) ; /* tmp990 = */ atspre_prerr_string (ATSstrcst(", but it is not.")) ; /* tmp991 = */ atspre_prerr_newline () ; /* tmp935 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp935) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_assgn_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 66770(line=2004, offs=5) -- 66990(line=2009, offs=21) */ ATSstaticdec() ats_ptr_type d2explst_elt_tr_dn_70 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp992) ; ATSlocal (ats_ptr_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; __ats_lab_d2explst_elt_tr_dn_70: do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp993 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp994 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp995 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp993, arg1) ; tmp996 = d2explst_elt_tr_dn_70 (tmp994, arg1) ; tmp992 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp992, atslab_0, tmp995) ; ats_selptrset_mac(anairiats_sum_6, tmp992, atslab_1, tmp996) ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_198_1: tmp992 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp992) ; } /* end of [d2explst_elt_tr_dn_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 67082(line=2015, offs=13) -- 84446(line=2466, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_ptr_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; // ATSlocal_void (tmp1011) ; ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_int_type, tmp1014) ; ATSlocal (ats_ptr_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; ATSlocal (ats_ptr_type, tmp1019) ; ATSlocal (ats_ptr_type, tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; ATSlocal (ats_bool_type, tmp1023) ; ATSlocal (ats_ptr_type, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; ATSlocal (ats_ptr_type, tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; // ATSlocal_void (tmp1035) ; // ATSlocal_void (tmp1036) ; // ATSlocal_void (tmp1037) ; // ATSlocal_void (tmp1038) ; // ATSlocal_void (tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_bool_type, tmp1042) ; ATSlocal (ats_ptr_type, tmp1043) ; ATSlocal (ats_int_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_int_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_char_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; ATSlocal (ats_ptr_type, tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; ATSlocal (ats_int_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_int_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_ptr_type, tmp1060) ; ATSlocal (ats_ptr_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; // ATSlocal_void (tmp1066) ; // ATSlocal_void (tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; // ATSlocal_void (tmp1069) ; ATSlocal (ats_ptr_type, tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_int_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_ptr_type, tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; // ATSlocal_void (tmp1078) ; // ATSlocal_void (tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; ATSlocal (ats_ptr_type, tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; ATSlocal (ats_ptr_type, tmp1091) ; ATSlocal (ats_ptr_type, tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_ptr_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; // ATSlocal_void (tmp1102) ; // ATSlocal_void (tmp1103) ; // ATSlocal_void (tmp1104) ; ATSlocal (ats_ptr_type, tmp1105) ; ATSlocal (ats_ptr_type, tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; ATSlocal (ats_ptr_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; ATSlocal (ats_ptr_type, tmp1110) ; ATSlocal (ats_ptr_type, tmp1111) ; // ATSlocal_void (tmp1112) ; // ATSlocal_void (tmp1113) ; // ATSlocal_void (tmp1114) ; ATSlocal (ats_int_type, tmp1115) ; ATSlocal (ats_int_type, tmp1116) ; ATSlocal (ats_ptr_type, tmp1117) ; ATSlocal (ats_ptr_type, tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; ATSlocal (anairiats_rec_2, tmp1120) ; ATSlocal (ats_ptr_type, tmp1121) ; ATSlocal (ats_ptr_type, tmp1122) ; ATSlocal (ats_ptr_type, tmp1123) ; ATSlocal (ats_int_type, tmp1124) ; ATSlocal (ats_int_type, tmp1125) ; ATSlocal (ats_ptr_type, tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; ATSlocal (ats_ptr_type, tmp1128) ; ATSlocal (anairiats_rec_2, tmp1129) ; ATSlocal (ats_ptr_type, tmp1130) ; ATSlocal (ats_ptr_type, tmp1131) ; ATSlocal (ats_ptr_type, tmp1132) ; ATSlocal (ats_int_type, tmp1133) ; // ATSlocal_void (tmp1134) ; ATSlocal (ats_ptr_type, tmp1135) ; ATSlocal (ats_ptr_type, tmp1136) ; ATSlocal (ats_int_type, tmp1137) ; ATSlocal (ats_int_type, tmp1138) ; // ATSlocal_void (tmp1139) ; // ATSlocal_void (tmp1140) ; ATSlocal (ats_int_type, tmp1141) ; // ATSlocal_void (tmp1142) ; // ATSlocal_void (tmp1143) ; // ATSlocal_void (tmp1144) ; ATSlocal (ats_bool_type, tmp1145) ; ATSlocal (ats_ptr_type, tmp1146) ; ATSlocal (ats_ptr_type, tmp1147) ; ATSlocal (ats_ptr_type, tmp1148) ; // ATSlocal_void (tmp1149) ; // ATSlocal_void (tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; // ATSlocal_void (tmp1152) ; ATSlocal (ats_ptr_type, tmp1153) ; // ATSlocal_void (tmp1154) ; ATSlocal (ats_ptr_type, tmp1155) ; ATSlocal (ats_ptr_type, tmp1156) ; ATSlocal (ats_ptr_type, tmp1157) ; // ATSlocal_void (tmp1158) ; // ATSlocal_void (tmp1159) ; // ATSlocal_void (tmp1160) ; ATSlocal (ats_ptr_type, tmp1161) ; // ATSlocal_void (tmp1162) ; ATSlocal (ats_ptr_type, tmp1163) ; ATSlocal (ats_ptr_type, tmp1164) ; ATSlocal (ats_ptr_type, tmp1165) ; // ATSlocal_void (tmp1166) ; // ATSlocal_void (tmp1167) ; // ATSlocal_void (tmp1168) ; // ATSlocal_void (tmp1169) ; // ATSlocal_void (tmp1170) ; // ATSlocal_void (tmp1171) ; // ATSlocal_void (tmp1172) ; // ATSlocal_void (tmp1173) ; ATSlocal (ats_ptr_type, tmp1174) ; // ATSlocal_void (tmp1175) ; ATSlocal (ats_ptr_type, tmp1176) ; // ATSlocal_void (tmp1177) ; // ATSlocal_void (tmp1178) ; // ATSlocal_void (tmp1179) ; // ATSlocal_void (tmp1180) ; // ATSlocal_void (tmp1181) ; // ATSlocal_void (tmp1182) ; // ATSlocal_void (tmp1183) ; ATSlocal (ats_ptr_type, tmp1184) ; ATSlocal (ats_ptr_type, tmp1185) ; // ATSlocal_void (tmp1186) ; // ATSlocal_void (tmp1187) ; // ATSlocal_void (tmp1188) ; // ATSlocal_void (tmp1189) ; // ATSlocal_void (tmp1190) ; // ATSlocal_void (tmp1191) ; // ATSlocal_void (tmp1192) ; // ATSlocal_void (tmp1193) ; ATSlocal (ats_ptr_type, tmp1194) ; // ATSlocal_void (tmp1195) ; ATSlocal (ats_ptr_type, tmp1196) ; // ATSlocal_void (tmp1197) ; // ATSlocal_void (tmp1198) ; // ATSlocal_void (tmp1199) ; // ATSlocal_void (tmp1200) ; // ATSlocal_void (tmp1201) ; // ATSlocal_void (tmp1202) ; // ATSlocal_void (tmp1203) ; ATSlocal (ats_ptr_type, tmp1204) ; ATSlocal (ats_ptr_type, tmp1205) ; // ATSlocal_void (tmp1206) ; // ATSlocal_void (tmp1207) ; // ATSlocal_void (tmp1208) ; // ATSlocal_void (tmp1209) ; // ATSlocal_void (tmp1210) ; // ATSlocal_void (tmp1211) ; ATSlocal (ats_ptr_type, tmp1212) ; ATSlocal (ats_ptr_type, tmp1213) ; // ATSlocal_void (tmp1214) ; // ATSlocal_void (tmp1215) ; // ATSlocal_void (tmp1216) ; // ATSlocal_void (tmp1217) ; ATSlocal (ats_int_type, tmp1218) ; ATSlocal (ats_ptr_type, tmp1219) ; ATSlocal (ats_ptr_type, tmp1220) ; ATSlocal (ats_int_type, tmp1221) ; ATSlocal (ats_int_type, tmp1222) ; ATSlocal (ats_ptr_type, tmp1223) ; ATSlocal (ats_ptr_type, tmp1224) ; ATSlocal (ats_ptr_type, tmp1225) ; ATSlocal (ats_ptr_type, tmp1226) ; ATSlocal (ats_ptr_type, tmp1227) ; ATSlocal (ats_bool_type, tmp1228) ; ATSlocal (ats_int_type, tmp1229) ; ATSlocal (ats_ptr_type, tmp1230) ; ATSlocal (ats_ptr_type, tmp1231) ; ATSlocal (ats_bool_type, tmp1232) ; ATSlocal (ats_ptr_type, tmp1233) ; ATSlocal (ats_ptr_type, tmp1234) ; ATSlocal (ats_ptr_type, tmp1235) ; ATSlocal (ats_ptr_type, tmp1236) ; ATSlocal (ats_ptr_type, tmp1237) ; ATSlocal (ats_ptr_type, tmp1238) ; // ATSlocal_void (tmp1239) ; // ATSlocal_void (tmp1240) ; // ATSlocal_void (tmp1241) ; // ATSlocal_void (tmp1242) ; ATSlocal (ats_ptr_type, tmp1243) ; ATSlocal (ats_ptr_type, tmp1244) ; // ATSlocal_void (tmp1245) ; ATSlocal (ats_ptr_type, tmp1246) ; ATSlocal (ats_ptr_type, tmp1247) ; ATSlocal (ats_ptr_type, tmp1248) ; ATSlocal (ats_int_type, tmp1249) ; ATSlocal (ats_int_type, tmp1250) ; ATSlocal (ats_ptr_type, tmp1251) ; ATSlocal (ats_ptr_type, tmp1252) ; ATSlocal (ats_ptr_type, tmp1253) ; ATSlocal (ats_ptr_type, tmp1254) ; ATSlocal (ats_ptr_type, tmp1255) ; ATSlocal (ats_ptr_type, tmp1256) ; ATSlocal (ats_ptr_type, tmp1257) ; ATSlocal (ats_ptr_type, tmp1258) ; ATSlocal (ats_ptr_type, tmp1259) ; ATSlocal (ats_ptr_type, tmp1260) ; // ATSlocal_void (tmp1261) ; ATSlocal (ats_ptr_type, tmp1262) ; ATSlocal (ats_ptr_type, tmp1263) ; ATSlocal (ats_ptr_type, tmp1264) ; ATSlocal (ats_ptr_type, tmp1265) ; ATSlocal (ats_ptr_type, tmp1266) ; ATSlocal (ats_ptr_type, tmp1267) ; ATSlocal (ats_int_type, tmp1268) ; ATSlocal (ats_size_type, tmp1269) ; ATSlocal (ats_int_type, tmp1270) ; ATSlocal (ats_ptr_type, tmp1271) ; ATSlocal (ats_ptr_type, tmp1272) ; ATSlocal (ats_ptr_type, tmp1273) ; // ATSlocal_void (tmp1274) ; // ATSlocal_void (tmp1275) ; // ATSlocal_void (tmp1276) ; ATSlocal (ats_ptr_type, tmp1277) ; ATSlocal (ats_ptr_type, tmp1278) ; ATSlocal (ats_ptr_type, tmp1279) ; // ATSlocal_void (tmp1280) ; // ATSlocal_void (tmp1281) ; ATSlocal (ats_ptr_type, tmp1282) ; ATSlocal (ats_ptr_type, tmp1283) ; ATSlocal (ats_ptr_type, tmp1284) ; ATSlocal (ats_ptr_type, tmp1285) ; ATSlocal (ats_ptr_type, tmp1286) ; ATSlocal (ats_int_type, tmp1287) ; ATSlocal (ats_ptr_type, tmp1288) ; ATSlocal (ats_ptr_type, tmp1289) ; ATSlocal (ats_ptr_type, tmp1290) ; ATSlocal (ats_ptr_type, tmp1291) ; ATSlocal (ats_ptr_type, tmp1292) ; ATSlocal (ats_ptr_type, tmp1293) ; ATSlocal (ats_ptr_type, tmp1294) ; // ATSlocal_void (tmp1295) ; ATSlocal (ats_ptr_type, tmp1296) ; ATSlocal (ats_ptr_type, tmp1297) ; ATSlocal (ats_ptr_type, tmp1298) ; ATSlocal (ats_ptr_type, tmp1299) ; // ATSlocal_void (tmp1300) ; // ATSlocal_void (tmp1301) ; // ATSlocal_void (tmp1302) ; // ATSlocal_void (tmp1303) ; // ATSlocal_void (tmp1304) ; // ATSlocal_void (tmp1305) ; ATSlocal (ats_ptr_type, tmp1306) ; ATSlocal (ats_ptr_type, tmp1307) ; // ATSlocal_void (tmp1308) ; // ATSlocal_void (tmp1309) ; // ATSlocal_void (tmp1310) ; // ATSlocal_void (tmp1311) ; ATSlocal (ats_ptr_type, tmp1312) ; ATSlocal (ats_ptr_type, tmp1313) ; ATSlocal (ats_ptr_type, tmp1314) ; ATSlocal (ats_ptr_type, tmp1315) ; ATSlocal (ats_ptr_type, tmp1316) ; // ATSlocal_void (tmp1317) ; // ATSlocal_void (tmp1318) ; // ATSlocal_void (tmp1319) ; // ATSlocal_void (tmp1320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up: tmp998 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_d2exp_loc) ; tmp999 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_199 */ __ats_lab_199_0: if (((ats_sum_ptr_type)tmp999)->tag != 2) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp1000 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1001 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp1003 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp1001) ; tmp1002 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp1000, tmp1003) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_ann_type (tmp998, tmp1002, tmp1001) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp999)->tag != 3) { goto __ats_lab_204_0 ; } __ats_lab_200_1: tmp1004 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1005 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp1006 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, tmp1004), atslab_d2exp_node) ; do { /* branch: __ats_lab_201 */ __ats_lab_201_0: if (((ats_sum_ptr_type)tmp1006)->tag != 40) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp1007 = ats_caselptrlab_mac(anairiats_sum_5, tmp1006, atslab_0) ; tmp1008 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short (tmp998, tmp1007, tmp1005) ; arg0 = tmp1008 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up ; // tail call break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: if (((ats_sum_ptr_type)tmp1006)->tag != 52) { goto __ats_lab_203_0 ; } __ats_lab_202_1: tmp1009 = ats_caselptrlab_mac(anairiats_sum_5, tmp1006, atslab_0) ; tmp997 = d2exp_apps_sym_tr_up_40 (tmp998, tmp1009, tmp1005) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: __ats_lab_203_1: tmp1010 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1004) ; /* tmp1011 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp1010) ; tmp997 = d2exp_apps_tr_up_18 (tmp1010, tmp1005) ; break ; } while (0) ; break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp999)->tag != 5) { goto __ats_lab_207_0 ; } __ats_lab_204_1: tmp1012 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1013 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp1014 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp1013) ; do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (tmp1012 == (ats_sum_ptr_type)0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp1016 = ats_caselptrlab_mac(anairiats_sum_24, tmp1012, atslab_0) ; tmp1015 = tmp1016 ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: // if (tmp1012 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_206_1: tmp1015 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; } while (0) ; tmp1017 = d2explst_elt_tr_dn_70 (tmp1013, tmp1015) ; tmp1018 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype (tmp1015, tmp1014) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_arrpsz (tmp998, tmp1018, tmp1015, tmp1017) ; break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: if (((ats_sum_ptr_type)tmp999)->tag != 6) { goto __ats_lab_210_0 ; } __ats_lab_207_1: tmp1019 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_0) ; tmp1020 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_1) ; tmp1021 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_2) ; tmp1022 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_3) ; tmp1023 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_var_cst_is_ptr (tmp1020) ; if (tmp1023) { tmp1024 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2lab_ind (tmp1021, tmp1022) ; tmp1025 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1025, atslab_0, tmp1024) ; tmp1026 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp1025), atslab_1) ; tmp1027 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1026) = tmp1027 ; tmp997 = d2exp_deref_tr_up_44 (tmp998, tmp1020, tmp1025) ; } else { do { /* branch: __ats_lab_208 */ __ats_lab_208_0: if (tmp1022 == (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } tmp1028 = ats_caselptrlab_mac(anairiats_sum_6, tmp1022, atslab_1) ; if (tmp1028 != (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp1029 = ats_caselptrlab_mac(anairiats_sum_6, tmp1022, atslab_0) ; tmp1031 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1031, atslab_0, tmp1020) ; ats_selptrset_mac(anairiats_sum_6, tmp1031, atslab_1, tmp1029) ; tmp1030 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp1030)->tag = 1 ; ats_selptrset_mac(anairiats_sum_14, tmp1030, atslab_0, tmp998) ; ats_selptrset_mac(anairiats_sum_14, tmp1030, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_14, tmp1030, atslab_2, tmp1031) ; tmp1032 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1032, atslab_0, tmp1030) ; tmp1033 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp1032), atslab_1) ; tmp1034 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1033) = tmp1034 ; tmp997 = d2exp_apps_sym_tr_up_40 (tmp998, tmp1019, tmp1032) ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: __ats_lab_209_1: /* tmp1035 = */ prerr_loc_error3_0 (tmp1021) ; /* tmp1036 = */ atspre_prerr_string (ATSstrcst(": the format for array subscripts [")) ; /* tmp1037 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2explstlst (tmp1022) ; /* tmp1038 = */ atspre_prerr_string (ATSstrcst("] is not supported.")) ; /* tmp1039 = */ atspre_prerr_newline () ; /* tmp997 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } /* end of [if] */ break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)tmp999)->tag != 7) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp1040 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1041 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = d2exp_assgn_tr_up_42 (tmp998, tmp1040, tmp1041) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp999)->tag != 8) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp1042 = ats_caselptrlab_mac(anairiats_sum_28, tmp999, atslab_0) ; tmp1043 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype (tmp1042) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_bool (tmp998, tmp1043, tmp1042) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp999)->tag != 9) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp1044 = ats_caselptrlab_mac(anairiats_sum_29, tmp999, atslab_0) ; tmp1045 = ats_caselptrlab_mac(anairiats_sum_29, tmp999, atslab_1) ; tmp1046 = ats_caselptrlab_mac(anairiats_sum_29, tmp999, atslab_2) ; tmp1047 = ats_caselptrlab_mac(anairiats_sum_29, tmp999, atslab_3) ; tmp1048 = ats_caselptrlab_mac(anairiats_sum_29, tmp999, atslab_4) ; tmp1049 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_caseof_tr_dn (tmp998, tmp1044, tmp1045, tmp1046, tmp1047, tmp1048, tmp1049) ; break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: if (((ats_sum_ptr_type)tmp999)->tag != 10) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp1050 = ats_caselptrlab_mac(anairiats_sum_30, tmp999, atslab_0) ; tmp1051 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype (tmp1050) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_char (tmp998, tmp1051, tmp1050) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp999)->tag != 11) { goto __ats_lab_215_0 ; } __ats_lab_214_1: tmp1052 = ats_caselptrlab_mac(anairiats_sum_31, tmp999, atslab_0) ; tmp1053 = ats_caselptrlab_mac(anairiats_sum_31, tmp999, atslab_1) ; tmp1054 = ats_caselptrlab_mac(anairiats_sum_31, tmp999, atslab_2) ; tmp1055 = ats_caselptrlab_mac(anairiats_sum_31, tmp999, atslab_3) ; tmp997 = d2exp_con_tr_up_45 (tmp998, tmp1052, tmp1053, tmp1054, tmp1055) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp999)->tag != 14) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp1056 = ats_caselptrlab_mac(anairiats_sum_32, tmp999, atslab_0) ; tmp1057 = ats_caselptrlab_mac(anairiats_sum_32, tmp999, atslab_1) ; tmp997 = d2exp_crypt_tr_up_48 (tmp998, tmp1056, tmp1057) ; break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp999)->tag != 12) { goto __ats_lab_217_0 ; } __ats_lab_216_1: tmp1058 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up (tmp998, tmp1058) ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp999)->tag != 13) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp1059 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1060 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn (tmp1059) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cstsp (tmp998, tmp1060, tmp1059) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp999)->tag != 15) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp1061 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1062 = (ats_sum_ptr_type)0 ; tmp997 = d2exp_deref_tr_up_44 (tmp998, tmp1061, tmp1062) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp999)->tag != 16) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp1063 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_dynload (tmp998, tmp1063) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp999)->tag != 17) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp1064 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1065 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; /* tmp1066 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask (tmp1064) ; /* tmp1067 = ats_selsin_mac(tmp1066, atslab_1) */ ; tmp1068 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1065) ; /* tmp1069 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_effmask (tmp998, tmp1064, tmp1068) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp999)->tag != 18) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp1070 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_empty (tmp998, tmp1070) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: if (((ats_sum_ptr_type)tmp999)->tag != 20) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp1071 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1072 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_extval (tmp998, tmp1071, tmp1072) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: if (((ats_sum_ptr_type)tmp999)->tag != 21) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp1073 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_0) ; tmp1074 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_1) ; tmp1075 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_2) ; tmp1076 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (tmp1075) ; tmp1077 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ats_selptrset_mac(anairiats_sum_24, tmp1077, atslab_0, tmp1076) ; /* tmp1078 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_mastyp (tmp1074, tmp1077) ; /* tmp1079 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp1074, tmp1077) ; tmp1080 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1075) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_fix (tmp998, tmp1076, tmp1073, tmp1074, tmp1080) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: if (((ats_sum_ptr_type)tmp999)->tag != 24) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp1081 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1082 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = d2exp_foldat_tr_up_52 (tmp998, tmp1081, tmp1082) ; break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: if (((ats_sum_ptr_type)tmp999)->tag != 25) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp1083 = ats_caselptrlab_mac(anairiats_sum_33, tmp999, atslab_0) ; tmp1084 = ats_caselptrlab_mac(anairiats_sum_33, tmp999, atslab_1) ; tmp1085 = ats_caselptrlab_mac(anairiats_sum_33, tmp999, atslab_2) ; tmp1086 = ats_caselptrlab_mac(anairiats_sum_33, tmp999, atslab_3) ; tmp1087 = ats_caselptrlab_mac(anairiats_sum_33, tmp999, atslab_4) ; tmp1088 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ats_selptrset_mac(anairiats_sum_24, tmp1088, atslab_0, tmp1084) ; tmp1089 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ats_selptrset_mac(anairiats_sum_24, tmp1089, atslab_0, tmp1086) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up (tmp998, tmp1083, tmp1088, tmp1085, tmp1089, tmp1087) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: if (((ats_sum_ptr_type)tmp999)->tag != 26) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp1090 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1091 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = d2exp_freeat_tr_up_53 (tmp998, tmp1090, tmp1091) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: if (((ats_sum_ptr_type)tmp999)->tag != 27) { goto __ats_lab_230_0 ; } __ats_lab_227_1: tmp1092 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_0) ; tmp1093 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_1) ; tmp1094 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_2) ; tmp1095 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_3) ; do { /* branch: __ats_lab_228 */ __ats_lab_228_0: if (tmp1095 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp1096 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (tmp1095 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp1096 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; } while (0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_if_tr_dn (tmp998, tmp1092, tmp1093, tmp1094, tmp1095, tmp1096) ; break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: if (((ats_sum_ptr_type)tmp999)->tag != 22) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp1097 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1098 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_float (tmp998, tmp1098, tmp1097) ; break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: if (((ats_sum_ptr_type)tmp999)->tag != 23) { goto __ats_lab_236_0 ; } __ats_lab_231_1: tmp1099 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1101 = atsopt_floatkind_eval (tmp1099) ; do { /* branch: __ats_lab_232 */ __ats_lab_232_0: if (((ats_sum_ptr_type)tmp1101)->tag != 0) { goto __ats_lab_233_0 ; } __ats_lab_232_1: tmp1100 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_float_t0ype () ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)tmp1101)->tag != 1) { goto __ats_lab_234_0 ; } __ats_lab_233_1: tmp1100 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: if (((ats_sum_ptr_type)tmp1101)->tag != 2) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp1100 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype () ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (((ats_sum_ptr_type)tmp1101)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: /* tmp1102 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp998) ; /* tmp1103 = */ atspre_prerr_string (ATSstrcst("Internal Error: d2exp_tr: D2Efloatsp: FLOATKINDnone")) ; /* tmp1104 = */ atspre_prerr_newline () ; /* tmp1100 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_floatsp (tmp998, tmp1100, tmp1099) ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)tmp999)->tag != 28) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp1105 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1106 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp1107 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype (tmp1106) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_int (tmp998, tmp1107, tmp1105, tmp1106) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: if (((ats_sum_ptr_type)tmp999)->tag != 29) { goto __ats_lab_244_0 ; } __ats_lab_237_1: tmp1108 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1109 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp1111 = atsopt_intkind_eval (tmp1108) ; do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (((ats_sum_ptr_type)tmp1111)->tag != 1) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp1110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_intinf_t0ype (tmp1109) ; break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: if (((ats_sum_ptr_type)tmp1111)->tag != 2) { goto __ats_lab_240_0 ; } __ats_lab_239_1: tmp1110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_intinf_t0ype (tmp1109) ; break ; /* branch: __ats_lab_240 */ __ats_lab_240_0: if (((ats_sum_ptr_type)tmp1111)->tag != 3) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp1110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_intinf_t0ype (tmp1109) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: if (((ats_sum_ptr_type)tmp1111)->tag != 4) { goto __ats_lab_242_0 ; } __ats_lab_241_1: tmp1110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype () ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: if (((ats_sum_ptr_type)tmp1111)->tag != 5) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp1110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype () ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: __ats_lab_243_1: /* tmp1112 = */ prerr_loc_interror_2 (tmp998) ; /* tmp1113 = */ atspre_prerr_string (ATSstrcst(": d2exp_tr: D2Eintsp")) ; /* tmp1114 = */ atspre_prerr_newline () ; /* tmp1110 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_intsp (tmp998, tmp1110, tmp1108, tmp1109) ; break ; /* branch: __ats_lab_244 */ __ats_lab_244_0: if (((ats_sum_ptr_type)tmp999)->tag != 30) { goto __ats_lab_245_0 ; } __ats_lab_244_1: tmp1115 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_0) ; tmp1116 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_1) ; tmp1117 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_2) ; tmp1118 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_3) ; tmp1119 = (ats_sum_ptr_type)0 ; tmp1120 = d2exp_arg_body_tr_up_54 (tmp998, tmp1119, tmp1115, tmp1116, tmp1117, tmp1118) ; tmp1121 = ats_select_mac(tmp1120, atslab_0) ; tmp1122 = ats_select_mac(tmp1120, atslab_1) ; tmp1123 = ats_select_mac(tmp1120, atslab_2) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_dyn (tmp998, tmp1121, tmp1115, tmp1116, tmp1122, tmp1123) ; break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: if (((ats_sum_ptr_type)tmp999)->tag != 31) { goto __ats_lab_251_0 ; } __ats_lab_245_1: tmp1124 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_0) ; tmp1125 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_1) ; tmp1126 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_2) ; tmp1127 = ats_caselptrlab_mac(anairiats_sum_34, tmp999, atslab_3) ; tmp1128 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp1128, atslab_0, 0) ; tmp1129 = d2exp_arg_body_tr_up_54 (tmp998, tmp1128, tmp1124, tmp1125, tmp1126, tmp1127) ; tmp1130 = ats_select_mac(tmp1129, atslab_0) ; tmp1131 = ats_select_mac(tmp1129, atslab_1) ; tmp1132 = ats_select_mac(tmp1129, atslab_2) ; /* ats_int_type tmp1133 ; */ tmp1133 = 0 ; tmp1135 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, tmp1130), atslab_s2exp_node) ; do { /* branch: __ats_lab_246 */ __ats_lab_246_0: if (((ats_sum_ptr_type)tmp1135)->tag != 11) { goto __ats_lab_250_0 ; } __ats_lab_246_1: tmp1136 = ats_caselptrlab_mac(anairiats_sum_11, tmp1135, atslab_0) ; do { /* branch: __ats_lab_247 */ __ats_lab_247_0: if (tmp1136 == (ats_sum_ptr_type)0) { goto __ats_lab_248_0 ; } tmp1137 = ats_caselptrlab_mac(anairiats_sum_12, tmp1136, atslab_0) ; if (tmp1137 != 0) { goto __ats_lab_248_0 ; } __ats_lab_247_1: break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: if (tmp1136 == (ats_sum_ptr_type)0) { goto __ats_lab_249_0 ; } __ats_lab_248_1: tmp1138 = atspre_iadd (tmp1133, 1) ; tmp1133 = tmp1138 ; /* tmp1139 = */ prerr_loc_error3_0 (tmp998) ; /* tmp1140 = */ atspre_prerr_string (ATSstrcst(": a flat closure is needed.")) ; /* tmp1134 = */ atspre_prerr_newline () ; break ; /* branch: __ats_lab_249 */ __ats_lab_249_0: // if (tmp1136 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_249_1: tmp1141 = atspre_iadd (tmp1133, 1) ; tmp1133 = tmp1141 ; /* tmp1142 = */ prerr_loc_error3_0 (tmp998) ; /* tmp1143 = */ atspre_prerr_string (ATSstrcst(": a flat closure is needed.")) ; /* tmp1134 = */ atspre_prerr_newline () ; break ; } while (0) ; break ; /* branch: __ats_lab_250 */ __ats_lab_250_0: __ats_lab_250_1: break ; } while (0) ; tmp1145 = atspre_gt_int_int (tmp1133, 0) ; if (tmp1145) { /* tmp1144 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_laminit_dyn (tmp998, tmp1130, tmp1124, tmp1125, tmp1131, tmp1132) ; break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: if (((ats_sum_ptr_type)tmp999)->tag != 32) { goto __ats_lab_252_0 ; } __ats_lab_251_1: tmp1146 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_0) ; tmp1147 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_1) ; tmp1148 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_2) ; /* tmp1149 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check (tmp998, tmp1147) ; tmp1151 = ats_ptrget_mac(ats_ptr_type, tmp1146) ; /* tmp1150 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_push (tmp1151, tmp1147) ; /* tmp1152 = ats_selsin_mac(tmp1150, atslab_1) */ ; tmp1153 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1148) ; /* tmp1154 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_pop () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_met (tmp998, tmp1147, tmp1153) ; break ; /* branch: __ats_lab_252 */ __ats_lab_252_0: if (((ats_sum_ptr_type)tmp999)->tag != 33) { goto __ats_lab_253_0 ; } __ats_lab_252_1: tmp1155 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_0) ; tmp1156 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_1) ; tmp1157 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_2) ; /* tmp1158 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp1159 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp1155) ; /* tmp1160 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (tmp998, tmp1156) ; tmp1161 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1157) ; /* tmp1162 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp998) ; tmp1164 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp1161), atslab_d3exp_typ) ; tmp1163 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp1155, tmp1156, tmp1164) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lam_sta (tmp998, tmp1163, tmp1155, tmp1156, tmp1161) ; break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: if (((ats_sum_ptr_type)tmp999)->tag != 34) { goto __ats_lab_254_0 ; } __ats_lab_253_1: tmp1165 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; /* tmp1166 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp1167 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; /* tmp1168 = ats_selsin_mac(tmp1167, atslab_1) */ ; /* tmp1169 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay () ; /* tmp1170 = ats_selsin_mac(tmp1169, atslab_1) */ ; /* tmp1171 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (1) ; /* tmp1172 = ats_selsin_mac(tmp1171, atslab_1) */ ; tmp1174 = (ats_sum_ptr_type)0 ; /* tmp1173 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam (tmp1174) ; /* tmp1175 = ats_selsin_mac(tmp1173, atslab_1) */ ; tmp1176 = d2exp_lazy_delay_tr_up_55 (tmp998, tmp1165) ; /* tmp1177 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp998) ; /* tmp1178 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam (tmp998) ; /* tmp1179 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; /* tmp1180 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () ; /* tmp1181 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp1182 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp1183 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp998) ; tmp997 = tmp1176 ; break ; /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp999)->tag != 35) { goto __ats_lab_255_0 ; } __ats_lab_254_1: tmp1184 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1185 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; /* tmp1186 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp1187 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_effmask (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; /* tmp1188 = ats_selsin_mac(tmp1187, atslab_1) */ ; /* tmp1189 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push_delay () ; /* tmp1190 = ats_selsin_mac(tmp1189, atslab_1) */ ; /* tmp1191 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (1) ; /* tmp1192 = ats_selsin_mac(tmp1191, atslab_1) */ ; tmp1194 = (ats_sum_ptr_type)0 ; /* tmp1193 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_lam (tmp1194) ; /* tmp1195 = ats_selsin_mac(tmp1193, atslab_1) */ ; tmp1196 = d2exp_lazy_ldelay_tr_up_56 (tmp998, tmp1184, tmp1185) ; /* tmp1197 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp998) ; /* tmp1198 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam (tmp998) ; /* tmp1199 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; /* tmp1200 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () ; /* tmp1201 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp1202 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; /* tmp1203 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (tmp998) ; tmp997 = tmp1196 ; break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: if (((ats_sum_ptr_type)tmp999)->tag != 36) { goto __ats_lab_256_0 ; } __ats_lab_255_1: tmp1204 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1205 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; /* tmp1206 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push () ; /* tmp1207 = ats_selsin_mac(tmp1206, atslab_1) */ ; /* tmp1208 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp1209 = ats_selsin_mac(tmp1208, atslab_1) */ ; /* tmp1210 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let () ; /* tmp1211 = ats_selsin_mac(tmp1210, atslab_1) */ ; tmp1212 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp1204) ; tmp1213 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1205) ; /* tmp1214 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp998) ; /* tmp1215 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let () ; /* tmp1216 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () ; /* tmp1217 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_let (tmp998, tmp1212, tmp1213) ; break ; /* branch: __ats_lab_256 */ __ats_lab_256_0: if (((ats_sum_ptr_type)tmp999)->tag != 37) { goto __ats_lab_257_0 ; } __ats_lab_256_1: tmp1218 = ats_caselptrlab_mac(anairiats_sum_32, tmp999, atslab_0) ; tmp1219 = ats_caselptrlab_mac(anairiats_sum_32, tmp999, atslab_1) ; tmp1220 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_tup (tmp998, 0, tmp1218, tmp1219) ; arg0 = tmp1220 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up ; // tail call break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: if (((ats_sum_ptr_type)tmp999)->tag != 38) { goto __ats_lab_258_0 ; } __ats_lab_257_1: tmp1221 = ats_caselptrlab_mac(anairiats_sum_35, tmp999, atslab_0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loopexn_tr_up (tmp998, tmp1221) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp999)->tag != 39) { goto __ats_lab_261_0 ; } __ats_lab_258_1: tmp1222 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_0) ; tmp1223 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_1) ; tmp1224 = ats_caselptrlab_mac(anairiats_sum_13, tmp999, atslab_2) ; do { /* branch: __ats_lab_259 */ __ats_lab_259_0: if (tmp1223 == (ats_sum_ptr_type)0) { goto __ats_lab_260_0 ; } __ats_lab_259_1: tmp1226 = ats_caselptrlab_mac(anairiats_sum_24, tmp1223, atslab_0) ; tmp1225 = tmp1226 ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: // if (tmp1223 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_260_1: tmp1228 = atspre_gt_int_int (tmp1222, 0) ; if (tmp1228) { tmp1227 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } else { tmp1227 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ tmp1225 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, tmp1227) ; break ; } while (0) ; tmp1229 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp1224) ; tmp1230 = d2explst_elt_tr_dn_70 (tmp1224, tmp1225) ; tmp1232 = atspre_gt_int_int (tmp1222, 0) ; if (tmp1232) { tmp1231 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_viewt0ype_int_viewtype (tmp1225, tmp1229) ; } else { tmp1231 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_t0ype_int_type (tmp1225, tmp1229) ; } /* end of [if] */ tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_lst (tmp998, tmp1231, tmp1222, tmp1225, tmp1230) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)tmp999)->tag != 40) { goto __ats_lab_262_0 ; } __ats_lab_261_1: tmp1233 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1234 = (ats_sum_ptr_type)0 ; tmp1235 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_app_short (tmp998, tmp1233, tmp1234) ; arg0 = tmp1235 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up ; // tail call break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp999)->tag != 41) { goto __ats_lab_266_0 ; } __ats_lab_262_1: tmp1236 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1237 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; do { /* branch: __ats_lab_263 */ __ats_lab_263_0: if (((ats_sum_ptr_type)tmp1236)->tag != 0) { goto __ats_lab_264_0 ; } __ats_lab_263_1: tmp1238 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_cross (tmp1237) ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: if (((ats_sum_ptr_type)tmp1236)->tag != 1) { goto __ats_lab_265_0 ; } __ats_lab_264_1: tmp1238 = ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__macro_eval_decode (tmp1237) ; break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: // if (((ats_sum_ptr_type)tmp1236)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_265_1: /* tmp1239 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp998) ; /* tmp1240 = */ atspre_prerr_string (ATSstrcst(": error(macro)")) ; /* tmp1241 = */ atspre_prerr_string (ATSstrcst(": the macro syntax `(...) is incorrectly used at this location.")) ; /* tmp1242 = */ atspre_prerr_newline () ; /* tmp1238 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; arg0 = tmp1238 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up ; // tail call break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: if (((ats_sum_ptr_type)tmp999)->tag != 42) { goto __ats_lab_267_0 ; } __ats_lab_266_1: tmp1243 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = d2exp_ptrof_tr_up_57 (tmp998, tmp1243) ; break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: if (((ats_sum_ptr_type)tmp999)->tag != 43) { goto __ats_lab_268_0 ; } __ats_lab_267_1: tmp1244 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; /* tmp1245 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_exn (tmp998) ; tmp1246 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype () ; tmp1247 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp1244, tmp1246) ; tmp1248 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_uni () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_raise (tmp998, tmp1248, tmp1247) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: if (((ats_sum_ptr_type)tmp999)->tag != 44) { goto __ats_lab_269_0 ; } __ats_lab_268_1: tmp1249 = ats_caselptrlab_mac(anairiats_sum_36, tmp999, atslab_0) ; tmp1250 = ats_caselptrlab_mac(anairiats_sum_36, tmp999, atslab_1) ; tmp1251 = ats_caselptrlab_mac(anairiats_sum_36, tmp999, atslab_2) ; tmp997 = d2exp_rec_tr_up_60 (tmp998, tmp1249, tmp1250, tmp1251) ; break ; /* branch: __ats_lab_269 */ __ats_lab_269_0: if (((ats_sum_ptr_type)tmp999)->tag != 45) { goto __ats_lab_270_0 ; } __ats_lab_269_1: tmp1252 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_0) ; tmp1253 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_1) ; tmp1254 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_2) ; tmp1255 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_scaseof_tr_dn (tmp998, tmp1252, tmp1253, tmp1254, tmp1255) ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: if (((ats_sum_ptr_type)tmp999)->tag != 46) { goto __ats_lab_271_0 ; } __ats_lab_270_1: tmp1256 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1257 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = d2exp_sel_tr_up_63 (tmp998, tmp1256, tmp1257) ; break ; /* branch: __ats_lab_271 */ __ats_lab_271_0: if (((ats_sum_ptr_type)tmp999)->tag != 47) { goto __ats_lab_272_0 ; } __ats_lab_271_1: tmp1258 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = d2exp_seq_tr_up_64 (tmp998, tmp1258) ; break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: if (((ats_sum_ptr_type)tmp999)->tag != 48) { goto __ats_lab_273_0 ; } __ats_lab_272_1: tmp1259 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp1260 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1259) ; /* tmp1261 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__fshowtype_d3exp (tmp1260) ; tmp997 = tmp1260 ; break ; /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)tmp999)->tag != 49) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp1262 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_0) ; tmp1263 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_1) ; tmp1264 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_2) ; tmp1265 = ats_caselptrlab_mac(anairiats_sum_22, tmp999, atslab_3) ; tmp1266 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp998, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_sif_tr_dn (tmp998, tmp1262, tmp1263, tmp1264, tmp1265, tmp1266) ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)tmp999)->tag != 51) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp1267 = ats_caselptrlab_mac(anairiats_sum_37, tmp999, atslab_0) ; tmp1268 = ats_caselptrlab_mac(anairiats_sum_37, tmp999, atslab_1) ; tmp1269 = atspre_string_length (tmp1267) ; tmp1270 = atspre_int1_of_size1 (ats_castfn_mac(ats_size_type, tmp1269)) ; tmp1271 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type (tmp1270) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_string (tmp998, tmp1271, tmp1267, tmp1268) ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)tmp999)->tag != 53) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp1272 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1273 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; tmp997 = d2exp_tmpid_tr_up_66 (tmp998, tmp1272, tmp1273) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: if (((ats_sum_ptr_type)tmp999)->tag != 54) { goto __ats_lab_277_0 ; } __ats_lab_276_1: /* tmp1274 = */ prerr_loc_error3_0 (tmp998) ; /* tmp1275 = */ atspre_prerr_string (ATSstrcst(": the type of [?] cannot be synthesized.")) ; /* tmp1276 = */ atspre_prerr_newline () ; /* tmp997 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp999)->tag != 55) { goto __ats_lab_278_0 ; } __ats_lab_277_1: tmp1277 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_0) ; tmp1278 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_1) ; tmp1279 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_2) ; /* tmp1280 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try () ; /* tmp1281 = ats_selsin_mac(tmp1280, atslab_1) */ ; tmp1282 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1278) ; tmp1283 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp1282), atslab_d3exp_typ) ; tmp1284 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype () ; tmp1286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp1282), atslab_d3exp_loc) ; tmp1285 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_top (tmp1286, tmp1284) ; /* ats_int_type tmp1287 ; */ tmp1287 = 0 ; tmp1289 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1289, atslab_0, tmp1285) ; tmp1290 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp1289), atslab_1) ; tmp1291 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1290) = tmp1291 ; tmp1292 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1292, atslab_0, tmp1284) ; tmp1293 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_6, tmp1292), atslab_1) ; tmp1294 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp1293) = tmp1294 ; tmp1288 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__c2laulst_tr_dn (tmp998, (&tmp1287), -1, tmp1277, tmp1279, tmp1289, 1, tmp1292, tmp1283) ; /* tmp1295 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_trywith (tmp998, tmp1282, tmp1288) ; break ; /* branch: __ats_lab_278 */ __ats_lab_278_0: if (((ats_sum_ptr_type)tmp999)->tag != 56) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp1296 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up (tmp998, tmp1296) ; break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: if (((ats_sum_ptr_type)tmp999)->tag != 57) { goto __ats_lab_280_0 ; } __ats_lab_279_1: tmp1297 = ats_caselptrlab_mac(anairiats_sum_5, tmp999, atslab_0) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__d2exp_viewat_tr_up (tmp998, tmp1297) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: if (((ats_sum_ptr_type)tmp999)->tag != 58) { goto __ats_lab_281_0 ; } __ats_lab_280_1: tmp1298 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_0) ; tmp1299 = ats_caselptrlab_mac(anairiats_sum_8, tmp999, atslab_1) ; /* tmp1300 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_push () ; /* tmp1301 = ats_selsin_mac(tmp1300, atslab_1) */ ; /* tmp1302 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_push () ; /* tmp1303 = ats_selsin_mac(tmp1302, atslab_1) */ ; /* tmp1304 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let () ; /* tmp1305 = ats_selsin_mac(tmp1304, atslab_1) */ ; tmp1306 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2eclst_tr (tmp1299) ; tmp1307 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1298) ; /* tmp1308 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (tmp998) ; /* tmp1309 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let () ; /* tmp1310 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2cstlst_env_pop_and_unbind () ; /* tmp1311 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_pop () ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_where (tmp998, tmp1307, tmp1306) ; break ; /* branch: __ats_lab_281 */ __ats_lab_281_0: if (((ats_sum_ptr_type)tmp999)->tag != 59) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp1312 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_0) ; tmp1313 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_1) ; tmp1314 = ats_caselptrlab_mac(anairiats_sum_20, tmp999, atslab_2) ; tmp1315 = (ats_sum_ptr_type)0 ; tmp1316 = (ats_sum_ptr_type)0 ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up (tmp998, tmp1312, tmp1315, tmp1313, tmp1316, tmp1314) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: __ats_lab_282_1: /* tmp1317 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp998) ; /* tmp1318 = */ atspre_prerr_string (ATSstrcst(": d2exp_tr_up: not implemented yet: d2e0 = ")) ; /* tmp1319 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2exp (arg0) ; /* tmp1320 = */ atspre_prerr_newline () ; /* tmp997 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp997) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 84497(line=2469, offs=16) -- 84616(line=2472, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1321) ; ATSlocal (ats_ptr_type, tmp1322) ; ATSlocal (ats_ptr_type, tmp1323) ; ATSlocal (ats_ptr_type, tmp1324) ; ATSlocal (ats_ptr_type, tmp1325) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up: do { /* branch: __ats_lab_283 */ __ats_lab_283_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp1322 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp1323 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp1324 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (tmp1322) ; tmp1325 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up (tmp1323) ; tmp1321 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1321, atslab_0, tmp1324) ; ats_selptrset_mac(anairiats_sum_6, tmp1321, atslab_1, tmp1325) ; break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_284_1: tmp1321 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 84673(line=2475, offs=19) -- 84804(line=2478, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1326) ; ATSlocal (ats_ptr_type, tmp1327) ; ATSlocal (ats_ptr_type, tmp1328) ; ATSlocal (ats_ptr_type, tmp1329) ; ATSlocal (ats_ptr_type, tmp1330) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up: do { /* branch: __ats_lab_285 */ __ats_lab_285_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_286_0 ; } __ats_lab_285_1: tmp1327 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp1328 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp1329 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explst_tr_up (tmp1327) ; tmp1330 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up (tmp1328) ; tmp1326 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1326, atslab_0, tmp1329) ; ats_selptrset_mac(anairiats_sum_6, tmp1326, atslab_1, tmp1330) ; break ; /* branch: __ats_lab_286 */ __ats_lab_286_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_286_1: tmp1326 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1326) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2explstlst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 85210(line=2496, offs=13) -- 85394(line=2500, offs=29) */ ATSstaticdec() ats_ptr_type aux_75 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1338) ; ATSlocal (ats_ptr_type, tmp1339) ; ATSlocal (ats_ptr_type, tmp1340) ; ATSlocal (ats_ptr_type, tmp1341) ; ATSlocal (ats_ptr_type, tmp1342) ; __ats_lab_aux_75: do { /* branch: __ats_lab_288 */ __ats_lab_288_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_289_0 ; } __ats_lab_288_1: tmp1339 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp1340 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp1341 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf (tmp1339) ; tmp1342 = aux_75 (tmp1340) ; tmp1338 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1338, atslab_0, tmp1341) ; ats_selptrset_mac(anairiats_sum_6, tmp1338, atslab_1, tmp1342) ; break ; /* branch: __ats_lab_289 */ __ats_lab_289_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_289_1: tmp1338 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1338) ; } /* end of [aux_75] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 84885(line=2484, offs=3) -- 85555(line=2506, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1331) ; ATSlocal (ats_ptr_type, tmp1332) ; ATSlocal (ats_ptr_type, tmp1333) ; ATSlocal (anairiats_rec_0, tmp1334) ; ATSlocal (ats_ptr_type, tmp1335) ; ATSlocal (ats_ptr_type, tmp1336) ; ATSlocal (ats_ptr_type, tmp1337) ; ATSlocal (ats_ptr_type, tmp1343) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up: tmp1332 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (arg1) ; tmp1333 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_decarg (arg1) ; do { /* branch: __ats_lab_287 */ __ats_lab_287_0: if (tmp1333 == (ats_sum_ptr_type)0) { goto __ats_lab_290_0 ; } __ats_lab_287_1: tmp1335 = (ats_sum_ptr_type)0 ; tmp1334 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate (arg0, tmp1333, tmp1335, tmp1332) ; tmp1336 = ats_select_mac(tmp1334, atslab_0) ; tmp1337 = ats_select_mac(tmp1334, atslab_1) ; tmp1343 = aux_75 (tmp1336) ; tmp1331 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpcst (arg0, tmp1337, arg1, tmp1343) ; break ; /* branch: __ats_lab_290 */ __ats_lab_290_0: // if (tmp1333 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_290_1: tmp1331 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_cst (arg0, arg1) ; break ; } while (0) ; return (tmp1331) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cst_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 85609(line=2510, offs=4) -- 86048(line=2524, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_var_mut_tr_up_76 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1344) ; ATSlocal (ats_ptr_type, tmp1345) ; ATSlocal (anairiats_rec_0, tmp1346) ; ATSlocal (ats_ptr_type, tmp1347) ; ATSlocal (ats_ptr_type, tmp1348) ; ATSlocal (ats_ptr_type, tmp1349) ; __ats_lab_d2exp_var_mut_tr_up_76: tmp1345 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, arg1) ; tmp1347 = (ats_sum_ptr_type)0 ; tmp1346 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__s2exp_addr_deref_slablst (arg0, tmp1345, tmp1347) ; tmp1348 = ats_select_mac(tmp1346, atslab_0) ; tmp1349 = ats_select_mac(tmp1346, atslab_1) ; tmp1344 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var (arg0, tmp1348, arg1) ; return (tmp1344) ; } /* end of [d2exp_var_mut_tr_up_76] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 87369(line=2562, offs=13) -- 87530(line=2564, offs=29) */ ATSstaticdec() ats_ptr_type aux_78 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1369) ; ATSlocal (ats_ptr_type, tmp1370) ; ATSlocal (ats_ptr_type, tmp1371) ; ATSlocal (ats_ptr_type, tmp1372) ; ATSlocal (ats_ptr_type, tmp1373) ; __ats_lab_aux_78: do { /* branch: __ats_lab_293 */ __ats_lab_293_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_294_0 ; } __ats_lab_293_1: tmp1370 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp1371 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp1372 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf (tmp1370) ; tmp1373 = aux_78 (tmp1371) ; tmp1369 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp1369, atslab_0, tmp1372) ; ats_selptrset_mac(anairiats_sum_6, tmp1369, atslab_1, tmp1373) ; break ; /* branch: __ats_lab_294 */ __ats_lab_294_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_294_1: tmp1369 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp1369) ; } /* end of [aux_78] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 86085(line=2526, offs=4) -- 87639(line=2569, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_var_nonmut_tr_up_77 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1350) ; ATSlocal (ats_int_type, tmp1351) ; ATSlocal (ats_ptr_type, tmp1352) ; // ATSlocal_void (tmp1353) ; ATSlocal (ats_bool_type, tmp1354) ; ATSlocal (ats_bool_type, tmp1355) ; // ATSlocal_void (tmp1356) ; ATSlocal (ats_int_type, tmp1357) ; ATSlocal (ats_ptr_type, tmp1358) ; // ATSlocal_void (tmp1359) ; // ATSlocal_void (tmp1360) ; // ATSlocal_void (tmp1361) ; // ATSlocal_void (tmp1362) ; // ATSlocal_void (tmp1363) ; ATSlocal (ats_ptr_type, tmp1364) ; ATSlocal (anairiats_rec_0, tmp1365) ; ATSlocal (ats_ptr_type, tmp1366) ; ATSlocal (ats_ptr_type, tmp1367) ; ATSlocal (ats_ptr_type, tmp1368) ; ATSlocal (ats_ptr_type, tmp1374) ; __ats_lab_d2exp_var_nonmut_tr_up_77: tmp1351 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (arg1) ; tmp1352 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ_some (arg0, arg1) ; tmp1354 = atspre_gte_int_int (tmp1351, 0) ; if (tmp1354) { tmp1355 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local (arg1) ; if (tmp1355) { tmp1357 = atspre_add_int_int (1, tmp1351) ; /* tmp1356 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (arg1, tmp1357) ; tmp1358 = (ats_sum_ptr_type)0 ; /* tmp1353 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp1358) ; } else { /* tmp1359 = */ prerr_loc_error3_0 (arg0) ; /* tmp1360 = */ atspre_prerr_string (ATSstrcst(": the linear dynamic variable [")) ; /* tmp1361 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp1362 = */ atspre_prerr_string (ATSstrcst("] is expected to be local but it is not.")) ; /* tmp1363 = */ atspre_prerr_newline () ; /* tmp1353 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp1364 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_decarg (arg1) ; do { /* branch: __ats_lab_291 */ __ats_lab_291_0: if (tmp1364 != (ats_sum_ptr_type)0) { goto __ats_lab_292_0 ; } __ats_lab_291_1: tmp1350 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_var (arg0, tmp1352, arg1) ; break ; /* branch: __ats_lab_292 */ __ats_lab_292_0: __ats_lab_292_1: tmp1366 = (ats_sum_ptr_type)0 ; tmp1365 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate (arg0, tmp1364, tmp1366, tmp1352) ; tmp1367 = ats_select_mac(tmp1365, atslab_0) ; tmp1368 = ats_select_mac(tmp1365, atslab_1) ; tmp1374 = aux_78 (tmp1367) ; tmp1350 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_tmpvar (arg0, tmp1368, arg1, tmp1374) ; break ; } while (0) ; return (tmp1350) ; } /* end of [d2exp_var_nonmut_tr_up_77] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_exp_up.dats: 87704(line=2573, offs=3) -- 87851(line=2576, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1375) ; ATSlocal (ats_bool_type, tmp1376) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up: do { /* branch: __ats_lab_295 */ __ats_lab_295_0: __ats_lab_295_1: tmp1376 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_is_mutable (arg1) ; if (!tmp1376) { goto __ats_lab_296_1 ; } tmp1375 = d2exp_var_mut_tr_up_76 (arg0, arg1) ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: __ats_lab_296_1: tmp1375 = d2exp_var_nonmut_tr_up_77 (arg0, arg1) ; break ; } while (0) ; return (tmp1375) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_var_tr_up] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_macro2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed2exp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D23Ed3exp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGsta_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__D3EXPARGdyn_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_exp_up_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_exp_up_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_syntax_dats.c0000664000175000017500000204720012223166160021452 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "prelude/CATS/string.cats" /* type definitions */ typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_c0har_loc ; ats_char_type atslab_c0har_val ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_e0xtcode_loc ; ats_int_type atslab_e0xtcode_pos ; ats_ptr_type atslab_e0xtcode_cod ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_f0loat_loc ; ats_ptr_type atslab_f0loat_val ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_f0loatsp_loc ; ats_ptr_type atslab_f0loatsp_val ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_i0nt_loc ; ats_ptr_type atslab_i0nt_val ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_i0ntsp_loc ; ats_ptr_type atslab_i0ntsp_val ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_s0tring_loc ; ats_ptr_type atslab_s0tring_val ; ats_int_type atslab_s0tring_len ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_l0ab_loc ; ats_ptr_type atslab_l0ab_lab ; } anairiats_rec_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_e0xp_loc ; ats_ptr_type atslab_e0xp_node ; } anairiats_rec_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_s0rtq_loc ; ats_ptr_type atslab_s0rtq_node ; } anairiats_rec_17 ; typedef struct { ats_ptr_type atslab_s0rt_loc ; ats_ptr_type atslab_s0rt_node ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_s0rtpol_loc ; ats_ptr_type atslab_s0rtpol_srt ; ats_int_type atslab_s0rtpol_pol ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_d0atsrtcon_loc ; ats_ptr_type atslab_d0atsrtcon_sym ; ats_ptr_type atslab_d0atsrtcon_arg ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_d0atsrtdec_loc ; ats_ptr_type atslab_d0atsrtdec_sym ; ats_ptr_type atslab_d0atsrtdec_con ; } anairiats_rec_21 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_e0fftag_loc ; ats_ptr_type atslab_e0fftag_node ; } anairiats_rec_23 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_24 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_25 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_26 ; typedef struct { ats_ptr_type atslab_s0taq_loc ; ats_ptr_type atslab_s0taq_node ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_d0ynq_loc ; ats_ptr_type atslab_d0ynq_node ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_sqi0de_loc ; ats_ptr_type atslab_sqi0de_qua ; ats_ptr_type atslab_sqi0de_sym ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_dqi0de_loc ; ats_ptr_type atslab_dqi0de_qua ; ats_ptr_type atslab_dqi0de_sym ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_arrqi0de_loc ; ats_ptr_type atslab_arrqi0de_qua ; ats_ptr_type atslab_arrqi0de_sym ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_tmpqi0de_loc ; ats_ptr_type atslab_tmpqi0de_qua ; ats_ptr_type atslab_tmpqi0de_sym ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_d0atarg_loc ; ats_ptr_type atslab_d0atarg_node ; } anairiats_rec_33 ; typedef struct { ats_ptr_type atslab_s0arg_loc ; ats_ptr_type atslab_s0arg_sym ; ats_ptr_type atslab_s0arg_srt ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_sp0at_loc ; ats_ptr_type atslab_sp0at_node ; } anairiats_rec_35 ; typedef struct { ats_ptr_type atslab_s0exp_loc ; ats_ptr_type atslab_s0exp_node ; } anairiats_rec_36 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_37 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_38 ; typedef struct { ats_ptr_type atslab_s0arrind_loc ; ats_ptr_type atslab_s0arrind_ind ; } anairiats_rec_39 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_40 ; typedef struct { ats_ptr_type atslab_s0rtext_loc ; ats_ptr_type atslab_s0rtext_node ; } anairiats_rec_41 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_42 ; typedef struct { ats_ptr_type atslab_s0qua_loc ; ats_ptr_type atslab_s0qua_node ; } anairiats_rec_43 ; typedef struct { ats_ptr_type atslab_impqi0de_loc ; ats_ptr_type atslab_impqi0de_qua ; ats_ptr_type atslab_impqi0de_sym ; ats_ptr_type atslab_impqi0de_arg ; } anairiats_rec_44 ; typedef struct { ats_ptr_type atslab_i0nvarg_loc ; ats_ptr_type atslab_i0nvarg_sym ; ats_ptr_type atslab_i0nvarg_typ ; } anairiats_rec_45 ; typedef struct { ats_ptr_type atslab_i0nvresstate_qua ; ats_ptr_type atslab_i0nvresstate_arg ; } anairiats_rec_46 ; typedef struct { ats_ptr_type atslab_loopi0nv_qua ; ats_ptr_type atslab_loopi0nv_met ; ats_ptr_type atslab_loopi0nv_arg ; ats_ptr_type atslab_loopi0nv_res ; } anairiats_rec_47 ; typedef struct { ats_ptr_type atslab_s0rtdef_loc ; ats_ptr_type atslab_s0rtdef_sym ; ats_ptr_type atslab_s0rtdef_def ; } anairiats_rec_48 ; typedef struct { ats_ptr_type atslab_s0tacon_fil ; ats_ptr_type atslab_s0tacon_loc ; ats_ptr_type atslab_s0tacon_sym ; ats_ptr_type atslab_s0tacon_arg ; ats_ptr_type atslab_s0tacon_def ; } anairiats_rec_49 ; typedef struct { ats_ptr_type atslab_s0tacst_fil ; ats_ptr_type atslab_s0tacst_loc ; ats_ptr_type atslab_s0tacst_sym ; ats_ptr_type atslab_s0tacst_arg ; ats_ptr_type atslab_s0tacst_res ; } anairiats_rec_50 ; typedef struct { ats_ptr_type atslab_s0tavar_loc ; ats_ptr_type atslab_s0tavar_sym ; ats_ptr_type atslab_s0tavar_srt ; } anairiats_rec_51 ; typedef struct { ats_ptr_type atslab_s0expdef_loc ; ats_ptr_type atslab_s0expdef_sym ; ats_ptr_type atslab_s0expdef_loc_id ; ats_ptr_type atslab_s0expdef_arg ; ats_ptr_type atslab_s0expdef_res ; ats_ptr_type atslab_s0expdef_def ; } anairiats_rec_52 ; typedef struct { ats_ptr_type atslab_s0aspdec_fil ; ats_ptr_type atslab_s0aspdec_loc ; ats_ptr_type atslab_s0aspdec_qid ; ats_ptr_type atslab_s0aspdec_arg ; ats_ptr_type atslab_s0aspdec_res ; ats_ptr_type atslab_s0aspdec_def ; } anairiats_rec_53 ; typedef struct { ats_ptr_type atslab_d0atcon_loc ; ats_ptr_type atslab_d0atcon_sym ; ats_ptr_type atslab_d0atcon_qua ; ats_ptr_type atslab_d0atcon_arg ; ats_ptr_type atslab_d0atcon_ind ; } anairiats_rec_54 ; typedef struct { ats_ptr_type atslab_d0atdec_fil ; ats_ptr_type atslab_d0atdec_loc ; ats_ptr_type atslab_d0atdec_headloc ; ats_ptr_type atslab_d0atdec_sym ; ats_ptr_type atslab_d0atdec_arg ; ats_ptr_type atslab_d0atdec_con ; } anairiats_rec_55 ; typedef struct { ats_ptr_type atslab_e0xndec_fil ; ats_ptr_type atslab_e0xndec_loc ; ats_ptr_type atslab_e0xndec_sym ; ats_ptr_type atslab_e0xndec_qua ; ats_ptr_type atslab_e0xndec_arg ; } anairiats_rec_56 ; typedef struct { ats_ptr_type atslab_p0arg_loc ; ats_ptr_type atslab_p0arg_sym ; ats_ptr_type atslab_p0arg_ann ; } anairiats_rec_57 ; typedef struct { ats_ptr_type atslab_d0arg_loc ; ats_ptr_type atslab_d0arg_node ; } anairiats_rec_58 ; typedef struct { ats_ptr_type atslab_d0cstdec_fil ; ats_ptr_type atslab_d0cstdec_loc ; ats_ptr_type atslab_d0cstdec_sym ; ats_ptr_type atslab_d0cstdec_arg ; ats_ptr_type atslab_d0cstdec_eff ; ats_ptr_type atslab_d0cstdec_res ; ats_ptr_type atslab_d0cstdec_extdef ; } anairiats_rec_59 ; typedef struct { ats_ptr_type atslab_p0at_loc ; ats_ptr_type atslab_p0at_node ; } anairiats_rec_60 ; typedef struct { ats_ptr_type atslab_f0arg_loc ; ats_ptr_type atslab_f0arg_node ; } anairiats_rec_61 ; typedef struct { ats_ptr_type atslab_s0elop_loc ; ats_int_type atslab_s0elop_knd ; } anairiats_rec_62 ; typedef struct { ats_ptr_type atslab_d0exp_loc ; ats_ptr_type atslab_d0exp_node ; } anairiats_rec_63 ; typedef struct { ats_ptr_type atslab_d0arrind_loc ; ats_ptr_type atslab_d0arrind_ind ; } anairiats_rec_64 ; typedef struct { ats_ptr_type atslab_c0lau_loc ; ats_ptr_type atslab_c0lau_pat ; ats_int_type atslab_c0lau_seq ; ats_int_type atslab_c0lau_neg ; ats_ptr_type atslab_c0lau_body ; } anairiats_rec_65 ; typedef struct { ats_ptr_type atslab_casehead_tok ; ats_int_type atslab_casehead_knd ; ats_ptr_type atslab_casehead_inv ; } anairiats_rec_66 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_67 ; typedef struct { ats_ptr_type atslab_loophead_tok ; ats_ptr_type atslab_loophead_inv ; } anairiats_rec_68 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_69 ; typedef struct { ats_ptr_type atslab_ifhead_tok ; ats_ptr_type atslab_ifhead_inv ; } anairiats_rec_70 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_71 ; typedef struct { ats_ptr_type atslab_sc0lau_loc ; ats_ptr_type atslab_sc0lau_pat ; ats_ptr_type atslab_sc0lau_body ; } anairiats_rec_72 ; typedef struct { ats_ptr_type atslab_tryhead_tok ; ats_ptr_type atslab_tryhead_inv ; } anairiats_rec_73 ; typedef struct { ats_ptr_type atslab_m0atch_loc ; ats_ptr_type atslab_m0atch_exp ; ats_ptr_type atslab_m0atch_pat ; } anairiats_rec_74 ; typedef struct { ats_ptr_type atslab_guap0at_loc ; ats_ptr_type atslab_guap0at_pat ; ats_ptr_type atslab_guap0at_gua ; } anairiats_rec_75 ; typedef struct { ats_ptr_type atslab_v0aldec_loc ; ats_ptr_type atslab_v0aldec_pat ; ats_ptr_type atslab_v0aldec_def ; ats_ptr_type atslab_v0aldec_ann ; } anairiats_rec_76 ; typedef struct { ats_ptr_type atslab_f0undec_loc ; ats_ptr_type atslab_f0undec_sym ; ats_ptr_type atslab_f0undec_sym_loc ; ats_ptr_type atslab_f0undec_arg ; ats_ptr_type atslab_f0undec_eff ; ats_ptr_type atslab_f0undec_res ; ats_ptr_type atslab_f0undec_def ; ats_ptr_type atslab_f0undec_ann ; } anairiats_rec_77 ; typedef struct { ats_ptr_type atslab_v0ardec_loc ; ats_int_type atslab_v0ardec_knd ; ats_ptr_type atslab_v0ardec_sym ; ats_ptr_type atslab_v0ardec_sym_loc ; ats_ptr_type atslab_v0ardec_typ ; ats_ptr_type atslab_v0ardec_wth ; ats_ptr_type atslab_v0ardec_ini ; } anairiats_rec_78 ; typedef struct { ats_ptr_type atslab_m0acdef_loc ; ats_ptr_type atslab_m0acdef_sym ; ats_ptr_type atslab_m0acdef_arg ; ats_ptr_type atslab_m0acdef_def ; } anairiats_rec_79 ; typedef struct { ats_ptr_type atslab_i0mpdec_loc ; ats_ptr_type atslab_i0mpdec_qid ; ats_ptr_type atslab_i0mpdec_arg ; ats_ptr_type atslab_i0mpdec_res ; ats_ptr_type atslab_i0mpdec_def ; } anairiats_rec_80 ; typedef struct { ats_ptr_type atslab_d0ec_loc ; ats_ptr_type atslab_d0ec_node ; } anairiats_rec_81 ; typedef struct { ats_ptr_type atslab_guad0ec_loc ; ats_ptr_type atslab_guad0ec_node ; } anairiats_rec_82 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCrgt_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDtype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDt0ype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewt0ype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDfun_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDval_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDcastfn_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDpraxi_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprfun_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprval_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDtype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDview_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDviewtype_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDgeneric_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDprop_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDtype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalminus_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfn_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfnstar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfun_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDcastfn_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDlam_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatlam_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDllam_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatllam_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDfix_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDatfix_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LAMKINDifix_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDif_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifdef_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifndef_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDTOK_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECint_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECide_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECinc_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0RECdec_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPeval_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPfloat_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPide_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPlist_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPstring_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQstr_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQsym_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTide_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTqid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTlist_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTtup_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGvar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGprf_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGlin_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGfun_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGclo_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQfildot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymcolon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQsymdot_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQfildot_symcolon_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymcolon_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQsymdot_symcolon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ATARGidsrt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SP0Tcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__T1MPS0EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABS0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0QUAvars_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXT_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Echar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eexi_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eextype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eide_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eimp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eint_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elam_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Elist2_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eopide_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eqid_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyarr_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etyrec_ext_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Etytup2_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Euni_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0Eunion_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYinf_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpre_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0XTYpos_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTassert_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTerror_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTprint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGsta_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0ARGdyn2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__M0ACARGlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEprop_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEtype_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEview_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEviewtype_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tchar_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Texist_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfloat_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tfree_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tide_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tint_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlist2_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Topide_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tqid_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trec_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tref_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Trefas_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tstring_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Tsvararg_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__P0Ttup2_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGdyn_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta1_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGsta2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__F0ARGmet_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Cone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ctwo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__GD0Ccons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfixity_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cnonfix_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpundef_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ce0xpact_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatsrts_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csrtdefs_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacons_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstacsts_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstavars_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cclassdec_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextype_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextval_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cextcode_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_par_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvaldecs_rec_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cvardecs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cmacdefs_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdynload_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cstaload_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Clocal_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cguadec_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABD0EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrinit_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrpsz_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Earrsub_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecaseof_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Echar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecstsp_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ecrypt_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edecseq_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edelay_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edynload_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eempty_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eexist_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eextval_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efix_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloat_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efloatsp_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efoldat_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efor_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Efreeat_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eide_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eidext_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eif_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eint_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eintsp_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elam_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elet_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elist2_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eloopexn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Elst_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Emacsyn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eopide_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eptrof_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eqid_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eraise_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Erec_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Escaseof_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_lab_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esel_ind_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eseq_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esexparg_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eshowtype_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Esif_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Estring_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etmpid_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etop_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etrywith_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etup2_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhere_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Ewhile_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0CLLSTcons_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_int_of_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, atspre_stropt_none) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTLT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSLTGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IN) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_sym) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0de_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0de_make_lrbrackets) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, fprint_s0rt) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0rtopt_none) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, e0fftaglst_nil) () ; ATSextern_fun(ats_ptr_type, e0fftaglstopt_none) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0taq_none) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0ynq_none) () ; ATSextern_fun(ats_ptr_type, sqi0de_make_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, dqi0de_make_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, arrqi0de_make_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, tmpqi0de_make_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0arg_make_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, s0explst_nil) () ; ATSextern_fun(ats_ptr_type, s0expopt_none) () ; ATSextern_fun(ats_ptr_type, s0expopt_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, gtlt_t1mps0expseqseq_nil) () ; ATSextern_fun(ats_ptr_type, s0qualstopt_none) () ; ATSextern_fun(ats_ptr_type, p0arg_make_none) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, p0arglst_nil) () ; ATSextern_fun(ats_ptr_type, p0arglst_cons) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, p0at_apps) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, p0atopt_none) () ; ATSextern_fun(ats_ptr_type, p0atopt_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, i0nvarglst_nil) () ; ATSextern_fun(ats_ptr_type, i0nvresstate_none) () ; ATSextern_fun(ats_ptr_type, d0exp_apps) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0exp_arrinit) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0exp_list) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0exp_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0expopt_none) () ; ATSextern_fun(ats_ptr_type, d0expopt_some) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, m0atchlst_nil) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error0_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_ptr_type lamkind_get_loc_51 (ats_ptr_type arg0) ; static ats_void_type aux_68 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_141 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type name_is_prf_149 (ats_ptr_type arg0) ; static ats_bool_type name_is_lin0_150 (ats_ptr_type arg0) ; static ats_bool_type name_is_lin1_151 (ats_ptr_type arg0) ; static ats_bool_type name_is_fun0_152 (ats_ptr_type arg0) ; static ats_bool_type name_is_fun1_153 (ats_ptr_type arg0) ; static ats_bool_type name_is_linfun0_154 (ats_ptr_type arg0) ; static ats_bool_type name_is_linfun1_155 (ats_ptr_type arg0) ; static ats_bool_type name_is_clo0_156 (ats_ptr_type arg0) ; static ats_bool_type name_is_clo1_157 (ats_ptr_type arg0) ; static ats_bool_type name_is_linclo0_158 (ats_ptr_type arg0) ; static ats_bool_type name_is_linclo1_159 (ats_ptr_type arg0) ; static ats_bool_type name_is_cloptr0_160 (ats_ptr_type arg0) ; static ats_bool_type name_is_cloptr1_161 (ats_ptr_type arg0) ; static ats_bool_type name_is_lincloptr0_162 (ats_ptr_type arg0) ; static ats_bool_type name_is_lincloptr1_163 (ats_ptr_type arg0) ; static ats_bool_type name_is_cloref0_164 (ats_ptr_type arg0) ; static ats_bool_type name_is_cloref1_165 (ats_ptr_type arg0) ; static ats_ptr_type aux_213 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type gtlt_t1mps0expseqseq_cons_loc_212 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type loop_223 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s0exp_lam_229 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_231 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_231_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_231_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_loc_303 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d0atdec_make_302 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type p0at_app_336 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d0exp_app_376 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_loc_385 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_397 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_397_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_397_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_400 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_400_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_400_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d0exp_macsyn_414 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_424 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_434 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux1_460 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_461 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type f0undec_make_476 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type v0ardec_make_483 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type aux1_loc_493 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux2_loc_494 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_loc_507 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_509 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_511 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_513 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_515 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_517 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d0ec_sexpdefs_main_516 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_521 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux1_loc_523 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux2_loc_524 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_526 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux1_loc_538 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux2_loc_539 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_544 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_546 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_loc_548 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type d0ecllst_revapp_556 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2243(line=78, offs=4) -- 2330(line=80, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error0_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error0_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(0)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error0_0] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2364(line=83, offs=4) -- 2419(line=83, offs=59) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_syntax)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2465(line=87, offs=24) -- 2484(line=87, offs=43) */ ATSglobaldec() ats_ptr_type abskind_prop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_abskind_prop: tmp3 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDprop_0) ; return (tmp3) ; } /* end of [abskind_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2508(line=88, offs=24) -- 2527(line=88, offs=43) */ ATSglobaldec() ats_ptr_type abskind_type () { /* local vardec */ ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_abskind_type: tmp4 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDtype_1) ; return (tmp4) ; } /* end of [abskind_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2552(line=89, offs=25) -- 2572(line=89, offs=45) */ ATSglobaldec() ats_ptr_type abskind_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_abskind_t0ype: tmp5 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDt0ype_2) ; return (tmp5) ; } /* end of [abskind_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2596(line=90, offs=24) -- 2615(line=90, offs=43) */ ATSglobaldec() ats_ptr_type abskind_view () { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_abskind_view: tmp6 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDview_3) ; return (tmp6) ; } /* end of [abskind_view] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2643(line=91, offs=28) -- 2666(line=91, offs=51) */ ATSglobaldec() ats_ptr_type abskind_viewtype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_abskind_viewtype: tmp7 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewtype_4) ; return (tmp7) ; } /* end of [abskind_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2695(line=92, offs=29) -- 2719(line=92, offs=53) */ ATSglobaldec() ats_ptr_type abskind_viewt0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_abskind_viewt0ype: tmp8 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__ABSKINDviewt0ype_5) ; return (tmp8) ; } /* end of [abskind_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2765(line=96, offs=24) -- 2784(line=96, offs=43) */ ATSglobaldec() ats_ptr_type dcstkind_fun () { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_dcstkind_fun: tmp9 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDfun_0) ; return (tmp9) ; } /* end of [dcstkind_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2808(line=97, offs=24) -- 2827(line=97, offs=43) */ ATSglobaldec() ats_ptr_type dcstkind_val () { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_dcstkind_val: tmp10 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDval_1) ; return (tmp10) ; } /* end of [dcstkind_val] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2854(line=98, offs=27) -- 2876(line=98, offs=49) */ ATSglobaldec() ats_ptr_type dcstkind_castfn () { /* local vardec */ ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_dcstkind_castfn: tmp11 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDcastfn_2) ; return (tmp11) ; } /* end of [dcstkind_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2902(line=99, offs=26) -- 2923(line=99, offs=47) */ ATSglobaldec() ats_ptr_type dcstkind_praxi () { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_dcstkind_praxi: tmp12 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDpraxi_3) ; return (tmp12) ; } /* end of [dcstkind_praxi] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2949(line=100, offs=26) -- 2970(line=100, offs=47) */ ATSglobaldec() ats_ptr_type dcstkind_prfun () { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_dcstkind_prfun: tmp13 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprfun_4) ; return (tmp13) ; } /* end of [dcstkind_prfun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 2996(line=101, offs=26) -- 3017(line=101, offs=47) */ ATSglobaldec() ats_ptr_type dcstkind_prval () { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_dcstkind_prval: tmp14 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTKINDprval_5) ; return (tmp14) ; } /* end of [dcstkind_prval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3045(line=104, offs=17) -- 3103(line=105, offs=40) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp15 = ats_true_bool ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp15 = ats_false_bool ; break ; } while (0) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3134(line=108, offs=20) -- 3195(line=109, offs=43) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_castfn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_castfn: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp16 = ats_true_bool ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp16 = ats_false_bool ; break ; } while (0) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3225(line=112, offs=19) -- 3285(line=113, offs=42) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_praxi (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_praxi: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp17 = ats_true_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp17 = ats_false_bool ; break ; } while (0) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_praxi] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3315(line=116, offs=19) -- 3375(line=117, offs=42) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prfun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prfun: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp18 = ats_true_bool ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: tmp18 = ats_false_bool ; break ; } while (0) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prfun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3405(line=120, offs=19) -- 3465(line=121, offs=42) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prval (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prval: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp19 = ats_true_bool ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: tmp19 = ats_false_bool ; break ; } while (0) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_prval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3495(line=124, offs=19) -- 3617(line=130, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp20 = ats_true_bool ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp20 = ats_true_bool ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp20 = ats_true_bool ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp20 = ats_false_bool ; break ; } while (0) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstkind_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 3677(line=134, offs=17) -- 4060(line=140, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_dcstkind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_dcstkind: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDfun")) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_16_0 ; } __ats_lab_15_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDval")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDcastfn")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_18_0 ; } __ats_lab_17_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDpraxi")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_19_0 ; } __ats_lab_18_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDprfun")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (((ats_sum_ptr_type)arg1)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: /* tmp21 = */ atspre_fprint_string (arg0, ATSstrcst("DCSTKINDprval")) ; break ; } while (0) ; return /* (tmp21) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_dcstkind] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4135(line=145, offs=25) -- 4155(line=145, offs=45) */ ATSglobaldec() ats_ptr_type datakind_prop () { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_datakind_prop: tmp22 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDprop_0) ; return (tmp22) ; } /* end of [datakind_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4180(line=146, offs=25) -- 4200(line=146, offs=45) */ ATSglobaldec() ats_ptr_type datakind_type () { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_datakind_type: tmp23 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDtype_1) ; return (tmp23) ; } /* end of [datakind_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4225(line=147, offs=25) -- 4245(line=147, offs=45) */ ATSglobaldec() ats_ptr_type datakind_view () { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_datakind_view: tmp24 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDview_2) ; return (tmp24) ; } /* end of [datakind_view] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4274(line=148, offs=29) -- 4298(line=148, offs=53) */ ATSglobaldec() ats_ptr_type datakind_viewtype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_datakind_viewtype: tmp25 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDviewtype_3) ; return (tmp25) ; } /* end of [datakind_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4328(line=150, offs=29) -- 4415(line=153, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp26 = ats_true_bool ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp26 = ats_true_bool ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp26 = ats_false_bool ; break ; } while (0) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__datakind_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4497(line=158, offs=30) -- 4522(line=158, offs=55) */ ATSglobaldec() ats_ptr_type stadefkind_generic () { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_stadefkind_generic: tmp27 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__STADEFKINDgeneric_0) ; return (tmp27) ; } /* end of [stadefkind_generic] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4549(line=159, offs=27) -- 4572(line=159, offs=50) */ ATSglobaldec() ats_ptr_type stadefkind_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; __ats_lab_stadefkind_prop: tmp28 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp28)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp28, atslab_0, arg0) ; return (tmp28) ; } /* end of [stadefkind_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4600(line=160, offs=27) -- 4623(line=160, offs=50) */ ATSglobaldec() ats_ptr_type stadefkind_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; __ats_lab_stadefkind_type: tmp29 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp29)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp29, atslab_0, arg0) ; return (tmp29) ; } /* end of [stadefkind_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4651(line=161, offs=27) -- 4674(line=161, offs=50) */ ATSglobaldec() ats_ptr_type stadefkind_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_stadefkind_view: tmp30 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp30)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp30, atslab_0, arg0) ; return (tmp30) ; } /* end of [stadefkind_view] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4706(line=162, offs=31) -- 4733(line=162, offs=58) */ ATSglobaldec() ats_ptr_type stadefkind_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_stadefkind_viewtype: tmp31 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp31)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp31, atslab_0, arg0) ; return (tmp31) ; } /* end of [stadefkind_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4779(line=166, offs=23) -- 4797(line=166, offs=41) */ ATSglobaldec() ats_ptr_type valkind_val () { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_valkind_val: tmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDval_0) ; return (tmp32) ; } /* end of [valkind_val] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4825(line=167, offs=28) -- 4848(line=167, offs=51) */ ATSglobaldec() ats_ptr_type valkind_valminus () { /* local vardec */ ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_valkind_valminus: tmp33 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalminus_1) ; return (tmp33) ; } /* end of [valkind_valminus] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4875(line=168, offs=27) -- 4897(line=168, offs=49) */ ATSglobaldec() ats_ptr_type valkind_valplus () { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_valkind_valplus: tmp34 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDvalplus_2) ; return (tmp34) ; } /* end of [valkind_valplus] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4922(line=169, offs=25) -- 4942(line=169, offs=45) */ ATSglobaldec() ats_ptr_type valkind_prval () { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_valkind_prval: tmp35 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__VALKINDprval_3) ; return (tmp35) ; } /* end of [valkind_prval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 4971(line=171, offs=28) -- 5030(line=173, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp36) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp36 = ats_true_bool ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp36 = ats_false_bool ; break ; } while (0) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__valkind_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5103(line=178, offs=22) -- 5120(line=178, offs=39) */ ATSglobaldec() ats_ptr_type funkind_fn () { /* local vardec */ ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_funkind_fn: tmp37 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfn_0) ; return (tmp37) ; } /* end of [funkind_fn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5146(line=179, offs=26) -- 5167(line=179, offs=47) */ ATSglobaldec() ats_ptr_type funkind_fnstar () { /* local vardec */ ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_funkind_fnstar: tmp38 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfnstar_1) ; return (tmp38) ; } /* end of [funkind_fnstar] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5190(line=180, offs=23) -- 5208(line=180, offs=41) */ ATSglobaldec() ats_ptr_type funkind_fun () { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_funkind_fun: tmp39 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDfun_2) ; return (tmp39) ; } /* end of [funkind_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5234(line=181, offs=26) -- 5255(line=181, offs=47) */ ATSglobaldec() ats_ptr_type funkind_castfn () { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; __ats_lab_funkind_castfn: tmp40 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDcastfn_5) ; return (tmp40) ; } /* end of [funkind_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5279(line=182, offs=24) -- 5298(line=182, offs=43) */ ATSglobaldec() ats_ptr_type funkind_prfn () { /* local vardec */ ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_funkind_prfn: tmp41 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfn_3) ; return (tmp41) ; } /* end of [funkind_prfn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5323(line=183, offs=25) -- 5343(line=183, offs=45) */ ATSglobaldec() ats_ptr_type funkind_prfun () { /* local vardec */ ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_funkind_prfun: tmp42 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNKINDprfun_4) ; return (tmp42) ; } /* end of [funkind_prfun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5372(line=186, offs=18) -- 5556(line=192, offs=28) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp43 = ats_false_bool ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp43 = ats_false_bool ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp43 = ats_false_bool ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp43 = ats_false_bool ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp43 = ats_true_bool ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp43 = ats_true_bool ; break ; } while (0) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5618(line=196, offs=22) -- 5800(line=202, offs=28) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp44) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp44 = ats_false_bool ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp44 = ats_true_bool ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp44 = ats_true_bool ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp44 = ats_true_bool ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp44 = ats_false_bool ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp44 = ats_true_bool ; break ; } while (0) ; return (tmp44) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_recursive] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 5866(line=205, offs=32) -- 5922(line=206, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_tailrecur (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_tailrecur: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp45 = ats_true_bool ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: __ats_lab_38_1: tmp45 = ats_false_bool ; break ; } while (0) ; return (tmp45) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__funkind_is_tailrecur] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6000(line=211, offs=23) -- 6019(line=211, offs=42) */ ATSglobaldec() ats_ptr_type lamkind_lam (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_lamkind_lam: tmp46 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp46)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp46, atslab_0, arg0) ; return (tmp46) ; } /* end of [lamkind_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6045(line=212, offs=25) -- 6066(line=212, offs=46) */ ATSglobaldec() ats_ptr_type lamkind_atlam (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_lamkind_atlam: tmp47 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp47)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp47, atslab_0, arg0) ; return (tmp47) ; } /* end of [lamkind_atlam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6091(line=213, offs=24) -- 6111(line=213, offs=44) */ ATSglobaldec() ats_ptr_type lamkind_llam (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_lamkind_llam: tmp48 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp48)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp48, atslab_0, arg0) ; return (tmp48) ; } /* end of [lamkind_llam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6138(line=214, offs=26) -- 6160(line=214, offs=48) */ ATSglobaldec() ats_ptr_type lamkind_atllam (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_lamkind_atllam: tmp49 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp49)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp49, atslab_0, arg0) ; return (tmp49) ; } /* end of [lamkind_atllam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6185(line=216, offs=23) -- 6204(line=216, offs=42) */ ATSglobaldec() ats_ptr_type fixkind_fix (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_fixkind_fix: tmp50 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp50)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp50, atslab_0, arg0) ; return (tmp50) ; } /* end of [fixkind_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6230(line=217, offs=25) -- 6251(line=217, offs=46) */ ATSglobaldec() ats_ptr_type fixkind_atfix (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_fixkind_atfix: tmp51 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp51)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp51, atslab_0, arg0) ; return (tmp51) ; } /* end of [fixkind_atfix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6258(line=219, offs=5) -- 6557(line=227, offs=27) */ ATSstaticdec() ats_ptr_type lamkind_get_loc_51 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_lamkind_get_loc_51: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp53, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp54, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp55, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp56, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp57, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_selsin_mac(tmp58, atslab_t0kn_loc) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (((ats_sum_ptr_type)arg0)->tag != 6) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = tmp59 ; break ; } while (0) ; return (tmp52) ; } /* end of [lamkind_get_loc_51] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6654(line=232, offs=27) -- 6692(line=232, offs=65) */ ATSglobaldec() ats_ptr_type srpifkindtok_if (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; __ats_lab_srpifkindtok_if: tmp61 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDif_0) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp60, atslab_0, tmp61) ; ats_selptrset_mac(anairiats_sum_1, tmp60, atslab_1, arg0) ; return (tmp60) ; } /* end of [srpifkindtok_if] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6722(line=233, offs=30) -- 6763(line=233, offs=71) */ ATSglobaldec() ats_ptr_type srpifkindtok_ifdef (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; __ats_lab_srpifkindtok_ifdef: tmp63 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifdef_1) ; tmp62 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp62, atslab_0, tmp63) ; ats_selptrset_mac(anairiats_sum_1, tmp62, atslab_1, arg0) ; return (tmp62) ; } /* end of [srpifkindtok_ifdef] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6794(line=234, offs=31) -- 6836(line=234, offs=73) */ ATSglobaldec() ats_ptr_type srpifkindtok_ifndef (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; __ats_lab_srpifkindtok_ifndef: tmp65 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifndef_2) ; tmp64 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp64, atslab_0, tmp65) ; ats_selptrset_mac(anairiats_sum_1, tmp64, atslab_1, arg0) ; return (tmp64) ; } /* end of [srpifkindtok_ifndef] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 6882(line=239, offs=14) -- 7038(line=241, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp66) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst("#FILENAME")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (((ats_sum_ptr_type)arg1)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst("#LOCATION")) ; break ; } while (0) ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7106(line=246, offs=21) -- 7132(line=246, offs=47) */ ATSglobaldec() ats_ptr_type t0kn_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_t0kn_make: tmp67 = arg0 ; return (tmp67) ; } /* end of [t0kn_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7176(line=250, offs=22) -- 7226(line=251, offs=38) */ ATSglobaldec() ats_ptr_type c0har_make (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp68) ; __ats_lab_c0har_make: tmp68 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp68, atslab_c0har_loc, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp68, atslab_c0har_val, arg1) ; return (tmp68) ; } /* end of [c0har_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7252(line=253, offs=25) -- 7332(line=254, offs=63) */ ATSglobaldec() ats_ptr_type e0xtcode_make (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_e0xtcode_make: tmp69 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp69, atslab_e0xtcode_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp69, atslab_e0xtcode_pos, arg1) ; ats_selptrset_mac(anairiats_rec_3, tmp69, atslab_e0xtcode_cod, arg2) ; return (tmp69) ; } /* end of [e0xtcode_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7356(line=256, offs=23) -- 7408(line=257, offs=40) */ ATSglobaldec() ats_ptr_type f0loat_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp70) ; __ats_lab_f0loat_make: tmp70 = ATS_MALLOC(sizeof(anairiats_rec_4)) ; ats_selptrset_mac(anairiats_rec_4, tmp70, atslab_f0loat_loc, arg0) ; ats_selptrset_mac(anairiats_rec_4, tmp70, atslab_f0loat_val, arg1) ; return (tmp70) ; } /* end of [f0loat_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7434(line=259, offs=25) -- 7490(line=260, offs=44) */ ATSglobaldec() ats_ptr_type f0loatsp_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp71) ; __ats_lab_f0loatsp_make: tmp71 = ATS_MALLOC(sizeof(anairiats_rec_5)) ; ats_selptrset_mac(anairiats_rec_5, tmp71, atslab_f0loatsp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_5, tmp71, atslab_f0loatsp_val, arg1) ; return (tmp71) ; } /* end of [f0loatsp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7512(line=262, offs=21) -- 7560(line=263, offs=36) */ ATSglobaldec() ats_ptr_type i0nt_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_i0nt_make: tmp72 = ATS_MALLOC(sizeof(anairiats_rec_6)) ; ats_selptrset_mac(anairiats_rec_6, tmp72, atslab_i0nt_loc, arg0) ; ats_selptrset_mac(anairiats_rec_6, tmp72, atslab_i0nt_val, arg1) ; return (tmp72) ; } /* end of [i0nt_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7584(line=265, offs=23) -- 7636(line=266, offs=40) */ ATSglobaldec() ats_ptr_type i0ntsp_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp73) ; __ats_lab_i0ntsp_make: tmp73 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp73, atslab_i0ntsp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_7, tmp73, atslab_i0ntsp_val, arg1) ; return (tmp73) ; } /* end of [i0ntsp_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7661(line=268, offs=24) -- 7738(line=269, offs=60) */ ATSglobaldec() ats_ptr_type s0tring_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp74) ; __ats_lab_s0tring_make: tmp74 = ATS_MALLOC(sizeof(anairiats_rec_8)) ; ats_selptrset_mac(anairiats_rec_8, tmp74, atslab_s0tring_loc, arg0) ; ats_selptrset_mac(anairiats_rec_8, tmp74, atslab_s0tring_val, arg1) ; ats_selptrset_mac(anairiats_rec_8, tmp74, atslab_s0tring_len, arg2) ; return (tmp74) ; } /* end of [s0tring_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7783(line=273, offs=23) -- 7844(line=274, offs=45) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de: tmp76 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp76) ; return /* (tmp75) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7867(line=276, offs=22) -- 7899(line=276, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_i0de (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; // ATSlocal_void (tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_i0de: tmp78 = atspre_stdout_get () ; tmp79 = ats_selsin_mac(tmp78, atslab_1) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (tmp79, arg0) ; /* tmp77 = */ atspre_stdout_view_set () ; return /* (tmp77) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_i0de] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7921(line=277, offs=22) -- 7953(line=277, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_i0de (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; // ATSlocal_void (tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_i0de: tmp82 = atspre_stderr_get () ; tmp83 = ats_selsin_mac(tmp82, atslab_1) ; /* tmp84 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (tmp83, arg0) ; /* tmp81 = */ atspre_stderr_view_set () ; return /* (tmp81) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_i0de] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8019(line=285, offs=5) -- 8241(line=296, offs=2) */ ATSstaticdec() ats_void_type aux_68 (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; __ats_lab_aux_68: do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (arg0, tmp87) ; /* tmp86 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: /* tmp86 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (arg0, arg1) ; break ; } while (0) ; return /* (tmp86) */ ; } /* end of [aux_68] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 7990(line=283, offs=7) -- 8318(line=300, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0delst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp85) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0delst: do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp85 = */ aux_68 (arg0, tmp89, tmp90) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: break ; } while (0) ; return /* (tmp85) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0delst] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8371(line=304, offs=21) -- 8554(line=313, offs=6) */ ATSglobaldec() ats_ptr_type i0de_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_i0de_make: tmp92 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg1) ; tmp91 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp91, atslab_i0de_loc, arg0) ; ats_selptrset_mac(anairiats_rec_9, tmp91, atslab_i0de_sym, tmp92) ; return (tmp91) ; } /* end of [i0de_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8608(line=315, offs=31) -- 8678(line=316, offs=63) */ ATSglobaldec() ats_ptr_type i0de_make_ampersand (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_i0de_make_ampersand: tmp94 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp93 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp93, atslab_i0de_loc, tmp94) ; ats_selptrset_mac(anairiats_rec_9, tmp93, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND) ; return (tmp93) ; } /* end of [i0de_make_ampersand] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8709(line=317, offs=31) -- 8779(line=318, offs=63) */ ATSglobaldec() ats_ptr_type i0de_make_backslash (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; __ats_lab_i0de_make_backslash: tmp96 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp95 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp95, atslab_i0de_loc, tmp96) ; ats_selptrset_mac(anairiats_rec_9, tmp95, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; return (tmp95) ; } /* end of [i0de_make_backslash] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8805(line=319, offs=26) -- 8870(line=320, offs=58) */ ATSglobaldec() ats_ptr_type i0de_make_bang (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; __ats_lab_i0de_make_bang: tmp98 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp97 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp97, atslab_i0de_loc, tmp98) ; ats_selptrset_mac(anairiats_rec_9, tmp97, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; return (tmp97) ; } /* end of [i0de_make_bang] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8894(line=321, offs=24) -- 8957(line=322, offs=56) */ ATSglobaldec() ats_ptr_type i0de_make_eq (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; __ats_lab_i0de_make_eq: tmp100 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp99 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp99, atslab_i0de_loc, tmp100) ; ats_selptrset_mac(anairiats_rec_9, tmp99, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; return (tmp99) ; } /* end of [i0de_make_eq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 8981(line=323, offs=24) -- 9044(line=324, offs=56) */ ATSglobaldec() ats_ptr_type i0de_make_gt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; __ats_lab_i0de_make_gt: tmp102 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp101 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp101, atslab_i0de_loc, tmp102) ; ats_selptrset_mac(anairiats_rec_9, tmp101, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; return (tmp101) ; } /* end of [i0de_make_gt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9070(line=325, offs=26) -- 9135(line=326, offs=58) */ ATSglobaldec() ats_ptr_type i0de_make_gtlt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; __ats_lab_i0de_make_gtlt: tmp104 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp103 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp103, atslab_i0de_loc, tmp104) ; ats_selptrset_mac(anairiats_rec_9, tmp103, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTLT) ; return (tmp103) ; } /* end of [i0de_make_gtlt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9159(line=327, offs=24) -- 9222(line=328, offs=56) */ ATSglobaldec() ats_ptr_type i0de_make_lt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; __ats_lab_i0de_make_lt: tmp106 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp105 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_i0de_loc, tmp106) ; ats_selptrset_mac(anairiats_rec_9, tmp105, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; return (tmp105) ; } /* end of [i0de_make_lt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9251(line=329, offs=29) -- 9319(line=330, offs=61) */ ATSglobaldec() ats_ptr_type i0de_make_minusgt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_i0de_make_minusgt: tmp108 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp107 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp107, atslab_i0de_loc, tmp108) ; ats_selptrset_mac(anairiats_rec_9, tmp107, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; return (tmp107) ; } /* end of [i0de_make_minusgt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9350(line=331, offs=31) -- 9420(line=332, offs=63) */ ATSglobaldec() ats_ptr_type i0de_make_minusltgt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_i0de_make_minusltgt: tmp110 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp109 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp109, atslab_i0de_loc, tmp110) ; ats_selptrset_mac(anairiats_rec_9, tmp109, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSLTGT) ; return (tmp109) ; } /* end of [i0de_make_minusltgt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9447(line=333, offs=27) -- 9513(line=334, offs=59) */ ATSglobaldec() ats_ptr_type i0de_make_r0ead (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_i0de_make_r0ead: tmp112 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp111 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp111, atslab_i0de_loc, tmp112) ; ats_selptrset_mac(anairiats_rec_9, tmp111, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD) ; return (tmp111) ; } /* end of [i0de_make_r0ead] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9540(line=335, offs=27) -- 9606(line=336, offs=59) */ ATSglobaldec() ats_ptr_type i0de_make_tilde (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; __ats_lab_i0de_make_tilde: tmp114 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp113 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_i0de_loc, tmp114) ; ats_selptrset_mac(anairiats_rec_9, tmp113, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; return (tmp113) ; } /* end of [i0de_make_tilde] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9634(line=338, offs=27) -- 9700(line=339, offs=59) */ ATSglobaldec() ats_ptr_type i0de_make_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; __ats_lab_i0de_make_t0ype: tmp116 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp115 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp115, atslab_i0de_loc, tmp116) ; ats_selptrset_mac(anairiats_rec_9, tmp115, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; return (tmp115) ; } /* end of [i0de_make_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9759(line=341, offs=31) -- 9829(line=342, offs=63) */ ATSglobaldec() ats_ptr_type i0de_make_viewt0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; __ats_lab_i0de_make_viewt0ype: tmp118 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp117 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp117, atslab_i0de_loc, tmp118) ; ats_selptrset_mac(anairiats_rec_9, tmp117, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; return (tmp117) ; } /* end of [i0de_make_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9889(line=346, offs=24) -- 9952(line=347, offs=56) */ ATSglobaldec() ats_ptr_type i0de_make_DO (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_i0de_make_DO: tmp120 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp119 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp119, atslab_i0de_loc, tmp120) ; ats_selptrset_mac(anairiats_rec_9, tmp119, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO) ; return (tmp119) ; } /* end of [i0de_make_DO] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 9976(line=348, offs=24) -- 10039(line=349, offs=56) */ ATSglobaldec() ats_ptr_type i0de_make_IN (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; __ats_lab_i0de_make_IN: tmp122 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp121 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_i0de_loc, tmp122) ; ats_selptrset_mac(anairiats_rec_9, tmp121, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IN) ; return (tmp121) ; } /* end of [i0de_make_IN] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10066(line=350, offs=27) -- 10132(line=351, offs=59) */ ATSglobaldec() ats_ptr_type i0de_make_WHILE (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; __ats_lab_i0de_make_WHILE: tmp124 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp123 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp123, atslab_i0de_loc, tmp124) ; ats_selptrset_mac(anairiats_rec_9, tmp123, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; return (tmp123) ; } /* end of [i0de_make_WHILE] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10168(line=355, offs=22) -- 10295(line=359, offs=6) */ ATSglobaldec() ats_ptr_type i0de_make_lrbrackets (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_i0de_make_lrbrackets: tmp127 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp128 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp127, tmp128) ; tmp125 = ATS_MALLOC(sizeof(anairiats_rec_9)) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_i0de_loc, tmp126) ; ats_selptrset_mac(anairiats_rec_9, tmp125, atslab_i0de_sym, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; return (tmp125) ; } /* end of [i0de_make_lrbrackets] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10356(line=363, offs=23) -- 10367(line=363, offs=34) */ ATSglobaldec() ats_ptr_type i0delst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_i0delst_nil: tmp129 = (ats_sum_ptr_type)0 ; return (tmp129) ; } /* end of [i0delst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10391(line=364, offs=24) -- 10413(line=364, offs=46) */ ATSglobaldec() ats_ptr_type i0delst_sing (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_i0delst_sing: tmp131 = (ats_sum_ptr_type)0 ; tmp130 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp130, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp130, atslab_1, tmp131) ; return (tmp130) ; } /* end of [i0delst_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10437(line=365, offs=24) -- 10459(line=365, offs=46) */ ATSglobaldec() ats_ptr_type i0delst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp132) ; __ats_lab_i0delst_cons: tmp132 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp132, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp132, atslab_1, arg1) ; return (tmp132) ; } /* end of [i0delst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10486(line=367, offs=26) -- 10497(line=367, offs=37) */ ATSglobaldec() ats_ptr_type i0delstlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_i0delstlst_nil: tmp133 = (ats_sum_ptr_type)0 ; return (tmp133) ; } /* end of [i0delstlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10524(line=368, offs=27) -- 10546(line=368, offs=49) */ ATSglobaldec() ats_ptr_type i0delstlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; __ats_lab_i0delstlst_cons: tmp134 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp134, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp134, atslab_1, arg1) ; return (tmp134) ; } /* end of [i0delstlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10588(line=372, offs=20) -- 10698(line=376, offs=6) */ ATSglobaldec() ats_ptr_type l0ab_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; __ats_lab_l0ab_ide: tmp137 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp136 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_sym (tmp137) ; tmp138 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp135 = ATS_MALLOC(sizeof(anairiats_rec_10)) ; ats_selptrset_mac(anairiats_rec_10, tmp135, atslab_l0ab_loc, tmp138) ; ats_selptrset_mac(anairiats_rec_10, tmp135, atslab_l0ab_lab, tmp136) ; return (tmp135) ; } /* end of [l0ab_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10740(line=378, offs=20) -- 10864(line=382, offs=6) */ ATSglobaldec() ats_ptr_type l0ab_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_int_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_l0ab_int: tmp142 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp141 = atspre_int_of_string (tmp142) ; tmp140 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__label_make_int (tmp141) ; tmp143 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp139 = ATS_MALLOC(sizeof(anairiats_rec_10)) ; ats_selptrset_mac(anairiats_rec_10, tmp139, atslab_l0ab_loc, tmp143) ; ats_selptrset_mac(anairiats_rec_10, tmp139, atslab_l0ab_lab, tmp140) ; return (tmp139) ; } /* end of [l0ab_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 10931(line=386, offs=24) -- 11033(line=390, offs=4) */ ATSglobaldec() ats_ptr_type stai0de_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_stai0de_make: tmp147 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp147) ; tmp145 = atspre_string_append (ATSstrcst("$"), tmp146) ; tmp148 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp144 = i0de_make (tmp148, tmp145) ; return (tmp144) ; } /* end of [stai0de_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11154(line=396, offs=21) -- 11169(line=396, offs=36) */ ATSglobaldec() ats_ptr_type p0rec_emp () { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_p0rec_emp: tmp149 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp149)->tag = 0 ; ats_selptrset_mac(anairiats_sum_11, tmp149, atslab_0, 0) ; return (tmp149) ; } /* end of [p0rec_emp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11190(line=397, offs=21) -- 11230(line=397, offs=61) */ ATSglobaldec() ats_ptr_type p0rec_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_int_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; __ats_lab_p0rec_int: tmp152 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp151 = atspre_int_of_string (tmp152) ; tmp150 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp150)->tag = 0 ; ats_selptrset_mac(anairiats_sum_11, tmp150, atslab_0, tmp151) ; return (tmp150) ; } /* end of [p0rec_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11252(line=398, offs=21) -- 11271(line=398, offs=40) */ ATSglobaldec() ats_ptr_type p0rec_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp153) ; __ats_lab_p0rec_ide: tmp153 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp153)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp153, atslab_0, arg0) ; return (tmp153) ; } /* end of [p0rec_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11293(line=399, offs=21) -- 11686(line=408, offs=8) */ ATSglobaldec() ats_ptr_type p0rec_opr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_bool_type, tmp156) ; ATSlocal (ats_int_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; __ats_lab_p0rec_opr: tmp155 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp156 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp155, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; if (!tmp156) { goto __ats_lab_53_1 ; } tmp158 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_i0nt_val) ; tmp157 = atspre_int_of_string (tmp158) ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_12, tmp154, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_12, tmp154, atslab_1, tmp157) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: tmp159 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp155, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; if (!tmp159) { goto __ats_lab_54_1 ; } tmp161 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg2), atslab_i0nt_val) ; tmp160 = atspre_int_of_string (tmp161) ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp154)->tag = 3 ; ats_selptrset_mac(anairiats_sum_12, tmp154, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_12, tmp154, atslab_1, tmp160) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp163 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; /* tmp162 = */ prerr_loc_error0_0 (tmp163) ; /* tmp164 = */ atspre_prerr_string (ATSstrcst(": the symbol [")) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp155) ; /* tmp166 = */ atspre_prerr_string (ATSstrcst("] must be either '+' or '-'.")) ; /* tmp167 = */ atspre_prerr_newline () ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp154) ; } /* end of [p0rec_opr] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11767(line=413, offs=23) -- 11778(line=413, offs=34) */ ATSglobaldec() ats_ptr_type e0xplst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_e0xplst_nil: tmp168 = (ats_sum_ptr_type)0 ; return (tmp168) ; } /* end of [e0xplst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11802(line=414, offs=24) -- 11824(line=414, offs=46) */ ATSglobaldec() ats_ptr_type e0xplst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp169) ; __ats_lab_e0xplst_cons: tmp169 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp169, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp169, atslab_1, arg1) ; return (tmp169) ; } /* end of [e0xplst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11849(line=416, offs=24) -- 11861(line=416, offs=36) */ ATSglobaldec() ats_ptr_type e0xpopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_e0xpopt_none: tmp170 = (ats_sum_ptr_type)0 ; return (tmp170) ; } /* end of [e0xpopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11885(line=417, offs=24) -- 11898(line=417, offs=37) */ ATSglobaldec() ats_ptr_type e0xpopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; __ats_lab_e0xpopt_some: tmp171 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp171, atslab_0, arg0) ; return (tmp171) ; } /* end of [e0xpopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 11941(line=421, offs=20) -- 12063(line=424, offs=6) */ ATSglobaldec() ats_ptr_type e0xp_app (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_e0xp_app: tmp174 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_e0xp_loc) ; tmp175 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_e0xp_loc) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp174, tmp175) ; tmp176 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp176)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp176, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp176, atslab_1, arg1) ; tmp172 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp172, atslab_e0xp_loc, tmp173) ; ats_selptrset_mac(anairiats_rec_14, tmp172, atslab_e0xp_node, tmp176) ; return (tmp172) ; } /* end of [e0xp_app] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12085(line=426, offs=21) -- 12150(line=427, offs=62) */ ATSglobaldec() ats_ptr_type e0xp_char (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_char_type, tmp180) ; __ats_lab_e0xp_char: tmp178 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_loc) ; tmp180 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_val) ; tmp179 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp179)->tag = 1 ; ats_selptrset_mac(anairiats_sum_16, tmp179, atslab_0, tmp180) ; tmp177 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp177, atslab_e0xp_loc, tmp178) ; ats_selptrset_mac(anairiats_rec_14, tmp177, atslab_e0xp_node, tmp179) ; return (tmp177) ; } /* end of [e0xp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12172(line=429, offs=21) -- 12299(line=433, offs=6) */ ATSglobaldec() ats_ptr_type e0xp_eval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; __ats_lab_e0xp_eval: tmp183 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp184 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp182 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp183, tmp184) ; tmp185 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp185)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp185, atslab_0, arg1) ; tmp181 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp181, atslab_e0xp_loc, tmp182) ; ats_selptrset_mac(anairiats_rec_14, tmp181, atslab_e0xp_node, tmp185) ; return (tmp181) ; } /* end of [e0xp_eval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12344(line=435, offs=22) -- 12412(line=436, offs=65) */ ATSglobaldec() ats_ptr_type e0xp_float (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_e0xp_float: tmp187 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_loc) ; tmp189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_val) ; tmp188 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp188)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp188, atslab_0, tmp189) ; tmp186 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp186, atslab_e0xp_loc, tmp187) ; ats_selptrset_mac(anairiats_rec_14, tmp186, atslab_e0xp_node, tmp188) ; return (tmp186) ; } /* end of [e0xp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12433(line=438, offs=20) -- 12498(line=439, offs=61) */ ATSglobaldec() ats_ptr_type e0xp_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; __ats_lab_e0xp_ide: tmp191 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp193 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp192 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp192)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp192, atslab_0, tmp193) ; tmp190 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp190, atslab_e0xp_loc, tmp191) ; ats_selptrset_mac(anairiats_rec_14, tmp190, atslab_e0xp_node, tmp192) ; return (tmp190) ; } /* end of [e0xp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12519(line=441, offs=20) -- 12581(line=442, offs=59) */ ATSglobaldec() ats_ptr_type e0xp_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; __ats_lab_e0xp_int: tmp195 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp197 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp196 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp196)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp196, atslab_0, tmp197) ; tmp194 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp194, atslab_e0xp_loc, tmp195) ; ats_selptrset_mac(anairiats_rec_14, tmp194, atslab_e0xp_node, tmp196) ; return (tmp194) ; } /* end of [e0xp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12603(line=444, offs=21) -- 12732(line=448, offs=6) */ ATSglobaldec() ats_ptr_type e0xp_list (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_e0xp_list: tmp200 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp201 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp199 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp200, tmp201) ; tmp202 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp202)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp202, atslab_0, arg1) ; tmp198 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp198, atslab_e0xp_loc, tmp199) ; ats_selptrset_mac(anairiats_rec_14, tmp198, atslab_e0xp_node, tmp202) ; return (tmp198) ; } /* end of [e0xp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12778(line=450, offs=23) -- 12867(line=453, offs=2) */ ATSglobaldec() ats_ptr_type e0xp_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_int_type, tmp207) ; __ats_lab_e0xp_string: tmp204 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp206 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_len) ; tmp205 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp205)->tag = 7 ; ats_selptrset_mac(anairiats_sum_12, tmp205, atslab_0, tmp206) ; ats_selptrset_mac(anairiats_sum_12, tmp205, atslab_1, tmp207) ; tmp203 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp203, atslab_e0xp_loc, tmp204) ; ats_selptrset_mac(anairiats_rec_14, tmp203, atslab_e0xp_node, tmp205) ; return (tmp203) ; } /* end of [e0xp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12893(line=455, offs=25) -- 12966(line=457, offs=2) */ ATSglobaldec() ats_ptr_type e0xp_FILENAME (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_e0xp_FILENAME: tmp209 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp211 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; tmp210 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp210)->tag = 8 ; ats_selptrset_mac(anairiats_sum_0, tmp210, atslab_0, tmp211) ; tmp208 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp208, atslab_e0xp_loc, tmp209) ; ats_selptrset_mac(anairiats_rec_14, tmp208, atslab_e0xp_node, tmp210) ; return (tmp208) ; } /* end of [e0xp_FILENAME] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 12992(line=459, offs=25) -- 13065(line=461, offs=2) */ ATSglobaldec() ats_ptr_type e0xp_LOCATION (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_e0xp_LOCATION: tmp213 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp215 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; tmp214 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp214)->tag = 8 ; ats_selptrset_mac(anairiats_sum_0, tmp214, atslab_0, tmp215) ; tmp212 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp212, atslab_e0xp_loc, tmp213) ; ats_selptrset_mac(anairiats_rec_14, tmp212, atslab_e0xp_node, tmp214) ; return (tmp212) ; } /* end of [e0xp_LOCATION] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13113(line=467, offs=3) -- 13488(line=479, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; // ATSlocal_void (tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; // ATSlocal_void (tmp223) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq: tmp217 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg1), atslab_s0rtq_node) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp217)->tag != 0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp217)->tag != 1) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_0, tmp217, atslab_0) ; /* tmp219 = */ atspre_fprint_char (arg0, '"') ; /* tmp220 = */ atspre_fprint_string (arg0, tmp218) ; /* tmp221 = */ atspre_fprint_char (arg0, '"') ; /* tmp216 = */ atspre_fprint_char (arg0, '.') ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (((ats_sum_ptr_type)tmp217)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_0, tmp217, atslab_0) ; /* tmp223 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp222) ; /* tmp216 = */ atspre_fprint_char (arg0, '.') ; break ; } while (0) ; return /* (tmp216) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13558(line=482, offs=23) -- 13591(line=482, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0rtq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; // ATSlocal_void (tmp227) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0rtq: tmp225 = atspre_stdout_get () ; tmp226 = ats_selsin_mac(tmp225, atslab_1) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq (tmp226, arg0) ; /* tmp224 = */ atspre_stdout_view_set () ; return /* (tmp224) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0rtq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13614(line=483, offs=23) -- 13647(line=483, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; // ATSlocal_void (tmp231) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq: tmp229 = atspre_stderr_get () ; tmp230 = ats_selsin_mac(tmp229, atslab_1) ; /* tmp231 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq (tmp230, arg0) ; /* tmp228 = */ atspre_stderr_view_set () ; return /* (tmp228) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0rtq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13691(line=487, offs=22) -- 13759(line=489, offs=2) */ ATSglobaldec() ats_ptr_type s0rtq_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; __ats_lab_s0rtq_none: tmp233 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0RTQnone_0) ; tmp232 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp232, atslab_s0rtq_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_17, tmp232, atslab_s0rtq_node, tmp233) ; return (tmp232) ; } /* end of [s0rtq_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13781(line=491, offs=21) -- 13854(line=493, offs=2) */ ATSglobaldec() ats_ptr_type s0rtq_str (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; __ats_lab_s0rtq_str: tmp235 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp237 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp236 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp236)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp236, atslab_0, tmp237) ; tmp234 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp234, atslab_s0rtq_loc, tmp235) ; ats_selptrset_mac(anairiats_rec_17, tmp234, atslab_s0rtq_node, tmp236) ; return (tmp234) ; } /* end of [s0rtq_str] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13876(line=495, offs=21) -- 13946(line=497, offs=2) */ ATSglobaldec() ats_ptr_type s0rtq_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; __ats_lab_s0rtq_sym: tmp239 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp240 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp240)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp240, atslab_0, tmp241) ; tmp238 = ATS_MALLOC(sizeof(anairiats_rec_17)) ; ats_selptrset_mac(anairiats_rec_17, tmp238, atslab_s0rtq_loc, tmp239) ; ats_selptrset_mac(anairiats_rec_17, tmp238, atslab_s0rtq_node, tmp240) ; return (tmp238) ; } /* end of [s0rtq_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 13991(line=501, offs=23) -- 14796(line=525, offs=8) */ ATSglobaldec() ats_void_type fprint_s0rt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; // ATSlocal_void (tmp246) ; // ATSlocal_void (tmp247) ; // ATSlocal_void (tmp248) ; // ATSlocal_void (tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; __ats_lab_fprint_s0rt: tmp243 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_node) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp243)->tag != 0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp244 = ats_caselptrlab_mac(anairiats_sum_15, tmp243, atslab_0) ; tmp245 = ats_caselptrlab_mac(anairiats_sum_15, tmp243, atslab_1) ; /* tmp246 = */ atspre_fprint_string (arg0, ATSstrcst("S0RTapp(")) ; /* tmp247 = */ fprint_s0rt (arg0, tmp244) ; /* tmp248 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp249 = */ fprint_s0rt (arg0, tmp245) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp243)->tag != 1) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp250 = ats_caselptrlab_mac(anairiats_sum_0, tmp243, atslab_0) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("S0RTid(")) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp250) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp243)->tag != 2) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_15, tmp243, atslab_0) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_15, tmp243, atslab_1) ; /* tmp255 = */ atspre_fprint_string (arg0, ATSstrcst("S0RTqid(")) ; /* tmp256 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq (arg0, tmp253) ; /* tmp257 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp254) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp243)->tag != 3) { goto __ats_lab_62_0 ; } __ats_lab_61_1: /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst("S0RTlist(...)")) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (((ats_sum_ptr_type)tmp243)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst("S0RTtup(...)")) ; break ; } while (0) ; return /* (tmp242) */ ; } /* end of [fprint_s0rt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 14841(line=529, offs=23) -- 14852(line=529, offs=34) */ ATSglobaldec() ats_ptr_type s0rtlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; __ats_lab_s0rtlst_nil: tmp258 = (ats_sum_ptr_type)0 ; return (tmp258) ; } /* end of [s0rtlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 14876(line=530, offs=24) -- 14898(line=530, offs=46) */ ATSglobaldec() ats_ptr_type s0rtlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp259) ; __ats_lab_s0rtlst_cons: tmp259 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp259, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp259, atslab_1, arg1) ; return (tmp259) ; } /* end of [s0rtlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 14923(line=532, offs=24) -- 14935(line=532, offs=36) */ ATSglobaldec() ats_ptr_type s0rtopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_s0rtopt_none: tmp260 = (ats_sum_ptr_type)0 ; return (tmp260) ; } /* end of [s0rtopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 14959(line=533, offs=24) -- 14972(line=533, offs=37) */ ATSglobaldec() ats_ptr_type s0rtopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; __ats_lab_s0rtopt_some: tmp261 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp261, atslab_0, arg0) ; return (tmp261) ; } /* end of [s0rtopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 14999(line=537, offs=21) -- 15069(line=539, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; __ats_lab_s0rt_prop: tmp263 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp264)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp264, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; tmp262 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp262, atslab_s0rt_loc, tmp263) ; ats_selptrset_mac(anairiats_rec_18, tmp262, atslab_s0rt_node, tmp264) ; return (tmp262) ; } /* end of [s0rt_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15091(line=541, offs=21) -- 15161(line=543, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; __ats_lab_s0rt_type: tmp266 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp267 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp267)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp267, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; tmp265 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp265, atslab_s0rt_loc, tmp266) ; ats_selptrset_mac(anairiats_rec_18, tmp265, atslab_s0rt_node, tmp267) ; return (tmp265) ; } /* end of [s0rt_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15184(line=545, offs=22) -- 15255(line=547, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; __ats_lab_s0rt_t0ype: tmp269 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp270 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp270)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp270, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; tmp268 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp268, atslab_s0rt_loc, tmp269) ; ats_selptrset_mac(anairiats_rec_18, tmp268, atslab_s0rt_node, tmp270) ; return (tmp268) ; } /* end of [s0rt_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15277(line=549, offs=21) -- 15347(line=551, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; __ats_lab_s0rt_view: tmp272 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp273 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp273)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp273, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; tmp271 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp271, atslab_s0rt_loc, tmp272) ; ats_selptrset_mac(anairiats_rec_18, tmp271, atslab_s0rt_node, tmp273) ; return (tmp271) ; } /* end of [s0rt_view] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15373(line=553, offs=25) -- 15447(line=555, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; __ats_lab_s0rt_viewtype: tmp275 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp276 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp276)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp276, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; tmp274 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp274, atslab_s0rt_loc, tmp275) ; ats_selptrset_mac(anairiats_rec_18, tmp274, atslab_s0rt_node, tmp276) ; return (tmp274) ; } /* end of [s0rt_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15474(line=557, offs=26) -- 15549(line=559, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_viewt0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; __ats_lab_s0rt_viewt0ype: tmp278 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp279 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp279)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp279, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; tmp277 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp277, atslab_s0rt_loc, tmp278) ; ats_selptrset_mac(anairiats_rec_18, tmp277, atslab_s0rt_node, tmp279) ; return (tmp277) ; } /* end of [s0rt_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15574(line=563, offs=20) -- 15909(line=572, offs=4) */ ATSglobaldec() ats_ptr_type s0rt_app (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; __ats_lab_s0rt_app: tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0rt_loc) ; tmp283 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_loc) ; tmp281 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp282, tmp283) ; tmp284 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp284)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp284, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp284, atslab_1, arg1) ; tmp280 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp280, atslab_s0rt_loc, tmp281) ; ats_selptrset_mac(anairiats_rec_18, tmp280, atslab_s0rt_node, tmp284) ; return (tmp280) ; } /* end of [s0rt_app] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 15951(line=574, offs=20) -- 16018(line=576, offs=2) */ ATSglobaldec() ats_ptr_type s0rt_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; __ats_lab_s0rt_ide: tmp286 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp288 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp287 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp287)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp287, atslab_0, tmp288) ; tmp285 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp285, atslab_s0rt_loc, tmp286) ; ats_selptrset_mac(anairiats_rec_18, tmp285, atslab_s0rt_node, tmp287) ; return (tmp285) ; } /* end of [s0rt_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16039(line=578, offs=20) -- 16168(line=581, offs=6) */ ATSglobaldec() ats_ptr_type s0rt_qid (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; __ats_lab_s0rt_qid: tmp291 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_17, arg0), atslab_s0rtq_loc) ; tmp292 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp290 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp291, tmp292) ; tmp294 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp293 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp293)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp293, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp293, atslab_1, tmp294) ; tmp289 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp289, atslab_s0rt_loc, tmp290) ; ats_selptrset_mac(anairiats_rec_18, tmp289, atslab_s0rt_node, tmp293) ; return (tmp289) ; } /* end of [s0rt_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16190(line=583, offs=21) -- 16495(line=592, offs=4) */ ATSglobaldec() ats_ptr_type s0rt_list (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; __ats_lab_s0rt_list: tmp297 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp298 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp296 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp297, tmp298) ; tmp299 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp299)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp299, atslab_0, arg1) ; tmp295 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp295, atslab_s0rt_loc, tmp296) ; ats_selptrset_mac(anairiats_rec_18, tmp295, atslab_s0rt_node, tmp299) ; return (tmp295) ; } /* end of [s0rt_list] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16516(line=594, offs=20) -- 16652(line=597, offs=6) */ ATSglobaldec() ats_ptr_type s0rt_tup (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; __ats_lab_s0rt_tup: tmp302 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp303 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp301 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp302, tmp303) ; tmp304 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp304)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp304, atslab_0, arg1) ; tmp300 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp300, atslab_s0rt_loc, tmp301) ; ats_selptrset_mac(anairiats_rec_18, tmp300, atslab_s0rt_node, tmp304) ; return (tmp300) ; } /* end of [s0rt_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16698(line=601, offs=24) -- 16779(line=603, offs=2) */ ATSglobaldec() ats_ptr_type s0rtpol_make (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; __ats_lab_s0rtpol_make: tmp306 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0rt_loc) ; tmp305 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp305, atslab_s0rtpol_loc, tmp306) ; ats_selptrset_mac(anairiats_rec_19, tmp305, atslab_s0rtpol_srt, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp305, atslab_s0rtpol_pol, arg1) ; return (tmp305) ; } /* end of [s0rtpol_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16833(line=607, offs=32) -- 16929(line=610, offs=2) */ ATSglobaldec() ats_ptr_type d0atsrtcon_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; __ats_lab_d0atsrtcon_make_none: tmp308 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp309 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp310 = (ats_sum_ptr_type)0 ; tmp307 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp307, atslab_d0atsrtcon_loc, tmp308) ; ats_selptrset_mac(anairiats_rec_20, tmp307, atslab_d0atsrtcon_sym, tmp309) ; ats_selptrset_mac(anairiats_rec_20, tmp307, atslab_d0atsrtcon_arg, tmp310) ; return (tmp307) ; } /* end of [d0atsrtcon_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 16995(line=612, offs=32) -- 17147(line=616, offs=6) */ ATSglobaldec() ats_ptr_type d0atsrtcon_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; __ats_lab_d0atsrtcon_make_some: tmp313 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp314 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_loc) ; tmp312 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp313, tmp314) ; tmp315 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp316 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp316, atslab_0, arg1) ; tmp311 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp311, atslab_d0atsrtcon_loc, tmp312) ; ats_selptrset_mac(anairiats_rec_20, tmp311, atslab_d0atsrtcon_sym, tmp315) ; ats_selptrset_mac(anairiats_rec_20, tmp311, atslab_d0atsrtcon_arg, tmp316) ; return (tmp311) ; } /* end of [d0atsrtcon_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17210(line=618, offs=29) -- 17221(line=618, offs=40) */ ATSglobaldec() ats_ptr_type d0atsrtconlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_d0atsrtconlst_nil: tmp317 = (ats_sum_ptr_type)0 ; return (tmp317) ; } /* end of [d0atsrtconlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17251(line=619, offs=30) -- 17273(line=619, offs=52) */ ATSglobaldec() ats_ptr_type d0atsrtconlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; __ats_lab_d0atsrtconlst_cons: tmp318 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp318, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp318, atslab_1, arg1) ; return (tmp318) ; } /* end of [d0atsrtconlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17343(line=624, offs=7) -- 17521(line=628, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_141 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; __ats_lab_aux_loc_141: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp321 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp322 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp321 ; arg2 = tmp322 ; goto __ats_lab_aux_loc_141 ; // tail call break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: tmp323 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp324 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg1), atslab_d0atsrtcon_loc) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp323, tmp324) ; break ; } while (0) ; return (tmp320) ; } /* end of [aux_loc_141] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17322(line=623, offs=27) -- 17716(line=634, offs=6) */ ATSglobaldec() ats_ptr_type d0atsrtdec_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; __ats_lab_d0atsrtdec_make: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp327 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp325 = aux_loc_141 (arg0, tmp326, tmp327) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: tmp325 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; break ; } while (0) ; tmp328 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp319 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp319, atslab_d0atsrtdec_loc, tmp325) ; ats_selptrset_mac(anairiats_rec_21, tmp319, atslab_d0atsrtdec_sym, tmp328) ; ats_selptrset_mac(anairiats_rec_21, tmp319, atslab_d0atsrtdec_con, arg1) ; return (tmp319) ; } /* end of [d0atsrtdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17774(line=636, offs=29) -- 17785(line=636, offs=40) */ ATSglobaldec() ats_ptr_type d0atsrtdeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp329) ; __ats_lab_d0atsrtdeclst_nil: tmp329 = (ats_sum_ptr_type)0 ; return (tmp329) ; } /* end of [d0atsrtdeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17815(line=637, offs=30) -- 17837(line=637, offs=52) */ ATSglobaldec() ats_ptr_type d0atsrtdeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp330) ; __ats_lab_d0atsrtdeclst_cons: tmp330 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp330, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp330, atslab_1, arg1) ; return (tmp330) ; } /* end of [d0atsrtdeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 17884(line=642, offs=15) -- 18031(line=644, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp331) ; ATSlocal (ats_int_type, tmp332) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo: do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp332 = ats_caselptrlab_mac(anairiats_sum_22, arg1, atslab_0) ; /* tmp331 = */ atspre_fprintf_exn (arg0, ATSstrcst("clo(%i)"), tmp332) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_68_1: /* tmp331 = */ atspre_fprint_string (arg0, ATSstrcst("fun")) ; break ; } while (0) ; return /* (tmp331) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18082(line=647, offs=24) -- 18118(line=647, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_funclo (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; // ATSlocal_void (tmp336) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_funclo: tmp334 = atspre_stdout_get () ; tmp335 = ats_selsin_mac(tmp334, atslab_1) ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (tmp335, arg0) ; /* tmp333 = */ atspre_stdout_view_set () ; return /* (tmp333) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18142(line=648, offs=24) -- 18178(line=648, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; // ATSlocal_void (tmp340) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo: tmp338 = atspre_stderr_get () ; tmp339 = ats_selsin_mac(tmp338, atslab_1) ; /* tmp340 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (tmp339, arg0) ; /* tmp337 = */ atspre_stderr_view_set () ; return /* (tmp337) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18207(line=651, offs=18) -- 18370(line=656, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp341) ; ATSlocal (ats_int_type, tmp342) ; ATSlocal (ats_int_type, tmp343) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo: do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_71_1 ; } __ats_lab_69_2: tmp342 = ats_caselptrlab_mac(anairiats_sum_22, arg0, atslab_0) ; tmp343 = ats_caselptrlab_mac(anairiats_sum_22, arg1, atslab_0) ; tmp341 = atspre_eq_int_int (tmp342, tmp343) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_71_1 ; } __ats_lab_70_2: tmp341 = ats_true_bool ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: __ats_lab_71_2: tmp341 = ats_false_bool ; break ; } while (0) ; return (tmp341) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18444(line=660, offs=23) -- 18576(line=664, offs=6) */ ATSglobaldec() ats_ptr_type e0fftag_cst (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; __ats_lab_e0fftag_cst: tmp346 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp346) ; tmp347 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp348 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp348)->tag = 0 ; ats_selptrset_mac(anairiats_sum_24, tmp348, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp348, atslab_1, tmp345) ; tmp344 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp344, atslab_e0fftag_loc, tmp347) ; ats_selptrset_mac(anairiats_rec_23, tmp344, atslab_e0fftag_node, tmp348) ; return (tmp344) ; } /* end of [e0fftag_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18612(line=668, offs=4) -- 18659(line=668, offs=51) */ ATSstaticdec() ats_bool_type name_is_prf_149 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp349) ; __ats_lab_name_is_prf_149: tmp349 = atspre_eq_string_string (arg0, ATSstrcst("prf")) ; return (tmp349) ; } /* end of [name_is_prf_149] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18668(line=672, offs=4) -- 18751(line=673, offs=47) */ ATSstaticdec() ats_bool_type name_is_lin0_150 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp350) ; ATSlocal (ats_bool_type, tmp351) ; __ats_lab_name_is_lin0_150: tmp351 = atspre_eq_string_string (arg0, ATSstrcst("lin")) ; if (tmp351) { tmp350 = ats_true_bool ; } else { tmp350 = atspre_eq_string_string (arg0, ATSstrcst("lin0")) ; } /* end of [if] */ return (tmp350) ; } /* end of [name_is_lin0_150] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18755(line=674, offs=4) -- 18804(line=674, offs=53) */ ATSstaticdec() ats_bool_type name_is_lin1_151 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp352) ; __ats_lab_name_is_lin1_151: tmp352 = atspre_eq_string_string (arg0, ATSstrcst("lin1")) ; return (tmp352) ; } /* end of [name_is_lin1_151] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18813(line=678, offs=4) -- 18896(line=679, offs=47) */ ATSstaticdec() ats_bool_type name_is_fun0_152 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp353) ; ATSlocal (ats_bool_type, tmp354) ; __ats_lab_name_is_fun0_152: tmp354 = atspre_eq_string_string (arg0, ATSstrcst("fun")) ; if (tmp354) { tmp353 = ats_true_bool ; } else { tmp353 = atspre_eq_string_string (arg0, ATSstrcst("fun0")) ; } /* end of [if] */ return (tmp353) ; } /* end of [name_is_fun0_152] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18900(line=680, offs=4) -- 18949(line=680, offs=53) */ ATSstaticdec() ats_bool_type name_is_fun1_153 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp355) ; __ats_lab_name_is_fun1_153: tmp355 = atspre_eq_string_string (arg0, ATSstrcst("fun1")) ; return (tmp355) ; } /* end of [name_is_fun1_153] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 18954(line=682, offs=4) -- 19046(line=683, offs=53) */ ATSstaticdec() ats_bool_type name_is_linfun0_154 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp356) ; ATSlocal (ats_bool_type, tmp357) ; __ats_lab_name_is_linfun0_154: tmp357 = atspre_eq_string_string (arg0, ATSstrcst("linfun")) ; if (tmp357) { tmp356 = ats_true_bool ; } else { tmp356 = atspre_eq_string_string (arg0, ATSstrcst("linfun0")) ; } /* end of [if] */ return (tmp356) ; } /* end of [name_is_linfun0_154] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19050(line=684, offs=4) -- 19105(line=684, offs=59) */ ATSstaticdec() ats_bool_type name_is_linfun1_155 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp358) ; __ats_lab_name_is_linfun1_155: tmp358 = atspre_eq_string_string (arg0, ATSstrcst("linfun1")) ; return (tmp358) ; } /* end of [name_is_linfun1_155] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19114(line=688, offs=4) -- 19196(line=689, offs=47) */ ATSstaticdec() ats_bool_type name_is_clo0_156 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp359) ; ATSlocal (ats_bool_type, tmp360) ; __ats_lab_name_is_clo0_156: tmp360 = atspre_eq_string_string (arg0, ATSstrcst("clo")) ; if (tmp360) { tmp359 = ats_true_bool ; } else { tmp359 = atspre_eq_string_string (arg0, ATSstrcst("clo0")) ; } /* end of [if] */ return (tmp359) ; } /* end of [name_is_clo0_156] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19200(line=690, offs=4) -- 19249(line=690, offs=53) */ ATSstaticdec() ats_bool_type name_is_clo1_157 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp361) ; __ats_lab_name_is_clo1_157: tmp361 = atspre_eq_string_string (arg0, ATSstrcst("clo1")) ; return (tmp361) ; } /* end of [name_is_clo1_157] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19254(line=692, offs=4) -- 19345(line=693, offs=53) */ ATSstaticdec() ats_bool_type name_is_linclo0_158 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp362) ; ATSlocal (ats_bool_type, tmp363) ; __ats_lab_name_is_linclo0_158: tmp363 = atspre_eq_string_string (arg0, ATSstrcst("linclo")) ; if (tmp363) { tmp362 = ats_true_bool ; } else { tmp362 = atspre_eq_string_string (arg0, ATSstrcst("linclo0")) ; } /* end of [if] */ return (tmp362) ; } /* end of [name_is_linclo0_158] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19349(line=694, offs=4) -- 19404(line=694, offs=59) */ ATSstaticdec() ats_bool_type name_is_linclo1_159 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp364) ; __ats_lab_name_is_linclo1_159: tmp364 = atspre_eq_string_string (arg0, ATSstrcst("linclo1")) ; return (tmp364) ; } /* end of [name_is_linclo1_159] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19413(line=698, offs=4) -- 19505(line=699, offs=53) */ ATSstaticdec() ats_bool_type name_is_cloptr0_160 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp365) ; ATSlocal (ats_bool_type, tmp366) ; __ats_lab_name_is_cloptr0_160: tmp366 = atspre_eq_string_string (arg0, ATSstrcst("cloptr")) ; if (tmp366) { tmp365 = ats_true_bool ; } else { tmp365 = atspre_eq_string_string (arg0, ATSstrcst("cloptr0")) ; } /* end of [if] */ return (tmp365) ; } /* end of [name_is_cloptr0_160] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19509(line=700, offs=4) -- 19564(line=700, offs=59) */ ATSstaticdec() ats_bool_type name_is_cloptr1_161 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp367) ; __ats_lab_name_is_cloptr1_161: tmp367 = atspre_eq_string_string (arg0, ATSstrcst("cloptr1")) ; return (tmp367) ; } /* end of [name_is_cloptr1_161] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19569(line=702, offs=4) -- 19670(line=703, offs=59) */ ATSstaticdec() ats_bool_type name_is_lincloptr0_162 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp368) ; ATSlocal (ats_bool_type, tmp369) ; __ats_lab_name_is_lincloptr0_162: tmp369 = atspre_eq_string_string (arg0, ATSstrcst("lincloptr")) ; if (tmp369) { tmp368 = ats_true_bool ; } else { tmp368 = atspre_eq_string_string (arg0, ATSstrcst("lincloptr0")) ; } /* end of [if] */ return (tmp368) ; } /* end of [name_is_lincloptr0_162] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19674(line=704, offs=4) -- 19735(line=704, offs=65) */ ATSstaticdec() ats_bool_type name_is_lincloptr1_163 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp370) ; __ats_lab_name_is_lincloptr1_163: tmp370 = atspre_eq_string_string (arg0, ATSstrcst("lincloptr1")) ; return (tmp370) ; } /* end of [name_is_lincloptr1_163] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19744(line=708, offs=4) -- 19836(line=709, offs=53) */ ATSstaticdec() ats_bool_type name_is_cloref0_164 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp371) ; ATSlocal (ats_bool_type, tmp372) ; __ats_lab_name_is_cloref0_164: tmp372 = atspre_eq_string_string (arg0, ATSstrcst("cloref")) ; if (tmp372) { tmp371 = ats_true_bool ; } else { tmp371 = atspre_eq_string_string (arg0, ATSstrcst("cloref0")) ; } /* end of [if] */ return (tmp371) ; } /* end of [name_is_cloref0_164] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19840(line=710, offs=4) -- 19895(line=710, offs=59) */ ATSstaticdec() ats_bool_type name_is_cloref1_165 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp373) ; __ats_lab_name_is_cloref1_165: tmp373 = atspre_eq_string_string (arg0, ATSstrcst("cloref1")) ; return (tmp373) ; } /* end of [name_is_cloref1_165] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 19998(line=720, offs=23) -- 21270(line=752, offs=6) */ ATSglobaldec() ats_ptr_type e0fftag_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_bool_type, tmp378) ; ATSlocal (ats_bool_type, tmp379) ; ATSlocal (ats_bool_type, tmp380) ; ATSlocal (ats_bool_type, tmp381) ; ATSlocal (ats_bool_type, tmp382) ; ATSlocal (ats_bool_type, tmp383) ; ATSlocal (ats_bool_type, tmp384) ; ATSlocal (ats_bool_type, tmp385) ; ATSlocal (ats_bool_type, tmp386) ; ATSlocal (ats_bool_type, tmp387) ; ATSlocal (ats_bool_type, tmp388) ; ATSlocal (ats_bool_type, tmp389) ; ATSlocal (ats_bool_type, tmp390) ; ATSlocal (ats_bool_type, tmp391) ; ATSlocal (ats_bool_type, tmp392) ; ATSlocal (ats_bool_type, tmp393) ; ATSlocal (ats_bool_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; __ats_lab_e0fftag_var: tmp376 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp376) ; do { /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: tmp378 = name_is_prf_149 (tmp375) ; if (!tmp378) { goto __ats_lab_73_1 ; } tmp377 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGprf_2) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: __ats_lab_73_1: tmp379 = name_is_clo0_156 (tmp375) ; if (!tmp379) { goto __ats_lab_74_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 0) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: __ats_lab_74_1: tmp380 = name_is_clo1_157 (tmp375) ; if (!tmp380) { goto __ats_lab_75_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 1) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: tmp381 = name_is_linclo0_158 (tmp375) ; if (!tmp381) { goto __ats_lab_76_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 0) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: __ats_lab_76_1: tmp382 = name_is_linclo1_159 (tmp375) ; if (!tmp382) { goto __ats_lab_77_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 1) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: __ats_lab_77_1: tmp383 = name_is_cloptr0_160 (tmp375) ; if (!tmp383) { goto __ats_lab_78_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 0) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: __ats_lab_78_1: tmp384 = name_is_cloptr1_161 (tmp375) ; if (!tmp384) { goto __ats_lab_79_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 1) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp385 = name_is_lincloptr0_162 (tmp375) ; if (!tmp385) { goto __ats_lab_80_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 0) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: __ats_lab_80_1: tmp386 = name_is_lincloptr1_163 (tmp375) ; if (!tmp386) { goto __ats_lab_81_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, 1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 1) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp387 = name_is_cloref0_164 (tmp375) ; if (!tmp387) { goto __ats_lab_82_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 0) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp388 = name_is_cloref1_165 (tmp375) ; if (!tmp388) { goto __ats_lab_83_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_25)) ; ((ats_sum_ptr_type)tmp377)->tag = 5 ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_1, -1) ; ats_selptrset_mac(anairiats_sum_25, tmp377, atslab_2, 1) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp389 = name_is_fun0_152 (tmp375) ; if (!tmp389) { goto __ats_lab_84_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ((ats_sum_ptr_type)tmp377)->tag = 4 ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_1, 0) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp390 = name_is_fun1_153 (tmp375) ; if (!tmp390) { goto __ats_lab_85_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ((ats_sum_ptr_type)tmp377)->tag = 4 ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_1, 1) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp391 = name_is_linfun0_154 (tmp375) ; if (!tmp391) { goto __ats_lab_86_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ((ats_sum_ptr_type)tmp377)->tag = 4 ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_1, 0) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp392 = name_is_linfun1_155 (tmp375) ; if (!tmp392) { goto __ats_lab_87_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ((ats_sum_ptr_type)tmp377)->tag = 4 ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_26, tmp377, atslab_1, 1) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: __ats_lab_87_1: tmp393 = name_is_lin0_150 (tmp375) ; if (!tmp393) { goto __ats_lab_88_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp377)->tag = 3 ; ats_selptrset_mac(anairiats_sum_11, tmp377, atslab_0, 0) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: __ats_lab_88_1: tmp394 = name_is_lin1_151 (tmp375) ; if (!tmp394) { goto __ats_lab_89_1 ; } tmp377 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp377)->tag = 3 ; ats_selptrset_mac(anairiats_sum_11, tmp377, atslab_0, 1) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: tmp377 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp377)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp377, atslab_0, arg0) ; break ; } while (0) ; tmp395 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp374 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp374, atslab_e0fftag_loc, tmp395) ; ats_selptrset_mac(anairiats_rec_23, tmp374, atslab_e0fftag_node, tmp377) ; return (tmp374) ; } /* end of [e0fftag_var] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21345(line=756, offs=27) -- 21420(line=758, offs=2) */ ATSglobaldec() ats_ptr_type e0fftag_var_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; __ats_lab_e0fftag_var_fun: tmp397 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_26)) ; ((ats_sum_ptr_type)tmp398)->tag = 4 ; ats_selptrset_mac(anairiats_sum_26, tmp398, atslab_0, -1) ; ats_selptrset_mac(anairiats_sum_26, tmp398, atslab_1, 0) ; tmp396 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp396, atslab_e0fftag_loc, tmp397) ; ats_selptrset_mac(anairiats_rec_23, tmp396, atslab_e0fftag_node, tmp398) ; return (tmp396) ; } /* end of [e0fftag_var_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21472(line=760, offs=23) -- 21550(line=762, offs=2) */ ATSglobaldec() ats_ptr_type e0fftag_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; __ats_lab_e0fftag_int: tmp400 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp402 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp401 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp401)->tag = 0 ; ats_selptrset_mac(anairiats_sum_24, tmp401, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_24, tmp401, atslab_1, tmp402) ; tmp399 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp399, atslab_e0fftag_loc, tmp400) ; ats_selptrset_mac(anairiats_rec_23, tmp399, atslab_e0fftag_node, tmp401) ; return (tmp399) ; } /* end of [e0fftag_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21577(line=764, offs=26) -- 21588(line=764, offs=37) */ ATSglobaldec() ats_ptr_type e0fftaglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp403) ; __ats_lab_e0fftaglst_nil: tmp403 = (ats_sum_ptr_type)0 ; return (tmp403) ; } /* end of [e0fftaglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21615(line=765, offs=27) -- 21637(line=765, offs=49) */ ATSglobaldec() ats_ptr_type e0fftaglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp404) ; __ats_lab_e0fftaglst_cons: tmp404 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp404, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp404, atslab_1, arg1) ; return (tmp404) ; } /* end of [e0fftaglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21668(line=767, offs=30) -- 21680(line=767, offs=42) */ ATSglobaldec() ats_ptr_type e0fftaglstopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; __ats_lab_e0fftaglstopt_none: tmp405 = (ats_sum_ptr_type)0 ; return (tmp405) ; } /* end of [e0fftaglstopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21710(line=768, offs=30) -- 21723(line=768, offs=43) */ ATSglobaldec() ats_ptr_type e0fftaglstopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp406) ; __ats_lab_e0fftaglstopt_some: tmp406 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp406, atslab_0, arg0) ; return (tmp406) ; } /* end of [e0fftaglstopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21796(line=775, offs=3) -- 21847(line=775, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__s0taq_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp407) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__s0taq_make: tmp407 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp407, atslab_s0taq_loc, arg0) ; ats_selptrset_mac(anairiats_rec_27, tmp407, atslab_s0taq_node, arg1) ; return (tmp407) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__s0taq_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 21890(line=779, offs=14) -- 22408(line=793, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; // ATSlocal_void (tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; // ATSlocal_void (tmp418) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq: tmp409 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg1), atslab_s0taq_node) ; do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp409)->tag != 0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp409)->tag != 1) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp410 = ats_caselptrlab_mac(anairiats_sum_0, tmp409, atslab_0) ; /* tmp411 = */ atspre_fprint_char (arg0, '$') ; /* tmp412 = */ atspre_fprint_char (arg0, '"') ; /* tmp413 = */ atspre_fprint_string (arg0, tmp410) ; /* tmp414 = */ atspre_fprint_char (arg0, '"') ; /* tmp408 = */ atspre_fprint_char (arg0, '.') ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp409)->tag != 2) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_0, tmp409, atslab_0) ; /* tmp416 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp415) ; /* tmp408 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (((ats_sum_ptr_type)tmp409)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp417 = ats_caselptrlab_mac(anairiats_sum_0, tmp409, atslab_0) ; /* tmp418 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp417) ; /* tmp408 = */ atspre_fprint_char (arg0, '.') ; break ; } while (0) ; return /* (tmp408) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 22481(line=796, offs=23) -- 22514(line=796, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0taq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; // ATSlocal_void (tmp422) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0taq: tmp420 = atspre_stdout_get () ; tmp421 = ats_selsin_mac(tmp420, atslab_1) ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq (tmp421, arg0) ; /* tmp419 = */ atspre_stdout_view_set () ; return /* (tmp419) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_s0taq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 22537(line=797, offs=23) -- 22570(line=797, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; // ATSlocal_void (tmp426) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq: tmp424 = atspre_stderr_get () ; tmp425 = ats_selsin_mac(tmp424, atslab_1) ; /* tmp426 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq (tmp425, arg0) ; /* tmp423 = */ atspre_stderr_view_set () ; return /* (tmp423) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_s0taq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 22614(line=801, offs=22) -- 22682(line=803, offs=2) */ ATSglobaldec() ats_ptr_type s0taq_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; __ats_lab_s0taq_none: tmp428 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0TAQnone_0) ; tmp427 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp427, atslab_s0taq_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_27, tmp427, atslab_s0taq_node, tmp428) ; return (tmp427) ; } /* end of [s0taq_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 22730(line=805, offs=24) -- 22820(line=807, offs=2) */ ATSglobaldec() ats_ptr_type s0taq_fildot (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; __ats_lab_s0taq_fildot: tmp430 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp432 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp431 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp431)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp431, atslab_0, tmp432) ; tmp429 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp429, atslab_s0taq_loc, tmp430) ; ats_selptrset_mac(anairiats_rec_27, tmp429, atslab_s0taq_node, tmp431) ; return (tmp429) ; } /* end of [s0taq_fildot] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 22872(line=809, offs=26) -- 22949(line=811, offs=2) */ ATSglobaldec() ats_ptr_type s0taq_symcolon (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; __ats_lab_s0taq_symcolon: tmp434 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp436 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp435 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp435)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp435, atslab_0, tmp436) ; tmp433 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp433, atslab_s0taq_loc, tmp434) ; ats_selptrset_mac(anairiats_rec_27, tmp433, atslab_s0taq_node, tmp435) ; return (tmp433) ; } /* end of [s0taq_symcolon] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 23001(line=813, offs=24) -- 23076(line=815, offs=2) */ ATSglobaldec() ats_ptr_type s0taq_symdot (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; __ats_lab_s0taq_symdot: tmp438 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp440 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp439 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp439)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp439, atslab_0, tmp440) ; tmp437 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp437, atslab_s0taq_loc, tmp438) ; ats_selptrset_mac(anairiats_rec_27, tmp437, atslab_s0taq_node, tmp439) ; return (tmp437) ; } /* end of [s0taq_symdot] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 23175(line=822, offs=3) -- 24173(line=851, offs=23) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; // ATSlocal_void (tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; // ATSlocal_void (tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; // ATSlocal_void (tmp450) ; // ATSlocal_void (tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; // ATSlocal_void (tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; // ATSlocal_void (tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; // ATSlocal_void (tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; // ATSlocal_void (tmp461) ; // ATSlocal_void (tmp462) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq: tmp442 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg1), atslab_d0ynq_node) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)tmp442)->tag != 1) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp443 = ats_caselptrlab_mac(anairiats_sum_0, tmp442, atslab_0) ; /* tmp444 = */ atspre_fprint_char (arg0, '$') ; /* tmp445 = */ atspre_fprint_char (arg0, '"') ; /* tmp446 = */ atspre_fprint_string (arg0, tmp443) ; /* tmp447 = */ atspre_fprint_char (arg0, '"') ; /* tmp441 = */ atspre_fprint_char (arg0, '.') ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: if (((ats_sum_ptr_type)tmp442)->tag != 2) { goto __ats_lab_96_0 ; } __ats_lab_95_1: tmp448 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_0) ; tmp449 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_1) ; /* tmp450 = */ atspre_fprint_char (arg0, '$') ; /* tmp451 = */ atspre_fprint_char (arg0, '"') ; /* tmp452 = */ atspre_fprint_string (arg0, tmp448) ; /* tmp453 = */ atspre_fprint_char (arg0, '"') ; /* tmp454 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp449) ; /* tmp441 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp442)->tag != 3) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp455 = ats_caselptrlab_mac(anairiats_sum_0, tmp442, atslab_0) ; /* tmp456 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp455) ; /* tmp441 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: if (((ats_sum_ptr_type)tmp442)->tag != 4) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp457 = ats_caselptrlab_mac(anairiats_sum_0, tmp442, atslab_0) ; /* tmp458 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp457) ; /* tmp441 = */ atspre_fprint_char (arg0, '.') ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp442)->tag != 5) { goto __ats_lab_99_0 ; } __ats_lab_98_1: tmp459 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_0) ; tmp460 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_1) ; /* tmp461 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp459) ; /* tmp462 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp460) ; /* tmp441 = */ atspre_fprint_char (arg0, ':') ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: // if (((ats_sum_ptr_type)tmp442)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_99_1: break ; } while (0) ; return /* (tmp441) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24222(line=854, offs=23) -- 24255(line=854, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_d0ynq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; // ATSlocal_void (tmp466) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_d0ynq: tmp464 = atspre_stdout_get () ; tmp465 = ats_selsin_mac(tmp464, atslab_1) ; /* tmp466 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (tmp465, arg0) ; /* tmp463 = */ atspre_stdout_view_set () ; return /* (tmp463) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__print_d0ynq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24278(line=855, offs=23) -- 24311(line=855, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; // ATSlocal_void (tmp470) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq: tmp468 = atspre_stderr_get () ; tmp469 = ats_selsin_mac(tmp468, atslab_1) ; /* tmp470 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (tmp469, arg0) ; /* tmp467 = */ atspre_stderr_view_set () ; return /* (tmp467) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__prerr_d0ynq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24355(line=859, offs=22) -- 24423(line=861, offs=2) */ ATSglobaldec() ats_ptr_type d0ynq_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; __ats_lab_d0ynq_none: tmp472 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0YNQnone_0) ; tmp471 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp471, atslab_d0ynq_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_28, tmp471, atslab_d0ynq_node, tmp472) ; return (tmp471) ; } /* end of [d0ynq_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24448(line=863, offs=24) -- 24538(line=865, offs=2) */ ATSglobaldec() ats_ptr_type d0ynq_fildot (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; __ats_lab_d0ynq_fildot: tmp474 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp476 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp475 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp475)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp475, atslab_0, tmp476) ; tmp473 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp473, atslab_d0ynq_loc, tmp474) ; ats_selptrset_mac(anairiats_rec_28, tmp473, atslab_d0ynq_node, tmp475) ; return (tmp473) ; } /* end of [d0ynq_fildot] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24572(line=867, offs=33) -- 24739(line=874, offs=6) */ ATSglobaldec() ats_ptr_type d0ynq_fildot_symcolon (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp477) ; ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; __ats_lab_d0ynq_fildot_symcolon: tmp479 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp480 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp478 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp479, tmp480) ; tmp482 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp483 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp481 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp481)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp481, atslab_0, tmp482) ; ats_selptrset_mac(anairiats_sum_15, tmp481, atslab_1, tmp483) ; tmp477 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp477, atslab_d0ynq_loc, tmp478) ; ats_selptrset_mac(anairiats_rec_28, tmp477, atslab_d0ynq_node, tmp481) ; return (tmp477) ; } /* end of [d0ynq_fildot_symcolon] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24800(line=876, offs=26) -- 24877(line=877, offs=71) */ ATSglobaldec() ats_ptr_type d0ynq_symcolon (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; __ats_lab_d0ynq_symcolon: tmp485 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp487 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp486 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp486)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp486, atslab_0, tmp487) ; tmp484 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp484, atslab_d0ynq_loc, tmp485) ; ats_selptrset_mac(anairiats_rec_28, tmp484, atslab_d0ynq_node, tmp486) ; return (tmp484) ; } /* end of [d0ynq_symcolon] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 24902(line=879, offs=24) -- 24977(line=880, offs=69) */ ATSglobaldec() ats_ptr_type d0ynq_symdot (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; __ats_lab_d0ynq_symdot: tmp489 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp491 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp490 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp490)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp490, atslab_0, tmp491) ; tmp488 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp488, atslab_d0ynq_loc, tmp489) ; ats_selptrset_mac(anairiats_rec_28, tmp488, atslab_d0ynq_node, tmp490) ; return (tmp488) ; } /* end of [d0ynq_symdot] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25011(line=882, offs=33) -- 25193(line=889, offs=6) */ ATSglobaldec() ats_ptr_type d0ynq_symdot_symcolon (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; __ats_lab_d0ynq_symdot_symcolon: tmp494 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp495 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp493 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp494, tmp495) ; tmp497 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp498 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp496 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp496)->tag = 5 ; ats_selptrset_mac(anairiats_sum_15, tmp496, atslab_0, tmp497) ; ats_selptrset_mac(anairiats_sum_15, tmp496, atslab_1, tmp498) ; tmp492 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp492, atslab_d0ynq_loc, tmp493) ; ats_selptrset_mac(anairiats_rec_28, tmp492, atslab_d0ynq_node, tmp496) ; return (tmp492) ; } /* end of [d0ynq_symdot_symcolon] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25313(line=895, offs=28) -- 25443(line=899, offs=6) */ ATSglobaldec() ats_ptr_type sqi0de_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; __ats_lab_sqi0de_make_some: tmp501 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_s0taq_loc) ; tmp502 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp500 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp501, tmp502) ; tmp503 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp499 = ATS_MALLOC(sizeof(anairiats_rec_29)) ; ats_selptrset_mac(anairiats_rec_29, tmp499, atslab_sqi0de_loc, tmp500) ; ats_selptrset_mac(anairiats_rec_29, tmp499, atslab_sqi0de_qua, arg0) ; ats_selptrset_mac(anairiats_rec_29, tmp499, atslab_sqi0de_sym, tmp503) ; return (tmp499) ; } /* end of [sqi0de_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25501(line=901, offs=28) -- 25567(line=902, offs=60) */ ATSglobaldec() ats_ptr_type sqi0de_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; __ats_lab_sqi0de_make_none: tmp505 = s0taq_none () ; tmp504 = sqi0de_make_some (tmp505, arg0) ; return (tmp504) ; } /* end of [sqi0de_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25633(line=906, offs=28) -- 25763(line=909, offs=6) */ ATSglobaldec() ats_ptr_type dqi0de_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; __ats_lab_dqi0de_make_some: tmp508 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_d0ynq_loc) ; tmp509 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp507 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp508, tmp509) ; tmp510 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp506 = ATS_MALLOC(sizeof(anairiats_rec_30)) ; ats_selptrset_mac(anairiats_rec_30, tmp506, atslab_dqi0de_loc, tmp507) ; ats_selptrset_mac(anairiats_rec_30, tmp506, atslab_dqi0de_qua, arg0) ; ats_selptrset_mac(anairiats_rec_30, tmp506, atslab_dqi0de_sym, tmp510) ; return (tmp506) ; } /* end of [dqi0de_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25821(line=911, offs=28) -- 25897(line=913, offs=4) */ ATSglobaldec() ats_ptr_type dqi0de_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; __ats_lab_dqi0de_make_none: tmp512 = d0ynq_none () ; tmp511 = dqi0de_make_some (tmp512, arg0) ; return (tmp511) ; } /* end of [dqi0de_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 25980(line=919, offs=3) -- 26067(line=922, offs=2) */ ATSglobaldec() ats_ptr_type arrqi0de_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; __ats_lab_arrqi0de_make_some: tmp514 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp515 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp513 = ATS_MALLOC(sizeof(anairiats_rec_31)) ; ats_selptrset_mac(anairiats_rec_31, tmp513, atslab_arrqi0de_loc, tmp514) ; ats_selptrset_mac(anairiats_rec_31, tmp513, atslab_arrqi0de_qua, arg0) ; ats_selptrset_mac(anairiats_rec_31, tmp513, atslab_arrqi0de_sym, tmp515) ; return (tmp513) ; } /* end of [arrqi0de_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26129(line=925, offs=20) -- 26197(line=926, offs=62) */ ATSglobaldec() ats_ptr_type arrqi0de_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; __ats_lab_arrqi0de_make_none: tmp517 = d0ynq_none () ; tmp516 = arrqi0de_make_some (tmp517, arg0) ; return (tmp516) ; } /* end of [arrqi0de_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26280(line=931, offs=30) -- 26416(line=934, offs=6) */ ATSglobaldec() ats_ptr_type tmpqi0de_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; ATSlocal (ats_ptr_type, tmp522) ; __ats_lab_tmpqi0de_make_some: tmp520 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_d0ynq_loc) ; tmp521 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp519 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp520, tmp521) ; tmp522 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp518 = ATS_MALLOC(sizeof(anairiats_rec_32)) ; ats_selptrset_mac(anairiats_rec_32, tmp518, atslab_tmpqi0de_loc, tmp519) ; ats_selptrset_mac(anairiats_rec_32, tmp518, atslab_tmpqi0de_qua, arg0) ; ats_selptrset_mac(anairiats_rec_32, tmp518, atslab_tmpqi0de_sym, tmp522) ; return (tmp518) ; } /* end of [tmpqi0de_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26478(line=936, offs=30) -- 26546(line=937, offs=62) */ ATSglobaldec() ats_ptr_type tmpqi0de_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; __ats_lab_tmpqi0de_make_none: tmp524 = d0ynq_none () ; tmp523 = tmpqi0de_make_some (tmp524, arg0) ; return (tmp523) ; } /* end of [tmpqi0de_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26622(line=942, offs=23) -- 26698(line=943, offs=68) */ ATSglobaldec() ats_ptr_type d0atarg_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; __ats_lab_d0atarg_srt: tmp526 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg0), atslab_s0rtpol_loc) ; tmp527 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp527)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp527, atslab_0, arg0) ; tmp525 = ATS_MALLOC(sizeof(anairiats_rec_33)) ; ats_selptrset_mac(anairiats_rec_33, tmp525, atslab_d0atarg_loc, tmp526) ; ats_selptrset_mac(anairiats_rec_33, tmp525, atslab_d0atarg_node, tmp527) ; return (tmp525) ; } /* end of [d0atarg_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26725(line=945, offs=26) -- 26876(line=948, offs=6) */ ATSglobaldec() ats_ptr_type d0atarg_id_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; __ats_lab_d0atarg_id_srt: tmp530 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp531 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_19, arg1), atslab_s0rtpol_loc) ; tmp529 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp530, tmp531) ; tmp533 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp532)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp532, atslab_0, tmp533) ; ats_selptrset_mac(anairiats_sum_15, tmp532, atslab_1, arg1) ; tmp528 = ATS_MALLOC(sizeof(anairiats_rec_33)) ; ats_selptrset_mac(anairiats_rec_33, tmp528, atslab_d0atarg_loc, tmp529) ; ats_selptrset_mac(anairiats_rec_33, tmp528, atslab_d0atarg_node, tmp532) ; return (tmp528) ; } /* end of [d0atarg_id_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26903(line=950, offs=26) -- 26914(line=950, offs=37) */ ATSglobaldec() ats_ptr_type d0atarglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp534) ; __ats_lab_d0atarglst_nil: tmp534 = (ats_sum_ptr_type)0 ; return (tmp534) ; } /* end of [d0atarglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26941(line=951, offs=27) -- 26963(line=951, offs=49) */ ATSglobaldec() ats_ptr_type d0atarglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp535) ; __ats_lab_d0atarglst_cons: tmp535 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp535, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp535, atslab_1, arg1) ; return (tmp535) ; } /* end of [d0atarglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 26994(line=953, offs=30) -- 27006(line=953, offs=42) */ ATSglobaldec() ats_ptr_type d0atarglstopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp536) ; __ats_lab_d0atarglstopt_none: tmp536 = (ats_sum_ptr_type)0 ; return (tmp536) ; } /* end of [d0atarglstopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27036(line=954, offs=30) -- 27049(line=954, offs=43) */ ATSglobaldec() ats_ptr_type d0atarglstopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp537) ; __ats_lab_d0atarglstopt_some: tmp537 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp537, atslab_0, arg0) ; return (tmp537) ; } /* end of [d0atarglstopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27094(line=958, offs=22) -- 27302(line=965, offs=6) */ ATSglobaldec() ats_ptr_type s0arg_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; __ats_lab_s0arg_make: do { /* branch: __ats_lab_100 */ __ats_lab_100_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp540 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_0) ; tmp541 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp542 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp540), atslab_s0rt_loc) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp541, tmp542) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_101_1: tmp539 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; break ; } while (0) ; tmp543 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp538 = ATS_MALLOC(sizeof(anairiats_rec_34)) ; ats_selptrset_mac(anairiats_rec_34, tmp538, atslab_s0arg_loc, tmp539) ; ats_selptrset_mac(anairiats_rec_34, tmp538, atslab_s0arg_sym, tmp543) ; ats_selptrset_mac(anairiats_rec_34, tmp538, atslab_s0arg_srt, arg1) ; return (tmp538) ; } /* end of [s0arg_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27353(line=967, offs=27) -- 27433(line=969, offs=2) */ ATSglobaldec() ats_ptr_type s0arg_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; __ats_lab_s0arg_make_none: tmp545 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp546 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp547 = (ats_sum_ptr_type)0 ; tmp544 = ATS_MALLOC(sizeof(anairiats_rec_34)) ; ats_selptrset_mac(anairiats_rec_34, tmp544, atslab_s0arg_loc, tmp545) ; ats_selptrset_mac(anairiats_rec_34, tmp544, atslab_s0arg_sym, tmp546) ; ats_selptrset_mac(anairiats_rec_34, tmp544, atslab_s0arg_srt, tmp547) ; return (tmp544) ; } /* end of [s0arg_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27458(line=971, offs=24) -- 27469(line=971, offs=35) */ ATSglobaldec() ats_ptr_type s0arglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp548) ; __ats_lab_s0arglst_nil: tmp548 = (ats_sum_ptr_type)0 ; return (tmp548) ; } /* end of [s0arglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27494(line=972, offs=25) -- 27516(line=972, offs=47) */ ATSglobaldec() ats_ptr_type s0arglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp549) ; __ats_lab_s0arglst_cons: tmp549 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp549, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp549, atslab_1, arg1) ; return (tmp549) ; } /* end of [s0arglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27544(line=974, offs=27) -- 27555(line=974, offs=38) */ ATSglobaldec() ats_ptr_type s0arglstlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp550) ; __ats_lab_s0arglstlst_nil: tmp550 = (ats_sum_ptr_type)0 ; return (tmp550) ; } /* end of [s0arglstlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27583(line=975, offs=28) -- 27609(line=975, offs=54) */ ATSglobaldec() ats_ptr_type s0arglstlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp551) ; __ats_lab_s0arglstlst_cons: tmp551 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp551, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp551, atslab_1, arg1) ; return (tmp551) ; } /* end of [s0arglstlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27641(line=976, offs=32) -- 27720(line=977, offs=68) */ ATSglobaldec() ats_ptr_type s0arglstlst_cons_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; __ats_lab_s0arglstlst_cons_ide: tmp553 = s0arg_make_none (arg0) ; tmp555 = (ats_sum_ptr_type)0 ; tmp554 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp554, atslab_0, tmp553) ; ats_selptrset_mac(anairiats_sum_1, tmp554, atslab_1, tmp555) ; tmp552 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp552, atslab_0, tmp554) ; ats_selptrset_mac(anairiats_sum_1, tmp552, atslab_1, arg1) ; return (tmp552) ; } /* end of [s0arglstlst_cons_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27786(line=984, offs=11) -- 27921(line=988, offs=6) */ ATSglobaldec() ats_ptr_type sp0at_con (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; __ats_lab_sp0at_con: tmp558 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_sqi0de_loc) ; tmp559 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp557 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp558, tmp559) ; tmp560 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp560, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp560, atslab_1, arg1) ; tmp556 = ATS_MALLOC(sizeof(anairiats_rec_35)) ; ats_selptrset_mac(anairiats_rec_35, tmp556, atslab_sp0at_loc, tmp557) ; ats_selptrset_mac(anairiats_rec_35, tmp556, atslab_sp0at_node, tmp560) ; return (tmp556) ; } /* end of [sp0at_con] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 28121(line=996, offs=7) -- 28301(line=1000, offs=51) */ ATSstaticdec() ats_ptr_type aux_213 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; __ats_lab_aux_213: do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp563 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp564 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp563 ; arg2 = tmp564 ; goto __ats_lab_aux_213 ; // tail call break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_103_1: tmp565 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp562 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (arg0, tmp565) ; break ; } while (0) ; return (tmp562) ; } /* end of [aux_213] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 27998(line=993, offs=4) -- 28502(line=1008, offs=4) */ ATSstaticdec() ats_ptr_type gtlt_t1mps0expseqseq_cons_loc_212 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; __ats_lab_gtlt_t1mps0expseqseq_cons_loc_212: do { /* branch: __ats_lab_104 */ __ats_lab_104_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp567 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp568 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp566 = aux_213 (arg0, tmp567, tmp568) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: tmp566 = arg0 ; break ; } while (0) ; tmp561 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp561, atslab_0, tmp566) ; ats_selptrset_mac(anairiats_sum_37, tmp561, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_37, tmp561, atslab_2, arg2) ; return (tmp561) ; } /* end of [gtlt_t1mps0expseqseq_cons_loc_212] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 28581(line=1010, offs=36) -- 28607(line=1010, offs=62) */ ATSglobaldec() ats_ptr_type gtlt_t1mps0expseqseq_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp569) ; __ats_lab_gtlt_t1mps0expseqseq_nil: tmp569 = (ats_sum_ptr_type)0 ; return (tmp569) ; } /* end of [gtlt_t1mps0expseqseq_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 28649(line=1012, offs=41) -- 28727(line=1013, offs=59) */ ATSglobaldec() ats_ptr_type gtlt_t1mps0expseqseq_cons_tok (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; __ats_lab_gtlt_t1mps0expseqseq_cons_tok: tmp571 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp570 = gtlt_t1mps0expseqseq_cons_loc_212 (tmp571, arg1, arg2) ; return (tmp570) ; } /* end of [gtlt_t1mps0expseqseq_cons_tok] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 28837(line=1020, offs=21) -- 28963(line=1024, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_ann (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; __ats_lab_s0exp_ann: tmp574 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg0), atslab_s0exp_loc) ; tmp575 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_loc) ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp574, tmp575) ; tmp576 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp576)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp576, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp576, atslab_1, arg1) ; tmp572 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp572, atslab_s0exp_loc, tmp573) ; ats_selptrset_mac(anairiats_rec_36, tmp572, atslab_s0exp_node, tmp576) ; return (tmp572) ; } /* end of [s0exp_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29007(line=1026, offs=21) -- 29158(line=1030, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_app (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp577) ; ATSlocal (ats_ptr_type, tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; __ats_lab_s0exp_app: tmp579 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg0), atslab_s0exp_loc) ; tmp580 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp578 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp579, tmp580) ; tmp581 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp581)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp581, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp581, atslab_1, arg1) ; tmp577 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp577, atslab_s0exp_loc, tmp578) ; ats_selptrset_mac(anairiats_rec_36, tmp577, atslab_s0exp_node, tmp581) ; return (tmp577) ; } /* end of [s0exp_app] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29203(line=1032, offs=22) -- 29273(line=1034, offs=2) */ ATSglobaldec() ats_ptr_type s0exp_char (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_char_type, tmp585) ; __ats_lab_s0exp_char: tmp583 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_loc) ; tmp585 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_val) ; tmp584 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp584)->tag = 2 ; ats_selptrset_mac(anairiats_sum_16, tmp584, atslab_0, tmp585) ; tmp582 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp582, atslab_s0exp_loc, tmp583) ; ats_selptrset_mac(anairiats_rec_36, tmp582, atslab_s0exp_node, tmp584) ; return (tmp582) ; } /* end of [s0exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29318(line=1037, offs=11) -- 29477(line=1041, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_exi (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; __ats_lab_s0exp_exi: tmp588 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp589 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp587 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp588, tmp589) ; tmp590 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp590)->tag = 3 ; ats_selptrset_mac(anairiats_sum_24, tmp590, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_24, tmp590, atslab_1, arg2) ; tmp586 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp586, atslab_s0exp_loc, tmp587) ; ats_selptrset_mac(anairiats_rec_36, tmp586, atslab_s0exp_node, tmp590) ; return (tmp586) ; } /* end of [s0exp_exi] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29584(line=1047, offs=14) -- 29616(line=1047, offs=46) */ ATSglobaldec() ats_ptr_type s0expext_nam (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; __ats_lab_s0expext_nam: tmp592 = (ats_sum_ptr_type)0 ; tmp591 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp591, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_37, tmp591, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_37, tmp591, atslab_2, tmp592) ; return (tmp591) ; } /* end of [s0expext_nam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29640(line=1049, offs=14) -- 29736(line=1051, offs=4) */ ATSglobaldec() ats_ptr_type s0expext_app (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; __ats_lab_s0expext_app: // tmp594 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_0) ; tmp595 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_1) ; tmp596 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_2) ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp597, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp597, atslab_1, tmp596) ; tmp593 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp593, atslab_0, tmp594) ; ats_selptrset_mac(anairiats_sum_37, tmp593, atslab_1, tmp595) ; ats_selptrset_mac(anairiats_sum_37, tmp593, atslab_2, tmp597) ; return (tmp593) ; } /* end of [s0expext_app] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29910(line=1057, offs=9) -- 30049(line=1060, offs=22) */ ATSstaticdec() ats_ptr_type loop_223 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; __ats_lab_loop_223: do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_107_0 ; } __ats_lab_106_1: tmp604 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp605 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp606 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp604), atslab_s0exp_loc) ; arg0 = tmp606 ; arg1 = tmp605 ; goto __ats_lab_loop_223 ; // tail call break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_107_1: tmp603 = arg0 ; break ; } while (0) ; return (tmp603) ; } /* end of [loop_223] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 29785(line=1053, offs=14) -- 30205(line=1066, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_extern (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (ats_ptr_type, tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; __ats_lab_s0exp_extern: // tmp599 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_0) ; tmp600 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_1) ; tmp601 = ats_caselptrlab_mac(anairiats_sum_37, arg0, atslab_2) ; tmp602 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp600), atslab_s0tring_loc) ; tmp607 = loop_223 (tmp602, tmp601) ; tmp609 = ats_selsin_mac(tmp599, atslab_t0kn_loc) ; tmp608 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp609, tmp607) ; tmp611 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp600), atslab_s0tring_val) ; tmp610 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp610)->tag = 4 ; ats_selptrset_mac(anairiats_sum_15, tmp610, atslab_0, tmp611) ; ats_selptrset_mac(anairiats_sum_15, tmp610, atslab_1, tmp601) ; tmp598 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp598, atslab_s0exp_loc, tmp608) ; ats_selptrset_mac(anairiats_rec_36, tmp598, atslab_s0exp_node, tmp610) ; return (tmp598) ; } /* end of [s0exp_extern] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 30252(line=1068, offs=21) -- 30321(line=1070, offs=2) */ ATSglobaldec() ats_ptr_type s0exp_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; __ats_lab_s0exp_ide: tmp613 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp615 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp614 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp614)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp614, atslab_0, tmp615) ; tmp612 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp612, atslab_s0exp_loc, tmp613) ; ats_selptrset_mac(anairiats_rec_36, tmp612, atslab_s0exp_node, tmp614) ; return (tmp612) ; } /* end of [s0exp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 30365(line=1072, offs=21) -- 30430(line=1074, offs=2) */ ATSglobaldec() ats_ptr_type s0exp_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; __ats_lab_s0exp_int: tmp617 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp619 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp618 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp618)->tag = 7 ; ats_selptrset_mac(anairiats_sum_0, tmp618, atslab_0, tmp619) ; tmp616 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp616, atslab_s0exp_loc, tmp617) ; ats_selptrset_mac(anairiats_rec_36, tmp616, atslab_s0exp_node, tmp618) ; return (tmp616) ; } /* end of [s0exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 30480(line=1077, offs=17) -- 30712(line=1085, offs=4) */ ATSglobaldec() ats_ptr_type s0exp_intsp_err (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp620) ; // ATSlocal_void (tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; // ATSlocal_void (tmp623) ; // ATSlocal_void (tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; // ATSlocal_void (tmp627) ; __ats_lab_s0exp_intsp_err: tmp622 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; /* tmp621 = */ prerr_loc_error0_0 (tmp622) ; /* tmp623 = */ atspre_prerr_string (ATSstrcst(": the specified integer [")) ; tmp625 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; /* tmp624 = */ atspre_prerr_string (tmp625) ; /* tmp626 = */ atspre_prerr_string (ATSstrcst("] is not allowed in statics.")) ; /* tmp627 = */ atspre_prerr_newline () ; /* tmp620 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp620) ; } /* end of [s0exp_intsp_err] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 30762(line=1088, offs=11) -- 30893(line=1092, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_imp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; __ats_lab_s0exp_imp: tmp630 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp631 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp629 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp630, tmp631) ; tmp632 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp632)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp632, atslab_0, arg1) ; tmp628 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp628, atslab_s0exp_loc, tmp629) ; ats_selptrset_mac(anairiats_rec_36, tmp628, atslab_s0exp_node, tmp632) ; return (tmp628) ; } /* end of [s0exp_imp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 30941(line=1094, offs=25) -- 31015(line=1096, offs=2) */ ATSglobaldec() ats_ptr_type s0exp_imp_emp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; __ats_lab_s0exp_imp_emp: tmp634 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp636 = e0fftaglst_nil () ; tmp635 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp635)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp635, atslab_0, tmp636) ; tmp633 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp633, atslab_s0exp_loc, tmp634) ; ats_selptrset_mac(anairiats_rec_36, tmp633, atslab_s0exp_node, tmp635) ; return (tmp633) ; } /* end of [s0exp_imp_emp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 31046(line=1098, offs=4) -- 31219(line=1102, offs=2) */ ATSstaticdec() ats_ptr_type s0exp_lam_229 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_ptr_type, tmp638) ; __ats_lab_s0exp_lam_229: tmp638 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp638)->tag = 8 ; ats_selptrset_mac(anairiats_sum_38, tmp638, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp638, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_38, tmp638, atslab_2, arg3) ; tmp637 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp637, atslab_s0exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_36, tmp637, atslab_s0exp_node, tmp638) ; return (tmp637) ; } /* end of [s0exp_lam_229] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 31359(line=1109, offs=7) -- 31593(line=1115, offs=49) */ ATSstaticdec() ats_ptr_type aux_231 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; __ats_lab_aux_231: do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp645 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp646 = s0rtopt_none () ; tmp647 = aux_231 (env0, env1, env2, tmp644, tmp645) ; tmp643 = s0exp_lam_229 (env2, arg0, tmp646, tmp647) ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_109_1: tmp643 = s0exp_lam_229 (env2, arg0, env0, env1) ; break ; } while (0) ; return (tmp643) ; } /* end of [aux_231] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_231_closure_type ; ats_ptr_type aux_231_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_231 (((aux_231_closure_type*)cloptr)->closure_env_0, ((aux_231_closure_type*)cloptr)->closure_env_1, ((aux_231_closure_type*)cloptr)->closure_env_2, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_231_closure_init (aux_231_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_231_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_231_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_231_closure_type *p_clo = ATS_MALLOC(sizeof(aux_231_closure_type)) ; aux_231_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 31265(line=1105, offs=12) -- 31691(line=1120, offs=4) */ ATSglobaldec() ats_ptr_type s0exp_lams (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_ptr_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; __ats_lab_s0exp_lams: tmp641 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp642 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg3), atslab_s0exp_loc) ; tmp640 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp641, tmp642) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp648 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp649 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp639 = aux_231 (arg2, arg3, tmp640, tmp648, tmp649) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_111_1: tmp639 = arg3 ; break ; } while (0) ; return (tmp639) ; } /* end of [s0exp_lams] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 31758(line=1124, offs=22) -- 31894(line=1127, offs=4) */ ATSglobaldec() ats_ptr_type s0exp_list (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; __ats_lab_s0exp_list: tmp652 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp653 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp651 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp652, tmp653) ; tmp654 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp654)->tag = 9 ; ats_selptrset_mac(anairiats_sum_0, tmp654, atslab_0, arg1) ; tmp650 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp650, atslab_s0exp_loc, tmp651) ; ats_selptrset_mac(anairiats_rec_36, tmp650, atslab_s0exp_node, tmp654) ; return (tmp650) ; } /* end of [s0exp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 31943(line=1130, offs=3) -- 32096(line=1133, offs=4) */ ATSglobaldec() ats_ptr_type s0exp_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_ptr_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; __ats_lab_s0exp_list2: tmp657 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp658 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp656 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp657, tmp658) ; tmp659 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp659)->tag = 10 ; ats_selptrset_mac(anairiats_sum_15, tmp659, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp659, atslab_1, arg2) ; tmp655 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp655, atslab_s0exp_loc, tmp656) ; ats_selptrset_mac(anairiats_rec_36, tmp655, atslab_s0exp_node, tmp659) ; return (tmp655) ; } /* end of [s0exp_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 32413(line=1148, offs=23) -- 32541(line=1152, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_opide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_ptr_type, tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; __ats_lab_s0exp_opide: tmp662 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp663 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp661 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp662, tmp663) ; tmp665 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp664 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp664)->tag = 12 ; ats_selptrset_mac(anairiats_sum_0, tmp664, atslab_0, tmp665) ; tmp660 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp660, atslab_s0exp_loc, tmp661) ; ats_selptrset_mac(anairiats_rec_36, tmp660, atslab_s0exp_node, tmp664) ; return (tmp660) ; } /* end of [s0exp_opide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 32587(line=1154, offs=21) -- 32718(line=1158, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_qid (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; __ats_lab_s0exp_qid: tmp668 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_27, arg0), atslab_s0taq_loc) ; tmp669 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp667 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp668, tmp669) ; tmp671 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp670 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp670)->tag = 13 ; ats_selptrset_mac(anairiats_sum_15, tmp670, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp670, atslab_1, tmp671) ; tmp666 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp666, atslab_s0exp_loc, tmp667) ; ats_selptrset_mac(anairiats_rec_36, tmp666, atslab_s0exp_node, tmp670) ; return (tmp666) ; } /* end of [s0exp_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 32997(line=1170, offs=23) -- 33150(line=1174, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_tyarr (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; __ats_lab_s0exp_tyarr: tmp674 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp675 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg2), atslab_s0arrind_loc) ; tmp673 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp674, tmp675) ; tmp677 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg2), atslab_s0arrind_ind) ; tmp676 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp676)->tag = 14 ; ats_selptrset_mac(anairiats_sum_15, tmp676, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp676, atslab_1, tmp677) ; tmp672 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp672, atslab_s0exp_loc, tmp673) ; ats_selptrset_mac(anairiats_rec_36, tmp672, atslab_s0exp_node, tmp676) ; return (tmp672) ; } /* end of [s0exp_tyarr] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 33200(line=1177, offs=3) -- 33351(line=1181, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_tyrec (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; __ats_lab_s0exp_tyrec: tmp680 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp681 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp679 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp680, tmp681) ; tmp682 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp682)->tag = 15 ; ats_selptrset_mac(anairiats_sum_24, tmp682, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp682, atslab_1, arg2) ; tmp678 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp678, atslab_s0exp_loc, tmp679) ; ats_selptrset_mac(anairiats_rec_36, tmp678, atslab_s0exp_node, tmp682) ; return (tmp678) ; } /* end of [s0exp_tyrec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 33405(line=1184, offs=3) -- 33583(line=1188, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_tyrec_ext (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; __ats_lab_s0exp_tyrec_ext: tmp685 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp686 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp684 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp685, tmp686) ; tmp688 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0tring_val) ; tmp687 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp687)->tag = 16 ; ats_selptrset_mac(anairiats_sum_15, tmp687, atslab_0, tmp688) ; ats_selptrset_mac(anairiats_sum_15, tmp687, atslab_1, arg2) ; tmp683 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp683, atslab_s0exp_loc, tmp684) ; ats_selptrset_mac(anairiats_rec_36, tmp683, atslab_s0exp_node, tmp687) ; return (tmp683) ; } /* end of [s0exp_tyrec_ext] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 33637(line=1191, offs=3) -- 33786(line=1195, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_tytup (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp689) ; ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; __ats_lab_s0exp_tytup: tmp691 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp692 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp691, tmp692) ; tmp693 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp693)->tag = 17 ; ats_selptrset_mac(anairiats_sum_24, tmp693, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp693, atslab_1, arg2) ; tmp689 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp689, atslab_s0exp_loc, tmp690) ; ats_selptrset_mac(anairiats_rec_36, tmp689, atslab_s0exp_node, tmp693) ; return (tmp689) ; } /* end of [s0exp_tytup] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 33837(line=1198, offs=3) -- 34003(line=1202, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_tytup2 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; __ats_lab_s0exp_tytup2: tmp696 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp697 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp695 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp696, tmp697) ; tmp698 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp698)->tag = 18 ; ats_selptrset_mac(anairiats_sum_40, tmp698, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp698, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_40, tmp698, atslab_2, arg3) ; tmp694 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp694, atslab_s0exp_loc, tmp695) ; ats_selptrset_mac(anairiats_rec_36, tmp694, atslab_s0exp_node, tmp698) ; return (tmp694) ; } /* end of [s0exp_tytup2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34050(line=1204, offs=21) -- 34190(line=1208, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_uni (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; __ats_lab_s0exp_uni: tmp701 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp702 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp700 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp701, tmp702) ; tmp703 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp703)->tag = 19 ; ats_selptrset_mac(anairiats_sum_0, tmp703, atslab_0, arg1) ; tmp699 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp699, atslab_s0exp_loc, tmp700) ; ats_selptrset_mac(anairiats_rec_36, tmp699, atslab_s0exp_node, tmp703) ; return (tmp699) ; } /* end of [s0exp_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34238(line=1211, offs=3) -- 34391(line=1215, offs=6) */ ATSglobaldec() ats_ptr_type s0exp_union (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_ptr_type, tmp708) ; __ats_lab_s0exp_union: tmp706 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp707 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp705 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp706, tmp707) ; tmp708 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp708)->tag = 20 ; ats_selptrset_mac(anairiats_sum_15, tmp708, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp708, atslab_1, arg2) ; tmp704 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp704, atslab_s0exp_loc, tmp705) ; ats_selptrset_mac(anairiats_rec_36, tmp704, atslab_s0exp_node, tmp708) ; return (tmp704) ; } /* end of [s0exp_union] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34461(line=1219, offs=24) -- 34472(line=1219, offs=35) */ ATSglobaldec() ats_ptr_type s0explst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp709) ; __ats_lab_s0explst_nil: tmp709 = (ats_sum_ptr_type)0 ; return (tmp709) ; } /* end of [s0explst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34497(line=1220, offs=25) -- 34519(line=1220, offs=47) */ ATSglobaldec() ats_ptr_type s0explst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp710) ; __ats_lab_s0explst_cons: tmp710 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp710, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp710, atslab_1, arg1) ; return (tmp710) ; } /* end of [s0explst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34545(line=1222, offs=25) -- 34557(line=1222, offs=37) */ ATSglobaldec() ats_ptr_type s0expopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp711) ; __ats_lab_s0expopt_none: tmp711 = (ats_sum_ptr_type)0 ; return (tmp711) ; } /* end of [s0expopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34582(line=1223, offs=25) -- 34595(line=1223, offs=38) */ ATSglobaldec() ats_ptr_type s0expopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp712) ; __ats_lab_s0expopt_some: tmp712 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp712, atslab_0, arg0) ; return (tmp712) ; } /* end of [s0expopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34624(line=1225, offs=27) -- 34635(line=1225, offs=38) */ ATSglobaldec() ats_ptr_type s0explstlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp713) ; __ats_lab_s0explstlst_nil: tmp713 = (ats_sum_ptr_type)0 ; return (tmp713) ; } /* end of [s0explstlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34663(line=1226, offs=28) -- 34685(line=1226, offs=50) */ ATSglobaldec() ats_ptr_type s0explstlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp714) ; __ats_lab_s0explstlst_cons: tmp714 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp714, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp714, atslab_1, arg1) ; return (tmp714) ; } /* end of [s0explstlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34714(line=1228, offs=28) -- 34726(line=1228, offs=40) */ ATSglobaldec() ats_ptr_type s0explstopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp715) ; __ats_lab_s0explstopt_none: tmp715 = (ats_sum_ptr_type)0 ; return (tmp715) ; } /* end of [s0explstopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34754(line=1229, offs=28) -- 34767(line=1229, offs=41) */ ATSglobaldec() ats_ptr_type s0explstopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp716) ; __ats_lab_s0explstopt_some: tmp716 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp716, atslab_0, arg0) ; return (tmp716) ; } /* end of [s0explstopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34817(line=1233, offs=27) -- 34839(line=1233, offs=49) */ ATSglobaldec() ats_ptr_type labs0explst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp717) ; __ats_lab_labs0explst_nil: tmp717 = (ats_sum_ptr_type)0 ; return (tmp717) ; } /* end of [labs0explst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34867(line=1234, offs=28) -- 34916(line=1234, offs=77) */ ATSglobaldec() ats_ptr_type labs0explst_cons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp718) ; __ats_lab_labs0explst_cons: tmp718 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp718, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_37, tmp718, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_37, tmp718, atslab_2, arg2) ; return (tmp718) ; } /* end of [labs0explst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 34968(line=1238, offs=30) -- 35064(line=1240, offs=2) */ ATSglobaldec() ats_ptr_type s0arrind_make_sing (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_ptr_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; __ats_lab_s0arrind_make_sing: tmp720 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp722 = (ats_sum_ptr_type)0 ; tmp721 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp721, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp721, atslab_1, tmp722) ; tmp719 = ATS_MALLOC(sizeof(anairiats_rec_39)) ; ats_selptrset_mac(anairiats_rec_39, tmp719, atslab_s0arrind_loc, tmp720) ; ats_selptrset_mac(anairiats_rec_39, tmp719, atslab_s0arrind_ind, tmp721) ; return (tmp719) ; } /* end of [s0arrind_make_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35126(line=1242, offs=30) -- 35222(line=1244, offs=2) */ ATSglobaldec() ats_ptr_type s0arrind_make_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_ptr_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_ptr_type, tmp726) ; __ats_lab_s0arrind_make_cons: tmp724 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg1), atslab_s0arrind_loc) ; tmp726 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_39, arg1), atslab_s0arrind_ind) ; tmp725 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp725, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp725, atslab_1, tmp726) ; tmp723 = ATS_MALLOC(sizeof(anairiats_rec_39)) ; ats_selptrset_mac(anairiats_rec_39, tmp723, atslab_s0arrind_loc, tmp724) ; ats_selptrset_mac(anairiats_rec_39, tmp723, atslab_s0arrind_ind, tmp725) ; return (tmp723) ; } /* end of [s0arrind_make_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35298(line=1248, offs=23) -- 35365(line=1249, offs=60) */ ATSglobaldec() ats_ptr_type s0rtext_srt (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; __ats_lab_s0rtext_srt: tmp728 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg0), atslab_s0rt_loc) ; tmp729 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp729)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp729, atslab_0, arg0) ; tmp727 = ATS_MALLOC(sizeof(anairiats_rec_41)) ; ats_selptrset_mac(anairiats_rec_41, tmp727, atslab_s0rtext_loc, tmp728) ; ats_selptrset_mac(anairiats_rec_41, tmp727, atslab_s0rtext_node, tmp729) ; return (tmp727) ; } /* end of [s0rtext_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35389(line=1251, offs=23) -- 35563(line=1254, offs=6) */ ATSglobaldec() ats_ptr_type s0rtext_sub (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_ptr_type, tmp732) ; ATSlocal (ats_ptr_type, tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; __ats_lab_s0rtext_sub: tmp732 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp733 = ats_selsin_mac(arg5, atslab_t0kn_loc) ; tmp731 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp732, tmp733) ; tmp734 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp734)->tag = 1 ; ats_selptrset_mac(anairiats_sum_42, tmp734, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp734, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp734, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_42, tmp734, atslab_3, arg4) ; tmp730 = ATS_MALLOC(sizeof(anairiats_rec_41)) ; ats_selptrset_mac(anairiats_rec_41, tmp730, atslab_s0rtext_loc, tmp731) ; ats_selptrset_mac(anairiats_rec_41, tmp730, atslab_s0rtext_node, tmp734) ; return (tmp730) ; } /* end of [s0rtext_sub] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35607(line=1258, offs=22) -- 35673(line=1260, offs=2) */ ATSglobaldec() ats_ptr_type s0qua_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; __ats_lab_s0qua_prop: tmp736 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg0), atslab_s0exp_loc) ; tmp737 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp737)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp737, atslab_0, arg0) ; tmp735 = ATS_MALLOC(sizeof(anairiats_rec_43)) ; ats_selptrset_mac(anairiats_rec_43, tmp735, atslab_s0qua_loc, tmp736) ; ats_selptrset_mac(anairiats_rec_43, tmp735, atslab_s0qua_node, tmp737) ; return (tmp735) ; } /* end of [s0qua_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35696(line=1262, offs=22) -- 35841(line=1265, offs=6) */ ATSglobaldec() ats_ptr_type s0qua_vars (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; __ats_lab_s0qua_vars: tmp740 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp741 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg2), atslab_s0rtext_loc) ; tmp739 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp740, tmp741) ; tmp742 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp742)->tag = 1 ; ats_selptrset_mac(anairiats_sum_38, tmp742, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp742, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp742, atslab_2, arg2) ; tmp738 = ATS_MALLOC(sizeof(anairiats_rec_43)) ; ats_selptrset_mac(anairiats_rec_43, tmp738, atslab_s0qua_loc, tmp739) ; ats_selptrset_mac(anairiats_rec_43, tmp738, atslab_s0qua_node, tmp742) ; return (tmp738) ; } /* end of [s0qua_vars] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35866(line=1267, offs=24) -- 35877(line=1267, offs=35) */ ATSglobaldec() ats_ptr_type s0qualst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp743) ; __ats_lab_s0qualst_nil: tmp743 = (ats_sum_ptr_type)0 ; return (tmp743) ; } /* end of [s0qualst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35902(line=1268, offs=25) -- 35924(line=1268, offs=47) */ ATSglobaldec() ats_ptr_type s0qualst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp744) ; __ats_lab_s0qualst_cons: tmp744 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp744, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp744, atslab_1, arg1) ; return (tmp744) ; } /* end of [s0qualst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35952(line=1270, offs=27) -- 35963(line=1270, offs=38) */ ATSglobaldec() ats_ptr_type s0qualstlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp745) ; __ats_lab_s0qualstlst_nil: tmp745 = (ats_sum_ptr_type)0 ; return (tmp745) ; } /* end of [s0qualstlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 35991(line=1271, offs=28) -- 36013(line=1271, offs=50) */ ATSglobaldec() ats_ptr_type s0qualstlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp746) ; __ats_lab_s0qualstlst_cons: tmp746 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp746, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp746, atslab_1, arg1) ; return (tmp746) ; } /* end of [s0qualstlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36042(line=1273, offs=28) -- 36054(line=1273, offs=40) */ ATSglobaldec() ats_ptr_type s0qualstopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp747) ; __ats_lab_s0qualstopt_none: tmp747 = (ats_sum_ptr_type)0 ; return (tmp747) ; } /* end of [s0qualstopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36082(line=1274, offs=28) -- 36095(line=1274, offs=41) */ ATSglobaldec() ats_ptr_type s0qualstopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp748) ; __ats_lab_s0qualstopt_some: tmp748 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp748, atslab_0, arg0) ; return (tmp748) ; } /* end of [s0qualstopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36148(line=1279, offs=20) -- 36297(line=1284, offs=2) */ ATSglobaldec() ats_ptr_type impqi0de_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_ptr_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; __ats_lab_impqi0de_make_none: tmp750 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_dqi0de_loc) ; tmp751 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_dqi0de_qua) ; tmp752 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg0), atslab_dqi0de_sym) ; tmp753 = gtlt_t1mps0expseqseq_nil () ; tmp749 = ATS_MALLOC(sizeof(anairiats_rec_44)) ; ats_selptrset_mac(anairiats_rec_44, tmp749, atslab_impqi0de_loc, tmp750) ; ats_selptrset_mac(anairiats_rec_44, tmp749, atslab_impqi0de_qua, tmp751) ; ats_selptrset_mac(anairiats_rec_44, tmp749, atslab_impqi0de_sym, tmp752) ; ats_selptrset_mac(anairiats_rec_44, tmp749, atslab_impqi0de_arg, tmp753) ; return (tmp749) ; } /* end of [impqi0de_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36361(line=1288, offs=3) -- 36705(line=1298, offs=6) */ ATSglobaldec() ats_ptr_type impqi0de_make_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; __ats_lab_impqi0de_make_some: tmp755 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_tmpqi0de_loc) ; tmp756 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make (tmp755) ; tmp758 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp757 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp755, tmp758) ; tmp759 = gtlt_t1mps0expseqseq_cons_loc_212 (tmp756, arg1, arg2) ; tmp760 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_tmpqi0de_qua) ; tmp761 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_tmpqi0de_sym) ; tmp754 = ATS_MALLOC(sizeof(anairiats_rec_44)) ; ats_selptrset_mac(anairiats_rec_44, tmp754, atslab_impqi0de_loc, tmp757) ; ats_selptrset_mac(anairiats_rec_44, tmp754, atslab_impqi0de_qua, tmp760) ; ats_selptrset_mac(anairiats_rec_44, tmp754, atslab_impqi0de_sym, tmp761) ; ats_selptrset_mac(anairiats_rec_44, tmp754, atslab_impqi0de_arg, tmp759) ; return (tmp754) ; } /* end of [impqi0de_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36788(line=1303, offs=19) -- 36884(line=1306, offs=2) */ ATSglobaldec() ats_ptr_type i0nvarg_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; __ats_lab_i0nvarg_make_none: tmp763 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp764 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp765 = s0expopt_none () ; tmp762 = ATS_MALLOC(sizeof(anairiats_rec_45)) ; ats_selptrset_mac(anairiats_rec_45, tmp762, atslab_i0nvarg_loc, tmp763) ; ats_selptrset_mac(anairiats_rec_45, tmp762, atslab_i0nvarg_sym, tmp764) ; ats_selptrset_mac(anairiats_rec_45, tmp762, atslab_i0nvarg_typ, tmp765) ; return (tmp762) ; } /* end of [i0nvarg_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 36914(line=1309, offs=19) -- 37069(line=1314, offs=6) */ ATSglobaldec() ats_ptr_type i0nvarg_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; __ats_lab_i0nvarg_make_some: tmp768 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp769 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp767 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp768, tmp769) ; tmp770 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp771 = s0expopt_some (arg1) ; tmp766 = ATS_MALLOC(sizeof(anairiats_rec_45)) ; ats_selptrset_mac(anairiats_rec_45, tmp766, atslab_i0nvarg_loc, tmp767) ; ats_selptrset_mac(anairiats_rec_45, tmp766, atslab_i0nvarg_sym, tmp770) ; ats_selptrset_mac(anairiats_rec_45, tmp766, atslab_i0nvarg_typ, tmp771) ; return (tmp766) ; } /* end of [i0nvarg_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37126(line=1316, offs=26) -- 37137(line=1316, offs=37) */ ATSglobaldec() ats_ptr_type i0nvarglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp772) ; __ats_lab_i0nvarglst_nil: tmp772 = (ats_sum_ptr_type)0 ; return (tmp772) ; } /* end of [i0nvarglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37164(line=1317, offs=27) -- 37186(line=1317, offs=49) */ ATSglobaldec() ats_ptr_type i0nvarglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp773) ; __ats_lab_i0nvarglst_cons: tmp773 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp773, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp773, atslab_1, arg1) ; return (tmp773) ; } /* end of [i0nvarglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37216(line=1320, offs=19) -- 37343(line=1324, offs=6) */ ATSglobaldec() ats_ptr_type i0nvresstate_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_ptr_type, tmp776) ; __ats_lab_i0nvresstate_none: tmp775 = s0qualstopt_none () ; tmp776 = i0nvarglst_nil () ; tmp774 = ATS_MALLOC(sizeof(anairiats_rec_46)) ; ats_selptrset_mac(anairiats_rec_46, tmp774, atslab_i0nvresstate_qua, tmp775) ; ats_selptrset_mac(anairiats_rec_46, tmp774, atslab_i0nvresstate_arg, tmp776) ; return (tmp774) ; } /* end of [i0nvresstate_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37403(line=1327, offs=19) -- 37467(line=1329, offs=2) */ ATSglobaldec() ats_ptr_type i0nvresstate_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp777) ; __ats_lab_i0nvresstate_some: tmp777 = ATS_MALLOC(sizeof(anairiats_rec_46)) ; ats_selptrset_mac(anairiats_rec_46, tmp777, atslab_i0nvresstate_qua, arg0) ; ats_selptrset_mac(anairiats_rec_46, tmp777, atslab_i0nvresstate_arg, arg1) ; return (tmp777) ; } /* end of [i0nvresstate_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37523(line=1332, offs=15) -- 37630(line=1337, offs=2) */ ATSglobaldec() ats_ptr_type loopi0nv_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp778) ; __ats_lab_loopi0nv_make: tmp778 = ATS_MALLOC(sizeof(anairiats_rec_47)) ; ats_selptrset_mac(anairiats_rec_47, tmp778, atslab_loopi0nv_qua, arg0) ; ats_selptrset_mac(anairiats_rec_47, tmp778, atslab_loopi0nv_met, arg1) ; ats_selptrset_mac(anairiats_rec_47, tmp778, atslab_loopi0nv_arg, arg2) ; ats_selptrset_mac(anairiats_rec_47, tmp778, atslab_loopi0nv_res, arg3) ; return (tmp778) ; } /* end of [loopi0nv_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37704(line=1341, offs=26) -- 37725(line=1341, offs=47) */ ATSglobaldec() ats_ptr_type witht0ype_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp779) ; __ats_lab_witht0ype_none: tmp779 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__WITHT0YPEnone_0) ; return (tmp779) ; } /* end of [witht0ype_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37751(line=1342, offs=26) -- 37777(line=1342, offs=52) */ ATSglobaldec() ats_ptr_type witht0ype_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp780) ; __ats_lab_witht0ype_prop: tmp780 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp780)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp780, atslab_0, arg0) ; return (tmp780) ; } /* end of [witht0ype_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37804(line=1343, offs=26) -- 37830(line=1343, offs=52) */ ATSglobaldec() ats_ptr_type witht0ype_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp781) ; __ats_lab_witht0ype_type: tmp781 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp781)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp781, atslab_0, arg0) ; return (tmp781) ; } /* end of [witht0ype_type] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37857(line=1344, offs=26) -- 37883(line=1344, offs=52) */ ATSglobaldec() ats_ptr_type witht0ype_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp782) ; __ats_lab_witht0ype_view: tmp782 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp782)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp782, atslab_0, arg0) ; return (tmp782) ; } /* end of [witht0ype_view] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37914(line=1345, offs=30) -- 37944(line=1345, offs=60) */ ATSglobaldec() ats_ptr_type witht0ype_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp783) ; __ats_lab_witht0ype_viewtype: tmp783 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp783)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp783, atslab_0, arg0) ; return (tmp783) ; } /* end of [witht0ype_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 37991(line=1349, offs=24) -- 38278(line=1361, offs=6) */ ATSglobaldec() ats_ptr_type s0rtdef_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; __ats_lab_s0rtdef_make: tmp786 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp787 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_41, arg1), atslab_s0rtext_loc) ; tmp785 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp786, tmp787) ; tmp788 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp784 = ATS_MALLOC(sizeof(anairiats_rec_48)) ; ats_selptrset_mac(anairiats_rec_48, tmp784, atslab_s0rtdef_loc, tmp785) ; ats_selptrset_mac(anairiats_rec_48, tmp784, atslab_s0rtdef_sym, tmp788) ; ats_selptrset_mac(anairiats_rec_48, tmp784, atslab_s0rtdef_def, arg1) ; return (tmp784) ; } /* end of [s0rtdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 38330(line=1363, offs=26) -- 38341(line=1363, offs=37) */ ATSglobaldec() ats_ptr_type s0rtdeflst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp789) ; __ats_lab_s0rtdeflst_nil: tmp789 = (ats_sum_ptr_type)0 ; return (tmp789) ; } /* end of [s0rtdeflst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 38368(line=1364, offs=27) -- 38390(line=1364, offs=49) */ ATSglobaldec() ats_ptr_type s0rtdeflst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp790) ; __ats_lab_s0rtdeflst_cons: tmp790 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp790, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp790, atslab_1, arg1) ; return (tmp790) ; } /* end of [s0rtdeflst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 38448(line=1370, offs=3) -- 38626(line=1378, offs=6) */ ATSglobaldec() ats_ptr_type s0tacon_make_none_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_ptr_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; __ats_lab_s0tacon_make_none_none: tmp792 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp793 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp794 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp795 = (ats_sum_ptr_type)0 ; tmp796 = (ats_sum_ptr_type)0 ; tmp791 = ATS_MALLOC(sizeof(anairiats_rec_49)) ; ats_selptrset_mac(anairiats_rec_49, tmp791, atslab_s0tacon_fil, tmp792) ; ats_selptrset_mac(anairiats_rec_49, tmp791, atslab_s0tacon_loc, tmp793) ; ats_selptrset_mac(anairiats_rec_49, tmp791, atslab_s0tacon_sym, tmp794) ; ats_selptrset_mac(anairiats_rec_49, tmp791, atslab_s0tacon_arg, tmp795) ; ats_selptrset_mac(anairiats_rec_49, tmp791, atslab_s0tacon_def, tmp796) ; return (tmp791) ; } /* end of [s0tacon_make_none_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 38698(line=1382, offs=3) -- 38882(line=1390, offs=6) */ ATSglobaldec() ats_ptr_type s0tacon_make_some_none (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; __ats_lab_s0tacon_make_some_none: tmp798 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp799 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp800 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp801 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp801, atslab_0, arg1) ; tmp802 = (ats_sum_ptr_type)0 ; tmp797 = ATS_MALLOC(sizeof(anairiats_rec_49)) ; ats_selptrset_mac(anairiats_rec_49, tmp797, atslab_s0tacon_fil, tmp798) ; ats_selptrset_mac(anairiats_rec_49, tmp797, atslab_s0tacon_loc, tmp799) ; ats_selptrset_mac(anairiats_rec_49, tmp797, atslab_s0tacon_sym, tmp800) ; ats_selptrset_mac(anairiats_rec_49, tmp797, atslab_s0tacon_arg, tmp801) ; ats_selptrset_mac(anairiats_rec_49, tmp797, atslab_s0tacon_def, tmp802) ; return (tmp797) ; } /* end of [s0tacon_make_some_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 38954(line=1394, offs=3) -- 39179(line=1402, offs=6) */ ATSglobaldec() ats_ptr_type s0tacon_make_none_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_ptr_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; __ats_lab_s0tacon_make_none_some: tmp804 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp806 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp807 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp805 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp806, tmp807) ; tmp808 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp809 = (ats_sum_ptr_type)0 ; tmp810 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp810, atslab_0, arg1) ; tmp803 = ATS_MALLOC(sizeof(anairiats_rec_49)) ; ats_selptrset_mac(anairiats_rec_49, tmp803, atslab_s0tacon_fil, tmp804) ; ats_selptrset_mac(anairiats_rec_49, tmp803, atslab_s0tacon_loc, tmp805) ; ats_selptrset_mac(anairiats_rec_49, tmp803, atslab_s0tacon_sym, tmp808) ; ats_selptrset_mac(anairiats_rec_49, tmp803, atslab_s0tacon_arg, tmp809) ; ats_selptrset_mac(anairiats_rec_49, tmp803, atslab_s0tacon_def, tmp810) ; return (tmp803) ; } /* end of [s0tacon_make_none_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 39251(line=1406, offs=3) -- 39482(line=1414, offs=6) */ ATSglobaldec() ats_ptr_type s0tacon_make_some_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_ptr_type, tmp818) ; __ats_lab_s0tacon_make_some_some: tmp812 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp814 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp815 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg2), atslab_s0exp_loc) ; tmp813 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp814, tmp815) ; tmp816 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp817 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp817, atslab_0, arg1) ; tmp818 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp818, atslab_0, arg2) ; tmp811 = ATS_MALLOC(sizeof(anairiats_rec_49)) ; ats_selptrset_mac(anairiats_rec_49, tmp811, atslab_s0tacon_fil, tmp812) ; ats_selptrset_mac(anairiats_rec_49, tmp811, atslab_s0tacon_loc, tmp813) ; ats_selptrset_mac(anairiats_rec_49, tmp811, atslab_s0tacon_sym, tmp816) ; ats_selptrset_mac(anairiats_rec_49, tmp811, atslab_s0tacon_arg, tmp817) ; ats_selptrset_mac(anairiats_rec_49, tmp811, atslab_s0tacon_def, tmp818) ; return (tmp811) ; } /* end of [s0tacon_make_some_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 39544(line=1416, offs=26) -- 39555(line=1416, offs=37) */ ATSglobaldec() ats_ptr_type s0taconlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp819) ; __ats_lab_s0taconlst_nil: tmp819 = (ats_sum_ptr_type)0 ; return (tmp819) ; } /* end of [s0taconlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 39582(line=1417, offs=27) -- 39604(line=1417, offs=49) */ ATSglobaldec() ats_ptr_type s0taconlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp820) ; __ats_lab_s0taconlst_cons: tmp820 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp820, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp820, atslab_1, arg1) ; return (tmp820) ; } /* end of [s0taconlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 39657(line=1423, offs=3) -- 39876(line=1432, offs=6) */ ATSglobaldec() ats_ptr_type s0tacst_make_none (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; __ats_lab_s0tacst_make_none: tmp822 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp824 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp825 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_loc) ; tmp823 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp824, tmp825) ; tmp826 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp827 = (ats_sum_ptr_type)0 ; tmp821 = ATS_MALLOC(sizeof(anairiats_rec_50)) ; ats_selptrset_mac(anairiats_rec_50, tmp821, atslab_s0tacst_fil, tmp822) ; ats_selptrset_mac(anairiats_rec_50, tmp821, atslab_s0tacst_loc, tmp823) ; ats_selptrset_mac(anairiats_rec_50, tmp821, atslab_s0tacst_sym, tmp826) ; ats_selptrset_mac(anairiats_rec_50, tmp821, atslab_s0tacst_arg, tmp827) ; ats_selptrset_mac(anairiats_rec_50, tmp821, atslab_s0tacst_res, arg1) ; return (tmp821) ; } /* end of [s0tacst_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 39938(line=1436, offs=3) -- 40163(line=1445, offs=6) */ ATSglobaldec() ats_ptr_type s0tacst_make_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; __ats_lab_s0tacst_make_some: tmp829 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp831 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp832 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg2), atslab_s0rt_loc) ; tmp830 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp831, tmp832) ; tmp833 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp834 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp834, atslab_0, arg1) ; tmp828 = ATS_MALLOC(sizeof(anairiats_rec_50)) ; ats_selptrset_mac(anairiats_rec_50, tmp828, atslab_s0tacst_fil, tmp829) ; ats_selptrset_mac(anairiats_rec_50, tmp828, atslab_s0tacst_loc, tmp830) ; ats_selptrset_mac(anairiats_rec_50, tmp828, atslab_s0tacst_sym, tmp833) ; ats_selptrset_mac(anairiats_rec_50, tmp828, atslab_s0tacst_arg, tmp834) ; ats_selptrset_mac(anairiats_rec_50, tmp828, atslab_s0tacst_res, arg2) ; return (tmp828) ; } /* end of [s0tacst_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40220(line=1447, offs=26) -- 40231(line=1447, offs=37) */ ATSglobaldec() ats_ptr_type s0tacstlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp835) ; __ats_lab_s0tacstlst_nil: tmp835 = (ats_sum_ptr_type)0 ; return (tmp835) ; } /* end of [s0tacstlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40258(line=1448, offs=27) -- 40280(line=1448, offs=49) */ ATSglobaldec() ats_ptr_type s0tacstlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp836) ; __ats_lab_s0tacstlst_cons: tmp836 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp836, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp836, atslab_1, arg1) ; return (tmp836) ; } /* end of [s0tacstlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40326(line=1453, offs=14) -- 40466(line=1459, offs=6) */ ATSglobaldec() ats_ptr_type s0tavar_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; __ats_lab_s0tavar_make: tmp839 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp840 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, arg1), atslab_s0rt_loc) ; tmp838 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp839, tmp840) ; tmp841 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp837 = ATS_MALLOC(sizeof(anairiats_rec_51)) ; ats_selptrset_mac(anairiats_rec_51, tmp837, atslab_s0tavar_loc, tmp838) ; ats_selptrset_mac(anairiats_rec_51, tmp837, atslab_s0tavar_sym, tmp841) ; ats_selptrset_mac(anairiats_rec_51, tmp837, atslab_s0tavar_srt, arg1) ; return (tmp837) ; } /* end of [s0tavar_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40518(line=1461, offs=26) -- 40529(line=1461, offs=37) */ ATSglobaldec() ats_ptr_type s0tavarlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp842) ; __ats_lab_s0tavarlst_nil: tmp842 = (ats_sum_ptr_type)0 ; return (tmp842) ; } /* end of [s0tavarlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40556(line=1462, offs=27) -- 40578(line=1462, offs=49) */ ATSglobaldec() ats_ptr_type s0tavarlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp843) ; __ats_lab_s0tavarlst_cons: tmp843 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp843, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp843, atslab_1, arg1) ; return (tmp843) ; } /* end of [s0tavarlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40625(line=1467, offs=15) -- 40853(line=1478, offs=6) */ ATSglobaldec() ats_ptr_type s0expdef_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_ptr_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_ptr_type, tmp848) ; ATSlocal (ats_ptr_type, tmp849) ; __ats_lab_s0expdef_make: tmp846 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp847 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg3), atslab_s0exp_loc) ; tmp845 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp846, tmp847) ; tmp848 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp849 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp844 = ATS_MALLOC(sizeof(anairiats_rec_52)) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_loc, tmp845) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_sym, tmp848) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_loc_id, tmp849) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_arg, arg1) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_res, arg2) ; ats_selptrset_mac(anairiats_rec_52, tmp844, atslab_s0expdef_def, arg3) ; return (tmp844) ; } /* end of [s0expdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40907(line=1480, offs=27) -- 40918(line=1480, offs=38) */ ATSglobaldec() ats_ptr_type s0expdeflst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp850) ; __ats_lab_s0expdeflst_nil: tmp850 = (ats_sum_ptr_type)0 ; return (tmp850) ; } /* end of [s0expdeflst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 40946(line=1481, offs=28) -- 40968(line=1481, offs=50) */ ATSglobaldec() ats_ptr_type s0expdeflst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp851) ; __ats_lab_s0expdeflst_cons: tmp851 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp851, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp851, atslab_1, arg1) ; return (tmp851) ; } /* end of [s0expdeflst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41017(line=1487, offs=3) -- 41264(line=1497, offs=6) */ ATSglobaldec() ats_ptr_type s0aspdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; __ats_lab_s0aspdec_make: tmp853 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp855 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_29, arg0), atslab_sqi0de_loc) ; tmp856 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg3), atslab_s0exp_loc) ; tmp854 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp855, tmp856) ; tmp852 = ATS_MALLOC(sizeof(anairiats_rec_53)) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_fil, tmp853) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_loc, tmp854) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_qid, arg0) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_arg, arg1) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_res, arg2) ; ats_selptrset_mac(anairiats_rec_53, tmp852, atslab_s0aspdec_def, arg3) ; return (tmp852) ; } /* end of [s0aspdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41336(line=1502, offs=14) -- 41728(line=1518, offs=6) */ ATSglobaldec() ats_ptr_type d0atcon_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; __ats_lab_d0atcon_make: tmp858 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; do { /* branch: __ats_lab_112 */ __ats_lab_112_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp860 = ats_caselptrlab_mac(anairiats_sum_13, arg3, atslab_0) ; tmp861 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp860), atslab_s0exp_loc) ; tmp859 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp858, tmp861) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp862 = ats_caselptrlab_mac(anairiats_sum_13, arg2, atslab_0) ; tmp863 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp862), atslab_s0exp_loc) ; tmp859 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp858, tmp863) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: __ats_lab_115_1: tmp859 = tmp858 ; break ; } while (0) ; break ; } while (0) ; tmp864 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp857 = ATS_MALLOC(sizeof(anairiats_rec_54)) ; ats_selptrset_mac(anairiats_rec_54, tmp857, atslab_d0atcon_loc, tmp859) ; ats_selptrset_mac(anairiats_rec_54, tmp857, atslab_d0atcon_sym, tmp864) ; ats_selptrset_mac(anairiats_rec_54, tmp857, atslab_d0atcon_qua, arg0) ; ats_selptrset_mac(anairiats_rec_54, tmp857, atslab_d0atcon_arg, arg3) ; ats_selptrset_mac(anairiats_rec_54, tmp857, atslab_d0atcon_ind, arg2) ; return (tmp857) ; } /* end of [d0atcon_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41780(line=1520, offs=26) -- 41791(line=1520, offs=37) */ ATSglobaldec() ats_ptr_type d0atconlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp865) ; __ats_lab_d0atconlst_nil: tmp865 = (ats_sum_ptr_type)0 ; return (tmp865) ; } /* end of [d0atconlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41818(line=1521, offs=27) -- 41840(line=1521, offs=49) */ ATSglobaldec() ats_ptr_type d0atconlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp866) ; __ats_lab_d0atconlst_cons: tmp866 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp866, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp866, atslab_1, arg1) ; return (tmp866) ; } /* end of [d0atconlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41950(line=1531, offs=5) -- 42113(line=1539, offs=2) */ ATSstaticdec() ats_ptr_type aux_loc_303 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_ptr_type, tmp869) ; ATSlocal (ats_ptr_type, tmp870) ; ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; __ats_lab_aux_loc_303: do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp869 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp870 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp869 ; arg2 = tmp870 ; goto __ats_lab_aux_loc_303 ; // tail call break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp871 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp872 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_54, arg1), atslab_d0atcon_loc) ; tmp868 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp871, tmp872) ; break ; } while (0) ; return (tmp868) ; } /* end of [aux_loc_303] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 41846(line=1523, offs=5) -- 42412(line=1555, offs=6) */ ATSstaticdec() ats_ptr_type d0atdec_make_302 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp867) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; __ats_lab_d0atdec_make_302: tmp873 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp875 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp876 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp874 = aux_loc_303 (arg0, tmp875, tmp876) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: tmp874 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; break ; } while (0) ; tmp877 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp867 = ATS_MALLOC(sizeof(anairiats_rec_55)) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_fil, tmp873) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_loc, tmp874) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_headloc, arg1) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_sym, tmp877) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_arg, arg2) ; ats_selptrset_mac(anairiats_rec_55, tmp867, atslab_d0atdec_con, arg3) ; return (tmp867) ; } /* end of [d0atdec_make_302] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 42467(line=1558, offs=19) -- 42525(line=1560, offs=46) */ ATSglobaldec() ats_ptr_type d0atdec_make_none (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_ptr_type, tmp880) ; __ats_lab_d0atdec_make_none: tmp879 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp880 = (ats_sum_ptr_type)0 ; tmp878 = d0atdec_make_302 (arg0, tmp879, tmp880, arg1) ; return (tmp878) ; } /* end of [d0atdec_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 42559(line=1565, offs=3) -- 42699(line=1570, offs=4) */ ATSglobaldec() ats_ptr_type d0atdec_make_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_ptr_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; __ats_lab_d0atdec_make_some: tmp882 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp884 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp883 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp882, tmp884) ; tmp885 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp885, atslab_0, arg1) ; tmp881 = d0atdec_make_302 (arg0, tmp883, tmp885, arg3) ; return (tmp881) ; } /* end of [d0atdec_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 42756(line=1572, offs=26) -- 42772(line=1572, offs=42) */ ATSglobaldec() ats_ptr_type d0atdeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp886) ; __ats_lab_d0atdeclst_nil: tmp886 = (ats_sum_ptr_type)0 ; return (tmp886) ; } /* end of [d0atdeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 42799(line=1573, offs=27) -- 42826(line=1573, offs=54) */ ATSglobaldec() ats_ptr_type d0atdeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp887) ; __ats_lab_d0atdeclst_cons: tmp887 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp887, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp887, atslab_1, arg1) ; return (tmp887) ; } /* end of [d0atdeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 42874(line=1579, offs=3) -- 43168(line=1591, offs=6) */ ATSglobaldec() ats_ptr_type e0xndec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp888) ; ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_ptr_type, tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; __ats_lab_e0xndec_make: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp890 = ats_caselptrlab_mac(anairiats_sum_13, arg2, atslab_0) ; tmp891 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp892 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp890), atslab_s0exp_loc) ; tmp889 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp891, tmp892) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: tmp889 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; break ; } while (0) ; tmp893 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp894 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp888 = ATS_MALLOC(sizeof(anairiats_rec_56)) ; ats_selptrset_mac(anairiats_rec_56, tmp888, atslab_e0xndec_fil, tmp893) ; ats_selptrset_mac(anairiats_rec_56, tmp888, atslab_e0xndec_loc, tmp889) ; ats_selptrset_mac(anairiats_rec_56, tmp888, atslab_e0xndec_sym, tmp894) ; ats_selptrset_mac(anairiats_rec_56, tmp888, atslab_e0xndec_qua, arg0) ; ats_selptrset_mac(anairiats_rec_56, tmp888, atslab_e0xndec_arg, arg2) ; return (tmp888) ; } /* end of [e0xndec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43220(line=1593, offs=26) -- 43236(line=1593, offs=42) */ ATSglobaldec() ats_ptr_type e0xndeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp895) ; __ats_lab_e0xndeclst_nil: tmp895 = (ats_sum_ptr_type)0 ; return (tmp895) ; } /* end of [e0xndeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43263(line=1594, offs=27) -- 43290(line=1594, offs=54) */ ATSglobaldec() ats_ptr_type e0xndeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp896) ; __ats_lab_e0xndeclst_cons: tmp896 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp896, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp896, atslab_1, arg1) ; return (tmp896) ; } /* end of [e0xndeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43339(line=1598, offs=27) -- 43419(line=1599, offs=74) */ ATSglobaldec() ats_ptr_type p0arg_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; __ats_lab_p0arg_make_none: tmp898 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp899 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp900 = (ats_sum_ptr_type)0 ; tmp897 = ATS_MALLOC(sizeof(anairiats_rec_57)) ; ats_selptrset_mac(anairiats_rec_57, tmp897, atslab_p0arg_loc, tmp898) ; ats_selptrset_mac(anairiats_rec_57, tmp897, atslab_p0arg_sym, tmp899) ; ats_selptrset_mac(anairiats_rec_57, tmp897, atslab_p0arg_ann, tmp900) ; return (tmp897) ; } /* end of [p0arg_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43447(line=1601, offs=27) -- 43585(line=1605, offs=6) */ ATSglobaldec() ats_ptr_type p0arg_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; __ats_lab_p0arg_make_some: tmp903 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp904 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp902 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp903, tmp904) ; tmp905 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp906 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp906, atslab_0, arg1) ; tmp901 = ATS_MALLOC(sizeof(anairiats_rec_57)) ; ats_selptrset_mac(anairiats_rec_57, tmp901, atslab_p0arg_loc, tmp902) ; ats_selptrset_mac(anairiats_rec_57, tmp901, atslab_p0arg_sym, tmp905) ; ats_selptrset_mac(anairiats_rec_57, tmp901, atslab_p0arg_ann, tmp906) ; return (tmp901) ; } /* end of [p0arg_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43638(line=1607, offs=24) -- 43654(line=1607, offs=40) */ ATSglobaldec() ats_ptr_type p0arglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp907) ; __ats_lab_p0arglst_nil: tmp907 = (ats_sum_ptr_type)0 ; return (tmp907) ; } /* end of [p0arglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43679(line=1608, offs=25) -- 43706(line=1608, offs=52) */ ATSglobaldec() ats_ptr_type p0arglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp908) ; __ats_lab_p0arglst_cons: tmp908 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp908, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp908, atslab_1, arg1) ; return (tmp908) ; } /* end of [p0arglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43749(line=1613, offs=11) -- 43896(line=1621, offs=6) */ ATSglobaldec() ats_ptr_type d0arg_var (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_ptr_type, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; __ats_lab_d0arg_var: tmp911 = p0arg_make_none (arg0) ; tmp912 = p0arglst_nil () ; tmp910 = p0arglst_cons (tmp911, tmp912) ; tmp913 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp914 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp914)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp914, atslab_0, tmp910) ; tmp909 = ATS_MALLOC(sizeof(anairiats_rec_58)) ; ats_selptrset_mac(anairiats_rec_58, tmp909, atslab_d0arg_loc, tmp913) ; ats_selptrset_mac(anairiats_rec_58, tmp909, atslab_d0arg_node, tmp914) ; return (tmp909) ; } /* end of [d0arg_var] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 43940(line=1624, offs=11) -- 44077(line=1627, offs=6) */ ATSglobaldec() ats_ptr_type d0arg_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_ptr_type, tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; __ats_lab_d0arg_dyn: tmp917 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp918 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp916 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp917, tmp918) ; tmp919 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp919)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp919, atslab_0, arg1) ; tmp915 = ATS_MALLOC(sizeof(anairiats_rec_58)) ; ats_selptrset_mac(anairiats_rec_58, tmp915, atslab_d0arg_loc, tmp916) ; ats_selptrset_mac(anairiats_rec_58, tmp915, atslab_d0arg_node, tmp919) ; return (tmp915) ; } /* end of [d0arg_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44100(line=1630, offs=12) -- 44254(line=1633, offs=6) */ ATSglobaldec() ats_ptr_type d0arg_dyn2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp920) ; ATSlocal (ats_ptr_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; ATSlocal (ats_ptr_type, tmp924) ; __ats_lab_d0arg_dyn2: tmp922 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp923 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp921 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp922, tmp923) ; tmp924 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp924)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp924, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp924, atslab_1, arg2) ; tmp920 = ATS_MALLOC(sizeof(anairiats_rec_58)) ; ats_selptrset_mac(anairiats_rec_58, tmp920, atslab_d0arg_loc, tmp921) ; ats_selptrset_mac(anairiats_rec_58, tmp920, atslab_d0arg_node, tmp924) ; return (tmp920) ; } /* end of [d0arg_dyn2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44276(line=1636, offs=11) -- 44413(line=1639, offs=6) */ ATSglobaldec() ats_ptr_type d0arg_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp925) ; ATSlocal (ats_ptr_type, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; ATSlocal (ats_ptr_type, tmp929) ; __ats_lab_d0arg_sta: tmp927 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp928 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp926 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp927, tmp928) ; tmp929 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp929)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp929, atslab_0, arg1) ; tmp925 = ATS_MALLOC(sizeof(anairiats_rec_58)) ; ats_selptrset_mac(anairiats_rec_58, tmp925, atslab_d0arg_loc, tmp926) ; ats_selptrset_mac(anairiats_rec_58, tmp925, atslab_d0arg_node, tmp929) ; return (tmp925) ; } /* end of [d0arg_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44438(line=1641, offs=24) -- 44449(line=1641, offs=35) */ ATSglobaldec() ats_ptr_type d0arglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp930) ; __ats_lab_d0arglst_nil: tmp930 = (ats_sum_ptr_type)0 ; return (tmp930) ; } /* end of [d0arglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44474(line=1642, offs=25) -- 44496(line=1642, offs=47) */ ATSglobaldec() ats_ptr_type d0arglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp931) ; __ats_lab_d0arglst_cons: tmp931 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp931, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp931, atslab_1, arg1) ; return (tmp931) ; } /* end of [d0arglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44541(line=1646, offs=23) -- 44560(line=1646, offs=42) */ ATSglobaldec() ats_ptr_type m0acarg_one (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp932) ; __ats_lab_m0acarg_one: tmp932 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp932)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp932, atslab_0, arg0) ; return (tmp932) ; } /* end of [m0acarg_one] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44584(line=1647, offs=23) -- 44619(line=1647, offs=58) */ ATSglobaldec() ats_ptr_type m0acarg_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp933) ; __ats_lab_m0acarg_lst: tmp933 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp933)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp933, atslab_0, arg1) ; return (tmp933) ; } /* end of [m0acarg_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44647(line=1649, offs=26) -- 44658(line=1649, offs=37) */ ATSglobaldec() ats_ptr_type m0acarglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp934) ; __ats_lab_m0acarglst_nil: tmp934 = (ats_sum_ptr_type)0 ; return (tmp934) ; } /* end of [m0acarglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44685(line=1650, offs=27) -- 44707(line=1650, offs=49) */ ATSglobaldec() ats_ptr_type m0acarglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp935) ; __ats_lab_m0acarglst_cons: tmp935 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp935, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp935, atslab_1, arg1) ; return (tmp935) ; } /* end of [m0acarglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44758(line=1654, offs=29) -- 44818(line=1655, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_mac (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp936) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_mac: do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp936 = ats_true_bool ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: __ats_lab_123_1: tmp936 = ats_false_bool ; break ; } while (0) ; return (tmp936) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_mac] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 44878(line=1658, offs=29) -- 44938(line=1659, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_sta (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp937) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_sta: do { /* branch: __ats_lab_124 */ __ats_lab_124_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp937 = ats_true_bool ; break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: __ats_lab_125_1: tmp937 = ats_false_bool ; break ; } while (0) ; return (tmp937) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__dcstextdef_is_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45016(line=1664, offs=26) -- 45032(line=1664, offs=42) */ ATSglobaldec() ats_ptr_type extnamopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp938) ; __ats_lab_extnamopt_none: tmp938 = atspre_stropt_none ; return (tmp938) ; } /* end of [extnamopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45058(line=1665, offs=26) -- 45247(line=1673, offs=4) */ ATSglobaldec() ats_ptr_type extnamopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; __ats_lab_extnamopt_some: tmp940 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp939 = ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, tmp940)) ; return (tmp939) ; } /* end of [extnamopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45302(line=1676, offs=3) -- 45587(line=1687, offs=6) */ ATSglobaldec() ats_ptr_type d0cstdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; ATSlocal (ats_ptr_type, tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; ATSlocal (ats_ptr_type, tmp946) ; __ats_lab_d0cstdec_make: tmp942 = ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__the_filename_get () ; tmp944 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp945 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg3), atslab_s0exp_loc) ; tmp943 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp944, tmp945) ; tmp946 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp941 = ATS_MALLOC(sizeof(anairiats_rec_59)) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_fil, tmp942) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_loc, tmp943) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_sym, tmp946) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_arg, arg1) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_eff, arg2) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_res, arg3) ; ats_selptrset_mac(anairiats_rec_59, tmp941, atslab_d0cstdec_extdef, arg4) ; return (tmp941) ; } /* end of [d0cstdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45641(line=1689, offs=27) -- 45652(line=1689, offs=38) */ ATSglobaldec() ats_ptr_type d0cstdeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp947) ; __ats_lab_d0cstdeclst_nil: tmp947 = (ats_sum_ptr_type)0 ; return (tmp947) ; } /* end of [d0cstdeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45680(line=1690, offs=28) -- 45702(line=1690, offs=50) */ ATSglobaldec() ats_ptr_type d0cstdeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp948) ; __ats_lab_d0cstdeclst_cons: tmp948 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp948, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp948, atslab_1, arg1) ; return (tmp948) ; } /* end of [d0cstdeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45748(line=1694, offs=24) -- 45767(line=1694, offs=43) */ ATSglobaldec() ats_ptr_type s0vararg_one () { /* local vardec */ ATSlocal (ats_ptr_type, tmp949) ; __ats_lab_s0vararg_one: tmp949 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGone_0) ; return (tmp949) ; } /* end of [s0vararg_one] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45791(line=1695, offs=24) -- 45810(line=1695, offs=43) */ ATSglobaldec() ats_ptr_type s0vararg_all () { /* local vardec */ ATSlocal (ats_ptr_type, tmp950) ; __ats_lab_s0vararg_all: tmp950 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0VARARGall_1) ; return (tmp950) ; } /* end of [s0vararg_all] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45834(line=1696, offs=24) -- 45859(line=1696, offs=49) */ ATSglobaldec() ats_ptr_type s0vararg_seq (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp951) ; __ats_lab_s0vararg_seq: tmp951 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp951)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp951, atslab_0, arg0) ; return (tmp951) ; } /* end of [s0vararg_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 45932(line=1704, offs=20) -- 46060(line=1707, offs=6) */ ATSglobaldec() ats_ptr_type p0at_ann (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; __ats_lab_p0at_ann: tmp954 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp955 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp953 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp954, tmp955) ; tmp956 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp956)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp956, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp956, atslab_1, arg1) ; tmp952 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp952, atslab_p0at_loc, tmp953) ; ats_selptrset_mac(anairiats_rec_60, tmp952, atslab_p0at_node, tmp956) ; return (tmp952) ; } /* end of [p0at_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46065(line=1709, offs=4) -- 46243(line=1712, offs=6) */ ATSstaticdec() ats_ptr_type p0at_app_336 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_ptr_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; __ats_lab_p0at_app_336: tmp959 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp960 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg1), atslab_p0at_loc) ; tmp958 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp959, tmp960) ; tmp961 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp961)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp961, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp961, atslab_1, arg1) ; tmp957 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp957, atslab_p0at_loc, tmp958) ; ats_selptrset_mac(anairiats_rec_60, tmp957, atslab_p0at_node, tmp961) ; return (tmp957) ; } /* end of [p0at_app_336] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46265(line=1714, offs=21) -- 46467(line=1720, offs=24) */ ATSglobaldec() ats_ptr_type p0at_apps (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; __ats_lab_p0at_apps: do { /* branch: __ats_lab_126 */ __ats_lab_126_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp963 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp964 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp965 = p0at_app_336 (arg0, tmp963) ; arg0 = tmp965 ; arg1 = tmp964 ; goto __ats_lab_p0at_apps ; // tail call break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: tmp962 = arg0 ; break ; } while (0) ; return (tmp962) ; } /* end of [p0at_apps] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46487(line=1722, offs=19) -- 46621(line=1725, offs=6) */ ATSglobaldec() ats_ptr_type p0at_as (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_ptr_type, tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; __ats_lab_p0at_as: tmp968 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp969 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg1), atslab_p0at_loc) ; tmp967 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp968, tmp969) ; tmp970 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp970)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp970, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp970, atslab_1, arg1) ; tmp966 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp966, atslab_p0at_loc, tmp967) ; ats_selptrset_mac(anairiats_rec_60, tmp966, atslab_p0at_node, tmp970) ; return (tmp966) ; } /* end of [p0at_as] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46643(line=1727, offs=21) -- 46709(line=1729, offs=2) */ ATSglobaldec() ats_ptr_type p0at_char (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_char_type, tmp974) ; __ats_lab_p0at_char: tmp972 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_loc) ; tmp974 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_val) ; tmp973 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp973)->tag = 3 ; ats_selptrset_mac(anairiats_sum_16, tmp973, atslab_0, tmp974) ; tmp971 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp971, atslab_p0at_loc, tmp972) ; ats_selptrset_mac(anairiats_rec_60, tmp971, atslab_p0at_node, tmp973) ; return (tmp971) ; } /* end of [p0at_char] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46732(line=1731, offs=22) -- 46867(line=1734, offs=6) */ ATSglobaldec() ats_ptr_type p0at_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp975) ; ATSlocal (ats_ptr_type, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; __ats_lab_p0at_exist: tmp977 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp978 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp976 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp977, tmp978) ; tmp979 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp979)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp979, atslab_0, arg1) ; tmp975 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp975, atslab_p0at_loc, tmp976) ; ats_selptrset_mac(anairiats_rec_60, tmp975, atslab_p0at_node, tmp979) ; return (tmp975) ; } /* end of [p0at_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46890(line=1736, offs=22) -- 46959(line=1738, offs=2) */ ATSglobaldec() ats_ptr_type p0at_float (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; __ats_lab_p0at_float: tmp981 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_loc) ; tmp983 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_val) ; tmp982 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp982)->tag = 5 ; ats_selptrset_mac(anairiats_sum_0, tmp982, atslab_0, tmp983) ; tmp980 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp980, atslab_p0at_loc, tmp981) ; ats_selptrset_mac(anairiats_rec_60, tmp980, atslab_p0at_node, tmp982) ; return (tmp980) ; } /* end of [p0at_float] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 46981(line=1740, offs=21) -- 47110(line=1743, offs=6) */ ATSglobaldec() ats_ptr_type p0at_free (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; ATSlocal (ats_ptr_type, tmp988) ; __ats_lab_p0at_free: tmp986 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp987 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg1), atslab_p0at_loc) ; tmp985 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp986, tmp987) ; tmp988 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp988)->tag = 6 ; ats_selptrset_mac(anairiats_sum_0, tmp988, atslab_0, arg1) ; tmp984 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp984, atslab_p0at_loc, tmp985) ; ats_selptrset_mac(anairiats_rec_60, tmp984, atslab_p0at_node, tmp988) ; return (tmp984) ; } /* end of [p0at_free] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47131(line=1745, offs=20) -- 47197(line=1747, offs=2) */ ATSglobaldec() ats_ptr_type p0at_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; ATSlocal (ats_ptr_type, tmp992) ; __ats_lab_p0at_ide: tmp990 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp992 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp991 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp991)->tag = 7 ; ats_selptrset_mac(anairiats_sum_0, tmp991, atslab_0, tmp992) ; tmp989 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp989, atslab_p0at_loc, tmp990) ; ats_selptrset_mac(anairiats_rec_60, tmp989, atslab_p0at_node, tmp991) ; return (tmp989) ; } /* end of [p0at_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47218(line=1749, offs=20) -- 47290(line=1752, offs=2) */ ATSglobaldec() ats_ptr_type p0at_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; __ats_lab_p0at_int: tmp994 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp996 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp995 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp995)->tag = 8 ; ats_selptrset_mac(anairiats_sum_0, tmp995, atslab_0, tmp996) ; tmp993 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp993, atslab_p0at_loc, tmp994) ; ats_selptrset_mac(anairiats_rec_60, tmp993, atslab_p0at_node, tmp995) ; return (tmp993) ; } /* end of [p0at_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47312(line=1754, offs=21) -- 47450(line=1757, offs=6) */ ATSglobaldec() ats_ptr_type p0at_list (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; __ats_lab_p0at_list: tmp999 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1000 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp998 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp999, tmp1000) ; tmp1001 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1001)->tag = 9 ; ats_selptrset_mac(anairiats_sum_0, tmp1001, atslab_0, arg1) ; tmp997 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp997, atslab_p0at_loc, tmp998) ; ats_selptrset_mac(anairiats_rec_60, tmp997, atslab_p0at_node, tmp1001) ; return (tmp997) ; } /* end of [p0at_list] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47473(line=1759, offs=22) -- 47628(line=1762, offs=6) */ ATSglobaldec() ats_ptr_type p0at_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_ptr_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; __ats_lab_p0at_list2: tmp1004 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1005 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1003 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1004, tmp1005) ; tmp1006 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1006)->tag = 10 ; ats_selptrset_mac(anairiats_sum_15, tmp1006, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1006, atslab_1, arg2) ; tmp1002 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1002, atslab_p0at_loc, tmp1003) ; ats_selptrset_mac(anairiats_rec_60, tmp1002, atslab_p0at_node, tmp1006) ; return (tmp1002) ; } /* end of [p0at_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47649(line=1764, offs=20) -- 47786(line=1767, offs=6) */ ATSglobaldec() ats_ptr_type p0at_lst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; ATSlocal (ats_ptr_type, tmp1011) ; __ats_lab_p0at_lst: tmp1009 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1010 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1008 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1009, tmp1010) ; tmp1011 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1011)->tag = 11 ; ats_selptrset_mac(anairiats_sum_0, tmp1011, atslab_0, arg1) ; tmp1007 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1007, atslab_p0at_loc, tmp1008) ; ats_selptrset_mac(anairiats_rec_60, tmp1007, atslab_p0at_node, tmp1011) ; return (tmp1007) ; } /* end of [p0at_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47809(line=1769, offs=22) -- 47935(line=1773, offs=6) */ ATSglobaldec() ats_ptr_type p0at_opide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; ATSlocal (ats_ptr_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; __ats_lab_p0at_opide: tmp1014 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1015 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1013 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1014, tmp1015) ; tmp1017 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp1016 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1016)->tag = 12 ; ats_selptrset_mac(anairiats_sum_0, tmp1016, atslab_0, tmp1017) ; tmp1012 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1012, atslab_p0at_loc, tmp1013) ; ats_selptrset_mac(anairiats_rec_60, tmp1012, atslab_p0at_node, tmp1016) ; return (tmp1012) ; } /* end of [p0at_opide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 47979(line=1775, offs=20) -- 48112(line=1778, offs=6) */ ATSglobaldec() ats_ptr_type p0at_qid (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1018) ; ATSlocal (ats_ptr_type, tmp1019) ; ATSlocal (ats_ptr_type, tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; ATSlocal (ats_ptr_type, tmp1023) ; __ats_lab_p0at_qid: tmp1020 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_d0ynq_loc) ; tmp1021 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1019 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1020, tmp1021) ; tmp1023 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp1022 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1022)->tag = 13 ; ats_selptrset_mac(anairiats_sum_15, tmp1022, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1022, atslab_1, tmp1023) ; tmp1018 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1018, atslab_p0at_loc, tmp1019) ; ats_selptrset_mac(anairiats_rec_60, tmp1018, atslab_p0at_node, tmp1022) ; return (tmp1018) ; } /* end of [p0at_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48133(line=1780, offs=20) -- 48284(line=1783, offs=6) */ ATSglobaldec() ats_ptr_type p0at_rec (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; __ats_lab_p0at_rec: tmp1026 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1027 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1025 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1026, tmp1027) ; tmp1028 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1028)->tag = 14 ; ats_selptrset_mac(anairiats_sum_24, tmp1028, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp1028, atslab_1, arg2) ; tmp1024 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1024, atslab_p0at_loc, tmp1025) ; ats_selptrset_mac(anairiats_rec_60, tmp1024, atslab_p0at_node, tmp1028) ; return (tmp1024) ; } /* end of [p0at_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48305(line=1785, offs=20) -- 48431(line=1788, offs=6) */ ATSglobaldec() ats_ptr_type p0at_ref (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; ATSlocal (ats_ptr_type, tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; __ats_lab_p0at_ref: tmp1031 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1032 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1030 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1031, tmp1032) ; tmp1033 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1033)->tag = 15 ; ats_selptrset_mac(anairiats_sum_0, tmp1033, atslab_0, arg1) ; tmp1029 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1029, atslab_p0at_loc, tmp1030) ; ats_selptrset_mac(anairiats_rec_60, tmp1029, atslab_p0at_node, tmp1033) ; return (tmp1029) ; } /* end of [p0at_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48454(line=1790, offs=22) -- 48594(line=1793, offs=6) */ ATSglobaldec() ats_ptr_type p0at_refas (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (ats_ptr_type, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; __ats_lab_p0at_refas: tmp1036 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1037 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg2), atslab_p0at_loc) ; tmp1035 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1036, tmp1037) ; tmp1038 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1038)->tag = 16 ; ats_selptrset_mac(anairiats_sum_15, tmp1038, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1038, atslab_1, arg2) ; tmp1034 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1034, atslab_p0at_loc, tmp1035) ; ats_selptrset_mac(anairiats_rec_60, tmp1034, atslab_p0at_node, tmp1038) ; return (tmp1034) ; } /* end of [p0at_refas] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48618(line=1795, offs=23) -- 48690(line=1797, offs=2) */ ATSglobaldec() ats_ptr_type p0at_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1039) ; ATSlocal (ats_ptr_type, tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_ptr_type, tmp1042) ; __ats_lab_p0at_string: tmp1040 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1042 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1041 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1041)->tag = 17 ; ats_selptrset_mac(anairiats_sum_0, tmp1041, atslab_0, tmp1042) ; tmp1039 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1039, atslab_p0at_loc, tmp1040) ; ats_selptrset_mac(anairiats_rec_60, tmp1039, atslab_p0at_node, tmp1041) ; return (tmp1039) ; } /* end of [p0at_string] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48715(line=1799, offs=24) -- 48852(line=1802, offs=6) */ ATSglobaldec() ats_ptr_type p0at_svararg (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1043) ; ATSlocal (ats_ptr_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; __ats_lab_p0at_svararg: tmp1045 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1046 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1044 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1045, tmp1046) ; tmp1047 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1047)->tag = 18 ; ats_selptrset_mac(anairiats_sum_0, tmp1047, atslab_0, arg1) ; tmp1043 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1043, atslab_p0at_loc, tmp1044) ; ats_selptrset_mac(anairiats_rec_60, tmp1043, atslab_p0at_node, tmp1047) ; return (tmp1043) ; } /* end of [p0at_svararg] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 48873(line=1804, offs=20) -- 49022(line=1807, offs=6) */ ATSglobaldec() ats_ptr_type p0at_tup (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; ATSlocal (ats_ptr_type, tmp1052) ; __ats_lab_p0at_tup: tmp1050 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1051 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1049 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1050, tmp1051) ; tmp1052 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1052)->tag = 19 ; ats_selptrset_mac(anairiats_sum_24, tmp1052, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp1052, atslab_1, arg2) ; tmp1048 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1048, atslab_p0at_loc, tmp1049) ; ats_selptrset_mac(anairiats_rec_60, tmp1048, atslab_p0at_node, tmp1052) ; return (tmp1048) ; } /* end of [p0at_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49044(line=1809, offs=21) -- 49210(line=1812, offs=6) */ ATSglobaldec() ats_ptr_type p0at_tup2 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1053) ; ATSlocal (ats_ptr_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; ATSlocal (ats_ptr_type, tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; __ats_lab_p0at_tup2: tmp1055 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1056 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1054 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1055, tmp1056) ; tmp1057 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1057)->tag = 20 ; ats_selptrset_mac(anairiats_sum_40, tmp1057, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp1057, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_40, tmp1057, atslab_2, arg3) ; tmp1053 = ATS_MALLOC(sizeof(anairiats_rec_60)) ; ats_selptrset_mac(anairiats_rec_60, tmp1053, atslab_p0at_loc, tmp1054) ; ats_selptrset_mac(anairiats_rec_60, tmp1053, atslab_p0at_node, tmp1057) ; return (tmp1053) ; } /* end of [p0at_tup2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49238(line=1816, offs=23) -- 49249(line=1816, offs=34) */ ATSglobaldec() ats_ptr_type p0atlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1058) ; __ats_lab_p0atlst_nil: tmp1058 = (ats_sum_ptr_type)0 ; return (tmp1058) ; } /* end of [p0atlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49273(line=1817, offs=24) -- 49295(line=1817, offs=46) */ ATSglobaldec() ats_ptr_type p0atlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1059) ; __ats_lab_p0atlst_cons: tmp1059 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1059, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1059, atslab_1, arg1) ; return (tmp1059) ; } /* end of [p0atlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49320(line=1819, offs=24) -- 49332(line=1819, offs=36) */ ATSglobaldec() ats_ptr_type p0atopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1060) ; __ats_lab_p0atopt_none: tmp1060 = (ats_sum_ptr_type)0 ; return (tmp1060) ; } /* end of [p0atopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49356(line=1820, offs=24) -- 49372(line=1820, offs=40) */ ATSglobaldec() ats_ptr_type p0atopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1061) ; __ats_lab_p0atopt_some: tmp1061 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1061, atslab_0, arg0) ; return (tmp1061) ; } /* end of [p0atopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49399(line=1822, offs=26) -- 49420(line=1822, offs=47) */ ATSglobaldec() ats_ptr_type labp0atlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1062) ; __ats_lab_labp0atlst_nil: tmp1062 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTnil_0) ; return (tmp1062) ; } /* end of [labp0atlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49446(line=1823, offs=26) -- 49467(line=1823, offs=47) */ ATSglobaldec() ats_ptr_type labp0atlst_dot () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1063) ; __ats_lab_labp0atlst_dot: tmp1063 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__LABP0ATLSTdot_1) ; return (tmp1063) ; } /* end of [labp0atlst_dot] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49494(line=1824, offs=27) -- 49534(line=1824, offs=67) */ ATSglobaldec() ats_ptr_type labp0atlst_cons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1064) ; __ats_lab_labp0atlst_cons: tmp1064 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1064)->tag = 2 ; ats_selptrset_mac(anairiats_sum_38, tmp1064, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1064, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1064, atslab_2, arg2) ; return (tmp1064) ; } /* end of [labp0atlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49578(line=1828, offs=22) -- 49718(line=1831, offs=6) */ ATSglobaldec() ats_ptr_type f0arg_sta1 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; ATSlocal (ats_ptr_type, tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; __ats_lab_f0arg_sta1: tmp1067 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1068 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1066 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1067, tmp1068) ; tmp1069 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1069)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1069, atslab_0, arg1) ; tmp1065 = ATS_MALLOC(sizeof(anairiats_rec_61)) ; ats_selptrset_mac(anairiats_rec_61, tmp1065, atslab_f0arg_loc, tmp1066) ; ats_selptrset_mac(anairiats_rec_61, tmp1065, atslab_f0arg_node, tmp1069) ; return (tmp1065) ; } /* end of [f0arg_sta1] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49741(line=1833, offs=22) -- 49881(line=1836, offs=6) */ ATSglobaldec() ats_ptr_type f0arg_sta2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; __ats_lab_f0arg_sta2: tmp1072 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1073 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1071 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1072, tmp1073) ; tmp1074 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1074)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp1074, atslab_0, arg1) ; tmp1070 = ATS_MALLOC(sizeof(anairiats_rec_61)) ; ats_selptrset_mac(anairiats_rec_61, tmp1070, atslab_f0arg_loc, tmp1071) ; ats_selptrset_mac(anairiats_rec_61, tmp1070, atslab_f0arg_node, tmp1074) ; return (tmp1070) ; } /* end of [f0arg_sta2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49903(line=1838, offs=21) -- 49967(line=1840, offs=2) */ ATSglobaldec() ats_ptr_type f0arg_dyn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_ptr_type, tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; __ats_lab_f0arg_dyn: tmp1076 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1077 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1077)->tag = 0 ; ats_selptrset_mac(anairiats_sum_0, tmp1077, atslab_0, arg0) ; tmp1075 = ATS_MALLOC(sizeof(anairiats_rec_61)) ; ats_selptrset_mac(anairiats_rec_61, tmp1075, atslab_f0arg_loc, tmp1076) ; ats_selptrset_mac(anairiats_rec_61, tmp1075, atslab_f0arg_node, tmp1077) ; return (tmp1075) ; } /* end of [f0arg_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 49994(line=1842, offs=26) -- 50068(line=1844, offs=2) */ ATSglobaldec() ats_ptr_type f0arg_met_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; __ats_lab_f0arg_met_none: tmp1079 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1081 = s0explst_nil () ; tmp1080 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1080)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp1080, atslab_0, tmp1081) ; tmp1078 = ATS_MALLOC(sizeof(anairiats_rec_61)) ; ats_selptrset_mac(anairiats_rec_61, tmp1078, atslab_f0arg_loc, tmp1079) ; ats_selptrset_mac(anairiats_rec_61, tmp1078, atslab_f0arg_node, tmp1080) ; return (tmp1078) ; } /* end of [f0arg_met_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50095(line=1846, offs=26) -- 50235(line=1849, offs=6) */ ATSglobaldec() ats_ptr_type f0arg_met_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; __ats_lab_f0arg_met_some: tmp1084 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1085 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1083 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1084, tmp1085) ; tmp1086 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1086)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp1086, atslab_0, arg1) ; tmp1082 = ATS_MALLOC(sizeof(anairiats_rec_61)) ; ats_selptrset_mac(anairiats_rec_61, tmp1082, atslab_f0arg_loc, tmp1083) ; ats_selptrset_mac(anairiats_rec_61, tmp1082, atslab_f0arg_node, tmp1086) ; return (tmp1082) ; } /* end of [f0arg_met_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50260(line=1851, offs=24) -- 50271(line=1851, offs=35) */ ATSglobaldec() ats_ptr_type f0arglst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1087) ; __ats_lab_f0arglst_nil: tmp1087 = (ats_sum_ptr_type)0 ; return (tmp1087) ; } /* end of [f0arglst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50295(line=1852, offs=24) -- 50317(line=1852, offs=46) */ ATSglobaldec() ats_ptr_type f0arglst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1088) ; __ats_lab_f0arglst_cons: tmp1088 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1088, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1088, atslab_1, arg1) ; return (tmp1088) ; } /* end of [f0arglst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50362(line=1856, offs=23) -- 50419(line=1858, offs=2) */ ATSglobaldec() ats_ptr_type s0elop_make (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; __ats_lab_s0elop_make: tmp1090 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1089 = ATS_MALLOC(sizeof(anairiats_rec_62)) ; ats_selptrset_mac(anairiats_rec_62, tmp1089, atslab_s0elop_loc, tmp1090) ; ats_selptrset_mac(anairiats_rec_62, tmp1089, atslab_s0elop_knd, arg0) ; return (tmp1089) ; } /* end of [s0elop_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50465(line=1862, offs=24) -- 50484(line=1862, offs=43) */ ATSglobaldec() ats_ptr_type s0exparg_one () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1091) ; __ats_lab_s0exparg_one: tmp1091 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGone_0) ; return (tmp1091) ; } /* end of [s0exparg_one] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50508(line=1863, offs=24) -- 50527(line=1863, offs=43) */ ATSglobaldec() ats_ptr_type s0exparg_all () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1092) ; __ats_lab_s0exparg_all: tmp1092 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__S0EXPARGall_1) ; return (tmp1092) ; } /* end of [s0exparg_all] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50551(line=1864, offs=24) -- 50576(line=1864, offs=49) */ ATSglobaldec() ats_ptr_type s0exparg_seq (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1093) ; __ats_lab_s0exparg_seq: tmp1093 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1093)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp1093, atslab_0, arg0) ; return (tmp1093) ; } /* end of [s0exparg_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50619(line=1869, offs=11) -- 50750(line=1874, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_ann (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; ATSlocal (ats_ptr_type, tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; __ats_lab_d0exp_ann: tmp1096 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1097 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp1095 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1096, tmp1097) ; tmp1098 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1098)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1098, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1098, atslab_1, arg1) ; tmp1094 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1094, atslab_d0exp_loc, tmp1095) ; ats_selptrset_mac(anairiats_rec_63, tmp1094, atslab_d0exp_node, tmp1098) ; return (tmp1094) ; } /* end of [d0exp_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 50777(line=1876, offs=4) -- 50968(line=1883, offs=6) */ ATSstaticdec() ats_ptr_type d0exp_app_376 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; ATSlocal (ats_ptr_type, tmp1102) ; ATSlocal (ats_ptr_type, tmp1103) ; __ats_lab_d0exp_app_376: tmp1101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1100 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1101, tmp1102) ; tmp1103 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1103)->tag = 1 ; ats_selptrset_mac(anairiats_sum_15, tmp1103, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1103, atslab_1, arg1) ; tmp1099 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1099, atslab_d0exp_loc, tmp1100) ; ats_selptrset_mac(anairiats_rec_63, tmp1099, atslab_d0exp_node, tmp1103) ; return (tmp1099) ; } /* end of [d0exp_app_376] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 51015(line=1887, offs=3) -- 51232(line=1894, offs=22) */ ATSglobaldec() ats_ptr_type d0exp_apps (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1104) ; ATSlocal (ats_ptr_type, tmp1105) ; ATSlocal (ats_ptr_type, tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; __ats_lab_d0exp_apps: do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp1105 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1106 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1107 = d0exp_app_376 (arg0, tmp1105) ; arg0 = tmp1107 ; arg1 = tmp1106 ; goto __ats_lab_d0exp_apps ; // tail call break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp1104 = arg0 ; break ; } while (0) ; return (tmp1104) ; } /* end of [d0exp_apps] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 51318(line=1900, offs=15) -- 52352(line=1924, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_arrinit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; ATSlocal (ats_ptr_type, tmp1110) ; ATSlocal (ats_ptr_type, tmp1111) ; // ATSlocal_void (tmp1112) ; ATSlocal (ats_ptr_type, tmp1113) ; // ATSlocal_void (tmp1114) ; // ATSlocal_void (tmp1115) ; // ATSlocal_void (tmp1116) ; ATSlocal (ats_ptr_type, tmp1117) ; __ats_lab_d0exp_arrinit: tmp1110 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1111 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1109 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1110, tmp1111) ; do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_133_0 ; } __ats_lab_130_1: do { /* branch: __ats_lab_131 */ __ats_lab_131_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } tmp1113 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; if (tmp1113 == (ats_sum_ptr_type)0) { goto __ats_lab_132_0 ; } __ats_lab_131_1: /* tmp1114 = */ prerr_loc_error0_0 (tmp1109) ; /* tmp1115 = */ atspre_prerr_string (ATSstrcst(": the syntax for array initialization is incorrect.")) ; /* tmp1116 = */ atspre_prerr_newline () ; /* tmp1112 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: __ats_lab_132_1: break ; } while (0) ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_133_1: break ; } while (0) ; tmp1117 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1117)->tag = 2 ; ats_selptrset_mac(anairiats_sum_38, tmp1117, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1117, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_38, tmp1117, atslab_2, arg3) ; tmp1108 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1108, atslab_d0exp_loc, tmp1109) ; ats_selptrset_mac(anairiats_rec_63, tmp1108, atslab_d0exp_node, tmp1117) ; return (tmp1108) ; } /* end of [d0exp_arrinit] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 52432(line=1930, offs=3) -- 52526(line=1931, offs=59) */ ATSglobaldec() ats_ptr_type d0exp_arrinit_none (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; __ats_lab_d0exp_arrinit_none: tmp1119 = (ats_sum_ptr_type)0 ; tmp1118 = d0exp_arrinit (arg0, arg1, tmp1119, arg2, arg3) ; return (tmp1118) ; } /* end of [d0exp_arrinit_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 52590(line=1936, offs=3) -- 52698(line=1937, offs=64) */ ATSglobaldec() ats_ptr_type d0exp_arrinit_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1120) ; ATSlocal (ats_ptr_type, tmp1121) ; __ats_lab_d0exp_arrinit_some: tmp1121 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1121, atslab_0, arg2) ; tmp1120 = d0exp_arrinit (arg0, arg1, tmp1121, arg3, arg4) ; return (tmp1120) ; } /* end of [d0exp_arrinit_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 52775(line=1943, offs=14) -- 53070(line=1953, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_arrpsz (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1122) ; ATSlocal (ats_ptr_type, tmp1123) ; ATSlocal (ats_ptr_type, tmp1124) ; ATSlocal (ats_ptr_type, tmp1125) ; ATSlocal (ats_ptr_type, tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; ATSlocal (ats_ptr_type, tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; __ats_lab_d0exp_arrpsz: tmp1124 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1125 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1123 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1124, tmp1125) ; do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } tmp1127 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; if (tmp1127 != (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp1128 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1126 = tmp1128 ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: __ats_lab_135_1: tmp1126 = d0exp_list (arg2, arg3, arg4) ; break ; } while (0) ; tmp1129 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1129)->tag = 3 ; ats_selptrset_mac(anairiats_sum_15, tmp1129, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1129, atslab_1, tmp1126) ; tmp1122 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1122, atslab_d0exp_loc, tmp1123) ; ats_selptrset_mac(anairiats_rec_63, tmp1122, atslab_d0exp_node, tmp1129) ; return (tmp1122) ; } /* end of [d0exp_arrpsz] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 53141(line=1958, offs=14) -- 53324(line=1964, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_arrsub (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1130) ; ATSlocal (ats_ptr_type, tmp1131) ; ATSlocal (ats_ptr_type, tmp1132) ; ATSlocal (ats_ptr_type, tmp1133) ; ATSlocal (ats_ptr_type, tmp1134) ; ATSlocal (ats_ptr_type, tmp1135) ; __ats_lab_d0exp_arrsub: tmp1131 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_loc) ; tmp1133 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_31, arg0), atslab_arrqi0de_loc) ; tmp1132 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1133, tmp1131) ; tmp1135 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_ind) ; tmp1134 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1134)->tag = 4 ; ats_selptrset_mac(anairiats_sum_38, tmp1134, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1134, atslab_1, tmp1131) ; ats_selptrset_mac(anairiats_sum_38, tmp1134, atslab_2, tmp1135) ; tmp1130 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1130, atslab_d0exp_loc, tmp1132) ; ats_selptrset_mac(anairiats_rec_63, tmp1130, atslab_d0exp_node, tmp1134) ; return (tmp1130) ; } /* end of [d0exp_arrsub] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 53393(line=1969, offs=12) -- 53461(line=1971, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_char (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1136) ; ATSlocal (ats_ptr_type, tmp1137) ; ATSlocal (ats_ptr_type, tmp1138) ; ATSlocal (ats_char_type, tmp1139) ; __ats_lab_d0exp_char: tmp1137 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_loc) ; tmp1139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_c0har_val) ; tmp1138 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp1138)->tag = 6 ; ats_selptrset_mac(anairiats_sum_16, tmp1138, atslab_0, tmp1139) ; tmp1136 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1136, atslab_d0exp_loc, tmp1137) ; ats_selptrset_mac(anairiats_rec_63, tmp1136, atslab_d0exp_node, tmp1138) ; return (tmp1136) ; } /* end of [d0exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 53543(line=1975, offs=7) -- 53740(line=1980, offs=57) */ ATSstaticdec() ats_ptr_type aux_loc_385 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1141) ; ATSlocal (ats_ptr_type, tmp1142) ; ATSlocal (ats_ptr_type, tmp1143) ; ATSlocal (ats_ptr_type, tmp1144) ; ATSlocal (ats_ptr_type, tmp1145) ; __ats_lab_aux_loc_385: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp1142 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1143 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1142 ; arg2 = tmp1143 ; goto __ats_lab_aux_loc_385 ; // tail call break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_137_1: tmp1144 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1145 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_65, arg1), atslab_c0lau_loc) ; tmp1141 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1144, tmp1145) ; break ; } while (0) ; return (tmp1141) ; } /* end of [aux_loc_385] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 53509(line=1974, offs=14) -- 54015(line=1988, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_caseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1140) ; ATSlocal (ats_ptr_type, tmp1146) ; ATSlocal (ats_ptr_type, tmp1147) ; ATSlocal (ats_ptr_type, tmp1148) ; ATSlocal (ats_ptr_type, tmp1149) ; ATSlocal (ats_ptr_type, tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; ATSlocal (ats_ptr_type, tmp1152) ; __ats_lab_d0exp_caseof: tmp1146 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_66, arg0), atslab_casehead_tok) ; do { /* branch: __ats_lab_138 */ __ats_lab_138_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp1148 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1149 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1147 = aux_loc_385 (tmp1146, tmp1148, tmp1149) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: tmp1150 = ats_selsin_mac(tmp1146, atslab_t0kn_loc) ; tmp1151 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1147 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1150, tmp1151) ; break ; } while (0) ; tmp1152 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1152)->tag = 5 ; ats_selptrset_mac(anairiats_sum_38, tmp1152, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1152, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1152, atslab_2, arg3) ; tmp1140 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1140, atslab_d0exp_loc, tmp1147) ; ats_selptrset_mac(anairiats_rec_63, tmp1140, atslab_d0exp_node, tmp1152) ; return (tmp1140) ; } /* end of [d0exp_caseof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54064(line=1991, offs=13) -- 54150(line=1993, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_crypt (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1153) ; ATSlocal (ats_ptr_type, tmp1154) ; ATSlocal (ats_ptr_type, tmp1155) ; __ats_lab_d0exp_crypt: tmp1154 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1155 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp1155)->tag = 8 ; ats_selptrset_mac(anairiats_sum_11, tmp1155, atslab_0, arg0) ; tmp1153 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1153, atslab_d0exp_loc, tmp1154) ; ats_selptrset_mac(anairiats_rec_63, tmp1153, atslab_d0exp_node, tmp1155) ; return (tmp1153) ; } /* end of [d0exp_crypt] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54201(line=1997, offs=3) -- 54375(line=2003, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_decseq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1156) ; ATSlocal (ats_ptr_type, tmp1157) ; ATSlocal (ats_ptr_type, tmp1158) ; ATSlocal (ats_ptr_type, tmp1159) ; ATSlocal (ats_ptr_type, tmp1160) ; __ats_lab_d0exp_decseq: tmp1158 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1159 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1157 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1158, tmp1159) ; tmp1160 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1160)->tag = 9 ; ats_selptrset_mac(anairiats_sum_0, tmp1160, atslab_0, arg1) ; tmp1156 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1156, atslab_d0exp_loc, tmp1157) ; ats_selptrset_mac(anairiats_rec_63, tmp1156, atslab_d0exp_node, tmp1160) ; return (tmp1156) ; } /* end of [d0exp_decseq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54424(line=2006, offs=13) -- 54503(line=2008, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_delay (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1161) ; ATSlocal (ats_ptr_type, tmp1162) ; ATSlocal (ats_ptr_type, tmp1163) ; __ats_lab_d0exp_delay: tmp1162 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1163 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp1163)->tag = 10 ; ats_selptrset_mac(anairiats_sum_11, tmp1163, atslab_0, arg0) ; tmp1161 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1161, atslab_d0exp_loc, tmp1162) ; ats_selptrset_mac(anairiats_rec_63, tmp1161, atslab_d0exp_node, tmp1163) ; return (tmp1161) ; } /* end of [d0exp_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54553(line=2011, offs=15) -- 54626(line=2013, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_dynload (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1164) ; ATSlocal (ats_ptr_type, tmp1165) ; ATSlocal (ats_ptr_type, tmp1166) ; __ats_lab_d0exp_dynload: tmp1165 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1166 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Edynload_11) ; tmp1164 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1164, atslab_d0exp_loc, tmp1165) ; ats_selptrset_mac(anairiats_rec_63, tmp1164, atslab_d0exp_node, tmp1166) ; return (tmp1164) ; } /* end of [d0exp_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54676(line=2016, offs=13) -- 54730(line=2018, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1167) ; ATSlocal (ats_ptr_type, tmp1168) ; __ats_lab_d0exp_empty: tmp1168 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eempty_13) ; tmp1167 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1167, atslab_d0exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_63, tmp1167, atslab_d0exp_node, tmp1168) ; return (tmp1167) ; } /* end of [d0exp_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 54780(line=2022, offs=3) -- 54996(line=2027, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1169) ; ATSlocal (ats_ptr_type, tmp1170) ; ATSlocal (ats_ptr_type, tmp1171) ; ATSlocal (ats_ptr_type, tmp1172) ; ATSlocal (ats_ptr_type, tmp1173) ; ATSlocal (ats_ptr_type, tmp1174) ; ATSlocal (ats_ptr_type, tmp1175) ; ATSlocal (ats_ptr_type, tmp1176) ; __ats_lab_d0exp_exist: tmp1171 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1172 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1170 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1171, tmp1172) ; tmp1174 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1175 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1173 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1174, tmp1175) ; tmp1176 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1176)->tag = 14 ; ats_selptrset_mac(anairiats_sum_38, tmp1176, atslab_0, tmp1173) ; ats_selptrset_mac(anairiats_sum_38, tmp1176, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1176, atslab_2, arg3) ; tmp1169 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1169, atslab_d0exp_loc, tmp1170) ; ats_selptrset_mac(anairiats_rec_63, tmp1169, atslab_d0exp_node, tmp1176) ; return (tmp1169) ; } /* end of [d0exp_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55047(line=2031, offs=3) -- 55225(line=2036, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1177) ; ATSlocal (ats_ptr_type, tmp1178) ; ATSlocal (ats_ptr_type, tmp1179) ; ATSlocal (ats_ptr_type, tmp1180) ; ATSlocal (ats_ptr_type, tmp1181) ; ATSlocal (ats_ptr_type, tmp1182) ; __ats_lab_d0exp_extval: tmp1179 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1180 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1178 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1179, tmp1180) ; tmp1181 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg2), atslab_s0tring_val) ; tmp1182 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1182)->tag = 15 ; ats_selptrset_mac(anairiats_sum_15, tmp1182, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1182, atslab_1, tmp1181) ; tmp1177 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1177, atslab_d0exp_loc, tmp1178) ; ats_selptrset_mac(anairiats_rec_63, tmp1177, atslab_d0exp_node, tmp1182) ; return (tmp1177) ; } /* end of [d0exp_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55274(line=2040, offs=3) -- 55471(line=2045, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_fix (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1183) ; ATSlocal (ats_ptr_type, tmp1184) ; ATSlocal (ats_ptr_type, tmp1185) ; ATSlocal (ats_ptr_type, tmp1186) ; ATSlocal (ats_ptr_type, tmp1187) ; __ats_lab_d0exp_fix: tmp1184 = lamkind_get_loc_51 (arg0) ; tmp1186 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg5), atslab_d0exp_loc) ; tmp1185 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1184, tmp1186) ; tmp1187 = ATS_MALLOC(sizeof(anairiats_sum_67)) ; ((ats_sum_ptr_type)tmp1187)->tag = 16 ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_3, arg3) ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_4, arg4) ; ats_selptrset_mac(anairiats_sum_67, tmp1187, atslab_5, arg5) ; tmp1183 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1183, atslab_d0exp_loc, tmp1185) ; ats_selptrset_mac(anairiats_rec_63, tmp1183, atslab_d0exp_node, tmp1187) ; return (tmp1183) ; } /* end of [d0exp_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55517(line=2048, offs=13) -- 55590(line=2050, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_float (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1188) ; ATSlocal (ats_ptr_type, tmp1189) ; ATSlocal (ats_ptr_type, tmp1190) ; ATSlocal (ats_ptr_type, tmp1191) ; __ats_lab_d0exp_float: tmp1189 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_loc) ; tmp1191 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_f0loat_val) ; tmp1190 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1190)->tag = 17 ; ats_selptrset_mac(anairiats_sum_0, tmp1190, atslab_0, tmp1191) ; tmp1188 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1188, atslab_d0exp_loc, tmp1189) ; ats_selptrset_mac(anairiats_rec_63, tmp1188, atslab_d0exp_node, tmp1190) ; return (tmp1188) ; } /* end of [d0exp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55640(line=2053, offs=15) -- 55719(line=2055, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_floatsp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1192) ; ATSlocal (ats_ptr_type, tmp1193) ; ATSlocal (ats_ptr_type, tmp1194) ; ATSlocal (ats_ptr_type, tmp1195) ; __ats_lab_d0exp_floatsp: tmp1193 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_f0loatsp_loc) ; tmp1195 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_f0loatsp_val) ; tmp1194 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1194)->tag = 18 ; ats_selptrset_mac(anairiats_sum_0, tmp1194, atslab_0, tmp1195) ; tmp1192 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1192, atslab_d0exp_loc, tmp1193) ; ats_selptrset_mac(anairiats_rec_63, tmp1192, atslab_d0exp_node, tmp1194) ; return (tmp1192) ; } /* end of [d0exp_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55820(line=2061, offs=7) -- 55989(line=2064, offs=59) */ ATSstaticdec() ats_ptr_type aux_397 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1197) ; ATSlocal (ats_ptr_type, tmp1198) ; ATSlocal (ats_ptr_type, tmp1199) ; ATSlocal (ats_ptr_type, tmp1200) ; ATSlocal (ats_ptr_type, tmp1201) ; __ats_lab_aux_397: do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_141_0 ; } __ats_lab_140_1: tmp1198 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1199 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; arg0 = tmp1198 ; arg1 = tmp1199 ; goto __ats_lab_aux_397 ; // tail call break ; /* branch: __ats_lab_141 */ __ats_lab_141_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_141_1: tmp1200 = ats_selsin_mac(env0, atslab_t0kn_loc) ; tmp1201 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1197 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1200, tmp1201) ; break ; } while (0) ; return (tmp1197) ; } /* end of [aux_397] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_397_closure_type ; ats_ptr_type aux_397_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_397 (((aux_397_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_397_closure_init (aux_397_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_397_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_397_closure_make (ats_ptr_type env0) { aux_397_closure_type *p_clo = ATS_MALLOC(sizeof(aux_397_closure_type)) ; aux_397_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 55791(line=2060, offs=14) -- 56144(line=2069, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_foldat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1196) ; ATSlocal (ats_ptr_type, tmp1202) ; ATSlocal (ats_ptr_type, tmp1203) ; ATSlocal (ats_ptr_type, tmp1204) ; ATSlocal (ats_ptr_type, tmp1205) ; __ats_lab_d0exp_foldat: do { /* branch: __ats_lab_142 */ __ats_lab_142_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_143_0 ; } __ats_lab_142_1: tmp1203 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1204 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1202 = aux_397 (arg0, tmp1203, tmp1204) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_143_1: tmp1202 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; break ; } while (0) ; tmp1205 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1205)->tag = 19 ; ats_selptrset_mac(anairiats_sum_0, tmp1205, atslab_0, arg1) ; tmp1196 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1196, atslab_d0exp_loc, tmp1202) ; ats_selptrset_mac(anairiats_rec_63, tmp1196, atslab_d0exp_node, tmp1205) ; return (tmp1196) ; } /* end of [d0exp_foldat] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 56216(line=2074, offs=15) -- 56596(line=2087, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_for_itp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1206) ; ATSlocal (ats_ptr_type, tmp1207) ; ATSlocal (ats_ptr_type, tmp1208) ; ATSlocal (ats_ptr_type, tmp1209) ; ATSlocal (ats_ptr_type, tmp1210) ; ATSlocal (ats_ptr_type, tmp1211) ; ATSlocal (ats_ptr_type, tmp1212) ; ATSlocal (ats_ptr_type, tmp1213) ; ATSlocal (ats_ptr_type, tmp1214) ; ATSlocal (ats_ptr_type, tmp1215) ; __ats_lab_d0exp_for_itp: tmp1207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_68, arg0), atslab_loophead_tok) ; tmp1208 = ats_selsin_mac(tmp1207, atslab_t0kn_loc) ; tmp1210 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg2), atslab_d0exp_loc) ; tmp1209 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1208, tmp1210) ; tmp1211 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_68, arg0), atslab_loophead_inv) ; tmp1213 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_69, arg1), atslab_0) ; tmp1214 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_69, arg1), atslab_1) ; tmp1215 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_69, arg1), atslab_2) ; tmp1212 = ATS_MALLOC(sizeof(anairiats_sum_67)) ; ((ats_sum_ptr_type)tmp1212)->tag = 20 ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_0, tmp1211) ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_1, tmp1208) ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_2, tmp1213) ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_3, tmp1214) ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_4, tmp1215) ; ats_selptrset_mac(anairiats_sum_67, tmp1212, atslab_5, arg2) ; tmp1206 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1206, atslab_d0exp_loc, tmp1209) ; ats_selptrset_mac(anairiats_rec_63, tmp1206, atslab_d0exp_node, tmp1212) ; return (tmp1206) ; } /* end of [d0exp_for_itp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 56697(line=2093, offs=7) -- 56866(line=2096, offs=59) */ ATSstaticdec() ats_ptr_type aux_400 (ats_ptr_type env0, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1217) ; ATSlocal (ats_ptr_type, tmp1218) ; ATSlocal (ats_ptr_type, tmp1219) ; ATSlocal (ats_ptr_type, tmp1220) ; ATSlocal (ats_ptr_type, tmp1221) ; __ats_lab_aux_400: do { /* branch: __ats_lab_144 */ __ats_lab_144_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp1218 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1219 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; arg0 = tmp1218 ; arg1 = tmp1219 ; goto __ats_lab_aux_400 ; // tail call break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_145_1: tmp1220 = ats_selsin_mac(env0, atslab_t0kn_loc) ; tmp1221 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1217 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1220, tmp1221) ; break ; } while (0) ; return (tmp1217) ; } /* end of [aux_400] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_400_closure_type ; ats_ptr_type aux_400_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_400 (((aux_400_closure_type*)cloptr)->closure_env_0, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_400_closure_init (aux_400_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_400_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_400_closure_make (ats_ptr_type env0) { aux_400_closure_type *p_clo = ATS_MALLOC(sizeof(aux_400_closure_type)) ; aux_400_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 56668(line=2092, offs=14) -- 57021(line=2101, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_freeat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1216) ; ATSlocal (ats_ptr_type, tmp1222) ; ATSlocal (ats_ptr_type, tmp1223) ; ATSlocal (ats_ptr_type, tmp1224) ; ATSlocal (ats_ptr_type, tmp1225) ; __ats_lab_d0exp_freeat: do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp1223 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1224 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1222 = aux_400 (arg0, tmp1223, tmp1224) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_147_1: tmp1222 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; break ; } while (0) ; tmp1225 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1225)->tag = 21 ; ats_selptrset_mac(anairiats_sum_0, tmp1225, atslab_0, arg1) ; tmp1216 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1216, atslab_d0exp_loc, tmp1222) ; ats_selptrset_mac(anairiats_rec_63, tmp1216, atslab_d0exp_node, tmp1225) ; return (tmp1216) ; } /* end of [d0exp_freeat] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 57089(line=2106, offs=11) -- 57328(line=2114, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_ide (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1226) ; ATSlocal (ats_ptr_type, tmp1227) ; ATSlocal (ats_bool_type, tmp1228) ; ATSlocal (ats_ptr_type, tmp1229) ; ATSlocal (ats_ptr_type, tmp1230) ; ATSlocal (ats_ptr_type, tmp1231) ; ATSlocal (ats_ptr_type, tmp1232) ; __ats_lab_d0exp_ide: tmp1227 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1228 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp1227, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK) ; if (tmp1228) { tmp1229 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1230 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Etop_49) ; tmp1226 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1226, atslab_d0exp_loc, tmp1229) ; ats_selptrset_mac(anairiats_rec_63, tmp1226, atslab_d0exp_node, tmp1230) ; } else { tmp1231 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1232 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1232)->tag = 22 ; ats_selptrset_mac(anairiats_sum_0, tmp1232, atslab_0, tmp1227) ; tmp1226 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1226, atslab_d0exp_loc, tmp1231) ; ats_selptrset_mac(anairiats_rec_63, tmp1226, atslab_d0exp_node, tmp1232) ; } /* end of [if] */ return (tmp1226) ; } /* end of [d0exp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 57377(line=2117, offs=13) -- 57449(line=2119, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_idext (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1233) ; ATSlocal (ats_ptr_type, tmp1234) ; ATSlocal (ats_ptr_type, tmp1235) ; ATSlocal (ats_ptr_type, tmp1236) ; __ats_lab_d0exp_idext: tmp1234 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1236 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1235 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1235)->tag = 23 ; ats_selptrset_mac(anairiats_sum_0, tmp1235, atslab_0, tmp1236) ; tmp1233 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1233, atslab_d0exp_loc, tmp1234) ; ats_selptrset_mac(anairiats_rec_63, tmp1233, atslab_d0exp_node, tmp1235) ; return (tmp1233) ; } /* end of [d0exp_idext] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 57523(line=2125, offs=3) -- 57718(line=2130, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_if_none (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1237) ; ATSlocal (ats_ptr_type, tmp1238) ; ATSlocal (ats_ptr_type, tmp1239) ; ATSlocal (ats_ptr_type, tmp1240) ; ATSlocal (ats_ptr_type, tmp1241) ; ATSlocal (ats_ptr_type, tmp1242) ; ATSlocal (ats_ptr_type, tmp1243) ; __ats_lab_d0exp_if_none: tmp1238 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_70, arg0), atslab_ifhead_tok) ; tmp1240 = ats_selsin_mac(tmp1238, atslab_t0kn_loc) ; tmp1241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg2), atslab_d0exp_loc) ; tmp1239 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1240, tmp1241) ; tmp1243 = (ats_sum_ptr_type)0 ; tmp1242 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1242)->tag = 24 ; ats_selptrset_mac(anairiats_sum_42, tmp1242, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1242, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1242, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1242, atslab_3, tmp1243) ; tmp1237 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1237, atslab_d0exp_loc, tmp1239) ; ats_selptrset_mac(anairiats_rec_63, tmp1237, atslab_d0exp_node, tmp1242) ; return (tmp1237) ; } /* end of [d0exp_if_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 57770(line=2133, offs=15) -- 57985(line=2140, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_if_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1244) ; ATSlocal (ats_ptr_type, tmp1245) ; ATSlocal (ats_ptr_type, tmp1246) ; ATSlocal (ats_ptr_type, tmp1247) ; ATSlocal (ats_ptr_type, tmp1248) ; ATSlocal (ats_ptr_type, tmp1249) ; ATSlocal (ats_ptr_type, tmp1250) ; __ats_lab_d0exp_if_some: tmp1245 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_70, arg0), atslab_ifhead_tok) ; tmp1247 = ats_selsin_mac(tmp1245, atslab_t0kn_loc) ; tmp1248 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg3), atslab_d0exp_loc) ; tmp1246 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1247, tmp1248) ; tmp1250 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1250, atslab_0, arg3) ; tmp1249 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1249)->tag = 24 ; ats_selptrset_mac(anairiats_sum_42, tmp1249, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1249, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1249, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1249, atslab_3, tmp1250) ; tmp1244 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1244, atslab_d0exp_loc, tmp1246) ; ats_selptrset_mac(anairiats_rec_63, tmp1244, atslab_d0exp_node, tmp1249) ; return (tmp1244) ; } /* end of [d0exp_if_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 58054(line=2144, offs=21) -- 58121(line=2146, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1251) ; ATSlocal (ats_ptr_type, tmp1252) ; ATSlocal (ats_ptr_type, tmp1253) ; ATSlocal (ats_ptr_type, tmp1254) ; __ats_lab_d0exp_int: tmp1252 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_loc) ; tmp1254 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg0), atslab_i0nt_val) ; tmp1253 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1253)->tag = 25 ; ats_selptrset_mac(anairiats_sum_0, tmp1253, atslab_0, tmp1254) ; tmp1251 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1251, atslab_d0exp_loc, tmp1252) ; ats_selptrset_mac(anairiats_rec_63, tmp1251, atslab_d0exp_node, tmp1253) ; return (tmp1251) ; } /* end of [d0exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 58167(line=2148, offs=23) -- 58240(line=2150, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_intsp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1255) ; ATSlocal (ats_ptr_type, tmp1256) ; ATSlocal (ats_ptr_type, tmp1257) ; ATSlocal (ats_ptr_type, tmp1258) ; __ats_lab_d0exp_intsp: tmp1256 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0ntsp_loc) ; tmp1258 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_i0ntsp_val) ; tmp1257 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1257)->tag = 26 ; ats_selptrset_mac(anairiats_sum_0, tmp1257, atslab_0, tmp1258) ; tmp1255 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1255, atslab_d0exp_loc, tmp1256) ; ats_selptrset_mac(anairiats_rec_63, tmp1255, atslab_d0exp_node, tmp1257) ; return (tmp1255) ; } /* end of [d0exp_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 58309(line=2155, offs=3) -- 58498(line=2160, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_lam (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1259) ; ATSlocal (ats_ptr_type, tmp1260) ; ATSlocal (ats_ptr_type, tmp1261) ; ATSlocal (ats_ptr_type, tmp1262) ; ATSlocal (ats_ptr_type, tmp1263) ; __ats_lab_d0exp_lam: tmp1260 = lamkind_get_loc_51 (arg0) ; tmp1262 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg4), atslab_d0exp_loc) ; tmp1261 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1260, tmp1262) ; tmp1263 = ATS_MALLOC(sizeof(anairiats_sum_71)) ; ((ats_sum_ptr_type)tmp1263)->tag = 27 ; ats_selptrset_mac(anairiats_sum_71, tmp1263, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_71, tmp1263, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_71, tmp1263, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_71, tmp1263, atslab_3, arg3) ; ats_selptrset_mac(anairiats_sum_71, tmp1263, atslab_4, arg4) ; tmp1259 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1259, atslab_d0exp_loc, tmp1261) ; ats_selptrset_mac(anairiats_rec_63, tmp1259, atslab_d0exp_node, tmp1263) ; return (tmp1259) ; } /* end of [d0exp_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 58569(line=2166, offs=3) -- 58763(line=2171, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_let_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1264) ; ATSlocal (ats_ptr_type, tmp1265) ; ATSlocal (ats_ptr_type, tmp1266) ; ATSlocal (ats_ptr_type, tmp1267) ; ATSlocal (ats_ptr_type, tmp1268) ; ATSlocal (ats_ptr_type, tmp1269) ; __ats_lab_d0exp_let_seq: tmp1266 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1267 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1265 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1266, tmp1267) ; tmp1268 = d0exp_seq (arg2, arg3, arg4) ; tmp1269 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1269)->tag = 28 ; ats_selptrset_mac(anairiats_sum_15, tmp1269, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1269, atslab_1, tmp1268) ; tmp1264 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1264, atslab_d0exp_loc, tmp1265) ; ats_selptrset_mac(anairiats_rec_63, tmp1264, atslab_d0exp_node, tmp1269) ; return (tmp1264) ; } /* end of [d0exp_let_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 58835(line=2177, offs=3) -- 58969(line=2181, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_list (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1270) ; ATSlocal (ats_ptr_type, tmp1271) ; ATSlocal (ats_ptr_type, tmp1272) ; ATSlocal (ats_ptr_type, tmp1273) ; ATSlocal (ats_ptr_type, tmp1274) ; __ats_lab_d0exp_list: tmp1272 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1273 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1271 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1272, tmp1273) ; tmp1274 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1274)->tag = 29 ; ats_selptrset_mac(anairiats_sum_0, tmp1274, atslab_0, arg1) ; tmp1270 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1270, atslab_d0exp_loc, tmp1271) ; ats_selptrset_mac(anairiats_rec_63, tmp1270, atslab_d0exp_node, tmp1274) ; return (tmp1270) ; } /* end of [d0exp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 59018(line=2185, offs=3) -- 59171(line=2189, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1275) ; ATSlocal (ats_ptr_type, tmp1276) ; ATSlocal (ats_ptr_type, tmp1277) ; ATSlocal (ats_ptr_type, tmp1278) ; ATSlocal (ats_ptr_type, tmp1279) ; __ats_lab_d0exp_list2: tmp1277 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1278 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1276 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1277, tmp1278) ; tmp1279 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1279)->tag = 30 ; ats_selptrset_mac(anairiats_sum_15, tmp1279, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1279, atslab_1, arg2) ; tmp1275 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1275, atslab_d0exp_loc, tmp1276) ; ats_selptrset_mac(anairiats_rec_63, tmp1275, atslab_d0exp_node, tmp1279) ; return (tmp1275) ; } /* end of [d0exp_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 59242(line=2193, offs=25) -- 59306(line=2194, offs=55) */ ATSglobaldec() ats_ptr_type d0exp_loopexn (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1280) ; ATSlocal (ats_ptr_type, tmp1281) ; ATSlocal (ats_ptr_type, tmp1282) ; __ats_lab_d0exp_loopexn: tmp1281 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1282 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp1282)->tag = 31 ; ats_selptrset_mac(anairiats_sum_11, tmp1282, atslab_0, arg0) ; tmp1280 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1280, atslab_d0exp_loc, tmp1281) ; ats_selptrset_mac(anairiats_rec_63, tmp1280, atslab_d0exp_node, tmp1282) ; return (tmp1280) ; } /* end of [d0exp_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 59375(line=2200, offs=11) -- 59677(line=2210, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_lst (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1283) ; ATSlocal (ats_ptr_type, tmp1284) ; ATSlocal (ats_ptr_type, tmp1285) ; ATSlocal (ats_ptr_type, tmp1286) ; ATSlocal (ats_ptr_type, tmp1287) ; ATSlocal (ats_ptr_type, tmp1288) ; ATSlocal (ats_ptr_type, tmp1289) ; ATSlocal (ats_ptr_type, tmp1290) ; __ats_lab_d0exp_lst: tmp1285 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1286 = ats_selsin_mac(arg5, atslab_t0kn_loc) ; tmp1284 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1285, tmp1286) ; do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } tmp1288 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; if (tmp1288 != (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp1289 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp1287 = tmp1289 ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: __ats_lab_149_1: tmp1287 = d0exp_list (arg3, arg4, arg5) ; break ; } while (0) ; tmp1290 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1290)->tag = 32 ; ats_selptrset_mac(anairiats_sum_40, tmp1290, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp1290, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_40, tmp1290, atslab_2, tmp1287) ; tmp1283 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1283, atslab_d0exp_loc, tmp1284) ; ats_selptrset_mac(anairiats_rec_63, tmp1283, atslab_d0exp_node, tmp1290) ; return (tmp1283) ; } /* end of [d0exp_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 59727(line=2213, offs=17) -- 59926(line=2220, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_lst_quote (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1291) ; ATSlocal (ats_ptr_type, tmp1292) ; ATSlocal (ats_ptr_type, tmp1293) ; ATSlocal (ats_ptr_type, tmp1294) ; ATSlocal (ats_ptr_type, tmp1295) ; __ats_lab_d0exp_lst_quote: tmp1292 = d0exp_list (arg0, arg1, arg2) ; tmp1293 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, tmp1292), atslab_d0exp_loc) ; tmp1295 = s0expopt_none () ; tmp1294 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1294)->tag = 32 ; ats_selptrset_mac(anairiats_sum_40, tmp1294, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_40, tmp1294, atslab_1, tmp1295) ; ats_selptrset_mac(anairiats_sum_40, tmp1294, atslab_2, tmp1292) ; tmp1291 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1291, atslab_d0exp_loc, tmp1293) ; ats_selptrset_mac(anairiats_rec_63, tmp1291, atslab_d0exp_node, tmp1294) ; return (tmp1291) ; } /* end of [d0exp_lst_quote] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 59988(line=2226, offs=5) -- 60109(line=2229, offs=2) */ ATSstaticdec() ats_ptr_type d0exp_macsyn_414 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1296) ; ATSlocal (ats_ptr_type, tmp1297) ; __ats_lab_d0exp_macsyn_414: tmp1297 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1297)->tag = 33 ; ats_selptrset_mac(anairiats_sum_15, tmp1297, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1297, atslab_1, arg2) ; tmp1296 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1296, atslab_d0exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_63, tmp1296, atslab_d0exp_node, tmp1297) ; return (tmp1296) ; } /* end of [d0exp_macsyn_414] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 60189(line=2233, offs=30) -- 60317(line=2237, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_macsyn_cross (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1298) ; ATSlocal (ats_ptr_type, tmp1299) ; ATSlocal (ats_ptr_type, tmp1300) ; ATSlocal (ats_ptr_type, tmp1301) ; ATSlocal (ats_ptr_type, tmp1302) ; __ats_lab_d0exp_macsyn_cross: tmp1300 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1301 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1299 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1300, tmp1301) ; tmp1302 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; tmp1298 = d0exp_macsyn_414 (tmp1299, tmp1302, arg1) ; return (tmp1298) ; } /* end of [d0exp_macsyn_cross] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 60380(line=2239, offs=31) -- 60509(line=2243, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_macsyn_decode (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1303) ; ATSlocal (ats_ptr_type, tmp1304) ; ATSlocal (ats_ptr_type, tmp1305) ; ATSlocal (ats_ptr_type, tmp1306) ; ATSlocal (ats_ptr_type, tmp1307) ; __ats_lab_d0exp_macsyn_decode: tmp1305 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1306 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1304 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1305, tmp1306) ; tmp1307 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; tmp1303 = d0exp_macsyn_414 (tmp1304, tmp1307, arg1) ; return (tmp1303) ; } /* end of [d0exp_macsyn_decode] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 60577(line=2245, offs=35) -- 60707(line=2249, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_macsyn_encode_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1308) ; ATSlocal (ats_ptr_type, tmp1309) ; ATSlocal (ats_ptr_type, tmp1310) ; ATSlocal (ats_ptr_type, tmp1311) ; __ats_lab_d0exp_macsyn_encode_seq: tmp1309 = d0exp_seq (arg0, arg1, arg2) ; tmp1310 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, tmp1309), atslab_d0exp_loc) ; tmp1311 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; tmp1308 = d0exp_macsyn_414 (tmp1310, tmp1311, tmp1309) ; return (tmp1308) ; } /* end of [d0exp_macsyn_encode_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 60811(line=2255, offs=23) -- 60939(line=2259, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_opide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1312) ; ATSlocal (ats_ptr_type, tmp1313) ; ATSlocal (ats_ptr_type, tmp1314) ; ATSlocal (ats_ptr_type, tmp1315) ; ATSlocal (ats_ptr_type, tmp1316) ; ATSlocal (ats_ptr_type, tmp1317) ; __ats_lab_d0exp_opide: tmp1314 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1315 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1313 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1314, tmp1315) ; tmp1317 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp1316 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1316)->tag = 34 ; ats_selptrset_mac(anairiats_sum_0, tmp1316, atslab_0, tmp1317) ; tmp1312 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1312, atslab_d0exp_loc, tmp1313) ; ats_selptrset_mac(anairiats_rec_63, tmp1312, atslab_d0exp_node, tmp1316) ; return (tmp1312) ; } /* end of [d0exp_opide] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 60987(line=2261, offs=23) -- 61054(line=2262, offs=58) */ ATSglobaldec() ats_ptr_type d0exp_ptrof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1318) ; ATSlocal (ats_ptr_type, tmp1319) ; ATSlocal (ats_ptr_type, tmp1320) ; __ats_lab_d0exp_ptrof: tmp1319 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1320 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eptrof_35) ; tmp1318 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1318, atslab_d0exp_loc, tmp1319) ; ats_selptrset_mac(anairiats_rec_63, tmp1318, atslab_d0exp_node, tmp1320) ; return (tmp1318) ; } /* end of [d0exp_ptrof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 61100(line=2265, offs=21) -- 61271(line=2270, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_qid (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1321) ; ATSlocal (ats_ptr_type, tmp1322) ; ATSlocal (ats_ptr_type, tmp1323) ; ATSlocal (ats_ptr_type, tmp1324) ; ATSlocal (ats_ptr_type, tmp1325) ; ATSlocal (ats_ptr_type, tmp1326) ; __ats_lab_d0exp_qid: tmp1322 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_28, arg0), atslab_d0ynq_loc) ; tmp1323 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1324 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1322, tmp1323) ; tmp1326 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_sym) ; tmp1325 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1325)->tag = 36 ; ats_selptrset_mac(anairiats_sum_15, tmp1325, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1325, atslab_1, tmp1326) ; tmp1321 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1321, atslab_d0exp_loc, tmp1324) ; ats_selptrset_mac(anairiats_rec_63, tmp1321, atslab_d0exp_node, tmp1325) ; return (tmp1321) ; } /* end of [d0exp_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 61317(line=2273, offs=13) -- 61448(line=2277, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_raise (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1327) ; ATSlocal (ats_ptr_type, tmp1328) ; ATSlocal (ats_ptr_type, tmp1329) ; ATSlocal (ats_ptr_type, tmp1330) ; ATSlocal (ats_ptr_type, tmp1331) ; __ats_lab_d0exp_raise: tmp1329 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1330 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1328 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1329, tmp1330) ; tmp1331 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1331)->tag = 37 ; ats_selptrset_mac(anairiats_sum_0, tmp1331, atslab_0, arg1) ; tmp1327 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1327, atslab_d0exp_loc, tmp1328) ; ats_selptrset_mac(anairiats_rec_63, tmp1327, atslab_d0exp_node, tmp1331) ; return (tmp1327) ; } /* end of [d0exp_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 61496(line=2280, offs=3) -- 61645(line=2284, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_rec (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1332) ; ATSlocal (ats_ptr_type, tmp1333) ; ATSlocal (ats_ptr_type, tmp1334) ; ATSlocal (ats_ptr_type, tmp1335) ; ATSlocal (ats_ptr_type, tmp1336) ; __ats_lab_d0exp_rec: tmp1334 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1335 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1333 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1334, tmp1335) ; tmp1336 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1336)->tag = 38 ; ats_selptrset_mac(anairiats_sum_24, tmp1336, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp1336, atslab_1, arg2) ; tmp1332 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1332, atslab_d0exp_loc, tmp1333) ; ats_selptrset_mac(anairiats_rec_63, tmp1332, atslab_d0exp_node, tmp1336) ; return (tmp1332) ; } /* end of [d0exp_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 61728(line=2287, offs=7) -- 61927(line=2290, offs=59) */ ATSstaticdec() ats_ptr_type aux_loc_424 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1338) ; ATSlocal (ats_ptr_type, tmp1339) ; ATSlocal (ats_ptr_type, tmp1340) ; ATSlocal (ats_ptr_type, tmp1341) ; ATSlocal (ats_ptr_type, tmp1342) ; __ats_lab_aux_loc_424: do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp1339 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1340 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1339 ; arg2 = tmp1340 ; goto __ats_lab_aux_loc_424 ; // tail call break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_151_1: tmp1341 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1342 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_72, arg1), atslab_sc0lau_loc) ; tmp1338 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1341, tmp1342) ; break ; } while (0) ; return (tmp1338) ; } /* end of [aux_loc_424] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 61693(line=2286, offs=25) -- 62210(line=2299, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_scaseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1337) ; ATSlocal (ats_ptr_type, tmp1343) ; ATSlocal (ats_ptr_type, tmp1344) ; ATSlocal (ats_ptr_type, tmp1345) ; ATSlocal (ats_ptr_type, tmp1346) ; ATSlocal (ats_ptr_type, tmp1347) ; ATSlocal (ats_ptr_type, tmp1348) ; ATSlocal (ats_ptr_type, tmp1349) ; __ats_lab_d0exp_scaseof: tmp1343 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_66, arg0), atslab_casehead_tok) ; do { /* branch: __ats_lab_152 */ __ats_lab_152_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_152_1: tmp1345 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1346 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1344 = aux_loc_424 (tmp1343, tmp1345, tmp1346) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: tmp1347 = ats_selsin_mac(tmp1343, atslab_t0kn_loc) ; tmp1348 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1344 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1347, tmp1348) ; break ; } while (0) ; tmp1349 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1349)->tag = 39 ; ats_selptrset_mac(anairiats_sum_38, tmp1349, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1349, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1349, atslab_2, arg3) ; tmp1337 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1337, atslab_d0exp_loc, tmp1344) ; ats_selptrset_mac(anairiats_rec_63, tmp1337, atslab_d0exp_node, tmp1349) ; return (tmp1337) ; } /* end of [d0exp_scaseof] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 62259(line=2301, offs=25) -- 62414(line=2304, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_sel_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1350) ; ATSlocal (ats_ptr_type, tmp1351) ; ATSlocal (ats_ptr_type, tmp1352) ; ATSlocal (ats_ptr_type, tmp1353) ; ATSlocal (ats_ptr_type, tmp1354) ; ATSlocal (ats_int_type, tmp1355) ; ATSlocal (ats_ptr_type, tmp1356) ; __ats_lab_d0exp_sel_lab: tmp1352 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_62, arg0), atslab_s0elop_loc) ; tmp1353 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_l0ab_loc) ; tmp1351 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1352, tmp1353) ; tmp1355 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_62, arg0), atslab_s0elop_knd) ; tmp1356 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_l0ab_lab) ; tmp1354 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1354)->tag = 40 ; ats_selptrset_mac(anairiats_sum_24, tmp1354, atslab_0, tmp1355) ; ats_selptrset_mac(anairiats_sum_24, tmp1354, atslab_1, tmp1356) ; tmp1350 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1350, atslab_d0exp_loc, tmp1351) ; ats_selptrset_mac(anairiats_rec_63, tmp1350, atslab_d0exp_node, tmp1354) ; return (tmp1350) ; } /* end of [d0exp_sel_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 62440(line=2306, offs=25) -- 62599(line=2310, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_sel_ind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1357) ; ATSlocal (ats_ptr_type, tmp1358) ; ATSlocal (ats_ptr_type, tmp1359) ; ATSlocal (ats_ptr_type, tmp1360) ; ATSlocal (ats_ptr_type, tmp1361) ; ATSlocal (ats_int_type, tmp1362) ; ATSlocal (ats_ptr_type, tmp1363) ; __ats_lab_d0exp_sel_ind: tmp1359 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_62, arg0), atslab_s0elop_loc) ; tmp1360 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_loc) ; tmp1358 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1359, tmp1360) ; tmp1362 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_62, arg0), atslab_s0elop_knd) ; tmp1363 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_ind) ; tmp1361 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1361)->tag = 41 ; ats_selptrset_mac(anairiats_sum_24, tmp1361, atslab_0, tmp1362) ; ats_selptrset_mac(anairiats_sum_24, tmp1361, atslab_1, tmp1363) ; tmp1357 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1357, atslab_d0exp_loc, tmp1358) ; ats_selptrset_mac(anairiats_rec_63, tmp1357, atslab_d0exp_node, tmp1361) ; return (tmp1357) ; } /* end of [d0exp_sel_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 62647(line=2312, offs=21) -- 62840(line=2318, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1364) ; ATSlocal (ats_ptr_type, tmp1365) ; ATSlocal (ats_ptr_type, tmp1366) ; ATSlocal (ats_ptr_type, tmp1367) ; ATSlocal (ats_ptr_type, tmp1368) ; __ats_lab_d0exp_seq: tmp1366 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1367 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1365 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1366, tmp1367) ; do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp1368 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1368)->tag = 42 ; ats_selptrset_mac(anairiats_sum_0, tmp1368, atslab_0, arg1) ; tmp1364 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1364, atslab_d0exp_loc, tmp1365) ; ats_selptrset_mac(anairiats_rec_63, tmp1364, atslab_d0exp_node, tmp1368) ; break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_155_1: tmp1364 = d0exp_empty (tmp1365) ; break ; } while (0) ; return (tmp1364) ; } /* end of [d0exp_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 62890(line=2322, offs=3) -- 63025(line=2326, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_sexparg (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1369) ; ATSlocal (ats_ptr_type, tmp1370) ; ATSlocal (ats_ptr_type, tmp1371) ; ATSlocal (ats_ptr_type, tmp1372) ; ATSlocal (ats_ptr_type, tmp1373) ; __ats_lab_d0exp_sexparg: tmp1371 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1372 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1370 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1371, tmp1372) ; tmp1373 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1373)->tag = 43 ; ats_selptrset_mac(anairiats_sum_0, tmp1373, atslab_0, arg1) ; tmp1369 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1369, atslab_d0exp_loc, tmp1370) ; ats_selptrset_mac(anairiats_rec_63, tmp1369, atslab_d0exp_node, tmp1373) ; return (tmp1369) ; } /* end of [d0exp_sexparg] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 63078(line=2329, offs=16) -- 63218(line=2333, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_showtype (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1374) ; ATSlocal (ats_ptr_type, tmp1375) ; ATSlocal (ats_ptr_type, tmp1376) ; ATSlocal (ats_ptr_type, tmp1377) ; ATSlocal (ats_ptr_type, tmp1378) ; __ats_lab_d0exp_showtype: tmp1376 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1377 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1375 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1376, tmp1377) ; tmp1378 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1378)->tag = 44 ; ats_selptrset_mac(anairiats_sum_0, tmp1378, atslab_0, arg1) ; tmp1374 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1374, atslab_d0exp_loc, tmp1375) ; ats_selptrset_mac(anairiats_rec_63, tmp1374, atslab_d0exp_node, tmp1378) ; return (tmp1374) ; } /* end of [d0exp_showtype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 63267(line=2336, offs=11) -- 63480(line=2343, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_sif (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1379) ; ATSlocal (ats_ptr_type, tmp1380) ; ATSlocal (ats_ptr_type, tmp1381) ; ATSlocal (ats_ptr_type, tmp1382) ; ATSlocal (ats_ptr_type, tmp1383) ; ATSlocal (ats_ptr_type, tmp1384) ; __ats_lab_d0exp_sif: tmp1380 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_70, arg0), atslab_ifhead_tok) ; tmp1382 = ats_selsin_mac(tmp1380, atslab_t0kn_loc) ; tmp1383 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg3), atslab_d0exp_loc) ; tmp1381 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1382, tmp1383) ; tmp1384 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1384)->tag = 45 ; ats_selptrset_mac(anairiats_sum_42, tmp1384, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1384, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1384, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1384, atslab_3, arg3) ; tmp1379 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1379, atslab_d0exp_loc, tmp1381) ; ats_selptrset_mac(anairiats_rec_63, tmp1379, atslab_d0exp_node, tmp1384) ; return (tmp1379) ; } /* end of [d0exp_sif] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 63527(line=2346, offs=14) -- 63619(line=2349, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1385) ; ATSlocal (ats_ptr_type, tmp1386) ; ATSlocal (ats_ptr_type, tmp1387) ; ATSlocal (ats_ptr_type, tmp1388) ; ATSlocal (ats_int_type, tmp1389) ; __ats_lab_d0exp_string: tmp1386 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1388 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1389 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_len) ; tmp1387 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp1387)->tag = 46 ; ats_selptrset_mac(anairiats_sum_12, tmp1387, atslab_0, tmp1388) ; ats_selptrset_mac(anairiats_sum_12, tmp1387, atslab_1, tmp1389) ; tmp1385 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1385, atslab_d0exp_loc, tmp1386) ; ats_selptrset_mac(anairiats_rec_63, tmp1385, atslab_d0exp_node, tmp1387) ; return (tmp1385) ; } /* end of [d0exp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 63670(line=2353, offs=3) -- 63959(line=2360, offs=4) */ ATSglobaldec() ats_ptr_type d0exp_tmpid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1390) ; ATSlocal (ats_ptr_type, tmp1391) ; ATSlocal (ats_ptr_type, tmp1392) ; ATSlocal (ats_ptr_type, tmp1393) ; ATSlocal (ats_ptr_type, tmp1394) ; ATSlocal (ats_ptr_type, tmp1395) ; ATSlocal (ats_ptr_type, tmp1396) ; __ats_lab_d0exp_tmpid: tmp1391 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_32, arg0), atslab_tmpqi0de_loc) ; tmp1392 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make (tmp1391) ; tmp1394 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1393 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1391, tmp1394) ; tmp1395 = gtlt_t1mps0expseqseq_cons_loc_212 (tmp1392, arg1, arg2) ; tmp1396 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1396)->tag = 48 ; ats_selptrset_mac(anairiats_sum_15, tmp1396, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1396, atslab_1, tmp1395) ; tmp1390 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1390, atslab_d0exp_loc, tmp1393) ; ats_selptrset_mac(anairiats_rec_63, tmp1390, atslab_d0exp_node, tmp1396) ; return (tmp1390) ; } /* end of [d0exp_tmpid] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 64050(line=2363, offs=7) -- 64239(line=2367, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_434 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1398) ; ATSlocal (ats_ptr_type, tmp1399) ; ATSlocal (ats_ptr_type, tmp1400) ; ATSlocal (ats_ptr_type, tmp1401) ; ATSlocal (ats_ptr_type, tmp1402) ; __ats_lab_aux_loc_434: do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp1399 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1400 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1399 ; arg2 = tmp1400 ; goto __ats_lab_aux_loc_434 ; // tail call break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_157_1: tmp1401 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1402 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_65, arg1), atslab_c0lau_loc) ; tmp1398 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1401, tmp1402) ; break ; } while (0) ; return (tmp1398) ; } /* end of [aux_loc_434] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 64013(line=2362, offs=29) -- 64558(line=2377, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_trywith_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1397) ; ATSlocal (ats_ptr_type, tmp1403) ; ATSlocal (ats_ptr_type, tmp1404) ; ATSlocal (ats_ptr_type, tmp1405) ; ATSlocal (ats_ptr_type, tmp1406) ; ATSlocal (ats_ptr_type, tmp1407) ; ATSlocal (ats_ptr_type, tmp1408) ; ATSlocal (ats_ptr_type, tmp1409) ; ATSlocal (ats_ptr_type, tmp1410) ; __ats_lab_d0exp_trywith_seq: tmp1403 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_73, arg0), atslab_tryhead_tok) ; do { /* branch: __ats_lab_158 */ __ats_lab_158_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp1405 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1406 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1404 = aux_loc_434 (tmp1403, tmp1405, tmp1406) ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: tmp1407 = ats_selsin_mac(tmp1403, atslab_t0kn_loc) ; tmp1408 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1404 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1407, tmp1408) ; break ; } while (0) ; tmp1409 = d0exp_seq (tmp1403, arg1, arg2) ; tmp1410 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1410)->tag = 50 ; ats_selptrset_mac(anairiats_sum_38, tmp1410, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1410, atslab_1, tmp1409) ; ats_selptrset_mac(anairiats_sum_38, tmp1410, atslab_2, arg3) ; tmp1397 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1397, atslab_d0exp_loc, tmp1404) ; ats_selptrset_mac(anairiats_rec_63, tmp1397, atslab_d0exp_node, tmp1410) ; return (tmp1397) ; } /* end of [d0exp_trywith_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 64608(line=2380, offs=3) -- 64755(line=2384, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_tup (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1411) ; ATSlocal (ats_ptr_type, tmp1412) ; ATSlocal (ats_ptr_type, tmp1413) ; ATSlocal (ats_ptr_type, tmp1414) ; ATSlocal (ats_ptr_type, tmp1415) ; __ats_lab_d0exp_tup: tmp1413 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1414 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1412 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1413, tmp1414) ; tmp1415 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1415)->tag = 51 ; ats_selptrset_mac(anairiats_sum_24, tmp1415, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp1415, atslab_1, arg2) ; tmp1411 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1411, atslab_d0exp_loc, tmp1412) ; ats_selptrset_mac(anairiats_rec_63, tmp1411, atslab_d0exp_node, tmp1415) ; return (tmp1411) ; } /* end of [d0exp_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 64802(line=2387, offs=3) -- 64966(line=2391, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_tup2 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1416) ; ATSlocal (ats_ptr_type, tmp1417) ; ATSlocal (ats_ptr_type, tmp1418) ; ATSlocal (ats_ptr_type, tmp1419) ; ATSlocal (ats_ptr_type, tmp1420) ; __ats_lab_d0exp_tup2: tmp1418 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1419 = ats_selsin_mac(arg4, atslab_t0kn_loc) ; tmp1417 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1418, tmp1419) ; tmp1420 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1420)->tag = 52 ; ats_selptrset_mac(anairiats_sum_40, tmp1420, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp1420, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_40, tmp1420, atslab_2, arg3) ; tmp1416 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1416, atslab_d0exp_loc, tmp1417) ; ats_selptrset_mac(anairiats_rec_63, tmp1416, atslab_d0exp_node, tmp1420) ; return (tmp1416) ; } /* end of [d0exp_tup2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65014(line=2393, offs=24) -- 65088(line=2395, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_viewat (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1421) ; ATSlocal (ats_ptr_type, tmp1422) ; ATSlocal (ats_ptr_type, tmp1423) ; __ats_lab_d0exp_viewat: tmp1422 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1423 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eviewat_53) ; tmp1421 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1421, atslab_d0exp_loc, tmp1422) ; ats_selptrset_mac(anairiats_rec_63, tmp1421, atslab_d0exp_node, tmp1423) ; return (tmp1421) ; } /* end of [d0exp_viewat] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65137(line=2397, offs=23) -- 65276(line=2401, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_where (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1424) ; ATSlocal (ats_ptr_type, tmp1425) ; ATSlocal (ats_ptr_type, tmp1426) ; ATSlocal (ats_ptr_type, tmp1427) ; ATSlocal (ats_ptr_type, tmp1428) ; __ats_lab_d0exp_where: tmp1426 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1427 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1425 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1426, tmp1427) ; tmp1428 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1428)->tag = 54 ; ats_selptrset_mac(anairiats_sum_15, tmp1428, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1428, atslab_1, arg1) ; tmp1424 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1424, atslab_d0exp_loc, tmp1425) ; ats_selptrset_mac(anairiats_rec_63, tmp1424, atslab_d0exp_node, tmp1428) ; return (tmp1424) ; } /* end of [d0exp_where] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65324(line=2403, offs=23) -- 65562(line=2410, offs=6) */ ATSglobaldec() ats_ptr_type d0exp_while (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1429) ; ATSlocal (ats_ptr_type, tmp1430) ; ATSlocal (ats_ptr_type, tmp1431) ; ATSlocal (ats_ptr_type, tmp1432) ; ATSlocal (ats_ptr_type, tmp1433) ; ATSlocal (ats_ptr_type, tmp1434) ; ATSlocal (ats_ptr_type, tmp1435) ; __ats_lab_d0exp_while: tmp1430 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_68, arg0), atslab_loophead_tok) ; tmp1431 = ats_selsin_mac(tmp1430, atslab_t0kn_loc) ; tmp1433 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg2), atslab_d0exp_loc) ; tmp1432 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1431, tmp1433) ; tmp1434 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_68, arg0), atslab_loophead_inv) ; tmp1435 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1435)->tag = 55 ; ats_selptrset_mac(anairiats_sum_42, tmp1435, atslab_0, tmp1434) ; ats_selptrset_mac(anairiats_sum_42, tmp1435, atslab_1, tmp1431) ; ats_selptrset_mac(anairiats_sum_42, tmp1435, atslab_2, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1435, atslab_3, arg2) ; tmp1429 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1429, atslab_d0exp_loc, tmp1432) ; ats_selptrset_mac(anairiats_rec_63, tmp1429, atslab_d0exp_node, tmp1435) ; return (tmp1429) ; } /* end of [d0exp_while] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65663(line=2418, offs=26) -- 65737(line=2420, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_FILENAME (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1436) ; ATSlocal (ats_ptr_type, tmp1437) ; ATSlocal (ats_ptr_type, tmp1438) ; ATSlocal (ats_ptr_type, tmp1439) ; __ats_lab_d0exp_FILENAME: tmp1437 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1439 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; tmp1438 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1438)->tag = 7 ; ats_selptrset_mac(anairiats_sum_0, tmp1438, atslab_0, tmp1439) ; tmp1436 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1436, atslab_d0exp_loc, tmp1437) ; ats_selptrset_mac(anairiats_rec_63, tmp1436, atslab_d0exp_node, tmp1438) ; return (tmp1436) ; } /* end of [d0exp_FILENAME] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65764(line=2422, offs=26) -- 65838(line=2424, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_LOCATION (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1440) ; ATSlocal (ats_ptr_type, tmp1441) ; ATSlocal (ats_ptr_type, tmp1442) ; ATSlocal (ats_ptr_type, tmp1443) ; __ats_lab_d0exp_LOCATION: tmp1441 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1443 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; tmp1442 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1442)->tag = 7 ; ats_selptrset_mac(anairiats_sum_0, tmp1442, atslab_0, tmp1443) ; tmp1440 = ATS_MALLOC(sizeof(anairiats_rec_63)) ; ats_selptrset_mac(anairiats_rec_63, tmp1440, atslab_d0exp_loc, tmp1441) ; ats_selptrset_mac(anairiats_rec_63, tmp1440, atslab_d0exp_node, tmp1442) ; return (tmp1440) ; } /* end of [d0exp_LOCATION] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65884(line=2428, offs=24) -- 65895(line=2428, offs=35) */ ATSglobaldec() ats_ptr_type d0explst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1444) ; __ats_lab_d0explst_nil: tmp1444 = (ats_sum_ptr_type)0 ; return (tmp1444) ; } /* end of [d0explst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65920(line=2429, offs=25) -- 65942(line=2429, offs=47) */ ATSglobaldec() ats_ptr_type d0explst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1445) ; __ats_lab_d0explst_cons: tmp1445 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1445, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1445, atslab_1, arg1) ; return (tmp1445) ; } /* end of [d0explst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 65967(line=2430, offs=25) -- 65989(line=2430, offs=47) */ ATSglobaldec() ats_ptr_type d0explst_sing (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1446) ; ATSlocal (ats_ptr_type, tmp1447) ; __ats_lab_d0explst_sing: tmp1447 = (ats_sum_ptr_type)0 ; tmp1446 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1446, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1446, atslab_1, tmp1447) ; return (tmp1446) ; } /* end of [d0explst_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66015(line=2432, offs=25) -- 66027(line=2432, offs=37) */ ATSglobaldec() ats_ptr_type d0expopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1448) ; __ats_lab_d0expopt_none: tmp1448 = (ats_sum_ptr_type)0 ; return (tmp1448) ; } /* end of [d0expopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66052(line=2433, offs=25) -- 66065(line=2433, offs=38) */ ATSglobaldec() ats_ptr_type d0expopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1449) ; __ats_lab_d0expopt_some: tmp1449 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1449, atslab_0, arg0) ; return (tmp1449) ; } /* end of [d0expopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66094(line=2435, offs=27) -- 66116(line=2435, offs=49) */ ATSglobaldec() ats_ptr_type labd0explst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1450) ; __ats_lab_labd0explst_nil: tmp1450 = (ats_sum_ptr_type)0 ; return (tmp1450) ; } /* end of [labd0explst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66144(line=2436, offs=28) -- 66185(line=2436, offs=69) */ ATSglobaldec() ats_ptr_type labd0explst_cons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1451) ; __ats_lab_labd0explst_cons: tmp1451 = ATS_MALLOC(sizeof(anairiats_sum_37)) ; ats_selptrset_mac(anairiats_sum_37, tmp1451, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_37, tmp1451, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_37, tmp1451, atslab_2, arg2) ; return (tmp1451) ; } /* end of [labd0explst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66214(line=2438, offs=28) -- 66226(line=2438, offs=40) */ ATSglobaldec() ats_ptr_type d0explstopt_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1452) ; __ats_lab_d0explstopt_none: tmp1452 = (ats_sum_ptr_type)0 ; return (tmp1452) ; } /* end of [d0explstopt_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66254(line=2439, offs=28) -- 66269(line=2439, offs=43) */ ATSglobaldec() ats_ptr_type d0explstopt_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1453) ; __ats_lab_d0explstopt_some: tmp1453 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1453, atslab_0, arg0) ; return (tmp1453) ; } /* end of [d0explstopt_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66319(line=2443, offs=30) -- 66415(line=2445, offs=2) */ ATSglobaldec() ats_ptr_type d0arrind_make_sing (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1454) ; ATSlocal (ats_ptr_type, tmp1455) ; ATSlocal (ats_ptr_type, tmp1456) ; ATSlocal (ats_ptr_type, tmp1457) ; __ats_lab_d0arrind_make_sing: tmp1455 = ats_selsin_mac(arg1, atslab_t0kn_loc) ; tmp1457 = (ats_sum_ptr_type)0 ; tmp1456 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1456, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1456, atslab_1, tmp1457) ; tmp1454 = ATS_MALLOC(sizeof(anairiats_rec_64)) ; ats_selptrset_mac(anairiats_rec_64, tmp1454, atslab_d0arrind_loc, tmp1455) ; ats_selptrset_mac(anairiats_rec_64, tmp1454, atslab_d0arrind_ind, tmp1456) ; return (tmp1454) ; } /* end of [d0arrind_make_sing] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66477(line=2447, offs=30) -- 66573(line=2449, offs=2) */ ATSglobaldec() ats_ptr_type d0arrind_make_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1458) ; ATSlocal (ats_ptr_type, tmp1459) ; ATSlocal (ats_ptr_type, tmp1460) ; ATSlocal (ats_ptr_type, tmp1461) ; __ats_lab_d0arrind_make_cons: tmp1459 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_loc) ; tmp1461 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_64, arg1), atslab_d0arrind_ind) ; tmp1460 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1460, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1460, atslab_1, tmp1461) ; tmp1458 = ATS_MALLOC(sizeof(anairiats_rec_64)) ; ats_selptrset_mac(anairiats_rec_64, tmp1458, atslab_d0arrind_loc, tmp1459) ; ats_selptrset_mac(anairiats_rec_64, tmp1458, atslab_d0arrind_ind, tmp1460) ; return (tmp1458) ; } /* end of [d0arrind_make_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66653(line=2454, offs=3) -- 66886(line=2460, offs=4) */ ATSglobaldec() ats_ptr_type initestpost_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1462) ; ATSlocal (ats_ptr_type, tmp1463) ; ATSlocal (ats_ptr_type, tmp1464) ; ATSlocal (ats_ptr_type, tmp1465) ; __ats_lab_initestpost_make: tmp1463 = d0exp_seq (arg0, arg1, arg2) ; tmp1464 = d0exp_seq (arg2, arg3, arg4) ; tmp1465 = d0exp_seq (arg4, arg5, arg6) ; tmp1462 = ATS_MALLOC(sizeof(anairiats_rec_69)) ; ats_selptrset_mac(anairiats_rec_69, tmp1462, atslab_0, tmp1463) ; ats_selptrset_mac(anairiats_rec_69, tmp1462, atslab_1, tmp1464) ; ats_selptrset_mac(anairiats_rec_69, tmp1462, atslab_2, tmp1465) ; return (tmp1462) ; } /* end of [initestpost_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 66962(line=2465, offs=18) -- 67048(line=2467, offs=2) */ ATSglobaldec() ats_ptr_type m0atch_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1466) ; ATSlocal (ats_ptr_type, tmp1467) ; ATSlocal (ats_ptr_type, tmp1468) ; __ats_lab_m0atch_make_none: tmp1467 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1468 = p0atopt_none () ; tmp1466 = ATS_MALLOC(sizeof(anairiats_rec_74)) ; ats_selptrset_mac(anairiats_rec_74, tmp1466, atslab_m0atch_loc, tmp1467) ; ats_selptrset_mac(anairiats_rec_74, tmp1466, atslab_m0atch_exp, arg0) ; ats_selptrset_mac(anairiats_rec_74, tmp1466, atslab_m0atch_pat, tmp1468) ; return (tmp1466) ; } /* end of [m0atch_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67106(line=2470, offs=18) -- 67259(line=2474, offs=6) */ ATSglobaldec() ats_ptr_type m0atch_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1469) ; ATSlocal (ats_ptr_type, tmp1470) ; ATSlocal (ats_ptr_type, tmp1471) ; ATSlocal (ats_ptr_type, tmp1472) ; ATSlocal (ats_ptr_type, tmp1473) ; ATSlocal (ats_ptr_type, tmp1474) ; __ats_lab_m0atch_make_some: tmp1471 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1472 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg1), atslab_p0at_loc) ; tmp1470 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1471, tmp1472) ; tmp1473 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg0), atslab_d0exp_loc) ; tmp1474 = p0atopt_some (arg1) ; tmp1469 = ATS_MALLOC(sizeof(anairiats_rec_74)) ; ats_selptrset_mac(anairiats_rec_74, tmp1469, atslab_m0atch_loc, tmp1473) ; ats_selptrset_mac(anairiats_rec_74, tmp1469, atslab_m0atch_exp, arg0) ; ats_selptrset_mac(anairiats_rec_74, tmp1469, atslab_m0atch_pat, tmp1474) ; return (tmp1469) ; } /* end of [m0atch_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67332(line=2478, offs=25) -- 67343(line=2478, offs=36) */ ATSglobaldec() ats_ptr_type m0atchlst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1475) ; __ats_lab_m0atchlst_nil: tmp1475 = (ats_sum_ptr_type)0 ; return (tmp1475) ; } /* end of [m0atchlst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67369(line=2479, offs=26) -- 67391(line=2479, offs=48) */ ATSglobaldec() ats_ptr_type m0atchlst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1476) ; __ats_lab_m0atchlst_cons: tmp1476 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1476, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1476, atslab_1, arg1) ; return (tmp1476) ; } /* end of [m0atchlst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67439(line=2483, offs=29) -- 67528(line=2485, offs=2) */ ATSglobaldec() ats_ptr_type guap0at_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1477) ; ATSlocal (ats_ptr_type, tmp1478) ; ATSlocal (ats_ptr_type, tmp1479) ; __ats_lab_guap0at_make_none: tmp1478 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1479 = m0atchlst_nil () ; tmp1477 = ATS_MALLOC(sizeof(anairiats_rec_75)) ; ats_selptrset_mac(anairiats_rec_75, tmp1477, atslab_guap0at_loc, tmp1478) ; ats_selptrset_mac(anairiats_rec_75, tmp1477, atslab_guap0at_pat, arg0) ; ats_selptrset_mac(anairiats_rec_75, tmp1477, atslab_guap0at_gua, tmp1479) ; return (tmp1477) ; } /* end of [guap0at_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67662(line=2489, offs=9) -- 67816(line=2492, offs=28) */ ATSstaticdec() ats_ptr_type aux1_460 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1481) ; ATSlocal (ats_ptr_type, tmp1482) ; ATSlocal (ats_ptr_type, tmp1483) ; __ats_lab_aux1_460: do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp1482 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1483 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1481 = aux2_461 (arg0, tmp1482, tmp1483) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: tmp1481 = arg0 ; break ; } while (0) ; return (tmp1481) ; } /* end of [aux1_460] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67825(line=2493, offs=9) -- 68026(line=2497, offs=55) */ ATSstaticdec() ats_ptr_type aux2_461 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1484) ; ATSlocal (ats_ptr_type, tmp1485) ; ATSlocal (ats_ptr_type, tmp1486) ; ATSlocal (ats_ptr_type, tmp1487) ; __ats_lab_aux2_461: do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp1485 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1486 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1485 ; arg2 = tmp1486 ; goto __ats_lab_aux2_461 ; // tail call break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_163_1: tmp1487 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_74, arg1), atslab_m0atch_loc) ; tmp1484 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (arg0, tmp1487) ; break ; } while (0) ; return (tmp1484) ; } /* end of [aux2_461] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 67588(line=2487, offs=29) -- 68126(line=2501, offs=6) */ ATSglobaldec() ats_ptr_type guap0at_make_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1480) ; ATSlocal (ats_ptr_type, tmp1488) ; ATSlocal (ats_ptr_type, tmp1489) ; ATSlocal (ats_ptr_type, tmp1490) ; __ats_lab_guap0at_make_some: tmp1489 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1488 = aux1_460 (tmp1489, arg1) ; tmp1490 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1480 = ATS_MALLOC(sizeof(anairiats_rec_75)) ; ats_selptrset_mac(anairiats_rec_75, tmp1480, atslab_guap0at_loc, tmp1490) ; ats_selptrset_mac(anairiats_rec_75, tmp1480, atslab_guap0at_pat, arg0) ; ats_selptrset_mac(anairiats_rec_75, tmp1480, atslab_guap0at_gua, arg1) ; return (tmp1480) ; } /* end of [guap0at_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68200(line=2506, offs=3) -- 68252(line=2506, offs=55) */ ATSglobaldec() ats_ptr_type ifhead_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1491) ; __ats_lab_ifhead_make: tmp1491 = ATS_MALLOC(sizeof(anairiats_rec_70)) ; ats_selptrset_mac(anairiats_rec_70, tmp1491, atslab_ifhead_tok, arg0) ; ats_selptrset_mac(anairiats_rec_70, tmp1491, atslab_ifhead_inv, arg1) ; return (tmp1491) ; } /* end of [ifhead_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68302(line=2509, offs=25) -- 68384(line=2511, offs=2) */ ATSglobaldec() ats_ptr_type casehead_make (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1492) ; __ats_lab_casehead_make: tmp1492 = ATS_MALLOC(sizeof(anairiats_rec_66)) ; ats_selptrset_mac(anairiats_rec_66, tmp1492, atslab_casehead_tok, arg1) ; ats_selptrset_mac(anairiats_rec_66, tmp1492, atslab_casehead_knd, arg0) ; ats_selptrset_mac(anairiats_rec_66, tmp1492, atslab_casehead_inv, arg2) ; return (tmp1492) ; } /* end of [casehead_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68441(line=2514, offs=20) -- 68502(line=2516, offs=2) */ ATSglobaldec() ats_ptr_type loophead_make_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1493) ; ATSlocal (ats_ptr_type, tmp1494) ; __ats_lab_loophead_make_none: tmp1494 = (ats_sum_ptr_type)0 ; tmp1493 = ATS_MALLOC(sizeof(anairiats_rec_68)) ; ats_selptrset_mac(anairiats_rec_68, tmp1493, atslab_loophead_tok, arg0) ; ats_selptrset_mac(anairiats_rec_68, tmp1493, atslab_loophead_inv, tmp1494) ; return (tmp1493) ; } /* end of [loophead_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68564(line=2519, offs=20) -- 68705(line=2523, offs=6) */ ATSglobaldec() ats_ptr_type loophead_make_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1495) ; ATSlocal (ats_ptr_type, tmp1496) ; ATSlocal (ats_ptr_type, tmp1497) ; ATSlocal (ats_ptr_type, tmp1498) ; ATSlocal (ats_ptr_type, tmp1499) ; __ats_lab_loophead_make_some: tmp1497 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1498 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1496 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1497, tmp1498) ; tmp1499 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1499, atslab_0, arg1) ; tmp1495 = ATS_MALLOC(sizeof(anairiats_rec_68)) ; ats_selptrset_mac(anairiats_rec_68, tmp1495, atslab_loophead_tok, arg0) ; ats_selptrset_mac(anairiats_rec_68, tmp1495, atslab_loophead_inv, tmp1499) ; return (tmp1495) ; } /* end of [loophead_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68761(line=2525, offs=24) -- 68831(line=2527, offs=2) */ ATSglobaldec() ats_ptr_type tryhead_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1500) ; ATSlocal (ats_ptr_type, tmp1501) ; __ats_lab_tryhead_make: tmp1501 = i0nvresstate_none () ; tmp1500 = ATS_MALLOC(sizeof(anairiats_rec_73)) ; ats_selptrset_mac(anairiats_rec_73, tmp1500, atslab_tryhead_tok, arg0) ; ats_selptrset_mac(anairiats_rec_73, tmp1500, atslab_tryhead_inv, tmp1501) ; return (tmp1500) ; } /* end of [tryhead_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 68900(line=2532, offs=12) -- 69083(line=2540, offs=6) */ ATSglobaldec() ats_ptr_type c0lau_make (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1502) ; ATSlocal (ats_ptr_type, tmp1503) ; ATSlocal (ats_ptr_type, tmp1504) ; ATSlocal (ats_ptr_type, tmp1505) ; __ats_lab_c0lau_make: tmp1504 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_75, arg0), atslab_guap0at_loc) ; tmp1505 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg3), atslab_d0exp_loc) ; tmp1503 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1504, tmp1505) ; tmp1502 = ATS_MALLOC(sizeof(anairiats_rec_65)) ; ats_selptrset_mac(anairiats_rec_65, tmp1502, atslab_c0lau_loc, tmp1503) ; ats_selptrset_mac(anairiats_rec_65, tmp1502, atslab_c0lau_pat, arg0) ; ats_selptrset_mac(anairiats_rec_65, tmp1502, atslab_c0lau_seq, arg1) ; ats_selptrset_mac(anairiats_rec_65, tmp1502, atslab_c0lau_neg, arg2) ; ats_selptrset_mac(anairiats_rec_65, tmp1502, atslab_c0lau_body, arg3) ; return (tmp1502) ; } /* end of [c0lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69131(line=2542, offs=24) -- 69142(line=2542, offs=35) */ ATSglobaldec() ats_ptr_type c0laulst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1506) ; __ats_lab_c0laulst_nil: tmp1506 = (ats_sum_ptr_type)0 ; return (tmp1506) ; } /* end of [c0laulst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69167(line=2543, offs=25) -- 69189(line=2543, offs=47) */ ATSglobaldec() ats_ptr_type c0laulst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1507) ; __ats_lab_c0laulst_cons: tmp1507 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1507, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1507, atslab_1, arg1) ; return (tmp1507) ; } /* end of [c0laulst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69213(line=2546, offs=13) -- 69348(line=2550, offs=6) */ ATSglobaldec() ats_ptr_type sc0lau_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1508) ; ATSlocal (ats_ptr_type, tmp1509) ; ATSlocal (ats_ptr_type, tmp1510) ; ATSlocal (ats_ptr_type, tmp1511) ; __ats_lab_sc0lau_make: tmp1510 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_35, arg0), atslab_sp0at_loc) ; tmp1511 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1509 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1510, tmp1511) ; tmp1508 = ATS_MALLOC(sizeof(anairiats_rec_72)) ; ats_selptrset_mac(anairiats_rec_72, tmp1508, atslab_sc0lau_loc, tmp1509) ; ats_selptrset_mac(anairiats_rec_72, tmp1508, atslab_sc0lau_pat, arg0) ; ats_selptrset_mac(anairiats_rec_72, tmp1508, atslab_sc0lau_body, arg1) ; return (tmp1508) ; } /* end of [sc0lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69398(line=2552, offs=25) -- 69409(line=2552, offs=36) */ ATSglobaldec() ats_ptr_type sc0laulst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1512) ; __ats_lab_sc0laulst_nil: tmp1512 = (ats_sum_ptr_type)0 ; return (tmp1512) ; } /* end of [sc0laulst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69435(line=2553, offs=26) -- 69457(line=2553, offs=48) */ ATSglobaldec() ats_ptr_type sc0laulst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1513) ; __ats_lab_sc0laulst_cons: tmp1513 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1513, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1513, atslab_1, arg1) ; return (tmp1513) ; } /* end of [sc0laulst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 69503(line=2557, offs=24) -- 70013(line=2572, offs=6) */ ATSglobaldec() ats_ptr_type v0aldec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1514) ; ATSlocal (ats_ptr_type, tmp1515) ; ATSlocal (ats_ptr_type, tmp1516) ; ATSlocal (ats_ptr_type, tmp1517) ; ATSlocal (ats_ptr_type, tmp1518) ; ATSlocal (ats_ptr_type, tmp1519) ; ATSlocal (ats_ptr_type, tmp1520) ; ATSlocal (ats_ptr_type, tmp1521) ; ATSlocal (ats_ptr_type, tmp1522) ; ATSlocal (ats_ptr_type, tmp1523) ; ATSlocal (ats_ptr_type, tmp1524) ; ATSlocal (ats_ptr_type, tmp1525) ; ATSlocal (ats_ptr_type, tmp1526) ; ATSlocal (ats_ptr_type, tmp1527) ; ATSlocal (ats_ptr_type, tmp1528) ; ATSlocal (ats_ptr_type, tmp1529) ; __ats_lab_v0aldec_make: do { /* branch: __ats_lab_164 */ __ats_lab_164_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_165_0 ; } __ats_lab_164_1: tmp1516 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1517 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1515 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1516, tmp1517) ; break ; /* branch: __ats_lab_165 */ __ats_lab_165_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp1518 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp1519 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1520 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1518), atslab_s0exp_loc) ; tmp1515 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1519, tmp1520) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp1521 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp1522 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1523 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1521), atslab_s0exp_loc) ; tmp1515 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1522, tmp1523) ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)arg2)->tag != 3) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp1524 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp1525 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1526 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1524), atslab_s0exp_loc) ; tmp1515 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1525, tmp1526) ; break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: // if (((ats_sum_ptr_type)arg2)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_168_1: tmp1527 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp1528 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_60, arg0), atslab_p0at_loc) ; tmp1529 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1527), atslab_s0exp_loc) ; tmp1515 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1528, tmp1529) ; break ; } while (0) ; tmp1514 = ATS_MALLOC(sizeof(anairiats_rec_76)) ; ats_selptrset_mac(anairiats_rec_76, tmp1514, atslab_v0aldec_loc, tmp1515) ; ats_selptrset_mac(anairiats_rec_76, tmp1514, atslab_v0aldec_pat, arg0) ; ats_selptrset_mac(anairiats_rec_76, tmp1514, atslab_v0aldec_def, arg1) ; ats_selptrset_mac(anairiats_rec_76, tmp1514, atslab_v0aldec_ann, arg2) ; return (tmp1514) ; } /* end of [v0aldec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 70065(line=2574, offs=26) -- 70076(line=2574, offs=37) */ ATSglobaldec() ats_ptr_type v0aldeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1530) ; __ats_lab_v0aldeclst_nil: tmp1530 = (ats_sum_ptr_type)0 ; return (tmp1530) ; } /* end of [v0aldeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 70103(line=2575, offs=27) -- 70125(line=2575, offs=49) */ ATSglobaldec() ats_ptr_type v0aldeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1531) ; __ats_lab_v0aldeclst_cons: tmp1531 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1531, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1531, atslab_1, arg1) ; return (tmp1531) ; } /* end of [v0aldeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 70152(line=2579, offs=5) -- 70863(line=2608, offs=6) */ ATSstaticdec() ats_ptr_type f0undec_make_476 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1532) ; ATSlocal (ats_ptr_type, tmp1533) ; ATSlocal (ats_ptr_type, tmp1534) ; ATSlocal (ats_ptr_type, tmp1535) ; ATSlocal (ats_ptr_type, tmp1536) ; ATSlocal (ats_ptr_type, tmp1537) ; ATSlocal (ats_ptr_type, tmp1538) ; ATSlocal (ats_ptr_type, tmp1539) ; ATSlocal (ats_ptr_type, tmp1540) ; ATSlocal (ats_ptr_type, tmp1541) ; ATSlocal (ats_ptr_type, tmp1542) ; ATSlocal (ats_ptr_type, tmp1543) ; ATSlocal (ats_ptr_type, tmp1544) ; ATSlocal (ats_ptr_type, tmp1545) ; ATSlocal (ats_ptr_type, tmp1546) ; ATSlocal (ats_ptr_type, tmp1547) ; ATSlocal (ats_ptr_type, tmp1548) ; ATSlocal (ats_ptr_type, tmp1549) ; __ats_lab_f0undec_make_476: do { /* branch: __ats_lab_169 */ __ats_lab_169_0: if (((ats_sum_ptr_type)arg5)->tag != 0) { goto __ats_lab_170_0 ; } __ats_lab_169_1: tmp1534 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1535 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg4), atslab_d0exp_loc) ; tmp1533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1534, tmp1535) ; break ; /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)arg5)->tag != 1) { goto __ats_lab_171_0 ; } __ats_lab_170_1: tmp1536 = ats_caselptrlab_mac(anairiats_sum_0, arg5, atslab_0) ; tmp1537 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1538 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1536), atslab_s0exp_loc) ; tmp1533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1537, tmp1538) ; break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (((ats_sum_ptr_type)arg5)->tag != 2) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp1539 = ats_caselptrlab_mac(anairiats_sum_0, arg5, atslab_0) ; tmp1540 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1541 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1539), atslab_s0exp_loc) ; tmp1533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1540, tmp1541) ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: if (((ats_sum_ptr_type)arg5)->tag != 3) { goto __ats_lab_173_0 ; } __ats_lab_172_1: tmp1542 = ats_caselptrlab_mac(anairiats_sum_0, arg5, atslab_0) ; tmp1543 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1544 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1542), atslab_s0exp_loc) ; tmp1533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1543, tmp1544) ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: // if (((ats_sum_ptr_type)arg5)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_173_1: tmp1545 = ats_caselptrlab_mac(anairiats_sum_0, arg5, atslab_0) ; tmp1546 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1547 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, tmp1545), atslab_s0exp_loc) ; tmp1533 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1546, tmp1547) ; break ; } while (0) ; tmp1548 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1549 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1532 = ATS_MALLOC(sizeof(anairiats_rec_77)) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_loc, tmp1533) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_sym, tmp1548) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_sym_loc, tmp1549) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_arg, arg1) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_eff, arg2) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_res, arg3) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_def, arg4) ; ats_selptrset_mac(anairiats_rec_77, tmp1532, atslab_f0undec_ann, arg5) ; return (tmp1532) ; } /* end of [f0undec_make_476] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 70920(line=2611, offs=3) -- 71017(line=2613, offs=2) */ ATSglobaldec() ats_ptr_type f0undec_make_none (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1550) ; ATSlocal (ats_ptr_type, tmp1551) ; ATSlocal (ats_ptr_type, tmp1552) ; __ats_lab_f0undec_make_none: tmp1551 = e0fftaglstopt_none () ; tmp1552 = s0expopt_none () ; tmp1550 = f0undec_make_476 (arg0, arg1, tmp1551, tmp1552, arg2, arg3) ; return (tmp1550) ; } /* end of [f0undec_make_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71077(line=2615, offs=29) -- 71158(line=2616, offs=50) */ ATSglobaldec() ats_ptr_type f0undec_make_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1553) ; ATSlocal (ats_ptr_type, tmp1554) ; __ats_lab_f0undec_make_some: tmp1554 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1554, atslab_0, arg3) ; tmp1553 = f0undec_make_476 (arg0, arg1, arg2, tmp1554, arg4, arg5) ; return (tmp1553) ; } /* end of [f0undec_make_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71185(line=2618, offs=26) -- 71196(line=2618, offs=37) */ ATSglobaldec() ats_ptr_type f0undeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1555) ; __ats_lab_f0undeclst_nil: tmp1555 = (ats_sum_ptr_type)0 ; return (tmp1555) ; } /* end of [f0undeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71223(line=2619, offs=27) -- 71245(line=2619, offs=49) */ ATSglobaldec() ats_ptr_type f0undeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1556) ; __ats_lab_f0undeclst_cons: tmp1556 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1556, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1556, atslab_1, arg1) ; return (tmp1556) ; } /* end of [f0undeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71291(line=2623, offs=24) -- 71303(line=2623, offs=36) */ ATSglobaldec() ats_ptr_type v0arwth_none () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1557) ; __ats_lab_v0arwth_none: tmp1557 = (ats_sum_ptr_type)0 ; return (tmp1557) ; } /* end of [v0arwth_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71327(line=2624, offs=24) -- 71342(line=2624, offs=39) */ ATSglobaldec() ats_ptr_type v0arwth_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1558) ; __ats_lab_v0arwth_some: tmp1558 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1558, atslab_0, arg0) ; return (tmp1558) ; } /* end of [v0arwth_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71348(line=2626, offs=4) -- 71630(line=2641, offs=2) */ ATSstaticdec() ats_ptr_type v0ardec_make_483 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1559) ; ATSlocal (ats_ptr_type, tmp1560) ; ATSlocal (ats_ptr_type, tmp1561) ; __ats_lab_v0ardec_make_483: tmp1560 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_i0de_sym) ; tmp1561 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg2), atslab_i0de_loc) ; tmp1559 = ATS_MALLOC(sizeof(anairiats_rec_78)) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_knd, arg1) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_sym, tmp1560) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_sym_loc, tmp1561) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_typ, arg3) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_wth, arg4) ; ats_selptrset_mac(anairiats_rec_78, tmp1559, atslab_v0ardec_ini, arg5) ; return (tmp1559) ; } /* end of [v0ardec_make_483] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71693(line=2644, offs=26) -- 71885(line=2650, offs=4) */ ATSglobaldec() ats_ptr_type v0ardec_make_some_none (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1562) ; ATSlocal (ats_ptr_type, tmp1563) ; ATSlocal (ats_ptr_type, tmp1564) ; ATSlocal (ats_ptr_type, tmp1565) ; ATSlocal (ats_ptr_type, tmp1566) ; ATSlocal (ats_ptr_type, tmp1567) ; __ats_lab_v0ardec_make_some_none: tmp1564 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1565 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg2), atslab_s0exp_loc) ; tmp1563 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1564, tmp1565) ; tmp1566 = s0expopt_some (arg2) ; tmp1567 = d0expopt_none () ; tmp1562 = v0ardec_make_483 (tmp1563, arg0, arg1, tmp1566, arg3, tmp1567) ; return (tmp1562) ; } /* end of [v0ardec_make_some_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 71957(line=2653, offs=26) -- 72149(line=2659, offs=4) */ ATSglobaldec() ats_ptr_type v0ardec_make_none_some (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1568) ; ATSlocal (ats_ptr_type, tmp1569) ; ATSlocal (ats_ptr_type, tmp1570) ; ATSlocal (ats_ptr_type, tmp1571) ; ATSlocal (ats_ptr_type, tmp1572) ; ATSlocal (ats_ptr_type, tmp1573) ; __ats_lab_v0ardec_make_none_some: tmp1570 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1571 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg3), atslab_d0exp_loc) ; tmp1569 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1570, tmp1571) ; tmp1572 = s0expopt_none () ; tmp1573 = d0expopt_some (arg3) ; tmp1568 = v0ardec_make_483 (tmp1569, arg0, arg1, tmp1572, arg2, tmp1573) ; return (tmp1568) ; } /* end of [v0ardec_make_none_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72221(line=2662, offs=26) -- 72419(line=2668, offs=4) */ ATSglobaldec() ats_ptr_type v0ardec_make_some_some (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1574) ; ATSlocal (ats_ptr_type, tmp1575) ; ATSlocal (ats_ptr_type, tmp1576) ; ATSlocal (ats_ptr_type, tmp1577) ; ATSlocal (ats_ptr_type, tmp1578) ; ATSlocal (ats_ptr_type, tmp1579) ; __ats_lab_v0ardec_make_some_some: tmp1576 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1577 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg4), atslab_d0exp_loc) ; tmp1575 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1576, tmp1577) ; tmp1578 = s0expopt_some (arg2) ; tmp1579 = d0expopt_some (arg4) ; tmp1574 = v0ardec_make_483 (tmp1575, arg0, arg1, tmp1578, arg3, tmp1579) ; return (tmp1574) ; } /* end of [v0ardec_make_some_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72481(line=2670, offs=26) -- 72492(line=2670, offs=37) */ ATSglobaldec() ats_ptr_type v0ardeclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1580) ; __ats_lab_v0ardeclst_nil: tmp1580 = (ats_sum_ptr_type)0 ; return (tmp1580) ; } /* end of [v0ardeclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72519(line=2671, offs=27) -- 72541(line=2671, offs=49) */ ATSglobaldec() ats_ptr_type v0ardeclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1581) ; __ats_lab_v0ardeclst_cons: tmp1581 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1581, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1581, atslab_1, arg1) ; return (tmp1581) ; } /* end of [v0ardeclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72587(line=2676, offs=14) -- 72752(line=2683, offs=6) */ ATSglobaldec() ats_ptr_type m0acdef_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1582) ; ATSlocal (ats_ptr_type, tmp1583) ; ATSlocal (ats_ptr_type, tmp1584) ; ATSlocal (ats_ptr_type, tmp1585) ; ATSlocal (ats_ptr_type, tmp1586) ; __ats_lab_m0acdef_make: tmp1584 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1585 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg2), atslab_d0exp_loc) ; tmp1583 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1584, tmp1585) ; tmp1586 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1582 = ATS_MALLOC(sizeof(anairiats_rec_79)) ; ats_selptrset_mac(anairiats_rec_79, tmp1582, atslab_m0acdef_loc, tmp1583) ; ats_selptrset_mac(anairiats_rec_79, tmp1582, atslab_m0acdef_sym, tmp1586) ; ats_selptrset_mac(anairiats_rec_79, tmp1582, atslab_m0acdef_arg, arg1) ; ats_selptrset_mac(anairiats_rec_79, tmp1582, atslab_m0acdef_def, arg2) ; return (tmp1582) ; } /* end of [m0acdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72804(line=2685, offs=26) -- 72815(line=2685, offs=37) */ ATSglobaldec() ats_ptr_type m0acdeflst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1587) ; __ats_lab_m0acdeflst_nil: tmp1587 = (ats_sum_ptr_type)0 ; return (tmp1587) ; } /* end of [m0acdeflst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72842(line=2686, offs=27) -- 72864(line=2686, offs=49) */ ATSglobaldec() ats_ptr_type m0acdeflst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1588) ; __ats_lab_m0acdeflst_cons: tmp1588 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1588, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1588, atslab_1, arg1) ; return (tmp1588) ; } /* end of [m0acdeflst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 72912(line=2692, offs=3) -- 73099(line=2700, offs=6) */ ATSglobaldec() ats_ptr_type i0mpdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1589) ; ATSlocal (ats_ptr_type, tmp1590) ; ATSlocal (ats_ptr_type, tmp1591) ; ATSlocal (ats_ptr_type, tmp1592) ; __ats_lab_i0mpdec_make: tmp1591 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_44, arg0), atslab_impqi0de_loc) ; tmp1592 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg3), atslab_d0exp_loc) ; tmp1590 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1591, tmp1592) ; tmp1589 = ATS_MALLOC(sizeof(anairiats_rec_80)) ; ats_selptrset_mac(anairiats_rec_80, tmp1589, atslab_i0mpdec_loc, tmp1590) ; ats_selptrset_mac(anairiats_rec_80, tmp1589, atslab_i0mpdec_qid, arg0) ; ats_selptrset_mac(anairiats_rec_80, tmp1589, atslab_i0mpdec_arg, arg1) ; ats_selptrset_mac(anairiats_rec_80, tmp1589, atslab_i0mpdec_res, arg2) ; ats_selptrset_mac(anairiats_rec_80, tmp1589, atslab_i0mpdec_def, arg3) ; return (tmp1589) ; } /* end of [i0mpdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 73199(line=2710, offs=5) -- 73360(line=2714, offs=42) */ ATSstaticdec() ats_ptr_type aux1_loc_493 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1593) ; ATSlocal (ats_ptr_type, tmp1594) ; ATSlocal (ats_ptr_type, tmp1595) ; ATSlocal (ats_ptr_type, tmp1596) ; __ats_lab_aux1_loc_493: do { /* branch: __ats_lab_174 */ __ats_lab_174_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp1594 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1595 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1594 ; arg2 = tmp1595 ; goto __ats_lab_aux1_loc_493 ; // tail call break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_175_1: tmp1596 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1593 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (arg0, tmp1596) ; break ; } while (0) ; return (tmp1593) ; } /* end of [aux1_loc_493] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 73387(line=2717, offs=5) -- 73513(line=2720, offs=19) */ ATSstaticdec() ats_ptr_type aux2_loc_494 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1597) ; ATSlocal (ats_ptr_type, tmp1598) ; ATSlocal (ats_ptr_type, tmp1599) ; __ats_lab_aux2_loc_494: do { /* branch: __ats_lab_176 */ __ats_lab_176_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_177_0 ; } __ats_lab_176_1: tmp1598 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1599 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1597 = aux1_loc_493 (arg0, tmp1598, tmp1599) ; break ; /* branch: __ats_lab_177 */ __ats_lab_177_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_177_1: tmp1597 = arg0 ; break ; } while (0) ; return (tmp1597) ; } /* end of [aux2_loc_494] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 73581(line=2726, offs=12) -- 73872(line=2738, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_infix (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1600) ; ATSlocal (ats_ptr_type, tmp1601) ; ATSlocal (ats_ptr_type, tmp1602) ; ATSlocal (ats_ptr_type, tmp1603) ; ATSlocal (ats_ptr_type, tmp1604) ; ATSlocal (ats_ptr_type, tmp1605) ; __ats_lab_d0ec_infix: tmp1602 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1601 = aux2_loc_494 (tmp1602, arg3) ; do { /* branch: __ats_lab_178 */ __ats_lab_178_0: if (arg2 != -1) { goto __ats_lab_179_0 ; } __ats_lab_178_1: tmp1603 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOClft_1) ; break ; /* branch: __ats_lab_179 */ __ats_lab_179_0: if (arg2 != 1) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp1603 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCrgt_2) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: __ats_lab_180_1: tmp1603 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__ASSOCnon_0) ; break ; } while (0) ; tmp1605 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1605)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1605, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1605, atslab_1, tmp1603) ; tmp1604 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1604)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1604, atslab_0, tmp1605) ; ats_selptrset_mac(anairiats_sum_15, tmp1604, atslab_1, arg3) ; tmp1600 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1600, atslab_d0ec_loc, tmp1601) ; ats_selptrset_mac(anairiats_rec_81, tmp1600, atslab_d0ec_node, tmp1604) ; return (tmp1600) ; } /* end of [d0ec_infix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 73919(line=2740, offs=23) -- 74056(line=2744, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_prefix (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1606) ; ATSlocal (ats_ptr_type, tmp1607) ; ATSlocal (ats_ptr_type, tmp1608) ; ATSlocal (ats_ptr_type, tmp1609) ; ATSlocal (ats_ptr_type, tmp1610) ; __ats_lab_d0ec_prefix: tmp1608 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1607 = aux2_loc_494 (tmp1608, arg2) ; tmp1610 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1610)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1610, atslab_0, arg1) ; tmp1609 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1609)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1609, atslab_0, tmp1610) ; ats_selptrset_mac(anairiats_sum_15, tmp1609, atslab_1, arg2) ; tmp1606 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1606, atslab_d0ec_loc, tmp1607) ; ats_selptrset_mac(anairiats_rec_81, tmp1606, atslab_d0ec_node, tmp1609) ; return (tmp1606) ; } /* end of [d0ec_prefix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74105(line=2746, offs=24) -- 74244(line=2750, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_postfix (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1611) ; ATSlocal (ats_ptr_type, tmp1612) ; ATSlocal (ats_ptr_type, tmp1613) ; ATSlocal (ats_ptr_type, tmp1614) ; ATSlocal (ats_ptr_type, tmp1615) ; __ats_lab_d0ec_postfix: tmp1613 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1612 = aux2_loc_494 (tmp1613, arg2) ; tmp1615 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1615)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp1615, atslab_0, arg1) ; tmp1614 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1614)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1614, atslab_0, tmp1615) ; ats_selptrset_mac(anairiats_sum_15, tmp1614, atslab_1, arg2) ; tmp1611 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1611, atslab_d0ec_loc, tmp1612) ; ats_selptrset_mac(anairiats_rec_81, tmp1611, atslab_d0ec_node, tmp1614) ; return (tmp1611) ; } /* end of [d0ec_postfix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74293(line=2752, offs=23) -- 74428(line=2756, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_nonfix (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1616) ; ATSlocal (ats_ptr_type, tmp1617) ; ATSlocal (ats_ptr_type, tmp1618) ; ATSlocal (ats_ptr_type, tmp1619) ; ATSlocal (ats_ptr_type, tmp1620) ; __ats_lab_d0ec_nonfix: tmp1618 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1617 = aux2_loc_494 (tmp1618, arg1) ; tmp1619 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1620 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1620)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1620, atslab_0, arg1) ; tmp1616 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1616, atslab_d0ec_loc, tmp1619) ; ats_selptrset_mac(anairiats_rec_81, tmp1616, atslab_d0ec_node, tmp1620) ; return (tmp1616) ; } /* end of [d0ec_nonfix] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74521(line=2762, offs=24) -- 74612(line=2764, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_include (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1621) ; ATSlocal (ats_ptr_type, tmp1622) ; ATSlocal (ats_ptr_type, tmp1623) ; ATSlocal (ats_ptr_type, tmp1624) ; __ats_lab_d0ec_include: tmp1622 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0tring_loc) ; tmp1624 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0tring_val) ; tmp1623 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1623)->tag = 2 ; ats_selptrset_mac(anairiats_sum_24, tmp1623, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_24, tmp1623, atslab_1, tmp1624) ; tmp1621 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1621, atslab_d0ec_loc, tmp1622) ; ats_selptrset_mac(anairiats_rec_81, tmp1621, atslab_d0ec_node, tmp1623) ; return (tmp1621) ; } /* end of [d0ec_include] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74683(line=2768, offs=24) -- 74764(line=2770, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_symintr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1625) ; ATSlocal (ats_ptr_type, tmp1626) ; ATSlocal (ats_ptr_type, tmp1627) ; __ats_lab_d0ec_symintr: tmp1626 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1627 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1627)->tag = 3 ; ats_selptrset_mac(anairiats_sum_0, tmp1627, atslab_0, arg1) ; tmp1625 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1625, atslab_d0ec_loc, tmp1626) ; ats_selptrset_mac(anairiats_rec_81, tmp1625, atslab_d0ec_node, tmp1627) ; return (tmp1625) ; } /* end of [d0ec_symintr] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74837(line=2774, offs=26) -- 74911(line=2776, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_e0xpundef (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1628) ; ATSlocal (ats_ptr_type, tmp1629) ; ATSlocal (ats_ptr_type, tmp1630) ; ATSlocal (ats_ptr_type, tmp1631) ; __ats_lab_d0ec_e0xpundef: tmp1629 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1631 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1630 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1630)->tag = 4 ; ats_selptrset_mac(anairiats_sum_0, tmp1630, atslab_0, tmp1631) ; tmp1628 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1628, atslab_d0ec_loc, tmp1629) ; ats_selptrset_mac(anairiats_rec_81, tmp1628, atslab_d0ec_node, tmp1630) ; return (tmp1628) ; } /* end of [d0ec_e0xpundef] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 74963(line=2778, offs=24) -- 75178(line=2785, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_e0xpdef (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1632) ; ATSlocal (ats_ptr_type, tmp1633) ; ATSlocal (ats_ptr_type, tmp1634) ; ATSlocal (ats_ptr_type, tmp1635) ; ATSlocal (ats_ptr_type, tmp1636) ; ATSlocal (ats_ptr_type, tmp1637) ; ATSlocal (ats_ptr_type, tmp1638) ; __ats_lab_d0ec_e0xpdef: do { /* branch: __ats_lab_181 */ __ats_lab_181_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp1634 = ats_caselptrlab_mac(anairiats_sum_13, arg1, atslab_0) ; tmp1635 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1636 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, tmp1634), atslab_e0xp_loc) ; tmp1633 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1635, tmp1636) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_182_1: tmp1633 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; break ; } while (0) ; tmp1638 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1637 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1637)->tag = 5 ; ats_selptrset_mac(anairiats_sum_15, tmp1637, atslab_0, tmp1638) ; ats_selptrset_mac(anairiats_sum_15, tmp1637, atslab_1, arg1) ; tmp1632 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1632, atslab_d0ec_loc, tmp1633) ; ats_selptrset_mac(anairiats_rec_81, tmp1632, atslab_d0ec_node, tmp1637) ; return (tmp1632) ; } /* end of [d0ec_e0xpdef] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 75256(line=2789, offs=31) -- 75331(line=2791, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_e0xpact_assert (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1639) ; ATSlocal (ats_ptr_type, tmp1640) ; ATSlocal (ats_ptr_type, tmp1641) ; ATSlocal (ats_ptr_type, tmp1642) ; __ats_lab_d0ec_e0xpact_assert: tmp1640 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_e0xp_loc) ; tmp1642 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTassert_0) ; tmp1641 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1641)->tag = 6 ; ats_selptrset_mac(anairiats_sum_15, tmp1641, atslab_0, tmp1642) ; ats_selptrset_mac(anairiats_sum_15, tmp1641, atslab_1, arg0) ; tmp1639 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1639, atslab_d0ec_loc, tmp1640) ; ats_selptrset_mac(anairiats_rec_81, tmp1639, atslab_d0ec_node, tmp1641) ; return (tmp1639) ; } /* end of [d0ec_e0xpact_assert] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 75394(line=2793, offs=30) -- 75468(line=2795, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_e0xpact_error (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1643) ; ATSlocal (ats_ptr_type, tmp1644) ; ATSlocal (ats_ptr_type, tmp1645) ; ATSlocal (ats_ptr_type, tmp1646) ; __ats_lab_d0ec_e0xpact_error: tmp1644 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_e0xp_loc) ; tmp1646 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTerror_1) ; tmp1645 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1645)->tag = 6 ; ats_selptrset_mac(anairiats_sum_15, tmp1645, atslab_0, tmp1646) ; ats_selptrset_mac(anairiats_sum_15, tmp1645, atslab_1, arg0) ; tmp1643 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1643, atslab_d0ec_loc, tmp1644) ; ats_selptrset_mac(anairiats_rec_81, tmp1643, atslab_d0ec_node, tmp1645) ; return (tmp1643) ; } /* end of [d0ec_e0xpact_error] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 75530(line=2797, offs=30) -- 75604(line=2799, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_e0xpact_print (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1647) ; ATSlocal (ats_ptr_type, tmp1648) ; ATSlocal (ats_ptr_type, tmp1649) ; ATSlocal (ats_ptr_type, tmp1650) ; __ats_lab_d0ec_e0xpact_print: tmp1648 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_e0xp_loc) ; tmp1650 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0XPACTprint_2) ; tmp1649 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1649)->tag = 6 ; ats_selptrset_mac(anairiats_sum_15, tmp1649, atslab_0, tmp1650) ; ats_selptrset_mac(anairiats_sum_15, tmp1649, atslab_1, arg0) ; tmp1647 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1647, atslab_d0ec_loc, tmp1648) ; ats_selptrset_mac(anairiats_rec_81, tmp1647, atslab_d0ec_node, tmp1649) ; return (tmp1647) ; } /* end of [d0ec_e0xpact_print] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 75702(line=2804, offs=7) -- 75874(line=2807, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_507 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1652) ; ATSlocal (ats_ptr_type, tmp1653) ; ATSlocal (ats_ptr_type, tmp1654) ; ATSlocal (ats_ptr_type, tmp1655) ; ATSlocal (ats_ptr_type, tmp1656) ; __ats_lab_aux_loc_507: do { /* branch: __ats_lab_183 */ __ats_lab_183_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp1653 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1654 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1653 ; arg2 = tmp1654 ; goto __ats_lab_aux_loc_507 ; // tail call break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_184_1: tmp1655 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_48, arg0), atslab_s0rtdef_loc) ; tmp1656 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_48, arg1), atslab_s0rtdef_loc) ; tmp1652 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1655, tmp1656) ; break ; } while (0) ; return (tmp1652) ; } /* end of [aux_loc_507] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 75681(line=2803, offs=24) -- 76062(line=2814, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_srtdefs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1651) ; ATSlocal (ats_ptr_type, tmp1657) ; ATSlocal (ats_ptr_type, tmp1658) ; ATSlocal (ats_ptr_type, tmp1659) ; ATSlocal (ats_ptr_type, tmp1660) ; __ats_lab_d0ec_srtdefs: do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp1658 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1659 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1657 = aux_loc_507 (arg0, tmp1658, tmp1659) ; break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_186_1: tmp1657 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_48, arg0), atslab_s0rtdef_loc) ; break ; } while (0) ; tmp1660 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1660)->tag = 8 ; ats_selptrset_mac(anairiats_sum_15, tmp1660, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1660, atslab_1, arg1) ; tmp1651 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1651, atslab_d0ec_loc, tmp1657) ; ats_selptrset_mac(anairiats_rec_81, tmp1651, atslab_d0ec_node, tmp1660) ; return (tmp1651) ; } /* end of [d0ec_srtdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 76160(line=2819, offs=7) -- 76351(line=2823, offs=62) */ ATSstaticdec() ats_ptr_type aux_loc_509 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1662) ; ATSlocal (ats_ptr_type, tmp1663) ; ATSlocal (ats_ptr_type, tmp1664) ; ATSlocal (ats_ptr_type, tmp1665) ; ATSlocal (ats_ptr_type, tmp1666) ; __ats_lab_aux_loc_509: do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp1663 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1664 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1663 ; arg2 = tmp1664 ; goto __ats_lab_aux_loc_509 ; // tail call break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_188_1: tmp1665 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg0), atslab_d0atsrtdec_loc) ; tmp1666 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg1), atslab_d0atsrtdec_loc) ; tmp1662 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1665, tmp1666) ; break ; } while (0) ; return (tmp1662) ; } /* end of [aux_loc_509] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 76133(line=2818, offs=24) -- 76526(line=2830, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_datsrts (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1661) ; ATSlocal (ats_ptr_type, tmp1667) ; ATSlocal (ats_ptr_type, tmp1668) ; ATSlocal (ats_ptr_type, tmp1669) ; ATSlocal (ats_ptr_type, tmp1670) ; __ats_lab_d0ec_datsrts: do { /* branch: __ats_lab_189 */ __ats_lab_189_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_190_0 ; } __ats_lab_189_1: tmp1668 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1669 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1667 = aux_loc_509 (arg1, tmp1668, tmp1669) ; break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_190_1: tmp1667 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_21, arg1), atslab_d0atsrtdec_loc) ; break ; } while (0) ; tmp1670 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1670)->tag = 7 ; ats_selptrset_mac(anairiats_sum_40, tmp1670, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp1670, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_40, tmp1670, atslab_2, arg2) ; tmp1661 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1661, atslab_d0ec_loc, tmp1667) ; ats_selptrset_mac(anairiats_rec_81, tmp1661, atslab_d0ec_node, tmp1670) ; return (tmp1661) ; } /* end of [d0ec_datsrts] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 76621(line=2835, offs=7) -- 76793(line=2838, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_511 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1672) ; ATSlocal (ats_ptr_type, tmp1673) ; ATSlocal (ats_ptr_type, tmp1674) ; ATSlocal (ats_ptr_type, tmp1675) ; ATSlocal (ats_ptr_type, tmp1676) ; __ats_lab_aux_loc_511: do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp1673 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1674 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1673 ; arg2 = tmp1674 ; goto __ats_lab_aux_loc_511 ; // tail call break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_192_1: tmp1675 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg0), atslab_s0tacon_loc) ; tmp1676 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg1), atslab_s0tacon_loc) ; tmp1672 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1675, tmp1676) ; break ; } while (0) ; return (tmp1672) ; } /* end of [aux_loc_511] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 76597(line=2834, offs=24) -- 76950(line=2844, offs=4) */ ATSglobaldec() ats_ptr_type d0ec_stacons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1671) ; ATSlocal (ats_ptr_type, tmp1677) ; ATSlocal (ats_ptr_type, tmp1678) ; ATSlocal (ats_ptr_type, tmp1679) ; ATSlocal (ats_ptr_type, tmp1680) ; __ats_lab_d0ec_stacons: do { /* branch: __ats_lab_193 */ __ats_lab_193_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp1678 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1679 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1677 = aux_loc_511 (arg1, tmp1678, tmp1679) ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_194_1: tmp1677 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_49, arg1), atslab_s0tacon_loc) ; break ; } while (0) ; tmp1680 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1680)->tag = 9 ; ats_selptrset_mac(anairiats_sum_38, tmp1680, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1680, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1680, atslab_2, arg2) ; tmp1671 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1671, atslab_d0ec_loc, tmp1677) ; ats_selptrset_mac(anairiats_rec_81, tmp1671, atslab_d0ec_node, tmp1680) ; return (tmp1671) ; } /* end of [d0ec_stacons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77021(line=2847, offs=7) -- 77197(line=2851, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_513 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1682) ; ATSlocal (ats_ptr_type, tmp1683) ; ATSlocal (ats_ptr_type, tmp1684) ; ATSlocal (ats_ptr_type, tmp1685) ; ATSlocal (ats_ptr_type, tmp1686) ; __ats_lab_aux_loc_513: do { /* branch: __ats_lab_195 */ __ats_lab_195_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_196_0 ; } __ats_lab_195_1: tmp1683 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1684 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1683 ; arg2 = tmp1684 ; goto __ats_lab_aux_loc_513 ; // tail call break ; /* branch: __ats_lab_196 */ __ats_lab_196_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_196_1: tmp1685 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_50, arg0), atslab_s0tacst_loc) ; tmp1686 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_50, arg1), atslab_s0tacst_loc) ; tmp1682 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1685, tmp1686) ; break ; } while (0) ; return (tmp1682) ; } /* end of [aux_loc_513] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77000(line=2846, offs=24) -- 77387(line=2860, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_stacsts (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1681) ; ATSlocal (ats_ptr_type, tmp1687) ; ATSlocal (ats_ptr_type, tmp1688) ; ATSlocal (ats_ptr_type, tmp1689) ; ATSlocal (ats_ptr_type, tmp1690) ; __ats_lab_d0ec_stacsts: do { /* branch: __ats_lab_197 */ __ats_lab_197_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_198_0 ; } __ats_lab_197_1: tmp1688 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1689 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1687 = aux_loc_513 (arg0, tmp1688, tmp1689) ; break ; /* branch: __ats_lab_198 */ __ats_lab_198_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_198_1: tmp1687 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_50, arg0), atslab_s0tacst_loc) ; break ; } while (0) ; tmp1690 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1690)->tag = 10 ; ats_selptrset_mac(anairiats_sum_15, tmp1690, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1690, atslab_1, arg1) ; tmp1681 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1681, atslab_d0ec_loc, tmp1687) ; ats_selptrset_mac(anairiats_rec_81, tmp1681, atslab_d0ec_node, tmp1690) ; return (tmp1681) ; } /* end of [d0ec_stacsts] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77458(line=2863, offs=7) -- 77634(line=2867, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_515 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1692) ; ATSlocal (ats_ptr_type, tmp1693) ; ATSlocal (ats_ptr_type, tmp1694) ; ATSlocal (ats_ptr_type, tmp1695) ; ATSlocal (ats_ptr_type, tmp1696) ; __ats_lab_aux_loc_515: do { /* branch: __ats_lab_199 */ __ats_lab_199_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_200_0 ; } __ats_lab_199_1: tmp1693 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1694 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1693 ; arg2 = tmp1694 ; goto __ats_lab_aux_loc_515 ; // tail call break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_200_1: tmp1695 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_51, arg0), atslab_s0tavar_loc) ; tmp1696 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_51, arg1), atslab_s0tavar_loc) ; tmp1692 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1695, tmp1696) ; break ; } while (0) ; return (tmp1692) ; } /* end of [aux_loc_515] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77437(line=2862, offs=24) -- 77802(line=2875, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_stavars (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1691) ; ATSlocal (ats_ptr_type, tmp1697) ; ATSlocal (ats_ptr_type, tmp1698) ; ATSlocal (ats_ptr_type, tmp1699) ; ATSlocal (ats_ptr_type, tmp1700) ; __ats_lab_d0ec_stavars: do { /* branch: __ats_lab_201 */ __ats_lab_201_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp1698 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1699 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1697 = aux_loc_515 (arg0, tmp1698, tmp1699) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_202_1: tmp1697 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_51, arg0), atslab_s0tavar_loc) ; break ; } while (0) ; tmp1700 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1700)->tag = 11 ; ats_selptrset_mac(anairiats_sum_15, tmp1700, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1700, atslab_1, arg1) ; tmp1691 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1691, atslab_d0ec_loc, tmp1697) ; ats_selptrset_mac(anairiats_rec_81, tmp1691, atslab_d0ec_node, tmp1700) ; return (tmp1691) ; } /* end of [d0ec_stavars] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77932(line=2881, offs=7) -- 78113(line=2885, offs=58) */ ATSstaticdec() ats_ptr_type aux_loc_517 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1702) ; ATSlocal (ats_ptr_type, tmp1703) ; ATSlocal (ats_ptr_type, tmp1704) ; ATSlocal (ats_ptr_type, tmp1705) ; ATSlocal (ats_ptr_type, tmp1706) ; __ats_lab_aux_loc_517: do { /* branch: __ats_lab_203 */ __ats_lab_203_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_204_0 ; } __ats_lab_203_1: tmp1703 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1704 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1703 ; arg2 = tmp1704 ; goto __ats_lab_aux_loc_517 ; // tail call break ; /* branch: __ats_lab_204 */ __ats_lab_204_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_204_1: tmp1705 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_52, arg0), atslab_s0expdef_loc) ; tmp1706 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_52, arg1), atslab_s0expdef_loc) ; tmp1702 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1705, tmp1706) ; break ; } while (0) ; return (tmp1702) ; } /* end of [aux_loc_517] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 77853(line=2879, offs=4) -- 78308(line=2892, offs=6) */ ATSstaticdec() ats_ptr_type d0ec_sexpdefs_main_516 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1701) ; ATSlocal (ats_ptr_type, tmp1707) ; ATSlocal (ats_ptr_type, tmp1708) ; ATSlocal (ats_ptr_type, tmp1709) ; ATSlocal (ats_ptr_type, tmp1710) ; __ats_lab_d0ec_sexpdefs_main_516: do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp1708 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1709 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1707 = aux_loc_517 (arg1, tmp1708, tmp1709) ; break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_206_1: tmp1707 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_52, arg1), atslab_s0expdef_loc) ; break ; } while (0) ; tmp1710 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1710)->tag = 12 ; ats_selptrset_mac(anairiats_sum_38, tmp1710, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1710, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1710, atslab_2, arg2) ; tmp1701 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1701, atslab_d0ec_loc, tmp1707) ; ats_selptrset_mac(anairiats_rec_81, tmp1701, atslab_d0ec_node, tmp1710) ; return (tmp1701) ; } /* end of [d0ec_sexpdefs_main_516] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 78365(line=2894, offs=25) -- 78960(line=2912, offs=4) */ ATSglobaldec() ats_ptr_type d0ec_sexpdefs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1711) ; ATSlocal (ats_ptr_type, tmp1712) ; ATSlocal (ats_ptr_type, tmp1713) ; ATSlocal (ats_ptr_type, tmp1714) ; ATSlocal (ats_ptr_type, tmp1715) ; ATSlocal (ats_ptr_type, tmp1716) ; ATSlocal (ats_ptr_type, tmp1717) ; ATSlocal (ats_ptr_type, tmp1718) ; ATSlocal (ats_ptr_type, tmp1719) ; ATSlocal (ats_ptr_type, tmp1720) ; ATSlocal (ats_ptr_type, tmp1721) ; ATSlocal (ats_ptr_type, tmp1722) ; ATSlocal (ats_ptr_type, tmp1723) ; ATSlocal (ats_ptr_type, tmp1724) ; ATSlocal (ats_ptr_type, tmp1725) ; ATSlocal (ats_ptr_type, tmp1726) ; ATSlocal (ats_ptr_type, tmp1727) ; ATSlocal (ats_ptr_type, tmp1728) ; __ats_lab_d0ec_sexpdefs: do { /* branch: __ats_lab_207 */ __ats_lab_207_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_208_0 ; } __ats_lab_207_1: tmp1712 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_208 */ __ats_lab_208_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp1713 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp1715 = ats_selsin_mac(tmp1713, atslab_t0kn_loc) ; tmp1716 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1716)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1716, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; tmp1714 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp1714, atslab_s0rt_loc, tmp1715) ; ats_selptrset_mac(anairiats_rec_18, tmp1714, atslab_s0rt_node, tmp1716) ; tmp1712 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1712, atslab_0, tmp1714) ; break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp1717 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp1719 = ats_selsin_mac(tmp1717, atslab_t0kn_loc) ; tmp1720 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1720)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1720, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; tmp1718 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp1718, atslab_s0rt_loc, tmp1719) ; ats_selptrset_mac(anairiats_rec_18, tmp1718, atslab_s0rt_node, tmp1720) ; tmp1712 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1712, atslab_0, tmp1718) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_211_0 ; } __ats_lab_210_1: tmp1721 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp1723 = ats_selsin_mac(tmp1721, atslab_t0kn_loc) ; tmp1724 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1724)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1724, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; tmp1722 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp1722, atslab_s0rt_loc, tmp1723) ; ats_selptrset_mac(anairiats_rec_18, tmp1722, atslab_s0rt_node, tmp1724) ; tmp1712 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1712, atslab_0, tmp1722) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_211_1: tmp1725 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp1727 = ats_selsin_mac(tmp1725, atslab_t0kn_loc) ; tmp1728 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1728)->tag = 1 ; ats_selptrset_mac(anairiats_sum_0, tmp1728, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; tmp1726 = ATS_MALLOC(sizeof(anairiats_rec_18)) ; ats_selptrset_mac(anairiats_rec_18, tmp1726, atslab_s0rt_loc, tmp1727) ; ats_selptrset_mac(anairiats_rec_18, tmp1726, atslab_s0rt_node, tmp1728) ; tmp1712 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1712, atslab_0, tmp1726) ; break ; } while (0) ; tmp1711 = d0ec_sexpdefs_main_516 (tmp1712, arg1, arg2) ; return (tmp1711) ; } /* end of [d0ec_sexpdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79032(line=2916, offs=24) -- 79096(line=2918, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_saspdec (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1729) ; ATSlocal (ats_ptr_type, tmp1730) ; ATSlocal (ats_ptr_type, tmp1731) ; __ats_lab_d0ec_saspdec: tmp1730 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_53, arg0), atslab_s0aspdec_loc) ; tmp1731 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1731)->tag = 13 ; ats_selptrset_mac(anairiats_sum_0, tmp1731, atslab_0, arg0) ; tmp1729 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1729, atslab_d0ec_loc, tmp1730) ; ats_selptrset_mac(anairiats_rec_81, tmp1729, atslab_d0ec_node, tmp1731) ; return (tmp1729) ; } /* end of [d0ec_saspdec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79197(line=2923, offs=7) -- 79378(line=2927, offs=58) */ ATSstaticdec() ats_ptr_type aux_loc_521 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1733) ; ATSlocal (ats_ptr_type, tmp1734) ; ATSlocal (ats_ptr_type, tmp1735) ; ATSlocal (ats_ptr_type, tmp1736) ; ATSlocal (ats_ptr_type, tmp1737) ; __ats_lab_aux_loc_521: do { /* branch: __ats_lab_212 */ __ats_lab_212_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp1734 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1735 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1734 ; arg2 = tmp1735 ; goto __ats_lab_aux_loc_521 ; // tail call break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_213_1: tmp1736 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_59, arg0), atslab_d0cstdec_loc) ; tmp1737 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_59, arg1), atslab_d0cstdec_loc) ; tmp1733 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1736, tmp1737) ; break ; } while (0) ; return (tmp1733) ; } /* end of [aux_loc_521] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79168(line=2922, offs=25) -- 79576(line=2934, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_dcstdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1732) ; ATSlocal (ats_ptr_type, tmp1738) ; ATSlocal (ats_ptr_type, tmp1739) ; ATSlocal (ats_ptr_type, tmp1740) ; ATSlocal (ats_ptr_type, tmp1741) ; __ats_lab_d0ec_dcstdecs: do { /* branch: __ats_lab_214 */ __ats_lab_214_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_215_0 ; } __ats_lab_214_1: tmp1739 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1740 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1738 = aux_loc_521 (arg2, tmp1739, tmp1740) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_215_1: tmp1738 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_59, arg2), atslab_d0cstdec_loc) ; break ; } while (0) ; tmp1741 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1741)->tag = 14 ; ats_selptrset_mac(anairiats_sum_42, tmp1741, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1741, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1741, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1741, atslab_3, arg3) ; tmp1732 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1732, atslab_d0ec_loc, tmp1738) ; ats_selptrset_mac(anairiats_rec_81, tmp1732, atslab_d0ec_node, tmp1741) ; return (tmp1732) ; } /* end of [d0ec_dcstdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79677(line=2939, offs=7) -- 79855(line=2943, offs=56) */ ATSstaticdec() ats_ptr_type aux1_loc_523 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1743) ; ATSlocal (ats_ptr_type, tmp1744) ; ATSlocal (ats_ptr_type, tmp1745) ; ATSlocal (ats_ptr_type, tmp1746) ; ATSlocal (ats_ptr_type, tmp1747) ; __ats_lab_aux1_loc_523: do { /* branch: __ats_lab_216 */ __ats_lab_216_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_217_0 ; } __ats_lab_216_1: tmp1744 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1745 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1744 ; arg2 = tmp1745 ; goto __ats_lab_aux1_loc_523 ; // tail call break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_217_1: tmp1746 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_55, arg0), atslab_d0atdec_loc) ; tmp1747 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_55, arg1), atslab_d0atdec_loc) ; tmp1743 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1746, tmp1747) ; break ; } while (0) ; return (tmp1743) ; } /* end of [aux1_loc_523] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79885(line=2945, offs=7) -- 80066(line=2949, offs=57) */ ATSstaticdec() ats_ptr_type aux2_loc_524 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1748) ; ATSlocal (ats_ptr_type, tmp1749) ; ATSlocal (ats_ptr_type, tmp1750) ; ATSlocal (ats_ptr_type, tmp1751) ; ATSlocal (ats_ptr_type, tmp1752) ; __ats_lab_aux2_loc_524: do { /* branch: __ats_lab_218 */ __ats_lab_218_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp1749 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1750 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1749 ; arg2 = tmp1750 ; goto __ats_lab_aux2_loc_524 ; // tail call break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_219_1: tmp1751 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_55, arg0), atslab_d0atdec_loc) ; tmp1752 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_52, arg1), atslab_s0expdef_loc) ; tmp1748 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1751, tmp1752) ; break ; } while (0) ; return (tmp1748) ; } /* end of [aux2_loc_524] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 79648(line=2938, offs=24) -- 80359(line=2960, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_datdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1742) ; ATSlocal (ats_ptr_type, tmp1753) ; ATSlocal (ats_ptr_type, tmp1754) ; ATSlocal (ats_ptr_type, tmp1755) ; ATSlocal (ats_ptr_type, tmp1756) ; ATSlocal (ats_ptr_type, tmp1757) ; ATSlocal (ats_ptr_type, tmp1758) ; __ats_lab_d0ec_datdecs: do { /* branch: __ats_lab_220 */ __ats_lab_220_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp1754 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1755 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1753 = aux2_loc_524 (arg1, tmp1754, tmp1755) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_221_1: do { /* branch: __ats_lab_222 */ __ats_lab_222_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_223_0 ; } __ats_lab_222_1: tmp1756 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1757 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1753 = aux1_loc_523 (arg1, tmp1756, tmp1757) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_223_1: tmp1753 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_55, arg1), atslab_d0atdec_loc) ; break ; } while (0) ; break ; } while (0) ; tmp1758 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1758)->tag = 15 ; ats_selptrset_mac(anairiats_sum_42, tmp1758, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1758, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1758, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1758, atslab_3, arg3) ; tmp1742 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1742, atslab_d0ec_loc, tmp1753) ; ats_selptrset_mac(anairiats_rec_81, tmp1742, atslab_d0ec_node, tmp1758) ; return (tmp1742) ; } /* end of [d0ec_datdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 80464(line=2966, offs=7) -- 80632(line=2970, offs=46) */ ATSstaticdec() ats_ptr_type aux_loc_526 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1760) ; ATSlocal (ats_ptr_type, tmp1761) ; ATSlocal (ats_ptr_type, tmp1762) ; ATSlocal (ats_ptr_type, tmp1763) ; __ats_lab_aux_loc_526: do { /* branch: __ats_lab_224 */ __ats_lab_224_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_225_0 ; } __ats_lab_224_1: tmp1761 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1762 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1761 ; arg2 = tmp1762 ; goto __ats_lab_aux_loc_526 ; // tail call break ; /* branch: __ats_lab_225 */ __ats_lab_225_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_225_1: tmp1763 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_56, arg1), atslab_e0xndec_loc) ; tmp1760 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (arg0, tmp1763) ; break ; } while (0) ; return (tmp1760) ; } /* end of [aux_loc_526] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 80430(line=2965, offs=14) -- 80765(line=2975, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_exndecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1759) ; ATSlocal (ats_ptr_type, tmp1764) ; ATSlocal (ats_ptr_type, tmp1765) ; ATSlocal (ats_ptr_type, tmp1766) ; __ats_lab_d0ec_exndecs: tmp1765 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1764 = aux_loc_526 (tmp1765, arg1, arg2) ; tmp1766 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1766)->tag = 16 ; ats_selptrset_mac(anairiats_sum_15, tmp1766, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1766, atslab_1, arg2) ; tmp1759 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1759, atslab_d0ec_loc, tmp1764) ; ats_selptrset_mac(anairiats_rec_81, tmp1759, atslab_d0ec_node, tmp1766) ; return (tmp1759) ; } /* end of [d0ec_exndecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 80842(line=2980, offs=20) -- 80976(line=2984, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_classdec_none (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1767) ; ATSlocal (ats_ptr_type, tmp1768) ; ATSlocal (ats_ptr_type, tmp1769) ; ATSlocal (ats_ptr_type, tmp1770) ; ATSlocal (ats_ptr_type, tmp1771) ; ATSlocal (ats_ptr_type, tmp1772) ; __ats_lab_d0ec_classdec_none: tmp1769 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1770 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_i0de_loc) ; tmp1768 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1769, tmp1770) ; tmp1772 = (ats_sum_ptr_type)0 ; tmp1771 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1771)->tag = 17 ; ats_selptrset_mac(anairiats_sum_15, tmp1771, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1771, atslab_1, tmp1772) ; tmp1767 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1767, atslab_d0ec_loc, tmp1768) ; ats_selptrset_mac(anairiats_rec_81, tmp1767, atslab_d0ec_node, tmp1771) ; return (tmp1767) ; } /* end of [d0ec_classdec_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 81038(line=2987, offs=20) -- 81183(line=2991, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_classdec_some (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1773) ; ATSlocal (ats_ptr_type, tmp1774) ; ATSlocal (ats_ptr_type, tmp1775) ; ATSlocal (ats_ptr_type, tmp1776) ; ATSlocal (ats_ptr_type, tmp1777) ; ATSlocal (ats_ptr_type, tmp1778) ; __ats_lab_d0ec_classdec_some: tmp1775 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1776 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg2), atslab_s0exp_loc) ; tmp1774 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1775, tmp1776) ; tmp1778 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1778, atslab_0, arg2) ; tmp1777 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1777)->tag = 17 ; ats_selptrset_mac(anairiats_sum_15, tmp1777, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1777, atslab_1, tmp1778) ; tmp1773 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1773, atslab_d0ec_loc, tmp1774) ; ats_selptrset_mac(anairiats_rec_81, tmp1773, atslab_d0ec_node, tmp1777) ; return (tmp1773) ; } /* end of [d0ec_classdec_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 81263(line=2997, offs=3) -- 81410(line=3001, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_overload (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1779) ; ATSlocal (ats_ptr_type, tmp1780) ; ATSlocal (ats_ptr_type, tmp1781) ; ATSlocal (ats_ptr_type, tmp1782) ; ATSlocal (ats_ptr_type, tmp1783) ; __ats_lab_d0ec_overload: tmp1781 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1782 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg2), atslab_dqi0de_loc) ; tmp1780 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1781, tmp1782) ; tmp1783 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1783)->tag = 18 ; ats_selptrset_mac(anairiats_sum_15, tmp1783, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1783, atslab_1, arg2) ; tmp1779 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1779, atslab_d0ec_loc, tmp1780) ; ats_selptrset_mac(anairiats_rec_81, tmp1779, atslab_d0ec_node, tmp1783) ; return (tmp1779) ; } /* end of [d0ec_overload] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 81475(line=3005, offs=3) -- 81671(line=3010, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_overload_lrbrackets (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1784) ; ATSlocal (ats_ptr_type, tmp1785) ; ATSlocal (ats_ptr_type, tmp1786) ; ATSlocal (ats_ptr_type, tmp1787) ; ATSlocal (ats_ptr_type, tmp1788) ; ATSlocal (ats_ptr_type, tmp1789) ; __ats_lab_d0ec_overload_lrbrackets: tmp1785 = i0de_make_lrbrackets (arg1, arg2) ; tmp1787 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1788 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_30, arg3), atslab_dqi0de_loc) ; tmp1786 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1787, tmp1788) ; tmp1789 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1789)->tag = 18 ; ats_selptrset_mac(anairiats_sum_15, tmp1789, atslab_0, tmp1785) ; ats_selptrset_mac(anairiats_sum_15, tmp1789, atslab_1, arg3) ; tmp1784 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1784, atslab_d0ec_loc, tmp1786) ; ats_selptrset_mac(anairiats_rec_81, tmp1784, atslab_d0ec_node, tmp1789) ; return (tmp1784) ; } /* end of [d0ec_overload_lrbrackets] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 81754(line=3014, offs=24) -- 81829(line=3016, offs=2) */ ATSglobaldec() ats_ptr_type d0ec_dynload (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1790) ; ATSlocal (ats_ptr_type, tmp1791) ; ATSlocal (ats_ptr_type, tmp1792) ; ATSlocal (ats_ptr_type, tmp1793) ; __ats_lab_d0ec_dynload: tmp1791 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1793 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1792 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp1792)->tag = 29 ; ats_selptrset_mac(anairiats_sum_0, tmp1792, atslab_0, tmp1793) ; tmp1790 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1790, atslab_d0ec_loc, tmp1791) ; ats_selptrset_mac(anairiats_rec_81, tmp1790, atslab_d0ec_node, tmp1792) ; return (tmp1790) ; } /* end of [d0ec_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 81888(line=3021, offs=19) -- 82010(line=3025, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_staload_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1794) ; ATSlocal (ats_ptr_type, tmp1795) ; ATSlocal (ats_ptr_type, tmp1796) ; ATSlocal (ats_ptr_type, tmp1797) ; ATSlocal (ats_ptr_type, tmp1798) ; __ats_lab_d0ec_staload_none: tmp1795 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1796 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1798 = (ats_sum_ptr_type)0 ; tmp1797 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1797)->tag = 30 ; ats_selptrset_mac(anairiats_sum_15, tmp1797, atslab_0, tmp1798) ; ats_selptrset_mac(anairiats_sum_15, tmp1797, atslab_1, tmp1795) ; tmp1794 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1794, atslab_d0ec_loc, tmp1796) ; ats_selptrset_mac(anairiats_rec_81, tmp1794, atslab_d0ec_node, tmp1797) ; return (tmp1794) ; } /* end of [d0ec_staload_none] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 82070(line=3028, offs=19) -- 82247(line=3033, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_staload_some (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1799) ; ATSlocal (ats_ptr_type, tmp1800) ; ATSlocal (ats_ptr_type, tmp1801) ; ATSlocal (ats_ptr_type, tmp1802) ; ATSlocal (ats_ptr_type, tmp1803) ; ATSlocal (ats_ptr_type, tmp1804) ; ATSlocal (ats_ptr_type, tmp1805) ; ATSlocal (ats_ptr_type, tmp1806) ; __ats_lab_d0ec_staload_some: tmp1800 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0tring_val) ; tmp1802 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_loc) ; tmp1803 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0tring_loc) ; tmp1801 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1802, tmp1803) ; tmp1806 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_i0de_sym) ; tmp1805 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ats_selptrset_mac(anairiats_sum_13, tmp1805, atslab_0, tmp1806) ; tmp1804 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1804)->tag = 30 ; ats_selptrset_mac(anairiats_sum_15, tmp1804, atslab_0, tmp1805) ; ats_selptrset_mac(anairiats_sum_15, tmp1804, atslab_1, tmp1800) ; tmp1799 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1799, atslab_d0ec_loc, tmp1801) ; ats_selptrset_mac(anairiats_rec_81, tmp1799, atslab_d0ec_node, tmp1804) ; return (tmp1799) ; } /* end of [d0ec_staload_some] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 82322(line=3037, offs=23) -- 82467(line=3041, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_extype (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1807) ; ATSlocal (ats_ptr_type, tmp1808) ; ATSlocal (ats_ptr_type, tmp1809) ; ATSlocal (ats_ptr_type, tmp1810) ; ATSlocal (ats_ptr_type, tmp1811) ; ATSlocal (ats_ptr_type, tmp1812) ; __ats_lab_d0ec_extype: tmp1809 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1810 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_36, arg1), atslab_s0exp_loc) ; tmp1808 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1809, tmp1810) ; tmp1812 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1811 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1811)->tag = 19 ; ats_selptrset_mac(anairiats_sum_15, tmp1811, atslab_0, tmp1812) ; ats_selptrset_mac(anairiats_sum_15, tmp1811, atslab_1, arg1) ; tmp1807 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1807, atslab_d0ec_loc, tmp1808) ; ats_selptrset_mac(anairiats_rec_81, tmp1807, atslab_d0ec_node, tmp1811) ; return (tmp1807) ; } /* end of [d0ec_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 82515(line=3043, offs=23) -- 82660(line=3047, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_extval (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1813) ; ATSlocal (ats_ptr_type, tmp1814) ; ATSlocal (ats_ptr_type, tmp1815) ; ATSlocal (ats_ptr_type, tmp1816) ; ATSlocal (ats_ptr_type, tmp1817) ; ATSlocal (ats_ptr_type, tmp1818) ; __ats_lab_d0ec_extval: tmp1815 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_loc) ; tmp1816 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_63, arg1), atslab_d0exp_loc) ; tmp1814 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1815, tmp1816) ; tmp1818 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg0), atslab_s0tring_val) ; tmp1817 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1817)->tag = 20 ; ats_selptrset_mac(anairiats_sum_15, tmp1817, atslab_0, tmp1818) ; ats_selptrset_mac(anairiats_sum_15, tmp1817, atslab_1, arg1) ; tmp1813 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1813, atslab_d0ec_loc, tmp1814) ; ats_selptrset_mac(anairiats_rec_81, tmp1813, atslab_d0ec_node, tmp1817) ; return (tmp1813) ; } /* end of [d0ec_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 82734(line=3051, offs=28) -- 83222(line=3066, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_extcode_dyn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1819) ; ATSlocal (ats_int_type, tmp1820) ; ATSlocal (ats_ptr_type, tmp1821) ; // ATSlocal_void (tmp1822) ; ATSlocal (ats_bool_type, tmp1823) ; // ATSlocal_void (tmp1824) ; // ATSlocal_void (tmp1825) ; // ATSlocal_void (tmp1826) ; // ATSlocal_void (tmp1827) ; // ATSlocal_void (tmp1828) ; ATSlocal (ats_ptr_type, tmp1829) ; ATSlocal (ats_ptr_type, tmp1830) ; __ats_lab_d0ec_extcode_dyn: tmp1820 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_pos) ; tmp1821 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_loc) ; tmp1823 = atspre_lt_int_int (tmp1820, 0) ; if (tmp1823) { /* tmp1824 = */ prerr_loc_error0_0 (tmp1821) ; /* tmp1825 = */ atspre_prerr_string (ATSstrcst(": the sequence \"%{#\" is only for")) ; /* tmp1826 = */ atspre_prerr_string (ATSstrcst(" including external code in a static file")) ; /* tmp1827 = */ atspre_prerr_string (ATSstrcst("; please use either \"%{\", \"%{^\", or \"%{$\" instead.")) ; /* tmp1828 = */ atspre_prerr_newline () ; /* tmp1822 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp1829 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_cod) ; tmp1830 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1830)->tag = 21 ; ats_selptrset_mac(anairiats_sum_24, tmp1830, atslab_0, tmp1820) ; ats_selptrset_mac(anairiats_sum_24, tmp1830, atslab_1, tmp1829) ; tmp1819 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1819, atslab_d0ec_loc, tmp1821) ; ats_selptrset_mac(anairiats_rec_81, tmp1819, atslab_d0ec_node, tmp1830) ; return (tmp1819) ; } /* end of [d0ec_extcode_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 83280(line=3068, offs=28) -- 83705(line=3082, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_extcode_sta (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1831) ; ATSlocal (ats_int_type, tmp1832) ; ATSlocal (ats_ptr_type, tmp1833) ; // ATSlocal_void (tmp1834) ; ATSlocal (ats_bool_type, tmp1835) ; // ATSlocal_void (tmp1836) ; // ATSlocal_void (tmp1837) ; // ATSlocal_void (tmp1838) ; // ATSlocal_void (tmp1839) ; ATSlocal (ats_ptr_type, tmp1840) ; ATSlocal (ats_ptr_type, tmp1841) ; __ats_lab_d0ec_extcode_sta: tmp1832 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_pos) ; tmp1833 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_loc) ; tmp1835 = atspre_gte_int_int (tmp1832, 0) ; if (tmp1835) { /* tmp1836 = */ prerr_loc_error0_0 (tmp1833) ; /* tmp1837 = */ atspre_prerr_string (ATSstrcst(": the sequence \"%{#\" should be used for")) ; /* tmp1838 = */ atspre_prerr_string (ATSstrcst(" including external code in a static file.")) ; /* tmp1839 = */ atspre_prerr_newline () ; /* tmp1834 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp1840 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_e0xtcode_cod) ; tmp1841 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp1841)->tag = 21 ; ats_selptrset_mac(anairiats_sum_24, tmp1841, atslab_0, tmp1832) ; ats_selptrset_mac(anairiats_sum_24, tmp1841, atslab_1, tmp1840) ; tmp1831 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1831, atslab_d0ec_loc, tmp1833) ; ats_selptrset_mac(anairiats_rec_81, tmp1831, atslab_d0ec_node, tmp1841) ; return (tmp1831) ; } /* end of [d0ec_extcode_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 83768(line=3088, offs=5) -- 83901(line=3092, offs=29) */ ATSstaticdec() ats_ptr_type aux1_loc_538 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1842) ; ATSlocal (ats_ptr_type, tmp1843) ; ATSlocal (ats_ptr_type, tmp1844) ; __ats_lab_aux1_loc_538: do { /* branch: __ats_lab_226 */ __ats_lab_226_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_227_0 ; } __ats_lab_226_1: tmp1843 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1844 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1842 = aux2_loc_539 (arg0, tmp1843, tmp1844) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_227_1: tmp1842 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_76, arg0), atslab_v0aldec_loc) ; break ; } while (0) ; return (tmp1842) ; } /* end of [aux1_loc_538] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 83925(line=3095, offs=5) -- 84095(line=3099, offs=54) */ ATSstaticdec() ats_ptr_type aux2_loc_539 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1845) ; ATSlocal (ats_ptr_type, tmp1846) ; ATSlocal (ats_ptr_type, tmp1847) ; ATSlocal (ats_ptr_type, tmp1848) ; ATSlocal (ats_ptr_type, tmp1849) ; __ats_lab_aux2_loc_539: do { /* branch: __ats_lab_228 */ __ats_lab_228_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp1846 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1847 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1846 ; arg2 = tmp1847 ; goto __ats_lab_aux2_loc_539 ; // tail call break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp1848 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_76, arg0), atslab_v0aldec_loc) ; tmp1849 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_76, arg1), atslab_v0aldec_loc) ; tmp1845 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1848, tmp1849) ; break ; } while (0) ; return (tmp1845) ; } /* end of [aux2_loc_539] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 84162(line=3104, offs=24) -- 84272(line=3108, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_valdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1850) ; ATSlocal (ats_ptr_type, tmp1851) ; ATSlocal (ats_ptr_type, tmp1852) ; __ats_lab_d0ec_valdecs: tmp1851 = aux1_loc_538 (arg1, arg2) ; tmp1852 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1852)->tag = 22 ; ats_selptrset_mac(anairiats_sum_38, tmp1852, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1852, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1852, atslab_2, arg2) ; tmp1850 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1850, atslab_d0ec_loc, tmp1851) ; ats_selptrset_mac(anairiats_rec_81, tmp1850, atslab_d0ec_node, tmp1852) ; return (tmp1850) ; } /* end of [d0ec_valdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 84326(line=3110, offs=28) -- 84434(line=3114, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_valdecs_par (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1853) ; ATSlocal (ats_ptr_type, tmp1854) ; ATSlocal (ats_ptr_type, tmp1855) ; __ats_lab_d0ec_valdecs_par: tmp1854 = aux1_loc_538 (arg0, arg1) ; tmp1855 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1855)->tag = 23 ; ats_selptrset_mac(anairiats_sum_15, tmp1855, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1855, atslab_1, arg1) ; tmp1853 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1853, atslab_d0ec_loc, tmp1854) ; ats_selptrset_mac(anairiats_rec_81, tmp1853, atslab_d0ec_node, tmp1855) ; return (tmp1853) ; } /* end of [d0ec_valdecs_par] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 84492(line=3116, offs=28) -- 84600(line=3120, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_valdecs_rec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1856) ; ATSlocal (ats_ptr_type, tmp1857) ; ATSlocal (ats_ptr_type, tmp1858) ; __ats_lab_d0ec_valdecs_rec: tmp1857 = aux1_loc_538 (arg0, arg1) ; tmp1858 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1858)->tag = 24 ; ats_selptrset_mac(anairiats_sum_15, tmp1858, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1858, atslab_1, arg1) ; tmp1856 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1856, atslab_d0ec_loc, tmp1857) ; ats_selptrset_mac(anairiats_rec_81, tmp1856, atslab_d0ec_node, tmp1858) ; return (tmp1856) ; } /* end of [d0ec_valdecs_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 84727(line=3128, offs=7) -- 84903(line=3132, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_544 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1860) ; ATSlocal (ats_ptr_type, tmp1861) ; ATSlocal (ats_ptr_type, tmp1862) ; ATSlocal (ats_ptr_type, tmp1863) ; ATSlocal (ats_ptr_type, tmp1864) ; __ats_lab_aux_loc_544: do { /* branch: __ats_lab_230 */ __ats_lab_230_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_231_0 ; } __ats_lab_230_1: tmp1861 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1862 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1861 ; arg2 = tmp1862 ; goto __ats_lab_aux_loc_544 ; // tail call break ; /* branch: __ats_lab_231 */ __ats_lab_231_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_231_1: tmp1863 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_77, arg0), atslab_f0undec_loc) ; tmp1864 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_77, arg1), atslab_f0undec_loc) ; tmp1860 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1863, tmp1864) ; break ; } while (0) ; return (tmp1860) ; } /* end of [aux_loc_544] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 84698(line=3127, offs=14) -- 85099(line=3139, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_fundecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1859) ; ATSlocal (ats_ptr_type, tmp1865) ; ATSlocal (ats_ptr_type, tmp1866) ; ATSlocal (ats_ptr_type, tmp1867) ; ATSlocal (ats_ptr_type, tmp1868) ; __ats_lab_d0ec_fundecs: do { /* branch: __ats_lab_232 */ __ats_lab_232_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_233_0 ; } __ats_lab_232_1: tmp1866 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp1867 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp1865 = aux_loc_544 (arg2, tmp1866, tmp1867) ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_233_1: tmp1865 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_77, arg2), atslab_f0undec_loc) ; break ; } while (0) ; tmp1868 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1868)->tag = 25 ; ats_selptrset_mac(anairiats_sum_42, tmp1868, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1868, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1868, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_42, tmp1868, atslab_3, arg3) ; tmp1859 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1859, atslab_d0ec_loc, tmp1865) ; ats_selptrset_mac(anairiats_rec_81, tmp1859, atslab_d0ec_node, tmp1868) ; return (tmp1859) ; } /* end of [d0ec_fundecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 85191(line=3145, offs=7) -- 85372(line=3150, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_546 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1870) ; ATSlocal (ats_ptr_type, tmp1871) ; ATSlocal (ats_ptr_type, tmp1872) ; ATSlocal (ats_ptr_type, tmp1873) ; ATSlocal (ats_ptr_type, tmp1874) ; __ats_lab_aux_loc_546: do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp1871 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1872 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1871 ; arg2 = tmp1872 ; goto __ats_lab_aux_loc_546 ; // tail call break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: tmp1873 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_78, arg0), atslab_v0ardec_loc) ; tmp1874 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_78, arg1), atslab_v0ardec_loc) ; tmp1870 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1873, tmp1874) ; break ; } while (0) ; return (tmp1870) ; } /* end of [aux_loc_546] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 85170(line=3144, offs=14) -- 85543(line=3156, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_vardecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1869) ; ATSlocal (ats_ptr_type, tmp1875) ; ATSlocal (ats_ptr_type, tmp1876) ; ATSlocal (ats_ptr_type, tmp1877) ; ATSlocal (ats_ptr_type, tmp1878) ; __ats_lab_d0ec_vardecs: do { /* branch: __ats_lab_236 */ __ats_lab_236_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp1876 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp1877 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp1875 = aux_loc_546 (arg0, tmp1876, tmp1877) ; break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_237_1: tmp1875 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_78, arg0), atslab_v0ardec_loc) ; break ; } while (0) ; tmp1878 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1878)->tag = 26 ; ats_selptrset_mac(anairiats_sum_15, tmp1878, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1878, atslab_1, arg1) ; tmp1869 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1869, atslab_d0ec_loc, tmp1875) ; ats_selptrset_mac(anairiats_rec_81, tmp1869, atslab_d0ec_node, tmp1878) ; return (tmp1869) ; } /* end of [d0ec_vardecs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 85685(line=3166, offs=7) -- 85861(line=3170, offs=56) */ ATSstaticdec() ats_ptr_type aux_loc_548 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1880) ; ATSlocal (ats_ptr_type, tmp1881) ; ATSlocal (ats_ptr_type, tmp1882) ; ATSlocal (ats_ptr_type, tmp1883) ; ATSlocal (ats_ptr_type, tmp1884) ; __ats_lab_aux_loc_548: do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp1881 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1882 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; arg0 = arg0 ; arg1 = tmp1881 ; arg2 = tmp1882 ; goto __ats_lab_aux_loc_548 ; // tail call break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_239_1: tmp1883 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_79, arg0), atslab_m0acdef_loc) ; tmp1884 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_79, arg1), atslab_m0acdef_loc) ; tmp1880 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1883, tmp1884) ; break ; } while (0) ; return (tmp1880) ; } /* end of [aux_loc_548] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 85616(line=3162, offs=3) -- 86366(line=3187, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_macdefs (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1879) ; ATSlocal (ats_ptr_type, tmp1885) ; ATSlocal (ats_ptr_type, tmp1886) ; ATSlocal (ats_ptr_type, tmp1887) ; // ATSlocal_void (tmp1888) ; ATSlocal (ats_bool_type, tmp1889) ; // ATSlocal_void (tmp1890) ; // ATSlocal_void (tmp1891) ; // ATSlocal_void (tmp1892) ; // ATSlocal_void (tmp1893) ; ATSlocal (ats_ptr_type, tmp1894) ; __ats_lab_d0ec_macdefs: do { /* branch: __ats_lab_240 */ __ats_lab_240_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_241_0 ; } __ats_lab_240_1: tmp1886 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1887 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; tmp1885 = aux_loc_548 (arg1, tmp1886, tmp1887) ; break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_241_1: tmp1885 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_79, arg1), atslab_m0acdef_loc) ; break ; } while (0) ; tmp1889 = atspre_lt_int_int (arg0, 0) ; if (tmp1889) { /* tmp1890 = */ prerr_loc_error0_0 (tmp1885) ; /* tmp1891 = */ atspre_prerr_string (ATSstrcst(": only a macro in long form can be recursively defined")) ; /* tmp1892 = */ atspre_prerr_string (ATSstrcst(", which is introduced via [macrodef] instead of [macdef].")) ; /* tmp1893 = */ atspre_prerr_newline () ; /* tmp1888 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp1894 = ATS_MALLOC(sizeof(anairiats_sum_40)) ; ((ats_sum_ptr_type)tmp1894)->tag = 27 ; ats_selptrset_mac(anairiats_sum_40, tmp1894, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_40, tmp1894, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_40, tmp1894, atslab_2, arg2) ; tmp1879 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1879, atslab_d0ec_loc, tmp1885) ; ats_selptrset_mac(anairiats_rec_81, tmp1879, atslab_d0ec_node, tmp1894) ; return (tmp1879) ; } /* end of [d0ec_macdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 86469(line=3195, offs=3) -- 86639(line=3199, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_impdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1895) ; ATSlocal (ats_ptr_type, tmp1896) ; ATSlocal (ats_ptr_type, tmp1897) ; ATSlocal (ats_ptr_type, tmp1898) ; ATSlocal (ats_ptr_type, tmp1899) ; __ats_lab_d0ec_impdec: tmp1897 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1898 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_80, arg2), atslab_i0mpdec_loc) ; tmp1896 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1897, tmp1898) ; tmp1899 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1899)->tag = 28 ; ats_selptrset_mac(anairiats_sum_15, tmp1899, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1899, atslab_1, arg2) ; tmp1895 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1895, atslab_d0ec_loc, tmp1896) ; ats_selptrset_mac(anairiats_rec_81, tmp1895, atslab_d0ec_node, tmp1899) ; return (tmp1895) ; } /* end of [d0ec_impdec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 86709(line=3205, offs=3) -- 86864(line=3209, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_local (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1900) ; ATSlocal (ats_ptr_type, tmp1901) ; ATSlocal (ats_ptr_type, tmp1902) ; ATSlocal (ats_ptr_type, tmp1903) ; ATSlocal (ats_ptr_type, tmp1904) ; __ats_lab_d0ec_local: tmp1902 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp1903 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1901 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1902, tmp1903) ; tmp1904 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1904)->tag = 31 ; ats_selptrset_mac(anairiats_sum_15, tmp1904, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp1904, atslab_1, arg2) ; tmp1900 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1900, atslab_d0ec_loc, tmp1901) ; ats_selptrset_mac(anairiats_rec_81, tmp1900, atslab_d0ec_node, tmp1904) ; return (tmp1900) ; } /* end of [d0ec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 86932(line=3214, offs=13) -- 87114(line=3219, offs=6) */ ATSglobaldec() ats_ptr_type d0ec_guadec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1905) ; ATSlocal (ats_ptr_type, tmp1906) ; ATSlocal (ats_ptr_type, tmp1907) ; ATSlocal (ats_ptr_type, tmp1908) ; ATSlocal (ats_ptr_type, tmp1909) ; ATSlocal (ats_ptr_type, tmp1910) ; ATSlocal (ats_ptr_type, tmp1911) ; __ats_lab_d0ec_guadec: tmp1906 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1907 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp1909 = ats_selsin_mac(tmp1907, atslab_t0kn_loc) ; tmp1910 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_82, arg1), atslab_guad0ec_loc) ; tmp1908 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (tmp1909, tmp1910) ; tmp1911 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1911)->tag = 32 ; ats_selptrset_mac(anairiats_sum_15, tmp1911, atslab_0, tmp1906) ; ats_selptrset_mac(anairiats_sum_15, tmp1911, atslab_1, arg1) ; tmp1905 = ATS_MALLOC(sizeof(anairiats_rec_81)) ; ats_selptrset_mac(anairiats_rec_81, tmp1905, atslab_d0ec_loc, tmp1908) ; ats_selptrset_mac(anairiats_rec_81, tmp1905, atslab_d0ec_node, tmp1911) ; return (tmp1905) ; } /* end of [d0ec_guadec] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87183(line=3223, offs=23) -- 87194(line=3223, offs=34) */ ATSglobaldec() ats_ptr_type d0eclst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1912) ; __ats_lab_d0eclst_nil: tmp1912 = (ats_sum_ptr_type)0 ; return (tmp1912) ; } /* end of [d0eclst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87218(line=3224, offs=24) -- 87240(line=3224, offs=46) */ ATSglobaldec() ats_ptr_type d0eclst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1913) ; __ats_lab_d0eclst_cons: tmp1913 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1913, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1913, atslab_1, arg1) ; return (tmp1913) ; } /* end of [d0eclst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87265(line=3226, offs=24) -- 87283(line=3226, offs=42) */ ATSglobaldec() ats_ptr_type d0ecllst_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1914) ; __ats_lab_d0ecllst_nil: tmp1914 = (ats_sum_ptr_type)0 ; return (tmp1914) ; } /* end of [d0ecllst_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87308(line=3227, offs=25) -- 87337(line=3227, offs=54) */ ATSglobaldec() ats_ptr_type d0ecllst_cons (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1915) ; __ats_lab_d0ecllst_cons: tmp1915 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1915, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp1915, atslab_1, arg1) ; return (tmp1915) ; } /* end of [d0ecllst_cons] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87343(line=3229, offs=5) -- 87499(line=3232, offs=25) */ ATSstaticdec() ats_ptr_type d0ecllst_revapp_556 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1916) ; ATSlocal (ats_ptr_type, tmp1917) ; ATSlocal (ats_ptr_type, tmp1918) ; ATSlocal (ats_ptr_type, tmp1919) ; __ats_lab_d0ecllst_revapp_556: do { /* branch: __ats_lab_242 */ __ats_lab_242_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_243_0 ; } __ats_lab_242_1: tmp1917 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1918 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; ATS_FREE(arg0) ; tmp1919 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp1919, atslab_0, tmp1918) ; ats_selptrset_mac(anairiats_sum_1, tmp1919, atslab_1, arg1) ; arg0 = tmp1917 ; arg1 = tmp1919 ; goto __ats_lab_d0ecllst_revapp_556 ; // tail call break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_243_1: tmp1916 = arg1 ; break ; } while (0) ; return (tmp1916) ; } /* end of [d0ecllst_revapp_556] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87555(line=3236, offs=18) -- 87590(line=3236, offs=53) */ ATSglobaldec() ats_ptr_type d0ecllst_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1920) ; ATSlocal (ats_ptr_type, tmp1921) ; __ats_lab_d0ecllst_reverse: tmp1921 = (ats_sum_ptr_type)0 ; tmp1920 = d0ecllst_revapp_556 (arg0, tmp1921) ; return (tmp1920) ; } /* end of [d0ecllst_reverse] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87637(line=3242, offs=3) -- 87742(line=3245, offs=2) */ ATSglobaldec() ats_ptr_type guad0ec_one (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1922) ; ATSlocal (ats_ptr_type, tmp1923) ; ATSlocal (ats_ptr_type, tmp1924) ; __ats_lab_guad0ec_one: tmp1923 = ats_selsin_mac(arg2, atslab_t0kn_loc) ; tmp1924 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp1924)->tag = 0 ; ats_selptrset_mac(anairiats_sum_15, tmp1924, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_15, tmp1924, atslab_1, arg1) ; tmp1922 = ATS_MALLOC(sizeof(anairiats_rec_82)) ; ats_selptrset_mac(anairiats_rec_82, tmp1922, atslab_guad0ec_loc, tmp1923) ; ats_selptrset_mac(anairiats_rec_82, tmp1922, atslab_guad0ec_node, tmp1924) ; return (tmp1922) ; } /* end of [guad0ec_one] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87792(line=3249, offs=3) -- 87919(line=3252, offs=2) */ ATSglobaldec() ats_ptr_type guad0ec_two (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1925) ; ATSlocal (ats_ptr_type, tmp1926) ; ATSlocal (ats_ptr_type, tmp1927) ; __ats_lab_guad0ec_two: tmp1926 = ats_selsin_mac(arg3, atslab_t0kn_loc) ; tmp1927 = ATS_MALLOC(sizeof(anairiats_sum_38)) ; ((ats_sum_ptr_type)tmp1927)->tag = 1 ; ats_selptrset_mac(anairiats_sum_38, tmp1927, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_38, tmp1927, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_38, tmp1927, atslab_2, arg2) ; tmp1925 = ATS_MALLOC(sizeof(anairiats_rec_82)) ; ats_selptrset_mac(anairiats_rec_82, tmp1925, atslab_guad0ec_loc, tmp1926) ; ats_selptrset_mac(anairiats_rec_82, tmp1925, atslab_guad0ec_node, tmp1927) ; return (tmp1925) ; } /* end of [guad0ec_two] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax.dats: 87970(line=3256, offs=3) -- 88147(line=3261, offs=6) */ ATSglobaldec() ats_ptr_type guad0ec_cons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1928) ; ATSlocal (ats_ptr_type, tmp1929) ; ATSlocal (ats_ptr_type, tmp1930) ; ATSlocal (ats_ptr_type, tmp1931) ; ATSlocal (ats_ptr_type, tmp1932) ; __ats_lab_guad0ec_cons: tmp1929 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp1930 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_82, arg3), atslab_guad0ec_loc) ; tmp1932 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_82, arg3), atslab_guad0ec_node) ; tmp1931 = ATS_MALLOC(sizeof(anairiats_sum_42)) ; ((ats_sum_ptr_type)tmp1931)->tag = 2 ; ats_selptrset_mac(anairiats_sum_42, tmp1931, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_42, tmp1931, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_42, tmp1931, atslab_2, tmp1929) ; ats_selptrset_mac(anairiats_sum_42, tmp1931, atslab_3, tmp1932) ; tmp1928 = ATS_MALLOC(sizeof(anairiats_rec_82)) ; ats_selptrset_mac(anairiats_rec_82, tmp1928, atslab_guad0ec_loc, tmp1930) ; ats_selptrset_mac(anairiats_rec_82, tmp1928, atslab_guad0ec_node, tmp1931) ; return (tmp1928) ; } /* end of [guad0ec_cons] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_fixity_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_lexer_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_syntax_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_trans_tailcal_dats.c0000664000175000017500000013751712223166160024136 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { ats_char_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_4 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_9 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__CHARLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTmark_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTcons_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int) (ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_tailjoined) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_function) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_union) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funentry_set_vtps) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funentry_set_vtps_flag) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funentry_set_tailjoin) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__sasp__tailcalist_token = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type aux_char_2 (ats_ref_type arg0, ats_char_type arg1) ; static ats_void_type aux_string_3 (ats_ref_type arg0, ats_size_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_entry_4 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_entrylst_5 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type tailjoin_name_make_1 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type tailjoin_retyp_check_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_9 (ats_int_type arg0, ats_ptr_type arg1) ; static anairiats_rec_4 tailjoin_funentry_update_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5) ; static ats_ptr_type tailjoin_funentrylst_update_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_int_type arg6) ; static ats_ptr_type aux_vtps_12 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type ref_make_elt_03894_ats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type aux_16 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_19 (ats_ptr_type arg0) ; static ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type emit_tailjoin_case_20 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_23 (ats_ref_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp128) ; ATSstatic (ats_ptr_type, statmp131) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 1930(line=57, offs=4) -- 1998(line=57, offs=72) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp_trans_tailcal)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 2132(line=64, offs=7) -- 2198(line=64, offs=73) */ ATSstaticdec() ats_void_type aux_char_2 (ats_ref_type arg0, ats_char_type arg1) { /* local vardec */ // ATSlocal_void (tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_aux_char_2: tmp3 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp3, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp3, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp3 ; return /* (tmp2) */ ; } /* end of [aux_char_2] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 2206(line=66, offs=7) -- 2430(line=71, offs=6) */ ATSstaticdec() ats_void_type aux_string_3 (ats_ref_type arg0, ats_size_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_char_type, tmp7) ; ATSlocal (ats_size_type, tmp8) ; __ats_lab_aux_string_3: tmp5 = atspre_string_is_atend (arg2, arg1) ; if (tmp5) { /* empty */ } else { tmp7 = atspre_string_get_char_at (arg2, arg1) ; tmp6 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp6, atslab_0, tmp7) ; ats_selptrset_mac(anairiats_sum_1, tmp6, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp6 ; tmp8 = atspre_add_size1_int1 (arg1, 1) ; arg0 = arg0 ; arg1 = tmp8 ; arg2 = arg2 ; goto __ats_lab_aux_string_3 ; // tail call } /* end of [if] */ return /* (tmp4) */ ; } /* end of [aux_string_3] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 2461(line=73, offs=7) -- 2627(line=79, offs=6) */ ATSstaticdec() ats_void_type aux_entry_4 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_aux_entry_4: tmp11 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (arg1) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name (tmp11) ; /* tmp9 = */ aux_string_3 (arg0, 0, ats_castfn_mac(ats_ptr_type, tmp10)) ; return /* (tmp9) */ ; } /* end of [aux_entry_4] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 2657(line=81, offs=7) -- 2877(line=86, offs=24) */ ATSstaticdec() ats_void_type aux_entrylst_5 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; // ATSlocal_void (tmp16) ; __ats_lab_aux_entrylst_5: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; /* tmp15 = */ aux_char_2 (arg0, '$') ; /* tmp16 = */ aux_entry_4 (arg0, tmp13) ; arg0 = arg0 ; arg1 = tmp14 ; goto __ats_lab_aux_entrylst_5 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp12) */ ; } /* end of [aux_entrylst_5] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 2024(line=61, offs=4) -- 3041(line=93, offs=4) */ ATSstaticdec() ats_ptr_type tailjoin_name_make_1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_tailjoin_name_make_1: /* ats_ptr_type tmp17 ; */ tmp17 = (ats_sum_ptr_type)0 ; /* tmp18 = */ aux_entry_4 ((&tmp17), arg0) ; /* tmp19 = */ aux_entrylst_5 ((&tmp17), arg1) ; tmp1 = ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__string_make_charlst_rev (tmp17) ; return (tmp1) ; } /* end of [tailjoin_name_make_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 3173(line=97, offs=7) -- 3808(line=116, offs=6) */ ATSstaticdec() ats_void_type aux_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_bool_type, tmp28) ; // ATSlocal_void (tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; // ATSlocal_void (tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; __ats_lab_aux_7: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_2_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp25 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (tmp22) ; tmp24 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp25) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name (tmp24) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_3, tmp26, atslab_1) ; do { /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp28 = atspre_eq_string_string (arg0, tmp27) ; if (!tmp28) { goto __ats_lab_4_1 ; } arg0 = arg0 ; arg1 = tmp23 ; goto __ats_lab_aux_7 ; // tail call break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: tmp30 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc (tmp22) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp30) ; /* tmp31 = */ atspre_prerr_string (ATSstrcst(": error(ccomp)")) ; /* tmp32 = */ atspre_prerr_string (ATSstrcst(": the return type of this function is inconsistent.")) ; /* tmp33 = */ atspre_prerr_newline () ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: break ; } while (0) ; return /* (tmp21) */ ; } /* end of [aux_7] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 3077(line=95, offs=4) -- 3902(line=120, offs=4) */ ATSstaticdec() ats_void_type tailjoin_retyp_check_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_tailjoin_retyp_check_6: tmp34 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_get_name (arg0) ; tmp35 = ats_caselptrlab_mac(anairiats_sum_3, tmp34, atslab_1) ; /* tmp20 = */ aux_7 (tmp35, arg1) ; return /* (tmp20) */ ; } /* end of [tailjoin_retyp_check_6] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 4646(line=147, offs=9) -- 5064(line=158, offs=35) */ ATSstaticdec() ats_ptr_type aux_9 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_int_type, tmp54) ; __ats_lab_aux_9: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_6_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp48 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp47), atslab_hityp_node) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp50)->tag != 3) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp49 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp49 = tmp47 ; break ; } while (0) ; tmp52 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp49) ; tmp51 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg (arg0, tmp52) ; tmp54 = atspre_add_int_int (arg0, 1) ; tmp53 = aux_9 (tmp54, tmp48) ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp46, atslab_0, tmp51) ; ats_selptrset_mac(anairiats_sum_2, tmp46, atslab_1, tmp53) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp46 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp46) ; } /* end of [aux_9] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 3961(line=124, offs=4) -- 5965(line=185, offs=4) */ ATSstaticdec() anairiats_rec_4 tailjoin_funentry_update_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5) { /* local vardec */ ATSlocal (anairiats_rec_4, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; // ATSlocal_void (tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; __ats_lab_tailjoin_funentry_update_8: tmp37 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (arg4) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (tmp37) ; tmp39 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_tailjoined (tmp37) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (arg4) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp39, &ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body (arg4) ; tmp43 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_function (arg0, arg3, tmp41, tmp42, tmp40) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__intinf_make_int (arg5) ; tmp44 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (tmp45) ; tmp56 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (tmp38) ; tmp55 = aux_9 (0, tmp56) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_loc (arg4) ; tmp58 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_funclo_make (arg1) ; tmp60 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp40) ; tmp59 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret (tmp60) ; tmp62 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp62, atslab_0, tmp44) ; ats_selptrset_mac(anairiats_sum_2, tmp62, atslab_1, tmp55) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call (tmp57, tmp59, arg2, tmp58, tmp62) ; tmp63 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (arg4) ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_push () ; tmp65 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_vartypset_pop () ; /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push () ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_add (arg1) ; tmp68 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop () ; tmp69 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp69, atslab_0, tmp61) ; tmp70 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp69), atslab_1) ; tmp71 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp70) = tmp71 ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make (tmp57, tmp37, tmp63, tmp68, tmp65, tmp59, tmp69) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate (tmp72) ; tmp36.atslab_0 = arg5 ; tmp36.atslab_1 = tmp37 ; tmp36.atslab_2 = tmp39 ; tmp36.atslab_3 = tmp43 ; return (tmp36) ; } /* end of [tailjoin_funentry_update_8] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 6029(line=189, offs=5) -- 6669(line=208, offs=4) */ ATSstaticdec() ats_ptr_type tailjoin_funentrylst_update_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ref_type arg4, ats_ptr_type arg5, ats_int_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (anairiats_rec_4, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_int_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; __ats_lab_tailjoin_funentrylst_update_10: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_2, arg5, atslab_0) ; tmp76 = ats_caselptrlab_mac(anairiats_sum_2, arg5, atslab_1) ; tmp77 = tailjoin_funentry_update_8 (arg0, arg1, arg2, arg3, tmp75, arg6) ; tmp79 = ats_select_mac(tmp77, atslab_3) ; tmp78 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp78, atslab_0, tmp79) ; ats_selptrset_mac(anairiats_sum_2, tmp78, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp78 ; tmp81 = atspre_add_int_int (arg6, 1) ; tmp80 = tailjoin_funentrylst_update_10 (arg0, arg1, arg2, arg3, arg4, tmp76, tmp81) ; tmp82 = ats_select_mac(tmp77, atslab_0) ; tmp83 = ats_select_mac(tmp77, atslab_1) ; tmp84 = ats_select_mac(tmp77, atslab_2) ; tmp74 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp74, atslab_0, tmp82) ; ats_selptrset_mac(anairiats_sum_5, tmp74, atslab_1, tmp83) ; ats_selptrset_mac(anairiats_sum_5, tmp74, atslab_2, tmp84) ; ats_selptrset_mac(anairiats_sum_5, tmp74, atslab_3, tmp80) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp74 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp74) ; } /* end of [tailjoin_funentrylst_update_10] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 7668(line=241, offs=9) -- 7972(line=250, offs=8) */ ATSstaticdec() ats_ptr_type aux_vtps_12 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_aux_vtps_12: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp111 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp113 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp110) ; tmp112 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__vartypset_union (arg0, tmp113) ; arg0 = tmp112 ; arg1 = tmp111 ; goto __ats_lab_aux_vtps_12 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp109 = arg0 ; break ; } while (0) ; return (tmp109) ; } /* end of [aux_vtps_12] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 6769(line=213, offs=28) -- 8897(line=275, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_tailjoin_funentrylst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp85) ; ATSlocal (anairiats_rec_6, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_tailjoin_funentrylst: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp87 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp88 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp86.atslab_0 = tmp87 ; tmp86.atslab_1 = tmp88 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp89 = */ prerr_interror_0 () ; /* tmp90 = */ atspre_prerr_string (ATSstrcst(": tailjoin_funentrylst: empty funentrylst")) ; /* tmp91 = */ atspre_prerr_newline () ; /* tmp86 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp92 = ats_select_mac(tmp86, atslab_0) ; tmp93 = ats_select_mac(tmp86, atslab_1) ; tmp94 = tailjoin_name_make_1 (tmp92, tmp93) ; tmp96 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (tmp92) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp96) ; /* tmp97 = */ tailjoin_retyp_check_6 (tmp95, tmp93) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret (tmp95) ; tmp100 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lab (tmp92) ; tmp99 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (tmp100) ; tmp101 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp101, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; tmp102 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp101), atslab_1) ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp103, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_vararg) ; ats_ptrget_mac(ats_ptr_type, tmp102) = tmp103 ; tmp102 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_2, tmp103), atslab_1) ; tmp103 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp102) = tmp103 ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp95) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp99, tmp101, tmp105) ; tmp107 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp104) ; tmp106 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ (tmp94, tmp107) ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_vtps_all (tmp92) ; tmp114 = aux_vtps_12 (tmp108, tmp93) ; /* tmp115 = */ atsopt_funentry_set_vtps (tmp92, tmp114) ; /* tmp116 = */ atsopt_funentry_set_vtps_flag (tmp92) ; tmp117 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ (tmp106) ; /* ats_ptr_type tmp118 ; */ tmp118 = (ats_sum_ptr_type)0 ; tmp119 = tailjoin_funentrylst_update_10 (arg0, tmp106, tmp117, tmp98, (&tmp118), arg1, 0) ; tmp120 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp118) ; tmp121 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_lev (tmp92) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_push () ; tmp123 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_funlabset_pop () ; tmp124 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_make (arg0, tmp106, tmp121, tmp123, tmp114, tmp98, tmp120) ; /* tmp125 = */ atsopt_funentry_set_vtps_flag (tmp124) ; /* tmp126 = */ atsopt_funentry_set_tailjoin (tmp124, tmp119) ; /* tmp127 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_add_lablst (tmp106) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_associate (tmp124) ; return /* (tmp85) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__ccomp_tailjoin_funentrylst] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03894_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; __ats_lab_ref_make_elt_03894_ats_ptr_type: /* ats_ptr_type tmp130 ; */ tmp130 = arg0 ; tmp129 = atspre_ref_make_elt_tsz ((&tmp130), sizeof(ats_ptr_type)) ; return (tmp129) ; } /* end of [ref_make_elt_03894_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 9116(line=288, offs=20) -- 9351(line=297, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add: tmp133 = atspre_ref_get_view_ptr (statmp128) ; tmp134 = ats_selsin_mac(tmp133, atslab_1) ; tmp136 = ats_ptrget_mac(ats_ptr_type, tmp134) ; tmp135 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp135)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp135, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_7, tmp135, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp135, atslab_2, tmp136) ; ats_ptrget_mac(ats_ptr_type, tmp134) = tmp135 ; return /* (tmp132) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 9432(line=301, offs=7) -- 9855(line=312, offs=6) */ ATSstaticdec() ats_ptr_type aux_16 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_bool_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_aux_16: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp141 = &ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_2) ; tmp142 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab (arg0, tmp139) ; if (tmp142) { tmp138 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp138, atslab_0, tmp140) ; } else { tmp143 = ats_ptrget_mac(ats_ptr_type, tmp141) ; arg0 = arg0 ; arg1 = tmp143 ; goto __ats_lab_aux_16 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp138 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp138 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp138) ; } /* end of [aux_16] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 9414(line=300, offs=21) -- 9965(line=316, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_find: tmp144 = atspre_ref_get_view_ptr (statmp128) ; tmp145 = ats_selsin_mac(tmp144, atslab_1) ; tmp146 = ats_ptrget_mac(ats_ptr_type, tmp145) ; tmp137 = aux_16 (arg0, tmp146) ; return (tmp137) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_find] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 10029(line=319, offs=21) -- 10146(line=323, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark () { /* local vardec */ // ATSlocal_void (tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark: tmp148 = atspre_ref_get_view_ptr (statmp128) ; tmp149 = ats_selsin_mac(tmp148, atslab_1) ; tmp151 = ats_ptrget_mac(ats_ptr_type, tmp149) ; tmp150 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp150)->tag = 1 ; ats_selptrset_mac(anairiats_sum_9, tmp150, atslab_0, tmp151) ; ats_ptrget_mac(ats_ptr_type, tmp149) = tmp150 ; return /* (tmp147) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_mark] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 10283(line=329, offs=7) -- 10473(line=334, offs=6) */ ATSstaticdec() ats_ptr_type aux_19 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_aux_19: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp154 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_2) ; ATS_FREE(arg0) ; arg0 = tmp154 ; goto __ats_lab_aux_19 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; ATS_FREE(arg0) ; tmp153 = tmp155 ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp153 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTnil_0) ; break ; } while (0) ; return (tmp153) ; } /* end of [aux_19] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 10214(line=327, offs=3) -- 10584(line=338, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark () { /* local vardec */ // ATSlocal_void (tmp152) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark: tmp156 = atspre_ref_get_view_ptr (statmp128) ; tmp157 = ats_selsin_mac(tmp156, atslab_1) ; tmp159 = ats_ptrget_mac(ats_ptr_type, tmp157) ; tmp158 = aux_19 (tmp159) ; ats_ptrget_mac(ats_ptr_type, tmp157) = tmp158 ; return /* (tmp152) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__the_tailcalist_unmark] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 11121(line=360, offs=9) -- 11570(line=371, offs=8) */ ATSstaticdec() ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; // ATSlocal_void (tmp172) ; __ats_lab_aux_21: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp167 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_valprim_tmpvar (arg0, tmp166) ; /* tmp169 = */ atspre_fprint_string (arg0, ATSstrcst(" = va_arg(funarg, ")) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (tmp166) ; /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (arg0, tmp171) ; /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; arg0 = arg0 ; arg1 = tmp167 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: break ; } while (0) ; return /* (tmp165) */ ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 10716(line=346, offs=4) -- 11828(line=381, offs=4) */ ATSstaticdec() ats_void_type emit_tailjoin_case_20 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; __ats_lab_emit_tailjoin_case_20: /* tmp161 = */ atspre_fprintf_exn (arg0, ATSstrcst("case %i:\n"), arg1) ; /* tmp162 = */ atspre_fprint_string (arg0, ATSstrcst("va_start(funarg, ")) ; /* tmp163 = */ atspre_fprint_string (arg0, ATSstrcst("arg0")) ; /* tmp164 = */ atspre_fprint_string (arg0, ATSstrcst(") ;\n")) ; /* tmp173 = */ aux_21 (arg0, arg3) ; /* tmp174 = */ atspre_fprint_string (arg0, ATSstrcst("va_end(funarg) ;\n")) ; /* tmp175 = */ atspre_fprint_string (arg0, ATSstrcst("goto __ats_lab_")) ; /* tmp176 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_funlab (arg0, arg2) ; /* tmp160 = */ atspre_fprint_string (arg0, ATSstrcst(" ;\n\n")) ; return /* (tmp160) */ ; } /* end of [emit_tailjoin_case_20] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 12181(line=392, offs=9) -- 12435(line=396, offs=32) */ ATSstaticdec() ats_void_type aux_23 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp182) ; ATSlocal (ats_int_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; __ats_lab_aux_23: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp183 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp184 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_2) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_3) ; /* tmp187 = */ emit_tailjoin_case_20 (arg0, tmp183, tmp184, tmp185) ; arg0 = arg0 ; arg1 = tmp186 ; goto __ats_lab_aux_23 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: break ; } while (0) ; return /* (tmp182) */ ; } /* end of [aux_23] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_trans_tailcal.dats: 11892(line=384, offs=22) -- 12629(line=404, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tailjoinlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; // ATSlocal_void (tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tailjoinlst: /* tmp178 = */ atspre_fprint_string (arg0, ATSstrcst("va_list funarg ;\n\n")) ; /* tmp179 = */ atspre_fprint_string (arg0, ATSstrcst("switch (")) ; /* tmp180 = */ atspre_fprint_string (arg0, ATSstrcst("arg0")) ; /* tmp181 = */ atspre_fprint_string (arg0, ATSstrcst(") {\n")) ; /* tmp188 = */ aux_23 (arg0, arg1) ; /* tmp177 = */ atspre_fprint_string (arg0, ATSstrcst("default: exit(1) ; /* deadcode */\n} /* end of switch */\n\n")) ; return /* (tmp177) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tailjoinlst] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_charlst_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_trans_tailcal_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp128, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp131, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp131 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTnil_0) ; statmp128 = ref_make_elt_03894_ats_ptr_type (statmp131) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_trans_tailcal_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_dats.c0000664000175000017500000047640312223166160021236 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; typedef struct { atsopt_count_type atslab_tmplab_stamp ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_tmpvar_typ ; ats_int_type atslab_tmpvar_ret ; ats_int_type atslab_tmpvar_top ; atsopt_count_type atslab_tmpvar_stamp ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_funlab_name ; ats_int_type atslab_funlab_lev ; ats_ptr_type atslab_funlab_typ ; ats_ptr_type atslab_funlab_qua ; atsopt_count_type atslab_funlab_stamp ; ats_ptr_type atslab_funlab_tailjoined ; ats_ptr_type atslab_funlab_entry ; ats_int_type atslab_funlab_prfck ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_valprim_node ; ats_ptr_type atslab_valprim_typ ; } anairiats_rec_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_instr_loc ; ats_ptr_type atslab_instr_node ; } anairiats_rec_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_18 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; ats_ptr_type atslab_6 ; ats_ptr_type atslab_7 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_20 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; } anairiats_sum_21 ; /* external typedefs */ typedef anairiats_rec_3 *funlab_t ; typedef anairiats_rec_2 *tmpvar_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_ext_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_mac_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DCSTEXTDEFsome_sta_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VParg_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPargtmpref_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcastfn_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPchar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPclo_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcst_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPenv_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPext_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfix_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloat_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfloatsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPfun_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPint_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPintsp_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPptrof_var_offs_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPsizeof_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPstring_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmp_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtmpref_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_arr_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_tail_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_clo_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_fun_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_val_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdefine_partval_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRextval_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfreeptr_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunlab_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRdynload_file_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloopexn_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_arg_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRpatck_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_ptr_offs_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRstore_var_offs_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtmplabint_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_beg_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_end_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRprfck_tst_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_tostringf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp) (atsopt_count_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make) () ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmplab_stamp_make) () ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmpvar_stamp_make) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_char) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_double) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_string) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlab) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_funlab_set_qua) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call_tail) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_tmpvar_set_ret) (ats_ptr_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__funlab_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__sasp__tmpvar_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__sasp__tmplab_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_ptr_type _tmplab_make_1 () ; static ats_ptr_type aux_11 (ats_ptr_type arg0) ; static ats_ptr_type _funlab_make_21 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, atsopt_count_type arg3, ats_int_type arg4) ; static ats_ptr_type global_cst_name_make_24 (ats_ptr_type arg0) ; static ats_ptr_type instr_arr_heap_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_arr_stack_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_assgn_arr_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_assgn_clo_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_define_clo_86 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_define_fun_88 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_define_val_90 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_define_partval_92 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_extval_94 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_freeptr_96 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type instr_patck_98 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_dynload_file_100 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type instr_load_ptr_102 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_load_var_103 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_load_ptr_offs_104 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_load_var_offs_105 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_loop_109 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) ; static ats_ptr_type instr_loopexn_111 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_move_arg_113 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_move_con_115 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_move_lazy_delay_117 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_move_lazy_force_119 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type instr_move_rec_flt_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_move_rec_box_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_move_ref_124 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_move_val_126 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_raise_128 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_select_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_selcon_132 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4) ; static ats_ptr_type instr_selcon_ptr_134 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4) ; static ats_ptr_type instr_store_ptr_136 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_store_ptr_offs_137 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_store_var_139 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type instr_store_var_offs_140 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_switch_142 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type instr_tmplabint_144 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_ptr_type instr_trywith_146 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type instr_vardec_148 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 2110(line=68, offs=4) -- 2164(line=68, offs=58) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_ccomp)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 2290(line=80, offs=4) -- 2364(line=82, offs=2) */ ATSstaticdec() ats_ptr_type _tmplab_make_1 () { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (atsopt_count_type, tmp2) ; __ats_lab__tmplab_make_1: tmp2 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmplab_stamp_make () ; tmp1 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp1, atslab_tmplab_stamp, tmp2) ; return (tmp1) ; } /* end of [_tmplab_make_1] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 2428(line=86, offs=23) -- 2448(line=86, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make () { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make: tmp3 = _tmplab_make_1 () ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 2477(line=88, offs=28) -- 2499(line=88, offs=50) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_get_stamp: tmp4 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_tmplab_stamp) ; return (tmp4) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmplab_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 2527(line=92, offs=3) -- 2666(line=95, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; ATSlocal (atsopt_count_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab: /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("__ats_lab_")) ; tmp7 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_tmplab_stamp) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp7) ; return /* (tmp5) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmplab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 3099(line=121, offs=3) -- 3276(line=125, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; ATSlocal (atsopt_count_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar: /* tmp9 = */ atspre_fprint_string (arg0, ATSstrcst("tmp(")) ; tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_tmpvar_stamp) ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp11) ; /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp8) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 3352(line=130, offs=18) -- 3429(line=131, offs=63) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_tmpvar_tmpvar (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp12) ; ATSlocal (atsopt_count_type, tmp13) ; ATSlocal (atsopt_count_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_tmpvar_tmpvar: tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_stamp) ; tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_tmpvar_stamp) ; tmp12 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp13, tmp14) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_tmpvar_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 3492(line=135, offs=23) -- 3574(line=136, offs=68) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_tmpvar_tmpvar (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp15) ; ATSlocal (atsopt_count_type, tmp16) ; ATSlocal (atsopt_count_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_tmpvar_tmpvar: tmp16 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_stamp) ; tmp17 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg1), atslab_tmpvar_stamp) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp16, tmp17) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_tmpvar_tmpvar] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 3653(line=142, offs=13) -- 3864(line=151, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (atsopt_count_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make: tmp19 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tmpvar_stamp_make () ; tmp18 = ATS_MALLOC(sizeof(anairiats_rec_2)) ; ats_selptrset_mac(anairiats_rec_2, tmp18, atslab_tmpvar_typ, arg0) ; ats_selptrset_mac(anairiats_rec_2, tmp18, atslab_tmpvar_ret, 0) ; ats_selptrset_mac(anairiats_rec_2, tmp18, atslab_tmpvar_top, 0) ; ats_selptrset_mac(anairiats_rec_2, tmp18, atslab_tmpvar_stamp, tmp19) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4060(line=164, offs=17) -- 4147(line=167, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret: tmp21 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (arg0) ; /* tmp22 = */ atsopt_tmpvar_set_ret (tmp21, 1) ; tmp20 = tmp21 ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make_ret] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4300(line=176, offs=6) -- 4359(line=176, offs=65) */ ATSstaticdec() ats_ptr_type aux_11 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_aux_11: tmp26 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (arg0) ; tmp25 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_make (tmp26) ; return (tmp25) ; } /* end of [aux_11] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4246(line=174, offs=16) -- 4399(line=179, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarlst_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarlst_make: tmp24 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_decode (arg0) ; tmp23 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (tmp24, &aux_11) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarlst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4474(line=183, offs=26) -- 4496(line=183, offs=48) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_ret (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_ret: tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_ret) ; return (tmp27) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_ret] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4522(line=184, offs=26) -- 4544(line=184, offs=48) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_top (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_top: tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_top) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_top] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4572(line=185, offs=28) -- 4596(line=185, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_stamp: tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_stamp) ; return (tmp29) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4622(line=186, offs=26) -- 4644(line=186, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ: tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_typ) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4671(line=188, offs=26) -- 4710(line=188, offs=65) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void: tmp32 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_typ) ; tmp31 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void (tmp32) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 4741(line=190, offs=29) -- 4817(line=192, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_nonvoid (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp33) ; ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_nonvoid: tmp35 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_2, arg0), atslab_tmpvar_typ) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_t_is_void (tmp35) ; if (tmp34) { tmp33 = ats_false_bool ; } else { tmp33 = ats_true_bool ; } /* end of [if] */ return (tmp33) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_nonvoid] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 5337(line=218, offs=15) -- 5407(line=220, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab: tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_funlab_name) ; /* tmp36 = */ atspre_fprint_string (arg0, tmp37) ; return /* (tmp36) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__fprint_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 5462(line=223, offs=18) -- 5545(line=225, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp38) ; ATSlocal (atsopt_count_type, tmp39) ; ATSlocal (atsopt_count_type, tmp40) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab: tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_stamp) ; tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_funlab_stamp) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__eq_stamp_stamp (tmp39, tmp40) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__eq_funlab_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 5608(line=228, offs=23) -- 5696(line=230, offs=4) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp41) ; ATSlocal (atsopt_count_type, tmp42) ; ATSlocal (atsopt_count_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab: tmp42 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_stamp) ; tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg1), atslab_funlab_stamp) ; tmp41 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (tmp42, tmp43) ; return (tmp41) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_funlab_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 5756(line=234, offs=4) -- 6046(line=245, offs=2) */ ATSstaticdec() ats_ptr_type _funlab_make_21 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, atsopt_count_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab__funlab_make_21: tmp45 = (ats_sum_ptr_type)0 ; tmp46 = (ats_sum_ptr_type)0 ; tmp47 = (ats_sum_ptr_type)0 ; tmp44 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_name, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_lev, arg1) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_typ, arg2) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_qua, tmp45) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_stamp, arg3) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_tailjoined, tmp46) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_entry, tmp47) ; ats_selptrset_mac(anairiats_rec_3, tmp44, atslab_funlab_prfck, arg4) ; return (tmp44) ; } /* end of [_funlab_make_21] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 6098(line=248, offs=17) -- 6308(line=254, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_int_type, tmp49) ; ATSlocal (atsopt_count_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ: tmp49 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp50 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () ; tmp52 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp (tmp50) ; tmp51 = atspre_string_append (ATSstrcst("__ats_fun_"), tmp52) ; tmp48 = _funlab_make_21 (tmp51, tmp49, arg0, tmp50, 0) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 6370(line=258, offs=3) -- 6530(line=263, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_int_type, tmp54) ; ATSlocal (atsopt_count_type, tmp55) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ: tmp54 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp55 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () ; tmp53 = _funlab_make_21 (arg0, tmp54, arg1, tmp55, 0) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_nam_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 6588(line=267, offs=4) -- 7100(line=284, offs=4) */ ATSstaticdec() ats_ptr_type global_cst_name_make_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; __ats_lab_global_cst_name_make_24: tmp57 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_extdef (arg0) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp57)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp58 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_sym (arg0) ; tmp56 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp58) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp57)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_4, tmp57, atslab_0) ; tmp56 = tmp59 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp57)->tag != 3) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_4, tmp57, atslab_0) ; tmp56 = tmp60 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (((ats_sum_ptr_type)tmp57)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: /* tmp61 = */ prerr_interror_0 () ; /* tmp62 = */ atspre_prerr_string (ATSstrcst(": global_cst_name_make: DCSTEXTDEFcall: d2c = ")) ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2cst (arg0) ; /* tmp64 = */ atspre_prerr_newline () ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp56) ; } /* end of [global_cst_name_make_24] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 7188(line=290, offs=3) -- 7929(line=314, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_typ (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_int_type, tmp69) ; ATSlocal (atsopt_count_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; // ATSlocal_void (tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_typ: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp66 = ats_false_bool ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp66 = ats_true_bool ; break ; } while (0) ; if (tmp66) { tmp67 = global_cst_name_make_24 (arg0) ; } else { tmp68 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplstlst_normalize (arg1) ; tmp67 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__template_cst_name_make (arg0, tmp68) ; } /* end of [if] */ tmp69 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp70 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () ; tmp71 = _funlab_make_21 (tmp67, tmp69, arg2, tmp70, 0) ; if (tmp66) { tmp73 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp73, atslab_0, arg0) ; /* tmp72 = */ atsopt_funlab_set_qua (tmp71, tmp73) ; } else { /* empty */ } /* end of [if] */ tmp65 = tmp71 ; return (tmp65) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 7993(line=317, offs=21) -- 8348(line=326, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_var_typ (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (atsopt_count_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_var_typ: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_sym (arg0) ; tmp75 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (tmp76) ; tmp77 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__d2var_current_level_get () ; tmp78 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__tostring_stamp (tmp78) ; tmp80 = atspre_tostringf (ATSstrcst("%s_%s"), tmp75, tmp79) ; tmp74 = _funlab_make_21 (ats_castfn_mac(ats_ptr_type, tmp80), tmp77, arg1, tmp78, 0) ; return (tmp74) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_var_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 8435(line=331, offs=23) -- 8762(line=341, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_prfck (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (atsopt_count_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_prfck: tmp82 = global_cst_name_make_24 (arg0) ; tmp85 = (ats_sum_ptr_type)0 ; tmp86 = (ats_sum_ptr_type)0 ; tmp84 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_fun (tmp85, tmp86, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; tmp83 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp84) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__funlab_stamp_make () ; tmp88 = _funlab_make_21 (tmp82, 0, tmp83, tmp87, 1) ; tmp90 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ats_selptrset_mac(anairiats_sum_5, tmp90, atslab_0, arg0) ; /* tmp89 = */ atsopt_funlab_set_qua (tmp88, tmp90) ; tmp81 = tmp88 ; return (tmp81) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_make_cst_prfck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 8845(line=345, offs=26) -- 8865(line=345, offs=46) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_lev (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_lev: tmp91 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_lev) ; return (tmp91) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_lev] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 8893(line=347, offs=27) -- 8914(line=347, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name: tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_name) ; return (tmp92) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_name] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 8941(line=349, offs=26) -- 8961(line=349, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ: tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_typ) ; return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 8992(line=352, offs=20) -- 9356(line=363, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg: tmp96 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_typ) ; tmp95 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp96) ; tmp97 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp95), atslab_hityp_node) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp97)->tag != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_6, tmp97, atslab_1) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityplst_encode (tmp98) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: /* tmp99 = */ prerr_interror_0 () ; /* tmp100 = */ atspre_prerr_string (ATSstrcst(": funlab_get_typ_arg: hit_fun = ")) ; /* tmp101 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (tmp95) ; /* tmp102 = */ atspre_prerr_newline () ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 9418(line=366, offs=20) -- 9775(line=377, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; // ATSlocal_void (tmp108) ; // ATSlocal_void (tmp109) ; // ATSlocal_void (tmp110) ; // ATSlocal_void (tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res: tmp105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_typ) ; tmp104 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp105) ; tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp104), atslab_hityp_node) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp106)->tag != 2) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_6, tmp106, atslab_2) ; tmp103 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp107) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: __ats_lab_9_1: /* tmp108 = */ prerr_interror_0 () ; /* tmp109 = */ atspre_prerr_string (ATSstrcst(": funlab_get_typ_res: hit_fun = ")) ; /* tmp110 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (tmp104) ; /* tmp111 = */ atspre_prerr_newline () ; /* tmp103 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp103) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ_res] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 9836(line=380, offs=19) -- 10175(line=390, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo: tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_typ) ; tmp113 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp114) ; tmp115 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp113), atslab_hityp_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp115)->tag != 2) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_6, tmp115, atslab_0) ; tmp112 = tmp116 ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: /* tmp117 = */ prerr_interror_0 () ; /* tmp118 = */ atspre_prerr_string (ATSstrcst(": funlab_get_funclo: hit_fun = ")) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__prerr_hityp (tmp113) ; /* tmp120 = */ atspre_prerr_newline () ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp112) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10232(line=392, offs=26) -- 10252(line=392, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua: tmp121 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_qua) ; return (tmp121) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_qua] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10286(line=394, offs=33) -- 10313(line=394, offs=60) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_tailjoined (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp122) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_tailjoined: tmp122 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_tailjoined) ; return (tmp122) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_tailjoined] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10342(line=396, offs=28) -- 10364(line=396, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry: tmp123 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_entry) ; return (tmp123) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10398(line=399, offs=23) -- 10648(line=406, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some: tmp125 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_entry) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp125 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_5, tmp125, atslab_0) ; tmp124 = tmp126 ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp125 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp127 = */ prerr_interror_0 () ; /* tmp128 = */ atspre_prerr_string (ATSstrcst(": funlab_get_entry_some: fl = ")) ; /* tmp129 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__prerr_funlab (arg0) ; /* tmp130 = */ atspre_prerr_newline () ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp124) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_entry_some] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10714(line=408, offs=28) -- 10736(line=408, offs=50) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck: tmp131 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_funlab_prfck) ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_prfck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 10809(line=415, offs=18) -- 11117(line=428, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const: tmp133 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_valprim_node) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp133)->tag != 3) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp133)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp134 = ats_caselptrlab_mac(anairiats_sum_8, tmp133, atslab_1) ; arg0 = tmp134 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp133)->tag != 5) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp133)->tag != 7) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp133)->tag != 12) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp133)->tag != 14) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp133)->tag != 15) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp133)->tag != 20) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp133)->tag != 21) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp133)->tag != 24) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp133)->tag != 25) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp132 = ats_true_bool ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp132 = ats_false_bool ; break ; } while (0) ; return (tmp132) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_const] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11198(line=434, offs=20) -- 11379(line=441, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable: tmp136 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_valprim_node) ; do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp136)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp135 = ats_true_bool ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp136)->tag != 23) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp135 = ats_true_bool ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp136)->tag != 4) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp137 = ats_caselptrlab_mac(anairiats_sum_8, tmp136, atslab_1) ; arg0 = tmp137 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp136)->tag != 2) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp135 = ats_true_bool ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp135 = ats_false_bool ; break ; } while (0) ; return (tmp135) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_mutable] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11455(line=446, offs=13) -- 11514(line=448, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg: tmp139 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp139)->tag = 0 ; ats_selptrset_mac(anairiats_sum_9, tmp139, atslab_0, arg0) ; tmp138 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp138, atslab_valprim_node, tmp139) ; ats_selptrset_mac(anairiats_rec_7, tmp138, atslab_valprim_typ, arg1) ; return (tmp138) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11565(line=451, offs=16) -- 11627(line=453, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argref (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argref: tmp141 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp141)->tag = 1 ; ats_selptrset_mac(anairiats_sum_9, tmp141, atslab_0, arg0) ; tmp140 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp140, atslab_valprim_node, tmp141) ; ats_selptrset_mac(anairiats_rec_7, tmp140, atslab_valprim_typ, arg1) ; return (tmp140) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argref] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11684(line=456, offs=19) -- 11749(line=458, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argtmpref (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argtmpref: tmp143 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp143)->tag = 2 ; ats_selptrset_mac(anairiats_sum_9, tmp143, atslab_0, arg0) ; tmp142 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp142, atslab_valprim_node, tmp143) ; ats_selptrset_mac(anairiats_rec_7, tmp142, atslab_valprim_typ, arg1) ; return (tmp142) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_argtmpref] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11825(line=463, offs=14) -- 11900(line=465, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool (ats_bool_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool: tmp145 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp145)->tag = 3 ; ats_selptrset_mac(anairiats_sum_10, tmp145, atslab_0, arg0) ; tmp146 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_bool) ; tmp144 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp144, atslab_valprim_node, tmp145) ; ats_selptrset_mac(anairiats_rec_7, tmp144, atslab_valprim_typ, tmp146) ; return (tmp144) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 11952(line=468, offs=16) -- 12026(line=470, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_castfn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_castfn: tmp148 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp148)->tag = 4 ; ats_selptrset_mac(anairiats_sum_8, tmp148, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp148, atslab_1, arg1) ; tmp147 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp147, atslab_valprim_node, tmp148) ; ats_selptrset_mac(anairiats_rec_7, tmp147, atslab_valprim_typ, arg2) ; return (tmp147) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_castfn] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12078(line=473, offs=14) -- 12153(line=475, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char (ats_char_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char: tmp150 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp150)->tag = 5 ; ats_selptrset_mac(anairiats_sum_11, tmp150, atslab_0, arg0) ; tmp151 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_char) ; tmp149 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp149, atslab_valprim_node, tmp150) ; ats_selptrset_mac(anairiats_rec_7, tmp149, atslab_valprim_typ, tmp151) ; return (tmp149) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_char] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12202(line=478, offs=13) -- 12265(line=480, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst: tmp153 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp153)->tag = 7 ; ats_selptrset_mac(anairiats_sum_4, tmp153, atslab_0, arg0) ; tmp152 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp152, atslab_valprim_node, tmp153) ; ats_selptrset_mac(anairiats_rec_7, tmp152, atslab_valprim_typ, arg1) ; return (tmp152) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12315(line=483, offs=15) -- 12390(line=485, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cstsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cstsp: tmp155 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp155)->tag = 8 ; ats_selptrset_mac(anairiats_sum_8, tmp155, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp155, atslab_1, arg1) ; tmp154 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp154, atslab_valprim_node, tmp155) ; ats_selptrset_mac(anairiats_rec_7, tmp154, atslab_valprim_typ, arg2) ; return (tmp154) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12440(line=488, offs=13) -- 12499(line=490, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env: tmp157 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp157)->tag = 9 ; ats_selptrset_mac(anairiats_sum_4, tmp157, atslab_0, arg0) ; tmp156 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp156, atslab_valprim_node, tmp157) ; ats_selptrset_mac(anairiats_rec_7, tmp156, atslab_valprim_typ, arg1) ; return (tmp156) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_env] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12547(line=493, offs=13) -- 12610(line=495, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext: tmp159 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp159)->tag = 10 ; ats_selptrset_mac(anairiats_sum_4, tmp159, atslab_0, arg0) ; tmp158 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp158, atslab_valprim_node, tmp159) ; ats_selptrset_mac(anairiats_rec_7, tmp158, atslab_valprim_typ, arg1) ; return (tmp158) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ext] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12679(line=500, offs=13) -- 12743(line=502, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix: tmp161 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp161)->tag = 11 ; ats_selptrset_mac(anairiats_sum_4, tmp161, atslab_0, arg0) ; tmp160 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp160, atslab_valprim_node, tmp161) ; ats_selptrset_mac(anairiats_rec_7, tmp160, atslab_valprim_typ, arg1) ; return (tmp160) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12814(line=507, offs=15) -- 12900(line=509, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float: tmp163 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp163)->tag = 12 ; ats_selptrset_mac(anairiats_sum_4, tmp163, atslab_0, arg0) ; tmp164 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_double) ; tmp162 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp162, atslab_valprim_node, tmp163) ; ats_selptrset_mac(anairiats_rec_7, tmp162, atslab_valprim_typ, tmp164) ; return (tmp162) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_float] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 12954(line=512, offs=17) -- 13015(line=514, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp: tmp166 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp166)->tag = 13 ; ats_selptrset_mac(anairiats_sum_4, tmp166, atslab_0, arg0) ; tmp165 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp165, atslab_valprim_node, tmp166) ; ats_selptrset_mac(anairiats_rec_7, tmp165, atslab_valprim_typ, arg1) ; return (tmp165) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13088(line=519, offs=13) -- 13251(line=523, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_clo (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_bool_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_clo: tmp169 = atspre_neq_int_int (arg0, 0) ; if (tmp169) { tmp168 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr ; } else { tmp168 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_clo ; } /* end of [if] */ tmp170 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ((ats_sum_ptr_type)tmp170)->tag = 6 ; ats_selptrset_mac(anairiats_sum_12, tmp170, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_12, tmp170, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_12, tmp170, atslab_2, arg2) ; tmp171 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (tmp168) ; tmp167 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp167, atslab_valprim_node, tmp170) ; ats_selptrset_mac(anairiats_rec_7, tmp167, atslab_valprim_typ, tmp171) ; return (tmp167) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_clo] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13299(line=526, offs=13) -- 13379(line=528, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun: tmp173 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp173)->tag = 14 ; ats_selptrset_mac(anairiats_sum_4, tmp173, atslab_0, arg0) ; tmp174 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funlab_get_typ (arg0) ; tmp172 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp172, atslab_valprim_node, tmp173) ; ats_selptrset_mac(anairiats_rec_7, tmp172, atslab_valprim_typ, tmp174) ; return (tmp172) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13448(line=533, offs=13) -- 13527(line=535, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int: tmp176 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp176)->tag = 15 ; ats_selptrset_mac(anairiats_sum_4, tmp176, atslab_0, arg0) ; tmp177 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; tmp175 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp175, atslab_valprim_node, tmp176) ; ats_selptrset_mac(anairiats_rec_7, tmp175, atslab_valprim_typ, tmp177) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_int] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13577(line=538, offs=15) -- 13684(line=541, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp: tmp179 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp179)->tag = 16 ; ats_selptrset_mac(anairiats_sum_8, tmp179, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp179, atslab_1, arg1) ; tmp178 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp178, atslab_valprim_node, tmp179) ; ats_selptrset_mac(anairiats_rec_7, tmp178, atslab_valprim_typ, arg2) ; return (tmp178) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13757(line=546, offs=15) -- 13834(line=548, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof: tmp181 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp181)->tag = 17 ; ats_selptrset_mac(anairiats_sum_4, tmp181, atslab_0, arg0) ; tmp182 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp180 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp180, atslab_valprim_node, tmp181) ; ats_selptrset_mac(anairiats_rec_7, tmp180, atslab_valprim_typ, tmp182) ; return (tmp180) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 13897(line=552, offs=3) -- 14113(line=558, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp184 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp184)->tag = 18 ; ats_selptrset_mac(anairiats_sum_8, tmp184, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp184, atslab_1, arg1) ; tmp185 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp183 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp183, atslab_valprim_node, tmp184) ; ats_selptrset_mac(anairiats_rec_7, tmp183, atslab_valprim_typ, tmp185) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_32_1: tmp183 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof (arg0) ; break ; } while (0) ; return (tmp183) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_ptr_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 14185(line=562, offs=3) -- 14401(line=568, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_var_offs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_var_offs: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp187 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp187)->tag = 19 ; ats_selptrset_mac(anairiats_sum_8, tmp187, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp187, atslab_1, arg1) ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_ptr) ; tmp186 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp186, atslab_valprim_node, tmp187) ; ats_selptrset_mac(anairiats_rec_7, tmp186, atslab_valprim_typ, tmp188) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp186 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof (arg0) ; break ; } while (0) ; return (tmp186) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_ptrof_var_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 14484(line=573, offs=16) -- 14565(line=576, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof: tmp190 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp190)->tag = 20 ; ats_selptrset_mac(anairiats_sum_4, tmp190, atslab_0, arg0) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_int) ; tmp189 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp189, atslab_valprim_node, tmp190) ; ats_selptrset_mac(anairiats_rec_7, tmp189, atslab_valprim_typ, tmp191) ; return (tmp189) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_sizeof] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 14619(line=579, offs=16) -- 14715(line=582, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string: tmp193 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp193)->tag = 21 ; ats_selptrset_mac(anairiats_sum_13, tmp193, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_13, tmp193, atslab_1, arg1) ; tmp194 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_string) ; tmp192 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp192, atslab_valprim_node, tmp193) ; ats_selptrset_mac(anairiats_rec_7, tmp192, atslab_valprim_typ, tmp194) ; return (tmp192) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_string] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 14766(line=585, offs=13) -- 14837(line=587, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp: tmp196 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp196)->tag = 22 ; ats_selptrset_mac(anairiats_sum_4, tmp196, atslab_0, arg0) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (arg0) ; tmp195 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp195, atslab_valprim_node, tmp196) ; ats_selptrset_mac(anairiats_rec_7, tmp195, atslab_valprim_typ, tmp197) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmp] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 14888(line=590, offs=16) -- 14962(line=592, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref: tmp199 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp199)->tag = 23 ; ats_selptrset_mac(anairiats_sum_4, tmp199, atslab_0, arg0) ; tmp200 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (arg0) ; tmp198 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp198, atslab_valprim_node, tmp199) ; ats_selptrset_mac(anairiats_rec_7, tmp198, atslab_valprim_typ, tmp200) ; return (tmp198) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_tmpref] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15013(line=595, offs=13) -- 15068(line=597, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top: tmp202 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPtop_24) ; tmp201 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp201, atslab_valprim_node, tmp202) ; ats_selptrset_mac(anairiats_rec_7, tmp201, atslab_valprim_typ, arg0) ; return (tmp201) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_top] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15117(line=600, offs=14) -- 15192(line=602, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void () { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void: tmp204 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__VPvoid_25) ; tmp205 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_encode (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_void) ; tmp203 = ATS_MALLOC(sizeof(anairiats_rec_7)) ; ats_selptrset_mac(anairiats_rec_7, tmp203, atslab_valprim_node, tmp204) ; ats_selptrset_mac(anairiats_rec_7, tmp203, atslab_valprim_typ, tmp205) ; return (tmp203) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_void] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15266(line=607, offs=17) -- 15328(line=609, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_void (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_void: tmp208 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_valprim_typ) ; tmp207 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_decode (tmp208) ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__hityp_is_void (tmp207) ; return (tmp206) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__valprim_is_void] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15402(line=615, offs=3) -- 15526(line=618, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call: tmp210 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp210)->tag = 4 ; ats_selptrset_mac(anairiats_sum_15, tmp210, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp210, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp210, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp210, atslab_3, arg4) ; tmp209 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp209, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp209, atslab_instr_node, tmp210) ; return (tmp209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15577(line=621, offs=17) -- 15643(line=623, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call_tail (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call_tail: tmp212 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp212)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp212, atslab_0, arg1) ; tmp211 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp211, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp211, atslab_instr_node, tmp212) ; return (tmp211) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call_tail] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15715(line=628, offs=12) -- 15810(line=630, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_cond (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_cond: tmp214 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp214)->tag = 6 ; ats_selptrset_mac(anairiats_sum_6, tmp214, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp214, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp214, atslab_2, arg3) ; tmp213 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp213, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp213, atslab_instr_node, tmp214) ; return (tmp213) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_cond] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 15883(line=636, offs=3) -- 16009(line=639, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_function (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_function: tmp216 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp216)->tag = 14 ; ats_selptrset_mac(anairiats_sum_15, tmp216, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp216, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp216, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp216, atslab_3, arg4) ; tmp215 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp215, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp215, atslab_instr_node, tmp216) ; return (tmp215) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_function] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16082(line=644, offs=14) -- 16156(line=646, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab: tmp218 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp218)->tag = 15 ; ats_selptrset_mac(anairiats_sum_4, tmp218, atslab_0, arg0) ; tmp217 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp217, atslab_instr_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_14, tmp217, atslab_instr_node, tmp218) ; return (tmp217) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_funlab] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16230(line=651, offs=17) -- 16310(line=654, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_beg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_beg: tmp220 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp220)->tag = 42 ; ats_selptrset_mac(anairiats_sum_4, tmp220, atslab_0, arg0) ; tmp219 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp219, atslab_instr_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_14, tmp219, atslab_instr_node, tmp220) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_beg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16337(line=656, offs=17) -- 16417(line=659, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst: tmp222 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp222)->tag = 44 ; ats_selptrset_mac(anairiats_sum_4, tmp222, atslab_0, arg0) ; tmp221 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp221, atslab_instr_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_14, tmp221, atslab_instr_node, tmp222) ; return (tmp221) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_tst] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16444(line=661, offs=17) -- 16524(line=664, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_end (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_end: tmp224 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp224)->tag = 43 ; ats_selptrset_mac(anairiats_sum_4, tmp224, atslab_0, arg0) ; tmp223 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp223, atslab_instr_loc, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; ats_selptrset_mac(anairiats_rec_14, tmp223, atslab_instr_node, tmp224) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_prfck_end] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16551(line=668, offs=5) -- 16714(line=674, offs=2) */ ATSstaticdec() ats_ptr_type instr_arr_heap_76 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; __ats_lab_instr_arr_heap_76: tmp226 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp226)->tag = 0 ; ats_selptrset_mac(anairiats_sum_16, tmp226, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp226, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp226, atslab_2, arg3) ; tmp225 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp225, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp225, atslab_instr_node, tmp226) ; return (tmp225) ; } /* end of [instr_arr_heap_76] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16774(line=678, offs=3) -- 16892(line=680, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_heap (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_heap: tmp229 = instr_arr_heap_76 (arg1, arg2, arg3, arg4) ; tmp228 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp228, atslab_0, tmp229) ; ats_selptrset_mac(anairiats_sum_17, tmp228, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp228 ; return /* (tmp227) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_heap] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 16950(line=684, offs=5) -- 17183(line=693, offs=2) */ ATSstaticdec() ats_ptr_type instr_arr_stack_78 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_instr_arr_stack_78: tmp231 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp231)->tag = 1 ; ats_selptrset_mac(anairiats_sum_18, tmp231, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp231, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_18, tmp231, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_18, tmp231, atslab_3, arg4) ; tmp230 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp230, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp230, atslab_instr_node, tmp231) ; return (tmp230) ; } /* end of [instr_arr_stack_78] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 17245(line=697, offs=3) -- 17384(line=699, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_stack (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_stack: tmp234 = instr_arr_stack_78 (arg1, arg2, arg3, arg4, arg5) ; tmp233 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp233, atslab_0, tmp234) ; ats_selptrset_mac(anairiats_sum_17, tmp233, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp233 ; return /* (tmp232) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_arr_stack] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 17443(line=703, offs=5) -- 17645(line=710, offs=2) */ ATSstaticdec() ats_ptr_type instr_assgn_arr_80 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; __ats_lab_instr_assgn_arr_80: tmp236 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp236)->tag = 2 ; ats_selptrset_mac(anairiats_sum_15, tmp236, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp236, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp236, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp236, atslab_3, arg4) ; tmp235 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp235, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp235, atslab_instr_node, tmp236) ; return (tmp235) ; } /* end of [instr_assgn_arr_80] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 17707(line=714, offs=3) -- 17836(line=715, offs=77) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_arr (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_arr: tmp239 = instr_assgn_arr_80 (arg1, arg2, arg3, arg4, arg5) ; tmp238 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp238, atslab_0, tmp239) ; ats_selptrset_mac(anairiats_sum_17, tmp238, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp238 ; return /* (tmp237) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_arr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 17895(line=720, offs=5) -- 18087(line=729, offs=2) */ ATSstaticdec() ats_ptr_type instr_assgn_clo_82 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; __ats_lab_instr_assgn_clo_82: tmp241 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp241)->tag = 3 ; ats_selptrset_mac(anairiats_sum_15, tmp241, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp241, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp241, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp241, atslab_3, arg4) ; tmp240 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp240, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp240, atslab_instr_node, tmp241) ; return (tmp240) ; } /* end of [instr_assgn_clo_82] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 18149(line=733, offs=3) -- 18264(line=734, offs=77) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_clo (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_clo: tmp244 = instr_assgn_clo_82 (arg1, arg2, arg3, arg4, arg5) ; tmp243 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp243, atslab_0, tmp244) ; ats_selptrset_mac(anairiats_sum_17, tmp243, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp243 ; return /* (tmp242) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_assgn_clo] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 18346(line=741, offs=3) -- 18501(line=745, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call (arg1, arg2, arg3, arg4, arg5) ; tmp247 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_17, tmp247, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp247 ; return /* (tmp245) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 18560(line=748, offs=21) -- 18631(line=749, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call_tail (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call_tail: tmp250 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_call_tail (arg1, arg2) ; tmp249 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp249, atslab_0, tmp250) ; ats_selptrset_mac(anairiats_sum_17, tmp249, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp249 ; return /* (tmp248) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_call_tail] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 18690(line=754, offs=5) -- 18822(line=758, offs=2) */ ATSstaticdec() ats_ptr_type instr_define_clo_86 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; __ats_lab_instr_define_clo_86: tmp252 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp252)->tag = 7 ; ats_selptrset_mac(anairiats_sum_8, tmp252, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp252, atslab_1, arg2) ; tmp251 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp251, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp251, atslab_instr_node, tmp252) ; return (tmp251) ; } /* end of [instr_define_clo_86] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 18884(line=761, offs=22) -- 18966(line=762, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_clo (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_clo: tmp255 = instr_define_clo_86 (arg1, arg2, arg3) ; tmp254 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp254, atslab_0, tmp255) ; ats_selptrset_mac(anairiats_sum_17, tmp254, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp254 ; return /* (tmp253) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_clo] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19005(line=765, offs=5) -- 19137(line=769, offs=2) */ ATSstaticdec() ats_ptr_type instr_define_fun_88 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_instr_define_fun_88: tmp257 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp257)->tag = 8 ; ats_selptrset_mac(anairiats_sum_8, tmp257, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp257, atslab_1, arg2) ; tmp256 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp256, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp256, atslab_instr_node, tmp257) ; return (tmp256) ; } /* end of [instr_define_fun_88] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19199(line=772, offs=22) -- 19281(line=773, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_fun (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_fun: tmp260 = instr_define_fun_88 (arg1, arg2, arg3) ; tmp259 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp259, atslab_0, tmp260) ; ats_selptrset_mac(anairiats_sum_17, tmp259, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp259 ; return /* (tmp258) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19320(line=776, offs=5) -- 19451(line=780, offs=2) */ ATSstaticdec() ats_ptr_type instr_define_val_90 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; __ats_lab_instr_define_val_90: tmp262 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp262)->tag = 9 ; ats_selptrset_mac(anairiats_sum_8, tmp262, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp262, atslab_1, arg2) ; tmp261 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp261, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp261, atslab_instr_node, tmp262) ; return (tmp261) ; } /* end of [instr_define_val_90] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19513(line=783, offs=22) -- 19595(line=784, offs=61) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_val (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_val: tmp265 = instr_define_val_90 (arg1, arg2, arg3) ; tmp264 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp264, atslab_0, tmp265) ; ats_selptrset_mac(anairiats_sum_17, tmp264, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp264 ; return /* (tmp263) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_val] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19702(line=792, offs=5) -- 19842(line=796, offs=2) */ ATSstaticdec() ats_ptr_type instr_define_partval_92 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; __ats_lab_instr_define_partval_92: tmp267 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp267)->tag = 10 ; ats_selptrset_mac(anairiats_sum_8, tmp267, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp267, atslab_1, arg2) ; tmp266 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp266, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp266, atslab_instr_node, tmp267) ; return (tmp266) ; } /* end of [instr_define_partval_92] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 19912(line=799, offs=26) -- 20000(line=800, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_partval (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_partval: tmp270 = instr_define_partval_92 (arg1, arg2, arg3) ; tmp269 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp269, atslab_0, tmp270) ; ats_selptrset_mac(anairiats_sum_17, tmp269, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp269 ; return /* (tmp268) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_define_partval] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20064(line=805, offs=5) -- 20188(line=809, offs=2) */ ATSstaticdec() ats_ptr_type instr_extval_94 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; __ats_lab_instr_extval_94: tmp272 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp272)->tag = 12 ; ats_selptrset_mac(anairiats_sum_8, tmp272, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp272, atslab_1, arg2) ; tmp271 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp271, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp271, atslab_instr_node, tmp272) ; return (tmp271) ; } /* end of [instr_extval_94] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20242(line=812, offs=18) -- 20322(line=813, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_extval (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_extval: tmp275 = instr_extval_94 (arg1, arg2, arg3) ; tmp274 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp274, atslab_0, tmp275) ; ats_selptrset_mac(anairiats_sum_17, tmp274, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp274 ; return /* (tmp273) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20378(line=818, offs=5) -- 20481(line=821, offs=2) */ ATSstaticdec() ats_ptr_type instr_freeptr_96 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; __ats_lab_instr_freeptr_96: tmp277 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp277)->tag = 13 ; ats_selptrset_mac(anairiats_sum_4, tmp277, atslab_0, arg1) ; tmp276 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp276, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp276, atslab_instr_node, tmp277) ; return (tmp276) ; } /* end of [instr_freeptr_96] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20537(line=824, offs=19) -- 20606(line=825, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr: tmp280 = instr_freeptr_96 (arg1, arg2) ; tmp279 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp279, atslab_0, tmp280) ; ats_selptrset_mac(anairiats_sum_17, tmp279, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp279 ; return /* (tmp278) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_freeptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20663(line=830, offs=5) -- 20805(line=835, offs=2) */ ATSstaticdec() ats_ptr_type instr_patck_98 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; __ats_lab_instr_patck_98: tmp282 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp282)->tag = 31 ; ats_selptrset_mac(anairiats_sum_6, tmp282, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp282, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp282, atslab_2, arg3) ; tmp281 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp281, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp281, atslab_instr_node, tmp282) ; return (tmp281) ; } /* end of [instr_patck_98] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 20857(line=838, offs=17) -- 20950(line=839, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck: tmp285 = instr_patck_98 (arg1, arg2, arg3, arg4) ; tmp284 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp284, atslab_0, tmp285) ; ats_selptrset_mac(anairiats_sum_17, tmp284, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp284 ; return /* (tmp283) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_patck] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21005(line=844, offs=5) -- 21118(line=847, offs=2) */ ATSstaticdec() ats_ptr_type instr_dynload_file_100 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_instr_dynload_file_100: tmp287 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp287)->tag = 16 ; ats_selptrset_mac(anairiats_sum_4, tmp287, atslab_0, arg1) ; tmp286 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp286, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp286, atslab_instr_node, tmp287) ; return (tmp286) ; } /* end of [instr_dynload_file_100] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21179(line=850, offs=24) -- 21255(line=851, offs=59) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file: tmp290 = instr_dynload_file_100 (arg1, arg2) ; tmp289 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp289, atslab_0, tmp290) ; ats_selptrset_mac(anairiats_sum_17, tmp289, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp289 ; return /* (tmp288) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_dynload_file] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21317(line=856, offs=5) -- 21445(line=860, offs=2) */ ATSstaticdec() ats_ptr_type instr_load_ptr_102 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; __ats_lab_instr_load_ptr_102: tmp292 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp292)->tag = 17 ; ats_selptrset_mac(anairiats_sum_8, tmp292, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp292, atslab_1, arg2) ; tmp291 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp291, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp291, atslab_instr_node, tmp292) ; return (tmp291) ; } /* end of [instr_load_ptr_102] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21478(line=862, offs=5) -- 21606(line=866, offs=2) */ ATSstaticdec() ats_ptr_type instr_load_var_103 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; __ats_lab_instr_load_var_103: tmp294 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp294)->tag = 19 ; ats_selptrset_mac(anairiats_sum_8, tmp294, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp294, atslab_1, arg2) ; tmp293 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp293, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp293, atslab_instr_node, tmp294) ; return (tmp293) ; } /* end of [instr_load_var_103] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21639(line=868, offs=5) -- 21800(line=872, offs=2) */ ATSstaticdec() ats_ptr_type instr_load_ptr_offs_104 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; __ats_lab_instr_load_ptr_offs_104: tmp296 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp296)->tag = 18 ; ats_selptrset_mac(anairiats_sum_6, tmp296, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp296, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp296, atslab_2, arg3) ; tmp295 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp295, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp295, atslab_instr_node, tmp296) ; return (tmp295) ; } /* end of [instr_load_ptr_offs_104] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 21838(line=874, offs=5) -- 21999(line=878, offs=2) */ ATSstaticdec() ats_ptr_type instr_load_var_offs_105 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; __ats_lab_instr_load_var_offs_105: tmp298 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp298)->tag = 20 ; ats_selptrset_mac(anairiats_sum_6, tmp298, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp298, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp298, atslab_2, arg3) ; tmp297 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp297, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp297, atslab_instr_node, tmp298) ; return (tmp297) ; } /* end of [instr_load_var_offs_105] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 22064(line=882, offs=3) -- 22154(line=884, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr: tmp301 = instr_load_ptr_102 (arg1, arg2, arg3) ; tmp300 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp300, atslab_0, tmp301) ; ats_selptrset_mac(anairiats_sum_17, tmp300, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp300 ; return /* (tmp299) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 22226(line=888, offs=3) -- 22473(line=896, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr_offs (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr_offs: do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp303 = instr_load_ptr_offs_104 (arg1, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp303 = instr_load_ptr_102 (arg1, arg2, arg3) ; break ; } while (0) ; tmp304 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp304, atslab_0, tmp303) ; ats_selptrset_mac(anairiats_sum_17, tmp304, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp304 ; return /* (tmp302) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_ptr_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 22550(line=900, offs=3) -- 22797(line=908, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp306 = instr_load_var_offs_105 (arg1, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp306 = instr_load_var_103 (arg1, arg2, arg3) ; break ; } while (0) ; tmp307 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp307, atslab_0, tmp306) ; ats_selptrset_mac(anairiats_sum_17, tmp307, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp307 ; return /* (tmp305) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_load_var_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 22863(line=912, offs=5) -- 23230(line=927, offs=2) */ ATSstaticdec() ats_ptr_type instr_loop_109 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7, ats_ptr_type arg8) { /* local vardec */ ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; __ats_lab_instr_loop_109: tmp309 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ((ats_sum_ptr_type)tmp309)->tag = 21 ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_4, arg5) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_5, arg6) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_6, arg7) ; ats_selptrset_mac(anairiats_sum_19, tmp309, atslab_7, arg8) ; tmp308 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp308, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp308, atslab_instr_node, tmp309) ; return (tmp308) ; } /* end of [instr_loop_109] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 23280(line=930, offs=16) -- 23587(line=944, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loop (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6, ats_ptr_type arg7, ats_ptr_type arg8, ats_ptr_type arg9) { /* local vardec */ // ATSlocal_void (tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loop: tmp311 = instr_loop_109 (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) ; tmp312 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp312, atslab_0, tmp311) ; ats_selptrset_mac(anairiats_sum_17, tmp312, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp312 ; return /* (tmp310) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loop] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 23620(line=946, offs=5) -- 23742(line=950, offs=2) */ ATSstaticdec() ats_ptr_type instr_loopexn_111 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; __ats_lab_instr_loopexn_111: tmp314 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp314)->tag = 22 ; ats_selptrset_mac(anairiats_sum_20, tmp314, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp314, atslab_1, arg2) ; tmp313 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp313, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp313, atslab_instr_node, tmp314) ; return (tmp313) ; } /* end of [instr_loopexn_111] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 23798(line=953, offs=19) -- 23878(line=954, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn: tmp317 = instr_loopexn_111 (arg1, arg2, arg3) ; tmp316 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp316, atslab_0, tmp317) ; ats_selptrset_mac(anairiats_sum_17, tmp316, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp316 ; return /* (tmp315) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 23935(line=959, offs=5) -- 24058(line=963, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_arg_113 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_instr_move_arg_113: tmp319 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp319)->tag = 23 ; ats_selptrset_mac(anairiats_sum_20, tmp319, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_20, tmp319, atslab_1, arg2) ; tmp318 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp318, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp318, atslab_instr_node, tmp319) ; return (tmp318) ; } /* end of [instr_move_arg_113] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 24118(line=967, offs=3) -- 24198(line=968, offs=59) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_arg (ats_ref_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_arg: tmp322 = instr_move_arg_113 (arg1, arg2, arg3) ; tmp321 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp321, atslab_0, tmp322) ; ats_selptrset_mac(anairiats_sum_17, tmp321, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp321 ; return /* (tmp320) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 24235(line=971, offs=5) -- 24434(line=979, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_con_115 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; __ats_lab_instr_move_con_115: tmp324 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp324)->tag = 24 ; ats_selptrset_mac(anairiats_sum_15, tmp324, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp324, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp324, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_15, tmp324, atslab_3, arg4) ; tmp323 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp323, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp323, atslab_instr_node, tmp324) ; return (tmp323) ; } /* end of [instr_move_con_115] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 24494(line=983, offs=3) -- 24620(line=984, offs=82) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con: tmp327 = instr_move_con_115 (arg1, arg2, arg3, arg4, arg5) ; tmp326 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp326, atslab_0, tmp327) ; ats_selptrset_mac(anairiats_sum_17, tmp326, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp326 ; return /* (tmp325) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_con] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 24678(line=989, offs=5) -- 24885(line=998, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_lazy_delay_117 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; __ats_lab_instr_move_lazy_delay_117: tmp329 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp329)->tag = 25 ; ats_selptrset_mac(anairiats_sum_18, tmp329, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp329, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_18, tmp329, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_18, tmp329, atslab_3, arg4) ; tmp328 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp328, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp328, atslab_instr_node, tmp329) ; return (tmp328) ; } /* end of [instr_move_lazy_delay_117] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 24963(line=1002, offs=3) -- 25123(line=1006, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay: tmp331 = instr_move_lazy_delay_117 (arg1, arg2, arg3, arg4, arg5) ; tmp332 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp332, atslab_0, tmp331) ; ats_selptrset_mac(anairiats_sum_17, tmp332, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp332 ; return /* (tmp330) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 25188(line=1010, offs=5) -- 25395(line=1019, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_lazy_force_119 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; __ats_lab_instr_move_lazy_force_119: tmp334 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp334)->tag = 26 ; ats_selptrset_mac(anairiats_sum_18, tmp334, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_18, tmp334, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_18, tmp334, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_18, tmp334, atslab_3, arg4) ; tmp333 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp333, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp333, atslab_instr_node, tmp334) ; return (tmp333) ; } /* end of [instr_move_lazy_force_119] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 25469(line=1023, offs=3) -- 25629(line=1027, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_force (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_force: tmp336 = instr_move_lazy_force_119 (arg1, arg2, arg3, arg4, arg5) ; tmp337 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp337, atslab_0, tmp336) ; ats_selptrset_mac(anairiats_sum_17, tmp337, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp337 ; return /* (tmp335) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_lazy_force] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 25694(line=1031, offs=5) -- 25879(line=1039, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_rec_flt_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; __ats_lab_instr_move_rec_flt_121: tmp339 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp339)->tag = 28 ; ats_selptrset_mac(anairiats_sum_6, tmp339, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp339, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp339, atslab_2, arg3) ; tmp338 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp338, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp338, atslab_instr_node, tmp339) ; return (tmp338) ; } /* end of [instr_move_rec_flt_121] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 25916(line=1041, offs=5) -- 26101(line=1049, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_rec_box_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; __ats_lab_instr_move_rec_box_122: tmp341 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp341)->tag = 27 ; ats_selptrset_mac(anairiats_sum_6, tmp341, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp341, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp341, atslab_2, arg3) ; tmp340 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp340, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp340, atslab_instr_node, tmp341) ; return (tmp340) ; } /* end of [instr_move_rec_box_122] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 26165(line=1053, offs=3) -- 26638(line=1065, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_rec (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_bool_type, tmp344) ; ATSlocal (ats_bool_type, tmp345) ; // ATSlocal_void (tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; // ATSlocal_void (tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_rec: do { /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp344 = atspre_eq_int_int (arg3, 0) ; if (!tmp344) { goto __ats_lab_40_1 ; } tmp343 = instr_move_rec_flt_121 (arg1, arg2, arg4, arg5) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp345 = atspre_gt_int_int (arg3, 0) ; if (!tmp345) { goto __ats_lab_41_1 ; } tmp343 = instr_move_rec_box_122 (arg1, arg2, arg4, arg5) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: /* tmp346 = */ prerr_interror_0 () ; /* tmp347 = */ atspre_prerr_string (ATSstrcst(": instr_add_move_rec: recknd = ")) ; /* tmp348 = */ atspre_prerr_int (arg3) ; /* tmp349 = */ atspre_prerr_newline () ; /* tmp343 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp350 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp350, atslab_0, tmp343) ; ats_selptrset_mac(anairiats_sum_17, tmp350, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp350 ; return /* (tmp342) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 26696(line=1069, offs=5) -- 26832(line=1073, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_ref_124 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; __ats_lab_instr_move_ref_124: tmp352 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp352)->tag = 29 ; ats_selptrset_mac(anairiats_sum_8, tmp352, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp352, atslab_1, arg2) ; tmp351 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp351, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp351, atslab_instr_node, tmp352) ; return (tmp351) ; } /* end of [instr_move_ref_124] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 26890(line=1076, offs=20) -- 26978(line=1077, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_ref (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_ref: tmp355 = instr_move_ref_124 (arg1, arg2, arg3) ; tmp354 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp354, atslab_0, tmp355) ; ats_selptrset_mac(anairiats_sum_17, tmp354, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp354 ; return /* (tmp353) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27015(line=1080, offs=5) -- 27151(line=1084, offs=2) */ ATSstaticdec() ats_ptr_type instr_move_val_126 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; __ats_lab_instr_move_val_126: tmp357 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp357)->tag = 30 ; ats_selptrset_mac(anairiats_sum_8, tmp357, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp357, atslab_1, arg2) ; tmp356 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp356, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp356, atslab_instr_node, tmp357) ; return (tmp356) ; } /* end of [instr_move_val_126] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27209(line=1087, offs=20) -- 27297(line=1088, offs=63) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val: tmp360 = instr_move_val_126 (arg1, arg2, arg3) ; tmp359 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp359, atslab_0, tmp360) ; ats_selptrset_mac(anairiats_sum_17, tmp359, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp359 ; return /* (tmp358) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_move_val] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27355(line=1093, offs=5) -- 27493(line=1097, offs=2) */ ATSstaticdec() ats_ptr_type instr_raise_128 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; __ats_lab_instr_raise_128: tmp362 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp362)->tag = 32 ; ats_selptrset_mac(anairiats_sum_8, tmp362, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp362, atslab_1, arg2) ; tmp361 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp361, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp361, atslab_instr_node, tmp362) ; return (tmp361) ; } /* end of [instr_raise_128] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27545(line=1100, offs=17) -- 27638(line=1101, offs=64) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_raise (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_raise: tmp365 = instr_raise_128 (arg1, arg2, arg3) ; tmp364 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp364, atslab_0, tmp365) ; ats_selptrset_mac(anairiats_sum_17, tmp364, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp364 ; return /* (tmp363) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27693(line=1106, offs=5) -- 27862(line=1114, offs=2) */ ATSstaticdec() ats_ptr_type instr_select_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; __ats_lab_instr_select_130: tmp367 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp367)->tag = 33 ; ats_selptrset_mac(anairiats_sum_6, tmp367, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp367, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp367, atslab_2, arg3) ; tmp366 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp366, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp366, atslab_instr_node, tmp367) ; return (tmp366) ; } /* end of [instr_select_130] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 27919(line=1118, offs=3) -- 28027(line=1119, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select: tmp370 = instr_select_130 (arg1, arg2, arg3, arg4) ; tmp369 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp369, atslab_0, tmp370) ; ats_selptrset_mac(anairiats_sum_17, tmp369, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp369 ; return /* (tmp368) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_select] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 28062(line=1122, offs=5) -- 28249(line=1131, offs=2) */ ATSstaticdec() ats_ptr_type instr_selcon_132 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; __ats_lab_instr_selcon_132: tmp372 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp372)->tag = 34 ; ats_selptrset_mac(anairiats_sum_21, tmp372, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp372, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp372, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp372, atslab_3, arg4) ; tmp371 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp371, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp371, atslab_instr_node, tmp372) ; return (tmp371) ; } /* end of [instr_selcon_132] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 28305(line=1135, offs=3) -- 28427(line=1136, offs=79) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon: tmp375 = instr_selcon_132 (arg1, arg2, arg3, arg4, arg5) ; tmp374 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp374, atslab_0, tmp375) ; ats_selptrset_mac(anairiats_sum_17, tmp374, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp374 ; return /* (tmp373) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 28462(line=1139, offs=5) -- 28657(line=1148, offs=2) */ ATSstaticdec() ats_ptr_type instr_selcon_ptr_134 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; __ats_lab_instr_selcon_ptr_134: tmp377 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ((ats_sum_ptr_type)tmp377)->tag = 35 ; ats_selptrset_mac(anairiats_sum_21, tmp377, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_21, tmp377, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_21, tmp377, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_21, tmp377, atslab_3, arg4) ; tmp376 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp376, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp376, atslab_instr_node, tmp377) ; return (tmp376) ; } /* end of [instr_selcon_ptr_134] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 28721(line=1152, offs=3) -- 28874(line=1156, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon_ptr (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_int_type arg5) { /* local vardec */ // ATSlocal_void (tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon_ptr: tmp379 = instr_selcon_ptr_134 (arg1, arg2, arg3, arg4, arg5) ; tmp380 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp380, atslab_0, tmp379) ; ats_selptrset_mac(anairiats_sum_17, tmp380, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp380 ; return /* (tmp378) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_selcon_ptr] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 28934(line=1160, offs=5) -- 29077(line=1164, offs=2) */ ATSstaticdec() ats_ptr_type instr_store_ptr_136 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; __ats_lab_instr_store_ptr_136: tmp382 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp382)->tag = 37 ; ats_selptrset_mac(anairiats_sum_8, tmp382, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp382, atslab_1, arg2) ; tmp381 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp381, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp381, atslab_instr_node, tmp382) ; return (tmp381) ; } /* end of [instr_store_ptr_136] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 29111(line=1166, offs=5) -- 29288(line=1171, offs=2) */ ATSstaticdec() ats_ptr_type instr_store_ptr_offs_137 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; __ats_lab_instr_store_ptr_offs_137: tmp384 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp384)->tag = 38 ; ats_selptrset_mac(anairiats_sum_6, tmp384, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp384, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp384, atslab_2, arg3) ; tmp383 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp383, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp383, atslab_instr_node, tmp384) ; return (tmp383) ; } /* end of [instr_store_ptr_offs_137] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 29360(line=1175, offs=3) -- 29601(line=1182, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp386 = instr_store_ptr_offs_137 (arg1, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_43_1: tmp386 = instr_store_ptr_136 (arg1, arg2, arg4) ; break ; } while (0) ; tmp387 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp387, atslab_0, tmp386) ; ats_selptrset_mac(anairiats_sum_17, tmp387, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp387 ; return /* (tmp385) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_ptr_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 29665(line=1186, offs=5) -- 29808(line=1190, offs=2) */ ATSstaticdec() ats_ptr_type instr_store_var_139 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; __ats_lab_instr_store_var_139: tmp389 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp389)->tag = 39 ; ats_selptrset_mac(anairiats_sum_8, tmp389, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp389, atslab_1, arg2) ; tmp388 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp388, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp388, atslab_instr_node, tmp389) ; return (tmp388) ; } /* end of [instr_store_var_139] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 29842(line=1192, offs=5) -- 30019(line=1197, offs=2) */ ATSstaticdec() ats_ptr_type instr_store_var_offs_140 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; __ats_lab_instr_store_var_offs_140: tmp391 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp391)->tag = 40 ; ats_selptrset_mac(anairiats_sum_6, tmp391, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp391, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp391, atslab_2, arg3) ; tmp390 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp390, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp390, atslab_instr_node, tmp391) ; return (tmp390) ; } /* end of [instr_store_var_offs_140] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 30091(line=1201, offs=3) -- 30361(line=1209, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_var_offs (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_var_offs: do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp393 = instr_store_var_offs_140 (arg1, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp393 = instr_store_var_139 (arg1, arg2, arg4) ; break ; } while (0) ; tmp394 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp394, atslab_0, tmp393) ; ats_selptrset_mac(anairiats_sum_17, tmp394, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp394 ; return /* (tmp392) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_store_var_offs] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 30425(line=1213, offs=5) -- 30531(line=1216, offs=2) */ ATSstaticdec() ats_ptr_type instr_switch_142 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; __ats_lab_instr_switch_142: tmp396 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp396)->tag = 36 ; ats_selptrset_mac(anairiats_sum_4, tmp396, atslab_0, arg1) ; tmp395 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp395, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp395, atslab_instr_node, tmp396) ; return (tmp395) ; } /* end of [instr_switch_142] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 30585(line=1219, offs=18) -- 30655(line=1220, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_switch (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_switch: tmp399 = instr_switch_142 (arg1, arg2) ; tmp398 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp398, atslab_0, tmp399) ; ats_selptrset_mac(anairiats_sum_17, tmp398, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp398 ; return /* (tmp397) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_switch] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 30690(line=1223, offs=5) -- 30813(line=1226, offs=2) */ ATSstaticdec() ats_ptr_type instr_tmplabint_144 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; __ats_lab_instr_tmplabint_144: tmp401 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp401)->tag = 41 ; ats_selptrset_mac(anairiats_sum_13, tmp401, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp401, atslab_1, arg2) ; tmp400 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp400, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp400, atslab_instr_node, tmp401) ; return (tmp400) ; } /* end of [instr_tmplabint_144] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 30873(line=1229, offs=21) -- 30954(line=1230, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3) { /* local vardec */ // ATSlocal_void (tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint: tmp404 = instr_tmplabint_144 (arg1, arg2, arg3) ; tmp403 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp403, atslab_0, tmp404) ; ats_selptrset_mac(anairiats_sum_17, tmp403, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp403 ; return /* (tmp402) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_tmplabint] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 31013(line=1235, offs=5) -- 31183(line=1243, offs=2) */ ATSstaticdec() ats_ptr_type instr_trywith_146 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; __ats_lab_instr_trywith_146: tmp406 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp406)->tag = 45 ; ats_selptrset_mac(anairiats_sum_6, tmp406, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_6, tmp406, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_6, tmp406, atslab_2, arg3) ; tmp405 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp405, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp405, atslab_instr_node, tmp406) ; return (tmp405) ; } /* end of [instr_trywith_146] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 31241(line=1247, offs=3) -- 31348(line=1248, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_trywith (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_trywith: tmp409 = instr_trywith_146 (arg1, arg2, arg3, arg4) ; tmp408 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp408, atslab_0, tmp409) ; ats_selptrset_mac(anairiats_sum_17, tmp408, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp408 ; return /* (tmp407) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_trywith] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 31384(line=1251, offs=5) -- 31488(line=1254, offs=2) */ ATSstaticdec() ats_ptr_type instr_vardec_148 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; __ats_lab_instr_vardec_148: tmp411 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp411)->tag = 46 ; ats_selptrset_mac(anairiats_sum_4, tmp411, atslab_0, arg1) ; tmp410 = ATS_MALLOC(sizeof(anairiats_rec_14)) ; ats_selptrset_mac(anairiats_rec_14, tmp410, atslab_instr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_14, tmp410, atslab_instr_node, tmp411) ; return (tmp410) ; } /* end of [instr_vardec_148] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp.dats: 31542(line=1257, offs=18) -- 31612(line=1258, offs=53) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec: tmp414 = instr_vardec_148 (arg1, arg2) ; tmp413 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ats_selptrset_mac(anairiats_sum_17, tmp413, atslab_0, tmp414) ; ats_selptrset_mac(anairiats_sum_17, tmp413, atslab_1, ats_ptrget_mac(ats_ptr_type, arg0)) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp413 ; return /* (tmp412) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_add_vardec] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_funlab_set_qua (ats_ptr_type fl, ats_ptr_type od2c) { ((funlab_t)fl)->atslab_funlab_qua = od2c ; return ; } // end of [atsopt_funlab_set_qua] ats_void_type atsopt_funlab_set_entry (ats_ptr_type fl, ats_ptr_type entry) { ((funlab_t)fl)->atslab_funlab_entry = entry ; return ; } // end of [atsopt_funlab_set_entry] ats_void_type atsopt_funlab_set_tailjoined (ats_ptr_type fl, ats_ptr_type tmps) { ((funlab_t)fl)->atslab_funlab_tailjoined = tmps ; return ; } // end of [atsopt_funlab_set_tailjoined] ats_void_type atsopt_tmpvar_set_ret (ats_ptr_type tmp, ats_int_type ret) { ((tmpvar_t)tmp)->atslab_tmpvar_ret = ret ; return ; } // end of [atsopt_tmpvar_set_ret] ats_void_type atsopt_tmpvar_set_top (ats_ptr_type tmp, ats_int_type top) { ((tmpvar_t)tmp)->atslab_tmpvar_top = top ; return ; } // end of [atsopt_tmpvar_set_top] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_state_dats.c0000664000175000017500000017324112223166160023411 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_stbefitem_var ; ats_int_type atslab_stbefitem_lin ; ats_ptr_type atslab_stbefitem_typ ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_sascstr_loc ; ats_ptr_type atslab_sascstr_met ; ats_ptr_type atslab_sascstr_sub ; ats_ptr_type atslab_sascstr_ref ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_staftitem_var ; ats_int_type atslab_staftitem_lin ; ats_ptr_type atslab_staftitem_typ ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_staftscstr_met ; ats_ptr_type atslab_staftscstr_res ; ats_ptr_type atslab_staftscstr_sais ; ats_ptr_type atslab_staftscstr_cstr ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_i2nvarg_var ; ats_ptr_type atslab_i2nvarg_typ ; } anairiats_rec_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; /* external typedefs */ typedef anairiats_rec_6 *staftscstr_t ; typedef anairiats_rec_5 *staftitem_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINdone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPnone_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ineq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr_ref) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_state_staftitem_set_lin) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_state_staftitem_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_state_staftscstr_cstr_set) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__staftscstr_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__staftitem_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__stbefitem_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPnone_1) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_void_type loop_3 (ats_ptr_type arg0) ; static ats_void_type loop_5 (ats_ptr_type arg0) ; static ats_ptr_type saityp_get_loc_6 (ats_ptr_type arg0) ; static ats_void_type print_saityp_7 (ats_ptr_type arg0) ; static ats_void_type loop_9 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_void_type print_saityplst_8 (ats_ptr_type arg0) ; static ats_ptr_type sascstr_make_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_12 (ats_ptr_type arg0) ; static ats_void_type aux_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type auxlst_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type ref_make_elt_03717_ats_ptr_type (ats_ptr_type arg0) ; static ats_void_type staftscstr_stbefitemlst_merge_ifmetck_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_bool_type arg3) ; static ats_ptr_type i2nvarglst_find_d2var_19 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type d2var_is_done_20 (ats_ptr_type arg0) ; static ats_ptr_type aux_find_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_item_errmsg1_22 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_item_errmsg2_23 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_saityp_24 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_item_one_25 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_item_all_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type aux_term_check_27 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_itemlst_all_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type aux_find_30 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_iter_31 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2131(line=67, offs=4) -- 2198(line=68, offs=53) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env_state)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2273(line=74, offs=16) -- 2394(line=77, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitem_make (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitem_make: tmp2 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg0) ; tmp1 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_stbefitem_var, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_stbefitem_lin, arg1) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_stbefitem_typ, tmp2) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitem_make] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2477(line=81, offs=7) -- 2736(line=88, offs=24) */ ATSstaticdec() ats_void_type loop_3 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_loop_3: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp6 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp7 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp5), atslab_stbefitem_var) ; tmp9 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp5), atslab_stbefitem_typ) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp7, tmp9) ; arg0 = tmp6 ; goto __ats_lab_loop_3 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp4) */ ; } /* end of [loop_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2458(line=80, offs=26) -- 2776(line=92, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_typ (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_typ: /* tmp3 = */ loop_3 (arg0) ; return /* (tmp3) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2873(line=96, offs=7) -- 3197(line=106, offs=24) */ ATSstaticdec() ats_void_type loop_5 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; // ATSlocal_void (tmp15) ; ATSlocal (ats_int_type, tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_loop_5: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp12), atslab_stbefitem_var) ; tmp16 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp12), atslab_stbefitem_lin) ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (tmp14, tmp16) ; tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp12), atslab_stbefitem_typ) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp14, tmp18) ; arg0 = tmp13 ; goto __ats_lab_loop_5 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp11) */ ; } /* end of [loop_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 2854(line=95, offs=30) -- 3237(line=110, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp10) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ: /* tmp10 = */ loop_5 (arg0) ; return /* (tmp10) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_lin_typ] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 3410(line=118, offs=4) -- 3511(line=119, offs=55) */ ATSstaticdec() ats_ptr_type saityp_get_loc_6 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_saityp_get_loc_6: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp19 = tmp20 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp19 = tmp21 ; break ; } while (0) ; return (tmp19) ; } /* end of [saityp_get_loc_6] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 3544(line=122, offs=5) -- 3713(line=126, offs=41) */ ATSstaticdec() ats_void_type print_saityp_7 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; __ats_lab_print_saityp_7: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; /* tmp24 = */ atspre_print_string (ATSstrcst("SAITYPsome(")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__print_s2exp (tmp23) ; /* tmp22 = */ atspre_print_string (ATSstrcst(")")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp22 = */ atspre_print_string (ATSstrcst("SAITYPnone()")) ; break ; } while (0) ; return /* (tmp22) */ ; } /* end of [print_saityp_7] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 3812(line=130, offs=7) -- 4014(line=135, offs=24) */ ATSstaticdec() ats_void_type loop_9 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; // ATSlocal_void (tmp30) ; ATSlocal (ats_bool_type, tmp31) ; // ATSlocal_void (tmp32) ; ATSlocal (ats_int_type, tmp33) ; __ats_lab_loop_9: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp28 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp29 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp31 = atspre_gt_int_int (arg1, 0) ; if (tmp31) { /* tmp30 = */ atspre_print_string (ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp32 = */ print_saityp_7 (tmp28) ; tmp33 = atspre_add_int_int (arg1, 1) ; arg0 = tmp29 ; arg1 = tmp33 ; goto __ats_lab_loop_9 ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; return /* (tmp27) */ ; } /* end of [loop_9] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 3743(line=128, offs=5) -- 4035(line=137, offs=2) */ ATSstaticdec() ats_void_type print_saityplst_8 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp26) ; __ats_lab_print_saityplst_8: /* tmp26 = */ loop_9 (arg0, 0) ; return /* (tmp26) */ ; } /* end of [print_saityplst_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 6406(line=218, offs=4) -- 6577(line=222, offs=2) */ ATSstaticdec() ats_ptr_type sascstr_make_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_sascstr_make_10: tmp34 = ATS_MALLOC(sizeof(anairiats_rec_4)) ; ats_selptrset_mac(anairiats_rec_4, tmp34, atslab_sascstr_loc, arg0) ; ats_selptrset_mac(anairiats_rec_4, tmp34, atslab_sascstr_met, arg1) ; ats_selptrset_mac(anairiats_rec_4, tmp34, atslab_sascstr_sub, arg2) ; ats_selptrset_mac(anairiats_rec_4, tmp34, atslab_sascstr_ref, arg3) ; return (tmp34) ; } /* end of [sascstr_make_10] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 7100(line=245, offs=9) -- 7753(line=261, offs=35) */ ATSstaticdec() ats_ptr_type aux_12 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_aux_12: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp38 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp37), atslab_stbefitem_var) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (tmp39) ; tmp42 = (ats_sum_ptr_type)0 ; tmp41 = ATS_MALLOC(sizeof(anairiats_rec_5)) ; ats_selptrset_mac(anairiats_rec_5, tmp41, atslab_staftitem_var, tmp39) ; ats_selptrset_mac(anairiats_rec_5, tmp41, atslab_staftitem_lin, tmp40) ; ats_selptrset_mac(anairiats_rec_5, tmp41, atslab_staftitem_typ, tmp42) ; tmp43 = aux_12 (tmp38) ; tmp36 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp36, atslab_0, tmp41) ; ats_selptrset_mac(anairiats_sum_1, tmp36, atslab_1, tmp43) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp36 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp36) ; } /* end of [aux_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 7044(line=243, offs=23) -- 7910(line=269, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize: tmp44 = aux_12 (arg1) ; tmp45 = (ats_sum_ptr_type)0 ; tmp46 = (ats_sum_ptr_type)0 ; tmp35 = ATS_MALLOC(sizeof(anairiats_rec_6)) ; ats_selptrset_mac(anairiats_rec_6, tmp35, atslab_staftscstr_met, tmp45) ; ats_selptrset_mac(anairiats_rec_6, tmp35, atslab_staftscstr_res, arg0) ; ats_selptrset_mac(anairiats_rec_6, tmp35, atslab_staftscstr_sais, tmp44) ; ats_selptrset_mac(anairiats_rec_6, tmp35, atslab_staftscstr_cstr, tmp46) ; return (tmp35) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 8140(line=279, offs=6) -- 10402(line=336, offs=6) */ ATSstaticdec() ats_void_type aux_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp48) ; ATSlocal (ats_int_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_int_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; ATSlocal (ats_bool_type, tmp57) ; ATSlocal (ats_int_type, tmp58) ; ATSlocal (ats_int_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; // ATSlocal_void (tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; // ATSlocal_void (tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; // ATSlocal_void (tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_aux_14: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg2), atslab_stbefitem_lin) ; tmp50 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg2), atslab_stbefitem_var) ; tmp51 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (tmp50) ; tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_staftitem_lin) ; tmp54 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (tmp50) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp54 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_0) ; tmp53 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp53)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp53, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_2, tmp53, atslab_1, tmp55) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (tmp54 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp53 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp53)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp53, atslab_0, arg0) ; break ; } while (0) ; tmp57 = atspre_gt_int_int (tmp51, tmp49) ; if (tmp57) { tmp59 = atspre_add_int_int (tmp52, tmp51) ; tmp58 = atspre_sub_int_int (tmp59, tmp49) ; /* tmp56 = */ atsopt_state_staftitem_set_lin (arg1, tmp58) ; } else { /* empty */ } /* end of [if] */ tmp60 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_staftitem_typ) ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp60 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_14_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_1, tmp60, atslab_0) ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp53)->tag != 0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: if (((ats_sum_ptr_type)tmp62)->tag != 1) { goto __ats_lab_17_1 ; } __ats_lab_15_2: tmp63 = ats_caselptrlab_mac(anairiats_sum_2, tmp53, atslab_0) ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp63) ; /* tmp65 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp66 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp67 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp50) ; /* tmp68 = */ atspre_prerr_string (ATSstrcst("] is expected to be consumed but it is preserved instead.")) ; /* tmp69 = */ atspre_prerr_newline () ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp53)->tag != 1) { goto __ats_lab_17_0 ; } __ats_lab_16_1: if (((ats_sum_ptr_type)tmp62)->tag != 0) { goto __ats_lab_17_1 ; } __ats_lab_16_2: tmp70 = ats_caselptrlab_mac(anairiats_sum_3, tmp53, atslab_0) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp70) ; /* tmp72 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp73 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp74 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (tmp50) ; /* tmp75 = */ atspre_prerr_string (ATSstrcst("] is expected to be preserved but it is consumed instead.")) ; /* tmp76 = */ atspre_prerr_newline () ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: __ats_lab_17_2: break ; } while (0) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (tmp60 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; tmp77 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp77, atslab_0, tmp53) ; ats_selptrset_mac(anairiats_sum_1, tmp77, atslab_1, tmp60) ; /* tmp48 = */ atsopt_state_staftitem_set_typ (arg1, tmp77) ; return /* (tmp48) */ ; } /* end of [aux_14] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 10425(line=337, offs=7) -- 10725(line=345, offs=24) */ ATSstaticdec() ats_void_type auxlst_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_auxlst_15: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; // if (arg2 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp81 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; /* tmp83 = */ aux_14 (arg0, tmp79, tmp81) ; arg0 = arg0 ; arg1 = tmp80 ; arg2 = tmp82 ; goto __ats_lab_auxlst_15 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: break ; } while (0) ; return /* (tmp78) */ ; } /* end of [auxlst_15] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_03717_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; __ats_lab_ref_make_elt_03717_ats_ptr_type: /* ats_ptr_type tmp94 ; */ tmp94 = arg0 ; tmp93 = atspre_ref_make_elt_tsz ((&tmp94), sizeof(ats_ptr_type)) ; return (tmp93) ; } /* end of [ref_make_elt_03717_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 8000(line=275, offs=1) -- 11326(line=363, offs=4) */ ATSstaticdec() ats_void_type staftscstr_stbefitemlst_merge_ifmetck_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_bool_type arg3) { /* local vardec */ // ATSlocal_void (tmp47) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_staftscstr_stbefitemlst_merge_ifmetck_13: tmp84 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_res) ; tmp86 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp84), atslab_i2nvresstate_svs) ; tmp87 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp84), atslab_i2nvresstate_gua) ; tmp85 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp86, tmp87) ; if (arg3) { tmp89 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp84), atslab_i2nvresstate_met) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (tmp89 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp90 = ats_caselptrlab_mac(anairiats_sum_7, tmp89, atslab_0) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp85, tmp90) ; tmp88 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp88, atslab_0, tmp91) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (tmp89 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: tmp88 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } else { tmp88 = (ats_sum_ptr_type)0 ; } /* end of [if] */ tmp95 = (ats_sum_ptr_type)0 ; tmp92 = ref_make_elt_03717_ats_ptr_type (tmp95) ; tmp96 = sascstr_make_10 (arg0, tmp88, tmp85, tmp92) ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr_ref (tmp92) ; tmp100 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_cstr) ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp99, atslab_0, tmp96) ; ats_selptrset_mac(anairiats_sum_1, tmp99, atslab_1, tmp100) ; /* tmp98 = */ atsopt_state_staftscstr_cstr_set (arg1, tmp99) ; tmp101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_sais) ; /* tmp47 = */ auxlst_15 (arg0, tmp101, arg2) ; return /* (tmp47) */ ; } /* end of [staftscstr_stbefitemlst_merge_ifmetck_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 11420(line=366, offs=3) -- 11501(line=366, offs=84) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp102) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge: /* tmp102 = */ staftscstr_stbefitemlst_merge_ifmetck_13 (arg0, arg1, arg2, ats_true_bool) ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 11597(line=370, offs=3) -- 11679(line=370, offs=85) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge_skipmetck (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge_skipmetck: /* tmp103 = */ staftscstr_stbefitemlst_merge_ifmetck_13 (arg0, arg1, arg2, ats_false_bool) ; return /* (tmp103) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge_skipmetck] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 11758(line=375, offs=5) -- 12182(line=389, offs=4) */ ATSstaticdec() ats_ptr_type i2nvarglst_find_d2var_19 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_bool_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; __ats_lab_i2nvarglst_find_d2var_19: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp105 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp106 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp108 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp105), atslab_i2nvarg_var) ; tmp107 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__eq_d2var_d2var (tmp108, arg1) ; if (tmp107) { tmp104 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp104, atslab_0, tmp105) ; } else { arg0 = tmp106 ; arg1 = arg1 ; goto __ats_lab_i2nvarglst_find_d2var_19 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp104 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp104) ; } /* end of [i2nvarglst_find_d2var_19] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 12245(line=395, offs=4) -- 12357(line=397, offs=4) */ ATSstaticdec() ats_bool_type d2var_is_done_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_d2var_is_done_20: tmp110 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin (arg0) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp110)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp109 = ats_true_bool ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp109 = ats_false_bool ; break ; } while (0) ; return (tmp109) ; } /* end of [d2var_is_done_20] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 12388(line=399, offs=4) -- 12800(line=415, offs=4) */ ATSstaticdec() ats_ptr_type aux_find_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_aux_find_21: tmp112 = i2nvarglst_find_d2var_19 (arg1, arg2) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp112 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_27_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_7, tmp112, atslab_0) ; ATS_FREE(tmp112) ; tmp115 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp113), atslab_i2nvarg_typ) ; do { /* branch: __ats_lab_28 */ __ats_lab_28_0: if (tmp115 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_7, tmp115, atslab_0) ; tmp117 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (arg0, tmp116) ; tmp114 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp114, atslab_0, tmp117) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp115 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp114 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp111 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp111, atslab_0, tmp114) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (tmp112 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: tmp111 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp111) ; } /* end of [aux_find_21] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 12826(line=417, offs=4) -- 13083(line=424, offs=4) */ ATSstaticdec() ats_ptr_type aux_item_errmsg1_22 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; __ats_lab_aux_item_errmsg1_22: /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp120 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp121 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp123 = */ atspre_prerr_string (ATSstrcst("] is expected to be consumed but it is not.")) ; /* tmp124 = */ atspre_prerr_newline () ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp118) ; } /* end of [aux_item_errmsg1_22] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 13117(line=426, offs=4) -- 13373(line=433, offs=4) */ ATSstaticdec() ats_void_type aux_item_errmsg2_23 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; // ATSlocal_void (tmp131) ; __ats_lab_aux_item_errmsg2_23: /* tmp126 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp127 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp128 = */ atspre_prerr_string (ATSstrcst(": the dynamic variable [")) ; /* tmp129 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp130 = */ atspre_prerr_string (ATSstrcst("] is expected to be preserved but it is not.")) ; /* tmp131 = */ atspre_prerr_newline () ; /* tmp125 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp125) */ ; } /* end of [aux_item_errmsg2_23] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 13407(line=435, offs=4) -- 15308(line=486, offs=4) */ ATSstaticdec() ats_void_type aux_saityp_24 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_int_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_int_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_bool_type, tmp143) ; // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_aux_saityp_24: do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)arg4)->tag != 0) { goto __ats_lab_38_0 ; } __ats_lab_31_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_2, arg4, atslab_0) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_2, arg4, atslab_1) ; /* ats_int_type tmp135 ; */ tmp135 = arg0 ; tmp137 = aux_find_21 (arg1, arg2, arg3) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp137 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_32_1: tmp138 = ats_caselptrlab_mac(anairiats_sum_7, tmp137, atslab_0) ; ATS_FREE(tmp137) ; tmp139 = atspre_add_int_int (tmp135, 1) ; tmp135 = tmp139 ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (tmp138 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp140 = ats_caselptrlab_mac(anairiats_sum_7, tmp138, atslab_0) ; tmp136 = tmp140 ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (tmp138 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp136 = aux_item_errmsg1_22 (tmp133, arg3) ; break ; } while (0) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (tmp137 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp141 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (arg3) ; do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (tmp141 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_7, tmp141, atslab_0) ; tmp136 = tmp142 ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp141 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp136 = aux_item_errmsg1_22 (tmp133, arg3) ; break ; } while (0) ; break ; } while (0) ; tmp143 = atspre_gt_int_int (tmp135, 0) ; if (tmp143) { /* tmp144 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp145 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (tmp133, tmp134, tmp136) ; tmp146 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp146)->tag = 4 ; ats_selptrset_mac(anairiats_sum_10, tmp146, atslab_0, arg3) ; ats_selptrset_mac(anairiats_sum_10, tmp146, atslab_1, tmp134) ; ats_selptrset_mac(anairiats_sum_10, tmp146, atslab_2, tmp136) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (tmp133, tmp146) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (((ats_sum_ptr_type)arg4)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp147 = ats_caselptrlab_mac(anairiats_sum_3, arg4, atslab_0) ; tmp148 = aux_find_21 (arg1, arg2, arg3) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (tmp148 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_39_1: tmp149 = ats_caselptrlab_mac(anairiats_sum_7, tmp148, atslab_0) ; ATS_FREE(tmp148) ; do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (tmp149 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: /* tmp132 = */ aux_item_errmsg2_23 (tmp147, arg3) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (tmp149 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: break ; } while (0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (tmp148 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: break ; } while (0) ; break ; } while (0) ; return /* (tmp132) */ ; } /* end of [aux_saityp_24] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 15336(line=488, offs=4) -- 15850(line=507, offs=4) */ ATSstaticdec() ats_void_type aux_item_one_25 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; __ats_lab_aux_item_one_25: tmp151 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg3), atslab_staftitem_typ) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (tmp151 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp152 = ats_caselptrlab_mac(anairiats_sum_1, tmp151, atslab_0) ; tmp153 = ats_caselptrlab_mac(anairiats_sum_1, tmp151, atslab_1) ; tmp154 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg2), atslab_i2nvresstate_arg) ; /* tmp155 = */ atsopt_state_staftitem_set_typ (arg3, tmp153) ; tmp156 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg2), atslab_i2nvresstate_arg) ; /* tmp150 = */ aux_saityp_24 (arg0, arg1, tmp156, arg4, tmp152) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (tmp151 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: break ; } while (0) ; return /* (tmp150) */ ; } /* end of [aux_item_one_25] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 15881(line=510, offs=1) -- 16705(line=537, offs=4) */ ATSstaticdec() ats_void_type aux_item_all_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_int_type, tmp163) ; ATSlocal (ats_int_type, tmp164) ; // ATSlocal_void (tmp165) ; ATSlocal (ats_bool_type, tmp166) ; ATSlocal (ats_int_type, tmp167) ; __ats_lab_aux_item_all_26: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_45_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp159 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; // if (arg3 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp160 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp162 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp160), atslab_stbefitem_var) ; tmp163 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp158), atslab_staftitem_lin) ; tmp164 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp160), atslab_stbefitem_lin) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp166 = d2var_is_done_20 (tmp162) ; if (!tmp166) { goto __ats_lab_47_1 ; } break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp167 = atspre_sub_int_int (tmp163, tmp164) ; /* tmp165 = */ aux_item_one_25 (tmp167, arg0, arg1, tmp158, tmp162) ; break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp159 ; arg3 = tmp161 ; goto __ats_lab_aux_item_all_26 ; // tail call break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: break ; } while (0) ; return /* (tmp157) */ ; } /* end of [aux_item_all_26] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 16735(line=539, offs=4) -- 17520(line=562, offs=4) */ ATSstaticdec() ats_void_type aux_term_check_27 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_int_type, tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_bool_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; // ATSlocal_void (tmp177) ; // ATSlocal_void (tmp178) ; ATSlocal (ats_bool_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; __ats_lab_aux_term_check_27: do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp170 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_sascstr_met) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp170 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_7, tmp170, atslab_0) ; tmp172 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (tmp171, tmp169) ; tmp174 = atspre_ineq (tmp172, 0) ; if (tmp174) { /* tmp175 = */ prerr_interror_0 () ; /* tmp176 = */ atspre_prerr_string (ATSstrcst(": aux_term_check: Some: Some")) ; /* tmp177 = */ atspre_prerr_newline () ; /* tmp178 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; tmp179 = atspre_ieq (tmp172, 0) ; /* tmp173 = */ atspre_assert (tmp179) ; } else { /* empty */ } /* end of [if] */ tmp180 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_sascstr_loc) ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec (tmp180, tmp171, tmp169) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (tmp170 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: break ; } while (0) ; break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: break ; } while (0) ; return /* (tmp168) */ ; } /* end of [aux_term_check_27] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 17553(line=565, offs=1) -- 18207(line=585, offs=4) */ ATSstaticdec() ats_void_type aux_itemlst_all_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ // ATSlocal_void (tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_aux_itemlst_all_28: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_1) ; /* tmp184 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp185 = */ aux_term_check_27 (arg0, tmp182) ; tmp187 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp182), atslab_sascstr_sub) ; /* tmp186 = */ aux_item_all_26 (tmp187, arg1, arg2, arg3) ; tmp188 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta () ; tmp189 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp188) ; tmp191 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp182), atslab_sascstr_loc) ; tmp192 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; tmp190 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst (tmp191, tmp192, tmp189) ; tmp193 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp182), atslab_sascstr_ref) ; tmp194 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp194, atslab_0, tmp190) ; ats_ptrget_mac(ats_ptr_type, tmp193) = tmp194 ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = tmp183 ; goto __ats_lab_aux_itemlst_all_28 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: break ; } while (0) ; return /* (tmp181) */ ; } /* end of [aux_itemlst_all_28] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 18300(line=591, offs=3) -- 18688(line=605, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp199) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check: tmp196 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_met) ; tmp197 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_res) ; tmp198 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_sais) ; tmp199 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_cstr) ; /* tmp195 = */ aux_itemlst_all_28 (tmp196, tmp197, tmp198, arg2, tmp199) ; return /* (tmp195) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 18787(line=613, offs=5) -- 19007(line=621, offs=4) */ ATSstaticdec() ats_ptr_type aux_find_30 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; __ats_lab_aux_find_30: tmp201 = i2nvarglst_find_d2var_19 (arg0, arg1) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (tmp201 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_7, tmp201, atslab_0) ; ATS_FREE(tmp201) ; tmp203 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp202), atslab_i2nvarg_typ) ; tmp200 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ats_selptrset_mac(anairiats_sum_7, tmp200, atslab_0, tmp203) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (tmp201 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: tmp200 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp200) ; } /* end of [aux_find_30] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 19034(line=624, offs=1) -- 20696(line=675, offs=4) */ ATSstaticdec() ats_void_type aux_iter_31 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_int_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; // ATSlocal_void (tmp212) ; ATSlocal (ats_bool_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; // ATSlocal_void (tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_bool_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_aux_iter_31: do { /* branch: __ats_lab_57 */ __ats_lab_57_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_64_0 ; } __ats_lab_57_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_1) ; // if (arg3 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp207 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_0) ; tmp208 = ats_caselptrlab_mac(anairiats_sum_1, arg3, atslab_1) ; tmp209 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp207), atslab_stbefitem_var) ; tmp210 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp205), atslab_staftitem_lin) ; tmp211 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp207), atslab_stbefitem_lin) ; tmp213 = atspre_gt_int_int (tmp210, tmp211) ; if (tmp213) { /* tmp212 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_lin (tmp209, tmp210) ; } else { /* empty */ } /* end of [if] */ tmp214 = aux_find_30 (arg1, tmp209) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp214 == (ats_sum_ptr_type)0) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp216 = ats_caselptrlab_mac(anairiats_sum_7, tmp214, atslab_0) ; ATS_FREE(tmp214) ; tmp217 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add (arg0, tmp216) ; /* tmp215 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp209, tmp217) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (tmp214 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: do { /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp218 = atspre_gt_int_int (tmp210, tmp211) ; if (!tmp218) { goto __ats_lab_63_1 ; } tmp219 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (tmp209) ; do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (tmp219 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp220 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_mastyp (tmp209) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add (arg0, tmp220) ; /* tmp215 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp209, tmp221) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (tmp219 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: break ; } while (0) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: break ; } while (0) ; break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp206 ; arg3 = tmp208 ; goto __ats_lab_aux_iter_31 ; // tail call break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: break ; } while (0) ; return /* (tmp204) */ ; } /* end of [aux_iter_31] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env_state.dats: 20783(line=681, offs=3) -- 21050(line=687, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; // ATSlocal_void (tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; // ATSlocal_void (tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update: tmp223 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_res) ; tmp224 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_staftscstr_sais) ; tmp226 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp223), atslab_i2nvresstate_svs) ; /* tmp225 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp226) ; tmp228 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp223), atslab_i2nvresstate_gua) ; /* tmp227 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp228) ; tmp229 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, tmp223), atslab_i2nvresstate_arg) ; /* tmp222 = */ aux_iter_31 (arg0, tmp229, tmp224, arg2) ; return /* (tmp222) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPsome_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__SAITYPnone_1.tag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_state_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_void_type atsopt_state_staftitem_set_lin (ats_ptr_type sai, ats_int_type lin) { ((staftitem_t)sai)->atslab_staftitem_lin = lin; return ; } // end of [atsopt_state_staftitem_set_lin] ats_void_type atsopt_state_staftitem_set_typ (ats_ptr_type sai, ats_ptr_type os2es) { ((staftitem_t)sai)->atslab_staftitem_typ = os2es; return ; } // end of [atsopt_state_staftitem_set_typ] ats_void_type atsopt_state_staftscstr_met_set (ats_ptr_type sac, ats_ptr_type met) { ((staftscstr_t)sac)->atslab_staftscstr_met = met ; return ; } // end of [atsopt_state_staftscstr_met_set] ats_void_type atsopt_state_staftscstr_cstr_set (ats_ptr_type sac, ats_ptr_type cstr) { ((staftscstr_t)sac)->atslab_staftscstr_cstr = cstr ; return ; } // end of [atsopt_state_staftscstr_cstr_set] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_state_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp3_sats.c0000664000175000017500000004242412223166160021536 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTdot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTcons_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tbool_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tchar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tfloat_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tint_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tstring_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvbox_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0lab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0ind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrinit_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrpsz_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_ptr_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_var_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ebool_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecaseof_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Echar_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Econ_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecstsp_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecrypt_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Edynload_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eeffmask_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eextval_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efix_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloat_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloatsp_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efoldat_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efreeat_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eif_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eint_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eintsp_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_dyn_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elaminit_dyn_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_met_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_sta_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_delay_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_ldelay_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_force_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elet_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloop_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloopexn_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elst_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_ptr_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_var_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eraise_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erec_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erefarg_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Escaseof_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eseq_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esif_47) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estring_48) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estruct_49) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etrywith_53) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_ptr_55) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_var_56) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ewhere_59) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clist_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Csaspdec_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdcstdec_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdatdec_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cexndec_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextype_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextval_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextcode_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_par_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_rec_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cfundecs_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvardecs_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cimpdec_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clocal_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cstaload_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdynload_17) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTnil_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTdot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABP3ATLSTcons_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tann_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tany_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tbool_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tchar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tcon_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tempty_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Texist_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tfloat_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tint_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tlst_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Trec_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tstring_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvbox_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1lab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB1ind_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0lab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3LAB0ind_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__LABD3EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eann_type_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_dyn_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eapp_sta_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrinit_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Earrpsz_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_ptr_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eassgn_var_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ebool_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecaseof_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Echar_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Econ_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecst_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecstsp_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ecrypt_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Edynload_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eeffmask_15.tag = 15 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eempty_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eextval_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efix_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloat_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efloatsp_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efoldat_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Efreeat_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eif_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eint_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eintsp_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_dyn_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elaminit_dyn_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_met_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elam_sta_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_delay_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_ldelay_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elazy_force_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elet_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloop_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eloopexn_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Elst_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_ptr_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eptrof_var_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eraise_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erec_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Erefarg_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Escaseof_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_ptr_44.tag = 44 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esel_var_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eseq_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Esif_47.tag = 47 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estring_48.tag = 48 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Estruct_49.tag = 49 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpcst_50.tag = 50 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etmpvar_51.tag = 51 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etop_52.tag = 52 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Etrywith_53.tag = 53 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Evar_54.tag = 54 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_ptr_55.tag = 55 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_assgn_var_56.tag = 56 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_ptr_57.tag = 57 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Eviewat_var_58.tag = 58 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Ewhere_59.tag = 59 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clist_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Csaspdec_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdcstdec_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdatdec_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cexndec_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextype_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextval_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cextcode_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_par_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvaldecs_rec_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cfundecs_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cvardecs_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cimpdec_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Clocal_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cstaload_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__D3Cdynload_17.tag = 17 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp3_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_bool_dats.c0000664000175000017500000000546312223166160022746 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_bool_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_bool_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_counter.cats0000664000175000017500000001036712223166160021302 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // July 2007 // /* ****** ****** */ /* ** ats_counter: a simple counter implementation */ /* ****** ****** */ #ifndef ATS_SRC_COUNTER_CATS #define ATS_SRC_COUNTER_CATS /* ****** ****** */ #include /* ****** ****** */ #include "ats_memory.h" #include "ats_types.h" /* ****** ****** */ typedef ats_int32_type atsopt_count_type ; /* typedef atsopt_count_type *atsopt_counter_type ; */ ATSinline() ats_ptr_type atsopt_counter_make () { ats_ptr_type cntr ; cntr = ATS_MALLOC (sizeof(atsopt_count_type)) ; *(atsopt_count_type*)cntr = 0 ; return cntr ; } // end of [atsopt_counter_make] ATSinline() ats_void_type atsopt_counter_inc (ats_ptr_type cntr) { *(atsopt_count_type*)cntr += 1 ; return ; } // end of [atsopt_counter_inc] ATSinline() atsopt_count_type atsopt_counter_get (ats_ptr_type cntr) { return *(atsopt_count_type*)cntr ; } // end of [atsopt_counter_get] ATSinline() ats_void_type atsopt_counter_set ( ats_ptr_type cntr, atsopt_count_type cnt ) { *(atsopt_count_type*)cntr = cnt ; return ; } // end of [atsopt_counter_set] ATSinline() ats_void_type atsopt_counter_reset (ats_ptr_type cntr) { *(atsopt_count_type*)cntr = 0 ; return ; } // end of [atsopt_counter_reset] ATSinline() atsopt_count_type atsopt_counter_getinc (ats_ptr_type cntr) { atsopt_count_type cnt ; cnt = *(atsopt_count_type*)cntr ; *(atsopt_count_type*)cntr += 1 ; return cnt ; } // end of [atsopt_counter_getinc] ATSinline() atsopt_count_type atsopt_counter_incget (ats_ptr_type cntr) { *((atsopt_count_type*)cntr) += 1 ; return *(atsopt_count_type*)cntr ; } // end of [atsopt_counter_incget] /* ****** ****** */ ATSinline() ats_int_type atsopt_compare_count_count (atsopt_count_type cnt1, atsopt_count_type cnt2) { if (cnt1 < cnt2) return -1 ; if (cnt1 > cnt2) return 1 ; return 0 ; } // end of [atsopt_compare_count_count] /* ****** ****** */ ATSinline() ats_uint_type atsopt_count_hash ( atsopt_count_type cnt ) { /* 2654435761 is the golden ration of 2^32 */ return (2654435761UL * (ats_uint_type)cnt) ; } // end of [atsopt_count_hash] /* ****** ****** */ ATSinline() ats_void_type atsopt_fprint_count ( ats_ptr_type out, atsopt_count_type cnt ) { fprintf ((FILE*)out, "%lli", (ats_llint_type)cnt) ; return ; } // end of [atsopt_fprint_count] /* ****** ****** */ extern ats_ptr_type atspre_tostringf (ats_ptr_type format, ...) ; ATSinline() ats_ptr_type atsopt_tostring_count (atsopt_count_type cnt) { return atspre_tostringf ("%lli", (ats_llint_type)cnt) ; } // end of [atsopt_tostring_count] ATSinline() ats_ptr_type atsopt_tostring_prefix_count ( ats_ptr_type pre, atsopt_count_type cnt ) { return atspre_tostringf ("%s%lli", (char*)pre, (ats_llint_type)cnt) ; } // end of [atsopt_tostring_prefix_count] /* ****** ****** */ #endif // ATS_SRC_COUNTER_CATS /* end of [ats_counter.cats] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_location_dats.c0000664000175000017500000005577512223166160021752 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_filename ; ats_int_type atslab_begpos_line ; ats_int_type atslab_begpos_loff ; ats_lint_type atslab_begpos_toff ; ats_int_type atslab_endpos_line ; ats_int_type atslab_endpos_loff ; ats_lint_type atslab_endpos_toff ; } anairiats_rec_0 ; /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_lint_type, atspre_add_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_lt_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_lte_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_bool_type, atspre_gte_lint_lint) (ats_lint_type, ats_lint_type) ; ATSextern_fun(ats_void_type, atspre_fprint_lint) (ats_ref_type, ats_lint_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_filename_fprint_filename_base) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_location_2esats__sasp__location_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy) ; /* internal function declarations */ static ats_bool_type location_is_none_2 (ats_ptr_type arg0) ; static ats_ptr_type location_combine_main_3 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 2276(line=78, offs=25) -- 2540(line=86, offs=2) */ ATSglobaldec() ats_ptr_type ats_location_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_int_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_lint_type, tmp4) ; ATSlocal (ats_int_type, tmp5) ; ATSlocal (ats_int_type, tmp6) ; ATSlocal (ats_lint_type, tmp7) ; __ats_lab_ats_location_make: tmp2 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line (arg1) ; tmp3 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff (arg1) ; tmp4 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (arg1) ; tmp5 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_line (arg2) ; tmp6 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_loff (arg2) ; tmp7 = ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__position_toff (arg2) ; tmp1 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_filename, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_begpos_line, tmp2) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_begpos_loff, tmp3) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_begpos_toff, tmp4) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_endpos_line, tmp5) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_endpos_loff, tmp6) ; ats_selptrset_mac(anairiats_rec_0, tmp1, atslab_endpos_toff, tmp7) ; return (tmp1) ; } /* end of [ats_location_make] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 2596(line=88, offs=29) -- 2847(line=96, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; ATSlocal (ats_int_type, tmp10) ; ATSlocal (ats_lint_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make: tmp9 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_line) ; tmp10 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_loff) ; tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_toff) ; tmp12 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename) ; tmp8 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_filename, tmp12) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_begpos_line, tmp9) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_begpos_loff, tmp10) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_begpos_toff, tmp11) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_endpos_line, tmp9) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_endpos_loff, tmp10) ; ats_selptrset_mac(anairiats_rec_0, tmp8, atslab_endpos_toff, tmp11) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_end_make] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 2910(line=102, offs=4) -- 2979(line=104, offs=25) */ ATSstaticdec() ats_bool_type location_is_none_2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp13) ; ATSlocal (ats_lint_type, tmp14) ; __ats_lab_location_is_none_2: tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_toff) ; tmp13 = atspre_lt_lint_lint (tmp14, 0L) ; return (tmp13) ; } /* end of [location_is_none_2] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 2984(line=106, offs=4) -- 4120(line=145, offs=6) */ ATSstaticdec() ats_ptr_type location_combine_main_3 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_int_type, tmp16) ; ATSlocal (ats_int_type, tmp17) ; ATSlocal (ats_lint_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_int_type, tmp20) ; ATSlocal (ats_lint_type, tmp21) ; ATSlocal (ats_bool_type, tmp23) ; ATSlocal (ats_lint_type, tmp24) ; ATSlocal (ats_lint_type, tmp25) ; ATSlocal (ats_int_type, tmp26) ; ATSlocal (ats_int_type, tmp27) ; ATSlocal (ats_lint_type, tmp28) ; ATSlocal (ats_int_type, tmp29) ; ATSlocal (ats_int_type, tmp30) ; ATSlocal (ats_lint_type, tmp31) ; ATSlocal (ats_bool_type, tmp33) ; ATSlocal (ats_lint_type, tmp34) ; ATSlocal (ats_lint_type, tmp35) ; ATSlocal (ats_int_type, tmp36) ; ATSlocal (ats_int_type, tmp37) ; ATSlocal (ats_lint_type, tmp38) ; ATSlocal (ats_int_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; ATSlocal (ats_lint_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_location_combine_main_3: /* ats_int_type tmp16 ; */ /* ats_int_type tmp17 ; */ /* ats_lint_type tmp18 ; */ /* ats_int_type tmp19 ; */ /* ats_int_type tmp20 ; */ /* ats_lint_type tmp21 ; */ tmp24 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_toff) ; tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_toff) ; tmp23 = atspre_lte_lint_lint (tmp24, tmp25) ; if (tmp23) { tmp26 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_line) ; tmp16 = tmp26 ; tmp27 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_loff) ; tmp17 = tmp27 ; tmp28 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_toff) ; tmp18 = tmp28 ; } else { tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_line) ; tmp16 = tmp29 ; tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_loff) ; tmp17 = tmp30 ; tmp31 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_toff) ; tmp18 = tmp31 ; } /* end of [if] */ tmp34 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_toff) ; tmp35 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_toff) ; tmp33 = atspre_gte_lint_lint (tmp34, tmp35) ; if (tmp33) { tmp36 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_line) ; tmp19 = tmp36 ; tmp37 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_loff) ; tmp20 = tmp37 ; tmp38 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_toff) ; tmp21 = tmp38 ; } else { tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_line) ; tmp19 = tmp39 ; tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_loff) ; tmp20 = tmp40 ; tmp41 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_toff) ; tmp21 = tmp41 ; } /* end of [if] */ tmp42 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename) ; tmp15 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_filename, tmp42) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_begpos_line, tmp16) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_begpos_loff, tmp17) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_begpos_toff, tmp18) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_endpos_line, tmp19) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_endpos_loff, tmp20) ; ats_selptrset_mac(anairiats_rec_0, tmp15, atslab_endpos_toff, tmp21) ; return (tmp15) ; } /* end of [location_combine_main_3] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4204(line=149, offs=28) -- 4367(line=154, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_bool_type, tmp44) ; ATSlocal (ats_bool_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: __ats_lab_0_1: tmp44 = location_is_none_2 (arg0) ; if (!tmp44) { goto __ats_lab_1_1 ; } tmp43 = arg1 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp45 = location_is_none_2 (arg1) ; if (!tmp45) { goto __ats_lab_2_1 ; } tmp43 = arg0 ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: __ats_lab_2_1: tmp43 = location_combine_main_3 (arg0, arg1) ; break ; } while (0) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_combine] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4474(line=161, offs=23) -- 4494(line=161, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename: tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_filename) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4526(line=162, offs=32) -- 4549(line=162, offs=55) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line: tmp47 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_line) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4581(line=163, offs=32) -- 4604(line=163, offs=55) */ ATSglobaldec() ats_lint_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_lint_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff: tmp48 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_toff) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4636(line=164, offs=32) -- 4659(line=164, offs=55) */ ATSglobaldec() ats_lint_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_lint_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff: tmp49 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_endpos_toff) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_endpos_toff] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4716(line=170, offs=3) -- 4768(line=170, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__lte_location_location (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp50) ; ATSlocal (ats_lint_type, tmp51) ; ATSlocal (ats_lint_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__lte_location_location: tmp51 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_begpos_toff) ; tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_toff) ; tmp50 = atspre_lte_lint_lint (tmp51, tmp52) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__lte_location_location] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 4852(line=176, offs=17) -- 5467(line=191, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_lint_type, tmp58) ; ATSlocal (ats_lint_type, tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_int_type, tmp67) ; // ATSlocal_void (tmp68) ; // ATSlocal_void (tmp69) ; ATSlocal (ats_lint_type, tmp70) ; ATSlocal (ats_lint_type, tmp71) ; // ATSlocal_void (tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_int_type, tmp78) ; ATSlocal (ats_int_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location: tmp55 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_filename) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp55) ; /* tmp56 = */ atspre_fprint_string (arg0, ATSstrcst(": ")) ; tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_toff) ; tmp58 = atspre_add_lint_lint (tmp59, 1L) ; /* tmp57 = */ atspre_fprint_lint (arg0, tmp58) ; /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst("(line=")) ; tmp63 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_line) ; tmp62 = atspre_add_int_int (tmp63, 1) ; /* tmp61 = */ atspre_fprint_int (arg0, tmp62) ; /* tmp64 = */ atspre_fprint_string (arg0, ATSstrcst(", offs=")) ; tmp67 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_begpos_loff) ; tmp66 = atspre_add_int_int (tmp67, 1) ; /* tmp65 = */ atspre_fprint_int (arg0, tmp66) ; /* tmp68 = */ atspre_fprint_string (arg0, ATSstrcst(") -- ")) ; tmp71 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_toff) ; tmp70 = atspre_add_lint_lint (tmp71, 1L) ; /* tmp69 = */ atspre_fprint_lint (arg0, tmp70) ; /* tmp72 = */ atspre_fprint_string (arg0, ATSstrcst("(line=")) ; tmp75 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_line) ; tmp74 = atspre_add_int_int (tmp75, 1) ; /* tmp73 = */ atspre_fprint_int (arg0, tmp74) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(", offs=")) ; tmp79 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_endpos_loff) ; tmp78 = atspre_add_int_int (tmp79, 1) ; /* tmp77 = */ atspre_fprint_int (arg0, tmp78) ; /* tmp53 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; return /* (tmp53) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 5522(line=193, offs=26) -- 5562(line=193, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__print_location (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__print_location: tmp81 = atspre_stdout_get () ; tmp82 = ats_selsin_mac(tmp81, atslab_1) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (tmp82, arg0) ; /* tmp80 = */ atspre_stdout_view_set () ; return /* (tmp80) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__print_location] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 5588(line=194, offs=26) -- 5628(line=194, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; // ATSlocal_void (tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location: tmp85 = atspre_stderr_get () ; tmp86 = ats_selsin_mac(tmp85, atslab_1) ; /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_location (tmp86, arg0) ; /* tmp84 = */ atspre_stderr_view_set () ; return /* (tmp84) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location] */ /* // /home/hwxi/research/Anairiats/src/ats_location.dats: 5682(line=200, offs=3) -- 6310(line=225, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp88) ; ATSlocal (ats_int_type, tmp89) ; ATSlocal (ats_bool_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_int_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line (arg1) ; tmp90 = atspre_gte_int_int (tmp89, 0) ; if (tmp90) { tmp91 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_get_filename (arg1) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst("#line ")) ; tmp94 = atspre_add_int_int (tmp89, 1) ; /* tmp93 = */ atspre_fprint_int (arg0, tmp94) ; /* tmp95 = */ atspre_fprint_string (arg0, ATSstrcst(" \"")) ; /* tmp96 = */ atsopt_filename_fprint_filename_base (arg0, tmp91) ; /* tmp88 = */ atspre_fprint_string (arg0, ATSstrcst("\"\n")) ; } else { /* empty */ } /* end of [if] */ return /* (tmp88) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_location_2esats__fprint_line_pragma] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_location_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_location_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_location_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_location_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_location_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_filename, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__filename_dummy) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_begpos_line, -1) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_begpos_loff, -1) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_begpos_toff, -1L) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_endpos_line, -1) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_endpos_loff, -1) ; ats_selptrset_mac(anairiats_rec_0, statmp0, atslab_endpos_toff, -1L) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_dummy = statmp0 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_location_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_solver_fm_sats.c0000664000175000017500000000273012223166160022134 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICvec_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICveclst_1) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICvec_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_solver_fm_2esats__ICveclst_1.tag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_solver_fm_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/prelude_dats_basics_dats.c0000664000175000017500000001213212223166160023246 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* functions for exits */ ats_void_type // external ats_exit(const ats_int_type n) { exit(n) ; return ; } ats_void_type // external ats_exit_errmsg (const ats_int_type n, const ats_ptr_type errmsg) { fprintf(stderr, "%s", (char *)errmsg) ; exit(n) ; return ; } /* functions for asserts */ ats_void_type atspre_assert ( const ats_bool_type assertion ) { if (!assertion) { ats_exit_errmsg (1, "[Exit: atspre_assert] failed\n") ; } return ; } // end of [atspre_assert] ats_void_type atspre_assert_errmsg ( const ats_bool_type assertion, const ats_ptr_type errmsg ) { if (!assertion) { fprintf (stderr, "%s", (char *)errmsg) ; ats_exit_errmsg (1, "[Exit: atspre_assert_errmsg] failed\n") ; } return ; } // end of [atspre_assert_errmsg] /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ #ifdef _ATS_PROOFCHECK /* // /home/hwxi/research/Anairiats/src/prelude_dats_basics.dats: 1621(line=41, offs=1) -- 1676(line=41, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () { /* local vardec */ // ATSlocal_void (tmp0) ; ats_proofcheck_beg_mac(ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r) ; ats_proofcheck_end_mac(ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck] */ #endif /* _ATS_PROOFCHECK */ #ifdef _ATS_PROOFCHECK /* // /home/hwxi/research/Anairiats/src/prelude_dats_basics.dats: 1727(line=44, offs=1) -- 1782(line=44, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () { /* local vardec */ // ATSlocal_void (tmp1) ; ats_proofcheck_beg_mac(ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w) ; ats_proofcheck_end_mac(ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w) ; return /* (tmp1) */ ; } /* end of [ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck] */ #endif /* _ATS_PROOFCHECK */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration // extern ats_int_type ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__dynload () { // ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2prelude_dats_basics_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_r_r_prfck () ; ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/prelude_dats_basics_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans2_env_sats.c0000664000175000017500000000404412223166160022221 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans2_env_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_constraint_sats.c0000664000175000017500000001430412223166160022324 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEexp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEint_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEintinf_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEvar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEineg_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEiadd_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEisub_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEimul_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEpdiff_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEexp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEvar_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbool_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbadd_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbmul_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbneg_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEiexp_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEexp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEvar_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEnull_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEpadd_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTmark_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTnil_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEexp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEint_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEintinf_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEvar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEineg_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEiadd_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEisub_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEimul_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3IEpdiff_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEexp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEvar_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbool_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbadd_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbmul_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEbneg_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3BEiexp_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEexp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEvar_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEnull_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S3AEpadd_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTcons_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTmark_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_constraint_2esats__S2CFDEFLSTnil_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_constraint_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_sats.c0000664000175000017500000004250012223166160021525 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_2 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTOPTsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTOPTnone_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatconptr_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatcontyp_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMe1xp_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMfil_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMvar_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt1_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEcst_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEextype_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyarr_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyrec_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEunion_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEvar_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEapp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEcst_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEfun_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyarr_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyrec_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEunion_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEvar_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__SP2Tcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsrt_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsub_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASpre_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGseq_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTOPTsome_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTOPTnone_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatconptr_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMdatcontyp_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMe1xp_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMfil_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMvar_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt1_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTcons_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEapp_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEcst_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEextype_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyarr_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyrec_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEunion_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEvar_8.tag = 8 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTcons_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEapp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEcst_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEfun_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyarr_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyrec_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEunion_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEvar_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__SP2Tcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsrt_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2TEsub_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASpre_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGseq_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_e1xp_eval_dats.c0000664000175000017500000030406112223166160022007 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_double_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_9 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDif_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifdef_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__SRPIFKINDifndef_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALchar_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALfloat_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALstring_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALcstsp_4) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert) (ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_neq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isdigit) (ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_char_isupper) (ats_char_type) ; ATSextern_fun(ats_int_type, atspre_sub_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_bool_type, atspre_neq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_double_type, atspre_double_of_string) (ats_ptr_type) ; ATSextern_fun(ats_double_type, atspre_add_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_sub_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_mul_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_double_type, atspre_div_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_lt_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_lte_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_gt_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_gte_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_bool_type, atspre_neq_double_double) (ats_double_type, ats_double_type) ; ATSextern_fun(ats_ptr_type, atspre_tostrptr_double) (ats_double_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_mul_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_div_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_asl_int_int1) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_asr_int_int1) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_tostrptr_int) (ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_int_of_size) (ats_size_type) ; ATSextern_fun(ats_size_type, atspre_add_size1_int1) (ats_size_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_lte_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_gt_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_gte_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_neq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_char_type, atspre_string_get_char_at__intsz) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_string_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_size_type, atspre_string_length) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_is_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_empty) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atspre_string_isnot_atend) (ats_ptr_type, ats_size_type) ; ATSextern_fun(ats_int_type, atsopt_debug_flag_get) () ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQEQ) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_bool_type is_debug_0 () ; static ats_ptr_type e1xp_eval_errmsg_app_3 (ats_ptr_type arg0) ; static ats_ptr_type e1xp_eval_errmsg_id_4 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_errmsg_list_5 (ats_ptr_type arg0) ; static ats_ptr_type e1xp_eval_appid_errmsg_arity_6 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_appid_errmsg_opr_7 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_opr_errmsg_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_errmsg_undef_9 (ats_ptr_type arg0) ; static ats_int_type loop1_11 (ats_int_type arg0, ats_ptr_type arg1, ats_size_type arg2) ; static ats_int_type loop2_12 (ats_int_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_int_type arg3) ; static ats_int_type e1xp_eval_int_10 (ats_ptr_type arg0) ; static ats_ptr_type e1xp_eval_defined_13 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_undefined_14 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type e1xp_eval_add_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_sub_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_mul_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_div_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_lt_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_lteq_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_gt_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_gteq_22 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_eq_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_neq_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_and_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_or_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_asl_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_asr_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type e1xp_eval_appid_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2059(line=66, offs=4) -- 2105(line=66, offs=50) */ ATSstaticdec() ats_bool_type is_debug_0 () { /* local vardec */ ATSlocal (ats_bool_type, tmp0) ; ATSlocal (ats_int_type, tmp1) ; __ats_lab_is_debug_0: tmp1 = atsopt_debug_flag_get () ; tmp0 = atspre_gt_int_int (tmp1, 0) ; return (tmp0) ; } /* end of [is_debug_0] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2151(line=71, offs=14) -- 2379(line=78, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_double_type, tmp5) ; ATSlocal (ats_char_type, tmp6) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp2 = atspre_neq_int_int (tmp3, 0) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp2 = atspre_string_isnot_empty (tmp4) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp2 = atspre_neq_double_double (tmp5, 0.0) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp6 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp2 = atspre_neq_char_char (tmp6, '\000') ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (((ats_sum_ptr_type)arg0)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: tmp2 = ats_true_bool ; break ; } while (0) ; return (tmp2) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2430(line=80, offs=25) -- 2451(line=80, offs=46) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_false (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp7) ; ATSlocal (ats_bool_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_false: tmp8 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_true (arg0) ; tmp7 = atspre_neg_bool (tmp8) ; return (tmp7) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__v1al_is_false] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2478(line=84, offs=4) -- 2668(line=91, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_errmsg_app_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; ATSlocal (ats_bool_type, tmp12) ; // ATSlocal_void (tmp13) ; // ATSlocal_void (tmp14) ; __ats_lab_e1xp_eval_errmsg_app_3: /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp12 = is_debug_0 () ; if (tmp12) { /* tmp11 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp13 = */ atspre_prerr_string (ATSstrcst(": an identifier is expected here.")) ; /* tmp14 = */ atspre_prerr_newline () ; /* tmp9 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp9) ; } /* end of [e1xp_eval_errmsg_app_3] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2706(line=93, offs=4) -- 2924(line=101, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_errmsg_id_4 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_bool_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; __ats_lab_e1xp_eval_errmsg_id_4: /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp18 = is_debug_0 () ; if (tmp18) { /* tmp17 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp19 = */ atspre_prerr_string (ATSstrcst(": unrecognized identifier: ")) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp21 = */ atspre_prerr_newline () ; /* tmp15 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp15) ; } /* end of [e1xp_eval_errmsg_id_4] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 2961(line=103, offs=4) -- 3158(line=110, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_errmsg_list_5 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; ATSlocal (ats_bool_type, tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_e1xp_eval_errmsg_list_5: /* tmp23 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp25 = is_debug_0 () ; if (tmp25) { /* tmp24 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp26 = */ atspre_prerr_string (ATSstrcst(": illegal list expression is used here.")) ; /* tmp27 = */ atspre_prerr_newline () ; /* tmp22 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp22) ; } /* end of [e1xp_eval_errmsg_list_5] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 3197(line=112, offs=4) -- 3449(line=121, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_appid_errmsg_arity_6 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; // ATSlocal_void (tmp29) ; // ATSlocal_void (tmp30) ; ATSlocal (ats_bool_type, tmp31) ; // ATSlocal_void (tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; __ats_lab_e1xp_eval_appid_errmsg_arity_6: /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp31 = is_debug_0 () ; if (tmp31) { /* tmp30 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval_appid")) ; } else { /* empty */ } /* end of [if] */ /* tmp32 = */ atspre_prerr_string (ATSstrcst(": the arity of [")) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp34 = */ atspre_prerr_string (ATSstrcst("] is mismatched.")) ; /* tmp35 = */ atspre_prerr_newline () ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp28) ; } /* end of [e1xp_eval_appid_errmsg_arity_6] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 3495(line=123, offs=4) -- 3739(line=131, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_appid_errmsg_opr_7 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; ATSlocal (ats_bool_type, tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; __ats_lab_e1xp_eval_appid_errmsg_opr_7: /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp39 = is_debug_0 () ; if (tmp39) { /* tmp38 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval_appid")) ; } else { /* empty */ } /* end of [if] */ /* tmp40 = */ atspre_prerr_string (ATSstrcst(": unrecognized operation: [")) ; /* tmp41 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp42 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp43 = */ atspre_prerr_newline () ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp36) ; } /* end of [e1xp_eval_appid_errmsg_opr_7] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 3783(line=133, offs=4) -- 4015(line=141, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_opr_errmsg_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; // ATSlocal_void (tmp46) ; ATSlocal (ats_bool_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; __ats_lab_e1xp_eval_opr_errmsg_8: /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp47 = is_debug_0 () ; if (tmp47) { /* tmp46 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp48 = */ atspre_prerr_string (ATSstrcst(": illegal argument(s) for [")) ; /* tmp49 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (arg1) ; /* tmp50 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp51 = */ atspre_prerr_newline () ; /* tmp44 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp44) ; } /* end of [e1xp_eval_opr_errmsg_8] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 4053(line=143, offs=4) -- 4248(line=150, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_errmsg_undef_9 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_bool_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; __ats_lab_e1xp_eval_errmsg_undef_9: /* tmp53 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp55 = is_debug_0 () ; if (tmp55) { /* tmp54 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp56 = */ atspre_prerr_string (ATSstrcst(": undefined expression is used here.")) ; /* tmp57 = */ atspre_prerr_newline () ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp52) ; } /* end of [e1xp_eval_errmsg_undef_9] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 4578(line=164, offs=7) -- 5291(line=186, offs=8) */ ATSstaticdec() ats_int_type loop1_11 (ats_int_type arg0, ats_ptr_type arg1, ats_size_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp59) ; ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_char_type, tmp61) ; ATSlocal (ats_bool_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; ATSlocal (ats_size_type, tmp64) ; ATSlocal (ats_int_type, tmp65) ; ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_size_type, tmp67) ; ATSlocal (ats_char_type, tmp68) ; ATSlocal (ats_size_type, tmp69) ; ATSlocal (ats_bool_type, tmp70) ; ATSlocal (ats_int_type, tmp71) ; ATSlocal (ats_size_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_size_type, tmp75) ; __ats_lab_loop1_11: tmp60 = atspre_string_isnot_atend (arg1, arg2) ; if (tmp60) { tmp61 = atspre_string_get_char_at (arg1, arg2) ; tmp62 = atspre_neq_char_char (tmp61, '0') ; if (tmp62) { tmp64 = atspre_add_size1_int1 (arg2, 1) ; tmp65 = atspre_sub_char_char (tmp61, '0') ; tmp63 = loop2_12 (10, arg1, tmp64, tmp65) ; tmp59 = atspre_mul_int_int (arg0, tmp63) ; } else { tmp67 = atspre_add_size1_int1 (arg2, 1) ; tmp66 = atspre_string_isnot_atend (arg1, tmp67) ; if (tmp66) { tmp69 = atspre_add_size1_int1 (arg2, 1) ; tmp68 = atspre_string_get_char_at (arg1, tmp69) ; tmp70 = atspre_char_isdigit (tmp68) ; if (tmp70) { tmp72 = atspre_add_size1_int1 (arg2, 2) ; tmp73 = atspre_sub_char_char (tmp68, '0') ; tmp71 = loop2_12 (8, arg1, tmp72, tmp73) ; tmp59 = atspre_mul_int_int (arg0, tmp71) ; } else { tmp75 = atspre_add_size1_int1 (arg2, 2) ; tmp74 = loop2_12 (16, arg1, tmp75, 0) ; tmp59 = atspre_mul_int_int (arg0, tmp74) ; } /* end of [if] */ } else { tmp59 = 0 ; } /* end of [if] */ } /* end of [if] */ } else { tmp59 = 0 ; } /* end of [if] */ return (tmp59) ; } /* end of [loop1_11] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 5336(line=189, offs=7) -- 5767(line=202, offs=8) */ ATSstaticdec() ats_int_type loop2_12 (ats_int_type arg0, ats_ptr_type arg1, ats_size_type arg2, ats_int_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp76) ; ATSlocal (ats_bool_type, tmp77) ; ATSlocal (ats_char_type, tmp78) ; ATSlocal (ats_int_type, tmp79) ; ATSlocal (ats_bool_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_size_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_int_type, tmp85) ; __ats_lab_loop2_12: tmp77 = atspre_string_isnot_atend (arg1, arg2) ; if (tmp77) { tmp78 = atspre_string_get_char_at (arg1, arg2) ; tmp80 = atspre_char_isdigit (tmp78) ; if (tmp80) { tmp79 = atspre_sub_char_char (tmp78, '0') ; } else { tmp82 = atspre_char_isupper (tmp78) ; if (tmp82) { tmp81 = atspre_sub_char_char (tmp78, 'A') ; } else { tmp81 = atspre_sub_char_char (tmp78, 'a') ; } /* end of [if] */ tmp79 = atspre_add_int_int (10, tmp81) ; } /* end of [if] */ tmp83 = atspre_add_size1_int1 (arg2, 1) ; tmp85 = atspre_mul_int_int (arg3, arg0) ; tmp84 = atspre_add_int_int (tmp85, tmp79) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp83 ; arg3 = tmp84 ; goto __ats_lab_loop2_12 ; // tail call } else { tmp76 = arg3 ; } /* end of [if] */ return (tmp76) ; } /* end of [loop2_12] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 4372(line=156, offs=5) -- 6028(line=215, offs=4) */ ATSstaticdec() ats_int_type e1xp_eval_int_10 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp58) ; ATSlocal (ats_bool_type, tmp86) ; ATSlocal (ats_char_type, tmp87) ; ATSlocal (ats_bool_type, tmp88) ; __ats_lab_e1xp_eval_int_10: tmp86 = atspre_string_isnot_atend (ats_castfn_mac(ats_ptr_type, arg0), 0) ; if (tmp86) { tmp87 = atspre_string_get_char_at__intsz (ats_castfn_mac(ats_ptr_type, arg0), 0) ; tmp88 = atspre_neq_char_char (tmp87, '~') ; if (tmp88) { tmp58 = loop1_11 (1, ats_castfn_mac(ats_ptr_type, arg0), 0) ; } else { tmp58 = loop1_11 (-1, ats_castfn_mac(ats_ptr_type, arg0), 1) ; } /* end of [if] */ } else { tmp58 = 0 ; } /* end of [if] */ return (tmp58) ; } /* end of [e1xp_eval_int_10] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 6084(line=219, offs=5) -- 6496(line=231, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_defined_13 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_int_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_e1xp_eval_defined_13: tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_e1xp_node) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp90)->tag != 3) { goto __ats_lab_10_0 ; } __ats_lab_5_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_1, tmp90, atslab_0) ; tmp93 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (tmp91) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp93 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_6_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_5, tmp93, atslab_0) ; ATS_FREE(tmp93) ; tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp94), atslab_e1xp_node) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp95)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp92 = 0 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp92 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp93 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp92 = 0 ; break ; } while (0) ; tmp89 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp89)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp89, atslab_0, tmp92) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: tmp89 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED) ; break ; } while (0) ; return (tmp89) ; } /* end of [e1xp_eval_defined_13] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 6532(line=233, offs=5) -- 6948(line=245, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_undefined_14 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_int_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; __ats_lab_e1xp_eval_undefined_14: tmp97 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_e1xp_node) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp97)->tag != 3) { goto __ats_lab_16_0 ; } __ats_lab_11_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_1, tmp97, atslab_0) ; tmp100 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (tmp98) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (tmp100 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_12_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_5, tmp100, atslab_0) ; ATS_FREE(tmp100) ; tmp102 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp101), atslab_e1xp_node) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp102)->tag != 7) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp99 = 1 ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp99 = 0 ; break ; } while (0) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp100 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp99 = 1 ; break ; } while (0) ; tmp96 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp96)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp96, atslab_0, tmp99) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp96 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED) ; break ; } while (0) ; return (tmp96) ; } /* end of [e1xp_eval_undefined_14] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 6988(line=247, offs=5) -- 7387(line=259, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_add_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_double_type, tmp106) ; ATSlocal (ats_double_type, tmp107) ; ATSlocal (ats_double_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_int_type, tmp110) ; ATSlocal (ats_int_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; __ats_lab_e1xp_eval_add_15: tmp104 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp105 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp104)->tag != 1) { goto __ats_lab_18_0 ; } __ats_lab_17_1: if (((ats_sum_ptr_type)tmp105)->tag != 1) { goto __ats_lab_20_1 ; } __ats_lab_17_2: tmp106 = ats_caselptrlab_mac(anairiats_sum_2, tmp104, atslab_0) ; tmp107 = ats_caselptrlab_mac(anairiats_sum_2, tmp105, atslab_0) ; tmp108 = atspre_add_double_double (tmp106, tmp107) ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp103)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp103, atslab_0, tmp108) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp104)->tag != 2) { goto __ats_lab_19_0 ; } __ats_lab_18_1: if (((ats_sum_ptr_type)tmp105)->tag != 2) { goto __ats_lab_20_1 ; } __ats_lab_18_2: tmp109 = ats_caselptrlab_mac(anairiats_sum_0, tmp104, atslab_0) ; tmp110 = ats_caselptrlab_mac(anairiats_sum_0, tmp105, atslab_0) ; tmp111 = atspre_add_int_int (tmp109, tmp110) ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp103)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp103, atslab_0, tmp111) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp104)->tag != 3) { goto __ats_lab_20_0 ; } __ats_lab_19_1: if (((ats_sum_ptr_type)tmp105)->tag != 3) { goto __ats_lab_20_1 ; } __ats_lab_19_2: tmp112 = ats_caselptrlab_mac(anairiats_sum_1, tmp104, atslab_0) ; tmp113 = ats_caselptrlab_mac(anairiats_sum_1, tmp105, atslab_0) ; tmp114 = atspre_string_append (tmp112, tmp113) ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp103)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp103, atslab_0, tmp114) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: __ats_lab_20_2: tmp103 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; break ; } while (0) ; return (tmp103) ; } /* end of [e1xp_eval_add_15] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 7419(line=261, offs=5) -- 7759(line=272, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_sub_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_double_type, tmp118) ; ATSlocal (ats_double_type, tmp119) ; ATSlocal (ats_double_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_int_type, tmp123) ; __ats_lab_e1xp_eval_sub_16: tmp116 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp117 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp116)->tag != 1) { goto __ats_lab_22_0 ; } __ats_lab_21_1: if (((ats_sum_ptr_type)tmp117)->tag != 1) { goto __ats_lab_23_1 ; } __ats_lab_21_2: tmp118 = ats_caselptrlab_mac(anairiats_sum_2, tmp116, atslab_0) ; tmp119 = ats_caselptrlab_mac(anairiats_sum_2, tmp117, atslab_0) ; tmp120 = atspre_sub_double_double (tmp118, tmp119) ; tmp115 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp115)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp115, atslab_0, tmp120) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp116)->tag != 2) { goto __ats_lab_23_0 ; } __ats_lab_22_1: if (((ats_sum_ptr_type)tmp117)->tag != 2) { goto __ats_lab_23_1 ; } __ats_lab_22_2: tmp121 = ats_caselptrlab_mac(anairiats_sum_0, tmp116, atslab_0) ; tmp122 = ats_caselptrlab_mac(anairiats_sum_0, tmp117, atslab_0) ; tmp123 = atspre_sub_int_int (tmp121, tmp122) ; tmp115 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp115)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp115, atslab_0, tmp123) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: __ats_lab_23_1: __ats_lab_23_2: tmp115 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; break ; } while (0) ; return (tmp115) ; } /* end of [e1xp_eval_sub_16] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 7791(line=274, offs=5) -- 8131(line=285, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_mul_17 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_double_type, tmp127) ; ATSlocal (ats_double_type, tmp128) ; ATSlocal (ats_double_type, tmp129) ; ATSlocal (ats_int_type, tmp130) ; ATSlocal (ats_int_type, tmp131) ; ATSlocal (ats_int_type, tmp132) ; __ats_lab_e1xp_eval_mul_17: tmp125 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp126 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp125)->tag != 1) { goto __ats_lab_25_0 ; } __ats_lab_24_1: if (((ats_sum_ptr_type)tmp126)->tag != 1) { goto __ats_lab_26_1 ; } __ats_lab_24_2: tmp127 = ats_caselptrlab_mac(anairiats_sum_2, tmp125, atslab_0) ; tmp128 = ats_caselptrlab_mac(anairiats_sum_2, tmp126, atslab_0) ; tmp129 = atspre_mul_double_double (tmp127, tmp128) ; tmp124 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp124)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp124, atslab_0, tmp129) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp125)->tag != 2) { goto __ats_lab_26_0 ; } __ats_lab_25_1: if (((ats_sum_ptr_type)tmp126)->tag != 2) { goto __ats_lab_26_1 ; } __ats_lab_25_2: tmp130 = ats_caselptrlab_mac(anairiats_sum_0, tmp125, atslab_0) ; tmp131 = ats_caselptrlab_mac(anairiats_sum_0, tmp126, atslab_0) ; tmp132 = atspre_mul_int_int (tmp130, tmp131) ; tmp124 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp124)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp124, atslab_0, tmp132) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: __ats_lab_26_2: tmp124 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; break ; } while (0) ; return (tmp124) ; } /* end of [e1xp_eval_mul_17] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 8163(line=287, offs=5) -- 8503(line=298, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_div_18 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_double_type, tmp136) ; ATSlocal (ats_double_type, tmp137) ; ATSlocal (ats_double_type, tmp138) ; ATSlocal (ats_int_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_int_type, tmp141) ; __ats_lab_e1xp_eval_div_18: tmp134 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp135 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp134)->tag != 1) { goto __ats_lab_28_0 ; } __ats_lab_27_1: if (((ats_sum_ptr_type)tmp135)->tag != 1) { goto __ats_lab_29_1 ; } __ats_lab_27_2: tmp136 = ats_caselptrlab_mac(anairiats_sum_2, tmp134, atslab_0) ; tmp137 = ats_caselptrlab_mac(anairiats_sum_2, tmp135, atslab_0) ; tmp138 = atspre_div_double_double (tmp136, tmp137) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp133)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_0, tmp138) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp134)->tag != 2) { goto __ats_lab_29_0 ; } __ats_lab_28_1: if (((ats_sum_ptr_type)tmp135)->tag != 2) { goto __ats_lab_29_1 ; } __ats_lab_28_2: tmp139 = ats_caselptrlab_mac(anairiats_sum_0, tmp134, atslab_0) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_0, tmp135, atslab_0) ; tmp141 = atspre_div_int_int (tmp139, tmp140) ; tmp133 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp133)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp133, atslab_0, tmp141) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: __ats_lab_29_1: __ats_lab_29_2: tmp133 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; break ; } while (0) ; return (tmp133) ; } /* end of [e1xp_eval_div_18] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 8535(line=300, offs=5) -- 9014(line=315, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_lt_19 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_double_type, tmp145) ; ATSlocal (ats_double_type, tmp146) ; ATSlocal (ats_bool_type, tmp147) ; ATSlocal (ats_int_type, tmp148) ; ATSlocal (ats_int_type, tmp149) ; ATSlocal (ats_bool_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_bool_type, tmp153) ; __ats_lab_e1xp_eval_lt_19: tmp143 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp144 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp143)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_30_1: if (((ats_sum_ptr_type)tmp144)->tag != 1) { goto __ats_lab_33_1 ; } __ats_lab_30_2: tmp145 = ats_caselptrlab_mac(anairiats_sum_2, tmp143, atslab_0) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_2, tmp144, atslab_0) ; tmp147 = atspre_lt_double_double (tmp145, tmp146) ; if (tmp147) { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 1) ; } else { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp143)->tag != 2) { goto __ats_lab_32_0 ; } __ats_lab_31_1: if (((ats_sum_ptr_type)tmp144)->tag != 2) { goto __ats_lab_33_1 ; } __ats_lab_31_2: tmp148 = ats_caselptrlab_mac(anairiats_sum_0, tmp143, atslab_0) ; tmp149 = ats_caselptrlab_mac(anairiats_sum_0, tmp144, atslab_0) ; tmp150 = atspre_lt_int_int (tmp148, tmp149) ; if (tmp150) { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 1) ; } else { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp143)->tag != 3) { goto __ats_lab_33_0 ; } __ats_lab_32_1: if (((ats_sum_ptr_type)tmp144)->tag != 3) { goto __ats_lab_33_1 ; } __ats_lab_32_2: tmp151 = ats_caselptrlab_mac(anairiats_sum_1, tmp143, atslab_0) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_1, tmp144, atslab_0) ; tmp153 = atspre_lt_string_string (tmp151, tmp152) ; if (tmp153) { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 1) ; } else { tmp142 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp142)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp142, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: __ats_lab_33_2: tmp142 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; break ; } while (0) ; return (tmp142) ; } /* end of [e1xp_eval_lt_19] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 9045(line=317, offs=5) -- 9531(line=332, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_lteq_20 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_double_type, tmp157) ; ATSlocal (ats_double_type, tmp158) ; ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_bool_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_bool_type, tmp165) ; __ats_lab_e1xp_eval_lteq_20: tmp155 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp156 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp155)->tag != 1) { goto __ats_lab_35_0 ; } __ats_lab_34_1: if (((ats_sum_ptr_type)tmp156)->tag != 1) { goto __ats_lab_37_1 ; } __ats_lab_34_2: tmp157 = ats_caselptrlab_mac(anairiats_sum_2, tmp155, atslab_0) ; tmp158 = ats_caselptrlab_mac(anairiats_sum_2, tmp156, atslab_0) ; tmp159 = atspre_lte_double_double (tmp157, tmp158) ; if (tmp159) { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 1) ; } else { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp155)->tag != 2) { goto __ats_lab_36_0 ; } __ats_lab_35_1: if (((ats_sum_ptr_type)tmp156)->tag != 2) { goto __ats_lab_37_1 ; } __ats_lab_35_2: tmp160 = ats_caselptrlab_mac(anairiats_sum_0, tmp155, atslab_0) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_0, tmp156, atslab_0) ; tmp162 = atspre_lte_int_int (tmp160, tmp161) ; if (tmp162) { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 1) ; } else { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp155)->tag != 3) { goto __ats_lab_37_0 ; } __ats_lab_36_1: if (((ats_sum_ptr_type)tmp156)->tag != 3) { goto __ats_lab_37_1 ; } __ats_lab_36_2: tmp163 = ats_caselptrlab_mac(anairiats_sum_1, tmp155, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_1, tmp156, atslab_0) ; tmp165 = atspre_lte_string_string (tmp163, tmp164) ; if (tmp165) { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 1) ; } else { tmp154 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp154)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp154, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: __ats_lab_37_1: __ats_lab_37_2: tmp154 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; break ; } while (0) ; return (tmp154) ; } /* end of [e1xp_eval_lteq_20] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 9564(line=334, offs=5) -- 10043(line=349, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_gt_21 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_double_type, tmp169) ; ATSlocal (ats_double_type, tmp170) ; ATSlocal (ats_bool_type, tmp171) ; ATSlocal (ats_int_type, tmp172) ; ATSlocal (ats_int_type, tmp173) ; ATSlocal (ats_bool_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_bool_type, tmp177) ; __ats_lab_e1xp_eval_gt_21: tmp167 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp168 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp167)->tag != 1) { goto __ats_lab_39_0 ; } __ats_lab_38_1: if (((ats_sum_ptr_type)tmp168)->tag != 1) { goto __ats_lab_41_1 ; } __ats_lab_38_2: tmp169 = ats_caselptrlab_mac(anairiats_sum_2, tmp167, atslab_0) ; tmp170 = ats_caselptrlab_mac(anairiats_sum_2, tmp168, atslab_0) ; tmp171 = atspre_gt_double_double (tmp169, tmp170) ; if (tmp171) { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 1) ; } else { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp167)->tag != 2) { goto __ats_lab_40_0 ; } __ats_lab_39_1: if (((ats_sum_ptr_type)tmp168)->tag != 2) { goto __ats_lab_41_1 ; } __ats_lab_39_2: tmp172 = ats_caselptrlab_mac(anairiats_sum_0, tmp167, atslab_0) ; tmp173 = ats_caselptrlab_mac(anairiats_sum_0, tmp168, atslab_0) ; tmp174 = atspre_gt_int_int (tmp172, tmp173) ; if (tmp174) { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 1) ; } else { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp167)->tag != 3) { goto __ats_lab_41_0 ; } __ats_lab_40_1: if (((ats_sum_ptr_type)tmp168)->tag != 3) { goto __ats_lab_41_1 ; } __ats_lab_40_2: tmp175 = ats_caselptrlab_mac(anairiats_sum_1, tmp167, atslab_0) ; tmp176 = ats_caselptrlab_mac(anairiats_sum_1, tmp168, atslab_0) ; tmp177 = atspre_gt_string_string (tmp175, tmp176) ; if (tmp177) { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 1) ; } else { tmp166 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp166)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp166, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: __ats_lab_41_2: tmp166 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; break ; } while (0) ; return (tmp166) ; } /* end of [e1xp_eval_gt_21] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 10074(line=351, offs=5) -- 10560(line=366, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_gteq_22 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_double_type, tmp181) ; ATSlocal (ats_double_type, tmp182) ; ATSlocal (ats_bool_type, tmp183) ; ATSlocal (ats_int_type, tmp184) ; ATSlocal (ats_int_type, tmp185) ; ATSlocal (ats_bool_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_bool_type, tmp189) ; __ats_lab_e1xp_eval_gteq_22: tmp179 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp180 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp179)->tag != 1) { goto __ats_lab_43_0 ; } __ats_lab_42_1: if (((ats_sum_ptr_type)tmp180)->tag != 1) { goto __ats_lab_45_1 ; } __ats_lab_42_2: tmp181 = ats_caselptrlab_mac(anairiats_sum_2, tmp179, atslab_0) ; tmp182 = ats_caselptrlab_mac(anairiats_sum_2, tmp180, atslab_0) ; tmp183 = atspre_gte_double_double (tmp181, tmp182) ; if (tmp183) { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 1) ; } else { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp179)->tag != 2) { goto __ats_lab_44_0 ; } __ats_lab_43_1: if (((ats_sum_ptr_type)tmp180)->tag != 2) { goto __ats_lab_45_1 ; } __ats_lab_43_2: tmp184 = ats_caselptrlab_mac(anairiats_sum_0, tmp179, atslab_0) ; tmp185 = ats_caselptrlab_mac(anairiats_sum_0, tmp180, atslab_0) ; tmp186 = atspre_gte_int_int (tmp184, tmp185) ; if (tmp186) { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 1) ; } else { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp179)->tag != 3) { goto __ats_lab_45_0 ; } __ats_lab_44_1: if (((ats_sum_ptr_type)tmp180)->tag != 3) { goto __ats_lab_45_1 ; } __ats_lab_44_2: tmp187 = ats_caselptrlab_mac(anairiats_sum_1, tmp179, atslab_0) ; tmp188 = ats_caselptrlab_mac(anairiats_sum_1, tmp180, atslab_0) ; tmp189 = atspre_gte_string_string (tmp187, tmp188) ; if (tmp189) { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 1) ; } else { tmp178 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp178)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp178, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: __ats_lab_45_2: tmp178 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; break ; } while (0) ; return (tmp178) ; } /* end of [e1xp_eval_gteq_22] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 10593(line=368, offs=5) -- 10989(line=381, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_eq_23 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_int_type, tmp194) ; ATSlocal (ats_bool_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_bool_type, tmp198) ; __ats_lab_e1xp_eval_eq_23: tmp191 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp192 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp191)->tag != 2) { goto __ats_lab_47_0 ; } __ats_lab_46_1: if (((ats_sum_ptr_type)tmp192)->tag != 2) { goto __ats_lab_48_1 ; } __ats_lab_46_2: tmp193 = ats_caselptrlab_mac(anairiats_sum_0, tmp191, atslab_0) ; tmp194 = ats_caselptrlab_mac(anairiats_sum_0, tmp192, atslab_0) ; tmp195 = atspre_eq_int_int (tmp193, tmp194) ; if (tmp195) { tmp190 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp190)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp190, atslab_0, 1) ; } else { tmp190 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp190)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp190, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp191)->tag != 3) { goto __ats_lab_48_0 ; } __ats_lab_47_1: if (((ats_sum_ptr_type)tmp192)->tag != 3) { goto __ats_lab_48_1 ; } __ats_lab_47_2: tmp196 = ats_caselptrlab_mac(anairiats_sum_1, tmp191, atslab_0) ; tmp197 = ats_caselptrlab_mac(anairiats_sum_1, tmp192, atslab_0) ; tmp198 = atspre_eq_string_string (tmp196, tmp197) ; if (tmp198) { tmp190 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp190)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp190, atslab_0, 1) ; } else { tmp190 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp190)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp190, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: __ats_lab_48_1: __ats_lab_48_2: tmp190 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; break ; } while (0) ; return (tmp190) ; } /* end of [e1xp_eval_eq_23] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 11020(line=383, offs=5) -- 11420(line=396, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_neq_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_int_type, tmp202) ; ATSlocal (ats_int_type, tmp203) ; ATSlocal (ats_bool_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_bool_type, tmp207) ; __ats_lab_e1xp_eval_neq_24: tmp200 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp201 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp200)->tag != 2) { goto __ats_lab_50_0 ; } __ats_lab_49_1: if (((ats_sum_ptr_type)tmp201)->tag != 2) { goto __ats_lab_51_1 ; } __ats_lab_49_2: tmp202 = ats_caselptrlab_mac(anairiats_sum_0, tmp200, atslab_0) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_0, tmp201, atslab_0) ; tmp204 = atspre_neq_int_int (tmp202, tmp203) ; if (tmp204) { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_0, 1) ; } else { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp200)->tag != 3) { goto __ats_lab_51_0 ; } __ats_lab_50_1: if (((ats_sum_ptr_type)tmp201)->tag != 3) { goto __ats_lab_51_1 ; } __ats_lab_50_2: tmp205 = ats_caselptrlab_mac(anairiats_sum_1, tmp200, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_1, tmp201, atslab_0) ; tmp207 = atspre_neq_string_string (tmp205, tmp206) ; if (tmp207) { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_0, 1) ; } else { tmp199 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp199)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_0, 0) ; } /* end of [if] */ break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: __ats_lab_51_2: tmp199 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; break ; } while (0) ; return (tmp199) ; } /* end of [e1xp_eval_neq_24] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 11452(line=398, offs=5) -- 12120(line=419, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_and_25 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; ATSlocal (ats_int_type, tmp212) ; ATSlocal (ats_bool_type, tmp213) ; ATSlocal (ats_bool_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_bool_type, tmp217) ; ATSlocal (ats_bool_type, tmp218) ; __ats_lab_e1xp_eval_and_25: tmp209 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp209)->tag != 2) { goto __ats_lab_53_0 ; } __ats_lab_52_1: if (((ats_sum_ptr_type)tmp210)->tag != 2) { goto __ats_lab_54_1 ; } __ats_lab_52_2: tmp211 = ats_caselptrlab_mac(anairiats_sum_0, tmp209, atslab_0) ; tmp212 = ats_caselptrlab_mac(anairiats_sum_0, tmp210, atslab_0) ; tmp213 = atspre_eq_int_int (tmp211, 0) ; if (tmp213) { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 0) ; } else { tmp214 = atspre_eq_int_int (tmp212, 0) ; if (tmp214) { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 0) ; } else { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 1) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp209)->tag != 3) { goto __ats_lab_54_0 ; } __ats_lab_53_1: if (((ats_sum_ptr_type)tmp210)->tag != 3) { goto __ats_lab_54_1 ; } __ats_lab_53_2: tmp215 = ats_caselptrlab_mac(anairiats_sum_1, tmp209, atslab_0) ; tmp216 = ats_caselptrlab_mac(anairiats_sum_1, tmp210, atslab_0) ; tmp217 = atspre_string_is_empty (ats_castfn_mac(ats_ptr_type, tmp215)) ; if (tmp217) { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 0) ; } else { tmp218 = atspre_string_is_empty (ats_castfn_mac(ats_ptr_type, tmp215)) ; if (tmp218) { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 0) ; } else { tmp208 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp208)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp208, atslab_0, 1) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: __ats_lab_54_2: tmp208 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND) ; break ; } while (0) ; return (tmp208) ; } /* end of [e1xp_eval_and_25] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 12152(line=421, offs=5) -- 12824(line=442, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_or_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_int_type, tmp222) ; ATSlocal (ats_int_type, tmp223) ; ATSlocal (ats_bool_type, tmp224) ; ATSlocal (ats_bool_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_bool_type, tmp228) ; ATSlocal (ats_bool_type, tmp229) ; __ats_lab_e1xp_eval_or_26: tmp220 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp221 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)tmp220)->tag != 2) { goto __ats_lab_56_0 ; } __ats_lab_55_1: if (((ats_sum_ptr_type)tmp221)->tag != 2) { goto __ats_lab_57_1 ; } __ats_lab_55_2: tmp222 = ats_caselptrlab_mac(anairiats_sum_0, tmp220, atslab_0) ; tmp223 = ats_caselptrlab_mac(anairiats_sum_0, tmp221, atslab_0) ; tmp224 = atspre_neq_int_int (tmp222, 0) ; if (tmp224) { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 1) ; } else { tmp225 = atspre_neq_int_int (tmp223, 0) ; if (tmp225) { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 1) ; } else { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 0) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp220)->tag != 3) { goto __ats_lab_57_0 ; } __ats_lab_56_1: if (((ats_sum_ptr_type)tmp221)->tag != 3) { goto __ats_lab_57_1 ; } __ats_lab_56_2: tmp226 = ats_caselptrlab_mac(anairiats_sum_1, tmp220, atslab_0) ; tmp227 = ats_caselptrlab_mac(anairiats_sum_1, tmp221, atslab_0) ; tmp228 = atspre_string_isnot_empty (ats_castfn_mac(ats_ptr_type, tmp226)) ; if (tmp228) { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 1) ; } else { tmp229 = atspre_string_isnot_empty (ats_castfn_mac(ats_ptr_type, tmp227)) ; if (tmp229) { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 1) ; } else { tmp219 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp219)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp219, atslab_0, 0) ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: __ats_lab_57_2: tmp219 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR) ; break ; } while (0) ; return (tmp219) ; } /* end of [e1xp_eval_or_26] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 12890(line=445, offs=5) -- 13673(line=469, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_asl_27 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_int_type, tmp233) ; ATSlocal (ats_int_type, tmp234) ; // ATSlocal_void (tmp235) ; ATSlocal (ats_bool_type, tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; ATSlocal (ats_bool_type, tmp239) ; // ATSlocal_void (tmp240) ; // ATSlocal_void (tmp241) ; // ATSlocal_void (tmp242) ; ATSlocal (ats_bool_type, tmp243) ; ATSlocal (ats_int_type, tmp244) ; __ats_lab_e1xp_eval_asl_27: tmp231 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp232 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp231)->tag != 2) { goto __ats_lab_59_0 ; } __ats_lab_58_1: if (((ats_sum_ptr_type)tmp232)->tag != 2) { goto __ats_lab_59_1 ; } __ats_lab_58_2: tmp233 = ats_caselptrlab_mac(anairiats_sum_0, tmp231, atslab_0) ; tmp234 = ats_caselptrlab_mac(anairiats_sum_0, tmp232, atslab_0) ; tmp236 = atspre_ilt (ats_castfn_mac(ats_int_type, tmp234), 0) ; if (tmp236) { /* tmp237 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp239 = is_debug_0 () ; if (tmp239) { /* tmp238 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp240 = */ atspre_prerr_string (ATSstrcst(": the second argument of [<<] must be a natural number.")) ; /* tmp241 = */ atspre_prerr_newline () ; /* tmp235 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp243 = atspre_igte (ats_castfn_mac(ats_int_type, tmp234), 0) ; /* tmp242 = */ atspre_assert (tmp243) ; tmp244 = atspre_asl_int_int1 (tmp233, ats_castfn_mac(ats_int_type, tmp234)) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp230)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp230, atslab_0, tmp244) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: __ats_lab_59_1: __ats_lab_59_2: tmp230 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT) ; break ; } while (0) ; return (tmp230) ; } /* end of [e1xp_eval_asl_27] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 13741(line=472, offs=5) -- 14523(line=496, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_asr_28 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_int_type, tmp248) ; ATSlocal (ats_int_type, tmp249) ; // ATSlocal_void (tmp250) ; ATSlocal (ats_bool_type, tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; ATSlocal (ats_bool_type, tmp254) ; // ATSlocal_void (tmp255) ; // ATSlocal_void (tmp256) ; // ATSlocal_void (tmp257) ; ATSlocal (ats_bool_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; __ats_lab_e1xp_eval_asr_28: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg2) ; do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp246)->tag != 2) { goto __ats_lab_61_0 ; } __ats_lab_60_1: if (((ats_sum_ptr_type)tmp247)->tag != 2) { goto __ats_lab_61_1 ; } __ats_lab_60_2: tmp248 = ats_caselptrlab_mac(anairiats_sum_0, tmp246, atslab_0) ; tmp249 = ats_caselptrlab_mac(anairiats_sum_0, tmp247, atslab_0) ; tmp251 = atspre_ilt (ats_castfn_mac(ats_int_type, tmp249), 0) ; if (tmp251) { /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; tmp254 = is_debug_0 () ; if (tmp254) { /* tmp253 = */ atspre_prerr_string (ATSstrcst(": e1xp_eval")) ; } else { /* empty */ } /* end of [if] */ /* tmp255 = */ atspre_prerr_string (ATSstrcst(": the second argument of [<<] must be a natural number.")) ; /* tmp256 = */ atspre_prerr_newline () ; /* tmp250 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp258 = atspre_igte (ats_castfn_mac(ats_int_type, tmp249), 0) ; /* tmp257 = */ atspre_assert (tmp258) ; tmp259 = atspre_asr_int_int1 (tmp248, ats_castfn_mac(ats_int_type, tmp249)) ; tmp245 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp245)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp245, atslab_0, tmp259) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: __ats_lab_61_2: tmp245 = e1xp_eval_opr_errmsg_8 (arg0, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; break ; } while (0) ; return (tmp245) ; } /* end of [e1xp_eval_asr_28] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 14576(line=500, offs=5) -- 17959(line=565, offs=4) */ ATSstaticdec() ats_ptr_type e1xp_eval_appid_29 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_bool_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_bool_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_bool_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_bool_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_bool_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_bool_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_bool_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_bool_type, tmp297) ; ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_bool_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_bool_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_bool_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_bool_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; ATSlocal (ats_bool_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_bool_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_bool_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_bool_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_bool_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_e1xp_eval_appid_29: tmp261 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED) ; if (tmp261) { do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } tmp262 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp262 != (ats_sum_ptr_type)0) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp263 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp260 = e1xp_eval_defined_13 (arg0, tmp263) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp264 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED) ; if (tmp264) { do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_65_0 ; } tmp265 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp265 != (ats_sum_ptr_type)0) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp260 = e1xp_eval_undefined_14 (arg0, tmp266) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: __ats_lab_65_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp267 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; if (tmp267) { do { /* branch: __ats_lab_66 */ __ats_lab_66_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } tmp268 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp268 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } tmp269 = ats_caselptrlab_mac(anairiats_sum_6, tmp268, atslab_1) ; if (tmp269 != (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp270 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp271 = ats_caselptrlab_mac(anairiats_sum_6, tmp268, atslab_0) ; tmp260 = e1xp_eval_add_15 (arg0, tmp270, tmp271) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: __ats_lab_67_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp272 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; if (tmp272) { do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } tmp273 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp273 == (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } tmp274 = ats_caselptrlab_mac(anairiats_sum_6, tmp273, atslab_1) ; if (tmp274 != (ats_sum_ptr_type)0) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp275 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp276 = ats_caselptrlab_mac(anairiats_sum_6, tmp273, atslab_0) ; tmp260 = e1xp_eval_sub_16 (arg0, tmp275, tmp276) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp277 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; if (tmp277) { do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } tmp278 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp278 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } tmp279 = ats_caselptrlab_mac(anairiats_sum_6, tmp278, atslab_1) ; if (tmp279 != (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_6, tmp278, atslab_0) ; tmp260 = e1xp_eval_mul_17 (arg0, tmp280, tmp281) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: __ats_lab_71_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp282 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; if (tmp282) { do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } tmp283 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp283 == (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } tmp284 = ats_caselptrlab_mac(anairiats_sum_6, tmp283, atslab_1) ; if (tmp284 != (ats_sum_ptr_type)0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp285 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp286 = ats_caselptrlab_mac(anairiats_sum_6, tmp283, atslab_0) ; tmp260 = e1xp_eval_div_18 (arg0, tmp285, tmp286) ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: __ats_lab_73_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp287 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; if (tmp287) { do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } tmp288 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp288 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } tmp289 = ats_caselptrlab_mac(anairiats_sum_6, tmp288, atslab_1) ; if (tmp289 != (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_6, tmp288, atslab_0) ; tmp260 = e1xp_eval_lt_19 (arg0, tmp290, tmp291) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp292 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; if (tmp292) { do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } tmp293 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp293 == (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } tmp294 = ats_caselptrlab_mac(anairiats_sum_6, tmp293, atslab_1) ; if (tmp294 != (ats_sum_ptr_type)0) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp295 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp296 = ats_caselptrlab_mac(anairiats_sum_6, tmp293, atslab_0) ; tmp260 = e1xp_eval_lteq_20 (arg0, tmp295, tmp296) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: __ats_lab_77_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp297 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; if (tmp297) { do { /* branch: __ats_lab_78 */ __ats_lab_78_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } tmp298 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp298 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } tmp299 = ats_caselptrlab_mac(anairiats_sum_6, tmp298, atslab_1) ; if (tmp299 != (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp300 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_6, tmp298, atslab_0) ; tmp260 = e1xp_eval_gt_21 (arg0, tmp300, tmp301) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: __ats_lab_79_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp302 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; if (tmp302) { do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } tmp303 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp303 == (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } tmp304 = ats_caselptrlab_mac(anairiats_sum_6, tmp303, atslab_1) ; if (tmp304 != (ats_sum_ptr_type)0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp306 = ats_caselptrlab_mac(anairiats_sum_6, tmp303, atslab_0) ; tmp260 = e1xp_eval_gteq_22 (arg0, tmp305, tmp306) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp307 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; if (tmp307) { do { /* branch: __ats_lab_82 */ __ats_lab_82_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } tmp308 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp308 == (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } tmp309 = ats_caselptrlab_mac(anairiats_sum_6, tmp308, atslab_1) ; if (tmp309 != (ats_sum_ptr_type)0) { goto __ats_lab_83_0 ; } __ats_lab_82_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp311 = ats_caselptrlab_mac(anairiats_sum_6, tmp308, atslab_0) ; tmp260 = e1xp_eval_eq_23 (arg0, tmp310, tmp311) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: __ats_lab_83_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp312 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ) ; if (tmp312) { do { /* branch: __ats_lab_84 */ __ats_lab_84_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_85_0 ; } tmp313 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp313 == (ats_sum_ptr_type)0) { goto __ats_lab_85_0 ; } tmp314 = ats_caselptrlab_mac(anairiats_sum_6, tmp313, atslab_1) ; if (tmp314 != (ats_sum_ptr_type)0) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp316 = ats_caselptrlab_mac(anairiats_sum_6, tmp313, atslab_0) ; tmp260 = e1xp_eval_eq_23 (arg0, tmp315, tmp316) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: __ats_lab_85_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp317 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; if (tmp317) { do { /* branch: __ats_lab_86 */ __ats_lab_86_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_87_0 ; } tmp318 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp318 == (ats_sum_ptr_type)0) { goto __ats_lab_87_0 ; } tmp319 = ats_caselptrlab_mac(anairiats_sum_6, tmp318, atslab_1) ; if (tmp319 != (ats_sum_ptr_type)0) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp320 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp321 = ats_caselptrlab_mac(anairiats_sum_6, tmp318, atslab_0) ; tmp260 = e1xp_eval_neq_24 (arg0, tmp320, tmp321) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: __ats_lab_87_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp322 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQEQ) ; if (tmp322) { do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } tmp323 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp323 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } tmp324 = ats_caselptrlab_mac(anairiats_sum_6, tmp323, atslab_1) ; if (tmp324 != (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp325 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp326 = ats_caselptrlab_mac(anairiats_sum_6, tmp323, atslab_0) ; tmp260 = e1xp_eval_neq_24 (arg0, tmp325, tmp326) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: __ats_lab_89_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp327 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND) ; if (tmp327) { do { /* branch: __ats_lab_90 */ __ats_lab_90_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } tmp328 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp328 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } tmp329 = ats_caselptrlab_mac(anairiats_sum_6, tmp328, atslab_1) ; if (tmp329 != (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp330 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_6, tmp328, atslab_0) ; tmp260 = e1xp_eval_and_25 (arg0, tmp330, tmp331) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp332 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR) ; if (tmp332) { do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } tmp333 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp333 == (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } tmp334 = ats_caselptrlab_mac(anairiats_sum_6, tmp333, atslab_1) ; if (tmp334 != (ats_sum_ptr_type)0) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp335 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_6, tmp333, atslab_0) ; tmp260 = e1xp_eval_or_26 (arg0, tmp335, tmp336) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: __ats_lab_93_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp337 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT) ; if (tmp337) { do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } tmp338 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp338 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } tmp339 = ats_caselptrlab_mac(anairiats_sum_6, tmp338, atslab_1) ; if (tmp339 != (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp340 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp341 = ats_caselptrlab_mac(anairiats_sum_6, tmp338, atslab_0) ; tmp260 = e1xp_eval_asl_27 (arg0, tmp340, tmp341) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp342 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (arg1, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; if (tmp342) { do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } tmp343 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_1) ; if (tmp343 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } tmp344 = ats_caselptrlab_mac(anairiats_sum_6, tmp343, atslab_1) ; if (tmp344 != (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp345 = ats_caselptrlab_mac(anairiats_sum_6, arg2, atslab_0) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_6, tmp343, atslab_0) ; tmp260 = e1xp_eval_asr_28 (arg0, tmp345, tmp346) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: tmp260 = e1xp_eval_appid_errmsg_arity_6 (arg0, arg1) ; break ; } while (0) ; } else { tmp260 = e1xp_eval_appid_errmsg_opr_7 (arg0, arg1) ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return (tmp260) ; } /* end of [e1xp_eval_appid_29] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 18030(line=570, offs=11) -- 19007(line=598, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_char_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_double_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_int_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval: tmp348 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_e1xp_node) ; do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (((ats_sum_ptr_type)tmp348)->tag != 0) { goto __ats_lab_101_0 ; } __ats_lab_98_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_7, tmp348, atslab_0) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_7, tmp348, atslab_2) ; tmp351 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp349), atslab_e1xp_node) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (((ats_sum_ptr_type)tmp351)->tag != 3) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp352 = ats_caselptrlab_mac(anairiats_sum_1, tmp351, atslab_0) ; tmp353 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp349), atslab_e1xp_loc) ; tmp347 = e1xp_eval_appid_29 (tmp353, tmp352, tmp350) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: tmp354 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp349), atslab_e1xp_loc) ; tmp347 = e1xp_eval_errmsg_app_3 (tmp354) ; break ; } while (0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)tmp348)->tag != 1) { goto __ats_lab_102_0 ; } __ats_lab_101_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_3, tmp348, atslab_0) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp347)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp347, atslab_0, tmp355) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)tmp348)->tag != 2) { goto __ats_lab_103_0 ; } __ats_lab_102_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_1, tmp348, atslab_0) ; tmp357 = atspre_double_of_string (tmp356) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp347)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp347, atslab_0, tmp357) ; break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp348)->tag != 4) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp358 = ats_caselptrlab_mac(anairiats_sum_1, tmp348, atslab_0) ; tmp359 = e1xp_eval_int_10 (tmp358) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp347)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp347, atslab_0, tmp359) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp348)->tag != 3) { goto __ats_lab_107_0 ; } __ats_lab_104_1: tmp360 = ats_caselptrlab_mac(anairiats_sum_1, tmp348, atslab_0) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__the_e1xpenv_find (tmp360) ; do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (tmp361 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp362 = ats_caselptrlab_mac(anairiats_sum_5, tmp361, atslab_0) ; ATS_FREE(tmp361) ; arg0 = tmp362 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval ; // tail call break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: // if (tmp361 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_106_1: tmp363 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_e1xp_loc) ; tmp347 = e1xp_eval_errmsg_id_4 (tmp363, tmp360) ; break ; } while (0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)tmp348)->tag != 5) { goto __ats_lab_110_0 ; } __ats_lab_107_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_1, tmp348, atslab_0) ; do { /* branch: __ats_lab_108 */ __ats_lab_108_0: if (tmp364 == (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } tmp365 = ats_caselptrlab_mac(anairiats_sum_6, tmp364, atslab_1) ; if (tmp365 != (ats_sum_ptr_type)0) { goto __ats_lab_109_0 ; } __ats_lab_108_1: tmp366 = ats_caselptrlab_mac(anairiats_sum_6, tmp364, atslab_0) ; arg0 = tmp366 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval ; // tail call break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: tmp367 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_e1xp_loc) ; tmp347 = e1xp_eval_errmsg_list_5 (tmp367) ; break ; } while (0) ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp348)->tag != 9) { goto __ats_lab_111_0 ; } __ats_lab_110_1: tmp347 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ((ats_sum_ptr_type)tmp347)->tag = 2 ; ats_selptrset_mac(anairiats_sum_0, tmp347, atslab_0, 0) ; break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp348)->tag != 6) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp368 = ats_caselptrlab_mac(anairiats_sum_8, tmp348, atslab_0) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp347)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp347, atslab_0, tmp368) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp348)->tag != 7) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp369 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_e1xp_loc) ; tmp347 = e1xp_eval_errmsg_undef_9 (tmp369) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (((ats_sum_ptr_type)tmp348)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_1, tmp348, atslab_0) ; tmp371 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_e1xp_loc) ; tmp347 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp347)->tag = 4 ; ats_selptrset_mac(anairiats_sum_9, tmp347, atslab_0, tmp371) ; ats_selptrset_mac(anairiats_sum_9, tmp347, atslab_1, tmp370) ; break ; } while (0) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 19075(line=603, offs=14) -- 19275(line=607, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp372 = ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval (arg1) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_116_0 ; } __ats_lab_115_1: tmp373 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_e1xp_loc) ; tmp372 = e1xp_eval_defined_13 (tmp373, arg1) ; break ; /* branch: __ats_lab_116 */ __ats_lab_116_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_116_1: tmp374 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg1), atslab_e1xp_loc) ; tmp372 = e1xp_eval_undefined_14 (tmp374, arg1) ; break ; } while (0) ; return (tmp372) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_eval_if] */ /* // /home/hwxi/research/Anairiats/src/ats_e1xp_eval.dats: 19348(line=612, offs=16) -- 19798(line=622, offs=55) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_make_v1al (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_char_type, tmp376) ; ATSlocal (ats_double_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_int_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_int_type, tmp382) ; ATSlocal (ats_size_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_make_v1al: do { /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_char (arg0, tmp376) ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp377 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_0) ; tmp378 = atspre_tostrptr_double (tmp377) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_float (arg0, tmp378) ; break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp379 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp380 = atspre_tostrptr_int (tmp379) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_int (arg0, tmp380) ; break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp381 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp383 = atspre_string_length (tmp381) ; tmp382 = atspre_int_of_size (tmp383) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_string (arg0, tmp381, tmp382) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (((ats_sum_ptr_type)arg1)->tag != 4) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: tmp384 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_1) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__e1xp_cstsp (arg0, tmp384) ; break ; } while (0) ; return (tmp375) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__e1xp_make_v1al] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans1_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_e1xp_eval_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_e1xp_eval_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_counter_sats.c0000664000175000017500000000203412223166160021614 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "ats_counter.cats" /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_counter_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_sats.c0000664000175000017500000001376012223166160022227 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDpattern_match_exhaustiveness_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDloop_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPObind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOeqeq_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRitmlst_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_ref_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMdisj_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMhypo_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsvar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsVar_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPlam_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop0_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop1_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPnone_3) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDpattern_match_exhaustiveness_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDloop_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOprop_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPObind_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOeqeq_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRprop_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRitmlst_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_ref_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMdisj_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMhypo_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsvar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsVar_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPlam_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop0_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop1_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPnone_3.tag = 3 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp1_dats.c0000664000175000017500000052507312223166160021523 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_i1nvresstate_qua ; ats_ptr_type atslab_i1nvresstate_arg ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_p1at_loc ; ats_ptr_type atslab_p1at_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_12 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_17 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_18 ; typedef struct { ats_ptr_type atslab_d1lab_loc ; ats_ptr_type atslab_d1lab_node ; } anairiats_rec_19 ; typedef struct { ats_ptr_type atslab_m1atch_loc ; ats_ptr_type atslab_m1atch_exp ; ats_ptr_type atslab_m1atch_pat ; } anairiats_rec_20 ; typedef struct { ats_ptr_type atslab_c1lau_loc ; ats_ptr_type atslab_c1lau_pat ; ats_ptr_type atslab_c1lau_gua ; ats_int_type atslab_c1lau_seq ; ats_int_type atslab_c1lau_neg ; ats_ptr_type atslab_c1lau_exp ; } anairiats_rec_21 ; typedef struct { ats_ptr_type atslab_sc1lau_loc ; ats_ptr_type atslab_sc1lau_pat ; ats_ptr_type atslab_sc1lau_exp ; } anairiats_rec_22 ; typedef struct { ats_ptr_type atslab_i1nvarg_loc ; ats_ptr_type atslab_i1nvarg_sym ; ats_ptr_type atslab_i1nvarg_typ ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_loopi1nv_loc ; ats_ptr_type atslab_loopi1nv_qua ; ats_ptr_type atslab_loopi1nv_met ; ats_ptr_type atslab_loopi1nv_arg ; ats_ptr_type atslab_loopi1nv_res ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_d1ec_loc ; ats_ptr_type atslab_d1ec_node ; } anairiats_rec_25 ; typedef struct { ats_ptr_type atslab_d1atsrtcon_loc ; ats_ptr_type atslab_d1atsrtcon_sym ; ats_ptr_type atslab_d1atsrtcon_arg ; } anairiats_rec_26 ; typedef struct { ats_ptr_type atslab_d1atsrtdec_loc ; ats_ptr_type atslab_d1atsrtdec_sym ; ats_ptr_type atslab_d1atsrtdec_con ; } anairiats_rec_27 ; typedef struct { ats_ptr_type atslab_s1rtdef_loc ; ats_ptr_type atslab_s1rtdef_sym ; ats_ptr_type atslab_s1rtdef_def ; } anairiats_rec_28 ; typedef struct { ats_ptr_type atslab_s1tacon_fil ; ats_ptr_type atslab_s1tacon_loc ; ats_ptr_type atslab_s1tacon_sym ; ats_ptr_type atslab_s1tacon_arg ; ats_ptr_type atslab_s1tacon_def ; } anairiats_rec_29 ; typedef struct { ats_ptr_type atslab_s1tacst_fil ; ats_ptr_type atslab_s1tacst_loc ; ats_ptr_type atslab_s1tacst_sym ; ats_ptr_type atslab_s1tacst_arg ; ats_ptr_type atslab_s1tacst_res ; } anairiats_rec_30 ; typedef struct { ats_ptr_type atslab_s1tavar_loc ; ats_ptr_type atslab_s1tavar_sym ; ats_ptr_type atslab_s1tavar_srt ; } anairiats_rec_31 ; typedef struct { ats_ptr_type atslab_s1expdef_loc ; ats_ptr_type atslab_s1expdef_sym ; ats_ptr_type atslab_s1expdef_arg ; ats_ptr_type atslab_s1expdef_res ; ats_ptr_type atslab_s1expdef_def ; } anairiats_rec_32 ; typedef struct { ats_ptr_type atslab_s1aspdec_fil ; ats_ptr_type atslab_s1aspdec_loc ; ats_ptr_type atslab_s1aspdec_qid ; ats_ptr_type atslab_s1aspdec_arg ; ats_ptr_type atslab_s1aspdec_res ; ats_ptr_type atslab_s1aspdec_def ; } anairiats_rec_33 ; typedef struct { ats_ptr_type atslab_d1cstdec_fil ; ats_ptr_type atslab_d1cstdec_loc ; ats_ptr_type atslab_d1cstdec_sym ; ats_ptr_type atslab_d1cstdec_typ ; ats_ptr_type atslab_d1cstdec_extdef ; } anairiats_rec_34 ; typedef struct { ats_ptr_type atslab_d1atcon_loc ; ats_ptr_type atslab_d1atcon_sym ; ats_ptr_type atslab_d1atcon_qua ; ats_int_type atslab_d1atcon_npf ; ats_ptr_type atslab_d1atcon_arg ; ats_ptr_type atslab_d1atcon_ind ; } anairiats_rec_35 ; typedef struct { ats_ptr_type atslab_d1atdec_fil ; ats_ptr_type atslab_d1atdec_loc ; ats_ptr_type atslab_d1atdec_sym ; ats_ptr_type atslab_d1atdec_arg ; ats_ptr_type atslab_d1atdec_con ; } anairiats_rec_36 ; typedef struct { ats_ptr_type atslab_e1xndec_fil ; ats_ptr_type atslab_e1xndec_loc ; ats_ptr_type atslab_e1xndec_sym ; ats_ptr_type atslab_e1xndec_qua ; ats_int_type atslab_e1xndec_npf ; ats_ptr_type atslab_e1xndec_arg ; } anairiats_rec_37 ; typedef struct { ats_ptr_type atslab_v1aldec_loc ; ats_ptr_type atslab_v1aldec_pat ; ats_ptr_type atslab_v1aldec_def ; ats_ptr_type atslab_v1aldec_ann ; } anairiats_rec_38 ; typedef struct { ats_ptr_type atslab_f1undec_loc ; ats_ptr_type atslab_f1undec_sym ; ats_ptr_type atslab_f1undec_sym_loc ; ats_ptr_type atslab_f1undec_def ; ats_ptr_type atslab_f1undec_ann ; } anairiats_rec_39 ; typedef struct { ats_ptr_type atslab_v1ardec_loc ; ats_int_type atslab_v1ardec_knd ; ats_ptr_type atslab_v1ardec_sym ; ats_ptr_type atslab_v1ardec_sym_loc ; ats_ptr_type atslab_v1ardec_typ ; ats_ptr_type atslab_v1ardec_wth ; ats_ptr_type atslab_v1ardec_ini ; } anairiats_rec_40 ; typedef struct { ats_ptr_type atslab_m1acdef_loc ; ats_ptr_type atslab_m1acdef_sym ; ats_ptr_type atslab_m1acdef_arg ; ats_ptr_type atslab_m1acdef_def ; } anairiats_rec_41 ; typedef struct { ats_ptr_type atslab_i1mpdec_loc ; ats_ptr_type atslab_i1mpdec_qid ; ats_ptr_type atslab_i1mpdec_tmparg ; ats_ptr_type atslab_i1mpdec_def ; } anairiats_rec_42 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tas_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tchar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Texist_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfloat_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfree_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tint_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlst_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tqid_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trec_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tref_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trefas_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tstring_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Ttup_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrinit_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrpsz_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrsub_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecrypt_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eexist_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eextval_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efix_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloat_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloatsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efoldat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efor_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efreeat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eif_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eint_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eintsp_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elet_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eloopexn_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elst_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Emacsyn_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eptrof_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eraise_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Erec_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Escaseof_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esel_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estruct_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etmpid_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etrywith_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etup_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eviewat_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhere_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhile_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cnone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cinclude_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymintr_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csymelim_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ce1xpdef_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatsrts_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csrtdefs_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacons_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstacsts_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstavars_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csexpdefs_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Csaspdec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdcstdecs_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdatdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cexndecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cclassdec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Coverload_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextype_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextval_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cextcode_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_par_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvaldecs_rec_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cfundecs_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cvardecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cmacdefs_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cimpdec_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Clocal_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cdynload_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cstaload_30) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, d0ynq_none) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any2) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char) (ats_ptr_type, ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf) (ats_ptr_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil) ; /* internal function declarations */ static ats_ptr_type aux_ifany_14 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type prerr_loc_error1_25 (ats_ptr_type arg0) ; static ats_ptr_type aux_27 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_27_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_27_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type auxlst_28 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type auxlst_28_closure_make (ats_ptr_type env0) ; static ats_ptr_type auxlst_28_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_bool_type auxsin_68 (ats_ptr_type arg0) ; static ats_ptr_type aux_96 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_96_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_96_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type auxlst_97 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type auxlst_97_closure_make (ats_ptr_type env0) ; static ats_ptr_type auxlst_97_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp262) ; ATSstatic (ats_ptr_type, statmp263) ; ATSstatic (ats_ptr_type, statmp264) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2084(line=69, offs=10) -- 2152(line=71, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ann (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ann: tmp2 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp2)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp2, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp2, atslab_1, arg2) ; tmp1 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp1, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp1, atslab_p1at_node, tmp2) ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ann] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2173(line=74, offs=10) -- 2223(line=76, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any: tmp4 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1) ; tmp3 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp3, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp3, atslab_p1at_node, tmp4) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2244(line=78, offs=11) -- 2295(line=80, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any2 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any2: tmp6 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2) ; tmp5 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp5, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp5, atslab_p1at_node, tmp6) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2322(line=84, offs=3) -- 2424(line=86, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn: tmp8 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp8)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp8, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp8, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp8, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp8, atslab_3, arg4) ; tmp7 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp7, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp7, atslab_p1at_node, tmp8) ; return (tmp7) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2449(line=88, offs=24) -- 2523(line=90, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta: tmp10 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp10)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp10, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp10, atslab_1, arg2) ; tmp9 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp9, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp9, atslab_p1at_node, tmp10) ; return (tmp9) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2543(line=92, offs=19) -- 2608(line=94, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_as (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_as: tmp12 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp12)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp12, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp12, atslab_1, arg2) ; tmp11 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp11, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp11, atslab_p1at_node, tmp12) ; return (tmp11) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_as] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2630(line=96, offs=21) -- 2683(line=98, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char: tmp14 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp14)->tag = 6 ; ats_selptrset_mac(anairiats_sum_4, tmp14, atslab_0, arg1) ; tmp13 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp13, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp13, atslab_p1at_node, tmp14) ; return (tmp13) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2706(line=100, offs=22) -- 2758(line=102, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_empty: tmp16 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7) ; tmp15 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp15, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp15, atslab_p1at_node, tmp16) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2781(line=104, offs=22) -- 2853(line=106, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_exist: tmp18 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp18)->tag = 8 ; ats_selptrset_mac(anairiats_sum_2, tmp18, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp18, atslab_1, arg2) ; tmp17 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp17, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp17, atslab_p1at_node, tmp18) ; return (tmp17) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2876(line=108, offs=22) -- 2936(line=110, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float: tmp20 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp20)->tag = 9 ; ats_selptrset_mac(anairiats_sum_5, tmp20, atslab_0, arg1) ; tmp19 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp19, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp19, atslab_p1at_node, tmp20) ; return (tmp19) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 2958(line=112, offs=21) -- 3015(line=114, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_free (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_free: tmp22 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp22)->tag = 10 ; ats_selptrset_mac(anairiats_sum_5, tmp22, atslab_0, arg1) ; tmp21 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp21, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp21, atslab_p1at_node, tmp22) ; return (tmp21) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_free] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3036(line=116, offs=20) -- 3104(line=118, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide: tmp24 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp24)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp24, atslab_0, statmp0) ; ats_selptrset_mac(anairiats_sum_2, tmp24, atslab_1, arg1) ; tmp23 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp23, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp23, atslab_p1at_node, tmp24) ; return (tmp23) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3125(line=120, offs=20) -- 3183(line=122, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int: tmp26 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp26)->tag = 11 ; ats_selptrset_mac(anairiats_sum_5, tmp26, atslab_0, arg1) ; tmp25 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp25, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp25, atslab_p1at_node, tmp26) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3253(line=130, offs=5) -- 3452(line=141, offs=4) */ ATSstaticdec() ats_ptr_type aux_ifany_14 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_aux_ifany_14: tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_p1at_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp29)->tag != 1) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp28 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_any2 (arg0) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp30 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg1), atslab_p1at_node) ; tmp28 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp28, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp28, atslab_p1at_node, tmp30) ; break ; } while (0) ; return (tmp28) ; } /* end of [aux_ifany_14] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3228(line=128, offs=3) -- 3647(line=153, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } tmp31 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; if (tmp31 != (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp27 = aux_ifany_14 (arg0, tmp32) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: tmp33 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp33)->tag = 12 ; ats_selptrset_mac(anairiats_sum_7, tmp33, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_7, tmp33, atslab_1, arg1) ; tmp27 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp27, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp27, atslab_p1at_node, tmp33) ; break ; } while (0) ; return (tmp27) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3694(line=157, offs=3) -- 3859(line=162, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list2: tmp35 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg1, arg2) ; tmp37 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp37)->tag = 12 ; ats_selptrset_mac(anairiats_sum_7, tmp37, atslab_0, tmp35) ; ats_selptrset_mac(anairiats_sum_7, tmp37, atslab_1, tmp36) ; tmp34 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp34, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp34, atslab_p1at_node, tmp37) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 3924(line=166, offs=20) -- 3984(line=168, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_lst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_lst: tmp39 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp39)->tag = 13 ; ats_selptrset_mac(anairiats_sum_5, tmp39, atslab_0, arg1) ; tmp38 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp38, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp38, atslab_p1at_node, tmp39) ; return (tmp38) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4005(line=170, offs=20) -- 4071(line=172, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid: tmp41 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp41)->tag = 14 ; ats_selptrset_mac(anairiats_sum_2, tmp41, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp41, atslab_1, arg2) ; tmp40 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp40, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp40, atslab_p1at_node, tmp41) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4092(line=174, offs=20) -- 4170(line=176, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_rec (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_rec: tmp43 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp43)->tag = 15 ; ats_selptrset_mac(anairiats_sum_7, tmp43, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp43, atslab_1, arg2) ; tmp42 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp42, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp42, atslab_p1at_node, tmp43) ; return (tmp42) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4191(line=178, offs=20) -- 4247(line=180, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ref (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ref: tmp45 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp45)->tag = 16 ; ats_selptrset_mac(anairiats_sum_5, tmp45, atslab_0, arg1) ; tmp44 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp44, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp44, atslab_p1at_node, tmp45) ; return (tmp44) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4270(line=182, offs=22) -- 4338(line=184, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_refas (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_refas: tmp47 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp47)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp47, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp47, atslab_1, arg2) ; tmp46 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp46, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp46, atslab_p1at_node, tmp47) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_refas] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4362(line=186, offs=23) -- 4421(line=188, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string: tmp49 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp49)->tag = 18 ; ats_selptrset_mac(anairiats_sum_5, tmp49, atslab_0, arg1) ; tmp48 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp48, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp48, atslab_p1at_node, tmp49) ; return (tmp48) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4446(line=190, offs=24) -- 4510(line=192, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_svararg (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_svararg: tmp51 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp51)->tag = 19 ; ats_selptrset_mac(anairiats_sum_5, tmp51, atslab_0, arg1) ; tmp50 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp50, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp50, atslab_p1at_node, tmp51) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_svararg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4531(line=194, offs=20) -- 4610(line=196, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup: tmp53 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp53)->tag = 20 ; ats_selptrset_mac(anairiats_sum_8, tmp53, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp53, atslab_1, 0) ; ats_selptrset_mac(anairiats_sum_8, tmp53, atslab_2, arg2) ; tmp52 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp52, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp52, atslab_p1at_node, tmp53) ; return (tmp52) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4634(line=199, offs=3) -- 4814(line=204, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup2 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_int_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup2: tmp55 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp56 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg2, arg3) ; tmp57 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp57)->tag = 20 ; ats_selptrset_mac(anairiats_sum_8, tmp57, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp57, atslab_1, tmp55) ; ats_selptrset_mac(anairiats_sum_8, tmp57, atslab_2, tmp56) ; tmp54 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp54, atslab_p1at_loc, arg0) ; ats_selptrset_mac(anairiats_rec_1, tmp54, atslab_p1at_node, tmp57) ; return (tmp54) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_tup2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 4862(line=208, offs=4) -- 4949(line=210, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error1_25 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; __ats_lab_prerr_loc_error1_25: /* tmp59 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp58 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; return /* (tmp58) */ ; } /* end of [prerr_loc_error1_25] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 5030(line=216, offs=7) -- 5900(line=236, offs=10) */ ATSstaticdec() ats_ptr_type aux_27 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_char_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; __ats_lab_aux_27: tmp62 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_e1xp_node) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp62)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_0) ; tmp64 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_1) ; tmp65 = ats_caselptrlab_mac(anairiats_sum_10, tmp62, atslab_2) ; tmp66 = aux_27 (env0, tmp63) ; tmp67 = auxlst_28 (env0, tmp65) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_app_dyn (env0, tmp66, tmp64, 0, tmp67) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp62)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_4, tmp62, atslab_0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_char (env0, tmp68) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp62)->tag != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_float (env0, tmp69) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp62)->tag != 3) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_qid (env0, statmp0, tmp70) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp62)->tag != 4) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_int (env0, tmp71) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp62)->tag != 5) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_5, tmp62, atslab_0) ; tmp73 = auxlst_28 (env0, tmp72) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_list (env0, tmp73) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp62)->tag != 9) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_empty (env0) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp62)->tag != 6) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_11, tmp62, atslab_0) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_string (env0, tmp74) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp62)->tag != 7) { goto __ats_lab_13_0 ; } __ats_lab_12_1: /* tmp75 = */ prerr_loc_error1_25 (env0) ; /* tmp76 = */ atspre_prerr_string (ATSstrcst(": incorrect use of undefined value.")) ; /* tmp77 = */ atspre_prerr_newline () ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)tmp62)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: /* tmp78 = */ prerr_loc_error1_25 (env0) ; /* tmp79 = */ atspre_prerr_string (ATSstrcst(": incorrect use of a special constant.")) ; /* tmp80 = */ atspre_prerr_newline () ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp61) ; } /* end of [aux_27] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_27_closure_type ; ats_ptr_type aux_27_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_27 (((aux_27_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_27_closure_init (aux_27_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_27_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_27_closure_make (ats_ptr_type env0) { aux_27_closure_type *p_clo = ATS_MALLOC(sizeof(aux_27_closure_type)) ; aux_27_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 5950(line=239, offs=7) -- 6073(line=241, offs=65) */ ATSstaticdec() ats_ptr_type auxlst_28 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; __ats_lab_auxlst_28: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp82 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp83 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp84 = aux_27 (env0, tmp82) ; tmp85 = auxlst_28 (env0, tmp83) ; tmp81 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp81, atslab_0, tmp84) ; ats_selptrset_mac(anairiats_sum_6, tmp81, atslab_1, tmp85) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp81 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp81) ; } /* end of [auxlst_28] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } auxlst_28_closure_type ; ats_ptr_type auxlst_28_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return auxlst_28 (((auxlst_28_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type auxlst_28_closure_init (auxlst_28_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_28_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_28_closure_make (ats_ptr_type env0) { auxlst_28_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_28_closure_type)) ; auxlst_28_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 5005(line=214, offs=16) -- 6112(line=245, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp60) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp: tmp60 = aux_27 (arg0, arg1) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__p1at_make_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6187(line=250, offs=16) -- 6262(line=252, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_effc (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_effc: tmp87 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp87)->tag = 0 ; ats_selptrset_mac(anairiats_sum_2, tmp87, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp87, atslab_1, arg2) ; tmp86 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp86, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp86, atslab_d1exp_node, tmp87) ; return (tmp86) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_effc] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6291(line=255, offs=18) -- 6366(line=257, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo: tmp89 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp89)->tag = 1 ; ats_selptrset_mac(anairiats_sum_2, tmp89, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp89, atslab_1, arg2) ; tmp88 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp88, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp88, atslab_d1exp_node, tmp89) ; return (tmp88) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6399(line=260, offs=22) -- 6517(line=263, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo_opt (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo_opt: tmp91 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp91)->tag != 1) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp90 = arg1 ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp90 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo (arg0, arg1, arg2) ; break ; } while (0) ; return (tmp90) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_funclo_opt] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6577(line=266, offs=16) -- 6652(line=268, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type: tmp93 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp93)->tag = 2 ; ats_selptrset_mac(anairiats_sum_2, tmp93, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp93, atslab_1, arg2) ; tmp92 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp92, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp92, atslab_d1exp_node, tmp93) ; return (tmp92) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ann_type] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6701(line=274, offs=3) -- 6805(line=276, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn: tmp95 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp95)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp95, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp95, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp95, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp95, atslab_3, arg4) ; tmp94 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp94, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp94, atslab_d1exp_node, tmp95) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 6857(line=279, offs=15) -- 6933(line=281, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta: tmp97 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp97)->tag = 4 ; ats_selptrset_mac(anairiats_sum_2, tmp97, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp97, atslab_1, arg2) ; tmp96 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp96, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp96, atslab_d1exp_node, tmp97) ; return (tmp96) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7006(line=286, offs=15) -- 7110(line=288, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrinit (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrinit: tmp99 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp99)->tag = 5 ; ats_selptrset_mac(anairiats_sum_10, tmp99, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp99, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp99, atslab_2, arg3) ; tmp98 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp98, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp98, atslab_d1exp_node, tmp99) ; return (tmp98) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrinit] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7135(line=291, offs=14) -- 7228(line=293, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrpsz (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrpsz: tmp101 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp101)->tag = 6 ; ats_selptrset_mac(anairiats_sum_2, tmp101, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp101, atslab_1, arg2) ; tmp100 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp100, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp100, atslab_d1exp_node, tmp101) ; return (tmp100) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrpsz] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7253(line=296, offs=14) -- 7364(line=298, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrsub (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrsub: tmp103 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp103)->tag = 7 ; ats_selptrset_mac(anairiats_sum_10, tmp103, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp103, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp103, atslab_2, arg3) ; tmp102 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp102, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp102, atslab_d1exp_node, tmp103) ; return (tmp102) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_arrsub] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7408(line=303, offs=12) -- 7467(line=305, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_bool (ats_ptr_type arg0, ats_bool_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_bool: tmp105 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp105)->tag = 8 ; ats_selptrset_mac(anairiats_sum_13, tmp105, atslab_0, arg1) ; tmp104 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp104, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp104, atslab_d1exp_node, tmp105) ; return (tmp104) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7538(line=310, offs=3) -- 7665(line=315, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_caseof (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_caseof: tmp107 = ATS_MALLOC(sizeof(anairiats_sum_14)) ; ((ats_sum_ptr_type)tmp107)->tag = 9 ; ats_selptrset_mac(anairiats_sum_14, tmp107, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_14, tmp107, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_14, tmp107, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_14, tmp107, atslab_3, arg4) ; tmp106 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp106, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp106, atslab_d1exp_node, tmp107) ; return (tmp106) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_caseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7713(line=317, offs=22) -- 7772(line=319, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char (ats_ptr_type arg0, ats_char_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char: tmp109 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp109)->tag = 10 ; ats_selptrset_mac(anairiats_sum_4, tmp109, atslab_0, arg1) ; tmp108 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp108, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp108, atslab_d1exp_node, tmp109) ; return (tmp108) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7796(line=321, offs=23) -- 7856(line=323, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp: tmp111 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp111)->tag = 11 ; ats_selptrset_mac(anairiats_sum_5, tmp111, atslab_0, arg1) ; tmp110 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp110, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp110, atslab_d1exp_node, tmp111) ; return (tmp110) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7880(line=325, offs=23) -- 7952(line=327, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_crypt (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_crypt: tmp113 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp113)->tag = 12 ; ats_selptrset_mac(anairiats_sum_7, tmp113, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp113, atslab_1, arg2) ; tmp112 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp112, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp112, atslab_d1exp_node, tmp113) ; return (tmp112) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_crypt] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 7977(line=330, offs=14) -- 8042(line=332, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_decseq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_decseq: tmp115 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp115)->tag = 13 ; ats_selptrset_mac(anairiats_sum_5, tmp115, atslab_0, arg1) ; tmp114 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp114, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp114, atslab_d1exp_node, tmp115) ; return (tmp114) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_decseq] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8093(line=335, offs=15) -- 8157(line=337, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_dynload: tmp117 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp117)->tag = 14 ; ats_selptrset_mac(anairiats_sum_5, tmp117, atslab_0, arg1) ; tmp116 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp116, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp116, atslab_d1exp_node, tmp117) ; return (tmp116) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8183(line=340, offs=15) -- 8258(line=342, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_effmask (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_effmask: tmp119 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp119)->tag = 15 ; ats_selptrset_mac(anairiats_sum_2, tmp119, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp119, atslab_1, arg2) ; tmp118 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp118, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp118, atslab_d1exp_node, tmp119) ; return (tmp118) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_effmask] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8282(line=345, offs=13) -- 8336(line=347, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty: tmp121 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16) ; tmp120 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp120, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp120, atslab_d1exp_node, tmp121) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8360(line=350, offs=13) -- 8432(line=352, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_exist (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_exist: tmp123 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp123)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp123, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp123, atslab_1, arg2) ; tmp122 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp122, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp122, atslab_d1exp_node, tmp123) ; return (tmp122) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_exist] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8457(line=354, offs=24) -- 8533(line=356, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_extval: tmp125 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp125)->tag = 18 ; ats_selptrset_mac(anairiats_sum_2, tmp125, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp125, atslab_1, arg2) ; tmp124 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp124, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp124, atslab_d1exp_node, tmp125) ; return (tmp124) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8557(line=358, offs=23) -- 8617(line=360, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float: tmp127 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp127)->tag = 20 ; ats_selptrset_mac(anairiats_sum_5, tmp127, atslab_0, arg1) ; tmp126 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp126, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp126, atslab_d1exp_node, tmp127) ; return (tmp126) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8643(line=362, offs=25) -- 8705(line=364, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_floatsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_floatsp: tmp129 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp129)->tag = 21 ; ats_selptrset_mac(anairiats_sum_5, tmp129, atslab_0, arg1) ; tmp128 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp128, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp128, atslab_d1exp_node, tmp129) ; return (tmp128) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_floatsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8727(line=366, offs=21) -- 8805(line=368, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_fix (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_fix: tmp131 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp131)->tag = 19 ; ats_selptrset_mac(anairiats_sum_15, tmp131, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp131, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp131, atslab_2, arg3) ; tmp130 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp130, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp130, atslab_d1exp_node, tmp131) ; return (tmp130) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_fix] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8830(line=370, offs=24) -- 8905(line=372, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_foldat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_foldat: tmp133 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp133)->tag = 22 ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp133, atslab_1, arg2) ; tmp132 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp132, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp132, atslab_d1exp_node, tmp133) ; return (tmp132) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_foldat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 8929(line=375, offs=3) -- 9035(line=377, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_for (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_for: tmp135 = ATS_MALLOC(sizeof(anairiats_sum_16)) ; ((ats_sum_ptr_type)tmp135)->tag = 23 ; ats_selptrset_mac(anairiats_sum_16, tmp135, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_16, tmp135, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_16, tmp135, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_16, tmp135, atslab_3, arg4) ; ats_selptrset_mac(anairiats_sum_16, tmp135, atslab_4, arg5) ; tmp134 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp134, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp134, atslab_d1exp_node, tmp135) ; return (tmp134) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_for] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9082(line=379, offs=24) -- 9157(line=381, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_freeat (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_freeat: tmp137 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp137)->tag = 24 ; ats_selptrset_mac(anairiats_sum_2, tmp137, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp137, atslab_1, arg2) ; tmp136 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp136, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp136, atslab_d1exp_node, tmp137) ; return (tmp136) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_freeat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9200(line=386, offs=11) -- 9270(line=388, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide: tmp139 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp139)->tag = 41 ; ats_selptrset_mac(anairiats_sum_2, tmp139, atslab_0, statmp0) ; ats_selptrset_mac(anairiats_sum_2, tmp139, atslab_1, arg1) ; tmp138 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp138, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp138, atslab_d1exp_node, tmp139) ; return (tmp138) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ide] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9321(line=392, offs=3) -- 9418(line=394, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp: tmp141 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp141)->tag = 25 ; ats_selptrset_mac(anairiats_sum_10, tmp141, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp141, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp141, atslab_2, arg3) ; tmp140 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp140, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp140, atslab_d1exp_node, tmp141) ; return (tmp140) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_idextapp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9487(line=398, offs=20) -- 9626(line=404, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if: tmp143 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ((ats_sum_ptr_type)tmp143)->tag = 26 ; ats_selptrset_mac(anairiats_sum_17, tmp143, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_17, tmp143, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_17, tmp143, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_17, tmp143, atslab_3, arg4) ; tmp142 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp142, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp142, atslab_d1exp_node, tmp143) ; return (tmp142) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_if] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9690(line=409, offs=11) -- 9750(line=411, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int: tmp145 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp145)->tag = 27 ; ats_selptrset_mac(anairiats_sum_5, tmp145, atslab_0, arg1) ; tmp144 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp144, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp144, atslab_d1exp_node, tmp145) ; return (tmp144) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9774(line=414, offs=13) -- 9836(line=416, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_intsp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_intsp: tmp147 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp147)->tag = 28 ; ats_selptrset_mac(anairiats_sum_5, tmp147, atslab_0, arg1) ; tmp146 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp146, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp146, atslab_d1exp_node, tmp147) ; return (tmp146) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_intsp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 9883(line=421, offs=15) -- 9967(line=423, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn: tmp149 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp149)->tag = 29 ; ats_selptrset_mac(anairiats_sum_15, tmp149, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp149, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp149, atslab_2, arg3) ; tmp148 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp148, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp148, atslab_d1exp_node, tmp149) ; return (tmp148) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10023(line=426, offs=19) -- 10111(line=428, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_laminit_dyn (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_laminit_dyn: tmp151 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp151)->tag = 30 ; ats_selptrset_mac(anairiats_sum_15, tmp151, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp151, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp151, atslab_2, arg3) ; tmp150 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp150, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp150, atslab_d1exp_node, tmp151) ; return (tmp150) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_laminit_dyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10188(line=433, offs=15) -- 10282(line=435, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_met (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_met: tmp153 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp153)->tag = 31 ; ats_selptrset_mac(anairiats_sum_10, tmp153, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp153, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp153, atslab_2, arg3) ; tmp152 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp152, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp152, atslab_d1exp_node, tmp153) ; return (tmp152) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_met] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10312(line=438, offs=19) -- 10410(line=440, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_ana (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_ana: tmp155 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp155)->tag = 32 ; ats_selptrset_mac(anairiats_sum_10, tmp155, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp155, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp155, atslab_2, arg3) ; tmp154 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp154, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp154, atslab_d1exp_node, tmp155) ; return (tmp154) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_ana] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10440(line=443, offs=19) -- 10538(line=445, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_syn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_syn: tmp157 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp157)->tag = 33 ; ats_selptrset_mac(anairiats_sum_10, tmp157, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp157, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp157, atslab_2, arg3) ; tmp156 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp156, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp156, atslab_d1exp_node, tmp157) ; return (tmp156) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lam_sta_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10588(line=450, offs=18) -- 10665(line=452, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lazy_delay (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lazy_delay: tmp159 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp159)->tag = 34 ; ats_selptrset_mac(anairiats_sum_7, tmp159, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp159, atslab_1, arg2) ; tmp158 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp158, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp158, atslab_d1exp_node, tmp159) ; return (tmp158) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lazy_delay] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10687(line=454, offs=21) -- 10759(line=456, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_let (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_let: tmp161 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp161)->tag = 35 ; ats_selptrset_mac(anairiats_sum_2, tmp161, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp161, atslab_1, arg2) ; tmp160 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp160, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp160, atslab_d1exp_node, tmp161) ; return (tmp160) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_let] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10830(line=464, offs=5) -- 11052(line=478, offs=4) */ ATSstaticdec() ats_bool_type auxsin_68 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_auxsin_68: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } tmp164 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; if (tmp164 != (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_18_1: tmp165 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp166 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, tmp165), atslab_d1exp_node) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp166)->tag != 36) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp167 = ats_caselptrlab_mac(anairiats_sum_7, tmp166, atslab_1) ; arg0 = tmp167 ; goto __ats_lab_auxsin_68 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp163 = ats_true_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp163 = ats_false_bool ; break ; } while (0) ; return (tmp163) ; } /* end of [auxsin_68] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 10805(line=462, offs=3) -- 11244(line=489, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_bool_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list: tmp168 = auxsin_68 (arg1) ; if (tmp168) { if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11131(line=485, offs=7) -- 11156(line=485, offs=32)") ; } tmp169 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp162 = tmp169 ; } else { tmp170 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp170)->tag = 36 ; ats_selptrset_mac(anairiats_sum_7, tmp170, atslab_0, 0) ; ats_selptrset_mac(anairiats_sum_7, tmp170, atslab_1, arg1) ; tmp162 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp162, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp162, atslab_d1exp_node, tmp170) ; } /* end of [if] */ return (tmp162) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11293(line=493, offs=3) -- 11460(line=498, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_int_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list2: tmp172 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg1) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg1, arg2) ; tmp174 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp174)->tag = 36 ; ats_selptrset_mac(anairiats_sum_7, tmp174, atslab_0, tmp172) ; ats_selptrset_mac(anairiats_sum_7, tmp174, atslab_1, tmp173) ; tmp171 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp171, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp171, atslab_d1exp_node, tmp174) ; return (tmp171) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11531(line=503, offs=15) -- 11591(line=505, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn: tmp176 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_sum_ptr_type)tmp176)->tag = 37 ; ats_selptrset_mac(anairiats_sum_18, tmp176, atslab_0, arg1) ; tmp175 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp175, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp175, atslab_d1exp_node, tmp176) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_loopexn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11660(line=510, offs=11) -- 11744(line=512, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lst (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lst: tmp178 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp178)->tag = 38 ; ats_selptrset_mac(anairiats_sum_15, tmp178, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp178, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp178, atslab_2, arg3) ; tmp177 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp177, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp177, atslab_d1exp_node, tmp178) ; return (tmp177) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_lst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11791(line=515, offs=14) -- 11864(line=517, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_macsyn (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_macsyn: tmp180 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp180)->tag = 39 ; ats_selptrset_mac(anairiats_sum_2, tmp180, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp180, atslab_1, arg2) ; tmp179 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp179, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp179, atslab_d1exp_node, tmp180) ; return (tmp179) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_macsyn] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 11913(line=520, offs=13) -- 11973(line=522, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ptrof (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ptrof: tmp182 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp182)->tag = 40 ; ats_selptrset_mac(anairiats_sum_5, tmp182, atslab_0, arg1) ; tmp181 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp181, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp181, atslab_d1exp_node, tmp182) ; return (tmp181) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_ptrof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12019(line=525, offs=11) -- 12083(line=527, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid: tmp184 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp184)->tag = 41 ; ats_selptrset_mac(anairiats_sum_2, tmp184, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp184, atslab_1, arg2) ; tmp183 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp183, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp183, atslab_d1exp_node, tmp184) ; return (tmp183) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12129(line=530, offs=13) -- 12191(line=532, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_raise (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_raise: tmp186 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp186)->tag = 42 ; ats_selptrset_mac(anairiats_sum_5, tmp186, atslab_0, arg1) ; tmp185 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp185, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp185, atslab_d1exp_node, tmp186) ; return (tmp185) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_raise] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12237(line=535, offs=11) -- 12317(line=537, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_rec (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_rec: tmp188 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp188)->tag = 43 ; ats_selptrset_mac(anairiats_sum_7, tmp188, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp188, atslab_1, arg2) ; tmp187 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp187, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp187, atslab_d1exp_node, tmp188) ; return (tmp187) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12365(line=540, offs=15) -- 12454(line=542, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_scaseof (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_scaseof: tmp190 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp190)->tag = 44 ; ats_selptrset_mac(anairiats_sum_10, tmp190, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp190, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp190, atslab_2, arg3) ; tmp189 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp189, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp189, atslab_d1exp_node, tmp190) ; return (tmp189) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_scaseof] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12502(line=545, offs=11) -- 12582(line=547, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel: tmp192 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_sum_ptr_type)tmp192)->tag = 45 ; ats_selptrset_mac(anairiats_sum_15, tmp192, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_15, tmp192, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_15, tmp192, atslab_2, arg3) ; tmp191 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp191, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp191, atslab_d1exp_node, tmp192) ; return (tmp191) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sel] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12626(line=550, offs=11) -- 12686(line=552, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq: tmp194 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp194)->tag = 46 ; ats_selptrset_mac(anairiats_sum_5, tmp194, atslab_0, arg1) ; tmp193 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp193, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp193, atslab_d1exp_node, tmp194) ; return (tmp193) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12712(line=555, offs=15) -- 12774(line=557, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sexparg (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sexparg: tmp196 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp196)->tag = 47 ; ats_selptrset_mac(anairiats_sum_5, tmp196, atslab_0, arg1) ; tmp195 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp195, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp195, atslab_d1exp_node, tmp196) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sexparg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12801(line=560, offs=16) -- 12866(line=562, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_showtype (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_showtype: tmp198 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp198)->tag = 48 ; ats_selptrset_mac(anairiats_sum_5, tmp198, atslab_0, arg1) ; tmp197 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp197, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp197, atslab_d1exp_node, tmp198) ; return (tmp197) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_showtype] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 12917(line=566, offs=3) -- 13062(line=571, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sif (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sif: tmp200 = ATS_MALLOC(sizeof(anairiats_sum_17)) ; ((ats_sum_ptr_type)tmp200)->tag = 49 ; ats_selptrset_mac(anairiats_sum_17, tmp200, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_17, tmp200, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_17, tmp200, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_17, tmp200, atslab_3, arg4) ; tmp199 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp199, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp199, atslab_d1exp_node, tmp200) ; return (tmp199) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_sif] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13109(line=574, offs=14) -- 13182(line=576, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string: tmp202 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp202)->tag = 50 ; ats_selptrset_mac(anairiats_sum_11, tmp202, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_11, tmp202, atslab_1, arg2) ; tmp201 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp201, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp201, atslab_d1exp_node, tmp202) ; return (tmp201) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13207(line=579, offs=14) -- 13274(line=581, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_struct (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_struct: tmp204 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp204)->tag = 51 ; ats_selptrset_mac(anairiats_sum_5, tmp204, atslab_0, arg1) ; tmp203 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp203, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp203, atslab_d1exp_node, tmp204) ; return (tmp203) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_struct] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13298(line=584, offs=13) -- 13376(line=586, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tmpid (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tmpid: tmp206 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp206)->tag = 52 ; ats_selptrset_mac(anairiats_sum_2, tmp206, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp206, atslab_1, arg2) ; tmp205 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp205, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp205, atslab_d1exp_node, tmp206) ; return (tmp205) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tmpid] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13398(line=589, offs=11) -- 13450(line=591, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_top (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_top: tmp208 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53) ; tmp207 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp207, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp207, atslab_d1exp_node, tmp208) ; return (tmp207) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_top] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13476(line=594, offs=15) -- 13562(line=596, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_trywith (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_trywith: tmp210 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp210)->tag = 54 ; ats_selptrset_mac(anairiats_sum_10, tmp210, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp210, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp210, atslab_2, arg3) ; tmp209 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp209, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp209, atslab_d1exp_node, tmp210) ; return (tmp209) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_trywith] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13607(line=602, offs=3) -- 13667(line=603, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp211) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup: tmp211 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf (arg0, arg1, 0, arg2) ; return (tmp211) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13714(line=608, offs=3) -- 13874(line=613, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup2 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_int_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup2: tmp213 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (arg2) ; tmp214 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg2, arg3) ; tmp212 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf (arg0, arg1, tmp213, tmp214) ; return (tmp212) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup2] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 13923(line=616, offs=15) -- 14011(line=618, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf (ats_ptr_type arg0, ats_int_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf: tmp216 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ((ats_sum_ptr_type)tmp216)->tag = 55 ; ats_selptrset_mac(anairiats_sum_8, tmp216, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp216, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_8, tmp216, atslab_2, arg3) ; tmp215 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp215, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp215, atslab_d1exp_node, tmp216) ; return (tmp215) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_tup_npf] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14083(line=623, offs=14) -- 14146(line=625, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_viewat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_viewat: tmp218 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp218)->tag = 56 ; ats_selptrset_mac(anairiats_sum_5, tmp218, atslab_0, arg1) ; tmp217 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp217, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp217, atslab_d1exp_node, tmp218) ; return (tmp217) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_viewat] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14195(line=628, offs=13) -- 14269(line=630, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_where (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_where: tmp220 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp220)->tag = 57 ; ats_selptrset_mac(anairiats_sum_2, tmp220, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp220, atslab_1, arg2) ; tmp219 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp219, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp219, atslab_d1exp_node, tmp220) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_where] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14317(line=633, offs=13) -- 14403(line=635, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while: tmp222 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp222)->tag = 58 ; ats_selptrset_mac(anairiats_sum_10, tmp222, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp222, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp222, atslab_2, arg3) ; tmp221 = ATS_MALLOC(sizeof(anairiats_rec_12)) ; ats_selptrset_mac(anairiats_rec_12, tmp221, atslab_d1exp_loc, arg0) ; ats_selptrset_mac(anairiats_rec_12, tmp221, atslab_d1exp_node, tmp222) ; return (tmp221) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_while] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14476(line=640, offs=17) -- 14717(line=647, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric: tmp224 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg0), atslab_d1exp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp224)->tag != 29) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp225 = ats_caselptrlab_mac(anairiats_sum_15, tmp224, atslab_2) ; arg0 = tmp225 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric ; // tail call break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp224)->tag != 31) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp223 = ats_true_bool ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp224)->tag != 32) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp226 = ats_caselptrlab_mac(anairiats_sum_10, tmp224, atslab_2) ; arg0 = tmp226 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp224)->tag != 33) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp227 = ats_caselptrlab_mac(anairiats_sum_10, tmp224, atslab_2) ; arg0 = tmp227 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: __ats_lab_26_1: tmp223 = ats_false_bool ; break ; } while (0) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_is_metric] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14819(line=654, offs=7) -- 15549(line=669, offs=48) */ ATSstaticdec() ats_ptr_type aux_96 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_char_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_int_type, tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; // ATSlocal_void (tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; __ats_lab_aux_96: tmp230 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg0), atslab_e1xp_node) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp230)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp231 = ats_caselptrlab_mac(anairiats_sum_10, tmp230, atslab_0) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_10, tmp230, atslab_1) ; tmp233 = ats_caselptrlab_mac(anairiats_sum_10, tmp230, atslab_2) ; tmp234 = aux_96 (env0, tmp231) ; tmp235 = auxlst_97 (env0, tmp233) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_app_dyn (env0, tmp234, tmp232, 0, tmp235) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp230)->tag != 1) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_4, tmp230, atslab_0) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_char (env0, tmp236) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp230)->tag != 2) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp237 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_float (env0, tmp237) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp230)->tag != 3) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp238 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_qid (env0, statmp0, tmp238) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp230)->tag != 4) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_int (env0, tmp239) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp230)->tag != 5) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp240 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp241 = auxlst_97 (env0, tmp240) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_list (env0, tmp241) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp230)->tag != 9) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_empty (env0) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp230)->tag != 6) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp242 = ats_caselptrlab_mac(anairiats_sum_11, tmp230, atslab_0) ; tmp243 = ats_caselptrlab_mac(anairiats_sum_11, tmp230, atslab_1) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_string (env0, tmp242, tmp243) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp230)->tag != 7) { goto __ats_lab_36_0 ; } __ats_lab_35_1: /* tmp244 = */ prerr_loc_error1_25 (env0) ; /* tmp245 = */ atspre_prerr_string (ATSstrcst(": incorrect use of undefined value.")) ; /* tmp246 = */ atspre_prerr_newline () ; /* tmp229 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (((ats_sum_ptr_type)tmp230)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: tmp247 = ats_caselptrlab_mac(anairiats_sum_5, tmp230, atslab_0) ; tmp229 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_cstsp (env0, tmp247) ; break ; } while (0) ; return (tmp229) ; } /* end of [aux_96] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_96_closure_type ; ats_ptr_type aux_96_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_96 (((aux_96_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_96_closure_init (aux_96_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_96_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_96_closure_make (ats_ptr_type env0) { aux_96_closure_type *p_clo = ATS_MALLOC(sizeof(aux_96_closure_type)) ; aux_96_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 15577(line=672, offs=7) -- 15702(line=674, offs=65) */ ATSstaticdec() ats_ptr_type auxlst_97 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; __ats_lab_auxlst_97: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp249 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp250 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp251 = aux_96 (env0, tmp249) ; tmp252 = auxlst_97 (env0, tmp250) ; tmp248 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ats_selptrset_mac(anairiats_sum_6, tmp248, atslab_0, tmp251) ; ats_selptrset_mac(anairiats_sum_6, tmp248, atslab_1, tmp252) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp248 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp248) ; } /* end of [auxlst_97] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } auxlst_97_closure_type ; ats_ptr_type auxlst_97_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return auxlst_97 (((auxlst_97_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type auxlst_97_closure_init (auxlst_97_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_97_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_97_closure_make (ats_ptr_type env0) { auxlst_97_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_97_closure_type)) ; auxlst_97_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 14794(line=652, offs=17) -- 15750(line=681, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp228) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp: tmp228 = aux_96 (arg0, arg1) ; return (tmp228) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1exp_make_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 15821(line=685, offs=21) -- 15881(line=687, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_lab (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_lab: tmp254 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp254)->tag = 0 ; ats_selptrset_mac(anairiats_sum_5, tmp254, atslab_0, arg1) ; tmp253 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp253, atslab_d1lab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp253, atslab_d1lab_node, tmp254) ; return (tmp253) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_lab] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 15902(line=688, offs=21) -- 15962(line=690, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_ind (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_ind: tmp256 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp256)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp256, atslab_0, arg1) ; tmp255 = ATS_MALLOC(sizeof(anairiats_rec_19)) ; ats_selptrset_mac(anairiats_rec_19, tmp255, atslab_d1lab_loc, arg0) ; ats_selptrset_mac(anairiats_rec_19, tmp255, atslab_d1lab_node, tmp256) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1lab_ind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16007(line=694, offs=23) -- 16083(line=696, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1atch_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp257) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1atch_make: tmp257 = ATS_MALLOC(sizeof(anairiats_rec_20)) ; ats_selptrset_mac(anairiats_rec_20, tmp257, atslab_m1atch_loc, arg0) ; ats_selptrset_mac(anairiats_rec_20, tmp257, atslab_m1atch_exp, arg1) ; ats_selptrset_mac(anairiats_rec_20, tmp257, atslab_m1atch_pat, arg2) ; return (tmp257) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1atch_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16106(line=698, offs=22) -- 16249(line=705, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__c1lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp258) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__c1lau_make: tmp258 = ATS_MALLOC(sizeof(anairiats_rec_21)) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_gua, arg2) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_seq, arg3) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_neg, arg4) ; ats_selptrset_mac(anairiats_rec_21, tmp258, atslab_c1lau_exp, arg5) ; return (tmp258) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__c1lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16296(line=707, offs=23) -- 16374(line=709, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__sc1lau_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp259) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__sc1lau_make: tmp259 = ATS_MALLOC(sizeof(anairiats_rec_22)) ; ats_selptrset_mac(anairiats_rec_22, tmp259, atslab_sc1lau_loc, arg0) ; ats_selptrset_mac(anairiats_rec_22, tmp259, atslab_sc1lau_pat, arg1) ; ats_selptrset_mac(anairiats_rec_22, tmp259, atslab_sc1lau_exp, arg2) ; return (tmp259) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__sc1lau_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16420(line=714, offs=14) -- 16503(line=720, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvarg_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvarg_make: tmp260 = ATS_MALLOC(sizeof(anairiats_rec_23)) ; ats_selptrset_mac(anairiats_rec_23, tmp260, atslab_i1nvarg_loc, arg0) ; ats_selptrset_mac(anairiats_rec_23, tmp260, atslab_i1nvarg_sym, arg1) ; ats_selptrset_mac(anairiats_rec_23, tmp260, atslab_i1nvarg_typ, arg2) ; return (tmp260) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvarg_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16558(line=723, offs=19) -- 16624(line=725, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make: tmp261 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp261, atslab_i1nvresstate_qua, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp261, atslab_i1nvresstate_arg, arg1) ; return (tmp261) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16756(line=732, offs=15) -- 16892(line=740, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp265) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make: tmp265 = ATS_MALLOC(sizeof(anairiats_rec_24)) ; ats_selptrset_mac(anairiats_rec_24, tmp265, atslab_loopi1nv_loc, arg0) ; ats_selptrset_mac(anairiats_rec_24, tmp265, atslab_loopi1nv_qua, arg1) ; ats_selptrset_mac(anairiats_rec_24, tmp265, atslab_loopi1nv_met, arg2) ; ats_selptrset_mac(anairiats_rec_24, tmp265, atslab_loopi1nv_arg, arg3) ; ats_selptrset_mac(anairiats_rec_24, tmp265, atslab_loopi1nv_res, arg4) ; return (tmp265) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 16943(line=743, offs=14) -- 17027(line=745, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil: tmp267 = (ats_sum_ptr_type)0 ; tmp268 = (ats_sum_ptr_type)0 ; tmp269 = (ats_sum_ptr_type)0 ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_make (arg0, tmp267, tmp268, tmp269, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil) ; return (tmp266) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__loopi1nv_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17095(line=749, offs=21) -- 17144(line=751, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none: tmp271 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Cnone_0) ; tmp270 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp270, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp270, atslab_d1ec_node, tmp271) ; return (tmp270) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_none] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17166(line=753, offs=21) -- 17225(line=755, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_list (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_list: tmp273 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp273)->tag = 1 ; ats_selptrset_mac(anairiats_sum_5, tmp273, atslab_0, arg1) ; tmp272 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp272, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp272, atslab_d1ec_node, tmp273) ; return (tmp272) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_list] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17250(line=757, offs=24) -- 17312(line=759, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_include (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_include: tmp275 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp275)->tag = 2 ; ats_selptrset_mac(anairiats_sum_5, tmp275, atslab_0, arg1) ; tmp274 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp274, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp274, atslab_d1ec_node, tmp275) ; return (tmp274) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_include] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17337(line=761, offs=24) -- 17397(line=763, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symintr (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symintr: tmp277 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp277)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp277, atslab_0, arg1) ; tmp276 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp276, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp276, atslab_d1ec_node, tmp277) ; return (tmp276) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symintr] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17422(line=765, offs=24) -- 17482(line=767, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symelim (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symelim: tmp279 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp279)->tag = 4 ; ats_selptrset_mac(anairiats_sum_5, tmp279, atslab_0, arg1) ; tmp278 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp278, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp278, atslab_d1ec_node, tmp279) ; return (tmp278) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_symelim] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17507(line=769, offs=24) -- 17577(line=771, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef: tmp281 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp281)->tag = 5 ; ats_selptrset_mac(anairiats_sum_2, tmp281, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp281, atslab_1, arg2) ; tmp280 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp280, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp280, atslab_d1ec_node, tmp281) ; return (tmp280) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_e1xpdef] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17602(line=773, offs=24) -- 17692(line=775, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datsrts (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datsrts: tmp283 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp283)->tag = 6 ; ats_selptrset_mac(anairiats_sum_7, tmp283, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp283, atslab_1, arg2) ; tmp282 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp282, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp282, atslab_d1ec_node, tmp283) ; return (tmp282) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datsrts] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17717(line=777, offs=24) -- 17793(line=779, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_srtdefs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_srtdefs: tmp285 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp285)->tag = 7 ; ats_selptrset_mac(anairiats_sum_5, tmp285, atslab_0, arg1) ; tmp284 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp284, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp284, atslab_d1ec_node, tmp285) ; return (tmp284) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_srtdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17818(line=781, offs=24) -- 17912(line=783, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacons (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacons: tmp287 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp287)->tag = 8 ; ats_selptrset_mac(anairiats_sum_2, tmp287, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp287, atslab_1, arg2) ; tmp286 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp286, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp286, atslab_d1ec_node, tmp287) ; return (tmp286) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacons] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 17937(line=785, offs=24) -- 18015(line=787, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacsts (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacsts: tmp289 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp289)->tag = 9 ; ats_selptrset_mac(anairiats_sum_5, tmp289, atslab_0, arg1) ; tmp288 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp288, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp288, atslab_d1ec_node, tmp289) ; return (tmp288) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stacsts] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18040(line=789, offs=24) -- 18118(line=791, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stavars (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stavars: tmp291 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp291)->tag = 10 ; ats_selptrset_mac(anairiats_sum_5, tmp291, atslab_0, arg1) ; tmp290 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp290, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp290, atslab_d1ec_node, tmp291) ; return (tmp290) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_stavars] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18146(line=794, offs=3) -- 18239(line=796, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_sexpdefs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_sexpdefs: tmp293 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp293)->tag = 11 ; ats_selptrset_mac(anairiats_sum_2, tmp293, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp293, atslab_1, arg2) ; tmp292 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp292, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp292, atslab_d1ec_node, tmp293) ; return (tmp292) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_sexpdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18264(line=798, offs=24) -- 18324(line=800, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_saspdec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_saspdec: tmp295 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp295)->tag = 12 ; ats_selptrset_mac(anairiats_sum_5, tmp295, atslab_0, arg1) ; tmp294 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp294, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp294, atslab_d1ec_node, tmp295) ; return (tmp294) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_saspdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18350(line=803, offs=15) -- 18449(line=805, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dcstdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dcstdecs: tmp297 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp297)->tag = 13 ; ats_selptrset_mac(anairiats_sum_10, tmp297, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp297, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp297, atslab_2, arg3) ; tmp296 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp296, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp296, atslab_d1ec_node, tmp297) ; return (tmp296) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dcstdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18502(line=808, offs=3) -- 18616(line=810, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datdecs: tmp299 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp299)->tag = 14 ; ats_selptrset_mac(anairiats_sum_10, tmp299, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp299, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp299, atslab_2, arg3) ; tmp298 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp298, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp298, atslab_d1ec_node, tmp299) ; return (tmp298) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_datdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18666(line=813, offs=14) -- 18744(line=815, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_exndecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_exndecs: tmp301 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp301)->tag = 15 ; ats_selptrset_mac(anairiats_sum_5, tmp301, atslab_0, arg1) ; tmp300 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp300, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp300, atslab_d1ec_node, tmp301) ; return (tmp300) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_exndecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18795(line=818, offs=15) -- 18866(line=820, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_classdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_classdec: tmp303 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp303)->tag = 16 ; ats_selptrset_mac(anairiats_sum_2, tmp303, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp303, atslab_1, arg2) ; tmp302 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp302, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp302, atslab_d1ec_node, tmp303) ; return (tmp302) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_classdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 18918(line=822, offs=25) -- 18989(line=824, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_overload (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_overload: tmp305 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp305)->tag = 17 ; ats_selptrset_mac(anairiats_sum_2, tmp305, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp305, atslab_1, arg2) ; tmp304 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp304, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp304, atslab_d1ec_node, tmp305) ; return (tmp304) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_overload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19039(line=826, offs=23) -- 19120(line=828, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extype (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extype: tmp307 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp307)->tag = 18 ; ats_selptrset_mac(anairiats_sum_2, tmp307, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp307, atslab_1, arg2) ; tmp306 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp306, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp306, atslab_d1ec_node, tmp307) ; return (tmp306) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extype] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19144(line=830, offs=23) -- 19225(line=832, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extval (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extval: tmp309 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp309)->tag = 19 ; ats_selptrset_mac(anairiats_sum_2, tmp309, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp309, atslab_1, arg2) ; tmp308 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp308, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp308, atslab_d1ec_node, tmp309) ; return (tmp308) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extval] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19250(line=834, offs=24) -- 19340(line=836, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extcode (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extcode: tmp311 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp311)->tag = 20 ; ats_selptrset_mac(anairiats_sum_7, tmp311, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp311, atslab_1, arg2) ; tmp310 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp310, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp310, atslab_d1ec_node, tmp311) ; return (tmp310) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_extcode] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19365(line=838, offs=24) -- 19455(line=840, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs: tmp313 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp313)->tag = 21 ; ats_selptrset_mac(anairiats_sum_2, tmp313, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp313, atslab_1, arg2) ; tmp312 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp312, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp312, atslab_d1ec_node, tmp313) ; return (tmp312) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19484(line=842, offs=28) -- 19558(line=844, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_par (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_ptr_type, tmp315) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_par: tmp315 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp315)->tag = 22 ; ats_selptrset_mac(anairiats_sum_5, tmp315, atslab_0, arg1) ; tmp314 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp314, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp314, atslab_d1ec_node, tmp315) ; return (tmp314) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_par] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19587(line=846, offs=28) -- 19661(line=848, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_rec (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_rec: tmp317 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp317)->tag = 23 ; ats_selptrset_mac(anairiats_sum_5, tmp317, atslab_0, arg1) ; tmp316 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp316, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp316, atslab_d1ec_node, tmp317) ; return (tmp316) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_valdecs_rec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19686(line=850, offs=24) -- 19790(line=852, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_fundecs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_fundecs: tmp319 = ATS_MALLOC(sizeof(anairiats_sum_10)) ; ((ats_sum_ptr_type)tmp319)->tag = 24 ; ats_selptrset_mac(anairiats_sum_10, tmp319, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_10, tmp319, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_10, tmp319, atslab_2, arg3) ; tmp318 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp318, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp318, atslab_d1ec_node, tmp319) ; return (tmp318) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_fundecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19815(line=854, offs=24) -- 19885(line=856, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_vardecs (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_vardecs: tmp321 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp321)->tag = 25 ; ats_selptrset_mac(anairiats_sum_5, tmp321, atslab_0, arg1) ; tmp320 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp320, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp320, atslab_d1ec_node, tmp321) ; return (tmp320) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_vardecs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 19910(line=858, offs=24) -- 20037(line=861, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_macdefs (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_macdefs: tmp323 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp323)->tag = 26 ; ats_selptrset_mac(anairiats_sum_7, tmp323, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp323, atslab_1, arg2) ; tmp322 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp322, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp322, atslab_d1ec_node, tmp323) ; return (tmp322) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_macdefs] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20061(line=863, offs=23) -- 20166(line=866, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_impdec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_impdec: tmp325 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp325)->tag = 27 ; ats_selptrset_mac(anairiats_sum_2, tmp325, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp325, atslab_1, arg2) ; tmp324 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp324, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp324, atslab_d1ec_node, tmp325) ; return (tmp324) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_impdec] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20189(line=868, offs=22) -- 20283(line=870, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_local (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_local: tmp327 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp327)->tag = 28 ; ats_selptrset_mac(anairiats_sum_2, tmp327, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_2, tmp327, atslab_1, arg2) ; tmp326 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp326, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp326, atslab_d1ec_node, tmp327) ; return (tmp326) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20308(line=872, offs=24) -- 20370(line=874, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dynload (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dynload: tmp329 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp329)->tag = 29 ; ats_selptrset_mac(anairiats_sum_5, tmp329, atslab_0, arg1) ; tmp328 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp328, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp328, atslab_d1ec_node, tmp329) ; return (tmp328) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_dynload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20397(line=877, offs=3) -- 20505(line=879, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_staload (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_staload: tmp331 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp331)->tag = 30 ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_1, arg2) ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_2, arg3) ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_3, arg4) ; tmp330 = ATS_MALLOC(sizeof(anairiats_rec_25)) ; ats_selptrset_mac(anairiats_rec_25, tmp330, atslab_d1ec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_25, tmp330, atslab_d1ec_node, tmp331) ; return (tmp330) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1ec_staload] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20579(line=883, offs=27) -- 20665(line=885, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtcon_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp332) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtcon_make: tmp332 = ATS_MALLOC(sizeof(anairiats_rec_26)) ; ats_selptrset_mac(anairiats_rec_26, tmp332, atslab_d1atsrtcon_loc, arg0) ; ats_selptrset_mac(anairiats_rec_26, tmp332, atslab_d1atsrtcon_sym, arg1) ; ats_selptrset_mac(anairiats_rec_26, tmp332, atslab_d1atsrtcon_arg, arg2) ; return (tmp332) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtcon_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20721(line=887, offs=27) -- 20803(line=889, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp333) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtdec_make: tmp333 = ATS_MALLOC(sizeof(anairiats_rec_27)) ; ats_selptrset_mac(anairiats_rec_27, tmp333, atslab_d1atsrtdec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_27, tmp333, atslab_d1atsrtdec_sym, arg1) ; ats_selptrset_mac(anairiats_rec_27, tmp333, atslab_d1atsrtdec_con, arg2) ; return (tmp333) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atsrtdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20856(line=891, offs=24) -- 20935(line=895, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1rtdef_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp334) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1rtdef_make: tmp334 = ATS_MALLOC(sizeof(anairiats_rec_28)) ; ats_selptrset_mac(anairiats_rec_28, tmp334, atslab_s1rtdef_loc, arg0) ; ats_selptrset_mac(anairiats_rec_28, tmp334, atslab_s1rtdef_sym, arg1) ; ats_selptrset_mac(anairiats_rec_28, tmp334, atslab_s1rtdef_def, arg2) ; return (tmp334) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1rtdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 20985(line=898, offs=14) -- 21110(line=904, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacon_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp335) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacon_make: tmp335 = ATS_MALLOC(sizeof(anairiats_rec_29)) ; ats_selptrset_mac(anairiats_rec_29, tmp335, atslab_s1tacon_fil, arg0) ; ats_selptrset_mac(anairiats_rec_29, tmp335, atslab_s1tacon_loc, arg1) ; ats_selptrset_mac(anairiats_rec_29, tmp335, atslab_s1tacon_sym, arg2) ; ats_selptrset_mac(anairiats_rec_29, tmp335, atslab_s1tacon_arg, arg3) ; ats_selptrset_mac(anairiats_rec_29, tmp335, atslab_s1tacon_def, arg4) ; return (tmp335) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacon_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 21160(line=907, offs=14) -- 21285(line=913, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacst_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp336) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacst_make: tmp336 = ATS_MALLOC(sizeof(anairiats_rec_30)) ; ats_selptrset_mac(anairiats_rec_30, tmp336, atslab_s1tacst_fil, arg0) ; ats_selptrset_mac(anairiats_rec_30, tmp336, atslab_s1tacst_loc, arg1) ; ats_selptrset_mac(anairiats_rec_30, tmp336, atslab_s1tacst_sym, arg2) ; ats_selptrset_mac(anairiats_rec_30, tmp336, atslab_s1tacst_arg, arg3) ; ats_selptrset_mac(anairiats_rec_30, tmp336, atslab_s1tacst_res, arg4) ; return (tmp336) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tacst_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 21335(line=915, offs=24) -- 21410(line=917, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tavar_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tavar_make: tmp337 = ATS_MALLOC(sizeof(anairiats_rec_31)) ; ats_selptrset_mac(anairiats_rec_31, tmp337, atslab_s1tavar_loc, arg0) ; ats_selptrset_mac(anairiats_rec_31, tmp337, atslab_s1tavar_sym, arg1) ; ats_selptrset_mac(anairiats_rec_31, tmp337, atslab_s1tavar_srt, arg2) ; return (tmp337) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1tavar_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 21436(line=919, offs=25) -- 21566(line=925, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1expdef_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp338) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1expdef_make: tmp338 = ATS_MALLOC(sizeof(anairiats_rec_32)) ; ats_selptrset_mac(anairiats_rec_32, tmp338, atslab_s1expdef_loc, arg0) ; ats_selptrset_mac(anairiats_rec_32, tmp338, atslab_s1expdef_sym, arg1) ; ats_selptrset_mac(anairiats_rec_32, tmp338, atslab_s1expdef_arg, arg2) ; ats_selptrset_mac(anairiats_rec_32, tmp338, atslab_s1expdef_res, arg3) ; ats_selptrset_mac(anairiats_rec_32, tmp338, atslab_s1expdef_def, arg4) ; return (tmp338) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1expdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 21620(line=928, offs=3) -- 21777(line=935, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1aspdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp339) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1aspdec_make: tmp339 = ATS_MALLOC(sizeof(anairiats_rec_33)) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_fil, arg0) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_loc, arg1) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_qid, arg2) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_arg, arg3) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_res, arg4) ; ats_selptrset_mac(anairiats_rec_33, tmp339, atslab_s1aspdec_def, arg5) ; return (tmp339) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__s1aspdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 21850(line=939, offs=25) -- 21989(line=945, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1cstdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp340) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1cstdec_make: tmp340 = ATS_MALLOC(sizeof(anairiats_rec_34)) ; ats_selptrset_mac(anairiats_rec_34, tmp340, atslab_d1cstdec_fil, arg0) ; ats_selptrset_mac(anairiats_rec_34, tmp340, atslab_d1cstdec_loc, arg1) ; ats_selptrset_mac(anairiats_rec_34, tmp340, atslab_d1cstdec_sym, arg2) ; ats_selptrset_mac(anairiats_rec_34, tmp340, atslab_d1cstdec_typ, arg3) ; ats_selptrset_mac(anairiats_rec_34, tmp340, atslab_d1cstdec_extdef, arg4) ; return (tmp340) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1cstdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22040(line=947, offs=24) -- 22189(line=954, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atcon_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp341) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atcon_make: tmp341 = ATS_MALLOC(sizeof(anairiats_rec_35)) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_loc, arg0) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_sym, arg1) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_qua, arg2) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_npf, arg3) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_arg, arg4) ; ats_selptrset_mac(anairiats_rec_35, tmp341, atslab_d1atcon_ind, arg5) ; return (tmp341) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atcon_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22239(line=956, offs=24) -- 22364(line=962, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp342) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atdec_make: tmp342 = ATS_MALLOC(sizeof(anairiats_rec_36)) ; ats_selptrset_mac(anairiats_rec_36, tmp342, atslab_d1atdec_fil, arg0) ; ats_selptrset_mac(anairiats_rec_36, tmp342, atslab_d1atdec_loc, arg1) ; ats_selptrset_mac(anairiats_rec_36, tmp342, atslab_d1atdec_sym, arg2) ; ats_selptrset_mac(anairiats_rec_36, tmp342, atslab_d1atdec_arg, arg3) ; ats_selptrset_mac(anairiats_rec_36, tmp342, atslab_d1atdec_con, arg4) ; return (tmp342) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__d1atdec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22414(line=964, offs=24) -- 22563(line=971, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__e1xndec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_int_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp343) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__e1xndec_make: tmp343 = ATS_MALLOC(sizeof(anairiats_rec_37)) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_fil, arg0) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_loc, arg1) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_sym, arg2) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_qua, arg3) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_npf, arg4) ; ats_selptrset_mac(anairiats_rec_37, tmp343, atslab_e1xndec_arg, arg5) ; return (tmp343) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__e1xndec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22634(line=975, offs=24) -- 22737(line=980, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1aldec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp344) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1aldec_make: tmp344 = ATS_MALLOC(sizeof(anairiats_rec_38)) ; ats_selptrset_mac(anairiats_rec_38, tmp344, atslab_v1aldec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_38, tmp344, atslab_v1aldec_pat, arg1) ; ats_selptrset_mac(anairiats_rec_38, tmp344, atslab_v1aldec_def, arg2) ; ats_selptrset_mac(anairiats_rec_38, tmp344, atslab_v1aldec_ann, arg3) ; return (tmp344) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1aldec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22787(line=982, offs=24) -- 22922(line=988, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__f1undec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp345) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__f1undec_make: tmp345 = ATS_MALLOC(sizeof(anairiats_rec_39)) ; ats_selptrset_mac(anairiats_rec_39, tmp345, atslab_f1undec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_39, tmp345, atslab_f1undec_sym, arg1) ; ats_selptrset_mac(anairiats_rec_39, tmp345, atslab_f1undec_sym_loc, arg2) ; ats_selptrset_mac(anairiats_rec_39, tmp345, atslab_f1undec_def, arg3) ; ats_selptrset_mac(anairiats_rec_39, tmp345, atslab_f1undec_ann, arg4) ; return (tmp345) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__f1undec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 22974(line=991, offs=3) -- 23172(line=999, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1ardec_make (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5, ats_ptr_type arg6) { /* local vardec */ ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1ardec_make: tmp346 = ATS_MALLOC(sizeof(anairiats_rec_40)) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_knd, arg1) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_sym, arg2) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_sym_loc, arg3) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_typ, arg4) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_wth, arg5) ; ats_selptrset_mac(anairiats_rec_40, tmp346, atslab_v1ardec_ini, arg6) ; return (tmp346) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__v1ardec_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 23222(line=1001, offs=24) -- 23323(line=1006, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1acdef_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1acdef_make: tmp347 = ATS_MALLOC(sizeof(anairiats_rec_41)) ; ats_selptrset_mac(anairiats_rec_41, tmp347, atslab_m1acdef_loc, arg0) ; ats_selptrset_mac(anairiats_rec_41, tmp347, atslab_m1acdef_sym, arg1) ; ats_selptrset_mac(anairiats_rec_41, tmp347, atslab_m1acdef_arg, arg2) ; ats_selptrset_mac(anairiats_rec_41, tmp347, atslab_m1acdef_def, arg3) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__m1acdef_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1.dats: 23373(line=1008, offs=24) -- 23485(line=1013, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1mpdec_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp348) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1mpdec_make: tmp348 = ATS_MALLOC(sizeof(anairiats_rec_42)) ; ats_selptrset_mac(anairiats_rec_42, tmp348, atslab_i1mpdec_loc, arg0) ; ats_selptrset_mac(anairiats_rec_42, tmp348, atslab_i1mpdec_qid, arg1) ; ats_selptrset_mac(anairiats_rec_42, tmp348, atslab_i1mpdec_tmparg, arg2) ; ats_selptrset_mac(anairiats_rec_42, tmp348, atslab_i1mpdec_def, arg3) ; return (tmp348) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1mpdec_make] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp262, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp263, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp264, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = d0ynq_none () ; statmp263 = (ats_sum_ptr_type)0 ; statmp264 = (ats_sum_ptr_type)0 ; statmp262 = ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_make (statmp263, statmp264) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__i1nvresstate_nil = statmp262 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp1_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_loop_dats.c0000664000175000017500000010410612223166160022364 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_i2nvarg_var ; ats_ptr_type atslab_i2nvarg_typ ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_loopi2nv_loc ; ats_ptr_type atslab_loopi2nv_svs ; ats_ptr_type atslab_loopi2nv_gua ; ats_ptr_type atslab_loopi2nv_met ; ats_ptr_type atslab_loopi2nv_arg ; ats_ptr_type atslab_loopi2nv_res ; } anairiats_rec_3 ; typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_7 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDloop_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__LMLPloop1_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make_met) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_update) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loop) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loopexn) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ntm) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_state_staftscstr_met_set) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge_skipmetck) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_top) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop0) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop1) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_free) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn) (ats_ptr_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type i2nvarg_subst_0 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_2 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_2_closure_make (ats_ptr_type env0) ; static ats_ptr_type __ats_fun_2_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type i2nvarglst_subst_1 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_4 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_4_closure_make (ats_ptr_type env0) ; static ats_void_type aux_4_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static anairiats_rec_2 d2exp_loopinv_tr_3 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 1839(line=55, offs=4) -- 2089(line=64, offs=4) */ ATSstaticdec() ats_ptr_type i2nvarg_subst_0 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; __ats_lab_i2nvarg_subst_0: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_i2nvarg_var) ; tmp3 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_i2nvarg_typ) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp3 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp4 = ats_caselptrlab_mac(anairiats_sum_1, tmp3, atslab_0) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (arg0, tmp4) ; tmp2 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp2, atslab_0, tmp5) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp2 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp0 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvarg_make (tmp1, tmp2) ; return (tmp0) ; } /* end of [i2nvarg_subst_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 2228(line=69, offs=11) -- 2271(line=69, offs=54) */ ATSstaticdec() ats_ptr_type __ats_fun_2 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; __ats_lab___ats_fun_2: tmp8 = i2nvarg_subst_0 (env0, arg0) ; return (tmp8) ; } /* end of [__ats_fun_2] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_2_closure_type ; ats_ptr_type __ats_fun_2_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_2 (((__ats_fun_2_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_2_closure_init (__ats_fun_2_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_2_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_2_closure_make (ats_ptr_type env0) { __ats_fun_2_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_2_closure_type)) ; __ats_fun_2_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 2120(line=66, offs=4) -- 2279(line=71, offs=4) */ ATSstaticdec() ats_ptr_type i2nvarglst_subst_1 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_i2nvarglst_subst_1: /* ats_ptr_type tmp7 ; */ tmp7 = __ats_fun_2_closure_make (arg0) ; tmp6 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (arg1, tmp7) ; ATS_FREE(tmp7) ; return (tmp6) ; } /* end of [i2nvarglst_subst_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 3261(line=99, offs=8) -- 3591(line=110, offs=9) */ ATSstaticdec() ats_void_type aux_4 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_aux_4: tmp22 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_i2nvarg_var) ; tmp23 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_i2nvarg_typ) ; do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (tmp23 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp24 = ats_caselptrlab_mac(anairiats_sum_1, tmp23, atslab_0) ; tmp25 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (env0, tmp24) ; tmp26 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp26, atslab_0, tmp25) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp22, tmp26) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp23 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp27 = (ats_sum_ptr_type)0 ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (tmp22, tmp27) ; break ; } while (0) ; return /* (tmp21) */ ; } /* end of [aux_4] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_4_closure_type ; ats_void_type aux_4_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_4 (((aux_4_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_4_closure_init (aux_4_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_4_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_4_closure_make (ats_ptr_type env0) { aux_4_closure_type *p_clo = ATS_MALLOC(sizeof(aux_4_closure_type)) ; aux_4_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 2313(line=73, offs=4) -- 3710(line=116, offs=4) */ ATSstaticdec() anairiats_rec_2 d2exp_loopinv_tr_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_2, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp28) ; ATSlocal (ats_clo_ptr_type, tmp29) ; __ats_lab_d2exp_loopinv_tr_3: tmp10 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_loopi2nv_loc) ; tmp11 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_loopi2nv_arg) ; tmp12 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_loopi2nv_res) ; tmp13 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp12), atslab_i2nvresstate_svs) ; tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp12), atslab_i2nvresstate_gua) ; tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, arg0), atslab_loopi2nv_met) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp15 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_1, tmp15, atslab_0) ; /* tmp16 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_nat_check (tmp10, tmp17) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp15 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; tmp18 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp12), atslab_i2nvresstate_arg) ; tmp19 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp18, tmp11) ; tmp20 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make (tmp13, tmp14, tmp19) ; /* ats_clo_ptr_type tmp29 ; */ tmp29 = aux_4_closure_make (tmp10) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_foreach_cloptr (tmp11, tmp29) ; ATS_FREE(tmp29) ; tmp9.atslab_0 = tmp15 ; tmp9.atslab_1 = tmp20 ; return (tmp9) ; } /* end of [d2exp_loopinv_tr_3] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 3791(line=121, offs=3) -- 7687(line=222, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; // ATSlocal_void (tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; // ATSlocal_void (tmp55) ; // ATSlocal_void (tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; // ATSlocal_void (tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; // ATSlocal_void (tmp66) ; ATSlocal (anairiats_rec_2, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; // ATSlocal_void (tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; // ATSlocal_void (tmp79) ; // ATSlocal_void (tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; // ATSlocal_void (tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; ATSlocal (ats_bool_type, tmp90) ; ATSlocal (ats_bool_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up: tmp31 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp34 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp33, tmp31) ; tmp32 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp32, atslab_0, tmp34) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: tmp32 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__loopi2nv_update (arg1) ; tmp36 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp35), atslab_loopi2nv_met) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (tmp36 != (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_effect_env_check_ntm (arg0) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (tmp36 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: break ; } while (0) ; tmp39 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp35), atslab_loopi2nv_svs) ; tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp35), atslab_loopi2nv_gua) ; tmp41 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp35), atslab_loopi2nv_arg) ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__i2nvresstate_make_met (tmp39, tmp40, tmp41, tmp36) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () ; /* tmp43 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; tmp44 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg3) ; /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp44) ; tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp44), atslab_d3exp_typ) ; /* tmp47 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn (arg0, ats_true_bool, tmp46) ; /* tmp48 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop0 () ; /* tmp49 = ats_selsin_mac(tmp48, atslab_1) */ ; tmp50 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg5, tmp31) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp52, tmp31) ; tmp51 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp51, atslab_0, tmp53) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp51 = (ats_sum_ptr_type)0 ; break ; } while (0) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; /* tmp55 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_free () ; /* tmp56 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitemlst_restore_typ (tmp42) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (tmp38, tmp42) ; /* tmp58 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp59 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp57, tmp42) ; tmp60 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp60)->tag = 5 ; ats_selptrset_mac(anairiats_sum_6, tmp60, atslab_0, 0) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp60) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp57, tmp42) ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp64 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp57, tmp42) ; tmp65 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (tmp38, tmp42) ; /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge_skipmetck (arg0, tmp65, tmp42) ; tmp67 = d2exp_loopinv_tr_3 (tmp35) ; tmp68 = ats_select_mac(tmp67, atslab_0) ; tmp69 = ats_select_mac(tmp67, atslab_1) ; /* tmp70 = */ atsopt_state_staftscstr_met_set (tmp65, tmp68) ; tmp71 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_initialize (tmp69, tmp42) ; tmp72 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_up (arg3) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp72) ; tmp74 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp72), atslab_d3exp_typ) ; /* tmp75 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp76 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn (arg0, ats_false_bool, tmp74) ; /* tmp77 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp71, tmp42) ; tmp78 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp78)->tag = 5 ; ats_selptrset_mac(anairiats_sum_6, tmp78, atslab_0, 1) ; /* tmp79 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp78) ; /* tmp80 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp81 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__assert_bool_tr_dn (arg0, ats_true_bool, tmp74) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_push_loop1 (tmp42, tmp65, tmp71, arg4) ; /* tmp83 = ats_selsin_mac(tmp82, atslab_1) */ ; tmp84 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (arg5, tmp31) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_1, arg4, atslab_0) ; tmp87 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp86, tmp31) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: break ; } while (0) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_pop () ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_is_raised (arg5) ; tmp90 = atspre_neg_bool (tmp91) ; if (tmp90) { /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp65, tmp42) ; } else { /* empty */ } /* end of [if] */ tmp92 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp92)->tag = 5 ; ats_selptrset_mac(anairiats_sum_6, tmp92, atslab_0, 2) ; /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp92) ; /* tmp94 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp65, tmp42) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_check (arg0, tmp71, tmp42) ; /* tmp96 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_update (arg0, tmp71, tmp42) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loop (arg0, tmp32, tmp72, tmp51, tmp84) ; return (tmp30) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loop_tr_up] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_loop.dats: 7794(line=229, offs=3) -- 8752(line=263, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loopexn_tr_up (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_bool_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_bool_type, tmp110) ; // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loopexn_tr_up: tmp99 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_top () ; do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp99)->tag != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp99)->tag != 2) { goto __ats_lab_18_0 ; } __ats_lab_15_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_7, tmp99, atslab_0) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_7, tmp99, atslab_1) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_7, tmp99, atslab_2) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_7, tmp99, atslab_3) ; tmp106 = atspre_gt_int_int (arg1, 0) ; if (tmp106) { do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (tmp104 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp107 = ats_caselptrlab_mac(anairiats_sum_1, tmp104, atslab_0) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; tmp108 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_tr_dn (tmp107, tmp109) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (tmp104 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: break ; } while (0) ; } else { /* empty */ } /* end of [if] */ tmp110 = atspre_gt_int_int (arg1, 0) ; if (tmp110) { /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp102, tmp101) ; } else { /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staftscstr_stbefitemlst_merge (arg0, tmp103, tmp101) ; } /* end of [if] */ break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp112 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_loop)")) ; /* tmp113 = */ atspre_prerr_string (ATSstrcst(": d2exp_loopexn_tr_up")) ; /* tmp114 = */ atspre_prerr_newline () ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp98 = ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__d3exp_loopexn (arg0, arg1) ; return (tmp98) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_loopexn_tr_up] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_loop_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_loop_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libc_sats_time_sats.c0000664000175000017500000000205612223166160022253 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ #include "libc/CATS/time.cats" /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libc_sats_time_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libc_sats_time_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_util_dats.c0000664000175000017500000014053412223166160022375 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_d3exp_loc ; ats_ptr_type atslab_d3exp_eff ; ats_ptr_type atslab_d3exp_typ ; ats_ptr_type atslab_d3exp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_d2exp_loc ; ats_ptr_type atslab_d2exp_node ; ats_ptr_type atslab_d2exp_typ ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_7 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPfilename_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__CSTSPlocation_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDfloat_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_long_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDnone_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDlint_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDulint_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDllint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDullint_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDnone_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_print_newline) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_print_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__print_location) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc) (ats_ptr_type, ats_bool_type, ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_d2exp_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, ats_dynexp3_d3exp_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp) (ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_ptr_type s2eff_of_d2exp_4 (ats_ptr_type arg0) ; static ats_ptr_type d2exp_arg_body_typ_syn_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) ; static ats_ptr_type aux_8 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type d3exp_get_ind_12 (ats_ptr_type arg0) ; static ats_ptr_type d3explst_get_ind_13 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp2) ; ATSstatic (ats_ptr_type, statmp3) ; ATSstatic (ats_ptr_type, statmp4) ; ATSstatic (ats_ptr_type, statmp5) ; ATSstatic (ats_ptr_type, statmp6) ; ATSstatic (ats_ptr_type, statmp7) ; ATSstatic (ats_ptr_type, statmp8) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp10) ; /* external value variable declarations */ ats_ptr_type FLOATKINDfloat ; ats_ptr_type FLOATKINDdouble ; ats_ptr_type FLOATKINDdouble_long ; ats_ptr_type FLOATKINDnone ; ats_ptr_type INTKINDint ; ats_ptr_type INTKINDuint ; ats_ptr_type INTKINDlint ; ats_ptr_type INTKINDulint ; ats_ptr_type INTKINDllint ; ats_ptr_type INTKINDullint ; ats_ptr_type INTKINDnone ; /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 4006(line=143, offs=4) -- 4095(line=146, offs=2) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; __ats_lab_prerr_loc_error3_0: /* tmp12 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp11 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp11) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 4175(line=152, offs=3) -- 4431(line=166, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__fshowtype_d3exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__fshowtype_d3exp: tmp14 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_loc) ; tmp15 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_typ) ; /* tmp16 = */ atspre_print_string (ATSstrcst("**SHOWTYPE**(")) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__print_location (tmp14) ; /* tmp18 = */ atspre_print_string (ATSstrcst("): ")) ; /* tmp19 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__fpprint_s2exp (stdout, tmp15) ; /* tmp13 = */ atspre_print_newline () ; return /* (tmp13) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__fshowtype_d3exp] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 4606(line=175, offs=23) -- 4724(line=177, offs=60) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp: tmp21 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp21)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_2, tmp21, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_2, tmp21, atslab_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp23 ; tmp20 = tmp22 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: __ats_lab_1_1: tmp20 = arg0 ; break ; } while (0) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 4814(line=184, offs=3) -- 5126(line=191, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_s2eff_of_d2exp (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_s2eff_of_d2exp: tmp25 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp25)->tag != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_2, tmp25, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_2, tmp25, atslab_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp27 ; tmp24 = tmp26 ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp25)->tag != 30) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp28 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp28 ; tmp24 = arg0 ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp25)->tag != 31) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp29 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp29 ; tmp24 = arg0 ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp25)->tag != 33) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp30 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp30 ; tmp24 = arg0 ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: __ats_lab_6_1: tmp31 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp31 ; tmp24 = arg0 ; break ; } while (0) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_s2eff_of_d2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 5185(line=195, offs=4) -- 5406(line=202, offs=21) */ ATSstaticdec() ats_ptr_type s2eff_of_d2exp_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; __ats_lab_s2eff_of_d2exp_4: tmp33 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp33)->tag != 1) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_2, tmp33, atslab_1) ; tmp32 = tmp34 ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp33)->tag != 30) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp33)->tag != 31) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp33)->tag != 33) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: __ats_lab_11_1: tmp32 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; } while (0) ; return (tmp32) ; } /* end of [s2eff_of_d2exp_4] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 5438(line=205, offs=4) -- 6341(line=237, offs=4) */ ATSstaticdec() ats_ptr_type d2exp_arg_body_typ_syn_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4, ats_ptr_type arg5) { /* local vardec */ ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_bool_type, tmp42) ; ATSlocal (ats_bool_type, tmp43) ; ATSlocal (ats_bool_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_d2exp_arg_body_typ_syn_5: tmp36 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_loc) ; /* ats_ptr_type tmp37 ; */ tmp37 = arg1 ; tmp38 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__p2atlst_typ_syn (arg4) ; tmp39 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (arg5) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_funclo_of_d2exp (arg5, (&tmp37)) ; tmp41 = s2eff_of_d2exp_4 (tmp40) ; tmp42 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp39) ; tmp44 = atspre_gt_int_int (arg2, 0) ; if (tmp44) { tmp43 = ats_true_bool ; } else { tmp43 = ats_false_bool ; } /* end of [if] */ tmp45 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc (tmp36, tmp42, tmp43, tmp37) ; tmp35 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp45, tmp37, arg2, tmp41, arg3, tmp38, tmp39) ; return (tmp35) ; } /* end of [d2exp_arg_body_typ_syn_5] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 6431(line=243, offs=3) -- 6551(line=245, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp46 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)arg0)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp46 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; break ; } while (0) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 6632(line=250, offs=7) -- 6759(line=251, offs=72) */ ATSstaticdec() ats_ptr_type aux_8 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_aux_8: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp49 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp50 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; arg0 = tmp49 ; arg1 = tmp50 ; goto __ats_lab_aux_8 ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp48 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (arg0) ; break ; } while (0) ; return (tmp48) ; } /* end of [aux_8] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 6613(line=249, offs=19) -- 6872(line=256, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_seq_typ_syn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_seq_typ_syn: do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp47 = aux_8 (tmp51, tmp52) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: tmp47 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; } while (0) ; return (tmp47) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_seq_typ_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 6949(line=261, offs=15) -- 9272(line=322, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_int_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_int_type, tmp68) ; ATSlocal (ats_int_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn: tmp54 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_node) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp54)->tag != 2) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_1) ; tmp53 = tmp55 ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp54)->tag != 1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_0) ; arg0 = tmp56 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp54)->tag != 0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_0) ; arg0 = tmp57 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)tmp54)->tag != 5) { goto __ats_lab_24_0 ; } __ats_lab_21_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_1) ; tmp60 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_loc) ; tmp61 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length (tmp59) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (tmp58 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_4, tmp58, atslab_0) ; tmp62 = tmp63 ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (tmp58 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp62 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp60, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; break ; } while (0) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype (tmp62, tmp61) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp54)->tag != 7) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp54)->tag != 10) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype () ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp54)->tag != 12) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_5, tmp54, atslab_0) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2cst_get_typ (tmp64) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp54)->tag != 13) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp65 = ats_caselptrlab_mac(anairiats_sum_5, tmp54, atslab_0) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d2exp_cstsp_typ_syn (tmp65) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp54)->tag != 17) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_1) ; arg0 = tmp66 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp54)->tag != 18) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp54)->tag != 21) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_6, tmp54, atslab_2) ; arg0 = tmp67 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp54)->tag != 22) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp54)->tag != 25) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp54)->tag != 28) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype () ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp54)->tag != 30) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_0) ; tmp69 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_1) ; tmp70 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_2) ; tmp71 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_3) ; tmp72 = (ats_sum_ptr_type)0 ; tmp53 = d2exp_arg_body_typ_syn_5 (arg0, tmp72, tmp68, tmp69, tmp70, tmp71) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp54)->tag != 31) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_0) ; tmp74 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_1) ; tmp75 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_2) ; tmp76 = ats_caselptrlab_mac(anairiats_sum_7, tmp54, atslab_3) ; tmp77 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp77, atslab_0, 0) ; tmp53 = d2exp_arg_body_typ_syn_5 (arg0, tmp77, tmp73, tmp74, tmp75, tmp76) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp54)->tag != 32) { goto __ats_lab_39_0 ; } __ats_lab_36_1: tmp78 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_0) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_1) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_2) ; tmp81 = ats_ptrget_mac(ats_ptr_type, tmp78) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (tmp81 == (ats_sum_ptr_type)0) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp82 = (ats_sum_ptr_type)0 ; tmp83 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (tmp80) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn (tmp82, tmp79, tmp83) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: // if (tmp81 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_38_1: tmp85 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_loc) ; /* tmp84 = */ prerr_loc_error3_0 (tmp85) ; /* tmp86 = */ atspre_prerr_string (ATSstrcst(": illegal use of termination metric.")) ; /* tmp87 = */ atspre_prerr_newline () ; /* tmp53 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp54)->tag != 33) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_0) ; tmp89 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_1) ; tmp90 = ats_caselptrlab_mac(anairiats_sum_9, tmp54, atslab_2) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn (tmp90) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp88, tmp89, tmp91) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp54)->tag != 36) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp92 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_1) ; arg0 = tmp92 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp54)->tag != 51) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp54)->tag != 58) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp93 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_0) ; arg0 = tmp93 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn ; // tail call break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp54)->tag != 59) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_1, arg0), atslab_d2exp_loc) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (tmp95, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp97 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp97, atslab_0, tmp94) ; /* tmp96 = */ atsopt_d2exp_set_typ (arg0, tmp97) ; tmp53 = tmp94 ; break ; } while (0) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2exp_typ_syn] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 9350(line=327, offs=20) -- 9459(line=331, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add: tmp100 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_loc) ; tmp101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_typ) ; tmp99 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (tmp100, tmp101) ; /* tmp98 = */ ats_dynexp3_d3exp_set_typ (arg0, tmp99) ; return /* (tmp98) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 9526(line=335, offs=3) -- 9693(line=339, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; // ATSlocal_void (tmp105) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp103 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp104 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (tmp103) ; arg0 = tmp104 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_46_1: break ; } while (0) ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explst_open_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 9760(line=346, offs=4) -- 10483(line=370, offs=4) */ ATSstaticdec() ats_ptr_type d3exp_get_ind_12 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; ATSlocal (ats_ptr_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; __ats_lab_d3exp_get_ind_12: /* tmp107 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3exp_open_and_add (arg0) ; tmp108 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_typ) ; tmp109 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype (tmp108) ; do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (tmp109 == (ats_sum_ptr_type)0) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp110 = tmp109 ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: // if (tmp109 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_48_1: tmp110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype (tmp108) ; break ; } while (0) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (tmp110 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp111 = ats_caselptrlab_mac(anairiats_sum_4, tmp110, atslab_0) ; ATS_FREE(tmp110) ; tmp106 = tmp111 ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp110 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp113 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_d3exp_loc) ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp113) ; /* tmp114 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; /* tmp115 = */ atspre_prerr_string (ATSstrcst(": the array index is assigned the type [")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp108) ; /* tmp117 = */ atspre_prerr_string (ATSstrcst("], which is not an indexed integer type.")) ; /* tmp118 = */ atspre_prerr_newline () ; /* tmp106 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp106) ; } /* end of [d3exp_get_ind_12] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 10514(line=372, offs=4) -- 10603(line=374, offs=42) */ ATSstaticdec() ats_ptr_type d3explst_get_ind_13 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp119) ; __ats_lab_d3explst_get_ind_13: tmp119 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &d3exp_get_ind_12) ; return (tmp119) ; } /* end of [d3explst_get_ind_13] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_util.dats: 10685(line=380, offs=21) -- 10740(line=381, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp120) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind: tmp120 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_fun (arg0, &d3explst_get_ind_13) ; return (tmp120) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__d3explstlst_get_ind] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_pprint_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_util_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp3, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp4, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp5, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp6, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp7, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp8, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp10, sizeof(ats_ptr_type)) ; /* marking external values for GC */ ATS_GC_MARKROOT (&FLOATKINDfloat, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&FLOATKINDdouble, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&FLOATKINDdouble_long, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&FLOATKINDnone, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDuint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDlint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDulint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDllint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDullint, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT (&INTKINDnone, sizeof(ats_ptr_type)) ; /* code for dynamic loading */ statmp0 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDfloat_0) ; ATS_GC_MARKROOT(&FLOATKINDfloat, sizeof(ats_ptr_type)) ; FLOATKINDfloat = statmp0 ; statmp1 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_1) ; ATS_GC_MARKROOT(&FLOATKINDdouble, sizeof(ats_ptr_type)) ; FLOATKINDdouble = statmp1 ; statmp2 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDdouble_long_2) ; ATS_GC_MARKROOT(&FLOATKINDdouble_long, sizeof(ats_ptr_type)) ; FLOATKINDdouble_long = statmp2 ; statmp3 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FLOATKINDnone_3) ; ATS_GC_MARKROOT(&FLOATKINDnone, sizeof(ats_ptr_type)) ; FLOATKINDnone = statmp3 ; statmp4 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDint_0) ; ATS_GC_MARKROOT(&INTKINDint, sizeof(ats_ptr_type)) ; INTKINDint = statmp4 ; statmp5 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDuint_1) ; ATS_GC_MARKROOT(&INTKINDuint, sizeof(ats_ptr_type)) ; INTKINDuint = statmp5 ; statmp6 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDlint_2) ; ATS_GC_MARKROOT(&INTKINDlint, sizeof(ats_ptr_type)) ; INTKINDlint = statmp6 ; statmp7 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDulint_3) ; ATS_GC_MARKROOT(&INTKINDulint, sizeof(ats_ptr_type)) ; INTKINDulint = statmp7 ; statmp8 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDllint_4) ; ATS_GC_MARKROOT(&INTKINDllint, sizeof(ats_ptr_type)) ; INTKINDllint = statmp8 ; statmp9 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDullint_5) ; ATS_GC_MARKROOT(&INTKINDullint, sizeof(ats_ptr_type)) ; INTKINDullint = statmp9 ; statmp10 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__INTKINDnone_16) ; ATS_GC_MARKROOT(&INTKINDnone, sizeof(ats_ptr_type)) ; INTKINDnone = statmp10 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ ats_ptr_type atsopt_floatkind_eval (ats_ptr_type s0) { // char *s ; // s = s0 ; while (*s) { ++s ; } ; --s ; switch (*s) { case 'f': case 'F': return FLOATKINDfloat ; case 'd': case 'D': return FLOATKINDdouble ; case 'l': case 'L': return FLOATKINDdouble_long ; default : ; } return FLOATKINDnone ; } // end of [atsopt_floatkind_eval] ats_ptr_type atsopt_intkind_eval (ats_ptr_type s0) { // char c, *s ; int nL, nU ; // s = s0 ; nL = 0 ; nU = 0 ; while (c = *s) { s += 1 ; switch (c) { case 'l': case 'L': ++nL ; break ; case 'u': case 'U': ++nU ; break ; default : break ; } // end of [switch] } /* end of [while] */ // if (nL == 0) { if (nU == 0) return INTKINDint ; /* deadcode */ if (nU == 1) return INTKINDuint ; /* unsigned */ } // end of [if] // if (nL == 1) { if (nU == 0) return INTKINDlint ; /* long */ if (nU == 1) return INTKINDulint ; /* unsigned long */ } // end of [if] // if (nL == 2) { if (nU == 0) return INTKINDllint ; /* long long */ if (nU == 1) return INTKINDullint ; /* unsigned long long */ } // end of [if] // return INTKINDnone ; } // end of [atsopt_intkind_eval] /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_util_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp1_print_dats.c0000664000175000017500000025217612223166160022740 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_p1at_loc ; ats_ptr_type atslab_p1at_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_3 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_l0ab_loc ; ats_ptr_type atslab_l0ab_lab ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_d1exp_loc ; ats_ptr_type atslab_d1exp_node ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_16 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_17 ; typedef struct { ats_ptr_type atslab_tmpqi0de_loc ; ats_ptr_type atslab_tmpqi0de_qua ; ats_ptr_type atslab_tmpqi0de_sym ; } anairiats_rec_18 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_19 ; typedef struct { ats_ptr_type atslab_d1lab_loc ; ats_ptr_type atslab_d1lab_node ; } anairiats_rec_20 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDcross_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDdecode_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__MACSYNKINDencode_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTdot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABP1ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tany2_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tas_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tchar_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tempty_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Texist_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfloat_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tfree_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tint_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlist_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tlst_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tqid_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trec_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tref_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Trefas_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tstring_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Tsvararg_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__P1Ttup_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABlab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1LABind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__LABD1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_effc_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_funclo_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eann_type_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_dyn_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eapp_sta_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrinit_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrpsz_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Earrsub_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ebool_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecaseof_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Echar_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecstsp_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ecrypt_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edecseq_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Edynload_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eeffmask_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eempty_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eexist_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eextval_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efix_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloat_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efloatsp_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efoldat_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efor_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Efreeat_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eidextapp_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eif_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eint_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eintsp_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_dyn_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elaminit_dyn_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_met_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_ana_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elam_sta_syn_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elazy_delay_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elet_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elist_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eloopexn_37) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Elst_38) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Emacsyn_39) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eptrof_40) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eqid_41) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eraise_42) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Erec_43) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Escaseof_44) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esel_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eseq_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esexparg_47) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eshowtype_48) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Esif_49) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estring_50) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Estruct_51) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etmpid_52) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etop_53) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etrywith_54) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Etup_55) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Eviewat_56) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhere_57) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__D1Ewhile_58) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_bool) (ats_ref_type, ats_bool_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_tmps1explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labp1atlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labd1explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1lab) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type aux_5 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 1992(line=65, offs=13) -- 5515(line=180, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_int_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; // ATSlocal_void (tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; // ATSlocal_void (tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; // ATSlocal_void (tmp27) ; // ATSlocal_void (tmp28) ; ATSlocal (ats_char_type, tmp29) ; // ATSlocal_void (tmp30) ; // ATSlocal_void (tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; // ATSlocal_void (tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; // ATSlocal_void (tmp38) ; // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; // ATSlocal_void (tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_int_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; // ATSlocal_void (tmp48) ; // ATSlocal_void (tmp49) ; // ATSlocal_void (tmp50) ; // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_int_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; // ATSlocal_void (tmp65) ; // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; // ATSlocal_void (tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; // ATSlocal_void (tmp77) ; // ATSlocal_void (tmp78) ; // ATSlocal_void (tmp79) ; ATSlocal (ats_int_type, tmp80) ; ATSlocal (ats_int_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; // ATSlocal_void (tmp83) ; // ATSlocal_void (tmp84) ; // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; // ATSlocal_void (tmp87) ; // ATSlocal_void (tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_p1at_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tann(")) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp2) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp3) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tany()")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tany2()")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp1)->tag != 4) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; /* tmp9 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tapp_sta(")) ; /* tmp10 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp8) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp1)->tag != 3) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_2) ; tmp15 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_3) ; /* tmp16 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tapp_dyn(")) ; /* tmp17 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp13) ; /* tmp18 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp19 = */ atspre_fprint_int (arg0, tmp14) ; /* tmp20 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp21 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst (arg0, tmp15) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp1)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp22 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp24 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tas(")) ; tmp26 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp22), atslab_i0de_sym) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp26) ; /* tmp27 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp23) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp1)->tag != 6) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp29 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_0) ; /* tmp30 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tchar(")) ; /* tmp31 = */ atspre_fprint_char (arg0, tmp29) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp1)->tag != 7) { goto __ats_lab_8_0 ; } __ats_lab_7_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tempty()")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp1)->tag != 8) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp33 = */ atspre_fprint_string (arg0, ATSstrcst("P1Texist(")) ; /* tmp34 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp35 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp36 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp32) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp1)->tag != 9) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp38 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tfloat(")) ; /* tmp39 = */ atspre_fprint_string (arg0, tmp37) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp1)->tag != 10) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp41 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tfree(")) ; /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp40) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp1)->tag != 11) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp43 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp44 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tint(")) ; /* tmp45 = */ atspre_fprint_string (arg0, tmp43) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp1)->tag != 12) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_1) ; /* tmp48 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tlist(")) ; /* tmp49 = */ atspre_fprint_int (arg0, tmp46) ; /* tmp50 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst (arg0, tmp47) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp1)->tag != 13) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp53 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tlst(")) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst (arg0, tmp52) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp1)->tag != 14) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp56 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (arg0, tmp55) ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp56) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp1)->tag != 15) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_6, tmp1, atslab_1) ; /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst("P1Trec(")) ; /* tmp61 = */ atspre_fprint_int (arg0, tmp58) ; /* tmp62 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labp1atlst (arg0, tmp59) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp1)->tag != 16) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp65 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tref(")) ; tmp67 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp64), atslab_i0de_sym) ; /* tmp66 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp67) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp1)->tag != 17) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp68 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp69 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_1) ; /* tmp70 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tref(")) ; tmp72 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_3, tmp68), atslab_i0de_sym) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp72) ; /* tmp73 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp74 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp69) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp1)->tag != 18) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_5, tmp1, atslab_0) ; /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tstring(\"")) ; /* tmp77 = */ atspre_fprint_string (arg0, tmp75) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("\")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp1)->tag != 19) { goto __ats_lab_20_0 ; } __ats_lab_19_1: /* tmp78 = */ atspre_fprint_string (arg0, ATSstrcst("P1Tsvararg(")) ; /* tmp79 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (((ats_sum_ptr_type)tmp1)->tag != 20) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp80 = ats_caselptrlab_mac(anairiats_sum_7, tmp1, atslab_0) ; tmp81 = ats_caselptrlab_mac(anairiats_sum_7, tmp1, atslab_1) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_7, tmp1, atslab_2) ; /* tmp83 = */ atspre_fprint_string (arg0, ATSstrcst("P1Ttup(")) ; /* tmp84 = */ atspre_fprint_int (arg0, tmp80) ; /* tmp85 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp86 = */ atspre_fprint_int (arg0, tmp81) ; /* tmp87 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst (arg0, tmp82) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 5562(line=182, offs=22) -- 5598(line=182, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_p1at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; // ATSlocal_void (tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_p1at: tmp90 = atspre_stdout_get () ; tmp91 = ats_selsin_mac(tmp90, atslab_1) ; /* tmp92 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (tmp91, arg0) ; /* tmp89 = */ atspre_stdout_view_set () ; return /* (tmp89) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_p1at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 5620(line=183, offs=22) -- 5656(line=183, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_p1at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_p1at: tmp94 = atspre_stderr_get () ; tmp95 = ats_selsin_mac(tmp94, atslab_1) ; /* tmp96 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (tmp95, arg0) ; /* tmp93 = */ atspre_stderr_view_set () ; return /* (tmp93) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_p1at] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 5704(line=188, offs=16) -- 5778(line=189, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp97) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst: /* tmp97 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at) ; return /* (tmp97) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 5872(line=195, offs=7) -- 6401(line=211, offs=6) */ ATSstaticdec() ats_void_type aux_5 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; // ATSlocal_void (tmp103) ; ATSlocal (ats_bool_type, tmp104) ; // ATSlocal_void (tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; // ATSlocal_void (tmp108) ; ATSlocal (ats_int_type, tmp109) ; // ATSlocal_void (tmp110) ; ATSlocal (ats_bool_type, tmp111) ; __ats_lab_aux_5: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp101 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_2) ; tmp104 = atspre_gt_int_int (arg1, 0) ; if (tmp104) { /* tmp103 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp100), atslab_l0ab_lab) ; /* tmp105 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp106) ; /* tmp107 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp108 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp101) ; tmp109 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp109 ; arg2 = tmp102 ; goto __ats_lab_aux_5 ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (((ats_sum_ptr_type)arg2)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp111 = atspre_gt_int_int (arg1, 0) ; if (tmp111) { /* tmp110 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp99 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; break ; } while (0) ; return /* (tmp99) */ ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 5841(line=194, offs=7) -- 6447(line=214, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labp1atlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp98) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labp1atlst: /* tmp98 = */ aux_5 (arg0, 0, arg1) ; return /* (tmp98) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labp1atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 6523(line=219, offs=14) -- 18137(line=614, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; // ATSlocal_void (tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; // ATSlocal_void (tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; // ATSlocal_void (tmp128) ; // ATSlocal_void (tmp129) ; // ATSlocal_void (tmp130) ; // ATSlocal_void (tmp131) ; ATSlocal (ats_ptr_type, tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; // ATSlocal_void (tmp137) ; // ATSlocal_void (tmp138) ; // ATSlocal_void (tmp139) ; // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; // ATSlocal_void (tmp142) ; // ATSlocal_void (tmp143) ; // ATSlocal_void (tmp144) ; // ATSlocal_void (tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; // ATSlocal_void (tmp154) ; // ATSlocal_void (tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; // ATSlocal_void (tmp158) ; // ATSlocal_void (tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; ATSlocal (ats_bool_type, tmp169) ; // ATSlocal_void (tmp170) ; // ATSlocal_void (tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_char_type, tmp174) ; // ATSlocal_void (tmp175) ; // ATSlocal_void (tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; ATSlocal (ats_int_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; // ATSlocal_void (tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; // ATSlocal_void (tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; // ATSlocal_void (tmp208) ; ATSlocal (ats_int_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; // ATSlocal_void (tmp222) ; // ATSlocal_void (tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; // ATSlocal_void (tmp235) ; // ATSlocal_void (tmp236) ; // ATSlocal_void (tmp237) ; // ATSlocal_void (tmp238) ; // ATSlocal_void (tmp239) ; // ATSlocal_void (tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; // ATSlocal_void (tmp242) ; // ATSlocal_void (tmp243) ; // ATSlocal_void (tmp244) ; // ATSlocal_void (tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; // ATSlocal_void (tmp248) ; // ATSlocal_void (tmp249) ; // ATSlocal_void (tmp250) ; // ATSlocal_void (tmp251) ; // ATSlocal_void (tmp252) ; // ATSlocal_void (tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; // ATSlocal_void (tmp257) ; // ATSlocal_void (tmp258) ; // ATSlocal_void (tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; // ATSlocal_void (tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; // ATSlocal_void (tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; // ATSlocal_void (tmp267) ; // ATSlocal_void (tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; // ATSlocal_void (tmp270) ; // ATSlocal_void (tmp271) ; ATSlocal (ats_int_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; // ATSlocal_void (tmp275) ; // ATSlocal_void (tmp276) ; // ATSlocal_void (tmp277) ; // ATSlocal_void (tmp278) ; // ATSlocal_void (tmp279) ; // ATSlocal_void (tmp280) ; ATSlocal (ats_int_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; // ATSlocal_void (tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; // ATSlocal_void (tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; // ATSlocal_void (tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; ATSlocal (ats_ptr_type, tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; // ATSlocal_void (tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; // ATSlocal_void (tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; ATSlocal (ats_int_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; // ATSlocal_void (tmp308) ; // ATSlocal_void (tmp309) ; // ATSlocal_void (tmp310) ; // ATSlocal_void (tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; // ATSlocal_void (tmp318) ; // ATSlocal_void (tmp319) ; ATSlocal (ats_int_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; // ATSlocal_void (tmp322) ; // ATSlocal_void (tmp323) ; // ATSlocal_void (tmp324) ; // ATSlocal_void (tmp325) ; ATSlocal (ats_int_type, tmp326) ; // ATSlocal_void (tmp327) ; // ATSlocal_void (tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; // ATSlocal_void (tmp332) ; // ATSlocal_void (tmp333) ; // ATSlocal_void (tmp334) ; // ATSlocal_void (tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; // ATSlocal_void (tmp337) ; // ATSlocal_void (tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; // ATSlocal_void (tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; // ATSlocal_void (tmp347) ; // ATSlocal_void (tmp348) ; ATSlocal (ats_int_type, tmp349) ; // ATSlocal_void (tmp350) ; // ATSlocal_void (tmp351) ; // ATSlocal_void (tmp352) ; // ATSlocal_void (tmp353) ; // ATSlocal_void (tmp354) ; // ATSlocal_void (tmp355) ; ATSlocal (ats_int_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; // ATSlocal_void (tmp359) ; // ATSlocal_void (tmp360) ; // ATSlocal_void (tmp361) ; // ATSlocal_void (tmp362) ; // ATSlocal_void (tmp363) ; // ATSlocal_void (tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; // ATSlocal_void (tmp366) ; // ATSlocal_void (tmp367) ; // ATSlocal_void (tmp368) ; // ATSlocal_void (tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; // ATSlocal_void (tmp371) ; // ATSlocal_void (tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; // ATSlocal_void (tmp376) ; // ATSlocal_void (tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; // ATSlocal_void (tmp381) ; // ATSlocal_void (tmp382) ; // ATSlocal_void (tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_int_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; // ATSlocal_void (tmp387) ; // ATSlocal_void (tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; // ATSlocal_void (tmp391) ; // ATSlocal_void (tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; // ATSlocal_void (tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; // ATSlocal_void (tmp399) ; // ATSlocal_void (tmp400) ; // ATSlocal_void (tmp401) ; // ATSlocal_void (tmp402) ; ATSlocal (ats_int_type, tmp403) ; ATSlocal (ats_int_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; // ATSlocal_void (tmp406) ; // ATSlocal_void (tmp407) ; // ATSlocal_void (tmp408) ; // ATSlocal_void (tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; // ATSlocal_void (tmp413) ; // ATSlocal_void (tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; // ATSlocal_void (tmp416) ; // ATSlocal_void (tmp417) ; // ATSlocal_void (tmp418) ; // ATSlocal_void (tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; // ATSlocal_void (tmp422) ; // ATSlocal_void (tmp423) ; // ATSlocal_void (tmp424) ; // ATSlocal_void (tmp425) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp: tmp113 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_d1exp_node) ; do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp113)->tag != 0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp114 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp115 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp116 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eann_effc(")) ; /* tmp117 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp114) ; /* tmp118 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp119 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst (arg0, tmp115) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp113)->tag != 1) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp120 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp121 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp122 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eann_funclo(")) ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp120) ; /* tmp124 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp125 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp121) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp113)->tag != 2) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp126 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp127 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp128 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eann_type(")) ; /* tmp129 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp126) ; /* tmp130 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp131 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp127) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp113)->tag != 3) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp132 = ats_caselptrlab_mac(anairiats_sum_2, tmp113, atslab_0) ; tmp133 = ats_caselptrlab_mac(anairiats_sum_2, tmp113, atslab_2) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_2, tmp113, atslab_3) ; /* tmp135 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eapp_dyn(")) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp132) ; /* tmp137 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp138 = */ atspre_fprint_int (arg0, tmp133) ; /* tmp139 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp134) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp113)->tag != 4) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; /* tmp142 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eapp_sta(")) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp141) ; /* tmp144 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp145 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp113)->tag != 5) { goto __ats_lab_32_0 ; } __ats_lab_29_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_0) ; tmp147 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_1) ; tmp148 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("D1Earrinit(")) ; /* tmp150 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp146) ; /* tmp151 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp147 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp153 = ats_caselptrlab_mac(anairiats_sum_11, tmp147, atslab_0) ; /* tmp152 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp153) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (tmp147 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: break ; } while (0) ; /* tmp154 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp155 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp148) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp113)->tag != 6) { goto __ats_lab_35_0 ; } __ats_lab_32_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp157 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp158 = */ atspre_fprint_string (arg0, ATSstrcst("D1Earrpsz(")) ; do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (tmp156 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_11, tmp156, atslab_0) ; /* tmp159 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp160) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (tmp156 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: break ; } while (0) ; /* tmp161 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp162 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp157) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp113)->tag != 7) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp165 = */ atspre_fprint_string (arg0, ATSstrcst("D1Earrsub(")) ; /* tmp166 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp163) ; /* tmp167 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst (arg0, tmp164) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp113)->tag != 8) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_12, tmp113, atslab_0) ; /* tmp170 = */ atspre_fprint_string (arg0, ATSstrcst("D1Ebool(")) ; /* tmp171 = */ atspre_fprint_bool (arg0, tmp169) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp113)->tag != 9) { goto __ats_lab_38_0 ; } __ats_lab_37_1: /* tmp172 = */ atspre_fprint_string (arg0, ATSstrcst("D1Ecaseof(")) ; /* tmp173 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp113)->tag != 10) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_4, tmp113, atslab_0) ; /* tmp175 = */ atspre_fprint_string (arg0, ATSstrcst("D1Echar(")) ; /* tmp176 = */ atspre_fprint_char (arg0, tmp174) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp113)->tag != 11) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp178 = */ atspre_fprint_string (arg0, ATSstrcst("D1Ecstsp(")) ; /* tmp179 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (arg0, tmp177) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp113)->tag != 12) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_1) ; /* tmp182 = */ atspre_fprint_string (arg0, ATSstrcst("D1Ecrypt(")) ; /* tmp183 = */ atspre_fprint_int (arg0, tmp180) ; /* tmp184 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp181) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp113)->tag != 13) { goto __ats_lab_42_0 ; } __ats_lab_41_1: /* tmp186 = */ atspre_fprint_string (arg0, ATSstrcst("D1Edecseq(")) ; /* tmp187 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp113)->tag != 14) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp188 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp189 = */ atspre_fprint_string (arg0, ATSstrcst("D1Edynload(")) ; /* tmp190 = */ ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__fprint_filename (arg0, tmp188) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp113)->tag != 15) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp192 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp193 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eeffmask(")) ; /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst (arg0, tmp191) ; /* tmp195 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp196 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp192) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp113)->tag != 16) { goto __ats_lab_45_0 ; } __ats_lab_44_1: /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eempty()")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp113)->tag != 17) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp198 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eexist(")) ; /* tmp199 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp200 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp201 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp197) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp113)->tag != 18) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp204 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp202) ; /* tmp205 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp207 = */ atspre_fprint_string (arg0, tmp203) ; /* tmp208 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp113)->tag != 19) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_0) ; tmp210 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_1) ; tmp211 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_2) ; /* tmp212 = */ atspre_fprint_string (arg0, ATSstrcst("D1Efix(")) ; /* tmp213 = */ atspre_fprint_int (arg0, tmp209) ; /* tmp214 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp215 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (arg0, tmp210) ; /* tmp216 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp217 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp211) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp113)->tag != 20) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp219 = */ atspre_fprint_string (arg0, ATSstrcst("D1Efloat(")) ; /* tmp220 = */ atspre_fprint_string (arg0, tmp218) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp113)->tag != 21) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp222 = */ atspre_fprint_string (arg0, ATSstrcst("D1Efloatsp(")) ; /* tmp223 = */ atspre_fprint_string (arg0, tmp221) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: if (((ats_sum_ptr_type)tmp113)->tag != 22) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp224 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp225 = */ atspre_fprint_string (arg0, ATSstrcst("D1Efoldat(")) ; /* tmp226 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp227 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp224) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp113)->tag != 23) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp229 = ats_caselptrlab_mac(anairiats_sum_14, tmp113, atslab_1) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_14, tmp113, atslab_2) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_14, tmp113, atslab_3) ; tmp232 = ats_caselptrlab_mac(anairiats_sum_14, tmp113, atslab_4) ; /* tmp233 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp234 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp235 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp229) ; /* tmp236 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp237 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp230) ; /* tmp238 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp239 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp231) ; /* tmp240 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; arg0 = arg0 ; arg1 = tmp232 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp ; // tail call break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp113)->tag != 24) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp241 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp242 = */ atspre_fprint_string (arg0, ATSstrcst("D1Efreeat(")) ; /* tmp243 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp244 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp245 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp241) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)tmp113)->tag != 25) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp246 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_0) ; tmp247 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp248 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eidextall(")) ; /* tmp249 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp246) ; /* tmp250 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp251 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp252 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp253 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp247) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)tmp113)->tag != 26) { goto __ats_lab_57_0 ; } __ats_lab_54_1: tmp254 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_1) ; tmp255 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_2) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_3) ; /* tmp257 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eif(")) ; /* tmp258 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp259 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp260 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp254) ; /* tmp261 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp262 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp255) ; do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (tmp256 == (ats_sum_ptr_type)0) { goto __ats_lab_56_0 ; } __ats_lab_55_1: tmp264 = ats_caselptrlab_mac(anairiats_sum_11, tmp256, atslab_0) ; /* tmp265 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp263 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp264) ; break ; /* branch: __ats_lab_56 */ __ats_lab_56_0: // if (tmp256 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_56_1: break ; } while (0) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: if (((ats_sum_ptr_type)tmp113)->tag != 27) { goto __ats_lab_58_0 ; } __ats_lab_57_1: tmp266 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp267 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eint(")) ; /* tmp268 = */ atspre_fprint_string (arg0, tmp266) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)tmp113)->tag != 28) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp269 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp270 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eintsp(")) ; /* tmp271 = */ atspre_fprint_string (arg0, tmp269) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp113)->tag != 29) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_0) ; tmp273 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_1) ; tmp274 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_2) ; /* tmp275 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elam_dyn(")) ; /* tmp276 = */ atspre_fprint_int (arg0, tmp272) ; /* tmp277 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp278 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp273) ; /* tmp279 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp280 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp274) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp113)->tag != 30) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_0) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_1) ; tmp283 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_2) ; /* tmp284 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elaminit_dyn(")) ; /* tmp285 = */ atspre_fprint_int (arg0, tmp281) ; /* tmp286 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp287 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_p1at (arg0, tmp282) ; /* tmp288 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp289 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp283) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)tmp113)->tag != 31) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp290 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_1) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp292 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elam_met(")) ; /* tmp293 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp290) ; /* tmp294 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp291) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp113)->tag != 32) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp296 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp297 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elam_sta_ana(")) ; /* tmp298 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp299 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp300 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp296) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: if (((ats_sum_ptr_type)tmp113)->tag != 33) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp301 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp302 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elam_sta_syn(")) ; /* tmp303 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp304 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp305 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp301) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp113)->tag != 34) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp306 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_0) ; tmp307 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_1) ; /* tmp308 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elazy_delay(")) ; /* tmp309 = */ atspre_fprint_int (arg0, tmp306) ; /* tmp310 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp311 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp307) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)tmp113)->tag != 35) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp312 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp313 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elet(")) ; /* tmp314 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp315 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp316 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp312) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: if (((ats_sum_ptr_type)tmp113)->tag != 40) { goto __ats_lab_67_0 ; } __ats_lab_66_1: tmp317 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp318 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eptrof(")) ; /* tmp319 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp317) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)tmp113)->tag != 36) { goto __ats_lab_68_0 ; } __ats_lab_67_1: tmp320 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_0) ; tmp321 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_1) ; /* tmp322 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elist(")) ; /* tmp323 = */ atspre_fprint_int (arg0, tmp320) ; /* tmp324 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp325 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp321) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp113)->tag != 37) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp326 = ats_caselptrlab_mac(anairiats_sum_16, tmp113, atslab_0) ; /* tmp327 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eloopexn(")) ; /* tmp328 = */ atspre_fprint_int (arg0, tmp326) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: if (((ats_sum_ptr_type)tmp113)->tag != 38) { goto __ats_lab_72_0 ; } __ats_lab_69_1: tmp329 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_0) ; tmp330 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_1) ; tmp331 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_2) ; /* tmp332 = */ atspre_fprint_string (arg0, ATSstrcst("D1Elst(")) ; /* tmp333 = */ atspre_fprint_int (arg0, tmp329) ; /* tmp334 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_70 */ __ats_lab_70_0: if (tmp330 == (ats_sum_ptr_type)0) { goto __ats_lab_71_0 ; } __ats_lab_70_1: tmp336 = ats_caselptrlab_mac(anairiats_sum_11, tmp330, atslab_0) ; /* tmp337 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp336) ; /* tmp335 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; break ; /* branch: __ats_lab_71 */ __ats_lab_71_0: // if (tmp330 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_71_1: break ; } while (0) ; /* tmp338 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp331) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp113)->tag != 39) { goto __ats_lab_76_0 ; } __ats_lab_72_1: tmp339 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp339)->tag != 0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: /* tmp341 = */ atspre_fprint_string (arg0, ATSstrcst("%(")) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp339)->tag != 1) { goto __ats_lab_75_0 ; } __ats_lab_74_1: /* tmp341 = */ atspre_fprint_string (arg0, ATSstrcst(",(")) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (((ats_sum_ptr_type)tmp339)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: /* tmp341 = */ atspre_fprint_string (arg0, ATSstrcst("`(")) ; break ; } while (0) ; /* tmp342 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp340) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: if (((ats_sum_ptr_type)tmp113)->tag != 41) { goto __ats_lab_77_0 ; } __ats_lab_76_1: tmp343 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (arg0, tmp343) ; /* tmp112 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp344) ; break ; /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp113)->tag != 42) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp346 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp347 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eraise(")) ; /* tmp348 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp346) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp113)->tag != 43) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_6, tmp113, atslab_0) ; /* tmp350 = */ atspre_fprint_string (arg0, ATSstrcst("D1Erec(")) ; /* tmp351 = */ atspre_fprint_int (arg0, tmp349) ; /* tmp352 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp353 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)tmp113)->tag != 44) { goto __ats_lab_80_0 ; } __ats_lab_79_1: /* tmp354 = */ atspre_fprint_string (arg0, ATSstrcst("D1Escaseof(")) ; /* tmp355 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp113)->tag != 45) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_0) ; tmp357 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_1) ; tmp358 = ats_caselptrlab_mac(anairiats_sum_13, tmp113, atslab_2) ; /* tmp359 = */ atspre_fprint_string (arg0, ATSstrcst("D1Esel(")) ; /* tmp360 = */ atspre_fprint_int (arg0, tmp356) ; /* tmp361 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp362 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp357) ; /* tmp363 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp364 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1lab (arg0, tmp358) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: if (((ats_sum_ptr_type)tmp113)->tag != 46) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp365 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp366 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eseq(")) ; /* tmp367 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp365) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)tmp113)->tag != 47) { goto __ats_lab_83_0 ; } __ats_lab_82_1: /* tmp368 = */ atspre_fprint_string (arg0, ATSstrcst("D1Esexparg(")) ; /* tmp369 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)tmp113)->tag != 48) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp371 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eshowtype(")) ; /* tmp372 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp370) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)tmp113)->tag != 49) { goto __ats_lab_85_0 ; } __ats_lab_84_1: tmp373 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_1) ; tmp374 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_2) ; tmp375 = ats_caselptrlab_mac(anairiats_sum_15, tmp113, atslab_3) ; /* tmp376 = */ atspre_fprint_string (arg0, ATSstrcst("D1Esif(")) ; /* tmp377 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp378 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp379 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp373) ; /* tmp380 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp381 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp374) ; /* tmp382 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp383 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp375) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)tmp113)->tag != 50) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp384 = ats_caselptrlab_mac(anairiats_sum_17, tmp113, atslab_0) ; tmp385 = ats_caselptrlab_mac(anairiats_sum_17, tmp113, atslab_1) ; /* tmp112 = */ atspre_fprintf_exn (arg0, ATSstrcst("D1Estring(\"%s\", %i)"), tmp384, tmp385) ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)tmp113)->tag != 51) { goto __ats_lab_87_0 ; } __ats_lab_86_1: tmp386 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp387 = */ atspre_fprint_string (arg0, ATSstrcst("D1Estruct(")) ; /* tmp388 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labd1explst (arg0, tmp386) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)tmp113)->tag != 52) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp389 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; tmp390 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_1) ; /* tmp391 = */ atspre_fprint_string (arg0, ATSstrcst("D1Etmpid(")) ; tmp393 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp389), atslab_tmpqi0de_qua) ; /* tmp392 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_d0ynq (arg0, tmp393) ; tmp395 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_18, tmp389), atslab_tmpqi0de_sym) ; /* tmp394 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp395) ; /* tmp396 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp397 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_tmps1explstlst (arg0, tmp390) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp113)->tag != 53) { goto __ats_lab_89_0 ; } __ats_lab_88_1: /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst("D1Etop()")) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp113)->tag != 54) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp398 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_1) ; /* tmp399 = */ atspre_fprint_string (arg0, ATSstrcst("D1Etrywith(")) ; /* tmp400 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp398) ; /* tmp401 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp402 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)tmp113)->tag != 55) { goto __ats_lab_91_0 ; } __ats_lab_90_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_7, tmp113, atslab_0) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_7, tmp113, atslab_1) ; tmp405 = ats_caselptrlab_mac(anairiats_sum_7, tmp113, atslab_2) ; /* tmp406 = */ atspre_fprint_string (arg0, ATSstrcst("D1Etup(")) ; /* tmp407 = */ atspre_fprint_int (arg0, tmp403) ; /* tmp408 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp409 = */ atspre_fprint_int (arg0, tmp404) ; /* tmp410 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp411 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (arg0, tmp405) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: if (((ats_sum_ptr_type)tmp113)->tag != 56) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp412 = ats_caselptrlab_mac(anairiats_sum_5, tmp113, atslab_0) ; /* tmp413 = */ atspre_fprint_string (arg0, ATSstrcst("D1Eviewat(")) ; /* tmp414 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp412) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: if (((ats_sum_ptr_type)tmp113)->tag != 57) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp415 = ats_caselptrlab_mac(anairiats_sum_1, tmp113, atslab_0) ; /* tmp416 = */ atspre_fprint_string (arg0, ATSstrcst("D1Ewhere(")) ; /* tmp417 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp415) ; /* tmp418 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp419 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp112 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: // if (((ats_sum_ptr_type)tmp113)->tag != 58) { ats_deadcode_failure_handle () ; } __ats_lab_93_1: tmp420 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_1) ; tmp421 = ats_caselptrlab_mac(anairiats_sum_8, tmp113, atslab_2) ; /* tmp422 = */ atspre_fprint_string (arg0, ATSstrcst("...")) ; /* tmp423 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp424 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp420) ; /* tmp425 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; arg0 = arg0 ; arg1 = tmp421 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp ; // tail call break ; } while (0) ; return /* (tmp112) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18186(line=616, offs=23) -- 18223(line=616, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_d1exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; // ATSlocal_void (tmp429) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_d1exp: tmp427 = atspre_stdout_get () ; tmp428 = ats_selsin_mac(tmp427, atslab_1) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (tmp428, arg0) ; /* tmp426 = */ atspre_stdout_view_set () ; return /* (tmp426) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__print_d1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18246(line=617, offs=23) -- 18283(line=617, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_d1exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_ptr_type, tmp432) ; // ATSlocal_void (tmp433) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_d1exp: tmp431 = atspre_stderr_get () ; tmp432 = ats_selsin_mac(tmp431, atslab_1) ; /* tmp433 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (tmp432, arg0) ; /* tmp430 = */ atspre_stderr_view_set () ; return /* (tmp430) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__prerr_d1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18332(line=622, offs=17) -- 18408(line=623, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp434) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst: /* tmp434 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp) ; return /* (tmp434) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18467(line=627, offs=20) -- 18549(line=628, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp435) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst: /* tmp435 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst("; "), &ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explst) ; return /* (tmp435) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18648(line=634, offs=7) -- 19074(line=647, offs=6) */ ATSstaticdec() ats_void_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; // ATSlocal_void (tmp441) ; ATSlocal (ats_bool_type, tmp442) ; // ATSlocal_void (tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; // ATSlocal_void (tmp445) ; // ATSlocal_void (tmp446) ; ATSlocal (ats_int_type, tmp447) ; __ats_lab_aux_12: do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp438 = ats_caselptrlab_mac(anairiats_sum_19, arg2, atslab_0) ; tmp439 = ats_caselptrlab_mac(anairiats_sum_19, arg2, atslab_1) ; tmp440 = ats_caselptrlab_mac(anairiats_sum_19, arg2, atslab_2) ; tmp442 = atspre_gt_int_int (arg1, 0) ; if (tmp442) { /* tmp441 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ tmp444 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp438), atslab_l0ab_lab) ; /* tmp443 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp444) ; /* tmp445 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp446 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1exp (arg0, tmp439) ; tmp447 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp447 ; arg2 = tmp440 ; goto __ats_lab_aux_12 ; // tail call break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_95_1: break ; } while (0) ; return /* (tmp437) */ ; } /* end of [aux_12] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 18617(line=633, offs=7) -- 19120(line=650, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labd1explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp436) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labd1explst: /* tmp436 = */ aux_12 (arg0, 0, arg1) ; return /* (tmp436) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_labd1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp1_print.dats: 19197(line=655, offs=14) -- 19471(line=663, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1lab (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; // ATSlocal_void (tmp452) ; // ATSlocal_void (tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1lab: tmp449 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_20, arg1), atslab_d1lab_node) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (((ats_sum_ptr_type)tmp449)->tag != 0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_5, tmp449, atslab_0) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp450) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (((ats_sum_ptr_type)tmp449)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp451 = ats_caselptrlab_mac(anairiats_sum_5, tmp449, atslab_0) ; /* tmp452 = */ atspre_fprint_string (arg0, ATSstrcst("[")) ; /* tmp453 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1explstlst (arg0, tmp451) ; /* tmp448 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; break ; } while (0) ; return /* (tmp448) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__fprint_d1lab] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp1_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp1_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_util_dats.c0000664000175000017500000015315212223166160022264 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_1 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_branch_lab ; ats_ptr_type atslab_branch_inss ; } anairiats_rec_4 ; typedef struct { ats_ptr_type atslab_instr_loc ; ats_ptr_type atslab_instr_node ; } anairiats_rec_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; ats_ptr_type atslab_6 ; ats_ptr_type atslab_7 ; } anairiats_sum_11 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_13 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_14 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_heap_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRarr_stack_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRassgn_clo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcall_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRcond_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRfunction_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_ptr_offs_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRload_var_offs_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRloop_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_con_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_delay_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_lazy_force_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_box_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_rec_flt_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_ref_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRmove_val_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRraise_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselect_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRselcon_ptr_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRswitch_36) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRtrywith_45) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__INSTRvardec_46) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__TAILJOINLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_tmpvar_tmpvar) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_tmpvar_set_top) (ats_ptr_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__sasp__tmpvarmap_vt = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_ptr_type bst_search_057_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01690_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type bst_size_029_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_034_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_068_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01688_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_void_type tmpvarmap_add_0 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type tmpvarmap_addlst_7 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type f_9 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type bst_foreach_inf_0132_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_void_type map_foreach_inf_01693_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type _emit_tmpvarmap_dec_8 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type f_13 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_int_type _emit_tmpvarmap_markroot_12 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type bst_free_025_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_void_type map_free_01686_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) ; static ats_void_type aux_branchlst_19 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_26 (ats_ref_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_057_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_int_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_int_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; __ats_lab_bst_search_057_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_0_1: tmp6 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp7 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_2) ; tmp8 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp9 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp10 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg2) (arg1, tmp6) ; do { /* branch: __ats_lab_1 */ __ats_lab_1_0: if (tmp10 != -1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp11 = ats_ptrget_mac(ats_ptr_type, tmp8) ; arg0 = tmp11 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_057_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp10 != 1) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp12 = ats_ptrget_mac(ats_ptr_type, tmp9) ; arg0 = tmp12 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_057_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (tmp10 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp5 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ats_selptrset_mac(anairiats_sum_2, tmp5, atslab_0, tmp7) ; break ; } while (0) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_4_1: tmp5 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp5) ; } /* end of [bst_search_057_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01690_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_map_search_01690_ats_ptr_type_2cats_int_type: // tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp4 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp13 = ats_ptrget_mac(ats_ptr_type, tmp4) ; tmp2 = bst_search_057_ats_ptr_type_2cats_int_type (tmp13, arg1, tmp3) ; return (tmp2) ; } /* end of [map_search_01690_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_029_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; __ats_lab_bst_size_029_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp40 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp39 = tmp40 ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp39 = 0 ; break ; } while (0) ; return (tmp39) ; } /* end of [bst_size_029_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_034_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_bool_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_int_type, tmp37) ; ATSlocal (ats_int_type, tmp38) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_int_type, tmp43) ; ATSlocal (ats_int_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_int_type, tmp50) ; ATSlocal (ats_int_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_int_type, tmp54) ; ATSlocal (ats_int_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; __ats_lab_bst_insert_atroot_034_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_8_1: tmp26 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp28 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp29 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp31 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp27) ; tmp30 = atspre_ilte (tmp31, 0) ; if (tmp30) { tmp33 = ats_ptrget_mac(ats_ptr_type, tmp28) ; tmp32 = bst_insert_atroot_034_ats_ptr_type_2cats_int_type (tmp33, arg1, arg2, arg3) ; // if (tmp32 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp34 = &ats_caselptrlab_mac(anairiats_sum_1, tmp32, atslab_0) ; tmp35 = &ats_caselptrlab_mac(anairiats_sum_1, tmp32, atslab_3) ; tmp36 = &ats_caselptrlab_mac(anairiats_sum_1, tmp32, atslab_4) ; tmp37 = ats_ptrget_mac(ats_int_type, tmp26) ; tmp41 = ats_ptrget_mac(ats_ptr_type, tmp35) ; tmp38 = bst_size_029_ats_ptr_type_2cats_int_type (tmp41) ; tmp42 = ats_ptrget_mac(ats_ptr_type, tmp36) ; ats_ptrget_mac(ats_ptr_type, tmp28) = tmp42 ; tmp43 = atspre_isub (tmp37, tmp38) ; ats_ptrget_mac(ats_int_type, tmp26) = tmp43 ; ats_ptrget_mac(ats_ptr_type, tmp36) = arg0 ; tmp44 = atspre_iadd (tmp37, 1) ; ats_ptrget_mac(ats_int_type, tmp34) = tmp44 ; tmp25 = tmp32 ; } else { tmp46 = ats_ptrget_mac(ats_ptr_type, tmp29) ; tmp45 = bst_insert_atroot_034_ats_ptr_type_2cats_int_type (tmp46, arg1, arg2, arg3) ; // if (tmp45 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp47 = &ats_caselptrlab_mac(anairiats_sum_1, tmp45, atslab_0) ; tmp48 = &ats_caselptrlab_mac(anairiats_sum_1, tmp45, atslab_3) ; tmp49 = &ats_caselptrlab_mac(anairiats_sum_1, tmp45, atslab_4) ; tmp50 = ats_ptrget_mac(ats_int_type, tmp26) ; tmp52 = ats_ptrget_mac(ats_ptr_type, tmp49) ; tmp51 = bst_size_029_ats_ptr_type_2cats_int_type (tmp52) ; tmp53 = ats_ptrget_mac(ats_ptr_type, tmp48) ; ats_ptrget_mac(ats_ptr_type, tmp29) = tmp53 ; tmp54 = atspre_isub (tmp50, tmp51) ; ats_ptrget_mac(ats_int_type, tmp26) = tmp54 ; ats_ptrget_mac(ats_ptr_type, tmp48) = arg0 ; tmp55 = atspre_iadd (tmp50, 1) ; ats_ptrget_mac(ats_int_type, tmp47) = tmp55 ; tmp25 = tmp45 ; } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp56 = (ats_sum_ptr_type)0 ; tmp57 = (ats_sum_ptr_type)0 ; tmp25 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp25, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp25, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp25, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp25, atslab_3, tmp56) ; ats_selptrset_mac(anairiats_sum_1, tmp25, atslab_4, tmp57) ; break ; } while (0) ; return (tmp25) ; } /* end of [bst_insert_atroot_034_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_068_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_bool_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_bool_type, tmp58) ; ATSlocal (ats_int_type, tmp59) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_int_type, tmp62) ; ATSlocal (ats_int_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_int_type, tmp66) ; ATSlocal (ats_int_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_bst_insert_random_068_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_7_1: tmp19 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp20 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp21 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp22 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp24 = ats_ptrget_mac(ats_int_type, tmp19) ; tmp23 = atsopt_map_lin_dice (1, tmp24) ; if (tmp23) { tmp18 = bst_insert_atroot_034_ats_ptr_type_2cats_int_type (arg0, arg1, arg2, arg3) ; } else { tmp59 = ((ats_int_type(*)(ats_ptr_type, ats_ptr_type))arg3) (arg1, tmp20) ; tmp58 = atspre_ilte (tmp59, 0) ; if (tmp58) { tmp61 = ats_ptrget_mac(ats_ptr_type, tmp21) ; tmp60 = bst_insert_random_068_ats_ptr_type_2cats_int_type (tmp61, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp21) = tmp60 ; tmp63 = ats_ptrget_mac(ats_int_type, tmp19) ; tmp62 = atspre_iadd (tmp63, 1) ; ats_ptrget_mac(ats_int_type, tmp19) = tmp62 ; tmp18 = arg0 ; } else { tmp65 = ats_ptrget_mac(ats_ptr_type, tmp22) ; tmp64 = bst_insert_random_068_ats_ptr_type_2cats_int_type (tmp65, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp22) = tmp64 ; tmp67 = ats_ptrget_mac(ats_int_type, tmp19) ; tmp66 = atspre_iadd (tmp67, 1) ; ats_ptrget_mac(ats_int_type, tmp19) = tmp66 ; tmp18 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp68 = (ats_sum_ptr_type)0 ; tmp69 = (ats_sum_ptr_type)0 ; tmp18 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp18, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_1, tmp18, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp18, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_1, tmp18, atslab_3, tmp68) ; ats_selptrset_mac(anairiats_sum_1, tmp18, atslab_4, tmp69) ; break ; } while (0) ; return (tmp18) ; } /* end of [bst_insert_random_068_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01688_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ // ATSlocal_void (tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp70) ; __ats_lab_map_insert_01688_ats_ptr_type_2cats_int_type: // tmp15 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp16 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp70 = ats_ptrget_mac(ats_ptr_type, tmp16) ; tmp17 = bst_insert_random_068_ats_ptr_type_2cats_int_type (tmp70, arg1, arg2, tmp15) ; ats_ptrget_mac(ats_ptr_type, tmp16) = tmp17 ; return /* (tmp14) */ ; } /* end of [map_insert_01688_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 1791(line=54, offs=4) -- 1957(line=58, offs=4) */ ATSstaticdec() ats_void_type tmpvarmap_add_0 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_tmpvarmap_add_0: tmp1 = map_search_01690_ats_ptr_type_2cats_int_type (ats_ptrget_mac(ats_ptr_type, arg0), arg1) ; do { /* branch: __ats_lab_5 */ __ats_lab_5_0: if (tmp1 == (ats_sum_ptr_type)0) { goto __ats_lab_6_0 ; } __ats_lab_5_1: ATS_FREE(tmp1) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (tmp1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: /* tmp0 = */ map_insert_01688_ats_ptr_type_2cats_int_type (ats_ptrget_mac(ats_ptr_type, arg0), arg1, 0) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [tmpvarmap_add_0] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 1989(line=60, offs=5) -- 2218(line=67, offs=4) */ ATSstaticdec() ats_void_type tmpvarmap_addlst_7 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; // ATSlocal_void (tmp74) ; __ats_lab_tmpvarmap_addlst_7: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp73 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp74 = */ tmpvarmap_add_0 (arg0, tmp72) ; arg0 = arg0 ; arg1 = tmp73 ; goto __ats_lab_tmpvarmap_addlst_7 ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: break ; } while (0) ; return /* (tmp71) */ ; } /* end of [tmpvarmap_addlst_7] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 2719(line=93, offs=6) -- 3996(line=126, offs=6) */ ATSstaticdec() ats_void_type f_9 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; ATSlocal (ats_int_type, tmp80) ; // ATSlocal_void (tmp81) ; ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_bool_type, tmp85) ; // ATSlocal_void (tmp86) ; ATSlocal (ats_bool_type, tmp87) ; // ATSlocal_void (tmp88) ; ATSlocal (ats_bool_type, tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_bool_type, tmp92) ; // ATSlocal_void (tmp93) ; ATSlocal (ats_bool_type, tmp94) ; // ATSlocal_void (tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; // ATSlocal_void (tmp97) ; // ATSlocal_void (tmp98) ; __ats_lab_f_9: // tmp78 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp79 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp80 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp82 = atspre_eq_int_int (tmp80, 1) ; if (tmp82) { /* tmp81 = */ atsopt_tmpvar_set_top (arg0, 1) ; } else { /* empty */ } /* end of [if] */ tmp84 = ats_ptrget_mac(ats_int_type, tmp79) ; tmp83 = atspre_add_int_int (tmp84, 1) ; ats_ptrget_mac(ats_int_type, tmp79) = tmp83 ; do { /* branch: __ats_lab_15 */ __ats_lab_15_0: __ats_lab_15_1: tmp85 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (arg0) ; if (!tmp85) { goto __ats_lab_16_1 ; } tmp87 = atspre_eq_int_int (tmp80, 0) ; if (tmp87) { /* tmp86 = */ atspre_fprint_string (tmp78, ATSstrcst("// ATSlocal_void (")) ; } else { /* empty */ } /* end of [if] */ tmp89 = atspre_eq_int_int (tmp80, 1) ; if (tmp89) { /* tmp88 = */ atspre_fprint_string (tmp78, ATSstrcst("// ATSstatic_void (")) ; } else { /* empty */ } /* end of [if] */ /* tmp90 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (tmp78, arg0) ; /* tmp77 = */ atspre_fprint_string (tmp78, ATSstrcst(") ;\n")) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp92 = atspre_eq_int_int (tmp80, 0) ; if (tmp92) { /* tmp91 = */ atspre_fprint_string (tmp78, ATSstrcst("ATSlocal (")) ; } else { /* empty */ } /* end of [if] */ tmp94 = atspre_eq_int_int (tmp80, 1) ; if (tmp94) { /* tmp93 = */ atspre_fprint_string (tmp78, ATSstrcst("ATSstatic (")) ; } else { /* empty */ } /* end of [if] */ tmp96 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (arg0) ; /* tmp95 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp78, tmp96) ; /* tmp97 = */ atspre_fprint_string (tmp78, ATSstrcst(", ")) ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (tmp78, arg0) ; /* tmp77 = */ atspre_fprint_string (tmp78, ATSstrcst(") ;\n")) ; break ; } while (0) ; return /* (tmp77) */ ; } /* end of [f_9] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8937(line=300, offs=25) -- 9308(line=314, offs=4) */ ATSstaticdec() ats_void_type bst_foreach_inf_0132_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (ats_int_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; // ATSlocal_void (tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_bst_foreach_inf_0132_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp104 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_2) ; tmp106 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp107 = &ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; tmp109 = ats_ptrget_mac(ats_ptr_type, tmp106) ; /* tmp108 = */ bst_foreach_inf_0132_ats_ptr_type_2cats_int_type (tmp109, arg1, arg2) ; /* tmp110 = */ ((ats_void_type(*)(ats_ptr_type, ats_int_type, ats_ptr_type))arg1) (tmp104, tmp105, arg2) ; tmp111 = ats_ptrget_mac(ats_ptr_type, tmp107) ; arg0 = tmp111 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_foreach_inf_0132_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: break ; } while (0) ; return /* (tmp103) */ ; } /* end of [bst_foreach_inf_0132_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 11800(line=406, offs=17) -- 11939(line=411, offs=4) */ ATSstaticdec() ats_void_type map_foreach_inf_01693_ats_ptr_type_2cats_int_type (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_ptr_type, tmp112) ; __ats_lab_map_foreach_inf_01693_ats_ptr_type_2cats_int_type: // tmp102 = &ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp112 = ats_ptrget_mac(ats_ptr_type, tmp102) ; /* tmp101 = */ bst_foreach_inf_0132_ats_ptr_type_2cats_int_type (tmp112, arg1, arg2) ; return /* (tmp101) */ ; } /* end of [map_foreach_inf_01693_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 2447(line=83, offs=4) -- 4249(line=134, offs=4) */ ATSstaticdec() ats_int_type _emit_tmpvarmap_dec_8 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp75) ; ATSlocal (ats_int_type, tmp76) ; ATSlocal (ats_ptr_type, tmp99) ; // ATSlocal_void (tmp100) ; __ats_lab__emit_tmpvarmap_dec_8: /* ats_int_type tmp76 ; */ tmp76 = 0 ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp99, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_3, tmp99, atslab_1, (&tmp76)) ; ats_selptrset_mac(anairiats_sum_3, tmp99, atslab_2, arg1) ; /* tmp100 = */ map_foreach_inf_01693_ats_ptr_type_2cats_int_type (arg2, &f_9, tmp99) ; // ATS_FREE(tmp99) ; tmp75 = tmp76 ; return (tmp75) ; } /* end of [_emit_tmpvarmap_dec_8] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 4636(line=149, offs=6) -- 5314(line=166, offs=6) */ ATSstaticdec() ats_void_type f_13 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; ATSlocal (ats_int_type, tmp119) ; ATSlocal (ats_bool_type, tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; __ats_lab_f_13: // tmp116 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp117 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp119 = ats_ptrget_mac(ats_int_type, tmp117) ; tmp118 = atspre_add_int_int (tmp119, 1) ; ats_ptrget_mac(ats_int_type, tmp117) = tmp118 ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp120 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_is_void (arg0) ; if (!tmp120) { goto __ats_lab_20_1 ; } break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: /* tmp121 = */ atspre_fprint_string (tmp116, ATSstrcst("ATS_GC_MARKROOT(&")) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvar (tmp116, arg0) ; /* tmp123 = */ atspre_fprint_string (tmp116, ATSstrcst(", sizeof(")) ; tmp125 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvar_get_typ (arg0) ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_hityp (tmp116, tmp125) ; /* tmp115 = */ atspre_fprint_string (tmp116, ATSstrcst(")) ;\n")) ; break ; } while (0) ; return /* (tmp115) */ ; } /* end of [f_13] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 4394(line=142, offs=4) -- 5559(line=174, offs=4) */ ATSstaticdec() ats_int_type _emit_tmpvarmap_markroot_12 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp113) ; ATSlocal (ats_int_type, tmp114) ; ATSlocal (ats_ptr_type, tmp126) ; // ATSlocal_void (tmp127) ; __ats_lab__emit_tmpvarmap_markroot_12: /* ats_int_type tmp114 ; */ tmp114 = 0 ; tmp126 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp126, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp126, atslab_1, (&tmp114)) ; /* tmp127 = */ map_foreach_inf_01693_ats_ptr_type_2cats_int_type (arg1, &f_13, tmp126) ; // ATS_FREE(tmp126) ; tmp113 = tmp114 ; return (tmp113) ; } /* end of [_emit_tmpvarmap_markroot_12] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 5688(line=183, offs=15) -- 5746(line=184, offs=54) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil () { /* local vardec */ ATSlocal (ats_ptr_type, tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil: tmp128 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__compare_tmpvar_tmpvar) ; return (tmp128) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_nil] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_025_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp132) ; ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; // ATSlocal_void (tmp135) ; __ats_lab_bst_free_025_ats_ptr_type_2cats_int_type: do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_22_0 ; } __ats_lab_21_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_3) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp135 = */ bst_free_025_ats_ptr_type_2cats_int_type (tmp133) ; arg0 = tmp134 ; goto __ats_lab_bst_free_025_ats_ptr_type_2cats_int_type ; // tail call break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_22_1: break ; } while (0) ; return /* (tmp132) */ ; } /* end of [bst_free_025_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9593(line=329, offs=10) -- 9649(line=330, offs=51) */ ATSstaticdec() ats_void_type map_free_01686_ats_ptr_type_2cats_int_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; __ats_lab_map_free_01686_ats_ptr_type_2cats_int_type: // tmp131 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; ATS_FREE(arg0) ; /* tmp130 = */ bst_free_025_ats_ptr_type_2cats_int_type (tmp131) ; return /* (tmp130) */ ; } /* end of [map_free_01686_ats_ptr_type_2cats_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 5800(line=187, offs=26) -- 5828(line=187, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp129) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free: /* tmp129 = */ map_free_01686_ats_ptr_type_2cats_int_type (arg0) ; return /* (tmp129) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tmpvarmap_free] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 5903(line=193, offs=7) -- 6175(line=201, offs=6) */ ATSstaticdec() ats_void_type aux_branchlst_19 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; // ATSlocal_void (tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; __ats_lab_aux_branchlst_19: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp138 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp139 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp141 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, tmp138), atslab_branch_inss) ; /* tmp140 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp141) ; arg0 = arg0 ; arg1 = tmp139 ; goto __ats_lab_aux_branchlst_19 ; // tail call break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: break ; } while (0) ; return /* (tmp137) */ ; } /* end of [aux_branchlst_19] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 5882(line=192, offs=21) -- 8605(line=263, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; // ATSlocal_void (tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; // ATSlocal_void (tmp181) ; // ATSlocal_void (tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add: tmp142 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_instr_node) ; do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp142)->tag != 0) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_6, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp143) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp142)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp144 = ats_caselptrlab_mac(anairiats_sum_7, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp144) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp142)->tag != 3) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp145 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_1) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp145) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp142)->tag != 4) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp146 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp146) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)tmp142)->tag != 6) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp147 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_1) ; tmp148 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_2) ; /* tmp149 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp147) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp148) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp142)->tag != 14) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp150 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_0) ; tmp151 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_2) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_3) ; /* tmp153 = */ tmpvarmap_add_0 (arg0, tmp150) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp151) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp152) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp142)->tag != 17) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_10, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp155) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp142)->tag != 18) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp156) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp142)->tag != 19) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_10, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp157) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp142)->tag != 20) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp158) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp142)->tag != 21) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_11, tmp142, atslab_3) ; tmp160 = ats_caselptrlab_mac(anairiats_sum_11, tmp142, atslab_5) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_11, tmp142, atslab_6) ; tmp162 = ats_caselptrlab_mac(anairiats_sum_11, tmp142, atslab_7) ; /* tmp163 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp159) ; /* tmp164 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp160) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp161) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp162) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp142)->tag != 24) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp166 = ats_caselptrlab_mac(anairiats_sum_8, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp166) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp142)->tag != 25) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp167 = ats_caselptrlab_mac(anairiats_sum_7, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp167) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp142)->tag != 26) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_7, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp168) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp142)->tag != 27) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp169 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp169) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp142)->tag != 28) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp170) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp142)->tag != 29) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_10, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp171) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp142)->tag != 30) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_10, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp172) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp142)->tag != 32) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp173 = ats_caselptrlab_mac(anairiats_sum_10, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp173) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp142)->tag != 33) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp174) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)tmp142)->tag != 34) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp175 = ats_caselptrlab_mac(anairiats_sum_12, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp175) ; break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp142)->tag != 35) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp176 = ats_caselptrlab_mac(anairiats_sum_12, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp176) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp142)->tag != 36) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_13, tmp142, atslab_0) ; /* tmp136 = */ aux_branchlst_19 (arg0, tmp177) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp142)->tag != 45) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp178 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_0) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_1) ; tmp180 = ats_caselptrlab_mac(anairiats_sum_9, tmp142, atslab_2) ; /* tmp181 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp178) ; /* tmp182 = */ tmpvarmap_add_0 (arg0, tmp179) ; /* tmp136 = */ aux_branchlst_19 (arg0, tmp180) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp142)->tag != 46) { goto __ats_lab_50_0 ; } __ats_lab_49_1: tmp183 = ats_caselptrlab_mac(anairiats_sum_13, tmp142, atslab_0) ; /* tmp136 = */ tmpvarmap_add_0 (arg0, tmp183) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: break ; } while (0) ; return /* (tmp136) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 8672(line=266, offs=24) -- 8853(line=270, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; // ATSlocal_void (tmp187) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp187 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instr_tmpvarmap_add (arg0, tmp185) ; arg0 = arg0 ; arg1 = tmp186 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add ; // tail call break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_52_1: break ; } while (0) ; return /* (tmp184) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 8946(line=276, offs=26) -- 9027(line=277, offs=63) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_local (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp188) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_local: tmp188 = _emit_tmpvarmap_dec_8 (arg0, 0, arg1) ; return (tmp188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_local] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 9102(line=281, offs=27) -- 9184(line=282, offs=64) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_static (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_static: tmp189 = _emit_tmpvarmap_dec_8 (arg0, 1, arg1) ; return (tmp189) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_dec_static] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 9279(line=288, offs=25) -- 9353(line=289, offs=56) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_markroot (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_markroot: tmp190 = _emit_tmpvarmap_markroot_12 (arg0, arg1) ; return (tmp190) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__emit_tmpvarmap_markroot] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 9447(line=296, offs=3) -- 9597(line=299, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funentry_tmpvarmap_add (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp191) ; // ATSlocal_void (tmp192) ; ATSlocal (ats_ptr_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funentry_tmpvarmap_add: tmp193 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_body (arg1) ; /* tmp192 = */ ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__instrlst_tmpvarmap_add (arg0, tmp193) ; tmp194 = ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__funentry_get_ret (arg1) ; /* tmp191 = */ tmpvarmap_add_0 (arg0, tmp194) ; return /* (tmp191) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__funentry_tmpvarmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 9738(line=306, offs=7) -- 10008(line=311, offs=30) */ ATSstaticdec() ats_void_type loop_26 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; // ATSlocal_void (tmp199) ; __ats_lab_loop_26: do { /* branch: __ats_lab_53 */ __ats_lab_53_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_14, arg1, atslab_2) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_14, arg1, atslab_3) ; /* tmp199 = */ tmpvarmap_addlst_7 (arg0, tmp197) ; arg0 = arg0 ; arg1 = tmp198 ; goto __ats_lab_loop_26 ; // tail call break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_54_1: break ; } while (0) ; return /* (tmp196) */ ; } /* end of [loop_26] */ /* // /home/hwxi/research/Anairiats/src/ats_ccomp_util.dats: 9693(line=305, offs=3) -- 10029(line=313, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tailjoinlst_tmpvarmap_add (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp195) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tailjoinlst_tmpvarmap_add: /* tmp195 = */ loop_26 (arg0, arg1) ; return /* (tmp195) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__tailjoinlst_tmpvarmap_add] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__ENVcon_0.tag = 0 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_util_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_util_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/libats_lex_lexing_sats.c0000664000175000017500000000260012223166160022761 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException) ; /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException.name = "ATS_2d0_2e2_2e11_2src_2libats_lex_lexing_2esats__LexingErrorException" ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/libats_lex_lexing_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_symbol_dats.c0000664000175000017500000013743112223166160021435 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_name ; atsopt_count_type atslab_code ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gt_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gte_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_int_type, atsopt_compare_count_count) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_uint_type, atsopt_count_hash) (atsopt_count_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_count) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_ptr_type, atsopt_counter_make) () ; ATSextern_fun(atsopt_count_type, atsopt_counter_getinc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_make) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_search) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_insert) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__sasp__symbol_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_empty) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_COLONEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FUN) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTLT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSLTGT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQEQ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARKBANG) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FOR) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IF) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IN) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SIZEOF) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_STDIN) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUPZ) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNION) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VBOX) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EXN) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATSOPT_NAMESPACE) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_STALOADFLAG) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFLAG) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFUN_NAME) ; /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp2) ; ATSstatic (ats_ptr_type, statmp9) ; ATSstatic (ats_ptr_type, statmp10) ; ATSstatic (ats_ptr_type, statmp11) ; ATSstatic (ats_ptr_type, statmp12) ; ATSstatic (ats_ptr_type, statmp13) ; ATSstatic (ats_ptr_type, statmp14) ; ATSstatic (ats_ptr_type, statmp15) ; ATSstatic (ats_ptr_type, statmp16) ; ATSstatic (ats_ptr_type, statmp17) ; ATSstatic (ats_ptr_type, statmp18) ; ATSstatic (ats_ptr_type, statmp19) ; ATSstatic (ats_ptr_type, statmp20) ; ATSstatic (ats_ptr_type, statmp21) ; ATSstatic (ats_ptr_type, statmp22) ; ATSstatic (ats_ptr_type, statmp23) ; ATSstatic (ats_ptr_type, statmp24) ; ATSstatic (ats_ptr_type, statmp25) ; ATSstatic (ats_ptr_type, statmp26) ; ATSstatic (ats_ptr_type, statmp27) ; ATSstatic (ats_ptr_type, statmp28) ; ATSstatic (ats_ptr_type, statmp29) ; ATSstatic (ats_ptr_type, statmp30) ; ATSstatic (ats_ptr_type, statmp31) ; ATSstatic (ats_ptr_type, statmp32) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp34) ; ATSstatic (ats_ptr_type, statmp35) ; ATSstatic (ats_ptr_type, statmp36) ; ATSstatic (ats_ptr_type, statmp37) ; ATSstatic (ats_ptr_type, statmp38) ; ATSstatic (ats_ptr_type, statmp39) ; ATSstatic (ats_ptr_type, statmp40) ; ATSstatic (ats_ptr_type, statmp41) ; ATSstatic (ats_ptr_type, statmp42) ; ATSstatic (ats_ptr_type, statmp43) ; ATSstatic (ats_ptr_type, statmp44) ; ATSstatic (ats_ptr_type, statmp45) ; ATSstatic (ats_ptr_type, statmp46) ; ATSstatic (ats_ptr_type, statmp47) ; ATSstatic (ats_ptr_type, statmp48) ; ATSstatic (ats_ptr_type, statmp49) ; ATSstatic (ats_ptr_type, statmp50) ; ATSstatic (ats_ptr_type, statmp51) ; ATSstatic (ats_ptr_type, statmp52) ; ATSstatic (ats_ptr_type, statmp53) ; ATSstatic (ats_ptr_type, statmp54) ; ATSstatic (ats_ptr_type, statmp55) ; ATSstatic (ats_ptr_type, statmp56) ; ATSstatic (ats_ptr_type, statmp57) ; ATSstatic (ats_ptr_type, statmp58) ; ATSstatic (ats_ptr_type, statmp59) ; ATSstatic (ats_ptr_type, statmp60) ; ATSstatic (ats_ptr_type, statmp61) ; ATSstatic (ats_ptr_type, statmp62) ; ATSstatic (ats_ptr_type, statmp63) ; ATSstatic (ats_ptr_type, statmp64) ; ATSstatic (ats_ptr_type, statmp65) ; ATSstatic (ats_ptr_type, statmp66) ; ATSstatic (ats_ptr_type, statmp67) ; ATSstatic (ats_ptr_type, statmp68) ; ATSstatic (ats_ptr_type, statmp69) ; ATSstatic (ats_ptr_type, statmp70) ; ATSstatic (ats_ptr_type, statmp71) ; ATSstatic (ats_ptr_type, statmp72) ; ATSstatic (ats_ptr_type, statmp73) ; ATSstatic (ats_ptr_type, statmp74) ; ATSstatic (ats_ptr_type, statmp75) ; ATSstatic (ats_ptr_type, statmp76) ; ATSstatic (ats_ptr_type, statmp77) ; ATSstatic (ats_ptr_type, statmp78) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 1973(line=63, offs=23) -- 1989(line=63, offs=39) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name: tmp0 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_name) ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_name] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 2118(line=72, offs=30) -- 2690(line=95, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (atsopt_count_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string: tmp4 = ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_search (statmp2, arg0) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp4 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp5 = ats_caselptrlab_mac(anairiats_sum_1, tmp4, atslab_0) ; tmp3 = tmp5 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp6 = atsopt_counter_getinc (statmp1) ; tmp7 = ATS_MALLOC(sizeof(anairiats_rec_0)) ; ats_selptrset_mac(anairiats_rec_0, tmp7, atslab_name, arg0) ; ats_selptrset_mac(anairiats_rec_0, tmp7, atslab_code, tmp6) ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_insert (statmp2, arg0, tmp7) ; tmp3 = tmp7 ; break ; } while (0) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 6838(line=211, offs=28) -- 6892(line=212, offs=40) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp79) ; ATSlocal (atsopt_count_type, tmp80) ; ATSlocal (atsopt_count_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol: tmp80 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp81 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp79 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lt_count_count (tmp80, tmp81) ; return (tmp79) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lt_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 6922(line=214, offs=29) -- 6977(line=215, offs=41) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp82) ; ATSlocal (atsopt_count_type, tmp83) ; ATSlocal (atsopt_count_type, tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol: tmp83 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp84 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp82 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__lte_count_count (tmp83, tmp84) ; return (tmp82) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__lte_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7006(line=217, offs=28) -- 7060(line=218, offs=40) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gt_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp85) ; ATSlocal (atsopt_count_type, tmp86) ; ATSlocal (atsopt_count_type, tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gt_symbol_symbol: tmp86 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp87 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp85 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gt_count_count (tmp86, tmp87) ; return (tmp85) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gt_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7090(line=220, offs=29) -- 7145(line=221, offs=41) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gte_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp88) ; ATSlocal (atsopt_count_type, tmp89) ; ATSlocal (atsopt_count_type, tmp90) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gte_symbol_symbol: tmp89 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp90 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp88 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__gte_count_count (tmp89, tmp90) ; return (tmp88) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__gte_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7174(line=223, offs=28) -- 7228(line=224, offs=40) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp91) ; ATSlocal (atsopt_count_type, tmp92) ; ATSlocal (atsopt_count_type, tmp93) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol: tmp92 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp91 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__eq_count_count (tmp92, tmp93) ; return (tmp91) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7258(line=226, offs=29) -- 7313(line=227, offs=41) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp94) ; ATSlocal (atsopt_count_type, tmp95) ; ATSlocal (atsopt_count_type, tmp96) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol: tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp96 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp94 = ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__neq_count_count (tmp95, tmp96) ; return (tmp94) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__neq_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7347(line=229, offs=33) -- 7406(line=230, offs=45) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp97) ; ATSlocal (atsopt_count_type, tmp98) ; ATSlocal (atsopt_count_type, tmp99) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol: tmp98 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp99 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; tmp97 = atsopt_compare_count_count (tmp98, tmp99) ; return (tmp97) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__compare_symbol_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7451(line=234, offs=23) -- 7479(line=234, offs=51) */ ATSglobaldec() ats_uint_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_uint_type, tmp100) ; ATSlocal (atsopt_count_type, tmp101) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash: tmp101 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg0), atslab_code) ; tmp100 = atsopt_count_hash (tmp101) ; return (tmp100) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_hash] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7527(line=238, offs=25) -- 7581(line=239, offs=37) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol: tmp103 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_name) ; /* tmp102 = */ atspre_fprint_string (arg0, tmp103) ; return /* (tmp102) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7606(line=241, offs=24) -- 7644(line=241, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol: tmp105 = atspre_stdout_get () ; tmp106 = ats_selsin_mac(tmp105, atslab_1) ; /* tmp107 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (tmp106, arg0) ; /* tmp104 = */ atspre_stdout_view_set () ; return /* (tmp104) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7668(line=242, offs=24) -- 7706(line=242, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; // ATSlocal_void (tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol: tmp109 = atspre_stderr_get () ; tmp110 = ats_selsin_mac(tmp109, atslab_1) ; /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (tmp110, arg0) ; /* tmp108 = */ atspre_stderr_view_set () ; return /* (tmp108) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7758(line=246, offs=30) -- 7922(line=251, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp112) ; // ATSlocal_void (tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (atsopt_count_type, tmp117) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code: tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_name) ; /* tmp113 = */ atspre_fprint_string (arg0, tmp114) ; /* tmp115 = */ atspre_fprint_char (arg0, '(') ; tmp117 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_code) ; /* tmp116 = */ atsopt_fprint_count (arg0, tmp117) ; /* tmp112 = */ atspre_fprint_char (arg0, ')') ; return /* (tmp112) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 7983(line=253, offs=29) -- 8026(line=253, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol_code (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; // ATSlocal_void (tmp121) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol_code: tmp119 = atspre_stdout_get () ; tmp120 = ats_selsin_mac(tmp119, atslab_1) ; /* tmp121 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code (tmp120, arg0) ; /* tmp118 = */ atspre_stdout_view_set () ; return /* (tmp118) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__print_symbol_code] */ /* // /home/hwxi/research/Anairiats/src/ats_symbol.dats: 8055(line=254, offs=29) -- 8098(line=254, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol_code (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; // ATSlocal_void (tmp125) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol_code: tmp123 = atspre_stderr_get () ; tmp124 = ats_selsin_mac(tmp123, atslab_1) ; /* tmp125 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol_code (tmp124, arg0) ; /* tmp122 = */ atspre_stderr_view_set () ; return /* (tmp122) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol_code] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_counter_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp9, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp10, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp11, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp12, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp13, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp14, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp15, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp16, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp17, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp18, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp19, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp20, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp21, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp22, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp23, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp24, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp25, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp26, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp28, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp29, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp30, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp31, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp32, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp34, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp35, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp36, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp37, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp38, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp39, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp40, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp41, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp42, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp43, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp44, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp45, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp46, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp47, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp48, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp49, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp50, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp51, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp52, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp53, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp54, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp55, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp56, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp57, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp58, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp59, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp60, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp61, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp62, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp63, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp64, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp65, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp66, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp67, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp68, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp69, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp70, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp71, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp72, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp73, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp74, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp75, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp76, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp77, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp78, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp1 = atsopt_counter_make () ; statmp2 = ATS_2d0_2e2_2e11_2src_2ats_symtbl_2esats__symtbl_make (512) ; statmp9 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_empty, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_empty = statmp9 ; statmp10 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("+")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADD = statmp10 ; statmp11 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("&")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AMPERSAND = statmp11 ; statmp12 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("@")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_AT = statmp12 ; statmp13 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("\\")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BACKSLASH = statmp13 ; statmp14 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("!")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BANG = statmp14 ; statmp15 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst(":=")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_COLONEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_COLONEQ = statmp15 ; statmp16 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("/")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DIV = statmp16 ; statmp17 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("=")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQ = statmp17 ; statmp18 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("==")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EQEQ = statmp18 ; statmp19 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("fun")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FUN, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FUN = statmp19 ; statmp20 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst(">")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GT = statmp20 ; statmp21 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst(">=")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTEQ = statmp21 ; statmp22 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst(">>")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTGT = statmp22 ; statmp23 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("><")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTLT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_GTLT = statmp23 ; statmp24 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("&&")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LAND = statmp24 ; statmp25 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("||")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LOR = statmp25 ; statmp26 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("[]")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LRBRACKETS = statmp26 ; statmp27 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("<")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LT = statmp27 ; statmp28 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("<=")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTEQ = statmp28 ; statmp29 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("<<")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LTLT = statmp29 ; statmp30 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("->")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSGT = statmp30 ; statmp31 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("-<>")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSLTGT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MINUSLTGT = statmp31 ; statmp32 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("*")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_MUL = statmp32 ; statmp33 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("<>")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQ = statmp33 ; statmp34 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("!=")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQEQ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_NEQEQ = statmp34 ; statmp35 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("?")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARK = statmp35 ; statmp36 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("?!")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARKBANG, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_QMARKBANG = statmp36 ; statmp37 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("-")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SUB = statmp37 ; statmp38 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("~")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TILDE = statmp38 ; statmp39 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("_")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDERSCORE = statmp39 ; statmp40 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("false")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FALSE = statmp40 ; statmp41 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("true")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TRUE = statmp41 ; statmp42 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("do")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DO = statmp42 ; statmp43 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("for")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FOR, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_FOR = statmp43 ; statmp44 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("if")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IF, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IF = statmp44 ; statmp45 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("in")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IN, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IN = statmp45 ; statmp46 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("r@ead")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_R0EAD = statmp46 ; statmp47 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("sizeof")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SIZEOF, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_SIZEOF = statmp47 ; statmp48 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("stdin")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_STDIN, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_STDIN = statmp48 ; statmp49 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("tupz")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUPZ, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUPZ = statmp49 ; statmp50 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("union")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNION, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNION = statmp50 ; statmp51 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("vbox")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VBOX, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VBOX = statmp51 ; statmp52 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("while")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_WHILE = statmp52 ; statmp53 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("defined")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_DEFINED = statmp53 ; statmp54 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("undefined")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_UNDEFINED = statmp54 ; statmp55 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("evalmac")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EVALMAC = statmp55 ; statmp56 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("liftmac")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_LIFTMAC = statmp56 ; statmp57 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("is_nil")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_NIL = statmp57 ; statmp58 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("is_cons")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_IS_CONS = statmp58 ; statmp59 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("tup_head")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_HEAD = statmp59 ; statmp60 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("tup_tail")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TUP_TAIL = statmp60 ; statmp61 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("addr")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ADDR = statmp61 ; statmp62 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_BOOL = statmp62 ; statmp63 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("char")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CHAR = statmp63 ; statmp64 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("cls")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS = statmp64 ; statmp65 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("eff")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EFF = statmp65 ; statmp66 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("exn")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EXN, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_EXN = statmp66 ; statmp67 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT = statmp67 ; statmp68 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("prop")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP = statmp68 ; statmp69 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE = statmp69 ; statmp70 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("t@ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE = statmp70 ; statmp71 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("view")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW = statmp71 ; statmp72 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE = statmp72 ; statmp73 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("viewt@ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE = statmp73 ; statmp74 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("types")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES = statmp74 ; statmp75 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("ATSOPT_NAMESPACE")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATSOPT_NAMESPACE, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATSOPT_NAMESPACE = statmp75 ; statmp76 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("ATS_STALOADFLAG")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_STALOADFLAG, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_STALOADFLAG = statmp76 ; statmp77 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("ATS_DYNLOADFLAG")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFLAG, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFLAG = statmp77 ; statmp78 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (ATSstrcst("ATS_DYNLOADFUN_NAME")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFUN_NAME, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_ATS_DYNLOADFUN_NAME = statmp78 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_symbol_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_stadyncst2_dats.c0000664000175000017500000054301512223166160022225 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_sym ; ats_ptr_type atslab_cst ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_5 ; typedef struct { ats_ptr_type atslab_sym ; ats_ptr_type atslab_con ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_7 ; typedef struct { anairiats_rec_7 atslab_0 ; } anairiats_sum_8 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ITEMcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pervasive_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ref_viewt0ype_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_long_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_short_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_short_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_exi) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_uni) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_exi) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_uni) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Arrayptrsize_viewt0ype_int_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_viewt0ype_int_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Crypt_viewt0ype_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Clo_viewt0ype_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloptr_viewt0ype_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloref_t0ype_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_types_viewt0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Btw_int_int_int_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sizeof_viewt0ype_int) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sasp__d2cstref_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sasp__d2conref_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sasp__s2cstref_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Byte_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Opt_viewt0ype_bool_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ref_viewt0ype_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_int_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_long_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_long_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_short_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_short_t0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_exi) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_uni) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_exi) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_uni) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Arrayptrsize_viewt0ype_int_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_viewt0ype_int_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Crypt_viewt0ype_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Clo_viewt0ype_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloptr_viewt0ype_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloref_t0ype_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_types_viewt0ype) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_bool_bool_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_bool_bool_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_char_char_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_char_char_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Btw_int_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_int_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sizeof_viewt0ype_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_addr_int_addr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_int_addr) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_addr_int) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_addr_addr_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_cls_cls_bool) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_nil) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_cons) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_void) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_argc_argv) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_dummy) ; /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_bool_type s2exp_is_app_s2cstref_27 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type un_s2exp_s2cstref_1_28 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type un_s2exp_s2cstref_2_29 (ats_ptr_type arg0, ats_ptr_type arg1) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp57) ; ATSstatic (ats_ptr_type, statmp58) ; ATSstatic (ats_ptr_type, statmp59) ; ATSstatic (ats_ptr_type, statmp60) ; ATSstatic (ats_ptr_type, statmp61) ; ATSstatic (ats_ptr_type, statmp62) ; ATSstatic (ats_ptr_type, statmp63) ; ATSstatic (ats_ptr_type, statmp64) ; ATSstatic (ats_ptr_type, statmp65) ; ATSstatic (ats_ptr_type, statmp66) ; ATSstatic (ats_ptr_type, statmp67) ; ATSstatic (ats_ptr_type, statmp68) ; ATSstatic (ats_ptr_type, statmp69) ; ATSstatic (ats_ptr_type, statmp70) ; ATSstatic (ats_ptr_type, statmp71) ; ATSstatic (ats_ptr_type, statmp72) ; ATSstatic (ats_ptr_type, statmp73) ; ATSstatic (ats_ptr_type, statmp74) ; ATSstatic (ats_ptr_type, statmp75) ; ATSstatic (ats_ptr_type, statmp76) ; ATSstatic (ats_ptr_type, statmp77) ; ATSstatic (ats_ptr_type, statmp78) ; ATSstatic (ats_ptr_type, statmp79) ; ATSstatic (ats_ptr_type, statmp80) ; ATSstatic (ats_ptr_type, statmp81) ; ATSstatic (ats_ptr_type, statmp82) ; ATSstatic (ats_ptr_type, statmp83) ; ATSstatic (ats_ptr_type, statmp84) ; ATSstatic (ats_ptr_type, statmp85) ; ATSstatic (ats_ptr_type, statmp86) ; ATSstatic (ats_ptr_type, statmp87) ; ATSstatic (ats_ptr_type, statmp88) ; ATSstatic (ats_ptr_type, statmp89) ; ATSstatic (ats_ptr_type, statmp90) ; ATSstatic (ats_ptr_type, statmp91) ; ATSstatic (ats_ptr_type, statmp92) ; ATSstatic (ats_ptr_type, statmp93) ; ATSstatic (ats_ptr_type, statmp94) ; ATSstatic (ats_ptr_type, statmp95) ; ATSstatic (ats_ptr_type, statmp96) ; ATSstatic (ats_ptr_type, statmp97) ; ATSstatic (ats_ptr_type, statmp98) ; ATSstatic (ats_ptr_type, statmp99) ; ATSstatic (ats_ptr_type, statmp100) ; ATSstatic (ats_ptr_type, statmp101) ; ATSstatic (ats_ptr_type, statmp102) ; ATSstatic (ats_ptr_type, statmp103) ; ATSstatic (ats_ptr_type, statmp104) ; ATSstatic (ats_ptr_type, statmp105) ; ATSstatic (ats_ptr_type, statmp106) ; ATSstatic (ats_ptr_type, statmp107) ; ATSstatic (ats_ptr_type, statmp108) ; ATSstatic (ats_ptr_type, statmp109) ; ATSstatic (ats_ptr_type, statmp110) ; ATSstatic (ats_ptr_type, statmp111) ; ATSstatic (ats_ptr_type, statmp112) ; ATSstatic (ats_ptr_type, statmp113) ; ATSstatic (ats_ptr_type, statmp114) ; ATSstatic (ats_ptr_type, statmp115) ; ATSstatic (ats_ptr_type, statmp116) ; ATSstatic (ats_ptr_type, statmp117) ; ATSstatic (ats_ptr_type, statmp118) ; ATSstatic (ats_ptr_type, statmp119) ; ATSstatic (ats_ptr_type, statmp120) ; ATSstatic (ats_ptr_type, statmp121) ; ATSstatic (ats_ptr_type, statmp122) ; ATSstatic (ats_ptr_type, statmp123) ; ATSstatic (ats_ptr_type, statmp124) ; ATSstatic (ats_ptr_type, statmp125) ; ATSstatic (ats_ptr_type, statmp126) ; ATSstatic (ats_ptr_type, statmp127) ; ATSstatic (ats_ptr_type, statmp128) ; ATSstatic (ats_ptr_type, statmp129) ; ATSstatic (ats_ptr_type, statmp130) ; ATSstatic (ats_ptr_type, statmp131) ; ATSstatic (ats_ptr_type, statmp132) ; ATSstatic (ats_ptr_type, statmp133) ; ATSstatic (ats_ptr_type, statmp134) ; ATSstatic (ats_ptr_type, statmp135) ; ATSstatic (ats_ptr_type, statmp136) ; ATSstatic (ats_ptr_type, statmp137) ; ATSstatic (ats_ptr_type, statmp138) ; ATSstatic (ats_ptr_type, statmp139) ; ATSstatic (ats_ptr_type, statmp140) ; ATSstatic (ats_ptr_type, statmp141) ; ATSstatic (ats_ptr_type, statmp142) ; ATSstatic (ats_ptr_type, statmp143) ; ATSstatic (ats_ptr_type, statmp144) ; ATSstatic (ats_ptr_type, statmp145) ; ATSstatic (ats_ptr_type, statmp146) ; ATSstatic (ats_ptr_type, statmp147) ; ATSstatic (ats_ptr_type, statmp148) ; ATSstatic (ats_ptr_type, statmp149) ; ATSstatic (ats_ptr_type, statmp150) ; ATSstatic (ats_ptr_type, statmp151) ; ATSstatic (ats_ptr_type, statmp152) ; ATSstatic (ats_ptr_type, statmp153) ; ATSstatic (ats_ptr_type, statmp154) ; ATSstatic (ats_ptr_type, statmp155) ; ATSstatic (ats_ptr_type, statmp156) ; ATSstatic (ats_ptr_type, statmp157) ; ATSstatic (ats_ptr_type, statmp158) ; ATSstatic (ats_ptr_type, statmp159) ; ATSstatic (ats_ptr_type, statmp160) ; ATSstatic (ats_ptr_type, statmp161) ; ATSstatic (ats_ptr_type, statmp162) ; ATSstatic (ats_ptr_type, statmp190) ; ATSstatic (ats_ptr_type, statmp191) ; ATSstatic (ats_ptr_type, statmp192) ; ATSstatic (ats_ptr_type, statmp193) ; ATSstatic (ats_ptr_type, statmp220) ; ATSstatic (ats_ptr_type, statmp221) ; ATSstatic (ats_ptr_type, statmp222) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 1869(line=57, offs=4) -- 1928(line=57, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_stadyncst2)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 2166(line=69, offs=25) -- 2502(line=79, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_ptr_type, tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make: tmp2 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg0) ; tmp3 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp4 = ats_selsin_mac(tmp3, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp4), atslab_sym) = tmp2 ; tmp5 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp4), atslab_cst) = tmp5 ; /* tmp6 = */ atspre_vbox_make_view_ptr (tmp4) ; /* tmp7 = ats_selsin_mac(tmp6, atslab_1) */ ; tmp1 = tmp4 ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 2579(line=83, offs=28) -- 3534(line=113, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; // ATSlocal_void (tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; // ATSlocal_void (tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst: tmp9 = ats_selsin_mac(arg0, atslab_1) ; tmp10 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp9), atslab_cst) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (tmp10 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_1, tmp10, atslab_0) ; tmp8 = tmp11 ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (tmp10 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp12 = ats_selsin_mac(arg0, atslab_1) ; tmp13 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp12), atslab_sym) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_s2expenv_pervasive_find (tmp13) ; do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (tmp15 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_2_1: tmp16 = ats_caselptrlab_mac(anairiats_sum_1, tmp15, atslab_0) ; ATS_FREE(tmp15) ; do { /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp16)->tag != 0) { goto __ats_lab_4_0 ; } tmp17 = ats_caselptrlab_mac(anairiats_sum_2, tmp16, atslab_0) ; if (tmp17 == (ats_sum_ptr_type)0) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_3, tmp17, atslab_0) ; tmp19 = ats_selsin_mac(arg0, atslab_1) ; tmp20 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp20, atslab_0, tmp18) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp19), atslab_cst) = tmp20 ; tmp14 = tmp20 ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: __ats_lab_4_1: tmp14 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (tmp15 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp14 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (tmp14 == (ats_sum_ptr_type)0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_1, tmp14, atslab_0) ; tmp8 = tmp21 ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: // if (tmp14 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_7_1: /* tmp22 = */ prerr_interror_0 () ; /* tmp23 = */ atspre_prerr_string (ATSstrcst(": s2cstref_get_cst: ")) ; /* tmp24 = */ atspre_prerr_string (ATSstrcst("the pervasive static constant [")) ; /* tmp25 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp13) ; /* tmp26 = */ atspre_prerr_string (ATSstrcst("] is not available.")) ; /* tmp27 = */ atspre_prerr_newline () ; /* tmp8 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 3615(line=119, offs=3) -- 4176(line=140, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_exp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; // ATSlocal_void (tmp36) ; // ATSlocal_void (tmp37) ; // ATSlocal_void (tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_exp: tmp29 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg0) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp29) ; do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_8_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; ATS_FREE(arg1) ; tmp33 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp29) ; do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp33)->tag != 1) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_4, tmp33, atslab_1) ; tmp32 = tmp34 ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: /* tmp35 = */ prerr_interror_0 () ; /* tmp36 = */ atspre_prerr_string (ATSstrcst(": s2cstref_get_exp: s2c = ")) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp29) ; /* tmp38 = */ atspre_prerr_newline () ; /* tmp32 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp28 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp32, tmp30, tmp31) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp28 = tmp30 ; break ; } while (0) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 4239(line=142, offs=30) -- 4647(line=154, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_unget_exp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_bool_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_bool_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_unget_exp: tmp40 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp40)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_12_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_4, tmp40, atslab_0) ; tmp42 = ats_caselptrlab_mac(anairiats_sum_4, tmp40, atslab_1) ; tmp43 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp41), atslab_s2exp_node) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp43)->tag != 4) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_2, tmp43, atslab_0) ; tmp46 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg0) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp46, tmp44) ; if (tmp45) { tmp39 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_0, tmp42) ; } else { tmp39 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp39 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp40)->tag != 4) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_2, tmp40, atslab_0) ; tmp49 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg0) ; tmp48 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp49, tmp47) ; if (tmp48) { tmp50 = (ats_sum_ptr_type)0 ; tmp39 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp39, atslab_0, tmp50) ; } else { tmp39 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp39 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp39) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_unget_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 4728(line=159, offs=18) -- 4791(line=160, offs=48) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst: tmp52 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg0) ; tmp51 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp52, arg1) ; return (tmp51) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 4851(line=165, offs=3) -- 5020(line=170, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp: tmp54 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp54)->tag != 0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_4, tmp54, atslab_0) ; arg0 = arg0 ; arg1 = tmp55 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp54)->tag != 4) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_2, tmp54, atslab_0) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_cst (arg0, tmp56) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp53 = ats_false_bool ; break ; } while (0) ; return (tmp53) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_equ_exp] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 12510(line=410, offs=25) -- 12846(line=420, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make: tmp164 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg0) ; tmp165 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_6)) ; tmp166 = ats_selsin_mac(tmp165, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_6, tmp166), atslab_sym) = tmp164 ; tmp167 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_6, tmp166), atslab_con) = tmp167 ; /* tmp168 = */ atspre_vbox_make_view_ptr (tmp166) ; /* tmp169 = ats_selsin_mac(tmp168, atslab_1) */ ; tmp163 = tmp166 ; return (tmp163) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 12902(line=422, offs=28) -- 14017(line=458, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; // ATSlocal_void (tmp186) ; // ATSlocal_void (tmp187) ; // ATSlocal_void (tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get: tmp171 = ats_selsin_mac(arg0, atslab_1) ; tmp172 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_6, tmp171), atslab_con) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp172 != (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_20_1: tmp173 = ats_selsin_mac(arg0, atslab_1) ; tmp174 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_6, tmp173), atslab_sym) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find (tmp174) ; do { /* branch: __ats_lab_21 */ __ats_lab_21_0: if (tmp175 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_21_1: tmp177 = ats_caselptrlab_mac(anairiats_sum_1, tmp175, atslab_0) ; ATS_FREE(tmp175) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp177)->tag != 0) { goto __ats_lab_25_0 ; } __ats_lab_22_1: tmp178 = ats_caselptrlab_mac(anairiats_sum_2, tmp177, atslab_0) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (tmp178 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_3, tmp178, atslab_0) ; tmp180 = ats_selsin_mac(arg0, atslab_1) ; tmp181 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp181, atslab_0, tmp179) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_6, tmp180), atslab_con) = tmp181 ; tmp176 = tmp181 ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (tmp178 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp176 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: __ats_lab_25_1: tmp176 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (tmp175 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: tmp176 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp176 == (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp182 = ats_caselptrlab_mac(anairiats_sum_1, tmp176, atslab_0) ; tmp170 = tmp182 ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp176 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: /* tmp183 = */ prerr_interror_0 () ; /* tmp184 = */ atspre_prerr_string (ATSstrcst(": d2conref_con_get: ")) ; /* tmp185 = */ atspre_prerr_string (ATSstrcst("the pervasive dynamic constructor [")) ; /* tmp186 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp174) ; /* tmp187 = */ atspre_prerr_string (ATSstrcst("] is not available.")) ; /* tmp188 = */ atspre_prerr_newline () ; /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (tmp172 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: tmp189 = ats_caselptrlab_mac(anairiats_sum_1, tmp172, atslab_0) ; tmp170 = tmp189 ; break ; } while (0) ; return (tmp170) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 14872(line=494, offs=25) -- 15208(line=504, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make: tmp195 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_make_string (arg0) ; tmp196 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_0)) ; tmp197 = ats_selsin_mac(tmp196, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp197), atslab_sym) = tmp195 ; tmp198 = (ats_sum_ptr_type)0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp197), atslab_cst) = tmp198 ; /* tmp199 = */ atspre_vbox_make_view_ptr (tmp197) ; /* tmp200 = ats_selsin_mac(tmp199, atslab_1) */ ; tmp194 = tmp197 ; return (tmp194) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 15264(line=507, offs=18) -- 16261(line=538, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; // ATSlocal_void (tmp213) ; // ATSlocal_void (tmp214) ; // ATSlocal_void (tmp215) ; // ATSlocal_void (tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst: tmp202 = ats_selsin_mac(arg0, atslab_1) ; tmp203 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp202), atslab_cst) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp203 != (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_30_1: tmp204 = ats_selsin_mac(arg0, atslab_1) ; tmp205 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp204), atslab_sym) ; tmp206 = ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__the_d2expenv_pervasive_find (tmp205) ; do { /* branch: __ats_lab_31 */ __ats_lab_31_0: if (tmp206 == (ats_sum_ptr_type)0) { goto __ats_lab_34_0 ; } __ats_lab_31_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_1, tmp206, atslab_0) ; ATS_FREE(tmp206) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp208)->tag != 1) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp209 = ats_caselptrlab_mac(anairiats_sum_2, tmp208, atslab_0) ; tmp210 = ats_selsin_mac(arg0, atslab_1) ; tmp211 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp211, atslab_0, tmp209) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_0, tmp210), atslab_cst) = tmp211 ; tmp207 = tmp211 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: __ats_lab_33_1: tmp207 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: // if (tmp206 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_34_1: tmp207 = (ats_sum_ptr_type)0 ; break ; } while (0) ; do { /* branch: __ats_lab_35 */ __ats_lab_35_0: if (tmp207 == (ats_sum_ptr_type)0) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; tmp201 = tmp212 ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: // if (tmp207 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_36_1: /* tmp213 = */ prerr_interror_0 () ; /* tmp214 = */ atspre_prerr_string (ATSstrcst(": d2cstref_get_cst: ")) ; /* tmp215 = */ atspre_prerr_string (ATSstrcst("the pervasive dynamic constant [")) ; /* tmp216 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp205) ; /* tmp217 = */ atspre_prerr_string (ATSstrcst("] is not available.")) ; /* tmp218 = */ atspre_prerr_newline () ; /* tmp201 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (tmp203 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: tmp219 = ats_caselptrlab_mac(anairiats_sum_1, tmp203, atslab_0) ; tmp201 = tmp219 ; break ; } while (0) ; return (tmp201) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_get_cst] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 16529(line=548, offs=22) -- 16672(line=555, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_bool_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool: if (arg0) { tmp224 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool) ; } else { tmp224 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool) ; } /* end of [if] */ tmp223 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp224) ; return (tmp223) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 16724(line=557, offs=28) -- 16797(line=559, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype: tmp226 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype) ; tmp225 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp226) ; return (tmp225) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 16860(line=561, offs=33) -- 16961(line=564, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype (ats_bool_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_ptr_type, tmp232) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype: tmp228 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; tmp230 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (arg0) ; tmp229 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp229, atslab_0, tmp230) ; tmp231 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp229), atslab_1) ; tmp232 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp231) = tmp232 ; tmp227 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp228, tmp229) ; return (tmp227) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool_bool_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17024(line=566, offs=28) -- 17097(line=568, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype: tmp234 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype) ; tmp233 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp234) ; return (tmp233) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17160(line=570, offs=33) -- 17261(line=573, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype (ats_char_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (ats_ptr_type, tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype: tmp236 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; tmp238 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char (arg0) ; tmp237 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp237, atslab_0, tmp238) ; tmp239 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp237), atslab_1) ; tmp240 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp239) = tmp240 ; tmp235 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp236, tmp237) ; return (tmp235) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_char_char_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17326(line=575, offs=30) -- 17401(line=577, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype: tmp242 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype) ; tmp241 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp242) ; return (tmp241) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17468(line=579, offs=35) -- 17550(line=582, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype: tmp244 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype) ; tmp243 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp244) ; return (tmp243) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_double_long_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17616(line=584, offs=29) -- 17690(line=586, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_float_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_float_t0ype: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype) ; tmp245 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp246) ; return (tmp245) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_float_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17748(line=588, offs=27) -- 17820(line=590, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype: tmp248 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp248) ; return (tmp247) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 17880(line=592, offs=31) -- 17978(line=595, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_int_t0ype (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; ATSlocal (ats_ptr_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_int_t0ype: tmp250 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg0) ; tmp251 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp251, atslab_0, tmp252) ; tmp253 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp251), atslab_1) ; tmp254 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp253) = tmp254 ; tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp250, tmp251) ; return (tmp249) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_int_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18045(line=597, offs=34) -- 18146(line=600, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype: tmp256 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; tmp258 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg0) ; tmp257 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp257, atslab_0, tmp258) ; tmp259 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp257), atslab_1) ; tmp260 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp259) = tmp260 ; tmp255 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp256, tmp257) ; return (tmp255) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_int_intinf_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18212(line=604, offs=26) -- 18283(line=606, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_type () { /* local vardec */ ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_ptr_type, tmp262) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_type: tmp262 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp262) ; return (tmp261) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18342(line=608, offs=31) -- 18466(line=612, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type: tmp264 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; tmp265 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp264) ; tmp266 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp266, atslab_0, arg0) ; tmp267 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp266), atslab_1) ; tmp268 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp267) = tmp268 ; tmp263 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp265, tmp266) ; return (tmp263) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ptr_addr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18528(line=614, offs=29) -- 18602(line=616, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type () { /* local vardec */ ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type: tmp270 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; tmp269 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp270) ; return (tmp269) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18666(line=618, offs=33) -- 18766(line=621, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type: tmp272 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; tmp274 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg0) ; tmp273 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp273, atslab_0, tmp274) ; tmp275 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp273), atslab_1) ; tmp276 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp275) = tmp276 ; tmp271 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp272, tmp273) ; return (tmp271) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_string_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18829(line=623, offs=28) -- 18875(line=624, offs=42) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype: tmp278 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp278) ; return (tmp277) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_void_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 18932(line=629, offs=4) -- 19272(line=639, offs=15) */ ATSstaticdec() ats_bool_type s2exp_is_app_s2cstref_27 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_bool_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; __ats_lab_s2exp_is_app_s2cstref_27: tmp280 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp280)->tag != 0) { goto __ats_lab_41_0 ; } __ats_lab_38_1: tmp281 = ats_caselptrlab_mac(anairiats_sum_4, tmp280, atslab_0) ; tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp281), atslab_s2exp_node) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp282)->tag != 4) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp283 = ats_caselptrlab_mac(anairiats_sum_2, tmp282, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg1) ; tmp284 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp285, tmp283) ; if (tmp284) { tmp279 = ats_true_bool ; } else { tmp279 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp279 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp279 = ats_false_bool ; break ; } while (0) ; return (tmp279) ; } /* end of [s2exp_is_app_s2cstref_27] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 19332(line=644, offs=4) -- 20044(line=664, offs=4) */ ATSstaticdec() ats_ptr_type un_s2exp_s2cstref_1_28 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_ptr_type, tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_bool_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_ptr_type, tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; // ATSlocal_void (tmp299) ; __ats_lab_un_s2exp_s2cstref_1_28: tmp287 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp287)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_42_1: tmp288 = ats_caselptrlab_mac(anairiats_sum_4, tmp287, atslab_0) ; tmp289 = ats_caselptrlab_mac(anairiats_sum_4, tmp287, atslab_1) ; tmp290 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp288), atslab_s2exp_node) ; do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp290)->tag != 4) { goto __ats_lab_46_0 ; } __ats_lab_43_1: tmp291 = ats_caselptrlab_mac(anairiats_sum_2, tmp290, atslab_0) ; tmp293 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg1) ; tmp292 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp293, tmp291) ; if (tmp292) { do { /* branch: __ats_lab_44 */ __ats_lab_44_0: if (tmp289 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } tmp294 = ats_caselptrlab_mac(anairiats_sum_3, tmp289, atslab_1) ; if (tmp294 != (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp295 = ats_caselptrlab_mac(anairiats_sum_3, tmp289, atslab_0) ; tmp286 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp286, atslab_0, tmp295) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: __ats_lab_45_1: /* tmp296 = */ prerr_interror_0 () ; /* tmp297 = */ atspre_prerr_string (ATSstrcst(": un_s2exp_s2cref: s2c = ")) ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp291) ; /* tmp299 = */ atspre_prerr_newline () ; /* tmp286 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { tmp286 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp286 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: __ats_lab_47_1: tmp286 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp286) ; } /* end of [un_s2exp_s2cstref_1_28] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 20081(line=666, offs=4) -- 20868(line=686, offs=4) */ ATSstaticdec() ats_ptr_type un_s2exp_s2cstref_2_29 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_bool_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (anairiats_rec_7, tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; // ATSlocal_void (tmp315) ; // ATSlocal_void (tmp316) ; __ats_lab_un_s2exp_s2cstref_2_29: tmp301 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp301)->tag != 0) { goto __ats_lab_53_0 ; } __ats_lab_48_1: tmp302 = ats_caselptrlab_mac(anairiats_sum_4, tmp301, atslab_0) ; tmp303 = ats_caselptrlab_mac(anairiats_sum_4, tmp301, atslab_1) ; tmp304 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp302), atslab_s2exp_node) ; do { /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)tmp304)->tag != 4) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp305 = ats_caselptrlab_mac(anairiats_sum_2, tmp304, atslab_0) ; tmp307 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (arg1) ; tmp306 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp307, tmp305) ; if (tmp306) { do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp303 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } tmp308 = ats_caselptrlab_mac(anairiats_sum_3, tmp303, atslab_1) ; if (tmp308 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } tmp309 = ats_caselptrlab_mac(anairiats_sum_3, tmp308, atslab_1) ; if (tmp309 != (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_3, tmp303, atslab_0) ; tmp311 = ats_caselptrlab_mac(anairiats_sum_3, tmp308, atslab_0) ; tmp312.atslab_0 = tmp310 ; tmp312.atslab_1 = tmp311 ; tmp300 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp300, atslab_0, tmp312) ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: __ats_lab_51_1: /* tmp313 = */ prerr_interror_0 () ; /* tmp314 = */ atspre_prerr_string (ATSstrcst(": un_s2exp_s2cref: s2c = ")) ; /* tmp315 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp305) ; /* tmp316 = */ atspre_prerr_newline () ; /* tmp300 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; } else { tmp300 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: __ats_lab_52_1: tmp300 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: tmp300 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp300) ; } /* end of [un_s2exp_s2cstref_2_29] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 20958(line=690, offs=36) -- 21010(line=691, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_bool_bool_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp317) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_bool_bool_t0ype: tmp317 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; return (tmp317) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_bool_bool_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21047(line=693, offs=36) -- 21099(line=694, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_char_char_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp318) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_char_char_t0ype: tmp318 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; return (tmp318) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_char_char_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21134(line=696, offs=34) -- 21184(line=697, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp319) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype: tmp319 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; return (tmp319) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21224(line=699, offs=39) -- 21279(line=700, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp320) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type: tmp320 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ref_viewt0ype_type) ; return (tmp320) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ref_viewt0ype_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21315(line=702, offs=35) -- 21366(line=703, offs=44) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype: tmp321 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; return (tmp321) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_size_int_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21403(line=705, offs=36) -- 21455(line=706, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_string_int_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp322) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_string_int_type: tmp322 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; return (tmp322) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_string_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21507(line=710, offs=28) -- 21582(line=714, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_t0ype: tmp324 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype) ; tmp323 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp324) ; return (tmp323) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21644(line=716, offs=32) -- 21743(line=720, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_int_t0ype (ats_int_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_int_t0ype: tmp326 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; tmp328 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg0) ; tmp327 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp327, atslab_0, tmp328) ; tmp329 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp327), atslab_1) ; tmp330 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp329) = tmp330 ; tmp325 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp326, tmp327) ; return (tmp325) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_int_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 21812(line=722, offs=35) -- 21914(line=726, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_intinf_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_intinf_t0ype: tmp332 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; tmp334 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg0) ; tmp333 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp333, atslab_0, tmp334) ; tmp335 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp333), atslab_1) ; tmp336 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp335) = tmp336 ; tmp331 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp332, tmp333) ; return (tmp331) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_uint_intinf_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22000(line=730, offs=28) -- 22077(line=732, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_t0ype: tmp338 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_t0ype) ; tmp337 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp338) ; return (tmp337) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22142(line=734, offs=35) -- 22244(line=738, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_intinf_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_intinf_t0ype: tmp340 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype) ; tmp342 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg0) ; tmp341 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp341, atslab_0, tmp342) ; tmp343 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp341), atslab_1) ; tmp344 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp343) = tmp344 ; tmp339 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp340, tmp341) ; return (tmp339) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lint_intinf_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22310(line=740, offs=29) -- 22388(line=742, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_t0ype: tmp346 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_t0ype) ; tmp345 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp346) ; return (tmp345) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22455(line=744, offs=36) -- 22558(line=748, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_intinf_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_intinf_t0ype: tmp348 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype) ; tmp350 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (arg0) ; tmp349 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp349, atslab_0, tmp350) ; tmp351 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp349), atslab_1) ; tmp352 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp351) = tmp352 ; tmp347 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cstapp (tmp348, tmp349) ; return (tmp347) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ulint_intinf_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22646(line=752, offs=29) -- 22728(line=754, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype: tmp354 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_long_t0ype) ; tmp353 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp354) ; return (tmp353) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_llint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22789(line=756, offs=30) -- 22872(line=758, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype: tmp356 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_long_t0ype) ; tmp355 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp356) ; return (tmp355) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ullint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 22953(line=762, offs=28) -- 23031(line=764, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_sint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_sint_t0ype: tmp358 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_t0ype) ; tmp357 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp358) ; return (tmp357) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_sint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23091(line=766, offs=30) -- 23176(line=768, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ussint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ussint_t0ype: tmp360 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_short_t0ype) ; tmp359 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp360) ; return (tmp359) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ussint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23258(line=772, offs=29) -- 23342(line=774, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ssint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ssint_t0ype: tmp362 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_short_t0ype) ; tmp361 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp362) ; return (tmp361) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_ssint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23402(line=776, offs=29) -- 23481(line=778, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_usint_t0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_usint_t0ype: tmp364 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_t0ype) ; tmp363 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp364) ; return (tmp363) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_usint_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23567(line=782, offs=34) -- 23617(line=783, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp365) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type: tmp365 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; return (tmp365) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_ptr_addr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23673(line=787, offs=34) -- 23725(line=788, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_exi () { /* local vardec */ ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_exi: tmp367 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_exi) ; tmp366 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp367) ; return (tmp366) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_exi] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23762(line=790, offs=34) -- 23814(line=791, offs=48) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_uni () { /* local vardec */ ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_uni: tmp369 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_uni) ; tmp368 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp369) ; return (tmp368) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_t0ype_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23855(line=793, offs=38) -- 23911(line=794, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_exi () { /* local vardec */ ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_exi: tmp371 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_exi) ; tmp370 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp371) ; return (tmp370) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_exi] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 23952(line=796, offs=38) -- 24008(line=797, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_uni () { /* local vardec */ ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_uni: tmp373 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_uni) ; tmp372 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp373) ; return (tmp372) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bottom_viewt0ype_uni] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 24047(line=799, offs=36) -- 24101(line=800, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype: tmp375 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype) ; tmp374 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp375) ; return (tmp374) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_exception_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 24165(line=804, offs=40) -- 24316(line=808, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; ATSlocal (ats_ptr_type, tmp381) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view: tmp377 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view) ; tmp378 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp377) ; tmp379 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp379, atslab_0, arg0) ; tmp380 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp379), atslab_1) ; tmp381 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp381, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp380) = tmp381 ; tmp380 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp381), atslab_1) ; tmp381 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp380) = tmp381 ; tmp376 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view, tmp378, tmp379) ; return (tmp376) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 24401(line=810, offs=43) -- 24460(line=811, offs=52) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp382) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view: tmp382 = un_s2exp_s2cstref_2_29 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view) ; return (tmp382) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 24586(line=816, offs=42) -- 24759(line=821, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_type (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; ATSlocal (ats_ptr_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_ptr_type, tmp389) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_type: tmp384 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_type) ; tmp385 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg1) ; tmp386 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp384) ; tmp387 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp387, atslab_0, arg0) ; tmp388 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp387), atslab_1) ; tmp389 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp389, atslab_0, tmp385) ; ats_ptrget_mac(ats_ptr_type, tmp388) = tmp389 ; tmp388 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp389), atslab_1) ; tmp389 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp388) = tmp389 ; tmp383 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp386, tmp387) ; return (tmp383) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 24911(line=824, offs=46) -- 25092(line=829, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_viewtype (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_viewtype: tmp391 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_viewtype) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg1) ; tmp393 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp391) ; tmp394 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp394, atslab_0, arg0) ; tmp395 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp394), atslab_1) ; tmp396 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp396, atslab_0, tmp392) ; ats_ptrget_mac(ats_ptr_type, tmp395) = tmp396 ; tmp395 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp396), atslab_1) ; tmp396 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp395) = tmp396 ; tmp390 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, tmp393, tmp394) ; return (tmp390) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_array_viewt0ype_int_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 25256(line=833, offs=44) -- 25446(line=838, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; ATSlocal (ats_ptr_type, tmp401) ; ATSlocal (ats_ptr_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype: tmp398 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Arrayptrsize_viewt0ype_int_viewt0ype) ; tmp399 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg1) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp398) ; tmp401 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp401, atslab_0, arg0) ; tmp402 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp401), atslab_1) ; tmp403 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp403, atslab_0, tmp399) ; ats_ptrget_mac(ats_ptr_type, tmp402) = tmp403 ; tmp402 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp403), atslab_1) ; tmp403 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp402) = tmp403 ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype, tmp400, tmp401) ; return (tmp397) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_arrayptrsize_viewt0ype_int_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 25620(line=843, offs=37) -- 25788(line=848, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_t0ype_int_type (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_ptr_type, tmp410) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_t0ype_int_type: tmp405 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type) ; tmp406 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg1) ; tmp407 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp405) ; tmp408 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp408, atslab_0, arg0) ; tmp409 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp408), atslab_1) ; tmp410 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp410, atslab_0, tmp406) ; ats_ptrget_mac(ats_ptr_type, tmp409) = tmp410 ; tmp409 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp410), atslab_1) ; tmp410 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp409) = tmp410 ; tmp404 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp407, tmp408) ; return (tmp404) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_t0ype_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 25867(line=850, offs=40) -- 25923(line=851, offs=49) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_list_t0ype_int_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp411) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_list_t0ype_int_type: tmp411 = un_s2exp_s2cstref_2_29 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type) ; return (tmp411) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_list_t0ype_int_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26029(line=854, offs=45) -- 26209(line=859, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_viewt0ype_int_viewtype (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; ATSlocal (ats_ptr_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_viewt0ype_int_viewtype: tmp413 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_viewt0ype_int_viewtype) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int (arg1) ; tmp415 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp413) ; tmp416 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp416, atslab_0, arg0) ; tmp417 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp416), atslab_1) ; tmp418 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp418, atslab_0, tmp414) ; ats_ptrget_mac(ats_ptr_type, tmp417) = tmp418 ; tmp417 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp418), atslab_1) ; tmp418 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp417) = tmp418 ; tmp412 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, tmp415, tmp416) ; return (tmp412) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_list_viewt0ype_int_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26310(line=863, offs=33) -- 26426(line=867, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_t0ype_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp419) ; ATSlocal (ats_ptr_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_t0ype_type: tmp420 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type) ; tmp421 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp420) ; tmp422 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp422, atslab_0, arg0) ; tmp423 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp422), atslab_1) ; tmp424 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp423) = tmp424 ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp421, tmp422) ; return (tmp419) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_t0ype_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26502(line=869, offs=41) -- 26630(line=873, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_viewt0ype_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_ptr_type, tmp427) ; ATSlocal (ats_ptr_type, tmp428) ; ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_viewt0ype_viewtype: tmp426 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype) ; tmp427 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp426) ; tmp428 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp428, atslab_0, arg0) ; tmp429 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp428), atslab_1) ; tmp430 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp429) = tmp430 ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, tmp427, tmp428) ; return (tmp425) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lazy_viewt0ype_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26709(line=875, offs=36) -- 26761(line=876, offs=45) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_t0ype_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp431) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_t0ype_type: tmp431 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type) ; return (tmp431) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_t0ype_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26806(line=878, offs=44) -- 26866(line=879, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_viewt0ype_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp432) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_viewt0ype_viewtype: tmp432 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype) ; return (tmp432) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_lazy_viewt0ype_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 26925(line=883, offs=37) -- 27045(line=887, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_printf_c_types_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp433) ; ATSlocal (ats_ptr_type, tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; ATSlocal (ats_ptr_type, tmp438) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_printf_c_types_type: tmp434 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type) ; tmp435 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp434) ; tmp436 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp436, atslab_0, arg0) ; tmp437 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp436), atslab_1) ; tmp438 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp437) = tmp438 ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, tmp435, tmp436) ; return (tmp433) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_printf_c_types_type] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 27140(line=891, offs=35) -- 27218(line=893, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_viewt0ype () { /* local vardec */ ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp440) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_viewt0ype: tmp440 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_viewt0ype) ; tmp439 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp440) ; return (tmp439) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 27296(line=895, offs=41) -- 27425(line=899, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_types_viewt0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_types_viewt0ype: tmp442 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_types_viewt0ype) ; tmp443 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp442) ; tmp444 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp444, atslab_0, arg0) ; tmp445 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp444), atslab_1) ; tmp446 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp445) = tmp446 ; tmp441 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype, tmp443, tmp444) ; return (tmp441) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_va_list_types_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 27521(line=903, offs=32) -- 27636(line=907, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; ATSlocal (ats_ptr_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop: tmp448 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop) ; tmp449 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp448) ; tmp450 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp450, atslab_0, arg0) ; tmp451 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp450), atslab_1) ; tmp452 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp451) = tmp452 ; tmp447 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop, tmp449, tmp450) ; return (tmp447) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_vbox_view_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 27705(line=909, offs=35) -- 27756(line=910, offs=44) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_vbox_view_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp453) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_vbox_view_prop: tmp453 = un_s2exp_s2cstref_1_28 (arg0, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop) ; return (tmp453) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_vbox_view_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 27823(line=915, offs=31) -- 27937(line=919, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neg_bool_bool (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neg_bool_bool: tmp455 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool) ; tmp456 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp455) ; tmp457 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp457, atslab_0, arg0) ; tmp458 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp457), atslab_1) ; tmp459 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp458) = tmp459 ; tmp454 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp456, tmp457) ; return (tmp454) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neg_bool_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 28006(line=921, offs=36) -- 28139(line=925, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_add_bool_bool_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_add_bool_bool_bool: tmp461 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool) ; tmp462 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp461) ; tmp463 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp463, atslab_0, arg0) ; tmp464 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp463), atslab_1) ; tmp465 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp465, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp464) = tmp465 ; tmp464 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp465), atslab_1) ; tmp465 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp464) = tmp465 ; tmp460 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp462, tmp463) ; return (tmp460) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_add_bool_bool_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 28213(line=927, offs=36) -- 28346(line=931, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_mul_bool_bool_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_mul_bool_bool_bool: tmp467 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool) ; tmp468 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp467) ; tmp469 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp469, atslab_0, arg0) ; tmp470 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp469), atslab_1) ; tmp471 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp471, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp470) = tmp471 ; tmp470 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp471), atslab_1) ; tmp471 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp470) = tmp471 ; tmp466 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp468, tmp469) ; return (tmp466) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_mul_bool_bool_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 28438(line=935, offs=33) -- 28568(line=939, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_int_int_bool: tmp473 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool) ; tmp474 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp473) ; tmp475 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp475, atslab_0, arg0) ; tmp476 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp475), atslab_1) ; tmp477 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp477, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp476) = tmp477 ; tmp476 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp477), atslab_1) ; tmp477 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp476) = tmp477 ; tmp472 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp474, tmp475) ; return (tmp472) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 28637(line=941, offs=34) -- 28768(line=945, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool: tmp479 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool) ; tmp480 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp479) ; tmp481 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp481, atslab_0, arg0) ; tmp482 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp481), atslab_1) ; tmp483 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp483, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp482) = tmp483 ; tmp482 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp483), atslab_1) ; tmp483 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp482) = tmp483 ; tmp478 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp480, tmp481) ; return (tmp478) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 28841(line=949, offs=33) -- 28971(line=953, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_int_int_bool: tmp485 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool) ; tmp486 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp485) ; tmp487 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp487, atslab_0, arg0) ; tmp488 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp487), atslab_1) ; tmp489 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp489, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp488) = tmp489 ; tmp488 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp489), atslab_1) ; tmp489 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp488) = tmp489 ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp486, tmp487) ; return (tmp484) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29040(line=955, offs=34) -- 29171(line=959, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_ptr_type, tmp495) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_int_int_bool: tmp491 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool) ; tmp492 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp491) ; tmp493 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp493, atslab_0, arg0) ; tmp494 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp493), atslab_1) ; tmp495 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp495, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp494) = tmp495 ; tmp494 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp495), atslab_1) ; tmp495 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp494) = tmp495 ; tmp490 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp492, tmp493) ; return (tmp490) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29245(line=963, offs=34) -- 29376(line=967, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neq_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neq_int_int_bool: tmp497 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool) ; tmp498 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp497) ; tmp499 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp499, atslab_0, arg0) ; tmp500 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp499), atslab_1) ; tmp501 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp501, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp500) = tmp501 ; tmp500 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp501), atslab_1) ; tmp501 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp500) = tmp501 ; tmp496 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp498, tmp499) ; return (tmp496) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neq_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29450(line=969, offs=38) -- 29603(line=973, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_btw_int_int_int_bool (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_ptr_type, tmp504) ; ATSlocal (ats_ptr_type, tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_btw_int_int_int_bool: tmp503 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Btw_int_int_int_bool) ; tmp504 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp503) ; tmp505 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp505, atslab_0, arg0) ; tmp506 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp505), atslab_1) ; tmp507 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp507, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp506) = tmp507 ; tmp506 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp507), atslab_1) ; tmp507 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp507, atslab_0, arg2) ; ats_ptrget_mac(ats_ptr_type, tmp506) = tmp507 ; tmp506 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp507), atslab_1) ; tmp507 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp506) = tmp507 ; tmp502 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp504, tmp505) ; return (tmp502) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_btw_int_int_int_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29691(line=977, offs=27) -- 29736(line=978, offs=41) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr () { /* local vardec */ ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr: tmp509 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr) ; tmp508 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp509) ; return (tmp508) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_null_addr] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29778(line=982, offs=35) -- 29910(line=986, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool: tmp511 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp511) ; tmp513 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp513, atslab_0, arg0) ; tmp514 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp513), atslab_1) ; tmp515 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp515, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp514) = tmp515 ; tmp514 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp515), atslab_1) ; tmp515 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp514) = tmp515 ; tmp510 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp512, tmp513) ; return (tmp510) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gt_addr_addr_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 29983(line=988, offs=36) -- 30116(line=992, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_addr_addr_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_addr_addr_bool: tmp517 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool) ; tmp518 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp517) ; tmp519 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp519, atslab_0, arg0) ; tmp520 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp519), atslab_1) ; tmp521 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp521, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp520) = tmp521 ; tmp520 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp521), atslab_1) ; tmp521 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp520) = tmp521 ; tmp516 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp518, tmp519) ; return (tmp516) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_addr_addr_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 30193(line=996, offs=35) -- 30325(line=1000, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_addr_addr_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_addr_addr_bool: tmp523 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool) ; tmp524 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp523) ; tmp525 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp525, atslab_0, arg0) ; tmp526 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp525), atslab_1) ; tmp527 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp527, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp526) = tmp527 ; tmp526 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp527), atslab_1) ; tmp527 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp526) = tmp527 ; tmp522 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp524, tmp525) ; return (tmp522) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lt_addr_addr_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 30398(line=1002, offs=36) -- 30531(line=1006, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_addr_addr_bool (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; ATSlocal (ats_ptr_type, tmp533) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_addr_addr_bool: tmp529 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool) ; tmp530 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_cst (tmp529) ; tmp531 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp531, atslab_0, arg0) ; tmp532 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp531), atslab_1) ; tmp533 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp533, atslab_0, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp532) = tmp533 ; tmp532 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp533), atslab_1) ; tmp533 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp532) = tmp533 ; tmp528 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_bool, tmp530, tmp531) ; return (tmp528) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_lte_addr_addr_bool] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 30632(line=1011, offs=32) -- 30973(line=1020, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__clo_viewt0ype_viewt0ype_assume () { /* local vardec */ // ATSlocal_void (tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__clo_viewt0ype_viewt0ype_assume: tmp535 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Clo_viewt0ype_viewt0ype) ; tmp536 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp535) ; tmp537 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; tmp539 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp537) ; tmp538 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype, 0, tmp539) ; tmp541 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp541, atslab_0, tmp537) ; tmp542 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp541), atslab_1) ; tmp543 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp542) = tmp543 ; tmp540 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp536, tmp541, tmp538) ; tmp544 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp544, atslab_0, tmp540) ; /* tmp534 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp535, tmp544) ; return /* (tmp534) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__clo_viewt0ype_viewt0ype_assume] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 31061(line=1023, offs=34) -- 31406(line=1032, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloptr_viewt0ype_viewtype_assume () { /* local vardec */ // ATSlocal_void (tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloptr_viewt0ype_viewtype_assume: tmp546 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloptr_viewt0ype_viewtype) ; tmp547 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp546) ; tmp548 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; tmp550 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp548) ; tmp549 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype, 1, tmp550) ; tmp552 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp552, atslab_0, tmp548) ; tmp553 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp552), atslab_1) ; tmp554 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp553) = tmp554 ; tmp551 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp547, tmp552, tmp549) ; tmp555 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp555, atslab_0, tmp551) ; /* tmp545 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp546, tmp555) ; return /* (tmp545) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloptr_viewt0ype_viewtype_assume] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 31488(line=1035, offs=26) -- 31818(line=1044, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloref_t0ype_type_assume () { /* local vardec */ // ATSlocal_void (tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; ATSlocal (ats_ptr_type, tmp566) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloref_t0ype_type_assume: tmp557 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloref_t0ype_type) ; tmp558 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp557) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp561 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp559) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type, -1, tmp561) ; tmp563 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp563, atslab_0, tmp559) ; tmp564 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp563), atslab_1) ; tmp565 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp564) = tmp565 ; tmp562 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp558, tmp563, tmp560) ; tmp566 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp566, atslab_0, tmp562) ; /* tmp556 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp557, tmp566) ; return /* (tmp556) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloref_t0ype_type_assume] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 31929(line=1049, offs=34) -- 32228(line=1057, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__crypt_viewt0ype_viewt0ype_assume () { /* local vardec */ // ATSlocal_void (tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; ATSlocal (ats_ptr_type, tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_ptr_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_ptr_type, tmp577) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__crypt_viewt0ype_viewt0ype_assume: tmp568 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Crypt_viewt0ype_viewt0ype) ; tmp569 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp568) ; tmp570 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; tmp572 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp570) ; tmp571 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (tmp572) ; tmp574 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp574, atslab_0, tmp570) ; tmp575 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp574), atslab_1) ; tmp576 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp575) = tmp576 ; tmp573 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp569, tmp574, tmp571) ; tmp577 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp577, atslab_0, tmp573) ; /* tmp567 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp568, tmp577) ; return /* (tmp567) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__crypt_viewt0ype_viewt0ype_assume] */ /* // /home/hwxi/research/Anairiats/src/ats_stadyncst2.dats: 32334(line=1062, offs=29) -- 32625(line=1070, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sizeof_viewt0ype_int_assume () { /* local vardec */ // ATSlocal_void (tmp578) ; ATSlocal (ats_ptr_type, tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; ATSlocal (ats_ptr_type, tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; ATSlocal (ats_ptr_type, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sizeof_viewt0ype_int_assume: tmp579 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sizeof_viewt0ype_int) ; tmp580 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp579) ; tmp581 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_srt (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; tmp583 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp581) ; tmp582 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof (tmp583) ; tmp585 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp585, atslab_0, tmp581) ; tmp586 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_3, tmp585), atslab_1) ; tmp587 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp586) = tmp587 ; tmp584 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp580, tmp585, tmp582) ; tmp588 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ats_selptrset_mac(anairiats_sum_1, tmp588, atslab_0, tmp584) ; /* tmp578 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_set_def (tmp579, tmp588) ; return /* (tmp578) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sizeof_viewt0ype_int_assume] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp57, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp58, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp59, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp60, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp61, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp62, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp63, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp64, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp65, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp66, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp67, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp68, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp69, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp70, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp71, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp72, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp73, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp74, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp75, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp76, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp77, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp78, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp79, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp80, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp81, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp82, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp83, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp84, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp85, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp86, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp87, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp88, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp89, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp90, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp91, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp92, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp93, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp94, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp95, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp96, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp97, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp98, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp99, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp100, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp101, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp102, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp103, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp104, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp105, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp106, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp107, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp108, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp109, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp110, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp111, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp112, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp113, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp114, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp115, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp116, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp117, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp118, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp119, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp120, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp121, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp122, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp123, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp124, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp125, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp126, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp127, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp128, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp129, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp130, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp131, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp132, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp133, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp134, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp135, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp136, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp137, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp138, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp139, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp140, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp141, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp142, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp143, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp144, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp145, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp146, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp147, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp148, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp149, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp150, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp151, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp152, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp153, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp154, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp155, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp156, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp157, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp158, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp159, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp160, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp161, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp162, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp190, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp191, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp192, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp193, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp220, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp221, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp222, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp57 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("true_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__True_bool = statmp57 ; statmp58 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("false_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__False_bool = statmp58 ; statmp59 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bool_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype = statmp59 ; statmp60 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bool_bool_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype = statmp60 ; statmp61 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("byte_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Byte_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Byte_t0ype = statmp61 ; statmp62 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("char_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype = statmp62 ; statmp63 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("char_char_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype = statmp63 ; statmp64 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("double_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_t0ype = statmp64 ; statmp65 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("double_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Double_long_t0ype = statmp65 ; statmp66 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("float_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Float_t0ype = statmp66 ; statmp67 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype = statmp67 ; statmp68 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype = statmp68 ; statmp69 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_t0ype = statmp69 ; statmp70 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lint_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype = statmp70 ; statmp71 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("opt_viewt0ype_bool_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Opt_viewt0ype_bool_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Opt_viewt0ype_bool_viewt0ype = statmp71 ; statmp72 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ptr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type = statmp72 ; statmp73 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ptr_addr_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type = statmp73 ; statmp74 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ref_viewt0ype_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ref_viewt0ype_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ref_viewt0ype_type = statmp74 ; statmp75 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("size_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype = statmp75 ; statmp76 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("size_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype = statmp76 ; statmp77 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ssize_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_t0ype = statmp77 ; statmp78 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ssize_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_int_t0ype = statmp78 ; statmp79 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("strbuf_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_t0ype = statmp79 ; statmp80 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("strbuf_int_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_int_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_int_int_t0ype = statmp80 ; statmp81 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("string_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type = statmp81 ; statmp82 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("string_int_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type = statmp82 ; statmp83 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype = statmp83 ; statmp84 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype = statmp84 ; statmp85 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_t0ype = statmp85 ; statmp86 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("ulint_int_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype = statmp86 ; statmp87 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("void_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Void_t0ype = statmp87 ; statmp88 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_t0ype = statmp88 ; statmp89 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_long_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_long_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_long_long_t0ype = statmp89 ; statmp90 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_t0ype = statmp90 ; statmp91 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_long_long_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_long_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_long_long_t0ype = statmp91 ; statmp92 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_short_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_t0ype = statmp92 ; statmp93 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_short_short_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_short_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_short_short_t0ype = statmp93 ; statmp94 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_short_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_t0ype = statmp94 ; statmp95 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("uint_short_short_t0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_short_t0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_short_short_t0ype = statmp95 ; statmp96 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bottom_t0ype_exi")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_exi, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_exi = statmp96 ; statmp97 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bottom_t0ype_uni")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_uni, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_t0ype_uni = statmp97 ; statmp98 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bottom_viewt0ype_exi")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_exi, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_exi = statmp98 ; statmp99 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("bottom_viewt0ype_uni")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_uni, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bottom_viewt0ype_uni = statmp99 ; statmp100 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("exception_viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Exception_viewtype = statmp100 ; statmp101 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("array_viewt0ype_int_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_type = statmp101 ; statmp102 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("array_viewt0ype_int_viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Array_viewt0ype_int_viewtype = statmp102 ; statmp103 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("arrayptrsize_viewt0ype_int_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Arrayptrsize_viewt0ype_int_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Arrayptrsize_viewt0ype_int_viewt0ype = statmp103 ; statmp104 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("list_t0ype_int_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_t0ype_int_type = statmp104 ; statmp105 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("list_viewt0ype_int_viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_viewt0ype_int_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_viewt0ype_int_viewtype = statmp105 ; statmp106 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("at_viewt0ype_addr_view")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__At_viewt0ype_addr_view = statmp106 ; statmp107 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("crypt_viewt0ype_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Crypt_viewt0ype_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Crypt_viewt0ype_viewt0ype = statmp107 ; statmp108 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("clo_viewt0ype_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Clo_viewt0ype_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Clo_viewt0ype_viewt0ype = statmp108 ; statmp109 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("cloptr_viewt0ype_viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloptr_viewt0ype_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloptr_viewt0ype_viewtype = statmp109 ; statmp110 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("cloref_t0ype_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloref_t0ype_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Cloref_t0ype_type = statmp110 ; statmp111 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lazy_t0ype_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_t0ype_type = statmp111 ; statmp112 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lazy_viewt0ype_viewtype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lazy_viewt0ype_viewtype = statmp112 ; statmp113 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("printf_c_types_type")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Printf_c_types_type = statmp113 ; statmp114 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("va_list_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_viewt0ype = statmp114 ; statmp115 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("va_list_types_viewt0ype")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_types_viewt0ype, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Va_list_types_viewt0ype = statmp115 ; statmp116 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("vbox_view_prop")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Vbox_view_prop = statmp116 ; statmp117 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neg_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_bool_bool = statmp117 ; statmp118 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("add_bool_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_bool_bool_bool = statmp118 ; statmp119 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("mul_bool_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_bool_bool_bool = statmp119 ; statmp120 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("eq_bool_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_bool_bool_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_bool_bool_bool = statmp120 ; statmp121 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neq_bool_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_bool_bool_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_bool_bool_bool = statmp121 ; statmp122 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("sub_char_char_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_char_char_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_char_char_int = statmp122 ; statmp123 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gt_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_char_char_bool = statmp123 ; statmp124 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gte_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_char_char_bool = statmp124 ; statmp125 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lt_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_char_char_bool = statmp125 ; statmp126 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lte_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_char_char_bool = statmp126 ; statmp127 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("eq_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_char_char_bool = statmp127 ; statmp128 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neq_char_char_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_char_char_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_char_char_bool = statmp128 ; statmp129 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neg_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neg_int_int = statmp129 ; statmp130 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("add_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_int_int_int = statmp130 ; statmp131 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("sub_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_int_int_int = statmp131 ; statmp132 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("mul_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Mul_int_int_int = statmp132 ; statmp133 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gt_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_int_int_bool = statmp133 ; statmp134 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gte_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_int_int_bool = statmp134 ; statmp135 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lt_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_int_int_bool = statmp135 ; statmp136 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lte_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_int_int_bool = statmp136 ; statmp137 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("eq_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_int_int_bool = statmp137 ; statmp138 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neq_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_int_int_bool = statmp138 ; statmp139 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("div_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int = statmp139 ; statmp140 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("div_int_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Div_int_int_int_bool = statmp140 ; statmp141 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("max_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int = statmp141 ; statmp142 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("max_int_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Max_int_int_int_bool = statmp142 ; statmp143 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("min_int_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int = statmp143 ; statmp144 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("min_int_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Min_int_int_int_bool = statmp144 ; statmp145 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("abs_int_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int = statmp145 ; statmp146 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("abs_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Abs_int_int_bool = statmp146 ; statmp147 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("btw_int_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Btw_int_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Btw_int_int_int_bool = statmp147 ; statmp148 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_of_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int = statmp148 ; statmp149 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("int_of_bool_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__IntOfBool_bool_int_bool = statmp149 ; statmp150 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("size_int_int_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_int_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_int_bool = statmp150 ; statmp151 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("sizeof_viewt0ype_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sizeof_viewt0ype_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sizeof_viewt0ype_int = statmp151 ; statmp152 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("null_addr")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Null_addr = statmp152 ; statmp153 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("add_addr_int_addr")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_addr_int_addr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Add_addr_int_addr = statmp153 ; statmp154 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("sub_addr_int_addr")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_int_addr, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_int_addr = statmp154 ; statmp155 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("sub_addr_addr_int")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_addr_int, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Sub_addr_addr_int = statmp155 ; statmp156 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gt_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gt_addr_addr_bool = statmp156 ; statmp157 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("gte_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Gte_addr_addr_bool = statmp157 ; statmp158 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lt_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lt_addr_addr_bool = statmp158 ; statmp159 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lte_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_addr_addr_bool = statmp159 ; statmp160 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("eq_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Eq_addr_addr_bool = statmp160 ; statmp161 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("neq_addr_addr_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_addr_addr_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Neq_addr_addr_bool = statmp161 ; statmp162 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_make (ATSstrcst("lte_cls_cls_bool")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_cls_cls_bool, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lte_cls_cls_bool = statmp162 ; statmp190 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make (ATSstrcst("list_nil")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil = statmp190 ; statmp191 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make (ATSstrcst("list_cons")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons = statmp191 ; statmp192 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make (ATSstrcst("list_vt_nil")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_nil = statmp192 ; statmp193 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_make (ATSstrcst("list_vt_cons")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_cons, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_vt_cons = statmp193 ; statmp220 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make (ATSstrcst("main_void")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_void, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_void = statmp220 ; statmp221 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make (ATSstrcst("main_argc_argv")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_argc_argv, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_argc_argv = statmp221 ; statmp222 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2cstref_make (ATSstrcst("main_dummy")) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_dummy, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ats_main_dummy = statmp222 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_stadyncst2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_label_sats.c0000664000175000017500000000217512223166160021222 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_label_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_global_sats.c0000664000175000017500000000177112223166160021404 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_global_2esats__staload_flag = 1 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_global_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp1_sats.c0000664000175000017500000002661712223166160021537 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALchar_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALfloat_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALint_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALstring_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALcstsp_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTqid_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTtup_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGsrt_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGidsrt_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__SP1Tcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qprop_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qvars_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsrt_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsub_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_some_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_none_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eapp_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Echar_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eexi_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eextype_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eimp_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eint_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Einvar_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elam_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eqid_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eread_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etop_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etrans_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyarr_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_ext_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup2_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Euni_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eunion_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGall_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGseq_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGall_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGseq_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEprop_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEtype_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEview_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEviewtype_4) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8.tag = 8 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALchar_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALfloat_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALint_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALstring_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__V1ALcstsp_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTqid_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTtup_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGsrt_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__D1ATARGidsrt_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__SP1Tcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qprop_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qvars_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsrt_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsub_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_some_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WTHS1EXPLSTcons_none_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eann_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eapp_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Echar_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eexi_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eextype_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eimp_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eint_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Einvar_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elam_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eqid_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eread_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etop_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etrans_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyarr_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_ext_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup2_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Euni_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eunion_21.tag = 21 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGall_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1VARARGseq_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGall_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1EXPARGseq_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEprop_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEtype_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEview_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__WITHT1YPEviewtype_4.tag = 4 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp1_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp2_util1_dats.c0000664000175000017500000117567712223166160022653 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ #include "ats_intinf.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_7 ; typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_9 ; typedef struct { anairiats_rec_0 atslab_0 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_14 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_15 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_rec_17 ; typedef struct { anairiats_rec_17 atslab_0 ; } anairiats_sum_18 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_19 ; typedef struct { int tag ; atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_20 ; typedef struct { anairiats_rec_0 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_21 ; typedef struct { ats_ptr_type atslab_s2arg_loc ; ats_ptr_type atslab_s2arg_sym ; ats_ptr_type atslab_s2arg_srt ; } anairiats_rec_22 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_23 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_24 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDtype_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDview_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__DATAKINDviewtype_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2CSTLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt_ext_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Echar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eclo_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecrypt_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ecst_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatconptr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeff_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eeqeq_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eextype_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eint_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eintinf_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Elam_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetlt_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eout_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eproj_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eread_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Erefarg_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esel_21) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esize_22) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Esizeof_23) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etop_24) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etup_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyarr_26) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etylst_28) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eunion_31) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evar_32) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EVar_33) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Evararg_34) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0ind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1ind_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFset_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2ZEXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEcst_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEextype_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyarr_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEtyrec_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEunion_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2KEXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEapp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEcst_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEfun_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyarr_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyrec_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEunion_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEvar_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTbas_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTtup_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASpre_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASimp_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2RTBASdef_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_lte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_neq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_int) (ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSextern_val(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; ATSextern_val(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil) ; ATSextern_fun(ats_uint_type, atsopt_effset_add) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_effset_contain) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atsopt_effset_union) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_types) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_linearize) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2rtdat_s2rtdat) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscon) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sup) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sVarset) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_copy) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_sVarset) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset) (ats_ptr_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg) (ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt) (ats_ptr_type, ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tup_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt) (ats_ptr_type, ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt) (ats_ptr_type, atsopt_count_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed) (ats_int_type, ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst) (ats_int_type, ats_int_type, ats_int_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx) (ats_int_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx) (ats_int_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx) (ats_int_type, ats_ptr_type, ats_ptr_type, ats_ref_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_domain) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_0, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__lte_s2rtbas_s2rtbas) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__sasp__stasub_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; /* internal function declarations */ static ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_bool_type s2exp_contain_eff_34 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_bool_type s2explst_contain_eff_35 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_bool_type aux_38 (ats_ptr_type env0, ats_uint_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0, ats_uint_type env1) ; static ats_bool_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_bool_type s2exp_contain_effvar_39 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2explst_contain_effvar_40 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2eff_contain_s2exp_42 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type s2eff_contain_s2explst_43 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_47 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_59 (ats_ptr_type arg0) ; static ats_bool_type lte_s2explst_s2rtlst_60 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type test_62 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type filter_63 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux0_66 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux1_67 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type labs2explst_is_singleton_65 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_void_type aux01_70 (ats_int_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux1_72 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_ptr_type aux2_73 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_bool_type test_76 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_s2var_75 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_s2exp_77 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_s2explst_78 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_s2Varboundlst_79 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_labs2explst_80 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_s2explst_arg_81 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_s2Var_82 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_bool_type s2kexp_match_union_approx_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_bool_type s2kexp_match_union_84 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2cst_get_root_89 (ats_ptr_type arg0) ; static ats_ptr_type s2zexp_make_s2cst_90 (ats_ptr_type arg0) ; static ats_ptr_type aux_s2exp_92 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_s2exp_app_93 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type aux_s2explst_94 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_labs2explst_95 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type f_98 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_s2var_96 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_s2Var_97 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_int_type loop_100 (ats_ptr_type arg0, ats_int_type arg1) ; static ats_ptr_type loop_103 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_105 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type loop_108 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static anairiats_rec_0 loop_112 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type err1_114 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static anairiats_rec_0 err2_115 (ats_ptr_type arg0) ; static anairiats_rec_0 err3_116 (ats_ptr_type arg0) ; static anairiats_rec_0 aux_117 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type s2var_subst_118 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_120 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2Var_subst_119 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2exp_subst_flag_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2explst_subst_flag_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2explstlst_subst_flag_123 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type labs2explst_subst_flag_124 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type wths2explst_subst_flag_125 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2eff_subst_flag_126 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2lab_subst_flag_127 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2zexp_subst_flag_128 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type s2zexplst_subst_flag_129 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type labs2zexplst_subst_flag_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_void_type aux_s2exp_137 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2explst_138 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2explstlst_139 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_labs2explst_140 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_wths2explst_141 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2eff_142 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2lab_143 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2Var_144 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2zexp_145 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2zexplst_146 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_labs2zexplst_147 (ats_ptr_type arg0, ats_ref_type arg1) ; static ats_void_type aux_s2exp_149 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2explst_150 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2explstlst_151 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_labs2explst_152 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_wths2explst_153 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2eff_154 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2lab_155 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2var_156 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2Var_157 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2zexp_158 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_s2zexplst_159 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; static ats_void_type aux_labs2zexplst_160 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp534) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 2278(line=72, offs=4) -- 2363(line=73, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error2_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error2_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(2)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error2_0] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 2397(line=76, offs=4) -- 2459(line=76, offs=66) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_staexp2_util1)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 2463(line=77, offs=4) -- 2578(line=79, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_staexp2_util1)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 2770(line=88, offs=21) -- 3071(line=95, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__lte_s2rtbas_s2rtbas (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; ATSlocal (ats_int_type, tmp8) ; ATSlocal (ats_int_type, tmp9) ; ATSlocal (ats_int_type, tmp10) ; ATSlocal (ats_int_type, tmp11) ; ATSlocal (ats_bool_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__lte_s2rtbas_s2rtbas: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_3_1 ; } __ats_lab_0_2: tmp6 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp7 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp6, tmp7) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_3_1 ; } __ats_lab_1_2: tmp8 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp9 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp10 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_1) ; tmp11 = ats_caselptrlab_mac(anairiats_sum_2, arg1, atslab_2) ; tmp12 = atspre_lte_int_int (tmp8, tmp10) ; if (tmp12) { tmp5 = atspre_lte_int_int (tmp9, tmp11) ; } else { tmp5 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_3_1 ; } __ats_lab_2_2: tmp13 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2rtdat_s2rtdat (tmp13, tmp14) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: __ats_lab_3_1: __ats_lab_3_2: tmp5 = ats_false_bool ; break ; } while (0) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__lte_s2rtbas_s2rtbas] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 3150(line=100, offs=15) -- 3429(line=107, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_bool_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_7_1 ; } __ats_lab_4_2: tmp16 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp17 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__lte_s2rtbas_s2rtbas (tmp16, tmp17) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_7_1 ; } __ats_lab_5_2: tmp18 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp19 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp20 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp21 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp22 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst (tmp20, tmp18) ; if (tmp22) { arg0 = tmp19 ; arg1 = tmp21 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt ; // tail call } else { tmp15 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_7_0 ; } __ats_lab_6_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_7_1 ; } __ats_lab_6_2: tmp23 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp15 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst (tmp23, tmp24) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: __ats_lab_7_1: __ats_lab_7_2: tmp15 = ats_false_bool ; break ; } while (0) ; return (tmp15) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 3487(line=110, offs=21) -- 3682(line=116, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_bool_type, tmp30) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_10_1 ; } __ats_lab_8_2: tmp26 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp28 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp29 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp30 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp26, tmp28) ; if (tmp30) { arg0 = tmp27 ; arg1 = tmp29 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst ; // tail call } else { tmp25 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_10_1 ; } __ats_lab_9_2: tmp25 = ats_true_bool ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: __ats_lab_10_1: __ats_lab_10_2: tmp25 = ats_false_bool ; break ; } while (0) ; return (tmp25) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rtlst_s2rtlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 3759(line=121, offs=13) -- 3929(line=126, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_cls (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_cls: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_11_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp32)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_1, tmp32, atslab_0) ; tmp31 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp33, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_CLS) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: __ats_lab_13_1: tmp31 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: __ats_lab_14_1: tmp31 = ats_false_bool ; break ; } while (0) ; return (tmp31) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_cls] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 3977(line=129, offs=13) -- 4112(line=132, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_18_0 ; } __ats_lab_15_1: tmp35 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp35)->tag != 2) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp34 = ats_true_bool ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp34 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp34 = ats_false_bool ; break ; } while (0) ; return (tmp34) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_dat] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 4160(line=135, offs=13) -- 4330(line=140, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_int (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_int: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_22_0 ; } __ats_lab_19_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp37)->tag != 0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_1, tmp37, atslab_0) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp38, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_INT) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp36 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: __ats_lab_22_1: tmp36 = ats_false_bool ; break ; } while (0) ; return (tmp36) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_int] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 4399(line=145, offs=13) -- 4450(line=145, offs=64) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp39) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_fun: do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp39 = ats_true_bool ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: __ats_lab_24_1: tmp39 = ats_false_bool ; break ; } while (0) ; return (tmp39) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 4496(line=150, offs=14) -- 4657(line=156, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_prop (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_prop: do { /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_28_0 ; } __ats_lab_25_1: tmp41 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp41)->tag != 1) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp42 = ats_caselptrlab_mac(anairiats_sum_2, tmp41, atslab_0) ; tmp40 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp42, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_PROP) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp40 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp40 = ats_false_bool ; break ; } while (0) ; return (tmp40) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 4707(line=159, offs=14) -- 4868(line=165, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_type: do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_32_0 ; } __ats_lab_29_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)tmp44)->tag != 1) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp45 = ats_caselptrlab_mac(anairiats_sum_2, tmp44, atslab_0) ; tmp43 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp45, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPE) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp43 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: __ats_lab_32_1: tmp43 = ats_false_bool ; break ; } while (0) ; return (tmp43) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_type] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 4919(line=168, offs=15) -- 5101(line=174, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_t0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_t0ype: do { /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_36_0 ; } __ats_lab_33_1: tmp47 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp47)->tag != 1) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp48 = ats_caselptrlab_mac(anairiats_sum_2, tmp47, atslab_0) ; tmp46 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp48, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_T0YPE) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: __ats_lab_35_1: tmp46 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: __ats_lab_36_1: tmp46 = ats_false_bool ; break ; } while (0) ; return (tmp46) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_t0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 5152(line=177, offs=14) -- 5333(line=183, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_view: do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_37_1: tmp50 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp50)->tag != 1) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_2, tmp50, atslab_0) ; tmp49 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp51, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEW) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: __ats_lab_39_1: tmp49 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: __ats_lab_40_1: tmp49 = ats_false_bool ; break ; } while (0) ; return (tmp49) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_view] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 5387(line=186, offs=18) -- 5572(line=192, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype: do { /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_44_0 ; } __ats_lab_41_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp53)->tag != 1) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_2, tmp53, atslab_0) ; tmp52 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp54, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWTYPE) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp52 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: __ats_lab_44_1: tmp52 = ats_false_bool ; break ; } while (0) ; return (tmp52) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 5634(line=195, offs=22) -- 5743(line=198, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp55) ; ATSlocal (ats_ptr_type, tmp56) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype_fun: do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_46_0 ; } __ats_lab_45_1: tmp56 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp56 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype_fun ; // tail call break ; /* branch: __ats_lab_46 */ __ats_lab_46_0: __ats_lab_46_1: tmp55 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype (arg0) ; break ; } while (0) ; return (tmp55) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewtype_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 5806(line=201, offs=19) -- 5992(line=207, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewt0ype (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewt0ype: do { /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_50_0 ; } __ats_lab_47_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp58)->tag != 1) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp59 = ats_caselptrlab_mac(anairiats_sum_2, tmp58, atslab_0) ; tmp57 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp59, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_VIEWT0YPE) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: __ats_lab_49_1: tmp57 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: __ats_lab_50_1: tmp57 = ats_false_bool ; break ; } while (0) ; return (tmp57) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_viewt0ype] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 6069(line=212, offs=15) -- 6239(line=216, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_types (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_types: do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_54_0 ; } __ats_lab_51_1: tmp61 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp61)->tag != 1) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp62 = ats_caselptrlab_mac(anairiats_sum_2, tmp61, atslab_0) ; tmp60 = ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__eq_symbol_symbol (tmp62, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__symbol_TYPES) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: tmp60 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: __ats_lab_54_1: tmp60 = ats_false_bool ; break ; } while (0) ; return (tmp60) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_types] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 6313(line=222, offs=16) -- 6472(line=226, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_int_type, tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear: do { /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_58_0 ; } __ats_lab_55_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (((ats_sum_ptr_type)tmp64)->tag != 1) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp65 = ats_caselptrlab_mac(anairiats_sum_2, tmp64, atslab_2) ; tmp63 = atspre_gt_int_int (tmp65, 0) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: tmp63 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: __ats_lab_58_1: tmp63 = ats_false_bool ; break ; } while (0) ; return (tmp63) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 6530(line=230, offs=20) -- 6623(line=231, offs=73) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear_fun: do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp67 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear_fun ; // tail call break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: __ats_lab_60_1: tmp66 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (arg0) ; break ; } while (0) ; return (tmp66) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 6699(line=237, offs=15) -- 6867(line=241, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_int_type, tmp70) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_64_0 ; } __ats_lab_61_1: tmp69 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_62 */ __ats_lab_62_0: if (((ats_sum_ptr_type)tmp69)->tag != 1) { goto __ats_lab_63_0 ; } __ats_lab_62_1: tmp70 = ats_caselptrlab_mac(anairiats_sum_2, tmp69, atslab_1) ; tmp68 = atspre_gte_int_int (tmp70, 2) ; break ; /* branch: __ats_lab_63 */ __ats_lab_63_0: __ats_lab_63_1: tmp68 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: __ats_lab_64_1: tmp68 = ats_false_bool ; break ; } while (0) ; return (tmp68) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 6923(line=245, offs=19) -- 7014(line=246, offs=71) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp72 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun ; // tail call break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: __ats_lab_66_1: tmp71 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (arg0) ; break ; } while (0) ; return (tmp71) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 7072(line=250, offs=17) -- 7239(line=254, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_int_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program: do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_70_0 ; } __ats_lab_67_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp74)->tag != 1) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_2, tmp74, atslab_1) ; tmp73 = atspre_lt_int_int (tmp75, 2) ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: tmp73 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: __ats_lab_70_1: tmp73 = ats_false_bool ; break ; } while (0) ; return (tmp73) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 7299(line=258, offs=21) -- 7394(line=259, offs=75) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program_fun: do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp77 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program_fun ; // tail call break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: __ats_lab_72_1: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program (arg0) ; break ; } while (0) ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_program_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 7460(line=263, offs=23) -- 7603(line=267, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative: do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_76_0 ; } __ats_lab_73_1: tmp79 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_74 */ __ats_lab_74_0: if (((ats_sum_ptr_type)tmp79)->tag != 1) { goto __ats_lab_75_0 ; } __ats_lab_74_1: tmp78 = ats_true_bool ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: __ats_lab_75_1: tmp78 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_76 */ __ats_lab_76_0: __ats_lab_76_1: tmp78 = ats_false_bool ; break ; } while (0) ; return (tmp78) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 7675(line=271, offs=27) -- 7784(line=273, offs=35) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp81 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun ; // tail call break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: __ats_lab_78_1: tmp80 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (arg0) ; break ; } while (0) ; return (tmp80) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 7848(line=277, offs=15) -- 8007(line=281, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; ATSlocal (ats_int_type, tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed: do { /* branch: __ats_lab_79 */ __ats_lab_79_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_79_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)tmp83)->tag != 1) { goto __ats_lab_81_0 ; } __ats_lab_80_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_2, tmp83, atslab_1) ; tmp82 = atspre_eq_int_int (tmp84, 0) ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: tmp82 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: __ats_lab_82_1: tmp82 = ats_false_bool ; break ; } while (0) ; return (tmp82) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 8063(line=285, offs=19) -- 8154(line=286, offs=71) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed_fun: do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp86 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp86 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed_fun ; // tail call break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: __ats_lab_84_1: tmp85 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (arg0) ; break ; } while (0) ; return (tmp85) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 8231(line=292, offs=15) -- 8304(line=293, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun: do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp88 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; arg0 = tmp88 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun ; // tail call break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: tmp87 = arg0 ; break ; } while (0) ; return (tmp87) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_base_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 8358(line=298, offs=3) -- 8544(line=302, offs=46) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_datakind (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp89) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_datakind: do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_88_0 ; } __ats_lab_87_1: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; break ; /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_90_0 ; } __ats_lab_89_1: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp89 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; } while (0) ; return (tmp89) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_datakind] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 8595(line=306, offs=14) -- 8713(line=309, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp90) ; ATSlocal (ats_bool_type, tmp91) ; ATSlocal (ats_bool_type, tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize: tmp91 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (arg0) ; if (tmp91) { tmp90 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } else { tmp92 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_boxed (arg0) ; if (tmp92) { tmp90 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp90 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } /* end of [if] */ return (tmp90) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_readize] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 8841(line=318, offs=3) -- 9782(line=344, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc (ats_ptr_type arg0, ats_bool_type arg1, ats_bool_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_int_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; // ATSlocal_void (tmp97) ; ATSlocal (ats_int_type, tmp98) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc: if (arg1) { if (arg2) { tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } else { tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } /* end of [if] */ } else { do { /* branch: __ats_lab_91 */ __ats_lab_91_0: __ats_lab_91_1: if (!arg2) { goto __ats_lab_97_1 ; } do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_96_0 ; } __ats_lab_92_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; do { /* branch: __ats_lab_93 */ __ats_lab_93_0: if (tmp94 != 0) { goto __ats_lab_94_0 ; } __ats_lab_93_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (tmp94 != 1) { goto __ats_lab_95_0 ; } __ats_lab_94_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: /* tmp95 = */ prerr_loc_error2_0 (arg0) ; /* tmp96 = */ atspre_prerr_string (ATSstrcst(": a closure reference cannot be linear.")) ; /* tmp97 = */ atspre_prerr_newline () ; /* tmp93 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_96 */ __ats_lab_96_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_96_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; } while (0) ; break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: __ats_lab_97_1: do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_102_0 ; } __ats_lab_98_1: tmp98 = ats_caselptrlab_mac(anairiats_sum_5, arg3, atslab_0) ; do { /* branch: __ats_lab_99 */ __ats_lab_99_0: if (tmp98 != 0) { goto __ats_lab_100_0 ; } __ats_lab_99_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: if (tmp98 != 1) { goto __ats_lab_101_0 ; } __ats_lab_100_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: __ats_lab_101_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; break ; } while (0) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_102_1: tmp93 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; break ; } while (0) ; break ; } while (0) ; } /* end of [if] */ return (tmp93) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prf_lin_fc] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 9861(line=350, offs=3) -- 10124(line=357, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_eff (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_uint_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_uint_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_uint_type, tmp104) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_eff: do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp99 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_105_0 ; } __ats_lab_104_1: tmp100 = atsopt_effset_add (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil, arg1) ; tmp101 = (ats_sum_ptr_type)0 ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp99)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, tmp99, atslab_0, tmp100) ; ats_selptrset_mac(anairiats_sum_6, tmp99, atslab_1, tmp101) ; break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp104 = atsopt_effset_add (tmp102, arg1) ; tmp99 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp99)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, tmp99, atslab_0, tmp104) ; ats_selptrset_mac(anairiats_sum_6, tmp99, atslab_1, tmp103) ; break ; } while (0) ; return (tmp99) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 10203(line=361, offs=19) -- 10575(line=372, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_uint_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_uint_type, tmp108) ; ATSlocal (ats_ptr_type, tmp109) ; ATSlocal (ats_uint_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff: do { /* branch: __ats_lab_106 */ __ats_lab_106_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_107_0 ; } __ats_lab_106_1: __ats_lab_106_2: tmp105 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: __ats_lab_107_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_108_0 ; } __ats_lab_107_2: tmp105 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EFFall_0) ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_109_0 ; } __ats_lab_108_1: __ats_lab_108_2: tmp105 = arg1 ; break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: __ats_lab_109_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_110_0 ; } __ats_lab_109_2: tmp105 = arg0 ; break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_110_1: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_110_2: tmp106 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp107 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp108 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp109 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp110 = atsopt_effset_union (tmp106, tmp108) ; tmp111 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (tmp107, tmp109) ; tmp105 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp105)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, tmp105, atslab_0, tmp110) ; ats_selptrset_mac(anairiats_sum_6, tmp105, atslab_1, tmp111) ; break ; } while (0) ; return (tmp105) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_union_s2eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 10695(line=377, offs=5) -- 11111(line=390, offs=4) */ ATSstaticdec() ats_bool_type s2exp_contain_eff_34 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_ptr_type, tmp115) ; ATSlocal (ats_ptr_type, tmp116) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_ptr_type, tmp118) ; // ATSlocal_void (tmp119) ; // ATSlocal_void (tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; __ats_lab_s2exp_contain_eff_34: tmp113 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp114 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp113), atslab_s2exp_node) ; do { /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp114)->tag != 7) { goto __ats_lab_112_0 ; } __ats_lab_111_1: tmp115 = ats_caselptrlab_mac(anairiats_sum_1, tmp114, atslab_0) ; tmp112 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff (tmp115, arg1) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: if (((ats_sum_ptr_type)tmp114)->tag != 33) { goto __ats_lab_113_0 ; } __ats_lab_112_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_1, tmp114, atslab_0) ; tmp118 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc (tmp116) ; /* tmp117 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp118) ; /* tmp119 = */ atspre_prerr_string (ATSstrcst(": INTERNAL WARNING (ats_staexp2_util1)")) ; /* tmp120 = */ atspre_prerr_string (ATSstrcst(": s2exp_contain_eff: s2e0 = ")) ; /* tmp121 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp113) ; /* tmp122 = */ atspre_prerr_newline () ; tmp112 = ats_false_bool ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: __ats_lab_113_1: tmp112 = ats_false_bool ; break ; } while (0) ; return (tmp112) ; } /* end of [s2exp_contain_eff_34] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 11147(line=392, offs=5) -- 11446(line=401, offs=4) */ ATSstaticdec() ats_bool_type s2explst_contain_eff_35 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_bool_type, tmp126) ; __ats_lab_s2explst_contain_eff_35: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp124 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp125 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp126 = s2exp_contain_eff_34 (tmp124, arg1) ; if (tmp126) { tmp123 = ats_true_bool ; } else { arg0 = tmp125 ; arg1 = arg1 ; goto __ats_lab_s2explst_contain_eff_35 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: tmp123 = ats_false_bool ; break ; } while (0) ; return (tmp123) ; } /* end of [s2explst_contain_eff_35] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 11509(line=404, offs=19) -- 11917(line=419, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp127) ; ATSlocal (ats_uint_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_bool_type, tmp130) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff: do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp127 = ats_true_bool ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_118_0 ; } __ats_lab_117_1: tmp127 = ats_false_bool ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp130 = atsopt_effset_contain (tmp128, arg1) ; if (tmp130) { tmp127 = ats_true_bool ; } else { tmp127 = s2explst_contain_eff_35 (tmp129, arg1) ; } /* end of [if] */ break ; } while (0) ; return (tmp127) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 12004(line=423, offs=7) -- 12284(line=431, offs=26) */ ATSstaticdec() ats_bool_type aux_38 (ats_ptr_type env0, ats_uint_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_bool_type, tmp135) ; ATSlocal (ats_bool_type, tmp136) ; __ats_lab_aux_38: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_120_0 ; } __ats_lab_119_1: tmp133 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp134 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp135 = atsopt_effset_contain (env1, tmp133) ; if (tmp135) { tmp136 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_eff (env0, tmp133) ; if (tmp136) { arg0 = tmp134 ; goto __ats_lab_aux_38 ; // tail call } else { tmp132 = ats_false_bool ; } /* end of [if] */ } else { arg0 = tmp134 ; goto __ats_lab_aux_38 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_120 */ __ats_lab_120_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_120_1: tmp132 = ats_true_bool ; break ; } while (0) ; return (tmp132) ; } /* end of [aux_38] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_uint_type closure_env_1 ; } aux_38_closure_type ; ats_bool_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_38 (((aux_38_closure_type*)cloptr)->closure_env_0, ((aux_38_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_38_closure_init (aux_38_closure_type *p_clo, ats_ptr_type env0, ats_uint_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_38_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0, ats_uint_type env1) { aux_38_closure_type *p_clo = ATS_MALLOC(sizeof(aux_38_closure_type)) ; aux_38_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 11980(line=422, offs=22) -- 12336(line=435, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset (ats_ptr_type arg0, ats_uint_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp131) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset: tmp131 = aux_38 (arg0, arg1, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; return (tmp131) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 12428(line=439, offs=5) -- 12888(line=453, offs=4) */ ATSstaticdec() ats_bool_type s2exp_contain_effvar_39 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; // ATSlocal_void (tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; // ATSlocal_void (tmp145) ; // ATSlocal_void (tmp146) ; // ATSlocal_void (tmp147) ; // ATSlocal_void (tmp148) ; __ats_lab_s2exp_contain_effvar_39: tmp138 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp139 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp138), atslab_s2exp_node) ; do { /* branch: __ats_lab_121 */ __ats_lab_121_0: if (((ats_sum_ptr_type)tmp139)->tag != 7) { goto __ats_lab_122_0 ; } __ats_lab_121_1: tmp140 = ats_caselptrlab_mac(anairiats_sum_1, tmp139, atslab_0) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar (tmp140, arg1) ; break ; /* branch: __ats_lab_122 */ __ats_lab_122_0: if (((ats_sum_ptr_type)tmp139)->tag != 32) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_1, tmp139, atslab_0) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (arg1, tmp141) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: if (((ats_sum_ptr_type)tmp139)->tag != 33) { goto __ats_lab_124_0 ; } __ats_lab_123_1: tmp142 = ats_caselptrlab_mac(anairiats_sum_1, tmp139, atslab_0) ; tmp144 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc (tmp142) ; /* tmp143 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp144) ; /* tmp145 = */ atspre_prerr_string (ATSstrcst(": INTERNAL WARNING (ats_staexp2_util1)")) ; /* tmp146 = */ atspre_prerr_string (ATSstrcst(": s2exp_contain_effvar: s2e = ")) ; /* tmp147 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp138) ; /* tmp148 = */ atspre_prerr_newline () ; tmp137 = ats_false_bool ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: tmp137 = ats_false_bool ; break ; } while (0) ; return (tmp137) ; } /* end of [s2exp_contain_effvar_39] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 12927(line=455, offs=5) -- 13234(line=464, offs=4) */ ATSstaticdec() ats_bool_type s2explst_contain_effvar_40 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; ATSlocal (ats_bool_type, tmp152) ; __ats_lab_s2explst_contain_effvar_40: do { /* branch: __ats_lab_125 */ __ats_lab_125_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_126_0 ; } __ats_lab_125_1: tmp150 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp151 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp152 = s2exp_contain_effvar_39 (tmp150, arg1) ; if (tmp152) { tmp149 = ats_true_bool ; } else { arg0 = tmp151 ; arg1 = arg1 ; goto __ats_lab_s2explst_contain_effvar_40 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_126 */ __ats_lab_126_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_126_1: tmp149 = ats_false_bool ; break ; } while (0) ; return (tmp149) ; } /* end of [s2explst_contain_effvar_40] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 13306(line=468, offs=3) -- 13446(line=471, offs=64) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar: do { /* branch: __ats_lab_127 */ __ats_lab_127_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_128_0 ; } __ats_lab_127_1: tmp153 = ats_true_bool ; break ; /* branch: __ats_lab_128 */ __ats_lab_128_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp153 = ats_false_bool ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: tmp154 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; tmp153 = s2explst_contain_effvar_40 (tmp154, arg1) ; break ; } while (0) ; return (tmp153) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 13538(line=476, offs=5) -- 13994(line=490, offs=4) */ ATSstaticdec() ats_bool_type s2eff_contain_s2exp_42 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; // ATSlocal_void (tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; // ATSlocal_void (tmp165) ; // ATSlocal_void (tmp166) ; __ats_lab_s2eff_contain_s2exp_42: tmp156 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp157 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp156), atslab_s2exp_node) ; do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (((ats_sum_ptr_type)tmp157)->tag != 7) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp158 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_0) ; tmp155 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff (arg0, tmp158) ; break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: if (((ats_sum_ptr_type)tmp157)->tag != 32) { goto __ats_lab_132_0 ; } __ats_lab_131_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_0) ; tmp155 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effvar (arg0, tmp159) ; break ; /* branch: __ats_lab_132 */ __ats_lab_132_0: if (((ats_sum_ptr_type)tmp157)->tag != 33) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_1, tmp157, atslab_0) ; tmp162 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc (tmp160) ; /* tmp161 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (tmp162) ; /* tmp163 = */ atspre_prerr_string (ATSstrcst(": INTERNAL WARNING")) ; /* tmp164 = */ atspre_prerr_string (ATSstrcst(": s2eff_contain_s2exp: s2e2 = ")) ; /* tmp165 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp156) ; /* tmp166 = */ atspre_prerr_newline () ; tmp155 = ats_false_bool ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: __ats_lab_133_1: tmp155 = ats_false_bool ; break ; } while (0) ; return (tmp155) ; } /* end of [s2eff_contain_s2exp_42] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 14032(line=492, offs=5) -- 14311(line=501, offs=4) */ ATSstaticdec() ats_bool_type s2eff_contain_s2explst_43 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_bool_type, tmp170) ; __ats_lab_s2eff_contain_s2explst_43: do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp168 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp169 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp170 = s2eff_contain_s2exp_42 (arg0, tmp168) ; if (tmp170) { arg0 = arg0 ; arg1 = tmp169 ; goto __ats_lab_s2eff_contain_s2explst_43 ; // tail call } else { tmp167 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: tmp167 = ats_true_bool ; break ; } while (0) ; return (tmp167) ; } /* end of [s2eff_contain_s2explst_43] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 14380(line=505, offs=3) -- 14749(line=515, offs=8) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp171) ; ATSlocal (ats_uint_type, tmp172) ; ATSlocal (ats_ptr_type, tmp173) ; ATSlocal (ats_bool_type, tmp174) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: tmp171 = ats_true_bool ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: __ats_lab_137_1: do { /* branch: __ats_lab_138 */ __ats_lab_138_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: tmp171 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset (arg0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_140_0 ; } __ats_lab_139_1: tmp171 = ats_true_bool ; break ; /* branch: __ats_lab_140 */ __ats_lab_140_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_140_1: tmp172 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp173 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp174 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_effset (arg0, tmp172) ; if (tmp174) { tmp171 = s2eff_contain_s2explst_43 (arg0, tmp173) ; } else { tmp171 = ats_false_bool ; } /* end of [if] */ break ; } while (0) ; break ; } while (0) ; return (tmp171) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2eff_contain_s2eff] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 14840(line=521, offs=13) -- 15248(line=532, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lab_syneq (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lab_syneq: do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_142_0 ; } __ats_lab_141_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_145_1 ; } __ats_lab_141_2: tmp176 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp177 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp176, tmp177) ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_143_0 ; } __ats_lab_142_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_145_1 ; } __ats_lab_142_2: tmp178 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp179 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp178, tmp179) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_144_0 ; } __ats_lab_143_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_145_1 ; } __ats_lab_143_2: tmp180 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq (tmp180, tmp181) ; break ; /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_145_0 ; } __ats_lab_144_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_145_1 ; } __ats_lab_144_2: tmp182 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp175 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_syneq (tmp182, tmp183) ; break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: __ats_lab_145_1: __ats_lab_145_2: tmp175 = ats_false_bool ; break ; } while (0) ; return (tmp175) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lab_syneq] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 15793(line=548, offs=7) -- 16213(line=560, offs=6) */ ATSstaticdec() ats_ptr_type aux_47 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; __ats_lab_aux_47: do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_149_0 ; } __ats_lab_146_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; do { /* branch: __ats_lab_147 */ __ats_lab_147_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_148_0 ; } __ats_lab_147_1: tmp187 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; arg0 = tmp186 ; arg1 = tmp187 ; goto __ats_lab_aux_47 ; // tail call break ; /* branch: __ats_lab_148 */ __ats_lab_148_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_148_1: /* tmp188 = */ prerr_interror_1 () ; /* tmp189 = */ atspre_prerr_string (ATSstrcst(": s2lablst_trim")) ; /* tmp190 = */ atspre_prerr_newline () ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_149_1: tmp185 = arg1 ; break ; } while (0) ; return (tmp185) ; } /* end of [aux_47] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 15408(line=540, offs=3) -- 16575(line=570, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst: do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_153_0 ; } __ats_lab_150_1: tmp191 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; do { /* branch: __ats_lab_151 */ __ats_lab_151_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp192 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; arg0 = tmp191 ; arg1 = tmp192 ; arg2 = arg2 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst ; // tail call break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_152_1: tmp184 = aux_47 (arg0, arg2) ; break ; } while (0) ; break ; /* branch: __ats_lab_153 */ __ats_lab_153_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_153_1: tmp184 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_append (arg1, arg2) ; break ; } while (0) ; return (tmp184) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2lablst_trim_s2lablst_s2lablst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 16667(line=575, offs=16) -- 16703(line=575, offs=52) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof: tmp194 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp193 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp194) ; return (tmp193) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 16734(line=577, offs=20) -- 16774(line=577, offs=60) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof_fun: tmp196 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp195 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof_fun (tmp196) ; return (tmp195) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 16803(line=580, offs=17) -- 16840(line=580, offs=54) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear: tmp198 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp197 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp198) ; return (tmp197) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 16868(line=582, offs=17) -- 16930(line=583, offs=55) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp199) ; ATSlocal (ats_bool_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin: tmp201 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp200 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp201) ; if (tmp200) { tmp199 = ats_false_bool ; } else { tmp199 = ats_true_bool ; } /* end of [if] */ return (tmp199) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 16995(line=587, offs=3) -- 17039(line=587, offs=47) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative: tmp203 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp202 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_impredicative (tmp203) ; return (tmp202) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 17066(line=588, offs=26) -- 17102(line=588, offs=62) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_types (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_types: tmp205 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_srt) ; tmp204 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_types (tmp205) ; return (tmp204) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_types] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 17152(line=593, offs=17) -- 17360(line=599, offs=15) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; ATSlocal (ats_bool_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon: tmp207 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_154 */ __ats_lab_154_0: if (((ats_sum_ptr_type)tmp207)->tag != 4) { goto __ats_lab_155_0 ; } __ats_lab_154_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_1, tmp207, atslab_0) ; tmp209 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_abstract (tmp208) ; if (tmp209) { tmp206 = ats_true_bool ; } else { tmp206 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_iscon (tmp208) ; } /* end of [if] */ break ; /* branch: __ats_lab_155 */ __ats_lab_155_0: if (((ats_sum_ptr_type)tmp207)->tag != 0) { goto __ats_lab_156_0 ; } __ats_lab_155_1: tmp210 = ats_caselptrlab_mac(anairiats_sum_3, tmp207, atslab_0) ; arg0 = tmp210 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon ; // tail call break ; /* branch: __ats_lab_156 */ __ats_lab_156_0: __ats_lab_156_1: tmp206 = ats_false_bool ; break ; } while (0) ; return (tmp206) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_abscon] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 17418(line=603, offs=18) -- 17623(line=610, offs=14) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun: tmp212 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp212)->tag != 11) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp211 = ats_false_bool ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: if (((ats_sum_ptr_type)tmp212)->tag != 33) { goto __ats_lab_159_0 ; } __ats_lab_158_1: tmp211 = ats_false_bool ; break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: if (((ats_sum_ptr_type)tmp212)->tag != 30) { goto __ats_lab_160_0 ; } __ats_lab_159_1: tmp213 = ats_caselptrlab_mac(anairiats_sum_9, tmp212, atslab_2) ; tmp214 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp213) ; arg0 = tmp214 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun ; // tail call break ; /* branch: __ats_lab_160 */ __ats_lab_160_0: __ats_lab_160_1: tmp211 = ats_true_bool ; break ; } while (0) ; return (tmp211) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_fun] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 17683(line=614, offs=20) -- 17892(line=621, offs=14) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec: tmp216 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_161 */ __ats_lab_161_0: if (((ats_sum_ptr_type)tmp216)->tag != 29) { goto __ats_lab_162_0 ; } __ats_lab_161_1: tmp215 = ats_false_bool ; break ; /* branch: __ats_lab_162 */ __ats_lab_162_0: if (((ats_sum_ptr_type)tmp216)->tag != 33) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp215 = ats_false_bool ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp216)->tag != 9) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp217 = ats_caselptrlab_mac(anairiats_sum_9, tmp216, atslab_2) ; tmp218 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp217) ; arg0 = tmp218 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec ; // tail call break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: __ats_lab_164_1: tmp215 = ats_true_bool ; break ; } while (0) ; return (tmp215) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_non_tyrec] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 17948(line=625, offs=14) -- 18054(line=626, offs=75) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth: tmp220 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_165 */ __ats_lab_165_0: if (((ats_sum_ptr_type)tmp220)->tag != 9) { goto __ats_lab_166_0 ; } __ats_lab_165_1: tmp221 = ats_caselptrlab_mac(anairiats_sum_9, tmp220, atslab_2) ; arg0 = tmp221 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth ; // tail call break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: if (((ats_sum_ptr_type)tmp220)->tag != 35) { goto __ats_lab_167_0 ; } __ats_lab_166_1: tmp219 = ats_true_bool ; break ; /* branch: __ats_lab_167 */ __ats_lab_167_0: __ats_lab_167_1: tmp219 = ats_false_bool ; break ; } while (0) ; return (tmp219) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_wth] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 18146(line=633, offs=7) -- 18239(line=634, offs=67) */ ATSstaticdec() ats_ptr_type loop_59 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_loop_59: tmp224 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)tmp224)->tag != 0) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp225 = ats_caselptrlab_mac(anairiats_sum_3, tmp224, atslab_0) ; arg0 = tmp225 ; goto __ats_lab_loop_59 ; // tail call break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: __ats_lab_169_1: tmp223 = arg0 ; break ; } while (0) ; return (tmp223) ; } /* end of [loop_59] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 18127(line=632, offs=16) -- 18290(line=638, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_head (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp226) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_head: tmp226 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg0) ; tmp222 = loop_59 (tmp226) ; return (tmp222) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_get_head] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 18344(line=642, offs=5) -- 18824(line=657, offs=20) */ ATSstaticdec() ats_bool_type lte_s2explst_s2rtlst_60 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; ATSlocal (ats_bool_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; __ats_lab_lte_s2explst_s2rtlst_60: do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_171_0 ; } __ats_lab_170_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_172_1 ; } __ats_lab_170_2: tmp228 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp231 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp233 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp228), atslab_s2exp_srt) ; tmp232 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp233, tmp230) ; if (tmp232) { arg0 = tmp229 ; arg1 = tmp231 ; goto __ats_lab_lte_s2explst_s2rtlst_60 ; // tail call } else { tmp227 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_171 */ __ats_lab_171_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_172_0 ; } __ats_lab_171_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_172_1 ; } __ats_lab_171_2: tmp227 = ats_true_bool ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: __ats_lab_172_1: __ats_lab_172_2: tmp227 = ats_false_bool ; break ; } while (0) ; return (tmp227) ; } /* end of [lte_s2explst_s2rtlst_60] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 18920(line=662, offs=7) -- 19273(line=671, offs=21) */ ATSstaticdec() ats_bool_type test_62 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; ATSlocal (anairiats_rec_0, tmp239) ; ATSlocal (ats_bool_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp242) ; __ats_lab_test_62: do { /* branch: __ats_lab_173 */ __ats_lab_173_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_176_0 ; } __ats_lab_173_1: tmp236 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp237 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp238 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__un_s2rt_fun (arg0) ; do { /* branch: __ats_lab_174 */ __ats_lab_174_0: if (tmp238 == (ats_sum_ptr_type)0) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp239 = ats_caselptrlab_mac(anairiats_sum_10, tmp238, atslab_0) ; ATS_FREE(tmp238) ; tmp241 = ats_select_mac(tmp239, atslab_0) ; tmp240 = lte_s2explst_s2rtlst_60 (tmp236, tmp241) ; if (tmp240) { tmp242 = ats_select_mac(tmp239, atslab_1) ; arg0 = tmp242 ; arg1 = tmp237 ; goto __ats_lab_test_62 ; // tail call } else { tmp235 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: // if (tmp238 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_175_1: tmp235 = ats_false_bool ; break ; } while (0) ; break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_176_1: tmp235 = ats_true_bool ; break ; } while (0) ; return (tmp235) ; } /* end of [test_62] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 19280(line=672, offs=7) -- 19888(line=689, offs=39) */ ATSstaticdec() ats_ptr_type filter_63 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_bool_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; __ats_lab_filter_63: do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp244 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp245 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp247 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_srt (tmp244) ; tmp246 = test_62 (tmp247, arg1) ; if (tmp246) { tmp248 = filter_63 (tmp245, arg1) ; tmp243 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_0, tmp244) ; ats_selptrset_mac(anairiats_sum_4, tmp243, atslab_1, tmp248) ; } else { arg0 = tmp245 ; arg1 = arg1 ; goto __ats_lab_filter_63 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_178_1: tmp243 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp243) ; } /* end of [filter_63] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 18894(line=661, offs=26) -- 19918(line=692, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_select_s2explstlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_select_s2explstlst: tmp234 = filter_63 (arg0, arg1) ; return (tmp234) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_select_s2explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 20009(line=698, offs=3) -- 20261(line=707, offs=6) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_bool_type, tmp250) ; ATSlocal (ats_bool_type, tmp251) ; ATSlocal (ats_bool_type, tmp252) ; ATSlocal (ats_bool_type, tmp253) ; ATSlocal (ats_bool_type, tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed: tmp250 = atspre_gt_int_int (arg0, 0) ; if (tmp250) { tmp251 = atspre_gt_int_int (arg1, 0) ; if (tmp251) { tmp252 = atspre_gt_int_int (arg2, 0) ; if (tmp252) { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } else { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ } else { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_view ; } /* end of [if] */ } else { tmp253 = atspre_gt_int_int (arg1, 0) ; if (tmp253) { tmp254 = atspre_gt_int_int (arg2, 0) ; if (tmp254) { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } else { tmp249 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_prop ; } /* end of [if] */ } /* end of [if] */ return (tmp249) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 20405(line=713, offs=7) -- 20850(line=722, offs=8) */ ATSstaticdec() ats_ptr_type aux0_66 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_bool_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_int_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_ptr_type, tmp261) ; ATSlocal (ats_bool_type, tmp262) ; __ats_lab_aux0_66: tmp257 = atspre_gt_int_int (arg0, 0) ; if (tmp257) { do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp258 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp259 = atspre_sub_int_int (arg0, 1) ; arg0 = tmp259 ; arg1 = tmp258 ; goto __ats_lab_aux0_66 ; // tail call break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_180_1: tmp256 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } else { do { /* branch: __ats_lab_181 */ __ats_lab_181_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp260 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp261 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp262 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp260) ; if (tmp262) { arg0 = 0 ; arg1 = tmp261 ; goto __ats_lab_aux0_66 ; // tail call } else { tmp256 = aux1_67 (tmp260, tmp261) ; } /* end of [if] */ break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_182_1: tmp256 = (ats_sum_ptr_type)0 ; break ; } while (0) ; } /* end of [if] */ return (tmp256) ; } /* end of [aux0_66] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 20891(line=724, offs=7) -- 21161(line=729, offs=40) */ ATSstaticdec() ats_ptr_type aux1_67 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_bool_type, tmp266) ; __ats_lab_aux1_67: do { /* branch: __ats_lab_183 */ __ats_lab_183_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_184_0 ; } __ats_lab_183_1: tmp264 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp265 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp266 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp264) ; if (tmp266) { arg0 = arg0 ; arg1 = tmp265 ; goto __ats_lab_aux1_67 ; // tail call } else { tmp263 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_184 */ __ats_lab_184_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_184_1: tmp263 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp263, atslab_0, arg0) ; break ; } while (0) ; return (tmp263) ; } /* end of [aux1_67] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 20315(line=710, offs=4) -- 21207(line=733, offs=4) */ ATSstaticdec() ats_ptr_type labs2explst_is_singleton_65 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp255) ; __ats_lab_labs2explst_is_singleton_65: tmp255 = aux0_66 (arg0, arg1) ; return (tmp255) ; } /* end of [labs2explst_is_singleton_65] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 21296(line=737, offs=3) -- 21777(line=753, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (ats_int_type arg0, ats_int_type arg1, ats_int_type arg2, ats_int_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_bool_type, tmp269) ; ATSlocal (ats_bool_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_bool_type, tmp274) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst: tmp268 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed (arg0, arg1, arg2) ; tmp269 = atspre_gt_int_int (arg1, 0) ; if (tmp269) { tmp270 = atspre_gt_int_int (arg2, 0) ; if (tmp270) { tmp267 = tmp268 ; } else { tmp271 = labs2explst_is_singleton_65 (arg3, arg4) ; do { /* branch: __ats_lab_185 */ __ats_lab_185_0: if (tmp271 == (ats_sum_ptr_type)0) { goto __ats_lab_186_0 ; } __ats_lab_185_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_12, tmp271, atslab_0) ; ATS_FREE(tmp271) ; tmp273 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp272), atslab_s2exp_srt) ; tmp274 = atspre_gt_int_int (arg0, 0) ; if (tmp274) { tmp267 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_linearize (tmp273) ; } else { tmp267 = tmp273 ; } /* end of [if] */ break ; /* branch: __ats_lab_186 */ __ats_lab_186_0: // if (tmp271 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_186_1: tmp267 = tmp268 ; break ; } while (0) ; } /* end of [if] */ } else { tmp267 = tmp268 ; } /* end of [if] */ return (tmp267) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 22033(line=762, offs=7) -- 22500(line=774, offs=30) */ ATSstaticdec() ats_void_type aux01_70 (ats_int_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp279) ; ATSlocal (ats_ptr_type, tmp280) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; ATSlocal (ats_bool_type, tmp284) ; ATSlocal (ats_int_type, tmp285) ; ATSlocal (ats_bool_type, tmp287) ; ATSlocal (ats_bool_type, tmp288) ; ATSlocal (ats_bool_type, tmp289) ; ATSlocal (ats_int_type, tmp290) ; ATSlocal (ats_int_type, tmp291) ; __ats_lab_aux01_70: do { /* branch: __ats_lab_189 */ __ats_lab_189_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_190_0 ; } __ats_lab_189_1: tmp280 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_1) ; tmp281 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_2) ; tmp282 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp280), atslab_s2exp_srt) ; tmp284 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp282) ; if (tmp284) { tmp285 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp285 ; } else { /* empty */ } /* end of [if] */ tmp287 = atspre_gte_int_int (arg0, arg1) ; if (tmp287) { tmp289 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_proof (tmp282) ; tmp288 = atspre_neg_bool (tmp289) ; if (tmp288) { tmp290 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg4), 1) ; ats_ptrget_mac(ats_int_type, arg4) = tmp290 ; } else { /* empty */ } /* end of [if] */ } else { /* empty */ } /* end of [if] */ tmp291 = atspre_add_int_int (arg0, 1) ; arg0 = tmp291 ; arg1 = arg1 ; arg2 = tmp281 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux01_70 ; // tail call break ; /* branch: __ats_lab_190 */ __ats_lab_190_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_190_1: break ; } while (0) ; return /* (tmp279) */ ; } /* end of [aux01_70] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 21869(line=758, offs=13) -- 23150(line=797, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec (ats_int_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_int_type, tmp277) ; ATSlocal (ats_int_type, tmp278) ; ATSlocal (ats_ptr_type, tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; // ATSlocal_void (tmp295) ; // ATSlocal_void (tmp296) ; // ATSlocal_void (tmp297) ; // ATSlocal_void (tmp298) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec: do { /* branch: __ats_lab_187 */ __ats_lab_187_0: if (arg0 != 0) { goto __ats_lab_188_0 ; } __ats_lab_187_1: tmp276 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDflt0_1) ; break ; /* branch: __ats_lab_188 */ __ats_lab_188_0: __ats_lab_188_1: tmp276 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TYRECKINDbox_0) ; break ; } while (0) ; /* ats_int_type tmp277 ; */ tmp277 = 0 ; /* ats_int_type tmp278 ; */ tmp278 = 0 ; do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (arg0 != 0) { goto __ats_lab_192_0 ; } __ats_lab_191_1: /* tmp293 = */ aux01_70 (0, arg1, arg2, (&tmp277), (&tmp278)) ; tmp292 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed_npf_labs2explst (tmp277, tmp278, 0, arg1, arg2) ; break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: if (arg0 != 1) { goto __ats_lab_193_0 ; } __ats_lab_192_1: /* tmp294 = */ aux01_70 (0, arg1, arg2, (&tmp277), (&tmp278)) ; tmp292 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_lin_prg_boxed (tmp277, tmp278, 1) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: if (arg0 != 2) { goto __ats_lab_194_0 ; } __ats_lab_193_1: tmp292 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; break ; /* branch: __ats_lab_194 */ __ats_lab_194_0: if (arg0 != 3) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp292 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: __ats_lab_195_1: /* tmp295 = */ prerr_interror_1 () ; /* tmp296 = */ atspre_prerr_string (ATSstrcst(": s2exp_tyrec: recknd = ")) ; /* tmp297 = */ atspre_prerr_int (arg0) ; /* tmp298 = */ atspre_prerr_newline () ; /* tmp292 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp275 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp292, tmp276, arg1, arg2) ; return (tmp275) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 23241(line=803, offs=7) -- 23510(line=809, offs=30) */ ATSstaticdec() ats_void_type aux1_72 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp300) ; ATSlocal (ats_ptr_type, tmp301) ; ATSlocal (ats_ptr_type, tmp302) ; ATSlocal (ats_bool_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_int_type, tmp306) ; __ats_lab_aux1_72: do { /* branch: __ats_lab_196 */ __ats_lab_196_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_197_0 ; } __ats_lab_196_1: tmp301 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp302 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp305 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp301), atslab_s2exp_srt) ; tmp304 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_is_linear (tmp305) ; if (tmp304) { tmp306 = atspre_add_int_int (1, ats_ptrget_mac(ats_int_type, arg1)) ; ats_ptrget_mac(ats_int_type, arg1) = tmp306 ; } else { /* empty */ } /* end of [if] */ arg0 = tmp302 ; arg1 = arg1 ; goto __ats_lab_aux1_72 ; // tail call break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_197_1: break ; } while (0) ; return /* (tmp300) */ ; } /* end of [aux1_72] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 23536(line=811, offs=7) -- 23775(line=816, offs=38) */ ATSstaticdec() ats_ptr_type aux2_73 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_ptr_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_bool_type, tmp310) ; ATSlocal (ats_int_type, tmp311) ; __ats_lab_aux2_73: do { /* branch: __ats_lab_198 */ __ats_lab_198_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp308 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp309 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; tmp310 = atspre_eq_int_int (arg1, 0) ; if (tmp310) { tmp307 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp307, atslab_0, tmp308) ; } else { tmp311 = atspre_sub_int_int (arg1, 1) ; arg0 = tmp309 ; arg1 = tmp311 ; goto __ats_lab_aux2_73 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_199_1: tmp307 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp307) ; } /* end of [aux2_73] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 23198(line=800, offs=13) -- 24431(line=839, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union (ats_bool_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_int_type, tmp312) ; // ATSlocal_void (tmp313) ; ATSlocal (ats_ptr_type, tmp314) ; ATSlocal (ats_int_type, tmp315) ; ATSlocal (ats_bool_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_bool_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_bool_type, tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union: /* ats_int_type tmp312 ; */ tmp312 = 0 ; tmp314 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg2), atslab_s2exp_node) ; do { /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)tmp314)->tag != 12) { goto __ats_lab_203_0 ; } __ats_lab_200_1: tmp315 = ats_caselptrlab_mac(anairiats_sum_13, tmp314, atslab_0) ; tmp316 = atspre_gte_int_int (tmp315, 0) ; if (tmp316) { tmp317 = aux2_73 (arg3, tmp315) ; do { /* branch: __ats_lab_201 */ __ats_lab_201_0: if (tmp317 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp318 = ats_caselptrlab_mac(anairiats_sum_12, tmp317, atslab_0) ; ATS_FREE(tmp317) ; tmp319 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp318) ; if (tmp319) { tmp312 = 1 ; } else { tmp312 = 0 ; } /* end of [if] */ break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: // if (tmp317 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_202_1: tmp312 = 0 ; break ; } while (0) ; } else { tmp312 = 0 ; } /* end of [if] */ break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: __ats_lab_203_1: /* tmp313 = */ aux1_72 (arg3, (&tmp312)) ; break ; } while (0) ; tmp321 = atspre_gt_int_int (tmp312, 0) ; if (tmp321) { if (arg0) { tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewtype ; } else { tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_viewt0ype ; } /* end of [if] */ } else { if (arg0) { tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_type ; } else { tmp320 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2rt_t0ype ; } /* end of [if] */ } /* end of [if] */ tmp299 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp320, arg1, arg2, arg3) ; return (tmp299) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 24661(line=851, offs=13) -- 24904(line=856, offs=33) */ ATSstaticdec() ats_bool_type test_76 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_bool_type, tmp329) ; __ats_lab_test_76: do { /* branch: __ats_lab_205 */ __ats_lab_205_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_206_0 ; } __ats_lab_205_1: tmp327 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp328 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp329 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (tmp327, arg1) ; if (tmp329) { tmp326 = ats_true_bool ; } else { arg0 = tmp328 ; arg1 = arg1 ; goto __ats_lab_test_76 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_206 */ __ats_lab_206_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_206_1: tmp326 = ats_false_bool ; break ; } while (0) ; return (tmp326) ; } /* end of [test_76] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 24528(line=846, offs=7) -- 25053(line=860, offs=34) */ ATSstaticdec() ats_ptr_type aux_s2var_75 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_ptr_type, tmp325) ; ATSlocal (ats_bool_type, tmp330) ; __ats_lab_aux_s2var_75: do { /* branch: __ats_lab_204 */ __ats_lab_204_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_207_0 ; } __ats_lab_204_1: tmp324 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp325 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp330 = test_76 (tmp324, arg1) ; if (tmp330) { tmp323 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; } else { arg0 = tmp325 ; arg1 = arg1 ; goto __ats_lab_aux_s2var_75 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_207_1: tmp323 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp323)->tag = 7 ; ats_selptrset_mac(anairiats_sum_1, tmp323, atslab_0, arg1) ; break ; } while (0) ; return (tmp323) ; } /* end of [aux_s2var_75] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 25087(line=863, offs=7) -- 26572(line=899, offs=7) */ ATSstaticdec() ats_ptr_type aux_s2exp_77 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; ATSlocal (ats_ptr_type, tmp342) ; ATSlocal (ats_ptr_type, tmp343) ; ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; __ats_lab_aux_s2exp_77: tmp332 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg2) ; tmp333 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp332), atslab_s2exp_node) ; do { /* branch: __ats_lab_208 */ __ats_lab_208_0: if (((ats_sum_ptr_type)tmp333)->tag != 0) { goto __ats_lab_211_0 ; } __ats_lab_208_1: tmp334 = ats_caselptrlab_mac(anairiats_sum_3, tmp333, atslab_0) ; tmp335 = ats_caselptrlab_mac(anairiats_sum_3, tmp333, atslab_1) ; tmp336 = aux_s2exp_77 (0, arg1, tmp334) ; tmp337 = aux_s2explst_arg_81 (0, arg1, tmp335) ; do { /* branch: __ats_lab_209 */ __ats_lab_209_0: if (tmp337 == (ats_sum_ptr_type)0) { goto __ats_lab_210_0 ; } __ats_lab_209_1: tmp331 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp331)->tag = 1 ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_0, tmp336) ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_1, tmp337) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: // if (tmp337 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_210_1: tmp331 = tmp336 ; break ; } while (0) ; break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)tmp333)->tag != 4) { goto __ats_lab_212_0 ; } __ats_lab_211_1: tmp338 = ats_caselptrlab_mac(anairiats_sum_1, tmp333, atslab_0) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp331)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp331, atslab_0, tmp338) ; break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)tmp333)->tag != 9) { goto __ats_lab_213_0 ; } __ats_lab_212_1: tmp339 = ats_caselptrlab_mac(anairiats_sum_9, tmp333, atslab_0) ; tmp340 = ats_caselptrlab_mac(anairiats_sum_9, tmp333, atslab_2) ; tmp341 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp341, atslab_0, tmp339) ; ats_selptrset_mac(anairiats_sum_4, tmp341, atslab_1, arg1) ; arg0 = arg0 ; arg1 = tmp341 ; arg2 = tmp340 ; goto __ats_lab_aux_s2exp_77 ; // tail call break ; /* branch: __ats_lab_213 */ __ats_lab_213_0: if (((ats_sum_ptr_type)tmp333)->tag != 11) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp342 = ats_caselptrlab_mac(anairiats_sum_14, tmp333, atslab_0) ; tmp343 = ats_caselptrlab_mac(anairiats_sum_14, tmp333, atslab_4) ; tmp344 = ats_caselptrlab_mac(anairiats_sum_14, tmp333, atslab_5) ; tmp345 = aux_s2explst_78 (0, arg1, tmp343) ; tmp346 = aux_s2exp_77 (0, arg1, tmp344) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp331)->tag = 3 ; ats_selptrset_mac(anairiats_sum_9, tmp331, atslab_0, tmp342) ; ats_selptrset_mac(anairiats_sum_9, tmp331, atslab_1, tmp345) ; ats_selptrset_mac(anairiats_sum_9, tmp331, atslab_2, tmp346) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: if (((ats_sum_ptr_type)tmp333)->tag != 19) { goto __ats_lab_215_0 ; } __ats_lab_214_1: tmp347 = ats_caselptrlab_mac(anairiats_sum_3, tmp333, atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp347 ; goto __ats_lab_aux_s2exp_77 ; // tail call break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)tmp333)->tag != 20) { goto __ats_lab_216_0 ; } __ats_lab_215_1: tmp348 = ats_caselptrlab_mac(anairiats_sum_15, tmp333, atslab_1) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp348 ; goto __ats_lab_aux_s2exp_77 ; // tail call break ; /* branch: __ats_lab_216 */ __ats_lab_216_0: if (((ats_sum_ptr_type)tmp333)->tag != 26) { goto __ats_lab_217_0 ; } __ats_lab_216_1: tmp331 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEtyarr_4) ; break ; /* branch: __ats_lab_217 */ __ats_lab_217_0: if (((ats_sum_ptr_type)tmp333)->tag != 29) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp349 = ats_caselptrlab_mac(anairiats_sum_16, tmp333, atslab_0) ; tmp350 = ats_caselptrlab_mac(anairiats_sum_16, tmp333, atslab_2) ; tmp351 = aux_labs2explst_80 (arg0, arg1, tmp350) ; tmp331 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp331)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_0, tmp349) ; ats_selptrset_mac(anairiats_sum_3, tmp331, atslab_1, tmp351) ; break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: if (((ats_sum_ptr_type)tmp333)->tag != 30) { goto __ats_lab_219_0 ; } __ats_lab_218_1: tmp352 = ats_caselptrlab_mac(anairiats_sum_9, tmp333, atslab_0) ; tmp353 = ats_caselptrlab_mac(anairiats_sum_9, tmp333, atslab_2) ; tmp354 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp354, atslab_0, tmp352) ; ats_selptrset_mac(anairiats_sum_4, tmp354, atslab_1, arg1) ; arg0 = arg0 ; arg1 = tmp354 ; arg2 = tmp353 ; goto __ats_lab_aux_s2exp_77 ; // tail call break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: if (((ats_sum_ptr_type)tmp333)->tag != 32) { goto __ats_lab_220_0 ; } __ats_lab_219_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_1, tmp333, atslab_0) ; tmp331 = aux_s2var_75 (arg1, tmp355) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)tmp333)->tag != 33) { goto __ats_lab_221_0 ; } __ats_lab_220_1: tmp356 = ats_caselptrlab_mac(anairiats_sum_1, tmp333, atslab_0) ; tmp331 = aux_s2Var_82 (arg0, arg1, tmp356) ; break ; /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp333)->tag != 35) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_3, tmp333, atslab_0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = tmp357 ; goto __ats_lab_aux_s2exp_77 ; // tail call break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: __ats_lab_222_1: tmp331 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; break ; } while (0) ; return (tmp331) ; } /* end of [aux_s2exp_77] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 26604(line=901, offs=7) -- 26872(line=907, offs=33) */ ATSstaticdec() ats_ptr_type aux_s2explst_78 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; __ats_lab_aux_s2explst_78: do { /* branch: __ats_lab_223 */ __ats_lab_223_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_224_0 ; } __ats_lab_223_1: tmp359 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp360 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp361 = aux_s2exp_77 (arg0, arg1, tmp359) ; tmp362 = aux_s2explst_78 (arg0, arg1, tmp360) ; tmp358 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp358, atslab_0, tmp361) ; ats_selptrset_mac(anairiats_sum_4, tmp358, atslab_1, tmp362) ; break ; /* branch: __ats_lab_224 */ __ats_lab_224_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_224_1: tmp358 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp358) ; } /* end of [aux_s2explst_78] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 26909(line=910, offs=7) -- 27262(line=919, offs=33) */ ATSstaticdec() ats_ptr_type aux_s2Varboundlst_79 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; __ats_lab_aux_s2Varboundlst_79: do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp364 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp367 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp364) ; tmp366 = aux_s2exp_77 (arg0, arg1, tmp367) ; tmp368 = aux_s2Varboundlst_79 (arg0, arg1, tmp365) ; tmp363 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp363, atslab_0, tmp366) ; ats_selptrset_mac(anairiats_sum_4, tmp363, atslab_1, tmp368) ; break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_226_1: tmp363 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp363) ; } /* end of [aux_s2Varboundlst_79] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 27304(line=922, offs=7) -- 27596(line=928, offs=46) */ ATSstaticdec() ats_ptr_type aux_labs2explst_80 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; __ats_lab_aux_labs2explst_80: do { /* branch: __ats_lab_227 */ __ats_lab_227_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_228_0 ; } __ats_lab_227_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_0) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_1) ; tmp372 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_2) ; tmp373 = aux_s2exp_77 (arg0, arg1, tmp371) ; tmp374 = aux_labs2explst_80 (arg0, arg1, tmp372) ; tmp369 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp369, atslab_0, tmp370) ; ats_selptrset_mac(anairiats_sum_11, tmp369, atslab_1, tmp373) ; ats_selptrset_mac(anairiats_sum_11, tmp369, atslab_2, tmp374) ; break ; /* branch: __ats_lab_228 */ __ats_lab_228_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_228_1: tmp369 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp369) ; } /* end of [aux_labs2explst_80] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 27636(line=931, offs=7) -- 28008(line=939, offs=33) */ ATSstaticdec() ats_ptr_type aux_s2explst_arg_81 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_bool_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; __ats_lab_aux_s2explst_arg_81: do { /* branch: __ats_lab_229 */ __ats_lab_229_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_230_0 ; } __ats_lab_229_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp377 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp378 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_impredicative (tmp376) ; if (tmp378) { tmp379 = aux_s2exp_77 (arg0, arg1, tmp376) ; tmp380 = aux_s2explst_78 (arg0, arg1, tmp377) ; tmp375 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp375, atslab_0, tmp379) ; ats_selptrset_mac(anairiats_sum_4, tmp375, atslab_1, tmp380) ; } else { tmp375 = aux_s2explst_78 (arg0, arg1, tmp377) ; } /* end of [if] */ break ; /* branch: __ats_lab_230 */ __ats_lab_230_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_230_1: tmp375 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp375) ; } /* end of [aux_s2explst_arg_81] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 28049(line=942, offs=7) -- 28230(line=947, offs=20) */ ATSstaticdec() ats_ptr_type aux_s2Var_82 (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_bool_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; __ats_lab_aux_s2Var_82: tmp382 = atspre_gt_int_int (arg0, 0) ; if (tmp382) { tmp384 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg2) ; tmp383 = aux_s2Varboundlst_79 (arg0, arg1, tmp384) ; tmp381 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp381)->tag = 6 ; ats_selptrset_mac(anairiats_sum_1, tmp381, atslab_0, tmp383) ; } else { tmp381 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2KEany_0) ; } /* end of [if] */ return (tmp381) ; } /* end of [aux_s2Var_82] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 24506(line=844, offs=19) -- 28299(line=952, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp385) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp: tmp385 = (ats_sum_ptr_type)0 ; tmp322 = aux_s2exp_77 (1, tmp385, arg0) ; return (tmp322) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_make_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 28350(line=956, offs=5) -- 28696(line=966, offs=4) */ ATSstaticdec() ats_bool_type s2kexp_match_union_approx_83 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_bool_type, tmp386) ; ATSlocal (ats_ptr_type, tmp387) ; ATSlocal (ats_ptr_type, tmp388) ; ATSlocal (ats_bool_type, tmp389) ; __ats_lab_s2kexp_match_union_approx_83: do { /* branch: __ats_lab_231 */ __ats_lab_231_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp387 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp388 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp389 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx (1, tmp387, arg1, arg2) ; if (tmp389) { arg0 = tmp388 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_s2kexp_match_union_approx_83 ; // tail call } else { tmp386 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_232_1: tmp386 = ats_true_bool ; break ; } while (0) ; return (tmp386) ; } /* end of [s2kexp_match_union_approx_83] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 28733(line=968, offs=5) -- 28881(line=972, offs=4) */ ATSstaticdec() ats_bool_type s2kexp_match_union_84 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp390) ; ATSlocal (ats_int_type, tmp391) ; __ats_lab_s2kexp_match_union_84: /* ats_int_type tmp391 ; */ tmp391 = 0 ; tmp390 = s2kexp_match_union_approx_83 (arg0, arg1, (&tmp391)) ; return (tmp390) ; } /* end of [s2kexp_match_union_84] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 28946(line=976, offs=3) -- 30571(line=1020, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_bool_type, tmp392) ; ATSlocal (ats_ptr_type, tmp393) ; ATSlocal (ats_ptr_type, tmp394) ; ATSlocal (ats_ptr_type, tmp395) ; ATSlocal (ats_ptr_type, tmp396) ; ATSlocal (ats_bool_type, tmp397) ; ATSlocal (ats_ptr_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_bool_type, tmp400) ; ATSlocal (ats_bool_type, tmp401) ; ATSlocal (ats_bool_type, tmp402) ; ATSlocal (ats_int_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_ptr_type, tmp409) ; ATSlocal (ats_bool_type, tmp410) ; ATSlocal (ats_ptr_type, tmp411) ; ATSlocal (ats_ptr_type, tmp412) ; ATSlocal (ats_ptr_type, tmp413) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx: do { /* branch: __ats_lab_233 */ __ats_lab_233_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_234_0 ; } __ats_lab_233_1: __ats_lab_233_2: tmp392 = ats_true_bool ; break ; /* branch: __ats_lab_234 */ __ats_lab_234_0: __ats_lab_234_1: if (((ats_sum_ptr_type)arg2)->tag != 0) { goto __ats_lab_235_1 ; } __ats_lab_234_2: tmp392 = ats_true_bool ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: __ats_lab_235_1: if (((ats_sum_ptr_type)arg2)->tag != 6) { goto __ats_lab_236_0 ; } __ats_lab_235_2: tmp392 = ats_true_bool ; break ; /* branch: __ats_lab_236 */ __ats_lab_236_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_237_0 ; } __ats_lab_236_1: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_243_1 ; } __ats_lab_236_2: tmp393 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp394 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp395 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp396 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp397 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx (0, tmp393, tmp395, arg3) ; if (tmp397) { tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx (0, tmp394, tmp396, arg3) ; } else { tmp392 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_238_0 ; } __ats_lab_237_1: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_243_1 ; } __ats_lab_237_2: tmp398 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp399 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp400 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2cst_s2cst (tmp398, tmp399) ; if (tmp400) { tmp392 = ats_true_bool ; } else { tmp401 = atspre_gt_int_int (arg0, 0) ; if (tmp401) { tmp402 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_is_eqsup (tmp398, tmp399) ; if (tmp402) { tmp403 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg3), 1) ; ats_ptrget_mac(ats_int_type, arg3) = tmp403 ; tmp392 = ats_true_bool ; } else { tmp392 = ats_false_bool ; } /* end of [if] */ } else { tmp392 = ats_false_bool ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_238 */ __ats_lab_238_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_239_0 ; } __ats_lab_238_1: if (((ats_sum_ptr_type)arg2)->tag != 3) { goto __ats_lab_243_1 ; } __ats_lab_238_2: tmp404 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp405 = ats_caselptrlab_mac(anairiats_sum_9, arg2, atslab_0) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__eq_funclo_funclo (tmp404, tmp405) ; break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_240_0 ; } __ats_lab_239_1: if (((ats_sum_ptr_type)arg2)->tag != 4) { goto __ats_lab_243_1 ; } __ats_lab_239_2: tmp392 = ats_true_bool ; break ; /* branch: __ats_lab_240 */ __ats_lab_240_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_241_0 ; } __ats_lab_240_1: if (((ats_sum_ptr_type)arg2)->tag != 5) { goto __ats_lab_243_1 ; } __ats_lab_240_2: tmp406 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp407 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp408 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp409 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp410 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_tyreckind_tyreckind (tmp406, tmp408) ; if (tmp410) { tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx (arg0, tmp407, tmp409, arg3) ; } else { tmp392 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_241 */ __ats_lab_241_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_242_0 ; } __ats_lab_241_1: if (((ats_sum_ptr_type)arg2)->tag != 7) { goto __ats_lab_243_1 ; } __ats_lab_241_2: tmp411 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp412 = ats_caselptrlab_mac(anairiats_sum_1, arg2, atslab_0) ; tmp392 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (tmp411, tmp412) ; break ; /* branch: __ats_lab_242 */ __ats_lab_242_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_243_0 ; } __ats_lab_242_1: __ats_lab_242_2: tmp413 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp392 = s2kexp_match_union_84 (tmp413, arg2) ; break ; /* branch: __ats_lab_243 */ __ats_lab_243_0: __ats_lab_243_1: __ats_lab_243_2: tmp392 = ats_false_bool ; break ; } while (0) ; return (tmp392) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 30640(line=1024, offs=3) -- 31055(line=1036, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_bool_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; ATSlocal (ats_ptr_type, tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_bool_type, tmp419) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx: do { /* branch: __ats_lab_244 */ __ats_lab_244_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_245_0 ; } __ats_lab_244_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_246_1 ; } __ats_lab_244_2: tmp415 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp416 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp417 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp418 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp419 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx (arg0, tmp415, tmp417, arg3) ; if (tmp419) { arg0 = arg0 ; arg1 = tmp416 ; arg2 = tmp418 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx ; // tail call } else { tmp414 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_245 */ __ats_lab_245_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_246_0 ; } __ats_lab_245_1: if (arg2 != (ats_sum_ptr_type)0) { goto __ats_lab_246_1 ; } __ats_lab_245_2: tmp414 = ats_true_bool ; break ; /* branch: __ats_lab_246 */ __ats_lab_246_0: __ats_lab_246_1: __ats_lab_246_2: tmp414 = ats_false_bool ; break ; } while (0) ; return (tmp414) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 31130(line=1040, offs=3) -- 31621(line=1052, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx (ats_int_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_bool_type, tmp420) ; ATSlocal (ats_ptr_type, tmp421) ; ATSlocal (ats_ptr_type, tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_ptr_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; ATSlocal (ats_bool_type, tmp427) ; ATSlocal (ats_bool_type, tmp428) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx: do { /* branch: __ats_lab_247 */ __ats_lab_247_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_248_0 ; } __ats_lab_247_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_249_1 ; } __ats_lab_247_2: tmp421 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp422 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp423 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp424 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_0) ; tmp425 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_1) ; tmp426 = ats_caselptrlab_mac(anairiats_sum_11, arg2, atslab_2) ; tmp427 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp421, tmp424) ; if (tmp427) { tmp428 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_approx (arg0, tmp422, tmp425, arg3) ; if (tmp428) { arg0 = arg0 ; arg1 = tmp423 ; arg2 = tmp426 ; arg3 = arg3 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx ; // tail call } else { tmp420 = ats_false_bool ; } /* end of [if] */ } else { tmp420 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_248 */ __ats_lab_248_0: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_249_0 ; } __ats_lab_248_1: if (arg2 != (ats_sum_ptr_type)0) { goto __ats_lab_249_1 ; } __ats_lab_248_2: tmp420 = ats_true_bool ; break ; /* branch: __ats_lab_249 */ __ats_lab_249_0: __ats_lab_249_1: __ats_lab_249_2: tmp420 = ats_false_bool ; break ; } while (0) ; return (tmp420) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__labs2kexplst_match_approx] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 31694(line=1056, offs=3) -- 32213(line=1072, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_fun_arg (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp429) ; ATSlocal (ats_ptr_type, tmp430) ; ATSlocal (ats_ptr_type, tmp431) ; ATSlocal (ats_int_type, tmp432) ; ATSlocal (ats_bool_type, tmp433) ; ATSlocal (anairiats_rec_17, tmp434) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_fun_arg: do { /* branch: __ats_lab_250 */ __ats_lab_250_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_251_0 ; } __ats_lab_250_1: tmp430 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp431 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; /* ats_int_type tmp432 ; */ tmp432 = 0 ; tmp433 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexplst_match_approx (1, arg1, tmp430, (&tmp432)) ; if (tmp433) { tmp434.atslab_0 = tmp431 ; tmp434.atslab_1 = tmp432 ; tmp429 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ats_selptrset_mac(anairiats_sum_18, tmp429, atslab_0, tmp434) ; } else { tmp429 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_251 */ __ats_lab_251_0: __ats_lab_251_1: tmp429 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp429) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2kexp_match_fun_arg] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 32273(line=1076, offs=5) -- 32414(line=1078, offs=72) */ ATSstaticdec() ats_ptr_type s2cst_get_root_89 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; ATSlocal (ats_ptr_type, tmp437) ; __ats_lab_s2cst_get_root_89: tmp436 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sup (arg0) ; do { /* branch: __ats_lab_252 */ __ats_lab_252_0: if (tmp436 == (ats_sum_ptr_type)0) { goto __ats_lab_253_0 ; } __ats_lab_252_1: tmp437 = ats_caselptrlab_mac(anairiats_sum_4, tmp436, atslab_0) ; arg0 = tmp437 ; goto __ats_lab_s2cst_get_root_89 ; // tail call break ; /* branch: __ats_lab_253 */ __ats_lab_253_0: // if (tmp436 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_253_1: tmp435 = arg0 ; break ; } while (0) ; return (tmp435) ; } /* end of [s2cst_get_root_89] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 32446(line=1081, offs=4) -- 32500(line=1081, offs=58) */ ATSstaticdec() ats_ptr_type s2zexp_make_s2cst_90 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp438) ; __ats_lab_s2zexp_make_s2cst_90: tmp438 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp438)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp438, atslab_0, arg0) ; return (tmp438) ; } /* end of [s2zexp_make_s2cst_90] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 32552(line=1086, offs=7) -- 34432(line=1131, offs=6) */ ATSstaticdec() ats_ptr_type aux_s2exp_92 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_ptr_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; ATSlocal (ats_ptr_type, tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; ATSlocal (ats_ptr_type, tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_int_type, tmp450) ; ATSlocal (ats_bool_type, tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; ATSlocal (ats_ptr_type, tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (ats_ptr_type, tmp464) ; ATSlocal (ats_ptr_type, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_ptr_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (atsopt_count_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (ats_ptr_type, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_aux_s2exp_92: tmp441 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp442 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp441), atslab_s2exp_node) ; do { /* branch: __ats_lab_254 */ __ats_lab_254_0: if (((ats_sum_ptr_type)tmp442)->tag != 0) { goto __ats_lab_255_0 ; } __ats_lab_254_1: tmp443 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_0) ; tmp444 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_1) ; tmp445 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp441), atslab_s2exp_srt) ; tmp440 = aux_s2exp_app_93 (arg0, tmp445, tmp443, tmp444) ; break ; /* branch: __ats_lab_255 */ __ats_lab_255_0: if (((ats_sum_ptr_type)tmp442)->tag != 4) { goto __ats_lab_258_0 ; } __ats_lab_255_1: tmp446 = ats_caselptrlab_mac(anairiats_sum_1, tmp442, atslab_0) ; tmp447 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs (tmp446) ; do { /* branch: __ats_lab_256 */ __ats_lab_256_0: if (tmp447 == (ats_sum_ptr_type)0) { goto __ats_lab_257_0 ; } tmp448 = ats_caselptrlab_mac(anairiats_sum_12, tmp447, atslab_0) ; if (tmp448 == (ats_sum_ptr_type)0) { goto __ats_lab_257_0 ; } __ats_lab_256_1: tmp449 = ats_caselptrlab_mac(anairiats_sum_12, tmp448, atslab_0) ; arg0 = arg0 ; arg1 = tmp449 ; goto __ats_lab_aux_s2exp_92 ; // tail call break ; /* branch: __ats_lab_257 */ __ats_lab_257_0: __ats_lab_257_1: tmp440 = s2zexp_make_s2cst_90 (tmp446) ; break ; } while (0) ; break ; /* branch: __ats_lab_258 */ __ats_lab_258_0: if (((ats_sum_ptr_type)tmp442)->tag != 2) { goto __ats_lab_259_0 ; } __ats_lab_258_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_0) ; tmp451 = atspre_neq_int_int (tmp450, 0) ; if (tmp451) { tmp440 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; } else { tmp440 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; } /* end of [if] */ break ; /* branch: __ats_lab_259 */ __ats_lab_259_0: if (((ats_sum_ptr_type)tmp442)->tag != 5) { goto __ats_lab_260_0 ; } __ats_lab_259_1: tmp452 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_0) ; tmp453 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (tmp452) ; tmp440 = s2zexp_make_s2cst_90 (tmp453) ; break ; /* branch: __ats_lab_260 */ __ats_lab_260_0: if (((ats_sum_ptr_type)tmp442)->tag != 6) { goto __ats_lab_261_0 ; } __ats_lab_260_1: tmp454 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_0) ; tmp455 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (tmp454) ; tmp440 = s2zexp_make_s2cst_90 (tmp455) ; break ; /* branch: __ats_lab_261 */ __ats_lab_261_0: if (((ats_sum_ptr_type)tmp442)->tag != 9) { goto __ats_lab_262_0 ; } __ats_lab_261_1: tmp456 = ats_caselptrlab_mac(anairiats_sum_9, tmp442, atslab_0) ; tmp457 = ats_caselptrlab_mac(anairiats_sum_9, tmp442, atslab_2) ; tmp458 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp458, atslab_0, tmp456) ; ats_selptrset_mac(anairiats_sum_4, tmp458, atslab_1, arg0) ; arg0 = tmp458 ; arg1 = tmp457 ; goto __ats_lab_aux_s2exp_92 ; // tail call break ; /* branch: __ats_lab_262 */ __ats_lab_262_0: if (((ats_sum_ptr_type)tmp442)->tag != 10) { goto __ats_lab_263_0 ; } __ats_lab_262_1: tmp459 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_0) ; tmp440 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp440)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp440, atslab_0, tmp459) ; break ; /* branch: __ats_lab_263 */ __ats_lab_263_0: if (((ats_sum_ptr_type)tmp442)->tag != 11) { goto __ats_lab_264_0 ; } __ats_lab_263_1: tmp440 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; break ; /* branch: __ats_lab_264 */ __ats_lab_264_0: if (((ats_sum_ptr_type)tmp442)->tag != 19) { goto __ats_lab_265_0 ; } __ats_lab_264_1: tmp460 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_1) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (tmp460) ; break ; /* branch: __ats_lab_265 */ __ats_lab_265_0: if (((ats_sum_ptr_type)tmp442)->tag != 22) { goto __ats_lab_266_0 ; } __ats_lab_265_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_1, tmp442, atslab_0) ; tmp440 = tmp461 ; break ; /* branch: __ats_lab_266 */ __ats_lab_266_0: if (((ats_sum_ptr_type)tmp442)->tag != 24) { goto __ats_lab_267_0 ; } __ats_lab_266_1: tmp462 = ats_caselptrlab_mac(anairiats_sum_15, tmp442, atslab_1) ; tmp440 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (tmp462) ; break ; /* branch: __ats_lab_267 */ __ats_lab_267_0: if (((ats_sum_ptr_type)tmp442)->tag != 26) { goto __ats_lab_268_0 ; } __ats_lab_267_1: tmp463 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_0) ; tmp464 = ats_caselptrlab_mac(anairiats_sum_3, tmp442, atslab_1) ; tmp465 = aux_s2exp_92 (arg0, tmp463) ; tmp440 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp440)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp440, atslab_0, tmp465) ; ats_selptrset_mac(anairiats_sum_3, tmp440, atslab_1, tmp464) ; break ; /* branch: __ats_lab_268 */ __ats_lab_268_0: if (((ats_sum_ptr_type)tmp442)->tag != 29) { goto __ats_lab_272_0 ; } __ats_lab_268_1: tmp466 = ats_caselptrlab_mac(anairiats_sum_16, tmp442, atslab_0) ; tmp467 = ats_caselptrlab_mac(anairiats_sum_16, tmp442, atslab_2) ; do { /* branch: __ats_lab_269 */ __ats_lab_269_0: if (((ats_sum_ptr_type)tmp466)->tag != 0) { goto __ats_lab_270_0 ; } __ats_lab_269_1: tmp440 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEptr_4) ; break ; /* branch: __ats_lab_270 */ __ats_lab_270_0: if (((ats_sum_ptr_type)tmp466)->tag != 3) { goto __ats_lab_271_0 ; } __ats_lab_270_1: tmp468 = ats_caselptrlab_mac(anairiats_sum_1, tmp466, atslab_0) ; tmp440 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp440)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp440, atslab_0, tmp468) ; break ; /* branch: __ats_lab_271 */ __ats_lab_271_0: __ats_lab_271_1: tmp469 = aux_labs2explst_95 (arg0, tmp467) ; tmp440 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp440)->tag = 6 ; ats_selptrset_mac(anairiats_sum_3, tmp440, atslab_0, tmp466) ; ats_selptrset_mac(anairiats_sum_3, tmp440, atslab_1, tmp469) ; break ; } while (0) ; break ; /* branch: __ats_lab_272 */ __ats_lab_272_0: if (((ats_sum_ptr_type)tmp442)->tag != 30) { goto __ats_lab_273_0 ; } __ats_lab_272_1: tmp470 = ats_caselptrlab_mac(anairiats_sum_9, tmp442, atslab_0) ; tmp471 = ats_caselptrlab_mac(anairiats_sum_9, tmp442, atslab_2) ; tmp472 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp472, atslab_0, tmp470) ; ats_selptrset_mac(anairiats_sum_4, tmp472, atslab_1, arg0) ; arg0 = tmp472 ; arg1 = tmp471 ; goto __ats_lab_aux_s2exp_92 ; // tail call break ; /* branch: __ats_lab_273 */ __ats_lab_273_0: if (((ats_sum_ptr_type)tmp442)->tag != 31) { goto __ats_lab_274_0 ; } __ats_lab_273_1: tmp473 = ats_caselptrlab_mac(anairiats_sum_19, tmp442, atslab_0) ; tmp474 = ats_caselptrlab_mac(anairiats_sum_19, tmp442, atslab_2) ; tmp475 = aux_labs2explst_95 (arg0, tmp474) ; tmp440 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp440)->tag = 7 ; ats_selptrset_mac(anairiats_sum_20, tmp440, atslab_0, tmp473) ; ats_selptrset_mac(anairiats_sum_20, tmp440, atslab_1, tmp475) ; break ; /* branch: __ats_lab_274 */ __ats_lab_274_0: if (((ats_sum_ptr_type)tmp442)->tag != 32) { goto __ats_lab_275_0 ; } __ats_lab_274_1: tmp476 = ats_caselptrlab_mac(anairiats_sum_1, tmp442, atslab_0) ; tmp440 = aux_s2var_96 (arg0, tmp476) ; break ; /* branch: __ats_lab_275 */ __ats_lab_275_0: if (((ats_sum_ptr_type)tmp442)->tag != 33) { goto __ats_lab_276_0 ; } __ats_lab_275_1: tmp477 = ats_caselptrlab_mac(anairiats_sum_1, tmp442, atslab_0) ; tmp440 = aux_s2Var_97 (arg0, tmp477) ; break ; /* branch: __ats_lab_276 */ __ats_lab_276_0: __ats_lab_276_1: tmp440 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; break ; } while (0) ; return (tmp440) ; } /* end of [aux_s2exp_92] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 34464(line=1133, offs=7) -- 35029(line=1145, offs=22) */ ATSstaticdec() ats_ptr_type aux_s2exp_app_93 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; ATSlocal (ats_ptr_type, tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; ATSlocal (ats_ptr_type, tmp484) ; ATSlocal (ats_ptr_type, tmp485) ; __ats_lab_aux_s2exp_app_93: tmp479 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg2), atslab_s2exp_node) ; do { /* branch: __ats_lab_277 */ __ats_lab_277_0: if (((ats_sum_ptr_type)tmp479)->tag != 4) { goto __ats_lab_280_0 ; } __ats_lab_277_1: tmp480 = ats_caselptrlab_mac(anairiats_sum_1, tmp479, atslab_0) ; tmp481 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_isabs (tmp480) ; do { /* branch: __ats_lab_278 */ __ats_lab_278_0: if (tmp481 == (ats_sum_ptr_type)0) { goto __ats_lab_279_0 ; } tmp482 = ats_caselptrlab_mac(anairiats_sum_12, tmp481, atslab_0) ; if (tmp482 == (ats_sum_ptr_type)0) { goto __ats_lab_279_0 ; } __ats_lab_278_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_12, tmp482, atslab_0) ; tmp484 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (arg1, tmp483, arg3) ; tmp478 = aux_s2exp_92 (arg0, tmp484) ; break ; /* branch: __ats_lab_279 */ __ats_lab_279_0: __ats_lab_279_1: tmp485 = s2cst_get_root_89 (tmp480) ; tmp478 = s2zexp_make_s2cst_90 (tmp485) ; break ; } while (0) ; break ; /* branch: __ats_lab_280 */ __ats_lab_280_0: __ats_lab_280_1: tmp478 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; break ; } while (0) ; return (tmp478) ; } /* end of [aux_s2exp_app_93] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 35083(line=1148, offs=7) -- 35356(line=1153, offs=33) */ ATSstaticdec() ats_ptr_type aux_s2explst_94 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp486) ; ATSlocal (ats_ptr_type, tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; __ats_lab_aux_s2explst_94: do { /* branch: __ats_lab_281 */ __ats_lab_281_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_282_0 ; } __ats_lab_281_1: tmp487 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp488 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp489 = aux_s2exp_92 (arg0, tmp487) ; tmp490 = aux_s2explst_94 (arg0, tmp488) ; tmp486 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp486, atslab_0, tmp489) ; ats_selptrset_mac(anairiats_sum_4, tmp486, atslab_1, tmp490) ; break ; /* branch: __ats_lab_282 */ __ats_lab_282_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_282_1: tmp486 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp486) ; } /* end of [aux_s2explst_94] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 35393(line=1156, offs=7) -- 35886(line=1169, offs=46) */ ATSstaticdec() ats_ptr_type aux_labs2explst_95 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp491) ; ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; ATSlocal (ats_ptr_type, tmp494) ; ATSlocal (ats_bool_type, tmp495) ; ATSlocal (ats_ptr_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; __ats_lab_aux_labs2explst_95: do { /* branch: __ats_lab_283 */ __ats_lab_283_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_284_0 ; } __ats_lab_283_1: tmp492 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp493 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp494 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp495 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_proof (tmp493) ; if (tmp495) { arg0 = arg0 ; arg1 = tmp494 ; goto __ats_lab_aux_labs2explst_95 ; // tail call } else { tmp496 = aux_s2exp_92 (arg0, tmp493) ; tmp497 = aux_labs2explst_95 (arg0, tmp494) ; tmp491 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp491, atslab_0, tmp492) ; ats_selptrset_mac(anairiats_sum_11, tmp491, atslab_1, tmp496) ; ats_selptrset_mac(anairiats_sum_11, tmp491, atslab_2, tmp497) ; } /* end of [if] */ break ; /* branch: __ats_lab_284 */ __ats_lab_284_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_284_1: tmp491 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp491) ; } /* end of [aux_labs2explst_95] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 36050(line=1175, offs=13) -- 36233(line=1178, offs=33) */ ATSstaticdec() ats_bool_type f_98 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; ATSlocal (ats_bool_type, tmp504) ; __ats_lab_f_98: do { /* branch: __ats_lab_286 */ __ats_lab_286_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_287_0 ; } __ats_lab_286_1: tmp502 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp503 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp504 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (arg1, tmp502) ; if (tmp504) { tmp501 = ats_true_bool ; } else { arg0 = tmp503 ; arg1 = arg1 ; goto __ats_lab_f_98 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_287 */ __ats_lab_287_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_287_1: tmp501 = ats_false_bool ; break ; } while (0) ; return (tmp501) ; } /* end of [f_98] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 35926(line=1172, offs=7) -- 36379(line=1182, offs=34) */ ATSstaticdec() ats_ptr_type aux_s2var_96 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; ATSlocal (ats_ptr_type, tmp500) ; ATSlocal (ats_bool_type, tmp505) ; __ats_lab_aux_s2var_96: do { /* branch: __ats_lab_285 */ __ats_lab_285_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_288_0 ; } __ats_lab_285_1: tmp499 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp500 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp505 = f_98 (tmp499, arg1) ; if (tmp505) { tmp498 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; } else { arg0 = tmp500 ; arg1 = arg1 ; goto __ats_lab_aux_s2var_96 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_288 */ __ats_lab_288_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_288_1: tmp498 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp498)->tag = 8 ; ats_selptrset_mac(anairiats_sum_1, tmp498, atslab_0, arg1) ; break ; } while (0) ; return (tmp498) ; } /* end of [aux_s2var_96] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 36413(line=1185, offs=7) -- 36982(line=1201, offs=6) */ ATSstaticdec() ats_ptr_type aux_s2Var_97 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp506) ; ATSlocal (ats_ptr_type, tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; ATSlocal (ats_ptr_type, tmp509) ; ATSlocal (ats_ptr_type, tmp510) ; ATSlocal (ats_ptr_type, tmp511) ; ATSlocal (ats_ptr_type, tmp512) ; __ats_lab_aux_s2Var_97: tmp507 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_lbs (arg1) ; do { /* branch: __ats_lab_289 */ __ats_lab_289_0: if (tmp507 == (ats_sum_ptr_type)0) { goto __ats_lab_290_0 ; } __ats_lab_289_1: tmp508 = ats_caselptrlab_mac(anairiats_sum_4, tmp507, atslab_0) ; tmp509 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp508) ; tmp506 = aux_s2exp_92 (arg0, tmp509) ; break ; /* branch: __ats_lab_290 */ __ats_lab_290_0: // if (tmp507 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_290_1: tmp510 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_ubs (arg1) ; do { /* branch: __ats_lab_291 */ __ats_lab_291_0: if (tmp510 == (ats_sum_ptr_type)0) { goto __ats_lab_292_0 ; } __ats_lab_291_1: tmp511 = ats_caselptrlab_mac(anairiats_sum_4, tmp510, atslab_0) ; tmp512 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varbound_get_val (tmp511) ; tmp506 = aux_s2exp_92 (arg0, tmp512) ; break ; /* branch: __ats_lab_292 */ __ats_lab_292_0: // if (tmp510 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_292_1: tmp506 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2ZEbot_1) ; break ; } while (0) ; break ; } while (0) ; return (tmp506) ; } /* end of [aux_s2Var_97] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 32530(line=1084, offs=19) -- 37043(line=1204, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp439) ; ATSlocal (ats_ptr_type, tmp513) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp: tmp513 = (ats_sum_ptr_type)0 ; tmp439 = aux_s2exp_92 (tmp513, arg0) ; return (tmp439) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37156(line=1210, offs=7) -- 37269(line=1211, offs=67) */ ATSstaticdec() ats_int_type loop_100 (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; ATSlocal (ats_int_type, tmp517) ; __ats_lab_loop_100: do { /* branch: __ats_lab_293 */ __ats_lab_293_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_294_0 ; } __ats_lab_293_1: tmp516 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp517 = atspre_iadd (arg1, 1) ; arg0 = tmp516 ; arg1 = tmp517 ; goto __ats_lab_loop_100 ; // tail call break ; /* branch: __ats_lab_294 */ __ats_lab_294_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_294_1: tmp515 = arg1 ; break ; } while (0) ; return (tmp515) ; } /* end of [loop_100] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37122(line=1209, offs=17) -- 37271(line=1212, offs=2) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_length (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp514) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_length: tmp514 = loop_100 (arg0, 0) ; return (tmp514) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_length] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37327(line=1215, offs=17) -- 37445(line=1217, offs=25) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append: do { /* branch: __ats_lab_295 */ __ats_lab_295_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_296_0 ; } __ats_lab_295_1: tmp519 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp520 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp521 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append (tmp520, arg1) ; tmp518 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp518, atslab_0, tmp519) ; ats_selptrset_mac(anairiats_sum_4, tmp518, atslab_1, tmp521) ; break ; /* branch: __ats_lab_296 */ __ats_lab_296_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_296_1: tmp518 = arg1 ; break ; } while (0) ; return (tmp518) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_append] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37519(line=1222, offs=7) -- 37669(line=1225, offs=27) */ ATSstaticdec() ats_ptr_type loop_103 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; ATSlocal (ats_ptr_type, tmp526) ; __ats_lab_loop_103: do { /* branch: __ats_lab_297 */ __ats_lab_297_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_298_0 ; } __ats_lab_297_1: tmp524 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp525 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; tmp526 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp526, atslab_0, tmp524) ; ats_selptrset_mac(anairiats_sum_4, tmp526, atslab_1, arg1) ; arg0 = tmp525 ; arg1 = tmp526 ; goto __ats_lab_loop_103 ; // tail call break ; /* branch: __ats_lab_298 */ __ats_lab_298_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_298_1: tmp523 = arg1 ; break ; } while (0) ; return (tmp523) ; } /* end of [loop_103] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37502(line=1221, offs=18) -- 37723(line=1229, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp527) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_reverse: tmp527 = (ats_sum_ptr_type)0 ; tmp522 = loop_103 (arg0, tmp527) ; return (tmp522) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cstlst_reverse] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37798(line=1233, offs=7) -- 37909(line=1234, offs=66) */ ATSstaticdec() ats_ptr_type loop_105 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (anairiats_rec_0, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; ATSlocal (ats_ptr_type, tmp532) ; __ats_lab_loop_105: do { /* branch: __ats_lab_299 */ __ats_lab_299_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_300_0 ; } __ats_lab_299_1: tmp530 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_0) ; tmp531 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_1) ; tmp532 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp532, atslab_0, tmp530) ; ats_selptrset_mac(anairiats_sum_21, tmp532, atslab_1, arg1) ; arg0 = tmp531 ; arg1 = tmp532 ; goto __ats_lab_loop_105 ; // tail call break ; /* branch: __ats_lab_300 */ __ats_lab_300_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_300_1: tmp529 = arg1 ; break ; } while (0) ; return (tmp529) ; } /* end of [loop_105] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 37781(line=1232, offs=18) -- 37960(line=1238, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp533) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse: tmp533 = (ats_sum_ptr_type)0 ; tmp528 = loop_105 (arg0, tmp533) ; return (tmp528) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2qualst_reverse] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 38134(line=1246, offs=22) -- 38170(line=1246, offs=58) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (anairiats_rec_0, tmp536) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add: tmp536.atslab_0 = arg1 ; tmp536.atslab_1 = arg2 ; tmp535 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp535, atslab_0, tmp536) ; ats_selptrset_mac(anairiats_sum_21, tmp535, atslab_1, arg0) ; return (tmp535) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 38225(line=1249, offs=7) -- 38518(line=1256, offs=20) */ ATSstaticdec() ats_ptr_type loop_108 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; ATSlocal (ats_ptr_type, tmp542) ; ATSlocal (ats_ptr_type, tmp543) ; __ats_lab_loop_108: do { /* branch: __ats_lab_301 */ __ats_lab_301_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_302_0 ; } __ats_lab_301_1: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_302_1 ; } __ats_lab_301_2: tmp539 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp540 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp541 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp542 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp543 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (arg0, tmp539, tmp541) ; arg0 = tmp543 ; arg1 = tmp540 ; arg2 = tmp542 ; goto __ats_lab_loop_108 ; // tail call break ; /* branch: __ats_lab_302 */ __ats_lab_302_0: __ats_lab_302_1: __ats_lab_302_2: tmp538 = arg0 ; break ; } while (0) ; return (tmp538) ; } /* end of [loop_108] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 38195(line=1248, offs=15) -- 38569(line=1260, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_addlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp537) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_addlst: tmp537 = loop_108 (arg0, arg1, arg2) ; return (tmp537) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_addlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 38627(line=1264, offs=3) -- 38759(line=1267, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_domain (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (anairiats_rec_0, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_domain: do { /* branch: __ats_lab_303 */ __ats_lab_303_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_304_0 ; } __ats_lab_303_1: tmp545 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_0) ; tmp546 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_1) ; tmp547 = ats_select_mac(tmp545, atslab_0) ; tmp548 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_domain (tmp546) ; tmp544 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp544, atslab_0, tmp547) ; ats_selptrset_mac(anairiats_sum_4, tmp544, atslab_1, tmp548) ; break ; /* branch: __ats_lab_304 */ __ats_lab_304_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_304_1: tmp544 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp544) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_domain] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 38828(line=1272, offs=3) -- 39035(line=1277, offs=31) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp549) ; ATSlocal (anairiats_rec_0, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; ATSlocal (ats_ptr_type, tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf: do { /* branch: __ats_lab_305 */ __ats_lab_305_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_306_0 ; } __ats_lab_305_1: tmp550 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_0) ; tmp551 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_1) ; tmp553 = ats_select_mac(tmp550, atslab_1) ; tmp552 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp553) ; tmp554 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf (tmp551) ; tmp549 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp549, atslab_0, tmp552) ; ats_selptrset_mac(anairiats_sum_4, tmp549, atslab_1, tmp554) ; break ; /* branch: __ats_lab_306 */ __ats_lab_306_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_306_1: tmp549 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp549) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_get_codomain_whnf] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 39151(line=1284, offs=7) -- 39497(line=1293, offs=52) */ ATSstaticdec() anairiats_rec_0 loop_112 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; ATSlocal (ats_ptr_type, tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (anairiats_rec_0, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; __ats_lab_loop_112: do { /* branch: __ats_lab_307 */ __ats_lab_307_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_308_0 ; } __ats_lab_307_1: tmp557 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; tmp558 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_1) ; tmp559 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_copy (tmp557) ; tmp560 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp559) ; tmp562.atslab_0 = tmp557 ; tmp562.atslab_1 = tmp560 ; tmp561 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp561, atslab_0, tmp562) ; ats_selptrset_mac(anairiats_sum_21, tmp561, atslab_1, arg0) ; tmp563 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp563, atslab_0, tmp559) ; ats_selptrset_mac(anairiats_sum_4, tmp563, atslab_1, arg1) ; arg0 = tmp561 ; arg1 = tmp563 ; arg2 = tmp558 ; goto __ats_lab_loop_112 ; // tail call break ; /* branch: __ats_lab_308 */ __ats_lab_308_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_308_1: tmp564 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg1) ; tmp556.atslab_0 = arg0 ; tmp556.atslab_1 = tmp564 ; break ; } while (0) ; return (tmp556) ; } /* end of [loop_112] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 39127(line=1283, offs=23) -- 39550(line=1297, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp555) ; ATSlocal (ats_ptr_type, tmp565) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst: tmp565 = (ats_sum_ptr_type)0 ; tmp555 = loop_112 (arg0, tmp565, arg1) ; return (tmp555) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 39668(line=1303, offs=6) -- 39931(line=1310, offs=6) */ ATSstaticdec() ats_ptr_type err1_114 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp567) ; // ATSlocal_void (tmp568) ; // ATSlocal_void (tmp569) ; // ATSlocal_void (tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; // ATSlocal_void (tmp572) ; // ATSlocal_void (tmp573) ; // ATSlocal_void (tmp574) ; // ATSlocal_void (tmp575) ; __ats_lab_err1_114: /* tmp568 = */ prerr_loc_error2_0 (arg0) ; /* tmp569 = */ atspre_prerr_string (ATSstrcst(": the static argument [")) ; tmp571 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, arg2), atslab_s2arg_sym) ; /* tmp570 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__prerr_symbol (tmp571) ; /* tmp572 = */ atspre_prerr_string (ATSstrcst("] is expected to be of sort [")) ; /* tmp573 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (arg1) ; /* tmp574 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp575 = */ atspre_prerr_newline () ; /* tmp567 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp567) ; } /* end of [err1_114] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 39957(line=1312, offs=6) -- 40152(line=1317, offs=6) */ ATSstaticdec() anairiats_rec_0 err2_115 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp576) ; // ATSlocal_void (tmp577) ; // ATSlocal_void (tmp578) ; // ATSlocal_void (tmp579) ; __ats_lab_err2_115: /* tmp577 = */ prerr_loc_error2_0 (arg0) ; /* tmp578 = */ atspre_prerr_string (ATSstrcst(": the static application is expected to have fewer arguments.")) ; /* tmp579 = */ atspre_prerr_newline () ; /* tmp576 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp576) ; } /* end of [err2_115] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 40178(line=1319, offs=6) -- 40372(line=1324, offs=6) */ ATSstaticdec() anairiats_rec_0 err3_116 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp580) ; // ATSlocal_void (tmp581) ; // ATSlocal_void (tmp582) ; // ATSlocal_void (tmp583) ; __ats_lab_err3_116: /* tmp581 = */ prerr_loc_error2_0 (arg0) ; /* tmp582 = */ atspre_prerr_string (ATSstrcst(": the static application is expected to have more arguments.")) ; /* tmp583 = */ atspre_prerr_newline () ; /* tmp580 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return (tmp580) ; } /* end of [err3_116] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 40399(line=1326, offs=7) -- 41210(line=1346, offs=47) */ ATSstaticdec() anairiats_rec_0 aux_117 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp584) ; ATSlocal (ats_ptr_type, tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; ATSlocal (ats_ptr_type, tmp588) ; ATSlocal (ats_ptr_type, tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; ATSlocal (ats_ptr_type, tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; ATSlocal (ats_ptr_type, tmp593) ; ATSlocal (ats_bool_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (anairiats_rec_0, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; ATSlocal (ats_ptr_type, tmp600) ; __ats_lab_aux_117: do { /* branch: __ats_lab_309 */ __ats_lab_309_0: if (arg3 != (ats_sum_ptr_type)0) { goto __ats_lab_310_0 ; } __ats_lab_309_1: if (arg4 != (ats_sum_ptr_type)0) { goto __ats_lab_314_1 ; } __ats_lab_309_2: tmp585 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg2) ; tmp584.atslab_0 = arg1 ; tmp584.atslab_1 = tmp585 ; break ; /* branch: __ats_lab_310 */ __ats_lab_310_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_313_0 ; } __ats_lab_310_1: if (arg4 == (ats_sum_ptr_type)0) { goto __ats_lab_313_1 ; } __ats_lab_310_2: tmp586 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_0) ; tmp587 = ats_caselptrlab_mac(anairiats_sum_4, arg3, atslab_1) ; tmp588 = ats_caselptrlab_mac(anairiats_sum_4, arg4, atslab_0) ; tmp589 = ats_caselptrlab_mac(anairiats_sum_4, arg4, atslab_1) ; tmp590 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp588) ; tmp592 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, tmp586), atslab_s2arg_srt) ; do { /* branch: __ats_lab_311 */ __ats_lab_311_0: if (tmp592 == (ats_sum_ptr_type)0) { goto __ats_lab_312_0 ; } __ats_lab_311_1: tmp593 = ats_caselptrlab_mac(anairiats_sum_12, tmp592, atslab_0) ; tmp594 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp590, tmp593) ; if (tmp594) { tmp591 = tmp593 ; } else { tmp591 = err1_114 (arg0, tmp590, tmp586) ; } /* end of [if] */ break ; /* branch: __ats_lab_312 */ __ats_lab_312_0: // if (tmp592 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_312_1: tmp591 = tmp590 ; break ; } while (0) ; tmp596 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_22, tmp586), atslab_s2arg_sym) ; tmp595 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_make_id_srt (tmp596, tmp591) ; tmp599 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (tmp595) ; tmp598.atslab_0 = tmp588 ; tmp598.atslab_1 = tmp599 ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp597, atslab_0, tmp598) ; ats_selptrset_mac(anairiats_sum_21, tmp597, atslab_1, arg1) ; tmp600 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp600, atslab_0, tmp595) ; ats_selptrset_mac(anairiats_sum_4, tmp600, atslab_1, arg2) ; arg0 = arg0 ; arg1 = tmp597 ; arg2 = tmp600 ; arg3 = tmp587 ; arg4 = tmp589 ; goto __ats_lab_aux_117 ; // tail call break ; /* branch: __ats_lab_313 */ __ats_lab_313_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_314_0 ; } __ats_lab_313_1: // if (arg4 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_313_2: tmp584 = err2_115 (arg0) ; break ; /* branch: __ats_lab_314 */ __ats_lab_314_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_314_1: // if (arg4 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_314_2: tmp584 = err3_116 (arg0) ; break ; } while (0) ; return (tmp584) ; } /* end of [aux_117] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 39628(line=1301, offs=3) -- 41273(line=1350, offs=4) */ ATSglobaldec() anairiats_rec_0 ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_sarglst_svarlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_0, tmp566) ; ATSlocal (ats_ptr_type, tmp601) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_sarglst_svarlst: tmp601 = (ats_sum_ptr_type)0 ; tmp566 = aux_117 (arg0, arg1, tmp601, arg2, arg3) ; return (tmp566) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_sarglst_svarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 41334(line=1354, offs=5) -- 41574(line=1362, offs=4) */ ATSstaticdec() ats_ptr_type s2var_subst_118 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp602) ; ATSlocal (anairiats_rec_0, tmp603) ; ATSlocal (ats_ptr_type, tmp604) ; ATSlocal (ats_bool_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; ATSlocal (ats_ptr_type, tmp607) ; __ats_lab_s2var_subst_118: do { /* branch: __ats_lab_315 */ __ats_lab_315_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_316_0 ; } __ats_lab_315_1: tmp603 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_0) ; tmp604 = ats_caselptrlab_mac(anairiats_sum_21, arg0, atslab_1) ; tmp606 = ats_select_mac(tmp603, atslab_0) ; tmp605 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2var_s2var (arg1, tmp606) ; if (tmp605) { tmp607 = ats_select_mac(tmp603, atslab_1) ; tmp602 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp602, atslab_0, tmp607) ; } else { arg0 = tmp604 ; arg1 = arg1 ; goto __ats_lab_s2var_subst_118 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_316 */ __ats_lab_316_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_316_1: tmp602 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp602) ; } /* end of [s2var_subst_118] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 41809(line=1370, offs=11) -- 42143(line=1379, offs=28) */ ATSstaticdec() ats_void_type aux_120 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp612) ; ATSlocal (anairiats_rec_0, tmp613) ; ATSlocal (ats_ptr_type, tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; // ATSlocal_void (tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; __ats_lab_aux_120: do { /* branch: __ats_lab_319 */ __ats_lab_319_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_320_0 ; } __ats_lab_319_1: tmp613 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_0) ; tmp614 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_1) ; tmp615 = ats_select_mac(tmp613, atslab_0) ; tmp616 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset (tmp615) ; tmp618 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add (tmp616, arg0) ; /* tmp617 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_set_sVarset (tmp615, tmp618) ; arg0 = arg0 ; arg1 = tmp614 ; goto __ats_lab_aux_120 ; // tail call break ; /* branch: __ats_lab_320 */ __ats_lab_320_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_320_1: break ; } while (0) ; return /* (tmp612) */ ; } /* end of [aux_120] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 41607(line=1364, offs=5) -- 42223(line=1383, offs=4) */ ATSstaticdec() ats_ptr_type s2Var_subst_119 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; // ATSlocal_void (tmp619) ; __ats_lab_s2Var_subst_119: tmp609 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (arg1) ; do { /* branch: __ats_lab_317 */ __ats_lab_317_0: if (tmp609 == (ats_sum_ptr_type)0) { goto __ats_lab_318_0 ; } __ats_lab_317_1: tmp610 = ats_caselptrlab_mac(anairiats_sum_12, tmp609, atslab_0) ; tmp611 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (arg0, tmp610) ; tmp608 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp608, atslab_0, tmp611) ; break ; /* branch: __ats_lab_318 */ __ats_lab_318_0: // if (tmp609 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_318_1: /* tmp619 = */ aux_120 (arg1, arg0) ; tmp608 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp608) ; } /* end of [s2Var_subst_119] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 42284(line=1389, offs=5) -- 50648(line=1629, offs=4) */ ATSstaticdec() ats_ptr_type s2exp_subst_flag_121 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp620) ; ATSlocal (ats_ptr_type, tmp621) ; ATSlocal (ats_ptr_type, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; ATSlocal (ats_int_type, tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; ATSlocal (ats_ptr_type, tmp626) ; ATSlocal (ats_bool_type, tmp627) ; ATSlocal (ats_ptr_type, tmp628) ; ATSlocal (ats_int_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_int_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_bool_type, tmp633) ; ATSlocal (ats_ptr_type, tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_int_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; ATSlocal (ats_bool_type, tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_int_type, tmp641) ; ATSlocal (ats_ptr_type, tmp642) ; ATSlocal (ats_bool_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_int_type, tmp646) ; ATSlocal (ats_ptr_type, tmp647) ; ATSlocal (ats_bool_type, tmp648) ; ATSlocal (ats_ptr_type, tmp649) ; ATSlocal (ats_int_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_bool_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_int_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; ATSlocal (ats_bool_type, tmp658) ; ATSlocal (ats_ptr_type, tmp659) ; ATSlocal (ats_ptr_type, tmp660) ; ATSlocal (ats_ptr_type, tmp661) ; ATSlocal (ats_int_type, tmp662) ; ATSlocal (anairiats_rec_0, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; ATSlocal (ats_ptr_type, tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_bool_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_int_type, tmp671) ; ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_bool_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; ATSlocal (ats_ptr_type, tmp675) ; ATSlocal (ats_int_type, tmp676) ; ATSlocal (ats_ptr_type, tmp677) ; ATSlocal (ats_int_type, tmp678) ; ATSlocal (ats_ptr_type, tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_int_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_bool_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; ATSlocal (ats_int_type, tmp689) ; ATSlocal (anairiats_rec_0, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; ATSlocal (ats_ptr_type, tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; ATSlocal (ats_bool_type, tmp694) ; ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; ATSlocal (ats_ptr_type, tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; ATSlocal (ats_int_type, tmp699) ; ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_bool_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_int_type, tmp705) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; ATSlocal (ats_bool_type, tmp708) ; ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_int_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_bool_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_int_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; ATSlocal (ats_ptr_type, tmp717) ; ATSlocal (ats_bool_type, tmp718) ; ATSlocal (ats_ptr_type, tmp719) ; ATSlocal (ats_ptr_type, tmp720) ; ATSlocal (ats_int_type, tmp721) ; ATSlocal (ats_ptr_type, tmp722) ; ATSlocal (ats_ptr_type, tmp723) ; ATSlocal (ats_bool_type, tmp724) ; ATSlocal (ats_ptr_type, tmp725) ; ATSlocal (ats_int_type, tmp726) ; ATSlocal (ats_ptr_type, tmp727) ; ATSlocal (ats_int_type, tmp728) ; ATSlocal (ats_ptr_type, tmp729) ; ATSlocal (ats_bool_type, tmp730) ; ATSlocal (ats_ptr_type, tmp731) ; ATSlocal (ats_int_type, tmp732) ; ATSlocal (ats_int_type, tmp733) ; ATSlocal (ats_ptr_type, tmp734) ; ATSlocal (ats_bool_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; ATSlocal (ats_ptr_type, tmp737) ; ATSlocal (ats_int_type, tmp738) ; ATSlocal (ats_ptr_type, tmp739) ; ATSlocal (ats_bool_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_int_type, tmp742) ; ATSlocal (ats_ptr_type, tmp743) ; ATSlocal (ats_bool_type, tmp744) ; ATSlocal (ats_int_type, tmp745) ; ATSlocal (ats_ptr_type, tmp746) ; ATSlocal (ats_int_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_bool_type, tmp749) ; ATSlocal (ats_ptr_type, tmp750) ; ATSlocal (ats_ptr_type, tmp751) ; ATSlocal (ats_int_type, tmp752) ; ATSlocal (ats_ptr_type, tmp753) ; ATSlocal (ats_bool_type, tmp754) ; ATSlocal (ats_ptr_type, tmp755) ; ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_int_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_bool_type, tmp761) ; ATSlocal (ats_int_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_int_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_bool_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_int_type, tmp770) ; ATSlocal (ats_ptr_type, tmp771) ; ATSlocal (ats_bool_type, tmp772) ; ATSlocal (ats_ptr_type, tmp773) ; ATSlocal (ats_int_type, tmp774) ; ATSlocal (ats_ptr_type, tmp775) ; ATSlocal (ats_int_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_bool_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; ATSlocal (ats_ptr_type, tmp782) ; ATSlocal (ats_int_type, tmp783) ; ATSlocal (anairiats_rec_0, tmp784) ; ATSlocal (ats_ptr_type, tmp785) ; ATSlocal (ats_ptr_type, tmp786) ; ATSlocal (ats_ptr_type, tmp787) ; ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_bool_type, tmp789) ; ATSlocal (atsopt_count_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; ATSlocal (ats_ptr_type, tmp792) ; ATSlocal (ats_int_type, tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_bool_type, tmp796) ; ATSlocal (ats_ptr_type, tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; ATSlocal (ats_ptr_type, tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_int_type, tmp801) ; ATSlocal (ats_ptr_type, tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; ATSlocal (ats_int_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; ATSlocal (ats_bool_type, tmp808) ; ATSlocal (ats_ptr_type, tmp809) ; ATSlocal (ats_ptr_type, tmp810) ; ATSlocal (ats_int_type, tmp811) ; ATSlocal (ats_ptr_type, tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_bool_type, tmp814) ; __ats_lab_s2exp_subst_flag_121: tmp621 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_321 */ __ats_lab_321_0: if (((ats_sum_ptr_type)tmp621)->tag != 0) { goto __ats_lab_322_0 ; } __ats_lab_321_1: tmp622 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp623 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp624 = ats_ptrget_mac(ats_int_type, arg2) ; tmp625 = s2exp_subst_flag_121 (arg0, tmp622, arg2) ; tmp626 = s2explst_subst_flag_122 (arg0, tmp623, arg2) ; tmp627 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp624) ; if (tmp627) { tmp628 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_app_srt (tmp628, tmp625, tmp626) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_322 */ __ats_lab_322_0: if (((ats_sum_ptr_type)tmp621)->tag != 1) { goto __ats_lab_323_0 ; } __ats_lab_322_1: tmp620 = arg1 ; break ; /* branch: __ats_lab_323 */ __ats_lab_323_0: if (((ats_sum_ptr_type)tmp621)->tag != 2) { goto __ats_lab_324_0 ; } __ats_lab_323_1: tmp629 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_0) ; tmp630 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_1) ; tmp631 = ats_ptrget_mac(ats_int_type, arg2) ; tmp632 = s2exp_subst_flag_121 (arg0, tmp630, arg2) ; tmp633 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp631) ; if (tmp633) { tmp634 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, tmp632), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_clo_srt (tmp634, tmp629, tmp632) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_324 */ __ats_lab_324_0: if (((ats_sum_ptr_type)tmp621)->tag != 3) { goto __ats_lab_325_0 ; } __ats_lab_324_1: tmp635 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp636 = ats_ptrget_mac(ats_int_type, arg2) ; tmp637 = s2exp_subst_flag_121 (arg0, tmp635, arg2) ; tmp638 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp636) ; if (tmp638) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_crypt (tmp637) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_325 */ __ats_lab_325_0: if (((ats_sum_ptr_type)tmp621)->tag != 4) { goto __ats_lab_326_0 ; } __ats_lab_325_1: tmp620 = arg1 ; break ; /* branch: __ats_lab_326 */ __ats_lab_326_0: if (((ats_sum_ptr_type)tmp621)->tag != 5) { goto __ats_lab_327_0 ; } __ats_lab_326_1: tmp639 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp640 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp641 = ats_ptrget_mac(ats_int_type, arg2) ; tmp642 = s2explst_subst_flag_122 (arg0, tmp640, arg2) ; tmp643 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp641) ; if (tmp643) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datconptr (tmp639, tmp642) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_327 */ __ats_lab_327_0: if (((ats_sum_ptr_type)tmp621)->tag != 6) { goto __ats_lab_328_0 ; } __ats_lab_327_1: tmp644 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp645 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp646 = ats_ptrget_mac(ats_int_type, arg2) ; tmp647 = s2explst_subst_flag_122 (arg0, tmp645, arg2) ; tmp648 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp646) ; if (tmp648) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_datcontyp (tmp644, tmp647) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_328 */ __ats_lab_328_0: if (((ats_sum_ptr_type)tmp621)->tag != 7) { goto __ats_lab_329_0 ; } __ats_lab_328_1: tmp649 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp650 = ats_ptrget_mac(ats_int_type, arg2) ; tmp651 = s2eff_subst_flag_126 (arg0, tmp649, arg2) ; tmp652 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp650) ; if (tmp652) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eff (tmp651) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_329 */ __ats_lab_329_0: if (((ats_sum_ptr_type)tmp621)->tag != 8) { goto __ats_lab_330_0 ; } __ats_lab_329_1: tmp653 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp654 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp655 = ats_ptrget_mac(ats_int_type, arg2) ; tmp656 = s2exp_subst_flag_121 (arg0, tmp653, arg2) ; tmp657 = s2exp_subst_flag_121 (arg0, tmp654, arg2) ; tmp658 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp655) ; if (tmp658) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq (tmp656, tmp657) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_330 */ __ats_lab_330_0: if (((ats_sum_ptr_type)tmp621)->tag != 9) { goto __ats_lab_331_0 ; } __ats_lab_330_1: tmp659 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_0) ; tmp660 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_1) ; tmp661 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_2) ; tmp662 = ats_ptrget_mac(ats_int_type, arg2) ; tmp663 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (arg0, tmp659) ; tmp664 = ats_select_mac(tmp663, atslab_0) ; tmp665 = ats_select_mac(tmp663, atslab_1) ; tmp666 = s2explst_subst_flag_122 (tmp664, tmp660, arg2) ; tmp667 = s2exp_subst_flag_121 (tmp664, tmp661, arg2) ; tmp668 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp662) ; if (tmp668) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_exi (tmp665, tmp666, tmp667) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_331 */ __ats_lab_331_0: if (((ats_sum_ptr_type)tmp621)->tag != 10) { goto __ats_lab_332_0 ; } __ats_lab_331_1: tmp669 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp670 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp671 = ats_ptrget_mac(ats_int_type, arg2) ; tmp672 = s2explstlst_subst_flag_123 (arg0, tmp670, arg2) ; tmp673 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp671) ; if (tmp673) { tmp674 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_extype_srt (tmp674, tmp669, tmp672) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_332 */ __ats_lab_332_0: if (((ats_sum_ptr_type)tmp621)->tag != 11) { goto __ats_lab_333_0 ; } __ats_lab_332_1: tmp675 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_0) ; tmp676 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_1) ; tmp677 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_2) ; tmp678 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_3) ; tmp679 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_4) ; tmp680 = ats_caselptrlab_mac(anairiats_sum_14, tmp621, atslab_5) ; tmp681 = ats_ptrget_mac(ats_int_type, arg2) ; tmp682 = s2eff_subst_flag_126 (arg0, tmp677, arg2) ; tmp683 = s2explst_subst_flag_122 (arg0, tmp679, arg2) ; tmp684 = s2exp_subst_flag_121 (arg0, tmp680, arg2) ; tmp685 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp681) ; if (tmp685) { tmp686 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_fun_srt (tmp686, tmp675, tmp676, tmp682, tmp678, tmp683, tmp684) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_333 */ __ats_lab_333_0: if (((ats_sum_ptr_type)tmp621)->tag != 12) { goto __ats_lab_334_0 ; } __ats_lab_333_1: tmp620 = arg1 ; break ; /* branch: __ats_lab_334 */ __ats_lab_334_0: if (((ats_sum_ptr_type)tmp621)->tag != 13) { goto __ats_lab_335_0 ; } __ats_lab_334_1: tmp620 = arg1 ; break ; /* branch: __ats_lab_335 */ __ats_lab_335_0: if (((ats_sum_ptr_type)tmp621)->tag != 14) { goto __ats_lab_336_0 ; } __ats_lab_335_1: tmp687 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp688 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp689 = ats_ptrget_mac(ats_int_type, arg2) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (arg0, tmp687) ; tmp691 = ats_select_mac(tmp690, atslab_0) ; tmp692 = ats_select_mac(tmp690, atslab_1) ; tmp693 = s2exp_subst_flag_121 (tmp691, tmp688, arg2) ; tmp694 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp689) ; if (tmp694) { tmp695 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_lam_srt (tmp695, tmp692, tmp693) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_336 */ __ats_lab_336_0: if (((ats_sum_ptr_type)tmp621)->tag != 15) { goto __ats_lab_337_0 ; } __ats_lab_336_1: tmp696 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_0) ; tmp697 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_1) ; tmp698 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_2) ; tmp699 = ats_ptrget_mac(ats_int_type, arg2) ; tmp700 = s2explst_subst_flag_122 (arg0, tmp697, arg2) ; tmp701 = s2exp_subst_flag_121 (arg0, tmp698, arg2) ; tmp702 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp699) ; if (tmp702) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metfn (tmp696, tmp700, tmp701) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_337 */ __ats_lab_337_0: if (((ats_sum_ptr_type)tmp621)->tag != 16) { goto __ats_lab_338_0 ; } __ats_lab_337_1: tmp703 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp704 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp705 = ats_ptrget_mac(ats_int_type, arg2) ; tmp706 = s2explst_subst_flag_122 (arg0, tmp703, arg2) ; tmp707 = s2explst_subst_flag_122 (arg0, tmp704, arg2) ; tmp708 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp705) ; if (tmp708) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt (tmp706, tmp707) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_338 */ __ats_lab_338_0: if (((ats_sum_ptr_type)tmp621)->tag != 17) { goto __ats_lab_339_0 ; } __ats_lab_338_1: tmp709 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp710 = ats_ptrget_mac(ats_int_type, arg2) ; tmp711 = s2exp_subst_flag_121 (arg0, tmp709, arg2) ; tmp712 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp710) ; if (tmp712) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_out (tmp711) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_339 */ __ats_lab_339_0: if (((ats_sum_ptr_type)tmp621)->tag != 18) { goto __ats_lab_340_0 ; } __ats_lab_339_1: tmp713 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp714 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp715 = ats_ptrget_mac(ats_int_type, arg2) ; tmp716 = s2exp_subst_flag_121 (arg0, tmp713, arg2) ; tmp717 = s2lab_subst_flag_127 (arg0, tmp714, arg2) ; tmp718 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp715) ; if (tmp718) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_proj (tmp716, tmp717) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_340 */ __ats_lab_340_0: if (((ats_sum_ptr_type)tmp621)->tag != 19) { goto __ats_lab_341_0 ; } __ats_lab_340_1: tmp719 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp720 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp721 = ats_ptrget_mac(ats_int_type, arg2) ; tmp722 = s2exp_subst_flag_121 (arg0, tmp719, arg2) ; tmp723 = s2exp_subst_flag_121 (arg0, tmp720, arg2) ; tmp724 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp721) ; if (tmp724) { tmp725 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_read_srt (tmp725, tmp722, tmp723) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_341 */ __ats_lab_341_0: if (((ats_sum_ptr_type)tmp621)->tag != 20) { goto __ats_lab_342_0 ; } __ats_lab_341_1: tmp726 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_0) ; tmp727 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_1) ; tmp728 = ats_ptrget_mac(ats_int_type, arg2) ; tmp729 = s2exp_subst_flag_121 (arg0, tmp727, arg2) ; tmp730 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp728) ; if (tmp730) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_refarg (tmp726, tmp729) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_342 */ __ats_lab_342_0: if (((ats_sum_ptr_type)tmp621)->tag != 21) { goto __ats_lab_343_0 ; } __ats_lab_342_1: tmp731 = ats_caselptrlab_mac(anairiats_sum_23, tmp621, atslab_0) ; tmp732 = ats_caselptrlab_mac(anairiats_sum_23, tmp621, atslab_1) ; tmp733 = ats_ptrget_mac(ats_int_type, arg2) ; tmp734 = s2exp_subst_flag_121 (arg0, tmp731, arg2) ; tmp735 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp733) ; if (tmp735) { tmp736 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sel_srt (tmp736, tmp734, tmp732) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_343 */ __ats_lab_343_0: if (((ats_sum_ptr_type)tmp621)->tag != 22) { goto __ats_lab_344_0 ; } __ats_lab_343_1: tmp737 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp738 = ats_ptrget_mac(ats_int_type, arg2) ; tmp739 = s2zexp_subst_flag_128 (arg0, tmp737, arg2) ; tmp740 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp738) ; if (tmp740) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_size (tmp739) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_344 */ __ats_lab_344_0: if (((ats_sum_ptr_type)tmp621)->tag != 23) { goto __ats_lab_345_0 ; } __ats_lab_344_1: tmp741 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp742 = ats_ptrget_mac(ats_int_type, arg2) ; tmp743 = s2exp_subst_flag_121 (arg0, tmp741, arg2) ; tmp744 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp742) ; if (tmp744) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_sizeof (tmp743) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_345 */ __ats_lab_345_0: if (((ats_sum_ptr_type)tmp621)->tag != 24) { goto __ats_lab_346_0 ; } __ats_lab_345_1: tmp745 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_0) ; tmp746 = ats_caselptrlab_mac(anairiats_sum_15, tmp621, atslab_1) ; tmp747 = ats_ptrget_mac(ats_int_type, arg2) ; tmp748 = s2exp_subst_flag_121 (arg0, tmp746, arg2) ; tmp749 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp747) ; if (tmp749) { tmp750 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_top_srt (tmp750, tmp745, tmp748) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_346 */ __ats_lab_346_0: if (((ats_sum_ptr_type)tmp621)->tag != 25) { goto __ats_lab_347_0 ; } __ats_lab_346_1: tmp751 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp752 = ats_ptrget_mac(ats_int_type, arg2) ; tmp753 = s2explst_subst_flag_122 (arg0, tmp751, arg2) ; tmp754 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp752) ; if (tmp754) { tmp755 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tup_srt (tmp755, tmp753) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_347 */ __ats_lab_347_0: if (((ats_sum_ptr_type)tmp621)->tag != 26) { goto __ats_lab_348_0 ; } __ats_lab_347_1: tmp756 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp757 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp758 = ats_ptrget_mac(ats_int_type, arg2) ; tmp759 = s2exp_subst_flag_121 (arg0, tmp756, arg2) ; tmp760 = s2explstlst_subst_flag_123 (arg0, tmp757, arg2) ; tmp761 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp758) ; if (tmp761) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyarr (tmp759, tmp760) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_348 */ __ats_lab_348_0: if (((ats_sum_ptr_type)tmp621)->tag != 27) { goto __ats_lab_349_0 ; } __ats_lab_348_1: tmp762 = ats_caselptrlab_mac(anairiats_sum_24, tmp621, atslab_0) ; tmp763 = ats_caselptrlab_mac(anairiats_sum_24, tmp621, atslab_1) ; tmp764 = ats_caselptrlab_mac(anairiats_sum_24, tmp621, atslab_2) ; tmp765 = ats_ptrget_mac(ats_int_type, arg2) ; tmp766 = s2exp_subst_flag_121 (arg0, tmp763, arg2) ; tmp767 = s2exp_subst_flag_121 (arg0, tmp764, arg2) ; tmp768 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp765) ; if (tmp768) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq (tmp762, tmp766, tmp767) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_349 */ __ats_lab_349_0: if (((ats_sum_ptr_type)tmp621)->tag != 28) { goto __ats_lab_350_0 ; } __ats_lab_349_1: tmp769 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp770 = ats_ptrget_mac(ats_int_type, arg2) ; tmp771 = s2explst_subst_flag_122 (arg0, tmp769, arg2) ; tmp772 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp770) ; if (tmp772) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tylst (tmp771) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_350 */ __ats_lab_350_0: if (((ats_sum_ptr_type)tmp621)->tag != 29) { goto __ats_lab_351_0 ; } __ats_lab_350_1: tmp773 = ats_caselptrlab_mac(anairiats_sum_16, tmp621, atslab_0) ; tmp774 = ats_caselptrlab_mac(anairiats_sum_16, tmp621, atslab_1) ; tmp775 = ats_caselptrlab_mac(anairiats_sum_16, tmp621, atslab_2) ; tmp776 = ats_ptrget_mac(ats_int_type, arg2) ; tmp777 = labs2explst_subst_flag_124 (arg0, tmp775, arg2) ; tmp778 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp776) ; if (tmp778) { tmp779 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyrec_srt (tmp779, tmp773, tmp774, tmp777) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_351 */ __ats_lab_351_0: if (((ats_sum_ptr_type)tmp621)->tag != 30) { goto __ats_lab_352_0 ; } __ats_lab_351_1: tmp780 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_0) ; tmp781 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_1) ; tmp782 = ats_caselptrlab_mac(anairiats_sum_9, tmp621, atslab_2) ; tmp783 = ats_ptrget_mac(ats_int_type, arg2) ; tmp784 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (arg0, tmp780) ; tmp785 = ats_select_mac(tmp784, atslab_0) ; tmp786 = ats_select_mac(tmp784, atslab_1) ; tmp787 = s2explst_subst_flag_122 (tmp785, tmp781, arg2) ; tmp788 = s2exp_subst_flag_121 (tmp785, tmp782, arg2) ; tmp789 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp783) ; if (tmp789) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_uni (tmp786, tmp787, tmp788) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_352 */ __ats_lab_352_0: if (((ats_sum_ptr_type)tmp621)->tag != 31) { goto __ats_lab_353_0 ; } __ats_lab_352_1: tmp790 = ats_caselptrlab_mac(anairiats_sum_19, tmp621, atslab_0) ; tmp791 = ats_caselptrlab_mac(anairiats_sum_19, tmp621, atslab_1) ; tmp792 = ats_caselptrlab_mac(anairiats_sum_19, tmp621, atslab_2) ; tmp793 = ats_ptrget_mac(ats_int_type, arg2) ; tmp794 = s2exp_subst_flag_121 (arg0, tmp791, arg2) ; tmp795 = labs2explst_subst_flag_124 (arg0, tmp792, arg2) ; tmp796 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp793) ; if (tmp796) { tmp797 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_srt) ; tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_union_srt (tmp797, tmp790, tmp794, tmp795) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_353 */ __ats_lab_353_0: if (((ats_sum_ptr_type)tmp621)->tag != 32) { goto __ats_lab_356_0 ; } __ats_lab_353_1: tmp798 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp799 = s2var_subst_118 (arg0, tmp798) ; do { /* branch: __ats_lab_354 */ __ats_lab_354_0: if (tmp799 == (ats_sum_ptr_type)0) { goto __ats_lab_355_0 ; } __ats_lab_354_1: tmp800 = ats_caselptrlab_mac(anairiats_sum_12, tmp799, atslab_0) ; ATS_FREE(tmp799) ; tmp801 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp801 ; tmp620 = tmp800 ; break ; /* branch: __ats_lab_355 */ __ats_lab_355_0: // if (tmp799 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_355_1: tmp620 = arg1 ; break ; } while (0) ; break ; /* branch: __ats_lab_356 */ __ats_lab_356_0: if (((ats_sum_ptr_type)tmp621)->tag != 33) { goto __ats_lab_359_0 ; } __ats_lab_356_1: tmp802 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp803 = s2Var_subst_119 (arg0, tmp802) ; do { /* branch: __ats_lab_357 */ __ats_lab_357_0: if (tmp803 == (ats_sum_ptr_type)0) { goto __ats_lab_358_0 ; } __ats_lab_357_1: tmp804 = ats_caselptrlab_mac(anairiats_sum_12, tmp803, atslab_0) ; ATS_FREE(tmp803) ; tmp620 = tmp804 ; break ; /* branch: __ats_lab_358 */ __ats_lab_358_0: // if (tmp803 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_358_1: tmp620 = arg1 ; break ; } while (0) ; break ; /* branch: __ats_lab_359 */ __ats_lab_359_0: if (((ats_sum_ptr_type)tmp621)->tag != 34) { goto __ats_lab_360_0 ; } __ats_lab_359_1: tmp805 = ats_caselptrlab_mac(anairiats_sum_1, tmp621, atslab_0) ; tmp806 = ats_ptrget_mac(ats_int_type, arg2) ; tmp807 = s2exp_subst_flag_121 (arg0, tmp805, arg2) ; tmp808 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp806) ; if (tmp808) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_vararg (tmp807) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_360 */ __ats_lab_360_0: // if (((ats_sum_ptr_type)tmp621)->tag != 35) { ats_deadcode_failure_handle () ; } __ats_lab_360_1: tmp809 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_0) ; tmp810 = ats_caselptrlab_mac(anairiats_sum_3, tmp621, atslab_1) ; tmp811 = ats_ptrget_mac(ats_int_type, arg2) ; tmp812 = s2exp_subst_flag_121 (arg0, tmp809, arg2) ; tmp813 = wths2explst_subst_flag_125 (arg0, tmp810, arg2) ; tmp814 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp811) ; if (tmp814) { tmp620 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_wth (tmp812, tmp813) ; } else { tmp620 = arg1 ; } /* end of [if] */ break ; } while (0) ; return (tmp620) ; } /* end of [s2exp_subst_flag_121] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 50683(line=1631, offs=5) -- 51077(line=1641, offs=31) */ ATSstaticdec() ats_ptr_type s2explst_subst_flag_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; ATSlocal (ats_ptr_type, tmp817) ; ATSlocal (ats_int_type, tmp818) ; ATSlocal (ats_ptr_type, tmp819) ; ATSlocal (ats_ptr_type, tmp820) ; ATSlocal (ats_bool_type, tmp821) ; __ats_lab_s2explst_subst_flag_122: do { /* branch: __ats_lab_361 */ __ats_lab_361_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_362_0 ; } __ats_lab_361_1: tmp816 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp817 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp818 = ats_ptrget_mac(ats_int_type, arg2) ; tmp819 = s2exp_subst_flag_121 (arg0, tmp816, arg2) ; tmp820 = s2explst_subst_flag_122 (arg0, tmp817, arg2) ; tmp821 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp818) ; if (tmp821) { tmp815 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp815, atslab_0, tmp819) ; ats_selptrset_mac(anairiats_sum_4, tmp815, atslab_1, tmp820) ; } else { tmp815 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_362 */ __ats_lab_362_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_362_1: tmp815 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp815) ; } /* end of [s2explst_subst_flag_122] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 51115(line=1644, offs=5) -- 51524(line=1654, offs=31) */ ATSstaticdec() ats_ptr_type s2explstlst_subst_flag_123 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_int_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; ATSlocal (ats_ptr_type, tmp827) ; ATSlocal (ats_bool_type, tmp828) ; __ats_lab_s2explstlst_subst_flag_123: do { /* branch: __ats_lab_363 */ __ats_lab_363_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_364_0 ; } __ats_lab_363_1: tmp823 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp824 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp825 = ats_ptrget_mac(ats_int_type, arg2) ; tmp826 = s2explst_subst_flag_122 (arg0, tmp823, arg2) ; tmp827 = s2explstlst_subst_flag_123 (arg0, tmp824, arg2) ; tmp828 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp825) ; if (tmp828) { tmp822 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp822, atslab_0, tmp826) ; ats_selptrset_mac(anairiats_sum_4, tmp822, atslab_1, tmp827) ; } else { tmp822 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_364 */ __ats_lab_364_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_364_1: tmp822 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp822) ; } /* end of [s2explstlst_subst_flag_123] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 51565(line=1657, offs=5) -- 52002(line=1667, offs=43) */ ATSstaticdec() ats_ptr_type labs2explst_subst_flag_124 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; ATSlocal (ats_ptr_type, tmp831) ; ATSlocal (ats_ptr_type, tmp832) ; ATSlocal (ats_int_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; ATSlocal (ats_ptr_type, tmp835) ; ATSlocal (ats_bool_type, tmp836) ; __ats_lab_labs2explst_subst_flag_124: do { /* branch: __ats_lab_365 */ __ats_lab_365_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_366_0 ; } __ats_lab_365_1: tmp830 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp831 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp832 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp833 = ats_ptrget_mac(ats_int_type, arg2) ; tmp834 = s2exp_subst_flag_121 (arg0, tmp831, arg2) ; tmp835 = labs2explst_subst_flag_124 (arg0, tmp832, arg2) ; tmp836 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp833) ; if (tmp836) { tmp829 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp829, atslab_0, tmp830) ; ats_selptrset_mac(anairiats_sum_11, tmp829, atslab_1, tmp834) ; ats_selptrset_mac(anairiats_sum_11, tmp829, atslab_2, tmp835) ; } else { tmp829 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_366 */ __ats_lab_366_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_366_1: tmp829 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp829) ; } /* end of [labs2explst_subst_flag_124] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 52043(line=1670, offs=5) -- 52749(line=1688, offs=4) */ ATSstaticdec() ats_ptr_type wths2explst_subst_flag_125 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp837) ; ATSlocal (ats_int_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_int_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_bool_type, tmp844) ; ATSlocal (ats_ptr_type, tmp845) ; ATSlocal (ats_int_type, tmp846) ; ATSlocal (ats_ptr_type, tmp847) ; ATSlocal (ats_bool_type, tmp848) ; __ats_lab_wths2explst_subst_flag_125: do { /* branch: __ats_lab_367 */ __ats_lab_367_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_368_0 ; } __ats_lab_367_1: tmp838 = ats_caselptrlab_mac(anairiats_sum_24, arg1, atslab_0) ; tmp839 = ats_caselptrlab_mac(anairiats_sum_24, arg1, atslab_1) ; tmp840 = ats_caselptrlab_mac(anairiats_sum_24, arg1, atslab_2) ; tmp841 = ats_ptrget_mac(ats_int_type, arg2) ; tmp842 = s2exp_subst_flag_121 (arg0, tmp839, arg2) ; tmp843 = wths2explst_subst_flag_125 (arg0, tmp840, arg2) ; tmp844 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp841) ; if (tmp844) { tmp837 = ATS_MALLOC(sizeof(anairiats_sum_24)) ; ((ats_sum_ptr_type)tmp837)->tag = 1 ; ats_selptrset_mac(anairiats_sum_24, tmp837, atslab_0, tmp838) ; ats_selptrset_mac(anairiats_sum_24, tmp837, atslab_1, tmp842) ; ats_selptrset_mac(anairiats_sum_24, tmp837, atslab_2, tmp843) ; } else { tmp837 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_368 */ __ats_lab_368_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_369_0 ; } __ats_lab_368_1: tmp845 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp846 = ats_ptrget_mac(ats_int_type, arg2) ; tmp847 = wths2explst_subst_flag_125 (arg0, tmp845, arg2) ; tmp848 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp846) ; if (tmp848) { tmp837 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp837)->tag = 2 ; ats_selptrset_mac(anairiats_sum_1, tmp837, atslab_0, tmp847) ; } else { tmp837 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_369 */ __ats_lab_369_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_369_1: tmp837 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; break ; } while (0) ; return (tmp837) ; } /* end of [wths2explst_subst_flag_125] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 52790(line=1690, offs=5) -- 53118(line=1700, offs=4) */ ATSstaticdec() ats_ptr_type s2eff_subst_flag_126 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_uint_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_int_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_bool_type, tmp854) ; __ats_lab_s2eff_subst_flag_126: do { /* branch: __ats_lab_370 */ __ats_lab_370_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_371_0 ; } __ats_lab_370_1: tmp850 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp851 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; tmp852 = ats_ptrget_mac(ats_int_type, arg2) ; tmp853 = s2explst_subst_flag_122 (arg0, tmp851, arg2) ; tmp854 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp852) ; if (tmp854) { tmp849 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp849)->tag = 2 ; ats_selptrset_mac(anairiats_sum_6, tmp849, atslab_0, tmp850) ; ats_selptrset_mac(anairiats_sum_6, tmp849, atslab_1, tmp853) ; } else { tmp849 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_371 */ __ats_lab_371_0: __ats_lab_371_1: tmp849 = arg1 ; break ; } while (0) ; return (tmp849) ; } /* end of [s2eff_subst_flag_126] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 53151(line=1702, offs=5) -- 53952(line=1725, offs=4) */ ATSstaticdec() ats_ptr_type s2lab_subst_flag_127 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_int_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_bool_type, tmp859) ; ATSlocal (ats_ptr_type, tmp860) ; ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_int_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_bool_type, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_int_type, tmp867) ; ATSlocal (ats_ptr_type, tmp868) ; ATSlocal (ats_ptr_type, tmp869) ; ATSlocal (ats_bool_type, tmp870) ; __ats_lab_s2lab_subst_flag_127: do { /* branch: __ats_lab_372 */ __ats_lab_372_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_373_0 ; } __ats_lab_372_1: tmp855 = arg1 ; break ; /* branch: __ats_lab_373 */ __ats_lab_373_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_374_0 ; } __ats_lab_373_1: tmp856 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp857 = ats_ptrget_mac(ats_int_type, arg2) ; tmp858 = s2explstlst_subst_flag_123 (arg0, tmp856, arg2) ; tmp859 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp857) ; if (tmp859) { tmp855 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp855)->tag = 1 ; ats_selptrset_mac(anairiats_sum_1, tmp855, atslab_0, tmp858) ; } else { tmp855 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_374 */ __ats_lab_374_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_375_0 ; } __ats_lab_374_1: tmp860 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp861 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp862 = ats_ptrget_mac(ats_int_type, arg2) ; tmp863 = s2exp_subst_flag_121 (arg0, tmp861, arg2) ; tmp864 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp862) ; if (tmp864) { tmp855 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp855)->tag = 2 ; ats_selptrset_mac(anairiats_sum_3, tmp855, atslab_0, tmp860) ; ats_selptrset_mac(anairiats_sum_3, tmp855, atslab_1, tmp863) ; } else { tmp855 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_375 */ __ats_lab_375_0: // if (((ats_sum_ptr_type)arg1)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_375_1: tmp865 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp866 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp867 = ats_ptrget_mac(ats_int_type, arg2) ; tmp868 = s2explstlst_subst_flag_123 (arg0, tmp865, arg2) ; tmp869 = s2exp_subst_flag_121 (arg0, tmp866, arg2) ; tmp870 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp867) ; if (tmp870) { tmp855 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp855)->tag = 3 ; ats_selptrset_mac(anairiats_sum_3, tmp855, atslab_0, tmp868) ; ats_selptrset_mac(anairiats_sum_3, tmp855, atslab_1, tmp869) ; } else { tmp855 = arg1 ; } /* end of [if] */ break ; } while (0) ; return (tmp855) ; } /* end of [s2lab_subst_flag_127] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 53987(line=1727, offs=5) -- 55387(line=1765, offs=4) */ ATSstaticdec() ats_ptr_type s2zexp_subst_flag_128 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp871) ; ATSlocal (ats_ptr_type, tmp872) ; ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_int_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_bool_type, tmp877) ; ATSlocal (ats_ptr_type, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; ATSlocal (ats_int_type, tmp880) ; ATSlocal (ats_ptr_type, tmp881) ; ATSlocal (ats_ptr_type, tmp882) ; ATSlocal (ats_bool_type, tmp883) ; ATSlocal (ats_ptr_type, tmp884) ; ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_int_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; ATSlocal (ats_bool_type, tmp888) ; ATSlocal (atsopt_count_type, tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_int_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; ATSlocal (ats_bool_type, tmp893) ; ATSlocal (ats_ptr_type, tmp894) ; ATSlocal (ats_ptr_type, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (ats_int_type, tmp897) ; __ats_lab_s2zexp_subst_flag_128: do { /* branch: __ats_lab_376 */ __ats_lab_376_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_377_0 ; } __ats_lab_376_1: tmp872 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp873 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp874 = ats_ptrget_mac(ats_int_type, arg2) ; tmp875 = s2zexp_subst_flag_128 (arg0, tmp872, arg2) ; tmp876 = s2zexplst_subst_flag_129 (arg0, tmp873, arg2) ; tmp877 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp874) ; if (tmp877) { tmp871 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp871)->tag = 0 ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_0, tmp875) ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_1, tmp876) ; } else { tmp871 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_377 */ __ats_lab_377_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_378_0 ; } __ats_lab_377_1: tmp871 = arg1 ; break ; /* branch: __ats_lab_378 */ __ats_lab_378_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_379_0 ; } __ats_lab_378_1: tmp871 = arg1 ; break ; /* branch: __ats_lab_379 */ __ats_lab_379_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_380_0 ; } __ats_lab_379_1: tmp871 = arg1 ; break ; /* branch: __ats_lab_380 */ __ats_lab_380_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_381_0 ; } __ats_lab_380_1: tmp871 = arg1 ; break ; /* branch: __ats_lab_381 */ __ats_lab_381_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_382_0 ; } __ats_lab_381_1: tmp878 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp879 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp880 = ats_ptrget_mac(ats_int_type, arg2) ; tmp881 = s2zexp_subst_flag_128 (arg0, tmp878, arg2) ; tmp882 = s2explstlst_subst_flag_123 (arg0, tmp879, arg2) ; tmp883 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp880) ; if (tmp883) { tmp871 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp871)->tag = 5 ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_0, tmp881) ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_1, tmp882) ; } else { tmp871 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_382 */ __ats_lab_382_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_383_0 ; } __ats_lab_382_1: tmp884 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp885 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp886 = ats_ptrget_mac(ats_int_type, arg2) ; tmp887 = labs2zexplst_subst_flag_130 (arg0, tmp885, arg2) ; tmp888 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp886) ; if (tmp888) { tmp871 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ((ats_sum_ptr_type)tmp871)->tag = 6 ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_0, tmp884) ; ats_selptrset_mac(anairiats_sum_3, tmp871, atslab_1, tmp887) ; } else { tmp871 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_383 */ __ats_lab_383_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_384_0 ; } __ats_lab_383_1: tmp889 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_0) ; tmp890 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_1) ; tmp891 = ats_ptrget_mac(ats_int_type, arg2) ; tmp892 = labs2zexplst_subst_flag_130 (arg0, tmp890, arg2) ; tmp893 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp891) ; if (tmp893) { tmp871 = ATS_MALLOC(sizeof(anairiats_sum_20)) ; ((ats_sum_ptr_type)tmp871)->tag = 7 ; ats_selptrset_mac(anairiats_sum_20, tmp871, atslab_0, tmp889) ; ats_selptrset_mac(anairiats_sum_20, tmp871, atslab_1, tmp892) ; } else { tmp871 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_384 */ __ats_lab_384_0: // if (((ats_sum_ptr_type)arg1)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_384_1: tmp894 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp895 = s2var_subst_118 (arg0, tmp894) ; do { /* branch: __ats_lab_385 */ __ats_lab_385_0: if (tmp895 == (ats_sum_ptr_type)0) { goto __ats_lab_386_0 ; } __ats_lab_385_1: tmp896 = ats_caselptrlab_mac(anairiats_sum_12, tmp895, atslab_0) ; ATS_FREE(tmp895) ; tmp897 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp897 ; tmp871 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2zexp_make_s2exp (tmp896) ; break ; /* branch: __ats_lab_386 */ __ats_lab_386_0: // if (tmp895 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_386_1: tmp871 = arg1 ; break ; } while (0) ; break ; } while (0) ; return (tmp871) ; } /* end of [s2zexp_subst_flag_128] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 55423(line=1767, offs=5) -- 55822(line=1777, offs=31) */ ATSstaticdec() ats_ptr_type s2zexplst_subst_flag_129 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; ATSlocal (ats_int_type, tmp901) ; ATSlocal (ats_ptr_type, tmp902) ; ATSlocal (ats_ptr_type, tmp903) ; ATSlocal (ats_bool_type, tmp904) ; __ats_lab_s2zexplst_subst_flag_129: do { /* branch: __ats_lab_387 */ __ats_lab_387_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_388_0 ; } __ats_lab_387_1: tmp899 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp900 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; tmp901 = ats_ptrget_mac(ats_int_type, arg2) ; tmp902 = s2zexp_subst_flag_128 (arg0, tmp899, arg2) ; tmp903 = s2zexplst_subst_flag_129 (arg0, tmp900, arg2) ; tmp904 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp901) ; if (tmp904) { tmp898 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp898, atslab_0, tmp902) ; ats_selptrset_mac(anairiats_sum_4, tmp898, atslab_1, tmp903) ; } else { tmp898 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_388 */ __ats_lab_388_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_388_1: tmp898 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp898) ; } /* end of [s2zexplst_subst_flag_129] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 55882(line=1780, offs=5) -- 56340(line=1790, offs=45) */ ATSstaticdec() ats_ptr_type labs2zexplst_subst_flag_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_int_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; ATSlocal (ats_bool_type, tmp912) ; __ats_lab_labs2zexplst_subst_flag_130: do { /* branch: __ats_lab_389 */ __ats_lab_389_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_390_0 ; } __ats_lab_389_1: tmp906 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp907 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp908 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; tmp909 = ats_ptrget_mac(ats_int_type, arg2) ; tmp910 = s2zexp_subst_flag_128 (arg0, tmp907, arg2) ; tmp911 = labs2zexplst_subst_flag_130 (arg0, tmp908, arg2) ; tmp912 = atspre_gt_int_int (ats_ptrget_mac(ats_int_type, arg2), tmp909) ; if (tmp912) { tmp905 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp905, atslab_0, tmp906) ; ats_selptrset_mac(anairiats_sum_11, tmp905, atslab_1, tmp910) ; ats_selptrset_mac(anairiats_sum_11, tmp905, atslab_2, tmp911) ; } else { tmp905 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_390 */ __ats_lab_390_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_390_1: tmp905 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp905) ; } /* end of [labs2zexplst_subst_flag_130] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 56407(line=1796, offs=16) -- 56491(line=1797, offs=70) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_int_type, tmp914) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst: /* ats_int_type tmp914 ; */ tmp914 = 0 ; tmp913 = s2explst_subst_flag_122 (arg0, arg1, (&tmp914)) ; return (tmp913) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 56548(line=1801, offs=19) -- 56637(line=1802, offs=74) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_subst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (ats_int_type, tmp916) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_subst: /* ats_int_type tmp916 ; */ tmp916 = 0 ; tmp915 = s2explstlst_subst_flag_123 (arg0, arg1, (&tmp916)) ; return (tmp915) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explstlst_subst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 56696(line=1807, offs=3) -- 56916(line=1814, offs=23) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_subst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_int_type, tmp919) ; ATSlocal (ats_ptr_type, tmp920) ; ATSlocal (ats_bool_type, tmp921) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_subst: do { /* branch: __ats_lab_391 */ __ats_lab_391_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_392_0 ; } __ats_lab_391_1: tmp918 = ats_caselptrlab_mac(anairiats_sum_12, arg1, atslab_0) ; /* ats_int_type tmp919 ; */ tmp919 = 0 ; tmp920 = s2exp_subst_flag_121 (arg0, tmp918, (&tmp919)) ; tmp921 = atspre_gt_int_int (tmp919, 0) ; if (tmp921) { tmp917 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp917, atslab_0, tmp920) ; } else { tmp917 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_392 */ __ats_lab_392_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_392_1: tmp917 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp917) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2expopt_subst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 56967(line=1818, offs=13) -- 57046(line=1819, offs=66) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_int_type, tmp923) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst: /* ats_int_type tmp923 ; */ tmp923 = 0 ; tmp922 = s2exp_subst_flag_121 (arg0, arg1, (&tmp923)) ; return (tmp922) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 57117(line=1825, offs=13) -- 57230(line=1828, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_alpha (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp924) ; ATSlocal (ats_ptr_type, tmp925) ; ATSlocal (anairiats_rec_0, tmp926) ; ATSlocal (ats_ptr_type, tmp927) ; ATSlocal (ats_ptr_type, tmp928) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_alpha: tmp927 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (arg1) ; tmp926.atslab_0 = arg0 ; tmp926.atslab_1 = tmp927 ; tmp928 = (ats_sum_ptr_type)0 ; tmp925 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp925, atslab_0, tmp926) ; ats_selptrset_mac(anairiats_sum_21, tmp925, atslab_1, tmp928) ; tmp924 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp925, arg2) ; return (tmp924) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_alpha] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 57281(line=1831, offs=16) -- 57399(line=1834, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_alpha (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (ats_ptr_type, tmp930) ; ATSlocal (anairiats_rec_0, tmp931) ; ATSlocal (ats_ptr_type, tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_alpha: tmp932 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_var (arg1) ; tmp931.atslab_0 = arg0 ; tmp931.atslab_1 = tmp932 ; tmp933 = (ats_sum_ptr_type)0 ; tmp930 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp930, atslab_0, tmp931) ; ats_selptrset_mac(anairiats_sum_21, tmp930, atslab_1, tmp933) ; tmp929 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp930, arg2) ; return (tmp929) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_alpha] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 57460(line=1840, offs=5) -- 60674(line=1927, offs=8) */ ATSstaticdec() ats_void_type aux_s2exp_137 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; ATSlocal (ats_ptr_type, tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; // ATSlocal_void (tmp938) ; ATSlocal (ats_ptr_type, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; ATSlocal (ats_ptr_type, tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; ATSlocal (ats_ptr_type, tmp943) ; ATSlocal (ats_ptr_type, tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; // ATSlocal_void (tmp946) ; ATSlocal (ats_ptr_type, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; ATSlocal (ats_ptr_type, tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; // ATSlocal_void (tmp951) ; // ATSlocal_void (tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; ATSlocal (ats_ptr_type, tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; // ATSlocal_void (tmp959) ; // ATSlocal_void (tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_ptr_type, tmp963) ; // ATSlocal_void (tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; // ATSlocal_void (tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; ATSlocal (ats_ptr_type, tmp971) ; // ATSlocal_void (tmp972) ; ATSlocal (ats_ptr_type, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; ATSlocal (ats_ptr_type, tmp975) ; // ATSlocal_void (tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; // ATSlocal_void (tmp979) ; ATSlocal (ats_ptr_type, tmp980) ; ATSlocal (ats_ptr_type, tmp981) ; ATSlocal (ats_ptr_type, tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; ATSlocal (ats_ptr_type, tmp985) ; ATSlocal (ats_ptr_type, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; // ATSlocal_void (tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; ATSlocal (ats_ptr_type, tmp990) ; // ATSlocal_void (tmp991) ; ATSlocal (ats_ptr_type, tmp992) ; ATSlocal (ats_ptr_type, tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_ptr_type, tmp997) ; // ATSlocal_void (tmp998) ; // ATSlocal_void (tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; // ATSlocal_void (tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; ATSlocal (ats_ptr_type, tmp1006) ; ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; // ATSlocal_void (tmp1011) ; __ats_lab_aux_s2exp_137: tmp935 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg0), atslab_s2exp_node) ; do { /* branch: __ats_lab_393 */ __ats_lab_393_0: if (((ats_sum_ptr_type)tmp935)->tag != 0) { goto __ats_lab_394_0 ; } __ats_lab_393_1: tmp936 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp937 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp938 = */ aux_s2exp_137 (tmp936, arg1) ; /* tmp934 = */ aux_s2explst_138 (tmp937, arg1) ; break ; /* branch: __ats_lab_394 */ __ats_lab_394_0: if (((ats_sum_ptr_type)tmp935)->tag != 1) { goto __ats_lab_395_0 ; } __ats_lab_394_1: break ; /* branch: __ats_lab_395 */ __ats_lab_395_0: if (((ats_sum_ptr_type)tmp935)->tag != 2) { goto __ats_lab_396_0 ; } __ats_lab_395_1: tmp939 = ats_caselptrlab_mac(anairiats_sum_15, tmp935, atslab_1) ; arg0 = tmp939 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_396 */ __ats_lab_396_0: if (((ats_sum_ptr_type)tmp935)->tag != 3) { goto __ats_lab_397_0 ; } __ats_lab_396_1: tmp940 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; arg0 = tmp940 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_397 */ __ats_lab_397_0: if (((ats_sum_ptr_type)tmp935)->tag != 4) { goto __ats_lab_398_0 ; } __ats_lab_397_1: break ; /* branch: __ats_lab_398 */ __ats_lab_398_0: if (((ats_sum_ptr_type)tmp935)->tag != 5) { goto __ats_lab_399_0 ; } __ats_lab_398_1: tmp941 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp934 = */ aux_s2explst_138 (tmp941, arg1) ; break ; /* branch: __ats_lab_399 */ __ats_lab_399_0: if (((ats_sum_ptr_type)tmp935)->tag != 6) { goto __ats_lab_400_0 ; } __ats_lab_399_1: tmp942 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp934 = */ aux_s2explst_138 (tmp942, arg1) ; break ; /* branch: __ats_lab_400 */ __ats_lab_400_0: if (((ats_sum_ptr_type)tmp935)->tag != 7) { goto __ats_lab_401_0 ; } __ats_lab_400_1: tmp943 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; /* tmp934 = */ aux_s2eff_142 (tmp943, arg1) ; break ; /* branch: __ats_lab_401 */ __ats_lab_401_0: if (((ats_sum_ptr_type)tmp935)->tag != 8) { goto __ats_lab_402_0 ; } __ats_lab_401_1: tmp944 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp945 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp946 = */ aux_s2exp_137 (tmp944, arg1) ; arg0 = tmp945 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_402 */ __ats_lab_402_0: if (((ats_sum_ptr_type)tmp935)->tag != 9) { goto __ats_lab_403_0 ; } __ats_lab_402_1: tmp947 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_0) ; tmp948 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_1) ; tmp949 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_2) ; /* ats_ptr_type tmp950 ; */ tmp950 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil ; /* tmp951 = */ aux_s2explst_138 (tmp948, (&tmp950)) ; /* tmp952 = */ aux_s2exp_137 (tmp949, (&tmp950)) ; tmp953 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels (tmp950, tmp947) ; tmp950 = tmp953 ; tmp954 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union (ats_ptrget_mac(ats_ptr_type, arg1), tmp950) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp954 ; break ; /* branch: __ats_lab_403 */ __ats_lab_403_0: if (((ats_sum_ptr_type)tmp935)->tag != 10) { goto __ats_lab_404_0 ; } __ats_lab_403_1: tmp955 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp934 = */ aux_s2explstlst_139 (tmp955, arg1) ; break ; /* branch: __ats_lab_404 */ __ats_lab_404_0: if (((ats_sum_ptr_type)tmp935)->tag != 11) { goto __ats_lab_405_0 ; } __ats_lab_404_1: tmp956 = ats_caselptrlab_mac(anairiats_sum_14, tmp935, atslab_2) ; tmp957 = ats_caselptrlab_mac(anairiats_sum_14, tmp935, atslab_4) ; tmp958 = ats_caselptrlab_mac(anairiats_sum_14, tmp935, atslab_5) ; /* tmp959 = */ aux_s2eff_142 (tmp956, arg1) ; /* tmp960 = */ aux_s2explst_138 (tmp957, arg1) ; arg0 = tmp958 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_405 */ __ats_lab_405_0: if (((ats_sum_ptr_type)tmp935)->tag != 12) { goto __ats_lab_406_0 ; } __ats_lab_405_1: break ; /* branch: __ats_lab_406 */ __ats_lab_406_0: if (((ats_sum_ptr_type)tmp935)->tag != 13) { goto __ats_lab_407_0 ; } __ats_lab_406_1: break ; /* branch: __ats_lab_407 */ __ats_lab_407_0: if (((ats_sum_ptr_type)tmp935)->tag != 14) { goto __ats_lab_408_0 ; } __ats_lab_407_1: tmp961 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp962 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* ats_ptr_type tmp963 ; */ tmp963 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil ; /* tmp964 = */ aux_s2exp_137 (tmp962, (&tmp963)) ; tmp965 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels (tmp963, tmp961) ; tmp963 = tmp965 ; tmp966 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union (ats_ptrget_mac(ats_ptr_type, arg1), tmp963) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp966 ; break ; /* branch: __ats_lab_408 */ __ats_lab_408_0: if (((ats_sum_ptr_type)tmp935)->tag != 15) { goto __ats_lab_409_0 ; } __ats_lab_408_1: tmp967 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_1) ; tmp968 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_2) ; /* tmp969 = */ aux_s2explst_138 (tmp967, arg1) ; arg0 = tmp968 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_409 */ __ats_lab_409_0: if (((ats_sum_ptr_type)tmp935)->tag != 16) { goto __ats_lab_410_0 ; } __ats_lab_409_1: tmp970 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp971 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp972 = */ aux_s2explst_138 (tmp970, arg1) ; /* tmp934 = */ aux_s2explst_138 (tmp971, arg1) ; break ; /* branch: __ats_lab_410 */ __ats_lab_410_0: if (((ats_sum_ptr_type)tmp935)->tag != 17) { goto __ats_lab_411_0 ; } __ats_lab_410_1: tmp973 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; arg0 = tmp973 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_411 */ __ats_lab_411_0: if (((ats_sum_ptr_type)tmp935)->tag != 18) { goto __ats_lab_412_0 ; } __ats_lab_411_1: tmp974 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp975 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp976 = */ aux_s2exp_137 (tmp974, arg1) ; /* tmp934 = */ aux_s2lab_143 (tmp975, arg1) ; break ; /* branch: __ats_lab_412 */ __ats_lab_412_0: if (((ats_sum_ptr_type)tmp935)->tag != 19) { goto __ats_lab_413_0 ; } __ats_lab_412_1: tmp977 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp978 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp979 = */ aux_s2exp_137 (tmp977, arg1) ; arg0 = tmp978 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_413 */ __ats_lab_413_0: if (((ats_sum_ptr_type)tmp935)->tag != 20) { goto __ats_lab_414_0 ; } __ats_lab_413_1: tmp980 = ats_caselptrlab_mac(anairiats_sum_15, tmp935, atslab_1) ; arg0 = tmp980 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_414 */ __ats_lab_414_0: if (((ats_sum_ptr_type)tmp935)->tag != 21) { goto __ats_lab_415_0 ; } __ats_lab_414_1: tmp981 = ats_caselptrlab_mac(anairiats_sum_23, tmp935, atslab_0) ; arg0 = tmp981 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_415 */ __ats_lab_415_0: if (((ats_sum_ptr_type)tmp935)->tag != 22) { goto __ats_lab_416_0 ; } __ats_lab_415_1: tmp982 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; /* tmp934 = */ aux_s2zexp_145 (tmp982, arg1) ; break ; /* branch: __ats_lab_416 */ __ats_lab_416_0: if (((ats_sum_ptr_type)tmp935)->tag != 23) { goto __ats_lab_417_0 ; } __ats_lab_416_1: tmp983 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; arg0 = tmp983 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_417 */ __ats_lab_417_0: if (((ats_sum_ptr_type)tmp935)->tag != 24) { goto __ats_lab_418_0 ; } __ats_lab_417_1: tmp984 = ats_caselptrlab_mac(anairiats_sum_15, tmp935, atslab_1) ; arg0 = tmp984 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_418 */ __ats_lab_418_0: if (((ats_sum_ptr_type)tmp935)->tag != 25) { goto __ats_lab_419_0 ; } __ats_lab_418_1: tmp985 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; /* tmp934 = */ aux_s2explst_138 (tmp985, arg1) ; break ; /* branch: __ats_lab_419 */ __ats_lab_419_0: if (((ats_sum_ptr_type)tmp935)->tag != 26) { goto __ats_lab_420_0 ; } __ats_lab_419_1: tmp986 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp987 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp988 = */ aux_s2exp_137 (tmp986, arg1) ; /* tmp934 = */ aux_s2explstlst_139 (tmp987, arg1) ; break ; /* branch: __ats_lab_420 */ __ats_lab_420_0: if (((ats_sum_ptr_type)tmp935)->tag != 27) { goto __ats_lab_421_0 ; } __ats_lab_420_1: tmp989 = ats_caselptrlab_mac(anairiats_sum_24, tmp935, atslab_1) ; tmp990 = ats_caselptrlab_mac(anairiats_sum_24, tmp935, atslab_2) ; /* tmp991 = */ aux_s2exp_137 (tmp989, arg1) ; arg0 = tmp990 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_421 */ __ats_lab_421_0: if (((ats_sum_ptr_type)tmp935)->tag != 28) { goto __ats_lab_422_0 ; } __ats_lab_421_1: tmp992 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; /* tmp934 = */ aux_s2explst_138 (tmp992, arg1) ; break ; /* branch: __ats_lab_422 */ __ats_lab_422_0: if (((ats_sum_ptr_type)tmp935)->tag != 29) { goto __ats_lab_423_0 ; } __ats_lab_422_1: tmp993 = ats_caselptrlab_mac(anairiats_sum_16, tmp935, atslab_2) ; /* tmp934 = */ aux_labs2explst_140 (tmp993, arg1) ; break ; /* branch: __ats_lab_423 */ __ats_lab_423_0: if (((ats_sum_ptr_type)tmp935)->tag != 30) { goto __ats_lab_424_0 ; } __ats_lab_423_1: tmp994 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_0) ; tmp995 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_1) ; tmp996 = ats_caselptrlab_mac(anairiats_sum_9, tmp935, atslab_2) ; /* ats_ptr_type tmp997 ; */ tmp997 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil ; /* tmp998 = */ aux_s2explst_138 (tmp995, (&tmp997)) ; /* tmp999 = */ aux_s2exp_137 (tmp996, (&tmp997)) ; tmp1000 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_dels (tmp997, tmp994) ; tmp997 = tmp1000 ; tmp1001 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_union (ats_ptrget_mac(ats_ptr_type, arg1), tmp997) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1001 ; break ; /* branch: __ats_lab_424 */ __ats_lab_424_0: if (((ats_sum_ptr_type)tmp935)->tag != 31) { goto __ats_lab_425_0 ; } __ats_lab_424_1: tmp1002 = ats_caselptrlab_mac(anairiats_sum_19, tmp935, atslab_1) ; tmp1003 = ats_caselptrlab_mac(anairiats_sum_19, tmp935, atslab_2) ; /* tmp1004 = */ aux_s2exp_137 (tmp1002, arg1) ; /* tmp934 = */ aux_labs2explst_140 (tmp1003, arg1) ; break ; /* branch: __ats_lab_425 */ __ats_lab_425_0: if (((ats_sum_ptr_type)tmp935)->tag != 32) { goto __ats_lab_426_0 ; } __ats_lab_425_1: tmp1005 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; tmp1006 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add (ats_ptrget_mac(ats_ptr_type, arg1), tmp1005) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1006 ; break ; /* branch: __ats_lab_426 */ __ats_lab_426_0: if (((ats_sum_ptr_type)tmp935)->tag != 33) { goto __ats_lab_427_0 ; } __ats_lab_426_1: tmp1007 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; /* tmp934 = */ aux_s2Var_144 (tmp1007, arg1) ; break ; /* branch: __ats_lab_427 */ __ats_lab_427_0: if (((ats_sum_ptr_type)tmp935)->tag != 34) { goto __ats_lab_428_0 ; } __ats_lab_427_1: tmp1008 = ats_caselptrlab_mac(anairiats_sum_1, tmp935, atslab_0) ; arg0 = tmp1008 ; arg1 = arg1 ; goto __ats_lab_aux_s2exp_137 ; // tail call break ; /* branch: __ats_lab_428 */ __ats_lab_428_0: // if (((ats_sum_ptr_type)tmp935)->tag != 35) { ats_deadcode_failure_handle () ; } __ats_lab_428_1: tmp1009 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_0) ; tmp1010 = ats_caselptrlab_mac(anairiats_sum_3, tmp935, atslab_1) ; /* tmp1011 = */ aux_s2exp_137 (tmp1009, arg1) ; /* tmp934 = */ aux_wths2explst_141 (tmp1010, arg1) ; break ; } while (0) ; return /* (tmp934) */ ; } /* end of [aux_s2exp_137] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 60721(line=1930, offs=5) -- 60937(line=1937, offs=22) */ ATSstaticdec() ats_void_type aux_s2explst_138 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; // ATSlocal_void (tmp1015) ; __ats_lab_aux_s2explst_138: do { /* branch: __ats_lab_429 */ __ats_lab_429_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_430_0 ; } __ats_lab_429_1: tmp1013 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp1014 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp1015 = */ aux_s2exp_137 (tmp1013, arg1) ; arg0 = tmp1014 ; arg1 = arg1 ; goto __ats_lab_aux_s2explst_138 ; // tail call break ; /* branch: __ats_lab_430 */ __ats_lab_430_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_430_1: break ; } while (0) ; return /* (tmp1012) */ ; } /* end of [aux_s2explst_138] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 60968(line=1940, offs=5) -- 61202(line=1947, offs=22) */ ATSstaticdec() ats_void_type aux_s2explstlst_139 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1016) ; ATSlocal (ats_ptr_type, tmp1017) ; ATSlocal (ats_ptr_type, tmp1018) ; // ATSlocal_void (tmp1019) ; __ats_lab_aux_s2explstlst_139: do { /* branch: __ats_lab_431 */ __ats_lab_431_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_432_0 ; } __ats_lab_431_1: tmp1017 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp1018 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp1019 = */ aux_s2explst_138 (tmp1017, arg1) ; arg0 = tmp1018 ; arg1 = arg1 ; goto __ats_lab_aux_s2explstlst_139 ; // tail call break ; /* branch: __ats_lab_432 */ __ats_lab_432_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_432_1: break ; } while (0) ; return /* (tmp1016) */ ; } /* end of [aux_s2explstlst_139] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 61236(line=1950, offs=5) -- 61493(line=1957, offs=28) */ ATSstaticdec() ats_void_type aux_labs2explst_140 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1020) ; ATSlocal (ats_ptr_type, tmp1021) ; ATSlocal (ats_ptr_type, tmp1022) ; // ATSlocal_void (tmp1023) ; __ats_lab_aux_labs2explst_140: do { /* branch: __ats_lab_433 */ __ats_lab_433_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_434_0 ; } __ats_lab_433_1: tmp1021 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp1022 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; /* tmp1023 = */ aux_s2exp_137 (tmp1021, arg1) ; arg0 = tmp1022 ; arg1 = arg1 ; goto __ats_lab_aux_labs2explst_140 ; // tail call break ; /* branch: __ats_lab_434 */ __ats_lab_434_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_434_1: break ; } while (0) ; return /* (tmp1020) */ ; } /* end of [aux_labs2explst_140] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 61527(line=1960, offs=5) -- 61874(line=1968, offs=28) */ ATSstaticdec() ats_void_type aux_wths2explst_141 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; // ATSlocal_void (tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; __ats_lab_aux_wths2explst_141: do { /* branch: __ats_lab_435 */ __ats_lab_435_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_436_0 ; } __ats_lab_435_1: tmp1025 = ats_caselptrlab_mac(anairiats_sum_24, arg0, atslab_1) ; tmp1026 = ats_caselptrlab_mac(anairiats_sum_24, arg0, atslab_2) ; /* tmp1027 = */ aux_s2exp_137 (tmp1025, arg1) ; arg0 = tmp1026 ; arg1 = arg1 ; goto __ats_lab_aux_wths2explst_141 ; // tail call break ; /* branch: __ats_lab_436 */ __ats_lab_436_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_437_0 ; } __ats_lab_436_1: tmp1028 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; arg0 = tmp1028 ; arg1 = arg1 ; goto __ats_lab_aux_wths2explst_141 ; // tail call break ; /* branch: __ats_lab_437 */ __ats_lab_437_0: // if (((ats_sum_ptr_type)arg0)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_437_1: break ; } while (0) ; return /* (tmp1024) */ ; } /* end of [aux_wths2explst_141] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 61908(line=1971, offs=5) -- 62069(line=1976, offs=51) */ ATSstaticdec() ats_void_type aux_s2eff_142 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1029) ; ATSlocal (ats_ptr_type, tmp1030) ; __ats_lab_aux_s2eff_142: do { /* branch: __ats_lab_438 */ __ats_lab_438_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_439_0 ; } __ats_lab_438_1: break ; /* branch: __ats_lab_439 */ __ats_lab_439_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_440_0 ; } __ats_lab_439_1: break ; /* branch: __ats_lab_440 */ __ats_lab_440_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_440_1: tmp1030 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_1) ; /* tmp1029 = */ aux_s2explst_138 (tmp1030, arg1) ; break ; } while (0) ; return /* (tmp1029) */ ; } /* end of [aux_s2eff_142] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 62097(line=1979, offs=5) -- 62409(line=1987, offs=8) */ ATSstaticdec() ats_void_type aux_s2lab_143 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1031) ; ATSlocal (ats_ptr_type, tmp1032) ; ATSlocal (ats_ptr_type, tmp1033) ; ATSlocal (ats_ptr_type, tmp1034) ; ATSlocal (ats_ptr_type, tmp1035) ; // ATSlocal_void (tmp1036) ; __ats_lab_aux_s2lab_143: do { /* branch: __ats_lab_441 */ __ats_lab_441_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_442_0 ; } __ats_lab_441_1: break ; /* branch: __ats_lab_442 */ __ats_lab_442_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_443_0 ; } __ats_lab_442_1: tmp1032 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; /* tmp1031 = */ aux_s2explstlst_139 (tmp1032, arg1) ; break ; /* branch: __ats_lab_443 */ __ats_lab_443_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_444_0 ; } __ats_lab_443_1: tmp1033 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp1031 = */ aux_s2exp_137 (tmp1033, arg1) ; break ; /* branch: __ats_lab_444 */ __ats_lab_444_0: // if (((ats_sum_ptr_type)arg0)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_444_1: tmp1034 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp1035 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp1036 = */ aux_s2explstlst_139 (tmp1034, arg1) ; /* tmp1031 = */ aux_s2exp_137 (tmp1035, arg1) ; break ; } while (0) ; return /* (tmp1031) */ ; } /* end of [aux_s2lab_143] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 62459(line=1990, offs=5) -- 62747(line=1997, offs=8) */ ATSstaticdec() ats_void_type aux_s2Var_144 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; ATSlocal (ats_ptr_type, tmp1039) ; // ATSlocal_void (tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; // ATSlocal_void (tmp1042) ; // ATSlocal_void (tmp1043) ; // ATSlocal_void (tmp1044) ; __ats_lab_aux_s2Var_144: tmp1038 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (arg0) ; do { /* branch: __ats_lab_445 */ __ats_lab_445_0: if (tmp1038 == (ats_sum_ptr_type)0) { goto __ats_lab_446_0 ; } __ats_lab_445_1: tmp1039 = ats_caselptrlab_mac(anairiats_sum_12, tmp1038, atslab_0) ; /* tmp1037 = */ aux_s2exp_137 (tmp1039, arg1) ; break ; /* branch: __ats_lab_446 */ __ats_lab_446_0: // if (tmp1038 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_446_1: tmp1041 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_loc (arg0) ; /* tmp1040 = */ prerr_loc_interror_2 (tmp1041) ; /* tmp1042 = */ atspre_prerr_string (ATSstrcst(": s2exp_freevars: s2V = ")) ; /* tmp1043 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2Var (arg0) ; /* tmp1044 = */ atspre_prerr_newline () ; /* tmp1037 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp1037) */ ; } /* end of [aux_s2Var_144] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 62792(line=2000, offs=5) -- 63396(line=2015, offs=52) */ ATSstaticdec() ats_void_type aux_s2zexp_145 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1045) ; ATSlocal (ats_ptr_type, tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; // ATSlocal_void (tmp1048) ; ATSlocal (ats_ptr_type, tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; // ATSlocal_void (tmp1051) ; ATSlocal (ats_ptr_type, tmp1052) ; ATSlocal (ats_ptr_type, tmp1053) ; ATSlocal (ats_ptr_type, tmp1054) ; ATSlocal (ats_ptr_type, tmp1055) ; __ats_lab_aux_s2zexp_145: do { /* branch: __ats_lab_447 */ __ats_lab_447_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_448_0 ; } __ats_lab_447_1: tmp1046 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp1047 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp1048 = */ aux_s2zexp_145 (tmp1046, arg1) ; /* tmp1045 = */ aux_s2zexplst_146 (tmp1047, arg1) ; break ; /* branch: __ats_lab_448 */ __ats_lab_448_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_449_0 ; } __ats_lab_448_1: break ; /* branch: __ats_lab_449 */ __ats_lab_449_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_450_0 ; } __ats_lab_449_1: break ; /* branch: __ats_lab_450 */ __ats_lab_450_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_451_0 ; } __ats_lab_450_1: break ; /* branch: __ats_lab_451 */ __ats_lab_451_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_452_0 ; } __ats_lab_451_1: break ; /* branch: __ats_lab_452 */ __ats_lab_452_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_453_0 ; } __ats_lab_452_1: tmp1049 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp1050 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp1051 = */ aux_s2zexp_145 (tmp1049, arg1) ; /* tmp1045 = */ aux_s2explstlst_139 (tmp1050, arg1) ; break ; /* branch: __ats_lab_453 */ __ats_lab_453_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_454_0 ; } __ats_lab_453_1: tmp1052 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; /* tmp1045 = */ aux_labs2zexplst_147 (tmp1052, arg1) ; break ; /* branch: __ats_lab_454 */ __ats_lab_454_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_455_0 ; } __ats_lab_454_1: tmp1053 = ats_caselptrlab_mac(anairiats_sum_20, arg0, atslab_1) ; /* tmp1045 = */ aux_labs2zexplst_147 (tmp1053, arg1) ; break ; /* branch: __ats_lab_455 */ __ats_lab_455_0: // if (((ats_sum_ptr_type)arg0)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_455_1: tmp1054 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp1055 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_add (ats_ptrget_mac(ats_ptr_type, arg1), tmp1054) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp1055 ; break ; } while (0) ; return /* (tmp1045) */ ; } /* end of [aux_s2zexp_145] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 63425(line=2018, offs=5) -- 63648(line=2024, offs=22) */ ATSstaticdec() ats_void_type aux_s2zexplst_146 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1056) ; ATSlocal (ats_ptr_type, tmp1057) ; ATSlocal (ats_ptr_type, tmp1058) ; // ATSlocal_void (tmp1059) ; __ats_lab_aux_s2zexplst_146: do { /* branch: __ats_lab_456 */ __ats_lab_456_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_457_0 ; } __ats_lab_456_1: tmp1057 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp1058 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_1) ; /* tmp1059 = */ aux_s2zexp_145 (tmp1057, arg1) ; arg0 = tmp1058 ; arg1 = arg1 ; goto __ats_lab_aux_s2zexplst_146 ; // tail call break ; /* branch: __ats_lab_457 */ __ats_lab_457_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_457_1: break ; } while (0) ; return /* (tmp1056) */ ; } /* end of [aux_s2zexplst_146] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 63680(line=2027, offs=5) -- 63947(line=2033, offs=29) */ ATSstaticdec() ats_void_type aux_labs2zexplst_147 (ats_ptr_type arg0, ats_ref_type arg1) { /* local vardec */ // ATSlocal_void (tmp1060) ; ATSlocal (ats_ptr_type, tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; // ATSlocal_void (tmp1063) ; __ats_lab_aux_labs2zexplst_147: do { /* branch: __ats_lab_458 */ __ats_lab_458_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_459_0 ; } __ats_lab_458_1: tmp1061 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp1062 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_2) ; /* tmp1063 = */ aux_s2zexp_145 (tmp1061, arg1) ; arg0 = tmp1062 ; arg1 = arg1 ; goto __ats_lab_aux_labs2zexplst_147 ; // tail call break ; /* branch: __ats_lab_459 */ __ats_lab_459_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_459_1: break ; } while (0) ; return /* (tmp1060) */ ; } /* end of [aux_labs2zexplst_147] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 64007(line=2039, offs=16) -- 64088(line=2040, offs=74) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_freevars (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; // ATSlocal_void (tmp1066) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_freevars: /* ats_ptr_type tmp1065 ; */ tmp1065 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varset_nil ; /* tmp1066 = */ aux_s2exp_137 (arg0, (&tmp1065)) ; tmp1064 = tmp1065 ; return (tmp1064) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_freevars] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 64172(line=2049, offs=5) -- 68355(line=2150, offs=8) */ ATSstaticdec() ats_void_type aux_s2exp_149 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; ATSlocal (ats_ptr_type, tmp1070) ; // ATSlocal_void (tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; ATSlocal (ats_ptr_type, tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; ATSlocal (ats_bool_type, tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; ATSlocal (ats_ptr_type, tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; ATSlocal (ats_ptr_type, tmp1082) ; // ATSlocal_void (tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; ATSlocal (ats_ptr_type, tmp1085) ; // ATSlocal_void (tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; ATSlocal (ats_ptr_type, tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; // ATSlocal_void (tmp1091) ; // ATSlocal_void (tmp1092) ; ATSlocal (ats_ptr_type, tmp1093) ; ATSlocal (ats_ptr_type, tmp1094) ; ATSlocal (ats_ptr_type, tmp1095) ; // ATSlocal_void (tmp1096) ; ATSlocal (ats_ptr_type, tmp1097) ; ATSlocal (ats_ptr_type, tmp1098) ; // ATSlocal_void (tmp1099) ; ATSlocal (ats_ptr_type, tmp1100) ; ATSlocal (ats_ptr_type, tmp1101) ; ATSlocal (ats_ptr_type, tmp1102) ; // ATSlocal_void (tmp1103) ; ATSlocal (ats_ptr_type, tmp1104) ; ATSlocal (ats_ptr_type, tmp1105) ; // ATSlocal_void (tmp1106) ; ATSlocal (ats_ptr_type, tmp1107) ; ATSlocal (ats_ptr_type, tmp1108) ; ATSlocal (ats_ptr_type, tmp1109) ; ATSlocal (ats_ptr_type, tmp1110) ; ATSlocal (ats_ptr_type, tmp1111) ; ATSlocal (ats_ptr_type, tmp1112) ; ATSlocal (ats_ptr_type, tmp1113) ; ATSlocal (ats_ptr_type, tmp1114) ; // ATSlocal_void (tmp1115) ; ATSlocal (ats_ptr_type, tmp1116) ; ATSlocal (ats_ptr_type, tmp1117) ; // ATSlocal_void (tmp1118) ; ATSlocal (ats_ptr_type, tmp1119) ; ATSlocal (ats_ptr_type, tmp1120) ; ATSlocal (ats_ptr_type, tmp1121) ; ATSlocal (ats_ptr_type, tmp1122) ; // ATSlocal_void (tmp1123) ; ATSlocal (ats_ptr_type, tmp1124) ; ATSlocal (ats_ptr_type, tmp1125) ; // ATSlocal_void (tmp1126) ; ATSlocal (ats_ptr_type, tmp1127) ; ATSlocal (ats_ptr_type, tmp1128) ; ATSlocal (ats_ptr_type, tmp1129) ; ATSlocal (ats_ptr_type, tmp1130) ; ATSlocal (ats_ptr_type, tmp1131) ; // ATSlocal_void (tmp1132) ; __ats_lab_aux_s2exp_149: tmp1068 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_460 */ __ats_lab_460_0: if (((ats_sum_ptr_type)tmp1068)->tag != 0) { goto __ats_lab_461_0 ; } __ats_lab_460_1: tmp1069 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1070 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1071 = */ aux_s2exp_149 (arg0, tmp1069, arg2, arg3, arg4) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1070, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_461 */ __ats_lab_461_0: if (((ats_sum_ptr_type)tmp1068)->tag != 1) { goto __ats_lab_462_0 ; } __ats_lab_461_1: break ; /* branch: __ats_lab_462 */ __ats_lab_462_0: if (((ats_sum_ptr_type)tmp1068)->tag != 2) { goto __ats_lab_463_0 ; } __ats_lab_462_1: tmp1072 = ats_caselptrlab_mac(anairiats_sum_15, tmp1068, atslab_1) ; arg0 = arg0 ; arg1 = tmp1072 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_463 */ __ats_lab_463_0: if (((ats_sum_ptr_type)tmp1068)->tag != 3) { goto __ats_lab_464_0 ; } __ats_lab_463_1: tmp1073 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; arg0 = arg0 ; arg1 = tmp1073 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_464 */ __ats_lab_464_0: if (((ats_sum_ptr_type)tmp1068)->tag != 4) { goto __ats_lab_465_0 ; } __ats_lab_464_1: tmp1074 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_sVarset (tmp1074) ; tmp1076 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem (tmp1075, arg0) ; if (tmp1076) { tmp1077 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1077, atslab_0, tmp1074) ; ats_selptrset_mac(anairiats_sum_4, tmp1077, atslab_1, ats_ptrget_mac(ats_ptr_type, arg3)) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp1077 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_465 */ __ats_lab_465_0: if (((ats_sum_ptr_type)tmp1068)->tag != 5) { goto __ats_lab_466_0 ; } __ats_lab_465_1: tmp1078 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1078, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_466 */ __ats_lab_466_0: if (((ats_sum_ptr_type)tmp1068)->tag != 6) { goto __ats_lab_467_0 ; } __ats_lab_466_1: tmp1079 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1079, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_467 */ __ats_lab_467_0: if (((ats_sum_ptr_type)tmp1068)->tag != 7) { goto __ats_lab_468_0 ; } __ats_lab_467_1: tmp1080 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2eff_154 (arg0, tmp1080, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_468 */ __ats_lab_468_0: if (((ats_sum_ptr_type)tmp1068)->tag != 8) { goto __ats_lab_469_0 ; } __ats_lab_468_1: tmp1081 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1082 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1083 = */ aux_s2exp_149 (arg0, tmp1081, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1082 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_469 */ __ats_lab_469_0: if (((ats_sum_ptr_type)tmp1068)->tag != 9) { goto __ats_lab_470_0 ; } __ats_lab_469_1: tmp1084 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_1) ; tmp1085 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_2) ; /* tmp1086 = */ aux_s2explst_150 (arg0, tmp1084, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1085 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_470 */ __ats_lab_470_0: if (((ats_sum_ptr_type)tmp1068)->tag != 10) { goto __ats_lab_471_0 ; } __ats_lab_470_1: tmp1087 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1067 = */ aux_s2explstlst_151 (arg0, tmp1087, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_471 */ __ats_lab_471_0: if (((ats_sum_ptr_type)tmp1068)->tag != 11) { goto __ats_lab_472_0 ; } __ats_lab_471_1: tmp1088 = ats_caselptrlab_mac(anairiats_sum_14, tmp1068, atslab_2) ; tmp1089 = ats_caselptrlab_mac(anairiats_sum_14, tmp1068, atslab_4) ; tmp1090 = ats_caselptrlab_mac(anairiats_sum_14, tmp1068, atslab_5) ; /* tmp1091 = */ aux_s2eff_154 (arg0, tmp1088, arg2, arg3, arg4) ; /* tmp1092 = */ aux_s2explst_150 (arg0, tmp1089, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1090 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_472 */ __ats_lab_472_0: if (((ats_sum_ptr_type)tmp1068)->tag != 12) { goto __ats_lab_473_0 ; } __ats_lab_472_1: break ; /* branch: __ats_lab_473 */ __ats_lab_473_0: if (((ats_sum_ptr_type)tmp1068)->tag != 13) { goto __ats_lab_474_0 ; } __ats_lab_473_1: break ; /* branch: __ats_lab_474 */ __ats_lab_474_0: if (((ats_sum_ptr_type)tmp1068)->tag != 14) { goto __ats_lab_475_0 ; } __ats_lab_474_1: tmp1093 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; arg0 = arg0 ; arg1 = tmp1093 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_475 */ __ats_lab_475_0: if (((ats_sum_ptr_type)tmp1068)->tag != 15) { goto __ats_lab_476_0 ; } __ats_lab_475_1: tmp1094 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_1) ; tmp1095 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_2) ; /* tmp1096 = */ aux_s2explst_150 (arg0, tmp1094, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1095 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_476 */ __ats_lab_476_0: if (((ats_sum_ptr_type)tmp1068)->tag != 16) { goto __ats_lab_477_0 ; } __ats_lab_476_1: tmp1097 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1098 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1099 = */ aux_s2explst_150 (arg0, tmp1097, arg2, arg3, arg4) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1098, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_477 */ __ats_lab_477_0: if (((ats_sum_ptr_type)tmp1068)->tag != 17) { goto __ats_lab_478_0 ; } __ats_lab_477_1: tmp1100 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; arg0 = arg0 ; arg1 = tmp1100 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_478 */ __ats_lab_478_0: if (((ats_sum_ptr_type)tmp1068)->tag != 18) { goto __ats_lab_479_0 ; } __ats_lab_478_1: tmp1101 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1102 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1103 = */ aux_s2exp_149 (arg0, tmp1101, arg2, arg3, arg4) ; /* tmp1067 = */ aux_s2lab_155 (arg0, tmp1102, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_479 */ __ats_lab_479_0: if (((ats_sum_ptr_type)tmp1068)->tag != 19) { goto __ats_lab_480_0 ; } __ats_lab_479_1: tmp1104 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1105 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1106 = */ aux_s2exp_149 (arg0, tmp1104, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1105 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_480 */ __ats_lab_480_0: if (((ats_sum_ptr_type)tmp1068)->tag != 20) { goto __ats_lab_481_0 ; } __ats_lab_480_1: tmp1107 = ats_caselptrlab_mac(anairiats_sum_15, tmp1068, atslab_1) ; arg0 = arg0 ; arg1 = tmp1107 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_481 */ __ats_lab_481_0: if (((ats_sum_ptr_type)tmp1068)->tag != 21) { goto __ats_lab_482_0 ; } __ats_lab_481_1: tmp1108 = ats_caselptrlab_mac(anairiats_sum_23, tmp1068, atslab_0) ; arg0 = arg0 ; arg1 = tmp1108 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_482 */ __ats_lab_482_0: if (((ats_sum_ptr_type)tmp1068)->tag != 22) { goto __ats_lab_483_0 ; } __ats_lab_482_1: tmp1109 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2zexp_158 (arg0, tmp1109, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_483 */ __ats_lab_483_0: if (((ats_sum_ptr_type)tmp1068)->tag != 23) { goto __ats_lab_484_0 ; } __ats_lab_483_1: tmp1110 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; arg0 = arg0 ; arg1 = tmp1110 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_484 */ __ats_lab_484_0: if (((ats_sum_ptr_type)tmp1068)->tag != 24) { goto __ats_lab_485_0 ; } __ats_lab_484_1: tmp1111 = ats_caselptrlab_mac(anairiats_sum_15, tmp1068, atslab_1) ; arg0 = arg0 ; arg1 = tmp1111 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_485 */ __ats_lab_485_0: if (((ats_sum_ptr_type)tmp1068)->tag != 25) { goto __ats_lab_486_0 ; } __ats_lab_485_1: tmp1112 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1112, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_486 */ __ats_lab_486_0: if (((ats_sum_ptr_type)tmp1068)->tag != 26) { goto __ats_lab_487_0 ; } __ats_lab_486_1: tmp1113 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1114 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1115 = */ aux_s2exp_149 (arg0, tmp1113, arg2, arg3, arg4) ; /* tmp1067 = */ aux_s2explstlst_151 (arg0, tmp1114, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_487 */ __ats_lab_487_0: if (((ats_sum_ptr_type)tmp1068)->tag != 27) { goto __ats_lab_488_0 ; } __ats_lab_487_1: tmp1116 = ats_caselptrlab_mac(anairiats_sum_24, tmp1068, atslab_1) ; tmp1117 = ats_caselptrlab_mac(anairiats_sum_24, tmp1068, atslab_2) ; /* tmp1118 = */ aux_s2exp_149 (arg0, tmp1116, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1117 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_488 */ __ats_lab_488_0: if (((ats_sum_ptr_type)tmp1068)->tag != 28) { goto __ats_lab_489_0 ; } __ats_lab_488_1: tmp1119 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2explst_150 (arg0, tmp1119, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_489 */ __ats_lab_489_0: if (((ats_sum_ptr_type)tmp1068)->tag != 29) { goto __ats_lab_490_0 ; } __ats_lab_489_1: tmp1120 = ats_caselptrlab_mac(anairiats_sum_16, tmp1068, atslab_2) ; /* tmp1067 = */ aux_labs2explst_152 (arg0, tmp1120, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_490 */ __ats_lab_490_0: if (((ats_sum_ptr_type)tmp1068)->tag != 30) { goto __ats_lab_491_0 ; } __ats_lab_490_1: tmp1121 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_1) ; tmp1122 = ats_caselptrlab_mac(anairiats_sum_9, tmp1068, atslab_2) ; /* tmp1123 = */ aux_s2explst_150 (arg0, tmp1121, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1122 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_491 */ __ats_lab_491_0: if (((ats_sum_ptr_type)tmp1068)->tag != 31) { goto __ats_lab_492_0 ; } __ats_lab_491_1: tmp1124 = ats_caselptrlab_mac(anairiats_sum_19, tmp1068, atslab_1) ; tmp1125 = ats_caselptrlab_mac(anairiats_sum_19, tmp1068, atslab_2) ; /* tmp1126 = */ aux_s2exp_149 (arg0, tmp1124, arg2, arg3, arg4) ; /* tmp1067 = */ aux_labs2explst_152 (arg0, tmp1125, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_492 */ __ats_lab_492_0: if (((ats_sum_ptr_type)tmp1068)->tag != 32) { goto __ats_lab_493_0 ; } __ats_lab_492_1: tmp1127 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2var_156 (arg0, tmp1127, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_493 */ __ats_lab_493_0: if (((ats_sum_ptr_type)tmp1068)->tag != 33) { goto __ats_lab_494_0 ; } __ats_lab_493_1: tmp1128 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; /* tmp1067 = */ aux_s2Var_157 (arg0, tmp1128, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_494 */ __ats_lab_494_0: if (((ats_sum_ptr_type)tmp1068)->tag != 34) { goto __ats_lab_495_0 ; } __ats_lab_494_1: tmp1129 = ats_caselptrlab_mac(anairiats_sum_1, tmp1068, atslab_0) ; arg0 = arg0 ; arg1 = tmp1129 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2exp_149 ; // tail call break ; /* branch: __ats_lab_495 */ __ats_lab_495_0: // if (((ats_sum_ptr_type)tmp1068)->tag != 35) { ats_deadcode_failure_handle () ; } __ats_lab_495_1: tmp1130 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_0) ; tmp1131 = ats_caselptrlab_mac(anairiats_sum_3, tmp1068, atslab_1) ; /* tmp1132 = */ aux_s2exp_149 (arg0, tmp1130, arg2, arg3, arg4) ; /* tmp1067 = */ aux_wths2explst_153 (arg0, tmp1131, arg2, arg3, arg4) ; break ; } while (0) ; return /* (tmp1067) */ ; } /* end of [aux_s2exp_149] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 68402(line=2153, offs=5) -- 68723(line=2163, offs=4) */ ATSstaticdec() ats_void_type aux_s2explst_150 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1133) ; ATSlocal (ats_ptr_type, tmp1134) ; ATSlocal (ats_ptr_type, tmp1135) ; // ATSlocal_void (tmp1136) ; __ats_lab_aux_s2explst_150: do { /* branch: __ats_lab_496 */ __ats_lab_496_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_497_0 ; } __ats_lab_496_1: tmp1134 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1135 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp1136 = */ aux_s2exp_149 (arg0, tmp1134, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1135 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2explst_150 ; // tail call break ; /* branch: __ats_lab_497 */ __ats_lab_497_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_497_1: break ; } while (0) ; return /* (tmp1133) */ ; } /* end of [aux_s2explst_150] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 68754(line=2165, offs=5) -- 69092(line=2176, offs=4) */ ATSstaticdec() ats_void_type aux_s2explstlst_151 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1137) ; ATSlocal (ats_ptr_type, tmp1138) ; ATSlocal (ats_ptr_type, tmp1139) ; // ATSlocal_void (tmp1140) ; __ats_lab_aux_s2explstlst_151: do { /* branch: __ats_lab_498 */ __ats_lab_498_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_499_0 ; } __ats_lab_498_1: tmp1138 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1139 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp1140 = */ aux_s2explst_150 (arg0, tmp1138, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1139 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2explstlst_151 ; // tail call break ; /* branch: __ats_lab_499 */ __ats_lab_499_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_499_1: break ; } while (0) ; return /* (tmp1137) */ ; } /* end of [aux_s2explstlst_151] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 69126(line=2178, offs=5) -- 69487(line=2189, offs=4) */ ATSstaticdec() ats_void_type aux_labs2explst_152 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1141) ; ATSlocal (ats_ptr_type, tmp1142) ; ATSlocal (ats_ptr_type, tmp1143) ; // ATSlocal_void (tmp1144) ; __ats_lab_aux_labs2explst_152: do { /* branch: __ats_lab_500 */ __ats_lab_500_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_501_0 ; } __ats_lab_500_1: tmp1142 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp1143 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; /* tmp1144 = */ aux_s2exp_149 (arg0, tmp1142, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1143 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_labs2explst_152 ; // tail call break ; /* branch: __ats_lab_501 */ __ats_lab_501_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_501_1: break ; } while (0) ; return /* (tmp1141) */ ; } /* end of [aux_labs2explst_152] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 69521(line=2191, offs=5) -- 69955(line=2202, offs=28) */ ATSstaticdec() ats_void_type aux_wths2explst_153 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1145) ; ATSlocal (ats_ptr_type, tmp1146) ; ATSlocal (ats_ptr_type, tmp1147) ; // ATSlocal_void (tmp1148) ; ATSlocal (ats_ptr_type, tmp1149) ; __ats_lab_aux_wths2explst_153: do { /* branch: __ats_lab_502 */ __ats_lab_502_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_503_0 ; } __ats_lab_502_1: tmp1146 = ats_caselptrlab_mac(anairiats_sum_24, arg1, atslab_1) ; tmp1147 = ats_caselptrlab_mac(anairiats_sum_24, arg1, atslab_2) ; /* tmp1148 = */ aux_s2exp_149 (arg0, tmp1146, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1147 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_wths2explst_153 ; // tail call break ; /* branch: __ats_lab_503 */ __ats_lab_503_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_504_0 ; } __ats_lab_503_1: tmp1149 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; arg0 = arg0 ; arg1 = tmp1149 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_wths2explst_153 ; // tail call break ; /* branch: __ats_lab_504 */ __ats_lab_504_0: // if (((ats_sum_ptr_type)arg1)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_504_1: break ; } while (0) ; return /* (tmp1145) */ ; } /* end of [aux_wths2explst_153] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 69989(line=2205, offs=5) -- 70222(line=2213, offs=4) */ ATSstaticdec() ats_void_type aux_s2eff_154 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1150) ; ATSlocal (ats_ptr_type, tmp1151) ; __ats_lab_aux_s2eff_154: do { /* branch: __ats_lab_505 */ __ats_lab_505_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_506_0 ; } __ats_lab_505_1: break ; /* branch: __ats_lab_506 */ __ats_lab_506_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_507_0 ; } __ats_lab_506_1: break ; /* branch: __ats_lab_507 */ __ats_lab_507_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_507_1: tmp1151 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_1) ; /* tmp1150 = */ aux_s2explst_150 (arg0, tmp1151, arg2, arg3, arg4) ; break ; } while (0) ; return /* (tmp1150) */ ; } /* end of [aux_s2eff_154] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 70250(line=2215, offs=5) -- 70770(line=2230, offs=4) */ ATSstaticdec() ats_void_type aux_s2lab_155 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1152) ; ATSlocal (ats_ptr_type, tmp1153) ; ATSlocal (ats_ptr_type, tmp1154) ; ATSlocal (ats_ptr_type, tmp1155) ; ATSlocal (ats_ptr_type, tmp1156) ; // ATSlocal_void (tmp1157) ; __ats_lab_aux_s2lab_155: do { /* branch: __ats_lab_508 */ __ats_lab_508_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_509_0 ; } __ats_lab_508_1: break ; /* branch: __ats_lab_509 */ __ats_lab_509_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_510_0 ; } __ats_lab_509_1: tmp1153 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp1152 = */ aux_s2explstlst_151 (arg0, tmp1153, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_510 */ __ats_lab_510_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_511_0 ; } __ats_lab_510_1: tmp1154 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp1152 = */ aux_s2exp_149 (arg0, tmp1154, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_511 */ __ats_lab_511_0: // if (((ats_sum_ptr_type)arg1)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_511_1: tmp1155 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp1156 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp1157 = */ aux_s2explstlst_151 (arg0, tmp1155, arg2, arg3, arg4) ; /* tmp1152 = */ aux_s2exp_149 (arg0, tmp1156, arg2, arg3, arg4) ; break ; } while (0) ; return /* (tmp1152) */ ; } /* end of [aux_s2lab_155] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 70798(line=2232, offs=5) -- 71040(line=2241, offs=4) */ ATSstaticdec() ats_void_type aux_s2var_156 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1158) ; ATSlocal (ats_ptr_type, tmp1159) ; ATSlocal (ats_bool_type, tmp1160) ; ATSlocal (ats_ptr_type, tmp1161) ; __ats_lab_aux_s2var_156: tmp1159 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_sVarset (arg1) ; tmp1160 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem (tmp1159, arg0) ; if (tmp1160) { tmp1161 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ats_selptrset_mac(anairiats_sum_4, tmp1161, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_4, tmp1161, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp1161 ; } else { /* empty */ } /* end of [if] */ return /* (tmp1158) */ ; } /* end of [aux_s2var_156] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 71068(line=2243, offs=5) -- 71553(line=2260, offs=4) */ ATSstaticdec() ats_void_type aux_s2Var_157 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1162) ; ATSlocal (ats_ptr_type, tmp1163) ; ATSlocal (ats_ptr_type, tmp1164) ; ATSlocal (ats_bool_type, tmp1165) ; ATSlocal (ats_int_type, tmp1166) ; ATSlocal (ats_ptr_type, tmp1167) ; ATSlocal (ats_bool_type, tmp1168) ; ATSlocal (ats_int_type, tmp1169) ; __ats_lab_aux_s2Var_157: tmp1163 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_link (arg1) ; do { /* branch: __ats_lab_512 */ __ats_lab_512_0: if (tmp1163 == (ats_sum_ptr_type)0) { goto __ats_lab_513_0 ; } __ats_lab_512_1: tmp1164 = ats_caselptrlab_mac(anairiats_sum_12, tmp1163, atslab_0) ; /* tmp1162 = */ aux_s2exp_149 (arg0, tmp1164, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_513 */ __ats_lab_513_0: // if (tmp1163 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_513_1: tmp1165 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_s2Var_s2Var (arg0, arg1) ; if (tmp1165) { tmp1166 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp1166 ; } else { tmp1167 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_get_sVarset (arg1) ; tmp1168 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_ismem (tmp1167, arg0) ; if (tmp1168) { tmp1169 = atspre_add_int_int (ats_ptrget_mac(ats_int_type, arg2), 1) ; ats_ptrget_mac(ats_int_type, arg2) = tmp1169 ; } else { /* empty */ } /* end of [if] */ } /* end of [if] */ break ; } while (0) ; return /* (tmp1162) */ ; } /* end of [aux_s2Var_157] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 71581(line=2262, offs=5) -- 72388(line=2286, offs=4) */ ATSstaticdec() ats_void_type aux_s2zexp_158 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1170) ; ATSlocal (ats_ptr_type, tmp1171) ; ATSlocal (ats_ptr_type, tmp1172) ; // ATSlocal_void (tmp1173) ; ATSlocal (ats_ptr_type, tmp1174) ; ATSlocal (ats_ptr_type, tmp1175) ; // ATSlocal_void (tmp1176) ; ATSlocal (ats_ptr_type, tmp1177) ; ATSlocal (ats_ptr_type, tmp1178) ; ATSlocal (ats_ptr_type, tmp1179) ; __ats_lab_aux_s2zexp_158: do { /* branch: __ats_lab_514 */ __ats_lab_514_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_515_0 ; } __ats_lab_514_1: tmp1171 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp1172 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp1173 = */ aux_s2zexp_158 (arg0, tmp1171, arg2, arg3, arg4) ; /* tmp1170 = */ aux_s2zexplst_159 (arg0, tmp1172, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_515 */ __ats_lab_515_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_516_0 ; } __ats_lab_515_1: break ; /* branch: __ats_lab_516 */ __ats_lab_516_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_517_0 ; } __ats_lab_516_1: break ; /* branch: __ats_lab_517 */ __ats_lab_517_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_518_0 ; } __ats_lab_517_1: break ; /* branch: __ats_lab_518 */ __ats_lab_518_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_519_0 ; } __ats_lab_518_1: break ; /* branch: __ats_lab_519 */ __ats_lab_519_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_520_0 ; } __ats_lab_519_1: tmp1174 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_0) ; tmp1175 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp1176 = */ aux_s2zexp_158 (arg0, tmp1174, arg2, arg3, arg4) ; /* tmp1170 = */ aux_s2explstlst_151 (arg0, tmp1175, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_520 */ __ats_lab_520_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_521_0 ; } __ats_lab_520_1: tmp1177 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; /* tmp1170 = */ aux_labs2zexplst_160 (arg0, tmp1177, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_521 */ __ats_lab_521_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_522_0 ; } __ats_lab_521_1: tmp1178 = ats_caselptrlab_mac(anairiats_sum_20, arg1, atslab_1) ; /* tmp1170 = */ aux_labs2zexplst_160 (arg0, tmp1178, arg2, arg3, arg4) ; break ; /* branch: __ats_lab_522 */ __ats_lab_522_0: // if (((ats_sum_ptr_type)arg1)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_522_1: tmp1179 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; /* tmp1170 = */ aux_s2var_156 (arg0, tmp1179, arg2, arg3, arg4) ; break ; } while (0) ; return /* (tmp1170) */ ; } /* end of [aux_s2zexp_158] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 72417(line=2288, offs=5) -- 72727(line=2296, offs=22) */ ATSstaticdec() ats_void_type aux_s2zexplst_159 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1180) ; ATSlocal (ats_ptr_type, tmp1181) ; ATSlocal (ats_ptr_type, tmp1182) ; // ATSlocal_void (tmp1183) ; __ats_lab_aux_s2zexplst_159: do { /* branch: __ats_lab_523 */ __ats_lab_523_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_524_0 ; } __ats_lab_523_1: tmp1181 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp1182 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp1183 = */ aux_s2zexp_158 (arg0, tmp1181, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1182 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_s2zexplst_159 ; // tail call break ; /* branch: __ats_lab_524 */ __ats_lab_524_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_524_1: break ; } while (0) ; return /* (tmp1180) */ ; } /* end of [aux_s2zexplst_159] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 72759(line=2299, offs=5) -- 73116(line=2307, offs=29) */ ATSstaticdec() ats_void_type aux_labs2zexplst_160 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4) { /* local vardec */ // ATSlocal_void (tmp1184) ; ATSlocal (ats_ptr_type, tmp1185) ; ATSlocal (ats_ptr_type, tmp1186) ; // ATSlocal_void (tmp1187) ; __ats_lab_aux_labs2zexplst_160: do { /* branch: __ats_lab_525 */ __ats_lab_525_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_526_0 ; } __ats_lab_525_1: tmp1185 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp1186 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_2) ; /* tmp1187 = */ aux_s2zexp_158 (arg0, tmp1185, arg2, arg3, arg4) ; arg0 = arg0 ; arg1 = tmp1186 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; goto __ats_lab_aux_labs2zexplst_160 ; // tail call break ; /* branch: __ats_lab_526 */ __ats_lab_526_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_526_1: break ; } while (0) ; return /* (tmp1184) */ ; } /* end of [aux_labs2zexplst_160] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp2_util1.dats: 73199(line=2314, offs=3) -- 73306(line=2316, offs=2) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2, ats_ref_type arg3) { /* local vardec */ ATSlocal (ats_int_type, tmp1188) ; ATSlocal (ats_int_type, tmp1189) ; // ATSlocal_void (tmp1190) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs: /* ats_int_type tmp1189 ; */ tmp1189 = 0 ; /* tmp1190 = */ aux_s2exp_149 (arg0, arg1, (&tmp1189), arg2, arg3) ; tmp1188 = tmp1189 ; return (tmp1188) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_s2exp_occurs] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_util1_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp534, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp534 = (ats_sum_ptr_type)0 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil = statmp534 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp2_util1_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_sats.c0000664000175000017500000005403212223166160021533 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_i2nvresstate_svs ; ats_ptr_type atslab_i2nvresstate_gua ; ats_ptr_type atslab_i2nvresstate_arg ; ats_ptr_type atslab_i2nvresstate_met ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTnone_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMe1xp_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacdef_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacvar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINdone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINsome_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINvbox_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABlab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ebool_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Edynload_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloatsp_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eintsp_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eshowtype_48) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clist_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cinclude_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymintr_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymelim_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstavars_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csaspdec_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdcstdec_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdatdec_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cexndec_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Coverload_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextype_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextval_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextcode_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_par_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_rec_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cfundecs_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvardecs_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cimpdec_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clocal_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdynload_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstaload_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGone_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGlst_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALarrsub_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALptr_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_lin_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_mut_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALnone_4) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symenv_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTsome_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2CSTOPTnone_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcon_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMcst_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMe1xp_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacdef_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMmacvar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMsymdef_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2ITEMvar_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINdone_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINsome_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINvbox_3.tag = 3 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTnil_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTdot_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5.tag = 5 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABlab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2LABind_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABD2EXPLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGsta_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2EXPARGdyn_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_funclo_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_seff_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eann_type_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eapps_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrinit_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrpsz_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Earrsub_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eassgn_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ebool_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecaseof_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Echar_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Econ_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecst_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecstsp_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ecrypt_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ederef_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Edynload_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eeffmask_17.tag = 17 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eempty_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eexist_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eextval_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efix_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloat_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efloatsp_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efoldat_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efor_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Efreeat_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eif_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eint_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eintsp_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_dyn_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elaminit_dyn_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_met_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elam_sta_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_delay_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elazy_ldelay_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elet_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elist_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eloopexn_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Elst_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emac_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Emacsyn_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eptrof_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eraise_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Erec_44.tag = 44 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Escaseof_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esel_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eseq_47.tag = 47 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eshowtype_48.tag = 48 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esif_49.tag = 49 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estruct_50.tag = 50 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Estring_51.tag = 51 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Esym_52.tag = 52 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etmpid_53.tag = 53 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etop_54.tag = 54 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Etrywith_55.tag = 55 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Evar_56.tag = 56 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Eviewat_57.tag = 57 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhere_58.tag = 58 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Ewhile_59.tag = 59 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cnone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clist_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cinclude_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymintr_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csymelim_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstavars_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Csaspdec_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdcstdec_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdatdec_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cexndec_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Coverload_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextype_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextval_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cextcode_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_par_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvaldecs_rec_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cfundecs_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cvardecs_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cimpdec_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Clocal_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cdynload_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2Cstaload_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGone_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__MACARGlst_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALarrsub_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALptr_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_lin_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALvar_mut_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__L2VALnone_4.tag = 4 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_dynexp2_dmac_dats.c0000664000175000017500000003465312223166160022507 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_d2mac_loc ; ats_ptr_type atslab_d2mac_sym ; ats_int_type atslab_d2mac_kind ; ats_int_type atslab_d2mac_narg ; ats_ptr_type atslab_d2mac_arglst ; ats_ptr_type atslab_d2mac_def ; atsopt_count_type atslab_d2mac_stamp ; } anairiats_rec_1 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_vbox_make_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, atspre_ptr_alloc_tsz) (ats_size_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2mac_stamp_make) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym) (ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__sasp__d2mac_abs_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_int_type aux_1 (ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 2458(line=85, offs=7) -- 2588(line=87, offs=63) */ ATSstaticdec() ats_int_type aux_1 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_int_type, tmp3) ; __ats_lab_aux_1: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp3 = aux_1 (tmp2) ; tmp1 = atspre_iadd (1, tmp3) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp1 = 0 ; break ; } while (0) ; return (tmp1) ; } /* end of [aux_1] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 2387(line=82, offs=3) -- 3097(line=112, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_make (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp0) ; ATSlocal (ats_int_type, tmp4) ; ATSlocal (atsopt_count_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_make: tmp4 = aux_1 (arg3) ; tmp5 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__d2mac_stamp_make () ; tmp6 = atspre_ptr_alloc_tsz (sizeof(anairiats_rec_1)) ; tmp7 = ats_selsin_mac(tmp6, atslab_2) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_loc) = arg0 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_sym) = arg1 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_kind) = arg2 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_narg) = tmp4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_arglst) = arg3 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_def) = arg4 ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp7), atslab_d2mac_stamp) = tmp5 ; /* tmp8 = */ atspre_vbox_make_view_ptr (tmp7) ; /* tmp9 = ats_selsin_mac(tmp8, atslab_1) */ ; tmp0 = tmp7 ; return (tmp0) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_make] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3146(line=114, offs=25) -- 3203(line=115, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_loc (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_loc: tmp11 = ats_selsin_mac(arg0, atslab_1) ; tmp10 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp11), atslab_d2mac_loc) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_loc] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3229(line=117, offs=25) -- 3286(line=118, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym: tmp13 = ats_selsin_mac(arg0, atslab_1) ; tmp12 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp13), atslab_d2mac_sym) ; return (tmp12) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3313(line=120, offs=26) -- 3371(line=121, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind: tmp15 = ats_selsin_mac(arg0, atslab_1) ; tmp14 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp15), atslab_d2mac_kind) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_kind] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3398(line=123, offs=26) -- 3456(line=124, offs=51) */ ATSglobaldec() ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg: tmp17 = ats_selsin_mac(arg0, atslab_1) ; tmp16 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp17), atslab_d2mac_narg) ; return (tmp16) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_narg] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3485(line=126, offs=28) -- 3545(line=127, offs=53) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst: tmp19 = ats_selsin_mac(arg0, atslab_1) ; tmp18 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp19), atslab_d2mac_arglst) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_arglst] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3571(line=129, offs=25) -- 3628(line=130, offs=50) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def: tmp21 = ats_selsin_mac(arg0, atslab_1) ; tmp20 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp21), atslab_d2mac_def) ; return (tmp20) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_def] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3654(line=132, offs=25) -- 3723(line=133, offs=57) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_set_def (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_set_def: tmp23 = ats_selsin_mac(arg0, atslab_1) ; ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp23), atslab_d2mac_def) = arg1 ; return /* (tmp22) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_set_def] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3751(line=135, offs=27) -- 3810(line=136, offs=52) */ ATSglobaldec() atsopt_count_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_stamp (ats_ptr_type arg0) { /* local vardec */ ATSlocal (atsopt_count_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_stamp: tmp25 = ats_selsin_mac(arg0, atslab_1) ; tmp24 = ats_selptr_mac(ats_castptr_mac(anairiats_rec_1, tmp25), atslab_d2mac_stamp) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_stamp] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 3904(line=143, offs=14) -- 3980(line=144, offs=55) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac: tmp27 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2mac_get_sym (arg1) ; /* tmp26 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp27) ; return /* (tmp26) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 4029(line=147, offs=23) -- 4066(line=147, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2mac (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; // ATSlocal_void (tmp31) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2mac: tmp29 = atspre_stdout_get () ; tmp30 = ats_selsin_mac(tmp29, atslab_1) ; /* tmp31 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac (tmp30, arg0) ; /* tmp28 = */ atspre_stdout_view_set () ; return /* (tmp28) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2mac] */ /* // /home/hwxi/research/Anairiats/src/ats_dynexp2_dmac.dats: 4089(line=148, offs=23) -- 4126(line=148, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; // ATSlocal_void (tmp35) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac: tmp33 = atspre_stderr_get () ; tmp34 = ats_selsin_mac(tmp33, atslab_1) ; /* tmp35 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__fprint_d2mac (tmp34, arg0) ; /* tmp32 = */ atspre_stderr_view_set () ; return /* (tmp32) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2mac] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_dmac_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_dynexp2_dmac_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_debug_dats.c0000664000175000017500000001000112223166160021175 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ // HX: there is no need for marking static // the variable as it contains no pointer ats_int_type the_debug_flag = 0 ; // ats_int_type atsopt_debug_flag_get () { return the_debug_flag ; } // ats_void_type atsopt_debug_flag_set (ats_int_type i) { the_debug_flag = i ; return ; } // end of [atsopt_debug_flag_set] // HX: there is no need for marking static // the variable as it contains no pointer ats_int_type the_gline_flag = 0 ; // ats_int_type atsopt_gline_flag_get () { return the_gline_flag ; } // ats_void_type atsopt_gline_flag_set (ats_int_type i) { the_gline_flag = i ; return ; } // end of [atsopt_gline_flag_set] ats_void_type atsopt_debug_vfprintf ( ats_ptr_type out , ats_ptr_type fmt , va_list ap // variadic arguments ) { // if (!the_debug_flag) return ; // (void)vfprintf((FILE*)out, (char*)fmt, ap) ; // return ; } // end of [atsopt_debug_printf] ats_void_type atsopt_debug_printf ( ats_ptr_type fmt, ... ) { va_list ap ; va_start(ap, fmt) ; atsopt_debug_vfprintf(stdout, (char*)fmt, ap) ; va_end(ap) ; return ; } // end of [atsopt_debug_printf] ats_void_type atsopt_debug_prerrf ( ats_ptr_type fmt, ... ) { va_list ap ; va_start(ap, fmt) ; atsopt_debug_vfprintf(stderr, (char*)fmt, ap) ; va_end(ap) ; return ; } // end of [atsopt_debug_prerrf] /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ /* external dynamic constant declarations */ /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK /* empty */ #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* static load function */ ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__staload_flag = 1 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_debug_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_hiexp_sats.c0000664000175000017500000004304712223166160021263 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_hityp_name ; ats_ptr_type atslab_hityp_node ; } anairiats_rec_0 ; /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITcltype_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITs2var_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyarr_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrec_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrectemp_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrecsin_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysum_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysumtemp_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITunion_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TMPVAROPTsome_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TMPVAROPTnone_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPfloat_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPlst_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILlab_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILind_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEapp_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrinit_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrpsz_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_ptr_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_var_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcaseof_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcastfn_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcstsp_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEdynload_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEextval_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloatsp_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfreeat_18) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEif_19) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEintsp_21) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_delay_24) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_ldelay_25) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_force_26) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElet_27) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloop_28) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloopexn_29) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_ptr_31) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_var_32) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEraise_33) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErefarg_35) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_36) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_ptr_37) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_var_38) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsif_40) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsizeof_41) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtrywith_46) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlist_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDsaspdec_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdcstdec_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdatdec_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDexndec_4) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextype_5) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextval_6) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextern_7) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDfundecs_8) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_9) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_par_10) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_rec_11) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvardecs_12) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_13) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_prf_14) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlocal_15) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDstaload_16) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdynload_17) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYrec_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYsum_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYuni_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITNAM_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHITYPLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITcltype_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITextype_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITfun_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITrefarg_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITs2var_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyarr_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrec_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrectemp_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtyrecsin_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysum_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITtysumtemp_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITunion_11.tag = 11 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HITvararg_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TMPVAROPTsome_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TMPVAROPTnone_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTdot_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIPATLSTnil_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPann_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPany_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPas_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPbool_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPchar_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPcon_any_6.tag = 6 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPempty_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPfloat_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPint_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPlst_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPrec_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPstring_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIPvar_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILlab_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HILind_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABHIEXPLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEapp_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrinit_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEarrpsz_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_ptr_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEassgn_var_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEbool_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcaseof_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcastfn_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEchar_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcon_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcst_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEcstsp_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEdynload_12.tag = 12 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEempty_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEextval_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfix_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloat_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfloatsp_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEfreeat_18.tag = 18 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEif_19.tag = 19 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEint_20.tag = 20 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEintsp_21.tag = 21 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElam_22.tag = 22 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElaminit_23.tag = 23 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_delay_24.tag = 24 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_ldelay_25.tag = 25 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElazy_force_26.tag = 26 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElet_27.tag = 27 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloop_28.tag = 28 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEloopexn_29.tag = 29 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIElst_30.tag = 30 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_ptr_31.tag = 31 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEptrof_var_32.tag = 32 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEraise_33.tag = 33 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErec_34.tag = 34 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIErefarg_35.tag = 35 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_36.tag = 36 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_ptr_37.tag = 37 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsel_var_38.tag = 38 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEseq_39.tag = 39 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsif_40.tag = 40 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEsizeof_41.tag = 41 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEstring_42.tag = 42 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpcst_43.tag = 43 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtmpvar_44.tag = 44 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtop_45.tag = 45 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEtrywith_46.tag = 46 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIEvar_47.tag = 47 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlist_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDsaspdec_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdcstdec_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdatdec_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDexndec_4.tag = 4 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextype_5.tag = 5 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextval_6.tag = 6 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDextern_7.tag = 7 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDfundecs_8.tag = 8 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_9.tag = 9 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_par_10.tag = 10 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvaldecs_rec_11.tag = 11 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDvardecs_12.tag = 12 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_13.tag = 13 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDimpdec_prf_14.tag = 14 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDlocal_15.tag = 15 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDstaload_16.tag = 16 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__HIDdynload_17.tag = 17 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__LABSTRLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYrec_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYsum_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__TYPKEYuni_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_hiexp_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_patcst2_dats.c0000664000175000017500000034223712223166160021512 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_intinf.cats" /* type definitions */ typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_3 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_5 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_int_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_8 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_10 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { ats_ptr_type atslab_c2lau_loc ; ats_ptr_type atslab_c2lau_pat ; ats_ptr_type atslab_c2lau_gua ; ats_int_type atslab_c2lau_seq ; ats_int_type atslab_c2lau_neg ; ats_ptr_type atslab_c2lau_exp ; } anairiats_rec_13 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__D2CONLSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__LABP2ATLSTcons_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tbool_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tchar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tcon_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tempty_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Texist_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tfloat_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tint_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tlst_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Trec_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tstring_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvar_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__P2Tvbox_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCbool_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCchar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCcon_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCempty_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCfloat_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCint_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCintc_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCrec_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCstring_9) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert_errmsg) (ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_newline) (ats_ref_type) ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_neg_bool) (ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_eq_bool_bool) (ats_bool_type, ats_bool_type) ; ATSextern_fun(ats_bool_type, atspre_eq_char_char) (ats_char_type, ats_char_type) ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprintf_exn) (ats_ref_type, ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_bool_type, atsopt_lt_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_eq_intinf_intinf) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_labp2atcstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference) (ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__sasp__intinfset_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_interror_0 () ; static ats_ptr_type intinfset_add_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) ; static ats_ptr_type intinfset_sing_3 (ats_ptr_type arg0) ; static ats_ptr_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type p2atcst_lst_4 (ats_ptr_type arg0) ; static ats_ptr_type labp2atcstlst_of_labp2atlst_6 (ats_ptr_type arg0) ; static ats_void_type aux_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_intinfset_9 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_15 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_19 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux1_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux2_27 (ats_int_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_25 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_25_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type p2atcst_con_complement_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_29 (ats_ptr_type arg0) ; static ats_ptr_type __ats_fun_30 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_30_closure_make (ats_int_type env0) ; static ats_ptr_type __ats_fun_30_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_32 (ats_ptr_type arg0) ; static ats_ptr_type aux_33 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_33_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_33_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_34 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_34_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_36 (ats_ptr_type arg0) ; static ats_ptr_type aux_37 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_37_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_37_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_38 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_40 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux_42 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux_43 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_47 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type __ats_fun_48 (ats_int_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_48_closure_make (ats_int_type env0) ; static ats_ptr_type __ats_fun_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_50 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_50_closure_make (ats_ptr_type env0) ; static ats_ptr_type aux_50_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_51 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_51_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_53 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_53_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_53_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_ptr_type aux_54 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_54_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) ; static ats_ptr_type aux_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 2232(line=80, offs=4) -- 2288(line=80, offs=60) */ ATSstaticdec() ats_void_type prerr_interror_0 () { /* local vardec */ // ATSlocal_void (tmp0) ; __ats_lab_prerr_interror_0: /* tmp0 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_patcst2)")) ; return /* (tmp0) */ ; } /* end of [prerr_interror_0] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 2403(line=86, offs=34) -- 2412(line=86, offs=43) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__intinflst_of_intinfset (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__intinflst_of_intinfset: tmp1 = arg0 ; return (tmp1) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__intinflst_of_intinfset] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 2418(line=88, offs=5) -- 2728(line=98, offs=32) */ ATSstaticdec() ats_ptr_type intinfset_add_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ref_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; ATSlocal (ats_ptr_type, tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_bool_type, tmp7) ; ATSlocal (ats_ptr_type, tmp8) ; __ats_lab_intinfset_add_2: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp3 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp4 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp5 = atsopt_lt_intinf_intinf (tmp3, arg1) ; if (tmp5) { tmp6 = intinfset_add_2 (tmp4, arg1, arg2) ; tmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_0, tmp3) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_1, tmp6) ; } else { tmp7 = atsopt_lt_intinf_intinf (arg1, tmp3) ; if (tmp7) { tmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_1, arg0) ; } else { ats_ptrget_mac(ats_int_type, arg2) = 1 ; tmp2 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: tmp8 = (ats_sum_ptr_type)0 ; tmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_0, tmp2, atslab_1, tmp8) ; break ; } while (0) ; return (tmp2) ; } /* end of [intinfset_add_2] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 2776(line=101, offs=5) -- 2836(line=101, offs=65) */ ATSstaticdec() ats_ptr_type intinfset_sing_3 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp9) ; ATSlocal (ats_ptr_type, tmp10) ; __ats_lab_intinfset_sing_3: tmp10 = (ats_sum_ptr_type)0 ; tmp9 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp9, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp9, atslab_1, tmp10) ; return (tmp9) ; } /* end of [intinfset_sing_3] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 3028(line=111, offs=7) -- 3316(line=119, offs=39) */ ATSstaticdec() ats_ptr_type aux_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; __ats_lab_aux_5: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp13 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp14 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp15 = aux_5 (arg0, arg1, tmp14) ; tmp16 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp16, atslab_0, tmp13) ; tmp17 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp16), atslab_1) ; tmp18 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp18, atslab_0, tmp15) ; ats_ptrget_mac(ats_ptr_type, tmp17) = tmp18 ; tmp17 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp18), atslab_1) ; tmp18 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp17) = tmp18 ; tmp12 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp12)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp12, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp12, atslab_1, tmp16) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: tmp19 = (ats_sum_ptr_type)0 ; tmp12 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp12)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp12, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_1, tmp12, atslab_1, tmp19) ; break ; } while (0) ; return (tmp12) ; } /* end of [aux_5] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 2862(line=105, offs=4) -- 3585(line=130, offs=4) */ ATSstaticdec() ats_ptr_type p2atcst_lst_4 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_p2atcst_lst_4: tmp20 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_nil) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__d2conref_con_get (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__List_cons) ; tmp11 = aux_5 (tmp21, tmp20, arg0) ; return (tmp11) ; } /* end of [p2atcst_lst_4] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 3615(line=132, offs=5) -- 3914(line=140, offs=29) */ ATSstaticdec() ats_ptr_type labp2atcstlst_of_labp2atlst_6 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_labp2atcstlst_of_labp2atlst_6: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp23 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_0) ; tmp24 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_1) ; tmp25 = ats_caselptrlab_mac(anairiats_sum_2, arg0, atslab_2) ; tmp26 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at (tmp24) ; tmp27 = labp2atcstlst_of_labp2atlst_6 (tmp25) ; tmp22 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp22, atslab_0, tmp23) ; ats_selptrset_mac(anairiats_sum_3, tmp22, atslab_1, tmp26) ; ats_selptrset_mac(anairiats_sum_3, tmp22, atslab_2, tmp27) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: __ats_lab_5_1: tmp22 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp22) ; } /* end of [labp2atcstlst_of_labp2atlst_6] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 3942(line=143, offs=17) -- 4882(line=169, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_bool_type, tmp32) ; ATSlocal (ats_char_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; // ATSlocal_void (tmp40) ; // ATSlocal_void (tmp41) ; // ATSlocal_void (tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_int_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at: tmp29 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_4, arg0), atslab_p2at_node) ; do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp29)->tag != 0) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp30 = ats_caselptrlab_mac(anairiats_sum_1, tmp29, atslab_0) ; arg0 = tmp30 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at ; // tail call break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp29)->tag != 1) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp28 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp29)->tag != 2) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp31 = ats_caselptrlab_mac(anairiats_sum_5, tmp29, atslab_2) ; arg0 = tmp31 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at ; // tail call break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: if (((ats_sum_ptr_type)tmp29)->tag != 3) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_6, tmp29, atslab_0) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp28)->tag = 1 ; ats_selptrset_mac(anairiats_sum_6, tmp28, atslab_0, tmp32) ; break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp29)->tag != 4) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_7, tmp29, atslab_0) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp28)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp28, atslab_0, tmp33) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp29)->tag != 5) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp34 = ats_caselptrlab_mac(anairiats_sum_8, tmp29, atslab_1) ; tmp35 = ats_caselptrlab_mac(anairiats_sum_8, tmp29, atslab_5) ; tmp36 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp35) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp28)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_0, tmp34) ; ats_selptrset_mac(anairiats_sum_1, tmp28, atslab_1, tmp36) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp29)->tag != 6) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp28 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCempty_4) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp29)->tag != 7) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp37 = ats_caselptrlab_mac(anairiats_sum_1, tmp29, atslab_1) ; arg0 = tmp37 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp29)->tag != 8) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_9, tmp29, atslab_0) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp28)->tag = 5 ; ats_selptrset_mac(anairiats_sum_9, tmp28, atslab_0, tmp38) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp29)->tag != 9) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp39 = ats_caselptrlab_mac(anairiats_sum_1, tmp29, atslab_1) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp28)->tag = 6 ; ats_selptrset_mac(anairiats_sum_9, tmp28, atslab_0, tmp39) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: if (((ats_sum_ptr_type)tmp29)->tag != 10) { goto __ats_lab_17_0 ; } __ats_lab_16_1: /* tmp40 = */ prerr_interror_0 () ; /* tmp41 = */ atspre_prerr_string (ATSstrcst(": p2atcst_of_p2at: p2t0 = ")) ; /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_p2at (arg0) ; /* tmp43 = */ atspre_prerr_newline () ; /* tmp28 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: if (((ats_sum_ptr_type)tmp29)->tag != 11) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_9, tmp29, atslab_0) ; tmp45 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp44) ; tmp28 = p2atcst_lst_4 (tmp45) ; break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp29)->tag != 12) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp46 = ats_caselptrlab_mac(anairiats_sum_10, tmp29, atslab_0) ; tmp47 = ats_caselptrlab_mac(anairiats_sum_10, tmp29, atslab_2) ; tmp48 = labp2atcstlst_of_labp2atlst_6 (tmp47) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp28)->tag = 8 ; ats_selptrset_mac(anairiats_sum_11, tmp28, atslab_0, tmp46) ; ats_selptrset_mac(anairiats_sum_11, tmp28, atslab_1, tmp48) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: if (((ats_sum_ptr_type)tmp29)->tag != 13) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp49 = ats_caselptrlab_mac(anairiats_sum_9, tmp29, atslab_0) ; tmp28 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp28)->tag = 9 ; ats_selptrset_mac(anairiats_sum_9, tmp28, atslab_0, tmp49) ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (((ats_sum_ptr_type)tmp29)->tag != 14) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp28 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (((ats_sum_ptr_type)tmp29)->tag != 15) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp28 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; break ; } while (0) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 4944(line=172, offs=23) -- 5103(line=176, offs=21) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp50) ; ATSlocal (ats_ptr_type, tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp51 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp52 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp53 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_of_p2at (tmp51) ; tmp54 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp52) ; tmp50 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp50, atslab_0, tmp53) ; ats_selptrset_mac(anairiats_sum_0, tmp50, atslab_1, tmp54) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_23_1: tmp50 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp50) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 5293(line=184, offs=7) -- 5575(line=191, offs=6) */ ATSstaticdec() ats_void_type aux_10 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp56) ; ATSlocal (ats_ptr_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; // ATSlocal_void (tmp59) ; ATSlocal (ats_bool_type, tmp60) ; // ATSlocal_void (tmp61) ; ATSlocal (ats_int_type, tmp62) ; __ats_lab_aux_10: do { /* branch: __ats_lab_24 */ __ats_lab_24_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp57 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp58 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp60 = atspre_gt_int_int (arg1, 0) ; if (tmp60) { /* tmp59 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp57) ; tmp62 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp62 ; arg2 = tmp58 ; goto __ats_lab_aux_10 ; // tail call break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: break ; } while (0) ; return /* (tmp56) */ ; } /* end of [aux_10] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 5180(line=181, offs=5) -- 5617(line=194, offs=4) */ ATSstaticdec() ats_void_type fprint_intinfset_9 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp55) ; __ats_lab_fprint_intinfset_9: /* tmp55 = */ aux_10 (arg0, 0, arg1) ; return /* (tmp55) */ ; } /* end of [fprint_intinfset_9] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 5673(line=197, offs=16) -- 6824(line=233, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp63) ; ATSlocal (ats_bool_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_char_type, tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; // ATSlocal_void (tmp70) ; // ATSlocal_void (tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; // ATSlocal_void (tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_int_type, tmp77) ; ATSlocal (ats_ptr_type, tmp78) ; // ATSlocal_void (tmp79) ; ATSlocal (ats_bool_type, tmp80) ; // ATSlocal_void (tmp81) ; // ATSlocal_void (tmp82) ; ATSlocal (ats_ptr_type, tmp83) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst: do { /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_27_0 ; } __ats_lab_26_1: /* tmp63 = */ atspre_fprint_char (arg0, '_') ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp64 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; if (tmp64) { tmp65 = ATSstrcst("true") ; } else { tmp65 = ATSstrcst("false") ; } /* end of [if] */ /* tmp63 = */ atspre_fprint_string (arg0, tmp65) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_29_0 ; } __ats_lab_28_1: tmp66 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; /* tmp63 = */ atspre_fprintf_exn (arg0, ATSstrcst("'%c'"), tmp66) ; break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_d2con (arg0, tmp67) ; /* tmp70 = */ atspre_fprint_string (arg0, ATSstrcst("(")) ; /* tmp71 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst (arg0, tmp68) ; /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_31_0 ; } __ats_lab_30_1: /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("()")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp72 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp63 = */ atspre_fprint_string (arg0, tmp72) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp73 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp63 = */ ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__fprint_intinf (arg0, tmp73) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_34_0 ; } __ats_lab_33_1: tmp74 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp75 = */ atspre_fprint_string (arg0, ATSstrcst("[^")) ; /* tmp76 = */ fprint_intinfset_9 (arg0, tmp74) ; /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("]")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp77 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp78 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp80 = atspre_gt_int_int (tmp77, 0) ; if (tmp80) { /* tmp79 = */ atspre_fprint_char (arg0, '\'') ; } else { /* tmp79 = */ atspre_fprint_char (arg0, '@') ; } /* end of [if] */ /* tmp81 = */ atspre_fprint_string (arg0, ATSstrcst("{")) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_labp2atcstlst (arg0, tmp78) ; /* tmp63 = */ atspre_fprint_string (arg0, ATSstrcst("}")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (((ats_sum_ptr_type)arg1)->tag != 9) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp83 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* tmp63 = */ atspre_fprintf_exn (arg0, ATSstrcst("\"%s\""), tmp83) ; break ; } while (0) ; return /* (tmp63) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 6877(line=236, offs=15) -- 6918(line=236, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; ATSlocal (ats_ptr_type, tmp86) ; // ATSlocal_void (tmp87) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcst: tmp85 = atspre_stdout_get () ; tmp86 = ats_selsin_mac(tmp85, atslab_1) ; /* tmp87 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst (tmp86, arg0) ; /* tmp84 = */ atspre_stdout_view_set () ; return /* (tmp84) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 6943(line=238, offs=15) -- 6984(line=238, offs=56) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcst: tmp89 = atspre_stderr_get () ; tmp90 = ats_selsin_mac(tmp89, atslab_1) ; /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst (tmp90, arg0) ; /* tmp88 = */ atspre_stderr_view_set () ; return /* (tmp88) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7071(line=245, offs=7) -- 7333(line=253, offs=19) */ ATSstaticdec() ats_void_type aux_15 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_bool_type, tmp97) ; // ATSlocal_void (tmp98) ; ATSlocal (ats_int_type, tmp99) ; __ats_lab_aux_15: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp95 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp97 = atspre_gt_int_int (arg1, 0) ; if (tmp97) { /* tmp96 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst (arg0, tmp94) ; tmp99 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp99 ; arg2 = tmp95 ; goto __ats_lab_aux_15 ; // tail call break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_37_1: break ; } while (0) ; return /* (tmp93) */ ; } /* end of [aux_15] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7041(line=244, offs=7) -- 7380(line=257, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp92) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst: /* tmp92 = */ aux_15 (arg0, 0, arg1) ; return /* (tmp92) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7439(line=259, offs=28) -- 7485(line=259, offs=74) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; // ATSlocal_void (tmp103) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlst: tmp101 = atspre_stdout_get () ; tmp102 = ats_selsin_mac(tmp101, atslab_1) ; /* tmp103 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst (tmp102, arg0) ; /* tmp100 = */ atspre_stdout_view_set () ; return /* (tmp100) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7513(line=260, offs=28) -- 7559(line=260, offs=74) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlst: tmp105 = atspre_stderr_get () ; tmp106 = ats_selsin_mac(tmp105, atslab_1) ; /* tmp107 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst (tmp106, arg0) ; /* tmp104 = */ atspre_stderr_view_set () ; return /* (tmp104) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7650(line=267, offs=7) -- 8027(line=277, offs=32) */ ATSstaticdec() ats_void_type aux_19 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; // ATSlocal_void (tmp113) ; ATSlocal (ats_bool_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; ATSlocal (ats_int_type, tmp118) ; __ats_lab_aux_19: do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp111 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp112 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_2) ; tmp114 = atspre_gt_int_int (arg1, 0) ; if (tmp114) { /* tmp113 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp115 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp110) ; /* tmp116 = */ atspre_fprint_string (arg0, ATSstrcst("= ")) ; /* tmp117 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcst (arg0, tmp111) ; tmp118 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp118 ; arg2 = tmp112 ; goto __ats_lab_aux_19 ; // tail call break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_39_1: break ; } while (0) ; return /* (tmp109) */ ; } /* end of [aux_19] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 7619(line=266, offs=7) -- 8075(line=281, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_labp2atcstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp108) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_labp2atcstlst: /* tmp108 = */ aux_19 (arg0, 0, arg1) ; return /* (tmp108) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_labp2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8199(line=288, offs=7) -- 8488(line=298, offs=19) */ ATSstaticdec() ats_void_type aux_21 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp120) ; ATSlocal (ats_ptr_type, tmp121) ; ATSlocal (ats_ptr_type, tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; __ats_lab_aux_21: do { /* branch: __ats_lab_40 */ __ats_lab_40_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp121 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp122 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; /* tmp123 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlst (arg0, tmp121) ; /* tmp124 = */ atspre_fprint_newline (arg0) ; arg0 = arg0 ; arg1 = tmp122 ; goto __ats_lab_aux_21 ; // tail call break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_41_1: break ; } while (0) ; return /* (tmp120) */ ; } /* end of [aux_21] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8168(line=287, offs=7) -- 8549(line=302, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp119) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst: /* tmp119 = */ aux_21 (arg0, arg1) ; return /* (tmp119) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8614(line=305, offs=21) -- 8665(line=305, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; // ATSlocal_void (tmp128) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlstlst: tmp126 = atspre_stdout_get () ; tmp127 = ats_selsin_mac(tmp126, atslab_1) ; /* tmp128 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst (tmp127, arg0) ; /* tmp125 = */ atspre_stdout_view_set () ; return /* (tmp125) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__print_p2atcstlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8696(line=307, offs=21) -- 8747(line=307, offs=72) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlstlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; // ATSlocal_void (tmp132) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlstlst: tmp130 = atspre_stderr_get () ; tmp131 = ats_selsin_mac(tmp130, atslab_1) ; /* tmp132 = */ ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__fprint_p2atcstlstlst (tmp131, arg0) ; /* tmp129 = */ atspre_stderr_view_set () ; return /* (tmp129) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__prerr_p2atcstlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 9136(line=320, offs=17) -- 9430(line=326, offs=30) */ ATSstaticdec() ats_ptr_type aux1_26 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_ptr_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; __ats_lab_aux1_26: do { /* branch: __ats_lab_43 */ __ats_lab_43_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp139 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp140 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp142 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp142)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp142, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp142, atslab_1, tmp139) ; tmp141 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp141, atslab_0, tmp142) ; ats_selptrset_mac(anairiats_sum_0, tmp141, atslab_1, arg2) ; arg0 = arg0 ; arg1 = tmp140 ; arg2 = tmp141 ; goto __ats_lab_aux1_26 ; // tail call break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp138 = arg2 ; break ; } while (0) ; return (tmp138) ; } /* end of [aux1_26] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 9618(line=333, offs=17) -- 9748(line=335, offs=23) */ ATSstaticdec() ats_ptr_type aux2_27 (ats_int_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp145) ; ATSlocal (ats_bool_type, tmp146) ; ATSlocal (ats_int_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_ptr_type, tmp149) ; __ats_lab_aux2_27: tmp146 = atspre_gt_int_int (arg0, 0) ; if (tmp146) { tmp147 = atspre_sub_int_int (arg0, 1) ; tmp149 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp148 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp148, atslab_0, tmp149) ; ats_selptrset_mac(anairiats_sum_0, tmp148, atslab_1, arg1) ; arg0 = tmp147 ; arg1 = tmp148 ; goto __ats_lab_aux2_27 ; // tail call } else { tmp145 = arg1 ; } /* end of [if] */ return (tmp145) ; } /* end of [aux2_27] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8876(line=314, offs=7) -- 9989(line=343, offs=6) */ ATSstaticdec() ats_ptr_type aux_25 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; ATSlocal (ats_ptr_type, tmp136) ; ATSlocal (ats_bool_type, tmp137) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_ptr_type, tmp144) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_int_type, tmp151) ; ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (ats_ptr_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; __ats_lab_aux_25: do { /* branch: __ats_lab_42 */ __ats_lab_42_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_45_0 ; } __ats_lab_42_1: tmp135 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp136 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp137 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (env0, tmp135) ; if (tmp137) { tmp144 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (env1) ; tmp143 = aux1_26 (tmp135, tmp144, arg1) ; arg0 = tmp136 ; arg1 = tmp143 ; goto __ats_lab_aux_25 ; // tail call } else { tmp151 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_arity_full (tmp135) ; tmp152 = (ats_sum_ptr_type)0 ; tmp150 = aux2_27 (tmp151, tmp152) ; tmp154 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp154)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp154, atslab_0, tmp135) ; ats_selptrset_mac(anairiats_sum_1, tmp154, atslab_1, tmp150) ; tmp153 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp153, atslab_0, tmp154) ; ats_selptrset_mac(anairiats_sum_0, tmp153, atslab_1, arg1) ; arg0 = tmp136 ; arg1 = tmp153 ; goto __ats_lab_aux_25 ; // tail call } /* end of [if] */ break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp134 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg1) ; break ; } while (0) ; return (tmp134) ; } /* end of [aux_25] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_25_closure_type ; ats_ptr_type aux_25_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_25 (((aux_25_closure_type*)cloptr)->closure_env_0, ((aux_25_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_25_closure_init (aux_25_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_25_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_25_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_25_closure_type *p_clo = ATS_MALLOC(sizeof(aux_25_closure_type)) ; aux_25_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 8773(line=311, offs=4) -- 10041(line=346, offs=4) */ ATSstaticdec() ats_ptr_type p2atcst_con_complement_24 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp133) ; ATSlocal (ats_ptr_type, tmp155) ; __ats_lab_p2atcst_con_complement_24: tmp155 = (ats_sum_ptr_type)0 ; tmp133 = aux_25 (arg0, arg2, arg1, tmp155) ; return (tmp133) ; } /* end of [p2atcst_con_complement_24] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 11162(line=375, offs=11) -- 11276(line=376, offs=65) */ ATSstaticdec() ats_ptr_type aux_29 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; __ats_lab_aux_29: do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp185 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp186 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp187 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp187)->tag = 6 ; ats_selptrset_mac(anairiats_sum_9, tmp187, atslab_0, tmp185) ; tmp188 = aux_29 (tmp186) ; tmp184 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp184, atslab_0, tmp187) ; ats_selptrset_mac(anairiats_sum_0, tmp184, atslab_1, tmp188) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_57_1: tmp184 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp184) ; } /* end of [aux_29] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 11430(line=381, offs=38) -- 11472(line=381, offs=80) */ ATSstaticdec() ats_ptr_type __ats_fun_30 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp193) ; __ats_lab___ats_fun_30: tmp193 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp193)->tag = 8 ; ats_selptrset_mac(anairiats_sum_11, tmp193, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_11, tmp193, atslab_1, arg0) ; return (tmp193) ; } /* end of [__ats_fun_30] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } __ats_fun_30_closure_type ; ats_ptr_type __ats_fun_30_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_30 (((__ats_fun_30_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_30_closure_init (__ats_fun_30_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_30_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_30_closure_make (ats_int_type env0) { __ats_fun_30_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_30_closure_type)) ; __ats_fun_30_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 10107(line=349, offs=20) -- 11734(line=391, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_bool_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_bool_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_ptr_type, tmp164) ; ATSlocal (ats_int_type, tmp165) ; ATSlocal (ats_bool_type, tmp166) ; ATSlocal (ats_ptr_type, tmp167) ; ATSlocal (ats_ptr_type, tmp168) ; ATSlocal (ats_ptr_type, tmp169) ; ATSlocal (ats_ptr_type, tmp170) ; // ATSlocal_void (tmp171) ; // ATSlocal_void (tmp172) ; // ATSlocal_void (tmp173) ; // ATSlocal_void (tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_ptr_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (ats_ptr_type, tmp183) ; ATSlocal (ats_int_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_ptr_type, tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp156 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp157 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp159 = atspre_neg_bool (tmp157) ; tmp158 = ATS_MALLOC(sizeof(anairiats_sum_6)) ; ((ats_sum_ptr_type)tmp158)->tag = 1 ; ats_selptrset_mac(anairiats_sum_6, tmp158, atslab_0, tmp159) ; tmp160 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp158) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp160) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp161 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp162 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp161) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp162) ; break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_52_0 ; } __ats_lab_49_1: tmp163 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp164 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp165 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_tag (tmp163) ; tmp166 = atspre_gte_int_int (tmp165, 0) ; if (tmp166) { tmp167 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__d2con_get_scst (tmp163) ; tmp169 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_get_conlst (tmp167) ; do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (tmp169 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp170 = ats_caselptrlab_mac(anairiats_sum_12, tmp169, atslab_0) ; tmp168 = tmp170 ; break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (tmp169 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: /* tmp171 = */ prerr_interror_0 () ; /* tmp172 = */ atspre_prerr_string (ATSstrcst(": p2atcst_complement: s2c0 = ")) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2cst (tmp167) ; /* tmp174 = */ atspre_prerr_newline () ; /* tmp168 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp156 = p2atcst_con_complement_24 (tmp163, tmp168, tmp164) ; } else { tmp175 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp176 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp175) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp176) ; } /* end of [if] */ break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp156 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: if (((ats_sum_ptr_type)arg0)->tag != 5) { goto __ats_lab_54_0 ; } __ats_lab_53_1: tmp177 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp178 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp177) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp178) ; break ; /* branch: __ats_lab_54 */ __ats_lab_54_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp179 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp181 = intinfset_sing_3 (tmp179) ; tmp180 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp180)->tag = 7 ; ats_selptrset_mac(anairiats_sum_9, tmp180, atslab_0, tmp181) ; tmp182 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp180) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp182) ; break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_58_0 ; } __ats_lab_55_1: tmp183 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp156 = aux_29 (tmp183) ; break ; /* branch: __ats_lab_58 */ __ats_lab_58_0: if (((ats_sum_ptr_type)arg0)->tag != 8) { goto __ats_lab_59_0 ; } __ats_lab_58_1: tmp189 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp190 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp191 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement (tmp190) ; /* ats_ptr_type tmp192 ; */ tmp192 = __ats_fun_30_closure_make (tmp189) ; tmp156 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (tmp191, tmp192) ; ATS_FREE(tmp192) ; break ; /* branch: __ats_lab_59 */ __ats_lab_59_0: // if (((ats_sum_ptr_type)arg0)->tag != 9) { ats_deadcode_failure_handle () ; } __ats_lab_59_1: tmp194 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp195 = (ats_sum_ptr_type)0 ; tmp156 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_0, tmp194) ; ats_selptrset_mac(anairiats_sum_0, tmp156, atslab_1, tmp195) ; break ; } while (0) ; return (tmp156) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 11919(line=398, offs=13) -- 12067(line=400, offs=74) */ ATSstaticdec() ats_ptr_type aux_32 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; __ats_lab_aux_32: do { /* branch: __ats_lab_61 */ __ats_lab_61_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_61_1: tmp200 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp201 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp202 = aux_32 (tmp200) ; tmp199 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_0, tmp201) ; ats_selptrset_mac(anairiats_sum_0, tmp199, atslab_1, tmp202) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: tmp199 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp199) ; } /* end of [aux_32] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 12168(line=403, offs=13) -- 12367(line=407, offs=29) */ ATSstaticdec() ats_ptr_type aux_33 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_ptr_type, tmp206) ; ATSlocal (ats_ptr_type, tmp207) ; ATSlocal (ats_ptr_type, tmp208) ; __ats_lab_aux_33: do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_64_0 ; } __ats_lab_63_1: tmp205 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp206 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp207 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp207, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_0, tmp207, atslab_1, tmp205) ; tmp208 = aux_33 (env0, tmp206) ; tmp204 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp204, atslab_0, tmp207) ; ats_selptrset_mac(anairiats_sum_0, tmp204, atslab_1, tmp208) ; break ; /* branch: __ats_lab_64 */ __ats_lab_64_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_64_1: tmp204 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp204) ; } /* end of [aux_33] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_33_closure_type ; ats_ptr_type aux_33_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_33 (((aux_33_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_33_closure_init (aux_33_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_33_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_33_closure_make (ats_ptr_type env0) { aux_33_closure_type *p_clo = ATS_MALLOC(sizeof(aux_33_closure_type)) ; aux_33_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 12464(line=410, offs=13) -- 12631(line=413, offs=27) */ ATSstaticdec() ats_ptr_type aux_34 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_aux_34: do { /* branch: __ats_lab_65 */ __ats_lab_65_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_65_1: tmp212 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp213 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp214 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp214, atslab_0, tmp212) ; ats_selptrset_mac(anairiats_sum_0, tmp214, atslab_1, env0) ; tmp215 = aux_34 (env0, env1, tmp213) ; tmp211 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp211, atslab_0, tmp214) ; ats_selptrset_mac(anairiats_sum_0, tmp211, atslab_1, tmp215) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: tmp211 = env1 ; break ; } while (0) ; return (tmp211) ; } /* end of [aux_34] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_34_closure_type ; ats_ptr_type aux_34_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_34 (((aux_34_closure_type*)cloptr)->closure_env_0, ((aux_34_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_34_closure_init (aux_34_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_34_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_34_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_34_closure_type *p_clo = ATS_MALLOC(sizeof(aux_34_closure_type)) ; aux_34_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 11803(line=394, offs=27) -- 12741(line=419, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; ATSlocal (ats_ptr_type, tmp198) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp209) ; ATSlocal (ats_ptr_type, tmp210) ; ATSlocal (ats_ptr_type, tmp216) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement: do { /* branch: __ats_lab_60 */ __ats_lab_60_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_67_0 ; } __ats_lab_60_1: tmp197 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp198 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp203 = aux_32 (tmp198) ; tmp210 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (tmp198) ; tmp209 = aux_33 (tmp197, tmp210) ; tmp216 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement (tmp197) ; tmp196 = aux_34 (tmp203, tmp209, tmp216) ; break ; /* branch: __ats_lab_67 */ __ats_lab_67_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_67_1: tmp196 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp196) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 12955(line=426, offs=13) -- 13210(line=431, offs=55) */ ATSstaticdec() ats_ptr_type aux_36 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp221) ; ATSlocal (ats_ptr_type, tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; __ats_lab_aux_36: do { /* branch: __ats_lab_69 */ __ats_lab_69_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_69_1: tmp222 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp223 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp224 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp225 = aux_36 (tmp223) ; tmp221 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp221, atslab_0, tmp222) ; ats_selptrset_mac(anairiats_sum_3, tmp221, atslab_1, tmp224) ; ats_selptrset_mac(anairiats_sum_3, tmp221, atslab_2, tmp225) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_70_1: tmp221 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp221) ; } /* end of [aux_36] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 13340(line=435, offs=13) -- 13583(line=440, offs=29) */ ATSstaticdec() ats_ptr_type aux_37 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; ATSlocal (ats_ptr_type, tmp231) ; __ats_lab_aux_37: do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_72_0 ; } __ats_lab_71_1: tmp228 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp229 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp230 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp230, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_3, tmp230, atslab_1, env1) ; ats_selptrset_mac(anairiats_sum_3, tmp230, atslab_2, tmp228) ; tmp231 = aux_37 (env0, env1, tmp229) ; tmp227 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp227, atslab_0, tmp230) ; ats_selptrset_mac(anairiats_sum_0, tmp227, atslab_1, tmp231) ; break ; /* branch: __ats_lab_72 */ __ats_lab_72_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_72_1: tmp227 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp227) ; } /* end of [aux_37] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_37_closure_type ; ats_ptr_type aux_37_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_37 (((aux_37_closure_type*)cloptr)->closure_env_0, ((aux_37_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_37_closure_init (aux_37_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_37_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_37_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_37_closure_type *p_clo = ATS_MALLOC(sizeof(aux_37_closure_type)) ; aux_37_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 13705(line=444, offs=13) -- 13932(line=449, offs=28) */ ATSstaticdec() ats_ptr_type aux_38 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; __ats_lab_aux_38: do { /* branch: __ats_lab_73 */ __ats_lab_73_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp235 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp236 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp237 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp237, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_3, tmp237, atslab_1, tmp235) ; ats_selptrset_mac(anairiats_sum_3, tmp237, atslab_2, env1) ; tmp238 = aux_38 (env0, env1, env2, tmp236) ; tmp234 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp234, atslab_0, tmp237) ; ats_selptrset_mac(anairiats_sum_0, tmp234, atslab_1, tmp238) ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: tmp234 = env2 ; break ; } while (0) ; return (tmp234) ; } /* end of [aux_38] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_38_closure_type ; ats_ptr_type aux_38_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_38 (((aux_38_closure_type*)cloptr)->closure_env_0, ((aux_38_closure_type*)cloptr)->closure_env_1, ((aux_38_closure_type*)cloptr)->closure_env_2, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_38_closure_init (aux_38_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_38_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_38_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_38_closure_type *p_clo = ATS_MALLOC(sizeof(aux_38_closure_type)) ; aux_38_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 12812(line=422, offs=26) -- 14025(line=455, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp232) ; ATSlocal (ats_ptr_type, tmp233) ; ATSlocal (ats_ptr_type, tmp239) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement: do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_68_1: tmp218 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp219 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp220 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp226 = aux_36 (tmp220) ; tmp233 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement (tmp220) ; tmp232 = aux_37 (tmp218, tmp219, tmp233) ; tmp239 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement (tmp219) ; tmp217 = aux_38 (tmp218, tmp226, tmp232, tmp239) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: tmp217 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp217) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_complement] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 14224(line=463, offs=11) -- 14417(line=467, offs=24) */ ATSstaticdec() ats_ptr_type aux_40 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; __ats_lab_aux_40: do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp243 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp245 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; tmp244 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp244, atslab_0, tmp245) ; ats_selptrset_mac(anairiats_sum_0, tmp244, atslab_1, arg1) ; arg0 = tmp243 ; arg1 = tmp244 ; goto __ats_lab_aux_40 ; // tail call break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_78_1: tmp242 = arg1 ; break ; } while (0) ; return (tmp242) ; } /* end of [aux_40] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 14116(line=460, offs=22) -- 14607(line=475, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; ATSlocal (ats_ptr_type, tmp251) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement: tmp241 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_c2lau_gua) ; do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (tmp241 == (ats_sum_ptr_type)0) { goto __ats_lab_79_0 ; } __ats_lab_76_1: tmp247 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_c2lau_pat) ; tmp248 = (ats_sum_ptr_type)0 ; tmp246 = aux_40 (tmp247, tmp248) ; tmp249 = (ats_sum_ptr_type)0 ; tmp240 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp240, atslab_0, tmp246) ; ats_selptrset_mac(anairiats_sum_0, tmp240, atslab_1, tmp249) ; break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (tmp241 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp251 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg0), atslab_c2lau_pat) ; tmp250 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_of_p2atlst (tmp251) ; tmp240 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_complement (tmp250) ; break ; } while (0) ; return (tmp240) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__c2lau_pat_complement] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 15422(line=498, offs=11) -- 15632(line=502, offs=30) */ ATSstaticdec() ats_bool_type aux_42 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_bool_type, tmp272) ; ATSlocal (ats_bool_type, tmp273) ; __ats_lab_aux_42: do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp270 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp271 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp272 = atsopt_lt_intinf_intinf (arg0, tmp270) ; if (tmp272) { tmp269 = ats_true_bool ; } else { tmp273 = atsopt_lt_intinf_intinf (tmp270, arg0) ; if (tmp273) { arg0 = arg0 ; arg1 = tmp271 ; goto __ats_lab_aux_42 ; // tail call } else { tmp269 = ats_false_bool ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_89_1: tmp269 = ats_true_bool ; break ; } while (0) ; return (tmp269) ; } /* end of [aux_42] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 15719(line=505, offs=11) -- 15929(line=509, offs=30) */ ATSstaticdec() ats_bool_type aux_43 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_bool_type, tmp279) ; ATSlocal (ats_bool_type, tmp280) ; __ats_lab_aux_43: do { /* branch: __ats_lab_91 */ __ats_lab_91_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_92_0 ; } __ats_lab_91_1: tmp277 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp278 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp279 = atsopt_lt_intinf_intinf (arg1, tmp277) ; if (tmp279) { tmp276 = ats_true_bool ; } else { tmp280 = atsopt_lt_intinf_intinf (tmp277, arg1) ; if (tmp280) { arg0 = tmp278 ; arg1 = arg1 ; goto __ats_lab_aux_43 ; // tail call } else { tmp276 = ats_false_bool ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_92 */ __ats_lab_92_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_92_1: tmp276 = ats_true_bool ; break ; } while (0) ; return (tmp276) ; } /* end of [aux_43] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 14696(line=480, offs=24) -- 16157(line=516, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp252) ; ATSlocal (ats_bool_type, tmp253) ; ATSlocal (ats_bool_type, tmp254) ; ATSlocal (ats_char_type, tmp255) ; ATSlocal (ats_char_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; ATSlocal (ats_ptr_type, tmp260) ; ATSlocal (ats_bool_type, tmp261) ; ATSlocal (ats_int_type, tmp262) ; // ATSlocal_void (tmp263) ; ATSlocal (ats_bool_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp281) ; ATSlocal (ats_ptr_type, tmp282) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test: do { /* branch: __ats_lab_80 */ __ats_lab_80_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_81_0 ; } __ats_lab_80_1: __ats_lab_80_2: tmp252 = ats_true_bool ; break ; /* branch: __ats_lab_81 */ __ats_lab_81_0: __ats_lab_81_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_82_0 ; } __ats_lab_81_2: tmp252 = ats_true_bool ; break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_83_0 ; } __ats_lab_82_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_95_1 ; } __ats_lab_82_2: tmp253 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp254 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp252 = atspre_eq_bool_bool (tmp253, tmp254) ; break ; /* branch: __ats_lab_83 */ __ats_lab_83_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_84_0 ; } __ats_lab_83_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_95_1 ; } __ats_lab_83_2: tmp255 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp256 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp252 = atspre_eq_char_char (tmp255, tmp256) ; break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_85_0 ; } __ats_lab_84_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_95_1 ; } __ats_lab_84_2: tmp257 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp259 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp260 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp261 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp257, tmp259) ; if (tmp261) { tmp262 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (tmp258, tmp260) ; tmp264 = atspre_ieq (tmp262, 0) ; /* tmp263 = */ atspre_assert_errmsg (tmp264, ATSstrcst("p2atcst_intersect_test")) ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test (tmp258, tmp260) ; } else { tmp252 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_85 */ __ats_lab_85_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_86_0 ; } __ats_lab_85_1: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_95_1 ; } __ats_lab_85_2: tmp252 = ats_true_bool ; break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_87_0 ; } __ats_lab_86_1: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_87_1 ; } __ats_lab_86_2: tmp265 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp266 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp252 = atsopt_eq_intinf_intinf (tmp265, tmp266) ; break ; /* branch: __ats_lab_87 */ __ats_lab_87_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_90_0 ; } __ats_lab_87_1: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_95_1 ; } __ats_lab_87_2: tmp267 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp268 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp252 = aux_42 (tmp267, tmp268) ; break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_93_0 ; } __ats_lab_90_1: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_93_1 ; } __ats_lab_90_2: tmp274 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp252 = aux_43 (tmp274, tmp275) ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_94_0 ; } __ats_lab_93_1: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_95_1 ; } __ats_lab_93_2: tmp252 = ats_true_bool ; break ; /* branch: __ats_lab_94 */ __ats_lab_94_0: if (((ats_sum_ptr_type)arg0)->tag != 8) { goto __ats_lab_95_0 ; } __ats_lab_94_1: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_95_1 ; } __ats_lab_94_2: tmp281 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp282 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp252 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test (tmp281, tmp282) ; break ; /* branch: __ats_lab_95 */ __ats_lab_95_0: __ats_lab_95_1: __ats_lab_95_2: tmp252 = ats_false_bool ; break ; } while (0) ; return (tmp252) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 16235(line=520, offs=3) -- 16514(line=533, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; ATSlocal (ats_ptr_type, tmp287) ; ATSlocal (ats_bool_type, tmp288) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test: do { /* branch: __ats_lab_96 */ __ats_lab_96_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_97_0 ; } __ats_lab_96_1: tmp284 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp285 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp286 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp287 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp288 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test (tmp284, tmp286) ; if (tmp288) { arg0 = tmp285 ; arg1 = tmp287 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test ; // tail call } else { tmp283 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_97 */ __ats_lab_97_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_97_1: tmp283 = ats_true_bool ; break ; } while (0) ; return (tmp283) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_intersect_test] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 16595(line=537, offs=3) -- 16936(line=549, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp289) ; ATSlocal (ats_ptr_type, tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; ATSlocal (ats_ptr_type, tmp293) ; ATSlocal (ats_bool_type, tmp294) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test: do { /* branch: __ats_lab_98 */ __ats_lab_98_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_99_0 ; } __ats_lab_98_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_99_1 ; } __ats_lab_98_2: tmp290 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp291 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp292 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp293 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp294 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_intersect_test (tmp290, tmp292) ; if (tmp294) { arg0 = tmp291 ; arg1 = tmp293 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test ; // tail call } else { tmp289 = ats_false_bool ; } /* end of [if] */ break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: __ats_lab_99_2: tmp289 = ats_true_bool ; break ; } while (0) ; return (tmp289) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_intersect_test] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 17512(line=566, offs=11) -- 17694(line=569, offs=27) */ ATSstaticdec() ats_ptr_type aux_47 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; ATSlocal (ats_ptr_type, tmp311) ; ATSlocal (ats_ptr_type, tmp312) ; ATSlocal (ats_ptr_type, tmp313) ; __ats_lab_aux_47: do { /* branch: __ats_lab_105 */ __ats_lab_105_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_105_1: tmp310 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp311 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp312 = ATS_MALLOC(sizeof(anairiats_sum_1)) ; ((ats_sum_ptr_type)tmp312)->tag = 3 ; ats_selptrset_mac(anairiats_sum_1, tmp312, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_1, tmp312, atslab_1, tmp310) ; tmp313 = aux_47 (arg0, tmp311) ; tmp309 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp309, atslab_0, tmp312) ; ats_selptrset_mac(anairiats_sum_0, tmp309, atslab_1, tmp313) ; break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_106_1: tmp309 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp309) ; } /* end of [aux_47] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 18768(line=596, offs=19) -- 18813(line=596, offs=64) */ ATSstaticdec() ats_ptr_type __ats_fun_48 (ats_int_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp340) ; __ats_lab___ats_fun_48: tmp340 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ((ats_sum_ptr_type)tmp340)->tag = 8 ; ats_selptrset_mac(anairiats_sum_11, tmp340, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_11, tmp340, atslab_1, arg0) ; return (tmp340) ; } /* end of [__ats_fun_48] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_int_type closure_env_0 ; } __ats_fun_48_closure_type ; ats_ptr_type __ats_fun_48_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return __ats_fun_48 (((__ats_fun_48_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type __ats_fun_48_closure_init (__ats_fun_48_closure_type *p_clo, ats_int_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_48_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_48_closure_make (ats_int_type env0) { __ats_fun_48_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_48_closure_type)) ; __ats_fun_48_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 17029(line=554, offs=20) -- 18999(line=602, offs=8) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp295) ; ATSlocal (ats_bool_type, tmp296) ; ATSlocal (ats_bool_type, tmp297) ; ATSlocal (ats_bool_type, tmp298) ; ATSlocal (ats_ptr_type, tmp299) ; ATSlocal (ats_char_type, tmp300) ; ATSlocal (ats_char_type, tmp301) ; ATSlocal (ats_bool_type, tmp302) ; ATSlocal (ats_ptr_type, tmp303) ; ATSlocal (ats_ptr_type, tmp304) ; ATSlocal (ats_ptr_type, tmp305) ; ATSlocal (ats_ptr_type, tmp306) ; ATSlocal (ats_ptr_type, tmp307) ; ATSlocal (ats_bool_type, tmp308) ; ATSlocal (ats_int_type, tmp314) ; // ATSlocal_void (tmp315) ; ATSlocal (ats_bool_type, tmp316) ; ATSlocal (ats_ptr_type, tmp317) ; ATSlocal (ats_ptr_type, tmp318) ; ATSlocal (ats_ptr_type, tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_bool_type, tmp321) ; ATSlocal (ats_ptr_type, tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; ATSlocal (ats_bool_type, tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_int_type, tmp329) ; ATSlocal (ats_ptr_type, tmp330) ; ATSlocal (ats_bool_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; ATSlocal (ats_ptr_type, tmp333) ; ATSlocal (ats_ptr_type, tmp334) ; ATSlocal (ats_int_type, tmp335) ; ATSlocal (ats_ptr_type, tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; // ATSlocal_void (tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference: do { /* branch: __ats_lab_100 */ __ats_lab_100_0: __ats_lab_100_1: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_101_0 ; } __ats_lab_100_2: tmp295 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_102_0 ; } __ats_lab_101_1: __ats_lab_101_2: tmp295 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_complement (arg1) ; break ; /* branch: __ats_lab_102 */ __ats_lab_102_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_103_0 ; } __ats_lab_102_1: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_112_1 ; } __ats_lab_102_2: tmp296 = ats_caselptrlab_mac(anairiats_sum_6, arg0, atslab_0) ; tmp297 = ats_caselptrlab_mac(anairiats_sum_6, arg1, atslab_0) ; tmp298 = atspre_eq_bool_bool (tmp296, tmp297) ; if (tmp298) { tmp295 = (ats_sum_ptr_type)0 ; } else { tmp299 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp299) ; } /* end of [if] */ break ; /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)arg0)->tag != 2) { goto __ats_lab_104_0 ; } __ats_lab_103_1: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_112_1 ; } __ats_lab_103_2: tmp300 = ats_caselptrlab_mac(anairiats_sum_7, arg0, atslab_0) ; tmp301 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp302 = atspre_eq_char_char (tmp300, tmp301) ; if (tmp302) { tmp295 = (ats_sum_ptr_type)0 ; } else { tmp303 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp303) ; } /* end of [if] */ break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)arg0)->tag != 3) { goto __ats_lab_107_0 ; } __ats_lab_104_1: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_112_1 ; } __ats_lab_104_2: tmp304 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_0) ; tmp305 = ats_caselptrlab_mac(anairiats_sum_1, arg0, atslab_1) ; tmp306 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_0) ; tmp307 = ats_caselptrlab_mac(anairiats_sum_1, arg1, atslab_1) ; tmp308 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__eq_d2con_d2con (tmp304, tmp306) ; if (tmp308) { tmp314 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (tmp305, tmp307) ; tmp316 = atspre_ieq (tmp314, 0) ; /* tmp315 = */ atspre_assert_errmsg (tmp316, ATSstrcst("p2atcst_difference: P2TCcon")) ; tmp317 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference (tmp305, tmp307) ; tmp295 = aux_47 (tmp304, tmp317) ; } else { tmp318 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp318) ; } /* end of [if] */ break ; /* branch: __ats_lab_107 */ __ats_lab_107_0: if (((ats_sum_ptr_type)arg0)->tag != 4) { goto __ats_lab_108_0 ; } __ats_lab_107_1: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_112_1 ; } __ats_lab_107_2: tmp295 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_sum_ptr_type)arg0)->tag != 6) { goto __ats_lab_109_0 ; } __ats_lab_108_1: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_112_1 ; } __ats_lab_108_2: tmp319 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp320 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp321 = atsopt_eq_intinf_intinf (tmp319, tmp320) ; if (tmp321) { tmp295 = (ats_sum_ptr_type)0 ; } else { tmp322 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp322) ; } /* end of [if] */ break ; /* branch: __ats_lab_109 */ __ats_lab_109_0: if (((ats_sum_ptr_type)arg0)->tag != 9) { goto __ats_lab_110_0 ; } __ats_lab_109_1: if (((ats_sum_ptr_type)arg1)->tag != 9) { goto __ats_lab_112_1 ; } __ats_lab_109_2: tmp323 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp324 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp325 = atspre_eq_string_string (tmp323, tmp324) ; if (tmp325) { tmp295 = (ats_sum_ptr_type)0 ; } else { tmp326 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp326) ; } /* end of [if] */ break ; /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)arg0)->tag != 7) { goto __ats_lab_111_0 ; } __ats_lab_110_1: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_112_1 ; } __ats_lab_110_2: tmp327 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp328 = ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; /* ats_int_type tmp329 ; */ tmp329 = 0 ; tmp330 = intinfset_add_2 (tmp327, tmp328, (&tmp329)) ; tmp331 = atspre_gt_int_int (tmp329, 0) ; if (tmp331) { tmp332 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp332) ; } else { tmp333 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ((ats_sum_ptr_type)tmp333)->tag = 7 ; ats_selptrset_mac(anairiats_sum_9, tmp333, atslab_0, tmp330) ; tmp334 = (ats_sum_ptr_type)0 ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_0, tmp333) ; ats_selptrset_mac(anairiats_sum_0, tmp295, atslab_1, tmp334) ; } /* end of [if] */ break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)arg0)->tag != 8) { goto __ats_lab_112_0 ; } __ats_lab_111_1: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_112_1 ; } __ats_lab_111_2: tmp335 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_0) ; tmp336 = ats_caselptrlab_mac(anairiats_sum_11, arg0, atslab_1) ; tmp337 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; tmp338 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference (tmp336, tmp337) ; /* ats_ptr_type tmp339 ; */ tmp339 = __ats_fun_48_closure_make (tmp335) ; tmp295 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_map_cloptr (tmp338, tmp339) ; ATS_FREE(tmp339) ; break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: __ats_lab_112_1: __ats_lab_112_2: /* tmp341 = */ prerr_interror_0 () ; /* tmp342 = */ atspre_prerr_string (ATSstrcst(": p2atcst_difference: failed")) ; /* tmp343 = */ atspre_prerr_newline () ; /* tmp295 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp295) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 19324(line=613, offs=13) -- 19527(line=616, offs=29) */ ATSstaticdec() ats_ptr_type aux_50 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp352) ; ATSlocal (ats_ptr_type, tmp353) ; __ats_lab_aux_50: do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp352 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp352, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_0, tmp352, atslab_1, tmp350) ; tmp353 = aux_50 (env0, tmp351) ; tmp349 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp349, atslab_0, tmp352) ; ats_selptrset_mac(anairiats_sum_0, tmp349, atslab_1, tmp353) ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: tmp349 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp349) ; } /* end of [aux_50] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } aux_50_closure_type ; ats_ptr_type aux_50_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_50 (((aux_50_closure_type*)cloptr)->closure_env_0, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_50_closure_init (aux_50_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_50_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type aux_50_closure_make (ats_ptr_type env0) { aux_50_closure_type *p_clo = ATS_MALLOC(sizeof(aux_50_closure_type)) ; aux_50_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 19667(line=620, offs=13) -- 19849(line=623, offs=29) */ ATSstaticdec() ats_ptr_type aux_51 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp356) ; ATSlocal (ats_ptr_type, tmp357) ; ATSlocal (ats_ptr_type, tmp358) ; ATSlocal (ats_ptr_type, tmp359) ; ATSlocal (ats_ptr_type, tmp360) ; __ats_lab_aux_51: do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp357 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp358 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp359 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp359, atslab_0, tmp357) ; ats_selptrset_mac(anairiats_sum_0, tmp359, atslab_1, env0) ; tmp360 = aux_51 (env0, env1, tmp358) ; tmp356 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp356, atslab_0, tmp359) ; ats_selptrset_mac(anairiats_sum_0, tmp356, atslab_1, tmp360) ; break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp356 = env1 ; break ; } while (0) ; return (tmp356) ; } /* end of [aux_51] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_51_closure_type ; ats_ptr_type aux_51_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_51 (((aux_51_closure_type*)cloptr)->closure_env_0, ((aux_51_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_51_closure_init (aux_51_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_51_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_51_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_51_closure_type *p_clo = ATS_MALLOC(sizeof(aux_51_closure_type)) ; aux_51_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 19090(line=607, offs=7) -- 19945(line=629, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp344) ; ATSlocal (ats_ptr_type, tmp345) ; ATSlocal (ats_ptr_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp348) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_ptr_type, tmp362) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference: do { /* branch: __ats_lab_113 */ __ats_lab_113_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_118_0 ; } __ats_lab_113_1: tmp345 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp346 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp347 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_0) ; tmp348 = ats_caselptrlab_mac(anairiats_sum_0, arg1, atslab_1) ; tmp355 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference (tmp346, tmp348) ; tmp354 = aux_50 (tmp345, tmp355) ; tmp362 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference (tmp345, tmp347) ; tmp361 = aux_51 (tmp346, tmp354, tmp362) ; tmp344 = tmp361 ; break ; /* branch: __ats_lab_118 */ __ats_lab_118_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_118_1: tmp344 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp344) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcstlst_difference] */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 20295(line=639, offs=13) -- 20571(line=644, offs=29) */ ATSstaticdec() ats_ptr_type aux_53 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp369) ; ATSlocal (ats_ptr_type, tmp370) ; ATSlocal (ats_ptr_type, tmp371) ; ATSlocal (ats_ptr_type, tmp372) ; ATSlocal (ats_ptr_type, tmp373) ; __ats_lab_aux_53: do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp370 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp371 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp372 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp372, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_3, tmp372, atslab_1, env1) ; ats_selptrset_mac(anairiats_sum_3, tmp372, atslab_2, tmp370) ; tmp373 = aux_53 (env0, env1, tmp371) ; tmp369 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp369, atslab_0, tmp372) ; ats_selptrset_mac(anairiats_sum_0, tmp369, atslab_1, tmp373) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_121_1: tmp369 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp369) ; } /* end of [aux_53] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_53_closure_type ; ats_ptr_type aux_53_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_53 (((aux_53_closure_type*)cloptr)->closure_env_0, ((aux_53_closure_type*)cloptr)->closure_env_1, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_53_closure_init (aux_53_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_53_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_53_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_53_closure_type *p_clo = ATS_MALLOC(sizeof(aux_53_closure_type)) ; aux_53_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 20708(line=648, offs=13) -- 20965(line=653, offs=30) */ ATSstaticdec() ats_ptr_type aux_54 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_ptr_type, tmp377) ; ATSlocal (ats_ptr_type, tmp378) ; ATSlocal (ats_ptr_type, tmp379) ; ATSlocal (ats_ptr_type, tmp380) ; __ats_lab_aux_54: do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp377 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_0) ; tmp378 = ats_caselptrlab_mac(anairiats_sum_0, arg0, atslab_1) ; tmp379 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp379, atslab_0, env0) ; ats_selptrset_mac(anairiats_sum_3, tmp379, atslab_1, tmp377) ; ats_selptrset_mac(anairiats_sum_3, tmp379, atslab_2, env1) ; tmp380 = aux_54 (env0, env1, env2, tmp378) ; tmp376 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp376, atslab_0, tmp379) ; ats_selptrset_mac(anairiats_sum_0, tmp376, atslab_1, tmp380) ; break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_123_1: tmp376 = env2 ; break ; } while (0) ; return (tmp376) ; } /* end of [aux_54] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_54_closure_type ; ats_ptr_type aux_54_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { return aux_54 (((aux_54_closure_type*)cloptr)->closure_env_0, ((aux_54_closure_type*)cloptr)->closure_env_1, ((aux_54_closure_type*)cloptr)->closure_env_2, arg0) ; } /* end of function */ ATSinline() ats_void_type aux_54_closure_init (aux_54_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_54_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_54_closure_make (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type env2) { aux_54_closure_type *p_clo = ATS_MALLOC(sizeof(aux_54_closure_type)) ; aux_54_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_patcst2.dats: 20021(line=633, offs=3) -- 21062(line=659, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference: do { /* branch: __ats_lab_119 */ __ats_lab_119_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_124_0 ; } __ats_lab_119_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_124_1 ; } __ats_lab_119_2: tmp364 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_0) ; tmp365 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_1) ; tmp366 = ats_caselptrlab_mac(anairiats_sum_3, arg0, atslab_2) ; tmp367 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_1) ; tmp368 = ats_caselptrlab_mac(anairiats_sum_3, arg1, atslab_2) ; tmp375 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference (tmp366, tmp368) ; tmp374 = aux_53 (tmp364, tmp365, tmp375) ; tmp382 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__p2atcst_difference (tmp365, tmp367) ; tmp381 = aux_54 (tmp364, tmp366, tmp374, tmp382) ; tmp363 = tmp381 ; break ; /* branch: __ats_lab_124 */ __ats_lab_124_0: __ats_lab_124_1: __ats_lab_124_2: tmp363 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp363) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__labp2atcstlst_difference] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_intinf_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_patcst2_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_effect_dats.c0000664000175000017500000013540412223166160021362 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_0 ; typedef struct { ats_ptr_type atslab_d0exp_loc ; ats_ptr_type atslab_d0exp_node ; } anairiats_rec_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_uint_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_e0fftag_loc ; ats_ptr_type atslab_e0fftag_node ; } anairiats_rec_5 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { int tag ; ats_int_type atslab_0 ; } anairiats_sum_7 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_9 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; } anairiats_sum_10 ; typedef struct { ats_int_type atslab_0 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_rec_12 ; /* external typedefs */ typedef ats_uint_type atsopt_effset_t ; typedef ats_int_type atsopt_effect_t ; /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOclo_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__FUNCLOfun_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGcst_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGvar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGprf_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGlin_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGfun_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__E0FFTAGclo_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Eeffmask_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTset_2) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_sub_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_asl_int_int1) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_uint_uint) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_bool_type, atspre_eq_string_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de) (ats_ref_type, ats_ptr_type) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm) ; ATSextern_val(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSextern_fun(ats_void_type, atsopt_fprint_effect) (ats_ref_type, ats_int_type) ; ATSextern_val(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; ATSextern_val(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset) (ats_uint_type, ats_uint_type) ; ATSextern_fun(ats_void_type, atsopt_fprint_effset) (ats_ref_type, ats_uint_type) ; ATSextern_fun(ats_uint_type, atsopt_effset_add) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_uint_type, atsopt_effset_del) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atsopt_effset_contain) (ats_uint_type, ats_int_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain) (ats_ptr_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__sasp__effset_t = 0 ; int ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__sasp__effect_t = 0 ; /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm) ; ATSglobal(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; ATSglobal(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; ATSglobal(ats_uint_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil) ; /* internal function declarations */ static ats_void_type aux_3 (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_effvarlst_11 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_bool_type name_is_emp_18 (ats_ptr_type arg0) ; static ats_bool_type name_is_all_19 (ats_ptr_type arg0) ; static ats_bool_type name_is_exn_20 (ats_ptr_type arg0) ; static ats_bool_type name_is_exnref_21 (ats_ptr_type arg0) ; static ats_bool_type name_is_ntm_22 (ats_ptr_type arg0) ; static ats_bool_type name_is_ref_23 (ats_ptr_type arg0) ; static ats_bool_type name_is_term_24 (ats_ptr_type arg0) ; static ats_bool_type name_is_lazy_25 (ats_ptr_type arg0) ; static ats_void_type loop_err_26 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_27 (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4, ats_ptr_type arg5) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; ATSstatic (ats_ptr_type, statmp1) ; ATSstatic (ats_ptr_type, statmp2) ; ATSstatic (ats_int_type, statmp26) ; ATSstatic (ats_int_type, statmp27) ; ATSstatic (ats_ptr_type, statmp50) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 2604(line=91, offs=3) -- 2642(line=91, offs=41) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect (ats_int_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp3) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect: tmp3 = atspre_eq_int_int (arg0, arg1) ; return (tmp3) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effect_effect] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 2699(line=96, offs=3) -- 3096(line=108, offs=4) */ ATSglobaldec() ats_void_type atsopt_fprint_effect (ats_ref_type arg0, ats_int_type arg1) { /* local vardec */ // ATSlocal_void (tmp4) ; ATSlocal (ats_bool_type, tmp5) ; ATSlocal (ats_bool_type, tmp6) ; ATSlocal (ats_bool_type, tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; __ats_lab_atsopt_fprint_effect: tmp5 = atspre_eq_int_int (arg1, 1) ; if (tmp5) { /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("exn")) ; } else { tmp6 = atspre_eq_int_int (arg1, 2) ; if (tmp6) { /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("ntm")) ; } else { tmp7 = atspre_eq_int_int (arg1, 3) ; if (tmp7) { /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("ref")) ; } else { /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst("eff(")) ; /* tmp9 = */ atspre_fprint_int (arg0, arg1) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; } /* end of [if] */ } /* end of [if] */ } /* end of [if] */ return /* (tmp4) */ ; } /* end of [atsopt_fprint_effect] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 3186(line=113, offs=7) -- 3463(line=119, offs=24) */ ATSstaticdec() ats_void_type aux_3 (ats_int_type arg0, ats_ref_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp11) ; ATSlocal (ats_int_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; // ATSlocal_void (tmp14) ; ATSlocal (ats_bool_type, tmp15) ; // ATSlocal_void (tmp16) ; ATSlocal (ats_int_type, tmp17) ; __ats_lab_aux_3: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp12 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_0) ; tmp13 = ats_caselptrlab_mac(anairiats_sum_0, arg2, atslab_1) ; tmp15 = atspre_gt_int_int (arg0, 0) ; if (tmp15) { /* tmp14 = */ atspre_fprint_string (arg1, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp16 = */ atsopt_fprint_effect (arg1, tmp12) ; tmp17 = atspre_add_int_int (arg0, 1) ; arg0 = tmp17 ; arg1 = arg1 ; arg2 = tmp13 ; goto __ats_lab_aux_3 ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp11) */ ; } /* end of [aux_3] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 3157(line=112, offs=7) -- 3530(line=123, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp10) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst: /* tmp10 = */ aux_3 (0, arg0, arg1) ; return /* (tmp10) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effectlst] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 3605(line=127, offs=24) -- 3643(line=127, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effect (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; // ATSlocal_void (tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effect: tmp19 = atspre_stdout_get () ; tmp20 = ats_selsin_mac(tmp19, atslab_1) ; /* tmp21 = */ atsopt_fprint_effect (tmp20, arg0) ; /* tmp18 = */ atspre_stdout_view_set () ; return /* (tmp18) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effect] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 3667(line=128, offs=24) -- 3705(line=128, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_ptr_type, tmp24) ; // ATSlocal_void (tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect: tmp23 = atspre_stderr_get () ; tmp24 = ats_selsin_mac(tmp23, atslab_1) ; /* tmp25 = */ atsopt_fprint_effect (tmp24, arg0) ; /* tmp22 = */ atspre_stderr_view_set () ; return /* (tmp22) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effect] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 4123(line=145, offs=28) -- 4163(line=145, offs=68) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset (ats_uint_type arg0, ats_uint_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp28) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset: tmp28 = atspre_eq_uint_uint (arg0, arg1) ; return (tmp28) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 5735(line=227, offs=24) -- 5818(line=229, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_effmask_all (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; __ats_lab_d0exp_effmask_all: tmp30 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp31 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp31)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp31, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all) ; tmp29 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp29, atslab_d0exp_loc, tmp30) ; ats_selptrset_mac(anairiats_rec_1, tmp29, atslab_d0exp_node, tmp31) ; return (tmp29) ; } /* end of [d0exp_effmask_all] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 5883(line=232, offs=24) -- 5966(line=234, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_effmask_exn (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; ATSlocal (ats_ptr_type, tmp37) ; __ats_lab_d0exp_effmask_exn: tmp33 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp35 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp35, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn) ; tmp36 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp35), atslab_1) ; tmp37 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp36) = tmp37 ; tmp34 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp34)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp34, atslab_0, tmp35) ; tmp32 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp32, atslab_d0exp_loc, tmp33) ; ats_selptrset_mac(anairiats_rec_1, tmp32, atslab_d0exp_node, tmp34) ; return (tmp32) ; } /* end of [d0exp_effmask_exn] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 6031(line=237, offs=24) -- 6114(line=239, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_effmask_ntm (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; ATSlocal (ats_ptr_type, tmp43) ; __ats_lab_d0exp_effmask_ntm: tmp39 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp41 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp41, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm) ; tmp42 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp41), atslab_1) ; tmp43 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp42) = tmp43 ; tmp40 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp40)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp40, atslab_0, tmp41) ; tmp38 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp38, atslab_d0exp_loc, tmp39) ; ats_selptrset_mac(anairiats_rec_1, tmp38, atslab_d0exp_node, tmp40) ; return (tmp38) ; } /* end of [d0exp_effmask_ntm] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 6179(line=242, offs=24) -- 6262(line=244, offs=2) */ ATSglobaldec() ats_ptr_type d0exp_effmask_ref (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_d0exp_effmask_ref: tmp45 = ats_selsin_mac(arg0, atslab_t0kn_loc) ; tmp47 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, tmp47, atslab_0, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref) ; tmp48 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, tmp47), atslab_1) ; tmp49 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp48) = tmp49 ; tmp46 = ATS_MALLOC(sizeof(anairiats_sum_2)) ; ((ats_sum_ptr_type)tmp46)->tag = 12 ; ats_selptrset_mac(anairiats_sum_2, tmp46, atslab_0, tmp47) ; tmp44 = ATS_MALLOC(sizeof(anairiats_rec_1)) ; ats_selptrset_mac(anairiats_rec_1, tmp44, atslab_d0exp_loc, tmp45) ; ats_selptrset_mac(anairiats_rec_1, tmp44, atslab_d0exp_node, tmp46) ; return (tmp44) ; } /* end of [d0exp_effmask_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 6478(line=256, offs=7) -- 6737(line=262, offs=19) */ ATSstaticdec() ats_void_type aux_12 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; // ATSlocal_void (tmp55) ; ATSlocal (ats_bool_type, tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_int_type, tmp58) ; __ats_lab_aux_12: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp53 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_0) ; tmp54 = ats_caselptrlab_mac(anairiats_sum_3, arg2, atslab_1) ; tmp56 = atspre_gt_int_int (arg1, 0) ; if (tmp56) { /* tmp55 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0de (arg0, tmp53) ; tmp58 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp58 ; arg2 = tmp54 ; goto __ats_lab_aux_12 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp52) */ ; } /* end of [aux_12] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 6356(line=250, offs=5) -- 6782(line=266, offs=4) */ ATSstaticdec() ats_void_type fprint_effvarlst_11 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp51) ; __ats_lab_fprint_effvarlst_11: /* tmp51 = */ aux_12 (arg0, 0, arg1) ; return /* (tmp51) */ ; } /* end of [fprint_effvarlst_11] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 6839(line=270, offs=3) -- 7241(line=280, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp59) ; ATSlocal (ats_uint_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; // ATSlocal_void (tmp62) ; // ATSlocal_void (tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: /* tmp59 = */ atspre_fprint_string (arg0, ATSstrcst("all")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_6_0 ; } __ats_lab_5_1: /* tmp59 = */ atspre_fprint_string (arg0, ATSstrcst("nil")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: // if (((ats_sum_ptr_type)arg1)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_6_1: tmp60 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp61 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_1) ; /* tmp62 = */ atspre_fprint_string (arg0, ATSstrcst("set(")) ; /* tmp63 = */ atsopt_fprint_effset (arg0, tmp60) ; /* tmp64 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp65 = */ fprint_effvarlst_11 (arg0, tmp61) ; /* tmp59 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp59) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7313(line=285, offs=14) -- 7351(line=285, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effcst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effcst: tmp67 = atspre_stdout_get () ; tmp68 = ats_selsin_mac(tmp67, atslab_1) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst (tmp68, arg0) ; /* tmp66 = */ atspre_stdout_view_set () ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__print_effcst] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7375(line=287, offs=14) -- 7413(line=287, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effcst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effcst: tmp71 = atspre_stderr_get () ; tmp72 = ats_selsin_mac(tmp71, atslab_1) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst (tmp72, arg0) ; /* tmp70 = */ atspre_stderr_view_set () ; return /* (tmp70) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__prerr_effcst] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7461(line=291, offs=26) -- 7604(line=296, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain (ats_ptr_type arg0, ats_int_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp74) ; ATSlocal (ats_uint_type, tmp75) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)arg0)->tag != 0) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp74 = ats_true_bool ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)arg0)->tag != 1) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp74 = ats_false_bool ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (((ats_sum_ptr_type)arg0)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp75 = ats_caselptrlab_mac(anairiats_sum_4, arg0, atslab_0) ; tmp74 = atsopt_effset_contain (tmp75, arg1) ; break ; } while (0) ; return (tmp74) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7662(line=298, offs=30) -- 7696(line=298, offs=64) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain_ntm (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp76) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain_ntm: tmp76 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain (arg0, 2) ; return (tmp76) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effcst_contain_ntm] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7722(line=302, offs=4) -- 7767(line=302, offs=49) */ ATSstaticdec() ats_bool_type name_is_emp_18 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp77) ; __ats_lab_name_is_emp_18: tmp77 = atspre_eq_string_string (arg0, ATSstrcst("0")) ; return (tmp77) ; } /* end of [name_is_emp_18] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7772(line=304, offs=4) -- 7817(line=304, offs=49) */ ATSstaticdec() ats_bool_type name_is_all_19 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp78) ; __ats_lab_name_is_all_19: tmp78 = atspre_eq_string_string (arg0, ATSstrcst("1")) ; return (tmp78) ; } /* end of [name_is_all_19] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7822(line=306, offs=4) -- 7908(line=307, offs=52) */ ATSstaticdec() ats_bool_type name_is_exn_20 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp79) ; ATSlocal (ats_bool_type, tmp80) ; __ats_lab_name_is_exn_20: tmp80 = atspre_eq_string_string (arg0, ATSstrcst("exn")) ; if (tmp80) { tmp79 = ats_true_bool ; } else { tmp79 = atspre_eq_string_string (arg0, ATSstrcst("exception")) ; } /* end of [if] */ return (tmp79) ; } /* end of [name_is_exn_20] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7913(line=309, offs=4) -- 7966(line=309, offs=57) */ ATSstaticdec() ats_bool_type name_is_exnref_21 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp81) ; __ats_lab_name_is_exnref_21: tmp81 = atspre_eq_string_string (arg0, ATSstrcst("exnref")) ; return (tmp81) ; } /* end of [name_is_exnref_21] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 7971(line=311, offs=4) -- 8055(line=312, offs=50) */ ATSstaticdec() ats_bool_type name_is_ntm_22 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp82) ; ATSlocal (ats_bool_type, tmp83) ; __ats_lab_name_is_ntm_22: tmp83 = atspre_eq_string_string (arg0, ATSstrcst("ntm")) ; if (tmp83) { tmp82 = ats_true_bool ; } else { tmp82 = atspre_eq_string_string (arg0, ATSstrcst("nonterm")) ; } /* end of [if] */ return (tmp82) ; } /* end of [name_is_ntm_22] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 8060(line=314, offs=4) -- 8145(line=315, offs=52) */ ATSstaticdec() ats_bool_type name_is_ref_23 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp84) ; ATSlocal (ats_bool_type, tmp85) ; __ats_lab_name_is_ref_23: tmp85 = atspre_eq_string_string (arg0, ATSstrcst("ref")) ; if (tmp85) { tmp84 = ats_true_bool ; } else { tmp84 = atspre_eq_string_string (arg0, ATSstrcst("reference")) ; } /* end of [if] */ return (tmp84) ; } /* end of [name_is_ref_23] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 8150(line=317, offs=4) -- 8199(line=317, offs=53) */ ATSstaticdec() ats_bool_type name_is_term_24 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp86) ; __ats_lab_name_is_term_24: tmp86 = atspre_eq_string_string (arg0, ATSstrcst("term")) ; return (tmp86) ; } /* end of [name_is_term_24] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 8335(line=327, offs=4) -- 8383(line=327, offs=52) */ ATSstaticdec() ats_bool_type name_is_lazy_25 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp87) ; __ats_lab_name_is_lazy_25: tmp87 = atspre_eq_string_string (arg0, ATSstrcst("laz")) ; return (tmp87) ; } /* end of [name_is_lazy_25] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 8416(line=333, offs=4) -- 8620(line=338, offs=4) */ ATSstaticdec() ats_void_type loop_err_26 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp88) ; // ATSlocal_void (tmp89) ; // ATSlocal_void (tmp90) ; // ATSlocal_void (tmp91) ; // ATSlocal_void (tmp92) ; // ATSlocal_void (tmp93) ; // ATSlocal_void (tmp94) ; __ats_lab_loop_err_26: /* tmp89 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp90 = */ atspre_prerr_string (ATSstrcst(": error(1)")) ; /* tmp91 = */ atspre_prerr_string (ATSstrcst(": unrecognized effect constant: [")) ; /* tmp92 = */ atspre_prerr_string (arg1) ; /* tmp93 = */ atspre_prerr_string (ATSstrcst("]")) ; /* tmp94 = */ atspre_prerr_newline () ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; return /* (tmp88) */ ; } /* end of [loop_err_26] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 8647(line=340, offs=5) -- 12133(line=441, offs=4) */ ATSstaticdec() ats_void_type loop_27 (ats_ref_type arg0, ats_ref_type arg1, ats_ref_type arg2, ats_ref_type arg3, ats_ref_type arg4, ats_ptr_type arg5) { /* local vardec */ // ATSlocal_void (tmp95) ; ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_bool_type, tmp104) ; ATSlocal (ats_bool_type, tmp105) ; ATSlocal (ats_int_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_bool_type, tmp108) ; ATSlocal (ats_bool_type, tmp109) ; ATSlocal (ats_int_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_bool_type, tmp112) ; ATSlocal (ats_bool_type, tmp113) ; ATSlocal (ats_uint_type, tmp114) ; ATSlocal (ats_uint_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_ptr_type, tmp117) ; ATSlocal (ats_bool_type, tmp118) ; ATSlocal (ats_bool_type, tmp119) ; ATSlocal (ats_uint_type, tmp120) ; ATSlocal (ats_uint_type, tmp121) ; ATSlocal (ats_bool_type, tmp122) ; ATSlocal (ats_bool_type, tmp123) ; ATSlocal (ats_uint_type, tmp124) ; ATSlocal (ats_uint_type, tmp125) ; ATSlocal (ats_uint_type, tmp126) ; ATSlocal (ats_uint_type, tmp127) ; ATSlocal (ats_bool_type, tmp128) ; ATSlocal (ats_bool_type, tmp129) ; ATSlocal (ats_uint_type, tmp130) ; ATSlocal (ats_uint_type, tmp131) ; ATSlocal (ats_bool_type, tmp132) ; ATSlocal (ats_bool_type, tmp133) ; ATSlocal (ats_uint_type, tmp134) ; ATSlocal (ats_uint_type, tmp135) ; ATSlocal (ats_bool_type, tmp136) ; ATSlocal (ats_bool_type, tmp137) ; ATSlocal (ats_uint_type, tmp138) ; ATSlocal (ats_uint_type, tmp139) ; ATSlocal (ats_ptr_type, tmp140) ; ATSlocal (ats_int_type, tmp141) ; ATSlocal (ats_bool_type, tmp142) ; ATSlocal (ats_int_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_bool_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; ATSlocal (ats_ptr_type, tmp148) ; ATSlocal (ats_bool_type, tmp149) ; ATSlocal (ats_int_type, tmp150) ; ATSlocal (ats_int_type, tmp151) ; ATSlocal (ats_int_type, tmp152) ; ATSlocal (ats_bool_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_bool_type, tmp157) ; __ats_lab_loop_27: do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (arg5 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_10_1: tmp96 = ats_caselptrlab_mac(anairiats_sum_3, arg5, atslab_0) ; tmp97 = ats_caselptrlab_mac(anairiats_sum_3, arg5, atslab_1) ; tmp99 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp96), atslab_e0fftag_node) ; do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp99)->tag != 1) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp100 = ats_caselptrlab_mac(anairiats_sum_2, tmp99, atslab_0) ; tmp101 = ATS_MALLOC(sizeof(anairiats_sum_3)) ; ats_selptrset_mac(anairiats_sum_3, tmp101, atslab_0, tmp100) ; ats_selptrset_mac(anairiats_sum_3, tmp101, atslab_1, ats_ptrget_mac(ats_ptr_type, arg4)) ; ats_ptrget_mac(ats_ptr_type, arg4) = tmp101 ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp99)->tag != 0) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp102 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_0) ; tmp103 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_1) ; tmp104 = name_is_all_19 (tmp103) ; if (!tmp104) { goto __ats_lab_13_1 ; } ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; tmp105 = atspre_gt_int_int (tmp102, 0) ; if (tmp105) { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil ; } else { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all ; } /* end of [if] */ break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: if (((ats_sum_ptr_type)tmp99)->tag != 0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp106 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_0) ; tmp107 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_1) ; tmp108 = name_is_emp_18 (tmp107) ; if (!tmp108) { goto __ats_lab_14_1 ; } ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; tmp109 = atspre_gt_int_int (tmp106, 0) ; if (tmp109) { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all ; } else { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil ; } /* end of [if] */ break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (((ats_sum_ptr_type)tmp99)->tag != 0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp110 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_0) ; tmp111 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_1) ; tmp112 = name_is_lazy_25 (tmp111) ; if (!tmp112) { goto __ats_lab_15_1 ; } ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; tmp113 = atspre_gt_int_int (tmp110, 0) ; if (tmp113) { tmp114 = atsopt_effset_add (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil, 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp114 ; } else { tmp115 = atsopt_effset_del (ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all, 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp115 ; } /* end of [if] */ break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: if (((ats_sum_ptr_type)tmp99)->tag != 0) { goto __ats_lab_22_0 ; } __ats_lab_15_1: tmp116 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_0) ; tmp117 = ats_caselptrlab_mac(anairiats_sum_6, tmp99, atslab_1) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: __ats_lab_16_1: tmp118 = name_is_exn_20 (tmp117) ; if (!tmp118) { goto __ats_lab_17_1 ; } tmp119 = atspre_gt_int_int (tmp116, 0) ; if (tmp119) { tmp120 = atsopt_effset_del (ats_ptrget_mac(ats_uint_type, arg3), 1) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp120 ; } else { tmp121 = atsopt_effset_add (ats_ptrget_mac(ats_uint_type, arg3), 1) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp121 ; } /* end of [if] */ break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: __ats_lab_17_1: tmp122 = name_is_exnref_21 (tmp117) ; if (!tmp122) { goto __ats_lab_18_1 ; } tmp123 = atspre_gt_int_int (tmp116, 0) ; if (tmp123) { tmp125 = atsopt_effset_del (ats_ptrget_mac(ats_uint_type, arg3), 1) ; tmp124 = atsopt_effset_del (tmp125, 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp124 ; } else { tmp127 = atsopt_effset_add (ats_ptrget_mac(ats_uint_type, arg3), 1) ; tmp126 = atsopt_effset_add (tmp127, 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp126 ; } /* end of [if] */ break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: __ats_lab_18_1: tmp128 = name_is_ntm_22 (tmp117) ; if (!tmp128) { goto __ats_lab_19_1 ; } tmp129 = atspre_gt_int_int (tmp116, 0) ; if (tmp129) { tmp130 = atsopt_effset_del (ats_ptrget_mac(ats_uint_type, arg3), 2) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp130 ; } else { tmp131 = atsopt_effset_add (ats_ptrget_mac(ats_uint_type, arg3), 2) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp131 ; } /* end of [if] */ break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: __ats_lab_19_1: tmp132 = name_is_term_24 (tmp117) ; if (!tmp132) { goto __ats_lab_20_1 ; } tmp133 = atspre_gt_int_int (tmp116, 0) ; if (tmp133) { tmp134 = atsopt_effset_add (ats_ptrget_mac(ats_uint_type, arg3), 2) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp134 ; } else { tmp135 = atsopt_effset_del (ats_ptrget_mac(ats_uint_type, arg3), 2) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp135 ; } /* end of [if] */ break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: __ats_lab_20_1: tmp136 = name_is_ref_23 (tmp117) ; if (!tmp136) { goto __ats_lab_21_1 ; } tmp137 = atspre_gt_int_int (tmp116, 0) ; if (tmp137) { tmp138 = atsopt_effset_del (ats_ptrget_mac(ats_uint_type, arg3), 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp138 ; } else { tmp139 = atsopt_effset_add (ats_ptrget_mac(ats_uint_type, arg3), 3) ; ats_ptrget_mac(ats_uint_type, arg3) = tmp139 ; } /* end of [if] */ break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: __ats_lab_21_1: tmp140 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, tmp96), atslab_e0fftag_loc) ; /* tmp98 = */ loop_err_26 (tmp140, tmp117) ; break ; } while (0) ; break ; /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp99)->tag != 2) { goto __ats_lab_23_0 ; } __ats_lab_22_1: ats_ptrget_mac(ats_int_type, arg2) = 1 ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp99)->tag != 3) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp141 = ats_caselptrlab_mac(anairiats_sum_7, tmp99, atslab_0) ; ats_ptrget_mac(ats_int_type, arg1) = 1 ; tmp142 = atspre_gt_int_int (tmp141, 0) ; if (tmp142) { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all ; ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp99)->tag != 4) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_8, tmp99, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_8, tmp99, atslab_1) ; tmp146 = atspre_gte_int_int (tmp143, 0) ; if (tmp146) { ats_ptrget_mac(ats_int_type, arg1) = tmp143 ; } else { /* empty */ } /* end of [if] */ tmp148 = (ats_sum_ptr_type)0 ; tmp147 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp147, atslab_0, tmp148) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp147 ; tmp149 = atspre_gt_int_int (tmp144, 0) ; if (tmp149) { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all ; ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (((ats_sum_ptr_type)tmp99)->tag != 5) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp150 = ats_caselptrlab_mac(anairiats_sum_10, tmp99, atslab_0) ; tmp151 = ats_caselptrlab_mac(anairiats_sum_10, tmp99, atslab_1) ; tmp152 = ats_caselptrlab_mac(anairiats_sum_10, tmp99, atslab_2) ; tmp154 = atspre_gte_int_int (tmp150, 0) ; if (tmp154) { ats_ptrget_mac(ats_int_type, arg1) = tmp150 ; } else { /* empty */ } /* end of [if] */ tmp156 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp156, atslab_0, tmp151) ; tmp155 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp155, atslab_0, tmp156) ; ats_ptrget_mac(ats_ptr_type, arg0) = tmp155 ; tmp157 = atspre_gt_int_int (tmp152, 0) ; if (tmp157) { ats_ptrget_mac(ats_uint_type, arg3) = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all ; ats_ptrget_mac(ats_ptr_type, arg4) = statmp50 ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; arg0 = arg0 ; arg1 = arg1 ; arg2 = arg2 ; arg3 = arg3 ; arg4 = arg4 ; arg5 = tmp97 ; goto __ats_lab_loop_27 ; // tail call break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (arg5 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: break ; } while (0) ; return /* (tmp95) */ ; } /* end of [loop_27] */ /* // /home/hwxi/research/Anairiats/src/ats_effect.dats: 12197(line=446, offs=15) -- 12713(line=460, offs=4) */ ATSglobaldec() anairiats_rec_12 ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr (ats_ptr_type arg0) { /* local vardec */ ATSlocal (anairiats_rec_12, tmp158) ; ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (ats_int_type, tmp160) ; ATSlocal (ats_int_type, tmp161) ; ATSlocal (ats_uint_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; // ATSlocal_void (tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_bool_type, tmp166) ; ATSlocal (ats_bool_type, tmp167) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr: /* ats_ptr_type tmp159 ; */ tmp159 = (ats_sum_ptr_type)0 ; /* ats_int_type tmp160 ; */ tmp160 = 0 ; /* ats_int_type tmp161 ; */ tmp161 = 0 ; /* ats_uint_type tmp162 ; */ tmp162 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil ; /* ats_ptr_type tmp163 ; */ tmp163 = statmp50 ; /* tmp164 = */ loop_27 ((&tmp159), (&tmp160), (&tmp161), (&tmp162), (&tmp163), arg0) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: __ats_lab_27_1: tmp166 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset (tmp162, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all) ; if (!tmp166) { goto __ats_lab_28_1 ; } tmp165 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTall_0) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: __ats_lab_28_1: tmp167 = ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__eq_effset_effset (tmp162, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil) ; if (!tmp167) { goto __ats_lab_31_1 ; } do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (tmp163 != (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp165 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__EFFCSTnil_1) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: __ats_lab_30_1: tmp165 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp165)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp165, atslab_0, tmp162) ; ats_selptrset_mac(anairiats_sum_4, tmp165, atslab_1, tmp163) ; break ; } while (0) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: __ats_lab_31_1: tmp165 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp165)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp165, atslab_0, tmp162) ; ats_selptrset_mac(anairiats_sum_4, tmp165, atslab_1, tmp163) ; break ; } while (0) ; tmp158.atslab_0 = tmp159 ; tmp158.atslab_1 = tmp160 ; tmp158.atslab_2 = tmp161 ; tmp158.atslab_3 = tmp165 ; return (tmp158) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__e0fftaglst_tr] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp1, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp2, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp26, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp27, sizeof(ats_int_type)) ; ATS_GC_MARKROOT(&statmp50, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_exn = 1 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ntm = 2 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref, sizeof(ats_int_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effect_ref = 3 ; statmp0 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp0, atslab_0, 1) ; statmp1 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, statmp0), atslab_1) ; statmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp2, atslab_0, 2) ; ats_ptrget_mac(ats_ptr_type, statmp1) = statmp2 ; statmp1 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, statmp2), atslab_1) ; statmp2 = ATS_MALLOC(sizeof(anairiats_sum_0)) ; ats_selptrset_mac(anairiats_sum_0, statmp2, atslab_0, 3) ; ats_ptrget_mac(ats_ptr_type, statmp1) = statmp2 ; statmp1 = &ats_selptr_mac(ats_castptr_mac(anairiats_sum_0, statmp2), atslab_1) ; statmp2 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp1) = statmp2 ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effectlst_all = statmp0 ; statmp27 = atspre_asl_int_int1 (1, 4) ; statmp26 = atspre_sub_int_int (statmp27, 1) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all, sizeof(ats_uint_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_all = ats_castfn_mac(ats_uint_type, statmp26) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil, sizeof(ats_uint_type)) ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__effset_nil = ats_castfn_mac(ats_uint_type, 0) ; statmp50 = (ats_sum_ptr_type)0 ; return ; } /* end of [dynload function] */ /* external codes at mid */ #define MAX_EFFECT_NUMBER 4 #ifdef __WORDSIZE #if (MAX_EFFECT_NUMBER > __WORDSIZE) #error "MAX_EFFECT_NUMBER is too large!" #endif #endif ats_void_type atsopt_fprint_effset ( ats_ptr_type out, atsopt_effset_t effs ) { int i, n ; i = 1 ; n = 0 ; while (i <= MAX_EFFECT_NUMBER) { if (effs & 0x1) { if (n > 0) fprintf ((FILE *)out, ","); atsopt_fprint_effect (out, i) ; ++n ; } ++i ; effs >>= 1 ; } return ; } /* end of [atsopt_fprint_effset] */ atsopt_effset_t atsopt_effset_add ( atsopt_effset_t efs, atsopt_effect_t eff ) { unsigned int i = 1 ; while (eff > 1) { i <<= 1; --eff ; } return (efs | i) ; } // end of [atsopt_effset_add] atsopt_effset_t atsopt_effset_del ( atsopt_effset_t efs, atsopt_effect_t eff ) { unsigned int i = 1 ; while (eff > 1) { i <<= 1; --eff ; } return (efs & ~i) ; } // end of [atsopt_effset_del] ats_bool_type atsopt_effset_contain ( atsopt_effset_t efs, atsopt_effect_t eff ) { unsigned int i = 1 ; while (eff > 1) { i <<= 1; --eff ; } return (efs & i ? ats_true_bool : ats_false_bool) ; } // end of [atsopt_effset_contain] atsopt_effset_t atsopt_effset_union ( atsopt_effset_t efs1, atsopt_effset_t efs2 ) { return (efs1 | efs2) ; } // end of [atsopt_effset_union] ats_bool_type atsopt_effset_subset ( atsopt_effset_t efs1, atsopt_effset_t efs2 ) { return (efs1 & ~efs2 ? ats_false_bool : ats_true_bool) ; } // end of [atsopt_effset_subset] /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_effect_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_trans3_env_dats.c0000664000175000017500000102566112223166160022214 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ #include "ats_counter.cats" /* only needed for [ATS/Geizella] */ /* type definitions */ typedef struct { ats_ptr_type atslab_s2exp_srt ; ats_ptr_type atslab_s2exp_node ; } anairiats_rec_0 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_1 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_rec_2 ; typedef struct { ats_ptr_type atslab_c3str_loc ; ats_ptr_type atslab_c3str_kind ; ats_ptr_type atslab_c3str_node ; } anairiats_rec_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_4 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_h3ypo_loc ; ats_ptr_type atslab_h3ypo_node ; } anairiats_rec_6 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_8 ; typedef struct { ats_int_type atslab_0 ; atsopt_count_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_sum_9 ; typedef struct { atsopt_count_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_rec_10 ; typedef struct { anairiats_rec_10 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_11 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_13 ; typedef struct { ats_ptr_type atslab_p2at_loc ; ats_ptr_type atslab_p2at_svs ; ats_ptr_type atslab_p2at_dvs ; ats_ptr_type atslab_p2at_typ ; ats_ptr_type atslab_p2at_node ; } anairiats_rec_14 ; typedef struct { int tag ; char *name ; ats_ptr_type atslab_0 ; } anairiats_sum_15 ; typedef struct { anairiats_rec_1 atslab_0 ; } anairiats_sum_16 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; ats_ptr_type atslab_4 ; } anairiats_rec_17 ; typedef struct { int tag ; char *name ; anairiats_rec_17 atslab_0 ; } anairiats_sum_18 ; typedef struct { anairiats_rec_17 atslab_0 ; } anairiats_sum_19 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_20 ; typedef struct { anairiats_rec_1 atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_21 ; typedef struct { atsopt_count_type atslab_0 ; } anairiats_sum_22 ; typedef struct { ats_ptr_type atslab_s2exparg_loc ; ats_ptr_type atslab_s2exparg_node ; } anairiats_rec_23 ; typedef struct { ats_ptr_type atslab_p3at_loc ; ats_ptr_type atslab_p3at_node ; ats_ptr_type atslab_p3at_typ ; ats_ptr_type atslab_p3at_typ_lft ; } anairiats_rec_24 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_25 ; typedef struct { int tag ; ats_bool_type atslab_0 ; } anairiats_sum_26 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_27 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; ats_int_type atslab_3 ; ats_ptr_type atslab_4 ; ats_ptr_type atslab_5 ; } anairiats_sum_28 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_29 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_vt_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_vt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_vt_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__WTHS2EXPLSTcons_none_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__TMPS2EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__LABS2EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Edatcontyp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Eexi_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Efun_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Emetfn_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyleq_27) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Etyrec_29) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Euni_30) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2Ewth_35) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB0lab_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2LAB1lab_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGall_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__S2EXPARGseq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTsome_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VAROPTnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINdone_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINnone_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINsome_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINvbox_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__LABP2ATCSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCany_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCbool_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCchar_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCcon_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCempty_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCfloat_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCint_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCintc_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCrec_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__P2TCstring_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tas_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__P3Tvar_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDpattern_match_exhaustiveness_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDvarfin_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPObind_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__H3YPOeqeq_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRitmlst_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMcstr_ref_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMdisj_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMhypo_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsvar_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__S3ITEMsVar_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTcons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__BSTnil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__MAP_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMlam_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMllam_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMset_2) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; ATSextern_val(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__ENVcon_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_assert_errmsg) (ats_bool_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_prerr_newline) () ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gte_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_eq_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ieq) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_icompare) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atspre_prerr_string) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_debug_prerrf) (ats_ptr_type, ...) ; ATSextern_fun(ats_varet_type, ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_copy__boxed) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp) (atsopt_count_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp) (ats_ref_type, atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(atsopt_count_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_srt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_d2con_d2con) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char) (ats_char_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq) (ats_ptr_type, ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq) (ats_int_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_absuni) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_opnexi) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_2, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_opnexi) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord) (ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varset) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varset) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_bool_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_cloptr) (ats_ptr_type, ats_clo_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst) (ats_ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_int_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_t0ype) ; ATSextern_val(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool) (ats_bool_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_bool_bool_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_char_char_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__clo_viewt0ype_viewt0ype_assume) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloptr_viewt0ype_viewtype_assume) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloref_t0ype_type_assume) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__crypt_viewt0ype_viewt0ype_assume) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neq_int_int_bool) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sizeof_viewt0ype_int_assume) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__intinflst_of_intinfset) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at) (ats_ptr_type) ; ATSextern_fun(anairiats_rec_1, ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_con_instantiate) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_print_s3itemlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, atsopt_print_s3itemlstlst) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_dec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_pattern_match_exhaustiveness) (ats_ptr_type, ats_int_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_bind) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add) (ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_push) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap) (ats_ref_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_get) (atsopt_count_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_labp2atcstlst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metric_instantiate) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_one) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_one) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_seq) (ats_ptr_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparg) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam) (ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitem_make) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get) () ; ATSextern_fun(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta) () ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta) () ; ATSextern_fun(ats_ptr_type, atspre_ref_make_elt_tsz) (ats_ref_type, ats_size_type) ; ATSextern_fun(ats_ptr_type, atspre_ref_get_view_ptr) (ats_ptr_type) ; ATSextern_fun(ats_bool_type, atsopt_map_lin_dice) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atsopt_print_the_s3itemlst) () ; ATSextern_fun(ats_void_type, atsopt_print_the_s3itemlstlst) () ; ATSextern_fun(ats_void_type, atsopt_free_the_s3itemlst) () ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__sasp__d2varset_env_token = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMlam_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMllam_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMset_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__ENVcon_0) ; /* exn constructor declarations */ ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found) ; ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; ATSglobal(ats_exn_type, ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found) ; /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) ; static ats_void_type prerr_interror_1 () ; static ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) ; static ats_ptr_type ref_make_elt_04159_ats_ptr_type (ats_ptr_type arg0) ; static ats_int_type __ats_fun_12 (atsopt_count_type arg0, atsopt_count_type arg1) ; static ats_void_type bst_free_036_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type map_cleanup_01911_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_void_type loop_17 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_list_inf_0132_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type map_list_inf_01916_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_int_type bst_size_040_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) ; static ats_ptr_type bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_ptr_type bst_insert_random_079_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type map_insert_01912_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) ; static ats_ptr_type bst_search_068_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) ; static ats_ptr_type map_search_01914_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_ptr_type bst_join_random_088_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type bst_remove_random_0102_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_ptr_type map_remove_01913_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1) ; static ats_void_type aux_32 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type s2lablst_is_prefix_42 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type d2var_fin_check_43 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type the_d2varset_env_get_llam_ld2vs_50 (ats_ptr_type arg0) ; static ats_bool_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_bool_type aux_60 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type __ats_fun_62 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type __ats_fun_62_closure_make (ats_ptr_type env0) ; static ats_void_type __ats_fun_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type auxCK_64 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type auxCK_64_closure_make (ats_ptr_type env0) ; static ats_void_type auxCK_64_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type auxlst_65 (ats_ptr_type env0, ats_ptr_type arg0) ; static ats_clo_ptr_type auxlst_65_closure_make (ats_ptr_type env0) ; static ats_void_type auxlst_65_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_void_type f_67 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_68 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type f_70 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type loop_71 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type f_73 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_74 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_80 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_83 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type trans3_env_hypo_add_disj_96 (ats_ptr_type arg0) ; static ats_ptr_type aux_108 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_ptr_type aux_110 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_110_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_110_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type auxvar_118 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type auxpatlst_119 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_121 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static ats_void_type auxlst_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux0_129 (ats_ptr_type arg0, ats_ptr_type arg1) ; static anairiats_rec_1 aux1_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) ; static anairiats_rec_1 aux2_131 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) ; static ats_void_type aux_137 (ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_138 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_138_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_void_type aux_138_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; static ats_int_type aux_140 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_int_type aux_142 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) ; static ats_ptr_type aux_144 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_clo_ptr_type aux_144_closure_make (ats_ptr_type env0, ats_ptr_type env1) ; static ats_ptr_type aux_144_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_147 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) ; static ats_clo_ptr_type aux_147_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) ; static ats_void_type aux_147_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) ; /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp28) ; ATSstatic (ats_ptr_type, statmp31) ; ATSstatic (ats_ptr_type, statmp32) ; ATSstatic (ats_ptr_type, statmp33) ; ATSstatic (ats_ptr_type, statmp34) ; ATSstatic (ats_ptr_type, statmp35) ; ATSstatic (ats_ptr_type, statmp239) ; ATSstatic (ats_ptr_type, statmp240) ; ATSstatic (ats_ptr_type, statmp241) ; ATSstatic (ats_ptr_type, statmp316) ; ATSstatic (ats_ptr_type, statmp317) ; ATSstatic (ats_ptr_type, statmp318) ; ATSstatic (ats_ptr_type, statmp509) ; ATSstatic (ats_ptr_type, statmp510) ; ATSstatic (ats_ptr_type, statmp511) ; ATSstatic (ats_ptr_type, statmp512) ; /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 2537(line=89, offs=4) -- 2622(line=90, offs=48) */ ATSstaticdec() ats_void_type prerr_loc_error3_0 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp0) ; // ATSlocal_void (tmp1) ; __ats_lab_prerr_loc_error3_0: /* tmp1 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp0 = */ atspre_prerr_string (ATSstrcst(": error(3)")) ; return /* (tmp0) */ ; } /* end of [prerr_loc_error3_0] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 2656(line=93, offs=4) -- 2715(line=93, offs=63) */ ATSstaticdec() ats_void_type prerr_interror_1 () { /* local vardec */ // ATSlocal_void (tmp2) ; __ats_lab_prerr_interror_1: /* tmp2 = */ atspre_prerr_string (ATSstrcst("INTERNAL ERROR (ats_trans3_env)")) ; return /* (tmp2) */ ; } /* end of [prerr_interror_1] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 2720(line=95, offs=4) -- 2832(line=97, offs=4) */ ATSstaticdec() ats_void_type prerr_loc_interror_2 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; __ats_lab_prerr_loc_interror_2: /* tmp4 = */ ATS_2d0_2e2_2e11_2src_2ats_location_2esats__prerr_location (arg0) ; /* tmp3 = */ atspre_prerr_string (ATSstrcst(": INTERNAL ERROR (ats_trans3_env)")) ; return /* (tmp3) */ ; } /* end of [prerr_loc_interror_2] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 2907(line=102, offs=12) -- 2999(line=106, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_prop (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp5) ; ATSlocal (ats_ptr_type, tmp6) ; ATSlocal (ats_ptr_type, tmp7) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_prop: tmp6 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; tmp7 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp7)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp7, atslab_0, arg1) ; tmp5 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp5, atslab_c3str_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp5, atslab_c3str_kind, tmp6) ; ats_selptrset_mac(anairiats_rec_3, tmp5, atslab_c3str_node, tmp7) ; return (tmp5) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3049(line=110, offs=3) -- 3140(line=114, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp8) ; ATSlocal (ats_ptr_type, tmp9) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst: tmp9 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp9)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp9, atslab_0, arg2) ; tmp8 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp8, atslab_c3str_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp8, atslab_c3str_kind, arg1) ; ats_selptrset_mac(anairiats_rec_3, tmp8, atslab_c3str_node, tmp9) ; return (tmp8) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3194(line=117, offs=18) -- 3369(line=123, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_nat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; ATSlocal (ats_ptr_type, tmp12) ; ATSlocal (ats_ptr_type, tmp13) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_nat: tmp11 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_nat_1) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_gte_int_int_bool (arg1, ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_int_0) ; tmp12 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp12)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp12, atslab_0, tmp13) ; tmp10 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp10, atslab_c3str_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp10, atslab_c3str_kind, tmp11) ; ats_selptrset_mac(anairiats_rec_3, tmp10, atslab_c3str_node, tmp12) ; return (tmp10) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_nat] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3398(line=126, offs=18) -- 3532(line=130, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_dec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_dec: tmp15 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmetric_dec_2) ; tmp17 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_metlt (arg1, arg2) ; tmp16 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp16)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp16, atslab_0, tmp17) ; tmp14 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp14, atslab_c3str_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp14, atslab_c3str_kind, tmp15) ; ats_selptrset_mac(anairiats_rec_3, tmp14, atslab_c3str_node, tmp16) ; return (tmp14) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3579(line=133, offs=36) -- 3728(line=137, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_pattern_match_exhaustiveness (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_ptr_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_pattern_match_exhaustiveness: tmp19 = ATS_MALLOC(sizeof(anairiats_sum_5)) ; ((ats_sum_ptr_type)tmp19)->tag = 3 ; ats_selptrset_mac(anairiats_sum_5, tmp19, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_5, tmp19, atslab_1, arg2) ; tmp21 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; tmp20 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp20)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp20, atslab_0, tmp21) ; tmp18 = ATS_MALLOC(sizeof(anairiats_rec_3)) ; ats_selptrset_mac(anairiats_rec_3, tmp18, atslab_c3str_loc, arg0) ; ats_selptrset_mac(anairiats_rec_3, tmp18, atslab_c3str_kind, tmp19) ; ats_selptrset_mac(anairiats_rec_3, tmp18, atslab_c3str_node, tmp20) ; return (tmp18) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_pattern_match_exhaustiveness] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3802(line=142, offs=12) -- 3864(line=144, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_prop (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_prop: tmp23 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp23)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp23, atslab_0, arg1) ; tmp22 = ATS_MALLOC(sizeof(anairiats_rec_6)) ; ats_selptrset_mac(anairiats_rec_6, tmp22, atslab_h3ypo_loc, arg0) ; ats_selptrset_mac(anairiats_rec_6, tmp22, atslab_h3ypo_node, tmp23) ; return (tmp22) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 3910(line=147, offs=12) -- 3988(line=149, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_bind (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp24) ; ATSlocal (ats_ptr_type, tmp25) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_bind: tmp25 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp25)->tag = 1 ; ats_selptrset_mac(anairiats_sum_7, tmp25, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp25, atslab_1, arg2) ; tmp24 = ATS_MALLOC(sizeof(anairiats_rec_6)) ; ats_selptrset_mac(anairiats_rec_6, tmp24, atslab_h3ypo_loc, arg0) ; ats_selptrset_mac(anairiats_rec_6, tmp24, atslab_h3ypo_node, tmp25) ; return (tmp24) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_bind] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 4034(line=152, offs=12) -- 4112(line=154, offs=2) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_eqeq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_eqeq: tmp27 = ATS_MALLOC(sizeof(anairiats_sum_7)) ; ((ats_sum_ptr_type)tmp27)->tag = 2 ; ats_selptrset_mac(anairiats_sum_7, tmp27, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_7, tmp27, atslab_1, arg2) ; tmp26 = ATS_MALLOC(sizeof(anairiats_rec_6)) ; ats_selptrset_mac(anairiats_rec_6, tmp26, atslab_h3ypo_loc, arg0) ; ats_selptrset_mac(anairiats_rec_6, tmp26, atslab_h3ypo_node, tmp27) ; return (tmp26) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_eqeq] */ /* // /home/hwxi/research/Anairiats/src/ats_reference.dats: 1888(line=57, offs=27) -- 1962(line=59, offs=4) */ ATSstaticdec() ats_ptr_type ref_make_elt_04159_ats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; __ats_lab_ref_make_elt_04159_ats_ptr_type: /* ats_ptr_type tmp30 ; */ tmp30 = arg0 ; tmp29 = atspre_ref_make_elt_tsz ((&tmp30), sizeof(ats_ptr_type)) ; return (tmp29) ; } /* end of [ref_make_elt_04159_ats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 4448(line=168, offs=6) -- 4499(line=168, offs=57) */ ATSstaticdec() ats_int_type __ats_fun_12 (atsopt_count_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_int_type, tmp36) ; __ats_lab___ats_fun_12: tmp36 = ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__compare_stamp_stamp (arg0, arg1) ; return (tmp36) ; } /* end of [__ats_fun_12] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2005(line=62, offs=3) -- 2140(line=65, offs=4) */ ATSstaticdec() ats_void_type bst_free_036_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; __ats_lab_bst_free_036_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp44 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp45 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; ATS_FREE(arg0) ; /* tmp46 = */ bst_free_036_atsopt_count_type_2cats_ptr_type (tmp44) ; arg0 = tmp45 ; goto __ats_lab_bst_free_036_atsopt_count_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_1_1: break ; } while (0) ; return /* (tmp43) */ ; } /* end of [bst_free_036_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9704(line=334, offs=13) -- 9797(line=337, offs=4) */ ATSstaticdec() ats_void_type map_cleanup_01911_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; ATSlocal (ats_ptr_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; __ats_lab_map_cleanup_01911_atsopt_count_type_2cats_ptr_type: // tmp41 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp47 = ats_ptrget_mac(ats_ptr_type, tmp41) ; /* tmp42 = */ bst_free_036_atsopt_count_type_2cats_ptr_type (tmp47) ; tmp48 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp41) = tmp48 ; return /* (tmp40) */ ; } /* end of [map_cleanup_01911_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 4592(line=174, offs=29) -- 4705(line=178, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize () { /* local vardec */ // ATSlocal_void (tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_ptr_type, tmp49) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize: tmp38 = atspre_ref_get_view_ptr (statmp34) ; tmp39 = ats_selsin_mac(tmp38, atslab_1) ; tmp49 = ats_ptrget_mac(ats_ptr_type, tmp39) ; /* tmp37 = */ map_cleanup_01911_atsopt_count_type_2cats_ptr_type (tmp49) ; return /* (tmp37) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 4813(line=183, offs=7) -- 5211(line=194, offs=28) */ ATSstaticdec() ats_void_type loop_17 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp51) ; ATSlocal (anairiats_rec_10, tmp52) ; ATSlocal (ats_ptr_type, tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (atsopt_count_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; // ATSlocal_void (tmp59) ; __ats_lab_loop_17: do { /* branch: __ats_lab_2 */ __ats_lab_2_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp52 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_0) ; tmp53 = ats_caselptrlab_mac(anairiats_sum_11, arg1, atslab_1) ; ATS_FREE(arg1) ; tmp55 = ats_select_mac(tmp52, atslab_0) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_stamp_2esats__fprint_stamp (arg0, tmp55) ; /* tmp56 = */ atspre_fprint_string (arg0, ATSstrcst(" -> ")) ; tmp58 = ats_select_mac(tmp52, atslab_1) ; /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__fprint_s2exp (arg0, tmp58) ; /* tmp59 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; arg0 = arg0 ; arg1 = tmp53 ; goto __ats_lab_loop_17 ; // tail call break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_3_1: break ; } while (0) ; return /* (tmp51) */ ; } /* end of [loop_17] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8374(line=278, offs=7) -- 8728(line=288, offs=6) */ ATSstaticdec() ats_ptr_type aux_20 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp66) ; ATSlocal (atsopt_count_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; ATSlocal (ats_ptr_type, tmp70) ; ATSlocal (anairiats_rec_10, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_ptr_type, tmp73) ; ATSlocal (ats_ptr_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; __ats_lab_aux_20: do { /* branch: __ats_lab_4 */ __ats_lab_4_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp67 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp68 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp69 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp70 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; tmp71.atslab_0 = tmp67 ; tmp71.atslab_1 = tmp68 ; tmp72 = ats_ptrget_mac(ats_ptr_type, tmp69) ; tmp75 = ats_ptrget_mac(ats_ptr_type, tmp70) ; tmp74 = aux_20 (tmp75, arg1) ; tmp73 = ATS_MALLOC(sizeof(anairiats_sum_11)) ; ats_selptrset_mac(anairiats_sum_11, tmp73, atslab_0, tmp71) ; ats_selptrset_mac(anairiats_sum_11, tmp73, atslab_1, tmp74) ; arg0 = tmp72 ; arg1 = tmp73 ; goto __ats_lab_aux_20 ; // tail call break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_5_1: tmp66 = arg1 ; break ; } while (0) ; return (tmp66) ; } /* end of [aux_20] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 8278(line=274, offs=22) -- 8777(line=291, offs=4) */ ATSstaticdec() ats_ptr_type bst_list_inf_0132_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp65) ; ATSlocal (ats_ptr_type, tmp76) ; __ats_lab_bst_list_inf_0132_atsopt_count_type_2cats_ptr_type: tmp76 = (ats_sum_ptr_type)0 ; tmp65 = aux_20 (arg0, tmp76) ; return (tmp65) ; } /* end of [bst_list_inf_0132_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 11607(line=396, offs=14) -- 11717(line=401, offs=4) */ ATSstaticdec() ats_ptr_type map_list_inf_01916_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp63) ; ATSlocal (ats_ptr_type, tmp64) ; ATSlocal (ats_ptr_type, tmp77) ; __ats_lab_map_list_inf_01916_atsopt_count_type_2cats_ptr_type: // tmp64 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp77 = ats_ptrget_mac(ats_ptr_type, tmp64) ; tmp63 = bst_list_inf_0132_atsopt_count_type_2cats_ptr_type (tmp77) ; return (tmp63) ; } /* end of [map_list_inf_01916_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 4787(line=182, offs=7) -- 5378(line=201, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap (ats_ref_type arg0) { /* local vardec */ // ATSlocal_void (tmp50) ; ATSlocal (ats_ptr_type, tmp60) ; ATSlocal (ats_ptr_type, tmp61) ; ATSlocal (ats_ptr_type, tmp62) ; ATSlocal (ats_ptr_type, tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap: tmp60 = atspre_ref_get_view_ptr (statmp34) ; tmp61 = ats_selsin_mac(tmp60, atslab_1) ; tmp78 = ats_ptrget_mac(ats_ptr_type, tmp61) ; tmp62 = map_list_inf_01916_atsopt_count_type_2cats_ptr_type (tmp78) ; /* tmp50 = */ loop_17 (arg0, tmp62) ; return /* (tmp50) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 5449(line=204, offs=24) -- 5621(line=209, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_the_s2varbindmap () { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_the_s2varbindmap: tmp80 = atspre_stdout_get () ; tmp81 = ats_selsin_mac(tmp80, atslab_1) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap (tmp81) ; /* tmp79 = */ atspre_stdout_view_set () ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__print_the_s2varbindmap] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 5691(line=212, offs=24) -- 5863(line=217, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_the_s2varbindmap () { /* local vardec */ // ATSlocal_void (tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_the_s2varbindmap: tmp84 = atspre_stderr_get () ; tmp85 = ats_selsin_mac(tmp84, atslab_1) ; /* tmp86 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__fprint_the_s2varbindmap (tmp85) ; /* tmp83 = */ atspre_stderr_view_set () ; return /* (tmp83) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__prerr_the_s2varbindmap] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2219(line=70, offs=18) -- 2335(line=71, offs=71) */ ATSstaticdec() ats_int_type bst_size_040_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_int_type, tmp117) ; ATSlocal (ats_int_type, tmp118) ; __ats_lab_bst_size_040_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_8 */ __ats_lab_8_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_9_0 ; } __ats_lab_8_1: tmp118 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp117 = tmp118 ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp117 = 0 ; break ; } while (0) ; return (tmp117) ; } /* end of [bst_size_040_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 2614(line=83, offs=33) -- 3587(line=109, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp103) ; ATSlocal (ats_ptr_type, tmp104) ; ATSlocal (atsopt_count_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; ATSlocal (ats_ptr_type, tmp107) ; ATSlocal (ats_bool_type, tmp108) ; ATSlocal (ats_int_type, tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; ATSlocal (ats_ptr_type, tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; ATSlocal (ats_int_type, tmp115) ; ATSlocal (ats_int_type, tmp116) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; ATSlocal (ats_int_type, tmp121) ; ATSlocal (ats_int_type, tmp122) ; ATSlocal (ats_ptr_type, tmp123) ; ATSlocal (ats_ptr_type, tmp124) ; ATSlocal (ats_ptr_type, tmp125) ; ATSlocal (ats_ptr_type, tmp126) ; ATSlocal (ats_ptr_type, tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_int_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; ATSlocal (ats_ptr_type, tmp131) ; ATSlocal (ats_int_type, tmp132) ; ATSlocal (ats_int_type, tmp133) ; ATSlocal (ats_ptr_type, tmp134) ; ATSlocal (ats_ptr_type, tmp135) ; __ats_lab_bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_7 */ __ats_lab_7_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_7_1: tmp104 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp105 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp106 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp107 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; tmp109 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg3) (arg1, tmp105) ; tmp108 = atspre_ilte (tmp109, 0) ; if (tmp108) { tmp111 = ats_ptrget_mac(ats_ptr_type, tmp106) ; tmp110 = bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type (tmp111, arg1, arg2, arg3) ; // if (tmp110 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp112 = &ats_caselptrlab_mac(anairiats_sum_9, tmp110, atslab_0) ; tmp113 = &ats_caselptrlab_mac(anairiats_sum_9, tmp110, atslab_3) ; tmp114 = &ats_caselptrlab_mac(anairiats_sum_9, tmp110, atslab_4) ; tmp115 = ats_ptrget_mac(ats_int_type, tmp104) ; tmp119 = ats_ptrget_mac(ats_ptr_type, tmp113) ; tmp116 = bst_size_040_atsopt_count_type_2cats_ptr_type (tmp119) ; tmp120 = ats_ptrget_mac(ats_ptr_type, tmp114) ; ats_ptrget_mac(ats_ptr_type, tmp106) = tmp120 ; tmp121 = atspre_isub (tmp115, tmp116) ; ats_ptrget_mac(ats_int_type, tmp104) = tmp121 ; ats_ptrget_mac(ats_ptr_type, tmp114) = arg0 ; tmp122 = atspre_iadd (tmp115, 1) ; ats_ptrget_mac(ats_int_type, tmp112) = tmp122 ; tmp103 = tmp110 ; } else { tmp124 = ats_ptrget_mac(ats_ptr_type, tmp107) ; tmp123 = bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type (tmp124, arg1, arg2, arg3) ; // if (tmp123 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp125 = &ats_caselptrlab_mac(anairiats_sum_9, tmp123, atslab_0) ; tmp126 = &ats_caselptrlab_mac(anairiats_sum_9, tmp123, atslab_3) ; tmp127 = &ats_caselptrlab_mac(anairiats_sum_9, tmp123, atslab_4) ; tmp128 = ats_ptrget_mac(ats_int_type, tmp104) ; tmp130 = ats_ptrget_mac(ats_ptr_type, tmp127) ; tmp129 = bst_size_040_atsopt_count_type_2cats_ptr_type (tmp130) ; tmp131 = ats_ptrget_mac(ats_ptr_type, tmp126) ; ats_ptrget_mac(ats_ptr_type, tmp107) = tmp131 ; tmp132 = atspre_isub (tmp128, tmp129) ; ats_ptrget_mac(ats_int_type, tmp104) = tmp132 ; ats_ptrget_mac(ats_ptr_type, tmp126) = arg0 ; tmp133 = atspre_iadd (tmp128, 1) ; ats_ptrget_mac(ats_int_type, tmp125) = tmp133 ; tmp103 = tmp123 ; } /* end of [if] */ break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp134 = (ats_sum_ptr_type)0 ; tmp135 = (ats_sum_ptr_type)0 ; tmp103 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp103, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_9, tmp103, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp103, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_9, tmp103, atslab_3, tmp134) ; ats_selptrset_mac(anairiats_sum_9, tmp103, atslab_4, tmp135) ; break ; } while (0) ; return (tmp103) ; } /* end of [bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 4580(line=147, offs=33) -- 5265(line=168, offs=4) */ ATSstaticdec() ats_ptr_type bst_insert_random_079_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (atsopt_count_type, tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; ATSlocal (ats_ptr_type, tmp100) ; ATSlocal (ats_bool_type, tmp101) ; ATSlocal (ats_int_type, tmp102) ; ATSlocal (ats_bool_type, tmp136) ; ATSlocal (ats_int_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; ATSlocal (ats_ptr_type, tmp139) ; ATSlocal (ats_int_type, tmp140) ; ATSlocal (ats_int_type, tmp141) ; ATSlocal (ats_ptr_type, tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; ATSlocal (ats_ptr_type, tmp147) ; __ats_lab_bst_insert_random_079_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_6 */ __ats_lab_6_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_11_0 ; } __ats_lab_6_1: tmp97 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp98 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp99 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp100 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; tmp102 = ats_ptrget_mac(ats_int_type, tmp97) ; tmp101 = atsopt_map_lin_dice (1, tmp102) ; if (tmp101) { tmp96 = bst_insert_atroot_045_atsopt_count_type_2cats_ptr_type (arg0, arg1, arg2, arg3) ; } else { tmp137 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg3) (arg1, tmp98) ; tmp136 = atspre_ilte (tmp137, 0) ; if (tmp136) { tmp139 = ats_ptrget_mac(ats_ptr_type, tmp99) ; tmp138 = bst_insert_random_079_atsopt_count_type_2cats_ptr_type (tmp139, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp99) = tmp138 ; tmp141 = ats_ptrget_mac(ats_int_type, tmp97) ; tmp140 = atspre_iadd (tmp141, 1) ; ats_ptrget_mac(ats_int_type, tmp97) = tmp140 ; tmp96 = arg0 ; } else { tmp143 = ats_ptrget_mac(ats_ptr_type, tmp100) ; tmp142 = bst_insert_random_079_atsopt_count_type_2cats_ptr_type (tmp143, arg1, arg2, arg3) ; ats_ptrget_mac(ats_ptr_type, tmp100) = tmp142 ; tmp145 = ats_ptrget_mac(ats_int_type, tmp97) ; tmp144 = atspre_iadd (tmp145, 1) ; ats_ptrget_mac(ats_int_type, tmp97) = tmp144 ; tmp96 = arg0 ; } /* end of [if] */ } /* end of [if] */ break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_11_1: tmp146 = (ats_sum_ptr_type)0 ; tmp147 = (ats_sum_ptr_type)0 ; tmp96 = ATS_MALLOC(sizeof(anairiats_sum_9)) ; ats_selptrset_mac(anairiats_sum_9, tmp96, atslab_0, 1) ; ats_selptrset_mac(anairiats_sum_9, tmp96, atslab_1, arg1) ; ats_selptrset_mac(anairiats_sum_9, tmp96, atslab_2, arg2) ; ats_selptrset_mac(anairiats_sum_9, tmp96, atslab_3, tmp146) ; ats_selptrset_mac(anairiats_sum_9, tmp96, atslab_4, tmp147) ; break ; } while (0) ; return (tmp96) ; } /* end of [bst_insert_random_079_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10043(line=350, offs=12) -- 10162(line=353, offs=4) */ ATSstaticdec() ats_void_type map_insert_01912_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; ATSlocal (ats_ptr_type, tmp148) ; __ats_lab_map_insert_01912_atsopt_count_type_2cats_ptr_type: // tmp93 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp94 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp148 = ats_ptrget_mac(ats_ptr_type, tmp94) ; tmp95 = bst_insert_random_079_atsopt_count_type_2cats_ptr_type (tmp148, arg1, arg2, tmp93) ; ats_ptrget_mac(ats_ptr_type, tmp94) = tmp95 ; return /* (tmp92) */ ; } /* end of [map_insert_01912_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 5935(line=222, offs=22) -- 6966(line=249, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp87) ; ATSlocal (atsopt_count_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; ATSlocal (ats_ptr_type, tmp90) ; // ATSlocal_void (tmp91) ; ATSlocal (ats_ptr_type, tmp149) ; ATSlocal (ats_ptr_type, tmp150) ; ATSlocal (ats_ptr_type, tmp151) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_add: tmp88 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (arg0) ; tmp89 = atspre_ref_get_view_ptr (statmp34) ; tmp90 = ats_selsin_mac(tmp89, atslab_1) ; tmp149 = ats_ptrget_mac(ats_ptr_type, tmp90) ; /* tmp91 = */ map_insert_01912_atsopt_count_type_2cats_ptr_type (tmp149, tmp88, arg1) ; tmp151 = ats_ptrget_mac(ats_ptr_type, statmp28) ; tmp150 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp150, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp150, atslab_1, tmp151) ; ats_ptrget_mac(ats_ptr_type, statmp28) = tmp150 ; return /* (tmp87) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_add] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 3687(line=114, offs=26) -- 4129(line=123, offs=4) */ ATSstaticdec() ats_ptr_type bst_search_068_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp159) ; ATSlocal (atsopt_count_type, tmp160) ; ATSlocal (ats_ptr_type, tmp161) ; ATSlocal (ats_ptr_type, tmp162) ; ATSlocal (ats_ptr_type, tmp163) ; ATSlocal (ats_int_type, tmp164) ; ATSlocal (ats_ptr_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; __ats_lab_bst_search_068_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_12 */ __ats_lab_12_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_12_1: tmp160 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp161 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp162 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp163 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; tmp164 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg2) (arg1, tmp160) ; do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (tmp164 != -1) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp165 = ats_ptrget_mac(ats_ptr_type, tmp162) ; arg0 = tmp165 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_atsopt_count_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: if (tmp164 != 1) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp166 = ats_ptrget_mac(ats_ptr_type, tmp163) ; arg0 = tmp166 ; arg1 = arg1 ; arg2 = arg2 ; goto __ats_lab_bst_search_068_atsopt_count_type_2cats_ptr_type ; // tail call break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (tmp164 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: tmp159 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp159, atslab_0, tmp161) ; break ; } while (0) ; break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp159 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp159) ; } /* end of [bst_search_068_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 9876(line=342, offs=12) -- 9988(line=347, offs=4) */ ATSstaticdec() ats_ptr_type map_search_01914_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp156) ; ATSlocal (ats_ptr_type, tmp157) ; ATSlocal (ats_ptr_type, tmp158) ; ATSlocal (ats_ptr_type, tmp167) ; __ats_lab_map_search_01914_atsopt_count_type_2cats_ptr_type: // tmp157 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp158 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp167 = ats_ptrget_mac(ats_ptr_type, tmp158) ; tmp156 = bst_search_068_atsopt_count_type_2cats_ptr_type (tmp167, arg1, tmp157) ; return (tmp156) ; } /* end of [map_search_01914_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 7033(line=252, offs=23) -- 7291(line=262, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp152) ; ATSlocal (atsopt_count_type, tmp153) ; ATSlocal (ats_ptr_type, tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp168) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find: tmp153 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (arg0) ; tmp154 = atspre_ref_get_view_ptr (statmp34) ; tmp155 = ats_selsin_mac(tmp154, atslab_1) ; tmp168 = ats_ptrget_mac(ats_ptr_type, tmp155) ; tmp152 = map_search_01914_atsopt_count_type_2cats_ptr_type (tmp168, tmp153) ; return (tmp152) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 5380(line=174, offs=25) -- 6039(line=193, offs=4) */ ATSstaticdec() ats_ptr_type bst_join_random_088_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; ATSlocal (ats_ptr_type, tmp204) ; ATSlocal (ats_ptr_type, tmp205) ; ATSlocal (ats_int_type, tmp206) ; ATSlocal (ats_int_type, tmp207) ; ATSlocal (ats_int_type, tmp208) ; ATSlocal (ats_bool_type, tmp209) ; ATSlocal (ats_int_type, tmp210) ; ATSlocal (ats_int_type, tmp211) ; ATSlocal (ats_ptr_type, tmp212) ; ATSlocal (ats_ptr_type, tmp213) ; ATSlocal (ats_ptr_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; __ats_lab_bst_join_random_088_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_25_0 ; } __ats_lab_22_1: tmp202 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp203 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; do { /* branch: __ats_lab_23 */ __ats_lab_23_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_24_0 ; } __ats_lab_23_1: tmp204 = &ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_0) ; tmp205 = &ats_caselptrlab_mac(anairiats_sum_9, arg1, atslab_3) ; tmp207 = ats_ptrget_mac(ats_int_type, tmp202) ; tmp208 = ats_ptrget_mac(ats_int_type, tmp204) ; tmp206 = atspre_iadd (tmp207, tmp208) ; tmp210 = ats_ptrget_mac(ats_int_type, tmp202) ; tmp211 = ats_ptrget_mac(ats_int_type, tmp204) ; tmp209 = atsopt_map_lin_dice (tmp210, tmp211) ; if (tmp209) { tmp213 = ats_ptrget_mac(ats_ptr_type, tmp203) ; tmp212 = bst_join_random_088_atsopt_count_type_2cats_ptr_type (tmp213, arg1) ; ats_ptrget_mac(ats_ptr_type, tmp203) = tmp212 ; ats_ptrget_mac(ats_int_type, tmp202) = tmp206 ; tmp201 = arg0 ; } else { tmp215 = ats_ptrget_mac(ats_ptr_type, tmp205) ; tmp214 = bst_join_random_088_atsopt_count_type_2cats_ptr_type (arg0, tmp215) ; ats_ptrget_mac(ats_ptr_type, tmp205) = tmp214 ; ats_ptrget_mac(ats_int_type, tmp204) = tmp206 ; tmp201 = arg1 ; } /* end of [if] */ break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_24_1: tmp201 = arg0 ; break ; } while (0) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_25_1: tmp201 = arg1 ; break ; } while (0) ; return (tmp201) ; } /* end of [bst_join_random_088_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 6466(line=208, offs=30) -- 7610(line=243, offs=4) */ ATSstaticdec() ats_ptr_type bst_remove_random_0102_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp181) ; ATSlocal (ats_ptr_type, tmp182) ; ATSlocal (atsopt_count_type, tmp183) ; ATSlocal (ats_ptr_type, tmp184) ; ATSlocal (ats_ptr_type, tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_int_type, tmp187) ; ATSlocal (ats_ptr_type, tmp188) ; ATSlocal (ats_ptr_type, tmp189) ; ATSlocal (ats_ptr_type, tmp190) ; ATSlocal (ats_int_type, tmp191) ; ATSlocal (ats_int_type, tmp192) ; ATSlocal (ats_int_type, tmp193) ; ATSlocal (ats_ptr_type, tmp194) ; ATSlocal (ats_ptr_type, tmp195) ; ATSlocal (ats_ptr_type, tmp196) ; ATSlocal (ats_int_type, tmp197) ; ATSlocal (ats_int_type, tmp198) ; ATSlocal (ats_int_type, tmp199) ; ATSlocal (ats_ptr_type, tmp200) ; ATSlocal (ats_ptr_type, tmp216) ; ATSlocal (ats_ptr_type, tmp217) ; ATSlocal (ats_ptr_type, tmp218) ; ATSlocal (ats_ptr_type, tmp219) ; __ats_lab_bst_remove_random_0102_atsopt_count_type_2cats_ptr_type: do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_26_0 ; } __ats_lab_18_1: tmp182 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_0) ; tmp183 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_1) ; tmp184 = ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_2) ; tmp185 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_3) ; tmp186 = &ats_caselptrlab_mac(anairiats_sum_9, arg0, atslab_4) ; tmp187 = ((ats_int_type(*)(atsopt_count_type, atsopt_count_type))arg4) (arg1, tmp183) ; do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (tmp187 != -1) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp189 = ats_ptrget_mac(ats_ptr_type, tmp185) ; tmp188 = bst_remove_random_0102_atsopt_count_type_2cats_ptr_type (tmp189, arg1, arg2, arg3, arg4) ; tmp190 = ats_selsin_mac(tmp188, atslab_2) ; tmp192 = ats_ptrget_mac(ats_int_type, tmp182) ; tmp193 = ats_ptrget_mac(ats_int_type, arg2) ; tmp191 = atspre_isub (tmp192, tmp193) ; ats_ptrget_mac(ats_int_type, tmp182) = tmp191 ; ats_ptrget_mac(ats_ptr_type, tmp185) = tmp190 ; tmp181 = arg0 ; break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: if (tmp187 != 1) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp195 = ats_ptrget_mac(ats_ptr_type, tmp186) ; tmp194 = bst_remove_random_0102_atsopt_count_type_2cats_ptr_type (tmp195, arg1, arg2, arg3, arg4) ; tmp196 = ats_selsin_mac(tmp194, atslab_2) ; tmp198 = ats_ptrget_mac(ats_int_type, tmp182) ; tmp199 = ats_ptrget_mac(ats_int_type, arg2) ; tmp197 = atspre_isub (tmp198, tmp199) ; ats_ptrget_mac(ats_int_type, tmp182) = tmp197 ; ats_ptrget_mac(ats_ptr_type, tmp186) = tmp196 ; tmp181 = arg0 ; break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (tmp187 != 0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: tmp216 = ats_ptrget_mac(ats_ptr_type, tmp185) ; tmp217 = ats_ptrget_mac(ats_ptr_type, tmp186) ; tmp200 = bst_join_random_088_atsopt_count_type_2cats_ptr_type (tmp216, tmp217) ; ats_ptrget_mac(ats_int_type, arg2) = 1 ; tmp218 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp218, atslab_0, tmp184) ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp218 ; ATS_FREE(arg0) ; tmp181 = tmp200 ; break ; } while (0) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_26_1: ats_ptrget_mac(ats_int_type, arg2) = 0 ; tmp219 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, arg3) = tmp219 ; tmp181 = arg0 ; break ; } while (0) ; return (tmp181) ; } /* end of [bst_remove_random_0102_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_map_lin.dats: 10217(line=356, offs=12) -- 10550(line=365, offs=4) */ ATSstaticdec() ats_ptr_type map_remove_01913_atsopt_count_type_2cats_ptr_type (ats_ptr_type arg0, atsopt_count_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp175) ; ATSlocal (ats_ptr_type, tmp176) ; ATSlocal (ats_ptr_type, tmp177) ; ATSlocal (ats_int_type, tmp178) ; ATSlocal (ats_ptr_type, tmp179) ; ATSlocal (ats_ptr_type, tmp180) ; ATSlocal (ats_ptr_type, tmp220) ; ATSlocal (ats_ptr_type, tmp221) ; __ats_lab_map_remove_01913_atsopt_count_type_2cats_ptr_type: // tmp176 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp177 = &ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; /* ats_int_type tmp178 ; */ /* ats_ptr_type tmp179 ; */ tmp220 = ats_ptrget_mac(ats_ptr_type, tmp177) ; tmp180 = bst_remove_random_0102_atsopt_count_type_2cats_ptr_type (tmp220, arg1, (&tmp178), (&tmp179), tmp176) ; tmp221 = ats_selsin_mac(tmp180, atslab_2) ; ats_ptrget_mac(ats_ptr_type, tmp177) = tmp221 ; tmp175 = tmp179 ; return (tmp175) ; } /* end of [map_remove_01913_atsopt_count_type_2cats_ptr_type] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 7500(line=271, offs=7) -- 7913(line=281, offs=24) */ ATSstaticdec() ats_void_type aux_32 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; ATSlocal (atsopt_count_type, tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp222) ; __ats_lab_aux_32: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_29_0 ; } __ats_lab_17_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp172 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp173 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_stamp (tmp171) ; tmp222 = ats_ptrget_mac(ats_ptr_type, arg0) ; tmp174 = map_remove_01913_atsopt_count_type_2cats_ptr_type (tmp222, tmp173) ; do { /* branch: __ats_lab_27 */ __ats_lab_27_0: if (tmp174 != (ats_sum_ptr_type)0) { goto __ats_lab_28_0 ; } __ats_lab_27_1: break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: // if (tmp174 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_28_1: ATS_FREE(tmp174) ; break ; } while (0) ; arg0 = arg0 ; arg1 = tmp172 ; goto __ats_lab_aux_32 ; // tail call break ; /* branch: __ats_lab_29 */ __ats_lab_29_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_29_1: break ; } while (0) ; return /* (tmp170) */ ; } /* end of [aux_32] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 7358(line=265, offs=22) -- 8515(line=303, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop () { /* local vardec */ // ATSlocal_void (tmp169) ; ATSlocal (ats_ptr_type, tmp224) ; ATSlocal (ats_ptr_type, tmp225) ; ATSlocal (ats_ptr_type, tmp226) ; ATSlocal (ats_ptr_type, tmp227) ; ATSlocal (ats_ptr_type, tmp228) ; // ATSlocal_void (tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; // ATSlocal_void (tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop: tmp224 = ats_ptrget_mac(ats_ptr_type, statmp32) ; do { /* branch: __ats_lab_30 */ __ats_lab_30_0: if (tmp224 == (ats_sum_ptr_type)0) { goto __ats_lab_31_0 ; } __ats_lab_30_1: tmp225 = ats_caselptrlab_mac(anairiats_sum_8, tmp224, atslab_0) ; tmp226 = ats_caselptrlab_mac(anairiats_sum_8, tmp224, atslab_1) ; tmp227 = atspre_ref_get_view_ptr (statmp34) ; tmp228 = ats_selsin_mac(tmp227, atslab_1) ; tmp230 = ats_ptrget_mac(ats_ptr_type, statmp28) ; /* tmp229 = */ aux_32 (tmp228, tmp230) ; ats_ptrget_mac(ats_ptr_type, statmp28) = tmp225 ; ats_ptrget_mac(ats_ptr_type, statmp32) = tmp226 ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: // if (tmp224 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_31_1: /* tmp231 = */ prerr_interror_1 () ; /* tmp232 = */ atspre_prerr_string (ATSstrcst(": the_s2varbindmap_pop: [s2varbind_svs_lst] is empty.")) ; /* tmp233 = */ atspre_prerr_newline () ; /* tmp169 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp169) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 8578(line=306, offs=23) -- 8715(line=311, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push () { /* local vardec */ // ATSlocal_void (tmp234) ; ATSlocal (ats_ptr_type, tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; ATSlocal (ats_ptr_type, tmp238) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push: tmp235 = ats_ptrget_mac(ats_ptr_type, statmp28) ; tmp236 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, statmp28) = tmp236 ; tmp238 = ats_ptrget_mac(ats_ptr_type, statmp32) ; tmp237 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp237, atslab_0, tmp235) ; ats_selptrset_mac(anairiats_sum_8, tmp237, atslab_1, tmp238) ; ats_ptrget_mac(ats_ptr_type, statmp32) = tmp237 ; return /* (tmp234) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 9007(line=327, offs=22) -- 9077(line=329, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp242) ; ATSlocal (ats_ptr_type, tmp243) ; ATSlocal (ats_ptr_type, tmp244) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add: tmp244 = ats_ptrget_mac(ats_ptr_type, statmp239) ; tmp243 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_add (tmp244, arg0) ; ats_ptrget_mac(ats_ptr_type, statmp239) = tmp243 ; return /* (tmp242) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 9110(line=332, offs=22) -- 9128(line=332, offs=40) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp245) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get: tmp245 = ats_ptrget_mac(ats_ptr_type, statmp239) ; return (tmp245) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 9166(line=335, offs=27) -- 9352(line=341, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev () { /* local vardec */ ATSlocal (ats_ptr_type, tmp246) ; ATSlocal (ats_ptr_type, tmp247) ; ATSlocal (ats_ptr_type, tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev: tmp247 = atspre_ref_get_view_ptr (statmp240) ; tmp248 = ats_selsin_mac(tmp247, atslab_1) ; tmp249 = ats_ptrget_mac(ats_ptr_type, tmp248) ; do { /* branch: __ats_lab_32 */ __ats_lab_32_0: if (tmp249 == (ats_sum_ptr_type)0) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp250 = ats_caselptrlab_mac(anairiats_sum_8, tmp249, atslab_0) ; tmp246 = tmp250 ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: // if (tmp249 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_33_1: tmp246 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil ; break ; } while (0) ; return (tmp246) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 9423(line=344, offs=22) -- 9869(line=360, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_pop () { /* local vardec */ // ATSlocal_void (tmp251) ; ATSlocal (ats_int_type, tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; ATSlocal (ats_ptr_type, tmp254) ; ATSlocal (ats_ptr_type, tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_bool_type, tmp259) ; // ATSlocal_void (tmp260) ; // ATSlocal_void (tmp261) ; // ATSlocal_void (tmp262) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_pop: /* ats_int_type tmp252 ; */ tmp252 = 0 ; tmp253 = atspre_ref_get_view_ptr (statmp240) ; tmp254 = ats_selsin_mac(tmp253, atslab_1) ; tmp256 = ats_ptrget_mac(ats_ptr_type, tmp254) ; do { /* branch: __ats_lab_34 */ __ats_lab_34_0: if (tmp256 == (ats_sum_ptr_type)0) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_8, tmp256, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_8, tmp256, atslab_1) ; ATS_FREE(tmp256) ; ats_ptrget_mac(ats_ptr_type, statmp239) = tmp257 ; ats_ptrget_mac(ats_ptr_type, tmp254) = tmp258 ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: // if (tmp256 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_35_1: tmp252 = 1 ; break ; } while (0) ; tmp259 = atspre_gt_int_int (tmp252, 0) ; if (tmp259) { /* tmp260 = */ prerr_interror_1 () ; /* tmp261 = */ atspre_prerr_string (ATSstrcst(": the_s2Varset_env_pop")) ; /* tmp262 = */ atspre_prerr_newline () ; /* tmp251 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp251) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_pop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 9936(line=363, offs=23) -- 10062(line=367, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_push () { /* local vardec */ // ATSlocal_void (tmp263) ; ATSlocal (ats_ptr_type, tmp264) ; ATSlocal (ats_ptr_type, tmp265) ; ATSlocal (ats_ptr_type, tmp266) ; ATSlocal (ats_ptr_type, tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_push: tmp264 = atspre_ref_get_view_ptr (statmp240) ; tmp265 = ats_selsin_mac(tmp264, atslab_1) ; tmp267 = ats_ptrget_mac(ats_ptr_type, statmp239) ; tmp268 = ats_ptrget_mac(ats_ptr_type, tmp265) ; tmp266 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp266, atslab_0, tmp267) ; ats_selptrset_mac(anairiats_sum_8, tmp266, atslab_1, tmp268) ; ats_ptrget_mac(ats_ptr_type, tmp265) = tmp266 ; return /* (tmp263) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_push] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 10146(line=373, offs=5) -- 11029(line=395, offs=4) */ ATSstaticdec() ats_ptr_type s2lablst_is_prefix_42 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp269) ; ATSlocal (ats_ptr_type, tmp270) ; ATSlocal (ats_ptr_type, tmp271) ; ATSlocal (ats_ptr_type, tmp272) ; ATSlocal (ats_ptr_type, tmp273) ; ATSlocal (ats_ptr_type, tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_bool_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; ATSlocal (ats_bool_type, tmp280) ; ATSlocal (ats_bool_type, tmp281) ; __ats_lab_s2lablst_is_prefix_42: do { /* branch: __ats_lab_36 */ __ats_lab_36_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_44_0 ; } __ats_lab_36_1: tmp270 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp271 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp270)->tag != 2) { goto __ats_lab_43_0 ; } __ats_lab_37_1: tmp272 = ats_caselptrlab_mac(anairiats_sum_7, tmp270, atslab_0) ; tmp273 = ats_caselptrlab_mac(anairiats_sum_7, tmp270, atslab_1) ; do { /* branch: __ats_lab_38 */ __ats_lab_38_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_42_0 ; } __ats_lab_38_1: tmp274 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp275 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; do { /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp274)->tag != 0) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp276 = ats_caselptrlab_mac(anairiats_sum_4, tmp274, atslab_0) ; tmp277 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp272, tmp276) ; if (tmp277) { arg0 = tmp271 ; arg1 = tmp275 ; goto __ats_lab_s2lablst_is_prefix_42 ; // tail call } else { tmp269 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp274)->tag != 2) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp278 = ats_caselptrlab_mac(anairiats_sum_7, tmp274, atslab_0) ; tmp279 = ats_caselptrlab_mac(anairiats_sum_7, tmp274, atslab_1) ; tmp280 = ATS_2d0_2e2_2e11_2src_2ats_label_2esats__eq_label_label (tmp272, tmp278) ; if (tmp280) { tmp281 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp273, tmp279) ; if (tmp281) { arg0 = tmp271 ; arg1 = tmp275 ; goto __ats_lab_s2lablst_is_prefix_42 ; // tail call } else { tmp269 = (ats_sum_ptr_type)0 ; } /* end of [if] */ } else { tmp269 = (ats_sum_ptr_type)0 ; } /* end of [if] */ break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: __ats_lab_41_1: tmp269 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_42_1: tmp269 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: __ats_lab_43_1: tmp269 = (ats_sum_ptr_type)0 ; break ; } while (0) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_44_1: tmp269 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp269, atslab_0, arg1) ; break ; } while (0) ; return (tmp269) ; } /* end of [s2lablst_is_prefix_42] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 11086(line=399, offs=4) -- 13543(line=463, offs=4) */ ATSstaticdec() ats_void_type d2var_fin_check_43 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp282) ; ATSlocal (ats_ptr_type, tmp283) ; ATSlocal (ats_ptr_type, tmp284) ; ATSlocal (ats_ptr_type, tmp285) ; ATSlocal (ats_ptr_type, tmp286) ; // ATSlocal_void (tmp287) ; // ATSlocal_void (tmp288) ; ATSlocal (ats_ptr_type, tmp289) ; // ATSlocal_void (tmp290) ; ATSlocal (ats_ptr_type, tmp291) ; ATSlocal (ats_ptr_type, tmp292) ; // ATSlocal_void (tmp293) ; // ATSlocal_void (tmp294) ; ATSlocal (ats_ptr_type, tmp295) ; // ATSlocal_void (tmp296) ; ATSlocal (ats_ptr_type, tmp297) ; // ATSlocal_void (tmp298) ; ATSlocal (ats_bool_type, tmp299) ; // ATSlocal_void (tmp300) ; // ATSlocal_void (tmp301) ; // ATSlocal_void (tmp302) ; // ATSlocal_void (tmp303) ; // ATSlocal_void (tmp304) ; // ATSlocal_void (tmp305) ; // ATSlocal_void (tmp306) ; ATSlocal (ats_bool_type, tmp307) ; ATSlocal (ats_int_type, tmp308) ; ATSlocal (ats_ptr_type, tmp309) ; ATSlocal (ats_ptr_type, tmp310) ; // ATSlocal_void (tmp311) ; // ATSlocal_void (tmp312) ; // ATSlocal_void (tmp313) ; // ATSlocal_void (tmp314) ; // ATSlocal_void (tmp315) ; __ats_lab_d2var_fin_check_43: tmp283 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg1) ; do { /* branch: __ats_lab_45 */ __ats_lab_45_0: if (tmp283 == (ats_sum_ptr_type)0) { goto __ats_lab_50_0 ; } __ats_lab_45_1: tmp284 = ats_caselptrlab_mac(anairiats_sum_12, tmp283, atslab_0) ; tmp285 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin (arg1) ; do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (((ats_sum_ptr_type)tmp285)->tag != 2) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp286 = ats_caselptrlab_mac(anairiats_sum_4, tmp285, atslab_0) ; /* tmp287 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp288 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp284, tmp286) ; tmp289 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp289)->tag = 4 ; ats_selptrset_mac(anairiats_sum_13, tmp289, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp289, atslab_1, tmp284) ; ats_selptrset_mac(anairiats_sum_13, tmp289, atslab_2, tmp286) ; /* tmp290 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp289) ; tmp291 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp291, atslab_0, tmp286) ; /* tmp282 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp291) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: if (((ats_sum_ptr_type)tmp285)->tag != 3) { goto __ats_lab_48_0 ; } __ats_lab_47_1: tmp292 = ats_caselptrlab_mac(anairiats_sum_4, tmp285, atslab_0) ; /* tmp293 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp294 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp284, tmp292) ; tmp295 = ATS_MALLOC(sizeof(anairiats_sum_13)) ; ((ats_sum_ptr_type)tmp295)->tag = 4 ; ats_selptrset_mac(anairiats_sum_13, tmp295, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_13, tmp295, atslab_1, tmp284) ; ats_selptrset_mac(anairiats_sum_13, tmp295, atslab_2, tmp292) ; /* tmp296 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp295) ; tmp297 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp297, atslab_0, tmp292) ; /* tmp282 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp297) ; break ; /* branch: __ats_lab_48 */ __ats_lab_48_0: if (((ats_sum_ptr_type)tmp285)->tag != 0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (((ats_sum_ptr_type)tmp285)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: tmp299 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_linear (tmp284) ; if (tmp299) { /* tmp300 = */ prerr_loc_error3_0 (arg0) ; /* tmp301 = */ atspre_prerr_string (ATSstrcst(": the linear dynamic variable [")) ; /* tmp302 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp303 = */ atspre_prerr_string (ATSstrcst("] needs to be consumed but it is preserved with the type [")) ; /* tmp304 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp284) ; /* tmp305 = */ atspre_prerr_string (ATSstrcst("] instead.")) ; /* tmp306 = */ atspre_prerr_newline () ; /* tmp298 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp308 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (arg1) ; tmp307 = atspre_gte_int_int (tmp308, 0) ; if (tmp307) { tmp309 = (ats_sum_ptr_type)0 ; /* tmp282 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg1, tmp309) ; } else { /* empty */ } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_50 */ __ats_lab_50_0: // if (tmp283 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_50_1: tmp310 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_fin (arg1) ; do { /* branch: __ats_lab_51 */ __ats_lab_51_0: if (((ats_sum_ptr_type)tmp310)->tag != 0) { goto __ats_lab_52_0 ; } __ats_lab_51_1: break ; /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp310)->tag != 1) { goto __ats_lab_53_0 ; } __ats_lab_52_1: break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: __ats_lab_53_1: /* tmp311 = */ prerr_loc_error3_0 (arg0) ; /* tmp312 = */ atspre_prerr_string (ATSstrcst(": the linear dynamic variable [")) ; /* tmp313 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp314 = */ atspre_prerr_string (ATSstrcst("] needs to be preserved but it is consumed instead.")) ; /* tmp315 = */ atspre_prerr_newline () ; /* tmp282 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; } while (0) ; return /* (tmp282) */ ; } /* end of [d2var_fin_check_43] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14094(line=485, offs=22) -- 14158(line=487, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp319) ; ATSlocal (ats_ptr_type, tmp320) ; ATSlocal (ats_ptr_type, tmp321) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add: tmp321 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp320 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_add (tmp321, arg0) ; ats_ptrget_mac(ats_ptr_type, statmp316) = tmp320 ; return /* (tmp319) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14227(line=490, offs=25) -- 14294(line=492, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_addlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp322) ; ATSlocal (ats_ptr_type, tmp323) ; ATSlocal (ats_ptr_type, tmp324) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_addlst: tmp324 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp323 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds (tmp324, arg0) ; ats_ptrget_mac(ats_ptr_type, statmp316) = tmp323 ; return /* (tmp322) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_addlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14368(line=495, offs=27) -- 14487(line=499, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp325) ; ATSlocal (ats_ptr_type, tmp326) ; ATSlocal (ats_ptr_type, tmp327) ; ATSlocal (ats_ptr_type, tmp328) ; ATSlocal (ats_ptr_type, tmp329) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at: tmp327 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg0), atslab_p2at_dvs) ; tmp326 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varlst_of_d2varlstord (tmp327) ; tmp329 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp328 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_adds (tmp329, tmp326) ; ats_ptrget_mac(ats_ptr_type, statmp316) = tmp328 ; return /* (tmp325) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14566(line=502, offs=30) -- 14746(line=506, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp330) ; ATSlocal (ats_ptr_type, tmp331) ; ATSlocal (ats_ptr_type, tmp332) ; // ATSlocal_void (tmp333) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst: do { /* branch: __ats_lab_54 */ __ats_lab_54_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_55_0 ; } __ats_lab_54_1: tmp331 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp332 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; /* tmp333 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2at (tmp331) ; arg0 = tmp332 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst ; // tail call break ; /* branch: __ats_lab_55 */ __ats_lab_55_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_55_1: break ; } while (0) ; return /* (tmp330) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_add_p2atlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14834(line=512, offs=30) -- 14856(line=512, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_print_ld2vs () { /* local vardec */ // ATSlocal_void (tmp334) ; ATSlocal (ats_ptr_type, tmp335) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_print_ld2vs: tmp335 = ats_ptrget_mac(ats_ptr_type, statmp316) ; /* tmp334 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__print_d2varset (tmp335) ; return /* (tmp334) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_print_ld2vs] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14897(line=514, offs=30) -- 14919(line=514, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_prerr_ld2vs () { /* local vardec */ // ATSlocal_void (tmp336) ; ATSlocal (ats_ptr_type, tmp337) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_prerr_ld2vs: tmp337 = ats_ptrget_mac(ats_ptr_type, statmp316) ; /* tmp336 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2varset (tmp337) ; return /* (tmp336) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_prerr_ld2vs] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 14925(line=516, offs=4) -- 15226(line=524, offs=4) */ ATSstaticdec() ats_ptr_type the_d2varset_env_get_llam_ld2vs_50 (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp338) ; ATSlocal (ats_ptr_type, tmp339) ; ATSlocal (ats_ptr_type, tmp340) ; ATSlocal (ats_ptr_type, tmp341) ; // ATSlocal_void (tmp342) ; // ATSlocal_void (tmp343) ; // ATSlocal_void (tmp344) ; __ats_lab_the_d2varset_env_get_llam_ld2vs_50: tmp339 = ats_ptrget_mac(ats_ptr_type, statmp317) ; do { /* branch: __ats_lab_56 */ __ats_lab_56_0: if (tmp339 == (ats_sum_ptr_type)0) { goto __ats_lab_57_0 ; } tmp340 = ats_caselptrlab_mac(anairiats_sum_8, tmp339, atslab_0) ; if (((ats_sum_ptr_type)tmp340)->tag != 1) { goto __ats_lab_57_0 ; } __ats_lab_56_1: tmp341 = ats_caselptrlab_mac(anairiats_sum_4, tmp340, atslab_0) ; tmp338 = ats_ptrget_mac(ats_ptr_type, tmp341) ; break ; /* branch: __ats_lab_57 */ __ats_lab_57_0: __ats_lab_57_1: /* tmp342 = */ prerr_loc_interror_2 (arg0) ; /* tmp343 = */ atspre_prerr_string (ATSstrcst(": the_d2varset_env_get_llam_ld2vs")) ; /* tmp344 = */ atspre_prerr_newline () ; /* tmp338 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp338) ; } /* end of [the_d2varset_env_get_llam_ld2vs_50] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 15313(line=530, offs=3) -- 16136(line=556, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () { /* local vardec */ // ATSlocal_void (tmp345) ; ATSlocal (ats_int_type, tmp346) ; ATSlocal (ats_ptr_type, tmp347) ; ATSlocal (ats_ptr_type, tmp349) ; ATSlocal (ats_ptr_type, tmp350) ; ATSlocal (ats_ptr_type, tmp351) ; ATSlocal (ats_ptr_type, tmp353) ; ATSlocal (ats_ptr_type, tmp354) ; ATSlocal (ats_ptr_type, tmp355) ; ATSlocal (ats_bool_type, tmp356) ; // ATSlocal_void (tmp357) ; // ATSlocal_void (tmp358) ; // ATSlocal_void (tmp359) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam: /* ats_int_type tmp346 ; */ tmp346 = 0 ; /* ats_ptr_type tmp347 ; */ tmp347 = (ats_sum_ptr_type)0 ; tmp349 = ats_ptrget_mac(ats_ptr_type, statmp317) ; do { /* branch: __ats_lab_58 */ __ats_lab_58_0: if (tmp349 == (ats_sum_ptr_type)0) { goto __ats_lab_62_0 ; } __ats_lab_58_1: tmp350 = ats_caselptrlab_mac(anairiats_sum_8, tmp349, atslab_0) ; tmp351 = ats_caselptrlab_mac(anairiats_sum_8, tmp349, atslab_1) ; do { /* branch: __ats_lab_59 */ __ats_lab_59_0: if (((ats_sum_ptr_type)tmp350)->tag != 0) { goto __ats_lab_60_0 ; } __ats_lab_59_1: tmp347 = tmp351 ; break ; /* branch: __ats_lab_60 */ __ats_lab_60_0: if (((ats_sum_ptr_type)tmp350)->tag != 1) { goto __ats_lab_61_0 ; } __ats_lab_60_1: tmp347 = tmp351 ; break ; /* branch: __ats_lab_61 */ __ats_lab_61_0: __ats_lab_61_1: tmp346 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_62 */ __ats_lab_62_0: // if (tmp349 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_62_1: tmp346 = 1 ; break ; } while (0) ; do { /* branch: __ats_lab_63 */ __ats_lab_63_0: if (tmp347 == (ats_sum_ptr_type)0) { goto __ats_lab_66_0 ; } __ats_lab_63_1: tmp353 = ats_caselptrlab_mac(anairiats_sum_8, tmp347, atslab_0) ; tmp354 = ats_caselptrlab_mac(anairiats_sum_8, tmp347, atslab_1) ; do { /* branch: __ats_lab_64 */ __ats_lab_64_0: if (((ats_sum_ptr_type)tmp353)->tag != 2) { goto __ats_lab_65_0 ; } __ats_lab_64_1: tmp355 = ats_caselptrlab_mac(anairiats_sum_4, tmp353, atslab_0) ; ats_ptrget_mac(ats_ptr_type, statmp316) = tmp355 ; ats_ptrget_mac(ats_ptr_type, statmp317) = tmp354 ; break ; /* branch: __ats_lab_65 */ __ats_lab_65_0: __ats_lab_65_1: tmp346 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_66 */ __ats_lab_66_0: // if (tmp347 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_66_1: tmp346 = 1 ; break ; } while (0) ; tmp356 = atspre_gt_int_int (tmp346, 0) ; if (tmp356) { /* tmp357 = */ prerr_interror_1 () ; /* tmp358 = */ atspre_prerr_string (ATSstrcst(": the_d2varset_env_pop_lam")) ; /* tmp359 = */ atspre_prerr_newline () ; /* tmp345 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp345) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 16211(line=559, offs=27) -- 16546(line=570, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (ats_int_type arg0) { /* local vardec */ // ATSlocal_void (tmp360) ; ATSlocal (ats_ptr_type, tmp361) ; ATSlocal (ats_bool_type, tmp362) ; ATSlocal (ats_ptr_type, tmp363) ; ATSlocal (ats_ptr_type, tmp364) ; ATSlocal (ats_ptr_type, tmp365) ; ATSlocal (ats_ptr_type, tmp366) ; ATSlocal (ats_ptr_type, tmp367) ; ATSlocal (ats_ptr_type, tmp368) ; ATSlocal (ats_ptr_type, tmp369) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam: tmp362 = atspre_gt_int_int (arg0, 0) ; if (tmp362) { tmp364 = (ats_sum_ptr_type)0 ; tmp363 = ref_make_elt_04159_ats_ptr_type (tmp364) ; tmp361 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp361)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp361, atslab_0, tmp363) ; } else { tmp361 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMlam_0) ; } /* end of [if] */ tmp368 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp367 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp367)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp367, atslab_0, tmp368) ; tmp369 = ats_ptrget_mac(ats_ptr_type, statmp317) ; tmp366 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp366, atslab_0, tmp367) ; ats_selptrset_mac(anairiats_sum_8, tmp366, atslab_1, tmp369) ; tmp365 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp365, atslab_0, tmp361) ; ats_selptrset_mac(anairiats_sum_8, tmp365, atslab_1, tmp366) ; ats_ptrget_mac(ats_ptr_type, statmp317) = tmp365 ; ats_ptrget_mac(ats_ptr_type, statmp316) = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil ; return /* (tmp360) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 16623(line=574, offs=3) -- 17178(line=592, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let () { /* local vardec */ // ATSlocal_void (tmp370) ; ATSlocal (ats_int_type, tmp371) ; ATSlocal (ats_ptr_type, tmp373) ; ATSlocal (ats_ptr_type, tmp374) ; ATSlocal (ats_ptr_type, tmp375) ; ATSlocal (ats_ptr_type, tmp376) ; ATSlocal (ats_bool_type, tmp377) ; // ATSlocal_void (tmp378) ; // ATSlocal_void (tmp379) ; // ATSlocal_void (tmp380) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let: /* ats_int_type tmp371 ; */ tmp371 = 0 ; tmp373 = ats_ptrget_mac(ats_ptr_type, statmp317) ; do { /* branch: __ats_lab_67 */ __ats_lab_67_0: if (tmp373 == (ats_sum_ptr_type)0) { goto __ats_lab_70_0 ; } __ats_lab_67_1: tmp374 = ats_caselptrlab_mac(anairiats_sum_8, tmp373, atslab_0) ; tmp375 = ats_caselptrlab_mac(anairiats_sum_8, tmp373, atslab_1) ; do { /* branch: __ats_lab_68 */ __ats_lab_68_0: if (((ats_sum_ptr_type)tmp374)->tag != 2) { goto __ats_lab_69_0 ; } __ats_lab_68_1: tmp376 = ats_caselptrlab_mac(anairiats_sum_4, tmp374, atslab_0) ; ats_ptrget_mac(ats_ptr_type, statmp316) = tmp376 ; ats_ptrget_mac(ats_ptr_type, statmp317) = tmp375 ; break ; /* branch: __ats_lab_69 */ __ats_lab_69_0: __ats_lab_69_1: tmp371 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_70 */ __ats_lab_70_0: // if (tmp373 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_70_1: tmp371 = 1 ; break ; } while (0) ; tmp377 = atspre_gt_int_int (tmp371, 0) ; if (tmp377) { /* tmp378 = */ prerr_interror_1 () ; /* tmp379 = */ atspre_prerr_string (ATSstrcst(": the_d2varset_env_pop_let")) ; /* tmp380 = */ atspre_prerr_newline () ; /* tmp370 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp370) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_let] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 17253(line=595, offs=27) -- 17441(line=601, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let () { /* local vardec */ // ATSlocal_void (tmp381) ; ATSlocal (ats_ptr_type, tmp382) ; ATSlocal (ats_ptr_type, tmp383) ; ATSlocal (ats_ptr_type, tmp384) ; ATSlocal (ats_ptr_type, tmp385) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let: tmp384 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp383 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp383)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp383, atslab_0, tmp384) ; tmp385 = ats_ptrget_mac(ats_ptr_type, statmp317) ; tmp382 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp382, atslab_0, tmp383) ; ats_selptrset_mac(anairiats_sum_8, tmp382, atslab_1, tmp385) ; ats_ptrget_mac(ats_ptr_type, statmp317) = tmp382 ; ats_ptrget_mac(ats_ptr_type, statmp316) = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil ; return /* (tmp381) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_let] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 17522(line=607, offs=3) -- 17592(line=609, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try () { /* local vardec */ // ATSlocal_void (tmp386) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try: /* tmp386 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_lam () ; return /* (tmp386) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_pop_try] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 17667(line=612, offs=27) -- 17720(line=614, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try () { /* local vardec */ // ATSlocal_void (tmp387) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try: /* tmp387 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_lam (0) ; return /* (tmp387) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_push_try] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 17833(line=622, offs=7) -- 18401(line=638, offs=6) */ ATSstaticdec() ats_bool_type aux_58 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp389) ; ATSlocal (ats_ptr_type, tmp390) ; ATSlocal (ats_ptr_type, tmp391) ; ATSlocal (ats_ptr_type, tmp392) ; ATSlocal (ats_bool_type, tmp393) ; // ATSlocal_void (tmp394) ; // ATSlocal_void (tmp395) ; // ATSlocal_void (tmp396) ; // ATSlocal_void (tmp397) ; __ats_lab_aux_58: do { /* branch: __ats_lab_71 */ __ats_lab_71_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_75_0 ; } __ats_lab_71_1: tmp390 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp391 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_72 */ __ats_lab_72_0: if (((ats_sum_ptr_type)tmp390)->tag != 0) { goto __ats_lab_73_0 ; } __ats_lab_72_1: tmp389 = ats_false_bool ; break ; /* branch: __ats_lab_73 */ __ats_lab_73_0: if (((ats_sum_ptr_type)tmp390)->tag != 1) { goto __ats_lab_74_0 ; } __ats_lab_73_1: tmp389 = ats_false_bool ; break ; /* branch: __ats_lab_74 */ __ats_lab_74_0: // if (((ats_sum_ptr_type)tmp390)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_74_1: tmp392 = ats_caselptrlab_mac(anairiats_sum_4, tmp390, atslab_0) ; tmp393 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem (tmp392, arg1) ; if (tmp393) { tmp389 = ats_true_bool ; } else { arg0 = tmp391 ; arg1 = arg1 ; goto __ats_lab_aux_58 ; // tail call } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_75 */ __ats_lab_75_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_75_1: /* tmp394 = */ prerr_interror_1 () ; /* tmp395 = */ atspre_prerr_string (ATSstrcst(": d2var_is_lam_local: aux: d2v = ")) ; /* tmp396 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp397 = */ atspre_prerr_newline () ; /* tmp389 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp389) ; } /* end of [aux_58] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 17812(line=620, offs=3) -- 18532(line=644, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_lam_local (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp388) ; ATSlocal (ats_bool_type, tmp398) ; ATSlocal (ats_ptr_type, tmp399) ; ATSlocal (ats_ptr_type, tmp400) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_lam_local: tmp399 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp398 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem (tmp399, arg0) ; if (tmp398) { tmp388 = ats_true_bool ; } else { tmp400 = ats_ptrget_mac(ats_ptr_type, statmp317) ; tmp388 = aux_58 (tmp400, arg0) ; } /* end of [if] */ return (tmp388) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_lam_local] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 18652(line=650, offs=7) -- 19312(line=668, offs=6) */ ATSstaticdec() ats_bool_type aux_60 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_bool_type, tmp402) ; ATSlocal (ats_ptr_type, tmp403) ; ATSlocal (ats_ptr_type, tmp404) ; ATSlocal (ats_ptr_type, tmp405) ; ATSlocal (ats_ptr_type, tmp406) ; ATSlocal (ats_ptr_type, tmp407) ; ATSlocal (ats_ptr_type, tmp408) ; ATSlocal (ats_bool_type, tmp409) ; // ATSlocal_void (tmp410) ; // ATSlocal_void (tmp411) ; // ATSlocal_void (tmp412) ; // ATSlocal_void (tmp413) ; __ats_lab_aux_60: do { /* branch: __ats_lab_76 */ __ats_lab_76_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_80_0 ; } __ats_lab_76_1: tmp403 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp404 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_77 */ __ats_lab_77_0: if (((ats_sum_ptr_type)tmp403)->tag != 0) { goto __ats_lab_78_0 ; } __ats_lab_77_1: tmp402 = ats_false_bool ; break ; /* branch: __ats_lab_78 */ __ats_lab_78_0: if (((ats_sum_ptr_type)tmp403)->tag != 1) { goto __ats_lab_79_0 ; } __ats_lab_78_1: tmp405 = ats_caselptrlab_mac(anairiats_sum_4, tmp403, atslab_0) ; tmp407 = ats_ptrget_mac(ats_ptr_type, tmp405) ; tmp406 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp406, atslab_0, arg1) ; ats_selptrset_mac(anairiats_sum_8, tmp406, atslab_1, tmp407) ; ats_ptrget_mac(ats_ptr_type, tmp405) = tmp406 ; arg0 = tmp404 ; arg1 = arg1 ; goto __ats_lab_aux_60 ; // tail call break ; /* branch: __ats_lab_79 */ __ats_lab_79_0: // if (((ats_sum_ptr_type)tmp403)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_79_1: tmp408 = ats_caselptrlab_mac(anairiats_sum_4, tmp403, atslab_0) ; tmp409 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem (tmp408, arg1) ; if (tmp409) { tmp402 = ats_true_bool ; } else { arg0 = tmp404 ; arg1 = arg1 ; goto __ats_lab_aux_60 ; // tail call } /* end of [if] */ break ; } while (0) ; break ; /* branch: __ats_lab_80 */ __ats_lab_80_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_80_1: /* tmp410 = */ prerr_interror_1 () ; /* tmp411 = */ atspre_prerr_string (ATSstrcst(": d2var_is_llam_local: aux: d2v = ")) ; /* tmp412 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg1) ; /* tmp413 = */ atspre_prerr_newline () ; /* tmp402 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp402) ; } /* end of [aux_60] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 18631(line=648, offs=3) -- 19740(line=687, offs=4) */ ATSglobaldec() ats_bool_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_bool_type, tmp401) ; ATSlocal (ats_bool_type, tmp414) ; ATSlocal (ats_ptr_type, tmp415) ; ATSlocal (ats_ptr_type, tmp416) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local: tmp415 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp414 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_ismem (tmp415, arg0) ; if (tmp414) { tmp401 = ats_true_bool ; } else { tmp416 = ats_ptrget_mac(ats_ptr_type, statmp317) ; tmp401 = aux_60 (tmp416, arg0) ; } /* end of [if] */ return (tmp401) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_d2var_is_llam_local] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 19992(line=700, offs=18) -- 20032(line=700, offs=58) */ ATSstaticdec() ats_void_type __ats_fun_62 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp420) ; __ats_lab___ats_fun_62: /* tmp420 = */ d2var_fin_check_43 (env0, arg0) ; return /* (tmp420) */ ; } /* end of [__ats_fun_62] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } __ats_fun_62_closure_type ; ats_void_type __ats_fun_62_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { __ats_fun_62 (((__ats_fun_62_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type __ats_fun_62_closure_init (__ats_fun_62_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&__ats_fun_62_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type __ats_fun_62_closure_make (ats_ptr_type env0) { __ats_fun_62_closure_type *p_clo = ATS_MALLOC(sizeof(__ats_fun_62_closure_type)) ; __ats_fun_62_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 19828(line=692, offs=24) -- 20037(line=701, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp417) ; ATSlocal (ats_ptr_type, tmp418) ; ATSlocal (ats_ptr_type, tmp419) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check: /* ats_ptr_type tmp418 ; */ tmp419 = ats_ptrget_mac(ats_ptr_type, statmp316) ; tmp418 = __ats_fun_62_closure_make (arg0) ; /* tmp417 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_cloptr (tmp419, tmp418) ; ATS_FREE(tmp418) ; return /* (tmp417) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 20130(line=705, offs=6) -- 20752(line=722, offs=6) */ ATSstaticdec() ats_void_type auxCK_64 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp422) ; ATSlocal (ats_ptr_type, tmp423) ; ATSlocal (ats_ptr_type, tmp424) ; ATSlocal (ats_bool_type, tmp425) ; ATSlocal (ats_ptr_type, tmp426) ; // ATSlocal_void (tmp427) ; // ATSlocal_void (tmp428) ; // ATSlocal_void (tmp429) ; // ATSlocal_void (tmp430) ; // ATSlocal_void (tmp431) ; // ATSlocal_void (tmp432) ; // ATSlocal_void (tmp433) ; __ats_lab_auxCK_64: tmp423 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg0) ; do { /* branch: __ats_lab_81 */ __ats_lab_81_0: if (tmp423 == (ats_sum_ptr_type)0) { goto __ats_lab_82_0 ; } __ats_lab_81_1: tmp424 = ats_caselptrlab_mac(anairiats_sum_12, tmp423, atslab_0) ; tmp425 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_is_nonlin (tmp424) ; if (tmp425) { tmp426 = (ats_sum_ptr_type)0 ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_typ (arg0, tmp426) ; } else { /* tmp427 = */ prerr_loc_error3_0 (env0) ; /* tmp428 = */ atspre_prerr_string (ATSstrcst(": the linear dynamic variable [")) ; /* tmp429 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__prerr_d2var (arg0) ; /* tmp430 = */ atspre_prerr_string (ATSstrcst("] needs to be consumed but it is preserved with the type [")) ; /* tmp431 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp424) ; /* tmp432 = */ atspre_prerr_string (ATSstrcst("] instead.")) ; /* tmp433 = */ atspre_prerr_newline () ; /* tmp422 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ break ; /* branch: __ats_lab_82 */ __ats_lab_82_0: // if (tmp423 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_82_1: break ; } while (0) ; return /* (tmp422) */ ; } /* end of [auxCK_64] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } auxCK_64_closure_type ; ats_void_type auxCK_64_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { auxCK_64 (((auxCK_64_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type auxCK_64_closure_init (auxCK_64_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxCK_64_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxCK_64_closure_make (ats_ptr_type env0) { auxCK_64_closure_type *p_clo = ATS_MALLOC(sizeof(auxCK_64_closure_type)) ; auxCK_64_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 20777(line=723, offs=7) -- 20919(line=725, offs=6) */ ATSstaticdec() ats_void_type auxlst_65 (ats_ptr_type env0, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp434) ; ATSlocal (ats_ptr_type, tmp435) ; ATSlocal (ats_ptr_type, tmp436) ; // ATSlocal_void (tmp437) ; __ats_lab_auxlst_65: do { /* branch: __ats_lab_83 */ __ats_lab_83_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_84_0 ; } __ats_lab_83_1: tmp435 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp436 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; /* tmp437 = */ auxCK_64 (env0, tmp435) ; arg0 = tmp436 ; goto __ats_lab_auxlst_65 ; // tail call break ; /* branch: __ats_lab_84 */ __ats_lab_84_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_84_1: break ; } while (0) ; return /* (tmp434) */ ; } /* end of [auxlst_65] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; } auxlst_65_closure_type ; ats_void_type auxlst_65_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { auxlst_65 (((auxlst_65_closure_type*)cloptr)->closure_env_0, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type auxlst_65_closure_init (auxlst_65_closure_type *p_clo, ats_ptr_type env0) { p_clo->closure_fun = (ats_fun_ptr_type)&auxlst_65_clofun ; p_clo->closure_env_0 = env0 ; return ; } /* end of function */ ats_clo_ptr_type auxlst_65_closure_make (ats_ptr_type env0) { auxlst_65_closure_type *p_clo = ATS_MALLOC(sizeof(auxlst_65_closure_type)) ; auxlst_65_closure_init (p_clo, env0) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 20112(line=704, offs=29) -- 20995(line=728, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp421) ; ATSlocal (ats_ptr_type, tmp438) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam: tmp438 = the_d2varset_env_get_llam_ld2vs_50 (arg0) ; /* tmp421 = */ auxlst_65 (arg0, tmp438) ; return /* (tmp421) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_check_llam] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 21264(line=737, offs=6) -- 21540(line=743, offs=6) */ ATSstaticdec() ats_void_type f_67 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp440) ; ATSlocal (ats_ptr_type, tmp441) ; ATSlocal (ats_ptr_type, tmp442) ; ATSlocal (ats_bool_type, tmp443) ; ATSlocal (ats_ptr_type, tmp444) ; __ats_lab_f_67: tmp441 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg0) ; do { /* branch: __ats_lab_85 */ __ats_lab_85_0: if (tmp441 == (ats_sum_ptr_type)0) { goto __ats_lab_86_0 ; } __ats_lab_85_1: tmp442 = ats_caselptrlab_mac(anairiats_sum_12, tmp441, atslab_0) ; tmp443 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (arg1, tmp442) ; if (tmp443) { tmp444 = ATS_MALLOC(sizeof(anairiats_sum_15)) ; ((ats_exn_ptr_type)tmp444)->tag = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag ; ((ats_exn_ptr_type)tmp444)->name = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.name ; ats_selptrset_mac(anairiats_sum_15, tmp444, atslab_0, arg0) ; /* tmp440 = */ ats_raise_exn (tmp444) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_86 */ __ats_lab_86_0: __ats_lab_86_1: break ; } while (0) ; return /* (tmp440) */ ; } /* end of [f_67] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 21561(line=744, offs=7) -- 22141(line=759, offs=6) */ ATSstaticdec() ats_void_type loop_68 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp445) ; ATSlocal (ats_ptr_type, tmp446) ; ATSlocal (ats_ptr_type, tmp447) ; // ATSlocal_void (tmp448) ; ATSlocal (ats_ptr_type, tmp449) ; ATSlocal (ats_ptr_type, tmp450) ; __ats_lab_loop_68: do { /* branch: __ats_lab_87 */ __ats_lab_87_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_91_0 ; } __ats_lab_87_1: tmp446 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp447 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_88 */ __ats_lab_88_0: if (((ats_sum_ptr_type)tmp446)->tag != 0) { goto __ats_lab_89_0 ; } __ats_lab_88_1: tmp449 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; /* tmp448 = */ ats_raise_exn (tmp449) ; break ; /* branch: __ats_lab_89 */ __ats_lab_89_0: if (((ats_sum_ptr_type)tmp446)->tag != 1) { goto __ats_lab_90_0 ; } __ats_lab_89_1: break ; /* branch: __ats_lab_90 */ __ats_lab_90_0: // if (((ats_sum_ptr_type)tmp446)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_90_1: tmp450 = ats_caselptrlab_mac(anairiats_sum_4, tmp446, atslab_0) ; /* tmp448 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp450, &f_67, arg1) ; break ; } while (0) ; arg0 = tmp447 ; arg1 = arg1 ; goto __ats_lab_loop_68 ; // tail call break ; /* branch: __ats_lab_91 */ __ats_lab_91_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_91_1: break ; } while (0) ; return /* (tmp445) */ ; } /* end of [loop_68] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 21095(line=733, offs=28) -- 22495(line=773, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_view (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp439) ; // ATSlocal_void (tmp451) ; ATSlocal (ats_ptr_type, tmp452) ; // ATSlocal_void (tmp453) ; ATSlocal (ats_ptr_type, tmp454) ; ATSlocal (ats_ptr_type, tmp455) ; ATSlocal (ats_ptr_type, tmp456) ; ATSlocal (ats_ptr_type, tmp457) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_view: ATS_TRYWITH_TRY(tmp456) tmp452 = ats_ptrget_mac(ats_ptr_type, statmp316) ; /* tmp451 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp452, &f_67, arg0) ; tmp454 = ats_ptrget_mac(ats_ptr_type, statmp317) ; /* tmp453 = */ loop_68 (tmp454, arg0) ; tmp455 = (ats_sum_ptr_type)0 ; tmp439 = tmp455 ; ATS_TRYWITH_WITH(tmp456) do { /* branch: __ats_lab_92 */ __ats_lab_92_0: if (tmp456 != &ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) { goto __ats_lab_93_0 ; } __ats_lab_92_1: tmp439 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_93 */ __ats_lab_93_0: if (((ats_exn_ptr_type)tmp456)->tag != ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag) { ats_raise_exn (tmp456) ; } __ats_lab_93_1: tmp457 = ats_caselptrlab_mac(anairiats_sum_15, tmp456, atslab_0) ; ATS_FREE(tmp456) ; tmp439 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp439, atslab_0, tmp457) ; break ; } while (0) ; ATS_TRYWITH_END() ; return (tmp439) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_view] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 22767(line=783, offs=6) -- 23738(line=808, offs=6) */ ATSstaticdec() ats_void_type f_70 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp459) ; ATSlocal (ats_ptr_type, tmp460) ; ATSlocal (ats_ptr_type, tmp461) ; ATSlocal (ats_ptr_type, tmp462) ; ATSlocal (ats_ptr_type, tmp463) ; ATSlocal (anairiats_rec_1, tmp464) ; ATSlocal (anairiats_rec_1, tmp465) ; ATSlocal (ats_ptr_type, tmp466) ; ATSlocal (ats_ptr_type, tmp467) ; ATSlocal (ats_ptr_type, tmp468) ; ATSlocal (ats_ptr_type, tmp469) ; ATSlocal (ats_ptr_type, tmp470) ; ATSlocal (ats_bool_type, tmp471) ; ATSlocal (ats_ptr_type, tmp472) ; ATSlocal (ats_ptr_type, tmp473) ; ATSlocal (ats_ptr_type, tmp474) ; ATSlocal (anairiats_rec_17, tmp475) ; ATSlocal (ats_ptr_type, tmp476) ; ATSlocal (ats_ptr_type, tmp477) ; __ats_lab_f_70: tmp460 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_typ (arg0) ; do { /* branch: __ats_lab_94 */ __ats_lab_94_0: if (tmp460 == (ats_sum_ptr_type)0) { goto __ats_lab_101_0 ; } __ats_lab_94_1: tmp461 = ats_caselptrlab_mac(anairiats_sum_12, tmp460, atslab_0) ; tmp462 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (tmp461) ; tmp463 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_at_viewt0ype_addr_view (tmp462) ; do { /* branch: __ats_lab_95 */ __ats_lab_95_0: if (tmp463 == (ats_sum_ptr_type)0) { goto __ats_lab_100_0 ; } __ats_lab_95_1: tmp464 = ats_caselptrlab_mac(anairiats_sum_16, tmp463, atslab_0) ; ATS_FREE(tmp463) ; tmp466 = ats_select_mac(tmp464, atslab_1) ; tmp465 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_addr_normalize (tmp466) ; tmp467 = ats_select_mac(tmp465, atslab_0) ; tmp468 = ats_select_mac(tmp465, atslab_1) ; // tmp469 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp470 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; do { /* branch: __ats_lab_96 */ __ats_lab_96_0: __ats_lab_96_1: tmp471 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_syneq (tmp469, tmp467) ; if (!tmp471) { goto __ats_lab_99_1 ; } tmp472 = s2lablst_is_prefix_42 (tmp468, tmp470) ; do { /* branch: __ats_lab_97 */ __ats_lab_97_0: if (tmp472 == (ats_sum_ptr_type)0) { goto __ats_lab_98_0 ; } __ats_lab_97_1: tmp473 = ats_caselptrlab_mac(anairiats_sum_12, tmp472, atslab_0) ; ATS_FREE(tmp472) ; tmp476 = ats_select_mac(tmp464, atslab_0) ; tmp477 = ats_select_mac(tmp464, atslab_1) ; tmp475.atslab_0 = arg0 ; tmp475.atslab_1 = tmp476 ; tmp475.atslab_2 = tmp477 ; tmp475.atslab_3 = tmp468 ; tmp475.atslab_4 = tmp473 ; tmp474 = ATS_MALLOC(sizeof(anairiats_sum_18)) ; ((ats_exn_ptr_type)tmp474)->tag = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag ; ((ats_exn_ptr_type)tmp474)->name = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.name ; ats_selptrset_mac(anairiats_sum_18, tmp474, atslab_0, tmp475) ; /* tmp459 = */ ats_raise_exn (tmp474) ; break ; /* branch: __ats_lab_98 */ __ats_lab_98_0: // if (tmp472 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_98_1: break ; } while (0) ; break ; /* branch: __ats_lab_99 */ __ats_lab_99_0: __ats_lab_99_1: break ; } while (0) ; break ; /* branch: __ats_lab_100 */ __ats_lab_100_0: // if (tmp463 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_100_1: break ; } while (0) ; break ; /* branch: __ats_lab_101 */ __ats_lab_101_0: __ats_lab_101_1: break ; } while (0) ; return /* (tmp459) */ ; } /* end of [f_70] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 23762(line=810, offs=7) -- 24345(line=826, offs=6) */ ATSstaticdec() ats_void_type loop_71 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp478) ; ATSlocal (ats_ptr_type, tmp479) ; ATSlocal (ats_ptr_type, tmp480) ; // ATSlocal_void (tmp481) ; ATSlocal (ats_ptr_type, tmp482) ; ATSlocal (ats_ptr_type, tmp483) ; __ats_lab_loop_71: do { /* branch: __ats_lab_102 */ __ats_lab_102_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_106_0 ; } __ats_lab_102_1: tmp479 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp480 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_103 */ __ats_lab_103_0: if (((ats_sum_ptr_type)tmp479)->tag != 0) { goto __ats_lab_104_0 ; } __ats_lab_103_1: tmp482 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) ; /* tmp481 = */ ats_raise_exn (tmp482) ; break ; /* branch: __ats_lab_104 */ __ats_lab_104_0: if (((ats_sum_ptr_type)tmp479)->tag != 1) { goto __ats_lab_105_0 ; } __ats_lab_104_1: break ; /* branch: __ats_lab_105 */ __ats_lab_105_0: // if (((ats_sum_ptr_type)tmp479)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_105_1: tmp483 = ats_caselptrlab_mac(anairiats_sum_4, tmp479, atslab_0) ; /* tmp481 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp483, &f_70, arg1) ; break ; } while (0) ; arg0 = tmp480 ; arg1 = arg1 ; goto __ats_lab_loop_71 ; // tail call break ; /* branch: __ats_lab_106 */ __ats_lab_106_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_106_1: break ; } while (0) ; return /* (tmp478) */ ; } /* end of [loop_71] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 22577(line=777, offs=3) -- 24760(line=843, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp458) ; ATSlocal (ats_ptr_type, tmp484) ; // ATSlocal_void (tmp485) ; ATSlocal (ats_ptr_type, tmp486) ; // ATSlocal_void (tmp487) ; ATSlocal (ats_ptr_type, tmp488) ; ATSlocal (ats_ptr_type, tmp489) ; ATSlocal (ats_ptr_type, tmp490) ; ATSlocal (anairiats_rec_17, tmp491) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat: ATS_TRYWITH_TRY(tmp490) tmp484 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp484, atslab_0, arg0) ; ats_selptrset_mac(anairiats_sum_8, tmp484, atslab_1, arg1) ; tmp486 = ats_ptrget_mac(ats_ptr_type, statmp316) ; /* tmp485 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp486, &f_70, tmp484) ; tmp488 = ats_ptrget_mac(ats_ptr_type, statmp317) ; /* tmp487 = */ loop_71 (tmp488, tmp484) ; // ATS_FREE(tmp484) ; tmp489 = (ats_sum_ptr_type)0 ; tmp458 = tmp489 ; ATS_TRYWITH_WITH(tmp490) do { /* branch: __ats_lab_107 */ __ats_lab_107_0: if (tmp490 != &ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound) { goto __ats_lab_108_0 ; } __ats_lab_107_1: tmp458 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_108 */ __ats_lab_108_0: if (((ats_exn_ptr_type)tmp490)->tag != ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag) { ats_raise_exn (tmp490) ; } __ats_lab_108_1: tmp491 = ats_caselptrlab_mac(anairiats_sum_18, tmp490, atslab_0) ; ATS_FREE(tmp490) ; tmp458 = ATS_MALLOC(sizeof(anairiats_sum_19)) ; ats_selptrset_mac(anairiats_sum_19, tmp458, atslab_0, tmp491) ; break ; } while (0) ; ATS_TRYWITH_END() ; return (tmp458) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_find_viewat] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 24997(line=856, offs=7) -- 25456(line=870, offs=6) */ ATSstaticdec() ats_void_type f_73 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp494) ; ATSlocal (ats_int_type, tmp495) ; ATSlocal (ats_bool_type, tmp496) ; ATSlocal (ats_ptr_type, tmp497) ; ATSlocal (ats_ptr_type, tmp498) ; ATSlocal (ats_ptr_type, tmp499) ; __ats_lab_f_73: tmp495 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_lin (arg0) ; tmp496 = atspre_gte_int_int (tmp495, 0) ; if (tmp496) { tmp497 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__stbefitem_make (arg0, tmp495) ; tmp499 = ats_ptrget_mac(ats_ptr_type, arg1) ; tmp498 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp498, atslab_0, tmp497) ; ats_selptrset_mac(anairiats_sum_8, tmp498, atslab_1, tmp499) ; ats_ptrget_mac(ats_ptr_type, arg1) = tmp498 ; } else { /* empty */ } /* end of [if] */ return /* (tmp494) */ ; } /* end of [f_73] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 25483(line=872, offs=7) -- 25963(line=888, offs=6) */ ATSstaticdec() ats_void_type aux_74 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp500) ; ATSlocal (ats_ptr_type, tmp501) ; ATSlocal (ats_ptr_type, tmp502) ; ATSlocal (ats_ptr_type, tmp503) ; // ATSlocal_void (tmp504) ; __ats_lab_aux_74: do { /* branch: __ats_lab_109 */ __ats_lab_109_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_113_0 ; } __ats_lab_109_1: tmp501 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp502 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; do { /* branch: __ats_lab_110 */ __ats_lab_110_0: if (((ats_sum_ptr_type)tmp501)->tag != 0) { goto __ats_lab_111_0 ; } __ats_lab_110_1: break ; /* branch: __ats_lab_111 */ __ats_lab_111_0: if (((ats_sum_ptr_type)tmp501)->tag != 1) { goto __ats_lab_112_0 ; } __ats_lab_111_1: arg0 = tmp502 ; arg1 = arg1 ; goto __ats_lab_aux_74 ; // tail call break ; /* branch: __ats_lab_112 */ __ats_lab_112_0: // if (((ats_sum_ptr_type)tmp501)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_112_1: tmp503 = ats_caselptrlab_mac(anairiats_sum_4, tmp501, atslab_0) ; /* tmp504 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp503, &f_73, arg1) ; arg0 = tmp502 ; arg1 = arg1 ; goto __ats_lab_aux_74 ; // tail call break ; } while (0) ; break ; /* branch: __ats_lab_113 */ __ats_lab_113_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_113_1: break ; } while (0) ; return /* (tmp500) */ ; } /* end of [aux_74] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 24871(line=849, offs=3) -- 26195(line=898, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save () { /* local vardec */ ATSlocal (ats_ptr_type, tmp492) ; ATSlocal (ats_ptr_type, tmp493) ; // ATSlocal_void (tmp505) ; ATSlocal (ats_ptr_type, tmp506) ; // ATSlocal_void (tmp507) ; ATSlocal (ats_ptr_type, tmp508) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save: /* ats_ptr_type tmp493 ; */ tmp493 = (ats_sum_ptr_type)0 ; tmp506 = ats_ptrget_mac(ats_ptr_type, statmp316) ; /* tmp505 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_foreach_main (tmp506, &f_73, (&tmp493)) ; tmp508 = ats_ptrget_mac(ats_ptr_type, statmp317) ; /* tmp507 = */ aux_74 (tmp508, (&tmp493)) ; tmp492 = tmp493 ; return (tmp492) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_d2varset_env_stbefitemlst_save] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 26470(line=912, offs=27) -- 26572(line=916, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_copy () { /* local vardec */ ATSlocal (ats_ptr_type, tmp513) ; ATSlocal (ats_ptr_type, tmp514) ; ATSlocal (ats_ptr_type, tmp515) ; ATSlocal (ats_ptr_type, tmp516) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_copy: tmp514 = atspre_ref_get_view_ptr (statmp509) ; tmp515 = ats_selsin_mac(tmp514, atslab_1) ; tmp516 = ats_ptrget_mac(ats_ptr_type, tmp515) ; tmp513 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_copy__boxed (tmp516) ; return (tmp513) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_copy] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 26647(line=919, offs=26) -- 26771(line=924, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_get () { /* local vardec */ ATSlocal (ats_ptr_type, tmp517) ; ATSlocal (ats_ptr_type, tmp518) ; ATSlocal (ats_ptr_type, tmp519) ; ATSlocal (ats_ptr_type, tmp520) ; ATSlocal (ats_ptr_type, tmp521) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_get: tmp518 = atspre_ref_get_view_ptr (statmp509) ; tmp519 = ats_selsin_mac(tmp518, atslab_1) ; tmp520 = ats_ptrget_mac(ats_ptr_type, tmp519) ; tmp521 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp519) = tmp521 ; tmp517 = tmp520 ; return (tmp517) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_get] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 26845(line=927, offs=26) -- 27030(line=933, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_set (ats_ptr_type arg0) { /* local vardec */ ATSlocal (ats_ptr_type, tmp522) ; ATSlocal (ats_ptr_type, tmp523) ; ATSlocal (ats_ptr_type, tmp524) ; ATSlocal (ats_ptr_type, tmp525) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_set: tmp523 = atspre_ref_get_view_ptr (statmp509) ; tmp524 = ats_selsin_mac(tmp523, atslab_1) ; tmp525 = ats_ptrget_mac(ats_ptr_type, tmp524) ; do { /* branch: __ats_lab_114 */ __ats_lab_114_0: if (tmp525 != (ats_sum_ptr_type)0) { goto __ats_lab_115_0 ; } __ats_lab_114_1: ats_ptrget_mac(ats_ptr_type, tmp524) = arg0 ; tmp522 = (ats_sum_ptr_type)0 ; break ; /* branch: __ats_lab_115 */ __ats_lab_115_0: // if (tmp525 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_115_1: tmp522 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp522, atslab_0, arg0) ; break ; } while (0) ; return (tmp522) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_s3itemlst_set] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27099(line=936, offs=21) -- 27214(line=940, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp526) ; ATSlocal (ats_ptr_type, tmp527) ; ATSlocal (ats_ptr_type, tmp528) ; ATSlocal (ats_ptr_type, tmp529) ; ATSlocal (ats_ptr_type, tmp530) ; ATSlocal (ats_ptr_type, tmp531) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar: tmp527 = atspre_ref_get_view_ptr (statmp509) ; tmp528 = ats_selsin_mac(tmp527, atslab_1) ; tmp530 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp530)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp530, atslab_0, arg0) ; tmp531 = ats_ptrget_mac(ats_ptr_type, tmp528) ; tmp529 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp529, atslab_0, tmp530) ; ats_selptrset_mac(anairiats_sum_8, tmp529, atslab_1, tmp531) ; ats_ptrget_mac(ats_ptr_type, tmp528) = tmp529 ; return /* (tmp526) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svar] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27300(line=944, offs=7) -- 27508(line=948, offs=26) */ ATSstaticdec() ats_ptr_type aux_80 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp533) ; ATSlocal (ats_ptr_type, tmp534) ; ATSlocal (ats_ptr_type, tmp535) ; ATSlocal (ats_ptr_type, tmp536) ; ATSlocal (ats_ptr_type, tmp537) ; __ats_lab_aux_80: do { /* branch: __ats_lab_116 */ __ats_lab_116_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_117_0 ; } __ats_lab_116_1: tmp534 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp535 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp537 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp537)->tag = 4 ; ats_selptrset_mac(anairiats_sum_4, tmp537, atslab_0, tmp534) ; tmp536 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp536, atslab_0, tmp537) ; ats_selptrset_mac(anairiats_sum_8, tmp536, atslab_1, arg0) ; arg0 = tmp536 ; arg1 = tmp535 ; goto __ats_lab_aux_80 ; // tail call break ; /* branch: __ats_lab_117 */ __ats_lab_117_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_117_1: tmp533 = arg0 ; break ; } while (0) ; return (tmp533) ; } /* end of [aux_80] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27281(line=943, offs=24) -- 27593(line=952, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp532) ; ATSlocal (ats_ptr_type, tmp538) ; ATSlocal (ats_ptr_type, tmp539) ; ATSlocal (ats_ptr_type, tmp540) ; ATSlocal (ats_ptr_type, tmp541) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst: tmp538 = atspre_ref_get_view_ptr (statmp509) ; tmp539 = ats_selsin_mac(tmp538, atslab_1) ; tmp541 = ats_ptrget_mac(ats_ptr_type, tmp539) ; tmp540 = aux_80 (tmp541, arg0) ; ats_ptrget_mac(ats_ptr_type, tmp539) = tmp540 ; return /* (tmp532) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27681(line=957, offs=21) -- 27831(line=962, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp542) ; // ATSlocal_void (tmp543) ; ATSlocal (ats_ptr_type, tmp544) ; ATSlocal (ats_ptr_type, tmp545) ; ATSlocal (ats_ptr_type, tmp546) ; ATSlocal (ats_ptr_type, tmp547) ; ATSlocal (ats_ptr_type, tmp548) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar: /* tmp543 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add (arg0) ; tmp544 = atspre_ref_get_view_ptr (statmp509) ; tmp545 = ats_selsin_mac(tmp544, atslab_1) ; tmp547 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp547)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp547, atslab_0, arg0) ; tmp548 = ats_ptrget_mac(ats_ptr_type, tmp545) ; tmp546 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp546, atslab_0, tmp547) ; ats_selptrset_mac(anairiats_sum_8, tmp546, atslab_1, tmp548) ; ats_ptrget_mac(ats_ptr_type, tmp545) = tmp546 ; return /* (tmp542) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27917(line=966, offs=7) -- 28227(line=974, offs=6) */ ATSstaticdec() ats_ptr_type aux_83 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp550) ; ATSlocal (ats_ptr_type, tmp551) ; ATSlocal (ats_ptr_type, tmp552) ; // ATSlocal_void (tmp553) ; ATSlocal (ats_ptr_type, tmp554) ; ATSlocal (ats_ptr_type, tmp555) ; __ats_lab_aux_83: do { /* branch: __ats_lab_118 */ __ats_lab_118_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_119_0 ; } __ats_lab_118_1: tmp551 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp552 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp553 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_add (tmp551) ; tmp555 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp555)->tag = 5 ; ats_selptrset_mac(anairiats_sum_4, tmp555, atslab_0, tmp551) ; tmp554 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp554, atslab_0, tmp555) ; ats_selptrset_mac(anairiats_sum_8, tmp554, atslab_1, arg0) ; arg0 = tmp554 ; arg1 = tmp552 ; goto __ats_lab_aux_83 ; // tail call break ; /* branch: __ats_lab_119 */ __ats_lab_119_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_119_1: tmp550 = arg0 ; break ; } while (0) ; return (tmp550) ; } /* end of [aux_83] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 27898(line=965, offs=24) -- 28326(line=978, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVarlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp549) ; ATSlocal (ats_ptr_type, tmp556) ; ATSlocal (ats_ptr_type, tmp557) ; ATSlocal (ats_ptr_type, tmp558) ; ATSlocal (ats_ptr_type, tmp559) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVarlst: tmp556 = atspre_ref_get_view_ptr (statmp509) ; tmp557 = ats_selsin_mac(tmp556, atslab_1) ; tmp559 = ats_ptrget_mac(ats_ptr_type, tmp557) ; tmp558 = aux_83 (tmp559, arg0) ; ats_ptrget_mac(ats_ptr_type, tmp557) = tmp558 ; return /* (tmp549) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVarlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 28414(line=983, offs=21) -- 28527(line=987, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp560) ; ATSlocal (ats_ptr_type, tmp561) ; ATSlocal (ats_ptr_type, tmp562) ; ATSlocal (ats_ptr_type, tmp563) ; ATSlocal (ats_ptr_type, tmp564) ; ATSlocal (ats_ptr_type, tmp565) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr: tmp561 = atspre_ref_get_view_ptr (statmp509) ; tmp562 = ats_selsin_mac(tmp561, atslab_1) ; tmp564 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp564)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp564, atslab_0, arg0) ; tmp565 = ats_ptrget_mac(ats_ptr_type, tmp562) ; tmp563 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp563, atslab_0, tmp564) ; ats_selptrset_mac(anairiats_sum_8, tmp563, atslab_1, tmp565) ; ats_ptrget_mac(ats_ptr_type, tmp562) = tmp563 ; return /* (tmp560) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 28595(line=990, offs=25) -- 28708(line=994, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr_ref (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp566) ; ATSlocal (ats_ptr_type, tmp567) ; ATSlocal (ats_ptr_type, tmp568) ; ATSlocal (ats_ptr_type, tmp569) ; ATSlocal (ats_ptr_type, tmp570) ; ATSlocal (ats_ptr_type, tmp571) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr_ref: tmp567 = atspre_ref_get_view_ptr (statmp509) ; tmp568 = ats_selsin_mac(tmp567, atslab_1) ; tmp570 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp570)->tag = 1 ; ats_selptrset_mac(anairiats_sum_4, tmp570, atslab_0, arg0) ; tmp571 = ats_ptrget_mac(ats_ptr_type, tmp568) ; tmp569 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp569, atslab_0, tmp570) ; ats_selptrset_mac(anairiats_sum_8, tmp569, atslab_1, tmp571) ; ats_ptrget_mac(ats_ptr_type, tmp568) = tmp569 ; return /* (tmp566) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr_ref] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 28797(line=999, offs=21) -- 29166(line=1010, offs=8) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp572) ; ATSlocal (ats_ptr_type, tmp573) ; ATSlocal (ats_int_type, tmp574) ; ATSlocal (ats_ptr_type, tmp575) ; ATSlocal (ats_ptr_type, tmp576) ; ATSlocal (ats_bool_type, tmp577) ; // ATSlocal_void (tmp578) ; // ATSlocal_void (tmp579) ; ATSlocal (ats_ptr_type, tmp580) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop: tmp573 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_s2exp_node) ; do { /* branch: __ats_lab_120 */ __ats_lab_120_0: if (((ats_sum_ptr_type)tmp573)->tag != 27) { goto __ats_lab_121_0 ; } __ats_lab_120_1: tmp574 = ats_caselptrlab_mac(anairiats_sum_20, tmp573, atslab_0) ; tmp575 = ats_caselptrlab_mac(anairiats_sum_20, tmp573, atslab_1) ; tmp576 = ats_caselptrlab_mac(anairiats_sum_20, tmp573, atslab_2) ; tmp577 = atspre_gt_int_int (tmp574, 0) ; if (!tmp577) { goto __ats_lab_121_1 ; } /* tmp578 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp579 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_tyleq_solve (arg0, tmp575, tmp576) ; /* tmp572 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (arg0) ; break ; /* branch: __ats_lab_121 */ __ats_lab_121_0: __ats_lab_121_1: tmp580 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_prop (arg0, arg1) ; /* tmp572 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr (tmp580) ; break ; } while (0) ; return /* (tmp572) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 29247(line=1014, offs=24) -- 29455(line=1021, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp581) ; ATSlocal (ats_ptr_type, tmp582) ; ATSlocal (ats_ptr_type, tmp583) ; // ATSlocal_void (tmp584) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst: do { /* branch: __ats_lab_122 */ __ats_lab_122_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_123_0 ; } __ats_lab_122_1: tmp582 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp583 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp584 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop (arg0, tmp582) ; arg0 = arg0 ; arg1 = tmp583 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst ; // tail call break ; /* branch: __ats_lab_123 */ __ats_lab_123_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_123_1: break ; } while (0) ; return /* (tmp581) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 29528(line=1025, offs=27) -- 29748(line=1032, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp585) ; ATSlocal (ats_ptr_type, tmp586) ; ATSlocal (ats_ptr_type, tmp587) ; // ATSlocal_void (tmp588) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst: do { /* branch: __ats_lab_124 */ __ats_lab_124_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_125_0 ; } __ats_lab_124_1: tmp586 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp587 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp588 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp586) ; arg0 = arg0 ; arg1 = tmp587 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst ; // tail call break ; /* branch: __ats_lab_125 */ __ats_lab_125_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_125_1: break ; } while (0) ; return /* (tmp585) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 29841(line=1039, offs=3) -- 30141(line=1049, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp589) ; ATSlocal (ats_ptr_type, tmp590) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq: tmp590 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_eqeq (arg1, arg2) ; /* tmp589 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop (arg0, tmp590) ; return /* (tmp589) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_eqeq] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 30208(line=1053, offs=3) -- 30328(line=1057, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp591) ; ATSlocal (ats_ptr_type, tmp592) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq: tmp592 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_tyleq (0, arg1, arg2) ; /* tmp591 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_prop (arg0, tmp592) ; return /* (tmp591) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_tyleq] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 30419(line=1062, offs=26) -- 30690(line=1072, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp593) ; ATSlocal (ats_ptr_type, tmp594) ; ATSlocal (ats_ptr_type, tmp595) ; ATSlocal (ats_ptr_type, tmp596) ; ATSlocal (ats_ptr_type, tmp597) ; ATSlocal (ats_ptr_type, tmp598) ; ATSlocal (ats_ptr_type, tmp599) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop: tmp594 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_prop (arg0, arg1) ; tmp595 = atspre_ref_get_view_ptr (statmp509) ; tmp596 = ats_selsin_mac(tmp595, atslab_1) ; tmp598 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp598)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp598, atslab_0, tmp594) ; tmp599 = ats_ptrget_mac(ats_ptr_type, tmp596) ; tmp597 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp597, atslab_0, tmp598) ; ats_selptrset_mac(anairiats_sum_8, tmp597, atslab_1, tmp599) ; ats_ptrget_mac(ats_ptr_type, tmp596) = tmp597 ; return /* (tmp593) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 30767(line=1075, offs=29) -- 30972(line=1081, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp600) ; ATSlocal (ats_ptr_type, tmp601) ; ATSlocal (ats_ptr_type, tmp602) ; // ATSlocal_void (tmp603) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst: do { /* branch: __ats_lab_126 */ __ats_lab_126_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_127_0 ; } __ats_lab_126_1: tmp601 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp602 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp603 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, tmp601) ; arg0 = arg0 ; arg1 = tmp602 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst ; // tail call break ; /* branch: __ats_lab_127 */ __ats_lab_127_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_127_1: break ; } while (0) ; return /* (tmp600) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 31051(line=1086, offs=3) -- 31691(line=1106, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp604) ; ATSlocal (ats_ptr_type, tmp605) ; ATSlocal (ats_ptr_type, tmp606) ; // ATSlocal_void (tmp607) ; ATSlocal (ats_ptr_type, tmp608) ; ATSlocal (ats_ptr_type, tmp609) ; ATSlocal (ats_ptr_type, tmp610) ; ATSlocal (ats_ptr_type, tmp611) ; ATSlocal (ats_ptr_type, tmp612) ; ATSlocal (ats_ptr_type, tmp613) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind: tmp605 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_find (arg1) ; do { /* branch: __ats_lab_128 */ __ats_lab_128_0: if (tmp605 == (ats_sum_ptr_type)0) { goto __ats_lab_129_0 ; } __ats_lab_128_1: tmp606 = ats_caselptrlab_mac(anairiats_sum_12, tmp605, atslab_0) ; ATS_FREE(tmp605) ; /* tmp604 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (arg0, tmp606, arg2) ; break ; /* branch: __ats_lab_129 */ __ats_lab_129_0: // if (tmp605 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_129_1: /* tmp607 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_add (arg1, arg2) ; tmp608 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_bind (arg0, arg1, arg2) ; tmp609 = atspre_ref_get_view_ptr (statmp509) ; tmp610 = ats_selsin_mac(tmp609, atslab_1) ; tmp612 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp612)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp612, atslab_0, tmp608) ; tmp613 = ats_ptrget_mac(ats_ptr_type, tmp610) ; tmp611 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp611, atslab_0, tmp612) ; ats_selptrset_mac(anairiats_sum_8, tmp611, atslab_1, tmp613) ; ats_ptrget_mac(ats_ptr_type, tmp610) = tmp611 ; break ; } while (0) ; return /* (tmp604) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_bind] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 31767(line=1110, offs=3) -- 32132(line=1121, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp614) ; ATSlocal (ats_ptr_type, tmp615) ; ATSlocal (ats_ptr_type, tmp616) ; ATSlocal (ats_ptr_type, tmp617) ; ATSlocal (ats_ptr_type, tmp618) ; ATSlocal (ats_ptr_type, tmp619) ; ATSlocal (ats_ptr_type, tmp620) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq: tmp615 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__h3ypo_eqeq (arg0, arg1, arg2) ; tmp616 = atspre_ref_get_view_ptr (statmp509) ; tmp617 = ats_selsin_mac(tmp616, atslab_1) ; tmp619 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp619)->tag = 3 ; ats_selptrset_mac(anairiats_sum_4, tmp619, atslab_0, tmp615) ; tmp620 = ats_ptrget_mac(ats_ptr_type, tmp617) ; tmp618 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp618, atslab_0, tmp619) ; ats_selptrset_mac(anairiats_sum_8, tmp618, atslab_1, tmp620) ; ats_ptrget_mac(ats_ptr_type, tmp617) = tmp618 ; return /* (tmp614) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_eqeq] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 32212(line=1125, offs=3) -- 32471(line=1131, offs=22) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp621) ; ATSlocal (anairiats_rec_1, tmp622) ; ATSlocal (ats_ptr_type, tmp623) ; // ATSlocal_void (tmp624) ; ATSlocal (ats_ptr_type, tmp625) ; // ATSlocal_void (tmp626) ; ATSlocal (ats_ptr_type, tmp627) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst: do { /* branch: __ats_lab_130 */ __ats_lab_130_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_131_0 ; } __ats_lab_130_1: tmp622 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_0) ; tmp623 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_1) ; tmp625 = ats_select_mac(tmp622, atslab_0) ; /* tmp624 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp625) ; tmp627 = ats_select_mac(tmp622, atslab_1) ; /* tmp626 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp627) ; arg0 = arg0 ; arg1 = tmp623 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst ; // tail call break ; /* branch: __ats_lab_131 */ __ats_lab_131_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_131_1: break ; } while (0) ; return /* (tmp621) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_s2qualst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 32574(line=1137, offs=4) -- 32738(line=1142, offs=4) */ ATSstaticdec() ats_void_type trans3_env_hypo_add_disj_96 (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp628) ; ATSlocal (ats_ptr_type, tmp629) ; ATSlocal (ats_ptr_type, tmp630) ; ATSlocal (ats_ptr_type, tmp631) ; ATSlocal (ats_ptr_type, tmp632) ; ATSlocal (ats_ptr_type, tmp633) ; __ats_lab_trans3_env_hypo_add_disj_96: tmp629 = atspre_ref_get_view_ptr (statmp509) ; tmp630 = ats_selsin_mac(tmp629, atslab_1) ; tmp632 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp632)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp632, atslab_0, arg0) ; tmp633 = ats_ptrget_mac(ats_ptr_type, tmp630) ; tmp631 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp631, atslab_0, tmp632) ; ats_selptrset_mac(anairiats_sum_8, tmp631, atslab_1, tmp633) ; ats_ptrget_mac(ats_ptr_type, tmp630) = tmp631 ; return /* (tmp628) */ ; } /* end of [trans3_env_hypo_add_disj_96] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 32934(line=1152, offs=21) -- 33041(line=1156, offs=4) */ ATSglobaldec() ats_void_type atsopt_print_the_s3itemlst () { /* local vardec */ // ATSlocal_void (tmp634) ; ATSlocal (ats_ptr_type, tmp635) ; ATSlocal (ats_ptr_type, tmp636) ; ATSlocal (ats_ptr_type, tmp637) ; __ats_lab_atsopt_print_the_s3itemlst: tmp635 = atspre_ref_get_view_ptr (statmp509) ; tmp636 = ats_selsin_mac(tmp635, atslab_1) ; tmp637 = ats_ptrget_mac(ats_ptr_type, tmp636) ; /* tmp634 = */ atsopt_print_s3itemlst (tmp637) ; return /* (tmp634) */ ; } /* end of [atsopt_print_the_s3itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 33225(line=1164, offs=24) -- 33340(line=1168, offs=4) */ ATSglobaldec() ats_void_type atsopt_print_the_s3itemlstlst () { /* local vardec */ // ATSlocal_void (tmp638) ; ATSlocal (ats_ptr_type, tmp639) ; ATSlocal (ats_ptr_type, tmp640) ; ATSlocal (ats_ptr_type, tmp641) ; __ats_lab_atsopt_print_the_s3itemlstlst: tmp639 = atspre_ref_get_view_ptr (statmp511) ; tmp640 = ats_selsin_mac(tmp639, atslab_1) ; tmp641 = ats_ptrget_mac(ats_ptr_type, tmp640) ; /* tmp638 = */ atsopt_print_s3itemlstlst (tmp641) ; return /* (tmp638) */ ; } /* end of [atsopt_print_the_s3itemlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 33497(line=1176, offs=20) -- 33637(line=1181, offs=4) */ ATSglobaldec() ats_void_type atsopt_free_the_s3itemlst () { /* local vardec */ // ATSlocal_void (tmp642) ; ATSlocal (ats_ptr_type, tmp643) ; ATSlocal (ats_ptr_type, tmp644) ; ATSlocal (ats_ptr_type, tmp645) ; ATSlocal (ats_ptr_type, tmp646) ; __ats_lab_atsopt_free_the_s3itemlst: tmp643 = atspre_ref_get_view_ptr (statmp509) ; tmp644 = ats_selsin_mac(tmp643, atslab_1) ; tmp645 = ats_ptrget_mac(ats_ptr_type, tmp644) ; tmp646 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp644) = tmp646 ; /* tmp642 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (tmp645) ; return /* (tmp642) */ ; } /* end of [atsopt_free_the_s3itemlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 33720(line=1186, offs=20) -- 34703(line=1214, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta () { /* local vardec */ ATSlocal (ats_ptr_type, tmp647) ; // ATSlocal_void (tmp648) ; // ATSlocal_void (tmp649) ; ATSlocal (ats_int_type, tmp650) ; ATSlocal (ats_ptr_type, tmp651) ; ATSlocal (ats_ptr_type, tmp652) ; ATSlocal (ats_ptr_type, tmp653) ; ATSlocal (ats_ptr_type, tmp654) ; ATSlocal (ats_ptr_type, tmp655) ; ATSlocal (ats_ptr_type, tmp656) ; ATSlocal (ats_ptr_type, tmp657) ; // ATSlocal_void (tmp658) ; ATSlocal (ats_bool_type, tmp659) ; // ATSlocal_void (tmp660) ; // ATSlocal_void (tmp661) ; // ATSlocal_void (tmp662) ; ATSlocal (ats_ptr_type, tmp663) ; ATSlocal (ats_ptr_type, tmp664) ; ATSlocal (ats_ptr_type, tmp665) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta: /* tmp648 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_pop () ; /* tmp649 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_pop () ; /* ats_int_type tmp650 ; */ tmp650 = 0 ; tmp651 = atspre_ref_get_view_ptr (statmp511) ; tmp652 = ats_selsin_mac(tmp651, atslab_1) ; tmp654 = ats_ptrget_mac(ats_ptr_type, tmp652) ; do { /* branch: __ats_lab_132 */ __ats_lab_132_0: if (tmp654 == (ats_sum_ptr_type)0) { goto __ats_lab_133_0 ; } __ats_lab_132_1: tmp655 = ats_caselptrlab_mac(anairiats_sum_8, tmp654, atslab_0) ; tmp656 = ats_caselptrlab_mac(anairiats_sum_8, tmp654, atslab_1) ; ATS_FREE(tmp654) ; ats_ptrget_mac(ats_ptr_type, tmp652) = tmp656 ; tmp653 = tmp655 ; break ; /* branch: __ats_lab_133 */ __ats_lab_133_0: // if (tmp654 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_133_1: tmp657 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp652) = tmp657 ; tmp650 = 1 ; tmp653 = (ats_sum_ptr_type)0 ; break ; } while (0) ; tmp659 = atspre_gt_int_int (tmp650, 0) ; if (tmp659) { /* tmp660 = */ prerr_interror_1 () ; /* tmp661 = */ atspre_prerr_string (ATSstrcst(": trans3_env_pop_sta: [the_s3itemlstlst] is empty.")) ; /* tmp662 = */ atspre_prerr_newline () ; /* tmp658 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ tmp663 = atspre_ref_get_view_ptr (statmp509) ; tmp664 = ats_selsin_mac(tmp663, atslab_1) ; tmp665 = ats_ptrget_mac(ats_ptr_type, tmp664) ; ats_ptrget_mac(ats_ptr_type, tmp664) = tmp653 ; tmp647 = tmp665 ; return (tmp647) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 34773(line=1217, offs=28) -- 35125(line=1228, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp666) ; ATSlocal (ats_ptr_type, tmp667) ; ATSlocal (ats_ptr_type, tmp668) ; ATSlocal (ats_ptr_type, tmp669) ; ATSlocal (ats_ptr_type, tmp670) ; ATSlocal (ats_ptr_type, tmp671) ; ATSlocal (ats_ptr_type, tmp672) ; ATSlocal (ats_ptr_type, tmp673) ; ATSlocal (ats_ptr_type, tmp674) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add: tmp667 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta () ; tmp669 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp667) ; tmp668 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_itmlst (arg0, arg1, tmp669) ; tmp670 = atspre_ref_get_view_ptr (statmp509) ; tmp671 = ats_selsin_mac(tmp670, atslab_1) ; tmp673 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp673)->tag = 0 ; ats_selptrset_mac(anairiats_sum_4, tmp673, atslab_0, tmp668) ; tmp674 = ats_ptrget_mac(ats_ptr_type, tmp671) ; tmp672 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp672, atslab_0, tmp673) ; ats_selptrset_mac(anairiats_sum_8, tmp672, atslab_1, tmp674) ; ats_ptrget_mac(ats_ptr_type, tmp671) = tmp672 ; return /* (tmp666) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 35208(line=1231, offs=33) -- 35267(line=1232, offs=52) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp675) ; ATSlocal (ats_ptr_type, tmp676) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none: tmp676 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__C3STRKINDmain_0) ; /* tmp675 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add (arg0, tmp676) ; return /* (tmp675) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 35321(line=1236, offs=29) -- 35403(line=1238, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_free () { /* local vardec */ // ATSlocal_void (tmp677) ; ATSlocal (ats_ptr_type, tmp678) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_free: tmp678 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta () ; /* tmp677 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_free__boxed (tmp678) ; return /* (tmp677) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_free] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 35496(line=1243, offs=21) -- 36102(line=1263, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () { /* local vardec */ // ATSlocal_void (tmp679) ; ATSlocal (ats_ptr_type, tmp680) ; ATSlocal (ats_ptr_type, tmp681) ; ATSlocal (ats_ptr_type, tmp682) ; ATSlocal (ats_ptr_type, tmp683) ; ATSlocal (ats_ptr_type, tmp684) ; ATSlocal (ats_ptr_type, tmp685) ; ATSlocal (ats_ptr_type, tmp686) ; ATSlocal (ats_ptr_type, tmp687) ; ATSlocal (ats_ptr_type, tmp688) ; // ATSlocal_void (tmp689) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta: /* ats_ptr_type tmp680 ; */ tmp681 = atspre_ref_get_view_ptr (statmp509) ; tmp682 = ats_selsin_mac(tmp681, atslab_1) ; tmp683 = ats_ptrget_mac(ats_ptr_type, tmp682) ; tmp680 = tmp683 ; tmp684 = (ats_sum_ptr_type)0 ; ats_ptrget_mac(ats_ptr_type, tmp682) = tmp684 ; tmp685 = atspre_ref_get_view_ptr (statmp511) ; tmp686 = ats_selsin_mac(tmp685, atslab_1) ; tmp688 = ats_ptrget_mac(ats_ptr_type, tmp686) ; tmp687 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp687, atslab_0, tmp680) ; ats_selptrset_mac(anairiats_sum_8, tmp687, atslab_1, tmp688) ; ats_ptrget_mac(ats_ptr_type, tmp686) = tmp687 ; /* tmp689 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_push () ; /* tmp679 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_push () ; return /* (tmp679) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 36230(line=1272, offs=20) -- 36401(line=1277, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp690) ; ATSlocal (ats_ptr_type, tmp691) ; // ATSlocal_void (tmp692) ; ATSlocal (ats_ptr_type, tmp693) ; // ATSlocal_void (tmp694) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt: tmp691 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_srt (arg0, arg1) ; tmp693 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev () ; /* tmp692 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset (tmp691, tmp693) ; /* tmp694 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar (tmp691) ; tmp690 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var (tmp691) ; return (tmp690) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_srt] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 36463(line=1280, offs=20) -- 36860(line=1295, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp695) ; ATSlocal (ats_ptr_type, tmp696) ; // ATSlocal_void (tmp697) ; ATSlocal (ats_ptr_type, tmp698) ; // ATSlocal_void (tmp699) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var: tmp696 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_make_var (arg0, arg1) ; tmp698 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get_prev () ; /* tmp697 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Var_set_sVarset (tmp696, tmp698) ; /* tmp699 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_sVar (tmp696) ; tmp695 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_Var (tmp696) ; return (tmp695) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 37223(line=1309, offs=9) -- 37638(line=1321, offs=34) */ ATSstaticdec() ats_ptr_type aux_108 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp701) ; ATSlocal (ats_ptr_type, tmp702) ; ATSlocal (ats_ptr_type, tmp703) ; ATSlocal (ats_ptr_type, tmp704) ; ATSlocal (ats_ptr_type, tmp705) ; __ats_lab_aux_108: do { /* branch: __ats_lab_134 */ __ats_lab_134_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_135_0 ; } __ats_lab_134_1: tmp702 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp703 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp704 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_Var_make_var (arg0, tmp702) ; tmp705 = aux_108 (arg0, tmp703) ; tmp701 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (tmp705, tmp702, tmp704) ; break ; /* branch: __ats_lab_135 */ __ats_lab_135_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_135_1: tmp701 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; break ; } while (0) ; return (tmp701) ; } /* end of [aux_108] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 36952(line=1301, offs=3) -- 37888(line=1331, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp700) ; ATSlocal (ats_ptr_type, tmp706) ; ATSlocal (ats_ptr_type, tmp707) ; // ATSlocal_void (tmp708) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add: tmp706 = aux_108 (arg0, arg1) ; tmp707 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp706, arg2) ; /* tmp708 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp707) ; tmp700 = tmp706 ; return (tmp700) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 38017(line=1336, offs=7) -- 39255(line=1368, offs=10) */ ATSstaticdec() ats_ptr_type aux_110 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp710) ; ATSlocal (ats_ptr_type, tmp711) ; ATSlocal (ats_ptr_type, tmp712) ; ATSlocal (ats_ptr_type, tmp713) ; ATSlocal (ats_ptr_type, tmp714) ; ATSlocal (ats_ptr_type, tmp715) ; ATSlocal (ats_ptr_type, tmp716) ; // ATSlocal_void (tmp717) ; ATSlocal (ats_bool_type, tmp718) ; // ATSlocal_void (tmp719) ; // ATSlocal_void (tmp720) ; // ATSlocal_void (tmp721) ; // ATSlocal_void (tmp722) ; // ATSlocal_void (tmp723) ; // ATSlocal_void (tmp724) ; // ATSlocal_void (tmp725) ; // ATSlocal_void (tmp726) ; // ATSlocal_void (tmp727) ; ATSlocal (ats_ptr_type, tmp728) ; // ATSlocal_void (tmp729) ; // ATSlocal_void (tmp730) ; // ATSlocal_void (tmp731) ; // ATSlocal_void (tmp732) ; // ATSlocal_void (tmp733) ; // ATSlocal_void (tmp734) ; __ats_lab_aux_110: do { /* branch: __ats_lab_136 */ __ats_lab_136_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_137_0 ; } __ats_lab_136_1: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_138_1 ; } __ats_lab_136_2: tmp711 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp712 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp713 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp714 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp715 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2var_get_srt (tmp711) ; tmp716 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp713), atslab_s2exp_srt) ; tmp718 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__lte_s2rt_s2rt (tmp716, tmp715) ; if (tmp718) { /* empty */ } else { /* tmp719 = */ prerr_loc_error3_0 (env1) ; /* tmp720 = */ atspre_prerr_string (ATSstrcst(": the static expression [")) ; /* tmp721 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp713) ; /* tmp722 = */ atspre_prerr_string (ATSstrcst("] is of sort [")) ; /* tmp723 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp716) ; /* tmp724 = */ atspre_prerr_string (ATSstrcst("] but is expected to be of sort [")) ; /* tmp725 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2rt (tmp715) ; /* tmp726 = */ atspre_prerr_string (ATSstrcst("].")) ; /* tmp727 = */ atspre_prerr_newline () ; /* tmp717 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } /* end of [if] */ tmp728 = aux_110 (env0, env1, tmp712, tmp714) ; tmp710 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_add (tmp728, tmp711, tmp713) ; break ; /* branch: __ats_lab_137 */ __ats_lab_137_0: if (arg0 != (ats_sum_ptr_type)0) { goto __ats_lab_138_0 ; } __ats_lab_137_1: if (arg1 != (ats_sum_ptr_type)0) { goto __ats_lab_139_1 ; } __ats_lab_137_2: tmp710 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil ; break ; /* branch: __ats_lab_138 */ __ats_lab_138_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_139_0 ; } __ats_lab_138_1: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_138_2: /* tmp729 = */ prerr_loc_error3_0 (env0) ; /* tmp730 = */ atspre_prerr_string (ATSstrcst(": the static application needs more arguments.")) ; /* tmp731 = */ atspre_prerr_newline () ; /* tmp710 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; /* branch: __ats_lab_139 */ __ats_lab_139_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_1: // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_139_2: /* tmp732 = */ prerr_loc_error3_0 (env0) ; /* tmp733 = */ atspre_prerr_string (ATSstrcst(": the static application needs fewer arguments.")) ; /* tmp734 = */ atspre_prerr_newline () ; /* tmp710 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp710) ; } /* end of [aux_110] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_110_closure_type ; ats_ptr_type aux_110_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_110 (((aux_110_closure_type*)cloptr)->closure_env_0, ((aux_110_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_110_closure_init (aux_110_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_110_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_110_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_110_closure_type *p_clo = ATS_MALLOC(sizeof(aux_110_closure_type)) ; aux_110_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 37971(line=1335, offs=3) -- 39424(line=1374, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (ats_ptr_type, tmp709) ; ATSlocal (ats_ptr_type, tmp735) ; ATSlocal (ats_ptr_type, tmp736) ; // ATSlocal_void (tmp737) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add: tmp735 = aux_110 (arg0, arg3, arg1, arg4) ; tmp736 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp735, arg2) ; /* tmp737 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_proplst (arg0, tmp736) ; tmp709 = tmp735 ; return (tmp709) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 39512(line=1378, offs=3) -- 39758(line=1385, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_hypo_instantiate_and_add (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp738) ; ATSlocal (anairiats_rec_1, tmp739) ; ATSlocal (ats_ptr_type, tmp740) ; ATSlocal (ats_ptr_type, tmp741) ; ATSlocal (ats_ptr_type, tmp742) ; // ATSlocal_void (tmp743) ; // ATSlocal_void (tmp744) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_hypo_instantiate_and_add: tmp739 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_extend_svarlst (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__stasub_nil, arg1) ; tmp740 = ats_select_mac(tmp739, atslab_0) ; tmp741 = ats_select_mac(tmp739, atslab_1) ; tmp742 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (tmp740, arg2) ; /* tmp743 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp741) ; /* tmp744 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp742) ; tmp738 = tmp740 ; return (tmp738) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_hypo_instantiate_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 39861(line=1391, offs=3) -- 40582(line=1410, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metric_instantiate (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp745) ; ATSlocal (atsopt_count_type, tmp746) ; ATSlocal (ats_ptr_type, tmp747) ; ATSlocal (ats_ptr_type, tmp748) ; ATSlocal (ats_ptr_type, tmp749) ; // ATSlocal_void (tmp750) ; // ATSlocal_void (tmp751) ; // ATSlocal_void (tmp752) ; ATSlocal (ats_int_type, tmp753) ; // ATSlocal_void (tmp754) ; ATSlocal (ats_bool_type, tmp755) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metric_instantiate: do { /* branch: __ats_lab_140 */ __ats_lab_140_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_143_0 ; } __ats_lab_140_1: tmp746 = ats_caselptrlab_mac(anairiats_sum_22, arg1, atslab_0) ; tmp748 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__metric_env_get (tmp746) ; do { /* branch: __ats_lab_141 */ __ats_lab_141_0: if (tmp748 == (ats_sum_ptr_type)0) { goto __ats_lab_142_0 ; } __ats_lab_141_1: tmp749 = ats_caselptrlab_mac(anairiats_sum_12, tmp748, atslab_0) ; tmp747 = tmp749 ; break ; /* branch: __ats_lab_142 */ __ats_lab_142_0: // if (tmp748 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_142_1: /* tmp750 = */ prerr_interror_1 () ; /* tmp751 = */ atspre_prerr_string (ATSstrcst(": s2exp_metric_instantiate: no metric bound")) ; /* tmp752 = */ atspre_prerr_newline () ; /* tmp747 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp753 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_length_compare (arg2, tmp747) ; tmp755 = atspre_ieq (tmp753, 0) ; /* tmp754 = */ atspre_assert_errmsg (tmp755, ATSstrcst("INTERNAL ERROR: s2exp_metric_instantiate: metric length mismatch")) ; /* tmp745 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec (arg0, arg2, tmp747) ; break ; /* branch: __ats_lab_143 */ __ats_lab_143_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_143_1: break ; } while (0) ; return /* (tmp745) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metric_instantiate] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 40678(line=1415, offs=27) -- 40999(line=1424, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp756) ; ATSlocal (ats_ptr_type, tmp757) ; ATSlocal (ats_ptr_type, tmp758) ; ATSlocal (ats_ptr_type, tmp759) ; ATSlocal (ats_ptr_type, tmp760) ; ATSlocal (ats_ptr_type, tmp761) ; ATSlocal (ats_ptr_type, tmp762) ; ATSlocal (ats_ptr_type, tmp763) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all: tmp757 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp758 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp757), atslab_s2exp_node) ; do { /* branch: __ats_lab_144 */ __ats_lab_144_0: if (((ats_sum_ptr_type)tmp758)->tag != 9) { goto __ats_lab_145_0 ; } __ats_lab_144_1: tmp759 = ats_caselptrlab_mac(anairiats_sum_13, tmp758, atslab_0) ; tmp760 = ats_caselptrlab_mac(anairiats_sum_13, tmp758, atslab_1) ; tmp761 = ats_caselptrlab_mac(anairiats_sum_13, tmp758, atslab_2) ; tmp762 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp759, tmp760) ; tmp763 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp762, tmp761) ; arg0 = arg0 ; arg1 = tmp763 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all ; // tail call break ; /* branch: __ats_lab_145 */ __ats_lab_145_0: __ats_lab_145_1: tmp756 = tmp757 ; break ; } while (0) ; return (tmp756) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 41075(line=1427, offs=27) -- 41557(line=1441, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_one (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp764) ; ATSlocal (ats_ptr_type, tmp765) ; ATSlocal (ats_ptr_type, tmp766) ; ATSlocal (ats_ptr_type, tmp767) ; ATSlocal (ats_ptr_type, tmp768) ; ATSlocal (ats_ptr_type, tmp769) ; ATSlocal (ats_ptr_type, tmp770) ; // ATSlocal_void (tmp771) ; // ATSlocal_void (tmp772) ; // ATSlocal_void (tmp773) ; // ATSlocal_void (tmp774) ; // ATSlocal_void (tmp775) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_one: tmp765 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp766 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp765), atslab_s2exp_node) ; do { /* branch: __ats_lab_146 */ __ats_lab_146_0: if (((ats_sum_ptr_type)tmp766)->tag != 9) { goto __ats_lab_147_0 ; } __ats_lab_146_1: tmp767 = ats_caselptrlab_mac(anairiats_sum_13, tmp766, atslab_0) ; tmp768 = ats_caselptrlab_mac(anairiats_sum_13, tmp766, atslab_1) ; tmp769 = ats_caselptrlab_mac(anairiats_sum_13, tmp766, atslab_2) ; tmp770 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp767, tmp768) ; tmp764 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp770, tmp769) ; break ; /* branch: __ats_lab_147 */ __ats_lab_147_0: __ats_lab_147_1: /* tmp771 = */ prerr_loc_error3_0 (arg0) ; /* tmp772 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp773 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp765) ; /* tmp774 = */ atspre_prerr_string (ATSstrcst("] is expected to be existentially quantified.")) ; /* tmp775 = */ atspre_prerr_newline () ; /* tmp764 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp764) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_one] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 41633(line=1444, offs=27) -- 42217(line=1465, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp776) ; ATSlocal (ats_ptr_type, tmp777) ; ATSlocal (ats_ptr_type, tmp778) ; ATSlocal (ats_ptr_type, tmp779) ; ATSlocal (ats_ptr_type, tmp780) ; ATSlocal (ats_ptr_type, tmp781) ; ATSlocal (ats_ptr_type, tmp782) ; // ATSlocal_void (tmp783) ; // ATSlocal_void (tmp784) ; // ATSlocal_void (tmp785) ; // ATSlocal_void (tmp786) ; // ATSlocal_void (tmp787) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_seq: tmp777 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp778 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp777), atslab_s2exp_node) ; do { /* branch: __ats_lab_148 */ __ats_lab_148_0: if (((ats_sum_ptr_type)tmp778)->tag != 9) { goto __ats_lab_149_0 ; } __ats_lab_148_1: tmp779 = ats_caselptrlab_mac(anairiats_sum_13, tmp778, atslab_0) ; tmp780 = ats_caselptrlab_mac(anairiats_sum_13, tmp778, atslab_1) ; tmp781 = ats_caselptrlab_mac(anairiats_sum_13, tmp778, atslab_2) ; tmp782 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add (arg0, tmp779, tmp780, arg2, arg3) ; tmp776 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp782, tmp781) ; break ; /* branch: __ats_lab_149 */ __ats_lab_149_0: __ats_lab_149_1: /* tmp783 = */ prerr_loc_error3_0 (arg0) ; /* tmp784 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp785 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp777) ; /* tmp786 = */ atspre_prerr_string (ATSstrcst("] is expected to be existentially quantified.")) ; /* tmp787 = */ atspre_prerr_newline () ; /* tmp776 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp776) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 42299(line=1469, offs=3) -- 42610(line=1476, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp788) ; ATSlocal (ats_ptr_type, tmp789) ; ATSlocal (ats_ptr_type, tmp790) ; ATSlocal (ats_ptr_type, tmp791) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg: tmp789 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_s2exparg_node) ; do { /* branch: __ats_lab_150 */ __ats_lab_150_0: if (((ats_sum_ptr_type)tmp789)->tag != 1) { goto __ats_lab_151_0 ; } __ats_lab_150_1: tmp788 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all (arg0, arg1) ; break ; /* branch: __ats_lab_151 */ __ats_lab_151_0: if (((ats_sum_ptr_type)tmp789)->tag != 0) { goto __ats_lab_152_0 ; } __ats_lab_151_1: tmp788 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_one (arg0, arg1) ; break ; /* branch: __ats_lab_152 */ __ats_lab_152_0: // if (((ats_sum_ptr_type)tmp789)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_152_1: tmp790 = ats_caselptrlab_mac(anairiats_sum_4, tmp789, atslab_0) ; tmp791 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_s2exparg_loc) ; tmp788 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_seq (arg0, arg1, tmp791, tmp790) ; break ; } while (0) ; return (tmp788) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_sexparg] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 42846(line=1487, offs=6) -- 43394(line=1505, offs=6) */ ATSstaticdec() ats_void_type auxvar_118 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp793) ; ATSlocal (ats_ptr_type, tmp794) ; ATSlocal (ats_ptr_type, tmp795) ; ATSlocal (ats_ptr_type, tmp796) ; // ATSlocal_void (tmp797) ; ATSlocal (ats_ptr_type, tmp798) ; __ats_lab_auxvar_118: tmp795 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view (arg1) ; do { /* branch: __ats_lab_153 */ __ats_lab_153_0: if (tmp795 == (ats_sum_ptr_type)0) { goto __ats_lab_154_0 ; } __ats_lab_153_1: tmp796 = ats_caselptrlab_mac(anairiats_sum_12, tmp795, atslab_0) ; tmp794 = tmp796 ; break ; /* branch: __ats_lab_154 */ __ats_lab_154_0: // if (tmp795 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_154_1: tmp794 = arg1 ; break ; } while (0) ; /* tmp797 = */ d2var_fin_check_43 (arg0, tmp794) ; tmp798 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__D2VARFINdone_0) ; /* tmp793 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp794, tmp798) ; return /* (tmp793) */ ; } /* end of [auxvar_118] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 43421(line=1507, offs=7) -- 43856(line=1520, offs=6) */ ATSstaticdec() ats_void_type auxpatlst_119 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp799) ; ATSlocal (ats_ptr_type, tmp800) ; ATSlocal (ats_ptr_type, tmp801) ; // ATSlocal_void (tmp802) ; ATSlocal (ats_ptr_type, tmp803) ; ATSlocal (ats_ptr_type, tmp804) ; ATSlocal (ats_ptr_type, tmp805) ; __ats_lab_auxpatlst_119: do { /* branch: __ats_lab_155 */ __ats_lab_155_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_159_0 ; } __ats_lab_155_1: tmp800 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp801 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; tmp803 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, tmp800), atslab_p3at_node) ; do { /* branch: __ats_lab_156 */ __ats_lab_156_0: if (((ats_sum_ptr_type)tmp803)->tag != 13) { goto __ats_lab_157_0 ; } __ats_lab_156_1: tmp804 = ats_caselptrlab_mac(anairiats_sum_5, tmp803, atslab_1) ; /* tmp802 = */ auxvar_118 (arg0, tmp804) ; break ; /* branch: __ats_lab_157 */ __ats_lab_157_0: if (((ats_sum_ptr_type)tmp803)->tag != 2) { goto __ats_lab_158_0 ; } __ats_lab_157_1: tmp805 = ats_caselptrlab_mac(anairiats_sum_20, tmp803, atslab_1) ; /* tmp802 = */ auxvar_118 (arg0, tmp805) ; break ; /* branch: __ats_lab_158 */ __ats_lab_158_0: __ats_lab_158_1: break ; } while (0) ; arg0 = arg0 ; arg1 = tmp801 ; goto __ats_lab_auxpatlst_119 ; // tail call break ; /* branch: __ats_lab_159 */ __ats_lab_159_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_159_1: break ; } while (0) ; return /* (tmp799) */ ; } /* end of [auxpatlst_119] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 42705(line=1481, offs=21) -- 44166(line=1530, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp792) ; ATSlocal (ats_ptr_type, tmp806) ; ATSlocal (ats_ptr_type, tmp807) ; // ATSlocal_void (tmp808) ; // ATSlocal_void (tmp809) ; // ATSlocal_void (tmp810) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check: tmp806 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get () ; do { /* branch: __ats_lab_160 */ __ats_lab_160_0: if (tmp806 == (ats_sum_ptr_type)0) { goto __ats_lab_161_0 ; } __ats_lab_160_1: tmp807 = ats_caselptrlab_mac(anairiats_sum_12, tmp806, atslab_0) ; ATS_FREE(tmp806) ; /* tmp792 = */ auxpatlst_119 (arg0, tmp807) ; break ; /* branch: __ats_lab_161 */ __ats_lab_161_0: // if (tmp806 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_161_1: /* tmp808 = */ prerr_loc_interror_2 (arg0) ; /* tmp809 = */ atspre_prerr_string (ATSstrcst(": funarg_varfin_check: no argument(s).")) ; /* tmp810 = */ atspre_prerr_newline () ; /* tmp792 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return /* (tmp792) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__funarg_varfin_check] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 44398(line=1541, offs=6) -- 45545(line=1574, offs=6) */ ATSstaticdec() ats_void_type aux_121 (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp812) ; ATSlocal (ats_ptr_type, tmp813) ; ATSlocal (ats_ptr_type, tmp814) ; ATSlocal (ats_ptr_type, tmp815) ; ATSlocal (ats_ptr_type, tmp816) ; // ATSlocal_void (tmp817) ; // ATSlocal_void (tmp818) ; // ATSlocal_void (tmp819) ; // ATSlocal_void (tmp820) ; ATSlocal (ats_bool_type, tmp821) ; ATSlocal (ats_ptr_type, tmp822) ; ATSlocal (ats_ptr_type, tmp823) ; ATSlocal (ats_ptr_type, tmp824) ; ATSlocal (ats_ptr_type, tmp825) ; ATSlocal (ats_ptr_type, tmp826) ; __ats_lab_aux_121: tmp814 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_24, arg2), atslab_p3at_node) ; do { /* branch: __ats_lab_162 */ __ats_lab_162_0: if (((ats_sum_ptr_type)tmp814)->tag != 13) { goto __ats_lab_163_0 ; } __ats_lab_162_1: tmp815 = ats_caselptrlab_mac(anairiats_sum_5, tmp814, atslab_1) ; tmp813 = tmp815 ; break ; /* branch: __ats_lab_163 */ __ats_lab_163_0: if (((ats_sum_ptr_type)tmp814)->tag != 2) { goto __ats_lab_164_0 ; } __ats_lab_163_1: tmp816 = ats_caselptrlab_mac(anairiats_sum_20, tmp814, atslab_1) ; tmp813 = tmp816 ; break ; /* branch: __ats_lab_164 */ __ats_lab_164_0: __ats_lab_164_1: /* tmp817 = */ prerr_loc_interror_2 (arg0) ; /* tmp818 = */ atspre_prerr_string (ATSstrcst(": s2exp_wth_instantiate: aux: p3t = ")) ; /* tmp819 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__prerr_p3at (arg2) ; /* tmp820 = */ atspre_prerr_newline () ; /* tmp813 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; do { /* branch: __ats_lab_165 */ __ats_lab_165_0: __ats_lab_165_1: tmp821 = atspre_eq_int_int (arg1, 0) ; if (!tmp821) { goto __ats_lab_166_1 ; } tmp822 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp822)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp822, atslab_0, arg3) ; /* tmp812 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp813, tmp822) ; break ; /* branch: __ats_lab_166 */ __ats_lab_166_0: __ats_lab_166_1: tmp823 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_view_some (arg0, tmp813) ; tmp824 = ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_get_addr_some (arg0, tmp813) ; tmp825 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_at_viewt0ype_addr_view (arg3, tmp824) ; tmp826 = ATS_MALLOC(sizeof(anairiats_sum_4)) ; ((ats_sum_ptr_type)tmp826)->tag = 2 ; ats_selptrset_mac(anairiats_sum_4, tmp826, atslab_0, tmp825) ; /* tmp812 = */ ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2var_set_fin (tmp823, tmp826) ; break ; } while (0) ; return /* (tmp812) */ ; } /* end of [aux_121] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 45568(line=1575, offs=7) -- 46402(line=1596, offs=30) */ ATSstaticdec() ats_void_type auxlst_122 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp827) ; ATSlocal (ats_int_type, tmp828) ; ATSlocal (ats_ptr_type, tmp829) ; ATSlocal (ats_ptr_type, tmp830) ; // ATSlocal_void (tmp831) ; ATSlocal (ats_bool_type, tmp832) ; ATSlocal (ats_ptr_type, tmp833) ; ATSlocal (ats_ptr_type, tmp834) ; // ATSlocal_void (tmp835) ; ATSlocal (ats_ptr_type, tmp836) ; ATSlocal (ats_ptr_type, tmp837) ; __ats_lab_auxlst_122: do { /* branch: __ats_lab_167 */ __ats_lab_167_0: if (((ats_sum_ptr_type)arg2)->tag != 1) { goto __ats_lab_168_0 ; } __ats_lab_167_1: tmp828 = ats_caselptrlab_mac(anairiats_sum_20, arg2, atslab_0) ; tmp829 = ats_caselptrlab_mac(anairiats_sum_20, arg2, atslab_1) ; tmp830 = ats_caselptrlab_mac(anairiats_sum_20, arg2, atslab_2) ; tmp832 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_is_cons (arg1) ; /* tmp831 = */ atspre_assert_errmsg (tmp832, ATSstrcst("INTERNAL ERROR: s2exp_wth_instantiate")) ; // if (arg1 == (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } tmp833 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp834 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; /* tmp835 = */ aux_121 (arg0, tmp828, tmp833, tmp829) ; arg0 = arg0 ; arg1 = tmp834 ; arg2 = tmp830 ; goto __ats_lab_auxlst_122 ; // tail call break ; /* branch: __ats_lab_168 */ __ats_lab_168_0: if (((ats_sum_ptr_type)arg2)->tag != 2) { goto __ats_lab_169_0 ; } __ats_lab_168_1: tmp836 = ats_caselptrlab_mac(anairiats_sum_4, arg2, atslab_0) ; if (arg1 == (ats_sum_ptr_type)0) { ats_caseof_failure_handle ("/home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 46255(line=1592, offs=14) -- 46283(line=1592, offs=42)") ; } tmp837 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; arg0 = arg0 ; arg1 = tmp837 ; arg2 = tmp836 ; goto __ats_lab_auxlst_122 ; // tail call break ; /* branch: __ats_lab_169 */ __ats_lab_169_0: // if (((ats_sum_ptr_type)arg2)->tag != 0) { ats_deadcode_failure_handle () ; } __ats_lab_169_1: break ; } while (0) ; return /* (tmp827) */ ; } /* end of [auxlst_122] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 44256(line=1535, offs=23) -- 46944(line=1615, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp811) ; ATSlocal (ats_ptr_type, tmp838) ; ATSlocal (ats_ptr_type, tmp839) ; ATSlocal (ats_ptr_type, tmp840) ; ATSlocal (ats_ptr_type, tmp841) ; ATSlocal (ats_ptr_type, tmp842) ; ATSlocal (ats_ptr_type, tmp843) ; ATSlocal (ats_ptr_type, tmp844) ; // ATSlocal_void (tmp845) ; // ATSlocal_void (tmp846) ; // ATSlocal_void (tmp847) ; // ATSlocal_void (tmp848) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate: tmp838 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_exi_instantiate_all (arg0, arg1) ; tmp839 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp838), atslab_s2exp_node) ; do { /* branch: __ats_lab_170 */ __ats_lab_170_0: if (((ats_sum_ptr_type)tmp839)->tag != 35) { goto __ats_lab_173_0 ; } __ats_lab_170_1: tmp840 = ats_caselptrlab_mac(anairiats_sum_7, tmp839, atslab_0) ; tmp841 = ats_caselptrlab_mac(anairiats_sum_7, tmp839, atslab_1) ; tmp842 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_lamloop_env_arg_get () ; do { /* branch: __ats_lab_171 */ __ats_lab_171_0: if (tmp842 == (ats_sum_ptr_type)0) { goto __ats_lab_172_0 ; } __ats_lab_171_1: tmp844 = ats_caselptrlab_mac(anairiats_sum_12, tmp842, atslab_0) ; ATS_FREE(tmp842) ; tmp843 = tmp844 ; break ; /* branch: __ats_lab_172 */ __ats_lab_172_0: // if (tmp842 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_172_1: /* tmp845 = */ prerr_loc_interror_2 (arg0) ; /* tmp846 = */ atspre_prerr_string (ATSstrcst(": s2exp_wth_instantiate")) ; /* tmp847 = */ atspre_prerr_newline () ; /* tmp843 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; /* tmp848 = */ auxlst_122 (arg0, tmp843, tmp841) ; tmp811 = tmp840 ; break ; /* branch: __ats_lab_173 */ __ats_lab_173_0: __ats_lab_173_1: tmp811 = tmp838 ; break ; } while (0) ; return (tmp811) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_wth_instantiate] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 47037(line=1620, offs=27) -- 47557(line=1634, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp849) ; ATSlocal (ats_ptr_type, tmp850) ; ATSlocal (ats_ptr_type, tmp851) ; ATSlocal (ats_ptr_type, tmp852) ; ATSlocal (ats_ptr_type, tmp853) ; ATSlocal (ats_ptr_type, tmp854) ; ATSlocal (ats_ptr_type, tmp855) ; ATSlocal (ats_ptr_type, tmp856) ; ATSlocal (ats_ptr_type, tmp857) ; ATSlocal (ats_ptr_type, tmp858) ; ATSlocal (ats_ptr_type, tmp859) ; // ATSlocal_void (tmp860) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all: tmp850 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp851 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp850), atslab_s2exp_node) ; do { /* branch: __ats_lab_174 */ __ats_lab_174_0: if (((ats_sum_ptr_type)tmp851)->tag != 30) { goto __ats_lab_175_0 ; } __ats_lab_174_1: tmp852 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_0) ; tmp853 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_1) ; tmp854 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_2) ; tmp855 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp852, tmp853) ; tmp856 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp855, tmp854) ; arg0 = arg0 ; arg1 = tmp856 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all ; // tail call break ; /* branch: __ats_lab_175 */ __ats_lab_175_0: if (((ats_sum_ptr_type)tmp851)->tag != 15) { goto __ats_lab_176_0 ; } __ats_lab_175_1: tmp857 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_0) ; tmp858 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_1) ; tmp859 = ats_caselptrlab_mac(anairiats_sum_13, tmp851, atslab_2) ; /* tmp860 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_metric_instantiate (arg0, tmp857, tmp858) ; arg0 = arg0 ; arg1 = tmp859 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all ; // tail call break ; /* branch: __ats_lab_176 */ __ats_lab_176_0: __ats_lab_176_1: tmp849 = tmp850 ; break ; } while (0) ; return (tmp849) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 47632(line=1638, offs=3) -- 48149(line=1656, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_one (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp861) ; ATSlocal (ats_ptr_type, tmp862) ; ATSlocal (ats_ptr_type, tmp863) ; ATSlocal (ats_ptr_type, tmp864) ; ATSlocal (ats_ptr_type, tmp865) ; ATSlocal (ats_ptr_type, tmp866) ; ATSlocal (ats_ptr_type, tmp867) ; // ATSlocal_void (tmp868) ; // ATSlocal_void (tmp869) ; // ATSlocal_void (tmp870) ; // ATSlocal_void (tmp871) ; // ATSlocal_void (tmp872) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_one: tmp862 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp863 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp862), atslab_s2exp_node) ; do { /* branch: __ats_lab_177 */ __ats_lab_177_0: if (((ats_sum_ptr_type)tmp863)->tag != 30) { goto __ats_lab_178_0 ; } __ats_lab_177_1: tmp864 = ats_caselptrlab_mac(anairiats_sum_13, tmp863, atslab_0) ; tmp865 = ats_caselptrlab_mac(anairiats_sum_13, tmp863, atslab_1) ; tmp866 = ats_caselptrlab_mac(anairiats_sum_13, tmp863, atslab_2) ; tmp867 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp864, tmp865) ; tmp861 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp867, tmp866) ; break ; /* branch: __ats_lab_178 */ __ats_lab_178_0: __ats_lab_178_1: /* tmp868 = */ prerr_loc_error3_0 (arg0) ; /* tmp869 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp870 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp862) ; /* tmp871 = */ atspre_prerr_string (ATSstrcst("] is expected to be universally quantified.")) ; /* tmp872 = */ atspre_prerr_newline () ; /* tmp861 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp861) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_one] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 48227(line=1660, offs=3) -- 48788(line=1676, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_seq (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (ats_ptr_type, tmp873) ; ATSlocal (ats_ptr_type, tmp874) ; ATSlocal (ats_ptr_type, tmp875) ; ATSlocal (ats_ptr_type, tmp876) ; ATSlocal (ats_ptr_type, tmp877) ; ATSlocal (ats_ptr_type, tmp878) ; ATSlocal (ats_ptr_type, tmp879) ; // ATSlocal_void (tmp880) ; // ATSlocal_void (tmp881) ; // ATSlocal_void (tmp882) ; // ATSlocal_void (tmp883) ; // ATSlocal_void (tmp884) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_seq: tmp874 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_whnf (arg1) ; tmp875 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp874), atslab_s2exp_node) ; do { /* branch: __ats_lab_179 */ __ats_lab_179_0: if (((ats_sum_ptr_type)tmp875)->tag != 30) { goto __ats_lab_180_0 ; } __ats_lab_179_1: tmp876 = ats_caselptrlab_mac(anairiats_sum_13, tmp875, atslab_0) ; tmp877 = ats_caselptrlab_mac(anairiats_sum_13, tmp875, atslab_1) ; tmp878 = ats_caselptrlab_mac(anairiats_sum_13, tmp875, atslab_2) ; tmp879 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add (arg0, tmp876, tmp877, arg2, arg3) ; tmp873 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp879, tmp878) ; break ; /* branch: __ats_lab_180 */ __ats_lab_180_0: __ats_lab_180_1: /* tmp880 = */ prerr_loc_error3_0 (arg0) ; /* tmp881 = */ atspre_prerr_string (ATSstrcst(": the type [")) ; /* tmp882 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__prerr_s2exp (tmp874) ; /* tmp883 = */ atspre_prerr_string (ATSstrcst("] is expected to be universally quantified.")) ; /* tmp884 = */ atspre_prerr_newline () ; /* tmp873 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; return (tmp873) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_seq] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 48870(line=1680, offs=3) -- 49181(line=1687, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparg (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp885) ; ATSlocal (ats_ptr_type, tmp886) ; ATSlocal (ats_ptr_type, tmp887) ; ATSlocal (ats_ptr_type, tmp888) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparg: tmp886 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_s2exparg_node) ; do { /* branch: __ats_lab_181 */ __ats_lab_181_0: if (((ats_sum_ptr_type)tmp886)->tag != 0) { goto __ats_lab_182_0 ; } __ats_lab_181_1: tmp885 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_one (arg0, arg1) ; break ; /* branch: __ats_lab_182 */ __ats_lab_182_0: if (((ats_sum_ptr_type)tmp886)->tag != 1) { goto __ats_lab_183_0 ; } __ats_lab_182_1: tmp885 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_all (arg0, arg1) ; break ; /* branch: __ats_lab_183 */ __ats_lab_183_0: // if (((ats_sum_ptr_type)tmp886)->tag != 2) { ats_deadcode_failure_handle () ; } __ats_lab_183_1: tmp887 = ats_caselptrlab_mac(anairiats_sum_4, tmp886, atslab_0) ; tmp888 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_23, arg2), atslab_s2exparg_loc) ; tmp885 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_seq (arg0, arg1, tmp888, tmp887) ; break ; } while (0) ; return (tmp885) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparg] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 49270(line=1691, offs=3) -- 49511(line=1699, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_ptr_type, tmp889) ; ATSlocal (ats_ptr_type, tmp890) ; ATSlocal (ats_ptr_type, tmp891) ; ATSlocal (ats_ptr_type, tmp892) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst: do { /* branch: __ats_lab_184 */ __ats_lab_184_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_185_0 ; } __ats_lab_184_1: tmp890 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp891 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; tmp892 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparg (arg0, arg1, tmp890) ; arg0 = arg0 ; arg1 = tmp892 ; arg2 = tmp891 ; goto __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst ; // tail call break ; /* branch: __ats_lab_185 */ __ats_lab_185_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_185_1: tmp889 = arg1 ; break ; } while (0) ; return (tmp889) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_uni_instantiate_sexparglst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 49658(line=1706, offs=7) -- 49928(line=1712, offs=6) */ ATSstaticdec() ats_ptr_type aux0_129 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp894) ; ATSlocal (anairiats_rec_1, tmp895) ; ATSlocal (ats_ptr_type, tmp896) ; ATSlocal (anairiats_rec_1, tmp897) ; ATSlocal (ats_ptr_type, tmp898) ; ATSlocal (ats_ptr_type, tmp899) ; ATSlocal (ats_ptr_type, tmp900) ; ATSlocal (ats_ptr_type, tmp901) ; __ats_lab_aux0_129: do { /* branch: __ats_lab_186 */ __ats_lab_186_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_187_0 ; } __ats_lab_186_1: tmp895 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_0) ; tmp896 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_1) ; tmp898 = ats_select_mac(tmp895, atslab_0) ; tmp900 = ats_select_mac(tmp895, atslab_1) ; tmp899 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_subst (arg0, tmp900) ; tmp897.atslab_0 = tmp898 ; tmp897.atslab_1 = tmp899 ; tmp901 = aux0_129 (arg0, tmp896) ; tmp894 = ATS_MALLOC(sizeof(anairiats_sum_21)) ; ats_selptrset_mac(anairiats_sum_21, tmp894, atslab_0, tmp897) ; ats_selptrset_mac(anairiats_sum_21, tmp894, atslab_1, tmp901) ; break ; /* branch: __ats_lab_187 */ __ats_lab_187_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_187_1: tmp894 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp894) ; } /* end of [aux0_129] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 49952(line=1713, offs=7) -- 50418(line=1723, offs=6) */ ATSstaticdec() anairiats_rec_1 aux1_130 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp902) ; ATSlocal (anairiats_rec_1, tmp903) ; ATSlocal (ats_ptr_type, tmp904) ; ATSlocal (ats_ptr_type, tmp905) ; ATSlocal (ats_ptr_type, tmp906) ; ATSlocal (ats_ptr_type, tmp907) ; ATSlocal (ats_ptr_type, tmp908) ; ATSlocal (ats_ptr_type, tmp909) ; ATSlocal (ats_ptr_type, tmp910) ; ATSlocal (ats_ptr_type, tmp911) ; __ats_lab_aux1_130: do { /* branch: __ats_lab_188 */ __ats_lab_188_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_189_0 ; } __ats_lab_188_1: tmp903 = ats_caselptrlab_mac(anairiats_sum_21, arg2, atslab_0) ; tmp904 = ats_caselptrlab_mac(anairiats_sum_21, arg2, atslab_1) ; tmp906 = ats_select_mac(tmp903, atslab_0) ; tmp907 = ats_select_mac(tmp903, atslab_1) ; tmp905 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_and_add (arg0, tmp906, tmp907) ; tmp908 = aux0_129 (tmp905, tmp904) ; tmp909 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp905, arg3) ; tmp910 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp910, atslab_0, tmp905) ; ats_selptrset_mac(anairiats_sum_8, tmp910, atslab_1, arg1) ; arg0 = arg0 ; arg1 = tmp910 ; arg2 = tmp908 ; arg3 = tmp909 ; goto __ats_lab_aux1_130 ; // tail call break ; /* branch: __ats_lab_189 */ __ats_lab_189_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_189_1: tmp911 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_reverse (arg1) ; tmp902.atslab_0 = tmp911 ; tmp902.atslab_1 = arg3 ; break ; } while (0) ; return (tmp902) ; } /* end of [aux1_130] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 50442(line=1724, offs=7) -- 51432(line=1751, offs=6) */ ATSstaticdec() anairiats_rec_1 aux2_131 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3, ats_ptr_type arg4) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp912) ; ATSlocal (ats_ptr_type, tmp913) ; ATSlocal (ats_ptr_type, tmp914) ; ATSlocal (ats_ptr_type, tmp915) ; ATSlocal (anairiats_rec_1, tmp916) ; ATSlocal (ats_ptr_type, tmp917) ; ATSlocal (ats_ptr_type, tmp918) ; ATSlocal (ats_ptr_type, tmp919) ; ATSlocal (ats_ptr_type, tmp920) ; ATSlocal (ats_ptr_type, tmp921) ; ATSlocal (ats_ptr_type, tmp922) ; ATSlocal (ats_ptr_type, tmp923) ; // ATSlocal_void (tmp924) ; // ATSlocal_void (tmp925) ; // ATSlocal_void (tmp926) ; // ATSlocal_void (tmp927) ; __ats_lab_aux2_131: do { /* branch: __ats_lab_190 */ __ats_lab_190_0: if (arg3 == (ats_sum_ptr_type)0) { goto __ats_lab_193_0 ; } __ats_lab_190_1: tmp913 = ats_caselptrlab_mac(anairiats_sum_25, arg3, atslab_0) ; tmp914 = ats_caselptrlab_mac(anairiats_sum_25, arg3, atslab_1) ; tmp915 = ats_caselptrlab_mac(anairiats_sum_25, arg3, atslab_2) ; do { /* branch: __ats_lab_191 */ __ats_lab_191_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_192_0 ; } __ats_lab_191_1: tmp916 = ats_caselptrlab_mac(anairiats_sum_21, arg2, atslab_0) ; tmp917 = ats_caselptrlab_mac(anairiats_sum_21, arg2, atslab_1) ; tmp919 = ats_select_mac(tmp916, atslab_0) ; tmp920 = ats_select_mac(tmp916, atslab_1) ; tmp918 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2qua_instantiate_with_and_add (arg0, tmp919, tmp920, tmp913, tmp914) ; tmp921 = aux0_129 (tmp918, tmp917) ; tmp922 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_subst (tmp918, arg4) ; tmp923 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp923, atslab_0, tmp918) ; ats_selptrset_mac(anairiats_sum_8, tmp923, atslab_1, arg1) ; arg0 = arg0 ; arg1 = tmp923 ; arg2 = tmp921 ; arg3 = tmp915 ; arg4 = tmp922 ; goto __ats_lab_aux2_131 ; // tail call break ; /* branch: __ats_lab_192 */ __ats_lab_192_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_192_1: /* tmp924 = */ prerr_loc_error3_0 (arg0) ; /* tmp925 = */ atsopt_debug_prerrf (ATSstrcst(": %s: s2exp_template_instantiate"), ATSstrcst("ats_trans3_env.dats")) ; /* tmp926 = */ atspre_prerr_string (ATSstrcst(": too many template arguments are given.")) ; /* tmp927 = */ atspre_prerr_newline () ; /* tmp912 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; break ; /* branch: __ats_lab_193 */ __ats_lab_193_0: // if (arg3 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_193_1: tmp912 = aux1_130 (arg0, arg1, arg2, arg4) ; break ; } while (0) ; return (tmp912) ; } /* end of [aux2_131] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 49618(line=1705, offs=3) -- 51504(line=1754, offs=4) */ ATSglobaldec() anairiats_rec_1 ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ ATSlocal (anairiats_rec_1, tmp893) ; ATSlocal (ats_ptr_type, tmp928) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate: tmp928 = (ats_sum_ptr_type)0 ; tmp893 = aux2_131 (arg0, tmp928, arg1, arg2, arg3) ; return (tmp893) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_template_instantiate] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 51597(line=1759, offs=22) -- 52287(line=1784, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp929) ; ATSlocal (anairiats_rec_2, tmp930) ; ATSlocal (ats_ptr_type, tmp931) ; // ATSlocal_void (tmp932) ; ATSlocal (ats_ptr_type, tmp933) ; // ATSlocal_void (tmp934) ; ATSlocal (ats_ptr_type, tmp935) ; // ATSlocal_void (tmp936) ; ATSlocal (ats_ptr_type, tmp937) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add: tmp930 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_absuni (arg1) ; tmp931 = ats_select_mac(tmp930, atslab_0) ; tmp933 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get () ; /* tmp932 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset (tmp931, tmp933) ; tmp935 = ats_select_mac(tmp930, atslab_0) ; /* tmp934 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp935) ; tmp937 = ats_select_mac(tmp930, atslab_1) ; /* tmp936 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp937) ; tmp929 = ats_select_mac(tmp930, atslab_2) ; return (tmp929) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_absuni_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 52353(line=1787, offs=22) -- 53037(line=1813, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp938) ; ATSlocal (anairiats_rec_2, tmp939) ; ATSlocal (ats_ptr_type, tmp940) ; // ATSlocal_void (tmp941) ; ATSlocal (ats_ptr_type, tmp942) ; // ATSlocal_void (tmp943) ; // ATSlocal_void (tmp944) ; ATSlocal (ats_ptr_type, tmp945) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add: tmp939 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_opnexi (arg1) ; tmp940 = ats_select_mac(tmp939, atslab_0) ; tmp942 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get () ; /* tmp941 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset (tmp940, tmp942) ; /* tmp943 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp940) ; tmp945 = ats_select_mac(tmp939, atslab_1) ; /* tmp944 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp945) ; tmp938 = ats_select_mac(tmp939, atslab_2) ; return (tmp938) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 53108(line=1817, offs=3) -- 53405(line=1827, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2explst_opnexi_and_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp946) ; ATSlocal (anairiats_rec_2, tmp947) ; ATSlocal (ats_ptr_type, tmp948) ; // ATSlocal_void (tmp949) ; ATSlocal (ats_ptr_type, tmp950) ; // ATSlocal_void (tmp951) ; // ATSlocal_void (tmp952) ; ATSlocal (ats_ptr_type, tmp953) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2explst_opnexi_and_add: tmp947 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2explst_opnexi (arg1) ; tmp948 = ats_select_mac(tmp947, atslab_0) ; tmp950 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2Varset_env_get () ; /* tmp949 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2varlst_set_sVarset (tmp948, tmp950) ; /* tmp951 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp948) ; tmp953 = ats_select_mac(tmp947, atslab_1) ; /* tmp952 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp953) ; tmp946 = ats_select_mac(tmp947, atslab_2) ; return (tmp946) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2explst_opnexi_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 53476(line=1831, offs=3) -- 53599(line=1835, offs=4) */ ATSglobaldec() ats_ptr_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp954) ; ATSlocal (ats_ptr_type, tmp955) ; ATSlocal (ats_ptr_type, tmp956) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add: do { /* branch: __ats_lab_194 */ __ats_lab_194_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_195_0 ; } __ats_lab_194_1: tmp955 = ats_caselptrlab_mac(anairiats_sum_12, arg1, atslab_0) ; tmp956 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, tmp955) ; tmp954 = ATS_MALLOC(sizeof(anairiats_sum_12)) ; ats_selptrset_mac(anairiats_sum_12, tmp954, atslab_0, tmp956) ; break ; /* branch: __ats_lab_195 */ __ats_lab_195_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_195_1: tmp954 = (ats_sum_ptr_type)0 ; break ; } while (0) ; return (tmp954) ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2expopt_opnexi_and_add] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 55570(line=1887, offs=15) -- 55884(line=1894, offs=32) */ ATSstaticdec() ats_void_type aux_137 (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp985) ; ATSlocal (anairiats_rec_1, tmp986) ; ATSlocal (ats_ptr_type, tmp987) ; // ATSlocal_void (tmp988) ; ATSlocal (ats_ptr_type, tmp989) ; // ATSlocal_void (tmp990) ; ATSlocal (ats_ptr_type, tmp991) ; __ats_lab_aux_137: do { /* branch: __ats_lab_208 */ __ats_lab_208_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_209_0 ; } __ats_lab_208_1: tmp986 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_0) ; tmp987 = ats_caselptrlab_mac(anairiats_sum_21, arg1, atslab_1) ; tmp989 = ats_select_mac(tmp986, atslab_0) ; /* tmp988 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_svarlst (tmp989) ; tmp991 = ats_select_mac(tmp986, atslab_1) ; /* tmp990 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_proplst (arg0, tmp991) ; arg0 = arg0 ; arg1 = tmp987 ; goto __ats_lab_aux_137 ; // tail call break ; /* branch: __ats_lab_209 */ __ats_lab_209_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_209_1: break ; } while (0) ; return /* (tmp985) */ ; } /* end of [aux_137] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 56552(line=1912, offs=13) -- 56834(line=1918, offs=30) */ ATSstaticdec() ats_void_type aux_138 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1001) ; ATSlocal (ats_ptr_type, tmp1002) ; ATSlocal (ats_ptr_type, tmp1003) ; ATSlocal (ats_ptr_type, tmp1004) ; ATSlocal (ats_ptr_type, tmp1005) ; // ATSlocal_void (tmp1006) ; __ats_lab_aux_138: do { /* branch: __ats_lab_217 */ __ats_lab_217_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_218_0 ; } __ats_lab_217_1: tmp1002 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp1003 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; tmp1005 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (tmp1002) ; tmp1004 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_neq_int_int_bool (env1, tmp1005) ; /* tmp1006 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (env0, tmp1004) ; arg0 = tmp1003 ; goto __ats_lab_aux_138 ; // tail call break ; /* branch: __ats_lab_218 */ __ats_lab_218_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_218_1: break ; } while (0) ; return /* (tmp1001) */ ; } /* end of [aux_138] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_138_closure_type ; ats_void_type aux_138_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_138 (((aux_138_closure_type*)cloptr)->closure_env_0, ((aux_138_closure_type*)cloptr)->closure_env_1, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_138_closure_init (aux_138_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_138_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_138_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_138_closure_type *p_clo = ATS_MALLOC(sizeof(aux_138_closure_type)) ; aux_138_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 53698(line=1841, offs=3) -- 57162(line=1929, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp957) ; ATSlocal (ats_ptr_type, tmp958) ; ATSlocal (ats_bool_type, tmp959) ; ATSlocal (ats_ptr_type, tmp960) ; ATSlocal (ats_ptr_type, tmp961) ; ATSlocal (ats_ptr_type, tmp962) ; ATSlocal (ats_char_type, tmp963) ; ATSlocal (ats_ptr_type, tmp964) ; ATSlocal (ats_ptr_type, tmp965) ; ATSlocal (ats_ptr_type, tmp966) ; ATSlocal (ats_ptr_type, tmp967) ; ATSlocal (ats_ptr_type, tmp968) ; ATSlocal (ats_ptr_type, tmp969) ; ATSlocal (ats_ptr_type, tmp970) ; ATSlocal (ats_bool_type, tmp971) ; ATSlocal (ats_ptr_type, tmp972) ; ATSlocal (anairiats_rec_1, tmp973) ; ATSlocal (ats_ptr_type, tmp974) ; ATSlocal (ats_ptr_type, tmp975) ; ATSlocal (anairiats_rec_1, tmp976) ; ATSlocal (ats_ptr_type, tmp977) ; ATSlocal (ats_ptr_type, tmp978) ; ATSlocal (ats_ptr_type, tmp979) ; // ATSlocal_void (tmp980) ; // ATSlocal_void (tmp981) ; // ATSlocal_void (tmp982) ; ATSlocal (ats_ptr_type, tmp983) ; ATSlocal (ats_ptr_type, tmp984) ; // ATSlocal_void (tmp992) ; // ATSlocal_void (tmp993) ; ATSlocal (ats_ptr_type, tmp994) ; ATSlocal (ats_ptr_type, tmp995) ; ATSlocal (ats_ptr_type, tmp996) ; ATSlocal (ats_ptr_type, tmp997) ; ATSlocal (ats_ptr_type, tmp998) ; ATSlocal (ats_ptr_type, tmp999) ; ATSlocal (ats_ptr_type, tmp1000) ; ATSlocal (ats_ptr_type, tmp1007) ; ATSlocal (ats_ptr_type, tmp1008) ; ATSlocal (ats_ptr_type, tmp1009) ; ATSlocal (ats_ptr_type, tmp1010) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst: tmp958 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__s2exp_opnexi_and_add (arg0, arg2) ; do { /* branch: __ats_lab_196 */ __ats_lab_196_0: if (((ats_sum_ptr_type)arg1)->tag != 0) { goto __ats_lab_197_0 ; } __ats_lab_196_1: break ; /* branch: __ats_lab_197 */ __ats_lab_197_0: if (((ats_sum_ptr_type)arg1)->tag != 1) { goto __ats_lab_200_0 ; } __ats_lab_197_1: tmp959 = ats_caselptrlab_mac(anairiats_sum_26, arg1, atslab_0) ; tmp960 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_bool_bool_t0ype (tmp958) ; do { /* branch: __ats_lab_198 */ __ats_lab_198_0: if (tmp960 == (ats_sum_ptr_type)0) { goto __ats_lab_199_0 ; } __ats_lab_198_1: tmp961 = ats_caselptrlab_mac(anairiats_sum_12, tmp960, atslab_0) ; ATS_FREE(tmp960) ; tmp962 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (tmp959) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp961, tmp962) ; break ; /* branch: __ats_lab_199 */ __ats_lab_199_0: // if (tmp960 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_199_1: break ; } while (0) ; break ; /* branch: __ats_lab_200 */ __ats_lab_200_0: if (((ats_sum_ptr_type)arg1)->tag != 2) { goto __ats_lab_203_0 ; } __ats_lab_200_1: tmp963 = ats_caselptrlab_mac(anairiats_sum_27, arg1, atslab_0) ; tmp964 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_char_char_t0ype (tmp958) ; do { /* branch: __ats_lab_201 */ __ats_lab_201_0: if (tmp964 == (ats_sum_ptr_type)0) { goto __ats_lab_202_0 ; } __ats_lab_201_1: tmp965 = ats_caselptrlab_mac(anairiats_sum_12, tmp964, atslab_0) ; ATS_FREE(tmp964) ; tmp966 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_char (tmp963) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp965, tmp966) ; break ; /* branch: __ats_lab_202 */ __ats_lab_202_0: // if (tmp964 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_202_1: break ; } while (0) ; break ; /* branch: __ats_lab_203 */ __ats_lab_203_0: if (((ats_sum_ptr_type)arg1)->tag != 3) { goto __ats_lab_210_0 ; } __ats_lab_203_1: tmp967 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; tmp968 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_1) ; tmp969 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp958), atslab_s2exp_node) ; do { /* branch: __ats_lab_204 */ __ats_lab_204_0: if (((ats_sum_ptr_type)tmp969)->tag != 6) { goto __ats_lab_205_0 ; } __ats_lab_204_1: tmp970 = ats_caselptrlab_mac(anairiats_sum_7, tmp969, atslab_0) ; tmp971 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__neq_d2con_d2con (tmp967, tmp970) ; if (tmp971) { tmp972 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2exp_bool (ats_false_bool) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_prop (arg0, tmp972) ; } else { /* empty */ } /* end of [if] */ break ; /* branch: __ats_lab_205 */ __ats_lab_205_0: __ats_lab_205_1: tmp973 = ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__p1at_con_instantiate (arg0, tmp967) ; tmp974 = ats_select_mac(tmp973, atslab_0) ; tmp975 = ats_select_mac(tmp973, atslab_1) ; tmp977 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp975), atslab_s2exp_node) ; do { /* branch: __ats_lab_206 */ __ats_lab_206_0: if (((ats_sum_ptr_type)tmp977)->tag != 11) { goto __ats_lab_207_0 ; } __ats_lab_206_1: tmp978 = ats_caselptrlab_mac(anairiats_sum_28, tmp977, atslab_4) ; tmp979 = ats_caselptrlab_mac(anairiats_sum_28, tmp977, atslab_5) ; tmp976.atslab_0 = tmp978 ; tmp976.atslab_1 = tmp979 ; break ; /* branch: __ats_lab_207 */ __ats_lab_207_0: __ats_lab_207_1: /* tmp980 = */ prerr_interror_1 () ; /* tmp981 = */ atspre_prerr_string (ATSstrcst(": tran3_env_hypo_add_p2atcst: P2TCcon")) ; /* tmp982 = */ atspre_prerr_newline () ; /* tmp976 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; break ; } while (0) ; tmp983 = ats_select_mac(tmp976, atslab_0) ; tmp984 = ats_select_mac(tmp976, atslab_1) ; /* tmp992 = */ aux_137 (arg0, tmp974) ; /* tmp993 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp984, tmp958) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst (arg0, tmp968, tmp983) ; break ; } while (0) ; break ; /* branch: __ats_lab_210 */ __ats_lab_210_0: if (((ats_sum_ptr_type)arg1)->tag != 4) { goto __ats_lab_211_0 ; } __ats_lab_210_1: break ; /* branch: __ats_lab_211 */ __ats_lab_211_0: if (((ats_sum_ptr_type)arg1)->tag != 5) { goto __ats_lab_212_0 ; } __ats_lab_211_1: break ; /* branch: __ats_lab_212 */ __ats_lab_212_0: if (((ats_sum_ptr_type)arg1)->tag != 6) { goto __ats_lab_215_0 ; } __ats_lab_212_1: tmp994 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp995 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype (tmp958) ; do { /* branch: __ats_lab_213 */ __ats_lab_213_0: if (tmp995 == (ats_sum_ptr_type)0) { goto __ats_lab_214_0 ; } __ats_lab_213_1: tmp996 = ats_caselptrlab_mac(anairiats_sum_12, tmp995, atslab_0) ; ATS_FREE(tmp995) ; tmp997 = ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2exp_intinf (tmp994) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__s2exp_hypo_equal_solve (arg0, tmp996, tmp997) ; break ; /* branch: __ats_lab_214 */ __ats_lab_214_0: // if (tmp995 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_214_1: break ; } while (0) ; break ; /* branch: __ats_lab_215 */ __ats_lab_215_0: if (((ats_sum_ptr_type)arg1)->tag != 7) { goto __ats_lab_220_0 ; } __ats_lab_215_1: tmp998 = ats_caselptrlab_mac(anairiats_sum_4, arg1, atslab_0) ; tmp999 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__un_s2exp_int_int_t0ype (tmp958) ; do { /* branch: __ats_lab_216 */ __ats_lab_216_0: if (tmp999 == (ats_sum_ptr_type)0) { goto __ats_lab_219_0 ; } __ats_lab_216_1: tmp1000 = ats_caselptrlab_mac(anairiats_sum_12, tmp999, atslab_0) ; ATS_FREE(tmp999) ; tmp1007 = ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__intinflst_of_intinfset (tmp998) ; /* tmp957 = */ aux_138 (arg0, tmp1000, tmp1007) ; break ; /* branch: __ats_lab_219 */ __ats_lab_219_0: // if (tmp999 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_219_1: break ; } while (0) ; break ; /* branch: __ats_lab_220 */ __ats_lab_220_0: if (((ats_sum_ptr_type)arg1)->tag != 8) { goto __ats_lab_223_0 ; } __ats_lab_220_1: tmp1008 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp1009 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, tmp958), atslab_s2exp_node) ; do { /* branch: __ats_lab_221 */ __ats_lab_221_0: if (((ats_sum_ptr_type)tmp1009)->tag != 29) { goto __ats_lab_222_0 ; } __ats_lab_221_1: tmp1010 = ats_caselptrlab_mac(anairiats_sum_29, tmp1009, atslab_2) ; /* tmp957 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_labp2atcstlst (arg0, tmp1008, tmp1010) ; break ; /* branch: __ats_lab_222 */ __ats_lab_222_0: __ats_lab_222_1: break ; } while (0) ; break ; /* branch: __ats_lab_223 */ __ats_lab_223_0: // if (((ats_sum_ptr_type)arg1)->tag != 9) { ats_deadcode_failure_handle () ; } __ats_lab_223_1: break ; } while (0) ; return /* (tmp957) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 57279(line=1934, offs=7) -- 57738(line=1946, offs=6) */ ATSstaticdec() ats_int_type aux_140 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp1012) ; ATSlocal (ats_ptr_type, tmp1013) ; ATSlocal (ats_ptr_type, tmp1014) ; ATSlocal (ats_ptr_type, tmp1015) ; ATSlocal (ats_ptr_type, tmp1016) ; // ATSlocal_void (tmp1017) ; __ats_lab_aux_140: do { /* branch: __ats_lab_224 */ __ats_lab_224_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_227_0 ; } __ats_lab_224_1: tmp1013 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_0) ; tmp1014 = ats_caselptrlab_mac(anairiats_sum_8, arg1, atslab_1) ; do { /* branch: __ats_lab_225 */ __ats_lab_225_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_226_0 ; } __ats_lab_225_1: tmp1015 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_0) ; tmp1016 = ats_caselptrlab_mac(anairiats_sum_8, arg2, atslab_1) ; /* tmp1017 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst (arg0, tmp1013, tmp1015) ; arg0 = arg0 ; arg1 = tmp1014 ; arg2 = tmp1016 ; goto __ats_lab_aux_140 ; // tail call break ; /* branch: __ats_lab_226 */ __ats_lab_226_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_226_1: tmp1012 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_227 */ __ats_lab_227_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_227_1: do { /* branch: __ats_lab_228 */ __ats_lab_228_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_229_0 ; } __ats_lab_228_1: tmp1012 = 1 ; break ; /* branch: __ats_lab_229 */ __ats_lab_229_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_229_1: tmp1012 = 0 ; break ; } while (0) ; break ; } while (0) ; return (tmp1012) ; } /* end of [aux_140] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 57247(line=1933, offs=3) -- 57960(line=1954, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1011) ; ATSlocal (ats_int_type, tmp1018) ; ATSlocal (ats_bool_type, tmp1019) ; // ATSlocal_void (tmp1020) ; // ATSlocal_void (tmp1021) ; // ATSlocal_void (tmp1022) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst: tmp1018 = aux_140 (arg0, arg1, arg2) ; tmp1019 = atspre_gt_int_int (tmp1018, 0) ; if (tmp1019) { /* tmp1020 = */ prerr_loc_interror_2 (arg0) ; /* tmp1021 = */ atspre_prerr_string (ATSstrcst(": trans3_env_hypo_add_p2atcstlst")) ; /* tmp1022 = */ atspre_prerr_newline () ; /* tmp1011 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp1011) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 58085(line=1959, offs=7) -- 58652(line=1972, offs=6) */ ATSstaticdec() ats_int_type aux_142 (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp1024) ; ATSlocal (ats_ptr_type, tmp1025) ; ATSlocal (ats_ptr_type, tmp1026) ; ATSlocal (ats_ptr_type, tmp1027) ; ATSlocal (ats_ptr_type, tmp1028) ; // ATSlocal_void (tmp1029) ; __ats_lab_aux_142: do { /* branch: __ats_lab_230 */ __ats_lab_230_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_233_0 ; } __ats_lab_230_1: tmp1025 = ats_caselptrlab_mac(anairiats_sum_25, arg1, atslab_1) ; tmp1026 = ats_caselptrlab_mac(anairiats_sum_25, arg1, atslab_2) ; do { /* branch: __ats_lab_231 */ __ats_lab_231_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_232_0 ; } __ats_lab_231_1: tmp1027 = ats_caselptrlab_mac(anairiats_sum_25, arg2, atslab_1) ; tmp1028 = ats_caselptrlab_mac(anairiats_sum_25, arg2, atslab_2) ; /* tmp1029 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcst (arg0, tmp1025, tmp1027) ; arg0 = arg0 ; arg1 = tmp1026 ; arg2 = tmp1028 ; goto __ats_lab_aux_142 ; // tail call break ; /* branch: __ats_lab_232 */ __ats_lab_232_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_232_1: tmp1024 = 1 ; break ; } while (0) ; break ; /* branch: __ats_lab_233 */ __ats_lab_233_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_233_1: do { /* branch: __ats_lab_234 */ __ats_lab_234_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_235_0 ; } __ats_lab_234_1: tmp1024 = 1 ; break ; /* branch: __ats_lab_235 */ __ats_lab_235_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_235_1: tmp1024 = 0 ; break ; } while (0) ; break ; } while (0) ; return (tmp1024) ; } /* end of [aux_142] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 58051(line=1958, offs=3) -- 58879(line=1980, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_labp2atcstlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1023) ; ATSlocal (ats_int_type, tmp1030) ; ATSlocal (ats_bool_type, tmp1031) ; // ATSlocal_void (tmp1032) ; // ATSlocal_void (tmp1033) ; // ATSlocal_void (tmp1034) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_labp2atcstlst: tmp1030 = aux_142 (arg0, arg1, arg2) ; tmp1031 = atspre_gt_int_int (tmp1030, 0) ; if (tmp1031) { /* tmp1032 = */ prerr_loc_interror_2 (arg0) ; /* tmp1033 = */ atspre_prerr_string (ATSstrcst(": trans3_env_hypo_add_labp2atcstlst")) ; /* tmp1034 = */ atspre_prerr_newline () ; /* tmp1023 = */ ATS_2d0_2e2_2e11_2src_2ats_error_2esats__abort () ; } else { /* empty */ } /* end of [if] */ return /* (tmp1023) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_labp2atcstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 59055(line=1988, offs=7) -- 59533(line=2000, offs=6) */ ATSstaticdec() ats_ptr_type aux_144 (ats_ptr_type env0, ats_ptr_type env1, ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ ATSlocal (ats_ptr_type, tmp1036) ; ATSlocal (ats_ptr_type, tmp1037) ; ATSlocal (ats_ptr_type, tmp1038) ; // ATSlocal_void (tmp1039) ; // ATSlocal_void (tmp1040) ; ATSlocal (ats_ptr_type, tmp1041) ; ATSlocal (ats_ptr_type, tmp1042) ; ATSlocal (ats_ptr_type, tmp1043) ; __ats_lab_aux_144: do { /* branch: __ats_lab_236 */ __ats_lab_236_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_237_0 ; } __ats_lab_236_1: tmp1037 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp1038 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; /* tmp1039 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp1040 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst (env0, tmp1037, env1) ; tmp1041 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta () ; tmp1042 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (tmp1041) ; tmp1043 = ATS_MALLOC(sizeof(anairiats_sum_8)) ; ats_selptrset_mac(anairiats_sum_8, tmp1043, atslab_0, tmp1042) ; ats_selptrset_mac(anairiats_sum_8, tmp1043, atslab_1, arg1) ; arg0 = tmp1038 ; arg1 = tmp1043 ; goto __ats_lab_aux_144 ; // tail call break ; /* branch: __ats_lab_237 */ __ats_lab_237_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_237_1: tmp1036 = ATS_2d0_2e2_2e11_2src_2ats_list_2esats__list_vt_reverse_list (arg1) ; break ; } while (0) ; return (tmp1036) ; } /* end of [aux_144] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_ptr_type closure_env_1 ; } aux_144_closure_type ; ats_ptr_type aux_144_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0, ats_ptr_type arg1) { return aux_144 (((aux_144_closure_type*)cloptr)->closure_env_0, ((aux_144_closure_type*)cloptr)->closure_env_1, arg0, arg1) ; } /* end of function */ ATSinline() ats_void_type aux_144_closure_init (aux_144_closure_type *p_clo, ats_ptr_type env0, ats_ptr_type env1) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_144_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; return ; } /* end of function */ ats_clo_ptr_type aux_144_closure_make (ats_ptr_type env0, ats_ptr_type env1) { aux_144_closure_type *p_clo = ATS_MALLOC(sizeof(aux_144_closure_type)) ; aux_144_closure_init (p_clo, env0, env1) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 59022(line=1987, offs=3) -- 59614(line=2003, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlstlst (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1035) ; ATSlocal (ats_ptr_type, tmp1044) ; ATSlocal (ats_ptr_type, tmp1045) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlstlst: tmp1045 = (ats_sum_ptr_type)0 ; tmp1044 = aux_144 (arg0, arg2, arg1, tmp1045) ; /* tmp1035 = */ trans3_env_hypo_add_disj_96 (tmp1044) ; return /* (tmp1035) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 59762(line=2010, offs=3) -- 59873(line=2014, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp1046) ; ATSlocal (ats_ptr_type, tmp1047) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec: tmp1047 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_metric_dec (arg0, arg1, arg2) ; /* tmp1046 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr (tmp1047) ; return /* (tmp1046) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_metric_dec] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 60055(line=2022, offs=7) -- 60601(line=2036, offs=6) */ ATSstaticdec() ats_void_type aux_147 (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2, ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp1049) ; ATSlocal (ats_ptr_type, tmp1050) ; ATSlocal (ats_ptr_type, tmp1051) ; // ATSlocal_void (tmp1052) ; // ATSlocal_void (tmp1053) ; ATSlocal (ats_ptr_type, tmp1054) ; // ATSlocal_void (tmp1055) ; // ATSlocal_void (tmp1056) ; __ats_lab_aux_147: do { /* branch: __ats_lab_238 */ __ats_lab_238_0: if (arg0 == (ats_sum_ptr_type)0) { goto __ats_lab_239_0 ; } __ats_lab_238_1: tmp1050 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_0) ; tmp1051 = ats_caselptrlab_mac(anairiats_sum_8, arg0, atslab_1) ; /* tmp1052 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_push_sta () ; /* tmp1053 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_hypo_add_p2atcstlst (env0, tmp1050, env2) ; tmp1054 = ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__c3str_pattern_match_exhaustiveness (env0, env1, tmp1050) ; /* tmp1055 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_cstr (tmp1054) ; /* tmp1056 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_pop_sta_and_add_none (env0) ; arg0 = tmp1051 ; goto __ats_lab_aux_147 ; // tail call break ; /* branch: __ats_lab_239 */ __ats_lab_239_0: // if (arg0 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_239_1: break ; } while (0) ; return /* (tmp1049) */ ; } /* end of [aux_147] */ typedef struct { ats_fun_ptr_type closure_fun ; ats_ptr_type closure_env_0 ; ats_int_type closure_env_1 ; ats_ptr_type closure_env_2 ; } aux_147_closure_type ; ats_void_type aux_147_clofun (ats_clo_ptr_type cloptr, ats_ptr_type arg0) { aux_147 (((aux_147_closure_type*)cloptr)->closure_env_0, ((aux_147_closure_type*)cloptr)->closure_env_1, ((aux_147_closure_type*)cloptr)->closure_env_2, arg0) ; return ; } /* end of function */ ATSinline() ats_void_type aux_147_closure_init (aux_147_closure_type *p_clo, ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { p_clo->closure_fun = (ats_fun_ptr_type)&aux_147_clofun ; p_clo->closure_env_0 = env0 ; p_clo->closure_env_1 = env1 ; p_clo->closure_env_2 = env2 ; return ; } /* end of function */ ats_clo_ptr_type aux_147_closure_make (ats_ptr_type env0, ats_int_type env1, ats_ptr_type env2) { aux_147_closure_type *p_clo = ATS_MALLOC(sizeof(aux_147_closure_type)) ; aux_147_closure_init (p_clo, env0, env1, env2) ; return (ats_clo_ptr_type)p_clo ; } /* end of function */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 60014(line=2021, offs=3) -- 60639(line=2039, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false (ats_ptr_type arg0, ats_int_type arg1, ats_ptr_type arg2, ats_ptr_type arg3) { /* local vardec */ // ATSlocal_void (tmp1048) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false: /* tmp1048 = */ aux_147 (arg0, arg1, arg3, arg2) ; return /* (tmp1048) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_add_p2atcstlstlst_false] */ /* // /home/hwxi/research/Anairiats/src/ats_trans3_env.dats: 60741(line=2044, offs=23) -- 62861(line=2111, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_initialize () { /* local vardec */ // ATSlocal_void (tmp1057) ; // ATSlocal_void (tmp1058) ; ATSlocal (ats_ptr_type, tmp1059) ; ATSlocal (ats_ptr_type, tmp1060) ; // ATSlocal_void (tmp1061) ; ATSlocal (ats_ptr_type, tmp1062) ; ATSlocal (ats_ptr_type, tmp1063) ; // ATSlocal_void (tmp1064) ; ATSlocal (ats_ptr_type, tmp1065) ; ATSlocal (ats_ptr_type, tmp1066) ; // ATSlocal_void (tmp1067) ; ATSlocal (ats_ptr_type, tmp1068) ; ATSlocal (ats_ptr_type, tmp1069) ; // ATSlocal_void (tmp1070) ; ATSlocal (ats_ptr_type, tmp1071) ; ATSlocal (ats_ptr_type, tmp1072) ; // ATSlocal_void (tmp1073) ; ATSlocal (ats_ptr_type, tmp1074) ; ATSlocal (ats_ptr_type, tmp1075) ; // ATSlocal_void (tmp1076) ; ATSlocal (ats_ptr_type, tmp1077) ; ATSlocal (ats_ptr_type, tmp1078) ; // ATSlocal_void (tmp1079) ; ATSlocal (ats_ptr_type, tmp1080) ; ATSlocal (ats_ptr_type, tmp1081) ; // ATSlocal_void (tmp1082) ; ATSlocal (ats_ptr_type, tmp1083) ; ATSlocal (ats_ptr_type, tmp1084) ; // ATSlocal_void (tmp1085) ; ATSlocal (ats_ptr_type, tmp1086) ; ATSlocal (ats_ptr_type, tmp1087) ; // ATSlocal_void (tmp1088) ; ATSlocal (ats_ptr_type, tmp1089) ; ATSlocal (ats_ptr_type, tmp1090) ; // ATSlocal_void (tmp1091) ; // ATSlocal_void (tmp1092) ; // ATSlocal_void (tmp1093) ; // ATSlocal_void (tmp1094) ; // ATSlocal_void (tmp1095) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_initialize: /* tmp1058 = */ ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__the_s2varbindmap_initialize () ; tmp1059 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_t0ype) ; tmp1060 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Bool_bool_t0ype) ; /* tmp1061 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1060, tmp1059) ; tmp1062 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_t0ype) ; tmp1063 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Char_char_t0ype) ; /* tmp1064 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1063, tmp1062) ; tmp1065 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_t0ype) ; tmp1066 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Int_int_t0ype) ; /* tmp1067 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1066, tmp1065) ; tmp1068 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_t0ype) ; tmp1069 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Uint_int_t0ype) ; /* tmp1070 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1069, tmp1068) ; tmp1071 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_t0ype) ; tmp1072 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Lint_int_t0ype) ; /* tmp1073 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1072, tmp1071) ; tmp1074 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_t0ype) ; tmp1075 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ulint_int_t0ype) ; /* tmp1076 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1075, tmp1074) ; tmp1077 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_t0ype) ; tmp1078 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Size_int_t0ype) ; /* tmp1079 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1078, tmp1077) ; tmp1080 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_t0ype) ; tmp1081 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ssize_int_t0ype) ; /* tmp1082 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1081, tmp1080) ; tmp1083 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_type) ; tmp1084 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Ptr_addr_type) ; /* tmp1085 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1084, tmp1083) ; tmp1086 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_t0ype) ; tmp1087 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__Strbuf_int_int_t0ype) ; /* tmp1088 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1087, tmp1086) ; tmp1089 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_type) ; tmp1090 = ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__s2cstref_get_cst (ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__String_int_type) ; /* tmp1091 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2cst_add_sup (tmp1090, tmp1089) ; /* tmp1092 = */ ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__clo_viewt0ype_viewt0ype_assume () ; /* tmp1093 = */ ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloptr_viewt0ype_viewtype_assume () ; /* tmp1094 = */ ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__cloref_t0ype_type_assume () ; /* tmp1095 = */ ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__crypt_viewt0ype_viewt0ype_assume () ; /* tmp1057 = */ ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__sizeof_viewt0ype_int_assume () ; return /* (tmp1057) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__trans3_env_initialize] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_debug_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_error_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_patcst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp3_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_solve_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_stadyncst2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_reference_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_map_lin_2edats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMlam_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMllam_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__LD2VSITEMset_2.tag = 2 ; // ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__ENVcon_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound.name = "ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound" ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.name = "ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found" ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound.name = "ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__NotFound" ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.tag = ats_exception_con_tag_new () ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found.name = "ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__Found" ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_trans3_env_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp28, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp31, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp32, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp33, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp34, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp35, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp239, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp240, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp241, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp316, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp317, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp318, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp509, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp510, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp511, sizeof(ats_ptr_type)) ; ATS_GC_MARKROOT(&statmp512, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp31 = (ats_sum_ptr_type)0 ; statmp28 = ref_make_elt_04159_ats_ptr_type (statmp31) ; statmp33 = (ats_sum_ptr_type)0 ; statmp32 = ref_make_elt_04159_ats_ptr_type (statmp33) ; statmp35 = ATS_2d0_2e2_2e11_2src_2ats_map_lin_2esats__map_make (&__ats_fun_12) ; statmp34 = ref_make_elt_04159_ats_ptr_type (statmp35) ; statmp239 = ref_make_elt_04159_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__s2Varset_nil) ; statmp241 = (ats_sum_ptr_type)0 ; statmp240 = ref_make_elt_04159_ats_ptr_type (statmp241) ; statmp316 = ref_make_elt_04159_ats_ptr_type (ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__d2varset_nil) ; statmp318 = (ats_sum_ptr_type)0 ; statmp317 = ref_make_elt_04159_ats_ptr_type (statmp318) ; statmp510 = (ats_sum_ptr_type)0 ; statmp509 = ref_make_elt_04159_ats_ptr_type (statmp510) ; statmp512 = (ats_sum_ptr_type)0 ; statmp511 = ref_make_elt_04159_ats_ptr_type (statmp512) ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_trans3_env_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_ccomp_env_sats.c0000664000175000017500000001543712223166160022121 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* prologues from statically loaded files */ #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" #include "ats_counter.cats" #include "ats_intinf.cats" #include "ats_counter.cats" /* external codes at top */ /* type definitions */ /* external typedefs */ /* assuming abstract types */ /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTcons_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_clo_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_fun_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_val_2) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTcons_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTnil_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTnil_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTmark_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTcons_2) ; /* exn constructor declarations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_filename_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_location_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_dynexp2_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_hiexp_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_2esats__staload () ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TYPDEFLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DATCSTLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXNCONLSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTYPELSTnil_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTVALLSTcons_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__EXTCODELSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__STAFILELSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__DYNFILELSTnil_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_clo_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_fun_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTcons_val_2.tag = 2 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__GLOCSTLSTnil_3.tag = 3 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTcons_0.tag = 0 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__PARTVALSTnil_1.tag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTnil_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTmark_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_ccomp_env_2esats__TAILCALLSTcons_2.tag = 2 ; return ; } /* staload function */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_ccomp_env_sats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_intinf.cats0000664000175000017500000001545512223166160021115 0ustar hwxihwxi/***********************************************************************/ /* */ /* Applied Type System */ /* */ /* Hongwei Xi */ /* */ /***********************************************************************/ /* ** ATS/Anairiats - Unleashing the Potential of Types! ** Copyright (C) 2002-2008 Hongwei Xi, Boston University ** All rights reserved ** ** ATS is free software; you can redistribute it and/or modify it under ** the terms of the GNU GENERAL PUBLIC LICENSE (GPL) as published by the ** Free Software Foundation; either version 3, or (at your option) any ** later version. ** ** ATS is distributed in the hope that it will be useful, but WITHOUT ANY ** WARRANTY; without even the implied warranty of MERCHANTABILITY or ** FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ** for more details. ** ** You should have received a copy of the GNU General Public License ** along with ATS; see the file COPYING. If not, please write to the ** Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ** 02110-1301, USA. */ /* ****** ****** */ // // Author: Hongwei Xi (hwxi AT cs DOT bu DOT edu) // July 2007 // /* ****** ****** */ #ifndef ATS_SRC_INTINF_CATS #define ATS_SRC_INTINF_CATS /* ****** ****** */ #include "config.h" /* automatically generated by [configure] */ /* ****** ****** */ #include "ats_memory.h" #include "ats_types.h" /* ****** ****** */ // #undef HAVE_GMP_H // testing #ifdef HAVE_GMP_H #include "libc/CATS/gmp.cats" #else #include "ats_gmp.cats" #endif /* ****** ****** */ // // HX: [mpz_ptr] is defined in [gmp.h] // /* ****** ****** */ ATSinline() ats_int_type atsopt_get_int ( ats_mpz_ptr_type x ) { return mpz_get_si ((mpz_ptr)x) ; } // end of [atsopt_get_int] /* ****** ****** */ ATSinline() ats_bool_type atsopt_lt_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, y) < 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_lt_intinf_int] ATSinline() ats_bool_type atsopt_lt_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) < 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_lt_intinf_intinf] ATSinline() ats_bool_type atsopt_lte_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, y) <= 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_lte_intinf_int] ATSinline() ats_bool_type atsopt_lte_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) <= 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_lte_intinf_intinf] /* ****** ****** */ ATSinline() ats_bool_type atsopt_gt_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, y) > 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_gt_intinf_int] ATSinline() ats_bool_type atsopt_gt_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) > 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_gt_intinf_intinf] ATSinline() ats_bool_type atsopt_gte_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, y) >= 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_gte_intinf_int] ATSinline() ats_bool_type atsopt_gte_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) >= 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_gte_intinf_intinf] /* ****** ****** */ ATSinline() ats_bool_type atsopt_eq_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, (int)y) == 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_eq_intinf_int] ATSinline() ats_bool_type atsopt_eq_int_intinf ( ats_int_type x, ats_mpz_ptr_type y ) { if (mpz_cmp_si((mpz_ptr)y, (int)x) == 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_eq_int_intinf] ATSinline() ats_bool_type atsopt_eq_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) == 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_eq_intinf_intinf] ATSinline() ats_bool_type atsopt_neq_intinf_int ( ats_mpz_ptr_type x, ats_int_type y ) { if (mpz_cmp_si((mpz_ptr)x, (int)y) != 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_neq_intinf_int] ATSinline() ats_bool_type atsopt_neq_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { if (mpz_cmp((mpz_ptr)x, (mpz_ptr)y) != 0) return ats_true_bool ; return ats_false_bool ; } // end of [atsopt_neq_intinf_intinf] /* ****** ****** */ ATSinline() ats_int_type atsopt_compare_intinf_intinf (ats_mpz_ptr_type x, ats_mpz_ptr_type y) { return mpz_cmp((mpz_ptr)x, (mpz_ptr)y) ; } // end of [atsopt_compare_intinf_intinf] /* ****** ****** */ ATSinline() ats_mpz_ptr_type atsopt_neg_intinf (ats_mpz_ptr_type x) { mpz_ptr ans = ATS_MALLOC (sizeof(ats_mpz_viewt0ype)); mpz_init((mpz_ptr)ans); mpz_neg (ans, (mpz_ptr)x) ; return ans ; } // end of [atsopt_neg_intinf] ATSinline() ats_mpz_ptr_type atsopt_add_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_ptr ans = ATS_MALLOC (sizeof(ats_mpz_viewt0ype)) ; mpz_init((mpz_ptr)ans) ; mpz_add ((mpz_ptr)ans, (mpz_ptr)x, (mpz_ptr)y) ; return ans ; } // end of [atsopt_add_intinf_intinf] ATSinline() ats_mpz_ptr_type atsopt_sub_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_ptr ans = ATS_MALLOC (sizeof(ats_mpz_viewt0ype)) ; mpz_init((mpz_ptr)ans) ; mpz_sub ((mpz_ptr)ans, (mpz_ptr)x, (mpz_ptr)y) ; return ans ; } // end of [atsopt_sub_intinf_intinf] ATSinline() ats_mpz_ptr_type atsopt_mul_intinf_intinf ( ats_mpz_ptr_type x, ats_mpz_ptr_type y ) { mpz_ptr ans = ATS_MALLOC (sizeof(ats_mpz_viewt0ype)) ; mpz_init((mpz_ptr)ans) ; mpz_mul ((mpz_ptr)ans, (mpz_ptr)x, (mpz_ptr)y) ; return ans; } // end of [atsopt_mul_intinf_intinf] /* ****** ****** */ // // HX: declared in [prelude/CATS/integer.cats] // extern ats_ptr_type atspre_tostrptr_llint (ats_llint_type x) ; ATSinline() ats_ptr_type atsopt_tostring_intinf (ats_mpz_ptr_type x) { #ifdef HAVE_GMP_H return mpz_get_str((char*)0, 10/*base*/, (mpz_ptr)x) ; #else // HAVE_GMP_H /* // HX: the following is in [ats_gmp.cats]: // typedef ats_llint_type mpz ; typedef mpz *mpz_ptr ; */ return atspre_tostrptr_llint (*(mpz_ptr)x) ; #endif // HAVE_GMP_H } // end of [atsopt_tostring_intinf] /* ****** ****** */ #endif // ATS_SRC_INTINF_CATS /* end of [ats_intinf.cats] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_syntax_taggen_dats.c0000664000175000017500000007356712223166160023014 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_d0ec_loc ; ats_ptr_type atslab_d0ec_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_5 ; typedef struct { ats_ptr_type atslab_i0de_loc ; ats_ptr_type atslab_i0de_sym ; } anairiats_rec_6 ; typedef struct { ats_ptr_type atslab_s0expdef_loc ; ats_ptr_type atslab_s0expdef_sym ; ats_ptr_type atslab_s0expdef_loc_id ; ats_ptr_type atslab_s0expdef_arg ; ats_ptr_type atslab_s0expdef_res ; ats_ptr_type atslab_s0expdef_def ; } anairiats_rec_7 ; typedef struct { ats_ptr_type atslab_s0aspdec_fil ; ats_ptr_type atslab_s0aspdec_loc ; ats_ptr_type atslab_s0aspdec_qid ; ats_ptr_type atslab_s0aspdec_arg ; ats_ptr_type atslab_s0aspdec_res ; ats_ptr_type atslab_s0aspdec_def ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_sqi0de_loc ; ats_ptr_type atslab_sqi0de_qua ; ats_ptr_type atslab_sqi0de_sym ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_d0atdec_fil ; ats_ptr_type atslab_d0atdec_loc ; ats_ptr_type atslab_d0atdec_headloc ; ats_ptr_type atslab_d0atdec_sym ; ats_ptr_type atslab_d0atdec_arg ; ats_ptr_type atslab_d0atdec_con ; } anairiats_rec_10 ; typedef struct { ats_ptr_type atslab_e0xndec_fil ; ats_ptr_type atslab_e0xndec_loc ; ats_ptr_type atslab_e0xndec_sym ; ats_ptr_type atslab_e0xndec_qua ; ats_ptr_type atslab_e0xndec_arg ; } anairiats_rec_11 ; typedef struct { ats_ptr_type atslab_d0cstdec_fil ; ats_ptr_type atslab_d0cstdec_loc ; ats_ptr_type atslab_d0cstdec_sym ; ats_ptr_type atslab_d0cstdec_arg ; ats_ptr_type atslab_d0cstdec_eff ; ats_ptr_type atslab_d0cstdec_res ; ats_ptr_type atslab_d0cstdec_extdef ; } anairiats_rec_12 ; typedef struct { ats_ptr_type atslab_f0undec_loc ; ats_ptr_type atslab_f0undec_sym ; ats_ptr_type atslab_f0undec_sym_loc ; ats_ptr_type atslab_f0undec_arg ; ats_ptr_type atslab_f0undec_eff ; ats_ptr_type atslab_f0undec_res ; ats_ptr_type atslab_f0undec_def ; ats_ptr_type atslab_f0undec_ann ; } anairiats_rec_13 ; typedef struct { ats_ptr_type atslab_i0mpdec_loc ; ats_ptr_type atslab_i0mpdec_qid ; ats_ptr_type atslab_i0mpdec_arg ; ats_ptr_type atslab_i0mpdec_res ; ats_ptr_type atslab_i0mpdec_def ; } anairiats_rec_14 ; typedef struct { ats_ptr_type atslab_impqi0de_loc ; ats_ptr_type atslab_impqi0de_qua ; ats_ptr_type atslab_impqi0de_sym ; ats_ptr_type atslab_impqi0de_arg ; } anairiats_rec_15 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csexpdefs_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Csaspdec_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdcstdecs_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cdatdecs_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cexndecs_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Coverload_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cfundecs_25) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__D0Cimpdec_28) ; /* external dynamic constant declarations */ ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ptr_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_lint) (ats_ptr_type, ats_lint_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_int_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line) (ats_ptr_type) ; ATSextern_fun(ats_lint_type, ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff) (ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__fprint_symbol) (ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc) (ats_ptr_type, ats_ptr_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_int_type aux_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxlst_3 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxi0de_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxsexpdef_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxsexpdeflst_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxsaspdec_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxdatdec_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxdatdeclst_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxexndec_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxexndeclst_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxdcstdec_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxdcstdeclst_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxfundec_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auxfundeclst_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; static ats_int_type auximpdec_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 2106(line=69, offs=3) -- 2288(line=78, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__fprint_symbol (ats_ptr_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__fprint_symbol: tmp1 = ats_selsin_mac(ats_castfn_mac(ats_ptr_type, ats_castfn_mac(ats_ptr_type, arg0)), atslab_2) ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (tmp1, arg1) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__fprint_symbol] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 2464(line=89, offs=1) -- 2973(line=110, offs=2) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (ats_ptr_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp2) ; // ATSlocal_void (tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; // ATSlocal_void (tmp8) ; // ATSlocal_void (tmp9) ; ATSlocal (ats_int_type, tmp10) ; // ATSlocal_void (tmp11) ; // ATSlocal_void (tmp12) ; ATSlocal (ats_lint_type, tmp13) ; // ATSlocal_void (tmp14) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc: /* tmp3 = */ atspre_fprint_string (arg0, ATSstrcst("{\n")) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("\"name\" : ")) ; /* tmp5 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp6 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__fprint_symbol (arg0, arg1) ; /* tmp7 = */ atspre_fprint_string (arg0, ATSstrcst("\"")) ; /* tmp8 = */ atspre_fprint_string (arg0, ATSstrcst(", \"nline\" : ")) ; tmp10 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_line (arg2) ; /* tmp9 = */ atspre_fprint_int (arg0, tmp10) ; /* tmp11 = */ atspre_fprint_string (arg0, ATSstrcst(", \"nchar\" : ")) ; tmp13 = ATS_2d0_2e2_2e11_2src_2ats_location_2esats__location_begpos_toff (arg2) ; /* tmp12 = */ atspre_fprint_lint (arg0, tmp13) ; /* tmp14 = */ atspre_fprint_string (arg0, ATSstrcst("\n")) ; /* tmp2 = */ atspre_fprint_string (arg0, ATSstrcst("}\n")) ; return /* (tmp2) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 3036(line=116, offs=5) -- 4126(line=171, offs=4) */ ATSstaticdec() ats_int_type aux_2 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp15) ; ATSlocal (ats_ptr_type, tmp16) ; ATSlocal (ats_ptr_type, tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; ATSlocal (ats_int_type, tmp19) ; ATSlocal (ats_ptr_type, tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_ptr_type, tmp22) ; ATSlocal (ats_ptr_type, tmp23) ; ATSlocal (ats_int_type, tmp24) ; ATSlocal (ats_int_type, tmp25) ; ATSlocal (ats_ptr_type, tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; ATSlocal (ats_int_type, tmp28) ; ATSlocal (ats_ptr_type, tmp29) ; ATSlocal (ats_ptr_type, tmp30) ; ATSlocal (ats_int_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; ATSlocal (ats_ptr_type, tmp33) ; ATSlocal (ats_ptr_type, tmp34) ; ATSlocal (ats_int_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; __ats_lab_aux_2: tmp16 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_d0ec_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp16)->tag != 12) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp17 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_1) ; tmp18 = ats_caselptrlab_mac(anairiats_sum_1, tmp16, atslab_2) ; tmp19 = auxsexpdef_5 (arg0, tmp17, arg2) ; tmp15 = auxsexpdeflst_6 (arg0, tmp18, tmp19) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp16)->tag != 13) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp20 = ats_caselptrlab_mac(anairiats_sum_2, tmp16, atslab_0) ; tmp15 = auxsaspdec_7 (arg0, tmp20, arg2) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp16)->tag != 15) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_1) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_2) ; tmp23 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_3) ; tmp24 = auxdatdec_8 (arg0, tmp21, arg2) ; tmp25 = auxdatdeclst_9 (arg0, tmp22, tmp24) ; tmp15 = auxsexpdeflst_6 (arg0, tmp23, tmp25) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp16)->tag != 16) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp26 = ats_caselptrlab_mac(anairiats_sum_4, tmp16, atslab_0) ; tmp27 = ats_caselptrlab_mac(anairiats_sum_4, tmp16, atslab_1) ; tmp28 = auxexndec_10 (arg0, tmp26, arg2) ; tmp15 = auxexndeclst_11 (arg0, tmp27, tmp28) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp16)->tag != 14) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp29 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_2) ; tmp30 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_3) ; tmp31 = auxdcstdec_12 (arg0, tmp29, arg2) ; tmp15 = auxdcstdeclst_13 (arg0, tmp30, tmp31) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp16)->tag != 18) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp32 = ats_caselptrlab_mac(anairiats_sum_4, tmp16, atslab_0) ; tmp15 = auxi0de_4 (arg0, tmp32, arg2) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp16)->tag != 25) { goto __ats_lab_7_0 ; } __ats_lab_6_1: tmp33 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_2) ; tmp34 = ats_caselptrlab_mac(anairiats_sum_3, tmp16, atslab_3) ; tmp35 = auxfundec_14 (arg0, tmp33, arg2) ; tmp15 = auxfundeclst_15 (arg0, tmp34, tmp35) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp16)->tag != 28) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp36 = ats_caselptrlab_mac(anairiats_sum_4, tmp16, atslab_1) ; tmp15 = auximpdec_16 (arg0, tmp36, arg2) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: __ats_lab_8_1: tmp15 = arg2 ; break ; } while (0) ; return (tmp15) ; } /* end of [aux_2] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 4151(line=173, offs=5) -- 4385(line=186, offs=4) */ ATSstaticdec() ats_int_type auxlst_3 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp37) ; ATSlocal (ats_ptr_type, tmp38) ; ATSlocal (ats_ptr_type, tmp39) ; ATSlocal (ats_int_type, tmp40) ; __ats_lab_auxlst_3: do { /* branch: __ats_lab_9 */ __ats_lab_9_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_10_0 ; } __ats_lab_9_1: tmp38 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp39 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp40 = aux_2 (arg0, tmp38, arg2) ; arg0 = arg0 ; arg1 = tmp39 ; arg2 = tmp40 ; goto __ats_lab_auxlst_3 ; // tail call break ; /* branch: __ats_lab_10 */ __ats_lab_10_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_10_1: tmp37 = arg2 ; break ; } while (0) ; return (tmp37) ; } /* end of [auxlst_3] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 4434(line=190, offs=5) -- 4631(line=202, offs=4) */ ATSstaticdec() ats_int_type auxi0de_4 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp41) ; ATSlocal (ats_ptr_type, tmp42) ; // ATSlocal_void (tmp43) ; ATSlocal (ats_bool_type, tmp44) ; // ATSlocal_void (tmp45) ; ATSlocal (ats_ptr_type, tmp46) ; __ats_lab_auxi0de_4: tmp42 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_i0de_sym) ; tmp44 = atspre_gt_int_int (arg2, 0) ; if (tmp44) { /* tmp43 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp46 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_6, arg1), atslab_i0de_loc) ; /* tmp45 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp42, tmp46) ; tmp41 = atspre_add_int_int (arg2, 1) ; return (tmp41) ; } /* end of [auxi0de_4] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 4678(line=206, offs=5) -- 4889(line=217, offs=4) */ ATSstaticdec() ats_int_type auxsexpdef_5 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; // ATSlocal_void (tmp49) ; ATSlocal (ats_bool_type, tmp50) ; // ATSlocal_void (tmp51) ; ATSlocal (ats_ptr_type, tmp52) ; __ats_lab_auxsexpdef_5: tmp48 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s0expdef_sym) ; tmp50 = atspre_gt_int_int (arg2, 0) ; if (tmp50) { /* tmp49 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp52 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_7, arg1), atslab_s0expdef_loc) ; /* tmp51 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp48, tmp52) ; tmp47 = atspre_add_int_int (arg2, 1) ; return (tmp47) ; } /* end of [auxsexpdef_5] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 4918(line=219, offs=5) -- 5171(line=232, offs=4) */ ATSstaticdec() ats_int_type auxsexpdeflst_6 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp53) ; ATSlocal (ats_ptr_type, tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; ATSlocal (ats_int_type, tmp56) ; __ats_lab_auxsexpdeflst_6: do { /* branch: __ats_lab_11 */ __ats_lab_11_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp54 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp55 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp56 = auxsexpdef_5 (arg0, tmp54, arg2) ; arg0 = arg0 ; arg1 = tmp55 ; arg2 = tmp56 ; goto __ats_lab_auxsexpdeflst_6 ; // tail call break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_12_1: tmp53 = arg2 ; break ; } while (0) ; return (tmp53) ; } /* end of [auxsexpdeflst_6] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 5224(line=236, offs=5) -- 5457(line=248, offs=4) */ ATSstaticdec() ats_int_type auxsaspdec_7 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; ATSlocal (ats_bool_type, tmp61) ; // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; __ats_lab_auxsaspdec_7: tmp58 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s0aspdec_qid) ; tmp59 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp58), atslab_sqi0de_sym) ; tmp61 = atspre_gt_int_int (arg2, 0) ; if (tmp61) { /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp63 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, tmp58), atslab_sqi0de_loc) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp59, tmp63) ; tmp57 = atspre_add_int_int (arg2, 1) ; return (tmp57) ; } /* end of [auxsaspdec_7] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 5507(line=252, offs=5) -- 5714(line=263, offs=4) */ ATSstaticdec() ats_int_type auxdatdec_8 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp64) ; ATSlocal (ats_ptr_type, tmp65) ; // ATSlocal_void (tmp66) ; ATSlocal (ats_bool_type, tmp67) ; // ATSlocal_void (tmp68) ; ATSlocal (ats_ptr_type, tmp69) ; __ats_lab_auxdatdec_8: tmp65 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_d0atdec_sym) ; tmp67 = atspre_gt_int_int (arg2, 0) ; if (tmp67) { /* tmp66 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp69 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_10, arg1), atslab_d0atdec_loc) ; /* tmp68 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp65, tmp69) ; tmp64 = atspre_add_int_int (arg2, 1) ; return (tmp64) ; } /* end of [auxdatdec_8] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 5742(line=265, offs=5) -- 5991(line=278, offs=4) */ ATSstaticdec() ats_int_type auxdatdeclst_9 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; ATSlocal (ats_int_type, tmp73) ; __ats_lab_auxdatdeclst_9: do { /* branch: __ats_lab_13 */ __ats_lab_13_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_14_0 ; } __ats_lab_13_1: tmp71 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp72 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp73 = auxdatdec_8 (arg0, tmp71, arg2) ; arg0 = arg0 ; arg1 = tmp72 ; arg2 = tmp73 ; goto __ats_lab_auxdatdeclst_9 ; // tail call break ; /* branch: __ats_lab_14 */ __ats_lab_14_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_14_1: tmp70 = arg2 ; break ; } while (0) ; return (tmp70) ; } /* end of [auxdatdeclst_9] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 6043(line=282, offs=5) -- 6248(line=294, offs=4) */ ATSstaticdec() ats_int_type auxexndec_10 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp74) ; ATSlocal (ats_ptr_type, tmp75) ; // ATSlocal_void (tmp76) ; ATSlocal (ats_bool_type, tmp77) ; // ATSlocal_void (tmp78) ; ATSlocal (ats_ptr_type, tmp79) ; __ats_lab_auxexndec_10: tmp75 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_e0xndec_sym) ; tmp77 = atspre_gt_int_int (arg2, 0) ; if (tmp77) { /* tmp76 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp79 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_e0xndec_loc) ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp75, tmp79) ; tmp74 = atspre_add_int_int (arg2, 1) ; return (tmp74) ; } /* end of [auxexndec_10] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 6276(line=296, offs=5) -- 6519(line=309, offs=4) */ ATSstaticdec() ats_int_type auxexndeclst_11 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; ATSlocal (ats_ptr_type, tmp82) ; ATSlocal (ats_int_type, tmp83) ; __ats_lab_auxexndeclst_11: do { /* branch: __ats_lab_15 */ __ats_lab_15_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_16_0 ; } __ats_lab_15_1: tmp81 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp82 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp83 = auxexndec_10 (arg0, tmp81, arg2) ; arg0 = arg0 ; arg1 = tmp82 ; arg2 = tmp83 ; goto __ats_lab_auxexndeclst_11 ; // tail call break ; /* branch: __ats_lab_16 */ __ats_lab_16_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_16_1: tmp80 = arg2 ; break ; } while (0) ; return (tmp80) ; } /* end of [auxexndeclst_11] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 6571(line=313, offs=5) -- 6782(line=324, offs=4) */ ATSstaticdec() ats_int_type auxdcstdec_12 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp84) ; ATSlocal (ats_ptr_type, tmp85) ; // ATSlocal_void (tmp86) ; ATSlocal (ats_bool_type, tmp87) ; // ATSlocal_void (tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; __ats_lab_auxdcstdec_12: tmp85 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_d0cstdec_sym) ; tmp87 = atspre_gt_int_int (arg2, 0) ; if (tmp87) { /* tmp86 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp89 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_12, arg1), atslab_d0cstdec_loc) ; /* tmp88 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp85, tmp89) ; tmp84 = atspre_add_int_int (arg2, 1) ; return (tmp84) ; } /* end of [auxdcstdec_12] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 6811(line=326, offs=5) -- 7064(line=339, offs=4) */ ATSstaticdec() ats_int_type auxdcstdeclst_13 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp90) ; ATSlocal (ats_ptr_type, tmp91) ; ATSlocal (ats_ptr_type, tmp92) ; ATSlocal (ats_int_type, tmp93) ; __ats_lab_auxdcstdeclst_13: do { /* branch: __ats_lab_17 */ __ats_lab_17_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_18_0 ; } __ats_lab_17_1: tmp91 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp92 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp93 = auxdcstdec_12 (arg0, tmp91, arg2) ; arg0 = arg0 ; arg1 = tmp92 ; arg2 = tmp93 ; goto __ats_lab_auxdcstdeclst_13 ; // tail call break ; /* branch: __ats_lab_18 */ __ats_lab_18_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_18_1: tmp90 = arg2 ; break ; } while (0) ; return (tmp90) ; } /* end of [auxdcstdeclst_13] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 7117(line=343, offs=5) -- 7324(line=354, offs=4) */ ATSstaticdec() ats_int_type auxfundec_14 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp94) ; ATSlocal (ats_ptr_type, tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_bool_type, tmp97) ; // ATSlocal_void (tmp98) ; ATSlocal (ats_ptr_type, tmp99) ; __ats_lab_auxfundec_14: tmp95 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_f0undec_sym) ; tmp97 = atspre_gt_int_int (arg2, 0) ; if (tmp97) { /* tmp96 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp99 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_13, arg1), atslab_f0undec_loc) ; /* tmp98 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp95, tmp99) ; tmp94 = atspre_add_int_int (arg2, 1) ; return (tmp94) ; } /* end of [auxfundec_14] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 7352(line=356, offs=5) -- 7601(line=369, offs=4) */ ATSstaticdec() ats_int_type auxfundeclst_15 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp100) ; ATSlocal (ats_ptr_type, tmp101) ; ATSlocal (ats_ptr_type, tmp102) ; ATSlocal (ats_int_type, tmp103) ; __ats_lab_auxfundeclst_15: do { /* branch: __ats_lab_19 */ __ats_lab_19_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_20_0 ; } __ats_lab_19_1: tmp101 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_0) ; tmp102 = ats_caselptrlab_mac(anairiats_sum_5, arg1, atslab_1) ; tmp103 = auxfundec_14 (arg0, tmp101, arg2) ; arg0 = arg0 ; arg1 = tmp102 ; arg2 = tmp103 ; goto __ats_lab_auxfundeclst_15 ; // tail call break ; /* branch: __ats_lab_20 */ __ats_lab_20_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_20_1: tmp100 = arg2 ; break ; } while (0) ; return (tmp100) ; } /* end of [auxfundeclst_15] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 7632(line=371, offs=5) -- 7869(line=383, offs=4) */ ATSstaticdec() ats_int_type auximpdec_16 (ats_ptr_type arg0, ats_ptr_type arg1, ats_int_type arg2) { /* local vardec */ ATSlocal (ats_int_type, tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; ATSlocal (ats_bool_type, tmp108) ; // ATSlocal_void (tmp109) ; ATSlocal (ats_ptr_type, tmp110) ; __ats_lab_auximpdec_16: tmp105 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_i0mpdec_qid) ; tmp106 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_15, tmp105), atslab_impqi0de_sym) ; tmp108 = atspre_gt_int_int (arg2, 0) ; if (tmp108) { /* tmp107 = */ atspre_fprint_string (arg0, ATSstrcst(",\n")) ; } else { /* empty */ } /* end of [if] */ tmp110 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_14, arg1), atslab_i0mpdec_loc) ; /* tmp109 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__taggen_symloc (arg0, tmp106, tmp110) ; tmp104 = atspre_add_int_int (arg2, 1) ; return (tmp104) ; } /* end of [auximpdec_16] */ /* // /home/hwxi/research/Anairiats/src/ats_syntax_taggen.dats: 7941(line=389, offs=1) -- 8360(line=408, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen (ats_ref_type arg0, ats_ptr_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp111) ; // ATSlocal_void (tmp112) ; // ATSlocal_void (tmp113) ; // ATSlocal_void (tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; ATSlocal (ats_int_type, tmp117) ; // ATSlocal_void (tmp118) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen: /* tmp112 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("{\n")) ; /* tmp113 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("\"tagfile\" : \"")) ; /* tmp114 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), arg1) ; /* tmp115 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("\",\n")) ; /* tmp116 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("\"tagentarr\" : [\n")) ; tmp117 = auxlst_3 (ats_castfn_mac(ats_ptr_type, arg0), arg2, 0) ; /* tmp118 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("]\n")) ; /* tmp111 = */ atspre_fprint_string (ats_castfn_mac(ats_ptr_type, arg0), ATSstrcst("}\n")) ; return /* (tmp111) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_taggen] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_syntax_taggen_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_syntax_taggen_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_staexp1_print_dats.c0000664000175000017500000017274412223166160022737 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ typedef struct { ats_ptr_type atslab_e1xp_loc ; ats_ptr_type atslab_e1xp_node ; } anairiats_rec_0 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_1 ; typedef struct { int tag ; ats_char_type atslab_0 ; } anairiats_sum_2 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; } anairiats_sum_3 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; } anairiats_sum_4 ; typedef struct { ats_ptr_type atslab_s1rt_loc ; ats_ptr_type atslab_s1rt_node ; } anairiats_rec_5 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_6 ; typedef struct { ats_ptr_type atslab_0 ; } anairiats_sum_7 ; typedef struct { ats_ptr_type atslab_s1arg_loc ; ats_ptr_type atslab_s1arg_sym ; ats_ptr_type atslab_s1arg_srt ; } anairiats_rec_8 ; typedef struct { ats_ptr_type atslab_s1qua_loc ; ats_ptr_type atslab_s1qua_node ; } anairiats_rec_9 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_10 ; typedef struct { ats_ptr_type atslab_s1exp_loc ; ats_ptr_type atslab_s1exp_node ; } anairiats_rec_11 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_12 ; typedef struct { int tag ; ats_ptr_type atslab_0 ; ats_int_type atslab_1 ; ats_int_type atslab_2 ; ats_ptr_type atslab_3 ; } anairiats_sum_13 ; typedef struct { int tag ; ats_int_type atslab_0 ; ats_ptr_type atslab_1 ; } anairiats_sum_14 ; typedef struct { ats_ptr_type atslab_0 ; ats_ptr_type atslab_1 ; ats_ptr_type atslab_2 ; } anairiats_sum_15 ; typedef struct { ats_ptr_type atslab_s1rtext_loc ; ats_ptr_type atslab_s1rtext_node ; } anairiats_rec_16 ; /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_cons_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__list_nil_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__None_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2prelude_2basics_sta_2esats__Some_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPchar_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPfloat_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPide_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPint_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPlist_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPstring_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPundef_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPcstsp_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__E1XPnone_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTapp_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTlist_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTqid_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1RTtup_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qprop_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Qvars_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsrt_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1TEsub_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__TMPS1EXPLSTLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTnil_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__LABS1EXPLSTcons_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eann_0) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eany_1) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eapp_2) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Echar_3) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eexi_4) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eextype_5) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eimp_6) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eint_7) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Einvar_8) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elam_9) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Elist_10) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eqid_11) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eread_12) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etop_13) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etrans_14) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyarr_15) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_16) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etyrec_ext_17) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup_18) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Etytup2_19) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Euni_20) ; ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__S1Eunion_21) ; /* external dynamic constant declarations */ ATSextern_fun(ats_ptr_type, atspre_stdout_get) () ; ATSextern_fun(ats_void_type, atspre_stdout_view_set) () ; ATSextern_fun(ats_ptr_type, atspre_stderr_get) () ; ATSextern_fun(ats_void_type, atspre_stderr_view_set) () ; ATSextern_fun(ats_void_type, atspre_fprint_char) (ats_ref_type, ats_char_type) ; ATSextern_fun(ats_int_type, atspre_add_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_gt_int_int) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_int) (ats_ref_type, ats_int_type) ; ATSextern_fun(ats_void_type, atspre_fprint_string) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0delst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst) (ats_ref_type, ats_ptr_type, ats_ptr_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explstlst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst) (ats_ref_type, ats_ptr_type) ; ATSextern_fun(ats_void_type, ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext) (ats_ref_type, ats_ptr_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK extern ats_void_type ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ /* sum constructor declarations */ /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ /* internal function declarations */ static ats_void_type fprint_s1arg_13 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type fprint_s1arglst_14 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type fprint_s1qua_15 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_17 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type fprint_s1qualst_16 (ats_ref_type arg0, ats_ptr_type arg1) ; static ats_void_type aux_27 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; static ats_void_type aux_29 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) ; /* partial value template declarations */ /* static temporary variable declarations */ /* external value variable declarations */ /* function implementations */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 2001(line=65, offs=13) -- 3458(line=110, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp0) ; ATSlocal (ats_ptr_type, tmp1) ; ATSlocal (ats_ptr_type, tmp2) ; ATSlocal (ats_ptr_type, tmp3) ; // ATSlocal_void (tmp4) ; // ATSlocal_void (tmp5) ; // ATSlocal_void (tmp6) ; // ATSlocal_void (tmp7) ; ATSlocal (ats_char_type, tmp8) ; // ATSlocal_void (tmp9) ; // ATSlocal_void (tmp10) ; ATSlocal (ats_ptr_type, tmp11) ; // ATSlocal_void (tmp12) ; // ATSlocal_void (tmp13) ; ATSlocal (ats_ptr_type, tmp14) ; ATSlocal (ats_ptr_type, tmp15) ; // ATSlocal_void (tmp16) ; // ATSlocal_void (tmp17) ; ATSlocal (ats_ptr_type, tmp18) ; // ATSlocal_void (tmp19) ; // ATSlocal_void (tmp20) ; ATSlocal (ats_ptr_type, tmp21) ; ATSlocal (ats_int_type, tmp22) ; // ATSlocal_void (tmp23) ; // ATSlocal_void (tmp24) ; // ATSlocal_void (tmp25) ; // ATSlocal_void (tmp26) ; ATSlocal (ats_ptr_type, tmp27) ; // ATSlocal_void (tmp28) ; // ATSlocal_void (tmp29) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp: tmp1 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_0, arg1), atslab_e1xp_node) ; do { /* branch: __ats_lab_0 */ __ats_lab_0_0: if (((ats_sum_ptr_type)tmp1)->tag != 0) { goto __ats_lab_1_0 ; } __ats_lab_0_1: tmp2 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_0) ; tmp3 = ats_caselptrlab_mac(anairiats_sum_1, tmp1, atslab_2) ; /* tmp4 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPapp(")) ; /* tmp5 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (arg0, tmp2) ; /* tmp6 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp7 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst (arg0, tmp3) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_1 */ __ats_lab_1_0: if (((ats_sum_ptr_type)tmp1)->tag != 1) { goto __ats_lab_2_0 ; } __ats_lab_1_1: tmp8 = ats_caselptrlab_mac(anairiats_sum_2, tmp1, atslab_0) ; /* tmp9 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPchar(")) ; /* tmp10 = */ atspre_fprint_char (arg0, tmp8) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_2 */ __ats_lab_2_0: if (((ats_sum_ptr_type)tmp1)->tag != 2) { goto __ats_lab_3_0 ; } __ats_lab_2_1: tmp11 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; /* tmp12 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPfloat(")) ; /* tmp13 = */ atspre_fprint_string (arg0, tmp11) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_3 */ __ats_lab_3_0: if (((ats_sum_ptr_type)tmp1)->tag != 3) { goto __ats_lab_4_0 ; } __ats_lab_3_1: tmp14 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; /* tmp0 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp14) ; break ; /* branch: __ats_lab_4 */ __ats_lab_4_0: if (((ats_sum_ptr_type)tmp1)->tag != 4) { goto __ats_lab_5_0 ; } __ats_lab_4_1: tmp15 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; /* tmp16 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPint(")) ; /* tmp17 = */ atspre_fprint_string (arg0, tmp15) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_5 */ __ats_lab_5_0: if (((ats_sum_ptr_type)tmp1)->tag != 5) { goto __ats_lab_6_0 ; } __ats_lab_5_1: tmp18 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; /* tmp19 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPlist(")) ; /* tmp20 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst (arg0, tmp18) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_6 */ __ats_lab_6_0: if (((ats_sum_ptr_type)tmp1)->tag != 9) { goto __ats_lab_7_0 ; } __ats_lab_6_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPnone()")) ; break ; /* branch: __ats_lab_7 */ __ats_lab_7_0: if (((ats_sum_ptr_type)tmp1)->tag != 6) { goto __ats_lab_8_0 ; } __ats_lab_7_1: tmp21 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_0) ; tmp22 = ats_caselptrlab_mac(anairiats_sum_4, tmp1, atslab_1) ; /* tmp23 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPstring(")) ; /* tmp24 = */ atspre_fprint_string (arg0, tmp21) ; /* tmp25 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp26 = */ atspre_fprint_int (arg0, tmp22) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_8 */ __ats_lab_8_0: if (((ats_sum_ptr_type)tmp1)->tag != 7) { goto __ats_lab_9_0 ; } __ats_lab_8_1: /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPundef()")) ; break ; /* branch: __ats_lab_9 */ __ats_lab_9_0: // if (((ats_sum_ptr_type)tmp1)->tag != 8) { ats_deadcode_failure_handle () ; } __ats_lab_9_1: tmp27 = ats_caselptrlab_mac(anairiats_sum_3, tmp1, atslab_0) ; /* tmp28 = */ atspre_fprint_string (arg0, ATSstrcst("E1XPcstsp(")) ; /* tmp29 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_cstsp (arg0, tmp27) ; /* tmp0 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp0) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3505(line=112, offs=22) -- 3537(line=112, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp30) ; ATSlocal (ats_ptr_type, tmp31) ; ATSlocal (ats_ptr_type, tmp32) ; // ATSlocal_void (tmp33) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xp: tmp31 = atspre_stdout_get () ; tmp32 = ats_selsin_mac(tmp31, atslab_1) ; /* tmp33 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (tmp32, arg0) ; /* tmp30 = */ atspre_stdout_view_set () ; return /* (tmp30) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3559(line=113, offs=22) -- 3591(line=113, offs=54) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp34) ; ATSlocal (ats_ptr_type, tmp35) ; ATSlocal (ats_ptr_type, tmp36) ; // ATSlocal_void (tmp37) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xp: tmp35 = atspre_stderr_get () ; tmp36 = ats_selsin_mac(tmp35, atslab_1) ; /* tmp37 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp (tmp36, arg0) ; /* tmp34 = */ atspre_stderr_view_set () ; return /* (tmp34) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3639(line=118, offs=16) -- 3713(line=119, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp38) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst: /* tmp38 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xp) ; return /* (tmp38) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3766(line=122, offs=25) -- 3803(line=122, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp39) ; ATSlocal (ats_ptr_type, tmp40) ; ATSlocal (ats_ptr_type, tmp41) ; // ATSlocal_void (tmp42) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xplst: tmp40 = atspre_stdout_get () ; tmp41 = ats_selsin_mac(tmp40, atslab_1) ; /* tmp42 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst (tmp41, arg0) ; /* tmp39 = */ atspre_stdout_view_set () ; return /* (tmp39) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_e1xplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3828(line=123, offs=25) -- 3865(line=123, offs=62) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xplst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp43) ; ATSlocal (ats_ptr_type, tmp44) ; ATSlocal (ats_ptr_type, tmp45) ; // ATSlocal_void (tmp46) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xplst: tmp44 = atspre_stderr_get () ; tmp45 = ats_selsin_mac(tmp44, atslab_1) ; /* tmp46 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_e1xplst (tmp45, arg0) ; /* tmp43 = */ atspre_stderr_view_set () ; return /* (tmp43) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_e1xplst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 3910(line=128, offs=13) -- 4645(line=153, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp47) ; ATSlocal (ats_ptr_type, tmp48) ; ATSlocal (ats_ptr_type, tmp49) ; ATSlocal (ats_ptr_type, tmp50) ; // ATSlocal_void (tmp51) ; // ATSlocal_void (tmp52) ; // ATSlocal_void (tmp53) ; // ATSlocal_void (tmp54) ; ATSlocal (ats_ptr_type, tmp55) ; // ATSlocal_void (tmp56) ; // ATSlocal_void (tmp57) ; ATSlocal (ats_ptr_type, tmp58) ; ATSlocal (ats_ptr_type, tmp59) ; // ATSlocal_void (tmp60) ; // ATSlocal_void (tmp61) ; // ATSlocal_void (tmp62) ; ATSlocal (ats_ptr_type, tmp63) ; // ATSlocal_void (tmp64) ; // ATSlocal_void (tmp65) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt: tmp48 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_5, arg1), atslab_s1rt_node) ; do { /* branch: __ats_lab_10 */ __ats_lab_10_0: if (((ats_sum_ptr_type)tmp48)->tag != 0) { goto __ats_lab_11_0 ; } __ats_lab_10_1: tmp49 = ats_caselptrlab_mac(anairiats_sum_6, tmp48, atslab_0) ; tmp50 = ats_caselptrlab_mac(anairiats_sum_6, tmp48, atslab_1) ; /* tmp51 = */ atspre_fprint_string (arg0, ATSstrcst("S1RTapp(")) ; /* tmp52 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (arg0, tmp49) ; /* tmp53 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp54 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (arg0, tmp50) ; /* tmp47 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_11 */ __ats_lab_11_0: if (((ats_sum_ptr_type)tmp48)->tag != 1) { goto __ats_lab_12_0 ; } __ats_lab_11_1: tmp55 = ats_caselptrlab_mac(anairiats_sum_3, tmp48, atslab_0) ; /* tmp56 = */ atspre_fprint_string (arg0, ATSstrcst("S1RTlist(")) ; /* tmp57 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (arg0, tmp55) ; /* tmp47 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_12 */ __ats_lab_12_0: if (((ats_sum_ptr_type)tmp48)->tag != 2) { goto __ats_lab_13_0 ; } __ats_lab_12_1: tmp58 = ats_caselptrlab_mac(anairiats_sum_6, tmp48, atslab_0) ; tmp59 = ats_caselptrlab_mac(anairiats_sum_6, tmp48, atslab_1) ; /* tmp60 = */ atspre_fprint_string (arg0, ATSstrcst("S1RTqid(")) ; /* tmp61 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0rtq (arg0, tmp58) ; /* tmp62 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp59) ; /* tmp47 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_13 */ __ats_lab_13_0: // if (((ats_sum_ptr_type)tmp48)->tag != 3) { ats_deadcode_failure_handle () ; } __ats_lab_13_1: tmp63 = ats_caselptrlab_mac(anairiats_sum_3, tmp48, atslab_0) ; /* tmp64 = */ atspre_fprint_string (arg0, ATSstrcst("S1RTtup(")) ; /* tmp65 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (arg0, tmp63) ; /* tmp47 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp47) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 4692(line=155, offs=22) -- 4728(line=155, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rt (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp66) ; ATSlocal (ats_ptr_type, tmp67) ; ATSlocal (ats_ptr_type, tmp68) ; // ATSlocal_void (tmp69) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rt: tmp67 = atspre_stdout_get () ; tmp68 = ats_selsin_mac(tmp67, atslab_1) ; /* tmp69 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (tmp68, arg0) ; /* tmp66 = */ atspre_stdout_view_set () ; return /* (tmp66) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 4750(line=156, offs=22) -- 4786(line=156, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rt (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp70) ; ATSlocal (ats_ptr_type, tmp71) ; ATSlocal (ats_ptr_type, tmp72) ; // ATSlocal_void (tmp73) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rt: tmp71 = atspre_stderr_get () ; tmp72 = ats_selsin_mac(tmp71, atslab_1) ; /* tmp73 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (tmp72, arg0) ; /* tmp70 = */ atspre_stderr_view_set () ; return /* (tmp70) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 4834(line=161, offs=16) -- 4908(line=162, offs=58) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp74) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst: /* tmp74 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt) ; return /* (tmp74) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 4961(line=165, offs=25) -- 5002(line=165, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rtlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp75) ; ATSlocal (ats_ptr_type, tmp76) ; ATSlocal (ats_ptr_type, tmp77) ; // ATSlocal_void (tmp78) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rtlst: tmp76 = atspre_stdout_get () ; tmp77 = ats_selsin_mac(tmp76, atslab_1) ; /* tmp78 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (tmp77, arg0) ; /* tmp75 = */ atspre_stdout_view_set () ; return /* (tmp75) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1rtlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 5027(line=166, offs=25) -- 5068(line=166, offs=66) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rtlst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp79) ; ATSlocal (ats_ptr_type, tmp80) ; ATSlocal (ats_ptr_type, tmp81) ; // ATSlocal_void (tmp82) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rtlst: tmp80 = atspre_stderr_get () ; tmp81 = ats_selsin_mac(tmp80, atslab_1) ; /* tmp82 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtlst (tmp81, arg0) ; /* tmp79 = */ atspre_stderr_view_set () ; return /* (tmp79) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1rtlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 5118(line=171, offs=3) -- 5210(line=172, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtopt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp83) ; ATSlocal (ats_ptr_type, tmp84) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtopt: do { /* branch: __ats_lab_14 */ __ats_lab_14_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_15_0 ; } __ats_lab_14_1: tmp84 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; /* tmp83 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (arg0, tmp84) ; break ; /* branch: __ats_lab_15 */ __ats_lab_15_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_15_1: break ; } while (0) ; return /* (tmp83) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtopt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 5263(line=177, offs=4) -- 5597(line=187, offs=4) */ ATSstaticdec() ats_void_type fprint_s1arg_13 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp85) ; // ATSlocal_void (tmp86) ; ATSlocal (ats_ptr_type, tmp87) ; ATSlocal (ats_ptr_type, tmp88) ; ATSlocal (ats_ptr_type, tmp89) ; // ATSlocal_void (tmp90) ; __ats_lab_fprint_s1arg_13: tmp87 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s1arg_sym) ; /* tmp86 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp87) ; tmp88 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_8, arg1), atslab_s1arg_srt) ; do { /* branch: __ats_lab_16 */ __ats_lab_16_0: if (tmp88 == (ats_sum_ptr_type)0) { goto __ats_lab_17_0 ; } __ats_lab_16_1: tmp89 = ats_caselptrlab_mac(anairiats_sum_7, tmp88, atslab_0) ; /* tmp90 = */ atspre_fprint_string (arg0, ATSstrcst(": ")) ; /* tmp85 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (arg0, tmp89) ; break ; /* branch: __ats_lab_17 */ __ats_lab_17_0: // if (tmp88 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_17_1: break ; } while (0) ; return /* (tmp85) */ ; } /* end of [fprint_s1arg_13] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 5627(line=189, offs=4) -- 5785(line=192, offs=60) */ ATSstaticdec() ats_void_type fprint_s1arglst_14 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp91) ; __ats_lab_fprint_s1arglst_14: /* tmp91 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &fprint_s1arg_13) ; return /* (tmp91) */ ; } /* end of [fprint_s1arglst_14] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 5840(line=197, offs=5) -- 6353(line=215, offs=4) */ ATSstaticdec() ats_void_type fprint_s1qua_15 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp92) ; ATSlocal (ats_ptr_type, tmp93) ; ATSlocal (ats_ptr_type, tmp94) ; // ATSlocal_void (tmp95) ; // ATSlocal_void (tmp96) ; ATSlocal (ats_ptr_type, tmp97) ; ATSlocal (ats_ptr_type, tmp98) ; // ATSlocal_void (tmp99) ; // ATSlocal_void (tmp100) ; // ATSlocal_void (tmp101) ; // ATSlocal_void (tmp102) ; __ats_lab_fprint_s1qua_15: tmp93 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_9, arg1), atslab_s1qua_node) ; do { /* branch: __ats_lab_18 */ __ats_lab_18_0: if (((ats_sum_ptr_type)tmp93)->tag != 0) { goto __ats_lab_19_0 ; } __ats_lab_18_1: tmp94 = ats_caselptrlab_mac(anairiats_sum_3, tmp93, atslab_0) ; /* tmp95 = */ atspre_fprint_string (arg0, ATSstrcst("S1Qprop(")) ; /* tmp96 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp94) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_19 */ __ats_lab_19_0: // if (((ats_sum_ptr_type)tmp93)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_19_1: tmp97 = ats_caselptrlab_mac(anairiats_sum_6, tmp93, atslab_0) ; tmp98 = ats_caselptrlab_mac(anairiats_sum_6, tmp93, atslab_1) ; /* tmp99 = */ atspre_fprint_string (arg0, ATSstrcst("S1Qvars(")) ; /* tmp100 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_i0delst (arg0, tmp97) ; /* tmp101 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp102 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext (arg0, tmp98) ; /* tmp92 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp92) */ ; } /* end of [fprint_s1qua_15] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 6496(line=220, offs=7) -- 6757(line=226, offs=19) */ ATSstaticdec() ats_void_type aux_17 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp104) ; ATSlocal (ats_ptr_type, tmp105) ; ATSlocal (ats_ptr_type, tmp106) ; // ATSlocal_void (tmp107) ; ATSlocal (ats_bool_type, tmp108) ; // ATSlocal_void (tmp109) ; ATSlocal (ats_int_type, tmp110) ; __ats_lab_aux_17: do { /* branch: __ats_lab_20 */ __ats_lab_20_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_21_0 ; } __ats_lab_20_1: tmp105 = ats_caselptrlab_mac(anairiats_sum_10, arg2, atslab_0) ; tmp106 = ats_caselptrlab_mac(anairiats_sum_10, arg2, atslab_1) ; tmp108 = atspre_gt_int_int (arg1, 0) ; if (tmp108) { /* tmp107 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp109 = */ fprint_s1qua_15 (arg0, tmp105) ; tmp110 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp110 ; arg2 = tmp106 ; goto __ats_lab_aux_17 ; // tail call break ; /* branch: __ats_lab_21 */ __ats_lab_21_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_21_1: break ; } while (0) ; return /* (tmp104) */ ; } /* end of [aux_17] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 6384(line=217, offs=5) -- 6820(line=230, offs=4) */ ATSstaticdec() ats_void_type fprint_s1qualst_16 (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp103) ; __ats_lab_fprint_s1qualst_16: /* tmp103 = */ aux_17 (arg0, 0, arg1) ; return /* (tmp103) */ ; } /* end of [fprint_s1qualst_16] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 6894(line=235, offs=14) -- 11726(line=403, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp111) ; ATSlocal (ats_ptr_type, tmp112) ; ATSlocal (ats_ptr_type, tmp113) ; ATSlocal (ats_ptr_type, tmp114) ; // ATSlocal_void (tmp115) ; // ATSlocal_void (tmp116) ; // ATSlocal_void (tmp117) ; // ATSlocal_void (tmp118) ; ATSlocal (ats_ptr_type, tmp119) ; ATSlocal (ats_ptr_type, tmp120) ; // ATSlocal_void (tmp121) ; // ATSlocal_void (tmp122) ; // ATSlocal_void (tmp123) ; // ATSlocal_void (tmp124) ; ATSlocal (ats_char_type, tmp125) ; // ATSlocal_void (tmp126) ; // ATSlocal_void (tmp127) ; ATSlocal (ats_int_type, tmp128) ; ATSlocal (ats_ptr_type, tmp129) ; ATSlocal (ats_ptr_type, tmp130) ; // ATSlocal_void (tmp131) ; // ATSlocal_void (tmp132) ; // ATSlocal_void (tmp133) ; // ATSlocal_void (tmp134) ; // ATSlocal_void (tmp135) ; // ATSlocal_void (tmp136) ; ATSlocal (ats_ptr_type, tmp137) ; ATSlocal (ats_ptr_type, tmp138) ; // ATSlocal_void (tmp139) ; // ATSlocal_void (tmp140) ; // ATSlocal_void (tmp141) ; // ATSlocal_void (tmp142) ; ATSlocal (ats_ptr_type, tmp143) ; ATSlocal (ats_int_type, tmp144) ; ATSlocal (ats_int_type, tmp145) ; ATSlocal (ats_ptr_type, tmp146) ; // ATSlocal_void (tmp147) ; // ATSlocal_void (tmp148) ; // ATSlocal_void (tmp149) ; // ATSlocal_void (tmp150) ; // ATSlocal_void (tmp151) ; // ATSlocal_void (tmp152) ; // ATSlocal_void (tmp153) ; // ATSlocal_void (tmp154) ; ATSlocal (ats_ptr_type, tmp155) ; ATSlocal (ats_ptr_type, tmp156) ; // ATSlocal_void (tmp157) ; // ATSlocal_void (tmp158) ; ATSlocal (ats_int_type, tmp159) ; ATSlocal (ats_ptr_type, tmp160) ; // ATSlocal_void (tmp161) ; // ATSlocal_void (tmp162) ; // ATSlocal_void (tmp163) ; // ATSlocal_void (tmp164) ; ATSlocal (ats_int_type, tmp165) ; ATSlocal (ats_ptr_type, tmp166) ; // ATSlocal_void (tmp167) ; // ATSlocal_void (tmp168) ; // ATSlocal_void (tmp169) ; // ATSlocal_void (tmp170) ; ATSlocal (ats_ptr_type, tmp171) ; ATSlocal (ats_ptr_type, tmp172) ; // ATSlocal_void (tmp173) ; ATSlocal (ats_ptr_type, tmp174) ; ATSlocal (ats_ptr_type, tmp175) ; // ATSlocal_void (tmp176) ; // ATSlocal_void (tmp177) ; // ATSlocal_void (tmp178) ; // ATSlocal_void (tmp179) ; ATSlocal (ats_int_type, tmp180) ; ATSlocal (ats_ptr_type, tmp181) ; // ATSlocal_void (tmp182) ; // ATSlocal_void (tmp183) ; // ATSlocal_void (tmp184) ; // ATSlocal_void (tmp185) ; ATSlocal (ats_ptr_type, tmp186) ; ATSlocal (ats_ptr_type, tmp187) ; // ATSlocal_void (tmp188) ; // ATSlocal_void (tmp189) ; // ATSlocal_void (tmp190) ; // ATSlocal_void (tmp191) ; ATSlocal (ats_ptr_type, tmp192) ; // ATSlocal_void (tmp193) ; // ATSlocal_void (tmp194) ; // ATSlocal_void (tmp195) ; ATSlocal (ats_int_type, tmp196) ; ATSlocal (ats_ptr_type, tmp197) ; // ATSlocal_void (tmp198) ; // ATSlocal_void (tmp199) ; // ATSlocal_void (tmp200) ; // ATSlocal_void (tmp201) ; ATSlocal (ats_ptr_type, tmp202) ; ATSlocal (ats_ptr_type, tmp203) ; // ATSlocal_void (tmp204) ; // ATSlocal_void (tmp205) ; // ATSlocal_void (tmp206) ; // ATSlocal_void (tmp207) ; ATSlocal (ats_int_type, tmp208) ; ATSlocal (ats_ptr_type, tmp209) ; // ATSlocal_void (tmp210) ; // ATSlocal_void (tmp211) ; // ATSlocal_void (tmp212) ; // ATSlocal_void (tmp213) ; ATSlocal (ats_int_type, tmp214) ; ATSlocal (ats_ptr_type, tmp215) ; ATSlocal (ats_ptr_type, tmp216) ; // ATSlocal_void (tmp217) ; // ATSlocal_void (tmp218) ; // ATSlocal_void (tmp219) ; // ATSlocal_void (tmp220) ; // ATSlocal_void (tmp221) ; // ATSlocal_void (tmp222) ; ATSlocal (ats_ptr_type, tmp223) ; ATSlocal (ats_ptr_type, tmp224) ; // ATSlocal_void (tmp225) ; // ATSlocal_void (tmp226) ; // ATSlocal_void (tmp227) ; // ATSlocal_void (tmp228) ; ATSlocal (ats_ptr_type, tmp229) ; ATSlocal (ats_ptr_type, tmp230) ; // ATSlocal_void (tmp231) ; // ATSlocal_void (tmp232) ; // ATSlocal_void (tmp233) ; // ATSlocal_void (tmp234) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp: tmp112 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_11, arg1), atslab_s1exp_node) ; do { /* branch: __ats_lab_22 */ __ats_lab_22_0: if (((ats_sum_ptr_type)tmp112)->tag != 0) { goto __ats_lab_23_0 ; } __ats_lab_22_1: tmp113 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp114 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp115 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eann(")) ; /* tmp116 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp113) ; /* tmp117 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp118 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (arg0, tmp114) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_23 */ __ats_lab_23_0: if (((ats_sum_ptr_type)tmp112)->tag != 1) { goto __ats_lab_24_0 ; } __ats_lab_23_1: /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eany()")) ; break ; /* branch: __ats_lab_24 */ __ats_lab_24_0: if (((ats_sum_ptr_type)tmp112)->tag != 2) { goto __ats_lab_25_0 ; } __ats_lab_24_1: tmp119 = ats_caselptrlab_mac(anairiats_sum_1, tmp112, atslab_0) ; tmp120 = ats_caselptrlab_mac(anairiats_sum_1, tmp112, atslab_2) ; /* tmp121 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eapp(")) ; /* tmp122 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp119) ; /* tmp123 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp124 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp120) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_25 */ __ats_lab_25_0: if (((ats_sum_ptr_type)tmp112)->tag != 3) { goto __ats_lab_26_0 ; } __ats_lab_25_1: tmp125 = ats_caselptrlab_mac(anairiats_sum_2, tmp112, atslab_0) ; /* tmp126 = */ atspre_fprint_string (arg0, ATSstrcst("S1Echar(")) ; /* tmp127 = */ atspre_fprint_char (arg0, tmp125) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_26 */ __ats_lab_26_0: if (((ats_sum_ptr_type)tmp112)->tag != 4) { goto __ats_lab_27_0 ; } __ats_lab_26_1: tmp128 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_0) ; tmp129 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_1) ; tmp130 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_2) ; /* tmp131 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eexi(")) ; /* tmp132 = */ atspre_fprint_int (arg0, tmp128) ; /* tmp133 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp134 = */ fprint_s1qualst_16 (arg0, tmp129) ; /* tmp135 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp136 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp130) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_27 */ __ats_lab_27_0: if (((ats_sum_ptr_type)tmp112)->tag != 5) { goto __ats_lab_28_0 ; } __ats_lab_27_1: tmp137 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp138 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp139 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eextype(")) ; /* tmp140 = */ atspre_fprint_string (arg0, tmp137) ; /* tmp141 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp142 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explstlst (arg0, tmp138) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_28 */ __ats_lab_28_0: if (((ats_sum_ptr_type)tmp112)->tag != 6) { goto __ats_lab_31_0 ; } __ats_lab_28_1: tmp143 = ats_caselptrlab_mac(anairiats_sum_13, tmp112, atslab_0) ; tmp144 = ats_caselptrlab_mac(anairiats_sum_13, tmp112, atslab_1) ; tmp145 = ats_caselptrlab_mac(anairiats_sum_13, tmp112, atslab_2) ; tmp146 = ats_caselptrlab_mac(anairiats_sum_13, tmp112, atslab_3) ; /* tmp147 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eimp(")) ; /* tmp148 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_funclo (arg0, tmp143) ; /* tmp149 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp150 = */ atspre_fprint_int (arg0, tmp144) ; /* tmp151 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp152 = */ atspre_fprint_int (arg0, tmp145) ; /* tmp153 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; do { /* branch: __ats_lab_29 */ __ats_lab_29_0: if (tmp146 == (ats_sum_ptr_type)0) { goto __ats_lab_30_0 ; } __ats_lab_29_1: tmp155 = ats_caselptrlab_mac(anairiats_sum_7, tmp146, atslab_0) ; /* tmp154 = */ ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__fprint_effcst (arg0, tmp155) ; break ; /* branch: __ats_lab_30 */ __ats_lab_30_0: // if (tmp146 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_30_1: break ; } while (0) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_31 */ __ats_lab_31_0: if (((ats_sum_ptr_type)tmp112)->tag != 7) { goto __ats_lab_32_0 ; } __ats_lab_31_1: tmp156 = ats_caselptrlab_mac(anairiats_sum_3, tmp112, atslab_0) ; /* tmp157 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eint(")) ; /* tmp158 = */ atspre_fprint_string (arg0, tmp156) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_32 */ __ats_lab_32_0: if (((ats_sum_ptr_type)tmp112)->tag != 8) { goto __ats_lab_33_0 ; } __ats_lab_32_1: tmp159 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_0) ; tmp160 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_1) ; /* tmp161 = */ atspre_fprint_string (arg0, ATSstrcst("S1Einvar(")) ; /* tmp162 = */ atspre_fprint_int (arg0, tmp159) ; /* tmp163 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp164 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp160) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_33 */ __ats_lab_33_0: if (((ats_sum_ptr_type)tmp112)->tag != 9) { goto __ats_lab_34_0 ; } __ats_lab_33_1: /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst("S1Elam(...)")) ; break ; /* branch: __ats_lab_34 */ __ats_lab_34_0: if (((ats_sum_ptr_type)tmp112)->tag != 10) { goto __ats_lab_35_0 ; } __ats_lab_34_1: tmp165 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_0) ; tmp166 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_1) ; /* tmp167 = */ atspre_fprint_string (arg0, ATSstrcst("S1Elist(")) ; /* tmp168 = */ atspre_fprint_int (arg0, tmp165) ; /* tmp169 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp170 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp166) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_35 */ __ats_lab_35_0: if (((ats_sum_ptr_type)tmp112)->tag != 11) { goto __ats_lab_36_0 ; } __ats_lab_35_1: tmp171 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp172 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp173 = */ ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__fprint_s0taq (arg0, tmp171) ; /* tmp111 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp172) ; break ; /* branch: __ats_lab_36 */ __ats_lab_36_0: if (((ats_sum_ptr_type)tmp112)->tag != 12) { goto __ats_lab_37_0 ; } __ats_lab_36_1: tmp174 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp175 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp176 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eread(")) ; /* tmp177 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp174) ; /* tmp178 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp179 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp175) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_37 */ __ats_lab_37_0: if (((ats_sum_ptr_type)tmp112)->tag != 13) { goto __ats_lab_38_0 ; } __ats_lab_37_1: tmp180 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_0) ; tmp181 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_1) ; /* tmp182 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etop(")) ; /* tmp183 = */ atspre_fprint_int (arg0, tmp180) ; /* tmp184 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp185 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp181) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_38 */ __ats_lab_38_0: if (((ats_sum_ptr_type)tmp112)->tag != 14) { goto __ats_lab_39_0 ; } __ats_lab_38_1: tmp186 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp187 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp188 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etrans(")) ; /* tmp189 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp186) ; /* tmp190 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; /* tmp191 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp187) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_39 */ __ats_lab_39_0: if (((ats_sum_ptr_type)tmp112)->tag != 15) { goto __ats_lab_40_0 ; } __ats_lab_39_1: tmp192 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; /* tmp193 = */ atspre_fprint_string (arg0, ATSstrcst("S1Earray(")) ; /* tmp194 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp192) ; /* tmp195 = */ atspre_fprint_string (arg0, ATSstrcst(", ...")) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_40 */ __ats_lab_40_0: if (((ats_sum_ptr_type)tmp112)->tag != 16) { goto __ats_lab_41_0 ; } __ats_lab_40_1: tmp196 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_0) ; tmp197 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_1) ; /* tmp198 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etyrec(")) ; /* tmp199 = */ atspre_fprint_int (arg0, tmp196) ; /* tmp200 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp201 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst (arg0, tmp197) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_41 */ __ats_lab_41_0: if (((ats_sum_ptr_type)tmp112)->tag != 17) { goto __ats_lab_42_0 ; } __ats_lab_41_1: tmp202 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp203 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp204 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etyrec_ext(")) ; /* tmp205 = */ atspre_fprint_string (arg0, tmp202) ; /* tmp206 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp207 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst (arg0, tmp203) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_42 */ __ats_lab_42_0: if (((ats_sum_ptr_type)tmp112)->tag != 18) { goto __ats_lab_43_0 ; } __ats_lab_42_1: tmp208 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_0) ; tmp209 = ats_caselptrlab_mac(anairiats_sum_14, tmp112, atslab_1) ; /* tmp210 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etytup(")) ; /* tmp211 = */ atspre_fprint_int (arg0, tmp208) ; /* tmp212 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp213 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp209) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_43 */ __ats_lab_43_0: if (((ats_sum_ptr_type)tmp112)->tag != 19) { goto __ats_lab_44_0 ; } __ats_lab_43_1: tmp214 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_0) ; tmp215 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_1) ; tmp216 = ats_caselptrlab_mac(anairiats_sum_12, tmp112, atslab_2) ; /* tmp217 = */ atspre_fprint_string (arg0, ATSstrcst("S1Etytup2(")) ; /* tmp218 = */ atspre_fprint_int (arg0, tmp214) ; /* tmp219 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp220 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp215) ; /* tmp221 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp222 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp216) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_44 */ __ats_lab_44_0: if (((ats_sum_ptr_type)tmp112)->tag != 20) { goto __ats_lab_45_0 ; } __ats_lab_44_1: tmp223 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp224 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp225 = */ atspre_fprint_string (arg0, ATSstrcst("S1Euni(")) ; /* tmp226 = */ fprint_s1qualst_16 (arg0, tmp223) ; /* tmp227 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp228 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp224) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; /* branch: __ats_lab_45 */ __ats_lab_45_0: // if (((ats_sum_ptr_type)tmp112)->tag != 21) { ats_deadcode_failure_handle () ; } __ats_lab_45_1: tmp229 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_0) ; tmp230 = ats_caselptrlab_mac(anairiats_sum_6, tmp112, atslab_1) ; /* tmp231 = */ atspre_fprint_string (arg0, ATSstrcst("S1Eunion(")) ; /* tmp232 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp229) ; /* tmp233 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp234 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst (arg0, tmp230) ; /* tmp111 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp111) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 11775(line=405, offs=23) -- 11812(line=405, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp235) ; ATSlocal (ats_ptr_type, tmp236) ; ATSlocal (ats_ptr_type, tmp237) ; // ATSlocal_void (tmp238) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1exp: tmp236 = atspre_stdout_get () ; tmp237 = ats_selsin_mac(tmp236, atslab_1) ; /* tmp238 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (tmp237, arg0) ; /* tmp235 = */ atspre_stdout_view_set () ; return /* (tmp235) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 11835(line=406, offs=23) -- 11872(line=406, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1exp (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp239) ; ATSlocal (ats_ptr_type, tmp240) ; ATSlocal (ats_ptr_type, tmp241) ; // ATSlocal_void (tmp242) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1exp: tmp240 = atspre_stderr_get () ; tmp241 = ats_selsin_mac(tmp240, atslab_1) ; /* tmp242 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (tmp241, arg0) ; /* tmp239 = */ atspre_stderr_view_set () ; return /* (tmp239) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1exp] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 11921(line=411, offs=17) -- 11997(line=412, offs=60) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp243) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst: /* tmp243 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp) ; return /* (tmp243) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12052(line=415, offs=26) -- 12094(line=415, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp244) ; ATSlocal (ats_ptr_type, tmp245) ; ATSlocal (ats_ptr_type, tmp246) ; // ATSlocal_void (tmp247) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1explst: tmp245 = atspre_stdout_get () ; tmp246 = ats_selsin_mac(tmp245, atslab_1) ; /* tmp247 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (tmp246, arg0) ; /* tmp244 = */ atspre_stdout_view_set () ; return /* (tmp244) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__print_s1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12120(line=416, offs=26) -- 12162(line=416, offs=68) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1explst (ats_ptr_type arg0) { /* local vardec */ // ATSlocal_void (tmp248) ; ATSlocal (ats_ptr_type, tmp249) ; ATSlocal (ats_ptr_type, tmp250) ; // ATSlocal_void (tmp251) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1explst: tmp249 = atspre_stderr_get () ; tmp250 = ats_selsin_mac(tmp249, atslab_1) ; /* tmp251 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (tmp250, arg0) ; /* tmp248 = */ atspre_stderr_view_set () ; return /* (tmp248) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__prerr_s1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12211(line=421, offs=17) -- 12312(line=423, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1expopt (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp252) ; ATSlocal (ats_ptr_type, tmp253) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1expopt: do { /* branch: __ats_lab_46 */ __ats_lab_46_0: if (arg1 == (ats_sum_ptr_type)0) { goto __ats_lab_47_0 ; } __ats_lab_46_1: tmp253 = ats_caselptrlab_mac(anairiats_sum_7, arg1, atslab_0) ; /* tmp252 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp253) ; break ; /* branch: __ats_lab_47 */ __ats_lab_47_0: // if (arg1 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_47_1: break ; } while (0) ; return /* (tmp252) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1expopt] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12371(line=426, offs=20) -- 12455(line=427, offs=67) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp254) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explstlst: /* tmp254 = */ ATS_2d0_2e2_2e11_2src_2ats_list_2esats__fprintlst (arg0, arg1, ATSstrcst(", "), &ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst) ; return /* (tmp254) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12553(line=433, offs=7) -- 12979(line=445, offs=6) */ ATSstaticdec() ats_void_type aux_27 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp256) ; ATSlocal (ats_ptr_type, tmp257) ; ATSlocal (ats_ptr_type, tmp258) ; ATSlocal (ats_ptr_type, tmp259) ; // ATSlocal_void (tmp260) ; ATSlocal (ats_bool_type, tmp261) ; // ATSlocal_void (tmp262) ; // ATSlocal_void (tmp263) ; // ATSlocal_void (tmp264) ; ATSlocal (ats_int_type, tmp265) ; __ats_lab_aux_27: do { /* branch: __ats_lab_48 */ __ats_lab_48_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_49_0 ; } __ats_lab_48_1: tmp257 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_0) ; tmp258 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_1) ; tmp259 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_2) ; tmp261 = atspre_gt_int_int (arg1, 0) ; if (tmp261) { /* tmp260 = */ atspre_fprint_string (arg0, ATSstrcst(", ")) ; } else { /* empty */ } /* end of [if] */ /* tmp262 = */ ATS_2d0_2e2_2e11_2src_2ats_label_2esats__fprint_label (arg0, tmp257) ; /* tmp263 = */ atspre_fprint_string (arg0, ATSstrcst("=")) ; /* tmp264 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1exp (arg0, tmp258) ; tmp265 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp265 ; arg2 = tmp259 ; goto __ats_lab_aux_27 ; // tail call break ; /* branch: __ats_lab_49 */ __ats_lab_49_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_49_1: break ; } while (0) ; return /* (tmp256) */ ; } /* end of [aux_27] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 12523(line=432, offs=7) -- 13024(line=448, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp255) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst: /* tmp255 = */ aux_27 (arg0, 0, arg1) ; return /* (tmp255) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_labs1explst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 13148(line=455, offs=7) -- 13505(line=464, offs=33) */ ATSstaticdec() ats_void_type aux_29 (ats_ref_type arg0, ats_int_type arg1, ats_ptr_type arg2) { /* local vardec */ // ATSlocal_void (tmp267) ; ATSlocal (ats_ptr_type, tmp268) ; ATSlocal (ats_ptr_type, tmp269) ; // ATSlocal_void (tmp270) ; ATSlocal (ats_bool_type, tmp271) ; // ATSlocal_void (tmp272) ; ATSlocal (ats_int_type, tmp273) ; __ats_lab_aux_29: do { /* branch: __ats_lab_50 */ __ats_lab_50_0: if (arg2 == (ats_sum_ptr_type)0) { goto __ats_lab_51_0 ; } __ats_lab_50_1: tmp268 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_1) ; tmp269 = ats_caselptrlab_mac(anairiats_sum_15, arg2, atslab_2) ; tmp271 = atspre_gt_int_int (arg1, 0) ; if (tmp271) { /* tmp270 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; } else { /* empty */ } /* end of [if] */ /* tmp272 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp268) ; tmp273 = atspre_add_int_int (arg1, 1) ; arg0 = arg0 ; arg1 = tmp273 ; arg2 = tmp269 ; goto __ats_lab_aux_29 ; // tail call break ; /* branch: __ats_lab_51 */ __ats_lab_51_0: // if (arg2 != (ats_sum_ptr_type)0) { ats_deadcode_failure_handle () ; } __ats_lab_51_1: break ; } while (0) ; return /* (tmp267) */ ; } /* end of [aux_29] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 13116(line=454, offs=7) -- 13554(line=468, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_tmps1explstlst (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp266) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_tmps1explstlst: /* tmp266 = */ aux_29 (arg0, 0, arg1) ; return /* (tmp266) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_tmps1explstlst] */ /* // /home/hwxi/research/Anairiats/src/ats_staexp1_print.dats: 13633(line=473, offs=16) -- 14055(line=487, offs=4) */ ATSglobaldec() ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext (ats_ref_type arg0, ats_ptr_type arg1) { /* local vardec */ // ATSlocal_void (tmp274) ; ATSlocal (ats_ptr_type, tmp275) ; ATSlocal (ats_ptr_type, tmp276) ; ATSlocal (ats_ptr_type, tmp277) ; ATSlocal (ats_ptr_type, tmp278) ; ATSlocal (ats_ptr_type, tmp279) ; // ATSlocal_void (tmp280) ; // ATSlocal_void (tmp281) ; // ATSlocal_void (tmp282) ; // ATSlocal_void (tmp283) ; // ATSlocal_void (tmp284) ; // ATSlocal_void (tmp285) ; __ats_lab_ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext: tmp275 = ats_selbox_mac(ats_castptr_mac(anairiats_rec_16, arg1), atslab_s1rtext_node) ; do { /* branch: __ats_lab_52 */ __ats_lab_52_0: if (((ats_sum_ptr_type)tmp275)->tag != 0) { goto __ats_lab_53_0 ; } __ats_lab_52_1: tmp276 = ats_caselptrlab_mac(anairiats_sum_3, tmp275, atslab_0) ; /* tmp274 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rt (arg0, tmp276) ; break ; /* branch: __ats_lab_53 */ __ats_lab_53_0: // if (((ats_sum_ptr_type)tmp275)->tag != 1) { ats_deadcode_failure_handle () ; } __ats_lab_53_1: tmp277 = ats_caselptrlab_mac(anairiats_sum_1, tmp275, atslab_0) ; tmp278 = ats_caselptrlab_mac(anairiats_sum_1, tmp275, atslab_1) ; tmp279 = ats_caselptrlab_mac(anairiats_sum_1, tmp275, atslab_2) ; /* tmp280 = */ atspre_fprint_string (arg0, ATSstrcst("S1TEsub(")) ; /* tmp281 = */ ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__fprint_symbol (arg0, tmp277) ; /* tmp282 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp283 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext (arg0, tmp278) ; /* tmp284 = */ atspre_fprint_string (arg0, ATSstrcst("; ")) ; /* tmp285 = */ ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1explst (arg0, tmp279) ; /* tmp274 = */ atspre_fprint_string (arg0, ATSstrcst(")")) ; break ; } while (0) ; return /* (tmp274) */ ; } /* end of [ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__fprint_s1rtext] */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload (void) ; extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_effect_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_label_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_list_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_symbol_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_syntax_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_2esats__staload () ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_staexp1_print_2edats__staload () ; #ifdef _ATS_PROOFCHECK ATS_2d0_2e2_2e11_2prelude_2basics_dyn_2esats__file_mode_lte_w_w_prfck () ; #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ /* marking external values for GC */ /* code for dynamic loading */ return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_staexp1_print_dats.c] */ ats-lang-anairiats-0.2.11/bootstrap1/ats_set_fun_dats.c0000664000175000017500000001044212223166160021563 0ustar hwxihwxi/* ** ** The C code is generated by ATS/Anairiats ** The compilation time is: 2013-10-2: 22h:43m ** */ /* include some .h files */ #ifndef _ATS_HEADER_NONE #include "ats_config.h" #include "ats_basics.h" #include "ats_types.h" #include "ats_exception.h" #include "ats_memory.h" #endif /* _ATS_HEADER_NONE */ /* include some .cats files */ #ifndef _ATS_PRELUDE_NONE #include "prelude/CATS/basics.cats" #include "prelude/CATS/bool.cats" #include "prelude/CATS/char.cats" #include "prelude/CATS/byte.cats" #include "prelude/CATS/float.cats" #include "prelude/CATS/integer.cats" #include "prelude/CATS/integer_ptr.cats" #include "prelude/CATS/integer_fixed.cats" #include "prelude/CATS/sizetype.cats" #include "prelude/CATS/pointer.cats" #include "prelude/CATS/reference.cats" #include "prelude/CATS/string.cats" #include "prelude/CATS/lazy.cats" #include "prelude/CATS/lazy_vt.cats" #include "prelude/CATS/printf.cats" #include "prelude/CATS/list.cats" #include "prelude/CATS/option.cats" #include "prelude/CATS/array.cats" #include "prelude/CATS/matrix.cats" #endif /* _ATS_PRELUDE_NONE */ /* prologues from statically loaded files */ /* external codes at top */ /* type definitions */ /* external typedefs */ /* external dynamic constructor declarations */ ATSextern_val(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; /* external dynamic constant declarations */ ATSextern_fun(ats_void_type, atspre_cloptr_free) (ats_ptr_type) ; ATSextern_fun(ats_int_type, atspre_iadd) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_int_type, atspre_isub) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_ilte) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igt) (ats_int_type, ats_int_type) ; ATSextern_fun(ats_bool_type, atspre_igte) (ats_int_type, ats_int_type) ; /* external dynamic terminating constant declarations */ #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* assuming abstract types */ int ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__sasp__set_t = 0 ; /* sum constructor declarations */ ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Bl_1) ; ATSglobal(ats_sum_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Br_2) ; /* exn constructor declarations */ /* global dynamic (non-functional) constant declarations */ ATSglobal(ats_ptr_type, ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil) ; /* internal function declarations */ /* partial value template declarations */ /* static temporary variable declarations */ ATSstatic (ats_ptr_type, statmp0) ; /* external value variable declarations */ /* function implementations */ /* static load function */ extern ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload (void) ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () { static int ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload_flag = 0 ; if (ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload_flag) return ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__staload () ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0.tag = 0 ; // ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Bl_1.tag = 1 ; // ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__Br_2.tag = 2 ; return ; } /* staload function */ /* dynamic load function */ // dynload flag declaration extern ats_int_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload_flag ; ats_void_type ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload () { ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__dynload_flag = 1 ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__staload () ; #ifdef _ATS_PROOFCHECK #endif /* _ATS_PROOFCHECK */ /* marking static variables for GC */ ATS_GC_MARKROOT(&statmp0, sizeof(ats_ptr_type)) ; /* marking external values for GC */ /* code for dynamic loading */ statmp0 = (ats_sum_ptr_type)(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2edats__E_0) ; ATS_GC_MARKROOT(&ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil, sizeof(ats_ptr_type)) ; ATS_2d0_2e2_2e11_2src_2ats_set_fun_2esats__set_nil = statmp0 ; return ; } /* end of [dynload function] */ /* external codes at mid */ /* external codes at bot */ /* ****** ****** */ /* end of [/home/hwxi/research/Anairiats/bootstrap1/ats_set_fun_dats.c] */